summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.gitignore2
-rwxr-xr-xbin/syncqt31
-rw-r--r--config.tests/arch/arch.pro1
-rw-r--r--config.tests/arch/arch_host.pro2
-rw-r--r--config.tests/qpa/linuxfb/linuxfb.cpp1
-rwxr-xr-xconfig.tests/unix/arch.test28
-rw-r--r--config.tests/unix/clock-monotonic/clock-monotonic.cpp2
-rwxr-xr-xconfig.tests/unix/compile.test9
-rw-r--r--config.tests/unix/eventfd/eventfd.pro3
-rw-r--r--config.tests/unix/eventfd/main.cpp (renamed from mkspecs/unsupported/linux-android-armeabi-v7a-g++/qplatformdefs.h)15
-rw-r--r--config.tests/unix/getaddrinfo/getaddrinfotest.cpp2
-rwxr-xr-xconfigure604
-rw-r--r--dist/changes-5.1.0140
-rw-r--r--doc/global/qt-cpp-ignore.qdocconf6
-rw-r--r--doc/global/template/style/offline.css41
-rw-r--r--doc/global/template/style/online.css42
-rw-r--r--doc/src/examples/customtypesending.qdoc2
-rw-r--r--examples/dbus/complexpingpong/complexping.cpp4
-rw-r--r--examples/dbus/complexpingpong/complexpong.cpp4
-rw-r--r--examples/dbus/pingpong/pong.cpp4
-rw-r--r--examples/gui/openglwindow/main.cpp5
-rw-r--r--examples/gui/openglwindow/openglwindow.cpp11
-rw-r--r--examples/gui/openglwindow/openglwindow.h1
-rw-r--r--examples/ipc/ipc.pro2
-rw-r--r--examples/ipc/sharedmemory/dialog.cpp2
-rw-r--r--examples/network/doc/src/blockingfortuneclient.qdoc4
-rw-r--r--examples/network/doc/src/threadedfortuneserver.qdoc8
-rw-r--r--examples/network/http/httpwindow.cpp4
-rw-r--r--examples/network/network.pro2
-rw-r--r--examples/network/securesocketclient/sslclient.h2
-rw-r--r--examples/network/torrent/addtorrentdialog.cpp4
-rw-r--r--examples/network/torrent/bencodeparser.cpp200
-rw-r--r--examples/network/torrent/bencodeparser.h2
-rw-r--r--examples/network/torrent/filemanager.h2
-rw-r--r--examples/network/torrent/main.cpp1
-rw-r--r--examples/network/torrent/mainwindow.cpp2
-rw-r--r--examples/network/torrent/mainwindow.h6
-rw-r--r--examples/network/torrent/metainfo.h2
-rw-r--r--examples/network/torrent/peerwireclient.cpp8
-rw-r--r--examples/network/torrent/peerwireclient.h11
-rw-r--r--examples/network/torrent/torrentclient.cpp10
-rw-r--r--examples/network/torrent/torrentclient.h4
-rw-r--r--examples/network/torrent/trackerclient.cpp49
-rw-r--r--examples/network/torrent/trackerclient.h4
-rw-r--r--examples/opengl/cube/geometryengine.cpp2
-rw-r--r--examples/opengl/cube/mainwidget.cpp2
-rw-r--r--examples/opengl/grabber/glwidget.cpp2
-rw-r--r--examples/opengl/grabber/glwidget.h2
-rw-r--r--examples/opengl/hellogl_es2/bubble.cpp2
-rw-r--r--examples/opengl/hellogl_es2/glwidget.cpp4
-rw-r--r--examples/opengl/hellogl_es2/glwidget.h2
-rw-r--r--examples/opengl/hellogl_es2/mainwindow.cpp2
-rw-r--r--examples/opengl/overpainting/bubble.cpp2
-rw-r--r--examples/opengl/paintedwindow/paintedwindow.cpp2
-rw-r--r--examples/qtconcurrent/imagescaling/imagescaling.cpp11
-rw-r--r--examples/qtconcurrent/progressdialog/main.cpp4
-rw-r--r--examples/qtestlib/tutorial5/benchmarking.cpp4
-rw-r--r--examples/sql/doc/src/querymodel.qdoc2
-rw-r--r--examples/sql/doc/src/relationaltablemodel.qdoc2
-rw-r--r--examples/sql/doc/src/tablemodel.qdoc2
-rw-r--r--examples/threads/queuedcustomtype/main.cpp2
-rw-r--r--examples/tools/doc/contiguouscache.qdoc2
-rw-r--r--examples/tools/doc/src/customtype.qdoc2
-rw-r--r--examples/touch/fingerpaint/scribblearea.cpp2
-rw-r--r--examples/touch/pinchzoom/mouse.cpp2
-rw-r--r--examples/widgets/animation/appchooser/main.cpp2
-rw-r--r--examples/widgets/animation/easing/window.h4
-rw-r--r--examples/widgets/animation/stickman/animation.cpp18
-rw-r--r--examples/widgets/animation/stickman/lifecycle.cpp20
-rw-r--r--examples/widgets/animation/stickman/node.cpp4
-rw-r--r--examples/widgets/animation/stickman/stickman.h4
-rw-r--r--examples/widgets/animation/sub-attaq/boat_p.h3
-rw-r--r--examples/widgets/animation/sub-attaq/qanimationstate.h4
-rw-r--r--examples/widgets/animation/sub-attaq/states.cpp4
-rw-r--r--examples/widgets/animation/sub-attaq/states.h7
-rw-r--r--examples/widgets/dialogs/classwizard/classwizard.h2
-rw-r--r--examples/widgets/dialogs/classwizard/main.cpp2
-rw-r--r--examples/widgets/dialogs/dialogs.pro1
-rw-r--r--examples/widgets/dialogs/licensewizard/licensewizard.cpp2
-rw-r--r--examples/widgets/dialogs/sipdialog/dialog.cpp2
-rw-r--r--examples/widgets/doc/src/addressbook-fr.qdoc48
-rw-r--r--examples/widgets/doc/src/addressbook-tutorial.qdoc6
-rw-r--r--examples/widgets/doc/src/addressbook.qdoc2
-rw-r--r--examples/widgets/doc/src/codeeditor.qdoc12
-rw-r--r--examples/widgets/doc/src/coloreditorfactory.qdoc20
-rw-r--r--examples/widgets/doc/src/diagramscene.qdoc232
-rw-r--r--examples/widgets/doc/src/dockwidgets.qdoc4
-rw-r--r--examples/widgets/doc/src/easing.qdoc2
-rw-r--r--examples/widgets/doc/src/echoplugin.qdoc18
-rw-r--r--examples/widgets/doc/src/fetchmore.qdoc2
-rw-r--r--examples/widgets/doc/src/flowlayout.qdoc90
-rw-r--r--examples/widgets/doc/src/fontsampler.qdoc2
-rw-r--r--examples/widgets/doc/src/fridgemagnets.qdoc2
-rw-r--r--examples/widgets/doc/src/i18n.qdoc4
-rw-r--r--examples/widgets/doc/src/mdi.qdoc2
-rw-r--r--examples/widgets/doc/src/moveblocks.qdoc4
-rw-r--r--examples/widgets/doc/src/pixelator.qdoc2
-rw-r--r--examples/widgets/doc/src/recentfiles.qdoc2
-rw-r--r--examples/widgets/doc/src/regexp.qdoc2
-rw-r--r--examples/widgets/doc/src/rogue.qdoc4
-rw-r--r--examples/widgets/doc/src/sdi.qdoc2
-rw-r--r--examples/widgets/doc/src/settingseditor.qdoc2
-rw-r--r--examples/widgets/doc/src/simplewidgetmapper.qdoc2
-rw-r--r--examples/widgets/doc/src/spinboxes.qdoc2
-rw-r--r--examples/widgets/doc/src/standarddialogs.qdoc2
-rw-r--r--examples/widgets/doc/src/stardelegate.qdoc2
-rw-r--r--examples/widgets/doc/src/styleplugin.qdoc4
-rw-r--r--examples/widgets/doc/src/stylesheet.qdoc2
-rw-r--r--examples/widgets/doc/src/sub-attaq.qdoc2
-rw-r--r--examples/widgets/doc/src/tablet.qdoc46
-rw-r--r--examples/widgets/doc/src/tetrix.qdoc2
-rw-r--r--examples/widgets/doc/src/undo.qdoc2
-rw-r--r--examples/widgets/doc/src/undoframework.qdoc46
-rw-r--r--examples/widgets/draganddrop/draggableicons/dragwidget.cpp4
-rw-r--r--examples/widgets/draganddrop/dropsite/droparea.cpp4
-rw-r--r--examples/widgets/draganddrop/dropsite/dropsitewindow.cpp8
-rw-r--r--examples/widgets/graphicsview/boxes/scene.cpp2
-rw-r--r--examples/widgets/graphicsview/chip/main.cpp2
-rw-r--r--examples/widgets/graphicsview/chip/mainwindow.cpp2
-rw-r--r--examples/widgets/graphicsview/chip/mainwindow.h4
-rw-r--r--examples/widgets/graphicsview/chip/view.cpp2
-rw-r--r--examples/widgets/graphicsview/collidingmice/mouse.cpp2
-rw-r--r--examples/widgets/graphicsview/dragdroprobot/robot.cpp2
-rw-r--r--examples/widgets/graphicsview/dragdroprobot/robot.h2
-rw-r--r--examples/widgets/graphicsview/elasticnodes/edge.cpp2
-rw-r--r--examples/widgets/graphicsview/elasticnodes/edge.h4
-rw-r--r--examples/widgets/graphicsview/elasticnodes/node.h2
-rw-r--r--examples/widgets/graphicsview/embeddeddialogs/customproxy.cpp6
-rw-r--r--examples/widgets/graphicsview/embeddeddialogs/customproxy.h2
-rw-r--r--examples/widgets/itemviews/addressbook/adddialog.cpp16
-rw-r--r--examples/widgets/itemviews/addressbook/adddialog.h2
-rw-r--r--examples/widgets/itemviews/addressbook/addresswidget.cpp20
-rw-r--r--examples/widgets/itemviews/addressbook/mainwindow.cpp6
-rw-r--r--examples/widgets/itemviews/addressbook/newaddresstab.cpp12
-rw-r--r--examples/widgets/itemviews/addressbook/newaddresstab.h4
-rw-r--r--examples/widgets/itemviews/addressbook/tablemodel.h2
-rw-r--r--examples/widgets/itemviews/combowidgetmapper/window.cpp4
-rw-r--r--examples/widgets/itemviews/fetchmore/filelistmodel.cpp6
-rw-r--r--examples/widgets/itemviews/fetchmore/window.cpp2
-rw-r--r--examples/widgets/itemviews/pixelator/mainwindow.cpp4
-rw-r--r--examples/widgets/itemviews/simplewidgetmapper/window.cpp2
-rw-r--r--examples/widgets/itemviews/spreadsheet/spreadsheet.cpp2
-rw-r--r--examples/widgets/itemviews/spreadsheet/spreadsheet.h2
-rw-r--r--examples/widgets/painting/deform/pathdeform.cpp4
-rw-r--r--examples/widgets/painting/fontsampler/mainwindow.cpp2
-rw-r--r--examples/widgets/painting/fontsampler/mainwindow.h4
-rw-r--r--examples/widgets/painting/gradients/gradients.cpp2
-rw-r--r--examples/widgets/painting/pathstroke/pathstroke.cpp4
-rw-r--r--examples/widgets/painting/shared/shared.pri2
-rw-r--r--examples/widgets/richtext/orderform/mainwindow.cpp2
-rw-r--r--examples/widgets/richtext/textedit/textedit.cpp6
-rw-r--r--examples/widgets/richtext/textedit/textedit.qdoc4
-rw-r--r--examples/widgets/scroller/graphicsview/main.cpp2
-rw-r--r--examples/widgets/statemachine/factorial/main.cpp2
-rw-r--r--examples/widgets/statemachine/rogue/window.cpp8
-rw-r--r--examples/widgets/tools/completer/mainwindow.cpp2
-rw-r--r--examples/widgets/tools/customcompleter/doc/src/customcompleter.qdoc (renamed from examples/tools/doc/src/customcompleter.qdoc)40
-rw-r--r--examples/widgets/tools/customcompleter/mainwindow.cpp2
-rw-r--r--examples/widgets/tools/customcompleter/textedit.cpp6
-rw-r--r--examples/widgets/tools/i18n/languagechooser.cpp12
-rw-r--r--examples/widgets/tools/i18n/languagechooser.h3
-rw-r--r--examples/widgets/tools/i18n/main.cpp4
-rw-r--r--examples/widgets/tools/plugandpaint/mainwindow.cpp2
-rw-r--r--examples/widgets/tools/plugandpaint/plugindialog.cpp2
-rw-r--r--examples/widgets/tools/undoframework/diagramscene.cpp4
-rw-r--r--examples/widgets/tutorials/addressbook-fr/part1/addressbook.cpp2
-rw-r--r--examples/widgets/tutorials/addressbook-fr/part2/addressbook.cpp10
-rw-r--r--examples/widgets/tutorials/addressbook-fr/part3/addressbook.cpp16
-rw-r--r--examples/widgets/tutorials/addressbook-fr/part3/addressbook.h6
-rw-r--r--examples/widgets/tutorials/addressbook-fr/part4/addressbook.cpp24
-rw-r--r--examples/widgets/tutorials/addressbook-fr/part4/addressbook.h8
-rw-r--r--examples/widgets/tutorials/addressbook-fr/part5/addressbook.cpp22
-rw-r--r--examples/widgets/tutorials/addressbook-fr/part5/addressbook.h12
-rw-r--r--examples/widgets/tutorials/addressbook-fr/part6/addressbook.cpp24
-rw-r--r--examples/widgets/tutorials/addressbook-fr/part6/addressbook.h8
-rw-r--r--examples/widgets/tutorials/addressbook-fr/part7/addressbook.cpp24
-rw-r--r--examples/widgets/tutorials/addressbook-fr/part7/addressbook.h6
-rw-r--r--examples/widgets/tutorials/addressbook/part1/addressbook.cpp2
-rw-r--r--examples/widgets/tutorials/addressbook/part2/addressbook.cpp10
-rw-r--r--examples/widgets/tutorials/addressbook/part3/addressbook.cpp16
-rw-r--r--examples/widgets/tutorials/addressbook/part3/addressbook.h6
-rw-r--r--examples/widgets/tutorials/addressbook/part4/addressbook.cpp24
-rw-r--r--examples/widgets/tutorials/addressbook/part4/addressbook.h8
-rw-r--r--examples/widgets/tutorials/addressbook/part5/addressbook.cpp22
-rw-r--r--examples/widgets/tutorials/addressbook/part5/addressbook.h12
-rw-r--r--examples/widgets/tutorials/addressbook/part6/addressbook.cpp24
-rw-r--r--examples/widgets/tutorials/addressbook/part6/addressbook.h8
-rw-r--r--examples/widgets/tutorials/addressbook/part7/addressbook.cpp24
-rw-r--r--examples/widgets/tutorials/addressbook/part7/addressbook.h6
-rw-r--r--examples/widgets/tutorials/gettingStarted/gsQt/part3/main.cpp4
-rw-r--r--examples/widgets/tutorials/modelview/5_edit/mymodel.cpp2
-rw-r--r--examples/widgets/tutorials/modelview/7_selections/mainwindow.cpp2
-rw-r--r--examples/widgets/widgets.pro3
-rw-r--r--examples/widgets/widgets/calculator/button.cpp2
-rw-r--r--examples/widgets/widgets/codeeditor/codeeditor.cpp4
-rw-r--r--examples/widgets/widgets/imageviewer/imageviewer.cpp2
-rw-r--r--examples/widgets/widgets/lineedits/window.cpp5
-rw-r--r--examples/widgets/widgets/scribble/scribblearea.cpp4
-rw-r--r--examples/widgets/widgets/styles/widgetgallery.cpp2
-rw-r--r--examples/widgets/widgets/styles/widgetgallery.h2
-rw-r--r--examples/widgets/windowcontainer/windowcontainer.cpp170
-rw-r--r--examples/widgets/windowcontainer/windowcontainer.pro9
-rw-r--r--examples/xml/xml.pro4
-rw-r--r--mkspecs/aix-g++-64/qmake.conf105
-rw-r--r--mkspecs/aix-g++/qmake.conf109
-rw-r--r--mkspecs/aix-xlc-64/qmake.conf103
-rw-r--r--mkspecs/aix-xlc/qmake.conf109
-rw-r--r--mkspecs/android-g++/qmake.conf178
-rw-r--r--mkspecs/android-g++/qplatformdefs.h187
-rw-r--r--mkspecs/blackberry-armv7le-qcc/qmake.conf2
-rw-r--r--mkspecs/common/armcc.conf60
-rw-r--r--mkspecs/common/clang-mac.conf5
-rw-r--r--mkspecs/common/clang.conf36
-rw-r--r--mkspecs/common/g++-base.conf20
-rw-r--r--mkspecs/common/g++-unix.conf4
-rw-r--r--mkspecs/common/gcc-base-mac.conf (renamed from mkspecs/common/gcc-base-ios.conf)15
-rw-r--r--mkspecs/common/gcc-base-macx.conf34
-rw-r--r--mkspecs/common/gcc-base-unix.conf12
-rw-r--r--mkspecs/common/gcc-base.conf55
-rw-r--r--mkspecs/common/ios.conf17
-rw-r--r--mkspecs/common/ios/arch.conf84
-rw-r--r--mkspecs/common/ios/clang.conf48
-rw-r--r--mkspecs/common/ios/g++.conf21
-rw-r--r--mkspecs/common/ios/llvm.conf31
-rw-r--r--mkspecs/common/ios/qmake.conf61
-rw-r--r--mkspecs/common/ios/versions.conf184
-rw-r--r--mkspecs/common/linux-android.conf4
-rw-r--r--mkspecs/common/linux.conf89
-rw-r--r--mkspecs/common/llvm.conf14
-rw-r--r--mkspecs/common/mac-clang-libc++-minimum-version.conf5
-rw-r--r--mkspecs/common/mac-minimum-version.conf4
-rw-r--r--mkspecs/common/mac.conf38
-rw-r--r--mkspecs/common/mac/qplatformdefs.h6
-rw-r--r--mkspecs/common/macx.conf8
-rw-r--r--mkspecs/common/nacl/nacl-base.conf10
-rw-r--r--mkspecs/common/qcc-base-qnx.conf21
-rw-r--r--mkspecs/common/qcc-base.conf64
-rw-r--r--mkspecs/common/shell-unix.conf26
-rw-r--r--mkspecs/common/shell-win32.conf26
-rw-r--r--mkspecs/common/unix.conf12
-rw-r--r--mkspecs/common/wince/qmake.conf96
-rw-r--r--mkspecs/common/xcode.conf21
-rw-r--r--mkspecs/cygwin-g++/qmake.conf115
-rw-r--r--mkspecs/darwin-g++/qmake.conf117
-rw-r--r--mkspecs/devices/blackberry-playbook-armv7le-qcc/qmake.conf1
-rw-r--r--mkspecs/devices/blackberry-playbook-x86-qcc/qmake.conf1
-rw-r--r--mkspecs/devices/common/linux_device_pre.conf4
-rw-r--r--mkspecs/devices/linux-archos-gen8-g++/qmake.conf2
-rw-r--r--mkspecs/devices/linux-arm-amlogic-8726M-g++/qmake.conf4
-rw-r--r--mkspecs/devices/linux-arm-trident-pnx8473-g++/qmake.conf18
-rw-r--r--mkspecs/devices/linux-beagleboard-g++/qmake.conf2
-rw-r--r--mkspecs/devices/linux-imx53qsb-g++/qmake.conf37
-rw-r--r--mkspecs/devices/linux-imx53qsb-g++/qplatformdefs.h (renamed from mkspecs/unsupported/macx-iosdevice-clang-legacy/qplatformdefs.h)2
-rw-r--r--mkspecs/devices/linux-maemo-n9-g++/qmake.conf4
-rw-r--r--mkspecs/devices/linux-mipsel-broadcom-97425-g++/qmake.conf10
-rw-r--r--mkspecs/devices/linux-rasp-pi-g++/qmake.conf8
-rw-r--r--mkspecs/devices/linux-sh4-stmicro-ST7108-g++/qmake.conf4
-rw-r--r--mkspecs/devices/linux-sh4-stmicro-ST7540-g++/qmake.conf10
-rw-r--r--mkspecs/devices/linux-snowball-g++/qmake.conf8
-rw-r--r--mkspecs/devices/linux-tegra2-g++/qmake.conf20
-rw-r--r--mkspecs/features/android.prf14
-rw-r--r--mkspecs/features/c++11.prf7
-rw-r--r--mkspecs/features/cmake_functions.prf26
-rw-r--r--mkspecs/features/configure.prf3
-rw-r--r--mkspecs/features/create_cmake.prf26
-rw-r--r--mkspecs/features/ctest_testcase.prf39
-rw-r--r--mkspecs/features/data/android/dx.bat102
-rw-r--r--mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in22
-rw-r--r--mkspecs/features/default_post.prf8
-rw-r--r--mkspecs/features/exclusive_builds.prf38
-rw-r--r--mkspecs/features/ios/default_post.prf69
-rw-r--r--mkspecs/features/ios/default_pre.prf4
-rw-r--r--mkspecs/features/java.prf65
-rw-r--r--mkspecs/features/mac/default_post.prf6
-rw-r--r--mkspecs/features/mac/sdk.prf64
-rw-r--r--mkspecs/features/moc.prf18
-rw-r--r--mkspecs/features/qml_plugin.prf24
-rw-r--r--mkspecs/features/qmltestcase.prf2
-rw-r--r--mkspecs/features/qpa/basicunixfontdatabase.prf2
-rw-r--r--mkspecs/features/qpa/genericunixfontdatabase.prf2
-rw-r--r--mkspecs/features/qt_android_deps.prf53
-rw-r--r--mkspecs/features/qt_build_config.prf3
-rw-r--r--mkspecs/features/qt_common.prf54
-rw-r--r--mkspecs/features/qt_docs.prf4
-rw-r--r--mkspecs/features/qt_module.prf23
-rw-r--r--mkspecs/features/qt_module_headers.prf14
-rw-r--r--mkspecs/features/qt_module_pris.prf2
-rw-r--r--mkspecs/features/qt_plugin.prf5
-rw-r--r--mkspecs/features/qt_tool.prf15
-rw-r--r--mkspecs/features/resolve_target.prf2
-rw-r--r--mkspecs/features/testcase.prf2
-rw-r--r--mkspecs/features/unix/opengl.prf2
-rw-r--r--mkspecs/features/unix/separate_debug_info.prf13
-rw-r--r--mkspecs/features/win32/opengl.prf1
-rw-r--r--mkspecs/freebsd-g++/qmake.conf45
-rw-r--r--mkspecs/freebsd-g++46/qmake.conf57
-rw-r--r--mkspecs/freebsd-icc/qmake.conf103
-rw-r--r--mkspecs/hpux-acc-64/qmake.conf179
-rw-r--r--mkspecs/hpux-acc-o64/qmake.conf173
-rw-r--r--mkspecs/hpux-acc/qmake.conf141
-rw-r--r--mkspecs/hpux-g++-64/qmake.conf115
-rw-r--r--mkspecs/hpux-g++/qmake.conf117
-rw-r--r--mkspecs/hpuxi-acc-32/qmake.conf107
-rw-r--r--mkspecs/hpuxi-acc-64/qmake.conf177
-rw-r--r--mkspecs/hpuxi-g++-64/qmake.conf117
-rw-r--r--mkspecs/hurd-g++/qmake.conf73
-rw-r--r--mkspecs/irix-cc-64/qmake.conf169
-rw-r--r--mkspecs/irix-cc/qmake.conf169
-rw-r--r--mkspecs/irix-g++-64/qmake.conf113
-rw-r--r--mkspecs/irix-g++/qmake.conf113
-rw-r--r--mkspecs/linux-arm-gnueabi-g++/qmake.conf2
-rw-r--r--mkspecs/linux-cxx/qmake.conf95
-rw-r--r--mkspecs/linux-g++-32/qmake.conf8
-rw-r--r--mkspecs/linux-g++-64/qmake.conf12
-rw-r--r--mkspecs/linux-g++/qmake.conf4
-rw-r--r--mkspecs/linux-icc-64/qmake.conf4
-rw-r--r--mkspecs/linux-icc/qmake.conf127
-rw-r--r--mkspecs/linux-kcc/qmake.conf115
-rw-r--r--mkspecs/linux-llvm/qmake.conf4
-rw-r--r--mkspecs/linux-lsb-g++/qmake.conf4
-rw-r--r--mkspecs/linux-pgcc/qmake.conf105
-rw-r--r--mkspecs/lynxos-g++/qmake.conf113
-rw-r--r--mkspecs/macx-clang-32/qmake.conf17
-rw-r--r--mkspecs/macx-clang-libc++-32/qmake.conf17
-rw-r--r--mkspecs/macx-clang-libc++/qmake.conf15
-rw-r--r--mkspecs/macx-clang/qmake.conf11
-rw-r--r--mkspecs/macx-g++-32/qmake.conf17
-rw-r--r--mkspecs/macx-g++/qmake.conf11
-rw-r--r--mkspecs/macx-g++40/qmake.conf23
-rw-r--r--mkspecs/macx-g++42/qmake.conf23
-rw-r--r--mkspecs/macx-icc/qmake.conf86
-rw-r--r--mkspecs/macx-llvm/qmake.conf13
-rw-r--r--mkspecs/macx-xcode/qmake.conf15
-rw-r--r--mkspecs/netbsd-g++/qmake.conf111
-rw-r--r--mkspecs/openbsd-g++/qmake.conf115
-rw-r--r--mkspecs/sco-cc/qmake.conf91
-rw-r--r--mkspecs/sco-g++/qmake.conf99
-rw-r--r--mkspecs/solaris-cc-64-stlport/qmake.conf4
-rw-r--r--mkspecs/solaris-cc-64/qmake.conf133
-rw-r--r--mkspecs/solaris-cc-stlport/qmake.conf4
-rw-r--r--mkspecs/solaris-cc/qmake.conf109
-rw-r--r--mkspecs/solaris-g++-64/qmake.conf135
-rw-r--r--mkspecs/solaris-g++/qmake.conf111
-rw-r--r--mkspecs/tru64-cxx/qmake.conf105
-rw-r--r--mkspecs/tru64-g++/qmake.conf109
-rw-r--r--mkspecs/unixware-cc/qmake.conf101
-rw-r--r--mkspecs/unixware-g++/qmake.conf107
-rw-r--r--mkspecs/unsupported/android-g++/qeglfshooks_surfaceflinger.cpp120
-rw-r--r--mkspecs/unsupported/android-g++/qmake.conf47
-rw-r--r--mkspecs/unsupported/integrity-ghs/qmake.conf72
-rw-r--r--mkspecs/unsupported/linux-android-armeabi-g++/qmake.conf14
-rw-r--r--mkspecs/unsupported/linux-android-armeabi-v7a-g++/qmake.conf14
-rw-r--r--mkspecs/unsupported/linux-android-x86-g++/qmake.conf14
-rw-r--r--mkspecs/unsupported/linux-armcc/qmake.conf22
-rw-r--r--mkspecs/unsupported/linux-host-g++/qmake.conf121
-rw-r--r--mkspecs/unsupported/linux-scratchbox2-g++/qmake.conf4
-rwxr-xr-xmkspecs/unsupported/macx-ios-clang/Info.plist.app28
-rw-r--r--mkspecs/unsupported/macx-ios-clang/Info.plist.lib18
-rw-r--r--mkspecs/unsupported/macx-ios-clang/qmake.conf27
-rw-r--r--mkspecs/unsupported/macx-ios-clang/qplatformdefs.h (renamed from mkspecs/unsupported/macx-iosdevice-clang/qplatformdefs.h)2
-rw-r--r--mkspecs/unsupported/macx-iosdevice-clang-legacy/qmake.conf35
-rw-r--r--mkspecs/unsupported/macx-iosdevice-clang/qmake.conf35
-rw-r--r--mkspecs/unsupported/macx-iosdevice-g++-legacy/qmake.conf35
-rw-r--r--mkspecs/unsupported/macx-iosdevice-g++/qmake.conf35
-rw-r--r--mkspecs/unsupported/macx-iosdevice-g++/qplatformdefs.h42
-rw-r--r--mkspecs/unsupported/macx-iosdevice-llvm-legacy/qmake.conf35
-rw-r--r--mkspecs/unsupported/macx-iosdevice-llvm-legacy/qplatformdefs.h42
-rw-r--r--mkspecs/unsupported/macx-iosdevice-llvm/qmake.conf35
-rw-r--r--mkspecs/unsupported/macx-iosdevice-llvm/qplatformdefs.h42
-rw-r--r--mkspecs/unsupported/macx-iossimulator-clang-legacy/qmake.conf6
-rw-r--r--mkspecs/unsupported/macx-iossimulator-clang-legacy/qplatformdefs.h42
-rw-r--r--mkspecs/unsupported/macx-iossimulator-clang/qmake.conf6
-rw-r--r--mkspecs/unsupported/macx-iossimulator-clang/qplatformdefs.h42
-rw-r--r--mkspecs/unsupported/macx-iossimulator-g++-legacy/qmake.conf33
-rw-r--r--mkspecs/unsupported/macx-iossimulator-g++-legacy/qplatformdefs.h42
-rw-r--r--mkspecs/unsupported/macx-iossimulator-g++/qmake.conf33
-rw-r--r--mkspecs/unsupported/macx-iossimulator-g++/qplatformdefs.h42
-rw-r--r--mkspecs/unsupported/macx-iossimulator-llvm-legacy/qmake.conf33
-rw-r--r--mkspecs/unsupported/macx-iossimulator-llvm-legacy/qplatformdefs.h42
-rw-r--r--mkspecs/unsupported/macx-iossimulator-llvm/qmake.conf33
-rw-r--r--mkspecs/unsupported/macx-iossimulator-llvm/qplatformdefs.h42
-rw-r--r--mkspecs/unsupported/qnx-X11-g++/qmake.conf47
-rw-r--r--mkspecs/unsupported/vxworks-ppc-dcc/qmake.conf139
-rw-r--r--mkspecs/unsupported/vxworks-ppc-g++/qmake.conf44
-rw-r--r--mkspecs/unsupported/vxworks-simpentium-dcc/qmake.conf125
-rw-r--r--mkspecs/unsupported/vxworks-simpentium-g++/qmake.conf46
-rw-r--r--mkspecs/unsupported/win32-msvc2003/qmake.conf10
-rw-r--r--mkspecs/win32-g++/qmake.conf98
-rw-r--r--mkspecs/win32-g++/qplatformdefs.h20
-rw-r--r--mkspecs/win32-icc/qmake.conf95
-rw-r--r--mkspecs/win32-msvc2005/qmake.conf10
-rw-r--r--mkspecs/win32-msvc2008/qmake.conf10
-rw-r--r--mkspecs/win32-msvc2010/qmake.conf10
-rw-r--r--mkspecs/win32-msvc2012/qmake.conf10
-rw-r--r--mkspecs/wince50standard-armv4i-msvc2005/qmake.conf6
-rw-r--r--mkspecs/wince50standard-mipsii-msvc2005/qmake.conf10
-rw-r--r--mkspecs/wince50standard-mipsiv-msvc2005/qmake.conf6
-rw-r--r--mkspecs/wince50standard-sh4-msvc2005/qmake.conf6
-rw-r--r--mkspecs/wince50standard-x86-msvc2005/qmake.conf8
-rw-r--r--mkspecs/wince60standard-armv4i-msvc2005/qmake.conf18
-rw-r--r--mkspecs/wince60standard-x86-msvc2005/qmake.conf8
-rw-r--r--mkspecs/wince70embedded-armv4i-msvc2008/qmake.conf7
-rw-r--r--mkspecs/wince70embedded-x86-msvc2008/qmake.conf2
-rw-r--r--mkspecs/wincewm50pocket-msvc2005/qmake.conf6
-rw-r--r--mkspecs/wincewm50smart-msvc2005/qmake.conf8
-rw-r--r--mkspecs/wincewm60professional-msvc2005/qmake.conf12
-rw-r--r--mkspecs/wincewm60standard-msvc2005/qmake.conf16
-rw-r--r--mkspecs/wincewm65professional-msvc2005/qmake.conf4
-rw-r--r--qmake/Makefile.unix78
-rw-r--r--qmake/Makefile.win326
-rw-r--r--qmake/Makefile.win32-g++160
-rw-r--r--qmake/generators/mac/pbuilder_pbx.cpp648
-rw-r--r--qmake/generators/makefile.cpp18
-rw-r--r--qmake/generators/makefile.h2
-rw-r--r--qmake/generators/makefiledeps.cpp10
-rw-r--r--qmake/generators/unix/unixmake.cpp23
-rw-r--r--qmake/generators/unix/unixmake2.cpp29
-rw-r--r--qmake/generators/win32/mingw_make.cpp12
-rw-r--r--qmake/generators/win32/mingw_make.h2
-rw-r--r--qmake/generators/win32/msvc_nmake.cpp15
-rw-r--r--qmake/generators/win32/msvc_vcproj.cpp10
-rw-r--r--qmake/generators/win32/winmakefile.cpp4
-rw-r--r--qmake/library/qmakebuiltins.cpp5
-rw-r--r--qmake/library/qmakeevaluator.cpp73
-rw-r--r--qmake/library/qmakeevaluator_p.h1
-rw-r--r--qmake/library/qmakeglobals.cpp1
-rw-r--r--qmake/library/qmakeparser.cpp29
-rw-r--r--qmake/main.cpp5
-rw-r--r--qmake/option.cpp3
-rw-r--r--qmake/option.h1
-rw-r--r--qmake/qmake.pri1
-rw-r--r--src/3rdparty/angle/.gitignore21
-rw-r--r--src/3rdparty/angle/include/GLES2/gl2ext.h46
-rw-r--r--src/3rdparty/angle/include/GLSLANG/ShaderLang.h103
-rw-r--r--src/3rdparty/angle/include/KHR/khrplatform.h3
-rw-r--r--src/3rdparty/angle/src/common/angleutils.h28
-rw-r--r--src/3rdparty/angle/src/common/debug.cpp15
-rw-r--r--src/3rdparty/angle/src/common/debug.h7
-rw-r--r--src/3rdparty/angle/src/common/system.h26
-rw-r--r--src/3rdparty/angle/src/common/version.h6
-rw-r--r--src/3rdparty/angle/src/compiler/BaseTypes.h6
-rw-r--r--src/3rdparty/angle/src/compiler/CodeGenHLSL.cpp10
-rw-r--r--src/3rdparty/angle/src/compiler/Compiler.cpp43
-rw-r--r--src/3rdparty/angle/src/compiler/ConstantUnion.h3
-rw-r--r--src/3rdparty/angle/src/compiler/DetectDiscontinuity.cpp22
-rw-r--r--src/3rdparty/angle/src/compiler/DetectDiscontinuity.h2
-rw-r--r--src/3rdparty/angle/src/compiler/Diagnostics.cpp2
-rw-r--r--src/3rdparty/angle/src/compiler/Diagnostics.h2
-rw-r--r--src/3rdparty/angle/src/compiler/DirectiveHandler.h2
-rw-r--r--src/3rdparty/angle/src/compiler/ExtensionBehavior.h2
-rw-r--r--src/3rdparty/angle/src/compiler/ForLoopUnroll.cpp4
-rw-r--r--src/3rdparty/angle/src/compiler/HashNames.h19
-rw-r--r--src/3rdparty/angle/src/compiler/Initialize.cpp2
-rw-r--r--src/3rdparty/angle/src/compiler/Intermediate.cpp40
-rw-r--r--src/3rdparty/angle/src/compiler/MapLongVariableNames.cpp6
-rw-r--r--src/3rdparty/angle/src/compiler/MapLongVariableNames.h2
-rw-r--r--src/3rdparty/angle/src/compiler/OutputESSL.cpp8
-rw-r--r--src/3rdparty/angle/src/compiler/OutputESSL.h6
-rw-r--r--src/3rdparty/angle/src/compiler/OutputGLSL.cpp8
-rw-r--r--src/3rdparty/angle/src/compiler/OutputGLSL.h6
-rw-r--r--src/3rdparty/angle/src/compiler/OutputGLSLBase.cpp168
-rw-r--r--src/3rdparty/angle/src/compiler/OutputGLSLBase.h25
-rw-r--r--src/3rdparty/angle/src/compiler/OutputHLSL.cpp1304
-rw-r--r--src/3rdparty/angle/src/compiler/OutputHLSL.h35
-rw-r--r--src/3rdparty/angle/src/compiler/ParseHelper.cpp17
-rw-r--r--src/3rdparty/angle/src/compiler/ParseHelper.h5
-rw-r--r--src/3rdparty/angle/src/compiler/ShHandle.h23
-rw-r--r--src/3rdparty/angle/src/compiler/ShaderLang.cpp113
-rw-r--r--src/3rdparty/angle/src/compiler/SymbolTable.h16
-rw-r--r--src/3rdparty/angle/src/compiler/TranslatorESSL.cpp5
-rw-r--r--src/3rdparty/angle/src/compiler/TranslatorGLSL.cpp5
-rw-r--r--src/3rdparty/angle/src/compiler/TranslatorHLSL.cpp9
-rw-r--r--src/3rdparty/angle/src/compiler/TranslatorHLSL.h11
-rw-r--r--src/3rdparty/angle/src/compiler/Types.h37
-rw-r--r--src/3rdparty/angle/src/compiler/UnfoldShortCircuit.cpp10
-rw-r--r--src/3rdparty/angle/src/compiler/Uniform.cpp21
-rw-r--r--src/3rdparty/angle/src/compiler/Uniform.h35
-rw-r--r--src/3rdparty/angle/src/compiler/ValidateLimitations.cpp2
-rw-r--r--src/3rdparty/angle/src/compiler/VariableInfo.cpp34
-rw-r--r--src/3rdparty/angle/src/compiler/VariableInfo.h5
-rw-r--r--src/3rdparty/angle/src/compiler/VariablePacker.cpp2
-rw-r--r--src/3rdparty/angle/src/compiler/glslang.h2
-rw-r--r--src/3rdparty/angle/src/compiler/glslang.l170
-rw-r--r--src/3rdparty/angle/src/compiler/glslang.y41
-rw-r--r--src/3rdparty/angle/src/compiler/intermOut.cpp2
-rw-r--r--src/3rdparty/angle/src/compiler/intermediate.h29
-rw-r--r--src/3rdparty/angle/src/compiler/osinclude.h21
-rw-r--r--src/3rdparty/angle/src/compiler/ossource_nspr.cpp43
-rw-r--r--src/3rdparty/angle/src/compiler/parseConst.cpp7
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/DiagnosticsBase.cpp (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Diagnostics.cpp)2
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/DiagnosticsBase.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Diagnostics.h)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/DirectiveHandlerBase.cpp (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/DirectiveHandler.cpp)2
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/DirectiveHandlerBase.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/DirectiveHandler.h)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/DirectiveParser.cpp (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/DirectiveParser.cpp)4
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/DirectiveParser.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/DirectiveParser.h)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/ExpressionParser.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/ExpressionParser.h)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/ExpressionParser.y (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/ExpressionParser.y)8
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/Input.cpp (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Input.cpp)15
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/Input.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Input.h)19
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/Lexer.cpp (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Lexer.cpp)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/Lexer.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Lexer.h)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/Macro.cpp (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Macro.cpp)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/Macro.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Macro.h)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/MacroExpander.cpp (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/MacroExpander.cpp)14
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/MacroExpander.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/MacroExpander.h)2
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/Preprocessor.cpp (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Preprocessor.cpp)4
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/Preprocessor.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Preprocessor.h)4
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/SourceLocation.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/SourceLocation.h)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/Token.cpp (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Token.cpp)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/Token.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Token.h)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/Tokenizer.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Tokenizer.h)4
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/Tokenizer.l (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/Tokenizer.l)16
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/atom.c737
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/atom.h63
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/compile.h100
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/cpp.c1118
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/cpp.h86
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/cppstruct.c152
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/memory.c158
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/memory.h58
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/numeric_lex.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/numeric_lex.h)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/parser.h93
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/pp_utils.h (renamed from src/3rdparty/angle/src/compiler/preprocessor/new/pp_utils.h)0
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/preprocess.h50
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/scanner.c698
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/scanner.h81
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/slglobals.h82
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/symbols.c288
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/symbols.h111
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/tokens.c467
-rw-r--r--src/3rdparty/angle/src/compiler/preprocessor/tokens.h90
-rw-r--r--src/3rdparty/angle/src/libEGL/Config.cpp117
-rw-r--r--src/3rdparty/angle/src/libEGL/Config.h15
-rw-r--r--src/3rdparty/angle/src/libEGL/Display.cpp874
-rw-r--r--src/3rdparty/angle/src/libEGL/Display.h94
-rw-r--r--src/3rdparty/angle/src/libEGL/Surface.cpp433
-rw-r--r--src/3rdparty/angle/src/libEGL/Surface.h34
-rw-r--r--src/3rdparty/angle/src/libEGL/libEGL.cpp258
-rw-r--r--src/3rdparty/angle/src/libEGL/main.cpp61
-rw-r--r--src/3rdparty/angle/src/libEGL/main.h3
-rw-r--r--src/3rdparty/angle/src/libGLESv2/BinaryStream.h3
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Buffer.cpp72
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Buffer.h42
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Context.cpp2769
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Context.h248
-rw-r--r--src/3rdparty/angle/src/libGLESv2/D3DConstantTable.cpp231
-rw-r--r--src/3rdparty/angle/src/libGLESv2/D3DConstantTable.h117
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Fence.cpp104
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Fence.h18
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.cpp1
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.py8
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Framebuffer.cpp361
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Framebuffer.h69
-rw-r--r--src/3rdparty/angle/src/libGLESv2/HandleAllocator.cpp1
-rw-r--r--src/3rdparty/angle/src/libGLESv2/IndexDataManager.cpp473
-rw-r--r--src/3rdparty/angle/src/libGLESv2/IndexDataManager.h149
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Program.cpp27
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Program.h15
-rw-r--r--src/3rdparty/angle/src/libGLESv2/ProgramBinary.cpp1774
-rw-r--r--src/3rdparty/angle/src/libGLESv2/ProgramBinary.h145
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Query.cpp98
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Query.h17
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Renderbuffer.cpp230
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Renderbuffer.h64
-rw-r--r--src/3rdparty/angle/src/libGLESv2/ResourceManager.cpp18
-rw-r--r--src/3rdparty/angle/src/libGLESv2/ResourceManager.h24
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Shader.cpp79
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Shader.h26
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Texture.cpp2301
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Texture.h242
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Uniform.cpp43
-rw-r--r--src/3rdparty/angle/src/libGLESv2/Uniform.h48
-rw-r--r--src/3rdparty/angle/src/libGLESv2/VertexDataManager.cpp783
-rw-r--r--src/3rdparty/angle/src/libGLESv2/VertexDataManager.h169
-rw-r--r--src/3rdparty/angle/src/libGLESv2/angletypes.h128
-rw-r--r--src/3rdparty/angle/src/libGLESv2/constants.h34
-rw-r--r--src/3rdparty/angle/src/libGLESv2/libGLESv2.cpp1390
-rw-r--r--src/3rdparty/angle/src/libGLESv2/libGLESv2.def3
-rw-r--r--src/3rdparty/angle/src/libGLESv2/libGLESv2d.def2
-rw-r--r--src/3rdparty/angle/src/libGLESv2/main.cpp65
-rw-r--r--src/3rdparty/angle/src/libGLESv2/main.h40
-rw-r--r--src/3rdparty/angle/src/libGLESv2/mathutil.h22
-rw-r--r--src/3rdparty/angle/src/libGLESv2/precompiled.cpp9
-rw-r--r--src/3rdparty/angle/src/libGLESv2/precompiled.h45
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Blit.cpp (renamed from src/3rdparty/angle/src/libGLESv2/Blit.cpp)163
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Blit.h (renamed from src/3rdparty/angle/src/libGLESv2/Blit.h)28
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage.cpp40
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage.h44
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.cpp352
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.h56
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.cpp76
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.h42
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Fence11.cpp134
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Fence11.h39
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Fence9.cpp135
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Fence9.h39
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/FenceImpl.h45
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Image.cpp548
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Image.h131
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Image11.cpp457
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Image11.h76
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Image9.cpp736
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Image9.h79
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/ImageSSE2.cpp (renamed from src/3rdparty/angle/src/libGLESv2/TextureSSE2.cpp)18
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer.cpp202
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer.h137
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer11.cpp182
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer11.h53
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer9.cpp207
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer9.h53
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/IndexDataManager.cpp316
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/IndexDataManager.h66
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/InputLayoutCache.cpp166
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/InputLayoutCache.h74
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Query11.cpp122
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Query11.h40
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Query9.cpp125
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Query9.h40
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/QueryImpl.h42
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/RenderStateCache.cpp406
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/RenderStateCache.h101
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget.h56
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget11.cpp378
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget11.h58
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget9.cpp113
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget9.h40
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Renderer.cpp201
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Renderer.h238
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Renderer11.cpp3531
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Renderer11.h348
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Renderer9.cpp3211
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/Renderer9.h347
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/ShaderCache.h (renamed from src/3rdparty/angle/src/libEGL/ShaderCache.h)20
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable.h51
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable11.cpp109
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable11.h47
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable9.cpp60
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable9.h39
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/SwapChain.h44
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.cpp770
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.h78
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.cpp449
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.h55
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage.cpp122
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage.h110
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage11.cpp676
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage11.h120
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage9.cpp328
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage9.h109
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer.cpp229
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer.h138
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer11.cpp418
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer11.h73
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer9.cpp486
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer9.h90
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/VertexDataManager.cpp258
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/VertexDataManager.h65
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/VertexDeclarationCache.cpp217
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/VertexDeclarationCache.h58
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/generatemip.h203
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/renderer11_utils.cpp688
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/renderer11_utils.h95
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/renderer9_utils.cpp500
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/renderer9_utils.h74
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/shaders/Blit.ps (renamed from src/3rdparty/angle/src/libGLESv2/shaders/Blit.ps)0
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/shaders/Blit.vs (renamed from src/3rdparty/angle/src/libGLESv2/shaders/Blit.vs)0
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/shaders/Clear11.hlsl33
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/shaders/Passthrough11.hlsl29
-rw-r--r--src/3rdparty/angle/src/libGLESv2/renderer/vertexconversion.h (renamed from src/3rdparty/angle/src/libGLESv2/vertexconversion.h)7
-rw-r--r--src/3rdparty/angle/src/libGLESv2/utilities.cpp674
-rw-r--r--src/3rdparty/angle/src/libGLESv2/utilities.h75
-rw-r--r--src/3rdparty/angle/src/third_party/compiler/ArrayBoundsClamper.cpp106
-rw-r--r--src/3rdparty/angle/src/third_party/compiler/ArrayBoundsClamper.h62
-rw-r--r--src/3rdparty/angle/src/third_party/compiler/LICENSE22
-rw-r--r--src/3rdparty/angle/src/third_party/compiler/README.angle12
-rw-r--r--src/3rdparty/angle/src/third_party/murmurhash/LICENSE2
-rw-r--r--src/3rdparty/angle/src/third_party/murmurhash/MurmurHash3.cpp334
-rw-r--r--src/3rdparty/angle/src/third_party/murmurhash/MurmurHash3.h37
-rw-r--r--src/3rdparty/freetype/ChangeLog3004
-rw-r--r--src/3rdparty/freetype/Jamfile2
-rw-r--r--src/3rdparty/freetype/README12
-rw-r--r--src/3rdparty/freetype/README.git (renamed from src/3rdparty/freetype/README.CVS)4
-rw-r--r--src/3rdparty/freetype/autogen.sh7
-rw-r--r--src/3rdparty/freetype/builds/atari/ATARI.H4
-rw-r--r--src/3rdparty/freetype/builds/atari/deflinejoiner.awk181
-rw-r--r--src/3rdparty/freetype/builds/atari/gen-purec-patch.sh40
-rw-r--r--src/3rdparty/freetype/builds/compiler/bcc-dev.mk12
-rw-r--r--src/3rdparty/freetype/builds/compiler/bcc.mk12
-rw-r--r--src/3rdparty/freetype/builds/compiler/gcc.mk4
-rw-r--r--src/3rdparty/freetype/builds/exports.mk4
-rw-r--r--src/3rdparty/freetype/builds/mac/README4
-rw-r--r--src/3rdparty/freetype/builds/toplevel.mk10
-rw-r--r--src/3rdparty/freetype/builds/unix/aclocal.m415
-rwxr-xr-xsrc/3rdparty/freetype/builds/unix/config.guess211
-rwxr-xr-xsrc/3rdparty/freetype/builds/unix/config.sub59
-rwxr-xr-xsrc/3rdparty/freetype/builds/unix/configure131
-rw-r--r--src/3rdparty/freetype/builds/unix/configure.ac75
-rw-r--r--src/3rdparty/freetype/builds/unix/configure.raw73
-rw-r--r--src/3rdparty/freetype/builds/unix/freetype-config.in22
-rw-r--r--src/3rdparty/freetype/builds/unix/freetype2.m48
-rw-r--r--src/3rdparty/freetype/builds/unix/ftconfig.h7
-rw-r--r--src/3rdparty/freetype/builds/unix/ftconfig.in2
-rw-r--r--src/3rdparty/freetype/builds/unix/ftsystem.c9
-rwxr-xr-xsrc/3rdparty/freetype/builds/unix/install-sh5
-rwxr-xr-xsrc/3rdparty/freetype/builds/unix/ltmain.sh16
-rw-r--r--src/3rdparty/freetype/builds/win32/ftdebug.c40
-rw-r--r--src/3rdparty/freetype/builds/win32/vc2005/freetype.sln2
-rw-r--r--src/3rdparty/freetype/builds/win32/vc2005/freetype.vcproj20
-rw-r--r--src/3rdparty/freetype/builds/win32/vc2005/index.html10
-rw-r--r--src/3rdparty/freetype/builds/win32/vc2008/freetype.vcproj28
-rw-r--r--src/3rdparty/freetype/builds/win32/vc2008/index.html10
-rw-r--r--src/3rdparty/freetype/builds/win32/visualc/freetype.dsp20
-rw-r--r--src/3rdparty/freetype/builds/win32/visualc/index.html10
-rw-r--r--src/3rdparty/freetype/builds/win32/visualce/freetype.dsp400
-rw-r--r--src/3rdparty/freetype/builds/win32/visualce/freetype.dsw29
-rw-r--r--src/3rdparty/freetype/builds/win32/visualce/index.html47
-rw-r--r--src/3rdparty/freetype/builds/win32/win32-def.mk1
-rw-r--r--src/3rdparty/freetype/builds/wince/ftdebug.c20
-rw-r--r--src/3rdparty/freetype/builds/wince/vc2005-ce/freetype.vcproj90
-rw-r--r--src/3rdparty/freetype/builds/wince/vc2005-ce/index.html10
-rw-r--r--src/3rdparty/freetype/builds/wince/vc2008-ce/freetype.vcproj104
-rw-r--r--src/3rdparty/freetype/builds/wince/vc2008-ce/index.html10
-rwxr-xr-xsrc/3rdparty/freetype/configure24
-rw-r--r--src/3rdparty/freetype/devel/ftoption.h50
-rw-r--r--src/3rdparty/freetype/docs/CHANGES79
-rw-r--r--src/3rdparty/freetype/docs/DEBUG7
-rw-r--r--src/3rdparty/freetype/docs/INSTALL.ANY10
-rw-r--r--src/3rdparty/freetype/docs/LICENSE.TXT9
-rw-r--r--src/3rdparty/freetype/docs/VERSION.DLL5
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-base_interface.html162
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-basic_types.html229
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-bdf_fonts.html12
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-bitmap_handling.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-cache_subsystem.html76
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-cid_fonts.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-computations.html44
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-font_formats.html5
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-gasp_table.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-glyph_management.html30
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-glyph_stroker.html14
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-glyph_variants.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-gx_validation.html12
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-gzip.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-header_file_macros.html214
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-incremental.html42
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-index.html494
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-lcd_filtering.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-list_processing.html20
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-lzw.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-mac_specific.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-module_management.html5
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-multiple_masters.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-ot_validation.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-outline_processing.html37
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-pfr_fonts.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-quick_advance.html12
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-raster.html16
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-sfnt_names.html50
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-sizes_management.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-system_interface.html20
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-toc.html6
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-truetype_engine.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-truetype_tables.html12
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-type1_tables.html60
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-user_allocation.html4
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-version.html6
-rw-r--r--src/3rdparty/freetype/docs/reference/ft2-winfnt_fonts.html12
-rw-r--r--src/3rdparty/freetype/docs/release89
-rw-r--r--src/3rdparty/freetype/include/freetype/config/ftconfig.h36
-rw-r--r--src/3rdparty/freetype/include/freetype/config/ftoption.h33
-rw-r--r--src/3rdparty/freetype/include/freetype/config/ftstdlib.h1
-rw-r--r--src/3rdparty/freetype/include/freetype/freetype.h35
-rw-r--r--src/3rdparty/freetype/include/freetype/ftbbox.h2
-rw-r--r--src/3rdparty/freetype/include/freetype/ftglyph.h6
-rw-r--r--src/3rdparty/freetype/include/freetype/ftimage.h117
-rw-r--r--src/3rdparty/freetype/include/freetype/ftincrem.h8
-rw-r--r--src/3rdparty/freetype/include/freetype/ftmodapi.h6
-rw-r--r--src/3rdparty/freetype/include/freetype/ftoutln.h11
-rw-r--r--src/3rdparty/freetype/include/freetype/ftsnames.h34
-rw-r--r--src/3rdparty/freetype/include/freetype/ftstroke.h12
-rw-r--r--src/3rdparty/freetype/include/freetype/fttypes.h3
-rw-r--r--src/3rdparty/freetype/include/freetype/ftwinfnt.h2
-rw-r--r--src/3rdparty/freetype/include/freetype/ftxf86.h3
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/autohint.h26
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/ftcalc.h3
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/ftdriver.h173
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/ftgloadr.h18
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/ftobjs.h526
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/ftpic.h67
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/ftserv.h292
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/fttrace.h5
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/internal.h1
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/psaux.h13
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/pshints.h47
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/services/svbdf.h20
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/services/svcid.h25
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/services/svgldict.h22
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/services/svmm.h25
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/services/svpostnm.h21
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/services/svpscmap.h37
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/services/svpsinfo.h27
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/services/svsfnt.h22
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/services/svttcmap.h23
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/services/svttglyf.h19
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/sfnt.h135
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/t1types.h6
-rw-r--r--src/3rdparty/freetype/include/freetype/internal/tttypes.h4
-rw-r--r--src/3rdparty/freetype/src/autofit/Jamfile6
-rw-r--r--src/3rdparty/freetype/src/autofit/afcjk.c71
-rw-r--r--src/3rdparty/freetype/src/autofit/afcjk.h3
-rw-r--r--src/3rdparty/freetype/src/autofit/afdummy.c6
-rw-r--r--src/3rdparty/freetype/src/autofit/afdummy.h3
-rw-r--r--src/3rdparty/freetype/src/autofit/afglobal.c63
-rw-r--r--src/3rdparty/freetype/src/autofit/afglobal.h8
-rw-r--r--src/3rdparty/freetype/src/autofit/afhints.c11
-rw-r--r--src/3rdparty/freetype/src/autofit/afindic.c18
-rw-r--r--src/3rdparty/freetype/src/autofit/afindic.h3
-rw-r--r--src/3rdparty/freetype/src/autofit/aflatin.c126
-rw-r--r--src/3rdparty/freetype/src/autofit/aflatin.h9
-rw-r--r--src/3rdparty/freetype/src/autofit/aflatin2.c142
-rw-r--r--src/3rdparty/freetype/src/autofit/aflatin2.h3
-rw-r--r--src/3rdparty/freetype/src/autofit/afloader.c38
-rw-r--r--src/3rdparty/freetype/src/autofit/afmodule.c15
-rw-r--r--src/3rdparty/freetype/src/autofit/afmodule.h4
-rw-r--r--src/3rdparty/freetype/src/autofit/afpic.c92
-rw-r--r--src/3rdparty/freetype/src/autofit/afpic.h64
-rw-r--r--src/3rdparty/freetype/src/autofit/aftypes.h55
-rw-r--r--src/3rdparty/freetype/src/autofit/autofit.c1
-rw-r--r--src/3rdparty/freetype/src/base/Jamfile3
-rw-r--r--src/3rdparty/freetype/src/base/basepic.c83
-rw-r--r--src/3rdparty/freetype/src/base/basepic.h62
-rw-r--r--src/3rdparty/freetype/src/base/ftadvanc.c2
-rw-r--r--src/3rdparty/freetype/src/base/ftbase.c6
-rw-r--r--src/3rdparty/freetype/src/base/ftbase.h6
-rw-r--r--src/3rdparty/freetype/src/base/ftbbox.c27
-rw-r--r--src/3rdparty/freetype/src/base/ftbitmap.c8
-rw-r--r--src/3rdparty/freetype/src/base/ftcalc.c34
-rw-r--r--src/3rdparty/freetype/src/base/ftdbgmem.c4
-rw-r--r--src/3rdparty/freetype/src/base/ftgloadr.c7
-rw-r--r--src/3rdparty/freetype/src/base/ftglyph.c27
-rw-r--r--src/3rdparty/freetype/src/base/ftinit.c113
-rw-r--r--src/3rdparty/freetype/src/base/ftobjs.c164
-rw-r--r--src/3rdparty/freetype/src/base/ftoutln.c8
-rw-r--r--src/3rdparty/freetype/src/base/ftpatent.c19
-rw-r--r--src/3rdparty/freetype/src/base/ftpic.c54
-rw-r--r--src/3rdparty/freetype/src/base/ftrfork.c4
-rw-r--r--src/3rdparty/freetype/src/base/ftsnames.c (renamed from src/3rdparty/freetype/src/base/ftnames.c)10
-rw-r--r--src/3rdparty/freetype/src/base/ftstream.c54
-rw-r--r--src/3rdparty/freetype/src/base/ftstroke.c64
-rw-r--r--src/3rdparty/freetype/src/base/ftsynth.c29
-rw-r--r--src/3rdparty/freetype/src/base/ftsystem.c9
-rw-r--r--src/3rdparty/freetype/src/base/fttrigon.c10
-rw-r--r--src/3rdparty/freetype/src/base/rules.mk2
-rw-r--r--src/3rdparty/freetype/src/bdf/bdf.h6
-rw-r--r--src/3rdparty/freetype/src/bdf/bdfdrivr.c68
-rw-r--r--src/3rdparty/freetype/src/bdf/bdfdrivr.h4
-rw-r--r--src/3rdparty/freetype/src/bdf/bdflib.c78
-rw-r--r--src/3rdparty/freetype/src/cache/ftcbasic.c94
-rw-r--r--src/3rdparty/freetype/src/cache/ftccache.c23
-rw-r--r--src/3rdparty/freetype/src/cache/ftccache.h11
-rw-r--r--src/3rdparty/freetype/src/cache/ftccback.h4
-rw-r--r--src/3rdparty/freetype/src/cache/ftccmap.c34
-rw-r--r--src/3rdparty/freetype/src/cache/ftcglyph.c8
-rw-r--r--src/3rdparty/freetype/src/cache/ftcglyph.h9
-rw-r--r--src/3rdparty/freetype/src/cache/ftcimage.c6
-rw-r--r--src/3rdparty/freetype/src/cache/ftcmanag.c56
-rw-r--r--src/3rdparty/freetype/src/cache/ftcmru.c8
-rw-r--r--src/3rdparty/freetype/src/cache/ftcmru.h7
-rw-r--r--src/3rdparty/freetype/src/cache/ftcsbits.c17
-rw-r--r--src/3rdparty/freetype/src/cff/Jamfile2
-rw-r--r--src/3rdparty/freetype/src/cff/cff.c1
-rw-r--r--src/3rdparty/freetype/src/cff/cffcmap.c17
-rw-r--r--src/3rdparty/freetype/src/cff/cffcmap.h6
-rw-r--r--src/3rdparty/freetype/src/cff/cffdrivr.c121
-rw-r--r--src/3rdparty/freetype/src/cff/cffdrivr.h3
-rw-r--r--src/3rdparty/freetype/src/cff/cffgload.c261
-rw-r--r--src/3rdparty/freetype/src/cff/cffgload.h16
-rw-r--r--src/3rdparty/freetype/src/cff/cffload.c70
-rw-r--r--src/3rdparty/freetype/src/cff/cffload.h3
-rw-r--r--src/3rdparty/freetype/src/cff/cffobjs.c61
-rw-r--r--src/3rdparty/freetype/src/cff/cffparse.c161
-rw-r--r--src/3rdparty/freetype/src/cff/cffparse.h35
-rw-r--r--src/3rdparty/freetype/src/cff/cffpic.c99
-rw-r--r--src/3rdparty/freetype/src/cff/cffpic.h80
-rw-r--r--src/3rdparty/freetype/src/cff/cfftypes.h2
-rw-r--r--src/3rdparty/freetype/src/cid/cidgload.c70
-rw-r--r--src/3rdparty/freetype/src/cid/cidload.c2
-rw-r--r--src/3rdparty/freetype/src/cid/cidobjs.c9
-rw-r--r--src/3rdparty/freetype/src/cid/cidparse.c9
-rw-r--r--src/3rdparty/freetype/src/cid/cidriver.c1
-rw-r--r--src/3rdparty/freetype/src/cid/cidriver.h4
-rw-r--r--src/3rdparty/freetype/src/cid/cidtoken.h2
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvbsln.c8
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvcommn.c35
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvcommn.h13
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvfeat.c2
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvjust.c26
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvkern.c4
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvlcar.c8
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmod.h4
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmort.c6
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmort.h2
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmort0.c6
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmort1.c6
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmort2.c4
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmort4.c8
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmort5.c6
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmorx.c4
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmorx0.c4
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmorx1.c16
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmorx2.c4
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvmorx5.c6
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvopbd.c12
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvprop.c8
-rw-r--r--src/3rdparty/freetype/src/gxvalid/gxvtrak.c2
-rw-r--r--src/3rdparty/freetype/src/gzip/adler32.c2
-rw-r--r--src/3rdparty/freetype/src/gzip/ftgzip.c12
-rw-r--r--src/3rdparty/freetype/src/gzip/zconf.h8
-rw-r--r--src/3rdparty/freetype/src/gzip/zutil.c8
-rw-r--r--src/3rdparty/freetype/src/gzip/zutil.h2
-rw-r--r--src/3rdparty/freetype/src/lzw/ftlzw.c16
-rw-r--r--src/3rdparty/freetype/src/lzw/ftzopen.c9
-rw-r--r--src/3rdparty/freetype/src/lzw/ftzopen.h4
-rw-r--r--src/3rdparty/freetype/src/otvalid/otvcommn.h44
-rw-r--r--src/3rdparty/freetype/src/otvalid/otvgpos.c5
-rw-r--r--src/3rdparty/freetype/src/otvalid/otvgsub.c3
-rw-r--r--src/3rdparty/freetype/src/otvalid/otvmod.c23
-rw-r--r--src/3rdparty/freetype/src/otvalid/otvmod.h4
-rw-r--r--src/3rdparty/freetype/src/pcf/pcf.h4
-rw-r--r--src/3rdparty/freetype/src/pcf/pcfdrivr.c82
-rw-r--r--src/3rdparty/freetype/src/pcf/pcfdrivr.h4
-rw-r--r--src/3rdparty/freetype/src/pcf/pcfread.c49
-rw-r--r--src/3rdparty/freetype/src/pcf/pcfutil.c8
-rw-r--r--src/3rdparty/freetype/src/pcf/pcfutil.h6
-rw-r--r--src/3rdparty/freetype/src/pfr/pfrcmap.c5
-rw-r--r--src/3rdparty/freetype/src/pfr/pfrdrivr.h4
-rw-r--r--src/3rdparty/freetype/src/pfr/pfrload.c15
-rw-r--r--src/3rdparty/freetype/src/pfr/pfrsbit.c34
-rw-r--r--src/3rdparty/freetype/src/pfr/pfrtypes.h6
-rw-r--r--src/3rdparty/freetype/src/psaux/afmparse.c31
-rw-r--r--src/3rdparty/freetype/src/psaux/afmparse.h4
-rw-r--r--src/3rdparty/freetype/src/psaux/psauxmod.h4
-rw-r--r--src/3rdparty/freetype/src/psaux/psconv.c10
-rw-r--r--src/3rdparty/freetype/src/psaux/psconv.h6
-rw-r--r--src/3rdparty/freetype/src/psaux/psobjs.c39
-rw-r--r--src/3rdparty/freetype/src/psaux/psobjs.h2
-rw-r--r--src/3rdparty/freetype/src/psaux/t1cmap.c8
-rw-r--r--src/3rdparty/freetype/src/psaux/t1decode.c360
-rw-r--r--src/3rdparty/freetype/src/pshinter/Jamfile2
-rw-r--r--src/3rdparty/freetype/src/pshinter/pshalgo.c14
-rw-r--r--src/3rdparty/freetype/src/pshinter/pshinter.c1
-rw-r--r--src/3rdparty/freetype/src/pshinter/pshmod.c17
-rw-r--r--src/3rdparty/freetype/src/pshinter/pshmod.h2
-rw-r--r--src/3rdparty/freetype/src/pshinter/pshpic.c67
-rw-r--r--src/3rdparty/freetype/src/pshinter/pshpic.h53
-rw-r--r--src/3rdparty/freetype/src/pshinter/pshrec.c101
-rw-r--r--src/3rdparty/freetype/src/psnames/Jamfile2
-rw-r--r--src/3rdparty/freetype/src/psnames/psmodule.c73
-rw-r--r--src/3rdparty/freetype/src/psnames/psmodule.h2
-rw-r--r--src/3rdparty/freetype/src/psnames/psnames.c1
-rw-r--r--src/3rdparty/freetype/src/psnames/pspic.c77
-rw-r--r--src/3rdparty/freetype/src/psnames/pspic.h54
-rw-r--r--src/3rdparty/freetype/src/raster/Jamfile2
-rw-r--r--src/3rdparty/freetype/src/raster/ftmisc.h25
-rw-r--r--src/3rdparty/freetype/src/raster/ftraster.c578
-rw-r--r--src/3rdparty/freetype/src/raster/ftrend1.c46
-rw-r--r--src/3rdparty/freetype/src/raster/ftrend1.h4
-rw-r--r--src/3rdparty/freetype/src/raster/raster.c1
-rw-r--r--src/3rdparty/freetype/src/raster/rastpic.c89
-rw-r--r--src/3rdparty/freetype/src/raster/rastpic.h50
-rw-r--r--src/3rdparty/freetype/src/raster/rules.mk3
-rw-r--r--src/3rdparty/freetype/src/sfnt/Jamfile2
-rw-r--r--src/3rdparty/freetype/src/sfnt/sfdriver.c194
-rw-r--r--src/3rdparty/freetype/src/sfnt/sfdriver.h2
-rw-r--r--src/3rdparty/freetype/src/sfnt/sfnt.c1
-rw-r--r--src/3rdparty/freetype/src/sfnt/sfntpic.c101
-rw-r--r--src/3rdparty/freetype/src/sfnt/sfntpic.h88
-rw-r--r--src/3rdparty/freetype/src/sfnt/sfobjs.c35
-rw-r--r--src/3rdparty/freetype/src/sfnt/ttbdf.c16
-rw-r--r--src/3rdparty/freetype/src/sfnt/ttcmap.c591
-rw-r--r--src/3rdparty/freetype/src/sfnt/ttcmap.h40
-rw-r--r--src/3rdparty/freetype/src/sfnt/ttcmapc.h55
-rw-r--r--src/3rdparty/freetype/src/sfnt/ttkern.c13
-rw-r--r--src/3rdparty/freetype/src/sfnt/ttload.c25
-rw-r--r--src/3rdparty/freetype/src/sfnt/ttmtx.c6
-rw-r--r--src/3rdparty/freetype/src/sfnt/ttpost.c3
-rw-r--r--src/3rdparty/freetype/src/sfnt/ttsbit.c2
-rw-r--r--src/3rdparty/freetype/src/sfnt/ttsbit0.c56
-rw-r--r--src/3rdparty/freetype/src/smooth/Jamfile2
-rw-r--r--src/3rdparty/freetype/src/smooth/ftgrays.c137
-rw-r--r--src/3rdparty/freetype/src/smooth/ftgrays.h1
-rw-r--r--src/3rdparty/freetype/src/smooth/ftsmooth.c64
-rw-r--r--src/3rdparty/freetype/src/smooth/ftsmooth.h8
-rw-r--r--src/3rdparty/freetype/src/smooth/ftspic.c97
-rw-r--r--src/3rdparty/freetype/src/smooth/ftspic.h50
-rw-r--r--src/3rdparty/freetype/src/smooth/smooth.c1
-rw-r--r--src/3rdparty/freetype/src/tools/apinames.c4
-rw-r--r--src/3rdparty/freetype/src/tools/chktrcmp.py114
-rw-r--r--src/3rdparty/freetype/src/tools/docmaker/content.py2
-rw-r--r--src/3rdparty/freetype/src/tools/test_afm.c2
-rw-r--r--src/3rdparty/freetype/src/truetype/Jamfile2
-rw-r--r--src/3rdparty/freetype/src/truetype/truetype.c1
-rw-r--r--src/3rdparty/freetype/src/truetype/ttdriver.c91
-rw-r--r--src/3rdparty/freetype/src/truetype/ttdriver.h2
-rw-r--r--src/3rdparty/freetype/src/truetype/ttgload.c317
-rw-r--r--src/3rdparty/freetype/src/truetype/ttgxvar.c83
-rw-r--r--src/3rdparty/freetype/src/truetype/ttgxvar.h2
-rw-r--r--src/3rdparty/freetype/src/truetype/ttinterp.c53
-rw-r--r--src/3rdparty/freetype/src/truetype/ttobjs.c20
-rw-r--r--src/3rdparty/freetype/src/truetype/ttobjs.h38
-rw-r--r--src/3rdparty/freetype/src/truetype/ttpic.c79
-rw-r--r--src/3rdparty/freetype/src/truetype/ttpic.h59
-rw-r--r--src/3rdparty/freetype/src/truetype/ttpload.c36
-rw-r--r--src/3rdparty/freetype/src/type1/t1afm.c22
-rw-r--r--src/3rdparty/freetype/src/type1/t1driver.h4
-rw-r--r--src/3rdparty/freetype/src/type1/t1gload.c94
-rw-r--r--src/3rdparty/freetype/src/type1/t1load.c58
-rw-r--r--src/3rdparty/freetype/src/type1/t1objs.c14
-rw-r--r--src/3rdparty/freetype/src/type1/t1parse.c36
-rw-r--r--src/3rdparty/freetype/src/type42/t42drivr.h4
-rw-r--r--src/3rdparty/freetype/src/type42/t42objs.c15
-rw-r--r--src/3rdparty/freetype/src/type42/t42parse.c33
-rw-r--r--src/3rdparty/freetype/src/winfonts/winfnt.c10
-rw-r--r--src/3rdparty/freetype/src/winfonts/winfnt.h4
-rw-r--r--src/3rdparty/harfbuzz/src/harfbuzz-arabic.c12
-rw-r--r--src/3rdparty/harfbuzz/src/harfbuzz-gpos.c11
-rw-r--r--src/3rdparty/harfbuzz/src/harfbuzz-gsub.c6
-rw-r--r--src/3rdparty/harfbuzz/src/harfbuzz-indic.cpp5
-rw-r--r--src/3rdparty/harfbuzz/src/harfbuzz-myanmar.c3
-rw-r--r--src/3rdparty/harfbuzz/src/harfbuzz-shaper-private.h2
-rw-r--r--src/3rdparty/harfbuzz/src/harfbuzz-shaper.cpp2
-rw-r--r--src/3rdparty/harfbuzz/src/harfbuzz-tibetan.c3
-rw-r--r--src/3rdparty/pcre.pri2
-rw-r--r--src/3rdparty/pcre/config.h4
-rwxr-xr-xsrc/3rdparty/pcre/import_from_pcre_tarball.sh22
-rw-r--r--src/3rdparty/pcre/pcre.h256
-rw-r--r--src/3rdparty/pcre/pcre16_ord2utf16.c7
-rw-r--r--src/3rdparty/pcre/pcre16_utf16_utils.c3
-rw-r--r--src/3rdparty/pcre/pcre16_valid_utf16.c20
-rw-r--r--src/3rdparty/pcre/pcre_byte_order.c48
-rw-r--r--src/3rdparty/pcre/pcre_compile.c2240
-rw-r--r--src/3rdparty/pcre/pcre_config.c24
-rw-r--r--src/3rdparty/pcre/pcre_dfa_exec.c614
-rw-r--r--src/3rdparty/pcre/pcre_exec.c1203
-rw-r--r--src/3rdparty/pcre/pcre_fullinfo.c37
-rw-r--r--src/3rdparty/pcre/pcre_get.c143
-rw-r--r--src/3rdparty/pcre/pcre_internal.h762
-rw-r--r--src/3rdparty/pcre/pcre_jit_compile.c4115
-rw-r--r--src/3rdparty/pcre/pcre_maketables.c9
-rw-r--r--src/3rdparty/pcre/pcre_newline.c82
-rw-r--r--src/3rdparty/pcre/pcre_ord2utf8.c11
-rw-r--r--src/3rdparty/pcre/pcre_refcount.c7
-rw-r--r--src/3rdparty/pcre/pcre_string_utils.c45
-rw-r--r--src/3rdparty/pcre/pcre_study.c209
-rw-r--r--src/3rdparty/pcre/pcre_tables.c335
-rw-r--r--src/3rdparty/pcre/pcre_ucd.c5469
-rw-r--r--src/3rdparty/pcre/pcre_valid_utf8.c17
-rw-r--r--src/3rdparty/pcre/pcre_version.c7
-rw-r--r--src/3rdparty/pcre/pcre_xclass.c6
-rw-r--r--src/3rdparty/pcre/sljit/sljitConfig.h16
-rw-r--r--src/3rdparty/pcre/sljit/sljitConfigInternal.h140
-rw-r--r--src/3rdparty/pcre/sljit/sljitExecAllocator.c28
-rw-r--r--src/3rdparty/pcre/sljit/sljitLir.c624
-rw-r--r--src/3rdparty/pcre/sljit/sljitLir.h606
-rw-r--r--src/3rdparty/pcre/sljit/sljitNativeARM_Thumb2.c529
-rw-r--r--src/3rdparty/pcre/sljit/sljitNativeARM_v5.c913
-rw-r--r--src/3rdparty/pcre/sljit/sljitNativeMIPS_32.c177
-rw-r--r--src/3rdparty/pcre/sljit/sljitNativeMIPS_common.c836
-rw-r--r--src/3rdparty/pcre/sljit/sljitNativePPC_32.c117
-rw-r--r--src/3rdparty/pcre/sljit/sljitNativePPC_64.c175
-rw-r--r--src/3rdparty/pcre/sljit/sljitNativePPC_common.c1094
-rw-r--r--src/3rdparty/pcre/sljit/sljitNativeSPARC_32.c164
-rw-r--r--src/3rdparty/pcre/sljit/sljitNativeSPARC_common.c1348
-rw-r--r--src/3rdparty/pcre/sljit/sljitNativeX86_32.c354
-rw-r--r--src/3rdparty/pcre/sljit/sljitNativeX86_64.c602
-rw-r--r--src/3rdparty/pcre/sljit/sljitNativeX86_common.c2468
-rw-r--r--src/3rdparty/pcre/sljit/sljitUtils.c104
-rw-r--r--src/3rdparty/pcre/ucp.h38
-rwxr-xr-xsrc/3rdparty/sha3/KeccakF-1600-32-rvk.macros555
-rwxr-xr-xsrc/3rdparty/sha3/KeccakF-1600-32.macros26
-rwxr-xr-xsrc/3rdparty/sha3/KeccakF-1600-64.macros728
-rwxr-xr-xsrc/3rdparty/sha3/KeccakF-1600-int-set.h6
-rwxr-xr-xsrc/3rdparty/sha3/KeccakF-1600-interface.h46
-rwxr-xr-xsrc/3rdparty/sha3/KeccakF-1600-opt32-settings.h4
-rwxr-xr-xsrc/3rdparty/sha3/KeccakF-1600-opt32.c524
-rwxr-xr-xsrc/3rdparty/sha3/KeccakF-1600-opt64-settings.h7
-rwxr-xr-xsrc/3rdparty/sha3/KeccakF-1600-opt64.c508
-rwxr-xr-xsrc/3rdparty/sha3/KeccakF-1600-unrolling.macros124
-rwxr-xr-xsrc/3rdparty/sha3/KeccakNISTInterface.c82
-rwxr-xr-xsrc/3rdparty/sha3/KeccakNISTInterface.h70
-rwxr-xr-xsrc/3rdparty/sha3/KeccakSponge.c266
-rwxr-xr-xsrc/3rdparty/sha3/KeccakSponge.h76
-rwxr-xr-xsrc/3rdparty/sha3/brg_endian.h142
-rw-r--r--src/3rdparty/sqlite/shell.c824
-rw-r--r--src/3rdparty/sqlite/sqlite3.c32632
-rw-r--r--src/3rdparty/sqlite/sqlite3.h709
-rw-r--r--src/android/android.pro2
-rw-r--r--src/android/jar/AndroidManifest.xml4
-rw-r--r--src/android/jar/jar.pro19
-rw-r--r--src/android/jar/res/values/strings.xml4
-rw-r--r--src/android/jar/src/org/qtproject/qt5/android/QtActivityDelegate.java806
-rw-r--r--src/android/jar/src/org/qtproject/qt5/android/QtEditText.java97
-rw-r--r--src/android/jar/src/org/qtproject/qt5/android/QtInputConnection.java244
-rw-r--r--src/android/jar/src/org/qtproject/qt5/android/QtLayout.java201
-rw-r--r--src/android/jar/src/org/qtproject/qt5/android/QtNative.java583
-rw-r--r--src/android/jar/src/org/qtproject/qt5/android/QtNativeLibrariesDir.java61
-rw-r--r--src/android/jar/src/org/qtproject/qt5/android/QtSurface.java207
-rw-r--r--src/android/java/AndroidManifest.xml33
-rw-r--r--src/android/java/java.pro11
-rw-r--r--src/android/java/res/layout/splash.xml13
-rw-r--r--src/android/java/res/values-de/strings.xml6
-rw-r--r--src/android/java/res/values-el/strings.xml6
-rw-r--r--src/android/java/res/values-es/strings.xml6
-rw-r--r--src/android/java/res/values-et/strings.xml6
-rw-r--r--src/android/java/res/values-fa/strings.xml6
-rw-r--r--src/android/java/res/values-fr/strings.xml6
-rw-r--r--src/android/java/res/values-id/strings.xml6
-rw-r--r--src/android/java/res/values-it/strings.xml6
-rw-r--r--src/android/java/res/values-ja/strings.xml6
-rw-r--r--src/android/java/res/values-ms/strings.xml6
-rw-r--r--src/android/java/res/values-nb/strings.xml6
-rw-r--r--src/android/java/res/values-nl/strings.xml6
-rw-r--r--src/android/java/res/values-pl/strings.xml6
-rw-r--r--src/android/java/res/values-pt-rBR/strings.xml6
-rw-r--r--src/android/java/res/values-ro/strings.xml6
-rw-r--r--src/android/java/res/values-rs/strings.xml6
-rw-r--r--src/android/java/res/values-ru/strings.xml6
-rw-r--r--src/android/java/res/values-zh-rCN/strings.xml6
-rw-r--r--src/android/java/res/values-zh-rTW/strings.xml6
-rw-r--r--src/android/java/res/values/libs.xml11
-rw-r--r--src/android/java/res/values/strings.xml7
-rw-r--r--src/android/java/src/org/kde/necessitas/ministro/IMinistro.aidl50
-rw-r--r--src/android/java/src/org/kde/necessitas/ministro/IMinistroCallback.aidl55
-rw-r--r--src/android/java/src/org/qtproject/qt5/android/bindings/QtActivity.java1295
-rw-r--r--src/android/java/src/org/qtproject/qt5/android/bindings/QtApplication.java149
-rw-r--r--src/android/java/version.xml8
-rw-r--r--src/angle/angle.pro17
-rw-r--r--src/angle/patches/0001-Dynamically-resolve-functions-of-dwmapi.dll.patch22
-rw-r--r--src/angle/patches/0001-Make-it-possible-to-link-ANGLE-statically-for-single.patch218
-rw-r--r--src/angle/patches/0003-Fix-Float16ToFloat32.py.patch54
-rw-r--r--src/angle/patches/0004-Fix-black-screen-after-minimizing-OpenGL-window-with.patch30
-rw-r--r--src/angle/patches/0005-Fix-build-when-SSE2-is-not-available.patch40
-rw-r--r--src/angle/patches/0006-ANGLE-Do-not-reset-the-share-handle-when-resetting-t.patch32
-rw-r--r--src/angle/patches/0006-Make-DX9-DX11-mutually-exclusive.patch140
-rw-r--r--src/angle/patches/0007-ANGLE-Fix-typedefs-for-Win64.patch14
-rw-r--r--src/angle/patches/0008-ANGLE-DX11-Prevent-assert-when-view-is-minimized-or-.patch58
-rw-r--r--src/angle/patches/0009-ANGLE-Avoid-memory-copies-on-buffers-when-data-is-nu.patch72
-rw-r--r--src/angle/src/common/common.pri2
-rw-r--r--src/angle/src/compiler/preprocessor/preprocessor.pro52
-rw-r--r--src/angle/src/compiler/translator_common.pro24
-rw-r--r--src/angle/src/compiler/translator_hlsl.pro6
-rw-r--r--src/angle/src/config.pri5
-rw-r--r--src/angle/src/libEGL/libEGL.pro9
-rw-r--r--src/angle/src/libGLESv2/libGLESv2.pro186
-rw-r--r--src/concurrent/qtconcurrent_global.h2
-rw-r--r--src/concurrent/qtconcurrentcompilertest.h2
-rw-r--r--src/concurrent/qtconcurrentexception.h2
-rw-r--r--src/concurrent/qtconcurrentfilter.cpp2
-rw-r--r--src/concurrent/qtconcurrentfilter.h2
-rw-r--r--src/concurrent/qtconcurrentfilterkernel.h2
-rw-r--r--src/concurrent/qtconcurrentfunctionwrappers.h2
-rw-r--r--src/concurrent/qtconcurrentiteratekernel.h2
-rw-r--r--src/concurrent/qtconcurrentmap.cpp6
-rw-r--r--src/concurrent/qtconcurrentmap.h2
-rw-r--r--src/concurrent/qtconcurrentmapkernel.h4
-rw-r--r--src/concurrent/qtconcurrentmedian.h2
-rw-r--r--src/concurrent/qtconcurrentreducekernel.h4
-rw-r--r--src/concurrent/qtconcurrentrun.cpp52
-rw-r--r--src/concurrent/qtconcurrentrun.h2
-rw-r--r--src/concurrent/qtconcurrentrunbase.h2
-rw-r--r--src/concurrent/qtconcurrentstoredfunctioncall.h2
-rw-r--r--src/concurrent/qtconcurrentthreadengine.h2
-rw-r--r--src/corelib/Qt5CTestMacros.cmake63
-rw-r--r--src/corelib/Qt5Config.cmake.in43
-rw-r--r--src/corelib/Qt5CoreConfigExtras.cmake.in36
-rw-r--r--src/corelib/animation/qabstractanimation.h4
-rw-r--r--src/corelib/animation/qanimationgroup.h4
-rw-r--r--src/corelib/animation/qparallelanimationgroup.h4
-rw-r--r--src/corelib/animation/qpauseanimation.h4
-rw-r--r--src/corelib/animation/qpropertyanimation.h4
-rw-r--r--src/corelib/animation/qsequentialanimationgroup.cpp4
-rw-r--r--src/corelib/animation/qsequentialanimationgroup.h4
-rw-r--r--src/corelib/animation/qvariantanimation.cpp4
-rw-r--r--src/corelib/animation/qvariantanimation.h4
-rw-r--r--src/corelib/arch/qatomic_alpha.h13
-rw-r--r--src/corelib/arch/qatomic_armv5.h15
-rw-r--r--src/corelib/arch/qatomic_armv6.h7
-rw-r--r--src/corelib/arch/qatomic_armv7.h5
-rw-r--r--src/corelib/arch/qatomic_bfin.h13
-rw-r--r--src/corelib/arch/qatomic_bootstrap.h7
-rw-r--r--src/corelib/arch/qatomic_cxx11.h5
-rw-r--r--src/corelib/arch/qatomic_gcc.h6
-rw-r--r--src/corelib/arch/qatomic_ia64.h41
-rw-r--r--src/corelib/arch/qatomic_integrity.h13
-rw-r--r--src/corelib/arch/qatomic_mips.h7
-rw-r--r--src/corelib/arch/qatomic_msvc.h6
-rw-r--r--src/corelib/arch/qatomic_power.h13
-rw-r--r--src/corelib/arch/qatomic_s390.h13
-rw-r--r--src/corelib/arch/qatomic_sh4a.h7
-rw-r--r--src/corelib/arch/qatomic_sparc.h13
-rw-r--r--src/corelib/arch/qatomic_unix.h6
-rw-r--r--src/corelib/arch/qatomic_vxworks.h18
-rw-r--r--src/corelib/arch/qatomic_x86.h7
-rw-r--r--src/corelib/arch/sparc/arch.pri2
-rw-r--r--src/corelib/arch/sparc/qatomic_sparc.cpp2
-rw-r--r--src/corelib/codecs/qeuckrcodec.cpp4
-rw-r--r--src/corelib/codecs/qiconvcodec.cpp2
-rw-r--r--src/corelib/codecs/qicucodec.cpp3
-rw-r--r--src/corelib/codecs/qjpunicode.cpp6
-rw-r--r--src/corelib/codecs/qtextcodec.cpp34
-rw-r--r--src/corelib/codecs/qtextcodec.h4
-rw-r--r--src/corelib/codecs/qtextcodec_p.h2
-rw-r--r--src/corelib/corelib.pro19
-rw-r--r--src/corelib/doc/snippets/code/doc_src_properties.cpp21
-rw-r--r--src/corelib/doc/snippets/code/src_corelib_global_qglobal.cpp4
-rw-r--r--src/corelib/doc/snippets/code/src_corelib_kernel_qabstractitemmodel.cpp34
-rw-r--r--src/corelib/doc/snippets/code/src_corelib_kernel_qcoreapplication.cpp7
-rw-r--r--src/corelib/doc/snippets/code/src_corelib_kernel_qmath.cpp63
-rw-r--r--src/corelib/doc/snippets/code/src_corelib_kernel_qobject.cpp1
-rw-r--r--src/corelib/doc/snippets/code/src_corelib_thread_qwaitcondition_unix.cpp2
-rw-r--r--src/corelib/doc/snippets/code/src_corelib_tools_qbytearray.cpp2
-rw-r--r--src/corelib/doc/snippets/code/src_corelib_tools_qpoint.cpp14
-rw-r--r--src/corelib/doc/snippets/fileinfo/main.cpp6
-rw-r--r--src/corelib/doc/snippets/qmessageauthenticationcode/main.cpp62
-rw-r--r--src/corelib/doc/snippets/qmetaobject-revision/main.cpp72
-rw-r--r--src/corelib/doc/snippets/qmetaobject-revision/qmetaobject-revision.pro4
-rw-r--r--src/corelib/doc/snippets/qmetaobject-revision/window.cpp66
-rw-r--r--src/corelib/doc/snippets/qmetaobject-revision/window.h63
-rw-r--r--src/corelib/doc/snippets/qstring/main.cpp2
-rw-r--r--src/corelib/doc/snippets/sharedemployee/employee.h10
-rw-r--r--src/corelib/doc/snippets/signalmapper/filereader.cpp4
-rw-r--r--src/corelib/doc/snippets/statemachine/eventtest.cpp4
-rw-r--r--src/corelib/doc/snippets/statemachine/main4.cpp2
-rw-r--r--src/corelib/doc/snippets/streaming/main.cpp4
-rw-r--r--src/corelib/doc/snippets/timers/timers.cpp2
-rw-r--r--src/corelib/doc/src/objectmodel/object.qdoc10
-rw-r--r--src/corelib/doc/src/objectmodel/properties.qdoc35
-rw-r--r--src/corelib/doc/src/objectmodel/signalsandslots.qdoc4
-rw-r--r--src/corelib/global/global.pri2
-rw-r--r--src/corelib/global/qcompilerdetection.h9
-rw-r--r--src/corelib/global/qendian.h4
-rw-r--r--src/corelib/global/qfeatures.h5
-rw-r--r--src/corelib/global/qfeatures.txt15
-rw-r--r--src/corelib/global/qflags.h4
-rw-r--r--src/corelib/global/qglobal.cpp71
-rw-r--r--src/corelib/global/qglobal.h145
-rw-r--r--src/corelib/global/qglobalstatic.cpp524
-rw-r--r--src/corelib/global/qglobalstatic.h142
-rw-r--r--src/corelib/global/qisenum.h3
-rw-r--r--src/corelib/global/qlibraryinfo.h4
-rw-r--r--src/corelib/global/qlogging.cpp123
-rw-r--r--src/corelib/global/qlogging.h3
-rw-r--r--src/corelib/global/qnamespace.h29
-rw-r--r--src/corelib/global/qnamespace.qdoc59
-rw-r--r--src/corelib/global/qnumeric.h4
-rw-r--r--src/corelib/global/qprocessordetection.h5
-rw-r--r--src/corelib/global/qsysinfo.h3
-rw-r--r--src/corelib/global/qsystemdetection.h60
-rw-r--r--src/corelib/global/qt_windows.h5
-rw-r--r--src/corelib/global/qtypeinfo.h3
-rw-r--r--src/corelib/global/qtypetraits.h7
-rw-r--r--src/corelib/io/io.pri20
-rw-r--r--src/corelib/io/qabstractfileengine.cpp31
-rw-r--r--src/corelib/io/qabstractfileengine_p.h8
-rw-r--r--src/corelib/io/qbuffer.h4
-rw-r--r--src/corelib/io/qdatastream.cpp6
-rw-r--r--src/corelib/io/qdatastream.h9
-rw-r--r--src/corelib/io/qdebug.cpp73
-rw-r--r--src/corelib/io/qdebug.h16
-rw-r--r--src/corelib/io/qdir.h4
-rw-r--r--src/corelib/io/qdiriterator.h4
-rw-r--r--src/corelib/io/qfile.h4
-rw-r--r--src/corelib/io/qfiledevice.cpp2
-rw-r--r--src/corelib/io/qfiledevice.h4
-rw-r--r--src/corelib/io/qfileinfo.h4
-rw-r--r--src/corelib/io/qfilesystemengine.cpp3
-rw-r--r--src/corelib/io/qfilesystemengine_unix.cpp18
-rw-r--r--src/corelib/io/qfilesystemengine_win.cpp2
-rw-r--r--src/corelib/io/qfilesystemwatcher.h4
-rw-r--r--src/corelib/io/qfilesystemwatcher_win.cpp2
-rw-r--r--src/corelib/io/qfsfileengine.cpp18
-rw-r--r--src/corelib/io/qfsfileengine_p.h3
-rw-r--r--src/corelib/io/qfsfileengine_unix.cpp23
-rw-r--r--src/corelib/io/qfsfileengine_win.cpp36
-rw-r--r--src/corelib/io/qiodevice.cpp2
-rw-r--r--src/corelib/io/qiodevice.h5
-rw-r--r--src/corelib/io/qlockfile.cpp346
-rw-r--r--src/corelib/io/qlockfile.h87
-rw-r--r--src/corelib/io/qlockfile_p.h104
-rw-r--r--src/corelib/io/qlockfile_unix.cpp207
-rw-r--r--src/corelib/io/qlockfile_win.cpp138
-rw-r--r--src/corelib/io/qnoncontiguousbytedevice.cpp11
-rw-r--r--src/corelib/io/qprocess.cpp96
-rw-r--r--src/corelib/io/qprocess.h10
-rw-r--r--src/corelib/io/qprocess_unix.cpp40
-rw-r--r--src/corelib/io/qprocess_win.cpp8
-rw-r--r--src/corelib/io/qprocess_wince.cpp2
-rw-r--r--src/corelib/io/qresource.cpp9
-rw-r--r--src/corelib/io/qresource.h4
-rw-r--r--src/corelib/io/qresource_p.h2
-rw-r--r--src/corelib/io/qsavefile.cpp383
-rw-r--r--src/corelib/io/qsavefile.h93
-rw-r--r--src/corelib/io/qsavefile_p.h (renamed from src/widgets/styles/qmacstylepixmaps_mac_p.h)46
-rw-r--r--src/corelib/io/qsettings.cpp12
-rw-r--r--src/corelib/io/qsettings.h4
-rw-r--r--src/corelib/io/qsettings_win.cpp2
-rw-r--r--src/corelib/io/qstandardpaths.h6
-rw-r--r--src/corelib/io/qstandardpaths_win.cpp4
-rw-r--r--src/corelib/io/qtemporarydir.cpp14
-rw-r--r--src/corelib/io/qtemporarydir.h4
-rw-r--r--src/corelib/io/qtemporaryfile.cpp69
-rw-r--r--src/corelib/io/qtemporaryfile.h6
-rw-r--r--src/corelib/io/qtemporaryfile_p.h103
-rw-r--r--src/corelib/io/qtextstream.cpp218
-rw-r--r--src/corelib/io/qtextstream.h5
-rw-r--r--src/corelib/io/qtextstream_p.h185
-rw-r--r--src/corelib/io/qtldurl.cpp18
-rw-r--r--src/corelib/io/qurl.cpp38
-rw-r--r--src/corelib/io/qurl.h7
-rw-r--r--src/corelib/io/qurlidna.cpp29
-rw-r--r--src/corelib/io/qurlquery.cpp1
-rw-r--r--src/corelib/io/qurlquery.h4
-rw-r--r--src/corelib/io/qurltlds_p.h15867
-rw-r--r--src/corelib/io/qwindowspipereader.cpp12
-rw-r--r--src/corelib/io/qwindowspipereader_p.h4
-rw-r--r--src/corelib/io/qwindowspipewriter_p.h4
-rw-r--r--src/corelib/io/qwinoverlappedionotifier_p.h4
-rw-r--r--src/corelib/itemmodels/qabstractitemmodel.cpp52
-rw-r--r--src/corelib/itemmodels/qabstractitemmodel.h11
-rw-r--r--src/corelib/itemmodels/qabstractproxymodel.cpp16
-rw-r--r--src/corelib/itemmodels/qabstractproxymodel.h7
-rw-r--r--src/corelib/itemmodels/qidentityproxymodel.h4
-rw-r--r--src/corelib/itemmodels/qitemselectionmodel.h4
-rw-r--r--src/corelib/itemmodels/qsortfilterproxymodel.cpp3
-rw-r--r--src/corelib/itemmodels/qsortfilterproxymodel.h4
-rw-r--r--src/corelib/itemmodels/qstringlistmodel.cpp4
-rw-r--r--src/corelib/itemmodels/qstringlistmodel.h4
-rw-r--r--src/corelib/json/qjsonarray.h4
-rw-r--r--src/corelib/json/qjsondocument.cpp39
-rw-r--r--src/corelib/json/qjsondocument.h17
-rw-r--r--src/corelib/json/qjsonobject.h4
-rw-r--r--src/corelib/json/qjsonvalue.h4
-rw-r--r--src/corelib/kernel/kernel.pri2
-rw-r--r--src/corelib/kernel/qabstracteventdispatcher.cpp2
-rw-r--r--src/corelib/kernel/qabstracteventdispatcher.h4
-rw-r--r--src/corelib/kernel/qabstractnativeeventfilter.cpp1
-rw-r--r--src/corelib/kernel/qabstractnativeeventfilter.h4
-rw-r--r--src/corelib/kernel/qbasictimer.h4
-rw-r--r--src/corelib/kernel/qcore_mac_p.h15
-rw-r--r--src/corelib/kernel/qcore_unix.cpp21
-rw-r--r--src/corelib/kernel/qcore_unix_p.h54
-rw-r--r--src/corelib/kernel/qcoreapplication.cpp256
-rw-r--r--src/corelib/kernel/qcoreapplication.h72
-rw-r--r--src/corelib/kernel/qcoreapplication_p.h46
-rw-r--r--src/corelib/kernel/qcoreapplication_win.cpp8
-rw-r--r--src/corelib/kernel/qcoreevent.cpp9
-rw-r--r--src/corelib/kernel/qcoreevent.h9
-rw-r--r--src/corelib/kernel/qeventdispatcher_blackberry.cpp18
-rw-r--r--src/corelib/kernel/qeventdispatcher_blackberry_p.h2
-rw-r--r--src/corelib/kernel/qeventdispatcher_glib.cpp11
-rw-r--r--src/corelib/kernel/qeventdispatcher_unix.cpp65
-rw-r--r--src/corelib/kernel/qeventdispatcher_unix_p.h13
-rw-r--r--src/corelib/kernel/qeventloop.cpp28
-rw-r--r--src/corelib/kernel/qeventloop.h4
-rw-r--r--src/corelib/kernel/qeventloop_p.h16
-rw-r--r--src/corelib/kernel/qfunctions_nacl.h8
-rw-r--r--src/corelib/kernel/qfunctions_p.h3
-rw-r--r--src/corelib/kernel/qfunctions_vxworks.cpp10
-rw-r--r--src/corelib/kernel/qfunctions_vxworks.h56
-rw-r--r--src/corelib/kernel/qfunctions_wince.h6
-rw-r--r--src/corelib/kernel/qmath.cpp87
-rw-r--r--src/corelib/kernel/qmath.h28
-rw-r--r--src/corelib/kernel/qmath.qdoc6
-rw-r--r--src/corelib/kernel/qmetaobject.cpp33
-rw-r--r--src/corelib/kernel/qmetaobject.h4
-rw-r--r--src/corelib/kernel/qmetatype.cpp8
-rw-r--r--src/corelib/kernel/qmetatype.h98
-rw-r--r--src/corelib/kernel/qmetatype_p.h2
-rw-r--r--src/corelib/kernel/qmimedata.h4
-rw-r--r--src/corelib/kernel/qobject.cpp134
-rw-r--r--src/corelib/kernel/qobject.h42
-rw-r--r--src/corelib/kernel/qobject_impl.h7
-rw-r--r--src/corelib/kernel/qobject_p.h77
-rw-r--r--src/corelib/kernel/qobjectcleanuphandler.h4
-rw-r--r--src/corelib/kernel/qobjectdefs.h4
-rw-r--r--src/corelib/kernel/qobjectdefs_impl.h49
-rw-r--r--src/corelib/kernel/qpointer.cpp1
-rw-r--r--src/corelib/kernel/qpointer.h100
-rw-r--r--src/corelib/kernel/qsharedmemory.h4
-rw-r--r--src/corelib/kernel/qsharedmemory_p.h2
-rw-r--r--src/corelib/kernel/qsharedmemory_unix.cpp3
-rw-r--r--src/corelib/kernel/qsignalmapper.h4
-rw-r--r--src/corelib/kernel/qsocketnotifier.cpp10
-rw-r--r--src/corelib/kernel/qsocketnotifier.h4
-rw-r--r--src/corelib/kernel/qsystemerror_p.h6
-rw-r--r--src/corelib/kernel/qsystemsemaphore.h4
-rw-r--r--src/corelib/kernel/qsystemsemaphore_win.cpp2
-rw-r--r--src/corelib/kernel/qtimer.h6
-rw-r--r--src/corelib/kernel/qtimerinfo_unix.cpp85
-rw-r--r--src/corelib/kernel/qtimerinfo_unix_p.h14
-rw-r--r--src/corelib/kernel/qtranslator.h4
-rw-r--r--src/corelib/kernel/qvariant.cpp12
-rw-r--r--src/corelib/kernel/qvariant.h30
-rw-r--r--src/corelib/kernel/qvariant_p.h2
-rw-r--r--src/corelib/kernel/qwineventnotifier.cpp4
-rw-r--r--src/corelib/kernel/qwineventnotifier.h4
-rw-r--r--src/corelib/mimetypes/qmimedatabase.cpp2
-rw-r--r--src/corelib/mimetypes/qmimedatabase.h3
-rw-r--r--src/corelib/mimetypes/qmimetype.h3
-rw-r--r--src/corelib/plugin/qfactoryinterface.h4
-rw-r--r--src/corelib/plugin/qlibrary.cpp173
-rw-r--r--src/corelib/plugin/qlibrary.h10
-rw-r--r--src/corelib/plugin/qlibrary_p.h9
-rw-r--r--src/corelib/plugin/qlibrary_unix.cpp2
-rw-r--r--src/corelib/plugin/qlibrary_win.cpp7
-rw-r--r--src/corelib/plugin/qplugin.h4
-rw-r--r--src/corelib/plugin/qplugin.qdoc2
-rw-r--r--src/corelib/plugin/qpluginloader.h9
-rw-r--r--src/corelib/plugin/quuid.cpp12
-rw-r--r--src/corelib/plugin/quuid.h14
-rw-r--r--src/corelib/statemachine/qabstractstate.h4
-rw-r--r--src/corelib/statemachine/qabstracttransition.h4
-rw-r--r--src/corelib/statemachine/qeventtransition.h4
-rw-r--r--src/corelib/statemachine/qfinalstate.h4
-rw-r--r--src/corelib/statemachine/qhistorystate.h4
-rw-r--r--src/corelib/statemachine/qsignaltransition.h4
-rw-r--r--src/corelib/statemachine/qstate.h4
-rw-r--r--src/corelib/statemachine/qstatemachine.h4
-rw-r--r--src/corelib/statemachine/qstatemachine_p.h8
-rw-r--r--src/corelib/thread/qatomic.cpp2
-rw-r--r--src/corelib/thread/qatomic.h4
-rw-r--r--src/corelib/thread/qbasicatomic.h8
-rw-r--r--src/corelib/thread/qexception.cpp4
-rw-r--r--src/corelib/thread/qexception.h2
-rw-r--r--src/corelib/thread/qfuture.h2
-rw-r--r--src/corelib/thread/qfuture.qdoc2
-rw-r--r--src/corelib/thread/qfutureinterface.cpp2
-rw-r--r--src/corelib/thread/qfutureinterface.h5
-rw-r--r--src/corelib/thread/qfuturesynchronizer.h5
-rw-r--r--src/corelib/thread/qfuturewatcher.h3
-rw-r--r--src/corelib/thread/qgenericatomic.h6
-rw-r--r--src/corelib/thread/qmutex.h4
-rw-r--r--src/corelib/thread/qmutex_p.h9
-rw-r--r--src/corelib/thread/qmutex_unix.cpp11
-rw-r--r--src/corelib/thread/qoldbasicatomic.h6
-rw-r--r--src/corelib/thread/qreadwritelock.cpp2
-rw-r--r--src/corelib/thread/qreadwritelock.h4
-rw-r--r--src/corelib/thread/qresultstore.cpp8
-rw-r--r--src/corelib/thread/qresultstore.h4
-rw-r--r--src/corelib/thread/qrunnable.cpp2
-rw-r--r--src/corelib/thread/qrunnable.h2
-rw-r--r--src/corelib/thread/qsemaphore.h4
-rw-r--r--src/corelib/thread/qthread.cpp21
-rw-r--r--src/corelib/thread/qthread.h4
-rw-r--r--src/corelib/thread/qthread_p.h13
-rw-r--r--src/corelib/thread/qthread_unix.cpp89
-rw-r--r--src/corelib/thread/qthread_win.cpp48
-rw-r--r--src/corelib/thread/qthreadpool.cpp14
-rw-r--r--src/corelib/thread/qthreadpool.h2
-rw-r--r--src/corelib/thread/qthreadstorage.h4
-rw-r--r--src/corelib/thread/qwaitcondition.h4
-rw-r--r--src/corelib/thread/qwaitcondition_unix.cpp70
-rw-r--r--src/corelib/thread/thread.pri2
-rw-r--r--src/corelib/tools/qalgorithms.h4
-rw-r--r--src/corelib/tools/qalgorithms.qdoc20
-rw-r--r--src/corelib/tools/qarraydata.h4
-rw-r--r--src/corelib/tools/qarraydataops.h4
-rw-r--r--src/corelib/tools/qarraydatapointer.h4
-rw-r--r--src/corelib/tools/qbitarray.cpp6
-rw-r--r--src/corelib/tools/qbitarray.h4
-rw-r--r--src/corelib/tools/qbytearray.cpp32
-rw-r--r--src/corelib/tools/qbytearray.h4
-rw-r--r--src/corelib/tools/qbytearraymatcher.cpp1
-rw-r--r--src/corelib/tools/qbytearraymatcher.h4
-rw-r--r--src/corelib/tools/qcache.h4
-rw-r--r--src/corelib/tools/qchar.cpp147
-rw-r--r--src/corelib/tools/qchar.h132
-rw-r--r--src/corelib/tools/qcollator_p.h4
-rw-r--r--src/corelib/tools/qcontainerfwd.h4
-rw-r--r--src/corelib/tools/qcontiguouscache.cpp4
-rw-r--r--src/corelib/tools/qcontiguouscache.h4
-rw-r--r--src/corelib/tools/qcryptographichash.cpp161
-rw-r--r--src/corelib/tools/qcryptographichash.h11
-rw-r--r--src/corelib/tools/qdatetime.cpp45
-rw-r--r--src/corelib/tools/qdatetime.h4
-rw-r--r--src/corelib/tools/qdatetime_p.h3
-rw-r--r--src/corelib/tools/qeasingcurve.h4
-rw-r--r--src/corelib/tools/qelapsedtimer.h4
-rw-r--r--src/corelib/tools/qelapsedtimer_mac.cpp6
-rw-r--r--src/corelib/tools/qelapsedtimer_unix.cpp10
-rw-r--r--src/corelib/tools/qfreelist_p.h4
-rw-r--r--src/corelib/tools/qharfbuzz_p.h303
-rw-r--r--src/corelib/tools/qhash.cpp22
-rw-r--r--src/corelib/tools/qhash.h23
-rw-r--r--src/corelib/tools/qiterator.h4
-rw-r--r--src/corelib/tools/qiterator.qdoc24
-rw-r--r--src/corelib/tools/qline.cpp6
-rw-r--r--src/corelib/tools/qline.h4
-rw-r--r--src/corelib/tools/qlinkedlist.h4
-rw-r--r--src/corelib/tools/qlist.cpp3
-rw-r--r--src/corelib/tools/qlist.h4
-rw-r--r--src/corelib/tools/qlocale.cpp359
-rw-r--r--src/corelib/tools/qlocale.h141
-rw-r--r--src/corelib/tools/qlocale.qdoc153
-rw-r--r--src/corelib/tools/qlocale_blackberry.cpp315
-rw-r--r--src/corelib/tools/qlocale_blackberry.h99
-rw-r--r--src/corelib/tools/qlocale_data_p.h8963
-rw-r--r--src/corelib/tools/qlocale_mac.mm24
-rw-r--r--src/corelib/tools/qlocale_p.h42
-rw-r--r--src/corelib/tools/qlocale_unix.cpp101
-rw-r--r--src/corelib/tools/qmap.cpp83
-rw-r--r--src/corelib/tools/qmap.h142
-rw-r--r--src/corelib/tools/qmargins.cpp236
-rw-r--r--src/corelib/tools/qmargins.h133
-rw-r--r--src/corelib/tools/qmessageauthenticationcode.cpp283
-rw-r--r--src/corelib/tools/qmessageauthenticationcode.h80
-rw-r--r--src/corelib/tools/qpair.h4
-rw-r--r--src/corelib/tools/qpair.qdoc2
-rw-r--r--src/corelib/tools/qpodlist_p.h4
-rw-r--r--src/corelib/tools/qpoint.cpp18
-rw-r--r--src/corelib/tools/qpoint.h10
-rw-r--r--src/corelib/tools/qqueue.h4
-rw-r--r--src/corelib/tools/qrect.h10
-rw-r--r--src/corelib/tools/qrefcount.h4
-rw-r--r--src/corelib/tools/qregexp.cpp2
-rw-r--r--src/corelib/tools/qregexp.h6
-rw-r--r--src/corelib/tools/qregularexpression.cpp188
-rw-r--r--src/corelib/tools/qregularexpression.h18
-rw-r--r--src/corelib/tools/qringbuffer_p.h2
-rw-r--r--src/corelib/tools/qscopedpointer.h3
-rw-r--r--src/corelib/tools/qscopedpointer_p.h2
-rw-r--r--src/corelib/tools/qscopedvaluerollback.h2
-rw-r--r--src/corelib/tools/qset.h15
-rw-r--r--src/corelib/tools/qset.qdoc30
-rw-r--r--src/corelib/tools/qshareddata.cpp6
-rw-r--r--src/corelib/tools/qshareddata.h4
-rw-r--r--src/corelib/tools/qsharedpointer.cpp86
-rw-r--r--src/corelib/tools/qsharedpointer.h7
-rw-r--r--src/corelib/tools/qsharedpointer_impl.h38
-rw-r--r--src/corelib/tools/qsimd.cpp2
-rw-r--r--src/corelib/tools/qsimd_p.h8
-rw-r--r--src/corelib/tools/qsize.h4
-rw-r--r--src/corelib/tools/qstack.h4
-rw-r--r--src/corelib/tools/qstring.cpp469
-rw-r--r--src/corelib/tools/qstring.h34
-rw-r--r--src/corelib/tools/qstringbuilder.h4
-rw-r--r--src/corelib/tools/qstringlist.cpp15
-rw-r--r--src/corelib/tools/qstringlist.h16
-rw-r--r--src/corelib/tools/qstringmatcher.cpp1
-rw-r--r--src/corelib/tools/qstringmatcher.h4
-rw-r--r--src/corelib/tools/qtextboundaryfinder.cpp43
-rw-r--r--src/corelib/tools/qtextboundaryfinder.h4
-rw-r--r--src/corelib/tools/qtimeline.cpp3
-rw-r--r--src/corelib/tools/qtimeline.h4
-rw-r--r--src/corelib/tools/qunicodetables.cpp11948
-rw-r--r--src/corelib/tools/qunicodetables_p.h113
-rw-r--r--src/corelib/tools/qunicodetools.cpp53
-rw-r--r--src/corelib/tools/qunicodetools_p.h3
-rw-r--r--src/corelib/tools/qvarlengtharray.h9
-rw-r--r--src/corelib/tools/qvarlengtharray.qdoc20
-rw-r--r--src/corelib/tools/qvector.cpp51
-rw-r--r--src/corelib/tools/qvector.h29
-rw-r--r--src/corelib/tools/tools.pri11
-rw-r--r--src/corelib/xml/qxmlstream.cpp2
-rw-r--r--src/corelib/xml/qxmlstream.h4
-rw-r--r--src/corelib/xml/qxmlstream_p.h1
-rw-r--r--src/corelib/xml/qxmlutils.cpp2
-rw-r--r--src/dbus/dbus.pro4
-rw-r--r--src/dbus/doc/snippets/code/doc_src_qdbusadaptors.cpp2
-rw-r--r--src/dbus/qdbus_symbols_p.h2
-rw-r--r--src/dbus/qdbusabstractadaptor.h4
-rw-r--r--src/dbus/qdbusabstractinterface.cpp21
-rw-r--r--src/dbus/qdbusabstractinterface.h4
-rw-r--r--src/dbus/qdbusargument.h21
-rw-r--r--src/dbus/qdbusconnection.cpp47
-rw-r--r--src/dbus/qdbusconnection.h4
-rw-r--r--src/dbus/qdbusconnection_p.h12
-rw-r--r--src/dbus/qdbusconnectioninterface.h4
-rw-r--r--src/dbus/qdbuscontext.h4
-rw-r--r--src/dbus/qdbuserror.cpp2
-rw-r--r--src/dbus/qdbuserror.h4
-rw-r--r--src/dbus/qdbusextratypes.h4
-rw-r--r--src/dbus/qdbusintegrator.cpp93
-rw-r--r--src/dbus/qdbusintegrator_p.h2
-rw-r--r--src/dbus/qdbusinterface.h4
-rw-r--r--src/dbus/qdbusintrospection_p.h2
-rw-r--r--src/dbus/qdbusmacros.h2
-rw-r--r--src/dbus/qdbusmessage.h4
-rw-r--r--src/dbus/qdbusmetaobject.cpp18
-rw-r--r--src/dbus/qdbusmetatype.cpp6
-rw-r--r--src/dbus/qdbusmetatype.h4
-rw-r--r--src/dbus/qdbuspendingcall.h4
-rw-r--r--src/dbus/qdbuspendingreply.cpp28
-rw-r--r--src/dbus/qdbuspendingreply.h14
-rw-r--r--src/dbus/qdbusreply.h8
-rw-r--r--src/dbus/qdbusserver.h4
-rw-r--r--src/dbus/qdbusservicewatcher.h4
-rw-r--r--src/dbus/qdbusunixfiledescriptor.h4
-rw-r--r--src/dbus/qdbusutil_p.h4
-rw-r--r--src/dbus/qdbusvirtualobject.cpp5
-rw-r--r--src/dbus/qdbusvirtualobject.h4
-rw-r--r--src/gui/QtGui.dynlist5
-rw-r--r--src/gui/accessible/accessible.pri4
-rw-r--r--src/gui/accessible/qaccessible.cpp208
-rw-r--r--src/gui/accessible/qaccessible.h38
-rw-r--r--src/gui/accessible/qaccessible2.cpp37
-rw-r--r--src/gui/accessible/qaccessible2_p.h (renamed from src/gui/accessible/qaccessible2.h)28
-rw-r--r--src/gui/accessible/qaccessiblebridge.h4
-rw-r--r--src/gui/accessible/qaccessiblecache.cpp (renamed from src/gui/text/qrawfont_ft.cpp)127
-rw-r--r--src/gui/accessible/qaccessiblecache_p.h78
-rw-r--r--src/gui/accessible/qaccessibleobject.cpp39
-rw-r--r--src/gui/accessible/qaccessibleobject.h5
-rw-r--r--src/gui/accessible/qaccessibleplugin.h4
-rw-r--r--src/gui/accessible/qplatformaccessibility.h4
-rw-r--r--src/gui/doc/qtgui.qdocconf2
-rw-r--r--src/gui/doc/snippets/code/src_gui_util_qvalidator.cpp43
-rw-r--r--src/gui/doc/snippets/textdocument-tables/mainwindow.cpp2
-rw-r--r--src/gui/doc/snippets/textdocument-texttable/main.cpp2
-rw-r--r--src/gui/doc/src/external-resources.qdoc5
-rw-r--r--src/gui/doc/src/paintsystem.qdoc10
-rw-r--r--src/gui/doc/src/qtgui.qdoc6
-rw-r--r--src/gui/gui.pro5
-rw-r--r--src/gui/image/qbitmap.h4
-rw-r--r--src/gui/image/qicon.cpp138
-rw-r--r--src/gui/image/qicon.h6
-rw-r--r--src/gui/image/qicon_p.h2
-rw-r--r--src/gui/image/qiconengine.h4
-rw-r--r--src/gui/image/qiconengineplugin.h4
-rw-r--r--src/gui/image/qiconloader_p.h2
-rw-r--r--src/gui/image/qimage.cpp1
-rw-r--r--src/gui/image/qimage.h4
-rw-r--r--src/gui/image/qimageiohandler.cpp2
-rw-r--r--src/gui/image/qimageiohandler.h4
-rw-r--r--src/gui/image/qimagereader.cpp75
-rw-r--r--src/gui/image/qimagereader.h5
-rw-r--r--src/gui/image/qimagewriter.cpp85
-rw-r--r--src/gui/image/qimagewriter.h5
-rw-r--r--src/gui/image/qmovie.cpp14
-rw-r--r--src/gui/image/qmovie.h4
-rw-r--r--src/gui/image/qpicture.h4
-rw-r--r--src/gui/image/qpictureformatplugin.h4
-rw-r--r--src/gui/image/qpixmap.cpp3
-rw-r--r--src/gui/image/qpixmap.h4
-rw-r--r--src/gui/image/qpixmap_raster.cpp10
-rw-r--r--src/gui/image/qpixmapcache.h4
-rw-r--r--src/gui/image/qplatformpixmap.cpp5
-rw-r--r--src/gui/image/qplatformpixmap.h5
-rw-r--r--src/gui/image/qxbmhandler.cpp2
-rw-r--r--src/gui/itemmodels/qstandarditemmodel.cpp2
-rw-r--r--src/gui/itemmodels/qstandarditemmodel.h5
-rw-r--r--src/gui/kernel/kernel.pri4
-rw-r--r--src/gui/kernel/qclipboard.cpp14
-rw-r--r--src/gui/kernel/qclipboard.h4
-rw-r--r--src/gui/kernel/qcursor.h6
-rw-r--r--src/gui/kernel/qdrag.h4
-rw-r--r--src/gui/kernel/qevent.cpp54
-rw-r--r--src/gui/kernel/qevent.h14
-rw-r--r--src/gui/kernel/qgenericplugin.h4
-rw-r--r--src/gui/kernel/qgenericpluginfactory.h4
-rw-r--r--src/gui/kernel/qguiapplication.cpp204
-rw-r--r--src/gui/kernel/qguiapplication.h4
-rw-r--r--src/gui/kernel/qguiapplication_p.h9
-rw-r--r--src/gui/kernel/qinputmethod.cpp27
-rw-r--r--src/gui/kernel/qinputmethod.h7
-rw-r--r--src/gui/kernel/qinputmethod_p.h5
-rw-r--r--src/gui/kernel/qkeysequence.cpp64
-rw-r--r--src/gui/kernel/qkeysequence.h10
-rw-r--r--src/gui/kernel/qoffscreensurface.cpp345
-rw-r--r--src/gui/kernel/qoffscreensurface.h98
-rw-r--r--src/gui/kernel/qopenglcontext.cpp275
-rw-r--r--src/gui/kernel/qopenglcontext.h67
-rw-r--r--src/gui/kernel/qopenglcontext_p.h7
-rw-r--r--src/gui/kernel/qpalette.h4
-rw-r--r--src/gui/kernel/qplatformclipboard.h4
-rw-r--r--src/gui/kernel/qplatformcursor.cpp4
-rw-r--r--src/gui/kernel/qplatformcursor.h4
-rw-r--r--src/gui/kernel/qplatformdialoghelper.h4
-rw-r--r--src/gui/kernel/qplatformdrag.h4
-rw-r--r--src/gui/kernel/qplatforminputcontext.h4
-rw-r--r--src/gui/kernel/qplatforminputcontext_p.h4
-rw-r--r--src/gui/kernel/qplatforminputcontextfactory.cpp4
-rw-r--r--src/gui/kernel/qplatforminputcontextfactory_p.h4
-rw-r--r--src/gui/kernel/qplatforminputcontextplugin_p.h4
-rw-r--r--src/gui/kernel/qplatformintegration.cpp22
-rw-r--r--src/gui/kernel/qplatformintegration.h12
-rw-r--r--src/gui/kernel/qplatformintegrationfactory_p.h4
-rw-r--r--src/gui/kernel/qplatformintegrationplugin.h4
-rw-r--r--src/gui/kernel/qplatformmenu.h16
-rw-r--r--src/gui/kernel/qplatformnativeinterface.h4
-rw-r--r--src/gui/kernel/qplatformoffscreensurface.cpp93
-rw-r--r--src/gui/kernel/qplatformoffscreensurface.h85
-rw-r--r--src/gui/kernel/qplatformopenglcontext.h7
-rw-r--r--src/gui/kernel/qplatformscreen.h4
-rw-r--r--src/gui/kernel/qplatformscreen_p.h4
-rw-r--r--src/gui/kernel/qplatformscreenpageflipper.h4
-rw-r--r--src/gui/kernel/qplatformservices.h3
-rw-r--r--src/gui/kernel/qplatformsharedgraphicscache.h4
-rw-r--r--src/gui/kernel/qplatformsurface.h5
-rw-r--r--src/gui/kernel/qplatformtheme.cpp16
-rw-r--r--src/gui/kernel/qplatformtheme.h7
-rw-r--r--src/gui/kernel/qplatformthemefactory_p.h4
-rw-r--r--src/gui/kernel/qplatformthemeplugin.h4
-rw-r--r--src/gui/kernel/qplatformwindow.cpp55
-rw-r--r--src/gui/kernel/qplatformwindow.h6
-rw-r--r--src/gui/kernel/qplatformwindow_p.h4
-rw-r--r--src/gui/kernel/qscreen.h4
-rw-r--r--src/gui/kernel/qscreen_p.h4
-rw-r--r--src/gui/kernel/qsessionmanager.h4
-rw-r--r--src/gui/kernel/qshortcutmap.cpp2
-rw-r--r--src/gui/kernel/qstylehints.h4
-rw-r--r--src/gui/kernel/qsurface.cpp1
-rw-r--r--src/gui/kernel/qsurface.h7
-rw-r--r--src/gui/kernel/qsurfaceformat.cpp24
-rw-r--r--src/gui/kernel/qsurfaceformat.h8
-rw-r--r--src/gui/kernel/qtouchdevice.h4
-rw-r--r--src/gui/kernel/qtouchdevice_p.h4
-rw-r--r--src/gui/kernel/qwindow.cpp293
-rw-r--r--src/gui/kernel/qwindow.h61
-rw-r--r--src/gui/kernel/qwindow_p.h14
-rw-r--r--src/gui/kernel/qwindowdefs.h4
-rw-r--r--src/gui/kernel/qwindowdefs_win.h4
-rw-r--r--src/gui/kernel/qwindowsysteminterface.cpp57
-rw-r--r--src/gui/kernel/qwindowsysteminterface.h15
-rw-r--r--src/gui/kernel/qwindowsysteminterface_p.h46
-rw-r--r--src/gui/math3d/qgenericmatrix.h4
-rw-r--r--src/gui/math3d/qmatrix4x4.h4
-rw-r--r--src/gui/math3d/qquaternion.cpp5
-rw-r--r--src/gui/math3d/qquaternion.h4
-rw-r--r--src/gui/math3d/qvector2d.cpp35
-rw-r--r--src/gui/math3d/qvector2d.h7
-rw-r--r--src/gui/math3d/qvector3d.cpp13
-rw-r--r--src/gui/math3d/qvector3d.h5
-rw-r--r--src/gui/math3d/qvector4d.h4
-rw-r--r--src/gui/opengl/opengl.pri68
-rw-r--r--src/gui/opengl/qopengl.h217
-rw-r--r--src/gui/opengl/qopengl2pexvertexarray_p.h6
-rw-r--r--src/gui/opengl/qopengl_p.h6
-rw-r--r--src/gui/opengl/qopenglbuffer.h6
-rw-r--r--src/gui/opengl/qopenglcustomshaderstage_p.h4
-rw-r--r--src/gui/opengl/qopengldebug.cpp1806
-rw-r--r--src/gui/opengl/qopengldebug.h220
-rw-r--r--src/gui/opengl/qopenglengineshadermanager_p.h4
-rw-r--r--src/gui/opengl/qopenglengineshadersource_p.h4
-rw-r--r--src/gui/opengl/qopengles2ext.h514
-rw-r--r--src/gui/opengl/qopenglext.h1584
-rw-r--r--src/gui/opengl/qopenglextensions_p.h4
-rw-r--r--src/gui/opengl/qopenglframebufferobject.h6
-rw-r--r--src/gui/opengl/qopenglfunctions.cpp11
-rw-r--r--src/gui/opengl/qopenglfunctions.h27
-rw-r--r--src/gui/opengl/qopenglfunctions_1_0.cpp141
-rw-r--r--src/gui/opengl/qopenglfunctions_1_0.h1930
-rw-r--r--src/gui/opengl/qopenglfunctions_1_1.cpp167
-rw-r--r--src/gui/opengl/qopenglfunctions_1_1.h2120
-rw-r--r--src/gui/opengl/qopenglfunctions_1_2.cpp193
-rw-r--r--src/gui/opengl/qopenglfunctions_1_2.h2358
-rw-r--r--src/gui/opengl/qopenglfunctions_1_3.cpp219
-rw-r--r--src/gui/opengl/qopenglfunctions_1_3.h2644
-rw-r--r--src/gui/opengl/qopenglfunctions_1_4.cpp245
-rw-r--r--src/gui/opengl/qopenglfunctions_1_4.h2924
-rw-r--r--src/gui/opengl/qopenglfunctions_1_5.cpp258
-rw-r--r--src/gui/opengl/qopenglfunctions_1_5.h3047
-rw-r--r--src/gui/opengl/qopenglfunctions_2_0.cpp284
-rw-r--r--src/gui/opengl/qopenglfunctions_2_0.h3615
-rw-r--r--src/gui/opengl/qopenglfunctions_2_1.cpp297
-rw-r--r--src/gui/opengl/qopenglfunctions_2_1.h3660
-rw-r--r--src/gui/opengl/qopenglfunctions_3_0.cpp323
-rw-r--r--src/gui/opengl/qopenglfunctions_3_0.h4174
-rw-r--r--src/gui/opengl/qopenglfunctions_3_1.cpp242
-rw-r--r--src/gui/opengl/qopenglfunctions_3_1.h1598
-rw-r--r--src/gui/opengl/qopenglfunctions_3_2_compatibility.cpp350
-rw-r--r--src/gui/opengl/qopenglfunctions_3_2_compatibility.h4378
-rw-r--r--src/gui/opengl/qopenglfunctions_3_2_core.cpp256
-rw-r--r--src/gui/opengl/qopenglfunctions_3_2_core.h1717
-rw-r--r--src/gui/opengl/qopenglfunctions_3_3_compatibility.cpp363
-rw-r--r--src/gui/opengl/qopenglfunctions_3_3_compatibility.h4735
-rw-r--r--src/gui/opengl/qopenglfunctions_3_3_core.cpp269
-rw-r--r--src/gui/opengl/qopenglfunctions_3_3_core.h2070
-rw-r--r--src/gui/opengl/qopenglfunctions_4_0_compatibility.cpp376
-rw-r--r--src/gui/opengl/qopenglfunctions_4_0_compatibility.h5020
-rw-r--r--src/gui/opengl/qopenglfunctions_4_0_core.cpp282
-rw-r--r--src/gui/opengl/qopenglfunctions_4_0_core.h2351
-rw-r--r--src/gui/opengl/qopenglfunctions_4_1_compatibility.cpp389
-rw-r--r--src/gui/opengl/qopenglfunctions_4_1_compatibility.h5557
-rw-r--r--src/gui/opengl/qopenglfunctions_4_1_core.cpp295
-rw-r--r--src/gui/opengl/qopenglfunctions_4_1_core.h2884
-rw-r--r--src/gui/opengl/qopenglfunctions_4_2_compatibility.cpp402
-rw-r--r--src/gui/opengl/qopenglfunctions_4_2_compatibility.h5638
-rw-r--r--src/gui/opengl/qopenglfunctions_4_2_core.cpp308
-rw-r--r--src/gui/opengl/qopenglfunctions_4_2_core.h2961
-rw-r--r--src/gui/opengl/qopenglfunctions_4_3_compatibility.cpp415
-rw-r--r--src/gui/opengl/qopenglfunctions_4_3_compatibility.h5845
-rw-r--r--src/gui/opengl/qopenglfunctions_4_3_core.cpp321
-rw-r--r--src/gui/opengl/qopenglfunctions_4_3_core.h3164
-rw-r--r--src/gui/opengl/qopenglfunctions_es2.cpp103
-rw-r--r--src/gui/opengl/qopenglfunctions_es2.h933
-rw-r--r--src/gui/opengl/qopenglpaintdevice.cpp14
-rw-r--r--src/gui/opengl/qopenglpaintdevice.h7
-rw-r--r--src/gui/opengl/qopenglpaintengine.cpp99
-rw-r--r--src/gui/opengl/qopenglpaintengine_p.h7
-rw-r--r--src/gui/opengl/qopenglqueryhelper_p.h177
-rw-r--r--src/gui/opengl/qopenglshadercache_meego_p.h4
-rw-r--r--src/gui/opengl/qopenglshadercache_p.h4
-rw-r--r--src/gui/opengl/qopenglshaderprogram.cpp318
-rw-r--r--src/gui/opengl/qopenglshaderprogram.h25
-rw-r--r--src/gui/opengl/qopengltexturecache.cpp7
-rw-r--r--src/gui/opengl/qopengltexturecache_p.h3
-rw-r--r--src/gui/opengl/qopengltextureglyphcache.cpp44
-rw-r--r--src/gui/opengl/qopengltimerquery.cpp876
-rw-r--r--src/gui/opengl/qopengltimerquery.h116
-rw-r--r--src/gui/opengl/qopenglversionfunctions.cpp1791
-rw-r--r--src/gui/opengl/qopenglversionfunctions.h1365
-rw-r--r--src/gui/opengl/qopenglversionfunctionsfactory.cpp153
-rw-r--r--src/gui/opengl/qopenglversionfunctionsfactory_p.h73
-rw-r--r--src/gui/opengl/qopenglvertexarrayobject.cpp473
-rw-r--r--src/gui/opengl/qopenglvertexarrayobject.h110
-rw-r--r--src/gui/opengl/qtriangulator.cpp10
-rw-r--r--src/gui/painting/qbackingstore.cpp7
-rw-r--r--src/gui/painting/qbackingstore.h4
-rw-r--r--src/gui/painting/qbrush.h13
-rw-r--r--src/gui/painting/qcolor.cpp2
-rw-r--r--src/gui/painting/qcolor.h8
-rw-r--r--src/gui/painting/qcosmeticstroker.cpp17
-rw-r--r--src/gui/painting/qcosmeticstroker_p.h4
-rw-r--r--src/gui/painting/qcssutil_p.h2
-rw-r--r--src/gui/painting/qdrawhelper.cpp2
-rw-r--r--src/gui/painting/qdrawhelper_p.h42
-rw-r--r--src/gui/painting/qemulationpaintengine_p.h10
-rw-r--r--src/gui/painting/qgrayraster.c10
-rw-r--r--src/gui/painting/qmatrix.h4
-rw-r--r--src/gui/painting/qoutlinemapper.cpp2
-rw-r--r--src/gui/painting/qpagedpaintdevice.h4
-rw-r--r--src/gui/painting/qpaintbuffer.cpp12
-rw-r--r--src/gui/painting/qpaintdevice.h4
-rw-r--r--src/gui/painting/qpaintengine.h4
-rw-r--r--src/gui/painting/qpaintengine_raster.cpp48
-rw-r--r--src/gui/painting/qpaintengine_raster_p.h4
-rw-r--r--src/gui/painting/qpaintengineex.cpp12
-rw-r--r--src/gui/painting/qpaintengineex_p.h6
-rw-r--r--src/gui/painting/qpainter.cpp44
-rw-r--r--src/gui/painting/qpainter.h4
-rw-r--r--src/gui/painting/qpainterpath.h4
-rw-r--r--src/gui/painting/qpathclipper.cpp4
-rw-r--r--src/gui/painting/qpathclipper_p.h4
-rw-r--r--src/gui/painting/qpdfwriter.h4
-rw-r--r--src/gui/painting/qpen.h4
-rw-r--r--src/gui/painting/qplatformbackingstore.h4
-rw-r--r--src/gui/painting/qpolygon.h4
-rw-r--r--src/gui/painting/qrasterizer.cpp2
-rw-r--r--src/gui/painting/qregion.h4
-rw-r--r--src/gui/painting/qrgb.h7
-rw-r--r--src/gui/painting/qtextureglyphcache.cpp25
-rw-r--r--src/gui/painting/qtextureglyphcache_p.h4
-rw-r--r--src/gui/painting/qtransform.h8
-rw-r--r--src/gui/painting/qvectorpath_p.h4
-rw-r--r--src/gui/text/qabstractfontengine_p.h108
-rw-r--r--src/gui/text/qabstracttextdocumentlayout.cpp2
-rw-r--r--src/gui/text/qabstracttextdocumentlayout.h4
-rw-r--r--src/gui/text/qcssparser.cpp8
-rw-r--r--src/gui/text/qfont.cpp207
-rw-r--r--src/gui/text/qfont.h4
-rw-r--r--src/gui/text/qfont_p.h12
-rw-r--r--src/gui/text/qfont_qpa.cpp2
-rw-r--r--src/gui/text/qfontdatabase.cpp206
-rw-r--r--src/gui/text/qfontdatabase.h4
-rw-r--r--src/gui/text/qfontdatabase_qpa.cpp17
-rw-r--r--src/gui/text/qfontengine.cpp129
-rw-r--r--src/gui/text/qfontengine_ft.cpp75
-rw-r--r--src/gui/text/qfontengine_ft_p.h8
-rw-r--r--src/gui/text/qfontengine_p.h35
-rw-r--r--src/gui/text/qfontengine_qpa.cpp4
-rw-r--r--src/gui/text/qfontengine_qpa_p.h4
-rw-r--r--src/gui/text/qfontengine_qpf.cpp9
-rw-r--r--src/gui/text/qfontengine_qpf_p.h2
-rw-r--r--src/gui/text/qfontengineglyphcache_p.h1
-rw-r--r--src/gui/text/qfontinfo.h4
-rw-r--r--src/gui/text/qfontmetrics.cpp98
-rw-r--r--src/gui/text/qfontmetrics.h4
-rw-r--r--src/gui/text/qglyphrun.h4
-rw-r--r--src/gui/text/qglyphrun_p.h4
-rw-r--r--src/gui/text/qharfbuzz_copy_p.h95
-rw-r--r--src/gui/text/qplatformfontdatabase.cpp108
-rw-r--r--src/gui/text/qplatformfontdatabase.h13
-rw-r--r--src/gui/text/qrawfont.cpp82
-rw-r--r--src/gui/text/qrawfont.h24
-rw-r--r--src/gui/text/qstatictext.cpp22
-rw-r--r--src/gui/text/qstatictext.h6
-rw-r--r--src/gui/text/qstatictext_p.h2
-rw-r--r--src/gui/text/qsyntaxhighlighter.cpp2
-rw-r--r--src/gui/text/qsyntaxhighlighter.h4
-rw-r--r--src/gui/text/qtextcursor.h4
-rw-r--r--src/gui/text/qtextdocument.cpp4
-rw-r--r--src/gui/text/qtextdocument.h4
-rw-r--r--src/gui/text/qtextdocumentfragment.h4
-rw-r--r--src/gui/text/qtextdocumentwriter.h4
-rw-r--r--src/gui/text/qtextengine.cpp194
-rw-r--r--src/gui/text/qtextengine_p.h60
-rw-r--r--src/gui/text/qtextformat.cpp1
-rw-r--r--src/gui/text/qtextformat.h4
-rw-r--r--src/gui/text/qtextlayout.cpp67
-rw-r--r--src/gui/text/qtextlayout.h4
-rw-r--r--src/gui/text/qtextlist.h4
-rw-r--r--src/gui/text/qtextobject.cpp2
-rw-r--r--src/gui/text/qtextobject.h4
-rw-r--r--src/gui/text/qtextodfwriter.cpp14
-rw-r--r--src/gui/text/qtextodfwriter_p.h3
-rw-r--r--src/gui/text/qtextoption.cpp2
-rw-r--r--src/gui/text/qtextoption.h4
-rw-r--r--src/gui/text/qtexttable.cpp6
-rw-r--r--src/gui/text/qtexttable.h4
-rw-r--r--src/gui/text/qzip.cpp12
-rw-r--r--src/gui/text/qzipreader_p.h2
-rw-r--r--src/gui/text/qzipwriter_p.h3
-rw-r--r--src/gui/text/text.pri1
-rw-r--r--src/gui/util/qdesktopservices.h4
-rw-r--r--src/gui/util/qvalidator.cpp159
-rw-r--r--src/gui/util/qvalidator.h37
-rw-r--r--src/network/access/qabstractnetworkcache.h4
-rw-r--r--src/network/access/qftp_p.h4
-rw-r--r--src/network/access/qhttpmultipart.cpp1
-rw-r--r--src/network/access/qhttpmultipart.h4
-rw-r--r--src/network/access/qhttpnetworkconnection.cpp14
-rw-r--r--src/network/access/qhttpnetworkconnection_p.h9
-rw-r--r--src/network/access/qhttpnetworkconnectionchannel.cpp21
-rw-r--r--src/network/access/qhttpnetworkconnectionchannel_p.h2
-rw-r--r--src/network/access/qhttpnetworkreply_p.h1
-rw-r--r--src/network/access/qhttpthreaddelegate.cpp9
-rw-r--r--src/network/access/qhttpthreaddelegate_p.h2
-rw-r--r--src/network/access/qnetworkaccessbackend.cpp7
-rw-r--r--src/network/access/qnetworkaccessbackend_p.h1
-rw-r--r--src/network/access/qnetworkaccessdebugpipebackend.cpp2
-rw-r--r--src/network/access/qnetworkaccessfilebackend.cpp18
-rw-r--r--src/network/access/qnetworkaccessmanager.cpp74
-rw-r--r--src/network/access/qnetworkaccessmanager.h6
-rw-r--r--src/network/access/qnetworkaccessmanager_p.h1
-rw-r--r--src/network/access/qnetworkcookie.h4
-rw-r--r--src/network/access/qnetworkcookiejar.h4
-rw-r--r--src/network/access/qnetworkdiskcache.h4
-rw-r--r--src/network/access/qnetworkreply.cpp25
-rw-r--r--src/network/access/qnetworkreply.h5
-rw-r--r--src/network/access/qnetworkreplyfileimpl.cpp12
-rw-r--r--src/network/access/qnetworkreplyhttpimpl.cpp12
-rw-r--r--src/network/access/qnetworkreplyhttpimpl_p.h2
-rw-r--r--src/network/access/qnetworkreplyimpl.cpp8
-rw-r--r--src/network/access/qnetworkreplyimpl_p.h1
-rw-r--r--src/network/access/qnetworkrequest.h4
-rw-r--r--src/network/bearer/qbearerplugin_p.h4
-rw-r--r--src/network/bearer/qnetworkconfigmanager.cpp8
-rw-r--r--src/network/bearer/qnetworkconfigmanager.h4
-rw-r--r--src/network/bearer/qnetworkconfigmanager_p.cpp2
-rw-r--r--src/network/bearer/qnetworkconfiguration.h4
-rw-r--r--src/network/bearer/qnetworksession.cpp108
-rw-r--r--src/network/bearer/qnetworksession.h4
-rw-r--r--src/network/bearer/qnetworksession_p.h2
-rw-r--r--src/network/doc/snippets/code/src_network_socket_qabstractsocket.cpp2
-rw-r--r--src/network/doc/snippets/network/tcpwait.cpp8
-rw-r--r--src/network/kernel/kernel.pri8
-rw-r--r--src/network/kernel/qauthenticator.cpp1
-rw-r--r--src/network/kernel/qauthenticator.h6
-rw-r--r--src/network/kernel/qdnslookup.h4
-rw-r--r--src/network/kernel/qhostaddress.cpp2
-rw-r--r--src/network/kernel/qhostaddress.h3
-rw-r--r--src/network/kernel/qhostinfo.cpp13
-rw-r--r--src/network/kernel/qhostinfo.h4
-rw-r--r--src/network/kernel/qhostinfo_unix.cpp2
-rw-r--r--src/network/kernel/qnetworkfunctions_wince.h4
-rw-r--r--src/network/kernel/qnetworkinterface.h6
-rw-r--r--src/network/kernel/qnetworkinterface_unix.cpp6
-rw-r--r--src/network/kernel/qnetworkinterface_win.cpp2
-rw-r--r--src/network/kernel/qnetworkinterface_win_p.h32
-rw-r--r--src/network/kernel/qnetworkproxy.cpp2
-rw-r--r--src/network/kernel/qnetworkproxy.h4
-rw-r--r--src/network/kernel/qnetworkproxy_blackberry.cpp30
-rw-r--r--src/network/kernel/qnetworkproxy_mac.cpp5
-rw-r--r--src/network/kernel/qurlinfo_p.h4
-rw-r--r--src/network/socket/qabstractsocket.cpp12
-rw-r--r--src/network/socket/qabstractsocket.h4
-rw-r--r--src/network/socket/qlocalserver.h4
-rw-r--r--src/network/socket/qlocalserver_unix.cpp4
-rw-r--r--src/network/socket/qlocalsocket.cpp75
-rw-r--r--src/network/socket/qlocalsocket.h7
-rw-r--r--src/network/socket/qlocalsocket_tcp.cpp22
-rw-r--r--src/network/socket/qlocalsocket_unix.cpp15
-rw-r--r--src/network/socket/qlocalsocket_win.cpp18
-rw-r--r--src/network/socket/qnativesocketengine.cpp16
-rw-r--r--src/network/socket/qnativesocketengine_unix.cpp8
-rw-r--r--src/network/socket/qnativesocketengine_win.cpp2
-rw-r--r--src/network/socket/qtcpserver.h4
-rw-r--r--src/network/socket/qtcpsocket.cpp2
-rw-r--r--src/network/socket/qtcpsocket.h4
-rw-r--r--src/network/socket/qudpsocket.h4
-rw-r--r--src/network/ssl/qssl.cpp2
-rw-r--r--src/network/ssl/qssl.h4
-rw-r--r--src/network/ssl/qsslcertificate.h4
-rw-r--r--src/network/ssl/qsslcertificateextension.h4
-rw-r--r--src/network/ssl/qsslcipher.cpp2
-rw-r--r--src/network/ssl/qsslcipher.h4
-rw-r--r--src/network/ssl/qsslconfiguration.cpp56
-rw-r--r--src/network/ssl/qsslconfiguration.h9
-rw-r--r--src/network/ssl/qsslconfiguration_p.h7
-rw-r--r--src/network/ssl/qsslcontext.cpp309
-rw-r--r--src/network/ssl/qsslcontext_p.h88
-rw-r--r--src/network/ssl/qsslerror.cpp4
-rw-r--r--src/network/ssl/qsslerror.h6
-rw-r--r--src/network/ssl/qsslkey.h4
-rw-r--r--src/network/ssl/qsslsocket.cpp74
-rw-r--r--src/network/ssl/qsslsocket.h7
-rw-r--r--src/network/ssl/qsslsocket_openssl.cpp307
-rw-r--r--src/network/ssl/qsslsocket_openssl_p.h5
-rw-r--r--src/network/ssl/qsslsocket_openssl_symbols.cpp48
-rw-r--r--src/network/ssl/qsslsocket_openssl_symbols_p.h4
-rw-r--r--src/network/ssl/qsslsocket_p.h11
-rw-r--r--src/network/ssl/ssl.pri6
-rw-r--r--src/opengl/doc/src/qtopengl-examples.qdoc2
-rw-r--r--src/opengl/gl2paintengineex/qgl2pexvertexarray_p.h6
-rw-r--r--src/opengl/gl2paintengineex/qglcustomshaderstage_p.h4
-rw-r--r--src/opengl/gl2paintengineex/qglengineshadermanager_p.h4
-rw-r--r--src/opengl/gl2paintengineex/qglengineshadersource_p.h4
-rw-r--r--src/opengl/gl2paintengineex/qglshadercache_meego_p.h4
-rw-r--r--src/opengl/gl2paintengineex/qglshadercache_p.h4
-rw-r--r--src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp127
-rw-r--r--src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h13
-rw-r--r--src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp21
-rw-r--r--src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h7
-rw-r--r--src/opengl/opengl.pro5
-rw-r--r--src/opengl/qgl.cpp309
-rw-r--r--src/opengl/qgl.h4
-rw-r--r--src/opengl/qgl_p.h79
-rw-r--r--src/opengl/qglbuffer.cpp44
-rw-r--r--src/opengl/qglbuffer.h4
-rw-r--r--src/opengl/qglcolormap.h4
-rw-r--r--src/opengl/qglextensions.cpp414
-rw-r--r--src/opengl/qglextensions_p.h587
-rw-r--r--src/opengl/qglframebufferobject.cpp149
-rw-r--r--src/opengl/qglframebufferobject.h3
-rw-r--r--src/opengl/qglframebufferobject_p.h3
-rw-r--r--src/opengl/qglfunctions.cpp7
-rw-r--r--src/opengl/qglfunctions.h4
-rw-r--r--src/opengl/qglpixelbuffer.h4
-rw-r--r--src/opengl/qglshaderprogram.cpp299
-rw-r--r--src/opengl/qglshaderprogram.h4
-rw-r--r--src/opengl/qgraphicsshadereffect_p.h4
-rw-r--r--src/opengl/qtopenglglobal.h4
-rw-r--r--src/openglextensions/openglextensions.pro15
-rw-r--r--src/openglextensions/qopenglextensions.cpp7713
-rw-r--r--src/openglextensions/qopenglextensions.h19469
-rw-r--r--src/platformsupport/cfsocketnotifier/cfsocketnotifier.pri4
-rw-r--r--src/platformsupport/cfsocketnotifier/qcfsocketnotifier.cpp255
-rw-r--r--src/platformsupport/cfsocketnotifier/qcfsocketnotifier_p.h90
-rw-r--r--src/platformsupport/cglconvenience/cglconvenience.mm11
-rw-r--r--src/platformsupport/cglconvenience/cglconvenience_p.h1
-rw-r--r--src/platformsupport/devicediscovery/devicediscovery.pri2
-rw-r--r--src/platformsupport/dnd/qshapedpixmapdndwindow.cpp4
-rw-r--r--src/platformsupport/dnd/qshapedpixmapdndwindow_p.h4
-rw-r--r--src/platformsupport/dnd/qsimpledrag.cpp4
-rw-r--r--src/platformsupport/dnd/qsimpledrag_p.h5
-rw-r--r--src/platformsupport/eglconvenience/eglconvenience.pri7
-rw-r--r--src/platformsupport/eglconvenience/qeglconvenience.cpp115
-rw-r--r--src/platformsupport/eglconvenience/qeglconvenience_p.h35
-rw-r--r--src/platformsupport/eglconvenience/qeglpbuffer.cpp76
-rw-r--r--src/platformsupport/eglconvenience/qeglpbuffer_p.h69
-rw-r--r--src/platformsupport/eglconvenience/qeglplatformcontext.cpp18
-rw-r--r--src/platformsupport/eglconvenience/qeglplatformcontext_p.h6
-rw-r--r--src/platformsupport/fbconvenience/qfbcursor.cpp2
-rw-r--r--src/platformsupport/fbconvenience/qfbscreen.cpp51
-rw-r--r--src/platformsupport/fbconvenience/qfbscreen_p.h6
-rw-r--r--src/platformsupport/fbconvenience/qfbwindow.cpp3
-rw-r--r--src/platformsupport/fbconvenience/qfbwindow_p.h2
-rw-r--r--src/platformsupport/fontdatabases/basic/qbasicfontdatabase.cpp137
-rw-r--r--src/platformsupport/fontdatabases/basic/qbasicfontdatabase_p.h5
-rw-r--r--src/platformsupport/fontdatabases/fontconfig/qfontconfigdatabase.cpp171
-rw-r--r--src/platformsupport/fontdatabases/fontconfig/qfontconfigdatabase_p.h6
-rw-r--r--src/platformsupport/fontdatabases/fontdatabases.pri2
-rw-r--r--src/platformsupport/fontdatabases/genericunix/qgenericunixfontdatabase_p.h2
-rw-r--r--src/platformsupport/fontdatabases/mac/coretext.pri8
-rw-r--r--src/platformsupport/fontdatabases/mac/qcoretextfontdatabase.mm211
-rw-r--r--src/platformsupport/fontdatabases/mac/qcoretextfontdatabase_p.h7
-rw-r--r--src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm90
-rw-r--r--src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h12
-rw-r--r--src/platformsupport/glxconvenience/qglxconvenience.cpp23
-rw-r--r--src/platformsupport/glxconvenience/qglxconvenience_p.h2
-rw-r--r--src/platformsupport/input/evdevkeyboard/qevdevkeyboardhandler_p.h4
-rw-r--r--src/platformsupport/input/evdevkeyboard/qevdevkeyboardmanager.cpp8
-rw-r--r--src/platformsupport/input/evdevkeyboard/qevdevkeyboardmanager_p.h4
-rw-r--r--src/platformsupport/input/evdevmouse/qevdevmousehandler_p.h4
-rw-r--r--src/platformsupport/input/evdevmouse/qevdevmousemanager.cpp7
-rw-r--r--src/platformsupport/input/evdevmouse/qevdevmousemanager_p.h4
-rw-r--r--src/platformsupport/input/evdevtablet/qevdevtablet_p.h4
-rw-r--r--src/platformsupport/input/evdevtouch/qevdevtouch.cpp8
-rw-r--r--src/platformsupport/input/evdevtouch/qevdevtouch_p.h6
-rw-r--r--src/platformsupport/jniconvenience/jniconvenience.pri9
-rw-r--r--src/platformsupport/jniconvenience/qjnihelpers.cpp115
-rw-r--r--src/platformsupport/jniconvenience/qjnihelpers_p.h191
-rw-r--r--src/platformsupport/jniconvenience/qjniobject.cpp3098
-rw-r--r--src/platformsupport/jniconvenience/qjniobject_p.h169
-rw-r--r--src/platformsupport/linuxaccessibility/application.cpp14
-rw-r--r--src/platformsupport/linuxaccessibility/application_p.h5
-rw-r--r--src/platformsupport/linuxaccessibility/atspiadaptor.cpp257
-rw-r--r--src/platformsupport/linuxaccessibility/atspiadaptor_p.h55
-rw-r--r--src/platformsupport/linuxaccessibility/bridge_p.h2
-rw-r--r--src/platformsupport/linuxaccessibility/cache_p.h2
-rw-r--r--src/platformsupport/linuxaccessibility/constant_mappings_p.h2
-rw-r--r--src/platformsupport/linuxaccessibility/dbusconnection_p.h2
-rw-r--r--src/platformsupport/linuxaccessibility/struct_marshallers_p.h2
-rw-r--r--src/platformsupport/platformsupport.pro4
-rw-r--r--src/platformsupport/services/genericunix/qgenericunixservices_p.h4
-rw-r--r--src/platformsupport/themes/genericunix/qgenericunixthemes.cpp5
-rw-r--r--src/platformsupport/themes/genericunix/qgenericunixthemes_p.h4
-rw-r--r--src/plugins/accessible/widgets/complexwidgets.cpp12
-rw-r--r--src/plugins/accessible/widgets/complexwidgets.h7
-rw-r--r--src/plugins/accessible/widgets/itemviews.cpp517
-rw-r--r--src/plugins/accessible/widgets/itemviews.h38
-rw-r--r--src/plugins/accessible/widgets/main.cpp24
-rw-r--r--src/plugins/accessible/widgets/qaccessiblemenu.cpp24
-rw-r--r--src/plugins/accessible/widgets/qaccessiblemenu.h2
-rw-r--r--src/plugins/accessible/widgets/qaccessiblewidgets.cpp95
-rw-r--r--src/plugins/accessible/widgets/qaccessiblewidgets.h12
-rw-r--r--src/plugins/accessible/widgets/rangecontrols.h4
-rw-r--r--src/plugins/accessible/widgets/simplewidgets.cpp7
-rw-r--r--src/plugins/accessible/widgets/simplewidgets.h10
-rw-r--r--src/plugins/accessible/widgets/widgets.json8
-rw-r--r--src/plugins/bearer/bearer.pro4
-rw-r--r--src/plugins/bearer/connman/qconnmanengine.cpp6
-rw-r--r--src/plugins/bearer/connman/qconnmanservice_linux.cpp4
-rw-r--r--src/plugins/bearer/connman/qconnmanservice_linux_p.h2
-rw-r--r--src/plugins/bearer/connman/qofonoservice_linux.cpp40
-rw-r--r--src/plugins/bearer/connman/qofonoservice_linux_p.h8
-rw-r--r--src/plugins/bearer/corewlan/corewlan.pro4
-rw-r--r--src/plugins/bearer/networkmanager/qnetworkmanagerservice.h84
-rw-r--r--src/plugins/bearer/qnetworksession_impl.h2
-rw-r--r--src/plugins/generic/evdevtouch/README2
-rw-r--r--src/plugins/generic/generic.pro4
-rw-r--r--src/plugins/generic/meego/qmeegointegration.h4
-rw-r--r--src/plugins/generic/tslib/qtslib.h4
-rw-r--r--src/plugins/imageformats/gif/gif.json3
-rw-r--r--src/plugins/imageformats/ico/ico.json3
-rw-r--r--src/plugins/imageformats/ico/qicohandler.cpp2
-rw-r--r--src/plugins/imageformats/ico/qicohandler.h6
-rw-r--r--src/plugins/imageformats/jpeg/jpeg.json3
-rw-r--r--src/plugins/platforminputcontexts/compose/compose.json3
-rw-r--r--src/plugins/platforminputcontexts/compose/compose.pro20
-rw-r--r--src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp401
-rw-r--r--src/plugins/platforminputcontexts/compose/generator/qtablegenerator.h128
-rw-r--r--src/plugins/platforminputcontexts/compose/main.cpp70
-rw-r--r--src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.cpp268
-rw-r--r--src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.h85
-rw-r--r--src/plugins/platforminputcontexts/compose/xkbcommon_workaround.h105
-rw-r--r--src/plugins/platforminputcontexts/ibus/qibusplatforminputcontext.cpp20
-rw-r--r--src/plugins/platforminputcontexts/platforminputcontexts.pro8
-rw-r--r--src/plugins/platforms/android/android.pro3
-rw-r--r--src/plugins/platforms/android/opengl/opengl.pro30
-rw-r--r--src/plugins/platforms/android/raster/raster.pro19
-rw-r--r--src/plugins/platforms/android/src/android.json3
-rw-r--r--src/plugins/platforms/android/src/androidjniclipboard.cpp120
-rw-r--r--src/plugins/platforms/android/src/androidjniclipboard.h61
-rw-r--r--src/plugins/platforms/android/src/androidjniinput.cpp497
-rw-r--r--src/plugins/platforms/android/src/androidjniinput.h59
-rw-r--r--src/plugins/platforms/android/src/androidjnimain.cpp831
-rw-r--r--src/plugins/platforms/android/src/androidjnimain.h122
-rw-r--r--src/plugins/platforms/android/src/androidjnimenu.cpp422
-rw-r--r--src/plugins/platforms/android/src/androidjnimenu.h69
-rw-r--r--src/plugins/platforms/android/src/androidplatformplugin.cpp66
-rw-r--r--src/plugins/platforms/android/src/opengl/qandroidopenglcontext.cpp (renamed from mkspecs/common/ios/qplatformdefs.h)95
-rw-r--r--src/plugins/platforms/android/src/opengl/qandroidopenglcontext.h68
-rw-r--r--src/plugins/platforms/android/src/opengl/qandroidopenglplatformwindow.cpp72
-rw-r--r--src/plugins/platforms/android/src/opengl/qandroidopenglplatformwindow.h73
-rw-r--r--src/plugins/platforms/android/src/opengl/qeglfshooks_android.cpp139
-rw-r--r--src/plugins/platforms/android/src/qandroidassetsfileenginehandler.cpp288
-rw-r--r--src/plugins/platforms/android/src/qandroidassetsfileenginehandler.h60
-rw-r--r--src/plugins/platforms/android/src/qandroidinputcontext.cpp653
-rw-r--r--src/plugins/platforms/android/src/qandroidinputcontext.h132
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformclipboard.cpp79
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformclipboard.h63
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformfontdatabase.cpp79
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformfontdatabase.h58
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformintegration.cpp285
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformintegration.h164
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformmenu.cpp167
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformmenu.h91
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformmenubar.cpp109
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformmenubar.h74
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformmenuitem.cpp180
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformmenuitem.h99
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformservices.cpp83
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformservices.h61
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformtheme.cpp78
-rw-r--r--src/plugins/platforms/android/src/qandroidplatformtheme.h56
-rw-r--r--src/plugins/platforms/android/src/raster/qandroidplatformscreen.cpp77
-rw-r--r--src/plugins/platforms/android/src/raster/qandroidplatformscreen.h60
-rw-r--r--src/plugins/platforms/android/src/raster/qandroidplatformwindow.cpp56
-rw-r--r--src/plugins/platforms/android/src/raster/qandroidplatformwindow.h60
-rw-r--r--src/plugins/platforms/android/src/raster/raster.pri7
-rw-r--r--src/plugins/platforms/android/src/src.pri47
-rw-r--r--src/plugins/platforms/cocoa/cocoa.pro5
-rw-r--r--src/plugins/platforms/cocoa/qcocoaaccessibility.h7
-rw-r--r--src/plugins/platforms/cocoa/qcocoaaccessibility.mm17
-rw-r--r--src/plugins/platforms/cocoa/qcocoaaccessibilityelement.h13
-rw-r--r--src/plugins/platforms/cocoa/qcocoaaccessibilityelement.mm121
-rw-r--r--src/plugins/platforms/cocoa/qcocoaapplicationdelegate.h13
-rw-r--r--src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm4
-rw-r--r--src/plugins/platforms/cocoa/qcocoabackingstore.mm10
-rw-r--r--src/plugins/platforms/cocoa/qcocoacursor.mm7
-rw-r--r--src/plugins/platforms/cocoa/qcocoaeventdispatcher.h12
-rw-r--r--src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm239
-rw-r--r--src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm38
-rw-r--r--src/plugins/platforms/cocoa/qcocoaglcontext.mm16
-rw-r--r--src/plugins/platforms/cocoa/qcocoahelpers.h2
-rw-r--r--src/plugins/platforms/cocoa/qcocoahelpers.mm38
-rw-r--r--src/plugins/platforms/cocoa/qcocoaintegration.h2
-rw-r--r--src/plugins/platforms/cocoa/qcocoaintegration.mm41
-rw-r--r--src/plugins/platforms/cocoa/qcocoaintrospection.mm4
-rw-r--r--src/plugins/platforms/cocoa/qcocoakeymapper.h1
-rw-r--r--src/plugins/platforms/cocoa/qcocoamenu.h12
-rw-r--r--src/plugins/platforms/cocoa/qcocoamenu.mm35
-rw-r--r--src/plugins/platforms/cocoa/qcocoamenubar.mm4
-rw-r--r--src/plugins/platforms/cocoa/qcocoamenuitem.h5
-rw-r--r--src/plugins/platforms/cocoa/qcocoamenuitem.mm11
-rw-r--r--src/plugins/platforms/cocoa/qcocoamenuloader.h2
-rw-r--r--src/plugins/platforms/cocoa/qcocoamenuloader.mm10
-rw-r--r--src/plugins/platforms/cocoa/qcocoanativeinterface.h19
-rw-r--r--src/plugins/platforms/cocoa/qcocoanativeinterface.mm38
-rw-r--r--src/plugins/platforms/cocoa/qcocoaprintersupport.h1
-rw-r--r--src/plugins/platforms/cocoa/qcocoaprintersupport.mm31
-rw-r--r--src/plugins/platforms/cocoa/qcocoasystemsettings.mm9
-rwxr-xr-xsrc/plugins/platforms/cocoa/qcocoasystemtrayicon.h2
-rwxr-xr-xsrc/plugins/platforms/cocoa/qcocoasystemtrayicon.mm47
-rw-r--r--src/plugins/platforms/cocoa/qcocoatheme.mm2
-rw-r--r--src/plugins/platforms/cocoa/qcocoawindow.h14
-rw-r--r--src/plugins/platforms/cocoa/qcocoawindow.mm124
-rw-r--r--src/plugins/platforms/cocoa/qmacdefines_mac.h4
-rw-r--r--src/plugins/platforms/cocoa/qmultitouch_mac.mm5
-rw-r--r--src/plugins/platforms/cocoa/qmultitouch_mac_p.h4
-rw-r--r--src/plugins/platforms/cocoa/qnsview.h5
-rw-r--r--src/plugins/platforms/cocoa/qnsview.mm176
-rw-r--r--src/plugins/platforms/cocoa/qnsviewaccessibility.mm15
-rw-r--r--src/plugins/platforms/cocoa/qnswindowdelegate.h20
-rw-r--r--src/plugins/platforms/cocoa/qpaintengine_mac.mm25
-rw-r--r--src/plugins/platforms/cocoa/qpaintengine_mac_p.h41
-rw-r--r--src/plugins/platforms/cocoa/qprintengine_mac.mm56
-rw-r--r--src/plugins/platforms/cocoa/qprintengine_mac_p.h3
-rw-r--r--src/plugins/platforms/directfb/qdirectfbcursor.cpp5
-rw-r--r--src/plugins/platforms/eglfs/eglfs.pri44
-rw-r--r--src/plugins/platforms/eglfs/eglfs.pro46
-rw-r--r--src/plugins/platforms/eglfs/qeglfscontext.cpp22
-rw-r--r--src/plugins/platforms/eglfs/qeglfscursor.cpp7
-rw-r--r--src/plugins/platforms/eglfs/qeglfshooks.h22
-rw-r--r--src/plugins/platforms/eglfs/qeglfshooks_stub.cpp143
-rw-r--r--src/plugins/platforms/eglfs/qeglfsintegration.cpp52
-rw-r--r--src/plugins/platforms/eglfs/qeglfsintegration.h12
-rw-r--r--src/plugins/platforms/eglfs/qeglfsscreen.cpp19
-rw-r--r--src/plugins/platforms/eglfs/qeglfsscreen.h3
-rw-r--r--src/plugins/platforms/eglfs/qeglfswindow.cpp37
-rw-r--r--src/plugins/platforms/eglfs/qeglfswindow.h4
-rw-r--r--src/plugins/platforms/ios/ios.json3
-rw-r--r--src/plugins/platforms/ios/ios.pro3
-rw-r--r--src/plugins/platforms/ios/plugin.mm69
-rw-r--r--src/plugins/platforms/ios/plugin.pro36
-rw-r--r--src/plugins/platforms/ios/qiosapplicationdelegate.h (renamed from mkspecs/unsupported/macx-iosdevice-g++-legacy/qplatformdefs.h)15
-rw-r--r--src/plugins/platforms/ios/qiosapplicationdelegate.mm94
-rw-r--r--src/plugins/platforms/ios/qiosbackingstore.h70
-rw-r--r--src/plugins/platforms/ios/qiosbackingstore.mm125
-rw-r--r--src/plugins/platforms/ios/qioscontext.h91
-rw-r--r--src/plugins/platforms/ios/qioscontext.mm204
-rw-r--r--src/plugins/platforms/ios/qioseventdispatcher.h133
-rw-r--r--src/plugins/platforms/ios/qioseventdispatcher.mm322
-rw-r--r--src/plugins/platforms/ios/qiosglobal.h67
-rw-r--r--src/plugins/platforms/ios/qiosglobal.mm144
-rw-r--r--src/plugins/platforms/ios/qiosinputcontext.h73
-rw-r--r--src/plugins/platforms/ios/qiosinputcontext.mm142
-rw-r--r--src/plugins/platforms/ios/qiosintegration.h88
-rw-r--r--src/plugins/platforms/ios/qiosintegration.mm180
-rw-r--r--src/plugins/platforms/ios/qiosscreen.h88
-rw-r--r--src/plugins/platforms/ios/qiosscreen.mm238
-rw-r--r--src/plugins/platforms/ios/qiossoftwareinputhandler.h71
-rw-r--r--src/plugins/platforms/ios/qiostheme.h68
-rw-r--r--src/plugins/platforms/ios/qiostheme.mm96
-rw-r--r--src/plugins/platforms/ios/qiosviewcontroller.h (renamed from mkspecs/common/ios/GLES/gl.h)9
-rw-r--r--src/plugins/platforms/ios/qiosviewcontroller.mm90
-rw-r--r--src/plugins/platforms/ios/qioswindow.h103
-rw-r--r--src/plugins/platforms/ios/qioswindow.mm523
-rw-r--r--src/plugins/platforms/ios/qtmain.mm93
-rw-r--r--src/plugins/platforms/ios/qtmain.pro8
-rw-r--r--src/plugins/platforms/kms/kms.pro5
-rw-r--r--src/plugins/platforms/kms/qkmscursor.cpp68
-rw-r--r--src/plugins/platforms/kms/qkmscursor.h10
-rw-r--r--src/plugins/platforms/kms/qkmsscreen.cpp12
-rw-r--r--src/plugins/platforms/minimalegl/qminimaleglbackingstore.cpp1
-rw-r--r--src/plugins/platforms/minimalegl/qminimaleglintegration.h3
-rw-r--r--src/plugins/platforms/offscreen/main.cpp67
-rw-r--r--src/plugins/platforms/offscreen/offscreen.json3
-rw-r--r--src/plugins/platforms/offscreen/offscreen.pro25
-rw-r--r--src/plugins/platforms/offscreen/qoffscreencommon.cpp229
-rw-r--r--src/plugins/platforms/offscreen/qoffscreencommon.h109
-rw-r--r--src/plugins/platforms/offscreen/qoffscreenintegration.cpp162
-rw-r--r--src/plugins/platforms/offscreen/qoffscreenintegration.h80
-rw-r--r--src/plugins/platforms/offscreen/qoffscreenintegration_dummy.cpp (renamed from src/corelib/io/qfilesystemengine_mac.cpp)15
-rw-r--r--src/plugins/platforms/offscreen/qoffscreenintegration_x11.cpp252
-rw-r--r--src/plugins/platforms/offscreen/qoffscreenintegration_x11.h108
-rw-r--r--src/plugins/platforms/offscreen/qoffscreenwindow.cpp199
-rw-r--r--src/plugins/platforms/offscreen/qoffscreenwindow.h86
-rw-r--r--src/plugins/platforms/platforms.pro9
-rw-r--r--src/plugins/platforms/qnx/qnx.pro7
-rw-r--r--src/plugins/platforms/qnx/qqnxabstractnavigator.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxbpseventfilter.cpp24
-rw-r--r--src/plugins/platforms/qnx/qqnxbuffer.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxbuttoneventnotifier.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxclipboard.cpp4
-rw-r--r--src/plugins/platforms/qnx/qqnxclipboard.h4
-rw-r--r--src/plugins/platforms/qnx/qqnxcursor.cpp78
-rw-r--r--src/plugins/platforms/qnx/qqnxcursor.h (renamed from mkspecs/unsupported/linux-android-x86-g++/qplatformdefs.h)33
-rw-r--r--src/plugins/platforms/qnx/qqnxfiledialoghelper.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxglcontext.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp4
-rw-r--r--src/plugins/platforms/qnx/qqnxinputcontext_noimf.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxintegration.cpp4
-rw-r--r--src/plugins/platforms/qnx/qqnxnavigatoreventhandler.cpp8
-rw-r--r--src/plugins/platforms/qnx/qqnxnavigatoreventhandler.h2
-rw-r--r--src/plugins/platforms/qnx/qqnxnavigatoreventnotifier.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxnavigatorpps.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxrasterbackingstore.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxrootwindow.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxscreen.cpp56
-rw-r--r--src/plugins/platforms/qnx/qqnxscreen.h7
-rw-r--r--src/plugins/platforms/qnx/qqnxscreeneventhandler.cpp4
-rw-r--r--src/plugins/platforms/qnx/qqnxscreeneventthread.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxtheme.cpp4
-rw-r--r--src/plugins/platforms/qnx/qqnxvirtualkeyboardbps.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxvirtualkeyboardpps.cpp2
-rw-r--r--src/plugins/platforms/qnx/qqnxvirtualkeyboardpps.h6
-rw-r--r--src/plugins/platforms/qnx/qqnxwindow.cpp64
-rw-r--r--src/plugins/platforms/qnx/qqnxwindow.h9
-rw-r--r--src/plugins/platforms/windows/accessible/iaccessible2.cpp239
-rw-r--r--src/plugins/platforms/windows/accessible/iaccessible2.h14
-rw-r--r--src/plugins/platforms/windows/accessible/qwindowsaccessibility.cpp65
-rw-r--r--src/plugins/platforms/windows/accessible/qwindowsaccessibility.h4
-rw-r--r--src/plugins/platforms/windows/accessible/qwindowsmsaaaccessible.cpp183
-rw-r--r--src/plugins/platforms/windows/accessible/qwindowsmsaaaccessible.h25
-rw-r--r--src/plugins/platforms/windows/qtwindows_additional.h4
-rw-r--r--src/plugins/platforms/windows/qwindowscontext.cpp94
-rw-r--r--src/plugins/platforms/windows/qwindowscursor.cpp35
-rw-r--r--src/plugins/platforms/windows/qwindowscursor.h5
-rw-r--r--src/plugins/platforms/windows/qwindowsdialoghelpers.cpp577
-rw-r--r--src/plugins/platforms/windows/qwindowsdialoghelpers.h10
-rw-r--r--src/plugins/platforms/windows/qwindowsdrag.cpp6
-rw-r--r--src/plugins/platforms/windows/qwindowsfontdatabase.cpp215
-rw-r--r--src/plugins/platforms/windows/qwindowsfontdatabase.h4
-rw-r--r--src/plugins/platforms/windows/qwindowsfontdatabase_ft.cpp96
-rw-r--r--src/plugins/platforms/windows/qwindowsfontdatabase_ft.h4
-rw-r--r--src/plugins/platforms/windows/qwindowsfontengine.cpp20
-rw-r--r--src/plugins/platforms/windows/qwindowsfontengine.h2
-rw-r--r--src/plugins/platforms/windows/qwindowsfontenginedirectwrite.cpp6
-rw-r--r--src/plugins/platforms/windows/qwindowsfontenginedirectwrite.h2
-rw-r--r--src/plugins/platforms/windows/qwindowsglcontext.cpp19
-rw-r--r--src/plugins/platforms/windows/qwindowsintegration.cpp48
-rw-r--r--src/plugins/platforms/windows/qwindowsintegration.h2
-rw-r--r--src/plugins/platforms/windows/qwindowskeymapper.cpp14
-rw-r--r--src/plugins/platforms/windows/qwindowsmime.cpp4
-rw-r--r--src/plugins/platforms/windows/qwindowsmousehandler.cpp4
-rw-r--r--src/plugins/platforms/windows/qwindowsmousehandler.h2
-rw-r--r--src/plugins/platforms/windows/qwindowsservices.cpp4
-rw-r--r--src/plugins/platforms/windows/qwindowswindow.cpp218
-rw-r--r--src/plugins/platforms/windows/qwindowswindow.h26
-rw-r--r--src/plugins/platforms/windows/windows.pro4
-rw-r--r--src/plugins/platforms/xcb/qglxintegration.cpp354
-rw-r--r--src/plugins/platforms/xcb/qglxintegration.h35
-rw-r--r--src/plugins/platforms/xcb/qxcbconnection.cpp7
-rw-r--r--src/plugins/platforms/xcb/qxcbconnection.h2
-rw-r--r--src/plugins/platforms/xcb/qxcbcursor.cpp34
-rw-r--r--src/plugins/platforms/xcb/qxcbintegration.cpp51
-rw-r--r--src/plugins/platforms/xcb/qxcbintegration.h12
-rw-r--r--src/plugins/platforms/xcb/qxcbkeyboard.cpp9
-rw-r--r--src/plugins/platforms/xcb/qxcbwindow.cpp302
-rw-r--r--src/plugins/platforms/xcb/qxcbwindow.h10
-rw-r--r--src/plugins/platformthemes/gtk2/gtk2.json3
-rw-r--r--src/plugins/platformthemes/gtk2/gtk2.pro20
-rw-r--r--src/plugins/platformthemes/gtk2/main.cpp67
-rw-r--r--src/plugins/platformthemes/gtk2/qgtk2dialoghelpers.cpp609
-rw-r--r--src/plugins/platformthemes/gtk2/qgtk2dialoghelpers.h143
-rw-r--r--src/plugins/platformthemes/gtk2/qgtk2theme.cpp108
-rw-r--r--src/plugins/platformthemes/gtk2/qgtk2theme.h64
-rw-r--r--src/plugins/platformthemes/platformthemes.pro3
-rw-r--r--src/plugins/plugins.pro5
-rw-r--r--src/plugins/printsupport/cups/qcupsprintengine.cpp47
-rw-r--r--src/plugins/printsupport/cups/qcupsprintengine_p.h1
-rw-r--r--src/plugins/printsupport/cups/qcupsprintersupport.cpp5
-rw-r--r--src/plugins/printsupport/cups/qcupsprintersupport_p.h3
-rw-r--r--src/plugins/printsupport/windows/qwindowsprintersupport.cpp5
-rw-r--r--src/plugins/printsupport/windows/qwindowsprintersupport.h3
-rw-r--r--src/plugins/sqldrivers/db2/main.cpp2
-rw-r--r--src/plugins/sqldrivers/ibase/main.cpp2
-rw-r--r--src/plugins/sqldrivers/mysql/main.cpp2
-rw-r--r--src/plugins/sqldrivers/oci/main.cpp2
-rw-r--r--src/plugins/sqldrivers/odbc/main.cpp2
-rw-r--r--src/plugins/sqldrivers/psql/main.cpp2
-rw-r--r--src/plugins/sqldrivers/qsqldriverbase.pri2
-rw-r--r--src/plugins/sqldrivers/sqlite/smain.cpp2
-rw-r--r--src/plugins/sqldrivers/sqlite2/smain.cpp2
-rw-r--r--src/plugins/sqldrivers/tds/main.cpp2
-rw-r--r--src/printsupport/dialogs/dialogs.pri2
-rw-r--r--src/printsupport/dialogs/qabstractprintdialog.h4
-rw-r--r--src/printsupport/dialogs/qpagesetupdialog.h4
-rw-r--r--src/printsupport/dialogs/qpagesetupdialog_unix.cpp16
-rw-r--r--src/printsupport/dialogs/qprintdialog.h4
-rw-r--r--src/printsupport/dialogs/qprintpreviewdialog.h4
-rw-r--r--src/printsupport/doc/snippets/widgetprinting.cpp2
-rw-r--r--src/printsupport/doc/src/qtprintsupport-index.qdoc4
-rw-r--r--src/printsupport/kernel/qcups.cpp21
-rw-r--r--src/printsupport/kernel/qcups_p.h1
-rw-r--r--src/printsupport/kernel/qpaintengine_alpha_p.h2
-rw-r--r--src/printsupport/kernel/qplatformprintersupport.cpp5
-rw-r--r--src/printsupport/kernel/qplatformprintersupport.h6
-rw-r--r--src/printsupport/kernel/qplatformprintplugin.h4
-rw-r--r--src/printsupport/kernel/qprintengine.h5
-rw-r--r--src/printsupport/kernel/qprintengine_win.cpp107
-rw-r--r--src/printsupport/kernel/qprintengine_win_p.h3
-rw-r--r--src/printsupport/kernel/qprinter.cpp33
-rw-r--r--src/printsupport/kernel/qprinter.h7
-rw-r--r--src/printsupport/kernel/qprinterinfo.cpp19
-rw-r--r--src/printsupport/kernel/qprinterinfo.h7
-rw-r--r--src/printsupport/kernel/qprinterinfo_p.h6
-rw-r--r--src/printsupport/kernel/qtprintsupportglobal.h4
-rw-r--r--src/printsupport/widgets/qprintpreviewwidget.h4
-rw-r--r--src/sql/doc/snippets/code/doc_src_sql-driver.cpp2
-rw-r--r--src/sql/doc/src/qsqldatatype-table.qdoc2
-rw-r--r--src/sql/doc/src/sql-driver.qdoc4
-rw-r--r--src/sql/doc/src/sql-programming.qdoc14
-rw-r--r--src/sql/drivers/db2/qsql_db2.cpp25
-rw-r--r--src/sql/drivers/db2/qsql_db2.pri2
-rw-r--r--src/sql/drivers/db2/qsql_db2_p.h (renamed from src/sql/drivers/db2/qsql_db2.h)24
-rw-r--r--src/sql/drivers/ibase/qsql_ibase.cpp62
-rw-r--r--src/sql/drivers/ibase/qsql_ibase.pri2
-rw-r--r--src/sql/drivers/ibase/qsql_ibase_p.h (renamed from src/sql/drivers/ibase/qsql_ibase.h)51
-rw-r--r--src/sql/drivers/mysql/qsql_mysql.cpp89
-rw-r--r--src/sql/drivers/mysql/qsql_mysql.pri2
-rw-r--r--src/sql/drivers/mysql/qsql_mysql_p.h (renamed from src/sql/drivers/mysql/qsql_mysql.h)24
-rw-r--r--src/sql/drivers/oci/qsql_oci.cpp66
-rw-r--r--src/sql/drivers/oci/qsql_oci.pri4
-rw-r--r--src/sql/drivers/oci/qsql_oci_p.h (renamed from src/sql/drivers/oci/qsql_oci.h)53
-rw-r--r--src/sql/drivers/odbc/qsql_odbc.cpp126
-rw-r--r--src/sql/drivers/odbc/qsql_odbc.pri2
-rw-r--r--src/sql/drivers/odbc/qsql_odbc_p.h (renamed from src/sql/drivers/odbc/qsql_odbc.h)24
-rw-r--r--src/sql/drivers/psql/qsql_psql.cpp168
-rw-r--r--src/sql/drivers/psql/qsql_psql.pri2
-rw-r--r--src/sql/drivers/psql/qsql_psql_p.h (renamed from src/sql/drivers/psql/qsql_psql.h)38
-rw-r--r--src/sql/drivers/sqlite/qsql_sqlite.cpp57
-rw-r--r--src/sql/drivers/sqlite/qsql_sqlite.pri2
-rw-r--r--src/sql/drivers/sqlite/qsql_sqlite_p.h (renamed from src/sql/drivers/sqlite/qsql_sqlite.h)51
-rw-r--r--src/sql/drivers/sqlite2/qsql_sqlite2.cpp58
-rw-r--r--src/sql/drivers/sqlite2/qsql_sqlite2.pri2
-rw-r--r--src/sql/drivers/sqlite2/qsql_sqlite2_p.h (renamed from src/sql/drivers/sqlite2/qsql_sqlite2.h)50
-rw-r--r--src/sql/drivers/tds/qsql_tds.cpp88
-rw-r--r--src/sql/drivers/tds/qsql_tds.pri2
-rw-r--r--src/sql/drivers/tds/qsql_tds_p.h (renamed from src/sql/drivers/tds/qsql_tds.h)43
-rw-r--r--src/sql/kernel/kernel.pri1
-rw-r--r--src/sql/kernel/qsql.h4
-rw-r--r--src/sql/kernel/qsqldatabase.cpp18
-rw-r--r--src/sql/kernel/qsqldatabase.h4
-rw-r--r--src/sql/kernel/qsqldriver.cpp32
-rw-r--r--src/sql/kernel/qsqldriver.h5
-rw-r--r--src/sql/kernel/qsqldriver_p.h86
-rw-r--r--src/sql/kernel/qsqldriverplugin.h4
-rw-r--r--src/sql/kernel/qsqlerror.cpp44
-rw-r--r--src/sql/kernel/qsqlerror.h15
-rw-r--r--src/sql/kernel/qsqlfield.h4
-rw-r--r--src/sql/kernel/qsqlindex.h4
-rw-r--r--src/sql/kernel/qsqlquery.cpp14
-rw-r--r--src/sql/kernel/qsqlquery.h4
-rw-r--r--src/sql/kernel/qsqlrecord.cpp15
-rw-r--r--src/sql/kernel/qsqlrecord.h5
-rw-r--r--src/sql/kernel/qsqlresult.cpp69
-rw-r--r--src/sql/kernel/qsqlresult.h10
-rw-r--r--src/sql/kernel/qsqlresult_p.h17
-rw-r--r--src/sql/models/qsqlquerymodel.h4
-rw-r--r--src/sql/models/qsqlquerymodel_p.h2
-rw-r--r--src/sql/models/qsqlrelationaldelegate.h4
-rw-r--r--src/sql/models/qsqlrelationaltablemodel.cpp2
-rw-r--r--src/sql/models/qsqlrelationaltablemodel.h4
-rw-r--r--src/sql/models/qsqltablemodel.cpp49
-rw-r--r--src/sql/models/qsqltablemodel.h5
-rw-r--r--src/sql/models/qsqltablemodel_p.h4
-rw-r--r--src/src.pro63
-rw-r--r--src/testlib/3rdparty/linux_perf_event_p.h615
-rw-r--r--src/testlib/doc/src/qttestlib-manual.qdoc8
-rw-r--r--src/testlib/qabstracttestlogger.cpp4
-rw-r--r--src/testlib/qbenchmark.cpp5
-rw-r--r--src/testlib/qbenchmark.h4
-rw-r--r--src/testlib/qbenchmark_p.h12
-rw-r--r--src/testlib/qbenchmarkmetric.cpp124
-rw-r--r--src/testlib/qbenchmarkmetric.h27
-rw-r--r--src/testlib/qbenchmarkmetric_p.h4
-rw-r--r--src/testlib/qbenchmarkperfevents.cpp607
-rw-r--r--src/testlib/qbenchmarkperfevents_p.h88
-rw-r--r--src/testlib/qplaintestlogger.cpp2
-rw-r--r--src/testlib/qsignalspy.h21
-rw-r--r--src/testlib/qsignalspy.qdoc2
-rw-r--r--src/testlib/qtest.h87
-rw-r--r--src/testlib/qtest_global.h4
-rw-r--r--src/testlib/qtest_gui.h4
-rw-r--r--src/testlib/qtest_widgets.h2
-rw-r--r--src/testlib/qtestaccessible.h6
-rw-r--r--src/testlib/qtestassert.h4
-rw-r--r--src/testlib/qtestcase.cpp92
-rw-r--r--src/testlib/qtestcase.h4
-rw-r--r--src/testlib/qtestcoreelement_p.h4
-rw-r--r--src/testlib/qtestcorelist_p.h4
-rw-r--r--src/testlib/qtestdata.h4
-rw-r--r--src/testlib/qtestelement_p.h4
-rw-r--r--src/testlib/qtestelementattribute_p.h4
-rw-r--r--src/testlib/qtestevent.h4
-rw-r--r--src/testlib/qtestevent.qdoc2
-rw-r--r--src/testlib/qtesteventloop.h4
-rw-r--r--src/testlib/qtestkeyboard.h4
-rw-r--r--src/testlib/qtestmouse.h5
-rw-r--r--src/testlib/qtestspontaneevent.h6
-rw-r--r--src/testlib/qtestsystem.h8
-rw-r--r--src/testlib/qtesttouch.h5
-rw-r--r--src/testlib/qtestxunitstreamer_p.h4
-rw-r--r--src/testlib/qxmltestlogger.cpp3
-rw-r--r--src/testlib/qxunittestlogger.cpp4
-rw-r--r--src/testlib/testlib.pro8
-rw-r--r--src/tools/bootstrap-dbus/bootstrap-dbus.pro32
-rw-r--r--src/tools/bootstrap/bootstrap.pro50
-rw-r--r--src/tools/moc/generator.cpp50
-rw-r--r--src/tools/moc/keywords.cpp2
-rw-r--r--src/tools/moc/moc.cpp12
-rw-r--r--src/tools/moc/moc.h2
-rw-r--r--src/tools/moc/moc.pro1
-rw-r--r--src/tools/moc/ppkeywords.cpp2
-rw-r--r--src/tools/moc/util/generate_keywords.cpp9
-rw-r--r--src/tools/moc/utils.h8
-rw-r--r--src/tools/qdbuscpp2xml/qdbuscpp2xml.cpp10
-rw-r--r--src/tools/qdbuscpp2xml/qdbuscpp2xml.pro26
-rw-r--r--src/tools/qdbusxml2cpp/qdbusxml2cpp.cpp4
-rw-r--r--src/tools/qdbusxml2cpp/qdbusxml2cpp.pro24
-rw-r--r--src/tools/qdoc/codemarker.cpp70
-rw-r--r--src/tools/qdoc/codemarker.h19
-rw-r--r--src/tools/qdoc/cppcodemarker.cpp34
-rw-r--r--src/tools/qdoc/doc.cpp4
-rw-r--r--src/tools/qdoc/generator.cpp2
-rw-r--r--src/tools/qdoc/htmlgenerator.cpp34
-rw-r--r--src/tools/qdoc/main.cpp18
-rw-r--r--src/tools/qdoc/node.cpp25
-rw-r--r--src/tools/qdoc/node.h8
-rw-r--r--src/tools/qdoc/qdoc.pro10
-rw-r--r--src/tools/qdoc/qdocdatabase.cpp53
-rw-r--r--src/tools/qdoc/qdocindexfiles.cpp8
-rw-r--r--src/tools/qdoc/qmlcodeparser.cpp2
-rw-r--r--src/tools/qdoc/qmlmarkupvisitor.cpp2
-rw-r--r--src/tools/qdoc/qmlmarkupvisitor.h2
-rw-r--r--src/tools/qdoc/qmlparser/parser.pri (renamed from src/tools/qdoc/qmlparser/qmlparser.pri)7
-rw-r--r--src/tools/qdoc/qmlparser/qqmljs.g171
-rw-r--r--src/tools/qdoc/qmlparser/qqmljsast.cpp35
-rw-r--r--src/tools/qdoc/qmlparser/qqmljsast_p.h119
-rw-r--r--src/tools/qdoc/qmlparser/qqmljsastfwd_p.h13
-rw-r--r--src/tools/qdoc/qmlparser/qqmljsastvisitor_p.h12
-rw-r--r--src/tools/qdoc/qmlparser/qqmljsengine_p.cpp8
-rw-r--r--src/tools/qdoc/qmlparser/qqmljsengine_p.h4
-rw-r--r--src/tools/qdoc/qmlparser/qqmljsgrammar.cpp1751
-rw-r--r--src/tools/qdoc/qmlparser/qqmljsgrammar_p.h47
-rw-r--r--src/tools/qdoc/qmlparser/qqmljskeywords_p.h96
-rw-r--r--src/tools/qdoc/qmlparser/qqmljslexer.cpp573
-rw-r--r--src/tools/qdoc/qmlparser/qqmljslexer_p.h28
-rw-r--r--src/tools/qdoc/qmlparser/qqmljsmemorypool_p.h1
-rw-r--r--src/tools/qdoc/qmlparser/qqmljsparser.cpp453
-rw-r--r--src/tools/qdoc/qmlparser/qqmljsparser_p.h24
-rw-r--r--src/tools/qdoc/qmlvisitor.cpp57
-rw-r--r--src/tools/qdoc/qmlvisitor.h5
-rw-r--r--src/tools/rcc/main.cpp4
-rw-r--r--src/tools/rcc/rcc.h4
-rw-r--r--src/tools/rcc/rcc.pro1
-rw-r--r--src/tools/tools.pro43
-rw-r--r--src/tools/uic/cpp/cppwriteincludes.cpp6
-rw-r--r--src/tools/uic/customwidgetsinfo.h1
-rw-r--r--src/tools/uic/driver.cpp2
-rw-r--r--src/tools/uic/qclass_lib_map.h18
-rw-r--r--src/widgets/QtGui.dynlist8
-rw-r--r--src/widgets/QtWidgets.dynlist5
-rw-r--r--src/widgets/accessible/accessible.pri2
-rw-r--r--src/widgets/accessible/qaccessiblewidget.cpp20
-rw-r--r--src/widgets/accessible/qaccessiblewidget_p.h (renamed from src/widgets/accessible/qaccessiblewidget.h)8
-rw-r--r--src/widgets/dialogs/qcolordialog.cpp7
-rw-r--r--src/widgets/dialogs/qcolordialog.h6
-rw-r--r--src/widgets/dialogs/qcolordialog_p.h2
-rw-r--r--src/widgets/dialogs/qdialog.cpp2
-rw-r--r--src/widgets/dialogs/qdialog.h6
-rw-r--r--src/widgets/dialogs/qdialog_p.h2
-rw-r--r--src/widgets/dialogs/qerrormessage.cpp2
-rw-r--r--src/widgets/dialogs/qerrormessage.h6
-rw-r--r--src/widgets/dialogs/qfiledialog.cpp6
-rw-r--r--src/widgets/dialogs/qfiledialog.h6
-rw-r--r--src/widgets/dialogs/qfiledialog.ui11
-rw-r--r--src/widgets/dialogs/qfiledialog_embedded.ui2
-rw-r--r--src/widgets/dialogs/qfiledialog_p.h4
-rw-r--r--src/widgets/dialogs/qfileinfogatherer.cpp4
-rw-r--r--src/widgets/dialogs/qfileinfogatherer_p.h2
-rw-r--r--src/widgets/dialogs/qfilesystemmodel.cpp10
-rw-r--r--src/widgets/dialogs/qfilesystemmodel.h6
-rw-r--r--src/widgets/dialogs/qfilesystemmodel_p.h2
-rw-r--r--src/widgets/dialogs/qfontdialog.cpp2
-rw-r--r--src/widgets/dialogs/qfontdialog.h6
-rw-r--r--src/widgets/dialogs/qfontdialog_p.h2
-rw-r--r--src/widgets/dialogs/qfscompleter_p.h2
-rw-r--r--src/widgets/dialogs/qinputdialog.cpp2
-rw-r--r--src/widgets/dialogs/qinputdialog.h6
-rw-r--r--src/widgets/dialogs/qmessagebox.cpp26
-rw-r--r--src/widgets/dialogs/qmessagebox.h10
-rw-r--r--src/widgets/dialogs/qprogressdialog.cpp6
-rw-r--r--src/widgets/dialogs/qprogressdialog.h6
-rw-r--r--src/widgets/dialogs/qsidebar.cpp2
-rw-r--r--src/widgets/dialogs/qsidebar_p.h2
-rw-r--r--src/widgets/dialogs/qwizard.cpp66
-rw-r--r--src/widgets/dialogs/qwizard.h6
-rw-r--r--src/widgets/dialogs/qwizard_win.cpp195
-rw-r--r--src/widgets/dialogs/qwizard_win_p.h17
-rw-r--r--src/widgets/doc/images/customcompleter-example.png (renamed from doc/src/images/customcompleter-example.png)bin11636 -> 11636 bytes
-rw-r--r--src/widgets/doc/images/customcompleter-insertcompletion.png (renamed from doc/src/images/customcompleter-insertcompletion.png)bin1371 -> 1371 bytes
-rw-r--r--src/widgets/doc/snippets/code/src_gui_itemviews_qdatawidgetmapper.cpp2
-rw-r--r--src/widgets/doc/snippets/customviewstyle.cpp2
-rw-r--r--src/widgets/doc/snippets/javastyle.cpp20
-rw-r--r--src/widgets/doc/snippets/layouts/layouts.cpp6
-rw-r--r--src/widgets/doc/snippets/mainwindowsnippet.cpp8
-rw-r--r--src/widgets/doc/snippets/mdiareasnippets.cpp2
-rw-r--r--src/widgets/doc/snippets/myscrollarea.cpp2
-rw-r--r--src/widgets/doc/snippets/qtablewidget-using/mainwindow.cpp2
-rw-r--r--src/widgets/doc/snippets/simplemodel-use/main.cpp2
-rw-r--r--src/widgets/doc/snippets/stringlistmodel/model.cpp4
-rw-r--r--src/widgets/doc/snippets/timeline/main.cpp8
-rw-r--r--src/widgets/doc/src/model-view-programming.qdoc2
-rw-r--r--src/widgets/doc/src/widgets-and-layouts/focus.qdoc6
-rw-r--r--src/widgets/doc/src/widgets-and-layouts/layout.qdoc14
-rw-r--r--src/widgets/doc/src/windows-and-dialogs/dialogs.qdoc4
-rw-r--r--src/widgets/doc/src/windows-and-dialogs/mainwindow.qdoc2
-rw-r--r--src/widgets/effects/qgraphicseffect.cpp2
-rw-r--r--src/widgets/effects/qgraphicseffect.h5
-rw-r--r--src/widgets/effects/qgraphicseffect_p.h2
-rw-r--r--src/widgets/effects/qpixmapfilter.cpp2
-rw-r--r--src/widgets/effects/qpixmapfilter_p.h6
-rw-r--r--src/widgets/graphicsview/qgraph_p.h2
-rw-r--r--src/widgets/graphicsview/qgraphicsanchorlayout.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicsanchorlayout.h6
-rw-r--r--src/widgets/graphicsview/qgraphicsanchorlayout_p.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicsanchorlayout_p.h2
-rw-r--r--src/widgets/graphicsview/qgraphicsgridlayout.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicsgridlayout.h6
-rw-r--r--src/widgets/graphicsview/qgraphicsitem.cpp75
-rw-r--r--src/widgets/graphicsview/qgraphicsitem.h6
-rw-r--r--src/widgets/graphicsview/qgraphicsitem_p.h2
-rw-r--r--src/widgets/graphicsview/qgraphicsitemanimation.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicsitemanimation.h6
-rw-r--r--src/widgets/graphicsview/qgraphicslayout.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicslayout.h6
-rw-r--r--src/widgets/graphicsview/qgraphicslayout_p.cpp4
-rw-r--r--src/widgets/graphicsview/qgraphicslayout_p.h2
-rw-r--r--src/widgets/graphicsview/qgraphicslayoutitem.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicslayoutitem.h6
-rw-r--r--src/widgets/graphicsview/qgraphicslayoutitem_p.h2
-rw-r--r--src/widgets/graphicsview/qgraphicslinearlayout.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicslinearlayout.h6
-rw-r--r--src/widgets/graphicsview/qgraphicsproxywidget.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicsproxywidget.h6
-rw-r--r--src/widgets/graphicsview/qgraphicsproxywidget_p.h2
-rw-r--r--src/widgets/graphicsview/qgraphicsscene.cpp104
-rw-r--r--src/widgets/graphicsview/qgraphicsscene.h7
-rw-r--r--src/widgets/graphicsview/qgraphicsscene_bsp.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicsscene_bsp_p.h2
-rw-r--r--src/widgets/graphicsview/qgraphicsscene_p.h5
-rw-r--r--src/widgets/graphicsview/qgraphicsscenebsptreeindex.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicssceneevent.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicssceneevent.h6
-rw-r--r--src/widgets/graphicsview/qgraphicssceneindex.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicssceneindex_p.h4
-rw-r--r--src/widgets/graphicsview/qgraphicsscenelinearindex.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicsscenelinearindex_p.h4
-rw-r--r--src/widgets/graphicsview/qgraphicstransform.h5
-rw-r--r--src/widgets/graphicsview/qgraphicstransform_p.h2
-rw-r--r--src/widgets/graphicsview/qgraphicsview.cpp135
-rw-r--r--src/widgets/graphicsview/qgraphicsview.h12
-rw-r--r--src/widgets/graphicsview/qgraphicsview_p.h5
-rw-r--r--src/widgets/graphicsview/qgraphicswidget.cpp2
-rw-r--r--src/widgets/graphicsview/qgraphicswidget.h6
-rw-r--r--src/widgets/graphicsview/qgraphicswidget_p.cpp106
-rw-r--r--src/widgets/graphicsview/qgraphicswidget_p.h2
-rw-r--r--src/widgets/graphicsview/qgridlayoutengine.cpp2
-rw-r--r--src/widgets/graphicsview/qgridlayoutengine_p.h2
-rw-r--r--src/widgets/graphicsview/qsimplex_p.cpp2
-rw-r--r--src/widgets/graphicsview/qsimplex_p.h2
-rw-r--r--src/widgets/itemviews/qabstractitemdelegate.cpp2
-rw-r--r--src/widgets/itemviews/qabstractitemdelegate.h6
-rw-r--r--src/widgets/itemviews/qabstractitemview.cpp27
-rw-r--r--src/widgets/itemviews/qabstractitemview.h6
-rw-r--r--src/widgets/itemviews/qabstractitemview_p.h2
-rw-r--r--src/widgets/itemviews/qbsptree.cpp2
-rw-r--r--src/widgets/itemviews/qbsptree_p.h2
-rw-r--r--src/widgets/itemviews/qcolumnview.cpp2
-rw-r--r--src/widgets/itemviews/qcolumnview.h6
-rw-r--r--src/widgets/itemviews/qcolumnview_p.h2
-rw-r--r--src/widgets/itemviews/qcolumnviewgrip.cpp2
-rw-r--r--src/widgets/itemviews/qcolumnviewgrip_p.h2
-rw-r--r--src/widgets/itemviews/qdatawidgetmapper.cpp2
-rw-r--r--src/widgets/itemviews/qdatawidgetmapper.h6
-rw-r--r--src/widgets/itemviews/qdirmodel.cpp2
-rw-r--r--src/widgets/itemviews/qdirmodel.h6
-rw-r--r--src/widgets/itemviews/qfileiconprovider.cpp2
-rw-r--r--src/widgets/itemviews/qfileiconprovider.h6
-rw-r--r--src/widgets/itemviews/qheaderview.cpp16
-rw-r--r--src/widgets/itemviews/qheaderview.h6
-rw-r--r--src/widgets/itemviews/qheaderview_p.h2
-rw-r--r--src/widgets/itemviews/qitemdelegate.cpp5
-rw-r--r--src/widgets/itemviews/qitemdelegate.h6
-rw-r--r--src/widgets/itemviews/qitemeditorfactory.cpp2
-rw-r--r--src/widgets/itemviews/qitemeditorfactory.h6
-rw-r--r--src/widgets/itemviews/qitemeditorfactory_p.h2
-rw-r--r--src/widgets/itemviews/qlistview.cpp2
-rw-r--r--src/widgets/itemviews/qlistview.h6
-rw-r--r--src/widgets/itemviews/qlistview_p.h2
-rw-r--r--src/widgets/itemviews/qlistwidget.cpp2
-rw-r--r--src/widgets/itemviews/qlistwidget.h6
-rw-r--r--src/widgets/itemviews/qlistwidget_p.h2
-rw-r--r--src/widgets/itemviews/qstyleditemdelegate.cpp14
-rw-r--r--src/widgets/itemviews/qstyleditemdelegate.h6
-rw-r--r--src/widgets/itemviews/qtableview.cpp2
-rw-r--r--src/widgets/itemviews/qtableview.h6
-rw-r--r--src/widgets/itemviews/qtableview_p.h2
-rw-r--r--src/widgets/itemviews/qtablewidget.cpp2
-rw-r--r--src/widgets/itemviews/qtablewidget.h6
-rw-r--r--src/widgets/itemviews/qtablewidget_p.h2
-rw-r--r--src/widgets/itemviews/qtreeview.cpp54
-rw-r--r--src/widgets/itemviews/qtreeview.h6
-rw-r--r--src/widgets/itemviews/qtreeview_p.h6
-rw-r--r--src/widgets/itemviews/qtreewidget.cpp2
-rw-r--r--src/widgets/itemviews/qtreewidget.h6
-rw-r--r--src/widgets/itemviews/qtreewidget_p.h2
-rw-r--r--src/widgets/itemviews/qtreewidgetitemiterator.cpp11
-rw-r--r--src/widgets/itemviews/qtreewidgetitemiterator.h6
-rw-r--r--src/widgets/itemviews/qtreewidgetitemiterator_p.h2
-rw-r--r--src/widgets/itemviews/qwidgetitemdata_p.h2
-rw-r--r--src/widgets/kernel/kernel.pri6
-rw-r--r--src/widgets/kernel/mac.pri2
-rw-r--r--src/widgets/kernel/qaction.cpp2
-rw-r--r--src/widgets/kernel/qaction.h6
-rw-r--r--src/widgets/kernel/qaction_p.h2
-rw-r--r--src/widgets/kernel/qactiongroup.cpp2
-rw-r--r--src/widgets/kernel/qactiongroup.h6
-rw-r--r--src/widgets/kernel/qapplication.cpp68
-rw-r--r--src/widgets/kernel/qapplication.h6
-rw-r--r--src/widgets/kernel/qapplication_p.h5
-rw-r--r--src/widgets/kernel/qapplication_qpa.cpp2
-rw-r--r--src/widgets/kernel/qboxlayout.cpp8
-rw-r--r--src/widgets/kernel/qboxlayout.h6
-rw-r--r--src/widgets/kernel/qdesktopwidget.cpp2
-rw-r--r--src/widgets/kernel/qdesktopwidget.h6
-rw-r--r--src/widgets/kernel/qdesktopwidget.qdoc8
-rw-r--r--src/widgets/kernel/qdesktopwidget_qpa.cpp2
-rw-r--r--src/widgets/kernel/qdesktopwidget_qpa_p.h5
-rw-r--r--src/widgets/kernel/qformlayout.cpp2
-rw-r--r--src/widgets/kernel/qformlayout.h6
-rw-r--r--src/widgets/kernel/qgesture.cpp4
-rw-r--r--src/widgets/kernel/qgesture.h6
-rw-r--r--src/widgets/kernel/qgesture_p.h2
-rw-r--r--src/widgets/kernel/qgesturemanager.cpp2
-rw-r--r--src/widgets/kernel/qgesturemanager_p.h2
-rw-r--r--src/widgets/kernel/qgesturerecognizer.cpp2
-rw-r--r--src/widgets/kernel/qgesturerecognizer.h6
-rw-r--r--src/widgets/kernel/qgridlayout.cpp2
-rw-r--r--src/widgets/kernel/qgridlayout.h6
-rw-r--r--src/widgets/kernel/qlayout.cpp4
-rw-r--r--src/widgets/kernel/qlayout.h6
-rw-r--r--src/widgets/kernel/qlayout_p.h2
-rw-r--r--src/widgets/kernel/qlayoutengine.cpp2
-rw-r--r--src/widgets/kernel/qlayoutengine_p.h2
-rw-r--r--src/widgets/kernel/qlayoutitem.cpp36
-rw-r--r--src/widgets/kernel/qlayoutitem.h8
-rw-r--r--src/widgets/kernel/qshortcut.cpp2
-rw-r--r--src/widgets/kernel/qshortcut.h6
-rw-r--r--src/widgets/kernel/qsizepolicy.h6
-rw-r--r--src/widgets/kernel/qstackedlayout.cpp2
-rw-r--r--src/widgets/kernel/qstackedlayout.h6
-rw-r--r--src/widgets/kernel/qstandardgestures.cpp2
-rw-r--r--src/widgets/kernel/qstandardgestures_p.h2
-rw-r--r--src/widgets/kernel/qt_widgets_pch.h2
-rw-r--r--src/widgets/kernel/qtooltip.cpp2
-rw-r--r--src/widgets/kernel/qtooltip.h6
-rw-r--r--src/widgets/kernel/qwhatsthis.cpp2
-rw-r--r--src/widgets/kernel/qwhatsthis.h6
-rw-r--r--src/widgets/kernel/qwidget.cpp58
-rw-r--r--src/widgets/kernel/qwidget.h10
-rw-r--r--src/widgets/kernel/qwidget_p.h2
-rw-r--r--src/widgets/kernel/qwidget_qpa.cpp47
-rw-r--r--src/widgets/kernel/qwidgetaction.cpp2
-rw-r--r--src/widgets/kernel/qwidgetaction.h10
-rw-r--r--src/widgets/kernel/qwidgetaction_p.h4
-rw-r--r--src/widgets/kernel/qwidgetbackingstore.cpp2
-rw-r--r--src/widgets/kernel/qwidgetbackingstore_p.h2
-rw-r--r--src/widgets/kernel/qwidgetsfunctions_wince.h5
-rw-r--r--src/widgets/kernel/qwidgetsvariant.cpp2
-rw-r--r--src/widgets/kernel/qwidgetwindow.cpp63
-rw-r--r--src/widgets/kernel/qwidgetwindow_qpa_p.h13
-rw-r--r--src/widgets/kernel/qwindowcontainer.cpp218
-rw-r--r--src/widgets/kernel/qwindowcontainer_p.h69
-rw-r--r--src/widgets/statemachine/qbasickeyeventtransition.cpp2
-rw-r--r--src/widgets/statemachine/qbasickeyeventtransition_p.h2
-rw-r--r--src/widgets/statemachine/qbasicmouseeventtransition.cpp2
-rw-r--r--src/widgets/statemachine/qbasicmouseeventtransition_p.h2
-rw-r--r--src/widgets/statemachine/qguistatemachine.cpp4
-rw-r--r--src/widgets/statemachine/qkeyeventtransition.cpp2
-rw-r--r--src/widgets/statemachine/qkeyeventtransition.h6
-rw-r--r--src/widgets/statemachine/qmouseeventtransition.cpp2
-rw-r--r--src/widgets/statemachine/qmouseeventtransition.h6
-rw-r--r--src/widgets/styles/images/toolbar-ext.pngbin0 -> 516 bytes
-rw-r--r--src/widgets/styles/images/toolbar-ext@2x.pngbin0 -> 505 bytes
-rw-r--r--src/widgets/styles/qandroidstyle.cpp1601
-rw-r--r--src/widgets/styles/qandroidstyle_p.h382
-rw-r--r--src/widgets/styles/qcommonstyle.cpp54
-rw-r--r--src/widgets/styles/qcommonstyle.h8
-rw-r--r--src/widgets/styles/qcommonstyle_p.h2
-rw-r--r--src/widgets/styles/qcommonstylepixmaps_p.h4
-rw-r--r--src/widgets/styles/qdrawutil.cpp6
-rw-r--r--src/widgets/styles/qdrawutil.h6
-rw-r--r--src/widgets/styles/qfusionstyle.cpp111
-rw-r--r--src/widgets/styles/qfusionstyle_p.h6
-rw-r--r--src/widgets/styles/qfusionstyle_p_p.h6
-rw-r--r--src/widgets/styles/qgtk2painter.cpp2
-rw-r--r--src/widgets/styles/qgtk2painter_p.h2
-rw-r--r--src/widgets/styles/qgtkglobal_p.h2
-rw-r--r--src/widgets/styles/qgtkpainter.cpp2
-rw-r--r--src/widgets/styles/qgtkpainter_p.h2
-rw-r--r--src/widgets/styles/qgtkstyle.cpp11
-rw-r--r--src/widgets/styles/qgtkstyle_p.cpp52
-rw-r--r--src/widgets/styles/qgtkstyle_p.h6
-rw-r--r--src/widgets/styles/qgtkstyle_p_p.h2
-rw-r--r--src/widgets/styles/qmacstyle.qdoc38
-rw-r--r--src/widgets/styles/qmacstyle_mac.mm128
-rw-r--r--src/widgets/styles/qmacstyle_mac_p.h6
-rw-r--r--src/widgets/styles/qmacstyle_mac_p_p.h2
-rw-r--r--src/widgets/styles/qproxystyle.cpp31
-rw-r--r--src/widgets/styles/qproxystyle.h9
-rw-r--r--src/widgets/styles/qproxystyle_p.h2
-rw-r--r--src/widgets/styles/qstyle.cpp7
-rw-r--r--src/widgets/styles/qstyle.h7
-rw-r--r--src/widgets/styles/qstyle.qrc2
-rw-r--r--src/widgets/styles/qstyle_p.h2
-rw-r--r--src/widgets/styles/qstyleanimation.cpp8
-rw-r--r--src/widgets/styles/qstyleanimation_p.h2
-rw-r--r--src/widgets/styles/qstylefactory.cpp14
-rw-r--r--src/widgets/styles/qstylefactory.h6
-rw-r--r--src/widgets/styles/qstylehelper.cpp3
-rw-r--r--src/widgets/styles/qstylehelper_p.h2
-rw-r--r--src/widgets/styles/qstyleoption.cpp24
-rw-r--r--src/widgets/styles/qstyleoption.h6
-rw-r--r--src/widgets/styles/qstylepainter.cpp2
-rw-r--r--src/widgets/styles/qstylepainter.h6
-rw-r--r--src/widgets/styles/qstyleplugin.cpp2
-rw-r--r--src/widgets/styles/qstyleplugin.h6
-rw-r--r--src/widgets/styles/qstylesheetstyle.cpp2
-rw-r--r--src/widgets/styles/qstylesheetstyle_default.cpp2
-rw-r--r--src/widgets/styles/qstylesheetstyle_p.h2
-rw-r--r--src/widgets/styles/qwindowscestyle.cpp2
-rw-r--r--src/widgets/styles/qwindowscestyle_p.h6
-rw-r--r--src/widgets/styles/qwindowscestyle_p_p.h2
-rw-r--r--src/widgets/styles/qwindowsmobilestyle.cpp126
-rw-r--r--src/widgets/styles/qwindowsmobilestyle_p.h6
-rw-r--r--src/widgets/styles/qwindowsmobilestyle_p_p.h2
-rw-r--r--src/widgets/styles/qwindowsstyle.cpp3
-rw-r--r--src/widgets/styles/qwindowsstyle_p.h6
-rw-r--r--src/widgets/styles/qwindowsstyle_p_p.h2
-rw-r--r--src/widgets/styles/qwindowsvistastyle.cpp55
-rw-r--r--src/widgets/styles/qwindowsvistastyle_p.h6
-rw-r--r--src/widgets/styles/qwindowsvistastyle_p_p.h2
-rw-r--r--src/widgets/styles/qwindowsxpstyle.cpp2
-rw-r--r--src/widgets/styles/qwindowsxpstyle_p.h6
-rw-r--r--src/widgets/styles/qwindowsxpstyle_p_p.h2
-rw-r--r--src/widgets/styles/styles.pri10
-rw-r--r--src/widgets/util/qcolormap.cpp2
-rw-r--r--src/widgets/util/qcolormap.h6
-rw-r--r--src/widgets/util/qcolormap.qdoc2
-rw-r--r--src/widgets/util/qcompleter.cpp4
-rw-r--r--src/widgets/util/qcompleter.h6
-rw-r--r--src/widgets/util/qcompleter_p.h2
-rw-r--r--src/widgets/util/qflickgesture.cpp2
-rw-r--r--src/widgets/util/qflickgesture_p.h2
-rw-r--r--src/widgets/util/qscroller.cpp4
-rw-r--r--src/widgets/util/qscroller.h6
-rw-r--r--src/widgets/util/qscroller_mac.mm2
-rw-r--r--src/widgets/util/qscroller_p.h2
-rw-r--r--src/widgets/util/qscrollerproperties.cpp4
-rw-r--r--src/widgets/util/qscrollerproperties.h6
-rw-r--r--src/widgets/util/qscrollerproperties_p.h2
-rw-r--r--src/widgets/util/qsystemtrayicon.cpp6
-rw-r--r--src/widgets/util/qsystemtrayicon.h6
-rw-r--r--src/widgets/util/qsystemtrayicon_p.h2
-rw-r--r--src/widgets/util/qsystemtrayicon_qpa.cpp2
-rw-r--r--src/widgets/util/qsystemtrayicon_win.cpp26
-rw-r--r--src/widgets/util/qsystemtrayicon_wince.cpp4
-rw-r--r--src/widgets/util/qsystemtrayicon_x11.cpp2
-rw-r--r--src/widgets/util/qundogroup.cpp2
-rw-r--r--src/widgets/util/qundogroup.h6
-rw-r--r--src/widgets/util/qundostack.cpp8
-rw-r--r--src/widgets/util/qundostack.h6
-rw-r--r--src/widgets/util/qundostack_p.h2
-rw-r--r--src/widgets/util/qundoview.cpp2
-rw-r--r--src/widgets/util/qundoview.h6
-rw-r--r--src/widgets/util/util.pri2
-rw-r--r--src/widgets/widgets.pro2
-rw-r--r--src/widgets/widgets/qabstractbutton.cpp4
-rw-r--r--src/widgets/widgets/qabstractbutton.h6
-rw-r--r--src/widgets/widgets/qabstractbutton_p.h2
-rw-r--r--src/widgets/widgets/qabstractscrollarea.cpp4
-rw-r--r--src/widgets/widgets/qabstractscrollarea.h6
-rw-r--r--src/widgets/widgets/qabstractscrollarea_p.h2
-rw-r--r--src/widgets/widgets/qabstractslider.cpp4
-rw-r--r--src/widgets/widgets/qabstractslider.h6
-rw-r--r--src/widgets/widgets/qabstractslider_p.h4
-rw-r--r--src/widgets/widgets/qabstractspinbox.cpp40
-rw-r--r--src/widgets/widgets/qabstractspinbox.h6
-rw-r--r--src/widgets/widgets/qabstractspinbox_p.h2
-rw-r--r--src/widgets/widgets/qbuttongroup.cpp6
-rw-r--r--src/widgets/widgets/qbuttongroup.h6
-rw-r--r--src/widgets/widgets/qcalendartextnavigator_p.h2
-rw-r--r--src/widgets/widgets/qcalendarwidget.cpp4
-rw-r--r--src/widgets/widgets/qcalendarwidget.h6
-rw-r--r--src/widgets/widgets/qcheckbox.cpp2
-rw-r--r--src/widgets/widgets/qcheckbox.h6
-rw-r--r--src/widgets/widgets/qcocoatoolbardelegate_mac.mm2
-rw-r--r--src/widgets/widgets/qcocoatoolbardelegate_mac_p.h2
-rw-r--r--src/widgets/widgets/qcombobox.cpp2
-rw-r--r--src/widgets/widgets/qcombobox.h6
-rw-r--r--src/widgets/widgets/qcombobox_p.h6
-rw-r--r--src/widgets/widgets/qcommandlinkbutton.cpp2
-rw-r--r--src/widgets/widgets/qcommandlinkbutton.h6
-rw-r--r--src/widgets/widgets/qdatetimeedit.cpp18
-rw-r--r--src/widgets/widgets/qdatetimeedit.h6
-rw-r--r--src/widgets/widgets/qdatetimeedit_p.h2
-rw-r--r--src/widgets/widgets/qdial.cpp2
-rw-r--r--src/widgets/widgets/qdial.h6
-rw-r--r--src/widgets/widgets/qdialogbuttonbox.cpp2
-rw-r--r--src/widgets/widgets/qdialogbuttonbox.h6
-rw-r--r--src/widgets/widgets/qdockarealayout.cpp4
-rw-r--r--src/widgets/widgets/qdockarealayout_p.h2
-rw-r--r--src/widgets/widgets/qdockwidget.cpp2
-rw-r--r--src/widgets/widgets/qdockwidget.h6
-rw-r--r--src/widgets/widgets/qdockwidget_p.h2
-rw-r--r--src/widgets/widgets/qeffects.cpp6
-rw-r--r--src/widgets/widgets/qeffects_p.h2
-rw-r--r--src/widgets/widgets/qfocusframe.cpp2
-rw-r--r--src/widgets/widgets/qfocusframe.h6
-rw-r--r--src/widgets/widgets/qfontcombobox.cpp39
-rw-r--r--src/widgets/widgets/qfontcombobox.h6
-rw-r--r--src/widgets/widgets/qframe.cpp2
-rw-r--r--src/widgets/widgets/qframe.h6
-rw-r--r--src/widgets/widgets/qframe_p.h2
-rw-r--r--src/widgets/widgets/qgroupbox.cpp6
-rw-r--r--src/widgets/widgets/qgroupbox.h8
-rw-r--r--src/widgets/widgets/qlabel.cpp16
-rw-r--r--src/widgets/widgets/qlabel.h6
-rw-r--r--src/widgets/widgets/qlabel_p.h2
-rw-r--r--src/widgets/widgets/qlcdnumber.cpp2
-rw-r--r--src/widgets/widgets/qlcdnumber.h6
-rw-r--r--src/widgets/widgets/qlineedit.cpp13
-rw-r--r--src/widgets/widgets/qlineedit.h6
-rw-r--r--src/widgets/widgets/qlineedit_p.cpp4
-rw-r--r--src/widgets/widgets/qlineedit_p.h2
-rw-r--r--src/widgets/widgets/qmaccocoaviewcontainer_mac.h6
-rw-r--r--src/widgets/widgets/qmaccocoaviewcontainer_mac.mm4
-rw-r--r--src/widgets/widgets/qmacnativewidget_mac.h6
-rw-r--r--src/widgets/widgets/qmacnativewidget_mac.mm2
-rw-r--r--src/widgets/widgets/qmainwindow.cpp2
-rw-r--r--src/widgets/widgets/qmainwindow.h6
-rw-r--r--src/widgets/widgets/qmainwindowlayout.cpp2
-rw-r--r--src/widgets/widgets/qmainwindowlayout_mac.mm2
-rw-r--r--src/widgets/widgets/qmainwindowlayout_p.h2
-rw-r--r--src/widgets/widgets/qmdiarea.cpp2
-rw-r--r--src/widgets/widgets/qmdiarea.h6
-rw-r--r--src/widgets/widgets/qmdiarea_p.h2
-rw-r--r--src/widgets/widgets/qmdisubwindow.cpp18
-rw-r--r--src/widgets/widgets/qmdisubwindow.h6
-rw-r--r--src/widgets/widgets/qmdisubwindow_p.h2
-rw-r--r--src/widgets/widgets/qmenu.cpp149
-rw-r--r--src/widgets/widgets/qmenu.h15
-rw-r--r--src/widgets/widgets/qmenu_p.h6
-rw-r--r--src/widgets/widgets/qmenu_wince.cpp26
-rw-r--r--src/widgets/widgets/qmenu_wince.rc32
-rw-r--r--src/widgets/widgets/qmenu_wince_resource_p.h5
-rw-r--r--src/widgets/widgets/qmenubar.cpp2
-rw-r--r--src/widgets/widgets/qmenubar.h6
-rw-r--r--src/widgets/widgets/qmenubar_p.h2
-rw-r--r--src/widgets/widgets/qplaintextedit.cpp2
-rw-r--r--src/widgets/widgets/qplaintextedit.h6
-rw-r--r--src/widgets/widgets/qplaintextedit_p.h2
-rw-r--r--src/widgets/widgets/qprogressbar.cpp48
-rw-r--r--src/widgets/widgets/qprogressbar.h9
-rw-r--r--src/widgets/widgets/qpushbutton.cpp2
-rw-r--r--src/widgets/widgets/qpushbutton.h8
-rw-r--r--src/widgets/widgets/qpushbutton_p.h2
-rw-r--r--src/widgets/widgets/qradiobutton.cpp2
-rw-r--r--src/widgets/widgets/qradiobutton.h6
-rw-r--r--src/widgets/widgets/qrubberband.cpp2
-rw-r--r--src/widgets/widgets/qrubberband.h6
-rw-r--r--src/widgets/widgets/qscrollarea.cpp4
-rw-r--r--src/widgets/widgets/qscrollarea.h6
-rw-r--r--src/widgets/widgets/qscrollarea_p.h4
-rw-r--r--src/widgets/widgets/qscrollbar.cpp2
-rw-r--r--src/widgets/widgets/qscrollbar.h6
-rw-r--r--src/widgets/widgets/qscrollbar_p.h2
-rw-r--r--src/widgets/widgets/qsizegrip.cpp2
-rw-r--r--src/widgets/widgets/qsizegrip.h6
-rw-r--r--src/widgets/widgets/qslider.cpp2
-rw-r--r--src/widgets/widgets/qslider.h6
-rw-r--r--src/widgets/widgets/qspinbox.cpp3
-rw-r--r--src/widgets/widgets/qspinbox.h6
-rw-r--r--src/widgets/widgets/qsplashscreen.cpp4
-rw-r--r--src/widgets/widgets/qsplashscreen.h6
-rw-r--r--src/widgets/widgets/qsplitter.cpp4
-rw-r--r--src/widgets/widgets/qsplitter.h6
-rw-r--r--src/widgets/widgets/qsplitter_p.h2
-rw-r--r--src/widgets/widgets/qstackedwidget.cpp2
-rw-r--r--src/widgets/widgets/qstackedwidget.h6
-rw-r--r--src/widgets/widgets/qstatusbar.cpp8
-rw-r--r--src/widgets/widgets/qstatusbar.h6
-rw-r--r--src/widgets/widgets/qtabbar.cpp4
-rw-r--r--src/widgets/widgets/qtabbar.h6
-rw-r--r--src/widgets/widgets/qtabbar_p.h2
-rw-r--r--src/widgets/widgets/qtabwidget.cpp2
-rw-r--r--src/widgets/widgets/qtabwidget.h6
-rw-r--r--src/widgets/widgets/qtextbrowser.cpp31
-rw-r--r--src/widgets/widgets/qtextbrowser.h6
-rw-r--r--src/widgets/widgets/qtextedit.cpp4
-rw-r--r--src/widgets/widgets/qtextedit.h6
-rw-r--r--src/widgets/widgets/qtextedit_p.h2
-rw-r--r--src/widgets/widgets/qtoolbar.cpp2
-rw-r--r--src/widgets/widgets/qtoolbar.h6
-rw-r--r--src/widgets/widgets/qtoolbar_p.h2
-rw-r--r--src/widgets/widgets/qtoolbararealayout.cpp6
-rw-r--r--src/widgets/widgets/qtoolbararealayout_p.h6
-rw-r--r--src/widgets/widgets/qtoolbarextension.cpp2
-rw-r--r--src/widgets/widgets/qtoolbarextension_p.h2
-rw-r--r--src/widgets/widgets/qtoolbarlayout.cpp4
-rw-r--r--src/widgets/widgets/qtoolbarlayout_p.h2
-rw-r--r--src/widgets/widgets/qtoolbarseparator.cpp2
-rw-r--r--src/widgets/widgets/qtoolbarseparator_p.h2
-rw-r--r--src/widgets/widgets/qtoolbox.cpp2
-rw-r--r--src/widgets/widgets/qtoolbox.h6
-rw-r--r--src/widgets/widgets/qtoolbutton.cpp2
-rw-r--r--src/widgets/widgets/qtoolbutton.h6
-rw-r--r--src/widgets/widgets/qwidgetanimator.cpp2
-rw-r--r--src/widgets/widgets/qwidgetanimator_p.h2
-rw-r--r--src/widgets/widgets/qwidgetlinecontrol.cpp2
-rw-r--r--src/widgets/widgets/qwidgetlinecontrol_p.h6
-rw-r--r--src/widgets/widgets/qwidgetresizehandler.cpp2
-rw-r--r--src/widgets/widgets/qwidgetresizehandler_p.h2
-rw-r--r--src/widgets/widgets/qwidgettextcontrol.cpp5
-rw-r--r--src/widgets/widgets/qwidgettextcontrol_p.h6
-rw-r--r--src/widgets/widgets/qwidgettextcontrol_p_p.h2
-rw-r--r--src/widgets/widgets/widgets.pri2
-rw-r--r--src/xml/doc/src/qtxml-index.qdoc2
-rw-r--r--src/xml/dom/qdom.h4
-rw-r--r--src/xml/qtxmlglobal.h4
-rw-r--r--src/xml/sax/qxml.cpp4
-rw-r--r--src/xml/sax/qxml.h4
-rw-r--r--sync.profile9
-rw-r--r--tests/auto/android/AndroidManifest.xml37
-rw-r--r--tests/auto/android/res/layout/main.xml12
-rw-r--r--tests/auto/android/res/values/libs.xml21
-rw-r--r--tests/auto/android/res/values/strings.xml4
-rwxr-xr-xtests/auto/android/runtests.pl366
-rw-r--r--tests/auto/android/src/org/qtproject/qt5/android/QtActivity.java328
-rw-r--r--tests/auto/android/src/org/qtproject/qt5/android/QtInputConnection.java209
-rw-r--r--tests/auto/android/src/org/qtproject/qt5/android/QtNative.java466
-rw-r--r--tests/auto/android/src/org/qtproject/qt5/android/QtSurface.java163
-rw-r--r--tests/auto/auto.pro4
-rw-r--r--tests/auto/bic/data/QtGui.5.0.0.linux-gcc-amd64.txt151
-rw-r--r--tests/auto/bic/data/QtGui.5.0.0.linux-gcc-ia32.txt151
-rw-r--r--tests/auto/bic/data/QtOpenGL.5.0.0.linux-gcc-amd64.txt201
-rw-r--r--tests/auto/bic/data/QtOpenGL.5.0.0.linux-gcc-ia32.txt201
-rw-r--r--tests/auto/bic/data/QtPrintSupport.5.0.0.linux-gcc-amd64.txt201
-rw-r--r--tests/auto/bic/data/QtPrintSupport.5.0.0.linux-gcc-ia32.txt201
-rw-r--r--tests/auto/bic/data/QtWidgets.5.0.0.linux-gcc-amd64.txt201
-rw-r--r--tests/auto/bic/data/QtWidgets.5.0.0.linux-gcc-ia32.txt201
-rw-r--r--tests/auto/cmake/CMakeLists.txt46
-rw-r--r--tests/auto/cmake/cmake.pro10
-rw-r--r--tests/auto/cmake/test(needsquoting)dirname/CMakeLists.txt6
-rw-r--r--tests/auto/cmake/test_concurrent_module/CMakeLists.txt2
-rw-r--r--tests/auto/cmake/test_dbus_module/CMakeLists.txt10
-rw-r--r--tests/auto/cmake/test_interface/CMakeLists.txt36
-rw-r--r--tests/auto/cmake/test_interface/main.cpp58
-rw-r--r--tests/auto/cmake/test_interface/mainwindow.cpp (renamed from mkspecs/unsupported/linux-android-armeabi-g++/qplatformdefs.h)12
-rw-r--r--tests/auto/cmake/test_interface/mainwindow.h57
-rw-r--r--tests/auto/cmake/test_openglextensions_module/CMakeLists.txt22
-rw-r--r--tests/auto/cmake/test_openglextensions_module/main.cpp56
-rw-r--r--tests/auto/cmake/test_testlib_definitions/CMakeLists.txt4
-rw-r--r--tests/auto/cmake/test_umbrella_config/CMakeLists.txt20
-rw-r--r--tests/auto/cmake/test_umbrella_config/components_found/CMakeLists.txt18
-rw-r--r--tests/auto/cmake/test_umbrella_config/components_not_found/CMakeLists.txt17
-rw-r--r--tests/auto/cmake/test_use_modules_function/CMakeLists.txt2
-rw-r--r--tests/auto/cmake/test_use_modules_function/three.cpp4
-rw-r--r--tests/auto/concurrent/qtconcurrentfilter/qtconcurrentfilter.pro1
-rw-r--r--tests/auto/concurrent/qtconcurrentfilter/tst_qtconcurrentfilter.cpp23
-rw-r--r--tests/auto/concurrent/qtconcurrentiteratekernel/qtconcurrentiteratekernel.pro1
-rw-r--r--tests/auto/concurrent/qtconcurrentiteratekernel/tst_qtconcurrentiteratekernel.cpp10
-rw-r--r--tests/auto/concurrent/qtconcurrentmap/qtconcurrentmap.pro1
-rw-r--r--tests/auto/concurrent/qtconcurrentmap/tst_qtconcurrentmap.cpp6
-rw-r--r--tests/auto/concurrent/qtconcurrentrun/qtconcurrentrun.pro1
-rw-r--r--tests/auto/concurrent/qtconcurrentrun/tst_qtconcurrentrun.cpp6
-rw-r--r--tests/auto/concurrent/qtconcurrentthreadengine/qtconcurrentthreadengine.pro1
-rw-r--r--tests/auto/corelib/animation/qsequentialanimationgroup/tst_qsequentialanimationgroup.cpp2
-rw-r--r--tests/auto/corelib/codecs/qtextcodec/tst_qtextcodec.cpp75
-rw-r--r--tests/auto/corelib/global/global.pro4
-rw-r--r--tests/auto/corelib/global/qgetputenv/tst_qgetputenv.cpp7
-rw-r--r--tests/auto/corelib/global/qglobal/tst_qglobal.cpp31
-rw-r--r--tests/auto/corelib/global/qglobalstatic/qglobalstatic.pro12
-rw-r--r--tests/auto/corelib/global/qglobalstatic/tst_qglobalstatic.cpp236
-rw-r--r--tests/auto/corelib/global/qlogging/tst_qlogging.cpp77
-rw-r--r--tests/auto/corelib/global/qrand/tst_qrand.cpp2
-rw-r--r--tests/auto/corelib/io/io.pro8
-rw-r--r--tests/auto/corelib/io/qdatastream/tst_qdatastream.cpp2
-rw-r--r--tests/auto/corelib/io/qdebug/tst_qdebug.cpp54
-rw-r--r--tests/auto/corelib/io/qfile/stdinprocess/main.cpp2
-rw-r--r--tests/auto/corelib/io/qfile/tst_qfile.cpp33
-rw-r--r--tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp149
-rw-r--r--tests/auto/corelib/io/qlockfile/qlockfile.pro3
-rw-r--r--tests/auto/corelib/io/qlockfile/qlockfiletesthelper/qlockfile_test_helper.cpp78
-rw-r--r--tests/auto/corelib/io/qlockfile/qlockfiletesthelper/qlockfile_test_helper.pro7
-rw-r--r--tests/auto/corelib/io/qlockfile/tst_qlockfile.cpp379
-rw-r--r--tests/auto/corelib/io/qlockfile/tst_qlockfile.pro6
-rw-r--r--tests/auto/corelib/io/qprocess/testForwarding/testForwarding.pro1
-rw-r--r--tests/auto/corelib/io/qprocess/testProcessEchoGui/main_win.cpp4
-rw-r--r--tests/auto/corelib/io/qprocess/testProcessNormal/testProcessNormal.pro1
-rw-r--r--tests/auto/corelib/io/qprocess/testProcessOutput/testProcessOutput.pro1
-rw-r--r--tests/auto/corelib/io/qprocess/testProcessSpacesArgs/twospaces.pro1
-rw-r--r--tests/auto/corelib/io/qprocess/testSetWorkingDirectory/testSetWorkingDirectory.pro1
-rw-r--r--tests/auto/corelib/io/qprocess/testSoftExit/main_unix.cpp2
-rw-r--r--tests/auto/corelib/io/qprocess/testSoftExit/main_win.cpp2
-rw-r--r--tests/auto/corelib/io/qprocess/testSoftExit/testSoftExit.pro1
-rw-r--r--tests/auto/corelib/io/qprocess/testSpaceInName/testSpaceInName.pro1
-rw-r--r--tests/auto/corelib/io/qprocess/tst_qprocess.cpp21
-rw-r--r--tests/auto/corelib/io/qresourceengine/tst_qresourceengine.cpp2
-rw-r--r--tests/auto/corelib/io/qsavefile/qsavefile.pro5
-rw-r--r--tests/auto/corelib/io/qsavefile/tst_qsavefile.cpp339
-rw-r--r--tests/auto/corelib/io/qsettings/tst_qsettings.cpp2
-rw-r--r--tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp14
-rw-r--r--tests/auto/corelib/io/qtemporaryfile/tst_qtemporaryfile.cpp35
-rw-r--r--tests/auto/corelib/io/qurl/tst_qurl.cpp48
-rw-r--r--tests/auto/corelib/io/qurlinternal/tst_qurlinternal.cpp14
-rw-r--r--tests/auto/corelib/io/qwinoverlappedionotifier/tst_qwinoverlappedionotifier.cpp13
-rw-r--r--tests/auto/corelib/itemmodels/qabstractitemmodel/tst_qabstractitemmodel.cpp5
-rw-r--r--tests/auto/corelib/itemmodels/qabstractproxymodel/tst_qabstractproxymodel.cpp2
-rw-r--r--tests/auto/corelib/itemmodels/qidentityproxymodel/tst_qidentityproxymodel.cpp26
-rw-r--r--tests/auto/corelib/itemmodels/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp224
-rw-r--r--tests/auto/corelib/json/tst_qtjson.cpp136
-rw-r--r--tests/auto/corelib/kernel/kernel.pro6
-rw-r--r--tests/auto/corelib/kernel/qcoreapplication/tst_qcoreapplication.cpp12
-rw-r--r--tests/auto/corelib/kernel/qmath/tst_qmath.cpp77
-rw-r--r--tests/auto/corelib/kernel/qmetamethod/qmetamethod.pro2
-rw-r--r--tests/auto/corelib/kernel/qmetaobjectbuilder/qmetaobjectbuilder.pro2
-rw-r--r--tests/auto/corelib/kernel/qmetatype/tst_qmetatype.cpp14
-rw-r--r--tests/auto/corelib/kernel/qobject/tst_qobject.cpp393
-rw-r--r--tests/auto/corelib/kernel/qpointer/tst_qpointer.cpp7
-rw-r--r--tests/auto/corelib/kernel/qsharedmemory/test/tst_qsharedmemory.cpp2
-rw-r--r--tests/auto/corelib/mimetypes/qmimedatabase/tst_qmimedatabase.cpp4
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/lib/mylib.c6
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/qpluginloader.pro2
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/theplugin/theplugin.cpp6
-rw-r--r--tests/auto/corelib/plugin/qpluginloader/tst_qpluginloader.cpp69
-rw-r--r--tests/auto/corelib/plugin/quuid/testProcessUniqueness/main.cpp2
-rw-r--r--tests/auto/corelib/statemachine/qstate/tst_qstate.cpp16
-rw-r--r--tests/auto/corelib/thread/qfuture/tst_qfuture.cpp32
-rw-r--r--tests/auto/corelib/thread/qfuturewatcher/tst_qfuturewatcher.cpp12
-rw-r--r--tests/auto/corelib/thread/qthread/tst_qthread.cpp10
-rw-r--r--tests/auto/corelib/thread/qthreadonce/qthreadonce.h4
-rw-r--r--tests/auto/corelib/thread/qthreadpool/tst_qthreadpool.cpp36
-rw-r--r--tests/auto/corelib/tools/qchar/tst_qchar.cpp68
-rw-r--r--tests/auto/corelib/tools/qcryptographichash/tst_qcryptographichash.cpp73
-rw-r--r--tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp48
-rw-r--r--tests/auto/corelib/tools/qhash/tst_qhash.cpp34
-rw-r--r--tests/auto/corelib/tools/qlocale/tst_qlocale.cpp77
-rw-r--r--tests/auto/corelib/tools/qmap/tst_qmap.cpp161
-rw-r--r--tests/auto/corelib/tools/qmargins/tst_qmargins.cpp46
-rw-r--r--tests/auto/corelib/tools/qmessageauthenticationcode/.gitignore1
-rw-r--r--tests/auto/corelib/tools/qmessageauthenticationcode/qmessageauthenticationcode.pro7
-rw-r--r--tests/auto/corelib/tools/qmessageauthenticationcode/tst_qmessageauthenticationcode.cpp151
-rw-r--r--tests/auto/corelib/tools/qpoint/tst_qpoint.cpp25
-rw-r--r--tests/auto/corelib/tools/qpointf/tst_qpointf.cpp26
-rw-r--r--tests/auto/corelib/tools/qqueue/tst_qqueue.cpp18
-rw-r--r--tests/auto/corelib/tools/qrect/tst_qrect.cpp21
-rw-r--r--tests/auto/corelib/tools/qregularexpression/tst_qregularexpression.cpp217
-rw-r--r--tests/auto/corelib/tools/qregularexpression/tst_qregularexpression.h5
-rw-r--r--tests/auto/corelib/tools/qset/tst_qset.cpp22
-rw-r--r--tests/auto/corelib/tools/qsharedpointer/externaltests.pri2
-rw-r--r--tests/auto/corelib/tools/qsharedpointer/tst_qsharedpointer.cpp122
-rw-r--r--tests/auto/corelib/tools/qstring/tst_qstring.cpp109
-rw-r--r--tests/auto/corelib/tools/qstringref/tst_qstringref.cpp954
-rw-r--r--tests/auto/corelib/tools/qtimeline/tst_qtimeline.cpp23
-rw-r--r--tests/auto/corelib/tools/qvarlengtharray/tst_qvarlengtharray.cpp24
-rw-r--r--tests/auto/corelib/tools/qvector/tst_qvector.cpp98
-rw-r--r--tests/auto/corelib/tools/tools.pro1
-rw-r--r--tests/auto/corelib/xml/xml.pro2
-rw-r--r--tests/auto/dbus/qdbusabstractinterface/tst_qdbusabstractinterface.cpp96
-rw-r--r--tests/auto/dbus/qdbusconnection/tst_qdbusconnection.cpp13
-rw-r--r--tests/auto/dbus/qdbusmetaobject/tst_qdbusmetaobject.cpp26
-rw-r--r--tests/auto/dbus/qdbuspendingreply/tst_qdbuspendingreply.cpp7
-rw-r--r--tests/auto/dbus/qdbusreply/tst_qdbusreply.cpp25
-rw-r--r--tests/auto/dbus/qdbusxmlparser/tst_qdbusxmlparser.cpp4
-rw-r--r--tests/auto/gui/image/image.pro3
-rw-r--r--tests/auto/gui/image/qicoimageformat/qicoimageformat.pro1
-rw-r--r--tests/auto/gui/image/qicon/qicon.pro1
-rw-r--r--tests/auto/gui/image/qicon/tst_qicon.cpp2
-rw-r--r--tests/auto/gui/image/qimage/qimage.pro1
-rw-r--r--tests/auto/gui/image/qimageiohandler/qimageiohandler.pro1
-rw-r--r--tests/auto/gui/image/qimageiohandler/tst_qimageiohandler.cpp2
-rw-r--r--tests/auto/gui/image/qimagereader/images/black.xpm30
-rw-r--r--tests/auto/gui/image/qimagereader/qimagereader.pro1
-rw-r--r--tests/auto/gui/image/qimagereader/tst_qimagereader.cpp21
-rw-r--r--tests/auto/gui/image/qimagewriter/qimagewriter.pro1
-rw-r--r--tests/auto/gui/image/qimagewriter/tst_qimagewriter.cpp21
-rw-r--r--tests/auto/gui/image/qmovie/qmovie.pro1
-rw-r--r--tests/auto/gui/image/qpicture/qpicture.pro1
-rw-r--r--tests/auto/gui/image/qpicture/tst_qpicture.cpp39
-rw-r--r--tests/auto/gui/image/qpixmap/qpixmap.pro1
-rw-r--r--tests/auto/gui/image/qpixmap/tst_qpixmap.cpp23
-rw-r--r--tests/auto/gui/image/qpixmapcache/qpixmapcache.pro1
-rw-r--r--tests/auto/gui/itemmodels/qstandarditem/qstandarditem.pro1
-rw-r--r--tests/auto/gui/itemmodels/qstandarditem/tst_qstandarditem.cpp2
-rw-r--r--tests/auto/gui/itemmodels/qstandarditemmodel/qstandarditemmodel.pro1
-rw-r--r--tests/auto/gui/itemmodels/qstandarditemmodel/tst_qstandarditemmodel.cpp2
-rw-r--r--tests/auto/gui/kernel/kernel.pro1
-rw-r--r--tests/auto/gui/kernel/qbackingstore/qbackingstore.pro1
-rw-r--r--tests/auto/gui/kernel/qclipboard/copier/copier.pro1
-rw-r--r--tests/auto/gui/kernel/qclipboard/paster/paster.pro1
-rw-r--r--tests/auto/gui/kernel/qclipboard/test/test.pro1
-rw-r--r--tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp5
-rw-r--r--tests/auto/gui/kernel/qdrag/qdrag.pro1
-rw-r--r--tests/auto/gui/kernel/qevent/qevent.pro1
-rw-r--r--tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/qfileopeneventexternal.pro1
-rw-r--r--tests/auto/gui/kernel/qfileopenevent/test/test.pro1
-rw-r--r--tests/auto/gui/kernel/qguiapplication/qguiapplication.pro1
-rw-r--r--tests/auto/gui/kernel/qguieventdispatcher/qguieventdispatcher.pro1
-rw-r--r--tests/auto/gui/kernel/qguimetatype/qguimetatype.pro1
-rw-r--r--tests/auto/gui/kernel/qguitimer/qguitimer.pro1
-rw-r--r--tests/auto/gui/kernel/qguivariant/no_application/no_application.pro1
-rw-r--r--tests/auto/gui/kernel/qguivariant/test/test.pro1
-rw-r--r--tests/auto/gui/kernel/qinputmethod/qinputmethod.pro1
-rw-r--r--tests/auto/gui/kernel/qkeysequence/tst_qkeysequence.cpp102
-rw-r--r--tests/auto/gui/kernel/qmouseevent/qmouseevent.pro1
-rw-r--r--tests/auto/gui/kernel/qmouseevent_modal/qmouseevent_modal.pro1
-rw-r--r--tests/auto/gui/kernel/qpalette/qpalette.pro1
-rw-r--r--tests/auto/gui/kernel/qscreen/qscreen.pro1
-rw-r--r--tests/auto/gui/kernel/qsurfaceformat/qsurfaceformat.pro7
-rw-r--r--tests/auto/gui/kernel/qsurfaceformat/tst_qsurfaceformat.cpp102
-rw-r--r--tests/auto/gui/kernel/qtouchevent/qtouchevent.pro1
-rw-r--r--tests/auto/gui/kernel/qtouchevent/tst_qtouchevent.cpp6
-rw-r--r--tests/auto/gui/kernel/qwindow/qwindow.pro1
-rw-r--r--tests/auto/gui/kernel/qwindow/tst_qwindow.cpp57
-rw-r--r--tests/auto/gui/math3d/qquaternion/qquaternion.pro1
-rw-r--r--tests/auto/gui/math3d/qvectornd/qvectornd.pro1
-rw-r--r--tests/auto/gui/math3d/qvectornd/tst_qvectornd.cpp174
-rw-r--r--tests/auto/gui/painting/qbrush/qbrush.pro1
-rw-r--r--tests/auto/gui/painting/qcolor/qcolor.pro1
-rw-r--r--tests/auto/gui/painting/qpaintengine/qpaintengine.pro1
-rw-r--r--tests/auto/gui/painting/qpainter/qpainter.pro1
-rw-r--r--tests/auto/gui/painting/qpainter/tst_qpainter.cpp3
-rw-r--r--tests/auto/gui/painting/qpainterpath/qpainterpath.pro1
-rw-r--r--tests/auto/gui/painting/qpainterpathstroker/qpainterpathstroker.pro1
-rw-r--r--tests/auto/gui/painting/qpathclipper/paths.cpp14
-rw-r--r--tests/auto/gui/painting/qpathclipper/qpathclipper.pro1
-rw-r--r--tests/auto/gui/painting/qpen/qpen.pro1
-rw-r--r--tests/auto/gui/painting/qpolygon/qpolygon.pro1
-rw-r--r--tests/auto/gui/painting/qregion/qregion.pro1
-rw-r--r--tests/auto/gui/painting/qtransform/qtransform.pro1
-rw-r--r--tests/auto/gui/painting/qwmatrix/qwmatrix.pro1
-rw-r--r--tests/auto/gui/painting/qwmatrix/tst_qwmatrix.cpp2
-rw-r--r--tests/auto/gui/qopengl/qopengl.pro1
-rw-r--r--tests/auto/gui/qopengl/tst_qopengl.cpp112
-rw-r--r--tests/auto/gui/text/qabstracttextdocumentlayout/qabstracttextdocumentlayout.pro1
-rw-r--r--tests/auto/gui/text/qcssparser/qcssparser.pro1
-rw-r--r--tests/auto/gui/text/qfontcache/.gitignore1
-rw-r--r--tests/auto/gui/text/qfontcache/qfontcache.pro7
-rw-r--r--tests/auto/gui/text/qfontcache/tst_qfontcache.cpp148
-rw-r--r--tests/auto/gui/text/qfontdatabase/qfontdatabase.pro3
-rw-r--r--tests/auto/gui/text/qfontdatabase/tst_qfontdatabase.cpp15
-rw-r--r--tests/auto/gui/text/qfontmetrics/qfontmetrics.pro1
-rw-r--r--tests/auto/gui/text/qfontmetrics/tst_qfontmetrics.cpp2
-rw-r--r--tests/auto/gui/text/qglyphrun/qglyphrun.pro1
-rw-r--r--tests/auto/gui/text/qrawfont/qrawfont.pro1
-rw-r--r--tests/auto/gui/text/qstatictext/qstatictext.pro1
-rw-r--r--tests/auto/gui/text/qstatictext/tst_qstatictext.cpp2
-rw-r--r--tests/auto/gui/text/qsyntaxhighlighter/qsyntaxhighlighter.pro1
-rw-r--r--tests/auto/gui/text/qsyntaxhighlighter/tst_qsyntaxhighlighter.cpp10
-rw-r--r--tests/auto/gui/text/qtextblock/qtextblock.pro1
-rw-r--r--tests/auto/gui/text/qtextcursor/qtextcursor.pro1
-rw-r--r--tests/auto/gui/text/qtextdocument/qtextdocument.pro1
-rw-r--r--tests/auto/gui/text/qtextdocumentfragment/qtextdocumentfragment.pro1
-rw-r--r--tests/auto/gui/text/qtextdocumentlayout/qtextdocumentlayout.pro1
-rw-r--r--tests/auto/gui/text/qtextformat/qtextformat.pro1
-rw-r--r--tests/auto/gui/text/qtextformat/tst_qtextformat.cpp2
-rw-r--r--tests/auto/gui/text/qtextlayout/qtextlayout.pro2
-rw-r--r--tests/auto/gui/text/qtextlist/qtextlist.pro1
-rw-r--r--tests/auto/gui/text/qtextobject/qtextobject.pro1
-rw-r--r--tests/auto/gui/text/qtextodfwriter/qtextodfwriter.pro1
-rw-r--r--tests/auto/gui/text/qtextpiecetable/qtextpiecetable.pro1
-rw-r--r--tests/auto/gui/text/qtextscriptengine/generate/generate.pro3
-rw-r--r--tests/auto/gui/text/qtextscriptengine/generate/main.cpp2
-rw-r--r--tests/auto/gui/text/qtextscriptengine/qtextscriptengine.pro1
-rw-r--r--tests/auto/gui/text/qtextscriptengine/tst_qtextscriptengine.cpp902
-rw-r--r--tests/auto/gui/text/qtexttable/qtexttable.pro1
-rw-r--r--tests/auto/gui/text/qzip/qzip.pro1
-rw-r--r--tests/auto/gui/text/text.pro2
-rw-r--r--tests/auto/gui/util/qdoublevalidator/qdoublevalidator.pro1
-rw-r--r--tests/auto/gui/util/qintvalidator/qintvalidator.pro1
-rw-r--r--tests/auto/gui/util/qregexpvalidator/qregexpvalidator.pro1
-rw-r--r--tests/auto/gui/util/qregularexpressionvalidator/.gitignore1
-rw-r--r--tests/auto/gui/util/qregularexpressionvalidator/qregularexpressionvalidator.pro4
-rw-r--r--tests/auto/gui/util/qregularexpressionvalidator/tst_qregularexpressionvalidator.cpp120
-rw-r--r--tests/auto/gui/util/util.pro1
-rw-r--r--tests/auto/network/access/qhttpnetworkconnection/tst_qhttpnetworkconnection.cpp6
-rw-r--r--tests/auto/network/access/qnetworkcookiejar/tst_qnetworkcookiejar.cpp2
-rw-r--r--tests/auto/network/access/qnetworkdiskcache/tst_qnetworkdiskcache.cpp2
-rw-r--r--tests/auto/network/access/qnetworkreply/echo/main.cpp2
-rw-r--r--tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp96
-rw-r--r--tests/auto/network/bearer/qnetworkconfiguration/tst_qnetworkconfiguration.cpp8
-rw-r--r--tests/auto/network/bearer/qnetworkconfigurationmanager/tst_qnetworkconfigurationmanager.cpp4
-rw-r--r--tests/auto/network/bearer/qnetworksession/test/tst_qnetworksession.cpp60
-rw-r--r--tests/auto/network/kernel/qhostaddress/tst_qhostaddress.cpp2
-rw-r--r--tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp13
-rw-r--r--tests/auto/network/kernel/qnetworkproxyfactory/tst_qnetworkproxyfactory.cpp2
-rw-r--r--tests/auto/network/socket/platformsocketengine/tst_platformsocketengine.cpp2
-rw-r--r--tests/auto/network/socket/qlocalsocket/tst_qlocalsocket.cpp6
-rw-r--r--tests/auto/network/socket/qtcpsocket/stressTest/Test.cpp4
-rw-r--r--tests/auto/network/socket/qtcpsocket/stressTest/main.cpp2
-rw-r--r--tests/auto/network/socket/qtcpsocket/tst_qtcpsocket.cpp1
-rw-r--r--tests/auto/network/socket/qudpsocket/clientserver/main.cpp4
-rw-r--r--tests/auto/network/socket/qudpsocket/udpServer/main.cpp6
-rw-r--r--tests/auto/network/ssl/qsslerror/tst_qsslerror.cpp2
-rw-r--r--tests/auto/network/ssl/qsslsocket/certs/ca.crt22
-rw-r--r--tests/auto/network/ssl/qsslsocket/certs/inter.crt22
-rw-r--r--tests/auto/network/ssl/qsslsocket/certs/leaf.crt23
-rw-r--r--tests/auto/network/ssl/qsslsocket/certs/leaf.key32
-rw-r--r--tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp93
-rw-r--r--tests/auto/opengl/qgl/tst_qgl.cpp4
-rw-r--r--tests/auto/opengl/qglbuffer/tst_qglbuffer.cpp5
-rw-r--r--tests/auto/other/collections/tst_collections.cpp2
-rw-r--r--tests/auto/other/lancelot/lancelot.pro1
-rw-r--r--tests/auto/other/lancelot/scripts/background.qps26
-rw-r--r--tests/auto/other/lancelot/scripts/bitmaps.qps4
-rw-r--r--tests/auto/other/lancelot/scripts/clippaths.qps12
-rw-r--r--tests/auto/other/lancelot/scripts/cliprects.qps12
-rw-r--r--tests/auto/other/lancelot/scripts/conical_gradients.qps2
-rw-r--r--tests/auto/other/lancelot/scripts/dashes.qps38
-rw-r--r--tests/auto/other/lancelot/scripts/deviceclipping.qps2
-rw-r--r--tests/auto/other/lancelot/scripts/pixmap_scaling.qps38
-rw-r--r--tests/auto/other/lancelot/scripts/pixmap_subpixel.qps12
-rw-r--r--tests/auto/other/lancelot/scripts/pixmaps.qps10
-rw-r--r--tests/auto/other/lancelot/scripts/rasterops.qps4
-rw-r--r--tests/auto/other/lancelot/scripts/sizes.qps6
-rw-r--r--tests/auto/other/lancelot/scripts/statictext.qps34
-rw-r--r--tests/auto/other/lancelot/scripts/text.qps84
-rw-r--r--tests/auto/other/lancelot/scripts/tiled_pixmap.qps10
-rw-r--r--tests/auto/other/macgui/guitest.cpp33
-rw-r--r--tests/auto/other/macgui/guitest.h9
-rw-r--r--tests/auto/other/macgui/tst_macgui.cpp6
-rw-r--r--tests/auto/other/macnativeevents/tst_macnativeevents.cpp2
-rw-r--r--tests/auto/other/other.pro8
-rw-r--r--tests/auto/other/qaccessibility/qaccessibility.pro2
-rw-r--r--tests/auto/other/qaccessibility/tst_qaccessibility.cpp631
-rw-r--r--tests/auto/other/qnetworkaccessmanager_and_qprogressdialog/tst_qnetworkaccessmanager_and_qprogressdialog.cpp2
-rw-r--r--tests/auto/other/windowsmobile/test/tst_windowsmobile.cpp2
-rw-r--r--tests/auto/other/windowsmobile/testQMenuBar/main.cpp2
-rw-r--r--tests/auto/sql/kernel/qsql/qsql.pro3
-rw-r--r--tests/auto/sql/kernel/qsql/tst_qsql.cpp148
-rw-r--r--tests/auto/sql/kernel/qsqldatabase/qsqldatabase.pro3
-rw-r--r--tests/auto/sql/kernel/qsqldatabase/tst_databases.h40
-rw-r--r--tests/auto/sql/kernel/qsqldatabase/tst_qsqldatabase.cpp193
-rw-r--r--tests/auto/sql/kernel/qsqldriver/qsqldriver.pro3
-rw-r--r--tests/auto/sql/kernel/qsqldriver/tst_qsqldriver.cpp8
-rw-r--r--tests/auto/sql/kernel/qsqlerror/qsqlerror.pro1
-rw-r--r--tests/auto/sql/kernel/qsqlfield/qsqlfield.pro1
-rw-r--r--tests/auto/sql/kernel/qsqlquery/qsqlquery.pro3
-rw-r--r--tests/auto/sql/kernel/qsqlquery/tst_qsqlquery.cpp288
-rw-r--r--tests/auto/sql/kernel/qsqlrecord/qsqlrecord.pro1
-rw-r--r--tests/auto/sql/kernel/qsqlresult/qsqlresult.pro1
-rw-r--r--tests/auto/sql/kernel/qsqlresult/testsqldriver.h2
-rw-r--r--tests/auto/sql/kernel/qsqlthread/qsqlthread.pro3
-rw-r--r--tests/auto/sql/kernel/qsqlthread/tst_qsqlthread.cpp14
-rw-r--r--tests/auto/sql/models/qsqlquerymodel/qsqlquerymodel.pro3
-rw-r--r--tests/auto/sql/models/qsqlquerymodel/tst_qsqlquerymodel.cpp70
-rw-r--r--tests/auto/sql/models/qsqlrelationaltablemodel/qsqlrelationaltablemodel.pro3
-rw-r--r--tests/auto/sql/models/qsqlrelationaltablemodel/tst_qsqlrelationaltablemodel.cpp86
-rw-r--r--tests/auto/sql/models/qsqltablemodel/qsqltablemodel.pro1
-rw-r--r--tests/auto/sql/models/qsqltablemodel/tst_qsqltablemodel.cpp62
-rwxr-xr-xtests/auto/test.pl97
-rw-r--r--tests/auto/testlib/qsignalspy/qsignalspy.pro1
-rw-r--r--tests/auto/testlib/selftests/alive/alive.pro1
-rw-r--r--tests/auto/testlib/selftests/assert/assert.pro1
-rw-r--r--tests/auto/testlib/selftests/badxml/badxml.pro1
-rw-r--r--tests/auto/testlib/selftests/benchlibcallgrind/benchlibcallgrind.pro1
-rw-r--r--tests/auto/testlib/selftests/benchlibcounting/benchlibcounting.pro1
-rw-r--r--tests/auto/testlib/selftests/benchlibeventcounter/benchlibeventcounter.pro1
-rw-r--r--tests/auto/testlib/selftests/benchliboptions/benchliboptions.pro1
-rw-r--r--tests/auto/testlib/selftests/benchlibtickcounter/benchlibtickcounter.pro1
-rw-r--r--tests/auto/testlib/selftests/benchlibwalltime/benchlibwalltime.pro1
-rw-r--r--tests/auto/testlib/selftests/cmptest/cmptest.pro1
-rw-r--r--tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp16
-rw-r--r--tests/auto/testlib/selftests/commandlinedata/commandlinedata.pro1
-rw-r--r--tests/auto/testlib/selftests/counting/counting.pro1
-rw-r--r--tests/auto/testlib/selftests/crashes/crashes.pro1
-rw-r--r--tests/auto/testlib/selftests/datatable/datatable.pro1
-rw-r--r--tests/auto/testlib/selftests/datetime/datetime.pro1
-rw-r--r--tests/auto/testlib/selftests/datetime/tst_datetime.cpp2
-rw-r--r--tests/auto/testlib/selftests/differentexec/differentexec.pro1
-rw-r--r--tests/auto/testlib/selftests/exceptionthrow/exceptionthrow.pro1
-rw-r--r--tests/auto/testlib/selftests/expected_cmptest.lightxml24
-rw-r--r--tests/auto/testlib/selftests/expected_cmptest.txt20
-rw-r--r--tests/auto/testlib/selftests/expected_cmptest.xml24
-rw-r--r--tests/auto/testlib/selftests/expected_cmptest.xunitxml22
-rw-r--r--tests/auto/testlib/selftests/expectfail/expectfail.pro1
-rw-r--r--tests/auto/testlib/selftests/failcleanup/failcleanup.pro1
-rw-r--r--tests/auto/testlib/selftests/failinit/failinit.pro1
-rw-r--r--tests/auto/testlib/selftests/failinitdata/failinitdata.pro1
-rw-r--r--tests/auto/testlib/selftests/fetchbogus/fetchbogus.pro1
-rw-r--r--tests/auto/testlib/selftests/findtestdata/findtestdata.pro1
-rw-r--r--tests/auto/testlib/selftests/float/float.pro1
-rw-r--r--tests/auto/testlib/selftests/globaldata/globaldata.pro1
-rw-r--r--tests/auto/testlib/selftests/longstring/longstring.pro1
-rw-r--r--tests/auto/testlib/selftests/maxwarnings/maxwarnings.pro1
-rw-r--r--tests/auto/testlib/selftests/multiexec/multiexec.pro1
-rw-r--r--tests/auto/testlib/selftests/printdatatags/printdatatags.pro1
-rw-r--r--tests/auto/testlib/selftests/printdatatagswithglobaltags/printdatatagswithglobaltags.pro1
-rw-r--r--tests/auto/testlib/selftests/qexecstringlist/qexecstringlist.pro1
-rw-r--r--tests/auto/testlib/selftests/silent/silent.pro1
-rw-r--r--tests/auto/testlib/selftests/singleskip/singleskip.pro1
-rw-r--r--tests/auto/testlib/selftests/skip/skip.pro1
-rw-r--r--tests/auto/testlib/selftests/skipcleanup/skipcleanup.pro1
-rw-r--r--tests/auto/testlib/selftests/skipinit/skipinit.pro1
-rw-r--r--tests/auto/testlib/selftests/skipinitdata/skipinitdata.pro1
-rw-r--r--tests/auto/testlib/selftests/sleep/sleep.pro1
-rw-r--r--tests/auto/testlib/selftests/strcmp/strcmp.pro1
-rw-r--r--tests/auto/testlib/selftests/subtest/subtest.pro1
-rw-r--r--tests/auto/testlib/selftests/test/test.pro1
-rw-r--r--tests/auto/testlib/selftests/tst_selftests.cpp7
-rw-r--r--tests/auto/testlib/selftests/verbose1/verbose1.pro1
-rw-r--r--tests/auto/testlib/selftests/verbose2/verbose2.pro1
-rw-r--r--tests/auto/testlib/selftests/warnings/warnings.pro1
-rw-r--r--tests/auto/testlib/selftests/xunit/xunit.pro1
-rw-r--r--tests/auto/tools/moc/dollars.h70
-rw-r--r--tests/auto/tools/moc/gadgetwithnoenums.h30
-rw-r--r--tests/auto/tools/moc/moc.pro2
-rw-r--r--tests/auto/tools/moc/parse-defines.h11
-rw-r--r--tests/auto/tools/moc/task189996.h10
-rw-r--r--tests/auto/tools/moc/template-gtgt.h4
-rw-r--r--tests/auto/tools/moc/tst_moc.cpp256
-rw-r--r--tests/auto/tools/qmake/tst_qmake.cpp9
-rw-r--r--tests/auto/widgets/dialogs/dialogs.pro1
-rw-r--r--tests/auto/widgets/dialogs/qabstractprintdialog/qabstractprintdialog.pro1
-rw-r--r--tests/auto/widgets/dialogs/qcolordialog/qcolordialog.pro1
-rw-r--r--tests/auto/widgets/dialogs/qdialog/qdialog.pro1
-rw-r--r--tests/auto/widgets/dialogs/qdialog/tst_qdialog.cpp18
-rw-r--r--tests/auto/widgets/dialogs/qerrormessage/qerrormessage.pro1
-rw-r--r--tests/auto/widgets/dialogs/qerrormessage/tst_qerrormessage.cpp18
-rw-r--r--tests/auto/widgets/dialogs/qfiledialog/qfiledialog.pro2
-rw-r--r--tests/auto/widgets/dialogs/qfiledialog/tst_qfiledialog.cpp77
-rw-r--r--tests/auto/widgets/dialogs/qfiledialog2/qfiledialog2.pro1
-rw-r--r--tests/auto/widgets/dialogs/qfiledialog2/tst_qfiledialog2.cpp90
-rw-r--r--tests/auto/widgets/dialogs/qfilesystemmodel/qfilesystemmodel.pro5
-rw-r--r--tests/auto/widgets/dialogs/qfilesystemmodel/tst_qfilesystemmodel.cpp55
-rw-r--r--tests/auto/widgets/dialogs/qfontdialog/qfontdialog.pro1
-rw-r--r--tests/auto/widgets/dialogs/qinputdialog/qinputdialog.pro3
-rw-r--r--tests/auto/widgets/dialogs/qinputdialog/tst_qinputdialog.cpp16
-rw-r--r--tests/auto/widgets/dialogs/qmessagebox/qmessagebox.pro1
-rw-r--r--tests/auto/widgets/dialogs/qprogressdialog/qprogressdialog.pro3
-rw-r--r--tests/auto/widgets/dialogs/qprogressdialog/tst_qprogressdialog.cpp2
-rw-r--r--tests/auto/widgets/dialogs/qwizard/qwizard.pro1
-rw-r--r--tests/auto/widgets/dialogs/qwizard/tst_qwizard.cpp8
-rw-r--r--tests/auto/widgets/effects/qpixmapfilter/qpixmapfilter.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsanchorlayout/qgraphicsanchorlayout.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/qgraphicsanchorlayout1.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicseffectsource/qgraphicseffectsource.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicseffectsource/tst_qgraphicseffectsource.cpp2
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsgridlayout/qgraphicsgridlayout.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsgridlayout/tst_qgraphicsgridlayout.cpp2
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsitem/tst_qgraphicsitem.cpp108
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsitemanimation/qgraphicsitemanimation.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicslayout/qgraphicslayout.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicslayoutitem/qgraphicslayoutitem.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicslinearlayout/qgraphicslinearlayout.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsobject/qgraphicsobject.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicspixmapitem/qgraphicspixmapitem.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicspolygonitem/qgraphicspolygonitem.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsproxywidget/tst_qgraphicsproxywidget.cpp2
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsscene/tst_qgraphicsscene.cpp122
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicstransform/qgraphicstransform.pro1
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp4
-rw-r--r--tests/auto/widgets/graphicsview/qgraphicswidget/tst_qgraphicswidget.cpp99
-rw-r--r--tests/auto/widgets/itemviews/qabstractitemview/qabstractitemview.pro1
-rw-r--r--tests/auto/widgets/itemviews/qabstractitemview/tst_qabstractitemview.cpp76
-rw-r--r--tests/auto/widgets/itemviews/qcolumnview/qcolumnview.pro1
-rw-r--r--tests/auto/widgets/itemviews/qcolumnview/tst_qcolumnview.cpp7
-rw-r--r--tests/auto/widgets/itemviews/qdatawidgetmapper/qdatawidgetmapper.pro1
-rw-r--r--tests/auto/widgets/itemviews/qdirmodel/qdirmodel.pro1
-rw-r--r--tests/auto/widgets/itemviews/qfileiconprovider/qfileiconprovider.pro1
-rw-r--r--tests/auto/widgets/itemviews/qheaderview/tst_qheaderview.cpp4
-rw-r--r--tests/auto/widgets/itemviews/qitemdelegate/qitemdelegate.pro1
-rw-r--r--tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp18
-rw-r--r--tests/auto/widgets/itemviews/qitemeditorfactory/qitemeditorfactory.pro1
-rw-r--r--tests/auto/widgets/itemviews/qitemview/qitemview.pro1
-rw-r--r--tests/auto/widgets/itemviews/qlistview/qlistview.pro1
-rw-r--r--tests/auto/widgets/itemviews/qlistview/tst_qlistview.cpp19
-rw-r--r--tests/auto/widgets/itemviews/qlistwidget/qlistwidget.pro1
-rw-r--r--tests/auto/widgets/itemviews/qtableview/tst_qtableview.cpp9
-rw-r--r--tests/auto/widgets/itemviews/qtablewidget/qtablewidget.pro1
-rw-r--r--tests/auto/widgets/itemviews/qtablewidget/tst_qtablewidget.cpp2
-rw-r--r--tests/auto/widgets/itemviews/qtreeview/qtreeview.pro1
-rw-r--r--tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp115
-rw-r--r--tests/auto/widgets/itemviews/qtreewidget/qtreewidget.pro1
-rw-r--r--tests/auto/widgets/itemviews/qtreewidget/tst_qtreewidget.cpp4
-rw-r--r--tests/auto/widgets/itemviews/qtreewidgetitemiterator/qtreewidgetitemiterator.pro1
-rw-r--r--tests/auto/widgets/itemviews/qtreewidgetitemiterator/tst_qtreewidgetitemiterator.cpp27
-rw-r--r--tests/auto/widgets/kernel/kernel.pro1
-rw-r--r--tests/auto/widgets/kernel/qaction/qaction.pro1
-rw-r--r--tests/auto/widgets/kernel/qactiongroup/qactiongroup.pro1
-rw-r--r--tests/auto/widgets/kernel/qapplication/desktopsettingsaware/desktopsettingsaware.pro1
-rw-r--r--tests/auto/widgets/kernel/qapplication/modal/modal.pro1
-rw-r--r--tests/auto/widgets/kernel/qapplication/test/test.pro3
-rw-r--r--tests/auto/widgets/kernel/qapplication/tst_qapplication.cpp5
-rw-r--r--tests/auto/widgets/kernel/qapplication/wincmdline/main.cpp7
-rw-r--r--tests/auto/widgets/kernel/qapplication/wincmdline/wincmdline.pro1
-rw-r--r--tests/auto/widgets/kernel/qboxlayout/qboxlayout.pro1
-rw-r--r--tests/auto/widgets/kernel/qdesktopwidget/qdesktopwidget.pro1
-rw-r--r--tests/auto/widgets/kernel/qdesktopwidget/tst_qdesktopwidget.cpp17
-rw-r--r--tests/auto/widgets/kernel/qformlayout/qformlayout.pro1
-rw-r--r--tests/auto/widgets/kernel/qformlayout/tst_qformlayout.cpp6
-rw-r--r--tests/auto/widgets/kernel/qgridlayout/qgridlayout.pro1
-rw-r--r--tests/auto/widgets/kernel/qlayout/qlayout.pro1
-rw-r--r--tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp12
-rw-r--r--tests/auto/widgets/kernel/qshortcut/qshortcut.pro3
-rw-r--r--tests/auto/widgets/kernel/qshortcut/tst_qshortcut.cpp2
-rw-r--r--tests/auto/widgets/kernel/qsizepolicy/qsizepolicy.pro1
-rw-r--r--tests/auto/widgets/kernel/qstackedlayout/qstackedlayout.pro1
-rw-r--r--tests/auto/widgets/kernel/qstackedlayout/tst_qstackedlayout.cpp1
-rw-r--r--tests/auto/widgets/kernel/qtooltip/qtooltip.pro1
-rw-r--r--tests/auto/widgets/kernel/qtooltip/tst_qtooltip.cpp2
-rw-r--r--tests/auto/widgets/kernel/qwidget/qwidget.pro1
-rw-r--r--tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp42
-rw-r--r--tests/auto/widgets/kernel/qwidget_window/qwidget_window.pro1
-rw-r--r--tests/auto/widgets/kernel/qwidgetaction/qwidgetaction.pro1
-rw-r--r--tests/auto/widgets/kernel/qwidgetmetatype/qwidgetmetatype.pro1
-rw-r--r--tests/auto/widgets/kernel/qwidgetsvariant/qwidgetsvariant.pro1
-rw-r--r--tests/auto/widgets/kernel/qwindowcontainer/.gitignore1
-rw-r--r--tests/auto/widgets/kernel/qwindowcontainer/qwindowcontainer.pro6
-rw-r--r--tests/auto/widgets/kernel/qwindowcontainer/tst_qwindowcontainer.cpp226
-rw-r--r--tests/auto/widgets/styles/qmacstyle/qmacstyle.pro1
-rw-r--r--tests/auto/widgets/styles/qmacstyle/tst_qmacstyle.cpp4
-rw-r--r--tests/auto/widgets/styles/qstyle/qstyle.pro1
-rw-r--r--tests/auto/widgets/styles/qstyle/tst_qstyle.cpp13
-rw-r--r--tests/auto/widgets/styles/qstyleoption/qstyleoption.pro1
-rw-r--r--tests/auto/widgets/styles/qstyleoption/tst_qstyleoption.cpp6
-rw-r--r--tests/auto/widgets/styles/qstylesheetstyle/qstylesheetstyle.pro1
-rw-r--r--tests/auto/widgets/styles/qstylesheetstyle/tst_qstylesheetstyle.cpp6
-rw-r--r--tests/auto/widgets/util/qcompleter/qcompleter.pro1
-rw-r--r--tests/auto/widgets/util/qcompleter/tst_qcompleter.cpp95
-rw-r--r--tests/auto/widgets/util/qscroller/qscroller.pro1
-rw-r--r--tests/auto/widgets/util/qscroller/tst_qscroller.cpp21
-rw-r--r--tests/auto/widgets/util/qsystemtrayicon/qsystemtrayicon.pro1
-rw-r--r--tests/auto/widgets/util/qundogroup/qundogroup.pro1
-rw-r--r--tests/auto/widgets/util/qundogroup/tst_qundogroup.cpp2
-rw-r--r--tests/auto/widgets/util/qundostack/qundostack.pro1
-rw-r--r--tests/auto/widgets/util/qundostack/tst_qundostack.cpp92
-rw-r--r--tests/auto/widgets/widgets/qabstractbutton/qabstractbutton.pro1
-rw-r--r--tests/auto/widgets/widgets/qabstractscrollarea/qabstractscrollarea.pro1
-rw-r--r--tests/auto/widgets/widgets/qabstractslider/qabstractslider.pro1
-rw-r--r--tests/auto/widgets/widgets/qabstractspinbox/qabstractspinbox.pro1
-rw-r--r--tests/auto/widgets/widgets/qbuttongroup/qbuttongroup.pro1
-rw-r--r--tests/auto/widgets/widgets/qcalendarwidget/qcalendarwidget.pro1
-rw-r--r--tests/auto/widgets/widgets/qcalendarwidget/tst_qcalendarwidget.cpp16
-rw-r--r--tests/auto/widgets/widgets/qcheckbox/qcheckbox.pro1
-rw-r--r--tests/auto/widgets/widgets/qcombobox/tst_qcombobox.cpp18
-rw-r--r--tests/auto/widgets/widgets/qcommandlinkbutton/qcommandlinkbutton.pro1
-rw-r--r--tests/auto/widgets/widgets/qdatetimeedit/qdatetimeedit.pro1
-rw-r--r--tests/auto/widgets/widgets/qdatetimeedit/tst_qdatetimeedit.cpp19
-rw-r--r--tests/auto/widgets/widgets/qdial/qdial.pro1
-rw-r--r--tests/auto/widgets/widgets/qdialogbuttonbox/qdialogbuttonbox.pro1
-rw-r--r--tests/auto/widgets/widgets/qdialogbuttonbox/tst_qdialogbuttonbox.cpp20
-rw-r--r--tests/auto/widgets/widgets/qdockwidget/qdockwidget.pro1
-rw-r--r--tests/auto/widgets/widgets/qdoublespinbox/qdoublespinbox.pro1
-rw-r--r--tests/auto/widgets/widgets/qfocusframe/qfocusframe.pro1
-rw-r--r--tests/auto/widgets/widgets/qfontcombobox/qfontcombobox.pro1
-rw-r--r--tests/auto/widgets/widgets/qgroupbox/qgroupbox.pro1
-rw-r--r--tests/auto/widgets/widgets/qlabel/qlabel.pro1
-rw-r--r--tests/auto/widgets/widgets/qlcdnumber/qlcdnumber.pro1
-rw-r--r--tests/auto/widgets/widgets/qlineedit/qlineedit.pro1
-rw-r--r--tests/auto/widgets/widgets/qlineedit/tst_qlineedit.cpp5
-rw-r--r--tests/auto/widgets/widgets/qmainwindow/qmainwindow.pro1
-rw-r--r--tests/auto/widgets/widgets/qmainwindow/tst_qmainwindow.cpp20
-rw-r--r--tests/auto/widgets/widgets/qmdiarea/qmdiarea.pro1
-rw-r--r--tests/auto/widgets/widgets/qmdiarea/tst_qmdiarea.cpp21
-rw-r--r--tests/auto/widgets/widgets/qmdisubwindow/qmdisubwindow.pro1
-rw-r--r--tests/auto/widgets/widgets/qmdisubwindow/tst_qmdisubwindow.cpp39
-rw-r--r--tests/auto/widgets/widgets/qmenu/qmenu.pro1
-rw-r--r--tests/auto/widgets/widgets/qmenubar/qmenubar.pro1
-rw-r--r--tests/auto/widgets/widgets/qmenubar/tst_qmenubar.cpp2
-rw-r--r--tests/auto/widgets/widgets/qplaintextedit/qplaintextedit.pro1
-rw-r--r--tests/auto/widgets/widgets/qplaintextedit/tst_qplaintextedit.cpp2
-rw-r--r--tests/auto/widgets/widgets/qprogressbar/qprogressbar.pro1
-rw-r--r--tests/auto/widgets/widgets/qprogressbar/tst_qprogressbar.cpp47
-rw-r--r--tests/auto/widgets/widgets/qpushbutton/qpushbutton.pro1
-rw-r--r--tests/auto/widgets/widgets/qpushbutton/tst_qpushbutton.cpp2
-rw-r--r--tests/auto/widgets/widgets/qradiobutton/qradiobutton.pro1
-rw-r--r--tests/auto/widgets/widgets/qscrollarea/qscrollarea.pro1
-rw-r--r--tests/auto/widgets/widgets/qscrollarea/tst_qscrollarea.cpp2
-rw-r--r--tests/auto/widgets/widgets/qscrollbar/qscrollbar.pro1
-rw-r--r--tests/auto/widgets/widgets/qsizegrip/qsizegrip.pro1
-rw-r--r--tests/auto/widgets/widgets/qslider/qslider.pro1
-rw-r--r--tests/auto/widgets/widgets/qspinbox/qspinbox.pro1
-rw-r--r--tests/auto/widgets/widgets/qsplitter/qsplitter.pro1
-rw-r--r--tests/auto/widgets/widgets/qsplitter/tst_qsplitter.cpp14
-rw-r--r--tests/auto/widgets/widgets/qstackedwidget/qstackedwidget.pro1
-rw-r--r--tests/auto/widgets/widgets/qstatusbar/qstatusbar.pro1
-rw-r--r--tests/auto/widgets/widgets/qstatusbar/tst_qstatusbar.cpp4
-rw-r--r--tests/auto/widgets/widgets/qtabbar/qtabbar.pro1
-rw-r--r--tests/auto/widgets/widgets/qtabwidget/qtabwidget.pro1
-rw-r--r--tests/auto/widgets/widgets/qtabwidget/tst_qtabwidget.cpp4
-rw-r--r--tests/auto/widgets/widgets/qtextbrowser/qtextbrowser.pro1
-rw-r--r--tests/auto/widgets/widgets/qtextedit/qtextedit.pro1
-rw-r--r--tests/auto/widgets/widgets/qtextedit/tst_qtextedit.cpp4
-rw-r--r--tests/auto/widgets/widgets/qtoolbar/qtoolbar.pro1
-rw-r--r--tests/auto/widgets/widgets/qtoolbox/qtoolbox.pro1
-rw-r--r--tests/auto/widgets/widgets/qtoolbutton/qtoolbutton.pro1
-rw-r--r--tests/auto/xml/dom/qdom/qdom.pro1
-rw-r--r--tests/auto/xml/dom/qdom/tst_qdom.cpp18
-rw-r--r--tests/auto/xml/sax/qxml/qxml.pro1
-rw-r--r--tests/auto/xml/sax/qxml/tst_qxml.cpp6
-rw-r--r--tests/auto/xml/sax/qxmlinputsource/qxmlinputsource.pro1
-rw-r--r--tests/auto/xml/sax/qxmlinputsource/tst_qxmlinputsource.cpp4
-rw-r--r--tests/auto/xml/sax/qxmlsimplereader/parser/parser.cpp2
-rw-r--r--tests/auto/xml/sax/qxmlsimplereader/parser/parser.pro1
-rw-r--r--tests/auto/xml/sax/qxmlsimplereader/qxmlsimplereader.pro1
-rw-r--r--tests/auto/xml/sax/sax.pro4
-rw-r--r--tests/baselineserver/shared/lookup3.cpp32
-rw-r--r--tests/benchmarks/README48
-rw-r--r--tests/benchmarks/benchmarks.pro2
-rw-r--r--tests/benchmarks/corelib/io/qdir/tree/bench_qdir_tree.cpp6
-rw-r--r--tests/benchmarks/corelib/io/qdiriterator/qfilesystemiterator.cpp14
-rw-r--r--tests/benchmarks/corelib/io/qdiriterator/qfilesystemiterator.h4
-rw-r--r--tests/benchmarks/corelib/io/qfile/main.cpp16
-rw-r--r--tests/benchmarks/corelib/tools/containers-associative/main.cpp16
-rw-r--r--tests/benchmarks/corelib/tools/qmap/main.cpp78
-rw-r--r--tests/benchmarks/corelib/tools/qregexp/main.cpp10
-rw-r--r--tests/benchmarks/corelib/tools/qvector/main.cpp39
-rw-r--r--tests/benchmarks/corelib/tools/qvector/qrawvector.h6
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.cpp14
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.cpp23
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.cpp14
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.h4
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.cpp1
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.h8
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/button.cpp22
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/button.h8
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.cpp4
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.h2
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.cpp22
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.h6
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.h2
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.cpp6
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.h2
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.cpp12
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.h2
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/label.cpp16
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/label.h2
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.cpp74
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.cpp4
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.h2
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.cpp6
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.cpp2
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.cpp8
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.cpp18
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.h6
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.cpp24
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.h6
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.cpp4
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/resourcemoninterface.h16
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.cpp36
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.h6
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.cpp10
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.h8
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.cpp10
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.cpp24
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.h2
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.cpp4
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.h2
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.cpp156
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.h31
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.cpp28
-rw-r--r--tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/webview_p.h2
-rw-r--r--tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/main.cpp2
-rw-r--r--tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.h2
-rw-r--r--tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/view.h2
-rw-r--r--tests/benchmarks/gui/graphicsview/qgraphicsview/chiptester/chiptester.h4
-rw-r--r--tests/benchmarks/gui/image/blendbench/main.cpp2
-rw-r--r--tests/benchmarks/gui/image/image.pro2
-rw-r--r--tests/benchmarks/gui/image/qimagereader/images/black.xpm30
-rw-r--r--tests/benchmarks/gui/itemviews/qtableview/tst_qtableview.cpp14
-rw-r--r--tests/benchmarks/gui/painting/qtbench/benchmarktests.h2
-rw-r--r--tests/benchmarks/gui/text/qtext/main.cpp2
-rw-r--r--tests/benchmarks/network/access/qnetworkreply/tst_qnetworkreply.cpp26
-rw-r--r--tests/benchmarks/sql/kernel/qsqlquery/main.cpp80
-rw-r--r--tests/benchmarks/sql/kernel/qsqlquery/qsqlquery.pro2
-rw-r--r--tests/manual/bearerex/bearerex.cpp42
-rw-r--r--tests/manual/bearerex/bearerex.h8
-rw-r--r--tests/manual/bearerex/xqlistwidget.cpp4
-rw-r--r--tests/manual/bearerex/xqlistwidget.h4
-rw-r--r--tests/manual/cocoa/nativewidgets/main.cpp147
-rw-r--r--tests/manual/cocoa/nativewidgets/nativewigets.pro7
-rw-r--r--tests/manual/dialogs/colordialogpanel.cpp261
-rw-r--r--tests/manual/dialogs/colordialogpanel.h86
-rw-r--r--tests/manual/dialogs/dialogs.pro6
-rw-r--r--tests/manual/dialogs/filedialogpanel.cpp105
-rw-r--r--tests/manual/dialogs/filedialogpanel.h13
-rw-r--r--tests/manual/dialogs/fontdialogpanel.cpp208
-rw-r--r--tests/manual/dialogs/fontdialogpanel.h87
-rw-r--r--tests/manual/dialogs/main.cpp7
-rw-r--r--tests/manual/dialogs/wizardpanel.cpp361
-rw-r--r--tests/manual/dialogs/wizardpanel.h69
-rw-r--r--tests/manual/filetest/main.cpp45
-rw-r--r--tests/manual/gestures/graphicsview/main.cpp11
-rw-r--r--tests/manual/gestures/scrollarea/main.cpp12
-rw-r--r--tests/manual/highdpi/highdpi.qrc8
-rw-r--r--tests/manual/highdpi/main.cpp201
-rw-r--r--tests/manual/highdpi/qticon16.pngbin0 -> 1884 bytes
-rw-r--r--tests/manual/highdpi/qticon16@2x.pngbin0 -> 3187 bytes
-rw-r--r--tests/manual/highdpi/qticon32.pngbin0 -> 3187 bytes
-rw-r--r--tests/manual/highdpi/qticon32@2x.png (renamed from tests/manual/highdpi/qticon.png)bin6474 -> 6474 bytes
-rw-r--r--tests/manual/highdpi/qticon64.pngbin0 -> 6474 bytes
-rw-r--r--tests/manual/highdpi/qticon@2x.pngbin17168 -> 0 bytes
-rw-r--r--tests/manual/highdpi/qticon_large.pngbin17168 -> 0 bytes
-rw-r--r--tests/manual/inputmethodhints/inputmethodhints.h4
-rw-r--r--tests/manual/inputmethodhints/main.cpp1
-rw-r--r--tests/manual/keypadnavigation/main.cpp9
-rw-r--r--tests/manual/lance/lance.pro1
-rw-r--r--tests/manual/manual.pro15
-rw-r--r--tests/manual/qcursor/allcursors/main.cpp2
-rw-r--r--tests/manual/qcursor/allcursors/mainwindow.h2
-rw-r--r--tests/manual/qcursor/grab_override/main.cpp2
-rw-r--r--tests/manual/qcursor/grab_override/mainwindow.h6
-rw-r--r--tests/manual/qdesktopwidget/main.cpp6
-rw-r--r--tests/manual/qgraphicsitem/main.cpp10
-rw-r--r--tests/manual/qgraphicsitemgroup/main.cpp2
-rw-r--r--tests/manual/qgraphicslayout/flicker/main.cpp3
-rw-r--r--tests/manual/qgraphicslayout/flicker/window.h20
-rw-r--r--tests/manual/qimagereader/main.cpp7
-rw-r--r--tests/manual/qlocale/calendar.cpp19
-rw-r--r--tests/manual/qlocale/calendar.h12
-rw-r--r--tests/manual/qlocale/currency.cpp4
-rw-r--r--tests/manual/qlocale/currency.h6
-rw-r--r--tests/manual/qlocale/dateformats.cpp7
-rw-r--r--tests/manual/qlocale/dateformats.h8
-rw-r--r--tests/manual/qlocale/info.cpp6
-rw-r--r--tests/manual/qlocale/info.h7
-rw-r--r--tests/manual/qlocale/languages.cpp4
-rw-r--r--tests/manual/qlocale/languages.h6
-rw-r--r--tests/manual/qlocale/main.cpp2
-rw-r--r--tests/manual/qlocale/miscellaneous.cpp4
-rw-r--r--tests/manual/qlocale/miscellaneous.h6
-rw-r--r--tests/manual/qlocale/numberformats.cpp6
-rw-r--r--tests/manual/qlocale/numberformats.h6
-rw-r--r--tests/manual/qlocale/window.cpp7
-rw-r--r--tests/manual/qlocale/window.h5
-rw-r--r--tests/manual/qnetworkreply/main.cpp6
-rw-r--r--tests/manual/qpainfo/main.cpp220
-rw-r--r--tests/manual/qpainfo/qpainfo.pro7
-rw-r--r--tests/manual/qtbug-8933/main.cpp2
-rw-r--r--tests/manual/qtouchevent/main.cpp3
-rw-r--r--tests/manual/qtouchevent/qtouchevent.pro3
-rw-r--r--tests/manual/qtouchevent/touchwidget.cpp2
-rw-r--r--tests/manual/qwidget_zorder/main.cpp6
-rw-r--r--tests/manual/repaint/mainwindow/main.cpp19
-rw-r--r--tests/manual/repaint/scrollarea/main.cpp9
-rw-r--r--tests/manual/repaint/shared/shared.h6
-rw-r--r--tests/manual/repaint/splitter/main.cpp7
-rw-r--r--tests/manual/repaint/tableview/main.cpp11
-rw-r--r--tests/manual/repaint/task141091/main.cpp15
-rw-r--r--tests/manual/repaint/toplevel/main.cpp3
-rw-r--r--tests/manual/repaint/widget/main.cpp12
-rw-r--r--tests/manual/textrendering/glyphshaping/main.cpp10
-rw-r--r--tests/manual/textrendering/textperformance/main.cpp7
-rw-r--r--tests/manual/transientwindow/main.cpp51
-rw-r--r--tests/manual/transientwindow/mainwindow.cpp66
-rw-r--r--tests/manual/transientwindow/mainwindow.h64
-rw-r--r--tests/manual/transientwindow/transientwindow.pro6
-rw-r--r--tests/manual/widgets/itemviews/delegate/example.cpp7
-rw-r--r--tests/manual/widgets/itemviews/qheaderview/qheaderviewtest1.cpp3
-rw-r--r--tests/manual/widgets/qgraphicsview/rubberband/rubberbandtest.cpp41
-rw-r--r--tests/manual/windowflags/controls.cpp4
-rw-r--r--tests/manual/windowgeometry/controllerwidget.cpp12
-rwxr-xr-xtests/manual/xembed-raster/gtk-embedder.py74
-rw-r--r--tests/manual/xembed-raster/main.cpp66
-rw-r--r--tests/manual/xembed-raster/rasterwindow.cpp107
-rw-r--r--tests/manual/xembed-raster/rasterwindow.h69
-rw-r--r--tests/manual/xembed-raster/xembed-raster.pro9
-rwxr-xr-xtests/manual/xembed-widgets/gtk-embedder.py77
-rw-r--r--tests/manual/xembed-widgets/main.cpp69
-rw-r--r--tests/manual/xembed-widgets/window.cpp228
-rw-r--r--tests/manual/xembed-widgets/window.h73
-rw-r--r--tests/manual/xembed-widgets/xembed-widgets.pro9
-rw-r--r--tools/configure/configureapp.cpp191
-rw-r--r--util/corelib/qurl-generateTLDs/main.cpp34
-rw-r--r--util/glgen/README.txt151
-rw-r--r--util/glgen/codegenerator.cpp1099
-rw-r--r--util/glgen/codegenerator.h149
-rw-r--r--util/glgen/glgen.pro35
-rw-r--r--util/glgen/main.cpp61
-rw-r--r--util/glgen/qopenglextensions.cpp.footer792
-rw-r--r--util/glgen/qopenglextensions.cpp.header76
-rw-r--r--util/glgen/qopenglextensions.h.footer1520
-rw-r--r--util/glgen/qopenglextensions.h.header96
-rw-r--r--util/glgen/qopenglversionfunctions.cpp.footer8
-rw-r--r--util/glgen/qopenglversionfunctions.cpp.header220
-rw-r--r--util/glgen/qopenglversionfunctions.h.footer13
-rw-r--r--util/glgen/qopenglversionfunctions.h.header164
-rw-r--r--util/glgen/qopenglversionfunctions__VERSION__.cpp.footer2
-rw-r--r--util/glgen/qopenglversionfunctions__VERSION__.cpp.header55
-rw-r--r--util/glgen/qopenglversionfunctions__VERSION__.h.footer6
-rw-r--r--util/glgen/qopenglversionfunctions__VERSION__.h.header62
-rw-r--r--util/glgen/qopenglversionfunctionsfactory.cpp.footer2
-rw-r--r--util/glgen/qopenglversionfunctionsfactory.cpp.header52
-rw-r--r--util/glgen/qopenglversionfunctionsfactory_p.h.header73
-rw-r--r--util/glgen/specparser.cpp312
-rw-r--r--util/glgen/specparser.h210
-rw-r--r--util/lexgen/generator.cpp48
-rw-r--r--util/lexgen/generator.h36
-rw-r--r--util/lexgen/main.cpp4
-rw-r--r--util/lexgen/nfa.cpp4
-rw-r--r--util/lexgen/nfa.h4
-rw-r--r--util/lexgen/tests/tst_lexgen.cpp2
-rw-r--r--util/local_database/enumdata.py134
-rwxr-xr-xutil/local_database/qlocalexml2cpp.py3
-rw-r--r--util/unicode/main.cpp241
3832 files changed, 299132 insertions, 84612 deletions
diff --git a/.gitignore b/.gitignore
index ec33ed9737..5f9854a674 100644
--- a/.gitignore
+++ b/.gitignore
@@ -48,6 +48,7 @@ pcviewer.cfg
core
.qmake.cache
.qmake.vars
+.device.vars
*.prl
tags
.DS_Store
@@ -306,6 +307,7 @@ tests/auto/corelib/thread/qthreadstorage/crashOnExit
tests/auto/corelib/io/qresourceengine/qresourceengine
tests/auto/corelib/codecs/qtextcodec/echo/echo
tests/auto/corelib/plugin/quuid/testProcessUniqueness/testProcessUniqueness
+tests/auto/corelib/io/qlockfile/qlockfiletesthelper/qlockfile_test_helper
tests/auto/dbus/qdbusabstractadaptor/qmyserver/qmyserver
tests/auto/dbus/qdbusabstractinterface/qpinger/qpinger
tests/auto/dbus/qdbusinterface/qmyserver/qmyserver
diff --git a/bin/syncqt b/bin/syncqt
index acfc6c4d57..306c4df57a 100755
--- a/bin/syncqt
+++ b/bin/syncqt
@@ -1,4 +1,4 @@
-#!/usr/bin/perl
+#!/usr/bin/env perl
#############################################################################
##
## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
@@ -763,7 +763,6 @@ my $class_lib_map_contents = "";
our @ignore_headers = ();
our @ignore_for_master_contents = ();
our @ignore_for_include_check = ();
-our @ignore_for_qt_begin_header_check = ();
our @ignore_for_qt_begin_namespace_check = ();
our @ignore_for_qt_module_check = ();
our %inject_headers = ();
@@ -1124,9 +1123,9 @@ if($check_includes) {
foreach my $subdir (@subdirs) {
my @headers = findFiles($subdir, "^[-a-z0-9_]*\\.h\$" , 0);
foreach my $header (@headers) {
- my $header_skip_qt_begin_header_test = 0;
my $header_skip_qt_begin_namespace_test = 0;
$header = 0 if($header =~ /^ui_.*.h/);
+ $header = 0 if ($header eq lc($lib)."version.h");
foreach (@ignore_headers) {
$header = 0 if($header eq $_);
}
@@ -1144,9 +1143,6 @@ if($check_includes) {
foreach (@ignore_for_include_check) {
$public_header = 0 if($header eq $_);
}
- foreach(@ignore_for_qt_begin_header_check) {
- $header_skip_qt_begin_header_test = 1 if ($header eq $_);
- }
foreach(@ignore_for_qt_begin_namespace_check) {
$header_skip_qt_begin_namespace_test = 1 if ($header eq $_);
}
@@ -1156,10 +1152,9 @@ if($check_includes) {
my $iheader = $subdir . "/" . $header;
if($public_header) {
if(open(F, "<$iheader")) {
- my $qt_begin_header_found = 0;
- my $qt_end_header_found = 0;
my $qt_begin_namespace_found = 0;
my $qt_end_namespace_found = 0;
+ my $qt_namespace_suffix = "";
my $line;
my $stop_processing = 0;
while($line = <F>) {
@@ -1184,25 +1179,13 @@ if($check_includes) {
}
}
}
- } elsif ($header_skip_qt_begin_header_test == 0 and $line =~ /^QT_BEGIN_HEADER\s*$/) {
- $qt_begin_header_found = 1;
- } elsif ($header_skip_qt_begin_header_test == 0 and $line =~ /^QT_END_HEADER\s*$/) {
- $qt_end_header_found = 1;
- } elsif ($header_skip_qt_begin_namespace_test == 0 and $line =~ /^QT_BEGIN_NAMESPACE\s*$/) {
+ } elsif ($header_skip_qt_begin_namespace_test == 0 and $line =~ /^QT_BEGIN_NAMESPACE(_[A-Z_]+)?\s*$/) {
+ $qt_namespace_suffix = $1 // "";
$qt_begin_namespace_found = 1;
- } elsif ($header_skip_qt_begin_namespace_test == 0 and $line =~ /^QT_END_NAMESPACE\s*$/) {
+ } elsif ($header_skip_qt_begin_namespace_test == 0 and $line =~ /^QT_END_NAMESPACE$qt_namespace_suffix\s*$/) {
$qt_end_namespace_found = 1;
}
}
- if ($header_skip_qt_begin_header_test == 0 and $stop_processing == 0) {
- if ($qt_begin_header_found == 0) {
- print "$lib: WARNING: $iheader does not include QT_BEGIN_HEADER\n";
- }
-
- if ($qt_begin_header_found && $qt_end_header_found == 0) {
- print "$lib: WARNING: $iheader has QT_BEGIN_HEADER but no QT_END_HEADER\n";
- }
- }
if ($header_skip_qt_begin_namespace_test == 0 and $stop_processing == 0) {
if ($qt_begin_namespace_found == 0) {
@@ -1210,7 +1193,7 @@ if($check_includes) {
}
if ($qt_begin_namespace_found && $qt_end_namespace_found == 0) {
- print "$lib: WARNING: $iheader has QT_BEGIN_NAMESPACE but no QT_END_NAMESPACE\n";
+ print "$lib: WARNING: $iheader has QT_BEGIN_NAMESPACE$qt_namespace_suffix but no QT_END_NAMESPACE$qt_namespace_suffix\n";
}
}
diff --git a/config.tests/arch/arch.pro b/config.tests/arch/arch.pro
index c6801264b4..fda4acc601 100644
--- a/config.tests/arch/arch.pro
+++ b/config.tests/arch/arch.pro
@@ -1,3 +1,4 @@
+TARGET = arch
SOURCES = arch.cpp
CONFIG -= qt dylib release debug_and_release
CONFIG += debug console
diff --git a/config.tests/arch/arch_host.pro b/config.tests/arch/arch_host.pro
new file mode 100644
index 0000000000..f7acef0c5d
--- /dev/null
+++ b/config.tests/arch/arch_host.pro
@@ -0,0 +1,2 @@
+option(host_build)
+include(arch.pro)
diff --git a/config.tests/qpa/linuxfb/linuxfb.cpp b/config.tests/qpa/linuxfb/linuxfb.cpp
index 892c3d9eae..81a257864e 100644
--- a/config.tests/qpa/linuxfb/linuxfb.cpp
+++ b/config.tests/qpa/linuxfb/linuxfb.cpp
@@ -40,6 +40,7 @@
****************************************************************************/
#include <linux/fb.h>
+#include <sys/kd.h>
#include <sys/ioctl.h>
int main(int, char **)
diff --git a/config.tests/unix/arch.test b/config.tests/unix/arch.test
index dacdcda8bf..e65541cda7 100755
--- a/config.tests/unix/arch.test
+++ b/config.tests/unix/arch.test
@@ -5,26 +5,20 @@ VERBOSE=$2
SRCDIR=$3
OUTDIR=$4
RESULTFILE=$5
-VARPREFIX=$6
+TARGET=$6
shift 6
+if [ "$TARGET" = "host" ]; then
+ VARPREFIX="CFG_HOST"
+ PROSUFFIX="_host"
+else
+ VARPREFIX="CFG"
+ PROSUFFIX=""
+fi
+
LFLAGS="$SYSROOT_FLAG"
CXXFLAGS="$SYSROOT_FLAG"
-while [ "$#" -gt 0 ]; do
- PARAM=$1
- case $PARAM in
- -sdk)
- LFLAGS="$LFLAGS -Wl,-syslibroot,$2"
- CXXFLAGS="$CXXFLAGS -isysroot $2"
- shift
- ;;
- *) ;;
- esac
- shift
-done
-
-
# debuggery
[ "$VERBOSE" = "yes" ] && echo "Determining architecture... ($*)"
@@ -32,7 +26,7 @@ done
test -d "$OUTDIR/config.tests/arch" || mkdir -p "$OUTDIR/config.tests/arch"
cd "$OUTDIR/config.tests/arch"
[ -f Makefile ] && $MAKE distclean >/dev/null 2>&1
-OUTDIR=$OUTDIR "$OUTDIR/bin/qmake" -nocache -spec "$QMKSPEC" "QT_BUILD_TREE=$OUTDIR" "LIBS+=$LFLAGS" "QMAKE_CXXFLAGS+=$CXXFLAGS" "$SRCDIR/config.tests/arch/arch.pro" >/dev/null 2>&1 || echo "qmake is broken" >&2
+OUTDIR=$OUTDIR "$OUTDIR/bin/qmake" -nocache -spec "$QMKSPEC" "QT_BUILD_TREE=$OUTDIR" "LIBS+=$LFLAGS" "QMAKE_CXXFLAGS+=$CXXFLAGS" "$SRCDIR/config.tests/arch/arch$PROSUFFIX.pro" >/dev/null 2>&1 || echo "qmake is broken" >&2
ARCH=""
@@ -42,6 +36,8 @@ if [ -f ./arch.exe ]; then
binary=./arch.exe
elif [ -f ./arch ]; then
binary=./arch
+elif [ -f ./libarch.so ]; then
+ binary=./libarch.so
else
[ "$VERBOSE" = "yes" ] && echo "Unable to determine architecture!"
exit 2
diff --git a/config.tests/unix/clock-monotonic/clock-monotonic.cpp b/config.tests/unix/clock-monotonic/clock-monotonic.cpp
index 27a653600c..7b7d92bef5 100644
--- a/config.tests/unix/clock-monotonic/clock-monotonic.cpp
+++ b/config.tests/unix/clock-monotonic/clock-monotonic.cpp
@@ -50,7 +50,7 @@ int main(int, char **)
#else
# error "Feature _POSIX_MONOTONIC_CLOCK not available"
// MIPSpro doesn't understand #error, so force a compiler error
- force_compiler_error = true;
+ force_compiler_error = true;
#endif
return 0;
}
diff --git a/config.tests/unix/compile.test b/config.tests/unix/compile.test
index 3f8c5c51a2..6b90044009 100755
--- a/config.tests/unix/compile.test
+++ b/config.tests/unix/compile.test
@@ -32,11 +32,6 @@ while [ "$#" -gt 0 ]; do
MAC_ARCH_LFLAGS="$MAC_ARCH_LFLAGS -arch $2"
shift
;;
- -sdk)
- LFLAGS="$LFLAGS -Wl,-syslibroot,$2"
- CXXFLAGS="$CXXFLAGS -isysroot $2"
- shift
- ;;
-F*|-m*|-x*)
LFLAGS="$LFLAGS $PARAM"
CXXFLAGS="$CXXFLAGS $PARAM"
@@ -72,7 +67,7 @@ test -r Makefile && $MAKE distclean >/dev/null 2>&1
# Make sure output from possible previous tests is gone
rm -f "$EXE" "${EXE}.exe"
-set -- "$OUTDIR/bin/qmake" -nocache -spec "$QMKSPEC" "CONFIG+=$QMAKE_CONFIG" "CONFIG-=debug_and_release" "LIBS*=$LFLAGS" "LIBS+=$MAC_ARCH_LFLAGS" "INCLUDEPATH*=$INCLUDEPATH" "QMAKE_CXXFLAGS*=$CXXFLAGS" "QMAKE_CXXFLAGS+=$MAC_ARCH_CXXFLAGS" "QT_BUILD_TREE=$OUTDIR" "$SRCDIR/$TEST/$EXE.pro" -o "$OUTDIR/$TEST/Makefile"
+set -- "$OUTDIR/bin/qmake" -nocache -spec "$QMKSPEC" "CONFIG+=$QMAKE_CONFIG" "CONFIG+=android_app" "CONFIG-=debug_and_release" "LIBS*=$LFLAGS" "LIBS+=$MAC_ARCH_LFLAGS" "INCLUDEPATH*=$INCLUDEPATH" "QMAKE_CXXFLAGS*=$CXXFLAGS" "QMAKE_CXXFLAGS+=$MAC_ARCH_CXXFLAGS" "QT_BUILD_TREE=$OUTDIR" "$SRCDIR/$TEST/$EXE.pro" -o "$OUTDIR/$TEST/Makefile"
if [ "$VERBOSE" = "yes" ]; then
OUTDIR=$OUTDIR "$@"
$MAKE
@@ -81,7 +76,7 @@ else
$MAKE >/dev/null 2>&1
fi
-( [ -x "$EXE" ] || [ -x "${EXE}.exe" ] ) && SUCCESS=yes
+( [ -f "$EXE" ] || [ -f "${EXE}.exe" ] ) && SUCCESS=yes
# done
if [ "$SUCCESS" != "yes" ]; then
diff --git a/config.tests/unix/eventfd/eventfd.pro b/config.tests/unix/eventfd/eventfd.pro
new file mode 100644
index 0000000000..c41204f49f
--- /dev/null
+++ b/config.tests/unix/eventfd/eventfd.pro
@@ -0,0 +1,3 @@
+SOURCES = main.cpp
+CONFIG -= qt dylib
+mac:CONFIG -= app_bundle
diff --git a/mkspecs/unsupported/linux-android-armeabi-v7a-g++/qplatformdefs.h b/config.tests/unix/eventfd/main.cpp
index 38b5f6e6d2..0523ee0320 100644
--- a/mkspecs/unsupported/linux-android-armeabi-v7a-g++/qplatformdefs.h
+++ b/config.tests/unix/eventfd/main.cpp
@@ -1,9 +1,9 @@
/****************************************************************************
**
-** Copyright (C) 2012 Collabora Ltd, author <robin.burchell@collabora.co.uk>
+** Copyright (C) 2012 Intel Corporation
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtCore module of the Qt Toolkit.
+** This file is part of the config.tests of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -39,4 +39,13 @@
**
****************************************************************************/
-#include "../../common/android/qplatformdefs.h"
+#include <sys/eventfd.h>
+
+int main()
+{
+ eventfd_t value;
+ int fd = eventfd(0, EFD_CLOEXEC);
+ eventfd_read(fd, &value);
+ eventfd_write(fd, value);
+ return 0;
+}
diff --git a/config.tests/unix/getaddrinfo/getaddrinfotest.cpp b/config.tests/unix/getaddrinfo/getaddrinfotest.cpp
index d8dc343f2e..c8c8eb41da 100644
--- a/config.tests/unix/getaddrinfo/getaddrinfotest.cpp
+++ b/config.tests/unix/getaddrinfo/getaddrinfotest.cpp
@@ -59,6 +59,6 @@ int main()
if (getaddrinfo("foo", 0, 0, &res) == 0)
freeaddrinfo(res);
gai_strerror(0);
-
+
return 0;
}
diff --git a/configure b/configure
index 2ea1ea435a..f55e2f622b 100755
--- a/configure
+++ b/configure
@@ -2,6 +2,7 @@
#############################################################################
##
## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+## Copyright (C) 2013 Intel Corporation.
## Contact: http://www.qt-project.org/legal
##
## This file is the build configuration utility of the Qt Toolkit.
@@ -125,7 +126,7 @@ shellArgumentListToQMakeList()
# Helper function for getQMakeConf. It parses include statements in
# qmake.conf and prints out the expanded file
-getQMakeConf1()
+expandQMakeConf()
{
while read line; do case "$line" in
include*)
@@ -136,7 +137,7 @@ getQMakeConf1()
echo "WARNING: Unable to find file $conf_file" >&2
continue
fi
- getQMakeConf1 "$conf_file"
+ expandQMakeConf "$conf_file"
;;
*load\(device_config\)*)
conf_file="$DEVICE_VARS_FILE"
@@ -144,7 +145,7 @@ getQMakeConf1()
echo "WARNING: Unable to find file $conf_file" >&2
continue
fi
- getQMakeConf1 "$conf_file"
+ expandQMakeConf "$conf_file"
;;
*)
echo "$line"
@@ -152,13 +153,19 @@ getQMakeConf1()
esac; done < "$1"
}
-getQMakeConf2()
+extractQMakeVariables()
{
$AWK '
BEGIN {
values["LITERAL_WHITESPACE"] = " "
values["LITERAL_DOLLAR"] = "$"
}
+/^!?host_build:/ {
+ scopeStart = index($0, ":") + 1
+ condition = substr($0, 0, scopeStart - 2)
+ if (condition != "'"$1"'") { next }
+ $0 = substr($0, scopeStart)
+}
/^[_A-Z0-9.]+[ \t]*\+?=/ {
valStart = index($0, "=") + 1
@@ -183,13 +190,26 @@ BEGIN {
}
ovalue = ovalue values[var]
}
- ovalue = ovalue value
+ value = ovalue value
+
+ ovalue = ""
+ while (match(value, /\$\$system\(("[^"]*"|[^)]*)\)/)) {
+ ovalue = ovalue substr(value, 1, RSTART - 1)
+ cmd = substr(value, RSTART + 9, RLENGTH - 10)
+ gsub(/^"|"$/, "", cmd)
+ value = substr(value, RSTART + RLENGTH)
+ while ((cmd | getline line) > 0) {
+ ovalue = ovalue line
+ }
+ close(cmd)
+ }
+ value = ovalue value
combinedValue = values[variable]
if (append == 1 && length(combinedValue) > 0) {
- combinedValue = combinedValue " " ovalue
+ combinedValue = combinedValue " " value
} else {
- combinedValue = ovalue
+ combinedValue = value
}
values[variable] = combinedValue
}
@@ -201,27 +221,76 @@ END {
'
}
-getQMakeConf3()
+getSingleQMakeVariable()
{
echo "$2" | $AWK "/^($1)=/ { print substr(\$0, index(\$0, \"=\") + 1) }"
}
+macSDKify()
+{
+ # Normally we take care of sysrootifying in sdk.prf, but configure extracts some
+ # values before qmake is even built, so we have to duplicate the logic here.
+
+ sdk=$(getSingleQMakeVariable "QMAKE_MAC_SDK" "$1")
+ if [ -z "$sdk" ]; then echo "QMAKE_MAC_SDK must be set when building on Mac" >&2; exit 1; fi
+ sysroot=$(/usr/bin/xcodebuild -sdk $sdk -version Path 2>/dev/null)
+ if [ -z "$sysroot" ]; then echo "Failed to resolve SDK path for '$sdk'" >&2; exit 1; fi
+
+ case "$sdk" in
+ macosx*)
+ version_min_flag="-mmacosx-version-min=$(getSingleQMakeVariable QMAKE_MACOSX_DEPLOYMENT_TARGET "$1")"
+ ;;
+ iphoneos*)
+ version_min_flag="-miphoneos-version-min=$(getSingleQMakeVariable QMAKE_IOS_DEPLOYMENT_TARGET "$1")"
+ ;;
+ iphonesimulator*)
+ version_min_flag="-mios-simulator-version-min=$(getSingleQMakeVariable QMAKE_IOS_DEPLOYMENT_TARGET "$1")"
+ ;;
+ *)
+ ;;
+ esac
+
+ echo "$1" | while read line; do
+ case "$line" in
+ QMAKE_CC=*|QMAKE_CXX=*|QMAKE_FIX_RPATH=*|QMAKE_AR=*|QMAKE_RANLIB=*|QMAKE_LINK=*|QMAKE_LINK_SHLIB=*)
+ # Prefix tool with toolchain path
+ var=$(echo "$line" | cut -d '=' -f 1)
+ val=$(echo "$line" | cut -d '=' -f 2-)
+ sdk_val=$(/usr/bin/xcrun -sdk $sdk -find $(echo $val | cut -d ' ' -f 1))
+ val=$(echo $sdk_val $(echo $val | cut -s -d ' ' -f 2-))
+ echo "$var=$val"
+ ;;
+ QMAKE_CFLAGS=*|QMAKE_CXXFLAGS=*|QMAKE_OBJECTIVE_CFLAGS=*)
+ echo "$line -isysroot $sysroot $version_min_flag"
+ ;;
+ QMAKE_LFLAGS=*)
+ echo "$line -Wl,-syslibroot,$sysroot $version_min_flag"
+ ;;
+ *)
+ echo "$line"
+ ;;
+ esac
+ done
+}
+
# relies on $QMAKESPEC being set correctly. parses include statements in
# qmake.conf and prints out the expanded file
getQMakeConf()
{
if [ -z "$specvals" ]; then
- specvals=`getQMakeConf1 "$QMAKESPEC/qmake.conf" | getQMakeConf2`
+ specvals=`expandQMakeConf "$QMAKESPEC/qmake.conf" | extractQMakeVariables "host_build"`
+ if [ "$BUILD_ON_MAC" = "yes" ]; then specvals=$(macSDKify "$specvals"); fi
fi
- getQMakeConf3 "$1" "$specvals"
+ getSingleQMakeVariable "$1" "$specvals"
}
getXQMakeConf()
{
if [ -z "$xspecvals" ]; then
- xspecvals=`getQMakeConf1 "$XQMAKESPEC/qmake.conf" | getQMakeConf2`
+ xspecvals=`expandQMakeConf "$XQMAKESPEC/qmake.conf" | extractQMakeVariables "!host_build"`
+ if [ "$BUILD_ON_MAC" = "yes" ]; then xspecvals=$(macSDKify "$xspecvals"); fi
fi
- getQMakeConf3 "$1" "$xspecvals"
+ getSingleQMakeVariable "$1" "$xspecvals"
}
compilerSupportsFlag()
@@ -369,6 +438,34 @@ if [ -d /System/Library/Frameworks/Carbon.framework ]; then
BUILD_ON_MAC=yes
PLATFORM_MAC=maybe
fi
+BUILD_ON_MSYS=no
+HOST_DIRLIST_SEP=":"
+if [ "$OSTYPE" = "msys" ]; then
+ HOST_DIRLIST_SEP=";"
+ BUILD_ON_MSYS=yes
+fi
+
+#-------------------------------------------------------------------------------
+# Verify Xcode installation on Mac OS
+#-------------------------------------------------------------------------------
+
+if [ "$BUILD_ON_MAC" = "yes" ]; then
+ if ! /usr/bin/xcode-select --print-path >/dev/null 2>&1; then
+ echo >&2
+ echo " No Xcode is selected. Use xcode-select -switch to choose an Xcode" >&2
+ echo " version. See the xcode-select man page for more information." >&2
+ echo >&2
+ exit 2
+ fi
+
+ if ! /usr/bin/xcrun -find xcrun >/dev/null 2>&1; then
+ echo >&2
+ echo " Xcode not set up properly. You may need to confirm the license" >&2
+ echo " agreement by running /usr/bin/xcodebuild without arguments." >&2
+ echo >&2
+ exit 2
+ fi
+fi
#-----------------------------------------------------------------------------
# Qt version detection
@@ -733,7 +830,7 @@ QMakeVar add styles "mac fusion windows"
unset QTDIR
# the minimum version of libdbus-1 that we require:
-MIN_DBUS_1_VERSION=0.93
+MIN_DBUS_1_VERSION=1.2
# initalize internal variables
CFG_CONFIGURE_EXIT_ON_ERROR=yes
@@ -810,6 +907,7 @@ CFG_KMS=auto
CFG_LIBUDEV=auto
CFG_OBSOLETE_WAYLAND=no
CFG_EVDEV=auto
+CFG_TSLIB=no
CFG_NIS=auto
CFG_CUPS=auto
CFG_ICONV=auto
@@ -844,10 +942,10 @@ CFG_GETADDRINFO=auto
CFG_IPV6IFNAME=auto
CFG_GETIFADDRS=auto
CFG_INOTIFY=auto
+CFG_EVENTFD=auto
CFG_RPATH=yes
CFG_FRAMEWORK=auto
CFG_MAC_HARFBUZZ=no
-CFG_SDK=
DEFINES=
D_FLAGS=
I_FLAGS=
@@ -856,6 +954,7 @@ RPATH_FLAGS=
W_FLAGS=
QCONFIG_FLAGS=
XPLATFORM= # This seems to be the QMAKESPEC, like "linux-g++"
+XPLATFORM_ANDROID=no
XPLATFORM_MINGW=no # Whether target platform is MinGW (win32-g++*)
XPLATFORM_MAEMO=no
XPLATFORM_QNX=no
@@ -876,6 +975,7 @@ CFG_PCRE=auto
QPA_PLATFORM_GUARD=yes
CFG_CXX11=auto
CFG_DIRECTWRITE=no
+CFG_WERROR=auto
# initalize variables used for installation
QT_INSTALL_PREFIX=
@@ -935,6 +1035,15 @@ CFG_SQL_oci=no
CFG_SQL_db2=no
CFG_SQL_AVAILABLE=
+
+# Android vars
+CFG_DEFAULT_ANDROID_NDK_ROOT=$ANDROID_NDK_ROOT
+CFG_DEFAULT_ANDROID_SDK_ROOT=$ANDROID_SDK_ROOT
+CFG_DEFAULT_ANDROID_PLATFORM=android-9
+CFG_DEFAULT_ANDROID_TARGET_ARCH=armeabi-v7a
+CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION=4.7
+CFG_DEFAULT_ANDROID_NDK_HOST=$ANDROID_NDK_HOST
+
if [ -d "$relpath/src/plugins/sqldrivers" ]; then
for a in "$relpath/src/plugins/sqldrivers/"*; do
if [ -d "$a" ]; then
@@ -996,7 +1105,7 @@ while [ "$#" -gt 0 ]; do
VAL=no
;;
#Qt style options that pass an argument
- -prefix|-docdir|-headerdir|-plugindir|-importdir|-qmldir|-archdatadir|-datadir|-libdir|-bindir|-libexecdir|-translationdir|-sysconfdir|-examplesdir|-testsdir|-depths|-make|-nomake|-skip|-platform|-xplatform|-device|-device-option|-sdk|-arch|-host-arch|-mysql_config|-sysroot|-hostdatadir|-hostbindir|-qpa|-qconfig)
+ -prefix|-docdir|-headerdir|-plugindir|-importdir|-qmldir|-archdatadir|-datadir|-libdir|-bindir|-libexecdir|-translationdir|-sysconfdir|-examplesdir|-testsdir|-depths|-make|-nomake|-skip|-platform|-xplatform|-device|-device-option|-sdk|-arch|-host-arch|-mysql_config|-sysroot|-hostdatadir|-hostbindir|-qpa|-qconfig|-android-sdk|-android-ndk|-android-ndk-platform|-android-ndk-host|-android-arch|-android-toolchain-version)
VAR=`echo $1 | sed "s,^-\(.*\),\1,"`
shift
VAL="$1"
@@ -1287,8 +1396,7 @@ while [ "$#" -gt 0 ]; do
;;
sdk)
if [ "$BUILD_ON_MAC" = "yes" ]; then
- CFG_SDK="$VAL"
- DeviceVar set QMAKE_MAC_SDK "$VAL"
+ DeviceVar set !host_build:QMAKE_MAC_SDK "$VAL"
else
UNKNOWN_OPT=yes
fi
@@ -1782,6 +1890,13 @@ while [ "$#" -gt 0 ]; do
UNKNOWN_OPT=yes
fi
;;
+ tslib)
+ if [ "$VAL" = "yes" ] || [ "$VAL" = "no" ]; then
+ CFG_TSLIB="$VAL"
+ else
+ UNKNOWN_OPT=yes
+ fi
+ ;;
cups)
if [ "$VAL" = "yes" ] || [ "$VAL" = "no" ]; then
CFG_CUPS="$VAL"
@@ -2118,6 +2233,31 @@ while [ "$#" -gt 0 ]; do
UNKNOWN_OPT=yes
fi
;;
+ warnings-are-errors|Werror)
+ if [ "$VAL" = "yes" ] || [ "$VAL" = "no" ]; then
+ CFG_WERROR="$VAL"
+ else
+ UNKNOWN_OPT=yes
+ fi
+ ;;
+ android-sdk)
+ CFG_DEFAULT_ANDROID_SDK_ROOT="$VAL"
+ ;;
+ android-ndk)
+ CFG_DEFAULT_ANDROID_NDK_ROOT="$VAL"
+ ;;
+ android-ndk-platform)
+ CFG_DEFAULT_ANDROID_PLATFORM="$VAL"
+ ;;
+ android-ndk-host)
+ CFG_DEFAULT_ANDROID_NDK_HOST="$VAL"
+ ;;
+ android-arch)
+ CFG_DEFAULT_ANDROID_TARGET_ARCH="$VAL"
+ ;;
+ android-toolchain-version)
+ CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION="$VAL"
+ ;;
l*) # -lfoo
L_FLAGS="$L_FLAGS -l\"${VAR#l}\""
;;
@@ -2333,20 +2473,25 @@ if [ -z "$PLATFORM" ]; then
PLATFORM_NOTES=
case "$UNAME_SYSTEM:$UNAME_RELEASE" in
Darwin:*)
- OSX_VERSION=`uname -r | cut -d. -f1`
- # Select compiler. Use g++ unless we find a usable Clang version
- PLATFORM=macx-g++
- if [ "$OSX_VERSION" -ge 12 ]; then
- # We're on Mountain Lion or above. Use Clang. Don't advertise gcc.
+ # Select compiler. Use g++ unless we find a usable Clang version. Note that
+ # we are checking the "Apple" clang/LLVM version number, not the actual
+ # clang/LLVM version number that the Apple version was based on. We look
+ # for Apple clang version 3.0 or higher, which was branched off LLVM 3.0
+ # from SVN, and first included in Xcode 4.2. Also note that we do not care
+ # about the OS version, since we're not using the clang version that comes
+ # with the system. We use 'xcrun' to check the clang version that's part of
+ # the Xcode installation.
+ if [ "$(/usr/bin/xcrun -sdk macosx clang -v 2>&1 | sed -n 's/.*version \([0-9]\).*/\1/p')" -ge 3 ]; then
PLATFORM=macx-clang
- elif [ "$OSX_VERSION" -eq 11 ]; then
- # We're on Lion. Check if we have a supported Clang version
- if [ "$(clang -v 2>&1 | grep -Po '(?<=version )[\d]')" -ge 3 ]; then
- PLATFORM=macx-clang
- PLATFORM_NOTES="\n - Also available for Mac OS X: macx-g++\n"
- fi
- fi
- ;;
+
+ # Advertise g++ as an alternative on Lion and below
+ if [ "$(uname -r | cut -d. -f1)" -le 11 ]; then
+ PLATFORM_NOTES="\n - Also available for Mac OS X: macx-g++\n"
+ fi
+ else
+ PLATFORM=macx-g++
+ fi
+ ;;
AIX:*)
#PLATFORM=aix-g++
#PLATFORM=aix-g++-64
@@ -2500,8 +2645,89 @@ fi
[ -z "$XPLATFORM" ] && XPLATFORM="$PLATFORM"
case `basename "$XPLATFORM"` in win32-g++*) XPLATFORM_MINGW=yes;; esac
-case "$XPLATFORM" in *-maemo*) XPLATFORM_MAEMO=yes;; esac
-case "$XPLATFORM" in *qnx-*|*blackberry-*) XPLATFORM_QNX=yes;; esac
+case "$XPLATFORM" in
+ *-maemo*)
+ XPLATFORM_MAEMO=yes
+ ;;
+ *qnx-*|*blackberry-*)
+ XPLATFORM_QNX=yes
+ ;;
+ *ios*)
+ XPLATFORM_IOS=yes
+ ;;
+ # XPLATFORM_ANDROID should not be set for unsupported/android-g++
+ *unsupported*)
+ ;;
+ *android-g++*)
+ XPLATFORM_ANDROID=yes
+ ;;
+esac
+
+if [ "$XPLATFORM_ANDROID" = "yes" ]; then
+ if [ -z "$CFG_DEFAULT_ANDROID_NDK_HOST" ]; then
+ case $PLATFORM in
+ linux-*-64)
+ if [ -d "$CFG_DEFAULT_ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-$CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION/prebuilt/linux-x86_64" ]; then
+ CFG_DEFAULT_ANDROID_NDK_HOST=linux-x86_64
+ else
+ CFG_DEFAULT_ANDROID_NDK_HOST=linux-x86
+ fi
+ ;;
+ linux-*)
+ CFG_DEFAULT_ANDROID_NDK_HOST=linux-x86
+ ;;
+ macx-*)
+ CFG_DEFAULT_ANDROID_NDK_HOST=darwin-x86
+ if [ ! -z "$NATIVE_64_ARCH" ] && [ -d "$CFG_DEFAULT_ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-$CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION/prebuilt/darwin-x86_64" ]; then
+ CFG_DEFAULT_ANDROID_NDK_HOST=darwin-x86_64
+ fi
+ ;;
+ win32-*)
+ CFG_DEFAULT_ANDROID_NDK_HOST=windows
+ if [ ! -z "$NATIVE_64_ARCH" ] && [ -d "$CFG_DEFAULT_ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-$CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION/prebuilt/windows-x86_64" ]; then
+ CFG_DEFAULT_ANDROID_NDK_HOST=windows-x86_64
+ fi
+ ;;
+ esac
+ fi
+
+ if [ "$OPT_HELP" != "yes" ]; then
+ if [ -z "$CFG_DEFAULT_ANDROID_NDK_ROOT" ]; then
+ echo
+ echo "Can not find Android NDK. Please use -android-ndk option to specify one"
+ exit 1
+ fi
+ if [ -z "$CFG_DEFAULT_ANDROID_SDK_ROOT" ]; then
+ echo
+ echo "Can not find Android SDK. Please use -android-sdk option to specify one"
+ exit 1
+ fi
+ if [ -z "CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION" ] || [ ! -d "$CFG_DEFAULT_ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-$CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION/prebuilt" ]; then
+ echo
+ echo "Can not detect Android NDK toolchain. Please use -android-toolchain-version to specify"
+ exit 1
+ fi
+ if [ -z "$CFG_DEFAULT_ANDROID_NDK_HOST" ] || [ ! -d "$CFG_DEFAULT_ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-$CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION/prebuilt/$CFG_DEFAULT_ANDROID_NDK_HOST" ]; then
+ echo
+ echo "Can not detect the android host. Please use -android-ndk-host option to specify one"
+ exit 1
+ fi
+
+ QT_QPA_DEFAULT_PLATFORM="android"
+ CFG_LARGEFILE="no"
+
+ # FIXME: Qt Creator requires this to be in the lib/ directory of Qt. This line can be removed
+ # once it's fixed to get the file directly from the NDK.
+ cp -f $CFG_DEFAULT_ANDROID_NDK_ROOT/sources/cxx-stl/gnu-libstdc++/$CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION/libs/$CFG_DEFAULT_ANDROID_TARGET_ARCH/libgnustl_shared.so $outpath/lib
+
+ DeviceVar set DEFAULT_ANDROID_SDK_ROOT "$CFG_DEFAULT_ANDROID_SDK_ROOT"
+ DeviceVar set DEFAULT_ANDROID_NDK_ROOT "$CFG_DEFAULT_ANDROID_NDK_ROOT"
+ DeviceVar set DEFAULT_ANDROID_PLATFORM "$CFG_DEFAULT_ANDROID_PLATFORM"
+ DeviceVar set DEFAULT_ANDROID_NDK_HOST "$CFG_DEFAULT_ANDROID_NDK_HOST"
+ DeviceVar set DEFAULT_ANDROID_TARGET_ARCH "$CFG_DEFAULT_ANDROID_TARGET_ARCH"
+ DeviceVar set DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION "$CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION"
+ fi
+fi
if [ -d "$PLATFORM" ]; then
QMAKESPEC="$PLATFORM"
@@ -2607,28 +2833,13 @@ if [ "$CFG_DEBUG_RELEASE" = "yes" ]; then
fi
if [ "$CFG_FORCEDEBUGINFO" = "yes" ]; then
- QT_CONFIG="$QT_CONFIG force_debug_info"
-fi
-
-# pass on $CFG_SDK to the arch/configure tests.
-if [ -n "$CFG_SDK" ]; then
- MAC_SDK_FLAG="-sdk $CFG_SDK"
-else
- MAC_SDK_FLAG=
+ QMAKE_CONFIG="$QMAKE_CONFIG force_debug_info"
fi
-# find the default framework value
-if [ "$BUILD_ON_MAC" = "yes" ]; then
- if [ "$CFG_FRAMEWORK" = "auto" ]; then
- CFG_FRAMEWORK="$CFG_SHARED"
- elif [ "$CFG_FRAMEWORK" = "yes" ] && [ "$CFG_SHARED" = "no" ]; then
- echo
- echo "WARNING: Using static linking will disable the use of Mac frameworks."
- echo
- CFG_FRAMEWORK="no"
- fi
-else
- CFG_FRAMEWORK=no
+if [ "$XPLATFORM_IOS" = "yes" ]; then
+ CFG_SHARED="no" # iOS builds should be static to be able to submit to the App Store
+ CFG_CXX11="no" # C++11 support disabled for now
+ CFG_SKIP_MODULES="$CFG_SKIP_MODULES qtdeclarative qtquickcontrols qtwebkit qtgraphicaleffects qtdoc qtmultimedia qtwebkit-examples-and-demos qttools"
fi
# disable GTK style support auto-detection on Mac
@@ -2639,6 +2850,32 @@ fi
QMAKE_CONF_COMPILER=`getXQMakeConf QMAKE_CXX`
TEST_COMPILER=$QMAKE_CONF_COMPILER
+
+if [ "$OPT_HELP" != "yes" ] && [ "$XPLATFORM_ANDROID" = "yes" ] ; then
+ ANDROID_NDK_TOOLS_PREFIX=
+ ANDROID_PLATFORM_ARCH=
+ case $CFG_DEFAULT_ANDROID_TARGET_ARCH in
+ armeabi*)
+ ANDROID_NDK_TOOLS_PREFIX=arm-linux-androideabi
+ ANDROID_PLATFORM_ARCH=arch-arm
+ ;;
+ x86)
+ ANDROID_NDK_TOOLS_PREFIX=x86
+ ANDROID_PLATFORM_ARCH=arch-x86
+ ;;
+ mips)
+ ANDROID_NDK_TOOLS_PREFIX=mipsel-linux-android
+ ANDROID_PLATFORM_ARCH=arch-mips
+ ;;
+ *)
+ echo "ERROR: Unknown android arch $CFG_DEFAULT_ANDROID_TARGET_ARCH"
+ exit 1
+ ;;
+ esac
+ QMAKE_CONF_COMPILER=$CFG_DEFAULT_ANDROID_NDK_ROOT/toolchains/$ANDROID_NDK_TOOLS_PREFIX-$CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION/prebuilt/$CFG_DEFAULT_ANDROID_NDK_HOST/bin/$ANDROID_NDK_TOOLS_PREFIX-g++
+ TEST_COMPILER="$QMAKE_CONF_COMPILER --sysroot=$CFG_DEFAULT_ANDROID_NDK_ROOT/platforms/$CFG_DEFAULT_ANDROID_PLATFORM/$ANDROID_PLATFORM_ARCH/"
+fi
+
if [ "$XPLATFORM_SYMBIAN_SBSV2" = "no" ]; then
if [ -z "$TEST_COMPILER" ]; then
echo "ERROR: Cannot set the compiler for the configuration tests"
@@ -2747,15 +2984,17 @@ else
fi
# auto-detect default include and library search paths
-gccout=`$TEST_COMPILER $SYSROOT_FLAG $TEST_COMPILER_CXXFLAGS -xc++ -E -v - < /dev/null 2>&1 > /dev/null`
+gccout=`LC_ALL=C $TEST_COMPILER $SYSROOT_FLAG $TEST_COMPILER_CXXFLAGS -xc++ -E -v - < /dev/null 2>&1 > /dev/null`
+# extract from one line like 'LIBRARY_PATH=/one/path:/another/path:...'
libdirs=`echo "$gccout" | sed -n -e 's/^LIBRARY_PATH=\(.*\)/\1/p'`
-DEFAULT_LIBDIRS=`IFS=:; for i in $libdirs; do test -d "$i" && cd "$i" && pwd; done | sort -u`
+DEFAULT_LIBDIRS=`IFS=${HOST_DIRLIST_SEP}; for i in $libdirs; do test -d "$i" && cd "$i" && pwd; done`
+# extract from indented lines between '#include <...> search starts here:' and 'End of search list.'
DEFAULT_INCDIRS=`echo "$gccout" | awk '
/^End of search/ { yup=0 }
/ \(framework directory\)$/ { next }
yup { print substr($0, 2) }
/^\#include </ { yup=1 }
-' | sort -u`
+'`
test -z "$DEFAULT_LIBDIRS" && DEFAULT_LIBDIRS="/lib
/usr/lib"
test -z "$DEFAULT_INCDIRS" && DEFAULT_INCDIRS="/usr/include
@@ -3093,6 +3332,9 @@ Configure options:
-opensource ........ Compile and link the Open-Source Edition of Qt.
-commercial ........ Compile and link the Commercial Edition of Qt.
+ -confirm-license.... Automatically acknowledge the license (use with
+ either -opensource or -commercial)
+
-no-c++11 .......... Do not compile Qt with C++11 support enabled.
+ -c++11 ............. Compile Qt with C++11 support enabled.
@@ -3197,7 +3439,7 @@ Third Party Libraries:
Additional options:
-make <part> ....... Add part to the list of parts to be built at make time.
- ($QT_DEFAULT_BUILD_PARTS)
+ (defaults to: $QT_DEFAULT_BUILD_PARTS)
-nomake <part> ..... Exclude part from the list of parts to be built.
-skip <module> ..... Exclude an entire module from the build.
@@ -3303,6 +3545,10 @@ Additional options:
* -no-system-proxies .. Do not use system network proxies by default.
-system-proxies ..... Use system network proxies by default.
+ -no-warnings-are-errors Make warnings be treated normally
+ -warnings-are-errors Make warnings be treated as errors
+ (enabled if -developer-build is active)
+
$GBN -no-glib ........... Do not compile Glib support.
$GBY -glib .............. Compile Glib support.
EOF
@@ -3339,8 +3585,8 @@ Qt/Mac only:
link tools against those frameworks.
-no-framework ...... Do not build Qt as a series of frameworks.
- -sdk <sdk> ......... Build Qt using Apple provided SDK <sdk>. This option requires gcc 4.
- To use a different SDK with gcc 3.3, set the SDKROOT environment variable.
+ -sdk <sdk> ......... Build Qt using Apple provided SDK <sdk>. The argument should be
+ one of the available SDKs as listed by 'xcodebuild -showsdks'.
-harfbuzz .......... Use HarfBuzz to do text layout instead of Core Text when possible.
* -no-harfbuzz ....... Disable HarfBuzz on Mac. It can still be enabled by setting
@@ -3349,6 +3595,31 @@ Qt/Mac only:
EOF
fi
+if [ "$XPLATFORM_ANDROID" = "yes" ]; then
+ cat << EOF
+
+Android options:
+ -android-sdk path .............. The Android SDK root path.
+ (default $CFG_DEFAULT_ANDROID_SDK_ROOT)
+
+ -android-ndk path .............. The Android NDK root path.
+ (default $CFG_DEFAULT_ANDROID_NDK_ROOT)
+
+ -android-ndk-platform .......... Sets the android platform
+ (default $CFG_DEFAULT_ANDROID_PLATFORM)
+
+ -android-ndk-host .............. Sets the android NDK host (linux-x86, linux-x86_64, etc.)
+ (default $CFG_DEFAULT_ANDROID_NDK_HOST)
+
+ -android-arch .................. Sets the android architecture (armeabi, armeabi-v7a, x86, mips)
+ (default $CFG_DEFAULT_ANDROID_TARGET_ARCH)
+
+ -android-toolchain-version ..... Sets the android toolchain version
+ (default $CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION)
+EOF
+
+fi
+
[ "x$ERROR" = "xyes" ] && exit 1
exit 0
fi # Help
@@ -3657,10 +3928,6 @@ if true; then ###[ '!' -f "$outpath/bin/qmake" ];
setBootstrapVariable QMAKE_CXXFLAGS
setBootstrapVariable QMAKE_LFLAGS
- if [ $QT_EDITION = "QT_EDITION_OPENSOURCE" ]; then
- EXTRA_CFLAGS="$EXTRA_CFLAGS -DQMAKE_OPENSOURCE_EDITION"
- EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS -DQMAKE_OPENSOURCE_EDITION"
- fi
if [ "$CFG_RELEASE_QMAKE" = "yes" ]; then
setBootstrapVariable QMAKE_CFLAGS_RELEASE
setBootstrapVariable QMAKE_CXXFLAGS_RELEASE
@@ -3679,22 +3946,48 @@ if true; then ###[ '!' -f "$outpath/bin/qmake" ];
EXTRA_LFLAGS="\$(QMAKE_LFLAGS_RPATH)\"$rpath\" $EXTRA_LFLAGS"
done
fi
+ if [ "$BUILD_ON_MSYS" = "yes" ]; then
+ EXTRA_CFLAGS="-DUNICODE"
+ EXTRA_CXXFLAGS="-DUNICODE"
+ EXTRA_OBJS="qfilesystemengine_win.o \
+ qfilesystemiterator_win.o \
+ qfsfileengine_win.o \
+ qlocale_win.o \
+ qsettings_win.o \
+ qsystemlibrary.o \
+ registry.o"
+ EXTRA_SRCS="\"\$(SOURCE_PATH)/src/corelib/corelib/io/qfilesystemengine_win.cpp\" \
+ \"\$(SOURCE_PATH)/src/corelib/io/qfilesystemiterator_win.cpp\" \
+ \"\$(SOURCE_PATH)/src/corelib/io/qfsfileengine_win.cpp\" \
+ \"\$(SOURCE_PATH)/src/corelib/io/qsettings_win.cpp\" \
+ \"\$(SOURCE_PATH)/src/corelib/tools/qlocale_win.cpp\" \
+ \"\$(SOURCE_PATH)/src/corelib/plugin/qsystemlibrary.cpp\" \
+ \"\$(SOURCE_PATH)/tools/shared/windows/registry.cpp\""
+ EXTRA_LFLAGS="-static -s -lole32 -luuid -ladvapi32 -lkernel32"
+ EXEEXT=".exe"
+ else
+ EXTRA_OBJS="qfilesystemengine_unix.o \
+ qfilesystemiterator_unix.o \
+ qfsfileengine_unix.o \
+ qlocale_unix.o"
+ EXTRA_SRCS="\"\$(SOURCE_PATH)/src/corelib/io/qfilesystemengine_unix.cpp\" \
+ \"\$(SOURCE_PATH)/src/corelib/io/qfilesystemiterator_unix.cpp\" \
+ \"\$(SOURCE_PATH)/src/corelib/io/qfsfileengine_unix.cpp\" \
+ \"\$(SOURCE_PATH)/src/corelib/tools/qlocal_unix.cpp\""
+ EXEEXT=
+ fi
if [ "$BUILD_ON_MAC" = "yes" ]; then
- echo "export MACOSX_DEPLOYMENT_TARGET = 10.6" >> "$mkfile"
echo "CARBON_LFLAGS =-framework ApplicationServices" >>"$mkfile"
echo "CARBON_CFLAGS =-fconstant-cfstrings" >>"$mkfile"
EXTRA_LFLAGS="$EXTRA_LFLAGS \$(CARBON_LFLAGS)"
EXTRA_CFLAGS="$EXTRA_CFLAGS \$(CARBON_CFLAGS)"
EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS \$(CARBON_CFLAGS)"
- EXTRA_OBJS="qsettings_mac.o qcore_mac.o"
- EXTRA_SRCS="\"$relpath/src/corelib/io/qsettings_mac.cpp\" \"$relpath/src/corelib/kernel/qcore_mac.cpp\""
- if [ '!' -z "$CFG_SDK" ]; then
- echo "SDK_LFLAGS =-Wl,-syslibroot,$CFG_SDK" >>"$mkfile"
- echo "SDK_CFLAGS =-isysroot $CFG_SDK" >>"$mkfile"
- EXTRA_CFLAGS="$EXTRA_CFLAGS \$(SDK_CFLAGS)"
- EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS \$(SDK_CFLAGS)"
- EXTRA_LFLAGS="$EXTRA_LFLAGS \$(SDK_LFLAGS)"
- fi
+ EXTRA_OBJS="$EXTRA_OBJS \
+ qsettings_mac.o \
+ qcore_mac.o"
+ EXTRA_SRCS="$EXTRA_SRCS \
+ \"\$(SOURCE_PATH)/src/corelib/io/qsettings_mac.cpp\" \
+ \"\$(SOURCE_PATH)/src/corelib/kernel/qcore_mac.cpp\""
fi
if [ '!' -z "$D_FLAGS" ]; then
EXTRA_CFLAGS="$EXTRA_CFLAGS $D_FLAGS"
@@ -3707,13 +4000,25 @@ if true; then ###[ '!' -f "$outpath/bin/qmake" ];
adjrelpath=`echo "$relpath" | sed 's/ /\\\\\\\\ /g'`
adjoutpath=`echo "$outpath" | sed 's/ /\\\\\\\\ /g'`
adjqmakespec=`echo "$QMAKESPEC" | sed 's/ /\\\\\\\\ /g'`
- sed -e "s,@SOURCE_PATH@,$adjrelpath,g" -e "s,@BUILD_PATH@,$adjoutpath,g" \
- -e "s,@QMAKE_CFLAGS@,$EXTRA_CFLAGS,g" -e "s,@QMAKE_LFLAGS@,$EXTRA_LFLAGS,g" \
- -e "s,@QMAKE_CXXFLAGS@,$EXTRA_CXXFLAGS,g" \
- -e "s,@QT_INSTALL_BINS@,\$(INSTALL_ROOT)$QMAKE_BIN_DIR,g" \
- -e "s,@QT_INSTALL_DATA@,\$(INSTALL_ROOT)$QMAKE_DATA_DIR,g" \
- -e "s,@QMAKE_QTOBJS@,$EXTRA_OBJS,g" -e "s,@QMAKE_QTSRCS@,$EXTRA_SRCS,g" \
- -e "s,@QMAKESPEC@,$adjqmakespec,g" -e "s,@QT_VERSION@,$QT_VERSION,g" "$in_mkfile" >>"$mkfile"
+
+ echo "BUILD_PATH = $adjoutpath" >> "$mkfile"
+ echo "SOURCE_PATH = $adjrelpath" >> "$mkfile"
+ echo "QMAKESPEC = $adjqmakespec" >> "$mkfile"
+ echo "QT_VERSION = $QT_VERSION" >> "$mkfile"
+ echo "EXTRA_CFLAGS = $EXTRA_CFLAGS" >> "$mkfile"
+ echo "EXTRA_CXXFLAGS = $EXTRA_CXXFLAGS" >> "$mkfile"
+ echo "QTOBJS = $EXTRA_OBJS" >> "$mkfile"
+ echo "QTSRCS = $EXTRA_SRCS" >> "$mkfile"
+ echo "LFLAGS = $EXTRA_LFLAGS" >> "$mkfile"
+ echo "QT_INSTALL_BINS = \$(INSTALL_ROOT)$QMAKE_BIN_DIR" >> "$mkfile"
+ echo "QT_INSTALL_DATA = \$(INSTALL_ROOT)$QMAKE_DATA_DIR" >> "$mkfile"
+ echo "EXEEXT = $EXEEXT" >> "$mkfile"
+ echo "RM_F = rm -f" >> "$mkfile"
+ echo "RM_RF = rm -rf" >> "$mkfile"
+ if [ $QT_EDITION = "QT_EDITION_OPENSOURCE" ]; then
+ echo "EXTRA_CPPFLAGS = -DQMAKE_OPENSOURCE_EDITION" >> "$mkfile"
+ fi
+ cat "$in_mkfile" >> "$mkfile"
if "$WHICH" makedepend >/dev/null 2>&1 && grep 'depend:' "$mkfile" >/dev/null 2>&1; then
(cd "$outpath/qmake" && "$MAKE" -f "$mkfile" depend) >/dev/null 2>&1
@@ -3750,6 +4055,20 @@ else
fi
#-------------------------------------------------------------------------------
+# Verify makespec
+#-------------------------------------------------------------------------------
+QMAKE_OUTPUT=`$outpath/bin/qmake -E -nocache -spec "$XQMAKESPEC" "QT=" /dev/null 2>&1 >/dev/null`
+if [ $? != "0" ]; then
+ echo "Failed to process makespec for platform '$XPLATFORM'"
+ if [ "$OPT_VERBOSE" = "yes" ]; then
+ echo "$QMAKE_OUTPUT"
+ else
+ echo "Turn on verbose messaging (-v) to see the final report."
+ fi
+ exit 101
+fi
+
+#-------------------------------------------------------------------------------
# Detect pkg-config
#-------------------------------------------------------------------------------
if [ -z "$PKG_CONFIG" ]; then
@@ -3826,7 +4145,7 @@ compileTest()
path=config.tests/$1
name=$2
shift 2
- "$unixtests/compile.test" "$XQMAKESPEC" "$QMAKE_CONFIG" $OPT_VERBOSE "$relpath" "$outpath" "$path" "$name" $I_FLAGS $D_FLAGS $L_FLAGS $MAC_SDK_FLAG "$@"
+ "$unixtests/compile.test" "$XQMAKESPEC" "$QMAKE_CONFIG" $OPT_VERBOSE "$relpath" "$outpath" "$path" "$name" $I_FLAGS $D_FLAGS $L_FLAGS "$@"
}
#-------------------------------------------------------------------------------
@@ -3835,7 +4154,7 @@ compileTest()
# Use config.tests/arch/arch.pro to have the compiler tell us what the target architecture is
OUTFILE=$outpath/arch.result
-"$unixtests/arch.test" "$XQMAKESPEC" $OPT_VERBOSE "$relpath" "$outpath" "$OUTFILE" "CFG" $MAC_SDK_FLAG
+"$unixtests/arch.test" "$XQMAKESPEC" $OPT_VERBOSE "$relpath" "$outpath" "$OUTFILE" "target"
if [ $? -eq 0 ]; then
eval `cat "$OUTFILE"`
else
@@ -3848,7 +4167,7 @@ rm -f "$OUTFILE" 2>/dev/null
if [ "$QMAKESPEC" != "$XQMAKESPEC" ]; then
# Do the same test again, using the host compiler
- SYSROOT_FLAG= "$unixtests/arch.test" "$QMAKESPEC" $OPT_VERBOSE "$relpath" "$outpath" "$OUTFILE" "CFG_HOST" $MAC_SDK_FLAG
+ SYSROOT_FLAG= "$unixtests/arch.test" "$QMAKESPEC" $OPT_VERBOSE "$relpath" "$outpath" "$OUTFILE" "host"
if [ $? -eq 0 ]; then
eval `cat "$OUTFILE"`
else
@@ -3876,7 +4195,12 @@ fi
# Detect C++11 support
if [ "$CFG_CXX11" != "no" ]; then
- if compileTest common/c++11 "C++11"; then
+ # Configure detects compiler features based on cross compiler, so we need
+ # to explicitly disable C++11 on Mac to avoid breaking builds where the
+ # host compiler does not support it.
+ if [ "$PLATFORM_MAC" = "yes" ] && [ "$XPLATFORM_ANDROID" = "yes" ]; then
+ CFG_CXX11="no"
+ elif compileTest common/c++11 "C++11"; then
CFG_CXX11="yes"
elif [ "$CFG_CXX11" != "auto" ] && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then
echo "C++11 support cannot be enabled due to functionality tests!"
@@ -3948,7 +4272,7 @@ if [ "${CFG_AVX}" = "auto" ]; then
*g++*|*-clang*)
# Some clang versions produce internal compiler errors compiling Qt AVX code
case `$TEST_COMPILER --version` in
- Apple\ clang\ version\ 2*|Apple\ clang\ version\ 3.0*)
+ Apple\ clang\ version\ [23]*)
CFG_AVX=no
if [ "$OPT_VERBOSE" = "yes" ]; then
echo 'AVX support disabled for blacklisted clang compiler'
@@ -3992,7 +4316,8 @@ fi
# detect neon support
if [ "$CFG_ARCH" = "arm" ] && [ "${CFG_NEON}" = "auto" ]; then
- if compileTest unix/neon "neon"; then
+ # The iOS toolchain has trouble building the pixman NEON draw-helpers
+ if [ "$XPLATFORM_IOS" != "yes" ] && compileTest unix/neon "neon"; then
CFG_NEON=yes
else
CFG_NEON=no
@@ -4024,6 +4349,7 @@ elif [ "$CFG_ARCH" != "mips" ]; then
fi
[ "$XPLATFORM_MINGW" = "yes" ] && QMakeVar add styles "windowsxp windowsvista"
+[ "$XPLATFORM_ANDROID" = "yes" ] && QMakeVar add styles "android"
# detect zlib
if [ "$CFG_ZLIB" = "no" ]; then
@@ -4338,7 +4664,7 @@ for _SQLDR in $CFG_SQL_AVAILABLE; do
if [ "$CFG_SQL_sqlite" != "no" ]; then
SQLITE_AUTODETECT_FAILED="no"
if [ "$CFG_SQLITE" = "system" ]; then
- if [ -n "$PKG_CONFIG" ]; then
+ if [ -n "$PKG_CONFIG" ] && $PKG_CONFIG --exists sqlite3 2>/dev/null; then
QT_CFLAGS_SQLITE=`$PKG_CONFIG --cflags sqlite3 2>/dev/null`
QT_LFLAGS_SQLITE=`$PKG_CONFIG --libs sqlite3 2>/dev/null`
else
@@ -4488,14 +4814,17 @@ fi
# auto-detect GTK style support
if [ "$CFG_GLIB" = "yes" -a "$CFG_QGTKSTYLE" != "no" ]; then
if [ -n "$PKG_CONFIG" ]; then
- QT_CFLAGS_QGTKSTYLE=`$PKG_CONFIG --cflags gtk+-2.0 ">=" 2.18 atk 2>/dev/null`
- QT_LIBS_QGTKSTYLE=`$PKG_CONFIG --libs gobject-2.0 2>/dev/null`
+ QT_CFLAGS_QGTK2=`$PKG_CONFIG --cflags gtk+-2.0 ">=" 2.18 atk 2>/dev/null`
+ QT_LIBS_QGTK2=`$PKG_CONFIG --libs gtk+-2.0 2>/dev/null`
+ QT_LIBS_QGOBJECT=`$PKG_CONFIG --libs gobject-2.0 2>/dev/null`
fi
- if [ -n "$QT_CFLAGS_QGTKSTYLE" ] ; then
+ if [ -n "$QT_CFLAGS_QGTK2" ] ; then
CFG_QGTKSTYLE=yes
- QT_CONFIG="$QT_CONFIG gtkstyle"
- QMakeVar set QT_CFLAGS_QGTKSTYLE "$QT_CFLAGS_QGTKSTYLE"
- QMakeVar set QT_LIBS_QGTKSTYLE "$QT_LIBS_QGTKSTYLE"
+ QT_CONFIG="$QT_CONFIG gtk2 gtkstyle"
+ QMakeVar set QT_CFLAGS_QGTKSTYLE "$QT_CFLAGS_QGTK2"
+ QMakeVar set QT_LIBS_QGTKSTYLE "$QT_LIBS_QGOBJECT"
+ QMakeVar set QT_CFLAGS_QGTK2 "$QT_CFLAGS_QGTK2"
+ QMakeVar set QT_LIBS_QGTK2 "$QT_LIBS_QGTK2"
else
if [ "$CFG_QGTKSTYLE" = "yes" ] && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then
echo "Gtk theme support cannot be enabled due to functionality tests!"
@@ -4775,6 +5104,18 @@ if [ "$CFG_EVDEV" = "no" ]; then
QMakeVar add DEFINES QT_NO_EVDEV
fi
+if [ "$CFG_TSLIB" != "no" ]; then
+ if compileTest unix/tslib "tslib"; then
+ CFG_TSLIB=yes
+ QT_CONFIG="$QT_CONFIG tslib"
+ elif [ "$CFG_TSLIB" = "yes" ]; then
+ echo "The tslib functionality test failed!"
+ exit 1
+ else
+ CFG_TSLIB=no
+ fi
+fi
+
# Check we actually have X11 :-)
if compileTest x11/xlib "XLib"; then
QT_CONFIG="$QT_CONFIG xlib"
@@ -4917,13 +5258,20 @@ if [ "$CFG_KMS" != "no" ]; then
fi
# Detect libxkbcommon
-if [ -n "$PKG_CONFIG" ] && $PKG_CONFIG --exists xkbcommon 2>/dev/null; then
+if [ -n "$PKG_CONFIG" ] && $PKG_CONFIG --exists "xkbcommon >= 0.2.0" 2>/dev/null; then
QMAKE_CFLAGS_XKBCOMMON="`$PKG_CONFIG --cflags xkbcommon 2>/dev/null`"
QMAKE_LIBS_XKBCOMMON="`$PKG_CONFIG --libs xkbcommon 2>/dev/null`"
- QMAKE_CFLAGS_XCB="$QMAKE_CFLAGS_XCB $QMAKE_CFLAGS_XKBCOMMON"
- QMAKE_LIBS_XCB="$QMAKE_LIBS_XCB $QMAKE_LIBS_XKBCOMMON"
-else
- QMAKE_DEFINES_XCB=QT_NO_XCB_XKB
+ QT_CONFIG="$QT_CONFIG xkbcommon"
+elif [ "$CFG_XCB" != "no" ]; then
+ echo "WARNING: XCB support enabled but libxkbcommon 0.2.0 (or higher) not found."
+ echo "Not satisfying this requirement will disable the compose key functionality,"
+ echo "which includes text input with dead keys."
+ QMakeVar add DEFINES QT_NO_XKBCOMMON
+fi
+
+if [ -n "$QMAKE_CFLAGS_XKBCOMMON" ] || [ -n "$QMAKE_LIBS_XKBCOMMON" ]; then
+ QMakeVar set QMAKE_CFLAGS_XKBCOMMON "$QMAKE_CFLAGS_XKBCOMMON"
+ QMakeVar set QMAKE_LIBS_XKBCOMMON "$QMAKE_LIBS_XKBCOMMON"
fi
# EGL Support
@@ -4955,7 +5303,7 @@ elif [ "$CFG_OPENGL" = "desktop" ]; then
fi
if [ "$CFG_EGLFS" != "no" ]; then
- if [ "$CFG_OPENGL" = "es2" ] && [ "$CFG_EVDEV" = "yes" ]; then
+ if [ "$CFG_OPENGL" = "es2" ] && [ "$XPLATFORM_QNX" = "no" ]; then
CFG_EGLFS="$CFG_EGL"
else
CFG_EGLFS="no"
@@ -5008,8 +5356,8 @@ fi
if [ -n "$QMAKE_CFLAGS_XCB" ] || [ -n "$QMAKE_LIBS_XCB" ]; then
QMakeVar set QMAKE_CFLAGS_XCB "$QMAKE_CFLAGS_XCB"
QMakeVar set QMAKE_LIBS_XCB "$QMAKE_LIBS_XCB"
- QMakeVar set QMAKE_DEFINES_XCB "$QMAKE_DEFINES_XCB"
fi
+
if [ "$CFG_DIRECTFB" = "yes" ]; then
QT_CONFIG="$QT_CONFIG directfb"
QMakeVar set QMAKE_CFLAGS_DIRECTFB "$QMAKE_CFLAGS_DIRECTFB"
@@ -5030,7 +5378,7 @@ if [ "$BUILD_ON_MAC" = "yes" ]; then
fi
fi
-if [ "$BUILD_ON_MAC" = "no" ] && [ "$XPLATFORM_MINGW" = "no" ] && [ "$XPLATFORM_QNX" = "no" ]; then
+if [ "$BUILD_ON_MAC" = "no" ] && [ "$XPLATFORM_MINGW" = "no" ] && [ "$XPLATFORM_QNX" = "no" ] && [ "$XPLATFORM_ANDROID" = "no" ]; then
if [ "$CFG_XCB" = "no" ] && [ "$CFG_EGLFS" = "no" ] && [ "$CFG_DIRECTFB" = "no" ] && [ "$CFG_LINUXFB" = "no" ] && [ "$CFG_KMS" = "no" ]; then
if [ "$QPA_PLATFORM_GUARD" = "yes" ] &&
( [ "$ORIG_CFG_XCB" = "auto" ] || [ "$ORIG_CFG_EGLFS" = "auto" ] || [ "$ORIG_CFG_DIRECTFB" = "auto" ] || [ "$ORIG_CFG_LINUXFB" = "auto" ] || [ "$ORIG_CFG_KMS" = "auto" ] ); then
@@ -5126,6 +5474,23 @@ if [ "$CFG_INOTIFY" != "no" ]; then
fi
fi
+# find if the platform provides eventfd
+if [ "$CFG_EVENTFD" != "no" ]; then
+ if compileTest unix/eventfd "eventfd"; then
+ CFG_EVENTFD=yes
+ else
+ if [ "$CFG_EVENTFD" = "yes" ] && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then
+ echo "eventfd support cannot be enabled due to functionality tests!"
+ echo " Turn on verbose messaging (-v) to $0 to see the final report."
+ echo " If you believe this message is in error you may use the continue"
+ echo " switch (-continue) to $0 to continue."
+ exit 101
+ else
+ CFG_EVENTFD=no
+ fi
+ fi
+fi
+
# find if the platform provides if_nametoindex (ipv6 interface name support)
if [ "$CFG_IPV6IFNAME" != "no" ]; then
if compileTest unix/ipv6ifname "IPv6 interface name"; then
@@ -5167,7 +5532,7 @@ if [ "$CFG_OPENSSL" != "no" ]; then
CFG_OPENSSL=yes
fi
else
- if ( [ "$CFG_OPENSSL" = "yes" ] || [ "$CFG_OPENSSL" = "linked" ] ) && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then
+ if ( [ "$CFG_OPENSSL" = "yes" ] || [ "$CFG_OPENSSL" = "linked" ] ) && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ] && [ "$XPLATFORM_ANDROID" = "no" ]; then
echo "OpenSSL support cannot be enabled due to functionality tests!"
echo " Turn on verbose messaging (-v) to $0 to see the final report."
echo " If you believe this message is in error you may use the continue"
@@ -5415,6 +5780,9 @@ fi
if [ "$CFG_INOTIFY" = "yes" ]; then
QT_CONFIG="$QT_CONFIG inotify"
fi
+if [ "$CFG_EVENTFD" = "yes" ]; then
+ QT_CONFIG="$QT_CONFIG eventfd"
+fi
if [ "$CFG_LIBJPEG" = "no" ]; then
CFG_JPEG="no"
elif [ "$CFG_LIBJPEG" = "system" ]; then
@@ -5736,6 +6104,19 @@ if [ "$CFG_QML_DEBUG" = "no" ]; then
fi
case "$QMAKE_CONF_COMPILER" in
+*clang*)
+ # Clang
+ COMPILER_VERSION=`${QMAKE_CONF_COMPILER} -v 2>&1 | sed -n -E '
+/^Apple (clang|LLVM) version /{s///; s/^([0-9]*)\.([0-9]*).*$/QT_APPLE_CLANG_MAJOR_VERSION=\1; QT_APPLE_CLANG_MINOR_VERSION=\2/;p;q;}
+/^clang version /{s///; s/^([0-9]*)\.([0-9]*).*$/QT_CLANG_MAJOR_VERSION=\1; QT_CLANG_MINOR_VERSION=\2/;p;q;}'`
+ eval "$COMPILER_VERSION"
+ ;;
+*icpc)
+ # Intel CC
+ COMPILER_VERSION=`${QMAKE_CONF_COMPILER} -v 2>&1 | sed -n '
+s/icpc version \([0-9]*\)\.\([0-9]*\)\.\([0-9]*\) .*$/QT_ICC_MAJOR_VERSION=\1; QT_ICC_MINOR_VERSION=\2; QT_ICC_PATCH_VERSION=\3/p'`
+ eval "$COMPILER_VERSION"
+ ;;
*g++*)
# GNU C++
COMPILER_VERSION=`${QMAKE_CONF_COMPILER} -dumpversion 2>/dev/null`
@@ -5891,6 +6272,7 @@ QMakeVar set sql-plugins "$SQL_PLUGINS"
[ "$CFG_IPV6IFNAME" = "no" ] && QCONFIG_FLAGS="$QCONFIG_FLAGS QT_NO_IPV6IFNAME"
[ "$CFG_GETIFADDRS" = "no" ] && QCONFIG_FLAGS="$QCONFIG_FLAGS QT_NO_GETIFADDRS"
[ "$CFG_INOTIFY" = "no" ] && QCONFIG_FLAGS="$QCONFIG_FLAGS QT_NO_INOTIFY"
+[ "$CFG_EVENTFD" = "no" ] && QCONFIG_FLAGS="$QCONFIG_FLAGS QT_NO_EVENTFD"
[ "$CFG_NIS" = "no" ] && QCONFIG_FLAGS="$QCONFIG_FLAGS QT_NO_NIS"
[ "$CFG_OPENSSL" = "no" ] && QCONFIG_FLAGS="$QCONFIG_FLAGS QT_NO_OPENSSL QT_NO_SSL"
[ "$CFG_OPENSSL" = "linked" ]&& QCONFIG_FLAGS="$QCONFIG_FLAGS QT_LINKED_OPENSSL"
@@ -6020,6 +6402,11 @@ else
fi
if [ "$CFG_DEV" = "yes" ]; then
QT_CONFIG="$QT_CONFIG private_tests"
+ if [ "$CFG_WERROR" != "no" ]; then
+ QMAKE_CONFIG="$QMAKE_CONFIG warnings_are_errors"
+ fi
+elif [ "$CFG_WERROR" = "yes" ]; then
+ QMAKE_CONFIG="$QMAKE_CONFIG warnings_are_errors"
fi
cat >>"$QTCONFIG.tmp" <<EOF
@@ -6075,6 +6462,19 @@ if [ -n "$QT_GCC_MAJOR_VERSION" ]; then
echo "QT_GCC_MINOR_VERSION = $QT_GCC_MINOR_VERSION" >> "$QTCONFIG.tmp"
echo "QT_GCC_PATCH_VERSION = $QT_GCC_PATCH_VERSION" >> "$QTCONFIG.tmp"
fi
+if [ -n "$QT_ICC_MAJOR_VERSION" ]; then
+ echo "QT_ICC_MAJOR_VERSION = $QT_ICC_MAJOR_VERSION" >> "$QTCONFIG.tmp"
+ echo "QT_ICC_MINOR_VERSION = $QT_ICC_MINOR_VERSION" >> "$QTCONFIG.tmp"
+ echo "QT_ICC_PATCH_VERSION = $QT_ICC_PATCH_VERSION" >> "$QTCONFIG.tmp"
+fi
+if [ -n "$QT_CLANG_MAJOR_VERSION" ]; then
+ echo "QT_CLANG_MAJOR_VERSION = $QT_CLANG_MAJOR_VERSION" >> "$QTCONFIG.tmp"
+ echo "QT_CLANG_MINOR_VERSION = $QT_CLANG_MINOR_VERSION" >> "$QTCONFIG.tmp"
+fi
+if [ -n "$QT_APPLE_CLANG_MAJOR_VERSION" ]; then
+ echo "QT_APPLE_CLANG_MAJOR_VERSION = $QT_APPLE_CLANG_MAJOR_VERSION" >> "$QTCONFIG.tmp"
+ echo "QT_APPLE_CLANG_MINOR_VERSION = $QT_APPLE_CLANG_MINOR_VERSION" >> "$QTCONFIG.tmp"
+fi
if [ -n "$QMAKE_INCDIR_OPENGL_ES2" ]; then
echo "#Qt opengl include path" >> "$QTCONFIG.tmp"
@@ -6297,7 +6697,7 @@ echo "Xi support ............. $CFG_XINPUT"
echo "Xi2 support ............ $CFG_XINPUT2"
echo "MIT-SHM support ........ $CFG_MITSHM"
echo "FontConfig support ..... $CFG_FONTCONFIG"
-echo "XKB Support ............ $CFG_XKB"
+echo "XKB support ............ $CFG_XKB"
echo "GTK theme support ...... $CFG_QGTKSTYLE"
if [ "$XPLATFORM_MINGW" = "yes" ] ; then
diff --git a/dist/changes-5.1.0 b/dist/changes-5.1.0
new file mode 100644
index 0000000000..d89914ce1a
--- /dev/null
+++ b/dist/changes-5.1.0
@@ -0,0 +1,140 @@
+Qt 5.1 introduces many new features and improvements as well as bugfixes
+over the 5.0.x series. For more details, refer to the online documentation
+included in this distribution. The documentation is also available online:
+
+ http://qt-project.org/doc/qt-5.1
+
+The Qt version 5.1 series is binary compatible with the 5.0.x series.
+Applications compiled for 5.0 will continue to run with 5.1.
+
+Some of the changes listed in this file include issue tracking numbers
+corresponding to tasks in the Qt Bug Tracker:
+
+ http://bugreports.qt-project.org/
+
+Each of these identifiers can be entered in the bug tracker to obtain more
+information about a particular change.
+
+****************************************************************************
+* General *
+****************************************************************************
+
+General Improvements
+--------------------
+
+ - Q_PROPERTY gained a MEMBER attribute that let you associate a property to a
+ class member without requiring to explicitly writing a getter or a setter
+
+
+Third party components
+----------------------
+
+ -
+
+
+****************************************************************************
+* Important Behavior Changes *
+****************************************************************************
+
+- QtWidgets
+
+ * [QTBUG-8836] QAbstractItemView now allows manual deselect in
+ SingleSelection mode (with control modifier)
+
+****************************************************************************
+* Library *
+****************************************************************************
+
+QtCore
+------
+
+ - QRect:
+ * Added marginsAdded(), marginsRemoved() and operators +, -, +=, -=
+ taking a QMargins object allowing for conveniently adding or removing
+ margins.
+ - QMargins:
+ * Added operators for adding and subtracting QMargins objects,
+ multiplication and division for int/qreal and unary minus.
+
+ - QMessageAuthenticationCode
+ * New class for hash-based message authentication code added to QtCore.
+
+ - QRegularExpression
+ * It's now possible to know the names of the named capturing groups
+ inside the pattern string, as well as the numerical index of each
+ named capturing group.
+
+ - QPointer
+ * It is now possible to create a QPointer with a const templated type.
+
+ -
+
+QtGui
+-----
+
+ - QOffscreenSurface
+ * New class for rendering graphics using OpenGL in an arbitrary thread
+ without needing to use a hidden QWindow.
+
+
+QtNetwork
+---------
+
+ -
+
+QtWidgets
+---------
+
+- QGraphicsView:
+ * Added function rubberBandRect() and signal rubberBandChanged.
+
+****************************************************************************
+* Database Drivers *
+****************************************************************************
+
+
+****************************************************************************
+* Platform Specific Changes *
+****************************************************************************
+
+Qt for Linux/X11
+----------------
+ -
+
+Qt for Windows
+--------------
+ -
+
+Qt for Mac OS X
+---------------
+ -
+
+Qt for Embedded Linux
+---------------------
+
+
+Qt for Windows CE
+-----------------
+
+
+****************************************************************************
+* Compiler Specific Changes *
+****************************************************************************
+
+
+****************************************************************************
+* Tools *
+****************************************************************************
+
+- qmake
+
+ * Windows: The feature of finding the highest version number of LIBS
+ entries is turned off by default.
+ It can be turned on with "CONFIG += link_highest_lib_version".
+
+
+****************************************************************************
+* Plugins *
+****************************************************************************
+
+
diff --git a/doc/global/qt-cpp-ignore.qdocconf b/doc/global/qt-cpp-ignore.qdocconf
index 6dd1536c1f..1f34f366cb 100644
--- a/doc/global/qt-cpp-ignore.qdocconf
+++ b/doc/global/qt-cpp-ignore.qdocconf
@@ -41,6 +41,7 @@ Cpp.ignoretokens += \
Q_OPENVG_EXPORT \
Q_OUTOFLINE_TEMPLATE \
Q_PRINTSUPPORT_EXPORT \
+ Q_QML_EXPORT \
Q_SCRIPT_EXPORT \
Q_SCRIPTTOOLS_EXPORT \
Q_SQL_EXPORT \
@@ -75,12 +76,10 @@ Cpp.ignoretokens += \
QM_EXPORT_XML \
QT_ASCII_CAST_WARN \
QT_ASCII_CAST_WARN_CONSTRUCTOR \
- QT_BEGIN_HEADER \
QT_BEGIN_INCLUDE_NAMESPACE \
QT_BEGIN_NAMESPACE \
QT_BOOTSTRAPPED \
QT_DESIGNER_STATIC \
- QT_END_HEADER \
QT_END_INCLUDE_NAMESPACE \
QT_END_NAMESPACE \
QT_FASTCALL \
@@ -113,4 +112,5 @@ Cpp.ignoredirectives = \
Q_INTERFACES \
Q_PRIVATE_PROPERTY \
QT_FORWARD_DECLARE_CLASS \
- Q_DECLARE_HANDLE
+ Q_DECLARE_HANDLE \
+ Q_REVISION
diff --git a/doc/global/template/style/offline.css b/doc/global/template/style/offline.css
index 40257730ff..0e4dd5e9a4 100644
--- a/doc/global/template/style/offline.css
+++ b/doc/global/template/style/offline.css
@@ -66,6 +66,11 @@ color: #44a51c;
text-align:left;
}
+/*
+-----------
+offline viewing: HTML links display an icon
+-----------
+*/
a[href*="http://"], a[href*="ftp://"],a[href*="https://"]
{
text-decoration: none;
@@ -127,7 +132,6 @@ Top navigation
.qtref{
display: block;
position: relative;
-top: -76px;
height:15px;
z-index: 1;
font-size:11px;
@@ -136,10 +140,11 @@ float:right;
}
.naviNextPrevious{
+clear: both;
display: block;
position: relative;
text-align: right;
-top: -53px;
+top: -47px;
float:right;
height:20px;
z-index:1;
@@ -167,6 +172,14 @@ padding-right:20px;
height:20px;
margin-left:30px;
}
+/*
+-----------
+footer and license
+-----------
+*/
+.footer{
+text-align:center
+}
/* table of content
no display
@@ -390,10 +403,15 @@ text-align: left;
.cpp{
display: block;
-margin: 10;
-overflow: hidden;
-overflow-x: hidden;
-overflow-y: hidden;
+margin: 10px;
+overflow: auto;
+padding: 20px 20px 20px 20px;
+}
+
+.js{
+display: block;
+margin: 10px;
+overflow: auto;
padding: 20px 20px 20px 20px;
}
@@ -424,9 +442,7 @@ padding: 3px 15px 3px 0;
.qml{
display: block;
margin: 10;
-overflow: hidden;
-overflow-x: hidden;
-overflow-y: hidden;
+overflow: auto;
padding: 20px 20px 20px 20px;
}
@@ -459,6 +475,7 @@ Content table
@media print{
.toc {
float: right;
+clear: right;
padding-bottom: 10px;
padding-top: 50px;
width: 100%;
@@ -470,8 +487,8 @@ background-repeat:no-repeat;
@media screen{
.toc{
-clear:both;
float:right;
+clear: right;
vertical-align:top;
-moz-border-radius: 7px 7px 7px 7px;
-webkit-border-radius: 7px 7px 7px 7px;
@@ -485,11 +502,7 @@ padding-bottom:10px;
height: auto;
width: 200px;
text-align:left;
-z-index:2;
margin-left:20px;
-margin-right:20px;
-margin-top:0px;
-padding-top:0px;
}
}
diff --git a/doc/global/template/style/online.css b/doc/global/template/style/online.css
index 9dff745358..7809783fa7 100644
--- a/doc/global/template/style/online.css
+++ b/doc/global/template/style/online.css
@@ -127,7 +127,6 @@ margin-left: 20px;
text-align:left
}
.nav-main-content{
-font-weight:bold;
margin-right: 20px;
display:inline-block;
}
@@ -156,9 +155,7 @@ left: 30px;
}
.qtref{
display: block;
-position: relative;
top: -76px;
-height:15px;
z-index: 1;
font-size:11px;
padding-right:10px;
@@ -171,7 +168,7 @@ text-align: right;
float:right;
z-index:1;
padding-right:10px;
-vertical-align:top;
+padding-top:4px;
}
@@ -196,16 +193,12 @@ margin-left:30px;
.breadcrumb{
display: block;
position: relative;
-top:-20px;
-/*border-top:2px solid #ffffff;*/
-border-bottom: 1px solid #cecece;
-background-color:#F2F2F2;
z-index:1;
height:20px;
padding:0px;
margin:0px;
padding-left:10px;
-padding-top:2px;
+padding-top:12px;
margin-left:-5px;
margin-right:-5px;
}
@@ -216,7 +209,6 @@ margin-right:-5px;
}
.breadcrumb ul li{
-background-color:#F2F2F2;
list-style-type:none;
padding:0;
margin:0;
@@ -236,7 +228,6 @@ padding-left:20px;
.breadcrumb li a{
-color:#2C418D;
display:block;
text-decoration:none;
background:url(../images/arrow.png);
@@ -506,10 +497,15 @@ text-align: left;
.cpp{
display: block;
-margin: 10;
-overflow: hidden;
-overflow-x: hidden;
-overflow-y: hidden;
+margin: 10px;
+overflow: auto;
+padding: 20px 20px 20px 20px;
+}
+
+.js{
+display: block;
+margin: 10px;
+overflow: auto;
padding: 20px 20px 20px 20px;
}
@@ -539,10 +535,8 @@ padding: 3px 15px 3px 0;
.qml{
display: block;
-margin: 10;
-overflow: hidden;
-overflow-x: hidden;
-overflow-y: hidden;
+margin: 10px;
+overflow: auto;
padding: 20px 20px 20px 20px;
}
@@ -576,6 +570,7 @@ Content table
@media print{
.toc {
float: right;
+clear: right;
padding-bottom: 10px;
padding-top: 50px;
width: 100%;
@@ -587,7 +582,10 @@ background-repeat:no-repeat;
@media screen{
.toc{
-clear:both;
+clear: both;
+clear: right;
+position: relative;
+top: 83px;
float:right;
vertical-align:top;
-moz-border-radius: 7px 7px 7px 7px;
@@ -602,11 +600,7 @@ padding-bottom:10px;
height: auto;
width: 200px;
text-align:left;
-z-index:2;
margin-left:20px;
-margin-right:20px;
-margin-top:0px;
-padding-top:0px;
}
}
diff --git a/doc/src/examples/customtypesending.qdoc b/doc/src/examples/customtypesending.qdoc
index 6cb28b1bd4..695ac2e057 100644
--- a/doc/src/examples/customtypesending.qdoc
+++ b/doc/src/examples/customtypesending.qdoc
@@ -61,7 +61,7 @@
message to be sent.
The \c Message class is defined in the following way:
-
+
\snippet examples/tools/customtypesending/message.h custom type definition
The type is declared to the meta-type system with the Q_DECLARE_METATYPE()
diff --git a/examples/dbus/complexpingpong/complexping.cpp b/examples/dbus/complexpingpong/complexping.cpp
index b094bfd247..61c918534f 100644
--- a/examples/dbus/complexpingpong/complexping.cpp
+++ b/examples/dbus/complexpingpong/complexping.cpp
@@ -82,7 +82,7 @@ void Ping::start(const QString &name, const QString &oldValue, const QString &ne
if (!reply.isNull())
printf("value = %s\n", qPrintable(reply.toString()));
} else if (line.startsWith("value=")) {
- iface->setProperty("value", line.mid(6));
+ iface->setProperty("value", line.mid(6));
} else {
QDBusReply<QDBusVariant> reply = iface->call("query", line);
if (reply.isValid())
@@ -92,7 +92,7 @@ void Ping::start(const QString &name, const QString &oldValue, const QString &ne
if (iface->lastError().isValid())
fprintf(stderr, "Call failed: %s\n", qPrintable(iface->lastError().message()));
}
-}
+}
int main(int argc, char **argv)
{
diff --git a/examples/dbus/complexpingpong/complexpong.cpp b/examples/dbus/complexpingpong/complexpong.cpp
index 3e4ba84001..fe122345f0 100644
--- a/examples/dbus/complexpingpong/complexpong.cpp
+++ b/examples/dbus/complexpingpong/complexpong.cpp
@@ -94,10 +94,10 @@ int main(int argc, char **argv)
if (!QDBusConnection::sessionBus().registerService(SERVICE_NAME)) {
fprintf(stderr, "%s\n",
- qPrintable(QDBusConnection::sessionBus().lastError().message()));
+ qPrintable(QDBusConnection::sessionBus().lastError().message()));
exit(1);
}
-
+
app.exec();
return 0;
}
diff --git a/examples/dbus/pingpong/pong.cpp b/examples/dbus/pingpong/pong.cpp
index 203bf53e0e..5f242569f1 100644
--- a/examples/dbus/pingpong/pong.cpp
+++ b/examples/dbus/pingpong/pong.cpp
@@ -67,13 +67,13 @@ int main(int argc, char **argv)
if (!QDBusConnection::sessionBus().registerService(SERVICE_NAME)) {
fprintf(stderr, "%s\n",
- qPrintable(QDBusConnection::sessionBus().lastError().message()));
+ qPrintable(QDBusConnection::sessionBus().lastError().message()));
exit(1);
}
Pong pong;
QDBusConnection::sessionBus().registerObject("/", &pong, QDBusConnection::ExportAllSlots);
-
+
app.exec();
return 0;
}
diff --git a/examples/gui/openglwindow/main.cpp b/examples/gui/openglwindow/main.cpp
index cd6dca3352..237680a889 100644
--- a/examples/gui/openglwindow/main.cpp
+++ b/examples/gui/openglwindow/main.cpp
@@ -80,7 +80,7 @@ int main(int argc, char **argv)
QGuiApplication app(argc, argv);
QSurfaceFormat format;
- format.setSamples(4);
+ format.setSamples(16);
TriangleWindow window;
window.setFormat(format);
@@ -136,7 +136,8 @@ void TriangleWindow::initialize()
//! [5]
void TriangleWindow::render()
{
- glViewport(0, 0, width(), height());
+ const qreal retinaScale = devicePixelRatio();
+ glViewport(0, 0, width() * retinaScale, height() * retinaScale);
glClear(GL_COLOR_BUFFER_BIT);
diff --git a/examples/gui/openglwindow/openglwindow.cpp b/examples/gui/openglwindow/openglwindow.cpp
index 5b247ebf19..afebf521f3 100644
--- a/examples/gui/openglwindow/openglwindow.cpp
+++ b/examples/gui/openglwindow/openglwindow.cpp
@@ -99,6 +99,7 @@ bool OpenGLWindow::event(QEvent *event)
{
switch (event->type()) {
case QEvent::UpdateRequest:
+ m_update_pending = false;
renderNow();
return true;
default:
@@ -113,14 +114,6 @@ void OpenGLWindow::exposeEvent(QExposeEvent *event)
if (isExposed())
renderNow();
}
-
-void OpenGLWindow::resizeEvent(QResizeEvent *event)
-{
- Q_UNUSED(event);
-
- if (isExposed())
- renderNow();
-}
//! [3]
//! [4]
@@ -129,8 +122,6 @@ void OpenGLWindow::renderNow()
if (!isExposed())
return;
- m_update_pending = false;
-
bool needsInitialize = false;
if (!m_context) {
diff --git a/examples/gui/openglwindow/openglwindow.h b/examples/gui/openglwindow/openglwindow.h
index 21ec033261..f6b53e3b33 100644
--- a/examples/gui/openglwindow/openglwindow.h
+++ b/examples/gui/openglwindow/openglwindow.h
@@ -70,7 +70,6 @@ protected:
bool event(QEvent *event);
void exposeEvent(QExposeEvent *event);
- void resizeEvent(QResizeEvent *event);
private:
bool m_update_pending;
diff --git a/examples/ipc/ipc.pro b/examples/ipc/ipc.pro
index f302b836af..4b4b3870a4 100644
--- a/examples/ipc/ipc.pro
+++ b/examples/ipc/ipc.pro
@@ -3,4 +3,4 @@ requires(qtHaveModule(widgets))
TEMPLATE = subdirs
# no QSharedMemory
!vxworks:!qnx:SUBDIRS = sharedmemory
-!wince*: SUBDIRS += localfortuneserver localfortuneclient
+!wince*:qtHaveModule(network): SUBDIRS += localfortuneserver localfortuneclient
diff --git a/examples/ipc/sharedmemory/dialog.cpp b/examples/ipc/sharedmemory/dialog.cpp
index 3b41c22d3f..2be62b1b47 100644
--- a/examples/ipc/sharedmemory/dialog.cpp
+++ b/examples/ipc/sharedmemory/dialog.cpp
@@ -182,7 +182,7 @@ void Dialog::loadFromMemory()
*/
void Dialog::detach()
{
- if (!sharedMemory.detach())
+ if (!sharedMemory.detach())
ui.label->setText(tr("Unable to detach from shared memory."));
}
diff --git a/examples/network/doc/src/blockingfortuneclient.qdoc b/examples/network/doc/src/blockingfortuneclient.qdoc
index bff2e29ea5..2d77d3fcba 100644
--- a/examples/network/doc/src/blockingfortuneclient.qdoc
+++ b/examples/network/doc/src/blockingfortuneclient.qdoc
@@ -43,7 +43,7 @@
QTcpSocket::connectToHost() returns immediately, and when the connection
has been established, QTcpSocket emits
\l{QTcpSocket::connected()}{connected()}.
-
+
\li \e{The synchronous (blocking) approach.} In non-GUI and multithreaded
applications, you can call the \c waitFor...() functions (e.g.,
QTcpSocket::waitForConnected()) to suspend the calling thread until the
@@ -208,7 +208,7 @@
\snippet blockingfortuneclient/blockingclient.cpp 3
\codeline
\snippet blockingfortuneclient/blockingclient.cpp 4
-
+
Here, we simply display the fortune we received as the argument.
\sa {Fortune Client Example}, {Fortune Server Example}
diff --git a/examples/network/doc/src/threadedfortuneserver.qdoc b/examples/network/doc/src/threadedfortuneserver.qdoc
index fe627d0141..1b64e30226 100644
--- a/examples/network/doc/src/threadedfortuneserver.qdoc
+++ b/examples/network/doc/src/threadedfortuneserver.qdoc
@@ -48,8 +48,8 @@
FortuneServer inherits QTcpServer and reimplements
QTcpServer::incomingConnection(). We also use it for storing the list of
- random fortunes.
-
+ random fortunes.
+
\snippet threadedfortuneserver/fortuneserver.cpp 0
We use FortuneServer's constructor to simply generate the list of
@@ -71,7 +71,7 @@
QThread::run(), and it has a signal for reporting errors.
\snippet threadedfortuneserver/fortunethread.cpp 0
-
+
FortuneThread's constructor simply stores the socket descriptor and
fortune text, so that they are available for run() later on.
@@ -101,7 +101,7 @@
But unlike the previous example, we finish off by calling
QTcpSocket::waitForDisconnected(), which blocks the calling thread until
the socket has disconnected. Because we are running in a separate thread,
- the GUI will remain responsive.
+ the GUI will remain responsive.
\sa {Fortune Server Example}, {Fortune Client Example}, {Blocking Fortune
Client Example}
diff --git a/examples/network/http/httpwindow.cpp b/examples/network/http/httpwindow.cpp
index 2f795ebe7f..2b689c7770 100644
--- a/examples/network/http/httpwindow.cpp
+++ b/examples/network/http/httpwindow.cpp
@@ -180,7 +180,7 @@ void HttpWindow::httpFinished()
tr("Download failed: %1.")
.arg(reply->errorString()));
downloadButton->setEnabled(true);
- } else if (!redirectionTarget.isNull()) {
+ } else if (!redirectionTarget.isNull()) {
QUrl newUrl = url.resolved(redirectionTarget.toUrl());
if (QMessageBox::question(this, tr("HTTP"),
tr("Redirect to %1 ?").arg(newUrl.toString()),
@@ -256,7 +256,7 @@ void HttpWindow::sslErrors(QNetworkReply*,const QList<QSslError> &errors)
errorString += ", ";
errorString += error.errorString();
}
-
+
if (QMessageBox::warning(this, tr("HTTP"),
tr("One or more SSL errors has occurred: %1").arg(errorString),
QMessageBox::Ignore | QMessageBox::Abort) == QMessageBox::Ignore) {
diff --git a/examples/network/network.pro b/examples/network/network.pro
index 342297528b..be4ccdbddf 100644
--- a/examples/network/network.pro
+++ b/examples/network/network.pro
@@ -1,3 +1,5 @@
+requires(qtHaveModule(network))
+
TEMPLATE = subdirs
SUBDIRS = \
dnslookup \
diff --git a/examples/network/securesocketclient/sslclient.h b/examples/network/securesocketclient/sslclient.h
index 3caf6e2af1..8ebf2cc536 100644
--- a/examples/network/securesocketclient/sslclient.h
+++ b/examples/network/securesocketclient/sslclient.h
@@ -57,7 +57,7 @@ class SslClient : public QWidget
public:
SslClient(QWidget *parent = 0);
~SslClient();
-
+
private slots:
void updateEnabledState();
void secureConnect();
diff --git a/examples/network/torrent/addtorrentdialog.cpp b/examples/network/torrent/addtorrentdialog.cpp
index fac75ba465..d168633df3 100644
--- a/examples/network/torrent/addtorrentdialog.cpp
+++ b/examples/network/torrent/addtorrentdialog.cpp
@@ -117,14 +117,14 @@ void AddTorrentDialog::setTorrent(const QString &torrentFile)
if (lastDestinationDirectory.isEmpty())
lastDestinationDirectory = lastDirectory;
-
+
MetaInfo metaInfo;
QFile torrent(torrentFile);
if (!torrent.open(QFile::ReadOnly) || !metaInfo.parse(torrent.readAll())) {
enableOkButton();
return;
}
-
+
ui.torrentFile->setText(torrentFile);
ui.announceUrl->setText(metaInfo.announceUrl());
if (metaInfo.comment().isEmpty())
diff --git a/examples/network/torrent/bencodeparser.cpp b/examples/network/torrent/bencodeparser.cpp
index 2abc41a852..6ef7234539 100644
--- a/examples/network/torrent/bencodeparser.cpp
+++ b/examples/network/torrent/bencodeparser.cpp
@@ -81,26 +81,26 @@ bool BencodeParser::getByteString(QByteArray *byteString)
const int contentSize = content.size();
int size = -1;
do {
- char c = content.at(index);
- if (c < '0' || c > '9') {
- if (size == -1)
- return false;
- if (c != ':') {
- errString = QString("Unexpected character at pos %1: %2")
- .arg(index).arg(c);
- return false;
- }
- ++index;
- break;
- }
- if (size == -1)
- size = 0;
- size *= 10;
- size += c - '0';
+ char c = content.at(index);
+ if (c < '0' || c > '9') {
+ if (size == -1)
+ return false;
+ if (c != ':') {
+ errString = QString("Unexpected character at pos %1: %2")
+ .arg(index).arg(c);
+ return false;
+ }
+ ++index;
+ break;
+ }
+ if (size == -1)
+ size = 0;
+ size *= 10;
+ size += c - '0';
} while (++index < contentSize);
if (byteString)
- *byteString = content.mid(index, size);
+ *byteString = content.mid(index, size);
index += size;
return true;
}
@@ -109,38 +109,38 @@ bool BencodeParser::getInteger(qint64 *integer)
{
const int contentSize = content.size();
if (content.at(index) != 'i')
- return false;
+ return false;
++index;
qint64 num = -1;
bool negative = false;
do {
- char c = content.at(index);
- if (c < '0' || c > '9') {
- if (num == -1) {
- if (c != '-' || negative)
- return false;
- negative = true;
- continue;
- } else {
- if (c != 'e') {
- errString = QString("Unexpected character at pos %1: %2")
- .arg(index).arg(c);
- return false;
- }
- ++index;
- break;
- }
- }
- if (num == -1)
- num = 0;
- num *= 10;
- num += c - '0';
+ char c = content.at(index);
+ if (c < '0' || c > '9') {
+ if (num == -1) {
+ if (c != '-' || negative)
+ return false;
+ negative = true;
+ continue;
+ } else {
+ if (c != 'e') {
+ errString = QString("Unexpected character at pos %1: %2")
+ .arg(index).arg(c);
+ return false;
+ }
+ ++index;
+ break;
+ }
+ }
+ if (num == -1)
+ num = 0;
+ num *= 10;
+ num += c - '0';
} while (++index < contentSize);
if (integer)
- *integer = negative ? -num : num;
+ *integer = negative ? -num : num;
return true;
}
@@ -148,38 +148,38 @@ bool BencodeParser::getList(QList<QVariant> *list)
{
const int contentSize = content.size();
if (content.at(index) != 'l')
- return false;
+ return false;
- QList<QVariant> tmp;
+ QList<QVariant> tmp;
++index;
do {
- if (content.at(index) == 'e') {
- ++index;
- break;
- }
-
- qint64 number;
- QByteArray byteString;
- QList<QVariant> tmpList;
- QMap<QByteArray, QVariant> dictionary;
-
- if (getInteger(&number))
- tmp << number;
- else if (getByteString(&byteString))
- tmp << byteString;
- else if (getList(&tmpList))
- tmp << tmpList;
- else if (getDictionary(&dictionary))
- tmp << QVariant::fromValue<QMap<QByteArray, QVariant> >(dictionary);
- else {
- errString = QString("error at index %1").arg(index);
- return false;
- }
+ if (content.at(index) == 'e') {
+ ++index;
+ break;
+ }
+
+ qint64 number;
+ QByteArray byteString;
+ QList<QVariant> tmpList;
+ QMap<QByteArray, QVariant> dictionary;
+
+ if (getInteger(&number))
+ tmp << number;
+ else if (getByteString(&byteString))
+ tmp << byteString;
+ else if (getList(&tmpList))
+ tmp << tmpList;
+ else if (getDictionary(&dictionary))
+ tmp << QVariant::fromValue<QMap<QByteArray, QVariant> >(dictionary);
+ else {
+ errString = QString("error at index %1").arg(index);
+ return false;
+ }
} while (index < contentSize);
if (list)
- *list = tmp;
+ *list = tmp;
return true;
}
@@ -187,48 +187,48 @@ bool BencodeParser::getDictionary(QMap<QByteArray, QVariant> *dictionary)
{
const int contentSize = content.size();
if (content.at(index) != 'd')
- return false;
+ return false;
- QMap<QByteArray, QVariant> tmp;
+ QMap<QByteArray, QVariant> tmp;
++index;
do {
- if (content.at(index) == 'e') {
- ++index;
- break;
- }
-
- QByteArray key;
- if (!getByteString(&key))
- break;
-
- if (key == "info")
- infoStart = index;
-
- qint64 number;
- QByteArray byteString;
- QList<QVariant> tmpList;
- QMap<QByteArray, QVariant> dictionary;
-
- if (getInteger(&number))
- tmp.insert(key, number);
- else if (getByteString(&byteString))
- tmp.insert(key, byteString);
- else if (getList(&tmpList))
- tmp.insert(key, tmpList);
- else if (getDictionary(&dictionary))
- tmp.insert(key, QVariant::fromValue<QMap<QByteArray, QVariant> >(dictionary));
- else {
- errString = QString("error at index %1").arg(index);
- return false;
- }
-
- if (key == "info")
- infoLength = index - infoStart;
+ if (content.at(index) == 'e') {
+ ++index;
+ break;
+ }
+
+ QByteArray key;
+ if (!getByteString(&key))
+ break;
+
+ if (key == "info")
+ infoStart = index;
+
+ qint64 number;
+ QByteArray byteString;
+ QList<QVariant> tmpList;
+ QMap<QByteArray, QVariant> dictionary;
+
+ if (getInteger(&number))
+ tmp.insert(key, number);
+ else if (getByteString(&byteString))
+ tmp.insert(key, byteString);
+ else if (getList(&tmpList))
+ tmp.insert(key, tmpList);
+ else if (getDictionary(&dictionary))
+ tmp.insert(key, QVariant::fromValue<QMap<QByteArray, QVariant> >(dictionary));
+ else {
+ errString = QString("error at index %1").arg(index);
+ return false;
+ }
+
+ if (key == "info")
+ infoLength = index - infoStart;
} while (index < contentSize);
if (dictionary)
- *dictionary = tmp;
+ *dictionary = tmp;
return true;
}
diff --git a/examples/network/torrent/bencodeparser.h b/examples/network/torrent/bencodeparser.h
index 4fcaeab50a..5d3aeada04 100644
--- a/examples/network/torrent/bencodeparser.h
+++ b/examples/network/torrent/bencodeparser.h
@@ -54,7 +54,7 @@ class BencodeParser
{
public:
BencodeParser();
-
+
bool parse(const QByteArray &content);
QString errorString() const;
diff --git a/examples/network/torrent/filemanager.h b/examples/network/torrent/filemanager.h
index 721d62210d..41f1aa9a40 100644
--- a/examples/network/torrent/filemanager.h
+++ b/examples/network/torrent/filemanager.h
@@ -65,7 +65,7 @@ public:
inline void setMetaInfo(const MetaInfo &info) { metaInfo = info; }
inline void setDestinationFolder(const QString &directory) { destinationPath = directory; }
-
+
int read(int pieceIndex, int offset, int length);
void write(int pieceIndex, int offset, const QByteArray &data);
void verifyPiece(int pieceIndex);
diff --git a/examples/network/torrent/main.cpp b/examples/network/torrent/main.cpp
index 13b40d28cc..9cdca69122 100644
--- a/examples/network/torrent/main.cpp
+++ b/examples/network/torrent/main.cpp
@@ -45,7 +45,6 @@
int main(int argc, char *argv[])
{
QApplication app(argc, argv);
- qWarning("The usage of QHttp is not recommended anymore, please use QNetworkAccessManager.");
qsrand(QTime(0,0,0).secsTo(QTime::currentTime()));
Q_INIT_RESOURCE(icons);
diff --git a/examples/network/torrent/mainwindow.cpp b/examples/network/torrent/mainwindow.cpp
index 8d664abb93..649dbb0a77 100644
--- a/examples/network/torrent/mainwindow.cpp
+++ b/examples/network/torrent/mainwindow.cpp
@@ -130,7 +130,7 @@ MainWindow::MainWindow(QWidget *parent)
QAction *newTorrentAction = new QAction(QIcon(":/icons/bottom.png"), tr("Add &new torrent"), this);
pauseTorrentAction = new QAction(QIcon(":/icons/player_pause.png"), tr("&Pause torrent"), this);
removeTorrentAction = new QAction(QIcon(":/icons/player_stop.png"), tr("&Remove torrent"), this);
-
+
// File menu
QMenu *fileMenu = menuBar()->addMenu(tr("&File"));
fileMenu->addAction(newTorrentAction);
diff --git a/examples/network/torrent/mainwindow.h b/examples/network/torrent/mainwindow.h
index f0c3ea62c9..6ba42be81f 100644
--- a/examples/network/torrent/mainwindow.h
+++ b/examples/network/torrent/mainwindow.h
@@ -65,7 +65,7 @@ public:
QSize sizeHint() const;
const TorrentClient *clientForRow(int row) const;
-
+
protected:
void closeEvent(QCloseEvent *event);
@@ -94,12 +94,12 @@ private slots:
void about();
void setActionsEnabled();
void acceptFileDrop(const QString &fileName);
-
+
private:
int rowOfClient(TorrentClient *client) const;
bool addTorrent(const QString &fileName, const QString &destinationFolder,
const QByteArray &resumeState = QByteArray());
-
+
TorrentView *torrentView;
QAction *pauseTorrentAction;
QAction *removeTorrentAction;
diff --git a/examples/network/torrent/metainfo.h b/examples/network/torrent/metainfo.h
index 741fe69299..17daca559e 100644
--- a/examples/network/torrent/metainfo.h
+++ b/examples/network/torrent/metainfo.h
@@ -100,7 +100,7 @@ public:
// Total size
qint64 totalSize() const;
-private:
+private:
QString errString;
QByteArray content;
QByteArray infoData;
diff --git a/examples/network/torrent/peerwireclient.cpp b/examples/network/torrent/peerwireclient.cpp
index ade465ab47..0f77ba10d3 100644
--- a/examples/network/torrent/peerwireclient.cpp
+++ b/examples/network/torrent/peerwireclient.cpp
@@ -386,15 +386,15 @@ bool PeerWireClient::canTransferMore() const
|| !outgoingBuffer.isEmpty() || !pendingBlocks.isEmpty();
}
-void PeerWireClient::connectToHostImplementation(const QString &hostName,
- quint16 port, OpenMode openMode)
+void PeerWireClient::connectToHost(const QHostAddress &address,
+ quint16 port, OpenMode openMode)
{
setOpenMode(openMode);
- socket.connectToHost(hostName, port, openMode);
+ socket.connectToHost(address, port, openMode);
}
-void PeerWireClient::diconnectFromHostImplementation()
+void PeerWireClient::diconnectFromHost()
{
socket.disconnectFromHost();
}
diff --git a/examples/network/torrent/peerwireclient.h b/examples/network/torrent/peerwireclient.h
index 391a77b8d8..35e4cc6ffb 100644
--- a/examples/network/torrent/peerwireclient.h
+++ b/examples/network/torrent/peerwireclient.h
@@ -63,7 +63,7 @@ struct TorrentBlock
&& offset == other.offset
&& length == other.length;
}
-
+
int pieceIndex;
int offset;
int length;
@@ -118,6 +118,10 @@ public:
void setReadBufferSize(qint64 size);
+ void connectToHost(const QHostAddress &address,
+ quint16 port, OpenMode openMode = ReadWrite);
+ void diconnectFromHost();
+
signals:
void infoHashReceived(const QByteArray &infoHash);
void readyToTransfer();
@@ -133,11 +137,6 @@ signals:
void bytesReceived(qint64 size);
-protected slots:
- void connectToHostImplementation(const QString &hostName,
- quint16 port, OpenMode openMode = ReadWrite);
- void diconnectFromHostImplementation();
-
protected:
void timerEvent(QTimerEvent *event);
diff --git a/examples/network/torrent/torrentclient.cpp b/examples/network/torrent/torrentclient.cpp
index 748e5185fe..b5969e552e 100644
--- a/examples/network/torrent/torrentclient.cpp
+++ b/examples/network/torrent/torrentclient.cpp
@@ -1020,7 +1020,7 @@ void TorrentClient::blockReceived(int pieceIndex, int begin, const QByteArray &d
if (blocksLeftForPiece(piece) == 0) {
// Ask the file manager to verify the newly downloaded piece
d->fileManager.verifyPiece(piece->index);
-
+
// Remove this piece from all payloads
QMultiMap<PeerWireClient *, TorrentPiece *>::Iterator it = d->payloads.begin();
while (it != d->payloads.end()) {
@@ -1103,7 +1103,7 @@ void TorrentClient::scheduleUploads()
}
if ((client->peerWireState() & PeerWireClient::ChokingPeer) == 0) {
- if ((qrand() % 10) == 0)
+ if ((qrand() % 10) == 0)
client->abort();
else
client->chokePeer();
@@ -1245,7 +1245,7 @@ void TorrentClient::schedulePieceForClient(PeerWireClient *client)
if (d->state == WarmingUp || (qrand() & 4) == 0) {
int *occurrences = new int[d->pieceCount];
memset(occurrences, 0, d->pieceCount * sizeof(int));
-
+
// Count how many of each piece are available.
foreach (PeerWireClient *peer, d->connections) {
QBitArray peerPieces = peer->availablePieces();
@@ -1342,7 +1342,7 @@ void TorrentClient::requestMore(PeerWireClient *client)
? MaxBlocksInMultiMode : MaxBlocksInProgress);
if (numBlocksInProgress == maxInProgress)
return;
-
+
// Starting with the first piece that we're waiting for, request
// blocks until the quota is filled up.
foreach (TorrentPiece *piece, piecesInProgress) {
@@ -1446,7 +1446,7 @@ void TorrentClient::addToPeerList(const QList<TorrentPeer> &peerList)
// Skip our own server.
continue;
}
-
+
bool known = false;
foreach (TorrentPeer *knownPeer, d->peers) {
if (knownPeer->port == peer.port
diff --git a/examples/network/torrent/torrentclient.h b/examples/network/torrent/torrentclient.h
index be50189b53..7f48d1697c 100644
--- a/examples/network/torrent/torrentclient.h
+++ b/examples/network/torrent/torrentclient.h
@@ -124,7 +124,7 @@ public:
qint64 uploadedBytes() const;
int connectedPeerCount() const;
int seedCount() const;
-
+
// Accessors for the tracker
QByteArray peerId() const;
QByteArray infoHash() const;
@@ -142,7 +142,7 @@ signals:
void downloadCompleted();
void peerInfoUpdated();
-
+
void dataSent(int uploadedBytes);
void dataReceived(int downloadedBytes);
void progressUpdated(int percentProgress);
diff --git a/examples/network/torrent/trackerclient.cpp b/examples/network/torrent/trackerclient.cpp
index d714050fa7..fef3c7d596 100644
--- a/examples/network/torrent/trackerclient.cpp
+++ b/examples/network/torrent/trackerclient.cpp
@@ -97,14 +97,10 @@ void TrackerClient::timerEvent(QTimerEvent *event)
void TrackerClient::fetchPeerList()
{
- // Prepare connection details
- QString fullUrl = metaInfo.announceUrl();
- QUrl url(fullUrl);
- QString passkey = "?";
- if (fullUrl.contains("?passkey")) {
- passkey = metaInfo.announceUrl().mid(fullUrl.indexOf("?passkey"), -1);
- passkey += '&';
- }
+ QUrl url(metaInfo.announceUrl());
+
+ // Base the query on announce url to include a passkey (if any)
+ QUrlQuery query(url);
// Percent encode the hash
QByteArray infoHash = torrentDownloader->infoHash();
@@ -115,43 +111,44 @@ void TrackerClient::fetchPeerList()
}
bool seeding = (torrentDownloader->state() == TorrentClient::Seeding);
- QByteArray query;
- query += url.path().toLatin1();
- query += passkey;
- query += "info_hash=" + encodedSum;
- query += "&peer_id=" + ConnectionManager::instance()->clientId();
- query += "&port=" + QByteArray::number(TorrentServer::instance()->serverPort());
- query += "&compact=1";
- query += "&uploaded=" + QByteArray::number(torrentDownloader->uploadedBytes());
+
+ query.addQueryItem("info_hash", encodedSum);
+ query.addQueryItem("peer_id", ConnectionManager::instance()->clientId());
+ query.addQueryItem("port", QByteArray::number(TorrentServer::instance()->serverPort()));
+ query.addQueryItem("compact", "1");
+ query.addQueryItem("uploaded", QByteArray::number(torrentDownloader->uploadedBytes()));
if (!firstSeeding) {
- query += "&downloaded=0";
- query += "&left=0";
+ query.addQueryItem("downloaded", "0");
+ query.addQueryItem("left", "0");
} else {
- query += "&downloaded=" + QByteArray::number(
- torrentDownloader->downloadedBytes());
+ query.addQueryItem("downloaded",
+ QByteArray::number(torrentDownloader->downloadedBytes()));
int left = qMax<int>(0, metaInfo.totalSize() - torrentDownloader->downloadedBytes());
- query += "&left=" + QByteArray::number(seeding ? 0 : left);
+ query.addQueryItem("left", QByteArray::number(seeding ? 0 : left));
}
if (seeding && firstSeeding) {
- query += "&event=completed";
+ query.addQueryItem("event", "completed");
firstSeeding = false;
} else if (firstTrackerRequest) {
firstTrackerRequest = false;
- query += "&event=started";
+ query.addQueryItem("event", "started");
} else if(lastTrackerRequest) {
- query += "&event=stopped";
+ query.addQueryItem("event", "stopped");
}
if (!trackerId.isEmpty())
- query += "&trackerid=" + trackerId;
+ query.addQueryItem("trackerid", trackerId);
+
+ url.setQuery(query);
QNetworkRequest req(url);
if (!url.userName().isEmpty()) {
uname = url.userName();
pwd = url.password();
- connect(&http, SIGNAL(authenticationRequired(QNetworkReply*,QAuthenticator*)), this, SLOT(provideAuthentication(QNetworkReply*,QAuthenticator*)));
+ connect(&http, SIGNAL(authenticationRequired(QNetworkReply*,QAuthenticator*)),
+ this, SLOT(provideAuthentication(QNetworkReply*,QAuthenticator*)));
}
http.get(req);
}
diff --git a/examples/network/torrent/trackerclient.h b/examples/network/torrent/trackerclient.h
index 17d237e665..6647422e3f 100644
--- a/examples/network/torrent/trackerclient.h
+++ b/examples/network/torrent/trackerclient.h
@@ -74,7 +74,7 @@ signals:
void uploadCountUpdated(qint64 newUploadCount);
void downloadCountUpdated(qint64 newDownloadCount);
-
+
void stopped();
protected:
@@ -99,7 +99,7 @@ private:
qint64 length;
QString uname;
QString pwd;
-
+
bool firstTrackerRequest;
bool lastTrackerRequest;
bool firstSeeding;
diff --git a/examples/opengl/cube/geometryengine.cpp b/examples/opengl/cube/geometryengine.cpp
index d573ade1e7..bf63934656 100644
--- a/examples/opengl/cube/geometryengine.cpp
+++ b/examples/opengl/cube/geometryengine.cpp
@@ -50,7 +50,7 @@ struct VertexData
};
GeometryEngine::GeometryEngine()
-{
+{
}
GeometryEngine::~GeometryEngine()
diff --git a/examples/opengl/cube/mainwidget.cpp b/examples/opengl/cube/mainwidget.cpp
index 0ba859c6b8..8c87de6736 100644
--- a/examples/opengl/cube/mainwidget.cpp
+++ b/examples/opengl/cube/mainwidget.cpp
@@ -68,7 +68,7 @@ void MainWidget::mouseReleaseEvent(QMouseEvent *e)
// Mouse release position - mouse press position
QVector2D diff = QVector2D(e->localPos()) - mousePressPosition;
- // Rotation axis is perpendicular to the mouse position difference
+ // Rotation axis is perpendicular to the mouse position difference
// vector
QVector3D n = QVector3D(diff.y(), diff.x(), 0.0).normalized();
diff --git a/examples/opengl/grabber/glwidget.cpp b/examples/opengl/grabber/glwidget.cpp
index f9e866b7c8..abe3a8540a 100644
--- a/examples/opengl/grabber/glwidget.cpp
+++ b/examples/opengl/grabber/glwidget.cpp
@@ -116,7 +116,7 @@ void GLWidget::initializeGL()
gear3 = makeGear(reflectance3, 1.3, 2.0, 0.5, 0.7, 10);
glEnable(GL_NORMALIZE);
- glClearColor(0.0f, 0.0f, 0.0f, 1.0f);
+ glClearColor(0.0f, 0.0f, 0.0f, 1.0f);
}
void GLWidget::paintGL()
diff --git a/examples/opengl/grabber/glwidget.h b/examples/opengl/grabber/glwidget.h
index 91e10edb6e..976d22a421 100644
--- a/examples/opengl/grabber/glwidget.h
+++ b/examples/opengl/grabber/glwidget.h
@@ -90,7 +90,7 @@ private:
int yRot;
int zRot;
int gear1Rot;
-
+
QPoint lastPos;
};
diff --git a/examples/opengl/hellogl_es2/bubble.cpp b/examples/opengl/hellogl_es2/bubble.cpp
index 50d64f37da..3e0f053bc8 100644
--- a/examples/opengl/hellogl_es2/bubble.cpp
+++ b/examples/opengl/hellogl_es2/bubble.cpp
@@ -114,7 +114,7 @@ void Bubble::move(const QRect &bbox)
qreal rightOverflow = position.x() + radius - bbox.right();
qreal topOverflow = position.y() - radius - bbox.top();
qreal bottomOverflow = position.y() + radius - bbox.bottom();
-
+
if (leftOverflow < 0.0) {
position.setX(position.x() - 2 * leftOverflow);
vel.setX(-vel.x());
diff --git a/examples/opengl/hellogl_es2/glwidget.cpp b/examples/opengl/hellogl_es2/glwidget.cpp
index 2727c73fa5..a5c22447f0 100644
--- a/examples/opengl/hellogl_es2/glwidget.cpp
+++ b/examples/opengl/hellogl_es2/glwidget.cpp
@@ -70,7 +70,7 @@ void GLWidget::setScaling(int scale) {
m_fScale = 1 + qreal(scale -50) / 50 * 0.5;
else if (scale < 50)
m_fScale = 1- (qreal(50 - scale) / 50 * 1/2);
- else
+ else
m_fScale = 1;
}
@@ -316,7 +316,7 @@ void GLWidget::paintGL()
painter.drawText(20, 40, framesPerSecond + " fps");
painter.end();
-
+
swapBuffers();
QMutableListIterator<Bubble*> iter(bubbles);
diff --git a/examples/opengl/hellogl_es2/glwidget.h b/examples/opengl/hellogl_es2/glwidget.h
index 4536dc3749..8ed86b1e01 100644
--- a/examples/opengl/hellogl_es2/glwidget.h
+++ b/examples/opengl/hellogl_es2/glwidget.h
@@ -55,7 +55,7 @@ class GLWidget : public QGLWidget {
public:
GLWidget(QWidget *parent = 0);
~GLWidget();
-public slots:
+public slots:
void setScaling(int scale);
void setLogo();
void setTexture();
diff --git a/examples/opengl/hellogl_es2/mainwindow.cpp b/examples/opengl/hellogl_es2/mainwindow.cpp
index a9db386c4c..eb4ce0ac3e 100644
--- a/examples/opengl/hellogl_es2/mainwindow.cpp
+++ b/examples/opengl/hellogl_es2/mainwindow.cpp
@@ -57,7 +57,7 @@ MainWindow::MainWindow()
QTimer *timer = new QTimer(this);
QSlider *slider = new QSlider(this);
slider->setOrientation(Qt::Horizontal);
-
+
slider->setRange(0, 100);
slider->setSliderPosition(50);
timer->setInterval(10);
diff --git a/examples/opengl/overpainting/bubble.cpp b/examples/opengl/overpainting/bubble.cpp
index c64cca7e0d..dbcb72bc93 100644
--- a/examples/opengl/overpainting/bubble.cpp
+++ b/examples/opengl/overpainting/bubble.cpp
@@ -85,7 +85,7 @@ void Bubble::move(const QRect &bbox)
qreal rightOverflow = position.x() + radius - bbox.right();
qreal topOverflow = position.y() - radius - bbox.top();
qreal bottomOverflow = position.y() + radius - bbox.bottom();
-
+
if (leftOverflow < 0.0) {
position.setX(position.x() - 2 * leftOverflow);
vel.setX(-vel.x());
diff --git a/examples/opengl/paintedwindow/paintedwindow.cpp b/examples/opengl/paintedwindow/paintedwindow.cpp
index 9b0ddb6ab1..d891f8d563 100644
--- a/examples/opengl/paintedwindow/paintedwindow.cpp
+++ b/examples/opengl/paintedwindow/paintedwindow.cpp
@@ -56,7 +56,7 @@ PaintedWindow::PaintedWindow()
format.setSamples(4);
setSurfaceType(QWindow::OpenGLSurface);
- setFlags(Qt::Window | Qt::WindowTitleHint | Qt::WindowMinMaxButtonsHint | Qt::WindowCloseButtonHint);
+ setFlags(Qt::Window | Qt::WindowTitleHint | Qt::WindowSystemMenuHint | Qt::WindowMinMaxButtonsHint | Qt::WindowCloseButtonHint);
setFormat(format);
create();
diff --git a/examples/qtconcurrent/imagescaling/imagescaling.cpp b/examples/qtconcurrent/imagescaling/imagescaling.cpp
index 6a0a73e867..01083edb4e 100644
--- a/examples/qtconcurrent/imagescaling/imagescaling.cpp
+++ b/examples/qtconcurrent/imagescaling/imagescaling.cpp
@@ -50,8 +50,8 @@ QImage scale(const QString &imageFileName)
return image.scaled(QSize(imageSize, imageSize), Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
}
-Images::Images(QWidget *parent)
-: QWidget(parent)
+Images::Images(QWidget *parent)
+ : QWidget(parent)
{
setWindowTitle(tr("Image loading and scaling example"));
resize(800, 600);
@@ -66,11 +66,11 @@ Images::Images(QWidget *parent)
cancelButton = new QPushButton(tr("Cancel"));
cancelButton->setEnabled(false);
connect(cancelButton, SIGNAL(clicked()), imageScaling, SLOT(cancel()));
-
+
pauseButton = new QPushButton(tr("Pause/Resume"));
pauseButton->setEnabled(false);
connect(pauseButton, SIGNAL(clicked()), imageScaling, SLOT(togglePaused()));
-
+
QHBoxLayout *buttonLayout = new QHBoxLayout();
buttonLayout->addWidget(openButton);
buttonLayout->addWidget(cancelButton);
@@ -101,7 +101,7 @@ void Images::open()
}
// Show a file open dialog at QStandardPaths::PicturesLocation.
- QStringList files = QFileDialog::getOpenFileNames(this, tr("Select Images"),
+ QStringList files = QFileDialog::getOpenFileNames(this, tr("Select Images"),
QStandardPaths::writableLocation(QStandardPaths::PicturesLocation),
"*.jpg *.png");
@@ -143,4 +143,3 @@ void Images::finished()
}
#endif // QT_NO_CONCURRENT
-
diff --git a/examples/qtconcurrent/progressdialog/main.cpp b/examples/qtconcurrent/progressdialog/main.cpp
index 155bb2ee11..c646105db6 100644
--- a/examples/qtconcurrent/progressdialog/main.cpp
+++ b/examples/qtconcurrent/progressdialog/main.cpp
@@ -69,7 +69,7 @@ int main(int argc, char **argv)
// Create a progress dialog.
QProgressDialog dialog;
dialog.setLabelText(QString("Progressing using %1 thread(s)...").arg(QThread::idealThreadCount()));
-
+
// Create a QFutureWatcher and connect signals and slots.
QFutureWatcher<void> futureWatcher;
QObject::connect(&futureWatcher, SIGNAL(finished()), &dialog, SLOT(reset()));
@@ -82,7 +82,7 @@ int main(int argc, char **argv)
// Display the dialog and start the event loop.
dialog.exec();
-
+
futureWatcher.waitForFinished();
// Query the future to check if was canceled.
diff --git a/examples/qtestlib/tutorial5/benchmarking.cpp b/examples/qtestlib/tutorial5/benchmarking.cpp
index 4ad984212b..55d25e8a36 100644
--- a/examples/qtestlib/tutorial5/benchmarking.cpp
+++ b/examples/qtestlib/tutorial5/benchmarking.cpp
@@ -81,7 +81,7 @@ void TestBenchmark::multiple()
QFETCH(bool, useLocaleCompare);
QString str1 = QLatin1String("This is a test string");
QString str2 = QLatin1String("This is a test string");
-
+
int result;
if (useLocaleCompare) {
QBENCHMARK {
@@ -101,7 +101,7 @@ void TestBenchmark::series_data()
{
QTest::addColumn<bool>("useLocaleCompare");
QTest::addColumn<int>("stringSize");
-
+
for (int i = 1; i < 10000; i += 2000) {
QByteArray size = QByteArray::number(i);
QTest::newRow(("locale aware compare--" + size).constData()) << true << i;
diff --git a/examples/sql/doc/src/querymodel.qdoc b/examples/sql/doc/src/querymodel.qdoc
index 9d9729192a..b25cc745e3 100644
--- a/examples/sql/doc/src/querymodel.qdoc
+++ b/examples/sql/doc/src/querymodel.qdoc
@@ -32,7 +32,7 @@
\brief The Query Model example shows how to make customized versions of
data obtained from a SQL query, using a model that encapsulates
- the query and table views to display the results.
+ the query and table views to display the results.
\image querymodel-example.png
*/
diff --git a/examples/sql/doc/src/relationaltablemodel.qdoc b/examples/sql/doc/src/relationaltablemodel.qdoc
index cf10322c2d..36fe7e2dfb 100644
--- a/examples/sql/doc/src/relationaltablemodel.qdoc
+++ b/examples/sql/doc/src/relationaltablemodel.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\example relationaltablemodel
\title Relational Table Model Example
\ingroup sql_examples
diff --git a/examples/sql/doc/src/tablemodel.qdoc b/examples/sql/doc/src/tablemodel.qdoc
index 146025c2d0..be1fb6b488 100644
--- a/examples/sql/doc/src/tablemodel.qdoc
+++ b/examples/sql/doc/src/tablemodel.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\example tablemodel
\title Table Model Example
\ingroup sql_examples
diff --git a/examples/threads/queuedcustomtype/main.cpp b/examples/threads/queuedcustomtype/main.cpp
index 337970445f..98933c66f3 100644
--- a/examples/threads/queuedcustomtype/main.cpp
+++ b/examples/threads/queuedcustomtype/main.cpp
@@ -81,7 +81,7 @@ QImage createImage(int width, int height)
int x = 0;
int y = 0;
int starWidth = image.width()/3;
- int starHeight = image.height()/3;
+ int starHeight = image.height()/3;
QRect rect(x, y, starWidth, starHeight);
diff --git a/examples/tools/doc/contiguouscache.qdoc b/examples/tools/doc/contiguouscache.qdoc
index a02c1796c6..2f7ea716e6 100644
--- a/examples/tools/doc/contiguouscache.qdoc
+++ b/examples/tools/doc/contiguouscache.qdoc
@@ -70,7 +70,7 @@
And thats it. A perfectly reasonable cache, using minimal memory for a very large
list. In this case the accessor for getting the words into the cache
- generates random information rather than fixed information. This allows you
+ generates random information rather than fixed information. This allows you
to see how the cache range is kept for a local number of rows when running the
example.
diff --git a/examples/tools/doc/src/customtype.qdoc b/examples/tools/doc/src/customtype.qdoc
index a4a05350f3..56172a4e26 100644
--- a/examples/tools/doc/src/customtype.qdoc
+++ b/examples/tools/doc/src/customtype.qdoc
@@ -104,7 +104,7 @@
With the type fully defined, implemented, and integrated with the
meta-object system, we can now use it.
- \section1 Using the Message
+ \section1 Using the Message
In the example's \c{main()} function, we show how a \c Message object can
be printed to the console by sending it to the debug stream:
diff --git a/examples/touch/fingerpaint/scribblearea.cpp b/examples/touch/fingerpaint/scribblearea.cpp
index f672a3fdd1..0d13e4579d 100644
--- a/examples/touch/fingerpaint/scribblearea.cpp
+++ b/examples/touch/fingerpaint/scribblearea.cpp
@@ -154,7 +154,7 @@ void ScribbleArea::resizeImage(QImage *image, const QSize &newSize)
//! [21]
void ScribbleArea::print()
{
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
QPrinter printer(QPrinter::HighResolution);
QPrintDialog printDialog(&printer, this);
diff --git a/examples/touch/pinchzoom/mouse.cpp b/examples/touch/pinchzoom/mouse.cpp
index 9c5ca86e6a..40e6ccb127 100644
--- a/examples/touch/pinchzoom/mouse.cpp
+++ b/examples/touch/pinchzoom/mouse.cpp
@@ -158,7 +158,7 @@ void Mouse::timerEvent(QTimerEvent *)
foreach (QGraphicsItem *item, dangerMice) {
if (item == this)
continue;
-
+
QLineF lineToMouse(QPointF(0, 0), mapFromItem(item, 0, 0));
qreal angleToMouse = ::acos(lineToMouse.dx() / lineToMouse.length());
if (lineToMouse.dy() < 0)
diff --git a/examples/widgets/animation/appchooser/main.cpp b/examples/widgets/animation/appchooser/main.cpp
index 2184d1bcdf..a65e998b32 100644
--- a/examples/widgets/animation/appchooser/main.cpp
+++ b/examples/widgets/animation/appchooser/main.cpp
@@ -108,7 +108,7 @@ void createStates(const QObjectList &objects,
void createAnimations(const QObjectList &objects, QStateMachine *machine)
{
for (int i=0; i<objects.size(); ++i)
- machine->addDefaultAnimation(new QPropertyAnimation(objects.at(i), "geometry"));
+ machine->addDefaultAnimation(new QPropertyAnimation(objects.at(i), "geometry"));
}
int main(int argc, char **argv)
diff --git a/examples/widgets/animation/easing/window.h b/examples/widgets/animation/easing/window.h
index b47f236d95..d7fa927b49 100644
--- a/examples/widgets/animation/easing/window.h
+++ b/examples/widgets/animation/easing/window.h
@@ -63,11 +63,11 @@ private slots:
void periodChanged(double);
void amplitudeChanged(double);
void overshootChanged(double);
-
+
private:
void createCurveIcons();
void startAnimation();
-
+
Ui::Form m_ui;
QGraphicsScene m_scene;
PixmapItem *m_item;
diff --git a/examples/widgets/animation/stickman/animation.cpp b/examples/widgets/animation/stickman/animation.cpp
index ebfbd1b5b8..730ee236e4 100644
--- a/examples/widgets/animation/stickman/animation.cpp
+++ b/examples/widgets/animation/stickman/animation.cpp
@@ -45,13 +45,13 @@
#include <QIODevice>
#include <QDataStream>
-class Frame
+class Frame
{
public:
Frame() {
}
- int nodeCount() const
+ int nodeCount() const
{
return m_nodePositions.size();
}
@@ -70,7 +70,7 @@ public:
{
m_nodePositions[idx] = pos;
}
-
+
private:
QVector<QPointF> m_nodePositions;
};
@@ -81,7 +81,7 @@ Animation::Animation()
m_frames.append(new Frame);
}
-Animation::~Animation()
+Animation::~Animation()
{
qDeleteAll(m_frames);
}
@@ -89,10 +89,10 @@ Animation::~Animation()
void Animation::setTotalFrames(int totalFrames)
{
while (m_frames.size() < totalFrames)
- m_frames.append(new Frame);
+ m_frames.append(new Frame);
while (totalFrames < m_frames.size())
- delete m_frames.takeLast();
+ delete m_frames.takeLast();
}
int Animation::totalFrames() const
@@ -165,15 +165,15 @@ void Animation::load(QIODevice *device)
QDataStream stream(device);
stream >> m_name;
-
+
int frameCount;
stream >> frameCount;
for (int i=0; i<frameCount; ++i) {
-
+
int nodeCount;
stream >> nodeCount;
-
+
Frame *frame = new Frame;
frame->setNodeCount(nodeCount);
diff --git a/examples/widgets/animation/stickman/lifecycle.cpp b/examples/widgets/animation/stickman/lifecycle.cpp
index c49fac7905..09ca45e55b 100644
--- a/examples/widgets/animation/stickman/lifecycle.cpp
+++ b/examples/widgets/animation/stickman/lifecycle.cpp
@@ -65,7 +65,7 @@ public:
if (QSignalTransition::eventTest(e)) {
QVariant key = static_cast<QStateMachine::SignalEvent*>(e)->arguments().at(0);
return (key.toInt() == int(m_key));
- }
+ }
return false;
}
@@ -100,7 +100,7 @@ LifeCycle::LifeCycle(StickMan *stickMan, GraphicsView *keyReceiver)
const int stickManNodeCount = m_stickMan->nodeCount();
for (int i=0; i<stickManNodeCount; ++i) {
QPropertyAnimation *pa = new QPropertyAnimation(m_stickMan->node(i), "pos");
- m_animationGroup->addAnimation(pa);
+ m_animationGroup->addAnimation(pa);
}
// Set up initial state graph
@@ -111,14 +111,14 @@ LifeCycle::LifeCycle(StickMan *stickMan, GraphicsView *keyReceiver)
m_alive = new QState(m_machine);
m_alive->setObjectName("alive");
-
+
// Make it blink when lightning strikes before entering dead animation
- QState *lightningBlink = new QState(m_machine);
+ QState *lightningBlink = new QState(m_machine);
lightningBlink->assignProperty(m_stickMan->scene(), "backgroundBrush", QColor(Qt::white));
lightningBlink->assignProperty(m_stickMan, "penColor", QColor(Qt::black));
lightningBlink->assignProperty(m_stickMan, "fillColor", QColor(Qt::white));
lightningBlink->assignProperty(m_stickMan, "isDead", true);
-
+
//! [5]
QTimer *timer = new QTimer(lightningBlink);
timer->setSingleShot(true);
@@ -126,13 +126,13 @@ LifeCycle::LifeCycle(StickMan *stickMan, GraphicsView *keyReceiver)
QObject::connect(lightningBlink, SIGNAL(entered()), timer, SLOT(start()));
QObject::connect(lightningBlink, SIGNAL(exited()), timer, SLOT(stop()));
//! [5]
-
+
m_dead = new QState(m_machine);
m_dead->assignProperty(m_stickMan->scene(), "backgroundBrush", QColor(Qt::black));
m_dead->assignProperty(m_stickMan, "penColor", QColor(Qt::white));
m_dead->assignProperty(m_stickMan, "fillColor", QColor(Qt::black));
m_dead->setObjectName("dead");
-
+
// Idle state (sets no properties)
m_idle = new QState(m_alive);
m_idle->setObjectName("idle");
@@ -172,7 +172,7 @@ void LifeCycle::addActivity(const QString &fileName, Qt::Key key, QObject *sende
QState *LifeCycle::makeState(QState *parentState, const QString &animationFileName)
{
QState *topLevel = new QState(parentState);
-
+
Animation animation;
{
QFile file(animationFileName);
@@ -186,7 +186,7 @@ QState *LifeCycle::makeState(QState *parentState, const QString &animationFileNa
animation.setCurrentFrame(i);
//! [1]
- QState *frameState = new QState(topLevel);
+ QState *frameState = new QState(topLevel);
const int nodeCount = animation.nodeCount();
for (int j=0; j<nodeCount; ++j)
frameState->assignProperty(m_stickMan->node(j), "pos", animation.nodePos(j));
@@ -199,7 +199,7 @@ QState *LifeCycle::makeState(QState *parentState, const QString &animationFileNa
//! [2]
previousState->addTransition(previousState, SIGNAL(propertiesAssigned()), frameState);
//! [2]
-
+
previousState = frameState;
}
diff --git a/examples/widgets/animation/stickman/node.cpp b/examples/widgets/animation/stickman/node.cpp
index b47a1e8433..0694ee3a2f 100644
--- a/examples/widgets/animation/stickman/node.cpp
+++ b/examples/widgets/animation/stickman/node.cpp
@@ -62,7 +62,7 @@ QRectF Node::boundingRect() const
}
void Node::paint(QPainter *painter, const QStyleOptionGraphicsItem *, QWidget *)
-{
+{
painter->setPen(Qt::white);
painter->drawEllipse(QPointF(0.0, 0.0), 5.0, 5.0);
}
@@ -83,7 +83,7 @@ void Node::mousePressEvent(QGraphicsSceneMouseEvent *)
void Node::mouseMoveEvent(QGraphicsSceneMouseEvent *event)
{
if (m_dragging)
- setPos(mapToParent(event->pos()));
+ setPos(mapToParent(event->pos()));
}
void Node::mouseReleaseEvent(QGraphicsSceneMouseEvent *)
diff --git a/examples/widgets/animation/stickman/stickman.h b/examples/widgets/animation/stickman/stickman.h
index 337fe4a794..08928a48a6 100644
--- a/examples/widgets/animation/stickman/stickman.h
+++ b/examples/widgets/animation/stickman/stickman.h
@@ -62,7 +62,7 @@ public:
virtual QRectF boundingRect() const;
virtual void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget);
- int nodeCount() const;
+ int nodeCount() const;
Node *node(int idx) const;
void setDrawSticks(bool on);
@@ -90,7 +90,7 @@ private:
Node *m_nodes[NodeCount];
qreal m_perfectBoneLengths[BoneCount];
-
+
uint m_sticks : 1;
uint m_isDead : 1;
uint m_reserved : 30;
diff --git a/examples/widgets/animation/sub-attaq/boat_p.h b/examples/widgets/animation/sub-attaq/boat_p.h
index 265e706d96..e12cbc74bd 100644
--- a/examples/widgets/animation/sub-attaq/boat_p.h
+++ b/examples/widgets/animation/sub-attaq/boat_p.h
@@ -68,7 +68,7 @@ class KeyStopTransition : public QKeyEventTransition
{
public:
KeyStopTransition(Boat *b, QEvent::Type t, int k)
- : QKeyEventTransition(b, t, k), boat(b), key(k)
+ : QKeyEventTransition(b, t, k), boat(b)
{
}
protected:
@@ -80,7 +80,6 @@ protected:
}
private:
Boat * boat;
- int key;
};
//These transtion test if we have to move the boat (i.e current speed was 0 or another value)
diff --git a/examples/widgets/animation/sub-attaq/qanimationstate.h b/examples/widgets/animation/sub-attaq/qanimationstate.h
index 9d733c10ee..68eac43e13 100644
--- a/examples/widgets/animation/sub-attaq/qanimationstate.h
+++ b/examples/widgets/animation/sub-attaq/qanimationstate.h
@@ -50,8 +50,6 @@
# include "qabstractanimation.h"
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -86,6 +84,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QANIMATIONSTATE_H
diff --git a/examples/widgets/animation/sub-attaq/states.cpp b/examples/widgets/animation/sub-attaq/states.cpp
index 8c78ccdd12..e36d13ad07 100644
--- a/examples/widgets/animation/sub-attaq/states.cpp
+++ b/examples/widgets/animation/sub-attaq/states.cpp
@@ -123,7 +123,7 @@ void PlayState::onEntry(QEvent *)
levelState->addTransition(winTransition);
//This state is an animation when the score changed
- UpdateScoreState *scoreState = new UpdateScoreState(this, levelState);
+ UpdateScoreState *scoreState = new UpdateScoreState(levelState);
//This transition update the score when a submarine die
UpdateScoreTransition *scoreTransition = new UpdateScoreTransition(scene, this, levelState);
@@ -275,7 +275,7 @@ void WinState::onExit(QEvent *)
}
/** UpdateScore State */
-UpdateScoreState::UpdateScoreState(PlayState *g, QState *parent) : QState(parent), game(g)
+UpdateScoreState::UpdateScoreState(QState *parent) : QState(parent)
{
}
diff --git a/examples/widgets/animation/sub-attaq/states.h b/examples/widgets/animation/sub-attaq/states.h
index b1730a230d..3cd27be9a4 100644
--- a/examples/widgets/animation/sub-attaq/states.h
+++ b/examples/widgets/animation/sub-attaq/states.h
@@ -70,7 +70,6 @@ private :
QStateMachine *machine;
int currentLevel;
int score;
- QState *parallelChild;
friend class UpdateScoreState;
friend class UpdateScoreTransition;
@@ -103,7 +102,6 @@ protected:
void onExit(QEvent *);
private :
GraphicsScene *scene;
- Boat *boat;
};
class LostState : public QState
@@ -135,10 +133,8 @@ private :
class UpdateScoreState : public QState
{
public:
- UpdateScoreState(PlayState *game, QState *parent);
+ UpdateScoreState(QState *parent);
private:
- QPropertyAnimation *scoreAnimation;
- PlayState *game;
};
//These transtion is used to update the score
@@ -174,7 +170,6 @@ protected:
virtual bool eventTest(QEvent *event);
private:
PlayState *game;
- int key;
};
#endif // STATES_H
diff --git a/examples/widgets/dialogs/classwizard/classwizard.h b/examples/widgets/dialogs/classwizard/classwizard.h
index 751179f81b..34a35a2ce9 100644
--- a/examples/widgets/dialogs/classwizard/classwizard.h
+++ b/examples/widgets/dialogs/classwizard/classwizard.h
@@ -124,7 +124,7 @@ class OutputFilesPage : public QWizardPage
{
Q_OBJECT
-public:
+public:
OutputFilesPage(QWidget *parent = 0);
protected:
diff --git a/examples/widgets/dialogs/classwizard/main.cpp b/examples/widgets/dialogs/classwizard/main.cpp
index 110ada0ed3..4a22dbb212 100644
--- a/examples/widgets/dialogs/classwizard/main.cpp
+++ b/examples/widgets/dialogs/classwizard/main.cpp
@@ -48,7 +48,7 @@
int main(int argc, char *argv[])
{
Q_INIT_RESOURCE(classwizard);
-
+
QApplication app(argc, argv);
#ifndef QT_NO_TRANSLATION
diff --git a/examples/widgets/dialogs/dialogs.pro b/examples/widgets/dialogs/dialogs.pro
index c31c37222d..d30c29778f 100644
--- a/examples/widgets/dialogs/dialogs.pro
+++ b/examples/widgets/dialogs/dialogs.pro
@@ -9,5 +9,6 @@ SUBDIRS = classwizard \
extension \
findfiles
+!qtHaveModule(printsupport): SUBDIRS -= licensewizard
contains(DEFINES, QT_NO_WIZARD): SUBDIRS -= trivialwizard licensewizard classwizard
wince*: SUBDIRS += sipdialog
diff --git a/examples/widgets/dialogs/licensewizard/licensewizard.cpp b/examples/widgets/dialogs/licensewizard/licensewizard.cpp
index e6bb506494..8f63583a7c 100644
--- a/examples/widgets/dialogs/licensewizard/licensewizard.cpp
+++ b/examples/widgets/dialogs/licensewizard/licensewizard.cpp
@@ -352,7 +352,7 @@ void ConclusionPage::setVisible(bool visible)
void ConclusionPage::printButtonClicked()
{
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
QPrinter printer;
QPrintDialog dialog(&printer, this);
if (dialog.exec())
diff --git a/examples/widgets/dialogs/sipdialog/dialog.cpp b/examples/widgets/dialogs/sipdialog/dialog.cpp
index b3592f3308..c51feac0a5 100644
--- a/examples/widgets/dialogs/sipdialog/dialog.cpp
+++ b/examples/widgets/dialogs/sipdialog/dialog.cpp
@@ -91,7 +91,7 @@ Dialog::Dialog()
//! [Dialog constructor part5]
connect(button, SIGNAL(clicked()),
qApp, SLOT(closeAllWindows()));
- connect(QApplication::desktop(), SIGNAL(workAreaResized(int)),
+ connect(QApplication::desktop(), SIGNAL(workAreaResized(int)),
this, SLOT(desktopResized(int)));
}
//! [Dialog constructor part5]
diff --git a/examples/widgets/doc/src/addressbook-fr.qdoc b/examples/widgets/doc/src/addressbook-fr.qdoc
index 0d6ff16b57..9a7bc3a6b7 100644
--- a/examples/widgets/doc/src/addressbook-fr.qdoc
+++ b/examples/widgets/doc/src/addressbook-fr.qdoc
@@ -36,7 +36,7 @@
\image addressbook-tutorial-screenshot.png
- Ce tutoriel va nous amener à découvrir quelques technologies fondamentales fournies
+ Ce tutoriel va nous amener à découvrir quelques technologies fondamentales fournies
par Qt, tel que:
\list
@@ -124,7 +124,7 @@
réutilisé dans d'autres projets
\endlist
- Comme Qt ne fournit pas de widget standard pour un carnet d'adresses, nous
+ Comme Qt ne fournit pas de widget standard pour un carnet d'adresses, nous
partirons d'une classe de widget Qt standard et y ajouterons des fonctionnalités.
La classe \c AddressBook crée dans ce tutoriel peut être réutilisée si on a besoin d'un
widget carnet d'adresses basique.
@@ -148,12 +148,12 @@
dans \c nameLine et \c addressText sont nécessaires à de nombreuses méthodes
du carnet d'adresses.
- Il n'est pas nécessaire de déclarer les objets QLabel que nous allons utiliser
+ Il n'est pas nécessaire de déclarer les objets QLabel que nous allons utiliser
puisque nous n'aurons pas besoin d'y faire référence après leur création.
La façon dont Qt gère la parenté des objets est traitée dans la section suivante.
La macro Q_OBJECT implémente des fonctionnalités parmi les plus avancées de Qt.
- Pour le moment, il est bon de voir la macro Q_OBJECT comme un raccourci nous
+ Pour le moment, il est bon de voir la macro Q_OBJECT comme un raccourci nous
permettant d'utiliser les méthodes \l{QObject::}{tr()} et \l{QObject::}{connect()}.
Nous en avons maintenant terminé avec le fichier \c addressbook.h et allons
@@ -295,13 +295,13 @@
Le bouton \c addButton est affiché en invoquant la méthode \l{QPushButton::show()}
{show()}, tandis que \c submitButton et \c cancelButton sont cachés en invoquant
- \l{QPushButton::hide()}{hide()}. Ces deux boutons ne seront affichés que lorsque
+ \l{QPushButton::hide()}{hide()}. Ces deux boutons ne seront affichés que lorsque
l'utilisateur cliquera sur "Add", et ceci est géré par la méthode \c addContact()
décrite plus loin.
\snippet tutorials/addressbook/part2/addressbook.cpp connecting signals and slots
- Nous connectons le signal \l{QPushButton::clicked()}{clicked()} de chaque bouton
+ Nous connectons le signal \l{QPushButton::clicked()}{clicked()} de chaque bouton
au slot qui gèrera l'action.
L'image ci-dessous illustre ceci:
@@ -379,8 +379,8 @@
\snippet tutorials/addressbook/part2/addressbook.cpp cancel
- L'idée générale pour augmenter la flexibilité lors de l'ajout d'un
- contact est de donner la possiblité de cliquer sur "Add"
+ L'idée générale pour augmenter la flexibilité lors de l'ajout d'un
+ contact est de donner la possiblité de cliquer sur "Add"
ou "Cancel" à n'importe quel moment.
L'organigramme ci-dessous reprend l'ensemble des interactions dévelopées
jusqu'ici:
@@ -458,15 +458,15 @@
\c mainLayout.
\image addressbook-tutorial-part3-labeled-layout.png
- Dans notre méthode \c addContact(), nous avons desactivé ces boutons
- pour être sûr que l'utilisateur n'utilise pas la navigation lors de
+ Dans notre méthode \c addContact(), nous avons desactivé ces boutons
+ pour être sûr que l'utilisateur n'utilise pas la navigation lors de
l'ajout d'un contact.
\snippet tutorials/addressbook/part3/addressbook.cpp disabling navigation
Dans notre méthode \c submitContact(), nous activons les boutons de
navigation, \c nextButton et \c previousButton, en fonction de la
- taille de \c contacts. Commen mentionné plus tôt, la navigation n'est
+ taille de \c contacts. Commen mentionné plus tôt, la navigation n'est
activée que si il y a plus d'un contact dans le carnet d'adresses.
Les lignes suivantes montrent comment faire cela:
@@ -475,13 +475,13 @@
Nous incluons aussi ces lignes de code dans le bouton \c cancel().
Souvenez vous que nous voulons émuler une liste-liée ciruculaire à
- l'aide de l'objet QMap, \c contacts. Pour faire cela, nous obtenons un itérateur
+ l'aide de l'objet QMap, \c contacts. Pour faire cela, nous obtenons un itérateur
sur \c contact dans la méthode \c next(), et ensuite:
\list
\li Si l'itérateur n'est pas à la fin de \c contacts, nous l'incrémentons
\li Si l'itérateur est à la fin de \c contacts, nous changeons sa position
- jusqu'au début de \c contacts. Cela donne l'illusion que notre QMap
+ jusqu'au début de \c contacts. Cela donne l'illusion que notre QMap
fonctionne comme une liste circulaire.
\endlist
@@ -490,7 +490,7 @@
Une fois que nous avons itéré jusqu'à l'objet recherché dans \c contacts,
nous affichons son contenu sur \c nameLine et \c addressText.
- De la même façon, pour la méthode \c previous(), nous obtenons un
+ De la même façon, pour la méthode \c previous(), nous obtenons un
itérateur sur \c contacts et ensuite:
\list
@@ -522,7 +522,7 @@
\image addressbook-tutorial-screenshot.png
Nous avons maintenant un carnet d'adresses qui ne se contente pas de
- lister des contacts de façon ordonnée, mais permet également la
+ lister des contacts de façon ordonnée, mais permet également la
navigation. Il serait pratique d'inclure des fonctions telles qu'éditer et
supprimer, afin que les détails associés à un contact puissent être
modifiés lorsque c'est nécessaire. Cependant, cela requiert une légère
@@ -563,7 +563,7 @@
\dots
\snippet tutorials/addressbook/part4/addressbook.h mode declaration
- Enfin, on déclare \c currentMode pour garder une trace du mode
+ Enfin, on déclare \c currentMode pour garder une trace du mode
actuellement utilisé.
\section1 Implémentation de la classe AddressBook
@@ -637,7 +637,7 @@
avant de tester sa valeur.
Chacun des boutons est ensuite activé ou désactivé, en fonction du mode.
- Le code source pour les cas \c AddingMode et \c EditingMode est visible
+ Le code source pour les cas \c AddingMode et \c EditingMode est visible
ci-dessous:
\snippet tutorials/addressbook/part4/addressbook.cpp update interface() part 1
@@ -840,7 +840,7 @@
\section1 Définition de la classe AddressBook
- On déclare deux slots publics, \c saveToFile() et \c loadFromFile(),
+ On déclare deux slots publics, \c saveToFile() et \c loadFromFile(),
ainsi que deux objets QPushButton, \c loadButton et \c saveButton.
\snippet tutorials/addressbook/part6/addressbook.h save and load functions declaration
@@ -863,11 +863,11 @@
\snippet tutorials/addressbook/part6/addressbook.cpp tooltip 2
Bien qu'on ne cite pas le code correspondant ici, nous ajoutons ces deux boutons au
- layout de droite, \c button1Layout, comme pour les fonctionnalités précédentes, et
+ layout de droite, \c button1Layout, comme pour les fonctionnalités précédentes, et
nous connectons leurs signaux
\l{QPushButton::clicked()}{clicked()} à leurs slots respectifs.
- Pour la sauvegarde, on commence par récupérer le nom de fichier
+ Pour la sauvegarde, on commence par récupérer le nom de fichier
\c fileName, en utilisant QFileDialog::getSaveFileName(). C'est une
méthode pratique fournie par QFileDialog, qui ouvre une boîte de
dialogue modale et permet à l'utilisateur d'entrer un nom de fichier ou
@@ -966,7 +966,7 @@
\section1 Définition de la classe AddressBook
Nous ajoutons un objet QPushButton, \c exportButton, et un slot
- public correspondant, \c exportAsVCard(), à notre classe \c AddressBook
+ public correspondant, \c exportAsVCard(), à notre classe \c AddressBook
dans le fichier \c addressbook.h.
\snippet tutorials/addressbook/part7/addressbook.h exportAsVCard() declaration
@@ -1001,7 +1001,7 @@
cela échoue, nous affichons un QMessageBox pour informer l'utilisateur
à propos de l'origine du problème et nous quittons la méthode. Sinon, nous passons le
fichier comme paramètre pour créer un objet QTextStream, \c out. De la même façon que
- QDataStream, la classe QTextStream fournit les fonctionnalités pour
+ QDataStream, la classe QTextStream fournit les fonctionnalités pour
lire et écrire des fichiers de texte. Grâce à celà, le fichier \c{.vcf}
généré pourra être ouvert et édité à l'aide d'un simple éditeur de texte.
@@ -1014,7 +1014,7 @@
à un nom de famille défini ou non. Si oui, nous utilions les détails de
\c nameList pour remplir le champ, dans le cas contraire on écrit uniquement le contenu
de \c firstName.
-
+
\snippet tutorials/addressbook/part7/addressbook.cpp export function part3
Nous continuons en écrivant l'adresse du contact. Les points-virgules
@@ -1026,7 +1026,7 @@
\snippet tutorials/addressbook/part7/addressbook.cpp export function part4
À la fin de la méthode, un QMessageBox est affiché pour informer l'utilisateur
- que la vCard a été exportée avec succès.
+ que la vCard a été exportée avec succès.
\e{vCard est une marque déposée de \l{http://www.imc.org}
{Internet Mail Consortium}}.
diff --git a/examples/widgets/doc/src/addressbook-tutorial.qdoc b/examples/widgets/doc/src/addressbook-tutorial.qdoc
index db3d785616..089ab2319d 100644
--- a/examples/widgets/doc/src/addressbook-tutorial.qdoc
+++ b/examples/widgets/doc/src/addressbook-tutorial.qdoc
@@ -73,7 +73,7 @@
have worked through this tutorial, we recommend reading the
\l{mainwindows/application}{Application} example, which presents a
small GUI application, with menus, toolbars, a status bar, and so
- on.
+ on.
*/
/*!
@@ -199,7 +199,7 @@
Notice that \c addressLabel is positioned using Qt::AlignTop as an
additional argument. This is to make sure it is not vertically centered in
- cell (1,0). For a basic overview on Qt Layouts, refer to the
+ cell (1,0). For a basic overview on Qt Layouts, refer to the
\l{Layout Management} documentation.
In order to install the layout object onto the widget, we have to invoke
@@ -431,7 +431,7 @@
\snippet tutorials/addressbook/part3/addressbook.cpp connecting navigation signals
- The image below is the expected graphical user interface.
+ The image below is the expected graphical user interface.
\image addressbook-tutorial-part3-screenshot.png
diff --git a/examples/widgets/doc/src/addressbook.qdoc b/examples/widgets/doc/src/addressbook.qdoc
index ea0cb46830..becff14f3f 100644
--- a/examples/widgets/doc/src/addressbook.qdoc
+++ b/examples/widgets/doc/src/addressbook.qdoc
@@ -273,7 +273,7 @@
\snippet itemviews/addressbook/addresswidget.cpp 4a
- Next we extract data from the row the user intends to
+ Next we extract data from the row the user intends to
edit. This data is displayed in an instance of \c AddDialog
with a different window title. The \c table is only
updated if changes have been made to data in \c aDialog.
diff --git a/examples/widgets/doc/src/codeeditor.qdoc b/examples/widgets/doc/src/codeeditor.qdoc
index 2848908233..3db55eddc5 100644
--- a/examples/widgets/doc/src/codeeditor.qdoc
+++ b/examples/widgets/doc/src/codeeditor.qdoc
@@ -60,7 +60,7 @@
We will now move on to the definitions and implementations of \c
CodeEditor and \c LineNumberArea. Let's start with the \c
- LineNumberArea class.
+ LineNumberArea class.
\section1 The LineNumberArea Class
@@ -130,7 +130,7 @@
\snippet widgets/codeeditor/codeeditor.cpp resizeEvent
When the size of the editor changes, we also need to resize the
- line number area.
+ line number area.
\snippet widgets/codeeditor/codeeditor.cpp cursorPositionChanged
@@ -155,7 +155,7 @@
The \c lineNumberAreaPaintEvent() is called from \c LineNumberArea
whenever it receives a paint event. We start off by painting the
- widget's background.
+ widget's background.
\snippet widgets/codeeditor/codeeditor.cpp extraAreaPaintEvent_1
@@ -163,11 +163,11 @@
numbers in the extra area for each line. Notice that in a plain
text edit each line will consist of one QTextBlock; though, if
line wrapping is enabled, a line may span several rows in the text
- edit's viewport.
+ edit's viewport.
We get the top and bottom y-coordinate of the first text block,
and adjust these values by the height of the current text block in
- each iteration in the loop.
+ each iteration in the loop.
\snippet widgets/codeeditor/codeeditor.cpp extraAreaPaintEvent_2
@@ -183,7 +183,7 @@
In addition to line numbers, you can add more to the extra area,
for instance, break points.
-
+
QSyntaxHighlighter gives the possibility to add user data to each
text block with
\l{QSyntaxHighlighter::}{setCurrentBlockUserData()}. This can be
diff --git a/examples/widgets/doc/src/coloreditorfactory.qdoc b/examples/widgets/doc/src/coloreditorfactory.qdoc
index 6728d88252..ad4a37492e 100644
--- a/examples/widgets/doc/src/coloreditorfactory.qdoc
+++ b/examples/widgets/doc/src/coloreditorfactory.qdoc
@@ -78,7 +78,7 @@
After the new factory has been set, all standard item delegates
will use it (i.e, also delegates that were created before the new
- default factory was set).
+ default factory was set).
The \c createGUI() function sets up the table and fills it
with data.
@@ -135,17 +135,17 @@
\list
\li If the editor widget has no user property defined, the delegate
- asks the factory for the property name, which it in turn
- asks the item editor creator for. In this case, you can use
- the QItemEditorCreator class, which takes the property
- name to use for editing as a constructor argument.
+ asks the factory for the property name, which it in turn
+ asks the item editor creator for. In this case, you can use
+ the QItemEditorCreator class, which takes the property
+ name to use for editing as a constructor argument.
\li If the editor requires other constructors or other
- initialization than provided by QItemEditorCreatorBase, you
- must reimplement
- QItemEditorCreatorBase::createWidget().
+ initialization than provided by QItemEditorCreatorBase, you
+ must reimplement
+ QItemEditorCreatorBase::createWidget().
\li You could also subclass QItemEditorFactory if you only want
- to provide editors for certain kinds of data or use another
- method of creating the editors than using creator bases.
+ to provide editors for certain kinds of data or use another
+ method of creating the editors than using creator bases.
\endlist
In this example, we use a standard QVariant data type. You can
diff --git a/examples/widgets/doc/src/diagramscene.qdoc b/examples/widgets/doc/src/diagramscene.qdoc
index f05ad42130..92048cdcaf 100644
--- a/examples/widgets/doc/src/diagramscene.qdoc
+++ b/examples/widgets/doc/src/diagramscene.qdoc
@@ -50,7 +50,7 @@
In this example we show how to create such custom graphics
scenes and items by implementing classes that inherit
- QGraphicsScene and QGraphicsItem.
+ QGraphicsScene and QGraphicsItem.
In particular we show how to:
@@ -65,21 +65,21 @@
The example consists of the following classes:
\list
\li \c MainWindow creates the widgets and display
- them in a QMainWindow. It also manages the interaction
- between the widgets and the graphics scene, view and
- items.
+ them in a QMainWindow. It also manages the interaction
+ between the widgets and the graphics scene, view and
+ items.
\li \c DiagramItem inherits QGraphicsPolygonItem and
- represents a flowchart shape.
+ represents a flowchart shape.
\li \c TextDiagramItem inherits QGraphicsTextItem and
- represents text items in the diagram. The class adds
- support for moving the item with the mouse, which is not
- supported by QGraphicsTextItem.
+ represents text items in the diagram. The class adds
+ support for moving the item with the mouse, which is not
+ supported by QGraphicsTextItem.
\li \c Arrow inherits QGraphicsLineItem and is an arrow
- that connect two DiagramItems.
+ that connect two DiagramItems.
\li \c DiagramScene inherits QGraphicsDiagramScene and
- provides support for \c DiagramItem, \c Arrow and
- \c DiagramTextItem (In addition to the support already
- handled by QGraphicsScene).
+ provides support for \c DiagramItem, \c Arrow and
+ \c DiagramTextItem (In addition to the support already
+ handled by QGraphicsScene).
\endlist
\section1 MainWindow Class Definition
@@ -88,7 +88,7 @@
The \c MainWindow class creates and lays out the widgets in a
QMainWindow. The class forwards input from the widgets to the
- DiagramScene. It also updates its widgets when the diagram
+ DiagramScene. It also updates its widgets when the diagram
scene's text item changes, or a diagram item or a diagram text item
is inserted into the scene.
@@ -104,8 +104,8 @@
\snippet graphicsview/diagramscene/mainwindow.cpp 0
In the constructor we call methods to create the widgets and
- layouts of the example before we create the diagram scene.
- The toolbars must be created after the scene as they connect
+ layouts of the example before we create the diagram scene.
+ The toolbars must be created after the scene as they connect
to its signals. We then lay the widgets out in the window.
We connect to the \c itemInserted() and \c textInserted() slots of
@@ -115,20 +115,20 @@
update the widgets that display font properties if the item
selected is a \c DiagramTextItem.
- The \c createToolBox() function creates and lays out the widgets
+ The \c createToolBox() function creates and lays out the widgets
of the \c toolBox QToolBox. We will not examine it with a
- high level of detail as it does not deal with graphics framework
+ high level of detail as it does not deal with graphics framework
specific functionality. Here is its implementation:
\snippet graphicsview/diagramscene/mainwindow.cpp 21
-
+
This part of the function sets up the tabbed widget item that
- contains the flowchart shapes. An exclusive QButtonGroup always
+ contains the flowchart shapes. An exclusive QButtonGroup always
keeps one button checked; we want the group to allow all buttons
to be unchecked.
We still use a button group since we can associate user
- data, which we use to store the diagram type, with each button.
- The \c createCellWidget() function sets up the buttons in the
+ data, which we use to store the diagram type, with each button.
+ The \c createCellWidget() function sets up the buttons in the
tabbed widget item and is examined later.
The buttons of the background tabbed widget item is set up in the
@@ -137,7 +137,7 @@
\snippet graphicsview/diagramscene/mainwindow.cpp 22
We set the preferred size of the toolbox as its maximum. This
- way, more space is given to the graphics view.
+ way, more space is given to the graphics view.
Here is the \c createActions() function:
@@ -202,7 +202,7 @@
with this function is used in the tool box.
Here is the \c createColorMenu() function:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 30
This function creates a color menu that is used as the
@@ -224,7 +224,7 @@
\snippet graphicsview/diagramscene/mainwindow.cpp 32
- This function creates an icon with a filled rectangle in the
+ This function creates an icon with a filled rectangle in the
color of \a color. It is used for creating icons for the color
menus in the \c fillColorToolButton, \c fontColorToolButton, and
\c lineColorToolButton.
@@ -240,8 +240,8 @@
with.
When one of the buttons in the background tabbed widget item is
- clicked we change the brush; we find out which button it is by
- checking its text.
+ clicked we change the brush; we find out which button it is by
+ checking its text.
Here is the implementation of \c buttonGroupClicked():
@@ -255,37 +255,37 @@
checked at a time.
\c QButtonGroup assigns an id to each button. We have set the id
- of each button to the diagram type, as given by DiagramItem::DiagramType
- that will be inserted into the scene when it is clicked. We can
- then use the button id when we set the diagram type with
+ of each button to the diagram type, as given by DiagramItem::DiagramType
+ that will be inserted into the scene when it is clicked. We can
+ then use the button id when we set the diagram type with
\c setItemType(). In the case of text we assigned an id that has a
value that is not in the DiagramType enum.
-
+
Here is the implementation of \c deleteItem():
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 3
-
+
This slot deletes the selected item, if any, from the scene. It
deletes the arrows first in order to avoid to delete them twice. If
the item to be deleted is a \c DiagramItem, we also need to delete
arrows connected to it; we don't want arrows in the scene that
aren't connected to items in both ends.
-
+
This is the implementation of pointerGroupClicked():
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 4
-
+
The \c pointerTypeGroup decides whether the scene is in ItemMove
- or InsertLine mode. This button group is exclusive, i.e., only
+ or InsertLine mode. This button group is exclusive, i.e., only
one button is checked at any time. As with the \c buttonGroup above
we have assigned an id to the buttons that matches values of the
DiagramScene::Mode enum, so that we can use the id to set the
correct mode.
-
+
Here is the \c bringToFront() slot:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 5
-
+
Several items may collide, i.e., overlap, with each other in
the scene. This slot is called when the user requests that an
item should be placed on top of the items it collides with.
@@ -296,169 +296,169 @@
lower values. When we bring an item to the front we can loop
through the items it collides with and set a z-value that is
higher than all of them.
-
+
Here is the \c sendToBack() slot:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 6
-
+
This slot works in the same way as \c bringToFront() described
above, but sets a z-value that is lower than items the item that
should be send to the back collides with.
-
+
This is the implementation of \c itemInserted():
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 7
-
+
This slot is called from the \c DiagramScene when an item has been
added to the scene. We set the mode of the scene back to the mode
before the item was inserted, which is ItemMove or InsertText
- depending on which button is checked in the \c pointerTypeGroup.
+ depending on which button is checked in the \c pointerTypeGroup.
We must also uncheck the button in the in the \c buttonGroup.
-
+
Here is the implementation of \c textInserted():
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 8
-
+
We simply set the mode of the scene back to the mode it had before
the text was inserted.
-
+
Here is the \c currentFontChanged() slot:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 9
-
+
When the user requests a font change, by using one of the
widgets in the \c fontToolBar, we create a new QFont object and
set its properties to match the state of the widgets. This is done
in \c handleFontChange(), so we simply call that slot.
-
+
Here is the \c fontSizeChanged() slot:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 10
-
+
When the user requests a font change, by using one of the
widgets in the \c fontToolBar, we create a new QFont object and
set its properties to match the state of the widgets. This is done
in \c handleFontChange(), so we simply call that slot.
-
+
Here is the implementation of \c sceneScaleChanged():
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 11
-
+
The user can increase or decrease the scale, with the \c
sceneScaleCombo, the scene is drawn in.
It is not the scene itself that changes its scale, but only the
- view.
-
+ view.
+
Here is the \c textColorChanged() slot:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 12
-
+
This slot is called when an item in the drop-down menu of the \c
- fontColorToolButton is pressed. We need to change the icon on
+ fontColorToolButton is pressed. We need to change the icon on
the button to the color of the selected QAction. We keep a pointer
to the selected action in \c textAction. It is in \c
textButtonTriggered() we change the text color to the color of \c
textAction, so we call that slot.
-
+
Here is the \c itemColorChanged() implementation:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 13
-
+
This slot handles requests for changing the color of \c
DiagramItems in the same manner as \c textColorChanged() does for
\c DiagramTextItems.
-
+
Here is the implementation of \c lineColorChanged():
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 14
-
+
This slot handles requests for changing the color of \c Arrows in
the same manner that \c textColorChanged() does it for \c
DiagramTextItems.
-
+
Here is the \c textButtonTriggered() slot:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 15
-
+
\c textAction points to the QAction of the currently selected menu item
in the \c fontColorToolButton's color drop-down menu. We have set
the data of the action to the QColor the action represents, so we
can simply fetch this when we set the color of text with \c
setTextColor().
-
+
Here is the \c fillButtonTriggered() slot:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 16
-
+
\c fillAction points to the selected menu item in the drop-down
menu of \c fillColorToolButton(). We can therefore use the data of
this action when we set the item color with \c setItemColor().
-
+
Here is the \c lineButtonTriggered() slot:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 17
-
+
\c lineAction point to the selected item in the drop-down menu of
- \c lineColorToolButton. We use its data when we set the arrow
+ \c lineColorToolButton. We use its data when we set the arrow
color with \c setLineColor().
-
+
Here is the \c handleFontChange() function:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 18
-
+
\c handleFontChange() is called when any of the widgets that show
font properties changes. We create a new QFont object and set its
properties based on the widgets. We then call the \c setFont()
function of \c DiagramScene; it is the scene that set the font of
the \c DiagramTextItems it manages.
-
+
Here is the \c itemSelected() slot:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 19
-
+
This slot is called when an item in the \c DiagramScene is
selected. In the case of this example it is only text items that
emit signals when they are selected, so we do not need to check
what kind of graphics \a item is.
-
+
We set the state of the widgets to match the properties of the
font of the selected text item.
-
+
This is the \c about() slot:
-
+
\snippet graphicsview/diagramscene/mainwindow.cpp 20
-
+
This slot displays an about box for the example when the user
selects the about menu item from the help menu.
-
+
\section1 DiagramScene Class Definition
-
+
The \c DiagramScene class inherits QGraphicsScene and adds
functionality to handle \c DiagramItems, \c Arrows, and \c
DiagramTextItems in addition to the items handled by its super
class.
-
-
+
+
\snippet graphicsview/diagramscene/diagramscene.h 0
-
+
In the \c DiagramScene a mouse click can give three different
actions: the item under the mouse can be moved, an item may be
inserted, or an arrow may be connected between to diagram items.
Which action a mouse click has depends on the mode, given by the
Mode enum, the scene is in. The mode is set with the \c setMode()
function.
-
+
The scene also sets the color of its items and the font of its
text items. The colors and font used by the scene can be set with
the \c setLineColor(), \c setTextColor(), \c setItemColor() and \c
setFont() functions. The type of \c DiagramItem, given by the
DiagramItem::DiagramType function, to be created when an item is
inserted is set with the \c setItemType() slot.
-
+
The \c MainWindow and \c DiagramScene share responsibility for
the examples functionality. \c MainWindow handles the following
tasks: the deletion of items, text, and arrows; moving diagram
- items to the back and front; and setting the scale of the scene.
+ items to the back and front; and setting the scale of the scene.
\section1 DiagramScene Class Implementation
@@ -492,12 +492,12 @@
\snippet graphicsview/diagramscene/diagramscene.cpp 3
- This function sets the color the scene will use when creating
+ This function sets the color the scene will use when creating
\c DiagramItems. It also changes the color of a selected \c
DiagramItem.
This is the implementation of \c setFont():
-
+
\snippet graphicsview/diagramscene/diagramscene.cpp 4
Set the font to use for new and selected, if a text item is
@@ -511,15 +511,15 @@
connected to this slot. We remove the item if it has no text.
If not, we would leak memory and confuse the user as the items
will be edited when pressed on by the mouse.
-
+
The \c mousePressEvent() function handles mouse press event's
different depending on which mode the \c DiagramScene is in. We
examine its implementation for each mode:
-
+
\snippet graphicsview/diagramscene/diagramscene.cpp 6
We simply create a new \c DiagramItem and add it to the scene at
- the position the mouse was pressed. Note that the origin of its
+ the position the mouse was pressed. Note that the origin of its
local coordinate system will be under the mouse pointer position.
\snippet graphicsview/diagramscene/diagramscene.cpp 7
@@ -534,7 +534,7 @@
line.
\snippet graphicsview/diagramscene/diagramscene.cpp 8
-
+
The \c DiagramTextItem is editable when the
Qt::TextEditorInteraction flag is set, else it is movable by the
mouse. We always want the text to be drawn on top of the other
@@ -547,12 +547,12 @@
can then call the QGraphicsScene implementation, which
handles movement of items with the mouse. We make this call even
if we are in another mode making it possible to add an item and
- then keep the mouse button pressed down and start moving
+ then keep the mouse button pressed down and start moving
the item. In the case of text items, this is not possible as they
do not propagate mouse events when they are editable.
This is the \c mouseMoveEvent() function:
-
+
\snippet graphicsview/diagramscene/diagramscene.cpp 10
We must draw the line if we are in InsertMode and the mouse button
@@ -567,7 +567,7 @@
should be added to the scene:
\snippet graphicsview/diagramscene/diagramscene.cpp 11
-
+
First we need to get the items (if any) under the line's start
and end points. The line itself is the first item at these points,
so we remove it from the lists. As a precaution, we check if the
@@ -603,7 +603,7 @@
DiagramScene. It inherits QGraphicsPolygonItem and has a polygon
for each shape. The enum DiagramType has a value for each of the
flowchart shapes.
-
+
The class has a list of the arrows that are connected to it.
This is necessary because only the item knows when it is being
moved (with the \c itemChanged() function) at which time the
@@ -612,7 +612,7 @@
buttons in \c MainWindow, see \c createColorToolButtonIcon() in
\c MainWindow.
- The Type enum is a unique identifier of the class. It is used by
+ The Type enum is a unique identifier of the class. It is used by
\c qgraphicsitem_cast(), which does dynamic casts of graphics
items. The UserType constant is the minimum value a custom
graphics item type can be.
@@ -646,7 +646,7 @@
item.
Here is the \c addArrow() function:
-
+
\snippet graphicsview/diagramscene/diagramitem.cpp 3
This function simply adds the \a arrow to the items \c arrows list.
@@ -695,7 +695,7 @@
possible to alter the mouse behavior of QGraphicsTextItem.
\section1 DiagramTextItem Implementation
-
+
We start with the constructor:
\snippet graphicsview/diagramscene/diagramtextitem.cpp 0
@@ -717,7 +717,7 @@
\c DiagramScene uses the signal emitted when the text item looses
focus to remove the item if it is empty, i.e., it contains no
- text.
+ text.
This is the implementation of \c mouseDoubleClickEvent():
@@ -740,7 +740,7 @@
The item's color can be set with \c setColor().
- \c boundingRect() and \c shape() are reimplemented
+ \c boundingRect() and \c shape() are reimplemented
from QGraphicsLineItem and are used by the scene
to check for collisions and selections.
@@ -769,7 +769,7 @@
We need to reimplement this function because the arrow is
larger than the bounding rectangle of the QGraphicsLineItem. The
graphics scene uses the bounding rectangle to know which regions
- of the scene to update.
+ of the scene to update.
Here is the \c shape() function:
@@ -779,14 +779,14 @@
shape of the item. The QGraphicsLineItem::shape() returns a path
with a line drawn with the current pen, so we only need to add
the arrow head. This function is used to check for collisions and
- selections with the mouse.
+ selections with the mouse.
Here is the \c updatePosition() slot:
\snippet graphicsview/diagramscene/arrow.cpp 3
This slot updates the arrow by setting the start and end
- points of its line to the center of the items it connects.
+ points of its line to the center of the items it connects.
Here is the \c paint() function:
@@ -809,7 +809,7 @@
one of the lines of the polygon. Note that the points in the
polygon are relative to the local coordinate system of the item.
We must therefore add the position of the end item to make the
- coordinates relative to the scene.
+ coordinates relative to the scene.
\snippet graphicsview/diagramscene/arrow.cpp 6
diff --git a/examples/widgets/doc/src/dockwidgets.qdoc b/examples/widgets/doc/src/dockwidgets.qdoc
index 7f08572a30..2987ec1211 100644
--- a/examples/widgets/doc/src/dockwidgets.qdoc
+++ b/examples/widgets/doc/src/dockwidgets.qdoc
@@ -133,7 +133,7 @@
that the entire name and address insertion is treated as a single
operation by the QTextEdit, so a single undo will revert all the
insertions.
-
+
\snippet mainwindows/dockwidgets/mainwindow.cpp 7
This function works in a similar way to \c insertCustomer(). First
@@ -141,7 +141,7 @@
replace it with the standard paragraph that the user clicked. Again
we use a \c beginEditBlock() ... \c endEditBlock() pair so that the
insertion can be undone as a single operation.
-
+
\snippet mainwindows/dockwidgets/mainwindow.cpp 3
Qt's QTextDocument class makes printing documents easy. We simply
diff --git a/examples/widgets/doc/src/easing.qdoc b/examples/widgets/doc/src/easing.qdoc
index 392cb4e826..1b5f0c8077 100644
--- a/examples/widgets/doc/src/easing.qdoc
+++ b/examples/widgets/doc/src/easing.qdoc
@@ -31,7 +31,7 @@
\brief The Easing Curves example shows how to use easing curves to
control the speed of an animation.
-
+
\image easing-example.png
*/
diff --git a/examples/widgets/doc/src/echoplugin.qdoc b/examples/widgets/doc/src/echoplugin.qdoc
index eae5269d62..7b7aa9b868 100644
--- a/examples/widgets/doc/src/echoplugin.qdoc
+++ b/examples/widgets/doc/src/echoplugin.qdoc
@@ -46,7 +46,7 @@
System}{meta-object system}. The plugin \l{How to Create Qt
Plugins}{overview document} gives a high-level introduction to
plugins.
-
+
We have implemented a plugin, the \c EchoPlugin, which implements
the \c EchoInterface. The interface consists of \c echo(), which
takes a QString as argument. The \c EchoPlugin returns the string
@@ -68,8 +68,8 @@
\snippet tools/echoplugin/echowindow/echowindow.h 0
We load the plugin in \c loadPlugin() and cast it to \c
- EchoInterface. When the user clicks the \c button we take the
- text in \c lineEdit and call the interface's \c echo() with it.
+ EchoInterface. When the user clicks the \c button we take the
+ text in \c lineEdit and call the interface's \c echo() with it.
\section1 EchoWindow Class Implementation
@@ -136,15 +136,15 @@
System}{Qt's meta object system} aware of the interface. We do
this so that it will be possible to identify plugins that
implements the interface at run-time. The second argument is a
- string that must identify the interface in a unique way.
+ string that must identify the interface in a unique way.
\section1 EchoPlugin Class Definition
We inherit both QObject and \c EchoInterface to make this class a
plugin. The Q_INTERFACES macro tells Qt which interfaces the class
- implements. In our case we only implement the \c EchoInterface.
- If a class implements more than one interface, they are given as
+ implements. In our case we only implement the \c EchoInterface.
+ If a class implements more than one interface, they are given as
a comma separated list. The Q_PLUGIN_METADATA macro is included next
to the Q_OBJECT macro. It contains the plugins IID and a filename
pointing to a json file containing the metadata for the plugin.
@@ -158,7 +158,7 @@
\snippet tools/echoplugin/plugin/echoplugin.cpp 0
- We simply return the functions parameter.
+ We simply return the functions parameter.
\section1 The \c main() function
@@ -169,7 +169,7 @@
\section1 The Profiles
When creating plugins the profiles need to be adjusted.
- We show here what changes need to be done.
+ We show here what changes need to be done.
The profile in the echoplugin directory uses the \c subdirs
template and simply includes includes to directories in which
@@ -196,7 +196,7 @@
You can find an overview of the macros needed to create plugins
\l{Macros for Defining Plugins}{here}.
-
+
We give an example of a plugin that extend Qt in the \l{Style
Plugin Example}{style plugin} example. The \l{Plug & Paint
Example}{plug and paint} example shows how to create static
diff --git a/examples/widgets/doc/src/fetchmore.qdoc b/examples/widgets/doc/src/fetchmore.qdoc
index 2f32a5d43d..1b1e87e06b 100644
--- a/examples/widgets/doc/src/fetchmore.qdoc
+++ b/examples/widgets/doc/src/fetchmore.qdoc
@@ -62,7 +62,7 @@
\l{QAbstractItemModel::}{fetchMore()} and
\l{QAbstractItemModel::}{canFetchMore()} from QAbstractItemModel.
These functions are called by the item view when it needs more
- items.
+ items.
The \c setDirPath() function sets the directory the model will
work on. We emit \c numberPopulated() each time we add a batch of
diff --git a/examples/widgets/doc/src/flowlayout.qdoc b/examples/widgets/doc/src/flowlayout.qdoc
index f7f5496d07..b482edf946 100644
--- a/examples/widgets/doc/src/flowlayout.qdoc
+++ b/examples/widgets/doc/src/flowlayout.qdoc
@@ -35,27 +35,27 @@
\image flowlayout-example.png Screenshot of the Flow Layout example
The items are first laid out horizontally and then vertically when each line
- in the layout runs out of space.
+ in the layout runs out of space.
- The Flowlayout class mainly uses QLayout and QWidgetItem, while the
- Window uses QWidget and QLabel. We will only document the definition
- and implementation of \c FlowLayout below.
+ The Flowlayout class mainly uses QLayout and QWidgetItem, while the
+ Window uses QWidget and QLabel. We will only document the definition
+ and implementation of \c FlowLayout below.
\section1 FlowLayout Class Definition
-
- The \c FlowLayout class inherits QLayout. It is a custom layout class
- that arranges its child widgets horizontally and vertically.
+
+ The \c FlowLayout class inherits QLayout. It is a custom layout class
+ that arranges its child widgets horizontally and vertically.
\snippet layouts/flowlayout/flowlayout.h 0
We reimplement functions inherited from QLayout. These functions add items to
- the layout and handle their orientation and geometry.
-
+ the layout and handle their orientation and geometry.
+
We also declare two private methods, \c doLayout() and \c smartSpacing().
\c doLayout() lays out the layout items, while the \c
smartSpacing() function calculates the spacing between them.
- \section1 FlowLayout Class Implementation
+ \section1 FlowLayout Class Implementation
We start off by looking at the constructor:
@@ -63,32 +63,32 @@
In the constructor we call \c setContentsMargins() to set the left, top,
right and bottom margin. By default, QLayout uses values provided by
- the current style (see QStyle::PixelMetric).
+ the current style (see QStyle::PixelMetric).
\snippet layouts/flowlayout/flowlayout.cpp 2
- In this example we reimplement \c addItem(), which is a pure virtual
- function. When using \c addItem() the ownership of the layout items is
- transferred to the layout, and it is therefore the layout's
- responsibility to delete them.
-
+ In this example we reimplement \c addItem(), which is a pure virtual
+ function. When using \c addItem() the ownership of the layout items is
+ transferred to the layout, and it is therefore the layout's
+ responsibility to delete them.
+
\snippet layouts/flowlayout/flowlayout.cpp 3
-
- \c addItem() is implemented to add items to the layout.
+
+ \c addItem() is implemented to add items to the layout.
\snippet layouts/flowlayout/flowlayout.cpp 4
We implement \c horizontalSpacing() and \c verticalSpacing() to get
- hold of the spacing between the widgets inside the layout. If the value
- is less than or equal to 0, this value will be used. If not,
+ hold of the spacing between the widgets inside the layout. If the value
+ is less than or equal to 0, this value will be used. If not,
\c smartSpacing() will be called to calculate the spacing.
\snippet layouts/flowlayout/flowlayout.cpp 5
-
- We then implement \c count() to return the number of items in the
- layout. To navigate the list of items we use \c itemAt() and
- takeAt() to remove and return items from the list. If an item is
- removed, the remaining items will be renumbered. All three
+
+ We then implement \c count() to return the number of items in the
+ layout. To navigate the list of items we use \c itemAt() and
+ takeAt() to remove and return items from the list. If an item is
+ removed, the remaining items will be renumbered. All three
functions are pure virtual functions from QLayout.
\snippet layouts/flowlayout/flowlayout.cpp 6
@@ -103,7 +103,7 @@
dependency, and \c heightForWidth() passes the width on to \c doLayout() which
in turn uses the width as an argument for the layout rect, i.e., the bounds in
which the items are laid out. This rect does not include the layout margin().
-
+
\snippet layouts/flowlayout/flowlayout.cpp 8
\c setGeometry() is normally used to do the actual layout, i.e., calculate
@@ -116,30 +116,30 @@
\snippet layouts/flowlayout/flowlayout.cpp 9
\c doLayout() handles the layout if \c horizontalSpacing() or \c
- verticalSpacing() don't return the default value. It uses
- \c getContentsMargins() to calculate the area available to the
- layout items.
-
+ verticalSpacing() don't return the default value. It uses
+ \c getContentsMargins() to calculate the area available to the
+ layout items.
+
\snippet layouts/flowlayout/flowlayout.cpp 10
- It then sets the proper amount of spacing for each widget in the
- layout, based on the current style.
-
+ It then sets the proper amount of spacing for each widget in the
+ layout, based on the current style.
+
\snippet layouts/flowlayout/flowlayout.cpp 11
- The position of each item in the layout is then calculated by
- adding the items width and the line height to the initial x and y
- coordinates. This in turn lets us find out whether the next item
- will fit on the current line or if it must be moved down to the next.
- We also find the height of the current line based on the widgets height.
-
+ The position of each item in the layout is then calculated by
+ adding the items width and the line height to the initial x and y
+ coordinates. This in turn lets us find out whether the next item
+ will fit on the current line or if it must be moved down to the next.
+ We also find the height of the current line based on the widgets height.
+
\snippet layouts/flowlayout/flowlayout.cpp 12
- \c smartSpacing() is designed to get the default spacing for either
- the top-level layouts or the sublayouts. The default spacing for
- top-level layouts, when the parent is a QWidget, will be determined
- by querying the style. The default spacing for sublayouts, when
- the parent is a QLayout, will be determined by querying the spacing
- of the parent layout.
+ \c smartSpacing() is designed to get the default spacing for either
+ the top-level layouts or the sublayouts. The default spacing for
+ top-level layouts, when the parent is a QWidget, will be determined
+ by querying the style. The default spacing for sublayouts, when
+ the parent is a QLayout, will be determined by querying the spacing
+ of the parent layout.
*/
diff --git a/examples/widgets/doc/src/fontsampler.qdoc b/examples/widgets/doc/src/fontsampler.qdoc
index b833390def..8a2678e2f8 100644
--- a/examples/widgets/doc/src/fontsampler.qdoc
+++ b/examples/widgets/doc/src/fontsampler.qdoc
@@ -30,7 +30,7 @@
\title Font Sampler Example
\ingroup examples-painting
\brief The Font Sampler example shows how to preview and print multi-page documents.
-
+
The Font Sampler example shows how to preview and print multi-page documents.
\image fontsampler-example.png
diff --git a/examples/widgets/doc/src/fridgemagnets.qdoc b/examples/widgets/doc/src/fridgemagnets.qdoc
index 5db2cd586c..abaeb2c52a 100644
--- a/examples/widgets/doc/src/fridgemagnets.qdoc
+++ b/examples/widgets/doc/src/fridgemagnets.qdoc
@@ -230,7 +230,7 @@
top-level corner of the drag pixmap, to be the point we calculated
above. This makes the process of dragging the label feel more natural
because the cursor always points to the same place on the label
- during the drag operation.
+ during the drag operation.
We start the drag operation using QDrag's \l{QDrag::}{exec()} function,
requesting that the magnet is copied when the drag is completed.
diff --git a/examples/widgets/doc/src/i18n.qdoc b/examples/widgets/doc/src/i18n.qdoc
index 69b458c882..068995fc90 100644
--- a/examples/widgets/doc/src/i18n.qdoc
+++ b/examples/widgets/doc/src/i18n.qdoc
@@ -32,7 +32,9 @@
\brief The Internationalization (I18N) example demonstrates Qt's support for translated
text. Developers can write the initial application text in one language, and
- translations can be provided later without any modifications to the code.
+ translations can be provided later without any modifications to the code. It also
+ demonstrates how to detect the system language settings and show the UI in the appropriate
+ language.
\image i18n-example.png
*/
diff --git a/examples/widgets/doc/src/mdi.qdoc b/examples/widgets/doc/src/mdi.qdoc
index b35975d50c..c3f74f7a9f 100644
--- a/examples/widgets/doc/src/mdi.qdoc
+++ b/examples/widgets/doc/src/mdi.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\example mainwindows/mdi
\title MDI Example
\ingroup examples-mainwindow
diff --git a/examples/widgets/doc/src/moveblocks.qdoc b/examples/widgets/doc/src/moveblocks.qdoc
index c9eecc9769..b41b16519d 100644
--- a/examples/widgets/doc/src/moveblocks.qdoc
+++ b/examples/widgets/doc/src/moveblocks.qdoc
@@ -43,7 +43,7 @@
\li \c StateSwitcher inherits QState and can add
\c {StateSwitchTransition}s to other states.
When entered, it will randomly transition to one of these
- states.
+ states.
\li \c StateSwitchTransition is a custom transition that
triggers on \c{StateSwitchEvent}s.
\li \c StateSwitchEvent is a QEvent that triggers \c{StateSwitchTransition}s.
@@ -152,7 +152,7 @@
\c StateSwitcher is a state designed for a particular purpose and
will always be a top-level state. We use \c m_stateCount to keep
track of how many states we are managing, and \c m_lastIndex to
- remember which state was the last state to which we transitioned.
+ remember which state was the last state to which we transitioned.
\snippet animation/moveblocks/main.cpp 11
diff --git a/examples/widgets/doc/src/pixelator.qdoc b/examples/widgets/doc/src/pixelator.qdoc
index 1e9af00361..c8b04bb4bc 100644
--- a/examples/widgets/doc/src/pixelator.qdoc
+++ b/examples/widgets/doc/src/pixelator.qdoc
@@ -216,7 +216,7 @@
This enables the items to be drawn without any gaps between them. Removing
the headers also prevents the user from adjusting the sizes of individual
- rows and columns.
+ rows and columns.
We also set the minimum section size to 1 on the headers. If we
didn't, the headers would default to a larger size, preventing
diff --git a/examples/widgets/doc/src/recentfiles.qdoc b/examples/widgets/doc/src/recentfiles.qdoc
index 939ef8b939..58f28b2832 100644
--- a/examples/widgets/doc/src/recentfiles.qdoc
+++ b/examples/widgets/doc/src/recentfiles.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\example mainwindows/recentfiles
\title Recent Files Example
\ingroup examples-mainwindow
diff --git a/examples/widgets/doc/src/regexp.qdoc b/examples/widgets/doc/src/regexp.qdoc
index 9dc3878c10..0523204fce 100644
--- a/examples/widgets/doc/src/regexp.qdoc
+++ b/examples/widgets/doc/src/regexp.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\example tools/regexp
\title Regular Expressions Example
\ingroup examples-widgets-tools
diff --git a/examples/widgets/doc/src/rogue.qdoc b/examples/widgets/doc/src/rogue.qdoc
index 81f34edc68..1690a351fb 100644
--- a/examples/widgets/doc/src/rogue.qdoc
+++ b/examples/widgets/doc/src/rogue.qdoc
@@ -151,7 +151,7 @@
When we enter \c quitState, we update the status bar of the
window.
-
+
\c QKeyEventTransition is a utility class that removes the hassle
of implementing transitions for \l{QKeyEvent}s. We simply need to
specify the key on which the transition should trigger and the
@@ -161,7 +161,7 @@
The transition from \c inputState allows triggering the quit state
when the player types \c {q}.
-
+
\snippet statemachine/rogue/window.cpp 5
The machine is set up, so it's time to start it.
diff --git a/examples/widgets/doc/src/sdi.qdoc b/examples/widgets/doc/src/sdi.qdoc
index 3e703a0ba8..3e8780423a 100644
--- a/examples/widgets/doc/src/sdi.qdoc
+++ b/examples/widgets/doc/src/sdi.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\example mainwindows/sdi
\title SDI Example
\ingroup examples-mainwindow
diff --git a/examples/widgets/doc/src/settingseditor.qdoc b/examples/widgets/doc/src/settingseditor.qdoc
index b53b0389cc..f1e84b7eb6 100644
--- a/examples/widgets/doc/src/settingseditor.qdoc
+++ b/examples/widgets/doc/src/settingseditor.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\example tools/settingseditor
\title Settings Editor Example
\ingroup examples-widgets-tools
diff --git a/examples/widgets/doc/src/simplewidgetmapper.qdoc b/examples/widgets/doc/src/simplewidgetmapper.qdoc
index 0b92c3a4b4..771ac982b5 100644
--- a/examples/widgets/doc/src/simplewidgetmapper.qdoc
+++ b/examples/widgets/doc/src/simplewidgetmapper.qdoc
@@ -61,7 +61,7 @@
The constructor of the \c Window class can be explained in three parts.
In the first part, we set up the widgets used for the user interface:
-
+
\snippet itemviews/simplewidgetmapper/window.cpp Set up widgets
We also set up the buddy relationships between various labels and the
diff --git a/examples/widgets/doc/src/spinboxes.qdoc b/examples/widgets/doc/src/spinboxes.qdoc
index 86cc246419..998a6d2636 100644
--- a/examples/widgets/doc/src/spinboxes.qdoc
+++ b/examples/widgets/doc/src/spinboxes.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\example widgets/spinboxes
\title Spin Boxes Example
\ingroup examples-widgets
diff --git a/examples/widgets/doc/src/standarddialogs.qdoc b/examples/widgets/doc/src/standarddialogs.qdoc
index 57c3281ae8..26c2548611 100644
--- a/examples/widgets/doc/src/standarddialogs.qdoc
+++ b/examples/widgets/doc/src/standarddialogs.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\example dialogs/standarddialogs
\title Standard Dialogs Example
\ingroup examples-dialogs
diff --git a/examples/widgets/doc/src/stardelegate.qdoc b/examples/widgets/doc/src/stardelegate.qdoc
index dae7ac9c80..4ee452d866 100644
--- a/examples/widgets/doc/src/stardelegate.qdoc
+++ b/examples/widgets/doc/src/stardelegate.qdoc
@@ -257,7 +257,7 @@
\l{QAbstractItemView::editTriggers()}{edit triggers}, so that the
editor is opened with a single click when the star rating item is
selected.
-
+
The \c populateTableWidget() function fills the QTableWidget with
data:
diff --git a/examples/widgets/doc/src/styleplugin.qdoc b/examples/widgets/doc/src/styleplugin.qdoc
index 51d1e5e73e..e65ded36a4 100644
--- a/examples/widgets/doc/src/styleplugin.qdoc
+++ b/examples/widgets/doc/src/styleplugin.qdoc
@@ -43,7 +43,7 @@
from that class, and adding a macro. In this example we extend Qt
by adding a new GUI look and feel (i.e., making a new QStyle
available). A high-level introduction to plugins is given in the
- plugin \l{How to Create Qt Plugins}{overview document}.
+ plugin \l{How to Create Qt Plugins}{overview document}.
Plugins that provide new styles inherit the QStylePlugin base
class. Style plugins are loaded by Qt and made available through
@@ -72,7 +72,7 @@
\section1 SimpleStylePlugin Class Definition
\c SimpleStylePlugin inherits QStylePlugin and is the plugin
- class.
+ class.
\snippet tools/styleplugin/plugin/simplestyleplugin.h 0
diff --git a/examples/widgets/doc/src/stylesheet.qdoc b/examples/widgets/doc/src/stylesheet.qdoc
index 79d9b35082..ee08b7b88a 100644
--- a/examples/widgets/doc/src/stylesheet.qdoc
+++ b/examples/widgets/doc/src/stylesheet.qdoc
@@ -30,7 +30,7 @@
\title Style Sheet Example
\ingroup examples-widgets
\brief The Style Sheet Example shows how to use style sheets.
-
+
\image stylesheet-pagefold.png Screen Shot of the Pagefold style sheet
*/
diff --git a/examples/widgets/doc/src/sub-attaq.qdoc b/examples/widgets/doc/src/sub-attaq.qdoc
index 1472412855..3b0070b28a 100644
--- a/examples/widgets/doc/src/sub-attaq.qdoc
+++ b/examples/widgets/doc/src/sub-attaq.qdoc
@@ -31,7 +31,7 @@
\brief This example shows Qt's ability to combine \l{The Animation Framework}{the animation framework}
and \l{The State Machine Framework}{the state machine framework} to create a game.
-
+
\image sub-attaq-demo.png
The purpose of the game is to destroy all submarines to win the current level.
diff --git a/examples/widgets/doc/src/tablet.qdoc b/examples/widgets/doc/src/tablet.qdoc
index 6cb9ef5057..4fa67b85d3 100644
--- a/examples/widgets/doc/src/tablet.qdoc
+++ b/examples/widgets/doc/src/tablet.qdoc
@@ -41,7 +41,7 @@
it is close but not pressed down on it), when a device is pushed
down and released from it, and when a device is moved on the
tablet.
-
+
The information available in QTabletEvent depends on the device
used. The tablet in this example has two different devices for
drawing: a stylus and an airbrush. For both devices the event
@@ -61,23 +61,23 @@
The example consists of the following:
\list
- \li The \c MainWindow class inherits QMainWindow and creates
- the examples menus and connect their slots and signals.
+ \li The \c MainWindow class inherits QMainWindow and creates
+ the examples menus and connect their slots and signals.
\li The \c TabletCanvas class inherits QWidget and
- receives tablet events. It uses the events to paint on a
- offscreen pixmap, which it draws onto itself.
+ receives tablet events. It uses the events to paint on a
+ offscreen pixmap, which it draws onto itself.
\li The \c TabletApplication class inherits QApplication. This
- class handles tablet events that are not sent to \c tabletEvent().
- We will look at this later.
+ class handles tablet events that are not sent to \c tabletEvent().
+ We will look at this later.
\li The \c main() function creates a \c MainWindow and shows it
- as a top level window.
+ as a top level window.
\endlist
\section1 MainWindow Class Definition
- The \c MainWindow creates a \c TabletCanvas and sets it as its
- center widget.
+ The \c MainWindow creates a \c TabletCanvas and sets it as its
+ center widget.
\snippet widgets/tablet/mainwindow.h 0
@@ -115,10 +115,10 @@
\snippet widgets/tablet/mainwindow.cpp 2
- The \c TabletCanvas class supports two ways by which the alpha
+ The \c TabletCanvas class supports two ways by which the alpha
channel of the drawing color can be changed: tablet pressure and
tilt. We have one action for each and an action if the alpha
- channel should not be changed.
+ channel should not be changed.
Here is the implementation of \c lineWidthActionTriggered():
@@ -155,12 +155,12 @@
\snippet widgets/tablet/mainwindow.cpp 7
- We show a message box with a short description of the example.
+ We show a message box with a short description of the example.
\c createActions() creates all actions and action groups of
the example. We look at the creation of one action group and its
actions. See the \l{Application Example}{application example} if
- you want a high-level introduction to QActions.
+ you want a high-level introduction to QActions.
Here is the implementation of \c createActions:
@@ -189,7 +189,7 @@
\section1 TabletCanvas Class Definition
The \c TabletCanvas class provides a surface on which the
- user can draw with a tablet.
+ user can draw with a tablet.
\snippet widgets/tablet/tabletcanvas.h 0
@@ -198,7 +198,7 @@
these; their values decide if it is the tablet pressure or tilt
that will alter them. We keep a private variable for each, the \c
alphaChannelType, \c colorSturationType, and \c penWidthType,
- which we provide access functions for.
+ which we provide access functions for.
We draw on a QPixmap with \c myPen and \c myBrush using \c
myColor. The \c saveImage() and \c loadImage() saves and loads
@@ -291,7 +291,7 @@
-60, 127 equals 0, and 255 equals 60 degrees. The angle measured
is between the device and the perpendicular of the tablet (see
QTabletEvent for an illustration).
-
+
\snippet widgets/tablet/tabletcanvas.cpp 8
The alpha channel of QColor is given as a number between 0
@@ -301,8 +301,8 @@
taking the absolute value we get the smallest alpha values (i.e.,
the color is most transparent) when the pen is perpendicular to
the tablet. We select the largest of the vertical and horizontal
- tilt value.
-
+ tilt value.
+
\snippet widgets/tablet/tabletcanvas.cpp 9
The colorsaturation is given as a number between 0 and 255. It is
@@ -317,7 +317,7 @@
the angle between the device and the perpendicular of the tablet.
\snippet widgets/tablet/tabletcanvas.cpp 11
-
+
We finally check whether the pointer is the stylus or the eraser.
If it is the eraser, we set the color to the background color of
the pixmap an let the pressure decide the pen width, else we set
@@ -327,7 +327,7 @@
\section1 TabletApplication Class Definition
We inherit QApplication in this class because we want to
- reimplement the \l{QApplication::}{event()} function.
+ reimplement the \l{QApplication::}{event()} function.
\snippet widgets/tablet/tabletapplication.h 0
@@ -336,7 +336,7 @@
and TabletLeaveProximity events are not sendt to the QApplication
object, while other tablet events are sendt to the QWidget's
\c event(), which sends them on to \l{QWidget::}{tabletEvent()}.
- Since we want to handle these events we have implemented \c
+ Since we want to handle these events we have implemented \c
TabletApplication.
@@ -352,7 +352,7 @@
events is to do work that is dependent on what kind of device is
used on the tablet. This way, you don't have to do this work
when other events are generated, which is more frequently than the
- leave and enter proximity events. We call \c setTabletDevice() in
+ leave and enter proximity events. We call \c setTabletDevice() in
\c TabletCanvas.
\section1 The \c main() function
diff --git a/examples/widgets/doc/src/tetrix.qdoc b/examples/widgets/doc/src/tetrix.qdoc
index 599323deb0..7527d6758f 100644
--- a/examples/widgets/doc/src/tetrix.qdoc
+++ b/examples/widgets/doc/src/tetrix.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\example widgets/tetrix
\title Tetrix Example
\ingroup examples-widgets
diff --git a/examples/widgets/doc/src/undo.qdoc b/examples/widgets/doc/src/undo.qdoc
index 07f586b8f3..fc89751e90 100644
--- a/examples/widgets/doc/src/undo.qdoc
+++ b/examples/widgets/doc/src/undo.qdoc
@@ -35,7 +35,7 @@
\image undodemo.png
Qt's undo framework is an implementation of the Command
- pattern, which provides advanced undo/redo functionality.
+ pattern, which provides advanced undo/redo functionality.
To show the abilities of the framework, we have implemented a
small diagram application in which the diagram items are geometric
diff --git a/examples/widgets/doc/src/undoframework.qdoc b/examples/widgets/doc/src/undoframework.qdoc
index ba146e65b9..1710ab9132 100644
--- a/examples/widgets/doc/src/undoframework.qdoc
+++ b/examples/widgets/doc/src/undoframework.qdoc
@@ -61,9 +61,9 @@
The example consists of the following classes:
- \list
+ \list
\li \c MainWindow is the main window and arranges the
- example's widgets. It creates the commands based
+ example's widgets. It creates the commands based
on user input and keeps them on the command stack.
\li \c AddCommand adds an item to the scene.
\li \c DeleteCommand deletes an item from the scene.
@@ -85,23 +85,23 @@
\l{QUndoCommand}s and pushes and pops them from the stack when it
receives the \c triggered() signal from \c undoAction and \c
redoAction.
-
+
\section1 MainWindow Class Implementation
- We will start with a look at the constructor:
+ We will start with a look at the constructor:
\snippet tools/undoframework/mainwindow.cpp 0
- In the constructor, we set up the DiagramScene and QGraphicsView.
+ In the constructor, we set up the DiagramScene and QGraphicsView.
- Here is the \c createUndoView() function:
+ Here is the \c createUndoView() function:
\snippet tools/undoframework/mainwindow.cpp 1
The QUndoView is a widget that display the text, which is set with
the \l{QUndoCommand::}{setText()} function, for each QUndoCommand
in the undo stack in a list.
-
+
Here is the \c createActions() function:
\snippet tools/undoframework/mainwindow.cpp 2
@@ -130,7 +130,7 @@
We have to use the QMenu \c aboutToShow() and \c aboutToHide()
signals since we only want \c deleteAction to be enabled when we
- have selected an item.
+ have selected an item.
Here is the \c itemMoved() slot:
@@ -155,9 +155,9 @@
\snippet tools/undoframework/mainwindow.cpp 12
We implement \c itemMenuAboutToShow() and \c itemMenuAboutToHide()
- to get a dynamic item menu. These slots are connected to the
+ to get a dynamic item menu. These slots are connected to the
\l{QMenu::}{aboutToShow()} and \l{QMenu::}{aboutToHide()} signals.
- We need this to disable or enable the \c deleteAction.
+ We need this to disable or enable the \c deleteAction.
Here is the \c addBox() slot:
@@ -171,21 +171,21 @@
\snippet tools/undoframework/mainwindow.cpp 14
The \c addTriangle() function creates an AddCommand and pushes it
- on the undo stack.
+ on the undo stack.
Here is the implementation of \c about():
\snippet tools/undoframework/mainwindow.cpp 15
-
+
The about slot is triggered by the \c aboutAction and displays an
about box for the example.
\section1 AddCommand Class Definition
-
+
\snippet tools/undoframework/commands.h 2
The \c AddCommand class adds DiagramItem graphics items to the
- DiagramScene.
+ DiagramScene.
\section1 AddCommand Class Implementation
@@ -208,20 +208,20 @@
constructor.
\section1 DeleteCommand Class Definition
-
+
\snippet tools/undoframework/commands.h 1
The DeleteCommand class implements the functionality to remove an
item from the scene.
-
+
\section1 DeleteCommand Class Implementation
\snippet tools/undoframework/commands.cpp 4
We know that there must be one selected item as it is not possible
to create a DeleteCommand unless the item to be deleted is
- selected and that only one item can be selected at any time.
- The item must be unselected if it is inserted back into the
+ selected and that only one item can be selected at any time.
+ The item must be unselected if it is inserted back into the
scene.
\snippet tools/undoframework/commands.cpp 5
@@ -242,7 +242,7 @@
\section1 MoveCommand Class Implementation
-
+
The constructor of MoveCommand looks like this:
\snippet tools/undoframework/commands.cpp 0
@@ -252,12 +252,12 @@
\snippet tools/undoframework/commands.cpp 2
- We simply set the items old position and update the scene.
+ We simply set the items old position and update the scene.
\snippet tools/undoframework/commands.cpp 3
We set the item to its new position.
-
+
\snippet tools/undoframework/commands.cpp 1
Whenever a MoveCommand is created, this function is called to
@@ -268,7 +268,7 @@
We first check whether it is the same item that has been moved
twice, in which case we merge the commands. We update the position
of the item so that it will take the last position in the move
- sequence when undone.
+ sequence when undone.
\section1 DiagramScene Class Definition
@@ -281,7 +281,7 @@
as it only deals with graphics framework issues.
\section1 The \c main() Function
-
+
The \c main() function of the program looks like this:
\snippet tools/undoframework/main.cpp 0
diff --git a/examples/widgets/draganddrop/draggableicons/dragwidget.cpp b/examples/widgets/draganddrop/draggableicons/dragwidget.cpp
index b13d571a26..5d01ee7619 100644
--- a/examples/widgets/draganddrop/draggableicons/dragwidget.cpp
+++ b/examples/widgets/draganddrop/draggableicons/dragwidget.cpp
@@ -103,7 +103,7 @@ void DragWidget::dropEvent(QDropEvent *event)
if (event->mimeData()->hasFormat("application/x-dnditemdata")) {
QByteArray itemData = event->mimeData()->data("application/x-dnditemdata");
QDataStream dataStream(&itemData, QIODevice::ReadOnly);
-
+
QPixmap pixmap;
QPoint offset;
dataStream >> pixmap >> offset;
@@ -143,7 +143,7 @@ void DragWidget::mousePressEvent(QMouseEvent *event)
QMimeData *mimeData = new QMimeData;
mimeData->setData("application/x-dnditemdata", itemData);
//! [2]
-
+
//! [3]
QDrag *drag = new QDrag(this);
drag->setMimeData(mimeData);
diff --git a/examples/widgets/draganddrop/dropsite/droparea.cpp b/examples/widgets/draganddrop/dropsite/droparea.cpp
index 8662ec80b3..fcabeb3b62 100644
--- a/examples/widgets/draganddrop/dropsite/droparea.cpp
+++ b/examples/widgets/draganddrop/dropsite/droparea.cpp
@@ -87,7 +87,7 @@ void DropArea::dropEvent(QDropEvent *event)
setText(mimeData->html());
setTextFormat(Qt::RichText);
} else if (mimeData->hasText()) {
- setText(mimeData->text());
+ setText(mimeData->text());
setTextFormat(Qt::PlainText);
} else if (mimeData->hasUrls()) {
QList<QUrl> urlList = mimeData->urls();
@@ -102,7 +102,7 @@ void DropArea::dropEvent(QDropEvent *event)
}
//! [dropEvent() function part2]
-//! [dropEvent() function part3]
+//! [dropEvent() function part3]
setBackgroundRole(QPalette::Dark);
event->acceptProposedAction();
}
diff --git a/examples/widgets/draganddrop/dropsite/dropsitewindow.cpp b/examples/widgets/draganddrop/dropsite/dropsitewindow.cpp
index 9b7f0c3de9..d69f4ee2a8 100644
--- a/examples/widgets/draganddrop/dropsite/dropsitewindow.cpp
+++ b/examples/widgets/draganddrop/dropsite/dropsitewindow.cpp
@@ -103,7 +103,7 @@ void DropSiteWindow::updateFormatsTable(const QMimeData *mimeData)
return;
//! [updateFormatsTable() part1]
-//! [updateFormatsTable() part2]
+//! [updateFormatsTable() part2]
foreach (QString format, mimeData->formats()) {
QTableWidgetItem *formatItem = new QTableWidgetItem(format);
formatItem->setFlags(Qt::ItemIsEnabled);
@@ -129,7 +129,7 @@ void DropSiteWindow::updateFormatsTable(const QMimeData *mimeData)
text.append(hex + " ");
}
}
-//! [updateFormatsTable() part3]
+//! [updateFormatsTable() part3]
//! [updateFormatsTable() part4]
int row = formatsTable->rowCount();
@@ -137,7 +137,7 @@ void DropSiteWindow::updateFormatsTable(const QMimeData *mimeData)
formatsTable->setItem(row, 0, new QTableWidgetItem(format));
formatsTable->setItem(row, 1, new QTableWidgetItem(text));
}
-
+
formatsTable->resizeColumnToContents(0);
}
-//! [updateFormatsTable() part4]
+//! [updateFormatsTable() part4]
diff --git a/examples/widgets/graphicsview/boxes/scene.cpp b/examples/widgets/graphicsview/boxes/scene.cpp
index c907070db8..11e9f4ea5a 100644
--- a/examples/widgets/graphicsview/boxes/scene.cpp
+++ b/examples/widgets/graphicsview/boxes/scene.cpp
@@ -567,7 +567,7 @@ void Scene::initGL()
m_environmentProgram->link();
const int NOISE_SIZE = 128; // for a different size, B and BM in fbm.c must also be changed
- m_noise = new GLTexture3D(NOISE_SIZE, NOISE_SIZE, NOISE_SIZE);
+ m_noise = new GLTexture3D(NOISE_SIZE, NOISE_SIZE, NOISE_SIZE);
QRgb *data = new QRgb[NOISE_SIZE * NOISE_SIZE * NOISE_SIZE];
memset(data, 0, NOISE_SIZE * NOISE_SIZE * NOISE_SIZE * sizeof(QRgb));
QRgb *p = data;
diff --git a/examples/widgets/graphicsview/chip/main.cpp b/examples/widgets/graphicsview/chip/main.cpp
index a0c1b919d1..c0f271a83c 100644
--- a/examples/widgets/graphicsview/chip/main.cpp
+++ b/examples/widgets/graphicsview/chip/main.cpp
@@ -51,7 +51,7 @@ int main(int argc, char *argv[])
app.setAttribute(Qt::AA_DontCreateNativeWidgetSiblings);
MainWindow window;
- window.show();
+ window.show();
return app.exec();
}
diff --git a/examples/widgets/graphicsview/chip/mainwindow.cpp b/examples/widgets/graphicsview/chip/mainwindow.cpp
index 0925e9c9cb..510dd2e5c9 100644
--- a/examples/widgets/graphicsview/chip/mainwindow.cpp
+++ b/examples/widgets/graphicsview/chip/mainwindow.cpp
@@ -53,7 +53,7 @@ MainWindow::MainWindow(QWidget *parent)
h1Splitter = new QSplitter;
h2Splitter = new QSplitter;
-
+
QSplitter *vSplitter = new QSplitter;
vSplitter->setOrientation(Qt::Vertical);
vSplitter->addWidget(h1Splitter);
diff --git a/examples/widgets/graphicsview/chip/mainwindow.h b/examples/widgets/graphicsview/chip/mainwindow.h
index 876a9f7d77..d4a9dfda85 100644
--- a/examples/widgets/graphicsview/chip/mainwindow.h
+++ b/examples/widgets/graphicsview/chip/mainwindow.h
@@ -54,11 +54,11 @@ class MainWindow : public QWidget
Q_OBJECT
public:
MainWindow(QWidget *parent = 0);
-
+
private:
void setupMatrix();
void populateScene();
-
+
QGraphicsScene *scene;
QSplitter *h1Splitter;
QSplitter *h2Splitter;
diff --git a/examples/widgets/graphicsview/chip/view.cpp b/examples/widgets/graphicsview/chip/view.cpp
index 4b5b608163..a439c837de 100644
--- a/examples/widgets/graphicsview/chip/view.cpp
+++ b/examples/widgets/graphicsview/chip/view.cpp
@@ -252,7 +252,7 @@ void View::toggleAntialiasing()
void View::print()
{
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
QPrinter printer;
QPrintDialog dialog(&printer, this);
if (dialog.exec() == QDialog::Accepted) {
diff --git a/examples/widgets/graphicsview/collidingmice/mouse.cpp b/examples/widgets/graphicsview/collidingmice/mouse.cpp
index e44d5549b3..d22e935828 100644
--- a/examples/widgets/graphicsview/collidingmice/mouse.cpp
+++ b/examples/widgets/graphicsview/collidingmice/mouse.cpp
@@ -159,7 +159,7 @@ void Mouse::advance(int step)
foreach (QGraphicsItem *item, dangerMice) {
if (item == this)
continue;
-
+
QLineF lineToMouse(QPointF(0, 0), mapFromItem(item, 0, 0));
qreal angleToMouse = ::acos(lineToMouse.dx() / lineToMouse.length());
if (lineToMouse.dy() < 0)
diff --git a/examples/widgets/graphicsview/dragdroprobot/robot.cpp b/examples/widgets/graphicsview/dragdroprobot/robot.cpp
index 90ae4e9e22..4bfcac4800 100644
--- a/examples/widgets/graphicsview/dragdroprobot/robot.cpp
+++ b/examples/widgets/graphicsview/dragdroprobot/robot.cpp
@@ -162,7 +162,7 @@ void RobotTorso::paint(QPainter *painter,
{
Q_UNUSED(option);
Q_UNUSED(widget);
-
+
painter->setBrush(dragOver ? color.light(130) : color);
painter->drawRoundedRect(-20, -20, 40, 60, 25, 25, Qt::RelativeSize);
painter->drawEllipse(-25, -20, 20, 20);
diff --git a/examples/widgets/graphicsview/dragdroprobot/robot.h b/examples/widgets/graphicsview/dragdroprobot/robot.h
index bb61bfe54b..a0c842e72c 100644
--- a/examples/widgets/graphicsview/dragdroprobot/robot.h
+++ b/examples/widgets/graphicsview/dragdroprobot/robot.h
@@ -109,7 +109,7 @@ class Robot : public RobotPart
{
public:
Robot(QGraphicsItem *parent = 0);
-
+
QRectF boundingRect() const;
void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0);
};
diff --git a/examples/widgets/graphicsview/elasticnodes/edge.cpp b/examples/widgets/graphicsview/elasticnodes/edge.cpp
index 8561983db9..1923550fd3 100644
--- a/examples/widgets/graphicsview/elasticnodes/edge.cpp
+++ b/examples/widgets/graphicsview/elasticnodes/edge.cpp
@@ -136,7 +136,7 @@ void Edge::paint(QPainter *painter, const QStyleOptionGraphicsItem *, QWidget *)
QPointF sourceArrowP1 = sourcePoint + QPointF(sin(angle + Pi / 3) * arrowSize,
cos(angle + Pi / 3) * arrowSize);
QPointF sourceArrowP2 = sourcePoint + QPointF(sin(angle + Pi - Pi / 3) * arrowSize,
- cos(angle + Pi - Pi / 3) * arrowSize);
+ cos(angle + Pi - Pi / 3) * arrowSize);
QPointF destArrowP1 = destPoint + QPointF(sin(angle - Pi / 3) * arrowSize,
cos(angle - Pi / 3) * arrowSize);
QPointF destArrowP2 = destPoint + QPointF(sin(angle - Pi + Pi / 3) * arrowSize,
diff --git a/examples/widgets/graphicsview/elasticnodes/edge.h b/examples/widgets/graphicsview/elasticnodes/edge.h
index 5800ca0d32..6ab71e3478 100644
--- a/examples/widgets/graphicsview/elasticnodes/edge.h
+++ b/examples/widgets/graphicsview/elasticnodes/edge.h
@@ -58,11 +58,11 @@ public:
enum { Type = UserType + 2 };
int type() const { return Type; }
-
+
protected:
QRectF boundingRect() const;
void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget);
-
+
private:
Node *source, *dest;
diff --git a/examples/widgets/graphicsview/elasticnodes/node.h b/examples/widgets/graphicsview/elasticnodes/node.h
index 703b99801a..813dbb1c54 100644
--- a/examples/widgets/graphicsview/elasticnodes/node.h
+++ b/examples/widgets/graphicsview/elasticnodes/node.h
@@ -74,7 +74,7 @@ protected:
void mousePressEvent(QGraphicsSceneMouseEvent *event);
void mouseReleaseEvent(QGraphicsSceneMouseEvent *event);
-
+
private:
QList<Edge *> edgeList;
QPointF newPos;
diff --git a/examples/widgets/graphicsview/embeddeddialogs/customproxy.cpp b/examples/widgets/graphicsview/embeddeddialogs/customproxy.cpp
index 5e7577f28b..fa108a21b3 100644
--- a/examples/widgets/graphicsview/embeddeddialogs/customproxy.cpp
+++ b/examples/widgets/graphicsview/embeddeddialogs/customproxy.cpp
@@ -64,7 +64,7 @@ void CustomProxy::paintWindowFrame(QPainter *painter, const QStyleOptionGraphics
QWidget *widget)
{
const QColor color(0, 0, 0, 64);
-
+
QRectF r = windowFrameRect();
QRectF right(r.right(), r.top() + 10, 10, r.height() - 10);
QRectF bottom(r.left() + 10, r.bottom(), r.width(), 10);
@@ -159,7 +159,7 @@ void CustomProxy::zoomIn()
{
if (timeLine->direction() != QTimeLine::Forward)
timeLine->setDirection(QTimeLine::Forward);
- if (timeLine->state() == QTimeLine::NotRunning)
+ if (timeLine->state() == QTimeLine::NotRunning)
timeLine->start();
}
@@ -167,6 +167,6 @@ void CustomProxy::zoomOut()
{
if (timeLine->direction() != QTimeLine::Backward)
timeLine->setDirection(QTimeLine::Backward);
- if (timeLine->state() == QTimeLine::NotRunning)
+ if (timeLine->state() == QTimeLine::NotRunning)
timeLine->start();
}
diff --git a/examples/widgets/graphicsview/embeddeddialogs/customproxy.h b/examples/widgets/graphicsview/embeddeddialogs/customproxy.h
index 3f7b540d2b..7257a90b12 100644
--- a/examples/widgets/graphicsview/embeddeddialogs/customproxy.h
+++ b/examples/widgets/graphicsview/embeddeddialogs/customproxy.h
@@ -54,7 +54,7 @@ public:
QRectF boundingRect() const;
void paintWindowFrame(QPainter *painter, const QStyleOptionGraphicsItem *option,
- QWidget *widget);
+ QWidget *widget);
protected:
void hoverEnterEvent(QGraphicsSceneHoverEvent *event);
diff --git a/examples/widgets/itemviews/addressbook/adddialog.cpp b/examples/widgets/itemviews/addressbook/adddialog.cpp
index f68cacc2e5..bb31fd60c4 100644
--- a/examples/widgets/itemviews/addressbook/adddialog.cpp
+++ b/examples/widgets/itemviews/addressbook/adddialog.cpp
@@ -50,31 +50,31 @@ AddDialog::AddDialog(QWidget *parent)
addressLabel = new QLabel("Address");
okButton = new QPushButton("OK");
cancelButton = new QPushButton("Cancel");
-
+
nameText = new QLineEdit;
addressText = new QTextEdit;
-
+
QGridLayout *gLayout = new QGridLayout;
gLayout->setColumnStretch(1, 2);
gLayout->addWidget(nameLabel, 0, 0);
gLayout->addWidget(nameText, 0, 1);
-
+
gLayout->addWidget(addressLabel, 1, 0, Qt::AlignLeft|Qt::AlignTop);
gLayout->addWidget(addressText, 1, 1, Qt::AlignLeft);
-
+
QHBoxLayout *buttonLayout = new QHBoxLayout;
buttonLayout->addWidget(okButton);
buttonLayout->addWidget(cancelButton);
-
+
gLayout->addLayout(buttonLayout, 2, 1, Qt::AlignRight);
-
+
QVBoxLayout *mainLayout = new QVBoxLayout;
mainLayout->addLayout(gLayout);
setLayout(mainLayout);
-
+
connect(okButton, SIGNAL(clicked()), this, SLOT(accept()));
connect(cancelButton, SIGNAL(clicked()), this, SLOT(reject()));
-
+
setWindowTitle(tr("Add a Contact"));
}
//! [0]
diff --git a/examples/widgets/itemviews/addressbook/adddialog.h b/examples/widgets/itemviews/addressbook/adddialog.h
index 8412664287..78f56ef744 100644
--- a/examples/widgets/itemviews/addressbook/adddialog.h
+++ b/examples/widgets/itemviews/addressbook/adddialog.h
@@ -54,7 +54,7 @@ QT_END_NAMESPACE
class AddDialog : public QDialog
{
Q_OBJECT
-
+
public:
AddDialog(QWidget *parent = 0);
QLineEdit *nameText;
diff --git a/examples/widgets/itemviews/addressbook/addresswidget.cpp b/examples/widgets/itemviews/addressbook/addresswidget.cpp
index 2c05e0e059..cd6f4a5534 100644
--- a/examples/widgets/itemviews/addressbook/addresswidget.cpp
+++ b/examples/widgets/itemviews/addressbook/addresswidget.cpp
@@ -52,7 +52,7 @@ AddressWidget::AddressWidget(QWidget *parent)
connect(newAddressTab, SIGNAL(sendDetails(QString, QString)),
this, SLOT(addEntry(QString, QString)));
- addTab(newAddressTab, "Address Book");
+ addTab(newAddressTab, "Address Book");
setupTabs();
}
@@ -60,13 +60,13 @@ AddressWidget::AddressWidget(QWidget *parent)
//! [2]
void AddressWidget::addEntry()
-{
+{
AddDialog aDialog;
if (aDialog.exec()) {
QString name = aDialog.nameText->text();
QString address = aDialog.addressText->toPlainText();
-
+
addEntry(name, address);
}
}
@@ -74,7 +74,7 @@ void AddressWidget::addEntry()
//! [3]
void AddressWidget::addEntry(QString name, QString address)
-{
+{
QList<QPair<QString, QString> >list = table->getList();
QPair<QString, QString> pair(name, address);
@@ -110,14 +110,14 @@ void AddressWidget::editEntry()
QModelIndex nameIndex = table->index(row, 0, QModelIndex());
QVariant varName = table->data(nameIndex, Qt::DisplayRole);
name = varName.toString();
-
+
QModelIndex addressIndex = table->index(row, 1, QModelIndex());
QVariant varAddr = table->data(addressIndex, Qt::DisplayRole);
address = varAddr.toString();
}
//! [4a]
-
-//! [4b]
+
+//! [4b]
AddDialog aDialog;
aDialog.setWindowTitle(tr("Edit a Contact"));
@@ -141,7 +141,7 @@ void AddressWidget::removeEntry()
QTableView *temp = static_cast<QTableView*>(currentWidget());
QSortFilterProxyModel *proxy = static_cast<QSortFilterProxyModel*>(temp->model());
QItemSelectionModel *selectionModel = temp->selectionModel();
-
+
QModelIndexList indexes = selectionModel->selectedRows();
foreach (QModelIndex index, indexes) {
@@ -163,7 +163,7 @@ void AddressWidget::setupTabs()
for (int i = 0; i < groups.size(); ++i) {
QString str = groups.at(i);
-
+
proxyModel = new QSortFilterProxyModel(this);
proxyModel->setSourceModel(table);
@@ -181,7 +181,7 @@ void AddressWidget::setupTabs()
proxyModel->setFilterRegExp(QRegExp(newStr, Qt::CaseInsensitive));
proxyModel->setFilterKeyColumn(0);
proxyModel->sort(0, Qt::AscendingOrder);
-
+
connect(tableView->selectionModel(),
SIGNAL(selectionChanged(QItemSelection,QItemSelection)),
this, SIGNAL(selectionChanged(QItemSelection)));
diff --git a/examples/widgets/itemviews/addressbook/mainwindow.cpp b/examples/widgets/itemviews/addressbook/mainwindow.cpp
index 8f1ea81763..8e66e9cb49 100644
--- a/examples/widgets/itemviews/addressbook/mainwindow.cpp
+++ b/examples/widgets/itemviews/addressbook/mainwindow.cpp
@@ -58,7 +58,7 @@ MainWindow::MainWindow()
void MainWindow::createMenus()
{
fileMenu = menuBar()->addMenu(tr("&File"));
-
+
openAct = new QAction(tr("&Open..."), this);
fileMenu->addAction(openAct);
connect(openAct, SIGNAL(triggered()), this, SLOT(openFile()));
@@ -79,7 +79,7 @@ void MainWindow::createMenus()
addAct = new QAction(tr("&Add Entry..."), this);
toolMenu->addAction(addAct);
connect(addAct, SIGNAL(triggered()), addressWidget, SLOT(addEntry()));
-
+
//! [1b]
editAct = new QAction(tr("&Edit Entry..."), this);
editAct->setEnabled(false);
@@ -120,7 +120,7 @@ void MainWindow::saveFile()
void MainWindow::updateActions(const QItemSelection &selection)
{
QModelIndexList indexes = selection.indexes();
-
+
if (!indexes.isEmpty()) {
removeAct->setEnabled(true);
editAct->setEnabled(true);
diff --git a/examples/widgets/itemviews/addressbook/newaddresstab.cpp b/examples/widgets/itemviews/addressbook/newaddresstab.cpp
index b443d9cf96..a8e770cab8 100644
--- a/examples/widgets/itemviews/addressbook/newaddresstab.cpp
+++ b/examples/widgets/itemviews/addressbook/newaddresstab.cpp
@@ -50,15 +50,15 @@ NewAddressTab::NewAddressTab(QWidget *parent)
descriptionLabel = new QLabel(tr("There are currently no contacts in your address book. "
"\nClick Add to add new contacts."));
-
+
addButton = new QPushButton(tr("Add"));
-
+
connect(addButton, SIGNAL(clicked()), this, SLOT(addEntry()));
-
+
mainLayout = new QVBoxLayout;
mainLayout->addWidget(descriptionLabel);
mainLayout->addWidget(addButton, 0, Qt::AlignCenter);
-
+
setLayout(mainLayout);
}
//! [0]
@@ -67,11 +67,11 @@ NewAddressTab::NewAddressTab(QWidget *parent)
void NewAddressTab::addEntry()
{
AddDialog aDialog;
-
+
if (aDialog.exec()) {
QString name = aDialog.nameText->text();
QString address = aDialog.addressText->toPlainText();
-
+
emit sendDetails(name, address);
}
}
diff --git a/examples/widgets/itemviews/addressbook/newaddresstab.h b/examples/widgets/itemviews/addressbook/newaddresstab.h
index 51e75aa366..2db7302e75 100644
--- a/examples/widgets/itemviews/addressbook/newaddresstab.h
+++ b/examples/widgets/itemviews/addressbook/newaddresstab.h
@@ -53,7 +53,7 @@ QT_END_NAMESPACE
class NewAddressTab : public QWidget
{
Q_OBJECT
-
+
public:
NewAddressTab(QWidget *parent = 0);
@@ -67,7 +67,7 @@ private:
QLabel *descriptionLabel;
QPushButton *addButton;
QVBoxLayout *mainLayout;
-
+
};
//! [0]
diff --git a/examples/widgets/itemviews/addressbook/tablemodel.h b/examples/widgets/itemviews/addressbook/tablemodel.h
index 0ef54fae6a..e282defa1b 100644
--- a/examples/widgets/itemviews/addressbook/tablemodel.h
+++ b/examples/widgets/itemviews/addressbook/tablemodel.h
@@ -49,7 +49,7 @@
class TableModel : public QAbstractTableModel
{
Q_OBJECT
-
+
public:
TableModel(QObject *parent = 0);
TableModel(QList<QPair<QString, QString> > listofPairs, QObject *parent = 0);
diff --git a/examples/widgets/itemviews/combowidgetmapper/window.cpp b/examples/widgets/itemviews/combowidgetmapper/window.cpp
index 39ba428ced..3dfb2834a8 100644
--- a/examples/widgets/itemviews/combowidgetmapper/window.cpp
+++ b/examples/widgets/itemviews/combowidgetmapper/window.cpp
@@ -101,7 +101,7 @@ void Window::setupModel()
QStringList items;
items << tr("Home") << tr("Work") << tr("Other");
typeModel = new QStringListModel(items, this);
-
+
model = new QStandardItemModel(5, 3, this);
QStringList names;
names << "Alice" << "Bob" << "Carol" << "Donald" << "Emma";
@@ -115,7 +115,7 @@ void Window::setupModel()
QStringList types;
types << "0" << "1" << "2" << "0" << "2";
-
+
for (int row = 0; row < 5; ++row) {
QStandardItem *item = new QStandardItem(names[row]);
model->setItem(row, 0, item);
diff --git a/examples/widgets/itemviews/fetchmore/filelistmodel.cpp b/examples/widgets/itemviews/fetchmore/filelistmodel.cpp
index 5e7ba2c754..6532189b06 100644
--- a/examples/widgets/itemviews/fetchmore/filelistmodel.cpp
+++ b/examples/widgets/itemviews/fetchmore/filelistmodel.cpp
@@ -60,10 +60,10 @@ QVariant FileListModel::data(const QModelIndex &index, int role) const
{
if (!index.isValid())
return QVariant();
-
+
if (index.row() >= fileList.size() || index.row() < 0)
return QVariant();
-
+
if (role == Qt::DisplayRole) {
return fileList.at(index.row());
} else if (role == Qt::BackgroundRole) {
@@ -94,7 +94,7 @@ void FileListModel::fetchMore(const QModelIndex & /* index */)
int itemsToFetch = qMin(100, remainder);
beginInsertRows(QModelIndex(), fileCount, fileCount+itemsToFetch-1);
-
+
fileCount += itemsToFetch;
endInsertRows();
diff --git a/examples/widgets/itemviews/fetchmore/window.cpp b/examples/widgets/itemviews/fetchmore/window.cpp
index ed2d2a2260..f35593923d 100644
--- a/examples/widgets/itemviews/fetchmore/window.cpp
+++ b/examples/widgets/itemviews/fetchmore/window.cpp
@@ -65,7 +65,7 @@ Window::Window(QWidget *parent)
logViewer, SLOT(clear()));
connect(model, SIGNAL(numberPopulated(int)),
this, SLOT(updateLog(int)));
-
+
QGridLayout *layout = new QGridLayout;
layout->addWidget(label, 0, 0);
layout->addWidget(lineEdit, 0, 1);
diff --git a/examples/widgets/itemviews/pixelator/mainwindow.cpp b/examples/widgets/itemviews/pixelator/mainwindow.cpp
index dec9ee4084..1f6a403efc 100644
--- a/examples/widgets/itemviews/pixelator/mainwindow.cpp
+++ b/examples/widgets/itemviews/pixelator/mainwindow.cpp
@@ -154,7 +154,7 @@ void MainWindow::openImage(const QString &fileName)
void MainWindow::printImage()
{
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
if (model->rowCount(QModelIndex())*model->columnCount(QModelIndex()) > 90000) {
QMessageBox::StandardButton answer;
answer = QMessageBox::question(this, tr("Large Image Size"),
@@ -226,7 +226,7 @@ void MainWindow::printImage()
tr("The printing process was canceled."), QMessageBox::Cancel);
}
#else
- QMessageBox::information(this, tr("Printing canceled"),
+ QMessageBox::information(this, tr("Printing canceled"),
tr("Printing is not supported on this Qt build"), QMessageBox::Cancel);
#endif
}
diff --git a/examples/widgets/itemviews/simplewidgetmapper/window.cpp b/examples/widgets/itemviews/simplewidgetmapper/window.cpp
index 7699bcc929..0e3314601a 100644
--- a/examples/widgets/itemviews/simplewidgetmapper/window.cpp
+++ b/examples/widgets/itemviews/simplewidgetmapper/window.cpp
@@ -109,7 +109,7 @@ void Window::setupModel()
QStringList ages;
ages << "20" << "31" << "32" << "19" << "26";
-
+
for (int row = 0; row < 5; ++row) {
QStandardItem *item = new QStandardItem(names[row]);
model->setItem(row, 0, item);
diff --git a/examples/widgets/itemviews/spreadsheet/spreadsheet.cpp b/examples/widgets/itemviews/spreadsheet/spreadsheet.cpp
index 39dd35e342..59d29f0e61 100644
--- a/examples/widgets/itemviews/spreadsheet/spreadsheet.cpp
+++ b/examples/widgets/itemviews/spreadsheet/spreadsheet.cpp
@@ -627,7 +627,7 @@ QString encode_pos(int row, int col)
void SpreadSheet::print()
{
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
QPrinter printer(QPrinter::ScreenResolution);
QPrintPreviewDialog dlg(&printer);
PrintView view;
diff --git a/examples/widgets/itemviews/spreadsheet/spreadsheet.h b/examples/widgets/itemviews/spreadsheet/spreadsheet.h
index c81af6666a..279146552a 100644
--- a/examples/widgets/itemviews/spreadsheet/spreadsheet.h
+++ b/examples/widgets/itemviews/spreadsheet/spreadsheet.h
@@ -77,7 +77,7 @@ public slots:
void actionSubtract();
void actionAdd();
void actionMultiply();
- void actionDivide();
+ void actionDivide();
protected:
void setupContextMenu();
diff --git a/examples/widgets/painting/deform/pathdeform.cpp b/examples/widgets/painting/deform/pathdeform.cpp
index 3c0624ac76..9f9a88700c 100644
--- a/examples/widgets/painting/deform/pathdeform.cpp
+++ b/examples/widgets/painting/deform/pathdeform.cpp
@@ -289,7 +289,7 @@ void PathDeformWidget::setStyle( QStyle * style )
return;
m_controls->setStyle(style);
-
+
QList<QWidget *> widgets = m_controls->findChildren<QWidget *>();
foreach (QWidget *w, widgets)
w->setStyle(style);
@@ -481,7 +481,7 @@ void PathDeformRenderer::mousePressEvent(QMouseEvent *e)
m_offset = m_pos - e->pos();
m_mousePress = e->pos();
-
+
// If we're not running in small screen mode, always assume we're dragging
m_mouseDrag = !m_smallScreen;
diff --git a/examples/widgets/painting/fontsampler/mainwindow.cpp b/examples/widgets/painting/fontsampler/mainwindow.cpp
index 645a2b1a9a..516ba5e2bc 100644
--- a/examples/widgets/painting/fontsampler/mainwindow.cpp
+++ b/examples/widgets/painting/fontsampler/mainwindow.cpp
@@ -241,7 +241,7 @@ QMap<QString, StyleItems> MainWindow::currentPageMap()
return pageMap;
}
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
void MainWindow::on_printAction_triggered()
{
pageMap = currentPageMap();
diff --git a/examples/widgets/painting/fontsampler/mainwindow.h b/examples/widgets/painting/fontsampler/mainwindow.h
index f9e06c8b89..f4ad448480 100644
--- a/examples/widgets/painting/fontsampler/mainwindow.h
+++ b/examples/widgets/painting/fontsampler/mainwindow.h
@@ -62,12 +62,12 @@ public:
public slots:
void on_clearAction_triggered();
void on_markAction_triggered();
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
void on_printAction_triggered();
void on_printPreviewAction_triggered();
#endif
void on_unmarkAction_triggered();
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
void printDocument(QPrinter *printer);
void printPage(int index, QPainter *painter, QPrinter *printer);
#endif
diff --git a/examples/widgets/painting/gradients/gradients.cpp b/examples/widgets/painting/gradients/gradients.cpp
index f3da5f3de5..ffca9f5560 100644
--- a/examples/widgets/painting/gradients/gradients.cpp
+++ b/examples/widgets/painting/gradients/gradients.cpp
@@ -362,7 +362,7 @@ GradientWidget::GradientWidget(QWidget *parent)
connect(showSourceButton, SIGNAL(clicked()), m_renderer, SLOT(showSource()));
#ifdef QT_OPENGL_SUPPORT
connect(enableOpenGLButton, SIGNAL(clicked(bool)), m_renderer, SLOT(enableOpenGL(bool)));
-#endif
+#endif
connect(whatsThisButton, SIGNAL(clicked(bool)), m_renderer, SLOT(setDescriptionEnabled(bool)));
connect(whatsThisButton, SIGNAL(clicked(bool)),
m_renderer->hoverPoints(), SLOT(setDisabled(bool)));
diff --git a/examples/widgets/painting/pathstroke/pathstroke.cpp b/examples/widgets/painting/pathstroke/pathstroke.cpp
index a8b87f51f4..6807585f57 100644
--- a/examples/widgets/painting/pathstroke/pathstroke.cpp
+++ b/examples/widgets/painting/pathstroke/pathstroke.cpp
@@ -380,7 +380,7 @@ void PathStrokeWidget::setStyle( QStyle * style )
if (m_controls != 0)
{
m_controls->setStyle(style);
-
+
QList<QWidget *> widgets = m_controls->findChildren<QWidget *>();
foreach (QWidget *w, widgets)
w->setStyle(style);
@@ -544,7 +544,7 @@ void PathStrokeRenderer::mousePressEvent(QMouseEvent *e)
setAnimation(false);
mouseMoveEvent(e);
}
-
+
// If we're not running in small screen mode, always assume we're dragging
m_mouseDrag = !m_smallScreen;
m_mousePress = e->pos();
diff --git a/examples/widgets/painting/shared/shared.pri b/examples/widgets/painting/shared/shared.pri
index 1b8be82d03..af027e081a 100644
--- a/examples/widgets/painting/shared/shared.pri
+++ b/examples/widgets/painting/shared/shared.pri
@@ -1,6 +1,6 @@
INCLUDEPATH += $$PWD
-qtHaveModule(opengl) {
+qtHaveModule(opengl)|contains(QT_CONFIG, opengles1)|contains(QT_CONFIG, opengles2) {
DEFINES += QT_OPENGL_SUPPORT
QT += opengl widgets
}
diff --git a/examples/widgets/richtext/orderform/mainwindow.cpp b/examples/widgets/richtext/orderform/mainwindow.cpp
index b99dfd86df..7c0aa666fd 100644
--- a/examples/widgets/richtext/orderform/mainwindow.cpp
+++ b/examples/widgets/richtext/orderform/mainwindow.cpp
@@ -235,7 +235,7 @@ void MainWindow::openDialog()
//! [17]
void MainWindow::printFile()
{
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
QTextEdit *editor = static_cast<QTextEdit*>(letters->currentWidget());
//! [18]
QPrinter printer;
diff --git a/examples/widgets/richtext/textedit/textedit.cpp b/examples/widgets/richtext/textedit/textedit.cpp
index 0398493250..ae2bdedf13 100644
--- a/examples/widgets/richtext/textedit/textedit.cpp
+++ b/examples/widgets/richtext/textedit/textedit.cpp
@@ -197,7 +197,7 @@ void TextEdit::setupFileActions()
#ifndef QT_NO_PRINTER
a = new QAction(QIcon::fromTheme("document-print", QIcon(rsrcPath + "/fileprint.png")),
tr("&Print..."), this);
- a->setPriority(QAction::LowPriority);
+ a->setPriority(QAction::LowPriority);
a->setShortcut(QKeySequence::Print);
connect(a, SIGNAL(triggered()), this, SLOT(filePrint()));
tb->addAction(a);
@@ -511,7 +511,7 @@ bool TextEdit::fileSaveAs()
void TextEdit::filePrint()
{
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
QPrinter printer(QPrinter::HighResolution);
QPrintDialog *dlg = new QPrintDialog(&printer, this);
if (textEdit->textCursor().hasSelection())
@@ -525,7 +525,7 @@ void TextEdit::filePrint()
void TextEdit::filePrintPreview()
{
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
QPrinter printer(QPrinter::HighResolution);
QPrintPreviewDialog preview(&printer, this);
connect(&preview, SIGNAL(paintRequested(QPrinter*)), SLOT(printPreview(QPrinter*)));
diff --git a/examples/widgets/richtext/textedit/textedit.qdoc b/examples/widgets/richtext/textedit/textedit.qdoc
index 1695adfb2e..8e7a0bef24 100644
--- a/examples/widgets/richtext/textedit/textedit.qdoc
+++ b/examples/widgets/richtext/textedit/textedit.qdoc
@@ -31,8 +31,8 @@
\title Text Edit Example
\brief This example displays a text editor with the user interface written
- in pure C++.
-
+ in pure C++.
+
A similar example which uses Qt Designer to produce the user
interface is in the \l {Qt Designer Manual}.
diff --git a/examples/widgets/scroller/graphicsview/main.cpp b/examples/widgets/scroller/graphicsview/main.cpp
index f887aeccce..c17529d7c8 100644
--- a/examples/widgets/scroller/graphicsview/main.cpp
+++ b/examples/widgets/scroller/graphicsview/main.cpp
@@ -204,7 +204,7 @@ public:
Q_UNUSED(option);
Q_UNUSED(widget);
painter->setPen(QPen(QColor(100, 100, 100), 3.0));
- painter->drawRect(QRect(1.5, 1.5, m_size.width() - 3, m_size.height() - 3));
+ painter->drawRect(QRectF(1.5, 1.5, m_size.width() - 3, m_size.height() - 3));
}
QSizeF m_size;
diff --git a/examples/widgets/statemachine/factorial/main.cpp b/examples/widgets/statemachine/factorial/main.cpp
index 9107fea013..1ad2740563 100644
--- a/examples/widgets/statemachine/factorial/main.cpp
+++ b/examples/widgets/statemachine/factorial/main.cpp
@@ -78,7 +78,7 @@ public:
Q_SIGNALS:
void xChanged(int value);
-
+
private:
int m_x;
int m_fac;
diff --git a/examples/widgets/statemachine/rogue/window.cpp b/examples/widgets/statemachine/rogue/window.cpp
index 1e26278051..af8390f928 100644
--- a/examples/widgets/statemachine/rogue/window.cpp
+++ b/examples/widgets/statemachine/rogue/window.cpp
@@ -96,7 +96,7 @@ void Window::paintEvent(QPaintEvent * /* event */)
painter.setPen(Qt::white);
painter.drawText(QPoint(0, yPos), status());
-
+
for (int y = 0; y < HEIGHT; ++y) {
yPos += fontHeight;
xPos = 0;
@@ -184,7 +184,7 @@ void Window::buildMachine()
//![3]
QState *quitState = new QState(machine);
- quitState->assignProperty(this, "status", "Really quit(y/n)?");
+ quitState->assignProperty(this, "status", "Really quit(y/n)?");
QKeyEventTransition *yesTransition = new
QKeyEventTransition(this, QEvent::KeyPress, Qt::Key_Y);
@@ -218,7 +218,7 @@ void Window::movePlayer(Direction direction)
switch (direction) {
case Left:
if (map[pX - 1][pY] != '#')
- --pX;
+ --pX;
break;
case Right:
if (map[pX + 1][pY] != '#')
@@ -231,7 +231,7 @@ void Window::movePlayer(Direction direction)
case Down:
if (map[pX][pY + 1] != '#')
++pY;
- break;
+ break;
}
repaint();
}
diff --git a/examples/widgets/tools/completer/mainwindow.cpp b/examples/widgets/tools/completer/mainwindow.cpp
index 6730193928..c299d08c17 100644
--- a/examples/widgets/tools/completer/mainwindow.cpp
+++ b/examples/widgets/tools/completer/mainwindow.cpp
@@ -100,7 +100,7 @@ MainWindow::MainWindow(QWidget *parent)
//! [3]
lineEdit = new QLineEdit;
-
+
QGridLayout *layout = new QGridLayout;
layout->addWidget(modelLabel, 0, 0); layout->addWidget(modelCombo, 0, 1);
layout->addWidget(modeLabel, 1, 0); layout->addWidget(modeCombo, 1, 1);
diff --git a/examples/tools/doc/src/customcompleter.qdoc b/examples/widgets/tools/customcompleter/doc/src/customcompleter.qdoc
index f9ad3a43e9..a6c425d4c8 100644
--- a/examples/tools/doc/src/customcompleter.qdoc
+++ b/examples/widgets/tools/customcompleter/doc/src/customcompleter.qdoc
@@ -1,6 +1,6 @@
/****************************************************************************
**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
** This file is part of the documentation of the Qt Toolkit.
@@ -26,9 +26,11 @@
****************************************************************************/
/*!
- \example customcompleter
+ \example tools/customcompleter
\title Custom Completer Example
+ \ingroup examples-widgets-tools
+
\brief The Custom Completer example shows how to provide string-completion
facilities for an input widget based on data provided by a model. The
completer pops up suggestions for possible words based on the first three
@@ -43,7 +45,7 @@
that has a list of words to help QCompleter complete words. This file
contains the following:
- \quotefile customcompleter/customcompleter.qrc
+ \quotefile tools/customcompleter/customcompleter.qrc
\section1 TextEdit Class Definition
@@ -54,7 +56,7 @@
contains a private function \c textUnderCursor() and a private instance
of QCompleter, \c c.
- \snippet customcompleter/textedit.h 0
+ \snippet tools/customcompleter/textedit.h 0
\section1 TextEdit Class Implementation
@@ -63,11 +65,11 @@
the \c TextEdit object, using the
\l{QTextEdit::setPlainText()}{setPlainText()} function.
- \snippet customcompleter/textedit.cpp 0
+ \snippet tools/customcompleter/textedit.cpp 0
In addition, \c TextEdit also includes a default destructor:
- \snippet customcompleter/textedit.cpp 1
+ \snippet tools/customcompleter/textedit.cpp 1
The \c setCompleter() function accepts a \a completer and sets it up.
We use \c{if (c)} to check if \c c has been initialized. If it has been
@@ -75,7 +77,7 @@
the signal from the slot. This is to ensure that no previous completer
object is still connected to the slot.
- \snippet customcompleter/textedit.cpp 2
+ \snippet tools/customcompleter/textedit.cpp 2
We then instantiate \c c with \a completer and set it as \c{TextEdit}'s
widget. The completion mode and case sensitivity are also set and then
@@ -84,7 +86,7 @@
The \c completer() function is a getter function that returns \c c.
- \snippet customcompleter/textedit.cpp 3
+ \snippet tools/customcompleter/textedit.cpp 3
The completer pops up the options available, based on the contents of
\e wordlist.txt, but the text cursor is responsible for filling in the
@@ -99,7 +101,7 @@
completer's widget is \c TextEdit before using \c tc to insert the extra
characters to complete the word.
- \snippet customcompleter/textedit.cpp 4
+ \snippet tools/customcompleter/textedit.cpp 4
The figure below illustrates this process:
@@ -116,13 +118,13 @@
The \c textUnderCursor() function uses a QTextCursor, \c tc, to select a
word under the cursor and return it.
- \snippet customcompleter/textedit.cpp 5
+ \snippet tools/customcompleter/textedit.cpp 5
The \c TextEdit class reimplements \l{QWidget::focusInEvent()}
{focusInEvent()} function, which is an event handler used to receive
keyboard focus events for the widget.
- \snippet customcompleter/textedit.cpp 6
+ \snippet tools/customcompleter/textedit.cpp 6
The \l{QAbstractScrollArea::keyPressEvent()}{keyPressEvent()} is
reimplemented to ignore key events like Qt::Key_Enter, Qt::Key_Return,
@@ -131,12 +133,12 @@
If there is an active completer, we cannot process the shortcut, Ctrl+E.
- \snippet customcompleter/textedit.cpp 7
+ \snippet tools/customcompleter/textedit.cpp 7
We also handle other modifiers and shortcuts for which we do not want the
completer to respond to.
- \snippet customcompleter/textedit.cpp 8
+ \snippet tools/customcompleter/textedit.cpp 8
Finally, we pop up the completer.
@@ -147,7 +149,7 @@
\c createMenu() and \c modelFromFile() as well as private instances of
QCompleter and \c TextEdit.
- \snippet customcompleter/mainwindow.h 0
+ \snippet tools/customcompleter/mainwindow.h 0
\section1 MainWindow Class Implementation
@@ -157,31 +159,31 @@
to populate the \c completer. The \c{MainWindow}'s central widget is set
to \c TextEdit and its size is set to 500 x 300.
- \snippet customcompleter/mainwindow.cpp 0
+ \snippet tools/customcompleter/mainwindow.cpp 0
The \c createMenu() function creates the necessary QAction objects needed
for the "File" and "Help" menu and their \l{QAction::triggered()}
{triggered()} signals are connected to the \c quit(), \c about(), and
\c aboutQt() slots respectively.
- \snippet customcompleter/mainwindow.cpp 1
+ \snippet tools/customcompleter/mainwindow.cpp 1
The \c modelFromFile() function accepts a \a fileName and attempts to
extract the contents of this file into a QStringListModel. We display the
Qt::WaitCursor when we are populating the QStringList, \c words, and
restore the mouse cursor when we are done.
- \snippet customcompleter/mainwindow.cpp 2
+ \snippet tools/customcompleter/mainwindow.cpp 2
The \c about() function provides a brief description about the Custom
Completer example.
- \snippet customcompleter/mainwindow.cpp 3
+ \snippet tools/customcompleter/mainwindow.cpp 3
\section1 \c main() Function
The \c main() function instantiates \c MainWindow and invokes the
\l{QWidget::show()}{show()} function.
- \snippet customcompleter/main.cpp 0
+ \snippet tools/customcompleter/main.cpp 0
*/
diff --git a/examples/widgets/tools/customcompleter/mainwindow.cpp b/examples/widgets/tools/customcompleter/mainwindow.cpp
index 54033b5dd3..20b5d509ff 100644
--- a/examples/widgets/tools/customcompleter/mainwindow.cpp
+++ b/examples/widgets/tools/customcompleter/mainwindow.cpp
@@ -93,7 +93,7 @@ QAbstractItemModel *MainWindow::modelFromFile(const QString& fileName)
QApplication::setOverrideCursor(QCursor(Qt::WaitCursor));
#endif
QStringList words;
-
+
while (!file.atEnd()) {
QByteArray line = file.readLine();
if (!line.isEmpty())
diff --git a/examples/widgets/tools/customcompleter/textedit.cpp b/examples/widgets/tools/customcompleter/textedit.cpp
index 1fafdcd04d..9b0c1b9c97 100644
--- a/examples/widgets/tools/customcompleter/textedit.cpp
+++ b/examples/widgets/tools/customcompleter/textedit.cpp
@@ -53,7 +53,7 @@ TextEdit::TextEdit(QWidget *parent)
: QTextEdit(parent), c(0)
{
setPlainText(tr("This TextEdit provides autocompletions for words that have more than"
- " 3 characters. You can trigger autocompletion using ") +
+ " 3 characters. You can trigger autocompletion using ") +
QKeySequence("Ctrl+E").toString(QKeySequence::NativeText));
}
//! [0]
@@ -133,7 +133,7 @@ void TextEdit::keyPressEvent(QKeyEvent *e)
case Qt::Key_Escape:
case Qt::Key_Tab:
case Qt::Key_Backtab:
- e->ignore();
+ e->ignore();
return; // let the completer do default behavior
default:
break;
@@ -154,7 +154,7 @@ void TextEdit::keyPressEvent(QKeyEvent *e)
bool hasModifier = (e->modifiers() != Qt::NoModifier) && !ctrlOrShift;
QString completionPrefix = textUnderCursor();
- if (!isShortcut && (hasModifier || e->text().isEmpty()|| completionPrefix.length() < 3
+ if (!isShortcut && (hasModifier || e->text().isEmpty()|| completionPrefix.length() < 3
|| eow.contains(e->text().right(1)))) {
c->popup()->hide();
return;
diff --git a/examples/widgets/tools/i18n/languagechooser.cpp b/examples/widgets/tools/i18n/languagechooser.cpp
index 14c66a079b..15cc906fb8 100644
--- a/examples/widgets/tools/i18n/languagechooser.cpp
+++ b/examples/widgets/tools/i18n/languagechooser.cpp
@@ -49,7 +49,7 @@ extern void qt_mac_set_menubar_merge(bool merge);
QT_END_NAMESPACE
#endif
-LanguageChooser::LanguageChooser(QWidget *parent)
+LanguageChooser::LanguageChooser(const QString& defaultLang, QWidget *parent)
: QDialog(parent, Qt::WindowStaysOnTopHint)
{
groupBox = new QGroupBox("Languages");
@@ -61,6 +61,8 @@ LanguageChooser::LanguageChooser(QWidget *parent)
QCheckBox *checkBox = new QCheckBox(languageName(qmFiles[i]));
qmFileForCheckBoxMap.insert(checkBox, qmFiles[i]);
connect(checkBox, SIGNAL(toggled(bool)), this, SLOT(checkBoxToggled()));
+ if (languageMatch(defaultLang, qmFiles[i]))
+ checkBox->setCheckState(Qt::Checked);
groupBoxLayout->addWidget(checkBox, i / 2, i % 2);
}
groupBox->setLayout(groupBoxLayout);
@@ -87,6 +89,14 @@ LanguageChooser::LanguageChooser(QWidget *parent)
setWindowTitle("I18N");
}
+bool LanguageChooser::languageMatch(const QString& lang, const QString& qmFile)
+{
+ //qmFile: i18n_xx.qm
+ const QString prefix = "i18n_";
+ const int langTokenLength = 2; /*FIXME: is checking two chars enough?*/
+ return qmFile.midRef(qmFile.indexOf(prefix) + prefix.length(), langTokenLength) == lang.leftRef(langTokenLength);
+}
+
bool LanguageChooser::eventFilter(QObject *object, QEvent *event)
{
if (event->type() == QEvent::Close) {
diff --git a/examples/widgets/tools/i18n/languagechooser.h b/examples/widgets/tools/i18n/languagechooser.h
index 13a7c3570a..a2282cdaf5 100644
--- a/examples/widgets/tools/i18n/languagechooser.h
+++ b/examples/widgets/tools/i18n/languagechooser.h
@@ -58,7 +58,7 @@ class LanguageChooser : public QDialog
Q_OBJECT
public:
- LanguageChooser(QWidget *parent = 0);
+ explicit LanguageChooser(const QString& defaultLang = QString(), QWidget *parent = 0);
protected:
bool eventFilter(QObject *object, QEvent *event);
@@ -73,6 +73,7 @@ private:
QStringList findQmFiles();
QString languageName(const QString &qmFile);
QColor colorForLanguage(const QString &language);
+ static bool languageMatch(const QString& lang, const QString& qmFile);
QGroupBox *groupBox;
QDialogButtonBox *buttonBox;
diff --git a/examples/widgets/tools/i18n/main.cpp b/examples/widgets/tools/i18n/main.cpp
index 9d78876460..59e3081c03 100644
--- a/examples/widgets/tools/i18n/main.cpp
+++ b/examples/widgets/tools/i18n/main.cpp
@@ -39,7 +39,7 @@
****************************************************************************/
#include <QApplication>
-
+#include <QLocale>
#include "languagechooser.h"
#include "mainwindow.h"
@@ -48,7 +48,7 @@ int main(int argc, char *argv[])
Q_INIT_RESOURCE(i18n);
QApplication app(argc, argv);
- LanguageChooser chooser;
+ LanguageChooser chooser(QLocale::system().name());
chooser.show();
return app.exec();
}
diff --git a/examples/widgets/tools/plugandpaint/mainwindow.cpp b/examples/widgets/tools/plugandpaint/mainwindow.cpp
index cc0ce48be8..fdd3689a1a 100644
--- a/examples/widgets/tools/plugandpaint/mainwindow.cpp
+++ b/examples/widgets/tools/plugandpaint/mainwindow.cpp
@@ -81,7 +81,7 @@ MainWindow::MainWindow() :
void MainWindow::open()
{
const QString fileName = QFileDialog::getOpenFileName(this,
- tr("Open File"),
+ tr("Open File"),
QDir::currentPath());
if (!fileName.isEmpty()) {
if (!paintArea->openImage(fileName)) {
diff --git a/examples/widgets/tools/plugandpaint/plugindialog.cpp b/examples/widgets/tools/plugandpaint/plugindialog.cpp
index 2c19d32584..19d2a103fa 100644
--- a/examples/widgets/tools/plugandpaint/plugindialog.cpp
+++ b/examples/widgets/tools/plugandpaint/plugindialog.cpp
@@ -58,7 +58,7 @@ PluginDialog::PluginDialog(const QString &path, const QStringList &fileNames,
QDialog(parent),
label(new QLabel),
treeWidget(new QTreeWidget),
- okButton(new QPushButton(tr("OK")))
+ okButton(new QPushButton(tr("OK")))
{
treeWidget->setAlternatingRowColors(false);
treeWidget->setSelectionMode(QAbstractItemView::NoSelection);
diff --git a/examples/widgets/tools/undoframework/diagramscene.cpp b/examples/widgets/tools/undoframework/diagramscene.cpp
index bef3b89df0..1083cba5db 100644
--- a/examples/widgets/tools/undoframework/diagramscene.cpp
+++ b/examples/widgets/tools/undoframework/diagramscene.cpp
@@ -59,8 +59,8 @@ void DiagramScene::mousePressEvent(QGraphicsSceneMouseEvent *event)
if (movingItem != 0 && event->button() == Qt::LeftButton) {
oldPos = movingItem->pos();
}
-
- clearSelection();
+
+ clearSelection();
QGraphicsScene::mousePressEvent(event);
}
diff --git a/examples/widgets/tutorials/addressbook-fr/part1/addressbook.cpp b/examples/widgets/tutorials/addressbook-fr/part1/addressbook.cpp
index 4e8c95635b..60acd6bb27 100644
--- a/examples/widgets/tutorials/addressbook-fr/part1/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook-fr/part1/addressbook.cpp
@@ -60,7 +60,7 @@ AddressBook::AddressBook(QWidget *parent)
mainLayout->addWidget(addressText, 1, 1);
//! [layout]
-//![setting the layout]
+//![setting the layout]
setLayout(mainLayout);
setWindowTitle(tr("Simple Address Book"));
}
diff --git a/examples/widgets/tutorials/addressbook-fr/part2/addressbook.cpp b/examples/widgets/tutorials/addressbook-fr/part2/addressbook.cpp
index bb221d2222..d88716a8c8 100644
--- a/examples/widgets/tutorials/addressbook-fr/part2/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook-fr/part2/addressbook.cpp
@@ -51,10 +51,10 @@ AddressBook::AddressBook(QWidget *parent)
//! [setting readonly 1]
QLabel *addressLabel = new QLabel(tr("Address:"));
addressText = new QTextEdit;
-//! [setting readonly 2]
+//! [setting readonly 2]
addressText->setReadOnly(true);
//! [setting readonly 2]
-
+
//! [pushbutton declaration]
addButton = new QPushButton(tr("&Add"));
addButton->show();
@@ -94,7 +94,7 @@ void AddressBook::addContact()
nameLine->clear();
addressText->clear();
-
+
nameLine->setReadOnly(false);
nameLine->setFocus(Qt::OtherFocusReason);
addressText->setReadOnly(false);
@@ -110,7 +110,7 @@ void AddressBook::submitContact()
{
QString name = nameLine->text();
QString address = addressText->toPlainText();
-
+
if ( name.isEmpty()|| address.isEmpty()) {
QMessageBox::information(this, tr("Empty Field"),
tr("Please enter a name and address."));
@@ -152,6 +152,6 @@ void AddressBook::cancel()
addButton->setEnabled(true);
submitButton->hide();
- cancelButton->hide();
+ cancelButton->hide();
}
//! [cancel]
diff --git a/examples/widgets/tutorials/addressbook-fr/part3/addressbook.cpp b/examples/widgets/tutorials/addressbook-fr/part3/addressbook.cpp
index 09b1e06bfe..86ff58d015 100644
--- a/examples/widgets/tutorials/addressbook-fr/part3/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook-fr/part3/addressbook.cpp
@@ -51,7 +51,7 @@ AddressBook::AddressBook(QWidget *parent)
QLabel *addressLabel = new QLabel(tr("Address:"));
addressText = new QTextEdit;
addressText->setReadOnly(true);
-
+
addButton = new QPushButton(tr("&Add"));
addButton->show();
submitButton = new QPushButton(tr("&Submit"));
@@ -68,7 +68,7 @@ AddressBook::AddressBook(QWidget *parent)
connect(addButton, SIGNAL(clicked()), this, SLOT(addContact()));
connect(submitButton, SIGNAL(clicked()), this, SLOT(submitContact()));
connect(cancelButton, SIGNAL(clicked()), this, SLOT(cancel()));
-//! [connecting navigation signals]
+//! [connecting navigation signals]
connect(nextButton, SIGNAL(clicked()), this, SLOT(next()));
connect(previousButton, SIGNAL(clicked()), this, SLOT(previous()));
//! [connecting navigation signals]
@@ -107,7 +107,7 @@ void AddressBook::addContact()
nameLine->setReadOnly(false);
nameLine->setFocus(Qt::OtherFocusReason);
addressText->setReadOnly(false);
-
+
addButton->setEnabled(false);
//! [disabling navigation]
nextButton->setEnabled(false);
@@ -121,7 +121,7 @@ void AddressBook::submitContact()
{
QString name = nameLine->text();
QString address = addressText->toPlainText();
-
+
if (name.isEmpty() || address.isEmpty()) {
QMessageBox::information(this, tr("Empty Field"),
tr("Please enter a name and address."));
@@ -159,20 +159,20 @@ void AddressBook::cancel()
{
nameLine->setText(oldName);
addressText->setText(oldAddress);
-
+
if (contacts.isEmpty()) {
nameLine->clear();
addressText->clear();
}
-
+
nameLine->setReadOnly(true);
addressText->setReadOnly(true);
addButton->setEnabled(true);
-
+
int number = contacts.size();
nextButton->setEnabled(number > 1);
previousButton->setEnabled(number > 1);
-
+
submitButton->hide();
cancelButton->hide();
}
diff --git a/examples/widgets/tutorials/addressbook-fr/part3/addressbook.h b/examples/widgets/tutorials/addressbook-fr/part3/addressbook.h
index 2458645ab5..3613fedb34 100644
--- a/examples/widgets/tutorials/addressbook-fr/part3/addressbook.h
+++ b/examples/widgets/tutorials/addressbook-fr/part3/addressbook.h
@@ -65,16 +65,16 @@ public slots:
//! [navigation functions]
void next();
void previous();
-//! [navigation functions]
+//! [navigation functions]
private:
QPushButton *addButton;
QPushButton *submitButton;
QPushButton *cancelButton;
-//! [navigation pushbuttons]
+//! [navigation pushbuttons]
QPushButton *nextButton;
QPushButton *previousButton;
-//! [navigation pushbuttons]
+//! [navigation pushbuttons]
QLineEdit *nameLine;
QTextEdit *addressText;
diff --git a/examples/widgets/tutorials/addressbook-fr/part4/addressbook.cpp b/examples/widgets/tutorials/addressbook-fr/part4/addressbook.cpp
index 2d158f3f17..70f5d110db 100644
--- a/examples/widgets/tutorials/addressbook-fr/part4/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook-fr/part4/addressbook.cpp
@@ -53,17 +53,17 @@ AddressBook::AddressBook(QWidget *parent)
addressText->setReadOnly(true);
addButton = new QPushButton(tr("&Add"));
-//! [edit and remove buttons]
+//! [edit and remove buttons]
editButton = new QPushButton(tr("&Edit"));
editButton->setEnabled(false);
removeButton = new QPushButton(tr("&Remove"));
removeButton->setEnabled(false);
-//! [edit and remove buttons]
+//! [edit and remove buttons]
submitButton = new QPushButton(tr("&Submit"));
submitButton->hide();
cancelButton = new QPushButton(tr("&Cancel"));
cancelButton->hide();
-
+
nextButton = new QPushButton(tr("&Next"));
nextButton->setEnabled(false);
previousButton = new QPushButton(tr("&Previous"));
@@ -71,20 +71,20 @@ AddressBook::AddressBook(QWidget *parent)
connect(addButton, SIGNAL(clicked()), this, SLOT(addContact()));
connect(submitButton, SIGNAL(clicked()), this, SLOT(submitContact()));
-//! [connecting edit and remove]
+//! [connecting edit and remove]
connect(editButton, SIGNAL(clicked()), this, SLOT(editContact()));
connect(removeButton, SIGNAL(clicked()), this, SLOT(removeContact()));
-//! [connecting edit and remove]
+//! [connecting edit and remove]
connect(cancelButton, SIGNAL(clicked()), this, SLOT(cancel()));
connect(nextButton, SIGNAL(clicked()), this, SLOT(next()));
connect(previousButton, SIGNAL(clicked()), this, SLOT(previous()));
QVBoxLayout *buttonLayout1 = new QVBoxLayout;
buttonLayout1->addWidget(addButton);
-//! [adding edit and remove to the layout]
+//! [adding edit and remove to the layout]
buttonLayout1->addWidget(editButton);
buttonLayout1->addWidget(removeButton);
-//! [adding edit and remove to the layout]
+//! [adding edit and remove to the layout]
buttonLayout1->addWidget(submitButton);
buttonLayout1->addWidget(cancelButton);
buttonLayout1->addStretch();
@@ -138,7 +138,7 @@ void AddressBook::submitContact()
}
//! [submitContact() function part1]
if (currentMode == AddingMode) {
-
+
if (!contacts.contains(name)) {
contacts.insert(name, address);
QMessageBox::information(this, tr("Add Successful"),
@@ -150,7 +150,7 @@ void AddressBook::submitContact()
//! [submitContact() function part1]
//! [submitContact() function part2]
} else if (currentMode == EditingMode) {
-
+
if (oldName != name) {
if (!contacts.contains(name)) {
QMessageBox::information(this, tr("Edit Successful"),
@@ -164,7 +164,7 @@ void AddressBook::submitContact()
} else if (oldAddress != address) {
QMessageBox::information(this, tr("Edit Successful"),
tr("\"%1\" has been edited in your address book.").arg(name));
- contacts[name] = address;
+ contacts[name] = address;
}
}
@@ -192,7 +192,7 @@ void AddressBook::removeContact()
QMessageBox::Yes | QMessageBox::No);
if (button == QMessageBox::Yes) {
-
+
previous();
contacts.remove(name);
@@ -243,7 +243,7 @@ void AddressBook::updateInterface(Mode mode)
currentMode = mode;
switch (currentMode) {
-
+
case AddingMode:
case EditingMode:
diff --git a/examples/widgets/tutorials/addressbook-fr/part4/addressbook.h b/examples/widgets/tutorials/addressbook-fr/part4/addressbook.h
index ff8c4f0318..6430ac3413 100644
--- a/examples/widgets/tutorials/addressbook-fr/part4/addressbook.h
+++ b/examples/widgets/tutorials/addressbook-fr/part4/addressbook.h
@@ -77,10 +77,10 @@ private:
void updateInterface(Mode mode);
//! [updateInterface() declaration]
QPushButton *addButton;
-//! [buttons declaration]
+//! [buttons declaration]
QPushButton *editButton;
QPushButton *removeButton;
-//! [buttons declaration]
+//! [buttons declaration]
QPushButton *submitButton;
QPushButton *cancelButton;
QPushButton *nextButton;
@@ -91,9 +91,9 @@ private:
QMap<QString, QString> contacts;
QString oldName;
QString oldAddress;
-//! [mode declaration]
+//! [mode declaration]
Mode currentMode;
-//! [mode declaration]
+//! [mode declaration]
};
#endif
diff --git a/examples/widgets/tutorials/addressbook-fr/part5/addressbook.cpp b/examples/widgets/tutorials/addressbook-fr/part5/addressbook.cpp
index 02f4788537..33af5f1e4e 100644
--- a/examples/widgets/tutorials/addressbook-fr/part5/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook-fr/part5/addressbook.cpp
@@ -81,19 +81,19 @@ AddressBook::AddressBook(QWidget *parent)
connect(editButton, SIGNAL(clicked()), this, SLOT(editContact()));
connect(cancelButton, SIGNAL(clicked()), this, SLOT(cancel()));
connect(removeButton, SIGNAL(clicked()), this, SLOT(removeContact()));
-//! [signals and slots for find]
+//! [signals and slots for find]
connect(findButton, SIGNAL(clicked()), this, SLOT(findContact()));
-//! [signals and slots for find]
+//! [signals and slots for find]
connect(nextButton, SIGNAL(clicked()), this, SLOT(next()));
connect(previousButton, SIGNAL(clicked()), this, SLOT(previous()));
-
+
QVBoxLayout *buttonLayout1 = new QVBoxLayout;
buttonLayout1->addWidget(addButton);
buttonLayout1->addWidget(editButton);
buttonLayout1->addWidget(removeButton);
-//! [adding findButton to layout]
+//! [adding findButton to layout]
buttonLayout1->addWidget(findButton);
-//! [adding findButton to layout]
+//! [adding findButton to layout]
buttonLayout1->addWidget(submitButton);
buttonLayout1->addWidget(cancelButton);
buttonLayout1->addStretch();
@@ -145,7 +145,7 @@ void AddressBook::submitContact()
}
if (currentMode == AddingMode) {
-
+
if (!contacts.contains(name)) {
contacts.insert(name, address);
QMessageBox::information(this, tr("Add Successful"),
@@ -155,7 +155,7 @@ void AddressBook::submitContact()
tr("Sorry, \"%1\" is already in your address book.").arg(name));
}
} else if (currentMode == EditingMode) {
-
+
if (oldName != name) {
if (!contacts.contains(name)) {
QMessageBox::information(this, tr("Edit Successful"),
@@ -196,7 +196,7 @@ void AddressBook::removeContact()
QMessageBox::Yes | QMessageBox::No);
if (button == QMessageBox::Yes) {
-
+
previous();
contacts.remove(name);
@@ -241,7 +241,7 @@ void AddressBook::previous()
nameLine->setText(i.key());
addressText->setText(i.value());
}
-//! [findContact() function]
+//! [findContact() function]
void AddressBook::findContact()
{
dialog->show();
@@ -261,7 +261,7 @@ void AddressBook::findContact()
updateInterface(NavigationMode);
}
-//! [findContact() function]
+//! [findContact() function]
void AddressBook::updateInterface(Mode mode)
{
@@ -288,7 +288,7 @@ void AddressBook::updateInterface(Mode mode)
break;
case NavigationMode:
-
+
if (contacts.isEmpty()) {
nameLine->clear();
addressText->clear();
diff --git a/examples/widgets/tutorials/addressbook-fr/part5/addressbook.h b/examples/widgets/tutorials/addressbook-fr/part5/addressbook.h
index 5e2c18e91a..f8a53304ee 100644
--- a/examples/widgets/tutorials/addressbook-fr/part5/addressbook.h
+++ b/examples/widgets/tutorials/addressbook-fr/part5/addressbook.h
@@ -68,9 +68,9 @@ public slots:
void submitContact();
void cancel();
void removeContact();
-//! [findContact() declaration]
+//! [findContact() declaration]
void findContact();
-//! [findContact() declaration]
+//! [findContact() declaration]
void next();
void previous();
@@ -80,9 +80,9 @@ private:
QPushButton *addButton;
QPushButton *editButton;
QPushButton *removeButton;
-//! [findButton declaration]
+//! [findButton declaration]
QPushButton *findButton;
-//! [findButton declaration]
+//! [findButton declaration]
QPushButton *submitButton;
QPushButton *cancelButton;
QPushButton *nextButton;
@@ -91,9 +91,9 @@ private:
QTextEdit *addressText;
QMap<QString, QString> contacts;
-//! [FindDialog declaration]
+//! [FindDialog declaration]
FindDialog *dialog;
-//! [FindDialog declaration]
+//! [FindDialog declaration]
QString oldName;
QString oldAddress;
Mode currentMode;
diff --git a/examples/widgets/tutorials/addressbook-fr/part6/addressbook.cpp b/examples/widgets/tutorials/addressbook-fr/part6/addressbook.cpp
index e8caa628a5..e81c959c2c 100644
--- a/examples/widgets/tutorials/addressbook-fr/part6/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook-fr/part6/addressbook.cpp
@@ -71,9 +71,9 @@ AddressBook::AddressBook(QWidget *parent)
previousButton->setEnabled(false);
loadButton = new QPushButton(tr("&Load..."));
-//! [tooltip 1]
+//! [tooltip 1]
loadButton->setToolTip(tr("Load contacts from a file"));
-//! [tooltip 1]
+//! [tooltip 1]
saveButton = new QPushButton(tr("Sa&ve..."));
//! [tooltip 2]
saveButton->setToolTip(tr("Save contacts to a file"));
@@ -92,7 +92,7 @@ AddressBook::AddressBook(QWidget *parent)
connect(previousButton, SIGNAL(clicked()), this, SLOT(previous()));
connect(loadButton, SIGNAL(clicked()), this, SLOT(loadFromFile()));
connect(saveButton, SIGNAL(clicked()), this, SLOT(saveToFile()));
-
+
QVBoxLayout *buttonLayout1 = new QVBoxLayout;
buttonLayout1->addWidget(addButton);
buttonLayout1->addWidget(editButton);
@@ -151,7 +151,7 @@ void AddressBook::submitContact()
}
if (currentMode == AddingMode) {
-
+
if (!contacts.contains(name)) {
contacts.insert(name, address);
QMessageBox::information(this, tr("Add Successful"),
@@ -161,7 +161,7 @@ void AddressBook::submitContact()
tr("Sorry, \"%1\" is already in your address book.").arg(name));
}
} else if (currentMode == EditingMode) {
-
+
if (oldName != name) {
if (!contacts.contains(name)) {
QMessageBox::information(this, tr("Edit Successful"),
@@ -202,7 +202,7 @@ void AddressBook::removeContact()
QMessageBox::Yes | QMessageBox::No);
if (button == QMessageBox::Yes) {
-
+
previous();
contacts.remove(name);
@@ -296,7 +296,7 @@ void AddressBook::updateInterface(Mode mode)
break;
case NavigationMode:
-
+
if (contacts.isEmpty()) {
nameLine->clear();
addressText->clear();
@@ -341,12 +341,12 @@ void AddressBook::saveToFile()
return;
}
-//! [saveToFile() function part2]
+//! [saveToFile() function part2]
//! [saveToFile() function part3]
QDataStream out(&file);
out.setVersion(QDataStream::Qt_4_5);
out << contacts;
- }
+ }
}
//! [saveToFile() function part3]
@@ -362,15 +362,15 @@ void AddressBook::loadFromFile()
if (fileName.isEmpty())
return;
else {
-
+
QFile file(fileName);
-
+
if (!file.open(QIODevice::ReadOnly)) {
QMessageBox::information(this, tr("Unable to open file"),
file.errorString());
return;
}
-
+
QDataStream in(&file);
in.setVersion(QDataStream::Qt_4_5);
contacts.empty(); // empty existing contacts
diff --git a/examples/widgets/tutorials/addressbook-fr/part6/addressbook.h b/examples/widgets/tutorials/addressbook-fr/part6/addressbook.h
index 99dfd1e404..ce2691ccad 100644
--- a/examples/widgets/tutorials/addressbook-fr/part6/addressbook.h
+++ b/examples/widgets/tutorials/addressbook-fr/part6/addressbook.h
@@ -70,10 +70,10 @@ public slots:
void findContact();
void next();
void previous();
-//! [save and load functions declaration]
+//! [save and load functions declaration]
void saveToFile();
void loadFromFile();
-//! [save and load functions declaration]
+//! [save and load functions declaration]
private:
void updateInterface(Mode mode);
@@ -86,10 +86,10 @@ private:
QPushButton *cancelButton;
QPushButton *nextButton;
QPushButton *previousButton;
-//! [save and load buttons declaration]
+//! [save and load buttons declaration]
QPushButton *loadButton;
QPushButton *saveButton;
-//! [save and load buttons declaration]
+//! [save and load buttons declaration]
QLineEdit *nameLine;
QTextEdit *addressText;
diff --git a/examples/widgets/tutorials/addressbook-fr/part7/addressbook.cpp b/examples/widgets/tutorials/addressbook-fr/part7/addressbook.cpp
index a91a3bbc12..a0780ae78a 100644
--- a/examples/widgets/tutorials/addressbook-fr/part7/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook-fr/part7/addressbook.cpp
@@ -93,7 +93,7 @@ AddressBook::AddressBook(QWidget *parent)
connect(loadButton, SIGNAL(clicked()), this, SLOT(loadFromFile()));
connect(saveButton, SIGNAL(clicked()), this, SLOT(saveToFile()));
connect(exportButton, SIGNAL(clicked()), this, SLOT(exportAsVCard()));
-
+
QVBoxLayout *buttonLayout1 = new QVBoxLayout;
buttonLayout1->addWidget(addButton);
buttonLayout1->addWidget(editButton);
@@ -153,7 +153,7 @@ void AddressBook::submitContact()
}
if (currentMode == AddingMode) {
-
+
if (!contacts.contains(name)) {
contacts.insert(name, address);
QMessageBox::information(this, tr("Add Successful"),
@@ -163,7 +163,7 @@ void AddressBook::submitContact()
tr("Sorry, \"%1\" is already in your address book.").arg(name));
}
} else if (currentMode == EditingMode) {
-
+
if (oldName != name) {
if (!contacts.contains(name)) {
QMessageBox::information(this, tr("Edit Successful"),
@@ -204,7 +204,7 @@ void AddressBook::removeContact()
QMessageBox::Yes | QMessageBox::No);
if (button == QMessageBox::Yes) {
-
+
previous();
contacts.remove(name);
@@ -298,7 +298,7 @@ void AddressBook::updateInterface(Mode mode)
break;
case NavigationMode:
-
+
if (contacts.isEmpty()) {
nameLine->clear();
addressText->clear();
@@ -331,7 +331,7 @@ void AddressBook::saveToFile()
QString fileName = QFileDialog::getSaveFileName(this,
tr("Save Address Book"), "",
tr("Address Book (*.abk);;All Files (*)"));
-
+
if (fileName.isEmpty())
return;
else {
@@ -404,14 +404,14 @@ void AddressBook::exportAsVCard()
QString fileName = QFileDialog::getSaveFileName(this,
tr("Export Contact"), "",
tr("vCard Files (*.vcf);;All Files (*)"));
-
+
if (fileName.isEmpty())
return;
QFile file(fileName);
//! [export function part1]
-
-//! [export function part2]
+
+//! [export function part2]
if (!file.open(QIODevice::WriteOnly)) {
QMessageBox::information(this, tr("Unable to open file"),
file.errorString());
@@ -425,12 +425,12 @@ void AddressBook::exportAsVCard()
out << "BEGIN:VCARD" << "\n";
out << "VERSION:2.1" << "\n";
out << "N:" << lastName << ";" << firstName << "\n";
-
- if (!nameList.isEmpty())
+
+ if (!nameList.isEmpty())
out << "FN:" << nameList.join(' ') << "\n";
else
out << "FN:" << firstName << "\n";
-//! [export function part3]
+//! [export function part3]
//! [export function part4]
address.replace(";", "\\;", Qt::CaseInsensitive);
diff --git a/examples/widgets/tutorials/addressbook-fr/part7/addressbook.h b/examples/widgets/tutorials/addressbook-fr/part7/addressbook.h
index a34cf24a23..d672c7a85b 100644
--- a/examples/widgets/tutorials/addressbook-fr/part7/addressbook.h
+++ b/examples/widgets/tutorials/addressbook-fr/part7/addressbook.h
@@ -74,7 +74,7 @@ public slots:
void loadFromFile();
//! [exportAsVCard() declaration]
void exportAsVCard();
-//! [exportAsVCard() declaration]
+//! [exportAsVCard() declaration]
private:
void updateInterface(Mode mode);
@@ -89,9 +89,9 @@ private:
QPushButton *previousButton;
QPushButton *loadButton;
QPushButton *saveButton;
-//! [exportButton declaration]
+//! [exportButton declaration]
QPushButton *exportButton;
-//! [exportButton declaration]
+//! [exportButton declaration]
QLineEdit *nameLine;
QTextEdit *addressText;
diff --git a/examples/widgets/tutorials/addressbook/part1/addressbook.cpp b/examples/widgets/tutorials/addressbook/part1/addressbook.cpp
index 4e8c95635b..60acd6bb27 100644
--- a/examples/widgets/tutorials/addressbook/part1/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook/part1/addressbook.cpp
@@ -60,7 +60,7 @@ AddressBook::AddressBook(QWidget *parent)
mainLayout->addWidget(addressText, 1, 1);
//! [layout]
-//![setting the layout]
+//![setting the layout]
setLayout(mainLayout);
setWindowTitle(tr("Simple Address Book"));
}
diff --git a/examples/widgets/tutorials/addressbook/part2/addressbook.cpp b/examples/widgets/tutorials/addressbook/part2/addressbook.cpp
index e6f3409efc..6fd5d03fea 100644
--- a/examples/widgets/tutorials/addressbook/part2/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook/part2/addressbook.cpp
@@ -51,10 +51,10 @@ AddressBook::AddressBook(QWidget *parent)
//! [setting readonly 1]
QLabel *addressLabel = new QLabel(tr("Address:"));
addressText = new QTextEdit;
-//! [setting readonly 2]
+//! [setting readonly 2]
addressText->setReadOnly(true);
//! [setting readonly 2]
-
+
//! [pushbutton declaration]
addButton = new QPushButton(tr("&Add"));
addButton->show();
@@ -94,7 +94,7 @@ void AddressBook::addContact()
nameLine->clear();
addressText->clear();
-
+
nameLine->setReadOnly(false);
nameLine->setFocus(Qt::OtherFocusReason);
addressText->setReadOnly(false);
@@ -110,7 +110,7 @@ void AddressBook::submitContact()
{
QString name = nameLine->text();
QString address = addressText->toPlainText();
-
+
if (name.isEmpty() || address.isEmpty()) {
QMessageBox::information(this, tr("Empty Field"),
tr("Please enter a name and address."));
@@ -152,6 +152,6 @@ void AddressBook::cancel()
addButton->setEnabled(true);
submitButton->hide();
- cancelButton->hide();
+ cancelButton->hide();
}
//! [cancel]
diff --git a/examples/widgets/tutorials/addressbook/part3/addressbook.cpp b/examples/widgets/tutorials/addressbook/part3/addressbook.cpp
index 61c331d1f5..bcf3f63430 100644
--- a/examples/widgets/tutorials/addressbook/part3/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook/part3/addressbook.cpp
@@ -51,7 +51,7 @@ AddressBook::AddressBook(QWidget *parent)
QLabel *addressLabel = new QLabel(tr("Address:"));
addressText = new QTextEdit;
addressText->setReadOnly(true);
-
+
addButton = new QPushButton(tr("&Add"));
addButton->show();
submitButton = new QPushButton(tr("&Submit"));
@@ -68,7 +68,7 @@ AddressBook::AddressBook(QWidget *parent)
connect(addButton, SIGNAL(clicked()), this, SLOT(addContact()));
connect(submitButton, SIGNAL(clicked()), this, SLOT(submitContact()));
connect(cancelButton, SIGNAL(clicked()), this, SLOT(cancel()));
-//! [connecting navigation signals]
+//! [connecting navigation signals]
connect(nextButton, SIGNAL(clicked()), this, SLOT(next()));
connect(previousButton, SIGNAL(clicked()), this, SLOT(previous()));
//! [connecting navigation signals]
@@ -107,7 +107,7 @@ void AddressBook::addContact()
nameLine->setReadOnly(false);
nameLine->setFocus(Qt::OtherFocusReason);
addressText->setReadOnly(false);
-
+
addButton->setEnabled(false);
//! [disabling navigation]
nextButton->setEnabled(false);
@@ -121,7 +121,7 @@ void AddressBook::submitContact()
{
QString name = nameLine->text();
QString address = addressText->toPlainText();
-
+
if (name.isEmpty() || address.isEmpty()) {
QMessageBox::information(this, tr("Empty Field"),
tr("Please enter a name and address."));
@@ -159,20 +159,20 @@ void AddressBook::cancel()
{
nameLine->setText(oldName);
addressText->setText(oldAddress);
-
+
if (contacts.isEmpty()) {
nameLine->clear();
addressText->clear();
}
-
+
nameLine->setReadOnly(true);
addressText->setReadOnly(true);
addButton->setEnabled(true);
-
+
int number = contacts.size();
nextButton->setEnabled(number > 1);
previousButton->setEnabled(number > 1);
-
+
submitButton->hide();
cancelButton->hide();
}
diff --git a/examples/widgets/tutorials/addressbook/part3/addressbook.h b/examples/widgets/tutorials/addressbook/part3/addressbook.h
index 2458645ab5..3613fedb34 100644
--- a/examples/widgets/tutorials/addressbook/part3/addressbook.h
+++ b/examples/widgets/tutorials/addressbook/part3/addressbook.h
@@ -65,16 +65,16 @@ public slots:
//! [navigation functions]
void next();
void previous();
-//! [navigation functions]
+//! [navigation functions]
private:
QPushButton *addButton;
QPushButton *submitButton;
QPushButton *cancelButton;
-//! [navigation pushbuttons]
+//! [navigation pushbuttons]
QPushButton *nextButton;
QPushButton *previousButton;
-//! [navigation pushbuttons]
+//! [navigation pushbuttons]
QLineEdit *nameLine;
QTextEdit *addressText;
diff --git a/examples/widgets/tutorials/addressbook/part4/addressbook.cpp b/examples/widgets/tutorials/addressbook/part4/addressbook.cpp
index 6b3731b5f6..66764a2815 100644
--- a/examples/widgets/tutorials/addressbook/part4/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook/part4/addressbook.cpp
@@ -53,17 +53,17 @@ AddressBook::AddressBook(QWidget *parent)
addressText->setReadOnly(true);
addButton = new QPushButton(tr("&Add"));
-//! [edit and remove buttons]
+//! [edit and remove buttons]
editButton = new QPushButton(tr("&Edit"));
editButton->setEnabled(false);
removeButton = new QPushButton(tr("&Remove"));
removeButton->setEnabled(false);
-//! [edit and remove buttons]
+//! [edit and remove buttons]
submitButton = new QPushButton(tr("&Submit"));
submitButton->hide();
cancelButton = new QPushButton(tr("&Cancel"));
cancelButton->hide();
-
+
nextButton = new QPushButton(tr("&Next"));
nextButton->setEnabled(false);
previousButton = new QPushButton(tr("&Previous"));
@@ -71,20 +71,20 @@ AddressBook::AddressBook(QWidget *parent)
connect(addButton, SIGNAL(clicked()), this, SLOT(addContact()));
connect(submitButton, SIGNAL(clicked()), this, SLOT(submitContact()));
-//! [connecting edit and remove]
+//! [connecting edit and remove]
connect(editButton, SIGNAL(clicked()), this, SLOT(editContact()));
connect(removeButton, SIGNAL(clicked()), this, SLOT(removeContact()));
-//! [connecting edit and remove]
+//! [connecting edit and remove]
connect(cancelButton, SIGNAL(clicked()), this, SLOT(cancel()));
connect(nextButton, SIGNAL(clicked()), this, SLOT(next()));
connect(previousButton, SIGNAL(clicked()), this, SLOT(previous()));
QVBoxLayout *buttonLayout1 = new QVBoxLayout;
buttonLayout1->addWidget(addButton);
-//! [adding edit and remove to the layout]
+//! [adding edit and remove to the layout]
buttonLayout1->addWidget(editButton);
buttonLayout1->addWidget(removeButton);
-//! [adding edit and remove to the layout]
+//! [adding edit and remove to the layout]
buttonLayout1->addWidget(submitButton);
buttonLayout1->addWidget(cancelButton);
buttonLayout1->addStretch();
@@ -138,7 +138,7 @@ void AddressBook::submitContact()
}
//! [submitContact() function part1]
if (currentMode == AddingMode) {
-
+
if (!contacts.contains(name)) {
contacts.insert(name, address);
QMessageBox::information(this, tr("Add Successful"),
@@ -150,7 +150,7 @@ void AddressBook::submitContact()
//! [submitContact() function part1]
//! [submitContact() function part2]
} else if (currentMode == EditingMode) {
-
+
if (oldName != name) {
if (!contacts.contains(name)) {
QMessageBox::information(this, tr("Edit Successful"),
@@ -164,7 +164,7 @@ void AddressBook::submitContact()
} else if (oldAddress != address) {
QMessageBox::information(this, tr("Edit Successful"),
tr("\"%1\" has been edited in your address book.").arg(name));
- contacts[name] = address;
+ contacts[name] = address;
}
}
@@ -192,7 +192,7 @@ void AddressBook::removeContact()
QMessageBox::Yes | QMessageBox::No);
if (button == QMessageBox::Yes) {
-
+
previous();
contacts.remove(name);
@@ -243,7 +243,7 @@ void AddressBook::updateInterface(Mode mode)
currentMode = mode;
switch (currentMode) {
-
+
case AddingMode:
case EditingMode:
diff --git a/examples/widgets/tutorials/addressbook/part4/addressbook.h b/examples/widgets/tutorials/addressbook/part4/addressbook.h
index ff8c4f0318..6430ac3413 100644
--- a/examples/widgets/tutorials/addressbook/part4/addressbook.h
+++ b/examples/widgets/tutorials/addressbook/part4/addressbook.h
@@ -77,10 +77,10 @@ private:
void updateInterface(Mode mode);
//! [updateInterface() declaration]
QPushButton *addButton;
-//! [buttons declaration]
+//! [buttons declaration]
QPushButton *editButton;
QPushButton *removeButton;
-//! [buttons declaration]
+//! [buttons declaration]
QPushButton *submitButton;
QPushButton *cancelButton;
QPushButton *nextButton;
@@ -91,9 +91,9 @@ private:
QMap<QString, QString> contacts;
QString oldName;
QString oldAddress;
-//! [mode declaration]
+//! [mode declaration]
Mode currentMode;
-//! [mode declaration]
+//! [mode declaration]
};
#endif
diff --git a/examples/widgets/tutorials/addressbook/part5/addressbook.cpp b/examples/widgets/tutorials/addressbook/part5/addressbook.cpp
index 90eb81986a..ca2f72e9e1 100644
--- a/examples/widgets/tutorials/addressbook/part5/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook/part5/addressbook.cpp
@@ -81,19 +81,19 @@ AddressBook::AddressBook(QWidget *parent)
connect(editButton, SIGNAL(clicked()), this, SLOT(editContact()));
connect(cancelButton, SIGNAL(clicked()), this, SLOT(cancel()));
connect(removeButton, SIGNAL(clicked()), this, SLOT(removeContact()));
-//! [signals and slots for find]
+//! [signals and slots for find]
connect(findButton, SIGNAL(clicked()), this, SLOT(findContact()));
-//! [signals and slots for find]
+//! [signals and slots for find]
connect(nextButton, SIGNAL(clicked()), this, SLOT(next()));
connect(previousButton, SIGNAL(clicked()), this, SLOT(previous()));
-
+
QVBoxLayout *buttonLayout1 = new QVBoxLayout;
buttonLayout1->addWidget(addButton);
buttonLayout1->addWidget(editButton);
buttonLayout1->addWidget(removeButton);
-//! [adding findButton to layout]
+//! [adding findButton to layout]
buttonLayout1->addWidget(findButton);
-//! [adding findButton to layout]
+//! [adding findButton to layout]
buttonLayout1->addWidget(submitButton);
buttonLayout1->addWidget(cancelButton);
buttonLayout1->addStretch();
@@ -145,7 +145,7 @@ void AddressBook::submitContact()
}
if (currentMode == AddingMode) {
-
+
if (!contacts.contains(name)) {
contacts.insert(name, address);
QMessageBox::information(this, tr("Add Successful"),
@@ -155,7 +155,7 @@ void AddressBook::submitContact()
tr("Sorry, \"%1\" is already in your address book.").arg(name));
}
} else if (currentMode == EditingMode) {
-
+
if (oldName != name) {
if (!contacts.contains(name)) {
QMessageBox::information(this, tr("Edit Successful"),
@@ -196,7 +196,7 @@ void AddressBook::removeContact()
QMessageBox::Yes | QMessageBox::No);
if (button == QMessageBox::Yes) {
-
+
previous();
contacts.remove(name);
@@ -241,7 +241,7 @@ void AddressBook::previous()
nameLine->setText(i.key());
addressText->setText(i.value());
}
-//! [findContact() function]
+//! [findContact() function]
void AddressBook::findContact()
{
dialog->show();
@@ -261,7 +261,7 @@ void AddressBook::findContact()
updateInterface(NavigationMode);
}
-//! [findContact() function]
+//! [findContact() function]
void AddressBook::updateInterface(Mode mode)
{
@@ -288,7 +288,7 @@ void AddressBook::updateInterface(Mode mode)
break;
case NavigationMode:
-
+
if (contacts.isEmpty()) {
nameLine->clear();
addressText->clear();
diff --git a/examples/widgets/tutorials/addressbook/part5/addressbook.h b/examples/widgets/tutorials/addressbook/part5/addressbook.h
index 5e2c18e91a..f8a53304ee 100644
--- a/examples/widgets/tutorials/addressbook/part5/addressbook.h
+++ b/examples/widgets/tutorials/addressbook/part5/addressbook.h
@@ -68,9 +68,9 @@ public slots:
void submitContact();
void cancel();
void removeContact();
-//! [findContact() declaration]
+//! [findContact() declaration]
void findContact();
-//! [findContact() declaration]
+//! [findContact() declaration]
void next();
void previous();
@@ -80,9 +80,9 @@ private:
QPushButton *addButton;
QPushButton *editButton;
QPushButton *removeButton;
-//! [findButton declaration]
+//! [findButton declaration]
QPushButton *findButton;
-//! [findButton declaration]
+//! [findButton declaration]
QPushButton *submitButton;
QPushButton *cancelButton;
QPushButton *nextButton;
@@ -91,9 +91,9 @@ private:
QTextEdit *addressText;
QMap<QString, QString> contacts;
-//! [FindDialog declaration]
+//! [FindDialog declaration]
FindDialog *dialog;
-//! [FindDialog declaration]
+//! [FindDialog declaration]
QString oldName;
QString oldAddress;
Mode currentMode;
diff --git a/examples/widgets/tutorials/addressbook/part6/addressbook.cpp b/examples/widgets/tutorials/addressbook/part6/addressbook.cpp
index a9bc2cc51c..2ced8e2404 100644
--- a/examples/widgets/tutorials/addressbook/part6/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook/part6/addressbook.cpp
@@ -71,9 +71,9 @@ AddressBook::AddressBook(QWidget *parent)
previousButton->setEnabled(false);
loadButton = new QPushButton(tr("&Load..."));
-//! [tooltip 1]
+//! [tooltip 1]
loadButton->setToolTip(tr("Load contacts from a file"));
-//! [tooltip 1]
+//! [tooltip 1]
saveButton = new QPushButton(tr("&Save..."));
//! [tooltip 2]
saveButton->setToolTip(tr("Save contacts to a file"));
@@ -92,7 +92,7 @@ AddressBook::AddressBook(QWidget *parent)
connect(previousButton, SIGNAL(clicked()), this, SLOT(previous()));
connect(loadButton, SIGNAL(clicked()), this, SLOT(loadFromFile()));
connect(saveButton, SIGNAL(clicked()), this, SLOT(saveToFile()));
-
+
QVBoxLayout *buttonLayout1 = new QVBoxLayout;
buttonLayout1->addWidget(addButton);
buttonLayout1->addWidget(editButton);
@@ -151,7 +151,7 @@ void AddressBook::submitContact()
}
if (currentMode == AddingMode) {
-
+
if (!contacts.contains(name)) {
contacts.insert(name, address);
QMessageBox::information(this, tr("Add Successful"),
@@ -161,7 +161,7 @@ void AddressBook::submitContact()
tr("Sorry, \"%1\" is already in your address book.").arg(name));
}
} else if (currentMode == EditingMode) {
-
+
if (oldName != name) {
if (!contacts.contains(name)) {
QMessageBox::information(this, tr("Edit Successful"),
@@ -202,7 +202,7 @@ void AddressBook::removeContact()
QMessageBox::Yes | QMessageBox::No);
if (button == QMessageBox::Yes) {
-
+
previous();
contacts.remove(name);
@@ -296,7 +296,7 @@ void AddressBook::updateInterface(Mode mode)
break;
case NavigationMode:
-
+
if (contacts.isEmpty()) {
nameLine->clear();
addressText->clear();
@@ -341,12 +341,12 @@ void AddressBook::saveToFile()
return;
}
-//! [saveToFile() function part2]
+//! [saveToFile() function part2]
//! [saveToFile() function part3]
QDataStream out(&file);
out.setVersion(QDataStream::Qt_4_5);
out << contacts;
- }
+ }
}
//! [saveToFile() function part3]
@@ -362,15 +362,15 @@ void AddressBook::loadFromFile()
if (fileName.isEmpty())
return;
else {
-
+
QFile file(fileName);
-
+
if (!file.open(QIODevice::ReadOnly)) {
QMessageBox::information(this, tr("Unable to open file"),
file.errorString());
return;
}
-
+
QDataStream in(&file);
in.setVersion(QDataStream::Qt_4_5);
contacts.clear(); // clear existing contacts
diff --git a/examples/widgets/tutorials/addressbook/part6/addressbook.h b/examples/widgets/tutorials/addressbook/part6/addressbook.h
index 99dfd1e404..ce2691ccad 100644
--- a/examples/widgets/tutorials/addressbook/part6/addressbook.h
+++ b/examples/widgets/tutorials/addressbook/part6/addressbook.h
@@ -70,10 +70,10 @@ public slots:
void findContact();
void next();
void previous();
-//! [save and load functions declaration]
+//! [save and load functions declaration]
void saveToFile();
void loadFromFile();
-//! [save and load functions declaration]
+//! [save and load functions declaration]
private:
void updateInterface(Mode mode);
@@ -86,10 +86,10 @@ private:
QPushButton *cancelButton;
QPushButton *nextButton;
QPushButton *previousButton;
-//! [save and load buttons declaration]
+//! [save and load buttons declaration]
QPushButton *loadButton;
QPushButton *saveButton;
-//! [save and load buttons declaration]
+//! [save and load buttons declaration]
QLineEdit *nameLine;
QTextEdit *addressText;
diff --git a/examples/widgets/tutorials/addressbook/part7/addressbook.cpp b/examples/widgets/tutorials/addressbook/part7/addressbook.cpp
index 6ad7630e8d..2060d97d2f 100644
--- a/examples/widgets/tutorials/addressbook/part7/addressbook.cpp
+++ b/examples/widgets/tutorials/addressbook/part7/addressbook.cpp
@@ -93,7 +93,7 @@ AddressBook::AddressBook(QWidget *parent)
connect(loadButton, SIGNAL(clicked()), this, SLOT(loadFromFile()));
connect(saveButton, SIGNAL(clicked()), this, SLOT(saveToFile()));
connect(exportButton, SIGNAL(clicked()), this, SLOT(exportAsVCard()));
-
+
QVBoxLayout *buttonLayout1 = new QVBoxLayout;
buttonLayout1->addWidget(addButton);
buttonLayout1->addWidget(editButton);
@@ -153,7 +153,7 @@ void AddressBook::submitContact()
}
if (currentMode == AddingMode) {
-
+
if (!contacts.contains(name)) {
contacts.insert(name, address);
QMessageBox::information(this, tr("Add Successful"),
@@ -163,7 +163,7 @@ void AddressBook::submitContact()
tr("Sorry, \"%1\" is already in your address book.").arg(name));
}
} else if (currentMode == EditingMode) {
-
+
if (oldName != name) {
if (!contacts.contains(name)) {
QMessageBox::information(this, tr("Edit Successful"),
@@ -204,7 +204,7 @@ void AddressBook::removeContact()
QMessageBox::Yes | QMessageBox::No);
if (button == QMessageBox::Yes) {
-
+
previous();
contacts.remove(name);
@@ -298,7 +298,7 @@ void AddressBook::updateInterface(Mode mode)
break;
case NavigationMode:
-
+
if (contacts.isEmpty()) {
nameLine->clear();
addressText->clear();
@@ -331,7 +331,7 @@ void AddressBook::saveToFile()
QString fileName = QFileDialog::getSaveFileName(this,
tr("Save Address Book"), "",
tr("Address Book (*.abk);;All Files (*)"));
-
+
if (fileName.isEmpty())
return;
else {
@@ -404,14 +404,14 @@ void AddressBook::exportAsVCard()
QString fileName = QFileDialog::getSaveFileName(this,
tr("Export Contact"), "",
tr("vCard Files (*.vcf);;All Files (*)"));
-
+
if (fileName.isEmpty())
return;
QFile file(fileName);
//! [export function part1]
-
-//! [export function part2]
+
+//! [export function part2]
if (!file.open(QIODevice::WriteOnly)) {
QMessageBox::information(this, tr("Unable to open file"),
file.errorString());
@@ -425,12 +425,12 @@ void AddressBook::exportAsVCard()
out << "BEGIN:VCARD" << "\n";
out << "VERSION:2.1" << "\n";
out << "N:" << lastName << ";" << firstName << "\n";
-
- if (!nameList.isEmpty())
+
+ if (!nameList.isEmpty())
out << "FN:" << nameList.join(' ') << "\n";
else
out << "FN:" << firstName << "\n";
-//! [export function part3]
+//! [export function part3]
//! [export function part4]
address.replace(";", "\\;", Qt::CaseInsensitive);
diff --git a/examples/widgets/tutorials/addressbook/part7/addressbook.h b/examples/widgets/tutorials/addressbook/part7/addressbook.h
index a34cf24a23..d672c7a85b 100644
--- a/examples/widgets/tutorials/addressbook/part7/addressbook.h
+++ b/examples/widgets/tutorials/addressbook/part7/addressbook.h
@@ -74,7 +74,7 @@ public slots:
void loadFromFile();
//! [exportAsVCard() declaration]
void exportAsVCard();
-//! [exportAsVCard() declaration]
+//! [exportAsVCard() declaration]
private:
void updateInterface(Mode mode);
@@ -89,9 +89,9 @@ private:
QPushButton *previousButton;
QPushButton *loadButton;
QPushButton *saveButton;
-//! [exportButton declaration]
+//! [exportButton declaration]
QPushButton *exportButton;
-//! [exportButton declaration]
+//! [exportButton declaration]
QLineEdit *nameLine;
QTextEdit *addressText;
diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part3/main.cpp b/examples/widgets/tutorials/gettingStarted/gsQt/part3/main.cpp
index e780986a53..bd0202c967 100644
--- a/examples/widgets/tutorials/gettingStarted/gsQt/part3/main.cpp
+++ b/examples/widgets/tutorials/gettingStarted/gsQt/part3/main.cpp
@@ -67,7 +67,7 @@ Notepad::Notepad()
layout->addWidget(textEdit);
layout->addWidget(quitButton);
- setLayout(layout);
+ setLayout(layout);
setWindowTitle(tr("Notepad"));
}
@@ -79,7 +79,7 @@ void Notepad::quit()
messageBox.setText(tr("Do you really want to quit?"));
messageBox.setStandardButtons(QMessageBox::Yes | QMessageBox::No);
messageBox.setDefaultButton(QMessageBox::No);
- if (messageBox.exec() == QMessageBox::Yes)
+ if (messageBox.exec() == QMessageBox::Yes)
qApp->quit();
}
diff --git a/examples/widgets/tutorials/modelview/5_edit/mymodel.cpp b/examples/widgets/tutorials/modelview/5_edit/mymodel.cpp
index a3567a08ab..317c4760fb 100644
--- a/examples/widgets/tutorials/modelview/5_edit/mymodel.cpp
+++ b/examples/widgets/tutorials/modelview/5_edit/mymodel.cpp
@@ -78,7 +78,7 @@ bool MyModel::setData(const QModelIndex & index, const QVariant & value, int rol
//save value from editor to member m_gridData
m_gridData[index.row()][index.column()] = value.toString();
//for presentation purposes only: build and emit a joined string
- QString result;
+ QString result;
for(int row= 0; row < ROWS; row++)
{
for(int col= 0; col < COLS; col++)
diff --git a/examples/widgets/tutorials/modelview/7_selections/mainwindow.cpp b/examples/widgets/tutorials/modelview/7_selections/mainwindow.cpp
index d969582928..0c1eb290fa 100644
--- a/examples/widgets/tutorials/modelview/7_selections/mainwindow.cpp
+++ b/examples/widgets/tutorials/modelview/7_selections/mainwindow.cpp
@@ -72,7 +72,7 @@ MainWindow::MainWindow(QWidget *parent)
europeItem-> appendRow(italyItem);
italyItem-> appendRow(romeItem);
italyItem-> appendRow(veronaItem);
-
+
//register the model
treeView->setModel(standardModel);
treeView->expandAll();
diff --git a/examples/widgets/widgets.pro b/examples/widgets/widgets.pro
index 768b602e61..726494ffd6 100644
--- a/examples/widgets/widgets.pro
+++ b/examples/widgets/widgets.pro
@@ -19,7 +19,8 @@ SUBDIRS = \
statemachine \
tools \
tutorials \
- widgets
+ widgets \
+ windowcontainer
contains(DEFINES, QT_NO_CURSOR): SUBDIRS -= mainwindows
contains(DEFINES, QT_NO_DRAGANDDROP): SUBDIRS -= draganddrop
diff --git a/examples/widgets/widgets/calculator/button.cpp b/examples/widgets/widgets/calculator/button.cpp
index 70dbd52fca..395f685751 100644
--- a/examples/widgets/widgets/calculator/button.cpp
+++ b/examples/widgets/widgets/calculator/button.cpp
@@ -38,7 +38,7 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QtWidgets>
#include "button.h"
diff --git a/examples/widgets/widgets/codeeditor/codeeditor.cpp b/examples/widgets/widgets/codeeditor/codeeditor.cpp
index 2a7865ce6e..7da0930301 100644
--- a/examples/widgets/widgets/codeeditor/codeeditor.cpp
+++ b/examples/widgets/widgets/codeeditor/codeeditor.cpp
@@ -79,7 +79,7 @@ int CodeEditor::lineNumberAreaWidth()
//![slotUpdateExtraAreaWidth]
void CodeEditor::updateLineNumberAreaWidth(int /* newBlockCount */)
-{
+{
setViewportMargins(lineNumberAreaWidth(), 0, 0, 0);
}
@@ -120,7 +120,7 @@ void CodeEditor::highlightCurrentLine()
if (!isReadOnly()) {
QTextEdit::ExtraSelection selection;
-
+
QColor lineColor = QColor(Qt::yellow).lighter(160);
selection.format.setBackground(lineColor);
diff --git a/examples/widgets/widgets/imageviewer/imageviewer.cpp b/examples/widgets/widgets/imageviewer/imageviewer.cpp
index ef200bc15f..77ec92d57a 100644
--- a/examples/widgets/widgets/imageviewer/imageviewer.cpp
+++ b/examples/widgets/widgets/imageviewer/imageviewer.cpp
@@ -99,7 +99,7 @@ void ImageViewer::print()
//! [5] //! [6]
{
Q_ASSERT(imageLabel->pixmap());
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
//! [6] //! [7]
QPrintDialog dialog(&printer, this);
//! [7] //! [8]
diff --git a/examples/widgets/widgets/lineedits/window.cpp b/examples/widgets/widgets/lineedits/window.cpp
index 0749e8d4fd..a0871e7c77 100644
--- a/examples/widgets/widgets/lineedits/window.cpp
+++ b/examples/widgets/widgets/lineedits/window.cpp
@@ -55,6 +55,7 @@ Window::Window()
echoComboBox->addItem(tr("No Echo"));
echoLineEdit = new QLineEdit;
+ echoLineEdit->setPlaceholderText("Placeholder Text");
echoLineEdit->setFocus();
//! [0]
@@ -68,6 +69,7 @@ Window::Window()
validatorComboBox->addItem(tr("Double validator"));
validatorLineEdit = new QLineEdit;
+ validatorLineEdit->setPlaceholderText("Placeholder Text");
//! [1]
//! [2]
@@ -80,6 +82,7 @@ Window::Window()
alignmentComboBox->addItem(tr("Right"));
alignmentLineEdit = new QLineEdit;
+ alignmentLineEdit->setPlaceholderText("Placeholder Text");
//! [2]
//! [3]
@@ -93,6 +96,7 @@ Window::Window()
inputMaskComboBox->addItem(tr("License key"));
inputMaskLineEdit = new QLineEdit;
+ inputMaskLineEdit->setPlaceholderText("Placeholder Text");
//! [3]
//! [4]
@@ -104,6 +108,7 @@ Window::Window()
accessComboBox->addItem(tr("True"));
accessLineEdit = new QLineEdit;
+ accessLineEdit->setPlaceholderText("Placeholder Text");
//! [4]
//! [5]
diff --git a/examples/widgets/widgets/scribble/scribblearea.cpp b/examples/widgets/widgets/scribble/scribblearea.cpp
index 2492476d38..4028263e69 100644
--- a/examples/widgets/widgets/scribble/scribblearea.cpp
+++ b/examples/widgets/widgets/scribble/scribblearea.cpp
@@ -200,9 +200,9 @@ void ScribbleArea::resizeImage(QImage *image, const QSize &newSize)
//! [21]
void ScribbleArea::print()
{
-#ifndef QT_NO_PRINTER
+#if !defined(QT_NO_PRINTER) && !defined(QT_NO_PRINTDIALOG)
QPrinter printer(QPrinter::HighResolution);
-
+
QPrintDialog printDialog(&printer, this);
//! [21] //! [22]
if (printDialog.exec() == QDialog::Accepted) {
diff --git a/examples/widgets/widgets/styles/widgetgallery.cpp b/examples/widgets/widgets/styles/widgetgallery.cpp
index 604f5af40b..4421bd19c4 100644
--- a/examples/widgets/widgets/styles/widgetgallery.cpp
+++ b/examples/widgets/widgets/styles/widgetgallery.cpp
@@ -215,7 +215,7 @@ void WidgetGallery::createBottomLeftTabWidget()
"Like a diamond in the sky.\n"
"Twinkle, twinkle, little star,\n"
"How I wonder what you are!\n"));
-
+
QHBoxLayout *tab2hbox = new QHBoxLayout;
tab2hbox->setMargin(5);
tab2hbox->addWidget(textEdit);
diff --git a/examples/widgets/widgets/styles/widgetgallery.h b/examples/widgets/widgets/styles/widgetgallery.h
index 27e82c4d14..25d4c5881d 100644
--- a/examples/widgets/widgets/styles/widgetgallery.h
+++ b/examples/widgets/widgets/styles/widgetgallery.h
@@ -83,7 +83,7 @@ private:
void createProgressBar();
QPalette originalPalette;
-
+
QLabel *styleLabel;
QComboBox *styleComboBox;
QCheckBox *useStylePaletteCheckBox;
diff --git a/examples/widgets/windowcontainer/windowcontainer.cpp b/examples/widgets/windowcontainer/windowcontainer.cpp
new file mode 100644
index 0000000000..42523a53d0
--- /dev/null
+++ b/examples/widgets/windowcontainer/windowcontainer.cpp
@@ -0,0 +1,170 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the examples 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$
+**
+****************************************************************************/
+
+#include "openglwindow.h"
+
+#include <QPainter>
+#include <QMouseEvent>
+#include <QKeyEvent>
+#include <QFocusEvent>
+
+#include <QApplication>
+#include <QWidget>
+#include <QHBoxLayout>
+#include <QLineEdit>
+
+
+
+// Making use of the class from the opengl example in gui.
+class Window : public OpenGLWindow
+{
+ Q_OBJECT
+public:
+ Window()
+ : m_mouseDown(false)
+ , m_focus(false)
+ {
+ }
+
+ void render(QPainter *p) {
+ QLinearGradient g(0, 0, 0, height());
+ g.setColorAt(0, QColor("lightsteelblue"));
+ g.setColorAt(1, Qt::black);
+ p->fillRect(0, 0, width(), height(), g);
+
+ p->setPen(Qt::white);
+
+ p->drawText(20, 30, QLatin1String("This is an OpenGL based QWindow"));
+
+ if (m_key.trimmed().length() > 0) {
+ QRect bounds = p->boundingRect(QRect(0, 0, width(), height()), Qt::AlignTop | Qt::AlignLeft, m_key);
+ p->save();
+ p->translate(width() / 2.0, height() / 2.0);
+ p->scale(10, 10);
+ p->translate(-bounds.width() / 2.0, -bounds.height() / 2.0);
+ p->drawText(bounds, Qt::AlignCenter, m_key);
+ p->restore();
+ }
+
+ if (m_focus) {
+ p->drawText(20, height() - 20, QLatin1String("Window has focus!"));
+ }
+
+ p->setRenderHint(QPainter::Antialiasing);
+ p->drawPolyline(m_polygon);
+ }
+
+ void mousePressEvent(QMouseEvent *e) {
+ m_mouseDown = true;
+ m_polygon.clear();
+ m_polygon.append(e->pos());
+ renderLater();
+ }
+
+ void mouseMoveEvent(QMouseEvent *e) {
+ if (m_mouseDown) {
+ m_polygon.append(e->pos());
+ renderLater();
+ }
+ }
+
+ void mouseReleaseEvent(QMouseEvent *e) {
+ m_mouseDown = false;
+ m_polygon.append(e->pos());
+ renderLater();
+ }
+
+ void focusInEvent(QFocusEvent *) {
+ m_focus = true;
+ renderLater();
+ }
+
+ void focusOutEvent(QFocusEvent *) {
+ m_focus = false;
+ m_polygon.clear();
+ renderLater();
+ }
+
+ void keyPressEvent(QKeyEvent *e) {
+ m_key = e->text();
+ renderLater();
+ }
+
+ void keyReleaseEvent(QKeyEvent *) {
+ m_key = QString();
+ renderLater();
+ }
+private:
+ QPolygon m_polygon;
+ bool m_mouseDown;
+
+ bool m_focus;
+
+ QString m_key;
+};
+
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QWidget *widget = new QWidget;
+ QHBoxLayout *layout = new QHBoxLayout(widget);
+
+ Window *window = new Window();
+
+ QWidget *container = QWidget::createWindowContainer(window);
+ container->setMinimumSize(300, 300);
+ container->setMaximumSize(600, 600);
+ container->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
+ container->setFocusPolicy(Qt::StrongFocus);
+
+ window->setGeometry(100, 100, 300, 200);
+
+ layout->addWidget(new QLineEdit(QLatin1String("A QLineEdit")));
+ layout->addWidget(container);
+ layout->addWidget(new QLineEdit(QLatin1String("A QLabel")));
+
+ widget->show();
+
+ return app.exec();
+}
+
+#include "windowcontainer.moc"
diff --git a/examples/widgets/windowcontainer/windowcontainer.pro b/examples/widgets/windowcontainer/windowcontainer.pro
new file mode 100644
index 0000000000..9ac7e4a5ab
--- /dev/null
+++ b/examples/widgets/windowcontainer/windowcontainer.pro
@@ -0,0 +1,9 @@
+SOURCES = windowcontainer.cpp
+
+QT += widgets
+
+# install
+target.path = $$[QT_INSTALL_EXAMPLES]/widgets/windowcontainer
+INSTALLS += target
+
+include(../../gui/openglwindow/openglwindow.pri)
diff --git a/examples/xml/xml.pro b/examples/xml/xml.pro
index bc8686a475..72bf95b2ea 100644
--- a/examples/xml/xml.pro
+++ b/examples/xml/xml.pro
@@ -4,7 +4,9 @@ SUBDIRS = htmlinfo \
qtHaveModule(widgets) {
SUBDIRS += dombookmarks \
- rsslisting \
saxbookmarks \
streambookmarks
+
+ qtHaveModule(network): SUBDIRS += \
+ rsslisting
}
diff --git a/mkspecs/aix-g++-64/qmake.conf b/mkspecs/aix-g++-64/qmake.conf
index a1e9bd5903..25acf04eda 100644
--- a/mkspecs/aix-g++-64/qmake.conf
+++ b/mkspecs/aix-g++-64/qmake.conf
@@ -2,66 +2,65 @@
# qmake configuration for aix-g++-64
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = aix
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = aix
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -maix64
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB =
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD = -D_THREAD_SAFE
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -maix64
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB =
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -D_THREAD_SAFE
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = /usr/X11R6/include
-QMAKE_LIBDIR_X11 = /usr/X11R6/lib
-QMAKE_INCDIR_OPENGL = /usr/X11R6/include
-QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = /usr/X11R6/include
+QMAKE_LIBDIR_X11 = /usr/X11R6/lib
+QMAKE_INCDIR_OPENGL = /usr/X11R6/include
+QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS = -maix64
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME =
-QMAKE_LFLAGS_THREAD = -L/usr/lib/threads
-QMAKE_LFLAGS_NOUNDEF =
-QMAKE_AIX_SHLIB = 1
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS = -maix64
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME =
+QMAKE_LFLAGS_THREAD = -L/usr/lib/threads
+QMAKE_LFLAGS_NOUNDEF =
+QMAKE_AIX_SHLIB = 1
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthreads
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthreads
QMAKE_AR = ar -X64 cq
QMAKE_OBJCOPY = objcopy
diff --git a/mkspecs/aix-g++/qmake.conf b/mkspecs/aix-g++/qmake.conf
index 5f7b8b44d3..94dbbd12ef 100644
--- a/mkspecs/aix-g++/qmake.conf
+++ b/mkspecs/aix-g++/qmake.conf
@@ -2,70 +2,69 @@
# qmake configuration for aix-g++
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = aix
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = aix
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -mpowerpc
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB =
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD = -D_THREAD_SAFE
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -mpowerpc
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB =
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -D_THREAD_SAFE
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = /usr/X11R6/include
-QMAKE_LIBDIR_X11 = /usr/X11R6/lib
-QMAKE_INCDIR_OPENGL = /usr/X11R6/include
-QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = /usr/X11R6/include
+QMAKE_LIBDIR_X11 = /usr/X11R6/lib
+QMAKE_INCDIR_OPENGL = /usr/X11R6/include
+QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME =
-QMAKE_LFLAGS_THREAD = -L/usr/lib/threads
-QMAKE_LFLAGS_NOUNDEF =
-QMAKE_AIX_SHLIB = 1
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME =
+QMAKE_LFLAGS_THREAD = -L/usr/lib/threads
+QMAKE_LFLAGS_NOUNDEF =
+QMAKE_AIX_SHLIB = 1
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthreads
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthreads
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/aix-xlc-64/qmake.conf b/mkspecs/aix-xlc-64/qmake.conf
index a0d4ba0ef5..d4b9718d74 100644
--- a/mkspecs/aix-xlc-64/qmake.conf
+++ b/mkspecs/aix-xlc-64/qmake.conf
@@ -2,69 +2,68 @@
# qmake configuration for aix-xlc
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = aix
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = aix
-QMAKE_COMPILER = ibm_xlc
+QMAKE_COMPILER = ibm_xlc
-QMAKE_CC = xlc
-QMAKE_CC_THREAD = xlc_r
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -qstrict -q64
+QMAKE_CC = xlc
+QMAKE_CC_THREAD = xlc_r
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -qstrict -q64
QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF =
-QMAKE_CFLAGS_RELEASE = -O3
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB =
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_WARN_OFF =
+QMAKE_CFLAGS_RELEASE = -O3
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB =
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC =
QMAKE_CFLAGS_THREAD = -qthreaded -qtls
-QMAKE_CXX = xlC
-QMAKE_CXX_THREAD = xlC_r
-QMAKE_CXXFLAGS = -+ $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = xlC
+QMAKE_CXX_THREAD = xlC_r
+QMAKE_CXXFLAGS = -+ $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_COMPILER_DEFINES += __xlC__
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_COMPILER_DEFINES += __xlC__
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = xlC
-QMAKE_LINK_THREAD = xlC_r
-QMAKE_LINK_SHLIB = ld
-QMAKE_LFLAGS = -q64 -bbigtoc
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -qmkshrobj
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME =
-QMAKE_LFLAGS_THREAD = -L/usr/lib/threads
-QMAKE_AIX_SHLIB = 1
+QMAKE_LINK = xlC
+QMAKE_LINK_THREAD = xlC_r
+QMAKE_LINK_SHLIB = ld
+QMAKE_LFLAGS = -q64 -bbigtoc
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -qmkshrobj
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME =
+QMAKE_LFLAGS_THREAD = -L/usr/lib/threads
+QMAKE_AIX_SHLIB = 1
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthreads
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthreads
-QMAKE_AR = ar -X64 cq
+QMAKE_AR = ar -X64 cq
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB = ranlib -X64
+QMAKE_RANLIB = ranlib -X64
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/aix-xlc/qmake.conf b/mkspecs/aix-xlc/qmake.conf
index 8ea3d57299..adcac80ea1 100644
--- a/mkspecs/aix-xlc/qmake.conf
+++ b/mkspecs/aix-xlc/qmake.conf
@@ -2,70 +2,69 @@
# qmake configuration for aix-xlc
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = aix
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = aix
-QMAKE_COMPILER = ibm_xlc
+QMAKE_COMPILER = ibm_xlc
-QMAKE_CC = xlc
-QMAKE_CC_THREAD = xlc_r
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -qstrict
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF =
-QMAKE_CFLAGS_RELEASE = -O3
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB =
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC =
-QMAKE_CFLAGS_THREAD = -qthreaded -qtls
+QMAKE_CC = xlc
+QMAKE_CC_THREAD = xlc_r
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -qstrict
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF =
+QMAKE_CFLAGS_RELEASE = -O3
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB =
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_THREAD = -qthreaded -qtls
-QMAKE_CXX = xlC
-QMAKE_CXX_THREAD = xlC_r
-QMAKE_CXXFLAGS = -+ $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = xlC
+QMAKE_CXX_THREAD = xlC_r
+QMAKE_CXXFLAGS = -+ $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_COMPILER_DEFINES += __xlC__
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_COMPILER_DEFINES += __xlC__
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = xlC
-QMAKE_LINK_THREAD = xlC_r
-QMAKE_LINK_SHLIB = ld
-QMAKE_LFLAGS = -bmaxdata:0x80000000
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -qmkshrobj
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME =
-QMAKE_LFLAGS_THREAD = -L/usr/lib/threads
-QMAKE_LFLAGS_NOUNDEF =
-QMAKE_AIX_SHLIB = 1
+QMAKE_LINK = xlC
+QMAKE_LINK_THREAD = xlC_r
+QMAKE_LINK_SHLIB = ld
+QMAKE_LFLAGS = -bmaxdata:0x80000000
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -qmkshrobj
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME =
+QMAKE_LFLAGS_THREAD = -L/usr/lib/threads
+QMAKE_LFLAGS_NOUNDEF =
+QMAKE_AIX_SHLIB = 1
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthreads
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthreads
-QMAKE_AR = ar cq
+QMAKE_AR = ar cq
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB = ranlib
+QMAKE_RANLIB = ranlib
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/android-g++/qmake.conf b/mkspecs/android-g++/qmake.conf
new file mode 100644
index 0000000000..e12bb03560
--- /dev/null
+++ b/mkspecs/android-g++/qmake.conf
@@ -0,0 +1,178 @@
+# qmake configuration for building with android-g++
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = android
+QMAKE_COMPILER = gcc
+
+CONFIG += android_install
+DEFINES += QT_NO_PRINTDIALOG
+
+include(../qdevice.pri)
+include(../common/linux.conf)
+include(../common/gcc-base-unix.conf)
+
+# Passing in -win32 to qmake (from NQTC) causes this condition to pass, however
+# qmake complains that -win32 is deprecated; should find another way, Q_OS_WIN
+# should really be all QMAKE_HOST.os needs to depend on?
+contains(QMAKE_HOST.os,Windows) {
+ # Not having sh.exe in your path causes this condition to pass
+ # To build Android Qt on Windows, this block must not be evaluated.
+ isEmpty(QMAKE_SH) {
+ include(../common/shell-win32.conf)
+ QMAKE_DEL_TREE = rmdir /s /q
+ QMAKE_INSTALL_FILE = copy /y
+ QMAKE_INSTALL_PROGRAM = copy /y
+ }
+}
+
+NDK_ROOT = $$(ANDROID_NDK_ROOT)
+!exists($$NDK_ROOT) {
+ NDK_ROOT = $$DEFAULT_ANDROID_NDK_ROOT
+ !exists($$NDK_ROOT): error("You need to set the ANDROID_NDK_ROOT environment variable to point to your Android NDK.")
+}
+
+NDK_HOST = $$(ANDROID_NDK_HOST)
+isEmpty(NDK_HOST): NDK_HOST = $$DEFAULT_ANDROID_NDK_HOST
+
+ANDROID_PLATFORM = $$(ANDROID_NDK_PLATFORM)
+isEmpty(ANDROID_PLATFORM): ANDROID_PLATFORM = $$DEFAULT_ANDROID_PLATFORM
+
+ANDROID_TARGET_ARCH = $$(ANDROID_TARGET_ARCH)
+isEmpty(ANDROID_TARGET_ARCH): ANDROID_TARGET_ARCH = $$DEFAULT_ANDROID_TARGET_ARCH
+
+NDK_TOOLCHAIN_PREFIX = $$(ANDROID_NDK_TOOLCHAIN_PREFIX)
+isEmpty(NDK_TOOLCHAIN_PREFIX) {
+ equals(ANDROID_TARGET_ARCH, x86): NDK_TOOLCHAIN_PREFIX = x86
+ else: equals(ANDROID_TARGET_ARCH, mips): NDK_TOOLCHAIN_PREFIX = mipsel-linux-android
+ else: NDK_TOOLCHAIN_PREFIX = arm-linux-androideabi
+}
+
+NDK_TOOLS_PREFIX = $$(ANDROID_NDK_TOOLS_PREFIX)
+isEmpty(NDK_TOOLS_PREFIX) {
+ equals(ANDROID_TARGET_ARCH, x86): NDK_TOOLS_PREFIX = i686-linux-android
+ else: equals(ANDROID_TARGET_ARCH, mips): NDK_TOOLS_PREFIX = mipsel-linux-android
+ else: NDK_TOOLS_PREFIX = arm-linux-androideabi
+}
+
+NDK_TOOLCHAIN_VERSION = $$(ANDROID_NDK_TOOLCHAIN_VERSION)
+isEmpty(NDK_TOOLCHAIN_VERSION): NDK_TOOLCHAIN_VERSION = $$DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION
+
+equals(ANDROID_TARGET_ARCH, x86): ANDROID_ARCHITECTURE = x86
+else: equals(ANDROID_TARGET_ARCH, mips): ANDROID_ARCHITECTURE = mips
+else: ANDROID_ARCHITECTURE = arm
+
+!equals(NDK_TOOLCHAIN_VERSION, 4.4.3): ANDROID_CXXSTL_SUFFIX = -$$NDK_TOOLCHAIN_VERSION
+
+NDK_TOOLCHAIN = $$NDK_TOOLCHAIN_PREFIX-$$NDK_TOOLCHAIN_VERSION
+NDK_TOOLCHAIN_PATH = $$NDK_ROOT/toolchains/$$NDK_TOOLCHAIN/prebuilt/$$NDK_HOST
+
+CONFIG += $$ANDROID_PLATFORM
+ANDROID_PLATFORM_ROOT_PATH = $$NDK_ROOT/platforms/$$ANDROID_PLATFORM/arch-$$ANDROID_ARCHITECTURE/
+ANDROID_PLATFORM_PATH = $$ANDROID_PLATFORM_ROOT_PATH/usr
+
+# used to compile platform plugins for android-4 and android-5
+QMAKE_ANDROID_PLATFORM_INCDIR = $$NDK_ROOT/platforms/$$ANDROID_PLATFORM/arch-$$ANDROID_ARCHITECTURE/usr/include
+QMAKE_ANDROID_PLATFORM_LIBDIR = $$NDK_ROOT/platforms/$$ANDROID_PLATFORM/arch-$$ANDROID_ARCHITECTURE/usr/lib
+
+ANDROID_SOURCES_CXX_STL_LIBDIR = $$NDK_ROOT/sources/cxx-stl/gnu-libstdc++/$$NDK_TOOLCHAIN_VERSION/libs/$$ANDROID_TARGET_ARCH
+ANDROID_SOURCES_CXX_STL_INCDIR = $$NDK_ROOT/sources/cxx-stl/gnu-libstdc++/$$NDK_TOOLCHAIN_VERSION/include $$ANDROID_SOURCES_CXX_STL_LIBDIR/include
+
+# modifications to g++.conf
+QMAKE_CC = $$NDK_TOOLCHAIN_PATH/bin/$$NDK_TOOLS_PREFIX-gcc
+
+equals(ANDROID_TARGET_ARCH, armeabi-v7a): \
+ QMAKE_CFLAGS = -Wno-psabi -march=armv7-a -mfloat-abi=softfp -mfpu=vfp -ffunction-sections -funwind-tables -fstack-protector -fno-short-enums -DANDROID -Wa,--noexecstack
+else: equals(ANDROID_TARGET_ARCH, armeabi): \
+ QMAKE_CFLAGS = -Wno-psabi -march=armv5te -mtune=xscale -msoft-float -ffunction-sections -funwind-tables -fstack-protector -fno-short-enums -DANDROID -Wa,--noexecstack
+else: equals(ANDROID_TARGET_ARCH, x86): \
+ QMAKE_CFLAGS = -ffunction-sections -funwind-tables -O2 -fomit-frame-pointer -fstrict-aliasing -funswitch-loops -finline-limit=300 -DANDROID -Wa,--noexecstack
+else: equals(ANDROID_TARGET_ARCH, mips): \
+ QMAKE_CFLAGS = -fno-strict-aliasing -finline-functions -ffunction-sections -funwind-tables -fmessage-length=0 -fno-inline-functions-called-once -fgcse-after-reload -frerun-cse-after-loop -frename-registers -O2 -fomit-frame-pointer -funswitch-loops -finline-limit=300 -DANDROID -Wa,--noexecstack
+
+QMAKE_CFLAGS_WARN_ON = -Wall -Wno-psabi -W
+QMAKE_CFLAGS_WARN_OFF = -Wno-psabi
+equals(ANDROID_TARGET_ARCH, x86) {
+ QMAKE_CFLAGS_RELEASE = -O2
+ QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO = -g -O2
+ QMAKE_CFLAGS_DEBUG = -g
+} else: equals(ANDROID_TARGET_ARCH, mips) {
+ QMAKE_CFLAGS_RELEASE = -O2
+ QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO = -g -O2
+ QMAKE_CFLAGS_DEBUG = -g -fno-omit-frame-pointer
+} else { # arm
+ QMAKE_CFLAGS_RELEASE = -mthumb -Os -fomit-frame-pointer -fno-strict-aliasing -finline-limit=64
+ QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO = -g -mthumb -Os -fomit-frame-pointer -fno-strict-aliasing -finline-limit=64
+ QMAKE_CFLAGS_DEBUG = -g -marm -O0 -fno-omit-frame-pointer
+}
+
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -D_REENTRANT
+QMAKE_CFLAGS_HIDESYMS = -fvisibility=hidden
+
+QMAKE_CXX = $$NDK_TOOLCHAIN_PATH/bin/$$NDK_TOOLS_PREFIX-g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -std=gnu++0x
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_RELEASE_WITH_DEBUGINFO += $$QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO
+QMAKE_CXXFLAGS_DEBUG += $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_HIDESYMS = $$QMAKE_CFLAGS_HIDESYMS -fvisibility-inlines-hidden
+
+QMAKE_LINK = $$QMAKE_CXX
+QMAKE_LINK_SHLIB = $$QMAKE_LINK
+
+# modifications to linux.conf
+QMAKE_AR = $$NDK_TOOLCHAIN_PATH/bin/$$NDK_TOOLS_PREFIX-ar cqs
+QMAKE_OBJCOPY = $$NDK_TOOLCHAIN_PATH/bin/$$NDK_TOOLS_PREFIX-objcopy
+
+QMAKE_STRIP =
+#$$NDK_TOOLCHAIN_PATH/bin/$$NDK_TOOLS_PREFIX-strip
+
+QMAKE_RANLIB = $$NDK_TOOLCHAIN_PATH/bin/$$NDK_TOOLS_PREFIX-ranlib
+
+QMAKE_INCDIR = $$ANDROID_SOURCES_CXX_STL_INCDIR $$ANDROID_PLATFORM_PATH/include
+QMAKE_LIBDIR = $$ANDROID_SOURCES_CXX_STL_LIBDIR $$ANDROID_PLATFORM_PATH/lib $$LIBGCC_PATH
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL = $$ANDROID_PLATFORM_PATH/include
+QMAKE_LIBDIR_OPENGL = $$ANDROID_PLATFORM_PATH/lib
+
+equals(ANDROID_TARGET_ARCH, x86)|equals(ANDROID_TARGET_ARCH, mips): \
+ LIBGCC_PATH_FULL = $$system("$$QMAKE_CC -print-libgcc-file-name")
+else: \
+ LIBGCC_PATH_FULL = $$system("$$QMAKE_CC -mthumb-interwork -print-libgcc-file-name")
+
+LIBGCC_PATH = $$dirname(LIBGCC_PATH_FULL)
+
+QMAKE_LINK = $$QMAKE_CXX
+QMAKE_LINK_SHLIB = $$QMAKE_CXX
+QMAKE_LFLAGS = --sysroot=$$ANDROID_PLATFORM_ROOT_PATH
+QMAKE_RPATHLINK = $$ANDROID_PLATFORM_PATH/lib
+QMAKE_LFLAGS_APP = -Wl,--no-undefined -Wl,-z,noexecstack -shared
+QMAKE_LFLAGS_SHLIB = -Wl,--no-undefined -Wl,-z,noexecstack -shared
+
+contains(NDK_ROOT, ".*r6")|contains(NDK_ROOT, ".*r5.*") {
+ !equals(ANDROID_PLATFORM, android-4):!equals(ANDROID_PLATFORM, android-5):!equals(ANDROID_PLATFORM, android-8) {
+ warning("Your NDK version is outdated. A workaround is enabled. Consider updating your NDK (workarounds are required until r6(a))")
+ QMAKE_LFLAGS_SHLIB += $$ANDROID_PLATFORM_PATH/lib/crtbegin_so.o $$ANDROID_PLATFORM_PATH/lib/crtend_so.o
+ }
+}
+
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME =
+QMAKE_LFLAGS_NOUNDEF = -Wl,--no-undefined
+QMAKE_LFLAGS_RPATH = -Wl,-rpath=
+QMAKE_LFLAGS_RPATHLINK = -Wl,-rpath-link=
+
+QMAKE_LIBS = -lgnustl_shared -lsupc++ -llog -lz -lm -ldl -lc -lgcc
+QMAKE_LIBS_X11 =
+QMAKE_LIBS_THREAD =
+QMAKE_LIBS_EGL = -lEGL
+QMAKE_LIBS_OPENGL =
+QMAKE_LIBS_OPENGL_ES1 = -lGLESv1_CM
+QMAKE_LIBS_OPENGL_ES2 = -lGLESv2 $$QMAKE_LIBS
+
+load(qt_config)
diff --git a/mkspecs/android-g++/qplatformdefs.h b/mkspecs/android-g++/qplatformdefs.h
new file mode 100644
index 0000000000..0acd19ea5d
--- /dev/null
+++ b/mkspecs/android-g++/qplatformdefs.h
@@ -0,0 +1,187 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the qmake spec of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QPLATFORMDEFS_H
+#define QPLATFORMDEFS_H
+
+#define QT_QPA_DEFAULT_PLATFORM_NAME "android"
+
+// Get Qt defines/settings
+
+#include "qglobal.h"
+
+// Set any POSIX/XOPEN defines at the top of this file to turn on specific APIs
+
+// 1) need to reset default environment if _BSD_SOURCE is defined
+// 2) need to specify POSIX thread interfaces explicitly in glibc 2.0
+// 3) it seems older glibc need this to include the X/Open stuff
+
+#include <unistd.h>
+
+// We are hot - unistd.h should have turned on the specific APIs we requested
+
+#include <features.h>
+#include <pthread.h>
+#include <dirent.h>
+#include <fcntl.h>
+#include <grp.h>
+#include <pwd.h>
+#include <signal.h>
+#include <dlfcn.h>
+
+#include <sys/types.h>
+#include <sys/ioctl.h>
+#include <sys/ipc.h>
+#include <sys/time.h>
+#include <sys/stat.h>
+#include <sys/wait.h>
+
+#ifndef QT_NO_IPV6IFNAME
+#include <net/if.h>
+#endif
+
+#ifndef _GNU_SOURCE
+# define _GNU_SOURCE
+#endif
+
+#ifdef QT_LARGEFILE_SUPPORT
+#define QT_STATBUF struct stat64
+#define QT_STATBUF4TSTAT struct stat64
+#define QT_STAT ::stat64
+#define QT_FSTAT ::fstat64
+#define QT_LSTAT ::lstat64
+#define QT_OPEN ::open64
+#define QT_TRUNCATE ::truncate64
+#define QT_FTRUNCATE ::ftruncate64
+#define QT_LSEEK ::lseek64
+#else
+#define QT_STATBUF struct stat
+#define QT_STATBUF4TSTAT struct stat
+#define QT_STAT ::stat
+#define QT_FSTAT ::fstat
+#define QT_LSTAT ::lstat
+#define QT_OPEN ::open
+#define QT_TRUNCATE ::truncate
+#define QT_FTRUNCATE ::ftruncate
+#define QT_LSEEK ::lseek
+#endif
+
+#ifdef QT_LARGEFILE_SUPPORT
+#define QT_FOPEN ::fopen64
+#define QT_FSEEK ::fseeko64
+#define QT_FTELL ::ftello64
+#define QT_FGETPOS ::fgetpos64
+#define QT_FSETPOS ::fsetpos64
+#define QT_MMAP ::mmap64
+#define QT_FPOS_T fpos64_t
+#define QT_OFF_T off64_t
+#else
+#define QT_FOPEN ::fopen
+#define QT_FSEEK ::fseek
+#define QT_FTELL ::ftell
+#define QT_FGETPOS ::fgetpos
+#define QT_FSETPOS ::fsetpos
+#define QT_MMAP ::mmap
+#define QT_FPOS_T fpos_t
+#define QT_OFF_T long
+#endif
+
+#define QT_STAT_REG S_IFREG
+#define QT_STAT_DIR S_IFDIR
+#define QT_STAT_MASK S_IFMT
+#define QT_STAT_LNK S_IFLNK
+#define QT_SOCKET_CONNECT ::connect
+#define QT_SOCKET_BIND ::bind
+#define QT_FILENO fileno
+#define QT_CLOSE ::close
+#define QT_READ ::read
+#define QT_WRITE ::write
+#define QT_ACCESS ::access
+#define QT_GETCWD ::getcwd
+#define QT_CHDIR ::chdir
+#define QT_MKDIR ::mkdir
+#define QT_RMDIR ::rmdir
+#define QT_OPEN_LARGEFILE O_LARGEFILE
+#define QT_OPEN_RDONLY O_RDONLY
+#define QT_OPEN_WRONLY O_WRONLY
+#define QT_OPEN_RDWR O_RDWR
+#define QT_OPEN_CREAT O_CREAT
+#define QT_OPEN_TRUNC O_TRUNC
+#define QT_OPEN_APPEND O_APPEND
+
+// Directory iteration
+#define QT_DIR DIR
+
+#define QT_OPENDIR ::opendir
+#define QT_CLOSEDIR ::closedir
+
+#if defined(QT_LARGEFILE_SUPPORT) \
+ && defined(QT_USE_XOPEN_LFS_EXTENSIONS) \
+ && !defined(QT_NO_READDIR64)
+#define QT_DIRENT struct dirent64
+#define QT_READDIR ::readdir64
+#define QT_READDIR_R ::readdir64_r
+#else
+#define QT_DIRENT struct dirent
+#define QT_READDIR ::readdir
+#define QT_READDIR_R ::readdir_r
+#endif
+
+#define QT_SOCKET_CONNECT ::connect
+#define QT_SOCKET_BIND ::bind
+
+
+#define QT_SIGNAL_RETTYPE void
+#define QT_SIGNAL_ARGS int
+#define QT_SIGNAL_IGNORE SIG_IGN
+
+#if defined(__GLIBC__) && (__GLIBC__ >= 2)
+#define QT_SOCKLEN_T socklen_t
+#else
+#define QT_SOCKLEN_T int
+#endif
+
+#if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500)
+#define QT_SNPRINTF ::snprintf
+#define QT_VSNPRINTF ::vsnprintf
+#endif
+
+#endif // QPLATFORMDEFS_H
diff --git a/mkspecs/blackberry-armv7le-qcc/qmake.conf b/mkspecs/blackberry-armv7le-qcc/qmake.conf
index 45883b05ec..2e24e4e0d3 100644
--- a/mkspecs/blackberry-armv7le-qcc/qmake.conf
+++ b/mkspecs/blackberry-armv7le-qcc/qmake.conf
@@ -15,7 +15,7 @@ contains(QT_CONFIG, stack-protector-strong) {
QMAKE_CFLAGS += -fstack-protector -fstack-protector-all
}
-QMAKE_CFLAGS += -mcpu=cortex-a9
+QMAKE_CFLAGS += -mcpu=cortex-a9 -mtune=cortex-a9 -mthumb -D_FORTIFY_SOURCE=2
QMAKE_LFLAGS_SHLIB += -Wl,-z,relro -Wl,-z,now
diff --git a/mkspecs/common/armcc.conf b/mkspecs/common/armcc.conf
index 443ff40db4..a52fefc106 100644
--- a/mkspecs/common/armcc.conf
+++ b/mkspecs/common/armcc.conf
@@ -2,41 +2,41 @@
# qmake configuration for armcc
#
-QMAKE_COMPILER = armcc
+QMAKE_COMPILER = armcc
-CONFIG += rvct_linker
-QMAKE_CC = armcc
-QMAKE_CFLAGS +=
-QMAKE_CFLAGS_DEPS += -M
-QMAKE_CFLAGS_WARN_ON +=
-QMAKE_CFLAGS_WARN_OFF += -W
-QMAKE_CFLAGS_RELEASE += -O2
-QMAKE_CFLAGS_DEBUG += -g -O0
-QMAKE_CFLAGS_HIDESYMS += --visibility_inlines_hidden
+CONFIG += rvct_linker
+QMAKE_CC = armcc
+QMAKE_CFLAGS +=
+QMAKE_CFLAGS_DEPS += -M
+QMAKE_CFLAGS_WARN_ON +=
+QMAKE_CFLAGS_WARN_OFF += -W
+QMAKE_CFLAGS_RELEASE += -O2
+QMAKE_CFLAGS_DEBUG += -g -O0
+QMAKE_CFLAGS_HIDESYMS += --visibility_inlines_hidden
-QMAKE_CXX = armcc
-QMAKE_CXXFLAGS += $$QMAKE_CFLAGS --exceptions --exceptions_unwind
-QMAKE_CXXFLAGS_DEPS += $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON += $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF += $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG += $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB += $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = armcc
+QMAKE_CXXFLAGS += $$QMAKE_CFLAGS --exceptions --exceptions_unwind
+QMAKE_CXXFLAGS_DEPS += $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON += $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF += $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG += $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB += $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB += $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC += $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_YACC += $$QMAKE_CFLAGS_YACC
QMAKE_CXXFLAGS_HIDESYMS += $$QMAKE_CFLAGS_HIDESYMS
-QMAKE_LINK = armlink
-QMAKE_LINK_SHLIB = armlink
-QMAKE_LINK_C = armlink
-QMAKE_LINK_C_SHLIB = armlink
-QMAKE_LFLAGS +=
-QMAKE_LFLAGS_RELEASE +=
-QMAKE_LFLAGS_DEBUG +=
-QMAKE_LFLAGS_APP +=
-QMAKE_LFLAGS_SHLIB +=
-QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_THREAD +=
+QMAKE_LINK = armlink
+QMAKE_LINK_SHLIB = armlink
+QMAKE_LINK_C = armlink
+QMAKE_LINK_C_SHLIB = armlink
+QMAKE_LFLAGS +=
+QMAKE_LFLAGS_RELEASE +=
+QMAKE_LFLAGS_DEBUG +=
+QMAKE_LFLAGS_APP +=
+QMAKE_LFLAGS_SHLIB +=
+QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_THREAD +=
QMAKE_AR = armar --create
QMAKE_LIB = armar --create
diff --git a/mkspecs/common/clang-mac.conf b/mkspecs/common/clang-mac.conf
index f7fe50a50b..3280274f36 100644
--- a/mkspecs/common/clang-mac.conf
+++ b/mkspecs/common/clang-mac.conf
@@ -3,3 +3,8 @@ QMAKE_OBJCFLAGS_PRECOMPILE = -x objective-c-header -c ${QMAKE_PCH_INPUT} -
QMAKE_OBJCFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
QMAKE_OBJCXXFLAGS_PRECOMPILE = -x objective-c++-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_OBJCXXFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
+
+QMAKE_XCODE_GCC_VERSION = com.apple.compilers.llvm.clang.1_0
+
+QMAKE_CXXFLAGS_CXX11 += -stdlib=libc++
+QMAKE_LFLAGS_CXX11 += -stdlib=libc++
diff --git a/mkspecs/common/clang.conf b/mkspecs/common/clang.conf
index 8c97644044..3ce04b679e 100644
--- a/mkspecs/common/clang.conf
+++ b/mkspecs/common/clang.conf
@@ -2,31 +2,31 @@
# Qmake configuration for Clang on Linux and Mac
#
-QMAKE_COMPILER = gcc clang llvm # clang pretends to be gcc
+QMAKE_COMPILER = gcc clang llvm # clang pretends to be gcc
-QMAKE_CC = clang
-QMAKE_CXX = clang++
+QMAKE_CC = clang
+QMAKE_CXX = clang++
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
+QMAKE_LINK = $$QMAKE_CXX
+QMAKE_LINK_SHLIB = $$QMAKE_CXX
-CONFIG += clang_pch_style
-QMAKE_PCH_OUTPUT_EXT = .pch
+CONFIG += clang_pch_style
+QMAKE_PCH_OUTPUT_EXT = .pch
QMAKE_CFLAGS_PRECOMPILE = -x c-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_CFLAGS_USE_PRECOMPILE = -Xclang -include-pch -Xclang ${QMAKE_PCH_OUTPUT}
QMAKE_CXXFLAGS_PRECOMPILE = -x c++-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_CXXFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
-QMAKE_CXXFLAGS_CXX11 = -std=c++11
-QMAKE_LFLAGS_CXX11 =
+QMAKE_CXXFLAGS_CXX11 = -std=c++11
+QMAKE_LFLAGS_CXX11 =
-QMAKE_CFLAGS_SSE2 += -msse2
-QMAKE_CFLAGS_SSE3 += -msse3
-QMAKE_CFLAGS_SSSE3 += -mssse3
-QMAKE_CFLAGS_SSE4_1 += -msse4.1
-QMAKE_CFLAGS_SSE4_2 += -msse4.2
-QMAKE_CFLAGS_AVX += -mavx
-QMAKE_CFLAGS_AVX2 += -mavx2
-QMAKE_CFLAGS_IWMMXT += -mcpu=iwmmxt
-QMAKE_CFLAGS_NEON += -mfpu=neon
+QMAKE_CFLAGS_SSE2 += -msse2
+QMAKE_CFLAGS_SSE3 += -msse3
+QMAKE_CFLAGS_SSSE3 += -mssse3
+QMAKE_CFLAGS_SSE4_1 += -msse4.1
+QMAKE_CFLAGS_SSE4_2 += -msse4.2
+QMAKE_CFLAGS_AVX += -mavx
+QMAKE_CFLAGS_AVX2 += -mavx2
+QMAKE_CFLAGS_IWMMXT += -mcpu=iwmmxt
+QMAKE_CFLAGS_NEON += -mfpu=neon
diff --git a/mkspecs/common/g++-base.conf b/mkspecs/common/g++-base.conf
index 0661298b18..4d38813710 100644
--- a/mkspecs/common/g++-base.conf
+++ b/mkspecs/common/g++-base.conf
@@ -8,28 +8,28 @@
# you can use the manual test in tests/manual/mkspecs.
#
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
+QMAKE_CC = gcc
-QMAKE_LINK_C = $$QMAKE_CC
-QMAKE_LINK_C_SHLIB = $$QMAKE_CC
+QMAKE_LINK_C = $$QMAKE_CC
+QMAKE_LINK_C_SHLIB = $$QMAKE_CC
QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO += -O2 -g
-QMAKE_CXX = g++
+QMAKE_CXX = g++
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
+QMAKE_LINK = $$QMAKE_CXX
+QMAKE_LINK_SHLIB = $$QMAKE_CXX
QMAKE_CXXFLAGS_RELEASE_WITH_DEBUGINFO += $$QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO
-QMAKE_PCH_OUTPUT_EXT = .gch
+QMAKE_PCH_OUTPUT_EXT = .gch
QMAKE_CFLAGS_PRECOMPILE = -x c-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_CFLAGS_USE_PRECOMPILE = -include ${QMAKE_PCH_OUTPUT_BASE}
QMAKE_CXXFLAGS_PRECOMPILE = -x c++-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_CXXFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
-QMAKE_CXXFLAGS_CXX11 = -std=c++0x
-QMAKE_LFLAGS_CXX11 =
+QMAKE_CXXFLAGS_CXX11 = -std=c++0x
+QMAKE_LFLAGS_CXX11 =
diff --git a/mkspecs/common/g++-unix.conf b/mkspecs/common/g++-unix.conf
index 96e301e8fa..a493cd5984 100644
--- a/mkspecs/common/g++-unix.conf
+++ b/mkspecs/common/g++-unix.conf
@@ -10,5 +10,5 @@
include(g++-base.conf)
-QMAKE_LFLAGS_RELEASE += -Wl,-O1
-QMAKE_LFLAGS_NOUNDEF += -Wl,--no-undefined
+QMAKE_LFLAGS_RELEASE += -Wl,-O1
+QMAKE_LFLAGS_NOUNDEF += -Wl,--no-undefined
diff --git a/mkspecs/common/gcc-base-ios.conf b/mkspecs/common/gcc-base-mac.conf
index 2fd597e973..fa2b5765bf 100644
--- a/mkspecs/common/gcc-base-ios.conf
+++ b/mkspecs/common/gcc-base-mac.conf
@@ -1,5 +1,5 @@
#
-# Base qmake configuration for GCC on iOS
+# Base qmake configuration for GCC on Mac OS X and iOS
#
# Before making changes to this file, please read the comment in
# gcc-base.conf, to make sure the change goes in the right place.
@@ -23,11 +23,12 @@ QMAKE_OBJECTIVE_CFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
QMAKE_OBJECTIVE_CFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
QMAKE_OBJECTIVE_CFLAGS_HIDESYMS = $$QMAKE_CXXFLAGS_HIDESYMS
-QMAKE_LFLAGS += -headerpad_max_install_names
-QMAKE_LFLAGS_SHLIB += -single_module -dynamiclib
-QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_INCREMENTAL += -undefined suppress -flat_namespace
-QMAKE_LFLAGS_SONAME += -install_name$${LITERAL_WHITESPACE}@executable_path/
-QMAKE_LFLAGS_VERSION += -current_version$${LITERAL_WHITESPACE}
+QMAKE_LFLAGS += -headerpad_max_install_names
+
+QMAKE_LFLAGS_SHLIB += -single_module -dynamiclib
+QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_INCREMENTAL += -undefined suppress -flat_namespace
+QMAKE_LFLAGS_SONAME += -install_name$${LITERAL_WHITESPACE}
+QMAKE_LFLAGS_VERSION += -current_version$${LITERAL_WHITESPACE}
QMAKE_LFLAGS_COMPAT_VERSION += -compatibility_version$${LITERAL_WHITESPACE}
diff --git a/mkspecs/common/gcc-base-macx.conf b/mkspecs/common/gcc-base-macx.conf
deleted file mode 100644
index 45fa248b66..0000000000
--- a/mkspecs/common/gcc-base-macx.conf
+++ /dev/null
@@ -1,34 +0,0 @@
-#
-# Base qmake configuration for GCC on Mac OS X
-#
-# Before making changes to this file, please read the comment in
-# gcc-base.conf, to make sure the change goes in the right place.
-#
-# To verify that your change has the desired effect on the final configuration
-# you can use the manual test in tests/manual/mkspecs.
-#
-
-include(gcc-base.conf)
-
-QMAKE_COMPILER_DEFINES += __APPLE__ __GNUC__=4
-
-QMAKE_CFLAGS_DEBUG += -gdwarf-2
-
-QMAKE_CXXFLAGS_DEBUG += -gdwarf-2
-
-QMAKE_OBJECTIVE_CFLAGS = $$QMAKE_CFLAGS
-QMAKE_OBJECTIVE_CFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_OBJECTIVE_CFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_OBJECTIVE_CFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_OBJECTIVE_CFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_OBJECTIVE_CFLAGS_HIDESYMS = $$QMAKE_CXXFLAGS_HIDESYMS
-
-QMAKE_LFLAGS += -headerpad_max_install_names
-
-QMAKE_LFLAGS_SHLIB += -single_module -dynamiclib
-QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_INCREMENTAL += -undefined suppress -flat_namespace
-QMAKE_LFLAGS_SONAME += -install_name$${LITERAL_WHITESPACE}
-QMAKE_LFLAGS_VERSION += -current_version$${LITERAL_WHITESPACE}
-QMAKE_LFLAGS_COMPAT_VERSION += -compatibility_version$${LITERAL_WHITESPACE}
-
diff --git a/mkspecs/common/gcc-base-unix.conf b/mkspecs/common/gcc-base-unix.conf
index dadaecaa29..84ef88aa4f 100644
--- a/mkspecs/common/gcc-base-unix.conf
+++ b/mkspecs/common/gcc-base-unix.conf
@@ -10,12 +10,12 @@
include(gcc-base.conf)
-QMAKE_LFLAGS_SHLIB += -shared
-QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME += -Wl,-soname,
-QMAKE_LFLAGS_THREAD +=
-QMAKE_LFLAGS_RPATH = -Wl,-rpath,
-QMAKE_LFLAGS_RPATHLINK = -Wl,-rpath-link,
+QMAKE_LFLAGS_SHLIB += -shared
+QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME += -Wl,-soname,
+QMAKE_LFLAGS_THREAD +=
+QMAKE_LFLAGS_RPATH = -Wl,-rpath,
+QMAKE_LFLAGS_RPATHLINK = -Wl,-rpath-link,
# -Bsymbolic-functions (ld) support
QMAKE_LFLAGS_BSYMBOLIC_FUNC = -Wl,-Bsymbolic-functions
diff --git a/mkspecs/common/gcc-base.conf b/mkspecs/common/gcc-base.conf
index 43ebc0ab3a..b1f2ad4979 100644
--- a/mkspecs/common/gcc-base.conf
+++ b/mkspecs/common/gcc-base.conf
@@ -7,8 +7,7 @@
#
# Platform-specific options shared by these compilers are put into:
#
-# - gcc-base-ios.conf
-# - gcc-base-macx.conf
+# - gcc-base-mac.conf
# - gcc-base-unix.conf
#
# These base files are then combined with configurations for each compiler:
@@ -20,11 +19,11 @@
# - clang.conf
#
# The combination happens in the top level mkspec, by including a platform-
-# specific version of the base-file, for example gcc-base-macx.conf, and then
+# specific version of the base-file, for example gcc-base-mac.conf, and then
# a (possibly platform-specific) version of the actual compiler configuration,
# for example g++-macx.conf.
#
-# If you are making changes to any of these files, please consider the
+# If you are making changes to any of these files, please consider the
# possible effect it may have due to these include-rules, and whether it
# might make more sense to share the rule or make it more specific.
#
@@ -32,17 +31,17 @@
# you can use the manual test in tests/manual/mkspecs.
#
-QMAKE_CFLAGS += -pipe
-QMAKE_CFLAGS_DEPS += -M
-QMAKE_CFLAGS_WARN_ON += -Wall -W
-QMAKE_CFLAGS_WARN_OFF += -w
-QMAKE_CFLAGS_RELEASE += -O2
-QMAKE_CFLAGS_DEBUG += -g
-QMAKE_CFLAGS_SHLIB += -fPIC
-QMAKE_CFLAGS_STATIC_LIB += -fPIC
-QMAKE_CFLAGS_APP += -fPIE
-QMAKE_CFLAGS_YACC += -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_HIDESYMS += -fvisibility=hidden
+QMAKE_CFLAGS += -pipe
+QMAKE_CFLAGS_DEPS += -M
+QMAKE_CFLAGS_WARN_ON += -Wall -W
+QMAKE_CFLAGS_WARN_OFF += -w
+QMAKE_CFLAGS_RELEASE += -O2
+QMAKE_CFLAGS_DEBUG += -g
+QMAKE_CFLAGS_SHLIB += -fPIC
+QMAKE_CFLAGS_STATIC_LIB += -fPIC
+QMAKE_CFLAGS_APP += -fPIE
+QMAKE_CFLAGS_YACC += -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_HIDESYMS += -fvisibility=hidden
QMAKE_CFLAGS_EXCEPTIONS_OFF += -fno-exceptions
QMAKE_CXXFLAGS += $$QMAKE_CFLAGS
@@ -58,18 +57,18 @@ QMAKE_CXXFLAGS_YACC += $$QMAKE_CFLAGS_YACC
QMAKE_CXXFLAGS_HIDESYMS += $$QMAKE_CFLAGS_HIDESYMS -fvisibility-inlines-hidden
QMAKE_CXXFLAGS_EXCEPTIONS_OFF += $$QMAKE_CFLAGS_EXCEPTIONS_OFF
-QMAKE_LFLAGS +=
-QMAKE_LFLAGS_DEBUG +=
-QMAKE_LFLAGS_APP +=
-QMAKE_LFLAGS_RELEASE +=
+QMAKE_LFLAGS +=
+QMAKE_LFLAGS_DEBUG +=
+QMAKE_LFLAGS_APP +=
+QMAKE_LFLAGS_RELEASE +=
QMAKE_LFLAGS_EXCEPTIONS_OFF +=
-QMAKE_CFLAGS_SSE2 += -msse2
-QMAKE_CFLAGS_SSE3 += -msse3
-QMAKE_CFLAGS_SSSE3 += -mssse3
-QMAKE_CFLAGS_SSE4_1 += -msse4.1
-QMAKE_CFLAGS_SSE4_2 += -msse4.2
-QMAKE_CFLAGS_AVX += -mavx
-QMAKE_CFLAGS_AVX2 += -mavx2
-QMAKE_CFLAGS_IWMMXT += -mcpu=iwmmxt
-QMAKE_CFLAGS_NEON += -mfpu=neon
+QMAKE_CFLAGS_SSE2 += -msse2
+QMAKE_CFLAGS_SSE3 += -msse3
+QMAKE_CFLAGS_SSSE3 += -mssse3
+QMAKE_CFLAGS_SSE4_1 += -msse4.1
+QMAKE_CFLAGS_SSE4_2 += -msse4.2
+QMAKE_CFLAGS_AVX += -mavx
+QMAKE_CFLAGS_AVX2 += -mavx2
+QMAKE_CFLAGS_IWMMXT += -mcpu=iwmmxt
+QMAKE_CFLAGS_NEON += -mfpu=neon
diff --git a/mkspecs/common/ios.conf b/mkspecs/common/ios.conf
index 7420b56daf..67705faf44 100644
--- a/mkspecs/common/ios.conf
+++ b/mkspecs/common/ios.conf
@@ -2,18 +2,7 @@
# qmake common configuration for iOS
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += ios reduce_exports incremental global_init_link_order lib_version_first plugin_no_soname
-QMAKE_INCREMENTAL_STYLE = sublib
+QMAKE_PLATFORM += ios
+QMAKE_MAC_SDK = iphoneos
-# Qt can't build iOS app bundle :(
-CONFIG -= app_bundle
-
-# Not deploying to Mac OSX
-QMAKE_MACOSX_DEPLOYMENT_TARGET =
-
-# Add iOS common folder to include path
-INCLUDEPATH += $$PWD/ios
-
-# iOS defines
-DEFINES += DARWIN_NO_CARBON Q_OS_IOS QT_NO_CORESERVICES QT_NO_PRINTER QT_NO_PRINTDIALOG
+include(mac.conf)
diff --git a/mkspecs/common/ios/arch.conf b/mkspecs/common/ios/arch.conf
deleted file mode 100644
index 4ad96874fe..0000000000
--- a/mkspecs/common/ios/arch.conf
+++ /dev/null
@@ -1,84 +0,0 @@
-#
-# Helper to set CPU architecture flags for iOS configurations
-#
-# Depends on:
-#
-# QMAKE_IPHONEOS_DEPLOYMENT_TARGET - set in mkspecs/common/ios/versions.conf
-#
-# Note:
-#
-# Must be included after load(qt_config) in mkspec for auto-detection based
-# on GL/ES version (GL/ES 2.x implies armv7 on iOS).
-#
-
-# Target architecture for iOS devices (armv6, armv7 or leave blank for default)
-QMAKE_IOS_TARGET_ARCH =
-
-###########################################################################
-
-# Device?
-!*simulator* {
- # Let mkspec specify archictecture
- *armv6*: QMAKE_IOS_TARGET_ARCH = armv6
- else:*armv7*: QMAKE_IOS_TARGET_ARCH = armv7
-
- # ARMv7 architecture device (see below) is required for OpenGL/ES 2.x
- isEmpty(QMAKE_IOS_TARGET_ARCH):contains(QT_CONFIG, opengles2): QMAKE_IOS_TARGET_ARCH = armv7
-
- # No target architecture specified?
- isEmpty(QMAKE_IOS_TARGET_ARCH) {
- # iOS versions < 4.3 can be armv6 or armv7, so need armv6 for max. compatibility,
- # assume that building for OpenGL/ES 1.x is targeting armv6
- lessThan(QMAKE_IPHONEOS_DEPLOYMENT_TARGET, "4.3")|contains(QT_CONFIG, opengles1) {
- QMAKE_IOS_TARGET_ARCH = armv6
- } else: QMAKE_IOS_TARGET_ARCH = armv7
- }
-
- # Samsung S5PC100, Apple A4, A5, A5X
- equals(QMAKE_IOS_TARGET_ARCH, "armv7") {
- # iOS CPU architecture (armv7)
- QMAKE_IOS_ARM_ARCH = __ARM_ARCH_7__
-
- # Thumb2 instructions
- QMAKE_IOS_ARM_FLAGS = -mthumb
- QMAKE_IOS_ARM_ARCH += __MARM_THUMB__
-
- # NEON instructions
- *-g++*: QMAKE_IOS_ARM_FLAGS += -mfloat-abi=softfp -mfpu=neon
- QMAKE_IOS_ARM_ARCH += __ARM_NEON__
- } else {
- # Samsung S5L8900
- if(equals(QMAKE_IOS_TARGET_ARCH, "armv6")) {
- # iOS CPU architecture (armv6)
- QMAKE_IOS_ARM_ARCH = __ARM_ARCH_6__
-
- # ARM instructions
- QMAKE_IOS_ARM_FLAGS = -marm -mcpu=arm1176jzf-s
- !*clang*: QMAKE_IOS_ARM_FLAGS += -march=armv6
- } else {
- # Unsupported architecture
- error("Invalid iOS target $${QMAKE_IOS_TARGET_ARCH}! Edit mkspecs/common/ios/arch.conf to specify target architecture.")
- }
- }
-# Simulator is i386 only
-} else: QMAKE_IOS_TARGET_ARCH = i386
-
-# iOS architecture build flags
-QMAKE_IOS_ARCH_FLAGS = -arch $$QMAKE_IOS_TARGET_ARCH
-QMAKE_CFLAGS += $$QMAKE_IOS_ARCH_FLAGS
-QMAKE_CXXFLAGS += $$QMAKE_IOS_ARCH_FLAGS
-QMAKE_OBJECTIVE_CFLAGS += $$QMAKE_IOS_ARCH_FLAGS
-QMAKE_LFLAGS += $$QMAKE_IOS_ARCH_FLAGS
-QMAKE_IOS_TARGET_ARCH =
-QMAKE_IOS_ARCH_FLAGS =
-
-# Architecture specific defines/flags
-!*simulator* {
- DEFINES += $$QMAKE_IOS_ARM_ARCH
- QMAKE_IOS_ARM_ARCH =
-
- QMAKE_CFLAGS += $$QMAKE_IOS_ARM_FLAGS
- QMAKE_CXXFLAGS += $$QMAKE_IOS_ARM_FLAGS
- QMAKE_OBJECTIVE_CFLAGS += $$QMAKE_IOS_ARM_FLAGS
- QMAKE_IOS_ARM_FLAGS =
-}
diff --git a/mkspecs/common/ios/clang.conf b/mkspecs/common/ios/clang.conf
index 10d1dbd24e..5da7e5a233 100644
--- a/mkspecs/common/ios/clang.conf
+++ b/mkspecs/common/ios/clang.conf
@@ -3,45 +3,35 @@
#
# Depends on:
#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
+# QMAKE_XCODE_VERSION - set in xcode.conf
#
# iOS build flags
-QMAKE_IOS_CFLAGS = -fvisibility=hidden -fpascal-strings -fmessage-length=0
+QMAKE_IOS_CFLAGS += -fvisibility=hidden -fpascal-strings -fmessage-length=0
QMAKE_IOS_CFLAGS += -Wno-trigraphs -Wreturn-type -Wparentheses -Wswitch -Wno-unused-parameter -Wunused-variable -Wunused-value -Wno-shorten-64-to-32 -Wno-sign-conversion
-QMAKE_IOS_CXXFLAGS = -fvisibility-inlines-hidden
-QMAKE_IOS_OBJ_CFLAGS = -Wno-arc-abi -Wc++0x-extensions
+QMAKE_IOS_CXXFLAGS += -fvisibility-inlines-hidden
+QMAKE_IOS_OBJ_CFLAGS += -Wno-arc-abi
-# Device or simulator specific flags
-*simulator* {
- QMAKE_IOS_CFLAGS += -fexceptions -fasm-blocks
- QMAKE_IOS_OBJ_CFLAGS += -fobjc-abi-version=2 -fobjc-legacy-dispatch
-}
+# Based on the following information, http://clang.llvm.org/doxygen/ObjCRuntime_8h_source.html,
+# we can conclude that it's safe to always pass the following flags
+QMAKE_IOS_OBJ_CFLAGS += -fobjc-nonfragile-abi -fobjc-legacy-dispatch
-# Compiler version-specific flags
-!lessThan(QMAKE_IOS_XCODE_VERSION, "4.3") {
- # Clang 3.1 flags (will be used for later versions too)
- QMAKE_IOS_CFLAGS += -Wno-missing-field-initializers -Wno-missing-prototypes -Wno-implicit-atomic-properties -Wformat -Wno-missing-braces -Wno-unused-function -Wno-unused-label -Wuninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-sign-compare -Wpointer-sign -Wno-newline-eof -Wdeprecated-declarations -Winvalid-offsetof -Wno-conversion
- QMAKE_IOS_CXXFLAGS += -Wno-non-virtual-dtor -Wno-overloaded-virtual -Wno-exit-time-destructors -Wc++11-extensions
- QMAKE_IOS_OBJ_CFLAGS += -Wno-deprecated-implementations -Wprotocol -Wno-selector -Wno-strict-selector-match -Wno-undeclared-selector
+# But these only apply to non-ARM targets
+!contains(QT_ARCH, arm): QMAKE_IOS_CFLAGS += -fexceptions -fasm-blocks
- # Warn about unsupported (later than 4.5) Xcode versions
- !lessThan(QMAKE_IOS_XCODE_VERSION, "4.6"): warning("The version of Xcode installed on this system is not recognised - custom compiler settings may be necessary")
-} else {
- if (!lessThan(QMAKE_IOS_XCODE_VERSION, "4.2")) {
- # Clang 3.0 flags
- QMAKE_IOS_CFLAGS += -fdiagnostics-print-source-range-info -fdiagnostics-show-category=id -fdiagnostics-parseable-fixits
- } else {
- # Older Clang versions are not supported
- error("Unsupported Xcode version $${QMAKE_IOS_XCODE_VERSION}")
- }
-}
+# Clang 3.1 (and above) flags
+QMAKE_IOS_CFLAGS += -Wno-missing-field-initializers -Wno-missing-prototypes -Wno-implicit-atomic-properties -Wformat -Wno-missing-braces -Wno-unused-function -Wno-unused-label -Wuninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-sign-compare -Wpointer-sign -Wno-newline-eof -Wdeprecated-declarations -Winvalid-offsetof -Wno-conversion
+QMAKE_IOS_CXXFLAGS += -Wno-non-virtual-dtor -Wno-overloaded-virtual -Wno-exit-time-destructors
+QMAKE_IOS_OBJ_CFLAGS += -Wno-deprecated-implementations -Wprotocol -Wno-selector -Wno-strict-selector-match -Wno-undeclared-selector
+
+# Warn about unsupported (later than 4.5) Xcode versions
+!lessThan(QMAKE_XCODE_VERSION, "4.7"): warning("The version of Xcode installed on this system is not recognised - custom compiler settings may be necessary")
# Set build flags
QMAKE_CFLAGS += $$QMAKE_IOS_CFLAGS
QMAKE_CXXFLAGS += $$QMAKE_IOS_CFLAGS $$QMAKE_IOS_CXXFLAGS
QMAKE_OBJECTIVE_CFLAGS += $$QMAKE_IOS_CFLAGS $$QMAKE_IOS_CXXFLAGS $$QMAKE_IOS_OBJ_CFLAGS
-QMAKE_IOS_CFLAGS =
-QMAKE_IOS_CXXFLAGS =
-QMAKE_IOS_OBJ_CFLAGS =
+QMAKE_IOS_CFLAGS =
+QMAKE_IOS_CXXFLAGS =
+QMAKE_IOS_OBJ_CFLAGS =
diff --git a/mkspecs/common/ios/g++.conf b/mkspecs/common/ios/g++.conf
deleted file mode 100644
index 8a1e0b20c0..0000000000
--- a/mkspecs/common/ios/g++.conf
+++ /dev/null
@@ -1,21 +0,0 @@
-#
-# compiler settings for iOS g++ compilers
-#
-
-# iOS build flags
-QMAKE_IOS_CFLAGS = -fvisibility=hidden -fexceptions -fmessage-length=0
-QMAKE_IOS_CFLAGS += -Wno-trigraphs -Wreturn-type -Wunused-variable
-QMAKE_IOS_CXXFLAGS = -fvisibility-inlines-hidden
-
-# Device or simulator specific flags
-!*simulator*: QMAKE_IOS_OBJ_CFLAGS =
-else: QMAKE_IOS_OBJ_CFLAGS = -fobjc-abi-version=2 -fobjc-legacy-dispatch
-
-# Set build flags
-QMAKE_CFLAGS += $$QMAKE_IOS_CFLAGS
-QMAKE_CXXFLAGS += $$QMAKE_IOS_CFLAGS $$QMAKE_IOS_CXXFLAGS
-QMAKE_OBJECTIVE_CFLAGS += $$QMAKE_IOS_CFLAGS $$QMAKE_IOS_CXXFLAGS $$QMAKE_IOS_OBJ_CFLAGS
-
-QMAKE_IOS_CFLAGS =
-QMAKE_IOS_CXXFLAGS =
-QMAKE_IOS_OBJ_CFLAGS =
diff --git a/mkspecs/common/ios/llvm.conf b/mkspecs/common/ios/llvm.conf
deleted file mode 100644
index fa2e519dd9..0000000000
--- a/mkspecs/common/ios/llvm.conf
+++ /dev/null
@@ -1,31 +0,0 @@
-#
-# compiler settings for iOS llvm-g++ compilers
-#
-# Depends on:
-#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
-#
-
-# iOS build flags
-QMAKE_IOS_CFLAGS = -fvisibility=hidden -fpascal-strings -fmessage-length=0
-QMAKE_IOS_CFLAGS += -Wno-trigraphs -Wreturn-type -Wunused-variable
-QMAKE_IOS_CXXFLAGS = -fvisibility-inlines-hidden
-
-# Device or simulator specific flags
-!*simulator*: QMAKE_IOS_OBJ_CFLAGS =
-else: QMAKE_IOS_OBJ_CFLAGS = -fobjc-abi-version=2 -fobjc-legacy-dispatch
-
-# Compiler version specific flags
-!lessThan(QMAKE_IOS_XCODE_VERSION, "4.3") {
- # Xcode 4.3+ specific flags
- QMAKE_IOS_CFLAGS += -Wuninitialized
-}
-
-# Set build flags
-QMAKE_CFLAGS += $$QMAKE_IOS_CFLAGS
-QMAKE_CXXFLAGS += $$QMAKE_IOS_CFLAGS $$QMAKE_IOS_CXXFLAGS
-QMAKE_OBJECTIVE_CFLAGS += $$QMAKE_IOS_CFLAGS $$QMAKE_IOS_CXXFLAGS $$QMAKE_IOS_OBJ_CFLAGS
-
-QMAKE_IOS_CFLAGS =
-QMAKE_IOS_CXXFLAGS =
-QMAKE_IOS_OBJ_CFLAGS =
diff --git a/mkspecs/common/ios/qmake.conf b/mkspecs/common/ios/qmake.conf
index 8ee2575fb4..39465aa765 100644
--- a/mkspecs/common/ios/qmake.conf
+++ b/mkspecs/common/ios/qmake.conf
@@ -1,66 +1,33 @@
#
# Common build settings for all iOS configurations
#
-# Depends on:
-#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
-# QMAKE_IOS_SDK_VERSION - set in mkspecs/common/ios/versions.conf
-# QMAKE_IOSSIMULATOR_SDK_VERSION - set in mkspecs/common/ios/versions.conf
-#
-
-# iOS SDK device type
-!*simulator*: QMAKE_IOS_DEVICE_TYPE = iPhoneOS
-else {
- QMAKE_IOS_DEVICE_TYPE = iPhoneSimulator
- # Use simulator SDK version
- QMAKE_IOS_SDK_VERSION = $$QMAKE_IOS_SIMULATOR_SDK_VERSION
- QMAKE_IOS_SIMULATOR_SDK_VERSION =
-}
+QT_QPA_DEFAULT_PLATFORM = ios
-!lessThan(QMAKE_IOS_XCODE_VERSION, "4.3") {
- # Xcode 4.3+ is stored in /Applications
- QMAKE_IOS_XCODE_PATH = /Applications/Xcode.app/Contents
-} else: QMAKE_IOS_XCODE_PATH =
+QMAKE_XCODE_CODE_SIGN_IDENTITY = "iPhone Developer"
-# iOS platform /Developer path
-QMAKE_IOS_DEV_PATH = $$QMAKE_IOS_XCODE_PATH/Developer/Platforms/$${QMAKE_IOS_DEVICE_TYPE}.platform/Developer
-QMAKE_IOS_XCODE_PATH =
-
-# iOS platform SDK path
-QMAKE_IOS_SDK = $$QMAKE_IOS_DEV_PATH/SDKs/$${QMAKE_IOS_DEVICE_TYPE}$${QMAKE_IOS_SDK_VERSION}.sdk
-QMAKE_IOS_DEV_PATH =
-QMAKE_IOS_DEVICE_TYPE =
-
-QMAKE_CFLAGS += -isysroot $$QMAKE_IOS_SDK
-QMAKE_CXXFLAGS += -isysroot $$QMAKE_IOS_SDK
-QMAKE_OBJECTIVE_CFLAGS += -isysroot $$QMAKE_IOS_SDK
-QMAKE_LFLAGS += -Wl,-syslibroot,$$QMAKE_IOS_SDK
-QMAKE_IOS_SDK =
+# iOS build tools
+QMAKE_CC = clang
+QMAKE_CXX = clang++
+QMAKE_FIX_RPATH = install_name_tool -id
+QMAKE_AR = ar cq
+QMAKE_RANLIB = ranlib -s
+QMAKE_LINK = $$QMAKE_CXX
+QMAKE_LINK_SHLIB = $$QMAKE_CXX
# Basic iOS frameworks needed for any GUI app
QMAKE_LFLAGS += -framework Foundation -framework UIKit -framework QuartzCore -lz
-# OpenGL ES1
-QMAKE_INCDIR_OPENGL_ES1 = $$QMAKE_IOS_SDK/System/Library/Frameworks/OpenGLES.framework/Headers
+# No OpenGL ES1
+QMAKE_INCDIR_OPENGL_ES1 =
QMAKE_LIBDIR_OPENGL_ES1 =
-QMAKE_LIBS_OPENGL_ES1 = -framework OpenGLES
+QMAKE_LIBS_OPENGL_ES1 =
# OpenGL ES2
-QMAKE_INCDIR_OPENGL_ES2 = $$QMAKE_IOS_SDK/System/Library/Frameworks/OpenGLES.framework/Headers
+QMAKE_INCDIR_OPENGL_ES2 =
QMAKE_LIBDIR_OPENGL_ES2 =
QMAKE_LIBS_OPENGL_ES2 = -framework OpenGLES
# No desktop OpenGL
QMAKE_INCDIR_OPENGL =
QMAKE_LIBS_OPENGL =
-QMAKE_LIBS_OPENGL_QT =
-
-# Compiler-specific flags
-!*-g++* {
- # Objective-C/C++ precompile flags
- QMAKE_OBJCFLAGS_PRECOMPILE = -x objective-c-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
- QMAKE_OBJCFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
- QMAKE_OBJCXXFLAGS_PRECOMPILE = -x objective-c++-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
- QMAKE_OBJCXXFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
-}
diff --git a/mkspecs/common/ios/versions.conf b/mkspecs/common/ios/versions.conf
deleted file mode 100644
index b755068769..0000000000
--- a/mkspecs/common/ios/versions.conf
+++ /dev/null
@@ -1,184 +0,0 @@
-#
-# Helper to set build tool & SDK versions for iOS configurations
-#
-# This file sets up the following configuration variables:
-#
-# QMAKE_IOS_XCODE_VERSION - version number of Xcode being used
-# QMAKE_IOS_SDK_VERSION - version number of iOS device SDK
-# QMAKE_IOS_SIMULATOR_SDK_VERSION - version number of iOS simulator SDK
-#
-# Used in:
-#
-# mkspecs/common/ios/clang.conf
-# mkspecs/common/ios/llvm.conf
-# mkspecs/common/ios/qmake.conf
-# mkspecs/unsupported/macx-iosdevice-clang-legacy/qmake.conf
-# mkspecs/unsupported/macx-iosdevice-clang/qmake.conf
-# mkspecs/unsupported/macx-iosdevice-llvm-legacy/qmake.conf
-# mkspecs/unsupported/macx-iosdevice-llvm/qmake.conf
-# mkspecs/unsupported/macx-iosdevice-g++-legacy/qmake.conf
-# mkspecs/unsupported/macx-iossimulator-llvm-legacy/qmake.conf
-# mkspecs/unsupported/macx-iossimulator-llvm/qmake.conf
-# mkspecs/unsupported/macx-iossimulator-g++-legacy/qmake.conf
-#
-
-#
-# IMPORTANT:
-#
-# Xcode versions <= 4.2.x must be installed in /Developer.
-# Xcode versions >= 4.3.x must be installed in /Applications
-#
-# Xcode versions >= 4.10 & < 5.0 and versions >= 10.0 are not supported due to
-# the way the version checks are done here. As Apple (so far) has not used
-# minor version numbers greater than 3 for Xcode, and the Xcode major version
-# has only changed three times in the period 2003-2012, this is viewed as an
-# acceptable limitation.
-#
-
-#
-# Edit values below to match iOS build environment, or leave blank for
-# autodetection (slower!)
-#
-
-# Xcode version used for cross-compiling
-QMAKE_IOS_XCODE_VERSION =
-
-# iOS SDK version used for cross-compiling for iOS devices
-QMAKE_IOS_SDK_VERSION =
-
-# iOS SDK version used for cross-compiling for the iOS simulator
-QMAKE_IOS_SIMULATOR_SDK_VERSION =
-
-#
-# Do not edit values below here if using a pre-built SDK
-#
-
-# Minimum iOS version required on deployment target (if not specified, will
-# default to minimum version that guarantees ARMv7 & OpenGL/ES 2.x).
-#
-# No part of Qt or any known plugin uses features that require iOS versions
-# later than 4.0.
-QMAKE_IPHONEOS_DEPLOYMENT_TARGET = 4.0
-
-###########################################################################
-
-# No Xcode version specified?
-isEmpty(QMAKE_IOS_XCODE_VERSION) {
- # Get version string from installed Xcode
- exists(/Applications/Xcode.app/Contents/Developer) {
- QMAKE_IOS_XCODE_INFO = $$system(/Applications/Xcode.app/Contents/Developer/usr/bin/xcodebuild -version)
- } else: QMAKE_IOS_XCODE_INFO = $$system(/Developer/usr/bin/xcodebuild -version)
-
- # Extract Xcode version number from output
- QMAKE_IOS_XCODE_VERSION = $$member(QMAKE_IOS_XCODE_INFO, 1)
- QMAKE_IOS_XCODE_INFO =
-}
-
-# Make sure Xcode version is valid
-!lessThan(QMAKE_IOS_XCODE_VERSION, "4.3") {
- # Xcode 4.3+ is stored in /Applications
- QMAKE_IOS_PLATFORM_PATH = /Applications/Xcode.app/Contents/Developer/Platforms
-
- # Make sure Xcode path is valid
- !exists($$QMAKE_IOS_PLATFORM_PATH): error("Xcode is not installed in /Applications/Xcode.app! Edit mkspecs/common/ios/versions.conf to specify version installed.")
-} else {
- # Older Xcode versions are stored in /Developer
- QMAKE_IOS_PLATFORM_PATH = /Developer/Platforms
-
- # Make sure Xcode path is valid
- !exists($$QMAKE_IOS_PLATFORM_PATH): error("Xcode is not installed in /Developer! Edit mkspecs/common/ios/versions.conf to specify version installed.")
-}
-
-# iOS 4.3 is the preferred version as it is the earliest version that is armv7/gles2 only
-QMAKE_IPHONEOS_PREFERRED_TARGET = 4.3
-
-# Building for iOS device?
-!*simulator* {
- # No iOS SDK version specified?
- isEmpty(QMAKE_IOS_SDK_VERSION) {
- # Get version string from installed Xcode
- !lessThan(QMAKE_IOS_XCODE_VERSION, "4.3") {
- QMAKE_IOS_SDK_INFO = $$system(/Applications/Xcode.app/Contents/Developer/usr/bin/xcodebuild -showsdks)
- } else: QMAKE_IOS_SDK_INFO = $$system(/Developer/usr/bin/xcodebuild -showsdks)
-
- # Get names of installed device SDKs
- QMAKE_IOS_SDK_INFO = $$find(QMAKE_IOS_SDK_INFO, ^iphoneos)
- for(v, QMAKE_IOS_SDK_INFO): {
- # Extract SDK version number from output
- v = $$replace(v,iphoneos,)
-
- # Use latest SDK version
- greaterThan(v, $$QMAKE_IOS_SDK_VERSION): QMAKE_IOS_SDK_VERSION = $$v
- }
- QMAKE_IOS_SDK_INFO =
- }
-
- # Make sure iOS SDK version is valid
- !exists($$QMAKE_IOS_PLATFORM_PATH/iPhoneOS.platform/Developer/SDKs/iPhoneOS$${QMAKE_IOS_SDK_VERSION}.sdk) {
- error("iOS $$QMAKE_IOS_SDK_VERSION SDK not found! Edit mkspecs/common/ios/versions.conf to specify version installed.")
- }
-
- # No deployment target specified?
- isEmpty(QMAKE_IPHONEOS_DEPLOYMENT_TARGET) {
- # Use SDK version for iOS versions < preferred
- lessThan(QMAKE_IOS_SDK_VERSION, $$QMAKE_IPHONEOS_PREFERRED_TARGET) {
- QMAKE_IPHONEOS_DEPLOYMENT_TARGET = $$QMAKE_IOS_SDK_VERSION
- } else: QMAKE_IPHONEOS_DEPLOYMENT_TARGET = $$QMAKE_IPHONEOS_PREFERRED_TARGET
- }
-
- # Make sure iOS SDK version is >= iOS target version
- !lessThan(QMAKE_IPHONEOS_DEPLOYMENT_TARGET, $$QMAKE_IOS_SDK_VERSION) {
- error("Target iOS version is greater that iOS SDK version $$QMAKE_IOS_SDK_VERSION! Edit mkspecs/common/ios/versions.conf to specify target iOS version.")
- }
-# Building for iOS simulator
-} else {
- # No iOS simulator SDK version specified?
- isEmpty(QMAKE_IOS_SIMULATOR_SDK_VERSION) {
- # Get version string from installed Xcode
- !lessThan(QMAKE_IOS_XCODE_VERSION, "4.3") {
- QMAKE_IOS_SDK_INFO = $$system(/Applications/Xcode.app/Contents/Developer/usr/bin/xcodebuild -showsdks)
- } else: QMAKE_IOS_SDK_INFO = $$system(/Developer/usr/bin/xcodebuild -showsdks)
-
- # Get names of installed device SDKs
- QMAKE_IOS_SDK_INFO = $$find(QMAKE_IOS_SDK_INFO, ^iphonesimulator)
- for(v, QMAKE_IOS_SDK_INFO): {
- # Extract SDK version number from output
- v = $$replace(v,iphonesimulator,)
-
- # Use latest SDK version
- greaterThan(v, $$QMAKE_IOS_SIMULATOR_SDK_VERSION): QMAKE_IOS_SIMULATOR_SDK_VERSION = $$v
- }
- QMAKE_IOS_SDK_INFO =
- }
-
- # Make sure iOS simulator SDK version is valid
- !exists($$QMAKE_IOS_PLATFORM_PATH/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator$${QMAKE_IOS_SIMULATOR_SDK_VERSION}.sdk) {
- error("iOS $$QMAKE_IOS_SIMULATOR_SDK_VERSION simulator SDK not found! Edit mkspecs/common/ios/versions.conf to specify version installed.")
- }
-
- # No deployment target specified?
- isEmpty(QMAKE_IPHONEOS_DEPLOYMENT_TARGET) {
- # Use SDK version for iOS versions < preferred
- lessThan(QMAKE_IOS_SIMULATOR_SDK_VERSION, $$QMAKE_IPHONEOS_PREFERRED_TARGET) {
- QMAKE_IPHONEOS_DEPLOYMENT_TARGET = $$QMAKE_IOS_SIMULATOR_SDK_VERSION
- } else: QMAKE_IPHONEOS_DEPLOYMENT_TARGET = $$QMAKE_IPHONEOS_PREFERRED_TARGET
- }
-
- # Make sure iOS simulator SDK version is >= iOS target version
- !lessThan(QMAKE_IPHONEOS_DEPLOYMENT_TARGET, $$QMAKE_IOS_SIMULATOR_SDK_VERSION) {
- error("Target iOS version is greater that iOS simulator SDK version $$QMAKE_IOS_SIMULATOR_SDK_VERSION! Edit mkspecs/common/ios/versions.conf to specify target iOS version.")
- }
-}
-
-QMAKE_IPHONEOS_PREFERRED_TARGET =
-QMAKE_IOS_PLATFORM_PATH =
-
-# Set deployment target
-QMAKE_IOS_VERSION_FLAGS = -miphoneos-version-min=$$QMAKE_IPHONEOS_DEPLOYMENT_TARGET
-
-# Set build flags
-QMAKE_CFLAGS += $$QMAKE_IOS_VERSION_FLAGS
-QMAKE_CXXFLAGS += $$QMAKE_IOS_VERSION_FLAGS
-QMAKE_OBJECTIVE_CFLAGS += $$QMAKE_IOS_VERSION_FLAGS
-QMAKE_LFLAGS += $$QMAKE_IOS_VERSION_FLAGS
-QMAKE_IOS_VERSION_FLAGS =
diff --git a/mkspecs/common/linux-android.conf b/mkspecs/common/linux-android.conf
index 5b1a55d0f5..363dac3a34 100644
--- a/mkspecs/common/linux-android.conf
+++ b/mkspecs/common/linux-android.conf
@@ -1,12 +1,11 @@
MAKEFILE_GENERATOR = UNIX
QMAKE_INCREMENTAL_STYLE = sublib
-QMAKE_PLATFORM += android
+QMAKE_PLATFORM += android
include(linux.conf)
include(gcc-base-unix.conf)
-DEFINES += Q_OS_LINUX_ANDROID
DEFINES += QT_NO_PRINTER QT_NO_PRINTDIALOG
QT_QPA_DEFAULT_PLATFORM = minimal
@@ -110,7 +109,6 @@ QMAKE_LIBS_QT_OPENGL =
QMAKE_LIBS_QTOPIA =
QMAKE_LIBS_THREAD =
QMAKE_LIBS_OPENGL =
-QMAKE_LIBS_OPENGL_QT =
QMAKE_LIBS_OPENGL_ES1 = -lGLESv1_CM
QMAKE_LIBS_OPENGL_ES2 = -lGLESv2 $$QMAKE_LIBS
diff --git a/mkspecs/common/linux.conf b/mkspecs/common/linux.conf
index 107aeb74eb..1c46ab7c21 100644
--- a/mkspecs/common/linux.conf
+++ b/mkspecs/common/linux.conf
@@ -2,58 +2,57 @@
# qmake configuration for common linux
#
-QMAKE_PLATFORM += linux
+QMAKE_PLATFORM += linux
-QMAKE_CFLAGS_THREAD += -D_REENTRANT
-QMAKE_CXXFLAGS_THREAD += $$QMAKE_CFLAGS_THREAD
+QMAKE_CFLAGS_THREAD += -D_REENTRANT
+QMAKE_CXXFLAGS_THREAD += $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
QMAKE_INCDIR_OPENGL_ES1 = $$QMAKE_INCDIR_OPENGL
QMAKE_LIBDIR_OPENGL_ES1 = $$QMAKE_LIBDIR_OPENGL
QMAKE_INCDIR_OPENGL_ES2 = $$QMAKE_INCDIR_OPENGL
QMAKE_LIBDIR_OPENGL_ES2 = $$QMAKE_LIBDIR_OPENGL
-QMAKE_INCDIR_EGL =
-QMAKE_LIBDIR_EGL =
-QMAKE_INCDIR_OPENVG =
-QMAKE_LIBDIR_OPENVG =
-
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_NIS = -lnsl
-QMAKE_LIBS_EGL = -lEGL
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_OPENGL_ES1 = -lGLESv1_CM
-QMAKE_LIBS_OPENGL_ES2 = -lGLESv2
-QMAKE_LIBS_OPENVG = -lOpenVG
-QMAKE_LIBS_THREAD = -lpthread
-QMAKE_LIBS_LIBUDEV = -ludev
-
-QMAKE_CFLAGS_WAYLAND =
-QMAKE_INCDIR_WAYLAND =
+QMAKE_INCDIR_EGL =
+QMAKE_LIBDIR_EGL =
+QMAKE_INCDIR_OPENVG =
+QMAKE_LIBDIR_OPENVG =
+
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_NIS = -lnsl
+QMAKE_LIBS_EGL = -lEGL
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_OPENGL_ES1 = -lGLESv1_CM
+QMAKE_LIBS_OPENGL_ES2 = -lGLESv2
+QMAKE_LIBS_OPENVG = -lOpenVG
+QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS_LIBUDEV = -ludev
+
+QMAKE_CFLAGS_WAYLAND =
+QMAKE_INCDIR_WAYLAND =
QMAKE_LIBS_WAYLAND_CLIENT = -lwayland-client
QMAKE_LIBS_WAYLAND_SERVER = -lwayland-server
-QMAKE_LIBDIR_WAYLAND =
-QMAKE_DEFINES_WAYLAND =
-QMAKE_WAYLAND_SCANNER = wayland-scanner
-
-QMAKE_CFLAGS_XCB =
-QMAKE_LIBS_XCB =
-QMAKE_DEFINES_XCB =
-
-QMAKE_AR = ar cqs
-QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
-
-QMAKE_STRIP = strip
-QMAKE_STRIPFLAGS_LIB += --strip-unneeded
-QMAKE_INSTALL_FILE = install -m 644 -p
-QMAKE_INSTALL_PROGRAM = install -m 755 -p
+QMAKE_LIBDIR_WAYLAND =
+QMAKE_DEFINES_WAYLAND =
+QMAKE_WAYLAND_SCANNER = wayland-scanner
+
+QMAKE_CFLAGS_XCB =
+QMAKE_LIBS_XCB =
+QMAKE_DEFINES_XCB =
+
+QMAKE_AR = ar cqs
+QMAKE_OBJCOPY = objcopy
+QMAKE_RANLIB =
+
+QMAKE_STRIP = strip
+QMAKE_STRIPFLAGS_LIB += --strip-unneeded
+QMAKE_INSTALL_FILE = install -m 644 -p
+QMAKE_INSTALL_PROGRAM = install -m 755 -p
include(unix.conf)
diff --git a/mkspecs/common/llvm.conf b/mkspecs/common/llvm.conf
index 7d0622de59..8f6946f9a2 100644
--- a/mkspecs/common/llvm.conf
+++ b/mkspecs/common/llvm.conf
@@ -2,17 +2,17 @@
# Qmake configuration for LLVM on Linux and Mac
#
-QMAKE_COMPILER = gcc llvm
+QMAKE_COMPILER = gcc llvm
-QMAKE_CC = llvm-gcc
-QMAKE_CXX = llvm-g++
+QMAKE_CC = llvm-gcc
+QMAKE_CXX = llvm-g++
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
+QMAKE_LINK = $$QMAKE_CXX
+QMAKE_LINK_SHLIB = $$QMAKE_CXX
-QMAKE_PCH_OUTPUT_EXT = .gch
+QMAKE_PCH_OUTPUT_EXT = .gch
QMAKE_CFLAGS_PRECOMPILE = -x c-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_CFLAGS_USE_PRECOMPILE = -include ${QMAKE_PCH_OUTPUT_BASE}
QMAKE_CXXFLAGS_PRECOMPILE = -x c++-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
-QMAKE_CXXFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE \ No newline at end of file
+QMAKE_CXXFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
diff --git a/mkspecs/common/mac-clang-libc++-minimum-version.conf b/mkspecs/common/mac-clang-libc++-minimum-version.conf
deleted file mode 100644
index 0941970b13..0000000000
--- a/mkspecs/common/mac-clang-libc++-minimum-version.conf
+++ /dev/null
@@ -1,5 +0,0 @@
-# clang libc++ requires 10.7
-QMAKE_CFLAGS += -mmacosx-version-min=10.7
-QMAKE_CXXFLAGS += -mmacosx-version-min=10.7
-QMAKE_OBJECTIVE_CFLAGS += -mmacosx-version-min=10.7
-QMAKE_LFLAGS += -mmacosx-version-min=10.7
diff --git a/mkspecs/common/mac-minimum-version.conf b/mkspecs/common/mac-minimum-version.conf
deleted file mode 100644
index acb4132cb6..0000000000
--- a/mkspecs/common/mac-minimum-version.conf
+++ /dev/null
@@ -1,4 +0,0 @@
-QMAKE_CFLAGS += -mmacosx-version-min=10.6
-QMAKE_LFLAGS += -mmacosx-version-min=10.6
-QMAKE_CXXFLAGS += -mmacosx-version-min=10.6
-QMAKE_OBJECTIVE_CFLAGS += -mmacosx-version-min=10.6
diff --git a/mkspecs/common/mac.conf b/mkspecs/common/mac.conf
index e318cb775e..f31db3bb4b 100644
--- a/mkspecs/common/mac.conf
+++ b/mkspecs/common/mac.conf
@@ -1,30 +1,32 @@
#
-# qmake configuration for common Mac OS X
+# qmake configuration for common Mac OS (OSX and iOS)
#
-!load(device_config) {
- error(Could not successfully load device configuration)
-}
-QMAKE_PLATFORM += macx mac
+!load(device_config): error(Could not successfully load device configuration)
-QMAKE_RESOURCE = /Developer/Tools/Rez
+QMAKE_PLATFORM += mac
-QMAKE_EXTENSION_SHLIB = dylib
+QMAKE_RESOURCE = /Developer/Tools/Rez
+QMAKE_EXTENSION_SHLIB = dylib
+QMAKE_LIBDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_OPENGL = $$QMAKE_MAC_SDK/System/Library/Frameworks/OpenGL.framework/Headers \
- $$QMAKE_MAC_SDK/System/Library/Frameworks/AGL.framework/Headers/
+# sdk.prf will prefix the proper SDK sysroot
+QMAKE_INCDIR_OPENGL = \
+ /System/Library/Frameworks/OpenGL.framework/Headers \
+ /System/Library/Frameworks/AGL.framework/Headers/
-QMAKE_FIX_RPATH = install_name_tool -id
+QMAKE_FIX_RPATH = install_name_tool -id
-QMAKE_LFLAGS_RPATH =
+QMAKE_LFLAGS_RPATH =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_OPENGL = -framework OpenGL -framework AGL
-QMAKE_LIBS_OPENGL_QT = $$QMAKE_LIBS_OPENGL
-QMAKE_LIBS_THREAD =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_OPENGL = -framework OpenGL -framework AGL
+QMAKE_LIBS_THREAD =
-QMAKE_AR = ar cq
-QMAKE_RANLIB = ranlib -s
+QMAKE_AR = ar cq
+QMAKE_RANLIB = ranlib -s
+
+# We rely on Xcode to build
+include(xcode.conf)
include(unix.conf)
diff --git a/mkspecs/common/mac/qplatformdefs.h b/mkspecs/common/mac/qplatformdefs.h
index 88a71dbd3e..7ee337cce4 100644
--- a/mkspecs/common/mac/qplatformdefs.h
+++ b/mkspecs/common/mac/qplatformdefs.h
@@ -42,8 +42,6 @@
#ifndef QPLATFORMDEFS_H
#define QPLATFORMDEFS_H
-#define QT_QPA_DEFAULT_PLATFORM_NAME "cocoa"
-
// Get Qt defines/settings
#include "qglobal.h"
@@ -85,11 +83,7 @@
#define QT_OPEN_LARGEFILE 0
-#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4)
#define QT_SOCKLEN_T socklen_t
-#else
-#define QT_SOCKLEN_T int
-#endif
#define QT_SIGNAL_IGNORE (void (*)(int))1
diff --git a/mkspecs/common/macx.conf b/mkspecs/common/macx.conf
new file mode 100644
index 0000000000..7f9f54ec12
--- /dev/null
+++ b/mkspecs/common/macx.conf
@@ -0,0 +1,8 @@
+#
+# qmake configuration for common Mac OS X
+#
+
+QMAKE_PLATFORM += macx
+QMAKE_MAC_SDK = macosx
+
+include(mac.conf)
diff --git a/mkspecs/common/nacl/nacl-base.conf b/mkspecs/common/nacl/nacl-base.conf
index 20a0f7507e..d94c5c96d7 100644
--- a/mkspecs/common/nacl/nacl-base.conf
+++ b/mkspecs/common/nacl/nacl-base.conf
@@ -1,11 +1,11 @@
-QMAKE_PLATFORM = nacl $$QMAKE_PLATFORM
+QMAKE_PLATFORM = nacl $$QMAKE_PLATFORM
# Work around linker crash when using PIC. We are building
# statically so this is safe.
QMAKE_CFLAGS_STATIC_LIB -= -fPIC
-QMAKE_CFLAGS_SHLIB -= -fPIC
+QMAKE_CFLAGS_SHLIB -= -fPIC
QMAKE_CXXFLAGS_STATIC_LIB -= -fPIC
-QMAKE_CXXFLAGS_SHLIB -= -fPIC
+QMAKE_CXXFLAGS_SHLIB -= -fPIC
-QMAKE_LIBS_DYNLOAD -= -ldl
-QMAKE_LIBS_OPENGL_ES2 = -lppapi_gles2
+QMAKE_LIBS_DYNLOAD -= -ldl
+QMAKE_LIBS_OPENGL_ES2 = -lppapi_gles2
diff --git a/mkspecs/common/qcc-base-qnx.conf b/mkspecs/common/qcc-base-qnx.conf
index b1bae7122d..d28fe1fc63 100644
--- a/mkspecs/common/qcc-base-qnx.conf
+++ b/mkspecs/common/qcc-base-qnx.conf
@@ -4,17 +4,17 @@
include(qcc-base.conf)
-CONFIG += qnx
+CONFIG += qnx
#Choose qnx QPA Plugin as default
QT_QPA_DEFAULT_PLATFORM = qnx
-QMAKE_LFLAGS_SHLIB += -shared
-QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME += -Wl,-soname,
-QMAKE_LFLAGS_THREAD +=
-QMAKE_LFLAGS_RPATH = -Wl,-rpath,
-QMAKE_LFLAGS_RPATHLINK = -Wl,-rpath-link,
+QMAKE_LFLAGS_SHLIB += -shared
+QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME += -Wl,-soname,
+QMAKE_LFLAGS_THREAD +=
+QMAKE_LFLAGS_RPATH = -Wl,-rpath,
+QMAKE_LFLAGS_RPATHLINK = -Wl,-rpath-link,
# -Bsymbolic-functions (ld) support
QMAKE_LFLAGS_BSYMBOLIC_FUNC = -Wl,-Bsymbolic-functions
@@ -23,7 +23,7 @@ QMAKE_LFLAGS_DYNAMIC_LIST = -Wl,--dynamic-list,
# Generic options for all BlackBerry/QNX qcc mkspecs
QMAKE_CFLAGS_THREAD = -D_REENTRANT
QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_COMPILER_DEFINES += __QNXNTO__
+QMAKE_COMPILER_DEFINES += __QNXNTO__
QMAKE_LIBS = -lm
QMAKE_LIBS_NETWORK = -lsocket
@@ -37,9 +37,8 @@ QMAKE_LIBS_EGL = -lEGL
# against the NDK's target directory which is referenced by the QNX_TARGET environment
# variable, and which is guaranteed by the NDK to be set.
QNX_DIR = $$(QNX_TARGET)
-
isEmpty(QNX_DIR) {
- error(QNX_TARGET environment variable not set)
+ error("QNX_TARGET environment variable not set")
}
QMAKE_INCDIR = $${QNX_DIR}/usr/include $${QNX_DIR}/usr/include/freetype2
@@ -54,7 +53,7 @@ QMAKE_LINK_C_SHLIB = $$QMAKE_CC
QMAKE_LINK = $$QMAKE_CXX
QMAKE_LINK_SHLIB = $$QMAKE_CXX
-QMAKE_STRIPFLAGS_LIB += --strip-unneeded
+QMAKE_STRIPFLAGS_LIB += --strip-unneeded
equals(QMAKE_HOST.os, Windows) {
isEmpty(QMAKE_SH): error("This mkspec requires an MSYS environment.")
diff --git a/mkspecs/common/qcc-base.conf b/mkspecs/common/qcc-base.conf
index 76d3d1362f..32645e539a 100644
--- a/mkspecs/common/qcc-base.conf
+++ b/mkspecs/common/qcc-base.conf
@@ -9,44 +9,44 @@
# 2) -Wno-psabi is added to silence harmless warnings about va_list mangling
#
-QMAKE_COMPILER = rim_qcc gcc # qcc is mostly gcc in disguise
+QMAKE_COMPILER = rim_qcc gcc # qcc is mostly gcc in disguise
-QMAKE_CFLAGS += -Wno-psabi
-QMAKE_CFLAGS_DEPS += -M
-QMAKE_CFLAGS_WARN_ON += -Wall -W
-QMAKE_CFLAGS_WARN_OFF += -w
-QMAKE_CFLAGS_RELEASE += -O2
-QMAKE_CFLAGS_DEBUG += -g
-QMAKE_CFLAGS_SHLIB += -fPIC -shared
-QMAKE_CFLAGS_STATIC_LIB += -fPIC
-QMAKE_CFLAGS_APP += -fPIE
-QMAKE_CFLAGS_YACC += -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_HIDESYMS += -fvisibility=hidden
-QMAKE_CFLAGS_SSE2 += -msse2
-QMAKE_CFLAGS_SSE3 += -msse3
-QMAKE_CFLAGS_SSSE3 += -mssse3
-QMAKE_CFLAGS_SSE4_1 += -msse4.1
-QMAKE_CFLAGS_SSE4_2 += -msse4.2
-QMAKE_CFLAGS_AVX += -mavx
-QMAKE_CFLAGS_AVX2 += -mavx2
-QMAKE_CFLAGS_IWMMXT += -mcpu=iwmmxt
-QMAKE_CFLAGS_NEON += -mfpu=neon
+QMAKE_CFLAGS += -Wno-psabi
+QMAKE_CFLAGS_DEPS += -M
+QMAKE_CFLAGS_WARN_ON += -Wall -W
+QMAKE_CFLAGS_WARN_OFF += -w
+QMAKE_CFLAGS_RELEASE += -O2
+QMAKE_CFLAGS_DEBUG += -g
+QMAKE_CFLAGS_SHLIB += -fPIC -shared
+QMAKE_CFLAGS_STATIC_LIB += -fPIC
+QMAKE_CFLAGS_APP += -fPIE
+QMAKE_CFLAGS_YACC += -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_HIDESYMS += -fvisibility=hidden
+QMAKE_CFLAGS_SSE2 += -msse2
+QMAKE_CFLAGS_SSE3 += -msse3
+QMAKE_CFLAGS_SSSE3 += -mssse3
+QMAKE_CFLAGS_SSE4_1 += -msse4.1
+QMAKE_CFLAGS_SSE4_2 += -msse4.2
+QMAKE_CFLAGS_AVX += -mavx
+QMAKE_CFLAGS_AVX2 += -mavx2
+QMAKE_CFLAGS_IWMMXT += -mcpu=iwmmxt
+QMAKE_CFLAGS_NEON += -mfpu=neon
-QMAKE_CXXFLAGS += $$QMAKE_CFLAGS -lang-c++
-QMAKE_CXXFLAGS_DEPS += $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON += $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF += $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG += $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB += $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXXFLAGS += $$QMAKE_CFLAGS -lang-c++
+QMAKE_CXXFLAGS_DEPS += $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON += $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF += $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG += $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB += $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB += $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_APP += $$QMAKE_CFLAGS_APP
-QMAKE_CXXFLAGS_YACC += $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_HIDESYMS += $$QMAKE_CFLAGS_HIDESYMS -fvisibility-inlines-hidden
+QMAKE_CXXFLAGS_APP += $$QMAKE_CFLAGS_APP
+QMAKE_CXXFLAGS_YACC += $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_HIDESYMS += $$QMAKE_CFLAGS_HIDESYMS -fvisibility-inlines-hidden
QMAKE_CFLAGS_PRECOMPILE = -x c-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_CFLAGS_USE_PRECOMPILE = -Wc,-include -Wc,${QMAKE_PCH_OUTPUT_BASE}
QMAKE_CXXFLAGS_PRECOMPILE = -x c++-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_CXXFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
-QMAKE_LFLAGS += -lang-c++
+QMAKE_LFLAGS += -lang-c++
diff --git a/mkspecs/common/shell-unix.conf b/mkspecs/common/shell-unix.conf
index 63c435d037..a533e77cb5 100644
--- a/mkspecs/common/shell-unix.conf
+++ b/mkspecs/common/shell-unix.conf
@@ -1,14 +1,14 @@
-QMAKE_TAR = tar -cf
-QMAKE_GZIP = gzip -9f
+QMAKE_TAR = tar -cf
+QMAKE_GZIP = gzip -9f
-QMAKE_COPY = cp -f
-QMAKE_COPY_FILE = $$QMAKE_COPY
-QMAKE_COPY_DIR = $$QMAKE_COPY -R
-QMAKE_MOVE = mv -f
-QMAKE_DEL_FILE = rm -f
-QMAKE_DEL_DIR = rmdir
-QMAKE_CHK_EXISTS = test -e %1 ||
-QMAKE_CHK_DIR_EXISTS = test -d # legacy
-QMAKE_MKDIR = mkdir -p # legacy
-QMAKE_MKDIR_CMD = test -d %1 || mkdir -p %1
-QMAKE_STREAM_EDITOR = sed
+QMAKE_COPY = cp -f
+QMAKE_COPY_FILE = $$QMAKE_COPY
+QMAKE_COPY_DIR = $$QMAKE_COPY -R
+QMAKE_MOVE = mv -f
+QMAKE_DEL_FILE = rm -f
+QMAKE_DEL_DIR = rmdir
+QMAKE_CHK_EXISTS = test -e %1 ||
+QMAKE_CHK_DIR_EXISTS = test -d # legacy
+QMAKE_MKDIR = mkdir -p # legacy
+QMAKE_MKDIR_CMD = test -d %1 || mkdir -p %1
+QMAKE_STREAM_EDITOR = sed
diff --git a/mkspecs/common/shell-win32.conf b/mkspecs/common/shell-win32.conf
index 77c9698388..131aa746c4 100644
--- a/mkspecs/common/shell-win32.conf
+++ b/mkspecs/common/shell-win32.conf
@@ -1,14 +1,16 @@
-QMAKE_ZIP = zip -r -9
-
-QMAKE_COPY = copy /y
-QMAKE_COPY_DIR = xcopy /s /q /y /i
-QMAKE_MOVE = move
-QMAKE_DEL_FILE = del
-QMAKE_DEL_DIR = rmdir
-QMAKE_CHK_EXISTS = if not exist %1
-QMAKE_CHK_DIR_EXISTS = if not exist # legacy
-QMAKE_MKDIR = mkdir # legacy
-QMAKE_MKDIR_CMD = if not exist %1 mkdir %1 & if not exist %1 exit 1
+QMAKE_ZIP = zip -r -9
+QMAKE_COPY = copy /y
+QMAKE_COPY_DIR = xcopy /s /q /y /i
+QMAKE_MOVE = move
+QMAKE_DEL_FILE = del
+QMAKE_DEL_DIR = rmdir
+QMAKE_CHK_EXISTS = if not exist %1
+QMAKE_CHK_DIR_EXISTS = if not exist # legacy
+QMAKE_MKDIR = mkdir # legacy
+QMAKE_MKDIR_CMD = if not exist %1 mkdir %1 & if not exist %1 exit 1
+# Ugly hack to support cross-building for unix (android).
+QMAKE_SYMBOLIC_LINK = $$QMAKE_COPY
+QMAKE_LN_SHLIB = $$QMAKE_SYMBOLIC_LINK
# xcopy copies the contained files if source is a directory. Deal with it.
-CONFIG += copy_dir_files
+CONFIG += copy_dir_files
diff --git a/mkspecs/common/unix.conf b/mkspecs/common/unix.conf
index a8f8c57323..c0deafd141 100644
--- a/mkspecs/common/unix.conf
+++ b/mkspecs/common/unix.conf
@@ -2,13 +2,13 @@
# qmake configuration for common unix
#
-QMAKE_PLATFORM += unix posix
+QMAKE_PLATFORM += unix posix
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS +=
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS += -d
-QMAKE_YACCFLAGS_MANGLE += -p $base -b $base
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS +=
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS += -d
+QMAKE_YACCFLAGS_MANGLE += -p $base -b $base
QMAKE_YACC_HEADER = $base.tab.h
QMAKE_YACC_SOURCE = $base.tab.c
QMAKE_PREFIX_SHLIB = lib
diff --git a/mkspecs/common/wince/qmake.conf b/mkspecs/common/wince/qmake.conf
index 46f002a360..b006992702 100644
--- a/mkspecs/common/wince/qmake.conf
+++ b/mkspecs/common/wince/qmake.conf
@@ -2,80 +2,80 @@
# qmake configuration for common Windows CE
#
-MAKEFILE_GENERATOR = MSVC.NET
-QMAKE_PLATFORM += wince win32
-CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target
+MAKEFILE_GENERATOR = MSVC.NET
+QMAKE_PLATFORM += wince win32
+CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target
-DEFINES += UNDER_CE WINCE _WINDOWS _UNICODE UNICODE _WIN32 QT_NO_PRINTER QT_NO_PRINTDIALOG
+DEFINES += UNDER_CE WINCE _WINDOWS _UNICODE UNICODE _WIN32 QT_NO_PRINTER QT_NO_PRINTDIALOG
-QMAKE_COMPILER_DEFINES += _MSC_VER=1400
+QMAKE_COMPILER_DEFINES += _MSC_VER=1400
-QMAKE_COMPILER = msvc
+QMAKE_COMPILER = msvc
-QMAKE_CC = cl
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = byacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -nologo -Zm200 -Zc:wchar_t-
-QMAKE_CFLAGS_WARN_ON = -W3
-QMAKE_CFLAGS_WARN_OFF = -W0
+QMAKE_CC = cl
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = byacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -nologo -Zm200 -Zc:wchar_t-
+QMAKE_CFLAGS_WARN_ON = -W3
+QMAKE_CFLAGS_WARN_OFF = -W0
QMAKE_CFLAGS_RELEASE = -O2 -MD
QMAKE_CFLAGS_LTCG = -GL
-QMAKE_CFLAGS_DEBUG = -DDEBUG -D_DEBUG -Zi -MDd
-QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_DEBUG = -DDEBUG -D_DEBUG -Zi -MDd
+QMAKE_CFLAGS_YACC =
# Uncomment the following lines to reduce library sizes
# with potential cost of performance
# QMAKE_CFLAGS += -Os
# QMAKE_CFLAGS_RELEASE += -Os
-QMAKE_CXX = $$QMAKE_CC
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON -w34100 -w34189
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXX = $$QMAKE_CC
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON -w34100 -w34189
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
QMAKE_CXXFLAGS_LTCG = $$QMAKE_CFLAGS_LTCG
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_STL_ON = -EHsc
-QMAKE_CXXFLAGS_STL_OFF =
-QMAKE_CXXFLAGS_RTTI_ON = -GR
-QMAKE_CXXFLAGS_RTTI_OFF =
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_STL_ON = -EHsc
+QMAKE_CXXFLAGS_STL_OFF =
+QMAKE_CXXFLAGS_RTTI_ON = -GR
+QMAKE_CXXFLAGS_RTTI_OFF =
QMAKE_CXXFLAGS_EXCEPTIONS_ON = -EHsc
QMAKE_CXXFLAGS_EXCEPTIONS_OFF = -EHs-c-
-QMAKE_INCDIR =
+QMAKE_INCDIR =
-QMAKE_RUN_CC = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$obj $src
-QMAKE_RUN_CC_IMP = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$@ $<
-QMAKE_RUN_CC_IMP_BATCH = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$@ @<<
-QMAKE_RUN_CXX = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$obj $src
-QMAKE_RUN_CXX_IMP = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$@ $<
-QMAKE_RUN_CXX_IMP_BATCH = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$@ @<<
+QMAKE_RUN_CC = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$obj $src
+QMAKE_RUN_CC_IMP = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$@ $<
+QMAKE_RUN_CC_IMP_BATCH = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$@ @<<
+QMAKE_RUN_CXX = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$obj $src
+QMAKE_RUN_CXX_IMP = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$@ $<
+QMAKE_RUN_CXX_IMP_BATCH = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$@ @<<
-QMAKE_LINK = link
-QMAKE_LFLAGS = /NOLOGO /NODEFAULTLIB:OLDNAMES.LIB
+QMAKE_LINK = link
+QMAKE_LFLAGS = /NOLOGO /NODEFAULTLIB:OLDNAMES.LIB
QMAKE_LFLAGS_RELEASE = /INCREMENTAL:NO
-QMAKE_LFLAGS_DEBUG = /DEBUG
+QMAKE_LFLAGS_DEBUG = /DEBUG
QMAKE_LFLAGS_LTCG = /LTCG
QMAKE_LIBS_NETWORK = ws2.lib
-QMAKE_LIBS_OPENGL =
-QMAKE_LIBS_COMPAT =
+QMAKE_LIBS_OPENGL =
+QMAKE_LIBS_COMPAT =
QMAKE_LIBS_EGL = libEGL.lib
-QMAKE_LIBS_OPENGL_ES1 = libGLES_CM.lib
-QMAKE_LIBS_OPENGL_ES2 = libGLESv2.lib
+QMAKE_LIBS_OPENGL_ES1 = libGLES_CM.lib
+QMAKE_LIBS_OPENGL_ES2 = libGLESv2.lib
-QMAKE_LIBS_QT_ENTRY = -lqtmain
+QMAKE_LIBS_QT_ENTRY = -lqtmain
-QMAKE_IDL = midl
-QMAKE_LIB = lib
-QMAKE_RC = rc
+QMAKE_IDL = midl
+QMAKE_LIB = lib
+QMAKE_RC = rc
include(../shell-win32.conf)
-VCPROJ_EXTENSION = .vcproj
-VCSOLUTION_EXTENSION = .sln
-VCPROJ_KEYWORD = Qt4VSv1.0
+VCPROJ_EXTENSION = .vcproj
+VCSOLUTION_EXTENSION = .sln
+VCPROJ_KEYWORD = Qt4VSv1.0
load(qt_config)
diff --git a/mkspecs/common/xcode.conf b/mkspecs/common/xcode.conf
new file mode 100644
index 0000000000..b15266b678
--- /dev/null
+++ b/mkspecs/common/xcode.conf
@@ -0,0 +1,21 @@
+#
+# qmake configuration for Xcode
+#
+
+# Get path of Xcode's Developer directory
+QMAKE_XCODE_DEVELOPER_PATH = $$system("/usr/bin/xcode-select --print-path 2>/dev/null")
+isEmpty(QMAKE_XCODE_DEVELOPER_PATH): \
+ error("Xcode path is not set. Please use xcode-select to choose Xcode installation path.")
+
+# Make sure Xcode path is valid
+!exists($$QMAKE_XCODE_DEVELOPER_PATH): \
+ error("Xcode is not installed in $${QMAKE_XCODE_DEVELOPER_PATH}. Please use xcode-select to choose Xcode installation path.")
+
+# Make sure Xcode is set up properly
+isEmpty($$list($$system("/usr/bin/xcrun -find xcrun 2>/dev/null"))): \
+ error("Xcode not set up properly. You may need to confirm the license agreement by running /usr/bin/xcodebuild.")
+
+# Extract Xcode version using xcodebuild
+xcode_version = $$system("/usr/bin/xcodebuild -version")
+QMAKE_XCODE_VERSION = $$member(xcode_version, 1)
+unset(xcode_version)
diff --git a/mkspecs/cygwin-g++/qmake.conf b/mkspecs/cygwin-g++/qmake.conf
index 3c53122707..a8e9d41485 100644
--- a/mkspecs/cygwin-g++/qmake.conf
+++ b/mkspecs/cygwin-g++/qmake.conf
@@ -4,74 +4,73 @@
# Written for Qt/X11 on Windows using Cygwin's POSIX API
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = cygwin unix posix
-CONFIG += incremental
-QMAKE_INCREMENTAL_STYLE = sublib
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = cygwin unix posix
+CONFIG += incremental
+QMAKE_INCREMENTAL_STYLE = sublib
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = byacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -pipe
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB =
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD = -D_REENTRANT
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = byacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -pipe
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB =
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -D_REENTRANT
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = /usr/X11R6/include
-QMAKE_LIBDIR_X11 = /usr/X11R6/lib
-QMAKE_INCDIR_OPENGL = /usr/X11R6/include
-QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = /usr/X11R6/include
+QMAKE_LIBDIR_X11 = /usr/X11R6/lib
+QMAKE_INCDIR_OPENGL = /usr/X11R6/include
+QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,-soname,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_RPATH = -Wl,-rpath,
-QMAKE_CYGWIN_SHLIB = 1
-QMAKE_CYGWIN_EXE = 1
-
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,-soname,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_RPATH = -Wl,-rpath,
+QMAKE_CYGWIN_SHLIB = 1
+QMAKE_CYGWIN_EXE = 1
+
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread
QMAKE_PREFIX_SHLIB = lib
QMAKE_PREFIX_STATICLIB = lib
QMAKE_EXTENSION_STATICLIB = a
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/shell-unix.conf)
load(qt_config)
diff --git a/mkspecs/darwin-g++/qmake.conf b/mkspecs/darwin-g++/qmake.conf
index 57bfb94ba2..21a13a3bb5 100644
--- a/mkspecs/darwin-g++/qmake.conf
+++ b/mkspecs/darwin-g++/qmake.conf
@@ -4,80 +4,79 @@
# Written for Qt/X11 on Darwin and XFree86
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = mac macx
-CONFIG += native_precompiled_headers
-DEFINES += __USE_WS_X11__
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = mac macx
+CONFIG += native_precompiled_headers
+DEFINES += __USE_WS_X11__
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = cc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -pipe
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_EXTENSION_SHLIB = dylib
-QMAKE_EXTENSION_PLUGIN = so
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_HIDESYMS += -fvisibility=hidden
-QMAKE_CFLAGS_THREAD =
-QMAKE_CFLAGS_PRECOMPILE += -x c-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
+QMAKE_CC = cc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -pipe
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_EXTENSION_SHLIB = dylib
+QMAKE_EXTENSION_PLUGIN = so
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_HIDESYMS += -fvisibility=hidden
+QMAKE_CFLAGS_THREAD =
+QMAKE_CFLAGS_PRECOMPILE += -x c-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_CFLAGS_USE_PRECOMPILE += -include ${QMAKE_PCH_OUTPUT_BASE}
-QMAKE_CXX = c++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = c++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_HIDESYMS += $$QMAKE_CFLAGS_HIDESYMS -fvisibility-inlines-hidden
-QMAKE_CXXFLAGS_THREAD =
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_HIDESYMS += $$QMAKE_CFLAGS_HIDESYMS -fvisibility-inlines-hidden
+QMAKE_CXXFLAGS_THREAD =
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = /usr/X11R6/include
-QMAKE_LIBDIR_X11 = /usr/X11R6/lib
-QMAKE_INCDIR_OPENGL = /usr/X11R6/include
-QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = /usr/X11R6/include
+QMAKE_LIBDIR_X11 = /usr/X11R6/lib
+QMAKE_INCDIR_OPENGL = /usr/X11R6/include
+QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
-QMAKE_LINK = c++
-QMAKE_LINK_SHLIB = c++
-QMAKE_LFLAGS += -headerpad_max_install_names
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
+QMAKE_LINK = c++
+QMAKE_LINK_SHLIB = c++
+QMAKE_LFLAGS += -headerpad_max_install_names
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
QMAKE_LFLAGS_APP = -prebind
-QMAKE_LFLAGS_SHLIB = -prebind -dynamiclib -single_module
-QMAKE_LFLAGS_PLUGIN = -prebind -bundle
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_SONAME += -install_name$${LITERAL_WHITESPACE}
+QMAKE_LFLAGS_SHLIB = -prebind -dynamiclib -single_module
+QMAKE_LFLAGS_PLUGIN = -prebind -bundle
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_SONAME += -install_name$${LITERAL_WHITESPACE}
QMAKE_LFLAGS_VERSION = -current_version$${LITERAL_WHITESPACE}
QMAKE_LFLAGS_COMPAT_VERSION = -compatibility_version$${LITERAL_WHITESPACE}
-QMAKE_LFLAGS_RPATH =
+QMAKE_LFLAGS_RPATH =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD =
-QMAKE_AR = ar cq
+QMAKE_AR = ar cq
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB = ranlib -s
+QMAKE_RANLIB = ranlib -s
QMAKE_PCH_OUTPUT_EXT = .gch
diff --git a/mkspecs/devices/blackberry-playbook-armv7le-qcc/qmake.conf b/mkspecs/devices/blackberry-playbook-armv7le-qcc/qmake.conf
index 07bc437e34..cc7435d1dc 100644
--- a/mkspecs/devices/blackberry-playbook-armv7le-qcc/qmake.conf
+++ b/mkspecs/devices/blackberry-playbook-armv7le-qcc/qmake.conf
@@ -5,3 +5,4 @@
include(../../blackberry-armv7le-qcc/qmake.conf)
DEFINES += Q_OS_BLACKBERRY_TABLET
+CONFIG += blackberry-playbook
diff --git a/mkspecs/devices/blackberry-playbook-x86-qcc/qmake.conf b/mkspecs/devices/blackberry-playbook-x86-qcc/qmake.conf
index 054e634ac8..ed9f7f33c7 100644
--- a/mkspecs/devices/blackberry-playbook-x86-qcc/qmake.conf
+++ b/mkspecs/devices/blackberry-playbook-x86-qcc/qmake.conf
@@ -5,3 +5,4 @@
include(../../blackberry-x86-qcc/qmake.conf)
DEFINES += Q_OS_BLACKBERRY_TABLET
+CONFIG += blackberry-playbook
diff --git a/mkspecs/devices/common/linux_device_pre.conf b/mkspecs/devices/common/linux_device_pre.conf
index ef9280b1f6..6d80fc7e1d 100644
--- a/mkspecs/devices/common/linux_device_pre.conf
+++ b/mkspecs/devices/common/linux_device_pre.conf
@@ -1,7 +1,7 @@
QT_QPA_DEFAULT_PLATFORM = eglfs
-MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../../common/linux.conf)
diff --git a/mkspecs/devices/linux-archos-gen8-g++/qmake.conf b/mkspecs/devices/linux-archos-gen8-g++/qmake.conf
index a480d072cc..a2c831e7fe 100644
--- a/mkspecs/devices/linux-archos-gen8-g++/qmake.conf
+++ b/mkspecs/devices/linux-archos-gen8-g++/qmake.conf
@@ -7,7 +7,7 @@
# http://github.com/KDAB/OpenEmbedded-Archos
MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../../common/linux.conf)
diff --git a/mkspecs/devices/linux-arm-amlogic-8726M-g++/qmake.conf b/mkspecs/devices/linux-arm-amlogic-8726M-g++/qmake.conf
index afc0814907..3f884ccb88 100644
--- a/mkspecs/devices/linux-arm-amlogic-8726M-g++/qmake.conf
+++ b/mkspecs/devices/linux-arm-amlogic-8726M-g++/qmake.conf
@@ -2,8 +2,8 @@
# qmake configuration for linux-g++
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../../common/linux.conf)
diff --git a/mkspecs/devices/linux-arm-trident-pnx8473-g++/qmake.conf b/mkspecs/devices/linux-arm-trident-pnx8473-g++/qmake.conf
index 21751453cb..3c8c78e0c7 100644
--- a/mkspecs/devices/linux-arm-trident-pnx8473-g++/qmake.conf
+++ b/mkspecs/devices/linux-arm-trident-pnx8473-g++/qmake.conf
@@ -5,7 +5,7 @@
#
MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../../common/linux.conf)
@@ -31,23 +31,23 @@ QMAKE_LINK_SHLIB = $${CROSS_COMPILE}g++
#
# Because of this fact not using "-sysroot <sysroot path>" and hence following code is required
#
-QMAKE_CFLAGS += --sysroot=$${TRIDENT_SHINER_SDK_BUILDTREE}/open_source_archive/linux/toolchains/gcc-4.5.2_uclibc/
-QMAKE_CXXFLAGS += --sysroot=$${TRIDENT_SHINER_SDK_BUILDTREE}/open_source_archive/linux/toolchains/gcc-4.5.2_uclibc/
-QMAKE_LFLAGS += --sysroot=$${TRIDENT_SHINER_SDK_BUILDTREE}/open_source_archive/linux/toolchains/gcc-4.5.2_uclibc/
+QMAKE_CFLAGS += --sysroot=$${TRIDENT_SHINER_SDK_BUILDTREE}/open_source_archive/linux/toolchains/gcc-4.5.2_uclibc/
+QMAKE_CXXFLAGS += --sysroot=$${TRIDENT_SHINER_SDK_BUILDTREE}/open_source_archive/linux/toolchains/gcc-4.5.2_uclibc/
+QMAKE_LFLAGS += --sysroot=$${TRIDENT_SHINER_SDK_BUILDTREE}/open_source_archive/linux/toolchains/gcc-4.5.2_uclibc/
deviceSanityCheckCompiler()
-QMAKE_CFLAGS = -march=armv7-a -mfpu=vfpv3-d16 -mfloat-abi=hard
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CFLAGS = -march=armv7-a -mfpu=vfpv3-d16 -mfloat-abi=hard
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
# modifications to linux.conf
QMAKE_AR = $${CROSS_COMPILE}ar cqs
QMAKE_OBJCOPY = $${CROSS_COMPILE}objcopy
QMAKE_STRIP = $${CROSS_COMPILE}strip
-QMAKE_INCDIR += $${TRIDENT_SHINER_SDK_BUILDTREE}/target/output/objs/$${TRIDENT_SHINER_SDK_BUILDSPEC}/comps/generic_apps/usr/include
-QMAKE_LIBDIR += $${TRIDENT_SHINER_SDK_BUILDTREE}/target/output/objs/$${TRIDENT_SHINER_SDK_BUILDSPEC}/comps/generic_apps/usr/lib
-QMAKE_LIBDIR += $${TRIDENT_SHINER_SDK_BUILDTREE}/target/output/objs/$${TRIDENT_SHINER_SDK_BUILDSPEC}/comps/generated/lib/armgnu_linux_el_cortex-a9
+QMAKE_INCDIR += $${TRIDENT_SHINER_SDK_BUILDTREE}/target/output/objs/$${TRIDENT_SHINER_SDK_BUILDSPEC}/comps/generic_apps/usr/include
+QMAKE_LIBDIR += $${TRIDENT_SHINER_SDK_BUILDTREE}/target/output/objs/$${TRIDENT_SHINER_SDK_BUILDSPEC}/comps/generic_apps/usr/lib
+QMAKE_LIBDIR += $${TRIDENT_SHINER_SDK_BUILDTREE}/target/output/objs/$${TRIDENT_SHINER_SDK_BUILDSPEC}/comps/generated/lib/armgnu_linux_el_cortex-a9
QMAKE_INCDIR_EGL = $${TRIDENT_SHINER_SDK_INCDIR_EGL_OPENGL_ES2}
QMAKE_LIBDIR_EGL = $${TRIDENT_SHINER_SDK_LIBDIR_EGL_OPENGL_ES2}
diff --git a/mkspecs/devices/linux-beagleboard-g++/qmake.conf b/mkspecs/devices/linux-beagleboard-g++/qmake.conf
index fd5b0b3ca2..54fe994bfa 100644
--- a/mkspecs/devices/linux-beagleboard-g++/qmake.conf
+++ b/mkspecs/devices/linux-beagleboard-g++/qmake.conf
@@ -3,7 +3,7 @@
# http://beagleboard.org/
MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../../common/linux.conf)
diff --git a/mkspecs/devices/linux-imx53qsb-g++/qmake.conf b/mkspecs/devices/linux-imx53qsb-g++/qmake.conf
new file mode 100644
index 0000000000..0a5ed89feb
--- /dev/null
+++ b/mkspecs/devices/linux-imx53qsb-g++/qmake.conf
@@ -0,0 +1,37 @@
+#
+# qmake configuration for the Freescale iMX53 board
+#
+# This mkspec is based and tested on the Yocto Project's Poky Distribution
+# with libEGL.so from Freescale without the X11 dependency.
+#
+# This mkspec is tested with a framebuffer (eglfs) configuration
+#
+# A typical configure line looks like:
+#
+# export PATH=/opt/imx53qsb/x86_64-linux/usr/bin/armv7a-vfp-neon-poky-linux-gnueabi:$PATH
+#
+# ./configure -prefix /usr/local/qt5-imx53 -hostprefix /opt/imx53qsb/x86_64-linux/usr/local/qt5-imx53 -release -device linux-imx53qsb-g++
+# -opensource -confirm-license -no-gtkstyle -device-option CROSS_COMPILE=arm-poky-linux-gnueabi- -sysroot /opt/imx53qsb/sysroot
+# -eglfs -no-pch -opengl es2 -no-xcb -silent
+
+include(../common/linux_device_pre.conf)
+
+QMAKE_INCDIR += $$[QT_SYSROOT]/usr/include
+QMAKE_LIBDIR += $$[QT_SYSROOT]/usr/lib
+
+QMAKE_LIBS_EGL += -lEGL
+QMAKE_LIBS_OPENGL_ES2 += -lGLESv2 -lEGL
+QMAKE_LIBS_OPENVG += -lOpenVG -lEGL
+
+QMAKE_LFLAGS += -Wl,-rpath-link,$$[QT_SYSROOT]/usr/lib
+
+IMX5_CFLAGS = -march=armv7-a -mfpu=neon -DLINUX=1 -DEGL_API_FB=1 -Wno-psabi
+IMX5_CFLAGS_RELEASE = -O2 $$IMX5_CFLAGS
+QMAKE_CFLAGS_RELEASE += $$IMX5_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_RELEASE += $$IMX5_CFLAGS_RELEASE
+QMAKE_CFLAGS_DEBUG += $$IMX5_CFLAGS
+QMAKE_CXXFLAGS_DEBUG += $$IMX5_CFLAGS
+
+include(../common/linux_device_post.conf)
+
+load(qt_config)
diff --git a/mkspecs/unsupported/macx-iosdevice-clang-legacy/qplatformdefs.h b/mkspecs/devices/linux-imx53qsb-g++/qplatformdefs.h
index 5f80a17860..461f3d5589 100644
--- a/mkspecs/unsupported/macx-iosdevice-clang-legacy/qplatformdefs.h
+++ b/mkspecs/devices/linux-imx53qsb-g++/qplatformdefs.h
@@ -39,4 +39,4 @@
**
****************************************************************************/
-#include "../../common/ios/qplatformdefs.h"
+#include "../../linux-g++/qplatformdefs.h"
diff --git a/mkspecs/devices/linux-maemo-n9-g++/qmake.conf b/mkspecs/devices/linux-maemo-n9-g++/qmake.conf
index 804de84dc7..fadeb85e8c 100644
--- a/mkspecs/devices/linux-maemo-n9-g++/qmake.conf
+++ b/mkspecs/devices/linux-maemo-n9-g++/qmake.conf
@@ -3,10 +3,10 @@
# http://wiki.qt-project.org/Devices/N9
MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
-QMAKE_PLATFORM = maemo
+QMAKE_PLATFORM = maemo
include(../../common/linux.conf)
include(../../common/gcc-base-unix.conf)
diff --git a/mkspecs/devices/linux-mipsel-broadcom-97425-g++/qmake.conf b/mkspecs/devices/linux-mipsel-broadcom-97425-g++/qmake.conf
index b23419f64b..bca69c3969 100644
--- a/mkspecs/devices/linux-mipsel-broadcom-97425-g++/qmake.conf
+++ b/mkspecs/devices/linux-mipsel-broadcom-97425-g++/qmake.conf
@@ -3,7 +3,7 @@
#
MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../../common/linux.conf)
@@ -47,13 +47,13 @@ QMAKE_LIBDIR_OPENGL_ES2 = $${BRCM_ROCKFORD_PATH}/middleware/v3d/lib_$${BRCM_PLAT
QMAKE_LIBS_OPENGL_ES2 = -lv3ddriver -lrt
QMAKE_LIBS_EGL =
-INCLUDEPATH += $${BRCM_APPLIBS_PATH}/opensource/zlib/zlib-1.2.3
-QMAKE_LIBDIR += $${BRCM_APPLIBS_PATH}/opensource/zlib/zlib-1.2.3
+INCLUDEPATH += $${BRCM_APPLIBS_PATH}/opensource/zlib/zlib-1.2.3
+QMAKE_LIBDIR += $${BRCM_APPLIBS_PATH}/opensource/zlib/zlib-1.2.3
-QMAKE_LFLAGS += -Wl,-rpath-link,$$QMAKE_LIBDIR_OPENGL_ES2 -Wl,-rpath-link,$${BRCM_APPLIBS_PATH}/opensource/zlib/zlib-1.2.3
+QMAKE_LFLAGS += -Wl,-rpath-link,$$QMAKE_LIBDIR_OPENGL_ES2 -Wl,-rpath-link,$${BRCM_APPLIBS_PATH}/opensource/zlib/zlib-1.2.3
# DirectFB platform hooks for this hardware
-QT_CONFIG += directfb_egl egl
+QT_CONFIG += directfb_egl egl
DIRECTFB_PLATFORM_HOOKS_SOURCES = $$PWD/qdirectfbeglhooks_bcm97425.cpp
DIRECTFB_PLATFORM_HOOKS_INCLUDEPATH = $${BRCM_ROCKFORD_PATH}/middleware/platform/directfb
DIRECTFB_PLATFORM_HOOKS_LIBS = -ldbpl
diff --git a/mkspecs/devices/linux-rasp-pi-g++/qmake.conf b/mkspecs/devices/linux-rasp-pi-g++/qmake.conf
index a6365d87ef..d6fea474a6 100644
--- a/mkspecs/devices/linux-rasp-pi-g++/qmake.conf
+++ b/mkspecs/devices/linux-rasp-pi-g++/qmake.conf
@@ -6,12 +6,14 @@ include(../common/linux_device_pre.conf)
QT_QPA_DEFAULT_PLATFORM = wayland
-QMAKE_LFLAGS += -Wl,-rpath-link,$$[QT_SYSROOT]/opt/vc/lib
+QMAKE_LFLAGS += -Wl,-rpath-link,$$[QT_SYSROOT]/opt/vc/lib
QMAKE_LIBDIR_OPENGL_ES2 = $$[QT_SYSROOT]/opt/vc/lib
QMAKE_LIBDIR_EGL = $$QMAKE_LIBDIR_OPENGL_ES2
-QMAKE_INCDIR_EGL = $$[QT_SYSROOT]/opt/vc/include $$[QT_SYSROOT]/opt/vc/include/interface/vcos/pthreads
+QMAKE_INCDIR_EGL = $$[QT_SYSROOT]/opt/vc/include \
+ $$[QT_SYSROOT]/opt/vc/include/interface/vcos/pthreads \
+ $$[QT_SYSROOT]/opt/vc/include/interface/vmcs_host/linux
QMAKE_INCDIR_OPENGL_ES2 = $${QMAKE_INCDIR_EGL}
QMAKE_LIBS_EGL = -lEGL -lGLESv2
@@ -28,7 +30,7 @@ contains(DISTRO, squeeze) {
DISTRO_OPTS += hard-float
}
-QMAKE_CFLAGS += \
+QMAKE_CFLAGS += \
-marm \
-mfpu=vfp \
-mtune=arm1176jzf-s \
diff --git a/mkspecs/devices/linux-sh4-stmicro-ST7108-g++/qmake.conf b/mkspecs/devices/linux-sh4-stmicro-ST7108-g++/qmake.conf
index d0cf2b8655..526716e991 100644
--- a/mkspecs/devices/linux-sh4-stmicro-ST7108-g++/qmake.conf
+++ b/mkspecs/devices/linux-sh4-stmicro-ST7108-g++/qmake.conf
@@ -5,7 +5,7 @@
#
MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../../common/linux.conf)
@@ -25,7 +25,7 @@ QMAKE_STRIP = $${CROSS_COMPILE}strip
deviceSanityCheckCompiler()
-QMAKE_LIBS_EGL += -lMali
+QMAKE_LIBS_EGL += -lMali
QT_QPA_DEFAULT_PLATFORM = eglfs
diff --git a/mkspecs/devices/linux-sh4-stmicro-ST7540-g++/qmake.conf b/mkspecs/devices/linux-sh4-stmicro-ST7540-g++/qmake.conf
index 83f54c38b6..caf9537f39 100644
--- a/mkspecs/devices/linux-sh4-stmicro-ST7540-g++/qmake.conf
+++ b/mkspecs/devices/linux-sh4-stmicro-ST7540-g++/qmake.conf
@@ -5,7 +5,7 @@
#
MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../../common/linux.conf)
@@ -25,18 +25,18 @@ QMAKE_STRIP = $${CROSS_COMPILE}strip
deviceSanityCheckCompiler()
-QMAKE_INCDIR_EGL += $$[QT_SYSROOT]/root/modules/include/
-QMAKE_LIBDIR_EGL += $$[QT_SYSROOT]/root/modules/
+QMAKE_INCDIR_EGL += $$[QT_SYSROOT]/root/modules/include/
+QMAKE_LIBDIR_EGL += $$[QT_SYSROOT]/root/modules/
#
# The EGL library used for ST7540 is based on DirectFB so it has to be linked with
# 1. libdirectfb.so 2. libfusion.so 3. libdirect.so
#
-QMAKE_LIBS_EGL += -lMali -ldirectfb -lfusion -ldirect
+QMAKE_LIBS_EGL += -lMali -ldirectfb -lfusion -ldirect
QMAKE_INCDIR_OPENGL_ES2 += $$QMAKE_INCDIR_EGL
QMAKE_LIBDIR_OPENGL_ES2 += $$QMAKE_LIBDIR_EGL
-QMAKE_LIBS_OPENGL_ES2 += $$QMAKE_LIBS_EGL
+QMAKE_LIBS_OPENGL_ES2 += $$QMAKE_LIBS_EGL
QT_QPA_DEFAULT_PLATFORM = eglfs
diff --git a/mkspecs/devices/linux-snowball-g++/qmake.conf b/mkspecs/devices/linux-snowball-g++/qmake.conf
index b0f6129aa7..f0d77fbb4a 100644
--- a/mkspecs/devices/linux-snowball-g++/qmake.conf
+++ b/mkspecs/devices/linux-snowball-g++/qmake.conf
@@ -2,8 +2,8 @@
# qmake configuration for ST Ericsson's Snowball
# http://qt-project.org/wiki/Snowball
-MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../../common/linux.conf)
@@ -22,8 +22,8 @@ QMAKE_AR = $${CROSS_COMPILE}ar cqs
QMAKE_OBJCOPY = $${CROSS_COMPILE}objcopy
QMAKE_STRIP = $${CROSS_COMPILE}strip
-QMAKE_LFLAGS += -Wl,-rpath-link,$$[QT_SYSROOT]/usr/lib/arm-linux-gnueabihf \
- -Wl,-rpath-link,$$[QT_SYSROOT]/lib/arm-linux-gnueabihf
+QMAKE_LFLAGS += -Wl,-rpath-link,$$[QT_SYSROOT]/usr/lib/arm-linux-gnueabihf \
+ -Wl,-rpath-link,$$[QT_SYSROOT]/lib/arm-linux-gnueabihf
deviceSanityCheckCompiler()
diff --git a/mkspecs/devices/linux-tegra2-g++/qmake.conf b/mkspecs/devices/linux-tegra2-g++/qmake.conf
index c846801a10..1c7a8cc52a 100644
--- a/mkspecs/devices/linux-tegra2-g++/qmake.conf
+++ b/mkspecs/devices/linux-tegra2-g++/qmake.conf
@@ -12,19 +12,19 @@
include(../common/linux_device_pre.conf)
-QMAKE_INCDIR += $$[QT_SYSROOT]/usr/include
+QMAKE_INCDIR += $$[QT_SYSROOT]/usr/include
-QMAKE_LIBDIR += $$[QT_SYSROOT]/usr/lib \
- $$[QT_SYSROOT]/lib/arm-linux-gnueabi \
- $$[QT_SYSROOT]/usr/lib/arm-linux-gnueabi
+QMAKE_LIBDIR += $$[QT_SYSROOT]/usr/lib \
+ $$[QT_SYSROOT]/lib/arm-linux-gnueabi \
+ $$[QT_SYSROOT]/usr/lib/arm-linux-gnueabi
-QMAKE_LFLAGS += -Wl,-rpath-link,$$[QT_SYSROOT]/usr/lib \
- -Wl,-rpath-link,$$[QT_SYSROOT]/usr/lib/arm-linux-gnueabi \
- -Wl,-rpath-link,$$[QT_SYSROOT]/lib/arm-linux-gnueabi
+QMAKE_LFLAGS += -Wl,-rpath-link,$$[QT_SYSROOT]/usr/lib \
+ -Wl,-rpath-link,$$[QT_SYSROOT]/usr/lib/arm-linux-gnueabi \
+ -Wl,-rpath-link,$$[QT_SYSROOT]/lib/arm-linux-gnueabi
-TEGRA2_CFLAGS = -mtune=cortex-a9 -march=armv7-a -mhard-float -mfloat-abi=softfp -mfpu=vfpv3-d16
-QMAKE_CFLAGS += $$TEGRA2_CFLAGS
-QMAKE_CXXFLAGS += $$TEGRA2_CFLAGS
+TEGRA2_CFLAGS = -mtune=cortex-a9 -march=armv7-a -mhard-float -mfloat-abi=softfp -mfpu=vfpv3-d16
+QMAKE_CFLAGS += $$TEGRA2_CFLAGS
+QMAKE_CXXFLAGS += $$TEGRA2_CFLAGS
include(../common/linux_device_post.conf)
diff --git a/mkspecs/features/android.prf b/mkspecs/features/android.prf
new file mode 100644
index 0000000000..2a3086d4ad
--- /dev/null
+++ b/mkspecs/features/android.prf
@@ -0,0 +1,14 @@
+contains(TEMPLATE, ".*app") {
+ !android_app {
+ !contains(TARGET, ".so"): TARGET = lib$${TARGET}.so
+ QMAKE_LFLAGS += -Wl,-soname,$$TARGET
+ }
+}
+!QTDIR_build:android_install {
+ isEmpty(QT_BUILD_TREE) {
+ target.path=/libs/$$ANDROID_TARGET_ARCH/
+ } else {
+ target.path = /
+ }
+ INSTALLS *= target
+}
diff --git a/mkspecs/features/c++11.prf b/mkspecs/features/c++11.prf
index 4b56fa9fd2..32eaca4a9b 100644
--- a/mkspecs/features/c++11.prf
+++ b/mkspecs/features/c++11.prf
@@ -1,3 +1,10 @@
QMAKE_CXXFLAGS += $$QMAKE_CXXFLAGS_CXX11
QMAKE_OBJECTIVE_CFLAGS += $$QMAKE_CXXFLAGS_CXX11
QMAKE_LFLAGS += $$QMAKE_LFLAGS_CXX11
+
+contains(QMAKE_LFLAGS, -stdlib=libc++) {
+ equals(QMAKE_MACOSX_DEPLOYMENT_TARGET, 10.6): \
+ QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.7
+ contains(QMAKE_IOS_DEPLOYMENT_TARGET, ^4.*): \
+ QMAKE_IOS_DEPLOYMENT_TARGET = 5.0
+}
diff --git a/mkspecs/features/cmake_functions.prf b/mkspecs/features/cmake_functions.prf
new file mode 100644
index 0000000000..62634d9b88
--- /dev/null
+++ b/mkspecs/features/cmake_functions.prf
@@ -0,0 +1,26 @@
+#
+# W A R N I N G
+# -------------
+#
+# This file is not part of the Qt API. It exists purely as an
+# implementation detail. It may change from version to version
+# without notice, or even be removed.
+#
+# We mean it.
+#
+
+defineReplace(cmakeModuleName) {
+ _module = $$1
+ _name = $$eval(QT.$${_module}.name)
+ cmake_module_name = $$replace(_name, ^Qt, )
+ return ($$cmake_module_name)
+}
+
+defineReplace(cmakeModuleList) {
+ variable = $$1
+ out =
+ for(v, variable) {
+ out += $$cmakeModuleName($$v)
+ }
+ return ($$join(out, ";"))
+}
diff --git a/mkspecs/features/configure.prf b/mkspecs/features/configure.prf
index 39144e7216..b4569df6d5 100644
--- a/mkspecs/features/configure.prf
+++ b/mkspecs/features/configure.prf
@@ -7,6 +7,9 @@ equals(MAKEFILE_GENERATOR, UNIX) {
QMAKE_MAKE = mingw32-make
} else:if(equals(MAKEFILE_GENERATOR, MSVC.NET)|equals(MAKEFILE_GENERATOR, MSBUILD)) {
QMAKE_MAKE = nmake
+} else:ios {
+ # iOS unsets MAKEFILE_GENERATOR in its default_pre.prf
+ QMAKE_MAKE = make
} else {
error("Configure tests are not supported with the $$MAKEFILE_GENERATOR Makefile generator.")
}
diff --git a/mkspecs/features/create_cmake.prf b/mkspecs/features/create_cmake.prf
index 43dca4cd70..cf0acaf4b7 100644
--- a/mkspecs/features/create_cmake.prf
+++ b/mkspecs/features/create_cmake.prf
@@ -9,21 +9,7 @@
# We mean it.
#
-defineReplace(cmakeModuleName) {
- _module = $$1
- _name = $$eval(QT.$${_module}.name)
- cmake_module_name = $$replace(_name, ^Qt, )
- return ($$cmake_module_name)
-}
-
-defineReplace(cmakeModuleList) {
- variable = $$1
- out =
- for(v, variable) {
- out += $$cmakeModuleName($$v)
- }
- return ($$join(out, ";"))
-}
+load(cmake_functions)
defineReplace(cmakeRelativePath) {
path = $$relative_path($$1, $$2)
@@ -69,10 +55,10 @@ CMAKE_BIN_DIR = $$cmakeRelativePath($$[QT_HOST_BINS], $$[QT_INSTALL_PREFIX])
CMAKE_BIN_DIR_IS_ABSOLUTE = True
}
-CMAKE_ARCHDATA_DIR = $$cmakeRelativePath($$[QT_INSTALL_ARCHDATA], $$[QT_INSTALL_PREFIX])
-!isEmpty(CMAKE_FORCE_ABSOLUTE_PATHS)|contains(CMAKE_ARCHDATA_DIR, "^\\.\\./.*") { # For the mkspecs
- CMAKE_ARCHDATA_DIR = $$[QT_INSTALL_ARCHDATA]/
- CMAKE_ARCHDATA_DIR_IS_ABSOLUTE = True
+CMAKE_HOST_DATA_DIR = $$cmakeRelativePath($$[QT_HOST_DATA], $$[QT_INSTALL_PREFIX])
+!isEmpty(CMAKE_FORCE_ABSOLUTE_PATHS)|contains(CMAKE_HOST_DATA_DIR, "^\\.\\./.*") {
+ CMAKE_HOST_DATA_DIR = $$[QT_HOST_DATA]/
+ CMAKE_HOST_DATA_DIR_IS_ABSOLUTE = True
}
static|staticlib:CMAKE_STATIC_TYPE = true
@@ -83,7 +69,7 @@ CMAKE_MKSPEC = $$[QMAKE_XSPEC]
CMAKE_QT_STEM = Qt$$eval(QT.$${MODULE}.MAJOR_VERSION)$${CMAKE_MODULE_NAME}$${QT_LIBINFIX}
-macx {
+mac {
!isEmpty(CMAKE_STATIC_TYPE) {
CMAKE_LIB_FILE_LOCATION_DEBUG = lib$${CMAKE_QT_STEM}_debug.a
CMAKE_LIB_FILE_LOCATION_RELEASE = lib$${CMAKE_QT_STEM}.a
diff --git a/mkspecs/features/ctest_testcase.prf b/mkspecs/features/ctest_testcase.prf
index 7f86ca0052..7faf738d6e 100644
--- a/mkspecs/features/ctest_testcase.prf
+++ b/mkspecs/features/ctest_testcase.prf
@@ -18,6 +18,8 @@ isEmpty(CMAKE_VERSION) {
CMAKE_VERSION_MAJOR = $$section(CMAKE_VERSION, ., 0, 0)
CMAKE_VERSION_MINOR = $$section(CMAKE_VERSION, ., 1, 1)
CMAKE_VERSION_PATCH = $$section(CMAKE_VERSION, ., 2, 2)
+ # CMake can report versions like 2.8.11-rc1, so strip off the rc part.
+ CMAKE_VERSION_PATCH ~= s,-.*,,
VERSION_OK =
greaterThan(CMAKE_VERSION_MAJOR, 2) {
@@ -31,6 +33,8 @@ isEmpty(CMAKE_VERSION) {
isEmpty(VERSION_OK) {
message("cmake $$CMAKE_VERSION is too old for this test.")
} else {
+ load(cmake_functions)
+
CMAKE_BUILD_TYPE = Debug
CONFIG(release, debug|release):CMAKE_BUILD_TYPE = Release
win32-g++*:CMAKE_GENERATOR = -G \"MinGW Makefiles\"
@@ -40,10 +44,39 @@ isEmpty(CMAKE_VERSION) {
for(d, $$list($$split($$list($$[QMAKE_MKSPECS]), $$DIRLIST_SEPARATOR))) {
CMAKE_PREFIX_PATH *= $$dirname(d)
}
+ CMAKE_PREFIX_PATH=\"$$join(CMAKE_PREFIX_PATH, ;)\"
+
+ !qtHaveModule(widgets): CMAKE_MODULE_DEFINES += -DNO_WIDGETS=True
+ !qtHaveModule(dbus): CMAKE_MODULE_DEFINES += -DNO_DBUS=True
+
+ dependentmodules = $$resolve_depends(CMAKE_QT_MODULES_UNDER_TEST, "QT.")
+ dependentmodules -= $$CMAKE_QT_MODULES_UNDER_TEST
+ dependentmodules = $$cmakeModuleList($$dependentmodules)
+
+ SET = set
+ equals(QMAKE_DIR_SEP, "/"):SET = export
+
+ CMAKE_MODULE_VERSIONS =
+ CMAKE_MODULES_UNDER_TEST =
+ for (MODULE_UNDER_TEST, CMAKE_QT_MODULES_UNDER_TEST) {
+ CMAKE_NAME = $$cmakeModuleName($$MODULE_UNDER_TEST)
+ CMAKE_MODULE_VERSIONS += \
+ -DCMAKE_$${CMAKE_NAME}_MODULE_MAJOR_VERSION=$$eval(QT.$${MODULE_UNDER_TEST}.MAJOR_VERSION) \
+ -DCMAKE_$${CMAKE_NAME}_MODULE_MINOR_VERSION=$$eval(QT.$${MODULE_UNDER_TEST}.MINOR_VERSION) \
+ -DCMAKE_$${CMAKE_NAME}_MODULE_PATCH_VERSION=$$eval(QT.$${MODULE_UNDER_TEST}.PATCH_VERSION)
+ CMAKE_MODULES_UNDER_TEST += $$CMAKE_NAME
+ }
+ CMAKE_MODULES_UNDER_TEST = $$join(CMAKE_MODULES_UNDER_TEST, ;)
check.commands = \
- $(MKDIR) $$BUILD_DIR && cd $$BUILD_DIR && \
- cmake $$_PRO_FILE_PWD_ $$CMAKE_GENERATOR -DCMAKE_BUILD_TYPE=$${CMAKE_BUILD_TYPE} -DCMAKE_PREFIX_PATH=\"$$join(CMAKE_PREFIX_PATH, ;)\" && \
+ $(MKDIR) $$BUILD_DIR && cd $$BUILD_DIR && $$SET VERBOSE=1 && \
+ cmake $$_PRO_FILE_PWD_ $$CMAKE_GENERATOR \
+ $$CMAKE_MODULE_DEFINES \
+ -DCMAKE_BUILD_TYPE=$${CMAKE_BUILD_TYPE} \
+ -DCMAKE_PREFIX_PATH=$$CMAKE_PREFIX_PATH \
+ -DQt5_MODULE_TEST_DEPENDS=\"$${dependentmodules}\" \
+ $${CMAKE_MODULE_VERSIONS} \
+ -DCMAKE_MODULES_UNDER_TEST=\"$$CMAKE_MODULES_UNDER_TEST\" && \
$(TESTRUNNER) ctest --output-on-failure
}
@@ -54,6 +87,4 @@ insignificant_test:!isEmpty(check.commands) {
check.commands = -$${check.commands}
}
-!qtHaveModule(widgets): CONFIG += insignificant_test # QTBUG-28540
-
QMAKE_EXTRA_TARGETS *= check
diff --git a/mkspecs/features/data/android/dx.bat b/mkspecs/features/data/android/dx.bat
new file mode 100644
index 0000000000..af143c52b5
--- /dev/null
+++ b/mkspecs/features/data/android/dx.bat
@@ -0,0 +1,102 @@
+@echo off
+REM Copyright (C) 2007 The Android Open Source Project
+REM
+REM Licensed under the Apache License, Version 2.0 (the "License");
+REM you may not use this file except in compliance with the License.
+REM You may obtain a copy of the License at
+REM
+REM http://www.apache.org/licenses/LICENSE-2.0
+REM
+REM Unless required by applicable law or agreed to in writing, software
+REM distributed under the License is distributed on an "AS IS" BASIS,
+REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+REM See the License for the specific language governing permissions and
+REM limitations under the License.
+
+REM If/when Google merge:
+REM https://android-review.googlesource.com/#/c/52680/
+REM this file will become redundant.
+
+REM don't modify the caller's environment
+setlocal
+
+REM Locate dx.jar in the directory where dx.bat was found and start it.
+
+REM Set up prog to be the path of this script, including following symlinks,
+REM and set up progdir to be the fully-qualified pathname of its directory.
+set prog=%~f0
+
+if [%1]==[] goto badArgs
+set "androidsdk=%1"
+shift /1
+
+if [%1]==[] goto badArgs
+
+rem Check we have a valid Java.exe in the path.
+set java_exe=
+call "%androidsdk%\tools\lib\find_java.bat"
+if not defined java_exe goto :EOF
+
+set jarfile=dx.jar
+set "frameworkdir=%androidsdk%\platform-tools"
+
+if exist "%frameworkdir%\%jarfile%" goto JarFileOk
+ set "frameworkdir=%frameworkdir%\lib"
+
+if exist "%frameworkdir%\%jarfile%" goto JarFileOk
+ set "frameworkdir=%androidsdk%\framework"
+
+:JarFileOk
+
+set jarpath=%frameworkdir%\%jarfile%
+
+set javaOpts=
+set args=
+
+REM By default, give dx a max heap size of 1 gig and a stack size of 1meg.
+rem This can be overridden by using "-JXmx..." and "-JXss..." options below.
+set defaultXmx=-Xmx1024M
+set defaultXss=-Xss1m
+
+REM Capture all arguments that are not -J options.
+REM Note that when reading the input arguments with %1, the cmd.exe
+REM automagically converts --name=value arguments into 2 arguments "--name"
+REM followed by "value". Dx has been changed to know how to deal with that.
+set params=
+
+:firstArg
+if [%1]==[] goto endArgs
+set a=%~1
+
+ if [%defaultXmx%]==[] goto notXmx
+ if %a:~0,5% NEQ -JXmx goto notXmx
+ set defaultXmx=
+ :notXmx
+
+ if [%defaultXss%]==[] goto notXss
+ if %a:~0,5% NEQ -JXss goto notXss
+ set defaultXss=
+ :notXss
+
+ if %a:~0,2% NEQ -J goto notJ
+ set javaOpts=%javaOpts% -%a:~2%
+ shift /1
+ goto firstArg
+
+ :notJ
+ set params=%params% %1
+ shift /1
+ goto firstArg
+
+:endArgs
+
+set javaOpts=%javaOpts% %defaultXmx% %defaultXss%
+
+call "%java_exe%" %javaOpts% -Djava.ext.dirs="%frameworkdir%" -jar "%jarpath%" %params%
+
+goto :EOF
+
+:badArgs
+echo Usage: dx (for Qt) <android_sdk_path> <dx_arguments>
+echo Example: dx (for Qt) C:\android-sdk --dex --output=target.jar .classes
+
diff --git a/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in b/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
index d70dbedbf4..65ba03d44c 100644
--- a/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
+++ b/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in
@@ -9,9 +9,7 @@ get_filename_component(_qt5$${CMAKE_MODULE_NAME}_install_prefix \"${CMAKE_CURREN
set(_qt5$${CMAKE_MODULE_NAME}_install_prefix \"$$[QT_INSTALL_PREFIX]\")
!!ENDIF
-set(Qt5$${CMAKE_MODULE_NAME}_VERSION_MAJOR "$$eval(QT.$${MODULE}.MAJOR_VERSION)")
-set(Qt5$${CMAKE_MODULE_NAME}_VERSION_MINOR "$$eval(QT.$${MODULE}.MINOR_VERSION)")
-set(Qt5$${CMAKE_MODULE_NAME}_VERSION_PATCH "$$eval(QT.$${MODULE}.PATCH_VERSION)")
+# For backwards compatibility only. Use Qt5$${CMAKE_MODULE_NAME}_VERSION instead.
set(Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING "$$eval(QT.$${MODULE}.MAJOR_VERSION).$$eval(QT.$${MODULE}.MINOR_VERSION).$$eval(QT.$${MODULE}.PATCH_VERSION)")
set(Qt5$${CMAKE_MODULE_NAME}_LIBRARIES Qt5::$${CMAKE_MODULE_NAME})
@@ -47,13 +45,13 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME})
!!IF !no_module_headers
!!IF isEmpty(CMAKE_INCLUDE_DIR_IS_ABSOLUTE)
- set(Qt5$${CMAKE_MODULE_NAME}_INCLUDE_DIRS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}$${MODULE_INCNAME}\")
+ set(Qt5$${CMAKE_MODULE_NAME}_INCLUDE_DIRS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$$CMAKE_INCLUDE_DIR\" \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}$${MODULE_INCNAME}\")
set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS
\"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}$${MODULE_INCNAME}/${Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING}\"
\"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}$${MODULE_INCNAME}/${Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING}/$${MODULE_INCNAME}\"
)
!!ELSE
- set(Qt5$${CMAKE_MODULE_NAME}_INCLUDE_DIRS \"$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}\")
+ set(Qt5$${CMAKE_MODULE_NAME}_INCLUDE_DIRS \"$$CMAKE_INCLUDE_DIR\" \"$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}\")
set(Qt5$${CMAKE_MODULE_NAME}_PRIVATE_INCLUDE_DIRS
\"$${CMAKE_INCLUDE_DIR}$${MODULE_INCNAME}/${Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING}\"
\"$${CMAKE_INCLUDE_DIR}$${MODULE_INCNAME}/${Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING}/$${MODULE_INCNAME}\"
@@ -77,13 +75,18 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME})
if (Qt5$${CMAKE_MODULE_NAME}_FIND_QUIETLY)
set(_Qt5$${CMAKE_MODULE_NAME}_DEPENDENCIES_FIND_QUIET QUIET)
endif()
+ set(_Qt5$${CMAKE_MODULE_NAME}_FIND_VERSION_EXACT)
+ if (Qt5$${CMAKE_MODULE_NAME}_FIND_VERSION_EXACT)
+ set(_Qt5$${CMAKE_MODULE_NAME}_FIND_VERSION_EXACT EXACT)
+ endif()
foreach(_module_dep ${_Qt5$${CMAKE_MODULE_NAME}_MODULE_DEPENDENCIES})
if (NOT Qt5${_module_dep}_FOUND)
find_package(Qt5${_module_dep}
+ ${Qt5$${CMAKE_MODULE_NAME}_VERSION_STRING} ${_Qt5$${CMAKE_MODULE_NAME}_FIND_VERSION_EXACT}
${_Qt5$${CMAKE_MODULE_NAME}_DEPENDENCIES_FIND_QUIET}
${_Qt5$${CMAKE_MODULE_NAME}_FIND_DEPENDENCIES_REQUIRED}
- PATHS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}\" NO_DEFAULT_PATH
+ PATHS \"${CMAKE_CURRENT_LIST_DIR}/..\" NO_DEFAULT_PATH
)
endif()
@@ -103,7 +106,7 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME})
list(REMOVE_DUPLICATES Qt5$${CMAKE_MODULE_NAME}_DEFINITIONS)
list(REMOVE_DUPLICATES Qt5$${CMAKE_MODULE_NAME}_COMPILE_DEFINITIONS)
if (Qt5$${CMAKE_MODULE_NAME}_EXECUTABLE_COMPILE_FLAGS)
- list(REMOVE_DUPLICATES Qt5$${CMAKE_MODULE_NAME}_EXECUTABLE_COMPILE_FLAGS)
+ list(REMOVE_DUPLICATES Qt5$${CMAKE_MODULE_NAME}_EXECUTABLE_COMPILE_FLAGS)
endif()
set(_Qt5$${CMAKE_MODULE_NAME}_LIB_DEPENDENCIES \"$${CMAKE_QT5_MODULE_DEPS}\")
@@ -118,6 +121,11 @@ if (NOT TARGET Qt5::$${CMAKE_MODULE_NAME})
set_property(TARGET Qt5::$${CMAKE_MODULE_NAME} PROPERTY FRAMEWORK 1)
!!ENDIF
+ set_property(TARGET Qt5::$${CMAKE_MODULE_NAME} PROPERTY
+ INTERFACE_INCLUDE_DIRECTORIES ${Qt5$${CMAKE_MODULE_NAME}_INCLUDE_DIRS})
+ set_property(TARGET Qt5::$${CMAKE_MODULE_NAME} PROPERTY
+ INTERFACE_COMPILE_DEFINITIONS $${MODULE_DEFINE})
+
!!IF !isEmpty(CMAKE_RELEASE_TYPE)
!!IF !isEmpty(CMAKE_STATIC_WINDOWS_BUILD)
_populate_$${CMAKE_MODULE_NAME}_target_properties(RELEASE \"$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\" \"\" )
diff --git a/mkspecs/features/default_post.prf b/mkspecs/features/default_post.prf
index cdd200e80b..c756455dd2 100644
--- a/mkspecs/features/default_post.prf
+++ b/mkspecs/features/default_post.prf
@@ -47,6 +47,14 @@ incredibuild_xge {
CONFIG = incredibuild_xge $$CONFIG
}
+silent {
+ # Ensure that we process silent.prf last, as it will mangle QMAKE_CXX
+ # and friends in a way that some of the other features (sdk.prf and
+ # simd.prf eg) do not handle.
+ CONFIG -= silent
+ CONFIG = silent $$CONFIG
+}
+
force_debug_info:win32 {
load(resolve_target)
QMAKE_CLEAN += $$replace(QMAKE_RESOLVED_TARGET, ...$, pdb) # for the debug case it is hardcoded in qmake
diff --git a/mkspecs/features/exclusive_builds.prf b/mkspecs/features/exclusive_builds.prf
index 0e0da05c70..c45ff22c06 100644
--- a/mkspecs/features/exclusive_builds.prf
+++ b/mkspecs/features/exclusive_builds.prf
@@ -6,7 +6,7 @@ defineTest(fixExclusiveOutputDirs) {
count(ARGS, 2, greaterThan):isEqual($$list($$lower($$3)), false):appendFirstBuild = false
else:appendFirstBuild = true
- isEmpty(QMAKE_DIR_REPLACE):QMAKE_DIR_REPLACE += OBJECTS_DIR MOC_DIR RCC_DIR
+ isEmpty(QMAKE_DIR_REPLACE):QMAKE_DIR_REPLACE += OBJECTS_DIR MOC_DIR RCC_DIR PRECOMPILED_DIR
lessThan(firstBuild, $$secondBuild):eval($${firstBuild}_and_$${secondBuild}_target:QMAKE_DIR_REPLACE += DESTDIR)
else:eval($${secondBuild}_and_$${firstBuild}_target:QMAKE_DIR_REPLACE += DESTDIR)
for(fix, QMAKE_DIR_REPLACE) {
@@ -33,15 +33,15 @@ defineTest(addExclusiveBuilds) {
contains(TEMPLATE, subdirs) {
eval(sub_$${firstBuildName}.target = $$firstBuild)
- export(sub_$${firstBuildName}.target)
+ export(sub_$${firstBuildName}.target)
eval(sub_$${firstBuildName}.CONFIG = recursive)
- export(sub_$${firstBuildName}.CONFIG)
+ export(sub_$${firstBuildName}.CONFIG)
eval(sub_$${secondBuildName}.target = $$secondBuild)
- export(sub_$${secondBuildName}.target)
+ export(sub_$${secondBuildName}.target)
eval(sub_$${secondBuildName}.CONFIG = recursive)
- export(sub_$${secondBuildName}.CONFIG)
- QMAKE_EXTRA_TARGETS += sub_$${firstBuildName} sub_$${secondBuildName}
- export(QMAKE_EXTRA_TARGETS)
+ export(sub_$${secondBuildName}.CONFIG)
+ QMAKE_EXTRA_TARGETS += sub_$${firstBuildName} sub_$${secondBuildName}
+ export(QMAKE_EXTRA_TARGETS)
} else:!build_pass {
first_BUILDS =
second_BUILDS =
@@ -56,32 +56,32 @@ defineTest(addExclusiveBuilds) {
else: permutationName = -$$permutation
# Makefile target rule
eval($${firstBuildName}$${permutation}.target = $${firstBuild}$$lower($${permutationName}))
- export($${firstBuildName}$${permutation}.target)
+ export($${firstBuildName}$${permutation}.target)
# IDE name
eval($${firstBuildName}$${permutation}.name = $${firstBuildName}$${permutationName})
- export($${firstBuildName}$${permutation}.name)
- # prl import CONFIG option
+ export($${firstBuildName}$${permutation}.name)
+ # prl import CONFIG option
eval($${firstBuildName}$${permutation}.PRL_CONFIG = $${firstBuild}$${permutation})
export($${firstBuildName}$${permutation}.PRL_CONFIG)
# Individual CONFIG option
eval($${firstBuildName}$${permutation}.CONFIG = $${firstBuild} $${firstBuildName}Build $$eval($${permutation}.CONFIG))
- export($${firstBuildName}$${permutation}.CONFIG)
+ export($${firstBuildName}$${permutation}.CONFIG)
eval($${secondBuildName}$${permutation}.target = $${secondBuild}$$lower($${permutationName}))
- export($${secondBuildName}$${permutation}.target)
+ export($${secondBuildName}$${permutation}.target)
eval($${secondBuildName}$${permutation}.name = $${secondBuildName}$${permutationName})
- export($${secondBuildName}$${permutation}.name)
- eval($${secondBuildName}$${permutation}.PRL_CONFIG = $${secondBuild}$${permutation})
- export($${secondBuildName}$${permutation}.PRL_CONFIG)
+ export($${secondBuildName}$${permutation}.name)
+ eval($${secondBuildName}$${permutation}.PRL_CONFIG = $${secondBuild}$${permutation})
+ export($${secondBuildName}$${permutation}.PRL_CONFIG)
eval($${secondBuildName}$${permutation}.CONFIG = $${secondBuild} $${secondBuildName}Build $$eval($${permutation}.CONFIG))
- export($${secondBuildName}$${permutation}.CONFIG)
-
+ export($${secondBuildName}$${permutation}.CONFIG)
+
first_BUILDS += $${firstBuildName}$${permutation}
second_BUILDS += $${secondBuildName}$${permutation}
}
-
+
# A mutual exclusive block.
- CONFIG($${firstBuild}, $${firstBuild}|$${secondBuild}): BUILDS = $$first_BUILDS $$second_BUILDS
+ CONFIG($${firstBuild}, $${firstBuild}|$${secondBuild}): BUILDS = $$first_BUILDS $$second_BUILDS
else: BUILDS = $$second_BUILDS $$first_BUILDS
export(BUILDS)
} else {
diff --git a/mkspecs/features/ios/default_post.prf b/mkspecs/features/ios/default_post.prf
new file mode 100644
index 0000000000..e9d2149351
--- /dev/null
+++ b/mkspecs/features/ios/default_post.prf
@@ -0,0 +1,69 @@
+
+CONFIG(qt):contains(QT, gui):equals(TEMPLATE, app): CONFIG += gui_app
+
+isEmpty(MAKEFILE_GENERATOR) {
+ gui_app:app_bundle: \
+ # For applications we want Xcode project files
+ MAKEFILE_GENERATOR = XCODE
+ else: \
+ # For libs, etc we still want regular Makefiles
+ MAKEFILE_GENERATOR = UNIX
+}
+
+gui_app {
+ # We have to do the link and dependency resolution for the platform plugin
+ # manually, since QTPLUGIN and the prl lookup logic does not support
+ # the -force_load link style. The -force_load option ensures that all
+ # symbols from the static library are included, not just the ones the
+ # linker have seen a use for so far. We need this because we load the platform
+ # plugin from the platform plugin itself, using Q_IMPORT_PLUGIN.
+ lib_path_and_base = $$[QT_INSTALL_PLUGINS/get]/platforms/libqios$$qtPlatformTargetSuffix()
+ LIBS += "-force_load $${lib_path_and_base}.$${QMAKE_EXTENSION_STATICLIB}"
+ LIBS += $$fromfile($${lib_path_and_base}.prl, QMAKE_PRL_LIBS)
+
+ # Which means we don't want the auto-generated import for the platform plugin
+ CONFIG -= import_qpa_plugin
+
+ !no_main_wrapper {
+ # We link the iosmain library manually as well, since it's not really a plugin
+ lib_name = qiosmain
+ lib_path_and_base = $$[QT_INSTALL_PLUGINS/get]/platforms/lib$${lib_name}$$qtPlatformTargetSuffix()
+ LIBS += -L$$[QT_INSTALL_PLUGINS/get]/platforms -l$${lib_name}$$qtPlatformTargetSuffix()
+ LIBS += $$fromfile($${lib_path_and_base}.prl, QMAKE_PRL_LIBS)
+ DEFINES += main=qt_main
+ }
+}
+
+contains(MAKEFILE_GENERATOR, XCODE) {
+ ios_device_family.name = TARGETED_DEVICE_FAMILY
+ ios_device_family.value = $$QMAKE_IOS_TARGETED_DEVICE_FAMILY
+ QMAKE_MAC_XCODE_SETTINGS += ios_device_family
+}
+
+isEmpty(QT_ARCH) {
+ # The iPhoneOS and iPhoneSimulator targets share the same toolchain,
+ # so when configure runs the arch tests it passes the correct sysroot,
+ # but we fail to pick up the architecture since we're not passing -arch
+ # yet. Xcode does not seem to have a way to run the shared toolchain
+ # in a way that will automatically do this (for example xcrun -sdk).
+ contains(QMAKE_MAC_SDK, iphoneos.*): QT_ARCH = armv7
+ else: QT_ARCH = i386 # Simulator
+} else {
+ # Fix up the QT_ARCH to be more specific
+ equals(QT_ARCH, arm) {
+ # Samsung S5PC100, Apple A4, A5, A5X
+ QT_ARCH = armv7
+
+ # FIXME: How do we support armv7s when Qt can't do universal builds?
+ }
+}
+
+!equals(MAKEFILE_GENERATOR, XCODE) {
+ arch_flag = -arch $$QT_ARCH
+ QMAKE_CFLAGS += $$arch_flag
+ QMAKE_CXXFLAGS += $$arch_flag
+ QMAKE_OBJECTIVE_CFLAGS += $$arch_flag
+ QMAKE_LFLAGS += $$arch_flag
+}
+
+load(default_post)
diff --git a/mkspecs/features/ios/default_pre.prf b/mkspecs/features/ios/default_pre.prf
new file mode 100644
index 0000000000..e2956bd77d
--- /dev/null
+++ b/mkspecs/features/ios/default_pre.prf
@@ -0,0 +1,4 @@
+# Unset makefile generator, so we can auto-detect value in default_post
+unset(MAKEFILE_GENERATOR)
+
+load(default_pre)
diff --git a/mkspecs/features/java.prf b/mkspecs/features/java.prf
new file mode 100644
index 0000000000..6cbd690c37
--- /dev/null
+++ b/mkspecs/features/java.prf
@@ -0,0 +1,65 @@
+TEMPLATE = lib
+android {
+ isEmpty(SDK_ROOT): SDK_ROOT = $$(ANDROID_SDK_ROOT)
+ isEmpty(SDK_ROOT): SDK_ROOT = $$DEFAULT_ANDROID_SDK_ROOT
+ isEmpty(API_VERSION) {
+ API_VERSION = $$(ANDROID_API_VERSION)
+ isEmpty(API_VERSION): API_VERSION = android-10
+ }
+
+ !exists($$SDK_ROOT/platforms/$$API_VERSION/android.jar) {
+ error("The Path $$SDK_ROOT/platforms/$$API_VERSION/android.jar does not exist. Make sure the ANDROID_SDK_ROOT and ANDROID_API_VERSION environment variables are correctly set.")
+ }
+ JAVACLASSPATH += $$SDK_ROOT/platforms/$$API_VERSION/android.jar
+
+ # FIXME: This is a hack to work around some hardcoded values in the android.prf. The
+ # android.prf should be fixed and this should be removed.
+ CONFIG += android_app
+}
+
+isEmpty(CLASS_DIR): CLASS_DIR = .classes
+
+CONFIG -= qt
+
+# Without these, qmake adds a name prefix and versioning postfixes (as well as file
+# links) to the target. This is hardcoded in the qmake code, so for now we use
+# the plugin configs to get what we want.
+CONFIG += plugin no_plugin_name_prefix
+
+javac.input = JAVASOURCES
+javac.output = $$CLASS_DIR
+javac.CONFIG += combine
+javac.commands = javac -source 6 -target 6 -cp $$shell_quote($$shell_path($$join(JAVACLASSPATH, $$QMAKE_DIRLIST_SEP))) -d $$shell_quote($$CLASS_DIR) ${QMAKE_FILE_IN}
+# Force rebuild every time, because we don't know the paths of the destination files
+# as they depend on the code.
+javac.depends = FORCE
+QMAKE_EXTRA_COMPILERS += javac
+
+mkpath($$absolute_path($$CLASS_DIR, $$OUT_PWD)) | error("Aborting.")
+
+# Disable all linker flags since we are overriding the regular linker
+QMAKE_LFLAGS =
+QMAKE_CFLAGS =
+QMAKE_LFLAGS_RPATH =
+QMAKE_LFLAGS_PLUGIN =
+QMAKE_LIBS =
+QMAKE_LIBS_OPENGL_ES2 =
+QMAKE_LIBDIR =
+QMAKE_EXTENSION_SHLIB = jar
+
+# Override linker with dex (for Android) or jar (for other java builds)
+android {
+ QMAKE_LINK_O_FLAG = --output=
+ contains(QMAKE_HOST.os, Windows) {
+ QMAKE_LINK = $$PWD/data/android/dx $$SDK_ROOT --dex
+ } else {
+ QMAKE_LINK = $$SDK_ROOT/platform-tools/dx --dex
+ }
+} else {
+ QMAKE_LINK_O_FLAG = "cf "
+ QMAKE_LINK = jar
+}
+
+# Force link step to always happen, since we are always updating the
+# .class files
+PRE_TARGETDEPS += FORCE
diff --git a/mkspecs/features/mac/default_post.prf b/mkspecs/features/mac/default_post.prf
index 273094d4cd..437e3d93e4 100644
--- a/mkspecs/features/mac/default_post.prf
+++ b/mkspecs/features/mac/default_post.prf
@@ -4,7 +4,7 @@ load(default_post)
# Pick a suitable default architecture for qmake-based applications.
# If the Qt package contains one of x86 and x86_64, pick that one. If it
# contains both then use the compiler default. Make a similiar decision for
-# PowerPC-based systems. Note that this logic assumes that Qt has been
+# PowerPC-based systems. Note that this logic assumes that Qt has been
# configured with an architecture that is usable on the system.
qt:!isEmpty(QT_CONFIG) {
contains(QMAKE_HOST.arch, ppc)|contains(QMAKE_HOST.arch, "Power Macintosh") {
@@ -15,3 +15,7 @@ qt:!isEmpty(QT_CONFIG) {
contains(QT_CONFIG, x86_64):!contains(QT_CONFIG, x86):CONFIG += x86_64
}
}
+
+# Ensure that we process sdk.prf first, as it will update QMAKE_CXX
+# and friends that other features/extra compilers may depend on.
+sdk: load(sdk)
diff --git a/mkspecs/features/mac/sdk.prf b/mkspecs/features/mac/sdk.prf
index 5eab94896b..ece0e27536 100644
--- a/mkspecs/features/mac/sdk.prf
+++ b/mkspecs/features/mac/sdk.prf
@@ -1,8 +1,58 @@
-!isEmpty(QMAKE_MAC_SDK) {
- !macx-xcode:!macx-pbuilder {
- QMAKE_CFLAGS += -isysroot $$QMAKE_MAC_SDK
- QMAKE_OBJECTIVE_CFLAGS += -isysroot $$QMAKE_MAC_SDK
- QMAKE_CXXFLAGS += -isysroot $$QMAKE_MAC_SDK
- QMAKE_LFLAGS += -Wl,-syslibroot,$$QMAKE_MAC_SDK
- }
+
+isEmpty(QMAKE_MAC_SDK): \
+ error("QMAKE_MAC_SDK must be set when using CONFIG += sdk.")
+
+contains(QMAKE_MAC_SDK, .*/.*): \
+ error("QMAKE_MAC_SDK can only contain short-form SDK names (eg. macosx, iphoneos)")
+
+QMAKE_MAC_SDK_PATH = $$system("/usr/bin/xcodebuild -sdk $$QMAKE_MAC_SDK -version Path 2>/dev/null")
+isEmpty(QMAKE_MAC_SDK_PATH): error("Could not resolve SDK path for \'$$QMAKE_MAC_SDK\'")
+
+!equals(MAKEFILE_GENERATOR, XCODE) {
+ QMAKE_CFLAGS += -isysroot $$QMAKE_MAC_SDK_PATH
+ QMAKE_CXXFLAGS += -isysroot $$QMAKE_MAC_SDK_PATH
+ QMAKE_OBJECTIVE_CFLAGS += -isysroot $$QMAKE_MAC_SDK_PATH
+ QMAKE_LFLAGS += -Wl,-syslibroot,$$QMAKE_MAC_SDK_PATH
+}
+
+sysrootified =
+for(val, QMAKE_INCDIR_OPENGL): sysrootified += $${QMAKE_MAC_SDK_PATH}$$val
+QMAKE_INCDIR_OPENGL = $$sysrootified
+
+# Resolve SDK version of various tools
+for(tool, $$list(QMAKE_CC QMAKE_CXX QMAKE_FIX_RPATH QMAKE_AR QMAKE_RANLIB QMAKE_LINK QMAKE_LINK_SHLIB)) {
+ value = $$eval($$tool)
+ isEmpty(value): next()
+
+ sysrooted = $$system("/usr/bin/xcrun -sdk $$QMAKE_MAC_SDK -find $$first(value) 2>/dev/null")
+ isEmpty(sysrooted): next()
+
+ $$tool = $$sysrooted $$member(value, 1, -1)
+}
+
+# We use xml as the output format instead of json since plutil on 10.6 does not have that option
+QMAKE_MAC_PLATFORM_NAME = $$system("plutil -convert xml1 \"$$QMAKE_MAC_SDK_PATH/SDKSettings.plist\" -o - | " \
+ "sed '/^<!DOCTYPE/d' | " \ # Don't look up http://www.apple.com/DTDs/PropertyList-1.0.dtd
+ "PERL5LIB= xpath 'string(//key[.=\"PLATFORM_NAME\"]/following-sibling::*[1])' 2>&1 | " \
+ "sed 's/.*Value: \\(.*\\)/\\1/'")
+
+isEmpty(QMAKE_MAC_PLATFORM_NAME): error("Could not resolve platform name for SDK '$$QMAKE_MAC_SDK'")
+
+!equals(MAKEFILE_GENERATOR, XCODE) {
+ # FIXME: Get the version_min_flag out of the platform's 'Native Build System.xcspec'
+ version_identifier = $$replace(QMAKE_MAC_PLATFORM_NAME, iphonesimulator, ios-simulator)
+
+ # C++11 support may affect the deployment target
+ c++11: load(c++11)
+
+ ios:!host_build: \
+ deployment_target = $$QMAKE_IOS_DEPLOYMENT_TARGET
+ else: \
+ deployment_target = $$QMAKE_MACOSX_DEPLOYMENT_TARGET
+
+ version_min_flag = -m$${version_identifier}-version-min=$$deployment_target
+ QMAKE_CFLAGS += $$version_min_flag
+ QMAKE_CXXFLAGS += $$version_min_flag
+ QMAKE_OBJECTIVE_CFLAGS += $$version_min_flag
+ QMAKE_LFLAGS += $$version_min_flag
}
diff --git a/mkspecs/features/moc.prf b/mkspecs/features/moc.prf
index 8bd512844d..59ac9db05b 100644
--- a/mkspecs/features/moc.prf
+++ b/mkspecs/features/moc.prf
@@ -9,7 +9,7 @@ isEmpty(QMAKE_EXT_CPP_MOC):QMAKE_EXT_CPP_MOC = .moc
# has too many includes. We do this to overcome a command-line limit on Win < XP
INCLUDETEMP=
WIN_INCLUDETEMP=
-win32:count($$list($$INCLUDEPATH), 40, >) {
+win32:count(INCLUDEPATH, 40, >) {
INCLUDETEMP = $$MOC_DIR/mocinclude.tmp
WIN_INCLUDETEMP=$$INCLUDETEMP
@@ -23,7 +23,7 @@ win32:count($$list($$INCLUDEPATH), 40, >) {
unset(INCFILELIST)
RET =
- for(incfile, $$list($$INCLUDEPATH)) {
+ for(incfile, INCLUDEPATH) {
INCFILELIST = -I$$incfile
isEmpty(RET): RET += @echo $$INCFILELIST> $$WIN_INCLUDETEMP $$EOC
else: RET += @echo $$INCFILELIST>> $$WIN_INCLUDETEMP $$EOC
@@ -38,15 +38,17 @@ win32:count($$list($$INCLUDEPATH), 40, >) {
}
defineReplace(mocCmdBase) {
+ RET =
!isEmpty(WIN_INCLUDETEMP) {
- RET =
contains(TEMPLATE, "vc.*") {
RET += $$mocinclude.commands
}
- RET += $$QMAKE_MOC $(DEFINES) @$$WIN_INCLUDETEMP $$join(QMAKE_COMPILER_DEFINES, " -D", -D) $$QMAKE_MOC_OPTIONS
- return($$RET)
+ incvar = @$$WIN_INCLUDETEMP
+ } else {
+ incvar = $(INCPATH)
}
- return($$QMAKE_MOC $(DEFINES) $(INCPATH) $$join(QMAKE_COMPILER_DEFINES, " -D", -D) $$QMAKE_MOC_OPTIONS)
+ RET += $$QMAKE_MOC $(DEFINES) $$join(QMAKE_COMPILER_DEFINES, " -D", -D) $$incvar $$join(QMAKE_DEFAULT_INCDIRS, " -I", -I) $$QMAKE_MOC_OPTIONS
+ return($$RET)
}
#moc headers
@@ -58,7 +60,7 @@ moc_header.input = HEADERS
moc_header.variable_out = SOURCES
moc_header.name = MOC ${QMAKE_FILE_IN}
!contains(TEMPLATE, "vc.*") {
- !isEmpty(INCLUDETEMP):moc_header.depends += $$INCLUDETEMP
+ !isEmpty(INCLUDETEMP):moc_header.depends += $$INCLUDETEMP
}
silent:moc_header.commands = @echo moc ${QMAKE_FILE_IN} && $$moc_header.commands
QMAKE_EXTRA_COMPILERS += moc_header
@@ -72,7 +74,7 @@ moc_source.output = $$MOC_DIR/$${QMAKE_CPP_MOD_MOC}${QMAKE_FILE_BASE}$${QMAKE_EX
moc_source.input = SOURCES OBJECTIVE_SOURCES
moc_source.name = MOC ${QMAKE_FILE_IN}
!contains(TEMPLATE, "vc.*") {
- !isEmpty(INCLUDETEMP):moc_source.depends += $$INCLUDETEMP
+ !isEmpty(INCLUDETEMP):moc_source.depends += $$INCLUDETEMP
}
silent:moc_source.commands = @echo moc ${QMAKE_FILE_IN} && $$moc_source.commands
QMAKE_EXTRA_COMPILERS += moc_source
diff --git a/mkspecs/features/qml_plugin.prf b/mkspecs/features/qml_plugin.prf
index f9beabdc18..70c3bd6b66 100644
--- a/mkspecs/features/qml_plugin.prf
+++ b/mkspecs/features/qml_plugin.prf
@@ -18,12 +18,8 @@ if(win32|mac):!macx-xcode {
contains(QT_CONFIG, debug_and_release):CONFIG += debug_and_release
contains(QT_CONFIG, build_all):CONFIG += build_all
}
-contains(QT_CONFIG, reduce_exports):CONFIG += hide_symbols
-contains(QT_CONFIG, separate_debug_info):CONFIG += separate_debug_info
-contains(QT_CONFIG, separate_debug_info_nocopy):CONFIG += separate_debug_info_nocopy
-contains(QT_CONFIG, c++11):CONFIG += c++11
-isEmpty(CXX_MODULE) {
+!no_cxx_module:isEmpty(CXX_MODULE) {
CXX_MODULE = $$TARGET
TARGET = declarative_$${TARGET}
}
@@ -34,11 +30,13 @@ exists($$QMLTYPEFILE): QML_FILES += $$QMLTYPEFILE
# Install rules
+load(qt_build_paths)
+
qml1_target {
- DESTDIR = $$eval(QT.$${CXX_MODULE}.imports)/$$TARGETPATH
+ DESTDIR = $$MODULE_BASE_OUTDIR/imports/$$TARGETPATH
instbase = $$[QT_INSTALL_IMPORTS]
} else {
- DESTDIR = $$eval(QT.$${CXX_MODULE}.qml)/$$TARGETPATH
+ DESTDIR = $$MODULE_BASE_OUTDIR/qml/$$TARGETPATH
instbase = $$[QT_INSTALL_QML]
}
@@ -50,6 +48,7 @@ INSTALLS += target
TARGET = $$qtLibraryTarget($$TARGET)
load(qt_targets)
+load(qt_common)
# plugins.qmltypes is used by Qt Creator for syntax highlighting and the QML code model. It needs
# to be regenerated whenever the QML elements exported by the plugin change. This cannot be done
@@ -61,7 +60,14 @@ load(qt_targets)
#
!cross_compile {
build_pass|!debug_and_release {
- isEmpty(IMPORT_VERSION): IMPORT_VERSION = $$eval(QT.$${CXX_MODULE}.MAJOR_VERSION).$$eval(QT.$${CXX_MODULE}.MINOR_VERSION)
+ isEmpty(IMPORT_VERSION) {
+ no_cxx_module {
+ IMPORT_VERSION = $$replace(MODULE_VERSION, ^(\\d+\\.\\d+).*, \\1)
+ isEmpty(IMPORT_VERSION): error("Must set IMPORT_VERSION")
+ } else {
+ IMPORT_VERSION = $$eval(QT.$${CXX_MODULE}.MAJOR_VERSION).$$eval(QT.$${CXX_MODULE}.MINOR_VERSION)
+ }
+ }
load(resolve_target)
qml1_target: \
@@ -94,7 +100,7 @@ unix|win32-g++* {
!isEmpty(_QMAKE_SUPER_CACHE_): \
lib_replace.match = $$dirname(_QMAKE_SUPER_CACHE_)/[^/][^/]*/lib
else: \
- lib_replace.match = $$eval(QT.$${CXX_MODULE}.libs)
+ lib_replace.match = $$MODULE_BASE_OUTDIR
lib_replace.replace = $$[QT_INSTALL_LIBS/raw]
QMAKE_PRL_INSTALL_REPLACE += lib_replace
}
diff --git a/mkspecs/features/qmltestcase.prf b/mkspecs/features/qmltestcase.prf
index 71e70e06a4..335ba90009 100644
--- a/mkspecs/features/qmltestcase.prf
+++ b/mkspecs/features/qmltestcase.prf
@@ -2,7 +2,7 @@ CONFIG += testcase
QT += qml qmltest
-macx: CONFIG -= app_bundle
+mac: CONFIG -= app_bundle
# If the .pro file specified an IMPORTPATH, then add that to
# the command-line when the test is run.
diff --git a/mkspecs/features/qpa/basicunixfontdatabase.prf b/mkspecs/features/qpa/basicunixfontdatabase.prf
index 65490e03a8..261eadb5d0 100644
--- a/mkspecs/features/qpa/basicunixfontdatabase.prf
+++ b/mkspecs/features/qpa/basicunixfontdatabase.prf
@@ -1,5 +1,3 @@
-DEFINES += QT_COMPILES_IN_HARFBUZZ
-
contains(QT_CONFIG, system-freetype) {
LIBS += -lfreetype
}
diff --git a/mkspecs/features/qpa/genericunixfontdatabase.prf b/mkspecs/features/qpa/genericunixfontdatabase.prf
index 36a358271c..fc11bea470 100644
--- a/mkspecs/features/qpa/genericunixfontdatabase.prf
+++ b/mkspecs/features/qpa/genericunixfontdatabase.prf
@@ -2,7 +2,7 @@ CONFIG += qpa/basicunixfontdatabase
contains(QT_CONFIG, fontconfig) {
DEFINES += Q_FONTCONFIGDATABASE
LIBS += -lfontconfig
-} else {
+} else:!android {
fonts.path = $$[QT_INSTALL_LIBS]/fonts
fonts.files = $$QT_SOURCE_TREE/lib/fonts/*
INSTALLS += fonts
diff --git a/mkspecs/features/qt_android_deps.prf b/mkspecs/features/qt_android_deps.prf
new file mode 100644
index 0000000000..27814a90a5
--- /dev/null
+++ b/mkspecs/features/qt_android_deps.prf
@@ -0,0 +1,53 @@
+
+# W A R N I N G
+# -------------
+#
+# This file is not part of the Qt API. It exists purely as an
+# implementation detail. It may change from version to version
+# without notice, or even be removed.
+#
+# We mean it.
+#
+
+# Generates an xml file to match the library in lib/ listing the dependencies
+# of the module on JNI-based libraries etc. Used for deployment of an Android
+# app.
+
+ANDROID_DEPENDS_DIR = $$MODULE_QMAKE_OUTDIR/lib/
+DEPENDENCY_FILE = $$ANDROID_DEPENDS_DIR$$TARGET-android-dependencies.xml
+
+!build_pass {
+ !isEmpty(ANDROID_JAR_DEPENDENCIES) {
+ for(JAR_FILE, ANDROID_JAR_DEPENDENCIES) {
+ INIT_CLASS = $$section(JAR_FILE, ":", 1, 1)
+ !isEmpty(INIT_CLASS): INIT_CLASS = "initClass=\"$$INIT_CLASS\""
+ JAR_FILE = $$section(JAR_FILE, ":", 0, 0)
+ FILE_CONTENT += "<jar file=\"$$JAR_FILE\" $$INIT_CLASS />"
+ }
+ }
+
+ !isEmpty(ANDROID_LIB_DEPENDENCIES) {
+ for(LIB_FILE, ANDROID_LIB_DEPENDENCIES) {
+ FILE_CONTENT += "<lib file=\"$$LIB_FILE\" />"
+ }
+ }
+
+ !isEmpty(ANDROID_LIB_DEPENDENCY_REPLACEMENTS) {
+ for(REPLACEMENT, ANDROID_LIB_DEPENDENCY_REPLACEMENTS) {
+ REPLACEMENT_FILE = $$section(REPLACEMENT, ":", 0, 0)
+ LIB_FILE = $$section(REPLACEMENT, ":", 1, 1)
+ FILE_CONTENT += "<lib file=\"$$LIB_FILE\" replaces=\"$$REPLACEMENT_FILE\" />"
+ }
+ }
+
+ !isEmpty(FILE_CONTENT) {
+ FILE_CONTENT = "<rules><dependencies><lib name=\"$$TARGET\"><depends>" $$FILE_CONTENT "</depends></lib></dependencies></rules>"
+ write_file($$DEPENDENCY_FILE, FILE_CONTENT) | error("Aborting.")
+ }
+}
+
+!isEmpty(ANDROID_JAR_DEPENDENCIES)|!isEmpty(ANDROID_LIB_DEPENDENCIES)|!isEmpty(ANDROID_LIB_DEPENDENCY_REPLACEMENTS) {
+ install_dependencies_file.files = $$DEPENDENCY_FILE
+ install_dependencies_file.path = $$[QT_INSTALL_LIBS]
+ INSTALLS += install_dependencies_file
+}
diff --git a/mkspecs/features/qt_build_config.prf b/mkspecs/features/qt_build_config.prf
index 88c1f3f3f2..4cbd08910c 100644
--- a/mkspecs/features/qt_build_config.prf
+++ b/mkspecs/features/qt_build_config.prf
@@ -40,6 +40,9 @@ mac {
}
}
+cross_compile: \
+ CONFIG += force_bootstrap
+
CONFIG += \
create_prl link_prl \
prepare_docs qt_docs_targets \
diff --git a/mkspecs/features/qt_common.prf b/mkspecs/features/qt_common.prf
new file mode 100644
index 0000000000..10b7736749
--- /dev/null
+++ b/mkspecs/features/qt_common.prf
@@ -0,0 +1,54 @@
+#
+# W A R N I N G
+# -------------
+#
+# This file is not part of the Qt API. It exists purely as an
+# implementation detail. It may change from version to version
+# without notice, or even be removed.
+#
+# We mean it.
+#
+
+contains(QT_CONFIG, c++11): CONFIG += c++11
+contains(TEMPLATE, .*lib) {
+ # module and plugins
+ contains(QT_CONFIG, reduce_exports): CONFIG += hide_symbols
+ unix:contains(QT_CONFIG, reduce_relocations): CONFIG += bsymbolic_functions
+ contains(QT_CONFIG, largefile): CONFIG += largefile
+ contains(QT_CONFIG, separate_debug_info): CONFIG += separate_debug_info
+ contains(QT_CONFIG, separate_debug_info_nocopy): CONFIG += separate_debug_info_nocopy
+}
+
+warnings_are_errors:warning_clean {
+ # If the module declares that it has does its clean-up of warnings, enable -Werror.
+ # This setting is compiler-dependent anyway because it depends on the version of the
+ # compiler.
+ clang {
+ # Apple clang 4.0+ or clang 3.1+
+ greaterThan(QT_CLANG_MAJOR_VERSION, 3) | \
+ if(equals(QT_CLANG_MAJOR_VERSION, 3):greaterThan(QT_CLANG_MINOR_VERSION, 1)) | \
+ greaterThan(QT_APPLE_CLANG_MAJOR_VERSION, 3) {
+ QMAKE_CXXFLAGS += -Werror -Wno-error=\\$${LITERAL_HASH}warnings $$WERROR
+ }
+ } else:intel_icc {
+ # Intel CC 13.0+ (a.k.a. Intel Composer XE 2013)
+ greaterThan(QT_ICC_MAJOR_VERSION, 12) {
+ # 177: function "entity" was declared but never referenced
+ # (too aggressive; ICC reports even for functions created due to template instantiation)
+ # 1224: #warning directive
+ # 1881: argument must be a constant null pointer value
+ # (NULL in C++ is usually a literal 0)
+ QMAKE_CXXFLAGS += -Werror -ww177,1224,1881 $$WERROR
+ }
+ } else:gcc {
+ # GCC 4.6+
+ # note: there was no GCC 3.6 and this assumes no one is crazy enough to compile Qt with GCC 2.7
+ greaterThan(QT_GCC_MAJOR_VERSION, 4)|greaterThan(QT_GCC_MINOR_VERSION, 5) {
+ QMAKE_CXXFLAGS += -Werror -Wno-error=cpp $$WERROR
+
+ # GCC prints this bogus warning, after it has inlined a lot of code
+ # error: assuming signed overflow does not occur when assuming that (X + c) < X is always false
+ QMAKE_CXXFLAGS += -Wno-error=strict-overflow
+ }
+ }
+}
diff --git a/mkspecs/features/qt_docs.prf b/mkspecs/features/qt_docs.prf
index c80efb03e0..5b42cfcac8 100644
--- a/mkspecs/features/qt_docs.prf
+++ b/mkspecs/features/qt_docs.prf
@@ -32,7 +32,9 @@ qtmver.name = QT_VER
qtmver.value = $$replace(qtver.value, ^(\\d+\\.\\d+).*$, \\1)
qtvertag.name = QT_VERSION_TAG
qtvertag.value = $$replace(qtver.value, \.,)
-qtAddToolEnv(QDOC, qtver qtmver qtvertag)
+qtdocs.name = QT_INSTALL_DOCS
+qtdocs.value = $$[QT_INSTALL_DOCS/get]
+qtAddToolEnv(QDOC, qtver qtmver qtvertag qtdocs)
doc_command = $$QDOC $$QMAKE_DOCS
prepare_docs {
prepare_docs.commands += $$doc_command -prepare -no-link-errors
diff --git a/mkspecs/features/qt_module.prf b/mkspecs/features/qt_module.prf
index 1132943d97..3531d28b42 100644
--- a/mkspecs/features/qt_module.prf
+++ b/mkspecs/features/qt_module.prf
@@ -27,6 +27,19 @@ isEmpty(VERSION): error("Module does not define version.")
# unless overridden. Host builds are always static
host_build|staticlib: CONFIG += static
+host_build {
+ QT -= gui # no host module will ever use gui
+ force_bootstrap {
+ !build_pass: CONFIG += release
+ contains(QT, core(-private)?|xml) {
+ QT -= core core-private xml
+ QT += bootstrap-private
+ }
+ } else {
+ !build_pass:contains(QT_CONFIG, build_all): CONFIG += release
+ }
+}
+
ucmodule = $$upper($$MODULE)
isEmpty(MODULE_INCNAME): MODULE_INCNAME = $$TARGET
@@ -74,13 +87,6 @@ contains(TARGET, QtAddOn.*): \
else: \
DEFINES += QT_BUILD_$${ucmodule}_LIB
-contains(QT_CONFIG, reduce_exports):CONFIG += hide_symbols
-unix:contains(QT_CONFIG, reduce_relocations):CONFIG += bsymbolic_functions
-contains(QT_CONFIG, largefile):CONFIG += largefile
-contains(QT_CONFIG, separate_debug_info):CONFIG += separate_debug_info
-contains(QT_CONFIG, separate_debug_info_nocopy):CONFIG += separate_debug_info_nocopy
-contains(QT_CONFIG, c++11):CONFIG += c++11
-
#mac frameworks
mac:CONFIG(shared, static|shared):contains(QT_CONFIG, qt_framework) {
#QMAKE_FRAMEWORK_VERSION = 4.0
@@ -115,6 +121,8 @@ aix-g++* {
QMAKE_CXXFLAGS += -mminimal-toc
}
+android: CONFIG += qt_android_deps
+
#install directives
load(qt_installs)
@@ -169,6 +177,7 @@ win32 {
TARGET = $$qtLibraryTarget($$TARGET$$QT_LIBINFIX) #do this towards the end
load(qt_targets)
+load(qt_common)
win32:DEFINES+=_USE_MATH_DEFINES
diff --git a/mkspecs/features/qt_module_headers.prf b/mkspecs/features/qt_module_headers.prf
index 40d6bb0d40..298ca102bc 100644
--- a/mkspecs/features/qt_module_headers.prf
+++ b/mkspecs/features/qt_module_headers.prf
@@ -13,13 +13,21 @@ load(qt_build_paths)
!build_pass {
qtPrepareTool(QMAKE_SYNCQT, syncqt)
- contains(QT_CONFIG, private_tests): \ # -developer-build
- QMAKE_SYNCQT += -check-includes
- QMAKE_SYNCQT += -module $$MODULE_INCNAME -version $$VERSION -outdir $$MODULE_BASE_OUTDIR $$MODULE_BASE_DIR
+ minimal_syncqt {
+ QMAKE_SYNCQT += -minimal $$QMAKE_SYNCQT_OPTIONS
+ } else {
+ contains(QT_CONFIG, private_tests): \ # -developer-build
+ QMAKE_SYNCQT += -check-includes
+ QMAKE_SYNCQT += -module $$MODULE_INCNAME -version $$VERSION
+ }
+ QMAKE_SYNCQT += \
+ -outdir $$MODULE_BASE_OUTDIR $$MODULE_BASE_DIR
!silent: message($$QMAKE_SYNCQT)
system($$QMAKE_SYNCQT)|error("Failed to run: $$QMAKE_SYNCQT")
}
+minimal_syncqt: return()
+
#load up the headers info
include($$MODULE_BASE_OUTDIR/include/$$MODULE_INCNAME/headers.pri, "", true)
diff --git a/mkspecs/features/qt_module_pris.prf b/mkspecs/features/qt_module_pris.prf
index 03863e0648..bedcfd4c47 100644
--- a/mkspecs/features/qt_module_pris.prf
+++ b/mkspecs/features/qt_module_pris.prf
@@ -43,7 +43,7 @@ else: \
module_config = "QT.$${MODULE}.CONFIG = $$MODULE_CONFIG"
else: \
module_config =
- !no_module_headers {
+ !no_module_headers:!minimal_syncqt {
MODULE_INCLUDES = "\$\$QT_MODULE_INCLUDE_BASE \$\$QT_MODULE_INCLUDE_BASE/$$MODULE_INCNAME"
MODULE_PRIVATE_INCLUDES = "\$\$QT_MODULE_INCLUDE_BASE/$$MODULE_INCNAME/$$VERSION \
\$\$QT_MODULE_INCLUDE_BASE/$$MODULE_INCNAME/$$VERSION/$$MODULE_INCNAME"
diff --git a/mkspecs/features/qt_plugin.prf b/mkspecs/features/qt_plugin.prf
index 158de39753..9f4882c5db 100644
--- a/mkspecs/features/qt_plugin.prf
+++ b/mkspecs/features/qt_plugin.prf
@@ -23,10 +23,6 @@ tool_plugin {
contains(QT_CONFIG, debug_and_release):CONFIG += debug_and_release
contains(QT_CONFIG, build_all):CONFIG += build_all
}
-contains(QT_CONFIG, reduce_exports):CONFIG += hide_symbols
-contains(QT_CONFIG, separate_debug_info):CONFIG += separate_debug_info
-contains(QT_CONFIG, separate_debug_info_nocopy):CONFIG += separate_debug_info_nocopy
-contains(QT_CONFIG, c++11):CONFIG += c++11
CONFIG(static, static|shared) {
isEmpty(MODULE): MODULE = $$basename(TARGET)
@@ -52,6 +48,7 @@ INSTALLS += target
TARGET = $$qtLibraryTarget($$TARGET)
load(qt_targets)
+load(qt_common)
wince*:LIBS += $$QMAKE_LIBS_GUI
QMAKE_LFLAGS += $$QMAKE_LFLAGS_NOUNDEF
diff --git a/mkspecs/features/qt_tool.prf b/mkspecs/features/qt_tool.prf
index 9d50856900..46d031fb32 100644
--- a/mkspecs/features/qt_tool.prf
+++ b/mkspecs/features/qt_tool.prf
@@ -17,9 +17,13 @@ DESTDIR = $$MODULE_BASE_OUTDIR/bin
CONFIG += console
isEmpty(QMAKE_INFO_PLIST): CONFIG -= app_bundle
-host_build {
+host_build: QT -= gui # no host tool will ever use gui
+host_build:force_bootstrap {
!build_pass: CONFIG += release
- QT = bootstrap-private
+ contains(QT, core(-private)?|xml) {
+ QT -= core core-private xml
+ QT += bootstrap-private
+ }
target.path = $$[QT_HOST_BINS]
} else {
!build_pass:contains(QT_CONFIG, build_all): CONFIG += release
@@ -28,11 +32,12 @@ host_build {
INSTALLS += target
load(qt_targets)
+load(qt_common)
# If we are doing a prefix build, create a "module" pri which enables
# qtPrepareTool() to work with the non-installed build.
-!build_pass:force_independent {
-
+# Non-bootstrapped tools always need this because of the environment setup.
+!build_pass:if(!host_build|!force_bootstrap|force_independent) {
isEmpty(MODULE):MODULE = $$TARGET
MODULE_DEPENDS = $$replace(QT, -private$, )
@@ -41,7 +46,7 @@ load(qt_targets)
load(resolve_target)
cmd = $$shell_path($$QMAKE_RESOLVED_TARGET)
- !host_build: qtAddTargetEnv(cmd)
+ !host_build|!force_bootstrap: qtAddTargetEnv(cmd)
TOOL_PRI = $$MODULE_QMAKE_OUTDIR/mkspecs/modules/qt_tool_$${MODULE}.pri
diff --git a/mkspecs/features/resolve_target.prf b/mkspecs/features/resolve_target.prf
index 8cd12b2a00..22d7722ce3 100644
--- a/mkspecs/features/resolve_target.prf
+++ b/mkspecs/features/resolve_target.prf
@@ -28,7 +28,7 @@ win32 {
} else {
contains(TEMPLATE, .*lib):LIBPREFIX = lib
- macx {
+ mac {
equals(TEMPLATE, lib) {
lib_bundle {
QMAKE_RESOLVED_TARGET = $${QMAKE_RESOLVED_TARGET}$${TARGET}.framework/$${TARGET}
diff --git a/mkspecs/features/testcase.prf b/mkspecs/features/testcase.prf
index faf4eeb124..15febe2dd5 100644
--- a/mkspecs/features/testcase.prf
+++ b/mkspecs/features/testcase.prf
@@ -32,7 +32,7 @@ contains(MUNGED_TARGET,.*/.*):check.commands = cd $(DESTDIR) &&
# Allow for a custom test runner script
check.commands += $(TESTRUNNER)
-macx {
+mac {
app_bundle: check.commands += ./$(QMAKE_TARGET).app/Contents/MacOS/$(QMAKE_TARGET)
else: check.commands += ./$(QMAKE_TARGET)
}
diff --git a/mkspecs/features/unix/opengl.prf b/mkspecs/features/unix/opengl.prf
index 74a514915d..8dd47d089d 100644
--- a/mkspecs/features/unix/opengl.prf
+++ b/mkspecs/features/unix/opengl.prf
@@ -11,7 +11,7 @@ contains(QT_CONFIG, opengles1) {
} else {
INCLUDEPATH += $$QMAKE_INCDIR_OPENGL
!isEmpty(QMAKE_LIBDIR_OPENGL):QMAKE_LIBDIR += $$QMAKE_LIBDIR_OPENGL
- target_qt:LIBS_PRIVATE += $$QMAKE_LIBS_OPENGL_QT
+ target_qt:LIBS_PRIVATE += $$QMAKE_LIBS_OPENGL
else:LIBS += $$QMAKE_LIBS_OPENGL
}
diff --git a/mkspecs/features/unix/separate_debug_info.prf b/mkspecs/features/unix/separate_debug_info.prf
index cea1731888..c5ff6dcba3 100644
--- a/mkspecs/features/unix/separate_debug_info.prf
+++ b/mkspecs/features/unix/separate_debug_info.prf
@@ -1,8 +1,15 @@
!separate_debug_info_nocopy:have_target:!static:!isEmpty(QMAKE_OBJCOPY) {
- qnx:debug_info_suffix=sym
- else:debug_info_suffix=debug
- QMAKE_SEPARATE_DEBUG_INFO = test -z \"$(DESTDIR)\" || cd \"$(DESTDIR)\" ; targ=`basename $(TARGET)`; $$QMAKE_OBJCOPY --only-keep-debug \"\$\$targ\" \"\$\$targ.$$debug_info_suffix\" && $$QMAKE_OBJCOPY --strip-debug \"\$\$targ\" && $$QMAKE_OBJCOPY --add-gnu-debuglink=\"\$\$targ.$$debug_info_suffix\" \"\$\$targ\" && chmod -x \"\$\$targ.$$debug_info_suffix\"
+ qnx {
+ debug_info_suffix = sym
+ debug_info_keep = --keep-file-symbols
+ debug_info_strip = --strip-debug -R.ident
+ } else {
+ debug_info_suffix = debug
+ debug_info_keep = --only-keep-debug
+ debug_info_strip = --strip-debug
+ }
+ QMAKE_SEPARATE_DEBUG_INFO = test -z \"$(DESTDIR)\" || cd \"$(DESTDIR)\" ; targ=`basename $(TARGET)`; $$QMAKE_OBJCOPY $$debug_info_keep \"\$\$targ\" \"\$\$targ.$$debug_info_suffix\" && $$QMAKE_OBJCOPY $$debug_info_strip \"\$\$targ\" && $$QMAKE_OBJCOPY --add-gnu-debuglink=\"\$\$targ.$$debug_info_suffix\" \"\$\$targ\" && chmod -x \"\$\$targ.$$debug_info_suffix\"
QMAKE_INSTALL_SEPARATE_DEBUG_INFO = test -z \"$(DESTDIR)\" || cd \"$(DESTDIR)\" ; $(INSTALL_FILE) `basename $(TARGET)`.$$debug_info_suffix $(INSTALL_ROOT)/\$\$target_path/
!isEmpty(QMAKE_POST_LINK):QMAKE_POST_LINK = $$escape_expand(\\n\\t)$$QMAKE_POST_LINK
diff --git a/mkspecs/features/win32/opengl.prf b/mkspecs/features/win32/opengl.prf
index 898dee77f9..0f33f31e59 100644
--- a/mkspecs/features/win32/opengl.prf
+++ b/mkspecs/features/win32/opengl.prf
@@ -21,6 +21,7 @@ wince* {
QMAKE_LIBDIR += $$QMAKE_LIBDIR_OPENGL_ES2_RELEASE
}
DEFINES += QT_OPENGL_ES_2 QT_OPENGL_ES_2_ANGLE
+ contains(QT_CONFIG, static): DEFINES += QT_OPENGL_ES_2_ANGLE_STATIC
QT_CONFIG -= opengl
} else {
QMAKE_LIBS += $$QMAKE_LIBS_OPENGL
diff --git a/mkspecs/freebsd-g++/qmake.conf b/mkspecs/freebsd-g++/qmake.conf
index 9e95a3e2c6..4e078ce2f2 100644
--- a/mkspecs/freebsd-g++/qmake.conf
+++ b/mkspecs/freebsd-g++/qmake.conf
@@ -2,34 +2,33 @@
# qmake configuration for freebsd-g++
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = freebsd bsd
-CONFIG += gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = freebsd bsd
+CONFIG += gdb_dwarf_index
-QMAKE_CFLAGS_THREAD = -pthread -D_THREAD_SAFE
+QMAKE_CFLAGS_THREAD = -pthread -D_THREAD_SAFE
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
# Addon software goes into /usr/local on the BSDs, by default we will look there
-QMAKE_INCDIR = /usr/local/include
-QMAKE_LIBDIR = /usr/local/lib
-QMAKE_INCDIR_X11 = /usr/X11R6/include
-QMAKE_LIBDIR_X11 = /usr/X11R6/lib
-QMAKE_INCDIR_OPENGL = /usr/X11R6/include
-QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
-
-QMAKE_LFLAGS_THREAD = -pthread
-
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD =
-
-QMAKE_AR = ar cqs
+QMAKE_INCDIR = /usr/local/include
+QMAKE_LIBDIR = /usr/local/lib
+QMAKE_INCDIR_X11 = /usr/X11R6/include
+QMAKE_LIBDIR_X11 = /usr/X11R6/lib
+QMAKE_INCDIR_OPENGL = /usr/X11R6/include
+QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
+
+QMAKE_LFLAGS_THREAD = -pthread
+
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD =
+
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
include(../common/gcc-base-unix.conf)
diff --git a/mkspecs/freebsd-g++46/qmake.conf b/mkspecs/freebsd-g++46/qmake.conf
index bddc196811..364dcd6233 100644
--- a/mkspecs/freebsd-g++46/qmake.conf
+++ b/mkspecs/freebsd-g++46/qmake.conf
@@ -2,34 +2,33 @@
# qmake configuration for freebsd-g++46 (using g++46 from ports/lang/gcc)
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = freebsd bsd
-CONFIG += gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = freebsd bsd
+CONFIG += gdb_dwarf_index
-QMAKE_CFLAGS_THREAD = -pthread -D_THREAD_SAFE
+QMAKE_CFLAGS_THREAD = -pthread -D_THREAD_SAFE
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
# Addon software goes into /usr/local on the BSDs, by default we will look there
-QMAKE_INCDIR = /usr/local/include
-QMAKE_LIBDIR = /usr/local/lib
-QMAKE_INCDIR_X11 = /usr/X11R6/include
-QMAKE_LIBDIR_X11 = /usr/X11R6/lib
-QMAKE_INCDIR_OPENGL = /usr/X11R6/include
-QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
-
-QMAKE_LFLAGS_THREAD = -pthread
-
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD =
-
-QMAKE_AR = ar cqs
+QMAKE_INCDIR = /usr/local/include
+QMAKE_LIBDIR = /usr/local/lib
+QMAKE_INCDIR_X11 = /usr/X11R6/include
+QMAKE_LIBDIR_X11 = /usr/X11R6/lib
+QMAKE_INCDIR_OPENGL = /usr/X11R6/include
+QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
+
+QMAKE_LFLAGS_THREAD = -pthread
+
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD =
+
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
include(../common/gcc-base-unix.conf)
@@ -37,11 +36,11 @@ include(../common/g++-unix.conf)
# Redefined here because g++-base.conf sets QMAKE_CC and QMAKE_CXX
# to gcc and g++, respectively.
-QMAKE_CC = gcc46
-QMAKE_CXX = g++46
-QMAKE_LINK_C = $$QMAKE_CC
-QMAKE_LINK_C_SHLIB = $$QMAKE_CC
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
+QMAKE_CC = gcc46
+QMAKE_CXX = g++46
+QMAKE_LINK_C = $$QMAKE_CC
+QMAKE_LINK_C_SHLIB = $$QMAKE_CC
+QMAKE_LINK = $$QMAKE_CXX
+QMAKE_LINK_SHLIB = $$QMAKE_CXX
load(qt_config)
diff --git a/mkspecs/freebsd-icc/qmake.conf b/mkspecs/freebsd-icc/qmake.conf
index 046b20c896..91aeb25520 100644
--- a/mkspecs/freebsd-icc/qmake.conf
+++ b/mkspecs/freebsd-icc/qmake.conf
@@ -27,68 +27,67 @@
# warning #1572: floating-point equality and inequality comparisons are unreliable
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = freebsd bsd
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = freebsd bsd
-QMAKE_COMPILER = gcc intel_icc # icc pretends to be gcc
+QMAKE_COMPILER = gcc intel_icc # icc pretends to be gcc
-QMAKE_CC = icc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -wd858,1572
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -w2 -wd171,193,279,304,310,383,424,444,488,810,967,981,1418,1419,1476,1477
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE =
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fpic
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC =
-QMAKE_CFLAGS_THREAD = -D_THREAD_SAFE
+QMAKE_CC = icc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -wd858,1572
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -w2 -wd171,193,279,304,310,383,424,444,488,810,967,981,1418,1419,1476,1477
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE =
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fpic
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_THREAD = -D_THREAD_SAFE
-QMAKE_CXX = icpc
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = icpc
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
# Addon software goes into /usr/local on the BSDs, by default we will look there
-QMAKE_INCDIR = /usr/local/include
-QMAKE_LIBDIR = /usr/local/lib
-QMAKE_INCDIR_X11 = /usr/X11R6/include
-QMAKE_LIBDIR_X11 = /usr/X11R6/lib
-QMAKE_INCDIR_OPENGL = /usr/X11R6/include
-QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
+QMAKE_INCDIR = /usr/local/include
+QMAKE_LIBDIR = /usr/local/lib
+QMAKE_INCDIR_X11 = /usr/X11R6/include
+QMAKE_LIBDIR_X11 = /usr/X11R6/lib
+QMAKE_INCDIR_OPENGL = /usr/X11R6/include
+QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
-QMAKE_LINK = icpc
-QMAKE_LINK_SHLIB = icpc
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Qoption,ld,-soname,
-QMAKE_LFLAGS_THREAD = -mt
-QMAKE_LFLAGS_RPATH = -Qoption,ld,-rpath,
+QMAKE_LINK = icpc
+QMAKE_LINK_SHLIB = icpc
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Qoption,ld,-soname,
+QMAKE_LFLAGS_THREAD = -mt
+QMAKE_LFLAGS_RPATH = -Qoption,ld,-rpath,
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD =
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD =
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/hpux-acc-64/qmake.conf b/mkspecs/hpux-acc-64/qmake.conf
index b285c2cdb6..60c87c29bf 100644
--- a/mkspecs/hpux-acc-64/qmake.conf
+++ b/mkspecs/hpux-acc-64/qmake.conf
@@ -4,112 +4,111 @@
# We define _POSIX_C_SOURCE to 199506L when using threads, therefore
# we also need to redefine _HPUX_SOURCE.
# From pthread(3t):
-# Some documentation will recommend the use of -D_REENTRANT for
-# compilation. While this also functions properly, it is considered
-# an obsolescent form.
+# Some documentation will recommend the use of -D_REENTRANT for
+# compilation. While this also functions properly, it is considered
+# an obsolescent form.
# See pthread(3t) for more details.
#
# From the "HP aC++ Online Programmer's Guide":
-# When +DA2.0W is specified:
-# * 64-bit SVR4 Executable and Linking Format (ELF) object files
-# are generated for PA-RISC 2.0.
-# * The preprocessor predefined macro, __LP64__ is defined.
-# * The correct path for 64-bit system and language libraries is
-# selected.
-# When +DD32 is specified:
-# * The size of an int, long, or pointer data type is 32-bits.
-# The size of an int data type is 32-bits. The size of a long or
-# pointer data type is 64-bits.
-# * This is the default, currently equivalent to +DA1.1 architecture.
-# When +DD64 is specified:
-# * The size of an int data type is 32-bits. The size of a long or
-# pointer data type is 64-bits.
-# * This is currently equivalent to +DA2.OW architecture.
-# * The preprocessor predefined macro, __LP64__ is defined.
-# Using +DS to Specify Instruction Scheduling:
-# * By default, the compiler performs scheduling tuned for the system
-# on which you are compiling, or, if specified, tuned for the setting
-# of the +DA option.
+# When +DA2.0W is specified:
+# * 64-bit SVR4 Executable and Linking Format (ELF) object files
+# are generated for PA-RISC 2.0.
+# * The preprocessor predefined macro, __LP64__ is defined.
+# * The correct path for 64-bit system and language libraries is
+# selected.
+# When +DD32 is specified:
+# * The size of an int, long, or pointer data type is 32-bits.
+# The size of an int data type is 32-bits. The size of a long or
+# pointer data type is 64-bits.
+# * This is the default, currently equivalent to +DA1.1 architecture.
+# When +DD64 is specified:
+# * The size of an int data type is 32-bits. The size of a long or
+# pointer data type is 64-bits.
+# * This is currently equivalent to +DA2.OW architecture.
+# * The preprocessor predefined macro, __LP64__ is defined.
+# Using +DS to Specify Instruction Scheduling:
+# * By default, the compiler performs scheduling tuned for the system
+# on which you are compiling, or, if specified, tuned for the setting
+# of the +DA option.
#
# From the online "C/HP-UX Reference Manual":
-# -Aa
-# Enables strict ANSI C compliance.
-# -Ae
-# Enables ANSI C compliance, HP value-added features (as described
-# for +e option), and _HPUX_SOURCE name space macro. It is equivalent
-# to -Aa +e -D_HPUX_SOURCE.
-# +e
-# Enables the following HP value added features while compiling in
-# ANSI C mode: sized enum, long long, long pointers, compiler supplied
-# defaults for missing arguments to intrinsic calls, and $ in identifier
-# HP C extensions.
+# -Aa
+# Enables strict ANSI C compliance.
+# -Ae
+# Enables ANSI C compliance, HP value-added features (as described
+# for +e option), and _HPUX_SOURCE name space macro. It is equivalent
+# to -Aa +e -D_HPUX_SOURCE.
+# +e
+# Enables the following HP value added features while compiling in
+# ANSI C mode: sized enum, long long, long pointers, compiler supplied
+# defaults for missing arguments to intrinsic calls, and $ in identifier
+# HP C extensions.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = hpux
-QMAKE_COMPILER_DEFINES += __hpux __HP_aCC
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = hpux
+QMAKE_COMPILER_DEFINES += __hpux __HP_aCC
-QMAKE_COMPILER = hp_acc
+QMAKE_COMPILER = hp_acc
-QMAKE_CC = cc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -Ae +DA2.0W -w
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = +O1
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = +Z
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC =
-QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE -mt
+QMAKE_CC = cc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -Ae +DA2.0W -w
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = +O1
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = +Z
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE -mt
-QMAKE_CXX = aCC
-QMAKE_CXXFLAGS = -AA +DA2.0W -w -D__STRICT_ANSI__ -D_HPUX_SOURCE
-QMAKE_CXXFLAGS_DEPS = +M
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = aCC
+QMAKE_CXXFLAGS = -AA +DA2.0W -w -D__STRICT_ANSI__ -D_HPUX_SOURCE
+QMAKE_CXXFLAGS_DEPS = +M
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -mt
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -mt
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = /usr/include/X11R6
-QMAKE_LIBDIR_X11 = /usr/lib/X11R6/pa20_64
-QMAKE_INCDIR_OPENGL = /opt/graphics/OpenGL/include /usr/contrib/X11R6/include
-QMAKE_LIBDIR_OPENGL = /opt/graphics/OpenGL/lib/pa20_64 /usr/contrib/X11R6/lib/pa20_64
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = /usr/include/X11R6
+QMAKE_LIBDIR_X11 = /usr/lib/X11R6/pa20_64
+QMAKE_INCDIR_OPENGL = /opt/graphics/OpenGL/include /usr/contrib/X11R6/include
+QMAKE_LIBDIR_OPENGL = /opt/graphics/OpenGL/lib/pa20_64 /usr/contrib/X11R6/lib/pa20_64
-QMAKE_LINK = aCC
-QMAKE_LINK_SHLIB = aCC
-QMAKE_LFLAGS = -AA +DA2.0W -Wl,+s
-QMAKE_LFLAGS_RELEASE = -O
-QMAKE_LFLAGS_DEBUG = -g
-QMAKE_LFLAGS_SHLIB = -b -Wl,-a,shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,+h,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
-QMAKE_LFLAGS_RPATH = -Wl,+b,
-QMAKE_HPUX_SHLIB = 3
-QMAKE_EXTENSION_SHLIB = sl
+QMAKE_LINK = aCC
+QMAKE_LINK_SHLIB = aCC
+QMAKE_LFLAGS = -AA +DA2.0W -Wl,+s
+QMAKE_LFLAGS_RELEASE = -O
+QMAKE_LFLAGS_DEBUG = -g
+QMAKE_LFLAGS_SHLIB = -b -Wl,-a,shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,+h,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
+QMAKE_LFLAGS_RPATH = -Wl,+b,
+QMAKE_HPUX_SHLIB = 3
+QMAKE_EXTENSION_SHLIB = sl
-QMAKE_LIBS = -lm
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11
-QMAKE_LIBS_OPENGL = -lGL -lXt
-QMAKE_LIBS_OPENGL_QT = -lGL -lXt
-QMAKE_LIBS_THREAD = -lpthread
-QMAKE_LIBS_YACC = -ly
+QMAKE_LIBS = -lm
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11
+QMAKE_LIBS_OPENGL = -lGL -lXt
+QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS_YACC = -ly
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/hpux-acc-o64/qmake.conf b/mkspecs/hpux-acc-o64/qmake.conf
index 985378d9fb..c11909fb81 100644
--- a/mkspecs/hpux-acc-o64/qmake.conf
+++ b/mkspecs/hpux-acc-o64/qmake.conf
@@ -4,110 +4,109 @@
# We define _POSIX_C_SOURCE to 199506L when using threads, therefore
# we also need to redefine _HPUX_SOURCE.
# From pthread(3t):
-# Some documentation will recommend the use of -D_REENTRANT for
-# compilation. While this also functions properly, it is considered
-# an obsolescent form.
+# Some documentation will recommend the use of -D_REENTRANT for
+# compilation. While this also functions properly, it is considered
+# an obsolescent form.
# See pthread(3t) for more details.
#
# From the "HP aC++ Online Programmer's Guide":
-# When +DA2.0W is specified:
-# * 64-bit SVR4 Executable and Linking Format (ELF) object files
-# are generated for PA-RISC 2.0.
-# * The preprocessor predefined macro, __LP64__ is defined.
-# * The correct path for 64-bit system and language libraries is
-# selected.
-# When +DD32 is specified:
-# * The size of an int, long, or pointer data type is 32-bits.
-# The size of an int data type is 32-bits. The size of a long or
-# pointer data type is 64-bits.
-# * This is the default, currently equivalent to +DA1.1 architecture.
-# When +DD64 is specified:
-# * The size of an int data type is 32-bits. The size of a long or
-# pointer data type is 64-bits.
-# * This is currently equivalent to +DA2.OW architecture.
-# * The preprocessor predefined macro, __LP64__ is defined.
-# Using +DS to Specify Instruction Scheduling:
-# * By default, the compiler performs scheduling tuned for the system
-# on which you are compiling, or, if specified, tuned for the setting
-# of the +DA option.
+# When +DA2.0W is specified:
+# * 64-bit SVR4 Executable and Linking Format (ELF) object files
+# are generated for PA-RISC 2.0.
+# * The preprocessor predefined macro, __LP64__ is defined.
+# * The correct path for 64-bit system and language libraries is
+# selected.
+# When +DD32 is specified:
+# * The size of an int, long, or pointer data type is 32-bits.
+# The size of an int data type is 32-bits. The size of a long or
+# pointer data type is 64-bits.
+# * This is the default, currently equivalent to +DA1.1 architecture.
+# When +DD64 is specified:
+# * The size of an int data type is 32-bits. The size of a long or
+# pointer data type is 64-bits.
+# * This is currently equivalent to +DA2.OW architecture.
+# * The preprocessor predefined macro, __LP64__ is defined.
+# Using +DS to Specify Instruction Scheduling:
+# * By default, the compiler performs scheduling tuned for the system
+# on which you are compiling, or, if specified, tuned for the setting
+# of the +DA option.
#
# From the online "C/HP-UX Reference Manual":
-# -Aa
-# Enables strict ANSI C compliance.
-# -Ae
-# Enables ANSI C compliance, HP value-added features (as described
-# for +e option), and _HPUX_SOURCE name space macro. It is equivalent
-# to -Aa +e -D_HPUX_SOURCE.
-# +e
-# Enables the following HP value added features while compiling in
-# ANSI C mode: sized enum, long long, long pointers, compiler supplied
-# defaults for missing arguments to intrinsic calls, and $ in identifier
-# HP C extensions.
+# -Aa
+# Enables strict ANSI C compliance.
+# -Ae
+# Enables ANSI C compliance, HP value-added features (as described
+# for +e option), and _HPUX_SOURCE name space macro. It is equivalent
+# to -Aa +e -D_HPUX_SOURCE.
+# +e
+# Enables the following HP value added features while compiling in
+# ANSI C mode: sized enum, long long, long pointers, compiler supplied
+# defaults for missing arguments to intrinsic calls, and $ in identifier
+# HP C extensions.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = hpux
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = hpux
-QMAKE_COMPILER = hp_acc
+QMAKE_COMPILER = hp_acc
-QMAKE_CC = cc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -Ae +DA2.0 -w
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF =
-QMAKE_CFLAGS_RELEASE = -O +Oentrysched +Onolimit
-QMAKE_CFLAGS_DEBUG = -y -g
-QMAKE_CFLAGS_SHLIB = +Z
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC =
-QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE
+QMAKE_CC = cc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -Ae +DA2.0 -w
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF =
+QMAKE_CFLAGS_RELEASE = -O +Oentrysched +Onolimit
+QMAKE_CFLAGS_DEBUG = -y -g
+QMAKE_CFLAGS_SHLIB = +Z
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE
-QMAKE_CXX = aCC
-QMAKE_CXXFLAGS = +DA2.0 -w -D__STRICT_ANSI__ -D_HPUX_SOURCE
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = -g
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = aCC
+QMAKE_CXXFLAGS = +DA2.0 -w -D__STRICT_ANSI__ -D_HPUX_SOURCE
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = -g
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = /usr/include/X11R6
-QMAKE_LIBDIR_X11 = /usr/lib/X11R6
-QMAKE_INCDIR_OPENGL = /opt/graphics/OpenGL/include /usr/contrib/X11R6/include
-QMAKE_LIBDIR_OPENGL = /opt/graphics/OpenGL/lib /usr/contrib/X11R6/lib
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = /usr/include/X11R6
+QMAKE_LIBDIR_X11 = /usr/lib/X11R6
+QMAKE_INCDIR_OPENGL = /opt/graphics/OpenGL/include /usr/contrib/X11R6/include
+QMAKE_LIBDIR_OPENGL = /opt/graphics/OpenGL/lib /usr/contrib/X11R6/lib
-QMAKE_LINK = aCC
-QMAKE_LINK_SHLIB = aCC
-QMAKE_LFLAGS = +DA2.0 -Wl,+s
-QMAKE_LFLAGS_RELEASE = -O
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -b
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,+h,
-QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
-QMAKE_LFLAGS_RPATH = -Wl,+b,
-QMAKE_HPUX_SHLIB = 2
-QMAKE_EXTENSION_SHLIB = sl
+QMAKE_LINK = aCC
+QMAKE_LINK_SHLIB = aCC
+QMAKE_LFLAGS = +DA2.0 -Wl,+s
+QMAKE_LFLAGS_RELEASE = -O
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -b
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,+h,
+QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
+QMAKE_LFLAGS_RPATH = -Wl,+b,
+QMAKE_HPUX_SHLIB = 2
+QMAKE_EXTENSION_SHLIB = sl
-QMAKE_LIBS = -lm
-QMAKE_LIBS_DYNLOAD = -ldld
-QMAKE_LIBS_X11 = -lXext -lX11
+QMAKE_LIBS = -lm
+QMAKE_LIBS_DYNLOAD = -ldld
+QMAKE_LIBS_X11 = -lXext -lX11
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread
-QMAKE_LIBS_YACC = -ly
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS_YACC = -ly
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/hpux-acc/qmake.conf b/mkspecs/hpux-acc/qmake.conf
index c7cdab49e6..5d1427c1f3 100644
--- a/mkspecs/hpux-acc/qmake.conf
+++ b/mkspecs/hpux-acc/qmake.conf
@@ -5,90 +5,89 @@
# we also need to redefine _HPUX_SOURCE. See pthread(3t) for more details.
#
# From the "HP aC++ Online Programmer's Guide":
-# Using +DS to Specify Instruction Scheduling:
-# * By default, the compiler performs scheduling tuned for the system
-# on which you are compiling, or, if specified, tuned for the setting
-# of the +DA option.
+# Using +DS to Specify Instruction Scheduling:
+# * By default, the compiler performs scheduling tuned for the system
+# on which you are compiling, or, if specified, tuned for the setting
+# of the +DA option.
#
# From the online "C/HP-UX Reference Manual":
-# -Aa
-# Enables strict ANSI C compliance.
-# -Ae
-# Enables ANSI C compliance, HP value-added features (as described
-# for +e option), and _HPUX_SOURCE name space macro. It is equivalent
-# to -Aa +e -D_HPUX_SOURCE.
-# +e
-# Enables the following HP value added features while compiling in
-# ANSI C mode: sized enum, long long, long pointers, compiler supplied
-# defaults for missing arguments to intrinsic calls, and $ in identifier
-# HP C extensions.
+# -Aa
+# Enables strict ANSI C compliance.
+# -Ae
+# Enables ANSI C compliance, HP value-added features (as described
+# for +e option), and _HPUX_SOURCE name space macro. It is equivalent
+# to -Aa +e -D_HPUX_SOURCE.
+# +e
+# Enables the following HP value added features while compiling in
+# ANSI C mode: sized enum, long long, long pointers, compiler supplied
+# defaults for missing arguments to intrinsic calls, and $ in identifier
+# HP C extensions.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = hpux
-QMAKE_COMPILER_DEFINES += __hpux __HP_aCC
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = hpux
+QMAKE_COMPILER_DEFINES += __hpux __HP_aCC
-QMAKE_COMPILER = hp_acc
+QMAKE_COMPILER = hp_acc
-QMAKE_CC = cc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -Ae +DAportable -w
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = +O1
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = +Z
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC =
-QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE -mt
+QMAKE_CC = cc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -Ae +DAportable -w
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = +O1
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = +Z
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE -mt
-QMAKE_CXX = aCC
-QMAKE_CXXFLAGS = -AA +DAportable -w -D__STRICT_ANSI__ -D_HPUX_SOURCE
-QMAKE_CXXFLAGS_DEPS = +M
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = aCC
+QMAKE_CXXFLAGS = -AA +DAportable -w -D__STRICT_ANSI__ -D_HPUX_SOURCE
+QMAKE_CXXFLAGS_DEPS = +M
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -mt
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -mt
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = /usr/include/X11R6
-QMAKE_LIBDIR_X11 = /usr/lib/X11R6
-QMAKE_INCDIR_OPENGL = /opt/graphics/OpenGL/include /usr/contrib/X11R6/include
-QMAKE_LIBDIR_OPENGL = /opt/graphics/OpenGL/lib /usr/contrib/X11R6/lib
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = /usr/include/X11R6
+QMAKE_LIBDIR_X11 = /usr/lib/X11R6
+QMAKE_INCDIR_OPENGL = /opt/graphics/OpenGL/include /usr/contrib/X11R6/include
+QMAKE_LIBDIR_OPENGL = /opt/graphics/OpenGL/lib /usr/contrib/X11R6/lib
-QMAKE_LINK = aCC
-QMAKE_LINK_SHLIB = aCC
-QMAKE_LFLAGS = -AA +DAportable -Wl,+s
-QMAKE_LFLAGS_RELEASE = -O
-QMAKE_LFLAGS_DEBUG = -g
-QMAKE_LFLAGS_SHLIB = -b -Wl,-a,shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,+h,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
-QMAKE_LFLAGS_RPATH = -Wl,+b,
-QMAKE_HPUX_SHLIB = 1
-QMAKE_EXTENSION_SHLIB = sl
+QMAKE_LINK = aCC
+QMAKE_LINK_SHLIB = aCC
+QMAKE_LFLAGS = -AA +DAportable -Wl,+s
+QMAKE_LFLAGS_RELEASE = -O
+QMAKE_LFLAGS_DEBUG = -g
+QMAKE_LFLAGS_SHLIB = -b -Wl,-a,shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,+h,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
+QMAKE_LFLAGS_RPATH = -Wl,+b,
+QMAKE_HPUX_SHLIB = 1
+QMAKE_EXTENSION_SHLIB = sl
-QMAKE_LIBS = -lm
-QMAKE_LIBS_DYNLOAD = -ldld
-QMAKE_LIBS_X11 = -lXext -lX11
-QMAKE_LIBS_OPENGL = -lGL -lXt
-QMAKE_LIBS_OPENGL_QT = -lGL -lXt
-QMAKE_LIBS_THREAD = -lpthread
-QMAKE_LIBS_YACC = -ly
+QMAKE_LIBS = -lm
+QMAKE_LIBS_DYNLOAD = -ldld
+QMAKE_LIBS_X11 = -lXext -lX11
+QMAKE_LIBS_OPENGL = -lGL -lXt
+QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS_YACC = -ly
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/hpux-g++-64/qmake.conf b/mkspecs/hpux-g++-64/qmake.conf
index 49eb1a3c67..8d598d7388 100644
--- a/mkspecs/hpux-g++-64/qmake.conf
+++ b/mkspecs/hpux-g++-64/qmake.conf
@@ -5,73 +5,72 @@
# therefore we also need to redefine _HPUX_SOURCE.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = hpux
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = hpux
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -D_HPUX_SOURCE
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -D_HPUX_SOURCE
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L
-QMAKE_INCDIR =
-QMAKE_LIBDIR = /usr/lib/pa20_64
-QMAKE_INCDIR_X11 = /usr/include/X11R6
-QMAKE_LIBDIR_X11 = /usr/lib/X11R6/pa20_64
-QMAKE_INCDIR_OPENGL = /opt/Mesa/include /usr/contrib/X11R6/include
-QMAKE_LIBDIR_OPENGL = /opt/Mesa/lib/pa20_64 /usr/contrib/X11R6/lib/pa20_64
+QMAKE_INCDIR =
+QMAKE_LIBDIR = /usr/lib/pa20_64
+QMAKE_INCDIR_X11 = /usr/include/X11R6
+QMAKE_LIBDIR_X11 = /usr/lib/X11R6/pa20_64
+QMAKE_INCDIR_OPENGL = /opt/Mesa/include /usr/contrib/X11R6/include
+QMAKE_LIBDIR_OPENGL = /opt/Mesa/lib/pa20_64 /usr/contrib/X11R6/lib/pa20_64
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS = -Wl,+s -lpthread
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -fPIC -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,+h,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
-QMAKE_LFLAGS_RPATH = -Wl,+b,
-QMAKE_HPUX_SHLIB = 3
-QMAKE_EXTENSION_SHLIB = sl
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS = -Wl,+s -lpthread
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -fPIC -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,+h,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
+QMAKE_LFLAGS_RPATH = -Wl,+b,
+QMAKE_HPUX_SHLIB = 3
+QMAKE_EXTENSION_SHLIB = sl
-QMAKE_LIBS = -lm
-QMAKE_LIBS_DYNLOAD = -ldld
-QMAKE_LIBS_X11 = -lXext -lX11
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread
-QMAKE_LIBS_YACC = -ly
+QMAKE_LIBS = -lm
+QMAKE_LIBS_DYNLOAD = -ldld
+QMAKE_LIBS_X11 = -lXext -lX11
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS_YACC = -ly
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/hpux-g++/qmake.conf b/mkspecs/hpux-g++/qmake.conf
index eca1b32b38..2f02e8e904 100644
--- a/mkspecs/hpux-g++/qmake.conf
+++ b/mkspecs/hpux-g++/qmake.conf
@@ -5,74 +5,73 @@
# therefore we also need to redefine _HPUX_SOURCE.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = hpux
-CONFIG += plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = hpux
+CONFIG += plugin_no_soname
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -D_HPUX_SOURCE -DGLU_VERSION_1_2
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -D_HPUX_SOURCE -DGLU_VERSION_1_2
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 = /usr/lib/X11R6
-QMAKE_INCDIR_OPENGL = /opt/Mesa/include /usr/contrib/X11R6/include
-QMAKE_LIBDIR_OPENGL = /opt/Mesa/lib /usr/contrib/X11R6/lib
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 = /usr/lib/X11R6
+QMAKE_INCDIR_OPENGL = /opt/Mesa/include /usr/contrib/X11R6/include
+QMAKE_LIBDIR_OPENGL = /opt/Mesa/lib /usr/contrib/X11R6/lib
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS = -Wl,+s
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -fPIC -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,+h,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
-QMAKE_LFLAGS_RPATH = -Wl,+b,
-QMAKE_HPUX_SHLIB = 1
-QMAKE_EXTENSION_SHLIB = sl
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS = -Wl,+s
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -fPIC -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,+h,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
+QMAKE_LFLAGS_RPATH = -Wl,+b,
+QMAKE_HPUX_SHLIB = 1
+QMAKE_EXTENSION_SHLIB = sl
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldld
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread
-QMAKE_LIBS_YACC = -ly
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldld
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS_YACC = -ly
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/hpuxi-acc-32/qmake.conf b/mkspecs/hpuxi-acc-32/qmake.conf
index bd2a58634f..a469b4f34c 100644
--- a/mkspecs/hpuxi-acc-32/qmake.conf
+++ b/mkspecs/hpuxi-acc-32/qmake.conf
@@ -2,69 +2,68 @@
# qmake configuration for hpuxi-acc-32
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = hpux
-CONFIG += plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = hpux
+CONFIG += plugin_no_soname
-QMAKE_COMPILER = hp_acc
+QMAKE_COMPILER = hp_acc
-QMAKE_CC = cc
-QMAKE_LEX = lex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = +DSitanium -w
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = +O1
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = +Z
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC =
-QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE -D_REENTRANT -mt
+QMAKE_CC = cc
+QMAKE_LEX = lex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = +DSitanium -w
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = +O1
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = +Z
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE -D_REENTRANT -mt
-QMAKE_CXX = aCC
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -D__STRICT_ANSI__ -D_HPUX_SOURCE
-QMAKE_CXXFLAGS_DEPS = +M
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = aCC
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -D__STRICT_ANSI__ -D_HPUX_SOURCE
+QMAKE_CXXFLAGS_DEPS = +M
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_REENTRANT -mt
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_REENTRANT -mt
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = /usr/include/X11R6
-QMAKE_LIBDIR_X11 = /usr/lib/hpux32/X11R6
-QMAKE_INCDIR_OPENGL = /opt/graphics/OpenGL/include /usr/contrib/X11R6/include
-QMAKE_LIBDIR_OPENGL = /opt/graphics/OpenGL/lib/hpux32 /usr/contrib/X11R6/lib/hpux32
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = /usr/include/X11R6
+QMAKE_LIBDIR_X11 = /usr/lib/hpux32/X11R6
+QMAKE_INCDIR_OPENGL = /opt/graphics/OpenGL/include /usr/contrib/X11R6/include
+QMAKE_LIBDIR_OPENGL = /opt/graphics/OpenGL/lib/hpux32 /usr/contrib/X11R6/lib/hpux32
-QMAKE_LINK = aCC
-QMAKE_LINK_SHLIB = aCC
-QMAKE_LFLAGS = +DSitanium -Wl,+s
-QMAKE_LFLAGS_RELEASE = -O
-QMAKE_LFLAGS_DEBUG = -g
-QMAKE_LFLAGS_SHLIB = -b -Wl,-a,shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,+h,
-QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_RPATH =
+QMAKE_LINK = aCC
+QMAKE_LINK_SHLIB = aCC
+QMAKE_LFLAGS = +DSitanium -Wl,+s
+QMAKE_LFLAGS_RELEASE = -O
+QMAKE_LFLAGS_DEBUG = -g
+QMAKE_LFLAGS_SHLIB = -b -Wl,-a,shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,+h,
+QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_RPATH =
-QMAKE_LIBS = -lm
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11
-QMAKE_LIBS_OPENGL = -lGL -lXt
-QMAKE_LIBS_OPENGL_QT = -lGL -lXt
-QMAKE_LIBS_THREAD = -lpthread
-QMAKE_LIBS_YACC = -ly
+QMAKE_LIBS = -lm
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11
+QMAKE_LIBS_OPENGL = -lGL -lXt
+QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS_YACC = -ly
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/hpuxi-acc-64/qmake.conf b/mkspecs/hpuxi-acc-64/qmake.conf
index d7c7f7b23f..a3b0ad0849 100644
--- a/mkspecs/hpuxi-acc-64/qmake.conf
+++ b/mkspecs/hpuxi-acc-64/qmake.conf
@@ -4,110 +4,109 @@
# We define _POSIX_C_SOURCE to 199506L when using threads, therefore
# we also need to redefine _HPUX_SOURCE.
# From pthread(3t):
-# Some documentation will recommend the use of -D_REENTRANT for
-# compilation. While this also functions properly, it is considered
-# an obsolescent form.
+# Some documentation will recommend the use of -D_REENTRANT for
+# compilation. While this also functions properly, it is considered
+# an obsolescent form.
# See pthread(3t) for more details.
#
# From the "HP aC++ Online Programmer's Guide":
-# When +DA2.0W is specified:
-# * 64-bit SVR4 Executable and Linking Format (ELF) object files
-# are generated for PA-RISC 2.0.
-# * The preprocessor predefined macro, __LP64__ is defined.
-# * The correct path for 64-bit system and language libraries is
-# selected.
-# When +DD32 is specified:
-# * The size of an int, long, or pointer data type is 32-bits.
-# The size of an int data type is 32-bits. The size of a long or
-# pointer data type is 64-bits.
-# * This is the default, currently equivalent to +DA1.1 architecture.
-# When +DD64 is specified:
-# * The size of an int data type is 32-bits. The size of a long or
-# pointer data type is 64-bits.
-# * This is currently equivalent to +DA2.OW architecture.
-# * The preprocessor predefined macro, __LP64__ is defined.
-# Using +DS to Specify Instruction Scheduling:
-# * By default, the compiler performs scheduling tuned for the system
-# on which you are compiling, or, if specified, tuned for the setting
-# of the +DA option.
+# When +DA2.0W is specified:
+# * 64-bit SVR4 Executable and Linking Format (ELF) object files
+# are generated for PA-RISC 2.0.
+# * The preprocessor predefined macro, __LP64__ is defined.
+# * The correct path for 64-bit system and language libraries is
+# selected.
+# When +DD32 is specified:
+# * The size of an int, long, or pointer data type is 32-bits.
+# The size of an int data type is 32-bits. The size of a long or
+# pointer data type is 64-bits.
+# * This is the default, currently equivalent to +DA1.1 architecture.
+# When +DD64 is specified:
+# * The size of an int data type is 32-bits. The size of a long or
+# pointer data type is 64-bits.
+# * This is currently equivalent to +DA2.OW architecture.
+# * The preprocessor predefined macro, __LP64__ is defined.
+# Using +DS to Specify Instruction Scheduling:
+# * By default, the compiler performs scheduling tuned for the system
+# on which you are compiling, or, if specified, tuned for the setting
+# of the +DA option.
#
# From the online "C/HP-UX Reference Manual":
-# -Aa
-# Enables strict ANSI C compliance.
-# -Ae
-# Enables ANSI C compliance, HP value-added features (as described
-# for +e option), and _HPUX_SOURCE name space macro. It is equivalent
-# to -Aa +e -D_HPUX_SOURCE.
-# +e
-# Enables the following HP value added features while compiling in
-# ANSI C mode: sized enum, long long, long pointers, compiler supplied
-# defaults for missing arguments to intrinsic calls, and $ in identifier
-# HP C extensions.
+# -Aa
+# Enables strict ANSI C compliance.
+# -Ae
+# Enables ANSI C compliance, HP value-added features (as described
+# for +e option), and _HPUX_SOURCE name space macro. It is equivalent
+# to -Aa +e -D_HPUX_SOURCE.
+# +e
+# Enables the following HP value added features while compiling in
+# ANSI C mode: sized enum, long long, long pointers, compiler supplied
+# defaults for missing arguments to intrinsic calls, and $ in identifier
+# HP C extensions.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = hpux
-CONFIG += plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = hpux
+CONFIG += plugin_no_soname
-QMAKE_COMPILER = hp_acc
+QMAKE_COMPILER = hp_acc
-QMAKE_CC = cc
-QMAKE_LEX = lex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = +DD64 +DSitanium -w
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = +O1
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = +Z
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC =
-QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE -D_REENTRANT -mt
+QMAKE_CC = cc
+QMAKE_LEX = lex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = +DD64 +DSitanium -w
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = +O1
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLI = +Z
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE -D_REENTRANT -mt
-QMAKE_CXX = aCC
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -D__STRICT_ANSI__ -D_HPUX_SOURCE
-QMAKE_CXXFLAGS_DEPS = +M
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_REENTRANT -mt
+QMAKE_CXX = aCC
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -D__STRICT_ANSI__ -D_HPUX_SOURCE
+QMAKE_CXXFLAGS_DEPS = +M
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXXFLAGS_STATIC_LB = $$QMAKE_CFLAGS_STATIC_LIB
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_REENTRANT -mt
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = /usr/include/X11R6
-QMAKE_LIBDIR_X11 = /usr/lib/hpux64/X11R6
-QMAKE_INCDIR_OPENGL = /opt/graphics/OpenGL/include /usr/contrib/X11R6/include
-QMAKE_LIBDIR_OPENGL = /opt/graphics/OpenGL/lib/hpux64 /usr/contrib/X11R6/lib/hpux64
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = /usr/include/X11R6
+QMAKE_LIBDIR_X11 = /usr/lib/hpux64/X11R6
+QMAKE_INCDIR_OPENGL = /opt/graphics/OpenGL/include /usr/contrib/X11R6/include
+QMAKE_LIBDIR_OPENGL = /opt/graphics/OpenGL/lib/hpux64 /usr/contrib/X11R6/lib/hpux64
-QMAKE_LINK = aCC
-QMAKE_LINK_SHLIB = aCC
-QMAKE_LFLAGS = +DD64 +DSitanium -Wl,+s
-QMAKE_LFLAGS_RELEASE = -O
-QMAKE_LFLAGS_DEBUG = -g
-QMAKE_LFLAGS_SHLIB = -b -Wl,-a,shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,+h,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
-QMAKE_LFLAGS_RPATH =
+QMAKE_LINK = aCC
+QMAKE_LINK_SHLIB = aCC
+QMAKE_LFLAGS = +DD64 +DSitanium -Wl,+s
+QMAKE_LFLAGS_RELEASE = -O
+QMAKE_LFLAGS_DEBUG = -g
+QMAKE_LFLAGS_SHLIB = -b -Wl,-a,shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,+h,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
+QMAKE_LFLAGS_RPATH =
-QMAKE_LIBS = -lm
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11
-QMAKE_LIBS_OPENGL = -lGL -lXt
-QMAKE_LIBS_OPENGL_QT = -lGL -lXt
-QMAKE_LIBS_THREAD = -lpthread
-QMAKE_LIBS_YACC = -ly
+QMAKE_LIBS = -lm
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11
+QMAKE_LIBS_OPENGL = -lGL -lXt
+QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS_YACC = -ly
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/hpuxi-g++-64/qmake.conf b/mkspecs/hpuxi-g++-64/qmake.conf
index 5703b8499f..756d361bb9 100644
--- a/mkspecs/hpuxi-g++-64/qmake.conf
+++ b/mkspecs/hpuxi-g++-64/qmake.conf
@@ -4,77 +4,76 @@
# We define _POSIX_C_SOURCE to 199506L when using threads, therefore
# we also need to redefine _HPUX_SOURCE.
# From pthread(3t):
-# Some documentation will recommend the use of -D_REENTRANT for
-# compilation. While this also functions properly, it is considered
-# an obsolescent form.
+# Some documentation will recommend the use of -D_REENTRANT for
+# compilation. While this also functions properly, it is considered
+# an obsolescent form.
# See pthread(3t) for more details.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = hpux
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = hpux
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -mlp64
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -mlp64
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L -D_HPUX_SOURCE
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -D_HPUX_SOURCE
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -D_HPUX_SOURCE
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = -D_POSIX_C_SOURCE=199506L
-QMAKE_INCDIR =
-QMAKE_LIBDIR = /usr/lib/hpux64
-QMAKE_INCDIR_X11 = /usr/include/X11R6
-QMAKE_LIBDIR_X11 = /usr/lib/hpux64/X11R6
-QMAKE_INCDIR_OPENGL = /opt/graphics/OpenGL/include /usr/contrib/X11R6/include
-QMAKE_LIBDIR_OPENGL = /opt/graphics/OpenGL/lib/hpux64 /usr/contrib/X11R6/lib/hpux64
+QMAKE_INCDIR =
+QMAKE_LIBDIR = /usr/lib/hpux64
+QMAKE_INCDIR_X11 = /usr/include/X11R6
+QMAKE_LIBDIR_X11 = /usr/lib/hpux64/X11R6
+QMAKE_INCDIR_OPENGL = /opt/graphics/OpenGL/include /usr/contrib/X11R6/include
+QMAKE_LIBDIR_OPENGL = /opt/graphics/OpenGL/lib/hpux64 /usr/contrib/X11R6/lib/hpux64
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS = -mlp64 -Wl,+s
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -fPIC -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,+h,
-QMAKE_LFLAGS_THREAD = -lpthread
-QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
-QMAKE_LFLAGS_RPATH = -Wl,+b,
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS = -mlp64 -Wl,+s
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -fPIC -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,+h,
+QMAKE_LFLAGS_THREAD = -lpthread
+QMAKE_LFLAGS_NOUNDEF = -Wl,+noallowunsats
+QMAKE_LFLAGS_RPATH = -Wl,+b,
-QMAKE_LIBS = -lm
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread
-QMAKE_LIBS_YACC = -ly
+QMAKE_LIBS = -lm
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS_YACC = -ly
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/hurd-g++/qmake.conf b/mkspecs/hurd-g++/qmake.conf
index c6ca94bfcf..9a3e83f373 100644
--- a/mkspecs/hurd-g++/qmake.conf
+++ b/mkspecs/hurd-g++/qmake.conf
@@ -2,49 +2,48 @@
# qmake configuration for hurd-g++
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = hurd
-CONFIG += incremental gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = hurd
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
-QMAKE_CFLAGS_THREAD += -D_REENTRANT
-QMAKE_CXXFLAGS_THREAD += $$QMAKE_CFLAGS_THREAD
+QMAKE_CFLAGS_THREAD += -D_REENTRANT
+QMAKE_CXXFLAGS_THREAD += $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = /usr/X11R6/include
-QMAKE_LIBDIR_X11 = /usr/X11R6/lib
-QMAKE_INCDIR_OPENGL = /usr/X11R6/include
-QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = /usr/X11R6/include
+QMAKE_LIBDIR_X11 = /usr/X11R6/lib
+QMAKE_INCDIR_OPENGL = /usr/X11R6/include
+QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
QMAKE_INCDIR_OPENGL_ES1 = $$QMAKE_INCDIR_OPENGL
QMAKE_LIBDIR_OPENGL_ES1 = $$QMAKE_LIBDIR_OPENGL
QMAKE_INCDIR_OPENGL_ES2 = $$QMAKE_INCDIR_OPENGL
QMAKE_LIBDIR_OPENGL_ES2 = $$QMAKE_LIBDIR_OPENGL
-QMAKE_INCDIR_EGL =
-QMAKE_LIBDIR_EGL =
-QMAKE_INCDIR_OPENVG =
-QMAKE_LIBDIR_OPENVG =
-
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_NIS = -lnsl
-QMAKE_LIBS_EGL = -lEGL
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_OPENGL_ES1 = -lGLES_CM
-QMAKE_LIBS_OPENGL_ES2 = -lGLESv2
-QMAKE_LIBS_OPENVG = -lOpenVG
-QMAKE_LIBS_THREAD = -lpthread
-
-QMAKE_AR = ar cqs
-QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
-
-QMAKE_STRIP = strip
-QMAKE_STRIPFLAGS_LIB += --strip-unneeded
-QMAKE_INSTALL_FILE = install -m 644 -p
-QMAKE_INSTALL_PROGRAM = install -m 755 -p
+QMAKE_INCDIR_EGL =
+QMAKE_LIBDIR_EGL =
+QMAKE_INCDIR_OPENVG =
+QMAKE_LIBDIR_OPENVG =
+
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_NIS = -lnsl
+QMAKE_LIBS_EGL = -lEGL
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_OPENGL_ES1 = -lGLES_CM
+QMAKE_LIBS_OPENGL_ES2 = -lGLESv2
+QMAKE_LIBS_OPENVG = -lOpenVG
+QMAKE_LIBS_THREAD = -lpthread
+
+QMAKE_AR = ar cqs
+QMAKE_OBJCOPY = objcopy
+QMAKE_RANLIB =
+
+QMAKE_STRIP = strip
+QMAKE_STRIPFLAGS_LIB += --strip-unneeded
+QMAKE_INSTALL_FILE = install -m 644 -p
+QMAKE_INSTALL_PROGRAM = install -m 755 -p
include(../common/unix.conf)
include(../common/gcc-base-unix.conf)
@@ -52,4 +51,4 @@ include(../common/g++-unix.conf)
load(qt_config)
# This is tricky but needed
-QMAKE_LIBS += $$QMAKE_LIBS_THREAD
+QMAKE_LIBS += $$QMAKE_LIBS_THREAD
diff --git a/mkspecs/irix-cc-64/qmake.conf b/mkspecs/irix-cc-64/qmake.conf
index f31094a96b..33514486f9 100644
--- a/mkspecs/irix-cc-64/qmake.conf
+++ b/mkspecs/irix-cc-64/qmake.conf
@@ -2,106 +2,105 @@
# qmake configuration for irix-cc-64
#
# From cc(1):
-# -64
-# Generates a 64-bit object. This defaults to -mips4 if -mips3 has
-# not been specified.
-# -LANG: ...
-# The language feature option group controls the source language
-# interpretation assumed by the compiler. The individual controls
-# in this group are as follows:
-# ansi-for-init-scope [ = ( ON|OFF ) ]
-# Enables or disables the ANSI scoping rules for for-init
-# declarations (the scope of the name declared extends to
-# the end of the for statement). This enables the behavior
-# that is required by the C++ standard. The default value
-# is OFF, which is the ARM behavior (the scope of the name
-# declared extends to the end of the block enclosing the for
-# statement).
-# bool [ = ( ON|OFF ) ]
-# Enables or disables the predefined bool data type, along
-# with the predefined values true and false. Use this option
-# only to suppress this type in old code that defines bool
-# itself. Because this option changes the mangling of function
-# names with bool parameters, all files comprising a program
-# should be compiled with consistent options.
-# Default is ON.
-# The _BOOL feature macro can be used in #ifdefs to do conditional
-# compilation based on whether or not this option is enabled.
-# std
-# Enables use of the standard C++ library and standard-
-# conforming iostream library. Specifying this flag also
-# triggers other standard-conforming behavior, such as the
-# new rules for the scope of for loop initializers.
+# -64
+# Generates a 64-bit object. This defaults to -mips4 if -mips3 has
+# not been specified.
+# -LANG: ...
+# The language feature option group controls the source language
+# interpretation assumed by the compiler. The individual controls
+# in this group are as follows:
+# ansi-for-init-scope [ = ( ON|OFF ) ]
+# Enables or disables the ANSI scoping rules for for-init
+# declarations (the scope of the name declared extends to
+# the end of the for statement). This enables the behavior
+# that is required by the C++ standard. The default value
+# is OFF, which is the ARM behavior (the scope of the name
+# declared extends to the end of the block enclosing the for
+# statement).
+# bool [ = ( ON|OFF ) ]
+# Enables or disables the predefined bool data type, along
+# with the predefined values true and false. Use this option
+# only to suppress this type in old code that defines bool
+# itself. Because this option changes the mangling of function
+# names with bool parameters, all files comprising a program
+# should be compiled with consistent options.
+# Default is ON.
+# The _BOOL feature macro can be used in #ifdefs to do conditional
+# compilation based on whether or not this option is enabled.
+# std
+# Enables use of the standard C++ library and standard-
+# conforming iostream library. Specifying this flag also
+# triggers other standard-conforming behavior, such as the
+# new rules for the scope of for loop initializers.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = irix
-QMAKE_COMPILER_DEFINES += __sgi __EDG
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = irix
+QMAKE_COMPILER_DEFINES += __sgi __EDG
-QMAKE_COMPILER = sgi_cc
+QMAKE_COMPILER = sgi_cc
-QMAKE_CC = cc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -64 -signed -woff 1209,1355,1375,1424,3303
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -fullwarn
-QMAKE_CFLAGS_WARN_OFF =
-QMAKE_CFLAGS_RELEASE = -O2 -OPT:Olimit=3000
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB =
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -woff 1110,1174,3262
-QMAKE_CFLAGS_THREAD =
+QMAKE_CC = cc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -64 -signed -woff 1209,1355,1375,1424,3303
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -fullwarn
+QMAKE_CFLAGS_WARN_OFF =
+QMAKE_CFLAGS_RELEASE = -O2 -OPT:Olimit=3000
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB =
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -woff 1110,1174,3262
+QMAKE_CFLAGS_THREAD =
QMAKE_CFLAGS_EXCEPTIONS_OFF = -LANG:exceptions=off
-QMAKE_CXX = CC
-QMAKE_CXXFLAGS = -64 -signed -LANG:std:libc_in_namespace_std=ON -woff 1209,1355,1375,1424,3303
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = CC
+QMAKE_CXXFLAGS = -64 -signed -LANG:std:libc_in_namespace_std=ON -woff 1209,1355,1375,1424,3303
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD =
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD =
QMAKE_CXXFLAGS_EXCEPTIONS_OFF = $$QMAKE_CFLAGS_EXCEPTIONS_OFF
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = CC
-QMAKE_LINK_SHLIB = CC
-QMAKE_LFLAGS = -64
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG = -g
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,-soname,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_NOUNDEF = -Wl,-no_unresolved
-QMAKE_LFLAGS_RPATH = -Wl,-rpath,
+QMAKE_LINK = CC
+QMAKE_LINK_SHLIB = CC
+QMAKE_LFLAGS = -64
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG = -g
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,-soname,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_NOUNDEF = -Wl,-no_unresolved
+QMAKE_LFLAGS_RPATH = -Wl,-rpath,
QMAKE_LFLAGS_EXCEPTIONS_OFF = $$QMAKE_CFLAGS_EXCEPTIONS_OFF
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL -lm
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL -lm
+QMAKE_LIBS_THREAD = -lpthread
-QMAKE_AR = CC -ar -o
+QMAKE_AR = CC -ar -o
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
-QMAKE_CLEAN = -r $(OBJECTS_DIR)so_locations $(OBJECTS_DIR)ii_files
+QMAKE_CLEAN = -r $(OBJECTS_DIR)so_locations $(OBJECTS_DIR)ii_files
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/irix-cc/qmake.conf b/mkspecs/irix-cc/qmake.conf
index 6e832e01e6..8073cf4012 100644
--- a/mkspecs/irix-cc/qmake.conf
+++ b/mkspecs/irix-cc/qmake.conf
@@ -2,106 +2,105 @@
# qmake configuration for irix-cc
#
# From cc(1):
-# -n32
-# Generates a (new) 32-bit object. This defaults to -mips3 if
-# -mips4 has not been specified.
-# -LANG: ...
-# The language feature option group controls the source language
-# interpretation assumed by the compiler. The individual controls
-# in this group are as follows:
-# ansi-for-init-scope [ = ( ON|OFF ) ]
-# Enables or disables the ANSI scoping rules for for-init
-# declarations (the scope of the name declared extends to
-# the end of the for statement). This enables the behavior
-# that is required by the C++ standard. The default value
-# is OFF, which is the ARM behavior (the scope of the name
-# declared extends to the end of the block enclosing the for
-# statement).
-# bool [ = ( ON|OFF ) ]
-# Enables or disables the predefined bool data type, along
-# with the predefined values true and false. Use this option
-# only to suppress this type in old code that defines bool
-# itself. Because this option changes the mangling of function
-# names with bool parameters, all files comprising a program
-# should be compiled with consistent options.
-# Default is ON.
-# The _BOOL feature macro can be used in #ifdefs to do conditional
-# compilation based on whether or not this option is enabled.
-# std
-# Enables use of the standard C++ library and standard-
-# conforming iostream library. Specifying this flag also
-# triggers other standard-conforming behavior, such as the
-# new rules for the scope of for loop initializers.
+# -n32
+# Generates a (new) 32-bit object. This defaults to -mips3 if
+# -mips4 has not been specified.
+# -LANG: ...
+# The language feature option group controls the source language
+# interpretation assumed by the compiler. The individual controls
+# in this group are as follows:
+# ansi-for-init-scope [ = ( ON|OFF ) ]
+# Enables or disables the ANSI scoping rules for for-init
+# declarations (the scope of the name declared extends to
+# the end of the for statement). This enables the behavior
+# that is required by the C++ standard. The default value
+# is OFF, which is the ARM behavior (the scope of the name
+# declared extends to the end of the block enclosing the for
+# statement).
+# bool [ = ( ON|OFF ) ]
+# Enables or disables the predefined bool data type, along
+# with the predefined values true and false. Use this option
+# only to suppress this type in old code that defines bool
+# itself. Because this option changes the mangling of function
+# names with bool parameters, all files comprising a program
+# should be compiled with consistent options.
+# Default is ON.
+# The _BOOL feature macro can be used in #ifdefs to do conditional
+# compilation based on whether or not this option is enabled.
+# std
+# Enables use of the standard C++ library and standard-
+# conforming iostream library. Specifying this flag also
+# triggers other standard-conforming behavior, such as the
+# new rules for the scope of for loop initializers.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = irix
-QMAKE_COMPILER_DEFINES += __sgi __EDG
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = irix
+QMAKE_COMPILER_DEFINES += __sgi __EDG
-QMAKE_COMPILER = sgi_cc
+QMAKE_COMPILER = sgi_cc
-QMAKE_CC = cc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -n32 -signed -woff 1209,1355,1375,1424,3303
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -fullwarn
-QMAKE_CFLAGS_WARN_OFF =
-QMAKE_CFLAGS_RELEASE = -O2 -OPT:Olimit=3000
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB =
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -woff 1110,1174,3262
-QMAKE_CFLAGS_THREAD =
+QMAKE_CC = cc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -n32 -signed -woff 1209,1355,1375,1424,3303
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -fullwarn
+QMAKE_CFLAGS_WARN_OFF =
+QMAKE_CFLAGS_RELEASE = -O2 -OPT:Olimit=3000
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB =
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -woff 1110,1174,3262
+QMAKE_CFLAGS_THREAD =
QMAKE_CFLAGS_EXCEPTIONS_OFF = -LANG:exceptions=off
-QMAKE_CXX = CC
-QMAKE_CXXFLAGS = -n32 -signed -LANG:std:libc_in_namespace_std=ON -woff 1209,1355,1375,1424,3303
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = CC
+QMAKE_CXXFLAGS = -n32 -signed -LANG:std:libc_in_namespace_std=ON -woff 1209,1355,1375,1424,3303
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD =
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD =
QMAKE_CXXFLAGS_EXCEPTIONS_OFF = $$QMAKE_CFLAGS_EXCEPTIONS_OFF
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = CC
-QMAKE_LINK_SHLIB = CC
-QMAKE_LFLAGS = -n32
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG = -g
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,-soname,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_NOUNDEF = -Wl,-no_unresolved
-QMAKE_LFLAGS_RPATH = -Wl,-rpath,
+QMAKE_LINK = CC
+QMAKE_LINK_SHLIB = CC
+QMAKE_LFLAGS = -n32
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG = -g
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,-soname,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_NOUNDEF = -Wl,-no_unresolved
+QMAKE_LFLAGS_RPATH = -Wl,-rpath,
QMAKE_LFLAGS_EXCEPTIONS_OFF = $$QMAKE_CFLAGS_EXCEPTIONS_OFF
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL -lm
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL -lm
+QMAKE_LIBS_THREAD = -lpthread
-QMAKE_AR = CC -ar -o
+QMAKE_AR = CC -ar -o
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
-QMAKE_CLEAN = -r $(OBJECTS_DIR)so_locations $(OBJECTS_DIR)ii_files
+QMAKE_CLEAN = -r $(OBJECTS_DIR)so_locations $(OBJECTS_DIR)ii_files
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/irix-g++-64/qmake.conf b/mkspecs/irix-g++-64/qmake.conf
index 637f12874a..845ded9667 100644
--- a/mkspecs/irix-g++-64/qmake.conf
+++ b/mkspecs/irix-g++-64/qmake.conf
@@ -2,76 +2,75 @@
# qmake configuration for irix-g++-64
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = irix
-QMAKE_COMPILER_DEFINES += __sgi __GNUC__
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = irix
+QMAKE_COMPILER_DEFINES += __sgi __GNUC__
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -mabi=64
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD =
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -mabi=64
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD =
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD =
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD =
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS = -mabi=64
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared -Wl,-LD_LAYOUT:lgot_buffer=1000
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,-soname,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_NOUNDEF = -Wl,-no_unresolved
-QMAKE_LFLAGS_RPATH = -Wl,-rpath,
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS = -mabi=64
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared -Wl,-LD_LAYOUT:lgot_buffer=1000
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,-soname,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_NOUNDEF = -Wl,-no_unresolved
+QMAKE_LFLAGS_RPATH = -Wl,-rpath,
-QMAKE_LIBS = -lC
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS = -lC
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
# libGLU is using the SGI C++ library internally and this somehow clashes
# with the GNU C++ library (similar name mangling and symbol names?)
# so we add -lC so that the SGI C++ library is used first...
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread
-QMAKE_AR = ar cq
+QMAKE_AR = ar cq
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
-QMAKE_CLEAN = so_locations
+QMAKE_CLEAN = so_locations
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/irix-g++/qmake.conf b/mkspecs/irix-g++/qmake.conf
index 6b1dbbd1f0..af5f5fe91d 100644
--- a/mkspecs/irix-g++/qmake.conf
+++ b/mkspecs/irix-g++/qmake.conf
@@ -2,76 +2,75 @@
# qmake configuration for irix-g++
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = irix
-QMAKE_COMPILER_DEFINES += __sgi __GNUC__
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = irix
+QMAKE_COMPILER_DEFINES += __sgi __GNUC__
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD =
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD =
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD =
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD =
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared -Wl,-LD_LAYOUT:lgot_buffer=1000
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,-soname,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_NOUNDEF = -Wl,-no_unresolved
-QMAKE_LFLAGS_RPATH = -Wl,-rpath,
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared -Wl,-LD_LAYOUT:lgot_buffer=1000
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,-soname,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_NOUNDEF = -Wl,-no_unresolved
+QMAKE_LFLAGS_RPATH = -Wl,-rpath,
-QMAKE_LIBS = -lC
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS = -lC
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
# libGLU is using the SGI C++ library internally and this somehow clashes
# with the GNU C++ library (similar name mangling and symbol names?)
# so we add -lC so that the SGI C++ library is used first...
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread
-QMAKE_AR = ar cq
+QMAKE_AR = ar cq
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
-QMAKE_CLEAN = so_locations
+QMAKE_CLEAN = so_locations
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/linux-arm-gnueabi-g++/qmake.conf b/mkspecs/linux-arm-gnueabi-g++/qmake.conf
index 574faa7456..d402f00d4d 100644
--- a/mkspecs/linux-arm-gnueabi-g++/qmake.conf
+++ b/mkspecs/linux-arm-gnueabi-g++/qmake.conf
@@ -3,7 +3,7 @@
#
MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../common/linux.conf)
diff --git a/mkspecs/linux-cxx/qmake.conf b/mkspecs/linux-cxx/qmake.conf
index 6b3d158f68..1c7cafc6f2 100644
--- a/mkspecs/linux-cxx/qmake.conf
+++ b/mkspecs/linux-cxx/qmake.conf
@@ -4,63 +4,62 @@
# Written for Compaq C++ for GNU/Linux on Alpha
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = linux
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = linux
-QMAKE_COMPILER = compaq_cc
+QMAKE_COMPILER = compaq_cc
-QMAKE_CC = ccc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -w
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF =
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB =
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Olimit 1000
+QMAKE_CC = ccc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -w
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF =
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB =
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Olimit 1000
-QMAKE_CXX = cxx
-QMAKE_CXXFLAGS = -w
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = cxx
+QMAKE_CXXFLAGS = -w
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = cxx
-QMAKE_LINK_SHLIB = cxx
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,-soname,
+QMAKE_LINK = cxx
+QMAKE_LINK_SHLIB = cxx
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,-soname,
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_NIS = -lnsl
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_NIS = -lnsl
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
+QMAKE_LIBS_OPENGL = -lGL
-QMAKE_AR = ar cqs
-QMAKE_RANLIB =
+QMAKE_AR = ar cqs
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/linux-g++-32/qmake.conf b/mkspecs/linux-g++-32/qmake.conf
index ffbccec6d0..56dfe8c1b2 100644
--- a/mkspecs/linux-g++-32/qmake.conf
+++ b/mkspecs/linux-g++-32/qmake.conf
@@ -2,12 +2,12 @@
# qmake configuration for linux-g++
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
-QMAKE_CFLAGS = -m32
-QMAKE_LFLAGS = -m32
+QMAKE_CFLAGS = -m32
+QMAKE_LFLAGS = -m32
include(../common/linux.conf)
include(../common/gcc-base-unix.conf)
diff --git a/mkspecs/linux-g++-64/qmake.conf b/mkspecs/linux-g++-64/qmake.conf
index 9e9c37ac56..fc7672f19d 100644
--- a/mkspecs/linux-g++-64/qmake.conf
+++ b/mkspecs/linux-g++-64/qmake.conf
@@ -5,19 +5,19 @@
# like the AMD Opteron.
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
-QMAKE_CFLAGS = -m64
-QMAKE_LFLAGS = -m64
+QMAKE_CFLAGS = -m64
+QMAKE_LFLAGS = -m64
include(../common/linux.conf)
include(../common/gcc-base-unix.conf)
include(../common/g++-unix.conf)
-QMAKE_LIBDIR_X11 = /usr/X11R6/lib64
-QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib64
+QMAKE_LIBDIR_X11 = /usr/X11R6/lib64
+QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib64
load(qt_config)
diff --git a/mkspecs/linux-g++/qmake.conf b/mkspecs/linux-g++/qmake.conf
index 9c1e0d7ab1..0c9634adf8 100644
--- a/mkspecs/linux-g++/qmake.conf
+++ b/mkspecs/linux-g++/qmake.conf
@@ -2,8 +2,8 @@
# qmake configuration for linux-g++
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../common/linux.conf)
diff --git a/mkspecs/linux-icc-64/qmake.conf b/mkspecs/linux-icc-64/qmake.conf
index 79620267a5..003cb5097d 100644
--- a/mkspecs/linux-icc-64/qmake.conf
+++ b/mkspecs/linux-icc-64/qmake.conf
@@ -12,5 +12,5 @@ include(../linux-icc/qmake.conf)
# Change the all LIBDIR variables to use lib64 instead of lib
-QMAKE_LIBDIR_X11 = /usr/X11R6/lib64
-QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib64
+QMAKE_LIBDIR_X11 = /usr/X11R6/lib64
+QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib64
diff --git a/mkspecs/linux-icc/qmake.conf b/mkspecs/linux-icc/qmake.conf
index 540069499b..4c3bbb5183 100644
--- a/mkspecs/linux-icc/qmake.conf
+++ b/mkspecs/linux-icc/qmake.conf
@@ -2,87 +2,86 @@
# qmake configuration for linux-icc
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+CONFIG += gdb_dwarf_index
-QMAKE_COMPILER = gcc intel_icc # icc pretends to be gcc
+QMAKE_COMPILER = gcc intel_icc # icc pretends to be gcc
-QMAKE_CC = icc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -w1 -Wcheck -wd654,1572,411,873,1125,2259,2261
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2 -falign-functions=16 -ansi-alias -fstrict-aliasing
-QMAKE_CFLAGS_DEBUG = -O0 -g
-QMAKE_CFLAGS_SHLIB = -fPIC -fno-jump-tables
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC =
-QMAKE_CFLAGS_THREAD = -D_REENTRANT
+QMAKE_CC = icc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -w1 -Wcheck -wd654,1572,411,873,1125,2259,2261
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2 -falign-functions=16 -ansi-alias -fstrict-aliasing
+QMAKE_CFLAGS_DEBUG = -O0 -g
+QMAKE_CFLAGS_SHLIB = -fPIC -fno-jump-tables
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_THREAD = -D_REENTRANT
-QMAKE_CFLAGS_SSE2 += -xSSE2
-QMAKE_CFLAGS_SSE3 += -xSSE3
-QMAKE_CFLAGS_SSSE3 += -xSSSE3
-QMAKE_CFLAGS_SSE4_1 += -xSSE4.1
-QMAKE_CFLAGS_SSE4_2 += -xSSE4.2
-QMAKE_CFLAGS_AVX += -xAVX
-QMAKE_CFLAGS_AVX2 += -xCORE-AVX2
+QMAKE_CFLAGS_SSE2 += -xSSE2
+QMAKE_CFLAGS_SSE3 += -xSSE3
+QMAKE_CFLAGS_SSSE3 += -xSSSE3
+QMAKE_CFLAGS_SSE4_1 += -xSSE4.1
+QMAKE_CFLAGS_SSE4_2 += -xSSE4.2
+QMAKE_CFLAGS_AVX += -xAVX
+QMAKE_CFLAGS_AVX2 += -xCORE-AVX2
-QMAKE_CXX = icpc
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = icpc
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
QMAKE_CXXFLAGS_CXX11 = -std=c++0x
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = icpc
-QMAKE_LINK_SHLIB = icpc
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared -shared-intel
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,-soname,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_NOUNDEF = -Wl,-z,defs
-QMAKE_LFLAGS_RPATH = -Wl,-rpath,
+QMAKE_LINK = icpc
+QMAKE_LINK_SHLIB = icpc
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared -shared-intel
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,-soname,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_NOUNDEF = -Wl,-z,defs
+QMAKE_LFLAGS_RPATH = -Wl,-rpath,
QMAKE_LFLAGS_CXX11 =
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_NIS = -lnsl
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_NIS = -lnsl
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread
-QMAKE_AR = xiar cqs
+QMAKE_AR = xiar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
-QMAKE_CLEAN = -r $(OBJECTS_DIR)/ti_files
+QMAKE_CLEAN = -r $(OBJECTS_DIR)/ti_files
# pch support
CONFIG += icc_pch_style
-QMAKE_PCH_OUTPUT_EXT = .pchi
+QMAKE_PCH_OUTPUT_EXT = .pchi
QMAKE_CXXFLAGS_USE_PRECOMPILE = -pch-use ${QMAKE_PCH_OUTPUT} -include ${QMAKE_PCH_INPUT}
-QMAKE_CXXFLAGS_PRECOMPILE = -c -pch-create ${QMAKE_PCH_OUTPUT} -include ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_TEMP_OBJECT} ${QMAKE_PCH_TEMP_SOURCE}
+QMAKE_CXXFLAGS_PRECOMPILE = -c -pch-create ${QMAKE_PCH_OUTPUT} -include ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_TEMP_OBJECT} ${QMAKE_PCH_TEMP_SOURCE}
# -Bsymbolic-functions (ld) support
QMAKE_LFLAGS_BSYMBOLIC_FUNC = -Wl,-Bsymbolic-functions
diff --git a/mkspecs/linux-kcc/qmake.conf b/mkspecs/linux-kcc/qmake.conf
index cbe474fc09..921b4e6390 100644
--- a/mkspecs/linux-kcc/qmake.conf
+++ b/mkspecs/linux-kcc/qmake.conf
@@ -7,76 +7,75 @@
#
# From the KAI C++ man page for Linux:
# --[no_]thread_safe
-# [Waive or] Request thread-safe handling of system-allocated objects.
-# To guarantee thread safety, this option must be used when both
-# compiling and linking. Thread-safe C++ is not link-compatible with
-# (the default) non-thread-safe C++.
+# [Waive or] Request thread-safe handling of system-allocated objects.
+# To guarantee thread safety, this option must be used when both
+# compiling and linking. Thread-safe C++ is not link-compatible with
+# (the default) non-thread-safe C++.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = linux
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = linux
-QMAKE_COMPILER = kai_cc
+QMAKE_COMPILER = kai_cc
-QMAKE_CC = KCC
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = --c --display_error_number --backend -pipe
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = +K2
-QMAKE_CFLAGS_DEBUG = +K0
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = --diag_suppress 111,177
-QMAKE_CFLAGS_THREAD = --thread_safe
+QMAKE_CC = KCC
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = --c --display_error_number --backend -pipe
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = +K2
+QMAKE_CFLAGS_DEBUG = +K0
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = --diag_suppress 111,177
+QMAKE_CFLAGS_THREAD = --thread_safe
-QMAKE_CXX = KCC
-QMAKE_CXXFLAGS = --display_error_number --diag_suppress 611,1142 --backend -pipe
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = KCC
+QMAKE_CXXFLAGS = --display_error_number --diag_suppress 611,1142 --backend -pipe
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = KCC
-QMAKE_LINK_SHLIB = KCC
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB =
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = --soname$$LITERAL_WHITESPACE
-QMAKE_LFLAGS_THREAD = --thread_safe
-QMAKE_LFLAGS_RPATH = -rpath$$LITERAL_WHITESPACE
+QMAKE_LINK = KCC
+QMAKE_LINK_SHLIB = KCC
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB =
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = --soname$$LITERAL_WHITESPACE
+QMAKE_LFLAGS_THREAD = --thread_safe
+QMAKE_LFLAGS_RPATH = -rpath$$LITERAL_WHITESPACE
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_NIS = -lnsl
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD =
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_NIS = -lnsl
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD =
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
-QMAKE_CLEAN = -r $(OBJECTS_DIR)ti_files
+QMAKE_CLEAN = -r $(OBJECTS_DIR)ti_files
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/linux-llvm/qmake.conf b/mkspecs/linux-llvm/qmake.conf
index 3b7034d1b6..6a9fed64c2 100644
--- a/mkspecs/linux-llvm/qmake.conf
+++ b/mkspecs/linux-llvm/qmake.conf
@@ -2,8 +2,8 @@
# qmake configuration for llvm
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../common/linux.conf)
diff --git a/mkspecs/linux-lsb-g++/qmake.conf b/mkspecs/linux-lsb-g++/qmake.conf
index 72d6a920fb..10a4014d65 100644
--- a/mkspecs/linux-lsb-g++/qmake.conf
+++ b/mkspecs/linux-lsb-g++/qmake.conf
@@ -3,7 +3,7 @@
#
MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental gdb_dwarf_index
+CONFIG += incremental gdb_dwarf_index
QMAKE_INCREMENTAL_STYLE = sublib
include(../common/linux.conf)
@@ -15,7 +15,7 @@ QMAKE_LIBS_THREAD += -lrt
QMAKE_LSB = 1
QMAKE_CC = lsbcc
-QMAKE_CXX = lsbc++
+QMAKE_CXX = lsbc++
QMAKE_LINK_C = $$QMAKE_CC
QMAKE_LINK_C_SHLIB = $$QMAKE_CC
diff --git a/mkspecs/linux-pgcc/qmake.conf b/mkspecs/linux-pgcc/qmake.conf
index 93c3762f16..404c1de1e9 100644
--- a/mkspecs/linux-pgcc/qmake.conf
+++ b/mkspecs/linux-pgcc/qmake.conf
@@ -4,68 +4,67 @@
# Written for the Portland Group compiler 6.0-5
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = linux
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = linux
-QMAKE_COMPILER = portland_cc
+QMAKE_COMPILER = portland_cc
-QMAKE_CC = pgcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -fast
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fpic
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC =
-QMAKE_CFLAGS_THREAD = -D_REENTRANT
+QMAKE_CC = pgcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -fast
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fpic
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_THREAD = -D_REENTRANT
-QMAKE_CXX = pgCC
-QMAKE_CXXFLAGS = --display_error_number --diag_suppress815 $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = pgCC
+QMAKE_CXXFLAGS = --display_error_number --diag_suppress815 $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = pgCC
-QMAKE_LINK_SHLIB = pgCC
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared -fpic
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,-soname,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_RPATH = -R
+QMAKE_LINK = pgCC
+QMAKE_LINK_SHLIB = pgCC
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared -fpic
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,-soname,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_RPATH = -R
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_NIS = -lnsl
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_NIS = -lnsl
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/lynxos-g++/qmake.conf b/mkspecs/lynxos-g++/qmake.conf
index 9762b4d76c..ab887825d6 100644
--- a/mkspecs/lynxos-g++/qmake.conf
+++ b/mkspecs/lynxos-g++/qmake.conf
@@ -4,75 +4,74 @@
# Written for LynxOS 4.0
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = lynxos
-CONFIG += incremental
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = lynxos
+CONFIG += incremental
QMAKE_INCREMENTAL_STYLE = sublib
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -pipe
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD = -D_REENTRANT
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -pipe
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -D_REENTRANT
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = /usr/include/X11
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL = /usr/include/GL
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = /usr/include/X11
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL = /usr/include/GL
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,-soname,
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_RPATH = -Wl,-rpath,
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,-soname,
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_RPATH = -Wl,-rpath,
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_NIS = -lnsl
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_NIS = -lnsl
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
QMAKE_STRIP = strip
-QMAKE_STRIPFLAGS_LIB += --strip-unneeded
+QMAKE_STRIPFLAGS_LIB += --strip-unneeded
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/macx-clang-32/qmake.conf b/mkspecs/macx-clang-32/qmake.conf
index b6cceaff91..e0c4bd57b7 100644
--- a/mkspecs/macx-clang-32/qmake.conf
+++ b/mkspecs/macx-clang-32/qmake.conf
@@ -2,19 +2,20 @@
# qmake configuration for 32-bit Clang on OS X
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
QMAKE_INCREMENTAL_STYLE = sublib
-include(../common/mac.conf)
-include(../common/gcc-base-macx.conf)
+include(../common/macx.conf)
+include(../common/gcc-base-mac.conf)
include(../common/clang.conf)
include(../common/clang-mac.conf)
-include(../common/mac-minimum-version.conf)
-QMAKE_CFLAGS += -arch i386
+QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.6
+
+QMAKE_CFLAGS += -arch i386
QMAKE_OBJECTIVE_CFLAGS += -arch i386
-QMAKE_CXXFLAGS += -arch i386
-QMAKE_LFLAGS += -arch i386
+QMAKE_CXXFLAGS += -arch i386
+QMAKE_LFLAGS += -arch i386
load(qt_config)
diff --git a/mkspecs/macx-clang-libc++-32/qmake.conf b/mkspecs/macx-clang-libc++-32/qmake.conf
index 122205c13d..aea19a4bc3 100644
--- a/mkspecs/macx-clang-libc++-32/qmake.conf
+++ b/mkspecs/macx-clang-libc++-32/qmake.conf
@@ -2,19 +2,20 @@
# qmake configuration for 32-bit Clang on OS X
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
QMAKE_INCREMENTAL_STYLE = sublib
-include(../common/mac.conf)
-include(../common/gcc-base-macx.conf)
+include(../common/macx.conf)
+include(../common/gcc-base-mac.conf)
include(../common/clang.conf)
include(../common/clang-mac.conf)
-include(../common/mac-clang-libc++-minimum-version.conf)
-QMAKE_CFLAGS += -arch i386
+QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.7
+
+QMAKE_CFLAGS += -arch i386
QMAKE_OBJECTIVE_CFLAGS += -arch i386 -stdlib=libc++
-QMAKE_CXXFLAGS += -arch i386 -stdlib=libc++
-QMAKE_LFLAGS += -arch i386 -stdlib=libc++
+QMAKE_CXXFLAGS += -arch i386 -stdlib=libc++
+QMAKE_LFLAGS += -arch i386 -stdlib=libc++
load(qt_config)
diff --git a/mkspecs/macx-clang-libc++/qmake.conf b/mkspecs/macx-clang-libc++/qmake.conf
index 700959865e..94cc0036d2 100644
--- a/mkspecs/macx-clang-libc++/qmake.conf
+++ b/mkspecs/macx-clang-libc++/qmake.conf
@@ -2,18 +2,19 @@
# qmake configuration for Clang on OS X
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
QMAKE_INCREMENTAL_STYLE = sublib
-include(../common/mac.conf)
-include(../common/gcc-base-macx.conf)
+include(../common/macx.conf)
+include(../common/gcc-base-mac.conf)
include(../common/clang.conf)
include(../common/clang-mac.conf)
-include(../common/mac-clang-libc++-minimum-version.conf)
+
+QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.7
QMAKE_OBJECTIVE_CFLAGS += -stdlib=libc++
-QMAKE_CXXFLAGS += -stdlib=libc++
-QMAKE_LFLAGS += -stdlib=libc++
+QMAKE_CXXFLAGS += -stdlib=libc++
+QMAKE_LFLAGS += -stdlib=libc++
load(qt_config)
diff --git a/mkspecs/macx-clang/qmake.conf b/mkspecs/macx-clang/qmake.conf
index 64ce81cabe..f28b728bd9 100644
--- a/mkspecs/macx-clang/qmake.conf
+++ b/mkspecs/macx-clang/qmake.conf
@@ -2,14 +2,15 @@
# qmake configuration for Clang on OS X
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
QMAKE_INCREMENTAL_STYLE = sublib
-include(../common/mac.conf)
-include(../common/gcc-base-macx.conf)
+include(../common/macx.conf)
+include(../common/gcc-base-mac.conf)
include(../common/clang.conf)
include(../common/clang-mac.conf)
-include(../common/mac-minimum-version.conf)
+
+QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.6
load(qt_config)
diff --git a/mkspecs/macx-g++-32/qmake.conf b/mkspecs/macx-g++-32/qmake.conf
index 845c3874dc..bf8f68c680 100644
--- a/mkspecs/macx-g++-32/qmake.conf
+++ b/mkspecs/macx-g++-32/qmake.conf
@@ -6,18 +6,19 @@
# Mac OS X + command-line compiler
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
QMAKE_INCREMENTAL_STYLE = sublib
-include(../common/mac.conf)
-include(../common/gcc-base-macx.conf)
+include(../common/macx.conf)
+include(../common/gcc-base-mac.conf)
include(../common/g++-macx.conf)
-include(../common/mac-minimum-version.conf)
-QMAKE_CFLAGS += -arch i386
+QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.6
+
+QMAKE_CFLAGS += -arch i386
QMAKE_OBJECTIVE_CFLAGS += -arch i386
-QMAKE_CXXFLAGS += -arch i386
-QMAKE_LFLAGS += -arch i386
+QMAKE_CXXFLAGS += -arch i386
+QMAKE_LFLAGS += -arch i386
load(qt_config)
diff --git a/mkspecs/macx-g++/qmake.conf b/mkspecs/macx-g++/qmake.conf
index 32da734e87..96d9f6e487 100644
--- a/mkspecs/macx-g++/qmake.conf
+++ b/mkspecs/macx-g++/qmake.conf
@@ -6,13 +6,14 @@
# Mac OS X + command-line compiler
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
QMAKE_INCREMENTAL_STYLE = sublib
-include(../common/mac.conf)
-include(../common/gcc-base-macx.conf)
+include(../common/macx.conf)
+include(../common/gcc-base-mac.conf)
include(../common/g++-macx.conf)
-include(../common/mac-minimum-version.conf)
+
+QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.6
load(qt_config)
diff --git a/mkspecs/macx-g++40/qmake.conf b/mkspecs/macx-g++40/qmake.conf
index 7f581ae58d..fe7683e02d 100644
--- a/mkspecs/macx-g++40/qmake.conf
+++ b/mkspecs/macx-g++40/qmake.conf
@@ -6,21 +6,22 @@
# Mac OS X + command-line compiler
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
QMAKE_INCREMENTAL_STYLE = sublib
-include(../common/mac.conf)
-include(../common/gcc-base-macx.conf)
+include(../common/macx.conf)
+include(../common/gcc-base-mac.conf)
include(../common/g++-macx.conf)
-include(../common/mac-minimum-version.conf)
-QMAKE_CC = gcc-4.0
-QMAKE_CXX = g++-4.0
+QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.6
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-QMAKE_LINK_C = $$QMAKE_CC
-QMAKE_LINK_C_SHLIB = $$QMAKE_CC
+QMAKE_CC = gcc-4.0
+QMAKE_CXX = g++-4.0
+
+QMAKE_LINK = $$QMAKE_CXX
+QMAKE_LINK_SHLIB = $$QMAKE_CXX
+QMAKE_LINK_C = $$QMAKE_CC
+QMAKE_LINK_C_SHLIB = $$QMAKE_CC
load(qt_config)
diff --git a/mkspecs/macx-g++42/qmake.conf b/mkspecs/macx-g++42/qmake.conf
index d4803da3cc..9041d8ba05 100644
--- a/mkspecs/macx-g++42/qmake.conf
+++ b/mkspecs/macx-g++42/qmake.conf
@@ -6,21 +6,22 @@
# Mac OS X + command-line compiler
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
QMAKE_INCREMENTAL_STYLE = sublib
-include(../common/mac.conf)
-include(../common/gcc-base-macx.conf)
+include(../common/macx.conf)
+include(../common/gcc-base-mac.conf)
include(../common/g++-macx.conf)
-include(../common/mac-minimum-version.conf)
-QMAKE_CC = gcc-4.2
-QMAKE_CXX = g++-4.2
+QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.6
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-QMAKE_LINK_C = $$QMAKE_CC
-QMAKE_LINK_C_SHLIB = $$QMAKE_CC
+QMAKE_CC = gcc-4.2
+QMAKE_CXX = g++-4.2
+
+QMAKE_LINK = $$QMAKE_CXX
+QMAKE_LINK_SHLIB = $$QMAKE_CXX
+QMAKE_LINK_C = $$QMAKE_CC
+QMAKE_LINK_C_SHLIB = $$QMAKE_CC
load(qt_config)
diff --git a/mkspecs/macx-icc/qmake.conf b/mkspecs/macx-icc/qmake.conf
index 1aa252a0ed..2522d5c382 100644
--- a/mkspecs/macx-icc/qmake.conf
+++ b/mkspecs/macx-icc/qmake.conf
@@ -12,62 +12,62 @@
# warning #1569: potential redeclared typedef
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += app_bundle
+MAKEFILE_GENERATOR = UNIX
+CONFIG += app_bundle
QMAKE_INCREMENTAL_STYLE = sublibs
-QMAKE_COMPILER_DEFINES += __APPLE__ __GNUC__
+QMAKE_COMPILER_DEFINES += __APPLE__ __GNUC__
-QMAKE_COMPILER = gcc intel_icc # icc pretends to be gcc
+QMAKE_COMPILER = gcc intel_icc # icc pretends to be gcc
-QMAKE_CC = icc
-QMAKE_CFLAGS = -wd858,1572,1569,279
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE =
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fpic
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD =
+QMAKE_CC = icc
+QMAKE_CFLAGS = -wd858,1572,1569,279
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE =
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fpic
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD =
QMAKE_OBJECTIVE_CC = gcc
-QMAKE_OBJECTIVE_CFLAGS = -pipe
-QMAKE_OBJECTIVE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_OBJECTIVE_CFLAGS_WARN_OFF = -w
-QMAKE_OBJECTIVE_CFLAGS_RELEASE = -Os
-QMAKE_OBJECTIVE_CFLAGS_DEBUG = -g
-QMAKE_OBJECTIVE_CFLAGS_HIDESYMS = -fvisibility=hidden
+QMAKE_OBJECTIVE_CFLAGS = -pipe
+QMAKE_OBJECTIVE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_OBJECTIVE_CFLAGS_WARN_OFF = -w
+QMAKE_OBJECTIVE_CFLAGS_RELEASE = -Os
+QMAKE_OBJECTIVE_CFLAGS_DEBUG = -g
+QMAKE_OBJECTIVE_CFLAGS_HIDESYMS = -fvisibility=hidden
-QMAKE_CXX = icpc
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = icpc
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_LINK = icpc
-QMAKE_LINK_SHLIB = icpc
-QMAKE_LFLAGS = -headerpad_max_install_names
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -single_module -dynamiclib
+QMAKE_LINK = icpc
+QMAKE_LINK_SHLIB = icpc
+QMAKE_LFLAGS = -headerpad_max_install_names
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -ingle_module -dynamiclib
QMAKE_LFLAGS_INCREMENTAL = -undefined suppress -flat_namespace
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -install_name$${LITERAL_WHITESPACE}
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_RPATH =
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -install_name$${LITERAL_WHITESPACE}
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_RPATH =
QMAKE_LFLAGS_VERSION = -current_version$${LITERAL_WHITESPACE}
QMAKE_LFLAGS_COMPAT_VERSION = -compatibility_version$${LITERAL_WHITESPACE}
-QMAKE_CLEAN = -r $(OBJECTS_DIR)/ti_files
+QMAKE_CLEAN = -r $(OBJECTS_DIR)/ti_files
-include(../common/mac.conf)
+include(../common/macx.conf)
load(qt_config)
diff --git a/mkspecs/macx-llvm/qmake.conf b/mkspecs/macx-llvm/qmake.conf
index d43eefe002..7e6ee1c9de 100644
--- a/mkspecs/macx-llvm/qmake.conf
+++ b/mkspecs/macx-llvm/qmake.conf
@@ -6,14 +6,17 @@
# Mac OS X + command-line compiler
#
-MAKEFILE_GENERATOR = UNIX
-CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+CONFIG += app_bundle incremental global_init_link_order lib_version_first plugin_no_soname
QMAKE_INCREMENTAL_STYLE = sublib
-include(../common/mac.conf)
-include(../common/gcc-base-macx.conf)
+include(../common/macx.conf)
+include(../common/gcc-base-mac.conf)
include(../common/llvm.conf)
-include(../common/mac-minimum-version.conf)
+
+QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.6
+
+QMAKE_XCODE_GCC_VERSION = com.apple.compilers.llvmgcc42
QMAKE_OBJCFLAGS_PRECOMPILE = -x objective-c-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_OBJCFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
diff --git a/mkspecs/macx-xcode/qmake.conf b/mkspecs/macx-xcode/qmake.conf
index 8504310c79..131619de32 100644
--- a/mkspecs/macx-xcode/qmake.conf
+++ b/mkspecs/macx-xcode/qmake.conf
@@ -4,22 +4,23 @@
# Mac OS X + XCode
#
-MAKEFILE_GENERATOR = XCODE
-CONFIG += lib_version_first incremental plugin_no_soname app_bundle
+MAKEFILE_GENERATOR = XCODE
+CONFIG += lib_version_first incremental plugin_no_soname app_bundle
-include(../common/mac.conf)
-include(../common/gcc-base-macx.conf)
+include(../common/macx.conf)
+include(../common/gcc-base-mac.conf)
include(../common/g++-macx.conf)
-include(../common/mac-minimum-version.conf)
+
+QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.6
QMAKE_LINK =
QMAKE_LINK_C =
QMAKE_LINK_C_SHLIB =
QMAKE_LINK_SHLIB =
-QMAKE_CFLAGS_HIDESYMS =
+QMAKE_CFLAGS_HIDESYMS =
QMAKE_LFLAGS_VERSION =
QMAKE_LFLAGS_COMPAT_VERSION =
QMAKE_LFLAGS_SONAME =
-QMAKE_INCDIR += /usr/local/include /System/Library/Frameworks/CarbonCore.framework/Headers
+QMAKE_INCDIR += /usr/local/include /System/Library/Frameworks/CarbonCore.framework/Headers
load(qt_config)
diff --git a/mkspecs/netbsd-g++/qmake.conf b/mkspecs/netbsd-g++/qmake.conf
index 5e6dd8f13c..ee36b3ac5d 100644
--- a/mkspecs/netbsd-g++/qmake.conf
+++ b/mkspecs/netbsd-g++/qmake.conf
@@ -2,72 +2,71 @@
# qmake configuration for netbsd-g++
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = netbsd bsd
-CONFIG += gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = netbsd bsd
+CONFIG += gdb_dwarf_index
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -pipe
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD = -pthread
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -pipe
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -pthread
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR = /usr/local/include
-QMAKE_LIBDIR = /usr/local/lib
-QMAKE_INCDIR_X11 = /usr/X11R6/include
-QMAKE_LIBDIR_X11 = /usr/X11R6/lib
-QMAKE_INCDIR_OPENGL = /usr/X11R6/include
-QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
+QMAKE_INCDIR = /usr/local/include
+QMAKE_LIBDIR = /usr/local/lib
+QMAKE_INCDIR_X11 = /usr/X11R6/include
+QMAKE_LIBDIR_X11 = /usr/X11R6/lib
+QMAKE_INCDIR_OPENGL = /usr/X11R6/include
+QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
QMAKE_LINK_SHLIB_CMD = $$QMAKE_LINK_SHLIB $$QMAKE_LFLAGS_SHLIB $(LFLAGS) $$QMAKE_LFLAGS -o $(TARGETD) $(OBJECTS) $(OBJMOC) $(LIBS)
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,-soname,
-QMAKE_LFLAGS_THREAD = -pthread
-QMAKE_LFLAGS_NOUNDEF = -Wl,-no_unresolved
-QMAKE_LFLAGS_RPATH = -Wl,-rpath,
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,-soname,
+QMAKE_LFLAGS_THREAD = -pthread
+QMAKE_LFLAGS_NOUNDEF = -Wl,-no_unresolved
+QMAKE_LFLAGS_RPATH = -Wl,-rpath,
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD =
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD =
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB = ranlib
+QMAKE_RANLIB = ranlib
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/openbsd-g++/qmake.conf b/mkspecs/openbsd-g++/qmake.conf
index 8dc53a620b..f7b19cfe48 100644
--- a/mkspecs/openbsd-g++/qmake.conf
+++ b/mkspecs/openbsd-g++/qmake.conf
@@ -2,73 +2,72 @@
# qmake configuration for openbsd-g++
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = openbsd bsd
-CONFIG += gdb_dwarf_index
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = openbsd bsd
+CONFIG += gdb_dwarf_index
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -pipe
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD = -pthread
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -pipe
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -pthread
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR = /usr/local/include
-QMAKE_LIBDIR = /usr/local/lib
-QMAKE_INCDIR_X11 = /usr/X11R6/include
-QMAKE_LIBDIR_X11 = /usr/X11R6/lib
-QMAKE_INCDIR_OPENGL = /usr/X11R6/include
-QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
+QMAKE_INCDIR = /usr/local/include
+QMAKE_LIBDIR = /usr/local/lib
+QMAKE_INCDIR_X11 = /usr/X11R6/include
+QMAKE_LIBDIR_X11 = /usr/X11R6/lib
+QMAKE_INCDIR_OPENGL = /usr/X11R6/include
+QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LINK_SHLIB_CMD = $$QMAKE_LINK_SHLIB $(LFLAGS) \
- $$QMAKE_CFLAGS_SHLIB $$QMAKE_LFLAGS \
- -o $(TARGETD) $(OBJECTS) $(OBJMOC) $(LIBS)
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -Wl,-soname,
-QMAKE_LFLAGS_THREAD = -pthread
-QMAKE_LFLAGS_NOUNDEF = -Wl,-no_unresolved
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LINK_SHLIB_CMD = $$QMAKE_LINK_SHLIB $(LFLAGS) \
+ $$QMAKE_CFLAGS_SHLIB $$QMAKE_LFLAGS \
+ -o $(TARGETD) $(OBJECTS) $(OBJMOC) $(LIBS)
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -Wl,-soname,
+QMAKE_LFLAGS_THREAD = -pthread
+QMAKE_LFLAGS_NOUNDEF = -Wl,-no_unresolved
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD =
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD =
-QMAKE_AR = ar q
+QMAKE_AR = ar q
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB = ranlib
+QMAKE_RANLIB = ranlib
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/sco-cc/qmake.conf b/mkspecs/sco-cc/qmake.conf
index ccd3aaa290..a1ebc5d033 100644
--- a/mkspecs/sco-cc/qmake.conf
+++ b/mkspecs/sco-cc/qmake.conf
@@ -4,64 +4,63 @@
# Written for SCO OpenServer with UDK
#
# -Wf,--diag_suppress,838
-# turns off warning about missing return types in X headers
+# turns off warning about missing return types in X headers
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = sco
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = sco
-QMAKE_COMPILER = sco_cc
+QMAKE_COMPILER = sco_cc
-QMAKE_CC = cc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -KPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wf,--diag_suppress,111 -Wf,--diag_suppress,177
+QMAKE_CC = cc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -KPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wf,--diag_suppress,111 -Wf,--diag_suppress,177
-QMAKE_CXX = CC
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -Wf,--display_error_number -Wf,--diag_suppress,838
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE -Tused
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = CC
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -Wf,--display_error_number -Wf,--diag_suppress,838
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE -Tused
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 = /usr/X/lib
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 = /usr/X/lib
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = CC
-QMAKE_LINK_SHLIB = CC
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -G
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
+QMAKE_LINK = CC
+QMAKE_LINK_SHLIB = CC
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -G
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl -lm
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl -lm
-QMAKE_LIBS_OPENGL = -lGL -lXt
-QMAKE_LIBS_OPENGL_QT = -lGL
+QMAKE_LIBS_OPENGL = -lGL -lXt
-QMAKE_AR = ar cq
+QMAKE_AR = ar cq
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/sco-g++/qmake.conf b/mkspecs/sco-g++/qmake.conf
index 68d655ad4b..38ea4f65b7 100644
--- a/mkspecs/sco-g++/qmake.conf
+++ b/mkspecs/sco-g++/qmake.conf
@@ -4,66 +4,65 @@
# Written for SCO OpenServer 5.0.6 with Skunkware's compiler
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = sco
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = sco
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -G
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
-QMAKE_LFLAGS_RPATH =
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -G
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
+QMAKE_LFLAGS_RPATH =
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lsocket -lm
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lsocket -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
+QMAKE_LIBS_OPENGL = -lGL
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/solaris-cc-64-stlport/qmake.conf b/mkspecs/solaris-cc-64-stlport/qmake.conf
index 3437b8fd22..355b8a3515 100644
--- a/mkspecs/solaris-cc-64-stlport/qmake.conf
+++ b/mkspecs/solaris-cc-64-stlport/qmake.conf
@@ -4,5 +4,5 @@
include(../solaris-cc-64/qmake.conf)
-QMAKE_CXXFLAGS += -library=stlport4
-QMAKE_LFLAGS += -library=stlport4
+QMAKE_CXXFLAGS += -library=stlport4
+QMAKE_LFLAGS += -library=stlport4
diff --git a/mkspecs/solaris-cc-64/qmake.conf b/mkspecs/solaris-cc-64/qmake.conf
index f88a71687c..fc761420d3 100644
--- a/mkspecs/solaris-cc-64/qmake.conf
+++ b/mkspecs/solaris-cc-64/qmake.conf
@@ -4,91 +4,90 @@
# Written for Forte Developer 6 and Sun ONE Studio 7 and 8
#
# From the standards(5) manual page:
-# The XNS4 specification is safe for use only in ILP32 (32-bit)
-# environments and should not be used for LP64 (64-bit)
-# application environments. Use XNS5, which has LP64-clean
-# interfaces that are portable across ILP32 and LP64 environments.
-# [...]
-# For platforms supporting the LP64 (64-bit) programming environment
-# where the SC5.0 Compilers have been installed, SUSv2-conforming LP64
-# applications using XNS5 library calls should be built with command
-# lines of the form:
-# c89 $(getconf XBS5_LP64_OFF64_CFLAGS) -D_XOPEN_SOURCE=500 \
-# $(getconf XBS5_LP64_OFF64_LDFLAGS) foo.c -o foo \
-# $(getconf XBS5_LP64_OFF64_LIBS) -lxnet
+# The XNS4 specification is safe for use only in ILP32 (32-bit)
+# environments and should not be used for LP64 (64-bit)
+# application environments. Use XNS5, which has LP64-clean
+# interfaces that are portable across ILP32 and LP64 environments.
+# [...]
+# For platforms supporting the LP64 (64-bit) programming environment
+# where the SC5.0 Compilers have been installed, SUSv2-conforming LP64
+# applications using XNS5 library calls should be built with command
+# lines of the form:
+# c89 $(getconf XBS5_LP64_OFF64_CFLAGS) -D_XOPEN_SOURCE=500 \
+# $(getconf XBS5_LP64_OFF64_LDFLAGS) foo.c -o foo \
+# $(getconf XBS5_LP64_OFF64_LIBS) -lxnet
# So it appears that _XOPEN_SOURCE=500 should be defined when building
# 64-bit applications (on Solaris 7 and better). But then __EXTENSIONS__
# should be defined as well to recover all the default system interface.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = solaris
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = solaris
-QMAKE_COMPILER = sun_cc
+QMAKE_COMPILER = sun_cc
-QMAKE_CC = cc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -xarch=generic64
-QMAKE_CFLAGS_DEPS = -xM
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -KPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC =
-QMAKE_CFLAGS_THREAD = -mt
+QMAKE_CC = cc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -xarch=generic64
+QMAKE_CFLAGS_DEPS = -xM
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -KPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_THREAD = -mt
QMAKE_CFLAGS_HIDESYMS = -xldscope=hidden
-QMAKE_CXX = CC
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = -O
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = CC
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = -O
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
QMAKE_CXXFLAGS_HIDESYMS = $$QMAKE_CFLAGS_HIDESYMS
-QMAKE_INCDIR = /usr/sfw/include
-QMAKE_LIBDIR = /usr/sfw/lib/64
-QMAKE_INCDIR_X11 = /usr/openwin/include
-QMAKE_LIBDIR_X11 = /usr/openwin/lib/64
-QMAKE_INCDIR_OPENGL = /usr/openwin/include
-QMAKE_LIBDIR_OPENGL = /usr/openwin/lib/64
+QMAKE_INCDIR = /usr/sfw/include
+QMAKE_LIBDIR = /usr/sfw/lib/64
+QMAKE_INCDIR_X11 = /usr/openwin/include
+QMAKE_LIBDIR_X11 = /usr/openwin/lib/64
+QMAKE_INCDIR_OPENGL = /usr/openwin/include
+QMAKE_LIBDIR_OPENGL = /usr/openwin/lib/64
-QMAKE_LINK = CC
-QMAKE_LINK_SHLIB = CC
-QMAKE_LFLAGS = -xarch=generic64
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -G
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
-QMAKE_LFLAGS_THREAD = -mt
-QMAKE_LFLAGS_NOUNDEF = -z defs
-QMAKE_LFLAGS_RPATH = -R
+QMAKE_LINK = CC
+QMAKE_LINK_SHLIB = CC
+QMAKE_LFLAGS = -xarch=generic64
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -G
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
+QMAKE_LFLAGS_THREAD = -mt
+QMAKE_LFLAGS_NOUNDEF = -z defs
+QMAKE_LFLAGS_RPATH = -R
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl
-QMAKE_LIBS_NIS =
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread -lrt
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl
+QMAKE_LIBS_NIS =
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread -lrt
QMAKE_LIBS_NETWORK = -lresolv -lsocket -lxnet -lnsl
-QMAKE_AR = CC -xar -o
+QMAKE_AR = CC -xar -o
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
-QMAKE_CLEAN = -r $(OBJECTS_DIR)Templates.DB $(OBJECTS_DIR)SunWS_cache
+QMAKE_CLEAN = -r $(OBJECTS_DIR)Templates.DB $(OBJECTS_DIR)SunWS_cache
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/solaris-cc-stlport/qmake.conf b/mkspecs/solaris-cc-stlport/qmake.conf
index b0df45e949..449b1c571f 100644
--- a/mkspecs/solaris-cc-stlport/qmake.conf
+++ b/mkspecs/solaris-cc-stlport/qmake.conf
@@ -4,5 +4,5 @@
include(../solaris-cc/qmake.conf)
-QMAKE_CXXFLAGS += -library=stlport4
-QMAKE_LFLAGS += -library=stlport4
+QMAKE_CXXFLAGS += -library=stlport4
+QMAKE_LFLAGS += -library=stlport4
diff --git a/mkspecs/solaris-cc/qmake.conf b/mkspecs/solaris-cc/qmake.conf
index 83d3918a77..29fbec38c0 100644
--- a/mkspecs/solaris-cc/qmake.conf
+++ b/mkspecs/solaris-cc/qmake.conf
@@ -4,74 +4,73 @@
# Written for Forte Developer 6 and Sun ONE Studio 7 and 8
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = solaris
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = solaris
-QMAKE_COMPILER = sun_cc
+QMAKE_COMPILER = sun_cc
-QMAKE_CC = cc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_DEPS = -xM
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -KPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC =
-QMAKE_CFLAGS_THREAD = -mt
+QMAKE_CC = cc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_DEPS = -xM
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -KPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_THREAD = -mt
QMAKE_CFLAGS_HIDESYMS = -xldscope=hidden
-QMAKE_CXX = CC
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = -O2
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = CC
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = -O2
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
QMAKE_CXXFLAGS_HIDESYMS = $$QMAKE_CFLAGS_HIDESYMS
-QMAKE_INCDIR = /usr/sfw/include
-QMAKE_LIBDIR = /usr/sfw/lib
-QMAKE_INCDIR_X11 = /usr/openwin/include
-QMAKE_LIBDIR_X11 = /usr/openwin/lib
-QMAKE_INCDIR_OPENGL = /usr/openwin/include
-QMAKE_LIBDIR_OPENGL = /usr/openwin/lib
+QMAKE_INCDIR = /usr/sfw/include
+QMAKE_LIBDIR = /usr/sfw/lib
+QMAKE_INCDIR_X11 = /usr/openwin/include
+QMAKE_LIBDIR_X11 = /usr/openwin/lib
+QMAKE_INCDIR_OPENGL = /usr/openwin/include
+QMAKE_LIBDIR_OPENGL = /usr/openwin/lib
-QMAKE_LINK = CC
-QMAKE_LINK_SHLIB = CC
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -G
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
-QMAKE_LFLAGS_THREAD = -mt
-QMAKE_LFLAGS_NOUNDEF = -z defs
-QMAKE_LFLAGS_RPATH = -R
+QMAKE_LINK = CC
+QMAKE_LINK_SHLIB = CC
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -G
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
+QMAKE_LFLAGS_THREAD = -mt
+QMAKE_LFLAGS_NOUNDEF = -z defs
+QMAKE_LFLAGS_RPATH = -R
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl
-QMAKE_LIBS_NIS =
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread -lrt
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl
+QMAKE_LIBS_NIS =
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread -lrt
QMAKE_LIBS_NETWORK = -lresolv -lsocket -lxnet -lnsl
-QMAKE_AR = CC -xar -o
+QMAKE_AR = CC -xar -o
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
-QMAKE_CLEAN = -r $(OBJECTS_DIR)Templates.DB $(OBJECTS_DIR)SunWS_cache
+QMAKE_CLEAN = -r $(OBJECTS_DIR)Templates.DB $(OBJECTS_DIR)SunWS_cache
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/solaris-g++-64/qmake.conf b/mkspecs/solaris-g++-64/qmake.conf
index 96044a1c8c..e0c2f2de9c 100644
--- a/mkspecs/solaris-g++-64/qmake.conf
+++ b/mkspecs/solaris-g++-64/qmake.conf
@@ -8,89 +8,88 @@
# because we don't use -isystem.
#
# From the standards(5) manual page:
-# The XNS4 specification is safe for use only in ILP32 (32-bit)
-# environments and should not be used for LP64 (64-bit)
-# application environments. Use XNS5, which has LP64-clean
-# interfaces that are portable across ILP32 and LP64 environments.
-# [...]
-# For platforms supporting the LP64 (64-bit) programming environment
-# where the SC5.0 Compilers have been installed, SUSv2-conforming LP64
-# applications using XNS5 library calls should be built with command
-# lines of the form:
-# c89 $(getconf XBS5_LP64_OFF64_CFLAGS) -D_XOPEN_SOURCE=500 \
-# $(getconf XBS5_LP64_OFF64_LDFLAGS) foo.c -o foo \
-# $(getconf XBS5_LP64_OFF64_LIBS) -lxnet
+# The XNS4 specification is safe for use only in ILP32 (32-bit)
+# environments and should not be used for LP64 (64-bit)
+# application environments. Use XNS5, which has LP64-clean
+# interfaces that are portable across ILP32 and LP64 environments.
+# [...]
+# For platforms supporting the LP64 (64-bit) programming environment
+# where the SC5.0 Compilers have been installed, SUSv2-conforming LP64
+# applications using XNS5 library calls should be built with command
+# lines of the form:
+# c89 $(getconf XBS5_LP64_OFF64_CFLAGS) -D_XOPEN_SOURCE=500 \
+# $(getconf XBS5_LP64_OFF64_LDFLAGS) foo.c -o foo \
+# $(getconf XBS5_LP64_OFF64_LIBS) -lxnet
# So it appears that _XOPEN_SOURCE=500 should be defined when building
# 64-bit applications (on Solaris 7 and better). But then __EXTENSIONS__
# should be defined as well to recover all the default system interface.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = solaris
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = solaris
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -m64 -D_XOPEN_SOURCE=500 -D__EXTENSIONS__
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD = -D_REENTRANT
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -m64 -D_XOPEN_SOURCE=500 -D__EXTENSIONS__
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -D_REENTRANT
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR = /usr/sfw/include
-QMAKE_LIBDIR = /usr/sfw/lib/64
-QMAKE_INCDIR_X11 = /usr/openwin/include
-QMAKE_LIBDIR_X11 = /usr/openwin/lib/64
-QMAKE_INCDIR_OPENGL = /usr/openwin/include
-QMAKE_LIBDIR_OPENGL = /usr/openwin/lib/64
+QMAKE_INCDIR = /usr/sfw/include
+QMAKE_LIBDIR = /usr/sfw/lib/64
+QMAKE_INCDIR_X11 = /usr/openwin/include
+QMAKE_LIBDIR_X11 = /usr/openwin/lib/64
+QMAKE_INCDIR_OPENGL = /usr/openwin/include
+QMAKE_LIBDIR_OPENGL = /usr/openwin/lib/64
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS = -m64
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG = -g
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_NOUNDEF = -z defs
-QMAKE_LFLAGS_RPATH = -Wl,-R,
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS = -m64
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG = -g
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_NOUNDEF = -z defs
+QMAKE_LFLAGS_RPATH = -Wl,-R,
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl
-QMAKE_LIBS_NIS =
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread -lrt
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl
+QMAKE_LIBS_NIS =
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread -lrt
QMAKE_LIBS_NETWORK = -lresolv -lsocket -lxnet -lnsl
-QMAKE_AR = ar cq
+QMAKE_AR = ar cq
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/solaris-g++/qmake.conf b/mkspecs/solaris-g++/qmake.conf
index ff2c01ca2c..9f714ea2d1 100644
--- a/mkspecs/solaris-g++/qmake.conf
+++ b/mkspecs/solaris-g++/qmake.conf
@@ -8,72 +8,71 @@
# because we don't use -isystem.
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = solaris
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = solaris
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD = -D_REENTRANT
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -D_REENTRANT
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR = /usr/sfw/include
-QMAKE_LIBDIR = /usr/sfw/lib
-QMAKE_INCDIR_X11 = /usr/openwin/include
-QMAKE_LIBDIR_X11 = /usr/openwin/lib
-QMAKE_INCDIR_OPENGL = /usr/openwin/include
-QMAKE_LIBDIR_OPENGL = /usr/openwin/lib
+QMAKE_INCDIR = /usr/sfw/include
+QMAKE_LIBDIR = /usr/sfw/lib
+QMAKE_INCDIR_X11 = /usr/openwin/include
+QMAKE_LIBDIR_X11 = /usr/openwin/lib
+QMAKE_INCDIR_OPENGL = /usr/openwin/include
+QMAKE_LIBDIR_OPENGL = /usr/openwin/lib
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG = -g
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_NOUNDEF = -z defs
-QMAKE_LFLAGS_RPATH = -Wl,-R,
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG = -g
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_NOUNDEF = -z defs
+QMAKE_LFLAGS_RPATH = -Wl,-R,
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl
-QMAKE_LIBS_NIS =
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread -lrt
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl
+QMAKE_LIBS_NIS =
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread -lrt
QMAKE_LIBS_NETWORK = -lresolv -lsocket -lxnet -lnsl
-QMAKE_AR = ar cq
+QMAKE_AR = ar cq
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/tru64-cxx/qmake.conf b/mkspecs/tru64-cxx/qmake.conf
index 34285d6f08..04cbe59b13 100644
--- a/mkspecs/tru64-cxx/qmake.conf
+++ b/mkspecs/tru64-cxx/qmake.conf
@@ -2,68 +2,67 @@
# qmake configuration for tru64-cxx
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = tru64
-CONFIG += plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = tru64
+CONFIG += plugin_no_soname
-QMAKE_COMPILER = dec_cc
+QMAKE_COMPILER = dec_cc
-QMAKE_CC = cc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF =
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB =
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Olimit 1000
-QMAKE_CFLAGS_THREAD = -pthread
+QMAKE_CC = cc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF =
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB =
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Olimit 1000
+QMAKE_CFLAGS_THREAD = -pthread
-QMAKE_CXX = cxx
-QMAKE_CXXFLAGS = -x cxx -model ansi $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = cxx
+QMAKE_CXXFLAGS = -x cxx -model ansi $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = cxx
-QMAKE_LINK_SHLIB = cxx
-QMAKE_LFLAGS = -model ansi
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_THREAD = -pthread
-QMAKE_LFLAGS_SONAME = -soname$$LITERAL_WHITESPACE
-QMAKE_LFLAGS_RPATH = -rpath$$LITERAL_WHITESPACE
+QMAKE_LINK = cxx
+QMAKE_LINK_SHLIB = cxx
+QMAKE_LFLAGS = -model ansi
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_THREAD = -pthread
+QMAKE_LFLAGS_SONAME = -soname$$LITERAL_WHITESPACE
+QMAKE_LFLAGS_RPATH = -rpath$$LITERAL_WHITESPACE
-QMAKE_LIBS = -lm
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lrt
+QMAKE_LIBS = -lm
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lrt
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/tru64-g++/qmake.conf b/mkspecs/tru64-g++/qmake.conf
index 7e2c748b45..a3f08220f6 100644
--- a/mkspecs/tru64-g++/qmake.conf
+++ b/mkspecs/tru64-g++/qmake.conf
@@ -2,70 +2,69 @@
# qmake configuration for tru64-g++
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = tru64
-CONFIG += plugin_no_soname
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = tru64
+CONFIG += plugin_no_soname
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD = -D_REENTRANT
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD = -D_REENTRANT
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_SONAME = -Wl,-soname,
-QMAKE_LFLAGS_RPATH = -Wl,-rpath,
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_SONAME = -Wl,-soname,
+QMAKE_LFLAGS_RPATH = -Wl,-rpath,
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lpthread -lexc -lrt
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD = -lpthread -lexc -lrt
-QMAKE_AR = ar cqs
+QMAKE_AR = ar cqs
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/unixware-cc/qmake.conf b/mkspecs/unixware-cc/qmake.conf
index 21940089d9..68018213c9 100644
--- a/mkspecs/unixware-cc/qmake.conf
+++ b/mkspecs/unixware-cc/qmake.conf
@@ -4,70 +4,69 @@
# Written for UnixWare 7 with UDK or OUDK
#
# -Wf,--diag_suppress,838
-# turns off warning about missing return types in X headers
+# turns off warning about missing return types in X headers
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = unixware
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = unixware
-QMAKE_COMPILER = sco_cc
+QMAKE_COMPILER = sco_cc
-QMAKE_CC = cc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -KPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wf,--diag_suppress,111 -Wf,--diag_suppress,177
-QMAKE_CFLAGS_THREAD = -Kthread
+QMAKE_CC = cc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -KPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wf,--diag_suppress,111 -Wf,--diag_suppress,177
+QMAKE_CFLAGS_THREAD = -Kthread
-QMAKE_CXX = CC
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -Wf,--display_error_number -Wf,--diag_suppress,838
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE -Tused
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = CC
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -Wf,--display_error_number -Wf,--diag_suppress,838
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE -Tused
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 = /usr/X/lib
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 = /usr/X/lib
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = CC
-QMAKE_LINK_SHLIB = CC
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -G
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
-QMAKE_LFLAGS_THREAD = -Kthread
-QMAKE_LFLAGS_RPATH = -R
+QMAKE_LINK = CC
+QMAKE_LINK_SHLIB = CC
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -G
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME = -h$$LITERAL_WHITESPACE
+QMAKE_LFLAGS_THREAD = -Kthread
+QMAKE_LFLAGS_RPATH = -R
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl -lm
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl -lm
-QMAKE_LIBS_OPENGL = -lGL -lXt
-QMAKE_LIBS_OPENGL_QT = -lGL
+QMAKE_LIBS_OPENGL = -lGL -lXt
-QMAKE_LIBS_THREAD =
+QMAKE_LIBS_THREAD =
-QMAKE_AR = ar cq
+QMAKE_AR = ar cq
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/unixware-g++/qmake.conf b/mkspecs/unixware-g++/qmake.conf
index a55f570f81..28f4314386 100644
--- a/mkspecs/unixware-g++/qmake.conf
+++ b/mkspecs/unixware-g++/qmake.conf
@@ -4,69 +4,68 @@
# Written for UnixWare 7 with OSTK
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = unixware
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = unixware
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = yacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS =
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -W
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_SHLIB = -fPIC
-QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_THREAD =
+QMAKE_CC = gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = yacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS =
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -W
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_SHLIB = -fPIC
+QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_THREAD =
-QMAKE_CXX = g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 = /usr/X/lib
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 = /usr/X/lib
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
-QMAKE_LINK = g++
-QMAKE_LINK_SHLIB = g++
-QMAKE_LINK_C = gcc
-QMAKE_LINK_C_SHLIB = gcc
-QMAKE_LFLAGS =
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_SHLIB = -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME =
-QMAKE_LFLAGS_THREAD =
-QMAKE_LFLAGS_RPATH = -Wl,-R,
+QMAKE_LINK = g++
+QMAKE_LINK_SHLIB = g++
+QMAKE_LINK_C = gcc
+QMAKE_LINK_C_SHLIB = gcc
+QMAKE_LFLAGS =
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_SHLIB = -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME =
+QMAKE_LFLAGS_THREAD =
+QMAKE_LFLAGS_RPATH = -Wl,-R,
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl -lm
-QMAKE_LIBS_OPENGL = -lGL -lXt
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD = -lthread
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lresolv -lsocket -lnsl -lm
+QMAKE_LIBS_OPENGL = -lGL -lXt
+QMAKE_LIBS_THREAD = -lthread
-QMAKE_AR = ar cq
+QMAKE_AR = ar cq
QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_RANLIB =
include(../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/unsupported/android-g++/qeglfshooks_surfaceflinger.cpp b/mkspecs/unsupported/android-g++/qeglfshooks_surfaceflinger.cpp
index 2329bf1eb0..78a1eb183e 100644
--- a/mkspecs/unsupported/android-g++/qeglfshooks_surfaceflinger.cpp
+++ b/mkspecs/unsupported/android-g++/qeglfshooks_surfaceflinger.cpp
@@ -43,12 +43,17 @@
#include <ui/DisplayInfo.h>
#include <ui/FramebufferNativeWindow.h>
-#include <gui/SurfaceComposerClient.h>
#include <fcntl.h>
#include <unistd.h>
#include <linux/fb.h>
#include <sys/ioctl.h>
+#if Q_ANDROID_VERSION_MAJOR > 4 || (Q_ANDROID_VERSION_MAJOR == 4 && Q_ANDROID_VERSION_MINOR >= 1)
+#include <gui/SurfaceComposerClient.h>
+#else
+#include <surfaceflinger/SurfaceComposerClient.h>
+#endif
+
using namespace android;
QT_BEGIN_NAMESPACE
@@ -56,17 +61,61 @@ QT_BEGIN_NAMESPACE
class QEglFSPandaHooks : public QEglFSHooks
{
public:
+ QEglFSPandaHooks();
virtual EGLNativeWindowType createNativeWindow(const QSize &size, const QSurfaceFormat &format);
- virtual QSize screenSize() const;
- virtual int screenDepth() const;
+ virtual bool filterConfig(EGLDisplay display, EGLConfig config) const;
+ virtual const char *fbDeviceName() const { return "/dev/graphics/fb0"; }
+
private:
+ EGLNativeWindowType createNativeWindowSurfaceFlinger(const QSize &size, const QSurfaceFormat &format);
+ EGLNativeWindowType createNativeWindowFramebuffer(const QSize &size, const QSurfaceFormat &format);
+
+ void ensureFramebufferNativeWindowCreated();
+
// androidy things
sp<android::SurfaceComposerClient> mSession;
sp<android::SurfaceControl> mControl;
sp<android::Surface> mAndroidSurface;
+
+ sp<android::FramebufferNativeWindow> mFramebufferNativeWindow;
+ EGLint mFramebufferVisualId;
+
+ bool mUseFramebuffer;
};
-EGLNativeWindowType QEglFSPandaHooks::createNativeWindow(const QSize &size, const QSurfaceFormat &)
+QEglFSPandaHooks::QEglFSPandaHooks()
+ : mFramebufferVisualId(EGL_DONT_CARE)
+{
+ mUseFramebuffer = qgetenv("QT_QPA_EGLFS_NO_SURFACEFLINGER").toInt();
+}
+
+void QEglFSPandaHooks::ensureFramebufferNativeWindowCreated()
+{
+ if (mFramebufferNativeWindow.get())
+ return;
+ mFramebufferNativeWindow = new FramebufferNativeWindow();
+ framebuffer_device_t const *fbDev = mFramebufferNativeWindow->getDevice();
+ if (!fbDev)
+ qFatal("Failed to get valid FramebufferNativeWindow, no way to create EGL surfaces");
+
+ ANativeWindow *window = mFramebufferNativeWindow.get();
+
+ window->query(window, NATIVE_WINDOW_FORMAT, &mFramebufferVisualId);
+}
+
+EGLNativeWindowType QEglFSPandaHooks::createNativeWindow(const QSize &size, const QSurfaceFormat &format)
+{
+ return mUseFramebuffer ? createNativeWindowFramebuffer(size, format) : createNativeWindowSurfaceFlinger(size, format);
+}
+
+EGLNativeWindowType QEglFSPandaHooks::createNativeWindowFramebuffer(const QSize &size, const QSurfaceFormat &)
+{
+ Q_UNUSED(size);
+ ensureFramebufferNativeWindowCreated();
+ return mFramebufferNativeWindow.get();
+}
+
+EGLNativeWindowType QEglFSPandaHooks::createNativeWindowSurfaceFlinger(const QSize &size, const QSurfaceFormat &)
{
Q_UNUSED(size);
@@ -85,66 +134,21 @@ EGLNativeWindowType QEglFSPandaHooks::createNativeWindow(const QSize &size, cons
EGLNativeWindowType eglWindow = mAndroidSurface.get();
return eglWindow;
}
-QSize QEglFSPandaHooks::screenSize() const
-{
- static QSize size;
-
- if (size.isEmpty()) {
- int width = qgetenv("QT_QPA_EGLFS_WIDTH").toInt();
- int height = qgetenv("QT_QPA_EGLFS_HEIGHT").toInt();
-
- if (width && height) {
- // no need to read fb0
- size.setWidth(width);
- size.setHeight(height);
- return size;
- }
-
- struct fb_var_screeninfo vinfo;
- int fd = open("/dev/graphics/fb0", O_RDONLY);
-
- if (fd != -1) {
- if (ioctl(fd, FBIOGET_VSCREENINFO, &vinfo) == -1)
- qWarning("Could not query variable screen info.");
- else
- size = QSize(vinfo.xres, vinfo.yres);
-
- close(fd);
- } else {
- qWarning("Failed to open /dev/graphics/fb0 to detect screen resolution.");
- }
-
- // override fb0 from environment var setting
- if (width)
- size.setWidth(width);
- if (height)
- size.setHeight(height);
- }
-
- return size;
-}
-int QEglFSPandaHooks::screenDepth() const
+bool QEglFSPandaHooks::filterConfig(EGLDisplay display, EGLConfig config) const
{
- static int depth = qgetenv("QT_QPA_EGLFS_DEPTH").toInt();
+ if (!mUseFramebuffer)
+ return true;
- if (depth == 0) {
- struct fb_var_screeninfo vinfo;
- int fd = open("/dev/graphics/fb0", O_RDONLY);
+ const_cast<QEglFSPandaHooks *>(this)->ensureFramebufferNativeWindowCreated();
- if (fd != -1) {
- if (ioctl(fd, FBIOGET_VSCREENINFO, &vinfo) == -1)
- qWarning("Could not query variable screen info.");
- else
- depth = vinfo.bits_per_pixel;
+ if (mFramebufferVisualId == EGL_DONT_CARE)
+ return true;
- close(fd);
- } else {
- qWarning("Failed to open /dev/graphics/fb0 to detect screen depth.");
- }
- }
+ EGLint nativeVisualId = 0;
+ eglGetConfigAttrib(display, config, EGL_NATIVE_VISUAL_ID, &nativeVisualId);
- return depth == 0 ? 32 : depth;
+ return nativeVisualId == mFramebufferVisualId;
}
static QEglFSPandaHooks eglFSPandaHooks;
diff --git a/mkspecs/unsupported/android-g++/qmake.conf b/mkspecs/unsupported/android-g++/qmake.conf
index 8e0af9268d..71b843af7e 100644
--- a/mkspecs/unsupported/android-g++/qmake.conf
+++ b/mkspecs/unsupported/android-g++/qmake.conf
@@ -18,11 +18,13 @@ defineReplace(getAndroidBuildVar) {
store_ANDROID_TARGET_CFLAGS = "ANDROID_TARGET_CFLAGS=$$getAndroidBuildVar(TARGET_GLOBAL_CFLAGS)"
store_ANDROID_TARGET_LDFLAGS = "ANDROID_TARGET_LDFLAGS=$$getAndroidBuildVar(TARGET_GLOBAL_LDFLAGS)"
store_ANDROID_TARGET_ARCH = "ANDROID_TARGET_ARCH=$$getAndroidBuildVar(TARGET_ARCH)"
+ store_ANDROID_VERSION = "ANDROID_VERSION=$$getAndroidBuildVar(PLATFORM_VERSION)"
write_file(android_build_vars, store_ANDROID_TOOLCHAIN_PREFIX)
write_file(android_build_vars, store_ANDROID_TARGET_CFLAGS, append)
write_file(android_build_vars, store_ANDROID_TARGET_LDFLAGS, append)
write_file(android_build_vars, store_ANDROID_TARGET_ARCH, append)
+ write_file(android_build_vars, store_ANDROID_VERSION, append)
}
info(using android build env from cache in $$PWD/android_build_vars . delete this file if you changed your build env )
@@ -30,6 +32,9 @@ exists($$PWD/android_build_vars) {
include($$PWD/android_build_vars)
}
+ANDROID_VERSION_SPLIT = $$split(ANDROID_VERSION, ".")
+ANDROID_VERSION_MAJOR = $$member(ANDROID_VERSION_SPLIT, 0)
+ANDROID_VERSION_MINOR = $$member(ANDROID_VERSION_SPLIT, 1)
MAKEFILE_GENERATOR = UNIX
QMAKE_COMPILER = gcc
@@ -42,7 +47,9 @@ include(../../common/gcc-base-unix.conf)
CONFIG = qt warn_on release link_prl
QT = core gui
-DEFINES += Q_OS_LINUX_ANDROID HAVE_ANDROID_OS
+DEFINES += HAVE_ANDROID_OS Q_OS_ANDROID_NO_SDK
+DEFINES += Q_ANDROID_VERSION_MAJOR=$$ANDROID_VERSION_MAJOR
+DEFINES += Q_ANDROID_VERSION_MINOR=$$ANDROID_VERSION_MINOR
DEFINES += QT_NO_PRINTER QT_NO_PRINTDIALOG QT_NO_EXCEPTIONS
#note: -DANDROID results in weird behaviour of math.h
@@ -50,7 +57,7 @@ DEFINES += ANDROID
QT_QPA_DEFAULT_PLATFORM = eglfs
EGLFS_PLATFORM_HOOKS_SOURCES = $$PWD/qeglfshooks_surfaceflinger.cpp
-EGLFS_PLATFORM_HOOKS_LIBS += -lgui -lutils
+EGLFS_PLATFORM_HOOKS_LIBS += -lui -lgui -lutils -lcutils
QMAKE_CC = $${ANDROID_TOOLCHAIN_PREFIX}gcc
@@ -128,26 +135,26 @@ QMAKE_INCDIR_OPENGL_ES2 =
QMAKE_LIBDIR_OPENGL_ES2 =
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-QMAKE_LFLAGS = $${ANDROID_TARGET_LDFLAGS} \
- -nostdlib \
- -L${ANDROID_PRODUCT_OUT}/obj/lib \
- -Wl,-rpath-link,${ANDROID_PRODUCT_OUT}/obj/lib
+QMAKE_LINK = $$QMAKE_CXX
+QMAKE_LINK_SHLIB = $$QMAKE_CXX
+QMAKE_LFLAGS = $${ANDROID_TARGET_LDFLAGS} \
+ -nostdlib \
+ -L${ANDROID_PRODUCT_OUT}/obj/lib \
+ -Wl,-rpath-link,${ANDROID_PRODUCT_OUT}/obj/lib
-QMAKE_LFLAGS_PLUGIN = -Wl,-T,${ANDROID_BUILD_TOP}/build/core/armelf.xsc \
- -Wl,-shared,-Bsymbolic
+QMAKE_LFLAGS_PLUGIN = -Wl,-T,${ANDROID_BUILD_TOP}/build/core/armelf.xsc \
+ -Wl,-shared,-Bsymbolic
#apparantly this file is missing from some builds.
#it does work without, but this may change in future.
#QMAKE_LFLAGS_APP = -Wl,-T,${ANDROID_BUILD_TOP}/build/core/armelf.xs \
-QMAKE_LFLAGS_APP = ${ANDROID_PRODUCT_OUT}/obj/lib/crtbegin_dynamic.o \
- ${ANDROID_PRODUCT_OUT}/obj/lib/crtend_android.o
+QMAKE_LFLAGS_APP = ${ANDROID_PRODUCT_OUT}/obj/lib/crtbegin_dynamic.o \
+ ${ANDROID_PRODUCT_OUT}/obj/lib/crtend_android.o
-QMAKE_LFLAGS_SHLIB = -Wl,-T,${ANDROID_BUILD_TOP}/build/core/armelf.xsc \
- -Wl,-shared,-Bsymbolic \
- ${ANDROID_PRODUCT_OUT}/obj/lib/crtbegin_so.o \
- ${ANDROID_PRODUCT_OUT}/obj/lib/crtend_so.o
+QMAKE_LFLAGS_SHLIB = -Wl,-T,${ANDROID_BUILD_TOP}/build/core/armelf.xsc \
+ -Wl,-shared,-Bsymbolic \
+ ${ANDROID_PRODUCT_OUT}/obj/lib/crtbegin_so.o \
+ ${ANDROID_PRODUCT_OUT}/obj/lib/crtend_so.o
QMAKE_LFLAGS_SONAME =
QMAKE_LFLAGS_NOUNDEF = -Wl,--no-undefined
@@ -164,17 +171,15 @@ QMAKE_LIBS_QT_OPENGL =
QMAKE_LIBS_QTOPIA =
QMAKE_LIBS_THREAD =
QMAKE_LIBS_OPENGL =
-QMAKE_LIBS_OPENGL_QT =
QMAKE_LIBS_OPENGL_ES1 = -lGLESv1_CM
QMAKE_LIBS_OPENGL_ES2 = -lEGL -lGLESv2 $$QMAKE_LIBS
-CONFIG += linux-android-9 android-9 linux-android android
+CONFIG += linux-android-9 android-9 linux-android android android-no-sdk android_app
load(qt_config)
-QT_CONFIG -=accessibility
# we don't support exceptions, but right now this has no effect
# you need to manually delete mkspecs/features/exceptions.prf
-CONFIG -= exceptions
-CONFIG += exceptions_off
+CONFIG -= exceptions
+CONFIG += exceptions_off
diff --git a/mkspecs/unsupported/integrity-ghs/qmake.conf b/mkspecs/unsupported/integrity-ghs/qmake.conf
index 72f31477df..1ffc2ccec8 100644
--- a/mkspecs/unsupported/integrity-ghs/qmake.conf
+++ b/mkspecs/unsupported/integrity-ghs/qmake.conf
@@ -2,51 +2,51 @@
# qmake configuration for integrity-ghs
#
-MAKEFILE_GENERATOR = GBUILD
-QMAKE_PLATFORM = integrity unix posix
-CONFIG -= link_prl # Not implemented
-
-QMAKE_CFLAGS = -bsp $$INTEGRITY_BSP -os_dir $__OS_DIR
-QMAKE_CFLAGS += --diag_suppress=1,228,236,381,611,997
-QMAKE_CFLAGS_WARN_ON =
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -g -Ospeed -Olink --signed_fields --no_commons
-QMAKE_CFLAGS_DEBUG = -g --no_commons --signed_fields
-QMAKE_CFLAGS_SHLIB =
-QMAKE_CFLAGS_THREAD = -D_REENTRANT
-
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS --no_implicit_include --link_once_templates
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
-
-QMAKE_LFLAGS = -lposix -livfs -lnet -lsocket -lfbdev -ldl
-QMAKE_LFLAGS_RELEASE = -g -Ospeed -Olink --no_commons -non_shared --link_once_templates
-QMAKE_LFLAGS_DEBUG = -g --no_commons
+MAKEFILE_GENERATOR = GBUILD
+QMAKE_PLATFORM = integrity unix posix
+CONFIG -= link_prl # Not implemented
+
+QMAKE_CFLAGS = -bsp $$INTEGRITY_BSP -os_dir $__OS_DIR
+QMAKE_CFLAGS += --diag_suppress=1,228,236,381,611,997
+QMAKE_CFLAGS_WARN_ON =
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -g -Ospeed -Olink --signed_fields --no_commons
+QMAKE_CFLAGS_DEBUG = -g --no_commons --signed_fields
+QMAKE_CFLAGS_SHLIB =
+QMAKE_CFLAGS_THREAD = -D_REENTRANT
+
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS --no_implicit_include --link_once_templates
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
+
+QMAKE_LFLAGS = -lposix -livfs -lnet -lsocket -lfbdev -ldl
+QMAKE_LFLAGS_RELEASE = -g -Ospeed -Olink --no_commons -non_shared --link_once_templates
+QMAKE_LFLAGS_DEBUG = -g --no_commons
QMAKE_LFLAGS_SHLIB =
QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
QMAKE_LFLAGS_SONAME =
QMAKE_LFLAGS_THREAD =
QMAKE_LFLAGS_RPATH =
-QMAKE_LIBS =
+QMAKE_LIBS =
QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 =
+QMAKE_LIBS_X11 =
QMAKE_LIBS_THREAD =
-QMAKE_AR = ar cqs
-QMAKE_RANLIB =
+QMAKE_AR = ar cqs
+QMAKE_RANLIB =
include(../../common/shell-unix.conf)
load(qt_config)
diff --git a/mkspecs/unsupported/linux-android-armeabi-g++/qmake.conf b/mkspecs/unsupported/linux-android-armeabi-g++/qmake.conf
deleted file mode 100644
index ea988d3a51..0000000000
--- a/mkspecs/unsupported/linux-android-armeabi-g++/qmake.conf
+++ /dev/null
@@ -1,14 +0,0 @@
-#
-# qmake configuration for building with android-g++ for ARMv5
-#
-
-ANDROID_TARGET_ARCH = armeabi
-ANDROID_ARCHITECTURE = arm
-ANDROID_NDK_TOOLCHAIN_PREFIX = arm-linux-androideabi
-ANDROID_NDK_TOOLS_PREFIX = arm-linux-androideabi
-QMAKE_CFLAGS = -Wno-psabi -march=armv5te -mtune=xscale -msoft-float -fpic -ffunction-sections -funwind-tables -fstack-protector -fno-short-enums -DANDROID -Wa,--noexecstack
-QMAKE_CFLAGS_RELEASE = -g -mthumb -Os -fomit-frame-pointer -fno-strict-aliasing -finline-limit=64
-QMAKE_CFLAGS_DEBUG = -g -marm -O0 -fno-omit-frame-pointer
-
-include(../../common/linux-android.conf)
-
diff --git a/mkspecs/unsupported/linux-android-armeabi-v7a-g++/qmake.conf b/mkspecs/unsupported/linux-android-armeabi-v7a-g++/qmake.conf
deleted file mode 100644
index 70445a536f..0000000000
--- a/mkspecs/unsupported/linux-android-armeabi-v7a-g++/qmake.conf
+++ /dev/null
@@ -1,14 +0,0 @@
-#
-# qmake configuration for building with android-g++ for ARMv7
-#
-
-ANDROID_TARGET_ARCH = armeabi-v7a
-ANDROID_ARCHITECTURE = arm
-ANDROID_NDK_TOOLCHAIN_PREFIX = arm-linux-androideabi
-ANDROID_NDK_TOOLS_PREFIX = arm-linux-androideabi
-QMAKE_CFLAGS = -Wno-psabi -march=armv7-a -mfloat-abi=softfp -mfpu=vfp -fpic -ffunction-sections -funwind-tables -fstack-protector -fno-short-enums -DANDROID -Wa,--noexecstack
-QMAKE_CFLAGS_RELEASE = -g -mthumb -Os -fomit-frame-pointer -fno-strict-aliasing -finline-limit=64
-QMAKE_CFLAGS_DEBUG = -g -marm -O0 -fno-omit-frame-pointer
-
-include(../../common/linux-android.conf)
-
diff --git a/mkspecs/unsupported/linux-android-x86-g++/qmake.conf b/mkspecs/unsupported/linux-android-x86-g++/qmake.conf
deleted file mode 100644
index 5a51704b38..0000000000
--- a/mkspecs/unsupported/linux-android-x86-g++/qmake.conf
+++ /dev/null
@@ -1,14 +0,0 @@
-#
-# qmake configuration for building with android-g++ for x86
-#
-
-ANDROID_TARGET_ARCH = x86
-ANDROID_ARCHITECTURE = x86
-ANDROID_NDK_TOOLCHAIN_PREFIX = x86
-ANDROID_NDK_TOOLS_PREFIX = i686-android-linux
-QMAKE_CFLAGS = -ffunction-sections -funwind-tables -O2 -fomit-frame-pointer -fstrict-aliasing -funswitch-loops -finline-limit=300 -DANDROID -Wa,--noexecstack
-QMAKE_CFLAGS_RELEASE = -g -O2
-QMAKE_CFLAGS_DEBUG = -g
-
-include(../../common/linux-android.conf)
-
diff --git a/mkspecs/unsupported/linux-armcc/qmake.conf b/mkspecs/unsupported/linux-armcc/qmake.conf
index a65f8d534e..2c7eb7c2d8 100644
--- a/mkspecs/unsupported/linux-armcc/qmake.conf
+++ b/mkspecs/unsupported/linux-armcc/qmake.conf
@@ -3,7 +3,7 @@
#
MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental armcc_linker
+CONFIG += incremental armcc_linker
QMAKE_INCREMENTAL_STYLE = sublib
include(../../common/linux.conf)
@@ -11,19 +11,19 @@ include(../../common/armcc.conf)
load(qt_config)
# use armcc for linking since armlink doesn't understand the arm_linux_config_file option
-QMAKE_LINK = armcc
-QMAKE_LINK_SHLIB = armcc
-QMAKE_LINK_C = armcc
-QMAKE_LINK_C_SHLIB = armcc
+QMAKE_LINK = armcc
+QMAKE_LINK_SHLIB = armcc
+QMAKE_LINK_C = armcc
+QMAKE_LINK_C_SHLIB = armcc
-QMAKE_LFLAGS_SHLIB += --apcs=/fpic --shared
+QMAKE_LFLAGS_SHLIB += --apcs=/fpic --shared
QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LIBS += libstdc++.so librt.so
+QMAKE_LIBS += libstdc++.so librt.so
-CONFIG -= rvct_linker
+CONFIG -= rvct_linker
-QMAKE_CFLAGS += --gnu --arm_linux --dllimport_runtime --thumb --cpu Cortex-A9 --arm_linux_config_file="$(HOME)/qt_rvct_config" --arm-linux-paths --apcs=/interwork --visibility_inlines_hidden --diag_suppress 1300,2523
-QMAKE_CXXFLAGS += $$QMAKE_CFLAGS --cpp
+QMAKE_CFLAGS += --gnu --arm_linux --dllimport_runtime --thumb --cpu Cortex-A9 --arm_linux_config_file="$(HOME)/qt_rvct_config" --arm-linux-paths --apcs=/interwork --visibility_inlines_hidden --diag_suppress 1300,2523
+QMAKE_CXXFLAGS += $$QMAKE_CFLAGS --cpp
-QMAKE_LFLAGS += --diag_suppress 6331,6780,6439 --arm_linux_config_file="$(HOME)/qt_rvct_config" --arm-linux-paths
+QMAKE_LFLAGS += --diag_suppress 6331,6780,6439 --arm_linux_config_file="$(HOME)/qt_rvct_config" --arm-linux-paths
diff --git a/mkspecs/unsupported/linux-host-g++/qmake.conf b/mkspecs/unsupported/linux-host-g++/qmake.conf
index 3e5840e7f4..710c1876aa 100644
--- a/mkspecs/unsupported/linux-host-g++/qmake.conf
+++ b/mkspecs/unsupported/linux-host-g++/qmake.conf
@@ -4,49 +4,49 @@
# This mkspec can be used as the platform mkspec when building
# Qt in scratchbox. If used as such, qmake and similar host
# tools will be compiled for the host architecture (E.g. x86)
-# and thus not run in the emulator. This results in a
+# and thus not run in the emulator. This results in a
# significant improvement in build times.
-#
+#
# Note: The mkspec copied & pasted parts from common/gcc.conf
# and common/linux.conf as setBootstrapVariable in
# configure has a bug which stops re-assignments working
# for QMake variables (I.e. "QMAKE_foo = bar" is broken).
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = linux
-CONFIG += incremental
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = linux
+CONFIG += incremental
QMAKE_INCREMENTAL_STYLE = sublib
#
# qmake configuration for common gcc
#
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
QMAKE_CC = host-gcc
-QMAKE_CFLAGS += -pipe
-QMAKE_CFLAGS_DEPS += -M
-QMAKE_CFLAGS_WARN_ON += -Wall -W
-QMAKE_CFLAGS_WARN_OFF += -w
-QMAKE_CFLAGS_RELEASE += -O2
-QMAKE_CFLAGS_DEBUG += -g
-QMAKE_CFLAGS_SHLIB += -fPIC
+QMAKE_CFLAGS += -pipe
+QMAKE_CFLAGS_DEPS += -M
+QMAKE_CFLAGS_WARN_ON += -Wall -W
+QMAKE_CFLAGS_WARN_OFF += -w
+QMAKE_CFLAGS_RELEASE += -O2
+QMAKE_CFLAGS_DEBUG += -g
+QMAKE_CFLAGS_SHLIB += -fPIC
QMAKE_CFLAGS_STATIC_LIB += -fPIC
-QMAKE_CFLAGS_YACC += -Wno-unused -Wno-parentheses
-QMAKE_CFLAGS_HIDESYMS += -fvisibility=hidden
+QMAKE_CFLAGS_YACC += -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_HIDESYMS += -fvisibility=hidden
QMAKE_CFLAGS_PRECOMPILE += -x c-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_CFLAGS_USE_PRECOMPILE += -include ${QMAKE_PCH_OUTPUT_BASE}
QMAKE_CXX = host-g++
-QMAKE_CXXFLAGS += $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS += $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON += $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS += $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS += $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON += $$QMAKE_CFLAGS_WARN_ON
QMAKE_CXXFLAGS_WARN_OFF += $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG += $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB += $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG += $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB += $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB += $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC += $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_YACC += $$QMAKE_CFLAGS_YACC
QMAKE_CXXFLAGS_HIDESYMS += $$QMAKE_CFLAGS_HIDESYMS -fvisibility-inlines-hidden
QMAKE_CXXFLAGS_PRECOMPILE += -x c++-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT}
QMAKE_CXXFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
@@ -55,15 +55,15 @@ QMAKE_LINK = host-g++
QMAKE_LINK_SHLIB = host-g++
QMAKE_LINK_C = host-gcc
QMAKE_LINK_C_SHLIB = host-gcc
-QMAKE_LFLAGS +=
-QMAKE_LFLAGS_RELEASE += -Wl,-O1
-QMAKE_LFLAGS_DEBUG +=
-QMAKE_LFLAGS_APP +=
-QMAKE_LFLAGS_SHLIB += -shared
-QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME += -Wl,-soname,
-QMAKE_LFLAGS_THREAD +=
-QMAKE_LFLAGS_NOUNDEF += -Wl,--no-undefined
+QMAKE_LFLAGS +=
+QMAKE_LFLAGS_RELEASE += -Wl,-O1
+QMAKE_LFLAGS_DEBUG +=
+QMAKE_LFLAGS_APP +=
+QMAKE_LFLAGS_SHLIB += -shared
+QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME += -Wl,-soname,
+QMAKE_LFLAGS_THREAD +=
+QMAKE_LFLAGS_NOUNDEF += -Wl,--no-undefined
QMAKE_LFLAGS_RPATH = -Wl,-rpath,
QMAKE_PCH_OUTPUT_EXT = .gch
@@ -76,44 +76,43 @@ QMAKE_LFLAGS_DYNAMIC_LIST = -Wl,--dynamic-list,
# qmake configuration for common linux
#
-QMAKE_CFLAGS_THREAD += -D_REENTRANT
-QMAKE_CXXFLAGS_THREAD += $$QMAKE_CFLAGS_THREAD
+QMAKE_CFLAGS_THREAD += -D_REENTRANT
+QMAKE_CXXFLAGS_THREAD += $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 =
-QMAKE_LIBDIR_X11 =
-QMAKE_INCDIR_OPENGL =
-QMAKE_LIBDIR_OPENGL =
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 =
+QMAKE_LIBDIR_X11 =
+QMAKE_INCDIR_OPENGL =
+QMAKE_LIBDIR_OPENGL =
QMAKE_INCDIR_OPENGL_ES1 = $$QMAKE_INCDIR_OPENGL
QMAKE_LIBDIR_OPENGL_ES1 = $$QMAKE_LIBDIR_OPENGL
QMAKE_INCDIR_OPENGL_ES2 = $$QMAKE_INCDIR_OPENGL
QMAKE_LIBDIR_OPENGL_ES2 = $$QMAKE_LIBDIR_OPENGL
-QMAKE_INCDIR_EGL =
-QMAKE_LIBDIR_EGL =
-QMAKE_INCDIR_OPENVG =
-QMAKE_LIBDIR_OPENVG =
+QMAKE_INCDIR_EGL =
+QMAKE_LIBDIR_EGL =
+QMAKE_INCDIR_OPENVG =
+QMAKE_LIBDIR_OPENVG =
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD = -ldl
-QMAKE_LIBS_X11 = -lXext -lX11 -lm
-QMAKE_LIBS_NIS = -lnsl
-QMAKE_LIBS_EGL = -lEGL
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_OPENGL_ES1 = -lGLES_CM
-QMAKE_LIBS_OPENGL_ES2 = -lGLESv2
-QMAKE_LIBS_OPENVG = -lOpenVG
-QMAKE_LIBS_THREAD = -lpthread
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD = -ldl
+QMAKE_LIBS_X11 = -lXext -lX11 -lm
+QMAKE_LIBS_NIS = -lnsl
+QMAKE_LIBS_EGL = -lEGL
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_OPENGL_ES1 = -lGLES_CM
+QMAKE_LIBS_OPENGL_ES2 = -lGLESv2
+QMAKE_LIBS_OPENVG = -lOpenVG
+QMAKE_LIBS_THREAD = -lpthread
-QMAKE_AR = host-ar cqs
-QMAKE_OBJCOPY = host-objcopy
-QMAKE_RANLIB =
+QMAKE_AR = host-ar cqs
+QMAKE_OBJCOPY = host-objcopy
+QMAKE_RANLIB =
-QMAKE_STRIP = host-strip
-QMAKE_STRIPFLAGS_LIB += --strip-unneeded
-QMAKE_INSTALL_FILE = install -m 644 -p
-QMAKE_INSTALL_PROGRAM = install -m 755 -p
+QMAKE_STRIP = host-strip
+QMAKE_STRIPFLAGS_LIB += --strip-unneeded
+QMAKE_INSTALL_FILE = install -m 644 -p
+QMAKE_INSTALL_PROGRAM = install -m 755 -p
include(../../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/unsupported/linux-scratchbox2-g++/qmake.conf b/mkspecs/unsupported/linux-scratchbox2-g++/qmake.conf
index 069b016adb..a300712d33 100644
--- a/mkspecs/unsupported/linux-scratchbox2-g++/qmake.conf
+++ b/mkspecs/unsupported/linux-scratchbox2-g++/qmake.conf
@@ -11,8 +11,8 @@
# correctly query and utilize your targets .pc files (normally stored in
# $staging/usr/lib/pkgconfig)
-MAKEFILE_GENERATOR = UNIX
-CONFIG += incremental
+MAKEFILE_GENERATOR = UNIX
+CONFIG += incremental
QMAKE_INCREMENTAL_STYLE = sublib
include(../../common/linux.conf)
diff --git a/mkspecs/unsupported/macx-ios-clang/Info.plist.app b/mkspecs/unsupported/macx-ios-clang/Info.plist.app
new file mode 100755
index 0000000000..c7d660b8d1
--- /dev/null
+++ b/mkspecs/unsupported/macx-ios-clang/Info.plist.app
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist SYSTEM "file://localhost/System/Library/DTDs/PropertyList.dtd">
+<plist version="0.9">
+<dict>
+ <key>CFBundleIconFile</key>
+ <string>@ICON@</string>
+ <key>CFBundlePackageType</key>
+ <string>APPL</string>
+ <key>CFBundleGetInfoString</key>
+ <string>Created by Qt/QMake</string>
+ <key>CFBundleSignature</key>
+ <string>@TYPEINFO@</string>
+ <key>CFBundleExecutable</key>
+ <string>@EXECUTABLE@</string>
+ <key>CFBundleIdentifier</key>
+ <string>com.yourcompany.@BUNDLEIDENTIFIER@</string>
+ <key>CFBundleDisplayName</key>
+ <string>${PRODUCT_NAME}</string>
+ <key>CFBundleName</key>
+ <string>${PRODUCT_NAME}</string>
+ <key>CFBundleShortVersionString</key>
+ <string>1.0</string>
+ <key>CFBundleVersion</key>
+ <string>1.0</string>
+ <key>NOTE</key>
+ <string>This file was generated by Qt/QMake.</string>
+</dict>
+</plist>
diff --git a/mkspecs/unsupported/macx-ios-clang/Info.plist.lib b/mkspecs/unsupported/macx-ios-clang/Info.plist.lib
new file mode 100644
index 0000000000..97609ed0ce
--- /dev/null
+++ b/mkspecs/unsupported/macx-ios-clang/Info.plist.lib
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist SYSTEM "file://localhost/System/Library/DTDs/PropertyList.dtd">
+<plist version="0.9">
+<dict>
+ <key>CFBundlePackageType</key>
+ <string>FMWK</string>
+ <key>CFBundleShortVersionString</key>
+ <string>@SHORT_VERSION@</string>
+ <key>CFBundleGetInfoString</key>
+ <string>Created by Qt/QMake</string>
+ <key>CFBundleSignature</key>
+ <string>@TYPEINFO@</string>
+ <key>CFBundleExecutable</key>
+ <string>@LIBRARY@</string>
+ <key>NOTE</key>
+ <string>Please, do NOT change this file -- It was generated by Qt/QMake.</string>
+</dict>
+</plist>
diff --git a/mkspecs/unsupported/macx-ios-clang/qmake.conf b/mkspecs/unsupported/macx-ios-clang/qmake.conf
new file mode 100644
index 0000000000..833e22e3bd
--- /dev/null
+++ b/mkspecs/unsupported/macx-ios-clang/qmake.conf
@@ -0,0 +1,27 @@
+#
+# qmake configuration for macx-ios-clang
+#
+
+MAKEFILE_GENERATOR = UNIX
+CONFIG += app_bundle reduce_exports incremental global_init_link_order lib_version_first plugin_no_soname sdk
+QMAKE_INCREMENTAL_STYLE = sublib
+
+QMAKE_MACOSX_DEPLOYMENT_TARGET =
+QMAKE_IOS_DEPLOYMENT_TARGET = 4.3
+
+INCLUDEPATH += $$PWD/ios
+DEFINES += DARWIN_NO_CARBON QT_NO_CORESERVICES QT_NO_PRINTER QT_NO_PRINTDIALOG
+
+# Universal target (iPhone and iPad)
+QMAKE_IOS_TARGETED_DEVICE_FAMILY = 1,2
+
+include(../../common/ios.conf)
+include(../../common/gcc-base-mac.conf)
+include(../../common/clang.conf)
+include(../../common/clang-mac.conf)
+include(../../common/ios/clang.conf)
+include(../../common/ios/qmake.conf)
+
+lessThan(QMAKE_XCODE_VERSION, "4.3"): error("This mkspec requires Xcode 4.3 or later")
+
+load(qt_config)
diff --git a/mkspecs/unsupported/macx-iosdevice-clang/qplatformdefs.h b/mkspecs/unsupported/macx-ios-clang/qplatformdefs.h
index 5f80a17860..581ad0d485 100644
--- a/mkspecs/unsupported/macx-iosdevice-clang/qplatformdefs.h
+++ b/mkspecs/unsupported/macx-ios-clang/qplatformdefs.h
@@ -39,4 +39,4 @@
**
****************************************************************************/
-#include "../../common/ios/qplatformdefs.h"
+#include "../../common/mac/qplatformdefs.h"
diff --git a/mkspecs/unsupported/macx-iosdevice-clang-legacy/qmake.conf b/mkspecs/unsupported/macx-iosdevice-clang-legacy/qmake.conf
deleted file mode 100644
index ff8e0b6aa9..0000000000
--- a/mkspecs/unsupported/macx-iosdevice-clang-legacy/qmake.conf
+++ /dev/null
@@ -1,35 +0,0 @@
-#
-# qmake configuration for ios-device-clang
-#
-# Depends on:
-#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
-#
-
-include(../../common/mac.conf)
-include(../../common/gcc-base-ios.conf)
-include(../../common/clang.conf)
-include(../../common/ios.conf)
-include(../../common/ios/versions.conf)
-include(../../common/ios/clang.conf)
-include(../../common/ios/qmake.conf)
-
-# Version check
-!lessThan(QMAKE_IOS_XCODE_VERSION, "4.3"): error("This mkspec requires Xcode 4.2.x or earlier")
-
-# iOS build tools
-QMAKE_CC = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/clang
-QMAKE_CXX = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/clang++
-QMAKE_FIX_RPATH = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/install_name_tool -id
-QMAKE_AR = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ar cq
-QMAKE_RANLIB = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ranlib -s
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-
-# Check that compiler is valid
-!exists($$QMAKE_CXX): error("The version of Xcode installed on this system does not include the clang compiler")
-
-load(qt_config)
-
-# Include after config is loaded to allow autodetection on GL/ES version
-include(../../common/ios/arch.conf)
diff --git a/mkspecs/unsupported/macx-iosdevice-clang/qmake.conf b/mkspecs/unsupported/macx-iosdevice-clang/qmake.conf
deleted file mode 100644
index 777b5ab6e2..0000000000
--- a/mkspecs/unsupported/macx-iosdevice-clang/qmake.conf
+++ /dev/null
@@ -1,35 +0,0 @@
-#
-# qmake configuration for ios-device-clang
-#
-# Depends on:
-#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
-#
-
-include(../../common/mac.conf)
-include(../../common/gcc-base-ios.conf)
-include(../../common/clang.conf)
-include(../../common/ios.conf)
-include(../../common/ios/versions.conf)
-include(../../common/ios/clang.conf)
-include(../../common/ios/qmake.conf)
-
-# Version check
-lessThan(QMAKE_IOS_XCODE_VERSION, "4.3"): error("This mkspec requires Xcode 4.3 or later")
-
-# iOS build tools
-QMAKE_CC = /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang
-QMAKE_CXX = /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++
-QMAKE_FIX_RPATH = /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/install_name_tool -id
-QMAKE_AR = /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ar cq
-QMAKE_RANLIB = /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib -s
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-
-# Check that compiler is valid
-!exists($$QMAKE_CXX): error("The version of Xcode installed on this system does not include the clang compiler")
-
-load(qt_config)
-
-# Include after config is loaded to allow autodetection on GL/ES version
-include(../../common/ios/arch.conf)
diff --git a/mkspecs/unsupported/macx-iosdevice-g++-legacy/qmake.conf b/mkspecs/unsupported/macx-iosdevice-g++-legacy/qmake.conf
deleted file mode 100644
index 5fcfb4a51d..0000000000
--- a/mkspecs/unsupported/macx-iosdevice-g++-legacy/qmake.conf
+++ /dev/null
@@ -1,35 +0,0 @@
-#
-# qmake configuration for ios-device-g++
-#
-# Depends on:
-#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
-#
-
-include(../../common/mac.conf)
-include(../../common/gcc-base-ios.conf)
-include(../../common/g++-macx.conf)
-include(../../common/ios.conf)
-include(../../common/ios/versions.conf)
-include(../../common/ios/g++.conf)
-include(../../common/ios/qmake.conf)
-
-# Version check (g++ was discontinued at version 4.2, but user may have added it themselves)
-!lessThan(QMAKE_IOS_XCODE_VERSION, "4.3"): error("This mkspec requires Xcode 4.2.x or earlier")
-
-# iOS build tools
-QMAKE_CC = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc-4.2
-QMAKE_CXX = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/g++-4.2
-QMAKE_FIX_RPATH = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/install_name_tool -id
-QMAKE_AR = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ar cq
-QMAKE_RANLIB = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ranlib -s
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-
-# Check that compiler is valid
-!exists($$QMAKE_CXX): error("The version of Xcode installed on this system does not include the g++ 4.2 compiler")
-
-load(qt_config)
-
-# Include after config is loaded to allow autodetection on GL/ES version
-include(../../common/ios/arch.conf)
diff --git a/mkspecs/unsupported/macx-iosdevice-g++/qmake.conf b/mkspecs/unsupported/macx-iosdevice-g++/qmake.conf
deleted file mode 100644
index 2a29335334..0000000000
--- a/mkspecs/unsupported/macx-iosdevice-g++/qmake.conf
+++ /dev/null
@@ -1,35 +0,0 @@
-#
-# qmake configuration for ios-device-g++
-#
-# Depends on:
-#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
-#
-
-include(../../common/mac.conf)
-include(../../common/gcc-base-ios.conf)
-include(../../common/g++-macx.conf)
-include(../../common/ios.conf)
-include(../../common/ios/versions.conf)
-include(../../common/ios/g++.conf)
-include(../../common/ios/qmake.conf)
-
-# Version check (g++ was discontinued at version 4.2, but user may have added it themselves)
-lessThan(QMAKE_IOS_XCODE_VERSION, "4.3"): error("This mkspec requires Xcode 4.3 or later")
-
-# iOS build tools
-QMAKE_CC = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc-4.2
-QMAKE_CXX = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/g++-4.2
-QMAKE_FIX_RPATH = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/install_name_tool -id
-QMAKE_AR = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ar cq
-QMAKE_RANLIB = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ranlib -s
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-
-# Check that compiler is valid
-!exists($$QMAKE_CXX): error("The version of Xcode installed on this system does not include the g++ 4.2 compiler")
-
-load(qt_config)
-
-# Include after config is loaded to allow autodetection on GL/ES version
-include(../../common/ios/arch.conf)
diff --git a/mkspecs/unsupported/macx-iosdevice-g++/qplatformdefs.h b/mkspecs/unsupported/macx-iosdevice-g++/qplatformdefs.h
deleted file mode 100644
index 5f80a17860..0000000000
--- a/mkspecs/unsupported/macx-iosdevice-g++/qplatformdefs.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
-**
-** This file is part of the qmake spec of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and Digia. For licensing terms and
-** conditions see http://qt.digia.com/licensing. For further information
-** use the contact form at http://qt.digia.com/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 2.1 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-**
-** In addition, as a special exception, Digia gives you certain additional
-** rights. These rights are described in the Digia Qt LGPL Exception
-** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3.0 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU General Public License version 3.0 requirements will be
-** met: http://www.gnu.org/copyleft/gpl.html.
-**
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include "../../common/ios/qplatformdefs.h"
diff --git a/mkspecs/unsupported/macx-iosdevice-llvm-legacy/qmake.conf b/mkspecs/unsupported/macx-iosdevice-llvm-legacy/qmake.conf
deleted file mode 100644
index 4554843610..0000000000
--- a/mkspecs/unsupported/macx-iosdevice-llvm-legacy/qmake.conf
+++ /dev/null
@@ -1,35 +0,0 @@
-#
-# qmake configuration for ios-device-llvm
-#
-# Depends on:
-#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
-#
-
-include(../../common/mac.conf)
-include(../../common/gcc-base-ios.conf)
-include(../../common/llvm.conf)
-include(../../common/ios.conf)
-include(../../common/ios/versions.conf)
-include(../../common/ios/llvm.conf)
-include(../../common/ios/qmake.conf)
-
-# Version check
-!lessThan(QMAKE_IOS_XCODE_VERSION, "4.3"): error("This mkspec requires Xcode 4.2.x or earlier")
-
-# iOS build tools
-QMAKE_CC = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/llvm-gcc-4.2
-QMAKE_CXX = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/llvm-g++-4.2
-QMAKE_FIX_RPATH = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/install_name_tool -id
-QMAKE_AR = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ar cq
-QMAKE_RANLIB = /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ranlib -s
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-
-# Check that compiler is valid
-!exists($$QMAKE_CXX): error("The version of Xcode installed on this system does not include the llvm-g++ 4.2 compiler")
-
-load(qt_config)
-
-# Include after config is loaded to allow autodetection on GL/ES version
-include(../../common/ios/arch.conf)
diff --git a/mkspecs/unsupported/macx-iosdevice-llvm-legacy/qplatformdefs.h b/mkspecs/unsupported/macx-iosdevice-llvm-legacy/qplatformdefs.h
deleted file mode 100644
index 5f80a17860..0000000000
--- a/mkspecs/unsupported/macx-iosdevice-llvm-legacy/qplatformdefs.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
-**
-** This file is part of the qmake spec of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and Digia. For licensing terms and
-** conditions see http://qt.digia.com/licensing. For further information
-** use the contact form at http://qt.digia.com/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 2.1 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-**
-** In addition, as a special exception, Digia gives you certain additional
-** rights. These rights are described in the Digia Qt LGPL Exception
-** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3.0 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU General Public License version 3.0 requirements will be
-** met: http://www.gnu.org/copyleft/gpl.html.
-**
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include "../../common/ios/qplatformdefs.h"
diff --git a/mkspecs/unsupported/macx-iosdevice-llvm/qmake.conf b/mkspecs/unsupported/macx-iosdevice-llvm/qmake.conf
deleted file mode 100644
index 335c68fd42..0000000000
--- a/mkspecs/unsupported/macx-iosdevice-llvm/qmake.conf
+++ /dev/null
@@ -1,35 +0,0 @@
-#
-# qmake configuration for ios-device-llvm
-#
-# Depends on:
-#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
-#
-
-include(../../common/mac.conf)
-include(../../common/gcc-base-ios.conf)
-include(../../common/llvm.conf)
-include(../../common/ios.conf)
-include(../../common/ios/versions.conf)
-include(../../common/ios/llvm.conf)
-include(../../common/ios/qmake.conf)
-
-# Version check
-lessThan(QMAKE_IOS_XCODE_VERSION, "4.3"): error("This mkspec requires Xcode 4.3 or later")
-
-# iOS build tools
-QMAKE_CC = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/llvm-gcc-4.2
-QMAKE_CXX = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/llvm-g++-4.2
-QMAKE_FIX_RPATH = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/install_name_tool -id
-QMAKE_AR = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ar cq
-QMAKE_RANLIB = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/ranlib -s
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-
-# Check that compiler is valid
-!exists($$QMAKE_CXX): error("The version of Xcode installed on this system does not include the llvm-g++ 4.2 compiler")
-
-load(qt_config)
-
-# Include after config is loaded to allow autodetection on GL/ES version
-include(../../common/ios/arch.conf)
diff --git a/mkspecs/unsupported/macx-iosdevice-llvm/qplatformdefs.h b/mkspecs/unsupported/macx-iosdevice-llvm/qplatformdefs.h
deleted file mode 100644
index 5f80a17860..0000000000
--- a/mkspecs/unsupported/macx-iosdevice-llvm/qplatformdefs.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
-**
-** This file is part of the qmake spec of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and Digia. For licensing terms and
-** conditions see http://qt.digia.com/licensing. For further information
-** use the contact form at http://qt.digia.com/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 2.1 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-**
-** In addition, as a special exception, Digia gives you certain additional
-** rights. These rights are described in the Digia Qt LGPL Exception
-** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3.0 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU General Public License version 3.0 requirements will be
-** met: http://www.gnu.org/copyleft/gpl.html.
-**
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include "../../common/ios/qplatformdefs.h"
diff --git a/mkspecs/unsupported/macx-iossimulator-clang-legacy/qmake.conf b/mkspecs/unsupported/macx-iossimulator-clang-legacy/qmake.conf
deleted file mode 100644
index b042766a39..0000000000
--- a/mkspecs/unsupported/macx-iossimulator-clang-legacy/qmake.conf
+++ /dev/null
@@ -1,6 +0,0 @@
-#
-# qmake configuration for ios-simulator-clang
-#
-
-# All differences between device and simulator are handled in iOS include files
-include(../macx-iosdevice-clang-legacy/qmake.conf)
diff --git a/mkspecs/unsupported/macx-iossimulator-clang-legacy/qplatformdefs.h b/mkspecs/unsupported/macx-iossimulator-clang-legacy/qplatformdefs.h
deleted file mode 100644
index 5f80a17860..0000000000
--- a/mkspecs/unsupported/macx-iossimulator-clang-legacy/qplatformdefs.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
-**
-** This file is part of the qmake spec of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and Digia. For licensing terms and
-** conditions see http://qt.digia.com/licensing. For further information
-** use the contact form at http://qt.digia.com/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 2.1 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-**
-** In addition, as a special exception, Digia gives you certain additional
-** rights. These rights are described in the Digia Qt LGPL Exception
-** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3.0 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU General Public License version 3.0 requirements will be
-** met: http://www.gnu.org/copyleft/gpl.html.
-**
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include "../../common/ios/qplatformdefs.h"
diff --git a/mkspecs/unsupported/macx-iossimulator-clang/qmake.conf b/mkspecs/unsupported/macx-iossimulator-clang/qmake.conf
deleted file mode 100644
index 11301cb72f..0000000000
--- a/mkspecs/unsupported/macx-iossimulator-clang/qmake.conf
+++ /dev/null
@@ -1,6 +0,0 @@
-#
-# qmake configuration for ios-simulator-clang
-#
-
-# All differences between device and simulator are handled in iOS include files
-include(../macx-iosdevice-clang/qmake.conf)
diff --git a/mkspecs/unsupported/macx-iossimulator-clang/qplatformdefs.h b/mkspecs/unsupported/macx-iossimulator-clang/qplatformdefs.h
deleted file mode 100644
index 5f80a17860..0000000000
--- a/mkspecs/unsupported/macx-iossimulator-clang/qplatformdefs.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
-**
-** This file is part of the qmake spec of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and Digia. For licensing terms and
-** conditions see http://qt.digia.com/licensing. For further information
-** use the contact form at http://qt.digia.com/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 2.1 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-**
-** In addition, as a special exception, Digia gives you certain additional
-** rights. These rights are described in the Digia Qt LGPL Exception
-** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3.0 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU General Public License version 3.0 requirements will be
-** met: http://www.gnu.org/copyleft/gpl.html.
-**
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include "../../common/ios/qplatformdefs.h"
diff --git a/mkspecs/unsupported/macx-iossimulator-g++-legacy/qmake.conf b/mkspecs/unsupported/macx-iossimulator-g++-legacy/qmake.conf
deleted file mode 100644
index abc695231e..0000000000
--- a/mkspecs/unsupported/macx-iossimulator-g++-legacy/qmake.conf
+++ /dev/null
@@ -1,33 +0,0 @@
-#
-# qmake configuration for ios-simulator-g++
-#
-# Depends on:
-#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
-#
-
-include(../../common/mac.conf)
-include(../../common/gcc-base-ios.conf)
-include(../../common/g++-macx.conf)
-include(../../common/ios.conf)
-include(../../common/ios/versions.conf)
-include(../../common/ios/arch.conf)
-include(../../common/ios/g++.conf)
-include(../../common/ios/qmake.conf)
-
-# Version check (g++ was discontinued at version 4.2)
-!lessThan(QMAKE_IOS_XCODE_VERSION, "4.2"): error("This mkspec requires Xcode 4.1.x or earlier")
-
-# iOS build tools
-QMAKE_CC = /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc-4.2
-QMAKE_CXX = /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++-4.2
-QMAKE_FIX_RPATH = /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/install_name_tool -id
-QMAKE_AR = /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ar cq
-QMAKE_RANLIB = /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ranlib -s
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-
-# Check that compiler is valid
-!exists($$QMAKE_CXX): error("The version of Xcode installed on this system does not include the g++ 4.2 compiler")
-
-load(qt_config)
diff --git a/mkspecs/unsupported/macx-iossimulator-g++-legacy/qplatformdefs.h b/mkspecs/unsupported/macx-iossimulator-g++-legacy/qplatformdefs.h
deleted file mode 100644
index 5f80a17860..0000000000
--- a/mkspecs/unsupported/macx-iossimulator-g++-legacy/qplatformdefs.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
-**
-** This file is part of the qmake spec of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and Digia. For licensing terms and
-** conditions see http://qt.digia.com/licensing. For further information
-** use the contact form at http://qt.digia.com/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 2.1 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-**
-** In addition, as a special exception, Digia gives you certain additional
-** rights. These rights are described in the Digia Qt LGPL Exception
-** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3.0 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU General Public License version 3.0 requirements will be
-** met: http://www.gnu.org/copyleft/gpl.html.
-**
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include "../../common/ios/qplatformdefs.h"
diff --git a/mkspecs/unsupported/macx-iossimulator-g++/qmake.conf b/mkspecs/unsupported/macx-iossimulator-g++/qmake.conf
deleted file mode 100644
index 99848be410..0000000000
--- a/mkspecs/unsupported/macx-iossimulator-g++/qmake.conf
+++ /dev/null
@@ -1,33 +0,0 @@
-#
-# qmake configuration for ios-simulator-g++
-#
-# Depends on:
-#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
-#
-
-include(../../common/mac.conf)
-include(../../common/gcc-base-ios.conf)
-include(../../common/g++-macx.conf)
-include(../../common/ios.conf)
-include(../../common/ios/versions.conf)
-include(../../common/ios/arch.conf)
-include(../../common/ios/g++.conf)
-include(../../common/ios/qmake.conf)
-
-# Version check (g++ was discontinued at version 4.2, but user may have added it themselves)
-lessThan(QMAKE_IOS_XCODE_VERSION, "4.3"): error("This mkspec requires Xcode 4.3 or later")
-
-# iOS build tools
-QMAKE_CC = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc-4.2
-QMAKE_CXX = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++-4.2
-QMAKE_FIX_RPATH = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/install_name_tool -id
-QMAKE_AR = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ar cq
-QMAKE_RANLIB = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ranlib -s
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-
-# Check that compiler is valid
-!exists($$QMAKE_CXX): error("The version of Xcode installed on this system does not include the g++ 4.2 compiler")
-
-load(qt_config)
diff --git a/mkspecs/unsupported/macx-iossimulator-g++/qplatformdefs.h b/mkspecs/unsupported/macx-iossimulator-g++/qplatformdefs.h
deleted file mode 100644
index 5f80a17860..0000000000
--- a/mkspecs/unsupported/macx-iossimulator-g++/qplatformdefs.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
-**
-** This file is part of the qmake spec of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and Digia. For licensing terms and
-** conditions see http://qt.digia.com/licensing. For further information
-** use the contact form at http://qt.digia.com/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 2.1 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-**
-** In addition, as a special exception, Digia gives you certain additional
-** rights. These rights are described in the Digia Qt LGPL Exception
-** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3.0 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU General Public License version 3.0 requirements will be
-** met: http://www.gnu.org/copyleft/gpl.html.
-**
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include "../../common/ios/qplatformdefs.h"
diff --git a/mkspecs/unsupported/macx-iossimulator-llvm-legacy/qmake.conf b/mkspecs/unsupported/macx-iossimulator-llvm-legacy/qmake.conf
deleted file mode 100644
index 95d530cc18..0000000000
--- a/mkspecs/unsupported/macx-iossimulator-llvm-legacy/qmake.conf
+++ /dev/null
@@ -1,33 +0,0 @@
-#
-# qmake configuration for ios-simulator-llvm
-#
-# Depends on:
-#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
-#
-
-include(../../common/mac.conf)
-include(../../common/gcc-base-ios.conf)
-include(../../common/llvm.conf)
-include(../../common/ios.conf)
-include(../../common/ios/versions.conf)
-include(../../common/ios/arch.conf)
-include(../../common/ios/llvm.conf)
-include(../../common/ios/qmake.conf)
-
-# Version check
-!lessThan(QMAKE_IOS_XCODE_VERSION, "4.3"): error("This mkspec requires Xcode 4.2.x or earlier")
-
-# iOS build tools
-QMAKE_CC = /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2
-QMAKE_CXX = /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-g++-4.2
-QMAKE_FIX_RPATH = /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/install_name_tool -id
-QMAKE_AR = /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ar cq
-QMAKE_RANLIB = /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ranlib -s
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-
-# Check that compiler is valid
-!exists($$QMAKE_CXX): error("The version of Xcode installed on this system does not include the llvm-g++ 4.2 compiler")
-
-load(qt_config)
diff --git a/mkspecs/unsupported/macx-iossimulator-llvm-legacy/qplatformdefs.h b/mkspecs/unsupported/macx-iossimulator-llvm-legacy/qplatformdefs.h
deleted file mode 100644
index 5f80a17860..0000000000
--- a/mkspecs/unsupported/macx-iossimulator-llvm-legacy/qplatformdefs.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
-**
-** This file is part of the qmake spec of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and Digia. For licensing terms and
-** conditions see http://qt.digia.com/licensing. For further information
-** use the contact form at http://qt.digia.com/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 2.1 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-**
-** In addition, as a special exception, Digia gives you certain additional
-** rights. These rights are described in the Digia Qt LGPL Exception
-** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3.0 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU General Public License version 3.0 requirements will be
-** met: http://www.gnu.org/copyleft/gpl.html.
-**
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include "../../common/ios/qplatformdefs.h"
diff --git a/mkspecs/unsupported/macx-iossimulator-llvm/qmake.conf b/mkspecs/unsupported/macx-iossimulator-llvm/qmake.conf
deleted file mode 100644
index 7e3d4b5710..0000000000
--- a/mkspecs/unsupported/macx-iossimulator-llvm/qmake.conf
+++ /dev/null
@@ -1,33 +0,0 @@
-#
-# qmake configuration for ios-simulator-llvm
-#
-# Depends on:
-#
-# QMAKE_IOS_XCODE_VERSION - set in mkspecs/common/ios/versions.conf
-#
-
-include(../../common/mac.conf)
-include(../../common/gcc-base-ios.conf)
-include(../../common/llvm.conf)
-include(../../common/ios.conf)
-include(../../common/ios/versions.conf)
-include(../../common/ios/arch.conf)
-include(../../common/ios/llvm.conf)
-include(../../common/ios/qmake.conf)
-
-# Version check
-lessThan(QMAKE_IOS_XCODE_VERSION, "4.3"): error("This mkspec requires Xcode 4.3 or later")
-
-# iOS build tools
-QMAKE_CC = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2
-QMAKE_CXX = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-g++-4.2
-QMAKE_FIX_RPATH = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/install_name_tool -id
-QMAKE_AR = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ar cq
-QMAKE_RANLIB = /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/ranlib -s
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-
-# Check that compiler is valid
-!exists($$QMAKE_CXX): error("The version of Xcode installed on this system does not include the llvm-g++ 4.2 compiler")
-
-load(qt_config)
diff --git a/mkspecs/unsupported/macx-iossimulator-llvm/qplatformdefs.h b/mkspecs/unsupported/macx-iossimulator-llvm/qplatformdefs.h
deleted file mode 100644
index 5f80a17860..0000000000
--- a/mkspecs/unsupported/macx-iossimulator-llvm/qplatformdefs.h
+++ /dev/null
@@ -1,42 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
-**
-** This file is part of the qmake spec of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and Digia. For licensing terms and
-** conditions see http://qt.digia.com/licensing. For further information
-** use the contact form at http://qt.digia.com/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 2.1 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-**
-** In addition, as a special exception, Digia gives you certain additional
-** rights. These rights are described in the Digia Qt LGPL Exception
-** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3.0 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU General Public License version 3.0 requirements will be
-** met: http://www.gnu.org/copyleft/gpl.html.
-**
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include "../../common/ios/qplatformdefs.h"
diff --git a/mkspecs/unsupported/qnx-X11-g++/qmake.conf b/mkspecs/unsupported/qnx-X11-g++/qmake.conf
index a5ee0b0e56..8d2c63f330 100644
--- a/mkspecs/unsupported/qnx-X11-g++/qmake.conf
+++ b/mkspecs/unsupported/qnx-X11-g++/qmake.conf
@@ -4,37 +4,36 @@
# Written for QNX RTOS v6 with X11
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = qnx
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = qnx
include(../common/gcc-base-unix.conf)
include(../common/g++-unix.conf)
include(../common/unix.conf)
-QMAKE_CFLAGS_THREAD = -D_REENTRANT
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CLFAGS_THREAD
-QMAKE_COMPILER_DEFINES += __QNXNTO__
-
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = /opt/X11R6/include
-QMAKE_LIBDIR_X11 = /opt/X11R6/lib
-QMAKE_INCDIR_OPENGL = /opt/X11R6/include
-QMAKE_LIBDIR_OPENGL = /opt/X11R6/lib
-
-#QMAKE_LIBS = -lunix
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11 -lm -lsocket
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD =
+QMAKE_CFLAGS_THREAD = -D_REENTRANT
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CLFAGS_THREAD
+QMAKE_COMPILER_DEFINES += __QNXNTO__
+
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = /opt/X11R6/include
+QMAKE_LIBDIR_X11 = /opt/X11R6/lib
+QMAKE_INCDIR_OPENGL = /opt/X11R6/include
+QMAKE_LIBDIR_OPENGL = /opt/X11R6/lib
+
+#QMAKE_LIBS = -lunix
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11 -lm -lsocket
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD =
QMAKE_LIBS_NETWORK = -lsocket
-QMAKE_AR = ar cqs
-QMAKE_RANLIB =
+QMAKE_AR = ar cqs
+QMAKE_RANLIB =
-QMAKE_STRIP = strip
-QMAKE_STRIPFLAGS_LIB += --strip-unneeded
+QMAKE_STRIP = strip
+QMAKE_STRIPFLAGS_LIB += --strip-unneeded
load(qt_config)
diff --git a/mkspecs/unsupported/vxworks-ppc-dcc/qmake.conf b/mkspecs/unsupported/vxworks-ppc-dcc/qmake.conf
index c5429aedf9..806484369b 100644
--- a/mkspecs/unsupported/vxworks-ppc-dcc/qmake.conf
+++ b/mkspecs/unsupported/vxworks-ppc-dcc/qmake.conf
@@ -2,58 +2,58 @@
# qmake configuration for vxworks-ppc-dcc
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = vxworks
-CONFIG += incremental
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = vxworks
+CONFIG += incremental
QMAKE_INCREMENTAL_STYLE = sublib
-VXWORKS_ARCH = ppc
-VXWORKS_CPU = PPC32
-VXWORKS_DIAB_SPEC = -tPPC7400FV:vxworks66
-VXWORKS_ARCH_MUNCH = ppc
-
-QMAKE_COMPILER = wr_dcc
-
-QMAKE_CC = dcc
-QMAKE_CFLAGS += $$VXWORKS_DIAB_SPEC -Xkeywords=0x0 -Xcode-absolute-far -Xansi -Xforce-declarations -I$(WIND_BASE)/target/h -I$(WIND_BASE)/target/h/wrn/coreip -DCPU=$$upper($$VXWORKS_ARCH) -DVX_CPU_FAMILY=$$VXWORKS_ARCH -DTOOL_FAMILY=diab -DTOOL=diab -D_WRS_KERNEL -DVXWORKS -D_VSB_CONFIG_FILE=\'<../lib/h/config/vsbConfig.h>\'
-QMAKE_CFLAGS_DEPS +=
-QMAKE_CFLAGS_WARN_ON +=
-QMAKE_CFLAGS_WARN_OFF += -Xsuppress-warnings
-QMAKE_CFLAGS_RELEASE +=
-QMAKE_CFLAGS_DEBUG += -g
-QMAKE_CFLAGS_SHLIB +=
-QMAKE_CFLAGS_STATIC_LIB +=
-QMAKE_CFLAGS_YACC +=
-QMAKE_CFLAGS_HIDESYMS +=
+VXWORKS_ARCH = ppc
+VXWORKS_CPU = PPC32
+VXWORKS_DIAB_SPEC = -tPPC7400FV:vxworks66
+VXWORKS_ARCH_MUNCH = ppc
+
+QMAKE_COMPILER = wr_dcc
+
+QMAKE_CC = dcc
+QMAKE_CFLAGS += $$VXWORKS_DIAB_SPEC -Xkeywords=0x0 -Xcode-absolute-far -Xansi -Xforce-declarations -I$(WIND_BASE)/target/h -I$(WIND_BASE)/target/h/wrn/coreip -DCPU=$$upper($$VXWORKS_ARCH) -DVX_CPU_FAMILY=$$VXWORKS_ARCH -DTOOL_FAMILY=diab -DTOOL=diab -D_WRS_KERNEL -DVXWORKS -D_VSB_CONFIG_FILE=\'<../lib/h/config/vsbConfig.h>\'
+QMAKE_CFLAGS_DEPS +=
+QMAKE_CFLAGS_WARN_ON +=
+QMAKE_CFLAGS_WARN_OFF += -Xsuppress-warnings
+QMAKE_CFLAGS_RELEASE +=
+QMAKE_CFLAGS_DEBUG += -g
+QMAKE_CFLAGS_SHLIB +=
+QMAKE_CFLAGS_STATIC_LIB +=
+QMAKE_CFLAGS_YACC +=
+QMAKE_CFLAGS_HIDESYMS +=
QMAKE_CFLAGS_PRECOMPILE +=
QMAKE_CFLAGS_USE_PRECOMPILE +=
-QMAKE_CXX = dcc
-QMAKE_CXXFLAGS += $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS += $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON += $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF += $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG += $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB += $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = dcc
+QMAKE_CXXFLAGS += $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS += $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON += $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF += $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG += $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB += $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB += $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC += $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_YACC += $$QMAKE_CFLAGS_YACC
QMAKE_CXXFLAGS_HIDESYMS += $$QMAKE_CFLAGS_HIDESYMS
QMAKE_CXXFLAGS_PRECOMPILE +=
QMAKE_CXXFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
-QMAKE_LINK = dld
-QMAKE_LINK_SHLIB = dld
-QMAKE_LFLAGS += $$VXWORKS_DIAB_SPEC
-QMAKE_LFLAGS_RELEASE +=
-QMAKE_LFLAGS_DEBUG +=
-QMAKE_LFLAGS_APP += -r5
-QMAKE_LFLAGS_SHLIB +=
-QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME +=
-QMAKE_LFLAGS_THREAD +=
-QMAKE_LFLAGS_NOUNDEF +=
-QMAKE_LFLAGS_RPATH =
+QMAKE_LINK = dld
+QMAKE_LINK_SHLIB = dld
+QMAKE_LFLAGS += $$VXWORKS_DIAB_SPEC
+QMAKE_LFLAGS_RELEASE +=
+QMAKE_LFLAGS_DEBUG +=
+QMAKE_LFLAGS_APP += -r5
+QMAKE_LFLAGS_SHLIB +=
+QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME +=
+QMAKE_LFLAGS_THREAD +=
+QMAKE_LFLAGS_NOUNDEF +=
+QMAKE_LFLAGS_RPATH =
QMAKE_PCH_OUTPUT_EXT = .gch
@@ -61,34 +61,33 @@ QMAKE_PCH_OUTPUT_EXT = .gch
QMAKE_LFLAGS_BSYMBOLIC_FUNC =
QMAKE_LFLAGS_DYNAMIC_LIST =
-QMAKE_CFLAGS_THREAD += -D_REENTRANT
-QMAKE_CXXFLAGS_THREAD += $$QMAKE_CFLAGS_THREAD
-
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = $(WIND_HOME)/GSS/include
-QMAKE_LIBDIR_X11 = $(WIND_HOME)/GSS/lib
-QMAKE_INCDIR_OPENGL = $$QMAKE_INCDIR_X11
-QMAKE_LIBDIR_OPENGL = $$QMAKE_LIBDIR_X11
-
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11
-QMAKE_LIBS_NIS = -lnsl
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD =
-QMAKE_LIBS_NETWORK = # -lnetwrap # only needed if kernel is missing gethostbyname and friends
-
-
-QMAKE_AR = ar cqs
-QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
-
-QMAKE_STRIP = strip
-QMAKE_STRIPFLAGS_LIB += --strip-unneeded
-QMAKE_INSTALL_FILE = install -m 644 -p
-QMAKE_INSTALL_PROGRAM = install -m 755 -p
+QMAKE_CFLAGS_THREAD += -D_REENTRANT
+QMAKE_CXXFLAGS_THREAD += $$QMAKE_CFLAGS_THREAD
+
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = $(WIND_HOME)/GSS/include
+QMAKE_LIBDIR_X11 = $(WIND_HOME)/GSS/lib
+QMAKE_INCDIR_OPENGL = $$QMAKE_INCDIR_X11
+QMAKE_LIBDIR_OPENGL = $$QMAKE_LIBDIR_X11
+
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11
+QMAKE_LIBS_NIS = -lnsl
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD =
+QMAKE_LIBS_NETWORK = # -lnetwrap # only needed if kernel is missing gethostbyname and friends
+
+
+QMAKE_AR = ar cqs
+QMAKE_OBJCOPY = objcopy
+QMAKE_RANLIB =
+
+QMAKE_STRIP = strip
+QMAKE_STRIPFLAGS_LIB += --strip-unneeded
+QMAKE_INSTALL_FILE = install -m 644 -p
+QMAKE_INSTALL_PROGRAM = install -m 755 -p
include(../../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/unsupported/vxworks-ppc-g++/qmake.conf b/mkspecs/unsupported/vxworks-ppc-g++/qmake.conf
index e659639ae4..1d3e9f4eb4 100644
--- a/mkspecs/unsupported/vxworks-ppc-g++/qmake.conf
+++ b/mkspecs/unsupported/vxworks-ppc-g++/qmake.conf
@@ -2,36 +2,36 @@
# qmake configuration for vxworks-simpentium-g++
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = vxworks
-CONFIG += incremental
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = vxworks
+CONFIG += incremental
QMAKE_INCREMENTAL_STYLE = sublib
-DEFINES += VXWORKS
+DEFINES += VXWORKS
-VXWORKS_ARCH = ppc
-VXWORKS_CPU = PPC32
-VXWORKS_ARCH_MUNCH = ppc
+VXWORKS_ARCH = ppc
+VXWORKS_CPU = PPC32
+VXWORKS_ARCH_MUNCH = ppc
include(../../common/gcc-base-unix.conf)
include(../../common/g++-unix.conf)
include(../../common/linux.conf)
-QMAKE_CC = cc$$VXWORKS_ARCH_MUNCH
-QMAKE_CFLAGS = -fno-builtin -I$(WIND_BASE)/target/h -I$(WIND_BASE)/target/h/wrn/coreip -DCPU=$$upper($$VXWORKS_ARCH) -DVX_CPU_FAMILY=$$VXWORKS_ARCH -DTOOL_FAMILY=gnu -DTOOL=gnu -D_WRS_KERNEL -D_VSB_CONFIG_FILE=\'<../lib/h/config/vsbConfig.h>\'
-QMAKE_CFLAGS_SHLIB = # remove -fPIC
-QMAKE_CFLAGS_STATIC_LIB = # remove -fPIC
-QMAKE_CXX = c++$$VXWORKS_ARCH_MUNCH
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_SHLIB= # remove -fPIC
-QMAKE_CXXFLAGS_STATIC_LIB= # remove -fPIC
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-QMAKE_LFLAGS_SHLIB = -Wl,-Ur -L $(WIND_BASE)/target/lib/$$VXWORKS_ARCH/$$VXWORKS_CPU/common # remove -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_APP += -Wl,-Ur -L $(WIND_BASE)/target/lib/$$VXWORKS_ARCH/$$VXWORKS_CPU/common
+QMAKE_CC = cc$$VXWORKS_ARCH_MUNCH
+QMAKE_CFLAGS = -fno-builtin -I$(WIND_BASE)/target/h -I$(WIND_BASE)/target/h/wrn/coreip -DCPU=$$upper($$VXWORKS_ARCH) -DVX_CPU_FAMILY=$$VXWORKS_ARCH -DTOOL_FAMILY=gnu -DTOOL=gnu -D_WRS_KERNEL -D_VSB_CONFIG_FILE=\'<../lib/h/config/vsbConfig.h>\'
+QMAKE_CFLAGS_SHLIB = # remove -fPIC
+QMAKE_CFLAGS_STATIC_LIB = # remove -fPIC
+QMAKE_CXX = c++$$VXWORKS_ARCH_MUNCH
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_SHLIB = # remove -fPIC
+QMAKE_CXXFLAGS_STATIC_LIB = # remove -fPIC
+QMAKE_LINK = $$QMAKE_CXX
+QMAKE_LINK_SHLIB = $$QMAKE_CXX
+QMAKE_LFLAGS_SHLIB = -Wl,-Ur -L $(WIND_BASE)/target/lib/$$VXWORKS_ARCH/$$VXWORKS_CPU/common # remove -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_APP += -Wl,-Ur -L $(WIND_BASE)/target/lib/$$VXWORKS_ARCH/$$VXWORKS_CPU/common
# QMAKE_LIBS_NETWORK = # -lnetwrap # only needed if kernel is missing gethostbyname() and friends
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_THREAD =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_THREAD =
load(qt_config)
diff --git a/mkspecs/unsupported/vxworks-simpentium-dcc/qmake.conf b/mkspecs/unsupported/vxworks-simpentium-dcc/qmake.conf
index 4729daf3e7..d349189878 100644
--- a/mkspecs/unsupported/vxworks-simpentium-dcc/qmake.conf
+++ b/mkspecs/unsupported/vxworks-simpentium-dcc/qmake.conf
@@ -2,58 +2,58 @@
# qmake configuration for vxworks-simpentium-dcc
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = vxworks
-CONFIG += incremental
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = vxworks
+CONFIG += incremental
QMAKE_INCREMENTAL_STYLE = sublib
-VXWORKS_ARCH = simlinux
-VXWORKS_CPU = SIMLINUX
-VXWORKS_DIAB_SPEC = -tX86LH:vxworks66
-VXWORKS_ARCH_MUNCH = pentium
+VXWORKS_ARCH = simlinux
+VXWORKS_CPU = SIMLINUX
+VXWORKS_DIAB_SPEC = -tX86LH:vxworks66
+VXWORKS_ARCH_MUNCH = pentium
-QMAKE_COMPILER = wr_dcc
+QMAKE_COMPILER = wr_dcc
-QMAKE_CC = dcc
-QMAKE_CFLAGS += $$VXWORKS_DIAB_SPEC -Xkeywords=0x0 -Xcode-absolute-far -Xansi -Xforce-declarations -I$(WIND_BASE)/target/h -I$(WIND_BASE)/target/h/wrn/coreip -DCPU=$$upper($$VXWORKS_ARCH) -DVX_CPU_FAMILY=$$VXWORKS_ARCH -DTOOL_FAMILY=diab -DTOOL=diab -D_WRS_KERNEL -DVXWORKS -D_VSB_CONFIG_FILE=\'<../lib/h/config/vsbConfig.h>\'
-QMAKE_CFLAGS_DEPS +=
-QMAKE_CFLAGS_WARN_ON +=
-QMAKE_CFLAGS_WARN_OFF += -Xsuppress-warnings
-QMAKE_CFLAGS_RELEASE +=
-QMAKE_CFLAGS_DEBUG += -g
-QMAKE_CFLAGS_SHLIB +=
-QMAKE_CFLAGS_STATIC_LIB +=
-QMAKE_CFLAGS_YACC +=
-QMAKE_CFLAGS_HIDESYMS +=
+QMAKE_CC = dcc
+QMAKE_CFLAGS += $$VXWORKS_DIAB_SPEC -Xkeywords=0x0 -Xcode-absolute-far -Xansi -Xforce-declarations -I$(WIND_BASE)/target/h -I$(WIND_BASE)/target/h/wrn/coreip -DCPU=$$upper($$VXWORKS_ARCH) -DVX_CPU_FAMILY=$$VXWORKS_ARCH -DTOOL_FAMILY=diab -DTOOL=diab -D_WRS_KERNEL -DVXWORKS -D_VSB_CONFIG_FILE=\'<../lib/h/config/vsbConfig.h>\'
+QMAKE_CFLAGS_DEPS +=
+QMAKE_CFLAGS_WARN_ON +=
+QMAKE_CFLAGS_WARN_OFF += -Xsuppress-warnings
+QMAKE_CFLAGS_RELEASE +=
+QMAKE_CFLAGS_DEBUG += -g
+QMAKE_CFLAGS_SHLIB +=
+QMAKE_CFLAGS_STATIC_LIB +=
+QMAKE_CFLAGS_YACC +=
+QMAKE_CFLAGS_HIDESYMS +=
QMAKE_CFLAGS_PRECOMPILE +=
QMAKE_CFLAGS_USE_PRECOMPILE +=
-QMAKE_CXX = dcc
-QMAKE_CXXFLAGS += $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS += $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON += $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF += $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG += $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_SHLIB += $$QMAKE_CFLAGS_SHLIB
+QMAKE_CXX = dcc
+QMAKE_CXXFLAGS += $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS += $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON += $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF += $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG += $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_SHLIB += $$QMAKE_CFLAGS_SHLIB
QMAKE_CXXFLAGS_STATIC_LIB += $$QMAKE_CFLAGS_STATIC_LIB
-QMAKE_CXXFLAGS_YACC += $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_YACC += $$QMAKE_CFLAGS_YACC
QMAKE_CXXFLAGS_HIDESYMS += $$QMAKE_CFLAGS_HIDESYMS
QMAKE_CXXFLAGS_PRECOMPILE +=
QMAKE_CXXFLAGS_USE_PRECOMPILE = $$QMAKE_CFLAGS_USE_PRECOMPILE
-QMAKE_LINK = dld
-QMAKE_LINK_SHLIB = dld
-QMAKE_LFLAGS += $$VXWORKS_DIAB_SPEC -L $(WIND_BASE)/target/lib/$$VXWORKS_ARCH/$$VXWORKS_CPU/common
-QMAKE_LFLAGS_RELEASE +=
-QMAKE_LFLAGS_DEBUG +=
-QMAKE_LFLAGS_APP += -r5
-QMAKE_LFLAGS_SHLIB +=
-QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_SONAME +=
-QMAKE_LFLAGS_THREAD +=
-QMAKE_LFLAGS_NOUNDEF +=
-QMAKE_LFLAGS_RPATH =
+QMAKE_LINK = dld
+QMAKE_LINK_SHLIB = dld
+QMAKE_LFLAGS += $$VXWORKS_DIAB_SPEC -L $(WIND_BASE)/target/lib/$$VXWORKS_ARCH/$$VXWORKS_CPU/common
+QMAKE_LFLAGS_RELEASE +=
+QMAKE_LFLAGS_DEBUG +=
+QMAKE_LFLAGS_APP += -r5
+QMAKE_LFLAGS_SHLIB +=
+QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_SONAME +=
+QMAKE_LFLAGS_THREAD +=
+QMAKE_LFLAGS_NOUNDEF +=
+QMAKE_LFLAGS_RPATH =
QMAKE_PCH_OUTPUT_EXT = .gch
@@ -61,33 +61,32 @@ QMAKE_PCH_OUTPUT_EXT = .gch
QMAKE_LFLAGS_BSYMBOLIC_FUNC =
QMAKE_LFLAGS_DYNAMIC_LIST =
-QMAKE_CFLAGS_THREAD += -D_REENTRANT
-QMAKE_CXXFLAGS_THREAD += $$QMAKE_CFLAGS_THREAD
+QMAKE_CFLAGS_THREAD += -D_REENTRANT
+QMAKE_CXXFLAGS_THREAD += $$QMAKE_CFLAGS_THREAD
-QMAKE_INCDIR =
-QMAKE_LIBDIR =
-QMAKE_INCDIR_X11 = $(WIND_HOME)/GSS/include
-QMAKE_LIBDIR_X11 = $(WIND_HOME)/GSS/lib
-QMAKE_INCDIR_OPENGL = $$QMAKE_INCDIR_X11
-QMAKE_LIBDIR_OPENGL = $$QMAKE_LIBDIR_X11
+QMAKE_INCDIR =
+QMAKE_LIBDIR =
+QMAKE_INCDIR_X11 = $(WIND_HOME)/GSS/include
+QMAKE_LIBDIR_X11 = $(WIND_HOME)/GSS/lib
+QMAKE_INCDIR_OPENGL = $$QMAKE_INCDIR_X11
+QMAKE_LIBDIR_OPENGL = $$QMAKE_LIBDIR_X11
-QMAKE_LIBS =
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_X11 = -lXext -lX11
-QMAKE_LIBS_NIS = -lnsl
-QMAKE_LIBS_OPENGL = -lGL
-QMAKE_LIBS_OPENGL_QT = -lGL
-QMAKE_LIBS_THREAD =
-QMAKE_LIBS_NETWORK = # -lnet # only needed if kernel is missing gethostbyname and friends
+QMAKE_LIBS =
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_X11 = -lXext -lX11
+QMAKE_LIBS_NIS = -lnsl
+QMAKE_LIBS_OPENGL = -lGL
+QMAKE_LIBS_THREAD =
+QMAKE_LIBS_NETWORK = # -lnet # only needed if kernel is missing gethostbyname and friends
-QMAKE_AR = ar cqs
-QMAKE_OBJCOPY = objcopy
-QMAKE_RANLIB =
+QMAKE_AR = ar cqs
+QMAKE_OBJCOPY = objcopy
+QMAKE_RANLIB =
-QMAKE_STRIP = strip
-QMAKE_STRIPFLAGS_LIB += --strip-unneeded
-QMAKE_INSTALL_FILE = install -m 644 -p
-QMAKE_INSTALL_PROGRAM = install -m 755 -p
+QMAKE_STRIP = strip
+QMAKE_STRIPFLAGS_LIB += --strip-unneeded
+QMAKE_INSTALL_FILE = install -m 644 -p
+QMAKE_INSTALL_PROGRAM = install -m 755 -p
include(../../common/unix.conf)
load(qt_config)
diff --git a/mkspecs/unsupported/vxworks-simpentium-g++/qmake.conf b/mkspecs/unsupported/vxworks-simpentium-g++/qmake.conf
index 3adfd1089e..3c8fd12d4a 100644
--- a/mkspecs/unsupported/vxworks-simpentium-g++/qmake.conf
+++ b/mkspecs/unsupported/vxworks-simpentium-g++/qmake.conf
@@ -2,36 +2,36 @@
# qmake configuration for vxworks-simpentium-g++
#
-MAKEFILE_GENERATOR = UNIX
-QMAKE_PLATFORM = vxworks
-CONFIG += incremental
+MAKEFILE_GENERATOR = UNIX
+QMAKE_PLATFORM = vxworks
+CONFIG += incremental
QMAKE_INCREMENTAL_STYLE = sublib
-DEFINES += VXWORKS
+DEFINES += VXWORKS
-VXWORKS_ARCH = simlinux
-VXWORKS_CPU = SIMLINUX
-VXWORKS_ARCH_MUNCH = pentium
+VXWORKS_ARCH = simlinux
+VXWORKS_CPU = SIMLINUX
+VXWORKS_ARCH_MUNCH = pentium
include(../../common/gcc-base-unix.conf)
include(../../common/g++-unix.conf)
include(../../common/linux.conf)
-QMAKE_CC = cc$$VXWORKS_ARCH_MUNCH
-QMAKE_CFLAGS = -fno-builtin -I$(WIND_BASE)/target/h -I$(WIND_BASE)/target/h/wrn/coreip -DCPU=$$upper($$VXWORKS_ARCH) -DVX_CPU_FAMILY=$$VXWORKS_ARCH -DTOOL_FAMILY=gnu -DTOOL=gnu -D_WRS_KERNEL -D_VSB_CONFIG_FILE=\'<../lib/h/config/vsbConfig.h>\'
-QMAKE_CFLAGS_SHLIB = # remove -fPIC
-QMAKE_CFLAGS_STATIC_LIB = # remove -fPIC
-QMAKE_CXX = c++$$VXWORKS_ARCH_MUNCH
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_SHLIB= # remove -fPIC
-QMAKE_CXXFLAGS_STATIC_LIB= # remove -fPIC
-QMAKE_LINK = $$QMAKE_CXX
-QMAKE_LINK_SHLIB = $$QMAKE_CXX
-QMAKE_LFLAGS_SHLIB = -Wl,-Ur -L $(WIND_BASE)/target/lib/$$VXWORKS_ARCH/$$VXWORKS_CPU/common # remove -shared
-QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
-QMAKE_LFLAGS_APP += -Wl,-Ur -L $(WIND_BASE)/target/lib/$$VXWORKS_ARCH/$$VXWORKS_CPU/common
-QMAKE_LIBS_NETWORK = # -lnetwrap # only needed if kernel is missing gethostbyname() and friends
-QMAKE_LIBS_DYNLOAD =
-QMAKE_LIBS_THREAD =
+QMAKE_CC = cc$$VXWORKS_ARCH_MUNCH
+QMAKE_CFLAGS = -fno-builtin -I$(WIND_BASE)/target/h -I$(WIND_BASE)/target/h/wrn/coreip -DCPU=$$upper($$VXWORKS_ARCH) -DVX_CPU_FAMILY=$$VXWORKS_ARCH -DTOOL_FAMILY=gnu -DTOOL=gnu -D_WRS_KERNEL -D_VSB_CONFIG_FILE=\'<../lib/h/config/vsbConfig.h>\'
+QMAKE_CFLAGS_SHLIB = # remove -fPIC
+QMAKE_CFLAGS_STATIC_LIB = # remove -fPIC
+QMAKE_CXX = c++$$VXWORKS_ARCH_MUNCH
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_SHLIB = # remove -fPIC
+QMAKE_CXXFLAGS_STATIC_LIB = # remove -fPIC
+QMAKE_LINK = $$QMAKE_CXX
+QMAKE_LINK_SHLIB = $$QMAKE_CXX
+QMAKE_LFLAGS_SHLIB = -Wl,-Ur -L $(WIND_BASE)/target/lib/$$VXWORKS_ARCH/$$VXWORKS_CPU/common # remove -shared
+QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB
+QMAKE_LFLAGS_APP += -Wl,-Ur -L $(WIND_BASE)/target/lib/$$VXWORKS_ARCH/$$VXWORKS_CPU/common
+QMAKE_LIBS_NETWORK = # -lnetwrap # only needed if kernel is missing gethostbyname() and friends
+QMAKE_LIBS_DYNLOAD =
+QMAKE_LIBS_THREAD =
load(qt_config)
diff --git a/mkspecs/unsupported/win32-msvc2003/qmake.conf b/mkspecs/unsupported/win32-msvc2003/qmake.conf
index e510b74738..a65a9929c3 100644
--- a/mkspecs/unsupported/win32-msvc2003/qmake.conf
+++ b/mkspecs/unsupported/win32-msvc2003/qmake.conf
@@ -6,11 +6,11 @@
MAKEFILE_GENERATOR = MSVC.NET
QMAKE_PLATFORM = win32
-CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target
-DEFINES += UNICODE WIN32
-QMAKE_COMPILER_DEFINES += _MSC_VER=1310 WIN32
+CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target
+DEFINES += UNICODE WIN32
+QMAKE_COMPILER_DEFINES += _MSC_VER=1310 WIN32
-QMAKE_COMPILER = msvc
+QMAKE_COMPILER = msvc
QMAKE_CC = cl
QMAKE_LEX = flex
@@ -74,5 +74,5 @@ include(../../common/shell-win32.conf)
VCPROJ_EXTENSION = .vcproj
VCSOLUTION_EXTENSION = .sln
-VCPROJ_KEYWORD = Qt4VSv1.0
+VCPROJ_KEYWORD = Qt4VSv1.0
load(qt_config)
diff --git a/mkspecs/win32-g++/qmake.conf b/mkspecs/win32-g++/qmake.conf
index d46294b2b1..22277e1e82 100644
--- a/mkspecs/win32-g++/qmake.conf
+++ b/mkspecs/win32-g++/qmake.conf
@@ -9,29 +9,29 @@
load(device_config)
-MAKEFILE_GENERATOR = MINGW
-QMAKE_PLATFORM = win32 mingw
-CONFIG += debug_and_release debug_and_release_target precompile_header
-DEFINES += UNICODE
-QMAKE_COMPILER_DEFINES += __GNUC__ WIN32
+MAKEFILE_GENERATOR = MINGW
+QMAKE_PLATFORM = win32 mingw
+CONFIG += debug_and_release debug_and_release_target precompile_header
+DEFINES += UNICODE
+QMAKE_COMPILER_DEFINES += __GNUC__ WIN32
QMAKE_EXT_OBJ = .o
QMAKE_EXT_RES = _res.o
-QMAKE_COMPILER = gcc
+QMAKE_COMPILER = gcc
-QMAKE_CC = $${CROSS_COMPILE}gcc
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = byacc
-QMAKE_YACCFLAGS = -d
+QMAKE_CC = $${CROSS_COMPILE}gcc
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = byacc
+QMAKE_YACCFLAGS = -d
QMAKE_CFLAGS = -pipe -fno-keep-inline-dllexport
-QMAKE_CFLAGS_DEPS = -M
-QMAKE_CFLAGS_WARN_ON = -Wall -Wextra
-QMAKE_CFLAGS_WARN_OFF = -w
-QMAKE_CFLAGS_RELEASE = -O2
-QMAKE_CFLAGS_DEBUG = -g
-QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
+QMAKE_CFLAGS_DEPS = -M
+QMAKE_CFLAGS_WARN_ON = -Wall -Wextra
+QMAKE_CFLAGS_WARN_OFF = -w
+QMAKE_CFLAGS_RELEASE = -O2
+QMAKE_CFLAGS_DEBUG = -g
+QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses
QMAKE_CFLAGS_SSE2 = -msse2
QMAKE_CFLAGS_SSE3 = -msse3
QMAKE_CFLAGS_SSSE3 = -mssse3
@@ -42,45 +42,45 @@ QMAKE_CFLAGS_AVX2 = -mavx2
QMAKE_CFLAGS_IWMMXT = -mcpu=iwmmxt
QMAKE_CFLAGS_NEON = -mfpu=neon
-QMAKE_CXX = $${CROSS_COMPILE}g++
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
-QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
-QMAKE_CXXFLAGS_RTTI_ON = -frtti
-QMAKE_CXXFLAGS_RTTI_OFF = -fno-rtti
+QMAKE_CXX = $${CROSS_COMPILE}g++
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS
+QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD
+QMAKE_CXXFLAGS_RTTI_ON = -frtti
+QMAKE_CXXFLAGS_RTTI_OFF = -fno-rtti
QMAKE_CXXFLAGS_EXCEPTIONS_ON = -fexceptions -mthreads
QMAKE_CXXFLAGS_EXCEPTIONS_OFF = -fno-exceptions
QMAKE_CXXFLAGS_CXX11 = -std=c++0x
-QMAKE_INCDIR =
+QMAKE_INCDIR =
-QMAKE_RUN_CC = $(CC) -c $(CFLAGS) $(INCPATH) -o $obj $src
-QMAKE_RUN_CC_IMP = $(CC) -c $(CFLAGS) $(INCPATH) -o $@ $<
-QMAKE_RUN_CXX = $(CXX) -c $(CXXFLAGS) $(INCPATH) -o $obj $src
-QMAKE_RUN_CXX_IMP = $(CXX) -c $(CXXFLAGS) $(INCPATH) -o $@ $<
+QMAKE_RUN_CC = $(CC) -c $(CFLAGS) $(INCPATH) -o $obj $src
+QMAKE_RUN_CC_IMP = $(CC) -c $(CFLAGS) $(INCPATH) -o $@ $<
+QMAKE_RUN_CXX = $(CXX) -c $(CXXFLAGS) $(INCPATH) -o $obj $src
+QMAKE_RUN_CXX_IMP = $(CXX) -c $(CXXFLAGS) $(INCPATH) -o $@ $<
-QMAKE_LINK = $${CROSS_COMPILE}g++
-QMAKE_LINK_C = $${CROSS_COMPILE}gcc
-QMAKE_LFLAGS =
+QMAKE_LINK = $${CROSS_COMPILE}g++
+QMAKE_LINK_C = $${CROSS_COMPILE}gcc
+QMAKE_LFLAGS =
QMAKE_LFLAGS_EXCEPTIONS_ON = -mthreads
QMAKE_LFLAGS_EXCEPTIONS_OFF =
-QMAKE_LFLAGS_RELEASE = -Wl,-s
-QMAKE_LFLAGS_DEBUG =
-QMAKE_LFLAGS_CONSOLE = -Wl,-subsystem,console
-QMAKE_LFLAGS_WINDOWS = -Wl,-subsystem,windows
+QMAKE_LFLAGS_RELEASE = -Wl,-s
+QMAKE_LFLAGS_DEBUG =
+QMAKE_LFLAGS_CONSOLE = -Wl,-subsystem,console
+QMAKE_LFLAGS_WINDOWS = -Wl,-subsystem,windows
QMAKE_LFLAGS_DLL = -shared
QMAKE_LFLAGS_CXX11 =
-QMAKE_LINK_OBJECT_MAX = 10
-QMAKE_LINK_OBJECT_SCRIPT= object_script
+QMAKE_LINK_OBJECT_MAX = 10
+QMAKE_LINK_OBJECT_SCRIPT = object_script
QMAKE_PREFIX_STATICLIB = lib
QMAKE_EXTENSION_STATICLIB = a
-QMAKE_LIBS =
+QMAKE_LIBS =
QMAKE_LIBS_CORE = -lole32 -luuid -lws2_32 -ladvapi32 -lshell32 -luser32 -lkernel32
QMAKE_LIBS_GUI = -lgdi32 -lcomdlg32 -loleaut32 -limm32 -lwinmm -lws2_32 -lole32 -luuid -luser32 -ladvapi32
QMAKE_LIBS_NETWORK = -lws2_32
@@ -92,16 +92,16 @@ QMAKE_LIBS_QT_ENTRY = -lmingw32 -lqtmain
!isEmpty(QMAKE_SH) {
MINGW_IN_SHELL = 1
- QMAKE_DIR_SEP = /
+ QMAKE_DIR_SEP = /
include(../common/shell-unix.conf)
} else {
include(../common/shell-win32.conf)
}
-QMAKE_IDL = midl
-QMAKE_LIB = $${CROSS_COMPILE}ar -ru
-QMAKE_RC = $${CROSS_COMPILE}windres
+QMAKE_IDL = midl
+QMAKE_LIB = $${CROSS_COMPILE}ar -ru
+QMAKE_RC = $${CROSS_COMPILE}windres
-QMAKE_STRIP = $${CROSS_COMPILE}strip
-QMAKE_STRIPFLAGS_LIB += --strip-unneeded
+QMAKE_STRIP = $${CROSS_COMPILE}strip
+QMAKE_STRIPFLAGS_LIB += --strip-unneeded
load(qt_config)
diff --git a/mkspecs/win32-g++/qplatformdefs.h b/mkspecs/win32-g++/qplatformdefs.h
index 736b69073a..4f339cbea6 100644
--- a/mkspecs/win32-g++/qplatformdefs.h
+++ b/mkspecs/win32-g++/qplatformdefs.h
@@ -65,16 +65,16 @@
#if !defined(_WIN32_WINNT) || (_WIN32_WINNT-0 < 0x0500)
typedef enum {
- NameUnknown = 0,
- NameFullyQualifiedDN = 1,
- NameSamCompatible = 2,
- NameDisplay = 3,
- NameUniqueId = 6,
- NameCanonical = 7,
- NameUserPrincipal = 8,
- NameCanonicalEx = 9,
- NameServicePrincipal = 10,
- NameDnsDomain = 12
+ NameUnknown = 0,
+ NameFullyQualifiedDN = 1,
+ NameSamCompatible = 2,
+ NameDisplay = 3,
+ NameUniqueId = 6,
+ NameCanonical = 7,
+ NameUserPrincipal = 8,
+ NameCanonicalEx = 9,
+ NameServicePrincipal = 10,
+ NameDnsDomain = 12
} EXTENDED_NAME_FORMAT, *PEXTENDED_NAME_FORMAT;
#endif
diff --git a/mkspecs/win32-icc/qmake.conf b/mkspecs/win32-icc/qmake.conf
index 9777a092f8..1ee07c64b6 100644
--- a/mkspecs/win32-icc/qmake.conf
+++ b/mkspecs/win32-icc/qmake.conf
@@ -4,73 +4,72 @@
# Written for Intel C++
#
-MAKEFILE_GENERATOR = MSVC.NET
-QMAKE_PLATFORM = win32
-CONFIG += incremental flat debug_and_release debug_and_release_target
-DEFINES += UNICODE
-QMAKE_COMPILER_DEFINES += __INTEL_COMPILER WIN32
+MAKEFILE_GENERATOR = MSVC.NET
+QMAKE_PLATFORM = win32
+CONFIG += incremental flat debug_and_release debug_and_release_target
+DEFINES += UNICODE
+QMAKE_COMPILER_DEFINES += __INTEL_COMPILER WIN32
-QMAKE_COMPILER = msvc intel_icl # icl pretends to be msvc
+QMAKE_COMPILER = msvc intel_icl # icl pretends to be msvc
-QMAKE_CC = icl
-QMAKE_LEX = flex
-QMAKE_LEXFLAGS =
-QMAKE_YACC = byacc
-QMAKE_YACCFLAGS = -d
-QMAKE_CFLAGS = -nologo -Zm200 /Qprec /Qwd1744,1738
-QMAKE_CFLAGS_WARN_ON = -W3 /Qwd673
-QMAKE_CFLAGS_WARN_OFF = -W0 /Qwd673
-QMAKE_CFLAGS_RELEASE = -O2 -MD
+QMAKE_CC = icl
+QMAKE_LEX = flex
+QMAKE_LEXFLAGS =
+QMAKE_YACC = byacc
+QMAKE_YACCFLAGS = -d
+QMAKE_CFLAGS = -nologo -Zm200 /Qprec /Qwd1744,1738
+QMAKE_CFLAGS_WARN_ON = -W3 /Qwd673
+QMAKE_CFLAGS_WARN_OFF = -W0 /Qwd673
+QMAKE_CFLAGS_RELEASE = -O2 -MD
# Giving -O2 to debug builds should make icc 9.1 happy, but it might make debugging harder, so it might be reverted.
# This is actually a workaround for a bug in icc 9.1.
-QMAKE_CFLAGS_DEBUG = -Zi -MDd -O2
-QMAKE_CFLAGS_YACC =
+QMAKE_CFLAGS_DEBUG = -Zi -MDd -O2
+QMAKE_CFLAGS_YACC =
-QMAKE_CXX = $$QMAKE_CC
-QMAKE_CXXFLAGS = $$QMAKE_CFLAGS /Zc:forScope
-QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
-QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
-QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
-QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
-QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
-QMAKE_CXXFLAGS_STL_ON = -GX
-QMAKE_CXXFLAGS_STL_OFF =
-QMAKE_CXXFLAGS_RTTI_ON = -GR
-QMAKE_CXXFLAGS_RTTI_OFF =
+QMAKE_CXX = $$QMAKE_CC
+QMAKE_CXXFLAGS = $$QMAKE_CFLAGS /Zc:forScope
+QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON
+QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG
+QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC
+QMAKE_CXXFLAGS_STL_ON = -GX
+QMAKE_CXXFLAGS_STL_OFF =
+QMAKE_CXXFLAGS_RTTI_ON = -GR
+QMAKE_CXXFLAGS_RTTI_OFF =
QMAKE_CXXFLAGS_EXCEPTIONS_ON = -GX
QMAKE_CXXFLAGS_EXCEPTIONS_OFF =
-QMAKE_INCDIR =
+QMAKE_INCDIR =
-QMAKE_RUN_CC = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$obj $src
-QMAKE_RUN_CC_IMP = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$@ $<
-QMAKE_RUN_CC_IMP_BATCH = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$@ @<<
-QMAKE_RUN_CXX = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$obj $src
-QMAKE_RUN_CXX_IMP = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$@ $<
-QMAKE_RUN_CXX_IMP_BATCH = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$@ @<<
+QMAKE_RUN_CC = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$obj $src
+QMAKE_RUN_CC_IMP = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$@ $<
+QMAKE_RUN_CC_IMP_BATCH = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$@ @<<
+QMAKE_RUN_CXX = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$obj $src
+QMAKE_RUN_CXX_IMP = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$@ $<
+QMAKE_RUN_CXX_IMP_BATCH = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$@ @<<
-QMAKE_LINK = xilink
-QMAKE_LFLAGS = /NOLOGO
-QMAKE_LFLAGS_RELEASE =
-QMAKE_LFLAGS_DEBUG = /DEBUG
-QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:console
-QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:windows
+QMAKE_LINK = xilink
+QMAKE_LFLAGS = /NOLOGO
+QMAKE_LFLAGS_RELEASE =
+QMAKE_LFLAGS_DEBUG = /DEBUG
+QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:console
+QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:windows
QMAKE_LFLAGS_DLL = /DLL
-QMAKE_LFLAGS_QT_DLL = /BASE:0x39D00000
-QMAKE_LIBS =
+QMAKE_LIBS =
QMAKE_LIBS_CORE = kernel32.lib user32.lib shell32.lib uuid.lib ole32.lib advapi32.lib ws2_32.lib
QMAKE_LIBS_GUI = gdi32.lib comdlg32.lib oleaut32.lib imm32.lib winmm.lib ws2_32.lib ole32.lib user32.lib advapi32.lib
QMAKE_LIBS_NETWORK = ws2_32.lib
QMAKE_LIBS_OPENGL = glu32.lib opengl32.lib gdi32.lib user32.lib delayimp.lib
QMAKE_LIBS_COMPAT = advapi32.lib shell32.lib comdlg32.lib user32.lib gdi32.lib ws2_32.lib
-QMAKE_LIBS_QT_ENTRY = -lqtmain
+QMAKE_LIBS_QT_ENTRY = -lqtmain
-QMAKE_IDL = midl
-QMAKE_LIB = xilib /NOLOGO
-QMAKE_RC = rc
+QMAKE_IDL = midl
+QMAKE_LIB = xilib /NOLOGO
+QMAKE_RC = rc
include(../common/shell-win32.conf)
-DSP_EXTENSION = .dsp
+DSP_EXTENSION = .dsp
load(qt_config)
diff --git a/mkspecs/win32-msvc2005/qmake.conf b/mkspecs/win32-msvc2005/qmake.conf
index 10f435b640..6d072242c9 100644
--- a/mkspecs/win32-msvc2005/qmake.conf
+++ b/mkspecs/win32-msvc2005/qmake.conf
@@ -6,11 +6,11 @@
MAKEFILE_GENERATOR = MSVC.NET
QMAKE_PLATFORM = win32
-CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target embed_manifest_dll embed_manifest_exe
-DEFINES += UNICODE WIN32
-QMAKE_COMPILER_DEFINES += _MSC_VER=1400 WIN32
+CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target embed_manifest_dll embed_manifest_exe
+DEFINES += UNICODE WIN32
+QMAKE_COMPILER_DEFINES += _MSC_VER=1400 WIN32
-QMAKE_COMPILER = msvc
+QMAKE_COMPILER = msvc
QMAKE_CC = cl
QMAKE_LEX = flex
@@ -86,5 +86,5 @@ include(../common/shell-win32.conf)
VCPROJ_EXTENSION = .vcproj
VCSOLUTION_EXTENSION = .sln
-VCPROJ_KEYWORD = Qt4VSv1.0
+VCPROJ_KEYWORD = Qt4VSv1.0
load(qt_config)
diff --git a/mkspecs/win32-msvc2008/qmake.conf b/mkspecs/win32-msvc2008/qmake.conf
index 348f5fb870..bd9a83a5d1 100644
--- a/mkspecs/win32-msvc2008/qmake.conf
+++ b/mkspecs/win32-msvc2008/qmake.conf
@@ -6,11 +6,11 @@
MAKEFILE_GENERATOR = MSVC.NET
QMAKE_PLATFORM = win32
-CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target embed_manifest_dll embed_manifest_exe
-DEFINES += UNICODE WIN32
-QMAKE_COMPILER_DEFINES += _MSC_VER=1500 WIN32
+CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target embed_manifest_dll embed_manifest_exe
+DEFINES += UNICODE WIN32
+QMAKE_COMPILER_DEFINES += _MSC_VER=1500 WIN32
-QMAKE_COMPILER = msvc
+QMAKE_COMPILER = msvc
QMAKE_CC = cl
QMAKE_LEX = flex
@@ -88,5 +88,5 @@ include(../common/shell-win32.conf)
VCPROJ_EXTENSION = .vcproj
VCSOLUTION_EXTENSION = .sln
-VCPROJ_KEYWORD = Qt4VSv1.0
+VCPROJ_KEYWORD = Qt4VSv1.0
load(qt_config)
diff --git a/mkspecs/win32-msvc2010/qmake.conf b/mkspecs/win32-msvc2010/qmake.conf
index de1edfa36a..f0e44078f9 100644
--- a/mkspecs/win32-msvc2010/qmake.conf
+++ b/mkspecs/win32-msvc2010/qmake.conf
@@ -6,11 +6,11 @@
MAKEFILE_GENERATOR = MSBUILD
QMAKE_PLATFORM = win32
-CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target embed_manifest_dll embed_manifest_exe
-DEFINES += UNICODE WIN32
-QMAKE_COMPILER_DEFINES += _MSC_VER=1600 WIN32
+CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target embed_manifest_dll embed_manifest_exe
+DEFINES += UNICODE WIN32
+QMAKE_COMPILER_DEFINES += _MSC_VER=1600 WIN32
-QMAKE_COMPILER = msvc
+QMAKE_COMPILER = msvc
QMAKE_CC = cl
QMAKE_LEX = flex
@@ -90,5 +90,5 @@ include(../common/shell-win32.conf)
VCPROJ_EXTENSION = .vcxproj
VCSOLUTION_EXTENSION = .sln
-VCPROJ_KEYWORD = Qt4VSv1.0
+VCPROJ_KEYWORD = Qt4VSv1.0
load(qt_config)
diff --git a/mkspecs/win32-msvc2012/qmake.conf b/mkspecs/win32-msvc2012/qmake.conf
index 8a595d16b1..c9e3f8c8e0 100644
--- a/mkspecs/win32-msvc2012/qmake.conf
+++ b/mkspecs/win32-msvc2012/qmake.conf
@@ -5,11 +5,11 @@
#
MAKEFILE_GENERATOR = MSBUILD
-CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target embed_manifest_dll embed_manifest_exe
-DEFINES += UNICODE WIN32
-QMAKE_COMPILER_DEFINES += _MSC_VER=1700 WIN32
+CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target embed_manifest_dll embed_manifest_exe
+DEFINES += UNICODE WIN32
+QMAKE_COMPILER_DEFINES += _MSC_VER=1700 WIN32
-QMAKE_COMPILER = msvc
+QMAKE_COMPILER = msvc
QMAKE_CC = cl
QMAKE_LEX = flex
@@ -89,5 +89,5 @@ include(../common/shell-win32.conf)
VCPROJ_EXTENSION = .vcxproj
VCSOLUTION_EXTENSION = .sln
-VCPROJ_KEYWORD = Qt4VSv1.0
+VCPROJ_KEYWORD = Qt4VSv1.0
load(qt_config)
diff --git a/mkspecs/wince50standard-armv4i-msvc2005/qmake.conf b/mkspecs/wince50standard-armv4i-msvc2005/qmake.conf
index 28ca6a6448..5883c75579 100644
--- a/mkspecs/wince50standard-armv4i-msvc2005/qmake.conf
+++ b/mkspecs/wince50standard-armv4i-msvc2005/qmake.conf
@@ -5,10 +5,10 @@
#
include(../common/wince/qmake.conf)
-CE_SDK = STANDARDSDK_500
-CE_ARCH = ARMV4I
+CE_SDK = STANDARDSDK_500
+CE_ARCH = ARMV4I
-DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x500 $$CE_ARCH _ARMV4I_ armv4i _ARM_ ARM _M_ARM ARM __arm__ Q_OS_WINCE_STD QT_NO_PRINTER QT_NO_PRINTDIALOG
+DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x500 $$CE_ARCH _ARMV4I_ armv4i _ARM_ ARM _M_ARM ARM __arm__ Q_OS_WINCE_STD QT_NO_PRINTER QT_NO_PRINTDIALOG
QMAKE_CFLAGS += -QRarch4T -QRinterwork-return
diff --git a/mkspecs/wince50standard-mipsii-msvc2005/qmake.conf b/mkspecs/wince50standard-mipsii-msvc2005/qmake.conf
index 0cc1ab03a0..40ef0566ae 100644
--- a/mkspecs/wince50standard-mipsii-msvc2005/qmake.conf
+++ b/mkspecs/wince50standard-mipsii-msvc2005/qmake.conf
@@ -5,13 +5,13 @@
#
include(../common/wince/qmake.conf)
-CE_SDK = STANDARDSDK_500
-CE_ARCH = MIPSII
+CE_SDK = STANDARDSDK_500
+CE_ARCH = MIPSII
-DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x500 _M_MRX000=3000 MIPS _MIPS_ Q_OS_WINCE_STD QT_NO_PRINTER QT_NO_PRINTDIALOG
+DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x500 _M_MRX000=3000 MIPS _MIPS_ Q_OS_WINCE_STD QT_NO_PRINTER QT_NO_PRINTDIALOG
-QMAKE_CFLAGS += -QMmips2
-QMAKE_CXXFLAGS += -QMmips2
+QMAKE_CFLAGS += -QMmips2
+QMAKE_CXXFLAGS += -QMmips2
QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,5.00 /MACHINE:MIPS /ENTRY:mainACRTStartup
QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,5.00 /MACHINE:MIPS
diff --git a/mkspecs/wince50standard-mipsiv-msvc2005/qmake.conf b/mkspecs/wince50standard-mipsiv-msvc2005/qmake.conf
index a22505c14d..b94f3f35d9 100644
--- a/mkspecs/wince50standard-mipsiv-msvc2005/qmake.conf
+++ b/mkspecs/wince50standard-mipsiv-msvc2005/qmake.conf
@@ -5,10 +5,10 @@
#
include(../common/wince/qmake.conf)
-CE_SDK = STANDARDSDK_500
-CE_ARCH = MIPSIV
+CE_SDK = STANDARDSDK_500
+CE_ARCH = MIPSIV
-DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x500 _M_MRX000=4000 MIPS _MIPS_ Q_OS_WINCE_STD QT_NO_PRINTER QT_NO_PRINTDIALOG MIPS_HAS_FPU
+DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x500 _M_MRX000=4000 MIPS _MIPS_ Q_OS_WINCE_STD QT_NO_PRINTER QT_NO_PRINTDIALOG MIPS_HAS_FPU
QMAKE_CFLAGS += -QMmips4
QMAKE_CXXFLAGS += -QMmips4
diff --git a/mkspecs/wince50standard-sh4-msvc2005/qmake.conf b/mkspecs/wince50standard-sh4-msvc2005/qmake.conf
index 1ee8950a44..3fdfdbfe43 100644
--- a/mkspecs/wince50standard-sh4-msvc2005/qmake.conf
+++ b/mkspecs/wince50standard-sh4-msvc2005/qmake.conf
@@ -5,10 +5,10 @@
#
include(../common/wince/qmake.conf)
-CE_SDK = STANDARDSDK_500
-CE_ARCH = SH4
+CE_SDK = STANDARDSDK_500
+CE_ARCH = SH4
-DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x500 _M_SH SHx _SHX_ Q_OS_WINCE_STD QT_NO_PRINTER QT_NO_PRINTDIALOG
+DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x500 _M_SH SHx _SHX_ Q_OS_WINCE_STD QT_NO_PRINTER QT_NO_PRINTDIALOG
QMAKE_CFLAGS = -nologo -Zm200 -Zc:wchar_t- -QSsh4
diff --git a/mkspecs/wince50standard-x86-msvc2005/qmake.conf b/mkspecs/wince50standard-x86-msvc2005/qmake.conf
index 2fa7556a29..850711d4c1 100644
--- a/mkspecs/wince50standard-x86-msvc2005/qmake.conf
+++ b/mkspecs/wince50standard-x86-msvc2005/qmake.conf
@@ -5,13 +5,13 @@
#
include(../common/wince/qmake.conf)
-CE_SDK = STANDARDSDK_500
-CE_ARCH = x86
+CE_SDK = STANDARDSDK_500
+CE_ARCH = x86
-DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x500 $$CE_ARCH _X86_ _M_IX86 Q_OS_WINCE_STD QT_NO_PRINTER QT_NO_PRINTDIALOG
+DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x500 $$CE_ARCH _X86_ _M_IX86 Q_OS_WINCE_STD QT_NO_PRINTER QT_NO_PRINTDIALOG
QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,5.00 /MACHINE:X86 /ENTRY:mainACRTStartup
-QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,5.00 /MACHINE:X86
+QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,5.00 /MACHINE:X86
QMAKE_LFLAGS_DLL = /SUBSYSTEM:WINDOWSCE,5.00 /MACHINE:X86 /DLL /SAFESEH:NO
QMAKE_LIBFLAGS = $$QMAKE_LFLAGS_WINDOWS
QMAKE_LIBFLAGS_RELEASE = /LTCG
diff --git a/mkspecs/wince60standard-armv4i-msvc2005/qmake.conf b/mkspecs/wince60standard-armv4i-msvc2005/qmake.conf
index 3bb18af3c2..3460e28fa4 100644
--- a/mkspecs/wince60standard-armv4i-msvc2005/qmake.conf
+++ b/mkspecs/wince60standard-armv4i-msvc2005/qmake.conf
@@ -7,21 +7,21 @@
include(../common/wince/qmake.conf)
-CE_SDK = STANDARDSDK_600 # replace with actual SDK name
-CE_ARCH = ARMV4I
+CE_SDK = STANDARDSDK_600 # replace with actual SDK name
+CE_ARCH = ARMV4I
-DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x600 $$CE_ARCH _ARMV4I_ armv4i _ARM_ ARM _M_ARM ARM _WIN32 __arm__
+DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x600 $$CE_ARCH _ARMV4I_ armv4i _ARM_ ARM _M_ARM ARM _WIN32 __arm__
-QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,6.00 /MACHINE:THUMB /ENTRY:mainACRTStartup
-QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,6.00 /MACHINE:THUMB
+QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,6.00 /MACHINE:THUMB /ENTRY:mainACRTStartup
+QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,6.00 /MACHINE:THUMB
QMAKE_LFLAGS_DLL = /SUBSYSTEM:WINDOWSCE,6.00 /MACHINE:THUMB /DLL /SAFESEH:NO
-QMAKE_LIBFLAGS_RELEASE = /LTCG
+QMAKE_LIBFLAGS_RELEASE = /LTCG
QMAKE_LIBS = corelibc.lib coredll.lib
QMAKE_LIBS_CORE = libcmt.lib corelibc.lib ole32.lib oleaut32.lib uuid.lib commctrl.lib coredll.lib winsock.lib
QMAKE_LIBS_GUI = ceshell.lib ole32.lib $$QMAKE_LIBS_CORE
QMAKE_LIBS_NETWORK = ws2.lib $$QMAKE_LIBS_GUI
-QMAKE_LIBS_OPENGL =
-QMAKE_LIBS_COMPAT =
+QMAKE_LIBS_OPENGL =
+QMAKE_LIBS_COMPAT =
-QMAKE_RC = rc /DUNDER_CE=600 /D_WIN32_WCE=0x600
+QMAKE_RC = rc /DUNDER_CE=600 /D_WIN32_WCE=0x600
diff --git a/mkspecs/wince60standard-x86-msvc2005/qmake.conf b/mkspecs/wince60standard-x86-msvc2005/qmake.conf
index 2896c69a02..4314483f7f 100644
--- a/mkspecs/wince60standard-x86-msvc2005/qmake.conf
+++ b/mkspecs/wince60standard-x86-msvc2005/qmake.conf
@@ -7,10 +7,10 @@
include(../common/wince/qmake.conf)
-CE_SDK = STANDARDSDK_600 # replace with actual SDK name
-CE_ARCH = x86
+CE_SDK = STANDARDSDK_600 # replace with actual SDK name
+CE_ARCH = x86
-DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x600 $$CE_ARCH _X86_ _M_IX86
+DEFINES += STANDARDSHELL_UI_MODEL _WIN32_WCE=0x600 $$CE_ARCH _X86_ _M_IX86
QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,6.00 /MACHINE:X86 /ENTRY:mainACRTStartup
QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,6.00 /MACHINE:X86
@@ -23,5 +23,5 @@ QMAKE_LIBS_NETWORK = ws2.lib $$QMAKE_LIBS_GUI
QMAKE_LIBS_OPENGL =
QMAKE_LIBS_COMPAT =
-QMAKE_RC = rc /DUNDER_CE=600 /D_WIN32_WCE=0x600
+QMAKE_RC = rc /DUNDER_CE=600 /D_WIN32_WCE=0x600
diff --git a/mkspecs/wince70embedded-armv4i-msvc2008/qmake.conf b/mkspecs/wince70embedded-armv4i-msvc2008/qmake.conf
index c9ca718812..fa00f24716 100644
--- a/mkspecs/wince70embedded-armv4i-msvc2008/qmake.conf
+++ b/mkspecs/wince70embedded-armv4i-msvc2008/qmake.conf
@@ -8,7 +8,7 @@ include(../common/wince/qmake.conf)
CE_SDK = WEC7_SDK_NAME # replace with actual SDK name
CE_ARCH = armv4i
-DEFINES += QT_NO_NATIVE_GESTURES QT_NOSTANDARDSHELL_UI_MODEL _CRT_SECURE_NO_DEPRECATE _WIN32_WCE=0x700 $$CE_ARCH _AMRV7_ armv7 _ARM_
+DEFINES += QT_NO_CLIPBOARD QT_NO_ACCESSIBILITY QT_NO_NATIVE_GESTURES QT_NOSTANDARDSHELL_UI_MODEL _CRT_SECURE_NO_DEPRECATE _WIN32_WCE=0x700 $$CE_ARCH _AMRV7_ armv7 _ARM_
QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,7.00 /MACHINE:THUMB /ENTRY:mainACRTStartup
QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,7.00 /MACHINE:THUMB
@@ -21,8 +21,9 @@ QMAKE_LIBS_NETWORK = ws2.lib $$QMAKE_LIBS_GUI
QMAKE_LIBS_OPENGL =
QMAKE_LIBS_COMPAT =
QMAKE_LIBS_OPENVG = libopenvg.lib
+QMAKE_LIBS_OPENGL_ES2 = libEGL.lib libGLESv2.lib
QMAKE_RC = rc
-QMAKE_COMPILER_DEFINES -= _MSC_VER=1400
-QMAKE_COMPILER_DEFINES += _MSC_VER=1500
+QMAKE_COMPILER_DEFINES -= _MSC_VER=1400
+QMAKE_COMPILER_DEFINES += _MSC_VER=1500
diff --git a/mkspecs/wince70embedded-x86-msvc2008/qmake.conf b/mkspecs/wince70embedded-x86-msvc2008/qmake.conf
index 89d912a347..156f767182 100644
--- a/mkspecs/wince70embedded-x86-msvc2008/qmake.conf
+++ b/mkspecs/wince70embedded-x86-msvc2008/qmake.conf
@@ -7,7 +7,7 @@ include(../common/wince/qmake.conf)
CE_SDK = Platform Builder
CE_ARCH = _TGTCPU
-DEFINES += QT_NO_NATIVE_GESTURES QT_NOSTANDARDSHELL_UI_MODEL _CRT_SECURE_NO_DEPRECATE _WIN32_WCE=0x700 $$CE_ARCH _X86_ _M_IX86
+DEFINES += QT_NO_NATIVE_GESTURES QT_NOSTANDARDSHELL_UI_MODEL _CRT_SECURE_NO_DEPRECATE _WIN32_WCE=0x700 $$CE_ARCH _X86_ _M_IX86
QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,7.00 /MACHINE:X86 /ENTRY:mainACRTStartup
QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,7.00 /MACHINE:X86
diff --git a/mkspecs/wincewm50pocket-msvc2005/qmake.conf b/mkspecs/wincewm50pocket-msvc2005/qmake.conf
index 676be5ac2a..f92cdb50f9 100644
--- a/mkspecs/wincewm50pocket-msvc2005/qmake.conf
+++ b/mkspecs/wincewm50pocket-msvc2005/qmake.conf
@@ -5,10 +5,10 @@
#
include(../common/wince/qmake.conf)
-CE_SDK = Windows Mobile 5.0 Pocket PC SDK
-CE_ARCH = ARMV4I
+CE_SDK = Windows Mobile 5.0 Pocket PC SDK
+CE_ARCH = ARMV4I
-DEFINES += _WIN32_WCE=0x501 $$CE_ARCH _ARMV4I_ armv4i _ARM_ ARM _M_ARM ARM __arm__ Q_OS_WINCE_WM QT_NO_PRINTER QT_NO_PRINTDIALOG
+DEFINES += _WIN32_WCE=0x501 $$CE_ARCH _ARMV4I_ armv4i _ARM_ ARM _M_ARM ARM __arm__ Q_OS_WINCE_WM QT_NO_PRINTER QT_NO_PRINTDIALOG
QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,5.01 /MACHINE:THUMB /ENTRY:mainACRTStartup
QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,5.01 /MACHINE:THUMB
diff --git a/mkspecs/wincewm50smart-msvc2005/qmake.conf b/mkspecs/wincewm50smart-msvc2005/qmake.conf
index c0f09cc0bb..9ac41c2866 100644
--- a/mkspecs/wincewm50smart-msvc2005/qmake.conf
+++ b/mkspecs/wincewm50smart-msvc2005/qmake.conf
@@ -5,13 +5,13 @@
#
include(../common/wince/qmake.conf)
-CE_SDK = Windows Mobile 5.0 Smartphone SDK
-CE_ARCH = ARMV4I
+CE_SDK = Windows Mobile 5.0 Smartphone SDK
+CE_ARCH = ARMV4I
-DEFINES += SMARTPHONE2003_UI_MODEL _WIN32_WCE=0x501 $$CE_ARCH _ARMV4I_ armv4i _ARM_ ARM _M_ARM ARM __arm__ Q_OS_WINCE_WM QT_NO_PRINTER QT_NO_PRINTDIALOG QT_KEYPAD_NAVIGATION
+DEFINES += SMARTPHONE2003_UI_MODEL _WIN32_WCE=0x501 $$CE_ARCH _ARMV4I_ armv4i _ARM_ ARM _M_ARM ARM __arm__ Q_OS_WINCE_WM QT_NO_PRINTER QT_NO_PRINTDIALOG QT_KEYPAD_NAVIGATION
QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,5.01 /MACHINE:THUMB /ENTRY:mainACRTStartup
-QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,5.01 /MACHINE:THUMB
+QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,5.01 /MACHINE:THUMB
QMAKE_LFLAGS_DLL = /SUBSYSTEM:WINDOWSCE,5.01 /MACHINE:THUMB /DLL
QMAKE_LIBFLAGS = $$QMAKE_LFLAGS_WINDOWS
QMAKE_LIBFLAGS_RELEASE = /LTCG
diff --git a/mkspecs/wincewm60professional-msvc2005/qmake.conf b/mkspecs/wincewm60professional-msvc2005/qmake.conf
index 78c5f0187a..029ea08652 100644
--- a/mkspecs/wincewm60professional-msvc2005/qmake.conf
+++ b/mkspecs/wincewm60professional-msvc2005/qmake.conf
@@ -1,13 +1,13 @@
include(../wincewm50pocket-msvc2005/qmake.conf)
-CE_SDK = Windows Mobile 6 Professional SDK
-CE_ARCH = ARMV4I
+CE_SDK = Windows Mobile 6 Professional SDK
+CE_ARCH = ARMV4I
-DEFINES -= _WIN32_WCE=0x501
-DEFINES += _WIN32_WCE=0x502
+DEFINES -= _WIN32_WCE=0x501
+DEFINES += _WIN32_WCE=0x502
-QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,5.02 /MACHINE:THUMB /ENTRY:mainACRTStartup
-QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,5.02 /MACHINE:THUMB
+QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,5.02 /MACHINE:THUMB /ENTRY:mainACRTStartup
+QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,5.02 /MACHINE:THUMB
QMAKE_LFLAGS_DLL = /SUBSYSTEM:WINDOWSCE,5.02 /MACHINE:THUMB /DLL
QMAKE_LIBFLAGS = $$QMAKE_LFLAGS_WINDOWS
diff --git a/mkspecs/wincewm60standard-msvc2005/qmake.conf b/mkspecs/wincewm60standard-msvc2005/qmake.conf
index 15cac422bc..aa1ade030a 100644
--- a/mkspecs/wincewm60standard-msvc2005/qmake.conf
+++ b/mkspecs/wincewm60standard-msvc2005/qmake.conf
@@ -1,18 +1,18 @@
include(../wincewm50smart-msvc2005/qmake.conf)
-CE_SDK = Windows Mobile 6 Standard SDK
-CE_ARCH = ARMV4I
+CE_SDK = Windows Mobile 6 Standard SDK
+CE_ARCH = ARMV4I
-DEFINES -= _WIN32_WCE=0x501
-DEFINES += _WIN32_WCE=0x502
+DEFINES -= _WIN32_WCE=0x501
+DEFINES += _WIN32_WCE=0x502
# Windows Mobile 6 Standard edition defines
# GWES_ICONCURS=1 although there is no cursor support
-
-DEFINES += QT_NO_CURSOR
-QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,5.02 /MACHINE:THUMB /ENTRY:mainACRTStartup
-QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,5.02 /MACHINE:THUMB
+DEFINES += QT_NO_CURSOR
+
+QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:WINDOWSCE,5.02 /MACHINE:THUMB /ENTRY:mainACRTStartup
+QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWSCE,5.02 /MACHINE:THUMB
QMAKE_LFLAGS_DLL = /SUBSYSTEM:WINDOWSCE,5.02 /MACHINE:THUMB /DLL
QMAKE_LIBFLAGS = $$QMAKE_LFLAGS_WINDOWS
diff --git a/mkspecs/wincewm65professional-msvc2005/qmake.conf b/mkspecs/wincewm65professional-msvc2005/qmake.conf
index b4ae0966cc..561c0495c9 100644
--- a/mkspecs/wincewm65professional-msvc2005/qmake.conf
+++ b/mkspecs/wincewm65professional-msvc2005/qmake.conf
@@ -1,5 +1,5 @@
include(../wincewm60professional-msvc2005/qmake.conf)
-DEFINES += QT_WINCE_GESTURES
-QMAKE_LIBS_GUI += TouchGestureCore.lib
+DEFINES += QT_WINCE_GESTURES
+QMAKE_LIBS_GUI += TouchGestureCore.lib
diff --git a/qmake/Makefile.unix b/qmake/Makefile.unix
index c8ac221293..7293f4c869 100644
--- a/qmake/Makefile.unix
+++ b/qmake/Makefile.unix
@@ -1,11 +1,3 @@
-SOURCE_PATH = @SOURCE_PATH@
-BUILD_PATH = @BUILD_PATH@
-QT_VERSION = @QT_VERSION@
-QTOBJS = @QMAKE_QTOBJS@
-QTSRCS = @QMAKE_QTSRCS@
-QMAKESPEC = @QMAKESPEC@
-LFLAGS = @QMAKE_LFLAGS@
-
QMKSRC = $(SOURCE_PATH)/qmake
QMKLIBSRC = $(QMKSRC)/library
QMKGENSRC = $(QMKSRC)/generators
@@ -22,18 +14,14 @@ OBJS=project.o option.o property.o main.o ioutils.o proitems.o \
#qt code
QOBJS=qtextcodec.o qutfcodec.o qstring.o qstringbuilder.o qtextstream.o qiodevice.o qmalloc.o qglobal.o \
qarraydata.o qbytearray.o qbytearraymatcher.o qdatastream.o qbuffer.o qlist.o qfiledevice.o qfile.o \
- qfilesystementry.o qfilesystemengine_unix.o qfilesystemengine.o qfilesystemiterator_unix.o \
- qfsfileengine_unix.o qfsfileengine.o \
- qfsfileengine_iterator.o qregexp.o qvector.o qbitarray.o qdir.o qdiriterator.o quuid.o qhash.o \
- qfileinfo.o qdatetime.o qstringlist.o qabstractfileengine.o qtemporaryfile.o \
- qmap.o qmetatype.o qsettings.o qsystemerror.o qlibraryinfo.o qvariant.o qvsnprintf.o \
- qlocale.o qlocale_tools.o qlocale_unix.o qlinkedlist.o qnumeric.o qcryptographichash.o \
- qxmlstream.o qxmlutils.o qlogging.o \
+ qfilesystementry.o qfilesystemengine.o qfsfileengine.o qfsfileengine_iterator.o qregexp.o qvector.o \
+ qbitarray.o qdir.o qdiriterator.o quuid.o qhash.o qfileinfo.o qdatetime.o qstringlist.o \
+ qabstractfileengine.o qtemporaryfile.o qmap.o qmetatype.o qsettings.o qsystemerror.o qlibraryinfo.o \
+ qvariant.o qvsnprintf.o qlocale.o qlocale_tools.o qlinkedlist.o qnumeric.o \
+ qcryptographichash.o qxmlstream.o qxmlutils.o qlogging.o \
$(QTOBJS)
-
-
#all sources, used for the depend target
DEPEND_SRC = \
$(QMKSRC)/main.cpp $(QMKSRC)/project.cpp $(QMKSRC)/option.cpp $(QMKSRC)/property.cpp \
@@ -58,10 +46,15 @@ DEPEND_SRC = \
$(SOURCE_PATH)/src/corelib/tools/qarraydata.cpp $(SOURCE_PATH)/src/corelib/tools/qbytearray.cpp\
$(SOURCE_PATH)/src/corelib/tools/qbytearraymatcher.cpp \
$(SOURCE_PATH)/src/corelib/io/qdatastream.cpp $(SOURCE_PATH)/src/corelib/io/qbuffer.cpp \
- $(SOURCE_PATH)/src/corelib/io/qfilesystementry.cpp $(SOURCE_PATH)/src/corelib/io/qfilesystemengine_unix.cpp \
- $(SOURCE_PATH)/src/corelib/io/qfilesystemengine_mac.cpp \
- $(SOURCE_PATH)/src/corelib/io/qfilesystemengine.cpp $(SOURCE_PATH)/src/corelib/io/qfilesystemiterator_unix.cpp \
- $(SOURCE_PATH)/src/corelib/io/qfsfileengine_unix.cpp $(SOURCE_PATH)/src/corelib/io/qabstractfileengine.cpp \
+ $(SOURCE_PATH)/src/corelib/io/qfilesystementry.cpp \
+ $(SOURCE_PATH)/src/corelib/io/qfilesystemengine_unix.cpp \
+ $(SOURCE_PATH)/src/corelib/io/qfilesystemengine_win.cpp \
+ $(SOURCE_PATH)/src/corelib/io/qfilesystemengine.cpp \
+ $(SOURCE_PATH)/src/corelib/io/qfilesystemiterator_unix.cpp \
+ $(SOURCE_PATH)/src/corelib/io/qfilesystemiterator_win.cpp \
+ $(SOURCE_PATH)/src/corelib/io/qfsfileengine_unix.cpp \
+ $(SOURCE_PATH)/src/corelib/io/qfsfileengine_win.cpp \
+ $(SOURCE_PATH)/src/corelib/io/qabstractfileengine.cpp \
$(SOURCE_PATH)/src/corelib/io/qfsfileengine_iterator.cpp \
$(SOURCE_PATH)/src/corelib/io/qfsfileengine.cpp $(SOURCE_PATH)/src/corelib/tools/qlist.cpp \
$(SOURCE_PATH)/src/corelib/tools/qvector.cpp $(SOURCE_PATH)/src/corelib/tools/qbitarray.cpp \
@@ -74,6 +67,7 @@ DEPEND_SRC = \
$(SOURCE_PATH)/src/corelib/tools/qlocale.cpp \
$(SOURCE_PATH)/src/corelib/tools/qlocale_tools.cpp \
$(SOURCE_PATH)/src/corelib/tools/qlocale_unix.cpp \
+ $(SOURCE_PATH)/src/corelib/tools/qlocale_win.cpp \
$(SOURCE_PATH)/src/corelib/tools/qlinkedlist.cpp \
$(SOURCE_PATH)/src/corelib/tools/qhash.cpp $(SOURCE_PATH)/src/corelib/kernel/qcore_mac.cpp \
$(SOURCE_PATH)/src/corelib/io/qtemporaryfile.cpp $(SOURCE_PATH)/src/corelib/kernel/qmetatype.cpp \
@@ -84,9 +78,11 @@ DEPEND_SRC = \
$(SOURCE_PATH)/src/corelib/xml/qxmlutils.cpp \
$(SOURCE_PATH)/src/corelib/kernel/qsystemerror.cpp \
$(SOURCE_PATH)/src/corelib/global/qlogging.cpp \
+ $(SOURCE_PATH)/src/corelib/plugin/qsystemlibrary.cpp \
+ $(SOURCE_PATH)/tools/shared/windows/registry.cpp \
$(QTSRCS)
-CPPFLAGS = -g $(OPENSOURCE_CXXFLAGS) \
+CPPFLAGS = -g $(EXTRA_CPPFLAGS) \
-I$(QMKSRC) -I$(QMKLIBSRC) -I$(QMKSRC)/generators -I$(QMKSRC)/generators/unix -I$(QMKSRC)/generators/win32 \
-I$(QMKSRC)/generators/mac -I$(QMKSRC)/generators/integrity \
-I$(BUILD_PATH)/include -I$(BUILD_PATH)/include/QtCore \
@@ -98,19 +94,23 @@ CPPFLAGS = -g $(OPENSOURCE_CXXFLAGS) \
-DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_COMPONENT -DQT_NO_COMPRESS \
-DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT -DQT_NO_DATASTREAM
-CXXFLAGS = @QMAKE_CXXFLAGS@ $(CPPFLAGS)
+CXXFLAGS = $(EXTRA_CXXFLAGS) $(CPPFLAGS)
-first all: $(BUILD_PATH)/bin/qmake
-qmake: $(BUILD_PATH)/bin/qmake
+first all: $(BUILD_PATH)/bin/qmake$(EXEEXT)
+qmake: $(BUILD_PATH)/bin/qmake$(EXEEXT)
-$(BUILD_PATH)/bin/qmake: $(OBJS) $(QOBJS)
+$(BUILD_PATH)/bin/qmake$(EXEEXT): $(OBJS) $(QOBJS)
$(CXX) -o "$@" $(OBJS) $(QOBJS) $(LFLAGS)
+Makefile: $(SOURCE_PATH)/qmake/Makefile.unix
+ @echo "Out of date, please rerun configure"
+
clean::
- rm -f $(OBJS) $(QOBJS)
+ $(RM_F) $(OBJS) $(QOBJS)
distclean:: clean
- rm -rf $(BUILD_PATH)/bin/qmake .deps
+ $(RM_RF) .deps
+ $(RM_F) $(BUILD_PATH)/bin/qmake$(EXEEXT)
depend:
makedepend -D__MAKEDEPEND__ $(CPPFLAGS) $(DEPEND_SRC)
@@ -222,6 +222,9 @@ qnumeric.o: $(SOURCE_PATH)/src/corelib/global/qnumeric.cpp
qsettings_mac.o: $(SOURCE_PATH)/src/corelib/io/qsettings_mac.cpp
$(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qsettings_mac.cpp
+qsettings_win.o: $(SOURCE_PATH)/src/corelib/io/qsettings_win.cpp
+ $(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qsettings_win.cpp
+
qiodevice.o: $(SOURCE_PATH)/src/corelib/io/qiodevice.cpp
$(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qiodevice.cpp
@@ -270,6 +273,9 @@ qlocale_tools.o: $(SOURCE_PATH)/src/corelib/tools/qlocale_tools.cpp
qlocale_unix.o: $(SOURCE_PATH)/src/corelib/tools/qlocale_unix.cpp
$(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/tools/qlocale_unix.cpp
+qlocale_win.o: $(SOURCE_PATH)/src/corelib/tools/qlocale_win.cpp
+ $(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/tools/qlocale_win.cpp
+
qdatastream.o: $(SOURCE_PATH)/src/corelib/io/qdatastream.cpp
$(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qdatastream.cpp
@@ -294,12 +300,15 @@ qfilesystemengine.o: $(SOURCE_PATH)/src/corelib/io/qfilesystemengine.cpp
qfilesystemengine_unix.o: $(SOURCE_PATH)/src/corelib/io/qfilesystemengine_unix.cpp
$(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qfilesystemengine_unix.cpp
-qfilesystemengine_mac.o: $(SOURCE_PATH)/src/corelib/io/qfilesystemengine_mac.cpp
- $(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qfilesystemengine_mac.cpp
+qfilesystemengine_win.o: $(SOURCE_PATH)/src/corelib/io/qfilesystemengine_win.cpp
+ $(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qfilesystemengine_win.cpp
qfilesystemiterator_unix.o: $(SOURCE_PATH)/src/corelib/io/qfilesystemiterator_unix.cpp
$(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qfilesystemiterator_unix.cpp
+qfilesystemiterator_win.o: $(SOURCE_PATH)/src/corelib/io/qfilesystemiterator_win.cpp
+ $(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qfilesystemiterator_win.cpp
+
qfsfileengine.o: $(SOURCE_PATH)/src/corelib/io/qfsfileengine.cpp
$(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qfsfileengine.cpp
@@ -309,6 +318,9 @@ qfsfileengine_iterator.o: $(SOURCE_PATH)/src/corelib/io/qfsfileengine_iterator.c
qfsfileengine_unix.o: $(SOURCE_PATH)/src/corelib/io/qfsfileengine_unix.cpp
$(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qfsfileengine_unix.cpp
+qfsfileengine_win.o: $(SOURCE_PATH)/src/corelib/io/qfsfileengine_win.cpp
+ $(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qfsfileengine_win.cpp
+
qabstractfileengine.o: $(SOURCE_PATH)/src/corelib/io/qabstractfileengine.cpp
$(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/io/qabstractfileengine.cpp
@@ -363,4 +375,10 @@ qxmlutils.o: $(SOURCE_PATH)/src/corelib/xml/qxmlutils.cpp
qlogging.o: $(SOURCE_PATH)/src/corelib/global/qlogging.cpp
$(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/global/qlogging.cpp
+qsystemlibrary.o: $(SOURCE_PATH)/src/corelib/plugin/qsystemlibrary.cpp
+ $(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/src/corelib/plugin/qsystemlibrary.cpp
+
+registry.o: $(SOURCE_PATH)/tools/shared/windows/registry.cpp
+ $(CXX) -c -o $@ $(CXXFLAGS) $(SOURCE_PATH)/tools/shared/windows/registry.cpp
+
# DO NOT DELETE THIS LINE -- make depend depends on it
diff --git a/qmake/Makefile.win32 b/qmake/Makefile.win32
index 222acfa9a6..63cdf50563 100644
--- a/qmake/Makefile.win32
+++ b/qmake/Makefile.win32
@@ -42,7 +42,7 @@ CFLAGS_BARE = -c -Fo./ \
-DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_COMPONENT -DQT_NO_COMPRESS \
-DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT -DQT_NO_DATASTREAM \
-DUNICODE
-CFLAGS = -Yuqmake_pch.h -FIqmake_pch.h -Fpqmake_pch.pch $(CFLAGS_BARE) $(CFLAGS)
+CFLAGS = -Yuqmake_pch.h -FIqmake_pch.h -Fpqmake_pch.pch $(CFLAGS_BARE) $(CFLAGS) $(EXTRA_CPPFLAGS)
CXXFLAGS_BARE = $(CFLAGS_BARE)
CXXFLAGS = $(CFLAGS)
@@ -66,10 +66,6 @@ OBJS = project.obj main.obj ioutils.obj proitems.obj \
msvc_objectmodel.obj msbuild_objectmodel.obj registry.obj \
gbuild.obj cesdkhandler.obj
-!IFDEF QMAKE_OPENSOURCE_EDITION
-CFLAGS = $(CFLAGS) -DQMAKE_OPENSOURCE_EDITION
-!ENDIF
-
#qt code
QTOBJS= \
qbitarray.obj \
diff --git a/qmake/Makefile.win32-g++ b/qmake/Makefile.win32-g++
deleted file mode 100644
index 565d5d2d51..0000000000
--- a/qmake/Makefile.win32-g++
+++ /dev/null
@@ -1,160 +0,0 @@
-ifeq "$(SOURCE_PATH)" ""
-SOURCE_PATH = ..
-endif
-
-ifeq "$(BUILD_PATH)" ""
-BUILD_PATH = ..
-endif
-
-CORESRC = $(SOURCE_PATH)/src/corelib
-TOOLSRC = $(SOURCE_PATH)/tools
-QMKSRC = $(SOURCE_PATH)/qmake
-QMKLIBSRC = $(QMKSRC)/library
-
-# SHELL is the full path of sh.exe, unless
-# 1) it is found in the current directory
-# 2) it is not found at all
-# 3) it is overridden on the command line with an existing file
-# ... otherwise it is always sh.exe. Specifically, SHELL from the
-# environment has no effect.
-#
-# This check will fail if SHELL is explicitly set to a not
-# sh-compatible shell. This is not a problem, because configure.exe
-# will not do that.
-ifeq ($(SHELL), sh.exe)
- ifeq ($(wildcard $(CURDIR)/sh.exe), )
- SH = 0
- else
- SH = 1
- endif
-else
- SH = 1
-endif
-
-ifeq ($(SH), 1)
- COPY = cp
- DEL = rm -f
-else
- COPY = copy
- DEL = del /f
-endif
-
-#
-# specific stuff for mingw g++ make
-#
-CXX = g++
-CFLAGS = -c -o$@ -O \
- -I$(QMKSRC) -I$(QMKLIBSRC) -I$(QMKSRC)/generators -I$(QMKSRC)/generators/unix -I$(QMKSRC)/generators/win32 -I$(QMKSRC)/generators/mac -I$(QMKSRC)/generators/integrity \
- -I$(BUILD_PATH)/include -I$(BUILD_PATH)/include/QtCore -I$(BUILD_PATH)/include/QtCore/$(QT_VERSION) -I$(BUILD_PATH)/include/QtCore/$(QT_VERSION)/QtCore \
- -I$(BUILD_PATH)/src/corelib/global -DHAVE_QCONFIG_CPP \
- -I$(SOURCE_PATH)/mkspecs/win32-g++ \
- -I$(SOURCE_PATH)/tools/shared \
- -DQT_BUILD_QMAKE -DQT_BOOTSTRAPPED -DPROEVALUATOR_FULL -DPROEVALUATOR_DEBUG \
- -DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_NO_COMPONENT -DQT_NO_COMPRESS \
- -DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT -DQT_NO_DATASTREAM \
- -DUNICODE
-CXXFLAGS = $(CFLAGS)
-LFLAGS = -static -s
-LIBS = -lole32 -luuid -ladvapi32 -lkernel32
-LINKQMAKE = g++ $(LFLAGS) -o qmake.exe $(OBJS) $(QTOBJS) $(LIBS)
-ADDCLEAN =
-
-
-#qmake code
-OBJS = project.o main.o ioutils.o proitems.o \
- qmakeglobals.o qmakeparser.o qmakeevaluator.o qmakebuiltins.o \
- makefile.o unixmake.o unixmake2.o mingw_make.o \
- option.o winmakefile.o projectgenerator.o property.o meta.o \
- makefiledeps.o metamakefile.o xmloutput.o pbuilder_pbx.o \
- msvc_nmake.o msvc_vcproj.o msvc_vcxproj.o \
- msvc_objectmodel.o msbuild_objectmodel.o registry.o gbuild.o \
- cesdkhandler.o
-
-ifdef QMAKE_OPENSOURCE_EDITION
-CFLAGS += -DQMAKE_OPENSOURCE_EDITION
-endif
-
-#qt code
-QTOBJS= \
- qbitarray.o \
- qbuffer.o \
- qarraydata.o \
- qbytearray.o \
- qcryptographichash.o \
- qvsnprintf.o \
- qbytearraymatcher.o \
- qconfig.o \
- qdatetime.o \
- qdir.o \
- qdiriterator.o \
- qfiledevice.o \
- qfile.o \
- qtemporaryfile.o \
- qfileinfo.o \
- qabstractfileengine.o \
- qfilesystementry.o \
- qfilesystemengine.o \
- qfilesystemengine_win.o \
- qfilesystemiterator_win.o \
- qfsfileengine.o \
- qfsfileengine_iterator.o \
- qfsfileengine_win.o \
- qglobal.o \
- qhash.o \
- qiodevice.o \
- qlibraryinfo.o \
- qlist.o \
- qlinkedlist.o \
- qlocale.o \
- qlocale_tools.o \
- qlocale_win.o \
- qmalloc.o \
- qmap.o \
- qregexp.o \
- qtextcodec.o \
- qutfcodec.o \
- qstring.o \
- qstringlist.o \
- qstringbuilder.o \
- qsystemerror.o \
- qsystemlibrary.o \
- qtextstream.o \
- quuid.o \
- qvector.o \
- qsettings.o \
- qsettings_win.o \
- qvariant.o \
- qmetatype.o \
- qxmlstream.o \
- qxmlutils.o \
- qnumeric.o \
- qlogging.o
-
-
-qmake.exe: $(OBJS) $(QTOBJS)
- $(LINKQMAKE)
- -$(COPY) qmake.exe $(BUILD_PATH)\bin\qmake.exe
-
-Makefile: $(SOURCE_PATH)/qmake/Makefile.win32-g++
- @echo "Out of date, please rerun configure"
-
-clean::
- -$(DEL) $(OBJS) $(QTOBJS) $(ADDCLEAN)
-
-distclean:: clean
- -$(DEL) qmake.exe
-
-.c.o:
- $(CXX) $(CFLAGS) $<
-
-.cpp.o:
- $(CXX) $(CXXFLAGS) $<
-
-QTVPATH = $(TOOLSRC)/shared/windows:$(CORESRC)/global:$(CORESRC)/kernel:$(CORESRC)/tools:$(CORESRC)/codecs:$(CORESRC)/io:$(CORESRC)/xml:$(CORESRC)/plugin:$(BUILD_PATH)/src/corelib/global
-VPATH = $(QMKSRC):$(QMKLIBSRC):$(QMKSRC)/generators:$(QMKSRC)/generators/unix:$(QMKSRC)/generators/mac:$(QMKSRC)/generators/win32:$(QMKSRC)/generators/integrity:$(QTVPATH)
-
-project.o: $(QMKSRC)/project.h $(QMKSRC)/option.h
-meta.o: $(QMKSRC)/project.h $(QMKSRC)/option.h
-main.o: $(QMKSRC)/project.h
-option.o: $(QMKSRC)/option.h
-property.o: $(QMKSRC)/project.h $(QMKSRC)/option.h
diff --git a/qmake/generators/mac/pbuilder_pbx.cpp b/qmake/generators/mac/pbuilder_pbx.cpp
index c9623e6f98..a09e10c55e 100644
--- a/qmake/generators/mac/pbuilder_pbx.cpp
+++ b/qmake/generators/mac/pbuilder_pbx.cpp
@@ -46,6 +46,7 @@
#include <qregexp.h>
#include <qcryptographichash.h>
#include <qdebug.h>
+#include <qstring.h>
#include <stdlib.h>
#include <time.h>
#ifdef Q_OS_UNIX
@@ -224,7 +225,6 @@ ProjectBuilderMakefileGenerator::writeSubDirs(QTextStream &t)
<< "\t\t\t" << writeSettings("lastKnownFileType", "wrapper.pb-project") << ";" << "\n"
<< "\t\t\t" << writeSettings("name", escapeFilePath(tmp_proj.first("TARGET") + projectSuffix())) << ";" << "\n"
<< "\t\t\t" << writeSettings("path", pbxproj) << ";" << "\n"
- << "\t\t\t" << writeSettings("refType", "0", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("sourceTree", "<absolute>") << ";" << "\n"
<< "\t\t" << "};" << "\n";
//WRAPPER
@@ -237,8 +237,7 @@ ProjectBuilderMakefileGenerator::writeSubDirs(QTextStream &t)
t << "\t\t\t" << writeSettings("fileType", "compiled.mach-o.dylib") << ";" << "\n"
<< "\t\t\t" << writeSettings("path", tmp_proj.first("TARGET") + ".dylib") << ";" << "\n";
}
- t << "\t\t\t" << writeSettings("refType", "3", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("remoteRef", keyFor(pbxproj + "_WRAPPERREF")) << ";" << "\n"
+ t << "\t\t\t" << writeSettings("remoteRef", keyFor(pbxproj + "_WRAPPERREF")) << ";" << "\n"
<< "\t\t\t" << writeSettings("sourceTree", "BUILT_PRODUCTS_DIR", SettingsNoQuote) << ";" << "\n"
<< "\t\t" << "};" << "\n";
t << "\t\t" << keyFor(pbxproj + "_WRAPPERREF") << " = {" << "\n"
@@ -254,7 +253,6 @@ ProjectBuilderMakefileGenerator::writeSubDirs(QTextStream &t)
<< "\t\t\t" << writeSettings("children", project->values(ProKey(pbxproj + "_WRAPPER")), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXGroup", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("name", "Products") << ";" << "\n"
- << "\t\t\t" << writeSettings("refType", "4", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("sourceTree", "<group>") << ";" << "\n"
<< "\t\t" << "};" << "\n";
}
@@ -294,14 +292,13 @@ ProjectBuilderMakefileGenerator::writeSubDirs(QTextStream &t)
<< "\t\t\t" << writeSettings("isa", "PBXGroup", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("children", grp_it.value(), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("name", escapeFilePath(grp_it.key().section(Option::dir_sep, -1))) << ";" << "\n"
- << "\t\t\t" << writeSettings("refType", "4", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("sourceTree", "<Group>") << ";" << "\n"
<< "\t\t" << "};" << "\n";
}
//DUMP EVERYTHING THAT TIES THE ABOVE TOGETHER
- //BUILDSTYLE
- QString active_buildstyle;
+ //BUILDCONFIGURATIONS
+ QString defaultConfig;
for(int as_release = 0; as_release < 2; as_release++)
{
QMap<QString, QString> settings;
@@ -323,6 +320,8 @@ ProjectBuilderMakefileGenerator::writeSubDirs(QTextStream &t)
}
QString name = (as_release ? "Release" : "Debug");
+ if (project->isActiveConfig("debug") != (bool)as_release)
+ defaultConfig = name;
QString key = keyFor("QMAKE_SUBDIR_PBX_BUILDCONFIG_" + name);
project->values("QMAKE_SUBDIR_PBX_BUILDCONFIGS").append(key);
t << "\t\t" << key << " = {" << "\n"
@@ -333,26 +332,12 @@ ProjectBuilderMakefileGenerator::writeSubDirs(QTextStream &t)
t << "\t\t\t" << "};" << "\n"
<< "\t\t\t" << writeSettings("name", name) << ";" << "\n"
<< "\t\t" << "};" << "\n";
-
- key = keyFor("QMAKE_SUBDIR_PBX_BUILDSTYLE_" + name);
- project->values("QMAKE_SUBDIR_PBX_BUILDSTYLES").append(key);
- if (project->isActiveConfig("debug") != (bool)as_release)
- active_buildstyle = name;
- t << "\t\t" << key << " = {" << "\n"
- << "\t\t\t" << writeSettings("buildRules", ProStringList(), SettingsAsList, 4) << ";" << "\n"
- << "\t\t\t" << "buildSettings = {" << "\n";
- for(QMap<QString, QString>::Iterator set_it = settings.begin(); set_it != settings.end(); ++set_it)
- t << "\t\t\t\t" << writeSettings(set_it.key(), set_it.value()) << ";\n";
- t << "\t\t\t" << "};" << "\n"
- << "\t\t\t" << writeSettings("isa", "PBXBuildStyle", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("name", name) << ";" << "\n"
- << "\t\t" << "};" << "\n";
}
t << "\t\t" << keyFor("QMAKE_SUBDIR_PBX_BUILDCONFIG_LIST") << " = {" << "\n"
<< "\t\t\t" << writeSettings("isa", "XCConfigurationList", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("buildConfigurations", project->values("QMAKE_SUBDIR_PBX_BUILDCONFIGS"), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("defaultConfigurationIsVisible", "0", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("defaultConfigurationIsName", active_buildstyle) << ";" << "\n"
+ << "\t\t\t" << writeSettings("defaultConfigurationName", defaultConfig, SettingsNoQuote) << ";" << "\n"
<< "\t\t" << "};" << "\n";
#ifdef GENERATE_AGGREGRATE_SUBDIR
@@ -379,7 +364,6 @@ ProjectBuilderMakefileGenerator::writeSubDirs(QTextStream &t)
t << "\t\t" << keyFor("QMAKE_SUBDIR_PBX_ROOT_GROUP") << " = {" << "\n"
<< "\t\t\t" << writeSettings("children", project->values("QMAKE_SUBDIR_PBX_GROUPS"), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXGroup", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("refType", "4", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("sourceTree", "<group>") << ";" << "\n"
<< "\t\t" << "};" << "\n";
@@ -454,18 +438,17 @@ public:
ProjectBuilderSources::ProjectBuilderSources(const QString &k, bool b,
const QString &g, const QString &c, bool o) : buildable(b), object_output(o), key(k), group(g), compiler(c)
{
- if(group.isNull()) {
- if(k == "SOURCES")
- group = "Sources";
- else if(k == "HEADERS")
- group = "Headers";
- else if(k == "QMAKE_INTERNAL_INCLUDED_FILES")
- group = "Sources [qmake]";
- else if(k == "GENERATED_SOURCES" || k == "GENERATED_FILES")
- group = "Temporary Sources";
- else
- fprintf(stderr, "No group available for %s!\n", k.toLatin1().constData());
- }
+ // Override group name for a few common keys
+ if (k == "SOURCES" || k == "OBJECTIVE_SOURCES" || k == "HEADERS")
+ group = "Sources";
+ else if (k == "QMAKE_INTERNAL_INCLUDED_FILES")
+ group = "Supporting Files";
+ else if (k == "GENERATED_SOURCES" || k == "GENERATED_FILES")
+ group = "Generated Sources";
+ else if (k == "RESOURCES")
+ group = "Resources";
+ else if (group.isNull())
+ group = QString("Sources [") + c + "]";
}
QStringList
@@ -473,7 +456,6 @@ ProjectBuilderSources::files(QMakeProject *project) const
{
QStringList ret = project->values(ProKey(key)).toQStringList();
if(key == "QMAKE_INTERNAL_INCLUDED_FILES") {
- ret.prepend(project->projectFile());
for(int i = 0; i < ret.size(); ++i) {
QStringList newret;
if(!ret.at(i).endsWith(Option::prf_ext))
@@ -486,10 +468,48 @@ ProjectBuilderSources::files(QMakeProject *project) const
return ret;
}
+static QString xcodeFiletypeForFilename(const QString &filename)
+{
+ foreach (const QString &ext, Option::cpp_ext) {
+ if (filename.endsWith(ext))
+ return QStringLiteral("sourcecode.cpp.cpp");
+ }
+
+ foreach (const QString &ext, Option::c_ext) {
+ if (filename.endsWith(ext))
+ return QStringLiteral("sourcecode.c.c");
+ }
+
+ foreach (const QString &ext, Option::h_ext) {
+ if (filename.endsWith(ext))
+ return "sourcecode.c.h";
+ }
+
+ if (filename.endsWith(QStringLiteral(".mm")))
+ return QStringLiteral("sourcecode.cpp.objcpp");
+ if (filename.endsWith(QStringLiteral(".m")))
+ return QStringLiteral("sourcecode.c.objc");
+ if (filename.endsWith(QStringLiteral(".framework")))
+ return QStringLiteral("wrapper.framework");
+ if (filename.endsWith(QStringLiteral(".a")))
+ return QStringLiteral("archive.ar");
+ if (filename.endsWith(QStringLiteral(".pro")) || filename.endsWith(QStringLiteral(".qrc")))
+ return QStringLiteral("text");
+
+ return QString();
+}
bool
ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
{
+ // The code in this function assumes that the current directory matches
+ // the output directory, which is not actually the case when we are called
+ // from the generic generator code. Instead of changing every single
+ // assumption and fileFixify we cheat by moving into the output directory
+ // for the duration of this function.
+ QString input_dir = qmake_getpwd();
+ qmake_setpwd(Option::output_dir);
+
ProStringList tmp;
bool did_preprocess = false;
@@ -511,6 +531,7 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
QFile mkf(mkfile);
if(mkf.open(QIODevice::WriteOnly | QIODevice::Text)) {
writingUnixMakefileGenerator = true;
+ qmake_setpwd(input_dir); // Makefile generation assumes input_dir as pwd
debug_msg(1, "pbuilder: Creating file: %s", mkfile.toLatin1().constData());
QTextStream mkt(&mkf);
writeHeader(mkt);
@@ -519,6 +540,7 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
mkt.flush();
mkf.close();
writingUnixMakefileGenerator = false;
+ qmake_setpwd(Option::output_dir);
}
QString phase_key = keyFor("QMAKE_PBX_MAKEQMAKE_BUILDPHASE");
mkfile = fileFixify(mkfile, qmake_getpwd());
@@ -526,15 +548,18 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
t << "\t\t" << phase_key << " = {" << "\n"
<< "\t\t\t" << writeSettings("buildActionMask", "2147483647", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("files", ProStringList(), SettingsAsList, 4) << ";" << "\n"
- << "\t\t\t" << writeSettings("generatedFileNames", ProStringList(), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXShellScriptBuildPhase", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("runOnlyForDeploymentPostprocessing", "0", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("name", "Qt Qmake") << ";" << "\n"
- << "\t\t\t" << writeSettings("neededFileNames", ProStringList(), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("shellPath", "/bin/sh") << ";" << "\n"
<< "\t\t\t" << writeSettings("shellScript", "make -C " + IoUtils::shellQuoteUnix(qmake_getpwd()) + " -f " + IoUtils::shellQuoteUnix(mkfile)) << ";" << "\n"
<< "\t\t" << "};" << "\n";
}
+ // FIXME: Move all file resolving logic out of ProjectBuilderSources::files(), as it
+ // doesn't have access to any of the information it needs to resolve relative paths.
+ project->values("QMAKE_INTERNAL_INCLUDED_FILES").prepend(fileFixify(project->projectFile(), qmake_getpwd(), input_dir));
+
//DUMP SOURCES
QMap<QString, ProStringList> groups;
QList<ProjectBuilderSources> sources;
@@ -548,14 +573,13 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
for (ProStringList::ConstIterator it = quc.begin(); it != quc.end(); ++it) {
if (project->isEmpty(ProKey(*it + ".output")))
continue;
- ProString name = *it;
- const ProKey nkey(*it + ".name");
- if (!project->isEmpty(nkey))
- name = project->first(nkey);
- const ProStringList &inputs = project->values(ProKey(*it + ".input"));
- for(int input = 0; input < inputs.size(); ++input) {
- if (project->isEmpty(inputs.at(input).toKey()))
+ ProStringList &inputs = project->values(ProKey(*it + ".input"));
+ int input = 0;
+ while (input < inputs.size()) {
+ if (project->isEmpty(inputs.at(input).toKey())) {
+ ++input;
continue;
+ }
bool duplicate = false;
bool isObj = project->values(ProKey(*it + ".CONFIG")).indexOf("no_link") == -1;
if (!isObj) {
@@ -575,8 +599,15 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
}
}
sources.append(ProjectBuilderSources(inputs.at(input).toQString(), true,
- QString("Sources [") + name + "]", (*it).toQString(), isObj));
+ QString(), (*it).toQString(), isObj));
+
+ if (isObj) {
+ inputs.removeAt(input);
+ continue;
+ }
}
+
+ ++input;
}
}
}
@@ -621,30 +652,29 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
}
last_grp = new_grp;
}
+ if (groups[last_grp].contains(src_key))
+ continue;
groups[last_grp] += src_key;
in_root = false;
}
}
- if(in_root)
+ if (in_root) {
+ if (src_list.contains(src_key))
+ continue;
src_list.append(src_key);
+ }
//source reference
t << "\t\t" << src_key << " = {" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXFileReference", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("name", escapeFilePath(name)) << ";" << "\n"
- << "\t\t\t" << writeSettings("path", escapeFilePath(file)) << ";" << "\n"
- << "\t\t\t" << writeSettings("refType", QString::number(reftypeForFile(file)), SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("sourceTree", sourceTreeForFile(file)) << ";" << "\n";
- QString filetype;
- for (QStringList::Iterator cppit = Option::cpp_ext.begin(); cppit != Option::cpp_ext.end(); ++cppit) {
- if (file.endsWith((*cppit))) {
- filetype = "sourcecode.cpp.cpp";
- break;
- }
- }
+ << "\t\t\t" << writeSettings("path", escapeFilePath(file)) << ";" << "\n";
+ if (name != file)
+ t << "\t\t\t" << writeSettings("name", escapeFilePath(name)) << ";" << "\n";
+ t << "\t\t\t" << writeSettings("sourceTree", sourceTreeForFile(file)) << ";" << "\n";
+ QString filetype = xcodeFiletypeForFilename(file);
if (!filetype.isNull())
t << "\t\t\t" << writeSettings("lastKnownFileType", filetype) << ";" << "\n";
t << "\t\t" << "};" << "\n";
- if(sources.at(source).isBuildable()) { //build reference
+ if (sources.at(source).isBuildable() && sources.at(source).isObjectOutput(file)) { //build reference
QString build_key = keyFor(file + ".BUILDABLE");
t << "\t\t" << build_key << " = {" << "\n"
<< "\t\t\t" << writeSettings("fileRef", src_key) << ";" << "\n"
@@ -653,8 +683,7 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
<< "\t\t\t\t" << writeSettings("ATTRIBUTES", ProStringList(), SettingsAsList, 5) << ";" << "\n"
<< "\t\t\t" << "};" << "\n"
<< "\t\t" << "};" << "\n";
- if(sources.at(source).isObjectOutput(file))
- project->values("QMAKE_PBX_OBJ").append(build_key);
+ project->values("QMAKE_PBX_OBJ").append(build_key);
}
}
if(!src_list.isEmpty()) {
@@ -674,7 +703,6 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
<< "\t\t\t" << writeSettings("isa", "PBXGroup", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("children", grp_it.value(), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("name", escapeFilePath(grp_it.key().section(Option::dir_sep, -1))) << ";" << "\n"
- << "\t\t\t" << writeSettings("refType", "4", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("sourceTree", "<Group>") << ";" << "\n"
<< "\t\t" << "};" << "\n";
}
@@ -778,10 +806,9 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
t << "\t\t" << phase_key << " = {" << "\n"
<< "\t\t\t" << writeSettings("buildActionMask", "2147483647", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("files", ProStringList(), SettingsAsList, 4) << ";" << "\n"
- << "\t\t\t" << writeSettings("generatedFileNames", fixListForOutput("QMAKE_PBX_OBJ"), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXShellScriptBuildPhase", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("runOnlyForDeploymentPostprocessing", "0", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("name", "Qt Preprocessors") << ";" << "\n"
- << "\t\t\t" << writeSettings("neededFileNames", fixListForOutput("QMAKE_PBX_OBJ"), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("shellPath", "/bin/sh") << ";" << "\n"
<< "\t\t\t" << writeSettings("shellScript", "make -C " + IoUtils::shellQuoteUnix(qmake_getpwd()) + " -f " + IoUtils::shellQuoteUnix(mkfile)) << ";" << "\n"
<< "\t\t" << "};" << "\n";
@@ -789,12 +816,13 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
//SOURCE BUILDPHASE
if(!project->isEmpty("QMAKE_PBX_OBJ")) {
- QString grp = "Build Sources", key = keyFor(grp);
+ QString grp = "Compile Sources", key = keyFor(grp);
project->values("QMAKE_PBX_BUILDPHASES").append(key);
t << "\t\t" << key << " = {" << "\n"
<< "\t\t\t" << writeSettings("buildActionMask", "2147483647", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("files", fixListForOutput("QMAKE_PBX_OBJ"), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXSourcesBuildPhase", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("runOnlyForDeploymentPostprocessing", "0", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("name", grp) << ";" << "\n"
<< "\t\t" << "};" << "\n";
}
@@ -902,26 +930,29 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
libdirs += path;
}
library = fileFixify(library);
+ QString filetype = xcodeFiletypeForFilename(library);
QString key = keyFor(library);
- bool is_frmwrk = (library.endsWith(".framework"));
- t << "\t\t" << key << " = {" << "\n"
- << "\t\t\t" << writeSettings("isa", "PBXFileReference", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("name", escapeFilePath(name)) << ";" << "\n"
- << "\t\t\t" << writeSettings("path", escapeFilePath(library)) << ";" << "\n"
- << "\t\t\t" << writeSettings("refType", QString::number(reftypeForFile(library)), SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("sourceTree", sourceTreeForFile(library)) << ";" << "\n";
- if (is_frmwrk)
- t << "\t\t\t" << writeSettings("lastKnownFileType", "wrapper.framework") << ";" << "\n";
- t << "\t\t" << "};" << "\n";
- project->values("QMAKE_PBX_LIBRARIES").append(key);
- QString build_key = keyFor(library + ".BUILDABLE");
- t << "\t\t" << build_key << " = {" << "\n"
- << "\t\t\t" << writeSettings("fileRef", key) << ";" << "\n"
- << "\t\t\t" << writeSettings("isa", "PBXBuildFile", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << "settings = {" << "\n"
- << "\t\t\t" << "};" << "\n"
- << "\t\t" << "};" << "\n";
- project->values("QMAKE_PBX_BUILD_LIBRARIES").append(build_key);
+ if (!project->values("QMAKE_PBX_LIBRARIES").contains(key)) {
+ bool is_frmwrk = (library.endsWith(".framework"));
+ t << "\t\t" << key << " = {" << "\n"
+ << "\t\t\t" << writeSettings("isa", "PBXFileReference", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("name", escapeFilePath(name)) << ";" << "\n"
+ << "\t\t\t" << writeSettings("path", escapeFilePath(library)) << ";" << "\n"
+ << "\t\t\t" << writeSettings("refType", QString::number(reftypeForFile(library)), SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("sourceTree", sourceTreeForFile(library)) << ";" << "\n";
+ if (is_frmwrk)
+ t << "\t\t\t" << writeSettings("lastKnownFileType", "wrapper.framework") << ";" << "\n";
+ t << "\t\t" << "};" << "\n";
+ project->values("QMAKE_PBX_LIBRARIES").append(key);
+ QString build_key = keyFor(library + ".BUILDABLE");
+ t << "\t\t" << build_key << " = {" << "\n"
+ << "\t\t\t" << writeSettings("fileRef", key) << ";" << "\n"
+ << "\t\t\t" << writeSettings("isa", "PBXBuildFile", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << "settings = {" << "\n"
+ << "\t\t\t" << "};" << "\n"
+ << "\t\t" << "};" << "\n";
+ project->values("QMAKE_PBX_BUILD_LIBRARIES").append(build_key);
+ }
}
if(remove)
tmp.removeAt(x);
@@ -960,10 +991,9 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
t << "\t\t" << phase_key << " = {" << "\n"
<< "\t\t\t" << writeSettings("buildActionMask", "2147483647", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("files", ProStringList(), SettingsAsList, 4) << ";" << "\n"
- << "\t\t\t" << writeSettings("generatedFileNames", ProStringList(), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXShellScriptBuildPhase", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("runOnlyForDeploymentPostprocessing", "0", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("name", "Qt Sublibs") << ";" << "\n"
- << "\t\t\t" << writeSettings("neededFileNames", ProStringList(), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("shellPath", "/bin/sh") << "\n"
<< "\t\t\t" << writeSettings("shellScript", "make -C " + IoUtils::shellQuoteUnix(qmake_getpwd()) + " -f " + IoUtils::shellQuoteUnix(mkfile)) << ";" << "\n"
<< "\t\t" << "};" << "\n";
@@ -972,42 +1002,24 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
if(!project->isEmpty("QMAKE_PBX_LIBRARIES")) {
tmp = project->values("QMAKE_PBX_LIBRARIES");
if(!tmp.isEmpty()) {
- QString grp("External Frameworks and Libraries"), key = keyFor(grp);
+ QString grp("Frameworks"), key = keyFor(grp);
project->values("QMAKE_PBX_GROUPS").append(key);
t << "\t\t" << key << " = {" << "\n"
<< "\t\t\t" << writeSettings("children", project->values("QMAKE_PBX_LIBRARIES"), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXGroup", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("name", escapeFilePath(grp)) << ";" << "\n"
- << "\t\t\t" << writeSettings("path", ProStringList()) << ";" << "\n"
- << "\t\t\t" << writeSettings("refType", "4", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("sourceTree", "<Group>") << ";" << "\n"
<< "\t\t" << "};" << "\n";
}
}
{
- QString grp("Frameworks & Libraries"), key = keyFor(grp);
+ QString grp("Link Binary With Libraries"), key = keyFor(grp);
project->values("QMAKE_PBX_BUILDPHASES").append(key);
t << "\t\t" << key << " = {" << "\n"
<< "\t\t\t" << writeSettings("buildActionMask", "2147483647", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("files", project->values("QMAKE_PBX_BUILD_LIBRARIES"), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXFrameworksBuildPhase", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("name", escapeFilePath(grp)) << ";" << "\n"
- << "\t\t" << "};" << "\n";
- }
- if(project->isActiveConfig("app_bundle") && project->first("TEMPLATE") == "app") { //BUNDLE RESOURCES
- QString grp("Bundle Resources"), key = keyFor(grp);
- project->values("QMAKE_PBX_BUILDPHASES").append(key);
- t << "\t\t" << key << " = {" << "\n"
- << "\t\t\t" << writeSettings("buildActionMask", "2147483647", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << "files = (" << "\n";
- if(!project->isEmpty("ICON")) {
- ProString icon = project->first("ICON");
- if (icon.length() >= 2 && (icon.at(0) == '"' || icon.at(0) == '\'') && icon.endsWith(icon.at(0)))
- icon = icon.mid(1, icon.length()-2);
- t << "\t\t\t\t" << keyFor(icon + ".BUILDABLE") << ",\n";
- }
- t << "\t\t\t" << ");" << "\n"
- << "\t\t\t" << writeSettings("isa", "PBXResourcesBuildPhase", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("runOnlyForDeploymentPostprocessing", "0", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("name", escapeFilePath(grp)) << ";" << "\n"
<< "\t\t" << "};" << "\n";
}
@@ -1029,78 +1041,96 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
<< "\t\t\t" << writeSettings("shellScript", fixForOutput("cp -r $BUILT_PRODUCTS_DIR/$FULL_PRODUCT_NAME " + escapeFilePath(destDir))) << ";" << "\n"
<< "\t\t" << "};\n";
}
- //BUNDLE_DATA BUILDPHASE (copy)
- if(!project->isEmpty("QMAKE_BUNDLE_DATA")) {
+ // Copy Bundle Resources
+ if (!project->isEmpty("QMAKE_BUNDLE_DATA")) {
ProStringList bundle_file_refs;
+ ProStringList bundle_resources_files;
+
+ bool useCopyResourcesPhase = project->isActiveConfig("app_bundle") && project->first("TEMPLATE") == "app";
+
//all bundle data
const ProStringList &bundle_data = project->values("QMAKE_BUNDLE_DATA");
for(int i = 0; i < bundle_data.count(); i++) {
- ProStringList pbx_files;
+ ProStringList bundle_files;
+ ProString path = project->first(ProKey(bundle_data[i] + ".path"));
//all files
const ProStringList &files = project->values(ProKey(bundle_data[i] + ".files"));
for(int file = 0; file < files.count(); file++) {
QString fn = files[file].toQString();
- QString file_ref_key = keyFor("QMAKE_PBX_BUNDLE_COPY_FILE_REF." + bundle_data[i] + "-" + fn);
+ QString file_ref_key = keyFor("QMAKE_PBX_BUNDLE_DATA_FILE_REF." + bundle_data[i] + "-" + fn);
bundle_file_refs += file_ref_key;
t << "\t\t" << file_ref_key << " = {" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXFileReference", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("path", escapeFilePath(fn)) << ";" << "\n"
- << "\t\t\t" << writeSettings("refType", QString::number(reftypeForFile(fn)), SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("sourceTree", sourceTreeForFile(fn)) << ";" << "\n"
<< "\t\t" << "};" << "\n";
- QString copy_file_key = keyFor("QMAKE_PBX_BUNDLE_COPY_FILE." + bundle_data[i] + "-" + fn);
- pbx_files += copy_file_key;
- t << "\t\t" << copy_file_key << " = {\n"
+ QString file_key = keyFor("QMAKE_PBX_BUNDLE_DATA_FILE." + bundle_data[i] + "-" + fn);
+ bundle_files += file_key;
+ t << "\t\t" << file_key << " = {\n"
<< "\t\t\t" << writeSettings("fileRef", file_ref_key) << ";" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXBuildFile", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << "settings = {\n"
- << "\t\t\t" << "}" << ";" << "\n"
<< "\t\t" << "}" << ";" << "\n";
}
- //the phase
- QString phase_key = keyFor("QMAKE_PBX_BUNDLE_COPY." + bundle_data[i]);
- QString path;
- if (!project->isEmpty(ProKey(bundle_data[i] + ".version"))) {
- //###
+
+ if (!useCopyResourcesPhase || !path.isEmpty()) {
+ // The resource copy phase doesn't support paths, so we have to use
+ // a regular file copy phase (which doesn't optimize the resources).
+ QString phase_key = keyFor("QMAKE_PBX_BUNDLE_COPY." + bundle_data[i]);
+ if (!project->isEmpty(ProKey(bundle_data[i] + ".version"))) {
+ //###
+ }
+
+ project->values("QMAKE_PBX_PRESCRIPT_BUILDPHASES").append(phase_key);
+ t << "\t\t" << phase_key << " = {\n"
+ << "\t\t\t" << writeSettings("name", "Copy '" + bundle_data[i] + "' Files to Bundle") << ";" << "\n"
+ << "\t\t\t" << writeSettings("buildActionMask", "2147483647", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("dstPath", escapeFilePath(path)) << ";" << "\n"
+ << "\t\t\t" << writeSettings("dstSubfolderSpec", "1", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("files", bundle_files, SettingsAsList, 4) << ";" << "\n"
+ << "\t\t\t" << writeSettings("isa", "PBXCopyFilesBuildPhase", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("runOnlyForDeploymentPostprocessing", "0", SettingsNoQuote) << ";" << "\n"
+ << "\t\t" << "}" << ";" << "\n";
+ } else {
+ // Otherwise we leave it to the resource copy phase below
+ bundle_resources_files += bundle_files;
+ }
+ }
+
+ if (useCopyResourcesPhase) {
+ if (!project->isEmpty("ICON")) {
+ ProString icon = project->first("ICON");
+ if (icon.length() >= 2 && (icon.at(0) == '"' || icon.at(0) == '\'') && icon.endsWith(icon.at(0))) {
+ icon = icon.mid(1, icon.length() - 2);
+ bundle_resources_files += keyFor(icon + ".BUILDABLE");
+ }
}
- path += project->first(ProKey(bundle_data[i] + ".path"));
- project->values("QMAKE_PBX_PRESCRIPT_BUILDPHASES").append(phase_key);
- t << "\t\t" << phase_key << " = {\n"
- << "\t\t\t" << writeSettings("name", "Bundle Copy [" + bundle_data[i] + "]") << ";" << "\n"
+
+ QString grp("Copy Bundle Resources"), key = keyFor(grp);
+ project->values("QMAKE_PBX_BUILDPHASES").append(key);
+ t << "\t\t" << key << " = {" << "\n"
<< "\t\t\t" << writeSettings("buildActionMask", "2147483647", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("dstPath", escapeFilePath(path)) << ";" << "\n"
- << "\t\t\t" << writeSettings("dstSubfolderSpec", "1", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("files", pbx_files, SettingsAsList, 4) << ";" << "\n"
- << "\t\t\t" << writeSettings("isa", "PBXCopyFilesBuildPhase", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("files", bundle_resources_files, SettingsAsList, 4) << ";" << "\n"
+ << "\t\t\t" << writeSettings("isa", "PBXResourcesBuildPhase", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("runOnlyForDeploymentPostprocessing", "0", SettingsNoQuote) << ";" << "\n"
- << "\t\t" << "}" << ";" << "\n";
+ << "\t\t\t" << writeSettings("name", escapeFilePath(grp)) << ";" << "\n"
+ << "\t\t" << "};" << "\n";
}
- QString bundle_copy_key = keyFor("QMAKE_PBX_BUNDLE_COPY");
- project->values("QMAKE_PBX_GROUPS").append(bundle_copy_key);
- t << "\t\t" << bundle_copy_key << " = {" << "\n"
+
+ QString bundle_data_key = keyFor("QMAKE_PBX_BUNDLE_DATA");
+ project->values("QMAKE_PBX_GROUPS").append(bundle_data_key);
+ t << "\t\t" << bundle_data_key << " = {" << "\n"
<< "\t\t\t" << writeSettings("children", bundle_file_refs, SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXGroup", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("name", "Source [bundle data]") << ";" << "\n"
- << "\t\t\t" << writeSettings("path", ProStringList()) << ";" << "\n"
- << "\t\t\t" << writeSettings("refType", "4", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("name", "Bundle Resources") << ";" << "\n"
<< "\t\t\t" << writeSettings("sourceTree", "<Group>") << ";" << "\n"
<< "\t\t" << "};" << "\n";
}
- //DUMP EVERYTHING THAT TIES THE ABOVE TOGETHER
- //ROOT_GROUP
- t << "\t\t" << keyFor("QMAKE_PBX_ROOT_GROUP") << " = {" << "\n"
- << "\t\t\t" << writeSettings("children", project->values("QMAKE_PBX_GROUPS"), SettingsAsList, 4) << ";" << "\n"
- << "\t\t\t" << writeSettings("isa", "PBXGroup", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("name", escapeFilePath(project->first("QMAKE_ORIG_TARGET"))) << ";" << "\n"
- << "\t\t\t" << writeSettings("path", ProStringList()) << ";" << "\n"
- << "\t\t\t" << writeSettings("refType", "4", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("sourceTree", "<Group>") << ";" << "\n"
- << "\t\t" << "};" << "\n";
//REFERENCE
project->values("QMAKE_PBX_PRODUCTS").append(keyFor(pbx_dir + "QMAKE_PBX_REFERENCE"));
t << "\t\t" << keyFor(pbx_dir + "QMAKE_PBX_REFERENCE") << " = {" << "\n"
- << "\t\t\t" << writeSettings("isa", "PBXFileReference", SettingsNoQuote) << ";" << "\n";
+ << "\t\t\t" << writeSettings("isa", "PBXFileReference", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("includeInIndex", "0", SettingsNoQuote) << ";" << "\n";
if(project->first("TEMPLATE") == "app") {
ProString targ = project->first("QMAKE_ORIG_TARGET");
if(project->isActiveConfig("bundle") && !project->isEmpty("QMAKE_BUNDLE_EXTENSION")) {
@@ -1115,7 +1145,7 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
targ += ".app";
t << "\t\t\t" << writeSettings("explicitFileType", "wrapper.application") << ";" << "\n";
} else {
- t << "\t\t\t" << writeSettings("explicitFileType", "wrapper.executable") << ";" << "\n";
+ t << "\t\t\t" << writeSettings("explicitFileType", "compiled.mach-o.executable") << ";" << "\n";
}
QString app = (!project->isEmpty("DESTDIR") ? project->first("DESTDIR") + project->first("QMAKE_ORIG_TARGET") :
qmake_getpwd()) + Option::dir_sep + targ;
@@ -1149,8 +1179,7 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
}
t << "\t\t\t" << writeSettings("path", escapeFilePath(lib)) << ";" << "\n";
}
- t << "\t\t\t" << writeSettings("refType", "3", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("sourceTree", "BUILT_PRODUCTS_DIR", SettingsNoQuote) << ";" << "\n"
+ t << "\t\t\t" << writeSettings("sourceTree", "BUILT_PRODUCTS_DIR", SettingsNoQuote) << ";" << "\n"
<< "\t\t" << "};" << "\n";
{ //Products group
QString grp("Products"), key = keyFor(grp);
@@ -1159,177 +1188,38 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
<< "\t\t\t" << writeSettings("children", project->values("QMAKE_PBX_PRODUCTS"), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXGroup", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("name", "Products") << ";" << "\n"
- << "\t\t\t" << writeSettings("refType", "4", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("sourceTree", "<Group>") << ";" << "\n"
<< "\t\t" << "};" << "\n";
}
+
+ //DUMP EVERYTHING THAT TIES THE ABOVE TOGETHER
+ //ROOT_GROUP
+ t << "\t\t" << keyFor("QMAKE_PBX_ROOT_GROUP") << " = {" << "\n"
+ << "\t\t\t" << writeSettings("children", project->values("QMAKE_PBX_GROUPS"), SettingsAsList, 4) << ";" << "\n"
+ << "\t\t\t" << writeSettings("isa", "PBXGroup", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("name", escapeFilePath(project->first("QMAKE_ORIG_TARGET"))) << ";" << "\n"
+ << "\t\t\t" << writeSettings("sourceTree", "<Group>") << ";" << "\n"
+ << "\t\t" << "};" << "\n";
+
//TARGET
QString target_key = keyFor(pbx_dir + "QMAKE_PBX_TARGET");
project->values("QMAKE_PBX_TARGETS").append(target_key);
t << "\t\t" << target_key << " = {" << "\n"
<< "\t\t\t" << writeSettings("buildPhases", project->values("QMAKE_PBX_PRESCRIPT_BUILDPHASES") + project->values("QMAKE_PBX_BUILDPHASES"),
- SettingsAsList, 4) << ";" << "\n"
- << "\t\t\t" << "buildSettings = {" << "\n";
- ProString cCompiler = project->first("QMAKE_CC");
- if (!cCompiler.isEmpty()) {
- t << "\t\t\t\t" << writeSettings("CC", fixForOutput(findProgram(cCompiler))) << ";" << "\n";
- }
- cCompiler = project->first("QMAKE_CXX");
- if (!cCompiler.isEmpty()) {
- t << "\t\t\t\t" << writeSettings("CPLUSPLUS", fixForOutput(findProgram(cCompiler))) << ";" << "\n";
- }
-
- t << "\t\t\t\t" << writeSettings("LEXFLAGS", fixListForOutput("QMAKE_LEXFLAGS")) << ";" << "\n"
- << "\t\t\t\t" << writeSettings("YACCFLAGS", fixListForOutput("QMAKE_YACCFLAGS")) << ";" << "\n"
- << "\t\t\t\t" << writeSettings("OTHER_REZFLAGS", ProStringList()) << ";" << "\n"
- << "\t\t\t\t" << writeSettings("SECTORDER_FLAGS", ProStringList()) << ";" << "\n"
- << "\t\t\t\t" << writeSettings("WARNING_CFLAGS", ProStringList()) << ";" << "\n"
- << "\t\t\t\t" << writeSettings("PREBINDING", ProStringList((project->isEmpty("QMAKE_DO_PREBINDING") ? "NO" : "YES")), SettingsNoQuote) << ";" << "\n";
- if((project->first("TEMPLATE") == "app" && project->isActiveConfig("app_bundle")) ||
- (project->first("TEMPLATE") == "lib" && !project->isActiveConfig("staticlib") &&
- project->isActiveConfig("lib_bundle"))) {
- QString plist = fileFixify(project->first("QMAKE_INFO_PLIST").toQString());
- if(plist.isEmpty())
- plist = specdir() + QDir::separator() + "Info.plist." + project->first("TEMPLATE");
- if(exists(plist)) {
- QFile plist_in_file(plist);
- if(plist_in_file.open(QIODevice::ReadOnly)) {
- QTextStream plist_in(&plist_in_file);
- QString plist_in_text = plist_in.readAll();
- plist_in_text = plist_in_text.replace("@ICON@",
- (project->isEmpty("ICON") ? QString("") : project->first("ICON").toQString().section(Option::dir_sep, -1)));
- if(project->first("TEMPLATE") == "app") {
- plist_in_text = plist_in_text.replace("@EXECUTABLE@", project->first("QMAKE_ORIG_TARGET").toQString());
- } else {
- plist_in_text = plist_in_text.replace("@LIBRARY@", project->first("QMAKE_ORIG_TARGET").toQString());
- }
- if (!project->values("VERSION").isEmpty()) {
- plist_in_text = plist_in_text.replace("@SHORT_VERSION@", project->first("VER_MAJ") + "." +
- project->first("VER_MIN"));
- }
- plist_in_text = plist_in_text.replace("@TYPEINFO@",
- (project->isEmpty("QMAKE_PKGINFO_TYPEINFO") ? QString::fromLatin1("????") :
- project->first("QMAKE_PKGINFO_TYPEINFO").left(4).toQString()));
- QFile plist_out_file("Info.plist");
- if(plist_out_file.open(QIODevice::WriteOnly | QIODevice::Text)) {
- QTextStream plist_out(&plist_out_file);
- plist_out << plist_in_text;
- t << "\t\t\t\t" << writeSettings("INFOPLIST_FILE", "Info.plist") << ";" << "\n";
- }
- }
- }
- }
-#if 1
- t << "\t\t\t\t" << writeSettings("BUILD_ROOT", escapeFilePath(qmake_getpwd())) << ";" << "\n";
-#endif
- if(!project->isActiveConfig("staticlib")) {
- t << "\t\t\t\t" << writeSettings("OTHER_LDFLAGS",
- fixListForOutput("SUBLIBS")
- + fixListForOutput("QMAKE_LFLAGS")
- + fixListForOutput("QMAKE_LIBS")
- + fixListForOutput("QMAKE_LIBS_PRIVATE"),
- SettingsAsList, 6) << ";" << "\n";
- }
- if(!project->isEmpty("DESTDIR")) {
- ProString dir = project->first("DESTDIR");
- if (QDir::isRelativePath(dir.toQString()))
- dir.prepend(qmake_getpwd() + Option::dir_sep);
- t << "\t\t\t\t" << writeSettings("INSTALL_DIR", dir) << ";" << "\n";
- }
- if (project->first("TEMPLATE") == "lib") {
- t << "\t\t\t\t" << writeSettings("INSTALL_PATH", ProStringList()) << ";" << "\n";
- }
- if(!project->isEmpty("VERSION") && project->first("VERSION") != "0.0.0") {
- t << "\t\t\t\t" << writeSettings("DYLIB_CURRENT_VERSION", project->first("VER_MAJ")+"."+project->first("VER_MIN")+"."+project->first("VER_PAT")) << ";" << "\n";
- if(project->isEmpty("COMPAT_VERSION"))
- t << "\t\t\t\t" << writeSettings("DYLIB_COMPATIBILITY_VERSION", project->first("VER_MAJ")+"."+project->first("VER_MIN")) << ";" << "\n";
- if(project->first("TEMPLATE") == "lib" && !project->isActiveConfig("staticlib") &&
- project->isActiveConfig("lib_bundle"))
- t << "\t\t\t\t" << writeSettings("FRAMEWORK_VERSION", project->first("QMAKE_FRAMEWORK_VERSION")) << ";" << "\n";
- }
- if(!project->isEmpty("COMPAT_VERSION"))
- t << "\t\t\t\t" << writeSettings("DYLIB_COMPATIBILITY_VERSION", project->first("COMPAT_VERSION")) << ";" << "\n";
- if(!project->isEmpty("QMAKE_MACOSX_DEPLOYMENT_TARGET"))
- t << "\t\t\t\t" << writeSettings("MACOSX_DEPLOYMENT_TARGET", project->first("QMAKE_MACOSX_DEPLOYMENT_TARGET")) << ";" << "\n";
- if(project->first("TEMPLATE") == "app") {
- t << "\t\t\t\t" << writeSettings("PRODUCT_NAME", fixForOutput(project->first("QMAKE_ORIG_TARGET").toQString())) << ";" << "\n";
- } else {
- if(!project->isActiveConfig("plugin") && project->isActiveConfig("staticlib")) {
- t << "\t\t\t\t" << writeSettings("LIBRARY_STYLE", "STATIC") << ";" << "\n";
- } else {
- t << "\t\t\t\t" << writeSettings("LIBRARY_STYLE", "DYNAMIC") << ";" << "\n";
- }
- ProString lib = project->first("QMAKE_ORIG_TARGET");
- if(!project->isActiveConfig("lib_bundle") && !project->isActiveConfig("staticlib"))
- lib.prepend("lib");
- t << "\t\t\t\t" << writeSettings("PRODUCT_NAME", escapeFilePath(lib)) << ";" << "\n";
- }
- tmp = project->values("QMAKE_PBX_VARS");
- for(int i = 0; i < tmp.count(); i++) {
- QString var = tmp[i].toQString(), val = QString::fromLocal8Bit(qgetenv(var.toLatin1().constData()));
- if(val.isEmpty() && var == "TB")
- val = "/usr/bin/";
- t << "\t\t\t\t" << writeSettings(var, escapeFilePath(val)) << ";" << "\n";
- }
- t << "\t\t\t" << "};" << "\n"
- << "\t\t\t" << "conditionalBuildSettings = {" << "\n"
- << "\t\t\t" << "};" << "\n"
- << "\t\t\t" << writeSettings("dependencies", project->values("QMAKE_PBX_TARGET_DEPENDS"), SettingsAsList, 4) << ";" << "\n"
- << "\t\t\t" << writeSettings("productReference", keyFor(pbx_dir + "QMAKE_PBX_REFERENCE")) << ";" << "\n"
- << "\t\t\t" << writeSettings("shouldUseHeadermap", "1", SettingsNoQuote) << ";" << "\n";
+ SettingsAsList, 4) << ";" << "\n";
+ t << "\t\t\t" << writeSettings("dependencies", project->values("QMAKE_PBX_TARGET_DEPENDS"), SettingsAsList, 4) << ";" << "\n"
+ << "\t\t\t" << writeSettings("productReference", keyFor(pbx_dir + "QMAKE_PBX_REFERENCE")) << ";" << "\n";
t << "\t\t\t" << writeSettings("buildConfigurationList", keyFor("QMAKE_PBX_BUILDCONFIG_LIST_TARGET"), SettingsNoQuote) << ";" << "\n";
t << "\t\t\t" << writeSettings("isa", "PBXNativeTarget", SettingsNoQuote) << ";" << "\n";
+ t << "\t\t\t" << writeSettings("buildRules", ProStringList(), SettingsAsList) << ";" << "\n";
if(project->first("TEMPLATE") == "app") {
- if(!project->isActiveConfig("app_bundle")) {
- if (!project->isEmpty("QMAKE_PBX_PRODUCT_TYPE"))
- t << "\t\t\t" << writeSettings("productType", project->first("QMAKE_PBX_PRODUCT_TYPE")) << ";" << "\n";
- else
- t << "\t\t\t" << writeSettings("productType", "com.apple.product-type.tool") << ";" << "\n";
+ if (!project->isEmpty("QMAKE_PBX_PRODUCT_TYPE")) {
+ t << "\t\t\t" << writeSettings("productType", project->first("QMAKE_PBX_PRODUCT_TYPE")) << ";" << "\n";
} else {
- if (!project->isEmpty("QMAKE_PBX_PRODUCT_TYPE"))
- t << "\t\t\t" << writeSettings("productType", project->first("QMAKE_PBX_PRODUCT_TYPE")) << ";" << "\n";
- else
+ if (project->isActiveConfig("app_bundle"))
t << "\t\t\t" << writeSettings("productType", "com.apple.product-type.application") << ";" << "\n";
- t << "\t\t\t" << "productSettingsXML = \"";
- bool read_plist = false;
- if(exists("Info.plist")) {
- QFile plist("Info.plist");
- if (plist.open(QIODevice::ReadOnly)) {
- read_plist = true;
- QTextStream stream(&plist);
- while(!stream.atEnd())
- t << stream.readLine().replace('"', "\\\"") << endl;
- }
- }
- if(!read_plist) {
- t << "<?xml version="
- << "\\\"1.0\\\" encoding=" << "\\\"UTF-8\\\"" << "?>" << "\n"
- << "\t\t\t\t" << "<!DOCTYPE plist SYSTEM \\\"file://localhost/System/"
- << "Library/DTDs/PropertyList.dtd\\\">" << "\n"
- << "\t\t\t\t" << "<plist version=\\\"0.9\\\">" << "\n"
- << "\t\t\t\t" << "<dict>" << "\n"
- << "\t\t\t\t\t" << "<key>CFBundleDevelopmentRegion</key>" << "\n"
- << "\t\t\t\t\t" << "<string>English</string>" << "\n"
- << "\t\t\t\t\t" << "<key>CFBundleExecutable</key>" << "\n"
- << "\t\t\t\t\t" << "<string>" << project->first("QMAKE_ORIG_TARGET") << "</string>" << "\n"
- << "\t\t\t\t\t" << "<key>CFBundleIconFile</key>" << "\n"
- << "\t\t\t\t\t" << "<string>" << var("ICON").section(Option::dir_sep, -1) << "</string>" << "\n"
- << "\t\t\t\t\t" << "<key>CFBundleInfoDictionaryVersion</key>" << "\n"
- << "\t\t\t\t\t" << "<string>6.0</string>" << "\n"
- << "\t\t\t\t\t" << "<key>CFBundlePackageType</key>" << "\n"
- << "\t\t\t\t\t" << "<string>APPL</string>" << "\n"
- << "\t\t\t\t\t" << "<key>CFBundleSignature</key>" << "\n"
- << "\t\t\t\t\t" << "<string>"
- << (project->isEmpty("QMAKE_PKGINFO_TYPEINFO") ? QString::fromLatin1("????") :
- project->first("QMAKE_PKGINFO_TYPEINFO").left(4)) << "</string>" << "\n"
- << "\t\t\t\t\t" << "<key>CFBundleVersion</key>" << "\n"
- << "\t\t\t\t\t" << "<string>0.1</string>" << "\n"
- << "\t\t\t\t\t" << "<key>CSResourcesFileMapped</key>" << "\n"
- << "\t\t\t\t\t" << "<true/>" << "\n"
- << "\t\t\t\t" << "</dict>" << "\n"
- << "\t\t\t\t" << "</plist>";
- }
- t << "\";" << "\n";
+ else
+ t << "\t\t\t" << writeSettings("productType", "com.apple.product-type.tool") << ";" << "\n";
}
t << "\t\t\t" << writeSettings("name", escapeFilePath(project->first("QMAKE_ORIG_TARGET"))) << ";" << "\n"
<< "\t\t\t" << writeSettings("productName", escapeFilePath(project->first("QMAKE_ORIG_TARGET"))) << ";" << "\n";
@@ -1348,12 +1238,11 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
else
t << "\t\t\t" << writeSettings("productType", "com.apple.product-type.library.dynamic") << ";" << "\n";
}
- t << "\t\t\t" << writeSettings("startupPath", "<<ProjectDirectory>>") << ";" << "\n";
if(!project->isEmpty("DESTDIR"))
t << "\t\t\t" << writeSettings("productInstallPath", escapeFilePath(project->first("DESTDIR"))) << ";" << "\n";
t << "\t\t" << "};" << "\n";
//DEBUG/RELEASE
- QString active_buildstyle;
+ QString defaultConfig;
for(int as_release = 0; as_release < 2; as_release++)
{
QMap<QString, QString> settings;
@@ -1384,6 +1273,8 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
}
QString name = (as_release ? "Release" : "Debug");
+ if (project->isActiveConfig("debug") != (bool)as_release)
+ defaultConfig = name;
for (int i = 0; i < buildConfigGroups.size(); i++) {
QString key = keyFor("QMAKE_PBX_BUILDCONFIG_" + name + buildConfigGroups.at(i));
project->values(ProKey("QMAKE_PBX_BUILDCONFIGS_" + buildConfigGroups.at(i))).append(key);
@@ -1392,15 +1283,104 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
<< "\t\t\t" << "buildSettings = {" << "\n";
for (QMap<QString, QString>::Iterator set_it = settings.begin(); set_it != settings.end(); ++set_it)
t << "\t\t\t\t" << writeSettings(set_it.key(), set_it.value()) << ";\n";
- if (!project->isEmpty("PRECOMPILED_HEADER")) {
- t << "\t\t\t\t" << writeSettings("GCC_PRECOMPILE_PREFIX_HEADER", "YES") << ";" << "\n"
- << "\t\t\t\t" << writeSettings("GCC_PREFIX_HEADER", escapeFilePath(project->first("PRECOMPILED_HEADER"))) << ";" << "\n";
- }
if (buildConfigGroups.at(i) == QLatin1String("PROJECT")) {
+ if (!project->isEmpty("QMAKE_XCODE_GCC_VERSION"))
+ t << "\t\t\t\t" << writeSettings("GCC_VERSION", project->first("QMAKE_XCODE_GCC_VERSION"), SettingsNoQuote) << ";" << "\n";
+ ProString program = project->first("QMAKE_CC");
+ if (!program.isEmpty())
+ t << "\t\t\t\t" << writeSettings("CC", fixForOutput(findProgram(program))) << ";" << "\n";
+ program = project->first("QMAKE_CXX");
+ // Xcode will automatically take care of using CC with the right -x option,
+ // and will actually break if we pass CPLUSPLUS, by adding an additional set of "++"
+ if (!program.isEmpty() && !program.contains("clang++"))
+ t << "\t\t\t\t" << writeSettings("CPLUSPLUS", fixForOutput(findProgram(program))) << ";" << "\n";
+ program = project->first("QMAKE_LINK");
+ if (!program.isEmpty())
+ t << "\t\t\t\t" << writeSettings("LDPLUSPLUS", fixForOutput(findProgram(program))) << ";" << "\n";
+
+ if ((project->first("TEMPLATE") == "app" && project->isActiveConfig("app_bundle")) ||
+ (project->first("TEMPLATE") == "lib" && !project->isActiveConfig("staticlib") &&
+ project->isActiveConfig("lib_bundle"))) {
+ QString plist = fileFixify(project->first("QMAKE_INFO_PLIST").toQString());
+ if (plist.isEmpty())
+ plist = specdir() + QDir::separator() + "Info.plist." + project->first("TEMPLATE");
+ if (exists(plist)) {
+ QFile plist_in_file(plist);
+ if (plist_in_file.open(QIODevice::ReadOnly)) {
+ QTextStream plist_in(&plist_in_file);
+ QString plist_in_text = plist_in.readAll();
+ plist_in_text = plist_in_text.replace("@ICON@",
+ (project->isEmpty("ICON") ? QString("") : project->first("ICON").toQString().section(Option::dir_sep, -1)));
+ if (project->first("TEMPLATE") == "app") {
+ plist_in_text = plist_in_text.replace("@EXECUTABLE@", project->first("QMAKE_ORIG_TARGET").toQString());
+ } else {
+ plist_in_text = plist_in_text.replace("@LIBRARY@", project->first("QMAKE_ORIG_TARGET").toQString());
+ }
+ plist_in_text = plist_in_text.replace("@BUNDLEIDENTIFIER@", QLatin1String("${PRODUCT_NAME:rfc1034identifier}"));
+ if (!project->values("VERSION").isEmpty()) {
+ plist_in_text = plist_in_text.replace("@SHORT_VERSION@", project->first("VER_MAJ") + "." +
+ project->first("VER_MIN"));
+ }
+ plist_in_text = plist_in_text.replace("@TYPEINFO@",
+ (project->isEmpty("QMAKE_PKGINFO_TYPEINFO")
+ ? QString::fromLatin1("????") : project->first("QMAKE_PKGINFO_TYPEINFO").left(4).toQString()));
+ QFile plist_out_file("Info.plist");
+ if (plist_out_file.open(QIODevice::WriteOnly | QIODevice::Text)) {
+ QTextStream plist_out(&plist_out_file);
+ plist_out << plist_in_text;
+ t << "\t\t\t\t" << writeSettings("INFOPLIST_FILE", "Info.plist") << ";" << "\n";
+ }
+ }
+ }
+ }
+
+ t << "\t\t\t\t" << writeSettings("SYMROOT", escapeFilePath(qmake_getpwd())) << ";" << "\n";
+
+ if (!project->isEmpty("DESTDIR")) {
+ ProString dir = project->first("DESTDIR");
+ if (QDir::isRelativePath(dir.toQString()))
+ dir.prepend(qmake_getpwd() + Option::dir_sep);
+ t << "\t\t\t\t" << writeSettings("TARGET_BUILD_DIR", dir) << ";" << "\n";
+ }
+
+ if (project->first("TEMPLATE") == "lib")
+ t << "\t\t\t\t" << writeSettings("INSTALL_PATH", ProStringList()) << ";" << "\n";
+
+ if (!project->isEmpty("VERSION") && project->first("VERSION") != "0.0.0") {
+ t << "\t\t\t\t" << writeSettings("DYLIB_CURRENT_VERSION", project->first("VER_MAJ")+"."+project->first("VER_MIN")+"."+project->first("VER_PAT")) << ";" << "\n";
+ if (project->isEmpty("COMPAT_VERSION"))
+ t << "\t\t\t\t" << writeSettings("DYLIB_COMPATIBILITY_VERSION", project->first("VER_MAJ")+"."+project->first("VER_MIN")) << ";" << "\n";
+ if (project->first("TEMPLATE") == "lib" && !project->isActiveConfig("staticlib") &&
+ project->isActiveConfig("lib_bundle"))
+ t << "\t\t\t\t" << writeSettings("FRAMEWORK_VERSION", project->first("QMAKE_FRAMEWORK_VERSION")) << ";" << "\n";
+ }
+ if (!project->isEmpty("COMPAT_VERSION"))
+ t << "\t\t\t\t" << writeSettings("DYLIB_COMPATIBILITY_VERSION", project->first("COMPAT_VERSION")) << ";" << "\n";
+
+ if (!project->isEmpty("QMAKE_MACOSX_DEPLOYMENT_TARGET"))
+ t << "\t\t\t\t" << writeSettings("MACOSX_DEPLOYMENT_TARGET", project->first("QMAKE_MACOSX_DEPLOYMENT_TARGET")) << ";" << "\n";
+ if (!project->isEmpty("QMAKE_IOS_DEPLOYMENT_TARGET"))
+ t << "\t\t\t\t" << writeSettings("IPHONEOS_DEPLOYMENT_TARGET", project->first("QMAKE_IOS_DEPLOYMENT_TARGET")) << ";" << "\n";
+
+ if (!project->isEmpty("QMAKE_XCODE_CODE_SIGN_IDENTITY"))
+ t << "\t\t\t\t" << writeSettings("CODE_SIGN_IDENTITY", project->first("QMAKE_XCODE_CODE_SIGN_IDENTITY")) << ";" << "\n";
+
+ tmp = project->values("QMAKE_PBX_VARS");
+ for (int i = 0; i < tmp.count(); i++) {
+ QString var = tmp[i].toQString(), val = QString::fromLocal8Bit(qgetenv(var.toLatin1().constData()));
+ if (val.isEmpty() && var == "TB")
+ val = "/usr/bin/";
+ t << "\t\t\t\t" << writeSettings(var, escapeFilePath(val)) << ";" << "\n";
+ }
+ if (!project->isEmpty("PRECOMPILED_HEADER")) {
+ t << "\t\t\t\t" << writeSettings("GCC_PRECOMPILE_PREFIX_HEADER", "YES") << ";" << "\n"
+ << "\t\t\t\t" << writeSettings("GCC_PREFIX_HEADER", escapeFilePath(project->first("PRECOMPILED_HEADER"))) << ";" << "\n";
+ }
t << "\t\t\t\t" << writeSettings("HEADER_SEARCH_PATHS", fixListForOutput("INCLUDEPATH") + ProStringList(fixForOutput(specdir())), SettingsAsList, 5) << ";" << "\n"
<< "\t\t\t\t" << writeSettings("LIBRARY_SEARCH_PATHS", fixListForOutput("QMAKE_PBX_LIBPATHS"), SettingsAsList, 5) << ";" << "\n"
- << "\t\t\t\t" << writeSettings("FRAMEWORK_SEARCH_PATHS", fixListForOutput("QMAKE_FRAMEWORKPATH"), SettingsAsList, 5) << ";" << "\n"
- << "\t\t\t\t" << writeSettings("INFOPLIST_FILE", "Info.plist") << ";" << "\n";
+ << "\t\t\t\t" << writeSettings("FRAMEWORK_SEARCH_PATHS", fixListForOutput("QMAKE_FRAMEWORKPATH"),
+ !project->values("QMAKE_FRAMEWORKPATH").isEmpty() ? SettingsAsList : 0, 5) << ";" << "\n";
+
{
ProStringList cflags = fixListForOutput("QMAKE_CFLAGS");
const ProStringList &prl_defines = project->values("PRL_EXPORT_DEFINES");
@@ -1451,20 +1431,6 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
t << "\t\t\t" << "};" << "\n"
<< "\t\t\t" << writeSettings("name", name) << ";" << "\n"
<< "\t\t" << "};" << "\n";
-
- key = keyFor("QMAKE_PBX_BUILDSTYLE_" + name);
- project->values("QMAKE_PBX_BUILDSTYLES").append(key);
- if (project->isActiveConfig("debug") != (bool)as_release)
- active_buildstyle = name;
- t << "\t\t" << key << " = {" << "\n"
- << "\t\t\t" << writeSettings("buildRules", ProStringList(), SettingsAsList, 4) << ";" << "\n"
- << "\t\t\t" << "buildSettings = {" << "\n";
- for(QMap<QString, QString>::Iterator set_it = settings.begin(); set_it != settings.end(); ++set_it)
- t << "\t\t\t\t" << writeSettings(set_it.key(), set_it.value()) << ";" << "\n";
- t << "\t\t\t" << "};" << "\n"
- << "\t\t\t" << writeSettings("isa", "PBXBuildStyle") << ";" << "\n"
- << "\t\t\t" << writeSettings("name", name) << ";" << "\n"
- << "\t\t" << "};" << "\n";
}
}
for (int i = 0; i < buildConfigGroups.size(); i++) {
@@ -1472,20 +1438,24 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
<< "\t\t\t" << writeSettings("isa", "XCConfigurationList", SettingsNoQuote) << ";" << "\n"
<< "\t\t\t" << writeSettings("buildConfigurations", project->values(ProKey("QMAKE_PBX_BUILDCONFIGS_" + buildConfigGroups.at(i))), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("defaultConfigurationIsVisible", "0", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("defaultConfigurationIsName", active_buildstyle) << ";" << "\n"
+ << "\t\t\t" << writeSettings("defaultConfigurationName", defaultConfig) << ";" << "\n"
<< "\t\t" << "};" << "\n";
}
//ROOT
t << "\t\t" << keyFor("QMAKE_PBX_ROOT") << " = {" << "\n"
- << "\t\t\t" << writeSettings("buildStyles", project->values("QMAKE_PBX_BUILDSTYLES"), SettingsAsList, 4) << ";" << "\n"
<< "\t\t\t" << writeSettings("hasScannedForEncodings", "1", SettingsNoQuote) << ";" << "\n"
+ << "\t\t\t" << writeSettings("compatibilityVersion", "Xcode 3.2") << ";" << "\n"
<< "\t\t\t" << writeSettings("isa", "PBXProject", SettingsNoQuote) << ";" << "\n"
- << "\t\t\t" << writeSettings("mainGroup", keyFor("QMAKE_PBX_ROOT_GROUP")) << ";" << "\n";
+ << "\t\t\t" << writeSettings("mainGroup", keyFor("QMAKE_PBX_ROOT_GROUP")) << ";" << "\n"
+ << "\t\t\t" << writeSettings("productRefGroup", keyFor("Products")) << ";" << "\n";
t << "\t\t\t" << writeSettings("buildConfigurationList", keyFor("QMAKE_PBX_BUILDCONFIG_LIST_PROJECT")) << ";" << "\n";
t << "\t\t\t" << writeSettings("projectDirPath", ProStringList()) << ";" << "\n"
+ << "\t\t\t" << writeSettings("projectRoot", "") << ";" << "\n"
<< "\t\t\t" << writeSettings("targets", project->values("QMAKE_PBX_TARGETS"), SettingsAsList, 4) << ";" << "\n"
<< "\t\t" << "};" << "\n";
+ // FIXME: Deal with developmentRegion and knownRegions for QMAKE_PBX_ROOT
+
//FOOTER
t << "\t" << "};" << "\n"
<< "\t" << writeSettings("rootObject", keyFor("QMAKE_PBX_ROOT")) << ";" << "\n"
@@ -1516,6 +1486,9 @@ ProjectBuilderMakefileGenerator::writeMakeParts(QTextStream &t)
writingUnixMakefileGenerator = false;
}
}
+
+ qmake_setpwd(input_dir);
+
return true;
}
@@ -1729,10 +1702,9 @@ ProjectBuilderMakefileGenerator::reftypeForFile(const QString &where)
QString ProjectBuilderMakefileGenerator::sourceTreeForFile(const QString &where)
{
- QString ret = "<absolute>";
- if (QDir::isRelativePath(unescapeFilePath(where)))
- ret = "SOURCE_ROOT"; //relative
- return ret;
+ // We always use absolute paths, instead of maintaining the SRCROOT
+ // build variable and making files relative to that.
+ return QLatin1String("<absolute>");
}
QString
diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp
index 3ea67fe6a5..d095bdf83d 100644
--- a/qmake/generators/makefile.cpp
+++ b/qmake/generators/makefile.cpp
@@ -295,8 +295,8 @@ MakefileGenerator::setProjectFile(QMakeProject *p)
project = p;
if (project->isActiveConfig("win32"))
target_mode = TARG_WIN_MODE;
- else if (project->isActiveConfig("macx"))
- target_mode = TARG_MACX_MODE;
+ else if (project->isActiveConfig("mac"))
+ target_mode = TARG_MAC_MODE;
else
target_mode = TARG_UNIX_MODE;
init();
@@ -442,6 +442,12 @@ MakefileGenerator::init()
}
}
+ if (v["QMAKE_CC_O_FLAG"].isEmpty())
+ v["QMAKE_CC_O_FLAG"].append("-o ");
+
+ if (v["QMAKE_LINK_O_FLAG"].isEmpty())
+ v["QMAKE_LINK_O_FLAG"].append("-o ");
+
ProStringList &quc = v["QMAKE_EXTRA_COMPILERS"];
//make sure the COMPILERS are in the correct input/output chain order
@@ -3227,7 +3233,7 @@ MakefileGenerator::writePkgConfigFile()
t << "Libs: ";
QString pkgConfiglibDir;
QString pkgConfiglibName;
- if (target_mode == TARG_MACX_MODE && project->isActiveConfig("lib_bundle")) {
+ if (target_mode == TARG_MAC_MODE && project->isActiveConfig("lib_bundle")) {
pkgConfiglibDir = "-F${libdir}";
ProString bundle;
if (!project->isEmpty("QMAKE_FRAMEWORK_BUNDLE_NAME"))
@@ -3265,10 +3271,10 @@ MakefileGenerator::writePkgConfigFile()
t << "Cflags: "
// << var("QMAKE_CXXFLAGS") << " "
<< varGlue("PRL_EXPORT_DEFINES","-D"," -D"," ")
- << project->values("PRL_EXPORT_CXXFLAGS").join(' ')
- << project->values("QMAKE_PKGCONFIG_CFLAGS").join(' ')
+ << varGlue("PRL_EXPORT_CXXFLAGS", "", " ", " ")
+ << varGlue("QMAKE_PKGCONFIG_CFLAGS", "", " ", " ")
// << varGlue("DEFINES","-D"," -D"," ")
- << " -I${includedir}" << endl;
+ << "-I${includedir}" << endl;
// requires
const QString requires = project->values("QMAKE_PKGCONFIG_REQUIRES").join(' ');
diff --git a/qmake/generators/makefile.h b/qmake/generators/makefile.h
index a0186d3d99..47acc8098f 100644
--- a/qmake/generators/makefile.h
+++ b/qmake/generators/makefile.h
@@ -90,7 +90,7 @@ class MakefileGenerator : protected QMakeSourceFileInfo
mutable QHash<ReplaceExtraCompilerCacheKey, QString> extraCompilerVariablesCache;
protected:
- enum TARG_MODE { TARG_UNIX_MODE, TARG_MACX_MODE, TARG_WIN_MODE } target_mode;
+ enum TARG_MODE { TARG_UNIX_MODE, TARG_MAC_MODE, TARG_WIN_MODE } target_mode;
ProStringList createObjectList(const ProStringList &sources);
diff --git a/qmake/generators/makefiledeps.cpp b/qmake/generators/makefiledeps.cpp
index a4f3e665b3..898903a423 100644
--- a/qmake/generators/makefiledeps.cpp
+++ b/qmake/generators/makefiledeps.cpp
@@ -392,8 +392,11 @@ bool QMakeSourceFileInfo::findDeps(SourceFile *file)
#else
fd = open(sourceFile.local().toLatin1().constData(), O_RDONLY);
#endif
- if(fd == -1 || fstat(fd, &fst) || S_ISDIR(fst.st_mode))
+ if (fd == -1 || fstat(fd, &fst) || S_ISDIR(fst.st_mode)) {
+ if (fd != -1)
+ QT_CLOSE(fd);
return false;
+ }
buffer = getBuffer(fst.st_size);
for(int have_read = 0;
(have_read = QT_READ(fd, buffer + buffer_len, fst.st_size - buffer_len));
@@ -702,8 +705,11 @@ bool QMakeSourceFileInfo::findMocs(SourceFile *file)
#else
fd = open(fixPathForFile(file->file, true).local().toLocal8Bit().constData(), O_RDONLY);
#endif
- if(fd == -1 || fstat(fd, &fst) || S_ISDIR(fst.st_mode))
+ if (fd == -1 || fstat(fd, &fst) || S_ISDIR(fst.st_mode)) {
+ if (fd != -1)
+ QT_CLOSE(fd);
return false; //shouldn't happen
+ }
buffer = getBuffer(fst.st_size);
for(int have_read = buffer_len = 0;
(have_read = QT_READ(fd, buffer + buffer_len, fst.st_size - buffer_len));
diff --git a/qmake/generators/unix/unixmake.cpp b/qmake/generators/unix/unixmake.cpp
index da0da53e05..9adcc3af7c 100644
--- a/qmake/generators/unix/unixmake.cpp
+++ b/qmake/generators/unix/unixmake.cpp
@@ -142,6 +142,7 @@ UnixMakefileGenerator::init()
project->values("QMAKE_L_FLAG")
<< (project->isActiveConfig("rvct_linker") ? "--userlibpath "
: project->isActiveConfig("armcc_linker") ? "-L--userlibpath="
+ : project->isActiveConfig("ti_linker") ? "--search_path="
: "-L");
ProStringList ldadd;
if(!project->isEmpty("QMAKE_LIBDIR")) {
@@ -255,10 +256,10 @@ UnixMakefileGenerator::init()
const ProKey runComp("QMAKE_RUN_" + compiler);
if(project->isEmpty(runComp))
- project->values(runComp).append("$(" + compiler + ") " + compile_flag + " -o $obj $src");
+ project->values(runComp).append("$(" + compiler + ") " + compile_flag + " " + var("QMAKE_CC_O_FLAG") + "$obj $src");
const ProKey runCompImp("QMAKE_RUN_" + compiler + "_IMP");
if(project->isEmpty(runCompImp))
- project->values(runCompImp).append("$(" + compiler + ") " + compile_flag + " -o \"$@\" \"$<\"");
+ project->values(runCompImp).append("$(" + compiler + ") " + compile_flag + " " + var("QMAKE_CC_O_FLAG") + "\"$@\" \"$<\"");
}
if(project->isActiveConfig("macx") && !project->isEmpty("TARGET") && !project->isActiveConfig("compile_libtool") &&
@@ -490,10 +491,12 @@ UnixMakefileGenerator::findLibraries()
} else if(opt.startsWith("-l")) {
if (project->isActiveConfig("rvct_linker") || project->isActiveConfig("armcc_linker")) {
(*it) = "lib" + opt.mid(2) + ".so";
+ } else if (project->isActiveConfig("ti_linker")) {
+ (*it) = opt.mid(2);
} else {
stub = opt.mid(2);
}
- } else if (target_mode == TARG_MACX_MODE && opt.startsWith("-framework")) {
+ } else if (target_mode == TARG_MAC_MODE && opt.startsWith("-framework")) {
if (opt.length() == 10)
++it;
// Skip
@@ -607,11 +610,11 @@ UnixMakefileGenerator::processPrlFiles()
break;
}
}
- } else if (target_mode == TARG_MACX_MODE && opt.startsWith("-F")) {
+ } else if (target_mode == TARG_MAC_MODE && opt.startsWith("-F")) {
QMakeLocalFileName f(opt.right(opt.length()-2));
if(!frameworkdirs.contains(f))
frameworkdirs.insert(fwidx++, f);
- } else if (target_mode == TARG_MACX_MODE && opt.startsWith("-framework")) {
+ } else if (target_mode == TARG_MAC_MODE && opt.startsWith("-framework")) {
if(opt.length() > 11)
opt = opt.mid(11);
else
@@ -650,7 +653,7 @@ UnixMakefileGenerator::processPrlFiles()
ProKey arch("default");
ProString opt = l.at(lit).trimmed();
if(opt.startsWith("-")) {
- if (target_mode == TARG_MACX_MODE && opt.startsWith("-Xarch")) {
+ if (target_mode == TARG_MAC_MODE && opt.startsWith("-Xarch")) {
if (opt.length() > 7) {
arch = opt.mid(7).toKey();
opt = l.at(++lit);
@@ -658,7 +661,7 @@ UnixMakefileGenerator::processPrlFiles()
}
if (opt.startsWith(libArg) ||
- (target_mode == TARG_MACX_MODE && opt.startsWith("-F"))) {
+ (target_mode == TARG_MAC_MODE && opt.startsWith("-F"))) {
if(!lflags[arch].contains(opt))
lflags[arch].append(opt);
} else if(opt.startsWith("-l") || opt == "-pthread") {
@@ -666,12 +669,12 @@ UnixMakefileGenerator::processPrlFiles()
if (lflags[arch].contains(opt))
lflags[arch].removeAll(opt);
lflags[arch].append(opt);
- } else if (target_mode == TARG_MACX_MODE && opt.startsWith("-framework")) {
+ } else if (target_mode == TARG_MAC_MODE && opt.startsWith("-framework")) {
if(opt.length() > 11)
opt = opt.mid(11);
else {
opt = l.at(++lit);
- if (target_mode == TARG_MACX_MODE && opt.startsWith("-Xarch"))
+ if (target_mode == TARG_MAC_MODE && opt.startsWith("-Xarch"))
opt = l.at(++lit); // The user has done the right thing and prefixed each part
}
bool found = false;
@@ -833,7 +836,7 @@ UnixMakefileGenerator::defaultInstall(const QString &t)
uninst.append("-$(DEL_FILE) \"" + dst_targ + "\"");
if(!links.isEmpty()) {
for(int i = 0; i < links.size(); ++i) {
- if (target_mode == TARG_UNIX_MODE || target_mode == TARG_MACX_MODE) {
+ if (target_mode == TARG_UNIX_MODE || target_mode == TARG_MAC_MODE) {
QString link = Option::fixPathToTargetOS(destdir + links[i], false);
int lslash = link.lastIndexOf(Option::dir_sep);
if(lslash != -1)
diff --git a/qmake/generators/unix/unixmake2.cpp b/qmake/generators/unix/unixmake2.cpp
index 41e40e0bb6..9cb63ce539 100644
--- a/qmake/generators/unix/unixmake2.cpp
+++ b/qmake/generators/unix/unixmake2.cpp
@@ -349,7 +349,8 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t)
<< project->first("QMAKE_EXTENSION_STATICLIB") << " ";
t << endl << endl;
}
- if(project->isActiveConfig("depend_prl") && !project->isEmpty("QMAKE_PRL_INTERNAL_FILES")) {
+ if ((project->isActiveConfig("depend_prl") || project->isActiveConfig("fast_depend_prl"))
+ && !project->isEmpty("QMAKE_PRL_INTERNAL_FILES")) {
const ProStringList &l = project->values("QMAKE_PRL_INTERNAL_FILES");
ProStringList::ConstIterator it;
for(it = l.begin(); it != l.end(); ++it) {
@@ -361,8 +362,12 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t)
dir = (*it).left(slsh + 1);
QString targ = dir + libinfo.first("QMAKE_PRL_TARGET");
target_deps += " " + targ;
- t << targ << ":" << "\n\t"
- << "@echo \"Creating '" << targ << "'\"" << "\n\t"
+ t << targ;
+ if (project->isActiveConfig("fast_depend_prl"))
+ t << ":\n\t@echo \"Creating '";
+ else
+ t << ": FORCE\n\t@echo \"Creating/updating '";
+ t << targ << "'\"" << "\n\t"
<< "(cd " << libinfo.first("QMAKE_PRL_BUILD_DIR") << ";"
<< "$(MAKE))" << endl;
}
@@ -436,7 +441,7 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t)
t << "\n\t" << mkdir_p_asstring(destdir) << "\n\t";
if(!project->isEmpty("QMAKE_PRE_LINK"))
t << var("QMAKE_PRE_LINK") << "\n\t";
- t << "$(LINK) $(LFLAGS) -o $(TARGET) " << incr_deps << " " << incr_objs << " $(OBJCOMP) $(LIBS)";
+ t << "$(LINK) $(LFLAGS) " << var("QMAKE_LINK_O_FLAG") << "$(TARGET) " << incr_deps << " " << incr_objs << " $(OBJCOMP) $(LIBS)";
if(!project->isEmpty("QMAKE_POST_LINK"))
t << "\n\t" << var("QMAKE_POST_LINK");
t << endl << endl;
@@ -451,7 +456,7 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t)
t << mkdir_p_asstring(destdir) << "\n\t";
if (!project->isEmpty("QMAKE_PRE_LINK"))
t << var("QMAKE_PRE_LINK") << "\n\t";
- t << "$(LINK) $(LFLAGS) -o $(TARGET) $(OBJECTS) $(OBJCOMP) $(LIBS)";
+ t << "$(LINK) $(LFLAGS) " << var("QMAKE_LINK_O_FLAG") << "$(TARGET) $(OBJECTS) $(OBJCOMP) $(LIBS)";
if (!project->isEmpty("QMAKE_POST_LINK"))
t << "\n\t" << var("QMAKE_POST_LINK");
}
@@ -503,7 +508,7 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t)
t << incr_target_dir << ": $(INCREMENTAL_OBJECTS)" << "\n\t";
if(!destdir.isEmpty())
t << mkdir_p_asstring(destdir) << "\n\t";
- t << "$(LINK) " << incr_lflags << " -o "<< incr_target_dir <<
+ t << "$(LINK) " << incr_lflags << " " << var("QMAKE_LINK_O_FLAG") << incr_target_dir <<
" $(INCREMENTAL_OBJECTS)" << endl;
//communicated below
ProStringList &cmd = project->values("QMAKE_LINK_SHLIB_CMD");
@@ -574,7 +579,10 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t)
<< "-$(DEL_FILE) " << destdir << "$(TARGET0)\n\t"
<< "-$(DEL_FILE) " << destdir << "$(TARGET1)\n\t"
<< "-$(DEL_FILE) " << destdir << "$(TARGET2)\n\t"
- << "-$(MOVE) $(TARGET) $(TARGET0) $(TARGET1) $(TARGET2) " << destdir;
+ << "-$(MOVE) $(TARGET) " << destdir << "\n\t"
+ << "-$(MOVE) $(TARGET0) " << destdir << "\n\t"
+ << "-$(MOVE) $(TARGET1) " << destdir << "\n\t"
+ << "-$(MOVE) $(TARGET2) " << destdir << "\n\t";
if(!project->isEmpty("QMAKE_POST_LINK"))
t << "\n\t" << var("QMAKE_POST_LINK");
t << endl << endl;
@@ -587,7 +595,8 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t)
t << "\n\t"
<< "-$(DEL_FILE) " << destdir << "$(TARGET)\n\t"
<< "-$(DEL_FILE) " << destdir << "$(TARGET0)\n\t"
- << "-$(MOVE) $(TARGET) $(TARGET0) " << destdir;
+ << "-$(MOVE) $(TARGET) " << destdir << "\n\t"
+ << "-$(MOVE) $(TARGET0) " << destdir << "\n\t";
if(!project->isEmpty("QMAKE_POST_LINK"))
t << "\n\t" << var("QMAKE_POST_LINK");
t << endl << endl;
@@ -1173,7 +1182,7 @@ void UnixMakefileGenerator::init2()
}
if (project->values("QMAKE_LINK_SHLIB_CMD").isEmpty())
project->values("QMAKE_LINK_SHLIB_CMD").append(
- "$(LINK) $(LFLAGS) -o $(TARGET) $(OBJECTS) $(LIBS) $(OBJCOMP)");
+ "$(LINK) $(LFLAGS) " + project->first("QMAKE_LINK_O_FLAG") + "$(TARGET) $(OBJECTS) $(LIBS) $(OBJCOMP)");
}
if (!project->values("QMAKE_APP_FLAG").isEmpty()) {
project->values("QMAKE_CFLAGS") += project->values("QMAKE_CFLAGS_APP");
@@ -1218,7 +1227,7 @@ void UnixMakefileGenerator::init2()
}
if(!project->isEmpty("QMAKE_BUNDLE")) {
- QString plist = fileFixify(project->first("QMAKE_INFO_PLIST").toQString());
+ QString plist = fileFixify(project->first("QMAKE_INFO_PLIST").toQString(), qmake_getpwd());
if(plist.isEmpty())
plist = specdir() + QDir::separator() + "Info.plist." + project->first("TEMPLATE");
if(exists(Option::fixPathToLocalOS(plist))) {
diff --git a/qmake/generators/win32/mingw_make.cpp b/qmake/generators/win32/mingw_make.cpp
index 06e25c29f3..be4f203f01 100644
--- a/qmake/generators/win32/mingw_make.cpp
+++ b/qmake/generators/win32/mingw_make.cpp
@@ -299,16 +299,16 @@ void MingwMakefileGenerator::init()
project->values("QMAKE_RUN_CC").clear();
project->values("QMAKE_RUN_CC").append("$(CC) -c -include " + preCompHeader +
- " $(CFLAGS) $(INCPATH) -o $obj $src");
+ " $(CFLAGS) $(INCPATH) " + var("QMAKE_CC_O_FLAG") + "$obj $src");
project->values("QMAKE_RUN_CC_IMP").clear();
project->values("QMAKE_RUN_CC_IMP").append("$(CC) -c -include " + preCompHeader +
- " $(CFLAGS) $(INCPATH) -o $@ $<");
+ " $(CFLAGS) $(INCPATH) " + var("QMAKE_CC_O_FLAG") + "$@ $<");
project->values("QMAKE_RUN_CXX").clear();
project->values("QMAKE_RUN_CXX").append("$(CXX) -c -include " + preCompHeader +
- " $(CXXFLAGS) $(INCPATH) -o $obj $src");
+ " $(CXXFLAGS) $(INCPATH) " + var("QMAKE_CC_O_FLAG") + "$obj $src");
project->values("QMAKE_RUN_CXX_IMP").clear();
project->values("QMAKE_RUN_CXX_IMP").append("$(CXX) -c -include " + preCompHeader +
- " $(CXXFLAGS) $(INCPATH) -o $@ $<");
+ " $(CXXFLAGS) $(INCPATH) " + var("QMAKE_CC_O_FLAG") + "$@ $<");
}
if(project->isActiveConfig("dll")) {
@@ -405,7 +405,7 @@ void MingwMakefileGenerator::writeBuildRulesPart(QTextStream &t)
t << "\n\t" << objectsLinkLine << " " ;
}
} else if (project->first("TEMPLATE") != "aux") {
- t << "\n\t" << "$(LINKER) $(LFLAGS) -o $(DESTDIR_TARGET) " << objectsLinkLine << " " << " $(LIBS)";
+ t << "\n\t" << "$(LINKER) $(LFLAGS) " << var("QMAKE_LINK_O_FLAG") << "$(DESTDIR_TARGET) " << objectsLinkLine << " " << " $(LIBS)";
}
if(!project->isEmpty("QMAKE_POST_LINK"))
t << "\n\t" <<var("QMAKE_POST_LINK");
@@ -431,7 +431,7 @@ void MingwMakefileGenerator::writeRcFilePart(QTextStream &t)
if (!rc_file.isEmpty()) {
t << escapeDependencyPath(var("RES_FILE")) << ": " << rc_file << "\n\t"
- << var("QMAKE_RC") << " -i " << rc_file << " -o " << var("RES_FILE")
+ << var("QMAKE_RC") << " -i " << rc_file << " -o " << var("RES_FILE")
<< incPathStr << " $(DEFINES)" << endl << endl;
}
}
diff --git a/qmake/generators/win32/mingw_make.h b/qmake/generators/win32/mingw_make.h
index 6bdcb7ea70..0e1267994e 100644
--- a/qmake/generators/win32/mingw_make.h
+++ b/qmake/generators/win32/mingw_make.h
@@ -65,7 +65,7 @@ private:
void writeRcFilePart(QTextStream &t);
QStringList &findDependencies(const QString &file);
-
+
QString preCompHeaderOut;
virtual bool findLibraries();
diff --git a/qmake/generators/win32/msvc_nmake.cpp b/qmake/generators/win32/msvc_nmake.cpp
index 8b40d4e935..e2c9fdbf37 100644
--- a/qmake/generators/win32/msvc_nmake.cpp
+++ b/qmake/generators/win32/msvc_nmake.cpp
@@ -49,7 +49,7 @@
QT_BEGIN_NAMESPACE
-NmakeMakefileGenerator::NmakeMakefileGenerator() : Win32MakefileGenerator(), init_flag(false)
+NmakeMakefileGenerator::NmakeMakefileGenerator() : Win32MakefileGenerator(), init_flag(false), usePCH(false)
{
}
@@ -276,6 +276,9 @@ void NmakeMakefileGenerator::init()
project->values("QMAKE_LFLAGS").append("/VERSION:" + major + "." + minor);
}
+ if (project->isEmpty("QMAKE_LINK_O_FLAG"))
+ project->values("QMAKE_LINK_O_FLAG").append("/OUT:");
+
// Base class init!
MakefileGenerator::init();
@@ -304,6 +307,10 @@ void NmakeMakefileGenerator::init()
project->values("QMAKE_CLEAN").append(project->first("DESTDIR") + project->first("TARGET") + version + ".ilk");
project->values("QMAKE_CLEAN").append("vc*.pdb");
project->values("QMAKE_CLEAN").append("vc*.idb");
+ } else {
+ ProStringList &defines = project->values("DEFINES");
+ if (!defines.contains("NDEBUG"))
+ defines.append("NDEBUG");
}
}
@@ -377,7 +384,7 @@ void NmakeMakefileGenerator::writeBuildRulesPart(QTextStream &t)
if(!project->isEmpty("QMAKE_PRE_LINK"))
t << "\n\t" <<var("QMAKE_PRE_LINK");
if(project->isActiveConfig("staticlib")) {
- t << "\n\t" << "$(LIBAPP) $(LIBFLAGS) /OUT:$(DESTDIR_TARGET) @<<" << "\n\t "
+ t << "\n\t" << "$(LIBAPP) $(LIBFLAGS) " << var("QMAKE_LINK_O_FLAG") << "$(DESTDIR_TARGET) @<<" << "\n\t "
<< "$(OBJECTS)"
<< "\n<<";
} else if (templateName != "aux") {
@@ -443,7 +450,7 @@ void NmakeMakefileGenerator::writeBuildRulesPart(QTextStream &t)
}
}
QString signature = !project->isEmpty("SIGNATURE_FILE") ? var("SIGNATURE_FILE") : var("DEFAULT_SIGNATURE");
- bool useSignature = !signature.isEmpty() && !project->isActiveConfig("staticlib") &&
+ bool useSignature = !signature.isEmpty() && !project->isActiveConfig("staticlib") &&
!project->isEmpty("CE_SDK") && !project->isEmpty("CE_ARCH");
if(useSignature) {
t << "\n\tsigntool sign /F " << signature << " $(DESTDIR_TARGET)";
@@ -459,7 +466,7 @@ void NmakeMakefileGenerator::writeLinkCommand(QTextStream &t, const QString &ext
t << "$(LINKER) $(LFLAGS)";
if (!extraFlags.isEmpty())
t << ' ' << extraFlags;
- t << " /OUT:$(DESTDIR_TARGET) @<<\n"
+ t << " " << var("QMAKE_LINK_O_FLAG") << "$(DESTDIR_TARGET) @<<\n"
<< "$(OBJECTS) $(LIBS)";
if (!extraInlineFileContent.isEmpty())
t << ' ' << extraInlineFileContent;
diff --git a/qmake/generators/win32/msvc_vcproj.cpp b/qmake/generators/win32/msvc_vcproj.cpp
index c7dfc13a71..d3187bacb5 100644
--- a/qmake/generators/win32/msvc_vcproj.cpp
+++ b/qmake/generators/win32/msvc_vcproj.cpp
@@ -981,12 +981,8 @@ void VcprojGenerator::initConfiguration()
initDeploymentTool();
initPreLinkEventTools();
- // Set definite values in both configurations
- if (isDebug) {
- conf.compiler.PreprocessorDefinitions.removeAll("NDEBUG");
- } else {
+ if (!isDebug)
conf.compiler.PreprocessorDefinitions += "NDEBUG";
- }
}
void VcprojGenerator::initCompilerTool()
@@ -1061,10 +1057,6 @@ void VcprojGenerator::initLinkerTool()
conf.linker.OutputFile = "$(OutDir)\\";
conf.linker.OutputFile += project->first("MSVCPROJ_TARGET").toQString();
-
- if(project->isActiveConfig("dll")){
- conf.linker.parseOptions(project->values("QMAKE_LFLAGS_QT_DLL"));
- }
}
void VcprojGenerator::initResourceTool()
diff --git a/qmake/generators/win32/winmakefile.cpp b/qmake/generators/win32/winmakefile.cpp
index cac63ed932..08674a323c 100644
--- a/qmake/generators/win32/winmakefile.cpp
+++ b/qmake/generators/win32/winmakefile.cpp
@@ -77,7 +77,7 @@ Win32MakefileGenerator::findHighestVersion(const QString &d, const QString &stem
return vover.first().toInt();
int biggest=-1;
- if(!project->isActiveConfig("no_versionlink")) {
+ if (project->isActiveConfig("link_highest_lib_version")) {
static QHash<QString, QStringList> dirEntryListCache;
QStringList entries = dirEntryListCache.value(bd);
if (entries.isEmpty()) {
@@ -122,7 +122,7 @@ Win32MakefileGenerator::findLibraries()
if(opt.startsWith("/LIBPATH:")) {
dirs.append(QMakeLocalFileName(opt.mid(9)));
} else if(opt.startsWith("-L") || opt.startsWith("/L")) {
- QString libpath = opt.mid(2);
+ QString libpath = Option::fixPathToTargetOS(opt.mid(2), false, false);
QMakeLocalFileName l(libpath);
if(!dirs.contains(l)) {
dirs.append(l);
diff --git a/qmake/library/qmakebuiltins.cpp b/qmake/library/qmakebuiltins.cpp
index f46d66ba89..0dedd64e6e 100644
--- a/qmake/library/qmakebuiltins.cpp
+++ b/qmake/library/qmakebuiltins.cpp
@@ -467,8 +467,7 @@ ProStringList QMakeEvaluator::evaluateBuiltinExpand(
QString tmp = args.at(0).toQString(m_tmp1);
for (int i = 1; i < args.count(); ++i)
tmp = tmp.arg(args.at(i).toQString(m_tmp2));
- // Note: this depends on split_value_list() making a deep copy
- ret = split_value_list(tmp);
+ ret << ProString(tmp);
}
break;
case E_FORMAT_NUMBER:
@@ -561,7 +560,7 @@ ProStringList QMakeEvaluator::evaluateBuiltinExpand(
src = s;
break;
}
- ret = split_value_list(before + var.join(glue) + after, src);
+ ret << ProString(before + var.join(glue) + after).setSource(src);
}
}
break;
diff --git a/qmake/library/qmakeevaluator.cpp b/qmake/library/qmakeevaluator.cpp
index 25a70d2fea..0515fe1c98 100644
--- a/qmake/library/qmakeevaluator.cpp
+++ b/qmake/library/qmakeevaluator.cpp
@@ -126,6 +126,7 @@ void QMakeEvaluator::initStatics()
statics.strforever = QLatin1String("forever");
statics.strhost_build = QLatin1String("host_build");
statics.strTEMPLATE = ProKey("TEMPLATE");
+ statics.strQMAKE_PLATFORM = ProKey("QMAKE_PLATFORM");
#ifdef PROEVALUATOR_FULL
statics.strREQUIRES = ProKey("REQUIRES");
#endif
@@ -263,48 +264,55 @@ ProStringList QMakeEvaluator::split_value_list(const QString &vals, const ProFil
{
QString build;
ProStringList ret;
- QStack<char> quote;
-
- const ushort SPACE = ' ';
- const ushort LPAREN = '(';
- const ushort RPAREN = ')';
- const ushort SINGLEQUOTE = '\'';
- const ushort DOUBLEQUOTE = '"';
- const ushort BACKSLASH = '\\';
if (!source)
source = currentProFile();
- ushort unicode;
const QChar *vals_data = vals.data();
const int vals_len = vals.length();
- int parens = 0;
+ ushort quote = 0;
+ bool hadWord = false;
for (int x = 0; x < vals_len; x++) {
- unicode = vals_data[x].unicode();
- if (x != (int)vals_len-1 && unicode == BACKSLASH &&
- (vals_data[x+1].unicode() == SINGLEQUOTE || vals_data[x+1].unicode() == DOUBLEQUOTE)) {
- build += vals_data[x++]; //get that 'escape'
- } else if (!quote.isEmpty() && unicode == quote.top()) {
- quote.pop();
- } else if (unicode == SINGLEQUOTE || unicode == DOUBLEQUOTE) {
- quote.push(unicode);
- } else if (unicode == RPAREN) {
- --parens;
- } else if (unicode == LPAREN) {
- ++parens;
+ ushort unicode = vals_data[x].unicode();
+ if (unicode == quote) {
+ quote = 0;
+ continue;
}
-
- if (!parens && quote.isEmpty() && vals_data[x] == SPACE) {
- ret << ProString(build).setSource(source);
- build.clear();
- } else {
- build += vals_data[x];
+ switch (unicode) {
+ case '"':
+ case '\'':
+ quote = unicode;
+ hadWord = true;
+ continue;
+ case ' ':
+ case '\t':
+ if (!quote) {
+ if (hadWord) {
+ ret << ProString(build).setSource(source);
+ build.clear();
+ hadWord = false;
+ }
+ continue;
+ }
+ build += QChar(unicode);
+ break;
+ case '\\':
+ if (x + 1 != vals_len) {
+ ushort next = vals_data[++x].unicode();
+ if (next == '\'' || next == '"' || next == '\\')
+ unicode = next;
+ else
+ --x;
+ }
+ // fallthrough
+ default:
+ hadWord = true;
+ build += QChar(unicode);
+ break;
}
}
- if (!build.isEmpty())
+ if (hadWord)
ret << ProString(build).setSource(source);
- if (parens)
- deprecationWarning(fL1S("Unmatched parentheses are deprecated."));
return ret;
}
@@ -924,6 +932,8 @@ void QMakeEvaluator::visitProVariable(
if (varName == statics.strTEMPLATE)
setTemplate();
+ else if (varName == statics.strQMAKE_PLATFORM)
+ updateFeaturePaths();
#ifdef PROEVALUATOR_FULL
else if (varName == statics.strREQUIRES)
checkRequirements(values(varName));
@@ -1217,7 +1227,6 @@ bool QMakeEvaluator::loadSpec()
}
if (!loadSpecInternal())
return false;
- updateFeaturePaths(); // The spec extends the feature search path, so rebuild the cache.
if (!m_conffile.isEmpty()
&& evaluateFile(m_conffile, QMakeHandler::EvalConfigFile, LoadProOnly) != ReturnTrue) {
return false;
diff --git a/qmake/library/qmakeevaluator_p.h b/qmake/library/qmakeevaluator_p.h
index 9830496424..935f112f52 100644
--- a/qmake/library/qmakeevaluator_p.h
+++ b/qmake/library/qmakeevaluator_p.h
@@ -89,6 +89,7 @@ struct QMakeStatics {
QString strforever;
QString strhost_build;
ProKey strTEMPLATE;
+ ProKey strQMAKE_PLATFORM;
#ifdef PROEVALUATOR_FULL
ProKey strREQUIRES;
#endif
diff --git a/qmake/library/qmakeglobals.cpp b/qmake/library/qmakeglobals.cpp
index ac9a0856ff..42bb85bb02 100644
--- a/qmake/library/qmakeglobals.cpp
+++ b/qmake/library/qmakeglobals.cpp
@@ -115,7 +115,6 @@ QMakeGlobals::QMakeGlobals()
dirlist_sep = QLatin1Char(':');
dir_sep = QLatin1Char('/');
#endif
- qmakespec = getEnv(QLatin1String("QMAKESPEC"));
}
QMakeGlobals::~QMakeGlobals()
diff --git a/qmake/library/qmakeparser.cpp b/qmake/library/qmakeparser.cpp
index f32267cf59..557a779717 100644
--- a/qmake/library/qmakeparser.cpp
+++ b/qmake/library/qmakeparser.cpp
@@ -1024,7 +1024,6 @@ void QMakeParser::finalizeCall(ushort *&tokPtr, ushort *uc, ushort *ptr, int arg
m_tmp.setRawData((QChar *)uc + 4, nlen);
const QString *defName;
ushort defType;
- uchar nest;
if (m_tmp == statics.strfor) {
if (m_invert || m_operator == OrOperator) {
// '|' could actually work reasonably, but qmake does nonsense here.
@@ -1101,13 +1100,20 @@ void QMakeParser::finalizeCall(ushort *&tokPtr, ushort *uc, ushort *ptr, int arg
parseError(fL1S("%1(function) requires one literal argument.").arg(*defName));
return;
} else if (m_tmp == statics.strreturn) {
- if (argc > 1) {
- parseError(fL1S("return() requires zero or one argument."));
- bogusTest(tokPtr);
- return;
+ if (m_blockstack.top().nest & NestFunction) {
+ if (argc > 1) {
+ parseError(fL1S("return() requires zero or one argument."));
+ bogusTest(tokPtr);
+ return;
+ }
+ } else {
+ if (*uce != TokFuncTerminator) {
+ parseError(fL1S("Top-level return() requires zero arguments."));
+ bogusTest(tokPtr);
+ return;
+ }
}
defType = TokReturn;
- nest = NestFunction;
goto ctrlstm2;
} else if (m_tmp == statics.strnext) {
defType = TokNext;
@@ -1120,15 +1126,14 @@ void QMakeParser::finalizeCall(ushort *&tokPtr, ushort *uc, ushort *ptr, int arg
bogusTest(tokPtr);
return;
}
- nest = NestLoop;
- ctrlstm2:
- if (m_invert) {
- parseError(fL1S("Unexpected NOT operator in front of %1().").arg(m_tmp));
+ if (!(m_blockstack.top().nest & NestLoop)) {
+ parseError(fL1S("Unexpected %1().").arg(m_tmp));
bogusTest(tokPtr);
return;
}
- if (!(m_blockstack.top().nest & nest)) {
- parseError(fL1S("Unexpected %1().").arg(m_tmp));
+ ctrlstm2:
+ if (m_invert) {
+ parseError(fL1S("Unexpected NOT operator in front of %1().").arg(m_tmp));
bogusTest(tokPtr);
return;
}
diff --git a/qmake/main.cpp b/qmake/main.cpp
index 7ea076be17..55f915b52f 100644
--- a/qmake/main.cpp
+++ b/qmake/main.cpp
@@ -109,6 +109,11 @@ int runQMake(int argc, char **argv)
if(!tmp_dir.isEmpty() && QFile::exists(tmp_dir))
dir = tmp_dir;
}
+#ifdef Q_OS_MAC
+ if (fi.fileName().endsWith(QStringLiteral(".pbxproj"))
+ && dir.endsWith(QStringLiteral(".xcodeproj")))
+ dir += QStringLiteral("/..");
+#endif
if(!dir.isNull() && dir != ".")
Option::output_dir = dir;
if(QDir::isRelativePath(Option::output_dir))
diff --git a/qmake/option.cpp b/qmake/option.cpp
index fdf11d9266..983d3490d8 100644
--- a/qmake/option.cpp
+++ b/qmake/option.cpp
@@ -57,7 +57,6 @@ ProFileCache *Option::proFileCache;
QMakeParser *Option::parser;
//convenience
-const char *Option::application_argv0 = 0;
QString Option::prf_ext;
QString Option::prl_ext;
QString Option::libtool_ext;
@@ -318,13 +317,11 @@ Option::parseCommandLine(QStringList &args, QMakeCmdLineParserState &state)
int
Option::init(int argc, char **argv)
{
- Option::application_argv0 = 0;
Option::prf_ext = ".prf";
Option::pro_ext = ".pro";
Option::field_sep = ' ';
if(argc && argv) {
- Option::application_argv0 = argv[0];
QString argv0 = argv[0];
if(Option::qmake_mode == Option::QMAKE_GENERATE_NOTHING)
Option::qmake_mode = default_mode(argv0);
diff --git a/qmake/option.h b/qmake/option.h
index 541757b264..6225f6b4d2 100644
--- a/qmake/option.h
+++ b/qmake/option.h
@@ -109,7 +109,6 @@ struct Option
static QString pro_ext;
static QString res_ext;
static char field_sep;
- static const char *application_argv0;
enum CmdLineFlags {
QMAKE_CMDLINE_SUCCESS = 0x00,
diff --git a/qmake/qmake.pri b/qmake/qmake.pri
index aff0a9efda..66f7964c5f 100644
--- a/qmake/qmake.pri
+++ b/qmake/qmake.pri
@@ -131,7 +131,6 @@ bootstrap { #Qt code
unix {
SOURCES += qfilesystemengine_unix.cpp qfilesystemiterator_unix.cpp qfsfileengine_unix.cpp
mac {
- SOURCES += qfilesystemengine_mac.cpp
SOURCES += qcore_mac.cpp qsettings_mac.cpp qlocale_mac.mm
LIBS += -framework ApplicationServices
} else {
diff --git a/src/3rdparty/angle/.gitignore b/src/3rdparty/angle/.gitignore
index cfa07de1ee..c53d356b04 100644
--- a/src/3rdparty/angle/.gitignore
+++ b/src/3rdparty/angle/.gitignore
@@ -19,17 +19,24 @@ DEPS
codereview.settings
# Generated by flex/bison
-src/compiler/preprocessor/new/Tokenizer.cpp
-src/compiler/preprocessor/new/ExpressionParser.cpp
+src/compiler/preprocessor/Tokenizer.cpp
+src/compiler/preprocessor/ExpressionParser.cpp
src/compiler/glslang_lex.cpp
src/compiler/glslang_tab.cpp
src/compiler/glslang_tab.h
# Generated by FXC
-src/libGLESv2/shaders/standardvs.h
-src/libGLESv2/shaders/flipyvs.h
-src/libGLESv2/shaders/luminanceps.h
-src/libGLESv2/shaders/componentmaskps.h
-src/libGLESv2/shaders/passthroughps.h
+src/libGLESv2/renderer/shaders/compiled/standardvs.h
+src/libGLESv2/renderer/shaders/compiled/flipyvs.h
+src/libGLESv2/renderer/shaders/compiled/luminanceps.h
+src/libGLESv2/renderer/shaders/compiled/componentmaskps.h
+src/libGLESv2/renderer/shaders/compiled/passthroughps.h
+src/libGLESv2/renderer/shaders/compiled/PassthroughRGBA11ps.h
+src/libGLESv2/renderer/shaders/compiled/PassthroughRGB11ps.h
+src/libGLESv2/renderer/shaders/compiled/PassthroughLumAlpha11ps.h
+src/libGLESv2/renderer/shaders/compiled/PassthroughLum11ps.h
+src/libGLESv2/renderer/shaders/compiled/Passthrough11vs.h
+src/libGLESv2/renderer/shaders/compiled/Clear11ps.h
+src/libGLESv2/renderer/shaders/compiled/Clear11vs.h
diff --git a/src/3rdparty/angle/include/GLES2/gl2ext.h b/src/3rdparty/angle/include/GLES2/gl2ext.h
index e297fbfe87..bad50f9ccb 100644
--- a/src/3rdparty/angle/include/GLES2/gl2ext.h
+++ b/src/3rdparty/angle/include/GLES2/gl2ext.h
@@ -556,6 +556,44 @@ typedef void* GLeglImageOES;
#define GL_COLOR_ATTACHMENT15_NV 0x8CEF
#endif
+/* GL_EXT_draw_buffers */
+#ifndef GL_EXT_draw_buffers
+#define GL_MAX_DRAW_BUFFERS_EXT 0x8824
+#define GL_DRAW_BUFFER0_EXT 0x8825
+#define GL_DRAW_BUFFER1_EXT 0x8826
+#define GL_DRAW_BUFFER2_EXT 0x8827
+#define GL_DRAW_BUFFER3_EXT 0x8828
+#define GL_DRAW_BUFFER4_EXT 0x8829
+#define GL_DRAW_BUFFER5_EXT 0x882A
+#define GL_DRAW_BUFFER6_EXT 0x882B
+#define GL_DRAW_BUFFER7_EXT 0x882C
+#define GL_DRAW_BUFFER8_EXT 0x882D
+#define GL_DRAW_BUFFER9_EXT 0x882E
+#define GL_DRAW_BUFFER10_EXT 0x882F
+#define GL_DRAW_BUFFER11_EXT 0x8830
+#define GL_DRAW_BUFFER12_EXT 0x8831
+#define GL_DRAW_BUFFER13_EXT 0x8832
+#define GL_DRAW_BUFFER14_EXT 0x8833
+#define GL_DRAW_BUFFER15_EXT 0x8834
+#define GL_COLOR_ATTACHMENT0_EXT 0x8CE0
+#define GL_COLOR_ATTACHMENT1_EXT 0x8CE1
+#define GL_COLOR_ATTACHMENT2_EXT 0x8CE2
+#define GL_COLOR_ATTACHMENT3_EXT 0x8CE3
+#define GL_COLOR_ATTACHMENT4_EXT 0x8CE4
+#define GL_COLOR_ATTACHMENT5_EXT 0x8CE5
+#define GL_COLOR_ATTACHMENT6_EXT 0x8CE6
+#define GL_COLOR_ATTACHMENT7_EXT 0x8CE7
+#define GL_COLOR_ATTACHMENT8_EXT 0x8CE8
+#define GL_COLOR_ATTACHMENT9_EXT 0x8CE9
+#define GL_COLOR_ATTACHMENT10_EXT 0x8CEA
+#define GL_COLOR_ATTACHMENT11_EXT 0x8CEB
+#define GL_COLOR_ATTACHMENT12_EXT 0x8CEC
+#define GL_COLOR_ATTACHMENT13_EXT 0x8CED
+#define GL_COLOR_ATTACHMENT14_EXT 0x8CEE
+#define GL_COLOR_ATTACHMENT15_EXT 0x8CEF
+#define GL_MAX_COLOR_ATTACHMENTS_EXT 0x8CDF
+#endif
+
/* GL_NV_fbo_color_attachments */
#ifndef GL_NV_fbo_color_attachments
#define GL_MAX_COLOR_ATTACHMENTS_NV 0x8CDF
@@ -1331,6 +1369,14 @@ GL_APICALL void GL_APIENTRY glDrawBuffersNV (GLsizei n, const GLenum *bufs);
typedef void (GL_APIENTRYP PFNGLDRAWBUFFERSNVPROC) (GLsizei n, const GLenum *bufs);
#endif
+#ifndef GL_EXT_draw_buffers
+#define GL_EXT_draw_buffers 1
+#ifdef GL_GLEXT_PROTOTYPES
+GL_APICALL void GL_APIENTRY glDrawBuffersEXT (GLsizei n, const GLenum *bufs);
+#endif
+typedef void (GL_APIENTRYP PFNGLDRAWBUFFERSEXTPROC) (GLsizei n, const GLenum *bufs);
+#endif
+
/* GL_NV_fbo_color_attachments */
#ifndef GL_NV_fbo_color_attachments
#define GL_NV_fbo_color_attachments 1
diff --git a/src/3rdparty/angle/include/GLSLANG/ShaderLang.h b/src/3rdparty/angle/include/GLSLANG/ShaderLang.h
index d925029a2c..da0f87aed9 100644
--- a/src/3rdparty/angle/include/GLSLANG/ShaderLang.h
+++ b/src/3rdparty/angle/include/GLSLANG/ShaderLang.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -23,6 +23,9 @@
#define COMPILER_EXPORT
#endif
+#include "KHR/khrplatform.h"
+#include <stddef.h>
+
//
// This is the platform independent interface between an OGL driver
// and the shading language compiler.
@@ -34,7 +37,7 @@ extern "C" {
// Version number for shader translation API.
// It is incremented everytime the API changes.
-#define SH_VERSION 107
+#define ANGLE_SH_VERSION 110
//
// The names of the following enums have been derived by replacing GL prefix
@@ -75,9 +78,11 @@ typedef enum {
} ShShaderSpec;
typedef enum {
- SH_ESSL_OUTPUT = 0x8B45,
- SH_GLSL_OUTPUT = 0x8B46,
- SH_HLSL_OUTPUT = 0x8B47
+ SH_ESSL_OUTPUT = 0x8B45,
+ SH_GLSL_OUTPUT = 0x8B46,
+ SH_HLSL_OUTPUT = 0x8B47,
+ SH_HLSL9_OUTPUT = 0x8B47,
+ SH_HLSL11_OUTPUT = 0x8B48
} ShShaderOutput;
typedef enum {
@@ -110,7 +115,11 @@ typedef enum {
SH_ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87,
SH_ACTIVE_ATTRIBUTES = 0x8B89,
SH_ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A,
- SH_MAPPED_NAME_MAX_LENGTH = 0x8B8B
+ SH_MAPPED_NAME_MAX_LENGTH = 0x6000,
+ SH_NAME_MAX_LENGTH = 0x6001,
+ SH_HASHED_NAME_MAX_LENGTH = 0x6002,
+ SH_HASHED_NAMES_COUNT = 0x6003,
+ SH_ACTIVE_UNIFORMS_ARRAY = 0x6004
} ShShaderInfo;
// Compile options.
@@ -146,8 +155,25 @@ typedef enum {
// Enforce the GLSL 1.017 Appendix A section 7 packing restrictions.
SH_ENFORCE_PACKING_RESTRICTIONS = 0x0800,
+
+ // This flag ensures all indirect (expression-based) array indexing
+ // is clamped to the bounds of the array. This ensures, for example,
+ // that you cannot read off the end of a uniform, whether an array
+ // vec234, or mat234 type. The ShArrayIndexClampingStrategy enum,
+ // specified in the ShBuiltInResources when constructing the
+ // compiler, selects the strategy for the clamping implementation.
+ SH_CLAMP_INDIRECT_ARRAY_BOUNDS = 0x1000
} ShCompileOptions;
+// Defines alternate strategies for implementing array index clamping.
+typedef enum {
+ // Use the clamp intrinsic for array index clamping.
+ SH_CLAMP_WITH_CLAMP_INTRINSIC = 1,
+
+ // Use a user-defined function for array index clamping.
+ SH_CLAMP_WITH_USER_DEFINED_INT_CLAMP_FUNCTION
+} ShArrayIndexClampingStrategy;
+
//
// Driver must call this first, once, before doing any other
// compiler operations.
@@ -160,6 +186,10 @@ COMPILER_EXPORT int ShInitialize();
//
COMPILER_EXPORT int ShFinalize();
+// The 64 bits hash function. The first parameter is the input string; the
+// second parameter is the string length.
+typedef khronos_uint64_t (*ShHashFunction64)(const char*, size_t);
+
//
// Implementation dependent built-in resources (constants and extensions).
// The names for these resources has been obtained by stripping gl_/GL_.
@@ -181,6 +211,20 @@ typedef struct
int OES_standard_derivatives;
int OES_EGL_image_external;
int ARB_texture_rectangle;
+ int EXT_draw_buffers;
+
+ // Set to 1 if highp precision is supported in the fragment language.
+ // Default is 0.
+ int FragmentPrecisionHigh;
+
+ // Name Hashing.
+ // Set a 64 bit hash function to enable user-defined name hashing.
+ // Default is NULL.
+ ShHashFunction64 HashFunction;
+
+ // Selects a strategy to use when implementing array index clamping.
+ // Default is SH_CLAMP_WITH_CLAMP_INTRINSIC.
+ ShArrayIndexClampingStrategy ArrayIndexClampingStrategy;
} ShBuiltInResources;
//
@@ -207,7 +251,7 @@ typedef void* ShHandle;
// spec: Specifies the language spec the compiler must conform to -
// SH_GLES2_SPEC or SH_WEBGL_SPEC.
// output: Specifies the output code type - SH_ESSL_OUTPUT, SH_GLSL_OUTPUT,
-// or SH_HLSL_OUTPUT.
+// SH_HLSL9_OUTPUT or SH_HLSL11_OUTPUT.
// resources: Specifies the built-in resources.
COMPILER_EXPORT ShHandle ShConstructCompiler(
ShShaderType type,
@@ -244,7 +288,7 @@ COMPILER_EXPORT void ShDestruct(ShHandle handle);
COMPILER_EXPORT int ShCompile(
const ShHandle handle,
const char* const shaderStrings[],
- const int numStrings,
+ size_t numStrings,
int compileOptions
);
@@ -267,11 +311,16 @@ COMPILER_EXPORT int ShCompile(
// termination character.
// SH_MAPPED_NAME_MAX_LENGTH: the length of the mapped variable name including
// the null termination character.
-//
+// SH_NAME_MAX_LENGTH: the max length of a user-defined name including the
+// null termination character.
+// SH_HASHED_NAME_MAX_LENGTH: the max length of a hashed name including the
+// null termination character.
+// SH_HASHED_NAMES_COUNT: the number of hashed names from the latest compile.
+//
// params: Requested parameter
COMPILER_EXPORT void ShGetInfo(const ShHandle handle,
ShShaderInfo pname,
- int* params);
+ size_t* params);
// Returns nul-terminated information log for a compiled shader.
// Parameters:
@@ -314,7 +363,7 @@ COMPILER_EXPORT void ShGetObjectCode(const ShHandle handle, char* objCode);
// mappedName are the same.
COMPILER_EXPORT void ShGetActiveAttrib(const ShHandle handle,
int index,
- int* length,
+ size_t* length,
int* size,
ShDataType* type,
char* name,
@@ -341,12 +390,42 @@ COMPILER_EXPORT void ShGetActiveAttrib(const ShHandle handle,
// mappedName are the same.
COMPILER_EXPORT void ShGetActiveUniform(const ShHandle handle,
int index,
- int* length,
+ size_t* length,
int* size,
ShDataType* type,
char* name,
char* mappedName);
+// Returns information about a name hashing entry from the latest compile.
+// Parameters:
+// handle: Specifies the compiler
+// index: Specifies the index of the name hashing entry to be queried.
+// name: Returns a null terminated string containing the user defined name.
+// It is assumed that name has enough memory to accomodate the name.
+// The size of the buffer required to store the user defined name can
+// be obtained by calling ShGetInfo with SH_NAME_MAX_LENGTH.
+// hashedName: Returns a null terminated string containing the hashed name of
+// the uniform variable, It is assumed that hashedName has enough
+// memory to accomodate the name. The size of the buffer required
+// to store the name can be obtained by calling ShGetInfo with
+// SH_HASHED_NAME_MAX_LENGTH.
+COMPILER_EXPORT void ShGetNameHashingEntry(const ShHandle handle,
+ int index,
+ char* name,
+ char* hashedName);
+
+// Returns a parameter from a compiled shader.
+// Parameters:
+// handle: Specifies the compiler
+// pname: Specifies the parameter to query.
+// The following parameters are defined:
+// SH_ACTIVE_UNIFORMS_ARRAY: an STL vector of active uniforms. Valid only for
+// HLSL output.
+// params: Requested parameter
+COMPILER_EXPORT void ShGetInfoPointer(const ShHandle handle,
+ ShShaderInfo pname,
+ void** params);
+
#ifdef __cplusplus
}
#endif
diff --git a/src/3rdparty/angle/include/KHR/khrplatform.h b/src/3rdparty/angle/include/KHR/khrplatform.h
index 56c676c77b..18a104ea1f 100644
--- a/src/3rdparty/angle/include/KHR/khrplatform.h
+++ b/src/3rdparty/angle/include/KHR/khrplatform.h
@@ -97,7 +97,8 @@
*-------------------------------------------------------------------------
* This precedes the return type of the function in the function prototype.
*/
-#if defined(_WIN32) && !defined(__SCITECH_SNAP__)
+
+#if defined(_WIN32) && !defined(__SCITECH_SNAP__) && !defined(QT_OPENGL_ES_2_ANGLE_STATIC)
# define KHRONOS_APICALL __declspec(dllimport)
#elif defined (__SYMBIAN32__)
# define KHRONOS_APICALL IMPORT_C
diff --git a/src/3rdparty/angle/src/common/angleutils.h b/src/3rdparty/angle/src/common/angleutils.h
index ff9730c4da..31ac559279 100644
--- a/src/3rdparty/angle/src/common/angleutils.h
+++ b/src/3rdparty/angle/src/common/angleutils.h
@@ -15,6 +15,31 @@
TypeName(const TypeName&); \
void operator=(const TypeName&)
+template <typename T, unsigned int N>
+inline unsigned int ArraySize(T(&)[N])
+{
+ return N;
+}
+
+template <typename T, unsigned int N>
+void SafeRelease(T (&resourceBlock)[N])
+{
+ for (unsigned int i = 0; i < N; i++)
+ {
+ SafeRelease(resourceBlock[i]);
+ }
+}
+
+template <typename T>
+void SafeRelease(T& resource)
+{
+ if (resource)
+ {
+ resource->Release();
+ resource = NULL;
+ }
+}
+
#if defined(_MSC_VER)
#define snprintf _snprintf
#endif
@@ -23,4 +48,7 @@
#define VENDOR_ID_INTEL 0x8086
#define VENDOR_ID_NVIDIA 0x10DE
+#define GL_BGRA4_ANGLEX 0x6ABC
+#define GL_BGR5_A1_ANGLEX 0x6ABD
+
#endif // COMMON_ANGLEUTILS_H_
diff --git a/src/3rdparty/angle/src/common/debug.cpp b/src/3rdparty/angle/src/common/debug.cpp
index b2238f9708..438d3975e8 100644
--- a/src/3rdparty/angle/src/common/debug.cpp
+++ b/src/3rdparty/angle/src/common/debug.cpp
@@ -7,11 +7,12 @@
// debug.cpp: Debugging utilities.
#include "common/debug.h"
-
-#include <stdio.h>
-#include <stdarg.h>
+#include "common/system.h"
+#ifdef ANGLE_ENABLE_D3D11
+typedef DWORD D3DCOLOR;
+#else
#include <d3d9.h>
-#include <windows.h>
+#endif
namespace gl
{
@@ -84,6 +85,12 @@ bool perfActive()
ScopedPerfEventHelper::ScopedPerfEventHelper(const char* format, ...)
{
#if !defined(ANGLE_DISABLE_PERF)
+#if defined(ANGLE_DISABLE_TRACE)
+ if (!perfActive())
+ {
+ return;
+ }
+#endif
va_list vararg;
va_start(vararg, format);
output(true, reinterpret_cast<PerfOutputFunction>(D3DPERF_BeginEvent), format, vararg);
diff --git a/src/3rdparty/angle/src/common/debug.h b/src/3rdparty/angle/src/common/debug.h
index 5f8f60fe61..23ee26d23b 100644
--- a/src/3rdparty/angle/src/common/debug.h
+++ b/src/3rdparty/angle/src/common/debug.h
@@ -99,6 +99,13 @@ namespace gl
#define UNREACHABLE() ERR("\t! Unreachable reached: %s(%d)\n", __FUNCTION__, __LINE__)
#endif
+// A macro that determines whether an object has a given runtime type.
+#if !defined(NDEBUG) && (!defined(_MSC_VER) || defined(_CPPRTTI))
+#define HAS_DYNAMIC_TYPE(type, obj) (dynamic_cast<type >(obj) != NULL)
+#else
+#define HAS_DYNAMIC_TYPE(type, obj) true
+#endif
+
// A macro functioning as a compile-time assert to validate constant conditions
#define META_ASSERT(condition) typedef int COMPILE_TIME_ASSERT_##__LINE__[static_cast<bool>(condition)?1:-1]
diff --git a/src/3rdparty/angle/src/common/system.h b/src/3rdparty/angle/src/common/system.h
new file mode 100644
index 0000000000..5eb140bccd
--- /dev/null
+++ b/src/3rdparty/angle/src/common/system.h
@@ -0,0 +1,26 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// system.h: Includes Windows system headers and undefines macros that conflict.
+
+#ifndef COMMON_SYSTEM_H
+#define COMMON_SYSTEM_H
+
+#if !defined(WIN32_LEAN_AND_MEAN)
+#define WIN32_LEAN_AND_MEAN
+#endif
+
+#include <windows.h>
+
+#if defined(min)
+#undef min
+#endif
+
+#if defined(max)
+#undef max
+#endif
+
+#endif // COMMON_SYSTEM_H
diff --git a/src/3rdparty/angle/src/common/version.h b/src/3rdparty/angle/src/common/version.h
index fec98a15c9..7913851e6a 100644
--- a/src/3rdparty/angle/src/common/version.h
+++ b/src/3rdparty/angle/src/common/version.h
@@ -1,10 +1,12 @@
#define MAJOR_VERSION 1
-#define MINOR_VERSION 0
+#define MINOR_VERSION 1
#define BUILD_VERSION 0
-#define BUILD_REVISION 1318
+#define BUILD_REVISION 2037
#define STRINGIFY(x) #x
#define MACRO_STRINGIFY(x) STRINGIFY(x)
#define REVISION_STRING MACRO_STRINGIFY(BUILD_REVISION)
#define VERSION_STRING MACRO_STRINGIFY(MAJOR_VERSION) "." MACRO_STRINGIFY(MINOR_VERSION) "." MACRO_STRINGIFY(BUILD_VERSION) "." MACRO_STRINGIFY(BUILD_REVISION)
+
+#define VERSION_DWORD ((MAJOR_VERSION << 24) | (MINOR_VERSION << 16) | BUILD_REVISION)
diff --git a/src/3rdparty/angle/src/compiler/BaseTypes.h b/src/3rdparty/angle/src/compiler/BaseTypes.h
index 5f83185304..af4c7e3ed9 100644
--- a/src/3rdparty/angle/src/compiler/BaseTypes.h
+++ b/src/3rdparty/angle/src/compiler/BaseTypes.h
@@ -16,7 +16,7 @@ enum TPrecision
EbpUndefined,
EbpLow,
EbpMedium,
- EbpHigh,
+ EbpHigh
};
inline const char* getPrecisionString(TPrecision p)
@@ -47,7 +47,7 @@ enum TBasicType
EbtGuardSamplerEnd, // non type: see implementation of IsSampler()
EbtStruct,
EbtAddress, // should be deprecated??
- EbtInvariant, // used as a type when qualifying a previously declared variable as being invariant
+ EbtInvariant // used as a type when qualifying a previously declared variable as being invariant
};
inline const char* getBasicString(TBasicType t)
@@ -114,7 +114,7 @@ enum TQualifier
EvqFragData,
// end of list
- EvqLast,
+ EvqLast
};
//
diff --git a/src/3rdparty/angle/src/compiler/CodeGenHLSL.cpp b/src/3rdparty/angle/src/compiler/CodeGenHLSL.cpp
index f46ff66d40..637ccc5e37 100644
--- a/src/3rdparty/angle/src/compiler/CodeGenHLSL.cpp
+++ b/src/3rdparty/angle/src/compiler/CodeGenHLSL.cpp
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -14,9 +14,11 @@
TCompiler* ConstructCompiler(
ShShaderType type, ShShaderSpec spec, ShShaderOutput output)
{
- switch (output) {
- case SH_HLSL_OUTPUT:
- return new TranslatorHLSL(type, spec);
+ switch (output)
+ {
+ case SH_HLSL9_OUTPUT:
+ case SH_HLSL11_OUTPUT:
+ return new TranslatorHLSL(type, spec, output);
default:
return NULL;
}
diff --git a/src/3rdparty/angle/src/compiler/Compiler.cpp b/src/3rdparty/angle/src/compiler/Compiler.cpp
index 9e7f75c33a..c8c79e7147 100644
--- a/src/3rdparty/angle/src/compiler/Compiler.cpp
+++ b/src/3rdparty/angle/src/compiler/Compiler.cpp
@@ -19,6 +19,7 @@
#include "compiler/depgraph/DependencyGraphOutput.h"
#include "compiler/timing/RestrictFragmentShaderTiming.h"
#include "compiler/timing/RestrictVertexShaderTiming.h"
+#include "third_party/compiler/ArrayBoundsClamper.h"
bool isWebGLBasedSpec(ShShaderSpec spec)
{
@@ -37,6 +38,7 @@ bool InitializeSymbolTable(
// The builtins deliberately don't specify precisions for the function
// arguments and return types. For that reason we don't try to check them.
TParseContext parseContext(symbolTable, extBehavior, intermediate, type, spec, 0, false, NULL, infoSink);
+ parseContext.fragmentPrecisionHigh = resources.FragmentPrecisionHigh == 1;
GlobalParseContext = &parseContext;
@@ -101,6 +103,8 @@ TShHandleBase::~TShHandleBase() {
TCompiler::TCompiler(ShShaderType type, ShShaderSpec spec)
: shaderType(type),
shaderSpec(spec),
+ fragmentPrecisionHigh(false),
+ clampingStrategy(SH_CLAMP_WITH_CLAMP_INTRINSIC),
builtInFunctionEmulator(type)
{
longNameMap = LongNameMap::GetInstance();
@@ -123,12 +127,18 @@ bool TCompiler::Init(const ShBuiltInResources& resources)
if (!InitBuiltInSymbolTable(resources))
return false;
InitExtensionBehavior(resources, extensionBehavior);
+ fragmentPrecisionHigh = resources.FragmentPrecisionHigh == 1;
+
+ arrayBoundsClamper.SetClampingStrategy(resources.ArrayIndexClampingStrategy);
+ clampingStrategy = resources.ArrayIndexClampingStrategy;
+
+ hashFunction = resources.HashFunction;
return true;
}
bool TCompiler::compile(const char* const shaderStrings[],
- const int numStrings,
+ size_t numStrings,
int compileOptions)
{
TScopedPoolAllocator scopedAlloc(&allocator, true);
@@ -143,7 +153,7 @@ bool TCompiler::compile(const char* const shaderStrings[],
// First string is path of source file if flag is set. The actual source follows.
const char* sourcePath = NULL;
- int firstSource = 0;
+ size_t firstSource = 0;
if (compileOptions & SH_SOURCE_PATH)
{
sourcePath = shaderStrings[0];
@@ -154,6 +164,7 @@ bool TCompiler::compile(const char* const shaderStrings[],
TParseContext parseContext(symbolTable, extensionBehavior, intermediate,
shaderType, shaderSpec, compileOptions, true,
sourcePath, infoSink);
+ parseContext.fragmentPrecisionHigh = fragmentPrecisionHigh;
GlobalParseContext = &parseContext;
// We preserve symbols at the built-in level from compile-to-compile.
@@ -190,10 +201,15 @@ bool TCompiler::compile(const char* const shaderStrings[],
if (success && (compileOptions & SH_EMULATE_BUILT_IN_FUNCTIONS))
builtInFunctionEmulator.MarkBuiltInFunctionsForEmulation(root);
+ // Clamping uniform array bounds needs to happen after validateLimitations pass.
+ if (success && (compileOptions & SH_CLAMP_INDIRECT_ARRAY_BOUNDS))
+ arrayBoundsClamper.MarkIndirectArrayBoundsForClamping(root);
+
// Call mapLongVariableNames() before collectAttribsUniforms() so in
// collectAttribsUniforms() we already have the mapped symbol names and
// we could composite mapped and original variable names.
- if (success && (compileOptions & SH_MAP_LONG_VARIABLE_NAMES))
+ // Also, if we hash all the names, then no need to do this for long names.
+ if (success && (compileOptions & SH_MAP_LONG_VARIABLE_NAMES) && hashFunction == NULL)
mapLongVariableNames(root);
if (success && (compileOptions & SH_ATTRIBUTES_UNIFORMS)) {
@@ -227,6 +243,7 @@ bool TCompiler::InitBuiltInSymbolTable(const ShBuiltInResources& resources)
{
TBuiltIns builtIns;
+ compileResources = resources;
builtIns.initialize(shaderType, shaderSpec, resources);
return InitializeSymbolTable(builtIns.getBuiltInStrings(),
shaderType, shaderSpec, resources, infoSink, symbolTable);
@@ -234,6 +251,7 @@ bool TCompiler::InitBuiltInSymbolTable(const ShBuiltInResources& resources)
void TCompiler::clearResults()
{
+ arrayBoundsClamper.Cleanup();
infoSink.info.erase();
infoSink.obj.erase();
infoSink.debug.erase();
@@ -242,6 +260,8 @@ void TCompiler::clearResults()
uniforms.clear();
builtInFunctionEmulator.Cleanup();
+
+ nameMap.clear();
}
bool TCompiler::detectRecursion(TIntermNode* root)
@@ -317,7 +337,7 @@ bool TCompiler::enforceVertexShaderTimingRestrictions(TIntermNode* root)
void TCompiler::collectAttribsUniforms(TIntermNode* root)
{
- CollectAttribsUniforms collect(attribs, uniforms);
+ CollectAttribsUniforms collect(attribs, uniforms, hashFunction);
root->traverse(&collect);
}
@@ -344,6 +364,21 @@ const TExtensionBehavior& TCompiler::getExtensionBehavior() const
return extensionBehavior;
}
+const ShBuiltInResources& TCompiler::getResources() const
+{
+ return compileResources;
+}
+
+const ArrayBoundsClamper& TCompiler::getArrayBoundsClamper() const
+{
+ return arrayBoundsClamper;
+}
+
+ShArrayIndexClampingStrategy TCompiler::getArrayIndexClampingStrategy() const
+{
+ return clampingStrategy;
+}
+
const BuiltInFunctionEmulator& TCompiler::getBuiltInFunctionEmulator() const
{
return builtInFunctionEmulator;
diff --git a/src/3rdparty/angle/src/compiler/ConstantUnion.h b/src/3rdparty/angle/src/compiler/ConstantUnion.h
index fd9d94dc5a..32af4d38b0 100644
--- a/src/3rdparty/angle/src/compiler/ConstantUnion.h
+++ b/src/3rdparty/angle/src/compiler/ConstantUnion.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -14,6 +14,7 @@ public:
ConstantUnion()
{
iConst = 0;
+ type = EbtVoid;
}
POOL_ALLOCATOR_NEW_DELETE(GlobalPoolAllocator)
diff --git a/src/3rdparty/angle/src/compiler/DetectDiscontinuity.cpp b/src/3rdparty/angle/src/compiler/DetectDiscontinuity.cpp
index 472232a75d..7c3b68a0b3 100644
--- a/src/3rdparty/angle/src/compiler/DetectDiscontinuity.cpp
+++ b/src/3rdparty/angle/src/compiler/DetectDiscontinuity.cpp
@@ -16,11 +16,26 @@ namespace sh
{
bool DetectLoopDiscontinuity::traverse(TIntermNode *node)
{
+ mLoopDepth = 0;
mLoopDiscontinuity = false;
node->traverse(this);
return mLoopDiscontinuity;
}
+bool DetectLoopDiscontinuity::visitLoop(Visit visit, TIntermLoop *loop)
+{
+ if (visit == PreVisit)
+ {
+ ++mLoopDepth;
+ }
+ else if (visit == PostVisit)
+ {
+ --mLoopDepth;
+ }
+
+ return true;
+}
+
bool DetectLoopDiscontinuity::visitBranch(Visit visit, TIntermBranch *node)
{
if (mLoopDiscontinuity)
@@ -28,14 +43,19 @@ bool DetectLoopDiscontinuity::visitBranch(Visit visit, TIntermBranch *node)
return false;
}
+ if (!mLoopDepth)
+ {
+ return true;
+ }
+
switch (node->getFlowOp())
{
case EOpKill:
break;
case EOpBreak:
case EOpContinue:
- mLoopDiscontinuity = true;
case EOpReturn:
+ mLoopDiscontinuity = true;
break;
default: UNREACHABLE();
}
diff --git a/src/3rdparty/angle/src/compiler/DetectDiscontinuity.h b/src/3rdparty/angle/src/compiler/DetectDiscontinuity.h
index 8bda4c3dea..e5520bd5b0 100644
--- a/src/3rdparty/angle/src/compiler/DetectDiscontinuity.h
+++ b/src/3rdparty/angle/src/compiler/DetectDiscontinuity.h
@@ -23,8 +23,10 @@ class DetectLoopDiscontinuity : public TIntermTraverser
protected:
bool visitBranch(Visit visit, TIntermBranch *node);
+ bool visitLoop(Visit visit, TIntermLoop *loop);
bool visitAggregate(Visit visit, TIntermAggregate *node);
+ int mLoopDepth;
bool mLoopDiscontinuity;
};
diff --git a/src/3rdparty/angle/src/compiler/Diagnostics.cpp b/src/3rdparty/angle/src/compiler/Diagnostics.cpp
index 8aa1cb6b24..06f370dbe5 100644
--- a/src/3rdparty/angle/src/compiler/Diagnostics.cpp
+++ b/src/3rdparty/angle/src/compiler/Diagnostics.cpp
@@ -8,7 +8,7 @@
#include "compiler/debug.h"
#include "compiler/InfoSink.h"
-#include "compiler/preprocessor/new/SourceLocation.h"
+#include "compiler/preprocessor/SourceLocation.h"
TDiagnostics::TDiagnostics(TInfoSink& infoSink) :
mInfoSink(infoSink),
diff --git a/src/3rdparty/angle/src/compiler/Diagnostics.h b/src/3rdparty/angle/src/compiler/Diagnostics.h
index 3670414b03..cb71bb1204 100644
--- a/src/3rdparty/angle/src/compiler/Diagnostics.h
+++ b/src/3rdparty/angle/src/compiler/Diagnostics.h
@@ -7,7 +7,7 @@
#ifndef COMPILER_DIAGNOSTICS_H_
#define COMPILER_DIAGNOSTICS_H_
-#include "compiler/preprocessor/new/Diagnostics.h"
+#include "compiler/preprocessor/DiagnosticsBase.h"
class TInfoSink;
diff --git a/src/3rdparty/angle/src/compiler/DirectiveHandler.h b/src/3rdparty/angle/src/compiler/DirectiveHandler.h
index 21d3dfc315..95ca59d6fe 100644
--- a/src/3rdparty/angle/src/compiler/DirectiveHandler.h
+++ b/src/3rdparty/angle/src/compiler/DirectiveHandler.h
@@ -9,7 +9,7 @@
#include "compiler/ExtensionBehavior.h"
#include "compiler/Pragma.h"
-#include "compiler/preprocessor/new/DirectiveHandler.h"
+#include "compiler/preprocessor/DirectiveHandlerBase.h"
class TDiagnostics;
diff --git a/src/3rdparty/angle/src/compiler/ExtensionBehavior.h b/src/3rdparty/angle/src/compiler/ExtensionBehavior.h
index 6040980837..5c1595fb21 100644
--- a/src/3rdparty/angle/src/compiler/ExtensionBehavior.h
+++ b/src/3rdparty/angle/src/compiler/ExtensionBehavior.h
@@ -16,7 +16,7 @@ typedef enum
EBhEnable,
EBhWarn,
EBhDisable,
- EBhUndefined,
+ EBhUndefined
} TBehavior;
inline const char* getBehaviorString(TBehavior b)
diff --git a/src/3rdparty/angle/src/compiler/ForLoopUnroll.cpp b/src/3rdparty/angle/src/compiler/ForLoopUnroll.cpp
index fdc3f44431..27a13eabab 100644
--- a/src/3rdparty/angle/src/compiler/ForLoopUnroll.cpp
+++ b/src/3rdparty/angle/src/compiler/ForLoopUnroll.cpp
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2011 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -210,6 +210,6 @@ int ForLoopUnroll::getLoopIncrement(TIntermLoop* node)
int ForLoopUnroll::evaluateIntConstant(TIntermConstantUnion* node)
{
ASSERT((node != NULL) && (node->getUnionArrayPointer() != NULL));
- return node->getUnionArrayPointer()->getIConst();
+ return node->getIConst(0);
}
diff --git a/src/3rdparty/angle/src/compiler/HashNames.h b/src/3rdparty/angle/src/compiler/HashNames.h
new file mode 100644
index 0000000000..d2141e2d85
--- /dev/null
+++ b/src/3rdparty/angle/src/compiler/HashNames.h
@@ -0,0 +1,19 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+#ifndef COMPILER_HASH_NAMES_H_
+#define COMPILER_HASH_NAMES_H_
+
+#include <map>
+
+#include "compiler/intermediate.h"
+#include "GLSLANG/ShaderLang.h"
+
+#define HASHED_NAME_PREFIX "webgl_"
+
+typedef std::map<TPersistString, TPersistString> NameMap;
+
+#endif // COMPILER_HASH_NAMES_H_
diff --git a/src/3rdparty/angle/src/compiler/Initialize.cpp b/src/3rdparty/angle/src/compiler/Initialize.cpp
index 3e94ce7ba8..97b46f898e 100644
--- a/src/3rdparty/angle/src/compiler/Initialize.cpp
+++ b/src/3rdparty/angle/src/compiler/Initialize.cpp
@@ -654,4 +654,6 @@ void InitExtensionBehavior(const ShBuiltInResources& resources,
extBehavior["GL_OES_EGL_image_external"] = EBhUndefined;
if (resources.ARB_texture_rectangle)
extBehavior["GL_ARB_texture_rectangle"] = EBhUndefined;
+ if (resources.EXT_draw_buffers)
+ extBehavior["GL_EXT_draw_buffers"] = EBhUndefined;
}
diff --git a/src/3rdparty/angle/src/compiler/Intermediate.cpp b/src/3rdparty/angle/src/compiler/Intermediate.cpp
index 92c450530e..edf279ef67 100644
--- a/src/3rdparty/angle/src/compiler/Intermediate.cpp
+++ b/src/3rdparty/angle/src/compiler/Intermediate.cpp
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -12,6 +12,7 @@
#include <limits.h>
#include <algorithm>
+#include "compiler/HashNames.h"
#include "compiler/localintermediate.h"
#include "compiler/QualifierAlive.h"
#include "compiler/RemoveTree.h"
@@ -592,7 +593,7 @@ TIntermNode* TIntermediate::addSelection(TIntermTyped* cond, TIntermNodePair nod
//
if (cond->getAsTyped() && cond->getAsTyped()->getAsConstantUnion()) {
- if (cond->getAsTyped()->getAsConstantUnion()->getUnionArrayPointer()->getBConst() == true)
+ if (cond->getAsConstantUnion()->getBConst(0) == true)
return nodePair.node1 ? setAggregateOperator(nodePair.node1, EOpSequence, nodePair.node1->getLine()) : NULL;
else
return nodePair.node2 ? setAggregateOperator(nodePair.node2, EOpSequence, nodePair.node2->getLine()) : NULL;
@@ -646,7 +647,7 @@ TIntermTyped* TIntermediate::addSelection(TIntermTyped* cond, TIntermTyped* true
//
if (cond->getAsConstantUnion() && trueBlock->getAsConstantUnion() && falseBlock->getAsConstantUnion()) {
- if (cond->getAsConstantUnion()->getUnionArrayPointer()->getBConst())
+ if (cond->getAsConstantUnion()->getBConst(0))
return trueBlock;
else
return falseBlock;
@@ -845,6 +846,7 @@ bool TIntermUnary::promote(TInfoSink&)
}
setType(operand->getType());
+ type.setQualifier(EvqTemporary);
return true;
}
@@ -1161,7 +1163,7 @@ TIntermTyped* TIntermConstantUnion::fold(TOperator op, TIntermTyped* constantNod
case EbtFloat:
if (rightUnionArray[i] == 0.0f) {
infoSink.info.message(EPrefixWarning, "Divide by zero error during constant folding", getLine());
- tempConstArray[i].setFConst(FLT_MAX);
+ tempConstArray[i].setFConst(unionArray[i].getFConst() < 0 ? -FLT_MAX : FLT_MAX);
} else
tempConstArray[i].setFConst(unionArray[i].getFConst() / rightUnionArray[i].getFConst());
break;
@@ -1376,7 +1378,6 @@ TIntermTyped* TIntermConstantUnion::fold(TOperator op, TIntermTyped* constantNod
TIntermTyped* TIntermediate::promoteConstantUnion(TBasicType promoteTo, TIntermConstantUnion* node)
{
- ConstantUnion *rightUnionArray = node->getUnionArrayPointer();
int size = node->getType().getObjectSize();
ConstantUnion *leftUnionArray = new ConstantUnion[size];
@@ -1387,13 +1388,13 @@ TIntermTyped* TIntermediate::promoteConstantUnion(TBasicType promoteTo, TIntermC
case EbtFloat:
switch (node->getType().getBasicType()) {
case EbtInt:
- leftUnionArray[i].setFConst(static_cast<float>(rightUnionArray[i].getIConst()));
+ leftUnionArray[i].setFConst(static_cast<float>(node->getIConst(i)));
break;
case EbtBool:
- leftUnionArray[i].setFConst(static_cast<float>(rightUnionArray[i].getBConst()));
+ leftUnionArray[i].setFConst(static_cast<float>(node->getBConst(i)));
break;
case EbtFloat:
- leftUnionArray[i] = rightUnionArray[i];
+ leftUnionArray[i].setFConst(static_cast<float>(node->getFConst(i)));
break;
default:
infoSink.info.message(EPrefixInternalError, "Cannot promote", node->getLine());
@@ -1403,13 +1404,13 @@ TIntermTyped* TIntermediate::promoteConstantUnion(TBasicType promoteTo, TIntermC
case EbtInt:
switch (node->getType().getBasicType()) {
case EbtInt:
- leftUnionArray[i] = rightUnionArray[i];
+ leftUnionArray[i].setIConst(static_cast<int>(node->getIConst(i)));
break;
case EbtBool:
- leftUnionArray[i].setIConst(static_cast<int>(rightUnionArray[i].getBConst()));
+ leftUnionArray[i].setIConst(static_cast<int>(node->getBConst(i)));
break;
case EbtFloat:
- leftUnionArray[i].setIConst(static_cast<int>(rightUnionArray[i].getFConst()));
+ leftUnionArray[i].setIConst(static_cast<int>(node->getFConst(i)));
break;
default:
infoSink.info.message(EPrefixInternalError, "Cannot promote", node->getLine());
@@ -1419,13 +1420,13 @@ TIntermTyped* TIntermediate::promoteConstantUnion(TBasicType promoteTo, TIntermC
case EbtBool:
switch (node->getType().getBasicType()) {
case EbtInt:
- leftUnionArray[i].setBConst(rightUnionArray[i].getIConst() != 0);
+ leftUnionArray[i].setBConst(node->getIConst(i) != 0);
break;
case EbtBool:
- leftUnionArray[i] = rightUnionArray[i];
+ leftUnionArray[i].setBConst(node->getBConst(i));
break;
case EbtFloat:
- leftUnionArray[i].setBConst(rightUnionArray[i].getFConst() != 0.0f);
+ leftUnionArray[i].setBConst(node->getFConst(i) != 0.0f);
break;
default:
infoSink.info.message(EPrefixInternalError, "Cannot promote", node->getLine());
@@ -1445,3 +1446,14 @@ TIntermTyped* TIntermediate::promoteConstantUnion(TBasicType promoteTo, TIntermC
return addConstantUnion(leftUnionArray, TType(promoteTo, t.getPrecision(), t.getQualifier(), t.getNominalSize(), t.isMatrix(), t.isArray()), node->getLine());
}
+// static
+TString TIntermTraverser::hash(const TString& name, ShHashFunction64 hashFunction)
+{
+ if (hashFunction == NULL || name.empty())
+ return name;
+ khronos_uint64_t number = (*hashFunction)(name.c_str(), name.length());
+ TStringStream stream;
+ stream << HASHED_NAME_PREFIX << std::hex << number;
+ TString hashedName = stream.str();
+ return hashedName;
+}
diff --git a/src/3rdparty/angle/src/compiler/MapLongVariableNames.cpp b/src/3rdparty/angle/src/compiler/MapLongVariableNames.cpp
index a50310154d..a41d20f4e8 100644
--- a/src/3rdparty/angle/src/compiler/MapLongVariableNames.cpp
+++ b/src/3rdparty/angle/src/compiler/MapLongVariableNames.cpp
@@ -8,7 +8,7 @@
namespace {
-TString mapLongName(int id, const TString& name, bool isGlobal)
+TString mapLongName(size_t id, const TString& name, bool isGlobal)
{
ASSERT(name.size() > MAX_SHORTENED_IDENTIFIER_SIZE);
TStringStream stream;
@@ -70,7 +70,7 @@ void LongNameMap::Insert(const char* originalName, const char* mappedName)
originalName, mappedName));
}
-int LongNameMap::Size() const
+size_t LongNameMap::Size() const
{
return mLongNameMap.size();
}
@@ -115,7 +115,7 @@ TString MapLongVariableNames::mapGlobalLongName(const TString& name)
const char* mappedName = mGlobalMap->Find(name.c_str());
if (mappedName != NULL)
return mappedName;
- int id = mGlobalMap->Size();
+ size_t id = mGlobalMap->Size();
TString rt = mapLongName(id, name, true);
mGlobalMap->Insert(name.c_str(), rt.c_str());
return rt;
diff --git a/src/3rdparty/angle/src/compiler/MapLongVariableNames.h b/src/3rdparty/angle/src/compiler/MapLongVariableNames.h
index fb2c7e81cb..d6352acb4b 100644
--- a/src/3rdparty/angle/src/compiler/MapLongVariableNames.h
+++ b/src/3rdparty/angle/src/compiler/MapLongVariableNames.h
@@ -31,7 +31,7 @@ public:
void Insert(const char* originalName, const char* mappedName);
// Return the number of entries in the map.
- int Size() const;
+ size_t Size() const;
private:
LongNameMap();
diff --git a/src/3rdparty/angle/src/compiler/OutputESSL.cpp b/src/3rdparty/angle/src/compiler/OutputESSL.cpp
index 64ee92d44e..c2048f1cec 100644
--- a/src/3rdparty/angle/src/compiler/OutputESSL.cpp
+++ b/src/3rdparty/angle/src/compiler/OutputESSL.cpp
@@ -6,8 +6,12 @@
#include "compiler/OutputESSL.h"
-TOutputESSL::TOutputESSL(TInfoSinkBase& objSink)
- : TOutputGLSLBase(objSink)
+TOutputESSL::TOutputESSL(TInfoSinkBase& objSink,
+ ShArrayIndexClampingStrategy clampingStrategy,
+ ShHashFunction64 hashFunction,
+ NameMap& nameMap,
+ TSymbolTable& symbolTable)
+ : TOutputGLSLBase(objSink, clampingStrategy, hashFunction, nameMap, symbolTable)
{
}
diff --git a/src/3rdparty/angle/src/compiler/OutputESSL.h b/src/3rdparty/angle/src/compiler/OutputESSL.h
index 4fa73c8047..05db96e497 100644
--- a/src/3rdparty/angle/src/compiler/OutputESSL.h
+++ b/src/3rdparty/angle/src/compiler/OutputESSL.h
@@ -12,7 +12,11 @@
class TOutputESSL : public TOutputGLSLBase
{
public:
- TOutputESSL(TInfoSinkBase& objSink);
+ TOutputESSL(TInfoSinkBase& objSink,
+ ShArrayIndexClampingStrategy clampingStrategy,
+ ShHashFunction64 hashFunction,
+ NameMap& nameMap,
+ TSymbolTable& symbolTable);
protected:
virtual bool writeVariablePrecision(TPrecision precision);
diff --git a/src/3rdparty/angle/src/compiler/OutputGLSL.cpp b/src/3rdparty/angle/src/compiler/OutputGLSL.cpp
index dd31b4b58b..206f403408 100644
--- a/src/3rdparty/angle/src/compiler/OutputGLSL.cpp
+++ b/src/3rdparty/angle/src/compiler/OutputGLSL.cpp
@@ -6,8 +6,12 @@
#include "compiler/OutputGLSL.h"
-TOutputGLSL::TOutputGLSL(TInfoSinkBase& objSink)
- : TOutputGLSLBase(objSink)
+TOutputGLSL::TOutputGLSL(TInfoSinkBase& objSink,
+ ShArrayIndexClampingStrategy clampingStrategy,
+ ShHashFunction64 hashFunction,
+ NameMap& nameMap,
+ TSymbolTable& symbolTable)
+ : TOutputGLSLBase(objSink, clampingStrategy, hashFunction, nameMap, symbolTable)
{
}
diff --git a/src/3rdparty/angle/src/compiler/OutputGLSL.h b/src/3rdparty/angle/src/compiler/OutputGLSL.h
index 0fe2356eb7..199b6f3e46 100644
--- a/src/3rdparty/angle/src/compiler/OutputGLSL.h
+++ b/src/3rdparty/angle/src/compiler/OutputGLSL.h
@@ -12,7 +12,11 @@
class TOutputGLSL : public TOutputGLSLBase
{
public:
- TOutputGLSL(TInfoSinkBase& objSink);
+ TOutputGLSL(TInfoSinkBase& objSink,
+ ShArrayIndexClampingStrategy clampingStrategy,
+ ShHashFunction64 hashFunction,
+ NameMap& nameMap,
+ TSymbolTable& symbolTable);
protected:
virtual bool writeVariablePrecision(TPrecision);
diff --git a/src/3rdparty/angle/src/compiler/OutputGLSLBase.cpp b/src/3rdparty/angle/src/compiler/OutputGLSLBase.cpp
index 552fa5066d..1b9a10deaa 100644
--- a/src/3rdparty/angle/src/compiler/OutputGLSLBase.cpp
+++ b/src/3rdparty/angle/src/compiler/OutputGLSLBase.cpp
@@ -7,37 +7,10 @@
#include "compiler/OutputGLSLBase.h"
#include "compiler/debug.h"
+#include <cfloat>
+
namespace
{
-TString getTypeName(const TType& type)
-{
- TInfoSinkBase out;
- if (type.isMatrix())
- {
- out << "mat";
- out << type.getNominalSize();
- }
- else if (type.isVector())
- {
- switch (type.getBasicType())
- {
- case EbtFloat: out << "vec"; break;
- case EbtInt: out << "ivec"; break;
- case EbtBool: out << "bvec"; break;
- default: UNREACHABLE(); break;
- }
- out << type.getNominalSize();
- }
- else
- {
- if (type.getBasicType() == EbtStruct)
- out << type.getTypeName();
- else
- out << type.getBasicString();
- }
- return TString(out.c_str());
-}
-
TString arrayBrackets(const TType& type)
{
ASSERT(type.isArray());
@@ -66,10 +39,18 @@ bool isSingleStatement(TIntermNode* node) {
}
} // namespace
-TOutputGLSLBase::TOutputGLSLBase(TInfoSinkBase& objSink)
+TOutputGLSLBase::TOutputGLSLBase(TInfoSinkBase& objSink,
+ ShArrayIndexClampingStrategy clampingStrategy,
+ ShHashFunction64 hashFunction,
+ NameMap& nameMap,
+ TSymbolTable& symbolTable)
: TIntermTraverser(true, true, true),
mObjSink(objSink),
- mDeclaringVariables(false)
+ mDeclaringVariables(false),
+ mClampingStrategy(clampingStrategy),
+ mHashFunction(hashFunction),
+ mNameMap(nameMap),
+ mSymbolTable(symbolTable)
{
}
@@ -101,7 +82,7 @@ void TOutputGLSLBase::writeVariableType(const TType& type)
if ((type.getBasicType() == EbtStruct) &&
(mDeclaredStructs.find(type.getTypeName()) == mDeclaredStructs.end()))
{
- out << "struct " << type.getTypeName() << "{\n";
+ out << "struct " << hashName(type.getTypeName()) << "{\n";
const TTypeList* structure = type.getStruct();
ASSERT(structure != NULL);
for (size_t i = 0; i < structure->size(); ++i)
@@ -110,7 +91,7 @@ void TOutputGLSLBase::writeVariableType(const TType& type)
ASSERT(fieldType != NULL);
if (writeVariablePrecision(fieldType->getPrecision()))
out << " ";
- out << getTypeName(*fieldType) << " " << fieldType->getFieldName();
+ out << getTypeName(*fieldType) << " " << hashName(fieldType->getFieldName());
if (fieldType->isArray())
out << arrayBrackets(*fieldType);
out << ";\n";
@@ -140,7 +121,7 @@ void TOutputGLSLBase::writeFunctionParameters(const TIntermSequence& args)
const TString& name = arg->getSymbol();
if (!name.empty())
- out << " " << name;
+ out << " " << hashName(name);
if (type.isArray())
out << arrayBrackets(type);
@@ -157,7 +138,7 @@ const ConstantUnion* TOutputGLSLBase::writeConstantUnion(const TType& type,
if (type.getBasicType() == EbtStruct)
{
- out << type.getTypeName() << "(";
+ out << hashName(type.getTypeName()) << "(";
const TTypeList* structure = type.getStruct();
ASSERT(structure != NULL);
for (size_t i = 0; i < structure->size(); ++i)
@@ -178,7 +159,7 @@ const ConstantUnion* TOutputGLSLBase::writeConstantUnion(const TType& type,
{
switch (pConstUnion->getType())
{
- case EbtFloat: out << pConstUnion->getFConst(); break;
+ case EbtFloat: out << std::min(FLT_MAX, std::max(-FLT_MAX, pConstUnion->getFConst())); break;
case EbtInt: out << pConstUnion->getIConst(); break;
case EbtBool: out << pConstUnion->getBConst(); break;
default: UNREACHABLE();
@@ -196,7 +177,7 @@ void TOutputGLSLBase::visitSymbol(TIntermSymbol* node)
if (mLoopUnroll.NeedsToReplaceSymbolWithValue(node))
out << mLoopUnroll.GetLoopIndexValue(node);
else
- out << node->getSymbol();
+ out << hashVariableName(node->getSymbol());
if (mDeclaringVariables && node->getType().isArray())
out << arrayBrackets(node->getType());
@@ -235,15 +216,59 @@ bool TOutputGLSLBase::visitBinary(Visit visit, TIntermBinary* node)
break;
case EOpIndexDirect:
- case EOpIndexIndirect:
writeTriplet(visit, NULL, "[", "]");
break;
+ case EOpIndexIndirect:
+ if (node->getAddIndexClamp())
+ {
+ if (visit == InVisit)
+ {
+ if (mClampingStrategy == SH_CLAMP_WITH_CLAMP_INTRINSIC) {
+ out << "[int(clamp(float(";
+ } else {
+ out << "[webgl_int_clamp(";
+ }
+ }
+ else if (visit == PostVisit)
+ {
+ int maxSize;
+ TIntermTyped *left = node->getLeft();
+ TType leftType = left->getType();
+
+ if (left->isArray())
+ {
+ // The shader will fail validation if the array length is not > 0.
+ maxSize = leftType.getArraySize() - 1;
+ }
+ else
+ {
+ maxSize = leftType.getNominalSize() - 1;
+ }
+
+ if (mClampingStrategy == SH_CLAMP_WITH_CLAMP_INTRINSIC) {
+ out << "), 0.0, float(" << maxSize << ")))]";
+ } else {
+ out << ", 0, " << maxSize << ")]";
+ }
+ }
+ }
+ else
+ {
+ writeTriplet(visit, NULL, "[", "]");
+ }
+ break;
case EOpIndexDirectStruct:
if (visit == InVisit)
{
out << ".";
// TODO(alokp): ASSERT
- out << node->getType().getFieldName();
+ TString fieldName = node->getType().getFieldName();
+
+ const TType& structType = node->getLeft()->getType();
+ if (!mSymbolTable.findBuiltIn(structType.getTypeName()))
+ fieldName = hashName(fieldName);
+
+ out << fieldName;
visitChildren = false;
}
break;
@@ -467,7 +492,7 @@ bool TOutputGLSLBase::visitAggregate(Visit visit, TIntermAggregate* node)
// Function declaration.
ASSERT(visit == PreVisit);
writeVariableType(node->getType());
- out << " " << node->getName();
+ out << " " << hashName(node->getName());
out << "(";
writeFunctionParameters(node->getSequence());
@@ -480,7 +505,7 @@ bool TOutputGLSLBase::visitAggregate(Visit visit, TIntermAggregate* node)
// Function definition.
ASSERT(visit == PreVisit);
writeVariableType(node->getType());
- out << " " << TFunction::unmangleName(node->getName());
+ out << " " << hashFunctionName(node->getName());
incrementDepth();
// Function definition node contains one or two children nodes
@@ -510,8 +535,7 @@ bool TOutputGLSLBase::visitAggregate(Visit visit, TIntermAggregate* node)
// Function call.
if (visit == PreVisit)
{
- TString functionName = TFunction::unmangleName(node->getName());
- out << functionName << "(";
+ out << hashFunctionName(node->getName()) << "(";
}
else if (visit == InVisit)
{
@@ -572,7 +596,7 @@ bool TOutputGLSLBase::visitAggregate(Visit visit, TIntermAggregate* node)
{
const TType& type = node->getType();
ASSERT(type.getBasicType() == EbtStruct);
- out << type.getTypeName() << "(";
+ out << hashName(type.getTypeName()) << "(";
}
else if (visit == InVisit)
{
@@ -718,3 +742,59 @@ void TOutputGLSLBase::visitCodeBlock(TIntermNode* node) {
out << "{\n}\n"; // Empty code block.
}
}
+
+TString TOutputGLSLBase::getTypeName(const TType& type)
+{
+ TInfoSinkBase out;
+ if (type.isMatrix())
+ {
+ out << "mat";
+ out << type.getNominalSize();
+ }
+ else if (type.isVector())
+ {
+ switch (type.getBasicType())
+ {
+ case EbtFloat: out << "vec"; break;
+ case EbtInt: out << "ivec"; break;
+ case EbtBool: out << "bvec"; break;
+ default: UNREACHABLE(); break;
+ }
+ out << type.getNominalSize();
+ }
+ else
+ {
+ if (type.getBasicType() == EbtStruct)
+ out << hashName(type.getTypeName());
+ else
+ out << type.getBasicString();
+ }
+ return TString(out.c_str());
+}
+
+TString TOutputGLSLBase::hashName(const TString& name)
+{
+ if (mHashFunction == NULL || name.empty())
+ return name;
+ NameMap::const_iterator it = mNameMap.find(name.c_str());
+ if (it != mNameMap.end())
+ return it->second.c_str();
+ TString hashedName = TIntermTraverser::hash(name, mHashFunction);
+ mNameMap[name.c_str()] = hashedName.c_str();
+ return hashedName;
+}
+
+TString TOutputGLSLBase::hashVariableName(const TString& name)
+{
+ if (mSymbolTable.findBuiltIn(name) != NULL)
+ return name;
+ return hashName(name);
+}
+
+TString TOutputGLSLBase::hashFunctionName(const TString& mangled_name)
+{
+ TString name = TFunction::unmangleName(mangled_name);
+ if (mSymbolTable.findBuiltIn(mangled_name) != NULL || name == "main")
+ return name;
+ return hashName(name);
+}
diff --git a/src/3rdparty/angle/src/compiler/OutputGLSLBase.h b/src/3rdparty/angle/src/compiler/OutputGLSLBase.h
index efd0b5fc2d..c9f72d5631 100644
--- a/src/3rdparty/angle/src/compiler/OutputGLSLBase.h
+++ b/src/3rdparty/angle/src/compiler/OutputGLSLBase.h
@@ -16,7 +16,11 @@
class TOutputGLSLBase : public TIntermTraverser
{
public:
- TOutputGLSLBase(TInfoSinkBase& objSink);
+ TOutputGLSLBase(TInfoSinkBase& objSink,
+ ShArrayIndexClampingStrategy clampingStrategy,
+ ShHashFunction64 hashFunction,
+ NameMap& nameMap,
+ TSymbolTable& symbolTable);
protected:
TInfoSinkBase& objSink() { return mObjSink; }
@@ -25,6 +29,7 @@ protected:
virtual bool writeVariablePrecision(TPrecision precision) = 0;
void writeFunctionParameters(const TIntermSequence& args);
const ConstantUnion* writeConstantUnion(const TType& type, const ConstantUnion* pConstUnion);
+ TString getTypeName(const TType& type);
virtual void visitSymbol(TIntermSymbol* node);
virtual void visitConstantUnion(TIntermConstantUnion* node);
@@ -37,6 +42,15 @@ protected:
void visitCodeBlock(TIntermNode* node);
+
+ // Return the original name if hash function pointer is NULL;
+ // otherwise return the hashed name.
+ TString hashName(const TString& name);
+ // Same as hashName(), but without hashing built-in variables.
+ TString hashVariableName(const TString& name);
+ // Same as hashName(), but without hashing built-in functions.
+ TString hashFunctionName(const TString& mangled_name);
+
private:
TInfoSinkBase& mObjSink;
bool mDeclaringVariables;
@@ -48,6 +62,15 @@ private:
DeclaredStructs mDeclaredStructs;
ForLoopUnroll mLoopUnroll;
+
+ ShArrayIndexClampingStrategy mClampingStrategy;
+
+ // name hashing.
+ ShHashFunction64 mHashFunction;
+
+ NameMap& mNameMap;
+
+ TSymbolTable& mSymbolTable;
};
#endif // CROSSCOMPILERGLSL_OUTPUTGLSLBASE_H_
diff --git a/src/3rdparty/angle/src/compiler/OutputHLSL.cpp b/src/3rdparty/angle/src/compiler/OutputHLSL.cpp
index a430695744..f6a984148b 100644
--- a/src/3rdparty/angle/src/compiler/OutputHLSL.cpp
+++ b/src/3rdparty/angle/src/compiler/OutputHLSL.cpp
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -8,13 +8,14 @@
#include "common/angleutils.h"
#include "compiler/debug.h"
+#include "compiler/DetectDiscontinuity.h"
#include "compiler/InfoSink.h"
-#include "compiler/UnfoldShortCircuit.h"
#include "compiler/SearchSymbol.h"
-#include "compiler/DetectDiscontinuity.h"
+#include "compiler/UnfoldShortCircuit.h"
-#include <stdio.h>
#include <algorithm>
+#include <cfloat>
+#include <stdio.h>
namespace sh
{
@@ -26,7 +27,8 @@ TString str(int i)
return buffer;
}
-OutputHLSL::OutputHLSL(TParseContext &context) : TIntermTraverser(true, true, true), mContext(context)
+OutputHLSL::OutputHLSL(TParseContext &context, const ShBuiltInResources& resources, ShShaderOutput outputType)
+ : TIntermTraverser(true, true, true), mContext(context), mOutputType(outputType)
{
mUnfoldShortCircuit = new UnfoldShortCircuit(context, this);
mInsideFunction = false;
@@ -46,6 +48,8 @@ OutputHLSL::OutputHLSL(TParseContext &context) : TIntermTraverser(true, true, tr
mUsesTexture2DProjLod0_bias = false;
mUsesTextureCubeLod0 = false;
mUsesTextureCubeLod0_bias = false;
+ mUsesFragColor = false;
+ mUsesFragData = false;
mUsesDepthRange = false;
mUsesFragCoord = false;
mUsesPointCoord = false;
@@ -80,6 +84,8 @@ OutputHLSL::OutputHLSL(TParseContext &context) : TIntermTraverser(true, true, tr
mUsesAtan2_3 = false;
mUsesAtan2_4 = false;
+ mNumRenderTargets = resources.EXT_draw_buffers ? resources.MaxDrawBuffers : 1;
+
mScopeDepth = 0;
mUniqueIndex = 0;
@@ -89,6 +95,24 @@ OutputHLSL::OutputHLSL(TParseContext &context) : TIntermTraverser(true, true, tr
mInsideDiscontinuousLoop = false;
mExcessiveLoopIndex = NULL;
+
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ if (mContext.shaderType == SH_FRAGMENT_SHADER)
+ {
+ mUniformRegister = 3; // Reserve registers for dx_DepthRange, dx_ViewCoords and dx_DepthFront
+ }
+ else
+ {
+ mUniformRegister = 2; // Reserve registers for dx_DepthRange and dx_ViewAdjust
+ }
+ }
+ else
+ {
+ mUniformRegister = 0;
+ }
+
+ mSamplerRegister = 0;
}
OutputHLSL::~OutputHLSL()
@@ -98,7 +122,7 @@ OutputHLSL::~OutputHLSL()
void OutputHLSL::output()
{
- mContainsLoopDiscontinuity = containsLoopDiscontinuity(mContext.treeRoot);
+ mContainsLoopDiscontinuity = mContext.shaderType == SH_FRAGMENT_SHADER && containsLoopDiscontinuity(mContext.treeRoot);
mContext.treeRoot->traverse(this); // Output the body first to determine what has to go in the header
header();
@@ -112,6 +136,11 @@ TInfoSinkBase &OutputHLSL::getBodyStream()
return mBody;
}
+const ActiveUniforms &OutputHLSL::getUniforms()
+{
+ return mActiveUniforms;
+}
+
int OutputHLSL::vectorSize(const TType &type) const
{
int elementSize = type.isMatrix() ? type.getNominalSize() : 1;
@@ -135,58 +164,71 @@ void OutputHLSL::header()
out << *constructor;
}
- if (shaderType == SH_FRAGMENT_SHADER)
+ TString uniforms;
+ TString varyings;
+ TString attributes;
+
+ for (ReferencedSymbols::const_iterator uniform = mReferencedUniforms.begin(); uniform != mReferencedUniforms.end(); uniform++)
{
- TString uniforms;
- TString varyings;
+ const TType &type = uniform->second->getType();
+ const TString &name = uniform->second->getSymbol();
- TSymbolTableLevel *symbols = mContext.symbolTable.getGlobalLevel();
- int semanticIndex = 0;
+ if (mOutputType == SH_HLSL11_OUTPUT && IsSampler(type.getBasicType())) // Also declare the texture
+ {
+ int index = samplerRegister(mReferencedUniforms[name]);
+
+ uniforms += "uniform SamplerState sampler_" + decorateUniform(name, type) + arrayString(type) +
+ " : register(s" + str(index) + ");\n";
- for (TSymbolTableLevel::const_iterator namedSymbol = symbols->begin(); namedSymbol != symbols->end(); namedSymbol++)
+ uniforms += "uniform " + textureString(type) + " texture_" + decorateUniform(name, type) + arrayString(type) +
+ " : register(t" + str(index) + ");\n";
+ }
+ else
{
- const TSymbol *symbol = (*namedSymbol).second;
- const TString &name = symbol->getName();
+ uniforms += "uniform " + typeString(type) + " " + decorateUniform(name, type) + arrayString(type) +
+ " : register(" + registerString(mReferencedUniforms[name]) + ");\n";
+ }
+ }
- if (symbol->isVariable())
- {
- const TVariable *variable = static_cast<const TVariable*>(symbol);
- const TType &type = variable->getType();
- TQualifier qualifier = type.getQualifier();
+ for (ReferencedSymbols::const_iterator varying = mReferencedVaryings.begin(); varying != mReferencedVaryings.end(); varying++)
+ {
+ const TType &type = varying->second->getType();
+ const TString &name = varying->second->getSymbol();
- if (qualifier == EvqUniform)
- {
- if (mReferencedUniforms.find(name.c_str()) != mReferencedUniforms.end())
- {
- uniforms += "uniform " + typeString(type) + " " + decorateUniform(name, type) + arrayString(type) + ";\n";
- }
- }
- else if (qualifier == EvqVaryingIn || qualifier == EvqInvariantVaryingIn)
- {
- if (mReferencedVaryings.find(name.c_str()) != mReferencedVaryings.end())
- {
- // Program linking depends on this exact format
- varyings += "static " + typeString(type) + " " + decorate(name) + arrayString(type) + " = " + initializer(type) + ";\n";
+ // Program linking depends on this exact format
+ varyings += "static " + typeString(type) + " " + decorate(name) + arrayString(type) + " = " + initializer(type) + ";\n";
+ }
- semanticIndex += type.isArray() ? type.getArraySize() : 1;
- }
- }
- else if (qualifier == EvqGlobal || qualifier == EvqTemporary)
- {
- // Globals are declared and intialized as an aggregate node
- }
- else if (qualifier == EvqConst)
- {
- // Constants are repeated as literals where used
- }
- else UNREACHABLE();
- }
- }
+ for (ReferencedSymbols::const_iterator attribute = mReferencedAttributes.begin(); attribute != mReferencedAttributes.end(); attribute++)
+ {
+ const TType &type = attribute->second->getType();
+ const TString &name = attribute->second->getSymbol();
+
+ attributes += "static " + typeString(type) + " " + decorate(name) + arrayString(type) + " = " + initializer(type) + ";\n";
+ }
+
+ if (shaderType == SH_FRAGMENT_SHADER)
+ {
+ TExtensionBehavior::const_iterator iter = mContext.extensionBehavior().find("GL_EXT_draw_buffers");
+ bool usingMRTExtension = iter != mContext.extensionBehavior().end() && iter->second == EBhEnable;
+
+ unsigned int numColorValues = usingMRTExtension ? mNumRenderTargets : 1;
out << "// Varyings\n";
out << varyings;
out << "\n"
- "static float4 gl_Color[1] = {float4(0, 0, 0, 0)};\n";
+ "static float4 gl_Color[" << numColorValues << "] =\n"
+ "{\n";
+ for (unsigned int i = 0; i < numColorValues; i++)
+ {
+ out << " float4(0, 0, 0, 0)";
+ if (i + 1 != numColorValues)
+ {
+ out << ",";
+ }
+ out << "\n";
+ }
+ out << "};\n";
if (mUsesFragCoord)
{
@@ -205,205 +247,379 @@ void OutputHLSL::header()
out << "\n";
- if (mUsesFragCoord)
+ if (mUsesDepthRange)
+ {
+ out << "struct gl_DepthRangeParameters\n"
+ "{\n"
+ " float near;\n"
+ " float far;\n"
+ " float diff;\n"
+ "};\n"
+ "\n";
+ }
+
+ if (mOutputType == SH_HLSL11_OUTPUT)
{
- out << "uniform float4 dx_Coord;\n"
- "uniform float2 dx_Depth;\n";
+ out << "cbuffer DriverConstants : register(b1)\n"
+ "{\n";
+
+ if (mUsesDepthRange)
+ {
+ out << " float3 dx_DepthRange : packoffset(c0);\n";
+ }
+
+ if (mUsesFragCoord)
+ {
+ out << " float4 dx_ViewCoords : packoffset(c1);\n";
+ }
+
+ if (mUsesFragCoord || mUsesFrontFacing)
+ {
+ out << " float3 dx_DepthFront : packoffset(c2);\n";
+ }
+
+ out << "};\n";
}
+ else
+ {
+ if (mUsesDepthRange)
+ {
+ out << "uniform float3 dx_DepthRange : register(c0);";
+ }
- if (mUsesFrontFacing)
+ if (mUsesFragCoord)
+ {
+ out << "uniform float4 dx_ViewCoords : register(c1);\n";
+ }
+
+ if (mUsesFragCoord || mUsesFrontFacing)
+ {
+ out << "uniform float3 dx_DepthFront : register(c2);\n";
+ }
+ }
+
+ out << "\n";
+
+ if (mUsesDepthRange)
{
- out << "uniform bool dx_PointsOrLines;\n"
- "uniform bool dx_FrontCCW;\n";
+ out << "static gl_DepthRangeParameters gl_DepthRange = {dx_DepthRange.x, dx_DepthRange.y, dx_DepthRange.z};\n"
+ "\n";
}
- out << "\n";
out << uniforms;
out << "\n";
if (mUsesTexture2D)
{
- out << "float4 gl_texture2D(sampler2D s, float2 t)\n"
- "{\n"
- " return tex2D(s, t);\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_texture2D(sampler2D s, float2 t)\n"
+ "{\n"
+ " return tex2D(s, t);\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_texture2D(Texture2D t, SamplerState s, float2 uv)\n"
+ "{\n"
+ " return t.Sample(s, uv);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
if (mUsesTexture2D_bias)
{
- out << "float4 gl_texture2D(sampler2D s, float2 t, float bias)\n"
- "{\n"
- " return tex2Dbias(s, float4(t.x, t.y, 0, bias));\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_texture2D(sampler2D s, float2 t, float bias)\n"
+ "{\n"
+ " return tex2Dbias(s, float4(t.x, t.y, 0, bias));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_texture2D(Texture2D t, SamplerState s, float2 uv, float bias)\n"
+ "{\n"
+ " return t.SampleBias(s, uv, bias);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
if (mUsesTexture2DProj)
{
- out << "float4 gl_texture2DProj(sampler2D s, float3 t)\n"
- "{\n"
- " return tex2Dproj(s, float4(t.x, t.y, 0, t.z));\n"
- "}\n"
- "\n"
- "float4 gl_texture2DProj(sampler2D s, float4 t)\n"
- "{\n"
- " return tex2Dproj(s, t);\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_texture2DProj(sampler2D s, float3 t)\n"
+ "{\n"
+ " return tex2Dproj(s, float4(t.x, t.y, 0, t.z));\n"
+ "}\n"
+ "\n"
+ "float4 gl_texture2DProj(sampler2D s, float4 t)\n"
+ "{\n"
+ " return tex2Dproj(s, t);\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_texture2DProj(Texture2D t, SamplerState s, float3 uvw)\n"
+ "{\n"
+ " return t.Sample(s, float2(uvw.x / uvw.z, uvw.y / uvw.z));\n"
+ "}\n"
+ "\n"
+ "float4 gl_texture2DProj(Texture2D t, SamplerState s, float4 uvw)\n"
+ "{\n"
+ " return t.Sample(s, float2(uvw.x / uvw.w, uvw.y / uvw.w));\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
if (mUsesTexture2DProj_bias)
{
- out << "float4 gl_texture2DProj(sampler2D s, float3 t, float bias)\n"
- "{\n"
- " return tex2Dbias(s, float4(t.x / t.z, t.y / t.z, 0, bias));\n"
- "}\n"
- "\n"
- "float4 gl_texture2DProj(sampler2D s, float4 t, float bias)\n"
- "{\n"
- " return tex2Dbias(s, float4(t.x / t.w, t.y / t.w, 0, bias));\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_texture2DProj(sampler2D s, float3 t, float bias)\n"
+ "{\n"
+ " return tex2Dbias(s, float4(t.x / t.z, t.y / t.z, 0, bias));\n"
+ "}\n"
+ "\n"
+ "float4 gl_texture2DProj(sampler2D s, float4 t, float bias)\n"
+ "{\n"
+ " return tex2Dbias(s, float4(t.x / t.w, t.y / t.w, 0, bias));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_texture2DProj(Texture2D t, SamplerState s, float3 uvw, float bias)\n"
+ "{\n"
+ " return t.SampleBias(s, float2(uvw.x / uvw.z, uvw.y / uvw.z), bias);\n"
+ "}\n"
+ "\n"
+ "float4 gl_texture2DProj(Texture2D t, SamplerState s, float4 uvw, float bias)\n"
+ "{\n"
+ " return t.SampleBias(s, float2(uvw.x / uvw.w, uvw.y / uvw.w), bias);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
if (mUsesTextureCube)
{
- out << "float4 gl_textureCube(samplerCUBE s, float3 t)\n"
- "{\n"
- " return texCUBE(s, t);\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_textureCube(samplerCUBE s, float3 t)\n"
+ "{\n"
+ " return texCUBE(s, t);\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_textureCube(TextureCube t, SamplerState s, float3 uvw)\n"
+ "{\n"
+ " return t.Sample(s, uvw);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
if (mUsesTextureCube_bias)
{
- out << "float4 gl_textureCube(samplerCUBE s, float3 t, float bias)\n"
- "{\n"
- " return texCUBEbias(s, float4(t.x, t.y, t.z, bias));\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_textureCube(samplerCUBE s, float3 t, float bias)\n"
+ "{\n"
+ " return texCUBEbias(s, float4(t.x, t.y, t.z, bias));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_textureCube(TextureCube t, SamplerState s, float3 uvw, float bias)\n"
+ "{\n"
+ " return t.SampleBias(s, uvw, bias);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
// These *Lod0 intrinsics are not available in GL fragment shaders.
// They are used to sample using discontinuous texture coordinates.
if (mUsesTexture2DLod0)
{
- out << "float4 gl_texture2DLod0(sampler2D s, float2 t)\n"
- "{\n"
- " return tex2Dlod(s, float4(t.x, t.y, 0, 0));\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_texture2DLod0(sampler2D s, float2 t)\n"
+ "{\n"
+ " return tex2Dlod(s, float4(t.x, t.y, 0, 0));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_texture2DLod0(Texture2D t, SamplerState s, float2 uv)\n"
+ "{\n"
+ " return t.SampleLevel(s, uv, 0);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
if (mUsesTexture2DLod0_bias)
{
- out << "float4 gl_texture2DLod0(sampler2D s, float2 t, float bias)\n"
- "{\n"
- " return tex2Dlod(s, float4(t.x, t.y, 0, 0));\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_texture2DLod0(sampler2D s, float2 t, float bias)\n"
+ "{\n"
+ " return tex2Dlod(s, float4(t.x, t.y, 0, 0));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_texture2DLod0(Texture2D t, SamplerState s, float2 uv, float bias)\n"
+ "{\n"
+ " return t.SampleLevel(s, uv, 0);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
if (mUsesTexture2DProjLod0)
{
- out << "float4 gl_texture2DProjLod0(sampler2D s, float3 t)\n"
- "{\n"
- " return tex2Dlod(s, float4(t.x / t.z, t.y / t.z, 0, 0));\n"
- "}\n"
- "\n"
- "float4 gl_texture2DProjLod(sampler2D s, float4 t)\n"
- "{\n"
- " return tex2Dlod(s, float4(t.x / t.w, t.y / t.w, 0, 0));\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_texture2DProjLod0(sampler2D s, float3 t)\n"
+ "{\n"
+ " return tex2Dlod(s, float4(t.x / t.z, t.y / t.z, 0, 0));\n"
+ "}\n"
+ "\n"
+ "float4 gl_texture2DProjLod(sampler2D s, float4 t)\n"
+ "{\n"
+ " return tex2Dlod(s, float4(t.x / t.w, t.y / t.w, 0, 0));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_texture2DProjLod0(Texture2D t, SamplerState s, float3 uvw)\n"
+ "{\n"
+ " return t.SampleLevel(s, float2(uvw.x / uvw.z, uvw.y / uvw.z), 0);\n"
+ "}\n"
+ "\n"
+ "float4 gl_texture2DProjLod0(Texture2D t, SamplerState s, float4 uvw)\n"
+ "{\n"
+ " return t.SampleLevel(s, float2(uvw.x / uvw.w, uvw.y / uvw.w), 0);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
if (mUsesTexture2DProjLod0_bias)
{
- out << "float4 gl_texture2DProjLod0_bias(sampler2D s, float3 t, float bias)\n"
- "{\n"
- " return tex2Dlod(s, float4(t.x / t.z, t.y / t.z, 0, 0));\n"
- "}\n"
- "\n"
- "float4 gl_texture2DProjLod_bias(sampler2D s, float4 t, float bias)\n"
- "{\n"
- " return tex2Dlod(s, float4(t.x / t.w, t.y / t.w, 0, 0));\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_texture2DProjLod0_bias(sampler2D s, float3 t, float bias)\n"
+ "{\n"
+ " return tex2Dlod(s, float4(t.x / t.z, t.y / t.z, 0, 0));\n"
+ "}\n"
+ "\n"
+ "float4 gl_texture2DProjLod_bias(sampler2D s, float4 t, float bias)\n"
+ "{\n"
+ " return tex2Dlod(s, float4(t.x / t.w, t.y / t.w, 0, 0));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_texture2DProjLod_bias(Texture2D t, SamplerState s, float3 uvw, float bias)\n"
+ "{\n"
+ " return t.SampleLevel(s, float2(uvw.x / uvw.z, uvw.y / uvw.z), 0);\n"
+ "}\n"
+ "\n"
+ "float4 gl_texture2DProjLod_bias(Texture2D t, SamplerState s, float4 uvw, float bias)\n"
+ "{\n"
+ " return t.SampleLevel(s, float2(uvw.x / uvw.w, uvw.y / uvw.w), 0);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
if (mUsesTextureCubeLod0)
{
- out << "float4 gl_textureCubeLod0(samplerCUBE s, float3 t)\n"
- "{\n"
- " return texCUBElod(s, float4(t.x, t.y, t.z, 0));\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_textureCubeLod0(samplerCUBE s, float3 t)\n"
+ "{\n"
+ " return texCUBElod(s, float4(t.x, t.y, t.z, 0));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_textureCubeLod0(TextureCube t, SamplerState s, float3 uvw)\n"
+ "{\n"
+ " return t.SampleLevel(s, uvw, 0);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
if (mUsesTextureCubeLod0_bias)
{
- out << "float4 gl_textureCubeLod0(samplerCUBE s, float3 t, float bias)\n"
- "{\n"
- " return texCUBElod(s, float4(t.x, t.y, t.z, 0));\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_textureCubeLod0(samplerCUBE s, float3 t, float bias)\n"
+ "{\n"
+ " return texCUBElod(s, float4(t.x, t.y, t.z, 0));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_textureCubeLod0(TextureCube t, SamplerState s, float3 uvw, float bias)\n"
+ "{\n"
+ " return t.SampleLevel(s, uvw, 0);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
- }
- else // Vertex shader
- {
- TString uniforms;
- TString attributes;
- TString varyings;
- TSymbolTableLevel *symbols = mContext.symbolTable.getGlobalLevel();
-
- for (TSymbolTableLevel::const_iterator namedSymbol = symbols->begin(); namedSymbol != symbols->end(); namedSymbol++)
+ if (usingMRTExtension && mNumRenderTargets > 1)
{
- const TSymbol *symbol = (*namedSymbol).second;
- const TString &name = symbol->getName();
-
- if (symbol->isVariable())
- {
- const TVariable *variable = static_cast<const TVariable*>(symbol);
- const TType &type = variable->getType();
- TQualifier qualifier = type.getQualifier();
+ out << "#define GL_USES_MRT\n";
+ }
- if (qualifier == EvqUniform)
- {
- if (mReferencedUniforms.find(name.c_str()) != mReferencedUniforms.end())
- {
- uniforms += "uniform " + typeString(type) + " " + decorateUniform(name, type) + arrayString(type) + ";\n";
- }
- }
- else if (qualifier == EvqAttribute)
- {
- if (mReferencedAttributes.find(name.c_str()) != mReferencedAttributes.end())
- {
- attributes += "static " + typeString(type) + " " + decorate(name) + arrayString(type) + " = " + initializer(type) + ";\n";
- }
- }
- else if (qualifier == EvqVaryingOut || qualifier == EvqInvariantVaryingOut)
- {
- if (mReferencedVaryings.find(name.c_str()) != mReferencedVaryings.end())
- {
- // Program linking depends on this exact format
- varyings += "static " + typeString(type) + " " + decorate(name) + arrayString(type) + " = " + initializer(type) + ";\n";
- }
- }
- else if (qualifier == EvqGlobal || qualifier == EvqTemporary)
- {
- // Globals are declared and intialized as an aggregate node
- }
- else if (qualifier == EvqConst)
- {
- // Constants are repeated as literals where used
- }
- else UNREACHABLE();
- }
+ if (mUsesFragColor)
+ {
+ out << "#define GL_USES_FRAG_COLOR\n";
}
+ if (mUsesFragData)
+ {
+ out << "#define GL_USES_FRAG_DATA\n";
+ }
+ }
+ else // Vertex shader
+ {
out << "// Attributes\n";
out << attributes;
out << "\n"
@@ -417,74 +633,194 @@ void OutputHLSL::header()
out << "\n"
"// Varyings\n";
out << varyings;
- out << "\n"
- "uniform float2 dx_HalfPixelSize;\n"
- "\n";
- out << uniforms;
out << "\n";
-
- if (mUsesTexture2D)
+
+ if (mUsesDepthRange)
{
- out << "float4 gl_texture2D(sampler2D s, float2 t)\n"
+ out << "struct gl_DepthRangeParameters\n"
"{\n"
- " return tex2Dlod(s, float4(t.x, t.y, 0, 0));\n"
- "}\n"
+ " float near;\n"
+ " float far;\n"
+ " float diff;\n"
+ "};\n"
"\n";
}
- if (mUsesTexture2DLod)
+ if (mOutputType == SH_HLSL11_OUTPUT)
{
- out << "float4 gl_texture2DLod(sampler2D s, float2 t, float lod)\n"
- "{\n"
- " return tex2Dlod(s, float4(t.x, t.y, 0, lod));\n"
- "}\n"
+ if (mUsesDepthRange)
+ {
+ out << "cbuffer DriverConstants : register(b1)\n"
+ "{\n"
+ " float3 dx_DepthRange : packoffset(c0);\n"
+ "};\n"
+ "\n";
+ }
+ }
+ else
+ {
+ if (mUsesDepthRange)
+ {
+ out << "uniform float3 dx_DepthRange : register(c0);\n";
+ }
+
+ out << "uniform float4 dx_ViewAdjust : register(c1);\n"
"\n";
}
- if (mUsesTexture2DProj)
+ if (mUsesDepthRange)
{
- out << "float4 gl_texture2DProj(sampler2D s, float3 t)\n"
- "{\n"
- " return tex2Dlod(s, float4(t.x / t.z, t.y / t.z, 0, 0));\n"
- "}\n"
- "\n"
- "float4 gl_texture2DProj(sampler2D s, float4 t)\n"
- "{\n"
- " return tex2Dlod(s, float4(t.x / t.w, t.y / t.w, 0, 0));\n"
- "}\n"
+ out << "static gl_DepthRangeParameters gl_DepthRange = {dx_DepthRange.x, dx_DepthRange.y, dx_DepthRange.z};\n"
"\n";
}
+ out << uniforms;
+ out << "\n";
+
+ if (mUsesTexture2D)
+ {
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_texture2D(sampler2D s, float2 t)\n"
+ "{\n"
+ " return tex2Dlod(s, float4(t.x, t.y, 0, 0));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_texture2D(Texture2D t, SamplerState s, float2 uv)\n"
+ "{\n"
+ " return t.SampleLevel(s, uv, 0);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
+ }
+
+ if (mUsesTexture2DLod)
+ {
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_texture2DLod(sampler2D s, float2 t, float lod)\n"
+ "{\n"
+ " return tex2Dlod(s, float4(t.x, t.y, 0, lod));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_texture2DLod(Texture2D t, SamplerState s, float2 uv, float lod)\n"
+ "{\n"
+ " return t.SampleLevel(s, uv, lod);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
+ }
+
+ if (mUsesTexture2DProj)
+ {
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_texture2DProj(sampler2D s, float3 t)\n"
+ "{\n"
+ " return tex2Dlod(s, float4(t.x / t.z, t.y / t.z, 0, 0));\n"
+ "}\n"
+ "\n"
+ "float4 gl_texture2DProj(sampler2D s, float4 t)\n"
+ "{\n"
+ " return tex2Dlod(s, float4(t.x / t.w, t.y / t.w, 0, 0));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_texture2DProj(Texture2D t, SamplerState s, float3 uvw)\n"
+ "{\n"
+ " return t.SampleLevel(s, float2(uvw.x / uvw.z, uvw.y / uvw.z), 0);\n"
+ "}\n"
+ "\n"
+ "float4 gl_texture2DProj(Texture2D t, SamplerState s, float4 uvw)\n"
+ "{\n"
+ " return t.SampleLevel(s, float2(uvw.x / uvw.w, uvw.y / uvw.w), 0);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
+ }
+
if (mUsesTexture2DProjLod)
{
- out << "float4 gl_texture2DProjLod(sampler2D s, float3 t, float lod)\n"
- "{\n"
- " return tex2Dlod(s, float4(t.x / t.z, t.y / t.z, 0, lod));\n"
- "}\n"
- "\n"
- "float4 gl_texture2DProjLod(sampler2D s, float4 t, float lod)\n"
- "{\n"
- " return tex2Dlod(s, float4(t.x / t.w, t.y / t.w, 0, lod));\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_texture2DProjLod(sampler2D s, float3 t, float lod)\n"
+ "{\n"
+ " return tex2Dlod(s, float4(t.x / t.z, t.y / t.z, 0, lod));\n"
+ "}\n"
+ "\n"
+ "float4 gl_texture2DProjLod(sampler2D s, float4 t, float lod)\n"
+ "{\n"
+ " return tex2Dlod(s, float4(t.x / t.w, t.y / t.w, 0, lod));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_texture2DProj(Texture2D t, SamplerState s, float3 uvw, float lod)\n"
+ "{\n"
+ " return t.SampleLevel(s, float2(uvw.x / uvw.z, uvw.y / uvw.z), lod);\n"
+ "}\n"
+ "\n"
+ "float4 gl_texture2DProj(Texture2D t, SamplerState s, float4 uvw)\n"
+ "{\n"
+ " return t.SampleLevel(s, float2(uvw.x / uvw.w, uvw.y / uvw.w), lod);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
if (mUsesTextureCube)
{
- out << "float4 gl_textureCube(samplerCUBE s, float3 t)\n"
- "{\n"
- " return texCUBElod(s, float4(t.x, t.y, t.z, 0));\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_textureCube(samplerCUBE s, float3 t)\n"
+ "{\n"
+ " return texCUBElod(s, float4(t.x, t.y, t.z, 0));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_textureCube(TextureCube t, SamplerState s, float3 uvw)\n"
+ "{\n"
+ " return t.SampleLevel(s, uvw, 0);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
if (mUsesTextureCubeLod)
{
- out << "float4 gl_textureCubeLod(samplerCUBE s, float3 t, float lod)\n"
- "{\n"
- " return texCUBElod(s, float4(t.x, t.y, t.z, lod));\n"
- "}\n"
- "\n";
+ if (mOutputType == SH_HLSL9_OUTPUT)
+ {
+ out << "float4 gl_textureCubeLod(samplerCUBE s, float3 t, float lod)\n"
+ "{\n"
+ " return texCUBElod(s, float4(t.x, t.y, t.z, lod));\n"
+ "}\n"
+ "\n";
+ }
+ else if (mOutputType == SH_HLSL11_OUTPUT)
+ {
+ out << "float4 gl_textureCubeLod(TextureCube t, SamplerState s, float3 uvw, float lod)\n"
+ "{\n"
+ " return t.SampleLevel(s, uvw, lod);\n"
+ "}\n"
+ "\n";
+ }
+ else UNREACHABLE();
}
}
@@ -508,20 +844,6 @@ void OutputHLSL::header()
out << "#define GL_USES_POINT_SIZE\n";
}
- if (mUsesDepthRange)
- {
- out << "struct gl_DepthRangeParameters\n"
- "{\n"
- " float near;\n"
- " float far;\n"
- " float diff;\n"
- "};\n"
- "\n"
- "uniform float3 dx_DepthRange;"
- "static gl_DepthRangeParameters gl_DepthRange = {dx_DepthRange.x, dx_DepthRange.y, dx_DepthRange.z};\n"
- "\n";
- }
-
if (mUsesXor)
{
out << "bool xor(bool p, bool q)\n"
@@ -812,10 +1134,12 @@ void OutputHLSL::visitSymbol(TIntermSymbol *node)
if (name == "gl_FragColor")
{
out << "gl_Color[0]";
+ mUsesFragColor = true;
}
else if (name == "gl_FragData")
{
out << "gl_Color";
+ mUsesFragData = true;
}
else if (name == "gl_DepthRange")
{
@@ -848,17 +1172,17 @@ void OutputHLSL::visitSymbol(TIntermSymbol *node)
if (qualifier == EvqUniform)
{
- mReferencedUniforms.insert(name.c_str());
+ mReferencedUniforms[name] = node;
out << decorateUniform(name, node->getType());
}
else if (qualifier == EvqAttribute)
{
- mReferencedAttributes.insert(name.c_str());
+ mReferencedAttributes[name] = node;
out << decorate(name);
}
else if (qualifier == EvqVaryingOut || qualifier == EvqInvariantVaryingOut || qualifier == EvqVaryingIn || qualifier == EvqInvariantVaryingIn)
{
- mReferencedVaryings.insert(name.c_str());
+ mReferencedVaryings[name] = node;
out << decorate(name);
}
else
@@ -973,7 +1297,7 @@ bool OutputHLSL::visitBinary(Visit visit, TIntermBinary *node)
if (element)
{
- int i = element->getUnionArrayPointer()[0].getIConst();
+ int i = element->getIConst(0);
switch (i)
{
@@ -1276,7 +1600,6 @@ bool OutputHLSL::visitAggregate(Visit visit, TIntermAggregate *node)
{
TIntermSequence &sequence = node->getSequence();
TIntermTyped *variable = sequence[0]->getAsTyped();
- bool visit = true;
if (variable && (variable->getQualifier() == EvqTemporary || variable->getQualifier() == EvqGlobal))
{
@@ -1309,19 +1632,11 @@ bool OutputHLSL::visitAggregate(Visit visit, TIntermAggregate *node)
(*sit)->traverse(this);
}
- if (visit && this->inVisit)
+ if (*sit != sequence.back())
{
- if (*sit != sequence.back())
- {
- visit = this->visitAggregate(InVisit, node);
- }
+ out << ", ";
}
}
-
- if (visit && this->postVisit)
- {
- this->visitAggregate(PostVisit, node);
- }
}
else if (variable->getAsSymbolNode() && variable->getAsSymbolNode()->getSymbol() == "") // Type (struct) declaration
{
@@ -1329,7 +1644,24 @@ bool OutputHLSL::visitAggregate(Visit visit, TIntermAggregate *node)
}
else UNREACHABLE();
}
-
+ else if (variable && (variable->getQualifier() == EvqVaryingOut || variable->getQualifier() == EvqInvariantVaryingOut))
+ {
+ for (TIntermSequence::iterator sit = sequence.begin(); sit != sequence.end(); sit++)
+ {
+ TIntermSymbol *symbol = (*sit)->getAsSymbolNode();
+
+ if (symbol)
+ {
+ // Vertex (output) varyings which are declared but not written to should still be declared to allow successful linking
+ mReferencedVaryings[symbol->getSymbol()] = symbol;
+ }
+ else
+ {
+ (*sit)->traverse(this);
+ }
+ }
+ }
+
return false;
}
else if (visit == InVisit)
@@ -1440,151 +1772,163 @@ bool OutputHLSL::visitAggregate(Visit visit, TIntermAggregate *node)
break;
case EOpFunctionCall:
{
- if (visit == PreVisit)
- {
- TString name = TFunction::unmangleName(node->getName());
- bool lod0 = mInsideDiscontinuousLoop || mOutputLod0Function;
+ TString name = TFunction::unmangleName(node->getName());
+ bool lod0 = mInsideDiscontinuousLoop || mOutputLod0Function;
- if (node->isUserDefined())
- {
- out << decorate(name) << (lod0 ? "Lod0(" : "(");
- }
- else
+ if (node->isUserDefined())
+ {
+ out << decorate(name) << (lod0 ? "Lod0(" : "(");
+ }
+ else
+ {
+ if (name == "texture2D")
{
- if (name == "texture2D")
+ if (!lod0)
{
- if (!lod0)
+ if (node->getSequence().size() == 2)
{
- if (node->getSequence().size() == 2)
- {
- mUsesTexture2D = true;
- }
- else if (node->getSequence().size() == 3)
- {
- mUsesTexture2D_bias = true;
- }
- else UNREACHABLE();
-
- out << "gl_texture2D(";
+ mUsesTexture2D = true;
}
- else
+ else if (node->getSequence().size() == 3)
{
- if (node->getSequence().size() == 2)
- {
- mUsesTexture2DLod0 = true;
- }
- else if (node->getSequence().size() == 3)
- {
- mUsesTexture2DLod0_bias = true;
- }
- else UNREACHABLE();
-
- out << "gl_texture2DLod0(";
+ mUsesTexture2D_bias = true;
}
+ else UNREACHABLE();
+
+ out << "gl_texture2D(";
}
- else if (name == "texture2DProj")
+ else
{
- if (!lod0)
+ if (node->getSequence().size() == 2)
{
- if (node->getSequence().size() == 2)
- {
- mUsesTexture2DProj = true;
- }
- else if (node->getSequence().size() == 3)
- {
- mUsesTexture2DProj_bias = true;
- }
- else UNREACHABLE();
-
- out << "gl_texture2DProj(";
+ mUsesTexture2DLod0 = true;
}
- else
+ else if (node->getSequence().size() == 3)
{
- if (node->getSequence().size() == 2)
- {
- mUsesTexture2DProjLod0 = true;
- }
- else if (node->getSequence().size() == 3)
- {
- mUsesTexture2DProjLod0_bias = true;
- }
- else UNREACHABLE();
-
- out << "gl_texture2DProjLod0(";
+ mUsesTexture2DLod0_bias = true;
}
+ else UNREACHABLE();
+
+ out << "gl_texture2DLod0(";
}
- else if (name == "textureCube")
+ }
+ else if (name == "texture2DProj")
+ {
+ if (!lod0)
{
- if (!lod0)
+ if (node->getSequence().size() == 2)
{
- if (node->getSequence().size() == 2)
- {
- mUsesTextureCube = true;
- }
- else if (node->getSequence().size() == 3)
- {
- mUsesTextureCube_bias = true;
- }
- else UNREACHABLE();
-
- out << "gl_textureCube(";
+ mUsesTexture2DProj = true;
}
- else
+ else if (node->getSequence().size() == 3)
{
- if (node->getSequence().size() == 2)
- {
- mUsesTextureCubeLod0 = true;
- }
- else if (node->getSequence().size() == 3)
- {
- mUsesTextureCubeLod0_bias = true;
- }
- else UNREACHABLE();
-
- out << "gl_textureCubeLod0(";
+ mUsesTexture2DProj_bias = true;
}
+ else UNREACHABLE();
+
+ out << "gl_texture2DProj(";
}
- else if (name == "texture2DLod")
+ else
{
- if (node->getSequence().size() == 3)
+ if (node->getSequence().size() == 2)
+ {
+ mUsesTexture2DProjLod0 = true;
+ }
+ else if (node->getSequence().size() == 3)
{
- mUsesTexture2DLod = true;
+ mUsesTexture2DProjLod0_bias = true;
}
else UNREACHABLE();
- out << "gl_texture2DLod(";
+ out << "gl_texture2DProjLod0(";
}
- else if (name == "texture2DProjLod")
+ }
+ else if (name == "textureCube")
+ {
+ if (!lod0)
{
- if (node->getSequence().size() == 3)
+ if (node->getSequence().size() == 2)
+ {
+ mUsesTextureCube = true;
+ }
+ else if (node->getSequence().size() == 3)
{
- mUsesTexture2DProjLod = true;
+ mUsesTextureCube_bias = true;
}
else UNREACHABLE();
- out << "gl_texture2DProjLod(";
+ out << "gl_textureCube(";
}
- else if (name == "textureCubeLod")
+ else
{
- if (node->getSequence().size() == 3)
+ if (node->getSequence().size() == 2)
{
- mUsesTextureCubeLod = true;
+ mUsesTextureCubeLod0 = true;
+ }
+ else if (node->getSequence().size() == 3)
+ {
+ mUsesTextureCubeLod0_bias = true;
}
else UNREACHABLE();
- out << "gl_textureCubeLod(";
+ out << "gl_textureCubeLod0(";
+ }
+ }
+ else if (name == "texture2DLod")
+ {
+ if (node->getSequence().size() == 3)
+ {
+ mUsesTexture2DLod = true;
+ }
+ else UNREACHABLE();
+
+ out << "gl_texture2DLod(";
+ }
+ else if (name == "texture2DProjLod")
+ {
+ if (node->getSequence().size() == 3)
+ {
+ mUsesTexture2DProjLod = true;
}
else UNREACHABLE();
+
+ out << "gl_texture2DProjLod(";
}
+ else if (name == "textureCubeLod")
+ {
+ if (node->getSequence().size() == 3)
+ {
+ mUsesTextureCubeLod = true;
+ }
+ else UNREACHABLE();
+
+ out << "gl_textureCubeLod(";
+ }
+ else UNREACHABLE();
}
- else if (visit == InVisit)
- {
- out << ", ";
- }
- else
+
+ TIntermSequence &arguments = node->getSequence();
+
+ for (TIntermSequence::iterator arg = arguments.begin(); arg != arguments.end(); arg++)
{
- out << ")";
+ if (mOutputType == SH_HLSL11_OUTPUT && IsSampler((*arg)->getAsTyped()->getBasicType()))
+ {
+ out << "texture_";
+ (*arg)->traverse(this);
+ out << ", sampler_";
+ }
+
+ (*arg)->traverse(this);
+
+ if (arg < arguments.end() - 1)
+ {
+ out << ", ";
+ }
}
+
+ out << ")";
+
+ return false;
}
break;
case EOpParameters: outputTriplet(visit, "(", ", ", ")\n{\n"); break;
@@ -1778,14 +2122,17 @@ bool OutputHLSL::visitLoop(Visit visit, TIntermLoop *node)
{
bool wasDiscontinuous = mInsideDiscontinuousLoop;
- if (!mInsideDiscontinuousLoop)
+ if (mContainsLoopDiscontinuity && !mInsideDiscontinuousLoop)
{
mInsideDiscontinuousLoop = containsLoopDiscontinuity(node);
}
- if (handleExcessiveLoop(node))
+ if (mOutputType == SH_HLSL9_OUTPUT)
{
- return false;
+ if (handleExcessiveLoop(node))
+ {
+ return false;
+ }
}
TInfoSinkBase &out = mBody;
@@ -1976,7 +2323,7 @@ bool OutputHLSL::handleExcessiveLoop(TIntermLoop *node)
if (constant->getBasicType() == EbtInt && constant->getNominalSize() == 1)
{
index = symbol;
- initial = constant->getUnionArrayPointer()[0].getIConst();
+ initial = constant->getIConst(0);
}
}
}
@@ -1998,7 +2345,7 @@ bool OutputHLSL::handleExcessiveLoop(TIntermLoop *node)
if (constant->getBasicType() == EbtInt && constant->getNominalSize() == 1)
{
comparator = test->getOp();
- limit = constant->getUnionArrayPointer()[0].getIConst();
+ limit = constant->getIConst(0);
}
}
}
@@ -2019,7 +2366,7 @@ bool OutputHLSL::handleExcessiveLoop(TIntermLoop *node)
{
if (constant->getBasicType() == EbtInt && constant->getNominalSize() == 1)
{
- int value = constant->getUnionArrayPointer()[0].getIConst();
+ int value = constant->getIConst(0);
switch (op)
{
@@ -2191,6 +2538,12 @@ TString OutputHLSL::argumentString(const TIntermSymbol *symbol)
name = decorate(name);
}
+ if (mOutputType == SH_HLSL11_OUTPUT && IsSampler(type.getBasicType()))
+ {
+ return qualifierString(qualifier) + " " + textureString(type) + " texture_" + name + arrayString(type) + ", " +
+ qualifierString(qualifier) + " SamplerState sampler_" + name + arrayString(type);
+ }
+
return qualifierString(qualifier) + " " + typeString(type) + " " + name + arrayString(type);
}
@@ -2285,10 +2638,28 @@ TString OutputHLSL::typeString(const TType &type)
}
}
- UNIMPLEMENTED(); // FIXME
+ UNREACHABLE();
return "<unknown type>";
}
+TString OutputHLSL::textureString(const TType &type)
+{
+ switch (type.getBasicType())
+ {
+ case EbtSampler2D:
+ return "Texture2D";
+ case EbtSamplerCube:
+ return "TextureCube";
+ case EbtSamplerExternalOES:
+ return "Texture2D";
+ default:
+ break;
+ }
+
+ UNREACHABLE();
+ return "<unknown texture type>";
+}
+
TString OutputHLSL::arrayString(const TType &type)
{
if (!type.isArray())
@@ -2565,7 +2936,7 @@ const ConstantUnion *OutputHLSL::writeConstantUnion(const TType &type, const Con
{
switch (constUnion->getType())
{
- case EbtFloat: out << constUnion->getFConst(); break;
+ case EbtFloat: out << std::min(FLT_MAX, std::max(-FLT_MAX, constUnion->getFConst())); break;
case EbtInt: out << constUnion->getIConst(); break;
case EbtBool: out << constUnion->getBConst(); break;
default: UNREACHABLE();
@@ -2640,11 +3011,7 @@ TString OutputHLSL::decorate(const TString &string)
TString OutputHLSL::decorateUniform(const TString &string, const TType &type)
{
- if (type.isArray())
- {
- return "ar_" + string; // Allows identifying arrays of size 1
- }
- else if (type.getBasicType() == EbtSamplerExternalOES)
+ if (type.getBasicType() == EbtSamplerExternalOES)
{
return "ex_" + string;
}
@@ -2661,4 +3028,197 @@ TString OutputHLSL::decorateField(const TString &string, const TType &structure)
return string;
}
+
+TString OutputHLSL::registerString(TIntermSymbol *operand)
+{
+ ASSERT(operand->getQualifier() == EvqUniform);
+
+ if (IsSampler(operand->getBasicType()))
+ {
+ return "s" + str(samplerRegister(operand));
+ }
+
+ return "c" + str(uniformRegister(operand));
+}
+
+int OutputHLSL::samplerRegister(TIntermSymbol *sampler)
+{
+ const TType &type = sampler->getType();
+ ASSERT(IsSampler(type.getBasicType()));
+
+ int index = mSamplerRegister;
+ mSamplerRegister += sampler->totalRegisterCount();
+
+ declareUniform(type, sampler->getSymbol(), index);
+
+ return index;
+}
+
+int OutputHLSL::uniformRegister(TIntermSymbol *uniform)
+{
+ const TType &type = uniform->getType();
+ ASSERT(!IsSampler(type.getBasicType()));
+
+ int index = mUniformRegister;
+ mUniformRegister += uniform->totalRegisterCount();
+
+ declareUniform(type, uniform->getSymbol(), index);
+
+ return index;
+}
+
+void OutputHLSL::declareUniform(const TType &type, const TString &name, int index)
+{
+ const TTypeList *structure = type.getStruct();
+
+ if (!structure)
+ {
+ mActiveUniforms.push_back(Uniform(glVariableType(type), glVariablePrecision(type), name.c_str(), type.getArraySize(), index));
+ }
+ else
+ {
+ if (type.isArray())
+ {
+ int elementIndex = index;
+
+ for (int i = 0; i < type.getArraySize(); i++)
+ {
+ for (size_t j = 0; j < structure->size(); j++)
+ {
+ const TType &fieldType = *(*structure)[j].type;
+ const TString &fieldName = fieldType.getFieldName();
+
+ const TString uniformName = name + "[" + str(i) + "]." + fieldName;
+ declareUniform(fieldType, uniformName, elementIndex);
+ elementIndex += fieldType.totalRegisterCount();
+ }
+ }
+ }
+ else
+ {
+ int fieldIndex = index;
+
+ for (size_t i = 0; i < structure->size(); i++)
+ {
+ const TType &fieldType = *(*structure)[i].type;
+ const TString &fieldName = fieldType.getFieldName();
+
+ const TString uniformName = name + "." + fieldName;
+ declareUniform(fieldType, uniformName, fieldIndex);
+ fieldIndex += fieldType.totalRegisterCount();
+ }
+ }
+ }
+}
+
+GLenum OutputHLSL::glVariableType(const TType &type)
+{
+ if (type.getBasicType() == EbtFloat)
+ {
+ if (type.isScalar())
+ {
+ return GL_FLOAT;
+ }
+ else if (type.isVector())
+ {
+ switch(type.getNominalSize())
+ {
+ case 2: return GL_FLOAT_VEC2;
+ case 3: return GL_FLOAT_VEC3;
+ case 4: return GL_FLOAT_VEC4;
+ default: UNREACHABLE();
+ }
+ }
+ else if (type.isMatrix())
+ {
+ switch(type.getNominalSize())
+ {
+ case 2: return GL_FLOAT_MAT2;
+ case 3: return GL_FLOAT_MAT3;
+ case 4: return GL_FLOAT_MAT4;
+ default: UNREACHABLE();
+ }
+ }
+ else UNREACHABLE();
+ }
+ else if (type.getBasicType() == EbtInt)
+ {
+ if (type.isScalar())
+ {
+ return GL_INT;
+ }
+ else if (type.isVector())
+ {
+ switch(type.getNominalSize())
+ {
+ case 2: return GL_INT_VEC2;
+ case 3: return GL_INT_VEC3;
+ case 4: return GL_INT_VEC4;
+ default: UNREACHABLE();
+ }
+ }
+ else UNREACHABLE();
+ }
+ else if (type.getBasicType() == EbtBool)
+ {
+ if (type.isScalar())
+ {
+ return GL_BOOL;
+ }
+ else if (type.isVector())
+ {
+ switch(type.getNominalSize())
+ {
+ case 2: return GL_BOOL_VEC2;
+ case 3: return GL_BOOL_VEC3;
+ case 4: return GL_BOOL_VEC4;
+ default: UNREACHABLE();
+ }
+ }
+ else UNREACHABLE();
+ }
+ else if (type.getBasicType() == EbtSampler2D)
+ {
+ return GL_SAMPLER_2D;
+ }
+ else if (type.getBasicType() == EbtSamplerCube)
+ {
+ return GL_SAMPLER_CUBE;
+ }
+ else UNREACHABLE();
+
+ return GL_NONE;
+}
+
+GLenum OutputHLSL::glVariablePrecision(const TType &type)
+{
+ if (type.getBasicType() == EbtFloat)
+ {
+ switch (type.getPrecision())
+ {
+ case EbpHigh: return GL_HIGH_FLOAT;
+ case EbpMedium: return GL_MEDIUM_FLOAT;
+ case EbpLow: return GL_LOW_FLOAT;
+ case EbpUndefined:
+ // Should be defined as the default precision by the parser
+ default: UNREACHABLE();
+ }
+ }
+ else if (type.getBasicType() == EbtInt)
+ {
+ switch (type.getPrecision())
+ {
+ case EbpHigh: return GL_HIGH_INT;
+ case EbpMedium: return GL_MEDIUM_INT;
+ case EbpLow: return GL_LOW_INT;
+ case EbpUndefined:
+ // Should be defined as the default precision by the parser
+ default: UNREACHABLE();
+ }
+ }
+
+ // Other types (boolean, sampler) don't have a precision
+ return GL_NONE;
+}
+
}
diff --git a/src/3rdparty/angle/src/compiler/OutputHLSL.h b/src/3rdparty/angle/src/compiler/OutputHLSL.h
index dc843fb366..749a3461b3 100644
--- a/src/3rdparty/angle/src/compiler/OutputHLSL.h
+++ b/src/3rdparty/angle/src/compiler/OutputHLSL.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -9,9 +9,14 @@
#include <list>
#include <set>
+#include <map>
+
+#define GL_APICALL
+#include <GLES2/gl2.h>
#include "compiler/intermediate.h"
#include "compiler/ParseHelper.h"
+#include "compiler/Uniform.h"
namespace sh
{
@@ -20,14 +25,16 @@ class UnfoldShortCircuit;
class OutputHLSL : public TIntermTraverser
{
public:
- explicit OutputHLSL(TParseContext &context);
+ OutputHLSL(TParseContext &context, const ShBuiltInResources& resources, ShShaderOutput outputType);
~OutputHLSL();
void output();
TInfoSinkBase &getBodyStream();
+ const ActiveUniforms &getUniforms();
TString typeString(const TType &type);
+ TString textureString(const TType &type);
static TString qualifierString(TQualifier qualifier);
static TString arrayString(const TType &type);
static TString initializer(const TType &type);
@@ -64,6 +71,7 @@ class OutputHLSL : public TIntermTraverser
TString structLookup(const TString &typeName);
TParseContext &mContext;
+ const ShShaderOutput mOutputType;
UnfoldShortCircuit *mUnfoldShortCircuit;
bool mInsideFunction;
@@ -72,9 +80,10 @@ class OutputHLSL : public TIntermTraverser
TInfoSinkBase mBody;
TInfoSinkBase mFooter;
- std::set<std::string> mReferencedUniforms;
- std::set<std::string> mReferencedAttributes;
- std::set<std::string> mReferencedVaryings;
+ typedef std::map<TString, TIntermSymbol*> ReferencedSymbols;
+ ReferencedSymbols mReferencedUniforms;
+ ReferencedSymbols mReferencedAttributes;
+ ReferencedSymbols mReferencedVaryings;
// Parameters determining what goes in the header output
bool mUsesTexture2D;
@@ -92,6 +101,8 @@ class OutputHLSL : public TIntermTraverser
bool mUsesTexture2DProjLod0_bias;
bool mUsesTextureCubeLod0;
bool mUsesTextureCubeLod0_bias;
+ bool mUsesFragColor;
+ bool mUsesFragData;
bool mUsesDepthRange;
bool mUsesFragCoord;
bool mUsesPointCoord;
@@ -126,6 +137,8 @@ class OutputHLSL : public TIntermTraverser
bool mUsesAtan2_3;
bool mUsesAtan2_4;
+ int mNumRenderTargets;
+
typedef std::set<TString> Constructors;
Constructors mConstructors;
@@ -146,6 +159,18 @@ class OutputHLSL : public TIntermTraverser
bool mInsideDiscontinuousLoop;
TIntermSymbol *mExcessiveLoopIndex;
+
+ int mUniformRegister;
+ int mSamplerRegister;
+
+ TString registerString(TIntermSymbol *operand);
+ int samplerRegister(TIntermSymbol *sampler);
+ int uniformRegister(TIntermSymbol *uniform);
+ void declareUniform(const TType &type, const TString &name, int index);
+ static GLenum glVariableType(const TType &type);
+ static GLenum glVariablePrecision(const TType &type);
+
+ ActiveUniforms mActiveUniforms;
};
}
diff --git a/src/3rdparty/angle/src/compiler/ParseHelper.cpp b/src/3rdparty/angle/src/compiler/ParseHelper.cpp
index 508f1726a7..441ff35e00 100644
--- a/src/3rdparty/angle/src/compiler/ParseHelper.cpp
+++ b/src/3rdparty/angle/src/compiler/ParseHelper.cpp
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -10,7 +10,7 @@
#include <stdio.h>
#include "compiler/glslang.h"
-#include "compiler/preprocessor/new/SourceLocation.h"
+#include "compiler/preprocessor/SourceLocation.h"
///////////////////////////////////////////////////////////////////////
//
@@ -33,7 +33,7 @@ bool TParseContext::parseVectorFields(const TString& compString, int vecSize, TV
enum {
exyzw,
ergba,
- estpq,
+ estpq
} fieldSet[4];
for (int i = 0; i < fields.num; ++i) {
@@ -286,7 +286,7 @@ bool TParseContext::lValueErrorCheck(int line, const char* op, TIntermTyped* nod
for (TIntermSequence::iterator p = aggrNode->getSequence().begin();
p != aggrNode->getSequence().end(); p++) {
- int value = (*p)->getAsTyped()->getAsConstantUnion()->getUnionArrayPointer()->getIConst();
+ int value = (*p)->getAsTyped()->getAsConstantUnion()->getIConst(0);
offset[value]++;
if (offset[value] > 1) {
error(line, " l-value of swizzle cannot have duplicate components", op);
@@ -493,7 +493,7 @@ bool TParseContext::constructorErrorCheck(int line, TIntermNode* node, TFunction
bool overFull = false;
bool matrixInMatrix = false;
bool arrayArg = false;
- for (int i = 0; i < function.getParamCount(); ++i) {
+ for (size_t i = 0; i < function.getParamCount(); ++i) {
const TParameter& param = function.getParam(i);
size += param.type->getObjectSize();
@@ -512,7 +512,7 @@ bool TParseContext::constructorErrorCheck(int line, TIntermNode* node, TFunction
if (constType)
type->setQualifier(EvqConst);
- if (type->isArray() && type->getArraySize() != function.getParamCount()) {
+ if (type->isArray() && static_cast<size_t>(type->getArraySize()) != function.getParamCount()) {
error(line, "array constructor needs one argument per array element", "constructor");
return true;
}
@@ -680,7 +680,7 @@ bool TParseContext::arraySizeErrorCheck(int line, TIntermTyped* expr, int& size)
return true;
}
- size = constant->getUnionArrayPointer()->getIConst();
+ size = constant->getIConst(0);
if (size <= 0) {
error(line, "array size must be a positive integer", "");
@@ -1313,7 +1313,6 @@ TIntermTyped* TParseContext::addConstVectorNode(TVectorFields& fields, TIntermTy
ConstantUnion *unionArray;
if (tempConstantNode) {
unionArray = tempConstantNode->getUnionArrayPointer();
- ASSERT(unionArray);
if (!unionArray) {
return node;
@@ -1507,7 +1506,7 @@ bool TParseContext::structNestingErrorCheck(TSourceLoc line, const TType& fieldT
//
// Returns 0 for success.
//
-int PaParseStrings(int count, const char* const string[], const int length[],
+int PaParseStrings(size_t count, const char* const string[], const int length[],
TParseContext* context) {
if ((count == 0) || (string == NULL))
return 1;
diff --git a/src/3rdparty/angle/src/compiler/ParseHelper.h b/src/3rdparty/angle/src/compiler/ParseHelper.h
index 824ee00f39..26a3ea1308 100644
--- a/src/3rdparty/angle/src/compiler/ParseHelper.h
+++ b/src/3rdparty/angle/src/compiler/ParseHelper.h
@@ -9,7 +9,7 @@
#include "compiler/Diagnostics.h"
#include "compiler/DirectiveHandler.h"
#include "compiler/localintermediate.h"
-#include "compiler/preprocessor/new/Preprocessor.h"
+#include "compiler/preprocessor/Preprocessor.h"
#include "compiler/ShHandle.h"
#include "compiler/SymbolTable.h"
@@ -58,6 +58,7 @@ struct TParseContext {
const TType* currentFunctionType; // the return type of the function that's currently being parsed
bool functionReturnsValue; // true if a non-void function has a return
bool checksPrecisionErrors; // true if an error will be generated when a variable is declared without precision, explicit or implicit.
+ bool fragmentPrecisionHigh; // true if highp precision is supported in the fragment language.
TString HashErrMsg;
bool AfterEOF;
TDiagnostics diagnostics;
@@ -134,7 +135,7 @@ struct TParseContext {
bool structNestingErrorCheck(TSourceLoc line, const TType& fieldType);
};
-int PaParseStrings(int count, const char* const string[], const int length[],
+int PaParseStrings(size_t count, const char* const string[], const int length[],
TParseContext* context);
#endif // _PARSER_HELPER_INCLUDED_
diff --git a/src/3rdparty/angle/src/compiler/ShHandle.h b/src/3rdparty/angle/src/compiler/ShHandle.h
index 6ba302ad04..28049305e0 100644
--- a/src/3rdparty/angle/src/compiler/ShHandle.h
+++ b/src/3rdparty/angle/src/compiler/ShHandle.h
@@ -18,13 +18,16 @@
#include "compiler/BuiltInFunctionEmulator.h"
#include "compiler/ExtensionBehavior.h"
+#include "compiler/HashNames.h"
#include "compiler/InfoSink.h"
#include "compiler/SymbolTable.h"
#include "compiler/VariableInfo.h"
+#include "third_party/compiler/ArrayBoundsClamper.h"
class LongNameMap;
class TCompiler;
class TDependencyGraph;
+class TranslatorHLSL;
//
// Helper function to identify specs that are based on the WebGL spec,
@@ -40,6 +43,7 @@ public:
TShHandleBase();
virtual ~TShHandleBase();
virtual TCompiler* getAsCompiler() { return 0; }
+ virtual TranslatorHLSL* getAsTranslatorHLSL() { return 0; }
protected:
// Memory allocator. Allocates and tracks memory required by the compiler.
@@ -59,7 +63,7 @@ public:
bool Init(const ShBuiltInResources& resources);
bool compile(const char* const shaderStrings[],
- const int numStrings,
+ size_t numStrings,
int compileOptions);
// Get results of the last compilation.
@@ -68,6 +72,10 @@ public:
const TVariableInfoList& getUniforms() const { return uniforms; }
int getMappedNameMaxLength() const;
+ ShHashFunction64 getHashFunction() const { return hashFunction; }
+ NameMap& getNameMap() { return nameMap; }
+ TSymbolTable& getSymbolTable() { return symbolTable; }
+
protected:
ShShaderType getShaderType() const { return shaderType; }
ShShaderSpec getShaderSpec() const { return shaderSpec; }
@@ -100,7 +108,11 @@ protected:
bool enforceFragmentShaderTimingRestrictions(const TDependencyGraph& graph);
// Get built-in extensions with default behavior.
const TExtensionBehavior& getExtensionBehavior() const;
+ // Get the resources set by InitBuiltInSymbolTable
+ const ShBuiltInResources& getResources() const;
+ const ArrayBoundsClamper& getArrayBoundsClamper() const;
+ ShArrayIndexClampingStrategy getArrayIndexClampingStrategy() const;
const BuiltInFunctionEmulator& getBuiltInFunctionEmulator() const;
private:
@@ -109,12 +121,17 @@ private:
int maxUniformVectors;
+ ShBuiltInResources compileResources;
+
// Built-in symbol table for the given language, spec, and resources.
// It is preserved from compile-to-compile.
TSymbolTable symbolTable;
// Built-in extensions with default behavior.
TExtensionBehavior extensionBehavior;
+ bool fragmentPrecisionHigh;
+ ArrayBoundsClamper arrayBoundsClamper;
+ ShArrayIndexClampingStrategy clampingStrategy;
BuiltInFunctionEmulator builtInFunctionEmulator;
// Results of compilation.
@@ -124,6 +141,10 @@ private:
// Cached copy of the ref-counted singleton.
LongNameMap* longNameMap;
+
+ // name hashing.
+ ShHashFunction64 hashFunction;
+ NameMap nameMap;
};
//
diff --git a/src/3rdparty/angle/src/compiler/ShaderLang.cpp b/src/3rdparty/angle/src/compiler/ShaderLang.cpp
index 56f5c7f2ec..92f39311c2 100644
--- a/src/3rdparty/angle/src/compiler/ShaderLang.cpp
+++ b/src/3rdparty/angle/src/compiler/ShaderLang.cpp
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2011 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -14,6 +14,7 @@
#include "compiler/InitializeDll.h"
#include "compiler/preprocessor/length_limits.h"
#include "compiler/ShHandle.h"
+#include "compiler/TranslatorHLSL.h"
//
// This is the platform independent interface between an OGL driver
@@ -21,18 +22,18 @@
//
static bool checkActiveUniformAndAttribMaxLengths(const ShHandle handle,
- int expectedValue)
+ size_t expectedValue)
{
- int activeUniformLimit = 0;
+ size_t activeUniformLimit = 0;
ShGetInfo(handle, SH_ACTIVE_UNIFORM_MAX_LENGTH, &activeUniformLimit);
- int activeAttribLimit = 0;
+ size_t activeAttribLimit = 0;
ShGetInfo(handle, SH_ACTIVE_ATTRIBUTE_MAX_LENGTH, &activeAttribLimit);
return (expectedValue == activeUniformLimit && expectedValue == activeAttribLimit);
}
-static bool checkMappedNameMaxLength(const ShHandle handle, int expectedValue)
+static bool checkMappedNameMaxLength(const ShHandle handle, size_t expectedValue)
{
- int mappedNameMaxLength = 0;
+ size_t mappedNameMaxLength = 0;
ShGetInfo(handle, SH_MAPPED_NAME_MAX_LENGTH, &mappedNameMaxLength);
return (expectedValue == mappedNameMaxLength);
}
@@ -40,7 +41,7 @@ static bool checkMappedNameMaxLength(const ShHandle handle, int expectedValue)
static void getVariableInfo(ShShaderInfo varType,
const ShHandle handle,
int index,
- int* length,
+ size_t* length,
int* size,
ShDataType* type,
char* name,
@@ -69,14 +70,14 @@ static void getVariableInfo(ShShaderInfo varType,
// This size must match that queried by
// SH_ACTIVE_UNIFORM_MAX_LENGTH and SH_ACTIVE_ATTRIBUTE_MAX_LENGTH
// in ShGetInfo, below.
- int activeUniformAndAttribLength = 1 + MAX_SYMBOL_NAME_LEN;
+ size_t activeUniformAndAttribLength = 1 + MAX_SYMBOL_NAME_LEN;
ASSERT(checkActiveUniformAndAttribMaxLengths(handle, activeUniformAndAttribLength));
strncpy(name, varInfo.name.c_str(), activeUniformAndAttribLength);
name[activeUniformAndAttribLength - 1] = 0;
if (mappedName) {
// This size must match that queried by
// SH_MAPPED_NAME_MAX_LENGTH in ShGetInfo, below.
- int maxMappedNameLength = 1 + MAX_SYMBOL_NAME_LEN;
+ size_t maxMappedNameLength = 1 + MAX_SYMBOL_NAME_LEN;
ASSERT(checkMappedNameMaxLength(handle, maxMappedNameLength));
strncpy(mappedName, varInfo.mappedName.c_str(), maxMappedNameLength);
mappedName[maxMappedNameLength - 1] = 0;
@@ -125,6 +126,15 @@ void ShInitBuiltInResources(ShBuiltInResources* resources)
resources->OES_standard_derivatives = 0;
resources->OES_EGL_image_external = 0;
resources->ARB_texture_rectangle = 0;
+ resources->EXT_draw_buffers = 0;
+
+ // Disable highp precision in fragment shader by default.
+ resources->FragmentPrecisionHigh = 0;
+
+ // Disable name hashing by default.
+ resources->HashFunction = NULL;
+
+ resources->ArrayIndexClampingStrategy = SH_CLAMP_WITH_CLAMP_INTRINSIC;
}
//
@@ -172,7 +182,7 @@ void ShDestruct(ShHandle handle)
int ShCompile(
const ShHandle handle,
const char* const shaderStrings[],
- const int numStrings,
+ size_t numStrings,
int compileOptions)
{
if (!InitThread())
@@ -190,7 +200,7 @@ int ShCompile(
return success ? 1 : 0;
}
-void ShGetInfo(const ShHandle handle, ShShaderInfo pname, int* params)
+void ShGetInfo(const ShHandle handle, ShShaderInfo pname, size_t* params)
{
if (!handle || !params)
return;
@@ -224,6 +234,22 @@ void ShGetInfo(const ShHandle handle, ShShaderInfo pname, int* params)
// handle array and struct dereferences.
*params = 1 + MAX_SYMBOL_NAME_LEN;
break;
+ case SH_NAME_MAX_LENGTH:
+ *params = 1 + MAX_SYMBOL_NAME_LEN;
+ break;
+ case SH_HASHED_NAME_MAX_LENGTH:
+ if (compiler->getHashFunction() == NULL) {
+ *params = 0;
+ } else {
+ // 64 bits hashing output requires 16 bytes for hex
+ // representation.
+ const char HashedNamePrefix[] = HASHED_NAME_PREFIX;
+ *params = 16 + sizeof(HashedNamePrefix);
+ }
+ break;
+ case SH_HASHED_NAMES_COUNT:
+ *params = compiler->getNameMap().size();
+ break;
default: UNREACHABLE();
}
}
@@ -262,7 +288,7 @@ void ShGetObjectCode(const ShHandle handle, char* objCode)
void ShGetActiveAttrib(const ShHandle handle,
int index,
- int* length,
+ size_t* length,
int* size,
ShDataType* type,
char* name,
@@ -274,7 +300,7 @@ void ShGetActiveAttrib(const ShHandle handle,
void ShGetActiveUniform(const ShHandle handle,
int index,
- int* length,
+ size_t* length,
int* size,
ShDataType* type,
char* name,
@@ -283,3 +309,64 @@ void ShGetActiveUniform(const ShHandle handle,
getVariableInfo(SH_ACTIVE_UNIFORMS,
handle, index, length, size, type, name, mappedName);
}
+
+void ShGetNameHashingEntry(const ShHandle handle,
+ int index,
+ char* name,
+ char* hashedName)
+{
+ if (!handle || !name || !hashedName || index < 0)
+ return;
+
+ TShHandleBase* base = static_cast<TShHandleBase*>(handle);
+ TCompiler* compiler = base->getAsCompiler();
+ if (!compiler) return;
+
+ const NameMap& nameMap = compiler->getNameMap();
+ if (index >= static_cast<int>(nameMap.size()))
+ return;
+
+ NameMap::const_iterator it = nameMap.begin();
+ for (int i = 0; i < index; ++i)
+ ++it;
+
+ size_t len = it->first.length() + 1;
+ size_t max_len = 0;
+ ShGetInfo(handle, SH_NAME_MAX_LENGTH, &max_len);
+ if (len > max_len) {
+ ASSERT(false);
+ len = max_len;
+ }
+ strncpy(name, it->first.c_str(), len);
+ // To be on the safe side in case the source is longer than expected.
+ name[len - 1] = '\0';
+
+ len = it->second.length() + 1;
+ max_len = 0;
+ ShGetInfo(handle, SH_HASHED_NAME_MAX_LENGTH, &max_len);
+ if (len > max_len) {
+ ASSERT(false);
+ len = max_len;
+ }
+ strncpy(hashedName, it->second.c_str(), len);
+ // To be on the safe side in case the source is longer than expected.
+ hashedName[len - 1] = '\0';
+}
+
+void ShGetInfoPointer(const ShHandle handle, ShShaderInfo pname, void** params)
+{
+ if (!handle || !params)
+ return;
+
+ TShHandleBase* base = static_cast<TShHandleBase*>(handle);
+ TranslatorHLSL* translator = base->getAsTranslatorHLSL();
+ if (!translator) return;
+
+ switch(pname)
+ {
+ case SH_ACTIVE_UNIFORMS_ARRAY:
+ *params = (void*)&translator->getUniforms();
+ break;
+ default: UNREACHABLE();
+ }
+}
diff --git a/src/3rdparty/angle/src/compiler/SymbolTable.h b/src/3rdparty/angle/src/compiler/SymbolTable.h
index a89499e4f4..d27aa332b7 100644
--- a/src/3rdparty/angle/src/compiler/SymbolTable.h
+++ b/src/3rdparty/angle/src/compiler/SymbolTable.h
@@ -169,8 +169,8 @@ public:
void setDefined() { defined = true; }
bool isDefined() { return defined; }
- int getParamCount() const { return static_cast<int>(parameters.size()); }
- const TParameter& getParam(int i) const { return parameters[i]; }
+ size_t getParamCount() const { return parameters.size(); }
+ const TParameter& getParam(size_t i) const { return parameters[i]; }
virtual void dump(TInfoSink &infoSink) const;
TFunction(const TFunction&, TStructureMap& remapper);
@@ -323,10 +323,16 @@ public:
void dump(TInfoSink &infoSink) const;
void copyTable(const TSymbolTable& copyOf);
- void setDefaultPrecision( TBasicType type, TPrecision prec ){
- if( type != EbtFloat && type != EbtInt ) return; // Only set default precision for int/float
+ bool setDefaultPrecision( const TPublicType& type, TPrecision prec ){
+ if (IsSampler(type.type))
+ return true; // Skip sampler types for the time being
+ if (type.type != EbtFloat && type.type != EbtInt)
+ return false; // Only set default precision for int/float
+ if (type.size != 1 || type.matrix || type.array)
+ return false; // Not allowed to set for aggregate types
int indexOfLastElement = static_cast<int>(precisionStack.size()) - 1;
- precisionStack[indexOfLastElement][type] = prec; // Uses map operator [], overwrites the current value
+ precisionStack[indexOfLastElement][type.type] = prec; // Uses map operator [], overwrites the current value
+ return true;
}
// Searches down the precisionStack for a precision qualifier for the specified TBasicType
diff --git a/src/3rdparty/angle/src/compiler/TranslatorESSL.cpp b/src/3rdparty/angle/src/compiler/TranslatorESSL.cpp
index e3a2c2a802..2900f8a8ed 100644
--- a/src/3rdparty/angle/src/compiler/TranslatorESSL.cpp
+++ b/src/3rdparty/angle/src/compiler/TranslatorESSL.cpp
@@ -22,8 +22,11 @@ void TranslatorESSL::translate(TIntermNode* root) {
getBuiltInFunctionEmulator().OutputEmulatedFunctionDefinition(
sink, getShaderType() == SH_FRAGMENT_SHADER);
+ // Write array bounds clamping emulation if needed.
+ getArrayBoundsClamper().OutputClampingFunctionDefinition(sink);
+
// Write translated shader.
- TOutputESSL outputESSL(sink);
+ TOutputESSL outputESSL(sink, getArrayIndexClampingStrategy(), getHashFunction(), getNameMap(), getSymbolTable());
root->traverse(&outputESSL);
}
diff --git a/src/3rdparty/angle/src/compiler/TranslatorGLSL.cpp b/src/3rdparty/angle/src/compiler/TranslatorGLSL.cpp
index bb07a1eb4e..7ca4341dcd 100644
--- a/src/3rdparty/angle/src/compiler/TranslatorGLSL.cpp
+++ b/src/3rdparty/angle/src/compiler/TranslatorGLSL.cpp
@@ -35,7 +35,10 @@ void TranslatorGLSL::translate(TIntermNode* root) {
getBuiltInFunctionEmulator().OutputEmulatedFunctionDefinition(
sink, false);
+ // Write array bounds clamping emulation if needed.
+ getArrayBoundsClamper().OutputClampingFunctionDefinition(sink);
+
// Write translated shader.
- TOutputGLSL outputGLSL(sink);
+ TOutputGLSL outputGLSL(sink, getArrayIndexClampingStrategy(), getHashFunction(), getNameMap(), getSymbolTable());
root->traverse(&outputGLSL);
}
diff --git a/src/3rdparty/angle/src/compiler/TranslatorHLSL.cpp b/src/3rdparty/angle/src/compiler/TranslatorHLSL.cpp
index f41decd48c..37408a07c4 100644
--- a/src/3rdparty/angle/src/compiler/TranslatorHLSL.cpp
+++ b/src/3rdparty/angle/src/compiler/TranslatorHLSL.cpp
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -9,15 +9,16 @@
#include "compiler/InitializeParseContext.h"
#include "compiler/OutputHLSL.h"
-TranslatorHLSL::TranslatorHLSL(ShShaderType type, ShShaderSpec spec)
- : TCompiler(type, spec)
+TranslatorHLSL::TranslatorHLSL(ShShaderType type, ShShaderSpec spec, ShShaderOutput output)
+ : TCompiler(type, spec), mOutputType(output)
{
}
void TranslatorHLSL::translate(TIntermNode *root)
{
TParseContext& parseContext = *GetGlobalParseContext();
- sh::OutputHLSL outputHLSL(parseContext);
+ sh::OutputHLSL outputHLSL(parseContext, getResources(), mOutputType);
outputHLSL.output();
+ mActiveUniforms = outputHLSL.getUniforms();
}
diff --git a/src/3rdparty/angle/src/compiler/TranslatorHLSL.h b/src/3rdparty/angle/src/compiler/TranslatorHLSL.h
index c3f672ba91..9550e15e8e 100644
--- a/src/3rdparty/angle/src/compiler/TranslatorHLSL.h
+++ b/src/3rdparty/angle/src/compiler/TranslatorHLSL.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -8,13 +8,20 @@
#define COMPILER_TRANSLATORHLSL_H_
#include "compiler/ShHandle.h"
+#include "compiler/Uniform.h"
class TranslatorHLSL : public TCompiler {
public:
- TranslatorHLSL(ShShaderType type, ShShaderSpec spec);
+ TranslatorHLSL(ShShaderType type, ShShaderSpec spec, ShShaderOutput output);
+
+ virtual TranslatorHLSL *getAsTranslatorHLSL() { return this; }
+ const sh::ActiveUniforms &getUniforms() { return mActiveUniforms; }
protected:
virtual void translate(TIntermNode* root);
+
+ sh::ActiveUniforms mActiveUniforms;
+ ShShaderOutput mOutputType;
};
#endif // COMPILER_TRANSLATORHLSL_H_
diff --git a/src/3rdparty/angle/src/compiler/Types.h b/src/3rdparty/angle/src/compiler/Types.h
index d4576673b1..854bb44c07 100644
--- a/src/3rdparty/angle/src/compiler/Types.h
+++ b/src/3rdparty/angle/src/compiler/Types.h
@@ -136,6 +136,43 @@ public:
return totalSize;
}
+ int elementRegisterCount() const
+ {
+ TTypeList *structure = getStruct();
+
+ if (structure)
+ {
+ int registerCount = 0;
+
+ for (size_t i = 0; i < structure->size(); i++)
+ {
+ registerCount += (*structure)[i].type->totalRegisterCount();
+ }
+
+ return registerCount;
+ }
+ else if (isMatrix())
+ {
+ return getNominalSize();
+ }
+ else
+ {
+ return 1;
+ }
+ }
+
+ int totalRegisterCount() const
+ {
+ if (array)
+ {
+ return arraySize * elementRegisterCount();
+ }
+ else
+ {
+ return elementRegisterCount();
+ }
+ }
+
bool isMatrix() const { return matrix ? true : false; }
void setMatrix(bool m) { matrix = m; }
diff --git a/src/3rdparty/angle/src/compiler/UnfoldShortCircuit.cpp b/src/3rdparty/angle/src/compiler/UnfoldShortCircuit.cpp
index 1782ebc90c..47f0afca6a 100644
--- a/src/3rdparty/angle/src/compiler/UnfoldShortCircuit.cpp
+++ b/src/3rdparty/angle/src/compiler/UnfoldShortCircuit.cpp
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -95,9 +95,9 @@ bool UnfoldShortCircuit::visitBinary(Visit visit, TIntermBinary *node)
mTemporaryIndex = i + 1;
}
return false;
+ default:
+ return true;
}
-
- return true;
}
bool UnfoldShortCircuit::visitSelection(Visit visit, TIntermSelection *node)
@@ -111,6 +111,8 @@ bool UnfoldShortCircuit::visitSelection(Visit visit, TIntermSelection *node)
out << mOutputHLSL->typeString(node->getType()) << " s" << i << ";\n";
+ out << "{\n";
+
mTemporaryIndex = i + 1;
node->getCondition()->traverse(this);
out << "if(";
@@ -135,6 +137,8 @@ bool UnfoldShortCircuit::visitSelection(Visit visit, TIntermSelection *node)
out << ";\n"
"}\n";
+ out << "}\n";
+
mTemporaryIndex = i + 1;
}
diff --git a/src/3rdparty/angle/src/compiler/Uniform.cpp b/src/3rdparty/angle/src/compiler/Uniform.cpp
new file mode 100644
index 0000000000..f367db2be8
--- /dev/null
+++ b/src/3rdparty/angle/src/compiler/Uniform.cpp
@@ -0,0 +1,21 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+#include "compiler/Uniform.h"
+
+namespace sh
+{
+
+Uniform::Uniform(GLenum type, GLenum precision, const char *name, int arraySize, int registerIndex)
+{
+ this->type = type;
+ this->precision = precision;
+ this->name = name;
+ this->arraySize = arraySize;
+ this->registerIndex = registerIndex;
+}
+
+}
diff --git a/src/3rdparty/angle/src/compiler/Uniform.h b/src/3rdparty/angle/src/compiler/Uniform.h
new file mode 100644
index 0000000000..4c53ffa7d2
--- /dev/null
+++ b/src/3rdparty/angle/src/compiler/Uniform.h
@@ -0,0 +1,35 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+#ifndef COMPILER_UNIFORM_H_
+#define COMPILER_UNIFORM_H_
+
+#include <string>
+#include <vector>
+
+#define GL_APICALL
+#include <GLES2/gl2.h>
+
+namespace sh
+{
+
+struct Uniform
+{
+ Uniform(GLenum type, GLenum precision, const char *name, int arraySize, int registerIndex);
+
+ GLenum type;
+ GLenum precision;
+ std::string name;
+ unsigned int arraySize;
+
+ int registerIndex;
+};
+
+typedef std::vector<Uniform> ActiveUniforms;
+
+}
+
+#endif // COMPILER_UNIFORM_H_
diff --git a/src/3rdparty/angle/src/compiler/ValidateLimitations.cpp b/src/3rdparty/angle/src/compiler/ValidateLimitations.cpp
index d69ec6bbaa..a5562d09a4 100644
--- a/src/3rdparty/angle/src/compiler/ValidateLimitations.cpp
+++ b/src/3rdparty/angle/src/compiler/ValidateLimitations.cpp
@@ -421,7 +421,7 @@ bool ValidateLimitations::validateFunctionCall(TIntermAggregate* node)
return true;
// List of param indices for which loop indices are used as argument.
- typedef std::vector<int> ParamIndex;
+ typedef std::vector<size_t> ParamIndex;
ParamIndex pIndex;
TIntermSequence& params = node->getSequence();
for (TIntermSequence::size_type i = 0; i < params.size(); ++i) {
diff --git a/src/3rdparty/angle/src/compiler/VariableInfo.cpp b/src/3rdparty/angle/src/compiler/VariableInfo.cpp
index 3ff283627b..eb6bea9b0f 100644
--- a/src/3rdparty/angle/src/compiler/VariableInfo.cpp
+++ b/src/3rdparty/angle/src/compiler/VariableInfo.cpp
@@ -77,23 +77,25 @@ static void getBuiltInVariableInfo(const TType& type,
static void getUserDefinedVariableInfo(const TType& type,
const TString& name,
const TString& mappedName,
- TVariableInfoList& infoList);
+ TVariableInfoList& infoList,
+ ShHashFunction64 hashFunction);
// Returns info for an attribute or uniform.
static void getVariableInfo(const TType& type,
const TString& name,
const TString& mappedName,
- TVariableInfoList& infoList)
+ TVariableInfoList& infoList,
+ ShHashFunction64 hashFunction)
{
if (type.getBasicType() == EbtStruct) {
if (type.isArray()) {
for (int i = 0; i < type.getArraySize(); ++i) {
TString lname = name + arrayBrackets(i);
TString lmappedName = mappedName + arrayBrackets(i);
- getUserDefinedVariableInfo(type, lname, lmappedName, infoList);
+ getUserDefinedVariableInfo(type, lname, lmappedName, infoList, hashFunction);
}
} else {
- getUserDefinedVariableInfo(type, name, mappedName, infoList);
+ getUserDefinedVariableInfo(type, name, mappedName, infoList, hashFunction);
}
} else {
getBuiltInVariableInfo(type, name, mappedName, infoList);
@@ -124,7 +126,8 @@ void getBuiltInVariableInfo(const TType& type,
void getUserDefinedVariableInfo(const TType& type,
const TString& name,
const TString& mappedName,
- TVariableInfoList& infoList)
+ TVariableInfoList& infoList,
+ ShHashFunction64 hashFunction)
{
ASSERT(type.getBasicType() == EbtStruct);
@@ -133,8 +136,9 @@ void getUserDefinedVariableInfo(const TType& type,
const TType* fieldType = (*structure)[i].type;
getVariableInfo(*fieldType,
name + "." + fieldType->getFieldName(),
- mappedName + "." + fieldType->getFieldName(),
- infoList);
+ mappedName + "." + TIntermTraverser::hash(fieldType->getFieldName(), hashFunction),
+ infoList,
+ hashFunction);
}
}
@@ -149,9 +153,11 @@ TVariableInfo::TVariableInfo(ShDataType type, int size)
}
CollectAttribsUniforms::CollectAttribsUniforms(TVariableInfoList& attribs,
- TVariableInfoList& uniforms)
+ TVariableInfoList& uniforms,
+ ShHashFunction64 hashFunction)
: mAttribs(attribs),
- mUniforms(uniforms)
+ mUniforms(uniforms),
+ mHashFunction(hashFunction)
{
}
@@ -206,10 +212,16 @@ bool CollectAttribsUniforms::visitAggregate(Visit, TIntermAggregate* node)
// cannot be initialized in a shader, we must have only
// TIntermSymbol nodes in the sequence.
ASSERT(variable != NULL);
+ TString processedSymbol;
+ if (mHashFunction == NULL)
+ processedSymbol = variable->getSymbol();
+ else
+ processedSymbol = TIntermTraverser::hash(variable->getOriginalSymbol(), mHashFunction);
getVariableInfo(variable->getType(),
variable->getOriginalSymbol(),
- variable->getSymbol(),
- infoList);
+ processedSymbol,
+ infoList,
+ mHashFunction);
}
}
break;
diff --git a/src/3rdparty/angle/src/compiler/VariableInfo.h b/src/3rdparty/angle/src/compiler/VariableInfo.h
index fdcc08f5b5..4130a589f5 100644
--- a/src/3rdparty/angle/src/compiler/VariableInfo.h
+++ b/src/3rdparty/angle/src/compiler/VariableInfo.h
@@ -27,7 +27,8 @@ typedef std::vector<TVariableInfo> TVariableInfoList;
class CollectAttribsUniforms : public TIntermTraverser {
public:
CollectAttribsUniforms(TVariableInfoList& attribs,
- TVariableInfoList& uniforms);
+ TVariableInfoList& uniforms,
+ ShHashFunction64 hashFunction);
virtual void visitSymbol(TIntermSymbol*);
virtual void visitConstantUnion(TIntermConstantUnion*);
@@ -41,6 +42,8 @@ public:
private:
TVariableInfoList& mAttribs;
TVariableInfoList& mUniforms;
+
+ ShHashFunction64 mHashFunction;
};
#endif // COMPILER_VARIABLE_INFO_H_
diff --git a/src/3rdparty/angle/src/compiler/VariablePacker.cpp b/src/3rdparty/angle/src/compiler/VariablePacker.cpp
index 2f0c4bc2a2..8957287763 100644
--- a/src/3rdparty/angle/src/compiler/VariablePacker.cpp
+++ b/src/3rdparty/angle/src/compiler/VariablePacker.cpp
@@ -85,7 +85,7 @@ int VariablePacker::GetNumRows(ShDataType type)
case SH_FLOAT_MAT3:
return 3;
case SH_FLOAT_MAT2:
- return 1;
+ return 2;
case SH_FLOAT_VEC4:
case SH_INT_VEC4:
case SH_BOOL_VEC4:
diff --git a/src/3rdparty/angle/src/compiler/glslang.h b/src/3rdparty/angle/src/compiler/glslang.h
index 3a45daf3a4..f221199093 100644
--- a/src/3rdparty/angle/src/compiler/glslang.h
+++ b/src/3rdparty/angle/src/compiler/glslang.h
@@ -8,7 +8,7 @@ struct TParseContext;
extern int glslang_initialize(TParseContext* context);
extern int glslang_finalize(TParseContext* context);
-extern int glslang_scan(int count,
+extern int glslang_scan(size_t count,
const char* const string[],
const int length[],
TParseContext* context);
diff --git a/src/3rdparty/angle/src/compiler/glslang.l b/src/3rdparty/angle/src/compiler/glslang.l
index e0483e2ea9..140a9aeb2d 100644
--- a/src/3rdparty/angle/src/compiler/glslang.l
+++ b/src/3rdparty/angle/src/compiler/glslang.l
@@ -38,7 +38,7 @@ WHICH GENERATES THE GLSL ES LEXER (glslang_lex.cpp).
%{
#include "compiler/glslang.h"
#include "compiler/ParseHelper.h"
-#include "compiler/preprocessor/new/Token.h"
+#include "compiler/preprocessor/Token.h"
#include "compiler/util.h"
#include "glslang_tab.h"
@@ -51,7 +51,7 @@ WHICH GENERATES THE GLSL ES LEXER (glslang_lex.cpp).
#define YY_INPUT(buf, result, max_size) \
result = string_input(buf, max_size, yyscanner);
-static int string_input(char* buf, int max_size, yyscan_t yyscanner);
+static yy_size_t string_input(char* buf, yy_size_t max_size, yyscan_t yyscanner);
static int check_type(yyscan_t yyscanner);
static int reserved_word(yyscan_t yyscanner);
%}
@@ -203,10 +203,10 @@ O [0-7]
return check_type(yyscanner);
}
-0[xX]{H}+ { yylval->lex.i = strtol(yytext, 0, 0); return(INTCONSTANT); }
-0{O}+ { yylval->lex.i = strtol(yytext, 0, 0); return(INTCONSTANT); }
+0[xX]{H}+ { yylval->lex.i = static_cast<int>(strtol(yytext, 0, 0)); return(INTCONSTANT); }
+0{O}+ { yylval->lex.i = static_cast<int>(strtol(yytext, 0, 0)); return(INTCONSTANT); }
0{D}+ { context->error(yylineno, "Invalid Octal number.", yytext); context->recover(); return 0;}
-{D}+ { yylval->lex.i = strtol(yytext, 0, 0); return(INTCONSTANT); }
+{D}+ { yylval->lex.i = static_cast<int>(strtol(yytext, 0, 0)); return(INTCONSTANT); }
{D}+{E} { yylval->lex.f = static_cast<float>(atof_dot(yytext)); return(FLOATCONSTANT); }
{D}+"."{D}*({E})? { yylval->lex.f = static_cast<float>(atof_dot(yytext)); return(FLOATCONSTANT); }
@@ -272,146 +272,13 @@ O [0-7]
%%
-// Old preprocessor interface.
-extern "C" {
-#include "compiler/preprocessor/preprocess.h"
-
-extern int InitPreprocessor();
-extern int FinalizePreprocessor();
-extern void PredefineIntMacro(const char *name, int value);
-
-#define SETUP_CONTEXT(pp) \
- TParseContext* context = (TParseContext*) pp->pC; \
- struct yyguts_t* yyg = (struct yyguts_t*) context->scanner;
-
-// Preprocessor callbacks.
-void CPPDebugLogMsg(const char *msg)
-{
- SETUP_CONTEXT(cpp);
- context->trace(msg);
-}
-
-void CPPWarningToInfoLog(const char *msg)
-{
- SETUP_CONTEXT(cpp);
- context->warning(yylineno, msg, "");
-}
-
-void CPPShInfoLogMsg(const char *msg)
-{
- SETUP_CONTEXT(cpp);
- context->error(yylineno, msg, "");
- context->recover();
-}
-
-void CPPErrorToInfoLog(const char *msg)
-{
- SETUP_CONTEXT(cpp);
- context->error(yylineno, msg, "");
- context->recover();
-}
-
-void SetLineNumber(int line)
-{
- SETUP_CONTEXT(cpp);
- int string = 0;
- DecodeSourceLoc(yylineno, &string, NULL);
- yylineno = EncodeSourceLoc(string, line);
-}
-
-void SetStringNumber(int string)
-{
- SETUP_CONTEXT(cpp);
- int line = 0;
- DecodeSourceLoc(yylineno, NULL, &line);
- yylineno = EncodeSourceLoc(string, line);
-}
-
-int GetStringNumber()
-{
- SETUP_CONTEXT(cpp);
- int string = 0;
- DecodeSourceLoc(yylineno, &string, NULL);
- return string;
-}
-
-int GetLineNumber()
-{
- SETUP_CONTEXT(cpp);
- int line = 0;
- DecodeSourceLoc(yylineno, NULL, &line);
- return line;
-}
-
-void IncLineNumber()
-{
- SETUP_CONTEXT(cpp);
- int string = 0, line = 0;
- DecodeSourceLoc(yylineno, &string, &line);
- yylineno = EncodeSourceLoc(string, ++line);
-}
-
-void DecLineNumber()
-{
- SETUP_CONTEXT(cpp);
- int string = 0, line = 0;
- DecodeSourceLoc(yylineno, &string, &line);
- yylineno = EncodeSourceLoc(string, --line);
-}
-
-void HandlePragma(const char **tokens, int numTokens)
-{
- SETUP_CONTEXT(cpp);
-
- if (numTokens != 4) return;
- if (strcmp(tokens[1], "(") != 0) return;
- if (strcmp(tokens[3], ")") != 0) return;
-
- context->handlePragmaDirective(yylineno, tokens[0], tokens[2]);
-}
-
-void StoreStr(const char *string)
-{
- SETUP_CONTEXT(cpp);
- TString strSrc;
- strSrc = TString(string);
-
- context->HashErrMsg = context->HashErrMsg + " " + strSrc;
-}
-
-const char* GetStrfromTStr(void)
-{
- SETUP_CONTEXT(cpp);
- cpp->ErrMsg = context->HashErrMsg.c_str();
- return cpp->ErrMsg;
-}
-
-void ResetTString(void)
-{
- SETUP_CONTEXT(cpp);
- context->HashErrMsg = "";
-}
-
-void updateExtensionBehavior(const char* extName, const char* behavior)
-{
- SETUP_CONTEXT(cpp);
- context->handleExtensionDirective(yylineno, extName, behavior);
-}
-} // extern "C"
-
-int string_input(char* buf, int max_size, yyscan_t yyscanner) {
- int len = 0;
-
-#if ANGLE_USE_NEW_PREPROCESSOR
+yy_size_t string_input(char* buf, yy_size_t max_size, yyscan_t yyscanner) {
pp::Token token;
yyget_extra(yyscanner)->preprocessor.lex(&token);
- len = token.type == pp::Token::LAST ? 0 : token.text.size();
- if ((len > 0) && (len < max_size))
+ yy_size_t len = token.type == pp::Token::LAST ? 0 : token.text.size();
+ if (len < max_size)
memcpy(buf, token.text.c_str(), len);
yyset_lineno(EncodeSourceLoc(token.location.file, token.location.line), yyscanner);
-#else
- len = yylex_CPP(buf, max_size);
-#endif // ANGLE_USE_NEW_PREPROCESSOR
if (len >= max_size)
YY_FATAL_ERROR("Input buffer overflow");
@@ -471,41 +338,28 @@ int glslang_finalize(TParseContext* context) {
context->scanner = NULL;
yylex_destroy(scanner);
-#if !ANGLE_USE_NEW_PREPROCESSOR
- FinalizePreprocessor();
-#endif
return 0;
}
-int glslang_scan(int count, const char* const string[], const int length[],
+int glslang_scan(size_t count, const char* const string[], const int length[],
TParseContext* context) {
yyrestart(NULL, context->scanner);
yyset_lineno(EncodeSourceLoc(0, 1), context->scanner);
context->AfterEOF = false;
// Initialize preprocessor.
-#if ANGLE_USE_NEW_PREPROCESSOR
if (!context->preprocessor.init(count, string, length))
return 1;
-#else
- if (InitPreprocessor())
- return 1;
- cpp->pC = context;
- cpp->pastFirstStatement = 0;
- if (InitScannerInput(cpp, count, string, length))
- return 1;
-#endif // ANGLE_USE_NEW_PREPROCESSOR
// Define extension macros.
const TExtensionBehavior& extBehavior = context->extensionBehavior();
for (TExtensionBehavior::const_iterator iter = extBehavior.begin();
iter != extBehavior.end(); ++iter) {
-#if ANGLE_USE_NEW_PREPROCESSOR
context->preprocessor.predefineMacro(iter->first.c_str(), 1);
-#else
- PredefineIntMacro(iter->first.c_str(), 1);
-#endif
}
+ if (context->fragmentPrecisionHigh)
+ context->preprocessor.predefineMacro("GL_FRAGMENT_PRECISION_HIGH", 1);
+
return 0;
}
diff --git a/src/3rdparty/angle/src/compiler/glslang.y b/src/3rdparty/angle/src/compiler/glslang.y
index 39c9cee26e..8dbcee32ef 100644
--- a/src/3rdparty/angle/src/compiler/glslang.y
+++ b/src/3rdparty/angle/src/compiler/glslang.y
@@ -1,6 +1,6 @@
/*
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -38,6 +38,9 @@ WHICH GENERATES THE GLSL ES PARSER (glslang_tab.cpp AND glslang_tab.h).
#include "compiler/ParseHelper.h"
#include "GLSLANG/ShaderLang.h"
+#define YYENABLE_NLS 0
+#define YYLTYPE_IS_TRIVIAL 1
+
#define YYLEX_PARAM context->scanner
%}
@@ -242,36 +245,36 @@ postfix_expression
}
if ($1->getType().getQualifier() == EvqConst && $3->getQualifier() == EvqConst) {
if ($1->isArray()) { // constant folding for arrays
- $$ = context->addConstArrayNode($3->getAsConstantUnion()->getUnionArrayPointer()->getIConst(), $1, $2.line);
+ $$ = context->addConstArrayNode($3->getAsConstantUnion()->getIConst(0), $1, $2.line);
} else if ($1->isVector()) { // constant folding for vectors
TVectorFields fields;
fields.num = 1;
- fields.offsets[0] = $3->getAsConstantUnion()->getUnionArrayPointer()->getIConst(); // need to do it this way because v.xy sends fields integer array
+ fields.offsets[0] = $3->getAsConstantUnion()->getIConst(0); // need to do it this way because v.xy sends fields integer array
$$ = context->addConstVectorNode(fields, $1, $2.line);
} else if ($1->isMatrix()) { // constant folding for matrices
- $$ = context->addConstMatrixNode($3->getAsConstantUnion()->getUnionArrayPointer()->getIConst(), $1, $2.line);
+ $$ = context->addConstMatrixNode($3->getAsConstantUnion()->getIConst(0), $1, $2.line);
}
} else {
if ($3->getQualifier() == EvqConst) {
- if (($1->isVector() || $1->isMatrix()) && $1->getType().getNominalSize() <= $3->getAsConstantUnion()->getUnionArrayPointer()->getIConst() && !$1->isArray() ) {
+ if (($1->isVector() || $1->isMatrix()) && $1->getType().getNominalSize() <= $3->getAsConstantUnion()->getIConst(0) && !$1->isArray() ) {
std::stringstream extraInfoStream;
- extraInfoStream << "field selection out of range '" << $3->getAsConstantUnion()->getUnionArrayPointer()->getIConst() << "'";
+ extraInfoStream << "field selection out of range '" << $3->getAsConstantUnion()->getIConst(0) << "'";
std::string extraInfo = extraInfoStream.str();
context->error($2.line, "", "[", extraInfo.c_str());
context->recover();
} else {
if ($1->isArray()) {
if ($1->getType().getArraySize() == 0) {
- if ($1->getType().getMaxArraySize() <= $3->getAsConstantUnion()->getUnionArrayPointer()->getIConst()) {
- if (context->arraySetMaxSize($1->getAsSymbolNode(), $1->getTypePointer(), $3->getAsConstantUnion()->getUnionArrayPointer()->getIConst(), true, $2.line))
+ if ($1->getType().getMaxArraySize() <= $3->getAsConstantUnion()->getIConst(0)) {
+ if (context->arraySetMaxSize($1->getAsSymbolNode(), $1->getTypePointer(), $3->getAsConstantUnion()->getIConst(0), true, $2.line))
context->recover();
} else {
if (context->arraySetMaxSize($1->getAsSymbolNode(), $1->getTypePointer(), 0, false, $2.line))
context->recover();
}
- } else if ( $3->getAsConstantUnion()->getUnionArrayPointer()->getIConst() >= $1->getType().getArraySize()) {
+ } else if ( $3->getAsConstantUnion()->getIConst(0) >= $1->getType().getArraySize()) {
std::stringstream extraInfoStream;
- extraInfoStream << "array index out of range '" << $3->getAsConstantUnion()->getUnionArrayPointer()->getIConst() << "'";
+ extraInfoStream << "array index out of range '" << $3->getAsConstantUnion()->getIConst(0) << "'";
std::string extraInfo = extraInfoStream.str();
context->error($2.line, "", "[", extraInfo.c_str());
context->recover();
@@ -521,7 +524,7 @@ function_call
$$->getAsAggregate()->setName(fnCandidate->getMangledName());
TQualifier qual;
- for (int i = 0; i < fnCandidate->getParamCount(); ++i) {
+ for (size_t i = 0; i < fnCandidate->getParamCount(); ++i) {
qual = fnCandidate->getParam(i).type->getQualifier();
if (qual == EvqOut || qual == EvqInOut) {
if (context->lValueErrorCheck($$->getLine(), "assign", $$->getAsAggregate()->getSequence()[i]->getAsTyped())) {
@@ -962,7 +965,7 @@ declaration
prototype->setType(function.getReturnType());
prototype->setName(function.getName());
- for (int i = 0; i < function.getParamCount(); i++)
+ for (size_t i = 0; i < function.getParamCount(); i++)
{
const TParameter &param = function.getParam(i);
if (param.name != 0)
@@ -988,7 +991,14 @@ declaration
$$ = $1.intermAggregate;
}
| PRECISION precision_qualifier type_specifier_no_prec SEMICOLON {
- context->symbolTable.setDefaultPrecision( $3.type, $2 );
+ if (($2 == EbpHigh) && (context->shaderType == SH_FRAGMENT_SHADER) && !context->fragmentPrecisionHigh) {
+ context->error($1.line, "precision is not supported in fragment shader", "highp");
+ context->recover();
+ }
+ if (!context->symbolTable.setDefaultPrecision( $3, $2 )) {
+ context->error($1.line, "illegal type argument for default precision qualifier", getBasicString($3.type));
+ context->recover();
+ }
$$ = 0;
}
;
@@ -1009,7 +1019,7 @@ function_prototype
context->error($2.line, "overloaded functions must have the same return type", $1->getReturnType().getBasicString());
context->recover();
}
- for (int i = 0; i < prevDec->getParamCount(); ++i) {
+ for (size_t i = 0; i < prevDec->getParamCount(); ++i) {
if (prevDec->getParam(i).type->getQualifier() != $1->getParam(i).type->getQualifier()) {
context->error($2.line, "overloaded functions must have the same parameter qualifiers", $1->getParam(i).type->getQualifierString());
context->recover();
@@ -2079,7 +2089,7 @@ function_definition
// knows where to find parameters.
//
TIntermAggregate* paramNodes = new TIntermAggregate;
- for (int i = 0; i < function->getParamCount(); i++) {
+ for (size_t i = 0; i < function->getParamCount(); i++) {
const TParameter& param = function->getParam(i);
if (param.name != 0) {
TVariable *variable = new TVariable(param.name, *param.type);
@@ -2139,4 +2149,3 @@ function_definition
int glslang_parse(TParseContext* context) {
return yyparse(context);
}
-
diff --git a/src/3rdparty/angle/src/compiler/intermOut.cpp b/src/3rdparty/angle/src/compiler/intermOut.cpp
index e83c7b72f2..f48a049c63 100644
--- a/src/3rdparty/angle/src/compiler/intermOut.cpp
+++ b/src/3rdparty/angle/src/compiler/intermOut.cpp
@@ -42,7 +42,7 @@ TString TType::getCompleteString() const
if (qualifier != EvqTemporary && qualifier != EvqGlobal)
stream << getQualifierString() << " " << getPrecisionString() << " ";
if (array)
- stream << "array of ";
+ stream << "array[" << getArraySize() << "] of ";
if (matrix)
stream << size << "X" << size << " matrix of ";
else if (size > 1)
diff --git a/src/3rdparty/angle/src/compiler/intermediate.h b/src/3rdparty/angle/src/compiler/intermediate.h
index af78fa00ef..8e76ef921f 100644
--- a/src/3rdparty/angle/src/compiler/intermediate.h
+++ b/src/3rdparty/angle/src/compiler/intermediate.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -16,6 +16,8 @@
#ifndef __INTERMEDIATE_H
#define __INTERMEDIATE_H
+#include "GLSLANG/ShaderLang.h"
+
#include "compiler/Common.h"
#include "compiler/Types.h"
#include "compiler/ConstantUnion.h"
@@ -181,7 +183,7 @@ enum TOperator {
EOpVectorTimesScalarAssign,
EOpMatrixTimesScalarAssign,
EOpMatrixTimesMatrixAssign,
- EOpDivAssign,
+ EOpDivAssign
};
extern const char* getOperatorString(TOperator op);
@@ -257,6 +259,10 @@ public:
const char* getQualifierString() const { return type.getQualifierString(); }
TString getCompleteString() const { return type.getCompleteString(); }
+ int totalRegisterCount() const { return type.totalRegisterCount(); }
+ int elementRegisterCount() const { return type.elementRegisterCount(); }
+ int getArraySize() const { return type.getArraySize(); }
+
protected:
TType type;
};
@@ -267,7 +273,7 @@ protected:
enum TLoopType {
ELoopFor,
ELoopWhile,
- ELoopDoWhile,
+ ELoopDoWhile
};
class TIntermLoop : public TIntermNode {
@@ -356,7 +362,10 @@ public:
TIntermConstantUnion(ConstantUnion *unionPointer, const TType& t) : TIntermTyped(t), unionArrayPointer(unionPointer) { }
ConstantUnion* getUnionArrayPointer() const { return unionArrayPointer; }
- void setUnionArrayPointer(ConstantUnion *c) { unionArrayPointer = c; }
+
+ int getIConst(int index) const { return unionArrayPointer ? unionArrayPointer[index].getIConst() : 0; }
+ float getFConst(int index) const { return unionArrayPointer ? unionArrayPointer[index].getFConst() : 0.0f; }
+ bool getBConst(int index) const { return unionArrayPointer ? unionArrayPointer[index].getBConst() : false; }
virtual TIntermConstantUnion* getAsConstantUnion() { return this; }
virtual void traverse(TIntermTraverser*);
@@ -389,7 +398,7 @@ protected:
//
class TIntermBinary : public TIntermOperator {
public:
- TIntermBinary(TOperator o) : TIntermOperator(o) {}
+ TIntermBinary(TOperator o) : TIntermOperator(o), addIndexClamp(false) {}
virtual TIntermBinary* getAsBinaryNode() { return this; }
virtual void traverse(TIntermTraverser*);
@@ -400,9 +409,15 @@ public:
TIntermTyped* getRight() const { return right; }
bool promote(TInfoSink&);
+ void setAddIndexClamp() { addIndexClamp = true; }
+ bool getAddIndexClamp() { return addIndexClamp; }
+
protected:
TIntermTyped* left;
TIntermTyped* right;
+
+ // If set to true, wrap any EOpIndexIndirect with a clamp to bounds.
+ bool addIndexClamp;
};
//
@@ -545,6 +560,10 @@ public:
void incrementDepth() {depth++;}
void decrementDepth() {depth--;}
+ // Return the original name if hash function pointer is NULL;
+ // otherwise return the hashed name.
+ static TString hash(const TString& name, ShHashFunction64 hashFunction);
+
const bool preVisit;
const bool inVisit;
const bool postVisit;
diff --git a/src/3rdparty/angle/src/compiler/osinclude.h b/src/3rdparty/angle/src/compiler/osinclude.h
index 1d95907b79..d8bb1a797c 100644
--- a/src/3rdparty/angle/src/compiler/osinclude.h
+++ b/src/3rdparty/angle/src/compiler/osinclude.h
@@ -24,9 +24,7 @@
#error Unsupported platform.
#endif
-#if defined(ANGLE_USE_NSPR)
-#include "prthread.h"
-#elif defined(ANGLE_OS_WIN)
+#if defined(ANGLE_OS_WIN)
#define STRICT
#define VC_EXTRALEAN 1
#include <windows.h>
@@ -34,7 +32,7 @@
#include <pthread.h>
#include <semaphore.h>
#include <errno.h>
-#endif // ANGLE_USE_NSPR
+#endif // ANGLE_OS_WIN
#include "compiler/debug.h"
@@ -42,16 +40,13 @@
//
// Thread Local Storage Operations
//
-#if defined(ANGLE_USE_NSPR)
-typedef PRUintn OS_TLSIndex;
-#define OS_INVALID_TLS_INDEX 0xFFFFFFFF
-#elif defined(ANGLE_OS_WIN)
+#if defined(ANGLE_OS_WIN)
typedef DWORD OS_TLSIndex;
#define OS_INVALID_TLS_INDEX (TLS_OUT_OF_INDEXES)
#elif defined(ANGLE_OS_POSIX)
-typedef unsigned int OS_TLSIndex;
-#define OS_INVALID_TLS_INDEX 0xFFFFFFFF
-#endif // ANGLE_USE_NSPR
+typedef pthread_key_t OS_TLSIndex;
+#define OS_INVALID_TLS_INDEX (static_cast<OS_TLSIndex>(-1))
+#endif // ANGLE_OS_WIN
OS_TLSIndex OS_AllocTLSIndex();
bool OS_SetTLSValue(OS_TLSIndex nIndex, void *lpvValue);
@@ -60,9 +55,7 @@ bool OS_FreeTLSIndex(OS_TLSIndex nIndex);
inline void* OS_GetTLSValue(OS_TLSIndex nIndex)
{
ASSERT(nIndex != OS_INVALID_TLS_INDEX);
-#if defined(ANGLE_USE_NSPR)
- return PR_GetThreadPrivate(nIndex);
-#elif defined(ANGLE_OS_WIN)
+#if defined(ANGLE_OS_WIN)
return TlsGetValue(nIndex);
#elif defined(ANGLE_OS_POSIX)
return pthread_getspecific(nIndex);
diff --git a/src/3rdparty/angle/src/compiler/ossource_nspr.cpp b/src/3rdparty/angle/src/compiler/ossource_nspr.cpp
deleted file mode 100644
index f63d81e5d5..0000000000
--- a/src/3rdparty/angle/src/compiler/ossource_nspr.cpp
+++ /dev/null
@@ -1,43 +0,0 @@
-//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-//
-
-//
-// This file contains the nspr specific functions
-//
-#include "compiler/osinclude.h"
-
-//
-// Thread Local Storage Operations
-//
-OS_TLSIndex OS_AllocTLSIndex()
-{
- PRUintn index;
- PRStatus status = PR_NewThreadPrivateIndex(&index, NULL);
-
- if (status) {
- assert(0 && "OS_AllocTLSIndex(): Unable to allocate Thread Local Storage");
- return OS_INVALID_TLS_INDEX;
- }
-
- return index;
-}
-
-bool OS_SetTLSValue(OS_TLSIndex nIndex, void *lpvValue)
-{
- if (nIndex == OS_INVALID_TLS_INDEX) {
- assert(0 && "OS_SetTLSValue(): Invalid TLS Index");
- return false;
- }
-
- return PR_SetThreadPrivate(nIndex, lpvValue) == 0;
-}
-
-bool OS_FreeTLSIndex(OS_TLSIndex nIndex)
-{
- // Can't delete TLS keys with nspr
- return true;
-}
-
diff --git a/src/3rdparty/angle/src/compiler/parseConst.cpp b/src/3rdparty/angle/src/compiler/parseConst.cpp
index 9a8a50c31c..421d31f586 100644
--- a/src/3rdparty/angle/src/compiler/parseConst.cpp
+++ b/src/3rdparty/angle/src/compiler/parseConst.cpp
@@ -151,6 +151,13 @@ bool TConstTraverser::visitSelection(Visit visit, TIntermSelection* node)
void TConstTraverser::visitConstantUnion(TIntermConstantUnion* node)
{
+ if (!node->getUnionArrayPointer())
+ {
+ // The constant was not initialized, this should already have been logged
+ assert(infoSink.info.size() != 0);
+ return;
+ }
+
ConstantUnion* leftUnionArray = unionArray;
int instanceSize = type.getObjectSize();
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Diagnostics.cpp b/src/3rdparty/angle/src/compiler/preprocessor/DiagnosticsBase.cpp
index 3f50dfc98a..3e22e1f1c5 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Diagnostics.cpp
+++ b/src/3rdparty/angle/src/compiler/preprocessor/DiagnosticsBase.cpp
@@ -4,7 +4,7 @@
// found in the LICENSE file.
//
-#include "Diagnostics.h"
+#include "DiagnosticsBase.h"
#include <cassert>
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Diagnostics.h b/src/3rdparty/angle/src/compiler/preprocessor/DiagnosticsBase.h
index 07bc411846..07bc411846 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Diagnostics.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/DiagnosticsBase.h
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/DirectiveHandler.cpp b/src/3rdparty/angle/src/compiler/preprocessor/DirectiveHandlerBase.cpp
index ca91e1c71b..ef35c6ed50 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/DirectiveHandler.cpp
+++ b/src/3rdparty/angle/src/compiler/preprocessor/DirectiveHandlerBase.cpp
@@ -4,7 +4,7 @@
// found in the LICENSE file.
//
-#include "DirectiveHandler.h"
+#include "DirectiveHandlerBase.h"
namespace pp
{
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/DirectiveHandler.h b/src/3rdparty/angle/src/compiler/preprocessor/DirectiveHandlerBase.h
index 2aaeec2818..2aaeec2818 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/DirectiveHandler.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/DirectiveHandlerBase.h
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/DirectiveParser.cpp b/src/3rdparty/angle/src/compiler/preprocessor/DirectiveParser.cpp
index f2e42d06bf..94dfdf513d 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/DirectiveParser.cpp
+++ b/src/3rdparty/angle/src/compiler/preprocessor/DirectiveParser.cpp
@@ -10,8 +10,8 @@
#include <cstdlib>
#include <sstream>
-#include "Diagnostics.h"
-#include "DirectiveHandler.h"
+#include "DiagnosticsBase.h"
+#include "DirectiveHandlerBase.h"
#include "ExpressionParser.h"
#include "MacroExpander.h"
#include "Token.h"
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/DirectiveParser.h b/src/3rdparty/angle/src/compiler/preprocessor/DirectiveParser.h
index 8a7f0072ba..8a7f0072ba 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/DirectiveParser.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/DirectiveParser.h
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/ExpressionParser.h b/src/3rdparty/angle/src/compiler/preprocessor/ExpressionParser.h
index 092d059413..092d059413 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/ExpressionParser.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/ExpressionParser.h
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/ExpressionParser.y b/src/3rdparty/angle/src/compiler/preprocessor/ExpressionParser.y
index 832ad4001e..b6d3143e60 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/ExpressionParser.y
+++ b/src/3rdparty/angle/src/compiler/preprocessor/ExpressionParser.y
@@ -22,7 +22,11 @@ WHICH GENERATES THE GLSL ES preprocessor expression parser.
#if defined(__GNUC__)
// Triggered by the auto-generated pplval variable.
+#if !defined(__clang__) && ((__GNUC__ > 4) || (__GNUC__ == 4 && __GNUC_MINOR__ >= 7))
+#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
+#else
#pragma GCC diagnostic ignored "-Wuninitialized"
+#endif
#elif defined(_MSC_VER)
#pragma warning(disable: 4065 4701)
#endif
@@ -32,7 +36,7 @@ WHICH GENERATES THE GLSL ES preprocessor expression parser.
#include <cassert>
#include <sstream>
-#include "Diagnostics.h"
+#include "DiagnosticsBase.h"
#include "Lexer.h"
#include "Token.h"
@@ -42,6 +46,8 @@ typedef __int64 YYSTYPE;
#include <stdint.h>
typedef intmax_t YYSTYPE;
#endif // _MSC_VER
+#define YYENABLE_NLS 0
+#define YYLTYPE_IS_TRIVIAL 1
#define YYSTYPE_IS_TRIVIAL 1
#define YYSTYPE_IS_DECLARED 1
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Input.cpp b/src/3rdparty/angle/src/compiler/preprocessor/Input.cpp
index c3de95f313..b4d970a97d 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Input.cpp
+++ b/src/3rdparty/angle/src/compiler/preprocessor/Input.cpp
@@ -17,27 +17,26 @@ Input::Input() : mCount(0), mString(0)
{
}
-Input::Input(int count, const char* const string[], const int length[]) :
+Input::Input(size_t count, const char* const string[], const int length[]) :
mCount(count),
mString(string)
{
- assert(mCount >= 0);
mLength.reserve(mCount);
- for (int i = 0; i < mCount; ++i)
+ for (size_t i = 0; i < mCount; ++i)
{
int len = length ? length[i] : -1;
- mLength.push_back(len < 0 ? strlen(mString[i]) : len);
+ mLength.push_back(len < 0 ? std::strlen(mString[i]) : len);
}
}
-int Input::read(char* buf, int maxSize)
+size_t Input::read(char* buf, size_t maxSize)
{
- int nRead = 0;
+ size_t nRead = 0;
while ((nRead < maxSize) && (mReadLoc.sIndex < mCount))
{
- int size = mLength[mReadLoc.sIndex] - mReadLoc.cIndex;
+ size_t size = mLength[mReadLoc.sIndex] - mReadLoc.cIndex;
size = std::min(size, maxSize);
- memcpy(buf + nRead, mString[mReadLoc.sIndex] + mReadLoc.cIndex, size);
+ std::memcpy(buf + nRead, mString[mReadLoc.sIndex] + mReadLoc.cIndex, size);
nRead += size;
mReadLoc.cIndex += size;
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Input.h b/src/3rdparty/angle/src/compiler/preprocessor/Input.h
index dac734b68d..14b7597cb4 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Input.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/Input.h
@@ -7,6 +7,7 @@
#ifndef COMPILER_PREPROCESSOR_INPUT_H_
#define COMPILER_PREPROCESSOR_INPUT_H_
+#include <stddef.h>
#include <vector>
namespace pp
@@ -17,18 +18,18 @@ class Input
{
public:
Input();
- Input(int count, const char* const string[], const int length[]);
+ Input(size_t count, const char* const string[], const int length[]);
- int count() const { return mCount; }
- const char* string(int index) const { return mString[index]; }
- int length(int index) const { return mLength[index]; }
+ size_t count() const { return mCount; }
+ const char* string(size_t index) const { return mString[index]; }
+ size_t length(size_t index) const { return mLength[index]; }
- int read(char* buf, int maxSize);
+ size_t read(char* buf, size_t maxSize);
struct Location
{
- int sIndex; // String index;
- int cIndex; // Char index.
+ size_t sIndex; // String index;
+ size_t cIndex; // Char index.
Location() : sIndex(0), cIndex(0) { }
};
@@ -36,9 +37,9 @@ class Input
private:
// Input.
- int mCount;
+ size_t mCount;
const char* const* mString;
- std::vector<int> mLength;
+ std::vector<size_t> mLength;
Location mReadLoc;
};
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Lexer.cpp b/src/3rdparty/angle/src/compiler/preprocessor/Lexer.cpp
index 7c663ee761..7c663ee761 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Lexer.cpp
+++ b/src/3rdparty/angle/src/compiler/preprocessor/Lexer.cpp
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Lexer.h b/src/3rdparty/angle/src/compiler/preprocessor/Lexer.h
index eb85cea873..eb85cea873 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Lexer.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/Lexer.h
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Macro.cpp b/src/3rdparty/angle/src/compiler/preprocessor/Macro.cpp
index b2e3088e32..b2e3088e32 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Macro.cpp
+++ b/src/3rdparty/angle/src/compiler/preprocessor/Macro.cpp
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Macro.h b/src/3rdparty/angle/src/compiler/preprocessor/Macro.h
index 7ec0149116..7ec0149116 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Macro.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/Macro.h
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/MacroExpander.cpp b/src/3rdparty/angle/src/compiler/preprocessor/MacroExpander.cpp
index 701cec9a4b..1116c516ff 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/MacroExpander.cpp
+++ b/src/3rdparty/angle/src/compiler/preprocessor/MacroExpander.cpp
@@ -9,7 +9,7 @@
#include <algorithm>
#include <sstream>
-#include "Diagnostics.h"
+#include "DiagnosticsBase.h"
#include "Token.h"
namespace pp
@@ -57,7 +57,7 @@ MacroExpander::MacroExpander(Lexer* lexer,
MacroExpander::~MacroExpander()
{
- for (size_t i = 0; i < mContextStack.size(); ++i)
+ for (std::size_t i = 0; i < mContextStack.size(); ++i)
{
delete mContextStack[i];
}
@@ -224,7 +224,7 @@ bool MacroExpander::expandMacro(const Macro& macro,
replaceMacroParams(macro, args, replacements);
}
- for (size_t i = 0; i < replacements->size(); ++i)
+ for (std::size_t i = 0; i < replacements->size(); ++i)
{
Token& repl = replacements->at(i);
if (i == 0)
@@ -311,7 +311,7 @@ bool MacroExpander::collectMacroArgs(const Macro& macro,
// Pre-expand each argument before substitution.
// This step expands each argument individually before they are
// inserted into the macro body.
- for (size_t i = 0; i < args->size(); ++i)
+ for (std::size_t i = 0; i < args->size(); ++i)
{
MacroArg& arg = args->at(i);
TokenLexer lexer(&arg);
@@ -332,7 +332,7 @@ void MacroExpander::replaceMacroParams(const Macro& macro,
const std::vector<MacroArg>& args,
std::vector<Token>* replacements)
{
- for (size_t i = 0; i < macro.replacements.size(); ++i)
+ for (std::size_t i = 0; i < macro.replacements.size(); ++i)
{
const Token& repl = macro.replacements[i];
if (repl.type != Token::IDENTIFIER)
@@ -352,13 +352,13 @@ void MacroExpander::replaceMacroParams(const Macro& macro,
continue;
}
- size_t iArg = std::distance(macro.parameters.begin(), iter);
+ std::size_t iArg = std::distance(macro.parameters.begin(), iter);
const MacroArg& arg = args[iArg];
if (arg.empty())
{
continue;
}
- size_t iRepl = replacements->size();
+ std::size_t iRepl = replacements->size();
replacements->insert(replacements->end(), arg.begin(), arg.end());
// The replacement token inherits padding properties from
// macro replacement token.
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/MacroExpander.h b/src/3rdparty/angle/src/compiler/preprocessor/MacroExpander.h
index 7c5c543871..21b67571f1 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/MacroExpander.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/MacroExpander.h
@@ -53,7 +53,7 @@ class MacroExpander : public Lexer
struct MacroContext
{
const Macro* macro;
- size_t index;
+ std::size_t index;
std::vector<Token> replacements;
MacroContext() : macro(0), index(0) { }
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Preprocessor.cpp b/src/3rdparty/angle/src/compiler/preprocessor/Preprocessor.cpp
index ffa7225a8f..5ffc6420bc 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Preprocessor.cpp
+++ b/src/3rdparty/angle/src/compiler/preprocessor/Preprocessor.cpp
@@ -9,7 +9,7 @@
#include <cassert>
#include <sstream>
-#include "Diagnostics.h"
+#include "DiagnosticsBase.h"
#include "DirectiveParser.h"
#include "Macro.h"
#include "MacroExpander.h"
@@ -48,7 +48,7 @@ Preprocessor::~Preprocessor()
delete mImpl;
}
-bool Preprocessor::init(int count,
+bool Preprocessor::init(size_t count,
const char* const string[],
const int length[])
{
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Preprocessor.h b/src/3rdparty/angle/src/compiler/preprocessor/Preprocessor.h
index 5fe35b27bd..7b70180fc8 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Preprocessor.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/Preprocessor.h
@@ -7,6 +7,8 @@
#ifndef COMPILER_PREPROCESSOR_PREPROCESSOR_H_
#define COMPILER_PREPROCESSOR_PREPROCESSOR_H_
+#include <stddef.h>
+
#include "pp_utils.h"
namespace pp
@@ -32,7 +34,7 @@ class Preprocessor
// Each element in the length array may contain the length of the
// corresponding string or a value less than 0 to indicate that the string
// is null terminated.
- bool init(int count, const char* const string[], const int length[]);
+ bool init(size_t count, const char* const string[], const int length[]);
// Adds a pre-defined macro.
void predefineMacro(const char* name, int value);
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/SourceLocation.h b/src/3rdparty/angle/src/compiler/preprocessor/SourceLocation.h
index 6982613ac7..6982613ac7 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/SourceLocation.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/SourceLocation.h
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Token.cpp b/src/3rdparty/angle/src/compiler/preprocessor/Token.cpp
index 67f50aa32c..67f50aa32c 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Token.cpp
+++ b/src/3rdparty/angle/src/compiler/preprocessor/Token.cpp
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Token.h b/src/3rdparty/angle/src/compiler/preprocessor/Token.h
index 8b553aecb6..8b553aecb6 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Token.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/Token.h
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Tokenizer.h b/src/3rdparty/angle/src/compiler/preprocessor/Tokenizer.h
index a594d2d865..7a6fa87b04 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Tokenizer.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/Tokenizer.h
@@ -32,12 +32,12 @@ class Tokenizer : public Lexer
bool leadingSpace;
bool lineStart;
};
- static const size_t kMaxTokenLength;
+ static const std::size_t kMaxTokenLength;
Tokenizer(Diagnostics* diagnostics);
~Tokenizer();
- bool init(int count, const char* const string[], const int length[]);
+ bool init(size_t count, const char* const string[], const int length[]);
void setFileNumber(int file);
void setLineNumber(int line);
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/Tokenizer.l b/src/3rdparty/angle/src/compiler/preprocessor/Tokenizer.l
index 9762988350..fc81d84f37 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/Tokenizer.l
+++ b/src/3rdparty/angle/src/compiler/preprocessor/Tokenizer.l
@@ -1,6 +1,6 @@
/*
//
-// Copyright (c) 2002-2011 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -14,7 +14,7 @@ IF YOU MODIFY THIS FILE YOU ALSO NEED TO RUN generate_parser.sh.
%top{
//
-// Copyright (c) 2011 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2011-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -25,7 +25,7 @@ IF YOU MODIFY THIS FILE YOU ALSO NEED TO RUN generate_parser.sh.
%{
#include "Tokenizer.h"
-#include "Diagnostics.h"
+#include "DiagnosticsBase.h"
#include "Token.h"
#if defined(__GNUC__)
@@ -229,6 +229,8 @@ FRACTIONAL_CONSTANT ({DIGIT}*"."{DIGIT}+)|({DIGIT}+".")
return '\n';
}
+\\{NEWLINE} { ++yylineno; }
+
. {
yylval->assign(1, yytext[0]);
return pp::Token::PP_OTHER;
@@ -239,13 +241,14 @@ FRACTIONAL_CONSTANT ({DIGIT}*"."{DIGIT}+)|({DIGIT}+".")
// Set the location for EOF token manually.
pp::Input* input = &yyextra->input;
pp::Input::Location* scanLoc = &yyextra->scanLoc;
- int sIndexMax = std::max(0, input->count() - 1);
+ yy_size_t sIndexMax = input->count() ? input->count() - 1 : 0;
if (scanLoc->sIndex != sIndexMax)
{
// We can only reach here if there are empty strings at the
// end of the input.
scanLoc->sIndex = sIndexMax; scanLoc->cIndex = 0;
- yyfileno = sIndexMax; yylineno = 1;
+ // FIXME: this is not 64-bit clean.
+ yyfileno = static_cast<int>(sIndexMax); yylineno = 1;
}
yylloc->file = yyfileno;
yylloc->line = yylineno;
@@ -278,9 +281,8 @@ Tokenizer::~Tokenizer()
destroyScanner();
}
-bool Tokenizer::init(int count, const char* const string[], const int length[])
+bool Tokenizer::init(size_t count, const char* const string[], const int length[])
{
- if (count < 0) return false;
if ((count > 0) && (string == 0)) return false;
mContext.input = Input(count, string, length);
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/atom.c b/src/3rdparty/angle/src/compiler/preprocessor/atom.c
deleted file mode 100644
index 39158d2fa1..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/atom.c
+++ /dev/null
@@ -1,737 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-
-//
-// atom.c
-//
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <string.h>
-
-#include "common/angleutils.h"
-#include "compiler/debug.h"
-#include "compiler/preprocessor/slglobals.h"
-
-#undef malloc
-#undef realloc
-#undef free
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-////////////////////////////////////////// String table: //////////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
-
-static const struct {
- int val;
- const char *str;
-} tokens[] = {
- { CPP_AND_OP, "&&" },
- { CPP_AND_ASSIGN, "&=" },
- { CPP_SUB_ASSIGN, "-=" },
- { CPP_MOD_ASSIGN, "%=" },
- { CPP_ADD_ASSIGN, "+=" },
- { CPP_DIV_ASSIGN, "/=" },
- { CPP_MUL_ASSIGN, "*=" },
- { CPP_RIGHT_BRACKET, ":>" },
- { CPP_EQ_OP, "==" },
- { CPP_XOR_OP, "^^" },
- { CPP_XOR_ASSIGN, "^=" },
- { CPP_FLOATCONSTANT, "<float-const>" },
- { CPP_GE_OP, ">=" },
- { CPP_RIGHT_OP, ">>" },
- { CPP_RIGHT_ASSIGN, ">>=" },
- { CPP_IDENTIFIER, "<ident>" },
- { CPP_INTCONSTANT, "<int-const>" },
- { CPP_LE_OP, "<=" },
- { CPP_LEFT_OP, "<<" },
- { CPP_LEFT_ASSIGN, "<<=" },
- { CPP_LEFT_BRACKET, "<:" },
- { CPP_LEFT_BRACE, "<%" },
- { CPP_DEC_OP, "--" },
- { CPP_RIGHT_BRACE, "%>" },
- { CPP_NE_OP, "!=" },
- { CPP_OR_OP, "||" },
- { CPP_OR_ASSIGN, "|=" },
- { CPP_INC_OP, "++" },
- { CPP_STRCONSTANT, "<string-const>" },
- { CPP_TYPEIDENTIFIER, "<type-ident>" },
-};
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-////////////////////////////////////////// String table: //////////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
-
-#define INIT_STRING_TABLE_SIZE 16384
-
-typedef struct StringTable_Rec {
- char *strings;
- int nextFree;
- int size;
-} StringTable;
-
-/*
- * InitStringTable() - Initialize the string table.
- *
- */
-
-static int InitStringTable(StringTable *stable)
-{
- stable->strings = (char *) malloc(INIT_STRING_TABLE_SIZE);
- if (!stable->strings)
- return 0;
- // Zero-th offset means "empty" so don't use it.
- stable->nextFree = 1;
- stable->size = INIT_STRING_TABLE_SIZE;
- return 1;
-} // InitStringTable
-
-/*
- * FreeStringTable() - Free the string table.
- *
- */
-
-static void FreeStringTable(StringTable *stable)
-{
- if (stable->strings)
- free(stable->strings);
- stable->strings = NULL;
- stable->nextFree = 0;
- stable->size = 0;
-} // FreeStringTable
-
-/*
- * HashString() - Hash a string with the base hash function.
- *
- */
-
-static int HashString(const char *s)
-{
- int hval = 0;
-
- while (*s) {
- hval = (hval*13507 + *s*197) ^ (hval >> 2);
- s++;
- }
- return hval & 0x7fffffff;
-} // HashString
-
-/*
- * HashString2() - Hash a string with the incrimenting hash function.
- *
- */
-
-static int HashString2(const char *s)
-{
- int hval = 0;
-
- while (*s) {
- hval = (hval*729 + *s*37) ^ (hval >> 1);
- s++;
- }
- return hval;
-} // HashString2
-
-/*
- * AddString() - Add a string to a string table. Return it's offset.
- *
- */
-
-static int AddString(StringTable *stable, const char *s)
-{
- int len, loc;
- char *str;
-
- len = (int) strlen(s);
- while (stable->nextFree + len + 1 >= stable->size) {
- assert(stable->size < 1000000);
- str = (char *) malloc(stable->size*2);
- memcpy(str, stable->strings, stable->size);
- free(stable->strings);
- stable->strings = str;
- stable->size = stable->size*2;
- }
- loc = stable->nextFree;
- strcpy(&stable->strings[loc], s);
- stable->nextFree += len + 1;
- return loc;
-} // AddString
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-/////////////////////////////////////////// Hash table: ///////////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
-
-#define INIT_HASH_TABLE_SIZE 2047
-#define HASH_TABLE_MAX_COLLISIONS 3
-
-typedef struct HashEntry_Rec {
- int index; // String table offset of string representation
- int value; // Atom (symbol) value
-} HashEntry;
-
-typedef struct HashTable_Rec {
- HashEntry *entry;
- int size;
- int entries;
- int counts[HASH_TABLE_MAX_COLLISIONS + 1];
-} HashTable;
-
-/*
- * InitHashTable() - Initialize the hash table.
- *
- */
-
-static int InitHashTable(HashTable *htable, int fsize)
-{
- int ii;
-
- htable->entry = (HashEntry *) malloc(sizeof(HashEntry)*fsize);
- if (!htable->entry)
- return 0;
- htable->size = fsize;
- for (ii = 0; ii < fsize; ii++) {
- htable->entry[ii].index = 0;
- htable->entry[ii].value = 0;
- }
- htable->entries = 0;
- for (ii = 0; ii <= HASH_TABLE_MAX_COLLISIONS; ii++)
- htable->counts[ii] = 0;
- return 1;
-} // InitHashTable
-
-/*
- * FreeHashTable() - Free the hash table.
- *
- */
-
-static void FreeHashTable(HashTable *htable)
-{
- if (htable->entry)
- free(htable->entry);
- htable->entry = NULL;
- htable->size = 0;
- htable->entries = 0;
-} // FreeHashTable
-
-/*
- * Empty() - See if a hash table entry is empty.
- *
- */
-
-static int Empty(HashTable *htable, int hashloc)
-{
- assert(hashloc >= 0 && hashloc < htable->size);
- if (htable->entry[hashloc].index == 0) {
- return 1;
- } else {
- return 0;
- }
-} // Empty
-
-/*
- * Match() - See if a hash table entry is matches a string.
- *
- */
-
-static int Match(HashTable *htable, StringTable *stable, const char *s, int hashloc)
-{
- int strloc;
-
- strloc = htable->entry[hashloc].index;
- if (!strcmp(s, &stable->strings[strloc])) {
- return 1;
- } else {
- return 0;
- }
-} // Match
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-/////////////////////////////////////////// Atom table: ///////////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
-
-#define INIT_ATOM_TABLE_SIZE 1024
-
-
-struct AtomTable_Rec {
- StringTable stable; // String table.
- HashTable htable; // Hashes string to atom number and token value. Multiple strings can
- // have the same token value but each unique string is a unique atom.
- int *amap; // Maps atom value to offset in string table. Atoms all map to unique
- // strings except for some undefined values in the lower, fixed part
- // of the atom table that map to "<undefined>". The lowest 256 atoms
- // correspond to single character ASCII values except for alphanumeric
- // characters and '_', which can be other tokens. Next come the
- // language tokens with their atom values equal to the token value.
- // Then come predefined atoms, followed by user specified identifiers.
- int *arev; // Reversed atom for symbol table use.
- int nextFree;
- int size;
-};
-
-static AtomTable latable = { { NULL, 0, 0 }, { NULL, 0, 0, {0} }, NULL, NULL, 0, 0 };
-AtomTable *atable = &latable;
-
-static int AddAtomFixed(AtomTable *atable, const char *s, int atom);
-
-/*
- * GrowAtomTable() - Grow the atom table to at least "size" if it's smaller.
- *
- */
-
-static int GrowAtomTable(AtomTable *atable, int size)
-{
- int *newmap, *newrev;
-
- if (atable->size < size) {
- if (atable->amap) {
- newmap = realloc(atable->amap, sizeof(int)*size);
- newrev = realloc(atable->arev, sizeof(int)*size);
- } else {
- newmap = malloc(sizeof(int)*size);
- newrev = malloc(sizeof(int)*size);
- atable->size = 0;
- }
- if (!newmap || !newrev) {
- /* failed to grow -- error */
- if (newmap)
- atable->amap = newmap;
- if (newrev)
- atable->arev = newrev;
- return -1;
- }
- memset(&newmap[atable->size], 0, (size - atable->size) * sizeof(int));
- memset(&newrev[atable->size], 0, (size - atable->size) * sizeof(int));
- atable->amap = newmap;
- atable->arev = newrev;
- atable->size = size;
- }
- return 0;
-} // GrowAtomTable
-
-/*
- * lReverse() - Reverse the bottom 20 bits of a 32 bit int.
- *
- */
-
-static int lReverse(int fval)
-{
- unsigned int in = fval;
- int result = 0, cnt = 0;
-
- while(in) {
- result <<= 1;
- result |= in&1;
- in >>= 1;
- cnt++;
- }
-
- // Don't use all 31 bits. One million atoms is plenty and sometimes the
- // upper bits are used for other things.
-
- if (cnt < 20)
- result <<= 20 - cnt;
- return result;
-} // lReverse
-
-/*
- * AllocateAtom() - Allocate a new atom. Associated with the "undefined" value of -1.
- *
- */
-
-static int AllocateAtom(AtomTable *atable)
-{
- if (atable->nextFree >= atable->size)
- GrowAtomTable(atable, atable->nextFree*2);
- atable->amap[atable->nextFree] = -1;
- atable->arev[atable->nextFree] = lReverse(atable->nextFree);
- atable->nextFree++;
- return atable->nextFree - 1;
-} // AllocateAtom
-
-/*
- * SetAtomValue() - Allocate a new atom associated with "hashindex".
- *
- */
-
-static void SetAtomValue(AtomTable *atable, int atomnumber, int hashindex)
-{
- atable->amap[atomnumber] = atable->htable.entry[hashindex].index;
- atable->htable.entry[hashindex].value = atomnumber;
-} // SetAtomValue
-
-/*
- * FindHashLoc() - Find the hash location for this string. Return -1 it hash table is full.
- *
- */
-
-static int FindHashLoc(AtomTable *atable, const char *s)
-{
- int hashloc, hashdelta, count;
- int FoundEmptySlot = 0;
- int collision[HASH_TABLE_MAX_COLLISIONS + 1];
-
- hashloc = HashString(s) % atable->htable.size;
- if (!Empty(&atable->htable, hashloc)) {
- if (Match(&atable->htable, &atable->stable, s, hashloc))
- return hashloc;
- collision[0] = hashloc;
- hashdelta = HashString2(s);
- count = 0;
- while (count < HASH_TABLE_MAX_COLLISIONS) {
- hashloc = ((hashloc + hashdelta) & 0x7fffffff) % atable->htable.size;
- if (!Empty(&atable->htable, hashloc)) {
- if (Match(&atable->htable, &atable->stable, s, hashloc)) {
- return hashloc;
- }
- } else {
- FoundEmptySlot = 1;
- break;
- }
- count++;
- collision[count] = hashloc;
- }
-
- if (!FoundEmptySlot) {
- if (cpp->options.DumpAtomTable) {
- int ii;
- char str[200];
- snprintf(str, sizeof(str), "*** Hash failed with more than %d collisions. Must increase hash table size. ***",
- HASH_TABLE_MAX_COLLISIONS);
- CPPShInfoLogMsg(str);
-
- snprintf(str, sizeof(str), "*** New string \"%s\", hash=%04x, delta=%04x", s, collision[0], hashdelta);
- CPPShInfoLogMsg(str);
- for (ii = 0; ii <= HASH_TABLE_MAX_COLLISIONS; ii++) {
- snprintf(str, sizeof(str), "*** Collides on try %d at hash entry %04x with \"%s\"",
- ii + 1, collision[ii], GetAtomString(atable, atable->htable.entry[collision[ii]].value));
- CPPShInfoLogMsg(str);
- }
- }
- return -1;
- } else {
- atable->htable.counts[count]++;
- }
- }
- return hashloc;
-} // FindHashLoc
-
-/*
- * IncreaseHashTableSize()
- *
- */
-
-static int IncreaseHashTableSize(AtomTable *atable)
-{
- int ii, strloc, oldhashloc, value, size;
- AtomTable oldtable;
- char *s;
-
- // Save the old atom table and create a new one:
-
- oldtable = *atable;
- size = oldtable.htable.size*2 + 1;
- if (!InitAtomTable(atable, size))
- return 0;
-
- // Add all the existing values to the new atom table preserving their atom values:
-
- for (ii = atable->nextFree; ii < oldtable.nextFree; ii++) {
- strloc = oldtable.amap[ii];
- s = &oldtable.stable.strings[strloc];
- oldhashloc = FindHashLoc(&oldtable, s);
- assert(oldhashloc >= 0);
- value = oldtable.htable.entry[oldhashloc].value;
- AddAtomFixed(atable, s, value);
- }
- FreeAtomTable(&oldtable);
- return 1;
-} // IncreaseHashTableSize
-
-/*
- * LookUpAddStringHash() - Lookup a string in the hash table. If it's not there, add it and
- * initialize the atom value in the hash table to 0. Return the hash table index.
- */
-
-static int LookUpAddStringHash(AtomTable *atable, const char *s)
-{
- int hashloc, strloc;
-
- while(1) {
- hashloc = FindHashLoc(atable, s);
- if (hashloc >= 0)
- break;
- IncreaseHashTableSize(atable);
- }
-
- if (Empty(&atable->htable, hashloc)) {
- atable->htable.entries++;
- strloc = AddString(&atable->stable, s);
- atable->htable.entry[hashloc].index = strloc;
- atable->htable.entry[hashloc].value = 0;
- }
- return hashloc;
-} // LookUpAddStringHash
-
-/*
- * LookUpAddString() - Lookup a string in the hash table. If it's not there, add it and
- * initialize the atom value in the hash table to the next atom number.
- * Return the atom value of string.
- */
-
-int LookUpAddString(AtomTable *atable, const char *s)
-{
- int hashindex, atom;
-
- hashindex = LookUpAddStringHash(atable, s);
- atom = atable->htable.entry[hashindex].value;
- if (atom == 0) {
- atom = AllocateAtom(atable);
- SetAtomValue(atable, atom, hashindex);
- }
- return atom;
-} // LookUpAddString
-
-/*
- * GetAtomString()
- *
- */
-
-const char *GetAtomString(AtomTable *atable, int atom)
-{
- int soffset;
-
- if (atom > 0 && atom < atable->nextFree) {
- soffset = atable->amap[atom];
- if (soffset > 0 && soffset < atable->stable.nextFree) {
- return &atable->stable.strings[soffset];
- } else {
- return "<internal error: bad soffset>";
- }
- } else {
- if (atom == 0) {
- return "<null atom>";
- } else {
- if (atom == EOF) {
- return "<EOF>";
- } else {
- return "<invalid atom>";
- }
- }
- }
-} // GetAtomString
-
-/*
- * GetReversedAtom()
- *
- */
-
-int GetReversedAtom(AtomTable *atable, int atom)
-{
- if (atom > 0 && atom < atable->nextFree) {
- return atable->arev[atom];
- } else {
- return 0;
- }
-} // GetReversedAtom
-
-/*
- * AddAtom() - Add a string to the atom, hash and string tables if it isn't already there.
- * Return it's atom index.
- */
-
-int AddAtom(AtomTable *atable, const char *s)
-{
- int atom;
-
- atom = LookUpAddString(atable, s);
- return atom;
-} // AddAtom
-
-/*
- * AddAtomFixed() - Add an atom to the hash and string tables if it isn't already there.
- * Assign it the atom value of "atom".
- */
-
-static int AddAtomFixed(AtomTable *atable, const char *s, int atom)
-{
- int hashindex, lsize;
-
- hashindex = LookUpAddStringHash(atable, s);
- if (atable->nextFree >= atable->size || atom >= atable->size) {
- lsize = atable->size*2;
- if (lsize <= atom)
- lsize = atom + 1;
- GrowAtomTable(atable, lsize);
- }
- atable->amap[atom] = atable->htable.entry[hashindex].index;
- atable->htable.entry[hashindex].value = atom;
- //if (atom >= atable->nextFree)
- // atable->nextFree = atom + 1;
- while (atom >= atable->nextFree) {
- atable->arev[atable->nextFree] = lReverse(atable->nextFree);
- atable->nextFree++;
- }
- return atom;
-} // AddAtomFixed
-
-/*
- * InitAtomTable() - Initialize the atom table.
- *
- */
-
-int InitAtomTable(AtomTable *atable, int htsize)
-{
- unsigned int ii;
-
- htsize = htsize <= 0 ? INIT_HASH_TABLE_SIZE : htsize;
- if (!InitStringTable(&atable->stable))
- return 0;
- if (!InitHashTable(&atable->htable, htsize))
- return 0;
-
- atable->nextFree = 0;
- atable->amap = NULL;
- atable->size = 0;
- GrowAtomTable(atable, INIT_ATOM_TABLE_SIZE);
- if (!atable->amap)
- return 0;
-
- // Initialize lower part of atom table to "<undefined>" atom:
-
- AddAtomFixed(atable, "<undefined>", 0);
- for (ii = 0; ii < FIRST_USER_TOKEN_SY; ii++)
- atable->amap[ii] = atable->amap[0];
-
- // Add single character tokens to the atom table:
-
- {
- const char *s = "~!%^&*()-+=|,.<>/?;:[]{}#";
- char t[2];
-
- t[1] = '\0';
- while (*s) {
- t[0] = *s;
- AddAtomFixed(atable, t, s[0]);
- s++;
- }
- }
-
- // Add multiple character scanner tokens :
-
- for (ii = 0; ii < sizeof(tokens)/sizeof(tokens[0]); ii++)
- AddAtomFixed(atable, tokens[ii].str, tokens[ii].val);
-
- // Add error symbol if running in error mode:
-
- if (cpp->options.ErrorMode)
- AddAtomFixed(atable, "error", ERROR_SY);
-
- AddAtom(atable, "<*** end fixed atoms ***>");
-
- return 1;
-} // InitAtomTable
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-////////////////////////////////// Debug Printing Functions: //////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
-
-/*
- * PrintAtomTable()
- *
- */
-
-void PrintAtomTable(AtomTable *atable)
-{
- int ii;
- char str[200];
-
- for (ii = 0; ii < atable->nextFree; ii++) {
- snprintf(str, sizeof(str), "%d: \"%s\"", ii, &atable->stable.strings[atable->amap[ii]]);
- CPPDebugLogMsg(str);
- }
- snprintf(str, sizeof(str), "Hash table: size=%d, entries=%d, collisions=",
- atable->htable.size, atable->htable.entries);
- CPPDebugLogMsg(str);
- for (ii = 0; ii < HASH_TABLE_MAX_COLLISIONS; ii++) {
- snprintf(str, sizeof(str), " %d", atable->htable.counts[ii]);
- CPPDebugLogMsg(str);
- }
-
-} // PrintAtomTable
-
-
-/*
- * GetStringOfAtom()
- *
- */
-
-char* GetStringOfAtom(AtomTable *atable, int atom)
-{
- char* chr_str;
- chr_str=&atable->stable.strings[atable->amap[atom]];
- return chr_str;
-} // GetStringOfAtom
-
-/*
- * FreeAtomTable() - Free the atom table and associated memory
- *
- */
-
-void FreeAtomTable(AtomTable *atable)
-{
- FreeStringTable(&atable->stable);
- FreeHashTable(&atable->htable);
- if (atable->amap)
- free(atable->amap);
- if (atable->arev)
- free(atable->arev);
- atable->amap = NULL;
- atable->arev = NULL;
- atable->nextFree = 0;
- atable->size = 0;
-} // FreeAtomTable
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-///////////////////////////////////////// End of atom.c ///////////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
-
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/atom.h b/src/3rdparty/angle/src/compiler/preprocessor/atom.h
deleted file mode 100644
index 1d84c32515..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/atom.h
+++ /dev/null
@@ -1,63 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-// atom.h
-//
-
-#if !defined(__ATOM_H)
-#define __ATOM_H 1
-
-typedef struct AtomTable_Rec AtomTable;
-
-extern AtomTable *atable;
-
-int InitAtomTable(AtomTable *atable, int htsize);
-void FreeAtomTable(AtomTable *atable);
-int AddAtom(AtomTable *atable, const char *s);
-void PrintAtomTable(AtomTable *atable);
-int LookUpAddString(AtomTable *atable, const char *s);
-const char *GetAtomString(AtomTable *atable, int atom);
-int GetReversedAtom(AtomTable *atable, int atom);
-char* GetStringOfAtom(AtomTable *atable, int atom);
-#endif // !defined(__ATOM_H)
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/compile.h b/src/3rdparty/angle/src/compiler/preprocessor/compile.h
deleted file mode 100644
index 11808531cc..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/compile.h
+++ /dev/null
@@ -1,100 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-// compile.h
-//
-
-#if !defined(__COMPILE_H)
-#define __COMPILE_H 1
-
-int InitCPPStruct(void);
-
-typedef struct Options_Rec{
- const char *profileString;
- int ErrorMode;
- int Quiet;
-
- // Debug The Compiler options:
- int DumpAtomTable;
-} Options;
-
-#define MAX_IF_NESTING 64
-struct CPPStruct_Rec {
- // Public members
- SourceLoc *pLastSourceLoc; // Set at the start of each statement by the tree walkers
- Options options; // Compile options and parameters
-
- // Private members
- SourceLoc lastSourceLoc;
-
- // Scanner data:
-
- SourceLoc *tokenLoc; // Source location of most recent token seen by the scanner
- int mostRecentToken; // Most recent token seen by the scanner
- InputSrc *currentInput;
- int previous_token;
- int pastFirstStatement; // used to make sure that #version is the first statement seen in the file, if present
-
- void *pC; // storing the parseContext of the compile object in cpp.
-
- // Private members:
- SourceLoc ltokenLoc;
- int ifdepth; //current #if-#else-#endif nesting in the cpp.c file (pre-processor)
- int elsedepth[MAX_IF_NESTING];//Keep a track of #if depth..Max allowed is 64.
- int elsetracker; //#if-#else and #endif constructs...Counter.
- const char *ErrMsg;
- int CompileError; //Indicate compile error when #error, #else,#elif mismatch.
-
- //
- // Globals used to communicate between PaParseStrings() and yy_input()and
- // also across the files.(gen_glslang.cpp and scanner.c)
- //
- int PaWhichStr; // which string we're parsing
- const int* PaStrLen; // array of lengths of the PaArgv strings
- int PaArgc; // count of strings in the array
- const char* const* PaArgv; // our array of strings to parse
- unsigned int tokensBeforeEOF : 1;
-};
-
-#endif // !defined(__COMPILE_H)
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/cpp.c b/src/3rdparty/angle/src/compiler/preprocessor/cpp.c
deleted file mode 100644
index 8a1076b9df..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/cpp.c
+++ /dev/null
@@ -1,1118 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-// cpp.c
-//
-
-#include <stdarg.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <ctype.h>
-
-#include "common/angleutils.h"
-#include "compiler/preprocessor/slglobals.h"
-
-#if defined(_MSC_VER)
-#pragma warning(disable: 4054)
-#pragma warning(disable: 4152)
-#pragma warning(disable: 4706)
-#endif
-
-static int CPPif(yystypepp * yylvalpp);
-
-/* Don't use memory.c's replacements, as we clean up properly here */
-#undef malloc
-#undef free
-
-static int bindAtom = 0;
-static int constAtom = 0;
-static int defaultAtom = 0;
-static int defineAtom = 0;
-static int definedAtom = 0;
-static int elseAtom = 0;
-static int elifAtom = 0;
-static int endifAtom = 0;
-static int ifAtom = 0;
-static int ifdefAtom = 0;
-static int ifndefAtom = 0;
-static int includeAtom = 0;
-static int lineAtom = 0;
-static int pragmaAtom = 0;
-static int texunitAtom = 0;
-static int undefAtom = 0;
-static int errorAtom = 0;
-static int __LINE__Atom = 0;
-static int __FILE__Atom = 0;
-static int __VERSION__Atom = 0;
-static int versionAtom = 0;
-static int extensionAtom = 0;
-
-static Scope *macros = 0;
-#define MAX_MACRO_ARGS 64
-
-static SourceLoc ifloc; /* outermost #if */
-
-int InitCPP(void)
-{
- char buffer[64], *t;
- const char *f;
-
- // Add various atoms needed by the CPP line scanner:
- bindAtom = LookUpAddString(atable, "bind");
- constAtom = LookUpAddString(atable, "const");
- defaultAtom = LookUpAddString(atable, "default");
- defineAtom = LookUpAddString(atable, "define");
- definedAtom = LookUpAddString(atable, "defined");
- elifAtom = LookUpAddString(atable, "elif");
- elseAtom = LookUpAddString(atable, "else");
- endifAtom = LookUpAddString(atable, "endif");
- ifAtom = LookUpAddString(atable, "if");
- ifdefAtom = LookUpAddString(atable, "ifdef");
- ifndefAtom = LookUpAddString(atable, "ifndef");
- includeAtom = LookUpAddString(atable, "include");
- lineAtom = LookUpAddString(atable, "line");
- pragmaAtom = LookUpAddString(atable, "pragma");
- texunitAtom = LookUpAddString(atable, "texunit");
- undefAtom = LookUpAddString(atable, "undef");
- errorAtom = LookUpAddString(atable, "error");
- __LINE__Atom = LookUpAddString(atable, "__LINE__");
- __FILE__Atom = LookUpAddString(atable, "__FILE__");
- __VERSION__Atom = LookUpAddString(atable, "__VERSION__");
- versionAtom = LookUpAddString(atable, "version");
- extensionAtom = LookUpAddString(atable, "extension");
- macros = NewScopeInPool(mem_CreatePool(0, 0));
- strcpy(buffer, "PROFILE_");
- t = buffer + strlen(buffer);
- f = cpp->options.profileString;
- while ((isalnum(*f) || *f == '_') && t < buffer + sizeof(buffer) - 1)
- *t++ = toupper(*f++);
- *t = 0;
-
- PredefineIntMacro("GL_ES", 1);
- PredefineIntMacro("GL_FRAGMENT_PRECISION_HIGH", 1);
-
- return 1;
-} // InitCPP
-
-int FreeCPP(void)
-{
- if (macros)
- {
- mem_FreePool(macros->pool);
- macros = 0;
- }
-
- return 1;
-}
-
-int FinalCPP(void)
-{
- if (cpp->ifdepth)
- CPPErrorToInfoLog("#if mismatch");
- return 1;
-}
-
-static int CPPdefine(yystypepp * yylvalpp)
-{
- int token, name, args[MAX_MACRO_ARGS], argc;
- const char *message;
- MacroSymbol mac;
- Symbol *symb;
- SourceLoc dummyLoc;
- memset(&mac, 0, sizeof(mac));
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token != CPP_IDENTIFIER) {
- CPPErrorToInfoLog("#define");
- return token;
- }
- name = yylvalpp->sc_ident;
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token == '(' && !yylvalpp->sc_int) {
- // gather arguments
- argc = 0;
- do {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (argc == 0 && token == ')') break;
- if (token != CPP_IDENTIFIER) {
- CPPErrorToInfoLog("#define");
- return token;
- }
- if (argc < MAX_MACRO_ARGS)
- args[argc++] = yylvalpp->sc_ident;
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- } while (token == ',');
- if (token != ')') {
- CPPErrorToInfoLog("#define");
- return token;
- }
- mac.argc = argc;
- mac.args = mem_Alloc(macros->pool, argc * sizeof(int));
- memcpy(mac.args, args, argc * sizeof(int));
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- }
- mac.body = NewTokenStream(GetAtomString(atable, name), macros->pool);
- while (token != '\n') {
- if (token == '\\') {
- CPPErrorToInfoLog("The line continuation character (\\) is not part of the OpenGL ES Shading Language");
- return token;
- } else if (token <= 0) { // EOF or error
- CPPErrorToInfoLog("unexpected end of input in #define preprocessor directive - expected a newline");
- return 0;
- }
- RecordToken(mac.body, token, yylvalpp);
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- };
-
- symb = LookUpSymbol(macros, name);
- if (symb) {
- if (!symb->details.mac.undef) {
- // already defined -- need to make sure they are identical
- if (symb->details.mac.argc != mac.argc) goto error;
- for (argc=0; argc < mac.argc; argc++)
- if (symb->details.mac.args[argc] != mac.args[argc])
- goto error;
- RewindTokenStream(symb->details.mac.body);
- RewindTokenStream(mac.body);
- do {
- int old_lval, old_token;
- old_token = ReadToken(symb->details.mac.body, yylvalpp);
- old_lval = yylvalpp->sc_int;
- token = ReadToken(mac.body, yylvalpp);
- if (token != old_token || yylvalpp->sc_int != old_lval) {
- error:
- StoreStr("Macro Redefined");
- StoreStr(GetStringOfAtom(atable,name));
- message=GetStrfromTStr();
- DecLineNumber();
- CPPShInfoLogMsg(message);
- IncLineNumber();
- ResetTString();
- break; }
- } while (token > 0);
- }
- //FreeMacro(&symb->details.mac);
- } else {
- dummyLoc.file = 0;
- dummyLoc.line = 0;
- symb = AddSymbol(&dummyLoc, macros, name, MACRO_S);
- }
- symb->details.mac = mac;
- return '\n';
-} // CPPdefine
-
-static int CPPundef(yystypepp * yylvalpp)
-{
- int token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- Symbol *symb;
- if(token == '\n'){
- CPPErrorToInfoLog("#undef");
- return token;
- }
- if (token != CPP_IDENTIFIER)
- goto error;
- symb = LookUpSymbol(macros, yylvalpp->sc_ident);
- if (symb) {
- symb->details.mac.undef = 1;
- }
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token != '\n') {
- error:
- CPPErrorToInfoLog("#undef");
- }
- return token;
-} // CPPundef
-
-/* CPPelse -- skip forward to appropriate spot. This is actually used
-** to skip to and #endif after seeing an #else, AND to skip to a #else,
-** #elif, or #endif after a #if/#ifdef/#ifndef/#elif test was false
-*/
-
-static int CPPelse(int matchelse, yystypepp * yylvalpp)
-{
- int atom,depth=0;
- int token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
-
- while (token > 0) {
- if (token != '#') {
- while (token != '\n') {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token <= 0) { // EOF or error
- CPPErrorToInfoLog("unexpected end of input in #else preprocessor directive - expected a newline");
- return 0;
- }
- }
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- continue;
- }
- if ((token = cpp->currentInput->scan(cpp->currentInput, yylvalpp)) != CPP_IDENTIFIER)
- continue;
- atom = yylvalpp->sc_ident;
- if (atom == ifAtom || atom == ifdefAtom || atom == ifndefAtom){
- depth++; cpp->ifdepth++; cpp->elsetracker++;
- if (cpp->ifdepth > MAX_IF_NESTING) {
- CPPErrorToInfoLog("max #if nesting depth exceeded");
- cpp->CompileError = 1;
- return 0;
- }
- // sanity check elsetracker
- if (cpp->elsetracker < 0 || cpp->elsetracker >= MAX_IF_NESTING) {
- CPPErrorToInfoLog("mismatched #if/#endif statements");
- cpp->CompileError = 1;
- return 0;
- }
- cpp->elsedepth[cpp->elsetracker] = 0;
- }
- else if (atom == endifAtom) {
- if(--depth<0){
- if (cpp->elsetracker)
- --cpp->elsetracker;
- if (cpp->ifdepth)
- --cpp->ifdepth;
- break;
- }
- --cpp->elsetracker;
- --cpp->ifdepth;
- }
- else if (((int)(matchelse) != 0)&& depth==0) {
- if (atom == elseAtom ) {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token != '\n') {
- CPPWarningToInfoLog("unexpected tokens following #else preprocessor directive - expected a newline");
- while (token != '\n') {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token <= 0) { // EOF or error
- CPPErrorToInfoLog("unexpected end of input following #else preprocessor directive - expected a newline");
- return 0;
- }
- }
- }
- break;
- }
- else if (atom == elifAtom) {
- /* we decrement cpp->ifdepth here, because CPPif will increment
- * it and we really want to leave it alone */
- if (cpp->ifdepth){
- --cpp->ifdepth;
- --cpp->elsetracker;
- }
- return CPPif(yylvalpp);
- }
- }
- else if((atom==elseAtom) && (!ChkCorrectElseNesting())){
- CPPErrorToInfoLog("#else after a #else");
- cpp->CompileError=1;
- return 0;
- }
- };
- return token;
-}
-
-enum eval_prec {
- MIN_PREC,
- COND, LOGOR, LOGAND, OR, XOR, AND, EQUAL, RELATION, SHIFT, ADD, MUL, UNARY,
- MAX_PREC
-};
-
-static int op_logor(int a, int b) { return a || b; }
-static int op_logand(int a, int b) { return a && b; }
-static int op_or(int a, int b) { return a | b; }
-static int op_xor(int a, int b) { return a ^ b; }
-static int op_and(int a, int b) { return a & b; }
-static int op_eq(int a, int b) { return a == b; }
-static int op_ne(int a, int b) { return a != b; }
-static int op_ge(int a, int b) { return a >= b; }
-static int op_le(int a, int b) { return a <= b; }
-static int op_gt(int a, int b) { return a > b; }
-static int op_lt(int a, int b) { return a < b; }
-static int op_shl(int a, int b) { return a << b; }
-static int op_shr(int a, int b) { return a >> b; }
-static int op_add(int a, int b) { return a + b; }
-static int op_sub(int a, int b) { return a - b; }
-static int op_mul(int a, int b) { return a * b; }
-static int op_div(int a, int b) { return a / b; }
-static int op_mod(int a, int b) { return a % b; }
-static int op_pos(int a) { return a; }
-static int op_neg(int a) { return -a; }
-static int op_cmpl(int a) { return ~a; }
-static int op_not(int a) { return !a; }
-
-struct {
- int token, prec, (*op)(int, int);
-} binop[] = {
- { CPP_OR_OP, LOGOR, op_logor },
- { CPP_AND_OP, LOGAND, op_logand },
- { '|', OR, op_or },
- { '^', XOR, op_xor },
- { '&', AND, op_and },
- { CPP_EQ_OP, EQUAL, op_eq },
- { CPP_NE_OP, EQUAL, op_ne },
- { '>', RELATION, op_gt },
- { CPP_GE_OP, RELATION, op_ge },
- { '<', RELATION, op_lt },
- { CPP_LE_OP, RELATION, op_le },
- { CPP_LEFT_OP, SHIFT, op_shl },
- { CPP_RIGHT_OP, SHIFT, op_shr },
- { '+', ADD, op_add },
- { '-', ADD, op_sub },
- { '*', MUL, op_mul },
- { '/', MUL, op_div },
- { '%', MUL, op_mod },
-};
-
-struct {
- int token, (*op)(int);
-} unop[] = {
- { '+', op_pos },
- { '-', op_neg },
- { '~', op_cmpl },
- { '!', op_not },
-};
-
-#define ALEN(A) (sizeof(A)/sizeof(A[0]))
-
-static int eval(int token, int prec, int *res, int *err, yystypepp * yylvalpp)
-{
- int i, val;
- Symbol *s;
- if (token == CPP_IDENTIFIER) {
- if (yylvalpp->sc_ident == definedAtom) {
- int needclose = 0;
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token == '(') {
- needclose = 1;
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- }
- if (token != CPP_IDENTIFIER)
- goto error;
- *res = (s = LookUpSymbol(macros, yylvalpp->sc_ident))
- ? !s->details.mac.undef : 0;
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (needclose) {
- if (token != ')')
- goto error;
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- }
- } else if (MacroExpand(yylvalpp->sc_ident, yylvalpp)) {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- return eval(token, prec, res, err, yylvalpp);
- } else {
- goto error;
- }
- } else if (token == CPP_INTCONSTANT) {
- *res = yylvalpp->sc_int;
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- } else if (token == '(') {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- token = eval(token, MIN_PREC, res, err, yylvalpp);
- if (!*err) {
- if (token != ')')
- goto error;
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- }
- } else {
- for (i = ALEN(unop) - 1; i >= 0; i--) {
- if (unop[i].token == token)
- break;
- }
- if (i >= 0) {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- token = eval(token, UNARY, res, err, yylvalpp);
- *res = unop[i].op(*res);
- } else {
- goto error;
- }
- }
- while (!*err) {
- if (token == ')' || token == '\n') break;
- for (i = ALEN(binop) - 1; i >= 0; i--) {
- if (binop[i].token == token)
- break;
- }
- if (i < 0 || binop[i].prec <= prec)
- break;
- val = *res;
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- token = eval(token, binop[i].prec, res, err, yylvalpp);
-
- if (binop[i].op == op_div || binop[i].op == op_mod)
- {
- if (*res == 0)
- {
- CPPErrorToInfoLog("preprocessor divide or modulo by zero");
- *err = 1;
- return token;
- }
- }
-
- *res = binop[i].op(val, *res);
- }
- return token;
-error:
- CPPErrorToInfoLog("incorrect preprocessor directive");
- *err = 1;
- *res = 0;
- return token;
-} // eval
-
-static int CPPif(yystypepp * yylvalpp) {
- int token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- int res = 0, err = 0;
-
- if (!cpp->ifdepth++)
- ifloc = *cpp->tokenLoc;
- if(cpp->ifdepth > MAX_IF_NESTING){
- CPPErrorToInfoLog("max #if nesting depth exceeded");
- cpp->CompileError = 1;
- return 0;
- }
- cpp->elsetracker++;
- // sanity check elsetracker
- if (cpp->elsetracker < 0 || cpp->elsetracker >= MAX_IF_NESTING) {
- CPPErrorToInfoLog("mismatched #if/#endif statements");
- cpp->CompileError = 1;
- return 0;
- }
- cpp->elsedepth[cpp->elsetracker] = 0;
-
- token = eval(token, MIN_PREC, &res, &err, yylvalpp);
- if (token != '\n') {
- CPPWarningToInfoLog("unexpected tokens following #if preprocessor directive - expected a newline");
- while (token != '\n') {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token <= 0) { // EOF or error
- CPPErrorToInfoLog("unexpected end of input in #if preprocessor directive - expected a newline");
- return 0;
- }
- }
- }
- if (!res && !err) {
- token = CPPelse(1, yylvalpp);
- }
-
- return token;
-} // CPPif
-
-static int CPPifdef(int defined, yystypepp * yylvalpp)
-{
- int token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- int name = yylvalpp->sc_ident;
- if(++cpp->ifdepth > MAX_IF_NESTING){
- CPPErrorToInfoLog("max #if nesting depth exceeded");
- cpp->CompileError = 1;
- return 0;
- }
- cpp->elsetracker++;
- // sanity check elsetracker
- if (cpp->elsetracker < 0 || cpp->elsetracker >= MAX_IF_NESTING) {
- CPPErrorToInfoLog("mismatched #if/#endif statements");
- cpp->CompileError = 1;
- return 0;
- }
- cpp->elsedepth[cpp->elsetracker] = 0;
-
- if (token != CPP_IDENTIFIER) {
- defined ? CPPErrorToInfoLog("ifdef"):CPPErrorToInfoLog("ifndef");
- } else {
- Symbol *s = LookUpSymbol(macros, name);
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token != '\n') {
- CPPWarningToInfoLog("unexpected tokens following #ifdef preprocessor directive - expected a newline");
- while (token != '\n') {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token <= 0) { // EOF or error
- CPPErrorToInfoLog("unexpected end of input in #ifdef preprocessor directive - expected a newline");
- return 0;
- }
- }
- }
- if (((s && !s->details.mac.undef) ? 1 : 0) != defined)
- token = CPPelse(1, yylvalpp);
- }
- return token;
-} // CPPifdef
-
-static int CPPline(yystypepp * yylvalpp)
-{
- int token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if(token=='\n'){
- DecLineNumber();
- CPPErrorToInfoLog("#line");
- IncLineNumber();
- return token;
- }
- else if (token == CPP_INTCONSTANT) {
- yylvalpp->sc_int=atoi(yylvalpp->symbol_name);
- SetLineNumber(yylvalpp->sc_int);
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
-
- if (token == CPP_INTCONSTANT) {
- yylvalpp->sc_int=atoi(yylvalpp->symbol_name);
- SetStringNumber(yylvalpp->sc_int);
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if(token!='\n')
- CPPErrorToInfoLog("#line");
- }
- else if (token == '\n'){
- return token;
- }
- else{
- CPPErrorToInfoLog("#line");
- }
- }
- else{
- CPPErrorToInfoLog("#line");
- }
- return token;
-}
-
-static int CPPerror(yystypepp * yylvalpp) {
-
- int token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- const char *message;
-
- while (token != '\n') {
- if (token <= 0){
- CPPErrorToInfoLog("unexpected end of input in #error preprocessor directive - expected a newline");
- return 0;
- }else if (token == CPP_FLOATCONSTANT || token == CPP_INTCONSTANT){
- StoreStr(yylvalpp->symbol_name);
- }else if(token == CPP_IDENTIFIER || token == CPP_STRCONSTANT){
- StoreStr(GetStringOfAtom(atable,yylvalpp->sc_ident));
- }else {
- StoreStr(GetStringOfAtom(atable,token));
- }
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- }
- DecLineNumber();
- //store this msg into the shader's information log..set the Compile Error flag!!!!
- message=GetStrfromTStr();
- CPPShInfoLogMsg(message);
- ResetTString();
- cpp->CompileError=1;
- IncLineNumber();
- return '\n';
-}//CPPerror
-
-static int CPPpragma(yystypepp * yylvalpp)
-{
- char SrcStrName[2];
- char** allTokens;
- int tokenCount = 0;
- int maxTokenCount = 10;
- const char* SrcStr;
- int i;
-
- int token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
-
- if (token=='\n') {
- DecLineNumber();
- CPPErrorToInfoLog("#pragma");
- IncLineNumber();
- return token;
- }
-
- allTokens = (char**)malloc(sizeof(char*) * maxTokenCount);
-
- while (token != '\n') {
- if (tokenCount >= maxTokenCount) {
- maxTokenCount *= 2;
- allTokens = (char**)realloc((char**)allTokens, sizeof(char*) * maxTokenCount);
- }
- switch (token) {
- case CPP_IDENTIFIER:
- SrcStr = GetAtomString(atable, yylvalpp->sc_ident);
- allTokens[tokenCount] = (char*)malloc(strlen(SrcStr) + 1);
- strcpy(allTokens[tokenCount++], SrcStr);
- break;
- case CPP_INTCONSTANT:
- SrcStr = yylvalpp->symbol_name;
- allTokens[tokenCount] = (char*)malloc(strlen(SrcStr) + 1);
- strcpy(allTokens[tokenCount++], SrcStr);
- break;
- case CPP_FLOATCONSTANT:
- SrcStr = yylvalpp->symbol_name;
- allTokens[tokenCount] = (char*)malloc(strlen(SrcStr) + 1);
- strcpy(allTokens[tokenCount++], SrcStr);
- break;
- case -1:
- // EOF
- CPPShInfoLogMsg("#pragma directive must end with a newline");
- goto freeMemoryAndReturnToken;
- default:
- SrcStrName[0] = token;
- SrcStrName[1] = '\0';
- allTokens[tokenCount] = (char*)malloc(2);
- strcpy(allTokens[tokenCount++], SrcStrName);
- }
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- }
-
- HandlePragma((const char**)allTokens, tokenCount);
-
-freeMemoryAndReturnToken:
- for (i = 0; i < tokenCount; ++i) {
- free (allTokens[i]);
- }
- free (allTokens);
-
- return token;
-} // CPPpragma
-
-#define ESSL_VERSION_NUMBER 100
-#define ESSL_VERSION_STRING "100"
-
-static int CPPversion(yystypepp * yylvalpp)
-{
-
- int token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
-
- if (cpp->pastFirstStatement == 1)
- CPPShInfoLogMsg("#version must occur before any other statement in the program");
-
- if(token=='\n'){
- DecLineNumber();
- CPPErrorToInfoLog("#version");
- IncLineNumber();
- return token;
- }
- if (token != CPP_INTCONSTANT)
- CPPErrorToInfoLog("#version");
-
- yylvalpp->sc_int=atoi(yylvalpp->symbol_name);
- //SetVersionNumber(yylvalpp->sc_int);
-
- if (yylvalpp->sc_int != ESSL_VERSION_NUMBER)
- CPPShInfoLogMsg("Version number not supported by ESSL");
-
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
-
- if (token == '\n'){
- return token;
- }
- else{
- CPPErrorToInfoLog("#version");
- }
- return token;
-} // CPPversion
-
-static int CPPextension(yystypepp * yylvalpp)
-{
-
- int token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- char extensionName[MAX_SYMBOL_NAME_LEN + 1];
-
- if(token=='\n'){
- DecLineNumber();
- CPPShInfoLogMsg("extension name not specified");
- IncLineNumber();
- return token;
- }
-
- if (token != CPP_IDENTIFIER)
- CPPErrorToInfoLog("#extension");
-
- strncpy(extensionName, GetAtomString(atable, yylvalpp->sc_ident), MAX_SYMBOL_NAME_LEN);
- extensionName[MAX_SYMBOL_NAME_LEN] = '\0';
-
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token != ':') {
- CPPShInfoLogMsg("':' missing after extension name");
- return token;
- }
-
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token != CPP_IDENTIFIER) {
- CPPShInfoLogMsg("behavior for extension not specified");
- return token;
- }
-
- updateExtensionBehavior(extensionName, GetAtomString(atable, yylvalpp->sc_ident));
-
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token == '\n'){
- return token;
- }
- else{
- CPPErrorToInfoLog("#extension");
- }
- return token;
-} // CPPextension
-
-int readCPPline(yystypepp * yylvalpp)
-{
- int token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- const char *message;
-
- if (token == CPP_IDENTIFIER) {
- if (yylvalpp->sc_ident == defineAtom) {
- token = CPPdefine(yylvalpp);
- } else if (yylvalpp->sc_ident == elseAtom) {
- if(ChkCorrectElseNesting()){
- if (!cpp->ifdepth ){
- CPPErrorToInfoLog("#else mismatch");
- cpp->CompileError=1;
- return 0;
- }
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token != '\n') {
- CPPWarningToInfoLog("unexpected tokens following #else preprocessor directive - expected a newline");
- while (token != '\n') {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token <= 0) { // EOF or error
- CPPErrorToInfoLog("unexpected end of input in #ifdef preprocessor directive - expected a newline");
- return 0;
- }
- }
- }
- token = CPPelse(0, yylvalpp);
- }else{
- CPPErrorToInfoLog("#else after a #else");
- cpp->ifdepth = 0;
- cpp->elsetracker = 0;
- cpp->pastFirstStatement = 1;
- cpp->CompileError = 1;
- return 0;
- }
- } else if (yylvalpp->sc_ident == elifAtom) {
- if (!cpp->ifdepth){
- CPPErrorToInfoLog("#elif mismatch");
- cpp->CompileError=1;
- return 0;
- }
- // this token is really a dont care, but we still need to eat the tokens
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- while (token != '\n') {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token <= 0) { // EOF or error
- CPPErrorToInfoLog("unexpect tokens following #elif preprocessor directive - expected a newline");
- cpp->CompileError = 1;
- return 0;
- }
- }
- token = CPPelse(0, yylvalpp);
- } else if (yylvalpp->sc_ident == endifAtom) {
- if (!cpp->ifdepth){
- CPPErrorToInfoLog("#endif mismatch");
- cpp->CompileError=1;
- return 0;
- }
- else
- --cpp->ifdepth;
-
- if (cpp->elsetracker)
- --cpp->elsetracker;
-
- } else if (yylvalpp->sc_ident == ifAtom) {
- token = CPPif(yylvalpp);
- } else if (yylvalpp->sc_ident == ifdefAtom) {
- token = CPPifdef(1, yylvalpp);
- } else if (yylvalpp->sc_ident == ifndefAtom) {
- token = CPPifdef(0, yylvalpp);
- } else if (yylvalpp->sc_ident == lineAtom) {
- token = CPPline(yylvalpp);
- } else if (yylvalpp->sc_ident == pragmaAtom) {
- token = CPPpragma(yylvalpp);
- } else if (yylvalpp->sc_ident == undefAtom) {
- token = CPPundef(yylvalpp);
- } else if (yylvalpp->sc_ident == errorAtom) {
- token = CPPerror(yylvalpp);
- } else if (yylvalpp->sc_ident == versionAtom) {
- token = CPPversion(yylvalpp);
- } else if (yylvalpp->sc_ident == extensionAtom) {
- token = CPPextension(yylvalpp);
- } else {
- StoreStr("Invalid Directive");
- StoreStr(GetStringOfAtom(atable,yylvalpp->sc_ident));
- message=GetStrfromTStr();
- CPPShInfoLogMsg(message);
- ResetTString();
- }
- }
- while (token != '\n' && token != 0 && token != EOF) {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- }
-
- cpp->pastFirstStatement = 1;
-
- return token;
-} // readCPPline
-
-void FreeMacro(MacroSymbol *s) {
- DeleteTokenStream(s->body);
-}
-
-void PredefineIntMacro(const char *name, int value) {
- SourceLoc location = {0, 0};
- Symbol *symbol = NULL;
- MacroSymbol macro = {0, NULL, NULL, 0, 0};
- yystypepp val = {0, 0.0, 0, {0}};
- int atom = 0;
-
- macro.body = NewTokenStream(name, macros->pool);
- val.sc_int = value;
- snprintf(val.symbol_name, MAX_SYMBOL_NAME_LEN+1, "%d", value);
- RecordToken(macro.body, CPP_INTCONSTANT, &val);
- atom = LookUpAddString(atable, name);
- symbol = AddSymbol(&location, macros, atom, MACRO_S);
- symbol->details.mac = macro;
-}
-
-static int eof_scan(InputSrc *in, yystypepp * yylvalpp) { return -1; }
-static void noop(InputSrc *in, int ch, yystypepp * yylvalpp) { }
-
-static void PushEofSrc() {
- InputSrc *in = malloc(sizeof(InputSrc));
- memset(in, 0, sizeof(InputSrc));
- in->scan = eof_scan;
- in->getch = eof_scan;
- in->ungetch = noop;
- in->prev = cpp->currentInput;
- cpp->currentInput = in;
-}
-
-static void PopEofSrc() {
- if (cpp->currentInput->scan == eof_scan) {
- InputSrc *in = cpp->currentInput;
- cpp->currentInput = in->prev;
- free(in);
- }
-}
-
-static TokenStream *PrescanMacroArg(TokenStream *a, yystypepp * yylvalpp) {
- int token;
- TokenStream *n;
- RewindTokenStream(a);
- do {
- token = ReadToken(a, yylvalpp);
- if (token == CPP_IDENTIFIER && LookUpSymbol(macros, yylvalpp->sc_ident))
- break;
- } while (token > 0);
- if (token <= 0) return a;
- n = NewTokenStream("macro arg", 0);
- PushEofSrc();
- ReadFromTokenStream(a, 0, 0);
- while ((token = cpp->currentInput->scan(cpp->currentInput, yylvalpp)) > 0) {
- if (token == CPP_IDENTIFIER && MacroExpand(yylvalpp->sc_ident, yylvalpp))
- continue;
- RecordToken(n, token, yylvalpp);
- }
- PopEofSrc();
- DeleteTokenStream(a);
- return n;
-} // PrescanMacroArg
-
-typedef struct MacroInputSrc {
- InputSrc base;
- MacroSymbol *mac;
- TokenStream **args;
-} MacroInputSrc;
-
-/* macro_scan ---
-** return the next token for a macro expanion, handling macro args
-*/
-static int macro_scan(MacroInputSrc *in, yystypepp * yylvalpp) {
- int i;
- int token = ReadToken(in->mac->body, yylvalpp);
- if (token == CPP_IDENTIFIER) {
- for (i = in->mac->argc-1; i>=0; i--)
- if (in->mac->args[i] == yylvalpp->sc_ident) break;
- if (i >= 0) {
- ReadFromTokenStream(in->args[i], yylvalpp->sc_ident, 0);
- return cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- }
- }
- if (token > 0) return token;
- in->mac->busy = 0;
- cpp->currentInput = in->base.prev;
- if (in->args) {
- for (i=in->mac->argc-1; i>=0; i--)
- DeleteTokenStream(in->args[i]);
- free(in->args);
- }
- free(in);
- return cpp->currentInput->scan(cpp->currentInput, yylvalpp);
-} // macro_scan
-
-/* MacroExpand
-** check an identifier (atom) to see if it a macro that should be expanded.
-** If it is, push an InputSrc that will produce the appropriate expansion
-** and return TRUE. If not, return FALSE.
-*/
-
-int MacroExpand(int atom, yystypepp * yylvalpp)
-{
- Symbol *sym = LookUpSymbol(macros, atom);
- MacroInputSrc *in;
- int i,j, token, depth=0;
- const char *message;
- if (atom == __LINE__Atom) {
- yylvalpp->sc_int = GetLineNumber();
- snprintf(yylvalpp->symbol_name, MAX_SYMBOL_NAME_LEN+1, "%d", yylvalpp->sc_int);
- UngetToken(CPP_INTCONSTANT, yylvalpp);
- return 1;
- }
- if (atom == __FILE__Atom) {
- yylvalpp->sc_int = GetStringNumber();
- snprintf(yylvalpp->symbol_name, MAX_SYMBOL_NAME_LEN+1, "%d", yylvalpp->sc_int);
- UngetToken(CPP_INTCONSTANT, yylvalpp);
- return 1;
- }
- if (atom == __VERSION__Atom) {
- strcpy(yylvalpp->symbol_name,ESSL_VERSION_STRING);
- yylvalpp->sc_int = atoi(yylvalpp->symbol_name);
- UngetToken(CPP_INTCONSTANT, yylvalpp);
- return 1;
- }
- if (!sym || sym->details.mac.undef) return 0;
- if (sym->details.mac.busy) return 0; // no recursive expansions
- in = malloc(sizeof(*in));
- memset(in, 0, sizeof(*in));
- in->base.scan = (void *)macro_scan;
- in->base.line = cpp->currentInput->line;
- in->base.name = cpp->currentInput->name;
- in->mac = &sym->details.mac;
- if (sym->details.mac.args) {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token != '(') {
- UngetToken(token, yylvalpp);
- yylvalpp->sc_ident = atom;
- return 0;
- }
- in->args = malloc(in->mac->argc * sizeof(TokenStream *));
- for (i=0; i<in->mac->argc; i++)
- in->args[i] = NewTokenStream("macro arg", 0);
- i=0;j=0;
- do{
- depth = 0;
- while(1) {
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token <= 0) {
- StoreStr("EOF in Macro ");
- StoreStr(GetStringOfAtom(atable,atom));
- message=GetStrfromTStr();
- CPPShInfoLogMsg(message);
- ResetTString();
- return 1;
- }
- if((in->mac->argc==0) && (token!=')')) break;
- if (depth == 0 && (token == ',' || token == ')')) break;
- if (token == '(') depth++;
- if (token == ')') depth--;
- RecordToken(in->args[i], token, yylvalpp);
- j=1;
- }
- if (token == ')') {
- if((in->mac->argc==1) &&j==0)
- break;
- i++;
- break;
- }
- i++;
- }while(i < in->mac->argc);
-
- if (i < in->mac->argc) {
- StoreStr("Too few args in Macro ");
- StoreStr(GetStringOfAtom(atable,atom));
- message=GetStrfromTStr();
- CPPShInfoLogMsg(message);
- ResetTString();
- } else if (token != ')') {
- depth=0;
- while (token >= 0 && (depth > 0 || token != ')')) {
- if (token == ')') depth--;
- token = cpp->currentInput->scan(cpp->currentInput, yylvalpp);
- if (token == '(') depth++;
- }
-
- if (token <= 0) {
- StoreStr("EOF in Macro ");
- StoreStr(GetStringOfAtom(atable,atom));
- message=GetStrfromTStr();
- CPPShInfoLogMsg(message);
- ResetTString();
- return 1;
- }
- StoreStr("Too many args in Macro ");
- StoreStr(GetStringOfAtom(atable,atom));
- message=GetStrfromTStr();
- CPPShInfoLogMsg(message);
- ResetTString();
- }
- for (i=0; i<in->mac->argc; i++) {
- in->args[i] = PrescanMacroArg(in->args[i], yylvalpp);
- }
- }
-#if 0
- printf(" <%s:%d>found macro %s\n", GetAtomString(atable, loc.file),
- loc.line, GetAtomString(atable, atom));
- for (i=0; i<in->mac->argc; i++) {
- printf("\targ %s = '", GetAtomString(atable, in->mac->args[i]));
- DumpTokenStream(stdout, in->args[i]);
- printf("'\n");
- }
-#endif
- /*retain the input source*/
- in->base.prev = cpp->currentInput;
- sym->details.mac.busy = 1;
- RewindTokenStream(sym->details.mac.body);
- cpp->currentInput = &in->base;
- return 1;
-} // MacroExpand
-
-int ChkCorrectElseNesting(void)
-{
- // sanity check to make sure elsetracker is in a valid range
- if (cpp->elsetracker < 0 || cpp->elsetracker >= MAX_IF_NESTING) {
- return 0;
- }
-
- if (cpp->elsedepth[cpp->elsetracker] == 0) {
- cpp->elsedepth[cpp->elsetracker] = 1;
- return 1;
- }
- return 0;
-}
-
-
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/cpp.h b/src/3rdparty/angle/src/compiler/preprocessor/cpp.h
deleted file mode 100644
index 802e23ef07..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/cpp.h
+++ /dev/null
@@ -1,86 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-// cpp.h
-//
-
-#if !defined(__CPP_H)
-#define __CPP_H 1
-
-#include "compiler/preprocessor/parser.h"
-#include "compiler/preprocessor/tokens.h"
-
-int InitCPP(void);
-int FinalCPP(void);
-int readCPPline(yystypepp * yylvalpp);
-int MacroExpand(int atom, yystypepp * yylvalpp);
-int ChkCorrectElseNesting(void);
-
-typedef struct MacroSymbol {
- int argc;
- int *args;
- TokenStream *body;
- unsigned busy:1;
- unsigned undef:1;
-} MacroSymbol;
-
-void FreeMacro(MacroSymbol *);
-void PredefineIntMacro(const char *name, int value);
-
-void CPPDebugLogMsg(const char *msg); // Prints information into debug log
-void CPPShInfoLogMsg(const char*); // Store cpp Err Msg into Sh.Info.Log
-void CPPWarningToInfoLog(const char *msg); // Prints warning messages into info log
-void HandlePragma(const char**, int numTokens); // #pragma directive container.
-void ResetTString(void); // #error Message as TString.
-void CPPErrorToInfoLog(const char*); // Stick all cpp errors into Sh.Info.log.
-void StoreStr(const char*); // Store the TString in Parse Context.
-void SetLineNumber(int); // Set line number.
-void SetStringNumber(int); // Set string number.
-int GetLineNumber(void); // Get the current String Number.
-int GetStringNumber(void); // Get the current String Number.
-const char* GetStrfromTStr(void); // Convert TString to String.
-void updateExtensionBehavior(const char* extName, const char* behavior);
-int FreeCPP(void);
-
-#endif // !(defined(__CPP_H)
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/cppstruct.c b/src/3rdparty/angle/src/compiler/preprocessor/cppstruct.c
deleted file mode 100644
index 58cff31091..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/cppstruct.c
+++ /dev/null
@@ -1,152 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-// cppstruct.c
-//
-
-#include <stdio.h>
-#include <stdlib.h>
-
-#include "compiler/preprocessor/slglobals.h"
-
-CPPStruct *cpp = NULL;
-static int refCount = 0;
-
-int InitPreprocessor(void);
-int ResetPreprocessor(void);
-int FreeCPPStruct(void);
-int FinalizePreprocessor(void);
-
-/*
- * InitCPPStruct() - Initilaize the CPP structure.
- *
- */
-
-int InitCPPStruct(void)
-{
- int len;
- char *p;
-
- cpp = (CPPStruct *) malloc(sizeof(CPPStruct));
- if (cpp == NULL)
- return 0;
-
- refCount++;
-
- // Initialize public members:
- cpp->pLastSourceLoc = &cpp->lastSourceLoc;
-
- p = (char *) &cpp->options;
- len = sizeof(cpp->options);
- while (--len >= 0)
- p[len] = 0;
-
- ResetPreprocessor();
- return 1;
-} // InitCPPStruct
-
-int ResetPreprocessor(void)
-{
- // Initialize private members:
-
- cpp->lastSourceLoc.file = 0;
- cpp->lastSourceLoc.line = 0;
- cpp->pC = 0;
- cpp->CompileError = 0;
- cpp->ifdepth = 0;
- for(cpp->elsetracker = 0; cpp->elsetracker < MAX_IF_NESTING; cpp->elsetracker++)
- cpp->elsedepth[cpp->elsetracker] = 0;
- cpp->elsetracker = 0;
- cpp->tokensBeforeEOF = 0;
- return 1;
-}
-
-//Intializing the Preprocessor.
-
-int InitPreprocessor(void)
-{
- # define CPP_STUFF true
- # ifdef CPP_STUFF
- FreeCPPStruct();
- InitCPPStruct();
- cpp->options.Quiet = 1;
- cpp->options.profileString = "generic";
- if (!InitAtomTable(atable, 0))
- return 1;
- if (!InitScanner(cpp))
- return 1;
- # endif
- return 0;
-}
-
-//FreeCPPStruct() - Free the CPP structure.
-
-int FreeCPPStruct(void)
-{
- if (refCount)
- {
- free(cpp);
- refCount--;
- }
-
- return 1;
-}
-
-//Finalizing the Preprocessor.
-
-int FinalizePreprocessor(void)
-{
- # define CPP_STUFF true
- # ifdef CPP_STUFF
- FreeAtomTable(atable);
- FreeCPPStruct();
- FreeScanner();
- # endif
- return 0;
-}
-
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-////////////////////////////////////// End of cppstruct.c //////////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/memory.c b/src/3rdparty/angle/src/compiler/preprocessor/memory.c
deleted file mode 100644
index 029521a559..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/memory.c
+++ /dev/null
@@ -1,158 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-#include <stddef.h>
-#include <stdlib.h>
-#include <string.h>
-
-#ifndef _MSC_VER
-#include <stdint.h>
-#endif
-
-#include "compiler/preprocessor/memory.h"
-
-#if defined(_MSC_VER)
-#pragma warning(disable: 4706)
-#endif
-
-// default alignment and chunksize, if called with 0 arguments
-#define CHUNKSIZE (64*1024)
-#define ALIGN 8
-
-// we need to call the `real' malloc and free, not our replacements
-#undef malloc
-#undef free
-
-struct chunk {
- struct chunk *next;
-};
-
-struct cleanup {
- struct cleanup *next;
- void (*fn)(void *);
- void *arg;
-};
-
-struct MemoryPool_rec {
- struct chunk *next;
- uintptr_t free, end;
- size_t chunksize;
- uintptr_t alignmask;
- struct cleanup *cleanup;
-};
-
-MemoryPool *mem_CreatePool(size_t chunksize, unsigned int align)
-{
- MemoryPool *pool;
-
- if (align == 0) align = ALIGN;
- if (chunksize == 0) chunksize = CHUNKSIZE;
- if (align & (align-1)) return 0;
- if (chunksize < sizeof(MemoryPool)) return 0;
- if (chunksize & (align-1)) return 0;
- if (!(pool = malloc(chunksize))) return 0;
- pool->next = 0;
- pool->chunksize = chunksize;
- pool->alignmask = (uintptr_t)(align)-1;
- pool->free = ((uintptr_t)(pool + 1) + pool->alignmask) & ~pool->alignmask;
- pool->end = (uintptr_t)pool + chunksize;
- pool->cleanup = 0;
- return pool;
-}
-
-void mem_FreePool(MemoryPool *pool)
-{
- struct cleanup *cleanup;
- struct chunk *p, *next;
-
- for (cleanup = pool->cleanup; cleanup; cleanup = cleanup->next) {
- cleanup->fn(cleanup->arg);
- }
- for (p = (struct chunk *)pool; p; p = next) {
- next = p->next;
- free(p);
- }
-}
-
-void *mem_Alloc(MemoryPool *pool, size_t size)
-{
- struct chunk *ch;
- void *rv = (void *)pool->free;
- size = (size + pool->alignmask) & ~pool->alignmask;
- if (size <= 0) size = pool->alignmask;
- pool->free += size;
- if (pool->free > pool->end || pool->free < (uintptr_t)rv) {
- size_t minreq = (size + sizeof(struct chunk) + pool->alignmask)
- & ~pool->alignmask;
- pool->free = (uintptr_t)rv;
- if (minreq >= pool->chunksize) {
- // request size is too big for the chunksize, so allocate it as
- // a single chunk of the right size
- ch = malloc(minreq);
- if (!ch) return 0;
- } else {
- ch = malloc(pool->chunksize);
- if (!ch) return 0;
- pool->free = (uintptr_t)ch + minreq;
- pool->end = (uintptr_t)ch + pool->chunksize;
- }
- ch->next = pool->next;
- pool->next = ch;
- rv = (void *)(((uintptr_t)(ch+1) + pool->alignmask) & ~pool->alignmask);
- }
- return rv;
-}
-
-int mem_AddCleanup(MemoryPool *pool, void (*fn)(void *), void *arg) {
- struct cleanup *cleanup;
-
- pool->free = (pool->free + sizeof(void *) - 1) & ~(sizeof(void *)-1);
- cleanup = mem_Alloc(pool, sizeof(struct cleanup));
- if (!cleanup) return -1;
- cleanup->next = pool->cleanup;
- cleanup->fn = fn;
- cleanup->arg = arg;
- pool->cleanup = cleanup;
- return 0;
-}
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/memory.h b/src/3rdparty/angle/src/compiler/preprocessor/memory.h
deleted file mode 100644
index 5fcadb32f6..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/memory.h
+++ /dev/null
@@ -1,58 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-#ifndef __MEMORY_H
-#define __MEMORY_H
-
-#include <stddef.h>
-
-typedef struct MemoryPool_rec MemoryPool;
-
-extern MemoryPool *mem_CreatePool(size_t chunksize, unsigned int align);
-extern void mem_FreePool(MemoryPool *);
-extern void *mem_Alloc(MemoryPool *p, size_t size);
-extern void *mem_Realloc(MemoryPool *p, void *old, size_t oldsize, size_t newsize);
-extern int mem_AddCleanup(MemoryPool *p, void (*fn)(void *), void *arg);
-
-#endif /* __MEMORY_H */
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/numeric_lex.h b/src/3rdparty/angle/src/compiler/preprocessor/numeric_lex.h
index b04125d230..b04125d230 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/numeric_lex.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/numeric_lex.h
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/parser.h b/src/3rdparty/angle/src/compiler/preprocessor/parser.h
deleted file mode 100644
index f67342b670..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/parser.h
+++ /dev/null
@@ -1,93 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-
-#ifndef BISON_PARSER_H
-# define BISON_PARSER_H
-
-#ifndef yystypepp
-typedef struct {
- int sc_int;
- float sc_fval;
- int sc_ident;
- char symbol_name[MAX_SYMBOL_NAME_LEN+1];
-} yystypepp;
-
-# define YYSTYPE_IS_TRIVIAL 1
-#endif
-# define CPP_AND_OP 257
-# define CPP_SUB_ASSIGN 259
-# define CPP_MOD_ASSIGN 260
-# define CPP_ADD_ASSIGN 261
-# define CPP_DIV_ASSIGN 262
-# define CPP_MUL_ASSIGN 263
-# define CPP_EQ_OP 264
-# define CPP_XOR_OP 265
-# define ERROR_SY 266
-# define CPP_FLOATCONSTANT 267
-# define CPP_GE_OP 268
-# define CPP_RIGHT_OP 269
-# define CPP_IDENTIFIER 270
-# define CPP_INTCONSTANT 271
-# define CPP_LE_OP 272
-# define CPP_LEFT_OP 273
-# define CPP_DEC_OP 274
-# define CPP_NE_OP 275
-# define CPP_OR_OP 276
-# define CPP_INC_OP 277
-# define CPP_STRCONSTANT 278
-# define CPP_TYPEIDENTIFIER 279
-
-# define FIRST_USER_TOKEN_SY 289
-
-# define CPP_RIGHT_ASSIGN 280
-# define CPP_LEFT_ASSIGN 281
-# define CPP_AND_ASSIGN 282
-# define CPP_OR_ASSIGN 283
-# define CPP_XOR_ASSIGN 284
-# define CPP_LEFT_BRACKET 285
-# define CPP_RIGHT_BRACKET 286
-# define CPP_LEFT_BRACE 287
-# define CPP_RIGHT_BRACE 288
-
-#endif /* not BISON_PARSER_H */
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/new/pp_utils.h b/src/3rdparty/angle/src/compiler/preprocessor/pp_utils.h
index 17164ea8b0..17164ea8b0 100644
--- a/src/3rdparty/angle/src/compiler/preprocessor/new/pp_utils.h
+++ b/src/3rdparty/angle/src/compiler/preprocessor/pp_utils.h
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/preprocess.h b/src/3rdparty/angle/src/compiler/preprocessor/preprocess.h
deleted file mode 100644
index 15056da2c9..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/preprocess.h
+++ /dev/null
@@ -1,50 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-
-#include "compiler/preprocessor/slglobals.h"
-extern CPPStruct *cpp;
-int InitCPPStruct(void);
-int InitScanner(CPPStruct *cpp);
-int InitAtomTable(AtomTable *atable, int htsize);
-char* GetStringOfAtom(AtomTable *atable, int atom);
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/scanner.c b/src/3rdparty/angle/src/compiler/preprocessor/scanner.c
deleted file mode 100644
index fde853c1e0..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/scanner.c
+++ /dev/null
@@ -1,698 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-// scanner.c
-//
-
-#include <assert.h>
-#include <stdarg.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-#if 0
- #include <ieeefp.h>
-#else
- #define isinff(x) (((*(int *)&(x) & 0x7f800000L)==0x7f800000L) && \
- ((*(int *)&(x) & 0x007fffffL)==0000000000L))
-#endif
-
-#include "compiler/preprocessor/slglobals.h"
-#include "compiler/util.h"
-
-typedef struct StringInputSrc {
- InputSrc base;
- char *p;
-} StringInputSrc;
-
-static int ScanFromString(const char *s);
-
-static int eof_scan(InputSrc *is, yystypepp * yylvalpp)
-{
- return EOF;
-} // eof_scan
-
-static void noop(InputSrc *in, int ch, yystypepp * yylvalpp) {}
-
-static InputSrc eof_inputsrc = { 0, &eof_scan, &eof_scan, &noop, 0, 0 };
-
-static int byte_scan(InputSrc *, yystypepp * yylvalpp);
-
-#define EOL_SY '\n'
-
-#if defined(_MSC_VER)
- #define DBG_BREAKPOINT() __asm int 3
-#elif defined(_M_AMD64)
- #define DBG_BREAKPOINT() assert(!"Dbg_Breakpoint");
-#else
- #define DBG_BREAKPOINT()
-#endif
-
-#if defined(_MSC_VER) && !defined(_M_AMD64)
- __int64 RDTSC ( void ) {
-
- __int64 v;
-
- __asm __emit 0x0f
- __asm __emit 0x31
- __asm mov dword ptr v, eax
- __asm mov dword ptr v+4, edx
-
- return v;
- }
-#endif
-
-
-int InitScanner(CPPStruct *cpp)
-{
- // Add various atoms needed by the CPP line scanner:
- if (!InitCPP())
- return 0;
-
- cpp->mostRecentToken = 0;
- cpp->tokenLoc = &cpp->ltokenLoc;
-
- cpp->ltokenLoc.file = 0;
- cpp->ltokenLoc.line = 0;
-
- cpp->currentInput = &eof_inputsrc;
- cpp->previous_token = '\n';
- cpp->pastFirstStatement = 0;
-
- return 1;
-} // InitScanner
-
-int FreeScanner(void)
-{
- return (FreeCPP());
-}
-
-int InitScannerInput(CPPStruct *cpp, int count, const char* const string[], const int length[])
-{
- cpp->PaWhichStr = 0;
- cpp->PaArgv = string;
- cpp->PaArgc = count;
- cpp->PaStrLen = length;
- ScanFromString(string[0]);
- return 0;
-}
-
-/*
- * str_getch()
- * takes care of reading from multiple strings.
- * returns the next-char from the input stream.
- * returns EOF when the complete shader is parsed.
- */
-static int str_getch(StringInputSrc *in)
-{
- for(;;){
- if (*in->p){
- if (*in->p == '\n') {
- in->base.line++;
- IncLineNumber();
- }
- return *in->p++;
- }
- if(++(cpp->PaWhichStr) < cpp->PaArgc){
- free(in);
- SetStringNumber(cpp->PaWhichStr);
- SetLineNumber(1);
- ScanFromString(cpp->PaArgv[cpp->PaWhichStr]);
- in=(StringInputSrc*)cpp->currentInput;
- continue;
- }
- else{
- cpp->currentInput = in->base.prev;
- cpp->PaWhichStr=0;
- free(in);
- return EOF;
- }
- }
-} // str_getch
-
-static void str_ungetch(StringInputSrc *in, int ch, yystypepp *type) {
- if (in->p[-1] == ch)in->p--;
- else {
- *(in->p)='\0'; //this would take care of shifting to the previous string.
- cpp->PaWhichStr--;
- }
- if (ch == '\n') {
- in->base.line--;
- DecLineNumber();
- }
-} // str_ungetch
-
-int ScanFromString(const char *s)
-{
-
- StringInputSrc *in = malloc(sizeof(StringInputSrc));
- memset(in, 0, sizeof(StringInputSrc));
- in->p = (char*) s;
- in->base.line = 1;
- in->base.scan = byte_scan;
- in->base.getch = (int (*)(InputSrc *, yystypepp *))str_getch;
- in->base.ungetch = (void (*)(InputSrc *, int, yystypepp *))str_ungetch;
- in->base.prev = cpp->currentInput;
- cpp->currentInput = &in->base;
-
- return 1;
-} // ScanFromString;
-
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-/////////////////////////////////// Floating point constants: /////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
-
-#define APPEND_CHAR_S(ch, str, len, max_len) \
- if (len < max_len) { \
- str[len++] = ch; \
- } else if (!alreadyComplained) { \
- CPPErrorToInfoLog("BUFFER OVERFLOW"); \
- alreadyComplained = 1; \
- }
-
-/*
- * lFloatConst() - Scan a floating point constant. Assumes that the scanner
- * has seen at least one digit, followed by either a decimal '.' or the
- * letter 'e'.
- * ch - '.' or 'e'
- * len - length of string already copied into yylvalpp->symbol_name.
- */
-
-static int lFloatConst(int ch, int len, yystypepp * yylvalpp)
-{
- int alreadyComplained = 0;
- assert((ch == '.') || (ch == 'e') || (ch == 'E'));
-
- if (ch == '.') {
- do {
- APPEND_CHAR_S(ch, yylvalpp->symbol_name, len, MAX_SYMBOL_NAME_LEN);
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- } while (ch >= '0' && ch <= '9');
- }
-
- // Exponent:
- if (ch == 'e' || ch == 'E') {
- APPEND_CHAR_S(ch, yylvalpp->symbol_name, len, MAX_SYMBOL_NAME_LEN);
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '+') {
- APPEND_CHAR_S(ch, yylvalpp->symbol_name, len, MAX_SYMBOL_NAME_LEN);
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- } else if (ch == '-') {
- APPEND_CHAR_S(ch, yylvalpp->symbol_name, len, MAX_SYMBOL_NAME_LEN);
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- }
- if (ch >= '0' && ch <= '9') {
- while (ch >= '0' && ch <= '9') {
- APPEND_CHAR_S(ch, yylvalpp->symbol_name, len, MAX_SYMBOL_NAME_LEN);
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- }
- } else {
- CPPErrorToInfoLog("EXPONENT INVALID");
- }
- }
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
-
- assert(len <= MAX_SYMBOL_NAME_LEN);
- yylvalpp->symbol_name[len] = '\0';
- yylvalpp->sc_fval = (float) atof_dot(yylvalpp->symbol_name);
- if (isinff(yylvalpp->sc_fval)) {
- CPPErrorToInfoLog("FLOAT CONSTANT OVERFLOW");
- }
- return CPP_FLOATCONSTANT;
-} // lFloatConst
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-///////////////////////////////////////// Normal Scanner //////////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
-
-static int byte_scan(InputSrc *in, yystypepp * yylvalpp)
-{
- char string_val[MAX_STRING_LEN + 1];
- int alreadyComplained = 0;
- int len, ch, ii, ival = 0;
-
- for (;;) {
- yylvalpp->sc_int = 0;
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
-
- while (ch == ' ' || ch == '\t' || ch == '\r') {
- yylvalpp->sc_int = 1;
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- }
-
- cpp->ltokenLoc.file = cpp->currentInput->name;
- cpp->ltokenLoc.line = cpp->currentInput->line;
- alreadyComplained = 0;
- len = 0;
- switch (ch) {
- default:
- return ch; // Single character token
- case EOF:
- return -1;
- case 'A': case 'B': case 'C': case 'D': case 'E':
- case 'F': case 'G': case 'H': case 'I': case 'J':
- case 'K': case 'L': case 'M': case 'N': case 'O':
- case 'P': case 'Q': case 'R': case 'S': case 'T':
- case 'U': case 'V': case 'W': case 'X': case 'Y':
- case 'Z': case '_':
- case 'a': case 'b': case 'c': case 'd': case 'e':
- case 'f': case 'g': case 'h': case 'i': case 'j':
- case 'k': case 'l': case 'm': case 'n': case 'o':
- case 'p': case 'q': case 'r': case 's': case 't':
- case 'u': case 'v': case 'w': case 'x': case 'y':
- case 'z':
- do {
- APPEND_CHAR_S(ch, yylvalpp->symbol_name, len, MAX_SYMBOL_NAME_LEN);
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- } while ((ch >= 'a' && ch <= 'z') ||
- (ch >= 'A' && ch <= 'Z') ||
- (ch >= '0' && ch <= '9') ||
- ch == '_');
- assert(len <= MAX_SYMBOL_NAME_LEN);
- yylvalpp->symbol_name[len] = '\0';
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- yylvalpp->sc_ident = LookUpAddString(atable, yylvalpp->symbol_name);
- return CPP_IDENTIFIER;
- break;
- case '0':
- APPEND_CHAR_S(ch, yylvalpp->symbol_name, len, MAX_SYMBOL_NAME_LEN);
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == 'x' || ch == 'X') { // hexadecimal integer constants
- APPEND_CHAR_S(ch, yylvalpp->symbol_name, len, MAX_SYMBOL_NAME_LEN);
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if ((ch >= '0' && ch <= '9') ||
- (ch >= 'A' && ch <= 'F') ||
- (ch >= 'a' && ch <= 'f'))
- {
- ival = 0;
- do {
- if ((ival <= 0x0fffffff) && (len < MAX_SYMBOL_NAME_LEN)) {
- yylvalpp->symbol_name[len++] = ch;
- if (ch >= '0' && ch <= '9') {
- ii = ch - '0';
- } else if (ch >= 'A' && ch <= 'F') {
- ii = ch - 'A' + 10;
- } else {
- ii = ch - 'a' + 10;
- }
- ival = (ival << 4) | ii;
- } else if (!alreadyComplained) {
- CPPErrorToInfoLog("HEX CONSTANT OVERFLOW");
- alreadyComplained = 1;
- }
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- } while ((ch >= '0' && ch <= '9') ||
- (ch >= 'A' && ch <= 'F') ||
- (ch >= 'a' && ch <= 'f'));
- } else {
- CPPErrorToInfoLog("HEX CONSTANT INVALID");
- }
- assert(len <= MAX_SYMBOL_NAME_LEN);
- yylvalpp->symbol_name[len] = '\0';
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- yylvalpp->sc_int = ival;
- return CPP_INTCONSTANT;
- } else if (ch >= '0' && ch <= '7') { // octal integer constants
- ival = 0;
- do {
- if ((ival <= 0x1fffffff) && (len < MAX_SYMBOL_NAME_LEN)) {
- yylvalpp->symbol_name[len++] = ch;
- ii = ch - '0';
- ival = (ival << 3) | ii;
- } else if (!alreadyComplained) {
- CPPErrorToInfoLog("OCT CONSTANT OVERFLOW");
- alreadyComplained = 1;
- }
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- } while (ch >= '0' && ch <= '7');
- if (ch == '.' || ch == 'e' || ch == 'f' || ch == 'h' || ch == 'x'|| ch == 'E')
- return lFloatConst(ch, len, yylvalpp);
- assert(len <= MAX_SYMBOL_NAME_LEN);
- yylvalpp->symbol_name[len] = '\0';
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- yylvalpp->sc_int = ival;
- return CPP_INTCONSTANT;
- } else {
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- ch = '0';
- }
- // Fall through...
- case '1': case '2': case '3': case '4':
- case '5': case '6': case '7': case '8': case '9':
- do {
- APPEND_CHAR_S(ch, yylvalpp->symbol_name, len, MAX_SYMBOL_NAME_LEN);
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- } while (ch >= '0' && ch <= '9');
- if (ch == '.' || ch == 'e' || ch == 'E') {
- return lFloatConst(ch, len, yylvalpp);
- } else {
- assert(len <= MAX_SYMBOL_NAME_LEN);
- yylvalpp->symbol_name[len] = '\0';
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- ival = 0;
- for (ii = 0; ii < len; ii++) {
- ch = yylvalpp->symbol_name[ii] - '0';
- ival = ival*10 + ch;
- if ((ival > 214748364) || (ival == 214748364 && ch >= 8)) {
- CPPErrorToInfoLog("INTEGER CONSTANT OVERFLOW");
- break;
- }
- }
- yylvalpp->sc_int = ival;
- if(ival==0)
- strcpy(yylvalpp->symbol_name,"0");
- return CPP_INTCONSTANT;
- }
- break;
- case '-':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '-') {
- return CPP_DEC_OP;
- } else if (ch == '=') {
- return CPP_SUB_ASSIGN;
- } else {
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '-';
- }
- case '+':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '+') {
- return CPP_INC_OP;
- } else if (ch == '=') {
- return CPP_ADD_ASSIGN;
- } else {
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '+';
- }
- case '*':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '=') {
- return CPP_MUL_ASSIGN;
- } else {
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '*';
- }
- case '%':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '=') {
- return CPP_MOD_ASSIGN;
- } else if (ch == '>'){
- return CPP_RIGHT_BRACE;
- } else {
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '%';
- }
- case ':':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '>') {
- return CPP_RIGHT_BRACKET;
- } else {
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return ':';
- }
- case '^':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '^') {
- return CPP_XOR_OP;
- } else {
- if (ch == '=')
- return CPP_XOR_ASSIGN;
- else{
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '^';
- }
- }
-
- case '=':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '=') {
- return CPP_EQ_OP;
- } else {
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '=';
- }
- case '!':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '=') {
- return CPP_NE_OP;
- } else {
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '!';
- }
- case '|':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '|') {
- return CPP_OR_OP;
- } else {
- if (ch == '=')
- return CPP_OR_ASSIGN;
- else{
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '|';
- }
- }
- case '&':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '&') {
- return CPP_AND_OP;
- } else {
- if (ch == '=')
- return CPP_AND_ASSIGN;
- else{
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '&';
- }
- }
- case '<':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '<') {
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if(ch == '=')
- return CPP_LEFT_ASSIGN;
- else{
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return CPP_LEFT_OP;
- }
- } else {
- if (ch == '=') {
- return CPP_LE_OP;
- } else {
- if (ch == '%')
- return CPP_LEFT_BRACE;
- else if (ch == ':')
- return CPP_LEFT_BRACKET;
- else{
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '<';
- }
- }
- }
- case '>':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '>') {
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if(ch == '=')
- return CPP_RIGHT_ASSIGN;
- else{
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return CPP_RIGHT_OP;
- }
- } else {
- if (ch == '=') {
- return CPP_GE_OP;
- } else {
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '>';
- }
- }
- case '.':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch >= '0' && ch <= '9') {
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return lFloatConst('.', 0, yylvalpp);
- } else {
- if (ch == '.') {
- return -1; // Special EOF hack
- } else {
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '.';
- }
- }
- case '/':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == '/') {
- do {
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- } while (ch != '\n' && ch != EOF);
- if (ch == EOF)
- return -1;
- return '\n';
- } else if (ch == '*') {
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- do {
- while (ch != '*') {
- if (ch == EOF) {
- CPPErrorToInfoLog("EOF IN COMMENT");
- return -1;
- }
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- }
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- if (ch == EOF) {
- CPPErrorToInfoLog("EOF IN COMMENT");
- return -1;
- }
- } while (ch != '/');
- // Go try it again...
- } else if (ch == '=') {
- return CPP_DIV_ASSIGN;
- } else {
- cpp->currentInput->ungetch(cpp->currentInput, ch, yylvalpp);
- return '/';
- }
- break;
- case '"':
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- while (ch != '"' && ch != '\n' && ch != EOF) {
- if (ch == '\\') {
- CPPErrorToInfoLog("The line continuation character (\\) is not part of the OpenGL ES Shading Language");
- return -1;
- }
- APPEND_CHAR_S(ch, string_val, len, MAX_STRING_LEN);
- ch = cpp->currentInput->getch(cpp->currentInput, yylvalpp);
- };
- assert(len <= MAX_STRING_LEN);
- string_val[len] = '\0';
- if (ch == '"') {
- yylvalpp->sc_ident = LookUpAddString(atable, string_val);
- return CPP_STRCONSTANT;
- } else {
- CPPErrorToInfoLog("EOL IN STRING");
- return ERROR_SY;
- }
- break;
- }
- }
-} // byte_scan
-
-int yylex_CPP(char* buf, int maxSize)
-{
- yystypepp yylvalpp;
- int token = '\n';
-
- for(;;) {
-
- char* tokenString = 0;
- token = cpp->currentInput->scan(cpp->currentInput, &yylvalpp);
- if(check_EOF(token))
- return 0;
- if (token < 0) {
- // This check may need to be improved to support UTF-8
- // characters in comments.
- CPPErrorToInfoLog("preprocessor encountered non-ASCII character in shader source");
- return 0;
- }
- if (token == '#') {
- if (cpp->previous_token == '\n'|| cpp->previous_token == 0) {
- token = readCPPline(&yylvalpp);
- if(check_EOF(token))
- return 0;
- continue;
- } else {
- CPPErrorToInfoLog("preprocessor command must not be preceded by any other statement in that line");
- return 0;
- }
- }
- cpp->previous_token = token;
- // expand macros
- if (token == CPP_IDENTIFIER && MacroExpand(yylvalpp.sc_ident, &yylvalpp)) {
- cpp->pastFirstStatement = 1;
- continue;
- }
-
- if (token == '\n')
- continue;
- cpp->pastFirstStatement = 1;
-
- if (token == CPP_IDENTIFIER) {
- tokenString = GetStringOfAtom(atable,yylvalpp.sc_ident);
- } else if (token == CPP_FLOATCONSTANT || token == CPP_INTCONSTANT){
- tokenString = yylvalpp.symbol_name;
- } else {
- tokenString = GetStringOfAtom(atable,token);
- }
-
- if (tokenString) {
- int len = strlen(tokenString);
- cpp->tokensBeforeEOF = 1;
- if (len >= maxSize) {
- return maxSize;
- } else if (len > 0) {
- strcpy(buf, tokenString);
- return len;
- }
-
- return 0;
- }
- }
-} // yylex
-
-//Checks if the token just read is EOF or not.
-int check_EOF(int token)
-{
- if(token==-1){
- if(cpp->ifdepth >0){
- CPPErrorToInfoLog("#endif missing!! Compilation stopped");
- cpp->CompileError=1;
- }
- return 1;
- }
- return 0;
-}
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-/////////////////////////////////////// End of scanner.c //////////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
-
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/scanner.h b/src/3rdparty/angle/src/compiler/preprocessor/scanner.h
deleted file mode 100644
index b67c1d644e..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/scanner.h
+++ /dev/null
@@ -1,81 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-// scanner.h
-//
-
-#if !defined(__SCANNER_H)
-#define __SCANNER_H 1
-
-#include "compiler/preprocessor/length_limits.h"
-#include "compiler/preprocessor/parser.h"
-
-// Not really atom table stuff but needed first...
-
-typedef struct SourceLoc_Rec {
- unsigned short file, line;
-} SourceLoc;
-
-int yylex_CPP(char* buf, int maxSize);
-
-typedef struct InputSrc {
- struct InputSrc *prev;
- int (*scan)(struct InputSrc *, yystypepp *);
- int (*getch)(struct InputSrc *, yystypepp *);
- void (*ungetch)(struct InputSrc *, int, yystypepp *);
- int name; /* atom */
- int line;
-} InputSrc;
-
-int InitScanner(CPPStruct *cpp); // Intialise the cpp scanner.
-int InitScannerInput(CPPStruct *cpp, int count, const char* const string[], const int length[]);
-int check_EOF(int); // check if we hit a EOF abruptly
-void CPPErrorToInfoLog(const char *); // sticking the msg,line into the Shader's.Info.log
-void SetLineNumber(int);
-void SetStringNumber(int);
-void IncLineNumber(void);
-void DecLineNumber(void);
-int FreeScanner(void); // Free the cpp scanner
-#endif // !(defined(__SCANNER_H)
-
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/slglobals.h b/src/3rdparty/angle/src/compiler/preprocessor/slglobals.h
deleted file mode 100644
index 4634626643..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/slglobals.h
+++ /dev/null
@@ -1,82 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-// slglobals.h
-//
-
-#if !defined(__SLGLOBALS_H)
-#define __SLGLOBALS_H 1
-
-typedef struct CPPStruct_Rec CPPStruct;
-
-extern CPPStruct *cpp;
-
-#undef CPPC_DEBUG_THE_COMPILER
-#if defined(_DEBUG)
-#define CPPC_DEBUG_THE_COMPILER 1
-#endif
-
-#undef CPPC_ENABLE_TOOLS
-#define CPPC_ENABLE_TOOLS 1
-
-#include "compiler/preprocessor/memory.h"
-#include "compiler/preprocessor/atom.h"
-#include "compiler/preprocessor/scanner.h"
-#include "compiler/preprocessor/cpp.h"
-#include "compiler/preprocessor/tokens.h"
-#include "compiler/preprocessor/symbols.h"
-#include "compiler/preprocessor/compile.h"
-#if !defined(NO_PARSER)
-#include "compiler/preprocessor/parser.h"
-#endif
-
-#if !defined(NULL)
-#define NULL 0
-#endif
-
-#endif // !(defined(__SLGLOBALS_H)
-
-
-
-
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/symbols.c b/src/3rdparty/angle/src/compiler/preprocessor/symbols.c
deleted file mode 100644
index f18b2569b3..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/symbols.c
+++ /dev/null
@@ -1,288 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-// symbols.c
-//
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <string.h>
-
-#include "compiler/preprocessor/slglobals.h"
-
-#if defined(_MSC_VER)
-#pragma warning(disable: 4706)
-#endif
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-/////////////////////////////////// Symbol Table Variables: ///////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
-
-Scope *ScopeList = NULL;
-Scope *CurrentScope = NULL;
-Scope *GlobalScope = NULL;
-
-static void unlinkScope(void *_scope) {
- Scope *scope = _scope;
-
- if (scope->next)
- scope->next->prev = scope->prev;
- if (scope->prev)
- scope->prev->next = scope->next;
- else
- ScopeList = scope->next;
-}
-
-/*
- * NewScope()
- *
- */
-Scope *NewScopeInPool(MemoryPool *pool)
-{
- Scope *lScope;
-
- lScope = mem_Alloc(pool, sizeof(Scope));
- lScope->pool = pool;
- lScope->parent = NULL;
- lScope->funScope = NULL;
- lScope->symbols = NULL;
-
- lScope->level = 0;
-
- lScope->programs = NULL;
- if ((lScope->next = ScopeList))
- ScopeList->prev = lScope;
- lScope->prev = 0;
- ScopeList = lScope;
- mem_AddCleanup(pool, unlinkScope, lScope);
- return lScope;
-} // NewScope
-
-/*
- * PushScope()
- *
- */
-
-void PushScope(Scope *fScope)
-{
- Scope *lScope;
-
- if (CurrentScope) {
- fScope->level = CurrentScope->level + 1;
- if (fScope->level == 1) {
- if (!GlobalScope) {
- /* HACK - CTD -- if GlobalScope==NULL and level==1, we're
- * defining a function in the superglobal scope. Things
- * will break if we leave the level as 1, so we arbitrarily
- * set it to 2 */
- fScope->level = 2;
- }
- }
- if (fScope->level >= 2) {
- lScope = fScope;
- while (lScope->level > 2)
- lScope = lScope->next;
- fScope->funScope = lScope;
- }
- } else {
- fScope->level = 0;
- }
- fScope->parent = CurrentScope;
- CurrentScope = fScope;
-} // PushScope
-
-/*
- * PopScope()
- *
- */
-
-Scope *PopScope(void)
-{
- Scope *lScope;
-
- lScope = CurrentScope;
- if (CurrentScope)
- CurrentScope = CurrentScope->parent;
- return lScope;
-} // PopScope
-
-/*
- * NewSymbol() - Allocate a new symbol node;
- *
- */
-
-Symbol *NewSymbol(SourceLoc *loc, Scope *fScope, int name, symbolkind kind)
-{
- Symbol *lSymb;
- char *pch;
- unsigned int ii;
-
- lSymb = (Symbol *) mem_Alloc(fScope->pool, sizeof(Symbol));
- lSymb->left = NULL;
- lSymb->right = NULL;
- lSymb->next = NULL;
- lSymb->name = name;
- lSymb->loc = *loc;
- lSymb->kind = kind;
-
- // Clear union area:
-
- pch = (char *) &lSymb->details;
- for (ii = 0; ii < sizeof(lSymb->details); ii++)
- *pch++ = 0;
- return lSymb;
-} // NewSymbol
-
-/*
- * lAddToTree() - Using a binary tree is not a good idea for basic atom values because they
- * are generated in order. We'll fix this later (by reversing the bit pattern).
- */
-
-static void lAddToTree(Symbol **fSymbols, Symbol *fSymb)
-{
- Symbol *lSymb;
- int lrev, frev;
-
- lSymb = *fSymbols;
- if (lSymb) {
- frev = GetReversedAtom(atable, fSymb->name);
- while (lSymb) {
- lrev = GetReversedAtom(atable, lSymb->name);
- if (lrev == frev) {
- CPPErrorToInfoLog("GetAtomString(atable, fSymb->name)");
- break;
- } else {
- if (lrev > frev) {
- if (lSymb->left) {
- lSymb = lSymb->left;
- } else {
- lSymb->left = fSymb;
- break;
- }
- } else {
- if (lSymb->right) {
- lSymb = lSymb->right;
- } else {
- lSymb->right = fSymb;
- break;
- }
- }
- }
- }
- } else {
- *fSymbols = fSymb;
- }
-} // lAddToTree
-
-
-/*
- * AddSymbol() - Add a variable, type, or function name to a scope.
- *
- */
-
-Symbol *AddSymbol(SourceLoc *loc, Scope *fScope, int atom, symbolkind kind)
-{
- Symbol *lSymb;
-
- if (!fScope)
- fScope = CurrentScope;
- lSymb = NewSymbol(loc, fScope, atom, kind);
- lAddToTree(&fScope->symbols, lSymb);
- return lSymb;
-} // AddSymbol
-
-
-/*********************************************************************************************/
-/************************************ Symbol Semantic Functions ******************************/
-/*********************************************************************************************/
-
-/*
- * LookUpLocalSymbol()
- *
- */
-
-Symbol *LookUpLocalSymbol(Scope *fScope, int atom)
-{
- Symbol *lSymb;
- int rname, ratom;
-
- ratom = GetReversedAtom(atable, atom);
- if (!fScope)
- fScope = CurrentScope;
- lSymb = fScope->symbols;
- while (lSymb) {
- rname = GetReversedAtom(atable, lSymb->name);
- if (rname == ratom) {
- return lSymb;
- } else {
- if (rname > ratom) {
- lSymb = lSymb->left;
- } else {
- lSymb = lSymb->right;
- }
- }
- }
- return NULL;
-} // LookUpLocalSymbol
-
-/*
- * LookUpSymbol()
- *
- */
-
-Symbol *LookUpSymbol(Scope *fScope, int atom)
-{
- Symbol *lSymb;
-
- if (!fScope)
- fScope = CurrentScope;
- while (fScope) {
- lSymb = LookUpLocalSymbol(fScope, atom);
- if (lSymb)
- return lSymb;
- fScope = fScope->parent;
- }
- return NULL;
-} // LookUpSymbol
-
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/symbols.h b/src/3rdparty/angle/src/compiler/preprocessor/symbols.h
deleted file mode 100644
index e7d0b075fa..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/symbols.h
+++ /dev/null
@@ -1,111 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-// symbols.h
-//
-
-#if !defined(__SYMBOLS_H)
-#define __SYMBOLS_H 1
-
-#include "compiler/preprocessor/memory.h"
-
-typedef enum symbolkind {
- MACRO_S
-} symbolkind;
-
-// Typedefs for things defined here in "symbols.h":
-
-typedef struct Scope_Rec Scope;
-typedef struct Symbol_Rec Symbol;
-
-typedef struct SymbolList_Rec {
- struct SymbolList_Rec *next;
- Symbol *symb;
-} SymbolList;
-
-struct Scope_Rec {
- Scope *next, *prev; // doubly-linked list of all scopes
- Scope *parent;
- Scope *funScope; // Points to base scope of enclosing function
- MemoryPool *pool; // pool used for allocation in this scope
- Symbol *symbols;
-
- int level; // 0 = super globals, 1 = globals, etc.
-
- // Only used at global scope (level 1):
- SymbolList *programs; // List of programs for this compilation.
-};
-
-
-// Symbol table is a simple binary tree.
-
-#include "compiler/preprocessor/cpp.h" // to get MacroSymbol def
-
-struct Symbol_Rec {
- Symbol *left, *right;
- Symbol *next;
- int name; // Name atom
- SourceLoc loc;
- symbolkind kind;
- union {
- MacroSymbol mac;
- } details;
-};
-
-extern Scope *CurrentScope;
-extern Scope *GlobalScope;
-extern Scope *ScopeList;
-
-Scope *NewScopeInPool(MemoryPool *);
-#define NewScope() NewScopeInPool(CurrentScope->pool)
-void PushScope(Scope *fScope);
-Scope *PopScope(void);
-Symbol *NewSymbol(SourceLoc *loc, Scope *fScope, int name, symbolkind kind);
-Symbol *AddSymbol(SourceLoc *loc, Scope *fScope, int atom, symbolkind kind);
-Symbol *LookUpLocalSymbol(Scope *fScope, int atom);
-Symbol *LookUpSymbol(Scope *fScope, int atom);
-
-
-#endif // !defined(__SYMBOLS_H)
-
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/tokens.c b/src/3rdparty/angle/src/compiler/preprocessor/tokens.c
deleted file mode 100644
index b94c05ebd4..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/tokens.c
+++ /dev/null
@@ -1,467 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-// tokens.c
-//
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <string.h>
-#include <ctype.h>
-
-#include "common/angleutils.h"
-#include "compiler/debug.h"
-#include "compiler/preprocessor/slglobals.h"
-#include "compiler/util.h"
-
-#if defined(_MSC_VER)
-#pragma warning(disable: 4054)
-#pragma warning(disable: 4152)
-#endif
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-//////////////////////// Preprocessor and Token Recorder and Playback: ////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
-
-/*
- * idstr()
- * Copy a string to a malloc'ed block and convert it into something suitable
- * for an ID
- *
- */
-
-static char *idstr(const char *fstr, MemoryPool *pool)
-{
- size_t len;
- char *str, *t;
- const char *f;
-
- len = strlen(fstr);
- if (!pool)
- str = (char *) malloc(len + 1);
- else
- str = (char *) mem_Alloc(pool, len + 1);
-
- for (f=fstr, t=str; *f; f++) {
- if (isalnum(*f)) *t++ = *f;
- else if (*f == '.' || *f == '/') *t++ = '_';
- }
- *t = 0;
- return str;
-} // idstr
-
-
-/*
- * lNewBlock()
- *
- */
-
-static TokenBlock *lNewBlock(TokenStream *fTok, MemoryPool *pool)
-{
- TokenBlock *lBlock;
-
- if (!pool)
- lBlock = (TokenBlock *) malloc(sizeof(TokenBlock) + 256);
- else
- lBlock = (TokenBlock *) mem_Alloc(pool, sizeof(TokenBlock) + 256);
- lBlock->count = 0;
- lBlock->current = 0;
- lBlock->data = (unsigned char *) lBlock + sizeof(TokenBlock);
- lBlock->max = 256;
- lBlock->next = NULL;
- if (fTok->head) {
- fTok->current->next = lBlock;
- } else {
- fTok->head = lBlock;
- }
- fTok->current = lBlock;
- return lBlock;
-} // lNewBlock
-
-/*
- * lAddByte()
- *
- */
-
-static void lAddByte(TokenStream *fTok, unsigned char fVal)
-{
- TokenBlock *lBlock;
- lBlock = fTok->current;
- if (lBlock->count >= lBlock->max)
- lBlock = lNewBlock(fTok, 0);
- lBlock->data[lBlock->count++] = fVal;
-} // lAddByte
-
-
-
-/*
- * lReadByte() - Get the next byte from a stream.
- *
- */
-
-static int lReadByte(TokenStream *pTok)
-{
- TokenBlock *lBlock;
- int lval = -1;
-
- lBlock = pTok->current;
- if (lBlock) {
- if (lBlock->current >= lBlock->count) {
- lBlock = lBlock->next;
- if (lBlock)
- lBlock->current = 0;
- pTok->current = lBlock;
- }
- if (lBlock)
- lval = lBlock->data[lBlock->current++];
- }
- return lval;
-} // lReadByte
-
-/////////////////////////////////////// Global Functions://////////////////////////////////////
-
-/*
- * NewTokenStream()
- *
- */
-
-TokenStream *NewTokenStream(const char *name, MemoryPool *pool)
-{
- TokenStream *pTok;
-
- if (!pool)
- pTok = (TokenStream *) malloc(sizeof(TokenStream));
- else
- pTok = (TokenStream*)mem_Alloc(pool, sizeof(TokenStream));
- pTok->next = NULL;
- pTok->name = idstr(name, pool);
- pTok->head = NULL;
- pTok->current = NULL;
- lNewBlock(pTok, pool);
- return pTok;
-} // NewTokenStream
-
-/*
- * DeleteTokenStream()
- *
- */
-
-void DeleteTokenStream(TokenStream *pTok)
-{
- TokenBlock *pBlock, *nBlock;
-
- if (pTok) {
- pBlock = pTok->head;
- while (pBlock) {
- nBlock = pBlock->next;
- free(pBlock);
- pBlock = nBlock;
- }
- if (pTok->name)
- free(pTok->name);
- free(pTok);
- }
-} // DeleteTokenStream
-
-/*
- * RecordToken() - Add a token to the end of a list for later playback or printout.
- *
- */
-
-void RecordToken(TokenStream *pTok, int token, yystypepp * yylvalpp)
-{
- const char *s;
- char *str=NULL;
-
- if (token > 256)
- lAddByte(pTok, (unsigned char)((token & 0x7f) + 0x80));
- else
- lAddByte(pTok, (unsigned char)(token & 0x7f));
- switch (token) {
- case CPP_IDENTIFIER:
- case CPP_TYPEIDENTIFIER:
- case CPP_STRCONSTANT:
- s = GetAtomString(atable, yylvalpp->sc_ident);
- while (*s)
- lAddByte(pTok, (unsigned char) *s++);
- lAddByte(pTok, 0);
- break;
- case CPP_FLOATCONSTANT:
- case CPP_INTCONSTANT:
- str=yylvalpp->symbol_name;
- while (*str){
- lAddByte(pTok, (unsigned char) *str++);
- }
- lAddByte(pTok, 0);
- break;
- case '(':
- lAddByte(pTok, (unsigned char)(yylvalpp->sc_int ? 1 : 0));
- default:
- break;
- }
-} // RecordToken
-
-/*
- * RewindTokenStream() - Reset a token stream in preperation for reading.
- *
- */
-
-void RewindTokenStream(TokenStream *pTok)
-{
- if (pTok->head) {
- pTok->current = pTok->head;
- pTok->current->current = 0;
- }
-} // RewindTokenStream
-
-/*
- * ReadToken() - Read the next token from a stream.
- *
- */
-
-int ReadToken(TokenStream *pTok, yystypepp * yylvalpp)
-{
- char symbol_name[MAX_SYMBOL_NAME_LEN + 1];
- char string_val[MAX_STRING_LEN + 1];
- int ltoken, len;
- char ch;
- int base, accum;
- char ch_val;
-
- ltoken = lReadByte(pTok);
- if (ltoken >= 0) {
- if (ltoken > 127)
- ltoken += 128;
- switch (ltoken) {
- case CPP_IDENTIFIER:
- case CPP_TYPEIDENTIFIER:
- len = 0;
- ch = lReadByte(pTok);
- while ((ch >= 'a' && ch <= 'z') ||
- (ch >= 'A' && ch <= 'Z') ||
- (ch >= '0' && ch <= '9') ||
- ch == '_')
- {
- if (len < MAX_SYMBOL_NAME_LEN) {
- symbol_name[len++] = ch;
- ch = lReadByte(pTok);
- }
- }
- symbol_name[len] = '\0';
- assert(ch == '\0');
- yylvalpp->sc_ident = LookUpAddString(atable, symbol_name);
- return CPP_IDENTIFIER;
- break;
- case CPP_STRCONSTANT:
- len = 0;
- while ((ch = lReadByte(pTok)) != 0)
- if (len < MAX_STRING_LEN)
- string_val[len++] = ch;
- string_val[len] = '\0';
- yylvalpp->sc_ident = LookUpAddString(atable, string_val);
- break;
- case CPP_FLOATCONSTANT:
- len = 0;
- ch = lReadByte(pTok);
- while ((ch >= '0' && ch <= '9')||(ch=='e'||ch=='E'||ch=='.')||(ch=='+'||ch=='-'))
- {
- if (len < MAX_SYMBOL_NAME_LEN) {
- symbol_name[len++] = ch;
- ch = lReadByte(pTok);
- }
- }
- symbol_name[len] = '\0';
- assert(ch == '\0');
- strcpy(yylvalpp->symbol_name,symbol_name);
- yylvalpp->sc_fval=(float)atof_dot(yylvalpp->symbol_name);
- break;
- case CPP_INTCONSTANT:
- len = 0;
- accum = 0;
- ch = lReadByte(pTok);
- if (ch == '0') {
- symbol_name[len++] = ch;
- ch = lReadByte(pTok);
- if (ch == 'x' || ch == 'X') {
- symbol_name[len++] = ch;
- base = 16;
- ch = lReadByte(pTok);
- } else {
- base = 8;
- }
- } else {
- base = 10;
- }
-
- while (len < MAX_SYMBOL_NAME_LEN)
- {
- ch_val = -1;
- if (isdigit(ch))
- ch_val = ch - '0';
- else if (isxdigit(ch))
- ch_val = tolower(ch) - 'a' + 10;
-
- if (ch_val < 0 || ch_val >= base)
- break;
-
- symbol_name[len++] = ch;
- accum = accum * base + ch_val;
- ch = lReadByte(pTok);
- }
- symbol_name[len] = '\0';
- assert(ch == '\0');
- strcpy(yylvalpp->symbol_name, symbol_name);
- yylvalpp->sc_int = accum;
- break;
- case '(':
- yylvalpp->sc_int = lReadByte(pTok);
- break;
- }
- return ltoken;
- }
- return EOF_SY;
-} // ReadToken
-
-typedef struct TokenInputSrc {
- InputSrc base;
- TokenStream *tokens;
- int (*final)(CPPStruct *);
-} TokenInputSrc;
-
-static int scan_token(TokenInputSrc *in, yystypepp * yylvalpp)
-{
- int token = ReadToken(in->tokens, yylvalpp);
- int (*final)(CPPStruct *);
- cpp->tokenLoc->file = cpp->currentInput->name;
- cpp->tokenLoc->line = cpp->currentInput->line;
- if (token == '\n') {
- in->base.line++;
- return token;
- }
- if (token > 0) return token;
- cpp->currentInput = in->base.prev;
- final = in->final;
- free(in);
- if (final && !final(cpp)) return -1;
- return cpp->currentInput->scan(cpp->currentInput, yylvalpp);
-}
-
-int ReadFromTokenStream(TokenStream *ts, int name, int (*final)(CPPStruct *))
-{
- TokenInputSrc *in = malloc(sizeof(TokenInputSrc));
- memset(in, 0, sizeof(TokenInputSrc));
- in->base.name = name;
- in->base.prev = cpp->currentInput;
- in->base.scan = (int (*)(InputSrc *, yystypepp *))scan_token;
- in->base.line = 1;
- in->tokens = ts;
- in->final = final;
- RewindTokenStream(ts);
- cpp->currentInput = &in->base;
- return 1;
-}
-
-typedef struct UngotToken {
- InputSrc base;
- int token;
- yystypepp lval;
-} UngotToken;
-
-static int reget_token(UngotToken *t, yystypepp * yylvalpp)
-{
- int token = t->token;
- *yylvalpp = t->lval;
- cpp->currentInput = t->base.prev;
- free(t);
- return token;
-}
-
-void UngetToken(int token, yystypepp * yylvalpp) {
- UngotToken *t = malloc(sizeof(UngotToken));
- memset(t, 0, sizeof(UngotToken));
- t->token = token;
- t->lval = *yylvalpp;
- t->base.scan = (void *)reget_token;
- t->base.prev = cpp->currentInput;
- t->base.name = cpp->currentInput->name;
- t->base.line = cpp->currentInput->line;
- cpp->currentInput = &t->base;
-}
-
-
-void DumpTokenStream(FILE *fp, TokenStream *s, yystypepp * yylvalpp) {
- int token;
- char str[100];
-
- if (fp == 0) fp = stdout;
- RewindTokenStream(s);
- while ((token = ReadToken(s, yylvalpp)) > 0) {
- switch (token) {
- case CPP_IDENTIFIER:
- case CPP_TYPEIDENTIFIER:
- snprintf(str, sizeof(str), "%s ", GetAtomString(atable, yylvalpp->sc_ident));
- break;
- case CPP_STRCONSTANT:
- snprintf(str, sizeof(str), "\"%s\"", GetAtomString(atable, yylvalpp->sc_ident));
- break;
- case CPP_FLOATCONSTANT:
- //printf("%g9.6 ", yylvalpp->sc_fval);
- break;
- case CPP_INTCONSTANT:
- //printf("%d ", yylvalpp->sc_int);
- break;
- default:
- if (token >= 127)
- snprintf(str, sizeof(str), "%s ", GetAtomString(atable, token));
- else
- snprintf(str, sizeof(str), "%c", token);
- break;
- }
- CPPDebugLogMsg(str);
- }
-}
-
-///////////////////////////////////////////////////////////////////////////////////////////////
-/////////////////////////////////////// End of tokens.c ///////////////////////////////////////
-///////////////////////////////////////////////////////////////////////////////////////////////
diff --git a/src/3rdparty/angle/src/compiler/preprocessor/tokens.h b/src/3rdparty/angle/src/compiler/preprocessor/tokens.h
deleted file mode 100644
index dbf4a2ccfe..0000000000
--- a/src/3rdparty/angle/src/compiler/preprocessor/tokens.h
+++ /dev/null
@@ -1,90 +0,0 @@
-/****************************************************************************\
-Copyright (c) 2002, NVIDIA Corporation.
-
-NVIDIA Corporation("NVIDIA") supplies this software to you in
-consideration of your agreement to the following terms, and your use,
-installation, modification or redistribution of this NVIDIA software
-constitutes acceptance of these terms. If you do not agree with these
-terms, please do not use, install, modify or redistribute this NVIDIA
-software.
-
-In consideration of your agreement to abide by the following terms, and
-subject to these terms, NVIDIA grants you a personal, non-exclusive
-license, under NVIDIA's copyrights in this original NVIDIA software (the
-"NVIDIA Software"), to use, reproduce, modify and redistribute the
-NVIDIA Software, with or without modifications, in source and/or binary
-forms; provided that if you redistribute the NVIDIA Software, you must
-retain the copyright notice of NVIDIA, this notice and the following
-text and disclaimers in all such redistributions of the NVIDIA Software.
-Neither the name, trademarks, service marks nor logos of NVIDIA
-Corporation may be used to endorse or promote products derived from the
-NVIDIA Software without specific prior written permission from NVIDIA.
-Except as expressly stated in this notice, no other rights or licenses
-express or implied, are granted by NVIDIA herein, including but not
-limited to any patent rights that may be infringed by your derivative
-works or by other works in which the NVIDIA Software may be
-incorporated. No hardware is licensed hereunder.
-
-THE NVIDIA SOFTWARE IS BEING PROVIDED ON AN "AS IS" BASIS, WITHOUT
-WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED,
-INCLUDING WITHOUT LIMITATION, WARRANTIES OR CONDITIONS OF TITLE,
-NON-INFRINGEMENT, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
-ITS USE AND OPERATION EITHER ALONE OR IN COMBINATION WITH OTHER
-PRODUCTS.
-
-IN NO EVENT SHALL NVIDIA BE LIABLE FOR ANY SPECIAL, INDIRECT,
-INCIDENTAL, EXEMPLARY, CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
-TO, LOST PROFITS; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
-USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) OR ARISING IN ANY WAY
-OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE
-NVIDIA SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT,
-TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
-NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-\****************************************************************************/
-//
-// tokens.h
-//
-
-#if !defined(__TOKENS_H)
-#define __TOKENS_H 1
-
-#include <stdio.h>
-#include "compiler/preprocessor/parser.h"
-
-#define EOF_SY (-1)
-
-typedef struct TokenBlock_Rec TokenBlock;
-
-typedef struct TokenStream_Rec {
- struct TokenStream_Rec *next;
- char *name;
- TokenBlock *head;
- TokenBlock *current;
-} TokenStream;
-
-struct TokenBlock_Rec {
- TokenBlock *next;
- int current;
- int count;
- int max;
- unsigned char *data;
-};
-
-extern TokenStream stdlib_cpp_stream;
-
-
-TokenStream *NewTokenStream(const char *name, MemoryPool *pool);
-void DeleteTokenStream(TokenStream *pTok);
-void RecordToken(TokenStream *pTok, int token, yystypepp * yylvalpp);
-void RewindTokenStream(TokenStream *pTok);
-int ReadToken(TokenStream *pTok, yystypepp * yylvalpp);
-int ReadFromTokenStream(TokenStream *pTok, int name, int (*final)(CPPStruct *));
-void UngetToken(int, yystypepp * yylvalpp);
-
-#if defined(CPPC_ENABLE_TOOLS)
-
-void DumpTokenStream(FILE *, TokenStream *, yystypepp * yylvalpp);
-
-#endif // defined(CPPC_ENABLE_TOOLS)
-
-#endif // !defined(__TOKENS_H)
diff --git a/src/3rdparty/angle/src/libEGL/Config.cpp b/src/3rdparty/angle/src/libEGL/Config.cpp
index 89bc8d89f4..5488cb6f4f 100644
--- a/src/3rdparty/angle/src/libEGL/Config.cpp
+++ b/src/3rdparty/angle/src/libEGL/Config.cpp
@@ -13,76 +13,30 @@
#include <algorithm>
#include <vector>
+#include <GLES2/gl2.h>
+#include <GLES2/gl2ext.h>
+
#include "common/debug.h"
using namespace std;
namespace egl
{
-Config::Config(D3DDISPLAYMODE displayMode, EGLint minInterval, EGLint maxInterval, D3DFORMAT renderTargetFormat, D3DFORMAT depthStencilFormat, EGLint multiSample, EGLint texWidth, EGLint texHeight)
- : mDisplayMode(displayMode), mRenderTargetFormat(renderTargetFormat), mDepthStencilFormat(depthStencilFormat), mMultiSample(multiSample)
-{
- set(displayMode, minInterval, maxInterval, renderTargetFormat, depthStencilFormat, multiSample, texWidth, texHeight);
-}
-
-void Config::setDefaults()
-{
- mBufferSize = 0;
- mRedSize = 0;
- mGreenSize = 0;
- mBlueSize = 0;
- mLuminanceSize = 0;
- mAlphaSize = 0;
- mAlphaMaskSize = 0;
- mBindToTextureRGB = EGL_DONT_CARE;
- mBindToTextureRGBA = EGL_DONT_CARE;
- mColorBufferType = EGL_RGB_BUFFER;
- mConfigCaveat = EGL_DONT_CARE;
- mConfigID = EGL_DONT_CARE;
- mConformant = 0;
- mDepthSize = 0;
- mLevel = 0;
- mMatchNativePixmap = EGL_NONE;
- mMaxPBufferWidth = 0;
- mMaxPBufferHeight = 0;
- mMaxPBufferPixels = 0;
- mMaxSwapInterval = EGL_DONT_CARE;
- mMinSwapInterval = EGL_DONT_CARE;
- mNativeRenderable = EGL_DONT_CARE;
- mNativeVisualID = 0;
- mNativeVisualType = EGL_DONT_CARE;
- mRenderableType = EGL_OPENGL_ES_BIT;
- mSampleBuffers = 0;
- mSamples = 0;
- mStencilSize = 0;
- mSurfaceType = EGL_WINDOW_BIT;
- mTransparentType = EGL_NONE;
- mTransparentRedValue = EGL_DONT_CARE;
- mTransparentGreenValue = EGL_DONT_CARE;
- mTransparentBlueValue = EGL_DONT_CARE;
-}
-
-void Config::set(D3DDISPLAYMODE displayMode, EGLint minInterval, EGLint maxInterval, D3DFORMAT renderTargetFormat, D3DFORMAT depthStencilFormat, EGLint multiSample, EGLint texWidth, EGLint texHeight)
+Config::Config(rx::ConfigDesc desc, EGLint minInterval, EGLint maxInterval, EGLint texWidth, EGLint texHeight)
+ : mRenderTargetFormat(desc.renderTargetFormat), mDepthStencilFormat(desc.depthStencilFormat), mMultiSample(desc.multiSample)
{
mBindToTextureRGB = EGL_FALSE;
mBindToTextureRGBA = EGL_FALSE;
- switch (renderTargetFormat)
+ switch (desc.renderTargetFormat)
{
- case D3DFMT_A1R5G5B5:
+ case GL_RGB5_A1:
mBufferSize = 16;
mRedSize = 5;
mGreenSize = 5;
mBlueSize = 5;
mAlphaSize = 1;
break;
- case D3DFMT_A2R10G10B10:
- mBufferSize = 32;
- mRedSize = 10;
- mGreenSize = 10;
- mBlueSize = 10;
- mAlphaSize = 2;
- break;
- case D3DFMT_A8R8G8B8:
+ case GL_RGBA8_OES:
mBufferSize = 32;
mRedSize = 8;
mGreenSize = 8;
@@ -90,14 +44,14 @@ void Config::set(D3DDISPLAYMODE displayMode, EGLint minInterval, EGLint maxInter
mAlphaSize = 8;
mBindToTextureRGBA = true;
break;
- case D3DFMT_R5G6B5:
+ case GL_RGB565:
mBufferSize = 16;
mRedSize = 5;
mGreenSize = 6;
mBlueSize = 5;
mAlphaSize = 0;
break;
- case D3DFMT_X8R8G8B8:
+ case GL_RGB8_OES:
mBufferSize = 32;
mRedSize = 8;
mGreenSize = 8;
@@ -105,6 +59,14 @@ void Config::set(D3DDISPLAYMODE displayMode, EGLint minInterval, EGLint maxInter
mAlphaSize = 0;
mBindToTextureRGB = true;
break;
+ case GL_BGRA8_EXT:
+ mBufferSize = 32;
+ mRedSize = 8;
+ mGreenSize = 8;
+ mBlueSize = 8;
+ mAlphaSize = 8;
+ mBindToTextureRGBA = true;
+ break;
default:
UNREACHABLE(); // Other formats should not be valid
}
@@ -112,52 +74,32 @@ void Config::set(D3DDISPLAYMODE displayMode, EGLint minInterval, EGLint maxInter
mLuminanceSize = 0;
mAlphaMaskSize = 0;
mColorBufferType = EGL_RGB_BUFFER;
- mConfigCaveat = (displayMode.Format == renderTargetFormat) ? EGL_NONE : EGL_SLOW_CONFIG;
+ mConfigCaveat = (desc.fastConfig) ? EGL_NONE : EGL_SLOW_CONFIG;
mConfigID = 0;
mConformant = EGL_OPENGL_ES2_BIT;
- switch (depthStencilFormat)
+ switch (desc.depthStencilFormat)
{
- case D3DFMT_UNKNOWN:
+ case GL_NONE:
mDepthSize = 0;
mStencilSize = 0;
break;
-// case D3DFMT_D16_LOCKABLE:
-// mDepthSize = 16;
-// mStencilSize = 0;
-// break;
- case D3DFMT_D32:
+ case GL_DEPTH_COMPONENT32_OES:
mDepthSize = 32;
mStencilSize = 0;
break;
- case D3DFMT_D15S1:
- mDepthSize = 15;
- mStencilSize = 1;
- break;
- case D3DFMT_D24S8:
+ case GL_DEPTH24_STENCIL8_OES:
mDepthSize = 24;
mStencilSize = 8;
break;
- case D3DFMT_D24X8:
+ case GL_DEPTH_COMPONENT24_OES:
mDepthSize = 24;
mStencilSize = 0;
break;
- case D3DFMT_D24X4S4:
- mDepthSize = 24;
- mStencilSize = 4;
- break;
- case D3DFMT_D16:
+ case GL_DEPTH_COMPONENT16:
mDepthSize = 16;
mStencilSize = 0;
break;
-// case D3DFMT_D32F_LOCKABLE:
-// mDepthSize = 32;
-// mStencilSize = 0;
-// break;
-// case D3DFMT_D24FS8:
-// mDepthSize = 24;
-// mStencilSize = 8;
-// break;
default:
UNREACHABLE();
}
@@ -173,8 +115,8 @@ void Config::set(D3DDISPLAYMODE displayMode, EGLint minInterval, EGLint maxInter
mNativeVisualID = 0;
mNativeVisualType = 0;
mRenderableType = EGL_OPENGL_ES2_BIT;
- mSampleBuffers = multiSample ? 1 : 0;
- mSamples = multiSample;
+ mSampleBuffers = desc.multiSample ? 1 : 0;
+ mSamples = desc.multiSample;
mSurfaceType = EGL_PBUFFER_BIT | EGL_WINDOW_BIT | EGL_SWAP_BEHAVIOR_PRESERVED_BIT;
mTransparentType = EGL_NONE;
mTransparentRedValue = 0;
@@ -288,10 +230,9 @@ ConfigSet::ConfigSet()
{
}
-void ConfigSet::add(D3DDISPLAYMODE displayMode, EGLint minSwapInterval, EGLint maxSwapInterval, D3DFORMAT renderTargetFormat, D3DFORMAT depthStencilFormat, EGLint multiSample, EGLint texWidth, EGLint texHeight)
+void ConfigSet::add(rx::ConfigDesc desc, EGLint minSwapInterval, EGLint maxSwapInterval, EGLint texWidth, EGLint texHeight)
{
- Config config(displayMode, minSwapInterval, maxSwapInterval, renderTargetFormat, depthStencilFormat, multiSample, texWidth, texHeight);
-
+ Config config(desc, minSwapInterval, maxSwapInterval, texWidth, texHeight);
mSet.insert(config);
}
diff --git a/src/3rdparty/angle/src/libEGL/Config.h b/src/3rdparty/angle/src/libEGL/Config.h
index 95626ed1ad..680337b700 100644
--- a/src/3rdparty/angle/src/libEGL/Config.h
+++ b/src/3rdparty/angle/src/libEGL/Config.h
@@ -13,10 +13,10 @@
#define EGLAPI
#include <EGL/egl.h>
-#include <d3d9.h>
#include <set>
+#include "libGLESv2/renderer/Renderer.h"
#include "common/angleutils.h"
namespace egl
@@ -26,16 +26,13 @@ class Display;
class Config
{
public:
- Config(D3DDISPLAYMODE displayMode, EGLint minSwapInterval, EGLint maxSwapInterval, D3DFORMAT renderTargetFormat, D3DFORMAT depthStencilFormat, EGLint multiSample, EGLint texWidth, EGLint texHeight);
+ Config(rx::ConfigDesc desc, EGLint minSwapInterval, EGLint maxSwapInterval, EGLint texWidth, EGLint texHeight);
- void setDefaults();
- void set(D3DDISPLAYMODE displayMode, EGLint minSwapInterval, EGLint maxSwapInterval, D3DFORMAT renderTargetFormat, D3DFORMAT depthStencilFormat, EGLint multiSample, EGLint texWidth, EGLint texHeight);
EGLConfig getHandle() const;
- const D3DDISPLAYMODE mDisplayMode;
- const D3DFORMAT mRenderTargetFormat;
- const D3DFORMAT mDepthStencilFormat;
- const EGLint mMultiSample;
+ const GLenum mRenderTargetFormat;
+ const GLenum mDepthStencilFormat;
+ const GLint mMultiSample;
EGLint mBufferSize; // Depth of the color buffer
EGLint mRedSize; // Bits of Red in the color buffer
@@ -99,7 +96,7 @@ class ConfigSet
public:
ConfigSet();
- void add(D3DDISPLAYMODE displayMode, EGLint minSwapInterval, EGLint maxSwapInterval, D3DFORMAT renderTargetFormat, D3DFORMAT depthStencilFormat, EGLint multiSample, EGLint texWidth, EGLint texHeight);
+ void add(rx::ConfigDesc desc, EGLint minSwapInterval, EGLint maxSwapInterval, EGLint texWidth, EGLint texHeight);
size_t size() const;
bool getConfigs(EGLConfig *configs, const EGLint *attribList, EGLint configSize, EGLint *numConfig);
const egl::Config *get(EGLConfig configHandle);
diff --git a/src/3rdparty/angle/src/libEGL/Display.cpp b/src/3rdparty/angle/src/libEGL/Display.cpp
index a2dee6d964..d5d0f0f831 100644
--- a/src/3rdparty/angle/src/libEGL/Display.cpp
+++ b/src/3rdparty/angle/src/libEGL/Display.cpp
@@ -16,20 +16,12 @@
#include "common/debug.h"
#include "libGLESv2/mathutil.h"
-#include "libGLESv2/utilities.h"
+#include "libGLESv2/main.h"
+#include "libGLESv2/Context.h"
+#include "libGLESv2/renderer/SwapChain.h"
#include "libEGL/main.h"
-
-// Can also be enabled by defining FORCE_REF_RAST in the project's predefined macros
-#define REF_RAST 0
-
-// The "Debug This Pixel..." feature in PIX often fails when using the
-// D3D9Ex interfaces. In order to get debug pixel to work on a Vista/Win 7
-// machine, define "ANGLE_ENABLE_D3D9EX=0" in your project file.
-#if !defined(ANGLE_ENABLE_D3D9EX)
-// Enables use of the IDirect3D9Ex interface, when available
-#define ANGLE_ENABLE_D3D9EX 1
-#endif // !defined(ANGLE_ENABLE_D3D9EX)
+#include "libEGL/Surface.h"
namespace egl
{
@@ -69,27 +61,10 @@ egl::Display *Display::getDisplay(EGLNativeDisplayType displayId)
Display::Display(EGLNativeDisplayType displayId, HDC deviceContext, bool software) : mDc(deviceContext)
{
- mD3d9Module = NULL;
-
- mD3d9 = NULL;
- mD3d9Ex = NULL;
- mDevice = NULL;
- mDeviceEx = NULL;
- mDeviceWindow = NULL;
-
- mAdapter = D3DADAPTER_DEFAULT;
-
- #if REF_RAST == 1 || defined(FORCE_REF_RAST)
- mDeviceType = D3DDEVTYPE_REF;
- #else
- mDeviceType = D3DDEVTYPE_HAL;
- #endif
-
- mMinSwapInterval = 1;
- mMaxSwapInterval = 1;
+
mSoftwareDevice = software;
mDisplayId = displayId;
- mDeviceLost = false;
+ mRenderer = NULL;
}
Display::~Display()
@@ -100,7 +75,7 @@ Display::~Display()
if (thisDisplay != displays.end())
{
- displays.erase(thisDisplay);
+ displays.erase(thisDisplay);
}
}
@@ -111,197 +86,48 @@ bool Display::initialize()
return true;
}
- if (mSoftwareDevice)
- {
- mD3d9Module = GetModuleHandle(TEXT("swiftshader_d3d9.dll"));
- }
- else
- {
- mD3d9Module = GetModuleHandle(TEXT("d3d9.dll"));
- }
- if (mD3d9Module == NULL)
+ mRenderer = glCreateRenderer(this, mDc, mSoftwareDevice);
+
+ if (!mRenderer)
{
terminate();
- return false;
- }
-
- typedef HRESULT (WINAPI *Direct3DCreate9ExFunc)(UINT, IDirect3D9Ex**);
- Direct3DCreate9ExFunc Direct3DCreate9ExPtr = reinterpret_cast<Direct3DCreate9ExFunc>(GetProcAddress(mD3d9Module, "Direct3DCreate9Ex"));
-
- // Use Direct3D9Ex if available. Among other things, this version is less
- // inclined to report a lost context, for example when the user switches
- // desktop. Direct3D9Ex is available in Windows Vista and later if suitable drivers are available.
- if (ANGLE_ENABLE_D3D9EX && Direct3DCreate9ExPtr && SUCCEEDED(Direct3DCreate9ExPtr(D3D_SDK_VERSION, &mD3d9Ex)))
- {
- ASSERT(mD3d9Ex);
- mD3d9Ex->QueryInterface(IID_IDirect3D9, reinterpret_cast<void**>(&mD3d9));
- ASSERT(mD3d9);
- }
- else
- {
- mD3d9 = Direct3DCreate9(D3D_SDK_VERSION);
+ return error(EGL_NOT_INITIALIZED, false);
}
- if (mD3d9)
- {
- if (mDc != NULL)
- {
- // UNIMPLEMENTED(); // FIXME: Determine which adapter index the device context corresponds to
- }
-
- HRESULT result;
-
- // Give up on getting device caps after about one second.
- for (int i = 0; i < 10; ++i)
- {
- result = mD3d9->GetDeviceCaps(mAdapter, mDeviceType, &mDeviceCaps);
-
- if (SUCCEEDED(result))
- {
- break;
- }
- else if (result == D3DERR_NOTAVAILABLE)
- {
- Sleep(100); // Give the driver some time to initialize/recover
- }
- else if (FAILED(result)) // D3DERR_OUTOFVIDEOMEMORY, E_OUTOFMEMORY, D3DERR_INVALIDDEVICE, or another error we can't recover from
- {
- terminate();
- return error(EGL_BAD_ALLOC, false);
- }
- }
-
- if (mDeviceCaps.PixelShaderVersion < D3DPS_VERSION(2, 0))
- {
- terminate();
- return error(EGL_NOT_INITIALIZED, false);
- }
-
- // When DirectX9 is running with an older DirectX8 driver, a StretchRect from a regular texture to a render target texture is not supported.
- // This is required by Texture2D::convertToRenderTarget.
- if ((mDeviceCaps.DevCaps2 & D3DDEVCAPS2_CAN_STRETCHRECT_FROM_TEXTURES) == 0)
- {
- terminate();
- return error(EGL_NOT_INITIALIZED, false);
- }
-
- mMinSwapInterval = 4;
- mMaxSwapInterval = 0;
-
- if (mDeviceCaps.PresentationIntervals & D3DPRESENT_INTERVAL_IMMEDIATE) {mMinSwapInterval = std::min(mMinSwapInterval, 0); mMaxSwapInterval = std::max(mMaxSwapInterval, 0);}
- if (mDeviceCaps.PresentationIntervals & D3DPRESENT_INTERVAL_ONE) {mMinSwapInterval = std::min(mMinSwapInterval, 1); mMaxSwapInterval = std::max(mMaxSwapInterval, 1);}
- if (mDeviceCaps.PresentationIntervals & D3DPRESENT_INTERVAL_TWO) {mMinSwapInterval = std::min(mMinSwapInterval, 2); mMaxSwapInterval = std::max(mMaxSwapInterval, 2);}
- if (mDeviceCaps.PresentationIntervals & D3DPRESENT_INTERVAL_THREE) {mMinSwapInterval = std::min(mMinSwapInterval, 3); mMaxSwapInterval = std::max(mMaxSwapInterval, 3);}
- if (mDeviceCaps.PresentationIntervals & D3DPRESENT_INTERVAL_FOUR) {mMinSwapInterval = std::min(mMinSwapInterval, 4); mMaxSwapInterval = std::max(mMaxSwapInterval, 4);}
-
- mD3d9->GetAdapterIdentifier(mAdapter, 0, &mAdapterIdentifier);
+ EGLint minSwapInterval = mRenderer->getMinSwapInterval();
+ EGLint maxSwapInterval = mRenderer->getMaxSwapInterval();
+ EGLint maxTextureWidth = mRenderer->getMaxTextureWidth();
+ EGLint maxTextureHeight = mRenderer->getMaxTextureHeight();
- // ATI cards on XP have problems with non-power-of-two textures.
- mSupportsNonPower2Textures = !(mDeviceCaps.TextureCaps & D3DPTEXTURECAPS_POW2) &&
- !(mDeviceCaps.TextureCaps & D3DPTEXTURECAPS_CUBEMAP_POW2) &&
- !(mDeviceCaps.TextureCaps & D3DPTEXTURECAPS_NONPOW2CONDITIONAL) &&
- !(getComparableOSVersion() < versionWindowsVista && mAdapterIdentifier.VendorId == VENDOR_ID_AMD);
-
- const D3DFORMAT renderTargetFormats[] =
- {
- D3DFMT_A1R5G5B5,
- // D3DFMT_A2R10G10B10, // The color_ramp conformance test uses ReadPixels with UNSIGNED_BYTE causing it to think that rendering skipped a colour value.
- D3DFMT_A8R8G8B8,
- D3DFMT_R5G6B5,
- // D3DFMT_X1R5G5B5, // Has no compatible OpenGL ES renderbuffer format
- D3DFMT_X8R8G8B8
- };
-
- const D3DFORMAT depthStencilFormats[] =
- {
- D3DFMT_UNKNOWN,
- // D3DFMT_D16_LOCKABLE,
- D3DFMT_D32,
- // D3DFMT_D15S1,
- D3DFMT_D24S8,
- D3DFMT_D24X8,
- // D3DFMT_D24X4S4,
- D3DFMT_D16,
- // D3DFMT_D32F_LOCKABLE,
- // D3DFMT_D24FS8
- };
-
- D3DDISPLAYMODE currentDisplayMode;
- mD3d9->GetAdapterDisplayMode(mAdapter, &currentDisplayMode);
-
- ConfigSet configSet;
-
- for (int formatIndex = 0; formatIndex < sizeof(renderTargetFormats) / sizeof(D3DFORMAT); formatIndex++)
- {
- D3DFORMAT renderTargetFormat = renderTargetFormats[formatIndex];
+ rx::ConfigDesc *descList;
+ int numConfigs = mRenderer->generateConfigs(&descList);
+ ConfigSet configSet;
- HRESULT result = mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_RENDERTARGET, D3DRTYPE_SURFACE, renderTargetFormat);
+ for (int i = 0; i < numConfigs; ++i)
+ configSet.add(descList[i], minSwapInterval, maxSwapInterval,
+ maxTextureWidth, maxTextureHeight);
- if (SUCCEEDED(result))
- {
- for (int depthStencilIndex = 0; depthStencilIndex < sizeof(depthStencilFormats) / sizeof(D3DFORMAT); depthStencilIndex++)
- {
- D3DFORMAT depthStencilFormat = depthStencilFormats[depthStencilIndex];
- HRESULT result = D3D_OK;
-
- if(depthStencilFormat != D3DFMT_UNKNOWN)
- {
- result = mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_DEPTHSTENCIL, D3DRTYPE_SURFACE, depthStencilFormat);
- }
-
- if (SUCCEEDED(result))
- {
- if(depthStencilFormat != D3DFMT_UNKNOWN)
- {
- result = mD3d9->CheckDepthStencilMatch(mAdapter, mDeviceType, currentDisplayMode.Format, renderTargetFormat, depthStencilFormat);
- }
-
- if (SUCCEEDED(result))
- {
- // FIXME: enumerate multi-sampling
-
- configSet.add(currentDisplayMode, mMinSwapInterval, mMaxSwapInterval, renderTargetFormat, depthStencilFormat, 0,
- mDeviceCaps.MaxTextureWidth, mDeviceCaps.MaxTextureHeight);
- }
- }
- }
- }
- }
-
- // Give the sorted configs a unique ID and store them internally
- EGLint index = 1;
- for (ConfigSet::Iterator config = configSet.mSet.begin(); config != configSet.mSet.end(); config++)
- {
- Config configuration = *config;
- configuration.mConfigID = index;
- index++;
-
- mConfigSet.mSet.insert(configuration);
- }
- }
-
- if (!isInitialized())
+ // Give the sorted configs a unique ID and store them internally
+ EGLint index = 1;
+ for (ConfigSet::Iterator config = configSet.mSet.begin(); config != configSet.mSet.end(); config++)
{
- terminate();
+ Config configuration = *config;
+ configuration.mConfigID = index;
+ index++;
- return false;
+ mConfigSet.mSet.insert(configuration);
}
- initExtensionString();
-
- static const TCHAR windowName[] = TEXT("AngleHiddenWindow");
- static const TCHAR className[] = TEXT("STATIC");
-
- mDeviceWindow = CreateWindowEx(WS_EX_NOACTIVATE, className, windowName, WS_DISABLED | WS_POPUP, 0, 0, 1, 1, HWND_MESSAGE, NULL, GetModuleHandle(NULL), NULL);
+ mRenderer->deleteConfigs(descList);
+ descList = NULL;
- if (!createDevice())
+ if (!isInitialized())
{
terminate();
return false;
}
- mVertexShaderCache.initialize(mDevice);
- mPixelShaderCache.initialize(mDevice);
+ initExtensionString();
return true;
}
@@ -318,79 +144,8 @@ void Display::terminate()
destroyContext(*mContextSet.begin());
}
- while (!mEventQueryPool.empty())
- {
- mEventQueryPool.back()->Release();
- mEventQueryPool.pop_back();
- }
-
- mVertexShaderCache.clear();
- mPixelShaderCache.clear();
-
- if (mDevice)
- {
- // If the device is lost, reset it first to prevent leaving the driver in an unstable state
- if (testDeviceLost())
- {
- resetDevice();
- }
-
- mDevice->Release();
- mDevice = NULL;
- }
-
- if (mDeviceEx)
- {
- mDeviceEx->Release();
- mDeviceEx = NULL;
- }
-
- if (mD3d9)
- {
- mD3d9->Release();
- mD3d9 = NULL;
- }
-
- if (mDeviceWindow)
- {
- DestroyWindow(mDeviceWindow);
- mDeviceWindow = NULL;
- }
-
- if (mD3d9Ex)
- {
- mD3d9Ex->Release();
- mD3d9Ex = NULL;
- }
-
- if (mD3d9Module)
- {
- mD3d9Module = NULL;
- }
-}
-
-void Display::startScene()
-{
- if (!mSceneStarted)
- {
- long result = mDevice->BeginScene();
- if (SUCCEEDED(result)) {
- // This is defensive checking against the device being
- // lost at unexpected times.
- mSceneStarted = true;
- }
- }
-}
-
-void Display::endScene()
-{
- if (mSceneStarted)
- {
- // EndScene can fail if the device was lost, for example due
- // to a TDR during a draw call.
- mDevice->EndScene();
- mSceneStarted = false;
- }
+ glDestroyRenderer(mRenderer);
+ mRenderer = NULL;
}
bool Display::getConfigs(EGLConfig *configs, const EGLint *attribList, EGLint configSize, EGLint *numConfig)
@@ -443,107 +198,7 @@ bool Display::getConfigAttrib(EGLConfig config, EGLint attribute, EGLint *value)
return true;
}
-bool Display::createDevice()
-{
- D3DPRESENT_PARAMETERS presentParameters = getDefaultPresentParameters();
- DWORD behaviorFlags = D3DCREATE_FPU_PRESERVE | D3DCREATE_NOWINDOWCHANGES;
-
- HRESULT result = mD3d9->CreateDevice(mAdapter, mDeviceType, mDeviceWindow, behaviorFlags | D3DCREATE_HARDWARE_VERTEXPROCESSING | D3DCREATE_PUREDEVICE, &presentParameters, &mDevice);
-
- if (result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY || result == D3DERR_DEVICELOST)
- {
- return error(EGL_BAD_ALLOC, false);
- }
-
- if (FAILED(result))
- {
- result = mD3d9->CreateDevice(mAdapter, mDeviceType, mDeviceWindow, behaviorFlags | D3DCREATE_SOFTWARE_VERTEXPROCESSING, &presentParameters, &mDevice);
-
- if (FAILED(result))
- {
- ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY || result == D3DERR_NOTAVAILABLE || result == D3DERR_DEVICELOST);
- return error(EGL_BAD_ALLOC, false);
- }
- }
-
- if (mD3d9Ex)
- {
- result = mDevice->QueryInterface(IID_IDirect3DDevice9Ex, (void**) &mDeviceEx);
- ASSERT(SUCCEEDED(result));
- }
-
- initializeDevice();
-
- return true;
-}
-
-// do any one-time device initialization
-// NOTE: this is also needed after a device lost/reset
-// to reset the scene status and ensure the default states are reset.
-void Display::initializeDevice()
-{
- // Permanent non-default states
- mDevice->SetRenderState(D3DRS_POINTSPRITEENABLE, TRUE);
- mDevice->SetRenderState(D3DRS_LASTPIXEL, FALSE);
-
- if (mDeviceCaps.PixelShaderVersion >= D3DPS_VERSION(3, 0))
- {
- mDevice->SetRenderState(D3DRS_POINTSIZE_MAX, (DWORD&)mDeviceCaps.MaxPointSize);
- }
- else
- {
- mDevice->SetRenderState(D3DRS_POINTSIZE_MAX, 0x3F800000); // 1.0f
- }
-
- mSceneStarted = false;
-}
-
-bool Display::resetDevice()
-{
- D3DPRESENT_PARAMETERS presentParameters = getDefaultPresentParameters();
-
- HRESULT result = D3D_OK;
- bool lost = testDeviceLost();
- int attempts = 3;
-
- while (lost && attempts > 0)
- {
- if (mDeviceEx)
- {
- Sleep(500); // Give the graphics driver some CPU time
- result = mDeviceEx->ResetEx(&presentParameters, NULL);
- }
- else
- {
- result = mDevice->TestCooperativeLevel();
-
- while (result == D3DERR_DEVICELOST)
- {
- Sleep(100); // Give the graphics driver some CPU time
- result = mDevice->TestCooperativeLevel();
- }
-
- if (result == D3DERR_DEVICENOTRESET)
- {
- result = mDevice->Reset(&presentParameters);
- }
- }
-
- lost = testDeviceLost();
- attempts --;
- }
-
- if (FAILED(result))
- {
- ERR("Reset/ResetEx failed multiple times: 0x%08X", result);
- return error(EGL_BAD_ALLOC, false);
- }
-
- // reset device defaults
- initializeDevice();
- return true;
-}
EGLSurface Display::createWindowSurface(HWND window, EGLConfig config, const EGLint *attribList)
{
@@ -587,7 +242,7 @@ EGLSurface Display::createWindowSurface(HWND window, EGLConfig config, const EGL
return error(EGL_BAD_ALLOC, EGL_NO_SURFACE);
}
- if (testDeviceLost())
+ if (mRenderer->testDeviceLost(false))
{
if (!restoreLostDevice())
return EGL_NO_SURFACE;
@@ -678,7 +333,7 @@ EGLSurface Display::createOffscreenSurface(EGLConfig config, HANDLE shareHandle,
return error(EGL_BAD_ATTRIBUTE, EGL_NO_SURFACE);
}
- if (textureFormat != EGL_NO_TEXTURE && !getNonPower2TextureSupport() && (!gl::isPow2(width) || !gl::isPow2(height)))
+ if (textureFormat != EGL_NO_TEXTURE && !mRenderer->getNonPower2TextureSupport() && (!gl::isPow2(width) || !gl::isPow2(height)))
{
return error(EGL_BAD_MATCH, EGL_NO_SURFACE);
}
@@ -700,7 +355,7 @@ EGLSurface Display::createOffscreenSurface(EGLConfig config, HANDLE shareHandle,
return error(EGL_BAD_ATTRIBUTE, EGL_NO_SURFACE);
}
- if (testDeviceLost())
+ if (mRenderer->testDeviceLost(false))
{
if (!restoreLostDevice())
return EGL_NO_SURFACE;
@@ -721,24 +376,18 @@ EGLSurface Display::createOffscreenSurface(EGLConfig config, HANDLE shareHandle,
EGLContext Display::createContext(EGLConfig configHandle, const gl::Context *shareContext, bool notifyResets, bool robustAccess)
{
- if (!mDevice)
+ if (!mRenderer)
{
- if (!createDevice())
- {
- return NULL;
- }
+ return NULL;
}
- else if (testDeviceLost()) // Lost device
+ else if (mRenderer->testDeviceLost(false)) // Lost device
{
if (!restoreLostDevice())
return NULL;
}
- const egl::Config *config = mConfigSet.get(configHandle);
-
- gl::Context *context = glCreateContext(config, shareContext, notifyResets, robustAccess);
+ gl::Context *context = glCreateContext(shareContext, mRenderer, notifyResets, robustAccess);
mContextSet.insert(context);
- mDeviceLost = false;
return context;
}
@@ -757,18 +406,9 @@ bool Display::restoreLostDevice()
(*surface)->release();
}
- while (!mEventQueryPool.empty())
- {
- mEventQueryPool.back()->Release();
- mEventQueryPool.pop_back();
- }
-
- mVertexShaderCache.clear();
- mPixelShaderCache.clear();
-
- if (!resetDevice())
+ if (!mRenderer->resetDevice())
{
- return false;
+ return error(EGL_BAD_ALLOC, false);
}
// Restore any surfaces that may have been lost
@@ -799,18 +439,20 @@ void Display::notifyDeviceLost()
{
(*context)->markContextLost();
}
- mDeviceLost = true;
- error(EGL_CONTEXT_LOST);
+ egl::error(EGL_CONTEXT_LOST);
}
-bool Display::isDeviceLost()
+void Display::recreateSwapChains()
{
- return mDeviceLost;
+ for (SurfaceSet::iterator surface = mSurfaceSet.begin(); surface != mSurfaceSet.end(); surface++)
+ {
+ (*surface)->getSwapChain()->recreate();
+ }
}
bool Display::isInitialized() const
{
- return mD3d9 != NULL && mConfigSet.size() > 0;
+ return mRenderer != NULL && mConfigSet.size() > 0;
}
bool Display::isValidConfig(EGLConfig config)
@@ -841,352 +483,10 @@ bool Display::hasExistingWindowSurface(HWND window)
return false;
}
-EGLint Display::getMinSwapInterval()
-{
- return mMinSwapInterval;
-}
-
-EGLint Display::getMaxSwapInterval()
-{
- return mMaxSwapInterval;
-}
-
-IDirect3DDevice9 *Display::getDevice()
-{
- if (!mDevice)
- {
- if (!createDevice())
- {
- return NULL;
- }
- }
-
- return mDevice;
-}
-
-D3DCAPS9 Display::getDeviceCaps()
-{
- return mDeviceCaps;
-}
-
-D3DADAPTER_IDENTIFIER9 *Display::getAdapterIdentifier()
-{
- return &mAdapterIdentifier;
-}
-
-bool Display::testDeviceLost()
-{
- if (mDeviceEx)
- {
- return FAILED(mDeviceEx->CheckDeviceState(NULL));
- }
- else if (mDevice)
- {
- return FAILED(mDevice->TestCooperativeLevel());
- }
-
- return false; // No device yet, so no reset required
-}
-
-bool Display::testDeviceResettable()
-{
- HRESULT status = D3D_OK;
-
- if (mDeviceEx)
- {
- status = mDeviceEx->CheckDeviceState(NULL);
- }
- else if (mDevice)
- {
- status = mDevice->TestCooperativeLevel();
- }
-
- switch (status)
- {
- case D3DERR_DEVICENOTRESET:
- case D3DERR_DEVICEHUNG:
- return true;
- default:
- return false;
- }
-}
-
-void Display::sync(bool block)
-{
- HRESULT result;
-
- IDirect3DQuery9* query = allocateEventQuery();
- if (!query)
- {
- return;
- }
-
- result = query->Issue(D3DISSUE_END);
- ASSERT(SUCCEEDED(result));
-
- do
- {
- result = query->GetData(NULL, 0, D3DGETDATA_FLUSH);
-
- if(block && result == S_FALSE)
- {
- // Keep polling, but allow other threads to do something useful first
- Sleep(0);
- // explicitly check for device loss
- // some drivers seem to return S_FALSE even if the device is lost
- // instead of D3DERR_DEVICELOST like they should
- if (testDeviceLost())
- {
- result = D3DERR_DEVICELOST;
- }
- }
- }
- while(block && result == S_FALSE);
-
- freeEventQuery(query);
-
- if (isDeviceLostError(result))
- {
- notifyDeviceLost();
- }
-}
-
-IDirect3DQuery9* Display::allocateEventQuery()
-{
- IDirect3DQuery9 *query = NULL;
-
- if (mEventQueryPool.empty())
- {
- HRESULT result = mDevice->CreateQuery(D3DQUERYTYPE_EVENT, &query);
- ASSERT(SUCCEEDED(result));
- }
- else
- {
- query = mEventQueryPool.back();
- mEventQueryPool.pop_back();
- }
-
- return query;
-}
-
-void Display::freeEventQuery(IDirect3DQuery9* query)
-{
- if (mEventQueryPool.size() > 1000)
- {
- query->Release();
- }
- else
- {
- mEventQueryPool.push_back(query);
- }
-}
-
-void Display::getMultiSampleSupport(D3DFORMAT format, bool *multiSampleArray)
-{
- for (int multiSampleIndex = 0; multiSampleIndex <= D3DMULTISAMPLE_16_SAMPLES; multiSampleIndex++)
- {
- HRESULT result = mD3d9->CheckDeviceMultiSampleType(mAdapter, mDeviceType, format,
- TRUE, (D3DMULTISAMPLE_TYPE)multiSampleIndex, NULL);
-
- multiSampleArray[multiSampleIndex] = SUCCEEDED(result);
- }
-}
-
-bool Display::getDXT1TextureSupport()
-{
- D3DDISPLAYMODE currentDisplayMode;
- mD3d9->GetAdapterDisplayMode(mAdapter, &currentDisplayMode);
-
- return SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_DXT1));
-}
-
-bool Display::getDXT3TextureSupport()
-{
- D3DDISPLAYMODE currentDisplayMode;
- mD3d9->GetAdapterDisplayMode(mAdapter, &currentDisplayMode);
-
- return SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_DXT3));
-}
-
-bool Display::getDXT5TextureSupport()
-{
- D3DDISPLAYMODE currentDisplayMode;
- mD3d9->GetAdapterDisplayMode(mAdapter, &currentDisplayMode);
-
- return SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_DXT5));
-}
-
-// we use INTZ for depth textures in Direct3D9
-// we also want NULL texture support to ensure the we can make depth-only FBOs
-// see http://aras-p.info/texts/D3D9GPUHacks.html
-bool Display::getDepthTextureSupport() const
-{
- D3DDISPLAYMODE currentDisplayMode;
- mD3d9->GetAdapterDisplayMode(mAdapter, &currentDisplayMode);
-
- bool intz = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format,
- D3DUSAGE_DEPTHSTENCIL, D3DRTYPE_TEXTURE, D3DFMT_INTZ));
- bool null = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format,
- D3DUSAGE_RENDERTARGET, D3DRTYPE_SURFACE, D3DFMT_NULL));
-
- return intz && null;
-}
-
-bool Display::getFloat32TextureSupport(bool *filtering, bool *renderable)
-{
- D3DDISPLAYMODE currentDisplayMode;
- mD3d9->GetAdapterDisplayMode(mAdapter, &currentDisplayMode);
-
- *filtering = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_QUERY_FILTER,
- D3DRTYPE_TEXTURE, D3DFMT_A32B32G32R32F)) &&
- SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_QUERY_FILTER,
- D3DRTYPE_CUBETEXTURE, D3DFMT_A32B32G32R32F));
-
- *renderable = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_RENDERTARGET,
- D3DRTYPE_TEXTURE, D3DFMT_A32B32G32R32F))&&
- SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_RENDERTARGET,
- D3DRTYPE_CUBETEXTURE, D3DFMT_A32B32G32R32F));
-
- if (!*filtering && !*renderable)
- {
- return SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0,
- D3DRTYPE_TEXTURE, D3DFMT_A32B32G32R32F)) &&
- SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0,
- D3DRTYPE_CUBETEXTURE, D3DFMT_A32B32G32R32F));
- }
- else
- {
- return true;
- }
-}
-
-bool Display::getFloat16TextureSupport(bool *filtering, bool *renderable)
-{
- D3DDISPLAYMODE currentDisplayMode;
- mD3d9->GetAdapterDisplayMode(mAdapter, &currentDisplayMode);
-
- *filtering = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_QUERY_FILTER,
- D3DRTYPE_TEXTURE, D3DFMT_A16B16G16R16F)) &&
- SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_QUERY_FILTER,
- D3DRTYPE_CUBETEXTURE, D3DFMT_A16B16G16R16F));
-
- *renderable = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_RENDERTARGET,
- D3DRTYPE_TEXTURE, D3DFMT_A16B16G16R16F)) &&
- SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_RENDERTARGET,
- D3DRTYPE_CUBETEXTURE, D3DFMT_A16B16G16R16F));
-
- if (!*filtering && !*renderable)
- {
- return SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0,
- D3DRTYPE_TEXTURE, D3DFMT_A16B16G16R16F)) &&
- SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0,
- D3DRTYPE_CUBETEXTURE, D3DFMT_A16B16G16R16F));
- }
- else
- {
- return true;
- }
-}
-
-bool Display::getLuminanceTextureSupport()
-{
- D3DDISPLAYMODE currentDisplayMode;
- mD3d9->GetAdapterDisplayMode(mAdapter, &currentDisplayMode);
-
- return SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_L8));
-}
-
-bool Display::getLuminanceAlphaTextureSupport()
-{
- D3DDISPLAYMODE currentDisplayMode;
- mD3d9->GetAdapterDisplayMode(mAdapter, &currentDisplayMode);
-
- return SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_A8L8));
-}
-
-float Display::getTextureFilterAnisotropySupport() const
-{
- // Must support a minimum of 2:1 anisotropy for max anisotropy to be considered supported, per the spec
- if ((mDeviceCaps.RasterCaps & D3DPRASTERCAPS_ANISOTROPY) && (mDeviceCaps.MaxAnisotropy >= 2))
- {
- return mDeviceCaps.MaxAnisotropy;
- }
- return 1.0f;
-}
-
-D3DPOOL Display::getBufferPool(DWORD usage) const
-{
- if (mD3d9Ex != NULL)
- {
- return D3DPOOL_DEFAULT;
- }
- else
- {
- if (!(usage & D3DUSAGE_DYNAMIC))
- {
- return D3DPOOL_MANAGED;
- }
- }
-
- return D3DPOOL_DEFAULT;
-}
-
-D3DPOOL Display::getTexturePool(DWORD usage) const
-{
- if (mD3d9Ex != NULL)
- {
- return D3DPOOL_DEFAULT;
- }
- else
- {
- if (!(usage & (D3DUSAGE_DEPTHSTENCIL | D3DUSAGE_RENDERTARGET)))
- {
- return D3DPOOL_MANAGED;
- }
- }
-
- return D3DPOOL_DEFAULT;
-}
-
-bool Display::getEventQuerySupport()
-{
- IDirect3DQuery9 *query = allocateEventQuery();
- if (query)
- {
- freeEventQuery(query);
- return true;
- }
- else
- {
- return false;
- }
-}
-
-D3DPRESENT_PARAMETERS Display::getDefaultPresentParameters()
-{
- D3DPRESENT_PARAMETERS presentParameters = {0};
-
- // The default swap chain is never actually used. Surface will create a new swap chain with the proper parameters.
- presentParameters.AutoDepthStencilFormat = D3DFMT_UNKNOWN;
- presentParameters.BackBufferCount = 1;
- presentParameters.BackBufferFormat = D3DFMT_UNKNOWN;
- presentParameters.BackBufferWidth = 1;
- presentParameters.BackBufferHeight = 1;
- presentParameters.EnableAutoDepthStencil = FALSE;
- presentParameters.Flags = 0;
- presentParameters.hDeviceWindow = mDeviceWindow;
- presentParameters.MultiSampleQuality = 0;
- presentParameters.MultiSampleType = D3DMULTISAMPLE_NONE;
- presentParameters.PresentationInterval = D3DPRESENT_INTERVAL_DEFAULT;
- presentParameters.SwapEffect = D3DSWAPEFFECT_DISCARD;
- presentParameters.Windowed = TRUE;
-
- return presentParameters;
-}
-
void Display::initExtensionString()
{
HMODULE swiftShader = GetModuleHandle(TEXT("swiftshader_d3d9.dll"));
+ bool shareHandleSupported = mRenderer->getShareHandleSupport();
mExtensionString = "";
@@ -1194,7 +494,7 @@ void Display::initExtensionString()
mExtensionString += "EGL_EXT_create_context_robustness ";
// ANGLE-specific extensions
- if (shareHandleSupported())
+ if (shareHandleSupported)
{
mExtensionString += "EGL_ANGLE_d3d_share_handle_client_buffer ";
}
@@ -1206,12 +506,15 @@ void Display::initExtensionString()
mExtensionString += "EGL_ANGLE_software_display ";
}
- if (shareHandleSupported())
+ if (shareHandleSupported)
{
mExtensionString += "EGL_ANGLE_surface_d3d_texture_2d_share_handle ";
}
- mExtensionString += "EGL_NV_post_sub_buffer";
+ if (mRenderer->getPostSubBufferSupport())
+ {
+ mExtensionString += "EGL_NV_post_sub_buffer";
+ }
std::string::size_type end = mExtensionString.find_last_not_of(' ');
if (end != std::string::npos)
@@ -1225,68 +528,5 @@ const char *Display::getExtensionString() const
return mExtensionString.c_str();
}
-bool Display::shareHandleSupported() const
-{
- // PIX doesn't seem to support using share handles, so disable them.
- return isD3d9ExDevice() && !gl::perfActive();
-}
-
-IDirect3DVertexShader9 *Display::createVertexShader(const DWORD *function, size_t length)
-{
- return mVertexShaderCache.create(function, length);
-}
-
-IDirect3DPixelShader9 *Display::createPixelShader(const DWORD *function, size_t length)
-{
- return mPixelShaderCache.create(function, length);
-}
-
-// Only Direct3D 10 ready devices support all the necessary vertex texture formats.
-// We test this using D3D9 by checking support for the R16F format.
-bool Display::getVertexTextureSupport() const
-{
- if (!isInitialized() || mDeviceCaps.PixelShaderVersion < D3DPS_VERSION(3, 0))
- {
- return false;
- }
-
- D3DDISPLAYMODE currentDisplayMode;
- mD3d9->GetAdapterDisplayMode(mAdapter, &currentDisplayMode);
-
- HRESULT result = mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_QUERY_VERTEXTEXTURE, D3DRTYPE_TEXTURE, D3DFMT_R16F);
-
- return SUCCEEDED(result);
-}
-
-bool Display::getNonPower2TextureSupport() const
-{
- return mSupportsNonPower2Textures;
-}
-
-bool Display::getOcclusionQuerySupport() const
-{
- if (!isInitialized())
- {
- return false;
- }
-
- IDirect3DQuery9 *query = NULL;
- HRESULT result = mDevice->CreateQuery(D3DQUERYTYPE_OCCLUSION, &query);
-
- if (SUCCEEDED(result) && query)
- {
- query->Release();
- return true;
- }
- else
- {
- return false;
- }
-}
-
-bool Display::getInstancingSupport() const
-{
- return mDeviceCaps.PixelShaderVersion >= D3DPS_VERSION(3, 0);
-}
}
diff --git a/src/3rdparty/angle/src/libEGL/Display.h b/src/3rdparty/angle/src/libEGL/Display.h
index 23b57b74c6..8c71e51b7a 100644
--- a/src/3rdparty/angle/src/libEGL/Display.h
+++ b/src/3rdparty/angle/src/libEGL/Display.h
@@ -11,36 +11,22 @@
#ifndef LIBEGL_DISPLAY_H_
#define LIBEGL_DISPLAY_H_
-#ifndef WIN32_LEAN_AND_MEAN
-#define WIN32_LEAN_AND_MEAN
-#endif
-#include <windows.h>
-#include <d3d9.h>
+#include "common/system.h"
#include <set>
#include <vector>
-#include "libGLESv2/Context.h"
-
#include "libEGL/Config.h"
-#include "libEGL/ShaderCache.h"
-#include "libEGL/Surface.h"
-
-const int versionWindowsVista = MAKEWORD(0x00, 0x06);
-const int versionWindows7 = MAKEWORD(0x01, 0x06);
-// Return the version of the operating system in a format suitable for ordering
-// comparison.
-inline int getComparableOSVersion()
+namespace gl
{
- DWORD version = GetVersion();
- int majorVersion = LOBYTE(LOWORD(version));
- int minorVersion = HIBYTE(LOWORD(version));
- return MAKEWORD(minorVersion, majorVersion);
+class Context;
}
namespace egl
{
+class Surface;
+
class Display
{
public:
@@ -49,9 +35,6 @@ class Display
bool initialize();
void terminate();
- virtual void startScene();
- virtual void endScene();
-
static egl::Display *getDisplay(EGLNativeDisplayType displayId);
bool getConfigs(EGLConfig *configs, const EGLint *attribList, EGLint configSize, EGLint *numConfig);
@@ -70,81 +53,25 @@ class Display
bool isValidSurface(egl::Surface *surface);
bool hasExistingWindowSurface(HWND window);
- EGLint getMinSwapInterval();
- EGLint getMaxSwapInterval();
-
- virtual IDirect3DDevice9 *getDevice();
- virtual D3DCAPS9 getDeviceCaps();
- virtual D3DADAPTER_IDENTIFIER9 *getAdapterIdentifier();
- virtual bool testDeviceLost();
- virtual bool testDeviceResettable();
- virtual void sync(bool block);
- virtual IDirect3DQuery9* allocateEventQuery();
- virtual void freeEventQuery(IDirect3DQuery9* query);
- virtual void getMultiSampleSupport(D3DFORMAT format, bool *multiSampleArray);
- virtual bool getDXT1TextureSupport();
- virtual bool getDXT3TextureSupport();
- virtual bool getDXT5TextureSupport();
- virtual bool getEventQuerySupport();
- virtual bool getFloat32TextureSupport(bool *filtering, bool *renderable);
- virtual bool getFloat16TextureSupport(bool *filtering, bool *renderable);
- virtual bool getLuminanceTextureSupport();
- virtual bool getLuminanceAlphaTextureSupport();
- virtual bool getVertexTextureSupport() const;
- virtual bool getNonPower2TextureSupport() const;
- virtual bool getDepthTextureSupport() const;
- virtual bool getOcclusionQuerySupport() const;
- virtual bool getInstancingSupport() const;
- virtual float getTextureFilterAnisotropySupport() const;
- virtual D3DPOOL getBufferPool(DWORD usage) const;
- virtual D3DPOOL getTexturePool(DWORD usage) const;
+ rx::Renderer *getRenderer() { return mRenderer; };
+ // exported methods must be virtual
virtual void notifyDeviceLost();
- bool isDeviceLost();
+ virtual void recreateSwapChains();
- bool isD3d9ExDevice() const { return mD3d9Ex != NULL; }
const char *getExtensionString() const;
- bool shareHandleSupported() const;
-
- virtual IDirect3DVertexShader9 *createVertexShader(const DWORD *function, size_t length);
- virtual IDirect3DPixelShader9 *createPixelShader(const DWORD *function, size_t length);
private:
DISALLOW_COPY_AND_ASSIGN(Display);
Display(EGLNativeDisplayType displayId, HDC deviceContext, bool software);
- D3DPRESENT_PARAMETERS getDefaultPresentParameters();
-
bool restoreLostDevice();
EGLNativeDisplayType mDisplayId;
const HDC mDc;
- HMODULE mD3d9Module;
-
- UINT mAdapter;
- D3DDEVTYPE mDeviceType;
- IDirect3D9 *mD3d9; // Always valid after successful initialization.
- IDirect3D9Ex *mD3d9Ex; // Might be null if D3D9Ex is not supported.
- IDirect3DDevice9 *mDevice;
- IDirect3DDevice9Ex *mDeviceEx; // Might be null if D3D9Ex is not supported.
-
- // A pool of event queries that are currently unused.
- std::vector<IDirect3DQuery9*> mEventQueryPool;
-
- VertexShaderCache mVertexShaderCache;
- PixelShaderCache mPixelShaderCache;
-
- D3DCAPS9 mDeviceCaps;
- D3DADAPTER_IDENTIFIER9 mAdapterIdentifier;
- HWND mDeviceWindow;
-
- bool mSceneStarted;
- EGLint mMaxSwapInterval;
- EGLint mMinSwapInterval;
bool mSoftwareDevice;
- bool mSupportsNonPower2Textures;
typedef std::set<Surface*> SurfaceSet;
SurfaceSet mSurfaceSet;
@@ -153,11 +80,8 @@ class Display
typedef std::set<gl::Context*> ContextSet;
ContextSet mContextSet;
- bool mDeviceLost;
- bool createDevice();
- void initializeDevice();
- bool resetDevice();
+ rx::Renderer *mRenderer;
void initExtensionString();
std::string mExtensionString;
diff --git a/src/3rdparty/angle/src/libEGL/Surface.cpp b/src/3rdparty/angle/src/libEGL/Surface.cpp
index d9e1887e85..a430a3530f 100644
--- a/src/3rdparty/angle/src/libEGL/Surface.cpp
+++ b/src/3rdparty/angle/src/libEGL/Surface.cpp
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -14,6 +14,8 @@
#include "common/debug.h"
#include "libGLESv2/Texture.h"
+#include "libGLESv2/renderer/SwapChain.h"
+#include "libGLESv2/main.h"
#include "libEGL/main.h"
#include "libEGL/Display.h"
@@ -23,14 +25,11 @@
namespace egl
{
-Surface::Surface(Display *display, const Config *config, HWND window, EGLint postSubBufferSupported)
+Surface::Surface(Display *display, const Config *config, HWND window, EGLint postSubBufferSupported)
: mDisplay(display), mConfig(config), mWindow(window), mPostSubBufferSupported(postSubBufferSupported)
{
+ mRenderer = mDisplay->getRenderer();
mSwapChain = NULL;
- mBackBuffer = NULL;
- mDepthStencil = NULL;
- mRenderTarget = NULL;
- mOffscreenTexture = NULL;
mShareHandle = NULL;
mTexture = NULL;
mTextureFormat = EGL_NO_TEXTURE;
@@ -40,6 +39,8 @@ Surface::Surface(Display *display, const Config *config, HWND window, EGLint pos
mRenderBuffer = EGL_BACK_BUFFER;
mSwapBehavior = EGL_BUFFER_PRESERVED;
mSwapInterval = -1;
+ mWidth = -1;
+ mHeight = -1;
setSwapInterval(1);
subclassWindow();
@@ -48,11 +49,8 @@ Surface::Surface(Display *display, const Config *config, HWND window, EGLint pos
Surface::Surface(Display *display, const Config *config, HANDLE shareHandle, EGLint width, EGLint height, EGLenum textureFormat, EGLenum textureType)
: mDisplay(display), mWindow(NULL), mConfig(config), mShareHandle(shareHandle), mWidth(width), mHeight(height), mPostSubBufferSupported(EGL_FALSE)
{
+ mRenderer = mDisplay->getRenderer();
mSwapChain = NULL;
- mBackBuffer = NULL;
- mDepthStencil = NULL;
- mRenderTarget = NULL;
- mOffscreenTexture = NULL;
mWindowSubclassed = false;
mTexture = NULL;
mTextureFormat = textureFormat;
@@ -76,8 +74,6 @@ bool Surface::initialize()
typedef HRESULT (STDAPICALLTYPE *PtrDwmIsCompositionEnabled)(BOOL*);
typedef HRESULT (STDAPICALLTYPE *PtrDwmSetPresentParameters)(HWND, DWM_PRESENT_PARAMETERS *);
- ASSERT(!mSwapChain && !mOffscreenTexture && !mDepthStencil);
-
if (!resetSwapChain())
return false;
@@ -118,260 +114,113 @@ bool Surface::initialize()
void Surface::release()
{
- if (mSwapChain)
- {
- mSwapChain->Release();
- mSwapChain = NULL;
- }
-
- if (mBackBuffer)
- {
- mBackBuffer->Release();
- mBackBuffer = NULL;
- }
-
- if (mDepthStencil)
- {
- mDepthStencil->Release();
- mDepthStencil = NULL;
- }
-
- if (mRenderTarget)
- {
- mRenderTarget->Release();
- mRenderTarget = NULL;
- }
-
- if (mOffscreenTexture)
- {
- mOffscreenTexture->Release();
- mOffscreenTexture = NULL;
- }
+ delete mSwapChain;
+ mSwapChain = NULL;
if (mTexture)
{
mTexture->releaseTexImage();
mTexture = NULL;
}
-
- mShareHandle = NULL;
}
bool Surface::resetSwapChain()
{
- if (!mWindow)
- {
- return resetSwapChain(mWidth, mHeight);
- }
-
- RECT windowRect;
- if (!GetClientRect(getWindowHandle(), &windowRect))
- {
- ASSERT(false);
+ ASSERT(!mSwapChain);
- ERR("Could not retrieve the window dimensions");
- return false;
- }
-
- return resetSwapChain(windowRect.right - windowRect.left, windowRect.bottom - windowRect.top);
-}
+ int width;
+ int height;
-bool Surface::resetSwapChain(int backbufferWidth, int backbufferHeight)
-{
- IDirect3DDevice9 *device = mDisplay->getDevice();
-
- if (device == NULL)
+ if (mWindow)
{
- return false;
- }
-
- // Evict all non-render target textures to system memory and release all resources
- // before reallocating them to free up as much video memory as possible.
- device->EvictManagedResources();
+ RECT windowRect;
+ if (!GetClientRect(getWindowHandle(), &windowRect))
+ {
+ ASSERT(false);
- HRESULT result;
+ ERR("Could not retrieve the window dimensions");
+ return error(EGL_BAD_SURFACE, false);
+ }
- // Release specific resources to free up memory for the new render target, while the
- // old render target still exists for the purpose of preserving its contents.
- if (mSwapChain)
- {
- mSwapChain->Release();
- mSwapChain = NULL;
+ width = windowRect.right - windowRect.left;
+ height = windowRect.bottom - windowRect.top;
}
-
- if (mBackBuffer)
+ else
{
- mBackBuffer->Release();
- mBackBuffer = NULL;
+ // non-window surface - size is determined at creation
+ width = mWidth;
+ height = mHeight;
}
- if (mOffscreenTexture)
+ mSwapChain = mRenderer->createSwapChain(mWindow, mShareHandle,
+ mConfig->mRenderTargetFormat,
+ mConfig->mDepthStencilFormat);
+ if (!mSwapChain)
{
- mOffscreenTexture->Release();
- mOffscreenTexture = NULL;
+ return error(EGL_BAD_ALLOC, false);
}
- if (mDepthStencil)
+ if (!resetSwapChain(width, height))
{
- mDepthStencil->Release();
- mDepthStencil = NULL;
+ delete mSwapChain;
+ mSwapChain = NULL;
+ return false;
}
- HANDLE *pShareHandle = NULL;
- if (!mWindow && mDisplay->shareHandleSupported())
- {
- pShareHandle = &mShareHandle;
- }
+ return true;
+}
- // CreateTexture will fail on zero dimensions, so just release old target
- if (!backbufferWidth || !backbufferHeight)
- {
- if (mRenderTarget)
- {
- mRenderTarget->Release();
- mRenderTarget = NULL;
- }
+bool Surface::resizeSwapChain(int backbufferWidth, int backbufferHeight)
+{
+ ASSERT(mSwapChain);
+ // Prevent bad swap chain resize by calling reset if size is invalid
+ if (backbufferWidth < 1 || backbufferHeight < 1)
+ {
mWidth = backbufferWidth;
mHeight = backbufferHeight;
- mPresentIntervalDirty = false;
-
- return true;
+ return mSwapChain->reset(0, 0, mSwapInterval) == EGL_SUCCESS;
}
- result = device->CreateTexture(backbufferWidth, backbufferHeight, 1, D3DUSAGE_RENDERTARGET,
- mConfig->mRenderTargetFormat, D3DPOOL_DEFAULT, &mOffscreenTexture, pShareHandle);
- if (FAILED(result))
- {
- ERR("Could not create offscreen texture: %08lX", result);
- release();
+ EGLint status = mSwapChain->resize(backbufferWidth, backbufferHeight);
- if(isDeviceLostError(result))
- {
- mDisplay->notifyDeviceLost();
- return false;
- }
- else
- {
- return error(EGL_BAD_ALLOC, false);
- }
+ if (status == EGL_CONTEXT_LOST)
+ {
+ mDisplay->notifyDeviceLost();
+ return false;
}
-
- IDirect3DSurface9 *oldRenderTarget = mRenderTarget;
-
- result = mOffscreenTexture->GetSurfaceLevel(0, &mRenderTarget);
- ASSERT(SUCCEEDED(result));
-
- if (oldRenderTarget)
+ else if (status != EGL_SUCCESS)
{
- RECT rect =
- {
- 0, 0,
- mWidth, mHeight
- };
-
- if (rect.right > static_cast<LONG>(backbufferWidth))
- {
- rect.right = backbufferWidth;
- }
+ return error(status, false);
+ }
- if (rect.bottom > static_cast<LONG>(backbufferHeight))
- {
- rect.bottom = backbufferHeight;
- }
+ mWidth = backbufferWidth;
+ mHeight = backbufferHeight;
- mDisplay->endScene();
+ return true;
+}
- result = device->StretchRect(oldRenderTarget, &rect, mRenderTarget, &rect, D3DTEXF_NONE);
- ASSERT(SUCCEEDED(result));
+bool Surface::resetSwapChain(int backbufferWidth, int backbufferHeight)
+{
+ ASSERT(backbufferWidth >= 0 && backbufferHeight >= 0);
+ ASSERT(mSwapChain);
- oldRenderTarget->Release();
- }
+ EGLint status = mSwapChain->reset(backbufferWidth, backbufferHeight, mSwapInterval);
- if (mWindow)
+ if (status == EGL_CONTEXT_LOST)
{
- D3DPRESENT_PARAMETERS presentParameters = {0};
- presentParameters.AutoDepthStencilFormat = mConfig->mDepthStencilFormat;
- presentParameters.BackBufferCount = 1;
- presentParameters.BackBufferFormat = mConfig->mRenderTargetFormat;
- presentParameters.EnableAutoDepthStencil = FALSE;
- presentParameters.Flags = 0;
- presentParameters.hDeviceWindow = getWindowHandle();
- presentParameters.MultiSampleQuality = 0; // FIXME: Unimplemented
- presentParameters.MultiSampleType = D3DMULTISAMPLE_NONE; // FIXME: Unimplemented
- presentParameters.PresentationInterval = mPresentInterval;
- presentParameters.SwapEffect = D3DSWAPEFFECT_DISCARD;
- presentParameters.Windowed = TRUE;
- presentParameters.BackBufferWidth = backbufferWidth;
- presentParameters.BackBufferHeight = backbufferHeight;
-
- // http://crbug.com/140239
- // http://crbug.com/143434
- //
- // Some AMD/Intel switchable systems / drivers appear to round swap chain surfaces to a multiple of 64 pixels in width
- // when using the integrated Intel. This rounds the width up rather than down.
- //
- // Some non-switchable AMD GPUs / drivers do not respect the source rectangle to Present. Therefore, when the vendor ID
- // is not Intel, the back buffer width must be exactly the same width as the window or horizontal scaling will occur.
- D3DADAPTER_IDENTIFIER9* adapterIdentifier = mDisplay->getAdapterIdentifier();
- if (adapterIdentifier->VendorId == VENDOR_ID_INTEL)
- {
- presentParameters.BackBufferWidth = (presentParameters.BackBufferWidth + 63) / 64 * 64;
- }
-
- result = device->CreateAdditionalSwapChain(&presentParameters, &mSwapChain);
-
- if (FAILED(result))
- {
- ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY || result == D3DERR_INVALIDCALL || result == D3DERR_DEVICELOST);
-
- ERR("Could not create additional swap chains or offscreen surfaces: %08lX", result);
- release();
-
- if(isDeviceLostError(result))
- {
- mDisplay->notifyDeviceLost();
- return false;
- }
- else
- {
- return error(EGL_BAD_ALLOC, false);
- }
- }
-
- result = mSwapChain->GetBackBuffer(0, D3DBACKBUFFER_TYPE_MONO, &mBackBuffer);
- ASSERT(SUCCEEDED(result));
- InvalidateRect(mWindow, NULL, FALSE);
+ mRenderer->notifyDeviceLost();
+ return false;
}
-
- if (mConfig->mDepthStencilFormat != D3DFMT_UNKNOWN)
+ else if (status != EGL_SUCCESS)
{
- result = device->CreateDepthStencilSurface(backbufferWidth, backbufferHeight, mConfig->mDepthStencilFormat, D3DMULTISAMPLE_NONE,
- 0, FALSE, &mDepthStencil, NULL);
-
- if (FAILED(result))
- {
- ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY || result == D3DERR_INVALIDCALL);
-
- ERR("Could not create depthstencil surface for new swap chain: 0x%08X", result);
- release();
-
- if(isDeviceLostError(result))
- {
- mDisplay->notifyDeviceLost();
- return false;
- }
- else
- {
- return error(EGL_BAD_ALLOC, false);
- }
- }
+ return error(status, false);
}
mWidth = backbufferWidth;
mHeight = backbufferHeight;
+ mSwapIntervalDirty = false;
- mPresentIntervalDirty = false;
return true;
}
@@ -397,86 +246,18 @@ bool Surface::swapRect(EGLint x, EGLint y, EGLint width, EGLint height)
return true;
}
- IDirect3DDevice9 *device = mDisplay->getDevice();
-
- // Disable all pipeline operations
- device->SetRenderState(D3DRS_ZENABLE, D3DZB_FALSE);
- device->SetRenderState(D3DRS_FILLMODE, D3DFILL_SOLID);
- device->SetRenderState(D3DRS_ALPHATESTENABLE, FALSE);
- device->SetRenderState(D3DRS_ALPHABLENDENABLE, FALSE);
- device->SetRenderState(D3DRS_CULLMODE, D3DCULL_NONE);
- device->SetRenderState(D3DRS_STENCILENABLE, FALSE);
- device->SetRenderState(D3DRS_CLIPPLANEENABLE, 0);
- device->SetRenderState(D3DRS_COLORWRITEENABLE, D3DCOLORWRITEENABLE_ALPHA | D3DCOLORWRITEENABLE_BLUE | D3DCOLORWRITEENABLE_GREEN | D3DCOLORWRITEENABLE_RED);
- device->SetRenderState(D3DRS_SRGBWRITEENABLE, FALSE);
- device->SetRenderState(D3DRS_SCISSORTESTENABLE, FALSE);
- device->SetPixelShader(NULL);
- device->SetVertexShader(NULL);
-
- device->SetRenderTarget(0, mBackBuffer);
- device->SetDepthStencilSurface(NULL);
-
- device->SetTexture(0, mOffscreenTexture);
- device->SetTextureStageState(0, D3DTSS_COLOROP, D3DTOP_SELECTARG1);
- device->SetTextureStageState(0, D3DTSS_COLORARG1, D3DTA_TEXTURE);
- device->SetTextureStageState(1, D3DTSS_COLOROP, D3DTOP_DISABLE);
- device->SetSamplerState(0, D3DSAMP_MAGFILTER, D3DTEXF_POINT);
- device->SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_POINT);
- device->SetSamplerState(0, D3DSAMP_ADDRESSU, D3DTADDRESS_CLAMP);
- device->SetSamplerState(0, D3DSAMP_ADDRESSV, D3DTADDRESS_CLAMP);
- device->SetFVF(D3DFVF_XYZRHW | D3DFVF_TEX1);
-
- D3DVIEWPORT9 viewport = {0, 0, mWidth, mHeight, 0.0f, 1.0f};
- device->SetViewport(&viewport);
-
- float x1 = x - 0.5f;
- float y1 = (mHeight - y - height) - 0.5f;
- float x2 = (x + width) - 0.5f;
- float y2 = (mHeight - y) - 0.5f;
-
- float u1 = x / float(mWidth);
- float v1 = y / float(mHeight);
- float u2 = (x + width) / float(mWidth);
- float v2 = (y + height) / float(mHeight);
-
- float quad[4][6] = {{x1, y1, 0.0f, 1.0f, u1, v2},
- {x2, y1, 0.0f, 1.0f, u2, v2},
- {x2, y2, 0.0f, 1.0f, u2, v1},
- {x1, y2, 0.0f, 1.0f, u1, v1}}; // x, y, z, rhw, u, v
-
- mDisplay->startScene();
- device->DrawPrimitiveUP(D3DPT_TRIANGLEFAN, 2, quad, 6 * sizeof(float));
- mDisplay->endScene();
-
- device->SetTexture(0, NULL);
-
- RECT rect =
- {
- x, mHeight - y - height,
- x + width, mHeight - y
- };
-
- HRESULT result = mSwapChain->Present(&rect, &rect, NULL, NULL, 0);
+ EGLint status = mSwapChain->swapRect(x, y, width, height);
- gl::Context *context = static_cast<gl::Context*>(glGetCurrentContext());
- if (context)
+ if (status == EGL_CONTEXT_LOST)
{
- context->markAllStateDirty();
- }
-
- if (isDeviceLostError(result))
- {
- mDisplay->notifyDeviceLost();
+ mRenderer->notifyDeviceLost();
return false;
}
-
- if (result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY || result == D3DERR_DRIVERINTERNALERROR)
+ else if (status != EGL_SUCCESS)
{
- return error(EGL_BAD_ALLOC, false);
+ return error(status, false);
}
- ASSERT(SUCCEEDED(result));
-
checkForOutOfDateSwapChain();
return true;
@@ -572,9 +353,17 @@ bool Surface::checkForOutOfDateSwapChain()
int clientHeight = client.bottom - client.top;
bool sizeDirty = clientWidth != getWidth() || clientHeight != getHeight();
- if (sizeDirty || mPresentIntervalDirty)
+ if (mSwapIntervalDirty)
{
resetSwapChain(clientWidth, clientHeight);
+ }
+ else if (sizeDirty)
+ {
+ resizeSwapChain(clientWidth, clientHeight);
+ }
+
+ if (mSwapIntervalDirty || sizeDirty)
+ {
if (static_cast<egl::Surface*>(getCurrentDrawSurface()) == this)
{
glMakeCurrent(glGetCurrentContext(), static_cast<egl::Display*>(getCurrentDisplay()), this);
@@ -582,22 +371,8 @@ bool Surface::checkForOutOfDateSwapChain()
return true;
}
- return false;
-}
-
-DWORD Surface::convertInterval(EGLint interval)
-{
- switch(interval)
- {
- case 0: return D3DPRESENT_INTERVAL_IMMEDIATE;
- case 1: return D3DPRESENT_INTERVAL_ONE;
- case 2: return D3DPRESENT_INTERVAL_TWO;
- case 3: return D3DPRESENT_INTERVAL_THREE;
- case 4: return D3DPRESENT_INTERVAL_FOUR;
- default: UNREACHABLE();
- }
- return D3DPRESENT_INTERVAL_DEFAULT;
+ return false;
}
bool Surface::swap()
@@ -631,38 +406,9 @@ EGLint Surface::isPostSubBufferSupported() const
return mPostSubBufferSupported;
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *Surface::getRenderTarget()
-{
- if (mRenderTarget)
- {
- mRenderTarget->AddRef();
- }
-
- return mRenderTarget;
-}
-
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *Surface::getDepthStencil()
-{
- if (mDepthStencil)
- {
- mDepthStencil->AddRef();
- }
-
- return mDepthStencil;
-}
-
-IDirect3DTexture9 *Surface::getOffscreenTexture()
+rx::SwapChain *Surface::getSwapChain() const
{
- if (mOffscreenTexture)
- {
- mOffscreenTexture->AddRef();
- }
-
- return mOffscreenTexture;
+ return mSwapChain;
}
void Surface::setSwapInterval(EGLint interval)
@@ -673,11 +419,10 @@ void Surface::setSwapInterval(EGLint interval)
}
mSwapInterval = interval;
- mSwapInterval = std::max(mSwapInterval, mDisplay->getMinSwapInterval());
- mSwapInterval = std::min(mSwapInterval, mDisplay->getMaxSwapInterval());
+ mSwapInterval = std::max(mSwapInterval, mRenderer->getMinSwapInterval());
+ mSwapInterval = std::min(mSwapInterval, mRenderer->getMaxSwapInterval());
- mPresentInterval = convertInterval(mSwapInterval);
- mPresentIntervalDirty = true;
+ mSwapIntervalDirty = true;
}
EGLenum Surface::getTextureFormat() const
@@ -700,7 +445,7 @@ gl::Texture2D *Surface::getBoundTexture() const
return mTexture;
}
-D3DFORMAT Surface::getFormat() const
+EGLenum Surface::getFormat() const
{
return mConfig->mRenderTargetFormat;
}
diff --git a/src/3rdparty/angle/src/libEGL/Surface.h b/src/3rdparty/angle/src/libEGL/Surface.h
index 40bd7028ab..938b800cdd 100644
--- a/src/3rdparty/angle/src/libEGL/Surface.h
+++ b/src/3rdparty/angle/src/libEGL/Surface.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -8,12 +8,11 @@
// such as the client area of a window, including any back buffers.
// Implements EGLSurface and related functionality. [EGL 1.4] section 2.2 page 3.
-#ifndef INCLUDE_SURFACE_H_
-#define INCLUDE_SURFACE_H_
+#ifndef LIBEGL_SURFACE_H_
+#define LIBEGL_SURFACE_H_
#define EGLAPI
#include <EGL/egl.h>
-#include <d3d9.h>
#include "common/angleutils.h"
@@ -21,6 +20,11 @@ namespace gl
{
class Texture2D;
}
+namespace rx
+{
+class Renderer;
+class SwapChain;
+}
namespace egl
{
@@ -48,18 +52,14 @@ class Surface
virtual EGLint isPostSubBufferSupported() const;
- virtual IDirect3DSurface9 *getRenderTarget();
- virtual IDirect3DSurface9 *getDepthStencil();
- virtual IDirect3DTexture9 *getOffscreenTexture();
-
- HANDLE getShareHandle() { return mShareHandle; }
+ virtual rx::SwapChain *getSwapChain() const;
void setSwapInterval(EGLint interval);
bool checkForOutOfDateSwapChain(); // Returns true if swapchain changed due to resize or interval update
virtual EGLenum getTextureFormat() const;
virtual EGLenum getTextureTarget() const;
- virtual D3DFORMAT getFormat() const;
+ virtual EGLenum getFormat() const;
virtual void setBoundTexture(gl::Texture2D *texture);
virtual gl::Texture2D *getBoundTexture() const;
@@ -68,19 +68,16 @@ private:
DISALLOW_COPY_AND_ASSIGN(Surface);
Display *const mDisplay;
- IDirect3DSwapChain9 *mSwapChain;
- IDirect3DSurface9 *mBackBuffer;
- IDirect3DSurface9 *mDepthStencil;
- IDirect3DSurface9* mRenderTarget;
- IDirect3DTexture9* mOffscreenTexture;
+ rx::Renderer *mRenderer;
HANDLE mShareHandle;
+ rx::SwapChain *mSwapChain;
void subclassWindow();
void unsubclassWindow();
+ bool resizeSwapChain(int backbufferWidth, int backbufferHeight);
bool resetSwapChain(int backbufferWidth, int backbufferHeight);
bool swapRect(EGLint x, EGLint y, EGLint width, EGLint height);
- static DWORD convertInterval(EGLint interval);
const HWND mWindow; // Window that the surface is created for.
bool mWindowSubclassed; // Indicates whether we successfully subclassed mWindow for WM_RESIZE hooking
@@ -103,10 +100,9 @@ private:
EGLint mSwapInterval;
EGLint mPostSubBufferSupported;
- DWORD mPresentInterval;
- bool mPresentIntervalDirty;
+ bool mSwapIntervalDirty;
gl::Texture2D *mTexture;
};
}
-#endif // INCLUDE_SURFACE_H_
+#endif // LIBEGL_SURFACE_H_
diff --git a/src/3rdparty/angle/src/libEGL/libEGL.cpp b/src/3rdparty/angle/src/libEGL/libEGL.cpp
index 25df1c8c24..7fca456cf5 100644
--- a/src/3rdparty/angle/src/libEGL/libEGL.cpp
+++ b/src/3rdparty/angle/src/libEGL/libEGL.cpp
@@ -12,21 +12,23 @@
#include "common/version.h"
#include "libGLESv2/Context.h"
#include "libGLESv2/Texture.h"
+#include "libGLESv2/main.h"
+#include "libGLESv2/renderer/SwapChain.h"
#include "libEGL/main.h"
#include "libEGL/Display.h"
-
+#include "libEGL/Surface.h"
bool validateDisplay(egl::Display *display)
{
if (display == EGL_NO_DISPLAY)
{
- return error(EGL_BAD_DISPLAY, false);
+ return egl::error(EGL_BAD_DISPLAY, false);
}
if (!display->isInitialized())
{
- return error(EGL_NOT_INITIALIZED, false);
+ return egl::error(EGL_NOT_INITIALIZED, false);
}
return true;
@@ -41,7 +43,7 @@ bool validateConfig(egl::Display *display, EGLConfig config)
if (!display->isValidConfig(config))
{
- return error(EGL_BAD_CONFIG, false);
+ return egl::error(EGL_BAD_CONFIG, false);
}
return true;
@@ -56,7 +58,7 @@ bool validateContext(egl::Display *display, gl::Context *context)
if (!display->isValidContext(context))
{
- return error(EGL_BAD_CONTEXT, false);
+ return egl::error(EGL_BAD_CONTEXT, false);
}
return true;
@@ -71,7 +73,7 @@ bool validateSurface(egl::Display *display, egl::Surface *surface)
if (!display->isValidSurface(surface))
{
- return error(EGL_BAD_SURFACE, false);
+ return egl::error(EGL_BAD_SURFACE, false);
}
return true;
@@ -103,7 +105,7 @@ EGLDisplay __stdcall eglGetDisplay(EGLNativeDisplayType display_id)
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_NO_DISPLAY);
+ return egl::error(EGL_BAD_ALLOC, EGL_NO_DISPLAY);
}
}
@@ -116,24 +118,24 @@ EGLBoolean __stdcall eglInitialize(EGLDisplay dpy, EGLint *major, EGLint *minor)
{
if (dpy == EGL_NO_DISPLAY)
{
- return error(EGL_BAD_DISPLAY, EGL_FALSE);
+ return egl::error(EGL_BAD_DISPLAY, EGL_FALSE);
}
egl::Display *display = static_cast<egl::Display*>(dpy);
if (!display->initialize())
{
- return error(EGL_NOT_INITIALIZED, EGL_FALSE);
+ return egl::error(EGL_NOT_INITIALIZED, EGL_FALSE);
}
if (major) *major = 1;
if (minor) *minor = 4;
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -145,18 +147,18 @@ EGLBoolean __stdcall eglTerminate(EGLDisplay dpy)
{
if (dpy == EGL_NO_DISPLAY)
{
- return error(EGL_BAD_DISPLAY, EGL_FALSE);
+ return egl::error(EGL_BAD_DISPLAY, EGL_FALSE);
}
egl::Display *display = static_cast<egl::Display*>(dpy);
display->terminate();
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -176,20 +178,20 @@ const char *__stdcall eglQueryString(EGLDisplay dpy, EGLint name)
switch (name)
{
case EGL_CLIENT_APIS:
- return success("OpenGL_ES");
+ return egl::success("OpenGL_ES");
case EGL_EXTENSIONS:
return display->getExtensionString();
case EGL_VENDOR:
- return success("Google Inc.");
+ return egl::success("Google Inc.");
case EGL_VERSION:
- return success("1.4 (ANGLE " VERSION_STRING ")");
+ return egl::success("1.4 (ANGLE " VERSION_STRING ")");
}
- return error(EGL_BAD_PARAMETER, (const char*)NULL);
+ return egl::error(EGL_BAD_PARAMETER, (const char*)NULL);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, (const char*)NULL);
+ return egl::error(EGL_BAD_ALLOC, (const char*)NULL);
}
}
@@ -210,21 +212,21 @@ EGLBoolean __stdcall eglGetConfigs(EGLDisplay dpy, EGLConfig *configs, EGLint co
if (!num_config)
{
- return error(EGL_BAD_PARAMETER, EGL_FALSE);
+ return egl::error(EGL_BAD_PARAMETER, EGL_FALSE);
}
const EGLint attribList[] = {EGL_NONE};
if (!display->getConfigs(configs, attribList, config_size, num_config))
{
- return error(EGL_BAD_ATTRIBUTE, EGL_FALSE);
+ return egl::error(EGL_BAD_ATTRIBUTE, EGL_FALSE);
}
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -245,7 +247,7 @@ EGLBoolean __stdcall eglChooseConfig(EGLDisplay dpy, const EGLint *attrib_list,
if (!num_config)
{
- return error(EGL_BAD_PARAMETER, EGL_FALSE);
+ return egl::error(EGL_BAD_PARAMETER, EGL_FALSE);
}
const EGLint attribList[] = {EGL_NONE};
@@ -257,11 +259,11 @@ EGLBoolean __stdcall eglChooseConfig(EGLDisplay dpy, const EGLint *attrib_list,
display->getConfigs(configs, attrib_list, config_size, num_config);
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -281,14 +283,14 @@ EGLBoolean __stdcall eglGetConfigAttrib(EGLDisplay dpy, EGLConfig config, EGLint
if (!display->getConfigAttrib(config, attribute, value))
{
- return error(EGL_BAD_ATTRIBUTE, EGL_FALSE);
+ return egl::error(EGL_BAD_ATTRIBUTE, EGL_FALSE);
}
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -310,14 +312,14 @@ EGLSurface __stdcall eglCreateWindowSurface(EGLDisplay dpy, EGLConfig config, EG
if (!IsWindow(window))
{
- return error(EGL_BAD_NATIVE_WINDOW, EGL_NO_SURFACE);
+ return egl::error(EGL_BAD_NATIVE_WINDOW, EGL_NO_SURFACE);
}
return display->createWindowSurface(window, config, attrib_list);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_NO_SURFACE);
+ return egl::error(EGL_BAD_ALLOC, EGL_NO_SURFACE);
}
}
@@ -339,7 +341,7 @@ EGLSurface __stdcall eglCreatePbufferSurface(EGLDisplay dpy, EGLConfig config, c
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_NO_SURFACE);
+ return egl::error(EGL_BAD_ALLOC, EGL_NO_SURFACE);
}
}
@@ -359,11 +361,11 @@ EGLSurface __stdcall eglCreatePixmapSurface(EGLDisplay dpy, EGLConfig config, EG
UNIMPLEMENTED(); // FIXME
- return success(EGL_NO_SURFACE);
+ return egl::success(EGL_NO_SURFACE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_NO_SURFACE);
+ return egl::error(EGL_BAD_ALLOC, EGL_NO_SURFACE);
}
}
@@ -383,16 +385,16 @@ EGLBoolean __stdcall eglDestroySurface(EGLDisplay dpy, EGLSurface surface)
if (surface == EGL_NO_SURFACE)
{
- return error(EGL_BAD_SURFACE, EGL_FALSE);
+ return egl::error(EGL_BAD_SURFACE, EGL_FALSE);
}
display->destroySurface((egl::Surface*)surface);
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -413,7 +415,7 @@ EGLBoolean __stdcall eglQuerySurface(EGLDisplay dpy, EGLSurface surface, EGLint
if (surface == EGL_NO_SURFACE)
{
- return error(EGL_BAD_SURFACE, EGL_FALSE);
+ return egl::error(EGL_BAD_SURFACE, EGL_FALSE);
}
switch (attribute)
@@ -470,14 +472,14 @@ EGLBoolean __stdcall eglQuerySurface(EGLDisplay dpy, EGLSurface surface, EGLint
*value = eglSurface->isPostSubBufferSupported();
break;
default:
- return error(EGL_BAD_ATTRIBUTE, EGL_FALSE);
+ return egl::error(EGL_BAD_ATTRIBUTE, EGL_FALSE);
}
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -498,23 +500,26 @@ EGLBoolean __stdcall eglQuerySurfacePointerANGLE(EGLDisplay dpy, EGLSurface surf
if (surface == EGL_NO_SURFACE)
{
- return error(EGL_BAD_SURFACE, EGL_FALSE);
+ return egl::error(EGL_BAD_SURFACE, EGL_FALSE);
}
switch (attribute)
{
case EGL_D3D_TEXTURE_2D_SHARE_HANDLE_ANGLE:
- *value = (void*) eglSurface->getShareHandle();
+ {
+ rx::SwapChain *swapchain = eglSurface->getSwapChain();
+ *value = (void*) (swapchain ? swapchain->getShareHandle() : NULL);
+ }
break;
default:
- return error(EGL_BAD_ATTRIBUTE, EGL_FALSE);
+ return egl::error(EGL_BAD_ATTRIBUTE, EGL_FALSE);
}
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -528,20 +533,20 @@ EGLBoolean __stdcall eglBindAPI(EGLenum api)
{
case EGL_OPENGL_API:
case EGL_OPENVG_API:
- return error(EGL_BAD_PARAMETER, EGL_FALSE); // Not supported by this implementation
+ return egl::error(EGL_BAD_PARAMETER, EGL_FALSE); // Not supported by this implementation
case EGL_OPENGL_ES_API:
break;
default:
- return error(EGL_BAD_PARAMETER, EGL_FALSE);
+ return egl::error(EGL_BAD_PARAMETER, EGL_FALSE);
}
egl::setCurrentAPI(api);
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -553,11 +558,11 @@ EGLenum __stdcall eglQueryAPI(void)
{
EGLenum API = egl::getCurrentAPI();
- return success(API);
+ return egl::success(API);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -569,11 +574,11 @@ EGLBoolean __stdcall eglWaitClient(void)
{
UNIMPLEMENTED(); // FIXME
- return success(0);
+ return egl::success(0);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -585,11 +590,11 @@ EGLBoolean __stdcall eglReleaseThread(void)
{
eglMakeCurrent(EGL_NO_DISPLAY, EGL_NO_CONTEXT, EGL_NO_SURFACE, EGL_NO_SURFACE);
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -610,14 +615,14 @@ EGLSurface __stdcall eglCreatePbufferFromClientBuffer(EGLDisplay dpy, EGLenum bu
if (buftype != EGL_D3D_TEXTURE_2D_SHARE_HANDLE_ANGLE || !buffer)
{
- return error(EGL_BAD_PARAMETER, EGL_NO_SURFACE);
+ return egl::error(EGL_BAD_PARAMETER, EGL_NO_SURFACE);
}
return display->createOffscreenSurface(config, (HANDLE)buffer, attrib_list);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_NO_SURFACE);
+ return egl::error(EGL_BAD_ALLOC, EGL_NO_SURFACE);
}
}
@@ -638,11 +643,11 @@ EGLBoolean __stdcall eglSurfaceAttrib(EGLDisplay dpy, EGLSurface surface, EGLint
UNIMPLEMENTED(); // FIXME
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -662,34 +667,34 @@ EGLBoolean __stdcall eglBindTexImage(EGLDisplay dpy, EGLSurface surface, EGLint
if (buffer != EGL_BACK_BUFFER)
{
- return error(EGL_BAD_PARAMETER, EGL_FALSE);
+ return egl::error(EGL_BAD_PARAMETER, EGL_FALSE);
}
if (surface == EGL_NO_SURFACE || eglSurface->getWindowHandle())
{
- return error(EGL_BAD_SURFACE, EGL_FALSE);
+ return egl::error(EGL_BAD_SURFACE, EGL_FALSE);
}
if (eglSurface->getBoundTexture())
{
- return error(EGL_BAD_ACCESS, EGL_FALSE);
+ return egl::error(EGL_BAD_ACCESS, EGL_FALSE);
}
if (eglSurface->getTextureFormat() == EGL_NO_TEXTURE)
{
- return error(EGL_BAD_MATCH, EGL_FALSE);
+ return egl::error(EGL_BAD_MATCH, EGL_FALSE);
}
if (!glBindTexImage(eglSurface))
{
- return error(EGL_BAD_MATCH, EGL_FALSE);
+ return egl::error(EGL_BAD_MATCH, EGL_FALSE);
}
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -709,17 +714,17 @@ EGLBoolean __stdcall eglReleaseTexImage(EGLDisplay dpy, EGLSurface surface, EGLi
if (buffer != EGL_BACK_BUFFER)
{
- return error(EGL_BAD_PARAMETER, EGL_FALSE);
+ return egl::error(EGL_BAD_PARAMETER, EGL_FALSE);
}
if (surface == EGL_NO_SURFACE || eglSurface->getWindowHandle())
{
- return error(EGL_BAD_SURFACE, EGL_FALSE);
+ return egl::error(EGL_BAD_SURFACE, EGL_FALSE);
}
if (eglSurface->getTextureFormat() == EGL_NO_TEXTURE)
{
- return error(EGL_BAD_MATCH, EGL_FALSE);
+ return egl::error(EGL_BAD_MATCH, EGL_FALSE);
}
gl::Texture2D *texture = eglSurface->getBoundTexture();
@@ -729,11 +734,11 @@ EGLBoolean __stdcall eglReleaseTexImage(EGLDisplay dpy, EGLSurface surface, EGLi
texture->releaseTexImage();
}
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -754,16 +759,16 @@ EGLBoolean __stdcall eglSwapInterval(EGLDisplay dpy, EGLint interval)
if (draw_surface == NULL)
{
- return error(EGL_BAD_SURFACE, EGL_FALSE);
+ return egl::error(EGL_BAD_SURFACE, EGL_FALSE);
}
draw_surface->setSwapInterval(interval);
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -791,32 +796,32 @@ EGLContext __stdcall eglCreateContext(EGLDisplay dpy, EGLConfig config, EGLConte
case EGL_CONTEXT_OPENGL_ROBUST_ACCESS_EXT:
if (attribute[1] == EGL_TRUE)
{
- return error(EGL_BAD_CONFIG, EGL_NO_CONTEXT); // Unimplemented
+ return egl::error(EGL_BAD_CONFIG, EGL_NO_CONTEXT); // Unimplemented
// robust_access = true;
}
else if (attribute[1] != EGL_FALSE)
- return error(EGL_BAD_ATTRIBUTE, EGL_NO_CONTEXT);
+ return egl::error(EGL_BAD_ATTRIBUTE, EGL_NO_CONTEXT);
break;
case EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY_EXT:
if (attribute[1] == EGL_LOSE_CONTEXT_ON_RESET_EXT)
reset_notification = true;
else if (attribute[1] != EGL_NO_RESET_NOTIFICATION_EXT)
- return error(EGL_BAD_ATTRIBUTE, EGL_NO_CONTEXT);
+ return egl::error(EGL_BAD_ATTRIBUTE, EGL_NO_CONTEXT);
break;
default:
- return error(EGL_BAD_ATTRIBUTE, EGL_NO_CONTEXT);
+ return egl::error(EGL_BAD_ATTRIBUTE, EGL_NO_CONTEXT);
}
}
}
if (client_version != 2)
{
- return error(EGL_BAD_CONFIG, EGL_NO_CONTEXT);
+ return egl::error(EGL_BAD_CONFIG, EGL_NO_CONTEXT);
}
if (share_context && static_cast<gl::Context*>(share_context)->isResetNotificationEnabled() != reset_notification)
{
- return error(EGL_BAD_MATCH, EGL_NO_CONTEXT);
+ return egl::error(EGL_BAD_MATCH, EGL_NO_CONTEXT);
}
egl::Display *display = static_cast<egl::Display*>(dpy);
@@ -829,13 +834,13 @@ EGLContext __stdcall eglCreateContext(EGLDisplay dpy, EGLConfig config, EGLConte
EGLContext context = display->createContext(config, static_cast<gl::Context*>(share_context), reset_notification, robust_access);
if (context)
- return success(context);
+ return egl::success(context);
else
- return error(EGL_CONTEXT_LOST, EGL_NO_CONTEXT);
+ return egl::error(EGL_CONTEXT_LOST, EGL_NO_CONTEXT);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_NO_CONTEXT);
+ return egl::error(EGL_BAD_ALLOC, EGL_NO_CONTEXT);
}
}
@@ -855,16 +860,16 @@ EGLBoolean __stdcall eglDestroyContext(EGLDisplay dpy, EGLContext ctx)
if (ctx == EGL_NO_CONTEXT)
{
- return error(EGL_BAD_CONTEXT, EGL_FALSE);
+ return egl::error(EGL_BAD_CONTEXT, EGL_FALSE);
}
display->destroyContext(context);
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -877,22 +882,21 @@ EGLBoolean __stdcall eglMakeCurrent(EGLDisplay dpy, EGLSurface draw, EGLSurface
{
egl::Display *display = static_cast<egl::Display*>(dpy);
gl::Context *context = static_cast<gl::Context*>(ctx);
- IDirect3DDevice9 *device = display->getDevice();
- if (!device || display->testDeviceLost())
+ if (ctx != EGL_NO_CONTEXT && !validateContext(display, context))
{
- display->notifyDeviceLost();
return EGL_FALSE;
}
- if (display->isDeviceLost())
+ rx::Renderer *renderer = display->getRenderer();
+ if (renderer->testDeviceLost(true))
{
- return error(EGL_CONTEXT_LOST, EGL_FALSE);
+ return EGL_FALSE;
}
- if (ctx != EGL_NO_CONTEXT && !validateContext(display, context))
+ if (renderer->isDeviceLost())
{
- return EGL_FALSE;
+ return egl::error(EGL_CONTEXT_LOST, EGL_FALSE);
}
if ((draw != EGL_NO_SURFACE && !validateSurface(display, static_cast<egl::Surface*>(draw))) ||
@@ -912,11 +916,11 @@ EGLBoolean __stdcall eglMakeCurrent(EGLDisplay dpy, EGLSurface draw, EGLSurface
glMakeCurrent(context, display, static_cast<egl::Surface*>(draw));
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -928,11 +932,11 @@ EGLContext __stdcall eglGetCurrentContext(void)
{
EGLContext context = glGetCurrentContext();
- return success(context);
+ return egl::success(context);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_NO_CONTEXT);
+ return egl::error(EGL_BAD_ALLOC, EGL_NO_CONTEXT);
}
}
@@ -945,21 +949,21 @@ EGLSurface __stdcall eglGetCurrentSurface(EGLint readdraw)
if (readdraw == EGL_READ)
{
EGLSurface read = egl::getCurrentReadSurface();
- return success(read);
+ return egl::success(read);
}
else if (readdraw == EGL_DRAW)
{
EGLSurface draw = egl::getCurrentDrawSurface();
- return success(draw);
+ return egl::success(draw);
}
else
{
- return error(EGL_BAD_PARAMETER, EGL_NO_SURFACE);
+ return egl::error(EGL_BAD_PARAMETER, EGL_NO_SURFACE);
}
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_NO_SURFACE);
+ return egl::error(EGL_BAD_ALLOC, EGL_NO_SURFACE);
}
}
@@ -971,11 +975,11 @@ EGLDisplay __stdcall eglGetCurrentDisplay(void)
{
EGLDisplay dpy = egl::getCurrentDisplay();
- return success(dpy);
+ return egl::success(dpy);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_NO_DISPLAY);
+ return egl::error(EGL_BAD_ALLOC, EGL_NO_DISPLAY);
}
}
@@ -996,11 +1000,11 @@ EGLBoolean __stdcall eglQueryContext(EGLDisplay dpy, EGLContext ctx, EGLint attr
UNIMPLEMENTED(); // FIXME
- return success(0);
+ return egl::success(0);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -1012,11 +1016,11 @@ EGLBoolean __stdcall eglWaitGL(void)
{
UNIMPLEMENTED(); // FIXME
- return success(0);
+ return egl::success(0);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -1028,11 +1032,11 @@ EGLBoolean __stdcall eglWaitNative(EGLint engine)
{
UNIMPLEMENTED(); // FIXME
- return success(0);
+ return egl::success(0);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -1050,24 +1054,24 @@ EGLBoolean __stdcall eglSwapBuffers(EGLDisplay dpy, EGLSurface surface)
return EGL_FALSE;
}
- if (display->isDeviceLost())
+ if (display->getRenderer()->isDeviceLost())
{
- return error(EGL_CONTEXT_LOST, EGL_FALSE);
+ return egl::error(EGL_CONTEXT_LOST, EGL_FALSE);
}
if (surface == EGL_NO_SURFACE)
{
- return error(EGL_BAD_SURFACE, EGL_FALSE);
+ return egl::error(EGL_BAD_SURFACE, EGL_FALSE);
}
if (eglSurface->swap())
{
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
return EGL_FALSE;
@@ -1087,18 +1091,18 @@ EGLBoolean __stdcall eglCopyBuffers(EGLDisplay dpy, EGLSurface surface, EGLNativ
return EGL_FALSE;
}
- if (display->isDeviceLost())
+ if (display->getRenderer()->isDeviceLost())
{
- return error(EGL_CONTEXT_LOST, EGL_FALSE);
+ return egl::error(EGL_CONTEXT_LOST, EGL_FALSE);
}
UNIMPLEMENTED(); // FIXME
- return success(0);
+ return egl::success(0);
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
}
@@ -1110,7 +1114,7 @@ EGLBoolean __stdcall eglPostSubBufferNV(EGLDisplay dpy, EGLSurface surface, EGLi
{
if (x < 0 || y < 0 || width < 0 || height < 0)
{
- return error(EGL_BAD_PARAMETER, EGL_FALSE);
+ return egl::error(EGL_BAD_PARAMETER, EGL_FALSE);
}
egl::Display *display = static_cast<egl::Display*>(dpy);
@@ -1121,24 +1125,24 @@ EGLBoolean __stdcall eglPostSubBufferNV(EGLDisplay dpy, EGLSurface surface, EGLi
return EGL_FALSE;
}
- if (display->isDeviceLost())
+ if (display->getRenderer()->isDeviceLost())
{
- return error(EGL_CONTEXT_LOST, EGL_FALSE);
+ return egl::error(EGL_CONTEXT_LOST, EGL_FALSE);
}
if (surface == EGL_NO_SURFACE)
{
- return error(EGL_BAD_SURFACE, EGL_FALSE);
+ return egl::error(EGL_BAD_SURFACE, EGL_FALSE);
}
if (eglSurface->postSubBuffer(x, y, width, height))
{
- return success(EGL_TRUE);
+ return egl::success(EGL_TRUE);
}
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, EGL_FALSE);
+ return egl::error(EGL_BAD_ALLOC, EGL_FALSE);
}
return EGL_FALSE;
@@ -1163,7 +1167,7 @@ __eglMustCastToProperFunctionPointerType __stdcall eglGetProcAddress(const char
{"", NULL},
};
- for (int ext = 0; ext < sizeof(eglExtensions) / sizeof(Extension); ext++)
+ for (unsigned int ext = 0; ext < ArraySize(eglExtensions); ext++)
{
if (strcmp(procname, eglExtensions[ext].name) == 0)
{
@@ -1175,7 +1179,7 @@ __eglMustCastToProperFunctionPointerType __stdcall eglGetProcAddress(const char
}
catch(std::bad_alloc&)
{
- return error(EGL_BAD_ALLOC, (__eglMustCastToProperFunctionPointerType)NULL);
+ return egl::error(EGL_BAD_ALLOC, (__eglMustCastToProperFunctionPointerType)NULL);
}
}
}
diff --git a/src/3rdparty/angle/src/libEGL/main.cpp b/src/3rdparty/angle/src/libEGL/main.cpp
index dc24c4fb04..7ba77f08d1 100644
--- a/src/3rdparty/angle/src/libEGL/main.cpp
+++ b/src/3rdparty/angle/src/libEGL/main.cpp
@@ -10,6 +10,8 @@
#include "common/debug.h"
+#ifndef QT_OPENGL_ES_2_ANGLE_STATIC
+
static DWORD currentTLS = TLS_OUT_OF_INDEXES;
extern "C" BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, LPVOID reserved)
@@ -86,80 +88,77 @@ extern "C" BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, LPVOID reserved
return TRUE;
}
+static inline egl::Current *current()
+{
+ return (egl::Current*)TlsGetValue(currentTLS);
+}
+
+#else // !QT_OPENGL_ES_2_ANGLE_STATIC
+
+static egl::Current *current()
+{
+ // No precautions for thread safety taken as ANGLE is used single-threaded in Qt.
+ static egl::Current curr = { EGL_SUCCESS, EGL_OPENGL_ES_API, EGL_NO_DISPLAY, EGL_NO_SURFACE, EGL_NO_SURFACE };
+ return &curr;
+}
+
+#endif // QT_OPENGL_ES_2_ANGLE_STATIC
+
namespace egl
{
void setCurrentError(EGLint error)
{
- Current *current = (Current*)TlsGetValue(currentTLS);
-
- current->error = error;
+ current()->error = error;
}
EGLint getCurrentError()
{
- Current *current = (Current*)TlsGetValue(currentTLS);
-
- return current->error;
+ return current()->error;
}
void setCurrentAPI(EGLenum API)
{
- Current *current = (Current*)TlsGetValue(currentTLS);
-
- current->API = API;
+ current()->API = API;
}
EGLenum getCurrentAPI()
{
- Current *current = (Current*)TlsGetValue(currentTLS);
-
- return current->API;
+ return current()->API;
}
void setCurrentDisplay(EGLDisplay dpy)
{
- Current *current = (Current*)TlsGetValue(currentTLS);
-
- current->display = dpy;
+ current()->display = dpy;
}
EGLDisplay getCurrentDisplay()
{
- Current *current = (Current*)TlsGetValue(currentTLS);
-
- return current->display;
+ return current()->display;
}
void setCurrentDrawSurface(EGLSurface surface)
{
- Current *current = (Current*)TlsGetValue(currentTLS);
-
- current->drawSurface = surface;
+ current()->drawSurface = surface;
}
EGLSurface getCurrentDrawSurface()
{
- Current *current = (Current*)TlsGetValue(currentTLS);
-
- return current->drawSurface;
+ return current()->drawSurface;
}
void setCurrentReadSurface(EGLSurface surface)
{
- Current *current = (Current*)TlsGetValue(currentTLS);
-
- current->readSurface = surface;
+ current()->readSurface = surface;
}
EGLSurface getCurrentReadSurface()
{
- Current *current = (Current*)TlsGetValue(currentTLS);
-
- return current->readSurface;
-}
+ return current()->readSurface;
}
void error(EGLint errorCode)
{
egl::setCurrentError(errorCode);
}
+
+}
diff --git a/src/3rdparty/angle/src/libEGL/main.h b/src/3rdparty/angle/src/libEGL/main.h
index d09d9e6bc3..77da8f0f8e 100644
--- a/src/3rdparty/angle/src/libEGL/main.h
+++ b/src/3rdparty/angle/src/libEGL/main.h
@@ -38,7 +38,6 @@ EGLSurface getCurrentDrawSurface();
void setCurrentReadSurface(EGLSurface surface);
EGLSurface getCurrentReadSurface();
-}
void error(EGLint errorCode);
@@ -58,4 +57,6 @@ const T &success(const T &returnValue)
return returnValue;
}
+}
+
#endif // LIBEGL_MAIN_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/BinaryStream.h b/src/3rdparty/angle/src/libGLESv2/BinaryStream.h
index 5f7213b8da..21c2f86ce8 100644
--- a/src/3rdparty/angle/src/libGLESv2/BinaryStream.h
+++ b/src/3rdparty/angle/src/libGLESv2/BinaryStream.h
@@ -9,9 +9,6 @@
#ifndef LIBGLESV2_BINARYSTREAM_H_
#define LIBGLESV2_BINARYSTREAM_H_
-#include <string>
-#include <vector>
-
#include "common/angleutils.h"
namespace gl
diff --git a/src/3rdparty/angle/src/libGLESv2/Buffer.cpp b/src/3rdparty/angle/src/libGLESv2/Buffer.cpp
index dd12e3c077..8d5b4ef2a1 100644
--- a/src/3rdparty/angle/src/libGLESv2/Buffer.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/Buffer.cpp
@@ -1,5 +1,6 @@
+#include "precompiled.h"
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -10,19 +11,20 @@
#include "libGLESv2/Buffer.h"
-#include "libGLESv2/main.h"
-#include "libGLESv2/VertexDataManager.h"
-#include "libGLESv2/IndexDataManager.h"
+#include "libGLESv2/renderer/VertexBuffer.h"
+#include "libGLESv2/renderer/IndexBuffer.h"
+#include "libGLESv2/renderer/BufferStorage.h"
+#include "libGLESv2/renderer/Renderer.h"
namespace gl
{
-Buffer::Buffer(GLuint id) : RefCountObject(id)
+Buffer::Buffer(rx::Renderer *renderer, GLuint id) : RefCountObject(id)
{
- mContents = NULL;
- mSize = 0;
+ mRenderer = renderer;
mUsage = GL_DYNAMIC_DRAW;
+ mBufferStorage = renderer->createBufferStorage();
mStaticVertexBuffer = NULL;
mStaticIndexBuffer = NULL;
mUnmodifiedDataUse = 0;
@@ -30,47 +32,32 @@ Buffer::Buffer(GLuint id) : RefCountObject(id)
Buffer::~Buffer()
{
- delete[] mContents;
+ delete mBufferStorage;
delete mStaticVertexBuffer;
delete mStaticIndexBuffer;
}
void Buffer::bufferData(const void *data, GLsizeiptr size, GLenum usage)
{
- if (size == 0)
- {
- delete[] mContents;
- mContents = NULL;
- }
- else if (size != mSize)
- {
- delete[] mContents;
- mContents = new GLubyte[size];
- memset(mContents, 0, size);
- }
+ mBufferStorage->clear();
+ mBufferStorage->setData(data, size, 0);
- if (data != NULL && size > 0)
- {
- memcpy(mContents, data, size);
- }
-
- mSize = size;
mUsage = usage;
invalidateStaticData();
if (usage == GL_STATIC_DRAW)
{
- mStaticVertexBuffer = new StaticVertexBuffer(getDevice());
- mStaticIndexBuffer = new StaticIndexBuffer(getDevice());
+ mStaticVertexBuffer = new rx::StaticVertexBufferInterface(mRenderer);
+ mStaticIndexBuffer = new rx::StaticIndexBufferInterface(mRenderer);
}
}
void Buffer::bufferSubData(const void *data, GLsizeiptr size, GLintptr offset)
{
- memcpy(mContents + offset, data, size);
-
- if ((mStaticVertexBuffer && mStaticVertexBuffer->size() != 0) || (mStaticIndexBuffer && mStaticIndexBuffer->size() != 0))
+ mBufferStorage->setData(data, size, offset);
+
+ if ((mStaticVertexBuffer && mStaticVertexBuffer->getBufferSize() != 0) || (mStaticIndexBuffer && mStaticIndexBuffer->getBufferSize() != 0))
{
invalidateStaticData();
}
@@ -78,12 +65,27 @@ void Buffer::bufferSubData(const void *data, GLsizeiptr size, GLintptr offset)
mUnmodifiedDataUse = 0;
}
-StaticVertexBuffer *Buffer::getStaticVertexBuffer()
+rx::BufferStorage *Buffer::getStorage() const
+{
+ return mBufferStorage;
+}
+
+unsigned int Buffer::size()
+{
+ return mBufferStorage->getSize();
+}
+
+GLenum Buffer::usage() const
+{
+ return mUsage;
+}
+
+rx::StaticVertexBufferInterface *Buffer::getStaticVertexBuffer()
{
return mStaticVertexBuffer;
}
-StaticIndexBuffer *Buffer::getStaticIndexBuffer()
+rx::StaticIndexBufferInterface *Buffer::getStaticIndexBuffer()
{
return mStaticIndexBuffer;
}
@@ -106,10 +108,10 @@ void Buffer::promoteStaticUsage(int dataSize)
{
mUnmodifiedDataUse += dataSize;
- if (mUnmodifiedDataUse > 3 * mSize)
+ if (mUnmodifiedDataUse > 3 * mBufferStorage->getSize())
{
- mStaticVertexBuffer = new StaticVertexBuffer(getDevice());
- mStaticIndexBuffer = new StaticIndexBuffer(getDevice());
+ mStaticVertexBuffer = new rx::StaticVertexBufferInterface(mRenderer);
+ mStaticIndexBuffer = new rx::StaticIndexBufferInterface(mRenderer);
}
}
}
diff --git a/src/3rdparty/angle/src/libGLESv2/Buffer.h b/src/3rdparty/angle/src/libGLESv2/Buffer.h
index 7019c4e160..4376ada5c0 100644
--- a/src/3rdparty/angle/src/libGLESv2/Buffer.h
+++ b/src/3rdparty/angle/src/libGLESv2/Buffer.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -11,49 +11,51 @@
#ifndef LIBGLESV2_BUFFER_H_
#define LIBGLESV2_BUFFER_H_
-#include <cstddef>
-#include <vector>
-
-#define GL_APICALL
-#include <GLES2/gl2.h>
-
#include "common/angleutils.h"
#include "common/RefCountObject.h"
+namespace rx
+{
+class Renderer;
+class BufferStorage;
+class StaticIndexBufferInterface;
+class StaticVertexBufferInterface;
+};
+
namespace gl
{
-class StaticVertexBuffer;
-class StaticIndexBuffer;
class Buffer : public RefCountObject
{
public:
- explicit Buffer(GLuint id);
+ Buffer(rx::Renderer *renderer, GLuint id);
virtual ~Buffer();
void bufferData(const void *data, GLsizeiptr size, GLenum usage);
void bufferSubData(const void *data, GLsizeiptr size, GLintptr offset);
- void *data() { return mContents; }
- size_t size() const { return mSize; }
- GLenum usage() const { return mUsage; }
+ GLenum usage() const;
+
+ rx::BufferStorage *getStorage() const;
+ unsigned int size();
- StaticVertexBuffer *getStaticVertexBuffer();
- StaticIndexBuffer *getStaticIndexBuffer();
+ rx::StaticVertexBufferInterface *getStaticVertexBuffer();
+ rx::StaticIndexBufferInterface *getStaticIndexBuffer();
void invalidateStaticData();
void promoteStaticUsage(int dataSize);
private:
DISALLOW_COPY_AND_ASSIGN(Buffer);
- GLubyte *mContents;
- GLsizeiptr mSize;
+ rx::Renderer *mRenderer;
GLenum mUsage;
- StaticVertexBuffer *mStaticVertexBuffer;
- StaticIndexBuffer *mStaticIndexBuffer;
- GLsizeiptr mUnmodifiedDataUse;
+ rx::BufferStorage *mBufferStorage;
+
+ rx::StaticVertexBufferInterface *mStaticVertexBuffer;
+ rx::StaticIndexBufferInterface *mStaticIndexBuffer;
+ unsigned int mUnmodifiedDataUse;
};
}
diff --git a/src/3rdparty/angle/src/libGLESv2/Context.cpp b/src/3rdparty/angle/src/libGLESv2/Context.cpp
index 414bfa968d..90ba2539d8 100644
--- a/src/3rdparty/angle/src/libGLESv2/Context.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/Context.cpp
@@ -1,5 +1,6 @@
+#include "precompiled.h"
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -9,38 +10,41 @@
#include "libGLESv2/Context.h"
-#include <algorithm>
-
-#include "libEGL/Display.h"
-
#include "libGLESv2/main.h"
-#include "libGLESv2/mathutil.h"
#include "libGLESv2/utilities.h"
-#include "libGLESv2/Blit.h"
-#include "libGLESv2/ResourceManager.h"
#include "libGLESv2/Buffer.h"
#include "libGLESv2/Fence.h"
#include "libGLESv2/Framebuffer.h"
+#include "libGLESv2/Renderbuffer.h"
#include "libGLESv2/Program.h"
#include "libGLESv2/ProgramBinary.h"
#include "libGLESv2/Query.h"
-#include "libGLESv2/Renderbuffer.h"
-#include "libGLESv2/Shader.h"
#include "libGLESv2/Texture.h"
-#include "libGLESv2/VertexDataManager.h"
-#include "libGLESv2/IndexDataManager.h"
+#include "libGLESv2/ResourceManager.h"
+#include "libGLESv2/renderer/IndexDataManager.h"
+#include "libGLESv2/renderer/RenderTarget.h"
+#include "libGLESv2/renderer/Renderer.h"
+
+#include "libEGL/Surface.h"
#undef near
#undef far
namespace gl
{
-Context::Context(const egl::Config *config, const gl::Context *shareContext, bool notifyResets, bool robustAccess) : mConfig(config)
+static const char* makeStaticString(const std::string& str)
{
- ASSERT(robustAccess == false); // Unimplemented
+ static std::set<std::string> strings;
+ std::set<std::string>::iterator it = strings.find(str);
+ if (it != strings.end())
+ return it->c_str();
+
+ return strings.insert(str).first->c_str();
+}
- mDisplay = NULL;
- mDevice = NULL;
+Context::Context(const gl::Context *shareContext, rx::Renderer *renderer, bool notifyResets, bool robustAccess) : mRenderer(renderer)
+{
+ ASSERT(robustAccess == false); // Unimplemented
mFenceHandleAllocator.setBaseHandle(0);
@@ -49,68 +53,73 @@ Context::Context(const egl::Config *config, const gl::Context *shareContext, boo
mState.depthClearValue = 1.0f;
mState.stencilClearValue = 0;
- mState.cullFace = false;
- mState.cullMode = GL_BACK;
- mState.frontFace = GL_CCW;
- mState.depthTest = false;
- mState.depthFunc = GL_LESS;
- mState.blend = false;
- mState.sourceBlendRGB = GL_ONE;
- mState.sourceBlendAlpha = GL_ONE;
- mState.destBlendRGB = GL_ZERO;
- mState.destBlendAlpha = GL_ZERO;
- mState.blendEquationRGB = GL_FUNC_ADD;
- mState.blendEquationAlpha = GL_FUNC_ADD;
+ mState.rasterizer.cullFace = false;
+ mState.rasterizer.cullMode = GL_BACK;
+ mState.rasterizer.frontFace = GL_CCW;
+ mState.rasterizer.polygonOffsetFill = false;
+ mState.rasterizer.polygonOffsetFactor = 0.0f;
+ mState.rasterizer.polygonOffsetUnits = 0.0f;
+ mState.rasterizer.pointDrawMode = false;
+ mState.scissorTest = false;
+ mState.scissor.x = 0;
+ mState.scissor.y = 0;
+ mState.scissor.width = 0;
+ mState.scissor.height = 0;
+
+ mState.blend.blend = false;
+ mState.blend.sourceBlendRGB = GL_ONE;
+ mState.blend.sourceBlendAlpha = GL_ONE;
+ mState.blend.destBlendRGB = GL_ZERO;
+ mState.blend.destBlendAlpha = GL_ZERO;
+ mState.blend.blendEquationRGB = GL_FUNC_ADD;
+ mState.blend.blendEquationAlpha = GL_FUNC_ADD;
+ mState.blend.sampleAlphaToCoverage = false;
+ mState.blend.dither = true;
+
mState.blendColor.red = 0;
mState.blendColor.green = 0;
mState.blendColor.blue = 0;
mState.blendColor.alpha = 0;
- mState.stencilTest = false;
- mState.stencilFunc = GL_ALWAYS;
+
+ mState.depthStencil.depthTest = false;
+ mState.depthStencil.depthFunc = GL_LESS;
+ mState.depthStencil.depthMask = true;
+ mState.depthStencil.stencilTest = false;
+ mState.depthStencil.stencilFunc = GL_ALWAYS;
+ mState.depthStencil.stencilMask = -1;
+ mState.depthStencil.stencilWritemask = -1;
+ mState.depthStencil.stencilBackFunc = GL_ALWAYS;
+ mState.depthStencil.stencilBackMask = - 1;
+ mState.depthStencil.stencilBackWritemask = -1;
+ mState.depthStencil.stencilFail = GL_KEEP;
+ mState.depthStencil.stencilPassDepthFail = GL_KEEP;
+ mState.depthStencil.stencilPassDepthPass = GL_KEEP;
+ mState.depthStencil.stencilBackFail = GL_KEEP;
+ mState.depthStencil.stencilBackPassDepthFail = GL_KEEP;
+ mState.depthStencil.stencilBackPassDepthPass = GL_KEEP;
+
mState.stencilRef = 0;
- mState.stencilMask = -1;
- mState.stencilWritemask = -1;
- mState.stencilBackFunc = GL_ALWAYS;
mState.stencilBackRef = 0;
- mState.stencilBackMask = - 1;
- mState.stencilBackWritemask = -1;
- mState.stencilFail = GL_KEEP;
- mState.stencilPassDepthFail = GL_KEEP;
- mState.stencilPassDepthPass = GL_KEEP;
- mState.stencilBackFail = GL_KEEP;
- mState.stencilBackPassDepthFail = GL_KEEP;
- mState.stencilBackPassDepthPass = GL_KEEP;
- mState.polygonOffsetFill = false;
- mState.polygonOffsetFactor = 0.0f;
- mState.polygonOffsetUnits = 0.0f;
- mState.sampleAlphaToCoverage = false;
+
mState.sampleCoverage = false;
mState.sampleCoverageValue = 1.0f;
mState.sampleCoverageInvert = false;
- mState.scissorTest = false;
- mState.dither = true;
mState.generateMipmapHint = GL_DONT_CARE;
mState.fragmentShaderDerivativeHint = GL_DONT_CARE;
mState.lineWidth = 1.0f;
- mState.viewportX = 0;
- mState.viewportY = 0;
- mState.viewportWidth = config->mDisplayMode.Width;
- mState.viewportHeight = config->mDisplayMode.Height;
+ mState.viewport.x = 0;
+ mState.viewport.y = 0;
+ mState.viewport.width = 0;
+ mState.viewport.height = 0;
mState.zNear = 0.0f;
mState.zFar = 1.0f;
- mState.scissorX = 0;
- mState.scissorY = 0;
- mState.scissorWidth = config->mDisplayMode.Width;
- mState.scissorHeight = config->mDisplayMode.Height;
-
- mState.colorMaskRed = true;
- mState.colorMaskGreen = true;
- mState.colorMaskBlue = true;
- mState.colorMaskAlpha = true;
- mState.depthMask = true;
+ mState.blend.colorMaskRed = true;
+ mState.blend.colorMaskGreen = true;
+ mState.blend.colorMaskBlue = true;
+ mState.blend.colorMaskAlpha = true;
if (shareContext != NULL)
{
@@ -119,7 +128,7 @@ Context::Context(const egl::Config *config, const gl::Context *shareContext, boo
}
else
{
- mResourceManager = new ResourceManager();
+ mResourceManager = new ResourceManager(mRenderer);
}
// [OpenGL ES 2.0.24] section 3.7 page 83:
@@ -128,8 +137,8 @@ Context::Context(const egl::Config *config, const gl::Context *shareContext, boo
// In order that access to these initial textures not be lost, they are treated as texture
// objects all of whose names are 0.
- mTexture2DZero.set(new Texture2D(0));
- mTextureCubeMapZero.set(new TextureCubeMap(0));
+ mTexture2DZero.set(new Texture2D(mRenderer, 0));
+ mTextureCubeMapZero.set(new TextureCubeMap(mRenderer, 0));
mState.activeSampler = 0;
bindArrayBuffer(0);
@@ -147,10 +156,8 @@ Context::Context(const egl::Config *config, const gl::Context *shareContext, boo
mState.unpackAlignment = 4;
mState.packReverseRowOrder = false;
- mVertexDataManager = NULL;
- mIndexDataManager = NULL;
- mBlit = NULL;
- mLineLoopIB = NULL;
+ mExtensionString = NULL;
+ mRendererString = NULL;
mInvalidEnum = false;
mInvalidValue = false;
@@ -164,15 +171,13 @@ Context::Context(const egl::Config *config, const gl::Context *shareContext, boo
mResetStrategy = (notifyResets ? GL_LOSE_CONTEXT_ON_RESET_EXT : GL_NO_RESET_NOTIFICATION_EXT);
mRobustAccess = robustAccess;
+ mSupportsBGRATextures = false;
mSupportsDXT1Textures = false;
mSupportsDXT3Textures = false;
mSupportsDXT5Textures = false;
mSupportsEventQueries = false;
mSupportsOcclusionQueries = false;
mNumCompressedTextureFormats = 0;
- mMaxSupportedSamples = 0;
- mMaskedClearSavedState = NULL;
- markAllStateDirty();
}
Context::~Context()
@@ -203,15 +208,9 @@ Context::~Context()
deleteQuery(mQueryMap.begin()->first);
}
- while (!mMultiSampleSupport.empty())
- {
- delete [] mMultiSampleSupport.begin()->second;
- mMultiSampleSupport.erase(mMultiSampleSupport.begin());
- }
-
for (int type = 0; type < TEXTURE_TYPE_COUNT; type++)
{
- for (int sampler = 0; sampler < MAX_COMBINED_TEXTURE_IMAGE_UNITS_VTF; sampler++)
+ for (int sampler = 0; sampler < IMPLEMENTATION_MAX_COMBINED_TEXTURE_IMAGE_UNITS; sampler++)
{
mState.samplerTexture[type][sampler].set(NULL);
}
@@ -239,86 +238,42 @@ Context::~Context()
mTexture2DZero.set(NULL);
mTextureCubeMapZero.set(NULL);
- delete mVertexDataManager;
- delete mIndexDataManager;
- delete mBlit;
- delete mLineLoopIB;
-
- if (mMaskedClearSavedState)
- {
- mMaskedClearSavedState->Release();
- }
-
mResourceManager->release();
}
-void Context::makeCurrent(egl::Display *display, egl::Surface *surface)
+void Context::makeCurrent(egl::Surface *surface)
{
- mDisplay = display;
- mDevice = mDisplay->getDevice();
-
if (!mHasBeenCurrent)
{
- mDeviceCaps = mDisplay->getDeviceCaps();
-
- mVertexDataManager = new VertexDataManager(this, mDevice);
- mIndexDataManager = new IndexDataManager(this, mDevice);
- mBlit = new Blit(this);
+ mMajorShaderModel = mRenderer->getMajorShaderModel();
+ mMaximumPointSize = mRenderer->getMaxPointSize();
+ mSupportsVertexTexture = mRenderer->getVertexTextureSupport();
+ mSupportsNonPower2Texture = mRenderer->getNonPower2TextureSupport();
+ mSupportsInstancing = mRenderer->getInstancingSupport();
- mSupportsShaderModel3 = mDeviceCaps.PixelShaderVersion >= D3DPS_VERSION(3, 0);
- mMaximumPointSize = mDeviceCaps.MaxPointSize;
- mSupportsVertexTexture = mDisplay->getVertexTextureSupport();
- mSupportsNonPower2Texture = mDisplay->getNonPower2TextureSupport();
- mSupportsInstancing = mDisplay->getInstancingSupport();
-
- mMaxTextureDimension = std::min(std::min((int)mDeviceCaps.MaxTextureWidth, (int)mDeviceCaps.MaxTextureHeight),
+ mMaxViewportDimension = mRenderer->getMaxViewportDimension();
+ mMaxTextureDimension = std::min(std::min(mRenderer->getMaxTextureWidth(), mRenderer->getMaxTextureHeight()),
(int)gl::IMPLEMENTATION_MAX_TEXTURE_SIZE);
mMaxCubeTextureDimension = std::min(mMaxTextureDimension, (int)gl::IMPLEMENTATION_MAX_CUBE_MAP_TEXTURE_SIZE);
mMaxRenderbufferDimension = mMaxTextureDimension;
mMaxTextureLevel = log2(mMaxTextureDimension) + 1;
- mMaxTextureAnisotropy = mDisplay->getTextureFilterAnisotropySupport();
+ mMaxTextureAnisotropy = mRenderer->getTextureMaxAnisotropy();
TRACE("MaxTextureDimension=%d, MaxCubeTextureDimension=%d, MaxRenderbufferDimension=%d, MaxTextureLevel=%d, MaxTextureAnisotropy=%f",
mMaxTextureDimension, mMaxCubeTextureDimension, mMaxRenderbufferDimension, mMaxTextureLevel, mMaxTextureAnisotropy);
- const D3DFORMAT renderBufferFormats[] =
- {
- D3DFMT_A8R8G8B8,
- D3DFMT_X8R8G8B8,
- D3DFMT_R5G6B5,
- D3DFMT_D24S8
- };
-
- int max = 0;
- for (int i = 0; i < sizeof(renderBufferFormats) / sizeof(D3DFORMAT); ++i)
- {
- bool *multisampleArray = new bool[D3DMULTISAMPLE_16_SAMPLES + 1];
- mDisplay->getMultiSampleSupport(renderBufferFormats[i], multisampleArray);
- mMultiSampleSupport[renderBufferFormats[i]] = multisampleArray;
-
- for (int j = D3DMULTISAMPLE_16_SAMPLES; j >= 0; --j)
- {
- if (multisampleArray[j] && j != D3DMULTISAMPLE_NONMASKABLE && j > max)
- {
- max = j;
- }
- }
- }
-
- mMaxSupportedSamples = max;
-
- mSupportsEventQueries = mDisplay->getEventQuerySupport();
- mSupportsOcclusionQueries = mDisplay->getOcclusionQuerySupport();
- mSupportsDXT1Textures = mDisplay->getDXT1TextureSupport();
- mSupportsDXT3Textures = mDisplay->getDXT3TextureSupport();
- mSupportsDXT5Textures = mDisplay->getDXT5TextureSupport();
- mSupportsFloat32Textures = mDisplay->getFloat32TextureSupport(&mSupportsFloat32LinearFilter, &mSupportsFloat32RenderableTextures);
- mSupportsFloat16Textures = mDisplay->getFloat16TextureSupport(&mSupportsFloat16LinearFilter, &mSupportsFloat16RenderableTextures);
- mSupportsLuminanceTextures = mDisplay->getLuminanceTextureSupport();
- mSupportsLuminanceAlphaTextures = mDisplay->getLuminanceAlphaTextureSupport();
- mSupportsDepthTextures = mDisplay->getDepthTextureSupport();
- mSupportsTextureFilterAnisotropy = mMaxTextureAnisotropy >= 2.0f;
-
- mSupports32bitIndices = mDeviceCaps.MaxVertexIndex >= (1 << 16);
+ mSupportsEventQueries = mRenderer->getEventQuerySupport();
+ mSupportsOcclusionQueries = mRenderer->getOcclusionQuerySupport();
+ mSupportsBGRATextures = mRenderer->getBGRATextureSupport();
+ mSupportsDXT1Textures = mRenderer->getDXT1TextureSupport();
+ mSupportsDXT3Textures = mRenderer->getDXT3TextureSupport();
+ mSupportsDXT5Textures = mRenderer->getDXT5TextureSupport();
+ mSupportsFloat32Textures = mRenderer->getFloat32TextureSupport(&mSupportsFloat32LinearFilter, &mSupportsFloat32RenderableTextures);
+ mSupportsFloat16Textures = mRenderer->getFloat16TextureSupport(&mSupportsFloat16LinearFilter, &mSupportsFloat16RenderableTextures);
+ mSupportsLuminanceTextures = mRenderer->getLuminanceTextureSupport();
+ mSupportsLuminanceAlphaTextures = mRenderer->getLuminanceAlphaTextureSupport();
+ mSupportsDepthTextures = mRenderer->getDepthTextureSupport();
+ mSupportsTextureFilterAnisotropy = mRenderer->getTextureFilterAnisotropySupport();
+ mSupports32bitIndices = mRenderer->get32BitIndexSupport();
mNumCompressedTextureFormats = 0;
if (supportsDXT1Textures())
@@ -337,89 +292,30 @@ void Context::makeCurrent(egl::Display *display, egl::Surface *surface)
initExtensionString();
initRendererString();
- mState.viewportX = 0;
- mState.viewportY = 0;
- mState.viewportWidth = surface->getWidth();
- mState.viewportHeight = surface->getHeight();
+ mState.viewport.x = 0;
+ mState.viewport.y = 0;
+ mState.viewport.width = surface->getWidth();
+ mState.viewport.height = surface->getHeight();
- mState.scissorX = 0;
- mState.scissorY = 0;
- mState.scissorWidth = surface->getWidth();
- mState.scissorHeight = surface->getHeight();
+ mState.scissor.x = 0;
+ mState.scissor.y = 0;
+ mState.scissor.width = surface->getWidth();
+ mState.scissor.height = surface->getHeight();
mHasBeenCurrent = true;
}
- // Wrap the existing Direct3D 9 resources into GL objects and assign them to the '0' names
- IDirect3DSurface9 *defaultRenderTarget = surface->getRenderTarget();
- IDirect3DSurface9 *depthStencil = surface->getDepthStencil();
+ // Wrap the existing swapchain resources into GL objects and assign them to the '0' names
+ rx::SwapChain *swapchain = surface->getSwapChain();
- Colorbuffer *colorbufferZero = new Colorbuffer(defaultRenderTarget);
- DepthStencilbuffer *depthStencilbufferZero = new DepthStencilbuffer(depthStencil);
- Framebuffer *framebufferZero = new DefaultFramebuffer(colorbufferZero, depthStencilbufferZero);
+ Colorbuffer *colorbufferZero = new Colorbuffer(mRenderer, swapchain);
+ DepthStencilbuffer *depthStencilbufferZero = new DepthStencilbuffer(mRenderer, swapchain);
+ Framebuffer *framebufferZero = new DefaultFramebuffer(mRenderer, colorbufferZero, depthStencilbufferZero);
setFramebufferZero(framebufferZero);
-
- if (defaultRenderTarget)
- {
- defaultRenderTarget->Release();
- }
-
- if (depthStencil)
- {
- depthStencil->Release();
- }
-
- // Reset pixel shader to null to work around a bug that only happens with Intel GPUs.
- // http://crbug.com/110343
- mDevice->SetPixelShader(NULL);
-
- markAllStateDirty();
-}
-
-// This function will set all of the state-related dirty flags, so that all state is set during next pre-draw.
-void Context::markAllStateDirty()
-{
- for (int t = 0; t < MAX_TEXTURE_IMAGE_UNITS; t++)
- {
- mAppliedTextureSerialPS[t] = 0;
- }
-
- for (int t = 0; t < MAX_VERTEX_TEXTURE_IMAGE_UNITS_VTF; t++)
- {
- mAppliedTextureSerialVS[t] = 0;
- }
-
- mAppliedProgramBinarySerial = 0;
- mAppliedRenderTargetSerial = 0;
- mAppliedDepthbufferSerial = 0;
- mAppliedStencilbufferSerial = 0;
- mAppliedIBSerial = 0;
- mDepthStencilInitialized = false;
- mViewportInitialized = false;
- mRenderTargetDescInitialized = false;
-
- mVertexDeclarationCache.markStateDirty();
-
- mClearStateDirty = true;
- mCullStateDirty = true;
- mDepthStateDirty = true;
- mMaskStateDirty = true;
- mBlendStateDirty = true;
- mStencilStateDirty = true;
- mPolygonOffsetStateDirty = true;
- mScissorStateDirty = true;
- mSampleStateDirty = true;
- mDitherStateDirty = true;
- mFrontFaceDirty = true;
- mDxUniformsDirty = true;
-}
-
-void Context::markDxUniformsDirty()
-{
- mDxUniformsDirty = true;
}
+// NOTE: this function should not assume that this context is current!
void Context::markContextLost()
{
if (mResetStrategy == GL_LOSE_CONTEXT_ON_RESET_EXT)
@@ -452,57 +348,37 @@ void Context::setClearStencil(int stencil)
void Context::setCullFace(bool enabled)
{
- if (mState.cullFace != enabled)
- {
- mState.cullFace = enabled;
- mCullStateDirty = true;
- }
+ mState.rasterizer.cullFace = enabled;
}
bool Context::isCullFaceEnabled() const
{
- return mState.cullFace;
+ return mState.rasterizer.cullFace;
}
void Context::setCullMode(GLenum mode)
{
- if (mState.cullMode != mode)
- {
- mState.cullMode = mode;
- mCullStateDirty = true;
- }
+ mState.rasterizer.cullMode = mode;
}
void Context::setFrontFace(GLenum front)
{
- if (mState.frontFace != front)
- {
- mState.frontFace = front;
- mFrontFaceDirty = true;
- }
+ mState.rasterizer.frontFace = front;
}
void Context::setDepthTest(bool enabled)
{
- if (mState.depthTest != enabled)
- {
- mState.depthTest = enabled;
- mDepthStateDirty = true;
- }
+ mState.depthStencil.depthTest = enabled;
}
bool Context::isDepthTestEnabled() const
{
- return mState.depthTest;
+ return mState.depthStencil.depthTest;
}
void Context::setDepthFunc(GLenum depthFunc)
{
- if (mState.depthFunc != depthFunc)
- {
- mState.depthFunc = depthFunc;
- mDepthStateDirty = true;
- }
+ mState.depthStencil.depthFunc = depthFunc;
}
void Context::setDepthRange(float zNear, float zFar)
@@ -513,190 +389,114 @@ void Context::setDepthRange(float zNear, float zFar)
void Context::setBlend(bool enabled)
{
- if (mState.blend != enabled)
- {
- mState.blend = enabled;
- mBlendStateDirty = true;
- }
+ mState.blend.blend = enabled;
}
bool Context::isBlendEnabled() const
{
- return mState.blend;
+ return mState.blend.blend;
}
void Context::setBlendFactors(GLenum sourceRGB, GLenum destRGB, GLenum sourceAlpha, GLenum destAlpha)
{
- if (mState.sourceBlendRGB != sourceRGB ||
- mState.sourceBlendAlpha != sourceAlpha ||
- mState.destBlendRGB != destRGB ||
- mState.destBlendAlpha != destAlpha)
- {
- mState.sourceBlendRGB = sourceRGB;
- mState.destBlendRGB = destRGB;
- mState.sourceBlendAlpha = sourceAlpha;
- mState.destBlendAlpha = destAlpha;
- mBlendStateDirty = true;
- }
+ mState.blend.sourceBlendRGB = sourceRGB;
+ mState.blend.destBlendRGB = destRGB;
+ mState.blend.sourceBlendAlpha = sourceAlpha;
+ mState.blend.destBlendAlpha = destAlpha;
}
void Context::setBlendColor(float red, float green, float blue, float alpha)
{
- if (mState.blendColor.red != red ||
- mState.blendColor.green != green ||
- mState.blendColor.blue != blue ||
- mState.blendColor.alpha != alpha)
- {
- mState.blendColor.red = red;
- mState.blendColor.green = green;
- mState.blendColor.blue = blue;
- mState.blendColor.alpha = alpha;
- mBlendStateDirty = true;
- }
+ mState.blendColor.red = red;
+ mState.blendColor.green = green;
+ mState.blendColor.blue = blue;
+ mState.blendColor.alpha = alpha;
}
void Context::setBlendEquation(GLenum rgbEquation, GLenum alphaEquation)
{
- if (mState.blendEquationRGB != rgbEquation ||
- mState.blendEquationAlpha != alphaEquation)
- {
- mState.blendEquationRGB = rgbEquation;
- mState.blendEquationAlpha = alphaEquation;
- mBlendStateDirty = true;
- }
+ mState.blend.blendEquationRGB = rgbEquation;
+ mState.blend.blendEquationAlpha = alphaEquation;
}
void Context::setStencilTest(bool enabled)
{
- if (mState.stencilTest != enabled)
- {
- mState.stencilTest = enabled;
- mStencilStateDirty = true;
- }
+ mState.depthStencil.stencilTest = enabled;
}
bool Context::isStencilTestEnabled() const
{
- return mState.stencilTest;
+ return mState.depthStencil.stencilTest;
}
void Context::setStencilParams(GLenum stencilFunc, GLint stencilRef, GLuint stencilMask)
{
- if (mState.stencilFunc != stencilFunc ||
- mState.stencilRef != stencilRef ||
- mState.stencilMask != stencilMask)
- {
- mState.stencilFunc = stencilFunc;
- mState.stencilRef = (stencilRef > 0) ? stencilRef : 0;
- mState.stencilMask = stencilMask;
- mStencilStateDirty = true;
- }
+ mState.depthStencil.stencilFunc = stencilFunc;
+ mState.stencilRef = (stencilRef > 0) ? stencilRef : 0;
+ mState.depthStencil.stencilMask = stencilMask;
}
void Context::setStencilBackParams(GLenum stencilBackFunc, GLint stencilBackRef, GLuint stencilBackMask)
{
- if (mState.stencilBackFunc != stencilBackFunc ||
- mState.stencilBackRef != stencilBackRef ||
- mState.stencilBackMask != stencilBackMask)
- {
- mState.stencilBackFunc = stencilBackFunc;
- mState.stencilBackRef = (stencilBackRef > 0) ? stencilBackRef : 0;
- mState.stencilBackMask = stencilBackMask;
- mStencilStateDirty = true;
- }
+ mState.depthStencil.stencilBackFunc = stencilBackFunc;
+ mState.stencilBackRef = (stencilBackRef > 0) ? stencilBackRef : 0;
+ mState.depthStencil.stencilBackMask = stencilBackMask;
}
void Context::setStencilWritemask(GLuint stencilWritemask)
{
- if (mState.stencilWritemask != stencilWritemask)
- {
- mState.stencilWritemask = stencilWritemask;
- mStencilStateDirty = true;
- }
+ mState.depthStencil.stencilWritemask = stencilWritemask;
}
void Context::setStencilBackWritemask(GLuint stencilBackWritemask)
{
- if (mState.stencilBackWritemask != stencilBackWritemask)
- {
- mState.stencilBackWritemask = stencilBackWritemask;
- mStencilStateDirty = true;
- }
+ mState.depthStencil.stencilBackWritemask = stencilBackWritemask;
}
void Context::setStencilOperations(GLenum stencilFail, GLenum stencilPassDepthFail, GLenum stencilPassDepthPass)
{
- if (mState.stencilFail != stencilFail ||
- mState.stencilPassDepthFail != stencilPassDepthFail ||
- mState.stencilPassDepthPass != stencilPassDepthPass)
- {
- mState.stencilFail = stencilFail;
- mState.stencilPassDepthFail = stencilPassDepthFail;
- mState.stencilPassDepthPass = stencilPassDepthPass;
- mStencilStateDirty = true;
- }
+ mState.depthStencil.stencilFail = stencilFail;
+ mState.depthStencil.stencilPassDepthFail = stencilPassDepthFail;
+ mState.depthStencil.stencilPassDepthPass = stencilPassDepthPass;
}
void Context::setStencilBackOperations(GLenum stencilBackFail, GLenum stencilBackPassDepthFail, GLenum stencilBackPassDepthPass)
{
- if (mState.stencilBackFail != stencilBackFail ||
- mState.stencilBackPassDepthFail != stencilBackPassDepthFail ||
- mState.stencilBackPassDepthPass != stencilBackPassDepthPass)
- {
- mState.stencilBackFail = stencilBackFail;
- mState.stencilBackPassDepthFail = stencilBackPassDepthFail;
- mState.stencilBackPassDepthPass = stencilBackPassDepthPass;
- mStencilStateDirty = true;
- }
+ mState.depthStencil.stencilBackFail = stencilBackFail;
+ mState.depthStencil.stencilBackPassDepthFail = stencilBackPassDepthFail;
+ mState.depthStencil.stencilBackPassDepthPass = stencilBackPassDepthPass;
}
void Context::setPolygonOffsetFill(bool enabled)
{
- if (mState.polygonOffsetFill != enabled)
- {
- mState.polygonOffsetFill = enabled;
- mPolygonOffsetStateDirty = true;
- }
+ mState.rasterizer.polygonOffsetFill = enabled;
}
bool Context::isPolygonOffsetFillEnabled() const
{
- return mState.polygonOffsetFill;
-
+ return mState.rasterizer.polygonOffsetFill;
}
void Context::setPolygonOffsetParams(GLfloat factor, GLfloat units)
{
- if (mState.polygonOffsetFactor != factor ||
- mState.polygonOffsetUnits != units)
- {
- mState.polygonOffsetFactor = factor;
- mState.polygonOffsetUnits = units;
- mPolygonOffsetStateDirty = true;
- }
+ // An application can pass NaN values here, so handle this gracefully
+ mState.rasterizer.polygonOffsetFactor = factor != factor ? 0.0f : factor;
+ mState.rasterizer.polygonOffsetUnits = units != units ? 0.0f : units;
}
void Context::setSampleAlphaToCoverage(bool enabled)
{
- if (mState.sampleAlphaToCoverage != enabled)
- {
- mState.sampleAlphaToCoverage = enabled;
- mSampleStateDirty = true;
- }
+ mState.blend.sampleAlphaToCoverage = enabled;
}
bool Context::isSampleAlphaToCoverageEnabled() const
{
- return mState.sampleAlphaToCoverage;
+ return mState.blend.sampleAlphaToCoverage;
}
void Context::setSampleCoverage(bool enabled)
{
- if (mState.sampleCoverage != enabled)
- {
- mState.sampleCoverage = enabled;
- mSampleStateDirty = true;
- }
+ mState.sampleCoverage = enabled;
}
bool Context::isSampleCoverageEnabled() const
@@ -706,22 +506,13 @@ bool Context::isSampleCoverageEnabled() const
void Context::setSampleCoverageParams(GLclampf value, bool invert)
{
- if (mState.sampleCoverageValue != value ||
- mState.sampleCoverageInvert != invert)
- {
- mState.sampleCoverageValue = value;
- mState.sampleCoverageInvert = invert;
- mSampleStateDirty = true;
- }
+ mState.sampleCoverageValue = value;
+ mState.sampleCoverageInvert = invert;
}
void Context::setScissorTest(bool enabled)
{
- if (mState.scissorTest != enabled)
- {
- mState.scissorTest = enabled;
- mScissorStateDirty = true;
- }
+ mState.scissorTest = enabled;
}
bool Context::isScissorTestEnabled() const
@@ -731,16 +522,12 @@ bool Context::isScissorTestEnabled() const
void Context::setDither(bool enabled)
{
- if (mState.dither != enabled)
- {
- mState.dither = enabled;
- mDitherStateDirty = true;
- }
+ mState.blend.dither = enabled;
}
bool Context::isDitherEnabled() const
{
- return mState.dither;
+ return mState.blend.dither;
}
void Context::setLineWidth(GLfloat width)
@@ -763,45 +550,31 @@ void Context::setFragmentShaderDerivativeHint(GLenum hint)
void Context::setViewportParams(GLint x, GLint y, GLsizei width, GLsizei height)
{
- mState.viewportX = x;
- mState.viewportY = y;
- mState.viewportWidth = width;
- mState.viewportHeight = height;
+ mState.viewport.x = x;
+ mState.viewport.y = y;
+ mState.viewport.width = width;
+ mState.viewport.height = height;
}
void Context::setScissorParams(GLint x, GLint y, GLsizei width, GLsizei height)
{
- if (mState.scissorX != x || mState.scissorY != y ||
- mState.scissorWidth != width || mState.scissorHeight != height)
- {
- mState.scissorX = x;
- mState.scissorY = y;
- mState.scissorWidth = width;
- mState.scissorHeight = height;
- mScissorStateDirty = true;
- }
+ mState.scissor.x = x;
+ mState.scissor.y = y;
+ mState.scissor.width = width;
+ mState.scissor.height = height;
}
void Context::setColorMask(bool red, bool green, bool blue, bool alpha)
{
- if (mState.colorMaskRed != red || mState.colorMaskGreen != green ||
- mState.colorMaskBlue != blue || mState.colorMaskAlpha != alpha)
- {
- mState.colorMaskRed = red;
- mState.colorMaskGreen = green;
- mState.colorMaskBlue = blue;
- mState.colorMaskAlpha = alpha;
- mMaskStateDirty = true;
- }
+ mState.blend.colorMaskRed = red;
+ mState.blend.colorMaskGreen = green;
+ mState.blend.colorMaskBlue = blue;
+ mState.blend.colorMaskAlpha = alpha;
}
void Context::setDepthMask(bool mask)
{
- if (mState.depthMask != mask)
- {
- mState.depthMask = mask;
- mMaskStateDirty = true;
- }
+ mState.depthStencil.depthMask = mask;
}
void Context::setActiveSampler(unsigned int active)
@@ -881,11 +654,6 @@ const void *Context::getVertexAttribPointer(unsigned int attribNum) const
return mState.vertexAttribute[attribNum].mPointer;
}
-const VertexAttributeArray &Context::getVertexAttributes()
-{
- return mState.vertexAttribute;
-}
-
void Context::setPackAlignment(GLint alignment)
{
mState.packAlignment = alignment;
@@ -955,7 +723,7 @@ GLuint Context::createFence()
{
GLuint handle = mFenceHandleAllocator.allocate();
- mFenceMap[handle] = new Fence(mDisplay);
+ mFenceMap[handle] = new Fence(mRenderer);
return handle;
}
@@ -1117,7 +885,7 @@ void Context::bindReadFramebuffer(GLuint framebuffer)
{
if (!getFramebuffer(framebuffer))
{
- mFramebufferMap[framebuffer] = new Framebuffer();
+ mFramebufferMap[framebuffer] = new Framebuffer(mRenderer);
}
mState.readFramebuffer = framebuffer;
@@ -1127,7 +895,7 @@ void Context::bindDrawFramebuffer(GLuint framebuffer)
{
if (!getFramebuffer(framebuffer))
{
- mFramebufferMap[framebuffer] = new Framebuffer();
+ mFramebufferMap[framebuffer] = new Framebuffer(mRenderer);
}
mState.drawFramebuffer = framebuffer;
@@ -1152,7 +920,6 @@ void Context::useProgram(GLuint program)
Program *newProgram = mResourceManager->getProgram(program);
Program *oldProgram = mResourceManager->getProgram(priorProgram);
mCurrentProgramBinary.set(NULL);
- mDxUniformsDirty = true;
if (newProgram)
{
@@ -1178,7 +945,6 @@ void Context::linkProgram(GLuint program)
if (linked && program == mState.currentProgram)
{
mCurrentProgramBinary.set(programObject->getProgramBinary());
- mDxUniformsDirty = true;
}
}
@@ -1193,7 +959,6 @@ void Context::setProgramBinary(GLuint program, const void *binary, GLint length)
if (loaded && program == mState.currentProgram)
{
mCurrentProgramBinary.set(programObject->getProgramBinary());
- mDxUniformsDirty = true;
}
}
@@ -1219,7 +984,7 @@ void Context::beginQuery(GLenum target, GLuint query)
{
if (mState.activeQuery[i].get() != NULL)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
@@ -1242,13 +1007,13 @@ void Context::beginQuery(GLenum target, GLuint query)
// check that name was obtained with glGenQueries
if (!queryObject)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
// check for type mismatch
if (queryObject->getType() != target)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
// set query as active for specified target
@@ -1279,7 +1044,7 @@ void Context::endQuery(GLenum target)
if (queryObject == NULL)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
queryObject->end();
@@ -1297,8 +1062,31 @@ void Context::setFramebufferZero(Framebuffer *buffer)
}
}
-void Context::setRenderbufferStorage(RenderbufferStorage *renderbuffer)
+void Context::setRenderbufferStorage(GLsizei width, GLsizei height, GLenum internalformat, GLsizei samples)
{
+ RenderbufferStorage *renderbuffer = NULL;
+ switch (internalformat)
+ {
+ case GL_DEPTH_COMPONENT16:
+ renderbuffer = new gl::Depthbuffer(mRenderer, width, height, samples);
+ break;
+ case GL_RGBA4:
+ case GL_RGB5_A1:
+ case GL_RGB565:
+ case GL_RGB8_OES:
+ case GL_RGBA8_OES:
+ renderbuffer = new gl::Colorbuffer(mRenderer,width, height, internalformat, samples);
+ break;
+ case GL_STENCIL_INDEX8:
+ renderbuffer = new gl::Stencilbuffer(mRenderer, width, height, samples);
+ break;
+ case GL_DEPTH24_STENCIL8_OES:
+ renderbuffer = new gl::DepthStencilbuffer(mRenderer, width, height, samples);
+ break;
+ default:
+ UNREACHABLE(); return;
+ }
+
Renderbuffer *renderbufferObject = mState.renderbuffer.get();
renderbufferObject->setStorage(renderbuffer);
}
@@ -1343,7 +1131,7 @@ Query *Context::getQuery(unsigned int handle, bool create, GLenum type)
{
if (!query->second && create)
{
- query->second = new Query(handle, type);
+ query->second = new Query(mRenderer, type, handle);
query->second->addRef();
}
return query->second;
@@ -1396,25 +1184,25 @@ bool Context::getBooleanv(GLenum pname, GLboolean *params)
{
switch (pname)
{
- case GL_SHADER_COMPILER: *params = GL_TRUE; break;
- case GL_SAMPLE_COVERAGE_INVERT: *params = mState.sampleCoverageInvert; break;
- case GL_DEPTH_WRITEMASK: *params = mState.depthMask; break;
+ case GL_SHADER_COMPILER: *params = GL_TRUE; break;
+ case GL_SAMPLE_COVERAGE_INVERT: *params = mState.sampleCoverageInvert; break;
+ case GL_DEPTH_WRITEMASK: *params = mState.depthStencil.depthMask; break;
case GL_COLOR_WRITEMASK:
- params[0] = mState.colorMaskRed;
- params[1] = mState.colorMaskGreen;
- params[2] = mState.colorMaskBlue;
- params[3] = mState.colorMaskAlpha;
+ params[0] = mState.blend.colorMaskRed;
+ params[1] = mState.blend.colorMaskGreen;
+ params[2] = mState.blend.colorMaskBlue;
+ params[3] = mState.blend.colorMaskAlpha;
break;
- case GL_CULL_FACE: *params = mState.cullFace; break;
- case GL_POLYGON_OFFSET_FILL: *params = mState.polygonOffsetFill; break;
- case GL_SAMPLE_ALPHA_TO_COVERAGE: *params = mState.sampleAlphaToCoverage; break;
- case GL_SAMPLE_COVERAGE: *params = mState.sampleCoverage; break;
- case GL_SCISSOR_TEST: *params = mState.scissorTest; break;
- case GL_STENCIL_TEST: *params = mState.stencilTest; break;
- case GL_DEPTH_TEST: *params = mState.depthTest; break;
- case GL_BLEND: *params = mState.blend; break;
- case GL_DITHER: *params = mState.dither; break;
- case GL_CONTEXT_ROBUST_ACCESS_EXT: *params = mRobustAccess ? GL_TRUE : GL_FALSE; break;
+ case GL_CULL_FACE: *params = mState.rasterizer.cullFace; break;
+ case GL_POLYGON_OFFSET_FILL: *params = mState.rasterizer.polygonOffsetFill; break;
+ case GL_SAMPLE_ALPHA_TO_COVERAGE: *params = mState.blend.sampleAlphaToCoverage; break;
+ case GL_SAMPLE_COVERAGE: *params = mState.sampleCoverage; break;
+ case GL_SCISSOR_TEST: *params = mState.scissorTest; break;
+ case GL_STENCIL_TEST: *params = mState.depthStencil.stencilTest; break;
+ case GL_DEPTH_TEST: *params = mState.depthStencil.depthTest; break;
+ case GL_BLEND: *params = mState.blend.blend; break;
+ case GL_DITHER: *params = mState.blend.dither; break;
+ case GL_CONTEXT_ROBUST_ACCESS_EXT: *params = mRobustAccess ? GL_TRUE : GL_FALSE; break;
default:
return false;
}
@@ -1430,11 +1218,11 @@ bool Context::getFloatv(GLenum pname, GLfloat *params)
// case, this should make no difference to the calling application.
switch (pname)
{
- case GL_LINE_WIDTH: *params = mState.lineWidth; break;
- case GL_SAMPLE_COVERAGE_VALUE: *params = mState.sampleCoverageValue; break;
- case GL_DEPTH_CLEAR_VALUE: *params = mState.depthClearValue; break;
- case GL_POLYGON_OFFSET_FACTOR: *params = mState.polygonOffsetFactor; break;
- case GL_POLYGON_OFFSET_UNITS: *params = mState.polygonOffsetUnits; break;
+ case GL_LINE_WIDTH: *params = mState.lineWidth; break;
+ case GL_SAMPLE_COVERAGE_VALUE: *params = mState.sampleCoverageValue; break;
+ case GL_DEPTH_CLEAR_VALUE: *params = mState.depthClearValue; break;
+ case GL_POLYGON_OFFSET_FACTOR: *params = mState.rasterizer.polygonOffsetFactor; break;
+ case GL_POLYGON_OFFSET_UNITS: *params = mState.rasterizer.polygonOffsetUnits; break;
case GL_ALIASED_LINE_WIDTH_RANGE:
params[0] = gl::ALIASED_LINE_WIDTH_RANGE_MIN;
params[1] = gl::ALIASED_LINE_WIDTH_RANGE_MAX;
@@ -1475,6 +1263,22 @@ bool Context::getFloatv(GLenum pname, GLfloat *params)
bool Context::getIntegerv(GLenum pname, GLint *params)
{
+ if (pname >= GL_DRAW_BUFFER0_EXT && pname <= GL_DRAW_BUFFER15_EXT)
+ {
+ unsigned int colorAttachment = (pname - GL_DRAW_BUFFER0_EXT);
+
+ if (colorAttachment >= mRenderer->getMaxRenderTargets())
+ {
+ // return true to stop further operation in the parent call
+ return gl::error(GL_INVALID_OPERATION, true);
+ }
+
+ Framebuffer *framebuffer = getDrawFramebuffer();
+
+ *params = framebuffer->getDrawBufferState(colorAttachment);
+ return true;
+ }
+
// Please note: DEPTH_CLEAR_VALUE is not included in our internal getIntegerv implementation
// because it is stored as a float, despite the fact that the GL ES 2.0 spec names
// GetIntegerv as its native query function. As it would require conversion in any
@@ -1483,13 +1287,15 @@ bool Context::getIntegerv(GLenum pname, GLint *params)
switch (pname)
{
case GL_MAX_VERTEX_ATTRIBS: *params = gl::MAX_VERTEX_ATTRIBS; break;
- case GL_MAX_VERTEX_UNIFORM_VECTORS: *params = gl::MAX_VERTEX_UNIFORM_VECTORS; break;
- case GL_MAX_VARYING_VECTORS: *params = getMaximumVaryingVectors(); break;
- case GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS: *params = getMaximumCombinedTextureImageUnits(); break;
- case GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS: *params = getMaximumVertexTextureImageUnits(); break;
+ case GL_MAX_VERTEX_UNIFORM_VECTORS: *params = mRenderer->getMaxVertexUniformVectors(); break;
+ case GL_MAX_VARYING_VECTORS: *params = mRenderer->getMaxVaryingVectors(); break;
+ case GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS: *params = mRenderer->getMaxCombinedTextureImageUnits(); break;
+ case GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS: *params = mRenderer->getMaxVertexTextureImageUnits(); break;
case GL_MAX_TEXTURE_IMAGE_UNITS: *params = gl::MAX_TEXTURE_IMAGE_UNITS; break;
- case GL_MAX_FRAGMENT_UNIFORM_VECTORS: *params = getMaximumFragmentUniformVectors(); break;
+ case GL_MAX_FRAGMENT_UNIFORM_VECTORS: *params = mRenderer->getMaxFragmentUniformVectors(); break;
case GL_MAX_RENDERBUFFER_SIZE: *params = getMaximumRenderbufferDimension(); break;
+ case GL_MAX_COLOR_ATTACHMENTS_EXT: *params = mRenderer->getMaxRenderTargets(); break;
+ case GL_MAX_DRAW_BUFFERS_EXT: *params = mRenderer->getMaxRenderTargets(); break;
case GL_NUM_SHADER_BINARY_FORMATS: *params = 0; break;
case GL_SHADER_BINARY_FORMATS: /* no shader binary formats are supported */ break;
case GL_ARRAY_BUFFER_BINDING: *params = mState.arrayBuffer.id(); break;
@@ -1505,27 +1311,27 @@ bool Context::getIntegerv(GLenum pname, GLint *params)
case GL_GENERATE_MIPMAP_HINT: *params = mState.generateMipmapHint; break;
case GL_FRAGMENT_SHADER_DERIVATIVE_HINT_OES: *params = mState.fragmentShaderDerivativeHint; break;
case GL_ACTIVE_TEXTURE: *params = (mState.activeSampler + GL_TEXTURE0); break;
- case GL_STENCIL_FUNC: *params = mState.stencilFunc; break;
- case GL_STENCIL_REF: *params = mState.stencilRef; break;
- case GL_STENCIL_VALUE_MASK: *params = mState.stencilMask; break;
- case GL_STENCIL_BACK_FUNC: *params = mState.stencilBackFunc; break;
- case GL_STENCIL_BACK_REF: *params = mState.stencilBackRef; break;
- case GL_STENCIL_BACK_VALUE_MASK: *params = mState.stencilBackMask; break;
- case GL_STENCIL_FAIL: *params = mState.stencilFail; break;
- case GL_STENCIL_PASS_DEPTH_FAIL: *params = mState.stencilPassDepthFail; break;
- case GL_STENCIL_PASS_DEPTH_PASS: *params = mState.stencilPassDepthPass; break;
- case GL_STENCIL_BACK_FAIL: *params = mState.stencilBackFail; break;
- case GL_STENCIL_BACK_PASS_DEPTH_FAIL: *params = mState.stencilBackPassDepthFail; break;
- case GL_STENCIL_BACK_PASS_DEPTH_PASS: *params = mState.stencilBackPassDepthPass; break;
- case GL_DEPTH_FUNC: *params = mState.depthFunc; break;
- case GL_BLEND_SRC_RGB: *params = mState.sourceBlendRGB; break;
- case GL_BLEND_SRC_ALPHA: *params = mState.sourceBlendAlpha; break;
- case GL_BLEND_DST_RGB: *params = mState.destBlendRGB; break;
- case GL_BLEND_DST_ALPHA: *params = mState.destBlendAlpha; break;
- case GL_BLEND_EQUATION_RGB: *params = mState.blendEquationRGB; break;
- case GL_BLEND_EQUATION_ALPHA: *params = mState.blendEquationAlpha; break;
- case GL_STENCIL_WRITEMASK: *params = mState.stencilWritemask; break;
- case GL_STENCIL_BACK_WRITEMASK: *params = mState.stencilBackWritemask; break;
+ case GL_STENCIL_FUNC: *params = mState.depthStencil.stencilFunc; break;
+ case GL_STENCIL_REF: *params = mState.stencilRef; break;
+ case GL_STENCIL_VALUE_MASK: *params = mState.depthStencil.stencilMask; break;
+ case GL_STENCIL_BACK_FUNC: *params = mState.depthStencil.stencilBackFunc; break;
+ case GL_STENCIL_BACK_REF: *params = mState.stencilBackRef; break;
+ case GL_STENCIL_BACK_VALUE_MASK: *params = mState.depthStencil.stencilBackMask; break;
+ case GL_STENCIL_FAIL: *params = mState.depthStencil.stencilFail; break;
+ case GL_STENCIL_PASS_DEPTH_FAIL: *params = mState.depthStencil.stencilPassDepthFail; break;
+ case GL_STENCIL_PASS_DEPTH_PASS: *params = mState.depthStencil.stencilPassDepthPass; break;
+ case GL_STENCIL_BACK_FAIL: *params = mState.depthStencil.stencilBackFail; break;
+ case GL_STENCIL_BACK_PASS_DEPTH_FAIL: *params = mState.depthStencil.stencilBackPassDepthFail; break;
+ case GL_STENCIL_BACK_PASS_DEPTH_PASS: *params = mState.depthStencil.stencilBackPassDepthPass; break;
+ case GL_DEPTH_FUNC: *params = mState.depthStencil.depthFunc; break;
+ case GL_BLEND_SRC_RGB: *params = mState.blend.sourceBlendRGB; break;
+ case GL_BLEND_SRC_ALPHA: *params = mState.blend.sourceBlendAlpha; break;
+ case GL_BLEND_DST_RGB: *params = mState.blend.destBlendRGB; break;
+ case GL_BLEND_DST_ALPHA: *params = mState.blend.destBlendAlpha; break;
+ case GL_BLEND_EQUATION_RGB: *params = mState.blend.blendEquationRGB; break;
+ case GL_BLEND_EQUATION_ALPHA: *params = mState.blend.blendEquationAlpha; break;
+ case GL_STENCIL_WRITEMASK: *params = mState.depthStencil.stencilWritemask; break;
+ case GL_STENCIL_BACK_WRITEMASK: *params = mState.depthStencil.stencilBackWritemask; break;
case GL_STENCIL_CLEAR_VALUE: *params = mState.stencilClearValue; break;
case GL_SUBPIXEL_BITS: *params = 4; break;
case GL_MAX_TEXTURE_SIZE: *params = getMaximumTextureDimension(); break;
@@ -1591,9 +1397,8 @@ bool Context::getIntegerv(GLenum pname, GLint *params)
break;
case GL_MAX_VIEWPORT_DIMS:
{
- int maxDimension = std::max(getMaximumRenderbufferDimension(), getMaximumTextureDimension());
- params[0] = maxDimension;
- params[1] = maxDimension;
+ params[0] = mMaxViewportDimension;
+ params[1] = mMaxViewportDimension;
}
break;
case GL_COMPRESSED_TEXTURE_FORMATS:
@@ -1614,35 +1419,35 @@ bool Context::getIntegerv(GLenum pname, GLint *params)
}
break;
case GL_VIEWPORT:
- params[0] = mState.viewportX;
- params[1] = mState.viewportY;
- params[2] = mState.viewportWidth;
- params[3] = mState.viewportHeight;
+ params[0] = mState.viewport.x;
+ params[1] = mState.viewport.y;
+ params[2] = mState.viewport.width;
+ params[3] = mState.viewport.height;
break;
case GL_SCISSOR_BOX:
- params[0] = mState.scissorX;
- params[1] = mState.scissorY;
- params[2] = mState.scissorWidth;
- params[3] = mState.scissorHeight;
+ params[0] = mState.scissor.x;
+ params[1] = mState.scissor.y;
+ params[2] = mState.scissor.width;
+ params[3] = mState.scissor.height;
break;
- case GL_CULL_FACE_MODE: *params = mState.cullMode; break;
- case GL_FRONT_FACE: *params = mState.frontFace; break;
+ case GL_CULL_FACE_MODE: *params = mState.rasterizer.cullMode; break;
+ case GL_FRONT_FACE: *params = mState.rasterizer.frontFace; break;
case GL_RED_BITS:
case GL_GREEN_BITS:
case GL_BLUE_BITS:
case GL_ALPHA_BITS:
{
gl::Framebuffer *framebuffer = getDrawFramebuffer();
- gl::Renderbuffer *colorbuffer = framebuffer->getColorbuffer();
+ gl::Renderbuffer *colorbuffer = framebuffer->getFirstColorbuffer();
if (colorbuffer)
{
switch (pname)
{
- case GL_RED_BITS: *params = colorbuffer->getRedSize(); break;
- case GL_GREEN_BITS: *params = colorbuffer->getGreenSize(); break;
- case GL_BLUE_BITS: *params = colorbuffer->getBlueSize(); break;
- case GL_ALPHA_BITS: *params = colorbuffer->getAlphaSize(); break;
+ case GL_RED_BITS: *params = colorbuffer->getRedSize(); break;
+ case GL_GREEN_BITS: *params = colorbuffer->getGreenSize(); break;
+ case GL_BLUE_BITS: *params = colorbuffer->getBlueSize(); break;
+ case GL_ALPHA_BITS: *params = colorbuffer->getAlphaSize(); break;
}
}
else
@@ -1683,9 +1488,9 @@ bool Context::getIntegerv(GLenum pname, GLint *params)
break;
case GL_TEXTURE_BINDING_2D:
{
- if (mState.activeSampler < 0 || mState.activeSampler > getMaximumCombinedTextureImageUnits() - 1)
+ if (mState.activeSampler > mRenderer->getMaxCombinedTextureImageUnits() - 1)
{
- error(GL_INVALID_OPERATION);
+ gl::error(GL_INVALID_OPERATION);
return false;
}
@@ -1694,9 +1499,9 @@ bool Context::getIntegerv(GLenum pname, GLint *params)
break;
case GL_TEXTURE_BINDING_CUBE_MAP:
{
- if (mState.activeSampler < 0 || mState.activeSampler > getMaximumCombinedTextureImageUnits() - 1)
+ if (mState.activeSampler > mRenderer->getMaxCombinedTextureImageUnits() - 1)
{
- error(GL_INVALID_OPERATION);
+ gl::error(GL_INVALID_OPERATION);
return false;
}
@@ -1721,6 +1526,13 @@ bool Context::getIntegerv(GLenum pname, GLint *params)
bool Context::getQueryParameterInfo(GLenum pname, GLenum *type, unsigned int *numParams)
{
+ if (pname >= GL_DRAW_BUFFER0_EXT && pname <= GL_DRAW_BUFFER15_EXT)
+ {
+ *type = GL_INT;
+ *numParams = 1;
+ return true;
+ }
+
// Please note: the query type returned for DEPTH_CLEAR_VALUE in this implementation
// is FLOAT rather than INT, as would be suggested by the GL ES 2.0 spec. This is due
// to the fact that it is stored internally as a float, and so would require conversion
@@ -1750,6 +1562,8 @@ bool Context::getQueryParameterInfo(GLenum pname, GLenum *type, unsigned int *nu
case GL_MAX_TEXTURE_IMAGE_UNITS:
case GL_MAX_FRAGMENT_UNIFORM_VECTORS:
case GL_MAX_RENDERBUFFER_SIZE:
+ case GL_MAX_COLOR_ATTACHMENTS_EXT:
+ case GL_MAX_DRAW_BUFFERS_EXT:
case GL_NUM_SHADER_BINARY_FORMATS:
case GL_NUM_COMPRESSED_TEXTURE_FORMATS:
case GL_ARRAY_BUFFER_BINDING:
@@ -1901,186 +1715,25 @@ bool Context::getQueryParameterInfo(GLenum pname, GLenum *type, unsigned int *nu
}
// Applies the render target surface, depth stencil surface, viewport rectangle and
-// scissor rectangle to the Direct3D 9 device
-bool Context::applyRenderTarget(bool ignoreViewport)
+// scissor rectangle to the renderer
+bool Context::applyRenderTarget(GLenum drawMode, bool ignoreViewport)
{
Framebuffer *framebufferObject = getDrawFramebuffer();
if (!framebufferObject || framebufferObject->completeness() != GL_FRAMEBUFFER_COMPLETE)
{
- return error(GL_INVALID_FRAMEBUFFER_OPERATION, false);
+ return gl::error(GL_INVALID_FRAMEBUFFER_OPERATION, false);
}
- // if there is no color attachment we must synthesize a NULL colorattachment
- // to keep the D3D runtime happy. This should only be possible if depth texturing.
- Renderbuffer *renderbufferObject = NULL;
- if (framebufferObject->getColorbufferType() != GL_NONE)
- {
- renderbufferObject = framebufferObject->getColorbuffer();
- }
- else
- {
- renderbufferObject = framebufferObject->getNullColorbuffer();
- }
- if (!renderbufferObject)
- {
- ERR("unable to locate renderbuffer for FBO.");
- return false;
- }
-
- bool renderTargetChanged = false;
- unsigned int renderTargetSerial = renderbufferObject->getSerial();
- if (renderTargetSerial != mAppliedRenderTargetSerial)
- {
- IDirect3DSurface9 *renderTarget = renderbufferObject->getRenderTarget();
- if (!renderTarget)
- {
- ERR("render target pointer unexpectedly null.");
- return false; // Context must be lost
- }
- mDevice->SetRenderTarget(0, renderTarget);
- mAppliedRenderTargetSerial = renderTargetSerial;
- mScissorStateDirty = true; // Scissor area must be clamped to render target's size-- this is different for different render targets.
- renderTargetChanged = true;
- renderTarget->Release();
- }
-
- IDirect3DSurface9 *depthStencil = NULL;
- unsigned int depthbufferSerial = 0;
- unsigned int stencilbufferSerial = 0;
- if (framebufferObject->getDepthbufferType() != GL_NONE)
- {
- Renderbuffer *depthbuffer = framebufferObject->getDepthbuffer();
- depthStencil = depthbuffer->getDepthStencil();
- if (!depthStencil)
- {
- ERR("Depth stencil pointer unexpectedly null.");
- return false;
- }
-
- depthbufferSerial = depthbuffer->getSerial();
- }
- else if (framebufferObject->getStencilbufferType() != GL_NONE)
- {
- Renderbuffer *stencilbuffer = framebufferObject->getStencilbuffer();
- depthStencil = stencilbuffer->getDepthStencil();
- if (!depthStencil)
- {
- ERR("Depth stencil pointer unexpectedly null.");
- return false;
- }
-
- stencilbufferSerial = stencilbuffer->getSerial();
- }
-
- if (depthbufferSerial != mAppliedDepthbufferSerial ||
- stencilbufferSerial != mAppliedStencilbufferSerial ||
- !mDepthStencilInitialized)
- {
- mDevice->SetDepthStencilSurface(depthStencil);
- mAppliedDepthbufferSerial = depthbufferSerial;
- mAppliedStencilbufferSerial = stencilbufferSerial;
- mDepthStencilInitialized = true;
- }
-
- if (depthStencil)
- {
- depthStencil->Release();
- }
-
- if (!mRenderTargetDescInitialized || renderTargetChanged)
- {
- IDirect3DSurface9 *renderTarget = renderbufferObject->getRenderTarget();
- if (!renderTarget)
- {
- return false; // Context must be lost
- }
- renderTarget->GetDesc(&mRenderTargetDesc);
- mRenderTargetDescInitialized = true;
- renderTarget->Release();
- }
-
- D3DVIEWPORT9 viewport;
-
- float zNear = clamp01(mState.zNear);
- float zFar = clamp01(mState.zFar);
-
- if (ignoreViewport)
- {
- viewport.X = 0;
- viewport.Y = 0;
- viewport.Width = mRenderTargetDesc.Width;
- viewport.Height = mRenderTargetDesc.Height;
- viewport.MinZ = 0.0f;
- viewport.MaxZ = 1.0f;
- }
- else
- {
- viewport.X = clamp(mState.viewportX, 0L, static_cast<LONG>(mRenderTargetDesc.Width));
- viewport.Y = clamp(mState.viewportY, 0L, static_cast<LONG>(mRenderTargetDesc.Height));
- viewport.Width = clamp(mState.viewportWidth, 0L, static_cast<LONG>(mRenderTargetDesc.Width) - static_cast<LONG>(viewport.X));
- viewport.Height = clamp(mState.viewportHeight, 0L, static_cast<LONG>(mRenderTargetDesc.Height) - static_cast<LONG>(viewport.Y));
- viewport.MinZ = zNear;
- viewport.MaxZ = zFar;
- }
-
- if (viewport.Width <= 0 || viewport.Height <= 0)
- {
- return false; // Nothing to render
- }
+ mRenderer->applyRenderTarget(framebufferObject);
- if (renderTargetChanged || !mViewportInitialized || memcmp(&viewport, &mSetViewport, sizeof mSetViewport) != 0)
+ if (!mRenderer->setViewport(mState.viewport, mState.zNear, mState.zFar, drawMode, mState.rasterizer.frontFace,
+ ignoreViewport))
{
- mDevice->SetViewport(&viewport);
- mSetViewport = viewport;
- mViewportInitialized = true;
- mDxUniformsDirty = true;
- }
-
- if (mScissorStateDirty)
- {
- if (mState.scissorTest)
- {
- RECT rect;
- rect.left = clamp(mState.scissorX, 0L, static_cast<LONG>(mRenderTargetDesc.Width));
- rect.top = clamp(mState.scissorY, 0L, static_cast<LONG>(mRenderTargetDesc.Height));
- rect.right = clamp(mState.scissorX + mState.scissorWidth, 0L, static_cast<LONG>(mRenderTargetDesc.Width));
- rect.bottom = clamp(mState.scissorY + mState.scissorHeight, 0L, static_cast<LONG>(mRenderTargetDesc.Height));
- mDevice->SetScissorRect(&rect);
- mDevice->SetRenderState(D3DRS_SCISSORTESTENABLE, TRUE);
- }
- else
- {
- mDevice->SetRenderState(D3DRS_SCISSORTESTENABLE, FALSE);
- }
-
- mScissorStateDirty = false;
+ return false;
}
- if (mState.currentProgram && mDxUniformsDirty)
- {
- ProgramBinary *programBinary = getCurrentProgramBinary();
-
- GLint halfPixelSize = programBinary->getDxHalfPixelSizeLocation();
- GLfloat xy[2] = {1.0f / viewport.Width, -1.0f / viewport.Height};
- programBinary->setUniform2fv(halfPixelSize, 1, xy);
-
- // These values are used for computing gl_FragCoord in Program::linkVaryings().
- GLint coord = programBinary->getDxCoordLocation();
- GLfloat whxy[4] = {mState.viewportWidth / 2.0f, mState.viewportHeight / 2.0f,
- (float)mState.viewportX + mState.viewportWidth / 2.0f,
- (float)mState.viewportY + mState.viewportHeight / 2.0f};
- programBinary->setUniform4fv(coord, 1, whxy);
-
- GLint depth = programBinary->getDxDepthLocation();
- GLfloat dz[2] = {(zFar - zNear) / 2.0f, (zNear + zFar) / 2.0f};
- programBinary->setUniform2fv(depth, 1, dz);
-
- GLint depthRange = programBinary->getDxDepthRangeLocation();
- GLfloat nearFarDiff[3] = {zNear, zFar, zFar - zNear};
- programBinary->setUniform3fv(depthRange, 1, nearFarDiff);
- mDxUniformsDirty = false;
- }
+ mRenderer->setScissorRectangle(mState.scissor, mState.scissorTest);
return true;
}
@@ -2088,290 +1741,42 @@ bool Context::applyRenderTarget(bool ignoreViewport)
// Applies the fixed-function state (culling, depth test, alpha blending, stenciling, etc) to the Direct3D 9 device
void Context::applyState(GLenum drawMode)
{
- ProgramBinary *programBinary = getCurrentProgramBinary();
-
- Framebuffer *framebufferObject = getDrawFramebuffer();
+ mState.rasterizer.pointDrawMode = (drawMode == GL_POINTS);
+ mRenderer->setRasterizerState(mState.rasterizer);
- GLint frontCCW = programBinary->getDxFrontCCWLocation();
- GLint ccw = (mState.frontFace == GL_CCW);
- programBinary->setUniform1iv(frontCCW, 1, &ccw);
-
- GLint pointsOrLines = programBinary->getDxPointsOrLinesLocation();
- GLint alwaysFront = !isTriangleMode(drawMode);
- programBinary->setUniform1iv(pointsOrLines, 1, &alwaysFront);
-
- D3DADAPTER_IDENTIFIER9 *identifier = mDisplay->getAdapterIdentifier();
- bool zeroColorMaskAllowed = identifier->VendorId != 0x1002;
- // Apparently some ATI cards have a bug where a draw with a zero color
- // write mask can cause later draws to have incorrect results. Instead,
- // set a nonzero color write mask but modify the blend state so that no
- // drawing is done.
- // http://code.google.com/p/angleproject/issues/detail?id=169
-
- if (mCullStateDirty || mFrontFaceDirty)
+ unsigned int mask = 0;
+ if (mState.sampleCoverage)
{
- if (mState.cullFace)
- {
- mDevice->SetRenderState(D3DRS_CULLMODE, es2dx::ConvertCullMode(mState.cullMode, mState.frontFace));
- }
- else
+ if (mState.sampleCoverageValue != 0)
{
- mDevice->SetRenderState(D3DRS_CULLMODE, D3DCULL_NONE);
- }
-
- mCullStateDirty = false;
- }
+ Framebuffer *framebufferObject = getDrawFramebuffer();
+ float threshold = 0.5f;
- if (mDepthStateDirty)
- {
- if (mState.depthTest)
- {
- mDevice->SetRenderState(D3DRS_ZENABLE, D3DZB_TRUE);
- mDevice->SetRenderState(D3DRS_ZFUNC, es2dx::ConvertComparison(mState.depthFunc));
- }
- else
- {
- mDevice->SetRenderState(D3DRS_ZENABLE, D3DZB_FALSE);
- }
-
- mDepthStateDirty = false;
- }
-
- if (!zeroColorMaskAllowed && (mMaskStateDirty || mBlendStateDirty))
- {
- mBlendStateDirty = true;
- mMaskStateDirty = true;
- }
-
- if (mBlendStateDirty)
- {
- if (mState.blend)
- {
- mDevice->SetRenderState(D3DRS_ALPHABLENDENABLE, TRUE);
-
- if (mState.sourceBlendRGB != GL_CONSTANT_ALPHA && mState.sourceBlendRGB != GL_ONE_MINUS_CONSTANT_ALPHA &&
- mState.destBlendRGB != GL_CONSTANT_ALPHA && mState.destBlendRGB != GL_ONE_MINUS_CONSTANT_ALPHA)
+ for (int i = 0; i < framebufferObject->getSamples(); ++i)
{
- mDevice->SetRenderState(D3DRS_BLENDFACTOR, es2dx::ConvertColor(mState.blendColor));
- }
- else
- {
- mDevice->SetRenderState(D3DRS_BLENDFACTOR, D3DCOLOR_RGBA(unorm<8>(mState.blendColor.alpha),
- unorm<8>(mState.blendColor.alpha),
- unorm<8>(mState.blendColor.alpha),
- unorm<8>(mState.blendColor.alpha)));
- }
-
- mDevice->SetRenderState(D3DRS_SRCBLEND, es2dx::ConvertBlendFunc(mState.sourceBlendRGB));
- mDevice->SetRenderState(D3DRS_DESTBLEND, es2dx::ConvertBlendFunc(mState.destBlendRGB));
- mDevice->SetRenderState(D3DRS_BLENDOP, es2dx::ConvertBlendOp(mState.blendEquationRGB));
-
- if (mState.sourceBlendRGB != mState.sourceBlendAlpha ||
- mState.destBlendRGB != mState.destBlendAlpha ||
- mState.blendEquationRGB != mState.blendEquationAlpha)
- {
- mDevice->SetRenderState(D3DRS_SEPARATEALPHABLENDENABLE, TRUE);
+ mask <<= 1;
- mDevice->SetRenderState(D3DRS_SRCBLENDALPHA, es2dx::ConvertBlendFunc(mState.sourceBlendAlpha));
- mDevice->SetRenderState(D3DRS_DESTBLENDALPHA, es2dx::ConvertBlendFunc(mState.destBlendAlpha));
- mDevice->SetRenderState(D3DRS_BLENDOPALPHA, es2dx::ConvertBlendOp(mState.blendEquationAlpha));
- }
- else
- {
- mDevice->SetRenderState(D3DRS_SEPARATEALPHABLENDENABLE, FALSE);
- }
- }
- else
- {
- mDevice->SetRenderState(D3DRS_ALPHABLENDENABLE, FALSE);
- }
-
- mBlendStateDirty = false;
- }
-
- if (mStencilStateDirty || mFrontFaceDirty)
- {
- if (mState.stencilTest && framebufferObject->hasStencil())
- {
- mDevice->SetRenderState(D3DRS_STENCILENABLE, TRUE);
- mDevice->SetRenderState(D3DRS_TWOSIDEDSTENCILMODE, TRUE);
-
- // FIXME: Unsupported by D3D9
- const D3DRENDERSTATETYPE D3DRS_CCW_STENCILREF = D3DRS_STENCILREF;
- const D3DRENDERSTATETYPE D3DRS_CCW_STENCILMASK = D3DRS_STENCILMASK;
- const D3DRENDERSTATETYPE D3DRS_CCW_STENCILWRITEMASK = D3DRS_STENCILWRITEMASK;
- if (mState.stencilWritemask != mState.stencilBackWritemask ||
- mState.stencilRef != mState.stencilBackRef ||
- mState.stencilMask != mState.stencilBackMask)
- {
- ERR("Separate front/back stencil writemasks, reference values, or stencil mask values are invalid under WebGL.");
- return error(GL_INVALID_OPERATION);
- }
-
- // get the maximum size of the stencil ref
- gl::Renderbuffer *stencilbuffer = framebufferObject->getStencilbuffer();
- GLuint maxStencil = (1 << stencilbuffer->getStencilSize()) - 1;
-
- mDevice->SetRenderState(mState.frontFace == GL_CCW ? D3DRS_STENCILWRITEMASK : D3DRS_CCW_STENCILWRITEMASK, mState.stencilWritemask);
- mDevice->SetRenderState(mState.frontFace == GL_CCW ? D3DRS_STENCILFUNC : D3DRS_CCW_STENCILFUNC,
- es2dx::ConvertComparison(mState.stencilFunc));
-
- mDevice->SetRenderState(mState.frontFace == GL_CCW ? D3DRS_STENCILREF : D3DRS_CCW_STENCILREF, (mState.stencilRef < (GLint)maxStencil) ? mState.stencilRef : maxStencil);
- mDevice->SetRenderState(mState.frontFace == GL_CCW ? D3DRS_STENCILMASK : D3DRS_CCW_STENCILMASK, mState.stencilMask);
-
- mDevice->SetRenderState(mState.frontFace == GL_CCW ? D3DRS_STENCILFAIL : D3DRS_CCW_STENCILFAIL,
- es2dx::ConvertStencilOp(mState.stencilFail));
- mDevice->SetRenderState(mState.frontFace == GL_CCW ? D3DRS_STENCILZFAIL : D3DRS_CCW_STENCILZFAIL,
- es2dx::ConvertStencilOp(mState.stencilPassDepthFail));
- mDevice->SetRenderState(mState.frontFace == GL_CCW ? D3DRS_STENCILPASS : D3DRS_CCW_STENCILPASS,
- es2dx::ConvertStencilOp(mState.stencilPassDepthPass));
-
- mDevice->SetRenderState(mState.frontFace == GL_CW ? D3DRS_STENCILWRITEMASK : D3DRS_CCW_STENCILWRITEMASK, mState.stencilBackWritemask);
- mDevice->SetRenderState(mState.frontFace == GL_CW ? D3DRS_STENCILFUNC : D3DRS_CCW_STENCILFUNC,
- es2dx::ConvertComparison(mState.stencilBackFunc));
-
- mDevice->SetRenderState(mState.frontFace == GL_CW ? D3DRS_STENCILREF : D3DRS_CCW_STENCILREF, (mState.stencilBackRef < (GLint)maxStencil) ? mState.stencilBackRef : maxStencil);
- mDevice->SetRenderState(mState.frontFace == GL_CW ? D3DRS_STENCILMASK : D3DRS_CCW_STENCILMASK, mState.stencilBackMask);
-
- mDevice->SetRenderState(mState.frontFace == GL_CW ? D3DRS_STENCILFAIL : D3DRS_CCW_STENCILFAIL,
- es2dx::ConvertStencilOp(mState.stencilBackFail));
- mDevice->SetRenderState(mState.frontFace == GL_CW ? D3DRS_STENCILZFAIL : D3DRS_CCW_STENCILZFAIL,
- es2dx::ConvertStencilOp(mState.stencilBackPassDepthFail));
- mDevice->SetRenderState(mState.frontFace == GL_CW ? D3DRS_STENCILPASS : D3DRS_CCW_STENCILPASS,
- es2dx::ConvertStencilOp(mState.stencilBackPassDepthPass));
- }
- else
- {
- mDevice->SetRenderState(D3DRS_STENCILENABLE, FALSE);
- }
-
- mStencilStateDirty = false;
- mFrontFaceDirty = false;
- }
-
- if (mMaskStateDirty)
- {
- int colorMask = es2dx::ConvertColorMask(mState.colorMaskRed, mState.colorMaskGreen,
- mState.colorMaskBlue, mState.colorMaskAlpha);
- if (colorMask == 0 && !zeroColorMaskAllowed)
- {
- // Enable green channel, but set blending so nothing will be drawn.
- mDevice->SetRenderState(D3DRS_COLORWRITEENABLE, D3DCOLORWRITEENABLE_GREEN);
- mDevice->SetRenderState(D3DRS_ALPHABLENDENABLE, TRUE);
-
- mDevice->SetRenderState(D3DRS_SRCBLEND, D3DBLEND_ZERO);
- mDevice->SetRenderState(D3DRS_DESTBLEND, D3DBLEND_ONE);
- mDevice->SetRenderState(D3DRS_BLENDOP, D3DBLENDOP_ADD);
- }
- else
- {
- mDevice->SetRenderState(D3DRS_COLORWRITEENABLE, colorMask);
- }
- mDevice->SetRenderState(D3DRS_ZWRITEENABLE, mState.depthMask ? TRUE : FALSE);
-
- mMaskStateDirty = false;
- }
-
- if (mPolygonOffsetStateDirty)
- {
- if (mState.polygonOffsetFill)
- {
- gl::Renderbuffer *depthbuffer = framebufferObject->getDepthbuffer();
- if (depthbuffer)
- {
- mDevice->SetRenderState(D3DRS_SLOPESCALEDEPTHBIAS, *((DWORD*)&mState.polygonOffsetFactor));
- float depthBias = ldexp(mState.polygonOffsetUnits, -(int)(depthbuffer->getDepthSize()));
- mDevice->SetRenderState(D3DRS_DEPTHBIAS, *((DWORD*)&depthBias));
- }
- }
- else
- {
- mDevice->SetRenderState(D3DRS_SLOPESCALEDEPTHBIAS, 0);
- mDevice->SetRenderState(D3DRS_DEPTHBIAS, 0);
- }
-
- mPolygonOffsetStateDirty = false;
- }
-
- if (mSampleStateDirty)
- {
- if (mState.sampleAlphaToCoverage)
- {
- FIXME("Sample alpha to coverage is unimplemented.");
- }
-
- mDevice->SetRenderState(D3DRS_MULTISAMPLEANTIALIAS, TRUE);
- if (mState.sampleCoverage)
- {
- unsigned int mask = 0;
- if (mState.sampleCoverageValue != 0)
- {
- float threshold = 0.5f;
-
- for (int i = 0; i < framebufferObject->getSamples(); ++i)
+ if ((i + 1) * mState.sampleCoverageValue >= threshold)
{
- mask <<= 1;
-
- if ((i + 1) * mState.sampleCoverageValue >= threshold)
- {
- threshold += 1.0f;
- mask |= 1;
- }
+ threshold += 1.0f;
+ mask |= 1;
}
}
-
- if (mState.sampleCoverageInvert)
- {
- mask = ~mask;
- }
-
- mDevice->SetRenderState(D3DRS_MULTISAMPLEMASK, mask);
}
- else
+
+ if (mState.sampleCoverageInvert)
{
- mDevice->SetRenderState(D3DRS_MULTISAMPLEMASK, 0xFFFFFFFF);
+ mask = ~mask;
}
-
- mSampleStateDirty = false;
- }
-
- if (mDitherStateDirty)
- {
- mDevice->SetRenderState(D3DRS_DITHERENABLE, mState.dither ? TRUE : FALSE);
-
- mDitherStateDirty = false;
}
-}
-
-GLenum Context::applyVertexBuffer(GLint first, GLsizei count, GLsizei instances, GLsizei *repeatDraw)
-{
- TranslatedAttribute attributes[MAX_VERTEX_ATTRIBS];
-
- GLenum err = mVertexDataManager->prepareVertexData(first, count, attributes, instances);
- if (err != GL_NO_ERROR)
- {
- return err;
- }
-
- ProgramBinary *programBinary = getCurrentProgramBinary();
- return mVertexDeclarationCache.applyDeclaration(mDevice, attributes, programBinary, instances, repeatDraw);
-}
-
-// Applies the indices and element array bindings to the Direct3D 9 device
-GLenum Context::applyIndexBuffer(const GLvoid *indices, GLsizei count, GLenum mode, GLenum type, TranslatedIndexData *indexInfo)
-{
- GLenum err = mIndexDataManager->prepareIndexData(type, count, mState.elementArrayBuffer.get(), indices, indexInfo);
-
- if (err == GL_NO_ERROR)
+ else
{
- if (indexInfo->serial != mAppliedIBSerial)
- {
- mDevice->SetIndices(indexInfo->indexBuffer);
- mAppliedIBSerial = indexInfo->serial;
- }
+ mask = 0xFFFFFFFF;
}
+ mRenderer->setBlendState(mState.blend, mState.blendColor, mask);
- return err;
+ mRenderer->setDepthStencilState(mState.depthStencil, mState.stencilRef, mState.stencilBackRef,
+ mState.rasterizer.frontFace == GL_CCW);
}
// Applies the shaders and shader constants to the Direct3D 9 device
@@ -2379,17 +1784,8 @@ void Context::applyShaders()
{
ProgramBinary *programBinary = getCurrentProgramBinary();
- if (programBinary->getSerial() != mAppliedProgramBinarySerial)
- {
- IDirect3DVertexShader9 *vertexShader = programBinary->getVertexShader();
- IDirect3DPixelShader9 *pixelShader = programBinary->getPixelShader();
-
- mDevice->SetPixelShader(pixelShader);
- mDevice->SetVertexShader(vertexShader);
- programBinary->dirtyAllUniforms();
- mAppliedProgramBinarySerial = programBinary->getSerial();
- }
-
+ mRenderer->applyShaders(programBinary);
+
programBinary->applyUniforms();
}
@@ -2411,84 +1807,43 @@ void Context::applyTextures(SamplerType type)
{
ProgramBinary *programBinary = getCurrentProgramBinary();
- int samplerCount = (type == SAMPLER_PIXEL) ? MAX_TEXTURE_IMAGE_UNITS : MAX_VERTEX_TEXTURE_IMAGE_UNITS_VTF; // Range of Direct3D 9 samplers of given sampler type
- unsigned int *appliedTextureSerial = (type == SAMPLER_PIXEL) ? mAppliedTextureSerialPS : mAppliedTextureSerialVS;
- int d3dSamplerOffset = (type == SAMPLER_PIXEL) ? 0 : D3DVERTEXTEXTURESAMPLER0;
+ // Range of Direct3D samplers of given sampler type
+ int samplerCount = (type == SAMPLER_PIXEL) ? MAX_TEXTURE_IMAGE_UNITS : mRenderer->getMaxVertexTextureImageUnits();
int samplerRange = programBinary->getUsedSamplerRange(type);
for (int samplerIndex = 0; samplerIndex < samplerRange; samplerIndex++)
{
int textureUnit = programBinary->getSamplerMapping(type, samplerIndex); // OpenGL texture image unit index
- int d3dSampler = samplerIndex + d3dSamplerOffset;
if (textureUnit != -1)
{
TextureType textureType = programBinary->getSamplerTextureType(type, samplerIndex);
-
Texture *texture = getSamplerTexture(textureUnit, textureType);
- unsigned int texSerial = texture->getTextureSerial();
- if (appliedTextureSerial[samplerIndex] != texSerial || texture->hasDirtyParameters() || texture->hasDirtyImages())
+ if (texture->isSamplerComplete())
{
- IDirect3DBaseTexture9 *d3dTexture = texture->getTexture();
-
- if (d3dTexture)
- {
- if (appliedTextureSerial[samplerIndex] != texSerial || texture->hasDirtyParameters())
- {
- GLenum wrapS = texture->getWrapS();
- GLenum wrapT = texture->getWrapT();
- GLenum minFilter = texture->getMinFilter();
- GLenum magFilter = texture->getMagFilter();
- float maxAnisotropy = texture->getMaxAnisotropy();
-
- mDevice->SetSamplerState(d3dSampler, D3DSAMP_ADDRESSU, es2dx::ConvertTextureWrap(wrapS));
- mDevice->SetSamplerState(d3dSampler, D3DSAMP_ADDRESSV, es2dx::ConvertTextureWrap(wrapT));
-
- mDevice->SetSamplerState(d3dSampler, D3DSAMP_MAGFILTER, es2dx::ConvertMagFilter(magFilter, maxAnisotropy));
- D3DTEXTUREFILTERTYPE d3dMinFilter, d3dMipFilter;
- es2dx::ConvertMinFilter(minFilter, &d3dMinFilter, &d3dMipFilter, maxAnisotropy);
- mDevice->SetSamplerState(d3dSampler, D3DSAMP_MINFILTER, d3dMinFilter);
- mDevice->SetSamplerState(d3dSampler, D3DSAMP_MIPFILTER, d3dMipFilter);
- mDevice->SetSamplerState(d3dSampler, D3DSAMP_MAXMIPLEVEL, texture->getLodOffset());
-
- if (supportsTextureFilterAnisotropy())
- {
- mDevice->SetSamplerState(d3dSampler, D3DSAMP_MAXANISOTROPY, (DWORD)maxAnisotropy);
- }
- }
+ SamplerState samplerState;
+ texture->getSamplerState(&samplerState);
+ mRenderer->setSamplerState(type, samplerIndex, samplerState);
- if (appliedTextureSerial[samplerIndex] != texSerial || texture->hasDirtyImages())
- {
- mDevice->SetTexture(d3dSampler, d3dTexture);
- }
- }
- else
- {
- mDevice->SetTexture(d3dSampler, getIncompleteTexture(textureType)->getTexture());
- }
+ mRenderer->setTexture(type, samplerIndex, texture);
- appliedTextureSerial[samplerIndex] = texSerial;
texture->resetDirty();
}
+ else
+ {
+ mRenderer->setTexture(type, samplerIndex, getIncompleteTexture(textureType));
+ }
}
else
{
- if (appliedTextureSerial[samplerIndex] != 0)
- {
- mDevice->SetTexture(d3dSampler, NULL);
- appliedTextureSerial[samplerIndex] = 0;
- }
+ mRenderer->setTexture(type, samplerIndex, NULL);
}
}
for (int samplerIndex = samplerRange; samplerIndex < samplerCount; samplerIndex++)
{
- if (appliedTextureSerial[samplerIndex] != 0)
- {
- mDevice->SetTexture(samplerIndex + d3dSamplerOffset, NULL);
- appliedTextureSerial[samplerIndex] = 0;
- }
+ mRenderer->setTexture(type, samplerIndex, NULL);
}
}
@@ -2499,339 +1854,26 @@ void Context::readPixels(GLint x, GLint y, GLsizei width, GLsizei height,
if (framebuffer->completeness() != GL_FRAMEBUFFER_COMPLETE)
{
- return error(GL_INVALID_FRAMEBUFFER_OPERATION);
+ return gl::error(GL_INVALID_FRAMEBUFFER_OPERATION);
}
if (getReadFramebufferHandle() != 0 && framebuffer->getSamples() != 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
- GLsizei outputPitch = ComputePitch(width, ConvertSizedInternalFormat(format, type), mState.packAlignment);
+ GLsizei outputPitch = ComputePitch(width, ConvertSizedInternalFormat(format, type), getPackAlignment());
// sized query sanity check
if (bufSize)
{
int requiredSize = outputPitch * height;
if (requiredSize > *bufSize)
{
- return error(GL_INVALID_OPERATION);
- }
- }
-
- IDirect3DSurface9 *renderTarget = framebuffer->getRenderTarget();
- if (!renderTarget)
- {
- return; // Context must be lost, return silently
- }
-
- D3DSURFACE_DESC desc;
- renderTarget->GetDesc(&desc);
-
- if (desc.MultiSampleType != D3DMULTISAMPLE_NONE)
- {
- UNIMPLEMENTED(); // FIXME: Requires resolve using StretchRect into non-multisampled render target
- renderTarget->Release();
- return error(GL_OUT_OF_MEMORY);
- }
-
- HRESULT result;
- IDirect3DSurface9 *systemSurface = NULL;
- bool directToPixels = !getPackReverseRowOrder() && getPackAlignment() <= 4 && mDisplay->isD3d9ExDevice() &&
- x == 0 && y == 0 && UINT(width) == desc.Width && UINT(height) == desc.Height &&
- desc.Format == D3DFMT_A8R8G8B8 && format == GL_BGRA_EXT && type == GL_UNSIGNED_BYTE;
- if (directToPixels)
- {
- // Use the pixels ptr as a shared handle to write directly into client's memory
- result = mDevice->CreateOffscreenPlainSurface(desc.Width, desc.Height, desc.Format,
- D3DPOOL_SYSTEMMEM, &systemSurface, &pixels);
- if (FAILED(result))
- {
- // Try again without the shared handle
- directToPixels = false;
- }
- }
-
- if (!directToPixels)
- {
- result = mDevice->CreateOffscreenPlainSurface(desc.Width, desc.Height, desc.Format,
- D3DPOOL_SYSTEMMEM, &systemSurface, NULL);
- if (FAILED(result))
- {
- ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
- renderTarget->Release();
- return error(GL_OUT_OF_MEMORY);
- }
- }
-
- result = mDevice->GetRenderTargetData(renderTarget, systemSurface);
- renderTarget->Release();
- renderTarget = NULL;
-
- if (FAILED(result))
- {
- systemSurface->Release();
-
- // It turns out that D3D will sometimes produce more error
- // codes than those documented.
- if (checkDeviceLost(result))
- return error(GL_OUT_OF_MEMORY);
- else
- {
- UNREACHABLE();
- return;
- }
-
- }
-
- if (directToPixels)
- {
- systemSurface->Release();
- return;
- }
-
- RECT rect;
- rect.left = clamp(x, 0L, static_cast<LONG>(desc.Width));
- rect.top = clamp(y, 0L, static_cast<LONG>(desc.Height));
- rect.right = clamp(x + width, 0L, static_cast<LONG>(desc.Width));
- rect.bottom = clamp(y + height, 0L, static_cast<LONG>(desc.Height));
-
- D3DLOCKED_RECT lock;
- result = systemSurface->LockRect(&lock, &rect, D3DLOCK_READONLY);
-
- if (FAILED(result))
- {
- UNREACHABLE();
- systemSurface->Release();
-
- return; // No sensible error to generate
- }
-
- unsigned char *dest = (unsigned char*)pixels;
- unsigned short *dest16 = (unsigned short*)pixels;
-
- unsigned char *source;
- int inputPitch;
- if (getPackReverseRowOrder())
- {
- source = ((unsigned char*)lock.pBits) + lock.Pitch * (rect.bottom - rect.top - 1);
- inputPitch = -lock.Pitch;
- }
- else
- {
- source = (unsigned char*)lock.pBits;
- inputPitch = lock.Pitch;
- }
-
- unsigned int fastPixelSize = 0;
-
- if (desc.Format == D3DFMT_A8R8G8B8 &&
- format == GL_BGRA_EXT &&
- type == GL_UNSIGNED_BYTE)
- {
- fastPixelSize = 4;
- }
- else if ((desc.Format == D3DFMT_A4R4G4B4 &&
- format == GL_BGRA_EXT &&
- type == GL_UNSIGNED_SHORT_4_4_4_4_REV_EXT) ||
- (desc.Format == D3DFMT_A1R5G5B5 &&
- format == GL_BGRA_EXT &&
- type == GL_UNSIGNED_SHORT_1_5_5_5_REV_EXT))
- {
- fastPixelSize = 2;
- }
- else if (desc.Format == D3DFMT_A16B16G16R16F &&
- format == GL_RGBA &&
- type == GL_HALF_FLOAT_OES)
- {
- fastPixelSize = 8;
- }
- else if (desc.Format == D3DFMT_A32B32G32R32F &&
- format == GL_RGBA &&
- type == GL_FLOAT)
- {
- fastPixelSize = 16;
- }
-
- for (int j = 0; j < rect.bottom - rect.top; j++)
- {
- if (fastPixelSize != 0)
- {
- // Fast path for formats which require no translation:
- // D3DFMT_A8R8G8B8 to BGRA/UNSIGNED_BYTE
- // D3DFMT_A4R4G4B4 to BGRA/UNSIGNED_SHORT_4_4_4_4_REV_EXT
- // D3DFMT_A1R5G5B5 to BGRA/UNSIGNED_SHORT_1_5_5_5_REV_EXT
- // D3DFMT_A16B16G16R16F to RGBA/HALF_FLOAT_OES
- // D3DFMT_A32B32G32R32F to RGBA/FLOAT
- //
- // Note that buffers with no alpha go through the slow path below.
- memcpy(dest + j * outputPitch,
- source + j * inputPitch,
- (rect.right - rect.left) * fastPixelSize);
- continue;
- }
-
- for (int i = 0; i < rect.right - rect.left; i++)
- {
- float r;
- float g;
- float b;
- float a;
-
- switch (desc.Format)
- {
- case D3DFMT_R5G6B5:
- {
- unsigned short rgb = *(unsigned short*)(source + 2 * i + j * inputPitch);
-
- a = 1.0f;
- b = (rgb & 0x001F) * (1.0f / 0x001F);
- g = (rgb & 0x07E0) * (1.0f / 0x07E0);
- r = (rgb & 0xF800) * (1.0f / 0xF800);
- }
- break;
- case D3DFMT_A1R5G5B5:
- {
- unsigned short argb = *(unsigned short*)(source + 2 * i + j * inputPitch);
-
- a = (argb & 0x8000) ? 1.0f : 0.0f;
- b = (argb & 0x001F) * (1.0f / 0x001F);
- g = (argb & 0x03E0) * (1.0f / 0x03E0);
- r = (argb & 0x7C00) * (1.0f / 0x7C00);
- }
- break;
- case D3DFMT_A8R8G8B8:
- {
- unsigned int argb = *(unsigned int*)(source + 4 * i + j * inputPitch);
-
- a = (argb & 0xFF000000) * (1.0f / 0xFF000000);
- b = (argb & 0x000000FF) * (1.0f / 0x000000FF);
- g = (argb & 0x0000FF00) * (1.0f / 0x0000FF00);
- r = (argb & 0x00FF0000) * (1.0f / 0x00FF0000);
- }
- break;
- case D3DFMT_X8R8G8B8:
- {
- unsigned int xrgb = *(unsigned int*)(source + 4 * i + j * inputPitch);
-
- a = 1.0f;
- b = (xrgb & 0x000000FF) * (1.0f / 0x000000FF);
- g = (xrgb & 0x0000FF00) * (1.0f / 0x0000FF00);
- r = (xrgb & 0x00FF0000) * (1.0f / 0x00FF0000);
- }
- break;
- case D3DFMT_A2R10G10B10:
- {
- unsigned int argb = *(unsigned int*)(source + 4 * i + j * inputPitch);
-
- a = (argb & 0xC0000000) * (1.0f / 0xC0000000);
- b = (argb & 0x000003FF) * (1.0f / 0x000003FF);
- g = (argb & 0x000FFC00) * (1.0f / 0x000FFC00);
- r = (argb & 0x3FF00000) * (1.0f / 0x3FF00000);
- }
- break;
- case D3DFMT_A32B32G32R32F:
- {
- // float formats in D3D are stored rgba, rather than the other way round
- r = *((float*)(source + 16 * i + j * inputPitch) + 0);
- g = *((float*)(source + 16 * i + j * inputPitch) + 1);
- b = *((float*)(source + 16 * i + j * inputPitch) + 2);
- a = *((float*)(source + 16 * i + j * inputPitch) + 3);
- }
- break;
- case D3DFMT_A16B16G16R16F:
- {
- // float formats in D3D are stored rgba, rather than the other way round
- r = float16ToFloat32(*((unsigned short*)(source + 8 * i + j * inputPitch) + 0));
- g = float16ToFloat32(*((unsigned short*)(source + 8 * i + j * inputPitch) + 1));
- b = float16ToFloat32(*((unsigned short*)(source + 8 * i + j * inputPitch) + 2));
- a = float16ToFloat32(*((unsigned short*)(source + 8 * i + j * inputPitch) + 3));
- }
- break;
- default:
- UNIMPLEMENTED(); // FIXME
- UNREACHABLE();
- return;
- }
-
- switch (format)
- {
- case GL_RGBA:
- switch (type)
- {
- case GL_UNSIGNED_BYTE:
- dest[4 * i + j * outputPitch + 0] = (unsigned char)(255 * r + 0.5f);
- dest[4 * i + j * outputPitch + 1] = (unsigned char)(255 * g + 0.5f);
- dest[4 * i + j * outputPitch + 2] = (unsigned char)(255 * b + 0.5f);
- dest[4 * i + j * outputPitch + 3] = (unsigned char)(255 * a + 0.5f);
- break;
- default: UNREACHABLE();
- }
- break;
- case GL_BGRA_EXT:
- switch (type)
- {
- case GL_UNSIGNED_BYTE:
- dest[4 * i + j * outputPitch + 0] = (unsigned char)(255 * b + 0.5f);
- dest[4 * i + j * outputPitch + 1] = (unsigned char)(255 * g + 0.5f);
- dest[4 * i + j * outputPitch + 2] = (unsigned char)(255 * r + 0.5f);
- dest[4 * i + j * outputPitch + 3] = (unsigned char)(255 * a + 0.5f);
- break;
- case GL_UNSIGNED_SHORT_4_4_4_4_REV_EXT:
- // According to the desktop GL spec in the "Transfer of Pixel Rectangles" section
- // this type is packed as follows:
- // 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
- // --------------------------------------------------------------------------------
- // | 4th | 3rd | 2nd | 1st component |
- // --------------------------------------------------------------------------------
- // in the case of BGRA_EXT, B is the first component, G the second, and so forth.
- dest16[i + j * outputPitch / sizeof(unsigned short)] =
- ((unsigned short)(15 * a + 0.5f) << 12)|
- ((unsigned short)(15 * r + 0.5f) << 8) |
- ((unsigned short)(15 * g + 0.5f) << 4) |
- ((unsigned short)(15 * b + 0.5f) << 0);
- break;
- case GL_UNSIGNED_SHORT_1_5_5_5_REV_EXT:
- // According to the desktop GL spec in the "Transfer of Pixel Rectangles" section
- // this type is packed as follows:
- // 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
- // --------------------------------------------------------------------------------
- // | 4th | 3rd | 2nd | 1st component |
- // --------------------------------------------------------------------------------
- // in the case of BGRA_EXT, B is the first component, G the second, and so forth.
- dest16[i + j * outputPitch / sizeof(unsigned short)] =
- ((unsigned short)( a + 0.5f) << 15) |
- ((unsigned short)(31 * r + 0.5f) << 10) |
- ((unsigned short)(31 * g + 0.5f) << 5) |
- ((unsigned short)(31 * b + 0.5f) << 0);
- break;
- default: UNREACHABLE();
- }
- break;
- case GL_RGB:
- switch (type)
- {
- case GL_UNSIGNED_SHORT_5_6_5:
- dest16[i + j * outputPitch / sizeof(unsigned short)] =
- ((unsigned short)(31 * b + 0.5f) << 0) |
- ((unsigned short)(63 * g + 0.5f) << 5) |
- ((unsigned short)(31 * r + 0.5f) << 11);
- break;
- case GL_UNSIGNED_BYTE:
- dest[3 * i + j * outputPitch + 0] = (unsigned char)(255 * r + 0.5f);
- dest[3 * i + j * outputPitch + 1] = (unsigned char)(255 * g + 0.5f);
- dest[3 * i + j * outputPitch + 2] = (unsigned char)(255 * b + 0.5f);
- break;
- default: UNREACHABLE();
- }
- break;
- default: UNREACHABLE();
- }
+ return gl::error(GL_INVALID_OPERATION);
}
}
- systemSurface->UnlockRect();
-
- systemSurface->Release();
+ mRenderer->readPixels(framebuffer, x, y, width, height, format, type, outputPitch, getPackReverseRowOrder(), getPackAlignment(), pixels);
}
void Context::clear(GLbitfield mask)
@@ -2840,300 +1882,112 @@ void Context::clear(GLbitfield mask)
if (!framebufferObject || framebufferObject->completeness() != GL_FRAMEBUFFER_COMPLETE)
{
- return error(GL_INVALID_FRAMEBUFFER_OPERATION);
+ return gl::error(GL_INVALID_FRAMEBUFFER_OPERATION);
}
DWORD flags = 0;
+ GLbitfield finalMask = 0;
if (mask & GL_COLOR_BUFFER_BIT)
{
mask &= ~GL_COLOR_BUFFER_BIT;
- if (framebufferObject->getColorbufferType() != GL_NONE)
+ if (framebufferObject->hasEnabledColorAttachment())
{
- flags |= D3DCLEAR_TARGET;
+ finalMask |= GL_COLOR_BUFFER_BIT;
}
}
if (mask & GL_DEPTH_BUFFER_BIT)
{
mask &= ~GL_DEPTH_BUFFER_BIT;
- if (mState.depthMask && framebufferObject->getDepthbufferType() != GL_NONE)
+ if (mState.depthStencil.depthMask && framebufferObject->getDepthbufferType() != GL_NONE)
{
- flags |= D3DCLEAR_ZBUFFER;
+ finalMask |= GL_DEPTH_BUFFER_BIT;
}
}
- GLuint stencilUnmasked = 0x0;
-
if (mask & GL_STENCIL_BUFFER_BIT)
{
mask &= ~GL_STENCIL_BUFFER_BIT;
if (framebufferObject->getStencilbufferType() != GL_NONE)
{
- IDirect3DSurface9 *depthStencil = framebufferObject->getStencilbuffer()->getDepthStencil();
+ rx::RenderTarget *depthStencil = framebufferObject->getStencilbuffer()->getDepthStencil();
if (!depthStencil)
{
ERR("Depth stencil pointer unexpectedly null.");
return;
}
-
- D3DSURFACE_DESC desc;
- depthStencil->GetDesc(&desc);
- depthStencil->Release();
-
- unsigned int stencilSize = dx2es::GetStencilSize(desc.Format);
- stencilUnmasked = (0x1 << stencilSize) - 1;
- if (stencilUnmasked != 0x0)
+ if (GetStencilSize(depthStencil->getActualFormat()) > 0)
{
- flags |= D3DCLEAR_STENCIL;
+ finalMask |= GL_STENCIL_BUFFER_BIT;
}
}
}
if (mask != 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
- if (!applyRenderTarget(true)) // Clips the clear to the scissor rectangle but not the viewport
+ if (!applyRenderTarget(GL_TRIANGLES, true)) // Clips the clear to the scissor rectangle but not the viewport
{
return;
}
- D3DCOLOR color = D3DCOLOR_ARGB(unorm<8>(mState.colorClearValue.alpha),
- unorm<8>(mState.colorClearValue.red),
- unorm<8>(mState.colorClearValue.green),
- unorm<8>(mState.colorClearValue.blue));
- float depth = clamp01(mState.depthClearValue);
- int stencil = mState.stencilClearValue & 0x000000FF;
-
- bool alphaUnmasked = (dx2es::GetAlphaSize(mRenderTargetDesc.Format) == 0) || mState.colorMaskAlpha;
-
- const bool needMaskedStencilClear = (flags & D3DCLEAR_STENCIL) &&
- (mState.stencilWritemask & stencilUnmasked) != stencilUnmasked;
- const bool needMaskedColorClear = (flags & D3DCLEAR_TARGET) &&
- !(mState.colorMaskRed && mState.colorMaskGreen &&
- mState.colorMaskBlue && alphaUnmasked);
-
- if (needMaskedColorClear || needMaskedStencilClear)
- {
- // State which is altered in all paths from this point to the clear call is saved.
- // State which is altered in only some paths will be flagged dirty in the case that
- // that path is taken.
- HRESULT hr;
- if (mMaskedClearSavedState == NULL)
- {
- hr = mDevice->BeginStateBlock();
- ASSERT(SUCCEEDED(hr) || hr == D3DERR_OUTOFVIDEOMEMORY || hr == E_OUTOFMEMORY);
-
- mDevice->SetRenderState(D3DRS_ZWRITEENABLE, FALSE);
- mDevice->SetRenderState(D3DRS_ZFUNC, D3DCMP_ALWAYS);
- mDevice->SetRenderState(D3DRS_ZENABLE, FALSE);
- mDevice->SetRenderState(D3DRS_CULLMODE, D3DCULL_NONE);
- mDevice->SetRenderState(D3DRS_FILLMODE, D3DFILL_SOLID);
- mDevice->SetRenderState(D3DRS_ALPHATESTENABLE, FALSE);
- mDevice->SetRenderState(D3DRS_ALPHABLENDENABLE, FALSE);
- mDevice->SetRenderState(D3DRS_CLIPPLANEENABLE, 0);
- mDevice->SetRenderState(D3DRS_COLORWRITEENABLE, 0);
- mDevice->SetRenderState(D3DRS_STENCILENABLE, FALSE);
- mDevice->SetPixelShader(NULL);
- mDevice->SetVertexShader(NULL);
- mDevice->SetFVF(D3DFVF_XYZRHW | D3DFVF_DIFFUSE);
- mDevice->SetStreamSource(0, NULL, 0, 0);
- mDevice->SetRenderState(D3DRS_SEPARATEALPHABLENDENABLE, TRUE);
- mDevice->SetTextureStageState(0, D3DTSS_COLOROP, D3DTOP_SELECTARG1);
- mDevice->SetTextureStageState(0, D3DTSS_COLORARG1, D3DTA_TFACTOR);
- mDevice->SetTextureStageState(0, D3DTSS_ALPHAOP, D3DTOP_SELECTARG1);
- mDevice->SetTextureStageState(0, D3DTSS_ALPHAARG1, D3DTA_TFACTOR);
- mDevice->SetRenderState(D3DRS_TEXTUREFACTOR, color);
- mDevice->SetRenderState(D3DRS_MULTISAMPLEMASK, 0xFFFFFFFF);
-
- for(int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
- {
- mDevice->SetStreamSourceFreq(i, 1);
- }
-
- hr = mDevice->EndStateBlock(&mMaskedClearSavedState);
- ASSERT(SUCCEEDED(hr) || hr == D3DERR_OUTOFVIDEOMEMORY || hr == E_OUTOFMEMORY);
- }
-
- ASSERT(mMaskedClearSavedState != NULL);
-
- if (mMaskedClearSavedState != NULL)
- {
- hr = mMaskedClearSavedState->Capture();
- ASSERT(SUCCEEDED(hr));
- }
-
- mDevice->SetRenderState(D3DRS_ZWRITEENABLE, FALSE);
- mDevice->SetRenderState(D3DRS_ZFUNC, D3DCMP_ALWAYS);
- mDevice->SetRenderState(D3DRS_ZENABLE, FALSE);
- mDevice->SetRenderState(D3DRS_CULLMODE, D3DCULL_NONE);
- mDevice->SetRenderState(D3DRS_FILLMODE, D3DFILL_SOLID);
- mDevice->SetRenderState(D3DRS_ALPHATESTENABLE, FALSE);
- mDevice->SetRenderState(D3DRS_ALPHABLENDENABLE, FALSE);
- mDevice->SetRenderState(D3DRS_CLIPPLANEENABLE, 0);
-
- if (flags & D3DCLEAR_TARGET)
- {
- mDevice->SetRenderState(D3DRS_COLORWRITEENABLE, es2dx::ConvertColorMask(mState.colorMaskRed, mState.colorMaskGreen, mState.colorMaskBlue, mState.colorMaskAlpha));
- }
- else
- {
- mDevice->SetRenderState(D3DRS_COLORWRITEENABLE, 0);
- }
-
- if (stencilUnmasked != 0x0 && (flags & D3DCLEAR_STENCIL))
- {
- mDevice->SetRenderState(D3DRS_STENCILENABLE, TRUE);
- mDevice->SetRenderState(D3DRS_TWOSIDEDSTENCILMODE, FALSE);
- mDevice->SetRenderState(D3DRS_STENCILFUNC, D3DCMP_ALWAYS);
- mDevice->SetRenderState(D3DRS_STENCILREF, stencil);
- mDevice->SetRenderState(D3DRS_STENCILWRITEMASK, mState.stencilWritemask);
- mDevice->SetRenderState(D3DRS_STENCILFAIL, D3DSTENCILOP_REPLACE);
- mDevice->SetRenderState(D3DRS_STENCILZFAIL, D3DSTENCILOP_REPLACE);
- mDevice->SetRenderState(D3DRS_STENCILPASS, D3DSTENCILOP_REPLACE);
- mStencilStateDirty = true;
- }
- else
- {
- mDevice->SetRenderState(D3DRS_STENCILENABLE, FALSE);
- }
-
- mDevice->SetPixelShader(NULL);
- mDevice->SetVertexShader(NULL);
- mDevice->SetFVF(D3DFVF_XYZRHW);
- mDevice->SetRenderState(D3DRS_SEPARATEALPHABLENDENABLE, TRUE);
- mDevice->SetTextureStageState(0, D3DTSS_COLOROP, D3DTOP_SELECTARG1);
- mDevice->SetTextureStageState(0, D3DTSS_COLORARG1, D3DTA_TFACTOR);
- mDevice->SetTextureStageState(0, D3DTSS_ALPHAOP, D3DTOP_SELECTARG1);
- mDevice->SetTextureStageState(0, D3DTSS_ALPHAARG1, D3DTA_TFACTOR);
- mDevice->SetRenderState(D3DRS_TEXTUREFACTOR, color);
- mDevice->SetRenderState(D3DRS_MULTISAMPLEMASK, 0xFFFFFFFF);
-
- for(int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
- {
- mDevice->SetStreamSourceFreq(i, 1);
- }
-
- float quad[4][4]; // A quadrilateral covering the target, aligned to match the edges
- quad[0][0] = -0.5f;
- quad[0][1] = mRenderTargetDesc.Height - 0.5f;
- quad[0][2] = 0.0f;
- quad[0][3] = 1.0f;
-
- quad[1][0] = mRenderTargetDesc.Width - 0.5f;
- quad[1][1] = mRenderTargetDesc.Height - 0.5f;
- quad[1][2] = 0.0f;
- quad[1][3] = 1.0f;
-
- quad[2][0] = -0.5f;
- quad[2][1] = -0.5f;
- quad[2][2] = 0.0f;
- quad[2][3] = 1.0f;
-
- quad[3][0] = mRenderTargetDesc.Width - 0.5f;
- quad[3][1] = -0.5f;
- quad[3][2] = 0.0f;
- quad[3][3] = 1.0f;
-
- mDisplay->startScene();
- mDevice->DrawPrimitiveUP(D3DPT_TRIANGLESTRIP, 2, quad, sizeof(float[4]));
+ ClearParameters clearParams;
+ clearParams.mask = finalMask;
+ clearParams.colorClearValue = mState.colorClearValue;
+ clearParams.colorMaskRed = mState.blend.colorMaskRed;
+ clearParams.colorMaskGreen = mState.blend.colorMaskGreen;
+ clearParams.colorMaskBlue = mState.blend.colorMaskBlue;
+ clearParams.colorMaskAlpha = mState.blend.colorMaskAlpha;
+ clearParams.depthClearValue = mState.depthClearValue;
+ clearParams.stencilClearValue = mState.stencilClearValue;
+ clearParams.stencilWriteMask = mState.depthStencil.stencilWritemask;
- if (flags & D3DCLEAR_ZBUFFER)
- {
- mDevice->SetRenderState(D3DRS_ZENABLE, TRUE);
- mDevice->SetRenderState(D3DRS_ZWRITEENABLE, TRUE);
- mDevice->Clear(0, NULL, D3DCLEAR_ZBUFFER, color, depth, stencil);
- }
-
- if (mMaskedClearSavedState != NULL)
- {
- mMaskedClearSavedState->Apply();
- }
- }
- else if (flags)
- {
- mDevice->Clear(0, NULL, flags, color, depth, stencil);
- }
+ mRenderer->clear(clearParams, framebufferObject);
}
void Context::drawArrays(GLenum mode, GLint first, GLsizei count, GLsizei instances)
{
if (!mState.currentProgram)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
- D3DPRIMITIVETYPE primitiveType;
- int primitiveCount;
-
- if(!es2dx::ConvertPrimitiveType(mode, count, &primitiveType, &primitiveCount))
- return error(GL_INVALID_ENUM);
-
- if (primitiveCount <= 0)
+ if (!mRenderer->applyPrimitiveType(mode, count))
{
return;
}
- if (!applyRenderTarget(false))
+ if (!applyRenderTarget(mode, false))
{
return;
}
applyState(mode);
- GLsizei repeatDraw = 1;
- GLenum err = applyVertexBuffer(first, count, instances, &repeatDraw);
+ ProgramBinary *programBinary = getCurrentProgramBinary();
+
+ GLenum err = mRenderer->applyVertexBuffer(programBinary, mState.vertexAttribute, first, count, instances);
if (err != GL_NO_ERROR)
{
- return error(err);
+ return gl::error(err);
}
applyShaders();
applyTextures();
- if (!getCurrentProgramBinary()->validateSamplers(NULL))
+ if (!programBinary->validateSamplers(NULL))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!skipDraw(mode))
{
- mDisplay->startScene();
-
- if (mode == GL_LINE_LOOP)
- {
- drawLineLoop(count, GL_NONE, NULL, 0);
- }
- else if (instances > 0)
- {
- StaticIndexBuffer *countingIB = mIndexDataManager->getCountingIndices(count);
- if (countingIB)
- {
- if (mAppliedIBSerial != countingIB->getSerial())
- {
- mDevice->SetIndices(countingIB->getBuffer());
- mAppliedIBSerial = countingIB->getSerial();
- }
-
- for (int i = 0; i < repeatDraw; i++)
- {
- mDevice->DrawIndexedPrimitive(primitiveType, 0, 0, count, 0, primitiveCount);
- }
- }
- else
- {
- ERR("Could not create a counting index buffer for glDrawArraysInstanced.");
- return error(GL_OUT_OF_MEMORY);
- }
- }
- else // Regular case
- {
- mDevice->DrawPrimitive(primitiveType, 0, primitiveCount);
- }
+ mRenderer->drawArrays(mode, count, instances);
}
}
@@ -3141,222 +1995,60 @@ void Context::drawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid
{
if (!mState.currentProgram)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!indices && !mState.elementArrayBuffer)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
-
- D3DPRIMITIVETYPE primitiveType;
- int primitiveCount;
-
- if(!es2dx::ConvertPrimitiveType(mode, count, &primitiveType, &primitiveCount))
- return error(GL_INVALID_ENUM);
-
- if (primitiveCount <= 0)
+
+ if (!mRenderer->applyPrimitiveType(mode, count))
{
return;
}
- if (!applyRenderTarget(false))
+ if (!applyRenderTarget(mode, false))
{
return;
}
applyState(mode);
- TranslatedIndexData indexInfo;
- GLenum err = applyIndexBuffer(indices, count, mode, type, &indexInfo);
+ rx::TranslatedIndexData indexInfo;
+ GLenum err = mRenderer->applyIndexBuffer(indices, mState.elementArrayBuffer.get(), count, mode, type, &indexInfo);
if (err != GL_NO_ERROR)
{
- return error(err);
+ return gl::error(err);
}
+ ProgramBinary *programBinary = getCurrentProgramBinary();
+
GLsizei vertexCount = indexInfo.maxIndex - indexInfo.minIndex + 1;
- GLsizei repeatDraw = 1;
- err = applyVertexBuffer(indexInfo.minIndex, vertexCount, instances, &repeatDraw);
+ err = mRenderer->applyVertexBuffer(programBinary, mState.vertexAttribute, indexInfo.minIndex, vertexCount, instances);
if (err != GL_NO_ERROR)
{
- return error(err);
+ return gl::error(err);
}
applyShaders();
applyTextures();
- if (!getCurrentProgramBinary()->validateSamplers(false))
+ if (!programBinary->validateSamplers(NULL))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!skipDraw(mode))
{
- mDisplay->startScene();
-
- if (mode == GL_LINE_LOOP)
- {
- drawLineLoop(count, type, indices, indexInfo.minIndex);
- }
- else
- {
- for (int i = 0; i < repeatDraw; i++)
- {
- mDevice->DrawIndexedPrimitive(primitiveType, -(INT)indexInfo.minIndex, indexInfo.minIndex, vertexCount, indexInfo.startIndex, primitiveCount);
- }
- }
+ mRenderer->drawElements(mode, count, type, indices, mState.elementArrayBuffer.get(), indexInfo, instances);
}
}
// Implements glFlush when block is false, glFinish when block is true
void Context::sync(bool block)
{
- mDisplay->sync(block);
-}
-
-void Context::drawLineLoop(GLsizei count, GLenum type, const GLvoid *indices, int minIndex)
-{
- // Get the raw indices for an indexed draw
- if (type != GL_NONE && mState.elementArrayBuffer.get())
- {
- Buffer *indexBuffer = mState.elementArrayBuffer.get();
- intptr_t offset = reinterpret_cast<intptr_t>(indices);
- indices = static_cast<const GLubyte*>(indexBuffer->data()) + offset;
- }
-
- UINT startIndex = 0;
- bool succeeded = false;
-
- if (supports32bitIndices())
- {
- const int spaceNeeded = (count + 1) * sizeof(unsigned int);
-
- if (!mLineLoopIB)
- {
- mLineLoopIB = new StreamingIndexBuffer(mDevice, INITIAL_INDEX_BUFFER_SIZE, D3DFMT_INDEX32);
- }
-
- if (mLineLoopIB)
- {
- mLineLoopIB->reserveSpace(spaceNeeded, GL_UNSIGNED_INT);
-
- UINT offset = 0;
- unsigned int *data = static_cast<unsigned int*>(mLineLoopIB->map(spaceNeeded, &offset));
- startIndex = offset / 4;
-
- if (data)
- {
- switch (type)
- {
- case GL_NONE: // Non-indexed draw
- for (int i = 0; i < count; i++)
- {
- data[i] = i;
- }
- data[count] = 0;
- break;
- case GL_UNSIGNED_BYTE:
- for (int i = 0; i < count; i++)
- {
- data[i] = static_cast<const GLubyte*>(indices)[i];
- }
- data[count] = static_cast<const GLubyte*>(indices)[0];
- break;
- case GL_UNSIGNED_SHORT:
- for (int i = 0; i < count; i++)
- {
- data[i] = static_cast<const GLushort*>(indices)[i];
- }
- data[count] = static_cast<const GLushort*>(indices)[0];
- break;
- case GL_UNSIGNED_INT:
- for (int i = 0; i < count; i++)
- {
- data[i] = static_cast<const GLuint*>(indices)[i];
- }
- data[count] = static_cast<const GLuint*>(indices)[0];
- break;
- default: UNREACHABLE();
- }
-
- mLineLoopIB->unmap();
- succeeded = true;
- }
- }
- }
- else
- {
- const int spaceNeeded = (count + 1) * sizeof(unsigned short);
-
- if (!mLineLoopIB)
- {
- mLineLoopIB = new StreamingIndexBuffer(mDevice, INITIAL_INDEX_BUFFER_SIZE, D3DFMT_INDEX16);
- }
-
- if (mLineLoopIB)
- {
- mLineLoopIB->reserveSpace(spaceNeeded, GL_UNSIGNED_SHORT);
-
- UINT offset = 0;
- unsigned short *data = static_cast<unsigned short*>(mLineLoopIB->map(spaceNeeded, &offset));
- startIndex = offset / 2;
-
- if (data)
- {
- switch (type)
- {
- case GL_NONE: // Non-indexed draw
- for (int i = 0; i < count; i++)
- {
- data[i] = i;
- }
- data[count] = 0;
- break;
- case GL_UNSIGNED_BYTE:
- for (int i = 0; i < count; i++)
- {
- data[i] = static_cast<const GLubyte*>(indices)[i];
- }
- data[count] = static_cast<const GLubyte*>(indices)[0];
- break;
- case GL_UNSIGNED_SHORT:
- for (int i = 0; i < count; i++)
- {
- data[i] = static_cast<const GLushort*>(indices)[i];
- }
- data[count] = static_cast<const GLushort*>(indices)[0];
- break;
- case GL_UNSIGNED_INT:
- for (int i = 0; i < count; i++)
- {
- data[i] = static_cast<const GLuint*>(indices)[i];
- }
- data[count] = static_cast<const GLuint*>(indices)[0];
- break;
- default: UNREACHABLE();
- }
-
- mLineLoopIB->unmap();
- succeeded = true;
- }
- }
- }
-
- if (succeeded)
- {
- if (mAppliedIBSerial != mLineLoopIB->getSerial())
- {
- mDevice->SetIndices(mLineLoopIB->getBuffer());
- mAppliedIBSerial = mLineLoopIB->getSerial();
- }
-
- mDevice->DrawIndexedPrimitive(D3DPT_LINESTRIP, -minIndex, minIndex, count, startIndex, count);
- }
- else
- {
- ERR("Could not create a looping index buffer for GL_LINE_LOOP.");
- return error(GL_OUT_OF_MEMORY);
- }
+ mRenderer->sync(block);
}
void Context::recordInvalidEnum()
@@ -3428,21 +2120,20 @@ GLenum Context::getError()
GLenum Context::getResetStatus()
{
- if (mResetStatus == GL_NO_ERROR)
+ if (mResetStatus == GL_NO_ERROR && !mContextLost)
{
- bool lost = mDisplay->testDeviceLost();
-
- if (lost)
- {
- mDisplay->notifyDeviceLost(); // Sets mResetStatus
- }
+ // mResetStatus will be set by the markContextLost callback
+ // in the case a notification is sent
+ mRenderer->testDeviceLost(true);
}
GLenum status = mResetStatus;
if (mResetStatus != GL_NO_ERROR)
{
- if (mDisplay->testDeviceResettable())
+ ASSERT(mContextLost);
+
+ if (mRenderer->testDeviceResettable())
{
mResetStatus = GL_NO_ERROR;
}
@@ -3456,63 +2147,29 @@ bool Context::isResetNotificationEnabled()
return (mResetStrategy == GL_LOSE_CONTEXT_ON_RESET_EXT);
}
-bool Context::supportsShaderModel3() const
+int Context::getMajorShaderModel() const
{
- return mSupportsShaderModel3;
+ return mMajorShaderModel;
}
float Context::getMaximumPointSize() const
{
- return mSupportsShaderModel3 ? mMaximumPointSize : ALIASED_POINT_SIZE_RANGE_MAX_SM2;
-}
-
-int Context::getMaximumVaryingVectors() const
-{
- return mSupportsShaderModel3 ? MAX_VARYING_VECTORS_SM3 : MAX_VARYING_VECTORS_SM2;
-}
-
-unsigned int Context::getMaximumVertexTextureImageUnits() const
-{
- return mSupportsVertexTexture ? MAX_VERTEX_TEXTURE_IMAGE_UNITS_VTF : 0;
+ return mMaximumPointSize;
}
unsigned int Context::getMaximumCombinedTextureImageUnits() const
{
- return MAX_TEXTURE_IMAGE_UNITS + getMaximumVertexTextureImageUnits();
-}
-
-int Context::getMaximumFragmentUniformVectors() const
-{
- return mSupportsShaderModel3 ? MAX_FRAGMENT_UNIFORM_VECTORS_SM3 : MAX_FRAGMENT_UNIFORM_VECTORS_SM2;
+ return mRenderer->getMaxCombinedTextureImageUnits();
}
int Context::getMaxSupportedSamples() const
{
- return mMaxSupportedSamples;
+ return mRenderer->getMaxSupportedSamples();
}
-int Context::getNearestSupportedSamples(D3DFORMAT format, int requested) const
+unsigned int Context::getMaximumRenderTargets() const
{
- if (requested == 0)
- {
- return requested;
- }
-
- std::map<D3DFORMAT, bool *>::const_iterator itr = mMultiSampleSupport.find(format);
- if (itr == mMultiSampleSupport.end())
- {
- return -1;
- }
-
- for (int i = requested; i <= D3DMULTISAMPLE_16_SAMPLES; ++i)
- {
- if (itr->second[i] && i != D3DMULTISAMPLE_NONMASKABLE)
- {
- return i;
- }
- }
-
- return -1;
+ return mRenderer->getMaxRenderTargets();
}
bool Context::supportsEventQueries() const
@@ -3525,6 +2182,11 @@ bool Context::supportsOcclusionQueries() const
return mSupportsOcclusionQueries;
}
+bool Context::supportsBGRATextures() const
+{
+ return mSupportsBGRATextures;
+}
+
bool Context::supportsDXT1Textures() const
{
return mSupportsDXT1Textures;
@@ -3635,20 +2297,17 @@ bool Context::getCurrentReadFormatType(GLenum *format, GLenum *type)
Framebuffer *framebuffer = getReadFramebuffer();
if (!framebuffer || framebuffer->completeness() != GL_FRAMEBUFFER_COMPLETE)
{
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
- Renderbuffer *renderbuffer = framebuffer->getColorbuffer();
+ Renderbuffer *renderbuffer = framebuffer->getReadColorbuffer();
if (!renderbuffer)
{
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
- if(!dx2es::ConvertReadBufferFormat(renderbuffer->getD3DFormat(), format, type))
- {
- ASSERT(false);
- return false;
- }
+ *format = gl::ExtractFormat(renderbuffer->getActualFormat());
+ *type = gl::ExtractType(renderbuffer->getActualFormat());
return true;
}
@@ -3686,7 +2345,7 @@ void Context::detachTexture(GLuint texture)
for (int type = 0; type < TEXTURE_TYPE_COUNT; type++)
{
- for (int sampler = 0; sampler < MAX_COMBINED_TEXTURE_IMAGE_UNITS_VTF; sampler++)
+ for (int sampler = 0; sampler < IMPLEMENTATION_MAX_COMBINED_TEXTURE_IMAGE_UNITS; sampler++)
{
if (mState.samplerTexture[type][sampler].id() == texture)
{
@@ -3777,7 +2436,7 @@ Texture *Context::getIncompleteTexture(TextureType type)
case TEXTURE_2D:
{
- Texture2D *incomplete2d = new Texture2D(Texture::INCOMPLETE_TEXTURE_ID);
+ Texture2D *incomplete2d = new Texture2D(mRenderer, Texture::INCOMPLETE_TEXTURE_ID);
incomplete2d->setImage(0, 1, 1, GL_RGBA, GL_UNSIGNED_BYTE, 1, color);
t = incomplete2d;
}
@@ -3785,7 +2444,7 @@ Texture *Context::getIncompleteTexture(TextureType type)
case TEXTURE_CUBE:
{
- TextureCubeMap *incompleteCube = new TextureCubeMap(Texture::INCOMPLETE_TEXTURE_ID);
+ TextureCubeMap *incompleteCube = new TextureCubeMap(mRenderer, Texture::INCOMPLETE_TEXTURE_ID);
incompleteCube->setImagePosX(0, 1, 1, GL_RGBA, GL_UNSIGNED_BYTE, 1, color);
incompleteCube->setImageNegX(0, 1, 1, GL_RGBA, GL_UNSIGNED_BYTE, 1, color);
@@ -3821,9 +2480,9 @@ bool Context::skipDraw(GLenum drawMode)
return true;
}
}
- else if (isTriangleMode(drawMode))
+ else if (IsTriangleMode(drawMode))
{
- if (mState.cullFace && mState.cullMode == GL_FRONT_AND_BACK)
+ if (mState.rasterizer.cullFace && mState.rasterizer.cullMode == GL_FRONT_AND_BACK)
{
return true;
}
@@ -3832,25 +2491,6 @@ bool Context::skipDraw(GLenum drawMode)
return false;
}
-bool Context::isTriangleMode(GLenum drawMode)
-{
- switch (drawMode)
- {
- case GL_TRIANGLES:
- case GL_TRIANGLE_FAN:
- case GL_TRIANGLE_STRIP:
- return true;
- case GL_POINTS:
- case GL_LINES:
- case GL_LINE_LOOP:
- case GL_LINE_STRIP:
- return false;
- default: UNREACHABLE();
- }
-
- return false;
-}
-
void Context::setVertexAttrib(GLuint index, const GLfloat *values)
{
ASSERT(index < gl::MAX_VERTEX_ATTRIBS);
@@ -3859,8 +2499,6 @@ void Context::setVertexAttrib(GLuint index, const GLfloat *values)
mState.vertexAttribute[index].mCurrentValue[1] = values[1];
mState.vertexAttribute[index].mCurrentValue[2] = values[2];
mState.vertexAttribute[index].mCurrentValue[3] = values[3];
-
- mVertexDataManager->dirtyCurrentValue(index);
}
void Context::setVertexAttribDivisor(GLuint index, GLuint divisor)
@@ -3876,124 +2514,139 @@ void Context::setVertexAttribDivisor(GLuint index, GLuint divisor)
// Vendor extensions
void Context::initExtensionString()
{
- mExtensionString = "";
+ std::string extensionString = "";
// OES extensions
if (supports32bitIndices())
{
- mExtensionString += "GL_OES_element_index_uint ";
+ extensionString += "GL_OES_element_index_uint ";
}
- mExtensionString += "GL_OES_packed_depth_stencil ";
- mExtensionString += "GL_OES_get_program_binary ";
- mExtensionString += "GL_OES_rgb8_rgba8 ";
- mExtensionString += "GL_OES_standard_derivatives ";
+ extensionString += "GL_OES_packed_depth_stencil ";
+ extensionString += "GL_OES_get_program_binary ";
+ extensionString += "GL_OES_rgb8_rgba8 ";
+ if (mRenderer->getDerivativeInstructionSupport())
+ {
+ extensionString += "GL_OES_standard_derivatives ";
+ }
if (supportsFloat16Textures())
{
- mExtensionString += "GL_OES_texture_half_float ";
+ extensionString += "GL_OES_texture_half_float ";
}
if (supportsFloat16LinearFilter())
{
- mExtensionString += "GL_OES_texture_half_float_linear ";
+ extensionString += "GL_OES_texture_half_float_linear ";
}
if (supportsFloat32Textures())
{
- mExtensionString += "GL_OES_texture_float ";
+ extensionString += "GL_OES_texture_float ";
}
if (supportsFloat32LinearFilter())
{
- mExtensionString += "GL_OES_texture_float_linear ";
+ extensionString += "GL_OES_texture_float_linear ";
}
if (supportsNonPower2Texture())
{
- mExtensionString += "GL_OES_texture_npot ";
+ extensionString += "GL_OES_texture_npot ";
}
// Multi-vendor (EXT) extensions
if (supportsOcclusionQueries())
{
- mExtensionString += "GL_EXT_occlusion_query_boolean ";
+ extensionString += "GL_EXT_occlusion_query_boolean ";
}
- mExtensionString += "GL_EXT_read_format_bgra ";
- mExtensionString += "GL_EXT_robustness ";
+ extensionString += "GL_EXT_read_format_bgra ";
+ extensionString += "GL_EXT_robustness ";
if (supportsDXT1Textures())
{
- mExtensionString += "GL_EXT_texture_compression_dxt1 ";
+ extensionString += "GL_EXT_texture_compression_dxt1 ";
}
if (supportsTextureFilterAnisotropy())
{
- mExtensionString += "GL_EXT_texture_filter_anisotropic ";
+ extensionString += "GL_EXT_texture_filter_anisotropic ";
+ }
+
+ if (supportsBGRATextures())
+ {
+ extensionString += "GL_EXT_texture_format_BGRA8888 ";
+ }
+
+ if (mRenderer->getMaxRenderTargets() > 1)
+ {
+ extensionString += "GL_EXT_draw_buffers ";
}
- mExtensionString += "GL_EXT_texture_format_BGRA8888 ";
- mExtensionString += "GL_EXT_texture_storage ";
+ extensionString += "GL_EXT_texture_storage ";
// ANGLE-specific extensions
if (supportsDepthTextures())
{
- mExtensionString += "GL_ANGLE_depth_texture ";
+ extensionString += "GL_ANGLE_depth_texture ";
}
- mExtensionString += "GL_ANGLE_framebuffer_blit ";
+ extensionString += "GL_ANGLE_framebuffer_blit ";
if (getMaxSupportedSamples() != 0)
{
- mExtensionString += "GL_ANGLE_framebuffer_multisample ";
+ extensionString += "GL_ANGLE_framebuffer_multisample ";
}
if (supportsInstancing())
{
- mExtensionString += "GL_ANGLE_instanced_arrays ";
+ extensionString += "GL_ANGLE_instanced_arrays ";
}
- mExtensionString += "GL_ANGLE_pack_reverse_row_order ";
+ extensionString += "GL_ANGLE_pack_reverse_row_order ";
if (supportsDXT3Textures())
{
- mExtensionString += "GL_ANGLE_texture_compression_dxt3 ";
+ extensionString += "GL_ANGLE_texture_compression_dxt3 ";
}
if (supportsDXT5Textures())
{
- mExtensionString += "GL_ANGLE_texture_compression_dxt5 ";
+ extensionString += "GL_ANGLE_texture_compression_dxt5 ";
}
- mExtensionString += "GL_ANGLE_texture_usage ";
- mExtensionString += "GL_ANGLE_translated_shader_source ";
+ extensionString += "GL_ANGLE_texture_usage ";
+ extensionString += "GL_ANGLE_translated_shader_source ";
// Other vendor-specific extensions
if (supportsEventQueries())
{
- mExtensionString += "GL_NV_fence ";
+ extensionString += "GL_NV_fence ";
}
- std::string::size_type end = mExtensionString.find_last_not_of(' ');
+ std::string::size_type end = extensionString.find_last_not_of(' ');
if (end != std::string::npos)
{
- mExtensionString.resize(end+1);
+ extensionString.resize(end+1);
}
+
+ mExtensionString = makeStaticString(extensionString);
}
const char *Context::getExtensionString() const
{
- return mExtensionString.c_str();
+ return mExtensionString;
}
void Context::initRendererString()
{
- D3DADAPTER_IDENTIFIER9 *identifier = mDisplay->getAdapterIdentifier();
+ std::ostringstream rendererString;
+ rendererString << "ANGLE (";
+ rendererString << mRenderer->getRendererDescription();
+ rendererString << ")";
- mRendererString = "ANGLE (";
- mRendererString += identifier->Description;
- mRendererString += ")";
+ mRendererString = makeStaticString(rendererString.str());
}
const char *Context::getRendererString() const
{
- return mRendererString.c_str();
+ return mRendererString;
}
void Context::blitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1,
@@ -4006,179 +2659,216 @@ void Context::blitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1
if (!readFramebuffer || readFramebuffer->completeness() != GL_FRAMEBUFFER_COMPLETE ||
!drawFramebuffer || drawFramebuffer->completeness() != GL_FRAMEBUFFER_COMPLETE)
{
- return error(GL_INVALID_FRAMEBUFFER_OPERATION);
+ return gl::error(GL_INVALID_FRAMEBUFFER_OPERATION);
}
if (drawFramebuffer->getSamples() != 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
+ }
+
+ Renderbuffer *readColorBuffer = readFramebuffer->getReadColorbuffer();
+ Renderbuffer *drawColorBuffer = drawFramebuffer->getFirstColorbuffer();
+
+ if (drawColorBuffer == NULL)
+ {
+ ERR("Draw buffers formats don't match, which is not supported in this implementation of BlitFramebufferANGLE");
+ return gl::error(GL_INVALID_OPERATION);
}
- int readBufferWidth = readFramebuffer->getColorbuffer()->getWidth();
- int readBufferHeight = readFramebuffer->getColorbuffer()->getHeight();
- int drawBufferWidth = drawFramebuffer->getColorbuffer()->getWidth();
- int drawBufferHeight = drawFramebuffer->getColorbuffer()->getHeight();
+ int readBufferWidth = readColorBuffer->getWidth();
+ int readBufferHeight = readColorBuffer->getHeight();
+ int drawBufferWidth = drawColorBuffer->getWidth();
+ int drawBufferHeight = drawColorBuffer->getHeight();
- RECT sourceRect;
- RECT destRect;
+ Rectangle sourceRect;
+ Rectangle destRect;
if (srcX0 < srcX1)
{
- sourceRect.left = srcX0;
- sourceRect.right = srcX1;
- destRect.left = dstX0;
- destRect.right = dstX1;
+ sourceRect.x = srcX0;
+ destRect.x = dstX0;
+ sourceRect.width = srcX1 - srcX0;
+ destRect.width = dstX1 - dstX0;
}
else
{
- sourceRect.left = srcX1;
- destRect.left = dstX1;
- sourceRect.right = srcX0;
- destRect.right = dstX0;
+ sourceRect.x = srcX1;
+ destRect.x = dstX1;
+ sourceRect.width = srcX0 - srcX1;
+ destRect.width = dstX0 - dstX1;
}
if (srcY0 < srcY1)
{
- sourceRect.bottom = srcY1;
- destRect.bottom = dstY1;
- sourceRect.top = srcY0;
- destRect.top = dstY0;
+ sourceRect.height = srcY1 - srcY0;
+ destRect.height = dstY1 - dstY0;
+ sourceRect.y = srcY0;
+ destRect.y = dstY0;
}
else
{
- sourceRect.bottom = srcY0;
- destRect.bottom = dstY0;
- sourceRect.top = srcY1;
- destRect.top = dstY1;
+ sourceRect.height = srcY0 - srcY1;
+ destRect.height = dstY0 - srcY1;
+ sourceRect.y = srcY1;
+ destRect.y = dstY1;
}
- RECT sourceScissoredRect = sourceRect;
- RECT destScissoredRect = destRect;
+ Rectangle sourceScissoredRect = sourceRect;
+ Rectangle destScissoredRect = destRect;
if (mState.scissorTest)
{
- // Only write to parts of the destination framebuffer which pass the scissor test
- // Please note: the destRect is now in D3D-style coordinates, so the *top* of the
- // rect will be checked against scissorY, rather than the bottom.
- if (destRect.left < mState.scissorX)
+ // Only write to parts of the destination framebuffer which pass the scissor test.
+ if (destRect.x < mState.scissor.x)
{
- int xDiff = mState.scissorX - destRect.left;
- destScissoredRect.left = mState.scissorX;
- sourceScissoredRect.left += xDiff;
+ int xDiff = mState.scissor.x - destRect.x;
+ destScissoredRect.x = mState.scissor.x;
+ destScissoredRect.width -= xDiff;
+ sourceScissoredRect.x += xDiff;
+ sourceScissoredRect.width -= xDiff;
+
}
- if (destRect.right > mState.scissorX + mState.scissorWidth)
+ if (destRect.x + destRect.width > mState.scissor.x + mState.scissor.width)
{
- int xDiff = destRect.right - (mState.scissorX + mState.scissorWidth);
- destScissoredRect.right = mState.scissorX + mState.scissorWidth;
- sourceScissoredRect.right -= xDiff;
+ int xDiff = (destRect.x + destRect.width) - (mState.scissor.x + mState.scissor.width);
+ destScissoredRect.width -= xDiff;
+ sourceScissoredRect.width -= xDiff;
}
- if (destRect.top < mState.scissorY)
+ if (destRect.y < mState.scissor.y)
{
- int yDiff = mState.scissorY - destRect.top;
- destScissoredRect.top = mState.scissorY;
- sourceScissoredRect.top += yDiff;
+ int yDiff = mState.scissor.y - destRect.y;
+ destScissoredRect.y = mState.scissor.y;
+ destScissoredRect.height -= yDiff;
+ sourceScissoredRect.y += yDiff;
+ sourceScissoredRect.height -= yDiff;
}
- if (destRect.bottom > mState.scissorY + mState.scissorHeight)
+ if (destRect.y + destRect.height > mState.scissor.y + mState.scissor.height)
{
- int yDiff = destRect.bottom - (mState.scissorY + mState.scissorHeight);
- destScissoredRect.bottom = mState.scissorY + mState.scissorHeight;
- sourceScissoredRect.bottom -= yDiff;
+ int yDiff = (destRect.y + destRect.height) - (mState.scissor.y + mState.scissor.height);
+ destScissoredRect.height -= yDiff;
+ sourceScissoredRect.height -= yDiff;
}
}
bool blitRenderTarget = false;
bool blitDepthStencil = false;
- RECT sourceTrimmedRect = sourceScissoredRect;
- RECT destTrimmedRect = destScissoredRect;
+ Rectangle sourceTrimmedRect = sourceScissoredRect;
+ Rectangle destTrimmedRect = destScissoredRect;
// The source & destination rectangles also may need to be trimmed if they fall out of the bounds of
// the actual draw and read surfaces.
- if (sourceTrimmedRect.left < 0)
+ if (sourceTrimmedRect.x < 0)
{
- int xDiff = 0 - sourceTrimmedRect.left;
- sourceTrimmedRect.left = 0;
- destTrimmedRect.left += xDiff;
+ int xDiff = 0 - sourceTrimmedRect.x;
+ sourceTrimmedRect.x = 0;
+ sourceTrimmedRect.width -= xDiff;
+ destTrimmedRect.x += xDiff;
+ destTrimmedRect.width -= xDiff;
}
- if (sourceTrimmedRect.right > readBufferWidth)
+ if (sourceTrimmedRect.x + sourceTrimmedRect.width > readBufferWidth)
{
- int xDiff = sourceTrimmedRect.right - readBufferWidth;
- sourceTrimmedRect.right = readBufferWidth;
- destTrimmedRect.right -= xDiff;
+ int xDiff = (sourceTrimmedRect.x + sourceTrimmedRect.width) - readBufferWidth;
+ sourceTrimmedRect.width -= xDiff;
+ destTrimmedRect.width -= xDiff;
}
- if (sourceTrimmedRect.top < 0)
+ if (sourceTrimmedRect.y < 0)
{
- int yDiff = 0 - sourceTrimmedRect.top;
- sourceTrimmedRect.top = 0;
- destTrimmedRect.top += yDiff;
+ int yDiff = 0 - sourceTrimmedRect.y;
+ sourceTrimmedRect.y = 0;
+ sourceTrimmedRect.height -= yDiff;
+ destTrimmedRect.y += yDiff;
+ destTrimmedRect.height -= yDiff;
}
- if (sourceTrimmedRect.bottom > readBufferHeight)
+ if (sourceTrimmedRect.y + sourceTrimmedRect.height > readBufferHeight)
{
- int yDiff = sourceTrimmedRect.bottom - readBufferHeight;
- sourceTrimmedRect.bottom = readBufferHeight;
- destTrimmedRect.bottom -= yDiff;
+ int yDiff = (sourceTrimmedRect.y + sourceTrimmedRect.height) - readBufferHeight;
+ sourceTrimmedRect.height -= yDiff;
+ destTrimmedRect.height -= yDiff;
}
- if (destTrimmedRect.left < 0)
+ if (destTrimmedRect.x < 0)
{
- int xDiff = 0 - destTrimmedRect.left;
- destTrimmedRect.left = 0;
- sourceTrimmedRect.left += xDiff;
+ int xDiff = 0 - destTrimmedRect.x;
+ destTrimmedRect.x = 0;
+ destTrimmedRect.width -= xDiff;
+ sourceTrimmedRect.x += xDiff;
+ sourceTrimmedRect.width -= xDiff;
}
- if (destTrimmedRect.right > drawBufferWidth)
+ if (destTrimmedRect.x + destTrimmedRect.width > drawBufferWidth)
{
- int xDiff = destTrimmedRect.right - drawBufferWidth;
- destTrimmedRect.right = drawBufferWidth;
- sourceTrimmedRect.right -= xDiff;
+ int xDiff = (destTrimmedRect.x + destTrimmedRect.width) - drawBufferWidth;
+ destTrimmedRect.width -= xDiff;
+ sourceTrimmedRect.width -= xDiff;
}
- if (destTrimmedRect.top < 0)
+ if (destTrimmedRect.y < 0)
{
- int yDiff = 0 - destTrimmedRect.top;
- destTrimmedRect.top = 0;
- sourceTrimmedRect.top += yDiff;
+ int yDiff = 0 - destTrimmedRect.y;
+ destTrimmedRect.y = 0;
+ destTrimmedRect.height -= yDiff;
+ sourceTrimmedRect.y += yDiff;
+ sourceTrimmedRect.height -= yDiff;
}
- if (destTrimmedRect.bottom > drawBufferHeight)
+ if (destTrimmedRect.y + destTrimmedRect.height > drawBufferHeight)
{
- int yDiff = destTrimmedRect.bottom - drawBufferHeight;
- destTrimmedRect.bottom = drawBufferHeight;
- sourceTrimmedRect.bottom -= yDiff;
+ int yDiff = (destTrimmedRect.y + destTrimmedRect.height) - drawBufferHeight;
+ destTrimmedRect.height -= yDiff;
+ sourceTrimmedRect.height -= yDiff;
}
bool partialBufferCopy = false;
- if (sourceTrimmedRect.bottom - sourceTrimmedRect.top < readBufferHeight ||
- sourceTrimmedRect.right - sourceTrimmedRect.left < readBufferWidth ||
- destTrimmedRect.bottom - destTrimmedRect.top < drawBufferHeight ||
- destTrimmedRect.right - destTrimmedRect.left < drawBufferWidth ||
- sourceTrimmedRect.top != 0 || destTrimmedRect.top != 0 || sourceTrimmedRect.left != 0 || destTrimmedRect.left != 0)
+ if (sourceTrimmedRect.height < readBufferHeight ||
+ sourceTrimmedRect.width < readBufferWidth ||
+ destTrimmedRect.height < drawBufferHeight ||
+ destTrimmedRect.width < drawBufferWidth ||
+ sourceTrimmedRect.y != 0 || destTrimmedRect.y != 0 || sourceTrimmedRect.x != 0 || destTrimmedRect.x != 0)
{
partialBufferCopy = true;
}
if (mask & GL_COLOR_BUFFER_BIT)
{
- const bool validReadType = readFramebuffer->getColorbufferType() == GL_TEXTURE_2D ||
- readFramebuffer->getColorbufferType() == GL_RENDERBUFFER;
- const bool validDrawType = drawFramebuffer->getColorbufferType() == GL_TEXTURE_2D ||
- drawFramebuffer->getColorbufferType() == GL_RENDERBUFFER;
- if (!validReadType || !validDrawType ||
- readFramebuffer->getColorbuffer()->getD3DFormat() != drawFramebuffer->getColorbuffer()->getD3DFormat())
+ const GLenum readColorbufferType = readFramebuffer->getReadColorbufferType();
+ const bool validReadType = (readColorbufferType == GL_TEXTURE_2D) || (readColorbufferType == GL_RENDERBUFFER);
+ bool validDrawType = true;
+ bool validDrawFormat = true;
+
+ for (unsigned int colorAttachment = 0; colorAttachment < gl::IMPLEMENTATION_MAX_DRAW_BUFFERS; colorAttachment++)
+ {
+ if (drawFramebuffer->isEnabledColorAttachment(colorAttachment))
+ {
+ if (drawFramebuffer->getColorbufferType(colorAttachment) != GL_TEXTURE_2D &&
+ drawFramebuffer->getColorbufferType(colorAttachment) != GL_RENDERBUFFER)
+ {
+ validDrawType = false;
+ }
+
+ if (drawFramebuffer->getColorbuffer(colorAttachment)->getActualFormat() != readColorBuffer->getActualFormat())
+ {
+ validDrawFormat = false;
+ }
+ }
+ }
+
+ if (!validReadType || !validDrawType || !validDrawFormat)
{
ERR("Color buffer format conversion in BlitFramebufferANGLE not supported by this implementation");
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (partialBufferCopy && readFramebuffer->getSamples() != 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
blitRenderTarget = true;
@@ -4198,9 +2888,9 @@ void Context::blitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1
if (readFramebuffer->getDepthbuffer() && drawFramebuffer->getDepthbuffer())
{
if (readFramebuffer->getDepthbufferType() != drawFramebuffer->getDepthbufferType() ||
- readFramebuffer->getDepthbuffer()->getD3DFormat() != drawFramebuffer->getDepthbuffer()->getD3DFormat())
+ readFramebuffer->getDepthbuffer()->getActualFormat() != drawFramebuffer->getDepthbuffer()->getActualFormat())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
blitDepthStencil = true;
@@ -4214,9 +2904,9 @@ void Context::blitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1
if (readFramebuffer->getStencilbuffer() && drawFramebuffer->getStencilbuffer())
{
if (readFramebuffer->getStencilbufferType() != drawFramebuffer->getStencilbufferType() ||
- readFramebuffer->getStencilbuffer()->getD3DFormat() != drawFramebuffer->getStencilbuffer()->getD3DFormat())
+ readFramebuffer->getStencilbuffer()->getActualFormat() != drawFramebuffer->getStencilbuffer()->getActualFormat())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
blitDepthStencil = true;
@@ -4228,255 +2918,29 @@ void Context::blitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1
if (partialBufferCopy)
{
ERR("Only whole-buffer depth and stencil blits are supported by this implementation.");
- return error(GL_INVALID_OPERATION); // only whole-buffer copies are permitted
+ return gl::error(GL_INVALID_OPERATION); // only whole-buffer copies are permitted
}
if ((drawDSBuffer && drawDSBuffer->getSamples() != 0) ||
(readDSBuffer && readDSBuffer->getSamples() != 0))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
if (blitRenderTarget || blitDepthStencil)
{
- mDisplay->endScene();
-
- if (blitRenderTarget)
- {
- IDirect3DSurface9* readRenderTarget = readFramebuffer->getRenderTarget();
- IDirect3DSurface9* drawRenderTarget = drawFramebuffer->getRenderTarget();
-
- HRESULT result = mDevice->StretchRect(readRenderTarget, &sourceTrimmedRect,
- drawRenderTarget, &destTrimmedRect, D3DTEXF_NONE);
-
- readRenderTarget->Release();
- drawRenderTarget->Release();
-
- if (FAILED(result))
- {
- ERR("BlitFramebufferANGLE failed: StretchRect returned %x.", result);
- return;
- }
- }
-
- if (blitDepthStencil)
- {
- IDirect3DSurface9* readDepthStencil = readFramebuffer->getDepthStencil();
- IDirect3DSurface9* drawDepthStencil = drawFramebuffer->getDepthStencil();
-
- HRESULT result = mDevice->StretchRect(readDepthStencil, NULL, drawDepthStencil, NULL, D3DTEXF_NONE);
-
- readDepthStencil->Release();
- drawDepthStencil->Release();
-
- if (FAILED(result))
- {
- ERR("BlitFramebufferANGLE failed: StretchRect returned %x.", result);
- return;
- }
- }
- }
-}
-
-VertexDeclarationCache::VertexDeclarationCache() : mMaxLru(0)
-{
- for (int i = 0; i < NUM_VERTEX_DECL_CACHE_ENTRIES; i++)
- {
- mVertexDeclCache[i].vertexDeclaration = NULL;
- mVertexDeclCache[i].lruCount = 0;
+ mRenderer->blitRect(readFramebuffer, sourceTrimmedRect, drawFramebuffer, destTrimmedRect, blitRenderTarget, blitDepthStencil);
}
}
-VertexDeclarationCache::~VertexDeclarationCache()
-{
- for (int i = 0; i < NUM_VERTEX_DECL_CACHE_ENTRIES; i++)
- {
- if (mVertexDeclCache[i].vertexDeclaration)
- {
- mVertexDeclCache[i].vertexDeclaration->Release();
- }
- }
-}
-
-GLenum VertexDeclarationCache::applyDeclaration(IDirect3DDevice9 *device, TranslatedAttribute attributes[], ProgramBinary *programBinary, GLsizei instances, GLsizei *repeatDraw)
-{
- *repeatDraw = 1;
-
- int indexedAttribute = MAX_VERTEX_ATTRIBS;
- int instancedAttribute = MAX_VERTEX_ATTRIBS;
-
- if (instances > 0)
- {
- // Find an indexed attribute to be mapped to D3D stream 0
- for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
- {
- if (attributes[i].active)
- {
- if (indexedAttribute == MAX_VERTEX_ATTRIBS)
- {
- if (attributes[i].divisor == 0)
- {
- indexedAttribute = i;
- }
- }
- else if (instancedAttribute == MAX_VERTEX_ATTRIBS)
- {
- if (attributes[i].divisor != 0)
- {
- instancedAttribute = i;
- }
- }
- else break; // Found both an indexed and instanced attribute
- }
- }
-
- if (indexedAttribute == MAX_VERTEX_ATTRIBS)
- {
- return GL_INVALID_OPERATION;
- }
- }
-
- D3DVERTEXELEMENT9 elements[MAX_VERTEX_ATTRIBS + 1];
- D3DVERTEXELEMENT9 *element = &elements[0];
-
- for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
- {
- if (attributes[i].active)
- {
- int stream = i;
-
- if (instances > 0)
- {
- // Due to a bug on ATI cards we can't enable instancing when none of the attributes are instanced.
- if (instancedAttribute == MAX_VERTEX_ATTRIBS)
- {
- *repeatDraw = instances;
- }
- else
- {
- if (i == indexedAttribute)
- {
- stream = 0;
- }
- else if (i == 0)
- {
- stream = indexedAttribute;
- }
-
- UINT frequency = 1;
-
- if (attributes[i].divisor == 0)
- {
- frequency = D3DSTREAMSOURCE_INDEXEDDATA | instances;
- }
- else
- {
- frequency = D3DSTREAMSOURCE_INSTANCEDATA | attributes[i].divisor;
- }
-
- device->SetStreamSourceFreq(stream, frequency);
- mInstancingEnabled = true;
- }
- }
-
- if (mAppliedVBs[stream].serial != attributes[i].serial ||
- mAppliedVBs[stream].stride != attributes[i].stride ||
- mAppliedVBs[stream].offset != attributes[i].offset)
- {
- device->SetStreamSource(stream, attributes[i].vertexBuffer, attributes[i].offset, attributes[i].stride);
- mAppliedVBs[stream].serial = attributes[i].serial;
- mAppliedVBs[stream].stride = attributes[i].stride;
- mAppliedVBs[stream].offset = attributes[i].offset;
- }
-
- element->Stream = stream;
- element->Offset = 0;
- element->Type = attributes[i].type;
- element->Method = D3DDECLMETHOD_DEFAULT;
- element->Usage = D3DDECLUSAGE_TEXCOORD;
- element->UsageIndex = programBinary->getSemanticIndex(i);
- element++;
- }
- }
-
- if (instances == 0 || instancedAttribute == MAX_VERTEX_ATTRIBS)
- {
- if (mInstancingEnabled)
- {
- for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
- {
- device->SetStreamSourceFreq(i, 1);
- }
-
- mInstancingEnabled = false;
- }
- }
-
- static const D3DVERTEXELEMENT9 end = D3DDECL_END();
- *(element++) = end;
-
- for (int i = 0; i < NUM_VERTEX_DECL_CACHE_ENTRIES; i++)
- {
- VertexDeclCacheEntry *entry = &mVertexDeclCache[i];
- if (memcmp(entry->cachedElements, elements, (element - elements) * sizeof(D3DVERTEXELEMENT9)) == 0 && entry->vertexDeclaration)
- {
- entry->lruCount = ++mMaxLru;
- if(entry->vertexDeclaration != mLastSetVDecl)
- {
- device->SetVertexDeclaration(entry->vertexDeclaration);
- mLastSetVDecl = entry->vertexDeclaration;
- }
-
- return GL_NO_ERROR;
- }
- }
-
- VertexDeclCacheEntry *lastCache = mVertexDeclCache;
-
- for (int i = 0; i < NUM_VERTEX_DECL_CACHE_ENTRIES; i++)
- {
- if (mVertexDeclCache[i].lruCount < lastCache->lruCount)
- {
- lastCache = &mVertexDeclCache[i];
- }
- }
-
- if (lastCache->vertexDeclaration != NULL)
- {
- lastCache->vertexDeclaration->Release();
- lastCache->vertexDeclaration = NULL;
- // mLastSetVDecl is set to the replacement, so we don't have to worry
- // about it.
- }
-
- memcpy(lastCache->cachedElements, elements, (element - elements) * sizeof(D3DVERTEXELEMENT9));
- device->CreateVertexDeclaration(elements, &lastCache->vertexDeclaration);
- device->SetVertexDeclaration(lastCache->vertexDeclaration);
- mLastSetVDecl = lastCache->vertexDeclaration;
- lastCache->lruCount = ++mMaxLru;
-
- return GL_NO_ERROR;
-}
-
-void VertexDeclarationCache::markStateDirty()
-{
- for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
- {
- mAppliedVBs[i].serial = 0;
- }
-
- mLastSetVDecl = NULL;
- mInstancingEnabled = true; // Forces it to be disabled when not used
-}
-
}
extern "C"
{
-gl::Context *glCreateContext(const egl::Config *config, const gl::Context *shareContext, bool notifyResets, bool robustAccess)
+gl::Context *glCreateContext(const gl::Context *shareContext, rx::Renderer *renderer, bool notifyResets, bool robustAccess)
{
- return new gl::Context(config, shareContext, notifyResets, robustAccess);
+ return new gl::Context(shareContext, renderer, notifyResets, robustAccess);
}
void glDestroyContext(gl::Context *context)
@@ -4498,4 +2962,5 @@ gl::Context *glGetCurrentContext()
{
return gl::getContext();
}
+
}
diff --git a/src/3rdparty/angle/src/libGLESv2/Context.h b/src/3rdparty/angle/src/libGLESv2/Context.h
index 2bbae76ef8..9c222be24d 100644
--- a/src/3rdparty/angle/src/libGLESv2/Context.h
+++ b/src/3rdparty/angle/src/libGLESv2/Context.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -15,7 +15,6 @@
#include <GLES2/gl2ext.h>
#define EGLAPI
#include <EGL/egl.h>
-#include <d3d9.h>
#include <string>
#include <map>
@@ -27,22 +26,23 @@
#include "common/angleutils.h"
#include "common/RefCountObject.h"
-#include "libGLESv2/ResourceManager.h"
#include "libGLESv2/HandleAllocator.h"
+#include "libGLESv2/angletypes.h"
+#include "libGLESv2/Constants.h"
+
+namespace rx
+{
+class Renderer;
+}
namespace egl
{
class Display;
class Surface;
-class Config;
}
namespace gl
{
-struct TranslatedAttribute;
-struct TranslatedIndexData;
-
-class Buffer;
class Shader;
class Program;
class ProgramBinary;
@@ -54,35 +54,12 @@ class Renderbuffer;
class RenderbufferStorage;
class Colorbuffer;
class Depthbuffer;
-class StreamingIndexBuffer;
class Stencilbuffer;
class DepthStencilbuffer;
-class VertexDataManager;
-class IndexDataManager;
-class Blit;
class Fence;
class Query;
-
-enum
-{
- D3D9_MAX_FLOAT_CONSTANTS = 256,
- D3D9_MAX_BOOL_CONSTANTS = 16,
- D3D9_MAX_INT_CONSTANTS = 16,
-
- MAX_VERTEX_ATTRIBS = 16,
- MAX_VERTEX_UNIFORM_VECTORS = D3D9_MAX_FLOAT_CONSTANTS - 2, // Reserve space for dx_HalfPixelSize and dx_DepthRange.
- MAX_VARYING_VECTORS_SM2 = 8,
- MAX_VARYING_VECTORS_SM3 = 10,
- MAX_TEXTURE_IMAGE_UNITS = 16,
- MAX_VERTEX_TEXTURE_IMAGE_UNITS_VTF = 4, // For devices supporting vertex texture fetch
- MAX_COMBINED_TEXTURE_IMAGE_UNITS_VTF = MAX_TEXTURE_IMAGE_UNITS + MAX_VERTEX_TEXTURE_IMAGE_UNITS_VTF,
- MAX_FRAGMENT_UNIFORM_VECTORS_SM2 = 32 - 3, // Reserve space for dx_Coord, dx_Depth, and dx_DepthRange. dx_PointOrLines and dx_FrontCCW use separate bool registers.
- MAX_FRAGMENT_UNIFORM_VECTORS_SM3 = 224 - 3,
- MAX_DRAW_BUFFERS = 1,
-
- GL_BGRA4_ANGLEX = 0x6ABC,
- GL_BGR5_A1_ANGLEX = 0x6ABD
-};
+class ResourceManager;
+class Buffer;
enum QueryType
{
@@ -92,19 +69,6 @@ enum QueryType
QUERY_TYPE_COUNT
};
-const float ALIASED_LINE_WIDTH_RANGE_MIN = 1.0f;
-const float ALIASED_LINE_WIDTH_RANGE_MAX = 1.0f;
-const float ALIASED_POINT_SIZE_RANGE_MIN = 1.0f;
-const float ALIASED_POINT_SIZE_RANGE_MAX_SM2 = 1.0f;
-
-struct Color
-{
- float red;
- float green;
- float blue;
- float alpha;
-};
-
// Helper structure describing a single vertex attribute
class VertexAttribute
{
@@ -155,8 +119,6 @@ class VertexAttribute
unsigned int mDivisor;
};
-typedef VertexAttribute VertexAttributeArray[MAX_VERTEX_ATTRIBS];
-
// Helper structure to store all raw state
struct State
{
@@ -164,67 +126,29 @@ struct State
GLclampf depthClearValue;
int stencilClearValue;
- bool cullFace;
- GLenum cullMode;
- GLenum frontFace;
- bool depthTest;
- GLenum depthFunc;
- bool blend;
- GLenum sourceBlendRGB;
- GLenum destBlendRGB;
- GLenum sourceBlendAlpha;
- GLenum destBlendAlpha;
- GLenum blendEquationRGB;
- GLenum blendEquationAlpha;
+ RasterizerState rasterizer;
+ bool scissorTest;
+ Rectangle scissor;
+
+ BlendState blend;
Color blendColor;
- bool stencilTest;
- GLenum stencilFunc;
- GLint stencilRef;
- GLuint stencilMask;
- GLenum stencilFail;
- GLenum stencilPassDepthFail;
- GLenum stencilPassDepthPass;
- GLuint stencilWritemask;
- GLenum stencilBackFunc;
- GLint stencilBackRef;
- GLuint stencilBackMask;
- GLenum stencilBackFail;
- GLenum stencilBackPassDepthFail;
- GLenum stencilBackPassDepthPass;
- GLuint stencilBackWritemask;
- bool polygonOffsetFill;
- GLfloat polygonOffsetFactor;
- GLfloat polygonOffsetUnits;
- bool sampleAlphaToCoverage;
bool sampleCoverage;
GLclampf sampleCoverageValue;
bool sampleCoverageInvert;
- bool scissorTest;
- bool dither;
+
+ DepthStencilState depthStencil;
+ GLint stencilRef;
+ GLint stencilBackRef;
GLfloat lineWidth;
GLenum generateMipmapHint;
GLenum fragmentShaderDerivativeHint;
- GLint viewportX;
- GLint viewportY;
- GLsizei viewportWidth;
- GLsizei viewportHeight;
+ Rectangle viewport;
float zNear;
float zFar;
- GLint scissorX;
- GLint scissorY;
- GLsizei scissorWidth;
- GLsizei scissorHeight;
-
- bool colorMaskRed;
- bool colorMaskGreen;
- bool colorMaskBlue;
- bool colorMaskAlpha;
- bool depthMask;
-
unsigned int activeSampler; // Active texture unit selector - GL_TEXTURE0
BindingPointer<Buffer> arrayBuffer;
BindingPointer<Buffer> elementArrayBuffer;
@@ -234,7 +158,7 @@ struct State
GLuint currentProgram;
VertexAttribute vertexAttribute[MAX_VERTEX_ATTRIBS];
- BindingPointer<Texture> samplerTexture[TEXTURE_TYPE_COUNT][MAX_COMBINED_TEXTURE_IMAGE_UNITS_VTF];
+ BindingPointer<Texture> samplerTexture[TEXTURE_TYPE_COUNT][IMPLEMENTATION_MAX_COMBINED_TEXTURE_IMAGE_UNITS];
BindingPointer<Query> activeQuery[QUERY_TYPE_COUNT];
GLint unpackAlignment;
@@ -242,52 +166,14 @@ struct State
bool packReverseRowOrder;
};
-// Helper class to construct and cache vertex declarations
-class VertexDeclarationCache
-{
- public:
- VertexDeclarationCache();
- ~VertexDeclarationCache();
-
- GLenum applyDeclaration(IDirect3DDevice9 *device, TranslatedAttribute attributes[], ProgramBinary *programBinary, GLsizei instances, GLsizei *repeatDraw);
-
- void markStateDirty();
-
- private:
- UINT mMaxLru;
-
- enum { NUM_VERTEX_DECL_CACHE_ENTRIES = 32 };
-
- struct VBData
- {
- unsigned int serial;
- unsigned int stride;
- unsigned int offset;
- };
-
- VBData mAppliedVBs[MAX_VERTEX_ATTRIBS];
- IDirect3DVertexDeclaration9 *mLastSetVDecl;
- bool mInstancingEnabled;
-
- struct VertexDeclCacheEntry
- {
- D3DVERTEXELEMENT9 cachedElements[MAX_VERTEX_ATTRIBS + 1];
- UINT lruCount;
- IDirect3DVertexDeclaration9 *vertexDeclaration;
- } mVertexDeclCache[NUM_VERTEX_DECL_CACHE_ENTRIES];
-};
-
class Context
{
public:
- Context(const egl::Config *config, const gl::Context *shareContext, bool notifyResets, bool robustAccess);
+ Context(const gl::Context *shareContext, rx::Renderer *renderer, bool notifyResets, bool robustAccess);
~Context();
- void makeCurrent(egl::Display *display, egl::Surface *surface);
-
- virtual void markAllStateDirty();
- void markDxUniformsDirty();
+ void makeCurrent(egl::Surface *surface);
virtual void markContextLost();
bool isContextLost();
@@ -377,8 +263,6 @@ class Context
bool normalized, GLsizei stride, const void *pointer);
const void *getVertexAttribPointer(unsigned int attribNum) const;
- const VertexAttributeArray &getVertexAttributes();
-
void setUnpackAlignment(GLint alignment);
GLint getUnpackAlignment() const;
@@ -430,7 +314,7 @@ class Context
void setFramebufferZero(Framebuffer *framebuffer);
- void setRenderbufferStorage(RenderbufferStorage *renderbuffer);
+ void setRenderbufferStorage(GLsizei width, GLsizei height, GLenum internalformat, GLsizei samples);
void setVertexAttrib(GLuint index, const GLfloat *values);
void setVertexAttribDivisor(GLuint index, GLuint divisor);
@@ -465,8 +349,6 @@ class Context
void drawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instances);
void sync(bool block); // flush/finish
- void drawLineLoop(GLsizei count, GLenum type, const GLvoid *indices, int minIndex);
-
void recordInvalidEnum();
void recordInvalidValue();
void recordInvalidOperation();
@@ -477,22 +359,20 @@ class Context
GLenum getResetStatus();
virtual bool isResetNotificationEnabled();
- bool supportsShaderModel3() const;
+ int getMajorShaderModel() const;
float getMaximumPointSize() const;
- int getMaximumVaryingVectors() const;
- unsigned int getMaximumVertexTextureImageUnits() const;
unsigned int getMaximumCombinedTextureImageUnits() const;
- int getMaximumFragmentUniformVectors() const;
int getMaximumRenderbufferDimension() const;
int getMaximumTextureDimension() const;
int getMaximumCubeTextureDimension() const;
int getMaximumTextureLevel() const;
+ unsigned int getMaximumRenderTargets() const;
GLsizei getMaxSupportedSamples() const;
- int getNearestSupportedSamples(D3DFORMAT format, int requested) const;
const char *getExtensionString() const;
const char *getRendererString() const;
bool supportsEventQueries() const;
bool supportsOcclusionQueries() const;
+ bool supportsBGRATextures() const;
bool supportsDXT1Textures() const;
bool supportsDXT3Textures() const;
bool supportsDXT5Textures() const;
@@ -518,17 +398,11 @@ class Context
GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1,
GLbitfield mask);
- Blit *getBlitter() { return mBlit; }
-
- const D3DCAPS9 &getDeviceCaps() { return mDeviceCaps; }
-
private:
DISALLOW_COPY_AND_ASSIGN(Context);
- bool applyRenderTarget(bool ignoreViewport);
+ bool applyRenderTarget(GLenum drawMode, bool ignoreViewport);
void applyState(GLenum drawMode);
- GLenum applyVertexBuffer(GLint first, GLsizei count, GLsizei instances, GLsizei *repeatDraw);
- GLenum applyIndexBuffer(const GLvoid *indices, GLsizei count, GLenum mode, GLenum type, TranslatedIndexData *indexInfo);
void applyShaders();
void applyTextures();
void applyTextures(SamplerType type);
@@ -541,14 +415,11 @@ class Context
Texture *getIncompleteTexture(TextureType type);
bool skipDraw(GLenum drawMode);
- bool isTriangleMode(GLenum drawMode);
void initExtensionString();
void initRendererString();
- const egl::Config *const mConfig;
- egl::Display *mDisplay;
- IDirect3DDevice9 *mDevice;
+ rx::Renderer *const mRenderer;
State mState;
@@ -575,15 +446,8 @@ class Context
QueryMap mQueryMap;
HandleAllocator mQueryHandleAllocator;
- std::string mExtensionString;
- std::string mRendererString;
-
- VertexDataManager *mVertexDataManager;
- IndexDataManager *mIndexDataManager;
-
- Blit *mBlit;
-
- StreamingIndexBuffer *mLineLoopIB;
+ const char *mExtensionString;
+ const char *mRendererString;
BindingPointer<Texture> mIncompleteTextures[TEXTURE_TYPE_COUNT];
@@ -601,36 +465,23 @@ class Context
GLenum mResetStrategy;
bool mRobustAccess;
- unsigned int mAppliedTextureSerialPS[MAX_TEXTURE_IMAGE_UNITS];
- unsigned int mAppliedTextureSerialVS[MAX_VERTEX_TEXTURE_IMAGE_UNITS_VTF];
- unsigned int mAppliedProgramBinarySerial;
- unsigned int mAppliedRenderTargetSerial;
- unsigned int mAppliedDepthbufferSerial;
- unsigned int mAppliedStencilbufferSerial;
- unsigned int mAppliedIBSerial;
- bool mDepthStencilInitialized;
- bool mViewportInitialized;
- D3DVIEWPORT9 mSetViewport;
- bool mRenderTargetDescInitialized;
- D3DSURFACE_DESC mRenderTargetDesc;
- bool mDxUniformsDirty;
BindingPointer<ProgramBinary> mCurrentProgramBinary;
Framebuffer *mBoundDrawFramebuffer;
- bool mSupportsShaderModel3;
+ int mMajorShaderModel;
float mMaximumPointSize;
bool mSupportsVertexTexture;
bool mSupportsNonPower2Texture;
bool mSupportsInstancing;
+ int mMaxViewportDimension;
int mMaxRenderbufferDimension;
int mMaxTextureDimension;
int mMaxCubeTextureDimension;
int mMaxTextureLevel;
float mMaxTextureAnisotropy;
- std::map<D3DFORMAT, bool *> mMultiSampleSupport;
- GLsizei mMaxSupportedSamples;
bool mSupportsEventQueries;
bool mSupportsOcclusionQueries;
+ bool mSupportsBGRATextures;
bool mSupportsDXT1Textures;
bool mSupportsDXT3Textures;
bool mSupportsDXT5Textures;
@@ -647,39 +498,8 @@ class Context
bool mSupportsTextureFilterAnisotropy;
int mNumCompressedTextureFormats;
- // state caching flags
- bool mClearStateDirty;
- bool mCullStateDirty;
- bool mDepthStateDirty;
- bool mMaskStateDirty;
- bool mPixelPackingStateDirty;
- bool mBlendStateDirty;
- bool mStencilStateDirty;
- bool mPolygonOffsetStateDirty;
- bool mScissorStateDirty;
- bool mSampleStateDirty;
- bool mFrontFaceDirty;
- bool mDitherStateDirty;
-
- IDirect3DStateBlock9 *mMaskedClearSavedState;
-
- D3DCAPS9 mDeviceCaps;
-
ResourceManager *mResourceManager;
-
- VertexDeclarationCache mVertexDeclarationCache;
};
}
-extern "C"
-{
-// Exported functions for use by EGL
-gl::Context *glCreateContext(const egl::Config *config, const gl::Context *shareContext, bool notifyResets, bool robustAccess);
-void glDestroyContext(gl::Context *context);
-void glMakeCurrent(gl::Context *context, egl::Display *display, egl::Surface *surface);
-gl::Context *glGetCurrentContext();
-__eglMustCastToProperFunctionPointerType __stdcall glGetProcAddress(const char *procname);
-bool __stdcall glBindTexImage(egl::Surface *surface);
-}
-
#endif // INCLUDE_CONTEXT_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/D3DConstantTable.cpp b/src/3rdparty/angle/src/libGLESv2/D3DConstantTable.cpp
deleted file mode 100644
index e136951bec..0000000000
--- a/src/3rdparty/angle/src/libGLESv2/D3DConstantTable.cpp
+++ /dev/null
@@ -1,231 +0,0 @@
-//
-// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-//
-
-// D3DConstantTable.cpp: Implements the D3DConstantTable class which parses
-// information about constants from the CTAB comment in a D3D shader blob.
-// Restructures the constant table as a hierarchy of constants in the same
-// way as D3DX.
-
-#include "libGLESv2/D3DConstantTable.h"
-
-#include <d3d9.h>
-#include <d3d9types.h>
-#include <windows.h>
-#include <mmsystem.h>
-
-#include "libGLESv2/BinaryStream.h"
-
-const static int SHADER_VERSION_MASK = D3DVS_VERSION(0, 0);
-const static int FOURCC_CTAB = MAKEFOURCC('C','T','A','B');
-
-namespace gl
-{
-// These structs and constants correspond to the format of the constant table in a shader binary.
-// They match the corresponding structures in d3dx9shader.h.
-namespace ctab
-{
-struct ConstantTable
-{
- DWORD size;
- DWORD creator;
- DWORD version;
- DWORD constants;
- DWORD constantInfos;
- DWORD flags;
- DWORD target;
-};
-
-struct ConstantInfo
-{
- DWORD name;
- WORD registerSet;
- WORD registerIndex;
- WORD registerCount;
- WORD reserved;
- DWORD typeInfo;
- DWORD defaultValue;
-};
-
-struct TypeInfo
-{
- WORD typeClass;
- WORD type;
- WORD rows;
- WORD columns;
- WORD elements;
- WORD structMembers;
- DWORD structMemberInfos;
-};
-
-struct StructMemberInfo
-{
- DWORD name;
- DWORD typeInfo;
-};
-}
-
-D3DConstant::D3DConstant(const char *base, const ctab::ConstantInfo *constantInfo)
-{
- const ctab::TypeInfo *typeInfo = reinterpret_cast<const ctab::TypeInfo*>(base + constantInfo->typeInfo);
-
- name = base + constantInfo->name;
- registerSet = static_cast<RegisterSet>(constantInfo->registerSet);
- registerIndex = constantInfo->registerIndex;
- registerCount = constantInfo->registerCount;
- typeClass = static_cast<Class>(typeInfo->typeClass);
- type = static_cast<Type>(typeInfo->type);
- rows = typeInfo->rows;
- columns = typeInfo->columns;
- elements = typeInfo->elements;
-
- if (typeClass == CLASS_STRUCT)
- {
- addStructMembers(base, registerSet, registerIndex, typeInfo);
- }
-}
-
-D3DConstant::D3DConstant(const char *base, RegisterSet registerSet, unsigned registerIndex, const ctab::StructMemberInfo *memberInfo)
- : registerSet(registerSet), registerIndex(registerIndex)
-{
- const ctab::TypeInfo *typeInfo = reinterpret_cast<const ctab::TypeInfo*>(base + memberInfo->typeInfo);
-
- name = base + memberInfo->name;
- registerCount = typeInfo->rows * typeInfo->elements;
- typeClass = static_cast<Class>(typeInfo->typeClass);
- type = static_cast<Type>(typeInfo->type);
- rows = typeInfo->rows;
- columns = typeInfo->columns;
- elements = typeInfo->elements;
-
- if (typeClass == CLASS_STRUCT)
- {
- registerCount = addStructMembers(base, registerSet, registerIndex, typeInfo);
- }
-}
-
-D3DConstant::~D3DConstant()
-{
- for (size_t j = 0; j < structMembers.size(); ++j)
- {
- for (size_t i = 0; i < structMembers[j].size(); ++i)
- {
- delete structMembers[j][i];
- }
- }
-}
-
-unsigned D3DConstant::addStructMembers(const char *base, RegisterSet registerSet, unsigned registerIndex, const ctab::TypeInfo *typeInfo)
-{
- const ctab::StructMemberInfo *memberInfos = reinterpret_cast<const ctab::StructMemberInfo*>(
- base + typeInfo->structMemberInfos);
-
- unsigned memberIndex = registerIndex;
-
- structMembers.resize(elements);
-
- for (unsigned j = 0; j < elements; ++j)
- {
- structMembers[j].resize(typeInfo->structMembers);
-
- for (unsigned i = 0; i < typeInfo->structMembers; ++i)
- {
- const ctab::TypeInfo *memberTypeInfo = reinterpret_cast<const ctab::TypeInfo*>(
- base + memberInfos[i].typeInfo);
-
- D3DConstant *member = new D3DConstant(base, registerSet, memberIndex, memberInfos + i);
- memberIndex += member->registerCount;
-
- structMembers[j][i] = member;
- }
- }
-
- return memberIndex - registerIndex;
-}
-
-D3DConstantTable::D3DConstantTable(void *blob, size_t size) : mError(false)
-{
- BinaryInputStream stream(blob, size);
-
- int version;
- stream.read(&version);
- if ((version & SHADER_VERSION_MASK) != SHADER_VERSION_MASK)
- {
- mError = true;
- return;
- }
-
- const ctab::ConstantTable* constantTable = NULL;
-
- while (!stream.error())
- {
- int token;
- stream.read(&token);
-
- if ((token & D3DSI_OPCODE_MASK) == D3DSIO_COMMENT)
- {
- size_t length = ((token & D3DSI_COMMENTSIZE_MASK) >> D3DSI_COMMENTSIZE_SHIFT) * sizeof(DWORD);
-
- int fourcc;
- stream.read(&fourcc);
- if (fourcc == FOURCC_CTAB)
- {
- constantTable = reinterpret_cast<const ctab::ConstantTable*>(static_cast<const char*>(blob) + stream.offset());
- break;
- }
-
- stream.skip(length - sizeof(fourcc));
- }
- else if (token == D3DSIO_END)
- {
- break;
- }
- }
-
- mError = !constantTable || stream.error();
- if (mError)
- {
- return;
- }
-
- const char *base = reinterpret_cast<const char*>(constantTable);
-
- mConstants.resize(constantTable->constants);
- const ctab::ConstantInfo *constantInfos =
- reinterpret_cast<const ctab::ConstantInfo*>(base + constantTable->constantInfos);
- for (size_t i = 0; i < constantTable->constants; ++i)
- {
- mConstants[i] = new D3DConstant(base, constantInfos + i);
- }
-}
-
-D3DConstantTable::~D3DConstantTable()
-{
- for (size_t i = 0; i < mConstants.size(); ++i)
- {
- delete mConstants[i];
- }
-}
-
-const D3DConstant *D3DConstantTable::getConstant(unsigned index) const
-{
- return mConstants[index];
-}
-
-const D3DConstant *D3DConstantTable::getConstantByName(const char *name) const
-{
- for (size_t i = 0; i < mConstants.size(); ++i)
- {
- const D3DConstant *constant = getConstant(i);
- if (constant->name == name)
- {
- return constant;
- }
- }
-
- return NULL;
-}
-
-}
diff --git a/src/3rdparty/angle/src/libGLESv2/D3DConstantTable.h b/src/3rdparty/angle/src/libGLESv2/D3DConstantTable.h
deleted file mode 100644
index ca6f3b9a3f..0000000000
--- a/src/3rdparty/angle/src/libGLESv2/D3DConstantTable.h
+++ /dev/null
@@ -1,117 +0,0 @@
-//
-// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-//
-
-// D3DConstantTable.h: Implements the D3DConstantTable class which parses
-// information about constants from the CTAB comment in a D3D shader blob.
-// Restructures the constant table as a hierarchy of constants in the same
-// way as D3DX.
-
-#ifndef LIBGLESV2_D3DCONSTANTTABLE_H_
-#define LIBGLESV2_D3DCONSTANTTABLE_H_
-
-#include <vector>
-#include <string>
-
-#include "common/angleutils.h"
-
-namespace gl
-{
-
-namespace ctab
-{
-struct ConstantTable;
-struct ConstantInfo;
-struct TypeInfo;
-struct StructMemberInfo;
-}
-
-struct D3DConstant
-{
- // These enums match those in d3dx9shader.h.
- enum Class
- {
- CLASS_SCALAR,
- CLASS_VECTOR,
- CLASS_MATRIX_ROWS,
- CLASS_MATRIX_COLUMNS,
- CLASS_OBJECT,
- CLASS_STRUCT,
- };
-
- enum RegisterSet
- {
- RS_BOOL,
- RS_INT4,
- RS_FLOAT4,
- RS_SAMPLER,
- };
-
- enum Type
- {
- PT_VOID,
- PT_BOOL,
- PT_INT,
- PT_FLOAT,
- PT_STRING,
- PT_TEXTURE,
- PT_TEXTURE1D,
- PT_TEXTURE2D,
- PT_TEXTURE3D,
- PT_TEXTURECUBE,
- PT_SAMPLER,
- PT_SAMPLER1D,
- PT_SAMPLER2D,
- PT_SAMPLER3D,
- PT_SAMPLERCUBE,
- PT_PIXELSHADER,
- PT_VERTEXSHADER,
- PT_PIXELFRAGMENT,
- PT_VERTEXFRAGMENT,
- PT_UNSUPPORTED,
- };
-
- D3DConstant(const char *base, const ctab::ConstantInfo *constantInfo);
- ~D3DConstant();
-
- std::string name;
- RegisterSet registerSet;
- unsigned registerIndex;
- unsigned registerCount;
- Class typeClass;
- Type type;
- unsigned rows;
- unsigned columns;
- unsigned elements;
-
- // Array of structure members.
- std::vector<std::vector<const D3DConstant*> > structMembers;
-
- private:
- D3DConstant(const char *base, RegisterSet registerSet, unsigned registerIndex, const ctab::StructMemberInfo *memberInfo);
- unsigned addStructMembers(const char *base, RegisterSet registerSet, unsigned registerIndex, const ctab::TypeInfo *typeInfo);
-};
-
-class D3DConstantTable
-{
- public:
- D3DConstantTable(void *blob, size_t size);
- ~D3DConstantTable();
-
- bool error() const { return mError; }
-
- unsigned constants() const { return mConstants.size(); }
- const D3DConstant *getConstant(unsigned index) const;
- const D3DConstant *getConstantByName(const char *name) const;
-
- private:
- DISALLOW_COPY_AND_ASSIGN(D3DConstantTable);
- std::vector<const D3DConstant*> mConstants;
- bool mError;
-};
-
-}
-
-#endif // LIBGLESV2_D3DCONSTANTTABLE_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/Fence.cpp b/src/3rdparty/angle/src/libGLESv2/Fence.cpp
index 14d1239abf..e4218bbeec 100644
--- a/src/3rdparty/angle/src/libGLESv2/Fence.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/Fence.cpp
@@ -1,5 +1,6 @@
+#include "precompiled.h"
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -7,126 +8,45 @@
// Fence.cpp: Implements the gl::Fence class, which supports the GL_NV_fence extension.
#include "libGLESv2/Fence.h"
-
-#include "libGLESv2/main.h"
+#include "libGLESv2/renderer/FenceImpl.h"
+#include "libGLESv2/renderer/Renderer.h"
namespace gl
{
-Fence::Fence(egl::Display* display)
+Fence::Fence(rx::Renderer *renderer)
{
- mDisplay = display;
- mQuery = NULL;
- mCondition = GL_NONE;
- mStatus = GL_FALSE;
+ mFence = renderer->createFence();
}
Fence::~Fence()
{
- if (mQuery != NULL)
- {
- mDisplay->freeEventQuery(mQuery);
- }
+ delete mFence;
}
GLboolean Fence::isFence()
{
- // GL_NV_fence spec:
- // A name returned by GenFencesNV, but not yet set via SetFenceNV, is not the name of an existing fence.
- return mQuery != NULL;
+ return mFence->isFence();
}
void Fence::setFence(GLenum condition)
{
- if (!mQuery)
- {
- mQuery = mDisplay->allocateEventQuery();
- if (!mQuery)
- {
- return error(GL_OUT_OF_MEMORY);
- }
- }
-
- HRESULT result = mQuery->Issue(D3DISSUE_END);
- ASSERT(SUCCEEDED(result));
-
- mCondition = condition;
- mStatus = GL_FALSE;
+ mFence->setFence(condition);
}
GLboolean Fence::testFence()
{
- if (mQuery == NULL)
- {
- return error(GL_INVALID_OPERATION, GL_TRUE);
- }
-
- HRESULT result = mQuery->GetData(NULL, 0, D3DGETDATA_FLUSH);
-
- if (checkDeviceLost(result))
- {
- return error(GL_OUT_OF_MEMORY, GL_TRUE);
- }
-
- ASSERT(result == S_OK || result == S_FALSE);
- mStatus = result == S_OK;
- return mStatus;
+ return mFence->testFence();
}
void Fence::finishFence()
{
- if (mQuery == NULL)
- {
- return error(GL_INVALID_OPERATION);
- }
-
- while (!testFence())
- {
- Sleep(0);
- }
+ mFence->finishFence();
}
void Fence::getFenceiv(GLenum pname, GLint *params)
{
- if (mQuery == NULL)
- {
- return error(GL_INVALID_OPERATION);
- }
-
- switch (pname)
- {
- case GL_FENCE_STATUS_NV:
- {
- // GL_NV_fence spec:
- // Once the status of a fence has been finished (via FinishFenceNV) or tested and the returned status is TRUE (via either TestFenceNV
- // or GetFenceivNV querying the FENCE_STATUS_NV), the status remains TRUE until the next SetFenceNV of the fence.
- if (mStatus)
- {
- params[0] = GL_TRUE;
- return;
- }
-
- HRESULT result = mQuery->GetData(NULL, 0, 0);
-
- if (checkDeviceLost(result))
- {
- params[0] = GL_TRUE;
- return error(GL_OUT_OF_MEMORY);
- }
-
- ASSERT(result == S_OK || result == S_FALSE);
- mStatus = result == S_OK;
- params[0] = mStatus;
-
- break;
- }
- case GL_FENCE_CONDITION_NV:
- params[0] = mCondition;
- break;
- default:
- return error(GL_INVALID_ENUM);
- break;
- }
+ mFence->getFenceiv(pname, params);
}
}
diff --git a/src/3rdparty/angle/src/libGLESv2/Fence.h b/src/3rdparty/angle/src/libGLESv2/Fence.h
index 9626cb0ff0..1cedebb112 100644
--- a/src/3rdparty/angle/src/libGLESv2/Fence.h
+++ b/src/3rdparty/angle/src/libGLESv2/Fence.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -9,15 +9,12 @@
#ifndef LIBGLESV2_FENCE_H_
#define LIBGLESV2_FENCE_H_
-#define GL_APICALL
-#include <GLES2/gl2.h>
-#include <d3d9.h>
-
#include "common/angleutils.h"
-namespace egl
+namespace rx
{
-class Display;
+class Renderer;
+class FenceImpl;
}
namespace gl
@@ -26,7 +23,7 @@ namespace gl
class Fence
{
public:
- explicit Fence(egl::Display* display);
+ explicit Fence(rx::Renderer *renderer);
virtual ~Fence();
GLboolean isFence();
@@ -38,10 +35,7 @@ class Fence
private:
DISALLOW_COPY_AND_ASSIGN(Fence);
- egl::Display* mDisplay;
- IDirect3DQuery9* mQuery;
- GLenum mCondition;
- GLboolean mStatus;
+ rx::FenceImpl *mFence;
};
}
diff --git a/src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.cpp b/src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.cpp
index 5bf7b3fce8..b90d2f6023 100644
--- a/src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.cpp
@@ -1,3 +1,4 @@
+#include "precompiled.h"
//
// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
diff --git a/src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.py b/src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.py
index ae646ffa12..cf039bfc21 100644
--- a/src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.py
+++ b/src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.py
@@ -56,22 +56,22 @@ namespace gl
print "const static unsigned g_mantissa[2048] = {"
for i in range(0, 2048):
- print " %08x," % convertMantissa(i)
+ print " %#010x," % convertMantissa(i)
print "};\n"
print "const static unsigned g_exponent[64] = {"
for i in range(0, 64):
- print " %08x," % convertExponent(i)
+ print " %#010x," % convertExponent(i)
print "};\n"
print "const static unsigned g_offset[64] = {"
for i in range(0, 64):
- print " %08x," % convertOffset(i)
+ print " %#010x," % convertOffset(i)
print "};\n"
print """float float16ToFloat32(unsigned short h)
{
- unsigned i32 = =g_mantissa[g_offset[h >> 10] + (h & 0x3ff)] + g_exponent[h >> 10];
+ unsigned i32 = g_mantissa[g_offset[h >> 10] + (h & 0x3ff)] + g_exponent[h >> 10];
return *(float*) &i32;
}
}
diff --git a/src/3rdparty/angle/src/libGLESv2/Framebuffer.cpp b/src/3rdparty/angle/src/libGLESv2/Framebuffer.cpp
index 77d79c0be2..42fee3bbad 100644
--- a/src/3rdparty/angle/src/libGLESv2/Framebuffer.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/Framebuffer.cpp
@@ -1,5 +1,6 @@
+#include "precompiled.h"
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -10,26 +11,38 @@
#include "libGLESv2/Framebuffer.h"
#include "libGLESv2/main.h"
-#include "libGLESv2/Renderbuffer.h"
-#include "libGLESv2/Texture.h"
#include "libGLESv2/utilities.h"
+#include "libGLESv2/Texture.h"
+#include "libGLESv2/Context.h"
+#include "libGLESv2/renderer/Renderer.h"
+#include "libGLESv2/Renderbuffer.h"
namespace gl
{
-Framebuffer::Framebuffer()
+Framebuffer::Framebuffer(rx::Renderer *renderer)
+ : mRenderer(renderer)
{
- mColorbufferType = GL_NONE;
+ for (unsigned int colorAttachment = 0; colorAttachment < IMPLEMENTATION_MAX_DRAW_BUFFERS; colorAttachment++)
+ {
+ mColorbufferTypes[colorAttachment] = GL_NONE;
+ mDrawBufferStates[colorAttachment] = GL_NONE;
+ }
+ mDrawBufferStates[0] = GL_COLOR_ATTACHMENT0_EXT;
+ mReadBufferState = GL_COLOR_ATTACHMENT0_EXT;
+
mDepthbufferType = GL_NONE;
mStencilbufferType = GL_NONE;
}
Framebuffer::~Framebuffer()
{
- mColorbufferPointer.set(NULL);
+ for (unsigned int colorAttachment = 0; colorAttachment < IMPLEMENTATION_MAX_DRAW_BUFFERS; colorAttachment++)
+ {
+ mColorbufferPointers[colorAttachment].set(NULL);
+ }
mDepthbufferPointer.set(NULL);
mStencilbufferPointer.set(NULL);
- mNullColorbufferPointer.set(NULL);
}
Renderbuffer *Framebuffer::lookupRenderbuffer(GLenum type, GLuint handle) const
@@ -57,10 +70,11 @@ Renderbuffer *Framebuffer::lookupRenderbuffer(GLenum type, GLuint handle) const
return buffer;
}
-void Framebuffer::setColorbuffer(GLenum type, GLuint colorbuffer)
+void Framebuffer::setColorbuffer(unsigned int colorAttachment, GLenum type, GLuint colorbuffer)
{
- mColorbufferType = (colorbuffer != 0) ? type : GL_NONE;
- mColorbufferPointer.set(lookupRenderbuffer(type, colorbuffer));
+ ASSERT(colorAttachment < IMPLEMENTATION_MAX_DRAW_BUFFERS);
+ mColorbufferTypes[colorAttachment] = (colorbuffer != 0) ? type : GL_NONE;
+ mColorbufferPointers[colorAttachment].set(lookupRenderbuffer(type, colorbuffer));
}
void Framebuffer::setDepthbuffer(GLenum type, GLuint depthbuffer)
@@ -77,10 +91,13 @@ void Framebuffer::setStencilbuffer(GLenum type, GLuint stencilbuffer)
void Framebuffer::detachTexture(GLuint texture)
{
- if (mColorbufferPointer.id() == texture && IsInternalTextureTarget(mColorbufferType))
+ for (unsigned int colorAttachment = 0; colorAttachment < IMPLEMENTATION_MAX_DRAW_BUFFERS; colorAttachment++)
{
- mColorbufferType = GL_NONE;
- mColorbufferPointer.set(NULL);
+ if (mColorbufferPointers[colorAttachment].id() == texture && IsInternalTextureTarget(mColorbufferTypes[colorAttachment]))
+ {
+ mColorbufferTypes[colorAttachment] = GL_NONE;
+ mColorbufferPointers[colorAttachment].set(NULL);
+ }
}
if (mDepthbufferPointer.id() == texture && IsInternalTextureTarget(mDepthbufferType))
@@ -98,10 +115,13 @@ void Framebuffer::detachTexture(GLuint texture)
void Framebuffer::detachRenderbuffer(GLuint renderbuffer)
{
- if (mColorbufferPointer.id() == renderbuffer && mColorbufferType == GL_RENDERBUFFER)
+ for (unsigned int colorAttachment = 0; colorAttachment < IMPLEMENTATION_MAX_DRAW_BUFFERS; colorAttachment++)
{
- mColorbufferType = GL_NONE;
- mColorbufferPointer.set(NULL);
+ if (mColorbufferPointers[colorAttachment].id() == renderbuffer && mColorbufferTypes[colorAttachment] == GL_RENDERBUFFER)
+ {
+ mColorbufferTypes[colorAttachment] = GL_NONE;
+ mColorbufferPointers[colorAttachment].set(NULL);
+ }
}
if (mDepthbufferPointer.id() == renderbuffer && mDepthbufferType == GL_RENDERBUFFER)
@@ -117,9 +137,11 @@ void Framebuffer::detachRenderbuffer(GLuint renderbuffer)
}
}
-unsigned int Framebuffer::getRenderTargetSerial()
+unsigned int Framebuffer::getRenderTargetSerial(unsigned int colorAttachment) const
{
- Renderbuffer *colorbuffer = mColorbufferPointer.get();
+ ASSERT(colorAttachment < IMPLEMENTATION_MAX_DRAW_BUFFERS);
+
+ Renderbuffer *colorbuffer = mColorbufferPointers[colorAttachment].get();
if (colorbuffer)
{
@@ -129,40 +151,7 @@ unsigned int Framebuffer::getRenderTargetSerial()
return 0;
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *Framebuffer::getRenderTarget()
-{
- Renderbuffer *colorbuffer = mColorbufferPointer.get();
-
- if (colorbuffer)
- {
- return colorbuffer->getRenderTarget();
- }
-
- return NULL;
-}
-
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *Framebuffer::getDepthStencil()
-{
- Renderbuffer *depthstencilbuffer = mDepthbufferPointer.get();
-
- if (!depthstencilbuffer)
- {
- depthstencilbuffer = mStencilbufferPointer.get();
- }
-
- if (depthstencilbuffer)
- {
- return depthstencilbuffer->getDepthStencil();
- }
-
- return NULL;
-}
-
-unsigned int Framebuffer::getDepthbufferSerial()
+unsigned int Framebuffer::getDepthbufferSerial() const
{
Renderbuffer *depthbuffer = mDepthbufferPointer.get();
@@ -174,7 +163,7 @@ unsigned int Framebuffer::getDepthbufferSerial()
return 0;
}
-unsigned int Framebuffer::getStencilbufferSerial()
+unsigned int Framebuffer::getStencilbufferSerial() const
{
Renderbuffer *stencilbuffer = mStencilbufferPointer.get();
@@ -186,80 +175,124 @@ unsigned int Framebuffer::getStencilbufferSerial()
return 0;
}
-Renderbuffer *Framebuffer::getColorbuffer()
+Renderbuffer *Framebuffer::getColorbuffer(unsigned int colorAttachment) const
{
- return mColorbufferPointer.get();
+ ASSERT(colorAttachment < IMPLEMENTATION_MAX_DRAW_BUFFERS);
+ return mColorbufferPointers[colorAttachment].get();
}
-Renderbuffer *Framebuffer::getDepthbuffer()
+Renderbuffer *Framebuffer::getDepthbuffer() const
{
return mDepthbufferPointer.get();
}
-Renderbuffer *Framebuffer::getStencilbuffer()
+Renderbuffer *Framebuffer::getStencilbuffer() const
{
return mStencilbufferPointer.get();
}
-Renderbuffer *Framebuffer::getNullColorbuffer()
+Renderbuffer *Framebuffer::getDepthOrStencilbuffer() const
{
- Renderbuffer *nullbuffer = mNullColorbufferPointer.get();
- Renderbuffer *depthbuffer = getDepthbuffer();
-
- if (!depthbuffer)
+ Renderbuffer *depthstencilbuffer = mDepthbufferPointer.get();
+
+ if (!depthstencilbuffer)
{
- ERR("Unexpected null depthbuffer for depth-only FBO.");
- return NULL;
+ depthstencilbuffer = mStencilbufferPointer.get();
}
- GLsizei width = depthbuffer->getWidth();
- GLsizei height = depthbuffer->getHeight();
+ return depthstencilbuffer;
+}
- if (!nullbuffer ||
- width != nullbuffer->getWidth() || height != nullbuffer->getHeight())
+Renderbuffer *Framebuffer::getReadColorbuffer() const
+{
+ // Will require more logic if glReadBuffers is supported
+ return mColorbufferPointers[0].get();
+}
+
+GLenum Framebuffer::getReadColorbufferType() const
+{
+ // Will require more logic if glReadBuffers is supported
+ return mColorbufferTypes[0];
+}
+
+Renderbuffer *Framebuffer::getFirstColorbuffer() const
+{
+ for (unsigned int colorAttachment = 0; colorAttachment < IMPLEMENTATION_MAX_DRAW_BUFFERS; colorAttachment++)
{
- nullbuffer = new Renderbuffer(0, new Colorbuffer(width, height, GL_NONE, 0));
- mNullColorbufferPointer.set(nullbuffer);
+ if (mColorbufferTypes[colorAttachment] != GL_NONE)
+ {
+ return mColorbufferPointers[colorAttachment].get();
+ }
}
- return nullbuffer;
+ return NULL;
}
-GLenum Framebuffer::getColorbufferType()
+GLenum Framebuffer::getColorbufferType(unsigned int colorAttachment) const
{
- return mColorbufferType;
+ ASSERT(colorAttachment < IMPLEMENTATION_MAX_DRAW_BUFFERS);
+ return mColorbufferTypes[colorAttachment];
}
-GLenum Framebuffer::getDepthbufferType()
+GLenum Framebuffer::getDepthbufferType() const
{
return mDepthbufferType;
}
-GLenum Framebuffer::getStencilbufferType()
+GLenum Framebuffer::getStencilbufferType() const
{
return mStencilbufferType;
}
-GLuint Framebuffer::getColorbufferHandle()
+GLuint Framebuffer::getColorbufferHandle(unsigned int colorAttachment) const
{
- return mColorbufferPointer.id();
+ ASSERT(colorAttachment < IMPLEMENTATION_MAX_DRAW_BUFFERS);
+ return mColorbufferPointers[colorAttachment].id();
}
-GLuint Framebuffer::getDepthbufferHandle()
+GLuint Framebuffer::getDepthbufferHandle() const
{
return mDepthbufferPointer.id();
}
-GLuint Framebuffer::getStencilbufferHandle()
+GLuint Framebuffer::getStencilbufferHandle() const
{
return mStencilbufferPointer.id();
}
-bool Framebuffer::hasStencil()
+GLenum Framebuffer::getDrawBufferState(unsigned int colorAttachment) const
+{
+ return mDrawBufferStates[colorAttachment];
+}
+
+void Framebuffer::setDrawBufferState(unsigned int colorAttachment, GLenum drawBuffer)
+{
+ mDrawBufferStates[colorAttachment] = drawBuffer;
+}
+
+bool Framebuffer::isEnabledColorAttachment(unsigned int colorAttachment) const
+{
+ return (mColorbufferTypes[colorAttachment] != GL_NONE && mDrawBufferStates[colorAttachment] != GL_NONE);
+}
+
+bool Framebuffer::hasEnabledColorAttachment() const
+{
+ for (unsigned int colorAttachment = 0; colorAttachment < gl::IMPLEMENTATION_MAX_DRAW_BUFFERS; colorAttachment++)
+ {
+ if (isEnabledColorAttachment(colorAttachment))
+ {
+ return true;
+ }
+ }
+
+ return false;
+}
+
+bool Framebuffer::hasStencil() const
{
if (mStencilbufferType != GL_NONE)
{
- Renderbuffer *stencilbufferObject = getStencilbuffer();
+ const Renderbuffer *stencilbufferObject = getStencilbuffer();
if (stencilbufferObject)
{
@@ -270,73 +303,112 @@ bool Framebuffer::hasStencil()
return false;
}
-GLenum Framebuffer::completeness()
+GLenum Framebuffer::completeness() const
{
- gl::Context *context = gl::getContext();
int width = 0;
int height = 0;
+ int colorbufferSize = 0;
int samples = -1;
bool missingAttachment = true;
- if (mColorbufferType != GL_NONE)
+ for (unsigned int colorAttachment = 0; colorAttachment < IMPLEMENTATION_MAX_DRAW_BUFFERS; colorAttachment++)
{
- Renderbuffer *colorbuffer = getColorbuffer();
-
- if (!colorbuffer)
+ if (mColorbufferTypes[colorAttachment] != GL_NONE)
{
- return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
- }
+ const Renderbuffer *colorbuffer = getColorbuffer(colorAttachment);
- if (colorbuffer->getWidth() == 0 || colorbuffer->getHeight() == 0)
- {
- return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
- }
-
- if (mColorbufferType == GL_RENDERBUFFER)
- {
- if (!gl::IsColorRenderable(colorbuffer->getInternalFormat()))
+ if (!colorbuffer)
{
return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
}
- }
- else if (IsInternalTextureTarget(mColorbufferType))
- {
- GLint internalformat = colorbuffer->getInternalFormat();
- GLenum format = gl::ExtractFormat(internalformat);
- if (IsCompressed(format) ||
- format == GL_ALPHA ||
- format == GL_LUMINANCE ||
- format == GL_LUMINANCE_ALPHA)
+ if (colorbuffer->getWidth() == 0 || colorbuffer->getHeight() == 0)
{
- return GL_FRAMEBUFFER_UNSUPPORTED;
+ return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
}
- if ((gl::IsFloat32Format(internalformat) && !context->supportsFloat32RenderableTextures()) ||
- (gl::IsFloat16Format(internalformat) && !context->supportsFloat16RenderableTextures()))
+ if (mColorbufferTypes[colorAttachment] == GL_RENDERBUFFER)
{
- return GL_FRAMEBUFFER_UNSUPPORTED;
+ if (!gl::IsColorRenderable(colorbuffer->getInternalFormat()))
+ {
+ return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
+ }
}
-
- if (gl::IsDepthTexture(internalformat) || gl::IsStencilTexture(internalformat))
+ else if (IsInternalTextureTarget(mColorbufferTypes[colorAttachment]))
{
+ GLint internalformat = colorbuffer->getInternalFormat();
+ GLenum format = gl::ExtractFormat(internalformat);
+
+ if (IsCompressed(format) ||
+ format == GL_ALPHA ||
+ format == GL_LUMINANCE ||
+ format == GL_LUMINANCE_ALPHA)
+ {
+ return GL_FRAMEBUFFER_UNSUPPORTED;
+ }
+
+ bool filtering, renderable;
+
+ if ((gl::IsFloat32Format(internalformat) && !mRenderer->getFloat32TextureSupport(&filtering, &renderable)) ||
+ (gl::IsFloat16Format(internalformat) && !mRenderer->getFloat16TextureSupport(&filtering, &renderable)))
+ {
+ return GL_FRAMEBUFFER_UNSUPPORTED;
+ }
+
+ if (gl::IsDepthTexture(internalformat) || gl::IsStencilTexture(internalformat))
+ {
+ return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
+ }
+ }
+ else
+ {
+ UNREACHABLE();
return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
}
- }
- else
- {
- UNREACHABLE();
- return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
- }
- width = colorbuffer->getWidth();
- height = colorbuffer->getHeight();
- samples = colorbuffer->getSamples();
- missingAttachment = false;
+ if (!missingAttachment)
+ {
+ // all color attachments must have the same width and height
+ if (colorbuffer->getWidth() != width || colorbuffer->getHeight() != height)
+ {
+ return GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS;
+ }
+
+ // APPLE_framebuffer_multisample, which EXT_draw_buffers refers to, requires that
+ // all color attachments have the same number of samples for the FBO to be complete.
+ if (colorbuffer->getSamples() != samples)
+ {
+ return GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT;
+ }
+
+ // all color attachments attachments must have the same number of bitplanes
+ if (gl::ComputePixelSize(colorbuffer->getInternalFormat()) != colorbufferSize)
+ {
+ return GL_FRAMEBUFFER_UNSUPPORTED;
+ }
+
+ // D3D11 does not allow for overlapping RenderTargetViews, so ensure uniqueness
+ for (unsigned int previousColorAttachment = 0; previousColorAttachment < colorAttachment; previousColorAttachment++)
+ {
+ if (mColorbufferPointers[colorAttachment].get() == mColorbufferPointers[previousColorAttachment].get())
+ {
+ return GL_FRAMEBUFFER_UNSUPPORTED;
+ }
+ }
+ }
+ else
+ {
+ width = colorbuffer->getWidth();
+ height = colorbuffer->getHeight();
+ samples = colorbuffer->getSamples();
+ colorbufferSize = gl::ComputePixelSize(colorbuffer->getInternalFormat());
+ missingAttachment = false;
+ }
+ }
}
- Renderbuffer *depthbuffer = NULL;
- Renderbuffer *stencilbuffer = NULL;
+ const Renderbuffer *depthbuffer = NULL;
+ const Renderbuffer *stencilbuffer = NULL;
if (mDepthbufferType != GL_NONE)
{
@@ -364,7 +436,7 @@ GLenum Framebuffer::completeness()
GLint internalformat = depthbuffer->getInternalFormat();
// depth texture attachments require OES/ANGLE_depth_texture
- if (!context->supportsDepthTextures())
+ if (!mRenderer->getDepthTextureSupport())
{
return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
}
@@ -424,7 +496,7 @@ GLenum Framebuffer::completeness()
// texture stencil attachments come along as part
// of OES_packed_depth_stencil + OES/ANGLE_depth_texture
- if (!context->supportsDepthTextures())
+ if (!mRenderer->getDepthTextureSupport())
{
return GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT;
}
@@ -473,36 +545,45 @@ GLenum Framebuffer::completeness()
return GL_FRAMEBUFFER_COMPLETE;
}
-DefaultFramebuffer::DefaultFramebuffer(Colorbuffer *colorbuffer, DepthStencilbuffer *depthStencil)
+DefaultFramebuffer::DefaultFramebuffer(rx::Renderer *renderer, Colorbuffer *colorbuffer, DepthStencilbuffer *depthStencil)
+ : Framebuffer(renderer)
{
- mColorbufferPointer.set(new Renderbuffer(0, colorbuffer));
+ mColorbufferPointers[0].set(new Renderbuffer(mRenderer, 0, colorbuffer));
- Renderbuffer *depthStencilRenderbuffer = new Renderbuffer(0, depthStencil);
+ Renderbuffer *depthStencilRenderbuffer = new Renderbuffer(mRenderer, 0, depthStencil);
mDepthbufferPointer.set(depthStencilRenderbuffer);
mStencilbufferPointer.set(depthStencilRenderbuffer);
- mColorbufferType = GL_RENDERBUFFER;
+ mColorbufferTypes[0] = GL_RENDERBUFFER;
mDepthbufferType = (depthStencilRenderbuffer->getDepthSize() != 0) ? GL_RENDERBUFFER : GL_NONE;
mStencilbufferType = (depthStencilRenderbuffer->getStencilSize() != 0) ? GL_RENDERBUFFER : GL_NONE;
+
+ mDrawBufferStates[0] = GL_BACK;
+ mReadBufferState = GL_BACK;
}
-int Framebuffer::getSamples()
+int Framebuffer::getSamples() const
{
if (completeness() == GL_FRAMEBUFFER_COMPLETE)
{
- return getColorbuffer()->getSamples();
- }
- else
- {
- return 0;
+ // for a complete framebuffer, all attachments must have the same sample count
+ // in this case return the first nonzero sample size
+ for (unsigned int colorAttachment = 0; colorAttachment < IMPLEMENTATION_MAX_DRAW_BUFFERS; colorAttachment++)
+ {
+ if (mColorbufferTypes[colorAttachment] != GL_NONE)
+ {
+ return getColorbuffer(colorAttachment)->getSamples();
+ }
+ }
}
+
+ return 0;
}
-GLenum DefaultFramebuffer::completeness()
+GLenum DefaultFramebuffer::completeness() const
{
- // The default framebuffer should always be complete
- ASSERT(Framebuffer::completeness() == GL_FRAMEBUFFER_COMPLETE);
-
+ // The default framebuffer *must* always be complete, though it may not be
+ // subject to the same rules as application FBOs. ie, it could have 0x0 size.
return GL_FRAMEBUFFER_COMPLETE;
}
diff --git a/src/3rdparty/angle/src/libGLESv2/Framebuffer.h b/src/3rdparty/angle/src/libGLESv2/Framebuffer.h
index 14d9c2a74c..66acdc4c37 100644
--- a/src/3rdparty/angle/src/libGLESv2/Framebuffer.h
+++ b/src/3rdparty/angle/src/libGLESv2/Framebuffer.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -10,12 +10,14 @@
#ifndef LIBGLESV2_FRAMEBUFFER_H_
#define LIBGLESV2_FRAMEBUFFER_H_
-#define GL_APICALL
-#include <GLES2/gl2.h>
-#include <d3d9.h>
-
#include "common/angleutils.h"
#include "common/RefCountObject.h"
+#include "constants.h"
+
+namespace rx
+{
+class Renderer;
+}
namespace gl
{
@@ -28,45 +30,52 @@ class DepthStencilbuffer;
class Framebuffer
{
public:
- Framebuffer();
+ explicit Framebuffer(rx::Renderer *renderer);
virtual ~Framebuffer();
- void setColorbuffer(GLenum type, GLuint colorbuffer);
+ void setColorbuffer(unsigned int colorAttachment, GLenum type, GLuint colorbuffer);
void setDepthbuffer(GLenum type, GLuint depthbuffer);
void setStencilbuffer(GLenum type, GLuint stencilbuffer);
void detachTexture(GLuint texture);
void detachRenderbuffer(GLuint renderbuffer);
- IDirect3DSurface9 *getRenderTarget();
- IDirect3DSurface9 *getDepthStencil();
+ unsigned int getRenderTargetSerial(unsigned int colorAttachment) const;
+ unsigned int getDepthbufferSerial() const;
+ unsigned int getStencilbufferSerial() const;
- unsigned int getRenderTargetSerial();
- unsigned int getDepthbufferSerial();
- unsigned int getStencilbufferSerial();
+ Renderbuffer *getColorbuffer(unsigned int colorAttachment) const;
+ Renderbuffer *getDepthbuffer() const;
+ Renderbuffer *getStencilbuffer() const;
+ Renderbuffer *getDepthOrStencilbuffer() const;
+ Renderbuffer *getReadColorbuffer() const;
+ GLenum getReadColorbufferType() const;
+ Renderbuffer *getFirstColorbuffer() const;
- Renderbuffer *getColorbuffer();
- Renderbuffer *getDepthbuffer();
- Renderbuffer *getStencilbuffer();
- Renderbuffer *getNullColorbuffer();
+ GLenum getColorbufferType(unsigned int colorAttachment) const;
+ GLenum getDepthbufferType() const;
+ GLenum getStencilbufferType() const;
- GLenum getColorbufferType();
- GLenum getDepthbufferType();
- GLenum getStencilbufferType();
+ GLuint getColorbufferHandle(unsigned int colorAttachment) const;
+ GLuint getDepthbufferHandle() const;
+ GLuint getStencilbufferHandle() const;
- GLuint getColorbufferHandle();
- GLuint getDepthbufferHandle();
- GLuint getStencilbufferHandle();
+ GLenum getDrawBufferState(unsigned int colorAttachment) const;
+ void setDrawBufferState(unsigned int colorAttachment, GLenum drawBuffer);
- bool hasStencil();
- int getSamples();
+ bool isEnabledColorAttachment(unsigned int colorAttachment) const;
+ bool hasEnabledColorAttachment() const;
+ bool hasStencil() const;
+ int getSamples() const;
- virtual GLenum completeness();
+ virtual GLenum completeness() const;
protected:
- GLenum mColorbufferType;
- BindingPointer<Renderbuffer> mColorbufferPointer;
+ GLenum mColorbufferTypes[IMPLEMENTATION_MAX_DRAW_BUFFERS];
+ BindingPointer<Renderbuffer> mColorbufferPointers[IMPLEMENTATION_MAX_DRAW_BUFFERS];
+ GLenum mDrawBufferStates[IMPLEMENTATION_MAX_DRAW_BUFFERS];
+ GLenum mReadBufferState;
GLenum mDepthbufferType;
BindingPointer<Renderbuffer> mDepthbufferPointer;
@@ -74,7 +83,7 @@ class Framebuffer
GLenum mStencilbufferType;
BindingPointer<Renderbuffer> mStencilbufferPointer;
- BindingPointer<Renderbuffer> mNullColorbufferPointer;
+ rx::Renderer *mRenderer;
private:
DISALLOW_COPY_AND_ASSIGN(Framebuffer);
@@ -85,9 +94,9 @@ class Framebuffer
class DefaultFramebuffer : public Framebuffer
{
public:
- DefaultFramebuffer(Colorbuffer *colorbuffer, DepthStencilbuffer *depthStencil);
+ DefaultFramebuffer(rx::Renderer *Renderer, Colorbuffer *colorbuffer, DepthStencilbuffer *depthStencil);
- virtual GLenum completeness();
+ virtual GLenum completeness() const;
private:
DISALLOW_COPY_AND_ASSIGN(DefaultFramebuffer);
diff --git a/src/3rdparty/angle/src/libGLESv2/HandleAllocator.cpp b/src/3rdparty/angle/src/libGLESv2/HandleAllocator.cpp
index c498f8a178..37da99aa18 100644
--- a/src/3rdparty/angle/src/libGLESv2/HandleAllocator.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/HandleAllocator.cpp
@@ -1,3 +1,4 @@
+#include "precompiled.h"
//
// Copyright (c) 2002-2011 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
diff --git a/src/3rdparty/angle/src/libGLESv2/IndexDataManager.cpp b/src/3rdparty/angle/src/libGLESv2/IndexDataManager.cpp
deleted file mode 100644
index 3dc0aef3f1..0000000000
--- a/src/3rdparty/angle/src/libGLESv2/IndexDataManager.cpp
+++ /dev/null
@@ -1,473 +0,0 @@
-//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-//
-
-// IndexDataManager.cpp: Defines the IndexDataManager, a class that
-// runs the Buffer translation process for index buffers.
-
-#include "libGLESv2/IndexDataManager.h"
-
-#include "common/debug.h"
-
-#include "libGLESv2/Buffer.h"
-#include "libGLESv2/mathutil.h"
-#include "libGLESv2/main.h"
-
-namespace gl
-{
-unsigned int IndexBuffer::mCurrentSerial = 1;
-
-IndexDataManager::IndexDataManager(Context *context, IDirect3DDevice9 *device) : mDevice(device)
-{
- mStreamingBufferShort = new StreamingIndexBuffer(mDevice, INITIAL_INDEX_BUFFER_SIZE, D3DFMT_INDEX16);
-
- if (context->supports32bitIndices())
- {
- mStreamingBufferInt = new StreamingIndexBuffer(mDevice, INITIAL_INDEX_BUFFER_SIZE, D3DFMT_INDEX32);
-
- if (!mStreamingBufferInt)
- {
- // Don't leave it in a half-initialized state
- delete mStreamingBufferShort;
- mStreamingBufferShort = NULL;
- }
- }
- else
- {
- mStreamingBufferInt = NULL;
- }
-
- if (!mStreamingBufferShort)
- {
- ERR("Failed to allocate the streaming index buffer(s).");
- }
-
- mCountingBuffer = NULL;
-}
-
-IndexDataManager::~IndexDataManager()
-{
- delete mStreamingBufferShort;
- delete mStreamingBufferInt;
- delete mCountingBuffer;
-}
-
-void convertIndices(GLenum type, const void *input, GLsizei count, void *output)
-{
- if (type == GL_UNSIGNED_BYTE)
- {
- const GLubyte *in = static_cast<const GLubyte*>(input);
- GLushort *out = static_cast<GLushort*>(output);
-
- for (GLsizei i = 0; i < count; i++)
- {
- out[i] = in[i];
- }
- }
- else if (type == GL_UNSIGNED_INT)
- {
- memcpy(output, input, count * sizeof(GLuint));
- }
- else if (type == GL_UNSIGNED_SHORT)
- {
- memcpy(output, input, count * sizeof(GLushort));
- }
- else UNREACHABLE();
-}
-
-template <class IndexType>
-void computeRange(const IndexType *indices, GLsizei count, GLuint *minIndex, GLuint *maxIndex)
-{
- *minIndex = indices[0];
- *maxIndex = indices[0];
-
- for (GLsizei i = 0; i < count; i++)
- {
- if (*minIndex > indices[i]) *minIndex = indices[i];
- if (*maxIndex < indices[i]) *maxIndex = indices[i];
- }
-}
-
-void computeRange(GLenum type, const GLvoid *indices, GLsizei count, GLuint *minIndex, GLuint *maxIndex)
-{
- if (type == GL_UNSIGNED_BYTE)
- {
- computeRange(static_cast<const GLubyte*>(indices), count, minIndex, maxIndex);
- }
- else if (type == GL_UNSIGNED_INT)
- {
- computeRange(static_cast<const GLuint*>(indices), count, minIndex, maxIndex);
- }
- else if (type == GL_UNSIGNED_SHORT)
- {
- computeRange(static_cast<const GLushort*>(indices), count, minIndex, maxIndex);
- }
- else UNREACHABLE();
-}
-
-GLenum IndexDataManager::prepareIndexData(GLenum type, GLsizei count, Buffer *buffer, const GLvoid *indices, TranslatedIndexData *translated)
-{
- if (!mStreamingBufferShort)
- {
- return GL_OUT_OF_MEMORY;
- }
-
- D3DFORMAT format = (type == GL_UNSIGNED_INT) ? D3DFMT_INDEX32 : D3DFMT_INDEX16;
- intptr_t offset = reinterpret_cast<intptr_t>(indices);
- bool alignedOffset = false;
-
- if (buffer != NULL)
- {
- switch (type)
- {
- case GL_UNSIGNED_BYTE: alignedOffset = (offset % sizeof(GLubyte) == 0); break;
- case GL_UNSIGNED_SHORT: alignedOffset = (offset % sizeof(GLushort) == 0); break;
- case GL_UNSIGNED_INT: alignedOffset = (offset % sizeof(GLuint) == 0); break;
- default: UNREACHABLE(); alignedOffset = false;
- }
-
- if (typeSize(type) * count + offset > static_cast<std::size_t>(buffer->size()))
- {
- return GL_INVALID_OPERATION;
- }
-
- indices = static_cast<const GLubyte*>(buffer->data()) + offset;
- }
-
- StreamingIndexBuffer *streamingBuffer = (type == GL_UNSIGNED_INT) ? mStreamingBufferInt : mStreamingBufferShort;
-
- StaticIndexBuffer *staticBuffer = buffer ? buffer->getStaticIndexBuffer() : NULL;
- IndexBuffer *indexBuffer = streamingBuffer;
- UINT streamOffset = 0;
-
- if (staticBuffer && staticBuffer->lookupType(type) && alignedOffset)
- {
- indexBuffer = staticBuffer;
- streamOffset = staticBuffer->lookupRange(offset, count, &translated->minIndex, &translated->maxIndex);
-
- if (streamOffset == -1)
- {
- streamOffset = (offset / typeSize(type)) * indexSize(format);
- computeRange(type, indices, count, &translated->minIndex, &translated->maxIndex);
- staticBuffer->addRange(offset, count, translated->minIndex, translated->maxIndex, streamOffset);
- }
- }
- else
- {
- int convertCount = count;
-
- if (staticBuffer)
- {
- if (staticBuffer->size() == 0 && alignedOffset)
- {
- indexBuffer = staticBuffer;
- convertCount = buffer->size() / typeSize(type);
- }
- else
- {
- buffer->invalidateStaticData();
- staticBuffer = NULL;
- }
- }
-
- void *output = NULL;
-
- if (indexBuffer)
- {
- indexBuffer->reserveSpace(convertCount * indexSize(format), type);
- output = indexBuffer->map(indexSize(format) * convertCount, &streamOffset);
- }
-
- if (output == NULL)
- {
- ERR("Failed to map index buffer.");
- return GL_OUT_OF_MEMORY;
- }
-
- convertIndices(type, staticBuffer ? buffer->data() : indices, convertCount, output);
- indexBuffer->unmap();
-
- computeRange(type, indices, count, &translated->minIndex, &translated->maxIndex);
-
- if (staticBuffer)
- {
- streamOffset = (offset / typeSize(type)) * indexSize(format);
- staticBuffer->addRange(offset, count, translated->minIndex, translated->maxIndex, streamOffset);
- }
- }
-
- translated->indexBuffer = indexBuffer->getBuffer();
- translated->serial = indexBuffer->getSerial();
- translated->startIndex = streamOffset / indexSize(format);
-
- if (buffer)
- {
- buffer->promoteStaticUsage(count * typeSize(type));
- }
-
- return GL_NO_ERROR;
-}
-
-std::size_t IndexDataManager::indexSize(D3DFORMAT format) const
-{
- return (format == D3DFMT_INDEX32) ? sizeof(unsigned int) : sizeof(unsigned short);
-}
-
-std::size_t IndexDataManager::typeSize(GLenum type) const
-{
- switch (type)
- {
- case GL_UNSIGNED_INT: return sizeof(GLuint);
- case GL_UNSIGNED_SHORT: return sizeof(GLushort);
- case GL_UNSIGNED_BYTE: return sizeof(GLubyte);
- default: UNREACHABLE(); return sizeof(GLushort);
- }
-}
-
-StaticIndexBuffer *IndexDataManager::getCountingIndices(GLsizei count)
-{
- if (count <= 65536) // 16-bit indices
- {
- const unsigned int spaceNeeded = count * sizeof(unsigned short);
-
- if (!mCountingBuffer || mCountingBuffer->size() < spaceNeeded)
- {
- delete mCountingBuffer;
- mCountingBuffer = new StaticIndexBuffer(mDevice);
- mCountingBuffer->reserveSpace(spaceNeeded, GL_UNSIGNED_SHORT);
-
- UINT offset;
- unsigned short *data = static_cast<unsigned short*>(mCountingBuffer->map(spaceNeeded, &offset));
-
- if (data)
- {
- for(int i = 0; i < count; i++)
- {
- data[i] = i;
- }
-
- mCountingBuffer->unmap();
- }
- }
- }
- else if (mStreamingBufferInt) // 32-bit indices supported
- {
- const unsigned int spaceNeeded = count * sizeof(unsigned int);
-
- if (!mCountingBuffer || mCountingBuffer->size() < spaceNeeded)
- {
- delete mCountingBuffer;
- mCountingBuffer = new StaticIndexBuffer(mDevice);
- mCountingBuffer->reserveSpace(spaceNeeded, GL_UNSIGNED_INT);
-
- UINT offset;
- unsigned int *data = static_cast<unsigned int*>(mCountingBuffer->map(spaceNeeded, &offset));
-
- if (data)
- {
- for(int i = 0; i < count; i++)
- {
- data[i] = i;
- }
-
- mCountingBuffer->unmap();
- }
- }
- }
- else return NULL;
-
- return mCountingBuffer;
-}
-
-IndexBuffer::IndexBuffer(IDirect3DDevice9 *device, UINT size, D3DFORMAT format) : mDevice(device), mBufferSize(size), mIndexBuffer(NULL)
-{
- if (size > 0)
- {
- D3DPOOL pool = getDisplay()->getBufferPool(D3DUSAGE_DYNAMIC | D3DUSAGE_WRITEONLY);
- HRESULT result = device->CreateIndexBuffer(size, D3DUSAGE_DYNAMIC | D3DUSAGE_WRITEONLY, format, pool, &mIndexBuffer, NULL);
- mSerial = issueSerial();
-
- if (FAILED(result))
- {
- ERR("Out of memory allocating an index buffer of size %lu.", size);
- }
- }
-}
-
-IndexBuffer::~IndexBuffer()
-{
- if (mIndexBuffer)
- {
- mIndexBuffer->Release();
- }
-}
-
-IDirect3DIndexBuffer9 *IndexBuffer::getBuffer() const
-{
- return mIndexBuffer;
-}
-
-unsigned int IndexBuffer::getSerial() const
-{
- return mSerial;
-}
-
-unsigned int IndexBuffer::issueSerial()
-{
- return mCurrentSerial++;
-}
-
-void IndexBuffer::unmap()
-{
- if (mIndexBuffer)
- {
- mIndexBuffer->Unlock();
- }
-}
-
-StreamingIndexBuffer::StreamingIndexBuffer(IDirect3DDevice9 *device, UINT initialSize, D3DFORMAT format) : IndexBuffer(device, initialSize, format)
-{
- mWritePosition = 0;
-}
-
-StreamingIndexBuffer::~StreamingIndexBuffer()
-{
-}
-
-void *StreamingIndexBuffer::map(UINT requiredSpace, UINT *offset)
-{
- void *mapPtr = NULL;
-
- if (mIndexBuffer)
- {
- HRESULT result = mIndexBuffer->Lock(mWritePosition, requiredSpace, &mapPtr, D3DLOCK_NOOVERWRITE);
-
- if (FAILED(result))
- {
- ERR(" Lock failed with error 0x%08x", result);
- return NULL;
- }
-
- *offset = mWritePosition;
- mWritePosition += requiredSpace;
- }
-
- return mapPtr;
-}
-
-void StreamingIndexBuffer::reserveSpace(UINT requiredSpace, GLenum type)
-{
- if (requiredSpace > mBufferSize)
- {
- if (mIndexBuffer)
- {
- mIndexBuffer->Release();
- mIndexBuffer = NULL;
- }
-
- mBufferSize = std::max(requiredSpace, 2 * mBufferSize);
-
- D3DPOOL pool = getDisplay()->getBufferPool(D3DUSAGE_DYNAMIC | D3DUSAGE_WRITEONLY);
- HRESULT result = mDevice->CreateIndexBuffer(mBufferSize, D3DUSAGE_DYNAMIC | D3DUSAGE_WRITEONLY, type == GL_UNSIGNED_INT ? D3DFMT_INDEX32 : D3DFMT_INDEX16, pool, &mIndexBuffer, NULL);
- mSerial = issueSerial();
-
- if (FAILED(result))
- {
- ERR("Out of memory allocating a vertex buffer of size %lu.", mBufferSize);
- }
-
- mWritePosition = 0;
- }
- else if (mWritePosition + requiredSpace > mBufferSize) // Recycle
- {
- void *dummy;
- mIndexBuffer->Lock(0, 1, &dummy, D3DLOCK_DISCARD);
- mIndexBuffer->Unlock();
-
- mWritePosition = 0;
- }
-}
-
-StaticIndexBuffer::StaticIndexBuffer(IDirect3DDevice9 *device) : IndexBuffer(device, 0, D3DFMT_UNKNOWN)
-{
- mCacheType = GL_NONE;
-}
-
-StaticIndexBuffer::~StaticIndexBuffer()
-{
-}
-
-void *StaticIndexBuffer::map(UINT requiredSpace, UINT *offset)
-{
- void *mapPtr = NULL;
-
- if (mIndexBuffer)
- {
- HRESULT result = mIndexBuffer->Lock(0, requiredSpace, &mapPtr, 0);
-
- if (FAILED(result))
- {
- ERR(" Lock failed with error 0x%08x", result);
- return NULL;
- }
-
- *offset = 0;
- }
-
- return mapPtr;
-}
-
-void StaticIndexBuffer::reserveSpace(UINT requiredSpace, GLenum type)
-{
- if (!mIndexBuffer && mBufferSize == 0)
- {
- D3DPOOL pool = getDisplay()->getBufferPool(D3DUSAGE_WRITEONLY);
- HRESULT result = mDevice->CreateIndexBuffer(requiredSpace, D3DUSAGE_WRITEONLY, type == GL_UNSIGNED_INT ? D3DFMT_INDEX32 : D3DFMT_INDEX16, pool, &mIndexBuffer, NULL);
- mSerial = issueSerial();
-
- if (FAILED(result))
- {
- ERR("Out of memory allocating a vertex buffer of size %lu.", mBufferSize);
- }
-
- mBufferSize = requiredSpace;
- mCacheType = type;
- }
- else if (mIndexBuffer && mBufferSize >= requiredSpace && mCacheType == type)
- {
- // Already allocated
- }
- else UNREACHABLE(); // Static index buffers can't be resized
-}
-
-bool StaticIndexBuffer::lookupType(GLenum type)
-{
- return mCacheType == type;
-}
-
-UINT StaticIndexBuffer::lookupRange(intptr_t offset, GLsizei count, UINT *minIndex, UINT *maxIndex)
-{
- IndexRange range = {offset, count};
-
- std::map<IndexRange, IndexResult>::iterator res = mCache.find(range);
-
- if (res == mCache.end())
- {
- return -1;
- }
-
- *minIndex = res->second.minIndex;
- *maxIndex = res->second.maxIndex;
- return res->second.streamOffset;
-}
-
-void StaticIndexBuffer::addRange(intptr_t offset, GLsizei count, UINT minIndex, UINT maxIndex, UINT streamOffset)
-{
- IndexRange indexRange = {offset, count};
- IndexResult indexResult = {minIndex, maxIndex, streamOffset};
- mCache[indexRange] = indexResult;
-}
-
-}
diff --git a/src/3rdparty/angle/src/libGLESv2/IndexDataManager.h b/src/3rdparty/angle/src/libGLESv2/IndexDataManager.h
deleted file mode 100644
index c1d4168315..0000000000
--- a/src/3rdparty/angle/src/libGLESv2/IndexDataManager.h
+++ /dev/null
@@ -1,149 +0,0 @@
-//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-//
-
-// IndexDataManager.h: Defines the IndexDataManager, a class that
-// runs the Buffer translation process for index buffers.
-
-#ifndef LIBGLESV2_INDEXDATAMANAGER_H_
-#define LIBGLESV2_INDEXDATAMANAGER_H_
-
-#include <vector>
-#include <cstddef>
-
-#define GL_APICALL
-#include <GLES2/gl2.h>
-
-#include "libGLESv2/Context.h"
-
-namespace
-{
- enum { INITIAL_INDEX_BUFFER_SIZE = 4096 * sizeof(GLuint) };
-}
-
-namespace gl
-{
-
-struct TranslatedIndexData
-{
- UINT minIndex;
- UINT maxIndex;
- UINT startIndex;
-
- IDirect3DIndexBuffer9 *indexBuffer;
- unsigned int serial;
-};
-
-class IndexBuffer
-{
- public:
- IndexBuffer(IDirect3DDevice9 *device, UINT size, D3DFORMAT format);
- virtual ~IndexBuffer();
-
- UINT size() const { return mBufferSize; }
- virtual void *map(UINT requiredSpace, UINT *offset) = 0;
- void unmap();
- virtual void reserveSpace(UINT requiredSpace, GLenum type) = 0;
-
- IDirect3DIndexBuffer9 *getBuffer() const;
- unsigned int getSerial() const;
-
- protected:
- IDirect3DDevice9 *const mDevice;
-
- IDirect3DIndexBuffer9 *mIndexBuffer;
- UINT mBufferSize;
-
- unsigned int mSerial;
- static unsigned int issueSerial();
- static unsigned int mCurrentSerial;
-
- private:
- DISALLOW_COPY_AND_ASSIGN(IndexBuffer);
-};
-
-class StreamingIndexBuffer : public IndexBuffer
-{
- public:
- StreamingIndexBuffer(IDirect3DDevice9 *device, UINT initialSize, D3DFORMAT format);
- ~StreamingIndexBuffer();
-
- virtual void *map(UINT requiredSpace, UINT *offset);
- virtual void reserveSpace(UINT requiredSpace, GLenum type);
-
- private:
- UINT mWritePosition;
-};
-
-class StaticIndexBuffer : public IndexBuffer
-{
- public:
- explicit StaticIndexBuffer(IDirect3DDevice9 *device);
- ~StaticIndexBuffer();
-
- virtual void *map(UINT requiredSpace, UINT *offset);
- virtual void reserveSpace(UINT requiredSpace, GLenum type);
-
- bool lookupType(GLenum type);
- UINT lookupRange(intptr_t offset, GLsizei count, UINT *minIndex, UINT *maxIndex); // Returns the offset into the index buffer, or -1 if not found
- void addRange(intptr_t offset, GLsizei count, UINT minIndex, UINT maxIndex, UINT streamOffset);
-
- private:
- GLenum mCacheType;
-
- struct IndexRange
- {
- intptr_t offset;
- GLsizei count;
-
- bool operator<(const IndexRange& rhs) const
- {
- if (offset != rhs.offset)
- {
- return offset < rhs.offset;
- }
- if (count != rhs.count)
- {
- return count < rhs.count;
- }
- return false;
- }
- };
-
- struct IndexResult
- {
- UINT minIndex;
- UINT maxIndex;
- UINT streamOffset;
- };
-
- std::map<IndexRange, IndexResult> mCache;
-};
-
-class IndexDataManager
-{
- public:
- IndexDataManager(Context *context, IDirect3DDevice9 *evice);
- virtual ~IndexDataManager();
-
- GLenum prepareIndexData(GLenum type, GLsizei count, Buffer *arrayElementBuffer, const GLvoid *indices, TranslatedIndexData *translated);
- StaticIndexBuffer *getCountingIndices(GLsizei count);
-
- private:
- DISALLOW_COPY_AND_ASSIGN(IndexDataManager);
-
- std::size_t typeSize(GLenum type) const;
- std::size_t indexSize(D3DFORMAT format) const;
-
- IDirect3DDevice9 *const mDevice;
-
- StreamingIndexBuffer *mStreamingBufferShort;
- StreamingIndexBuffer *mStreamingBufferInt;
- StaticIndexBuffer *mCountingBuffer;
-};
-
-}
-
-#endif // LIBGLESV2_INDEXDATAMANAGER_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/Program.cpp b/src/3rdparty/angle/src/libGLESv2/Program.cpp
index 5f53a1f581..c38aa5a61a 100644
--- a/src/3rdparty/angle/src/libGLESv2/Program.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/Program.cpp
@@ -1,5 +1,6 @@
+#include "precompiled.h"
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -9,14 +10,7 @@
#include "libGLESv2/Program.h"
#include "libGLESv2/ProgramBinary.h"
-
-#include "common/debug.h"
-
-#include "libGLESv2/main.h"
-#include "libGLESv2/Shader.h"
-#include "libGLESv2/utilities.h"
-
-#include <string>
+#include "libGLESv2/ResourceManager.h"
namespace gl
{
@@ -91,7 +85,7 @@ void InfoLog::appendSanitized(const char *message)
}
while (found != std::string::npos);
- append("%s\n", msg.c_str());
+ append("%s", msg.c_str());
}
void InfoLog::append(const char *format, ...)
@@ -112,15 +106,17 @@ void InfoLog::append(const char *format, ...)
if (!mInfoLog)
{
- mInfoLog = new char[infoLength + 1];
+ mInfoLog = new char[infoLength + 2];
strcpy(mInfoLog, info);
+ strcpy(mInfoLog + infoLength, "\n");
}
else
{
size_t logLength = strlen(mInfoLog);
- char *newLog = new char[logLength + infoLength + 1];
+ char *newLog = new char[logLength + infoLength + 2];
strcpy(newLog, mInfoLog);
strcpy(newLog + logLength, info);
+ strcpy(newLog + logLength + infoLength, "\n");
delete[] mInfoLog;
mInfoLog = newLog;
@@ -136,7 +132,7 @@ void InfoLog::reset()
}
}
-Program::Program(ResourceManager *manager, GLuint handle) : mResourceManager(manager), mHandle(handle)
+Program::Program(rx::Renderer *renderer, ResourceManager *manager, GLuint handle) : mResourceManager(manager), mHandle(handle)
{
mFragmentShader = NULL;
mVertexShader = NULL;
@@ -144,6 +140,7 @@ Program::Program(ResourceManager *manager, GLuint handle) : mResourceManager(man
mDeleteStatus = false;
mLinked = false;
mRefCount = 0;
+ mRenderer = renderer;
}
Program::~Program()
@@ -247,7 +244,7 @@ bool Program::link()
mInfoLog.reset();
- mProgramBinary.set(new ProgramBinary());
+ mProgramBinary.set(new ProgramBinary(mRenderer));
mLinked = mProgramBinary->link(mInfoLog, mAttributeBindings, mFragmentShader, mVertexShader);
return mLinked;
@@ -304,7 +301,7 @@ bool Program::setProgramBinary(const void *binary, GLsizei length)
mInfoLog.reset();
- mProgramBinary.set(new ProgramBinary());
+ mProgramBinary.set(new ProgramBinary(mRenderer));
mLinked = mProgramBinary->load(mInfoLog, binary, length);
if (!mLinked)
{
diff --git a/src/3rdparty/angle/src/libGLESv2/Program.h b/src/3rdparty/angle/src/libGLESv2/Program.h
index 1c4716bfe8..a9db83403d 100644
--- a/src/3rdparty/angle/src/libGLESv2/Program.h
+++ b/src/3rdparty/angle/src/libGLESv2/Program.h
@@ -13,14 +13,22 @@
#include <string>
#include <set>
-#include "libGLESv2/Shader.h"
-#include "libGLESv2/Context.h"
+#include "common/angleutils.h"
+#include "common/RefCountObject.h"
+#include "libGLESv2/Constants.h"
+
+namespace rx
+{
+class Renderer;
+}
namespace gl
{
class ResourceManager;
class FragmentShader;
class VertexShader;
+class ProgramBinary;
+class Shader;
extern const char * const g_fakepath;
@@ -57,7 +65,7 @@ class InfoLog
class Program
{
public:
- Program(ResourceManager *manager, GLuint handle);
+ Program(rx::Renderer *renderer, ResourceManager *manager, GLuint handle);
~Program();
@@ -112,6 +120,7 @@ class Program
unsigned int mRefCount;
ResourceManager *mResourceManager;
+ rx::Renderer *mRenderer;
const GLuint mHandle;
InfoLog mInfoLog;
diff --git a/src/3rdparty/angle/src/libGLESv2/ProgramBinary.cpp b/src/3rdparty/angle/src/libGLESv2/ProgramBinary.cpp
index b3f5e3b867..14e6c94ca4 100644
--- a/src/3rdparty/angle/src/libGLESv2/ProgramBinary.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/ProgramBinary.cpp
@@ -1,5 +1,6 @@
+#include "precompiled.h"
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -8,21 +9,21 @@
// and related functionality. [OpenGL ES 2.0.24] section 2.10.3 page 28.
#include "libGLESv2/BinaryStream.h"
-#include "libGLESv2/Program.h"
#include "libGLESv2/ProgramBinary.h"
+#include "libGLESv2/renderer/ShaderExecutable.h"
#include "common/debug.h"
#include "common/version.h"
+#include "utilities.h"
#include "libGLESv2/main.h"
#include "libGLESv2/Shader.h"
-#include "libGLESv2/utilities.h"
-
-#include <string>
+#include "libGLESv2/Program.h"
+#include "libGLESv2/renderer/Renderer.h"
+#include "libGLESv2/renderer/VertexDataManager.h"
-#if !defined(ANGLE_COMPILE_OPTIMIZATION_LEVEL)
-#define ANGLE_COMPILE_OPTIMIZATION_LEVEL D3DCOMPILE_OPTIMIZATION_LEVEL3
-#endif
+#undef near
+#undef far
namespace gl
{
@@ -33,43 +34,18 @@ std::string str(int i)
return buffer;
}
-Uniform::Uniform(GLenum type, const std::string &_name, unsigned int arraySize)
- : type(type), _name(_name), name(ProgramBinary::undecorateUniform(_name)), arraySize(arraySize)
-{
- int bytes = UniformInternalSize(type) * arraySize;
- data = new unsigned char[bytes];
- memset(data, 0, bytes);
- dirty = true;
-}
-
-Uniform::~Uniform()
-{
- delete[] data;
-}
-
-bool Uniform::isArray()
-{
- size_t dot = _name.find_last_of('.');
- if (dot == std::string::npos) dot = -1;
-
- return _name.compare(dot + 1, dot + 4, "ar_") == 0;
-}
-
-UniformLocation::UniformLocation(const std::string &_name, unsigned int element, unsigned int index)
- : name(ProgramBinary::undecorateUniform(_name)), element(element), index(index)
+UniformLocation::UniformLocation(const std::string &name, unsigned int element, unsigned int index)
+ : name(name), element(element), index(index)
{
}
unsigned int ProgramBinary::mCurrentSerial = 1;
-ProgramBinary::ProgramBinary() : RefCountObject(0), mSerial(issueSerial())
+ProgramBinary::ProgramBinary(rx::Renderer *renderer) : mRenderer(renderer), RefCountObject(0), mSerial(issueSerial())
{
- mDevice = getDevice();
-
mPixelExecutable = NULL;
mVertexExecutable = NULL;
- mConstantTablePS = NULL;
- mConstantTableVS = NULL;
+ mGeometryExecutable = NULL;
mValidated = false;
@@ -83,36 +59,26 @@ ProgramBinary::ProgramBinary() : RefCountObject(0), mSerial(issueSerial())
mSamplersPS[index].active = false;
}
- for (int index = 0; index < MAX_VERTEX_TEXTURE_IMAGE_UNITS_VTF; index++)
+ for (int index = 0; index < IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS; index++)
{
mSamplersVS[index].active = false;
}
mUsedVertexSamplerRange = 0;
mUsedPixelSamplerRange = 0;
-
- mDxDepthRangeLocation = -1;
- mDxDepthLocation = -1;
- mDxCoordLocation = -1;
- mDxHalfPixelSizeLocation = -1;
- mDxFrontCCWLocation = -1;
- mDxPointsOrLinesLocation = -1;
+ mUsesPointSize = false;
}
ProgramBinary::~ProgramBinary()
{
- if (mPixelExecutable)
- {
- mPixelExecutable->Release();
- }
+ delete mPixelExecutable;
+ mPixelExecutable = NULL;
- if (mVertexExecutable)
- {
- mVertexExecutable->Release();
- }
+ delete mVertexExecutable;
+ mVertexExecutable = NULL;
- delete mConstantTablePS;
- delete mConstantTableVS;
+ delete mGeometryExecutable;
+ mGeometryExecutable = NULL;
while (!mUniforms.empty())
{
@@ -131,16 +97,21 @@ unsigned int ProgramBinary::issueSerial()
return mCurrentSerial++;
}
-IDirect3DPixelShader9 *ProgramBinary::getPixelShader()
+rx::ShaderExecutable *ProgramBinary::getPixelExecutable()
{
return mPixelExecutable;
}
-IDirect3DVertexShader9 *ProgramBinary::getVertexShader()
+rx::ShaderExecutable *ProgramBinary::getVertexExecutable()
{
return mVertexExecutable;
}
+rx::ShaderExecutable *ProgramBinary::getGeometryExecutable()
+{
+ return mGeometryExecutable;
+}
+
GLuint ProgramBinary::getAttributeLocation(const char *name)
{
if (name)
@@ -184,6 +155,16 @@ bool ProgramBinary::usesPointSize() const
return mUsesPointSize;
}
+bool ProgramBinary::usesPointSpriteEmulation() const
+{
+ return mUsesPointSize && mRenderer->getMajorShaderModel() >= 4;
+}
+
+bool ProgramBinary::usesGeometryShader() const
+{
+ return usesPointSpriteEmulation();
+}
+
// Returns the index of the texture image unit (0-19) corresponding to a Direct3D 9 sampler
// index (0-15 for the pixel shader and 0-3 for the vertex shader).
GLint ProgramBinary::getSamplerMapping(SamplerType type, unsigned int samplerIndex)
@@ -211,7 +192,7 @@ GLint ProgramBinary::getSamplerMapping(SamplerType type, unsigned int samplerInd
default: UNREACHABLE();
}
- if (logicalTextureUnit >= 0 && logicalTextureUnit < (GLint)getContext()->getMaximumCombinedTextureImageUnits())
+ if (logicalTextureUnit >= 0 && logicalTextureUnit < (GLint)mRenderer->getMaxCombinedTextureImageUnits())
{
return logicalTextureUnit;
}
@@ -275,15 +256,15 @@ bool ProgramBinary::setUniform1fv(GLint location, GLsizei count, const GLfloat*
Uniform *targetUniform = mUniforms[mUniformIndex[location].index];
targetUniform->dirty = true;
- if (targetUniform->type == GL_FLOAT)
- {
- int arraySize = targetUniform->arraySize;
+ int elementCount = targetUniform->elementCount();
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
+ if (elementCount == 1 && count > 1)
+ return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
+ count = std::min(elementCount - (int)mUniformIndex[location].element, count);
+ if (targetUniform->type == GL_FLOAT)
+ {
GLfloat *target = (GLfloat*)targetUniform->data + mUniformIndex[location].element * 4;
for (int i = 0; i < count; i++)
@@ -298,24 +279,16 @@ bool ProgramBinary::setUniform1fv(GLint location, GLsizei count, const GLfloat*
}
else if (targetUniform->type == GL_BOOL)
{
- int arraySize = targetUniform->arraySize;
-
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
-
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
- GLboolean *boolParams = (GLboolean*)targetUniform->data + mUniformIndex[location].element;
+ GLint *boolParams = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- for (int i = 0; i < count; ++i)
+ for (int i = 0; i < count; i++)
{
- if (v[i] == 0.0f)
- {
- boolParams[i] = GL_FALSE;
- }
- else
- {
- boolParams[i] = GL_TRUE;
- }
+ boolParams[0] = (v[0] == 0.0f) ? GL_FALSE : GL_TRUE;
+ boolParams[1] = GL_FALSE;
+ boolParams[2] = GL_FALSE;
+ boolParams[3] = GL_FALSE;
+ boolParams += 4;
+ v += 1;
}
}
else
@@ -336,15 +309,15 @@ bool ProgramBinary::setUniform2fv(GLint location, GLsizei count, const GLfloat *
Uniform *targetUniform = mUniforms[mUniformIndex[location].index];
targetUniform->dirty = true;
- if (targetUniform->type == GL_FLOAT_VEC2)
- {
- int arraySize = targetUniform->arraySize;
+ int elementCount = targetUniform->elementCount();
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
+ if (elementCount == 1 && count > 1)
+ return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
+ count = std::min(elementCount - (int)mUniformIndex[location].element, count);
+ if (targetUniform->type == GL_FLOAT_VEC2)
+ {
GLfloat *target = (GLfloat*)targetUniform->data + mUniformIndex[location].element * 4;
for (int i = 0; i < count; i++)
@@ -359,25 +332,16 @@ bool ProgramBinary::setUniform2fv(GLint location, GLsizei count, const GLfloat *
}
else if (targetUniform->type == GL_BOOL_VEC2)
{
- int arraySize = targetUniform->arraySize;
-
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
-
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
+ GLint *boolParams = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- GLboolean *boolParams = (GLboolean*)targetUniform->data + mUniformIndex[location].element * 2;
-
- for (int i = 0; i < count * 2; ++i)
+ for (int i = 0; i < count; i++)
{
- if (v[i] == 0.0f)
- {
- boolParams[i] = GL_FALSE;
- }
- else
- {
- boolParams[i] = GL_TRUE;
- }
+ boolParams[0] = (v[0] == 0.0f) ? GL_FALSE : GL_TRUE;
+ boolParams[1] = (v[1] == 0.0f) ? GL_FALSE : GL_TRUE;
+ boolParams[2] = GL_FALSE;
+ boolParams[3] = GL_FALSE;
+ boolParams += 4;
+ v += 2;
}
}
else
@@ -398,15 +362,15 @@ bool ProgramBinary::setUniform3fv(GLint location, GLsizei count, const GLfloat *
Uniform *targetUniform = mUniforms[mUniformIndex[location].index];
targetUniform->dirty = true;
- if (targetUniform->type == GL_FLOAT_VEC3)
- {
- int arraySize = targetUniform->arraySize;
+ int elementCount = targetUniform->elementCount();
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
+ if (elementCount == 1 && count > 1)
+ return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
+ count = std::min(elementCount - (int)mUniformIndex[location].element, count);
+ if (targetUniform->type == GL_FLOAT_VEC3)
+ {
GLfloat *target = (GLfloat*)targetUniform->data + mUniformIndex[location].element * 4;
for (int i = 0; i < count; i++)
@@ -421,24 +385,16 @@ bool ProgramBinary::setUniform3fv(GLint location, GLsizei count, const GLfloat *
}
else if (targetUniform->type == GL_BOOL_VEC3)
{
- int arraySize = targetUniform->arraySize;
-
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
-
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
- GLboolean *boolParams = (GLboolean*)targetUniform->data + mUniformIndex[location].element * 3;
+ GLint *boolParams = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- for (int i = 0; i < count * 3; ++i)
+ for (int i = 0; i < count; i++)
{
- if (v[i] == 0.0f)
- {
- boolParams[i] = GL_FALSE;
- }
- else
- {
- boolParams[i] = GL_TRUE;
- }
+ boolParams[0] = (v[0] == 0.0f) ? GL_FALSE : GL_TRUE;
+ boolParams[1] = (v[1] == 0.0f) ? GL_FALSE : GL_TRUE;
+ boolParams[2] = (v[2] == 0.0f) ? GL_FALSE : GL_TRUE;
+ boolParams[3] = GL_FALSE;
+ boolParams += 4;
+ v += 3;
}
}
else
@@ -459,38 +415,39 @@ bool ProgramBinary::setUniform4fv(GLint location, GLsizei count, const GLfloat *
Uniform *targetUniform = mUniforms[mUniformIndex[location].index];
targetUniform->dirty = true;
- if (targetUniform->type == GL_FLOAT_VEC4)
- {
- int arraySize = targetUniform->arraySize;
+ int elementCount = targetUniform->elementCount();
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
+ if (elementCount == 1 && count > 1)
+ return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
+ count = std::min(elementCount - (int)mUniformIndex[location].element, count);
+
+ if (targetUniform->type == GL_FLOAT_VEC4)
+ {
+ GLfloat *target = (GLfloat*)targetUniform->data + mUniformIndex[location].element * 4;
- memcpy(targetUniform->data + mUniformIndex[location].element * sizeof(GLfloat) * 4,
- v, 4 * sizeof(GLfloat) * count);
+ for (int i = 0; i < count; i++)
+ {
+ target[0] = v[0];
+ target[1] = v[1];
+ target[2] = v[2];
+ target[3] = v[3];
+ target += 4;
+ v += 4;
+ }
}
else if (targetUniform->type == GL_BOOL_VEC4)
{
- int arraySize = targetUniform->arraySize;
-
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
-
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
- GLboolean *boolParams = (GLboolean*)targetUniform->data + mUniformIndex[location].element * 4;
+ GLint *boolParams = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- for (int i = 0; i < count * 4; ++i)
+ for (int i = 0; i < count; i++)
{
- if (v[i] == 0.0f)
- {
- boolParams[i] = GL_FALSE;
- }
- else
- {
- boolParams[i] = GL_TRUE;
- }
+ boolParams[0] = (v[0] == 0.0f) ? GL_FALSE : GL_TRUE;
+ boolParams[1] = (v[1] == 0.0f) ? GL_FALSE : GL_TRUE;
+ boolParams[2] = (v[2] == 0.0f) ? GL_FALSE : GL_TRUE;
+ boolParams[3] = (v[3] == 0.0f) ? GL_FALSE : GL_TRUE;
+ boolParams += 4;
+ v += 4;
}
}
else
@@ -547,14 +504,14 @@ bool ProgramBinary::setUniformMatrix2fv(GLint location, GLsizei count, const GLf
return false;
}
- int arraySize = targetUniform->arraySize;
+ int elementCount = targetUniform->elementCount();
- if (arraySize == 1 && count > 1)
+ if (elementCount == 1 && count > 1)
return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
-
+ count = std::min(elementCount - (int)mUniformIndex[location].element, count);
GLfloat *target = (GLfloat*)targetUniform->data + mUniformIndex[location].element * 8;
+
for (int i = 0; i < count; i++)
{
transposeMatrix<GLfloat,4,2,2,2>(target, value);
@@ -580,14 +537,14 @@ bool ProgramBinary::setUniformMatrix3fv(GLint location, GLsizei count, const GLf
return false;
}
- int arraySize = targetUniform->arraySize;
+ int elementCount = targetUniform->elementCount();
- if (arraySize == 1 && count > 1)
+ if (elementCount == 1 && count > 1)
return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
-
+ count = std::min(elementCount - (int)mUniformIndex[location].element, count);
GLfloat *target = (GLfloat*)targetUniform->data + mUniformIndex[location].element * 12;
+
for (int i = 0; i < count; i++)
{
transposeMatrix<GLfloat,4,3,3,3>(target, value);
@@ -614,14 +571,14 @@ bool ProgramBinary::setUniformMatrix4fv(GLint location, GLsizei count, const GLf
return false;
}
- int arraySize = targetUniform->arraySize;
+ int elementCount = targetUniform->elementCount();
- if (arraySize == 1 && count > 1)
+ if (elementCount == 1 && count > 1)
return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
-
+ count = std::min(elementCount - (int)mUniformIndex[location].element, count);
GLfloat *target = (GLfloat*)(targetUniform->data + mUniformIndex[location].element * sizeof(GLfloat) * 16);
+
for (int i = 0; i < count; i++)
{
transposeMatrix<GLfloat,4,4,4,4>(target, value);
@@ -642,40 +599,41 @@ bool ProgramBinary::setUniform1iv(GLint location, GLsizei count, const GLint *v)
Uniform *targetUniform = mUniforms[mUniformIndex[location].index];
targetUniform->dirty = true;
+ int elementCount = targetUniform->elementCount();
+
+ if (elementCount == 1 && count > 1)
+ return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
+
+ count = std::min(elementCount - (int)mUniformIndex[location].element, count);
+
if (targetUniform->type == GL_INT ||
targetUniform->type == GL_SAMPLER_2D ||
targetUniform->type == GL_SAMPLER_CUBE)
{
- int arraySize = targetUniform->arraySize;
-
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
-
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
+ GLint *target = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- memcpy(targetUniform->data + mUniformIndex[location].element * sizeof(GLint),
- v, sizeof(GLint) * count);
+ for (int i = 0; i < count; i++)
+ {
+ target[0] = v[0];
+ target[1] = 0;
+ target[2] = 0;
+ target[3] = 0;
+ target += 4;
+ v += 1;
+ }
}
else if (targetUniform->type == GL_BOOL)
{
- int arraySize = targetUniform->arraySize;
-
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
-
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
- GLboolean *boolParams = (GLboolean*)targetUniform->data + mUniformIndex[location].element;
+ GLint *boolParams = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- for (int i = 0; i < count; ++i)
+ for (int i = 0; i < count; i++)
{
- if (v[i] == 0)
- {
- boolParams[i] = GL_FALSE;
- }
- else
- {
- boolParams[i] = GL_TRUE;
- }
+ boolParams[0] = (v[0] == 0) ? GL_FALSE : GL_TRUE;
+ boolParams[1] = GL_FALSE;
+ boolParams[2] = GL_FALSE;
+ boolParams[3] = GL_FALSE;
+ boolParams += 4;
+ v += 1;
}
}
else
@@ -696,38 +654,39 @@ bool ProgramBinary::setUniform2iv(GLint location, GLsizei count, const GLint *v)
Uniform *targetUniform = mUniforms[mUniformIndex[location].index];
targetUniform->dirty = true;
- if (targetUniform->type == GL_INT_VEC2)
- {
- int arraySize = targetUniform->arraySize;
+ int elementCount = targetUniform->elementCount();
+
+ if (elementCount == 1 && count > 1)
+ return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
+ count = std::min(elementCount - (int)mUniformIndex[location].element, count);
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
+ if (targetUniform->type == GL_INT_VEC2)
+ {
+ GLint *target = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- memcpy(targetUniform->data + mUniformIndex[location].element * sizeof(GLint) * 2,
- v, 2 * sizeof(GLint) * count);
+ for (int i = 0; i < count; i++)
+ {
+ target[0] = v[0];
+ target[1] = v[1];
+ target[2] = 0;
+ target[3] = 0;
+ target += 4;
+ v += 2;
+ }
}
else if (targetUniform->type == GL_BOOL_VEC2)
{
- int arraySize = targetUniform->arraySize;
-
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
+ GLint *boolParams = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
- GLboolean *boolParams = (GLboolean*)targetUniform->data + mUniformIndex[location].element * 2;
-
- for (int i = 0; i < count * 2; ++i)
+ for (int i = 0; i < count; i++)
{
- if (v[i] == 0)
- {
- boolParams[i] = GL_FALSE;
- }
- else
- {
- boolParams[i] = GL_TRUE;
- }
+ boolParams[0] = (v[0] == 0) ? GL_FALSE : GL_TRUE;
+ boolParams[1] = (v[1] == 0) ? GL_FALSE : GL_TRUE;
+ boolParams[2] = GL_FALSE;
+ boolParams[3] = GL_FALSE;
+ boolParams += 4;
+ v += 2;
}
}
else
@@ -748,38 +707,39 @@ bool ProgramBinary::setUniform3iv(GLint location, GLsizei count, const GLint *v)
Uniform *targetUniform = mUniforms[mUniformIndex[location].index];
targetUniform->dirty = true;
- if (targetUniform->type == GL_INT_VEC3)
- {
- int arraySize = targetUniform->arraySize;
+ int elementCount = targetUniform->elementCount();
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
+ if (elementCount == 1 && count > 1)
+ return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
+ count = std::min(elementCount - (int)mUniformIndex[location].element, count);
- memcpy(targetUniform->data + mUniformIndex[location].element * sizeof(GLint) * 3,
- v, 3 * sizeof(GLint) * count);
+ if (targetUniform->type == GL_INT_VEC3)
+ {
+ GLint *target = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
+
+ for (int i = 0; i < count; i++)
+ {
+ target[0] = v[0];
+ target[1] = v[1];
+ target[2] = v[2];
+ target[3] = 0;
+ target += 4;
+ v += 3;
+ }
}
else if (targetUniform->type == GL_BOOL_VEC3)
{
- int arraySize = targetUniform->arraySize;
-
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
-
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
- GLboolean *boolParams = (GLboolean*)targetUniform->data + mUniformIndex[location].element * 3;
+ GLint *boolParams = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- for (int i = 0; i < count * 3; ++i)
+ for (int i = 0; i < count; i++)
{
- if (v[i] == 0)
- {
- boolParams[i] = GL_FALSE;
- }
- else
- {
- boolParams[i] = GL_TRUE;
- }
+ boolParams[0] = (v[0] == 0) ? GL_FALSE : GL_TRUE;
+ boolParams[1] = (v[1] == 0) ? GL_FALSE : GL_TRUE;
+ boolParams[2] = (v[2] == 0) ? GL_FALSE : GL_TRUE;
+ boolParams[3] = GL_FALSE;
+ boolParams += 4;
+ v += 3;
}
}
else
@@ -800,38 +760,39 @@ bool ProgramBinary::setUniform4iv(GLint location, GLsizei count, const GLint *v)
Uniform *targetUniform = mUniforms[mUniformIndex[location].index];
targetUniform->dirty = true;
- if (targetUniform->type == GL_INT_VEC4)
- {
- int arraySize = targetUniform->arraySize;
+ int elementCount = targetUniform->elementCount();
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
+ if (elementCount == 1 && count > 1)
+ return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
+ count = std::min(elementCount - (int)mUniformIndex[location].element, count);
- memcpy(targetUniform->data + mUniformIndex[location].element * sizeof(GLint) * 4,
- v, 4 * sizeof(GLint) * count);
+ if (targetUniform->type == GL_INT_VEC4)
+ {
+ GLint *target = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
+
+ for (int i = 0; i < count; i++)
+ {
+ target[0] = v[0];
+ target[1] = v[1];
+ target[2] = v[2];
+ target[3] = v[3];
+ target += 4;
+ v += 4;
+ }
}
else if (targetUniform->type == GL_BOOL_VEC4)
{
- int arraySize = targetUniform->arraySize;
-
- if (arraySize == 1 && count > 1)
- return false; // attempting to write an array to a non-array uniform is an INVALID_OPERATION
+ GLint *boolParams = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- count = std::min(arraySize - (int)mUniformIndex[location].element, count);
- GLboolean *boolParams = (GLboolean*)targetUniform->data + mUniformIndex[location].element * 4;
-
- for (int i = 0; i < count * 4; ++i)
+ for (int i = 0; i < count; i++)
{
- if (v[i] == 0)
- {
- boolParams[i] = GL_FALSE;
- }
- else
- {
- boolParams[i] = GL_TRUE;
- }
+ boolParams[0] = (v[0] == 0) ? GL_FALSE : GL_TRUE;
+ boolParams[1] = (v[1] == 0) ? GL_FALSE : GL_TRUE;
+ boolParams[2] = (v[2] == 0) ? GL_FALSE : GL_TRUE;
+ boolParams[3] = (v[3] == 0) ? GL_FALSE : GL_TRUE;
+ boolParams += 4;
+ v += 4;
}
}
else
@@ -874,30 +835,29 @@ bool ProgramBinary::getUniformfv(GLint location, GLsizei *bufSize, GLfloat *para
break;
default:
{
- unsigned int count = UniformExternalComponentCount(targetUniform->type);
- unsigned int internalCount = UniformInternalComponentCount(targetUniform->type);
+ unsigned int size = UniformComponentCount(targetUniform->type);
switch (UniformComponentType(targetUniform->type))
{
case GL_BOOL:
{
- GLboolean *boolParams = (GLboolean*)targetUniform->data + mUniformIndex[location].element * internalCount;
+ GLint *boolParams = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- for (unsigned int i = 0; i < count; ++i)
+ for (unsigned int i = 0; i < size; i++)
{
params[i] = (boolParams[i] == GL_FALSE) ? 0.0f : 1.0f;
}
}
break;
case GL_FLOAT:
- memcpy(params, targetUniform->data + mUniformIndex[location].element * internalCount * sizeof(GLfloat),
- count * sizeof(GLfloat));
+ memcpy(params, targetUniform->data + mUniformIndex[location].element * 4 * sizeof(GLfloat),
+ size * sizeof(GLfloat));
break;
case GL_INT:
{
- GLint *intParams = (GLint*)targetUniform->data + mUniformIndex[location].element * internalCount;
+ GLint *intParams = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- for (unsigned int i = 0; i < count; ++i)
+ for (unsigned int i = 0; i < size; i++)
{
params[i] = (float)intParams[i];
}
@@ -933,50 +893,43 @@ bool ProgramBinary::getUniformiv(GLint location, GLsizei *bufSize, GLint *params
switch (targetUniform->type)
{
case GL_FLOAT_MAT2:
- {
- transposeMatrix<GLint,2,2,4,2>(params, (GLfloat*)targetUniform->data + mUniformIndex[location].element * 8);
- }
+ transposeMatrix<GLint,2,2,4,2>(params, (GLfloat*)targetUniform->data + mUniformIndex[location].element * 8);
break;
case GL_FLOAT_MAT3:
- {
- transposeMatrix<GLint,3,3,4,3>(params, (GLfloat*)targetUniform->data + mUniformIndex[location].element * 12);
- }
+ transposeMatrix<GLint,3,3,4,3>(params, (GLfloat*)targetUniform->data + mUniformIndex[location].element * 12);
break;
case GL_FLOAT_MAT4:
- {
- transposeMatrix<GLint,4,4,4,4>(params, (GLfloat*)targetUniform->data + mUniformIndex[location].element * 16);
- }
+ transposeMatrix<GLint,4,4,4,4>(params, (GLfloat*)targetUniform->data + mUniformIndex[location].element * 16);
break;
default:
{
- unsigned int count = UniformExternalComponentCount(targetUniform->type);
- unsigned int internalCount = UniformInternalComponentCount(targetUniform->type);
+ unsigned int size = VariableColumnCount(targetUniform->type);
switch (UniformComponentType(targetUniform->type))
{
case GL_BOOL:
{
- GLboolean *boolParams = targetUniform->data + mUniformIndex[location].element * internalCount;
+ GLint *boolParams = (GLint*)targetUniform->data + mUniformIndex[location].element * 4;
- for (unsigned int i = 0; i < count; ++i)
+ for (unsigned int i = 0; i < size; i++)
{
- params[i] = (GLint)boolParams[i];
+ params[i] = boolParams[i];
}
}
break;
case GL_FLOAT:
{
- GLfloat *floatParams = (GLfloat*)targetUniform->data + mUniformIndex[location].element * internalCount;
+ GLfloat *floatParams = (GLfloat*)targetUniform->data + mUniformIndex[location].element * 4;
- for (unsigned int i = 0; i < count; ++i)
+ for (unsigned int i = 0; i < size; i++)
{
params[i] = (GLint)floatParams[i];
}
}
break;
case GL_INT:
- memcpy(params, targetUniform->data + mUniformIndex[location].element * internalCount * sizeof(GLint),
- count * sizeof(GLint));
+ memcpy(params, targetUniform->data + mUniformIndex[location].element * 4 * sizeof(GLint),
+ size * sizeof(GLint));
break;
default: UNREACHABLE();
}
@@ -995,153 +948,67 @@ void ProgramBinary::dirtyAllUniforms()
}
}
-// Applies all the uniforms set for this program object to the Direct3D 9 device
+// Applies all the uniforms set for this program object to the renderer
void ProgramBinary::applyUniforms()
{
- for (std::vector<Uniform*>::iterator ub = mUniforms.begin(), ue = mUniforms.end(); ub != ue; ++ub) {
+ // Retrieve sampler uniform values
+ for (std::vector<Uniform*>::iterator ub = mUniforms.begin(), ue = mUniforms.end(); ub != ue; ++ub)
+ {
Uniform *targetUniform = *ub;
if (targetUniform->dirty)
{
- int arraySize = targetUniform->arraySize;
- GLfloat *f = (GLfloat*)targetUniform->data;
- GLint *i = (GLint*)targetUniform->data;
- GLboolean *b = (GLboolean*)targetUniform->data;
-
- switch (targetUniform->type)
+ if (targetUniform->type == GL_SAMPLER_2D ||
+ targetUniform->type == GL_SAMPLER_CUBE)
{
- case GL_BOOL: applyUniformnbv(targetUniform, arraySize, 1, b); break;
- case GL_BOOL_VEC2: applyUniformnbv(targetUniform, arraySize, 2, b); break;
- case GL_BOOL_VEC3: applyUniformnbv(targetUniform, arraySize, 3, b); break;
- case GL_BOOL_VEC4: applyUniformnbv(targetUniform, arraySize, 4, b); break;
- case GL_FLOAT:
- case GL_FLOAT_VEC2:
- case GL_FLOAT_VEC3:
- case GL_FLOAT_VEC4:
- case GL_FLOAT_MAT2:
- case GL_FLOAT_MAT3:
- case GL_FLOAT_MAT4: applyUniformnfv(targetUniform, f); break;
- case GL_SAMPLER_2D:
- case GL_SAMPLER_CUBE:
- case GL_INT: applyUniform1iv(targetUniform, arraySize, i); break;
- case GL_INT_VEC2: applyUniform2iv(targetUniform, arraySize, i); break;
- case GL_INT_VEC3: applyUniform3iv(targetUniform, arraySize, i); break;
- case GL_INT_VEC4: applyUniform4iv(targetUniform, arraySize, i); break;
- default:
- UNREACHABLE();
- }
-
- targetUniform->dirty = false;
- }
- }
-}
+ int count = targetUniform->elementCount();
+ GLint (*v)[4] = (GLint(*)[4])targetUniform->data;
-// Compiles the HLSL code of the attached shaders into executable binaries
-ID3D10Blob *ProgramBinary::compileToBinary(InfoLog &infoLog, const char *hlsl, const char *profile, D3DConstantTable **constantTable)
-{
- if (!hlsl)
- {
- return NULL;
- }
-
- DWORD result = NOERROR;
- UINT flags = 0;
- std::string sourceText;
- if (perfActive())
- {
- flags |= D3DCOMPILE_DEBUG;
-#ifdef NDEBUG
- flags |= ANGLE_COMPILE_OPTIMIZATION_LEVEL;
-#else
- flags |= D3DCOMPILE_SKIP_OPTIMIZATION;
-#endif
-
- std::string sourcePath = getTempPath();
- sourceText = std::string("#line 2 \"") + sourcePath + std::string("\"\n\n") + std::string(hlsl);
- writeFile(sourcePath.c_str(), sourceText.c_str(), sourceText.size());
- }
- else
- {
- flags |= ANGLE_COMPILE_OPTIMIZATION_LEVEL;
- sourceText = hlsl;
- }
-
- // Sometimes D3DCompile will fail with the default compilation flags for complicated shaders when it would otherwise pass with alternative options.
- // Try the default flags first and if compilation fails, try some alternatives.
- const static UINT extraFlags[] =
- {
- 0,
- D3DCOMPILE_AVOID_FLOW_CONTROL,
- D3DCOMPILE_PREFER_FLOW_CONTROL
- };
-
- const static char * const extraFlagNames[] =
- {
- "default",
- "avoid flow control",
- "prefer flow control"
- };
-
- for (int i = 0; i < sizeof(extraFlags) / sizeof(UINT); ++i)
- {
- ID3D10Blob *errorMessage = NULL;
- ID3D10Blob *binary = NULL;
- result = D3DCompile(hlsl, strlen(hlsl), g_fakepath, NULL, NULL, "main", profile, flags | extraFlags[i], 0, &binary, &errorMessage);
-
- if (errorMessage)
- {
- const char *message = (const char*)errorMessage->GetBufferPointer();
+ if (targetUniform->psRegisterIndex >= 0)
+ {
+ unsigned int firstIndex = targetUniform->psRegisterIndex;
- infoLog.appendSanitized(message);
- TRACE("\n%s", hlsl);
- TRACE("\n%s", message);
+ for (int i = 0; i < count; i++)
+ {
+ unsigned int samplerIndex = firstIndex + i;
- errorMessage->Release();
- errorMessage = NULL;
- }
+ if (samplerIndex < MAX_TEXTURE_IMAGE_UNITS)
+ {
+ ASSERT(mSamplersPS[samplerIndex].active);
+ mSamplersPS[samplerIndex].logicalTextureUnit = v[i][0];
+ }
+ }
+ }
- if (SUCCEEDED(result))
- {
- D3DConstantTable *table = new D3DConstantTable(binary->GetBufferPointer(), binary->GetBufferSize());
- if (table->error())
- {
- delete table;
- binary->Release();
- return NULL;
- }
+ if (targetUniform->vsRegisterIndex >= 0)
+ {
+ unsigned int firstIndex = targetUniform->vsRegisterIndex;
- *constantTable = table;
-
- return binary;
- }
- else
- {
- if (result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY)
- {
- return error(GL_OUT_OF_MEMORY, (ID3D10Blob*) NULL);
- }
+ for (int i = 0; i < count; i++)
+ {
+ unsigned int samplerIndex = firstIndex + i;
- infoLog.append("Warning: D3D shader compilation failed with ");
- infoLog.append(extraFlagNames[i]);
- infoLog.append(" flags.");
- if (i + 1 < sizeof(extraFlagNames) / sizeof(char*))
- {
- infoLog.append(" Retrying with ");
- infoLog.append(extraFlagNames[i + 1]);
- infoLog.append(".\n");
+ if (samplerIndex < IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS)
+ {
+ ASSERT(mSamplersVS[samplerIndex].active);
+ mSamplersVS[samplerIndex].logicalTextureUnit = v[i][0];
+ }
+ }
+ }
}
}
}
- return NULL;
+ mRenderer->applyUniforms(this, &mUniforms);
}
// Packs varyings into generic varying registers, using the algorithm from [OpenGL ES Shading Language 1.00 rev. 17] appendix A section 7 page 111
// Returns the number of used varying registers, or -1 if unsuccesful
int ProgramBinary::packVaryings(InfoLog &infoLog, const Varying *packing[][4], FragmentShader *fragmentShader)
{
- Context *context = getContext();
- const int maxVaryingVectors = context->getMaximumVaryingVectors();
+ const int maxVaryingVectors = mRenderer->getMaxVaryingVectors();
+
+ fragmentShader->resetVaryingsRegisterAssignment();
for (VaryingList::iterator varying = fragmentShader->mVaryings.begin(); varying != fragmentShader->mVaryings.end(); varying++)
{
@@ -1286,47 +1153,39 @@ int ProgramBinary::packVaryings(InfoLog &infoLog, const Varying *packing[][4], F
return registers;
}
-bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::string& vertexHLSL, FragmentShader *fragmentShader, VertexShader *vertexShader)
+bool ProgramBinary::linkVaryings(InfoLog &infoLog, int registers, const Varying *packing[][4],
+ std::string& pixelHLSL, std::string& vertexHLSL,
+ FragmentShader *fragmentShader, VertexShader *vertexShader)
{
if (pixelHLSL.empty() || vertexHLSL.empty())
{
return false;
}
- // Reset the varying register assignments
- for (VaryingList::iterator fragVar = fragmentShader->mVaryings.begin(); fragVar != fragmentShader->mVaryings.end(); fragVar++)
- {
- fragVar->reg = -1;
- fragVar->col = -1;
- }
-
- for (VaryingList::iterator vtxVar = vertexShader->mVaryings.begin(); vtxVar != vertexShader->mVaryings.end(); vtxVar++)
- {
- vtxVar->reg = -1;
- vtxVar->col = -1;
- }
-
- // Map the varyings to the register file
- const Varying *packing[MAX_VARYING_VECTORS_SM3][4] = {NULL};
- int registers = packVaryings(infoLog, packing, fragmentShader);
-
- if (registers < 0)
+ bool usesMRT = fragmentShader->mUsesMultipleRenderTargets;
+ bool usesFragColor = fragmentShader->mUsesFragColor;
+ bool usesFragData = fragmentShader->mUsesFragData;
+ if (usesMRT && usesFragColor && usesFragData)
{
+ infoLog.append("Cannot use both gl_FragColor and gl_FragData in the same fragment shader.");
return false;
}
// Write the HLSL input/output declarations
- Context *context = getContext();
- const bool sm3 = context->supportsShaderModel3();
- const int maxVaryingVectors = context->getMaximumVaryingVectors();
+ const int shaderModel = mRenderer->getMajorShaderModel();
+ const int maxVaryingVectors = mRenderer->getMaxVaryingVectors();
- if (registers == maxVaryingVectors && fragmentShader->mUsesFragCoord)
+ const int registersNeeded = registers + (fragmentShader->mUsesFragCoord ? 1 : 0) + (fragmentShader->mUsesPointCoord ? 1 : 0);
+
+ if (registersNeeded > maxVaryingVectors)
{
- infoLog.append("No varying registers left to support gl_FragCoord");
+ infoLog.append("No varying registers left to support gl_FragCoord/gl_PointCoord");
return false;
}
+ vertexShader->resetVaryingsRegisterAssignment();
+
for (VaryingList::iterator input = fragmentShader->mVaryings.begin(); input != fragmentShader->mVaryings.end(); input++)
{
bool matched = false;
@@ -1359,10 +1218,38 @@ bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::
}
mUsesPointSize = vertexShader->mUsesPointSize;
- std::string varyingSemantic = (mUsesPointSize && sm3) ? "COLOR" : "TEXCOORD";
+ std::string varyingSemantic = (mUsesPointSize && shaderModel == 3) ? "COLOR" : "TEXCOORD";
+ std::string targetSemantic = (shaderModel >= 4) ? "SV_Target" : "COLOR";
+ std::string positionSemantic = (shaderModel >= 4) ? "SV_Position" : "POSITION";
+
+ const unsigned int renderTargetCount = usesMRT ? mRenderer->getMaxRenderTargets() : 1;
+
+ // special varyings that use reserved registers
+ int reservedRegisterIndex = registers;
+ std::string fragCoordSemantic;
+ std::string pointCoordSemantic;
+
+ if (fragmentShader->mUsesFragCoord)
+ {
+ fragCoordSemantic = varyingSemantic + str(reservedRegisterIndex++);
+ }
+
+ if (fragmentShader->mUsesPointCoord)
+ {
+ // Shader model 3 uses a special TEXCOORD semantic for point sprite texcoords.
+ // In DX11 we compute this in the GS.
+ if (shaderModel == 3)
+ {
+ pointCoordSemantic = "TEXCOORD0";
+ }
+ else if (shaderModel >= 4)
+ {
+ pointCoordSemantic = varyingSemantic + str(reservedRegisterIndex++);
+ }
+ }
vertexHLSL += "struct VS_INPUT\n"
- "{\n";
+ "{\n";
int semanticIndex = 0;
for (AttributeArray::iterator attribute = vertexShader->mAttributes.begin(); attribute != vertexShader->mAttributes.end(); attribute++)
@@ -1385,10 +1272,14 @@ bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::
}
vertexHLSL += "};\n"
- "\n"
- "struct VS_OUTPUT\n"
- "{\n"
- " float4 gl_Position : POSITION;\n";
+ "\n"
+ "struct VS_OUTPUT\n"
+ "{\n";
+
+ if (shaderModel < 4)
+ {
+ vertexHLSL += " float4 gl_Position : " + positionSemantic + ";\n";
+ }
for (int r = 0; r < registers; r++)
{
@@ -1399,18 +1290,23 @@ bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::
if (fragmentShader->mUsesFragCoord)
{
- vertexHLSL += " float4 gl_FragCoord : " + varyingSemantic + str(registers) + ";\n";
+ vertexHLSL += " float4 gl_FragCoord : " + fragCoordSemantic + ";\n";
}
- if (vertexShader->mUsesPointSize && sm3)
+ if (vertexShader->mUsesPointSize && shaderModel >= 3)
{
vertexHLSL += " float gl_PointSize : PSIZE;\n";
}
+ if (shaderModel >= 4)
+ {
+ vertexHLSL += " float4 gl_Position : " + positionSemantic + ";\n";
+ }
+
vertexHLSL += "};\n"
- "\n"
- "VS_OUTPUT main(VS_INPUT input)\n"
- "{\n";
+ "\n"
+ "VS_OUTPUT main(VS_INPUT input)\n"
+ "{\n";
for (AttributeArray::iterator attribute = vertexShader->mAttributes.begin(); attribute != vertexShader->mAttributes.end(); attribute++)
{
@@ -1424,16 +1320,30 @@ bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::
vertexHLSL += "(input." + decorateAttribute(attribute->name) + ");\n";
}
- vertexHLSL += "\n"
- " gl_main();\n"
- "\n"
- " VS_OUTPUT output;\n"
- " output.gl_Position.x = gl_Position.x - dx_HalfPixelSize.x * gl_Position.w;\n"
- " output.gl_Position.y = -(gl_Position.y + dx_HalfPixelSize.y * gl_Position.w);\n"
- " output.gl_Position.z = (gl_Position.z + gl_Position.w) * 0.5;\n"
- " output.gl_Position.w = gl_Position.w;\n";
+ if (shaderModel >= 4)
+ {
+ vertexHLSL += "\n"
+ " gl_main();\n"
+ "\n"
+ " VS_OUTPUT output;\n"
+ " output.gl_Position.x = gl_Position.x;\n"
+ " output.gl_Position.y = -gl_Position.y;\n"
+ " output.gl_Position.z = (gl_Position.z + gl_Position.w) * 0.5;\n"
+ " output.gl_Position.w = gl_Position.w;\n";
+ }
+ else
+ {
+ vertexHLSL += "\n"
+ " gl_main();\n"
+ "\n"
+ " VS_OUTPUT output;\n"
+ " output.gl_Position.x = gl_Position.x * dx_ViewAdjust.z + dx_ViewAdjust.x * gl_Position.w;\n"
+ " output.gl_Position.y = -(gl_Position.y * dx_ViewAdjust.w + dx_ViewAdjust.y * gl_Position.w);\n"
+ " output.gl_Position.z = (gl_Position.z + gl_Position.w) * 0.5;\n"
+ " output.gl_Position.w = gl_Position.w;\n";
+ }
- if (vertexShader->mUsesPointSize && sm3)
+ if (vertexShader->mUsesPointSize && shaderModel >= 3)
{
vertexHLSL += " output.gl_PointSize = gl_PointSize;\n";
}
@@ -1505,11 +1415,11 @@ bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::
}
vertexHLSL += "\n"
- " return output;\n"
- "}\n";
+ " return output;\n"
+ "}\n";
pixelHLSL += "struct PS_INPUT\n"
- "{\n";
+ "{\n";
for (VaryingList::iterator varying = fragmentShader->mVaryings.begin(); varying != fragmentShader->mVaryings.end(); varying++)
{
@@ -1521,7 +1431,7 @@ bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::
for (int j = 0; j < rows; j++)
{
std::string n = str(varying->reg + i * rows + j);
- pixelHLSL += " float4 v" + n + " : " + varyingSemantic + n + ";\n";
+ pixelHLSL += " float" + str(VariableColumnCount(varying->type)) + " v" + n + " : " + varyingSemantic + n + ";\n";
}
}
}
@@ -1530,53 +1440,91 @@ bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::
if (fragmentShader->mUsesFragCoord)
{
- pixelHLSL += " float4 gl_FragCoord : " + varyingSemantic + str(registers) + ";\n";
- if (sm3) {
+ pixelHLSL += " float4 gl_FragCoord : " + fragCoordSemantic + ";\n";
+ }
+
+ if (fragmentShader->mUsesPointCoord && shaderModel >= 3)
+ {
+ pixelHLSL += " float2 gl_PointCoord : " + pointCoordSemantic + ";\n";
+ }
+
+ // Must consume the PSIZE element if the geometry shader is not active
+ // We won't know if we use a GS until we draw
+ if (vertexShader->mUsesPointSize && shaderModel >= 4)
+ {
+ pixelHLSL += " float gl_PointSize : PSIZE;\n";
+ }
+
+ if (fragmentShader->mUsesFragCoord)
+ {
+ if (shaderModel >= 4)
+ {
+ pixelHLSL += " float4 dx_VPos : SV_Position;\n";
+ }
+ else if (shaderModel >= 3)
+ {
pixelHLSL += " float2 dx_VPos : VPOS;\n";
}
}
- if (fragmentShader->mUsesPointCoord && sm3)
+ pixelHLSL += "};\n"
+ "\n"
+ "struct PS_OUTPUT\n"
+ "{\n";
+
+ for (unsigned int i = 0; i < renderTargetCount; i++)
{
- pixelHLSL += " float2 gl_PointCoord : TEXCOORD0;\n";
+ pixelHLSL += " float4 gl_Color" + str(i) + " : " + targetSemantic + str(i) + ";\n";
}
+ pixelHLSL += "};\n"
+ "\n";
+
if (fragmentShader->mUsesFrontFacing)
{
- pixelHLSL += " float vFace : VFACE;\n";
+ if (shaderModel >= 4)
+ {
+ pixelHLSL += "PS_OUTPUT main(PS_INPUT input, bool isFrontFace : SV_IsFrontFace)\n"
+ "{\n";
+ }
+ else
+ {
+ pixelHLSL += "PS_OUTPUT main(PS_INPUT input, float vFace : VFACE)\n"
+ "{\n";
+ }
+ }
+ else
+ {
+ pixelHLSL += "PS_OUTPUT main(PS_INPUT input)\n"
+ "{\n";
}
-
- pixelHLSL += "};\n"
- "\n"
- "struct PS_OUTPUT\n"
- "{\n"
- " float4 gl_Color[1] : COLOR;\n"
- "};\n"
- "\n"
- "PS_OUTPUT main(PS_INPUT input)\n"
- "{\n";
if (fragmentShader->mUsesFragCoord)
{
pixelHLSL += " float rhw = 1.0 / input.gl_FragCoord.w;\n";
- if (sm3)
+ if (shaderModel >= 4)
+ {
+ pixelHLSL += " gl_FragCoord.x = input.dx_VPos.x;\n"
+ " gl_FragCoord.y = input.dx_VPos.y;\n";
+ }
+ else if (shaderModel >= 3)
{
pixelHLSL += " gl_FragCoord.x = input.dx_VPos.x + 0.5;\n"
- " gl_FragCoord.y = input.dx_VPos.y + 0.5;\n";
+ " gl_FragCoord.y = input.dx_VPos.y + 0.5;\n";
}
else
{
- // dx_Coord contains the viewport width/2, height/2, center.x and center.y. See Context::applyRenderTarget()
- pixelHLSL += " gl_FragCoord.x = (input.gl_FragCoord.x * rhw) * dx_Coord.x + dx_Coord.z;\n"
- " gl_FragCoord.y = (input.gl_FragCoord.y * rhw) * dx_Coord.y + dx_Coord.w;\n";
+ // dx_ViewCoords contains the viewport width/2, height/2, center.x and center.y. See Renderer::setViewport()
+ pixelHLSL += " gl_FragCoord.x = (input.gl_FragCoord.x * rhw) * dx_ViewCoords.x + dx_ViewCoords.z;\n"
+ " gl_FragCoord.y = (input.gl_FragCoord.y * rhw) * dx_ViewCoords.y + dx_ViewCoords.w;\n";
}
- pixelHLSL += " gl_FragCoord.z = (input.gl_FragCoord.z * rhw) * dx_Depth.x + dx_Depth.y;\n"
- " gl_FragCoord.w = rhw;\n";
+ pixelHLSL += " gl_FragCoord.z = (input.gl_FragCoord.z * rhw) * dx_DepthFront.x + dx_DepthFront.y;\n"
+ " gl_FragCoord.w = rhw;\n";
}
- if (fragmentShader->mUsesPointCoord && sm3)
+ if (fragmentShader->mUsesPointCoord && shaderModel >= 3)
{
pixelHLSL += " gl_PointCoord.x = input.gl_PointCoord.x;\n";
pixelHLSL += " gl_PointCoord.y = 1.0 - input.gl_PointCoord.y;\n";
@@ -1584,7 +1532,14 @@ bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::
if (fragmentShader->mUsesFrontFacing)
{
- pixelHLSL += " gl_FrontFacing = dx_PointsOrLines || (dx_FrontCCW ? (input.vFace >= 0.0) : (input.vFace <= 0.0));\n";
+ if (shaderModel <= 3)
+ {
+ pixelHLSL += " gl_FrontFacing = (vFace * dx_DepthFront.z >= 0.0);\n";
+ }
+ else
+ {
+ pixelHLSL += " gl_FrontFacing = isFrontFace;\n";
+ }
}
for (VaryingList::iterator varying = fragmentShader->mVaryings.begin(); varying != fragmentShader->mVaryings.end(); varying++)
@@ -1609,7 +1564,14 @@ bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::
pixelHLSL += "[" + str(j) + "]";
}
- pixelHLSL += " = input.v" + n + ";\n";
+ switch (VariableColumnCount(varying->type))
+ {
+ case 1: pixelHLSL += " = input.v" + n + ".x;\n"; break;
+ case 2: pixelHLSL += " = input.v" + n + ".xy;\n"; break;
+ case 3: pixelHLSL += " = input.v" + n + ".xyz;\n"; break;
+ case 4: pixelHLSL += " = input.v" + n + ";\n"; break;
+ default: UNREACHABLE();
+ }
}
}
}
@@ -1617,13 +1579,20 @@ bool ProgramBinary::linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::
}
pixelHLSL += "\n"
- " gl_main();\n"
- "\n"
- " PS_OUTPUT output;\n"
- " output.gl_Color[0] = gl_Color[0];\n"
- "\n"
- " return output;\n"
- "}\n";
+ " gl_main();\n"
+ "\n"
+ " PS_OUTPUT output;\n";
+
+ for (unsigned int i = 0; i < renderTargetCount; i++)
+ {
+ unsigned int sourceColor = fragmentShader->mUsesFragData ? i : 0;
+
+ pixelHLSL += " output.gl_Color" + str(i) + " = gl_Color[" + str(sourceColor) + "];\n";
+ }
+
+ pixelHLSL += "\n"
+ " return output;\n"
+ "}\n";
return true;
}
@@ -1642,7 +1611,7 @@ bool ProgramBinary::load(InfoLog &infoLog, const void *binary, GLsizei length)
int version = 0;
stream.read(&version);
- if (version != BUILD_REVISION)
+ if (version != VERSION_DWORD)
{
infoLog.append("Invalid program binary version.");
return false;
@@ -1667,7 +1636,7 @@ bool ProgramBinary::load(InfoLog &infoLog, const void *binary, GLsizei length)
mSamplersPS[i].textureType = (TextureType) textureType;
}
- for (unsigned int i = 0; i < MAX_VERTEX_TEXTURE_IMAGE_UNITS_VTF; ++i)
+ for (unsigned int i = 0; i < IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS; ++i)
{
stream.read(&mSamplersVS[i].active);
stream.read(&mSamplersVS[i].logicalTextureUnit);
@@ -1679,8 +1648,9 @@ bool ProgramBinary::load(InfoLog &infoLog, const void *binary, GLsizei length)
stream.read(&mUsedVertexSamplerRange);
stream.read(&mUsedPixelSamplerRange);
+ stream.read(&mUsesPointSize);
- unsigned int size;
+ size_t size;
stream.read(&size);
if (stream.error())
{
@@ -1692,24 +1662,20 @@ bool ProgramBinary::load(InfoLog &infoLog, const void *binary, GLsizei length)
for (unsigned int i = 0; i < size; ++i)
{
GLenum type;
- std::string _name;
+ GLenum precision;
+ std::string name;
unsigned int arraySize;
stream.read(&type);
- stream.read(&_name);
+ stream.read(&precision);
+ stream.read(&name);
stream.read(&arraySize);
- mUniforms[i] = new Uniform(type, _name, arraySize);
+ mUniforms[i] = new Uniform(type, precision, name, arraySize);
- stream.read(&mUniforms[i]->ps.float4Index);
- stream.read(&mUniforms[i]->ps.samplerIndex);
- stream.read(&mUniforms[i]->ps.boolIndex);
- stream.read(&mUniforms[i]->ps.registerCount);
-
- stream.read(&mUniforms[i]->vs.float4Index);
- stream.read(&mUniforms[i]->vs.samplerIndex);
- stream.read(&mUniforms[i]->vs.boolIndex);
- stream.read(&mUniforms[i]->vs.registerCount);
+ stream.read(&mUniforms[i]->psRegisterIndex);
+ stream.read(&mUniforms[i]->vsRegisterIndex);
+ stream.read(&mUniforms[i]->registerCount);
}
stream.read(&size);
@@ -1727,26 +1693,22 @@ bool ProgramBinary::load(InfoLog &infoLog, const void *binary, GLsizei length)
stream.read(&mUniformIndex[i].index);
}
- stream.read(&mDxDepthRangeLocation);
- stream.read(&mDxDepthLocation);
- stream.read(&mDxCoordLocation);
- stream.read(&mDxHalfPixelSizeLocation);
- stream.read(&mDxFrontCCWLocation);
- stream.read(&mDxPointsOrLinesLocation);
-
unsigned int pixelShaderSize;
stream.read(&pixelShaderSize);
unsigned int vertexShaderSize;
stream.read(&vertexShaderSize);
+ unsigned int geometryShaderSize;
+ stream.read(&geometryShaderSize);
+
const char *ptr = (const char*) binary + stream.offset();
- const D3DCAPS9 *binaryIdentifier = (const D3DCAPS9*) ptr;
+ const GUID *binaryIdentifier = (const GUID *) ptr;
ptr += sizeof(GUID);
- D3DADAPTER_IDENTIFIER9 *currentIdentifier = getDisplay()->getAdapterIdentifier();
- if (memcmp(&currentIdentifier->DeviceIdentifier, binaryIdentifier, sizeof(GUID)) != 0)
+ GUID identifier = mRenderer->getAdapterIdentifier();
+ if (memcmp(&identifier, binaryIdentifier, sizeof(GUID)) != 0)
{
infoLog.append("Invalid program binary.");
return false;
@@ -1758,22 +1720,46 @@ bool ProgramBinary::load(InfoLog &infoLog, const void *binary, GLsizei length)
const char *vertexShaderFunction = ptr;
ptr += vertexShaderSize;
- mPixelExecutable = getDisplay()->createPixelShader(reinterpret_cast<const DWORD*>(pixelShaderFunction), pixelShaderSize);
+ const char *geometryShaderFunction = geometryShaderSize > 0 ? ptr : NULL;
+ ptr += geometryShaderSize;
+
+ mPixelExecutable = mRenderer->loadExecutable(reinterpret_cast<const DWORD*>(pixelShaderFunction),
+ pixelShaderSize, rx::SHADER_PIXEL);
if (!mPixelExecutable)
{
infoLog.append("Could not create pixel shader.");
return false;
}
- mVertexExecutable = getDisplay()->createVertexShader(reinterpret_cast<const DWORD*>(vertexShaderFunction), vertexShaderSize);
+ mVertexExecutable = mRenderer->loadExecutable(reinterpret_cast<const DWORD*>(vertexShaderFunction),
+ vertexShaderSize, rx::SHADER_VERTEX);
if (!mVertexExecutable)
{
infoLog.append("Could not create vertex shader.");
- mPixelExecutable->Release();
+ delete mPixelExecutable;
mPixelExecutable = NULL;
return false;
}
+ if (geometryShaderFunction != NULL && geometryShaderSize > 0)
+ {
+ mGeometryExecutable = mRenderer->loadExecutable(reinterpret_cast<const DWORD*>(geometryShaderFunction),
+ geometryShaderSize, rx::SHADER_GEOMETRY);
+ if (!mGeometryExecutable)
+ {
+ infoLog.append("Could not create geometry shader.");
+ delete mPixelExecutable;
+ mPixelExecutable = NULL;
+ delete mVertexExecutable;
+ mVertexExecutable = NULL;
+ return false;
+ }
+ }
+ else
+ {
+ mGeometryExecutable = NULL;
+ }
+
return true;
}
@@ -1782,7 +1768,7 @@ bool ProgramBinary::save(void* binary, GLsizei bufSize, GLsizei *length)
BinaryOutputStream stream;
stream.write(GL_PROGRAM_BINARY_ANGLE);
- stream.write(BUILD_REVISION);
+ stream.write(VERSION_DWORD);
for (unsigned int i = 0; i < MAX_VERTEX_ATTRIBS; ++i)
{
@@ -1798,7 +1784,7 @@ bool ProgramBinary::save(void* binary, GLsizei bufSize, GLsizei *length)
stream.write((int) mSamplersPS[i].textureType);
}
- for (unsigned int i = 0; i < MAX_VERTEX_TEXTURE_IMAGE_UNITS_VTF; ++i)
+ for (unsigned int i = 0; i < IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS; ++i)
{
stream.write(mSamplersVS[i].active);
stream.write(mSamplersVS[i].logicalTextureUnit);
@@ -1807,23 +1793,19 @@ bool ProgramBinary::save(void* binary, GLsizei bufSize, GLsizei *length)
stream.write(mUsedVertexSamplerRange);
stream.write(mUsedPixelSamplerRange);
+ stream.write(mUsesPointSize);
stream.write(mUniforms.size());
for (unsigned int i = 0; i < mUniforms.size(); ++i)
{
stream.write(mUniforms[i]->type);
- stream.write(mUniforms[i]->_name);
+ stream.write(mUniforms[i]->precision);
+ stream.write(mUniforms[i]->name);
stream.write(mUniforms[i]->arraySize);
- stream.write(mUniforms[i]->ps.float4Index);
- stream.write(mUniforms[i]->ps.samplerIndex);
- stream.write(mUniforms[i]->ps.boolIndex);
- stream.write(mUniforms[i]->ps.registerCount);
-
- stream.write(mUniforms[i]->vs.float4Index);
- stream.write(mUniforms[i]->vs.samplerIndex);
- stream.write(mUniforms[i]->vs.boolIndex);
- stream.write(mUniforms[i]->vs.registerCount);
+ stream.write(mUniforms[i]->psRegisterIndex);
+ stream.write(mUniforms[i]->vsRegisterIndex);
+ stream.write(mUniforms[i]->registerCount);
}
stream.write(mUniformIndex.size());
@@ -1834,29 +1816,21 @@ bool ProgramBinary::save(void* binary, GLsizei bufSize, GLsizei *length)
stream.write(mUniformIndex[i].index);
}
- stream.write(mDxDepthRangeLocation);
- stream.write(mDxDepthLocation);
- stream.write(mDxCoordLocation);
- stream.write(mDxHalfPixelSizeLocation);
- stream.write(mDxFrontCCWLocation);
- stream.write(mDxPointsOrLinesLocation);
-
- UINT pixelShaderSize;
- HRESULT result = mPixelExecutable->GetFunction(NULL, &pixelShaderSize);
- ASSERT(SUCCEEDED(result));
+ UINT pixelShaderSize = mPixelExecutable->getLength();
stream.write(pixelShaderSize);
- UINT vertexShaderSize;
- result = mVertexExecutable->GetFunction(NULL, &vertexShaderSize);
- ASSERT(SUCCEEDED(result));
+ UINT vertexShaderSize = mVertexExecutable->getLength();
stream.write(vertexShaderSize);
- D3DADAPTER_IDENTIFIER9 *identifier = getDisplay()->getAdapterIdentifier();
+ UINT geometryShaderSize = (mGeometryExecutable != NULL) ? mGeometryExecutable->getLength() : 0;
+ stream.write(geometryShaderSize);
+
+ GUID identifier = mRenderer->getAdapterIdentifier();
GLsizei streamLength = stream.length();
const void *streamData = stream.data();
- GLsizei totalLength = streamLength + sizeof(GUID) + pixelShaderSize + vertexShaderSize;
+ GLsizei totalLength = streamLength + sizeof(GUID) + pixelShaderSize + vertexShaderSize + geometryShaderSize;
if (totalLength > bufSize)
{
if (length)
@@ -1874,17 +1848,21 @@ bool ProgramBinary::save(void* binary, GLsizei bufSize, GLsizei *length)
memcpy(ptr, streamData, streamLength);
ptr += streamLength;
- memcpy(ptr, &identifier->DeviceIdentifier, sizeof(GUID));
+ memcpy(ptr, &identifier, sizeof(GUID));
ptr += sizeof(GUID);
- result = mPixelExecutable->GetFunction(ptr, &pixelShaderSize);
- ASSERT(SUCCEEDED(result));
+ memcpy(ptr, mPixelExecutable->getFunction(), pixelShaderSize);
ptr += pixelShaderSize;
- result = mVertexExecutable->GetFunction(ptr, &vertexShaderSize);
- ASSERT(SUCCEEDED(result));
+ memcpy(ptr, mVertexExecutable->getFunction(), vertexShaderSize);
ptr += vertexShaderSize;
+ if (mGeometryExecutable != NULL && geometryShaderSize > 0)
+ {
+ memcpy(ptr, mGeometryExecutable->getFunction(), geometryShaderSize);
+ ptr += geometryShaderSize;
+ }
+
ASSERT(ptr - totalLength == binary);
}
@@ -1924,69 +1902,54 @@ bool ProgramBinary::link(InfoLog &infoLog, const AttributeBindings &attributeBin
std::string pixelHLSL = fragmentShader->getHLSL();
std::string vertexHLSL = vertexShader->getHLSL();
- if (!linkVaryings(infoLog, pixelHLSL, vertexHLSL, fragmentShader, vertexShader))
+ // Map the varyings to the register file
+ const Varying *packing[IMPLEMENTATION_MAX_VARYING_VECTORS][4] = {NULL};
+ int registers = packVaryings(infoLog, packing, fragmentShader);
+
+ if (registers < 0)
{
return false;
}
- Context *context = getContext();
- const char *vertexProfile = context->supportsShaderModel3() ? "vs_3_0" : "vs_2_0";
- const char *pixelProfile = context->supportsShaderModel3() ? "ps_3_0" : "ps_2_0";
-
- ID3D10Blob *vertexBinary = compileToBinary(infoLog, vertexHLSL.c_str(), vertexProfile, &mConstantTableVS);
- ID3D10Blob *pixelBinary = compileToBinary(infoLog, pixelHLSL.c_str(), pixelProfile, &mConstantTablePS);
-
- if (vertexBinary && pixelBinary)
+ if (!linkVaryings(infoLog, registers, packing, pixelHLSL, vertexHLSL, fragmentShader, vertexShader))
{
- mVertexExecutable = getDisplay()->createVertexShader((DWORD*)vertexBinary->GetBufferPointer(), vertexBinary->GetBufferSize());
- if (!mVertexExecutable)
- {
- return error(GL_OUT_OF_MEMORY, false);
- }
-
- mPixelExecutable = getDisplay()->createPixelShader((DWORD*)pixelBinary->GetBufferPointer(), pixelBinary->GetBufferSize());
- if (!mPixelExecutable)
- {
- mVertexExecutable->Release();
- mVertexExecutable = NULL;
- return error(GL_OUT_OF_MEMORY, false);
- }
+ return false;
+ }
- vertexBinary->Release();
- pixelBinary->Release();
- vertexBinary = NULL;
- pixelBinary = NULL;
+ bool success = true;
+ mVertexExecutable = mRenderer->compileToExecutable(infoLog, vertexHLSL.c_str(), rx::SHADER_VERTEX);
+ mPixelExecutable = mRenderer->compileToExecutable(infoLog, pixelHLSL.c_str(), rx::SHADER_PIXEL);
- if (!linkAttributes(infoLog, attributeBindings, fragmentShader, vertexShader))
- {
- return false;
- }
-
- if (!linkUniforms(infoLog, GL_FRAGMENT_SHADER, mConstantTablePS))
- {
- return false;
- }
+ if (usesGeometryShader())
+ {
+ std::string geometryHLSL = generateGeometryShaderHLSL(registers, packing, fragmentShader, vertexShader);
+ mGeometryExecutable = mRenderer->compileToExecutable(infoLog, geometryHLSL.c_str(), rx::SHADER_GEOMETRY);
+ }
- if (!linkUniforms(infoLog, GL_VERTEX_SHADER, mConstantTableVS))
- {
- return false;
- }
+ if (!mVertexExecutable || !mPixelExecutable || (usesGeometryShader() && !mGeometryExecutable))
+ {
+ infoLog.append("Failed to create D3D shaders.");
+ success = false;
- // these uniforms are searched as already-decorated because gl_ and dx_
- // are reserved prefixes, and do not receive additional decoration
- mDxDepthRangeLocation = getUniformLocation("dx_DepthRange");
- mDxDepthLocation = getUniformLocation("dx_Depth");
- mDxCoordLocation = getUniformLocation("dx_Coord");
- mDxHalfPixelSizeLocation = getUniformLocation("dx_HalfPixelSize");
- mDxFrontCCWLocation = getUniformLocation("dx_FrontCCW");
- mDxPointsOrLinesLocation = getUniformLocation("dx_PointsOrLines");
+ delete mVertexExecutable;
+ mVertexExecutable = NULL;
+ delete mPixelExecutable;
+ mPixelExecutable = NULL;
+ delete mGeometryExecutable;
+ mGeometryExecutable = NULL;
+ }
- context->markDxUniformsDirty();
+ if (!linkAttributes(infoLog, attributeBindings, fragmentShader, vertexShader))
+ {
+ success = false;
+ }
- return true;
+ if (!linkUniforms(infoLog, vertexShader->getUniforms(), fragmentShader->getUniforms()))
+ {
+ success = false;
}
- return false;
+ return success;
}
// Determines the mapping between GL attributes and Direct3D 9 vertex stream usage indices
@@ -2059,13 +2022,19 @@ bool ProgramBinary::linkAttributes(InfoLog &infoLog, const AttributeBindings &at
return true;
}
-bool ProgramBinary::linkUniforms(InfoLog &infoLog, GLenum shader, D3DConstantTable *constantTable)
+bool ProgramBinary::linkUniforms(InfoLog &infoLog, const sh::ActiveUniforms &vertexUniforms, const sh::ActiveUniforms &fragmentUniforms)
{
- for (unsigned int constantIndex = 0; constantIndex < constantTable->constants(); constantIndex++)
+ for (sh::ActiveUniforms::const_iterator uniform = vertexUniforms.begin(); uniform != vertexUniforms.end(); uniform++)
{
- const D3DConstant *constant = constantTable->getConstant(constantIndex);
+ if (!defineUniform(GL_VERTEX_SHADER, *uniform, infoLog))
+ {
+ return false;
+ }
+ }
- if (!defineUniform(infoLog, shader, constant))
+ for (sh::ActiveUniforms::const_iterator uniform = fragmentUniforms.begin(); uniform != fragmentUniforms.end(); uniform++)
+ {
+ if (!defineUniform(GL_FRAGMENT_SHADER, *uniform, infoLog))
{
return false;
}
@@ -2074,432 +2043,271 @@ bool ProgramBinary::linkUniforms(InfoLog &infoLog, GLenum shader, D3DConstantTab
return true;
}
-// Adds the description of a constant found in the binary shader to the list of uniforms
-// Returns true if succesful (uniform not already defined)
-bool ProgramBinary::defineUniform(InfoLog &infoLog, GLenum shader, const D3DConstant *constant, std::string name)
+bool ProgramBinary::defineUniform(GLenum shader, const sh::Uniform &constant, InfoLog &infoLog)
{
- if (constant->registerSet == D3DConstant::RS_SAMPLER)
+ if (constant.type == GL_SAMPLER_2D ||
+ constant.type == GL_SAMPLER_CUBE)
{
- for (unsigned int i = 0; i < constant->registerCount; i++)
+ unsigned int samplerIndex = constant.registerIndex;
+
+ do
{
- const D3DConstant *psConstant = mConstantTablePS->getConstantByName(constant->name.c_str());
- const D3DConstant *vsConstant = mConstantTableVS->getConstantByName(constant->name.c_str());
-
- if (psConstant)
+ if (shader == GL_VERTEX_SHADER)
{
- unsigned int samplerIndex = psConstant->registerIndex + i;
-
- if (samplerIndex < MAX_TEXTURE_IMAGE_UNITS)
+ if (samplerIndex < mRenderer->getMaxVertexTextureImageUnits())
{
- mSamplersPS[samplerIndex].active = true;
- mSamplersPS[samplerIndex].textureType = (constant->type == D3DConstant::PT_SAMPLERCUBE) ? TEXTURE_CUBE : TEXTURE_2D;
- mSamplersPS[samplerIndex].logicalTextureUnit = 0;
- mUsedPixelSamplerRange = std::max(samplerIndex + 1, mUsedPixelSamplerRange);
+ mSamplersVS[samplerIndex].active = true;
+ mSamplersVS[samplerIndex].textureType = (constant.type == GL_SAMPLER_CUBE) ? TEXTURE_CUBE : TEXTURE_2D;
+ mSamplersVS[samplerIndex].logicalTextureUnit = 0;
+ mUsedVertexSamplerRange = std::max(samplerIndex + 1, mUsedVertexSamplerRange);
}
else
{
- infoLog.append("Pixel shader sampler count exceeds MAX_TEXTURE_IMAGE_UNITS (%d).", MAX_TEXTURE_IMAGE_UNITS);
+ infoLog.append("Vertex shader sampler count exceeds the maximum vertex texture units (%d).", mRenderer->getMaxVertexTextureImageUnits());
return false;
}
}
-
- if (vsConstant)
+ else if (shader == GL_FRAGMENT_SHADER)
{
- unsigned int samplerIndex = vsConstant->registerIndex + i;
-
- if (samplerIndex < getContext()->getMaximumVertexTextureImageUnits())
+ if (samplerIndex < MAX_TEXTURE_IMAGE_UNITS)
{
- mSamplersVS[samplerIndex].active = true;
- mSamplersVS[samplerIndex].textureType = (constant->type == D3DConstant::PT_SAMPLERCUBE) ? TEXTURE_CUBE : TEXTURE_2D;
- mSamplersVS[samplerIndex].logicalTextureUnit = 0;
- mUsedVertexSamplerRange = std::max(samplerIndex + 1, mUsedVertexSamplerRange);
+ mSamplersPS[samplerIndex].active = true;
+ mSamplersPS[samplerIndex].textureType = (constant.type == GL_SAMPLER_CUBE) ? TEXTURE_CUBE : TEXTURE_2D;
+ mSamplersPS[samplerIndex].logicalTextureUnit = 0;
+ mUsedPixelSamplerRange = std::max(samplerIndex + 1, mUsedPixelSamplerRange);
}
else
{
- infoLog.append("Vertex shader sampler count exceeds MAX_VERTEX_TEXTURE_IMAGE_UNITS (%d).", getContext()->getMaximumVertexTextureImageUnits());
+ infoLog.append("Pixel shader sampler count exceeds MAX_TEXTURE_IMAGE_UNITS (%d).", MAX_TEXTURE_IMAGE_UNITS);
return false;
}
}
+ else UNREACHABLE();
+
+ samplerIndex++;
}
+ while (samplerIndex < constant.registerIndex + constant.arraySize);
}
- switch(constant->typeClass)
- {
- case D3DConstant::CLASS_STRUCT:
- {
- for (unsigned int arrayIndex = 0; arrayIndex < constant->elements; arrayIndex++)
- {
- for (unsigned int field = 0; field < constant->structMembers[arrayIndex].size(); field++)
- {
- const D3DConstant *fieldConstant = constant->structMembers[arrayIndex][field];
+ Uniform *uniform = NULL;
+ GLint location = getUniformLocation(constant.name);
- std::string structIndex = (constant->elements > 1) ? ("[" + str(arrayIndex) + "]") : "";
+ if (location >= 0) // Previously defined, type and precision must match
+ {
+ uniform = mUniforms[mUniformIndex[location].index];
- if (!defineUniform(infoLog, shader, fieldConstant, name + constant->name + structIndex + "."))
- {
- return false;
- }
- }
- }
+ if (uniform->type != constant.type)
+ {
+ infoLog.append("Types for uniform %s do not match between the vertex and fragment shader", uniform->name.c_str());
+ return false;
+ }
- return true;
+ if (uniform->precision != constant.precision)
+ {
+ infoLog.append("Precisions for uniform %s do not match between the vertex and fragment shader", uniform->name.c_str());
+ return false;
}
- case D3DConstant::CLASS_SCALAR:
- case D3DConstant::CLASS_VECTOR:
- case D3DConstant::CLASS_MATRIX_COLUMNS:
- case D3DConstant::CLASS_OBJECT:
- return defineUniform(shader, constant, name + constant->name);
- default:
- UNREACHABLE();
- return false;
}
-}
-
-bool ProgramBinary::defineUniform(GLenum shader, const D3DConstant *constant, const std::string &_name)
-{
- Uniform *uniform = createUniform(constant, _name);
+ else
+ {
+ uniform = new Uniform(constant.type, constant.precision, constant.name, constant.arraySize);
+ }
- if(!uniform)
+ if (!uniform)
{
return false;
}
- // Check if already defined
- GLint location = getUniformLocation(uniform->name);
- GLenum type = uniform->type;
-
- if (location >= 0)
+ if (shader == GL_FRAGMENT_SHADER)
{
- delete uniform;
- uniform = mUniforms[mUniformIndex[location].index];
+ uniform->psRegisterIndex = constant.registerIndex;
}
-
- if (shader == GL_FRAGMENT_SHADER) uniform->ps.set(constant);
- if (shader == GL_VERTEX_SHADER) uniform->vs.set(constant);
+ else if (shader == GL_VERTEX_SHADER)
+ {
+ uniform->vsRegisterIndex = constant.registerIndex;
+ }
+ else UNREACHABLE();
if (location >= 0)
{
- return uniform->type == type;
+ return uniform->type == constant.type;
}
mUniforms.push_back(uniform);
unsigned int uniformIndex = mUniforms.size() - 1;
- for (unsigned int i = 0; i < uniform->arraySize; ++i)
+ for (unsigned int i = 0; i < uniform->elementCount(); i++)
{
- mUniformIndex.push_back(UniformLocation(_name, i, uniformIndex));
+ mUniformIndex.push_back(UniformLocation(constant.name, i, uniformIndex));
}
- return true;
-}
-
-Uniform *ProgramBinary::createUniform(const D3DConstant *constant, const std::string &_name)
-{
- if (constant->rows == 1) // Vectors and scalars
+ if (shader == GL_VERTEX_SHADER)
{
- switch (constant->type)
+ if (constant.registerIndex + uniform->registerCount > mRenderer->getReservedVertexUniformVectors() + mRenderer->getMaxVertexUniformVectors())
{
- case D3DConstant::PT_SAMPLER2D:
- switch (constant->columns)
- {
- case 1: return new Uniform(GL_SAMPLER_2D, _name, constant->elements);
- default: UNREACHABLE();
- }
- break;
- case D3DConstant::PT_SAMPLERCUBE:
- switch (constant->columns)
- {
- case 1: return new Uniform(GL_SAMPLER_CUBE, _name, constant->elements);
- default: UNREACHABLE();
- }
- break;
- case D3DConstant::PT_BOOL:
- switch (constant->columns)
- {
- case 1: return new Uniform(GL_BOOL, _name, constant->elements);
- case 2: return new Uniform(GL_BOOL_VEC2, _name, constant->elements);
- case 3: return new Uniform(GL_BOOL_VEC3, _name, constant->elements);
- case 4: return new Uniform(GL_BOOL_VEC4, _name, constant->elements);
- default: UNREACHABLE();
- }
- break;
- case D3DConstant::PT_INT:
- switch (constant->columns)
- {
- case 1: return new Uniform(GL_INT, _name, constant->elements);
- case 2: return new Uniform(GL_INT_VEC2, _name, constant->elements);
- case 3: return new Uniform(GL_INT_VEC3, _name, constant->elements);
- case 4: return new Uniform(GL_INT_VEC4, _name, constant->elements);
- default: UNREACHABLE();
- }
- break;
- case D3DConstant::PT_FLOAT:
- switch (constant->columns)
- {
- case 1: return new Uniform(GL_FLOAT, _name, constant->elements);
- case 2: return new Uniform(GL_FLOAT_VEC2, _name, constant->elements);
- case 3: return new Uniform(GL_FLOAT_VEC3, _name, constant->elements);
- case 4: return new Uniform(GL_FLOAT_VEC4, _name, constant->elements);
- default: UNREACHABLE();
- }
- break;
- default:
- UNREACHABLE();
+ infoLog.append("Vertex shader active uniforms exceed GL_MAX_VERTEX_UNIFORM_VECTORS (%u)", mRenderer->getMaxVertexUniformVectors());
+ return false;
}
}
- else if (constant->rows == constant->columns) // Square matrices
+ else if (shader == GL_FRAGMENT_SHADER)
{
- switch (constant->type)
+ if (constant.registerIndex + uniform->registerCount > mRenderer->getReservedFragmentUniformVectors() + mRenderer->getMaxFragmentUniformVectors())
{
- case D3DConstant::PT_FLOAT:
- switch (constant->rows)
- {
- case 2: return new Uniform(GL_FLOAT_MAT2, _name, constant->elements);
- case 3: return new Uniform(GL_FLOAT_MAT3, _name, constant->elements);
- case 4: return new Uniform(GL_FLOAT_MAT4, _name, constant->elements);
- default: UNREACHABLE();
- }
- break;
- default: UNREACHABLE();
+ infoLog.append("Fragment shader active uniforms exceed GL_MAX_FRAGMENT_UNIFORM_VECTORS (%u)", mRenderer->getMaxFragmentUniformVectors());
+ return false;
}
}
else UNREACHABLE();
- return 0;
+ return true;
}
-// This method needs to match OutputHLSL::decorate
-std::string ProgramBinary::decorateAttribute(const std::string &name)
+std::string ProgramBinary::generateGeometryShaderHLSL(int registers, const Varying *packing[][4], FragmentShader *fragmentShader, VertexShader *vertexShader) const
{
- if (name.compare(0, 3, "gl_") != 0 && name.compare(0, 3, "dx_") != 0)
- {
- return "_" + name;
- }
-
- return name;
+ // for now we only handle point sprite emulation
+ ASSERT(usesPointSpriteEmulation());
+ return generatePointSpriteHLSL(registers, packing, fragmentShader, vertexShader);
}
-std::string ProgramBinary::undecorateUniform(const std::string &_name)
+std::string ProgramBinary::generatePointSpriteHLSL(int registers, const Varying *packing[][4], FragmentShader *fragmentShader, VertexShader *vertexShader) const
{
- std::string name = _name;
-
- // Remove any structure field decoration
- size_t pos = 0;
- while ((pos = name.find("._", pos)) != std::string::npos)
- {
- name.replace(pos, 2, ".");
- }
+ ASSERT(registers >= 0);
+ ASSERT(vertexShader->mUsesPointSize);
+ ASSERT(mRenderer->getMajorShaderModel() >= 4);
- // Remove the leading decoration
- if (name[0] == '_')
- {
- return name.substr(1);
- }
- else if (name.compare(0, 3, "ar_") == 0)
- {
- return name.substr(3);
- }
-
- return name;
-}
+ std::string geomHLSL;
-void ProgramBinary::applyUniformnbv(Uniform *targetUniform, GLsizei count, int width, const GLboolean *v)
-{
- float vector[D3D9_MAX_FLOAT_CONSTANTS * 4];
- BOOL boolVector[D3D9_MAX_BOOL_CONSTANTS];
+ std::string varyingSemantic = "TEXCOORD";
- if (targetUniform->ps.float4Index >= 0 || targetUniform->vs.float4Index >= 0)
- {
- ASSERT(count <= D3D9_MAX_FLOAT_CONSTANTS);
- for (int i = 0; i < count; i++)
- {
- for (int j = 0; j < 4; j++)
- {
- if (j < width)
- {
- vector[i * 4 + j] = (v[i * width + j] == GL_FALSE) ? 0.0f : 1.0f;
- }
- else
- {
- vector[i * 4 + j] = 0.0f;
- }
- }
- }
- }
+ std::string fragCoordSemantic;
+ std::string pointCoordSemantic;
- if (targetUniform->ps.boolIndex >= 0 || targetUniform->vs.boolIndex >= 0)
- {
- int psCount = targetUniform->ps.boolIndex >= 0 ? targetUniform->ps.registerCount : 0;
- int vsCount = targetUniform->vs.boolIndex >= 0 ? targetUniform->vs.registerCount : 0;
- int copyCount = std::min(count * width, std::max(psCount, vsCount));
- ASSERT(copyCount <= D3D9_MAX_BOOL_CONSTANTS);
- for (int i = 0; i < copyCount; i++)
- {
- boolVector[i] = v[i] != GL_FALSE;
- }
- }
+ int reservedRegisterIndex = registers;
- if (targetUniform->ps.float4Index >= 0)
- {
- mDevice->SetPixelShaderConstantF(targetUniform->ps.float4Index, vector, targetUniform->ps.registerCount);
- }
-
- if (targetUniform->ps.boolIndex >= 0)
- {
- mDevice->SetPixelShaderConstantB(targetUniform->ps.boolIndex, boolVector, targetUniform->ps.registerCount);
- }
-
- if (targetUniform->vs.float4Index >= 0)
+ if (fragmentShader->mUsesFragCoord)
{
- mDevice->SetVertexShaderConstantF(targetUniform->vs.float4Index, vector, targetUniform->vs.registerCount);
+ fragCoordSemantic = varyingSemantic + str(reservedRegisterIndex++);
}
-
- if (targetUniform->vs.boolIndex >= 0)
+
+ if (fragmentShader->mUsesPointCoord)
{
- mDevice->SetVertexShaderConstantB(targetUniform->vs.boolIndex, boolVector, targetUniform->vs.registerCount);
+ pointCoordSemantic = varyingSemantic + str(reservedRegisterIndex++);
}
-}
-bool ProgramBinary::applyUniformnfv(Uniform *targetUniform, const GLfloat *v)
-{
- if (targetUniform->ps.registerCount)
+ geomHLSL += "uniform float4 dx_ViewCoords : register(c1);\n"
+ "\n"
+ "struct GS_INPUT\n"
+ "{\n";
+
+ for (int r = 0; r < registers; r++)
{
- mDevice->SetPixelShaderConstantF(targetUniform->ps.float4Index, v, targetUniform->ps.registerCount);
+ int registerSize = packing[r][3] ? 4 : (packing[r][2] ? 3 : (packing[r][1] ? 2 : 1));
+
+ geomHLSL += " float" + str(registerSize) + " v" + str(r) + " : " + varyingSemantic + str(r) + ";\n";
}
- if (targetUniform->vs.registerCount)
+ if (fragmentShader->mUsesFragCoord)
{
- mDevice->SetVertexShaderConstantF(targetUniform->vs.float4Index, v, targetUniform->vs.registerCount);
+ geomHLSL += " float4 gl_FragCoord : " + fragCoordSemantic + ";\n";
}
- return true;
-}
-
-bool ProgramBinary::applyUniform1iv(Uniform *targetUniform, GLsizei count, const GLint *v)
-{
- ASSERT(count <= D3D9_MAX_FLOAT_CONSTANTS);
- Vector4 vector[D3D9_MAX_FLOAT_CONSTANTS];
+ geomHLSL += " float gl_PointSize : PSIZE;\n"
+ " float4 gl_Position : SV_Position;\n"
+ "};\n"
+ "\n"
+ "struct GS_OUTPUT\n"
+ "{\n";
- for (int i = 0; i < count; i++)
+ for (int r = 0; r < registers; r++)
{
- vector[i] = Vector4((float)v[i], 0, 0, 0);
+ int registerSize = packing[r][3] ? 4 : (packing[r][2] ? 3 : (packing[r][1] ? 2 : 1));
+
+ geomHLSL += " float" + str(registerSize) + " v" + str(r) + " : " + varyingSemantic + str(r) + ";\n";
}
- if (targetUniform->ps.registerCount)
+ if (fragmentShader->mUsesFragCoord)
{
- if (targetUniform->ps.samplerIndex >= 0)
- {
- unsigned int firstIndex = targetUniform->ps.samplerIndex;
-
- for (int i = 0; i < count; i++)
- {
- unsigned int samplerIndex = firstIndex + i;
-
- if (samplerIndex < MAX_TEXTURE_IMAGE_UNITS)
- {
- ASSERT(mSamplersPS[samplerIndex].active);
- mSamplersPS[samplerIndex].logicalTextureUnit = v[i];
- }
- }
- }
- else
- {
- ASSERT(targetUniform->ps.float4Index >= 0);
- mDevice->SetPixelShaderConstantF(targetUniform->ps.float4Index, (const float*)vector, targetUniform->ps.registerCount);
- }
+ geomHLSL += " float4 gl_FragCoord : " + fragCoordSemantic + ";\n";
}
- if (targetUniform->vs.registerCount)
+ if (fragmentShader->mUsesPointCoord)
{
- if (targetUniform->vs.samplerIndex >= 0)
- {
- unsigned int firstIndex = targetUniform->vs.samplerIndex;
-
- for (int i = 0; i < count; i++)
- {
- unsigned int samplerIndex = firstIndex + i;
-
- if (samplerIndex < MAX_VERTEX_TEXTURE_IMAGE_UNITS_VTF)
- {
- ASSERT(mSamplersVS[samplerIndex].active);
- mSamplersVS[samplerIndex].logicalTextureUnit = v[i];
- }
- }
- }
- else
- {
- ASSERT(targetUniform->vs.float4Index >= 0);
- mDevice->SetVertexShaderConstantF(targetUniform->vs.float4Index, (const float *)vector, targetUniform->vs.registerCount);
- }
+ geomHLSL += " float2 gl_PointCoord : " + pointCoordSemantic + ";\n";
}
- return true;
-}
-
-bool ProgramBinary::applyUniform2iv(Uniform *targetUniform, GLsizei count, const GLint *v)
-{
- ASSERT(count <= D3D9_MAX_FLOAT_CONSTANTS);
- Vector4 vector[D3D9_MAX_FLOAT_CONSTANTS];
+ geomHLSL += " float gl_PointSize : PSIZE;\n"
+ " float4 gl_Position : SV_Position;\n"
+ "};\n"
+ "\n"
+ "static float2 pointSpriteCorners[] = \n"
+ "{\n"
+ " float2( 0.5f, -0.5f),\n"
+ " float2( 0.5f, 0.5f),\n"
+ " float2(-0.5f, -0.5f),\n"
+ " float2(-0.5f, 0.5f)\n"
+ "};\n"
+ "\n"
+ "static float2 pointSpriteTexcoords[] = \n"
+ "{\n"
+ " float2(1.0f, 1.0f),\n"
+ " float2(1.0f, 0.0f),\n"
+ " float2(0.0f, 1.0f),\n"
+ " float2(0.0f, 0.0f)\n"
+ "};\n"
+ "\n"
+ "static float minPointSize = " + str(ALIASED_POINT_SIZE_RANGE_MIN) + ".0f;\n"
+ "static float maxPointSize = " + str(mRenderer->getMaxPointSize()) + ".0f;\n"
+ "\n"
+ "[maxvertexcount(4)]\n"
+ "void main(point GS_INPUT input[1], inout TriangleStream<GS_OUTPUT> outStream)\n"
+ "{\n"
+ " GS_OUTPUT output = (GS_OUTPUT)0;\n"
+ " output.gl_PointSize = input[0].gl_PointSize;\n";
- for (int i = 0; i < count; i++)
+ for (int r = 0; r < registers; r++)
{
- vector[i] = Vector4((float)v[0], (float)v[1], 0, 0);
-
- v += 2;
+ geomHLSL += " output.v" + str(r) + " = input[0].v" + str(r) + ";\n";
}
- applyUniformniv(targetUniform, count, vector);
-
- return true;
-}
-
-bool ProgramBinary::applyUniform3iv(Uniform *targetUniform, GLsizei count, const GLint *v)
-{
- ASSERT(count <= D3D9_MAX_FLOAT_CONSTANTS);
- Vector4 vector[D3D9_MAX_FLOAT_CONSTANTS];
-
- for (int i = 0; i < count; i++)
+ if (fragmentShader->mUsesFragCoord)
{
- vector[i] = Vector4((float)v[0], (float)v[1], (float)v[2], 0);
-
- v += 3;
+ geomHLSL += " output.gl_FragCoord = input[0].gl_FragCoord;\n";
}
- applyUniformniv(targetUniform, count, vector);
-
- return true;
-}
+ geomHLSL += " \n"
+ " float gl_PointSize = clamp(input[0].gl_PointSize, minPointSize, maxPointSize);\n"
+ " float4 gl_Position = input[0].gl_Position;\n"
+ " float2 viewportScale = float2(1.0f / dx_ViewCoords.x, 1.0f / dx_ViewCoords.y) * gl_Position.w;\n";
-bool ProgramBinary::applyUniform4iv(Uniform *targetUniform, GLsizei count, const GLint *v)
-{
- ASSERT(count <= D3D9_MAX_FLOAT_CONSTANTS);
- Vector4 vector[D3D9_MAX_FLOAT_CONSTANTS];
-
- for (int i = 0; i < count; i++)
+ for (int corner = 0; corner < 4; corner++)
{
- vector[i] = Vector4((float)v[0], (float)v[1], (float)v[2], (float)v[3]);
+ geomHLSL += " \n"
+ " output.gl_Position = gl_Position + float4(pointSpriteCorners[" + str(corner) + "] * viewportScale * gl_PointSize, 0.0f, 0.0f);\n";
+
+ if (fragmentShader->mUsesPointCoord)
+ {
+ geomHLSL += " output.gl_PointCoord = pointSpriteTexcoords[" + str(corner) + "];\n";
+ }
- v += 4;
+ geomHLSL += " outStream.Append(output);\n";
}
- applyUniformniv(targetUniform, count, vector);
+ geomHLSL += " \n"
+ " outStream.RestartStrip();\n"
+ "}\n";
- return true;
+ return geomHLSL;
}
-void ProgramBinary::applyUniformniv(Uniform *targetUniform, GLsizei count, const Vector4 *vector)
+// This method needs to match OutputHLSL::decorate
+std::string ProgramBinary::decorateAttribute(const std::string &name)
{
- if (targetUniform->ps.registerCount)
- {
- ASSERT(targetUniform->ps.float4Index >= 0);
- mDevice->SetPixelShaderConstantF(targetUniform->ps.float4Index, (const float *)vector, targetUniform->ps.registerCount);
- }
-
- if (targetUniform->vs.registerCount)
+ if (name.compare(0, 3, "gl_") != 0 && name.compare(0, 3, "dx_") != 0)
{
- ASSERT(targetUniform->vs.float4Index >= 0);
- mDevice->SetVertexShaderConstantF(targetUniform->vs.float4Index, (const float *)vector, targetUniform->vs.registerCount);
+ return "_" + name;
}
+
+ return name;
}
bool ProgramBinary::isValidated() const
@@ -2507,7 +2315,7 @@ bool ProgramBinary::isValidated() const
return mValidated;
}
-void ProgramBinary::getActiveAttribute(GLuint index, GLsizei bufsize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+void ProgramBinary::getActiveAttribute(GLuint index, GLsizei bufsize, GLsizei *length, GLint *size, GLenum *type, GLchar *name) const
{
// Skip over inactive attributes
unsigned int activeAttribute = 0;
@@ -2545,7 +2353,7 @@ void ProgramBinary::getActiveAttribute(GLuint index, GLsizei bufsize, GLsizei *l
*type = mLinkedAttribute[attribute].type;
}
-GLint ProgramBinary::getActiveAttributeCount()
+GLint ProgramBinary::getActiveAttributeCount() const
{
int count = 0;
@@ -2560,7 +2368,7 @@ GLint ProgramBinary::getActiveAttributeCount()
return count;
}
-GLint ProgramBinary::getActiveAttributeMaxLength()
+GLint ProgramBinary::getActiveAttributeMaxLength() const
{
int maxLength = 0;
@@ -2575,33 +2383,15 @@ GLint ProgramBinary::getActiveAttributeMaxLength()
return maxLength;
}
-void ProgramBinary::getActiveUniform(GLuint index, GLsizei bufsize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+void ProgramBinary::getActiveUniform(GLuint index, GLsizei bufsize, GLsizei *length, GLint *size, GLenum *type, GLchar *name) const
{
- // Skip over internal uniforms
- unsigned int activeUniform = 0;
- unsigned int uniform;
- for (uniform = 0; uniform < mUniforms.size(); uniform++)
- {
- if (mUniforms[uniform]->name.compare(0, 3, "dx_") == 0)
- {
- continue;
- }
-
- if (activeUniform == index)
- {
- break;
- }
-
- activeUniform++;
- }
-
- ASSERT(uniform < mUniforms.size()); // index must be smaller than getActiveUniformCount()
+ ASSERT(index < mUniforms.size()); // index must be smaller than getActiveUniformCount()
if (bufsize > 0)
{
- std::string string = mUniforms[uniform]->name;
+ std::string string = mUniforms[index]->name;
- if (mUniforms[uniform]->isArray())
+ if (mUniforms[index]->isArray())
{
string += "[0]";
}
@@ -2615,35 +2405,24 @@ void ProgramBinary::getActiveUniform(GLuint index, GLsizei bufsize, GLsizei *len
}
}
- *size = mUniforms[uniform]->arraySize;
+ *size = mUniforms[index]->elementCount();
- *type = mUniforms[uniform]->type;
+ *type = mUniforms[index]->type;
}
-GLint ProgramBinary::getActiveUniformCount()
+GLint ProgramBinary::getActiveUniformCount() const
{
- int count = 0;
-
- unsigned int numUniforms = mUniforms.size();
- for (unsigned int uniformIndex = 0; uniformIndex < numUniforms; uniformIndex++)
- {
- if (mUniforms[uniformIndex]->name.compare(0, 3, "dx_") != 0)
- {
- count++;
- }
- }
-
- return count;
+ return mUniforms.size();
}
-GLint ProgramBinary::getActiveUniformMaxLength()
+GLint ProgramBinary::getActiveUniformMaxLength() const
{
int maxLength = 0;
unsigned int numUniforms = mUniforms.size();
for (unsigned int uniformIndex = 0; uniformIndex < numUniforms; uniformIndex++)
{
- if (!mUniforms[uniformIndex]->name.empty() && mUniforms[uniformIndex]->name.compare(0, 3, "dx_") != 0)
+ if (!mUniforms[uniformIndex]->name.empty())
{
int length = (int)(mUniforms[uniformIndex]->name.length() + 1);
if (mUniforms[uniformIndex]->isArray())
@@ -2676,10 +2455,10 @@ bool ProgramBinary::validateSamplers(InfoLog *infoLog)
// texture image unit, and this is the current program, then ValidateProgram will fail, and
// DrawArrays and DrawElements will issue the INVALID_OPERATION error.
- const unsigned int maxCombinedTextureImageUnits = getContext()->getMaximumCombinedTextureImageUnits();
- TextureType textureUnitType[MAX_COMBINED_TEXTURE_IMAGE_UNITS_VTF];
+ const unsigned int maxCombinedTextureImageUnits = mRenderer->getMaxCombinedTextureImageUnits();
+ TextureType textureUnitType[IMPLEMENTATION_MAX_COMBINED_TEXTURE_IMAGE_UNITS];
- for (unsigned int i = 0; i < MAX_COMBINED_TEXTURE_IMAGE_UNITS_VTF; ++i)
+ for (unsigned int i = 0; i < IMPLEMENTATION_MAX_COMBINED_TEXTURE_IMAGE_UNITS; ++i)
{
textureUnitType[i] = TEXTURE_UNKNOWN;
}
@@ -2694,7 +2473,7 @@ bool ProgramBinary::validateSamplers(InfoLog *infoLog)
{
if (infoLog)
{
- infoLog->append("Sampler uniform (%d) exceeds MAX_COMBINED_TEXTURE_IMAGE_UNITS (%d)", unit, maxCombinedTextureImageUnits);
+ infoLog->append("Sampler uniform (%d) exceeds IMPLEMENTATION_MAX_COMBINED_TEXTURE_IMAGE_UNITS (%d)", unit, maxCombinedTextureImageUnits);
}
return false;
@@ -2729,7 +2508,7 @@ bool ProgramBinary::validateSamplers(InfoLog *infoLog)
{
if (infoLog)
{
- infoLog->append("Sampler uniform (%d) exceeds MAX_COMBINED_TEXTURE_IMAGE_UNITS (%d)", unit, maxCombinedTextureImageUnits);
+ infoLog->append("Sampler uniform (%d) exceeds IMPLEMENTATION_MAX_COMBINED_TEXTURE_IMAGE_UNITS (%d)", unit, maxCombinedTextureImageUnits);
}
return false;
@@ -2757,38 +2536,51 @@ bool ProgramBinary::validateSamplers(InfoLog *infoLog)
return true;
}
-GLint ProgramBinary::getDxDepthRangeLocation() const
+ProgramBinary::Sampler::Sampler() : active(false), logicalTextureUnit(0), textureType(TEXTURE_2D)
{
- return mDxDepthRangeLocation;
}
-GLint ProgramBinary::getDxDepthLocation() const
+struct AttributeSorter
{
- return mDxDepthLocation;
-}
+ AttributeSorter(const int (&semanticIndices)[MAX_VERTEX_ATTRIBS])
+ : originalIndices(semanticIndices)
+ {
+ for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
+ {
+ indices[i] = i;
+ }
-GLint ProgramBinary::getDxCoordLocation() const
-{
- return mDxCoordLocation;
-}
+ std::sort(&indices[0], &indices[MAX_VERTEX_ATTRIBS], *this);
+ }
-GLint ProgramBinary::getDxHalfPixelSizeLocation() const
-{
- return mDxHalfPixelSizeLocation;
-}
+ bool operator()(int a, int b)
+ {
+ return originalIndices[a] == -1 ? false : originalIndices[a] < originalIndices[b];
+ }
-GLint ProgramBinary::getDxFrontCCWLocation() const
-{
- return mDxFrontCCWLocation;
-}
+ int indices[MAX_VERTEX_ATTRIBS];
+ const int (&originalIndices)[MAX_VERTEX_ATTRIBS];
+};
-GLint ProgramBinary::getDxPointsOrLinesLocation() const
+void ProgramBinary::sortAttributesByLayout(rx::TranslatedAttribute attributes[MAX_VERTEX_ATTRIBS], int sortedSemanticIndices[MAX_VERTEX_ATTRIBS]) const
{
- return mDxPointsOrLinesLocation;
-}
+ AttributeSorter sorter(mSemanticIndex);
-ProgramBinary::Sampler::Sampler() : active(false), logicalTextureUnit(0), textureType(TEXTURE_2D)
-{
+ int oldIndices[MAX_VERTEX_ATTRIBS];
+ rx::TranslatedAttribute oldTranslatedAttributes[MAX_VERTEX_ATTRIBS];
+
+ for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
+ {
+ oldIndices[i] = mSemanticIndex[i];
+ oldTranslatedAttributes[i] = attributes[i];
+ }
+
+ for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
+ {
+ int oldIndex = sorter.indices[i];
+ sortedSemanticIndices[i] = oldIndices[oldIndex];
+ attributes[i] = oldTranslatedAttributes[oldIndex];
+ }
}
}
diff --git a/src/3rdparty/angle/src/libGLESv2/ProgramBinary.h b/src/3rdparty/angle/src/libGLESv2/ProgramBinary.h
index 9ffe70b617..2386c0bd6f 100644
--- a/src/3rdparty/angle/src/libGLESv2/ProgramBinary.h
+++ b/src/3rdparty/angle/src/libGLESv2/ProgramBinary.h
@@ -14,71 +14,30 @@
#include <GLES2/gl2.h>
#include <GLES2/gl2ext.h>
-#include <d3dcompiler.h>
#include <string>
#include <vector>
-#include "libGLESv2/Context.h"
-#include "libGLESv2/D3DConstantTable.h"
+#include "common/RefCountObject.h"
+#include "angletypes.h"
#include "libGLESv2/mathutil.h"
+#include "libGLESv2/Uniform.h"
#include "libGLESv2/Shader.h"
+#include "libGLESv2/Constants.h"
+
+namespace rx
+{
+class ShaderExecutable;
+class Renderer;
+struct TranslatedAttribute;
+}
namespace gl
{
class FragmentShader;
class VertexShader;
-
-// Helper struct representing a single shader uniform
-struct Uniform
-{
- Uniform(GLenum type, const std::string &_name, unsigned int arraySize);
-
- ~Uniform();
-
- bool isArray();
-
- const GLenum type;
- const std::string _name; // Decorated name
- const std::string name; // Undecorated name
- const unsigned int arraySize;
-
- unsigned char *data;
- bool dirty;
-
- struct RegisterInfo
- {
- RegisterInfo()
- {
- float4Index = -1;
- samplerIndex = -1;
- boolIndex = -1;
- registerCount = 0;
- }
-
- void set(const D3DConstant *constant)
- {
- switch(constant->registerSet)
- {
- case D3DConstant::RS_BOOL: boolIndex = constant->registerIndex; break;
- case D3DConstant::RS_FLOAT4: float4Index = constant->registerIndex; break;
- case D3DConstant::RS_SAMPLER: samplerIndex = constant->registerIndex; break;
- default: UNREACHABLE();
- }
-
- ASSERT(registerCount == 0 || registerCount == (int)constant->registerCount);
- registerCount = constant->registerCount;
- }
-
- int float4Index;
- int samplerIndex;
- int boolIndex;
-
- int registerCount;
- };
-
- RegisterInfo ps;
- RegisterInfo vs;
-};
+class InfoLog;
+class AttributeBindings;
+struct Varying;
// Struct used for correlating uniforms/elements of uniform arrays to handles
struct UniformLocation
@@ -87,7 +46,7 @@ struct UniformLocation
{
}
- UniformLocation(const std::string &_name, unsigned int element, unsigned int index);
+ UniformLocation(const std::string &name, unsigned int element, unsigned int index);
std::string name;
unsigned int element;
@@ -98,11 +57,12 @@ struct UniformLocation
class ProgramBinary : public RefCountObject
{
public:
- ProgramBinary();
+ explicit ProgramBinary(rx::Renderer *renderer);
~ProgramBinary();
- IDirect3DPixelShader9 *getPixelShader();
- IDirect3DVertexShader9 *getVertexShader();
+ rx::ShaderExecutable *getPixelExecutable();
+ rx::ShaderExecutable *getVertexExecutable();
+ rx::ShaderExecutable *getGeometryExecutable();
GLuint getAttributeLocation(const char *name);
int getSemanticIndex(int attributeIndex);
@@ -111,6 +71,8 @@ class ProgramBinary : public RefCountObject
TextureType getSamplerTextureType(SamplerType type, unsigned int samplerIndex);
GLint getUsedSamplerRange(SamplerType type);
bool usesPointSize() const;
+ bool usesPointSpriteEmulation() const;
+ bool usesGeometryShader() const;
GLint getUniformLocation(std::string name);
bool setUniform1fv(GLint location, GLsizei count, const GLfloat *v);
@@ -128,13 +90,6 @@ class ProgramBinary : public RefCountObject
bool getUniformfv(GLint location, GLsizei *bufSize, GLfloat *params);
bool getUniformiv(GLint location, GLsizei *bufSize, GLint *params);
- GLint getDxDepthRangeLocation() const;
- GLint getDxDepthLocation() const;
- GLint getDxCoordLocation() const;
- GLint getDxHalfPixelSizeLocation() const;
- GLint getDxFrontCCWLocation() const;
- GLint getDxPointsOrLinesLocation() const;
-
void dirtyAllUniforms();
void applyUniforms();
@@ -145,13 +100,13 @@ class ProgramBinary : public RefCountObject
bool link(InfoLog &infoLog, const AttributeBindings &attributeBindings, FragmentShader *fragmentShader, VertexShader *vertexShader);
void getAttachedShaders(GLsizei maxCount, GLsizei *count, GLuint *shaders);
- void getActiveAttribute(GLuint index, GLsizei bufsize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
- GLint getActiveAttributeCount();
- GLint getActiveAttributeMaxLength();
+ void getActiveAttribute(GLuint index, GLsizei bufsize, GLsizei *length, GLint *size, GLenum *type, GLchar *name) const;
+ GLint getActiveAttributeCount() const;
+ GLint getActiveAttributeMaxLength() const;
- void getActiveUniform(GLuint index, GLsizei bufsize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
- GLint getActiveUniformCount();
- GLint getActiveUniformMaxLength();
+ void getActiveUniform(GLuint index, GLsizei bufsize, GLsizei *length, GLint *size, GLenum *type, GLchar *name) const;
+ GLint getActiveUniformCount() const;
+ GLint getActiveUniformMaxLength() const;
void validate(InfoLog &infoLog);
bool validateSamplers(InfoLog *infoLog);
@@ -159,39 +114,31 @@ class ProgramBinary : public RefCountObject
unsigned int getSerial() const;
+ void sortAttributesByLayout(rx::TranslatedAttribute attributes[gl::MAX_VERTEX_ATTRIBS], int sortedSemanticIndices[MAX_VERTEX_ATTRIBS]) const;
+
static std::string decorateAttribute(const std::string &name); // Prepend an underscore
- static std::string undecorateUniform(const std::string &_name); // Remove leading underscore
private:
DISALLOW_COPY_AND_ASSIGN(ProgramBinary);
- ID3D10Blob *compileToBinary(InfoLog &infoLog, const char *hlsl, const char *profile, D3DConstantTable **constantTable);
-
int packVaryings(InfoLog &infoLog, const Varying *packing[][4], FragmentShader *fragmentShader);
- bool linkVaryings(InfoLog &infoLog, std::string& pixelHLSL, std::string& vertexHLSL, FragmentShader *fragmentShader, VertexShader *vertexShader);
+ bool linkVaryings(InfoLog &infoLog, int registers, const Varying *packing[][4],
+ std::string& pixelHLSL, std::string& vertexHLSL,
+ FragmentShader *fragmentShader, VertexShader *vertexShader);
bool linkAttributes(InfoLog &infoLog, const AttributeBindings &attributeBindings, FragmentShader *fragmentShader, VertexShader *vertexShader);
- bool linkUniforms(InfoLog &infoLog, GLenum shader, D3DConstantTable *constantTable);
- bool defineUniform(InfoLog &infoLog, GLenum shader, const D3DConstant *constant, std::string name = "");
- bool defineUniform(GLenum shader, const D3DConstant *constant, const std::string &name);
- Uniform *createUniform( const D3DConstant *constant, const std::string &name);
- bool applyUniformnfv(Uniform *targetUniform, const GLfloat *v);
- bool applyUniform1iv(Uniform *targetUniform, GLsizei count, const GLint *v);
- bool applyUniform2iv(Uniform *targetUniform, GLsizei count, const GLint *v);
- bool applyUniform3iv(Uniform *targetUniform, GLsizei count, const GLint *v);
- bool applyUniform4iv(Uniform *targetUniform, GLsizei count, const GLint *v);
- void applyUniformniv(Uniform *targetUniform, GLsizei count, const Vector4 *vector);
- void applyUniformnbv(Uniform *targetUniform, GLsizei count, int width, const GLboolean *v);
+ bool linkUniforms(InfoLog &infoLog, const sh::ActiveUniforms &vertexUniforms, const sh::ActiveUniforms &fragmentUniforms);
+ bool defineUniform(GLenum shader, const sh::Uniform &constant, InfoLog &infoLog);
+
+ std::string generateGeometryShaderHLSL(int registers, const Varying *packing[][4], FragmentShader *fragmentShader, VertexShader *vertexShader) const;
+ std::string generatePointSpriteHLSL(int registers, const Varying *packing[][4], FragmentShader *fragmentShader, VertexShader *vertexShader) const;
- IDirect3DDevice9 *mDevice;
+ rx::Renderer *const mRenderer;
- IDirect3DPixelShader9 *mPixelExecutable;
- IDirect3DVertexShader9 *mVertexExecutable;
-
- // These are only used during linking.
- D3DConstantTable *mConstantTablePS;
- D3DConstantTable *mConstantTableVS;
+ rx::ShaderExecutable *mPixelExecutable;
+ rx::ShaderExecutable *mVertexExecutable;
+ rx::ShaderExecutable *mGeometryExecutable;
Attribute mLinkedAttribute[MAX_VERTEX_ATTRIBS];
int mSemanticIndex[MAX_VERTEX_ATTRIBS];
@@ -206,23 +153,15 @@ class ProgramBinary : public RefCountObject
};
Sampler mSamplersPS[MAX_TEXTURE_IMAGE_UNITS];
- Sampler mSamplersVS[MAX_VERTEX_TEXTURE_IMAGE_UNITS_VTF];
+ Sampler mSamplersVS[IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS];
GLuint mUsedVertexSamplerRange;
GLuint mUsedPixelSamplerRange;
bool mUsesPointSize;
- typedef std::vector<Uniform*> UniformArray;
UniformArray mUniforms;
typedef std::vector<UniformLocation> UniformIndex;
UniformIndex mUniformIndex;
- GLint mDxDepthRangeLocation;
- GLint mDxDepthLocation;
- GLint mDxCoordLocation;
- GLint mDxHalfPixelSizeLocation;
- GLint mDxFrontCCWLocation;
- GLint mDxPointsOrLinesLocation;
-
bool mValidated;
const unsigned int mSerial;
diff --git a/src/3rdparty/angle/src/libGLESv2/Query.cpp b/src/3rdparty/angle/src/libGLESv2/Query.cpp
index 10edda5c57..bd987954f1 100644
--- a/src/3rdparty/angle/src/libGLESv2/Query.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/Query.cpp
@@ -1,3 +1,4 @@
+#include "precompiled.h"
//
// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
@@ -7,122 +8,45 @@
// Query.cpp: Implements the gl::Query class
#include "libGLESv2/Query.h"
-
-#include "libGLESv2/main.h"
+#include "libGLESv2/renderer/QueryImpl.h"
+#include "libGLESv2/renderer/Renderer.h"
namespace gl
{
-Query::Query(GLuint id, GLenum type) : RefCountObject(id)
+Query::Query(rx::Renderer *renderer, GLenum type, GLuint id) : RefCountObject(id)
{
- mQuery = NULL;
- mStatus = GL_FALSE;
- mResult = GL_FALSE;
- mType = type;
+ mQuery = renderer->createQuery(type);
}
Query::~Query()
{
- if (mQuery != NULL)
- {
- mQuery->Release();
- mQuery = NULL;
- }
+ delete mQuery;
}
void Query::begin()
{
- if (mQuery == NULL)
- {
- if (FAILED(getDevice()->CreateQuery(D3DQUERYTYPE_OCCLUSION, &mQuery)))
- {
- return error(GL_OUT_OF_MEMORY);
- }
- }
-
- HRESULT result = mQuery->Issue(D3DISSUE_BEGIN);
- ASSERT(SUCCEEDED(result));
+ mQuery->begin();
}
void Query::end()
{
- if (mQuery == NULL)
- {
- return error(GL_INVALID_OPERATION);
- }
-
- HRESULT result = mQuery->Issue(D3DISSUE_END);
- ASSERT(SUCCEEDED(result));
-
- mStatus = GL_FALSE;
- mResult = GL_FALSE;
+ mQuery->end();
}
GLuint Query::getResult()
{
- if (mQuery != NULL)
- {
- while (!testQuery())
- {
- Sleep(0);
- // explicitly check for device loss
- // some drivers seem to return S_FALSE even if the device is lost
- // instead of D3DERR_DEVICELOST like they should
- if (gl::getDisplay()->testDeviceLost())
- {
- gl::getDisplay()->notifyDeviceLost();
- return error(GL_OUT_OF_MEMORY, 0);
- }
- }
- }
-
- return (GLuint)mResult;
+ return mQuery->getResult();
}
GLboolean Query::isResultAvailable()
{
- if (mQuery != NULL)
- {
- testQuery();
- }
-
- return mStatus;
+ return mQuery->isResultAvailable();
}
GLenum Query::getType() const
{
- return mType;
+ return mQuery->getType();
}
-GLboolean Query::testQuery()
-{
- if (mQuery != NULL && mStatus != GL_TRUE)
- {
- DWORD numPixels = 0;
-
- HRESULT hres = mQuery->GetData(&numPixels, sizeof(DWORD), D3DGETDATA_FLUSH);
- if (hres == S_OK)
- {
- mStatus = GL_TRUE;
-
- switch (mType)
- {
- case GL_ANY_SAMPLES_PASSED_EXT:
- case GL_ANY_SAMPLES_PASSED_CONSERVATIVE_EXT:
- mResult = (numPixels > 0) ? GL_TRUE : GL_FALSE;
- break;
- default:
- ASSERT(false);
- }
- }
- else if (checkDeviceLost(hres))
- {
- return error(GL_OUT_OF_MEMORY, GL_TRUE);
- }
-
- return mStatus;
- }
-
- return GL_TRUE; // prevent blocking when query is null
-}
}
diff --git a/src/3rdparty/angle/src/libGLESv2/Query.h b/src/3rdparty/angle/src/libGLESv2/Query.h
index 79357a0583..e9b95b729b 100644
--- a/src/3rdparty/angle/src/libGLESv2/Query.h
+++ b/src/3rdparty/angle/src/libGLESv2/Query.h
@@ -11,22 +11,28 @@
#define GL_APICALL
#include <GLES2/gl2.h>
-#include <d3d9.h>
#include "common/angleutils.h"
#include "common/RefCountObject.h"
+namespace rx
+{
+class Renderer;
+class QueryImpl;
+}
+
namespace gl
{
class Query : public RefCountObject
{
public:
- Query(GLuint id, GLenum type);
+ Query(rx::Renderer *renderer, GLenum type, GLuint id);
virtual ~Query();
void begin();
void end();
+
GLuint getResult();
GLboolean isResultAvailable();
@@ -35,12 +41,7 @@ class Query : public RefCountObject
private:
DISALLOW_COPY_AND_ASSIGN(Query);
- GLboolean testQuery();
-
- IDirect3DQuery9* mQuery;
- GLenum mType;
- GLboolean mStatus;
- GLint mResult;
+ rx::QueryImpl *mQuery;
};
}
diff --git a/src/3rdparty/angle/src/libGLESv2/Renderbuffer.cpp b/src/3rdparty/angle/src/libGLESv2/Renderbuffer.cpp
index 4b911e8120..127513741c 100644
--- a/src/3rdparty/angle/src/libGLESv2/Renderbuffer.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/Renderbuffer.cpp
@@ -1,5 +1,6 @@
+#include "precompiled.h"
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -9,9 +10,10 @@
// objects and related functionality. [OpenGL ES 2.0.24] section 4.4.3 page 108.
#include "libGLESv2/Renderbuffer.h"
+#include "libGLESv2/renderer/RenderTarget.h"
-#include "libGLESv2/main.h"
#include "libGLESv2/Texture.h"
+#include "libGLESv2/renderer/Renderer.h"
#include "libGLESv2/utilities.h"
namespace gl
@@ -35,32 +37,32 @@ void RenderbufferInterface::releaseProxy(const Renderbuffer *proxy)
GLuint RenderbufferInterface::getRedSize() const
{
- return dx2es::GetRedSize(getD3DFormat());
+ return gl::GetRedSize(getActualFormat());
}
GLuint RenderbufferInterface::getGreenSize() const
{
- return dx2es::GetGreenSize(getD3DFormat());
+ return gl::GetGreenSize(getActualFormat());
}
GLuint RenderbufferInterface::getBlueSize() const
{
- return dx2es::GetBlueSize(getD3DFormat());
+ return gl::GetBlueSize(getActualFormat());
}
GLuint RenderbufferInterface::getAlphaSize() const
{
- return dx2es::GetAlphaSize(getD3DFormat());
+ return gl::GetAlphaSize(getActualFormat());
}
GLuint RenderbufferInterface::getDepthSize() const
{
- return dx2es::GetDepthSize(getD3DFormat());
+ return gl::GetDepthSize(getActualFormat());
}
GLuint RenderbufferInterface::getStencilSize() const
{
- return dx2es::GetStencilSize(getD3DFormat());
+ return gl::GetStencilSize(getActualFormat());
}
///// RenderbufferTexture2D Implementation ////////
@@ -87,16 +89,12 @@ void RenderbufferTexture2D::releaseProxy(const Renderbuffer *proxy)
mTexture2D->releaseProxy(proxy);
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *RenderbufferTexture2D::getRenderTarget()
+rx::RenderTarget *RenderbufferTexture2D::getRenderTarget()
{
return mTexture2D->getRenderTarget(mTarget);
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *RenderbufferTexture2D::getDepthStencil()
+rx::RenderTarget *RenderbufferTexture2D::getDepthStencil()
{
return mTexture2D->getDepthStencil(mTarget);
}
@@ -116,9 +114,9 @@ GLenum RenderbufferTexture2D::getInternalFormat() const
return mTexture2D->getInternalFormat(0);
}
-D3DFORMAT RenderbufferTexture2D::getD3DFormat() const
+GLenum RenderbufferTexture2D::getActualFormat() const
{
- return mTexture2D->getD3DFormat(0);
+ return mTexture2D->getActualFormat(0);
}
GLsizei RenderbufferTexture2D::getSamples() const
@@ -155,16 +153,12 @@ void RenderbufferTextureCubeMap::releaseProxy(const Renderbuffer *proxy)
mTextureCubeMap->releaseProxy(proxy);
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *RenderbufferTextureCubeMap::getRenderTarget()
+rx::RenderTarget *RenderbufferTextureCubeMap::getRenderTarget()
{
return mTextureCubeMap->getRenderTarget(mTarget);
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *RenderbufferTextureCubeMap::getDepthStencil()
+rx::RenderTarget *RenderbufferTextureCubeMap::getDepthStencil()
{
return NULL;
}
@@ -184,9 +178,9 @@ GLenum RenderbufferTextureCubeMap::getInternalFormat() const
return mTextureCubeMap->getInternalFormat(GL_TEXTURE_CUBE_MAP_POSITIVE_X, 0);
}
-D3DFORMAT RenderbufferTextureCubeMap::getD3DFormat() const
+GLenum RenderbufferTextureCubeMap::getActualFormat() const
{
- return mTextureCubeMap->getD3DFormat(GL_TEXTURE_CUBE_MAP_POSITIVE_X, 0);
+ return mTextureCubeMap->getActualFormat(GL_TEXTURE_CUBE_MAP_POSITIVE_X, 0);
}
GLsizei RenderbufferTextureCubeMap::getSamples() const
@@ -201,7 +195,7 @@ unsigned int RenderbufferTextureCubeMap::getSerial() const
////// Renderbuffer Implementation //////
-Renderbuffer::Renderbuffer(GLuint id, RenderbufferInterface *instance) : RefCountObject(id)
+Renderbuffer::Renderbuffer(rx::Renderer *renderer, GLuint id, RenderbufferInterface *instance) : RefCountObject(id)
{
ASSERT(instance != NULL);
mInstance = instance;
@@ -228,16 +222,12 @@ void Renderbuffer::release() const
RefCountObject::release();
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *Renderbuffer::getRenderTarget()
+rx::RenderTarget *Renderbuffer::getRenderTarget()
{
return mInstance->getRenderTarget();
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *Renderbuffer::getDepthStencil()
+rx::RenderTarget *Renderbuffer::getDepthStencil()
{
return mInstance->getDepthStencil();
}
@@ -257,9 +247,9 @@ GLenum Renderbuffer::getInternalFormat() const
return mInstance->getInternalFormat();
}
-D3DFORMAT Renderbuffer::getD3DFormat() const
+GLenum Renderbuffer::getActualFormat() const
{
- return mInstance->getD3DFormat();
+ return mInstance->getActualFormat();
}
GLuint Renderbuffer::getRedSize() const
@@ -315,7 +305,7 @@ RenderbufferStorage::RenderbufferStorage() : mSerial(issueSerial())
mWidth = 0;
mHeight = 0;
mInternalFormat = GL_RGBA4;
- mD3DFormat = D3DFMT_A8R8G8B8;
+ mActualFormat = GL_RGBA8_OES;
mSamples = 0;
}
@@ -323,16 +313,12 @@ RenderbufferStorage::~RenderbufferStorage()
{
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *RenderbufferStorage::getRenderTarget()
+rx::RenderTarget *RenderbufferStorage::getRenderTarget()
{
return NULL;
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *RenderbufferStorage::getDepthStencil()
+rx::RenderTarget *RenderbufferStorage::getDepthStencil()
{
return NULL;
}
@@ -352,9 +338,9 @@ GLenum RenderbufferStorage::getInternalFormat() const
return mInternalFormat;
}
-D3DFORMAT RenderbufferStorage::getD3DFormat() const
+GLenum RenderbufferStorage::getActualFormat() const
{
- return mD3DFormat;
+ return mActualFormat;
}
GLsizei RenderbufferStorage::getSamples() const
@@ -379,164 +365,96 @@ unsigned int RenderbufferStorage::issueCubeSerials()
return firstSerial;
}
-Colorbuffer::Colorbuffer(IDirect3DSurface9 *renderTarget) : mRenderTarget(renderTarget)
+Colorbuffer::Colorbuffer(rx::Renderer *renderer, rx::SwapChain *swapChain)
{
- if (renderTarget)
- {
- renderTarget->AddRef();
-
- D3DSURFACE_DESC description;
- renderTarget->GetDesc(&description);
+ mRenderTarget = renderer->createRenderTarget(swapChain, false);
- mWidth = description.Width;
- mHeight = description.Height;
- mInternalFormat = dx2es::ConvertBackBufferFormat(description.Format);
- mD3DFormat = description.Format;
- mSamples = dx2es::GetSamplesFromMultisampleType(description.MultiSampleType);
+ if (mRenderTarget)
+ {
+ mWidth = mRenderTarget->getWidth();
+ mHeight = mRenderTarget->getHeight();
+ mInternalFormat = mRenderTarget->getInternalFormat();
+ mActualFormat = mRenderTarget->getActualFormat();
+ mSamples = mRenderTarget->getSamples();
}
}
-Colorbuffer::Colorbuffer(int width, int height, GLenum format, GLsizei samples) : mRenderTarget(NULL)
+Colorbuffer::Colorbuffer(rx::Renderer *renderer, int width, int height, GLenum format, GLsizei samples) : mRenderTarget(NULL)
{
- IDirect3DDevice9 *device = getDevice();
-
- D3DFORMAT requestedFormat = es2dx::ConvertRenderbufferFormat(format);
- int supportedSamples = getContext()->getNearestSupportedSamples(requestedFormat, samples);
+ mRenderTarget = renderer->createRenderTarget(width, height, format, samples, false);
- if (supportedSamples == -1)
+ if (mRenderTarget)
{
- error(GL_OUT_OF_MEMORY);
-
- return;
+ mWidth = width;
+ mHeight = height;
+ mInternalFormat = format;
+ mActualFormat = mRenderTarget->getActualFormat();
+ mSamples = mRenderTarget->getSamples();
}
-
- if (width > 0 && height > 0)
- {
- HRESULT result = device->CreateRenderTarget(width, height, requestedFormat,
- es2dx::GetMultisampleTypeFromSamples(supportedSamples), 0, FALSE, &mRenderTarget, NULL);
-
- if (result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY)
- {
- error(GL_OUT_OF_MEMORY);
-
- return;
- }
-
- ASSERT(SUCCEEDED(result));
- }
-
- mWidth = width;
- mHeight = height;
- mInternalFormat = format;
- mD3DFormat = requestedFormat;
- mSamples = supportedSamples;
}
Colorbuffer::~Colorbuffer()
{
if (mRenderTarget)
{
- mRenderTarget->Release();
+ delete mRenderTarget;
}
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *Colorbuffer::getRenderTarget()
+rx::RenderTarget *Colorbuffer::getRenderTarget()
{
if (mRenderTarget)
{
- mRenderTarget->AddRef();
+ return mRenderTarget;
}
- return mRenderTarget;
+ return NULL;
}
-DepthStencilbuffer::DepthStencilbuffer(IDirect3DSurface9 *depthStencil) : mDepthStencil(depthStencil)
+DepthStencilbuffer::DepthStencilbuffer(rx::Renderer *renderer, rx::SwapChain *swapChain)
{
- if (depthStencil)
+ mDepthStencil = renderer->createRenderTarget(swapChain, true);
+ if (mDepthStencil)
{
- depthStencil->AddRef();
-
- D3DSURFACE_DESC description;
- depthStencil->GetDesc(&description);
-
- mWidth = description.Width;
- mHeight = description.Height;
- mInternalFormat = dx2es::ConvertDepthStencilFormat(description.Format);
- mSamples = dx2es::GetSamplesFromMultisampleType(description.MultiSampleType);
- mD3DFormat = description.Format;
+ mWidth = mDepthStencil->getWidth();
+ mHeight = mDepthStencil->getHeight();
+ mInternalFormat = mDepthStencil->getInternalFormat();
+ mSamples = mDepthStencil->getSamples();
+ mActualFormat = mDepthStencil->getActualFormat();
}
}
-DepthStencilbuffer::DepthStencilbuffer(int width, int height, GLsizei samples)
+DepthStencilbuffer::DepthStencilbuffer(rx::Renderer *renderer, int width, int height, GLsizei samples)
{
- IDirect3DDevice9 *device = getDevice();
- mDepthStencil = NULL;
-
- int supportedSamples = getContext()->getNearestSupportedSamples(D3DFMT_D24S8, samples);
+ mDepthStencil = renderer->createRenderTarget(width, height, GL_DEPTH24_STENCIL8_OES, samples, true);
- if (supportedSamples == -1)
- {
- error(GL_OUT_OF_MEMORY);
-
- return;
- }
-
- if (width > 0 && height > 0)
- {
- HRESULT result = device->CreateDepthStencilSurface(width, height, D3DFMT_D24S8, es2dx::GetMultisampleTypeFromSamples(supportedSamples),
- 0, FALSE, &mDepthStencil, 0);
-
- if (result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY)
- {
- error(GL_OUT_OF_MEMORY);
-
- return;
- }
-
- ASSERT(SUCCEEDED(result));
- }
-
- mWidth = width;
- mHeight = height;
+ mWidth = mDepthStencil->getWidth();
+ mHeight = mDepthStencil->getHeight();
mInternalFormat = GL_DEPTH24_STENCIL8_OES;
- mD3DFormat = D3DFMT_D24S8;
- mSamples = supportedSamples;
+ mActualFormat = mDepthStencil->getActualFormat();
+ mSamples = mDepthStencil->getSamples();
}
DepthStencilbuffer::~DepthStencilbuffer()
{
if (mDepthStencil)
{
- mDepthStencil->Release();
+ delete mDepthStencil;
}
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *DepthStencilbuffer::getDepthStencil()
+rx::RenderTarget *DepthStencilbuffer::getDepthStencil()
{
if (mDepthStencil)
{
- mDepthStencil->AddRef();
+ return mDepthStencil;
}
- return mDepthStencil;
-}
-
-Depthbuffer::Depthbuffer(IDirect3DSurface9 *depthStencil) : DepthStencilbuffer(depthStencil)
-{
- if (depthStencil)
- {
- mInternalFormat = GL_DEPTH_COMPONENT16; // If the renderbuffer parameters are queried, the calling function
- // will expect one of the valid renderbuffer formats for use in
- // glRenderbufferStorage
- }
+ return NULL;
}
-Depthbuffer::Depthbuffer(int width, int height, GLsizei samples) : DepthStencilbuffer(width, height, samples)
+Depthbuffer::Depthbuffer(rx::Renderer *renderer, int width, int height, GLsizei samples) : DepthStencilbuffer(renderer, width, height, samples)
{
if (mDepthStencil)
{
@@ -550,17 +468,7 @@ Depthbuffer::~Depthbuffer()
{
}
-Stencilbuffer::Stencilbuffer(IDirect3DSurface9 *depthStencil) : DepthStencilbuffer(depthStencil)
-{
- if (depthStencil)
- {
- mInternalFormat = GL_STENCIL_INDEX8; // If the renderbuffer parameters are queried, the calling function
- // will expect one of the valid renderbuffer formats for use in
- // glRenderbufferStorage
- }
-}
-
-Stencilbuffer::Stencilbuffer(int width, int height, GLsizei samples) : DepthStencilbuffer(width, height, samples)
+Stencilbuffer::Stencilbuffer(rx::Renderer *renderer, int width, int height, GLsizei samples) : DepthStencilbuffer(renderer, width, height, samples)
{
if (mDepthStencil)
{
diff --git a/src/3rdparty/angle/src/libGLESv2/Renderbuffer.h b/src/3rdparty/angle/src/libGLESv2/Renderbuffer.h
index e6d5ddb875..eca2f3a780 100644
--- a/src/3rdparty/angle/src/libGLESv2/Renderbuffer.h
+++ b/src/3rdparty/angle/src/libGLESv2/Renderbuffer.h
@@ -14,11 +14,17 @@
#define GL_APICALL
#include <GLES2/gl2.h>
-#include <d3d9.h>
#include "common/angleutils.h"
#include "common/RefCountObject.h"
+namespace rx
+{
+class Renderer;
+class SwapChain;
+class RenderTarget;
+}
+
namespace gl
{
class Texture2D;
@@ -37,13 +43,13 @@ class RenderbufferInterface
virtual void addProxyRef(const Renderbuffer *proxy);
virtual void releaseProxy(const Renderbuffer *proxy);
- virtual IDirect3DSurface9 *getRenderTarget() = 0;
- virtual IDirect3DSurface9 *getDepthStencil() = 0;
+ virtual rx::RenderTarget *getRenderTarget() = 0;
+ virtual rx::RenderTarget *getDepthStencil() = 0;
virtual GLsizei getWidth() const = 0;
virtual GLsizei getHeight() const = 0;
virtual GLenum getInternalFormat() const = 0;
- virtual D3DFORMAT getD3DFormat() const = 0;
+ virtual GLenum getActualFormat() const = 0;
virtual GLsizei getSamples() const = 0;
GLuint getRedSize() const;
@@ -69,13 +75,13 @@ class RenderbufferTexture2D : public RenderbufferInterface
void addProxyRef(const Renderbuffer *proxy);
void releaseProxy(const Renderbuffer *proxy);
- IDirect3DSurface9 *getRenderTarget();
- IDirect3DSurface9 *getDepthStencil();
+ rx::RenderTarget *getRenderTarget();
+ rx::RenderTarget *getDepthStencil();
virtual GLsizei getWidth() const;
virtual GLsizei getHeight() const;
virtual GLenum getInternalFormat() const;
- virtual D3DFORMAT getD3DFormat() const;
+ virtual GLenum getActualFormat() const;
virtual GLsizei getSamples() const;
virtual unsigned int getSerial() const;
@@ -97,13 +103,13 @@ class RenderbufferTextureCubeMap : public RenderbufferInterface
void addProxyRef(const Renderbuffer *proxy);
void releaseProxy(const Renderbuffer *proxy);
- IDirect3DSurface9 *getRenderTarget();
- IDirect3DSurface9 *getDepthStencil();
+ rx::RenderTarget *getRenderTarget();
+ rx::RenderTarget *getDepthStencil();
virtual GLsizei getWidth() const;
virtual GLsizei getHeight() const;
virtual GLenum getInternalFormat() const;
- virtual D3DFORMAT getD3DFormat() const;
+ virtual GLenum getActualFormat() const;
virtual GLsizei getSamples() const;
virtual unsigned int getSerial() const;
@@ -125,13 +131,13 @@ class RenderbufferStorage : public RenderbufferInterface
virtual ~RenderbufferStorage() = 0;
- virtual IDirect3DSurface9 *getRenderTarget();
- virtual IDirect3DSurface9 *getDepthStencil();
+ virtual rx::RenderTarget *getRenderTarget();
+ virtual rx::RenderTarget *getDepthStencil();
virtual GLsizei getWidth() const;
virtual GLsizei getHeight() const;
virtual GLenum getInternalFormat() const;
- virtual D3DFORMAT getD3DFormat() const;
+ virtual GLenum getActualFormat() const;
virtual GLsizei getSamples() const;
virtual unsigned int getSerial() const;
@@ -143,7 +149,7 @@ class RenderbufferStorage : public RenderbufferInterface
GLsizei mWidth;
GLsizei mHeight;
GLenum mInternalFormat;
- D3DFORMAT mD3DFormat;
+ GLenum mActualFormat;
GLsizei mSamples;
private:
@@ -160,7 +166,7 @@ class RenderbufferStorage : public RenderbufferInterface
class Renderbuffer : public RefCountObject
{
public:
- Renderbuffer(GLuint id, RenderbufferInterface *storage);
+ Renderbuffer(rx::Renderer *renderer, GLuint id, RenderbufferInterface *storage);
virtual ~Renderbuffer();
@@ -171,13 +177,13 @@ class Renderbuffer : public RefCountObject
void addRef() const;
void release() const;
- IDirect3DSurface9 *getRenderTarget();
- IDirect3DSurface9 *getDepthStencil();
+ rx::RenderTarget *getRenderTarget();
+ rx::RenderTarget *getDepthStencil();
GLsizei getWidth() const;
GLsizei getHeight() const;
GLenum getInternalFormat() const;
- D3DFORMAT getD3DFormat() const;
+ GLenum getActualFormat() const;
GLuint getRedSize() const;
GLuint getGreenSize() const;
GLuint getBlueSize() const;
@@ -199,31 +205,31 @@ class Renderbuffer : public RefCountObject
class Colorbuffer : public RenderbufferStorage
{
public:
- explicit Colorbuffer(IDirect3DSurface9 *renderTarget);
- Colorbuffer(GLsizei width, GLsizei height, GLenum format, GLsizei samples);
+ Colorbuffer(rx::Renderer *renderer, rx::SwapChain *swapChain);
+ Colorbuffer(rx::Renderer *renderer, GLsizei width, GLsizei height, GLenum format, GLsizei samples);
virtual ~Colorbuffer();
- virtual IDirect3DSurface9 *getRenderTarget();
+ virtual rx::RenderTarget *getRenderTarget();
private:
DISALLOW_COPY_AND_ASSIGN(Colorbuffer);
- IDirect3DSurface9 *mRenderTarget;
+ rx::RenderTarget *mRenderTarget;
};
class DepthStencilbuffer : public RenderbufferStorage
{
public:
- explicit DepthStencilbuffer(IDirect3DSurface9 *depthStencil);
- DepthStencilbuffer(GLsizei width, GLsizei height, GLsizei samples);
+ DepthStencilbuffer(rx::Renderer *renderer, rx::SwapChain *swapChain);
+ DepthStencilbuffer(rx::Renderer *renderer, GLsizei width, GLsizei height, GLsizei samples);
~DepthStencilbuffer();
- virtual IDirect3DSurface9 *getDepthStencil();
+ virtual rx::RenderTarget *getDepthStencil();
protected:
- IDirect3DSurface9 *mDepthStencil;
+ rx::RenderTarget *mDepthStencil;
private:
DISALLOW_COPY_AND_ASSIGN(DepthStencilbuffer);
@@ -232,8 +238,7 @@ class DepthStencilbuffer : public RenderbufferStorage
class Depthbuffer : public DepthStencilbuffer
{
public:
- explicit Depthbuffer(IDirect3DSurface9 *depthStencil);
- Depthbuffer(GLsizei width, GLsizei height, GLsizei samples);
+ Depthbuffer(rx::Renderer *renderer, GLsizei width, GLsizei height, GLsizei samples);
virtual ~Depthbuffer();
@@ -244,8 +249,7 @@ class Depthbuffer : public DepthStencilbuffer
class Stencilbuffer : public DepthStencilbuffer
{
public:
- explicit Stencilbuffer(IDirect3DSurface9 *depthStencil);
- Stencilbuffer(GLsizei width, GLsizei height, GLsizei samples);
+ Stencilbuffer(rx::Renderer *renderer, GLsizei width, GLsizei height, GLsizei samples);
virtual ~Stencilbuffer();
diff --git a/src/3rdparty/angle/src/libGLESv2/ResourceManager.cpp b/src/3rdparty/angle/src/libGLESv2/ResourceManager.cpp
index 4b97e9c113..58dd44fd95 100644
--- a/src/3rdparty/angle/src/libGLESv2/ResourceManager.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/ResourceManager.cpp
@@ -1,3 +1,4 @@
+#include "precompiled.h"
//
// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
@@ -17,9 +18,10 @@
namespace gl
{
-ResourceManager::ResourceManager()
+ResourceManager::ResourceManager(rx::Renderer *renderer)
{
mRefCount = 1;
+ mRenderer = renderer;
}
ResourceManager::~ResourceManager()
@@ -80,11 +82,11 @@ GLuint ResourceManager::createShader(GLenum type)
if (type == GL_VERTEX_SHADER)
{
- mShaderMap[handle] = new VertexShader(this, handle);
+ mShaderMap[handle] = new VertexShader(this, mRenderer, handle);
}
else if (type == GL_FRAGMENT_SHADER)
{
- mShaderMap[handle] = new FragmentShader(this, handle);
+ mShaderMap[handle] = new FragmentShader(this, mRenderer, handle);
}
else UNREACHABLE();
@@ -96,7 +98,7 @@ GLuint ResourceManager::createProgram()
{
GLuint handle = mProgramShaderHandleAllocator.allocate();
- mProgramMap[handle] = new Program(this, handle);
+ mProgramMap[handle] = new Program(mRenderer, this, handle);
return handle;
}
@@ -276,7 +278,7 @@ void ResourceManager::checkBufferAllocation(unsigned int buffer)
{
if (buffer != 0 && !getBuffer(buffer))
{
- Buffer *bufferObject = new Buffer(buffer);
+ Buffer *bufferObject = new Buffer(mRenderer, buffer);
mBufferMap[buffer] = bufferObject;
bufferObject->addRef();
}
@@ -290,11 +292,11 @@ void ResourceManager::checkTextureAllocation(GLuint texture, TextureType type)
if (type == TEXTURE_2D)
{
- textureObject = new Texture2D(texture);
+ textureObject = new Texture2D(mRenderer, texture);
}
else if (type == TEXTURE_CUBE)
{
- textureObject = new TextureCubeMap(texture);
+ textureObject = new TextureCubeMap(mRenderer, texture);
}
else
{
@@ -311,7 +313,7 @@ void ResourceManager::checkRenderbufferAllocation(GLuint renderbuffer)
{
if (renderbuffer != 0 && !getRenderbuffer(renderbuffer))
{
- Renderbuffer *renderbufferObject = new Renderbuffer(renderbuffer, new Colorbuffer(0, 0, GL_RGBA4, 0));
+ Renderbuffer *renderbufferObject = new Renderbuffer(mRenderer, renderbuffer, new Colorbuffer(mRenderer, 0, 0, GL_RGBA4, 0));
mRenderbufferMap[renderbuffer] = renderbufferObject;
renderbufferObject->addRef();
}
diff --git a/src/3rdparty/angle/src/libGLESv2/ResourceManager.h b/src/3rdparty/angle/src/libGLESv2/ResourceManager.h
index ae4f1b04a5..e99c77c35d 100644
--- a/src/3rdparty/angle/src/libGLESv2/ResourceManager.h
+++ b/src/3rdparty/angle/src/libGLESv2/ResourceManager.h
@@ -20,8 +20,14 @@
#endif
#include "common/angleutils.h"
+#include "libGLESv2/angletypes.h"
#include "libGLESv2/HandleAllocator.h"
+namespace rx
+{
+class Renderer;
+}
+
namespace gl
{
class Buffer;
@@ -30,25 +36,10 @@ class Program;
class Texture;
class Renderbuffer;
-enum TextureType
-{
- TEXTURE_2D,
- TEXTURE_CUBE,
-
- TEXTURE_TYPE_COUNT,
- TEXTURE_UNKNOWN
-};
-
-enum SamplerType
-{
- SAMPLER_PIXEL,
- SAMPLER_VERTEX
-};
-
class ResourceManager
{
public:
- ResourceManager();
+ explicit ResourceManager(rx::Renderer *renderer);
~ResourceManager();
void addRef();
@@ -82,6 +73,7 @@ class ResourceManager
DISALLOW_COPY_AND_ASSIGN(ResourceManager);
std::size_t mRefCount;
+ rx::Renderer *mRenderer;
#ifndef HASH_MAP
# ifdef _MSC_VER
diff --git a/src/3rdparty/angle/src/libGLESv2/Shader.cpp b/src/3rdparty/angle/src/libGLESv2/Shader.cpp
index 1087f11b4a..abddab427b 100644
--- a/src/3rdparty/angle/src/libGLESv2/Shader.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/Shader.cpp
@@ -1,5 +1,6 @@
+#include "precompiled.h"
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -10,18 +11,19 @@
#include "libGLESv2/Shader.h"
-#include <string>
-
#include "GLSLANG/ShaderLang.h"
-#include "libGLESv2/main.h"
#include "libGLESv2/utilities.h"
+#include "libGLESv2/renderer/Renderer.h"
+#include "libGLESv2/Constants.h"
+#include "libGLESv2/ResourceManager.h"
namespace gl
{
void *Shader::mFragmentCompiler = NULL;
void *Shader::mVertexCompiler = NULL;
-Shader::Shader(ResourceManager *manager, GLuint handle) : mHandle(handle), mResourceManager(manager)
+Shader::Shader(ResourceManager *manager, const rx::Renderer *renderer, GLuint handle)
+ : mHandle(handle), mRenderer(renderer), mResourceManager(manager)
{
mSource = NULL;
mHlsl = NULL;
@@ -174,6 +176,11 @@ void Shader::getTranslatedSource(GLsizei bufSize, GLsizei *length, char *buffer)
getSourceImpl(mHlsl, bufSize, length, buffer);
}
+const sh::ActiveUniforms &Shader::getUniforms()
+{
+ return mActiveUniforms;
+}
+
bool Shader::isCompiled()
{
return mHlsl != NULL;
@@ -223,23 +230,26 @@ void Shader::initializeCompiler()
if (result)
{
+ ShShaderOutput hlslVersion = (mRenderer->getMajorShaderModel() >= 4) ? SH_HLSL11_OUTPUT : SH_HLSL9_OUTPUT;
+
ShBuiltInResources resources;
ShInitBuiltInResources(&resources);
- Context *context = getContext();
resources.MaxVertexAttribs = MAX_VERTEX_ATTRIBS;
- resources.MaxVertexUniformVectors = MAX_VERTEX_UNIFORM_VECTORS;
- resources.MaxVaryingVectors = context->getMaximumVaryingVectors();
- resources.MaxVertexTextureImageUnits = context->getMaximumVertexTextureImageUnits();
- resources.MaxCombinedTextureImageUnits = context->getMaximumCombinedTextureImageUnits();
+ resources.MaxVertexUniformVectors = mRenderer->getMaxVertexUniformVectors();
+ resources.MaxVaryingVectors = mRenderer->getMaxVaryingVectors();
+ resources.MaxVertexTextureImageUnits = mRenderer->getMaxVertexTextureImageUnits();
+ resources.MaxCombinedTextureImageUnits = mRenderer->getMaxCombinedTextureImageUnits();
resources.MaxTextureImageUnits = MAX_TEXTURE_IMAGE_UNITS;
- resources.MaxFragmentUniformVectors = context->getMaximumFragmentUniformVectors();
- resources.MaxDrawBuffers = MAX_DRAW_BUFFERS;
- resources.OES_standard_derivatives = 1;
- // resources.OES_EGL_image_external = getDisplay()->isD3d9ExDevice() ? 1 : 0; // TODO: commented out until the extension is actually supported.
-
- mFragmentCompiler = ShConstructCompiler(SH_FRAGMENT_SHADER, SH_GLES2_SPEC, SH_HLSL_OUTPUT, &resources);
- mVertexCompiler = ShConstructCompiler(SH_VERTEX_SHADER, SH_GLES2_SPEC, SH_HLSL_OUTPUT, &resources);
+ resources.MaxFragmentUniformVectors = mRenderer->getMaxFragmentUniformVectors();
+ resources.MaxDrawBuffers = mRenderer->getMaxRenderTargets();
+ resources.OES_standard_derivatives = mRenderer->getDerivativeInstructionSupport();
+ resources.EXT_draw_buffers = mRenderer->getMaxRenderTargets() > 1;
+ // resources.OES_EGL_image_external = mRenderer->getShareHandleSupport() ? 1 : 0; // TODO: commented out until the extension is actually supported.
+ resources.FragmentPrecisionHigh = 1; // Shader Model 2+ always supports FP24 (s16e7) which corresponds to highp
+
+ mFragmentCompiler = ShConstructCompiler(SH_FRAGMENT_SHADER, SH_GLES2_SPEC, hlslVersion, &resources);
+ mVertexCompiler = ShConstructCompiler(SH_VERTEX_SHADER, SH_GLES2_SPEC, hlslVersion, &resources);
}
}
}
@@ -287,6 +297,9 @@ void Shader::parseVaryings()
input = strstr(input, ";") + 2;
}
+ mUsesMultipleRenderTargets = strstr(mHlsl, "GL_USES_MRT") != NULL;
+ mUsesFragColor = strstr(mHlsl, "GL_USES_FRAG_COLOR") != NULL;
+ mUsesFragData = strstr(mHlsl, "GL_USES_FRAG_DATA") != NULL;
mUsesFragCoord = strstr(mHlsl, "GL_USES_FRAG_COORD") != NULL;
mUsesFrontFacing = strstr(mHlsl, "GL_USES_FRONT_FACING") != NULL;
mUsesPointSize = strstr(mHlsl, "GL_USES_POINT_SIZE") != NULL;
@@ -294,6 +307,15 @@ void Shader::parseVaryings()
}
}
+void Shader::resetVaryingsRegisterAssignment()
+{
+ for (VaryingList::iterator var = mVaryings.begin(); var != mVaryings.end(); var++)
+ {
+ var->reg = -1;
+ var->col = -1;
+ }
+}
+
// initialize/clean up previous state
void Shader::uncompile()
{
@@ -306,16 +328,21 @@ void Shader::uncompile()
// set by parseVaryings
mVaryings.clear();
+ mUsesMultipleRenderTargets = false;
+ mUsesFragColor = false;
+ mUsesFragData = false;
mUsesFragCoord = false;
mUsesFrontFacing = false;
mUsesPointSize = false;
mUsesPointCoord = false;
+
+ mActiveUniforms.clear();
}
void Shader::compileToHLSL(void *compiler)
{
// ensure we don't pass a NULL source to the compiler
- char *source = "\0";
+ const char *source = "\0";
if (mSource)
{
source = mSource;
@@ -351,14 +378,18 @@ void Shader::compileToHLSL(void *compiler)
if (result)
{
- int objCodeLen = 0;
+ size_t objCodeLen = 0;
ShGetInfo(compiler, SH_OBJECT_CODE_LENGTH, &objCodeLen);
mHlsl = new char[objCodeLen];
ShGetObjectCode(compiler, mHlsl);
+
+ void *activeUniforms;
+ ShGetInfoPointer(compiler, SH_ACTIVE_UNIFORMS_ARRAY, &activeUniforms);
+ mActiveUniforms = *(sh::ActiveUniforms*)activeUniforms;
}
else
{
- int infoLogLen = 0;
+ size_t infoLogLen = 0;
ShGetInfo(compiler, SH_INFO_LOG_LENGTH, &infoLogLen);
mInfoLog = new char[infoLogLen];
ShGetInfoLog(compiler, mInfoLog);
@@ -485,7 +516,8 @@ bool Shader::compareVarying(const Varying &x, const Varying &y)
return false;
}
-VertexShader::VertexShader(ResourceManager *manager, GLuint handle) : Shader(manager, handle)
+VertexShader::VertexShader(ResourceManager *manager, const rx::Renderer *renderer, GLuint handle)
+ : Shader(manager, renderer, handle)
{
}
@@ -504,7 +536,7 @@ void VertexShader::uncompile()
// set by ParseAttributes
mAttributes.clear();
-};
+}
void VertexShader::compile()
{
@@ -560,7 +592,8 @@ void VertexShader::parseAttributes()
}
}
-FragmentShader::FragmentShader(ResourceManager *manager, GLuint handle) : Shader(manager, handle)
+FragmentShader::FragmentShader(ResourceManager *manager, const rx::Renderer *renderer, GLuint handle)
+ : Shader(manager, renderer, handle)
{
}
diff --git a/src/3rdparty/angle/src/libGLESv2/Shader.h b/src/3rdparty/angle/src/libGLESv2/Shader.h
index b73fc288a1..f471968550 100644
--- a/src/3rdparty/angle/src/libGLESv2/Shader.h
+++ b/src/3rdparty/angle/src/libGLESv2/Shader.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -18,10 +18,18 @@
#include <list>
#include <vector>
-#include "libGLESv2/ResourceManager.h"
+#include "compiler/Uniform.h"
+#include "common/angleutils.h"
+
+namespace rx
+{
+class Renderer;
+}
namespace gl
{
+class ResourceManager;
+
struct Varying
{
Varying(GLenum type, const std::string &name, int size, bool array)
@@ -45,7 +53,7 @@ class Shader
friend class ProgramBinary;
public:
- Shader(ResourceManager *manager, GLuint handle);
+ Shader(ResourceManager *manager, const rx::Renderer *renderer, GLuint handle);
virtual ~Shader();
@@ -60,6 +68,7 @@ class Shader
void getSource(GLsizei bufSize, GLsizei *length, char *buffer);
int getTranslatedSourceLength() const;
void getTranslatedSource(GLsizei bufSize, GLsizei *length, char *buffer);
+ const sh::ActiveUniforms &getUniforms();
virtual void compile() = 0;
virtual void uncompile();
@@ -76,6 +85,7 @@ class Shader
protected:
void parseVaryings();
+ void resetVaryingsRegisterAssignment();
void compileToHLSL(void *compiler);
@@ -84,8 +94,13 @@ class Shader
static GLenum parseType(const std::string &type);
static bool compareVarying(const Varying &x, const Varying &y);
+ const rx::Renderer *const mRenderer;
+
VaryingList mVaryings;
+ bool mUsesMultipleRenderTargets;
+ bool mUsesFragColor;
+ bool mUsesFragData;
bool mUsesFragCoord;
bool mUsesFrontFacing;
bool mUsesPointSize;
@@ -106,6 +121,7 @@ class Shader
char *mSource;
char *mHlsl;
char *mInfoLog;
+ sh::ActiveUniforms mActiveUniforms;
ResourceManager *mResourceManager;
};
@@ -131,7 +147,7 @@ class VertexShader : public Shader
friend class ProgramBinary;
public:
- VertexShader(ResourceManager *manager, GLuint handle);
+ VertexShader(ResourceManager *manager, const rx::Renderer *renderer, GLuint handle);
~VertexShader();
@@ -151,7 +167,7 @@ class VertexShader : public Shader
class FragmentShader : public Shader
{
public:
- FragmentShader(ResourceManager *manager, GLuint handle);
+ FragmentShader(ResourceManager *manager,const rx::Renderer *renderer, GLuint handle);
~FragmentShader();
diff --git a/src/3rdparty/angle/src/libGLESv2/Texture.cpp b/src/3rdparty/angle/src/libGLESv2/Texture.cpp
index 0ea475d088..461357a1ce 100644
--- a/src/3rdparty/angle/src/libGLESv2/Texture.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/Texture.cpp
@@ -1,5 +1,6 @@
+#include "precompiled.h"
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -10,1320 +11,34 @@
#include "libGLESv2/Texture.h"
-#include <algorithm>
-
-#include "common/debug.h"
-
-#include "libEGL/Display.h"
-
#include "libGLESv2/main.h"
#include "libGLESv2/mathutil.h"
#include "libGLESv2/utilities.h"
-#include "libGLESv2/Blit.h"
-#include "libGLESv2/Framebuffer.h"
-
-namespace gl
-{
-unsigned int TextureStorage::mCurrentTextureSerial = 1;
-
-static D3DFORMAT ConvertTextureInternalFormat(GLint internalformat)
-{
- switch (internalformat)
- {
- case GL_DEPTH_COMPONENT16:
- case GL_DEPTH_COMPONENT32_OES:
- case GL_DEPTH24_STENCIL8_OES:
- return D3DFMT_INTZ;
- case GL_COMPRESSED_RGB_S3TC_DXT1_EXT:
- case GL_COMPRESSED_RGBA_S3TC_DXT1_EXT:
- return D3DFMT_DXT1;
- case GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE:
- return D3DFMT_DXT3;
- case GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE:
- return D3DFMT_DXT5;
- case GL_RGBA32F_EXT:
- case GL_RGB32F_EXT:
- case GL_ALPHA32F_EXT:
- case GL_LUMINANCE32F_EXT:
- case GL_LUMINANCE_ALPHA32F_EXT:
- return D3DFMT_A32B32G32R32F;
- case GL_RGBA16F_EXT:
- case GL_RGB16F_EXT:
- case GL_ALPHA16F_EXT:
- case GL_LUMINANCE16F_EXT:
- case GL_LUMINANCE_ALPHA16F_EXT:
- return D3DFMT_A16B16G16R16F;
- case GL_LUMINANCE8_EXT:
- if (getContext()->supportsLuminanceTextures())
- {
- return D3DFMT_L8;
- }
- break;
- case GL_LUMINANCE8_ALPHA8_EXT:
- if (getContext()->supportsLuminanceAlphaTextures())
- {
- return D3DFMT_A8L8;
- }
- break;
- case GL_RGB8_OES:
- case GL_RGB565:
- return D3DFMT_X8R8G8B8;
- }
-
- return D3DFMT_A8R8G8B8;
-}
-
-static bool IsTextureFormatRenderable(D3DFORMAT format)
-{
- if (format == D3DFMT_INTZ)
- {
- return true;
- }
- switch(format)
- {
- case D3DFMT_L8:
- case D3DFMT_A8L8:
- case D3DFMT_DXT1:
- case D3DFMT_DXT3:
- case D3DFMT_DXT5:
- return false;
- case D3DFMT_A8R8G8B8:
- case D3DFMT_X8R8G8B8:
- case D3DFMT_A16B16G16R16F:
- case D3DFMT_A32B32G32R32F:
- return true;
- default:
- UNREACHABLE();
- }
-
- return false;
-}
-
-static inline DWORD GetTextureUsage(D3DFORMAT d3dfmt, GLenum glusage, bool forceRenderable)
-{
- DWORD d3dusage = 0;
-
- if (d3dfmt == D3DFMT_INTZ)
- {
- d3dusage |= D3DUSAGE_DEPTHSTENCIL;
- }
- else if(forceRenderable || (IsTextureFormatRenderable(d3dfmt) && (glusage == GL_FRAMEBUFFER_ATTACHMENT_ANGLE)))
- {
- d3dusage |= D3DUSAGE_RENDERTARGET;
- }
- return d3dusage;
-}
-
-static void MakeValidSize(bool isImage, bool isCompressed, GLsizei *requestWidth, GLsizei *requestHeight, int *levelOffset)
-{
- int upsampleCount = 0;
-
- if (isCompressed)
- {
- // Don't expand the size of full textures that are at least 4x4
- // already.
- if (isImage || *requestWidth < 4 || *requestHeight < 4)
- {
- while (*requestWidth % 4 != 0 || *requestHeight % 4 != 0)
- {
- *requestWidth <<= 1;
- *requestHeight <<= 1;
- upsampleCount++;
- }
- }
- }
- *levelOffset = upsampleCount;
-}
-
-static void CopyLockableSurfaces(IDirect3DSurface9 *dest, IDirect3DSurface9 *source)
-{
- D3DLOCKED_RECT sourceLock = {0};
- D3DLOCKED_RECT destLock = {0};
-
- source->LockRect(&sourceLock, NULL, 0);
- dest->LockRect(&destLock, NULL, 0);
-
- if (sourceLock.pBits && destLock.pBits)
- {
- D3DSURFACE_DESC desc;
- source->GetDesc(&desc);
-
- int rows = dx::IsCompressedFormat(desc.Format) ? desc.Height / 4 : desc.Height;
- int bytes = dx::ComputeRowSize(desc.Format, desc.Width);
- ASSERT(bytes <= sourceLock.Pitch && bytes <= destLock.Pitch);
-
- for(int i = 0; i < rows; i++)
- {
- memcpy((char*)destLock.pBits + destLock.Pitch * i, (char*)sourceLock.pBits + sourceLock.Pitch * i, bytes);
- }
-
- source->UnlockRect();
- dest->UnlockRect();
- }
- else UNREACHABLE();
-}
-
-Image::Image()
-{
- mWidth = 0;
- mHeight = 0;
- mInternalFormat = GL_NONE;
-
- mSurface = NULL;
-
- mDirty = false;
-
- mD3DPool = D3DPOOL_SYSTEMMEM;
- mD3DFormat = D3DFMT_UNKNOWN;
-}
-
-Image::~Image()
-{
- if (mSurface)
- {
- mSurface->Release();
- }
-}
-
-bool Image::redefine(GLint internalformat, GLsizei width, GLsizei height, bool forceRelease)
-{
- if (mWidth != width ||
- mHeight != height ||
- mInternalFormat != internalformat ||
- forceRelease)
- {
- mWidth = width;
- mHeight = height;
- mInternalFormat = internalformat;
- // compute the d3d format that will be used
- mD3DFormat = ConvertTextureInternalFormat(internalformat);
-
- if (mSurface)
- {
- mSurface->Release();
- mSurface = NULL;
- }
-
- return true;
- }
-
- return false;
-}
-
-void Image::createSurface()
-{
- if(mSurface)
- {
- return;
- }
-
- IDirect3DTexture9 *newTexture = NULL;
- IDirect3DSurface9 *newSurface = NULL;
- const D3DPOOL poolToUse = D3DPOOL_SYSTEMMEM;
- const D3DFORMAT d3dFormat = getD3DFormat();
- ASSERT(d3dFormat != D3DFMT_INTZ); // We should never get here for depth textures
-
- if (mWidth != 0 && mHeight != 0)
- {
- int levelToFetch = 0;
- GLsizei requestWidth = mWidth;
- GLsizei requestHeight = mHeight;
- MakeValidSize(true, IsCompressed(mInternalFormat), &requestWidth, &requestHeight, &levelToFetch);
-
- HRESULT result = getDevice()->CreateTexture(requestWidth, requestHeight, levelToFetch + 1, NULL, d3dFormat,
- poolToUse, &newTexture, NULL);
-
- if (FAILED(result))
- {
- ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
- ERR("Creating image surface failed.");
- return error(GL_OUT_OF_MEMORY);
- }
-
- newTexture->GetSurfaceLevel(levelToFetch, &newSurface);
- newTexture->Release();
- }
-
- mSurface = newSurface;
- mDirty = false;
- mD3DPool = poolToUse;
-}
-
-HRESULT Image::lock(D3DLOCKED_RECT *lockedRect, const RECT *rect)
-{
- createSurface();
-
- HRESULT result = D3DERR_INVALIDCALL;
-
- if (mSurface)
- {
- result = mSurface->LockRect(lockedRect, rect, 0);
- ASSERT(SUCCEEDED(result));
-
- mDirty = true;
- }
-
- return result;
-}
-
-void Image::unlock()
-{
- if (mSurface)
- {
- HRESULT result = mSurface->UnlockRect();
- ASSERT(SUCCEEDED(result));
- }
-}
-
-bool Image::isRenderableFormat() const
-{
- return IsTextureFormatRenderable(getD3DFormat());
-}
-
-D3DFORMAT Image::getD3DFormat() const
-{
- // this should only happen if the image hasn't been redefined first
- // which would be a bug by the caller
- ASSERT(mD3DFormat != D3DFMT_UNKNOWN);
-
- return mD3DFormat;
-}
-
-IDirect3DSurface9 *Image::getSurface()
-{
- createSurface();
-
- return mSurface;
-}
-
-void Image::setManagedSurface(IDirect3DSurface9 *surface)
-{
- D3DSURFACE_DESC desc;
- surface->GetDesc(&desc);
- ASSERT(desc.Pool == D3DPOOL_MANAGED);
-
- if ((GLsizei)desc.Width == mWidth && (GLsizei)desc.Height == mHeight)
- {
- if (mSurface)
- {
- CopyLockableSurfaces(surface, mSurface);
- mSurface->Release();
- }
-
- mSurface = surface;
- mD3DPool = desc.Pool;
- }
-}
-
-void Image::updateSurface(IDirect3DSurface9 *destSurface, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height)
-{
- IDirect3DSurface9 *sourceSurface = getSurface();
-
- if (sourceSurface && sourceSurface != destSurface)
- {
- RECT rect;
- rect.left = xoffset;
- rect.top = yoffset;
- rect.right = xoffset + width;
- rect.bottom = yoffset + height;
-
- POINT point = {rect.left, rect.top};
-
- if (mD3DPool == D3DPOOL_MANAGED)
- {
- D3DSURFACE_DESC desc;
- sourceSurface->GetDesc(&desc);
-
- IDirect3DSurface9 *surf = 0;
- HRESULT result = getDevice()->CreateOffscreenPlainSurface(desc.Width, desc.Height, desc.Format, D3DPOOL_SYSTEMMEM, &surf, NULL);
-
- if (SUCCEEDED(result))
- {
- CopyLockableSurfaces(surf, sourceSurface);
- result = getDevice()->UpdateSurface(surf, &rect, destSurface, &point);
- ASSERT(SUCCEEDED(result));
- surf->Release();
- }
- }
- else
- {
- // UpdateSurface: source must be SYSTEMMEM, dest must be DEFAULT pools
- HRESULT result = getDevice()->UpdateSurface(sourceSurface, &rect, destSurface, &point);
- ASSERT(SUCCEEDED(result));
- }
- }
-}
-
-// Store the pixel rectangle designated by xoffset,yoffset,width,height with pixels stored as format/type at input
-// into the target pixel rectangle.
-void Image::loadData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
- GLint unpackAlignment, const void *input)
-{
- RECT lockRect =
- {
- xoffset, yoffset,
- xoffset + width, yoffset + height
- };
-
- D3DLOCKED_RECT locked;
- HRESULT result = lock(&locked, &lockRect);
- if (FAILED(result))
- {
- return;
- }
-
-
- GLsizei inputPitch = ComputePitch(width, mInternalFormat, unpackAlignment);
-
- switch (mInternalFormat)
- {
- case GL_ALPHA8_EXT:
-#if defined(__SSE2__)
- if (supportsSSE2())
- {
- loadAlphaDataSSE2(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- }
- else
-#endif
- {
- loadAlphaData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- }
- break;
- case GL_LUMINANCE8_EXT:
- loadLuminanceData(width, height, inputPitch, input, locked.Pitch, locked.pBits, getD3DFormat() == D3DFMT_L8);
- break;
- case GL_ALPHA32F_EXT:
- loadAlphaFloatData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_LUMINANCE32F_EXT:
- loadLuminanceFloatData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_ALPHA16F_EXT:
- loadAlphaHalfFloatData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_LUMINANCE16F_EXT:
- loadLuminanceHalfFloatData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_LUMINANCE8_ALPHA8_EXT:
- loadLuminanceAlphaData(width, height, inputPitch, input, locked.Pitch, locked.pBits, getD3DFormat() == D3DFMT_A8L8);
- break;
- case GL_LUMINANCE_ALPHA32F_EXT:
- loadLuminanceAlphaFloatData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_LUMINANCE_ALPHA16F_EXT:
- loadLuminanceAlphaHalfFloatData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_RGB8_OES:
- loadRGBUByteData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_RGB565:
- loadRGB565Data(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_RGBA8_OES:
-#if defined(__SSE2__)
- if (supportsSSE2())
- {
- loadRGBAUByteDataSSE2(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- }
- else
+#if defined(ANGLE_ENABLE_D3D11)
+# define D3DFMT_UNKNOWN DXGI_FORMAT_UNKNOWN
+#else
+# include "libGLESv2/renderer/Blit.h"
#endif
- {
- loadRGBAUByteData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- }
- break;
- case GL_RGBA4:
- loadRGBA4444Data(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_RGB5_A1:
- loadRGBA5551Data(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_BGRA8_EXT:
- loadBGRAData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- // float textures are converted to RGBA, not BGRA, as they're stored that way in D3D
- case GL_RGB32F_EXT:
- loadRGBFloatData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_RGB16F_EXT:
- loadRGBHalfFloatData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_RGBA32F_EXT:
- loadRGBAFloatData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- case GL_RGBA16F_EXT:
- loadRGBAHalfFloatData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
- break;
- default: UNREACHABLE();
- }
-
- unlock();
-}
-
-void Image::loadAlphaData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const unsigned char *source = NULL;
- unsigned char *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = static_cast<const unsigned char*>(input) + y * inputPitch;
- dest = static_cast<unsigned char*>(output) + y * outputPitch;
- for (int x = 0; x < width; x++)
- {
- dest[4 * x + 0] = 0;
- dest[4 * x + 1] = 0;
- dest[4 * x + 2] = 0;
- dest[4 * x + 3] = source[x];
- }
- }
-}
-
-void Image::loadAlphaFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const float *source = NULL;
- float *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const float*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = reinterpret_cast<float*>(static_cast<unsigned char*>(output) + y * outputPitch);
- for (int x = 0; x < width; x++)
- {
- dest[4 * x + 0] = 0;
- dest[4 * x + 1] = 0;
- dest[4 * x + 2] = 0;
- dest[4 * x + 3] = source[x];
- }
- }
-}
-
-void Image::loadAlphaHalfFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const unsigned short *source = NULL;
- unsigned short *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = reinterpret_cast<unsigned short*>(static_cast<unsigned char*>(output) + y * outputPitch);
- for (int x = 0; x < width; x++)
- {
- dest[4 * x + 0] = 0;
- dest[4 * x + 1] = 0;
- dest[4 * x + 2] = 0;
- dest[4 * x + 3] = source[x];
- }
- }
-}
-
-void Image::loadLuminanceData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output, bool native) const
-{
- const unsigned char *source = NULL;
- unsigned char *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = static_cast<const unsigned char*>(input) + y * inputPitch;
- dest = static_cast<unsigned char*>(output) + y * outputPitch;
-
- if (!native) // BGRA8 destination format
- {
- for (int x = 0; x < width; x++)
- {
- dest[4 * x + 0] = source[x];
- dest[4 * x + 1] = source[x];
- dest[4 * x + 2] = source[x];
- dest[4 * x + 3] = 0xFF;
- }
- }
- else // L8 destination format
- {
- memcpy(dest, source, width);
- }
- }
-}
-
-void Image::loadLuminanceFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const float *source = NULL;
- float *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const float*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = reinterpret_cast<float*>(static_cast<unsigned char*>(output) + y * outputPitch);
- for (int x = 0; x < width; x++)
- {
- dest[4 * x + 0] = source[x];
- dest[4 * x + 1] = source[x];
- dest[4 * x + 2] = source[x];
- dest[4 * x + 3] = 1.0f;
- }
- }
-}
-
-void Image::loadLuminanceHalfFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const unsigned short *source = NULL;
- unsigned short *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = reinterpret_cast<unsigned short*>(static_cast<unsigned char*>(output) + y * outputPitch);
- for (int x = 0; x < width; x++)
- {
- dest[4 * x + 0] = source[x];
- dest[4 * x + 1] = source[x];
- dest[4 * x + 2] = source[x];
- dest[4 * x + 3] = 0x3C00; // SEEEEEMMMMMMMMMM, S = 0, E = 15, M = 0: 16bit flpt representation of 1
- }
- }
-}
-
-void Image::loadLuminanceAlphaData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output, bool native) const
-{
- const unsigned char *source = NULL;
- unsigned char *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = static_cast<const unsigned char*>(input) + y * inputPitch;
- dest = static_cast<unsigned char*>(output) + y * outputPitch;
-
- if (!native) // BGRA8 destination format
- {
- for (int x = 0; x < width; x++)
- {
- dest[4 * x + 0] = source[2*x+0];
- dest[4 * x + 1] = source[2*x+0];
- dest[4 * x + 2] = source[2*x+0];
- dest[4 * x + 3] = source[2*x+1];
- }
- }
- else
- {
- memcpy(dest, source, width * 2);
- }
- }
-}
-
-void Image::loadLuminanceAlphaFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const float *source = NULL;
- float *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const float*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = reinterpret_cast<float*>(static_cast<unsigned char*>(output) + y * outputPitch);
- for (int x = 0; x < width; x++)
- {
- dest[4 * x + 0] = source[2*x+0];
- dest[4 * x + 1] = source[2*x+0];
- dest[4 * x + 2] = source[2*x+0];
- dest[4 * x + 3] = source[2*x+1];
- }
- }
-}
-
-void Image::loadLuminanceAlphaHalfFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const unsigned short *source = NULL;
- unsigned short *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = reinterpret_cast<unsigned short*>(static_cast<unsigned char*>(output) + y * outputPitch);
- for (int x = 0; x < width; x++)
- {
- dest[4 * x + 0] = source[2*x+0];
- dest[4 * x + 1] = source[2*x+0];
- dest[4 * x + 2] = source[2*x+0];
- dest[4 * x + 3] = source[2*x+1];
- }
- }
-}
-
-void Image::loadRGBUByteData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const unsigned char *source = NULL;
- unsigned char *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = static_cast<const unsigned char*>(input) + y * inputPitch;
- dest = static_cast<unsigned char*>(output) + y * outputPitch;
- for (int x = 0; x < width; x++)
- {
- dest[4 * x + 0] = source[x * 3 + 2];
- dest[4 * x + 1] = source[x * 3 + 1];
- dest[4 * x + 2] = source[x * 3 + 0];
- dest[4 * x + 3] = 0xFF;
- }
- }
-}
-
-void Image::loadRGB565Data(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const unsigned short *source = NULL;
- unsigned char *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = static_cast<unsigned char*>(output) + y * outputPitch;
- for (int x = 0; x < width; x++)
- {
- unsigned short rgba = source[x];
- dest[4 * x + 0] = ((rgba & 0x001F) << 3) | ((rgba & 0x001F) >> 2);
- dest[4 * x + 1] = ((rgba & 0x07E0) >> 3) | ((rgba & 0x07E0) >> 9);
- dest[4 * x + 2] = ((rgba & 0xF800) >> 8) | ((rgba & 0xF800) >> 13);
- dest[4 * x + 3] = 0xFF;
- }
- }
-}
-
-void Image::loadRGBFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const float *source = NULL;
- float *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const float*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = reinterpret_cast<float*>(static_cast<unsigned char*>(output) + y * outputPitch);
- for (int x = 0; x < width; x++)
- {
- dest[4 * x + 0] = source[x * 3 + 0];
- dest[4 * x + 1] = source[x * 3 + 1];
- dest[4 * x + 2] = source[x * 3 + 2];
- dest[4 * x + 3] = 1.0f;
- }
- }
-}
-
-void Image::loadRGBHalfFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const unsigned short *source = NULL;
- unsigned short *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = reinterpret_cast<unsigned short*>(static_cast<unsigned char*>(output) + y * outputPitch);
- for (int x = 0; x < width; x++)
- {
- dest[4 * x + 0] = source[x * 3 + 0];
- dest[4 * x + 1] = source[x * 3 + 1];
- dest[4 * x + 2] = source[x * 3 + 2];
- dest[4 * x + 3] = 0x3C00; // SEEEEEMMMMMMMMMM, S = 0, E = 15, M = 0: 16bit flpt representation of 1
- }
- }
-}
-
-void Image::loadRGBAUByteData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const unsigned int *source = NULL;
- unsigned int *dest = NULL;
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const unsigned int*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = reinterpret_cast<unsigned int*>(static_cast<unsigned char*>(output) + y * outputPitch);
-
- for (int x = 0; x < width; x++)
- {
- unsigned int rgba = source[x];
- dest[x] = (_rotl(rgba, 16) & 0x00ff00ff) | (rgba & 0xff00ff00);
- }
- }
-}
-
-void Image::loadRGBA4444Data(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const unsigned short *source = NULL;
- unsigned char *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = static_cast<unsigned char*>(output) + y * outputPitch;
- for (int x = 0; x < width; x++)
- {
- unsigned short rgba = source[x];
- dest[4 * x + 0] = ((rgba & 0x00F0) << 0) | ((rgba & 0x00F0) >> 4);
- dest[4 * x + 1] = ((rgba & 0x0F00) >> 4) | ((rgba & 0x0F00) >> 8);
- dest[4 * x + 2] = ((rgba & 0xF000) >> 8) | ((rgba & 0xF000) >> 12);
- dest[4 * x + 3] = ((rgba & 0x000F) << 4) | ((rgba & 0x000F) >> 0);
- }
- }
-}
-
-void Image::loadRGBA5551Data(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const unsigned short *source = NULL;
- unsigned char *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = static_cast<unsigned char*>(output) + y * outputPitch;
- for (int x = 0; x < width; x++)
- {
- unsigned short rgba = source[x];
- dest[4 * x + 0] = ((rgba & 0x003E) << 2) | ((rgba & 0x003E) >> 3);
- dest[4 * x + 1] = ((rgba & 0x07C0) >> 3) | ((rgba & 0x07C0) >> 8);
- dest[4 * x + 2] = ((rgba & 0xF800) >> 8) | ((rgba & 0xF800) >> 13);
- dest[4 * x + 3] = (rgba & 0x0001) ? 0xFF : 0;
- }
- }
-}
-
-void Image::loadRGBAFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const float *source = NULL;
- float *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = reinterpret_cast<const float*>(static_cast<const unsigned char*>(input) + y * inputPitch);
- dest = reinterpret_cast<float*>(static_cast<unsigned char*>(output) + y * outputPitch);
- memcpy(dest, source, width * 16);
- }
-}
-
-void Image::loadRGBAHalfFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const unsigned char *source = NULL;
- unsigned char *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = static_cast<const unsigned char*>(input) + y * inputPitch;
- dest = static_cast<unsigned char*>(output) + y * outputPitch;
- memcpy(dest, source, width * 8);
- }
-}
-
-void Image::loadBGRAData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
-{
- const unsigned char *source = NULL;
- unsigned char *dest = NULL;
-
- for (int y = 0; y < height; y++)
- {
- source = static_cast<const unsigned char*>(input) + y * inputPitch;
- dest = static_cast<unsigned char*>(output) + y * outputPitch;
- memcpy(dest, source, width*4);
- }
-}
-
-void Image::loadCompressedData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
- const void *input) {
- ASSERT(xoffset % 4 == 0);
- ASSERT(yoffset % 4 == 0);
-
- RECT lockRect = {
- xoffset, yoffset,
- xoffset + width, yoffset + height
- };
-
- D3DLOCKED_RECT locked;
- HRESULT result = lock(&locked, &lockRect);
- if (FAILED(result))
- {
- return;
- }
-
- GLsizei inputSize = ComputeCompressedSize(width, height, mInternalFormat);
- GLsizei inputPitch = ComputeCompressedPitch(width, mInternalFormat);
- int rows = inputSize / inputPitch;
- for (int i = 0; i < rows; ++i)
- {
- memcpy((void*)((BYTE*)locked.pBits + i * locked.Pitch), (void*)((BYTE*)input + i * inputPitch), inputPitch);
- }
-
- unlock();
-}
-
-// This implements glCopyTex[Sub]Image2D for non-renderable internal texture formats and incomplete textures
-void Image::copy(GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height, IDirect3DSurface9 *renderTarget)
-{
- IDirect3DDevice9 *device = getDevice();
- IDirect3DSurface9 *renderTargetData = NULL;
- D3DSURFACE_DESC description;
- renderTarget->GetDesc(&description);
-
- HRESULT result = device->CreateOffscreenPlainSurface(description.Width, description.Height, description.Format, D3DPOOL_SYSTEMMEM, &renderTargetData, NULL);
-
- if (FAILED(result))
- {
- ERR("Could not create matching destination surface.");
- return error(GL_OUT_OF_MEMORY);
- }
-
- result = device->GetRenderTargetData(renderTarget, renderTargetData);
-
- if (FAILED(result))
- {
- ERR("GetRenderTargetData unexpectedly failed.");
- renderTargetData->Release();
- return error(GL_OUT_OF_MEMORY);
- }
-
- RECT sourceRect = {x, y, x + width, y + height};
- RECT destRect = {xoffset, yoffset, xoffset + width, yoffset + height};
-
- D3DLOCKED_RECT sourceLock = {0};
- result = renderTargetData->LockRect(&sourceLock, &sourceRect, 0);
-
- if (FAILED(result))
- {
- ERR("Failed to lock the source surface (rectangle might be invalid).");
- renderTargetData->Release();
- return error(GL_OUT_OF_MEMORY);
- }
-
- D3DLOCKED_RECT destLock = {0};
- result = lock(&destLock, &destRect);
-
- if (FAILED(result))
- {
- ERR("Failed to lock the destination surface (rectangle might be invalid).");
- renderTargetData->UnlockRect();
- renderTargetData->Release();
- return error(GL_OUT_OF_MEMORY);
- }
-
- if (destLock.pBits && sourceLock.pBits)
- {
- unsigned char *source = (unsigned char*)sourceLock.pBits;
- unsigned char *dest = (unsigned char*)destLock.pBits;
-
- switch (description.Format)
- {
- case D3DFMT_X8R8G8B8:
- case D3DFMT_A8R8G8B8:
- switch(getD3DFormat())
- {
- case D3DFMT_X8R8G8B8:
- case D3DFMT_A8R8G8B8:
- for(int y = 0; y < height; y++)
- {
- memcpy(dest, source, 4 * width);
-
- source += sourceLock.Pitch;
- dest += destLock.Pitch;
- }
- break;
- case D3DFMT_L8:
- for(int y = 0; y < height; y++)
- {
- for(int x = 0; x < width; x++)
- {
- dest[x] = source[x * 4 + 2];
- }
-
- source += sourceLock.Pitch;
- dest += destLock.Pitch;
- }
- break;
- case D3DFMT_A8L8:
- for(int y = 0; y < height; y++)
- {
- for(int x = 0; x < width; x++)
- {
- dest[x * 2 + 0] = source[x * 4 + 2];
- dest[x * 2 + 1] = source[x * 4 + 3];
- }
-
- source += sourceLock.Pitch;
- dest += destLock.Pitch;
- }
- break;
- default:
- UNREACHABLE();
- }
- break;
- case D3DFMT_R5G6B5:
- switch(getD3DFormat())
- {
- case D3DFMT_X8R8G8B8:
- for(int y = 0; y < height; y++)
- {
- for(int x = 0; x < width; x++)
- {
- unsigned short rgb = ((unsigned short*)source)[x];
- unsigned char red = (rgb & 0xF800) >> 8;
- unsigned char green = (rgb & 0x07E0) >> 3;
- unsigned char blue = (rgb & 0x001F) << 3;
- dest[x + 0] = blue | (blue >> 5);
- dest[x + 1] = green | (green >> 6);
- dest[x + 2] = red | (red >> 5);
- dest[x + 3] = 0xFF;
- }
-
- source += sourceLock.Pitch;
- dest += destLock.Pitch;
- }
- break;
- case D3DFMT_L8:
- for(int y = 0; y < height; y++)
- {
- for(int x = 0; x < width; x++)
- {
- unsigned char red = source[x * 2 + 1] & 0xF8;
- dest[x] = red | (red >> 5);
- }
-
- source += sourceLock.Pitch;
- dest += destLock.Pitch;
- }
- break;
- default:
- UNREACHABLE();
- }
- break;
- case D3DFMT_A1R5G5B5:
- switch(getD3DFormat())
- {
- case D3DFMT_X8R8G8B8:
- for(int y = 0; y < height; y++)
- {
- for(int x = 0; x < width; x++)
- {
- unsigned short argb = ((unsigned short*)source)[x];
- unsigned char red = (argb & 0x7C00) >> 7;
- unsigned char green = (argb & 0x03E0) >> 2;
- unsigned char blue = (argb & 0x001F) << 3;
- dest[x + 0] = blue | (blue >> 5);
- dest[x + 1] = green | (green >> 5);
- dest[x + 2] = red | (red >> 5);
- dest[x + 3] = 0xFF;
- }
-
- source += sourceLock.Pitch;
- dest += destLock.Pitch;
- }
- break;
- case D3DFMT_A8R8G8B8:
- for(int y = 0; y < height; y++)
- {
- for(int x = 0; x < width; x++)
- {
- unsigned short argb = ((unsigned short*)source)[x];
- unsigned char red = (argb & 0x7C00) >> 7;
- unsigned char green = (argb & 0x03E0) >> 2;
- unsigned char blue = (argb & 0x001F) << 3;
- unsigned char alpha = (signed short)argb >> 15;
- dest[x + 0] = blue | (blue >> 5);
- dest[x + 1] = green | (green >> 5);
- dest[x + 2] = red | (red >> 5);
- dest[x + 3] = alpha;
- }
-
- source += sourceLock.Pitch;
- dest += destLock.Pitch;
- }
- break;
- case D3DFMT_L8:
- for(int y = 0; y < height; y++)
- {
- for(int x = 0; x < width; x++)
- {
- unsigned char red = source[x * 2 + 1] & 0x7C;
- dest[x] = (red << 1) | (red >> 4);
- }
-
- source += sourceLock.Pitch;
- dest += destLock.Pitch;
- }
- break;
- case D3DFMT_A8L8:
- for(int y = 0; y < height; y++)
- {
- for(int x = 0; x < width; x++)
- {
- unsigned char red = source[x * 2 + 1] & 0x7C;
- dest[x * 2 + 0] = (red << 1) | (red >> 4);
- dest[x * 2 + 1] = (signed char)source[x * 2 + 1] >> 7;
- }
-
- source += sourceLock.Pitch;
- dest += destLock.Pitch;
- }
- break;
- default:
- UNREACHABLE();
- }
- break;
- default:
- UNREACHABLE();
- }
- }
-
- unlock();
- renderTargetData->UnlockRect();
-
- renderTargetData->Release();
+#include "libGLESv2/Renderbuffer.h"
+#include "libGLESv2/renderer/Image.h"
+#include "libGLESv2/renderer/Renderer.h"
+#include "libGLESv2/renderer/TextureStorage.h"
+#include "libEGL/Surface.h"
- mDirty = true;
-}
-
-namespace
-{
-struct L8
-{
- unsigned char L;
-
- static void average(L8 *dst, const L8 *src1, const L8 *src2)
- {
- dst->L = ((src1->L ^ src2->L) >> 1) + (src1->L & src2->L);
- }
-};
-
-struct A8L8
-{
- unsigned char L;
- unsigned char A;
-
- static void average(A8L8 *dst, const A8L8 *src1, const A8L8 *src2)
- {
- *(unsigned short*)dst = (((*(unsigned short*)src1 ^ *(unsigned short*)src2) & 0xFEFE) >> 1) + (*(unsigned short*)src1 & *(unsigned short*)src2);
- }
-};
-
-struct A8R8G8B8
-{
- unsigned char B;
- unsigned char G;
- unsigned char R;
- unsigned char A;
-
- static void average(A8R8G8B8 *dst, const A8R8G8B8 *src1, const A8R8G8B8 *src2)
- {
- *(unsigned int*)dst = (((*(unsigned int*)src1 ^ *(unsigned int*)src2) & 0xFEFEFEFE) >> 1) + (*(unsigned int*)src1 & *(unsigned int*)src2);
- }
-};
-
-struct A16B16G16R16F
-{
- unsigned short R;
- unsigned short G;
- unsigned short B;
- unsigned short A;
-
- static void average(A16B16G16R16F *dst, const A16B16G16R16F *src1, const A16B16G16R16F *src2)
- {
- dst->R = float32ToFloat16((float16ToFloat32(src1->R) + float16ToFloat32(src2->R)) * 0.5f);
- dst->G = float32ToFloat16((float16ToFloat32(src1->G) + float16ToFloat32(src2->G)) * 0.5f);
- dst->B = float32ToFloat16((float16ToFloat32(src1->B) + float16ToFloat32(src2->B)) * 0.5f);
- dst->A = float32ToFloat16((float16ToFloat32(src1->A) + float16ToFloat32(src2->A)) * 0.5f);
- }
-};
-
-struct A32B32G32R32F
-{
- float R;
- float G;
- float B;
- float A;
-
- static void average(A32B32G32R32F *dst, const A32B32G32R32F *src1, const A32B32G32R32F *src2)
- {
- dst->R = (src1->R + src2->R) * 0.5f;
- dst->G = (src1->G + src2->G) * 0.5f;
- dst->B = (src1->B + src2->B) * 0.5f;
- dst->A = (src1->A + src2->A) * 0.5f;
- }
-};
-
-template <typename T>
-void GenerateMip(unsigned int sourceWidth, unsigned int sourceHeight,
- const unsigned char *sourceData, int sourcePitch,
- unsigned char *destData, int destPitch)
-{
- unsigned int mipWidth = std::max(1U, sourceWidth >> 1);
- unsigned int mipHeight = std::max(1U, sourceHeight >> 1);
-
- if (sourceHeight == 1)
- {
- ASSERT(sourceWidth != 1);
-
- const T *src = (const T*)sourceData;
- T *dst = (T*)destData;
-
- for (unsigned int x = 0; x < mipWidth; x++)
- {
- T::average(&dst[x], &src[x * 2], &src[x * 2 + 1]);
- }
- }
- else if (sourceWidth == 1)
- {
- ASSERT(sourceHeight != 1);
-
- for (unsigned int y = 0; y < mipHeight; y++)
- {
- const T *src0 = (const T*)(sourceData + y * 2 * sourcePitch);
- const T *src1 = (const T*)(sourceData + y * 2 * sourcePitch + sourcePitch);
- T *dst = (T*)(destData + y * destPitch);
-
- T::average(dst, src0, src1);
- }
- }
- else
- {
- for (unsigned int y = 0; y < mipHeight; y++)
- {
- const T *src0 = (const T*)(sourceData + y * 2 * sourcePitch);
- const T *src1 = (const T*)(sourceData + y * 2 * sourcePitch + sourcePitch);
- T *dst = (T*)(destData + y * destPitch);
-
- for (unsigned int x = 0; x < mipWidth; x++)
- {
- T tmp0;
- T tmp1;
-
- T::average(&tmp0, &src0[x * 2], &src0[x * 2 + 1]);
- T::average(&tmp1, &src1[x * 2], &src1[x * 2 + 1]);
- T::average(&dst[x], &tmp0, &tmp1);
- }
- }
- }
-}
-
-void GenerateMip(IDirect3DSurface9 *destSurface, IDirect3DSurface9 *sourceSurface)
-{
- D3DSURFACE_DESC destDesc;
- HRESULT result = destSurface->GetDesc(&destDesc);
- ASSERT(SUCCEEDED(result));
-
- D3DSURFACE_DESC sourceDesc;
- result = sourceSurface->GetDesc(&sourceDesc);
- ASSERT(SUCCEEDED(result));
-
- ASSERT(sourceDesc.Format == destDesc.Format);
- ASSERT(sourceDesc.Width == 1 || sourceDesc.Width / 2 == destDesc.Width);
- ASSERT(sourceDesc.Height == 1 || sourceDesc.Height / 2 == destDesc.Height);
-
- D3DLOCKED_RECT sourceLocked = {0};
- result = sourceSurface->LockRect(&sourceLocked, NULL, D3DLOCK_READONLY);
- ASSERT(SUCCEEDED(result));
-
- D3DLOCKED_RECT destLocked = {0};
- result = destSurface->LockRect(&destLocked, NULL, 0);
- ASSERT(SUCCEEDED(result));
-
- const unsigned char *sourceData = reinterpret_cast<const unsigned char*>(sourceLocked.pBits);
- unsigned char *destData = reinterpret_cast<unsigned char*>(destLocked.pBits);
-
- if (sourceData && destData)
- {
- switch (sourceDesc.Format)
- {
- case D3DFMT_L8:
- GenerateMip<L8>(sourceDesc.Width, sourceDesc.Height, sourceData, sourceLocked.Pitch, destData, destLocked.Pitch);
- break;
- case D3DFMT_A8L8:
- GenerateMip<A8L8>(sourceDesc.Width, sourceDesc.Height, sourceData, sourceLocked.Pitch, destData, destLocked.Pitch);
- break;
- case D3DFMT_A8R8G8B8:
- case D3DFMT_X8R8G8B8:
- GenerateMip<A8R8G8B8>(sourceDesc.Width, sourceDesc.Height, sourceData, sourceLocked.Pitch, destData, destLocked.Pitch);
- break;
- case D3DFMT_A16B16G16R16F:
- GenerateMip<A16B16G16R16F>(sourceDesc.Width, sourceDesc.Height, sourceData, sourceLocked.Pitch, destData, destLocked.Pitch);
- break;
- case D3DFMT_A32B32G32R32F:
- GenerateMip<A32B32G32R32F>(sourceDesc.Width, sourceDesc.Height, sourceData, sourceLocked.Pitch, destData, destLocked.Pitch);
- break;
- default:
- UNREACHABLE();
- break;
- }
-
- destSurface->UnlockRect();
- sourceSurface->UnlockRect();
- }
-}
-}
-
-TextureStorage::TextureStorage(DWORD usage)
- : mD3DUsage(usage),
- mD3DPool(getDisplay()->getTexturePool(usage)),
- mTextureSerial(issueTextureSerial()),
- mLodOffset(0)
-{
-}
-
-TextureStorage::~TextureStorage()
-{
-}
-
-bool TextureStorage::isRenderTarget() const
-{
- return (mD3DUsage & (D3DUSAGE_RENDERTARGET | D3DUSAGE_DEPTHSTENCIL)) != 0;
-}
-
-bool TextureStorage::isManaged() const
-{
- return (mD3DPool == D3DPOOL_MANAGED);
-}
-
-D3DPOOL TextureStorage::getPool() const
-{
- return mD3DPool;
-}
-
-DWORD TextureStorage::getUsage() const
-{
- return mD3DUsage;
-}
-
-unsigned int TextureStorage::getTextureSerial() const
-{
- return mTextureSerial;
-}
-
-unsigned int TextureStorage::issueTextureSerial()
+namespace gl
{
- return mCurrentTextureSerial++;
-}
-int TextureStorage::getLodOffset() const
+Texture::Texture(rx::Renderer *renderer, GLuint id) : RefCountObject(id)
{
- return mLodOffset;
-}
+ mRenderer = renderer;
-Texture::Texture(GLuint id) : RefCountObject(id)
-{
- mMinFilter = GL_NEAREST_MIPMAP_LINEAR;
- mMagFilter = GL_LINEAR;
- mWrapS = GL_REPEAT;
- mWrapT = GL_REPEAT;
- mDirtyParameters = true;
+ mSamplerState.minFilter = GL_NEAREST_MIPMAP_LINEAR;
+ mSamplerState.magFilter = GL_LINEAR;
+ mSamplerState.wrapS = GL_REPEAT;
+ mSamplerState.wrapT = GL_REPEAT;
+ mSamplerState.maxAnisotropy = 1.0f;
+ mSamplerState.lodOffset = 0;
mUsage = GL_NONE;
- mMaxAnisotropy = 1.0f;
mDirtyImages = true;
@@ -1345,14 +60,8 @@ bool Texture::setMinFilter(GLenum filter)
case GL_LINEAR_MIPMAP_NEAREST:
case GL_NEAREST_MIPMAP_LINEAR:
case GL_LINEAR_MIPMAP_LINEAR:
- {
- if (mMinFilter != filter)
- {
- mMinFilter = filter;
- mDirtyParameters = true;
- }
- return true;
- }
+ mSamplerState.minFilter = filter;
+ return true;
default:
return false;
}
@@ -1365,14 +74,8 @@ bool Texture::setMagFilter(GLenum filter)
{
case GL_NEAREST:
case GL_LINEAR:
- {
- if (mMagFilter != filter)
- {
- mMagFilter = filter;
- mDirtyParameters = true;
- }
- return true;
- }
+ mSamplerState.magFilter = filter;
+ return true;
default:
return false;
}
@@ -1386,14 +89,8 @@ bool Texture::setWrapS(GLenum wrap)
case GL_REPEAT:
case GL_CLAMP_TO_EDGE:
case GL_MIRRORED_REPEAT:
- {
- if (mWrapS != wrap)
- {
- mWrapS = wrap;
- mDirtyParameters = true;
- }
- return true;
- }
+ mSamplerState.wrapS = wrap;
+ return true;
default:
return false;
}
@@ -1407,14 +104,8 @@ bool Texture::setWrapT(GLenum wrap)
case GL_REPEAT:
case GL_CLAMP_TO_EDGE:
case GL_MIRRORED_REPEAT:
- {
- if (mWrapT != wrap)
- {
- mWrapT = wrap;
- mDirtyParameters = true;
- }
- return true;
- }
+ mSamplerState.wrapT = wrap;
+ return true;
default:
return false;
}
@@ -1428,11 +119,9 @@ bool Texture::setMaxAnisotropy(float textureMaxAnisotropy, float contextMaxAniso
{
return false;
}
- if (mMaxAnisotropy != textureMaxAnisotropy)
- {
- mMaxAnisotropy = textureMaxAnisotropy;
- mDirtyParameters = true;
- }
+
+ mSamplerState.maxAnisotropy = textureMaxAnisotropy;
+
return true;
}
@@ -1452,27 +141,39 @@ bool Texture::setUsage(GLenum usage)
GLenum Texture::getMinFilter() const
{
- return mMinFilter;
+ return mSamplerState.minFilter;
}
GLenum Texture::getMagFilter() const
{
- return mMagFilter;
+ return mSamplerState.magFilter;
}
GLenum Texture::getWrapS() const
{
- return mWrapS;
+ return mSamplerState.wrapS;
}
GLenum Texture::getWrapT() const
{
- return mWrapT;
+ return mSamplerState.wrapT;
}
float Texture::getMaxAnisotropy() const
{
- return mMaxAnisotropy;
+ return mSamplerState.maxAnisotropy;
+}
+
+int Texture::getLodOffset()
+{
+ rx::TextureStorageInterface *texture = getStorage(false);
+ return texture ? texture->getLodOffset() : 0;
+}
+
+void Texture::getSamplerState(SamplerState *sampler)
+{
+ *sampler = mSamplerState;
+ sampler->lodOffset = getLodOffset();
}
GLenum Texture::getUsage() const
@@ -1480,7 +181,24 @@ GLenum Texture::getUsage() const
return mUsage;
}
-void Texture::setImage(GLint unpackAlignment, const void *pixels, Image *image)
+bool Texture::isMipmapFiltered() const
+{
+ switch (mSamplerState.minFilter)
+ {
+ case GL_NEAREST:
+ case GL_LINEAR:
+ return false;
+ case GL_NEAREST_MIPMAP_NEAREST:
+ case GL_LINEAR_MIPMAP_NEAREST:
+ case GL_NEAREST_MIPMAP_LINEAR:
+ case GL_LINEAR_MIPMAP_LINEAR:
+ return true;
+ default: UNREACHABLE();
+ return false;
+ }
+}
+
+void Texture::setImage(GLint unpackAlignment, const void *pixels, rx::Image *image)
{
if (pixels != NULL)
{
@@ -1489,7 +207,7 @@ void Texture::setImage(GLint unpackAlignment, const void *pixels, Image *image)
}
}
-void Texture::setCompressedImage(GLsizei imageSize, const void *pixels, Image *image)
+void Texture::setCompressedImage(GLsizei imageSize, const void *pixels, rx::Image *image)
{
if (pixels != NULL)
{
@@ -1498,7 +216,7 @@ void Texture::setCompressedImage(GLsizei imageSize, const void *pixels, Image *i
}
}
-bool Texture::subImage(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels, Image *image)
+bool Texture::subImage(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels, rx::Image *image)
{
if (pixels != NULL)
{
@@ -1509,7 +227,7 @@ bool Texture::subImage(GLint xoffset, GLint yoffset, GLsizei width, GLsizei heig
return true;
}
-bool Texture::subImageCompressed(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *pixels, Image *image)
+bool Texture::subImageCompressed(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *pixels, rx::Image *image)
{
if (pixels != NULL)
{
@@ -1520,27 +238,17 @@ bool Texture::subImageCompressed(GLint xoffset, GLint yoffset, GLsizei width, GL
return true;
}
-IDirect3DBaseTexture9 *Texture::getTexture()
+rx::TextureStorageInterface *Texture::getNativeTexture()
{
- if (!isSamplerComplete())
- {
- return NULL;
- }
-
// ensure the underlying texture is created
- if (getStorage(false) == NULL)
+
+ rx::TextureStorageInterface *storage = getStorage(false);
+ if (storage)
{
- return NULL;
+ updateTexture();
}
- updateTexture();
-
- return getBaseTexture();
-}
-
-bool Texture::hasDirtyParameters() const
-{
- return mDirtyParameters;
+ return storage;
}
bool Texture::hasDirtyImages() const
@@ -1550,19 +258,18 @@ bool Texture::hasDirtyImages() const
void Texture::resetDirty()
{
- mDirtyParameters = false;
mDirtyImages = false;
}
unsigned int Texture::getTextureSerial()
{
- TextureStorage *texture = getStorage(false);
+ rx::TextureStorageInterface *texture = getStorage(false);
return texture ? texture->getTextureSerial() : 0;
}
unsigned int Texture::getRenderTargetSerial(GLenum target)
{
- TextureStorage *texture = getStorage(true);
+ rx::TextureStorageInterface *texture = getStorage(true);
return texture ? texture->getRenderTargetSerial(target) : 0;
}
@@ -1571,15 +278,9 @@ bool Texture::isImmutable() const
return mImmutable;
}
-int Texture::getLodOffset()
-{
- TextureStorage *texture = getStorage(false);
- return texture ? texture->getLodOffset() : 0;
-}
-
GLint Texture::creationLevels(GLsizei width, GLsizei height) const
{
- if ((isPow2(width) && isPow2(height)) || getContext()->supportsNonPower2Texture())
+ if ((isPow2(width) && isPow2(height)) || mRenderer->getNonPower2TextureSupport())
{
return 0; // Maximum number of levels
}
@@ -1595,127 +296,17 @@ GLint Texture::creationLevels(GLsizei size) const
return creationLevels(size, size);
}
-int Texture::levelCount()
-{
- return getBaseTexture() ? getBaseTexture()->GetLevelCount() - getLodOffset() : 0;
-}
-
-Blit *Texture::getBlitter()
-{
- Context *context = getContext();
- return context->getBlitter();
-}
-
-bool Texture::copyToRenderTarget(IDirect3DSurface9 *dest, IDirect3DSurface9 *source, bool fromManaged)
-{
- if (source && dest)
- {
- HRESULT result = D3DERR_OUTOFVIDEOMEMORY;
-
- if (fromManaged)
- {
- D3DSURFACE_DESC desc;
- source->GetDesc(&desc);
-
- IDirect3DSurface9 *surf = 0;
- result = getDevice()->CreateOffscreenPlainSurface(desc.Width, desc.Height, desc.Format, D3DPOOL_SYSTEMMEM, &surf, NULL);
-
- if (SUCCEEDED(result))
- {
- CopyLockableSurfaces(surf, source);
- result = getDevice()->UpdateSurface(surf, NULL, dest, NULL);
- surf->Release();
- }
- }
- else
- {
- egl::Display *display = getDisplay();
- IDirect3DDevice9 *device = display->getDevice();
-
- display->endScene();
- result = device->StretchRect(source, NULL, dest, NULL, D3DTEXF_NONE);
- }
-
- if (FAILED(result))
- {
- ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
- return false;
- }
- }
-
- return true;
-}
-
-TextureStorage2D::TextureStorage2D(IDirect3DTexture9 *surfaceTexture) : TextureStorage(D3DUSAGE_RENDERTARGET), mRenderTargetSerial(RenderbufferStorage::issueSerial())
-{
- mTexture = surfaceTexture;
-}
-
-TextureStorage2D::TextureStorage2D(int levels, D3DFORMAT format, DWORD usage, int width, int height)
- : TextureStorage(usage), mRenderTargetSerial(RenderbufferStorage::issueSerial())
-{
- mTexture = NULL;
- // if the width or height is not positive this should be treated as an incomplete texture
- // we handle that here by skipping the d3d texture creation
- if (width > 0 && height > 0)
- {
- IDirect3DDevice9 *device = getDevice();
- MakeValidSize(false, dx::IsCompressedFormat(format), &width, &height, &mLodOffset);
- HRESULT result = device->CreateTexture(width, height, levels ? levels + mLodOffset : 0, getUsage(), format, getPool(), &mTexture, NULL);
-
- if (FAILED(result))
- {
- ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
- error(GL_OUT_OF_MEMORY);
- }
- }
-}
-
-TextureStorage2D::~TextureStorage2D()
-{
- if (mTexture)
- {
- mTexture->Release();
- }
-}
-
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *TextureStorage2D::getSurfaceLevel(int level, bool dirty)
-{
- IDirect3DSurface9 *surface = NULL;
-
- if (mTexture)
- {
- HRESULT result = mTexture->GetSurfaceLevel(level + mLodOffset, &surface);
- ASSERT(SUCCEEDED(result));
-
- // With managed textures the driver needs to be informed of updates to the lower mipmap levels
- if (level != 0 && isManaged() && dirty)
- {
- mTexture->AddDirtyRect(NULL);
- }
- }
-
- return surface;
-}
-
-IDirect3DBaseTexture9 *TextureStorage2D::getBaseTexture() const
-{
- return mTexture;
-}
-
-unsigned int TextureStorage2D::getRenderTargetSerial(GLenum target) const
-{
- return mRenderTargetSerial;
-}
-
-Texture2D::Texture2D(GLuint id) : Texture(id)
+Texture2D::Texture2D(rx::Renderer *renderer, GLuint id) : Texture(renderer, id)
{
mTexStorage = NULL;
mSurface = NULL;
mColorbufferProxy = NULL;
mProxyRefs = 0;
+
+ for (int i = 0; i < IMPLEMENTATION_MAX_TEXTURE_LEVELS; ++i)
+ {
+ mImageArray[i] = renderer->createImage();
+ }
}
Texture2D::~Texture2D()
@@ -1730,6 +321,11 @@ Texture2D::~Texture2D()
mSurface->setBoundTexture(NULL);
mSurface = NULL;
}
+
+ for (int i = 0; i < IMPLEMENTATION_MAX_TEXTURE_LEVELS; ++i)
+ {
+ delete mImageArray[i];
+ }
}
// We need to maintain a count of references to renderbuffers acting as
@@ -1757,7 +353,7 @@ GLenum Texture2D::getTarget() const
GLsizei Texture2D::getWidth(GLint level) const
{
if (level < IMPLEMENTATION_MAX_TEXTURE_LEVELS)
- return mImageArray[level].getWidth();
+ return mImageArray[level]->getWidth();
else
return 0;
}
@@ -1765,7 +361,7 @@ GLsizei Texture2D::getWidth(GLint level) const
GLsizei Texture2D::getHeight(GLint level) const
{
if (level < IMPLEMENTATION_MAX_TEXTURE_LEVELS)
- return mImageArray[level].getHeight();
+ return mImageArray[level]->getHeight();
else
return 0;
}
@@ -1773,15 +369,15 @@ GLsizei Texture2D::getHeight(GLint level) const
GLenum Texture2D::getInternalFormat(GLint level) const
{
if (level < IMPLEMENTATION_MAX_TEXTURE_LEVELS)
- return mImageArray[level].getInternalFormat();
+ return mImageArray[level]->getInternalFormat();
else
return GL_NONE;
}
-D3DFORMAT Texture2D::getD3DFormat(GLint level) const
+GLenum Texture2D::getActualFormat(GLint level) const
{
if (level < IMPLEMENTATION_MAX_TEXTURE_LEVELS)
- return mImageArray[level].getD3DFormat();
+ return mImageArray[level]->getActualFormat();
else
return D3DFMT_UNKNOWN;
}
@@ -1790,18 +386,31 @@ void Texture2D::redefineImage(GLint level, GLint internalformat, GLsizei width,
{
releaseTexImage();
- bool redefined = mImageArray[level].redefine(internalformat, width, height, false);
+ // If there currently is a corresponding storage texture image, it has these parameters
+ const int storageWidth = std::max(1, mImageArray[0]->getWidth() >> level);
+ const int storageHeight = std::max(1, mImageArray[0]->getHeight() >> level);
+ const int storageFormat = mImageArray[0]->getInternalFormat();
+
+ mImageArray[level]->redefine(mRenderer, internalformat, width, height, false);
- if (mTexStorage && redefined)
+ if (mTexStorage)
{
- for (int i = 0; i < IMPLEMENTATION_MAX_TEXTURE_LEVELS; i++)
+ const int storageLevels = mTexStorage->levelCount();
+
+ if ((level >= storageLevels && storageLevels != 0) ||
+ width != storageWidth ||
+ height != storageHeight ||
+ internalformat != storageFormat) // Discard mismatched storage
{
- mImageArray[i].markDirty();
- }
+ for (int i = 0; i < IMPLEMENTATION_MAX_TEXTURE_LEVELS; i++)
+ {
+ mImageArray[i]->markDirty();
+ }
- delete mTexStorage;
- mTexStorage = NULL;
- mDirtyImages = true;
+ delete mTexStorage;
+ mTexStorage = NULL;
+ mDirtyImages = true;
+ }
}
}
@@ -1810,32 +419,19 @@ void Texture2D::setImage(GLint level, GLsizei width, GLsizei height, GLenum form
GLint internalformat = ConvertSizedInternalFormat(format, type);
redefineImage(level, internalformat, width, height);
- Texture::setImage(unpackAlignment, pixels, &mImageArray[level]);
+ Texture::setImage(unpackAlignment, pixels, mImageArray[level]);
}
void Texture2D::bindTexImage(egl::Surface *surface)
{
releaseTexImage();
- GLint internalformat;
-
- switch(surface->getFormat())
- {
- case D3DFMT_A8R8G8B8:
- internalformat = GL_RGBA8_OES;
- break;
- case D3DFMT_X8R8G8B8:
- internalformat = GL_RGB8_OES;
- break;
- default:
- UNIMPLEMENTED();
- return;
- }
+ GLint internalformat = surface->getFormat();
- mImageArray[0].redefine(internalformat, surface->getWidth(), surface->getHeight(), true);
+ mImageArray[0]->redefine(mRenderer, internalformat, surface->getWidth(), surface->getHeight(), true);
delete mTexStorage;
- mTexStorage = new TextureStorage2D(surface->getOffscreenTexture());
+ mTexStorage = new rx::TextureStorageInterface2D(mRenderer, surface->getSwapChain());
mDirtyImages = true;
mSurface = surface;
@@ -1857,7 +453,7 @@ void Texture2D::releaseTexImage()
for (int i = 0; i < IMPLEMENTATION_MAX_TEXTURE_LEVELS; i++)
{
- mImageArray[i].redefine(GL_RGBA8_OES, 0, 0, true);
+ mImageArray[i]->redefine(mRenderer, GL_NONE, 0, 0, true);
}
}
}
@@ -1867,23 +463,16 @@ void Texture2D::setCompressedImage(GLint level, GLenum format, GLsizei width, GL
// compressed formats don't have separate sized internal formats-- we can just use the compressed format directly
redefineImage(level, format, width, height);
- Texture::setCompressedImage(imageSize, pixels, &mImageArray[level]);
+ Texture::setCompressedImage(imageSize, pixels, mImageArray[level]);
}
void Texture2D::commitRect(GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height)
{
- ASSERT(mImageArray[level].getSurface() != NULL);
-
if (level < levelCount())
{
- IDirect3DSurface9 *destLevel = mTexStorage->getSurfaceLevel(level, true);
-
- if (destLevel)
+ rx::Image *image = mImageArray[level];
+ if (image->updateSurface(mTexStorage, level, xoffset, yoffset, width, height))
{
- Image *image = &mImageArray[level];
- image->updateSurface(destLevel, xoffset, yoffset, width, height);
-
- destLevel->Release();
image->markClean();
}
}
@@ -1891,7 +480,7 @@ void Texture2D::commitRect(GLint level, GLint xoffset, GLint yoffset, GLsizei wi
void Texture2D::subImage(GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels)
{
- if (Texture::subImage(xoffset, yoffset, width, height, format, type, unpackAlignment, pixels, &mImageArray[level]))
+ if (Texture::subImage(xoffset, yoffset, width, height, format, type, unpackAlignment, pixels, mImageArray[level]))
{
commitRect(level, xoffset, yoffset, width, height);
}
@@ -1899,7 +488,7 @@ void Texture2D::subImage(GLint level, GLint xoffset, GLint yoffset, GLsizei widt
void Texture2D::subImageCompressed(GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *pixels)
{
- if (Texture::subImageCompressed(xoffset, yoffset, width, height, format, imageSize, pixels, &mImageArray[level]))
+ if (Texture::subImageCompressed(xoffset, yoffset, width, height, format, imageSize, pixels, mImageArray[level]))
{
commitRect(level, xoffset, yoffset, width, height);
}
@@ -1907,20 +496,12 @@ void Texture2D::subImageCompressed(GLint level, GLint xoffset, GLint yoffset, GL
void Texture2D::copyImage(GLint level, GLenum format, GLint x, GLint y, GLsizei width, GLsizei height, Framebuffer *source)
{
- IDirect3DSurface9 *renderTarget = source->getRenderTarget();
-
- if (!renderTarget)
- {
- ERR("Failed to retrieve the render target.");
- return error(GL_OUT_OF_MEMORY);
- }
-
GLint internalformat = ConvertSizedInternalFormat(format, GL_UNSIGNED_BYTE);
redefineImage(level, internalformat, width, height);
-
- if (!mImageArray[level].isRenderableFormat())
+
+ if (!mImageArray[level]->isRenderableFormat())
{
- mImageArray[level].copy(0, 0, x, y, width, height, renderTarget);
+ mImageArray[level]->copy(0, 0, x, y, width, height, source);
mDirtyImages = true;
}
else
@@ -1930,47 +511,31 @@ void Texture2D::copyImage(GLint level, GLenum format, GLint x, GLint y, GLsizei
convertToRenderTarget();
}
- mImageArray[level].markClean();
+ mImageArray[level]->markClean();
if (width != 0 && height != 0 && level < levelCount())
{
- RECT sourceRect;
- sourceRect.left = x;
- sourceRect.right = x + width;
- sourceRect.top = y;
- sourceRect.bottom = y + height;
-
- IDirect3DSurface9 *dest = mTexStorage->getSurfaceLevel(level, true);
-
- if (dest)
- {
- getBlitter()->copy(renderTarget, sourceRect, format, 0, 0, dest);
- dest->Release();
- }
+ gl::Rectangle sourceRect;
+ sourceRect.x = x;
+ sourceRect.width = width;
+ sourceRect.y = y;
+ sourceRect.height = height;
+
+ mRenderer->copyImage(source, sourceRect, format, 0, 0, mTexStorage, level);
}
}
-
- renderTarget->Release();
}
void Texture2D::copySubImage(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height, Framebuffer *source)
{
- if (xoffset + width > mImageArray[level].getWidth() || yoffset + height > mImageArray[level].getHeight())
- {
- return error(GL_INVALID_VALUE);
- }
-
- IDirect3DSurface9 *renderTarget = source->getRenderTarget();
-
- if (!renderTarget)
+ if (xoffset + width > mImageArray[level]->getWidth() || yoffset + height > mImageArray[level]->getHeight())
{
- ERR("Failed to retrieve the render target.");
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_INVALID_VALUE);
}
- if (!mImageArray[level].isRenderableFormat() || (!mTexStorage && !isSamplerComplete()))
+ if (!mImageArray[level]->isRenderableFormat() || (!mTexStorage && !isSamplerComplete()))
{
- mImageArray[level].copy(xoffset, yoffset, x, y, width, height, renderTarget);
+ mImageArray[level]->copy(xoffset, yoffset, x, y, width, height, source);
mDirtyImages = true;
}
else
@@ -1984,46 +549,35 @@ void Texture2D::copySubImage(GLenum target, GLint level, GLint xoffset, GLint yo
if (level < levelCount())
{
- RECT sourceRect;
- sourceRect.left = x;
- sourceRect.right = x + width;
- sourceRect.top = y;
- sourceRect.bottom = y + height;
-
- IDirect3DSurface9 *dest = mTexStorage->getSurfaceLevel(level, true);
+ gl::Rectangle sourceRect;
+ sourceRect.x = x;
+ sourceRect.width = width;
+ sourceRect.y = y;
+ sourceRect.height = height;
- if (dest)
- {
- getBlitter()->copy(renderTarget, sourceRect,
- gl::ExtractFormat(mImageArray[0].getInternalFormat()),
- xoffset, yoffset, dest);
- dest->Release();
- }
+ mRenderer->copyImage(source, sourceRect,
+ gl::ExtractFormat(mImageArray[0]->getInternalFormat()),
+ xoffset, yoffset, mTexStorage, level);
}
}
-
- renderTarget->Release();
}
void Texture2D::storage(GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height)
{
- D3DFORMAT d3dfmt = ConvertTextureInternalFormat(internalformat);
- DWORD d3dusage = GetTextureUsage(d3dfmt, mUsage, false);
-
delete mTexStorage;
- mTexStorage = new TextureStorage2D(levels, d3dfmt, d3dusage, width, height);
+ mTexStorage = new rx::TextureStorageInterface2D(mRenderer, levels, internalformat, mUsage, false, width, height);
mImmutable = true;
for (int level = 0; level < levels; level++)
{
- mImageArray[level].redefine(internalformat, width, height, true);
+ mImageArray[level]->redefine(mRenderer, internalformat, width, height, true);
width = std::max(1, width >> 1);
height = std::max(1, height >> 1);
}
for (int level = levels; level < IMPLEMENTATION_MAX_TEXTURE_LEVELS; level++)
{
- mImageArray[level].redefine(GL_NONE, 0, 0, true);
+ mImageArray[level]->redefine(mRenderer, GL_NONE, 0, 0, true);
}
if (mTexStorage->isManaged())
@@ -2032,8 +586,7 @@ void Texture2D::storage(GLsizei levels, GLenum internalformat, GLsizei width, GL
for (int level = 0; level < levels; level++)
{
- IDirect3DSurface9 *surface = mTexStorage->getSurfaceLevel(level, false);
- mImageArray[level].setManagedSurface(surface);
+ mImageArray[level]->setManagedSurface(mTexStorage, level);
}
}
}
@@ -2041,46 +594,33 @@ void Texture2D::storage(GLsizei levels, GLenum internalformat, GLsizei width, GL
// Tests for 2D texture sampling completeness. [OpenGL ES 2.0.24] section 3.8.2 page 85.
bool Texture2D::isSamplerComplete() const
{
- GLsizei width = mImageArray[0].getWidth();
- GLsizei height = mImageArray[0].getHeight();
+ GLsizei width = mImageArray[0]->getWidth();
+ GLsizei height = mImageArray[0]->getHeight();
if (width <= 0 || height <= 0)
{
return false;
}
- bool mipmapping = false;
-
- switch (mMinFilter)
- {
- case GL_NEAREST:
- case GL_LINEAR:
- mipmapping = false;
- break;
- case GL_NEAREST_MIPMAP_NEAREST:
- case GL_LINEAR_MIPMAP_NEAREST:
- case GL_NEAREST_MIPMAP_LINEAR:
- case GL_LINEAR_MIPMAP_LINEAR:
- mipmapping = true;
- break;
- default: UNREACHABLE();
- }
+ bool mipmapping = isMipmapFiltered();
+ bool filtering, renderable;
- if ((IsFloat32Format(getInternalFormat(0)) && !getContext()->supportsFloat32LinearFilter()) ||
- (IsFloat16Format(getInternalFormat(0)) && !getContext()->supportsFloat16LinearFilter()))
+ if ((IsFloat32Format(getInternalFormat(0)) && !mRenderer->getFloat32TextureSupport(&filtering, &renderable)) ||
+ (IsFloat16Format(getInternalFormat(0)) && !mRenderer->getFloat16TextureSupport(&filtering, &renderable)))
{
- if (mMagFilter != GL_NEAREST || (mMinFilter != GL_NEAREST && mMinFilter != GL_NEAREST_MIPMAP_NEAREST))
+ if (mSamplerState.magFilter != GL_NEAREST ||
+ (mSamplerState.minFilter != GL_NEAREST && mSamplerState.minFilter != GL_NEAREST_MIPMAP_NEAREST))
{
return false;
}
}
- bool npotSupport = getContext()->supportsNonPower2Texture();
+ bool npotSupport = mRenderer->getNonPower2TextureSupport();
if (!npotSupport)
{
- if ((getWrapS() != GL_CLAMP_TO_EDGE && !isPow2(width)) ||
- (getWrapT() != GL_CLAMP_TO_EDGE && !isPow2(height)))
+ if ((mSamplerState.wrapS != GL_CLAMP_TO_EDGE && !isPow2(width)) ||
+ (mSamplerState.wrapT != GL_CLAMP_TO_EDGE && !isPow2(height)))
{
return false;
}
@@ -2113,8 +653,8 @@ bool Texture2D::isMipmapComplete() const
return true;
}
- GLsizei width = mImageArray[0].getWidth();
- GLsizei height = mImageArray[0].getHeight();
+ GLsizei width = mImageArray[0]->getWidth();
+ GLsizei height = mImageArray[0]->getHeight();
if (width <= 0 || height <= 0)
{
@@ -2125,17 +665,17 @@ bool Texture2D::isMipmapComplete() const
for (int level = 1; level <= q; level++)
{
- if (mImageArray[level].getInternalFormat() != mImageArray[0].getInternalFormat())
+ if (mImageArray[level]->getInternalFormat() != mImageArray[0]->getInternalFormat())
{
return false;
}
- if (mImageArray[level].getWidth() != std::max(1, width >> level))
+ if (mImageArray[level]->getWidth() != std::max(1, width >> level))
{
return false;
}
- if (mImageArray[level].getHeight() != std::max(1, height >> level))
+ if (mImageArray[level]->getHeight() != std::max(1, height >> level))
{
return false;
}
@@ -2154,26 +694,20 @@ bool Texture2D::isDepth(GLint level) const
return IsDepthTexture(getInternalFormat(level));
}
-IDirect3DBaseTexture9 *Texture2D::getBaseTexture() const
-{
- return mTexStorage ? mTexStorage->getBaseTexture() : NULL;
-}
-
-// Constructs a Direct3D 9 texture resource from the texture images
+// Constructs a native texture resource from the texture images
void Texture2D::createTexture()
{
- GLsizei width = mImageArray[0].getWidth();
- GLsizei height = mImageArray[0].getHeight();
+ GLsizei width = mImageArray[0]->getWidth();
+ GLsizei height = mImageArray[0]->getHeight();
if (!(width > 0 && height > 0))
- return; // do not attempt to create d3d textures for nonexistant data
+ return; // do not attempt to create native textures for nonexistant data
GLint levels = creationLevels(width, height);
- D3DFORMAT d3dfmt = mImageArray[0].getD3DFormat();
- DWORD d3dusage = GetTextureUsage(d3dfmt, mUsage, false);
+ GLenum internalformat = mImageArray[0]->getInternalFormat();
delete mTexStorage;
- mTexStorage = new TextureStorage2D(levels, d3dfmt, d3dusage, width, height);
+ mTexStorage = new rx::TextureStorageInterface2D(mRenderer, levels, internalformat, mUsage, false, width, height);
if (mTexStorage->isManaged())
{
@@ -2181,8 +715,7 @@ void Texture2D::createTexture()
for (int level = 0; level < levels; level++)
{
- IDirect3DSurface9 *surface = mTexStorage->getSurfaceLevel(level, false);
- mImageArray[level].setManagedSurface(surface);
+ mImageArray[level]->setManagedSurface(mTexStorage, level);
}
}
@@ -2191,51 +724,40 @@ void Texture2D::createTexture()
void Texture2D::updateTexture()
{
- int levels = levelCount();
+ bool mipmapping = (isMipmapFiltered() && isMipmapComplete());
+
+ int levels = (mipmapping ? levelCount() : 1);
for (int level = 0; level < levels; level++)
{
- Image *image = &mImageArray[level];
+ rx::Image *image = mImageArray[level];
if (image->isDirty())
{
- commitRect(level, 0, 0, mImageArray[level].getWidth(), mImageArray[level].getHeight());
+ commitRect(level, 0, 0, mImageArray[level]->getWidth(), mImageArray[level]->getHeight());
}
}
}
void Texture2D::convertToRenderTarget()
{
- TextureStorage2D *newTexStorage = NULL;
+ rx::TextureStorageInterface2D *newTexStorage = NULL;
- if (mImageArray[0].getWidth() != 0 && mImageArray[0].getHeight() != 0)
+ if (mImageArray[0]->getWidth() != 0 && mImageArray[0]->getHeight() != 0)
{
- GLsizei width = mImageArray[0].getWidth();
- GLsizei height = mImageArray[0].getHeight();
- GLint levels = creationLevels(width, height);
- D3DFORMAT d3dfmt = mImageArray[0].getD3DFormat();
- DWORD d3dusage = GetTextureUsage(d3dfmt, GL_FRAMEBUFFER_ATTACHMENT_ANGLE, true);
+ GLsizei width = mImageArray[0]->getWidth();
+ GLsizei height = mImageArray[0]->getHeight();
+ GLint levels = mTexStorage != NULL ? mTexStorage->levelCount() : creationLevels(width, height);
+ GLenum internalformat = mImageArray[0]->getInternalFormat();
- newTexStorage = new TextureStorage2D(levels, d3dfmt, d3dusage, width, height);
+ newTexStorage = new rx::TextureStorageInterface2D(mRenderer, levels, internalformat, GL_FRAMEBUFFER_ATTACHMENT_ANGLE, true, width, height);
if (mTexStorage != NULL)
{
- int levels = levelCount();
- for (int i = 0; i < levels; i++)
- {
- IDirect3DSurface9 *source = mTexStorage->getSurfaceLevel(i, false);
- IDirect3DSurface9 *dest = newTexStorage->getSurfaceLevel(i, true);
-
- if (!copyToRenderTarget(dest, source, mTexStorage->isManaged()))
- {
- delete newTexStorage;
- if (source) source->Release();
- if (dest) dest->Release();
- return error(GL_OUT_OF_MEMORY);
- }
-
- if (source) source->Release();
- if (dest) dest->Release();
+ if (!mRenderer->copyToRenderTarget(newTexStorage, mTexStorage))
+ {
+ delete newTexStorage;
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
}
@@ -2248,53 +770,37 @@ void Texture2D::convertToRenderTarget()
void Texture2D::generateMipmaps()
{
- if (!getContext()->supportsNonPower2Texture())
+ if (!mRenderer->getNonPower2TextureSupport())
{
- if (!isPow2(mImageArray[0].getWidth()) || !isPow2(mImageArray[0].getHeight()))
+ if (!isPow2(mImageArray[0]->getWidth()) || !isPow2(mImageArray[0]->getHeight()))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
// Purge array levels 1 through q and reset them to represent the generated mipmap levels.
- unsigned int q = log2(std::max(mImageArray[0].getWidth(), mImageArray[0].getHeight()));
+ unsigned int q = log2(std::max(mImageArray[0]->getWidth(), mImageArray[0]->getHeight()));
for (unsigned int i = 1; i <= q; i++)
{
- redefineImage(i, mImageArray[0].getInternalFormat(),
- std::max(mImageArray[0].getWidth() >> i, 1),
- std::max(mImageArray[0].getHeight() >> i, 1));
+ redefineImage(i, mImageArray[0]->getInternalFormat(),
+ std::max(mImageArray[0]->getWidth() >> i, 1),
+ std::max(mImageArray[0]->getHeight() >> i, 1));
}
if (mTexStorage && mTexStorage->isRenderTarget())
{
for (unsigned int i = 1; i <= q; i++)
{
- IDirect3DSurface9 *upper = mTexStorage->getSurfaceLevel(i - 1, false);
- IDirect3DSurface9 *lower = mTexStorage->getSurfaceLevel(i, true);
-
- if (upper != NULL && lower != NULL)
- {
- getBlitter()->boxFilter(upper, lower);
- }
-
- if (upper != NULL) upper->Release();
- if (lower != NULL) lower->Release();
+ mTexStorage->generateMipmap(i);
- mImageArray[i].markClean();
+ mImageArray[i]->markClean();
}
}
else
{
for (unsigned int i = 1; i <= q; i++)
{
- if (mImageArray[i].getSurface() == NULL)
- {
- return error(GL_OUT_OF_MEMORY);
- }
-
- GenerateMip(mImageArray[i].getSurface(), mImageArray[i - 1].getSurface());
-
- mImageArray[i].markDirty();
+ mRenderer->generateMipmap(mImageArray[i], mImageArray[i - 1]);
}
}
}
@@ -2303,20 +809,18 @@ Renderbuffer *Texture2D::getRenderbuffer(GLenum target)
{
if (target != GL_TEXTURE_2D)
{
- return error(GL_INVALID_OPERATION, (Renderbuffer *)NULL);
+ return gl::error(GL_INVALID_OPERATION, (Renderbuffer *)NULL);
}
if (mColorbufferProxy == NULL)
{
- mColorbufferProxy = new Renderbuffer(id(), new RenderbufferTexture2D(this, target));
+ mColorbufferProxy = new Renderbuffer(mRenderer, id(), new RenderbufferTexture2D(this, target));
}
return mColorbufferProxy;
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *Texture2D::getRenderTarget(GLenum target)
+rx::RenderTarget *Texture2D::getRenderTarget(GLenum target)
{
ASSERT(target == GL_TEXTURE_2D);
@@ -2333,12 +837,11 @@ IDirect3DSurface9 *Texture2D::getRenderTarget(GLenum target)
{
return NULL;
}
- return mTexStorage->getSurfaceLevel(0, false);
+
+ return mTexStorage->getRenderTarget();
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *Texture2D::getDepthStencil(GLenum target)
+rx::RenderTarget *Texture2D::getDepthStencil(GLenum target)
{
ASSERT(target == GL_TEXTURE_2D);
@@ -2355,10 +858,15 @@ IDirect3DSurface9 *Texture2D::getDepthStencil(GLenum target)
{
return NULL;
}
- return mTexStorage->getSurfaceLevel(0, false);
+ return mTexStorage->getRenderTarget();
+}
+
+int Texture2D::levelCount()
+{
+ return mTexStorage ? mTexStorage->levelCount() : 0;
}
-TextureStorage *Texture2D::getStorage(bool renderTarget)
+rx::TextureStorageInterface *Texture2D::getStorage(bool renderTarget)
{
if (!mTexStorage || (renderTarget && !mTexStorage->isRenderTarget()))
{
@@ -2375,74 +883,18 @@ TextureStorage *Texture2D::getStorage(bool renderTarget)
return mTexStorage;
}
-TextureStorageCubeMap::TextureStorageCubeMap(int levels, D3DFORMAT format, DWORD usage, int size)
- : TextureStorage(usage), mFirstRenderTargetSerial(RenderbufferStorage::issueCubeSerials())
-{
- mTexture = NULL;
- // if the size is not positive this should be treated as an incomplete texture
- // we handle that here by skipping the d3d texture creation
- if (size > 0)
- {
- IDirect3DDevice9 *device = getDevice();
- int height = size;
- MakeValidSize(false, dx::IsCompressedFormat(format), &size, &height, &mLodOffset);
- HRESULT result = device->CreateCubeTexture(size, levels ? levels + mLodOffset : 0, getUsage(), format, getPool(), &mTexture, NULL);
-
- if (FAILED(result))
- {
- ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
- error(GL_OUT_OF_MEMORY);
- }
- }
-}
-
-TextureStorageCubeMap::~TextureStorageCubeMap()
-{
- if (mTexture)
- {
- mTexture->Release();
- }
-}
-
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *TextureStorageCubeMap::getCubeMapSurface(GLenum faceTarget, int level, bool dirty)
-{
- IDirect3DSurface9 *surface = NULL;
-
- if (mTexture)
- {
- D3DCUBEMAP_FACES face = es2dx::ConvertCubeFace(faceTarget);
- HRESULT result = mTexture->GetCubeMapSurface(face, level + mLodOffset, &surface);
- ASSERT(SUCCEEDED(result));
-
- // With managed textures the driver needs to be informed of updates to the lower mipmap levels
- if (level != 0 && isManaged() && dirty)
- {
- mTexture->AddDirtyRect(face, NULL);
- }
- }
-
- return surface;
-}
-
-IDirect3DBaseTexture9 *TextureStorageCubeMap::getBaseTexture() const
-{
- return mTexture;
-}
-
-unsigned int TextureStorageCubeMap::getRenderTargetSerial(GLenum target) const
-{
- return mFirstRenderTargetSerial + TextureCubeMap::faceIndex(target);
-}
-
-TextureCubeMap::TextureCubeMap(GLuint id) : Texture(id)
+TextureCubeMap::TextureCubeMap(rx::Renderer *renderer, GLuint id) : Texture(renderer, id)
{
mTexStorage = NULL;
for (int i = 0; i < 6; i++)
{
mFaceProxies[i] = NULL;
mFaceProxyRefs[i] = 0;
+
+ for (int j = 0; j < IMPLEMENTATION_MAX_TEXTURE_LEVELS; ++j)
+ {
+ mImageArray[i][j] = renderer->createImage();
+ }
}
}
@@ -2451,6 +903,11 @@ TextureCubeMap::~TextureCubeMap()
for (int i = 0; i < 6; i++)
{
mFaceProxies[i] = NULL;
+
+ for (int j = 0; j < IMPLEMENTATION_MAX_TEXTURE_LEVELS; ++j)
+ {
+ delete mImageArray[i][j];
+ }
}
delete mTexStorage;
@@ -2494,7 +951,7 @@ GLenum TextureCubeMap::getTarget() const
GLsizei TextureCubeMap::getWidth(GLenum target, GLint level) const
{
if (level < IMPLEMENTATION_MAX_TEXTURE_LEVELS)
- return mImageArray[faceIndex(target)][level].getWidth();
+ return mImageArray[faceIndex(target)][level]->getWidth();
else
return 0;
}
@@ -2502,7 +959,7 @@ GLsizei TextureCubeMap::getWidth(GLenum target, GLint level) const
GLsizei TextureCubeMap::getHeight(GLenum target, GLint level) const
{
if (level < IMPLEMENTATION_MAX_TEXTURE_LEVELS)
- return mImageArray[faceIndex(target)][level].getHeight();
+ return mImageArray[faceIndex(target)][level]->getHeight();
else
return 0;
}
@@ -2510,15 +967,15 @@ GLsizei TextureCubeMap::getHeight(GLenum target, GLint level) const
GLenum TextureCubeMap::getInternalFormat(GLenum target, GLint level) const
{
if (level < IMPLEMENTATION_MAX_TEXTURE_LEVELS)
- return mImageArray[faceIndex(target)][level].getInternalFormat();
+ return mImageArray[faceIndex(target)][level]->getInternalFormat();
else
return GL_NONE;
}
-D3DFORMAT TextureCubeMap::getD3DFormat(GLenum target, GLint level) const
+GLenum TextureCubeMap::getActualFormat(GLenum target, GLint level) const
{
if (level < IMPLEMENTATION_MAX_TEXTURE_LEVELS)
- return mImageArray[faceIndex(target)][level].getD3DFormat();
+ return mImageArray[faceIndex(target)][level]->getActualFormat();
else
return D3DFMT_UNKNOWN;
}
@@ -2558,32 +1015,22 @@ void TextureCubeMap::setCompressedImage(GLenum face, GLint level, GLenum format,
// compressed formats don't have separate sized internal formats-- we can just use the compressed format directly
redefineImage(faceIndex(face), level, format, width, height);
- Texture::setCompressedImage(imageSize, pixels, &mImageArray[faceIndex(face)][level]);
+ Texture::setCompressedImage(imageSize, pixels, mImageArray[faceIndex(face)][level]);
}
void TextureCubeMap::commitRect(int face, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height)
{
- ASSERT(mImageArray[face][level].getSurface() != NULL);
-
if (level < levelCount())
{
- IDirect3DSurface9 *destLevel = mTexStorage->getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, level, true);
- ASSERT(destLevel != NULL);
-
- if (destLevel != NULL)
- {
- Image *image = &mImageArray[face][level];
- image->updateSurface(destLevel, xoffset, yoffset, width, height);
-
- destLevel->Release();
+ rx::Image *image = mImageArray[face][level];
+ if (image->updateSurface(mTexStorage, face, level, xoffset, yoffset, width, height))
image->markClean();
- }
}
}
void TextureCubeMap::subImage(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels)
{
- if (Texture::subImage(xoffset, yoffset, width, height, format, type, unpackAlignment, pixels, &mImageArray[faceIndex(target)][level]))
+ if (Texture::subImage(xoffset, yoffset, width, height, format, type, unpackAlignment, pixels, mImageArray[faceIndex(target)][level]))
{
commitRect(faceIndex(target), level, xoffset, yoffset, width, height);
}
@@ -2591,7 +1038,7 @@ void TextureCubeMap::subImage(GLenum target, GLint level, GLint xoffset, GLint y
void TextureCubeMap::subImageCompressed(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *pixels)
{
- if (Texture::subImageCompressed(xoffset, yoffset, width, height, format, imageSize, pixels, &mImageArray[faceIndex(target)][level]))
+ if (Texture::subImageCompressed(xoffset, yoffset, width, height, format, imageSize, pixels, mImageArray[faceIndex(target)][level]))
{
commitRect(faceIndex(target), level, xoffset, yoffset, width, height);
}
@@ -2600,39 +1047,24 @@ void TextureCubeMap::subImageCompressed(GLenum target, GLint level, GLint xoffse
// Tests for cube map sampling completeness. [OpenGL ES 2.0.24] section 3.8.2 page 86.
bool TextureCubeMap::isSamplerComplete() const
{
- int size = mImageArray[0][0].getWidth();
+ int size = mImageArray[0][0]->getWidth();
- bool mipmapping;
-
- switch (mMinFilter)
- {
- case GL_NEAREST:
- case GL_LINEAR:
- mipmapping = false;
- break;
- case GL_NEAREST_MIPMAP_NEAREST:
- case GL_LINEAR_MIPMAP_NEAREST:
- case GL_NEAREST_MIPMAP_LINEAR:
- case GL_LINEAR_MIPMAP_LINEAR:
- mipmapping = true;
- break;
- default:
- UNREACHABLE();
- return false;
- }
+ bool mipmapping = isMipmapFiltered();
+ bool filtering, renderable;
- if ((gl::ExtractType(getInternalFormat(GL_TEXTURE_CUBE_MAP_POSITIVE_X, 0)) == GL_FLOAT && !getContext()->supportsFloat32LinearFilter()) ||
- (gl::ExtractType(getInternalFormat(GL_TEXTURE_CUBE_MAP_POSITIVE_X, 0) == GL_HALF_FLOAT_OES) && !getContext()->supportsFloat16LinearFilter()))
+ if ((gl::ExtractType(getInternalFormat(GL_TEXTURE_CUBE_MAP_POSITIVE_X, 0)) == GL_FLOAT && !mRenderer->getFloat32TextureSupport(&filtering, &renderable)) ||
+ (gl::ExtractType(getInternalFormat(GL_TEXTURE_CUBE_MAP_POSITIVE_X, 0) == GL_HALF_FLOAT_OES) && !mRenderer->getFloat16TextureSupport(&filtering, &renderable)))
{
- if (mMagFilter != GL_NEAREST || (mMinFilter != GL_NEAREST && mMinFilter != GL_NEAREST_MIPMAP_NEAREST))
+ if (mSamplerState.magFilter != GL_NEAREST ||
+ (mSamplerState.minFilter != GL_NEAREST && mSamplerState.minFilter != GL_NEAREST_MIPMAP_NEAREST))
{
return false;
}
}
- if (!isPow2(size) && !getContext()->supportsNonPower2Texture())
+ if (!isPow2(size) && !mRenderer->getNonPower2TextureSupport())
{
- if (getWrapS() != GL_CLAMP_TO_EDGE || getWrapT() != GL_CLAMP_TO_EDGE || mipmapping)
+ if (mSamplerState.wrapS != GL_CLAMP_TO_EDGE || mSamplerState.wrapT != GL_CLAMP_TO_EDGE || mipmapping)
{
return false;
}
@@ -2659,16 +1091,16 @@ bool TextureCubeMap::isSamplerComplete() const
// Tests for cube texture completeness. [OpenGL ES 2.0.24] section 3.7.10 page 81.
bool TextureCubeMap::isCubeComplete() const
{
- if (mImageArray[0][0].getWidth() <= 0 || mImageArray[0][0].getHeight() != mImageArray[0][0].getWidth())
+ if (mImageArray[0][0]->getWidth() <= 0 || mImageArray[0][0]->getHeight() != mImageArray[0][0]->getWidth())
{
return false;
}
for (unsigned int face = 1; face < 6; face++)
{
- if (mImageArray[face][0].getWidth() != mImageArray[0][0].getWidth() ||
- mImageArray[face][0].getWidth() != mImageArray[0][0].getHeight() ||
- mImageArray[face][0].getInternalFormat() != mImageArray[0][0].getInternalFormat())
+ if (mImageArray[face][0]->getWidth() != mImageArray[0][0]->getWidth() ||
+ mImageArray[face][0]->getWidth() != mImageArray[0][0]->getHeight() ||
+ mImageArray[face][0]->getInternalFormat() != mImageArray[0][0]->getInternalFormat())
{
return false;
}
@@ -2689,7 +1121,7 @@ bool TextureCubeMap::isMipmapCubeComplete() const
return false;
}
- GLsizei size = mImageArray[0][0].getWidth();
+ GLsizei size = mImageArray[0][0]->getWidth();
int q = log2(size);
@@ -2697,12 +1129,12 @@ bool TextureCubeMap::isMipmapCubeComplete() const
{
for (int level = 1; level <= q; level++)
{
- if (mImageArray[face][level].getInternalFormat() != mImageArray[0][0].getInternalFormat())
+ if (mImageArray[face][level]->getInternalFormat() != mImageArray[0][0]->getInternalFormat())
{
return false;
}
- if (mImageArray[face][level].getWidth() != std::max(1, size >> level))
+ if (mImageArray[face][level]->getWidth() != std::max(1, size >> level))
{
return false;
}
@@ -2717,25 +1149,19 @@ bool TextureCubeMap::isCompressed(GLenum target, GLint level) const
return IsCompressed(getInternalFormat(target, level));
}
-IDirect3DBaseTexture9 *TextureCubeMap::getBaseTexture() const
-{
- return mTexStorage ? mTexStorage->getBaseTexture() : NULL;
-}
-
-// Constructs a Direct3D 9 texture resource from the texture images, or returns an existing one
+// Constructs a native texture resource from the texture images, or returns an existing one
void TextureCubeMap::createTexture()
{
- GLsizei size = mImageArray[0][0].getWidth();
+ GLsizei size = mImageArray[0][0]->getWidth();
if (!(size > 0))
- return; // do not attempt to create d3d textures for nonexistant data
+ return; // do not attempt to create native textures for nonexistant data
GLint levels = creationLevels(size);
- D3DFORMAT d3dfmt = mImageArray[0][0].getD3DFormat();
- DWORD d3dusage = GetTextureUsage(d3dfmt, mUsage, false);
+ GLenum internalformat = mImageArray[0][0]->getInternalFormat();
delete mTexStorage;
- mTexStorage = new TextureStorageCubeMap(levels, d3dfmt, d3dusage, size);
+ mTexStorage = new rx::TextureStorageInterfaceCube(mRenderer, levels, internalformat, mUsage, false, size);
if (mTexStorage->isManaged())
{
@@ -2745,8 +1171,7 @@ void TextureCubeMap::createTexture()
{
for (int level = 0; level < levels; level++)
{
- IDirect3DSurface9 *surface = mTexStorage->getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, level, false);
- mImageArray[face][level].setManagedSurface(surface);
+ mImageArray[face][level]->setManagedSurface(mTexStorage, face, level);
}
}
}
@@ -2756,12 +1181,15 @@ void TextureCubeMap::createTexture()
void TextureCubeMap::updateTexture()
{
+ bool mipmapping = isMipmapFiltered() && isMipmapCubeComplete();
+
for (int face = 0; face < 6; face++)
{
- int levels = levelCount();
+ int levels = (mipmapping ? levelCount() : 1);
+
for (int level = 0; level < levels; level++)
{
- Image *image = &mImageArray[face][level];
+ rx::Image *image = mImageArray[face][level];
if (image->isDirty())
{
@@ -2773,38 +1201,22 @@ void TextureCubeMap::updateTexture()
void TextureCubeMap::convertToRenderTarget()
{
- TextureStorageCubeMap *newTexStorage = NULL;
+ rx::TextureStorageInterfaceCube *newTexStorage = NULL;
- if (mImageArray[0][0].getWidth() != 0)
+ if (mImageArray[0][0]->getWidth() != 0)
{
- GLsizei size = mImageArray[0][0].getWidth();
- GLint levels = creationLevels(size);
- D3DFORMAT d3dfmt = mImageArray[0][0].getD3DFormat();
- DWORD d3dusage = GetTextureUsage(d3dfmt, GL_FRAMEBUFFER_ATTACHMENT_ANGLE, true);
+ GLsizei size = mImageArray[0][0]->getWidth();
+ GLint levels = mTexStorage != NULL ? mTexStorage->levelCount() : creationLevels(size);
+ GLenum internalformat = mImageArray[0][0]->getInternalFormat();
- newTexStorage = new TextureStorageCubeMap(levels, d3dfmt, d3dusage, size);
+ newTexStorage = new rx::TextureStorageInterfaceCube(mRenderer, levels, internalformat, GL_FRAMEBUFFER_ATTACHMENT_ANGLE, true, size);
if (mTexStorage != NULL)
{
- int levels = levelCount();
- for (int f = 0; f < 6; f++)
+ if (!mRenderer->copyToRenderTarget(newTexStorage, mTexStorage))
{
- for (int i = 0; i < levels; i++)
- {
- IDirect3DSurface9 *source = mTexStorage->getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + f, i, false);
- IDirect3DSurface9 *dest = newTexStorage->getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + f, i, true);
-
- if (!copyToRenderTarget(dest, source, mTexStorage->isManaged()))
- {
- delete newTexStorage;
- if (source) source->Release();
- if (dest) dest->Release();
- return error(GL_OUT_OF_MEMORY);
- }
-
- if (source) source->Release();
- if (dest) dest->Release();
- }
+ delete newTexStorage;
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
}
@@ -2820,7 +1232,7 @@ void TextureCubeMap::setImage(int faceIndex, GLint level, GLsizei width, GLsizei
GLint internalformat = ConvertSizedInternalFormat(format, type);
redefineImage(faceIndex, level, internalformat, width, height);
- Texture::setImage(unpackAlignment, pixels, &mImageArray[faceIndex][level]);
+ Texture::setImage(unpackAlignment, pixels, mImageArray[faceIndex][level]);
}
unsigned int TextureCubeMap::faceIndex(GLenum face)
@@ -2836,42 +1248,47 @@ unsigned int TextureCubeMap::faceIndex(GLenum face)
void TextureCubeMap::redefineImage(int face, GLint level, GLint internalformat, GLsizei width, GLsizei height)
{
- bool redefined = mImageArray[face][level].redefine(internalformat, width, height, false);
+ // If there currently is a corresponding storage texture image, it has these parameters
+ const int storageWidth = std::max(1, mImageArray[0][0]->getWidth() >> level);
+ const int storageHeight = std::max(1, mImageArray[0][0]->getHeight() >> level);
+ const int storageFormat = mImageArray[0][0]->getInternalFormat();
+
+ mImageArray[face][level]->redefine(mRenderer, internalformat, width, height, false);
- if (mTexStorage && redefined)
+ if (mTexStorage)
{
- for (int i = 0; i < IMPLEMENTATION_MAX_TEXTURE_LEVELS; i++)
+ const int storageLevels = mTexStorage->levelCount();
+
+ if ((level >= storageLevels && storageLevels != 0) ||
+ width != storageWidth ||
+ height != storageHeight ||
+ internalformat != storageFormat) // Discard mismatched storage
{
- for (int f = 0; f < 6; f++)
+ for (int i = 0; i < IMPLEMENTATION_MAX_TEXTURE_LEVELS; i++)
{
- mImageArray[f][i].markDirty();
+ for (int f = 0; f < 6; f++)
+ {
+ mImageArray[f][i]->markDirty();
+ }
}
- }
- delete mTexStorage;
- mTexStorage = NULL;
+ delete mTexStorage;
+ mTexStorage = NULL;
- mDirtyImages = true;
+ mDirtyImages = true;
+ }
}
}
void TextureCubeMap::copyImage(GLenum target, GLint level, GLenum format, GLint x, GLint y, GLsizei width, GLsizei height, Framebuffer *source)
{
- IDirect3DSurface9 *renderTarget = source->getRenderTarget();
-
- if (!renderTarget)
- {
- ERR("Failed to retrieve the render target.");
- return error(GL_OUT_OF_MEMORY);
- }
-
unsigned int faceindex = faceIndex(target);
GLint internalformat = gl::ConvertSizedInternalFormat(format, GL_UNSIGNED_BYTE);
redefineImage(faceindex, level, internalformat, width, height);
- if (!mImageArray[faceindex][level].isRenderableFormat())
+ if (!mImageArray[faceindex][level]->isRenderableFormat())
{
- mImageArray[faceindex][level].copy(0, 0, x, y, width, height, renderTarget);
+ mImageArray[faceindex][level]->copy(0, 0, x, y, width, height, source);
mDirtyImages = true;
}
else
@@ -2881,53 +1298,37 @@ void TextureCubeMap::copyImage(GLenum target, GLint level, GLenum format, GLint
convertToRenderTarget();
}
- mImageArray[faceindex][level].markClean();
+ mImageArray[faceindex][level]->markClean();
ASSERT(width == height);
if (width > 0 && level < levelCount())
{
- RECT sourceRect;
- sourceRect.left = x;
- sourceRect.right = x + width;
- sourceRect.top = y;
- sourceRect.bottom = y + height;
+ gl::Rectangle sourceRect;
+ sourceRect.x = x;
+ sourceRect.width = width;
+ sourceRect.y = y;
+ sourceRect.height = height;
- IDirect3DSurface9 *dest = mTexStorage->getCubeMapSurface(target, level, true);
-
- if (dest)
- {
- getBlitter()->copy(renderTarget, sourceRect, format, 0, 0, dest);
- dest->Release();
- }
+ mRenderer->copyImage(source, sourceRect, format, 0, 0, mTexStorage, target, level);
}
}
-
- renderTarget->Release();
}
void TextureCubeMap::copySubImage(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height, Framebuffer *source)
{
- GLsizei size = mImageArray[faceIndex(target)][level].getWidth();
+ GLsizei size = mImageArray[faceIndex(target)][level]->getWidth();
if (xoffset + width > size || yoffset + height > size)
{
- return error(GL_INVALID_VALUE);
- }
-
- IDirect3DSurface9 *renderTarget = source->getRenderTarget();
-
- if (!renderTarget)
- {
- ERR("Failed to retrieve the render target.");
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_INVALID_VALUE);
}
unsigned int faceindex = faceIndex(target);
- if (!mImageArray[faceindex][level].isRenderableFormat() || (!mTexStorage && !isSamplerComplete()))
+ if (!mImageArray[faceindex][level]->isRenderableFormat() || (!mTexStorage && !isSamplerComplete()))
{
- mImageArray[faceindex][level].copy(0, 0, x, y, width, height, renderTarget);
+ mImageArray[faceindex][level]->copy(0, 0, x, y, width, height, source);
mDirtyImages = true;
}
else
@@ -2941,39 +1342,29 @@ void TextureCubeMap::copySubImage(GLenum target, GLint level, GLint xoffset, GLi
if (level < levelCount())
{
- RECT sourceRect;
- sourceRect.left = x;
- sourceRect.right = x + width;
- sourceRect.top = y;
- sourceRect.bottom = y + height;
-
- IDirect3DSurface9 *dest = mTexStorage->getCubeMapSurface(target, level, true);
+ gl::Rectangle sourceRect;
+ sourceRect.x = x;
+ sourceRect.width = width;
+ sourceRect.y = y;
+ sourceRect.height = height;
- if (dest)
- {
- getBlitter()->copy(renderTarget, sourceRect, gl::ExtractFormat(mImageArray[0][0].getInternalFormat()), xoffset, yoffset, dest);
- dest->Release();
- }
+ mRenderer->copyImage(source, sourceRect, gl::ExtractFormat(mImageArray[0][0]->getInternalFormat()),
+ xoffset, yoffset, mTexStorage, target, level);
}
}
-
- renderTarget->Release();
}
void TextureCubeMap::storage(GLsizei levels, GLenum internalformat, GLsizei size)
{
- D3DFORMAT d3dfmt = ConvertTextureInternalFormat(internalformat);
- DWORD d3dusage = GetTextureUsage(d3dfmt, mUsage, false);
-
delete mTexStorage;
- mTexStorage = new TextureStorageCubeMap(levels, d3dfmt, d3dusage, size);
+ mTexStorage = new rx::TextureStorageInterfaceCube(mRenderer, levels, internalformat, mUsage, false, size);
mImmutable = true;
for (int level = 0; level < levels; level++)
{
for (int face = 0; face < 6; face++)
{
- mImageArray[face][level].redefine(internalformat, size, size, true);
+ mImageArray[face][level]->redefine(mRenderer, internalformat, size, size, true);
size = std::max(1, size >> 1);
}
}
@@ -2982,7 +1373,7 @@ void TextureCubeMap::storage(GLsizei levels, GLenum internalformat, GLsizei size
{
for (int face = 0; face < 6; face++)
{
- mImageArray[face][level].redefine(GL_NONE, 0, 0, true);
+ mImageArray[face][level]->redefine(mRenderer, GL_NONE, 0, 0, true);
}
}
@@ -2994,8 +1385,7 @@ void TextureCubeMap::storage(GLsizei levels, GLenum internalformat, GLsizei size
{
for (int level = 0; level < levels; level++)
{
- IDirect3DSurface9 *surface = mTexStorage->getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, level, false);
- mImageArray[face][level].setManagedSurface(surface);
+ mImageArray[face][level]->setManagedSurface(mTexStorage, face, level);
}
}
}
@@ -3005,26 +1395,26 @@ void TextureCubeMap::generateMipmaps()
{
if (!isCubeComplete())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
- if (!getContext()->supportsNonPower2Texture())
+ if (!mRenderer->getNonPower2TextureSupport())
{
- if (!isPow2(mImageArray[0][0].getWidth()))
+ if (!isPow2(mImageArray[0][0]->getWidth()))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
// Purge array levels 1 through q and reset them to represent the generated mipmap levels.
- unsigned int q = log2(mImageArray[0][0].getWidth());
+ unsigned int q = log2(mImageArray[0][0]->getWidth());
for (unsigned int f = 0; f < 6; f++)
{
for (unsigned int i = 1; i <= q; i++)
{
- redefineImage(f, i, mImageArray[f][0].getInternalFormat(),
- std::max(mImageArray[f][0].getWidth() >> i, 1),
- std::max(mImageArray[f][0].getWidth() >> i, 1));
+ redefineImage(f, i, mImageArray[f][0]->getInternalFormat(),
+ std::max(mImageArray[f][0]->getWidth() >> i, 1),
+ std::max(mImageArray[f][0]->getWidth() >> i, 1));
}
}
@@ -3034,18 +1424,9 @@ void TextureCubeMap::generateMipmaps()
{
for (unsigned int i = 1; i <= q; i++)
{
- IDirect3DSurface9 *upper = mTexStorage->getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + f, i - 1, false);
- IDirect3DSurface9 *lower = mTexStorage->getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + f, i, true);
-
- if (upper != NULL && lower != NULL)
- {
- getBlitter()->boxFilter(upper, lower);
- }
-
- if (upper != NULL) upper->Release();
- if (lower != NULL) lower->Release();
+ mTexStorage->generateMipmap(f, i);
- mImageArray[f][i].markClean();
+ mImageArray[f][i]->markClean();
}
}
}
@@ -3055,14 +1436,7 @@ void TextureCubeMap::generateMipmaps()
{
for (unsigned int i = 1; i <= q; i++)
{
- if (mImageArray[f][i].getSurface() == NULL)
- {
- return error(GL_OUT_OF_MEMORY);
- }
-
- GenerateMip(mImageArray[f][i].getSurface(), mImageArray[f][i - 1].getSurface());
-
- mImageArray[f][i].markDirty();
+ mRenderer->generateMipmap(mImageArray[f][i], mImageArray[f][i - 1]);
}
}
}
@@ -3072,22 +1446,20 @@ Renderbuffer *TextureCubeMap::getRenderbuffer(GLenum target)
{
if (!IsCubemapTextureTarget(target))
{
- return error(GL_INVALID_OPERATION, (Renderbuffer *)NULL);
+ return gl::error(GL_INVALID_OPERATION, (Renderbuffer *)NULL);
}
unsigned int face = faceIndex(target);
if (mFaceProxies[face] == NULL)
{
- mFaceProxies[face] = new Renderbuffer(id(), new RenderbufferTextureCubeMap(this, target));
+ mFaceProxies[face] = new Renderbuffer(mRenderer, id(), new RenderbufferTextureCubeMap(this, target));
}
return mFaceProxies[face];
}
-// Increments refcount on surface.
-// caller must Release() the returned surface
-IDirect3DSurface9 *TextureCubeMap::getRenderTarget(GLenum target)
+rx::RenderTarget *TextureCubeMap::getRenderTarget(GLenum target)
{
ASSERT(IsCubemapTextureTarget(target));
@@ -3099,10 +1471,15 @@ IDirect3DSurface9 *TextureCubeMap::getRenderTarget(GLenum target)
updateTexture();
- return mTexStorage->getCubeMapSurface(target, 0, false);
+ return mTexStorage->getRenderTarget(target);
+}
+
+int TextureCubeMap::levelCount()
+{
+ return mTexStorage ? mTexStorage->levelCount() - getLodOffset() : 0;
}
-TextureStorage *TextureCubeMap::getStorage(bool renderTarget)
+rx::TextureStorageInterface *TextureCubeMap::getStorage(bool renderTarget)
{
if (!mTexStorage || (renderTarget && !mTexStorage->isRenderTarget()))
{
diff --git a/src/3rdparty/angle/src/libGLESv2/Texture.h b/src/3rdparty/angle/src/libGLESv2/Texture.h
index 7d7378f88b..4f5fab28d0 100644
--- a/src/3rdparty/angle/src/libGLESv2/Texture.h
+++ b/src/3rdparty/angle/src/libGLESv2/Texture.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -15,22 +15,30 @@
#define GL_APICALL
#include <GLES2/gl2.h>
-#include <d3d9.h>
#include "common/debug.h"
#include "common/RefCountObject.h"
-#include "libGLESv2/Renderbuffer.h"
-#include "libGLESv2/utilities.h"
+#include "libGLESv2/angletypes.h"
namespace egl
{
class Surface;
}
+namespace rx
+{
+class Renderer;
+class TextureStorageInterface;
+class TextureStorageInterface2D;
+class TextureStorageInterfaceCube;
+class RenderTarget;
+class Image;
+}
+
namespace gl
{
-class Blit;
class Framebuffer;
+class Renderbuffer;
enum
{
@@ -43,132 +51,10 @@ enum
IMPLEMENTATION_MAX_TEXTURE_LEVELS = 15 // 1+log2 of MAX_TEXTURE_SIZE
};
-class Image
-{
- public:
- Image();
- ~Image();
-
- bool redefine(GLint internalformat, GLsizei width, GLsizei height, bool forceRelease);
- void markDirty() {mDirty = true;}
- void markClean() {mDirty = false;}
-
- bool isRenderableFormat() const;
- D3DFORMAT getD3DFormat() const;
-
- GLsizei getWidth() const {return mWidth;}
- GLsizei getHeight() const {return mHeight;}
- GLenum getInternalFormat() const {return mInternalFormat;}
- bool isDirty() const {return mSurface && mDirty;}
- IDirect3DSurface9 *getSurface();
-
- void setManagedSurface(IDirect3DSurface9 *surface);
- void updateSurface(IDirect3DSurface9 *dest, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height);
-
- void loadData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
- GLint unpackAlignment, const void *input);
-
- void loadAlphaData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadAlphaDataSSE2(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadAlphaFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadAlphaHalfFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadLuminanceData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output, bool native) const;
- void loadLuminanceFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadLuminanceHalfFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadLuminanceAlphaData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output, bool native) const;
- void loadLuminanceAlphaFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadLuminanceAlphaHalfFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadRGBUByteData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadRGB565Data(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadRGBFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadRGBHalfFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadRGBAUByteDataSSE2(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadRGBAUByteData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadRGBA4444Data(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadRGBA5551Data(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadRGBAFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadRGBAHalfFloatData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadBGRAData(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const;
- void loadCompressedData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
- const void *input);
-
- void copy(GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height, IDirect3DSurface9 *renderTarget);
-
- private:
- DISALLOW_COPY_AND_ASSIGN(Image);
-
- void createSurface();
-
- HRESULT lock(D3DLOCKED_RECT *lockedRect, const RECT *rect);
- void unlock();
-
- GLsizei mWidth;
- GLsizei mHeight;
- GLint mInternalFormat;
-
- bool mDirty;
-
- D3DPOOL mD3DPool; // can only be D3DPOOL_SYSTEMMEM or D3DPOOL_MANAGED since it needs to be lockable.
- D3DFORMAT mD3DFormat;
-
- IDirect3DSurface9 *mSurface;
-};
-
-class TextureStorage
-{
- public:
- explicit TextureStorage(DWORD usage);
-
- virtual ~TextureStorage();
-
- bool isRenderTarget() const;
- bool isManaged() const;
- D3DPOOL getPool() const;
- DWORD getUsage() const;
- unsigned int getTextureSerial() const;
- virtual unsigned int getRenderTargetSerial(GLenum target) const = 0;
- int getLodOffset() const;
-
- protected:
- int mLodOffset;
-
- private:
- DISALLOW_COPY_AND_ASSIGN(TextureStorage);
-
- const DWORD mD3DUsage;
- const D3DPOOL mD3DPool;
-
- const unsigned int mTextureSerial;
- static unsigned int issueTextureSerial();
-
- static unsigned int mCurrentTextureSerial;
-};
-
class Texture : public RefCountObject
{
public:
- explicit Texture(GLuint id);
+ Texture(rx::Renderer *renderer, GLuint id);
virtual ~Texture();
@@ -189,11 +75,14 @@ class Texture : public RefCountObject
GLenum getWrapS() const;
GLenum getWrapT() const;
float getMaxAnisotropy() const;
+ int getLodOffset();
+ void getSamplerState(SamplerState *sampler);
GLenum getUsage() const;
+ bool isMipmapFiltered() const;
virtual bool isSamplerComplete() const = 0;
- IDirect3DBaseTexture9 *getTexture();
+ rx::TextureStorageInterface *getNativeTexture();
virtual Renderbuffer *getRenderbuffer(GLenum target) = 0;
virtual void generateMipmaps() = 0;
@@ -206,36 +95,28 @@ class Texture : public RefCountObject
unsigned int getRenderTargetSerial(GLenum target);
bool isImmutable() const;
- int getLodOffset();
static const GLuint INCOMPLETE_TEXTURE_ID = static_cast<GLuint>(-1); // Every texture takes an id at creation time. The value is arbitrary because it is never registered with the resource manager.
protected:
- void setImage(GLint unpackAlignment, const void *pixels, Image *image);
- bool subImage(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels, Image *image);
- void setCompressedImage(GLsizei imageSize, const void *pixels, Image *image);
- bool subImageCompressed(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *pixels, Image *image);
+ void setImage(GLint unpackAlignment, const void *pixels, rx::Image *image);
+ bool subImage(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels, rx::Image *image);
+ void setCompressedImage(GLsizei imageSize, const void *pixels, rx::Image *image);
+ bool subImageCompressed(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const void *pixels, rx::Image *image);
GLint creationLevels(GLsizei width, GLsizei height) const;
GLint creationLevels(GLsizei size) const;
- virtual IDirect3DBaseTexture9 *getBaseTexture() const = 0;
virtual void createTexture() = 0;
virtual void updateTexture() = 0;
virtual void convertToRenderTarget() = 0;
- virtual IDirect3DSurface9 *getRenderTarget(GLenum target) = 0;
+ virtual rx::RenderTarget *getRenderTarget(GLenum target) = 0;
- int levelCount();
+ virtual int levelCount() = 0;
- static Blit *getBlitter();
- static bool copyToRenderTarget(IDirect3DSurface9 *dest, IDirect3DSurface9 *source, bool fromManaged);
+ rx::Renderer *mRenderer;
- GLenum mMinFilter;
- GLenum mMagFilter;
- GLenum mWrapS;
- GLenum mWrapT;
- float mMaxAnisotropy;
- bool mDirtyParameters;
+ SamplerState mSamplerState;
GLenum mUsage;
bool mDirtyImages;
@@ -245,33 +126,13 @@ class Texture : public RefCountObject
private:
DISALLOW_COPY_AND_ASSIGN(Texture);
- virtual TextureStorage *getStorage(bool renderTarget) = 0;
-};
-
-class TextureStorage2D : public TextureStorage
-{
- public:
- explicit TextureStorage2D(IDirect3DTexture9 *surfaceTexture);
- TextureStorage2D(int levels, D3DFORMAT format, DWORD usage, int width, int height);
-
- virtual ~TextureStorage2D();
-
- IDirect3DSurface9 *getSurfaceLevel(int level, bool dirty);
- IDirect3DBaseTexture9 *getBaseTexture() const;
-
- virtual unsigned int getRenderTargetSerial(GLenum target) const;
-
- private:
- DISALLOW_COPY_AND_ASSIGN(TextureStorage2D);
-
- IDirect3DTexture9 *mTexture;
- const unsigned int mRenderTargetSerial;
+ virtual rx::TextureStorageInterface *getStorage(bool renderTarget) = 0;
};
class Texture2D : public Texture
{
public:
- explicit Texture2D(GLuint id);
+ Texture2D(rx::Renderer *renderer, GLuint id);
~Texture2D();
@@ -283,7 +144,7 @@ class Texture2D : public Texture
GLsizei getWidth(GLint level) const;
GLsizei getHeight(GLint level) const;
GLenum getInternalFormat(GLint level) const;
- D3DFORMAT getD3DFormat(GLint level) const;
+ GLenum getActualFormat(GLint level) const;
bool isCompressed(GLint level) const;
bool isDepth(GLint level) const;
@@ -305,26 +166,26 @@ class Texture2D : public Texture
protected:
friend class RenderbufferTexture2D;
- virtual IDirect3DSurface9 *getRenderTarget(GLenum target);
- virtual IDirect3DSurface9 *getDepthStencil(GLenum target);
+ virtual rx::RenderTarget *getRenderTarget(GLenum target);
+ virtual rx::RenderTarget *getDepthStencil(GLenum target);
+ virtual int levelCount();
private:
DISALLOW_COPY_AND_ASSIGN(Texture2D);
- virtual IDirect3DBaseTexture9 *getBaseTexture() const;
virtual void createTexture();
virtual void updateTexture();
virtual void convertToRenderTarget();
- virtual TextureStorage *getStorage(bool renderTarget);
+ virtual rx::TextureStorageInterface *getStorage(bool renderTarget);
bool isMipmapComplete() const;
void redefineImage(GLint level, GLint internalformat, GLsizei width, GLsizei height);
void commitRect(GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height);
- Image mImageArray[IMPLEMENTATION_MAX_TEXTURE_LEVELS];
+ rx::Image *mImageArray[IMPLEMENTATION_MAX_TEXTURE_LEVELS];
- TextureStorage2D *mTexStorage;
+ rx::TextureStorageInterface2D *mTexStorage;
egl::Surface *mSurface;
// A specific internal reference count is kept for colorbuffer proxy references,
@@ -336,29 +197,10 @@ class Texture2D : public Texture
unsigned int mProxyRefs;
};
-class TextureStorageCubeMap : public TextureStorage
-{
- public:
- TextureStorageCubeMap(int levels, D3DFORMAT format, DWORD usage, int size);
-
- virtual ~TextureStorageCubeMap();
-
- IDirect3DSurface9 *getCubeMapSurface(GLenum faceTarget, int level, bool dirty);
- IDirect3DBaseTexture9 *getBaseTexture() const;
-
- virtual unsigned int getRenderTargetSerial(GLenum target) const;
-
- private:
- DISALLOW_COPY_AND_ASSIGN(TextureStorageCubeMap);
-
- IDirect3DCubeTexture9 *mTexture;
- const unsigned int mFirstRenderTargetSerial;
-};
-
class TextureCubeMap : public Texture
{
public:
- explicit TextureCubeMap(GLuint id);
+ TextureCubeMap(rx::Renderer *renderer, GLuint id);
~TextureCubeMap();
@@ -370,7 +212,7 @@ class TextureCubeMap : public Texture
GLsizei getWidth(GLenum target, GLint level) const;
GLsizei getHeight(GLenum target, GLint level) const;
GLenum getInternalFormat(GLenum target, GLint level) const;
- D3DFORMAT getD3DFormat(GLenum target, GLint level) const;
+ GLenum getActualFormat(GLenum target, GLint level) const;
bool isCompressed(GLenum target, GLint level) const;
void setImagePosX(GLint level, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint unpackAlignment, const void *pixels);
@@ -398,16 +240,16 @@ class TextureCubeMap : public Texture
protected:
friend class RenderbufferTextureCubeMap;
- virtual IDirect3DSurface9 *getRenderTarget(GLenum target);
+ virtual rx::RenderTarget *getRenderTarget(GLenum target);
+ virtual int levelCount();
private:
DISALLOW_COPY_AND_ASSIGN(TextureCubeMap);
- virtual IDirect3DBaseTexture9 *getBaseTexture() const;
virtual void createTexture();
virtual void updateTexture();
virtual void convertToRenderTarget();
- virtual TextureStorage *getStorage(bool renderTarget);
+ virtual rx::TextureStorageInterface *getStorage(bool renderTarget);
bool isCubeComplete() const;
bool isMipmapCubeComplete() const;
@@ -416,9 +258,9 @@ class TextureCubeMap : public Texture
void commitRect(int faceIndex, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height);
void redefineImage(int faceIndex, GLint level, GLint internalformat, GLsizei width, GLsizei height);
- Image mImageArray[6][IMPLEMENTATION_MAX_TEXTURE_LEVELS];
+ rx::Image *mImageArray[6][IMPLEMENTATION_MAX_TEXTURE_LEVELS];
- TextureStorageCubeMap *mTexStorage;
+ rx::TextureStorageInterfaceCube *mTexStorage;
// A specific internal reference count is kept for colorbuffer proxy references,
// because, as the renderbuffer acting as proxy will maintain a binding pointer
diff --git a/src/3rdparty/angle/src/libGLESv2/Uniform.cpp b/src/3rdparty/angle/src/libGLESv2/Uniform.cpp
new file mode 100644
index 0000000000..5424e271b5
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/Uniform.cpp
@@ -0,0 +1,43 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2010-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+#include "libGLESv2/Uniform.h"
+
+#include "libGLESv2/utilities.h"
+
+namespace gl
+{
+
+Uniform::Uniform(GLenum type, GLenum precision, const std::string &name, unsigned int arraySize)
+ : type(type), precision(precision), name(name), arraySize(arraySize)
+{
+ int bytes = gl::UniformInternalSize(type) * elementCount();
+ data = new unsigned char[bytes];
+ memset(data, 0, bytes);
+ dirty = true;
+
+ psRegisterIndex = -1;
+ vsRegisterIndex = -1;
+ registerCount = VariableRowCount(type) * elementCount();
+}
+
+Uniform::~Uniform()
+{
+ delete[] data;
+}
+
+bool Uniform::isArray() const
+{
+ return arraySize > 0;
+}
+
+unsigned int Uniform::elementCount() const
+{
+ return arraySize > 0 ? arraySize : 1;
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/Uniform.h b/src/3rdparty/angle/src/libGLESv2/Uniform.h
new file mode 100644
index 0000000000..8ab0fbe234
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/Uniform.h
@@ -0,0 +1,48 @@
+//
+// Copyright (c) 2010-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+#ifndef LIBGLESV2_UNIFORM_H_
+#define LIBGLESV2_UNIFORM_H_
+
+#include <string>
+#include <vector>
+
+#define GL_APICALL
+#include <GLES2/gl2.h>
+
+#include "common/debug.h"
+
+namespace gl
+{
+
+// Helper struct representing a single shader uniform
+struct Uniform
+{
+ Uniform(GLenum type, GLenum precision, const std::string &name, unsigned int arraySize);
+
+ ~Uniform();
+
+ bool isArray() const;
+ unsigned int elementCount() const;
+
+ const GLenum type;
+ const GLenum precision;
+ const std::string name;
+ const unsigned int arraySize;
+
+ unsigned char *data;
+ bool dirty;
+
+ int psRegisterIndex;
+ int vsRegisterIndex;
+ unsigned int registerCount;
+};
+
+typedef std::vector<Uniform*> UniformArray;
+
+}
+
+#endif // LIBGLESV2_UNIFORM_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/VertexDataManager.cpp b/src/3rdparty/angle/src/libGLESv2/VertexDataManager.cpp
deleted file mode 100644
index 32c40182d3..0000000000
--- a/src/3rdparty/angle/src/libGLESv2/VertexDataManager.cpp
+++ /dev/null
@@ -1,783 +0,0 @@
-//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-//
-
-// VertexDataManager.h: Defines the VertexDataManager, a class that
-// runs the Buffer translation process.
-
-#include "libGLESv2/VertexDataManager.h"
-
-#include "common/debug.h"
-
-#include "libGLESv2/Buffer.h"
-#include "libGLESv2/Program.h"
-#include "libGLESv2/ProgramBinary.h"
-#include "libGLESv2/main.h"
-
-#include "libGLESv2/vertexconversion.h"
-#include "libGLESv2/IndexDataManager.h"
-
-namespace
-{
- enum { INITIAL_STREAM_BUFFER_SIZE = 1024*1024 };
- // This has to be at least 4k or else it fails on ATI cards.
- enum { CONSTANT_VERTEX_BUFFER_SIZE = 4096 };
-}
-
-namespace gl
-{
-unsigned int VertexBuffer::mCurrentSerial = 1;
-
-int elementsInBuffer(const VertexAttribute &attribute, int size)
-{
- int stride = attribute.stride();
- return (size - attribute.mOffset % stride + (stride - attribute.typeSize())) / stride;
-}
-
-VertexDataManager::VertexDataManager(Context *context, IDirect3DDevice9 *device) : mContext(context), mDevice(device)
-{
- for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
- {
- mDirtyCurrentValue[i] = true;
- mCurrentValueBuffer[i] = NULL;
- mCurrentValueOffsets[i] = 0;
- }
-
- const D3DCAPS9 &caps = context->getDeviceCaps();
- checkVertexCaps(caps.DeclTypes);
-
- mStreamingBuffer = new StreamingVertexBuffer(mDevice, INITIAL_STREAM_BUFFER_SIZE);
-
- if (!mStreamingBuffer)
- {
- ERR("Failed to allocate the streaming vertex buffer.");
- }
-}
-
-VertexDataManager::~VertexDataManager()
-{
- delete mStreamingBuffer;
-
- for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
- {
- delete mCurrentValueBuffer[i];
- }
-}
-
-std::size_t VertexDataManager::writeAttributeData(ArrayVertexBuffer *vertexBuffer, GLint start, GLsizei count, const VertexAttribute &attribute, GLsizei instances)
-{
- Buffer *buffer = attribute.mBoundBuffer.get();
-
- int inputStride = attribute.stride();
- int elementSize = attribute.typeSize();
- const FormatConverter &converter = formatConverter(attribute);
- std::size_t streamOffset = 0;
-
- void *output = NULL;
-
- if (vertexBuffer)
- {
- output = vertexBuffer->map(attribute, spaceRequired(attribute, count, instances), &streamOffset);
- }
-
- if (output == NULL)
- {
- ERR("Failed to map vertex buffer.");
- return -1;
- }
-
- const char *input = NULL;
-
- if (buffer)
- {
- int offset = attribute.mOffset;
-
- input = static_cast<const char*>(buffer->data()) + offset;
- }
- else
- {
- input = static_cast<const char*>(attribute.mPointer);
- }
-
- if (instances == 0 || attribute.mDivisor == 0)
- {
- input += inputStride * start;
- }
-
- if (converter.identity && inputStride == elementSize)
- {
- memcpy(output, input, count * inputStride);
- }
- else
- {
- converter.convertArray(input, inputStride, count, output);
- }
-
- vertexBuffer->unmap();
-
- return streamOffset;
-}
-
-GLenum VertexDataManager::prepareVertexData(GLint start, GLsizei count, TranslatedAttribute *translated, GLsizei instances)
-{
- if (!mStreamingBuffer)
- {
- return GL_OUT_OF_MEMORY;
- }
-
- const VertexAttributeArray &attribs = mContext->getVertexAttributes();
- ProgramBinary *programBinary = mContext->getCurrentProgramBinary();
-
- for (int attributeIndex = 0; attributeIndex < MAX_VERTEX_ATTRIBS; attributeIndex++)
- {
- translated[attributeIndex].active = (programBinary->getSemanticIndex(attributeIndex) != -1);
- }
-
- // Determine the required storage size per used buffer, and invalidate static buffers that don't contain matching attributes
- for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
- {
- if (translated[i].active && attribs[i].mArrayEnabled)
- {
- Buffer *buffer = attribs[i].mBoundBuffer.get();
- StaticVertexBuffer *staticBuffer = buffer ? buffer->getStaticVertexBuffer() : NULL;
-
- if (staticBuffer)
- {
- if (staticBuffer->size() == 0)
- {
- int totalCount = elementsInBuffer(attribs[i], buffer->size());
- staticBuffer->addRequiredSpace(spaceRequired(attribs[i], totalCount, 0));
- }
- else if (staticBuffer->lookupAttribute(attribs[i]) == -1)
- {
- // This static buffer doesn't have matching attributes, so fall back to using the streaming buffer
- // Add the space of all previous attributes belonging to the invalidated static buffer to the streaming buffer
- for (int previous = 0; previous < i; previous++)
- {
- if (translated[previous].active && attribs[previous].mArrayEnabled)
- {
- Buffer *previousBuffer = attribs[previous].mBoundBuffer.get();
- StaticVertexBuffer *previousStaticBuffer = previousBuffer ? previousBuffer->getStaticVertexBuffer() : NULL;
-
- if (staticBuffer == previousStaticBuffer)
- {
- mStreamingBuffer->addRequiredSpace(spaceRequired(attribs[previous], count, instances));
- }
- }
- }
-
- mStreamingBuffer->addRequiredSpace(spaceRequired(attribs[i], count, instances));
-
- buffer->invalidateStaticData();
- }
- }
- else
- {
- mStreamingBuffer->addRequiredSpace(spaceRequired(attribs[i], count, instances));
- }
- }
- }
-
- // Reserve the required space per used buffer
- for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
- {
- if (translated[i].active && attribs[i].mArrayEnabled)
- {
- Buffer *buffer = attribs[i].mBoundBuffer.get();
- ArrayVertexBuffer *staticBuffer = buffer ? buffer->getStaticVertexBuffer() : NULL;
- ArrayVertexBuffer *vertexBuffer = staticBuffer ? staticBuffer : mStreamingBuffer;
-
- if (vertexBuffer)
- {
- vertexBuffer->reserveRequiredSpace();
- }
- }
- }
-
- // Perform the vertex data translations
- for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
- {
- if (translated[i].active)
- {
- if (attribs[i].mArrayEnabled)
- {
- Buffer *buffer = attribs[i].mBoundBuffer.get();
-
- if (!buffer && attribs[i].mPointer == NULL)
- {
- // This is an application error that would normally result in a crash, but we catch it and return an error
- ERR("An enabled vertex array has no buffer and no pointer.");
- return GL_INVALID_OPERATION;
- }
-
- const FormatConverter &converter = formatConverter(attribs[i]);
-
- StaticVertexBuffer *staticBuffer = buffer ? buffer->getStaticVertexBuffer() : NULL;
- ArrayVertexBuffer *vertexBuffer = staticBuffer ? staticBuffer : static_cast<ArrayVertexBuffer*>(mStreamingBuffer);
-
- std::size_t streamOffset = -1;
-
- if (staticBuffer)
- {
- streamOffset = staticBuffer->lookupAttribute(attribs[i]);
-
- if (streamOffset == -1)
- {
- // Convert the entire buffer
- int totalCount = elementsInBuffer(attribs[i], buffer->size());
- int startIndex = attribs[i].mOffset / attribs[i].stride();
-
- streamOffset = writeAttributeData(staticBuffer, -startIndex, totalCount, attribs[i], 0);
- }
-
- if (streamOffset != -1)
- {
- streamOffset += (attribs[i].mOffset / attribs[i].stride()) * converter.outputElementSize;
-
- if (instances == 0 || attribs[i].mDivisor == 0)
- {
- streamOffset += start * converter.outputElementSize;
- }
- }
- }
- else
- {
- streamOffset = writeAttributeData(mStreamingBuffer, start, count, attribs[i], instances);
- }
-
- if (streamOffset == -1)
- {
- return GL_OUT_OF_MEMORY;
- }
-
- translated[i].vertexBuffer = vertexBuffer->getBuffer();
- translated[i].serial = vertexBuffer->getSerial();
- translated[i].divisor = attribs[i].mDivisor;
-
- translated[i].type = converter.d3dDeclType;
- translated[i].stride = converter.outputElementSize;
- translated[i].offset = streamOffset;
- }
- else
- {
- if (!mCurrentValueBuffer[i])
- {
- mCurrentValueBuffer[i] = new StreamingVertexBuffer(mDevice, CONSTANT_VERTEX_BUFFER_SIZE);
- }
-
- StreamingVertexBuffer *buffer = mCurrentValueBuffer[i];
-
- if (mDirtyCurrentValue[i])
- {
- const int requiredSpace = 4 * sizeof(float);
- buffer->addRequiredSpace(requiredSpace);
- buffer->reserveRequiredSpace();
- float *data = static_cast<float*>(buffer->map(VertexAttribute(), requiredSpace, &mCurrentValueOffsets[i]));
- if (data)
- {
- data[0] = attribs[i].mCurrentValue[0];
- data[1] = attribs[i].mCurrentValue[1];
- data[2] = attribs[i].mCurrentValue[2];
- data[3] = attribs[i].mCurrentValue[3];
- buffer->unmap();
- mDirtyCurrentValue[i] = false;
- }
- }
-
- translated[i].vertexBuffer = mCurrentValueBuffer[i]->getBuffer();
- translated[i].serial = mCurrentValueBuffer[i]->getSerial();
- translated[i].divisor = 0;
-
- translated[i].type = D3DDECLTYPE_FLOAT4;
- translated[i].stride = 0;
- translated[i].offset = mCurrentValueOffsets[i];
- }
- }
- }
-
- for (int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
- {
- if (translated[i].active && attribs[i].mArrayEnabled)
- {
- Buffer *buffer = attribs[i].mBoundBuffer.get();
-
- if (buffer)
- {
- buffer->promoteStaticUsage(count * attribs[i].typeSize());
- }
- }
- }
-
- return GL_NO_ERROR;
-}
-
-std::size_t VertexDataManager::spaceRequired(const VertexAttribute &attrib, std::size_t count, GLsizei instances) const
-{
- size_t elementSize = formatConverter(attrib).outputElementSize;
-
- if (instances == 0 || attrib.mDivisor == 0)
- {
- return elementSize * count;
- }
- else
- {
- return elementSize * ((instances + attrib.mDivisor - 1) / attrib.mDivisor);
- }
-}
-
-// Mapping from OpenGL-ES vertex attrib type to D3D decl type:
-//
-// BYTE SHORT (Cast)
-// BYTE-norm FLOAT (Normalize) (can't be exactly represented as SHORT-norm)
-// UNSIGNED_BYTE UBYTE4 (Identity) or SHORT (Cast)
-// UNSIGNED_BYTE-norm UBYTE4N (Identity) or FLOAT (Normalize)
-// SHORT SHORT (Identity)
-// SHORT-norm SHORT-norm (Identity) or FLOAT (Normalize)
-// UNSIGNED_SHORT FLOAT (Cast)
-// UNSIGNED_SHORT-norm USHORT-norm (Identity) or FLOAT (Normalize)
-// FIXED (not in WebGL) FLOAT (FixedToFloat)
-// FLOAT FLOAT (Identity)
-
-// GLToCType maps from GL type (as GLenum) to the C typedef.
-template <GLenum GLType> struct GLToCType { };
-
-template <> struct GLToCType<GL_BYTE> { typedef GLbyte type; };
-template <> struct GLToCType<GL_UNSIGNED_BYTE> { typedef GLubyte type; };
-template <> struct GLToCType<GL_SHORT> { typedef GLshort type; };
-template <> struct GLToCType<GL_UNSIGNED_SHORT> { typedef GLushort type; };
-template <> struct GLToCType<GL_FIXED> { typedef GLuint type; };
-template <> struct GLToCType<GL_FLOAT> { typedef GLfloat type; };
-
-// This differs from D3DDECLTYPE in that it is unsized. (Size expansion is applied last.)
-enum D3DVertexType
-{
- D3DVT_FLOAT,
- D3DVT_SHORT,
- D3DVT_SHORT_NORM,
- D3DVT_UBYTE,
- D3DVT_UBYTE_NORM,
- D3DVT_USHORT_NORM
-};
-
-// D3DToCType maps from D3D vertex type (as enum D3DVertexType) to the corresponding C type.
-template <unsigned int D3DType> struct D3DToCType { };
-
-template <> struct D3DToCType<D3DVT_FLOAT> { typedef float type; };
-template <> struct D3DToCType<D3DVT_SHORT> { typedef short type; };
-template <> struct D3DToCType<D3DVT_SHORT_NORM> { typedef short type; };
-template <> struct D3DToCType<D3DVT_UBYTE> { typedef unsigned char type; };
-template <> struct D3DToCType<D3DVT_UBYTE_NORM> { typedef unsigned char type; };
-template <> struct D3DToCType<D3DVT_USHORT_NORM> { typedef unsigned short type; };
-
-// Encode the type/size combinations that D3D permits. For each type/size it expands to a widener that will provide the appropriate final size.
-template <unsigned int type, int size>
-struct WidenRule
-{
-};
-
-template <int size> struct WidenRule<D3DVT_FLOAT, size> : gl::NoWiden<size> { };
-template <int size> struct WidenRule<D3DVT_SHORT, size> : gl::WidenToEven<size> { };
-template <int size> struct WidenRule<D3DVT_SHORT_NORM, size> : gl::WidenToEven<size> { };
-template <int size> struct WidenRule<D3DVT_UBYTE, size> : gl::WidenToFour<size> { };
-template <int size> struct WidenRule<D3DVT_UBYTE_NORM, size> : gl::WidenToFour<size> { };
-template <int size> struct WidenRule<D3DVT_USHORT_NORM, size> : gl::WidenToEven<size> { };
-
-// VertexTypeFlags encodes the D3DCAPS9::DeclType flag and vertex declaration flag for each D3D vertex type & size combination.
-template <unsigned int d3dtype, int size>
-struct VertexTypeFlags
-{
-};
-
-template <unsigned int _capflag, unsigned int _declflag>
-struct VertexTypeFlagsHelper
-{
- enum { capflag = _capflag };
- enum { declflag = _declflag };
-};
-
-template <> struct VertexTypeFlags<D3DVT_FLOAT, 1> : VertexTypeFlagsHelper<0, D3DDECLTYPE_FLOAT1> { };
-template <> struct VertexTypeFlags<D3DVT_FLOAT, 2> : VertexTypeFlagsHelper<0, D3DDECLTYPE_FLOAT2> { };
-template <> struct VertexTypeFlags<D3DVT_FLOAT, 3> : VertexTypeFlagsHelper<0, D3DDECLTYPE_FLOAT3> { };
-template <> struct VertexTypeFlags<D3DVT_FLOAT, 4> : VertexTypeFlagsHelper<0, D3DDECLTYPE_FLOAT4> { };
-template <> struct VertexTypeFlags<D3DVT_SHORT, 2> : VertexTypeFlagsHelper<0, D3DDECLTYPE_SHORT2> { };
-template <> struct VertexTypeFlags<D3DVT_SHORT, 4> : VertexTypeFlagsHelper<0, D3DDECLTYPE_SHORT4> { };
-template <> struct VertexTypeFlags<D3DVT_SHORT_NORM, 2> : VertexTypeFlagsHelper<D3DDTCAPS_SHORT2N, D3DDECLTYPE_SHORT2N> { };
-template <> struct VertexTypeFlags<D3DVT_SHORT_NORM, 4> : VertexTypeFlagsHelper<D3DDTCAPS_SHORT4N, D3DDECLTYPE_SHORT4N> { };
-template <> struct VertexTypeFlags<D3DVT_UBYTE, 4> : VertexTypeFlagsHelper<D3DDTCAPS_UBYTE4, D3DDECLTYPE_UBYTE4> { };
-template <> struct VertexTypeFlags<D3DVT_UBYTE_NORM, 4> : VertexTypeFlagsHelper<D3DDTCAPS_UBYTE4N, D3DDECLTYPE_UBYTE4N> { };
-template <> struct VertexTypeFlags<D3DVT_USHORT_NORM, 2> : VertexTypeFlagsHelper<D3DDTCAPS_USHORT2N, D3DDECLTYPE_USHORT2N> { };
-template <> struct VertexTypeFlags<D3DVT_USHORT_NORM, 4> : VertexTypeFlagsHelper<D3DDTCAPS_USHORT4N, D3DDECLTYPE_USHORT4N> { };
-
-
-// VertexTypeMapping maps GL type & normalized flag to preferred and fallback D3D vertex types (as D3DVertexType enums).
-template <GLenum GLtype, bool normalized>
-struct VertexTypeMapping
-{
-};
-
-template <D3DVertexType Preferred, D3DVertexType Fallback = Preferred>
-struct VertexTypeMappingBase
-{
- enum { preferred = Preferred };
- enum { fallback = Fallback };
-};
-
-template <> struct VertexTypeMapping<GL_BYTE, false> : VertexTypeMappingBase<D3DVT_SHORT> { }; // Cast
-template <> struct VertexTypeMapping<GL_BYTE, true> : VertexTypeMappingBase<D3DVT_FLOAT> { }; // Normalize
-template <> struct VertexTypeMapping<GL_UNSIGNED_BYTE, false> : VertexTypeMappingBase<D3DVT_UBYTE, D3DVT_FLOAT> { }; // Identity, Cast
-template <> struct VertexTypeMapping<GL_UNSIGNED_BYTE, true> : VertexTypeMappingBase<D3DVT_UBYTE_NORM, D3DVT_FLOAT> { }; // Identity, Normalize
-template <> struct VertexTypeMapping<GL_SHORT, false> : VertexTypeMappingBase<D3DVT_SHORT> { }; // Identity
-template <> struct VertexTypeMapping<GL_SHORT, true> : VertexTypeMappingBase<D3DVT_SHORT_NORM, D3DVT_FLOAT> { }; // Cast, Normalize
-template <> struct VertexTypeMapping<GL_UNSIGNED_SHORT, false> : VertexTypeMappingBase<D3DVT_FLOAT> { }; // Cast
-template <> struct VertexTypeMapping<GL_UNSIGNED_SHORT, true> : VertexTypeMappingBase<D3DVT_USHORT_NORM, D3DVT_FLOAT> { }; // Cast, Normalize
-template <bool normalized> struct VertexTypeMapping<GL_FIXED, normalized> : VertexTypeMappingBase<D3DVT_FLOAT> { }; // FixedToFloat
-template <bool normalized> struct VertexTypeMapping<GL_FLOAT, normalized> : VertexTypeMappingBase<D3DVT_FLOAT> { }; // Identity
-
-
-// Given a GL type & norm flag and a D3D type, ConversionRule provides the type conversion rule (Cast, Normalize, Identity, FixedToFloat).
-// The conversion rules themselves are defined in vertexconversion.h.
-
-// Almost all cases are covered by Cast (including those that are actually Identity since Cast<T,T> knows it's an identity mapping).
-template <GLenum fromType, bool normalized, unsigned int toType>
-struct ConversionRule : gl::Cast<typename GLToCType<fromType>::type, typename D3DToCType<toType>::type>
-{
-};
-
-// All conversions from normalized types to float use the Normalize operator.
-template <GLenum fromType> struct ConversionRule<fromType, true, D3DVT_FLOAT> : gl::Normalize<typename GLToCType<fromType>::type> { };
-
-// Use a full specialisation for this so that it preferentially matches ahead of the generic normalize-to-float rules.
-template <> struct ConversionRule<GL_FIXED, true, D3DVT_FLOAT> : gl::FixedToFloat<GLint, 16> { };
-template <> struct ConversionRule<GL_FIXED, false, D3DVT_FLOAT> : gl::FixedToFloat<GLint, 16> { };
-
-// A 2-stage construction is used for DefaultVertexValues because float must use SimpleDefaultValues (i.e. 0/1)
-// whether it is normalized or not.
-template <class T, bool normalized>
-struct DefaultVertexValuesStage2
-{
-};
-
-template <class T> struct DefaultVertexValuesStage2<T, true> : gl::NormalizedDefaultValues<T> { };
-template <class T> struct DefaultVertexValuesStage2<T, false> : gl::SimpleDefaultValues<T> { };
-
-// Work out the default value rule for a D3D type (expressed as the C type) and
-template <class T, bool normalized>
-struct DefaultVertexValues : DefaultVertexValuesStage2<T, normalized>
-{
-};
-
-template <bool normalized> struct DefaultVertexValues<float, normalized> : gl::SimpleDefaultValues<float> { };
-
-// Policy rules for use with Converter, to choose whether to use the preferred or fallback conversion.
-// The fallback conversion produces an output that all D3D9 devices must support.
-template <class T> struct UsePreferred { enum { type = T::preferred }; };
-template <class T> struct UseFallback { enum { type = T::fallback }; };
-
-// Converter ties it all together. Given an OpenGL type/norm/size and choice of preferred/fallback conversion,
-// it provides all the members of the appropriate VertexDataConverter, the D3DCAPS9::DeclTypes flag in cap flag
-// and the D3DDECLTYPE member needed for the vertex declaration in declflag.
-template <GLenum fromType, bool normalized, int size, template <class T> class PreferenceRule>
-struct Converter
- : gl::VertexDataConverter<typename GLToCType<fromType>::type,
- WidenRule<PreferenceRule< VertexTypeMapping<fromType, normalized> >::type, size>,
- ConversionRule<fromType,
- normalized,
- PreferenceRule< VertexTypeMapping<fromType, normalized> >::type>,
- DefaultVertexValues<typename D3DToCType<PreferenceRule< VertexTypeMapping<fromType, normalized> >::type>::type, normalized > >
-{
-private:
- enum { d3dtype = PreferenceRule< VertexTypeMapping<fromType, normalized> >::type };
- enum { d3dsize = WidenRule<d3dtype, size>::finalWidth };
-
-public:
- enum { capflag = VertexTypeFlags<d3dtype, d3dsize>::capflag };
- enum { declflag = VertexTypeFlags<d3dtype, d3dsize>::declflag };
-};
-
-// Initialise a TranslationInfo
-#define TRANSLATION(type, norm, size, preferred) \
- { \
- Converter<type, norm, size, preferred>::identity, \
- Converter<type, norm, size, preferred>::finalSize, \
- Converter<type, norm, size, preferred>::convertArray, \
- static_cast<D3DDECLTYPE>(Converter<type, norm, size, preferred>::declflag) \
- }
-
-#define TRANSLATION_FOR_TYPE_NORM_SIZE(type, norm, size) \
- { \
- Converter<type, norm, size, UsePreferred>::capflag, \
- TRANSLATION(type, norm, size, UsePreferred), \
- TRANSLATION(type, norm, size, UseFallback) \
- }
-
-#define TRANSLATIONS_FOR_TYPE(type) \
- { \
- { TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 1), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 2), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 3), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 4) }, \
- { TRANSLATION_FOR_TYPE_NORM_SIZE(type, true, 1), TRANSLATION_FOR_TYPE_NORM_SIZE(type, true, 2), TRANSLATION_FOR_TYPE_NORM_SIZE(type, true, 3), TRANSLATION_FOR_TYPE_NORM_SIZE(type, true, 4) }, \
- }
-
-#define TRANSLATIONS_FOR_TYPE_NO_NORM(type) \
- { \
- { TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 1), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 2), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 3), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 4) }, \
- { TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 1), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 2), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 3), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 4) }, \
- }
-
-const VertexDataManager::TranslationDescription VertexDataManager::mPossibleTranslations[NUM_GL_VERTEX_ATTRIB_TYPES][2][4] = // [GL types as enumerated by typeIndex()][normalized][size-1]
-{
- TRANSLATIONS_FOR_TYPE(GL_BYTE),
- TRANSLATIONS_FOR_TYPE(GL_UNSIGNED_BYTE),
- TRANSLATIONS_FOR_TYPE(GL_SHORT),
- TRANSLATIONS_FOR_TYPE(GL_UNSIGNED_SHORT),
- TRANSLATIONS_FOR_TYPE_NO_NORM(GL_FIXED),
- TRANSLATIONS_FOR_TYPE_NO_NORM(GL_FLOAT)
-};
-
-void VertexDataManager::checkVertexCaps(DWORD declTypes)
-{
- for (unsigned int i = 0; i < NUM_GL_VERTEX_ATTRIB_TYPES; i++)
- {
- for (unsigned int j = 0; j < 2; j++)
- {
- for (unsigned int k = 0; k < 4; k++)
- {
- if (mPossibleTranslations[i][j][k].capsFlag == 0 || (declTypes & mPossibleTranslations[i][j][k].capsFlag) != 0)
- {
- mAttributeTypes[i][j][k] = mPossibleTranslations[i][j][k].preferredConversion;
- }
- else
- {
- mAttributeTypes[i][j][k] = mPossibleTranslations[i][j][k].fallbackConversion;
- }
- }
- }
- }
-}
-
-// This is used to index mAttributeTypes and mPossibleTranslations.
-unsigned int VertexDataManager::typeIndex(GLenum type) const
-{
- switch (type)
- {
- case GL_BYTE: return 0;
- case GL_UNSIGNED_BYTE: return 1;
- case GL_SHORT: return 2;
- case GL_UNSIGNED_SHORT: return 3;
- case GL_FIXED: return 4;
- case GL_FLOAT: return 5;
-
- default: UNREACHABLE(); return 5;
- }
-}
-
-VertexBuffer::VertexBuffer(IDirect3DDevice9 *device, std::size_t size, DWORD usageFlags) : mDevice(device), mVertexBuffer(NULL)
-{
- if (size > 0)
- {
- D3DPOOL pool = getDisplay()->getBufferPool(usageFlags);
- HRESULT result = device->CreateVertexBuffer(size, usageFlags, 0, pool, &mVertexBuffer, NULL);
- mSerial = issueSerial();
-
- if (FAILED(result))
- {
- ERR("Out of memory allocating a vertex buffer of size %lu.", size);
- }
- }
-}
-
-VertexBuffer::~VertexBuffer()
-{
- if (mVertexBuffer)
- {
- mVertexBuffer->Release();
- }
-}
-
-void VertexBuffer::unmap()
-{
- if (mVertexBuffer)
- {
- mVertexBuffer->Unlock();
- }
-}
-
-IDirect3DVertexBuffer9 *VertexBuffer::getBuffer() const
-{
- return mVertexBuffer;
-}
-
-unsigned int VertexBuffer::getSerial() const
-{
- return mSerial;
-}
-
-unsigned int VertexBuffer::issueSerial()
-{
- return mCurrentSerial++;
-}
-
-ArrayVertexBuffer::ArrayVertexBuffer(IDirect3DDevice9 *device, std::size_t size, DWORD usageFlags) : VertexBuffer(device, size, usageFlags)
-{
- mBufferSize = size;
- mWritePosition = 0;
- mRequiredSpace = 0;
-}
-
-ArrayVertexBuffer::~ArrayVertexBuffer()
-{
-}
-
-void ArrayVertexBuffer::addRequiredSpace(UINT requiredSpace)
-{
- mRequiredSpace += requiredSpace;
-}
-
-StreamingVertexBuffer::StreamingVertexBuffer(IDirect3DDevice9 *device, std::size_t initialSize) : ArrayVertexBuffer(device, initialSize, D3DUSAGE_DYNAMIC | D3DUSAGE_WRITEONLY)
-{
-}
-
-StreamingVertexBuffer::~StreamingVertexBuffer()
-{
-}
-
-void *StreamingVertexBuffer::map(const VertexAttribute &attribute, std::size_t requiredSpace, std::size_t *offset)
-{
- void *mapPtr = NULL;
-
- if (mVertexBuffer)
- {
- HRESULT result = mVertexBuffer->Lock(mWritePosition, requiredSpace, &mapPtr, D3DLOCK_NOOVERWRITE);
-
- if (FAILED(result))
- {
- ERR("Lock failed with error 0x%08x", result);
- return NULL;
- }
-
- *offset = mWritePosition;
- mWritePosition += requiredSpace;
- }
-
- return mapPtr;
-}
-
-void StreamingVertexBuffer::reserveRequiredSpace()
-{
- if (mRequiredSpace > mBufferSize)
- {
- if (mVertexBuffer)
- {
- mVertexBuffer->Release();
- mVertexBuffer = NULL;
- }
-
- mBufferSize = std::max(mRequiredSpace, 3 * mBufferSize / 2); // 1.5 x mBufferSize is arbitrary and should be checked to see we don't have too many reallocations.
-
- D3DPOOL pool = getDisplay()->getBufferPool(D3DUSAGE_DYNAMIC | D3DUSAGE_WRITEONLY);
- HRESULT result = mDevice->CreateVertexBuffer(mBufferSize, D3DUSAGE_DYNAMIC | D3DUSAGE_WRITEONLY, 0, pool, &mVertexBuffer, NULL);
- mSerial = issueSerial();
-
- if (FAILED(result))
- {
- ERR("Out of memory allocating a vertex buffer of size %lu.", mBufferSize);
- }
-
- mWritePosition = 0;
- }
- else if (mWritePosition + mRequiredSpace > mBufferSize) // Recycle
- {
- if (mVertexBuffer)
- {
- void *dummy;
- mVertexBuffer->Lock(0, 1, &dummy, D3DLOCK_DISCARD);
- mVertexBuffer->Unlock();
- }
-
- mWritePosition = 0;
- }
-
- mRequiredSpace = 0;
-}
-
-StaticVertexBuffer::StaticVertexBuffer(IDirect3DDevice9 *device) : ArrayVertexBuffer(device, 0, D3DUSAGE_WRITEONLY)
-{
-}
-
-StaticVertexBuffer::~StaticVertexBuffer()
-{
-}
-
-void *StaticVertexBuffer::map(const VertexAttribute &attribute, std::size_t requiredSpace, std::size_t *streamOffset)
-{
- void *mapPtr = NULL;
-
- if (mVertexBuffer)
- {
- HRESULT result = mVertexBuffer->Lock(mWritePosition, requiredSpace, &mapPtr, 0);
-
- if (FAILED(result))
- {
- ERR("Lock failed with error 0x%08x", result);
- return NULL;
- }
-
- int attributeOffset = attribute.mOffset % attribute.stride();
- VertexElement element = {attribute.mType, attribute.mSize, attribute.stride(), attribute.mNormalized, attributeOffset, mWritePosition};
- mCache.push_back(element);
-
- *streamOffset = mWritePosition;
- mWritePosition += requiredSpace;
- }
-
- return mapPtr;
-}
-
-void StaticVertexBuffer::reserveRequiredSpace()
-{
- if (!mVertexBuffer && mBufferSize == 0)
- {
- D3DPOOL pool = getDisplay()->getBufferPool(D3DUSAGE_WRITEONLY);
- HRESULT result = mDevice->CreateVertexBuffer(mRequiredSpace, D3DUSAGE_WRITEONLY, 0, pool, &mVertexBuffer, NULL);
- mSerial = issueSerial();
-
- if (FAILED(result))
- {
- ERR("Out of memory allocating a vertex buffer of size %lu.", mRequiredSpace);
- }
-
- mBufferSize = mRequiredSpace;
- }
- else if (mVertexBuffer && mBufferSize >= mRequiredSpace)
- {
- // Already allocated
- }
- else UNREACHABLE(); // Static vertex buffers can't be resized
-
- mRequiredSpace = 0;
-}
-
-std::size_t StaticVertexBuffer::lookupAttribute(const VertexAttribute &attribute)
-{
- for (unsigned int element = 0; element < mCache.size(); element++)
- {
- if (mCache[element].type == attribute.mType &&
- mCache[element].size == attribute.mSize &&
- mCache[element].stride == attribute.stride() &&
- mCache[element].normalized == attribute.mNormalized)
- {
- if (mCache[element].attributeOffset == attribute.mOffset % attribute.stride())
- {
- return mCache[element].streamOffset;
- }
- }
- }
-
- return -1;
-}
-
-const VertexDataManager::FormatConverter &VertexDataManager::formatConverter(const VertexAttribute &attribute) const
-{
- return mAttributeTypes[typeIndex(attribute.mType)][attribute.mNormalized][attribute.mSize - 1];
-}
-}
diff --git a/src/3rdparty/angle/src/libGLESv2/VertexDataManager.h b/src/3rdparty/angle/src/libGLESv2/VertexDataManager.h
deleted file mode 100644
index 857591ac29..0000000000
--- a/src/3rdparty/angle/src/libGLESv2/VertexDataManager.h
+++ /dev/null
@@ -1,169 +0,0 @@
-//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-//
-
-// VertexDataManager.h: Defines the VertexDataManager, a class that
-// runs the Buffer translation process.
-
-#ifndef LIBGLESV2_VERTEXDATAMANAGER_H_
-#define LIBGLESV2_VERTEXDATAMANAGER_H_
-
-#include <vector>
-#include <cstddef>
-
-#define GL_APICALL
-#include <GLES2/gl2.h>
-
-#include "libGLESv2/Context.h"
-
-namespace gl
-{
-
-struct TranslatedAttribute
-{
- bool active;
-
- D3DDECLTYPE type;
- UINT offset;
- UINT stride; // 0 means not to advance the read pointer at all
-
- IDirect3DVertexBuffer9 *vertexBuffer;
- unsigned int serial;
- unsigned int divisor;
-};
-
-class VertexBuffer
-{
- public:
- VertexBuffer(IDirect3DDevice9 *device, std::size_t size, DWORD usageFlags);
- virtual ~VertexBuffer();
-
- void unmap();
-
- IDirect3DVertexBuffer9 *getBuffer() const;
- unsigned int getSerial() const;
-
- protected:
- IDirect3DDevice9 *const mDevice;
- IDirect3DVertexBuffer9 *mVertexBuffer;
-
- unsigned int mSerial;
- static unsigned int issueSerial();
- static unsigned int mCurrentSerial;
-
- private:
- DISALLOW_COPY_AND_ASSIGN(VertexBuffer);
-};
-
-class ArrayVertexBuffer : public VertexBuffer
-{
- public:
- ArrayVertexBuffer(IDirect3DDevice9 *device, std::size_t size, DWORD usageFlags);
- ~ArrayVertexBuffer();
-
- std::size_t size() const { return mBufferSize; }
- virtual void *map(const VertexAttribute &attribute, std::size_t requiredSpace, std::size_t *streamOffset) = 0;
- virtual void reserveRequiredSpace() = 0;
- void addRequiredSpace(UINT requiredSpace);
-
- protected:
- std::size_t mBufferSize;
- std::size_t mWritePosition;
- std::size_t mRequiredSpace;
-};
-
-class StreamingVertexBuffer : public ArrayVertexBuffer
-{
- public:
- StreamingVertexBuffer(IDirect3DDevice9 *device, std::size_t initialSize);
- ~StreamingVertexBuffer();
-
- void *map(const VertexAttribute &attribute, std::size_t requiredSpace, std::size_t *streamOffset);
- void reserveRequiredSpace();
-};
-
-class StaticVertexBuffer : public ArrayVertexBuffer
-{
- public:
- explicit StaticVertexBuffer(IDirect3DDevice9 *device);
- ~StaticVertexBuffer();
-
- void *map(const VertexAttribute &attribute, std::size_t requiredSpace, std::size_t *streamOffset);
- void reserveRequiredSpace();
-
- std::size_t lookupAttribute(const VertexAttribute &attribute); // Returns the offset into the vertex buffer, or -1 if not found
-
- private:
- struct VertexElement
- {
- GLenum type;
- GLint size;
- GLsizei stride;
- bool normalized;
- int attributeOffset;
-
- std::size_t streamOffset;
- };
-
- std::vector<VertexElement> mCache;
-};
-
-class VertexDataManager
-{
- public:
- VertexDataManager(Context *context, IDirect3DDevice9 *backend);
- virtual ~VertexDataManager();
-
- void dirtyCurrentValue(int index) { mDirtyCurrentValue[index] = true; }
-
- GLenum prepareVertexData(GLint start, GLsizei count, TranslatedAttribute *outAttribs, GLsizei instances);
-
- private:
- DISALLOW_COPY_AND_ASSIGN(VertexDataManager);
-
- std::size_t spaceRequired(const VertexAttribute &attrib, std::size_t count, GLsizei instances) const;
- std::size_t writeAttributeData(ArrayVertexBuffer *vertexBuffer, GLint start, GLsizei count, const VertexAttribute &attribute, GLsizei instances);
-
- Context *const mContext;
- IDirect3DDevice9 *const mDevice;
-
- StreamingVertexBuffer *mStreamingBuffer;
-
- bool mDirtyCurrentValue[MAX_VERTEX_ATTRIBS];
- StreamingVertexBuffer *mCurrentValueBuffer[MAX_VERTEX_ATTRIBS];
- std::size_t mCurrentValueOffsets[MAX_VERTEX_ATTRIBS];
-
- // Attribute format conversion
- struct FormatConverter
- {
- bool identity;
- std::size_t outputElementSize;
- void (*convertArray)(const void *in, std::size_t stride, std::size_t n, void *out);
- D3DDECLTYPE d3dDeclType;
- };
-
- enum { NUM_GL_VERTEX_ATTRIB_TYPES = 6 };
-
- FormatConverter mAttributeTypes[NUM_GL_VERTEX_ATTRIB_TYPES][2][4]; // [GL types as enumerated by typeIndex()][normalized][size - 1]
-
- struct TranslationDescription
- {
- DWORD capsFlag;
- FormatConverter preferredConversion;
- FormatConverter fallbackConversion;
- };
-
- // This table is used to generate mAttributeTypes.
- static const TranslationDescription mPossibleTranslations[NUM_GL_VERTEX_ATTRIB_TYPES][2][4]; // [GL types as enumerated by typeIndex()][normalized][size - 1]
-
- void checkVertexCaps(DWORD declTypes);
-
- unsigned int typeIndex(GLenum type) const;
- const FormatConverter &formatConverter(const VertexAttribute &attribute) const;
-};
-
-}
-
-#endif // LIBGLESV2_VERTEXDATAMANAGER_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/angletypes.h b/src/3rdparty/angle/src/libGLESv2/angletypes.h
new file mode 100644
index 0000000000..37f67f41ac
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/angletypes.h
@@ -0,0 +1,128 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// angletypes.h : Defines a variety of structures and enum types that are used throughout libGLESv2
+
+#ifndef LIBGLESV2_ANGLETYPES_H_
+#define LIBGLESV2_ANGLETYPES_H_
+
+namespace gl
+{
+
+enum TextureType
+{
+ TEXTURE_2D,
+ TEXTURE_CUBE,
+
+ TEXTURE_TYPE_COUNT,
+ TEXTURE_UNKNOWN
+};
+
+enum SamplerType
+{
+ SAMPLER_PIXEL,
+ SAMPLER_VERTEX
+};
+
+struct Color
+{
+ float red;
+ float green;
+ float blue;
+ float alpha;
+};
+
+struct Rectangle
+{
+ int x;
+ int y;
+ int width;
+ int height;
+};
+
+struct RasterizerState
+{
+ bool cullFace;
+ GLenum cullMode;
+ GLenum frontFace;
+
+ bool polygonOffsetFill;
+ GLfloat polygonOffsetFactor;
+ GLfloat polygonOffsetUnits;
+
+ bool pointDrawMode;
+};
+
+struct BlendState
+{
+ bool blend;
+ GLenum sourceBlendRGB;
+ GLenum destBlendRGB;
+ GLenum sourceBlendAlpha;
+ GLenum destBlendAlpha;
+ GLenum blendEquationRGB;
+ GLenum blendEquationAlpha;
+
+ bool colorMaskRed;
+ bool colorMaskGreen;
+ bool colorMaskBlue;
+ bool colorMaskAlpha;
+
+ bool sampleAlphaToCoverage;
+
+ bool dither;
+};
+
+struct DepthStencilState
+{
+ bool depthTest;
+ GLenum depthFunc;
+ bool depthMask;
+
+ bool stencilTest;
+ GLenum stencilFunc;
+ GLuint stencilMask;
+ GLenum stencilFail;
+ GLenum stencilPassDepthFail;
+ GLenum stencilPassDepthPass;
+ GLuint stencilWritemask;
+ GLenum stencilBackFunc;
+ GLuint stencilBackMask;
+ GLenum stencilBackFail;
+ GLenum stencilBackPassDepthFail;
+ GLenum stencilBackPassDepthPass;
+ GLuint stencilBackWritemask;
+};
+
+struct SamplerState
+{
+ GLenum minFilter;
+ GLenum magFilter;
+ GLenum wrapS;
+ GLenum wrapT;
+ float maxAnisotropy;
+ int lodOffset;
+};
+
+struct ClearParameters
+{
+ GLbitfield mask;
+
+ Color colorClearValue;
+ bool colorMaskRed;
+ bool colorMaskGreen;
+ bool colorMaskBlue;
+ bool colorMaskAlpha;
+
+ float depthClearValue;
+
+ GLint stencilClearValue;
+ GLuint stencilWriteMask;
+};
+
+}
+
+#endif // LIBGLESV2_ANGLETYPES_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/constants.h b/src/3rdparty/angle/src/libGLESv2/constants.h
new file mode 100644
index 0000000000..9f24d66a7d
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/constants.h
@@ -0,0 +1,34 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Contants.h: Defines some implementation specific and gl constants
+
+#ifndef LIBGLESV2_CONSTANTS_H_
+#define LIBGLESV2_CONSTANTS_H_
+
+namespace gl
+{
+
+enum
+{
+ MAX_VERTEX_ATTRIBS = 16,
+ MAX_TEXTURE_IMAGE_UNITS = 16,
+
+ // Implementation upper limits, real maximums depend on the hardware
+ IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS = 16,
+ IMPLEMENTATION_MAX_COMBINED_TEXTURE_IMAGE_UNITS = MAX_TEXTURE_IMAGE_UNITS + IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS,
+
+ IMPLEMENTATION_MAX_VARYING_VECTORS = 32,
+ IMPLEMENTATION_MAX_DRAW_BUFFERS = 8
+};
+
+const float ALIASED_LINE_WIDTH_RANGE_MIN = 1.0f;
+const float ALIASED_LINE_WIDTH_RANGE_MAX = 1.0f;
+const float ALIASED_POINT_SIZE_RANGE_MIN = 1.0f;
+
+}
+
+#endif // LIBGLESV2_CONSTANTS_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/libGLESv2.cpp b/src/3rdparty/angle/src/libGLESv2/libGLESv2.cpp
index 16d9c1775d..64f67d7d6d 100644
--- a/src/3rdparty/angle/src/libGLESv2/libGLESv2.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/libGLESv2.cpp
@@ -1,3 +1,4 @@
+#include "precompiled.h"
//
// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
@@ -6,29 +7,19 @@
// libGLESv2.cpp: Implements the exported OpenGL ES 2.0 functions.
-#define GL_APICALL
-#include <GLES2/gl2.h>
-#include <GLES2/gl2ext.h>
-
-#include <exception>
-#include <limits>
-
-#include "common/debug.h"
#include "common/version.h"
#include "libGLESv2/main.h"
-#include "libGLESv2/mathutil.h"
#include "libGLESv2/utilities.h"
#include "libGLESv2/Buffer.h"
-#include "libGLESv2/Context.h"
#include "libGLESv2/Fence.h"
#include "libGLESv2/Framebuffer.h"
+#include "libGLESv2/Renderbuffer.h"
#include "libGLESv2/Program.h"
#include "libGLESv2/ProgramBinary.h"
-#include "libGLESv2/Renderbuffer.h"
-#include "libGLESv2/Shader.h"
#include "libGLESv2/Texture.h"
#include "libGLESv2/Query.h"
+#include "libGLESv2/Context.h"
bool validImageSize(GLint level, GLsizei width, GLsizei height)
{
@@ -71,7 +62,7 @@ bool checkTextureFormatType(GLenum format, GLenum type)
case GL_DEPTH_STENCIL_OES:
break;
default:
- return error(GL_INVALID_ENUM, false);
+ return gl::error(GL_INVALID_ENUM, false);
}
// invalid <type> -> sets INVALID_ENUM
@@ -89,7 +80,7 @@ bool checkTextureFormatType(GLenum format, GLenum type)
case GL_LUMINANCE_ALPHA:
return true;
default:
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
case GL_FLOAT:
@@ -103,7 +94,7 @@ bool checkTextureFormatType(GLenum format, GLenum type)
case GL_LUMINANCE_ALPHA:
return true;
default:
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
case GL_UNSIGNED_SHORT_4_4_4_4:
@@ -113,7 +104,7 @@ bool checkTextureFormatType(GLenum format, GLenum type)
case GL_RGBA:
return true;
default:
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
case GL_UNSIGNED_SHORT_5_6_5:
@@ -122,7 +113,7 @@ bool checkTextureFormatType(GLenum format, GLenum type)
case GL_RGB:
return true;
default:
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
case GL_UNSIGNED_SHORT:
@@ -132,7 +123,7 @@ bool checkTextureFormatType(GLenum format, GLenum type)
case GL_DEPTH_COMPONENT:
return true;
default:
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
case GL_UNSIGNED_INT_24_8_OES:
@@ -141,11 +132,11 @@ bool checkTextureFormatType(GLenum format, GLenum type)
case GL_DEPTH_STENCIL_OES:
return true;
default:
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
default:
- return error(GL_INVALID_ENUM, false);
+ return gl::error(GL_INVALID_ENUM, false);
}
}
@@ -155,12 +146,12 @@ bool validateSubImageParams2D(bool compressed, GLsizei width, GLsizei height,
{
if (!texture)
{
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
if (compressed != texture->isCompressed(level))
{
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
if (format != GL_NONE)
@@ -168,7 +159,7 @@ bool validateSubImageParams2D(bool compressed, GLsizei width, GLsizei height,
GLenum internalformat = gl::ConvertSizedInternalFormat(format, type);
if (internalformat != texture->getInternalFormat(level))
{
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
}
@@ -177,14 +168,14 @@ bool validateSubImageParams2D(bool compressed, GLsizei width, GLsizei height,
if ((width % 4 != 0 && width != texture->getWidth(0)) ||
(height % 4 != 0 && height != texture->getHeight(0)))
{
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
}
if (xoffset + width > texture->getWidth(level) ||
yoffset + height > texture->getHeight(level))
{
- return error(GL_INVALID_VALUE, false);
+ return gl::error(GL_INVALID_VALUE, false);
}
return true;
@@ -196,12 +187,12 @@ bool validateSubImageParamsCube(bool compressed, GLsizei width, GLsizei height,
{
if (!texture)
{
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
if (compressed != texture->isCompressed(target, level))
{
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
if (format != GL_NONE)
@@ -209,7 +200,7 @@ bool validateSubImageParamsCube(bool compressed, GLsizei width, GLsizei height,
GLenum internalformat = gl::ConvertSizedInternalFormat(format, type);
if (internalformat != texture->getInternalFormat(target, level))
{
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
}
@@ -218,14 +209,14 @@ bool validateSubImageParamsCube(bool compressed, GLsizei width, GLsizei height,
if ((width % 4 != 0 && width != texture->getWidth(target, 0)) ||
(height % 4 != 0 && height != texture->getHeight(target, 0)))
{
- return error(GL_INVALID_OPERATION, false);
+ return gl::error(GL_INVALID_OPERATION, false);
}
}
if (xoffset + width > texture->getWidth(target, level) ||
yoffset + height > texture->getHeight(target, level))
{
- return error(GL_INVALID_VALUE, false);
+ return gl::error(GL_INVALID_VALUE, false);
}
return true;
@@ -277,7 +268,7 @@ void __stdcall glActiveTexture(GLenum texture)
{
if (texture < GL_TEXTURE0 || texture > GL_TEXTURE0 + context->getMaximumCombinedTextureImageUnits() - 1)
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
context->setActiveSampler(texture - GL_TEXTURE0);
@@ -285,7 +276,7 @@ void __stdcall glActiveTexture(GLenum texture)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -306,11 +297,11 @@ void __stdcall glAttachShader(GLuint program, GLuint shader)
{
if (context->getShader(program))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
@@ -318,23 +309,23 @@ void __stdcall glAttachShader(GLuint program, GLuint shader)
{
if (context->getProgram(shader))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
if (!programObject->attachShader(shaderObject))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -350,12 +341,12 @@ void __stdcall glBeginQueryEXT(GLenum target, GLuint id)
case GL_ANY_SAMPLES_PASSED_CONSERVATIVE_EXT:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (id == 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
gl::Context *context = gl::getNonLostContext();
@@ -367,7 +358,7 @@ void __stdcall glBeginQueryEXT(GLenum target, GLuint id)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -379,7 +370,7 @@ void __stdcall glBindAttribLocation(GLuint program, GLuint index, const GLchar*
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -392,17 +383,17 @@ void __stdcall glBindAttribLocation(GLuint program, GLuint index, const GLchar*
{
if (context->getShader(program))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
if (strncmp(name, "gl_", 3) == 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
programObject->bindAttributeLocation(index, name);
@@ -410,7 +401,7 @@ void __stdcall glBindAttribLocation(GLuint program, GLuint index, const GLchar*
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -433,13 +424,13 @@ void __stdcall glBindBuffer(GLenum target, GLuint buffer)
context->bindElementArrayBuffer(buffer);
return;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -451,7 +442,7 @@ void __stdcall glBindFramebuffer(GLenum target, GLuint framebuffer)
{
if (target != GL_FRAMEBUFFER && target != GL_DRAW_FRAMEBUFFER_ANGLE && target != GL_READ_FRAMEBUFFER_ANGLE)
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -471,7 +462,7 @@ void __stdcall glBindFramebuffer(GLenum target, GLuint framebuffer)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -483,7 +474,7 @@ void __stdcall glBindRenderbuffer(GLenum target, GLuint renderbuffer)
{
if (target != GL_RENDERBUFFER)
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -495,7 +486,7 @@ void __stdcall glBindRenderbuffer(GLenum target, GLuint renderbuffer)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -513,7 +504,7 @@ void __stdcall glBindTexture(GLenum target, GLuint texture)
if (textureObject && textureObject->getTarget() != target && texture != 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
switch (target)
@@ -525,13 +516,13 @@ void __stdcall glBindTexture(GLenum target, GLuint texture)
context->bindTextureCubeMap(texture);
return;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -551,7 +542,7 @@ void __stdcall glBlendColor(GLclampf red, GLclampf green, GLclampf blue, GLclamp
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -573,7 +564,7 @@ void __stdcall glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
case GL_FUNC_REVERSE_SUBTRACT:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (modeAlpha)
@@ -583,7 +574,7 @@ void __stdcall glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
case GL_FUNC_REVERSE_SUBTRACT:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -595,7 +586,7 @@ void __stdcall glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -630,7 +621,7 @@ void __stdcall glBlendFuncSeparate(GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha
case GL_SRC_ALPHA_SATURATE:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (dstRGB)
@@ -651,7 +642,7 @@ void __stdcall glBlendFuncSeparate(GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha
case GL_ONE_MINUS_CONSTANT_ALPHA:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (srcAlpha)
@@ -673,7 +664,7 @@ void __stdcall glBlendFuncSeparate(GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha
case GL_SRC_ALPHA_SATURATE:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (dstAlpha)
@@ -694,7 +685,7 @@ void __stdcall glBlendFuncSeparate(GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha
case GL_ONE_MINUS_CONSTANT_ALPHA:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
bool constantColorUsed = (srcRGB == GL_CONSTANT_COLOR || srcRGB == GL_ONE_MINUS_CONSTANT_COLOR ||
@@ -706,7 +697,7 @@ void __stdcall glBlendFuncSeparate(GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha
if (constantColorUsed && constantAlphaUsed)
{
ERR("Simultaneous use of GL_CONSTANT_ALPHA/GL_ONE_MINUS_CONSTANT_ALPHA and GL_CONSTANT_COLOR/GL_ONE_MINUS_CONSTANT_COLOR invalid under WebGL");
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
gl::Context *context = gl::getNonLostContext();
@@ -718,7 +709,7 @@ void __stdcall glBlendFuncSeparate(GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -731,7 +722,7 @@ void __stdcall glBufferData(GLenum target, GLsizeiptr size, const GLvoid* data,
{
if (size < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
switch (usage)
@@ -741,7 +732,7 @@ void __stdcall glBufferData(GLenum target, GLsizeiptr size, const GLvoid* data,
case GL_DYNAMIC_DRAW:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -759,12 +750,12 @@ void __stdcall glBufferData(GLenum target, GLsizeiptr size, const GLvoid* data,
buffer = context->getElementArrayBuffer();
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (!buffer)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
buffer->bufferData(data, size, usage);
@@ -772,7 +763,7 @@ void __stdcall glBufferData(GLenum target, GLsizeiptr size, const GLvoid* data,
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -785,7 +776,7 @@ void __stdcall glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size,
{
if (size < 0 || offset < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (data == NULL)
@@ -808,17 +799,17 @@ void __stdcall glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size,
buffer = context->getElementArrayBuffer();
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (!buffer)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if ((size_t)size + offset > buffer->size())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
buffer->bufferSubData(data, size, offset);
@@ -826,7 +817,7 @@ void __stdcall glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size,
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -838,7 +829,7 @@ GLenum __stdcall glCheckFramebufferStatus(GLenum target)
{
if (target != GL_FRAMEBUFFER && target != GL_DRAW_FRAMEBUFFER_ANGLE && target != GL_READ_FRAMEBUFFER_ANGLE)
{
- return error(GL_INVALID_ENUM, 0);
+ return gl::error(GL_INVALID_ENUM, 0);
}
gl::Context *context = gl::getNonLostContext();
@@ -860,7 +851,7 @@ GLenum __stdcall glCheckFramebufferStatus(GLenum target)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, 0);
+ return gl::error(GL_OUT_OF_MEMORY, 0);
}
return 0;
@@ -881,7 +872,7 @@ void __stdcall glClear(GLbitfield mask)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -901,7 +892,7 @@ void __stdcall glClearColor(GLclampf red, GLclampf green, GLclampf blue, GLclamp
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -920,7 +911,7 @@ void __stdcall glClearDepthf(GLclampf depth)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -939,7 +930,7 @@ void __stdcall glClearStencil(GLint s)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -959,7 +950,7 @@ void __stdcall glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboo
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -979,11 +970,11 @@ void __stdcall glCompileShader(GLuint shader)
{
if (context->getProgram(shader))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
@@ -992,7 +983,7 @@ void __stdcall glCompileShader(GLuint shader)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1007,7 +998,7 @@ void __stdcall glCompressedTexImage2D(GLenum target, GLint level, GLenum interna
{
if (!validImageSize(level, width, height) || border != 0 || imageSize < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
switch (internalformat)
@@ -1018,12 +1009,22 @@ void __stdcall glCompressedTexImage2D(GLenum target, GLint level, GLenum interna
case GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (border != 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_OPERATION);
+ }
+
+ if (width != 1 && width != 2 && width % 4 != 0)
+ {
+ return gl::error(GL_INVALID_OPERATION);
+ }
+
+ if (height != 1 && height != 2 && height % 4 != 0)
+ {
+ return gl::error(GL_INVALID_OPERATION);
}
gl::Context *context = gl::getNonLostContext();
@@ -1032,7 +1033,7 @@ void __stdcall glCompressedTexImage2D(GLenum target, GLint level, GLenum interna
{
if (level > context->getMaximumTextureLevel())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
switch (target)
@@ -1041,7 +1042,7 @@ void __stdcall glCompressedTexImage2D(GLenum target, GLint level, GLenum interna
if (width > (context->getMaximumTextureDimension() >> level) ||
height > (context->getMaximumTextureDimension() >> level))
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
break;
case GL_TEXTURE_CUBE_MAP_POSITIVE_X:
@@ -1052,17 +1053,17 @@ void __stdcall glCompressedTexImage2D(GLenum target, GLint level, GLenum interna
case GL_TEXTURE_CUBE_MAP_NEGATIVE_Z:
if (width != height)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (width > (context->getMaximumCubeTextureDimension() >> level) ||
height > (context->getMaximumCubeTextureDimension() >> level))
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (internalformat) {
@@ -1070,19 +1071,19 @@ void __stdcall glCompressedTexImage2D(GLenum target, GLint level, GLenum interna
case GL_COMPRESSED_RGBA_S3TC_DXT1_EXT:
if (!context->supportsDXT1Textures())
{
- return error(GL_INVALID_ENUM); // in this case, it's as though the internal format switch failed
+ return gl::error(GL_INVALID_ENUM); // in this case, it's as though the internal format switch failed
}
break;
case GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE:
if (!context->supportsDXT3Textures())
{
- return error(GL_INVALID_ENUM); // in this case, it's as though the internal format switch failed
+ return gl::error(GL_INVALID_ENUM); // in this case, it's as though the internal format switch failed
}
break;
case GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE:
if (!context->supportsDXT5Textures())
{
- return error(GL_INVALID_ENUM); // in this case, it's as though the internal format switch failed
+ return gl::error(GL_INVALID_ENUM); // in this case, it's as though the internal format switch failed
}
break;
default: UNREACHABLE();
@@ -1090,7 +1091,7 @@ void __stdcall glCompressedTexImage2D(GLenum target, GLint level, GLenum interna
if (imageSize != gl::ComputeCompressedSize(width, height, internalformat))
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (target == GL_TEXTURE_2D)
@@ -1099,12 +1100,12 @@ void __stdcall glCompressedTexImage2D(GLenum target, GLint level, GLenum interna
if (!texture)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (texture->isImmutable())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
texture->setCompressedImage(level, internalformat, width, height, imageSize, data);
@@ -1115,12 +1116,12 @@ void __stdcall glCompressedTexImage2D(GLenum target, GLint level, GLenum interna
if (!texture)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (texture->isImmutable())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
switch (target)
@@ -1141,7 +1142,7 @@ void __stdcall glCompressedTexImage2D(GLenum target, GLint level, GLenum interna
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1157,12 +1158,12 @@ void __stdcall glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffs
{
if (!gl::IsInternalTextureTarget(target))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (xoffset < 0 || yoffset < 0 || !validImageSize(level, width, height) || imageSize < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
switch (format)
@@ -1173,7 +1174,7 @@ void __stdcall glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffs
case GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (width == 0 || height == 0 || data == NULL)
@@ -1187,7 +1188,7 @@ void __stdcall glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffs
{
if (level > context->getMaximumTextureLevel())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
switch (format) {
@@ -1195,19 +1196,19 @@ void __stdcall glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffs
case GL_COMPRESSED_RGBA_S3TC_DXT1_EXT:
if (!context->supportsDXT1Textures())
{
- return error(GL_INVALID_ENUM); // in this case, it's as though the internal format switch failed
+ return gl::error(GL_INVALID_ENUM); // in this case, it's as though the internal format switch failed
}
break;
case GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE:
if (!context->supportsDXT3Textures())
{
- return error(GL_INVALID_ENUM); // in this case, it's as though the internal format switch failed
+ return gl::error(GL_INVALID_ENUM); // in this case, it's as though the internal format switch failed
}
break;
case GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE:
if (!context->supportsDXT5Textures())
{
- return error(GL_INVALID_ENUM); // in this case, it's as though the internal format switch failed
+ return gl::error(GL_INVALID_ENUM); // in this case, it's as though the internal format switch failed
}
break;
default: UNREACHABLE();
@@ -1215,12 +1216,12 @@ void __stdcall glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffs
if (imageSize != gl::ComputeCompressedSize(width, height, format))
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (xoffset % 4 != 0 || yoffset % 4 != 0)
{
- return error(GL_INVALID_OPERATION); // we wait to check the offsets until this point, because the multiple-of-four restriction
+ return gl::error(GL_INVALID_OPERATION); // we wait to check the offsets until this point, because the multiple-of-four restriction
// does not exist unless DXT textures are supported.
}
@@ -1248,7 +1249,7 @@ void __stdcall glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffs
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1262,12 +1263,12 @@ void __stdcall glCopyTexImage2D(GLenum target, GLint level, GLenum internalforma
{
if (!validImageSize(level, width, height))
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (border != 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -1276,7 +1277,7 @@ void __stdcall glCopyTexImage2D(GLenum target, GLint level, GLenum internalforma
{
if (level > context->getMaximumTextureLevel())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
switch (target)
@@ -1285,7 +1286,7 @@ void __stdcall glCopyTexImage2D(GLenum target, GLint level, GLenum internalforma
if (width > (context->getMaximumTextureDimension() >> level) ||
height > (context->getMaximumTextureDimension() >> level))
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
break;
case GL_TEXTURE_CUBE_MAP_POSITIVE_X:
@@ -1296,32 +1297,32 @@ void __stdcall glCopyTexImage2D(GLenum target, GLint level, GLenum internalforma
case GL_TEXTURE_CUBE_MAP_NEGATIVE_Z:
if (width != height)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (width > (context->getMaximumCubeTextureDimension() >> level) ||
height > (context->getMaximumCubeTextureDimension() >> level))
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Framebuffer *framebuffer = context->getReadFramebuffer();
if (framebuffer->completeness() != GL_FRAMEBUFFER_COMPLETE)
{
- return error(GL_INVALID_FRAMEBUFFER_OPERATION);
+ return gl::error(GL_INVALID_FRAMEBUFFER_OPERATION);
}
- if (context->getReadFramebufferHandle() != 0 && framebuffer->getColorbuffer()->getSamples() != 0)
+ if (context->getReadFramebufferHandle() != 0 && framebuffer->getSamples() != 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
- gl::Renderbuffer *source = framebuffer->getColorbuffer();
+ gl::Renderbuffer *source = framebuffer->getReadColorbuffer();
GLenum colorbufferFormat = source->getInternalFormat();
// [OpenGL ES 2.0.24] table 3.9
@@ -1331,9 +1332,10 @@ void __stdcall glCopyTexImage2D(GLenum target, GLint level, GLenum internalforma
if (colorbufferFormat != GL_ALPHA8_EXT &&
colorbufferFormat != GL_RGBA4 &&
colorbufferFormat != GL_RGB5_A1 &&
+ colorbufferFormat != GL_BGRA8_EXT &&
colorbufferFormat != GL_RGBA8_OES)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
case GL_LUMINANCE:
@@ -1342,49 +1344,51 @@ void __stdcall glCopyTexImage2D(GLenum target, GLint level, GLenum internalforma
colorbufferFormat != GL_RGB8_OES &&
colorbufferFormat != GL_RGBA4 &&
colorbufferFormat != GL_RGB5_A1 &&
+ colorbufferFormat != GL_BGRA8_EXT &&
colorbufferFormat != GL_RGBA8_OES)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
case GL_LUMINANCE_ALPHA:
case GL_RGBA:
if (colorbufferFormat != GL_RGBA4 &&
colorbufferFormat != GL_RGB5_A1 &&
+ colorbufferFormat != GL_BGRA8_EXT &&
colorbufferFormat != GL_RGBA8_OES)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
case GL_COMPRESSED_RGB_S3TC_DXT1_EXT:
case GL_COMPRESSED_RGBA_S3TC_DXT1_EXT:
if (context->supportsDXT1Textures())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE:
if (context->supportsDXT3Textures())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE:
if (context->supportsDXT5Textures())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_DEPTH_COMPONENT:
@@ -1394,14 +1398,14 @@ void __stdcall glCopyTexImage2D(GLenum target, GLint level, GLenum internalforma
case GL_DEPTH24_STENCIL8_OES:
if (context->supportsDepthTextures())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (target == GL_TEXTURE_2D)
@@ -1410,12 +1414,12 @@ void __stdcall glCopyTexImage2D(GLenum target, GLint level, GLenum internalforma
if (!texture)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (texture->isImmutable())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
texture->copyImage(level, internalformat, x, y, width, height, framebuffer);
@@ -1426,12 +1430,12 @@ void __stdcall glCopyTexImage2D(GLenum target, GLint level, GLenum internalforma
if (!texture)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (texture->isImmutable())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
texture->copyImage(target, level, internalformat, x, y, width, height, framebuffer);
@@ -1441,7 +1445,7 @@ void __stdcall glCopyTexImage2D(GLenum target, GLint level, GLenum internalforma
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1455,17 +1459,17 @@ void __stdcall glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GL
{
if (!gl::IsInternalTextureTarget(target))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (level < 0 || xoffset < 0 || yoffset < 0 || width < 0 || height < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (std::numeric_limits<GLsizei>::max() - xoffset < width || std::numeric_limits<GLsizei>::max() - yoffset < height)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (width == 0 || height == 0)
@@ -1479,22 +1483,22 @@ void __stdcall glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GL
{
if (level > context->getMaximumTextureLevel())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Framebuffer *framebuffer = context->getReadFramebuffer();
if (framebuffer->completeness() != GL_FRAMEBUFFER_COMPLETE)
{
- return error(GL_INVALID_FRAMEBUFFER_OPERATION);
+ return gl::error(GL_INVALID_FRAMEBUFFER_OPERATION);
}
- if (context->getReadFramebufferHandle() != 0 && framebuffer->getColorbuffer()->getSamples() != 0)
+ if (context->getReadFramebufferHandle() != 0 && framebuffer->getSamples() != 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
- gl::Renderbuffer *source = framebuffer->getColorbuffer();
+ gl::Renderbuffer *source = framebuffer->getReadColorbuffer();
GLenum colorbufferFormat = source->getInternalFormat();
gl::Texture *texture = NULL;
GLenum textureFormat = GL_RGBA;
@@ -1532,7 +1536,7 @@ void __stdcall glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GL
colorbufferFormat != GL_RGB5_A1 &&
colorbufferFormat != GL_RGBA8_OES)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
case GL_LUMINANCE:
@@ -1543,7 +1547,7 @@ void __stdcall glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GL
colorbufferFormat != GL_RGB5_A1 &&
colorbufferFormat != GL_RGBA8_OES)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
case GL_LUMINANCE_ALPHA:
@@ -1552,19 +1556,19 @@ void __stdcall glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GL
colorbufferFormat != GL_RGB5_A1 &&
colorbufferFormat != GL_RGBA8_OES)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
case GL_COMPRESSED_RGB_S3TC_DXT1_EXT:
case GL_COMPRESSED_RGBA_S3TC_DXT1_EXT:
case GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE:
case GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE:
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
case GL_DEPTH_COMPONENT:
case GL_DEPTH_STENCIL_OES:
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
default:
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
texture->copySubImage(target, level, xoffset, yoffset, x, y, width, height, framebuffer);
@@ -1573,7 +1577,7 @@ void __stdcall glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GL
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1592,7 +1596,7 @@ GLuint __stdcall glCreateProgram(void)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, 0);
+ return gl::error(GL_OUT_OF_MEMORY, 0);
}
return 0;
@@ -1614,13 +1618,13 @@ GLuint __stdcall glCreateShader(GLenum type)
case GL_VERTEX_SHADER:
return context->createShader(type);
default:
- return error(GL_INVALID_ENUM, 0);
+ return gl::error(GL_INVALID_ENUM, 0);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, 0);
+ return gl::error(GL_OUT_OF_MEMORY, 0);
}
return 0;
@@ -1647,12 +1651,12 @@ void __stdcall glCullFace(GLenum mode)
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1664,7 +1668,7 @@ void __stdcall glDeleteBuffers(GLsizei n, const GLuint* buffers)
{
if (n < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -1679,7 +1683,7 @@ void __stdcall glDeleteBuffers(GLsizei n, const GLuint* buffers)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1691,7 +1695,7 @@ void __stdcall glDeleteFencesNV(GLsizei n, const GLuint* fences)
{
if (n < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -1706,7 +1710,7 @@ void __stdcall glDeleteFencesNV(GLsizei n, const GLuint* fences)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1718,7 +1722,7 @@ void __stdcall glDeleteFramebuffers(GLsizei n, const GLuint* framebuffers)
{
if (n < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -1736,7 +1740,7 @@ void __stdcall glDeleteFramebuffers(GLsizei n, const GLuint* framebuffers)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1759,11 +1763,11 @@ void __stdcall glDeleteProgram(GLuint program)
{
if(context->getShader(program))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
@@ -1772,7 +1776,7 @@ void __stdcall glDeleteProgram(GLuint program)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1784,7 +1788,7 @@ void __stdcall glDeleteQueriesEXT(GLsizei n, const GLuint *ids)
{
if (n < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -1799,7 +1803,7 @@ void __stdcall glDeleteQueriesEXT(GLsizei n, const GLuint *ids)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1811,7 +1815,7 @@ void __stdcall glDeleteRenderbuffers(GLsizei n, const GLuint* renderbuffers)
{
if (n < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -1826,7 +1830,7 @@ void __stdcall glDeleteRenderbuffers(GLsizei n, const GLuint* renderbuffers)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1849,11 +1853,11 @@ void __stdcall glDeleteShader(GLuint shader)
{
if(context->getProgram(shader))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
@@ -1862,7 +1866,7 @@ void __stdcall glDeleteShader(GLuint shader)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1874,7 +1878,7 @@ void __stdcall glDeleteTextures(GLsizei n, const GLuint* textures)
{
if (n < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -1892,7 +1896,7 @@ void __stdcall glDeleteTextures(GLsizei n, const GLuint* textures)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1914,7 +1918,7 @@ void __stdcall glDepthFunc(GLenum func)
case GL_NOTEQUAL:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -1926,7 +1930,7 @@ void __stdcall glDepthFunc(GLenum func)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1945,7 +1949,7 @@ void __stdcall glDepthMask(GLboolean flag)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1964,7 +1968,7 @@ void __stdcall glDepthRangef(GLclampf zNear, GLclampf zFar)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -1988,11 +1992,11 @@ void __stdcall glDetachShader(GLuint program, GLuint shader)
shaderByProgramHandle = context->getShader(program);
if (!shaderByProgramHandle)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
else
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
@@ -2001,23 +2005,23 @@ void __stdcall glDetachShader(GLuint program, GLuint shader)
gl::Program *programByShaderHandle = context->getProgram(shader);
if (!programByShaderHandle)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
else
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
if (!programObject->detachShader(shaderObject))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2043,13 +2047,13 @@ void __stdcall glDisable(GLenum cap)
case GL_BLEND: context->setBlend(false); break;
case GL_DITHER: context->setDither(false); break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2061,7 +2065,7 @@ void __stdcall glDisableVertexAttribArray(GLuint index)
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2073,7 +2077,7 @@ void __stdcall glDisableVertexAttribArray(GLuint index)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2085,7 +2089,7 @@ void __stdcall glDrawArrays(GLenum mode, GLint first, GLsizei count)
{
if (count < 0 || first < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2097,7 +2101,7 @@ void __stdcall glDrawArrays(GLenum mode, GLint first, GLsizei count)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2109,7 +2113,7 @@ void __stdcall glDrawArraysInstancedANGLE(GLenum mode, GLint first, GLsizei coun
{
if (count < 0 || first < 0 || primcount < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (primcount > 0)
@@ -2124,7 +2128,7 @@ void __stdcall glDrawArraysInstancedANGLE(GLenum mode, GLint first, GLsizei coun
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2137,7 +2141,7 @@ void __stdcall glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLv
{
if (count < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2152,11 +2156,11 @@ void __stdcall glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLv
case GL_UNSIGNED_INT:
if (!context->supports32bitIndices())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
context->drawElements(mode, count, type, indices, 0);
@@ -2164,7 +2168,7 @@ void __stdcall glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLv
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2177,7 +2181,7 @@ void __stdcall glDrawElementsInstancedANGLE(GLenum mode, GLsizei count, GLenum t
{
if (count < 0 || primcount < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (primcount > 0)
@@ -2194,11 +2198,11 @@ void __stdcall glDrawElementsInstancedANGLE(GLenum mode, GLsizei count, GLenum t
case GL_UNSIGNED_INT:
if (!context->supports32bitIndices())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
context->drawElements(mode, count, type, indices, primcount);
@@ -2207,7 +2211,7 @@ void __stdcall glDrawElementsInstancedANGLE(GLenum mode, GLsizei count, GLenum t
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2233,13 +2237,13 @@ void __stdcall glEnable(GLenum cap)
case GL_BLEND: context->setBlend(true); break;
case GL_DITHER: context->setDither(true); break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2251,7 +2255,7 @@ void __stdcall glEnableVertexAttribArray(GLuint index)
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2263,7 +2267,7 @@ void __stdcall glEnableVertexAttribArray(GLuint index)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2279,7 +2283,7 @@ void __stdcall glEndQueryEXT(GLenum target)
case GL_ANY_SAMPLES_PASSED_CONSERVATIVE_EXT:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -2291,7 +2295,7 @@ void __stdcall glEndQueryEXT(GLenum target)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2309,7 +2313,7 @@ void __stdcall glFinishFenceNV(GLuint fence)
if (fenceObject == NULL)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
fenceObject->finishFence();
@@ -2317,7 +2321,7 @@ void __stdcall glFinishFenceNV(GLuint fence)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2336,7 +2340,7 @@ void __stdcall glFinish(void)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2355,7 +2359,7 @@ void __stdcall glFlush(void)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2369,7 +2373,7 @@ void __stdcall glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenu
if ((target != GL_FRAMEBUFFER && target != GL_DRAW_FRAMEBUFFER_ANGLE && target != GL_READ_FRAMEBUFFER_ANGLE)
|| (renderbuffertarget != GL_RENDERBUFFER && renderbuffer != 0))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -2391,28 +2395,39 @@ void __stdcall glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenu
if (!framebuffer || (framebufferHandle == 0 && renderbuffer != 0))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
- switch (attachment)
+ if (attachment >= GL_COLOR_ATTACHMENT0_EXT && attachment <= GL_COLOR_ATTACHMENT15_EXT)
{
- case GL_COLOR_ATTACHMENT0:
- framebuffer->setColorbuffer(GL_RENDERBUFFER, renderbuffer);
- break;
- case GL_DEPTH_ATTACHMENT:
- framebuffer->setDepthbuffer(GL_RENDERBUFFER, renderbuffer);
- break;
- case GL_STENCIL_ATTACHMENT:
- framebuffer->setStencilbuffer(GL_RENDERBUFFER, renderbuffer);
- break;
- default:
- return error(GL_INVALID_ENUM);
+ const unsigned int colorAttachment = (attachment - GL_COLOR_ATTACHMENT0_EXT);
+
+ if (colorAttachment >= context->getMaximumRenderTargets())
+ {
+ return gl::error(GL_INVALID_VALUE);
+ }
+
+ framebuffer->setColorbuffer(colorAttachment, GL_RENDERBUFFER, renderbuffer);
+ }
+ else
+ {
+ switch (attachment)
+ {
+ case GL_DEPTH_ATTACHMENT:
+ framebuffer->setDepthbuffer(GL_RENDERBUFFER, renderbuffer);
+ break;
+ case GL_STENCIL_ATTACHMENT:
+ framebuffer->setStencilbuffer(GL_RENDERBUFFER, renderbuffer);
+ break;
+ default:
+ return gl::error(GL_INVALID_ENUM);
+ }
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2425,23 +2440,34 @@ void __stdcall glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum t
{
if (target != GL_FRAMEBUFFER && target != GL_DRAW_FRAMEBUFFER_ANGLE && target != GL_READ_FRAMEBUFFER_ANGLE)
{
- return error(GL_INVALID_ENUM);
- }
-
- switch (attachment)
- {
- case GL_COLOR_ATTACHMENT0:
- case GL_DEPTH_ATTACHMENT:
- case GL_STENCIL_ATTACHMENT:
- break;
- default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
if (context)
{
+ if (attachment >= GL_COLOR_ATTACHMENT0_EXT && attachment <= GL_COLOR_ATTACHMENT15_EXT)
+ {
+ const unsigned int colorAttachment = (attachment - GL_COLOR_ATTACHMENT0_EXT);
+
+ if (colorAttachment >= context->getMaximumRenderTargets())
+ {
+ return gl::error(GL_INVALID_VALUE);
+ }
+ }
+ else
+ {
+ switch (attachment)
+ {
+ case GL_DEPTH_ATTACHMENT:
+ case GL_STENCIL_ATTACHMENT:
+ break;
+ default:
+ return gl::error(GL_INVALID_ENUM);
+ }
+ }
+
if (texture == 0)
{
textarget = GL_NONE;
@@ -2452,7 +2478,7 @@ void __stdcall glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum t
if (tex == NULL)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
switch (textarget)
@@ -2461,12 +2487,12 @@ void __stdcall glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum t
{
if (tex->getTarget() != GL_TEXTURE_2D)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
gl::Texture2D *tex2d = static_cast<gl::Texture2D *>(tex);
if (tex2d->isCompressed(0))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
}
@@ -2480,23 +2506,23 @@ void __stdcall glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum t
{
if (tex->getTarget() != GL_TEXTURE_CUBE_MAP)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
gl::TextureCubeMap *texcube = static_cast<gl::TextureCubeMap *>(tex);
if (texcube->isCompressed(textarget, level))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
}
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (level != 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
@@ -2515,20 +2541,33 @@ void __stdcall glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum t
if (framebufferHandle == 0 || !framebuffer)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
- switch (attachment)
+ if (attachment >= GL_COLOR_ATTACHMENT0_EXT && attachment <= GL_COLOR_ATTACHMENT15_EXT)
{
- case GL_COLOR_ATTACHMENT0: framebuffer->setColorbuffer(textarget, texture); break;
- case GL_DEPTH_ATTACHMENT: framebuffer->setDepthbuffer(textarget, texture); break;
- case GL_STENCIL_ATTACHMENT: framebuffer->setStencilbuffer(textarget, texture); break;
+ const unsigned int colorAttachment = (attachment - GL_COLOR_ATTACHMENT0_EXT);
+
+ if (colorAttachment >= context->getMaximumRenderTargets())
+ {
+ return gl::error(GL_INVALID_VALUE);
+ }
+
+ framebuffer->setColorbuffer(colorAttachment, textarget, texture);
+ }
+ else
+ {
+ switch (attachment)
+ {
+ case GL_DEPTH_ATTACHMENT: framebuffer->setDepthbuffer(textarget, texture); break;
+ case GL_STENCIL_ATTACHMENT: framebuffer->setStencilbuffer(textarget, texture); break;
+ }
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2552,12 +2591,12 @@ void __stdcall glFrontFace(GLenum mode)
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2569,7 +2608,7 @@ void __stdcall glGenBuffers(GLsizei n, GLuint* buffers)
{
if (n < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2584,7 +2623,7 @@ void __stdcall glGenBuffers(GLsizei n, GLuint* buffers)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2606,11 +2645,11 @@ void __stdcall glGenerateMipmap(GLenum target)
if (tex2d->isCompressed(0))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (tex2d->isDepth(0))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
tex2d->generateMipmaps();
@@ -2623,7 +2662,7 @@ void __stdcall glGenerateMipmap(GLenum target)
if (texcube->isCompressed(GL_TEXTURE_CUBE_MAP_POSITIVE_X, 0))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
texcube->generateMipmaps();
@@ -2631,13 +2670,13 @@ void __stdcall glGenerateMipmap(GLenum target)
}
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2649,7 +2688,7 @@ void __stdcall glGenFencesNV(GLsizei n, GLuint* fences)
{
if (n < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2664,7 +2703,7 @@ void __stdcall glGenFencesNV(GLsizei n, GLuint* fences)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2676,7 +2715,7 @@ void __stdcall glGenFramebuffers(GLsizei n, GLuint* framebuffers)
{
if (n < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2691,7 +2730,7 @@ void __stdcall glGenFramebuffers(GLsizei n, GLuint* framebuffers)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2703,7 +2742,7 @@ void __stdcall glGenQueriesEXT(GLsizei n, GLuint* ids)
{
if (n < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2718,7 +2757,7 @@ void __stdcall glGenQueriesEXT(GLsizei n, GLuint* ids)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2730,7 +2769,7 @@ void __stdcall glGenRenderbuffers(GLsizei n, GLuint* renderbuffers)
{
if (n < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2745,7 +2784,7 @@ void __stdcall glGenRenderbuffers(GLsizei n, GLuint* renderbuffers)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2757,7 +2796,7 @@ void __stdcall glGenTextures(GLsizei n, GLuint* textures)
{
if (n < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2772,7 +2811,7 @@ void __stdcall glGenTextures(GLsizei n, GLuint* textures)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2786,7 +2825,7 @@ void __stdcall glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufsize,
{
if (bufsize < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2799,17 +2838,17 @@ void __stdcall glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufsize,
{
if (context->getShader(program))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
if (index >= (GLuint)programObject->getActiveAttributeCount())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
programObject->getActiveAttribute(index, bufsize, length, size, type, name);
@@ -2817,7 +2856,7 @@ void __stdcall glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufsize,
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2831,7 +2870,7 @@ void __stdcall glGetActiveUniform(GLuint program, GLuint index, GLsizei bufsize,
{
if (bufsize < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2844,17 +2883,17 @@ void __stdcall glGetActiveUniform(GLuint program, GLuint index, GLsizei bufsize,
{
if (context->getShader(program))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
if (index >= (GLuint)programObject->getActiveUniformCount())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
programObject->getActiveUniform(index, bufsize, length, size, type, name);
@@ -2862,7 +2901,7 @@ void __stdcall glGetActiveUniform(GLuint program, GLuint index, GLsizei bufsize,
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2875,7 +2914,7 @@ void __stdcall glGetAttachedShaders(GLuint program, GLsizei maxcount, GLsizei* c
{
if (maxcount < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -2888,11 +2927,11 @@ void __stdcall glGetAttachedShaders(GLuint program, GLsizei maxcount, GLsizei* c
{
if (context->getShader(program))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
@@ -2901,7 +2940,7 @@ void __stdcall glGetAttachedShaders(GLuint program, GLsizei maxcount, GLsizei* c
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -2922,18 +2961,18 @@ int __stdcall glGetAttribLocation(GLuint program, const GLchar* name)
{
if (context->getShader(program))
{
- return error(GL_INVALID_OPERATION, -1);
+ return gl::error(GL_INVALID_OPERATION, -1);
}
else
{
- return error(GL_INVALID_VALUE, -1);
+ return gl::error(GL_INVALID_VALUE, -1);
}
}
gl::ProgramBinary *programBinary = programObject->getProgramBinary();
if (!programObject->isLinked() || !programBinary)
{
- return error(GL_INVALID_OPERATION, -1);
+ return gl::error(GL_INVALID_OPERATION, -1);
}
return programBinary->getAttributeLocation(name);
@@ -2941,7 +2980,7 @@ int __stdcall glGetAttribLocation(GLuint program, const GLchar* name)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, -1);
+ return gl::error(GL_OUT_OF_MEMORY, -1);
}
return -1;
@@ -2962,7 +3001,7 @@ void __stdcall glGetBooleanv(GLenum pname, GLboolean* params)
GLenum nativeType;
unsigned int numParams = 0;
if (!context->getQueryParameterInfo(pname, &nativeType, &numParams))
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
if (numParams == 0)
return; // it is known that the pname is valid, but there are no parameters to return
@@ -3006,7 +3045,7 @@ void __stdcall glGetBooleanv(GLenum pname, GLboolean* params)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3030,13 +3069,13 @@ void __stdcall glGetBufferParameteriv(GLenum target, GLenum pname, GLint* params
case GL_ELEMENT_ARRAY_BUFFER:
buffer = context->getElementArrayBuffer();
break;
- default: return error(GL_INVALID_ENUM);
+ default: return gl::error(GL_INVALID_ENUM);
}
if (!buffer)
{
// A null buffer means that "0" is bound to the requested buffer target
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
switch (pname)
@@ -3047,13 +3086,13 @@ void __stdcall glGetBufferParameteriv(GLenum target, GLenum pname, GLint* params
case GL_BUFFER_SIZE:
*params = buffer->size();
break;
- default: return error(GL_INVALID_ENUM);
+ default: return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3086,7 +3125,7 @@ void __stdcall glGetFenceivNV(GLuint fence, GLenum pname, GLint *params)
if (fenceObject == NULL)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
fenceObject->getFenceiv(pname, params);
@@ -3094,7 +3133,7 @@ void __stdcall glGetFenceivNV(GLuint fence, GLenum pname, GLint *params)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3113,7 +3152,7 @@ void __stdcall glGetFloatv(GLenum pname, GLfloat* params)
GLenum nativeType;
unsigned int numParams = 0;
if (!context->getQueryParameterInfo(pname, &nativeType, &numParams))
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
if (numParams == 0)
return; // it is known that the pname is valid, but that there are no parameters to return.
@@ -3154,7 +3193,7 @@ void __stdcall glGetFloatv(GLenum pname, GLfloat* params)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3171,7 +3210,7 @@ void __stdcall glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attac
{
if (target != GL_FRAMEBUFFER && target != GL_DRAW_FRAMEBUFFER_ANGLE && target != GL_READ_FRAMEBUFFER_ANGLE)
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Framebuffer *framebuffer = NULL;
@@ -3179,7 +3218,7 @@ void __stdcall glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attac
{
if(context->getReadFramebufferHandle() == 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
framebuffer = context->getReadFramebuffer();
@@ -3188,7 +3227,7 @@ void __stdcall glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attac
{
if (context->getDrawFramebufferHandle() == 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
framebuffer = context->getDrawFramebuffer();
@@ -3196,21 +3235,33 @@ void __stdcall glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attac
GLenum attachmentType;
GLuint attachmentHandle;
- switch (attachment)
+
+ if (attachment >= GL_COLOR_ATTACHMENT0_EXT && attachment <= GL_COLOR_ATTACHMENT15_EXT)
{
- case GL_COLOR_ATTACHMENT0:
- attachmentType = framebuffer->getColorbufferType();
- attachmentHandle = framebuffer->getColorbufferHandle();
- break;
- case GL_DEPTH_ATTACHMENT:
- attachmentType = framebuffer->getDepthbufferType();
- attachmentHandle = framebuffer->getDepthbufferHandle();
- break;
- case GL_STENCIL_ATTACHMENT:
- attachmentType = framebuffer->getStencilbufferType();
- attachmentHandle = framebuffer->getStencilbufferHandle();
- break;
- default: return error(GL_INVALID_ENUM);
+ const unsigned int colorAttachment = (attachment - GL_COLOR_ATTACHMENT0_EXT);
+
+ if (colorAttachment >= context->getMaximumRenderTargets())
+ {
+ return gl::error(GL_INVALID_ENUM);
+ }
+
+ attachmentType = framebuffer->getColorbufferType(colorAttachment);
+ attachmentHandle = framebuffer->getColorbufferHandle(colorAttachment);
+ }
+ else
+ {
+ switch (attachment)
+ {
+ case GL_DEPTH_ATTACHMENT:
+ attachmentType = framebuffer->getDepthbufferType();
+ attachmentHandle = framebuffer->getDepthbufferHandle();
+ break;
+ case GL_STENCIL_ATTACHMENT:
+ attachmentType = framebuffer->getStencilbufferType();
+ attachmentHandle = framebuffer->getStencilbufferHandle();
+ break;
+ default: return gl::error(GL_INVALID_ENUM);
+ }
}
GLenum attachmentObjectType; // Type category
@@ -3240,7 +3291,7 @@ void __stdcall glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attac
}
else
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL:
@@ -3250,7 +3301,7 @@ void __stdcall glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attac
}
else
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE:
@@ -3267,17 +3318,17 @@ void __stdcall glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attac
}
else
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3317,7 +3368,7 @@ void __stdcall glGetIntegerv(GLenum pname, GLint* params)
GLenum nativeType;
unsigned int numParams = 0;
if (!context->getQueryParameterInfo(pname, &nativeType, &numParams))
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
if (numParams == 0)
return; // it is known that pname is valid, but there are no parameters to return
@@ -3363,7 +3414,7 @@ void __stdcall glGetIntegerv(GLenum pname, GLint* params)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3381,7 +3432,7 @@ void __stdcall glGetProgramiv(GLuint program, GLenum pname, GLint* params)
if (!programObject)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
switch (pname)
@@ -3417,13 +3468,13 @@ void __stdcall glGetProgramiv(GLuint program, GLenum pname, GLint* params)
*params = programObject->getProgramBinaryLength();
return;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3436,7 +3487,7 @@ void __stdcall glGetProgramInfoLog(GLuint program, GLsizei bufsize, GLsizei* len
{
if (bufsize < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -3447,7 +3498,7 @@ void __stdcall glGetProgramInfoLog(GLuint program, GLsizei bufsize, GLsizei* len
if (!programObject)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
programObject->getInfoLog(bufsize, length, infolog);
@@ -3455,7 +3506,7 @@ void __stdcall glGetProgramInfoLog(GLuint program, GLsizei bufsize, GLsizei* len
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3470,7 +3521,7 @@ void __stdcall glGetQueryivEXT(GLenum target, GLenum pname, GLint *params)
case GL_CURRENT_QUERY_EXT:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -3482,7 +3533,7 @@ void __stdcall glGetQueryivEXT(GLenum target, GLenum pname, GLint *params)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3498,7 +3549,7 @@ void __stdcall glGetQueryObjectuivEXT(GLuint id, GLenum pname, GLuint *params)
case GL_QUERY_RESULT_AVAILABLE_EXT:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -3508,12 +3559,12 @@ void __stdcall glGetQueryObjectuivEXT(GLuint id, GLenum pname, GLuint *params)
if (!queryObject)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (context->getActiveQuery(queryObject->getType()) == id)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
switch(pname)
@@ -3531,7 +3582,7 @@ void __stdcall glGetQueryObjectuivEXT(GLuint id, GLenum pname, GLuint *params)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3547,12 +3598,12 @@ void __stdcall glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint*
{
if (target != GL_RENDERBUFFER)
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (context->getRenderbufferHandle() == 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
gl::Renderbuffer *renderbuffer = context->getRenderbuffer(context->getRenderbufferHandle());
@@ -3575,17 +3626,17 @@ void __stdcall glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint*
}
else
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3603,7 +3654,7 @@ void __stdcall glGetShaderiv(GLuint shader, GLenum pname, GLint* params)
if (!shaderObject)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
switch (pname)
@@ -3627,13 +3678,13 @@ void __stdcall glGetShaderiv(GLuint shader, GLenum pname, GLint* params)
*params = shaderObject->getTranslatedSourceLength();
return;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3646,7 +3697,7 @@ void __stdcall glGetShaderInfoLog(GLuint shader, GLsizei bufsize, GLsizei* lengt
{
if (bufsize < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -3657,7 +3708,7 @@ void __stdcall glGetShaderInfoLog(GLuint shader, GLsizei bufsize, GLsizei* lengt
if (!shaderObject)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
shaderObject->getInfoLog(bufsize, length, infolog);
@@ -3665,7 +3716,7 @@ void __stdcall glGetShaderInfoLog(GLuint shader, GLsizei bufsize, GLsizei* lengt
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3682,7 +3733,7 @@ void __stdcall glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontyp
case GL_FRAGMENT_SHADER:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (precisiontype)
@@ -3705,12 +3756,12 @@ void __stdcall glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontyp
*precision = 0;
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3723,7 +3774,7 @@ void __stdcall glGetShaderSource(GLuint shader, GLsizei bufsize, GLsizei* length
{
if (bufsize < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -3734,7 +3785,7 @@ void __stdcall glGetShaderSource(GLuint shader, GLsizei bufsize, GLsizei* length
if (!shaderObject)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
shaderObject->getSource(bufsize, length, source);
@@ -3742,7 +3793,7 @@ void __stdcall glGetShaderSource(GLuint shader, GLsizei bufsize, GLsizei* length
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3755,7 +3806,7 @@ void __stdcall glGetTranslatedShaderSourceANGLE(GLuint shader, GLsizei bufsize,
{
if (bufsize < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -3766,7 +3817,7 @@ void __stdcall glGetTranslatedShaderSourceANGLE(GLuint shader, GLsizei bufsize,
if (!shaderObject)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
shaderObject->getTranslatedSource(bufsize, length, source);
@@ -3774,7 +3825,7 @@ void __stdcall glGetTranslatedShaderSourceANGLE(GLuint shader, GLsizei bufsize,
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3799,12 +3850,12 @@ const GLubyte* __stdcall glGetString(GLenum name)
case GL_EXTENSIONS:
return (GLubyte*)((context != NULL) ? context->getExtensionString() : "");
default:
- return error(GL_INVALID_ENUM, (GLubyte*)NULL);
+ return gl::error(GL_INVALID_ENUM, (GLubyte*)NULL);
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, (GLubyte*)NULL);
+ return gl::error(GL_OUT_OF_MEMORY, (GLubyte*)NULL);
}
}
@@ -3829,7 +3880,7 @@ void __stdcall glGetTexParameterfv(GLenum target, GLenum pname, GLfloat* params)
texture = context->getTextureCubeMap();
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (pname)
@@ -3855,18 +3906,18 @@ void __stdcall glGetTexParameterfv(GLenum target, GLenum pname, GLfloat* params)
case GL_TEXTURE_MAX_ANISOTROPY_EXT:
if (!context->supportsTextureFilterAnisotropy())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
*params = (GLfloat)texture->getMaxAnisotropy();
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3891,7 +3942,7 @@ void __stdcall glGetTexParameteriv(GLenum target, GLenum pname, GLint* params)
texture = context->getTextureCubeMap();
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (pname)
@@ -3917,18 +3968,18 @@ void __stdcall glGetTexParameteriv(GLenum target, GLenum pname, GLint* params)
case GL_TEXTURE_MAX_ANISOTROPY_EXT:
if (!context->supportsTextureFilterAnisotropy())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
*params = (GLint)texture->getMaxAnisotropy();
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3941,7 +3992,7 @@ void __stdcall glGetnUniformfvEXT(GLuint program, GLint location, GLsizei bufSiz
{
if (bufSize < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -3950,31 +4001,31 @@ void __stdcall glGetnUniformfvEXT(GLuint program, GLint location, GLsizei bufSiz
{
if (program == 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Program *programObject = context->getProgram(program);
if (!programObject || !programObject->isLinked())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
gl::ProgramBinary *programBinary = programObject->getProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->getUniformfv(location, &bufSize, params))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -3990,31 +4041,31 @@ void __stdcall glGetUniformfv(GLuint program, GLint location, GLfloat* params)
{
if (program == 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Program *programObject = context->getProgram(program);
if (!programObject || !programObject->isLinked())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
gl::ProgramBinary *programBinary = programObject->getProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->getUniformfv(location, NULL, params))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4027,7 +4078,7 @@ void __stdcall glGetnUniformivEXT(GLuint program, GLint location, GLsizei bufSiz
{
if (bufSize < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -4036,31 +4087,31 @@ void __stdcall glGetnUniformivEXT(GLuint program, GLint location, GLsizei bufSiz
{
if (program == 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Program *programObject = context->getProgram(program);
if (!programObject || !programObject->isLinked())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
gl::ProgramBinary *programBinary = programObject->getProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->getUniformiv(location, &bufSize, params))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4076,31 +4127,31 @@ void __stdcall glGetUniformiv(GLuint program, GLint location, GLint* params)
{
if (program == 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Program *programObject = context->getProgram(program);
if (!programObject || !programObject->isLinked())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
gl::ProgramBinary *programBinary = programObject->getProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->getUniformiv(location, NULL, params))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4125,18 +4176,18 @@ int __stdcall glGetUniformLocation(GLuint program, const GLchar* name)
{
if (context->getShader(program))
{
- return error(GL_INVALID_OPERATION, -1);
+ return gl::error(GL_INVALID_OPERATION, -1);
}
else
{
- return error(GL_INVALID_VALUE, -1);
+ return gl::error(GL_INVALID_VALUE, -1);
}
}
gl::ProgramBinary *programBinary = programObject->getProgramBinary();
if (!programObject->isLinked() || !programBinary)
{
- return error(GL_INVALID_OPERATION, -1);
+ return gl::error(GL_INVALID_OPERATION, -1);
}
return programBinary->getUniformLocation(name);
@@ -4144,7 +4195,7 @@ int __stdcall glGetUniformLocation(GLuint program, const GLchar* name)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, -1);
+ return gl::error(GL_OUT_OF_MEMORY, -1);
}
return -1;
@@ -4162,7 +4213,7 @@ void __stdcall glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat* params)
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
const gl::VertexAttribute &attribState = context->getVertexAttribState(index);
@@ -4196,13 +4247,13 @@ void __stdcall glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat* params)
case GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE:
*params = (GLfloat)attribState.mDivisor;
break;
- default: return error(GL_INVALID_ENUM);
+ default: return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4218,7 +4269,7 @@ void __stdcall glGetVertexAttribiv(GLuint index, GLenum pname, GLint* params)
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
const gl::VertexAttribute &attribState = context->getVertexAttribState(index);
@@ -4253,13 +4304,13 @@ void __stdcall glGetVertexAttribiv(GLuint index, GLenum pname, GLint* params)
case GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE:
*params = (GLint)attribState.mDivisor;
break;
- default: return error(GL_INVALID_ENUM);
+ default: return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4275,12 +4326,12 @@ void __stdcall glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid** po
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (pname != GL_VERTEX_ATTRIB_ARRAY_POINTER)
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
*pointer = const_cast<GLvoid*>(context->getVertexAttribPointer(index));
@@ -4288,7 +4339,7 @@ void __stdcall glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid** po
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4305,7 +4356,7 @@ void __stdcall glHint(GLenum target, GLenum mode)
case GL_DONT_CARE:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -4318,12 +4369,12 @@ void __stdcall glHint(GLenum target, GLenum mode)
if (context) context->setFragmentShaderDerivativeHint(mode);
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4347,7 +4398,7 @@ GLboolean __stdcall glIsBuffer(GLuint buffer)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, GL_FALSE);
+ return gl::error(GL_OUT_OF_MEMORY, GL_FALSE);
}
return GL_FALSE;
@@ -4375,13 +4426,13 @@ GLboolean __stdcall glIsEnabled(GLenum cap)
case GL_BLEND: return context->isBlendEnabled();
case GL_DITHER: return context->isDitherEnabled();
default:
- return error(GL_INVALID_ENUM, false);
+ return gl::error(GL_INVALID_ENUM, false);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, false);
+ return gl::error(GL_OUT_OF_MEMORY, false);
}
return false;
@@ -4409,7 +4460,7 @@ GLboolean __stdcall glIsFenceNV(GLuint fence)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, GL_FALSE);
+ return gl::error(GL_OUT_OF_MEMORY, GL_FALSE);
}
return GL_FALSE;
@@ -4435,7 +4486,7 @@ GLboolean __stdcall glIsFramebuffer(GLuint framebuffer)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, GL_FALSE);
+ return gl::error(GL_OUT_OF_MEMORY, GL_FALSE);
}
return GL_FALSE;
@@ -4461,7 +4512,7 @@ GLboolean __stdcall glIsProgram(GLuint program)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, GL_FALSE);
+ return gl::error(GL_OUT_OF_MEMORY, GL_FALSE);
}
return GL_FALSE;
@@ -4492,7 +4543,7 @@ GLboolean __stdcall glIsQueryEXT(GLuint id)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, GL_FALSE);
+ return gl::error(GL_OUT_OF_MEMORY, GL_FALSE);
}
return GL_FALSE;
@@ -4518,7 +4569,7 @@ GLboolean __stdcall glIsRenderbuffer(GLuint renderbuffer)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, GL_FALSE);
+ return gl::error(GL_OUT_OF_MEMORY, GL_FALSE);
}
return GL_FALSE;
@@ -4544,7 +4595,7 @@ GLboolean __stdcall glIsShader(GLuint shader)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, GL_FALSE);
+ return gl::error(GL_OUT_OF_MEMORY, GL_FALSE);
}
return GL_FALSE;
@@ -4570,7 +4621,7 @@ GLboolean __stdcall glIsTexture(GLuint texture)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, GL_FALSE);
+ return gl::error(GL_OUT_OF_MEMORY, GL_FALSE);
}
return GL_FALSE;
@@ -4584,7 +4635,7 @@ void __stdcall glLineWidth(GLfloat width)
{
if (width <= 0.0f)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -4596,7 +4647,7 @@ void __stdcall glLineWidth(GLfloat width)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4616,11 +4667,11 @@ void __stdcall glLinkProgram(GLuint program)
{
if (context->getShader(program))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
@@ -4629,7 +4680,7 @@ void __stdcall glLinkProgram(GLuint program)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4648,7 +4699,7 @@ void __stdcall glPixelStorei(GLenum pname, GLint param)
case GL_UNPACK_ALIGNMENT:
if (param != 1 && param != 2 && param != 4 && param != 8)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
context->setUnpackAlignment(param);
@@ -4657,7 +4708,7 @@ void __stdcall glPixelStorei(GLenum pname, GLint param)
case GL_PACK_ALIGNMENT:
if (param != 1 && param != 2 && param != 4 && param != 8)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
context->setPackAlignment(param);
@@ -4668,13 +4719,13 @@ void __stdcall glPixelStorei(GLenum pname, GLint param)
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4693,7 +4744,7 @@ void __stdcall glPolygonOffset(GLfloat factor, GLfloat units)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4709,7 +4760,7 @@ void __stdcall glReadnPixelsEXT(GLint x, GLint y, GLsizei width, GLsizei height,
{
if (width < 0 || height < 0 || bufSize < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -4726,7 +4777,7 @@ void __stdcall glReadnPixelsEXT(GLint x, GLint y, GLsizei width, GLsizei height,
if (!(currentFormat == format && currentType == type) && !validReadFormatType(format, type))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
context->readPixels(x, y, width, height, format, type, &bufSize, data);
@@ -4734,7 +4785,7 @@ void __stdcall glReadnPixelsEXT(GLint x, GLint y, GLsizei width, GLsizei height,
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4749,7 +4800,7 @@ void __stdcall glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height,
{
if (width < 0 || height < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -4766,7 +4817,7 @@ void __stdcall glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height,
if (!(currentFormat == format && currentType == type) && !validReadFormatType(format, type))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
context->readPixels(x, y, width, height, format, type, NULL, pixels);
@@ -4774,7 +4825,7 @@ void __stdcall glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height,
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4788,7 +4839,7 @@ void __stdcall glReleaseShaderCompiler(void)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4804,17 +4855,17 @@ void __stdcall glRenderbufferStorageMultisampleANGLE(GLenum target, GLsizei samp
case GL_RENDERBUFFER:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (!gl::IsColorRenderable(internalformat) && !gl::IsDepthRenderable(internalformat) && !gl::IsStencilRenderable(internalformat))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (width < 0 || height < 0 || samples < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -4825,41 +4876,35 @@ void __stdcall glRenderbufferStorageMultisampleANGLE(GLenum target, GLsizei samp
height > context->getMaximumRenderbufferDimension() ||
samples > context->getMaxSupportedSamples())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
GLuint handle = context->getRenderbufferHandle();
if (handle == 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
switch (internalformat)
{
case GL_DEPTH_COMPONENT16:
- context->setRenderbufferStorage(new gl::Depthbuffer(width, height, samples));
- break;
case GL_RGBA4:
case GL_RGB5_A1:
case GL_RGB565:
case GL_RGB8_OES:
case GL_RGBA8_OES:
- context->setRenderbufferStorage(new gl::Colorbuffer(width, height, internalformat, samples));
- break;
case GL_STENCIL_INDEX8:
- context->setRenderbufferStorage(new gl::Stencilbuffer(width, height, samples));
- break;
case GL_DEPTH24_STENCIL8_OES:
- context->setRenderbufferStorage(new gl::DepthStencilbuffer(width, height, samples));
+ context->setRenderbufferStorage(width, height, internalformat, samples);
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4883,7 +4928,7 @@ void __stdcall glSampleCoverage(GLclampf value, GLboolean invert)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4895,7 +4940,7 @@ void __stdcall glSetFenceNV(GLuint fence, GLenum condition)
{
if (condition != GL_ALL_COMPLETED_NV)
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -4906,7 +4951,7 @@ void __stdcall glSetFenceNV(GLuint fence, GLenum condition)
if (fenceObject == NULL)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
fenceObject->setFence(condition);
@@ -4914,7 +4959,7 @@ void __stdcall glSetFenceNV(GLuint fence, GLenum condition)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4926,7 +4971,7 @@ void __stdcall glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
{
if (width < 0 || height < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context* context = gl::getNonLostContext();
@@ -4938,7 +4983,7 @@ void __stdcall glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4951,11 +4996,11 @@ void __stdcall glShaderBinary(GLsizei n, const GLuint* shaders, GLenum binaryfor
try
{
// No binary shader formats are supported.
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -4968,7 +5013,7 @@ void __stdcall glShaderSource(GLuint shader, GLsizei count, const GLchar** strin
{
if (count < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -4981,11 +5026,11 @@ void __stdcall glShaderSource(GLuint shader, GLsizei count, const GLchar** strin
{
if (context->getProgram(shader))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
@@ -4994,7 +5039,7 @@ void __stdcall glShaderSource(GLuint shader, GLsizei count, const GLchar** strin
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -5016,7 +5061,7 @@ void __stdcall glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint
case GL_FRONT_AND_BACK:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (func)
@@ -5031,7 +5076,7 @@ void __stdcall glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint
case GL_NOTEQUAL:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -5051,7 +5096,7 @@ void __stdcall glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -5073,7 +5118,7 @@ void __stdcall glStencilMaskSeparate(GLenum face, GLuint mask)
case GL_FRONT_AND_BACK:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -5093,7 +5138,7 @@ void __stdcall glStencilMaskSeparate(GLenum face, GLuint mask)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -5116,7 +5161,7 @@ void __stdcall glStencilOpSeparate(GLenum face, GLenum fail, GLenum zfail, GLenu
case GL_FRONT_AND_BACK:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (fail)
@@ -5131,7 +5176,7 @@ void __stdcall glStencilOpSeparate(GLenum face, GLenum fail, GLenum zfail, GLenu
case GL_DECR_WRAP:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (zfail)
@@ -5146,7 +5191,7 @@ void __stdcall glStencilOpSeparate(GLenum face, GLenum fail, GLenum zfail, GLenu
case GL_DECR_WRAP:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (zpass)
@@ -5161,7 +5206,7 @@ void __stdcall glStencilOpSeparate(GLenum face, GLenum fail, GLenum zfail, GLenu
case GL_DECR_WRAP:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -5181,7 +5226,7 @@ void __stdcall glStencilOpSeparate(GLenum face, GLenum fail, GLenum zfail, GLenu
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -5199,7 +5244,7 @@ GLboolean __stdcall glTestFenceNV(GLuint fence)
if (fenceObject == NULL)
{
- return error(GL_INVALID_OPERATION, GL_TRUE);
+ return gl::error(GL_INVALID_OPERATION, GL_TRUE);
}
return fenceObject->testFence();
@@ -5207,7 +5252,7 @@ GLboolean __stdcall glTestFenceNV(GLuint fence)
}
catch(std::bad_alloc&)
{
- error(GL_OUT_OF_MEMORY);
+ gl::error(GL_OUT_OF_MEMORY);
}
return GL_TRUE;
@@ -5224,12 +5269,12 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
{
if (!validImageSize(level, width, height))
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (internalformat != GLint(format))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
// validate <type> by itself (used as secondary key below)
@@ -5246,7 +5291,7 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
case GL_FLOAT:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
// validate <format> + <type> combinations
@@ -5264,7 +5309,7 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
case GL_HALF_FLOAT_OES:
break;
default:
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
case GL_RGB:
@@ -5276,7 +5321,7 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
case GL_HALF_FLOAT_OES:
break;
default:
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
case GL_RGBA:
@@ -5289,7 +5334,7 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
case GL_HALF_FLOAT_OES:
break;
default:
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
case GL_BGRA_EXT:
@@ -5298,7 +5343,7 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
case GL_UNSIGNED_BYTE:
break;
default:
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
case GL_COMPRESSED_RGB_S3TC_DXT1_EXT: // error cases for compressed textures are handled below
@@ -5313,7 +5358,7 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
case GL_UNSIGNED_INT:
break;
default:
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
case GL_DEPTH_STENCIL_OES:
@@ -5322,16 +5367,16 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
case GL_UNSIGNED_INT_24_8_OES:
break;
default:
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (border != 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -5340,7 +5385,7 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
{
if (level > context->getMaximumTextureLevel())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
switch (target)
@@ -5349,7 +5394,7 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
if (width > (context->getMaximumTextureDimension() >> level) ||
height > (context->getMaximumTextureDimension() >> level))
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
break;
case GL_TEXTURE_CUBE_MAP_POSITIVE_X:
@@ -5360,17 +5405,17 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
case GL_TEXTURE_CUBE_MAP_NEGATIVE_Z:
if (width != height)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (width > (context->getMaximumCubeTextureDimension() >> level) ||
height > (context->getMaximumCubeTextureDimension() >> level))
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (format) {
@@ -5378,48 +5423,48 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
case GL_COMPRESSED_RGBA_S3TC_DXT1_EXT:
if (context->supportsDXT1Textures())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE:
if (context->supportsDXT3Textures())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE:
if (context->supportsDXT5Textures())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_DEPTH_COMPONENT:
case GL_DEPTH_STENCIL_OES:
if (!context->supportsDepthTextures())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (target != GL_TEXTURE_2D)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
// OES_depth_texture supports loading depth data and multiple levels,
// but ANGLE_depth_texture does not
if (pixels != NULL || level != 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
default:
@@ -5430,14 +5475,14 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
{
if (!context->supportsFloat32Textures())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
else if (type == GL_HALF_FLOAT_OES)
{
if (!context->supportsFloat16Textures())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
@@ -5447,12 +5492,12 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
if (!texture)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (texture->isImmutable())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
texture->setImage(level, width, height, format, type, context->getUnpackAlignment(), pixels);
@@ -5463,12 +5508,12 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
if (!texture)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (texture->isImmutable())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
switch (target)
@@ -5498,7 +5543,7 @@ void __stdcall glTexImage2D(GLenum target, GLint level, GLint internalformat, GL
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -5523,7 +5568,7 @@ void __stdcall glTexParameterf(GLenum target, GLenum pname, GLfloat param)
texture = context->getTextureCubeMap();
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (pname)
@@ -5531,51 +5576,51 @@ void __stdcall glTexParameterf(GLenum target, GLenum pname, GLfloat param)
case GL_TEXTURE_WRAP_S:
if (!texture->setWrapS((GLenum)param))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_TEXTURE_WRAP_T:
if (!texture->setWrapT((GLenum)param))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_TEXTURE_MIN_FILTER:
if (!texture->setMinFilter((GLenum)param))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_TEXTURE_MAG_FILTER:
if (!texture->setMagFilter((GLenum)param))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_TEXTURE_USAGE_ANGLE:
if (!texture->setUsage((GLenum)param))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_TEXTURE_MAX_ANISOTROPY_EXT:
if (!context->supportsTextureFilterAnisotropy())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (!texture->setMaxAnisotropy((float)param, context->getTextureMaxAnisotropy()))
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -5605,7 +5650,7 @@ void __stdcall glTexParameteri(GLenum target, GLenum pname, GLint param)
texture = context->getTextureCubeMap();
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
switch (pname)
@@ -5613,51 +5658,51 @@ void __stdcall glTexParameteri(GLenum target, GLenum pname, GLint param)
case GL_TEXTURE_WRAP_S:
if (!texture->setWrapS((GLenum)param))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_TEXTURE_WRAP_T:
if (!texture->setWrapT((GLenum)param))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_TEXTURE_MIN_FILTER:
if (!texture->setMinFilter((GLenum)param))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_TEXTURE_MAG_FILTER:
if (!texture->setMagFilter((GLenum)param))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_TEXTURE_USAGE_ANGLE:
if (!texture->setUsage((GLenum)param))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_TEXTURE_MAX_ANISOTROPY_EXT:
if (!context->supportsTextureFilterAnisotropy())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (!texture->setMaxAnisotropy((float)param, context->getTextureMaxAnisotropy()))
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -5675,22 +5720,22 @@ void __stdcall glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalf
{
if (target != GL_TEXTURE_2D && target != GL_TEXTURE_CUBE_MAP)
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (width < 1 || height < 1 || levels < 1)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (target == GL_TEXTURE_CUBE_MAP && width != height)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (levels != 1 && levels != gl::log2(std::max(width, height)) + 1)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
GLenum format = gl::ExtractFormat(internalformat);
@@ -5698,7 +5743,7 @@ void __stdcall glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalf
if (format == GL_NONE || type == GL_NONE)
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Context *context = gl::getNonLostContext();
@@ -5711,25 +5756,25 @@ void __stdcall glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalf
if (width > context->getMaximumTextureDimension() ||
height > context->getMaximumTextureDimension())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
break;
case GL_TEXTURE_CUBE_MAP:
if (width > context->getMaximumCubeTextureDimension() ||
height > context->getMaximumCubeTextureDimension())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (levels != 1 && !context->supportsNonPower2Texture())
{
if (!gl::isPow2(width) || !gl::isPow2(height))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
@@ -5739,19 +5784,19 @@ void __stdcall glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalf
case GL_COMPRESSED_RGBA_S3TC_DXT1_EXT:
if (!context->supportsDXT1Textures())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE:
if (!context->supportsDXT3Textures())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE:
if (!context->supportsDXT5Textures())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_RGBA32F_EXT:
@@ -5761,7 +5806,7 @@ void __stdcall glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalf
case GL_LUMINANCE_ALPHA32F_EXT:
if (!context->supportsFloat32Textures())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_RGBA16F_EXT:
@@ -5771,7 +5816,7 @@ void __stdcall glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalf
case GL_LUMINANCE_ALPHA16F_EXT:
if (!context->supportsFloat16Textures())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
break;
case GL_DEPTH_COMPONENT16:
@@ -5779,16 +5824,16 @@ void __stdcall glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalf
case GL_DEPTH24_STENCIL8_OES:
if (!context->supportsDepthTextures())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (target != GL_TEXTURE_2D)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
// ANGLE_depth_texture only supports 1-level textures
if (levels != 1)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
break;
default:
@@ -5801,12 +5846,12 @@ void __stdcall glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalf
if (!texture || texture->id() == 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (texture->isImmutable())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
texture->storage(levels, internalformat, width, height);
@@ -5817,12 +5862,12 @@ void __stdcall glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalf
if (!texture || texture->id() == 0)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (texture->isImmutable())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
texture->storage(levels, internalformat, width);
@@ -5832,7 +5877,7 @@ void __stdcall glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalf
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -5848,17 +5893,17 @@ void __stdcall glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint
{
if (!gl::IsInternalTextureTarget(target))
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (level < 0 || xoffset < 0 || yoffset < 0 || width < 0 || height < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (std::numeric_limits<GLsizei>::max() - xoffset < width || std::numeric_limits<GLsizei>::max() - yoffset < height)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (!checkTextureFormatType(format, type))
@@ -5872,35 +5917,35 @@ void __stdcall glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint
{
if (level > context->getMaximumTextureLevel())
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (format == GL_FLOAT)
{
if (!context->supportsFloat32Textures())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
else if (format == GL_HALF_FLOAT_OES)
{
if (!context->supportsFloat16Textures())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
}
else if (gl::IsDepthTexture(format))
{
if (!context->supportsDepthTextures())
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (target != GL_TEXTURE_2D)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
// OES_depth_texture supports loading depth data, but ANGLE_depth_texture does not
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (width == 0 || height == 0 || pixels == NULL)
@@ -5932,7 +5977,7 @@ void __stdcall glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -5949,7 +5994,7 @@ void __stdcall glUniform1fv(GLint location, GLsizei count, const GLfloat* v)
{
if (count < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (location == -1)
@@ -5964,18 +6009,18 @@ void __stdcall glUniform1fv(GLint location, GLsizei count, const GLfloat* v)
gl::ProgramBinary *programBinary = context->getCurrentProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->setUniform1fv(location, count, v))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -5992,7 +6037,7 @@ void __stdcall glUniform1iv(GLint location, GLsizei count, const GLint* v)
{
if (count < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (location == -1)
@@ -6007,18 +6052,18 @@ void __stdcall glUniform1iv(GLint location, GLsizei count, const GLint* v)
gl::ProgramBinary *programBinary = context->getCurrentProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->setUniform1iv(location, count, v))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6037,7 +6082,7 @@ void __stdcall glUniform2fv(GLint location, GLsizei count, const GLfloat* v)
{
if (count < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (location == -1)
@@ -6052,18 +6097,18 @@ void __stdcall glUniform2fv(GLint location, GLsizei count, const GLfloat* v)
gl::ProgramBinary *programBinary = context->getCurrentProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->setUniform2fv(location, count, v))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6082,7 +6127,7 @@ void __stdcall glUniform2iv(GLint location, GLsizei count, const GLint* v)
{
if (count < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (location == -1)
@@ -6097,18 +6142,18 @@ void __stdcall glUniform2iv(GLint location, GLsizei count, const GLint* v)
gl::ProgramBinary *programBinary = context->getCurrentProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->setUniform2iv(location, count, v))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6127,7 +6172,7 @@ void __stdcall glUniform3fv(GLint location, GLsizei count, const GLfloat* v)
{
if (count < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (location == -1)
@@ -6142,18 +6187,18 @@ void __stdcall glUniform3fv(GLint location, GLsizei count, const GLfloat* v)
gl::ProgramBinary *programBinary = context->getCurrentProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->setUniform3fv(location, count, v))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6172,7 +6217,7 @@ void __stdcall glUniform3iv(GLint location, GLsizei count, const GLint* v)
{
if (count < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (location == -1)
@@ -6187,18 +6232,18 @@ void __stdcall glUniform3iv(GLint location, GLsizei count, const GLint* v)
gl::ProgramBinary *programBinary = context->getCurrentProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->setUniform3iv(location, count, v))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6217,7 +6262,7 @@ void __stdcall glUniform4fv(GLint location, GLsizei count, const GLfloat* v)
{
if (count < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (location == -1)
@@ -6232,18 +6277,18 @@ void __stdcall glUniform4fv(GLint location, GLsizei count, const GLfloat* v)
gl::ProgramBinary *programBinary = context->getCurrentProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->setUniform4fv(location, count, v))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6262,7 +6307,7 @@ void __stdcall glUniform4iv(GLint location, GLsizei count, const GLint* v)
{
if (count < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (location == -1)
@@ -6277,18 +6322,18 @@ void __stdcall glUniform4iv(GLint location, GLsizei count, const GLint* v)
gl::ProgramBinary *programBinary = context->getCurrentProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->setUniform4iv(location, count, v))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6301,7 +6346,7 @@ void __stdcall glUniformMatrix2fv(GLint location, GLsizei count, GLboolean trans
{
if (count < 0 || transpose != GL_FALSE)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (location == -1)
@@ -6316,18 +6361,18 @@ void __stdcall glUniformMatrix2fv(GLint location, GLsizei count, GLboolean trans
gl::ProgramBinary *programBinary = context->getCurrentProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->setUniformMatrix2fv(location, count, value))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6340,7 +6385,7 @@ void __stdcall glUniformMatrix3fv(GLint location, GLsizei count, GLboolean trans
{
if (count < 0 || transpose != GL_FALSE)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (location == -1)
@@ -6355,18 +6400,18 @@ void __stdcall glUniformMatrix3fv(GLint location, GLsizei count, GLboolean trans
gl::ProgramBinary *programBinary = context->getCurrentProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->setUniformMatrix3fv(location, count, value))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6379,7 +6424,7 @@ void __stdcall glUniformMatrix4fv(GLint location, GLsizei count, GLboolean trans
{
if (count < 0 || transpose != GL_FALSE)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (location == -1)
@@ -6394,18 +6439,18 @@ void __stdcall glUniformMatrix4fv(GLint location, GLsizei count, GLboolean trans
gl::ProgramBinary *programBinary = context->getCurrentProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->setUniformMatrix4fv(location, count, value))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
}
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6425,17 +6470,17 @@ void __stdcall glUseProgram(GLuint program)
{
if (context->getShader(program))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
if (program != 0 && !programObject->isLinked())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
context->useProgram(program);
@@ -6443,7 +6488,7 @@ void __stdcall glUseProgram(GLuint program)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6463,11 +6508,11 @@ void __stdcall glValidateProgram(GLuint program)
{
if (context->getShader(program))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
else
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
}
@@ -6476,7 +6521,7 @@ void __stdcall glValidateProgram(GLuint program)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6488,7 +6533,7 @@ void __stdcall glVertexAttrib1f(GLuint index, GLfloat x)
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -6501,7 +6546,7 @@ void __stdcall glVertexAttrib1f(GLuint index, GLfloat x)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6513,7 +6558,7 @@ void __stdcall glVertexAttrib1fv(GLuint index, const GLfloat* values)
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -6526,7 +6571,7 @@ void __stdcall glVertexAttrib1fv(GLuint index, const GLfloat* values)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6538,7 +6583,7 @@ void __stdcall glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y)
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -6551,7 +6596,7 @@ void __stdcall glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6563,7 +6608,7 @@ void __stdcall glVertexAttrib2fv(GLuint index, const GLfloat* values)
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -6576,7 +6621,7 @@ void __stdcall glVertexAttrib2fv(GLuint index, const GLfloat* values)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6588,7 +6633,7 @@ void __stdcall glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z)
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -6601,7 +6646,7 @@ void __stdcall glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6613,7 +6658,7 @@ void __stdcall glVertexAttrib3fv(GLuint index, const GLfloat* values)
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -6626,7 +6671,7 @@ void __stdcall glVertexAttrib3fv(GLuint index, const GLfloat* values)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6638,7 +6683,7 @@ void __stdcall glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, G
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -6651,7 +6696,7 @@ void __stdcall glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, G
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6663,7 +6708,7 @@ void __stdcall glVertexAttrib4fv(GLuint index, const GLfloat* values)
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -6675,7 +6720,7 @@ void __stdcall glVertexAttrib4fv(GLuint index, const GLfloat* values)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6687,7 +6732,7 @@ void __stdcall glVertexAttribDivisorANGLE(GLuint index, GLuint divisor)
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -6699,7 +6744,7 @@ void __stdcall glVertexAttribDivisorANGLE(GLuint index, GLuint divisor)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6713,12 +6758,12 @@ void __stdcall glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLbo
{
if (index >= gl::MAX_VERTEX_ATTRIBS)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (size < 1 || size > 4)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
switch (type)
@@ -6731,12 +6776,12 @@ void __stdcall glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLbo
case GL_FLOAT:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if (stride < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -6748,7 +6793,7 @@ void __stdcall glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLbo
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6760,7 +6805,7 @@ void __stdcall glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
{
if (width < 0 || height < 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
gl::Context *context = gl::getNonLostContext();
@@ -6772,7 +6817,7 @@ void __stdcall glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6791,18 +6836,18 @@ void __stdcall glBlitFramebufferANGLE(GLint srcX0, GLint srcY0, GLint srcX1, GLi
case GL_NEAREST:
break;
default:
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
if ((mask & ~(GL_COLOR_BUFFER_BIT | GL_STENCIL_BUFFER_BIT | GL_DEPTH_BUFFER_BIT)) != 0)
{
- return error(GL_INVALID_VALUE);
+ return gl::error(GL_INVALID_VALUE);
}
if (srcX1 - srcX0 != dstX1 - dstX0 || srcY1 - srcY0 != dstY1 - dstY0)
{
ERR("Scaling and flipping in BlitFramebufferANGLE not supported by this implementation");
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
gl::Context *context = gl::getNonLostContext();
@@ -6812,7 +6857,7 @@ void __stdcall glBlitFramebufferANGLE(GLint srcX0, GLint srcY0, GLint srcX1, GLi
if (context->getReadFramebufferHandle() == context->getDrawFramebufferHandle())
{
ERR("Blits with the same source and destination framebuffer are not supported by this implementation.");
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
context->blitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask);
@@ -6820,7 +6865,7 @@ void __stdcall glBlitFramebufferANGLE(GLint srcX0, GLint srcY0, GLint srcX1, GLi
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6838,7 +6883,7 @@ void __stdcall glTexImage3DOES(GLenum target, GLint level, GLenum internalformat
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6858,19 +6903,19 @@ void __stdcall glGetProgramBinaryOES(GLuint program, GLsizei bufSize, GLsizei *l
if (!programObject || !programObject->isLinked())
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
gl::ProgramBinary *programBinary = programObject->getProgramBinary();
if (!programBinary)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
if (!programBinary->save(binary, bufSize, length))
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
*binaryFormat = GL_PROGRAM_BINARY_ANGLE;
@@ -6878,7 +6923,7 @@ void __stdcall glGetProgramBinaryOES(GLuint program, GLsizei bufSize, GLsizei *l
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6896,14 +6941,14 @@ void __stdcall glProgramBinaryOES(GLuint program, GLenum binaryFormat,
{
if (binaryFormat != GL_PROGRAM_BINARY_ANGLE)
{
- return error(GL_INVALID_ENUM);
+ return gl::error(GL_INVALID_ENUM);
}
gl::Program *programObject = context->getProgram(program);
if (!programObject)
{
- return error(GL_INVALID_OPERATION);
+ return gl::error(GL_INVALID_OPERATION);
}
context->setProgramBinary(program, binary, length);
@@ -6911,7 +6956,63 @@ void __stdcall glProgramBinaryOES(GLuint program, GLenum binaryFormat,
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+}
+
+void __stdcall glDrawBuffersEXT(GLsizei n, const GLenum *bufs)
+{
+ EVENT("(GLenum n = %d, bufs = 0x%0.8p)", n, bufs);
+
+ try
+ {
+ gl::Context *context = gl::getNonLostContext();
+
+ if (context)
+ {
+ if (n < 0 || (unsigned int)n > context->getMaximumRenderTargets())
+ {
+ return gl::error(GL_INVALID_VALUE);
+ }
+
+ if (context->getDrawFramebufferHandle() == 0)
+ {
+ if (n > 1)
+ {
+ return gl::error(GL_INVALID_OPERATION);
+ }
+
+ if (n == 1)
+ {
+ if (bufs[0] != GL_NONE && bufs[0] != GL_BACK)
+ {
+ return gl::error(GL_INVALID_OPERATION);
+ }
+ }
+ }
+ else
+ {
+ for (int colorAttachment = 0; colorAttachment < n; colorAttachment++)
+ {
+ const GLenum attachment = GL_COLOR_ATTACHMENT0_EXT + colorAttachment;
+ if (bufs[colorAttachment] != GL_NONE && bufs[colorAttachment] != attachment)
+ {
+ return gl::error(GL_INVALID_OPERATION);
+ }
+ }
+ }
+
+ gl::Framebuffer *framebuffer = context->getDrawFramebuffer();
+
+ for (int colorAttachment = 0; colorAttachment < n; colorAttachment++)
+ {
+ framebuffer->setDrawBufferState(colorAttachment, bufs[colorAttachment]);
+ }
+ }
+ }
+ catch (std::bad_alloc&)
+ {
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
@@ -6948,13 +7049,14 @@ __eglMustCastToProperFunctionPointerType __stdcall glGetProcAddress(const char *
{"glEndQueryEXT", (__eglMustCastToProperFunctionPointerType)glEndQueryEXT},
{"glGetQueryivEXT", (__eglMustCastToProperFunctionPointerType)glGetQueryivEXT},
{"glGetQueryObjectuivEXT", (__eglMustCastToProperFunctionPointerType)glGetQueryObjectuivEXT},
+ {"glDrawBuffersEXT", (__eglMustCastToProperFunctionPointerType)glDrawBuffersEXT},
{"glVertexAttribDivisorANGLE", (__eglMustCastToProperFunctionPointerType)glVertexAttribDivisorANGLE},
{"glDrawArraysInstancedANGLE", (__eglMustCastToProperFunctionPointerType)glDrawArraysInstancedANGLE},
{"glDrawElementsInstancedANGLE", (__eglMustCastToProperFunctionPointerType)glDrawElementsInstancedANGLE},
{"glGetProgramBinaryOES", (__eglMustCastToProperFunctionPointerType)glGetProgramBinaryOES},
{"glProgramBinaryOES", (__eglMustCastToProperFunctionPointerType)glProgramBinaryOES}, };
- for (int ext = 0; ext < sizeof(glExtensions) / sizeof(Extension); ext++)
+ for (unsigned int ext = 0; ext < ArraySize(glExtensions); ext++)
{
if (strcmp(procname, glExtensions[ext].name) == 0)
{
@@ -6993,7 +7095,7 @@ bool __stdcall glBindTexImage(egl::Surface *surface)
}
catch(std::bad_alloc&)
{
- return error(GL_OUT_OF_MEMORY, false);
+ return gl::error(GL_OUT_OF_MEMORY, false);
}
return true;
diff --git a/src/3rdparty/angle/src/libGLESv2/libGLESv2.def b/src/3rdparty/angle/src/libGLESv2/libGLESv2.def
index 5f935c3733..71398b3142 100644
--- a/src/3rdparty/angle/src/libGLESv2/libGLESv2.def
+++ b/src/3rdparty/angle/src/libGLESv2/libGLESv2.def
@@ -172,6 +172,7 @@ EXPORTS
glDrawElementsInstancedANGLE @174
glProgramBinaryOES @175
glGetProgramBinaryOES @176
+ glDrawBuffersEXT @179
; EGL dependencies
glCreateContext @144 NONAME
@@ -180,3 +181,5 @@ EXPORTS
glGetCurrentContext @147 NONAME
glGetProcAddress @148 NONAME
glBindTexImage @158 NONAME
+ glCreateRenderer @177 NONAME
+ glDestroyRenderer @178 NONAME \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/libGLESv2d.def b/src/3rdparty/angle/src/libGLESv2/libGLESv2d.def
index c20864aa31..2b3b34009e 100644
--- a/src/3rdparty/angle/src/libGLESv2/libGLESv2d.def
+++ b/src/3rdparty/angle/src/libGLESv2/libGLESv2d.def
@@ -180,3 +180,5 @@ EXPORTS
glGetCurrentContext @147 NONAME
glGetProcAddress @148 NONAME
glBindTexImage @158 NONAME
+ glCreateRenderer @177 NONAME
+ glDestroyRenderer @178 NONAME
diff --git a/src/3rdparty/angle/src/libGLESv2/main.cpp b/src/3rdparty/angle/src/libGLESv2/main.cpp
index 6e678c2616..5d23e8e70f 100644
--- a/src/3rdparty/angle/src/libGLESv2/main.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/main.cpp
@@ -1,3 +1,4 @@
+#include "precompiled.h"
//
// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
@@ -7,12 +8,10 @@
// main.cpp: DLL entry point and management of thread-local data.
#include "libGLESv2/main.h"
-#include "libGLESv2/utilities.h"
-#include "common/debug.h"
-#include "libEGL/Surface.h"
+#include "libGLESv2/Context.h"
-#include "libGLESv2/Framebuffer.h"
+#ifndef QT_OPENGL_ES_2_ANGLE_STATIC
static DWORD currentTLS = TLS_OUT_OF_INDEXES;
@@ -72,26 +71,40 @@ extern "C" BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, LPVOID reserved
return TRUE;
}
+static gl::Current *current()
+{
+ return (gl::Current*)TlsGetValue(currentTLS);
+}
+
+#else // !QT_OPENGL_ES_2_ANGLE_STATIC
+
+static inline gl::Current *current()
+{
+ // No precautions for thread safety taken as ANGLE is used single-threaded in Qt.
+ static gl::Current curr = { 0, 0 };
+ return &curr;
+}
+
+#endif // QT_OPENGL_ES_2_ANGLE_STATIC
+
namespace gl
{
void makeCurrent(Context *context, egl::Display *display, egl::Surface *surface)
{
- Current *current = (Current*)TlsGetValue(currentTLS);
+ Current *curr = current();
- current->context = context;
- current->display = display;
+ curr->context = context;
+ curr->display = display;
if (context && display && surface)
{
- context->makeCurrent(display, surface);
+ context->makeCurrent(surface);
}
}
Context *getContext()
{
- Current *current = (Current*)TlsGetValue(currentTLS);
-
- return current->context;
+ return current()->context;
}
Context *getNonLostContext()
@@ -102,7 +115,7 @@ Context *getNonLostContext()
{
if (context->isContextLost())
{
- error(GL_OUT_OF_MEMORY);
+ gl::error(GL_OUT_OF_MEMORY);
return NULL;
}
else
@@ -115,30 +128,7 @@ Context *getNonLostContext()
egl::Display *getDisplay()
{
- Current *current = (Current*)TlsGetValue(currentTLS);
-
- return current->display;
-}
-
-IDirect3DDevice9 *getDevice()
-{
- egl::Display *display = getDisplay();
-
- return display->getDevice();
-}
-
-bool checkDeviceLost(HRESULT errorCode)
-{
- egl::Display *display = NULL;
-
- if (isDeviceLostError(errorCode))
- {
- display = gl::getDisplay();
- display->notifyDeviceLost();
- return true;
- }
- return false;
-}
+ return current()->display;
}
// Records an error code
@@ -174,3 +164,6 @@ void error(GLenum errorCode)
}
}
}
+
+}
+
diff --git a/src/3rdparty/angle/src/libGLESv2/main.h b/src/3rdparty/angle/src/libGLESv2/main.h
index 504848aa65..9168a2212e 100644
--- a/src/3rdparty/angle/src/libGLESv2/main.h
+++ b/src/3rdparty/angle/src/libGLESv2/main.h
@@ -9,17 +9,19 @@
#ifndef LIBGLESV2_MAIN_H_
#define LIBGLESV2_MAIN_H_
-#define GL_APICALL
-#include <GLES2/gl2.h>
-#include <GLES2/gl2ext.h>
-
#include "common/debug.h"
-#include "libEGL/Display.h"
+#include "common/system.h"
-#include "libGLESv2/Context.h"
+namespace egl
+{
+class Display;
+class Surface;
+}
namespace gl
{
+class Context;
+
struct Current
{
Context *context;
@@ -32,11 +34,6 @@ Context *getContext();
Context *getNonLostContext();
egl::Display *getDisplay();
-IDirect3DDevice9 *getDevice();
-
-bool checkDeviceLost(HRESULT errorCode);
-}
-
void error(GLenum errorCode);
template<class T>
@@ -47,4 +44,25 @@ const T &error(GLenum errorCode, const T &returnValue)
return returnValue;
}
+}
+
+namespace rx
+{
+class Renderer;
+}
+
+extern "C"
+{
+// Exported functions for use by EGL
+gl::Context *glCreateContext(const gl::Context *shareContext, rx::Renderer *renderer, bool notifyResets, bool robustAccess);
+void glDestroyContext(gl::Context *context);
+void glMakeCurrent(gl::Context *context, egl::Display *display, egl::Surface *surface);
+gl::Context *glGetCurrentContext();
+rx::Renderer *glCreateRenderer(egl::Display *display, HDC hDc, bool softwareDevice);
+void glDestroyRenderer(rx::Renderer *renderer);
+
+__eglMustCastToProperFunctionPointerType __stdcall glGetProcAddress(const char *procname);
+bool __stdcall glBindTexImage(egl::Surface *surface);
+}
+
#endif // LIBGLESV2_MAIN_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/mathutil.h b/src/3rdparty/angle/src/libGLESv2/mathutil.h
index 790ecd89fa..672c443c11 100644
--- a/src/3rdparty/angle/src/libGLESv2/mathutil.h
+++ b/src/3rdparty/angle/src/libGLESv2/mathutil.h
@@ -9,9 +9,8 @@
#ifndef LIBGLESV2_MATHUTIL_H_
#define LIBGLESV2_MATHUTIL_H_
-#include <intrin.h>
-#include <math.h>
-#include <windows.h>
+#include "common/system.h"
+#include "common/debug.h"
namespace gl
{
@@ -54,7 +53,8 @@ inline unsigned int ceilPow2(unsigned int x)
template<typename T, typename MIN, typename MAX>
inline T clamp(T x, MIN min, MAX max)
{
- return x < min ? min : (x > max ? max : x);
+ // Since NaNs fail all comparison tests, a NaN value will default to min
+ return x > min ? (x > max ? max : x) : min;
}
inline float clamp01(float x)
@@ -142,4 +142,18 @@ float float16ToFloat32(unsigned short h);
}
+namespace rx
+{
+
+struct Range
+{
+ Range() {}
+ Range(int lo, int hi) : start(lo), end(hi) { ASSERT(lo <= hi); }
+
+ int start;
+ int end;
+};
+
+}
+
#endif // LIBGLESV2_MATHUTIL_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/precompiled.cpp b/src/3rdparty/angle/src/libGLESv2/precompiled.cpp
new file mode 100644
index 0000000000..2621cd6ce3
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/precompiled.cpp
@@ -0,0 +1,9 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// precompiled.cpp: Precompiled header source file for libGLESv2.
+
+#include "precompiled.h"
diff --git a/src/3rdparty/angle/src/libGLESv2/precompiled.h b/src/3rdparty/angle/src/libGLESv2/precompiled.h
new file mode 100644
index 0000000000..b8b043c964
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/precompiled.h
@@ -0,0 +1,45 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// precompiled.h: Precompiled header file for libGLESv2.
+
+#define GL_APICALL
+#include <GLES2/gl2.h>
+#include <GLES2/gl2ext.h>
+
+#define EGLAPI
+#include <EGL/egl.h>
+
+#include <assert.h>
+#include <cstddef>
+#include <float.h>
+#include <intrin.h>
+#include <math.h>
+#include <stdarg.h>
+#include <stdlib.h>
+#include <stdio.h>
+#include <string.h>
+
+#include <algorithm> // for std::min and std::max
+#include <limits>
+#include <map>
+#include <set>
+#include <sstream>
+#include <string>
+#include <unordered_map>
+#include <vector>
+
+#if defined(ANGLE_ENABLE_D3D11)
+# include <D3D11.h>
+# include <dxgi.h>
+#else
+# include <d3d9.h>
+#endif
+#include <D3Dcompiler.h>
+
+#ifdef _MSC_VER
+#include <hash_map>
+#endif
diff --git a/src/3rdparty/angle/src/libGLESv2/Blit.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Blit.cpp
index 28f3fbffbb..2a3ce39c63 100644
--- a/src/3rdparty/angle/src/libGLESv2/Blit.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Blit.cpp
@@ -1,3 +1,4 @@
+#include "precompiled.h"
//
// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
@@ -6,20 +7,23 @@
// Blit.cpp: Surface copy utility class.
-#include "libGLESv2/Blit.h"
-
-#include "common/debug.h"
+#include "libGLESv2/renderer/Blit.h"
#include "libGLESv2/main.h"
-#include "libGLESv2/utilities.h"
+#include "libGLESv2/renderer/renderer9_utils.h"
+#include "libGLESv2/renderer/TextureStorage9.h"
+#include "libGLESv2/renderer/RenderTarget9.h"
+#include "libGLESv2/renderer/Renderer9.h"
+#include "libGLESv2/Framebuffer.h"
+#include "libGLESv2/Renderbuffer.h"
namespace
{
-#include "libGLESv2/shaders/standardvs.h"
-#include "libGLESv2/shaders/flipyvs.h"
-#include "libGLESv2/shaders/passthroughps.h"
-#include "libGLESv2/shaders/luminanceps.h"
-#include "libGLESv2/shaders/componentmaskps.h"
+#include "libGLESv2/renderer/shaders/compiled/standardvs.h"
+#include "libGLESv2/renderer/shaders/compiled/flipyvs.h"
+#include "libGLESv2/renderer/shaders/compiled/passthroughps.h"
+#include "libGLESv2/renderer/shaders/compiled/luminanceps.h"
+#include "libGLESv2/renderer/shaders/compiled/componentmaskps.h"
const BYTE* const g_shaderCode[] =
{
@@ -40,10 +44,10 @@ const size_t g_shaderSize[] =
};
}
-namespace gl
+namespace rx
{
-Blit::Blit(Context *context)
- : mContext(context), mQuadVertexBuffer(NULL), mQuadVertexDeclaration(NULL), mSavedRenderTarget(NULL), mSavedDepthStencil(NULL), mSavedStateBlock(NULL)
+Blit::Blit(rx::Renderer9 *renderer)
+ : mRenderer(renderer), mQuadVertexBuffer(NULL), mQuadVertexDeclaration(NULL), mSavedStateBlock(NULL), mSavedRenderTarget(NULL), mSavedDepthStencil(NULL)
{
initGeometry();
memset(mCompiledShaders, 0, sizeof(mCompiledShaders));
@@ -74,14 +78,14 @@ void Blit::initGeometry()
1, 1
};
- IDirect3DDevice9 *device = getDevice();
+ IDirect3DDevice9 *device = mRenderer->getDevice();
HRESULT result = device->CreateVertexBuffer(sizeof(quad), D3DUSAGE_WRITEONLY, 0, D3DPOOL_DEFAULT, &mQuadVertexBuffer, NULL);
if (FAILED(result))
{
ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
void *lockPtr = NULL;
@@ -90,7 +94,7 @@ void Blit::initGeometry()
if (FAILED(result) || lockPtr == NULL)
{
ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
memcpy(lockPtr, quad, sizeof(quad));
@@ -107,17 +111,16 @@ void Blit::initGeometry()
if (FAILED(result))
{
ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
- return error(GL_OUT_OF_MEMORY);
+ return gl::error(GL_OUT_OF_MEMORY);
}
}
template <class D3DShaderType>
bool Blit::setShader(ShaderId source, const char *profile,
- D3DShaderType *(egl::Display::*createShader)(const DWORD *, size_t length),
+ D3DShaderType *(rx::Renderer9::*createShader)(const DWORD *, size_t length),
HRESULT (WINAPI IDirect3DDevice9::*setShader)(D3DShaderType*))
{
- egl::Display *display = getDisplay();
- IDirect3DDevice9 *device = display->getDevice();
+ IDirect3DDevice9 *device = mRenderer->getDevice();
D3DShaderType *shader;
@@ -130,7 +133,7 @@ bool Blit::setShader(ShaderId source, const char *profile,
const BYTE* shaderCode = g_shaderCode[source];
size_t shaderSize = g_shaderSize[source];
- shader = (display->*createShader)(reinterpret_cast<const DWORD*>(shaderCode), shaderSize);
+ shader = (mRenderer->*createShader)(reinterpret_cast<const DWORD*>(shaderCode), shaderSize);
if (!shader)
{
ERR("Failed to create shader for blit operation");
@@ -153,12 +156,12 @@ bool Blit::setShader(ShaderId source, const char *profile,
bool Blit::setVertexShader(ShaderId shader)
{
- return setShader<IDirect3DVertexShader9>(shader, "vs_2_0", &egl::Display::createVertexShader, &IDirect3DDevice9::SetVertexShader);
+ return setShader<IDirect3DVertexShader9>(shader, "vs_2_0", &rx::Renderer9::createVertexShader, &IDirect3DDevice9::SetVertexShader);
}
bool Blit::setPixelShader(ShaderId shader)
{
- return setShader<IDirect3DPixelShader9>(shader, "ps_2_0", &egl::Display::createPixelShader, &IDirect3DDevice9::SetPixelShader);
+ return setShader<IDirect3DPixelShader9>(shader, "ps_2_0", &rx::Renderer9::createPixelShader, &IDirect3DDevice9::SetPixelShader);
}
RECT Blit::getSurfaceRect(IDirect3DSurface9 *surface) const
@@ -183,7 +186,7 @@ bool Blit::boxFilter(IDirect3DSurface9 *source, IDirect3DSurface9 *dest)
return false;
}
- IDirect3DDevice9 *device = getDevice();
+ IDirect3DDevice9 *device = mRenderer->getDevice();
saveState();
@@ -208,9 +211,86 @@ bool Blit::boxFilter(IDirect3DSurface9 *source, IDirect3DSurface9 *dest)
return true;
}
+bool Blit::copy(gl::Framebuffer *framebuffer, const RECT &sourceRect, GLenum destFormat, GLint xoffset, GLint yoffset, TextureStorageInterface2D *storage, GLint level)
+{
+ RenderTarget9 *renderTarget = NULL;
+ IDirect3DSurface9 *source = NULL;
+ gl::Renderbuffer *colorbuffer = framebuffer->getColorbuffer(0);
+
+ if (colorbuffer)
+ {
+ renderTarget = RenderTarget9::makeRenderTarget9(colorbuffer->getRenderTarget());
+ }
+
+ if (renderTarget)
+ {
+ source = renderTarget->getSurface();
+ }
+
+ if (!source)
+ {
+ ERR("Failed to retrieve the render target.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ TextureStorage9_2D *storage9 = TextureStorage9_2D::makeTextureStorage9_2D(storage->getStorageInstance());
+ IDirect3DSurface9 *destSurface = storage9->getSurfaceLevel(level, true);
+ bool result = false;
+
+ if (destSurface)
+ {
+ result = copy(source, sourceRect, destFormat, xoffset, yoffset, destSurface);
+ destSurface->Release();
+ }
+
+ source->Release();
+ return result;
+}
+
+bool Blit::copy(gl::Framebuffer *framebuffer, const RECT &sourceRect, GLenum destFormat, GLint xoffset, GLint yoffset, TextureStorageInterfaceCube *storage, GLenum target, GLint level)
+{
+ RenderTarget9 *renderTarget = NULL;
+ IDirect3DSurface9 *source = NULL;
+ gl::Renderbuffer *colorbuffer = framebuffer->getColorbuffer(0);
+
+ if (colorbuffer)
+ {
+ renderTarget = RenderTarget9::makeRenderTarget9(colorbuffer->getRenderTarget());
+ }
+
+ if (renderTarget)
+ {
+ source = renderTarget->getSurface();
+ }
+
+ if (!source)
+ {
+ ERR("Failed to retrieve the render target.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ TextureStorage9_Cube *storage9 = TextureStorage9_Cube::makeTextureStorage9_Cube(storage->getStorageInstance());
+ IDirect3DSurface9 *destSurface = storage9->getCubeMapSurface(target, level, true);
+ bool result = false;
+
+ if (destSurface)
+ {
+ result = copy(source, sourceRect, destFormat, xoffset, yoffset, destSurface);
+ destSurface->Release();
+ }
+
+ source->Release();
+ return result;
+}
+
bool Blit::copy(IDirect3DSurface9 *source, const RECT &sourceRect, GLenum destFormat, GLint xoffset, GLint yoffset, IDirect3DSurface9 *dest)
{
- IDirect3DDevice9 *device = getDevice();
+ if (!dest)
+ {
+ return false;
+ }
+
+ IDirect3DDevice9 *device = mRenderer->getDevice();
D3DSURFACE_DESC sourceDesc;
D3DSURFACE_DESC destDesc;
@@ -218,7 +298,7 @@ bool Blit::copy(IDirect3DSurface9 *source, const RECT &sourceRect, GLenum destFo
dest->GetDesc(&destDesc);
if (sourceDesc.Format == destDesc.Format && destDesc.Usage & D3DUSAGE_RENDERTARGET &&
- dx2es::IsFormatChannelEquivalent(destDesc.Format, destFormat)) // Can use StretchRect
+ d3d9_gl::IsFormatChannelEquivalent(destDesc.Format, destFormat)) // Can use StretchRect
{
RECT destRect = {xoffset, yoffset, xoffset + (sourceRect.right - sourceRect.left), yoffset + (sourceRect.bottom - sourceRect.top)};
HRESULT result = device->StretchRect(source, &sourceRect, dest, &destRect, D3DTEXF_POINT);
@@ -226,14 +306,13 @@ bool Blit::copy(IDirect3DSurface9 *source, const RECT &sourceRect, GLenum destFo
if (FAILED(result))
{
ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
- return error(GL_OUT_OF_MEMORY, false);
+ return gl::error(GL_OUT_OF_MEMORY, false);
}
}
else
{
return formatConvert(source, sourceRect, destFormat, xoffset, yoffset, dest);
}
-
return true;
}
@@ -245,7 +324,7 @@ bool Blit::formatConvert(IDirect3DSurface9 *source, const RECT &sourceRect, GLen
return false;
}
- IDirect3DDevice9 *device = getDevice();
+ IDirect3DDevice9 *device = mRenderer->getDevice();
saveState();
@@ -325,7 +404,7 @@ bool Blit::setFormatConvertShaders(GLenum destFormat)
break;
}
- getDevice()->SetPixelShaderConstantF(0, psConst0, 1);
+ mRenderer->getDevice()->SetPixelShaderConstantF(0, psConst0, 1);
return true;
}
@@ -337,8 +416,7 @@ IDirect3DTexture9 *Blit::copySurfaceToTexture(IDirect3DSurface9 *surface, const
return NULL;
}
- egl::Display *display = getDisplay();
- IDirect3DDevice9 *device = getDevice();
+ IDirect3DDevice9 *device = mRenderer->getDevice();
D3DSURFACE_DESC sourceDesc;
surface->GetDesc(&sourceDesc);
@@ -350,7 +428,7 @@ IDirect3DTexture9 *Blit::copySurfaceToTexture(IDirect3DSurface9 *surface, const
if (FAILED(result))
{
ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
- return error(GL_OUT_OF_MEMORY, (IDirect3DTexture9*)NULL);
+ return gl::error(GL_OUT_OF_MEMORY, (IDirect3DTexture9*)NULL);
}
IDirect3DSurface9 *textureSurface;
@@ -360,10 +438,10 @@ IDirect3DTexture9 *Blit::copySurfaceToTexture(IDirect3DSurface9 *surface, const
{
ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
texture->Release();
- return error(GL_OUT_OF_MEMORY, (IDirect3DTexture9*)NULL);
+ return gl::error(GL_OUT_OF_MEMORY, (IDirect3DTexture9*)NULL);
}
- display->endScene();
+ mRenderer->endScene();
result = device->StretchRect(surface, &sourceRect, textureSurface, NULL, D3DTEXF_NONE);
textureSurface->Release();
@@ -372,7 +450,7 @@ IDirect3DTexture9 *Blit::copySurfaceToTexture(IDirect3DSurface9 *surface, const
{
ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
texture->Release();
- return error(GL_OUT_OF_MEMORY, (IDirect3DTexture9*)NULL);
+ return gl::error(GL_OUT_OF_MEMORY, (IDirect3DTexture9*)NULL);
}
return texture;
@@ -380,7 +458,7 @@ IDirect3DTexture9 *Blit::copySurfaceToTexture(IDirect3DSurface9 *surface, const
void Blit::setViewport(const RECT &sourceRect, GLint xoffset, GLint yoffset)
{
- IDirect3DDevice9 *device = getDevice();
+ IDirect3DDevice9 *device = mRenderer->getDevice();
D3DVIEWPORT9 vp;
vp.X = xoffset;
@@ -397,7 +475,7 @@ void Blit::setViewport(const RECT &sourceRect, GLint xoffset, GLint yoffset)
void Blit::setCommonBlitState()
{
- IDirect3DDevice9 *device = getDevice();
+ IDirect3DDevice9 *device = mRenderer->getDevice();
device->SetDepthStencilSurface(NULL);
@@ -419,7 +497,7 @@ void Blit::setCommonBlitState()
RECT scissorRect = {0}; // Scissoring is disabled for flipping, but we need this to capture and restore the old rectangle
device->SetScissorRect(&scissorRect);
- for(int i = 0; i < MAX_VERTEX_ATTRIBS; i++)
+ for(int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
{
device->SetStreamSourceFreq(i, 1);
}
@@ -427,19 +505,18 @@ void Blit::setCommonBlitState()
void Blit::render()
{
- egl::Display *display = getDisplay();
- IDirect3DDevice9 *device = getDevice();
+ IDirect3DDevice9 *device = mRenderer->getDevice();
HRESULT hr = device->SetStreamSource(0, mQuadVertexBuffer, 0, 2 * sizeof(float));
hr = device->SetVertexDeclaration(mQuadVertexDeclaration);
- display->startScene();
+ mRenderer->startScene();
hr = device->DrawPrimitive(D3DPT_TRIANGLESTRIP, 0, 2);
}
void Blit::saveState()
{
- IDirect3DDevice9 *device = getDevice();
+ IDirect3DDevice9 *device = mRenderer->getDevice();
HRESULT hr;
@@ -491,7 +568,7 @@ void Blit::saveState()
void Blit::restoreState()
{
- IDirect3DDevice9 *device = getDevice();
+ IDirect3DDevice9 *device = mRenderer->getDevice();
device->SetDepthStencilSurface(mSavedDepthStencil);
if (mSavedDepthStencil != NULL)
diff --git a/src/3rdparty/angle/src/libGLESv2/Blit.h b/src/3rdparty/angle/src/libGLESv2/renderer/Blit.h
index a9bb4956eb..3718028e66 100644
--- a/src/3rdparty/angle/src/libGLESv2/Blit.h
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Blit.h
@@ -9,30 +9,29 @@
#ifndef LIBGLESV2_BLIT_H_
#define LIBGLESV2_BLIT_H_
-#include <map>
-
-#define GL_APICALL
-#include <GLES2/gl2.h>
-
-#include <d3d9.h>
-
#include "common/angleutils.h"
-#include "libEGL/Display.h"
-
namespace gl
{
-class Context;
+class Framebuffer;
+}
+
+namespace rx
+{
+class Renderer9;
+class TextureStorageInterface2D;
+class TextureStorageInterfaceCube;
class Blit
{
public:
- explicit Blit(Context *context);
+ explicit Blit(Renderer9 *renderer);
~Blit();
// Copy from source surface to dest surface.
// sourceRect, xoffset, yoffset are in D3D coordinates (0,0 in upper-left)
- bool copy(IDirect3DSurface9 *source, const RECT &sourceRect, GLenum destFormat, GLint xoffset, GLint yoffset, IDirect3DSurface9 *dest);
+ bool copy(gl::Framebuffer *framebuffer, const RECT &sourceRect, GLenum destFormat, GLint xoffset, GLint yoffset, TextureStorageInterface2D *storage, GLint level);
+ bool copy(gl::Framebuffer *framebuffer, const RECT &sourceRect, GLenum destFormat, GLint xoffset, GLint yoffset, TextureStorageInterfaceCube *storage, GLenum target, GLint level);
// Copy from source surface to dest surface.
// sourceRect, xoffset, yoffset are in D3D coordinates (0,0 in upper-left)
@@ -44,7 +43,7 @@ class Blit
bool boxFilter(IDirect3DSurface9 *source, IDirect3DSurface9 *dest);
private:
- Context *mContext;
+ rx::Renderer9 *mRenderer;
IDirect3DVertexBuffer9 *mQuadVertexBuffer;
IDirect3DVertexDeclaration9 *mQuadVertexDeclaration;
@@ -53,6 +52,7 @@ class Blit
bool setFormatConvertShaders(GLenum destFormat);
+ bool copy(IDirect3DSurface9 *source, const RECT &sourceRect, GLenum destFormat, GLint xoffset, GLint yoffset, IDirect3DSurface9 *dest);
IDirect3DTexture9 *copySurfaceToTexture(IDirect3DSurface9 *surface, const RECT &sourceRect);
void setViewport(const RECT &sourceRect, GLint xoffset, GLint yoffset);
void setCommonBlitState();
@@ -74,7 +74,7 @@ class Blit
template <class D3DShaderType>
bool setShader(ShaderId source, const char *profile,
- D3DShaderType *(egl::Display::*createShader)(const DWORD *, size_t length),
+ D3DShaderType *(Renderer9::*createShader)(const DWORD *, size_t length),
HRESULT (WINAPI IDirect3DDevice9::*setShader)(D3DShaderType*));
bool setVertexShader(ShaderId shader);
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage.cpp
new file mode 100644
index 0000000000..a49b7bab84
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage.cpp
@@ -0,0 +1,40 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// BufferStorage.cpp Defines the abstract BufferStorage class.
+
+#include "libGLESv2/renderer/BufferStorage.h"
+
+namespace rx
+{
+
+unsigned int BufferStorage::mNextSerial = 1;
+
+BufferStorage::BufferStorage()
+{
+ updateSerial();
+}
+
+BufferStorage::~BufferStorage()
+{
+}
+
+unsigned int BufferStorage::getSerial() const
+{
+ return mSerial;
+}
+
+void BufferStorage::updateSerial()
+{
+ mSerial = mNextSerial++;
+}
+
+void BufferStorage::markBufferUsage()
+{
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage.h b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage.h
new file mode 100644
index 0000000000..ace1a11bae
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage.h
@@ -0,0 +1,44 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// BufferStorage.h Defines the abstract BufferStorage class.
+
+#ifndef LIBGLESV2_RENDERER_BUFFERSTORAGE_H_
+#define LIBGLESV2_RENDERER_BUFFERSTORAGE_H_
+
+#include "common/angleutils.h"
+
+namespace rx
+{
+
+class BufferStorage
+{
+ public:
+ BufferStorage();
+ virtual ~BufferStorage();
+
+ // The data returned is only guaranteed valid until next non-const method.
+ virtual void *getData() = 0;
+ virtual void setData(const void* data, unsigned int size, unsigned int offset) = 0;
+ virtual void clear() = 0;
+ virtual unsigned int getSize() const = 0;
+ virtual bool supportsDirectBinding() const = 0;
+ virtual void markBufferUsage();
+ unsigned int getSerial() const;
+
+ protected:
+ void updateSerial();
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(BufferStorage);
+
+ unsigned int mSerial;
+ static unsigned int mNextSerial;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_BUFFERSTORAGE_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.cpp
new file mode 100644
index 0000000000..7fe9e6b762
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.cpp
@@ -0,0 +1,352 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// BufferStorage11.cpp Defines the BufferStorage11 class.
+
+#include "libGLESv2/renderer/BufferStorage11.h"
+#include "libGLESv2/main.h"
+#include "libGLESv2/renderer/Renderer11.h"
+
+namespace rx
+{
+
+BufferStorage11::BufferStorage11(Renderer11 *renderer)
+{
+ mRenderer = renderer;
+
+ mStagingBuffer = NULL;
+ mStagingBufferSize = 0;
+
+ mBuffer = NULL;
+ mBufferSize = 0;
+
+ mSize = 0;
+
+ mResolvedData = NULL;
+ mResolvedDataSize = 0;
+ mResolvedDataValid = false;
+
+ mReadUsageCount = 0;
+ mWriteUsageCount = 0;
+}
+
+BufferStorage11::~BufferStorage11()
+{
+ if (mStagingBuffer)
+ {
+ mStagingBuffer->Release();
+ mStagingBuffer = NULL;
+ }
+
+ if (mBuffer)
+ {
+ mBuffer->Release();
+ mBuffer = NULL;
+ }
+
+ if (mResolvedData)
+ {
+ free(mResolvedData);
+ mResolvedData = NULL;
+ }
+}
+
+BufferStorage11 *BufferStorage11::makeBufferStorage11(BufferStorage *bufferStorage)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(BufferStorage11*, bufferStorage));
+ return static_cast<BufferStorage11*>(bufferStorage);
+}
+
+void *BufferStorage11::getData()
+{
+ if (!mResolvedDataValid)
+ {
+ ID3D11Device *device = mRenderer->getDevice();
+ ID3D11DeviceContext *context = mRenderer->getDeviceContext();
+ HRESULT result;
+
+ if (!mStagingBuffer || mStagingBufferSize < mBufferSize)
+ {
+ if (mStagingBuffer)
+ {
+ mStagingBuffer->Release();
+ mStagingBuffer = NULL;
+ mStagingBufferSize = 0;
+ }
+
+ D3D11_BUFFER_DESC bufferDesc;
+ bufferDesc.ByteWidth = mSize;
+ bufferDesc.Usage = D3D11_USAGE_STAGING;
+ bufferDesc.BindFlags = 0;
+ bufferDesc.CPUAccessFlags = D3D11_CPU_ACCESS_READ | D3D11_CPU_ACCESS_WRITE;
+ bufferDesc.MiscFlags = 0;
+ bufferDesc.StructureByteStride = 0;
+
+ result = device->CreateBuffer(&bufferDesc, NULL, &mStagingBuffer);
+ if (FAILED(result))
+ {
+ return gl::error(GL_OUT_OF_MEMORY, (void*)NULL);
+ }
+
+ mStagingBufferSize = bufferDesc.ByteWidth;
+ }
+
+ if (!mResolvedData || mResolvedDataSize < mBufferSize)
+ {
+ free(mResolvedData);
+ mResolvedData = malloc(mSize);
+ mResolvedDataSize = mSize;
+ }
+
+ D3D11_BOX srcBox;
+ srcBox.left = 0;
+ srcBox.right = mSize;
+ srcBox.top = 0;
+ srcBox.bottom = 1;
+ srcBox.front = 0;
+ srcBox.back = 1;
+
+ context->CopySubresourceRegion(mStagingBuffer, 0, 0, 0, 0, mBuffer, 0, &srcBox);
+
+ D3D11_MAPPED_SUBRESOURCE mappedResource;
+ result = context->Map(mStagingBuffer, 0, D3D11_MAP_READ, 0, &mappedResource);
+ if (FAILED(result))
+ {
+ return gl::error(GL_OUT_OF_MEMORY, (void*)NULL);
+ }
+
+ memcpy(mResolvedData, mappedResource.pData, mSize);
+
+ context->Unmap(mStagingBuffer, 0);
+
+ mResolvedDataValid = true;
+ }
+
+ mReadUsageCount = 0;
+
+ return mResolvedData;
+}
+
+void BufferStorage11::setData(const void* data, unsigned int size, unsigned int offset)
+{
+ ID3D11Device *device = mRenderer->getDevice();
+ ID3D11DeviceContext *context = mRenderer->getDeviceContext();
+ HRESULT result;
+
+ unsigned int requiredBufferSize = size + offset;
+ unsigned int requiredStagingSize = size;
+ bool directInitialization = offset == 0 && (!mBuffer || mBufferSize < size + offset);
+
+ if (!directInitialization)
+ {
+ if (!mStagingBuffer || mStagingBufferSize < requiredStagingSize)
+ {
+ if (mStagingBuffer)
+ {
+ mStagingBuffer->Release();
+ mStagingBuffer = NULL;
+ mStagingBufferSize = 0;
+ }
+
+ D3D11_BUFFER_DESC bufferDesc;
+ bufferDesc.ByteWidth = size;
+ bufferDesc.Usage = D3D11_USAGE_STAGING;
+ bufferDesc.BindFlags = 0;
+ bufferDesc.CPUAccessFlags = D3D11_CPU_ACCESS_READ | D3D11_CPU_ACCESS_WRITE;
+ bufferDesc.MiscFlags = 0;
+ bufferDesc.StructureByteStride = 0;
+
+ D3D11_SUBRESOURCE_DATA initialData;
+ initialData.pSysMem = data;
+ initialData.SysMemPitch = size;
+ initialData.SysMemSlicePitch = 0;
+
+ result = device->CreateBuffer(&bufferDesc, &initialData, &mStagingBuffer);
+ if (FAILED(result))
+ {
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ mStagingBufferSize = size;
+ }
+ else
+ {
+ D3D11_MAPPED_SUBRESOURCE mappedResource;
+ result = context->Map(mStagingBuffer, 0, D3D11_MAP_WRITE, 0, &mappedResource);
+ if (FAILED(result))
+ {
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ if (data)
+ memcpy(mappedResource.pData, data, size);
+
+ context->Unmap(mStagingBuffer, 0);
+ }
+ }
+
+ if (!mBuffer || mBufferSize < size + offset)
+ {
+ D3D11_BUFFER_DESC bufferDesc;
+ bufferDesc.ByteWidth = requiredBufferSize;
+ bufferDesc.Usage = D3D11_USAGE_DEFAULT;
+ bufferDesc.BindFlags = D3D11_BIND_VERTEX_BUFFER | D3D11_BIND_INDEX_BUFFER;
+ bufferDesc.CPUAccessFlags = 0;
+ bufferDesc.MiscFlags = 0;
+ bufferDesc.StructureByteStride = 0;
+
+ if (directInitialization)
+ {
+ // Since the data will fill the entire buffer (being larger than the initial size and having
+ // no offset), the buffer can be initialized with the data so no staging buffer is required
+
+ // No longer need the old buffer
+ if (mBuffer)
+ {
+ mBuffer->Release();
+ mBuffer = NULL;
+ mBufferSize = 0;
+ }
+
+
+ if (data)
+ {
+ D3D11_SUBRESOURCE_DATA initialData;
+ initialData.pSysMem = data;
+ initialData.SysMemPitch = size;
+ initialData.SysMemSlicePitch = 0;
+
+ result = device->CreateBuffer(&bufferDesc, &initialData, &mBuffer);
+ }
+ else
+ {
+ result = device->CreateBuffer(&bufferDesc, NULL, &mBuffer);
+ }
+
+ if (FAILED(result))
+ {
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+ else if (mBuffer && offset > 0)
+ {
+ // If offset is greater than zero and the buffer is non-null, need to preserve the data from
+ // the old buffer up to offset
+ ID3D11Buffer *newBuffer = NULL;
+
+ result = device->CreateBuffer(&bufferDesc, NULL, &newBuffer);
+ if (FAILED(result))
+ {
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ D3D11_BOX srcBox;
+ srcBox.left = 0;
+ srcBox.right = std::min(offset, mBufferSize);
+ srcBox.top = 0;
+ srcBox.bottom = 1;
+ srcBox.front = 0;
+ srcBox.back = 1;
+
+ context->CopySubresourceRegion(newBuffer, 0, 0, 0, 0, mBuffer, 0, &srcBox);
+
+ mBuffer->Release();
+ mBuffer = newBuffer;
+ }
+ else
+ {
+ // Simple case, nothing needs to be copied from the old buffer to the new one, just create
+ // a new buffer
+
+ // No longer need the old buffer
+ if (mBuffer)
+ {
+ mBuffer->Release();
+ mBuffer = NULL;
+ mBufferSize = 0;
+ }
+
+ // Create a new buffer for data storage
+ result = device->CreateBuffer(&bufferDesc, NULL, &mBuffer);
+ if (FAILED(result))
+ {
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ updateSerial();
+ mBufferSize = bufferDesc.ByteWidth;
+ }
+
+ if (!directInitialization)
+ {
+ ASSERT(mStagingBuffer && mStagingBufferSize >= requiredStagingSize);
+
+ // Data is already put into the staging buffer, copy it over to the data buffer
+ D3D11_BOX srcBox;
+ srcBox.left = 0;
+ srcBox.right = size;
+ srcBox.top = 0;
+ srcBox.bottom = 1;
+ srcBox.front = 0;
+ srcBox.back = 1;
+
+ context->CopySubresourceRegion(mBuffer, 0, offset, 0, 0, mStagingBuffer, 0, &srcBox);
+ }
+
+ mSize = std::max(mSize, offset + size);
+
+ mWriteUsageCount = 0;
+
+ mResolvedDataValid = false;
+}
+
+void BufferStorage11::clear()
+{
+ mResolvedDataValid = false;
+ mSize = 0;
+}
+
+unsigned int BufferStorage11::getSize() const
+{
+ return mSize;
+}
+
+bool BufferStorage11::supportsDirectBinding() const
+{
+ return true;
+}
+
+void BufferStorage11::markBufferUsage()
+{
+ mReadUsageCount++;
+ mWriteUsageCount++;
+
+ static const unsigned int usageLimit = 5;
+
+ if (mReadUsageCount > usageLimit && mResolvedData)
+ {
+ free(mResolvedData);
+ mResolvedData = NULL;
+ mResolvedDataSize = 0;
+ mResolvedDataValid = false;
+ }
+
+ if (mReadUsageCount > usageLimit && mWriteUsageCount > usageLimit && mStagingBuffer)
+ {
+ mStagingBuffer->Release();
+ mStagingBuffer = NULL;
+ mStagingBufferSize = 0;
+ }
+}
+
+ID3D11Buffer *BufferStorage11::getBuffer() const
+{
+ return mBuffer;
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.h b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.h
new file mode 100644
index 0000000000..b62348b0c9
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.h
@@ -0,0 +1,56 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// BufferStorage11.h Defines the BufferStorage11 class.
+
+#ifndef LIBGLESV2_RENDERER_BUFFERSTORAGE11_H_
+#define LIBGLESV2_RENDERER_BUFFERSTORAGE11_H_
+
+#include "libGLESv2/renderer/BufferStorage.h"
+
+namespace rx
+{
+class Renderer11;
+
+class BufferStorage11 : public BufferStorage
+{
+ public:
+ explicit BufferStorage11(Renderer11 *renderer);
+ virtual ~BufferStorage11();
+
+ static BufferStorage11 *makeBufferStorage11(BufferStorage *bufferStorage);
+
+ virtual void *getData();
+ virtual void setData(const void* data, unsigned int size, unsigned int offset);
+ virtual void clear();
+ virtual unsigned int getSize() const;
+ virtual bool supportsDirectBinding() const;
+ virtual void markBufferUsage();
+
+ ID3D11Buffer *getBuffer() const;
+
+ private:
+ Renderer11 *mRenderer;
+
+ ID3D11Buffer *mStagingBuffer;
+ unsigned int mStagingBufferSize;
+
+ ID3D11Buffer *mBuffer;
+ unsigned int mBufferSize;
+
+ unsigned int mSize;
+
+ void *mResolvedData;
+ unsigned int mResolvedDataSize;
+ bool mResolvedDataValid;
+
+ unsigned int mReadUsageCount;
+ unsigned int mWriteUsageCount;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_BUFFERSTORAGE11_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.cpp
new file mode 100644
index 0000000000..4468461871
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.cpp
@@ -0,0 +1,76 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// BufferStorage9.cpp Defines the BufferStorage9 class.
+
+#include "libGLESv2/renderer/BufferStorage9.h"
+#include "common/debug.h"
+
+namespace rx
+{
+
+BufferStorage9::BufferStorage9()
+{
+ mMemory = NULL;
+ mAllocatedSize = 0;
+ mSize = 0;
+}
+
+BufferStorage9::~BufferStorage9()
+{
+ delete[] mMemory;
+}
+
+BufferStorage9 *BufferStorage9::makeBufferStorage9(BufferStorage *bufferStorage)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(BufferStorage9*, bufferStorage));
+ return static_cast<BufferStorage9*>(bufferStorage);
+}
+
+void *BufferStorage9::getData()
+{
+ return mMemory;
+}
+
+void BufferStorage9::setData(const void* data, unsigned int size, unsigned int offset)
+{
+ if (!mMemory || offset + size > mAllocatedSize)
+ {
+ unsigned int newAllocatedSize = offset + size;
+ void *newMemory = new char[newAllocatedSize];
+
+ if (offset > 0 && mMemory && mAllocatedSize > 0)
+ {
+ memcpy(newMemory, mMemory, std::min(offset, mAllocatedSize));
+ }
+
+ delete[] mMemory;
+ mMemory = newMemory;
+ mAllocatedSize = newAllocatedSize;
+ }
+
+ mSize = std::max(mSize, offset + size);
+ if (data)
+ memcpy(reinterpret_cast<char*>(mMemory) + offset, data, size);
+}
+
+void BufferStorage9::clear()
+{
+ mSize = 0;
+}
+
+unsigned int BufferStorage9::getSize() const
+{
+ return mSize;
+}
+
+bool BufferStorage9::supportsDirectBinding() const
+{
+ return false;
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.h b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.h
new file mode 100644
index 0000000000..3e803969bc
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.h
@@ -0,0 +1,42 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// BufferStorage9.h Defines the BufferStorage9 class.
+
+#ifndef LIBGLESV2_RENDERER_BUFFERSTORAGE9_H_
+#define LIBGLESV2_RENDERER_BUFFERSTORAGE9_H_
+
+#include "libGLESv2/renderer/BufferStorage.h"
+
+namespace rx
+{
+
+class BufferStorage9 : public BufferStorage
+{
+ public:
+ BufferStorage9();
+ virtual ~BufferStorage9();
+
+ static BufferStorage9 *makeBufferStorage9(BufferStorage *bufferStorage);
+
+ virtual void *getData();
+ virtual void setData(const void* data, unsigned int size, unsigned int offset);
+ virtual void clear();
+ virtual unsigned int getSize() const;
+ virtual bool supportsDirectBinding() const;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(BufferStorage9);
+
+ void *mMemory;
+ unsigned int mAllocatedSize;
+
+ unsigned int mSize;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_BUFFERSTORAGE9_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Fence11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Fence11.cpp
new file mode 100644
index 0000000000..9d11c9a0fc
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Fence11.cpp
@@ -0,0 +1,134 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Fence11.cpp: Defines the rx::Fence11 class which implements rx::FenceImpl.
+
+#include "libGLESv2/renderer/Fence11.h"
+#include "libGLESv2/main.h"
+#include "libGLESv2/renderer/Renderer11.h"
+
+namespace rx
+{
+
+Fence11::Fence11(rx::Renderer11 *renderer)
+{
+ mRenderer = renderer;
+ mQuery = NULL;
+}
+
+Fence11::~Fence11()
+{
+ if (mQuery)
+ {
+ mQuery->Release();
+ mQuery = NULL;
+ }
+}
+
+GLboolean Fence11::isFence()
+{
+ // GL_NV_fence spec:
+ // A name returned by GenFencesNV, but not yet set via SetFenceNV, is not the name of an existing fence.
+ return mQuery != NULL;
+}
+
+void Fence11::setFence(GLenum condition)
+{
+ if (!mQuery)
+ {
+ D3D11_QUERY_DESC queryDesc;
+ queryDesc.Query = D3D11_QUERY_EVENT;
+ queryDesc.MiscFlags = 0;
+
+ if (FAILED(mRenderer->getDevice()->CreateQuery(&queryDesc, &mQuery)))
+ {
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ mRenderer->getDeviceContext()->End(mQuery);
+
+ setCondition(condition);
+ setStatus(GL_FALSE);
+}
+
+GLboolean Fence11::testFence()
+{
+ if (mQuery == NULL)
+ {
+ return gl::error(GL_INVALID_OPERATION, GL_TRUE);
+ }
+
+ HRESULT result = mRenderer->getDeviceContext()->GetData(mQuery, NULL, 0, 0);
+
+ if (mRenderer->isDeviceLost())
+ {
+ return gl::error(GL_OUT_OF_MEMORY, GL_TRUE);
+ }
+
+ ASSERT(result == S_OK || result == S_FALSE);
+ setStatus(result == S_OK);
+ return getStatus();
+}
+
+void Fence11::finishFence()
+{
+ if (mQuery == NULL)
+ {
+ return gl::error(GL_INVALID_OPERATION);
+ }
+
+ while (!testFence())
+ {
+ Sleep(0);
+ }
+}
+
+void Fence11::getFenceiv(GLenum pname, GLint *params)
+{
+ if (mQuery == NULL)
+ {
+ return gl::error(GL_INVALID_OPERATION);
+ }
+
+ switch (pname)
+ {
+ case GL_FENCE_STATUS_NV:
+ {
+ // GL_NV_fence spec:
+ // Once the status of a fence has been finished (via FinishFenceNV) or tested and the returned status is TRUE (via either TestFenceNV
+ // or GetFenceivNV querying the FENCE_STATUS_NV), the status remains TRUE until the next SetFenceNV of the fence.
+ if (getStatus())
+ {
+ params[0] = GL_TRUE;
+ return;
+ }
+
+ HRESULT result = mRenderer->getDeviceContext()->GetData(mQuery, NULL, 0, D3D11_ASYNC_GETDATA_DONOTFLUSH);
+
+ if (mRenderer->isDeviceLost())
+ {
+ params[0] = GL_TRUE;
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ ASSERT(result == S_OK || result == S_FALSE);
+ setStatus(result == S_OK);
+ params[0] = getStatus();
+
+ break;
+ }
+ case GL_FENCE_CONDITION_NV:
+ params[0] = getCondition();
+ break;
+ default:
+ return gl::error(GL_INVALID_ENUM);
+ break;
+ }
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Fence11.h b/src/3rdparty/angle/src/libGLESv2/renderer/Fence11.h
new file mode 100644
index 0000000000..a5398bca14
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Fence11.h
@@ -0,0 +1,39 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Fence11.h: Defines the rx::Fence11 class which implements rx::FenceImpl.
+
+#ifndef LIBGLESV2_RENDERER_Fence11_H_
+#define LIBGLESV2_RENDERER_Fence11_H_
+
+#include "libGLESv2/renderer/FenceImpl.h"
+
+namespace rx
+{
+class Renderer11;
+
+class Fence11 : public FenceImpl
+{
+ public:
+ explicit Fence11(rx::Renderer11 *renderer);
+ virtual ~Fence11();
+
+ GLboolean isFence();
+ void setFence(GLenum condition);
+ GLboolean testFence();
+ void finishFence();
+ void getFenceiv(GLenum pname, GLint *params);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(Fence11);
+
+ rx::Renderer11 *mRenderer;
+ ID3D11Query *mQuery;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_FENCE11_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Fence9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Fence9.cpp
new file mode 100644
index 0000000000..86064d7e52
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Fence9.cpp
@@ -0,0 +1,135 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Fence9.cpp: Defines the rx::Fence9 class.
+
+#include "libGLESv2/renderer/Fence9.h"
+#include "libGLESv2/main.h"
+#include "libGLESv2/renderer/renderer9_utils.h"
+#include "libGLESv2/renderer/Renderer9.h"
+
+namespace rx
+{
+
+Fence9::Fence9(rx::Renderer9 *renderer)
+{
+ mRenderer = renderer;
+ mQuery = NULL;
+}
+
+Fence9::~Fence9()
+{
+ if (mQuery)
+ {
+ mRenderer->freeEventQuery(mQuery);
+ mQuery = NULL;
+ }
+}
+
+GLboolean Fence9::isFence()
+{
+ // GL_NV_fence spec:
+ // A name returned by GenFencesNV, but not yet set via SetFenceNV, is not the name of an existing fence.
+ return mQuery != NULL;
+}
+
+void Fence9::setFence(GLenum condition)
+{
+ if (!mQuery)
+ {
+ mQuery = mRenderer->allocateEventQuery();
+ if (!mQuery)
+ {
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ HRESULT result = mQuery->Issue(D3DISSUE_END);
+ ASSERT(SUCCEEDED(result));
+
+ setCondition(condition);
+ setStatus(GL_FALSE);
+}
+
+GLboolean Fence9::testFence()
+{
+ if (mQuery == NULL)
+ {
+ return gl::error(GL_INVALID_OPERATION, GL_TRUE);
+ }
+
+ HRESULT result = mQuery->GetData(NULL, 0, D3DGETDATA_FLUSH);
+
+ if (d3d9::isDeviceLostError(result))
+ {
+ mRenderer->notifyDeviceLost();
+ return gl::error(GL_OUT_OF_MEMORY, GL_TRUE);
+ }
+
+ ASSERT(result == S_OK || result == S_FALSE);
+ setStatus(result == S_OK);
+ return getStatus();
+}
+
+void Fence9::finishFence()
+{
+ if (mQuery == NULL)
+ {
+ return gl::error(GL_INVALID_OPERATION);
+ }
+
+ while (!testFence())
+ {
+ Sleep(0);
+ }
+}
+
+void Fence9::getFenceiv(GLenum pname, GLint *params)
+{
+ if (mQuery == NULL)
+ {
+ return gl::error(GL_INVALID_OPERATION);
+ }
+
+ switch (pname)
+ {
+ case GL_FENCE_STATUS_NV:
+ {
+ // GL_NV_fence spec:
+ // Once the status of a fence has been finished (via FinishFenceNV) or tested and the returned status is TRUE (via either TestFenceNV
+ // or GetFenceivNV querying the FENCE_STATUS_NV), the status remains TRUE until the next SetFenceNV of the fence.
+ if (getStatus())
+ {
+ params[0] = GL_TRUE;
+ return;
+ }
+
+ HRESULT result = mQuery->GetData(NULL, 0, 0);
+
+ if (d3d9::isDeviceLostError(result))
+ {
+ params[0] = GL_TRUE;
+ mRenderer->notifyDeviceLost();
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ ASSERT(result == S_OK || result == S_FALSE);
+ setStatus(result == S_OK);
+ params[0] = getStatus();
+
+ break;
+ }
+ case GL_FENCE_CONDITION_NV:
+ params[0] = getCondition();
+ break;
+ default:
+ return gl::error(GL_INVALID_ENUM);
+ break;
+ }
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Fence9.h b/src/3rdparty/angle/src/libGLESv2/renderer/Fence9.h
new file mode 100644
index 0000000000..9f17641e51
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Fence9.h
@@ -0,0 +1,39 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Fence9.h: Defines the rx::Fence9 class which implements rx::FenceImpl.
+
+#ifndef LIBGLESV2_RENDERER_FENCE9_H_
+#define LIBGLESV2_RENDERER_FENCE9_H_
+
+#include "libGLESv2/renderer/FenceImpl.h"
+
+namespace rx
+{
+class Renderer9;
+
+class Fence9 : public FenceImpl
+{
+ public:
+ explicit Fence9(rx::Renderer9 *renderer);
+ virtual ~Fence9();
+
+ GLboolean isFence();
+ void setFence(GLenum condition);
+ GLboolean testFence();
+ void finishFence();
+ void getFenceiv(GLenum pname, GLint *params);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(Fence9);
+
+ rx::Renderer9 *mRenderer;
+ IDirect3DQuery9 *mQuery;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_FENCE9_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/FenceImpl.h b/src/3rdparty/angle/src/libGLESv2/renderer/FenceImpl.h
new file mode 100644
index 0000000000..d7f2102a2e
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/FenceImpl.h
@@ -0,0 +1,45 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// FenceImpl.h: Defines the rx::FenceImpl class.
+
+#ifndef LIBGLESV2_RENDERER_FENCEIMPL_H_
+#define LIBGLESV2_RENDERER_FENCEIMPL_H_
+
+#include "common/angleutils.h"
+
+namespace rx
+{
+
+class FenceImpl
+{
+ public:
+ FenceImpl() : mStatus(GL_FALSE), mCondition(GL_NONE) { };
+ virtual ~FenceImpl() { };
+
+ virtual GLboolean isFence() = 0;
+ virtual void setFence(GLenum condition) = 0;
+ virtual GLboolean testFence() = 0;
+ virtual void finishFence() = 0;
+ virtual void getFenceiv(GLenum pname, GLint *params) = 0;
+
+ protected:
+ void setStatus(GLboolean status) { mStatus = status; }
+ GLboolean getStatus() const { return mStatus; }
+
+ void setCondition(GLuint condition) { mCondition = condition; }
+ GLuint getCondition() const { return mCondition; }
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(FenceImpl);
+
+ GLboolean mStatus;
+ GLenum mCondition;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_FENCEIMPL_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Image.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Image.cpp
new file mode 100644
index 0000000000..57239ef74f
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Image.cpp
@@ -0,0 +1,548 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Image.h: Implements the rx::Image class, an abstract base class for the
+// renderer-specific classes which will define the interface to the underlying
+// surfaces or resources.
+
+#include "libGLESv2/renderer/Image.h"
+
+namespace rx
+{
+
+Image::Image()
+{
+ mWidth = 0;
+ mHeight = 0;
+ mInternalFormat = GL_NONE;
+ mActualFormat = GL_NONE;
+}
+
+void Image::loadAlphaDataToBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned char *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = static_cast<const unsigned char*>(input) + y * inputPitch;
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = 0;
+ dest[4 * x + 1] = 0;
+ dest[4 * x + 2] = 0;
+ dest[4 * x + 3] = source[x];
+ }
+ }
+}
+
+void Image::loadAlphaDataToNative(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned char *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = static_cast<const unsigned char*>(input) + y * inputPitch;
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+ memcpy(dest, source, width);
+ }
+}
+
+void Image::loadAlphaFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const float *source = NULL;
+ float *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const float*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<float*>(static_cast<unsigned char*>(output) + y * outputPitch);
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = 0;
+ dest[4 * x + 1] = 0;
+ dest[4 * x + 2] = 0;
+ dest[4 * x + 3] = source[x];
+ }
+ }
+}
+
+void Image::loadAlphaHalfFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned short *source = NULL;
+ unsigned short *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<unsigned short*>(static_cast<unsigned char*>(output) + y * outputPitch);
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = 0;
+ dest[4 * x + 1] = 0;
+ dest[4 * x + 2] = 0;
+ dest[4 * x + 3] = source[x];
+ }
+ }
+}
+
+void Image::loadLuminanceDataToNativeOrBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output, bool native)
+{
+ const unsigned char *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = static_cast<const unsigned char*>(input) + y * inputPitch;
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+
+ if (!native) // BGRA8 destination format
+ {
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = source[x];
+ dest[4 * x + 1] = source[x];
+ dest[4 * x + 2] = source[x];
+ dest[4 * x + 3] = 0xFF;
+ }
+ }
+ else // L8 destination format
+ {
+ memcpy(dest, source, width);
+ }
+ }
+}
+
+void Image::loadLuminanceFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const float *source = NULL;
+ float *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const float*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<float*>(static_cast<unsigned char*>(output) + y * outputPitch);
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = source[x];
+ dest[4 * x + 1] = source[x];
+ dest[4 * x + 2] = source[x];
+ dest[4 * x + 3] = 1.0f;
+ }
+ }
+}
+
+void Image::loadLuminanceFloatDataToRGB(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const float *source = NULL;
+ float *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const float*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<float*>(static_cast<unsigned char*>(output) + y * outputPitch);
+ for (int x = 0; x < width; x++)
+ {
+ dest[3 * x + 0] = source[x];
+ dest[3 * x + 1] = source[x];
+ dest[3 * x + 2] = source[x];
+ }
+ }
+}
+
+void Image::loadLuminanceHalfFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned short *source = NULL;
+ unsigned short *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<unsigned short*>(static_cast<unsigned char*>(output) + y * outputPitch);
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = source[x];
+ dest[4 * x + 1] = source[x];
+ dest[4 * x + 2] = source[x];
+ dest[4 * x + 3] = 0x3C00; // SEEEEEMMMMMMMMMM, S = 0, E = 15, M = 0: 16bit flpt representation of 1
+ }
+ }
+}
+
+void Image::loadLuminanceAlphaDataToNativeOrBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output, bool native)
+{
+ const unsigned char *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = static_cast<const unsigned char*>(input) + y * inputPitch;
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+
+ if (!native) // BGRA8 destination format
+ {
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = source[2*x+0];
+ dest[4 * x + 1] = source[2*x+0];
+ dest[4 * x + 2] = source[2*x+0];
+ dest[4 * x + 3] = source[2*x+1];
+ }
+ }
+ else
+ {
+ memcpy(dest, source, width * 2);
+ }
+ }
+}
+
+void Image::loadLuminanceAlphaFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const float *source = NULL;
+ float *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const float*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<float*>(static_cast<unsigned char*>(output) + y * outputPitch);
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = source[2*x+0];
+ dest[4 * x + 1] = source[2*x+0];
+ dest[4 * x + 2] = source[2*x+0];
+ dest[4 * x + 3] = source[2*x+1];
+ }
+ }
+}
+
+void Image::loadLuminanceAlphaHalfFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned short *source = NULL;
+ unsigned short *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<unsigned short*>(static_cast<unsigned char*>(output) + y * outputPitch);
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = source[2*x+0];
+ dest[4 * x + 1] = source[2*x+0];
+ dest[4 * x + 2] = source[2*x+0];
+ dest[4 * x + 3] = source[2*x+1];
+ }
+ }
+}
+
+void Image::loadRGBUByteDataToBGRX(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned char *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = static_cast<const unsigned char*>(input) + y * inputPitch;
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = source[x * 3 + 2];
+ dest[4 * x + 1] = source[x * 3 + 1];
+ dest[4 * x + 2] = source[x * 3 + 0];
+ dest[4 * x + 3] = 0xFF;
+ }
+ }
+}
+
+void Image::loadRGBUByteDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned char *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = static_cast<const unsigned char*>(input) + y * inputPitch;
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = source[x * 3 + 0];
+ dest[4 * x + 1] = source[x * 3 + 1];
+ dest[4 * x + 2] = source[x * 3 + 2];
+ dest[4 * x + 3] = 0xFF;
+ }
+ }
+}
+
+void Image::loadRGB565DataToBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned short *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+ for (int x = 0; x < width; x++)
+ {
+ unsigned short rgba = source[x];
+ dest[4 * x + 0] = ((rgba & 0x001F) << 3) | ((rgba & 0x001F) >> 2);
+ dest[4 * x + 1] = ((rgba & 0x07E0) >> 3) | ((rgba & 0x07E0) >> 9);
+ dest[4 * x + 2] = ((rgba & 0xF800) >> 8) | ((rgba & 0xF800) >> 13);
+ dest[4 * x + 3] = 0xFF;
+ }
+ }
+}
+
+void Image::loadRGB565DataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned short *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+ for (int x = 0; x < width; x++)
+ {
+ unsigned short rgba = source[x];
+ dest[4 * x + 0] = ((rgba & 0xF800) >> 8) | ((rgba & 0xF800) >> 13);
+ dest[4 * x + 1] = ((rgba & 0x07E0) >> 3) | ((rgba & 0x07E0) >> 9);
+ dest[4 * x + 2] = ((rgba & 0x001F) << 3) | ((rgba & 0x001F) >> 2);
+ dest[4 * x + 3] = 0xFF;
+ }
+ }
+}
+
+void Image::loadRGBFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const float *source = NULL;
+ float *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const float*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<float*>(static_cast<unsigned char*>(output) + y * outputPitch);
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = source[x * 3 + 0];
+ dest[4 * x + 1] = source[x * 3 + 1];
+ dest[4 * x + 2] = source[x * 3 + 2];
+ dest[4 * x + 3] = 1.0f;
+ }
+ }
+}
+
+void Image::loadRGBFloatDataToNative(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const float *source = NULL;
+ float *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const float*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<float*>(static_cast<unsigned char*>(output) + y * outputPitch);
+ memcpy(dest, source, width * 12);
+ }
+}
+
+void Image::loadRGBHalfFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned short *source = NULL;
+ unsigned short *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<unsigned short*>(static_cast<unsigned char*>(output) + y * outputPitch);
+ for (int x = 0; x < width; x++)
+ {
+ dest[4 * x + 0] = source[x * 3 + 0];
+ dest[4 * x + 1] = source[x * 3 + 1];
+ dest[4 * x + 2] = source[x * 3 + 2];
+ dest[4 * x + 3] = 0x3C00; // SEEEEEMMMMMMMMMM, S = 0, E = 15, M = 0: 16bit flpt representation of 1
+ }
+ }
+}
+
+void Image::loadRGBAUByteDataToBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned int *source = NULL;
+ unsigned int *dest = NULL;
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const unsigned int*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<unsigned int*>(static_cast<unsigned char*>(output) + y * outputPitch);
+
+ for (int x = 0; x < width; x++)
+ {
+ unsigned int rgba = source[x];
+ dest[x] = (_rotl(rgba, 16) & 0x00ff00ff) | (rgba & 0xff00ff00);
+ }
+ }
+}
+
+void Image::loadRGBAUByteDataToNative(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned int *source = NULL;
+ unsigned int *dest = NULL;
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const unsigned int*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<unsigned int*>(static_cast<unsigned char*>(output) + y * outputPitch);
+
+ memcpy(dest, source, width * 4);
+ }
+}
+
+void Image::loadRGBA4444DataToBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned short *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+ for (int x = 0; x < width; x++)
+ {
+ unsigned short rgba = source[x];
+ dest[4 * x + 0] = ((rgba & 0x00F0) << 0) | ((rgba & 0x00F0) >> 4);
+ dest[4 * x + 1] = ((rgba & 0x0F00) >> 4) | ((rgba & 0x0F00) >> 8);
+ dest[4 * x + 2] = ((rgba & 0xF000) >> 8) | ((rgba & 0xF000) >> 12);
+ dest[4 * x + 3] = ((rgba & 0x000F) << 4) | ((rgba & 0x000F) >> 0);
+ }
+ }
+}
+
+void Image::loadRGBA4444DataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned short *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+ for (int x = 0; x < width; x++)
+ {
+ unsigned short rgba = source[x];
+ dest[4 * x + 0] = ((rgba & 0xF000) >> 8) | ((rgba & 0xF000) >> 12);
+ dest[4 * x + 1] = ((rgba & 0x0F00) >> 4) | ((rgba & 0x0F00) >> 8);
+ dest[4 * x + 2] = ((rgba & 0x00F0) << 0) | ((rgba & 0x00F0) >> 4);
+ dest[4 * x + 3] = ((rgba & 0x000F) << 4) | ((rgba & 0x000F) >> 0);
+ }
+ }
+}
+
+void Image::loadRGBA5551DataToBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned short *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+ for (int x = 0; x < width; x++)
+ {
+ unsigned short rgba = source[x];
+ dest[4 * x + 0] = ((rgba & 0x003E) << 2) | ((rgba & 0x003E) >> 3);
+ dest[4 * x + 1] = ((rgba & 0x07C0) >> 3) | ((rgba & 0x07C0) >> 8);
+ dest[4 * x + 2] = ((rgba & 0xF800) >> 8) | ((rgba & 0xF800) >> 13);
+ dest[4 * x + 3] = (rgba & 0x0001) ? 0xFF : 0;
+ }
+ }
+}
+
+void Image::loadRGBA5551DataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned short *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const unsigned short*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+ for (int x = 0; x < width; x++)
+ {
+ unsigned short rgba = source[x];
+ dest[4 * x + 0] = ((rgba & 0xF800) >> 8) | ((rgba & 0xF800) >> 13);
+ dest[4 * x + 1] = ((rgba & 0x07C0) >> 3) | ((rgba & 0x07C0) >> 8);
+ dest[4 * x + 2] = ((rgba & 0x003E) << 2) | ((rgba & 0x003E) >> 3);
+ dest[4 * x + 3] = (rgba & 0x0001) ? 0xFF : 0;
+ }
+ }
+}
+
+void Image::loadRGBAFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const float *source = NULL;
+ float *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = reinterpret_cast<const float*>(static_cast<const unsigned char*>(input) + y * inputPitch);
+ dest = reinterpret_cast<float*>(static_cast<unsigned char*>(output) + y * outputPitch);
+ memcpy(dest, source, width * 16);
+ }
+}
+
+void Image::loadRGBAHalfFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned char *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = static_cast<const unsigned char*>(input) + y * inputPitch;
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+ memcpy(dest, source, width * 8);
+ }
+}
+
+void Image::loadBGRADataToBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
+{
+ const unsigned char *source = NULL;
+ unsigned char *dest = NULL;
+
+ for (int y = 0; y < height; y++)
+ {
+ source = static_cast<const unsigned char*>(input) + y * inputPitch;
+ dest = static_cast<unsigned char*>(output) + y * outputPitch;
+ memcpy(dest, source, width*4);
+ }
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Image.h b/src/3rdparty/angle/src/libGLESv2/renderer/Image.h
new file mode 100644
index 0000000000..454e83e21e
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Image.h
@@ -0,0 +1,131 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Image.h: Defines the rx::Image class, an abstract base class for the
+// renderer-specific classes which will define the interface to the underlying
+// surfaces or resources.
+
+#ifndef LIBGLESV2_RENDERER_IMAGE_H_
+#define LIBGLESV2_RENDERER_IMAGE_H_
+
+#include "common/debug.h"
+
+namespace gl
+{
+class Framebuffer;
+}
+
+namespace rx
+{
+class Renderer;
+class TextureStorageInterface2D;
+class TextureStorageInterfaceCube;
+
+class Image
+{
+ public:
+ Image();
+ virtual ~Image() {};
+
+ GLsizei getWidth() const { return mWidth; }
+ GLsizei getHeight() const { return mHeight; }
+ GLenum getInternalFormat() const { return mInternalFormat; }
+ GLenum getActualFormat() const { return mActualFormat; }
+
+ void markDirty() {mDirty = true;}
+ void markClean() {mDirty = false;}
+ virtual bool isDirty() const = 0;
+
+ virtual void setManagedSurface(TextureStorageInterface2D *storage, int level) {};
+ virtual void setManagedSurface(TextureStorageInterfaceCube *storage, int face, int level) {};
+ virtual bool updateSurface(TextureStorageInterface2D *storage, int level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height) = 0;
+ virtual bool updateSurface(TextureStorageInterfaceCube *storage, int face, int level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height) = 0;
+
+ virtual bool redefine(Renderer *renderer, GLint internalformat, GLsizei width, GLsizei height, bool forceRelease) = 0;
+
+ virtual bool isRenderableFormat() const = 0;
+
+ virtual void loadData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
+ GLint unpackAlignment, const void *input) = 0;
+ virtual void loadCompressedData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
+ const void *input) = 0;
+
+ virtual void copy(GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height, gl::Framebuffer *source) = 0;
+
+ static void loadAlphaDataToBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadAlphaDataToNative(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadAlphaDataToBGRASSE2(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadAlphaFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadAlphaHalfFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadLuminanceDataToNativeOrBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output, bool native);
+ static void loadLuminanceFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadLuminanceFloatDataToRGB(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadLuminanceHalfFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadLuminanceAlphaDataToNativeOrBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output, bool native);
+ static void loadLuminanceAlphaFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadLuminanceAlphaHalfFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBUByteDataToBGRX(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBUByteDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGB565DataToBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGB565DataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBFloatDataToNative(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBHalfFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBAUByteDataToBGRASSE2(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBAUByteDataToBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBAUByteDataToNative(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBA4444DataToBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBA4444DataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBA5551DataToBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBA5551DataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBAFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadRGBAHalfFloatDataToRGBA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+ static void loadBGRADataToBGRA(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output);
+
+ protected:
+ GLsizei mWidth;
+ GLsizei mHeight;
+ GLint mInternalFormat;
+ GLenum mActualFormat;
+
+ bool mDirty;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(Image);
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_IMAGE_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Image11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Image11.cpp
new file mode 100644
index 0000000000..8c78c7d750
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Image11.cpp
@@ -0,0 +1,457 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Image11.h: Implements the rx::Image11 class, which acts as the interface to
+// the actual underlying resources of a Texture
+
+#include "libGLESv2/renderer/Renderer11.h"
+#include "libGLESv2/renderer/Image11.h"
+#include "libGLESv2/renderer/TextureStorage11.h"
+#include "libGLESv2/Framebuffer.h"
+#include "libGLESv2/Renderbuffer.h"
+
+#include "libGLESv2/main.h"
+#include "libGLESv2/utilities.h"
+#include "libGLESv2/renderer/renderer11_utils.h"
+#include "libGLESv2/renderer/generatemip.h"
+
+namespace rx
+{
+
+Image11::Image11()
+{
+ mStagingTexture = NULL;
+ mRenderer = NULL;
+ mDXGIFormat = DXGI_FORMAT_UNKNOWN;
+}
+
+Image11::~Image11()
+{
+ if (mStagingTexture)
+ {
+ mStagingTexture->Release();
+ }
+}
+
+Image11 *Image11::makeImage11(Image *img)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(rx::Image11*, img));
+ return static_cast<rx::Image11*>(img);
+}
+
+void Image11::generateMipmap(Image11 *dest, Image11 *src)
+{
+ ASSERT(src->getDXGIFormat() == dest->getDXGIFormat());
+ ASSERT(src->getWidth() == 1 || src->getWidth() / 2 == dest->getWidth());
+ ASSERT(src->getHeight() == 1 || src->getHeight() / 2 == dest->getHeight());
+
+ D3D11_MAPPED_SUBRESOURCE destMapped, srcMapped;
+ dest->map(&destMapped);
+ src->map(&srcMapped);
+
+ const unsigned char *sourceData = reinterpret_cast<const unsigned char*>(srcMapped.pData);
+ unsigned char *destData = reinterpret_cast<unsigned char*>(destMapped.pData);
+
+ if (sourceData && destData)
+ {
+ switch (src->getDXGIFormat())
+ {
+ case DXGI_FORMAT_R8G8B8A8_UNORM:
+ case DXGI_FORMAT_B8G8R8A8_UNORM:
+ GenerateMip<R8G8B8A8>(src->getWidth(), src->getHeight(), sourceData, srcMapped.RowPitch, destData, destMapped.RowPitch);
+ break;
+ case DXGI_FORMAT_A8_UNORM:
+ GenerateMip<A8>(src->getWidth(), src->getHeight(), sourceData, srcMapped.RowPitch, destData, destMapped.RowPitch);
+ break;
+ case DXGI_FORMAT_R8_UNORM:
+ GenerateMip<R8>(src->getWidth(), src->getHeight(), sourceData, srcMapped.RowPitch, destData, destMapped.RowPitch);
+ break;
+ case DXGI_FORMAT_R32G32B32A32_FLOAT:
+ GenerateMip<A32B32G32R32F>(src->getWidth(), src->getHeight(), sourceData, srcMapped.RowPitch, destData, destMapped.RowPitch);
+ break;
+ case DXGI_FORMAT_R32G32B32_FLOAT:
+ GenerateMip<R32G32B32F>(src->getWidth(), src->getHeight(), sourceData, srcMapped.RowPitch, destData, destMapped.RowPitch);
+ break;
+ case DXGI_FORMAT_R16G16B16A16_FLOAT:
+ GenerateMip<A16B16G16R16F>(src->getWidth(), src->getHeight(), sourceData, srcMapped.RowPitch, destData, destMapped.RowPitch);
+ break;
+ case DXGI_FORMAT_R8G8_UNORM:
+ GenerateMip<R8G8>(src->getWidth(), src->getHeight(), sourceData, srcMapped.RowPitch, destData, destMapped.RowPitch);
+ break;
+ case DXGI_FORMAT_R16_FLOAT:
+ GenerateMip<R16F>(src->getWidth(), src->getHeight(), sourceData, srcMapped.RowPitch, destData, destMapped.RowPitch);
+ break;
+ case DXGI_FORMAT_R16G16_FLOAT:
+ GenerateMip<R16G16F>(src->getWidth(), src->getHeight(), sourceData, srcMapped.RowPitch, destData, destMapped.RowPitch);
+ break;
+ case DXGI_FORMAT_R32_FLOAT:
+ GenerateMip<R32F>(src->getWidth(), src->getHeight(), sourceData, srcMapped.RowPitch, destData, destMapped.RowPitch);
+ break;
+ case DXGI_FORMAT_R32G32_FLOAT:
+ GenerateMip<R32G32F>(src->getWidth(), src->getHeight(), sourceData, srcMapped.RowPitch, destData, destMapped.RowPitch);
+ break;
+ default:
+ UNREACHABLE();
+ break;
+ }
+
+ dest->unmap();
+ src->unmap();
+ }
+
+ dest->markDirty();
+}
+
+bool Image11::isDirty() const
+{
+ return (mStagingTexture && mDirty);
+}
+
+bool Image11::updateSurface(TextureStorageInterface2D *storage, int level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height)
+{
+ TextureStorage11_2D *storage11 = TextureStorage11_2D::makeTextureStorage11_2D(storage->getStorageInstance());
+ return storage11->updateSubresourceLevel(getStagingTexture(), getStagingSubresource(), level, 0, xoffset, yoffset, width, height);
+}
+
+bool Image11::updateSurface(TextureStorageInterfaceCube *storage, int face, int level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height)
+{
+ TextureStorage11_Cube *storage11 = TextureStorage11_Cube::makeTextureStorage11_Cube(storage->getStorageInstance());
+ return storage11->updateSubresourceLevel(getStagingTexture(), getStagingSubresource(), level, face, xoffset, yoffset, width, height);
+}
+
+bool Image11::redefine(Renderer *renderer, GLint internalformat, GLsizei width, GLsizei height, bool forceRelease)
+{
+ if (mWidth != width ||
+ mHeight != height ||
+ mInternalFormat != internalformat ||
+ forceRelease)
+ {
+ mRenderer = Renderer11::makeRenderer11(renderer);
+
+ mWidth = width;
+ mHeight = height;
+ mInternalFormat = internalformat;
+ // compute the d3d format that will be used
+ mDXGIFormat = gl_d3d11::ConvertTextureFormat(internalformat);
+ mActualFormat = d3d11_gl::ConvertTextureInternalFormat(mDXGIFormat);
+
+ if (mStagingTexture)
+ {
+ mStagingTexture->Release();
+ mStagingTexture = NULL;
+ }
+
+ return true;
+ }
+
+ return false;
+}
+
+bool Image11::isRenderableFormat() const
+{
+ return TextureStorage11::IsTextureFormatRenderable(mDXGIFormat);
+}
+
+DXGI_FORMAT Image11::getDXGIFormat() const
+{
+ // this should only happen if the image hasn't been redefined first
+ // which would be a bug by the caller
+ ASSERT(mDXGIFormat != DXGI_FORMAT_UNKNOWN);
+
+ return mDXGIFormat;
+}
+
+// Store the pixel rectangle designated by xoffset,yoffset,width,height with pixels stored as format/type at input
+// into the target pixel rectangle.
+void Image11::loadData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
+ GLint unpackAlignment, const void *input)
+{
+ D3D11_MAPPED_SUBRESOURCE mappedImage;
+ HRESULT result = map(&mappedImage);
+ if (FAILED(result))
+ {
+ ERR("Could not map image for loading.");
+ return;
+ }
+
+ GLsizei inputPitch = gl::ComputePitch(width, mInternalFormat, unpackAlignment);
+ size_t pixelSize = d3d11::ComputePixelSizeBits(mDXGIFormat) / 8;
+ void* offsetMappedData = (void*)((BYTE *)mappedImage.pData + (yoffset * mappedImage.RowPitch + xoffset * pixelSize));
+
+ switch (mInternalFormat)
+ {
+ case GL_ALPHA8_EXT:
+ loadAlphaDataToNative(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_LUMINANCE8_EXT:
+ loadLuminanceDataToNativeOrBGRA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData, false);
+ break;
+ case GL_ALPHA32F_EXT:
+ loadAlphaFloatDataToRGBA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_LUMINANCE32F_EXT:
+ loadLuminanceFloatDataToRGB(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_ALPHA16F_EXT:
+ loadAlphaHalfFloatDataToRGBA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_LUMINANCE16F_EXT:
+ loadLuminanceHalfFloatDataToRGBA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_LUMINANCE8_ALPHA8_EXT:
+ loadLuminanceAlphaDataToNativeOrBGRA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData, false);
+ break;
+ case GL_LUMINANCE_ALPHA32F_EXT:
+ loadLuminanceAlphaFloatDataToRGBA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_LUMINANCE_ALPHA16F_EXT:
+ loadLuminanceAlphaHalfFloatDataToRGBA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_RGB8_OES:
+ loadRGBUByteDataToRGBA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_RGB565:
+ loadRGB565DataToRGBA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_RGBA8_OES:
+ loadRGBAUByteDataToNative(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_RGBA4:
+ loadRGBA4444DataToRGBA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_RGB5_A1:
+ loadRGBA5551DataToRGBA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_BGRA8_EXT:
+ loadBGRADataToBGRA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_RGB32F_EXT:
+ loadRGBFloatDataToNative(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_RGB16F_EXT:
+ loadRGBHalfFloatDataToRGBA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_RGBA32F_EXT:
+ loadRGBAFloatDataToRGBA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ case GL_RGBA16F_EXT:
+ loadRGBAHalfFloatDataToRGBA(width, height, inputPitch, input, mappedImage.RowPitch, offsetMappedData);
+ break;
+ default: UNREACHABLE();
+ }
+
+ unmap();
+}
+
+void Image11::loadCompressedData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
+ const void *input)
+{
+ ASSERT(xoffset % 4 == 0);
+ ASSERT(yoffset % 4 == 0);
+
+ D3D11_MAPPED_SUBRESOURCE mappedImage;
+ HRESULT result = map(&mappedImage);
+ if (FAILED(result))
+ {
+ ERR("Could not map image for loading.");
+ return;
+ }
+
+ // Size computation assumes a 4x4 block compressed texture format
+ size_t blockSize = d3d11::ComputeBlockSizeBits(mDXGIFormat) / 8;
+ void* offsetMappedData = (void*)((BYTE *)mappedImage.pData + ((yoffset / 4) * mappedImage.RowPitch + (xoffset / 4) * blockSize));
+
+ GLsizei inputSize = gl::ComputeCompressedSize(width, height, mInternalFormat);
+ GLsizei inputPitch = gl::ComputeCompressedPitch(width, mInternalFormat);
+ int rows = inputSize / inputPitch;
+ for (int i = 0; i < rows; ++i)
+ {
+ memcpy((void*)((BYTE*)offsetMappedData + i * mappedImage.RowPitch), (void*)((BYTE*)input + i * inputPitch), inputPitch);
+ }
+
+ unmap();
+}
+
+void Image11::copy(GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height, gl::Framebuffer *source)
+{
+ gl::Renderbuffer *colorbuffer = source->getReadColorbuffer();
+
+ if (colorbuffer && colorbuffer->getActualFormat() == (GLuint)mActualFormat)
+ {
+ // No conversion needed-- use copyback fastpath
+ ID3D11Texture2D *colorBufferTexture = NULL;
+ unsigned int subresourceIndex = 0;
+
+ if (mRenderer->getRenderTargetResource(colorbuffer, &subresourceIndex, &colorBufferTexture))
+ {
+ D3D11_TEXTURE2D_DESC textureDesc;
+ colorBufferTexture->GetDesc(&textureDesc);
+
+ ID3D11Device *device = mRenderer->getDevice();
+ ID3D11DeviceContext *deviceContext = mRenderer->getDeviceContext();
+
+ ID3D11Texture2D* srcTex = NULL;
+ if (textureDesc.SampleDesc.Count > 1)
+ {
+ D3D11_TEXTURE2D_DESC resolveDesc;
+ resolveDesc.Width = textureDesc.Width;
+ resolveDesc.Height = textureDesc.Height;
+ resolveDesc.MipLevels = 1;
+ resolveDesc.ArraySize = 1;
+ resolveDesc.Format = textureDesc.Format;
+ resolveDesc.SampleDesc.Count = 1;
+ resolveDesc.SampleDesc.Quality = 0;
+ resolveDesc.Usage = D3D11_USAGE_DEFAULT;
+ resolveDesc.BindFlags = 0;
+ resolveDesc.CPUAccessFlags = 0;
+ resolveDesc.MiscFlags = 0;
+
+ HRESULT result = device->CreateTexture2D(&resolveDesc, NULL, &srcTex);
+ if (FAILED(result))
+ {
+ ERR("Failed to create resolve texture for Image11::copy, HRESULT: 0x%X.", result);
+ return;
+ }
+
+ deviceContext->ResolveSubresource(srcTex, 0, colorBufferTexture, subresourceIndex, textureDesc.Format);
+ subresourceIndex = 0;
+ }
+ else
+ {
+ srcTex = colorBufferTexture;
+ srcTex->AddRef();
+ }
+
+ D3D11_BOX srcBox;
+ srcBox.left = x;
+ srcBox.right = x + width;
+ srcBox.top = y;
+ srcBox.bottom = y + height;
+ srcBox.front = 0;
+ srcBox.back = 1;
+
+ deviceContext->CopySubresourceRegion(mStagingTexture, 0, xoffset, yoffset, 0, srcTex, subresourceIndex, &srcBox);
+
+ srcTex->Release();
+ colorBufferTexture->Release();
+ }
+ }
+ else
+ {
+ // This format requires conversion, so we must copy the texture to staging and manually convert via readPixels
+ D3D11_MAPPED_SUBRESOURCE mappedImage;
+ HRESULT result = map(&mappedImage);
+
+ // determine the offset coordinate into the destination buffer
+ GLsizei rowOffset = gl::ComputePixelSize(mActualFormat) * xoffset;
+ void *dataOffset = static_cast<unsigned char*>(mappedImage.pData) + mappedImage.RowPitch * yoffset + rowOffset;
+
+ mRenderer->readPixels(source, x, y, width, height, gl::ExtractFormat(mInternalFormat),
+ gl::ExtractType(mInternalFormat), mappedImage.RowPitch, false, 4, dataOffset);
+
+ unmap();
+ }
+}
+
+ID3D11Texture2D *Image11::getStagingTexture()
+{
+ createStagingTexture();
+
+ return mStagingTexture;
+}
+
+unsigned int Image11::getStagingSubresource()
+{
+ createStagingTexture();
+
+ return mStagingSubresource;
+}
+
+void Image11::createStagingTexture()
+{
+ if (mStagingTexture)
+ {
+ return;
+ }
+
+ ID3D11Texture2D *newTexture = NULL;
+ int lodOffset = 1;
+ const DXGI_FORMAT dxgiFormat = getDXGIFormat();
+ ASSERT(!d3d11::IsDepthStencilFormat(dxgiFormat)); // We should never get here for depth textures
+
+ if (mWidth != 0 && mHeight != 0)
+ {
+ GLsizei width = mWidth;
+ GLsizei height = mHeight;
+
+ // adjust size if needed for compressed textures
+ gl::MakeValidSize(false, d3d11::IsCompressed(dxgiFormat), &width, &height, &lodOffset);
+ ID3D11Device *device = mRenderer->getDevice();
+
+ D3D11_TEXTURE2D_DESC desc;
+ desc.Width = width;
+ desc.Height = height;
+ desc.MipLevels = lodOffset + 1;
+ desc.ArraySize = 1;
+ desc.Format = dxgiFormat;
+ desc.SampleDesc.Count = 1;
+ desc.SampleDesc.Quality = 0;
+ desc.Usage = D3D11_USAGE_STAGING;
+ desc.BindFlags = 0;
+ desc.CPUAccessFlags = D3D11_CPU_ACCESS_WRITE;
+ desc.MiscFlags = 0;
+
+ HRESULT result = device->CreateTexture2D(&desc, NULL, &newTexture);
+
+ if (FAILED(result))
+ {
+ ASSERT(result == E_OUTOFMEMORY);
+ ERR("Creating image failed.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ mStagingTexture = newTexture;
+ mStagingSubresource = D3D11CalcSubresource(lodOffset, 0, lodOffset + 1);
+ mDirty = false;
+}
+
+HRESULT Image11::map(D3D11_MAPPED_SUBRESOURCE *map)
+{
+ createStagingTexture();
+
+ HRESULT result = E_FAIL;
+
+ if (mStagingTexture)
+ {
+ ID3D11DeviceContext *deviceContext = mRenderer->getDeviceContext();
+ result = deviceContext->Map(mStagingTexture, mStagingSubresource, D3D11_MAP_WRITE, 0, map);
+
+ // this can fail if the device is removed (from TDR)
+ if (d3d11::isDeviceLostError(result))
+ {
+ mRenderer->notifyDeviceLost();
+ }
+ else if (SUCCEEDED(result))
+ {
+ mDirty = true;
+ }
+ }
+
+ return result;
+}
+
+void Image11::unmap()
+{
+ if (mStagingTexture)
+ {
+ ID3D11DeviceContext *deviceContext = mRenderer->getDeviceContext();
+ deviceContext->Unmap(mStagingTexture, mStagingSubresource);
+ }
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Image11.h b/src/3rdparty/angle/src/libGLESv2/renderer/Image11.h
new file mode 100644
index 0000000000..4d5f1c1780
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Image11.h
@@ -0,0 +1,76 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Image11.h: Defines the rx::Image11 class, which acts as the interface to
+// the actual underlying resources of a Texture
+
+#ifndef LIBGLESV2_RENDERER_IMAGE11_H_
+#define LIBGLESV2_RENDERER_IMAGE11_H_
+
+#include "libGLESv2/renderer/Image.h"
+
+#include "common/debug.h"
+
+namespace gl
+{
+class Framebuffer;
+}
+
+namespace rx
+{
+class Renderer;
+class Renderer11;
+class TextureStorageInterface2D;
+class TextureStorageInterfaceCube;
+
+class Image11 : public Image
+{
+ public:
+ Image11();
+ virtual ~Image11();
+
+ static Image11 *makeImage11(Image *img);
+
+ static void generateMipmap(Image11 *dest, Image11 *src);
+
+ virtual bool isDirty() const;
+
+ virtual bool updateSurface(TextureStorageInterface2D *storage, int level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height);
+ virtual bool updateSurface(TextureStorageInterfaceCube *storage, int face, int level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height);
+
+ virtual bool redefine(Renderer *renderer, GLint internalformat, GLsizei width, GLsizei height, bool forceRelease);
+
+ virtual bool isRenderableFormat() const;
+ DXGI_FORMAT getDXGIFormat() const;
+
+ virtual void loadData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
+ GLint unpackAlignment, const void *input);
+ virtual void loadCompressedData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
+ const void *input);
+
+ virtual void copy(GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height, gl::Framebuffer *source);
+
+ protected:
+ HRESULT map(D3D11_MAPPED_SUBRESOURCE *map);
+ void unmap();
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(Image11);
+
+ ID3D11Texture2D *getStagingTexture();
+ unsigned int getStagingSubresource();
+ void createStagingTexture();
+
+ Renderer11 *mRenderer;
+
+ DXGI_FORMAT mDXGIFormat;
+ ID3D11Texture2D *mStagingTexture;
+ unsigned int mStagingSubresource;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_IMAGE11_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Image9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Image9.cpp
new file mode 100644
index 0000000000..53030b7f1e
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Image9.cpp
@@ -0,0 +1,736 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Image9.cpp: Implements the rx::Image9 class, which acts as the interface to
+// the actual underlying surfaces of a Texture.
+
+#include "libGLESv2/renderer/Image9.h"
+
+#include "libGLESv2/main.h"
+#include "libGLESv2/Framebuffer.h"
+#include "libGLESv2/Renderbuffer.h"
+#include "libGLESv2/renderer/Renderer9.h"
+#include "libGLESv2/renderer/RenderTarget9.h"
+#include "libGLESv2/renderer/TextureStorage9.h"
+
+#include "libGLESv2/renderer/renderer9_utils.h"
+#include "libGLESv2/renderer/generatemip.h"
+
+namespace rx
+{
+
+Image9::Image9()
+{
+ mSurface = NULL;
+ mRenderer = NULL;
+
+ mD3DPool = D3DPOOL_SYSTEMMEM;
+ mD3DFormat = D3DFMT_UNKNOWN;
+}
+
+Image9::~Image9()
+{
+ if (mSurface)
+ {
+ mSurface->Release();
+ }
+}
+
+void Image9::generateMip(IDirect3DSurface9 *destSurface, IDirect3DSurface9 *sourceSurface)
+{
+ D3DSURFACE_DESC destDesc;
+ HRESULT result = destSurface->GetDesc(&destDesc);
+ ASSERT(SUCCEEDED(result));
+
+ D3DSURFACE_DESC sourceDesc;
+ result = sourceSurface->GetDesc(&sourceDesc);
+ ASSERT(SUCCEEDED(result));
+
+ ASSERT(sourceDesc.Format == destDesc.Format);
+ ASSERT(sourceDesc.Width == 1 || sourceDesc.Width / 2 == destDesc.Width);
+ ASSERT(sourceDesc.Height == 1 || sourceDesc.Height / 2 == destDesc.Height);
+
+ D3DLOCKED_RECT sourceLocked = {0};
+ result = sourceSurface->LockRect(&sourceLocked, NULL, D3DLOCK_READONLY);
+ ASSERT(SUCCEEDED(result));
+
+ D3DLOCKED_RECT destLocked = {0};
+ result = destSurface->LockRect(&destLocked, NULL, 0);
+ ASSERT(SUCCEEDED(result));
+
+ const unsigned char *sourceData = reinterpret_cast<const unsigned char*>(sourceLocked.pBits);
+ unsigned char *destData = reinterpret_cast<unsigned char*>(destLocked.pBits);
+
+ if (sourceData && destData)
+ {
+ switch (sourceDesc.Format)
+ {
+ case D3DFMT_L8:
+ GenerateMip<L8>(sourceDesc.Width, sourceDesc.Height, sourceData, sourceLocked.Pitch, destData, destLocked.Pitch);
+ break;
+ case D3DFMT_A8L8:
+ GenerateMip<A8L8>(sourceDesc.Width, sourceDesc.Height, sourceData, sourceLocked.Pitch, destData, destLocked.Pitch);
+ break;
+ case D3DFMT_A8R8G8B8:
+ case D3DFMT_X8R8G8B8:
+ GenerateMip<A8R8G8B8>(sourceDesc.Width, sourceDesc.Height, sourceData, sourceLocked.Pitch, destData, destLocked.Pitch);
+ break;
+ case D3DFMT_A16B16G16R16F:
+ GenerateMip<A16B16G16R16F>(sourceDesc.Width, sourceDesc.Height, sourceData, sourceLocked.Pitch, destData, destLocked.Pitch);
+ break;
+ case D3DFMT_A32B32G32R32F:
+ GenerateMip<A32B32G32R32F>(sourceDesc.Width, sourceDesc.Height, sourceData, sourceLocked.Pitch, destData, destLocked.Pitch);
+ break;
+ default:
+ UNREACHABLE();
+ break;
+ }
+
+ destSurface->UnlockRect();
+ sourceSurface->UnlockRect();
+ }
+}
+
+Image9 *Image9::makeImage9(Image *img)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(rx::Image9*, img));
+ return static_cast<rx::Image9*>(img);
+}
+
+void Image9::generateMipmap(Image9 *dest, Image9 *source)
+{
+ IDirect3DSurface9 *sourceSurface = source->getSurface();
+ if (sourceSurface == NULL)
+ return gl::error(GL_OUT_OF_MEMORY);
+
+ IDirect3DSurface9 *destSurface = dest->getSurface();
+ generateMip(destSurface, sourceSurface);
+
+ dest->markDirty();
+}
+
+void Image9::copyLockableSurfaces(IDirect3DSurface9 *dest, IDirect3DSurface9 *source)
+{
+ D3DLOCKED_RECT sourceLock = {0};
+ D3DLOCKED_RECT destLock = {0};
+
+ source->LockRect(&sourceLock, NULL, 0);
+ dest->LockRect(&destLock, NULL, 0);
+
+ if (sourceLock.pBits && destLock.pBits)
+ {
+ D3DSURFACE_DESC desc;
+ source->GetDesc(&desc);
+
+ int rows = d3d9::IsCompressedFormat(desc.Format) ? desc.Height / 4 : desc.Height;
+ int bytes = d3d9::ComputeRowSize(desc.Format, desc.Width);
+ ASSERT(bytes <= sourceLock.Pitch && bytes <= destLock.Pitch);
+
+ for(int i = 0; i < rows; i++)
+ {
+ memcpy((char*)destLock.pBits + destLock.Pitch * i, (char*)sourceLock.pBits + sourceLock.Pitch * i, bytes);
+ }
+
+ source->UnlockRect();
+ dest->UnlockRect();
+ }
+ else UNREACHABLE();
+}
+
+bool Image9::redefine(rx::Renderer *renderer, GLint internalformat, GLsizei width, GLsizei height, bool forceRelease)
+{
+ if (mWidth != width ||
+ mHeight != height ||
+ mInternalFormat != internalformat ||
+ forceRelease)
+ {
+ mRenderer = Renderer9::makeRenderer9(renderer);
+
+ mWidth = width;
+ mHeight = height;
+ mInternalFormat = internalformat;
+ // compute the d3d format that will be used
+ mD3DFormat = mRenderer->ConvertTextureInternalFormat(internalformat);
+ mActualFormat = d3d9_gl::GetEquivalentFormat(mD3DFormat);
+
+ if (mSurface)
+ {
+ mSurface->Release();
+ mSurface = NULL;
+ }
+
+ return true;
+ }
+
+ return false;
+}
+
+void Image9::createSurface()
+{
+ if(mSurface)
+ {
+ return;
+ }
+
+ IDirect3DTexture9 *newTexture = NULL;
+ IDirect3DSurface9 *newSurface = NULL;
+ const D3DPOOL poolToUse = D3DPOOL_SYSTEMMEM;
+ const D3DFORMAT d3dFormat = getD3DFormat();
+ ASSERT(d3dFormat != D3DFMT_INTZ); // We should never get here for depth textures
+
+ if (mWidth != 0 && mHeight != 0)
+ {
+ int levelToFetch = 0;
+ GLsizei requestWidth = mWidth;
+ GLsizei requestHeight = mHeight;
+ gl::MakeValidSize(true, gl::IsCompressed(mInternalFormat), &requestWidth, &requestHeight, &levelToFetch);
+
+ IDirect3DDevice9 *device = mRenderer->getDevice();
+
+ HRESULT result = device->CreateTexture(requestWidth, requestHeight, levelToFetch + 1, 0, d3dFormat,
+ poolToUse, &newTexture, NULL);
+
+ if (FAILED(result))
+ {
+ ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
+ ERR("Creating image surface failed.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ newTexture->GetSurfaceLevel(levelToFetch, &newSurface);
+ newTexture->Release();
+ }
+
+ mSurface = newSurface;
+ mDirty = false;
+ mD3DPool = poolToUse;
+}
+
+HRESULT Image9::lock(D3DLOCKED_RECT *lockedRect, const RECT *rect)
+{
+ createSurface();
+
+ HRESULT result = D3DERR_INVALIDCALL;
+
+ if (mSurface)
+ {
+ result = mSurface->LockRect(lockedRect, rect, 0);
+ ASSERT(SUCCEEDED(result));
+
+ mDirty = true;
+ }
+
+ return result;
+}
+
+void Image9::unlock()
+{
+ if (mSurface)
+ {
+ HRESULT result = mSurface->UnlockRect();
+ ASSERT(SUCCEEDED(result));
+ }
+}
+
+bool Image9::isRenderableFormat() const
+{
+ return TextureStorage9::IsTextureFormatRenderable(getD3DFormat());
+}
+
+D3DFORMAT Image9::getD3DFormat() const
+{
+ // this should only happen if the image hasn't been redefined first
+ // which would be a bug by the caller
+ ASSERT(mD3DFormat != D3DFMT_UNKNOWN);
+
+ return mD3DFormat;
+}
+
+IDirect3DSurface9 *Image9::getSurface()
+{
+ createSurface();
+
+ return mSurface;
+}
+
+void Image9::setManagedSurface(TextureStorageInterface2D *storage, int level)
+{
+ TextureStorage9_2D *storage9 = TextureStorage9_2D::makeTextureStorage9_2D(storage->getStorageInstance());
+ setManagedSurface(storage9->getSurfaceLevel(level, false));
+}
+
+void Image9::setManagedSurface(TextureStorageInterfaceCube *storage, int face, int level)
+{
+ TextureStorage9_Cube *storage9 = TextureStorage9_Cube::makeTextureStorage9_Cube(storage->getStorageInstance());
+ setManagedSurface(storage9->getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, level, false));
+}
+
+void Image9::setManagedSurface(IDirect3DSurface9 *surface)
+{
+ D3DSURFACE_DESC desc;
+ surface->GetDesc(&desc);
+ ASSERT(desc.Pool == D3DPOOL_MANAGED);
+
+ if ((GLsizei)desc.Width == mWidth && (GLsizei)desc.Height == mHeight)
+ {
+ if (mSurface)
+ {
+ copyLockableSurfaces(surface, mSurface);
+ mSurface->Release();
+ }
+
+ mSurface = surface;
+ mD3DPool = desc.Pool;
+ }
+}
+
+bool Image9::updateSurface(TextureStorageInterface2D *storage, int level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height)
+{
+ ASSERT(getSurface() != NULL);
+ TextureStorage9_2D *storage9 = TextureStorage9_2D::makeTextureStorage9_2D(storage->getStorageInstance());
+ return updateSurface(storage9->getSurfaceLevel(level, true), xoffset, yoffset, width, height);
+}
+
+bool Image9::updateSurface(TextureStorageInterfaceCube *storage, int face, int level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height)
+{
+ ASSERT(getSurface() != NULL);
+ TextureStorage9_Cube *storage9 = TextureStorage9_Cube::makeTextureStorage9_Cube(storage->getStorageInstance());
+ return updateSurface(storage9->getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, level, true), xoffset, yoffset, width, height);
+}
+
+bool Image9::updateSurface(IDirect3DSurface9 *destSurface, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height)
+{
+ if (!destSurface)
+ return false;
+
+ IDirect3DSurface9 *sourceSurface = getSurface();
+
+ if (sourceSurface && sourceSurface != destSurface)
+ {
+ RECT rect;
+ rect.left = xoffset;
+ rect.top = yoffset;
+ rect.right = xoffset + width;
+ rect.bottom = yoffset + height;
+
+ POINT point = {rect.left, rect.top};
+
+ IDirect3DDevice9 *device = mRenderer->getDevice();
+
+ if (mD3DPool == D3DPOOL_MANAGED)
+ {
+ D3DSURFACE_DESC desc;
+ sourceSurface->GetDesc(&desc);
+
+ IDirect3DSurface9 *surf = 0;
+ HRESULT result = device->CreateOffscreenPlainSurface(desc.Width, desc.Height, desc.Format, D3DPOOL_SYSTEMMEM, &surf, NULL);
+
+ if (SUCCEEDED(result))
+ {
+ copyLockableSurfaces(surf, sourceSurface);
+ result = device->UpdateSurface(surf, &rect, destSurface, &point);
+ ASSERT(SUCCEEDED(result));
+ surf->Release();
+ }
+ }
+ else
+ {
+ // UpdateSurface: source must be SYSTEMMEM, dest must be DEFAULT pools
+ HRESULT result = device->UpdateSurface(sourceSurface, &rect, destSurface, &point);
+ ASSERT(SUCCEEDED(result));
+ }
+ }
+
+ destSurface->Release();
+ return true;
+}
+
+// Store the pixel rectangle designated by xoffset,yoffset,width,height with pixels stored as format/type at input
+// into the target pixel rectangle.
+void Image9::loadData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
+ GLint unpackAlignment, const void *input)
+{
+ RECT lockRect =
+ {
+ xoffset, yoffset,
+ xoffset + width, yoffset + height
+ };
+
+ D3DLOCKED_RECT locked;
+ HRESULT result = lock(&locked, &lockRect);
+ if (FAILED(result))
+ {
+ return;
+ }
+
+
+ GLsizei inputPitch = gl::ComputePitch(width, mInternalFormat, unpackAlignment);
+
+ switch (mInternalFormat)
+ {
+ case GL_ALPHA8_EXT:
+#if defined(__SSE2__)
+ if (gl::supportsSSE2())
+ {
+ loadAlphaDataToBGRASSE2(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ }
+ else
+#endif
+ {
+ loadAlphaDataToBGRA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ }
+ break;
+ case GL_LUMINANCE8_EXT:
+ loadLuminanceDataToNativeOrBGRA(width, height, inputPitch, input, locked.Pitch, locked.pBits, getD3DFormat() == D3DFMT_L8);
+ break;
+ case GL_ALPHA32F_EXT:
+ loadAlphaFloatDataToRGBA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_LUMINANCE32F_EXT:
+ loadLuminanceFloatDataToRGBA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_ALPHA16F_EXT:
+ loadAlphaHalfFloatDataToRGBA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_LUMINANCE16F_EXT:
+ loadLuminanceHalfFloatDataToRGBA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_LUMINANCE8_ALPHA8_EXT:
+ loadLuminanceAlphaDataToNativeOrBGRA(width, height, inputPitch, input, locked.Pitch, locked.pBits, getD3DFormat() == D3DFMT_A8L8);
+ break;
+ case GL_LUMINANCE_ALPHA32F_EXT:
+ loadLuminanceAlphaFloatDataToRGBA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_LUMINANCE_ALPHA16F_EXT:
+ loadLuminanceAlphaHalfFloatDataToRGBA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_RGB8_OES:
+ loadRGBUByteDataToBGRX(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_RGB565:
+ loadRGB565DataToBGRA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_RGBA8_OES:
+#if defined(__SSE2__)
+ if (gl::supportsSSE2())
+ {
+ loadRGBAUByteDataToBGRASSE2(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ }
+ else
+#endif
+ {
+ loadRGBAUByteDataToBGRA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ }
+ break;
+ case GL_RGBA4:
+ loadRGBA4444DataToBGRA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_RGB5_A1:
+ loadRGBA5551DataToBGRA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_BGRA8_EXT:
+ loadBGRADataToBGRA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ // float textures are converted to RGBA, not BGRA, as they're stored that way in D3D
+ case GL_RGB32F_EXT:
+ loadRGBFloatDataToRGBA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_RGB16F_EXT:
+ loadRGBHalfFloatDataToRGBA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_RGBA32F_EXT:
+ loadRGBAFloatDataToRGBA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ case GL_RGBA16F_EXT:
+ loadRGBAHalfFloatDataToRGBA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ break;
+ default: UNREACHABLE();
+ }
+
+ unlock();
+}
+
+void Image9::loadCompressedData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
+ const void *input)
+{
+ ASSERT(xoffset % 4 == 0);
+ ASSERT(yoffset % 4 == 0);
+
+ RECT lockRect = {
+ xoffset, yoffset,
+ xoffset + width, yoffset + height
+ };
+
+ D3DLOCKED_RECT locked;
+ HRESULT result = lock(&locked, &lockRect);
+ if (FAILED(result))
+ {
+ return;
+ }
+
+ GLsizei inputSize = gl::ComputeCompressedSize(width, height, mInternalFormat);
+ GLsizei inputPitch = gl::ComputeCompressedPitch(width, mInternalFormat);
+ int rows = inputSize / inputPitch;
+ for (int i = 0; i < rows; ++i)
+ {
+ memcpy((void*)((BYTE*)locked.pBits + i * locked.Pitch), (void*)((BYTE*)input + i * inputPitch), inputPitch);
+ }
+
+ unlock();
+}
+
+// This implements glCopyTex[Sub]Image2D for non-renderable internal texture formats and incomplete textures
+void Image9::copy(GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height, gl::Framebuffer *source)
+{
+ RenderTarget9 *renderTarget = NULL;
+ IDirect3DSurface9 *surface = NULL;
+ gl::Renderbuffer *colorbuffer = source->getColorbuffer(0);
+
+ if (colorbuffer)
+ {
+ renderTarget = RenderTarget9::makeRenderTarget9(colorbuffer->getRenderTarget());
+ }
+
+ if (renderTarget)
+ {
+ surface = renderTarget->getSurface();
+ }
+
+ if (!surface)
+ {
+ ERR("Failed to retrieve the render target.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ IDirect3DDevice9 *device = mRenderer->getDevice();
+
+ IDirect3DSurface9 *renderTargetData = NULL;
+ D3DSURFACE_DESC description;
+ surface->GetDesc(&description);
+
+ HRESULT result = device->CreateOffscreenPlainSurface(description.Width, description.Height, description.Format, D3DPOOL_SYSTEMMEM, &renderTargetData, NULL);
+
+ if (FAILED(result))
+ {
+ ERR("Could not create matching destination surface.");
+ surface->Release();
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ result = device->GetRenderTargetData(surface, renderTargetData);
+
+ if (FAILED(result))
+ {
+ ERR("GetRenderTargetData unexpectedly failed.");
+ renderTargetData->Release();
+ surface->Release();
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ RECT sourceRect = {x, y, x + width, y + height};
+ RECT destRect = {xoffset, yoffset, xoffset + width, yoffset + height};
+
+ D3DLOCKED_RECT sourceLock = {0};
+ result = renderTargetData->LockRect(&sourceLock, &sourceRect, 0);
+
+ if (FAILED(result))
+ {
+ ERR("Failed to lock the source surface (rectangle might be invalid).");
+ renderTargetData->Release();
+ surface->Release();
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ D3DLOCKED_RECT destLock = {0};
+ result = lock(&destLock, &destRect);
+
+ if (FAILED(result))
+ {
+ ERR("Failed to lock the destination surface (rectangle might be invalid).");
+ renderTargetData->UnlockRect();
+ renderTargetData->Release();
+ surface->Release();
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ if (destLock.pBits && sourceLock.pBits)
+ {
+ unsigned char *source = (unsigned char*)sourceLock.pBits;
+ unsigned char *dest = (unsigned char*)destLock.pBits;
+
+ switch (description.Format)
+ {
+ case D3DFMT_X8R8G8B8:
+ case D3DFMT_A8R8G8B8:
+ switch(getD3DFormat())
+ {
+ case D3DFMT_X8R8G8B8:
+ case D3DFMT_A8R8G8B8:
+ for(int y = 0; y < height; y++)
+ {
+ memcpy(dest, source, 4 * width);
+
+ source += sourceLock.Pitch;
+ dest += destLock.Pitch;
+ }
+ break;
+ case D3DFMT_L8:
+ for(int y = 0; y < height; y++)
+ {
+ for(int x = 0; x < width; x++)
+ {
+ dest[x] = source[x * 4 + 2];
+ }
+
+ source += sourceLock.Pitch;
+ dest += destLock.Pitch;
+ }
+ break;
+ case D3DFMT_A8L8:
+ for(int y = 0; y < height; y++)
+ {
+ for(int x = 0; x < width; x++)
+ {
+ dest[x * 2 + 0] = source[x * 4 + 2];
+ dest[x * 2 + 1] = source[x * 4 + 3];
+ }
+
+ source += sourceLock.Pitch;
+ dest += destLock.Pitch;
+ }
+ break;
+ default:
+ UNREACHABLE();
+ }
+ break;
+ case D3DFMT_R5G6B5:
+ switch(getD3DFormat())
+ {
+ case D3DFMT_X8R8G8B8:
+ for(int y = 0; y < height; y++)
+ {
+ for(int x = 0; x < width; x++)
+ {
+ unsigned short rgb = ((unsigned short*)source)[x];
+ unsigned char red = (rgb & 0xF800) >> 8;
+ unsigned char green = (rgb & 0x07E0) >> 3;
+ unsigned char blue = (rgb & 0x001F) << 3;
+ dest[x + 0] = blue | (blue >> 5);
+ dest[x + 1] = green | (green >> 6);
+ dest[x + 2] = red | (red >> 5);
+ dest[x + 3] = 0xFF;
+ }
+
+ source += sourceLock.Pitch;
+ dest += destLock.Pitch;
+ }
+ break;
+ case D3DFMT_L8:
+ for(int y = 0; y < height; y++)
+ {
+ for(int x = 0; x < width; x++)
+ {
+ unsigned char red = source[x * 2 + 1] & 0xF8;
+ dest[x] = red | (red >> 5);
+ }
+
+ source += sourceLock.Pitch;
+ dest += destLock.Pitch;
+ }
+ break;
+ default:
+ UNREACHABLE();
+ }
+ break;
+ case D3DFMT_A1R5G5B5:
+ switch(getD3DFormat())
+ {
+ case D3DFMT_X8R8G8B8:
+ for(int y = 0; y < height; y++)
+ {
+ for(int x = 0; x < width; x++)
+ {
+ unsigned short argb = ((unsigned short*)source)[x];
+ unsigned char red = (argb & 0x7C00) >> 7;
+ unsigned char green = (argb & 0x03E0) >> 2;
+ unsigned char blue = (argb & 0x001F) << 3;
+ dest[x + 0] = blue | (blue >> 5);
+ dest[x + 1] = green | (green >> 5);
+ dest[x + 2] = red | (red >> 5);
+ dest[x + 3] = 0xFF;
+ }
+
+ source += sourceLock.Pitch;
+ dest += destLock.Pitch;
+ }
+ break;
+ case D3DFMT_A8R8G8B8:
+ for(int y = 0; y < height; y++)
+ {
+ for(int x = 0; x < width; x++)
+ {
+ unsigned short argb = ((unsigned short*)source)[x];
+ unsigned char red = (argb & 0x7C00) >> 7;
+ unsigned char green = (argb & 0x03E0) >> 2;
+ unsigned char blue = (argb & 0x001F) << 3;
+ unsigned char alpha = (signed short)argb >> 15;
+ dest[x + 0] = blue | (blue >> 5);
+ dest[x + 1] = green | (green >> 5);
+ dest[x + 2] = red | (red >> 5);
+ dest[x + 3] = alpha;
+ }
+
+ source += sourceLock.Pitch;
+ dest += destLock.Pitch;
+ }
+ break;
+ case D3DFMT_L8:
+ for(int y = 0; y < height; y++)
+ {
+ for(int x = 0; x < width; x++)
+ {
+ unsigned char red = source[x * 2 + 1] & 0x7C;
+ dest[x] = (red << 1) | (red >> 4);
+ }
+
+ source += sourceLock.Pitch;
+ dest += destLock.Pitch;
+ }
+ break;
+ case D3DFMT_A8L8:
+ for(int y = 0; y < height; y++)
+ {
+ for(int x = 0; x < width; x++)
+ {
+ unsigned char red = source[x * 2 + 1] & 0x7C;
+ dest[x * 2 + 0] = (red << 1) | (red >> 4);
+ dest[x * 2 + 1] = (signed char)source[x * 2 + 1] >> 7;
+ }
+
+ source += sourceLock.Pitch;
+ dest += destLock.Pitch;
+ }
+ break;
+ default:
+ UNREACHABLE();
+ }
+ break;
+ default:
+ UNREACHABLE();
+ }
+ }
+
+ unlock();
+ renderTargetData->UnlockRect();
+
+ renderTargetData->Release();
+ surface->Release();
+
+ mDirty = true;
+}
+
+} \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Image9.h b/src/3rdparty/angle/src/libGLESv2/renderer/Image9.h
new file mode 100644
index 0000000000..2fbbca3124
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Image9.h
@@ -0,0 +1,79 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Image9.h: Defines the rx::Image9 class, which acts as the interface to
+// the actual underlying surfaces of a Texture.
+
+#ifndef LIBGLESV2_RENDERER_IMAGE9_H_
+#define LIBGLESV2_RENDERER_IMAGE9_H_
+
+#include "libGLESv2/renderer/Image.h"
+#include "common/debug.h"
+
+namespace gl
+{
+class Framebuffer;
+}
+
+namespace rx
+{
+class Renderer;
+class Renderer9;
+class TextureStorageInterface2D;
+class TextureStorageInterfaceCube;
+
+class Image9 : public Image
+{
+ public:
+ Image9();
+ ~Image9();
+
+ static Image9 *makeImage9(Image *img);
+
+ static void generateMipmap(Image9 *dest, Image9 *source);
+ static void generateMip(IDirect3DSurface9 *destSurface, IDirect3DSurface9 *sourceSurface);
+ static void copyLockableSurfaces(IDirect3DSurface9 *dest, IDirect3DSurface9 *source);
+
+ virtual bool redefine(Renderer *renderer, GLint internalformat, GLsizei width, GLsizei height, bool forceRelease);
+
+ virtual bool isRenderableFormat() const;
+ D3DFORMAT getD3DFormat() const;
+
+ virtual bool isDirty() const {return mSurface && mDirty;}
+ IDirect3DSurface9 *getSurface();
+
+ virtual void setManagedSurface(TextureStorageInterface2D *storage, int level);
+ virtual void setManagedSurface(TextureStorageInterfaceCube *storage, int face, int level);
+ virtual bool updateSurface(TextureStorageInterface2D *storage, int level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height);
+ virtual bool updateSurface(TextureStorageInterfaceCube *storage, int face, int level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height);
+
+ virtual void loadData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
+ GLint unpackAlignment, const void *input);
+ virtual void loadCompressedData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height,
+ const void *input);
+
+ virtual void copy(GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height, gl::Framebuffer *source);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(Image9);
+
+ void createSurface();
+ void setManagedSurface(IDirect3DSurface9 *surface);
+ bool updateSurface(IDirect3DSurface9 *dest, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height);
+
+ HRESULT lock(D3DLOCKED_RECT *lockedRect, const RECT *rect);
+ void unlock();
+
+ Renderer9 *mRenderer;
+
+ D3DPOOL mD3DPool; // can only be D3DPOOL_SYSTEMMEM or D3DPOOL_MANAGED since it needs to be lockable.
+ D3DFORMAT mD3DFormat;
+
+ IDirect3DSurface9 *mSurface;
+};
+}
+
+#endif // LIBGLESV2_RENDERER_IMAGE9_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/TextureSSE2.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/ImageSSE2.cpp
index 48ea6643bc..b2a90ca961 100644
--- a/src/3rdparty/angle/src/libGLESv2/TextureSSE2.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/ImageSSE2.cpp
@@ -1,22 +1,22 @@
+#include "precompiled.h"
//
-// Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
-// TextureSSE2.cpp: Implements SSE2-based functions of gl::Image class. It's
+// ImageSSE2.cpp: Implements SSE2-based functions of rx::Image class. It's
// in a separated file for GCC, which can enable SSE usage only per-file,
// not for code blocks that use SSE2 explicitly.
#include "libGLESv2/Texture.h"
+#include "libGLESv2/renderer/Image.h"
-#include <intrin.h>
-
-namespace gl
+namespace rx
{
-void Image::loadRGBAUByteDataSSE2(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
+void Image::loadRGBAUByteDataToBGRASSE2(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
{
const unsigned int *source = NULL;
unsigned int *dest = NULL;
@@ -57,8 +57,8 @@ void Image::loadRGBAUByteDataSSE2(GLsizei width, GLsizei height,
}
}
-void Image::loadAlphaDataSSE2(GLsizei width, GLsizei height,
- int inputPitch, const void *input, size_t outputPitch, void *output) const
+void Image::loadAlphaDataToBGRASSE2(GLsizei width, GLsizei height,
+ int inputPitch, const void *input, size_t outputPitch, void *output)
{
const unsigned char *source = NULL;
unsigned int *dest = NULL;
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer.cpp
new file mode 100644
index 0000000000..16fd782315
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer.cpp
@@ -0,0 +1,202 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// IndexBuffer.cpp: Defines the abstract IndexBuffer class and IndexBufferInterface
+// class with derivations, classes that perform graphics API agnostic index buffer operations.
+
+#include "libGLESv2/renderer/IndexBuffer.h"
+#include "libGLESv2/renderer/Renderer.h"
+
+namespace rx
+{
+
+unsigned int IndexBuffer::mNextSerial = 1;
+
+IndexBuffer::IndexBuffer()
+{
+ updateSerial();
+}
+
+IndexBuffer::~IndexBuffer()
+{
+}
+
+unsigned int IndexBuffer::getSerial() const
+{
+ return mSerial;
+}
+
+void IndexBuffer::updateSerial()
+{
+ mSerial = mNextSerial++;
+}
+
+
+IndexBufferInterface::IndexBufferInterface(Renderer *renderer, bool dynamic) : mRenderer(renderer)
+{
+ mIndexBuffer = renderer->createIndexBuffer();
+
+ mDynamic = dynamic;
+ mWritePosition = 0;
+}
+
+IndexBufferInterface::~IndexBufferInterface()
+{
+ if (mIndexBuffer)
+ {
+ delete mIndexBuffer;
+ }
+}
+
+GLenum IndexBufferInterface::getIndexType() const
+{
+ return mIndexBuffer->getIndexType();
+}
+
+unsigned int IndexBufferInterface::getBufferSize() const
+{
+ return mIndexBuffer->getBufferSize();
+}
+
+unsigned int IndexBufferInterface::getSerial() const
+{
+ return mIndexBuffer->getSerial();
+}
+
+int IndexBufferInterface::mapBuffer(unsigned int size, void** outMappedMemory)
+{
+ if (!mIndexBuffer->mapBuffer(mWritePosition, size, outMappedMemory))
+ {
+ *outMappedMemory = NULL;
+ return -1;
+ }
+
+ int oldWritePos = static_cast<int>(mWritePosition);
+ mWritePosition += size;
+
+ return oldWritePos;
+}
+
+bool IndexBufferInterface::unmapBuffer()
+{
+ return mIndexBuffer->unmapBuffer();
+}
+
+IndexBuffer * IndexBufferInterface::getIndexBuffer() const
+{
+ return mIndexBuffer;
+}
+
+unsigned int IndexBufferInterface::getWritePosition() const
+{
+ return mWritePosition;
+}
+
+void IndexBufferInterface::setWritePosition(unsigned int writePosition)
+{
+ mWritePosition = writePosition;
+}
+
+bool IndexBufferInterface::discard()
+{
+ return mIndexBuffer->discard();
+}
+
+bool IndexBufferInterface::setBufferSize(unsigned int bufferSize, GLenum indexType)
+{
+ if (mIndexBuffer->getBufferSize() == 0)
+ {
+ return mIndexBuffer->initialize(bufferSize, indexType, mDynamic);
+ }
+ else
+ {
+ return mIndexBuffer->setSize(bufferSize, indexType);
+ }
+}
+
+StreamingIndexBufferInterface::StreamingIndexBufferInterface(Renderer *renderer) : IndexBufferInterface(renderer, true)
+{
+}
+
+StreamingIndexBufferInterface::~StreamingIndexBufferInterface()
+{
+}
+
+bool StreamingIndexBufferInterface::reserveBufferSpace(unsigned int size, GLenum indexType)
+{
+ bool result = true;
+ unsigned int curBufferSize = getBufferSize();
+ if (size > curBufferSize)
+ {
+ result = setBufferSize(std::max(size, 2 * curBufferSize), indexType);
+ setWritePosition(0);
+ }
+ else if (getWritePosition() + size > curBufferSize)
+ {
+ if (!discard())
+ {
+ return false;
+ }
+ setWritePosition(0);
+ }
+
+ return result;
+}
+
+
+StaticIndexBufferInterface::StaticIndexBufferInterface(Renderer *renderer) : IndexBufferInterface(renderer, false)
+{
+}
+
+StaticIndexBufferInterface::~StaticIndexBufferInterface()
+{
+}
+
+bool StaticIndexBufferInterface::reserveBufferSpace(unsigned int size, GLenum indexType)
+{
+ unsigned int curSize = getBufferSize();
+ if (curSize == 0)
+ {
+ return setBufferSize(size, indexType);
+ }
+ else if (curSize >= size && indexType == getIndexType())
+ {
+ return true;
+ }
+ else
+ {
+ ERR("Static index buffers can't be resized");
+ UNREACHABLE();
+ return false;
+ }
+}
+
+unsigned int StaticIndexBufferInterface::lookupRange(intptr_t offset, GLsizei count, unsigned int *minIndex, unsigned int *maxIndex)
+{
+ IndexRange range = {offset, count};
+
+ std::map<IndexRange, IndexResult>::iterator res = mCache.find(range);
+
+ if (res == mCache.end())
+ {
+ return -1;
+ }
+
+ *minIndex = res->second.minIndex;
+ *maxIndex = res->second.maxIndex;
+ return res->second.streamOffset;
+}
+
+void StaticIndexBufferInterface::addRange(intptr_t offset, GLsizei count, unsigned int minIndex, unsigned int maxIndex, unsigned int streamOffset)
+{
+ IndexRange indexRange = {offset, count};
+ IndexResult indexResult = {minIndex, maxIndex, streamOffset};
+ mCache[indexRange] = indexResult;
+}
+
+}
+
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer.h b/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer.h
new file mode 100644
index 0000000000..1afbd626fa
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer.h
@@ -0,0 +1,137 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// IndexBuffer.h: Defines the abstract IndexBuffer class and IndexBufferInterface
+// class with derivations, classes that perform graphics API agnostic index buffer operations.
+
+#ifndef LIBGLESV2_RENDERER_INDEXBUFFER_H_
+#define LIBGLESV2_RENDERER_INDEXBUFFER_H_
+
+#include "common/angleutils.h"
+
+namespace rx
+{
+class Renderer;
+
+class IndexBuffer
+{
+ public:
+ IndexBuffer();
+ virtual ~IndexBuffer();
+
+ virtual bool initialize(unsigned int bufferSize, GLenum indexType, bool dynamic) = 0;
+
+ virtual bool mapBuffer(unsigned int offset, unsigned int size, void** outMappedMemory) = 0;
+ virtual bool unmapBuffer() = 0;
+
+ virtual bool discard() = 0;
+
+ virtual GLenum getIndexType() const = 0;
+ virtual unsigned int getBufferSize() const = 0;
+ virtual bool setSize(unsigned int bufferSize, GLenum indexType) = 0;
+
+ unsigned int getSerial() const;
+
+ protected:
+ void updateSerial();
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(IndexBuffer);
+
+ unsigned int mSerial;
+ static unsigned int mNextSerial;
+};
+
+class IndexBufferInterface
+{
+ public:
+ IndexBufferInterface(Renderer *renderer, bool dynamic);
+ virtual ~IndexBufferInterface();
+
+ virtual bool reserveBufferSpace(unsigned int size, GLenum indexType) = 0;
+
+ GLenum getIndexType() const;
+ unsigned int getBufferSize() const;
+
+ unsigned int getSerial() const;
+
+ int mapBuffer(unsigned int size, void** outMappedMemory);
+ bool unmapBuffer();
+
+ IndexBuffer *getIndexBuffer() const;
+
+ protected:
+ unsigned int getWritePosition() const;
+ void setWritePosition(unsigned int writePosition);
+
+ bool discard();
+
+ bool setBufferSize(unsigned int bufferSize, GLenum indexType);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(IndexBufferInterface);
+
+ rx::Renderer *const mRenderer;
+
+ IndexBuffer* mIndexBuffer;
+
+ unsigned int mWritePosition;
+ bool mDynamic;
+};
+
+class StreamingIndexBufferInterface : public IndexBufferInterface
+{
+ public:
+ StreamingIndexBufferInterface(Renderer *renderer);
+ ~StreamingIndexBufferInterface();
+
+ virtual bool reserveBufferSpace(unsigned int size, GLenum indexType);
+};
+
+class StaticIndexBufferInterface : public IndexBufferInterface
+{
+ public:
+ explicit StaticIndexBufferInterface(Renderer *renderer);
+ ~StaticIndexBufferInterface();
+
+ virtual bool reserveBufferSpace(unsigned int size, GLenum indexType);
+
+ unsigned int lookupRange(intptr_t offset, GLsizei count, unsigned int *minIndex, unsigned int *maxIndex); // Returns the offset into the index buffer, or -1 if not found
+ void addRange(intptr_t offset, GLsizei count, unsigned int minIndex, unsigned int maxIndex, unsigned int streamOffset);
+
+ private:
+ struct IndexRange
+ {
+ intptr_t offset;
+ GLsizei count;
+
+ bool operator<(const IndexRange& rhs) const
+ {
+ if (offset != rhs.offset)
+ {
+ return offset < rhs.offset;
+ }
+ if (count != rhs.count)
+ {
+ return count < rhs.count;
+ }
+ return false;
+ }
+ };
+
+ struct IndexResult
+ {
+ unsigned int minIndex;
+ unsigned int maxIndex;
+ unsigned int streamOffset;
+ };
+
+ std::map<IndexRange, IndexResult> mCache;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_INDEXBUFFER_H_ \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer11.cpp
new file mode 100644
index 0000000000..2a442ecd1a
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer11.cpp
@@ -0,0 +1,182 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// IndexBuffer11.cpp: Defines the D3D11 IndexBuffer implementation.
+
+#include "libGLESv2/renderer/IndexBuffer11.h"
+#include "libGLESv2/renderer/Renderer11.h"
+
+namespace rx
+{
+
+IndexBuffer11::IndexBuffer11(Renderer11 *const renderer) : mRenderer(renderer)
+{
+ mBuffer = NULL;
+ mBufferSize = 0;
+ mDynamicUsage = false;
+}
+
+IndexBuffer11::~IndexBuffer11()
+{
+ if (mBuffer)
+ {
+ mBuffer->Release();
+ mBuffer = NULL;
+ }
+}
+
+bool IndexBuffer11::initialize(unsigned int bufferSize, GLenum indexType, bool dynamic)
+{
+ if (mBuffer)
+ {
+ mBuffer->Release();
+ mBuffer = NULL;
+ }
+
+ updateSerial();
+
+ if (bufferSize > 0)
+ {
+ ID3D11Device* dxDevice = mRenderer->getDevice();
+
+ D3D11_BUFFER_DESC bufferDesc;
+ bufferDesc.ByteWidth = bufferSize;
+ bufferDesc.Usage = D3D11_USAGE_DYNAMIC;
+ bufferDesc.BindFlags = D3D11_BIND_INDEX_BUFFER;
+ bufferDesc.CPUAccessFlags = D3D11_CPU_ACCESS_WRITE;
+ bufferDesc.MiscFlags = 0;
+ bufferDesc.StructureByteStride = 0;
+
+ HRESULT result = dxDevice->CreateBuffer(&bufferDesc, NULL, &mBuffer);
+ if (FAILED(result))
+ {
+ return false;
+ }
+ }
+
+ mBufferSize = bufferSize;
+ mIndexType = indexType;
+ mDynamicUsage = dynamic;
+
+ return true;
+}
+
+IndexBuffer11 *IndexBuffer11::makeIndexBuffer11(IndexBuffer *indexBuffer)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(IndexBuffer11*, indexBuffer));
+ return static_cast<IndexBuffer11*>(indexBuffer);
+}
+
+bool IndexBuffer11::mapBuffer(unsigned int offset, unsigned int size, void** outMappedMemory)
+{
+ if (mBuffer)
+ {
+ if (offset + size > mBufferSize)
+ {
+ ERR("Index buffer map range is not inside the buffer.");
+ return false;
+ }
+
+ ID3D11DeviceContext *dxContext = mRenderer->getDeviceContext();
+
+ D3D11_MAPPED_SUBRESOURCE mappedResource;
+ HRESULT result = dxContext->Map(mBuffer, 0, D3D11_MAP_WRITE_NO_OVERWRITE, 0, &mappedResource);
+ if (FAILED(result))
+ {
+ ERR("Index buffer map failed with error 0x%08x", result);
+ return false;
+ }
+
+ *outMappedMemory = reinterpret_cast<char*>(mappedResource.pData) + offset;
+ return true;
+ }
+ else
+ {
+ ERR("Index buffer not initialized.");
+ return false;
+ }
+}
+
+bool IndexBuffer11::unmapBuffer()
+{
+ if (mBuffer)
+ {
+ ID3D11DeviceContext *dxContext = mRenderer->getDeviceContext();
+ dxContext->Unmap(mBuffer, 0);
+ return true;
+ }
+ else
+ {
+ ERR("Index buffer not initialized.");
+ return false;
+ }
+}
+
+GLenum IndexBuffer11::getIndexType() const
+{
+ return mIndexType;
+}
+
+unsigned int IndexBuffer11::getBufferSize() const
+{
+ return mBufferSize;
+}
+
+bool IndexBuffer11::setSize(unsigned int bufferSize, GLenum indexType)
+{
+ if (bufferSize > mBufferSize || indexType != mIndexType)
+ {
+ return initialize(bufferSize, indexType, mDynamicUsage);
+ }
+ else
+ {
+ return true;
+ }
+}
+
+bool IndexBuffer11::discard()
+{
+ if (mBuffer)
+ {
+ ID3D11DeviceContext *dxContext = mRenderer->getDeviceContext();
+
+ D3D11_MAPPED_SUBRESOURCE mappedResource;
+ HRESULT result = dxContext->Map(mBuffer, 0, D3D11_MAP_WRITE_DISCARD, 0, &mappedResource);
+ if (FAILED(result))
+ {
+ ERR("Index buffer map failed with error 0x%08x", result);
+ return false;
+ }
+
+ dxContext->Unmap(mBuffer, 0);
+
+ return true;
+ }
+ else
+ {
+ ERR("Index buffer not initialized.");
+ return false;
+ }
+}
+
+DXGI_FORMAT IndexBuffer11::getIndexFormat() const
+{
+ switch (mIndexType)
+ {
+ case GL_UNSIGNED_BYTE: return DXGI_FORMAT_R16_UINT;
+ case GL_UNSIGNED_SHORT: return DXGI_FORMAT_R16_UINT;
+ case GL_UNSIGNED_INT: return DXGI_FORMAT_R32_UINT;
+ default: UNREACHABLE(); return DXGI_FORMAT_UNKNOWN;
+ }
+}
+
+ID3D11Buffer *IndexBuffer11::getBuffer() const
+{
+ return mBuffer;
+}
+
+} \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer11.h b/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer11.h
new file mode 100644
index 0000000000..39a61946ad
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer11.h
@@ -0,0 +1,53 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// IndexBuffer11.h: Defines the D3D11 IndexBuffer implementation.
+
+#ifndef LIBGLESV2_RENDERER_INDEXBUFFER11_H_
+#define LIBGLESV2_RENDERER_INDEXBUFFER11_H_
+
+#include "libGLESv2/renderer/IndexBuffer.h"
+
+namespace rx
+{
+class Renderer11;
+
+class IndexBuffer11 : public IndexBuffer
+{
+ public:
+ explicit IndexBuffer11(Renderer11 *const renderer);
+ virtual ~IndexBuffer11();
+
+ virtual bool initialize(unsigned int bufferSize, GLenum indexType, bool dynamic);
+
+ static IndexBuffer11 *makeIndexBuffer11(IndexBuffer *indexBuffer);
+
+ virtual bool mapBuffer(unsigned int offset, unsigned int size, void** outMappedMemory);
+ virtual bool unmapBuffer();
+
+ virtual GLenum getIndexType() const;
+ virtual unsigned int getBufferSize() const;
+ virtual bool setSize(unsigned int bufferSize, GLenum indexType);
+
+ virtual bool discard();
+
+ DXGI_FORMAT getIndexFormat() const;
+ ID3D11Buffer *getBuffer() const;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(IndexBuffer11);
+
+ rx::Renderer11 *const mRenderer;
+
+ ID3D11Buffer *mBuffer;
+ unsigned int mBufferSize;
+ GLenum mIndexType;
+ bool mDynamicUsage;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_INDEXBUFFER11_H_ \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer9.cpp
new file mode 100644
index 0000000000..c6d83c5dca
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer9.cpp
@@ -0,0 +1,207 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Indexffer9.cpp: Defines the D3D9 IndexBuffer implementation.
+
+#include "libGLESv2/renderer/IndexBuffer9.h"
+#include "libGLESv2/renderer/Renderer9.h"
+
+namespace rx
+{
+
+IndexBuffer9::IndexBuffer9(Renderer9 *const renderer) : mRenderer(renderer)
+{
+ mIndexBuffer = NULL;
+ mBufferSize = 0;
+ mIndexType = 0;
+ mDynamic = false;
+}
+
+IndexBuffer9::~IndexBuffer9()
+{
+ if (mIndexBuffer)
+ {
+ mIndexBuffer->Release();
+ mIndexBuffer = NULL;
+ }
+}
+
+bool IndexBuffer9::initialize(unsigned int bufferSize, GLenum indexType, bool dynamic)
+{
+ if (mIndexBuffer)
+ {
+ mIndexBuffer->Release();
+ mIndexBuffer = NULL;
+ }
+
+ updateSerial();
+
+ if (bufferSize > 0)
+ {
+ D3DFORMAT format;
+ if (indexType == GL_UNSIGNED_SHORT || indexType == GL_UNSIGNED_BYTE)
+ {
+ format = D3DFMT_INDEX16;
+ }
+ else if (indexType == GL_UNSIGNED_INT)
+ {
+ if (mRenderer->get32BitIndexSupport())
+ {
+ format = D3DFMT_INDEX32;
+ }
+ else
+ {
+ ERR("Attempted to create a 32-bit index buffer but renderer does not support 32-bit indices.");
+ return false;
+ }
+ }
+ else
+ {
+ ERR("Invalid index type %u.", indexType);
+ return false;
+ }
+
+ DWORD usageFlags = D3DUSAGE_WRITEONLY;
+ if (dynamic)
+ {
+ usageFlags |= D3DUSAGE_DYNAMIC;
+ }
+
+ HRESULT result = mRenderer->createIndexBuffer(bufferSize, usageFlags, format, &mIndexBuffer);
+ if (FAILED(result))
+ {
+ ERR("Failed to create an index buffer of size %u, result: 0x%08x.", mBufferSize, result);
+ return false;
+ }
+ }
+
+ mBufferSize = bufferSize;
+ mIndexType = indexType;
+ mDynamic = dynamic;
+
+ return true;
+}
+
+IndexBuffer9 *IndexBuffer9::makeIndexBuffer9(IndexBuffer *indexBuffer)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(IndexBuffer9*, indexBuffer));
+ return static_cast<IndexBuffer9*>(indexBuffer);
+}
+
+bool IndexBuffer9::mapBuffer(unsigned int offset, unsigned int size, void** outMappedMemory)
+{
+ if (mIndexBuffer)
+ {
+ DWORD lockFlags = mDynamic ? D3DLOCK_NOOVERWRITE : 0;
+
+ void *mapPtr = NULL;
+ HRESULT result = mIndexBuffer->Lock(offset, size, &mapPtr, lockFlags);
+ if (FAILED(result))
+ {
+ ERR("Index buffer lock failed with error 0x%08x", result);
+ return false;
+ }
+
+ *outMappedMemory = mapPtr;
+ return true;
+ }
+ else
+ {
+ ERR("Index buffer not initialized.");
+ return false;
+ }
+}
+
+bool IndexBuffer9::unmapBuffer()
+{
+ if (mIndexBuffer)
+ {
+ HRESULT result = mIndexBuffer->Unlock();
+ if (FAILED(result))
+ {
+ ERR("Index buffer unlock failed with error 0x%08x", result);
+ return false;
+ }
+
+ return true;
+ }
+ else
+ {
+ ERR("Index buffer not initialized.");
+ return false;
+ }
+}
+
+GLenum IndexBuffer9::getIndexType() const
+{
+ return mIndexType;
+}
+
+unsigned int IndexBuffer9::getBufferSize() const
+{
+ return mBufferSize;
+}
+
+bool IndexBuffer9::setSize(unsigned int bufferSize, GLenum indexType)
+{
+ if (bufferSize > mBufferSize || indexType != mIndexType)
+ {
+ return initialize(bufferSize, indexType, mDynamic);
+ }
+ else
+ {
+ return true;
+ }
+}
+
+bool IndexBuffer9::discard()
+{
+ if (mIndexBuffer)
+ {
+ void *dummy;
+ HRESULT result;
+
+ result = mIndexBuffer->Lock(0, 1, &dummy, D3DLOCK_DISCARD);
+ if (FAILED(result))
+ {
+ ERR("Discard lock failed with error 0x%08x", result);
+ return false;
+ }
+
+ result = mIndexBuffer->Unlock();
+ if (FAILED(result))
+ {
+ ERR("Discard unlock failed with error 0x%08x", result);
+ return false;
+ }
+
+ return true;
+ }
+ else
+ {
+ ERR("Index buffer not initialized.");
+ return false;
+ }
+}
+
+D3DFORMAT IndexBuffer9::getIndexFormat() const
+{
+ switch (mIndexType)
+ {
+ case GL_UNSIGNED_BYTE: return D3DFMT_INDEX16;
+ case GL_UNSIGNED_SHORT: return D3DFMT_INDEX16;
+ case GL_UNSIGNED_INT: return D3DFMT_INDEX32;
+ default: UNREACHABLE(); return D3DFMT_UNKNOWN;
+ }
+}
+
+IDirect3DIndexBuffer9 * IndexBuffer9::getBuffer() const
+{
+ return mIndexBuffer;
+}
+
+} \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer9.h b/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer9.h
new file mode 100644
index 0000000000..6801867532
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/IndexBuffer9.h
@@ -0,0 +1,53 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Indexffer9.h: Defines the D3D9 IndexBuffer implementation.
+
+#ifndef LIBGLESV2_RENDERER_INDEXBUFFER9_H_
+#define LIBGLESV2_RENDERER_INDEXBUFFER9_H_
+
+#include "libGLESv2/renderer/IndexBuffer.h"
+
+namespace rx
+{
+class Renderer9;
+
+class IndexBuffer9 : public IndexBuffer
+{
+ public:
+ explicit IndexBuffer9(Renderer9 *const renderer);
+ virtual ~IndexBuffer9();
+
+ virtual bool initialize(unsigned int bufferSize, GLenum indexType, bool dynamic);
+
+ static IndexBuffer9 *makeIndexBuffer9(IndexBuffer *indexBuffer);
+
+ virtual bool mapBuffer(unsigned int offset, unsigned int size, void** outMappedMemory);
+ virtual bool unmapBuffer();
+
+ virtual GLenum getIndexType() const;
+ virtual unsigned int getBufferSize() const;
+ virtual bool setSize(unsigned int bufferSize, GLenum indexType);
+
+ virtual bool discard();
+
+ D3DFORMAT getIndexFormat() const;
+ IDirect3DIndexBuffer9 *getBuffer() const;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(IndexBuffer9);
+
+ rx::Renderer9 *const mRenderer;
+
+ IDirect3DIndexBuffer9 *mIndexBuffer;
+ unsigned int mBufferSize;
+ GLenum mIndexType;
+ bool mDynamic;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_INDEXBUFFER9_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/IndexDataManager.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/IndexDataManager.cpp
new file mode 100644
index 0000000000..84b79b4109
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/IndexDataManager.cpp
@@ -0,0 +1,316 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// IndexDataManager.cpp: Defines the IndexDataManager, a class that
+// runs the Buffer translation process for index buffers.
+
+#include "libGLESv2/renderer/IndexDataManager.h"
+#include "libGLESv2/renderer/BufferStorage.h"
+
+#include "libGLESv2/Buffer.h"
+#include "libGLESv2/main.h"
+#include "libGLESv2/renderer/IndexBuffer.h"
+
+namespace rx
+{
+
+IndexDataManager::IndexDataManager(Renderer *renderer) : mRenderer(renderer)
+{
+ mStreamingBufferShort = new StreamingIndexBufferInterface(mRenderer);
+ if (!mStreamingBufferShort->reserveBufferSpace(INITIAL_INDEX_BUFFER_SIZE, GL_UNSIGNED_SHORT))
+ {
+ delete mStreamingBufferShort;
+ mStreamingBufferShort = NULL;
+ }
+
+ mStreamingBufferInt = new StreamingIndexBufferInterface(mRenderer);
+ if (!mStreamingBufferInt->reserveBufferSpace(INITIAL_INDEX_BUFFER_SIZE, GL_UNSIGNED_INT))
+ {
+ delete mStreamingBufferInt;
+ mStreamingBufferInt = NULL;
+ }
+
+ if (!mStreamingBufferShort)
+ {
+ // Make sure both buffers are deleted.
+ delete mStreamingBufferInt;
+ mStreamingBufferInt = NULL;
+
+ ERR("Failed to allocate the streaming index buffer(s).");
+ }
+
+ mCountingBuffer = NULL;
+}
+
+IndexDataManager::~IndexDataManager()
+{
+ delete mStreamingBufferShort;
+ delete mStreamingBufferInt;
+ delete mCountingBuffer;
+}
+
+static unsigned int indexTypeSize(GLenum type)
+{
+ switch (type)
+ {
+ case GL_UNSIGNED_INT: return sizeof(GLuint);
+ case GL_UNSIGNED_SHORT: return sizeof(GLushort);
+ case GL_UNSIGNED_BYTE: return sizeof(GLubyte);
+ default: UNREACHABLE(); return sizeof(GLushort);
+ }
+}
+
+static void convertIndices(GLenum type, const void *input, GLsizei count, void *output)
+{
+ if (type == GL_UNSIGNED_BYTE)
+ {
+ const GLubyte *in = static_cast<const GLubyte*>(input);
+ GLushort *out = static_cast<GLushort*>(output);
+
+ for (GLsizei i = 0; i < count; i++)
+ {
+ out[i] = in[i];
+ }
+ }
+ else if (type == GL_UNSIGNED_INT)
+ {
+ memcpy(output, input, count * sizeof(GLuint));
+ }
+ else if (type == GL_UNSIGNED_SHORT)
+ {
+ memcpy(output, input, count * sizeof(GLushort));
+ }
+ else UNREACHABLE();
+}
+
+template <class IndexType>
+static void computeRange(const IndexType *indices, GLsizei count, GLuint *minIndex, GLuint *maxIndex)
+{
+ *minIndex = indices[0];
+ *maxIndex = indices[0];
+
+ for (GLsizei i = 0; i < count; i++)
+ {
+ if (*minIndex > indices[i]) *minIndex = indices[i];
+ if (*maxIndex < indices[i]) *maxIndex = indices[i];
+ }
+}
+
+static void computeRange(GLenum type, const GLvoid *indices, GLsizei count, GLuint *minIndex, GLuint *maxIndex)
+{
+ if (type == GL_UNSIGNED_BYTE)
+ {
+ computeRange(static_cast<const GLubyte*>(indices), count, minIndex, maxIndex);
+ }
+ else if (type == GL_UNSIGNED_INT)
+ {
+ computeRange(static_cast<const GLuint*>(indices), count, minIndex, maxIndex);
+ }
+ else if (type == GL_UNSIGNED_SHORT)
+ {
+ computeRange(static_cast<const GLushort*>(indices), count, minIndex, maxIndex);
+ }
+ else UNREACHABLE();
+}
+
+GLenum IndexDataManager::prepareIndexData(GLenum type, GLsizei count, gl::Buffer *buffer, const GLvoid *indices, TranslatedIndexData *translated)
+{
+ if (!mStreamingBufferShort)
+ {
+ return GL_OUT_OF_MEMORY;
+ }
+
+ GLenum destinationIndexType = (type == GL_UNSIGNED_INT) ? GL_UNSIGNED_INT : GL_UNSIGNED_SHORT;
+ intptr_t offset = reinterpret_cast<intptr_t>(indices);
+ bool alignedOffset = false;
+
+ BufferStorage *storage = NULL;
+
+ if (buffer != NULL)
+ {
+ storage = buffer->getStorage();
+
+ switch (type)
+ {
+ case GL_UNSIGNED_BYTE: alignedOffset = (offset % sizeof(GLubyte) == 0); break;
+ case GL_UNSIGNED_SHORT: alignedOffset = (offset % sizeof(GLushort) == 0); break;
+ case GL_UNSIGNED_INT: alignedOffset = (offset % sizeof(GLuint) == 0); break;
+ default: UNREACHABLE(); alignedOffset = false;
+ }
+
+ if (indexTypeSize(type) * count + offset > storage->getSize())
+ {
+ return GL_INVALID_OPERATION;
+ }
+
+ indices = static_cast<const GLubyte*>(storage->getData()) + offset;
+ }
+
+ StreamingIndexBufferInterface *streamingBuffer = (type == GL_UNSIGNED_INT) ? mStreamingBufferInt : mStreamingBufferShort;
+
+ StaticIndexBufferInterface *staticBuffer = buffer ? buffer->getStaticIndexBuffer() : NULL;
+ IndexBufferInterface *indexBuffer = streamingBuffer;
+ bool directStorage = alignedOffset && storage && storage->supportsDirectBinding() &&
+ destinationIndexType == type;
+ UINT streamOffset = 0;
+
+ if (directStorage)
+ {
+ indexBuffer = streamingBuffer;
+ streamOffset = offset;
+ storage->markBufferUsage();
+ computeRange(type, indices, count, &translated->minIndex, &translated->maxIndex);
+ }
+ else if (staticBuffer && staticBuffer->getBufferSize() != 0 && staticBuffer->getIndexType() == type && alignedOffset)
+ {
+ indexBuffer = staticBuffer;
+ streamOffset = staticBuffer->lookupRange(offset, count, &translated->minIndex, &translated->maxIndex);
+
+ if (streamOffset == -1)
+ {
+ streamOffset = (offset / indexTypeSize(type)) * indexTypeSize(destinationIndexType);
+ computeRange(type, indices, count, &translated->minIndex, &translated->maxIndex);
+ staticBuffer->addRange(offset, count, translated->minIndex, translated->maxIndex, streamOffset);
+ }
+ }
+ else
+ {
+ int convertCount = count;
+
+ if (staticBuffer)
+ {
+ if (staticBuffer->getBufferSize() == 0 && alignedOffset)
+ {
+ indexBuffer = staticBuffer;
+ convertCount = storage->getSize() / indexTypeSize(type);
+ }
+ else
+ {
+ buffer->invalidateStaticData();
+ staticBuffer = NULL;
+ }
+ }
+
+ if (!indexBuffer)
+ {
+ ERR("No valid index buffer.");
+ return GL_INVALID_OPERATION;
+ }
+
+ unsigned int bufferSizeRequired = convertCount * indexTypeSize(destinationIndexType);
+ indexBuffer->reserveBufferSpace(bufferSizeRequired, type);
+
+ void* output = NULL;
+ streamOffset = indexBuffer->mapBuffer(bufferSizeRequired, &output);
+ if (streamOffset == -1 || output == NULL)
+ {
+ ERR("Failed to map index buffer.");
+ return GL_OUT_OF_MEMORY;
+ }
+
+ convertIndices(type, staticBuffer ? storage->getData() : indices, convertCount, output);
+
+ if (!indexBuffer->unmapBuffer())
+ {
+ ERR("Failed to unmap index buffer.");
+ return GL_OUT_OF_MEMORY;
+ }
+
+ computeRange(type, indices, count, &translated->minIndex, &translated->maxIndex);
+
+ if (staticBuffer)
+ {
+ streamOffset = (offset / indexTypeSize(type)) * indexTypeSize(destinationIndexType);
+ staticBuffer->addRange(offset, count, translated->minIndex, translated->maxIndex, streamOffset);
+ }
+ }
+
+ translated->storage = directStorage ? storage : NULL;
+ translated->indexBuffer = indexBuffer->getIndexBuffer();
+ translated->serial = directStorage ? storage->getSerial() : indexBuffer->getSerial();
+ translated->startIndex = streamOffset / indexTypeSize(destinationIndexType);
+ translated->startOffset = streamOffset;
+
+ if (buffer)
+ {
+ buffer->promoteStaticUsage(count * indexTypeSize(type));
+ }
+
+ return GL_NO_ERROR;
+}
+
+StaticIndexBufferInterface *IndexDataManager::getCountingIndices(GLsizei count)
+{
+ if (count <= 65536) // 16-bit indices
+ {
+ const unsigned int spaceNeeded = count * sizeof(unsigned short);
+
+ if (!mCountingBuffer || mCountingBuffer->getBufferSize() < spaceNeeded)
+ {
+ delete mCountingBuffer;
+ mCountingBuffer = new StaticIndexBufferInterface(mRenderer);
+ mCountingBuffer->reserveBufferSpace(spaceNeeded, GL_UNSIGNED_SHORT);
+
+ void* mappedMemory = NULL;
+ if (mCountingBuffer->mapBuffer(spaceNeeded, &mappedMemory) == -1 || mappedMemory == NULL)
+ {
+ ERR("Failed to map counting buffer.");
+ return NULL;
+ }
+
+ unsigned short *data = reinterpret_cast<unsigned short*>(mappedMemory);
+ for(int i = 0; i < count; i++)
+ {
+ data[i] = i;
+ }
+
+ if (!mCountingBuffer->unmapBuffer())
+ {
+ ERR("Failed to unmap counting buffer.");
+ return NULL;
+ }
+ }
+ }
+ else if (mStreamingBufferInt) // 32-bit indices supported
+ {
+ const unsigned int spaceNeeded = count * sizeof(unsigned int);
+
+ if (!mCountingBuffer || mCountingBuffer->getBufferSize() < spaceNeeded)
+ {
+ delete mCountingBuffer;
+ mCountingBuffer = new StaticIndexBufferInterface(mRenderer);
+ mCountingBuffer->reserveBufferSpace(spaceNeeded, GL_UNSIGNED_INT);
+
+ void* mappedMemory = NULL;
+ if (mCountingBuffer->mapBuffer(spaceNeeded, &mappedMemory) == -1 || mappedMemory == NULL)
+ {
+ ERR("Failed to map counting buffer.");
+ return NULL;
+ }
+
+ unsigned int *data = reinterpret_cast<unsigned int*>(mappedMemory);
+ for(int i = 0; i < count; i++)
+ {
+ data[i] = i;
+ }
+
+ if (!mCountingBuffer->unmapBuffer())
+ {
+ ERR("Failed to unmap counting buffer.");
+ return NULL;
+ }
+ }
+ }
+ else
+ {
+ return NULL;
+ }
+
+ return mCountingBuffer;
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/IndexDataManager.h b/src/3rdparty/angle/src/libGLESv2/renderer/IndexDataManager.h
new file mode 100644
index 0000000000..0e77c81d1b
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/IndexDataManager.h
@@ -0,0 +1,66 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// IndexDataManager.h: Defines the IndexDataManager, a class that
+// runs the Buffer translation process for index buffers.
+
+#ifndef LIBGLESV2_INDEXDATAMANAGER_H_
+#define LIBGLESV2_INDEXDATAMANAGER_H_
+
+#include "common/angleutils.h"
+
+namespace
+{
+ enum { INITIAL_INDEX_BUFFER_SIZE = 4096 * sizeof(GLuint) };
+}
+
+namespace gl
+{
+class Buffer;
+}
+
+namespace rx
+{
+class StaticIndexBufferInterface;
+class StreamingIndexBufferInterface;
+class IndexBuffer;
+class BufferStorage;
+class Renderer;
+
+struct TranslatedIndexData
+{
+ unsigned int minIndex;
+ unsigned int maxIndex;
+ unsigned int startIndex;
+ unsigned int startOffset; // In bytes
+
+ IndexBuffer *indexBuffer;
+ BufferStorage *storage;
+ unsigned int serial;
+};
+
+class IndexDataManager
+{
+ public:
+ explicit IndexDataManager(Renderer *renderer);
+ virtual ~IndexDataManager();
+
+ GLenum prepareIndexData(GLenum type, GLsizei count, gl::Buffer *arrayElementBuffer, const GLvoid *indices, TranslatedIndexData *translated);
+ StaticIndexBufferInterface *getCountingIndices(GLsizei count);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(IndexDataManager);
+
+ Renderer *const mRenderer;
+
+ StreamingIndexBufferInterface *mStreamingBufferShort;
+ StreamingIndexBufferInterface *mStreamingBufferInt;
+ StaticIndexBufferInterface *mCountingBuffer;
+};
+
+}
+
+#endif // LIBGLESV2_INDEXDATAMANAGER_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/InputLayoutCache.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/InputLayoutCache.cpp
new file mode 100644
index 0000000000..0402bb35ac
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/InputLayoutCache.cpp
@@ -0,0 +1,166 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// InputLayoutCache.cpp: Defines InputLayoutCache, a class that builds and caches
+// D3D11 input layouts.
+
+#include "libGLESv2/renderer/InputLayoutCache.h"
+#include "libGLESv2/renderer/VertexBuffer11.h"
+#include "libGLESv2/renderer/BufferStorage11.h"
+#include "libGLESv2/renderer/ShaderExecutable11.h"
+#include "libGLESv2/ProgramBinary.h"
+#include "libGLESv2/Context.h"
+#include "libGLESv2/renderer/VertexDataManager.h"
+
+#include "third_party/murmurhash/MurmurHash3.h"
+
+namespace rx
+{
+
+const unsigned int InputLayoutCache::kMaxInputLayouts = 1024;
+
+InputLayoutCache::InputLayoutCache() : mInputLayoutMap(kMaxInputLayouts, hashInputLayout, compareInputLayouts)
+{
+ mCounter = 0;
+ mDevice = NULL;
+ mDeviceContext = NULL;
+}
+
+InputLayoutCache::~InputLayoutCache()
+{
+ clear();
+}
+
+void InputLayoutCache::initialize(ID3D11Device *device, ID3D11DeviceContext *context)
+{
+ clear();
+ mDevice = device;
+ mDeviceContext = context;
+}
+
+void InputLayoutCache::clear()
+{
+ for (InputLayoutMap::iterator i = mInputLayoutMap.begin(); i != mInputLayoutMap.end(); i++)
+ {
+ i->second.inputLayout->Release();
+ }
+ mInputLayoutMap.clear();
+}
+
+GLenum InputLayoutCache::applyVertexBuffers(TranslatedAttribute attributes[gl::MAX_VERTEX_ATTRIBS],
+ gl::ProgramBinary *programBinary)
+{
+ int sortedSemanticIndices[gl::MAX_VERTEX_ATTRIBS];
+ programBinary->sortAttributesByLayout(attributes, sortedSemanticIndices);
+
+ if (!mDevice || !mDeviceContext)
+ {
+ ERR("InputLayoutCache is not initialized.");
+ return GL_INVALID_OPERATION;
+ }
+
+ InputLayoutKey ilKey = { 0 };
+
+ ID3D11Buffer *vertexBuffers[gl::MAX_VERTEX_ATTRIBS] = { NULL };
+ UINT vertexStrides[gl::MAX_VERTEX_ATTRIBS] = { 0 };
+ UINT vertexOffsets[gl::MAX_VERTEX_ATTRIBS] = { 0 };
+
+ static const char* semanticName = "TEXCOORD";
+
+ for (unsigned int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ if (attributes[i].active)
+ {
+ VertexBuffer11 *vertexBuffer = VertexBuffer11::makeVertexBuffer11(attributes[i].vertexBuffer);
+ BufferStorage11 *bufferStorage = attributes[i].storage ? BufferStorage11::makeBufferStorage11(attributes[i].storage) : NULL;
+
+ D3D11_INPUT_CLASSIFICATION inputClass = attributes[i].divisor > 0 ? D3D11_INPUT_PER_INSTANCE_DATA : D3D11_INPUT_PER_VERTEX_DATA;
+
+ // Record the type of the associated vertex shader vector in our key
+ // This will prevent mismatched vertex shaders from using the same input layout
+ GLint attributeSize;
+ programBinary->getActiveAttribute(ilKey.elementCount, 0, NULL, &attributeSize, &ilKey.glslElementType[ilKey.elementCount], NULL);
+
+ ilKey.elements[ilKey.elementCount].SemanticName = semanticName;
+ ilKey.elements[ilKey.elementCount].SemanticIndex = sortedSemanticIndices[i];
+ ilKey.elements[ilKey.elementCount].Format = attributes[i].attribute->mArrayEnabled ? vertexBuffer->getDXGIFormat(*attributes[i].attribute) : DXGI_FORMAT_R32G32B32A32_FLOAT;
+ ilKey.elements[ilKey.elementCount].InputSlot = i;
+ ilKey.elements[ilKey.elementCount].AlignedByteOffset = 0;
+ ilKey.elements[ilKey.elementCount].InputSlotClass = inputClass;
+ ilKey.elements[ilKey.elementCount].InstanceDataStepRate = attributes[i].divisor;
+ ilKey.elementCount++;
+
+ vertexBuffers[i] = bufferStorage ? bufferStorage->getBuffer() : vertexBuffer->getBuffer();
+ vertexStrides[i] = attributes[i].stride;
+ vertexOffsets[i] = attributes[i].offset;
+ }
+ }
+
+ ID3D11InputLayout *inputLayout = NULL;
+
+ InputLayoutMap::iterator i = mInputLayoutMap.find(ilKey);
+ if (i != mInputLayoutMap.end())
+ {
+ inputLayout = i->second.inputLayout;
+ i->second.lastUsedTime = mCounter++;
+ }
+ else
+ {
+ ShaderExecutable11 *shader = ShaderExecutable11::makeShaderExecutable11(programBinary->getVertexExecutable());
+
+ HRESULT result = mDevice->CreateInputLayout(ilKey.elements, ilKey.elementCount, shader->getFunction(), shader->getLength(), &inputLayout);
+ if (FAILED(result))
+ {
+ ERR("Failed to crate input layout, result: 0x%08x", result);
+ return GL_INVALID_OPERATION;
+ }
+
+ if (mInputLayoutMap.size() >= kMaxInputLayouts)
+ {
+ TRACE("Overflowed the limit of %u input layouts, removing the least recently used "
+ "to make room.", kMaxInputLayouts);
+
+ InputLayoutMap::iterator leastRecentlyUsed = mInputLayoutMap.begin();
+ for (InputLayoutMap::iterator i = mInputLayoutMap.begin(); i != mInputLayoutMap.end(); i++)
+ {
+ if (i->second.lastUsedTime < leastRecentlyUsed->second.lastUsedTime)
+ {
+ leastRecentlyUsed = i;
+ }
+ }
+ leastRecentlyUsed->second.inputLayout->Release();
+ mInputLayoutMap.erase(leastRecentlyUsed);
+ }
+
+ InputLayoutCounterPair inputCounterPair;
+ inputCounterPair.inputLayout = inputLayout;
+ inputCounterPair.lastUsedTime = mCounter++;
+
+ mInputLayoutMap.insert(std::make_pair(ilKey, inputCounterPair));
+ }
+
+ mDeviceContext->IASetInputLayout(inputLayout);
+ mDeviceContext->IASetVertexBuffers(0, gl::MAX_VERTEX_ATTRIBS, vertexBuffers, vertexStrides, vertexOffsets);
+
+ return GL_NO_ERROR;
+}
+
+std::size_t InputLayoutCache::hashInputLayout(const InputLayoutKey &inputLayout)
+{
+ static const unsigned int seed = 0xDEADBEEF;
+
+ std::size_t hash = 0;
+ MurmurHash3_x86_32(&inputLayout, sizeof(InputLayoutKey), seed, &hash);
+ return hash;
+}
+
+bool InputLayoutCache::compareInputLayouts(const InputLayoutKey &a, const InputLayoutKey &b)
+{
+ return memcmp(&a, &b, sizeof(InputLayoutKey)) == 0;
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/InputLayoutCache.h b/src/3rdparty/angle/src/libGLESv2/renderer/InputLayoutCache.h
new file mode 100644
index 0000000000..d95f39fae4
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/InputLayoutCache.h
@@ -0,0 +1,74 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// InputLayoutCache.h: Defines InputLayoutCache, a class that builds and caches
+// D3D11 input layouts.
+
+#ifndef LIBGLESV2_RENDERER_INPUTLAYOUTCACHE_H_
+#define LIBGLESV2_RENDERER_INPUTLAYOUTCACHE_H_
+
+#include "libGLESv2/Constants.h"
+#include "common/angleutils.h"
+
+namespace gl
+{
+class ProgramBinary;
+}
+
+namespace rx
+{
+struct TranslatedAttribute;
+
+class InputLayoutCache
+{
+ public:
+ InputLayoutCache();
+ virtual ~InputLayoutCache();
+
+ void initialize(ID3D11Device *device, ID3D11DeviceContext *context);
+ void clear();
+
+ GLenum applyVertexBuffers(TranslatedAttribute attributes[gl::MAX_VERTEX_ATTRIBS],
+ gl::ProgramBinary *programBinary);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(InputLayoutCache);
+
+ struct InputLayoutKey
+ {
+ unsigned int elementCount;
+ D3D11_INPUT_ELEMENT_DESC elements[gl::MAX_VERTEX_ATTRIBS];
+ GLenum glslElementType[gl::MAX_VERTEX_ATTRIBS];
+ };
+
+ struct InputLayoutCounterPair
+ {
+ ID3D11InputLayout *inputLayout;
+ unsigned long long lastUsedTime;
+ };
+
+ static std::size_t hashInputLayout(const InputLayoutKey &inputLayout);
+ static bool compareInputLayouts(const InputLayoutKey &a, const InputLayoutKey &b);
+
+ typedef std::size_t (*InputLayoutHashFunction)(const InputLayoutKey &);
+ typedef bool (*InputLayoutEqualityFunction)(const InputLayoutKey &, const InputLayoutKey &);
+ typedef std::unordered_map<InputLayoutKey,
+ InputLayoutCounterPair,
+ InputLayoutHashFunction,
+ InputLayoutEqualityFunction> InputLayoutMap;
+ InputLayoutMap mInputLayoutMap;
+
+ static const unsigned int kMaxInputLayouts;
+
+ unsigned long long mCounter;
+
+ ID3D11Device *mDevice;
+ ID3D11DeviceContext *mDeviceContext;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_INPUTLAYOUTCACHE_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Query11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Query11.cpp
new file mode 100644
index 0000000000..13210fc929
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Query11.cpp
@@ -0,0 +1,122 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Query11.cpp: Defines the rx::Query11 class which implements rx::QueryImpl.
+
+#include "libGLESv2/renderer/Query11.h"
+#include "libGLESv2/renderer/Renderer11.h"
+#include "libGLESv2/main.h"
+
+namespace rx
+{
+
+Query11::Query11(rx::Renderer11 *renderer, GLenum type) : QueryImpl(type)
+{
+ mRenderer = renderer;
+ mQuery = NULL;
+}
+
+Query11::~Query11()
+{
+ if (mQuery)
+ {
+ mQuery->Release();
+ mQuery = NULL;
+ }
+}
+
+void Query11::begin()
+{
+ if (mQuery == NULL)
+ {
+ D3D11_QUERY_DESC queryDesc;
+ queryDesc.Query = D3D11_QUERY_OCCLUSION;
+ queryDesc.MiscFlags = 0;
+
+ if (FAILED(mRenderer->getDevice()->CreateQuery(&queryDesc, &mQuery)))
+ {
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ mRenderer->getDeviceContext()->Begin(mQuery);
+}
+
+void Query11::end()
+{
+ if (mQuery == NULL)
+ {
+ return gl::error(GL_INVALID_OPERATION);
+ }
+
+ mRenderer->getDeviceContext()->End(mQuery);
+
+ mStatus = GL_FALSE;
+ mResult = GL_FALSE;
+}
+
+GLuint Query11::getResult()
+{
+ if (mQuery != NULL)
+ {
+ while (!testQuery())
+ {
+ Sleep(0);
+ // explicitly check for device loss, some drivers seem to return S_FALSE
+ // if the device is lost
+ if (mRenderer->testDeviceLost(true))
+ {
+ return gl::error(GL_OUT_OF_MEMORY, 0);
+ }
+ }
+ }
+
+ return mResult;
+}
+
+GLboolean Query11::isResultAvailable()
+{
+ if (mQuery != NULL)
+ {
+ testQuery();
+ }
+
+ return mStatus;
+}
+
+GLboolean Query11::testQuery()
+{
+ if (mQuery != NULL && mStatus != GL_TRUE)
+ {
+ UINT64 numPixels = 0;
+ HRESULT result = mRenderer->getDeviceContext()->GetData(mQuery, &numPixels, sizeof(UINT64), 0);
+ if (result == S_OK)
+ {
+ mStatus = GL_TRUE;
+
+ switch (getType())
+ {
+ case GL_ANY_SAMPLES_PASSED_EXT:
+ case GL_ANY_SAMPLES_PASSED_CONSERVATIVE_EXT:
+ mResult = (numPixels > 0) ? GL_TRUE : GL_FALSE;
+ break;
+ default:
+ UNREACHABLE();
+ }
+ }
+ else if (mRenderer->testDeviceLost(true))
+ {
+ return gl::error(GL_OUT_OF_MEMORY, GL_TRUE);
+ }
+
+ return mStatus;
+ }
+
+ return GL_TRUE; // prevent blocking when query is null
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Query11.h b/src/3rdparty/angle/src/libGLESv2/renderer/Query11.h
new file mode 100644
index 0000000000..0a03de77ca
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Query11.h
@@ -0,0 +1,40 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Query11.h: Defines the rx::Query11 class which implements rx::QueryImpl.
+
+#ifndef LIBGLESV2_RENDERER_QUERY11_H_
+#define LIBGLESV2_RENDERER_QUERY11_H_
+
+#include "libGLESv2/renderer/QueryImpl.h"
+
+namespace rx
+{
+class Renderer11;
+
+class Query11 : public QueryImpl
+{
+ public:
+ Query11(rx::Renderer11 *renderer, GLenum type);
+ virtual ~Query11();
+
+ void begin();
+ void end();
+ GLuint getResult();
+ GLboolean isResultAvailable();
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(Query11);
+
+ GLboolean testQuery();
+
+ rx::Renderer11 *mRenderer;
+ ID3D11Query *mQuery;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_QUERY11_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Query9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Query9.cpp
new file mode 100644
index 0000000000..ef694267dd
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Query9.cpp
@@ -0,0 +1,125 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Query9.cpp: Defines the rx::Query9 class which implements rx::QueryImpl.
+
+
+#include "libGLESv2/renderer/Query9.h"
+#include "libGLESv2/main.h"
+#include "libGLESv2/renderer/renderer9_utils.h"
+#include "libGLESv2/renderer/Renderer9.h"
+
+namespace rx
+{
+
+Query9::Query9(rx::Renderer9 *renderer, GLenum type) : QueryImpl(type)
+{
+ mRenderer = renderer;
+ mQuery = NULL;
+}
+
+Query9::~Query9()
+{
+ if (mQuery)
+ {
+ mQuery->Release();
+ mQuery = NULL;
+ }
+}
+
+void Query9::begin()
+{
+ if (mQuery == NULL)
+ {
+ if (FAILED(mRenderer->getDevice()->CreateQuery(D3DQUERYTYPE_OCCLUSION, &mQuery)))
+ {
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ HRESULT result = mQuery->Issue(D3DISSUE_BEGIN);
+ ASSERT(SUCCEEDED(result));
+}
+
+void Query9::end()
+{
+ if (mQuery == NULL)
+ {
+ return gl::error(GL_INVALID_OPERATION);
+ }
+
+ HRESULT result = mQuery->Issue(D3DISSUE_END);
+ ASSERT(SUCCEEDED(result));
+
+ mStatus = GL_FALSE;
+ mResult = GL_FALSE;
+}
+
+GLuint Query9::getResult()
+{
+ if (mQuery != NULL)
+ {
+ while (!testQuery())
+ {
+ Sleep(0);
+ // explicitly check for device loss
+ // some drivers seem to return S_FALSE even if the device is lost
+ // instead of D3DERR_DEVICELOST like they should
+ if (mRenderer->testDeviceLost(true))
+ {
+ return gl::error(GL_OUT_OF_MEMORY, 0);
+ }
+ }
+ }
+
+ return mResult;
+}
+
+GLboolean Query9::isResultAvailable()
+{
+ if (mQuery != NULL)
+ {
+ testQuery();
+ }
+
+ return mStatus;
+}
+
+GLboolean Query9::testQuery()
+{
+ if (mQuery != NULL && mStatus != GL_TRUE)
+ {
+ DWORD numPixels = 0;
+
+ HRESULT hres = mQuery->GetData(&numPixels, sizeof(DWORD), D3DGETDATA_FLUSH);
+ if (hres == S_OK)
+ {
+ mStatus = GL_TRUE;
+
+ switch (getType())
+ {
+ case GL_ANY_SAMPLES_PASSED_EXT:
+ case GL_ANY_SAMPLES_PASSED_CONSERVATIVE_EXT:
+ mResult = (numPixels > 0) ? GL_TRUE : GL_FALSE;
+ break;
+ default:
+ ASSERT(false);
+ }
+ }
+ else if (d3d9::isDeviceLostError(hres))
+ {
+ mRenderer->notifyDeviceLost();
+ return gl::error(GL_OUT_OF_MEMORY, GL_TRUE);
+ }
+
+ return mStatus;
+ }
+
+ return GL_TRUE; // prevent blocking when query is null
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Query9.h b/src/3rdparty/angle/src/libGLESv2/renderer/Query9.h
new file mode 100644
index 0000000000..47eef89336
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Query9.h
@@ -0,0 +1,40 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Query9.h: Defines the rx::Query9 class which implements rx::QueryImpl.
+
+#ifndef LIBGLESV2_RENDERER_QUERY9_H_
+#define LIBGLESV2_RENDERER_QUERY9_H_
+
+#include "libGLESv2/renderer/QueryImpl.h"
+
+namespace rx
+{
+class Renderer9;
+
+class Query9 : public QueryImpl
+{
+ public:
+ Query9(rx::Renderer9 *renderer, GLenum type);
+ virtual ~Query9();
+
+ void begin();
+ void end();
+ GLuint getResult();
+ GLboolean isResultAvailable();
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(Query9);
+
+ GLboolean testQuery();
+
+ rx::Renderer9 *mRenderer;
+ IDirect3DQuery9 *mQuery;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_QUERY9_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/QueryImpl.h b/src/3rdparty/angle/src/libGLESv2/renderer/QueryImpl.h
new file mode 100644
index 0000000000..a874047b0c
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/QueryImpl.h
@@ -0,0 +1,42 @@
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// QueryImpl.h: Defines the abstract rx::QueryImpl class.
+
+#ifndef LIBGLESV2_RENDERER_QUERYIMPL_H_
+#define LIBGLESV2_RENDERER_QUERYIMPL_H_
+
+#include "common/angleutils.h"
+
+namespace rx
+{
+
+class QueryImpl
+{
+ public:
+ explicit QueryImpl(GLenum type) : mType(type), mStatus(GL_FALSE), mResult(0) { }
+ virtual ~QueryImpl() { }
+
+ virtual void begin() = 0;
+ virtual void end() = 0;
+ virtual GLuint getResult() = 0;
+ virtual GLboolean isResultAvailable() = 0;
+
+ GLenum getType() const { return mType; }
+
+ protected:
+ GLuint mResult;
+ GLboolean mStatus;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(QueryImpl);
+
+ GLenum mType;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_QUERYIMPL_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/RenderStateCache.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/RenderStateCache.cpp
new file mode 100644
index 0000000000..f60a88f97a
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/RenderStateCache.cpp
@@ -0,0 +1,406 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// RenderStateCache.cpp: Defines rx::RenderStateCache, a cache of Direct3D render
+// state objects.
+
+#include "libGLESv2/renderer/RenderStateCache.h"
+#include "libGLESv2/renderer/renderer11_utils.h"
+
+#include "common/debug.h"
+#include "third_party/murmurhash/MurmurHash3.h"
+
+namespace rx
+{
+
+// MSDN's documentation of ID3D11Device::CreateBlendState, ID3D11Device::CreateRasterizerState,
+// ID3D11Device::CreateDepthStencilState and ID3D11Device::CreateSamplerState claims the maximum
+// number of unique states of each type an application can create is 4096
+const unsigned int RenderStateCache::kMaxBlendStates = 4096;
+const unsigned int RenderStateCache::kMaxRasterizerStates = 4096;
+const unsigned int RenderStateCache::kMaxDepthStencilStates = 4096;
+const unsigned int RenderStateCache::kMaxSamplerStates = 4096;
+
+RenderStateCache::RenderStateCache() : mDevice(NULL), mCounter(0),
+ mBlendStateCache(kMaxBlendStates, hashBlendState, compareBlendStates),
+ mRasterizerStateCache(kMaxRasterizerStates, hashRasterizerState, compareRasterizerStates),
+ mDepthStencilStateCache(kMaxDepthStencilStates, hashDepthStencilState, compareDepthStencilStates),
+ mSamplerStateCache(kMaxSamplerStates, hashSamplerState, compareSamplerStates)
+{
+}
+
+RenderStateCache::~RenderStateCache()
+{
+ clear();
+}
+
+void RenderStateCache::initialize(ID3D11Device *device)
+{
+ clear();
+ mDevice = device;
+}
+
+void RenderStateCache::clear()
+{
+ for (BlendStateMap::iterator i = mBlendStateCache.begin(); i != mBlendStateCache.end(); i++)
+ {
+ i->second.first->Release();
+ }
+ mBlendStateCache.clear();
+
+ for (RasterizerStateMap::iterator i = mRasterizerStateCache.begin(); i != mRasterizerStateCache.end(); i++)
+ {
+ i->second.first->Release();
+ }
+ mRasterizerStateCache.clear();
+
+ for (DepthStencilStateMap::iterator i = mDepthStencilStateCache.begin(); i != mDepthStencilStateCache.end(); i++)
+ {
+ i->second.first->Release();
+ }
+ mDepthStencilStateCache.clear();
+
+ for (SamplerStateMap::iterator i = mSamplerStateCache.begin(); i != mSamplerStateCache.end(); i++)
+ {
+ i->second.first->Release();
+ }
+ mSamplerStateCache.clear();
+}
+
+std::size_t RenderStateCache::hashBlendState(const gl::BlendState &blendState)
+{
+ static const unsigned int seed = 0xABCDEF98;
+
+ std::size_t hash = 0;
+ MurmurHash3_x86_32(&blendState, sizeof(gl::BlendState), seed, &hash);
+ return hash;
+}
+
+bool RenderStateCache::compareBlendStates(const gl::BlendState &a, const gl::BlendState &b)
+{
+ return memcmp(&a, &b, sizeof(gl::BlendState)) == 0;
+}
+
+ID3D11BlendState *RenderStateCache::getBlendState(const gl::BlendState &blendState)
+{
+ if (!mDevice)
+ {
+ ERR("RenderStateCache is not initialized.");
+ return NULL;
+ }
+
+ BlendStateMap::iterator i = mBlendStateCache.find(blendState);
+ if (i != mBlendStateCache.end())
+ {
+ BlendStateCounterPair &state = i->second;
+ state.second = mCounter++;
+ return state.first;
+ }
+ else
+ {
+ if (mBlendStateCache.size() >= kMaxBlendStates)
+ {
+ TRACE("Overflowed the limit of %u blend states, removing the least recently used "
+ "to make room.", kMaxBlendStates);
+
+ BlendStateMap::iterator leastRecentlyUsed = mBlendStateCache.begin();
+ for (BlendStateMap::iterator i = mBlendStateCache.begin(); i != mBlendStateCache.end(); i++)
+ {
+ if (i->second.second < leastRecentlyUsed->second.second)
+ {
+ leastRecentlyUsed = i;
+ }
+ }
+ leastRecentlyUsed->second.first->Release();
+ mBlendStateCache.erase(leastRecentlyUsed);
+ }
+
+ // Create a new blend state and insert it into the cache
+ D3D11_BLEND_DESC blendDesc = { 0 };
+ blendDesc.AlphaToCoverageEnable = blendState.sampleAlphaToCoverage;
+ blendDesc.IndependentBlendEnable = FALSE;
+
+ for (unsigned int i = 0; i < D3D11_SIMULTANEOUS_RENDER_TARGET_COUNT; i++)
+ {
+ D3D11_RENDER_TARGET_BLEND_DESC &rtBlend = blendDesc.RenderTarget[i];
+
+ rtBlend.BlendEnable = blendState.blend;
+ if (blendState.blend)
+ {
+ rtBlend.SrcBlend = gl_d3d11::ConvertBlendFunc(blendState.sourceBlendRGB, false);
+ rtBlend.DestBlend = gl_d3d11::ConvertBlendFunc(blendState.destBlendRGB, false);
+ rtBlend.BlendOp = gl_d3d11::ConvertBlendOp(blendState.blendEquationRGB);
+
+ rtBlend.SrcBlendAlpha = gl_d3d11::ConvertBlendFunc(blendState.sourceBlendAlpha, true);
+ rtBlend.DestBlendAlpha = gl_d3d11::ConvertBlendFunc(blendState.destBlendAlpha, true);
+ rtBlend.BlendOpAlpha = gl_d3d11::ConvertBlendOp(blendState.blendEquationAlpha);
+ }
+
+ rtBlend.RenderTargetWriteMask = gl_d3d11::ConvertColorMask(blendState.colorMaskRed,
+ blendState.colorMaskGreen,
+ blendState.colorMaskBlue,
+ blendState.colorMaskAlpha);
+ }
+
+ ID3D11BlendState *dx11BlendState = NULL;
+ HRESULT result = mDevice->CreateBlendState(&blendDesc, &dx11BlendState);
+ if (FAILED(result) || !dx11BlendState)
+ {
+ ERR("Unable to create a ID3D11BlendState, HRESULT: 0x%X.", result);
+ return NULL;
+ }
+
+ mBlendStateCache.insert(std::make_pair(blendState, std::make_pair(dx11BlendState, mCounter++)));
+
+ return dx11BlendState;
+ }
+}
+
+std::size_t RenderStateCache::hashRasterizerState(const RasterizerStateKey &rasterState)
+{
+ static const unsigned int seed = 0xABCDEF98;
+
+ std::size_t hash = 0;
+ MurmurHash3_x86_32(&rasterState, sizeof(RasterizerStateKey), seed, &hash);
+ return hash;
+}
+
+bool RenderStateCache::compareRasterizerStates(const RasterizerStateKey &a, const RasterizerStateKey &b)
+{
+ return memcmp(&a, &b, sizeof(RasterizerStateKey)) == 0;
+}
+
+ID3D11RasterizerState *RenderStateCache::getRasterizerState(const gl::RasterizerState &rasterState,
+ bool scissorEnabled, unsigned int depthSize)
+{
+ if (!mDevice)
+ {
+ ERR("RenderStateCache is not initialized.");
+ return NULL;
+ }
+
+ RasterizerStateKey key;
+ key.rasterizerState = rasterState;
+ key.scissorEnabled = scissorEnabled;
+ key.depthSize = depthSize;
+
+ RasterizerStateMap::iterator i = mRasterizerStateCache.find(key);
+ if (i != mRasterizerStateCache.end())
+ {
+ RasterizerStateCounterPair &state = i->second;
+ state.second = mCounter++;
+ return state.first;
+ }
+ else
+ {
+ if (mRasterizerStateCache.size() >= kMaxRasterizerStates)
+ {
+ TRACE("Overflowed the limit of %u rasterizer states, removing the least recently used "
+ "to make room.", kMaxRasterizerStates);
+
+ RasterizerStateMap::iterator leastRecentlyUsed = mRasterizerStateCache.begin();
+ for (RasterizerStateMap::iterator i = mRasterizerStateCache.begin(); i != mRasterizerStateCache.end(); i++)
+ {
+ if (i->second.second < leastRecentlyUsed->second.second)
+ {
+ leastRecentlyUsed = i;
+ }
+ }
+ leastRecentlyUsed->second.first->Release();
+ mRasterizerStateCache.erase(leastRecentlyUsed);
+ }
+
+ D3D11_CULL_MODE cullMode = gl_d3d11::ConvertCullMode(rasterState.cullFace, rasterState.cullMode);
+
+ // Disable culling if drawing points
+ if (rasterState.pointDrawMode)
+ {
+ cullMode = D3D11_CULL_NONE;
+ }
+
+ D3D11_RASTERIZER_DESC rasterDesc;
+ rasterDesc.FillMode = D3D11_FILL_SOLID;
+ rasterDesc.CullMode = cullMode;
+ rasterDesc.FrontCounterClockwise = (rasterState.frontFace == GL_CCW) ? FALSE: TRUE;
+ rasterDesc.DepthBias = ldexp(rasterState.polygonOffsetUnits, -static_cast<int>(depthSize));
+ rasterDesc.DepthBiasClamp = 0.0f; // MSDN documentation of DepthBiasClamp implies a value of zero will preform no clamping, must be tested though.
+ rasterDesc.SlopeScaledDepthBias = rasterState.polygonOffsetFactor;
+ rasterDesc.DepthClipEnable = TRUE;
+ rasterDesc.ScissorEnable = scissorEnabled ? TRUE : FALSE;
+ rasterDesc.MultisampleEnable = TRUE;
+ rasterDesc.AntialiasedLineEnable = FALSE;
+
+ ID3D11RasterizerState *dx11RasterizerState = NULL;
+ HRESULT result = mDevice->CreateRasterizerState(&rasterDesc, &dx11RasterizerState);
+ if (FAILED(result) || !dx11RasterizerState)
+ {
+ ERR("Unable to create a ID3D11RasterizerState, HRESULT: 0x%X.", result);
+ return NULL;
+ }
+
+ mRasterizerStateCache.insert(std::make_pair(key, std::make_pair(dx11RasterizerState, mCounter++)));
+
+ return dx11RasterizerState;
+ }
+}
+
+std::size_t RenderStateCache::hashDepthStencilState(const gl::DepthStencilState &dsState)
+{
+ static const unsigned int seed = 0xABCDEF98;
+
+ std::size_t hash = 0;
+ MurmurHash3_x86_32(&dsState, sizeof(gl::DepthStencilState), seed, &hash);
+ return hash;
+}
+
+bool RenderStateCache::compareDepthStencilStates(const gl::DepthStencilState &a, const gl::DepthStencilState &b)
+{
+ return memcmp(&a, &b, sizeof(gl::DepthStencilState)) == 0;
+}
+
+ID3D11DepthStencilState *RenderStateCache::getDepthStencilState(const gl::DepthStencilState &dsState)
+{
+ if (!mDevice)
+ {
+ ERR("RenderStateCache is not initialized.");
+ return NULL;
+ }
+
+ DepthStencilStateMap::iterator i = mDepthStencilStateCache.find(dsState);
+ if (i != mDepthStencilStateCache.end())
+ {
+ DepthStencilStateCounterPair &state = i->second;
+ state.second = mCounter++;
+ return state.first;
+ }
+ else
+ {
+ if (mDepthStencilStateCache.size() >= kMaxDepthStencilStates)
+ {
+ TRACE("Overflowed the limit of %u depth stencil states, removing the least recently used "
+ "to make room.", kMaxDepthStencilStates);
+
+ DepthStencilStateMap::iterator leastRecentlyUsed = mDepthStencilStateCache.begin();
+ for (DepthStencilStateMap::iterator i = mDepthStencilStateCache.begin(); i != mDepthStencilStateCache.end(); i++)
+ {
+ if (i->second.second < leastRecentlyUsed->second.second)
+ {
+ leastRecentlyUsed = i;
+ }
+ }
+ leastRecentlyUsed->second.first->Release();
+ mDepthStencilStateCache.erase(leastRecentlyUsed);
+ }
+
+ D3D11_DEPTH_STENCIL_DESC dsDesc = { 0 };
+ dsDesc.DepthEnable = dsState.depthTest ? TRUE : FALSE;
+ dsDesc.DepthWriteMask = gl_d3d11::ConvertDepthMask(dsState.depthMask);
+ dsDesc.DepthFunc = gl_d3d11::ConvertComparison(dsState.depthFunc);
+ dsDesc.StencilEnable = dsState.stencilTest ? TRUE : FALSE;
+ dsDesc.StencilReadMask = gl_d3d11::ConvertStencilMask(dsState.stencilMask);
+ dsDesc.StencilWriteMask = gl_d3d11::ConvertStencilMask(dsState.stencilWritemask);
+ dsDesc.FrontFace.StencilFailOp = gl_d3d11::ConvertStencilOp(dsState.stencilFail);
+ dsDesc.FrontFace.StencilDepthFailOp = gl_d3d11::ConvertStencilOp(dsState.stencilPassDepthFail);
+ dsDesc.FrontFace.StencilPassOp = gl_d3d11::ConvertStencilOp(dsState.stencilPassDepthPass);
+ dsDesc.FrontFace.StencilFunc = gl_d3d11::ConvertComparison(dsState.stencilFunc);
+ dsDesc.BackFace.StencilFailOp = gl_d3d11::ConvertStencilOp(dsState.stencilBackFail);
+ dsDesc.BackFace.StencilDepthFailOp = gl_d3d11::ConvertStencilOp(dsState.stencilBackPassDepthFail);
+ dsDesc.BackFace.StencilPassOp = gl_d3d11::ConvertStencilOp(dsState.stencilBackPassDepthPass);
+ dsDesc.BackFace.StencilFunc = gl_d3d11::ConvertComparison(dsState.stencilBackFunc);
+
+ ID3D11DepthStencilState *dx11DepthStencilState = NULL;
+ HRESULT result = mDevice->CreateDepthStencilState(&dsDesc, &dx11DepthStencilState);
+ if (FAILED(result) || !dx11DepthStencilState)
+ {
+ ERR("Unable to create a ID3D11DepthStencilState, HRESULT: 0x%X.", result);
+ return NULL;
+ }
+
+ mDepthStencilStateCache.insert(std::make_pair(dsState, std::make_pair(dx11DepthStencilState, mCounter++)));
+
+ return dx11DepthStencilState;
+ }
+}
+
+std::size_t RenderStateCache::hashSamplerState(const gl::SamplerState &samplerState)
+{
+ static const unsigned int seed = 0xABCDEF98;
+
+ std::size_t hash = 0;
+ MurmurHash3_x86_32(&samplerState, sizeof(gl::SamplerState), seed, &hash);
+ return hash;
+}
+
+bool RenderStateCache::compareSamplerStates(const gl::SamplerState &a, const gl::SamplerState &b)
+{
+ return memcmp(&a, &b, sizeof(gl::SamplerState)) == 0;
+}
+
+ID3D11SamplerState *RenderStateCache::getSamplerState(const gl::SamplerState &samplerState)
+{
+ if (!mDevice)
+ {
+ ERR("RenderStateCache is not initialized.");
+ return NULL;
+ }
+
+ SamplerStateMap::iterator i = mSamplerStateCache.find(samplerState);
+ if (i != mSamplerStateCache.end())
+ {
+ SamplerStateCounterPair &state = i->second;
+ state.second = mCounter++;
+ return state.first;
+ }
+ else
+ {
+ if (mSamplerStateCache.size() >= kMaxSamplerStates)
+ {
+ TRACE("Overflowed the limit of %u sampler states, removing the least recently used "
+ "to make room.", kMaxSamplerStates);
+
+ SamplerStateMap::iterator leastRecentlyUsed = mSamplerStateCache.begin();
+ for (SamplerStateMap::iterator i = mSamplerStateCache.begin(); i != mSamplerStateCache.end(); i++)
+ {
+ if (i->second.second < leastRecentlyUsed->second.second)
+ {
+ leastRecentlyUsed = i;
+ }
+ }
+ leastRecentlyUsed->second.first->Release();
+ mSamplerStateCache.erase(leastRecentlyUsed);
+ }
+
+ D3D11_SAMPLER_DESC samplerDesc;
+ samplerDesc.Filter = gl_d3d11::ConvertFilter(samplerState.minFilter, samplerState.magFilter, samplerState.maxAnisotropy);
+ samplerDesc.AddressU = gl_d3d11::ConvertTextureWrap(samplerState.wrapS);
+ samplerDesc.AddressV = gl_d3d11::ConvertTextureWrap(samplerState.wrapT);
+ samplerDesc.AddressW = D3D11_TEXTURE_ADDRESS_CLAMP;
+ samplerDesc.MipLODBias = static_cast<float>(samplerState.lodOffset);
+ samplerDesc.MaxAnisotropy = samplerState.maxAnisotropy;
+ samplerDesc.ComparisonFunc = D3D11_COMPARISON_NEVER;
+ samplerDesc.BorderColor[0] = 0.0f;
+ samplerDesc.BorderColor[1] = 0.0f;
+ samplerDesc.BorderColor[2] = 0.0f;
+ samplerDesc.BorderColor[3] = 0.0f;
+ samplerDesc.MinLOD = gl_d3d11::ConvertMinLOD(samplerState.minFilter, samplerState.lodOffset);
+ samplerDesc.MaxLOD = gl_d3d11::ConvertMaxLOD(samplerState.minFilter, samplerState.lodOffset);
+
+ ID3D11SamplerState *dx11SamplerState = NULL;
+ HRESULT result = mDevice->CreateSamplerState(&samplerDesc, &dx11SamplerState);
+ if (FAILED(result) || !dx11SamplerState)
+ {
+ ERR("Unable to create a ID3D11DepthStencilState, HRESULT: 0x%X.", result);
+ return NULL;
+ }
+
+ mSamplerStateCache.insert(std::make_pair(samplerState, std::make_pair(dx11SamplerState, mCounter++)));
+
+ return dx11SamplerState;
+ }
+}
+
+} \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/RenderStateCache.h b/src/3rdparty/angle/src/libGLESv2/renderer/RenderStateCache.h
new file mode 100644
index 0000000000..f8b5111de4
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/RenderStateCache.h
@@ -0,0 +1,101 @@
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// RenderStateCache.h: Defines rx::RenderStateCache, a cache of Direct3D render
+// state objects.
+
+#ifndef LIBGLESV2_RENDERER_RENDERSTATECACHE_H_
+#define LIBGLESV2_RENDERER_RENDERSTATECACHE_H_
+
+#include "libGLESv2/angletypes.h"
+#include "common/angleutils.h"
+
+namespace rx
+{
+
+class RenderStateCache
+{
+ public:
+ RenderStateCache();
+ virtual ~RenderStateCache();
+
+ void initialize(ID3D11Device *device);
+ void clear();
+
+ // Increments refcount on the returned blend state, Release() must be called.
+ ID3D11BlendState *getBlendState(const gl::BlendState &blendState);
+ ID3D11RasterizerState *getRasterizerState(const gl::RasterizerState &rasterState,
+ bool scissorEnabled, unsigned int depthSize);
+ ID3D11DepthStencilState *getDepthStencilState(const gl::DepthStencilState &dsState);
+ ID3D11SamplerState *getSamplerState(const gl::SamplerState &samplerState);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(RenderStateCache);
+
+ unsigned long long mCounter;
+
+ // Blend state cache
+ static std::size_t hashBlendState(const gl::BlendState &blendState);
+ static bool compareBlendStates(const gl::BlendState &a, const gl::BlendState &b);
+ static const unsigned int kMaxBlendStates;
+
+ typedef std::size_t (*BlendStateHashFunction)(const gl::BlendState &);
+ typedef bool (*BlendStateEqualityFunction)(const gl::BlendState &, const gl::BlendState &);
+ typedef std::pair<ID3D11BlendState*, unsigned long long> BlendStateCounterPair;
+ typedef std::unordered_map<gl::BlendState, BlendStateCounterPair, BlendStateHashFunction, BlendStateEqualityFunction> BlendStateMap;
+ BlendStateMap mBlendStateCache;
+
+ // Rasterizer state cache
+ struct RasterizerStateKey
+ {
+ gl::RasterizerState rasterizerState;
+ bool scissorEnabled;
+ unsigned int depthSize;
+ };
+ static std::size_t hashRasterizerState(const RasterizerStateKey &rasterState);
+ static bool compareRasterizerStates(const RasterizerStateKey &a, const RasterizerStateKey &b);
+ static const unsigned int kMaxRasterizerStates;
+
+ typedef std::size_t (*RasterizerStateHashFunction)(const RasterizerStateKey &);
+ typedef bool (*RasterizerStateEqualityFunction)(const RasterizerStateKey &, const RasterizerStateKey &);
+ typedef std::pair<ID3D11RasterizerState*, unsigned long long> RasterizerStateCounterPair;
+ typedef std::unordered_map<RasterizerStateKey, RasterizerStateCounterPair, RasterizerStateHashFunction, RasterizerStateEqualityFunction> RasterizerStateMap;
+ RasterizerStateMap mRasterizerStateCache;
+
+ // Depth stencil state cache
+ static std::size_t hashDepthStencilState(const gl::DepthStencilState &dsState);
+ static bool compareDepthStencilStates(const gl::DepthStencilState &a, const gl::DepthStencilState &b);
+ static const unsigned int kMaxDepthStencilStates;
+
+ typedef std::size_t (*DepthStencilStateHashFunction)(const gl::DepthStencilState &);
+ typedef bool (*DepthStencilStateEqualityFunction)(const gl::DepthStencilState &, const gl::DepthStencilState &);
+ typedef std::pair<ID3D11DepthStencilState*, unsigned long long> DepthStencilStateCounterPair;
+ typedef std::unordered_map<gl::DepthStencilState,
+ DepthStencilStateCounterPair,
+ DepthStencilStateHashFunction,
+ DepthStencilStateEqualityFunction> DepthStencilStateMap;
+ DepthStencilStateMap mDepthStencilStateCache;
+
+ // Sample state cache
+ static std::size_t hashSamplerState(const gl::SamplerState &samplerState);
+ static bool compareSamplerStates(const gl::SamplerState &a, const gl::SamplerState &b);
+ static const unsigned int kMaxSamplerStates;
+
+ typedef std::size_t (*SamplerStateHashFunction)(const gl::SamplerState &);
+ typedef bool (*SamplerStateEqualityFunction)(const gl::SamplerState &, const gl::SamplerState &);
+ typedef std::pair<ID3D11SamplerState*, unsigned long long> SamplerStateCounterPair;
+ typedef std::unordered_map<gl::SamplerState,
+ SamplerStateCounterPair,
+ SamplerStateHashFunction,
+ SamplerStateEqualityFunction> SamplerStateMap;
+ SamplerStateMap mSamplerStateCache;
+
+ ID3D11Device *mDevice;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_RENDERSTATECACHE_H_ \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget.h b/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget.h
new file mode 100644
index 0000000000..80de39f4f7
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget.h
@@ -0,0 +1,56 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// RenderTarget.h: Defines an abstract wrapper class to manage IDirect3DSurface9
+// and ID3D11View objects belonging to renderbuffers.
+
+#ifndef LIBGLESV2_RENDERER_RENDERTARGET_H_
+#define LIBGLESV2_RENDERER_RENDERTARGET_H_
+
+#include "common/angleutils.h"
+
+namespace rx
+{
+class RenderTarget
+{
+ public:
+ RenderTarget()
+ {
+ mWidth = 0;
+ mHeight = 0;
+ mInternalFormat = GL_NONE;
+ mActualFormat = GL_NONE;
+ mSamples = 0;
+ }
+
+ virtual ~RenderTarget() {};
+
+ GLsizei getWidth() { return mWidth; }
+ GLsizei getHeight() { return mHeight; }
+ GLenum getInternalFormat() { return mInternalFormat; }
+ GLenum getActualFormat() { return mActualFormat; }
+ GLsizei getSamples() { return mSamples; }
+
+ struct Desc {
+ GLsizei width;
+ GLsizei height;
+ GLenum format;
+ };
+
+ protected:
+ GLsizei mWidth;
+ GLsizei mHeight;
+ GLenum mInternalFormat;
+ GLenum mActualFormat;
+ GLsizei mSamples;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(RenderTarget);
+};
+
+}
+
+#endif // LIBGLESV2_RENDERTARGET_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget11.cpp
new file mode 100644
index 0000000000..cf226de17b
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget11.cpp
@@ -0,0 +1,378 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// RenderTarget11.cpp: Implements a DX11-specific wrapper for ID3D11View pointers
+// retained by Renderbuffers.
+
+#include "libGLESv2/renderer/RenderTarget11.h"
+#include "libGLESv2/renderer/Renderer11.h"
+
+#include "libGLESv2/renderer/renderer11_utils.h"
+#include "libGLESv2/main.h"
+
+namespace rx
+{
+
+static unsigned int getRTVSubresourceIndex(ID3D11Texture2D *texture, ID3D11RenderTargetView *view)
+{
+ D3D11_RENDER_TARGET_VIEW_DESC rtvDesc;
+ view->GetDesc(&rtvDesc);
+
+ D3D11_TEXTURE2D_DESC texDesc;
+ texture->GetDesc(&texDesc);
+
+ unsigned int mipSlice = 0;
+ unsigned int arraySlice = 0;
+ unsigned int mipLevels = texDesc.MipLevels;
+
+ switch (rtvDesc.ViewDimension)
+ {
+ case D3D11_RTV_DIMENSION_TEXTURE1D:
+ mipSlice = rtvDesc.Texture1D.MipSlice;
+ arraySlice = 0;
+ break;
+
+ case D3D11_RTV_DIMENSION_TEXTURE1DARRAY:
+ mipSlice = rtvDesc.Texture1DArray.MipSlice;
+ arraySlice = rtvDesc.Texture1DArray.FirstArraySlice;
+ break;
+
+ case D3D11_RTV_DIMENSION_TEXTURE2D:
+ mipSlice = rtvDesc.Texture2D.MipSlice;
+ arraySlice = 0;
+ break;
+
+ case D3D11_RTV_DIMENSION_TEXTURE2DARRAY:
+ mipSlice = rtvDesc.Texture2DArray.MipSlice;
+ arraySlice = rtvDesc.Texture2DArray.FirstArraySlice;
+ break;
+
+ case D3D11_RTV_DIMENSION_TEXTURE2DMS:
+ mipSlice = 0;
+ arraySlice = 0;
+ break;
+
+ case D3D11_RTV_DIMENSION_TEXTURE2DMSARRAY:
+ mipSlice = 0;
+ arraySlice = rtvDesc.Texture2DMSArray.FirstArraySlice;
+ break;
+
+ case D3D11_RTV_DIMENSION_TEXTURE3D:
+ mipSlice = rtvDesc.Texture3D.MipSlice;
+ arraySlice = 0;
+ break;
+
+ case D3D11_RTV_DIMENSION_UNKNOWN:
+ case D3D11_RTV_DIMENSION_BUFFER:
+ UNIMPLEMENTED();
+ break;
+
+ default:
+ UNREACHABLE();
+ break;
+ }
+
+ return D3D11CalcSubresource(mipSlice, arraySlice, mipLevels);
+}
+
+static unsigned int getDSVSubresourceIndex(ID3D11Texture2D *texture, ID3D11DepthStencilView *view)
+{
+ D3D11_DEPTH_STENCIL_VIEW_DESC dsvDesc;
+ view->GetDesc(&dsvDesc);
+
+ D3D11_TEXTURE2D_DESC texDesc;
+ texture->GetDesc(&texDesc);
+
+ unsigned int mipSlice = 0;
+ unsigned int arraySlice = 0;
+ unsigned int mipLevels = texDesc.MipLevels;
+
+ switch (dsvDesc.ViewDimension)
+ {
+ case D3D11_DSV_DIMENSION_TEXTURE1D:
+ mipSlice = dsvDesc.Texture1D.MipSlice;
+ arraySlice = 0;
+ break;
+
+ case D3D11_DSV_DIMENSION_TEXTURE1DARRAY:
+ mipSlice = dsvDesc.Texture1DArray.MipSlice;
+ arraySlice = dsvDesc.Texture1DArray.FirstArraySlice;
+ break;
+
+ case D3D11_DSV_DIMENSION_TEXTURE2D:
+ mipSlice = dsvDesc.Texture2D.MipSlice;
+ arraySlice = 0;
+ break;
+
+ case D3D11_DSV_DIMENSION_TEXTURE2DARRAY:
+ mipSlice = dsvDesc.Texture2DArray.MipSlice;
+ arraySlice = dsvDesc.Texture2DArray.FirstArraySlice;
+ break;
+
+ case D3D11_DSV_DIMENSION_TEXTURE2DMS:
+ mipSlice = 0;
+ arraySlice = 0;
+ break;
+
+ case D3D11_DSV_DIMENSION_TEXTURE2DMSARRAY:
+ mipSlice = 0;
+ arraySlice = dsvDesc.Texture2DMSArray.FirstArraySlice;
+ break;
+
+ case D3D11_RTV_DIMENSION_UNKNOWN:
+ UNIMPLEMENTED();
+ break;
+
+ default:
+ UNREACHABLE();
+ break;
+ }
+
+ return D3D11CalcSubresource(mipSlice, arraySlice, mipLevels);
+}
+
+RenderTarget11::RenderTarget11(Renderer *renderer, ID3D11RenderTargetView *rtv, ID3D11Texture2D *tex, ID3D11ShaderResourceView *srv, GLsizei width, GLsizei height)
+{
+ mRenderer = Renderer11::makeRenderer11(renderer);
+ mTexture = tex;
+ mRenderTarget = rtv;
+ mDepthStencil = NULL;
+ mShaderResource = srv;
+ mSubresourceIndex = 0;
+
+ if (mRenderTarget && mTexture)
+ {
+ D3D11_RENDER_TARGET_VIEW_DESC desc;
+ mRenderTarget->GetDesc(&desc);
+
+ D3D11_TEXTURE2D_DESC texDesc;
+ mTexture->GetDesc(&texDesc);
+
+ mSubresourceIndex = getRTVSubresourceIndex(mTexture, mRenderTarget);
+ mWidth = width;
+ mHeight = height;
+ mSamples = (texDesc.SampleDesc.Count > 1) ? texDesc.SampleDesc.Count : 0;
+
+ mInternalFormat = d3d11_gl::ConvertTextureInternalFormat(desc.Format);
+ mActualFormat = d3d11_gl::ConvertTextureInternalFormat(desc.Format);
+ }
+}
+
+RenderTarget11::RenderTarget11(Renderer *renderer, ID3D11DepthStencilView *dsv, ID3D11Texture2D *tex, ID3D11ShaderResourceView *srv, GLsizei width, GLsizei height)
+{
+ mRenderer = Renderer11::makeRenderer11(renderer);
+ mTexture = tex;
+ mRenderTarget = NULL;
+ mDepthStencil = dsv;
+ mShaderResource = srv;
+ mSubresourceIndex = 0;
+
+ if (mDepthStencil && mTexture)
+ {
+ D3D11_DEPTH_STENCIL_VIEW_DESC desc;
+ mDepthStencil->GetDesc(&desc);
+
+ D3D11_TEXTURE2D_DESC texDesc;
+ mTexture->GetDesc(&texDesc);
+
+ mSubresourceIndex = getDSVSubresourceIndex(mTexture, mDepthStencil);
+ mWidth = width;
+ mHeight = height;
+ mSamples = (texDesc.SampleDesc.Count > 1) ? texDesc.SampleDesc.Count : 0;
+
+ mInternalFormat = d3d11_gl::ConvertTextureInternalFormat(desc.Format);
+ mActualFormat = d3d11_gl::ConvertTextureInternalFormat(desc.Format);
+ }
+}
+
+RenderTarget11::RenderTarget11(Renderer *renderer, GLsizei width, GLsizei height, GLenum format, GLsizei samples, bool depth)
+{
+ mRenderer = Renderer11::makeRenderer11(renderer);
+ mTexture = NULL;
+ mRenderTarget = NULL;
+ mDepthStencil = NULL;
+ mShaderResource = NULL;
+
+ DXGI_FORMAT requestedFormat = gl_d3d11::ConvertRenderbufferFormat(format);
+
+ int supportedSamples = mRenderer->getNearestSupportedSamples(requestedFormat, samples);
+ if (supportedSamples < 0)
+ {
+ gl::error(GL_OUT_OF_MEMORY);
+ return;
+ }
+
+ if (width > 0 && height > 0)
+ {
+ // Create texture resource
+ D3D11_TEXTURE2D_DESC desc;
+ desc.Width = width;
+ desc.Height = height;
+ desc.MipLevels = 1;
+ desc.ArraySize = 1;
+ desc.Format = requestedFormat;
+ desc.SampleDesc.Count = (supportedSamples == 0) ? 1 : supportedSamples;
+ desc.SampleDesc.Quality = 0;
+ desc.Usage = D3D11_USAGE_DEFAULT;
+ desc.CPUAccessFlags = 0;
+ desc.MiscFlags = 0;
+ desc.BindFlags = (depth ? D3D11_BIND_DEPTH_STENCIL : (D3D11_BIND_RENDER_TARGET | D3D11_BIND_SHADER_RESOURCE));
+
+ ID3D11Device *device = mRenderer->getDevice();
+ HRESULT result = device->CreateTexture2D(&desc, NULL, &mTexture);
+
+ if (result == E_OUTOFMEMORY)
+ {
+ gl::error(GL_OUT_OF_MEMORY);
+ return;
+ }
+ ASSERT(SUCCEEDED(result));
+
+ if (depth)
+ {
+ D3D11_DEPTH_STENCIL_VIEW_DESC dsvDesc;
+ dsvDesc.Format = requestedFormat;
+ dsvDesc.ViewDimension = (supportedSamples == 0) ? D3D11_DSV_DIMENSION_TEXTURE2D : D3D11_DSV_DIMENSION_TEXTURE2DMS;
+ dsvDesc.Texture2D.MipSlice = 0;
+ dsvDesc.Flags = 0;
+ result = device->CreateDepthStencilView(mTexture, &dsvDesc, &mDepthStencil);
+
+ if (result == E_OUTOFMEMORY)
+ {
+ mTexture->Release();
+ mTexture = NULL;
+ gl::error(GL_OUT_OF_MEMORY);
+ }
+ ASSERT(SUCCEEDED(result));
+ }
+ else
+ {
+ D3D11_RENDER_TARGET_VIEW_DESC rtvDesc;
+ rtvDesc.Format = requestedFormat;
+ rtvDesc.ViewDimension = (supportedSamples == 0) ? D3D11_RTV_DIMENSION_TEXTURE2D : D3D11_RTV_DIMENSION_TEXTURE2DMS;
+ rtvDesc.Texture2D.MipSlice = 0;
+ result = device->CreateRenderTargetView(mTexture, &rtvDesc, &mRenderTarget);
+
+ if (result == E_OUTOFMEMORY)
+ {
+ mTexture->Release();
+ mTexture = NULL;
+ gl::error(GL_OUT_OF_MEMORY);
+ return;
+ }
+ ASSERT(SUCCEEDED(result));
+
+ D3D11_SHADER_RESOURCE_VIEW_DESC srvDesc;
+ srvDesc.Format = requestedFormat;
+ srvDesc.ViewDimension = (supportedSamples == 0) ? D3D11_SRV_DIMENSION_TEXTURE2D : D3D11_SRV_DIMENSION_TEXTURE2DMS;
+ srvDesc.Texture2D.MostDetailedMip = 0;
+ srvDesc.Texture2D.MipLevels = 1;
+ result = device->CreateShaderResourceView(mTexture, &srvDesc, &mShaderResource);
+
+ if (result == E_OUTOFMEMORY)
+ {
+ mTexture->Release();
+ mTexture = NULL;
+ mRenderTarget->Release();
+ mRenderTarget = NULL;
+ gl::error(GL_OUT_OF_MEMORY);
+ return;
+ }
+ ASSERT(SUCCEEDED(result));
+ }
+ }
+
+ mWidth = width;
+ mHeight = height;
+ mInternalFormat = format;
+ mSamples = supportedSamples;
+ mActualFormat = d3d11_gl::ConvertTextureInternalFormat(requestedFormat);
+ mSubresourceIndex = D3D11CalcSubresource(0, 0, 1);
+}
+
+RenderTarget11::~RenderTarget11()
+{
+ if (mTexture)
+ {
+ mTexture->Release();
+ mTexture = NULL;
+ }
+
+ if (mRenderTarget)
+ {
+ mRenderTarget->Release();
+ mRenderTarget = NULL;
+ }
+
+ if (mDepthStencil)
+ {
+ mDepthStencil->Release();
+ mDepthStencil = NULL;
+ }
+
+ if (mShaderResource)
+ {
+ mShaderResource->Release();
+ mShaderResource = NULL;
+ }
+}
+
+RenderTarget11 *RenderTarget11::makeRenderTarget11(RenderTarget *target)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(rx::RenderTarget11*, target));
+ return static_cast<rx::RenderTarget11*>(target);
+}
+
+ID3D11Texture2D *RenderTarget11::getTexture() const
+{
+ if (mTexture)
+ {
+ mTexture->AddRef();
+ }
+
+ return mTexture;
+}
+
+// Adds reference, caller must call Release
+ID3D11RenderTargetView *RenderTarget11::getRenderTargetView() const
+{
+ if (mRenderTarget)
+ {
+ mRenderTarget->AddRef();
+ }
+
+ return mRenderTarget;
+}
+
+// Adds reference, caller must call Release
+ID3D11DepthStencilView *RenderTarget11::getDepthStencilView() const
+{
+ if (mDepthStencil)
+ {
+ mDepthStencil->AddRef();
+ }
+
+ return mDepthStencil;
+}
+
+// Adds reference, caller must call Release
+ID3D11ShaderResourceView *RenderTarget11::getShaderResourceView() const
+{
+ if (mShaderResource)
+ {
+ mShaderResource->AddRef();
+ }
+
+ return mShaderResource;
+}
+
+unsigned int RenderTarget11::getSubresourceIndex() const
+{
+ return mSubresourceIndex;
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget11.h b/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget11.h
new file mode 100644
index 0000000000..dc697cf0e3
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget11.h
@@ -0,0 +1,58 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// RenderTarget11.h: Defines a DX11-specific wrapper for ID3D11View pointers
+// retained by Renderbuffers.
+
+#ifndef LIBGLESV2_RENDERER_RENDERTARGET11_H_
+#define LIBGLESV2_RENDERER_RENDERTARGET11_H_
+
+#include "libGLESv2/renderer/RenderTarget.h"
+
+namespace rx
+{
+class Renderer;
+class Renderer11;
+
+class RenderTarget11 : public RenderTarget
+{
+ public:
+ RenderTarget11(Renderer *renderer, ID3D11RenderTargetView *rtv, ID3D11Texture2D *tex, ID3D11ShaderResourceView *srv, GLsizei width, GLsizei height);
+ RenderTarget11(Renderer *renderer, ID3D11DepthStencilView *dsv, ID3D11Texture2D *tex, ID3D11ShaderResourceView *srv, GLsizei width, GLsizei height);
+ RenderTarget11(Renderer *renderer, GLsizei width, GLsizei height, GLenum format, GLsizei samples, bool depth);
+ virtual ~RenderTarget11();
+
+ static RenderTarget11 *makeRenderTarget11(RenderTarget *renderTarget);
+
+ // Adds reference, caller must call Release
+ ID3D11Texture2D *getTexture() const;
+
+ // Adds reference, caller must call Release
+ ID3D11RenderTargetView *getRenderTargetView() const;
+
+ // Adds reference, caller must call Release
+ ID3D11DepthStencilView *getDepthStencilView() const;
+
+ // Adds reference, caller must call Release
+ ID3D11ShaderResourceView *getShaderResourceView() const;
+
+ unsigned int getSubresourceIndex() const;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(RenderTarget11);
+
+ unsigned int mSubresourceIndex;
+ ID3D11Texture2D *mTexture;
+ ID3D11RenderTargetView *mRenderTarget;
+ ID3D11DepthStencilView *mDepthStencil;
+ ID3D11ShaderResourceView *mShaderResource;
+
+ Renderer11 *mRenderer;
+};
+
+}
+
+#endif LIBGLESV2_RENDERER_RENDERTARGET11_H_ \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget9.cpp
new file mode 100644
index 0000000000..a84c709059
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget9.cpp
@@ -0,0 +1,113 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// RenderTarget9.cpp: Implements a D3D9-specific wrapper for IDirect3DSurface9
+// pointers retained by renderbuffers.
+
+#include "libGLESv2/renderer/RenderTarget9.h"
+#include "libGLESv2/renderer/Renderer9.h"
+
+#include "libGLESv2/renderer/renderer9_utils.h"
+#include "libGLESv2/main.h"
+
+namespace rx
+{
+
+RenderTarget9::RenderTarget9(Renderer *renderer, IDirect3DSurface9 *surface)
+{
+ mRenderer = Renderer9::makeRenderer9(renderer);
+ mRenderTarget = surface;
+
+ if (mRenderTarget)
+ {
+ D3DSURFACE_DESC description;
+ mRenderTarget->GetDesc(&description);
+
+ mWidth = description.Width;
+ mHeight = description.Height;
+
+ mInternalFormat = d3d9_gl::GetEquivalentFormat(description.Format);
+ mActualFormat = d3d9_gl::GetEquivalentFormat(description.Format);
+ mSamples = d3d9_gl::GetSamplesFromMultisampleType(description.MultiSampleType);
+ }
+}
+
+RenderTarget9::RenderTarget9(Renderer *renderer, GLsizei width, GLsizei height, GLenum format, GLsizei samples)
+{
+ mRenderer = Renderer9::makeRenderer9(renderer);
+ mRenderTarget = NULL;
+
+ D3DFORMAT requestedFormat = gl_d3d9::ConvertRenderbufferFormat(format);
+ int supportedSamples = mRenderer->getNearestSupportedSamples(requestedFormat, samples);
+
+ if (supportedSamples == -1)
+ {
+ gl::error(GL_OUT_OF_MEMORY);
+
+ return;
+ }
+
+ HRESULT result = D3DERR_INVALIDCALL;
+
+ if (width > 0 && height > 0)
+ {
+ if (requestedFormat == D3DFMT_D24S8)
+ {
+ result = mRenderer->getDevice()->CreateDepthStencilSurface(width, height, requestedFormat,
+ gl_d3d9::GetMultisampleTypeFromSamples(supportedSamples),
+ 0, FALSE, &mRenderTarget, NULL);
+ }
+ else
+ {
+ result = mRenderer->getDevice()->CreateRenderTarget(width, height, requestedFormat,
+ gl_d3d9::GetMultisampleTypeFromSamples(supportedSamples),
+ 0, FALSE, &mRenderTarget, NULL);
+ }
+
+ if (result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY)
+ {
+ gl::error(GL_OUT_OF_MEMORY);
+
+ return;
+ }
+
+ ASSERT(SUCCEEDED(result));
+ }
+
+ mWidth = width;
+ mHeight = height;
+ mInternalFormat = format;
+ mSamples = supportedSamples;
+ mActualFormat = d3d9_gl::GetEquivalentFormat(requestedFormat);
+}
+
+RenderTarget9::~RenderTarget9()
+{
+ if (mRenderTarget)
+ {
+ mRenderTarget->Release();
+ }
+}
+
+RenderTarget9 *RenderTarget9::makeRenderTarget9(RenderTarget *target)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(rx::RenderTarget9*, target));
+ return static_cast<rx::RenderTarget9*>(target);
+}
+
+IDirect3DSurface9 *RenderTarget9::getSurface()
+{
+ // Caller is responsible for releasing the returned surface reference.
+ if (mRenderTarget)
+ {
+ mRenderTarget->AddRef();
+ }
+
+ return mRenderTarget;
+}
+
+} \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget9.h b/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget9.h
new file mode 100644
index 0000000000..faf8ad1c6d
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/RenderTarget9.h
@@ -0,0 +1,40 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// RenderTarget9.h: Defines a D3D9-specific wrapper for IDirect3DSurface9 pointers
+// retained by Renderbuffers.
+
+#ifndef LIBGLESV2_RENDERER_RENDERTARGET9_H_
+#define LIBGLESV2_RENDERER_RENDERTARGET9_H_
+
+#include "libGLESv2/renderer/RenderTarget.h"
+
+namespace rx
+{
+class Renderer;
+class Renderer9;
+
+class RenderTarget9 : public RenderTarget
+{
+ public:
+ RenderTarget9(Renderer *renderer, IDirect3DSurface9 *surface);
+ RenderTarget9(Renderer *renderer, GLsizei width, GLsizei height, GLenum format, GLsizei samples);
+ virtual ~RenderTarget9();
+
+ static RenderTarget9 *makeRenderTarget9(RenderTarget *renderTarget);
+ IDirect3DSurface9 *getSurface();
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(RenderTarget9);
+
+ IDirect3DSurface9 *mRenderTarget;
+
+ Renderer9 *mRenderer;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_RENDERTARGET9_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Renderer.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer.cpp
new file mode 100644
index 0000000000..41cdb8b278
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer.cpp
@@ -0,0 +1,201 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Renderer.cpp: Implements EGL dependencies for creating and destroying Renderer instances.
+
+#include "libGLESv2/main.h"
+#include "libGLESv2/Program.h"
+#include "libGLESv2/renderer/Renderer.h"
+#if defined(ANGLE_ENABLE_D3D11)
+# include "libGLESv2/renderer/Renderer11.h"
+# define D3DERR_OUTOFVIDEOMEMORY MAKE_HRESULT( 1, 0x876, 380 )
+#else
+# include "libGLESv2/renderer/Renderer9.h"
+#endif
+#include "libGLESv2/utilities.h"
+
+#if !defined(ANGLE_COMPILE_OPTIMIZATION_LEVEL)
+#define ANGLE_COMPILE_OPTIMIZATION_LEVEL D3DCOMPILE_OPTIMIZATION_LEVEL3
+#endif
+
+namespace rx
+{
+
+Renderer::Renderer(egl::Display *display) : mDisplay(display)
+{
+ mD3dCompilerModule = NULL;
+ mD3DCompileFunc = NULL;
+}
+
+Renderer::~Renderer()
+{
+ if (mD3dCompilerModule)
+ {
+ FreeLibrary(mD3dCompilerModule);
+ mD3dCompilerModule = NULL;
+ }
+}
+
+bool Renderer::initializeCompiler()
+{
+#if defined(ANGLE_PRELOADED_D3DCOMPILER_MODULE_NAMES)
+ // Find a D3DCompiler module that had already been loaded based on a predefined list of versions.
+ static TCHAR* d3dCompilerNames[] = ANGLE_PRELOADED_D3DCOMPILER_MODULE_NAMES;
+
+ for (size_t i = 0; i < ArraySize(d3dCompilerNames); ++i)
+ {
+ if (GetModuleHandleEx(0, d3dCompilerNames[i], &mD3dCompilerModule))
+ {
+ break;
+ }
+ }
+#else
+ // Load the version of the D3DCompiler DLL associated with the Direct3D version ANGLE was built with.
+ mD3dCompilerModule = LoadLibrary(D3DCOMPILER_DLL);
+#endif // ANGLE_PRELOADED_D3DCOMPILER_MODULE_NAMES
+
+ if (!mD3dCompilerModule)
+ {
+ ERR("No D3D compiler module found - aborting!\n");
+ return false;
+ }
+
+ mD3DCompileFunc = reinterpret_cast<pCompileFunc>(GetProcAddress(mD3dCompilerModule, "D3DCompile"));
+ ASSERT(mD3DCompileFunc);
+
+ return mD3DCompileFunc != NULL;
+}
+
+// Compiles HLSL code into executable binaries
+ShaderBlob *Renderer::compileToBinary(gl::InfoLog &infoLog, const char *hlsl, const char *profile, UINT optimizationFlags, bool alternateFlags)
+{
+ if (!hlsl)
+ {
+ return NULL;
+ }
+
+ HRESULT result = S_OK;
+ UINT flags = 0;
+ std::string sourceText;
+ if (gl::perfActive())
+ {
+ flags |= D3DCOMPILE_DEBUG;
+
+#ifdef NDEBUG
+ flags |= optimizationFlags;
+#else
+ flags |= D3DCOMPILE_SKIP_OPTIMIZATION;
+#endif
+
+ std::string sourcePath = getTempPath();
+ sourceText = std::string("#line 2 \"") + sourcePath + std::string("\"\n\n") + std::string(hlsl);
+ writeFile(sourcePath.c_str(), sourceText.c_str(), sourceText.size());
+ }
+ else
+ {
+ flags |= optimizationFlags;
+ sourceText = hlsl;
+ }
+
+ // Sometimes D3DCompile will fail with the default compilation flags for complicated shaders when it would otherwise pass with alternative options.
+ // Try the default flags first and if compilation fails, try some alternatives.
+ const static UINT extraFlags[] =
+ {
+ 0,
+ D3DCOMPILE_AVOID_FLOW_CONTROL,
+ D3DCOMPILE_PREFER_FLOW_CONTROL
+ };
+
+ const static char * const extraFlagNames[] =
+ {
+ "default",
+ "avoid flow control",
+ "prefer flow control"
+ };
+
+ int attempts = alternateFlags ? ArraySize(extraFlags) : 1;
+ pD3DCompile compileFunc = reinterpret_cast<pD3DCompile>(mD3DCompileFunc);
+ for (int i = 0; i < attempts; ++i)
+ {
+ ID3DBlob *errorMessage = NULL;
+ ID3DBlob *binary = NULL;
+
+ result = compileFunc(hlsl, strlen(hlsl), gl::g_fakepath, NULL, NULL,
+ "main", profile, flags | extraFlags[i], 0, &binary, &errorMessage);
+ if (errorMessage)
+ {
+ const char *message = (const char*)errorMessage->GetBufferPointer();
+
+ infoLog.appendSanitized(message);
+ TRACE("\n%s", hlsl);
+ TRACE("\n%s", message);
+
+ errorMessage->Release();
+ errorMessage = NULL;
+ }
+
+ if (SUCCEEDED(result))
+ {
+ return (ShaderBlob*)binary;
+ }
+ else
+ {
+ if (result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY)
+ {
+ return gl::error(GL_OUT_OF_MEMORY, (ShaderBlob*) NULL);
+ }
+
+ infoLog.append("Warning: D3D shader compilation failed with ");
+ infoLog.append(extraFlagNames[i]);
+ infoLog.append(" flags.");
+ if (i + 1 < attempts)
+ {
+ infoLog.append(" Retrying with ");
+ infoLog.append(extraFlagNames[i + 1]);
+ infoLog.append(".\n");
+ }
+ }
+ }
+
+ return NULL;
+}
+
+}
+
+extern "C"
+{
+
+rx::Renderer *glCreateRenderer(egl::Display *display, HDC hDc, bool softwareDevice)
+{
+ rx::Renderer *renderer = NULL;
+ EGLint status = EGL_BAD_ALLOC;
+
+#if defined(ANGLE_ENABLE_D3D11)
+ renderer = new rx::Renderer11(display, hDc);
+#else
+ renderer = new rx::Renderer9(display, hDc, softwareDevice);
+#endif
+
+ if (renderer)
+ {
+ status = renderer->initialize();
+ }
+
+ if (status == EGL_SUCCESS)
+ {
+ return renderer;
+ }
+
+ return NULL;
+}
+
+void glDestroyRenderer(rx::Renderer *renderer)
+{
+ delete renderer;
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Renderer.h b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer.h
new file mode 100644
index 0000000000..656cb0f1bf
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer.h
@@ -0,0 +1,238 @@
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Renderer.h: Defines a back-end specific class that hides the details of the
+// implementation-specific renderer.
+
+#ifndef LIBGLESV2_RENDERER_RENDERER_H_
+#define LIBGLESV2_RENDERER_RENDERER_H_
+
+#include "libGLESv2/Uniform.h"
+#include "libGLESv2/angletypes.h"
+
+const int versionWindowsVista = MAKEWORD(0x00, 0x06);
+const int versionWindows7 = MAKEWORD(0x01, 0x06);
+
+// Return the version of the operating system in a format suitable for ordering
+// comparison.
+inline int getComparableOSVersion()
+{
+ DWORD version = GetVersion();
+ int majorVersion = LOBYTE(LOWORD(version));
+ int minorVersion = HIBYTE(LOWORD(version));
+ return MAKEWORD(minorVersion, majorVersion);
+}
+
+namespace egl
+{
+class Display;
+}
+
+namespace gl
+{
+class InfoLog;
+class ProgramBinary;
+class VertexAttribute;
+class Buffer;
+class Texture;
+class Framebuffer;
+}
+
+namespace rx
+{
+class TextureStorageInterface2D;
+class TextureStorageInterfaceCube;
+class VertexBuffer;
+class IndexBuffer;
+class QueryImpl;
+class FenceImpl;
+class BufferStorage;
+class Blit;
+struct TranslatedIndexData;
+class ShaderExecutable;
+class SwapChain;
+class RenderTarget;
+class Image;
+class TextureStorage;
+
+typedef void * ShaderBlob;
+typedef void (*pCompileFunc)();
+
+struct ConfigDesc
+{
+ GLenum renderTargetFormat;
+ GLenum depthStencilFormat;
+ GLint multiSample;
+ bool fastConfig;
+};
+
+struct dx_VertexConstants
+{
+ float depthRange[4];
+ float viewAdjust[4];
+};
+
+struct dx_PixelConstants
+{
+ float depthRange[4];
+ float viewCoords[4];
+ float depthFront[4];
+};
+
+enum ShaderType
+{
+ SHADER_VERTEX,
+ SHADER_PIXEL,
+ SHADER_GEOMETRY
+};
+
+class Renderer
+{
+ public:
+ explicit Renderer(egl::Display *display);
+ virtual ~Renderer();
+
+ virtual EGLint initialize() = 0;
+ virtual bool resetDevice() = 0;
+
+ virtual int generateConfigs(ConfigDesc **configDescList) = 0;
+ virtual void deleteConfigs(ConfigDesc *configDescList) = 0;
+
+ virtual void sync(bool block) = 0;
+
+ virtual SwapChain *createSwapChain(HWND window, HANDLE shareHandle, GLenum backBufferFormat, GLenum depthBufferFormat) = 0;
+
+ virtual void setSamplerState(gl::SamplerType type, int index, const gl::SamplerState &sampler) = 0;
+ virtual void setTexture(gl::SamplerType type, int index, gl::Texture *texture) = 0;
+
+ virtual void setRasterizerState(const gl::RasterizerState &rasterState) = 0;
+ virtual void setBlendState(const gl::BlendState &blendState, const gl::Color &blendColor,
+ unsigned int sampleMask) = 0;
+ virtual void setDepthStencilState(const gl::DepthStencilState &depthStencilState, int stencilRef,
+ int stencilBackRef, bool frontFaceCCW) = 0;
+
+ virtual void setScissorRectangle(const gl::Rectangle &scissor, bool enabled) = 0;
+ virtual bool setViewport(const gl::Rectangle &viewport, float zNear, float zFar, GLenum drawMode, GLenum frontFace,
+ bool ignoreViewport) = 0;
+
+ virtual bool applyRenderTarget(gl::Framebuffer *frameBuffer) = 0;
+ virtual void applyShaders(gl::ProgramBinary *programBinary) = 0;
+ virtual void applyUniforms(gl::ProgramBinary *programBinary, gl::UniformArray *uniformArray) = 0;
+ virtual bool applyPrimitiveType(GLenum primitiveType, GLsizei elementCount) = 0;
+ virtual GLenum applyVertexBuffer(gl::ProgramBinary *programBinary, gl::VertexAttribute vertexAttributes[], GLint first, GLsizei count, GLsizei instances) = 0;
+ virtual GLenum applyIndexBuffer(const GLvoid *indices, gl::Buffer *elementArrayBuffer, GLsizei count, GLenum mode, GLenum type, TranslatedIndexData *indexInfo) = 0;
+
+ virtual void drawArrays(GLenum mode, GLsizei count, GLsizei instances) = 0;
+ virtual void drawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, gl::Buffer *elementArrayBuffer, const TranslatedIndexData &indexInfo, GLsizei instances) = 0;
+
+ virtual void clear(const gl::ClearParameters &clearParams, gl::Framebuffer *frameBuffer) = 0;
+
+ virtual void markAllStateDirty() = 0;
+
+ // lost device
+ virtual void notifyDeviceLost() = 0;
+ virtual bool isDeviceLost() = 0;
+ virtual bool testDeviceLost(bool notify) = 0;
+ virtual bool testDeviceResettable() = 0;
+
+ // Renderer capabilities
+ virtual DWORD getAdapterVendor() const = 0;
+ virtual std::string getRendererDescription() const = 0;
+ virtual GUID getAdapterIdentifier() const = 0;
+
+ virtual bool getBGRATextureSupport() const = 0;
+ virtual bool getDXT1TextureSupport() = 0;
+ virtual bool getDXT3TextureSupport() = 0;
+ virtual bool getDXT5TextureSupport() = 0;
+ virtual bool getEventQuerySupport() = 0;
+ virtual bool getFloat32TextureSupport(bool *filtering, bool *renderable) = 0;
+ virtual bool getFloat16TextureSupport(bool *filtering, bool *renderable) = 0;
+ virtual bool getLuminanceTextureSupport() = 0;
+ virtual bool getLuminanceAlphaTextureSupport() = 0;
+ bool getVertexTextureSupport() const { return getMaxVertexTextureImageUnits() > 0; }
+ virtual unsigned int getMaxVertexTextureImageUnits() const = 0;
+ virtual unsigned int getMaxCombinedTextureImageUnits() const = 0;
+ virtual unsigned int getReservedVertexUniformVectors() const = 0;
+ virtual unsigned int getReservedFragmentUniformVectors() const = 0;
+ virtual unsigned int getMaxVertexUniformVectors() const = 0;
+ virtual unsigned int getMaxFragmentUniformVectors() const = 0;
+ virtual unsigned int getMaxVaryingVectors() const = 0;
+ virtual bool getNonPower2TextureSupport() const = 0;
+ virtual bool getDepthTextureSupport() const = 0;
+ virtual bool getOcclusionQuerySupport() const = 0;
+ virtual bool getInstancingSupport() const = 0;
+ virtual bool getTextureFilterAnisotropySupport() const = 0;
+ virtual float getTextureMaxAnisotropy() const = 0;
+ virtual bool getShareHandleSupport() const = 0;
+ virtual bool getDerivativeInstructionSupport() const = 0;
+ virtual bool getPostSubBufferSupport() const = 0;
+
+ virtual int getMajorShaderModel() const = 0;
+ virtual float getMaxPointSize() const = 0;
+ virtual int getMaxViewportDimension() const = 0;
+ virtual int getMaxTextureWidth() const = 0;
+ virtual int getMaxTextureHeight() const = 0;
+ virtual bool get32BitIndexSupport() const = 0;
+ virtual int getMinSwapInterval() const = 0;
+ virtual int getMaxSwapInterval() const = 0;
+
+ virtual GLsizei getMaxSupportedSamples() const = 0;
+
+ virtual unsigned int getMaxRenderTargets() const = 0;
+
+ // Pixel operations
+ virtual bool copyToRenderTarget(TextureStorageInterface2D *dest, TextureStorageInterface2D *source) = 0;
+ virtual bool copyToRenderTarget(TextureStorageInterfaceCube *dest, TextureStorageInterfaceCube *source) = 0;
+
+ virtual bool copyImage(gl::Framebuffer *framebuffer, const gl::Rectangle &sourceRect, GLenum destFormat,
+ GLint xoffset, GLint yoffset, TextureStorageInterface2D *storage, GLint level) = 0;
+ virtual bool copyImage(gl::Framebuffer *framebuffer, const gl::Rectangle &sourceRect, GLenum destFormat,
+ GLint xoffset, GLint yoffset, TextureStorageInterfaceCube *storage, GLenum target, GLint level) = 0;
+
+ virtual bool blitRect(gl::Framebuffer *readTarget, const gl::Rectangle &readRect, gl::Framebuffer *drawTarget, const gl::Rectangle &drawRect,
+ bool blitRenderTarget, bool blitDepthStencil) = 0;
+ virtual void readPixels(gl::Framebuffer *framebuffer, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type,
+ GLsizei outputPitch, bool packReverseRowOrder, GLint packAlignment, void* pixels) = 0;
+
+ // RenderTarget creation
+ virtual RenderTarget *createRenderTarget(SwapChain *swapChain, bool depth) = 0;
+ virtual RenderTarget *createRenderTarget(int width, int height, GLenum format, GLsizei samples, bool depth) = 0;
+
+ // Shader operations
+ virtual ShaderExecutable *loadExecutable(const void *function, size_t length, rx::ShaderType type) = 0;
+ virtual ShaderExecutable *compileToExecutable(gl::InfoLog &infoLog, const char *shaderHLSL, rx::ShaderType type) = 0;
+
+ // Image operations
+ virtual Image *createImage() = 0;
+ virtual void generateMipmap(Image *dest, Image *source) = 0;
+ virtual TextureStorage *createTextureStorage2D(SwapChain *swapChain) = 0;
+ virtual TextureStorage *createTextureStorage2D(int levels, GLenum internalformat, GLenum usage, bool forceRenderable, GLsizei width, GLsizei height) = 0;
+ virtual TextureStorage *createTextureStorageCube(int levels, GLenum internalformat, GLenum usage, bool forceRenderable, int size) = 0;
+
+ // Buffer creation
+ virtual VertexBuffer *createVertexBuffer() = 0;
+ virtual IndexBuffer *createIndexBuffer() = 0;
+ virtual BufferStorage *createBufferStorage() = 0;
+
+ // Query and Fence creation
+ virtual QueryImpl *createQuery(GLenum type) = 0;
+ virtual FenceImpl *createFence() = 0;
+
+ protected:
+ bool initializeCompiler();
+ ShaderBlob *compileToBinary(gl::InfoLog &infoLog, const char *hlsl, const char *profile, UINT optimizationFlags, bool alternateFlags);
+
+ egl::Display *mDisplay;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(Renderer);
+
+ HMODULE mD3dCompilerModule;
+ pCompileFunc mD3DCompileFunc;
+};
+
+}
+#endif // LIBGLESV2_RENDERER_RENDERER_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Renderer11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer11.cpp
new file mode 100644
index 0000000000..cf083963e1
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer11.cpp
@@ -0,0 +1,3531 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Renderer11.cpp: Implements a back-end specific class for the D3D11 renderer.
+
+#include "libGLESv2/main.h"
+#include "libGLESv2/utilities.h"
+#include "libGLESv2/Buffer.h"
+#include "libGLESv2/ProgramBinary.h"
+#include "libGLESv2/Framebuffer.h"
+#include "libGLESv2/RenderBuffer.h"
+#include "libGLESv2/renderer/Renderer11.h"
+#include "libGLESv2/renderer/RenderTarget11.h"
+#include "libGLESv2/renderer/renderer11_utils.h"
+#include "libGLESv2/renderer/ShaderExecutable11.h"
+#include "libGLESv2/renderer/SwapChain11.h"
+#include "libGLESv2/renderer/Image11.h"
+#include "libGLESv2/renderer/VertexBuffer11.h"
+#include "libGLESv2/renderer/IndexBuffer11.h"
+#include "libGLESv2/renderer/BufferStorage11.h"
+#include "libGLESv2/renderer/VertexDataManager.h"
+#include "libGLESv2/renderer/IndexDataManager.h"
+#include "libGLESv2/renderer/TextureStorage11.h"
+#include "libGLESv2/renderer/Query11.h"
+#include "libGLESv2/renderer/Fence11.h"
+
+#include "libGLESv2/renderer/shaders/compiled/passthrough11vs.h"
+#include "libGLESv2/renderer/shaders/compiled/passthroughrgba11ps.h"
+#include "libGLESv2/renderer/shaders/compiled/passthroughrgb11ps.h"
+#include "libGLESv2/renderer/shaders/compiled/passthroughlum11ps.h"
+#include "libGLESv2/renderer/shaders/compiled/passthroughlumalpha11ps.h"
+
+#include "libGLESv2/renderer/shaders/compiled/clear11vs.h"
+#include "libGLESv2/renderer/shaders/compiled/clear11ps.h"
+
+#include "libEGL/Display.h"
+
+#ifdef _DEBUG
+// this flag enables suppressing some spurious warnings that pop up in certain WebGL samples
+// and conformance tests. to enable all warnings, remove this define.
+#define ANGLE_SUPPRESS_D3D11_HAZARD_WARNINGS 1
+#endif
+
+namespace rx
+{
+static const DXGI_FORMAT RenderTargetFormats[] =
+ {
+ DXGI_FORMAT_B8G8R8A8_UNORM,
+ DXGI_FORMAT_R8G8B8A8_UNORM
+ };
+
+static const DXGI_FORMAT DepthStencilFormats[] =
+ {
+ DXGI_FORMAT_UNKNOWN,
+ DXGI_FORMAT_D24_UNORM_S8_UINT,
+ DXGI_FORMAT_D16_UNORM
+ };
+
+enum
+{
+ MAX_TEXTURE_IMAGE_UNITS_VTF_SM4 = 16
+};
+
+Renderer11::Renderer11(egl::Display *display, HDC hDc) : Renderer(display), mDc(hDc)
+{
+ mVertexDataManager = NULL;
+ mIndexDataManager = NULL;
+
+ mLineLoopIB = NULL;
+ mTriangleFanIB = NULL;
+
+ mCopyResourcesInitialized = false;
+ mCopyVB = NULL;
+ mCopySampler = NULL;
+ mCopyIL = NULL;
+ mCopyVS = NULL;
+ mCopyRGBAPS = NULL;
+ mCopyRGBPS = NULL;
+ mCopyLumPS = NULL;
+ mCopyLumAlphaPS = NULL;
+
+ mClearResourcesInitialized = false;
+ mClearVB = NULL;
+ mClearIL = NULL;
+ mClearVS = NULL;
+ mClearPS = NULL;
+ mClearScissorRS = NULL;
+ mClearNoScissorRS = NULL;
+
+ mSyncQuery = NULL;
+
+ mD3d11Module = NULL;
+ mDxgiModule = NULL;
+
+ mDeviceLost = false;
+
+ mMaxSupportedSamples = 0;
+
+ mDevice = NULL;
+ mDeviceContext = NULL;
+ mDxgiAdapter = NULL;
+ mDxgiFactory = NULL;
+
+ mDriverConstantBufferVS = NULL;
+ mDriverConstantBufferPS = NULL;
+
+ mBGRATextureSupport = false;
+
+ mIsGeometryShaderActive = false;
+}
+
+Renderer11::~Renderer11()
+{
+ release();
+}
+
+Renderer11 *Renderer11::makeRenderer11(Renderer *renderer)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(rx::Renderer11*, renderer));
+ return static_cast<rx::Renderer11*>(renderer);
+}
+
+#ifndef __d3d11_1_h__
+#define D3D11_MESSAGE_ID_DEVICE_DRAW_RENDERTARGETVIEW_NOT_SET ((D3D11_MESSAGE_ID)3146081)
+#endif
+
+EGLint Renderer11::initialize()
+{
+ if (!initializeCompiler())
+ {
+ return EGL_NOT_INITIALIZED;
+ }
+
+ mDxgiModule = LoadLibrary(TEXT("dxgi.dll"));
+ mD3d11Module = LoadLibrary(TEXT("d3d11.dll"));
+
+ if (mD3d11Module == NULL || mDxgiModule == NULL)
+ {
+ ERR("Could not load D3D11 or DXGI library - aborting!\n");
+ return EGL_NOT_INITIALIZED;
+ }
+
+ // create the D3D11 device
+ ASSERT(mDevice == NULL);
+ PFN_D3D11_CREATE_DEVICE D3D11CreateDevice = (PFN_D3D11_CREATE_DEVICE)GetProcAddress(mD3d11Module, "D3D11CreateDevice");
+
+ if (D3D11CreateDevice == NULL)
+ {
+ ERR("Could not retrieve D3D11CreateDevice address - aborting!\n");
+ return EGL_NOT_INITIALIZED;
+ }
+
+ D3D_FEATURE_LEVEL featureLevels[] =
+ {
+ D3D_FEATURE_LEVEL_11_0,
+ D3D_FEATURE_LEVEL_10_1,
+ D3D_FEATURE_LEVEL_10_0,
+ };
+
+ HRESULT result = D3D11CreateDevice(NULL,
+ D3D_DRIVER_TYPE_HARDWARE,
+ NULL,
+ #if defined(_DEBUG)
+ D3D11_CREATE_DEVICE_DEBUG,
+ #else
+ 0,
+ #endif
+ featureLevels,
+ ArraySize(featureLevels),
+ D3D11_SDK_VERSION,
+ &mDevice,
+ &mFeatureLevel,
+ &mDeviceContext);
+
+ if (!mDevice || FAILED(result))
+ {
+ ERR("Could not create D3D11 device - aborting!\n");
+ return EGL_NOT_INITIALIZED; // Cleanup done by destructor through glDestroyRenderer
+ }
+
+ IDXGIDevice *dxgiDevice = NULL;
+ result = mDevice->QueryInterface(__uuidof(IDXGIDevice), (void**)&dxgiDevice);
+
+ if (FAILED(result))
+ {
+ ERR("Could not query DXGI device - aborting!\n");
+ return EGL_NOT_INITIALIZED;
+ }
+
+ result = dxgiDevice->GetParent(__uuidof(IDXGIAdapter), (void**)&mDxgiAdapter);
+
+ if (FAILED(result))
+ {
+ ERR("Could not retrieve DXGI adapter - aborting!\n");
+ return EGL_NOT_INITIALIZED;
+ }
+
+ dxgiDevice->Release();
+
+ mDxgiAdapter->GetDesc(&mAdapterDescription);
+ memset(mDescription, 0, sizeof(mDescription));
+ wcstombs(mDescription, mAdapterDescription.Description, sizeof(mDescription) - 1);
+
+ result = mDxgiAdapter->GetParent(__uuidof(IDXGIFactory), (void**)&mDxgiFactory);
+
+ if (!mDxgiFactory || FAILED(result))
+ {
+ ERR("Could not create DXGI factory - aborting!\n");
+ return EGL_NOT_INITIALIZED;
+ }
+
+ // Disable some spurious D3D11 debug warnings to prevent them from flooding the output log
+#if defined(ANGLE_SUPPRESS_D3D11_HAZARD_WARNINGS) && defined(_DEBUG)
+ ID3D11InfoQueue *infoQueue;
+ result = mDevice->QueryInterface(__uuidof(ID3D11InfoQueue), (void **)&infoQueue);
+
+ if (SUCCEEDED(result))
+ {
+ D3D11_MESSAGE_ID hideMessages[] =
+ {
+ D3D11_MESSAGE_ID_DEVICE_OMSETRENDERTARGETS_HAZARD,
+ D3D11_MESSAGE_ID_DEVICE_PSSETSHADERRESOURCES_HAZARD,
+ D3D11_MESSAGE_ID_DEVICE_DRAW_RENDERTARGETVIEW_NOT_SET
+ };
+
+ D3D11_INFO_QUEUE_FILTER filter = {0};
+ filter.DenyList.NumIDs = ArraySize(hideMessages);
+ filter.DenyList.pIDList = hideMessages;
+
+ infoQueue->AddStorageFilterEntries(&filter);
+
+ infoQueue->Release();
+ }
+#endif
+
+ unsigned int maxSupportedSamples = 0;
+ unsigned int rtFormatCount = ArraySize(RenderTargetFormats);
+ unsigned int dsFormatCount = ArraySize(DepthStencilFormats);
+ for (unsigned int i = 0; i < rtFormatCount + dsFormatCount; ++i)
+ {
+ DXGI_FORMAT format = (i < rtFormatCount) ? RenderTargetFormats[i] : DepthStencilFormats[i - rtFormatCount];
+ if (format != DXGI_FORMAT_UNKNOWN)
+ {
+ UINT formatSupport;
+ result = mDevice->CheckFormatSupport(format, &formatSupport);
+ if (SUCCEEDED(result) && (formatSupport & D3D11_FORMAT_SUPPORT_MULTISAMPLE_RENDERTARGET))
+ {
+ MultisampleSupportInfo supportInfo;
+
+ for (unsigned int j = 1; j <= D3D11_MAX_MULTISAMPLE_SAMPLE_COUNT; j++)
+ {
+ result = mDevice->CheckMultisampleQualityLevels(format, j, &supportInfo.qualityLevels[j - 1]);
+ if (SUCCEEDED(result) && supportInfo.qualityLevels[j - 1] > 0)
+ {
+ maxSupportedSamples = std::max(j, maxSupportedSamples);
+ }
+ else
+ {
+ supportInfo.qualityLevels[j - 1] = 0;
+ }
+ }
+
+ mMultisampleSupportMap.insert(std::make_pair(format, supportInfo));
+ }
+ }
+ }
+ mMaxSupportedSamples = maxSupportedSamples;
+
+ initializeDevice();
+
+ // BGRA texture support is optional in feature levels 10 and 10_1
+ UINT formatSupport;
+ result = mDevice->CheckFormatSupport(DXGI_FORMAT_B8G8R8A8_UNORM, &formatSupport);
+ if (FAILED(result))
+ {
+ ERR("Error checking BGRA format support: 0x%08X", result);
+ }
+ else
+ {
+ const int flags = (D3D11_FORMAT_SUPPORT_TEXTURE2D | D3D11_FORMAT_SUPPORT_RENDER_TARGET);
+ mBGRATextureSupport = (formatSupport & flags) == flags;
+ }
+
+ // Check floating point texture support
+ static const unsigned int requiredTextureFlags = D3D11_FORMAT_SUPPORT_TEXTURE2D | D3D11_FORMAT_SUPPORT_TEXTURECUBE;
+ static const unsigned int requiredRenderableFlags = D3D11_FORMAT_SUPPORT_RENDER_TARGET;
+ static const unsigned int requiredFilterFlags = D3D11_FORMAT_SUPPORT_SHADER_SAMPLE;
+
+ DXGI_FORMAT float16Formats[] =
+ {
+ DXGI_FORMAT_R16_FLOAT,
+ DXGI_FORMAT_R16G16_FLOAT,
+ DXGI_FORMAT_R16G16B16A16_FLOAT,
+ };
+
+ DXGI_FORMAT float32Formats[] =
+ {
+ DXGI_FORMAT_R32_FLOAT,
+ DXGI_FORMAT_R32G32_FLOAT,
+ DXGI_FORMAT_R32G32B32_FLOAT,
+ DXGI_FORMAT_R32G32B32A32_FLOAT,
+ };
+
+ mFloat16TextureSupport = true;
+ mFloat16FilterSupport = true;
+ mFloat16RenderSupport = true;
+ for (unsigned int i = 0; i < ArraySize(float16Formats); i++)
+ {
+ if (SUCCEEDED(mDevice->CheckFormatSupport(float16Formats[i], &formatSupport)))
+ {
+ mFloat16TextureSupport = mFloat16TextureSupport && (formatSupport & requiredTextureFlags) == requiredTextureFlags;
+ mFloat16FilterSupport = mFloat16FilterSupport && (formatSupport & requiredFilterFlags) == requiredFilterFlags;
+ mFloat16RenderSupport = mFloat16RenderSupport && (formatSupport & requiredRenderableFlags) == requiredRenderableFlags;
+ }
+ else
+ {
+ mFloat16TextureSupport = false;
+ mFloat16RenderSupport = false;
+ mFloat16FilterSupport = false;
+ }
+ }
+
+ mFloat32TextureSupport = true;
+ mFloat32FilterSupport = true;
+ mFloat32RenderSupport = true;
+ for (unsigned int i = 0; i < ArraySize(float32Formats); i++)
+ {
+ if (SUCCEEDED(mDevice->CheckFormatSupport(float32Formats[i], &formatSupport)))
+ {
+ mFloat32TextureSupport = mFloat32TextureSupport && (formatSupport & requiredTextureFlags) == requiredTextureFlags;
+ mFloat32FilterSupport = mFloat32FilterSupport && (formatSupport & requiredFilterFlags) == requiredFilterFlags;
+ mFloat32RenderSupport = mFloat32RenderSupport && (formatSupport & requiredRenderableFlags) == requiredRenderableFlags;
+ }
+ else
+ {
+ mFloat32TextureSupport = false;
+ mFloat32FilterSupport = false;
+ mFloat32RenderSupport = false;
+ }
+ }
+
+ // Check compressed texture support
+ const unsigned int requiredCompressedTextureFlags = D3D11_FORMAT_SUPPORT_TEXTURE2D;
+
+ if (SUCCEEDED(mDevice->CheckFormatSupport(DXGI_FORMAT_BC1_UNORM, &formatSupport)))
+ {
+ mDXT1TextureSupport = (formatSupport & requiredCompressedTextureFlags) == requiredCompressedTextureFlags;
+ }
+ else
+ {
+ mDXT1TextureSupport = false;
+ }
+
+ if (SUCCEEDED(mDevice->CheckFormatSupport(DXGI_FORMAT_BC3_UNORM, &formatSupport)))
+ {
+ mDXT3TextureSupport = (formatSupport & requiredCompressedTextureFlags) == requiredCompressedTextureFlags;
+ }
+ else
+ {
+ mDXT3TextureSupport = false;
+ }
+
+ if (SUCCEEDED(mDevice->CheckFormatSupport(DXGI_FORMAT_BC5_UNORM, &formatSupport)))
+ {
+ mDXT5TextureSupport = (formatSupport & requiredCompressedTextureFlags) == requiredCompressedTextureFlags;
+ }
+ else
+ {
+ mDXT5TextureSupport = false;
+ }
+
+ // Check depth texture support
+ DXGI_FORMAT depthTextureFormats[] =
+ {
+ DXGI_FORMAT_D16_UNORM,
+ DXGI_FORMAT_D24_UNORM_S8_UINT,
+ };
+
+ static const unsigned int requiredDepthTextureFlags = D3D11_FORMAT_SUPPORT_DEPTH_STENCIL |
+ D3D11_FORMAT_SUPPORT_TEXTURE2D;
+
+ mDepthTextureSupport = true;
+ for (unsigned int i = 0; i < ArraySize(depthTextureFormats); i++)
+ {
+ if (SUCCEEDED(mDevice->CheckFormatSupport(depthTextureFormats[i], &formatSupport)))
+ {
+ mDepthTextureSupport = mDepthTextureSupport && ((formatSupport & requiredDepthTextureFlags) == requiredDepthTextureFlags);
+ }
+ else
+ {
+ mDepthTextureSupport = false;
+ }
+ }
+
+ return EGL_SUCCESS;
+}
+
+// do any one-time device initialization
+// NOTE: this is also needed after a device lost/reset
+// to reset the scene status and ensure the default states are reset.
+void Renderer11::initializeDevice()
+{
+ mStateCache.initialize(mDevice);
+ mInputLayoutCache.initialize(mDevice, mDeviceContext);
+
+ ASSERT(!mVertexDataManager && !mIndexDataManager);
+ mVertexDataManager = new VertexDataManager(this);
+ mIndexDataManager = new IndexDataManager(this);
+
+ markAllStateDirty();
+}
+
+int Renderer11::generateConfigs(ConfigDesc **configDescList)
+{
+ unsigned int numRenderFormats = ArraySize(RenderTargetFormats);
+ unsigned int numDepthFormats = ArraySize(DepthStencilFormats);
+ (*configDescList) = new ConfigDesc[numRenderFormats * numDepthFormats];
+ int numConfigs = 0;
+
+ for (unsigned int formatIndex = 0; formatIndex < numRenderFormats; formatIndex++)
+ {
+ for (unsigned int depthStencilIndex = 0; depthStencilIndex < numDepthFormats; depthStencilIndex++)
+ {
+ DXGI_FORMAT renderTargetFormat = RenderTargetFormats[formatIndex];
+
+ UINT formatSupport = 0;
+ HRESULT result = mDevice->CheckFormatSupport(renderTargetFormat, &formatSupport);
+
+ if (SUCCEEDED(result) && (formatSupport & D3D11_FORMAT_SUPPORT_RENDER_TARGET))
+ {
+ DXGI_FORMAT depthStencilFormat = DepthStencilFormats[depthStencilIndex];
+
+ bool depthStencilFormatOK = true;
+
+ if (depthStencilFormat != DXGI_FORMAT_UNKNOWN)
+ {
+ UINT formatSupport = 0;
+ result = mDevice->CheckFormatSupport(depthStencilFormat, &formatSupport);
+ depthStencilFormatOK = SUCCEEDED(result) && (formatSupport & D3D11_FORMAT_SUPPORT_DEPTH_STENCIL);
+ }
+
+ if (depthStencilFormatOK)
+ {
+ ConfigDesc newConfig;
+ newConfig.renderTargetFormat = d3d11_gl::ConvertBackBufferFormat(renderTargetFormat);
+ newConfig.depthStencilFormat = d3d11_gl::ConvertDepthStencilFormat(depthStencilFormat);
+ newConfig.multiSample = 0; // FIXME: enumerate multi-sampling
+ newConfig.fastConfig = true; // Assume all DX11 format conversions to be fast
+
+ (*configDescList)[numConfigs++] = newConfig;
+ }
+ }
+ }
+ }
+
+ return numConfigs;
+}
+
+void Renderer11::deleteConfigs(ConfigDesc *configDescList)
+{
+ delete [] (configDescList);
+}
+
+void Renderer11::sync(bool block)
+{
+ if (block)
+ {
+ HRESULT result;
+
+ if (!mSyncQuery)
+ {
+ D3D11_QUERY_DESC queryDesc;
+ queryDesc.Query = D3D11_QUERY_EVENT;
+ queryDesc.MiscFlags = 0;
+
+ result = mDevice->CreateQuery(&queryDesc, &mSyncQuery);
+ ASSERT(SUCCEEDED(result));
+ }
+
+ mDeviceContext->End(mSyncQuery);
+ mDeviceContext->Flush();
+
+ do
+ {
+ result = mDeviceContext->GetData(mSyncQuery, NULL, 0, D3D11_ASYNC_GETDATA_DONOTFLUSH);
+
+ // Keep polling, but allow other threads to do something useful first
+ Sleep(0);
+
+ if (testDeviceLost(true))
+ {
+ return;
+ }
+ }
+ while (result == S_FALSE);
+ }
+ else
+ {
+ mDeviceContext->Flush();
+ }
+}
+
+SwapChain *Renderer11::createSwapChain(HWND window, HANDLE shareHandle, GLenum backBufferFormat, GLenum depthBufferFormat)
+{
+ return new rx::SwapChain11(this, window, shareHandle, backBufferFormat, depthBufferFormat);
+}
+
+void Renderer11::setSamplerState(gl::SamplerType type, int index, const gl::SamplerState &samplerState)
+{
+ if (type == gl::SAMPLER_PIXEL)
+ {
+ if (index < 0 || index >= gl::MAX_TEXTURE_IMAGE_UNITS)
+ {
+ ERR("Pixel shader sampler index %i is not valid.", index);
+ return;
+ }
+
+ if (mForceSetPixelSamplerStates[index] || memcmp(&samplerState, &mCurPixelSamplerStates[index], sizeof(gl::SamplerState)) != 0)
+ {
+ ID3D11SamplerState *dxSamplerState = mStateCache.getSamplerState(samplerState);
+
+ if (!dxSamplerState)
+ {
+ ERR("NULL sampler state returned by RenderStateCache::getSamplerState, setting the default"
+ "sampler state for pixel shaders at slot %i.", index);
+ }
+
+ mDeviceContext->PSSetSamplers(index, 1, &dxSamplerState);
+
+ mCurPixelSamplerStates[index] = samplerState;
+ }
+
+ mForceSetPixelSamplerStates[index] = false;
+ }
+ else if (type == gl::SAMPLER_VERTEX)
+ {
+ if (index < 0 || index >= (int)getMaxVertexTextureImageUnits())
+ {
+ ERR("Vertex shader sampler index %i is not valid.", index);
+ return;
+ }
+
+ if (mForceSetVertexSamplerStates[index] || memcmp(&samplerState, &mCurVertexSamplerStates[index], sizeof(gl::SamplerState)) != 0)
+ {
+ ID3D11SamplerState *dxSamplerState = mStateCache.getSamplerState(samplerState);
+
+ if (!dxSamplerState)
+ {
+ ERR("NULL sampler state returned by RenderStateCache::getSamplerState, setting the default"
+ "sampler state for vertex shaders at slot %i.", index);
+ }
+
+ mDeviceContext->VSSetSamplers(index, 1, &dxSamplerState);
+
+ mCurVertexSamplerStates[index] = samplerState;
+ }
+
+ mForceSetVertexSamplerStates[index] = false;
+ }
+ else UNREACHABLE();
+}
+
+void Renderer11::setTexture(gl::SamplerType type, int index, gl::Texture *texture)
+{
+ ID3D11ShaderResourceView *textureSRV = NULL;
+ unsigned int serial = 0;
+ bool forceSetTexture = false;
+
+ if (texture)
+ {
+ TextureStorageInterface *texStorage = texture->getNativeTexture();
+ if (texStorage)
+ {
+ TextureStorage11 *storage11 = TextureStorage11::makeTextureStorage11(texStorage->getStorageInstance());
+ textureSRV = storage11->getSRV();
+ }
+
+ // If we get NULL back from getSRV here, something went wrong in the texture class and we're unexpectedly
+ // missing the shader resource view
+ ASSERT(textureSRV != NULL);
+
+ serial = texture->getTextureSerial();
+ forceSetTexture = texture->hasDirtyImages();
+ }
+
+ if (type == gl::SAMPLER_PIXEL)
+ {
+ if (index < 0 || index >= gl::MAX_TEXTURE_IMAGE_UNITS)
+ {
+ ERR("Pixel shader sampler index %i is not valid.", index);
+ return;
+ }
+
+ if (forceSetTexture || mCurPixelTextureSerials[index] != serial)
+ {
+ mDeviceContext->PSSetShaderResources(index, 1, &textureSRV);
+ }
+
+ mCurPixelTextureSerials[index] = serial;
+ }
+ else if (type == gl::SAMPLER_VERTEX)
+ {
+ if (index < 0 || index >= (int)getMaxVertexTextureImageUnits())
+ {
+ ERR("Vertex shader sampler index %i is not valid.", index);
+ return;
+ }
+
+ if (forceSetTexture || mCurVertexTextureSerials[index] != serial)
+ {
+ mDeviceContext->VSSetShaderResources(index, 1, &textureSRV);
+ }
+
+ mCurVertexTextureSerials[index] = serial;
+ }
+ else UNREACHABLE();
+}
+
+void Renderer11::setRasterizerState(const gl::RasterizerState &rasterState)
+{
+ if (mForceSetRasterState || memcmp(&rasterState, &mCurRasterState, sizeof(gl::RasterizerState)) != 0)
+ {
+ ID3D11RasterizerState *dxRasterState = mStateCache.getRasterizerState(rasterState, mScissorEnabled,
+ mCurDepthSize);
+ if (!dxRasterState)
+ {
+ ERR("NULL rasterizer state returned by RenderStateCache::getRasterizerState, setting the default"
+ "rasterizer state.");
+ }
+
+ mDeviceContext->RSSetState(dxRasterState);
+
+ mCurRasterState = rasterState;
+ }
+
+ mForceSetRasterState = false;
+}
+
+void Renderer11::setBlendState(const gl::BlendState &blendState, const gl::Color &blendColor,
+ unsigned int sampleMask)
+{
+ if (mForceSetBlendState ||
+ memcmp(&blendState, &mCurBlendState, sizeof(gl::BlendState)) != 0 ||
+ memcmp(&blendColor, &mCurBlendColor, sizeof(gl::Color)) != 0 ||
+ sampleMask != mCurSampleMask)
+ {
+ ID3D11BlendState *dxBlendState = mStateCache.getBlendState(blendState);
+ if (!dxBlendState)
+ {
+ ERR("NULL blend state returned by RenderStateCache::getBlendState, setting the default "
+ "blend state.");
+ }
+
+ const float blendColors[] = { blendColor.red, blendColor.green, blendColor.blue, blendColor.alpha };
+ mDeviceContext->OMSetBlendState(dxBlendState, blendColors, sampleMask);
+
+ mCurBlendState = blendState;
+ mCurBlendColor = blendColor;
+ mCurSampleMask = sampleMask;
+ }
+
+ mForceSetBlendState = false;
+}
+
+void Renderer11::setDepthStencilState(const gl::DepthStencilState &depthStencilState, int stencilRef,
+ int stencilBackRef, bool frontFaceCCW)
+{
+ if (mForceSetDepthStencilState ||
+ memcmp(&depthStencilState, &mCurDepthStencilState, sizeof(gl::DepthStencilState)) != 0 ||
+ stencilRef != mCurStencilRef || stencilBackRef != mCurStencilBackRef)
+ {
+ if (depthStencilState.stencilWritemask != depthStencilState.stencilBackWritemask ||
+ stencilRef != stencilBackRef ||
+ depthStencilState.stencilMask != depthStencilState.stencilBackMask)
+ {
+ ERR("Separate front/back stencil writemasks, reference values, or stencil mask values are "
+ "invalid under WebGL.");
+ return gl::error(GL_INVALID_OPERATION);
+ }
+
+ ID3D11DepthStencilState *dxDepthStencilState = mStateCache.getDepthStencilState(depthStencilState);
+ if (!dxDepthStencilState)
+ {
+ ERR("NULL depth stencil state returned by RenderStateCache::getDepthStencilState, "
+ "setting the default depth stencil state.");
+ }
+
+ mDeviceContext->OMSetDepthStencilState(dxDepthStencilState, static_cast<UINT>(stencilRef));
+
+ mCurDepthStencilState = depthStencilState;
+ mCurStencilRef = stencilRef;
+ mCurStencilBackRef = stencilBackRef;
+ }
+
+ mForceSetDepthStencilState = false;
+}
+
+void Renderer11::setScissorRectangle(const gl::Rectangle &scissor, bool enabled)
+{
+ if (mForceSetScissor || memcmp(&scissor, &mCurScissor, sizeof(gl::Rectangle)) != 0 ||
+ enabled != mScissorEnabled)
+ {
+ if (enabled)
+ {
+ D3D11_RECT rect;
+ rect.left = std::max(0, scissor.x);
+ rect.top = std::max(0, scissor.y);
+ rect.right = scissor.x + std::max(0, scissor.width);
+ rect.bottom = scissor.y + std::max(0, scissor.height);
+
+ mDeviceContext->RSSetScissorRects(1, &rect);
+ }
+
+ if (enabled != mScissorEnabled)
+ {
+ mForceSetRasterState = true;
+ }
+
+ mCurScissor = scissor;
+ mScissorEnabled = enabled;
+ }
+
+ mForceSetScissor = false;
+}
+
+bool Renderer11::setViewport(const gl::Rectangle &viewport, float zNear, float zFar, GLenum drawMode, GLenum frontFace,
+ bool ignoreViewport)
+{
+ gl::Rectangle actualViewport = viewport;
+ float actualZNear = gl::clamp01(zNear);
+ float actualZFar = gl::clamp01(zFar);
+ if (ignoreViewport)
+ {
+ actualViewport.x = 0;
+ actualViewport.y = 0;
+ actualViewport.width = mRenderTargetDesc.width;
+ actualViewport.height = mRenderTargetDesc.height;
+ actualZNear = 0.0f;
+ actualZFar = 1.0f;
+ }
+
+ // Get D3D viewport bounds, which depends on the feature level
+ const Range& viewportBounds = getViewportBounds();
+
+ // Clamp width and height first to the gl maximum, then clamp further if we extend past the D3D maximum bounds
+ D3D11_VIEWPORT dxViewport;
+ dxViewport.TopLeftX = gl::clamp(actualViewport.x, viewportBounds.start, viewportBounds.end);
+ dxViewport.TopLeftY = gl::clamp(actualViewport.y, viewportBounds.start, viewportBounds.end);
+ dxViewport.Width = gl::clamp(actualViewport.width, 0, getMaxViewportDimension());
+ dxViewport.Height = gl::clamp(actualViewport.height, 0, getMaxViewportDimension());
+ dxViewport.Width = std::min((int)dxViewport.Width, viewportBounds.end - static_cast<int>(dxViewport.TopLeftX));
+ dxViewport.Height = std::min((int)dxViewport.Height, viewportBounds.end - static_cast<int>(dxViewport.TopLeftY));
+ dxViewport.MinDepth = actualZNear;
+ dxViewport.MaxDepth = actualZFar;
+
+ if (dxViewport.Width <= 0 || dxViewport.Height <= 0)
+ {
+ return false; // Nothing to render
+ }
+
+ bool viewportChanged = mForceSetViewport || memcmp(&actualViewport, &mCurViewport, sizeof(gl::Rectangle)) != 0 ||
+ actualZNear != mCurNear || actualZFar != mCurFar;
+
+ if (viewportChanged)
+ {
+ mDeviceContext->RSSetViewports(1, &dxViewport);
+
+ mCurViewport = actualViewport;
+ mCurNear = actualZNear;
+ mCurFar = actualZFar;
+
+ mPixelConstants.viewCoords[0] = actualViewport.width * 0.5f;
+ mPixelConstants.viewCoords[1] = actualViewport.height * 0.5f;
+ mPixelConstants.viewCoords[2] = actualViewport.x + (actualViewport.width * 0.5f);
+ mPixelConstants.viewCoords[3] = actualViewport.y + (actualViewport.height * 0.5f);
+
+ mPixelConstants.depthFront[0] = (actualZFar - actualZNear) * 0.5f;
+ mPixelConstants.depthFront[1] = (actualZNear + actualZFar) * 0.5f;
+
+ mVertexConstants.depthRange[0] = actualZNear;
+ mVertexConstants.depthRange[1] = actualZFar;
+ mVertexConstants.depthRange[2] = actualZFar - actualZNear;
+
+ mPixelConstants.depthRange[0] = actualZNear;
+ mPixelConstants.depthRange[1] = actualZFar;
+ mPixelConstants.depthRange[2] = actualZFar - actualZNear;
+ }
+
+ mForceSetViewport = false;
+ return true;
+}
+
+bool Renderer11::applyPrimitiveType(GLenum mode, GLsizei count)
+{
+ D3D11_PRIMITIVE_TOPOLOGY primitiveTopology = D3D_PRIMITIVE_TOPOLOGY_UNDEFINED;
+
+ switch (mode)
+ {
+ case GL_POINTS: primitiveTopology = D3D11_PRIMITIVE_TOPOLOGY_POINTLIST; break;
+ case GL_LINES: primitiveTopology = D3D_PRIMITIVE_TOPOLOGY_LINELIST; break;
+ case GL_LINE_LOOP: primitiveTopology = D3D_PRIMITIVE_TOPOLOGY_LINESTRIP; break;
+ case GL_LINE_STRIP: primitiveTopology = D3D_PRIMITIVE_TOPOLOGY_LINESTRIP; break;
+ case GL_TRIANGLES: primitiveTopology = D3D_PRIMITIVE_TOPOLOGY_TRIANGLELIST; break;
+ case GL_TRIANGLE_STRIP: primitiveTopology = D3D_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP; break;
+ // emulate fans via rewriting index buffer
+ case GL_TRIANGLE_FAN: primitiveTopology = D3D_PRIMITIVE_TOPOLOGY_TRIANGLELIST; break;
+ default:
+ return gl::error(GL_INVALID_ENUM, false);
+ }
+
+ mDeviceContext->IASetPrimitiveTopology(primitiveTopology);
+
+ return count > 0;
+}
+
+bool Renderer11::applyRenderTarget(gl::Framebuffer *framebuffer)
+{
+ // Get the color render buffer and serial
+ // Also extract the render target dimensions and view
+ unsigned int renderTargetWidth = 0;
+ unsigned int renderTargetHeight = 0;
+ GLenum renderTargetFormat = 0;
+ unsigned int renderTargetSerials[gl::IMPLEMENTATION_MAX_DRAW_BUFFERS] = {0};
+ ID3D11RenderTargetView* framebufferRTVs[gl::IMPLEMENTATION_MAX_DRAW_BUFFERS] = {NULL};
+ bool missingColorRenderTarget = true;
+
+ for (unsigned int colorAttachment = 0; colorAttachment < gl::IMPLEMENTATION_MAX_DRAW_BUFFERS; colorAttachment++)
+ {
+ const GLenum drawBufferState = framebuffer->getDrawBufferState(colorAttachment);
+
+ if (framebuffer->getColorbufferType(colorAttachment) != GL_NONE && drawBufferState != GL_NONE)
+ {
+ // the draw buffer must be either "none", "back" for the default buffer or the same index as this color (in order)
+ ASSERT(drawBufferState == GL_BACK || drawBufferState == (GL_COLOR_ATTACHMENT0_EXT + colorAttachment));
+
+ gl::Renderbuffer *colorbuffer = framebuffer->getColorbuffer(colorAttachment);
+
+ if (!colorbuffer)
+ {
+ ERR("render target pointer unexpectedly null.");
+ return false;
+ }
+
+ // check for zero-sized default framebuffer, which is a special case.
+ // in this case we do not wish to modify any state and just silently return false.
+ // this will not report any gl error but will cause the calling method to return.
+ if (colorbuffer->getWidth() == 0 || colorbuffer->getHeight() == 0)
+ {
+ return false;
+ }
+
+ renderTargetSerials[colorAttachment] = colorbuffer->getSerial();
+
+ // Extract the render target dimensions and view
+ RenderTarget11 *renderTarget = RenderTarget11::makeRenderTarget11(colorbuffer->getRenderTarget());
+ if (!renderTarget)
+ {
+ ERR("render target pointer unexpectedly null.");
+ return false;
+ }
+
+ framebufferRTVs[colorAttachment] = renderTarget->getRenderTargetView();
+ if (!framebufferRTVs[colorAttachment])
+ {
+ ERR("render target view pointer unexpectedly null.");
+ return false;
+ }
+
+ if (missingColorRenderTarget)
+ {
+ renderTargetWidth = colorbuffer->getWidth();
+ renderTargetHeight = colorbuffer->getHeight();
+ renderTargetFormat = colorbuffer->getActualFormat();
+ missingColorRenderTarget = false;
+ }
+ }
+ }
+
+ // Get the depth stencil render buffer and serials
+ gl::Renderbuffer *depthStencil = NULL;
+ unsigned int depthbufferSerial = 0;
+ unsigned int stencilbufferSerial = 0;
+ if (framebuffer->getDepthbufferType() != GL_NONE)
+ {
+ depthStencil = framebuffer->getDepthbuffer();
+ if (!depthStencil)
+ {
+ ERR("Depth stencil pointer unexpectedly null.");
+ SafeRelease(framebufferRTVs);
+ return false;
+ }
+
+ depthbufferSerial = depthStencil->getSerial();
+ }
+ else if (framebuffer->getStencilbufferType() != GL_NONE)
+ {
+ depthStencil = framebuffer->getStencilbuffer();
+ if (!depthStencil)
+ {
+ ERR("Depth stencil pointer unexpectedly null.");
+ SafeRelease(framebufferRTVs);
+ return false;
+ }
+
+ stencilbufferSerial = depthStencil->getSerial();
+ }
+
+ // Extract the depth stencil sizes and view
+ unsigned int depthSize = 0;
+ unsigned int stencilSize = 0;
+ ID3D11DepthStencilView* framebufferDSV = NULL;
+ if (depthStencil)
+ {
+ RenderTarget11 *depthStencilRenderTarget = RenderTarget11::makeRenderTarget11(depthStencil->getDepthStencil());
+ if (!depthStencilRenderTarget)
+ {
+ ERR("render target pointer unexpectedly null.");
+ SafeRelease(framebufferRTVs);
+ return false;
+ }
+
+ framebufferDSV = depthStencilRenderTarget->getDepthStencilView();
+ if (!framebufferDSV)
+ {
+ ERR("depth stencil view pointer unexpectedly null.");
+ SafeRelease(framebufferRTVs);
+ return false;
+ }
+
+ // If there is no render buffer, the width, height and format values come from
+ // the depth stencil
+ if (missingColorRenderTarget)
+ {
+ renderTargetWidth = depthStencil->getWidth();
+ renderTargetHeight = depthStencil->getHeight();
+ renderTargetFormat = depthStencil->getActualFormat();
+ }
+
+ depthSize = depthStencil->getDepthSize();
+ stencilSize = depthStencil->getStencilSize();
+ }
+
+ // Apply the render target and depth stencil
+ if (!mRenderTargetDescInitialized || !mDepthStencilInitialized ||
+ memcmp(renderTargetSerials, mAppliedRenderTargetSerials, sizeof(renderTargetSerials)) != 0 ||
+ depthbufferSerial != mAppliedDepthbufferSerial ||
+ stencilbufferSerial != mAppliedStencilbufferSerial)
+ {
+ mDeviceContext->OMSetRenderTargets(getMaxRenderTargets(), framebufferRTVs, framebufferDSV);
+
+ mRenderTargetDesc.width = renderTargetWidth;
+ mRenderTargetDesc.height = renderTargetHeight;
+ mRenderTargetDesc.format = renderTargetFormat;
+ mForceSetViewport = true;
+ mForceSetScissor = true;
+
+ if (!mDepthStencilInitialized || depthSize != mCurDepthSize)
+ {
+ mCurDepthSize = depthSize;
+ mForceSetRasterState = true;
+ }
+
+ mCurStencilSize = stencilSize;
+
+ for (unsigned int rtIndex = 0; rtIndex < gl::IMPLEMENTATION_MAX_DRAW_BUFFERS; rtIndex++)
+ {
+ mAppliedRenderTargetSerials[rtIndex] = renderTargetSerials[rtIndex];
+ }
+ mAppliedDepthbufferSerial = depthbufferSerial;
+ mAppliedStencilbufferSerial = stencilbufferSerial;
+ mRenderTargetDescInitialized = true;
+ mDepthStencilInitialized = true;
+ }
+
+ SafeRelease(framebufferRTVs);
+ SafeRelease(framebufferDSV);
+
+ return true;
+}
+
+GLenum Renderer11::applyVertexBuffer(gl::ProgramBinary *programBinary, gl::VertexAttribute vertexAttributes[], GLint first, GLsizei count, GLsizei instances)
+{
+ TranslatedAttribute attributes[gl::MAX_VERTEX_ATTRIBS];
+ GLenum err = mVertexDataManager->prepareVertexData(vertexAttributes, programBinary, first, count, attributes, instances);
+ if (err != GL_NO_ERROR)
+ {
+ return err;
+ }
+
+ return mInputLayoutCache.applyVertexBuffers(attributes, programBinary);
+}
+
+GLenum Renderer11::applyIndexBuffer(const GLvoid *indices, gl::Buffer *elementArrayBuffer, GLsizei count, GLenum mode, GLenum type, TranslatedIndexData *indexInfo)
+{
+ GLenum err = mIndexDataManager->prepareIndexData(type, count, elementArrayBuffer, indices, indexInfo);
+
+ if (err == GL_NO_ERROR)
+ {
+ if (indexInfo->storage)
+ {
+ if (indexInfo->serial != mAppliedStorageIBSerial || indexInfo->startOffset != mAppliedIBOffset)
+ {
+ BufferStorage11 *storage = BufferStorage11::makeBufferStorage11(indexInfo->storage);
+ IndexBuffer11* indexBuffer = IndexBuffer11::makeIndexBuffer11(indexInfo->indexBuffer);
+
+ mDeviceContext->IASetIndexBuffer(storage->getBuffer(), indexBuffer->getIndexFormat(), indexInfo->startOffset);
+
+ mAppliedIBSerial = 0;
+ mAppliedStorageIBSerial = storage->getSerial();
+ mAppliedIBOffset = indexInfo->startOffset;
+ }
+ }
+ else if (indexInfo->serial != mAppliedIBSerial || indexInfo->startOffset != mAppliedIBOffset)
+ {
+ IndexBuffer11* indexBuffer = IndexBuffer11::makeIndexBuffer11(indexInfo->indexBuffer);
+
+ mDeviceContext->IASetIndexBuffer(indexBuffer->getBuffer(), indexBuffer->getIndexFormat(), indexInfo->startOffset);
+
+ mAppliedIBSerial = indexInfo->serial;
+ mAppliedStorageIBSerial = 0;
+ mAppliedIBOffset = indexInfo->startOffset;
+ }
+ }
+
+ return err;
+}
+
+void Renderer11::drawArrays(GLenum mode, GLsizei count, GLsizei instances)
+{
+ if (mode == GL_LINE_LOOP)
+ {
+ drawLineLoop(count, GL_NONE, NULL, 0, NULL);
+ }
+ else if (mode == GL_TRIANGLE_FAN)
+ {
+ drawTriangleFan(count, GL_NONE, NULL, 0, NULL, instances);
+ }
+ else if (instances > 0)
+ {
+ mDeviceContext->DrawInstanced(count, instances, 0, 0);
+ }
+ else
+ {
+ mDeviceContext->Draw(count, 0);
+ }
+}
+
+void Renderer11::drawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, gl::Buffer *elementArrayBuffer, const TranslatedIndexData &indexInfo, GLsizei instances)
+{
+ if (mode == GL_LINE_LOOP)
+ {
+ drawLineLoop(count, type, indices, indexInfo.minIndex, elementArrayBuffer);
+ }
+ else if (mode == GL_TRIANGLE_FAN)
+ {
+ drawTriangleFan(count, type, indices, indexInfo.minIndex, elementArrayBuffer, instances);
+ }
+ else if (instances > 0)
+ {
+ mDeviceContext->DrawIndexedInstanced(count, instances, 0, -static_cast<int>(indexInfo.minIndex), 0);
+ }
+ else
+ {
+ mDeviceContext->DrawIndexed(count, 0, -static_cast<int>(indexInfo.minIndex));
+ }
+}
+
+void Renderer11::drawLineLoop(GLsizei count, GLenum type, const GLvoid *indices, int minIndex, gl::Buffer *elementArrayBuffer)
+{
+ // Get the raw indices for an indexed draw
+ if (type != GL_NONE && elementArrayBuffer)
+ {
+ gl::Buffer *indexBuffer = elementArrayBuffer;
+ BufferStorage *storage = indexBuffer->getStorage();
+ intptr_t offset = reinterpret_cast<intptr_t>(indices);
+ indices = static_cast<const GLubyte*>(storage->getData()) + offset;
+ }
+
+ if (!mLineLoopIB)
+ {
+ mLineLoopIB = new StreamingIndexBufferInterface(this);
+ if (!mLineLoopIB->reserveBufferSpace(INITIAL_INDEX_BUFFER_SIZE, GL_UNSIGNED_INT))
+ {
+ delete mLineLoopIB;
+ mLineLoopIB = NULL;
+
+ ERR("Could not create a 32-bit looping index buffer for GL_LINE_LOOP.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ const int spaceNeeded = (count + 1) * sizeof(unsigned int);
+ if (!mLineLoopIB->reserveBufferSpace(spaceNeeded, GL_UNSIGNED_INT))
+ {
+ ERR("Could not reserve enough space in looping index buffer for GL_LINE_LOOP.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ void* mappedMemory = NULL;
+ int offset = mLineLoopIB->mapBuffer(spaceNeeded, &mappedMemory);
+ if (offset == -1 || mappedMemory == NULL)
+ {
+ ERR("Could not map index buffer for GL_LINE_LOOP.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ unsigned int *data = reinterpret_cast<unsigned int*>(mappedMemory);
+ unsigned int indexBufferOffset = static_cast<unsigned int>(offset);
+
+ switch (type)
+ {
+ case GL_NONE: // Non-indexed draw
+ for (int i = 0; i < count; i++)
+ {
+ data[i] = i;
+ }
+ data[count] = 0;
+ break;
+ case GL_UNSIGNED_BYTE:
+ for (int i = 0; i < count; i++)
+ {
+ data[i] = static_cast<const GLubyte*>(indices)[i];
+ }
+ data[count] = static_cast<const GLubyte*>(indices)[0];
+ break;
+ case GL_UNSIGNED_SHORT:
+ for (int i = 0; i < count; i++)
+ {
+ data[i] = static_cast<const GLushort*>(indices)[i];
+ }
+ data[count] = static_cast<const GLushort*>(indices)[0];
+ break;
+ case GL_UNSIGNED_INT:
+ for (int i = 0; i < count; i++)
+ {
+ data[i] = static_cast<const GLuint*>(indices)[i];
+ }
+ data[count] = static_cast<const GLuint*>(indices)[0];
+ break;
+ default: UNREACHABLE();
+ }
+
+ if (!mLineLoopIB->unmapBuffer())
+ {
+ ERR("Could not unmap index buffer for GL_LINE_LOOP.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ if (mAppliedIBSerial != mLineLoopIB->getSerial() || mAppliedIBOffset != indexBufferOffset)
+ {
+ IndexBuffer11 *indexBuffer = IndexBuffer11::makeIndexBuffer11(mLineLoopIB->getIndexBuffer());
+
+ mDeviceContext->IASetIndexBuffer(indexBuffer->getBuffer(), indexBuffer->getIndexFormat(), indexBufferOffset);
+ mAppliedIBSerial = mLineLoopIB->getSerial();
+ mAppliedStorageIBSerial = 0;
+ mAppliedIBOffset = indexBufferOffset;
+ }
+
+ mDeviceContext->DrawIndexed(count + 1, 0, -minIndex);
+}
+
+void Renderer11::drawTriangleFan(GLsizei count, GLenum type, const GLvoid *indices, int minIndex, gl::Buffer *elementArrayBuffer, int instances)
+{
+ // Get the raw indices for an indexed draw
+ if (type != GL_NONE && elementArrayBuffer)
+ {
+ gl::Buffer *indexBuffer = elementArrayBuffer;
+ BufferStorage *storage = indexBuffer->getStorage();
+ intptr_t offset = reinterpret_cast<intptr_t>(indices);
+ indices = static_cast<const GLubyte*>(storage->getData()) + offset;
+ }
+
+ if (!mTriangleFanIB)
+ {
+ mTriangleFanIB = new StreamingIndexBufferInterface(this);
+ if (!mTriangleFanIB->reserveBufferSpace(INITIAL_INDEX_BUFFER_SIZE, GL_UNSIGNED_INT))
+ {
+ delete mTriangleFanIB;
+ mTriangleFanIB = NULL;
+
+ ERR("Could not create a scratch index buffer for GL_TRIANGLE_FAN.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ const int numTris = count - 2;
+ const int spaceNeeded = (numTris * 3) * sizeof(unsigned int);
+ if (!mTriangleFanIB->reserveBufferSpace(spaceNeeded, GL_UNSIGNED_INT))
+ {
+ ERR("Could not reserve enough space in scratch index buffer for GL_TRIANGLE_FAN.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ void* mappedMemory = NULL;
+ int offset = mTriangleFanIB->mapBuffer(spaceNeeded, &mappedMemory);
+ if (offset == -1 || mappedMemory == NULL)
+ {
+ ERR("Could not map scratch index buffer for GL_TRIANGLE_FAN.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ unsigned int *data = reinterpret_cast<unsigned int*>(mappedMemory);
+ unsigned int indexBufferOffset = static_cast<unsigned int>(offset);
+
+ switch (type)
+ {
+ case GL_NONE: // Non-indexed draw
+ for (int i = 0; i < numTris; i++)
+ {
+ data[i*3 + 0] = 0;
+ data[i*3 + 1] = i + 1;
+ data[i*3 + 2] = i + 2;
+ }
+ break;
+ case GL_UNSIGNED_BYTE:
+ for (int i = 0; i < numTris; i++)
+ {
+ data[i*3 + 0] = static_cast<const GLubyte*>(indices)[0];
+ data[i*3 + 1] = static_cast<const GLubyte*>(indices)[i + 1];
+ data[i*3 + 2] = static_cast<const GLubyte*>(indices)[i + 2];
+ }
+ break;
+ case GL_UNSIGNED_SHORT:
+ for (int i = 0; i < numTris; i++)
+ {
+ data[i*3 + 0] = static_cast<const GLushort*>(indices)[0];
+ data[i*3 + 1] = static_cast<const GLushort*>(indices)[i + 1];
+ data[i*3 + 2] = static_cast<const GLushort*>(indices)[i + 2];
+ }
+ break;
+ case GL_UNSIGNED_INT:
+ for (int i = 0; i < numTris; i++)
+ {
+ data[i*3 + 0] = static_cast<const GLuint*>(indices)[0];
+ data[i*3 + 1] = static_cast<const GLuint*>(indices)[i + 1];
+ data[i*3 + 2] = static_cast<const GLuint*>(indices)[i + 2];
+ }
+ break;
+ default: UNREACHABLE();
+ }
+
+ if (!mTriangleFanIB->unmapBuffer())
+ {
+ ERR("Could not unmap scratch index buffer for GL_TRIANGLE_FAN.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ if (mAppliedIBSerial != mTriangleFanIB->getSerial() || mAppliedIBOffset != indexBufferOffset)
+ {
+ IndexBuffer11 *indexBuffer = IndexBuffer11::makeIndexBuffer11(mTriangleFanIB->getIndexBuffer());
+
+ mDeviceContext->IASetIndexBuffer(indexBuffer->getBuffer(), indexBuffer->getIndexFormat(), indexBufferOffset);
+ mAppliedIBSerial = mTriangleFanIB->getSerial();
+ mAppliedStorageIBSerial = 0;
+ mAppliedIBOffset = indexBufferOffset;
+ }
+
+ if (instances > 0)
+ {
+ mDeviceContext->DrawIndexedInstanced(numTris * 3, instances, 0, -minIndex, 0);
+ }
+ else
+ {
+ mDeviceContext->DrawIndexed(numTris * 3, 0, -minIndex);
+ }
+}
+
+void Renderer11::applyShaders(gl::ProgramBinary *programBinary)
+{
+ unsigned int programBinarySerial = programBinary->getSerial();
+ const bool updateProgramState = (programBinarySerial != mAppliedProgramBinarySerial);
+
+ if (updateProgramState)
+ {
+ ShaderExecutable *vertexExe = programBinary->getVertexExecutable();
+ ShaderExecutable *pixelExe = programBinary->getPixelExecutable();
+
+ ID3D11VertexShader *vertexShader = NULL;
+ if (vertexExe) vertexShader = ShaderExecutable11::makeShaderExecutable11(vertexExe)->getVertexShader();
+
+ ID3D11PixelShader *pixelShader = NULL;
+ if (pixelExe) pixelShader = ShaderExecutable11::makeShaderExecutable11(pixelExe)->getPixelShader();
+
+ mDeviceContext->PSSetShader(pixelShader, NULL, 0);
+ mDeviceContext->VSSetShader(vertexShader, NULL, 0);
+
+ programBinary->dirtyAllUniforms();
+
+ mAppliedProgramBinarySerial = programBinarySerial;
+ }
+
+ // Only use the geometry shader currently for point sprite drawing
+ const bool usesGeometryShader = (programBinary->usesGeometryShader() && mCurRasterState.pointDrawMode);
+
+ if (updateProgramState || usesGeometryShader != mIsGeometryShaderActive)
+ {
+ if (usesGeometryShader)
+ {
+ ShaderExecutable *geometryExe = programBinary->getGeometryExecutable();
+ ID3D11GeometryShader *geometryShader = ShaderExecutable11::makeShaderExecutable11(geometryExe)->getGeometryShader();
+ mDeviceContext->GSSetShader(geometryShader, NULL, 0);
+ }
+ else
+ {
+ mDeviceContext->GSSetShader(NULL, NULL, 0);
+ }
+
+ mIsGeometryShaderActive = usesGeometryShader;
+ }
+}
+
+void Renderer11::applyUniforms(gl::ProgramBinary *programBinary, gl::UniformArray *uniformArray)
+{
+ ShaderExecutable11 *vertexExecutable = ShaderExecutable11::makeShaderExecutable11(programBinary->getVertexExecutable());
+ ShaderExecutable11 *pixelExecutable = ShaderExecutable11::makeShaderExecutable11(programBinary->getPixelExecutable());
+
+ unsigned int totalRegisterCountVS = 0;
+ unsigned int totalRegisterCountPS = 0;
+
+ bool vertexUniformsDirty = false;
+ bool pixelUniformsDirty = false;
+
+ for (gl::UniformArray::const_iterator uniform_iterator = uniformArray->begin(); uniform_iterator != uniformArray->end(); uniform_iterator++)
+ {
+ const gl::Uniform *uniform = *uniform_iterator;
+
+ if (uniform->vsRegisterIndex >= 0)
+ {
+ totalRegisterCountVS += uniform->registerCount;
+ vertexUniformsDirty = vertexUniformsDirty || uniform->dirty;
+ }
+
+ if (uniform->psRegisterIndex >= 0)
+ {
+ totalRegisterCountPS += uniform->registerCount;
+ pixelUniformsDirty = pixelUniformsDirty || uniform->dirty;
+ }
+ }
+
+ ID3D11Buffer *vertexConstantBuffer = vertexExecutable->getConstantBuffer(mDevice, totalRegisterCountVS);
+ ID3D11Buffer *pixelConstantBuffer = pixelExecutable->getConstantBuffer(mDevice, totalRegisterCountPS);
+
+ float (*mapVS)[4] = NULL;
+ float (*mapPS)[4] = NULL;
+
+ if (totalRegisterCountVS > 0 && vertexUniformsDirty)
+ {
+ D3D11_MAPPED_SUBRESOURCE map = {0};
+ HRESULT result = mDeviceContext->Map(vertexConstantBuffer, 0, D3D11_MAP_WRITE_DISCARD, 0, &map);
+ ASSERT(SUCCEEDED(result));
+ mapVS = (float(*)[4])map.pData;
+ }
+
+ if (totalRegisterCountPS > 0 && pixelUniformsDirty)
+ {
+ D3D11_MAPPED_SUBRESOURCE map = {0};
+ HRESULT result = mDeviceContext->Map(pixelConstantBuffer, 0, D3D11_MAP_WRITE_DISCARD, 0, &map);
+ ASSERT(SUCCEEDED(result));
+ mapPS = (float(*)[4])map.pData;
+ }
+
+ for (gl::UniformArray::iterator uniform_iterator = uniformArray->begin(); uniform_iterator != uniformArray->end(); uniform_iterator++)
+ {
+ gl::Uniform *uniform = *uniform_iterator;
+
+ if (uniform->type != GL_SAMPLER_2D && uniform->type != GL_SAMPLER_CUBE)
+ {
+ if (uniform->vsRegisterIndex >= 0 && mapVS)
+ {
+ memcpy(mapVS + uniform->vsRegisterIndex, uniform->data, uniform->registerCount * sizeof(float[4]));
+ }
+
+ if (uniform->psRegisterIndex >= 0 && mapPS)
+ {
+ memcpy(mapPS + uniform->psRegisterIndex, uniform->data, uniform->registerCount * sizeof(float[4]));
+ }
+ }
+
+ uniform->dirty = false;
+ }
+
+ if (mapVS)
+ {
+ mDeviceContext->Unmap(vertexConstantBuffer, 0);
+ }
+
+ if (mapPS)
+ {
+ mDeviceContext->Unmap(pixelConstantBuffer, 0);
+ }
+
+ mDeviceContext->VSSetConstantBuffers(0, 1, &vertexConstantBuffer);
+ mDeviceContext->PSSetConstantBuffers(0, 1, &pixelConstantBuffer);
+
+ // Driver uniforms
+ if (!mDriverConstantBufferVS)
+ {
+ D3D11_BUFFER_DESC constantBufferDescription = {0};
+ constantBufferDescription.ByteWidth = sizeof(dx_VertexConstants);
+ constantBufferDescription.Usage = D3D11_USAGE_DEFAULT;
+ constantBufferDescription.BindFlags = D3D11_BIND_CONSTANT_BUFFER;
+ constantBufferDescription.CPUAccessFlags = 0;
+ constantBufferDescription.MiscFlags = 0;
+ constantBufferDescription.StructureByteStride = 0;
+
+ HRESULT result = mDevice->CreateBuffer(&constantBufferDescription, NULL, &mDriverConstantBufferVS);
+ ASSERT(SUCCEEDED(result));
+
+ mDeviceContext->VSSetConstantBuffers(1, 1, &mDriverConstantBufferVS);
+ }
+
+ if (!mDriverConstantBufferPS)
+ {
+ D3D11_BUFFER_DESC constantBufferDescription = {0};
+ constantBufferDescription.ByteWidth = sizeof(dx_PixelConstants);
+ constantBufferDescription.Usage = D3D11_USAGE_DEFAULT;
+ constantBufferDescription.BindFlags = D3D11_BIND_CONSTANT_BUFFER;
+ constantBufferDescription.CPUAccessFlags = 0;
+ constantBufferDescription.MiscFlags = 0;
+ constantBufferDescription.StructureByteStride = 0;
+
+ HRESULT result = mDevice->CreateBuffer(&constantBufferDescription, NULL, &mDriverConstantBufferPS);
+ ASSERT(SUCCEEDED(result));
+
+ mDeviceContext->PSSetConstantBuffers(1, 1, &mDriverConstantBufferPS);
+ }
+
+ if (memcmp(&mVertexConstants, &mAppliedVertexConstants, sizeof(dx_VertexConstants)) != 0)
+ {
+ mDeviceContext->UpdateSubresource(mDriverConstantBufferVS, 0, NULL, &mVertexConstants, 16, 0);
+ memcpy(&mAppliedVertexConstants, &mVertexConstants, sizeof(dx_VertexConstants));
+ }
+
+ if (memcmp(&mPixelConstants, &mAppliedPixelConstants, sizeof(dx_PixelConstants)) != 0)
+ {
+ mDeviceContext->UpdateSubresource(mDriverConstantBufferPS, 0, NULL, &mPixelConstants, 16, 0);
+ memcpy(&mAppliedPixelConstants, &mPixelConstants, sizeof(dx_PixelConstants));
+ }
+
+ // needed for the point sprite geometry shader
+ mDeviceContext->GSSetConstantBuffers(0, 1, &mDriverConstantBufferPS);
+}
+
+void Renderer11::clear(const gl::ClearParameters &clearParams, gl::Framebuffer *frameBuffer)
+{
+ bool alphaUnmasked = (gl::GetAlphaSize(mRenderTargetDesc.format) == 0) || clearParams.colorMaskAlpha;
+ bool needMaskedColorClear = (clearParams.mask & GL_COLOR_BUFFER_BIT) &&
+ !(clearParams.colorMaskRed && clearParams.colorMaskGreen &&
+ clearParams.colorMaskBlue && alphaUnmasked);
+
+ unsigned int stencilUnmasked = 0x0;
+ if (frameBuffer->hasStencil())
+ {
+ unsigned int stencilSize = gl::GetStencilSize(frameBuffer->getStencilbuffer()->getActualFormat());
+ stencilUnmasked = (0x1 << stencilSize) - 1;
+ }
+ bool needMaskedStencilClear = (clearParams.mask & GL_STENCIL_BUFFER_BIT) &&
+ (clearParams.stencilWriteMask & stencilUnmasked) != stencilUnmasked;
+
+ bool needScissoredClear = mScissorEnabled && (mCurScissor.x > 0 || mCurScissor.y > 0 ||
+ mCurScissor.x + mCurScissor.width < mRenderTargetDesc.width ||
+ mCurScissor.y + mCurScissor.height < mRenderTargetDesc.height);
+
+ if (needMaskedColorClear || needMaskedStencilClear || needScissoredClear)
+ {
+ maskedClear(clearParams);
+ }
+ else
+ {
+ if (clearParams.mask & GL_COLOR_BUFFER_BIT)
+ {
+ for (unsigned int colorAttachment = 0; colorAttachment < gl::IMPLEMENTATION_MAX_DRAW_BUFFERS; colorAttachment++)
+ {
+ if (frameBuffer->isEnabledColorAttachment(colorAttachment))
+ {
+ gl::Renderbuffer *renderbufferObject = frameBuffer->getColorbuffer(colorAttachment);
+ if (renderbufferObject)
+ {
+ RenderTarget11 *renderTarget = RenderTarget11::makeRenderTarget11(renderbufferObject->getRenderTarget());
+ if (!renderTarget)
+ {
+ ERR("render target pointer unexpectedly null.");
+ return;
+ }
+
+ ID3D11RenderTargetView *framebufferRTV = renderTarget->getRenderTargetView();
+ if (!framebufferRTV)
+ {
+ ERR("render target view pointer unexpectedly null.");
+ return;
+ }
+
+ const float clearValues[4] = { clearParams.colorClearValue.red,
+ clearParams.colorClearValue.green,
+ clearParams.colorClearValue.blue,
+ clearParams.colorClearValue.alpha };
+ mDeviceContext->ClearRenderTargetView(framebufferRTV, clearValues);
+
+ framebufferRTV->Release();
+ }
+ }
+ }
+ }
+ if (clearParams.mask & GL_DEPTH_BUFFER_BIT || clearParams.mask & GL_STENCIL_BUFFER_BIT)
+ {
+ gl::Renderbuffer *renderbufferObject = frameBuffer->getDepthOrStencilbuffer();
+ if (renderbufferObject)
+ {
+ RenderTarget11 *renderTarget = RenderTarget11::makeRenderTarget11(renderbufferObject->getDepthStencil());
+ if (!renderTarget)
+ {
+ ERR("render target pointer unexpectedly null.");
+ return;
+ }
+
+ ID3D11DepthStencilView *framebufferDSV = renderTarget->getDepthStencilView();
+ if (!framebufferDSV)
+ {
+ ERR("depth stencil view pointer unexpectedly null.");
+ return;
+ }
+
+ UINT clearFlags = 0;
+ if (clearParams.mask & GL_DEPTH_BUFFER_BIT)
+ {
+ clearFlags |= D3D11_CLEAR_DEPTH;
+ }
+ if (clearParams.mask & GL_STENCIL_BUFFER_BIT)
+ {
+ clearFlags |= D3D11_CLEAR_STENCIL;
+ }
+
+ float depthClear = gl::clamp01(clearParams.depthClearValue);
+ UINT8 stencilClear = clearParams.stencilClearValue & 0x000000FF;
+
+ mDeviceContext->ClearDepthStencilView(framebufferDSV, clearFlags, depthClear, stencilClear);
+
+ framebufferDSV->Release();
+ }
+ }
+ }
+}
+
+void Renderer11::maskedClear(const gl::ClearParameters &clearParams)
+{
+ HRESULT result;
+
+ if (!mClearResourcesInitialized)
+ {
+ ASSERT(!mClearVB && !mClearVS && !mClearPS && !mClearScissorRS && !mClearNoScissorRS);
+
+ D3D11_BUFFER_DESC vbDesc;
+ vbDesc.ByteWidth = sizeof(d3d11::PositionDepthColorVertex) * 4;
+ vbDesc.Usage = D3D11_USAGE_DYNAMIC;
+ vbDesc.BindFlags = D3D11_BIND_VERTEX_BUFFER;
+ vbDesc.CPUAccessFlags = D3D11_CPU_ACCESS_WRITE;
+ vbDesc.MiscFlags = 0;
+ vbDesc.StructureByteStride = 0;
+
+ result = mDevice->CreateBuffer(&vbDesc, NULL, &mClearVB);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mClearVB, "Renderer11 masked clear vertex buffer");
+
+ D3D11_INPUT_ELEMENT_DESC quadLayout[] =
+ {
+ { "POSITION", 0, DXGI_FORMAT_R32G32B32_FLOAT, 0, 0, D3D11_INPUT_PER_VERTEX_DATA, 0 },
+ { "COLOR", 0, DXGI_FORMAT_R32G32B32A32_FLOAT, 0, 12, D3D11_INPUT_PER_VERTEX_DATA, 0 },
+ };
+
+ result = mDevice->CreateInputLayout(quadLayout, 2, g_VS_Clear, sizeof(g_VS_Clear), &mClearIL);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mClearIL, "Renderer11 masked clear input layout");
+
+ result = mDevice->CreateVertexShader(g_VS_Clear, sizeof(g_VS_Clear), NULL, &mClearVS);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mClearVS, "Renderer11 masked clear vertex shader");
+
+ result = mDevice->CreatePixelShader(g_PS_Clear, sizeof(g_PS_Clear), NULL, &mClearPS);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mClearPS, "Renderer11 masked clear pixel shader");
+
+ D3D11_RASTERIZER_DESC rsScissorDesc;
+ rsScissorDesc.FillMode = D3D11_FILL_SOLID;
+ rsScissorDesc.CullMode = D3D11_CULL_NONE;
+ rsScissorDesc.FrontCounterClockwise = FALSE;
+ rsScissorDesc.DepthBias = 0;
+ rsScissorDesc.DepthBiasClamp = 0.0f;
+ rsScissorDesc.SlopeScaledDepthBias = 0.0f;
+ rsScissorDesc.DepthClipEnable = FALSE;
+ rsScissorDesc.ScissorEnable = TRUE;
+ rsScissorDesc.MultisampleEnable = FALSE;
+ rsScissorDesc.AntialiasedLineEnable = FALSE;
+
+ result = mDevice->CreateRasterizerState(&rsScissorDesc, &mClearScissorRS);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mClearScissorRS, "Renderer11 masked clear scissor rasterizer state");
+
+ D3D11_RASTERIZER_DESC rsNoScissorDesc;
+ rsNoScissorDesc.FillMode = D3D11_FILL_SOLID;
+ rsNoScissorDesc.CullMode = D3D11_CULL_NONE;
+ rsNoScissorDesc.FrontCounterClockwise = FALSE;
+ rsNoScissorDesc.DepthBias = 0;
+ rsNoScissorDesc.DepthBiasClamp = 0.0f;
+ rsNoScissorDesc.SlopeScaledDepthBias = 0.0f;
+ rsNoScissorDesc.DepthClipEnable = FALSE;
+ rsNoScissorDesc.ScissorEnable = FALSE;
+ rsNoScissorDesc.MultisampleEnable = FALSE;
+ rsNoScissorDesc.AntialiasedLineEnable = FALSE;
+
+ result = mDevice->CreateRasterizerState(&rsNoScissorDesc, &mClearNoScissorRS);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mClearNoScissorRS, "Renderer11 masked clear no scissor rasterizer state");
+
+ mClearResourcesInitialized = true;
+ }
+
+ // Prepare the depth stencil state to write depth values if the depth should be cleared
+ // and stencil values if the stencil should be cleared
+ gl::DepthStencilState glDSState;
+ glDSState.depthTest = (clearParams.mask & GL_DEPTH_BUFFER_BIT) != 0;
+ glDSState.depthFunc = GL_ALWAYS;
+ glDSState.depthMask = (clearParams.mask & GL_DEPTH_BUFFER_BIT) != 0;
+ glDSState.stencilTest = (clearParams.mask & GL_STENCIL_BUFFER_BIT) != 0;
+ glDSState.stencilFunc = GL_ALWAYS;
+ glDSState.stencilMask = 0;
+ glDSState.stencilFail = GL_REPLACE;
+ glDSState.stencilPassDepthFail = GL_REPLACE;
+ glDSState.stencilPassDepthPass = GL_REPLACE;
+ glDSState.stencilWritemask = clearParams.stencilWriteMask;
+ glDSState.stencilBackFunc = GL_ALWAYS;
+ glDSState.stencilBackMask = 0;
+ glDSState.stencilBackFail = GL_REPLACE;
+ glDSState.stencilBackPassDepthFail = GL_REPLACE;
+ glDSState.stencilBackPassDepthPass = GL_REPLACE;
+ glDSState.stencilBackWritemask = clearParams.stencilWriteMask;
+
+ int stencilClear = clearParams.stencilClearValue & 0x000000FF;
+
+ ID3D11DepthStencilState *dsState = mStateCache.getDepthStencilState(glDSState);
+
+ // Prepare the blend state to use a write mask if the color buffer should be cleared
+ gl::BlendState glBlendState;
+ glBlendState.blend = false;
+ glBlendState.sourceBlendRGB = GL_ONE;
+ glBlendState.destBlendRGB = GL_ZERO;
+ glBlendState.sourceBlendAlpha = GL_ONE;
+ glBlendState.destBlendAlpha = GL_ZERO;
+ glBlendState.blendEquationRGB = GL_FUNC_ADD;
+ glBlendState.blendEquationAlpha = GL_FUNC_ADD;
+ glBlendState.colorMaskRed = (clearParams.mask & GL_COLOR_BUFFER_BIT) ? clearParams.colorMaskRed : false;
+ glBlendState.colorMaskGreen = (clearParams.mask & GL_COLOR_BUFFER_BIT) ? clearParams.colorMaskGreen : false;
+ glBlendState.colorMaskBlue = (clearParams.mask & GL_COLOR_BUFFER_BIT) ? clearParams.colorMaskBlue : false;
+ glBlendState.colorMaskAlpha = (clearParams.mask & GL_COLOR_BUFFER_BIT) ? clearParams.colorMaskAlpha : false;
+ glBlendState.sampleAlphaToCoverage = false;
+ glBlendState.dither = false;
+
+ static const float blendFactors[4] = { 1.0f, 1.0f, 1.0f, 1.0f };
+ static const UINT sampleMask = 0xFFFFFFFF;
+
+ ID3D11BlendState *blendState = mStateCache.getBlendState(glBlendState);
+
+ // Set the vertices
+ D3D11_MAPPED_SUBRESOURCE mappedResource;
+ result = mDeviceContext->Map(mClearVB, 0, D3D11_MAP_WRITE_DISCARD, 0, &mappedResource);
+ if (FAILED(result))
+ {
+ ERR("Failed to map masked clear vertex buffer, HRESULT: 0x%X.", result);
+ return;
+ }
+
+ d3d11::PositionDepthColorVertex *vertices = reinterpret_cast<d3d11::PositionDepthColorVertex*>(mappedResource.pData);
+
+ float depthClear = gl::clamp01(clearParams.depthClearValue);
+ d3d11::SetPositionDepthColorVertex(&vertices[0], -1.0f, 1.0f, depthClear, clearParams.colorClearValue);
+ d3d11::SetPositionDepthColorVertex(&vertices[1], -1.0f, -1.0f, depthClear, clearParams.colorClearValue);
+ d3d11::SetPositionDepthColorVertex(&vertices[2], 1.0f, 1.0f, depthClear, clearParams.colorClearValue);
+ d3d11::SetPositionDepthColorVertex(&vertices[3], 1.0f, -1.0f, depthClear, clearParams.colorClearValue);
+
+ mDeviceContext->Unmap(mClearVB, 0);
+
+ // Apply state
+ mDeviceContext->OMSetBlendState(blendState, blendFactors, sampleMask);
+ mDeviceContext->OMSetDepthStencilState(dsState, stencilClear);
+ mDeviceContext->RSSetState(mScissorEnabled ? mClearScissorRS : mClearNoScissorRS);
+
+ // Apply shaders
+ mDeviceContext->IASetInputLayout(mClearIL);
+ mDeviceContext->VSSetShader(mClearVS, NULL, 0);
+ mDeviceContext->PSSetShader(mClearPS, NULL, 0);
+ mDeviceContext->GSSetShader(NULL, NULL, 0);
+
+ // Apply vertex buffer
+ static UINT stride = sizeof(d3d11::PositionDepthColorVertex);
+ static UINT startIdx = 0;
+ mDeviceContext->IASetVertexBuffers(0, 1, &mClearVB, &stride, &startIdx);
+ mDeviceContext->IASetPrimitiveTopology(D3D_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP);
+
+ // Draw the clear quad
+ mDeviceContext->Draw(4, 0);
+
+ // Clean up
+ markAllStateDirty();
+}
+
+void Renderer11::markAllStateDirty()
+{
+ for (unsigned int rtIndex = 0; rtIndex < gl::IMPLEMENTATION_MAX_DRAW_BUFFERS; rtIndex++)
+ {
+ mAppliedRenderTargetSerials[rtIndex] = 0;
+ }
+ mAppliedDepthbufferSerial = 0;
+ mAppliedStencilbufferSerial = 0;
+ mDepthStencilInitialized = false;
+ mRenderTargetDescInitialized = false;
+
+ for (int i = 0; i < gl::IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS; i++)
+ {
+ mForceSetVertexSamplerStates[i] = true;
+ mCurVertexTextureSerials[i] = 0;
+ }
+ for (int i = 0; i < gl::MAX_TEXTURE_IMAGE_UNITS; i++)
+ {
+ mForceSetPixelSamplerStates[i] = true;
+ mCurPixelTextureSerials[i] = 0;
+ }
+
+ mForceSetBlendState = true;
+ mForceSetRasterState = true;
+ mForceSetDepthStencilState = true;
+ mForceSetScissor = true;
+ mForceSetViewport = true;
+
+ mAppliedIBSerial = 0;
+ mAppliedStorageIBSerial = 0;
+ mAppliedIBOffset = 0;
+
+ mAppliedProgramBinarySerial = 0;
+ memset(&mAppliedVertexConstants, 0, sizeof(dx_VertexConstants));
+ memset(&mAppliedPixelConstants, 0, sizeof(dx_PixelConstants));
+}
+
+void Renderer11::releaseDeviceResources()
+{
+ mStateCache.clear();
+ mInputLayoutCache.clear();
+
+ delete mVertexDataManager;
+ mVertexDataManager = NULL;
+
+ delete mIndexDataManager;
+ mIndexDataManager = NULL;
+
+ delete mLineLoopIB;
+ mLineLoopIB = NULL;
+
+ delete mTriangleFanIB;
+ mTriangleFanIB = NULL;
+
+ if (mCopyVB)
+ {
+ mCopyVB->Release();
+ mCopyVB = NULL;
+ }
+
+ if (mCopySampler)
+ {
+ mCopySampler->Release();
+ mCopySampler = NULL;
+ }
+
+ if (mCopyIL)
+ {
+ mCopyIL->Release();
+ mCopyIL = NULL;
+ }
+
+ if (mCopyVS)
+ {
+ mCopyVS->Release();
+ mCopyVS = NULL;
+ }
+
+ if (mCopyRGBAPS)
+ {
+ mCopyRGBAPS->Release();
+ mCopyRGBAPS = NULL;
+ }
+
+ if (mCopyRGBPS)
+ {
+ mCopyRGBPS->Release();
+ mCopyRGBPS = NULL;
+ }
+
+ if (mCopyLumPS)
+ {
+ mCopyLumPS->Release();
+ mCopyLumPS = NULL;
+ }
+
+ if (mCopyLumAlphaPS)
+ {
+ mCopyLumAlphaPS->Release();
+ mCopyLumAlphaPS = NULL;
+ }
+
+ mCopyResourcesInitialized = false;
+
+ if (mClearVB)
+ {
+ mClearVB->Release();
+ mClearVB = NULL;
+ }
+
+ if (mClearIL)
+ {
+ mClearIL->Release();
+ mClearIL = NULL;
+ }
+
+ if (mClearVS)
+ {
+ mClearVS->Release();
+ mClearVS = NULL;
+ }
+
+ if (mClearPS)
+ {
+ mClearPS->Release();
+ mClearPS = NULL;
+ }
+
+ if (mClearScissorRS)
+ {
+ mClearScissorRS->Release();
+ mClearScissorRS = NULL;
+ }
+
+ if (mClearNoScissorRS)
+ {
+ mClearNoScissorRS->Release();
+ mClearNoScissorRS = NULL;
+ }
+
+ mClearResourcesInitialized = false;
+
+ if (mDriverConstantBufferVS)
+ {
+ mDriverConstantBufferVS->Release();
+ mDriverConstantBufferVS = NULL;
+ }
+
+ if (mDriverConstantBufferPS)
+ {
+ mDriverConstantBufferPS->Release();
+ mDriverConstantBufferPS = NULL;
+ }
+
+ if (mSyncQuery)
+ {
+ mSyncQuery->Release();
+ mSyncQuery = NULL;
+ }
+}
+
+void Renderer11::notifyDeviceLost()
+{
+ mDeviceLost = true;
+ mDisplay->notifyDeviceLost();
+}
+
+bool Renderer11::isDeviceLost()
+{
+ return mDeviceLost;
+}
+
+// set notify to true to broadcast a message to all contexts of the device loss
+bool Renderer11::testDeviceLost(bool notify)
+{
+ bool isLost = false;
+
+ // GetRemovedReason is used to test if the device is removed
+ HRESULT result = mDevice->GetDeviceRemovedReason();
+ isLost = d3d11::isDeviceLostError(result);
+
+ if (isLost)
+ {
+ // Log error if this is a new device lost event
+ if (mDeviceLost == false)
+ {
+ ERR("The D3D11 device was removed: 0x%08X", result);
+ }
+
+ // ensure we note the device loss --
+ // we'll probably get this done again by notifyDeviceLost
+ // but best to remember it!
+ // Note that we don't want to clear the device loss status here
+ // -- this needs to be done by resetDevice
+ mDeviceLost = true;
+ if (notify)
+ {
+ notifyDeviceLost();
+ }
+ }
+
+ return isLost;
+}
+
+bool Renderer11::testDeviceResettable()
+{
+ // determine if the device is resettable by creating a dummy device
+ PFN_D3D11_CREATE_DEVICE D3D11CreateDevice = (PFN_D3D11_CREATE_DEVICE)GetProcAddress(mD3d11Module, "D3D11CreateDevice");
+
+ if (D3D11CreateDevice == NULL)
+ {
+ return false;
+ }
+
+ D3D_FEATURE_LEVEL featureLevels[] =
+ {
+ D3D_FEATURE_LEVEL_11_0,
+ D3D_FEATURE_LEVEL_10_1,
+ D3D_FEATURE_LEVEL_10_0,
+ };
+
+ ID3D11Device* dummyDevice;
+ D3D_FEATURE_LEVEL dummyFeatureLevel;
+ ID3D11DeviceContext* dummyContext;
+
+ HRESULT result = D3D11CreateDevice(NULL,
+ D3D_DRIVER_TYPE_HARDWARE,
+ NULL,
+ #if defined(_DEBUG)
+ D3D11_CREATE_DEVICE_DEBUG,
+ #else
+ 0,
+ #endif
+ featureLevels,
+ ArraySize(featureLevels),
+ D3D11_SDK_VERSION,
+ &dummyDevice,
+ &dummyFeatureLevel,
+ &dummyContext);
+
+ if (!mDevice || FAILED(result))
+ {
+ return false;
+ }
+
+ dummyContext->Release();
+ dummyDevice->Release();
+
+ return true;
+}
+
+void Renderer11::release()
+{
+ releaseDeviceResources();
+
+ if (mDxgiFactory)
+ {
+ mDxgiFactory->Release();
+ mDxgiFactory = NULL;
+ }
+
+ if (mDxgiAdapter)
+ {
+ mDxgiAdapter->Release();
+ mDxgiAdapter = NULL;
+ }
+
+ if (mDeviceContext)
+ {
+ mDeviceContext->ClearState();
+ mDeviceContext->Flush();
+ mDeviceContext->Release();
+ mDeviceContext = NULL;
+ }
+
+ if (mDevice)
+ {
+ mDevice->Release();
+ mDevice = NULL;
+ }
+
+ if (mD3d11Module)
+ {
+ FreeLibrary(mD3d11Module);
+ mD3d11Module = NULL;
+ }
+
+ if (mDxgiModule)
+ {
+ FreeLibrary(mDxgiModule);
+ mDxgiModule = NULL;
+ }
+}
+
+bool Renderer11::resetDevice()
+{
+ // recreate everything
+ release();
+ EGLint result = initialize();
+
+ if (result != EGL_SUCCESS)
+ {
+ ERR("Could not reinitialize D3D11 device: %08X", result);
+ return false;
+ }
+
+ mDeviceLost = false;
+
+ return true;
+}
+
+DWORD Renderer11::getAdapterVendor() const
+{
+ return mAdapterDescription.VendorId;
+}
+
+std::string Renderer11::getRendererDescription() const
+{
+ std::ostringstream rendererString;
+
+ rendererString << mDescription;
+ rendererString << " Direct3D11";
+
+ rendererString << " vs_" << getMajorShaderModel() << "_" << getMinorShaderModel();
+ rendererString << " ps_" << getMajorShaderModel() << "_" << getMinorShaderModel();
+
+ return rendererString.str();
+}
+
+GUID Renderer11::getAdapterIdentifier() const
+{
+ // Use the adapter LUID as our adapter ID
+ // This number is local to a machine is only guaranteed to be unique between restarts
+ META_ASSERT(sizeof(LUID) <= sizeof(GUID));
+ GUID adapterId = {0};
+ memcpy(&adapterId, &mAdapterDescription.AdapterLuid, sizeof(LUID));
+ return adapterId;
+}
+
+bool Renderer11::getBGRATextureSupport() const
+{
+ return mBGRATextureSupport;
+}
+
+bool Renderer11::getDXT1TextureSupport()
+{
+ return mDXT1TextureSupport;
+}
+
+bool Renderer11::getDXT3TextureSupport()
+{
+ return mDXT3TextureSupport;
+}
+
+bool Renderer11::getDXT5TextureSupport()
+{
+ return mDXT5TextureSupport;
+}
+
+bool Renderer11::getDepthTextureSupport() const
+{
+ return mDepthTextureSupport;
+}
+
+bool Renderer11::getFloat32TextureSupport(bool *filtering, bool *renderable)
+{
+ *renderable = mFloat32RenderSupport;
+ *filtering = mFloat32FilterSupport;
+ return mFloat32TextureSupport;
+}
+
+bool Renderer11::getFloat16TextureSupport(bool *filtering, bool *renderable)
+{
+ *renderable = mFloat16RenderSupport;
+ *filtering = mFloat16FilterSupport;
+ return mFloat16TextureSupport;
+}
+
+bool Renderer11::getLuminanceTextureSupport()
+{
+ return false;
+}
+
+bool Renderer11::getLuminanceAlphaTextureSupport()
+{
+ return false;
+}
+
+bool Renderer11::getTextureFilterAnisotropySupport() const
+{
+ return true;
+}
+
+float Renderer11::getTextureMaxAnisotropy() const
+{
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0:
+ return D3D11_MAX_MAXANISOTROPY;
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0:
+ return D3D10_MAX_MAXANISOTROPY;
+ default: UNREACHABLE();
+ return 0;
+ }
+}
+
+bool Renderer11::getEventQuerySupport()
+{
+ return true;
+}
+
+Range Renderer11::getViewportBounds() const
+{
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0:
+ return Range(D3D11_VIEWPORT_BOUNDS_MIN, D3D11_VIEWPORT_BOUNDS_MAX);
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0:
+ return Range(D3D10_VIEWPORT_BOUNDS_MIN, D3D10_VIEWPORT_BOUNDS_MAX);
+ default: UNREACHABLE();
+ return Range(0, 0);
+ }
+}
+
+unsigned int Renderer11::getMaxVertexTextureImageUnits() const
+{
+ META_ASSERT(MAX_TEXTURE_IMAGE_UNITS_VTF_SM4 <= gl::IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS);
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0:
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0:
+ return MAX_TEXTURE_IMAGE_UNITS_VTF_SM4;
+ default: UNREACHABLE();
+ return 0;
+ }
+}
+
+unsigned int Renderer11::getMaxCombinedTextureImageUnits() const
+{
+ return gl::MAX_TEXTURE_IMAGE_UNITS + getMaxVertexTextureImageUnits();
+}
+
+unsigned int Renderer11::getReservedVertexUniformVectors() const
+{
+ return 0; // Driver uniforms are stored in a separate constant buffer
+}
+
+unsigned int Renderer11::getReservedFragmentUniformVectors() const
+{
+ return 0; // Driver uniforms are stored in a separate constant buffer
+}
+
+unsigned int Renderer11::getMaxVertexUniformVectors() const
+{
+ META_ASSERT(MAX_VERTEX_UNIFORM_VECTORS_D3D11 <= D3D10_REQ_CONSTANT_BUFFER_ELEMENT_COUNT);
+ ASSERT(mFeatureLevel >= D3D_FEATURE_LEVEL_10_0);
+ return MAX_VERTEX_UNIFORM_VECTORS_D3D11;
+}
+
+unsigned int Renderer11::getMaxFragmentUniformVectors() const
+{
+ META_ASSERT(MAX_FRAGMENT_UNIFORM_VECTORS_D3D11 <= D3D10_REQ_CONSTANT_BUFFER_ELEMENT_COUNT);
+ ASSERT(mFeatureLevel >= D3D_FEATURE_LEVEL_10_0);
+ return MAX_FRAGMENT_UNIFORM_VECTORS_D3D11;
+}
+
+unsigned int Renderer11::getMaxVaryingVectors() const
+{
+ META_ASSERT(gl::IMPLEMENTATION_MAX_VARYING_VECTORS == D3D11_VS_OUTPUT_REGISTER_COUNT);
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0:
+ return D3D11_VS_OUTPUT_REGISTER_COUNT;
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0:
+ return D3D10_VS_OUTPUT_REGISTER_COUNT;
+ default: UNREACHABLE();
+ return 0;
+ }
+}
+
+bool Renderer11::getNonPower2TextureSupport() const
+{
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0:
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0:
+ return true;
+ default: UNREACHABLE();
+ return false;
+ }
+}
+
+bool Renderer11::getOcclusionQuerySupport() const
+{
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0:
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0:
+ return true;
+ default: UNREACHABLE();
+ return false;
+ }
+}
+
+bool Renderer11::getInstancingSupport() const
+{
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0:
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0:
+ return true;
+ default: UNREACHABLE();
+ return false;
+ }
+}
+
+bool Renderer11::getShareHandleSupport() const
+{
+ // We only currently support share handles with BGRA surfaces, because
+ // chrome needs BGRA. Once chrome fixes this, we should always support them.
+ // PIX doesn't seem to support using share handles, so disable them.
+ return getBGRATextureSupport() && !gl::perfActive();
+}
+
+bool Renderer11::getDerivativeInstructionSupport() const
+{
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0:
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0:
+ return true;
+ default: UNREACHABLE();
+ return false;
+ }
+}
+
+bool Renderer11::getPostSubBufferSupport() const
+{
+ // D3D11 does not support present with dirty rectangles until D3D11.1 and DXGI 1.2.
+ return false;
+}
+
+int Renderer11::getMajorShaderModel() const
+{
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0: return D3D11_SHADER_MAJOR_VERSION; // 5
+ case D3D_FEATURE_LEVEL_10_1: return D3D10_1_SHADER_MAJOR_VERSION; // 4
+ case D3D_FEATURE_LEVEL_10_0: return D3D10_SHADER_MAJOR_VERSION; // 4
+ default: UNREACHABLE(); return 0;
+ }
+}
+
+int Renderer11::getMinorShaderModel() const
+{
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0: return D3D11_SHADER_MINOR_VERSION; // 0
+ case D3D_FEATURE_LEVEL_10_1: return D3D10_1_SHADER_MINOR_VERSION; // 1
+ case D3D_FEATURE_LEVEL_10_0: return D3D10_SHADER_MINOR_VERSION; // 0
+ default: UNREACHABLE(); return 0;
+ }
+}
+
+float Renderer11::getMaxPointSize() const
+{
+ // choose a reasonable maximum. we enforce this in the shader.
+ // (nb: on a Radeon 2600xt, DX9 reports a 256 max point size)
+ return 1024.0f;
+}
+
+int Renderer11::getMaxViewportDimension() const
+{
+ // Maximum viewport size must be at least as large as the largest render buffer (or larger).
+ // In our case return the maximum texture size, which is the maximum render buffer size.
+ META_ASSERT(D3D11_REQ_TEXTURE2D_U_OR_V_DIMENSION * 2 - 1 <= D3D11_VIEWPORT_BOUNDS_MAX);
+ META_ASSERT(D3D10_REQ_TEXTURE2D_U_OR_V_DIMENSION * 2 - 1 <= D3D10_VIEWPORT_BOUNDS_MAX);
+
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0:
+ return D3D11_REQ_TEXTURE2D_U_OR_V_DIMENSION; // 16384
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0:
+ return D3D10_REQ_TEXTURE2D_U_OR_V_DIMENSION; // 8192
+ default: UNREACHABLE();
+ return 0;
+ }
+}
+
+int Renderer11::getMaxTextureWidth() const
+{
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0: return D3D11_REQ_TEXTURE2D_U_OR_V_DIMENSION; // 16384
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0: return D3D10_REQ_TEXTURE2D_U_OR_V_DIMENSION; // 8192
+ default: UNREACHABLE(); return 0;
+ }
+}
+
+int Renderer11::getMaxTextureHeight() const
+{
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0: return D3D11_REQ_TEXTURE2D_U_OR_V_DIMENSION; // 16384
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0: return D3D10_REQ_TEXTURE2D_U_OR_V_DIMENSION; // 8192
+ default: UNREACHABLE(); return 0;
+ }
+}
+
+bool Renderer11::get32BitIndexSupport() const
+{
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0:
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0: return D3D10_REQ_DRAWINDEXED_INDEX_COUNT_2_TO_EXP >= 32; // true
+ default: UNREACHABLE(); return false;
+ }
+}
+
+int Renderer11::getMinSwapInterval() const
+{
+ return 0;
+}
+
+int Renderer11::getMaxSwapInterval() const
+{
+ return 4;
+}
+
+int Renderer11::getMaxSupportedSamples() const
+{
+ return mMaxSupportedSamples;
+}
+
+int Renderer11::getNearestSupportedSamples(DXGI_FORMAT format, unsigned int requested) const
+{
+ if (requested == 0)
+ {
+ return 0;
+ }
+
+ MultisampleSupportMap::const_iterator iter = mMultisampleSupportMap.find(format);
+ if (iter != mMultisampleSupportMap.end())
+ {
+ const MultisampleSupportInfo& info = iter->second;
+ for (unsigned int i = requested - 1; i < D3D11_MAX_MULTISAMPLE_SAMPLE_COUNT; i++)
+ {
+ if (info.qualityLevels[i] > 0)
+ {
+ return i + 1;
+ }
+ }
+ }
+
+ return -1;
+}
+
+unsigned int Renderer11::getMaxRenderTargets() const
+{
+ META_ASSERT(D3D11_SIMULTANEOUS_RENDER_TARGET_COUNT <= gl::IMPLEMENTATION_MAX_DRAW_BUFFERS);
+ META_ASSERT(D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT <= gl::IMPLEMENTATION_MAX_DRAW_BUFFERS);
+
+ switch (mFeatureLevel)
+ {
+ case D3D_FEATURE_LEVEL_11_0:
+ return D3D11_SIMULTANEOUS_RENDER_TARGET_COUNT; // 8
+ case D3D_FEATURE_LEVEL_10_1:
+ case D3D_FEATURE_LEVEL_10_0:
+ return D3D10_SIMULTANEOUS_RENDER_TARGET_COUNT; // 8
+ default:
+ UNREACHABLE();
+ return 1;
+ }
+}
+
+bool Renderer11::copyToRenderTarget(TextureStorageInterface2D *dest, TextureStorageInterface2D *source)
+{
+ if (source && dest)
+ {
+ TextureStorage11_2D *source11 = TextureStorage11_2D::makeTextureStorage11_2D(source->getStorageInstance());
+ TextureStorage11_2D *dest11 = TextureStorage11_2D::makeTextureStorage11_2D(dest->getStorageInstance());
+
+ mDeviceContext->CopyResource(dest11->getBaseTexture(), source11->getBaseTexture());
+ return true;
+ }
+
+ return false;
+}
+
+bool Renderer11::copyToRenderTarget(TextureStorageInterfaceCube *dest, TextureStorageInterfaceCube *source)
+{
+ if (source && dest)
+ {
+ TextureStorage11_Cube *source11 = TextureStorage11_Cube::makeTextureStorage11_Cube(source->getStorageInstance());
+ TextureStorage11_Cube *dest11 = TextureStorage11_Cube::makeTextureStorage11_Cube(dest->getStorageInstance());
+
+ mDeviceContext->CopyResource(dest11->getBaseTexture(), source11->getBaseTexture());
+ return true;
+ }
+
+ return false;
+}
+
+bool Renderer11::copyImage(gl::Framebuffer *framebuffer, const gl::Rectangle &sourceRect, GLenum destFormat,
+ GLint xoffset, GLint yoffset, TextureStorageInterface2D *storage, GLint level)
+{
+ gl::Renderbuffer *colorbuffer = framebuffer->getReadColorbuffer();
+ if (!colorbuffer)
+ {
+ ERR("Failed to retrieve the color buffer from the frame buffer.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ RenderTarget11 *sourceRenderTarget = RenderTarget11::makeRenderTarget11(colorbuffer->getRenderTarget());
+ if (!sourceRenderTarget)
+ {
+ ERR("Failed to retrieve the render target from the frame buffer.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ ID3D11ShaderResourceView *source = sourceRenderTarget->getShaderResourceView();
+ if (!source)
+ {
+ ERR("Failed to retrieve the render target view from the render target.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ TextureStorage11_2D *storage11 = TextureStorage11_2D::makeTextureStorage11_2D(storage->getStorageInstance());
+ if (!storage11)
+ {
+ source->Release();
+ ERR("Failed to retrieve the texture storage from the destination.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ RenderTarget11 *destRenderTarget = RenderTarget11::makeRenderTarget11(storage11->getRenderTarget(level));
+ if (!destRenderTarget)
+ {
+ source->Release();
+ ERR("Failed to retrieve the render target from the destination storage.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ ID3D11RenderTargetView *dest = destRenderTarget->getRenderTargetView();
+ if (!dest)
+ {
+ source->Release();
+ ERR("Failed to retrieve the render target view from the destination render target.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ gl::Rectangle destRect;
+ destRect.x = xoffset;
+ destRect.y = yoffset;
+ destRect.width = sourceRect.width;
+ destRect.height = sourceRect.height;
+
+ bool ret = copyTexture(source, sourceRect, sourceRenderTarget->getWidth(), sourceRenderTarget->getHeight(),
+ dest, destRect, destRenderTarget->getWidth(), destRenderTarget->getHeight(), destFormat);
+
+ source->Release();
+ dest->Release();
+
+ return ret;
+}
+
+bool Renderer11::copyImage(gl::Framebuffer *framebuffer, const gl::Rectangle &sourceRect, GLenum destFormat,
+ GLint xoffset, GLint yoffset, TextureStorageInterfaceCube *storage, GLenum target, GLint level)
+{
+ gl::Renderbuffer *colorbuffer = framebuffer->getReadColorbuffer();
+ if (!colorbuffer)
+ {
+ ERR("Failed to retrieve the color buffer from the frame buffer.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ RenderTarget11 *sourceRenderTarget = RenderTarget11::makeRenderTarget11(colorbuffer->getRenderTarget());
+ if (!sourceRenderTarget)
+ {
+ ERR("Failed to retrieve the render target from the frame buffer.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ ID3D11ShaderResourceView *source = sourceRenderTarget->getShaderResourceView();
+ if (!source)
+ {
+ ERR("Failed to retrieve the render target view from the render target.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ TextureStorage11_Cube *storage11 = TextureStorage11_Cube::makeTextureStorage11_Cube(storage->getStorageInstance());
+ if (!storage11)
+ {
+ source->Release();
+ ERR("Failed to retrieve the texture storage from the destination.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ RenderTarget11 *destRenderTarget = RenderTarget11::makeRenderTarget11(storage11->getRenderTarget(target, level));
+ if (!destRenderTarget)
+ {
+ source->Release();
+ ERR("Failed to retrieve the render target from the destination storage.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ ID3D11RenderTargetView *dest = destRenderTarget->getRenderTargetView();
+ if (!dest)
+ {
+ source->Release();
+ ERR("Failed to retrieve the render target view from the destination render target.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ gl::Rectangle destRect;
+ destRect.x = xoffset;
+ destRect.y = yoffset;
+ destRect.width = sourceRect.width;
+ destRect.height = sourceRect.height;
+
+ bool ret = copyTexture(source, sourceRect, sourceRenderTarget->getWidth(), sourceRenderTarget->getHeight(),
+ dest, destRect, destRenderTarget->getWidth(), destRenderTarget->getHeight(), destFormat);
+
+ source->Release();
+ dest->Release();
+
+ return ret;
+}
+
+bool Renderer11::copyTexture(ID3D11ShaderResourceView *source, const gl::Rectangle &sourceArea, unsigned int sourceWidth, unsigned int sourceHeight,
+ ID3D11RenderTargetView *dest, const gl::Rectangle &destArea, unsigned int destWidth, unsigned int destHeight, GLenum destFormat)
+{
+ HRESULT result;
+
+ if (!mCopyResourcesInitialized)
+ {
+ ASSERT(!mCopyVB && !mCopySampler && !mCopyIL && !mCopyVS && !mCopyRGBAPS && !mCopyRGBPS && !mCopyLumPS && !mCopyLumAlphaPS);
+
+ D3D11_BUFFER_DESC vbDesc;
+ vbDesc.ByteWidth = sizeof(d3d11::PositionTexCoordVertex) * 4;
+ vbDesc.Usage = D3D11_USAGE_DYNAMIC;
+ vbDesc.BindFlags = D3D11_BIND_VERTEX_BUFFER;
+ vbDesc.CPUAccessFlags = D3D11_CPU_ACCESS_WRITE;
+ vbDesc.MiscFlags = 0;
+ vbDesc.StructureByteStride = 0;
+
+ result = mDevice->CreateBuffer(&vbDesc, NULL, &mCopyVB);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mCopyVB, "Renderer11 copy texture vertex buffer");
+
+ D3D11_SAMPLER_DESC samplerDesc;
+ samplerDesc.Filter = D3D11_FILTER_MIN_MAG_MIP_LINEAR;
+ samplerDesc.AddressU = D3D11_TEXTURE_ADDRESS_CLAMP;
+ samplerDesc.AddressV = D3D11_TEXTURE_ADDRESS_CLAMP;
+ samplerDesc.AddressW = D3D11_TEXTURE_ADDRESS_CLAMP;
+ samplerDesc.MipLODBias = 0.0f;
+ samplerDesc.MaxAnisotropy = 0;
+ samplerDesc.ComparisonFunc = D3D11_COMPARISON_NEVER;
+ samplerDesc.BorderColor[0] = 0.0f;
+ samplerDesc.BorderColor[1] = 0.0f;
+ samplerDesc.BorderColor[2] = 0.0f;
+ samplerDesc.BorderColor[3] = 0.0f;
+ samplerDesc.MinLOD = 0.0f;
+ samplerDesc.MaxLOD = 0.0f;
+
+ result = mDevice->CreateSamplerState(&samplerDesc, &mCopySampler);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mCopySampler, "Renderer11 copy sampler");
+
+ D3D11_INPUT_ELEMENT_DESC quadLayout[] =
+ {
+ { "POSITION", 0, DXGI_FORMAT_R32G32_FLOAT, 0, 0, D3D11_INPUT_PER_VERTEX_DATA, 0 },
+ { "TEXCOORD", 0, DXGI_FORMAT_R32G32_FLOAT, 0, 8, D3D11_INPUT_PER_VERTEX_DATA, 0 },
+ };
+
+ result = mDevice->CreateInputLayout(quadLayout, 2, g_VS_Passthrough, sizeof(g_VS_Passthrough), &mCopyIL);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mCopyIL, "Renderer11 copy texture input layout");
+
+ result = mDevice->CreateVertexShader(g_VS_Passthrough, sizeof(g_VS_Passthrough), NULL, &mCopyVS);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mCopyVS, "Renderer11 copy texture vertex shader");
+
+ result = mDevice->CreatePixelShader(g_PS_PassthroughRGBA, sizeof(g_PS_PassthroughRGBA), NULL, &mCopyRGBAPS);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mCopyRGBAPS, "Renderer11 copy texture RGBA pixel shader");
+
+ result = mDevice->CreatePixelShader(g_PS_PassthroughRGB, sizeof(g_PS_PassthroughRGB), NULL, &mCopyRGBPS);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mCopyRGBPS, "Renderer11 copy texture RGB pixel shader");
+
+ result = mDevice->CreatePixelShader(g_PS_PassthroughLum, sizeof(g_PS_PassthroughLum), NULL, &mCopyLumPS);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mCopyLumPS, "Renderer11 copy texture luminance pixel shader");
+
+ result = mDevice->CreatePixelShader(g_PS_PassthroughLumAlpha, sizeof(g_PS_PassthroughLumAlpha), NULL, &mCopyLumAlphaPS);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mCopyLumAlphaPS, "Renderer11 copy texture luminance alpha pixel shader");
+
+ mCopyResourcesInitialized = true;
+ }
+
+ // Verify the source and destination area sizes
+ if (sourceArea.x < 0 || sourceArea.x + sourceArea.width > static_cast<int>(sourceWidth) ||
+ sourceArea.y < 0 || sourceArea.y + sourceArea.height > static_cast<int>(sourceHeight) ||
+ destArea.x < 0 || destArea.x + destArea.width > static_cast<int>(destWidth) ||
+ destArea.y < 0 || destArea.y + destArea.height > static_cast<int>(destHeight))
+ {
+ return gl::error(GL_INVALID_VALUE, false);
+ }
+
+ // Set vertices
+ D3D11_MAPPED_SUBRESOURCE mappedResource;
+ result = mDeviceContext->Map(mCopyVB, 0, D3D11_MAP_WRITE_DISCARD, 0, &mappedResource);
+ if (FAILED(result))
+ {
+ ERR("Failed to map vertex buffer for texture copy, HRESULT: 0x%X.", result);
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ d3d11::PositionTexCoordVertex *vertices = static_cast<d3d11::PositionTexCoordVertex*>(mappedResource.pData);
+
+ // Create a quad in homogeneous coordinates
+ float x1 = (destArea.x / float(destWidth)) * 2.0f - 1.0f;
+ float y1 = ((destHeight - destArea.y - destArea.height) / float(destHeight)) * 2.0f - 1.0f;
+ float x2 = ((destArea.x + destArea.width) / float(destWidth)) * 2.0f - 1.0f;
+ float y2 = ((destHeight - destArea.y) / float(destHeight)) * 2.0f - 1.0f;
+
+ float u1 = sourceArea.x / float(sourceWidth);
+ float v1 = sourceArea.y / float(sourceHeight);
+ float u2 = (sourceArea.x + sourceArea.width) / float(sourceWidth);
+ float v2 = (sourceArea.y + sourceArea.height) / float(sourceHeight);
+
+ d3d11::SetPositionTexCoordVertex(&vertices[0], x1, y1, u1, v2);
+ d3d11::SetPositionTexCoordVertex(&vertices[1], x1, y2, u1, v1);
+ d3d11::SetPositionTexCoordVertex(&vertices[2], x2, y1, u2, v2);
+ d3d11::SetPositionTexCoordVertex(&vertices[3], x2, y2, u2, v1);
+
+ mDeviceContext->Unmap(mCopyVB, 0);
+
+ static UINT stride = sizeof(d3d11::PositionTexCoordVertex);
+ static UINT startIdx = 0;
+ mDeviceContext->IASetVertexBuffers(0, 1, &mCopyVB, &stride, &startIdx);
+
+ // Apply state
+ mDeviceContext->OMSetBlendState(NULL, NULL, 0xFFFFFFF);
+ mDeviceContext->OMSetDepthStencilState(NULL, 0xFFFFFFFF);
+ mDeviceContext->RSSetState(NULL);
+
+ // Apply shaders
+ mDeviceContext->IASetInputLayout(mCopyIL);
+ mDeviceContext->IASetPrimitiveTopology(D3D_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP);
+ mDeviceContext->VSSetShader(mCopyVS, NULL, 0);
+
+ ID3D11PixelShader *ps = NULL;
+ switch(destFormat)
+ {
+ case GL_RGBA: ps = mCopyRGBAPS; break;
+ case GL_RGB: ps = mCopyRGBPS; break;
+ case GL_ALPHA: ps = mCopyRGBAPS; break;
+ case GL_BGRA_EXT: ps = mCopyRGBAPS; break;
+ case GL_LUMINANCE: ps = mCopyLumPS; break;
+ case GL_LUMINANCE_ALPHA: ps = mCopyLumAlphaPS; break;
+ default: UNREACHABLE(); ps = NULL; break;
+ }
+
+ mDeviceContext->PSSetShader(ps, NULL, 0);
+ mDeviceContext->GSSetShader(NULL, NULL, 0);
+
+ // Unset the currently bound shader resource to avoid conflicts
+ static ID3D11ShaderResourceView *const nullSRV = NULL;
+ mDeviceContext->PSSetShaderResources(0, 1, &nullSRV);
+
+ // Apply render target
+ setOneTimeRenderTarget(dest);
+
+ // Set the viewport
+ D3D11_VIEWPORT viewport;
+ viewport.TopLeftX = 0;
+ viewport.TopLeftY = 0;
+ viewport.Width = destWidth;
+ viewport.Height = destHeight;
+ viewport.MinDepth = 0.0f;
+ viewport.MaxDepth = 1.0f;
+ mDeviceContext->RSSetViewports(1, &viewport);
+
+ // Apply textures
+ mDeviceContext->PSSetShaderResources(0, 1, &source);
+ mDeviceContext->PSSetSamplers(0, 1, &mCopySampler);
+
+ // Draw the quad
+ mDeviceContext->Draw(4, 0);
+
+ // Unbind textures and render targets and vertex buffer
+ mDeviceContext->PSSetShaderResources(0, 1, &nullSRV);
+
+ unapplyRenderTargets();
+
+ UINT zero = 0;
+ ID3D11Buffer *const nullBuffer = NULL;
+ mDeviceContext->IASetVertexBuffers(0, 1, &nullBuffer, &zero, &zero);
+
+ markAllStateDirty();
+
+ return true;
+}
+
+void Renderer11::unapplyRenderTargets()
+{
+ setOneTimeRenderTarget(NULL);
+}
+
+void Renderer11::setOneTimeRenderTarget(ID3D11RenderTargetView *renderTargetView)
+{
+ ID3D11RenderTargetView *rtvArray[gl::IMPLEMENTATION_MAX_DRAW_BUFFERS] = {NULL};
+
+ rtvArray[0] = renderTargetView;
+
+ mDeviceContext->OMSetRenderTargets(getMaxRenderTargets(), rtvArray, NULL);
+
+ // Do not preserve the serial for this one-time-use render target
+ for (unsigned int rtIndex = 0; rtIndex < gl::IMPLEMENTATION_MAX_DRAW_BUFFERS; rtIndex++)
+ {
+ mAppliedRenderTargetSerials[rtIndex] = 0;
+ }
+}
+
+RenderTarget *Renderer11::createRenderTarget(SwapChain *swapChain, bool depth)
+{
+ SwapChain11 *swapChain11 = SwapChain11::makeSwapChain11(swapChain);
+ RenderTarget11 *renderTarget = NULL;
+
+ if (depth)
+ {
+ // Note: depth stencil may be NULL for 0 sized surfaces
+ renderTarget = new RenderTarget11(this, swapChain11->getDepthStencil(),
+ swapChain11->getDepthStencilTexture(), NULL,
+ swapChain11->getWidth(), swapChain11->getHeight());
+ }
+ else
+ {
+ // Note: render target may be NULL for 0 sized surfaces
+ renderTarget = new RenderTarget11(this, swapChain11->getRenderTarget(),
+ swapChain11->getOffscreenTexture(),
+ swapChain11->getRenderTargetShaderResource(),
+ swapChain11->getWidth(), swapChain11->getHeight());
+ }
+ return renderTarget;
+}
+
+RenderTarget *Renderer11::createRenderTarget(int width, int height, GLenum format, GLsizei samples, bool depth)
+{
+ RenderTarget11 *renderTarget = new RenderTarget11(this, width, height, format, samples, depth);
+ return renderTarget;
+}
+
+ShaderExecutable *Renderer11::loadExecutable(const void *function, size_t length, rx::ShaderType type)
+{
+ ShaderExecutable11 *executable = NULL;
+
+ switch (type)
+ {
+ case rx::SHADER_VERTEX:
+ {
+ ID3D11VertexShader *vshader = NULL;
+ HRESULT result = mDevice->CreateVertexShader(function, length, NULL, &vshader);
+ ASSERT(SUCCEEDED(result));
+
+ if (vshader)
+ {
+ executable = new ShaderExecutable11(function, length, vshader);
+ }
+ }
+ break;
+ case rx::SHADER_PIXEL:
+ {
+ ID3D11PixelShader *pshader = NULL;
+ HRESULT result = mDevice->CreatePixelShader(function, length, NULL, &pshader);
+ ASSERT(SUCCEEDED(result));
+
+ if (pshader)
+ {
+ executable = new ShaderExecutable11(function, length, pshader);
+ }
+ }
+ break;
+ case rx::SHADER_GEOMETRY:
+ {
+ ID3D11GeometryShader *gshader = NULL;
+ HRESULT result = mDevice->CreateGeometryShader(function, length, NULL, &gshader);
+ ASSERT(SUCCEEDED(result));
+
+ if (gshader)
+ {
+ executable = new ShaderExecutable11(function, length, gshader);
+ }
+ }
+ break;
+ default:
+ UNREACHABLE();
+ break;
+ }
+
+ return executable;
+}
+
+ShaderExecutable *Renderer11::compileToExecutable(gl::InfoLog &infoLog, const char *shaderHLSL, rx::ShaderType type)
+{
+ const char *profile = NULL;
+
+ switch (type)
+ {
+ case rx::SHADER_VERTEX:
+ profile = "vs_4_0";
+ break;
+ case rx::SHADER_PIXEL:
+ profile = "ps_4_0";
+ break;
+ case rx::SHADER_GEOMETRY:
+ profile = "gs_4_0";
+ break;
+ default:
+ UNREACHABLE();
+ return NULL;
+ }
+
+ ID3DBlob *binary = (ID3DBlob*)compileToBinary(infoLog, shaderHLSL, profile, D3DCOMPILE_OPTIMIZATION_LEVEL0, false);
+ if (!binary)
+ return NULL;
+
+ ShaderExecutable *executable = loadExecutable((DWORD *)binary->GetBufferPointer(), binary->GetBufferSize(), type);
+ binary->Release();
+
+ return executable;
+}
+
+VertexBuffer *Renderer11::createVertexBuffer()
+{
+ return new VertexBuffer11(this);
+}
+
+IndexBuffer *Renderer11::createIndexBuffer()
+{
+ return new IndexBuffer11(this);
+}
+
+BufferStorage *Renderer11::createBufferStorage()
+{
+ return new BufferStorage11(this);
+}
+
+QueryImpl *Renderer11::createQuery(GLenum type)
+{
+ return new Query11(this, type);
+}
+
+FenceImpl *Renderer11::createFence()
+{
+ return new Fence11(this);
+}
+
+bool Renderer11::getRenderTargetResource(gl::Renderbuffer *colorbuffer, unsigned int *subresourceIndex, ID3D11Texture2D **resource)
+{
+ ASSERT(colorbuffer != NULL);
+
+ RenderTarget11 *renderTarget = RenderTarget11::makeRenderTarget11(colorbuffer->getRenderTarget());
+ if (renderTarget)
+ {
+ *subresourceIndex = renderTarget->getSubresourceIndex();
+
+ ID3D11RenderTargetView *colorBufferRTV = renderTarget->getRenderTargetView();
+ if (colorBufferRTV)
+ {
+ ID3D11Resource *textureResource = NULL;
+ colorBufferRTV->GetResource(&textureResource);
+ colorBufferRTV->Release();
+
+ if (textureResource)
+ {
+ HRESULT result = textureResource->QueryInterface(IID_ID3D11Texture2D, (void**)resource);
+ textureResource->Release();
+
+ if (SUCCEEDED(result))
+ {
+ return true;
+ }
+ else
+ {
+ ERR("Failed to extract the ID3D11Texture2D from the render target resource, "
+ "HRESULT: 0x%X.", result);
+ }
+ }
+ }
+ }
+
+ return false;
+}
+
+bool Renderer11::blitRect(gl::Framebuffer *readTarget, const gl::Rectangle &readRect, gl::Framebuffer *drawTarget, const gl::Rectangle &drawRect,
+ bool blitRenderTarget, bool blitDepthStencil)
+{
+ if (blitRenderTarget)
+ {
+ gl::Renderbuffer *readBuffer = readTarget->getReadColorbuffer();
+
+ if (!readBuffer)
+ {
+ ERR("Failed to retrieve the read buffer from the read framebuffer.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ RenderTarget *readRenderTarget = readBuffer->getRenderTarget();
+
+ for (unsigned int colorAttachment = 0; colorAttachment < gl::IMPLEMENTATION_MAX_DRAW_BUFFERS; colorAttachment++)
+ {
+ if (drawTarget->isEnabledColorAttachment(colorAttachment))
+ {
+ gl::Renderbuffer *drawBuffer = drawTarget->getColorbuffer(colorAttachment);
+
+ if (!drawBuffer)
+ {
+ ERR("Failed to retrieve the draw buffer from the draw framebuffer.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ RenderTarget *drawRenderTarget = drawBuffer->getRenderTarget();
+
+ if (!blitRenderbufferRect(readRect, drawRect, readRenderTarget, drawRenderTarget, false))
+ {
+ return false;
+ }
+ }
+ }
+ }
+
+ if (blitDepthStencil)
+ {
+ gl::Renderbuffer *readBuffer = readTarget->getDepthOrStencilbuffer();
+ gl::Renderbuffer *drawBuffer = drawTarget->getDepthOrStencilbuffer();
+
+ if (!readBuffer)
+ {
+ ERR("Failed to retrieve the read depth-stencil buffer from the read framebuffer.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ if (!drawBuffer)
+ {
+ ERR("Failed to retrieve the draw depth-stencil buffer from the draw framebuffer.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ RenderTarget *readRenderTarget = readBuffer->getDepthStencil();
+ RenderTarget *drawRenderTarget = drawBuffer->getDepthStencil();
+
+ if (!blitRenderbufferRect(readRect, drawRect, readRenderTarget, drawRenderTarget, true))
+ {
+ return false;
+ }
+ }
+
+ return true;
+}
+
+void Renderer11::readPixels(gl::Framebuffer *framebuffer, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type,
+ GLsizei outputPitch, bool packReverseRowOrder, GLint packAlignment, void* pixels)
+{
+ ID3D11Texture2D *colorBufferTexture = NULL;
+ unsigned int subresourceIndex = 0;
+
+ gl::Renderbuffer *colorbuffer = framebuffer->getReadColorbuffer();
+
+ if (colorbuffer && getRenderTargetResource(colorbuffer, &subresourceIndex, &colorBufferTexture))
+ {
+ gl::Rectangle area;
+ area.x = x;
+ area.y = y;
+ area.width = width;
+ area.height = height;
+
+ readTextureData(colorBufferTexture, subresourceIndex, area, format, type, outputPitch,
+ packReverseRowOrder, packAlignment, pixels);
+
+ colorBufferTexture->Release();
+ colorBufferTexture = NULL;
+ }
+}
+
+Image *Renderer11::createImage()
+{
+ return new Image11();
+}
+
+void Renderer11::generateMipmap(Image *dest, Image *src)
+{
+ Image11 *dest11 = Image11::makeImage11(dest);
+ Image11 *src11 = Image11::makeImage11(src);
+ Image11::generateMipmap(dest11, src11);
+}
+
+TextureStorage *Renderer11::createTextureStorage2D(SwapChain *swapChain)
+{
+ SwapChain11 *swapChain11 = SwapChain11::makeSwapChain11(swapChain);
+ return new TextureStorage11_2D(this, swapChain11);
+}
+
+TextureStorage *Renderer11::createTextureStorage2D(int levels, GLenum internalformat, GLenum usage, bool forceRenderable, GLsizei width, GLsizei height)
+{
+ return new TextureStorage11_2D(this, levels, internalformat, usage, forceRenderable, width, height);
+}
+
+TextureStorage *Renderer11::createTextureStorageCube(int levels, GLenum internalformat, GLenum usage, bool forceRenderable, int size)
+{
+ return new TextureStorage11_Cube(this, levels, internalformat, usage, forceRenderable, size);
+}
+
+static inline unsigned int getFastPixelCopySize(DXGI_FORMAT sourceFormat, GLenum destFormat, GLenum destType)
+{
+ if (sourceFormat == DXGI_FORMAT_A8_UNORM &&
+ destFormat == GL_ALPHA &&
+ destType == GL_UNSIGNED_BYTE)
+ {
+ return 1;
+ }
+ else if (sourceFormat == DXGI_FORMAT_R8G8B8A8_UNORM &&
+ destFormat == GL_RGBA &&
+ destType == GL_UNSIGNED_BYTE)
+ {
+ return 4;
+ }
+ else if (sourceFormat == DXGI_FORMAT_B8G8R8A8_UNORM &&
+ destFormat == GL_BGRA_EXT &&
+ destType == GL_UNSIGNED_BYTE)
+ {
+ return 4;
+ }
+ else if (sourceFormat == DXGI_FORMAT_R16G16B16A16_FLOAT &&
+ destFormat == GL_RGBA &&
+ destType == GL_HALF_FLOAT_OES)
+ {
+ return 8;
+ }
+ else if (sourceFormat == DXGI_FORMAT_R32G32B32_FLOAT &&
+ destFormat == GL_RGB &&
+ destType == GL_FLOAT)
+ {
+ return 12;
+ }
+ else if (sourceFormat == DXGI_FORMAT_R32G32B32A32_FLOAT &&
+ destFormat == GL_RGBA &&
+ destType == GL_FLOAT)
+ {
+ return 16;
+ }
+ else
+ {
+ return 0;
+ }
+}
+
+static inline void readPixelColor(const unsigned char *data, DXGI_FORMAT format, unsigned int x,
+ unsigned int y, int inputPitch, gl::Color *outColor)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_R8G8B8A8_UNORM:
+ {
+ unsigned int rgba = *reinterpret_cast<const unsigned int*>(data + 4 * x + y * inputPitch);
+ outColor->red = (rgba & 0x000000FF) * (1.0f / 0x000000FF);
+ outColor->green = (rgba & 0x0000FF00) * (1.0f / 0x0000FF00);
+ outColor->blue = (rgba & 0x00FF0000) * (1.0f / 0x00FF0000);
+ outColor->alpha = (rgba & 0xFF000000) * (1.0f / 0xFF000000);
+ }
+ break;
+
+ case DXGI_FORMAT_A8_UNORM:
+ {
+ outColor->red = 0.0f;
+ outColor->green = 0.0f;
+ outColor->blue = 0.0f;
+ outColor->alpha = *(data + x + y * inputPitch) / 255.0f;
+ }
+ break;
+
+ case DXGI_FORMAT_R32G32B32A32_FLOAT:
+ {
+ outColor->red = *(reinterpret_cast<const float*>(data + 16 * x + y * inputPitch) + 0);
+ outColor->green = *(reinterpret_cast<const float*>(data + 16 * x + y * inputPitch) + 1);
+ outColor->blue = *(reinterpret_cast<const float*>(data + 16 * x + y * inputPitch) + 2);
+ outColor->alpha = *(reinterpret_cast<const float*>(data + 16 * x + y * inputPitch) + 3);
+ }
+ break;
+
+ case DXGI_FORMAT_R32G32B32_FLOAT:
+ {
+ outColor->red = *(reinterpret_cast<const float*>(data + 12 * x + y * inputPitch) + 0);
+ outColor->green = *(reinterpret_cast<const float*>(data + 12 * x + y * inputPitch) + 1);
+ outColor->blue = *(reinterpret_cast<const float*>(data + 12 * x + y * inputPitch) + 2);
+ outColor->alpha = 1.0f;
+ }
+ break;
+
+ case DXGI_FORMAT_R16G16B16A16_FLOAT:
+ {
+ outColor->red = gl::float16ToFloat32(*(reinterpret_cast<const unsigned short*>(data + 8 * x + y * inputPitch) + 0));
+ outColor->green = gl::float16ToFloat32(*(reinterpret_cast<const unsigned short*>(data + 8 * x + y * inputPitch) + 1));
+ outColor->blue = gl::float16ToFloat32(*(reinterpret_cast<const unsigned short*>(data + 8 * x + y * inputPitch) + 2));
+ outColor->alpha = gl::float16ToFloat32(*(reinterpret_cast<const unsigned short*>(data + 8 * x + y * inputPitch) + 3));
+ }
+ break;
+
+ case DXGI_FORMAT_B8G8R8A8_UNORM:
+ {
+ unsigned int bgra = *reinterpret_cast<const unsigned int*>(data + 4 * x + y * inputPitch);
+ outColor->red = (bgra & 0x00FF0000) * (1.0f / 0x00FF0000);
+ outColor->blue = (bgra & 0x000000FF) * (1.0f / 0x000000FF);
+ outColor->green = (bgra & 0x0000FF00) * (1.0f / 0x0000FF00);
+ outColor->alpha = (bgra & 0xFF000000) * (1.0f / 0xFF000000);
+ }
+ break;
+
+ case DXGI_FORMAT_R8_UNORM:
+ {
+ outColor->red = *(data + x + y * inputPitch) / 255.0f;
+ outColor->green = 0.0f;
+ outColor->blue = 0.0f;
+ outColor->alpha = 1.0f;
+ }
+ break;
+
+ case DXGI_FORMAT_R8G8_UNORM:
+ {
+ unsigned short rg = *reinterpret_cast<const unsigned short*>(data + 2 * x + y * inputPitch);
+
+ outColor->red = (rg & 0xFF00) * (1.0f / 0xFF00);
+ outColor->green = (rg & 0x00FF) * (1.0f / 0x00FF);
+ outColor->blue = 0.0f;
+ outColor->alpha = 1.0f;
+ }
+ break;
+
+ case DXGI_FORMAT_R16_FLOAT:
+ {
+ outColor->red = gl::float16ToFloat32(*reinterpret_cast<const unsigned short*>(data + 2 * x + y * inputPitch));
+ outColor->green = 0.0f;
+ outColor->blue = 0.0f;
+ outColor->alpha = 1.0f;
+ }
+ break;
+
+ case DXGI_FORMAT_R16G16_FLOAT:
+ {
+ outColor->red = gl::float16ToFloat32(*(reinterpret_cast<const unsigned short*>(data + 4 * x + y * inputPitch) + 0));
+ outColor->green = gl::float16ToFloat32(*(reinterpret_cast<const unsigned short*>(data + 4 * x + y * inputPitch) + 1));
+ outColor->blue = 0.0f;
+ outColor->alpha = 1.0f;
+ }
+ break;
+
+ default:
+ ERR("ReadPixelColor not implemented for DXGI format %u.", format);
+ UNIMPLEMENTED();
+ break;
+ }
+}
+
+static inline void writePixelColor(const gl::Color &color, GLenum format, GLenum type, unsigned int x,
+ unsigned int y, int outputPitch, void *outData)
+{
+ unsigned char* byteData = reinterpret_cast<unsigned char*>(outData);
+ unsigned short* shortData = reinterpret_cast<unsigned short*>(outData);
+
+ switch (format)
+ {
+ case GL_RGBA:
+ switch (type)
+ {
+ case GL_UNSIGNED_BYTE:
+ byteData[4 * x + y * outputPitch + 0] = static_cast<unsigned char>(255 * color.red + 0.5f);
+ byteData[4 * x + y * outputPitch + 1] = static_cast<unsigned char>(255 * color.green + 0.5f);
+ byteData[4 * x + y * outputPitch + 2] = static_cast<unsigned char>(255 * color.blue + 0.5f);
+ byteData[4 * x + y * outputPitch + 3] = static_cast<unsigned char>(255 * color.alpha + 0.5f);
+ break;
+
+ default:
+ ERR("WritePixelColor not implemented for format GL_RGBA and type 0x%X.", type);
+ UNIMPLEMENTED();
+ break;
+ }
+ break;
+
+ case GL_BGRA_EXT:
+ switch (type)
+ {
+ case GL_UNSIGNED_BYTE:
+ byteData[4 * x + y * outputPitch + 0] = static_cast<unsigned char>(255 * color.blue + 0.5f);
+ byteData[4 * x + y * outputPitch + 1] = static_cast<unsigned char>(255 * color.green + 0.5f);
+ byteData[4 * x + y * outputPitch + 2] = static_cast<unsigned char>(255 * color.red + 0.5f);
+ byteData[4 * x + y * outputPitch + 3] = static_cast<unsigned char>(255 * color.alpha + 0.5f);
+ break;
+
+ case GL_UNSIGNED_SHORT_4_4_4_4_REV_EXT:
+ // According to the desktop GL spec in the "Transfer of Pixel Rectangles" section
+ // this type is packed as follows:
+ // 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
+ // --------------------------------------------------------------------------------
+ // | 4th | 3rd | 2nd | 1st component |
+ // --------------------------------------------------------------------------------
+ // in the case of BGRA_EXT, B is the first component, G the second, and so forth.
+ shortData[x + y * outputPitch / sizeof(unsigned short)] =
+ (static_cast<unsigned short>(15 * color.alpha + 0.5f) << 12) |
+ (static_cast<unsigned short>(15 * color.red + 0.5f) << 8) |
+ (static_cast<unsigned short>(15 * color.green + 0.5f) << 4) |
+ (static_cast<unsigned short>(15 * color.blue + 0.5f) << 0);
+ break;
+
+ case GL_UNSIGNED_SHORT_1_5_5_5_REV_EXT:
+ // According to the desktop GL spec in the "Transfer of Pixel Rectangles" section
+ // this type is packed as follows:
+ // 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
+ // --------------------------------------------------------------------------------
+ // | 4th | 3rd | 2nd | 1st component |
+ // --------------------------------------------------------------------------------
+ // in the case of BGRA_EXT, B is the first component, G the second, and so forth.
+ shortData[x + y * outputPitch / sizeof(unsigned short)] =
+ (static_cast<unsigned short>( color.alpha + 0.5f) << 15) |
+ (static_cast<unsigned short>(31 * color.red + 0.5f) << 10) |
+ (static_cast<unsigned short>(31 * color.green + 0.5f) << 5) |
+ (static_cast<unsigned short>(31 * color.blue + 0.5f) << 0);
+ break;
+
+ default:
+ ERR("WritePixelColor not implemented for format GL_BGRA_EXT and type 0x%X.", type);
+ UNIMPLEMENTED();
+ break;
+ }
+ break;
+
+ case GL_RGB:
+ switch (type)
+ {
+ case GL_UNSIGNED_SHORT_5_6_5:
+ shortData[x + y * outputPitch / sizeof(unsigned short)] =
+ (static_cast<unsigned short>(31 * color.blue + 0.5f) << 0) |
+ (static_cast<unsigned short>(63 * color.green + 0.5f) << 5) |
+ (static_cast<unsigned short>(31 * color.red + 0.5f) << 11);
+ break;
+
+ case GL_UNSIGNED_BYTE:
+ byteData[3 * x + y * outputPitch + 0] = static_cast<unsigned char>(255 * color.red + 0.5f);
+ byteData[3 * x + y * outputPitch + 1] = static_cast<unsigned char>(255 * color.green + 0.5f);
+ byteData[3 * x + y * outputPitch + 2] = static_cast<unsigned char>(255 * color.blue + 0.5f);
+ break;
+
+ default:
+ ERR("WritePixelColor not implemented for format GL_RGB and type 0x%X.", type);
+ UNIMPLEMENTED();
+ break;
+ }
+ break;
+
+ default:
+ ERR("WritePixelColor not implemented for format 0x%X.", format);
+ UNIMPLEMENTED();
+ break;
+ }
+}
+
+void Renderer11::readTextureData(ID3D11Texture2D *texture, unsigned int subResource, const gl::Rectangle &area,
+ GLenum format, GLenum type, GLsizei outputPitch, bool packReverseRowOrder,
+ GLint packAlignment, void *pixels)
+{
+ D3D11_TEXTURE2D_DESC textureDesc;
+ texture->GetDesc(&textureDesc);
+
+ D3D11_TEXTURE2D_DESC stagingDesc;
+ stagingDesc.Width = area.width;
+ stagingDesc.Height = area.height;
+ stagingDesc.MipLevels = 1;
+ stagingDesc.ArraySize = 1;
+ stagingDesc.Format = textureDesc.Format;
+ stagingDesc.SampleDesc.Count = 1;
+ stagingDesc.SampleDesc.Quality = 0;
+ stagingDesc.Usage = D3D11_USAGE_STAGING;
+ stagingDesc.BindFlags = 0;
+ stagingDesc.CPUAccessFlags = D3D11_CPU_ACCESS_READ;
+ stagingDesc.MiscFlags = 0;
+
+ ID3D11Texture2D* stagingTex = NULL;
+ HRESULT result = mDevice->CreateTexture2D(&stagingDesc, NULL, &stagingTex);
+ if (FAILED(result))
+ {
+ ERR("Failed to create staging texture for readPixels, HRESULT: 0x%X.", result);
+ return;
+ }
+
+ ID3D11Texture2D* srcTex = NULL;
+ if (textureDesc.SampleDesc.Count > 1)
+ {
+ D3D11_TEXTURE2D_DESC resolveDesc;
+ resolveDesc.Width = textureDesc.Width;
+ resolveDesc.Height = textureDesc.Height;
+ resolveDesc.MipLevels = 1;
+ resolveDesc.ArraySize = 1;
+ resolveDesc.Format = textureDesc.Format;
+ resolveDesc.SampleDesc.Count = 1;
+ resolveDesc.SampleDesc.Quality = 0;
+ resolveDesc.Usage = D3D11_USAGE_DEFAULT;
+ resolveDesc.BindFlags = 0;
+ resolveDesc.CPUAccessFlags = 0;
+ resolveDesc.MiscFlags = 0;
+
+ result = mDevice->CreateTexture2D(&resolveDesc, NULL, &srcTex);
+ if (FAILED(result))
+ {
+ ERR("Failed to create resolve texture for readPixels, HRESULT: 0x%X.", result);
+ stagingTex->Release();
+ return;
+ }
+
+ mDeviceContext->ResolveSubresource(srcTex, 0, texture, subResource, textureDesc.Format);
+ subResource = 0;
+ }
+ else
+ {
+ srcTex = texture;
+ srcTex->AddRef();
+ }
+
+ D3D11_BOX srcBox;
+ srcBox.left = area.x;
+ srcBox.right = area.x + area.width;
+ srcBox.top = area.y;
+ srcBox.bottom = area.y + area.height;
+ srcBox.front = 0;
+ srcBox.back = 1;
+
+ mDeviceContext->CopySubresourceRegion(stagingTex, 0, 0, 0, 0, srcTex, subResource, &srcBox);
+
+ srcTex->Release();
+ srcTex = NULL;
+
+ D3D11_MAPPED_SUBRESOURCE mapping;
+ mDeviceContext->Map(stagingTex, 0, D3D11_MAP_READ, 0, &mapping);
+
+ unsigned char *source;
+ int inputPitch;
+ if (packReverseRowOrder)
+ {
+ source = static_cast<unsigned char*>(mapping.pData) + mapping.RowPitch * (area.height - 1);
+ inputPitch = -static_cast<int>(mapping.RowPitch);
+ }
+ else
+ {
+ source = static_cast<unsigned char*>(mapping.pData);
+ inputPitch = static_cast<int>(mapping.RowPitch);
+ }
+
+ unsigned int fastPixelSize = getFastPixelCopySize(textureDesc.Format, format, type);
+ if (fastPixelSize != 0)
+ {
+ unsigned char *dest = static_cast<unsigned char*>(pixels);
+ for (int j = 0; j < area.height; j++)
+ {
+ memcpy(dest + j * outputPitch, source + j * inputPitch, area.width * fastPixelSize);
+ }
+ }
+ else if (textureDesc.Format == DXGI_FORMAT_B8G8R8A8_UNORM &&
+ format == GL_RGBA &&
+ type == GL_UNSIGNED_BYTE)
+ {
+ // Fast path for swapping red with blue
+ unsigned char *dest = static_cast<unsigned char*>(pixels);
+
+ for (int j = 0; j < area.height; j++)
+ {
+ for (int i = 0; i < area.width; i++)
+ {
+ unsigned int argb = *(unsigned int*)(source + 4 * i + j * inputPitch);
+ *(unsigned int*)(dest + 4 * i + j * outputPitch) =
+ (argb & 0xFF00FF00) | // Keep alpha and green
+ (argb & 0x00FF0000) >> 16 | // Move red to blue
+ (argb & 0x000000FF) << 16; // Move blue to red
+ }
+ }
+ }
+ else
+ {
+ gl::Color pixelColor;
+ for (int j = 0; j < area.height; j++)
+ {
+ for (int i = 0; i < area.width; i++)
+ {
+ readPixelColor(source, textureDesc.Format, i, j, inputPitch, &pixelColor);
+ writePixelColor(pixelColor, format, type, i, j, outputPitch, pixels);
+ }
+ }
+ }
+
+ mDeviceContext->Unmap(stagingTex, 0);
+
+ stagingTex->Release();
+ stagingTex = NULL;
+}
+
+bool Renderer11::blitRenderbufferRect(const gl::Rectangle &readRect, const gl::Rectangle &drawRect, RenderTarget *readRenderTarget,
+ RenderTarget *drawRenderTarget, bool wholeBufferCopy)
+{
+ ASSERT(readRect.width == drawRect.width && readRect.height == drawRect.height);
+
+ RenderTarget11 *readRenderTarget11 = RenderTarget11::makeRenderTarget11(readRenderTarget);
+ if (!readRenderTarget)
+ {
+ ERR("Failed to retrieve the read render target from the read framebuffer.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ ID3D11Texture2D *readTexture = NULL;
+ unsigned int readSubresource = 0;
+ if (readRenderTarget->getSamples() > 0)
+ {
+ ID3D11Texture2D *unresolvedTexture = readRenderTarget11->getTexture();
+
+ readTexture = resolveMultisampledTexture(unresolvedTexture, readRenderTarget11->getSubresourceIndex());
+ readSubresource = 0;
+
+ unresolvedTexture->Release();
+ }
+ else
+ {
+ readTexture = readRenderTarget11->getTexture();
+ readSubresource = readRenderTarget11->getSubresourceIndex();
+ }
+
+ if (!readTexture)
+ {
+ ERR("Failed to retrieve the read render target view from the read render target.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ RenderTarget11 *drawRenderTarget11 = RenderTarget11::makeRenderTarget11(drawRenderTarget);
+ if (!drawRenderTarget)
+ {
+ readTexture->Release();
+ ERR("Failed to retrieve the draw render target from the draw framebuffer.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ ID3D11Texture2D *drawTexture = drawRenderTarget11->getTexture();
+ unsigned int drawSubresource = drawRenderTarget11->getSubresourceIndex();
+
+ D3D11_BOX readBox;
+ readBox.left = readRect.x;
+ readBox.right = readRect.x + readRect.width;
+ readBox.top = readRect.y;
+ readBox.bottom = readRect.y + readRect.height;
+ readBox.front = 0;
+ readBox.back = 1;
+
+ // D3D11 needs depth-stencil CopySubresourceRegions to have a NULL pSrcBox
+ // We also require complete framebuffer copies for depth-stencil blit.
+ D3D11_BOX *pSrcBox = wholeBufferCopy ? NULL : &readBox;
+
+ mDeviceContext->CopySubresourceRegion(drawTexture, drawSubresource, drawRect.x, drawRect.y, 0,
+ readTexture, readSubresource, pSrcBox);
+
+ readTexture->Release();
+ drawTexture->Release();
+
+ return true;
+}
+
+ID3D11Texture2D *Renderer11::resolveMultisampledTexture(ID3D11Texture2D *source, unsigned int subresource)
+{
+ D3D11_TEXTURE2D_DESC textureDesc;
+ source->GetDesc(&textureDesc);
+
+ if (textureDesc.SampleDesc.Count > 1)
+ {
+ D3D11_TEXTURE2D_DESC resolveDesc;
+ resolveDesc.Width = textureDesc.Width;
+ resolveDesc.Height = textureDesc.Height;
+ resolveDesc.MipLevels = 1;
+ resolveDesc.ArraySize = 1;
+ resolveDesc.Format = textureDesc.Format;
+ resolveDesc.SampleDesc.Count = 1;
+ resolveDesc.SampleDesc.Quality = 0;
+ resolveDesc.Usage = textureDesc.Usage;
+ resolveDesc.BindFlags = textureDesc.BindFlags;
+ resolveDesc.CPUAccessFlags = 0;
+ resolveDesc.MiscFlags = 0;
+
+ ID3D11Texture2D *resolveTexture = NULL;
+ HRESULT result = mDevice->CreateTexture2D(&resolveDesc, NULL, &resolveTexture);
+ if (FAILED(result))
+ {
+ ERR("Failed to create a multisample resolve texture, HRESULT: 0x%X.", result);
+ return NULL;
+ }
+
+ mDeviceContext->ResolveSubresource(resolveTexture, 0, source, subresource, textureDesc.Format);
+ return resolveTexture;
+ }
+ else
+ {
+ source->AddRef();
+ return source;
+ }
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Renderer11.h b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer11.h
new file mode 100644
index 0000000000..a3e42e9048
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer11.h
@@ -0,0 +1,348 @@
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Renderer11.h: Defines a back-end specific class for the D3D11 renderer.
+
+#ifndef LIBGLESV2_RENDERER_RENDERER11_H_
+#define LIBGLESV2_RENDERER_RENDERER11_H_
+
+#include "common/angleutils.h"
+#include "libGLESv2/angletypes.h"
+#include "libGLESv2/mathutil.h"
+
+#include "libGLESv2/renderer/Renderer.h"
+#include "libGLESv2/renderer/RenderStateCache.h"
+#include "libGLESv2/renderer/InputLayoutCache.h"
+#include "libGLESv2/renderer/RenderTarget.h"
+
+namespace gl
+{
+class Renderbuffer;
+}
+
+namespace rx
+{
+
+class VertexDataManager;
+class IndexDataManager;
+class StreamingIndexBufferInterface;
+
+enum
+{
+ MAX_VERTEX_UNIFORM_VECTORS_D3D11 = 1024,
+ MAX_FRAGMENT_UNIFORM_VECTORS_D3D11 = 1024
+};
+
+class Renderer11 : public Renderer
+{
+ public:
+ Renderer11(egl::Display *display, HDC hDc);
+ virtual ~Renderer11();
+
+ static Renderer11 *makeRenderer11(Renderer *renderer);
+
+ virtual EGLint initialize();
+ virtual bool resetDevice();
+
+ virtual int generateConfigs(ConfigDesc **configDescList);
+ virtual void deleteConfigs(ConfigDesc *configDescList);
+
+ virtual void sync(bool block);
+
+ virtual SwapChain *createSwapChain(HWND window, HANDLE shareHandle, GLenum backBufferFormat, GLenum depthBufferFormat);
+
+ virtual void setSamplerState(gl::SamplerType type, int index, const gl::SamplerState &sampler);
+ virtual void setTexture(gl::SamplerType type, int index, gl::Texture *texture);
+
+ virtual void setRasterizerState(const gl::RasterizerState &rasterState);
+ virtual void setBlendState(const gl::BlendState &blendState, const gl::Color &blendColor,
+ unsigned int sampleMask);
+ virtual void setDepthStencilState(const gl::DepthStencilState &depthStencilState, int stencilRef,
+ int stencilBackRef, bool frontFaceCCW);
+
+ virtual void setScissorRectangle(const gl::Rectangle &scissor, bool enabled);
+ virtual bool setViewport(const gl::Rectangle &viewport, float zNear, float zFar, GLenum drawMode, GLenum frontFace,
+ bool ignoreViewport);
+
+ virtual bool applyPrimitiveType(GLenum mode, GLsizei count);
+ virtual bool applyRenderTarget(gl::Framebuffer *frameBuffer);
+ virtual void applyShaders(gl::ProgramBinary *programBinary);
+ virtual void applyUniforms(gl::ProgramBinary *programBinary, gl::UniformArray *uniformArray);
+ virtual GLenum applyVertexBuffer(gl::ProgramBinary *programBinary, gl::VertexAttribute vertexAttributes[], GLint first, GLsizei count, GLsizei instances);
+ virtual GLenum applyIndexBuffer(const GLvoid *indices, gl::Buffer *elementArrayBuffer, GLsizei count, GLenum mode, GLenum type, TranslatedIndexData *indexInfo);
+
+ virtual void drawArrays(GLenum mode, GLsizei count, GLsizei instances);
+ virtual void drawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, gl::Buffer *elementArrayBuffer, const TranslatedIndexData &indexInfo, GLsizei instances);
+
+ virtual void clear(const gl::ClearParameters &clearParams, gl::Framebuffer *frameBuffer);
+
+ virtual void markAllStateDirty();
+
+ // lost device
+ void notifyDeviceLost();
+ virtual bool isDeviceLost();
+ virtual bool testDeviceLost(bool notify);
+ virtual bool testDeviceResettable();
+
+ // Renderer capabilities
+ virtual DWORD getAdapterVendor() const;
+ virtual std::string getRendererDescription() const;
+ virtual GUID getAdapterIdentifier() const;
+
+ virtual bool getBGRATextureSupport() const;
+ virtual bool getDXT1TextureSupport();
+ virtual bool getDXT3TextureSupport();
+ virtual bool getDXT5TextureSupport();
+ virtual bool getEventQuerySupport();
+ virtual bool getFloat32TextureSupport(bool *filtering, bool *renderable);
+ virtual bool getFloat16TextureSupport(bool *filtering, bool *renderable);
+ virtual bool getLuminanceTextureSupport();
+ virtual bool getLuminanceAlphaTextureSupport();
+ virtual unsigned int getMaxVertexTextureImageUnits() const;
+ virtual unsigned int getMaxCombinedTextureImageUnits() const;
+ virtual unsigned int getReservedVertexUniformVectors() const;
+ virtual unsigned int getReservedFragmentUniformVectors() const;
+ virtual unsigned int getMaxVertexUniformVectors() const;
+ virtual unsigned int getMaxFragmentUniformVectors() const;
+ virtual unsigned int getMaxVaryingVectors() const;
+ virtual bool getNonPower2TextureSupport() const;
+ virtual bool getDepthTextureSupport() const;
+ virtual bool getOcclusionQuerySupport() const;
+ virtual bool getInstancingSupport() const;
+ virtual bool getTextureFilterAnisotropySupport() const;
+ virtual float getTextureMaxAnisotropy() const;
+ virtual bool getShareHandleSupport() const;
+ virtual bool getDerivativeInstructionSupport() const;
+ virtual bool getPostSubBufferSupport() const;
+
+ virtual int getMajorShaderModel() const;
+ virtual float getMaxPointSize() const;
+ virtual int getMaxViewportDimension() const;
+ virtual int getMaxTextureWidth() const;
+ virtual int getMaxTextureHeight() const;
+ virtual bool get32BitIndexSupport() const;
+ virtual int getMinSwapInterval() const;
+ virtual int getMaxSwapInterval() const;
+
+ virtual GLsizei getMaxSupportedSamples() const;
+ int getNearestSupportedSamples(DXGI_FORMAT format, unsigned int requested) const;
+
+ virtual unsigned int getMaxRenderTargets() const;
+
+ // Pixel operations
+ virtual bool copyToRenderTarget(TextureStorageInterface2D *dest, TextureStorageInterface2D *source);
+ virtual bool copyToRenderTarget(TextureStorageInterfaceCube *dest, TextureStorageInterfaceCube *source);
+
+ virtual bool copyImage(gl::Framebuffer *framebuffer, const gl::Rectangle &sourceRect, GLenum destFormat,
+ GLint xoffset, GLint yoffset, TextureStorageInterface2D *storage, GLint level);
+ virtual bool copyImage(gl::Framebuffer *framebuffer, const gl::Rectangle &sourceRect, GLenum destFormat,
+ GLint xoffset, GLint yoffset, TextureStorageInterfaceCube *storage, GLenum target, GLint level);
+
+ bool copyTexture(ID3D11ShaderResourceView *source, const gl::Rectangle &sourceArea, unsigned int sourceWidth, unsigned int sourceHeight,
+ ID3D11RenderTargetView *dest, const gl::Rectangle &destArea, unsigned int destWidth, unsigned int destHeight, GLenum destFormat);
+
+ virtual bool blitRect(gl::Framebuffer *readTarget, const gl::Rectangle &readRect, gl::Framebuffer *drawTarget, const gl::Rectangle &drawRect,
+ bool blitRenderTarget, bool blitDepthStencil);
+ virtual void readPixels(gl::Framebuffer *framebuffer, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type,
+ GLsizei outputPitch, bool packReverseRowOrder, GLint packAlignment, void* pixels);
+
+ // RenderTarget creation
+ virtual RenderTarget *createRenderTarget(SwapChain *swapChain, bool depth);
+ virtual RenderTarget *createRenderTarget(int width, int height, GLenum format, GLsizei samples, bool depth);
+
+ // Shader operations
+ virtual ShaderExecutable *loadExecutable(const void *function, size_t length, rx::ShaderType type);
+ virtual ShaderExecutable *compileToExecutable(gl::InfoLog &infoLog, const char *shaderHLSL, rx::ShaderType type);
+
+ // Image operations
+ virtual Image *createImage();
+ virtual void generateMipmap(Image *dest, Image *source);
+ virtual TextureStorage *createTextureStorage2D(SwapChain *swapChain);
+ virtual TextureStorage *createTextureStorage2D(int levels, GLenum internalformat, GLenum usage, bool forceRenderable, GLsizei width, GLsizei height);
+ virtual TextureStorage *createTextureStorageCube(int levels, GLenum internalformat, GLenum usage, bool forceRenderable, int size);
+
+ // Buffer creation
+ virtual VertexBuffer *createVertexBuffer();
+ virtual IndexBuffer *createIndexBuffer();
+ virtual BufferStorage *createBufferStorage();
+
+ // Query and Fence creation
+ virtual QueryImpl *createQuery(GLenum type);
+ virtual FenceImpl *createFence();
+
+ // D3D11-renderer specific methods
+ ID3D11Device *getDevice() { return mDevice; }
+ ID3D11DeviceContext *getDeviceContext() { return mDeviceContext; };
+ IDXGIFactory *getDxgiFactory() { return mDxgiFactory; };
+
+ bool getRenderTargetResource(gl::Renderbuffer *colorbuffer, unsigned int *subresourceIndex, ID3D11Texture2D **resource);
+ void unapplyRenderTargets();
+ void setOneTimeRenderTarget(ID3D11RenderTargetView *renderTargetView);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(Renderer11);
+
+ void drawLineLoop(GLsizei count, GLenum type, const GLvoid *indices, int minIndex, gl::Buffer *elementArrayBuffer);
+ void drawTriangleFan(GLsizei count, GLenum type, const GLvoid *indices, int minIndex, gl::Buffer *elementArrayBuffer, int instances);
+
+ void readTextureData(ID3D11Texture2D *texture, unsigned int subResource, const gl::Rectangle &area,
+ GLenum format, GLenum type, GLsizei outputPitch, bool packReverseRowOrder,
+ GLint packAlignment, void *pixels);
+
+ void maskedClear(const gl::ClearParameters &clearParams);
+ rx::Range getViewportBounds() const;
+
+ bool blitRenderbufferRect(const gl::Rectangle &readRect, const gl::Rectangle &drawRect, RenderTarget *readRenderTarget,
+ RenderTarget *drawRenderTarget, bool wholeBufferCopy);
+ ID3D11Texture2D *resolveMultisampledTexture(ID3D11Texture2D *source, unsigned int subresource);
+
+ HMODULE mD3d11Module;
+ HMODULE mDxgiModule;
+ HDC mDc;
+
+ bool mDeviceLost;
+
+ void initializeDevice();
+ void releaseDeviceResources();
+ int getMinorShaderModel() const;
+ void release();
+
+ RenderStateCache mStateCache;
+
+ // Support flags
+ bool mFloat16TextureSupport;
+ bool mFloat16FilterSupport;
+ bool mFloat16RenderSupport;
+
+ bool mFloat32TextureSupport;
+ bool mFloat32FilterSupport;
+ bool mFloat32RenderSupport;
+
+ bool mDXT1TextureSupport;
+ bool mDXT3TextureSupport;
+ bool mDXT5TextureSupport;
+
+ bool mDepthTextureSupport;
+
+ // Multisample format support
+ struct MultisampleSupportInfo
+ {
+ unsigned int qualityLevels[D3D11_MAX_MULTISAMPLE_SAMPLE_COUNT];
+ };
+
+ typedef std::unordered_map<DXGI_FORMAT, MultisampleSupportInfo> MultisampleSupportMap;
+ MultisampleSupportMap mMultisampleSupportMap;
+
+ unsigned int mMaxSupportedSamples;
+
+ // current render target states
+ unsigned int mAppliedRenderTargetSerials[gl::IMPLEMENTATION_MAX_DRAW_BUFFERS];
+ unsigned int mAppliedDepthbufferSerial;
+ unsigned int mAppliedStencilbufferSerial;
+ bool mDepthStencilInitialized;
+ bool mRenderTargetDescInitialized;
+ rx::RenderTarget::Desc mRenderTargetDesc;
+ unsigned int mCurDepthSize;
+ unsigned int mCurStencilSize;
+
+ // Currently applied sampler states
+ bool mForceSetVertexSamplerStates[gl::IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS];
+ gl::SamplerState mCurVertexSamplerStates[gl::IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS];
+
+ bool mForceSetPixelSamplerStates[gl::MAX_TEXTURE_IMAGE_UNITS];
+ gl::SamplerState mCurPixelSamplerStates[gl::MAX_TEXTURE_IMAGE_UNITS];
+
+ // Currently applied textures
+ unsigned int mCurVertexTextureSerials[gl::IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS];
+ unsigned int mCurPixelTextureSerials[gl::MAX_TEXTURE_IMAGE_UNITS];
+
+ // Currently applied blend state
+ bool mForceSetBlendState;
+ gl::BlendState mCurBlendState;
+ gl::Color mCurBlendColor;
+ unsigned int mCurSampleMask;
+
+ // Currently applied rasterizer state
+ bool mForceSetRasterState;
+ gl::RasterizerState mCurRasterState;
+
+ // Currently applied depth stencil state
+ bool mForceSetDepthStencilState;
+ gl::DepthStencilState mCurDepthStencilState;
+ int mCurStencilRef;
+ int mCurStencilBackRef;
+
+ // Currently applied scissor rectangle
+ bool mForceSetScissor;
+ bool mScissorEnabled;
+ gl::Rectangle mCurScissor;
+
+ // Currently applied viewport
+ bool mForceSetViewport;
+ gl::Rectangle mCurViewport;
+ float mCurNear;
+ float mCurFar;
+
+ unsigned int mAppliedIBSerial;
+ unsigned int mAppliedStorageIBSerial;
+ unsigned int mAppliedIBOffset;
+
+ unsigned int mAppliedProgramBinarySerial;
+ bool mIsGeometryShaderActive;
+
+ dx_VertexConstants mVertexConstants;
+ dx_VertexConstants mAppliedVertexConstants;
+ ID3D11Buffer *mDriverConstantBufferVS;
+
+ dx_PixelConstants mPixelConstants;
+ dx_PixelConstants mAppliedPixelConstants;
+ ID3D11Buffer *mDriverConstantBufferPS;
+
+ // Vertex, index and input layouts
+ VertexDataManager *mVertexDataManager;
+ IndexDataManager *mIndexDataManager;
+ InputLayoutCache mInputLayoutCache;
+
+ StreamingIndexBufferInterface *mLineLoopIB;
+ StreamingIndexBufferInterface *mTriangleFanIB;
+
+ // Texture copy resources
+ bool mCopyResourcesInitialized;
+ ID3D11Buffer *mCopyVB;
+ ID3D11SamplerState *mCopySampler;
+ ID3D11InputLayout *mCopyIL;
+ ID3D11VertexShader *mCopyVS;
+ ID3D11PixelShader *mCopyRGBAPS;
+ ID3D11PixelShader *mCopyRGBPS;
+ ID3D11PixelShader *mCopyLumPS;
+ ID3D11PixelShader *mCopyLumAlphaPS;
+
+ // Masked clear resources
+ bool mClearResourcesInitialized;
+ ID3D11Buffer *mClearVB;
+ ID3D11InputLayout *mClearIL;
+ ID3D11VertexShader *mClearVS;
+ ID3D11PixelShader *mClearPS;
+ ID3D11RasterizerState *mClearScissorRS;
+ ID3D11RasterizerState *mClearNoScissorRS;
+
+ // Sync query
+ ID3D11Query *mSyncQuery;
+
+ ID3D11Device *mDevice;
+ D3D_FEATURE_LEVEL mFeatureLevel;
+ ID3D11DeviceContext *mDeviceContext;
+ IDXGIAdapter *mDxgiAdapter;
+ DXGI_ADAPTER_DESC mAdapterDescription;
+ char mDescription[128];
+ IDXGIFactory *mDxgiFactory;
+
+ // Cached device caps
+ bool mBGRATextureSupport;
+};
+
+}
+#endif // LIBGLESV2_RENDERER_RENDERER11_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Renderer9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer9.cpp
new file mode 100644
index 0000000000..8acbce4be7
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer9.cpp
@@ -0,0 +1,3211 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Renderer9.cpp: Implements a back-end specific class for the D3D9 renderer.
+
+#include "libGLESv2/main.h"
+#include "libGLESv2/Buffer.h"
+#include "libGLESv2/Texture.h"
+#include "libGLESv2/Framebuffer.h"
+#include "libGLESv2/Renderbuffer.h"
+#include "libGLESv2/ProgramBinary.h"
+#include "libGLESv2/renderer/IndexDataManager.h"
+#include "libGLESv2/renderer/Renderer9.h"
+#include "libGLESv2/renderer/renderer9_utils.h"
+#include "libGLESv2/renderer/ShaderExecutable9.h"
+#include "libGLESv2/renderer/SwapChain9.h"
+#include "libGLESv2/renderer/TextureStorage9.h"
+#include "libGLESv2/renderer/Image9.h"
+#include "libGLESv2/renderer/Blit.h"
+#include "libGLESv2/renderer/RenderTarget9.h"
+#include "libGLESv2/renderer/VertexBuffer9.h"
+#include "libGLESv2/renderer/IndexBuffer9.h"
+#include "libGLESv2/renderer/BufferStorage9.h"
+#include "libGLESv2/renderer/Query9.h"
+#include "libGLESv2/renderer/Fence9.h"
+
+#include "libEGL/Display.h"
+
+// Can also be enabled by defining FORCE_REF_RAST in the project's predefined macros
+#define REF_RAST 0
+
+// The "Debug This Pixel..." feature in PIX often fails when using the
+// D3D9Ex interfaces. In order to get debug pixel to work on a Vista/Win 7
+// machine, define "ANGLE_ENABLE_D3D9EX=0" in your project file.
+#if !defined(ANGLE_ENABLE_D3D9EX)
+// Enables use of the IDirect3D9Ex interface, when available
+#define ANGLE_ENABLE_D3D9EX 1
+#endif // !defined(ANGLE_ENABLE_D3D9EX)
+
+#if !defined(ANGLE_COMPILE_OPTIMIZATION_LEVEL)
+#define ANGLE_COMPILE_OPTIMIZATION_LEVEL D3DCOMPILE_OPTIMIZATION_LEVEL3
+#endif
+
+namespace rx
+{
+static const D3DFORMAT RenderTargetFormats[] =
+ {
+ D3DFMT_A1R5G5B5,
+ // D3DFMT_A2R10G10B10, // The color_ramp conformance test uses ReadPixels with UNSIGNED_BYTE causing it to think that rendering skipped a colour value.
+ D3DFMT_A8R8G8B8,
+ D3DFMT_R5G6B5,
+ // D3DFMT_X1R5G5B5, // Has no compatible OpenGL ES renderbuffer format
+ D3DFMT_X8R8G8B8
+ };
+
+static const D3DFORMAT DepthStencilFormats[] =
+ {
+ D3DFMT_UNKNOWN,
+ // D3DFMT_D16_LOCKABLE,
+ D3DFMT_D32,
+ // D3DFMT_D15S1,
+ D3DFMT_D24S8,
+ D3DFMT_D24X8,
+ // D3DFMT_D24X4S4,
+ D3DFMT_D16,
+ // D3DFMT_D32F_LOCKABLE,
+ // D3DFMT_D24FS8
+ };
+
+enum
+{
+ MAX_VERTEX_CONSTANT_VECTORS_D3D9 = 256,
+ MAX_PIXEL_CONSTANT_VECTORS_SM2 = 32,
+ MAX_PIXEL_CONSTANT_VECTORS_SM3 = 224,
+ MAX_VARYING_VECTORS_SM2 = 8,
+ MAX_VARYING_VECTORS_SM3 = 10,
+
+ MAX_TEXTURE_IMAGE_UNITS_VTF_SM3 = 4
+};
+
+Renderer9::Renderer9(egl::Display *display, HDC hDc, bool softwareDevice) : Renderer(display), mDc(hDc), mSoftwareDevice(softwareDevice)
+{
+ mD3d9Module = NULL;
+
+ mD3d9 = NULL;
+ mD3d9Ex = NULL;
+ mDevice = NULL;
+ mDeviceEx = NULL;
+ mDeviceWindow = NULL;
+ mBlit = NULL;
+
+ mAdapter = D3DADAPTER_DEFAULT;
+
+ #if REF_RAST == 1 || defined(FORCE_REF_RAST)
+ mDeviceType = D3DDEVTYPE_REF;
+ #else
+ mDeviceType = D3DDEVTYPE_HAL;
+ #endif
+
+ mDeviceLost = false;
+
+ mMaxSupportedSamples = 0;
+
+ mMaskedClearSavedState = NULL;
+
+ mVertexDataManager = NULL;
+ mIndexDataManager = NULL;
+ mLineLoopIB = NULL;
+
+ mMaxNullColorbufferLRU = 0;
+ for (int i = 0; i < NUM_NULL_COLORBUFFER_CACHE_ENTRIES; i++)
+ {
+ mNullColorbufferCache[i].lruCount = 0;
+ mNullColorbufferCache[i].width = 0;
+ mNullColorbufferCache[i].height = 0;
+ mNullColorbufferCache[i].buffer = NULL;
+ }
+}
+
+Renderer9::~Renderer9()
+{
+ releaseDeviceResources();
+
+ if (mDevice)
+ {
+ // If the device is lost, reset it first to prevent leaving the driver in an unstable state
+ if (testDeviceLost(false))
+ {
+ resetDevice();
+ }
+
+ mDevice->Release();
+ mDevice = NULL;
+ }
+
+ if (mDeviceEx)
+ {
+ mDeviceEx->Release();
+ mDeviceEx = NULL;
+ }
+
+ if (mD3d9)
+ {
+ mD3d9->Release();
+ mD3d9 = NULL;
+ }
+
+ if (mDeviceWindow)
+ {
+ DestroyWindow(mDeviceWindow);
+ mDeviceWindow = NULL;
+ }
+
+ if (mD3d9Ex)
+ {
+ mD3d9Ex->Release();
+ mD3d9Ex = NULL;
+ }
+
+ if (mD3d9Module)
+ {
+ mD3d9Module = NULL;
+ }
+
+ while (!mMultiSampleSupport.empty())
+ {
+ delete [] mMultiSampleSupport.begin()->second;
+ mMultiSampleSupport.erase(mMultiSampleSupport.begin());
+ }
+}
+
+Renderer9 *Renderer9::makeRenderer9(Renderer *renderer)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(rx::Renderer9*, renderer));
+ return static_cast<rx::Renderer9*>(renderer);
+}
+
+EGLint Renderer9::initialize()
+{
+ if (!initializeCompiler())
+ {
+ return EGL_NOT_INITIALIZED;
+ }
+
+ if (mSoftwareDevice)
+ {
+ mD3d9Module = GetModuleHandle(TEXT("swiftshader_d3d9.dll"));
+ }
+ else
+ {
+ mD3d9Module = GetModuleHandle(TEXT("d3d9.dll"));
+ }
+
+ if (mD3d9Module == NULL)
+ {
+ ERR("No D3D9 module found - aborting!\n");
+ return EGL_NOT_INITIALIZED;
+ }
+
+ typedef HRESULT (WINAPI *Direct3DCreate9ExFunc)(UINT, IDirect3D9Ex**);
+ Direct3DCreate9ExFunc Direct3DCreate9ExPtr = reinterpret_cast<Direct3DCreate9ExFunc>(GetProcAddress(mD3d9Module, "Direct3DCreate9Ex"));
+
+ // Use Direct3D9Ex if available. Among other things, this version is less
+ // inclined to report a lost context, for example when the user switches
+ // desktop. Direct3D9Ex is available in Windows Vista and later if suitable drivers are available.
+ if (ANGLE_ENABLE_D3D9EX && Direct3DCreate9ExPtr && SUCCEEDED(Direct3DCreate9ExPtr(D3D_SDK_VERSION, &mD3d9Ex)))
+ {
+ ASSERT(mD3d9Ex);
+ mD3d9Ex->QueryInterface(IID_IDirect3D9, reinterpret_cast<void**>(&mD3d9));
+ ASSERT(mD3d9);
+ }
+ else
+ {
+ mD3d9 = Direct3DCreate9(D3D_SDK_VERSION);
+ }
+
+ if (!mD3d9)
+ {
+ ERR("Could not create D3D9 device - aborting!\n");
+ return EGL_NOT_INITIALIZED;
+ }
+
+ if (mDc != NULL)
+ {
+ // UNIMPLEMENTED(); // FIXME: Determine which adapter index the device context corresponds to
+ }
+
+ HRESULT result;
+
+ // Give up on getting device caps after about one second.
+ for (int i = 0; i < 10; ++i)
+ {
+ result = mD3d9->GetDeviceCaps(mAdapter, mDeviceType, &mDeviceCaps);
+ if (SUCCEEDED(result))
+ {
+ break;
+ }
+ else if (result == D3DERR_NOTAVAILABLE)
+ {
+ Sleep(100); // Give the driver some time to initialize/recover
+ }
+ else if (FAILED(result)) // D3DERR_OUTOFVIDEOMEMORY, E_OUTOFMEMORY, D3DERR_INVALIDDEVICE, or another error we can't recover from
+ {
+ ERR("failed to get device caps (0x%x)\n", result);
+ return EGL_NOT_INITIALIZED;
+ }
+ }
+
+ if (mDeviceCaps.PixelShaderVersion < D3DPS_VERSION(2, 0))
+ {
+ ERR("Renderer does not support PS 2.0. aborting!\n");
+ return EGL_NOT_INITIALIZED;
+ }
+
+ // When DirectX9 is running with an older DirectX8 driver, a StretchRect from a regular texture to a render target texture is not supported.
+ // This is required by Texture2D::convertToRenderTarget.
+ if ((mDeviceCaps.DevCaps2 & D3DDEVCAPS2_CAN_STRETCHRECT_FROM_TEXTURES) == 0)
+ {
+ ERR("Renderer does not support stretctrect from textures!\n");
+ return EGL_NOT_INITIALIZED;
+ }
+
+ mD3d9->GetAdapterIdentifier(mAdapter, 0, &mAdapterIdentifier);
+
+ // ATI cards on XP have problems with non-power-of-two textures.
+ mSupportsNonPower2Textures = !(mDeviceCaps.TextureCaps & D3DPTEXTURECAPS_POW2) &&
+ !(mDeviceCaps.TextureCaps & D3DPTEXTURECAPS_CUBEMAP_POW2) &&
+ !(mDeviceCaps.TextureCaps & D3DPTEXTURECAPS_NONPOW2CONDITIONAL) &&
+ !(getComparableOSVersion() < versionWindowsVista && mAdapterIdentifier.VendorId == VENDOR_ID_AMD);
+
+ // Must support a minimum of 2:1 anisotropy for max anisotropy to be considered supported, per the spec
+ mSupportsTextureFilterAnisotropy = ((mDeviceCaps.RasterCaps & D3DPRASTERCAPS_ANISOTROPY) && (mDeviceCaps.MaxAnisotropy >= 2));
+
+ mMinSwapInterval = 4;
+ mMaxSwapInterval = 0;
+
+ if (mDeviceCaps.PresentationIntervals & D3DPRESENT_INTERVAL_IMMEDIATE)
+ {
+ mMinSwapInterval = std::min(mMinSwapInterval, 0);
+ mMaxSwapInterval = std::max(mMaxSwapInterval, 0);
+ }
+ if (mDeviceCaps.PresentationIntervals & D3DPRESENT_INTERVAL_ONE)
+ {
+ mMinSwapInterval = std::min(mMinSwapInterval, 1);
+ mMaxSwapInterval = std::max(mMaxSwapInterval, 1);
+ }
+ if (mDeviceCaps.PresentationIntervals & D3DPRESENT_INTERVAL_TWO)
+ {
+ mMinSwapInterval = std::min(mMinSwapInterval, 2);
+ mMaxSwapInterval = std::max(mMaxSwapInterval, 2);
+ }
+ if (mDeviceCaps.PresentationIntervals & D3DPRESENT_INTERVAL_THREE)
+ {
+ mMinSwapInterval = std::min(mMinSwapInterval, 3);
+ mMaxSwapInterval = std::max(mMaxSwapInterval, 3);
+ }
+ if (mDeviceCaps.PresentationIntervals & D3DPRESENT_INTERVAL_FOUR)
+ {
+ mMinSwapInterval = std::min(mMinSwapInterval, 4);
+ mMaxSwapInterval = std::max(mMaxSwapInterval, 4);
+ }
+
+ int max = 0;
+ for (unsigned int i = 0; i < ArraySize(RenderTargetFormats); ++i)
+ {
+ bool *multisampleArray = new bool[D3DMULTISAMPLE_16_SAMPLES + 1];
+ getMultiSampleSupport(RenderTargetFormats[i], multisampleArray);
+ mMultiSampleSupport[RenderTargetFormats[i]] = multisampleArray;
+
+ for (int j = D3DMULTISAMPLE_16_SAMPLES; j >= 0; --j)
+ {
+ if (multisampleArray[j] && j != D3DMULTISAMPLE_NONMASKABLE && j > max)
+ {
+ max = j;
+ }
+ }
+ }
+
+ for (unsigned int i = 0; i < ArraySize(DepthStencilFormats); ++i)
+ {
+ if (DepthStencilFormats[i] == D3DFMT_UNKNOWN)
+ continue;
+
+ bool *multisampleArray = new bool[D3DMULTISAMPLE_16_SAMPLES + 1];
+ getMultiSampleSupport(DepthStencilFormats[i], multisampleArray);
+ mMultiSampleSupport[DepthStencilFormats[i]] = multisampleArray;
+
+ for (int j = D3DMULTISAMPLE_16_SAMPLES; j >= 0; --j)
+ {
+ if (multisampleArray[j] && j != D3DMULTISAMPLE_NONMASKABLE && j > max)
+ {
+ max = j;
+ }
+ }
+ }
+
+ mMaxSupportedSamples = max;
+
+ static const TCHAR windowName[] = TEXT("AngleHiddenWindow");
+ static const TCHAR className[] = TEXT("STATIC");
+
+ mDeviceWindow = CreateWindowEx(WS_EX_NOACTIVATE, className, windowName, WS_DISABLED | WS_POPUP, 0, 0, 1, 1, HWND_MESSAGE, NULL, GetModuleHandle(NULL), NULL);
+
+ D3DPRESENT_PARAMETERS presentParameters = getDefaultPresentParameters();
+ DWORD behaviorFlags = D3DCREATE_FPU_PRESERVE | D3DCREATE_NOWINDOWCHANGES;
+
+ result = mD3d9->CreateDevice(mAdapter, mDeviceType, mDeviceWindow, behaviorFlags | D3DCREATE_HARDWARE_VERTEXPROCESSING | D3DCREATE_PUREDEVICE, &presentParameters, &mDevice);
+ if (result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY || result == D3DERR_DEVICELOST)
+ {
+ return EGL_BAD_ALLOC;
+ }
+
+ if (FAILED(result))
+ {
+ result = mD3d9->CreateDevice(mAdapter, mDeviceType, mDeviceWindow, behaviorFlags | D3DCREATE_SOFTWARE_VERTEXPROCESSING, &presentParameters, &mDevice);
+
+ if (FAILED(result))
+ {
+ ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY || result == D3DERR_NOTAVAILABLE || result == D3DERR_DEVICELOST);
+ return EGL_BAD_ALLOC;
+ }
+ }
+
+ if (mD3d9Ex)
+ {
+ result = mDevice->QueryInterface(IID_IDirect3DDevice9Ex, (void**) &mDeviceEx);
+ ASSERT(SUCCEEDED(result));
+ }
+
+ mVertexShaderCache.initialize(mDevice);
+ mPixelShaderCache.initialize(mDevice);
+
+ // Check occlusion query support
+ IDirect3DQuery9 *occlusionQuery = NULL;
+ if (SUCCEEDED(mDevice->CreateQuery(D3DQUERYTYPE_OCCLUSION, &occlusionQuery)) && occlusionQuery)
+ {
+ occlusionQuery->Release();
+ mOcclusionQuerySupport = true;
+ }
+ else
+ {
+ mOcclusionQuerySupport = false;
+ }
+
+ // Check event query support
+ IDirect3DQuery9 *eventQuery = NULL;
+ if (SUCCEEDED(mDevice->CreateQuery(D3DQUERYTYPE_EVENT, &eventQuery)) && eventQuery)
+ {
+ eventQuery->Release();
+ mEventQuerySupport = true;
+ }
+ else
+ {
+ mEventQuerySupport = false;
+ }
+
+ D3DDISPLAYMODE currentDisplayMode;
+ mD3d9->GetAdapterDisplayMode(mAdapter, &currentDisplayMode);
+
+ // Check vertex texture support
+ // Only Direct3D 10 ready devices support all the necessary vertex texture formats.
+ // We test this using D3D9 by checking support for the R16F format.
+ mVertexTextureSupport = mDeviceCaps.PixelShaderVersion >= D3DPS_VERSION(3, 0) &&
+ SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format,
+ D3DUSAGE_QUERY_VERTEXTEXTURE, D3DRTYPE_TEXTURE, D3DFMT_R16F));
+
+ // Check depth texture support
+ // we use INTZ for depth textures in Direct3D9
+ // we also want NULL texture support to ensure the we can make depth-only FBOs
+ // see http://aras-p.info/texts/D3D9GPUHacks.html
+ mDepthTextureSupport = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format,
+ D3DUSAGE_DEPTHSTENCIL, D3DRTYPE_TEXTURE, D3DFMT_INTZ)) &&
+ SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format,
+ D3DUSAGE_RENDERTARGET, D3DRTYPE_SURFACE, D3DFMT_NULL));
+
+ // Check 32 bit floating point texture support
+ mFloat32FilterSupport = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_QUERY_FILTER,
+ D3DRTYPE_TEXTURE, D3DFMT_A32B32G32R32F)) &&
+ SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_QUERY_FILTER,
+ D3DRTYPE_CUBETEXTURE, D3DFMT_A32B32G32R32F));
+
+ mFloat32RenderSupport = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_RENDERTARGET,
+ D3DRTYPE_TEXTURE, D3DFMT_A32B32G32R32F)) &&
+ SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_RENDERTARGET,
+ D3DRTYPE_CUBETEXTURE, D3DFMT_A32B32G32R32F));
+
+ if (!mFloat32FilterSupport && !mFloat32RenderSupport)
+ {
+ mFloat32TextureSupport = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0,
+ D3DRTYPE_TEXTURE, D3DFMT_A32B32G32R32F)) &&
+ SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0,
+ D3DRTYPE_CUBETEXTURE, D3DFMT_A32B32G32R32F));
+ }
+ else
+ {
+ mFloat32TextureSupport = true;
+ }
+
+ // Check 16 bit floating point texture support
+ mFloat16FilterSupport = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_QUERY_FILTER,
+ D3DRTYPE_TEXTURE, D3DFMT_A16B16G16R16F)) &&
+ SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_QUERY_FILTER,
+ D3DRTYPE_CUBETEXTURE, D3DFMT_A16B16G16R16F));
+
+ mFloat16RenderSupport = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_RENDERTARGET,
+ D3DRTYPE_TEXTURE, D3DFMT_A16B16G16R16F)) &&
+ SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_RENDERTARGET,
+ D3DRTYPE_CUBETEXTURE, D3DFMT_A16B16G16R16F));
+
+ if (!mFloat16FilterSupport && !mFloat16RenderSupport)
+ {
+ mFloat16TextureSupport = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0,
+ D3DRTYPE_TEXTURE, D3DFMT_A16B16G16R16F)) &&
+ SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0,
+ D3DRTYPE_CUBETEXTURE, D3DFMT_A16B16G16R16F));
+ }
+ else
+ {
+ mFloat16TextureSupport = true;
+ }
+
+ // Check DXT texture support
+ mDXT1TextureSupport = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_DXT1));
+ mDXT3TextureSupport = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_DXT3));
+ mDXT5TextureSupport = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_DXT5));
+
+ // Check luminance[alpha] texture support
+ mLuminanceTextureSupport = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_L8));
+ mLuminanceAlphaTextureSupport = SUCCEEDED(mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, 0, D3DRTYPE_TEXTURE, D3DFMT_A8L8));
+
+ initializeDevice();
+
+ return EGL_SUCCESS;
+}
+
+// do any one-time device initialization
+// NOTE: this is also needed after a device lost/reset
+// to reset the scene status and ensure the default states are reset.
+void Renderer9::initializeDevice()
+{
+ // Permanent non-default states
+ mDevice->SetRenderState(D3DRS_POINTSPRITEENABLE, TRUE);
+ mDevice->SetRenderState(D3DRS_LASTPIXEL, FALSE);
+
+ if (mDeviceCaps.PixelShaderVersion >= D3DPS_VERSION(3, 0))
+ {
+ mDevice->SetRenderState(D3DRS_POINTSIZE_MAX, (DWORD&)mDeviceCaps.MaxPointSize);
+ }
+ else
+ {
+ mDevice->SetRenderState(D3DRS_POINTSIZE_MAX, 0x3F800000); // 1.0f
+ }
+
+ markAllStateDirty();
+
+ mSceneStarted = false;
+
+ ASSERT(!mBlit && !mVertexDataManager && !mIndexDataManager);
+ mBlit = new Blit(this);
+ mVertexDataManager = new rx::VertexDataManager(this);
+ mIndexDataManager = new rx::IndexDataManager(this);
+}
+
+D3DPRESENT_PARAMETERS Renderer9::getDefaultPresentParameters()
+{
+ D3DPRESENT_PARAMETERS presentParameters = {0};
+
+ // The default swap chain is never actually used. Surface will create a new swap chain with the proper parameters.
+ presentParameters.AutoDepthStencilFormat = D3DFMT_UNKNOWN;
+ presentParameters.BackBufferCount = 1;
+ presentParameters.BackBufferFormat = D3DFMT_UNKNOWN;
+ presentParameters.BackBufferWidth = 1;
+ presentParameters.BackBufferHeight = 1;
+ presentParameters.EnableAutoDepthStencil = FALSE;
+ presentParameters.Flags = 0;
+ presentParameters.hDeviceWindow = mDeviceWindow;
+ presentParameters.MultiSampleQuality = 0;
+ presentParameters.MultiSampleType = D3DMULTISAMPLE_NONE;
+ presentParameters.PresentationInterval = D3DPRESENT_INTERVAL_DEFAULT;
+ presentParameters.SwapEffect = D3DSWAPEFFECT_DISCARD;
+ presentParameters.Windowed = TRUE;
+
+ return presentParameters;
+}
+
+int Renderer9::generateConfigs(ConfigDesc **configDescList)
+{
+ D3DDISPLAYMODE currentDisplayMode;
+ mD3d9->GetAdapterDisplayMode(mAdapter, &currentDisplayMode);
+
+ unsigned int numRenderFormats = ArraySize(RenderTargetFormats);
+ unsigned int numDepthFormats = ArraySize(DepthStencilFormats);
+ (*configDescList) = new ConfigDesc[numRenderFormats * numDepthFormats];
+ int numConfigs = 0;
+
+ for (unsigned int formatIndex = 0; formatIndex < numRenderFormats; formatIndex++)
+ {
+ D3DFORMAT renderTargetFormat = RenderTargetFormats[formatIndex];
+
+ HRESULT result = mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_RENDERTARGET, D3DRTYPE_SURFACE, renderTargetFormat);
+
+ if (SUCCEEDED(result))
+ {
+ for (unsigned int depthStencilIndex = 0; depthStencilIndex < numDepthFormats; depthStencilIndex++)
+ {
+ D3DFORMAT depthStencilFormat = DepthStencilFormats[depthStencilIndex];
+ HRESULT result = D3D_OK;
+
+ if(depthStencilFormat != D3DFMT_UNKNOWN)
+ {
+ result = mD3d9->CheckDeviceFormat(mAdapter, mDeviceType, currentDisplayMode.Format, D3DUSAGE_DEPTHSTENCIL, D3DRTYPE_SURFACE, depthStencilFormat);
+ }
+
+ if (SUCCEEDED(result))
+ {
+ if(depthStencilFormat != D3DFMT_UNKNOWN)
+ {
+ result = mD3d9->CheckDepthStencilMatch(mAdapter, mDeviceType, currentDisplayMode.Format, renderTargetFormat, depthStencilFormat);
+ }
+
+ if (SUCCEEDED(result))
+ {
+ ConfigDesc newConfig;
+ newConfig.renderTargetFormat = d3d9_gl::ConvertBackBufferFormat(renderTargetFormat);
+ newConfig.depthStencilFormat = d3d9_gl::ConvertDepthStencilFormat(depthStencilFormat);
+ newConfig.multiSample = 0; // FIXME: enumerate multi-sampling
+ newConfig.fastConfig = (currentDisplayMode.Format == renderTargetFormat);
+
+ (*configDescList)[numConfigs++] = newConfig;
+ }
+ }
+ }
+ }
+ }
+
+ return numConfigs;
+}
+
+void Renderer9::deleteConfigs(ConfigDesc *configDescList)
+{
+ delete [] (configDescList);
+}
+
+void Renderer9::startScene()
+{
+ if (!mSceneStarted)
+ {
+ long result = mDevice->BeginScene();
+ if (SUCCEEDED(result)) {
+ // This is defensive checking against the device being
+ // lost at unexpected times.
+ mSceneStarted = true;
+ }
+ }
+}
+
+void Renderer9::endScene()
+{
+ if (mSceneStarted)
+ {
+ // EndScene can fail if the device was lost, for example due
+ // to a TDR during a draw call.
+ mDevice->EndScene();
+ mSceneStarted = false;
+ }
+}
+
+void Renderer9::sync(bool block)
+{
+ HRESULT result;
+
+ IDirect3DQuery9* query = allocateEventQuery();
+ if (!query)
+ {
+ return;
+ }
+
+ result = query->Issue(D3DISSUE_END);
+ ASSERT(SUCCEEDED(result));
+
+ do
+ {
+ result = query->GetData(NULL, 0, D3DGETDATA_FLUSH);
+
+ if(block && result == S_FALSE)
+ {
+ // Keep polling, but allow other threads to do something useful first
+ Sleep(0);
+ // explicitly check for device loss
+ // some drivers seem to return S_FALSE even if the device is lost
+ // instead of D3DERR_DEVICELOST like they should
+ if (testDeviceLost(false))
+ {
+ result = D3DERR_DEVICELOST;
+ }
+ }
+ }
+ while(block && result == S_FALSE);
+
+ freeEventQuery(query);
+
+ if (d3d9::isDeviceLostError(result))
+ {
+ notifyDeviceLost();
+ }
+}
+
+SwapChain *Renderer9::createSwapChain(HWND window, HANDLE shareHandle, GLenum backBufferFormat, GLenum depthBufferFormat)
+{
+ return new rx::SwapChain9(this, window, shareHandle, backBufferFormat, depthBufferFormat);
+}
+
+IDirect3DQuery9* Renderer9::allocateEventQuery()
+{
+ IDirect3DQuery9 *query = NULL;
+
+ if (mEventQueryPool.empty())
+ {
+ HRESULT result = mDevice->CreateQuery(D3DQUERYTYPE_EVENT, &query);
+ ASSERT(SUCCEEDED(result));
+ }
+ else
+ {
+ query = mEventQueryPool.back();
+ mEventQueryPool.pop_back();
+ }
+
+ return query;
+}
+
+void Renderer9::freeEventQuery(IDirect3DQuery9* query)
+{
+ if (mEventQueryPool.size() > 1000)
+ {
+ query->Release();
+ }
+ else
+ {
+ mEventQueryPool.push_back(query);
+ }
+}
+
+IDirect3DVertexShader9 *Renderer9::createVertexShader(const DWORD *function, size_t length)
+{
+ return mVertexShaderCache.create(function, length);
+}
+
+IDirect3DPixelShader9 *Renderer9::createPixelShader(const DWORD *function, size_t length)
+{
+ return mPixelShaderCache.create(function, length);
+}
+
+HRESULT Renderer9::createVertexBuffer(UINT Length, DWORD Usage, IDirect3DVertexBuffer9 **ppVertexBuffer)
+{
+ D3DPOOL Pool = getBufferPool(Usage);
+ return mDevice->CreateVertexBuffer(Length, Usage, 0, Pool, ppVertexBuffer, NULL);
+}
+
+VertexBuffer *Renderer9::createVertexBuffer()
+{
+ return new VertexBuffer9(this);
+}
+
+HRESULT Renderer9::createIndexBuffer(UINT Length, DWORD Usage, D3DFORMAT Format, IDirect3DIndexBuffer9 **ppIndexBuffer)
+{
+ D3DPOOL Pool = getBufferPool(Usage);
+ return mDevice->CreateIndexBuffer(Length, Usage, Format, Pool, ppIndexBuffer, NULL);
+}
+
+IndexBuffer *Renderer9::createIndexBuffer()
+{
+ return new IndexBuffer9(this);
+}
+
+BufferStorage *Renderer9::createBufferStorage()
+{
+ return new BufferStorage9();
+}
+
+QueryImpl *Renderer9::createQuery(GLenum type)
+{
+ return new Query9(this, type);
+}
+
+FenceImpl *Renderer9::createFence()
+{
+ return new Fence9(this);
+}
+
+void Renderer9::setSamplerState(gl::SamplerType type, int index, const gl::SamplerState &samplerState)
+{
+ bool *forceSetSamplers = (type == gl::SAMPLER_PIXEL) ? mForceSetPixelSamplerStates : mForceSetVertexSamplerStates;
+ gl::SamplerState *appliedSamplers = (type == gl::SAMPLER_PIXEL) ? mCurPixelSamplerStates: mCurVertexSamplerStates;
+
+ if (forceSetSamplers[index] || memcmp(&samplerState, &appliedSamplers[index], sizeof(gl::SamplerState)) != 0)
+ {
+ int d3dSamplerOffset = (type == gl::SAMPLER_PIXEL) ? 0 : D3DVERTEXTEXTURESAMPLER0;
+ int d3dSampler = index + d3dSamplerOffset;
+
+ mDevice->SetSamplerState(d3dSampler, D3DSAMP_ADDRESSU, gl_d3d9::ConvertTextureWrap(samplerState.wrapS));
+ mDevice->SetSamplerState(d3dSampler, D3DSAMP_ADDRESSV, gl_d3d9::ConvertTextureWrap(samplerState.wrapT));
+
+ mDevice->SetSamplerState(d3dSampler, D3DSAMP_MAGFILTER, gl_d3d9::ConvertMagFilter(samplerState.magFilter, samplerState.maxAnisotropy));
+ D3DTEXTUREFILTERTYPE d3dMinFilter, d3dMipFilter;
+ gl_d3d9::ConvertMinFilter(samplerState.minFilter, &d3dMinFilter, &d3dMipFilter, samplerState.maxAnisotropy);
+ mDevice->SetSamplerState(d3dSampler, D3DSAMP_MINFILTER, d3dMinFilter);
+ mDevice->SetSamplerState(d3dSampler, D3DSAMP_MIPFILTER, d3dMipFilter);
+ mDevice->SetSamplerState(d3dSampler, D3DSAMP_MAXMIPLEVEL, samplerState.lodOffset);
+ if (mSupportsTextureFilterAnisotropy)
+ {
+ mDevice->SetSamplerState(d3dSampler, D3DSAMP_MAXANISOTROPY, (DWORD)samplerState.maxAnisotropy);
+ }
+ }
+
+ forceSetSamplers[index] = false;
+ appliedSamplers[index] = samplerState;
+}
+
+void Renderer9::setTexture(gl::SamplerType type, int index, gl::Texture *texture)
+{
+ int d3dSamplerOffset = (type == gl::SAMPLER_PIXEL) ? 0 : D3DVERTEXTEXTURESAMPLER0;
+ int d3dSampler = index + d3dSamplerOffset;
+ IDirect3DBaseTexture9 *d3dTexture = NULL;
+ unsigned int serial = 0;
+ bool forceSetTexture = false;
+
+ unsigned int *appliedSerials = (type == gl::SAMPLER_PIXEL) ? mCurPixelTextureSerials : mCurVertexTextureSerials;
+
+ if (texture)
+ {
+ TextureStorageInterface *texStorage = texture->getNativeTexture();
+ if (texStorage)
+ {
+ TextureStorage9 *storage9 = TextureStorage9::makeTextureStorage9(texStorage->getStorageInstance());
+ d3dTexture = storage9->getBaseTexture();
+ }
+ // If we get NULL back from getBaseTexture here, something went wrong
+ // in the texture class and we're unexpectedly missing the d3d texture
+ ASSERT(d3dTexture != NULL);
+
+ serial = texture->getTextureSerial();
+ forceSetTexture = texture->hasDirtyImages();
+ }
+
+ if (forceSetTexture || appliedSerials[index] != serial)
+ {
+ mDevice->SetTexture(d3dSampler, d3dTexture);
+ }
+
+ appliedSerials[index] = serial;
+}
+
+void Renderer9::setRasterizerState(const gl::RasterizerState &rasterState)
+{
+ bool rasterStateChanged = mForceSetRasterState || memcmp(&rasterState, &mCurRasterState, sizeof(gl::RasterizerState)) != 0;
+
+ if (rasterStateChanged)
+ {
+ // Set the cull mode
+ if (rasterState.cullFace)
+ {
+ mDevice->SetRenderState(D3DRS_CULLMODE, gl_d3d9::ConvertCullMode(rasterState.cullMode, rasterState.frontFace));
+ }
+ else
+ {
+ mDevice->SetRenderState(D3DRS_CULLMODE, D3DCULL_NONE);
+ }
+
+ if (rasterState.polygonOffsetFill)
+ {
+ if (mCurDepthSize > 0)
+ {
+ mDevice->SetRenderState(D3DRS_SLOPESCALEDEPTHBIAS, *(DWORD*)&rasterState.polygonOffsetFactor);
+
+ float depthBias = ldexp(rasterState.polygonOffsetUnits, -static_cast<int>(mCurDepthSize));
+ mDevice->SetRenderState(D3DRS_DEPTHBIAS, *(DWORD*)&depthBias);
+ }
+ }
+ else
+ {
+ mDevice->SetRenderState(D3DRS_SLOPESCALEDEPTHBIAS, 0);
+ mDevice->SetRenderState(D3DRS_DEPTHBIAS, 0);
+ }
+
+ mCurRasterState = rasterState;
+ }
+
+ mForceSetRasterState = false;
+}
+
+void Renderer9::setBlendState(const gl::BlendState &blendState, const gl::Color &blendColor, unsigned int sampleMask)
+{
+ bool blendStateChanged = mForceSetBlendState || memcmp(&blendState, &mCurBlendState, sizeof(gl::BlendState)) != 0;
+ bool blendColorChanged = mForceSetBlendState || memcmp(&blendColor, &mCurBlendColor, sizeof(gl::Color)) != 0;
+ bool sampleMaskChanged = mForceSetBlendState || sampleMask != mCurSampleMask;
+
+ if (blendStateChanged || blendColorChanged)
+ {
+ if (blendState.blend)
+ {
+ mDevice->SetRenderState(D3DRS_ALPHABLENDENABLE, TRUE);
+
+ if (blendState.sourceBlendRGB != GL_CONSTANT_ALPHA && blendState.sourceBlendRGB != GL_ONE_MINUS_CONSTANT_ALPHA &&
+ blendState.destBlendRGB != GL_CONSTANT_ALPHA && blendState.destBlendRGB != GL_ONE_MINUS_CONSTANT_ALPHA)
+ {
+ mDevice->SetRenderState(D3DRS_BLENDFACTOR, gl_d3d9::ConvertColor(blendColor));
+ }
+ else
+ {
+ mDevice->SetRenderState(D3DRS_BLENDFACTOR, D3DCOLOR_RGBA(gl::unorm<8>(blendColor.alpha),
+ gl::unorm<8>(blendColor.alpha),
+ gl::unorm<8>(blendColor.alpha),
+ gl::unorm<8>(blendColor.alpha)));
+ }
+
+ mDevice->SetRenderState(D3DRS_SRCBLEND, gl_d3d9::ConvertBlendFunc(blendState.sourceBlendRGB));
+ mDevice->SetRenderState(D3DRS_DESTBLEND, gl_d3d9::ConvertBlendFunc(blendState.destBlendRGB));
+ mDevice->SetRenderState(D3DRS_BLENDOP, gl_d3d9::ConvertBlendOp(blendState.blendEquationRGB));
+
+ if (blendState.sourceBlendRGB != blendState.sourceBlendAlpha ||
+ blendState.destBlendRGB != blendState.destBlendAlpha ||
+ blendState.blendEquationRGB != blendState.blendEquationAlpha)
+ {
+ mDevice->SetRenderState(D3DRS_SEPARATEALPHABLENDENABLE, TRUE);
+
+ mDevice->SetRenderState(D3DRS_SRCBLENDALPHA, gl_d3d9::ConvertBlendFunc(blendState.sourceBlendAlpha));
+ mDevice->SetRenderState(D3DRS_DESTBLENDALPHA, gl_d3d9::ConvertBlendFunc(blendState.destBlendAlpha));
+ mDevice->SetRenderState(D3DRS_BLENDOPALPHA, gl_d3d9::ConvertBlendOp(blendState.blendEquationAlpha));
+ }
+ else
+ {
+ mDevice->SetRenderState(D3DRS_SEPARATEALPHABLENDENABLE, FALSE);
+ }
+ }
+ else
+ {
+ mDevice->SetRenderState(D3DRS_ALPHABLENDENABLE, FALSE);
+ }
+
+ if (blendState.sampleAlphaToCoverage)
+ {
+ FIXME("Sample alpha to coverage is unimplemented.");
+ }
+
+ // Set the color mask
+ bool zeroColorMaskAllowed = getAdapterVendor() != VENDOR_ID_AMD;
+ // Apparently some ATI cards have a bug where a draw with a zero color
+ // write mask can cause later draws to have incorrect results. Instead,
+ // set a nonzero color write mask but modify the blend state so that no
+ // drawing is done.
+ // http://code.google.com/p/angleproject/issues/detail?id=169
+
+ DWORD colorMask = gl_d3d9::ConvertColorMask(blendState.colorMaskRed, blendState.colorMaskGreen,
+ blendState.colorMaskBlue, blendState.colorMaskAlpha);
+ if (colorMask == 0 && !zeroColorMaskAllowed)
+ {
+ // Enable green channel, but set blending so nothing will be drawn.
+ mDevice->SetRenderState(D3DRS_COLORWRITEENABLE, D3DCOLORWRITEENABLE_GREEN);
+ mDevice->SetRenderState(D3DRS_ALPHABLENDENABLE, TRUE);
+
+ mDevice->SetRenderState(D3DRS_SRCBLEND, D3DBLEND_ZERO);
+ mDevice->SetRenderState(D3DRS_DESTBLEND, D3DBLEND_ONE);
+ mDevice->SetRenderState(D3DRS_BLENDOP, D3DBLENDOP_ADD);
+ }
+ else
+ {
+ mDevice->SetRenderState(D3DRS_COLORWRITEENABLE, colorMask);
+ }
+
+ mDevice->SetRenderState(D3DRS_DITHERENABLE, blendState.dither ? TRUE : FALSE);
+
+ mCurBlendState = blendState;
+ mCurBlendColor = blendColor;
+ }
+
+ if (sampleMaskChanged)
+ {
+ // Set the multisample mask
+ mDevice->SetRenderState(D3DRS_MULTISAMPLEANTIALIAS, TRUE);
+ mDevice->SetRenderState(D3DRS_MULTISAMPLEMASK, static_cast<DWORD>(sampleMask));
+
+ mCurSampleMask = sampleMask;
+ }
+
+ mForceSetBlendState = false;
+}
+
+void Renderer9::setDepthStencilState(const gl::DepthStencilState &depthStencilState, int stencilRef,
+ int stencilBackRef, bool frontFaceCCW)
+{
+ bool depthStencilStateChanged = mForceSetDepthStencilState ||
+ memcmp(&depthStencilState, &mCurDepthStencilState, sizeof(gl::DepthStencilState)) != 0;
+ bool stencilRefChanged = mForceSetDepthStencilState || stencilRef != mCurStencilRef ||
+ stencilBackRef != mCurStencilBackRef;
+ bool frontFaceCCWChanged = mForceSetDepthStencilState || frontFaceCCW != mCurFrontFaceCCW;
+
+ if (depthStencilStateChanged)
+ {
+ if (depthStencilState.depthTest)
+ {
+ mDevice->SetRenderState(D3DRS_ZENABLE, D3DZB_TRUE);
+ mDevice->SetRenderState(D3DRS_ZFUNC, gl_d3d9::ConvertComparison(depthStencilState.depthFunc));
+ }
+ else
+ {
+ mDevice->SetRenderState(D3DRS_ZENABLE, D3DZB_FALSE);
+ }
+
+ mCurDepthStencilState = depthStencilState;
+ }
+
+ if (depthStencilStateChanged || stencilRefChanged || frontFaceCCWChanged)
+ {
+ if (depthStencilState.stencilTest && mCurStencilSize > 0)
+ {
+ mDevice->SetRenderState(D3DRS_STENCILENABLE, TRUE);
+ mDevice->SetRenderState(D3DRS_TWOSIDEDSTENCILMODE, TRUE);
+
+ // FIXME: Unsupported by D3D9
+ const D3DRENDERSTATETYPE D3DRS_CCW_STENCILREF = D3DRS_STENCILREF;
+ const D3DRENDERSTATETYPE D3DRS_CCW_STENCILMASK = D3DRS_STENCILMASK;
+ const D3DRENDERSTATETYPE D3DRS_CCW_STENCILWRITEMASK = D3DRS_STENCILWRITEMASK;
+ if (depthStencilState.stencilWritemask != depthStencilState.stencilBackWritemask ||
+ stencilRef != stencilBackRef ||
+ depthStencilState.stencilMask != depthStencilState.stencilBackMask)
+ {
+ ERR("Separate front/back stencil writemasks, reference values, or stencil mask values are invalid under WebGL.");
+ return gl::error(GL_INVALID_OPERATION);
+ }
+
+ // get the maximum size of the stencil ref
+ unsigned int maxStencil = (1 << mCurStencilSize) - 1;
+
+ mDevice->SetRenderState(frontFaceCCW ? D3DRS_STENCILWRITEMASK : D3DRS_CCW_STENCILWRITEMASK,
+ depthStencilState.stencilWritemask);
+ mDevice->SetRenderState(frontFaceCCW ? D3DRS_STENCILFUNC : D3DRS_CCW_STENCILFUNC,
+ gl_d3d9::ConvertComparison(depthStencilState.stencilFunc));
+
+ mDevice->SetRenderState(frontFaceCCW ? D3DRS_STENCILREF : D3DRS_CCW_STENCILREF,
+ (stencilRef < (int)maxStencil) ? stencilRef : maxStencil);
+ mDevice->SetRenderState(frontFaceCCW ? D3DRS_STENCILMASK : D3DRS_CCW_STENCILMASK,
+ depthStencilState.stencilMask);
+
+ mDevice->SetRenderState(frontFaceCCW ? D3DRS_STENCILFAIL : D3DRS_CCW_STENCILFAIL,
+ gl_d3d9::ConvertStencilOp(depthStencilState.stencilFail));
+ mDevice->SetRenderState(frontFaceCCW ? D3DRS_STENCILZFAIL : D3DRS_CCW_STENCILZFAIL,
+ gl_d3d9::ConvertStencilOp(depthStencilState.stencilPassDepthFail));
+ mDevice->SetRenderState(frontFaceCCW ? D3DRS_STENCILPASS : D3DRS_CCW_STENCILPASS,
+ gl_d3d9::ConvertStencilOp(depthStencilState.stencilPassDepthPass));
+
+ mDevice->SetRenderState(!frontFaceCCW ? D3DRS_STENCILWRITEMASK : D3DRS_CCW_STENCILWRITEMASK,
+ depthStencilState.stencilBackWritemask);
+ mDevice->SetRenderState(!frontFaceCCW ? D3DRS_STENCILFUNC : D3DRS_CCW_STENCILFUNC,
+ gl_d3d9::ConvertComparison(depthStencilState.stencilBackFunc));
+
+ mDevice->SetRenderState(!frontFaceCCW ? D3DRS_STENCILREF : D3DRS_CCW_STENCILREF,
+ (stencilBackRef < (int)maxStencil) ? stencilBackRef : maxStencil);
+ mDevice->SetRenderState(!frontFaceCCW ? D3DRS_STENCILMASK : D3DRS_CCW_STENCILMASK,
+ depthStencilState.stencilBackMask);
+
+ mDevice->SetRenderState(!frontFaceCCW ? D3DRS_STENCILFAIL : D3DRS_CCW_STENCILFAIL,
+ gl_d3d9::ConvertStencilOp(depthStencilState.stencilBackFail));
+ mDevice->SetRenderState(!frontFaceCCW ? D3DRS_STENCILZFAIL : D3DRS_CCW_STENCILZFAIL,
+ gl_d3d9::ConvertStencilOp(depthStencilState.stencilBackPassDepthFail));
+ mDevice->SetRenderState(!frontFaceCCW ? D3DRS_STENCILPASS : D3DRS_CCW_STENCILPASS,
+ gl_d3d9::ConvertStencilOp(depthStencilState.stencilBackPassDepthPass));
+ }
+ else
+ {
+ mDevice->SetRenderState(D3DRS_STENCILENABLE, FALSE);
+ }
+
+ mDevice->SetRenderState(D3DRS_ZWRITEENABLE, depthStencilState.depthMask ? TRUE : FALSE);
+
+ mCurStencilRef = stencilRef;
+ mCurStencilBackRef = stencilBackRef;
+ mCurFrontFaceCCW = frontFaceCCW;
+ }
+
+ mForceSetDepthStencilState = false;
+}
+
+void Renderer9::setScissorRectangle(const gl::Rectangle &scissor, bool enabled)
+{
+ bool scissorChanged = mForceSetScissor ||
+ memcmp(&scissor, &mCurScissor, sizeof(gl::Rectangle)) != 0 ||
+ enabled != mScissorEnabled;
+
+ if (scissorChanged)
+ {
+ if (enabled)
+ {
+ RECT rect;
+ rect.left = gl::clamp(scissor.x, 0, static_cast<int>(mRenderTargetDesc.width));
+ rect.top = gl::clamp(scissor.y, 0, static_cast<int>(mRenderTargetDesc.height));
+ rect.right = gl::clamp(scissor.x + scissor.width, 0, static_cast<int>(mRenderTargetDesc.width));
+ rect.bottom = gl::clamp(scissor.y + scissor.height, 0, static_cast<int>(mRenderTargetDesc.height));
+ mDevice->SetScissorRect(&rect);
+ }
+
+ mDevice->SetRenderState(D3DRS_SCISSORTESTENABLE, enabled ? TRUE : FALSE);
+
+ mScissorEnabled = enabled;
+ mCurScissor = scissor;
+ }
+
+ mForceSetScissor = false;
+}
+
+bool Renderer9::setViewport(const gl::Rectangle &viewport, float zNear, float zFar, GLenum drawMode, GLenum frontFace,
+ bool ignoreViewport)
+{
+ gl::Rectangle actualViewport = viewport;
+ float actualZNear = gl::clamp01(zNear);
+ float actualZFar = gl::clamp01(zFar);
+ if (ignoreViewport)
+ {
+ actualViewport.x = 0;
+ actualViewport.y = 0;
+ actualViewport.width = mRenderTargetDesc.width;
+ actualViewport.height = mRenderTargetDesc.height;
+ actualZNear = 0.0f;
+ actualZFar = 1.0f;
+ }
+
+ D3DVIEWPORT9 dxViewport;
+ dxViewport.X = gl::clamp(actualViewport.x, 0, static_cast<int>(mRenderTargetDesc.width));
+ dxViewport.Y = gl::clamp(actualViewport.y, 0, static_cast<int>(mRenderTargetDesc.height));
+ dxViewport.Width = gl::clamp(actualViewport.width, 0, static_cast<int>(mRenderTargetDesc.width) - static_cast<int>(dxViewport.X));
+ dxViewport.Height = gl::clamp(actualViewport.height, 0, static_cast<int>(mRenderTargetDesc.height) - static_cast<int>(dxViewport.Y));
+ dxViewport.MinZ = actualZNear;
+ dxViewport.MaxZ = actualZFar;
+
+ if (dxViewport.Width <= 0 || dxViewport.Height <= 0)
+ {
+ return false; // Nothing to render
+ }
+
+ bool viewportChanged = mForceSetViewport || memcmp(&actualViewport, &mCurViewport, sizeof(gl::Rectangle)) != 0 ||
+ actualZNear != mCurNear || actualZFar != mCurFar;
+ if (viewportChanged)
+ {
+ mDevice->SetViewport(&dxViewport);
+
+ mCurViewport = actualViewport;
+ mCurNear = actualZNear;
+ mCurFar = actualZFar;
+
+ dx_VertexConstants vc = {0};
+ dx_PixelConstants pc = {0};
+
+ vc.viewAdjust[0] = (float)((actualViewport.width - (int)dxViewport.Width) + 2 * (actualViewport.x - (int)dxViewport.X) - 1) / dxViewport.Width;
+ vc.viewAdjust[1] = (float)((actualViewport.height - (int)dxViewport.Height) + 2 * (actualViewport.y - (int)dxViewport.Y) - 1) / dxViewport.Height;
+ vc.viewAdjust[2] = (float)actualViewport.width / dxViewport.Width;
+ vc.viewAdjust[3] = (float)actualViewport.height / dxViewport.Height;
+
+ pc.viewCoords[0] = actualViewport.width * 0.5f;
+ pc.viewCoords[1] = actualViewport.height * 0.5f;
+ pc.viewCoords[2] = actualViewport.x + (actualViewport.width * 0.5f);
+ pc.viewCoords[3] = actualViewport.y + (actualViewport.height * 0.5f);
+
+ pc.depthFront[0] = (actualZFar - actualZNear) * 0.5f;
+ pc.depthFront[1] = (actualZNear + actualZFar) * 0.5f;
+ pc.depthFront[2] = !gl::IsTriangleMode(drawMode) ? 0.0f : (frontFace == GL_CCW ? 1.0f : -1.0f);;
+
+ vc.depthRange[0] = actualZNear;
+ vc.depthRange[1] = actualZFar;
+ vc.depthRange[2] = actualZFar - actualZNear;
+
+ pc.depthRange[0] = actualZNear;
+ pc.depthRange[1] = actualZFar;
+ pc.depthRange[2] = actualZFar - actualZNear;
+
+ if (memcmp(&vc, &mVertexConstants, sizeof(dx_VertexConstants)) != 0)
+ {
+ mVertexConstants = vc;
+ mDxUniformsDirty = true;
+ }
+
+ if (memcmp(&pc, &mPixelConstants, sizeof(dx_PixelConstants)) != 0)
+ {
+ mPixelConstants = pc;
+ mDxUniformsDirty = true;
+ }
+ }
+
+ mForceSetViewport = false;
+ return true;
+}
+
+bool Renderer9::applyPrimitiveType(GLenum mode, GLsizei count)
+{
+ switch (mode)
+ {
+ case GL_POINTS:
+ mPrimitiveType = D3DPT_POINTLIST;
+ mPrimitiveCount = count;
+ break;
+ case GL_LINES:
+ mPrimitiveType = D3DPT_LINELIST;
+ mPrimitiveCount = count / 2;
+ break;
+ case GL_LINE_LOOP:
+ mPrimitiveType = D3DPT_LINESTRIP;
+ mPrimitiveCount = count - 1; // D3D doesn't support line loops, so we draw the last line separately
+ break;
+ case GL_LINE_STRIP:
+ mPrimitiveType = D3DPT_LINESTRIP;
+ mPrimitiveCount = count - 1;
+ break;
+ case GL_TRIANGLES:
+ mPrimitiveType = D3DPT_TRIANGLELIST;
+ mPrimitiveCount = count / 3;
+ break;
+ case GL_TRIANGLE_STRIP:
+ mPrimitiveType = D3DPT_TRIANGLESTRIP;
+ mPrimitiveCount = count - 2;
+ break;
+ case GL_TRIANGLE_FAN:
+ mPrimitiveType = D3DPT_TRIANGLEFAN;
+ mPrimitiveCount = count - 2;
+ break;
+ default:
+ return gl::error(GL_INVALID_ENUM, false);
+ }
+
+ return mPrimitiveCount > 0;
+}
+
+
+gl::Renderbuffer *Renderer9::getNullColorbuffer(gl::Renderbuffer *depthbuffer)
+{
+ if (!depthbuffer)
+ {
+ ERR("Unexpected null depthbuffer for depth-only FBO.");
+ return NULL;
+ }
+
+ GLsizei width = depthbuffer->getWidth();
+ GLsizei height = depthbuffer->getHeight();
+
+ // search cached nullcolorbuffers
+ for (int i = 0; i < NUM_NULL_COLORBUFFER_CACHE_ENTRIES; i++)
+ {
+ if (mNullColorbufferCache[i].buffer != NULL &&
+ mNullColorbufferCache[i].width == width &&
+ mNullColorbufferCache[i].height == height)
+ {
+ mNullColorbufferCache[i].lruCount = ++mMaxNullColorbufferLRU;
+ return mNullColorbufferCache[i].buffer;
+ }
+ }
+
+ gl::Renderbuffer *nullbuffer = new gl::Renderbuffer(this, 0, new gl::Colorbuffer(this, width, height, GL_NONE, 0));
+
+ // add nullbuffer to the cache
+ NullColorbufferCacheEntry *oldest = &mNullColorbufferCache[0];
+ for (int i = 1; i < NUM_NULL_COLORBUFFER_CACHE_ENTRIES; i++)
+ {
+ if (mNullColorbufferCache[i].lruCount < oldest->lruCount)
+ {
+ oldest = &mNullColorbufferCache[i];
+ }
+ }
+
+ delete oldest->buffer;
+ oldest->buffer = nullbuffer;
+ oldest->lruCount = ++mMaxNullColorbufferLRU;
+ oldest->width = width;
+ oldest->height = height;
+
+ return nullbuffer;
+}
+
+bool Renderer9::applyRenderTarget(gl::Framebuffer *framebuffer)
+{
+ // if there is no color attachment we must synthesize a NULL colorattachment
+ // to keep the D3D runtime happy. This should only be possible if depth texturing.
+ gl::Renderbuffer *renderbufferObject = NULL;
+ if (framebuffer->getColorbufferType(0) != GL_NONE)
+ {
+ renderbufferObject = framebuffer->getColorbuffer(0);
+ }
+ else
+ {
+ renderbufferObject = getNullColorbuffer(framebuffer->getDepthbuffer());
+ }
+ if (!renderbufferObject)
+ {
+ ERR("unable to locate renderbuffer for FBO.");
+ return false;
+ }
+
+ bool renderTargetChanged = false;
+ unsigned int renderTargetSerial = renderbufferObject->getSerial();
+ if (renderTargetSerial != mAppliedRenderTargetSerial)
+ {
+ // Apply the render target on the device
+ IDirect3DSurface9 *renderTargetSurface = NULL;
+
+ RenderTarget *renderTarget = renderbufferObject->getRenderTarget();
+ if (renderTarget)
+ {
+ renderTargetSurface = RenderTarget9::makeRenderTarget9(renderTarget)->getSurface();
+ }
+
+ if (!renderTargetSurface)
+ {
+ ERR("render target pointer unexpectedly null.");
+ return false; // Context must be lost
+ }
+
+ mDevice->SetRenderTarget(0, renderTargetSurface);
+ renderTargetSurface->Release();
+
+ mAppliedRenderTargetSerial = renderTargetSerial;
+ renderTargetChanged = true;
+ }
+
+ gl::Renderbuffer *depthStencil = NULL;
+ unsigned int depthbufferSerial = 0;
+ unsigned int stencilbufferSerial = 0;
+ if (framebuffer->getDepthbufferType() != GL_NONE)
+ {
+ depthStencil = framebuffer->getDepthbuffer();
+ if (!depthStencil)
+ {
+ ERR("Depth stencil pointer unexpectedly null.");
+ return false;
+ }
+
+ depthbufferSerial = depthStencil->getSerial();
+ }
+ else if (framebuffer->getStencilbufferType() != GL_NONE)
+ {
+ depthStencil = framebuffer->getStencilbuffer();
+ if (!depthStencil)
+ {
+ ERR("Depth stencil pointer unexpectedly null.");
+ return false;
+ }
+
+ stencilbufferSerial = depthStencil->getSerial();
+ }
+
+ if (depthbufferSerial != mAppliedDepthbufferSerial ||
+ stencilbufferSerial != mAppliedStencilbufferSerial ||
+ !mDepthStencilInitialized)
+ {
+ unsigned int depthSize = 0;
+ unsigned int stencilSize = 0;
+
+ // Apply the depth stencil on the device
+ if (depthStencil)
+ {
+ IDirect3DSurface9 *depthStencilSurface = NULL;
+ RenderTarget *depthStencilRenderTarget = depthStencil->getDepthStencil();
+
+ if (depthStencilRenderTarget)
+ {
+ depthStencilSurface = RenderTarget9::makeRenderTarget9(depthStencilRenderTarget)->getSurface();
+ }
+
+ if (!depthStencilSurface)
+ {
+ ERR("depth stencil pointer unexpectedly null.");
+ return false; // Context must be lost
+ }
+
+ mDevice->SetDepthStencilSurface(depthStencilSurface);
+ depthStencilSurface->Release();
+
+ depthSize = depthStencil->getDepthSize();
+ stencilSize = depthStencil->getStencilSize();
+ }
+ else
+ {
+ mDevice->SetDepthStencilSurface(NULL);
+ }
+
+ if (!mDepthStencilInitialized || depthSize != mCurDepthSize)
+ {
+ mCurDepthSize = depthSize;
+ mForceSetRasterState = true;
+ }
+
+ if (!mDepthStencilInitialized || stencilSize != mCurStencilSize)
+ {
+ mCurStencilSize = stencilSize;
+ mForceSetDepthStencilState = true;
+ }
+
+ mAppliedDepthbufferSerial = depthbufferSerial;
+ mAppliedStencilbufferSerial = stencilbufferSerial;
+ mDepthStencilInitialized = true;
+ }
+
+ if (renderTargetChanged || !mRenderTargetDescInitialized)
+ {
+ mForceSetScissor = true;
+ mForceSetViewport = true;
+
+ mRenderTargetDesc.width = renderbufferObject->getWidth();
+ mRenderTargetDesc.height = renderbufferObject->getHeight();
+ mRenderTargetDesc.format = renderbufferObject->getActualFormat();
+ mRenderTargetDescInitialized = true;
+ }
+
+ return true;
+}
+
+GLenum Renderer9::applyVertexBuffer(gl::ProgramBinary *programBinary, gl::VertexAttribute vertexAttributes[], GLint first, GLsizei count, GLsizei instances)
+{
+ TranslatedAttribute attributes[gl::MAX_VERTEX_ATTRIBS];
+ GLenum err = mVertexDataManager->prepareVertexData(vertexAttributes, programBinary, first, count, attributes, instances);
+ if (err != GL_NO_ERROR)
+ {
+ return err;
+ }
+
+ return mVertexDeclarationCache.applyDeclaration(mDevice, attributes, programBinary, instances, &mRepeatDraw);
+}
+
+// Applies the indices and element array bindings to the Direct3D 9 device
+GLenum Renderer9::applyIndexBuffer(const GLvoid *indices, gl::Buffer *elementArrayBuffer, GLsizei count, GLenum mode, GLenum type, TranslatedIndexData *indexInfo)
+{
+ GLenum err = mIndexDataManager->prepareIndexData(type, count, elementArrayBuffer, indices, indexInfo);
+
+ if (err == GL_NO_ERROR)
+ {
+ // Directly binding the storage buffer is not supported for d3d9
+ ASSERT(indexInfo->storage == NULL);
+
+ if (indexInfo->serial != mAppliedIBSerial)
+ {
+ IndexBuffer9* indexBuffer = IndexBuffer9::makeIndexBuffer9(indexInfo->indexBuffer);
+
+ mDevice->SetIndices(indexBuffer->getBuffer());
+ mAppliedIBSerial = indexInfo->serial;
+ }
+ }
+
+ return err;
+}
+
+void Renderer9::drawArrays(GLenum mode, GLsizei count, GLsizei instances)
+{
+ startScene();
+
+ if (mode == GL_LINE_LOOP)
+ {
+ drawLineLoop(count, GL_NONE, NULL, 0, NULL);
+ }
+ else if (instances > 0)
+ {
+ StaticIndexBufferInterface *countingIB = mIndexDataManager->getCountingIndices(count);
+ if (countingIB)
+ {
+ if (mAppliedIBSerial != countingIB->getSerial())
+ {
+ IndexBuffer9 *indexBuffer = IndexBuffer9::makeIndexBuffer9(countingIB->getIndexBuffer());
+
+ mDevice->SetIndices(indexBuffer->getBuffer());
+ mAppliedIBSerial = countingIB->getSerial();
+ }
+
+ for (int i = 0; i < mRepeatDraw; i++)
+ {
+ mDevice->DrawIndexedPrimitive(mPrimitiveType, 0, 0, count, 0, mPrimitiveCount);
+ }
+ }
+ else
+ {
+ ERR("Could not create a counting index buffer for glDrawArraysInstanced.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+ else // Regular case
+ {
+ mDevice->DrawPrimitive(mPrimitiveType, 0, mPrimitiveCount);
+ }
+}
+
+void Renderer9::drawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, gl::Buffer *elementArrayBuffer, const TranslatedIndexData &indexInfo, GLsizei /*instances*/)
+{
+ startScene();
+
+ if (mode == GL_POINTS)
+ {
+ drawIndexedPoints(count, type, indices, elementArrayBuffer);
+ }
+ else if (mode == GL_LINE_LOOP)
+ {
+ drawLineLoop(count, type, indices, indexInfo.minIndex, elementArrayBuffer);
+ }
+ else
+ {
+ for (int i = 0; i < mRepeatDraw; i++)
+ {
+ GLsizei vertexCount = indexInfo.maxIndex - indexInfo.minIndex + 1;
+ mDevice->DrawIndexedPrimitive(mPrimitiveType, -(INT)indexInfo.minIndex, indexInfo.minIndex, vertexCount, indexInfo.startIndex, mPrimitiveCount);
+ }
+ }
+}
+
+void Renderer9::drawLineLoop(GLsizei count, GLenum type, const GLvoid *indices, int minIndex, gl::Buffer *elementArrayBuffer)
+{
+ // Get the raw indices for an indexed draw
+ if (type != GL_NONE && elementArrayBuffer)
+ {
+ gl::Buffer *indexBuffer = elementArrayBuffer;
+ BufferStorage *storage = indexBuffer->getStorage();
+ intptr_t offset = reinterpret_cast<intptr_t>(indices);
+ indices = static_cast<const GLubyte*>(storage->getData()) + offset;
+ }
+
+ UINT startIndex = 0;
+
+ if (get32BitIndexSupport())
+ {
+ if (!mLineLoopIB)
+ {
+ mLineLoopIB = new StreamingIndexBufferInterface(this);
+ if (!mLineLoopIB->reserveBufferSpace(INITIAL_INDEX_BUFFER_SIZE, GL_UNSIGNED_INT))
+ {
+ delete mLineLoopIB;
+ mLineLoopIB = NULL;
+
+ ERR("Could not create a 32-bit looping index buffer for GL_LINE_LOOP.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ const int spaceNeeded = (count + 1) * sizeof(unsigned int);
+ if (!mLineLoopIB->reserveBufferSpace(spaceNeeded, GL_UNSIGNED_INT))
+ {
+ ERR("Could not reserve enough space in looping index buffer for GL_LINE_LOOP.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ void* mappedMemory = NULL;
+ int offset = mLineLoopIB->mapBuffer(spaceNeeded, &mappedMemory);
+ if (offset == -1 || mappedMemory == NULL)
+ {
+ ERR("Could not map index buffer for GL_LINE_LOOP.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ startIndex = static_cast<UINT>(offset) / 4;
+ unsigned int *data = reinterpret_cast<unsigned int*>(mappedMemory);
+
+ switch (type)
+ {
+ case GL_NONE: // Non-indexed draw
+ for (int i = 0; i < count; i++)
+ {
+ data[i] = i;
+ }
+ data[count] = 0;
+ break;
+ case GL_UNSIGNED_BYTE:
+ for (int i = 0; i < count; i++)
+ {
+ data[i] = static_cast<const GLubyte*>(indices)[i];
+ }
+ data[count] = static_cast<const GLubyte*>(indices)[0];
+ break;
+ case GL_UNSIGNED_SHORT:
+ for (int i = 0; i < count; i++)
+ {
+ data[i] = static_cast<const GLushort*>(indices)[i];
+ }
+ data[count] = static_cast<const GLushort*>(indices)[0];
+ break;
+ case GL_UNSIGNED_INT:
+ for (int i = 0; i < count; i++)
+ {
+ data[i] = static_cast<const GLuint*>(indices)[i];
+ }
+ data[count] = static_cast<const GLuint*>(indices)[0];
+ break;
+ default: UNREACHABLE();
+ }
+
+ if (!mLineLoopIB->unmapBuffer())
+ {
+ ERR("Could not unmap index buffer for GL_LINE_LOOP.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+ else
+ {
+ if (!mLineLoopIB)
+ {
+ mLineLoopIB = new StreamingIndexBufferInterface(this);
+ if (!mLineLoopIB->reserveBufferSpace(INITIAL_INDEX_BUFFER_SIZE, GL_UNSIGNED_SHORT))
+ {
+ delete mLineLoopIB;
+ mLineLoopIB = NULL;
+
+ ERR("Could not create a 16-bit looping index buffer for GL_LINE_LOOP.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ const int spaceNeeded = (count + 1) * sizeof(unsigned short);
+ if (!mLineLoopIB->reserveBufferSpace(spaceNeeded, GL_UNSIGNED_SHORT))
+ {
+ ERR("Could not reserve enough space in looping index buffer for GL_LINE_LOOP.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ void* mappedMemory = NULL;
+ int offset = mLineLoopIB->mapBuffer(spaceNeeded, &mappedMemory);
+ if (offset == -1 || mappedMemory == NULL)
+ {
+ ERR("Could not map index buffer for GL_LINE_LOOP.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ startIndex = static_cast<UINT>(offset) / 2;
+ unsigned short *data = reinterpret_cast<unsigned short*>(mappedMemory);
+
+ switch (type)
+ {
+ case GL_NONE: // Non-indexed draw
+ for (int i = 0; i < count; i++)
+ {
+ data[i] = i;
+ }
+ data[count] = 0;
+ break;
+ case GL_UNSIGNED_BYTE:
+ for (int i = 0; i < count; i++)
+ {
+ data[i] = static_cast<const GLubyte*>(indices)[i];
+ }
+ data[count] = static_cast<const GLubyte*>(indices)[0];
+ break;
+ case GL_UNSIGNED_SHORT:
+ for (int i = 0; i < count; i++)
+ {
+ data[i] = static_cast<const GLushort*>(indices)[i];
+ }
+ data[count] = static_cast<const GLushort*>(indices)[0];
+ break;
+ case GL_UNSIGNED_INT:
+ for (int i = 0; i < count; i++)
+ {
+ data[i] = static_cast<const GLuint*>(indices)[i];
+ }
+ data[count] = static_cast<const GLuint*>(indices)[0];
+ break;
+ default: UNREACHABLE();
+ }
+
+ if (!mLineLoopIB->unmapBuffer())
+ {
+ ERR("Could not unmap index buffer for GL_LINE_LOOP.");
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ if (mAppliedIBSerial != mLineLoopIB->getSerial())
+ {
+ IndexBuffer9 *indexBuffer = IndexBuffer9::makeIndexBuffer9(mLineLoopIB->getIndexBuffer());
+
+ mDevice->SetIndices(indexBuffer->getBuffer());
+ mAppliedIBSerial = mLineLoopIB->getSerial();
+ }
+
+ mDevice->DrawIndexedPrimitive(D3DPT_LINESTRIP, -minIndex, minIndex, count, startIndex, count);
+}
+
+template <typename T>
+static void drawPoints(IDirect3DDevice9* device, GLsizei count, const GLvoid *indices)
+{
+ for (int i = 0; i < count; i++)
+ {
+ unsigned int indexValue = static_cast<unsigned int>(static_cast<const T*>(indices)[i]);
+ device->DrawPrimitive(D3DPT_POINTLIST, indexValue, 1);
+ }
+}
+
+void Renderer9::drawIndexedPoints(GLsizei count, GLenum type, const GLvoid *indices, gl::Buffer *elementArrayBuffer)
+{
+ // Drawing index point lists is unsupported in d3d9, fall back to a regular DrawPrimitive call
+ // for each individual point. This call is not expected to happen often.
+
+ if (elementArrayBuffer)
+ {
+ BufferStorage *storage = elementArrayBuffer->getStorage();
+ intptr_t offset = reinterpret_cast<intptr_t>(indices);
+ indices = static_cast<const GLubyte*>(storage->getData()) + offset;
+ }
+
+ switch (type)
+ {
+ case GL_UNSIGNED_BYTE: drawPoints<GLubyte>(mDevice, count, indices); break;
+ case GL_UNSIGNED_SHORT: drawPoints<GLushort>(mDevice, count, indices); break;
+ case GL_UNSIGNED_INT: drawPoints<GLuint>(mDevice, count, indices); break;
+ default: UNREACHABLE();
+ }
+}
+
+void Renderer9::applyShaders(gl::ProgramBinary *programBinary)
+{
+ unsigned int programBinarySerial = programBinary->getSerial();
+ if (programBinarySerial != mAppliedProgramBinarySerial)
+ {
+ ShaderExecutable *vertexExe = programBinary->getVertexExecutable();
+ ShaderExecutable *pixelExe = programBinary->getPixelExecutable();
+
+ IDirect3DVertexShader9 *vertexShader = NULL;
+ if (vertexExe) vertexShader = ShaderExecutable9::makeShaderExecutable9(vertexExe)->getVertexShader();
+
+ IDirect3DPixelShader9 *pixelShader = NULL;
+ if (pixelExe) pixelShader = ShaderExecutable9::makeShaderExecutable9(pixelExe)->getPixelShader();
+
+ mDevice->SetPixelShader(pixelShader);
+ mDevice->SetVertexShader(vertexShader);
+ programBinary->dirtyAllUniforms();
+ mDxUniformsDirty = true;
+
+ mAppliedProgramBinarySerial = programBinarySerial;
+ }
+}
+
+void Renderer9::applyUniforms(gl::ProgramBinary *programBinary, gl::UniformArray *uniformArray)
+{
+ for (std::vector<gl::Uniform*>::const_iterator ub = uniformArray->begin(), ue = uniformArray->end(); ub != ue; ++ub)
+ {
+ gl::Uniform *targetUniform = *ub;
+
+ if (targetUniform->dirty)
+ {
+ GLfloat *f = (GLfloat*)targetUniform->data;
+ GLint *i = (GLint*)targetUniform->data;
+
+ switch (targetUniform->type)
+ {
+ case GL_SAMPLER_2D:
+ case GL_SAMPLER_CUBE:
+ break;
+ case GL_BOOL:
+ case GL_BOOL_VEC2:
+ case GL_BOOL_VEC3:
+ case GL_BOOL_VEC4:
+ applyUniformnbv(targetUniform, i);
+ break;
+ case GL_FLOAT:
+ case GL_FLOAT_VEC2:
+ case GL_FLOAT_VEC3:
+ case GL_FLOAT_VEC4:
+ case GL_FLOAT_MAT2:
+ case GL_FLOAT_MAT3:
+ case GL_FLOAT_MAT4:
+ applyUniformnfv(targetUniform, f);
+ break;
+ case GL_INT:
+ case GL_INT_VEC2:
+ case GL_INT_VEC3:
+ case GL_INT_VEC4:
+ applyUniformniv(targetUniform, i);
+ break;
+ default:
+ UNREACHABLE();
+ }
+
+ targetUniform->dirty = false;
+ }
+ }
+
+ // Driver uniforms
+ if (mDxUniformsDirty)
+ {
+ mDevice->SetVertexShaderConstantF(0, (float*)&mVertexConstants, sizeof(dx_VertexConstants) / sizeof(float[4]));
+ mDevice->SetPixelShaderConstantF(0, (float*)&mPixelConstants, sizeof(dx_PixelConstants) / sizeof(float[4]));
+ mDxUniformsDirty = false;
+ }
+}
+
+void Renderer9::applyUniformnfv(gl::Uniform *targetUniform, const GLfloat *v)
+{
+ if (targetUniform->psRegisterIndex >= 0)
+ {
+ mDevice->SetPixelShaderConstantF(targetUniform->psRegisterIndex, v, targetUniform->registerCount);
+ }
+
+ if (targetUniform->vsRegisterIndex >= 0)
+ {
+ mDevice->SetVertexShaderConstantF(targetUniform->vsRegisterIndex, v, targetUniform->registerCount);
+ }
+}
+
+void Renderer9::applyUniformniv(gl::Uniform *targetUniform, const GLint *v)
+{
+ ASSERT(targetUniform->registerCount <= MAX_VERTEX_CONSTANT_VECTORS_D3D9);
+ GLfloat vector[MAX_VERTEX_CONSTANT_VECTORS_D3D9][4];
+
+ for (unsigned int i = 0; i < targetUniform->registerCount; i++)
+ {
+ vector[i][0] = (GLfloat)v[4 * i + 0];
+ vector[i][1] = (GLfloat)v[4 * i + 1];
+ vector[i][2] = (GLfloat)v[4 * i + 2];
+ vector[i][3] = (GLfloat)v[4 * i + 3];
+ }
+
+ applyUniformnfv(targetUniform, (GLfloat*)vector);
+}
+
+void Renderer9::applyUniformnbv(gl::Uniform *targetUniform, const GLint *v)
+{
+ ASSERT(targetUniform->registerCount <= MAX_VERTEX_CONSTANT_VECTORS_D3D9);
+ GLfloat vector[MAX_VERTEX_CONSTANT_VECTORS_D3D9][4];
+
+ for (unsigned int i = 0; i < targetUniform->registerCount; i++)
+ {
+ vector[i][0] = (v[4 * i + 0] == GL_FALSE) ? 0.0f : 1.0f;
+ vector[i][1] = (v[4 * i + 1] == GL_FALSE) ? 0.0f : 1.0f;
+ vector[i][2] = (v[4 * i + 2] == GL_FALSE) ? 0.0f : 1.0f;
+ vector[i][3] = (v[4 * i + 3] == GL_FALSE) ? 0.0f : 1.0f;
+ }
+
+ applyUniformnfv(targetUniform, (GLfloat*)vector);
+}
+
+void Renderer9::clear(const gl::ClearParameters &clearParams, gl::Framebuffer *frameBuffer)
+{
+ D3DCOLOR color = D3DCOLOR_ARGB(gl::unorm<8>(clearParams.colorClearValue.alpha),
+ gl::unorm<8>(clearParams.colorClearValue.red),
+ gl::unorm<8>(clearParams.colorClearValue.green),
+ gl::unorm<8>(clearParams.colorClearValue.blue));
+ float depth = gl::clamp01(clearParams.depthClearValue);
+ int stencil = clearParams.stencilClearValue & 0x000000FF;
+
+ unsigned int stencilUnmasked = 0x0;
+ if ((clearParams.mask & GL_STENCIL_BUFFER_BIT) && frameBuffer->hasStencil())
+ {
+ unsigned int stencilSize = gl::GetStencilSize(frameBuffer->getStencilbuffer()->getActualFormat());
+ stencilUnmasked = (0x1 << stencilSize) - 1;
+ }
+
+ bool alphaUnmasked = (gl::GetAlphaSize(mRenderTargetDesc.format) == 0) || clearParams.colorMaskAlpha;
+
+ const bool needMaskedStencilClear = (clearParams.mask & GL_STENCIL_BUFFER_BIT) &&
+ (clearParams.stencilWriteMask & stencilUnmasked) != stencilUnmasked;
+ const bool needMaskedColorClear = (clearParams.mask & GL_COLOR_BUFFER_BIT) &&
+ !(clearParams.colorMaskRed && clearParams.colorMaskGreen &&
+ clearParams.colorMaskBlue && alphaUnmasked);
+
+ if (needMaskedColorClear || needMaskedStencilClear)
+ {
+ // State which is altered in all paths from this point to the clear call is saved.
+ // State which is altered in only some paths will be flagged dirty in the case that
+ // that path is taken.
+ HRESULT hr;
+ if (mMaskedClearSavedState == NULL)
+ {
+ hr = mDevice->BeginStateBlock();
+ ASSERT(SUCCEEDED(hr) || hr == D3DERR_OUTOFVIDEOMEMORY || hr == E_OUTOFMEMORY);
+
+ mDevice->SetRenderState(D3DRS_ZWRITEENABLE, FALSE);
+ mDevice->SetRenderState(D3DRS_ZFUNC, D3DCMP_ALWAYS);
+ mDevice->SetRenderState(D3DRS_ZENABLE, FALSE);
+ mDevice->SetRenderState(D3DRS_CULLMODE, D3DCULL_NONE);
+ mDevice->SetRenderState(D3DRS_FILLMODE, D3DFILL_SOLID);
+ mDevice->SetRenderState(D3DRS_ALPHATESTENABLE, FALSE);
+ mDevice->SetRenderState(D3DRS_ALPHABLENDENABLE, FALSE);
+ mDevice->SetRenderState(D3DRS_CLIPPLANEENABLE, 0);
+ mDevice->SetRenderState(D3DRS_COLORWRITEENABLE, 0);
+ mDevice->SetRenderState(D3DRS_STENCILENABLE, FALSE);
+ mDevice->SetPixelShader(NULL);
+ mDevice->SetVertexShader(NULL);
+ mDevice->SetFVF(D3DFVF_XYZRHW | D3DFVF_DIFFUSE);
+ mDevice->SetStreamSource(0, NULL, 0, 0);
+ mDevice->SetRenderState(D3DRS_SEPARATEALPHABLENDENABLE, TRUE);
+ mDevice->SetTextureStageState(0, D3DTSS_COLOROP, D3DTOP_SELECTARG1);
+ mDevice->SetTextureStageState(0, D3DTSS_COLORARG1, D3DTA_TFACTOR);
+ mDevice->SetTextureStageState(0, D3DTSS_ALPHAOP, D3DTOP_SELECTARG1);
+ mDevice->SetTextureStageState(0, D3DTSS_ALPHAARG1, D3DTA_TFACTOR);
+ mDevice->SetRenderState(D3DRS_TEXTUREFACTOR, color);
+ mDevice->SetRenderState(D3DRS_MULTISAMPLEMASK, 0xFFFFFFFF);
+
+ for(int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ mDevice->SetStreamSourceFreq(i, 1);
+ }
+
+ hr = mDevice->EndStateBlock(&mMaskedClearSavedState);
+ ASSERT(SUCCEEDED(hr) || hr == D3DERR_OUTOFVIDEOMEMORY || hr == E_OUTOFMEMORY);
+ }
+
+ ASSERT(mMaskedClearSavedState != NULL);
+
+ if (mMaskedClearSavedState != NULL)
+ {
+ hr = mMaskedClearSavedState->Capture();
+ ASSERT(SUCCEEDED(hr));
+ }
+
+ mDevice->SetRenderState(D3DRS_ZWRITEENABLE, FALSE);
+ mDevice->SetRenderState(D3DRS_ZFUNC, D3DCMP_ALWAYS);
+ mDevice->SetRenderState(D3DRS_ZENABLE, FALSE);
+ mDevice->SetRenderState(D3DRS_CULLMODE, D3DCULL_NONE);
+ mDevice->SetRenderState(D3DRS_FILLMODE, D3DFILL_SOLID);
+ mDevice->SetRenderState(D3DRS_ALPHATESTENABLE, FALSE);
+ mDevice->SetRenderState(D3DRS_ALPHABLENDENABLE, FALSE);
+ mDevice->SetRenderState(D3DRS_CLIPPLANEENABLE, 0);
+
+ if (clearParams.mask & GL_COLOR_BUFFER_BIT)
+ {
+ mDevice->SetRenderState(D3DRS_COLORWRITEENABLE,
+ gl_d3d9::ConvertColorMask(clearParams.colorMaskRed,
+ clearParams.colorMaskGreen,
+ clearParams.colorMaskBlue,
+ clearParams.colorMaskAlpha));
+ }
+ else
+ {
+ mDevice->SetRenderState(D3DRS_COLORWRITEENABLE, 0);
+ }
+
+ if (stencilUnmasked != 0x0 && (clearParams.mask & GL_STENCIL_BUFFER_BIT))
+ {
+ mDevice->SetRenderState(D3DRS_STENCILENABLE, TRUE);
+ mDevice->SetRenderState(D3DRS_TWOSIDEDSTENCILMODE, FALSE);
+ mDevice->SetRenderState(D3DRS_STENCILFUNC, D3DCMP_ALWAYS);
+ mDevice->SetRenderState(D3DRS_STENCILREF, stencil);
+ mDevice->SetRenderState(D3DRS_STENCILWRITEMASK, clearParams.stencilWriteMask);
+ mDevice->SetRenderState(D3DRS_STENCILFAIL, D3DSTENCILOP_REPLACE);
+ mDevice->SetRenderState(D3DRS_STENCILZFAIL, D3DSTENCILOP_REPLACE);
+ mDevice->SetRenderState(D3DRS_STENCILPASS, D3DSTENCILOP_REPLACE);
+ }
+ else
+ {
+ mDevice->SetRenderState(D3DRS_STENCILENABLE, FALSE);
+ }
+
+ mDevice->SetPixelShader(NULL);
+ mDevice->SetVertexShader(NULL);
+ mDevice->SetFVF(D3DFVF_XYZRHW);
+ mDevice->SetRenderState(D3DRS_SEPARATEALPHABLENDENABLE, TRUE);
+ mDevice->SetTextureStageState(0, D3DTSS_COLOROP, D3DTOP_SELECTARG1);
+ mDevice->SetTextureStageState(0, D3DTSS_COLORARG1, D3DTA_TFACTOR);
+ mDevice->SetTextureStageState(0, D3DTSS_ALPHAOP, D3DTOP_SELECTARG1);
+ mDevice->SetTextureStageState(0, D3DTSS_ALPHAARG1, D3DTA_TFACTOR);
+ mDevice->SetRenderState(D3DRS_TEXTUREFACTOR, color);
+ mDevice->SetRenderState(D3DRS_MULTISAMPLEMASK, 0xFFFFFFFF);
+
+ for(int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ mDevice->SetStreamSourceFreq(i, 1);
+ }
+
+ float quad[4][4]; // A quadrilateral covering the target, aligned to match the edges
+ quad[0][0] = -0.5f;
+ quad[0][1] = mRenderTargetDesc.height - 0.5f;
+ quad[0][2] = 0.0f;
+ quad[0][3] = 1.0f;
+
+ quad[1][0] = mRenderTargetDesc.width - 0.5f;
+ quad[1][1] = mRenderTargetDesc.height - 0.5f;
+ quad[1][2] = 0.0f;
+ quad[1][3] = 1.0f;
+
+ quad[2][0] = -0.5f;
+ quad[2][1] = -0.5f;
+ quad[2][2] = 0.0f;
+ quad[2][3] = 1.0f;
+
+ quad[3][0] = mRenderTargetDesc.width - 0.5f;
+ quad[3][1] = -0.5f;
+ quad[3][2] = 0.0f;
+ quad[3][3] = 1.0f;
+
+ startScene();
+ mDevice->DrawPrimitiveUP(D3DPT_TRIANGLESTRIP, 2, quad, sizeof(float[4]));
+
+ if (clearParams.mask & GL_DEPTH_BUFFER_BIT)
+ {
+ mDevice->SetRenderState(D3DRS_ZENABLE, TRUE);
+ mDevice->SetRenderState(D3DRS_ZWRITEENABLE, TRUE);
+ mDevice->Clear(0, NULL, D3DCLEAR_ZBUFFER, color, depth, stencil);
+ }
+
+ if (mMaskedClearSavedState != NULL)
+ {
+ mMaskedClearSavedState->Apply();
+ }
+ }
+ else if (clearParams.mask)
+ {
+ DWORD dxClearFlags = 0;
+ if (clearParams.mask & GL_COLOR_BUFFER_BIT)
+ {
+ dxClearFlags |= D3DCLEAR_TARGET;
+ }
+ if (clearParams.mask & GL_DEPTH_BUFFER_BIT)
+ {
+ dxClearFlags |= D3DCLEAR_ZBUFFER;
+ }
+ if (clearParams.mask & GL_STENCIL_BUFFER_BIT)
+ {
+ dxClearFlags |= D3DCLEAR_STENCIL;
+ }
+
+ mDevice->Clear(0, NULL, dxClearFlags, color, depth, stencil);
+ }
+}
+
+void Renderer9::markAllStateDirty()
+{
+ mAppliedRenderTargetSerial = 0;
+ mAppliedDepthbufferSerial = 0;
+ mAppliedStencilbufferSerial = 0;
+ mDepthStencilInitialized = false;
+ mRenderTargetDescInitialized = false;
+
+ mForceSetDepthStencilState = true;
+ mForceSetRasterState = true;
+ mForceSetScissor = true;
+ mForceSetViewport = true;
+ mForceSetBlendState = true;
+
+ for (unsigned int i = 0; i < gl::IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS; i++)
+ {
+ mForceSetVertexSamplerStates[i] = true;
+ mCurVertexTextureSerials[i] = 0;
+ }
+ for (unsigned int i = 0; i < gl::MAX_TEXTURE_IMAGE_UNITS; i++)
+ {
+ mForceSetPixelSamplerStates[i] = true;
+ mCurPixelTextureSerials[i] = 0;
+ }
+
+ mAppliedIBSerial = 0;
+ mAppliedProgramBinarySerial = 0;
+ mDxUniformsDirty = true;
+
+ mVertexDeclarationCache.markStateDirty();
+}
+
+void Renderer9::releaseDeviceResources()
+{
+ while (!mEventQueryPool.empty())
+ {
+ mEventQueryPool.back()->Release();
+ mEventQueryPool.pop_back();
+ }
+
+ if (mMaskedClearSavedState)
+ {
+ mMaskedClearSavedState->Release();
+ mMaskedClearSavedState = NULL;
+ }
+
+ mVertexShaderCache.clear();
+ mPixelShaderCache.clear();
+
+ delete mBlit;
+ mBlit = NULL;
+
+ delete mVertexDataManager;
+ mVertexDataManager = NULL;
+
+ delete mIndexDataManager;
+ mIndexDataManager = NULL;
+
+ delete mLineLoopIB;
+ mLineLoopIB = NULL;
+
+ for (int i = 0; i < NUM_NULL_COLORBUFFER_CACHE_ENTRIES; i++)
+ {
+ delete mNullColorbufferCache[i].buffer;
+ mNullColorbufferCache[i].buffer = NULL;
+ }
+
+}
+
+
+void Renderer9::notifyDeviceLost()
+{
+ mDeviceLost = true;
+ mDisplay->notifyDeviceLost();
+}
+
+bool Renderer9::isDeviceLost()
+{
+ return mDeviceLost;
+}
+
+// set notify to true to broadcast a message to all contexts of the device loss
+bool Renderer9::testDeviceLost(bool notify)
+{
+ HRESULT status = S_OK;
+
+ if (mDeviceEx)
+ {
+ status = mDeviceEx->CheckDeviceState(NULL);
+
+ if (status == S_PRESENT_MODE_CHANGED)
+ {
+ // Reset the device so that D3D stops reporting S_PRESENT_MODE_CHANGED. Otherwise it will report
+ // it continuously, potentially masking a lost device. D3D resources are not lost on a mode change with WDDM.
+ D3DPRESENT_PARAMETERS presentParameters = getDefaultPresentParameters();
+ mDeviceEx->Reset(&presentParameters);
+
+ // Existing swap chains sometimes crash on the next present after a reset.
+ mDisplay->recreateSwapChains();
+
+ // Reset will not always cause the device loss to be reported so issue a dummy present.
+ mDeviceEx->Present(NULL, NULL, NULL, NULL);
+
+ // Retest the device status to see if the mode change really indicated a lost device.
+ status = mDeviceEx->CheckDeviceState(NULL);
+ }
+ }
+ else if (mDevice)
+ {
+ status = mDevice->TestCooperativeLevel();
+ }
+ else
+ {
+ // No device yet, so no reset required
+ }
+
+ bool isLost = FAILED(status) || d3d9::isDeviceLostError(status);
+
+ if (isLost)
+ {
+ // ensure we note the device loss --
+ // we'll probably get this done again by notifyDeviceLost
+ // but best to remember it!
+ // Note that we don't want to clear the device loss status here
+ // -- this needs to be done by resetDevice
+ mDeviceLost = true;
+ if (notify)
+ {
+ notifyDeviceLost();
+ }
+ }
+
+ return isLost;
+}
+
+bool Renderer9::testDeviceResettable()
+{
+ HRESULT status = D3D_OK;
+
+ if (mDeviceEx)
+ {
+ status = mDeviceEx->CheckDeviceState(NULL);
+ }
+ else if (mDevice)
+ {
+ status = mDevice->TestCooperativeLevel();
+ }
+
+ // On D3D9Ex, DEVICELOST represents a hung device that needs to be restarted
+ // DEVICEREMOVED indicates the device has been stopped and must be recreated
+ switch (status)
+ {
+ case D3DERR_DEVICENOTRESET:
+ case D3DERR_DEVICEHUNG:
+ return true;
+ case D3DERR_DEVICELOST:
+ return (mDeviceEx != NULL);
+ case D3DERR_DEVICEREMOVED:
+ UNIMPLEMENTED();
+ return false;
+ default:
+ return false;
+ }
+}
+
+bool Renderer9::resetDevice()
+{
+ releaseDeviceResources();
+
+ D3DPRESENT_PARAMETERS presentParameters = getDefaultPresentParameters();
+
+ HRESULT result = D3D_OK;
+ bool lost = testDeviceLost(false);
+ int attempts = 3;
+
+ while (lost && attempts > 0)
+ {
+ if (mDeviceEx)
+ {
+ Sleep(500); // Give the graphics driver some CPU time
+ result = mDeviceEx->ResetEx(&presentParameters, NULL);
+ }
+ else
+ {
+ result = mDevice->TestCooperativeLevel();
+ while (result == D3DERR_DEVICELOST)
+ {
+ Sleep(100); // Give the graphics driver some CPU time
+ result = mDevice->TestCooperativeLevel();
+ }
+
+ if (result == D3DERR_DEVICENOTRESET)
+ {
+ result = mDevice->Reset(&presentParameters);
+ }
+ }
+
+ lost = testDeviceLost(false);
+ attempts --;
+ }
+
+ if (FAILED(result))
+ {
+ ERR("Reset/ResetEx failed multiple times: 0x%08X", result);
+ return false;
+ }
+
+ // reset device defaults
+ initializeDevice();
+ mDeviceLost = false;
+
+ return true;
+}
+
+DWORD Renderer9::getAdapterVendor() const
+{
+ return mAdapterIdentifier.VendorId;
+}
+
+std::string Renderer9::getRendererDescription() const
+{
+ std::ostringstream rendererString;
+
+ rendererString << mAdapterIdentifier.Description;
+ if (getShareHandleSupport())
+ {
+ rendererString << " Direct3D9Ex";
+ }
+ else
+ {
+ rendererString << " Direct3D9";
+ }
+
+ rendererString << " vs_" << D3DSHADER_VERSION_MAJOR(mDeviceCaps.VertexShaderVersion) << "_" << D3DSHADER_VERSION_MINOR(mDeviceCaps.VertexShaderVersion);
+ rendererString << " ps_" << D3DSHADER_VERSION_MAJOR(mDeviceCaps.PixelShaderVersion) << "_" << D3DSHADER_VERSION_MINOR(mDeviceCaps.PixelShaderVersion);
+
+ return rendererString.str();
+}
+
+GUID Renderer9::getAdapterIdentifier() const
+{
+ return mAdapterIdentifier.DeviceIdentifier;
+}
+
+void Renderer9::getMultiSampleSupport(D3DFORMAT format, bool *multiSampleArray)
+{
+ for (int multiSampleIndex = 0; multiSampleIndex <= D3DMULTISAMPLE_16_SAMPLES; multiSampleIndex++)
+ {
+ HRESULT result = mD3d9->CheckDeviceMultiSampleType(mAdapter, mDeviceType, format,
+ TRUE, (D3DMULTISAMPLE_TYPE)multiSampleIndex, NULL);
+
+ multiSampleArray[multiSampleIndex] = SUCCEEDED(result);
+ }
+}
+
+bool Renderer9::getBGRATextureSupport() const
+{
+ // DirectX 9 always supports BGRA
+ return true;
+}
+
+bool Renderer9::getDXT1TextureSupport()
+{
+ return mDXT1TextureSupport;
+}
+
+bool Renderer9::getDXT3TextureSupport()
+{
+ return mDXT3TextureSupport;
+}
+
+bool Renderer9::getDXT5TextureSupport()
+{
+ return mDXT5TextureSupport;
+}
+
+bool Renderer9::getDepthTextureSupport() const
+{
+ return mDepthTextureSupport;
+}
+
+bool Renderer9::getFloat32TextureSupport(bool *filtering, bool *renderable)
+{
+ *filtering = mFloat32FilterSupport;
+ *renderable = mFloat32RenderSupport;
+ return mFloat32TextureSupport;
+}
+
+bool Renderer9::getFloat16TextureSupport(bool *filtering, bool *renderable)
+{
+ *filtering = mFloat16FilterSupport;
+ *renderable = mFloat16RenderSupport;
+ return mFloat16TextureSupport;
+}
+
+bool Renderer9::getLuminanceTextureSupport()
+{
+ return mLuminanceTextureSupport;
+}
+
+bool Renderer9::getLuminanceAlphaTextureSupport()
+{
+ return mLuminanceAlphaTextureSupport;
+}
+
+bool Renderer9::getTextureFilterAnisotropySupport() const
+{
+ return mSupportsTextureFilterAnisotropy;
+}
+
+float Renderer9::getTextureMaxAnisotropy() const
+{
+ if (mSupportsTextureFilterAnisotropy)
+ {
+ return static_cast<float>(mDeviceCaps.MaxAnisotropy);
+ }
+ return 1.0f;
+}
+
+bool Renderer9::getEventQuerySupport()
+{
+ return mEventQuerySupport;
+}
+
+unsigned int Renderer9::getMaxVertexTextureImageUnits() const
+{
+ META_ASSERT(MAX_TEXTURE_IMAGE_UNITS_VTF_SM3 <= gl::IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS);
+ return mVertexTextureSupport ? MAX_TEXTURE_IMAGE_UNITS_VTF_SM3 : 0;
+}
+
+unsigned int Renderer9::getMaxCombinedTextureImageUnits() const
+{
+ return gl::MAX_TEXTURE_IMAGE_UNITS + getMaxVertexTextureImageUnits();
+}
+
+unsigned int Renderer9::getReservedVertexUniformVectors() const
+{
+ return 2; // dx_ViewAdjust and dx_DepthRange.
+}
+
+unsigned int Renderer9::getReservedFragmentUniformVectors() const
+{
+ return 3; // dx_ViewCoords, dx_DepthFront and dx_DepthRange.
+}
+
+unsigned int Renderer9::getMaxVertexUniformVectors() const
+{
+ return MAX_VERTEX_CONSTANT_VECTORS_D3D9 - getReservedVertexUniformVectors();
+}
+
+unsigned int Renderer9::getMaxFragmentUniformVectors() const
+{
+ const int maxPixelConstantVectors = (getMajorShaderModel() >= 3) ? MAX_PIXEL_CONSTANT_VECTORS_SM3 : MAX_PIXEL_CONSTANT_VECTORS_SM2;
+
+ return maxPixelConstantVectors - getReservedFragmentUniformVectors();
+}
+
+unsigned int Renderer9::getMaxVaryingVectors() const
+{
+ return (getMajorShaderModel() >= 3) ? MAX_VARYING_VECTORS_SM3 : MAX_VARYING_VECTORS_SM2;
+}
+
+bool Renderer9::getNonPower2TextureSupport() const
+{
+ return mSupportsNonPower2Textures;
+}
+
+bool Renderer9::getOcclusionQuerySupport() const
+{
+ return mOcclusionQuerySupport;
+}
+
+bool Renderer9::getInstancingSupport() const
+{
+ return mDeviceCaps.PixelShaderVersion >= D3DPS_VERSION(3, 0);
+}
+
+bool Renderer9::getShareHandleSupport() const
+{
+ // PIX doesn't seem to support using share handles, so disable them.
+ return (mD3d9Ex != NULL) && !gl::perfActive();
+}
+
+bool Renderer9::getDerivativeInstructionSupport() const
+{
+ return (mDeviceCaps.PS20Caps.Caps & D3DPS20CAPS_GRADIENTINSTRUCTIONS) != 0;
+}
+
+bool Renderer9::getPostSubBufferSupport() const
+{
+ return true;
+}
+
+int Renderer9::getMajorShaderModel() const
+{
+ return D3DSHADER_VERSION_MAJOR(mDeviceCaps.PixelShaderVersion);
+}
+
+float Renderer9::getMaxPointSize() const
+{
+ // Point size clamped at 1.0f for SM2
+ return getMajorShaderModel() == 3 ? mDeviceCaps.MaxPointSize : 1.0f;
+}
+
+int Renderer9::getMaxViewportDimension() const
+{
+ int maxTextureDimension = std::min(std::min(getMaxTextureWidth(), getMaxTextureHeight()),
+ (int)gl::IMPLEMENTATION_MAX_TEXTURE_SIZE);
+ return maxTextureDimension;
+}
+
+int Renderer9::getMaxTextureWidth() const
+{
+ return (int)mDeviceCaps.MaxTextureWidth;
+}
+
+int Renderer9::getMaxTextureHeight() const
+{
+ return (int)mDeviceCaps.MaxTextureHeight;
+}
+
+bool Renderer9::get32BitIndexSupport() const
+{
+ return mDeviceCaps.MaxVertexIndex >= (1 << 16);
+}
+
+DWORD Renderer9::getCapsDeclTypes() const
+{
+ return mDeviceCaps.DeclTypes;
+}
+
+int Renderer9::getMinSwapInterval() const
+{
+ return mMinSwapInterval;
+}
+
+int Renderer9::getMaxSwapInterval() const
+{
+ return mMaxSwapInterval;
+}
+
+int Renderer9::getMaxSupportedSamples() const
+{
+ return mMaxSupportedSamples;
+}
+
+int Renderer9::getNearestSupportedSamples(D3DFORMAT format, int requested) const
+{
+ if (requested == 0)
+ {
+ return requested;
+ }
+
+ std::map<D3DFORMAT, bool *>::const_iterator itr = mMultiSampleSupport.find(format);
+ if (itr == mMultiSampleSupport.end())
+ {
+ if (format == D3DFMT_UNKNOWN)
+ return 0;
+ return -1;
+ }
+
+ for (int i = requested; i <= D3DMULTISAMPLE_16_SAMPLES; ++i)
+ {
+ if (itr->second[i] && i != D3DMULTISAMPLE_NONMASKABLE)
+ {
+ return i;
+ }
+ }
+
+ return -1;
+}
+
+unsigned int Renderer9::getMaxRenderTargets() const
+{
+ // we do not support MRT in d3d9
+ return 1;
+}
+
+D3DFORMAT Renderer9::ConvertTextureInternalFormat(GLint internalformat)
+{
+ switch (internalformat)
+ {
+ case GL_DEPTH_COMPONENT16:
+ case GL_DEPTH_COMPONENT32_OES:
+ case GL_DEPTH24_STENCIL8_OES:
+ return D3DFMT_INTZ;
+ case GL_COMPRESSED_RGB_S3TC_DXT1_EXT:
+ case GL_COMPRESSED_RGBA_S3TC_DXT1_EXT:
+ return D3DFMT_DXT1;
+ case GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE:
+ return D3DFMT_DXT3;
+ case GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE:
+ return D3DFMT_DXT5;
+ case GL_RGBA32F_EXT:
+ case GL_RGB32F_EXT:
+ case GL_ALPHA32F_EXT:
+ case GL_LUMINANCE32F_EXT:
+ case GL_LUMINANCE_ALPHA32F_EXT:
+ return D3DFMT_A32B32G32R32F;
+ case GL_RGBA16F_EXT:
+ case GL_RGB16F_EXT:
+ case GL_ALPHA16F_EXT:
+ case GL_LUMINANCE16F_EXT:
+ case GL_LUMINANCE_ALPHA16F_EXT:
+ return D3DFMT_A16B16G16R16F;
+ case GL_LUMINANCE8_EXT:
+ if (getLuminanceTextureSupport())
+ {
+ return D3DFMT_L8;
+ }
+ break;
+ case GL_LUMINANCE8_ALPHA8_EXT:
+ if (getLuminanceAlphaTextureSupport())
+ {
+ return D3DFMT_A8L8;
+ }
+ break;
+ case GL_RGB8_OES:
+ case GL_RGB565:
+ return D3DFMT_X8R8G8B8;
+ }
+
+ return D3DFMT_A8R8G8B8;
+}
+
+bool Renderer9::copyToRenderTarget(TextureStorageInterface2D *dest, TextureStorageInterface2D *source)
+{
+ bool result = false;
+
+ if (source && dest)
+ {
+ TextureStorage9_2D *source9 = TextureStorage9_2D::makeTextureStorage9_2D(source->getStorageInstance());
+ TextureStorage9_2D *dest9 = TextureStorage9_2D::makeTextureStorage9_2D(dest->getStorageInstance());
+
+ int levels = source9->levelCount();
+ for (int i = 0; i < levels; ++i)
+ {
+ IDirect3DSurface9 *srcSurf = source9->getSurfaceLevel(i, false);
+ IDirect3DSurface9 *dstSurf = dest9->getSurfaceLevel(i, false);
+
+ result = copyToRenderTarget(dstSurf, srcSurf, source9->isManaged());
+
+ if (srcSurf) srcSurf->Release();
+ if (dstSurf) dstSurf->Release();
+
+ if (!result)
+ return false;
+ }
+ }
+
+ return result;
+}
+
+bool Renderer9::copyToRenderTarget(TextureStorageInterfaceCube *dest, TextureStorageInterfaceCube *source)
+{
+ bool result = false;
+
+ if (source && dest)
+ {
+ TextureStorage9_Cube *source9 = TextureStorage9_Cube::makeTextureStorage9_Cube(source->getStorageInstance());
+ TextureStorage9_Cube *dest9 = TextureStorage9_Cube::makeTextureStorage9_Cube(dest->getStorageInstance());
+ int levels = source9->levelCount();
+ for (int f = 0; f < 6; f++)
+ {
+ for (int i = 0; i < levels; i++)
+ {
+ IDirect3DSurface9 *srcSurf = source9->getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + f, i, false);
+ IDirect3DSurface9 *dstSurf = dest9->getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + f, i, true);
+
+ result = copyToRenderTarget(dstSurf, srcSurf, source9->isManaged());
+
+ if (srcSurf) srcSurf->Release();
+ if (dstSurf) dstSurf->Release();
+
+ if (!result)
+ return false;
+ }
+ }
+ }
+
+ return result;
+}
+
+D3DPOOL Renderer9::getBufferPool(DWORD usage) const
+{
+ if (mD3d9Ex != NULL)
+ {
+ return D3DPOOL_DEFAULT;
+ }
+ else
+ {
+ if (!(usage & D3DUSAGE_DYNAMIC))
+ {
+ return D3DPOOL_MANAGED;
+ }
+ }
+
+ return D3DPOOL_DEFAULT;
+}
+
+bool Renderer9::copyImage(gl::Framebuffer *framebuffer, const gl::Rectangle &sourceRect, GLenum destFormat,
+ GLint xoffset, GLint yoffset, TextureStorageInterface2D *storage, GLint level)
+{
+ RECT rect;
+ rect.left = sourceRect.x;
+ rect.top = sourceRect.y;
+ rect.right = sourceRect.x + sourceRect.width;
+ rect.bottom = sourceRect.y + sourceRect.height;
+
+ return mBlit->copy(framebuffer, rect, destFormat, xoffset, yoffset, storage, level);
+}
+
+bool Renderer9::copyImage(gl::Framebuffer *framebuffer, const gl::Rectangle &sourceRect, GLenum destFormat,
+ GLint xoffset, GLint yoffset, TextureStorageInterfaceCube *storage, GLenum target, GLint level)
+{
+ RECT rect;
+ rect.left = sourceRect.x;
+ rect.top = sourceRect.y;
+ rect.right = sourceRect.x + sourceRect.width;
+ rect.bottom = sourceRect.y + sourceRect.height;
+
+ return mBlit->copy(framebuffer, rect, destFormat, xoffset, yoffset, storage, target, level);
+}
+
+bool Renderer9::blitRect(gl::Framebuffer *readFramebuffer, const gl::Rectangle &readRect, gl::Framebuffer *drawFramebuffer, const gl::Rectangle &drawRect,
+ bool blitRenderTarget, bool blitDepthStencil)
+{
+ endScene();
+
+ if (blitRenderTarget)
+ {
+ gl::Renderbuffer *readBuffer = readFramebuffer->getColorbuffer(0);
+ gl::Renderbuffer *drawBuffer = drawFramebuffer->getColorbuffer(0);
+ RenderTarget9 *readRenderTarget = NULL;
+ RenderTarget9 *drawRenderTarget = NULL;
+ IDirect3DSurface9* readSurface = NULL;
+ IDirect3DSurface9* drawSurface = NULL;
+
+ if (readBuffer)
+ {
+ readRenderTarget = RenderTarget9::makeRenderTarget9(readBuffer->getRenderTarget());
+ }
+ if (drawBuffer)
+ {
+ drawRenderTarget = RenderTarget9::makeRenderTarget9(drawBuffer->getRenderTarget());
+ }
+
+ if (readRenderTarget)
+ {
+ readSurface = readRenderTarget->getSurface();
+ }
+ if (drawRenderTarget)
+ {
+ drawSurface = drawRenderTarget->getSurface();
+ }
+
+ if (!readSurface || !drawSurface)
+ {
+ ERR("Failed to retrieve the render target.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ RECT srcRect;
+ srcRect.left = readRect.x;
+ srcRect.right = readRect.x + readRect.width;
+ srcRect.top = readRect.y;
+ srcRect.bottom = readRect.y + readRect.height;
+
+ RECT dstRect;
+ dstRect.left = drawRect.x;
+ dstRect.right = drawRect.x + drawRect.width;
+ dstRect.top = drawRect.y;
+ dstRect.bottom = drawRect.y + drawRect.height;
+
+ HRESULT result = mDevice->StretchRect(readSurface, &srcRect, drawSurface, &dstRect, D3DTEXF_NONE);
+
+ readSurface->Release();
+ drawSurface->Release();
+
+ if (FAILED(result))
+ {
+ ERR("BlitFramebufferANGLE failed: StretchRect returned %x.", result);
+ return false;
+ }
+ }
+
+ if (blitDepthStencil)
+ {
+ gl::Renderbuffer *readBuffer = readFramebuffer->getDepthOrStencilbuffer();
+ gl::Renderbuffer *drawBuffer = drawFramebuffer->getDepthOrStencilbuffer();
+ RenderTarget9 *readDepthStencil = NULL;
+ RenderTarget9 *drawDepthStencil = NULL;
+ IDirect3DSurface9* readSurface = NULL;
+ IDirect3DSurface9* drawSurface = NULL;
+
+ if (readBuffer)
+ {
+ readDepthStencil = RenderTarget9::makeRenderTarget9(readBuffer->getDepthStencil());
+ }
+ if (drawBuffer)
+ {
+ drawDepthStencil = RenderTarget9::makeRenderTarget9(drawBuffer->getDepthStencil());
+ }
+
+ if (readDepthStencil)
+ {
+ readSurface = readDepthStencil->getSurface();
+ }
+ if (drawDepthStencil)
+ {
+ drawSurface = drawDepthStencil->getSurface();
+ }
+
+ if (!readSurface || !drawSurface)
+ {
+ ERR("Failed to retrieve the render target.");
+ return gl::error(GL_OUT_OF_MEMORY, false);
+ }
+
+ HRESULT result = mDevice->StretchRect(readSurface, NULL, drawSurface, NULL, D3DTEXF_NONE);
+
+ readSurface->Release();
+ drawSurface->Release();
+
+ if (FAILED(result))
+ {
+ ERR("BlitFramebufferANGLE failed: StretchRect returned %x.", result);
+ return false;
+ }
+ }
+
+ return true;
+}
+
+void Renderer9::readPixels(gl::Framebuffer *framebuffer, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type,
+ GLsizei outputPitch, bool packReverseRowOrder, GLint packAlignment, void* pixels)
+{
+ RenderTarget9 *renderTarget = NULL;
+ IDirect3DSurface9 *surface = NULL;
+ gl::Renderbuffer *colorbuffer = framebuffer->getColorbuffer(0);
+
+ if (colorbuffer)
+ {
+ renderTarget = RenderTarget9::makeRenderTarget9(colorbuffer->getRenderTarget());
+ }
+
+ if (renderTarget)
+ {
+ surface = renderTarget->getSurface();
+ }
+
+ if (!surface)
+ {
+ // context must be lost
+ return;
+ }
+
+ D3DSURFACE_DESC desc;
+ surface->GetDesc(&desc);
+
+ if (desc.MultiSampleType != D3DMULTISAMPLE_NONE)
+ {
+ UNIMPLEMENTED(); // FIXME: Requires resolve using StretchRect into non-multisampled render target
+ surface->Release();
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+ HRESULT result;
+ IDirect3DSurface9 *systemSurface = NULL;
+ bool directToPixels = !packReverseRowOrder && packAlignment <= 4 && getShareHandleSupport() &&
+ x == 0 && y == 0 && UINT(width) == desc.Width && UINT(height) == desc.Height &&
+ desc.Format == D3DFMT_A8R8G8B8 && format == GL_BGRA_EXT && type == GL_UNSIGNED_BYTE;
+ if (directToPixels)
+ {
+ // Use the pixels ptr as a shared handle to write directly into client's memory
+ result = mDevice->CreateOffscreenPlainSurface(desc.Width, desc.Height, desc.Format,
+ D3DPOOL_SYSTEMMEM, &systemSurface, &pixels);
+ if (FAILED(result))
+ {
+ // Try again without the shared handle
+ directToPixels = false;
+ }
+ }
+
+ if (!directToPixels)
+ {
+ result = mDevice->CreateOffscreenPlainSurface(desc.Width, desc.Height, desc.Format,
+ D3DPOOL_SYSTEMMEM, &systemSurface, NULL);
+ if (FAILED(result))
+ {
+ ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
+ surface->Release();
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ result = mDevice->GetRenderTargetData(surface, systemSurface);
+ surface->Release();
+ surface = NULL;
+
+ if (FAILED(result))
+ {
+ systemSurface->Release();
+
+ // It turns out that D3D will sometimes produce more error
+ // codes than those documented.
+ if (d3d9::isDeviceLostError(result))
+ {
+ notifyDeviceLost();
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+ else
+ {
+ UNREACHABLE();
+ return;
+ }
+
+ }
+
+ if (directToPixels)
+ {
+ systemSurface->Release();
+ return;
+ }
+
+ RECT rect;
+ rect.left = gl::clamp(x, 0L, static_cast<LONG>(desc.Width));
+ rect.top = gl::clamp(y, 0L, static_cast<LONG>(desc.Height));
+ rect.right = gl::clamp(x + width, 0L, static_cast<LONG>(desc.Width));
+ rect.bottom = gl::clamp(y + height, 0L, static_cast<LONG>(desc.Height));
+
+ D3DLOCKED_RECT lock;
+ result = systemSurface->LockRect(&lock, &rect, D3DLOCK_READONLY);
+
+ if (FAILED(result))
+ {
+ UNREACHABLE();
+ systemSurface->Release();
+
+ return; // No sensible error to generate
+ }
+
+ unsigned char *dest = (unsigned char*)pixels;
+ unsigned short *dest16 = (unsigned short*)pixels;
+
+ unsigned char *source;
+ int inputPitch;
+ if (packReverseRowOrder)
+ {
+ source = ((unsigned char*)lock.pBits) + lock.Pitch * (rect.bottom - rect.top - 1);
+ inputPitch = -lock.Pitch;
+ }
+ else
+ {
+ source = (unsigned char*)lock.pBits;
+ inputPitch = lock.Pitch;
+ }
+
+ unsigned int fastPixelSize = 0;
+
+ if (desc.Format == D3DFMT_A8R8G8B8 &&
+ format == GL_BGRA_EXT &&
+ type == GL_UNSIGNED_BYTE)
+ {
+ fastPixelSize = 4;
+ }
+ else if ((desc.Format == D3DFMT_A4R4G4B4 &&
+ format == GL_BGRA_EXT &&
+ type == GL_UNSIGNED_SHORT_4_4_4_4_REV_EXT) ||
+ (desc.Format == D3DFMT_A1R5G5B5 &&
+ format == GL_BGRA_EXT &&
+ type == GL_UNSIGNED_SHORT_1_5_5_5_REV_EXT))
+ {
+ fastPixelSize = 2;
+ }
+ else if (desc.Format == D3DFMT_A16B16G16R16F &&
+ format == GL_RGBA &&
+ type == GL_HALF_FLOAT_OES)
+ {
+ fastPixelSize = 8;
+ }
+ else if (desc.Format == D3DFMT_A32B32G32R32F &&
+ format == GL_RGBA &&
+ type == GL_FLOAT)
+ {
+ fastPixelSize = 16;
+ }
+
+ for (int j = 0; j < rect.bottom - rect.top; j++)
+ {
+ if (fastPixelSize != 0)
+ {
+ // Fast path for formats which require no translation:
+ // D3DFMT_A8R8G8B8 to BGRA/UNSIGNED_BYTE
+ // D3DFMT_A4R4G4B4 to BGRA/UNSIGNED_SHORT_4_4_4_4_REV_EXT
+ // D3DFMT_A1R5G5B5 to BGRA/UNSIGNED_SHORT_1_5_5_5_REV_EXT
+ // D3DFMT_A16B16G16R16F to RGBA/HALF_FLOAT_OES
+ // D3DFMT_A32B32G32R32F to RGBA/FLOAT
+ //
+ // Note that buffers with no alpha go through the slow path below.
+ memcpy(dest + j * outputPitch,
+ source + j * inputPitch,
+ (rect.right - rect.left) * fastPixelSize);
+ continue;
+ }
+ else if (desc.Format == D3DFMT_A8R8G8B8 &&
+ format == GL_RGBA &&
+ type == GL_UNSIGNED_BYTE)
+ {
+ // Fast path for swapping red with blue
+ for (int i = 0; i < rect.right - rect.left; i++)
+ {
+ unsigned int argb = *(unsigned int*)(source + 4 * i + j * inputPitch);
+ *(unsigned int*)(dest + 4 * i + j * outputPitch) =
+ (argb & 0xFF00FF00) | // Keep alpha and green
+ (argb & 0x00FF0000) >> 16 | // Move red to blue
+ (argb & 0x000000FF) << 16; // Move blue to red
+ }
+ continue;
+ }
+
+ for (int i = 0; i < rect.right - rect.left; i++)
+ {
+ float r;
+ float g;
+ float b;
+ float a;
+
+ switch (desc.Format)
+ {
+ case D3DFMT_R5G6B5:
+ {
+ unsigned short rgb = *(unsigned short*)(source + 2 * i + j * inputPitch);
+
+ a = 1.0f;
+ b = (rgb & 0x001F) * (1.0f / 0x001F);
+ g = (rgb & 0x07E0) * (1.0f / 0x07E0);
+ r = (rgb & 0xF800) * (1.0f / 0xF800);
+ }
+ break;
+ case D3DFMT_A1R5G5B5:
+ {
+ unsigned short argb = *(unsigned short*)(source + 2 * i + j * inputPitch);
+
+ a = (argb & 0x8000) ? 1.0f : 0.0f;
+ b = (argb & 0x001F) * (1.0f / 0x001F);
+ g = (argb & 0x03E0) * (1.0f / 0x03E0);
+ r = (argb & 0x7C00) * (1.0f / 0x7C00);
+ }
+ break;
+ case D3DFMT_A8R8G8B8:
+ {
+ unsigned int argb = *(unsigned int*)(source + 4 * i + j * inputPitch);
+
+ a = (argb & 0xFF000000) * (1.0f / 0xFF000000);
+ b = (argb & 0x000000FF) * (1.0f / 0x000000FF);
+ g = (argb & 0x0000FF00) * (1.0f / 0x0000FF00);
+ r = (argb & 0x00FF0000) * (1.0f / 0x00FF0000);
+ }
+ break;
+ case D3DFMT_X8R8G8B8:
+ {
+ unsigned int xrgb = *(unsigned int*)(source + 4 * i + j * inputPitch);
+
+ a = 1.0f;
+ b = (xrgb & 0x000000FF) * (1.0f / 0x000000FF);
+ g = (xrgb & 0x0000FF00) * (1.0f / 0x0000FF00);
+ r = (xrgb & 0x00FF0000) * (1.0f / 0x00FF0000);
+ }
+ break;
+ case D3DFMT_A2R10G10B10:
+ {
+ unsigned int argb = *(unsigned int*)(source + 4 * i + j * inputPitch);
+
+ a = (argb & 0xC0000000) * (1.0f / 0xC0000000);
+ b = (argb & 0x000003FF) * (1.0f / 0x000003FF);
+ g = (argb & 0x000FFC00) * (1.0f / 0x000FFC00);
+ r = (argb & 0x3FF00000) * (1.0f / 0x3FF00000);
+ }
+ break;
+ case D3DFMT_A32B32G32R32F:
+ {
+ // float formats in D3D are stored rgba, rather than the other way round
+ r = *((float*)(source + 16 * i + j * inputPitch) + 0);
+ g = *((float*)(source + 16 * i + j * inputPitch) + 1);
+ b = *((float*)(source + 16 * i + j * inputPitch) + 2);
+ a = *((float*)(source + 16 * i + j * inputPitch) + 3);
+ }
+ break;
+ case D3DFMT_A16B16G16R16F:
+ {
+ // float formats in D3D are stored rgba, rather than the other way round
+ r = gl::float16ToFloat32(*((unsigned short*)(source + 8 * i + j * inputPitch) + 0));
+ g = gl::float16ToFloat32(*((unsigned short*)(source + 8 * i + j * inputPitch) + 1));
+ b = gl::float16ToFloat32(*((unsigned short*)(source + 8 * i + j * inputPitch) + 2));
+ a = gl::float16ToFloat32(*((unsigned short*)(source + 8 * i + j * inputPitch) + 3));
+ }
+ break;
+ default:
+ UNIMPLEMENTED(); // FIXME
+ UNREACHABLE();
+ return;
+ }
+
+ switch (format)
+ {
+ case GL_RGBA:
+ switch (type)
+ {
+ case GL_UNSIGNED_BYTE:
+ dest[4 * i + j * outputPitch + 0] = (unsigned char)(255 * r + 0.5f);
+ dest[4 * i + j * outputPitch + 1] = (unsigned char)(255 * g + 0.5f);
+ dest[4 * i + j * outputPitch + 2] = (unsigned char)(255 * b + 0.5f);
+ dest[4 * i + j * outputPitch + 3] = (unsigned char)(255 * a + 0.5f);
+ break;
+ default: UNREACHABLE();
+ }
+ break;
+ case GL_BGRA_EXT:
+ switch (type)
+ {
+ case GL_UNSIGNED_BYTE:
+ dest[4 * i + j * outputPitch + 0] = (unsigned char)(255 * b + 0.5f);
+ dest[4 * i + j * outputPitch + 1] = (unsigned char)(255 * g + 0.5f);
+ dest[4 * i + j * outputPitch + 2] = (unsigned char)(255 * r + 0.5f);
+ dest[4 * i + j * outputPitch + 3] = (unsigned char)(255 * a + 0.5f);
+ break;
+ case GL_UNSIGNED_SHORT_4_4_4_4_REV_EXT:
+ // According to the desktop GL spec in the "Transfer of Pixel Rectangles" section
+ // this type is packed as follows:
+ // 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
+ // --------------------------------------------------------------------------------
+ // | 4th | 3rd | 2nd | 1st component |
+ // --------------------------------------------------------------------------------
+ // in the case of BGRA_EXT, B is the first component, G the second, and so forth.
+ dest16[i + j * outputPitch / sizeof(unsigned short)] =
+ ((unsigned short)(15 * a + 0.5f) << 12)|
+ ((unsigned short)(15 * r + 0.5f) << 8) |
+ ((unsigned short)(15 * g + 0.5f) << 4) |
+ ((unsigned short)(15 * b + 0.5f) << 0);
+ break;
+ case GL_UNSIGNED_SHORT_1_5_5_5_REV_EXT:
+ // According to the desktop GL spec in the "Transfer of Pixel Rectangles" section
+ // this type is packed as follows:
+ // 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
+ // --------------------------------------------------------------------------------
+ // | 4th | 3rd | 2nd | 1st component |
+ // --------------------------------------------------------------------------------
+ // in the case of BGRA_EXT, B is the first component, G the second, and so forth.
+ dest16[i + j * outputPitch / sizeof(unsigned short)] =
+ ((unsigned short)( a + 0.5f) << 15) |
+ ((unsigned short)(31 * r + 0.5f) << 10) |
+ ((unsigned short)(31 * g + 0.5f) << 5) |
+ ((unsigned short)(31 * b + 0.5f) << 0);
+ break;
+ default: UNREACHABLE();
+ }
+ break;
+ case GL_RGB:
+ switch (type)
+ {
+ case GL_UNSIGNED_SHORT_5_6_5:
+ dest16[i + j * outputPitch / sizeof(unsigned short)] =
+ ((unsigned short)(31 * b + 0.5f) << 0) |
+ ((unsigned short)(63 * g + 0.5f) << 5) |
+ ((unsigned short)(31 * r + 0.5f) << 11);
+ break;
+ case GL_UNSIGNED_BYTE:
+ dest[3 * i + j * outputPitch + 0] = (unsigned char)(255 * r + 0.5f);
+ dest[3 * i + j * outputPitch + 1] = (unsigned char)(255 * g + 0.5f);
+ dest[3 * i + j * outputPitch + 2] = (unsigned char)(255 * b + 0.5f);
+ break;
+ default: UNREACHABLE();
+ }
+ break;
+ default: UNREACHABLE();
+ }
+ }
+ }
+
+ systemSurface->UnlockRect();
+
+ systemSurface->Release();
+}
+
+RenderTarget *Renderer9::createRenderTarget(SwapChain *swapChain, bool depth)
+{
+ SwapChain9 *swapChain9 = SwapChain9::makeSwapChain9(swapChain);
+ IDirect3DSurface9 *surface = NULL;
+ if (depth)
+ {
+ surface = swapChain9->getDepthStencil();
+ }
+ else
+ {
+ surface = swapChain9->getRenderTarget();
+ }
+
+ RenderTarget9 *renderTarget = new RenderTarget9(this, surface);
+
+ return renderTarget;
+}
+
+RenderTarget *Renderer9::createRenderTarget(int width, int height, GLenum format, GLsizei samples, bool depth)
+{
+ RenderTarget9 *renderTarget = new RenderTarget9(this, width, height, format, samples);
+ return renderTarget;
+}
+
+ShaderExecutable *Renderer9::loadExecutable(const void *function, size_t length, rx::ShaderType type)
+{
+ ShaderExecutable9 *executable = NULL;
+
+ switch (type)
+ {
+ case rx::SHADER_VERTEX:
+ {
+ IDirect3DVertexShader9 *vshader = createVertexShader((DWORD*)function, length);
+ if (vshader)
+ {
+ executable = new ShaderExecutable9(function, length, vshader);
+ }
+ }
+ break;
+ case rx::SHADER_PIXEL:
+ {
+ IDirect3DPixelShader9 *pshader = createPixelShader((DWORD*)function, length);
+ if (pshader)
+ {
+ executable = new ShaderExecutable9(function, length, pshader);
+ }
+ }
+ break;
+ default:
+ UNREACHABLE();
+ break;
+ }
+
+ return executable;
+}
+
+ShaderExecutable *Renderer9::compileToExecutable(gl::InfoLog &infoLog, const char *shaderHLSL, rx::ShaderType type)
+{
+ const char *profile = NULL;
+
+ switch (type)
+ {
+ case rx::SHADER_VERTEX:
+ profile = getMajorShaderModel() >= 3 ? "vs_3_0" : "vs_2_0";
+ break;
+ case rx::SHADER_PIXEL:
+ profile = getMajorShaderModel() >= 3 ? "ps_3_0" : "ps_2_0";
+ break;
+ default:
+ UNREACHABLE();
+ return NULL;
+ }
+
+ ID3DBlob *binary = (ID3DBlob*)compileToBinary(infoLog, shaderHLSL, profile, ANGLE_COMPILE_OPTIMIZATION_LEVEL, true);
+ if (!binary)
+ return NULL;
+
+ ShaderExecutable *executable = loadExecutable(binary->GetBufferPointer(), binary->GetBufferSize(), type);
+ binary->Release();
+
+ return executable;
+}
+
+bool Renderer9::boxFilter(IDirect3DSurface9 *source, IDirect3DSurface9 *dest)
+{
+ return mBlit->boxFilter(source, dest);
+}
+
+D3DPOOL Renderer9::getTexturePool(DWORD usage) const
+{
+ if (mD3d9Ex != NULL)
+ {
+ return D3DPOOL_DEFAULT;
+ }
+ else
+ {
+ if (!(usage & (D3DUSAGE_DEPTHSTENCIL | D3DUSAGE_RENDERTARGET)))
+ {
+ return D3DPOOL_MANAGED;
+ }
+ }
+
+ return D3DPOOL_DEFAULT;
+}
+
+bool Renderer9::copyToRenderTarget(IDirect3DSurface9 *dest, IDirect3DSurface9 *source, bool fromManaged)
+{
+ if (source && dest)
+ {
+ HRESULT result = D3DERR_OUTOFVIDEOMEMORY;
+
+ if (fromManaged)
+ {
+ D3DSURFACE_DESC desc;
+ source->GetDesc(&desc);
+
+ IDirect3DSurface9 *surf = 0;
+ result = mDevice->CreateOffscreenPlainSurface(desc.Width, desc.Height, desc.Format, D3DPOOL_SYSTEMMEM, &surf, NULL);
+
+ if (SUCCEEDED(result))
+ {
+ Image9::copyLockableSurfaces(surf, source);
+ result = mDevice->UpdateSurface(surf, NULL, dest, NULL);
+ surf->Release();
+ }
+ }
+ else
+ {
+ endScene();
+ result = mDevice->StretchRect(source, NULL, dest, NULL, D3DTEXF_NONE);
+ }
+
+ if (FAILED(result))
+ {
+ ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
+ return false;
+ }
+ }
+
+ return true;
+}
+
+Image *Renderer9::createImage()
+{
+ return new Image9();
+}
+
+void Renderer9::generateMipmap(Image *dest, Image *src)
+{
+ Image9 *src9 = Image9::makeImage9(src);
+ Image9 *dst9 = Image9::makeImage9(dest);
+ Image9::generateMipmap(dst9, src9);
+}
+
+TextureStorage *Renderer9::createTextureStorage2D(SwapChain *swapChain)
+{
+ SwapChain9 *swapChain9 = SwapChain9::makeSwapChain9(swapChain);
+ return new TextureStorage9_2D(this, swapChain9);
+}
+
+TextureStorage *Renderer9::createTextureStorage2D(int levels, GLenum internalformat, GLenum usage, bool forceRenderable, GLsizei width, GLsizei height)
+{
+ return new TextureStorage9_2D(this, levels, internalformat, usage, forceRenderable, width, height);
+}
+
+TextureStorage *Renderer9::createTextureStorageCube(int levels, GLenum internalformat, GLenum usage, bool forceRenderable, int size)
+{
+ return new TextureStorage9_Cube(this, levels, internalformat, usage, forceRenderable, size);
+}
+
+} \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Renderer9.h b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer9.h
new file mode 100644
index 0000000000..527a5010ae
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer9.h
@@ -0,0 +1,347 @@
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// Renderer9.h: Defines a back-end specific class for the D3D9 renderer.
+
+#ifndef LIBGLESV2_RENDERER_RENDERER9_H_
+#define LIBGLESV2_RENDERER_RENDERER9_H_
+
+#include "common/angleutils.h"
+#include "libGLESv2/mathutil.h"
+#include "libGLESv2/renderer/ShaderCache.h"
+#include "libGLESv2/renderer/VertexDeclarationCache.h"
+#include "libGLESv2/renderer/Renderer.h"
+#include "libGLESv2/renderer/RenderTarget.h"
+
+namespace gl
+{
+class Renderbuffer;
+}
+
+namespace rx
+{
+class VertexDataManager;
+class IndexDataManager;
+class StreamingIndexBufferInterface;
+struct TranslatedAttribute;
+
+class Renderer9 : public Renderer
+{
+ public:
+ Renderer9(egl::Display *display, HDC hDc, bool softwareDevice);
+ virtual ~Renderer9();
+
+ static Renderer9 *makeRenderer9(Renderer *renderer);
+
+ virtual EGLint initialize();
+ virtual bool resetDevice();
+
+ virtual int generateConfigs(ConfigDesc **configDescList);
+ virtual void deleteConfigs(ConfigDesc *configDescList);
+
+ void startScene();
+ void endScene();
+
+ virtual void sync(bool block);
+
+ virtual SwapChain *createSwapChain(HWND window, HANDLE shareHandle, GLenum backBufferFormat, GLenum depthBufferFormat);
+
+ IDirect3DQuery9* allocateEventQuery();
+ void freeEventQuery(IDirect3DQuery9* query);
+
+ // resource creation
+ IDirect3DVertexShader9 *createVertexShader(const DWORD *function, size_t length);
+ IDirect3DPixelShader9 *createPixelShader(const DWORD *function, size_t length);
+ HRESULT createVertexBuffer(UINT Length, DWORD Usage, IDirect3DVertexBuffer9 **ppVertexBuffer);
+ HRESULT createIndexBuffer(UINT Length, DWORD Usage, D3DFORMAT Format, IDirect3DIndexBuffer9 **ppIndexBuffer);
+#if 0
+ void *createTexture2D();
+ void *createTextureCube();
+ void *createQuery();
+ void *createIndexBuffer();
+ void *createVertexbuffer();
+
+ // state setup
+ void applyShaders();
+ void applyConstants();
+#endif
+ virtual void setSamplerState(gl::SamplerType type, int index, const gl::SamplerState &sampler);
+ virtual void setTexture(gl::SamplerType type, int index, gl::Texture *texture);
+
+ virtual void setRasterizerState(const gl::RasterizerState &rasterState);
+ virtual void setBlendState(const gl::BlendState &blendState, const gl::Color &blendColor,
+ unsigned int sampleMask);
+ virtual void setDepthStencilState(const gl::DepthStencilState &depthStencilState, int stencilRef,
+ int stencilBackRef, bool frontFaceCCW);
+
+ virtual void setScissorRectangle(const gl::Rectangle &scissor, bool enabled);
+ virtual bool setViewport(const gl::Rectangle &viewport, float zNear, float zFar, GLenum drawMode, GLenum frontFace,
+ bool ignoreViewport);
+
+ virtual bool applyRenderTarget(gl::Framebuffer *frameBuffer);
+ virtual void applyShaders(gl::ProgramBinary *programBinary);
+ virtual void applyUniforms(gl::ProgramBinary *programBinary, gl::UniformArray *uniformArray);
+ virtual bool applyPrimitiveType(GLenum primitiveType, GLsizei elementCount);
+ virtual GLenum applyVertexBuffer(gl::ProgramBinary *programBinary, gl::VertexAttribute vertexAttributes[], GLint first, GLsizei count, GLsizei instances);
+ virtual GLenum applyIndexBuffer(const GLvoid *indices, gl::Buffer *elementArrayBuffer, GLsizei count, GLenum mode, GLenum type, TranslatedIndexData *indexInfo);
+
+ virtual void drawArrays(GLenum mode, GLsizei count, GLsizei instances);
+ virtual void drawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, gl::Buffer *elementArrayBuffer, const TranslatedIndexData &indexInfo, GLsizei instances);
+
+ virtual void clear(const gl::ClearParameters &clearParams, gl::Framebuffer *frameBuffer);
+
+ virtual void markAllStateDirty();
+
+ // lost device
+ void notifyDeviceLost();
+ virtual bool isDeviceLost();
+ virtual bool testDeviceLost(bool notify);
+ virtual bool testDeviceResettable();
+
+ // Renderer capabilities
+ IDirect3DDevice9 *getDevice() { return mDevice; }
+ virtual DWORD getAdapterVendor() const;
+ virtual std::string getRendererDescription() const;
+ virtual GUID getAdapterIdentifier() const;
+
+ virtual bool getBGRATextureSupport() const;
+ virtual bool getDXT1TextureSupport();
+ virtual bool getDXT3TextureSupport();
+ virtual bool getDXT5TextureSupport();
+ virtual bool getEventQuerySupport();
+ virtual bool getFloat32TextureSupport(bool *filtering, bool *renderable);
+ virtual bool getFloat16TextureSupport(bool *filtering, bool *renderable);
+ virtual bool getLuminanceTextureSupport();
+ virtual bool getLuminanceAlphaTextureSupport();
+ virtual unsigned int getMaxVertexTextureImageUnits() const;
+ virtual unsigned int getMaxCombinedTextureImageUnits() const;
+ virtual unsigned int getReservedVertexUniformVectors() const;
+ virtual unsigned int getReservedFragmentUniformVectors() const;
+ virtual unsigned int getMaxVertexUniformVectors() const;
+ virtual unsigned int getMaxFragmentUniformVectors() const;
+ virtual unsigned int getMaxVaryingVectors() const;
+ virtual bool getNonPower2TextureSupport() const;
+ virtual bool getDepthTextureSupport() const;
+ virtual bool getOcclusionQuerySupport() const;
+ virtual bool getInstancingSupport() const;
+ virtual bool getTextureFilterAnisotropySupport() const;
+ virtual float getTextureMaxAnisotropy() const;
+ virtual bool getShareHandleSupport() const;
+ virtual bool getDerivativeInstructionSupport() const;
+ virtual bool getPostSubBufferSupport() const;
+
+ virtual int getMajorShaderModel() const;
+ virtual float getMaxPointSize() const;
+ virtual int getMaxViewportDimension() const;
+ virtual int getMaxTextureWidth() const;
+ virtual int getMaxTextureHeight() const;
+ virtual bool get32BitIndexSupport() const;
+ DWORD getCapsDeclTypes() const;
+ virtual int getMinSwapInterval() const;
+ virtual int getMaxSwapInterval() const;
+
+ virtual GLsizei getMaxSupportedSamples() const;
+ int getNearestSupportedSamples(D3DFORMAT format, int requested) const;
+
+ virtual unsigned int getMaxRenderTargets() const;
+
+ D3DFORMAT ConvertTextureInternalFormat(GLint internalformat);
+
+ // Pixel operations
+ virtual bool copyToRenderTarget(TextureStorageInterface2D *dest, TextureStorageInterface2D *source);
+ virtual bool copyToRenderTarget(TextureStorageInterfaceCube *dest, TextureStorageInterfaceCube *source);
+
+ virtual bool copyImage(gl::Framebuffer *framebuffer, const gl::Rectangle &sourceRect, GLenum destFormat,
+ GLint xoffset, GLint yoffset, TextureStorageInterface2D *storage, GLint level);
+ virtual bool copyImage(gl::Framebuffer *framebuffer, const gl::Rectangle &sourceRect, GLenum destFormat,
+ GLint xoffset, GLint yoffset, TextureStorageInterfaceCube *storage, GLenum target, GLint level);
+
+ virtual bool blitRect(gl::Framebuffer *readTarget, const gl::Rectangle &readRect, gl::Framebuffer *drawTarget, const gl::Rectangle &drawRect,
+ bool blitRenderTarget, bool blitDepthStencil);
+ virtual void readPixels(gl::Framebuffer *framebuffer, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type,
+ GLsizei outputPitch, bool packReverseRowOrder, GLint packAlignment, void* pixels);
+
+ // RenderTarget creation
+ virtual RenderTarget *createRenderTarget(SwapChain *swapChain, bool depth);
+ virtual RenderTarget *createRenderTarget(int width, int height, GLenum format, GLsizei samples, bool depth);
+
+ // Shader operations
+ virtual ShaderExecutable *loadExecutable(const void *function, size_t length, rx::ShaderType type);
+ virtual ShaderExecutable *compileToExecutable(gl::InfoLog &infoLog, const char *shaderHLSL, rx::ShaderType type);
+
+ // Image operations
+ virtual Image *createImage();
+ virtual void generateMipmap(Image *dest, Image *source);
+ virtual TextureStorage *createTextureStorage2D(SwapChain *swapChain);
+ virtual TextureStorage *createTextureStorage2D(int levels, GLenum internalformat, GLenum usage, bool forceRenderable, GLsizei width, GLsizei height);
+ virtual TextureStorage *createTextureStorageCube(int levels, GLenum internalformat, GLenum usage, bool forceRenderable, int size);
+
+ // Buffer creation
+ virtual VertexBuffer *createVertexBuffer();
+ virtual IndexBuffer *createIndexBuffer();
+ virtual BufferStorage *createBufferStorage();
+
+ // Query and Fence creation
+ virtual QueryImpl *createQuery(GLenum type);
+ virtual FenceImpl *createFence();
+
+ // D3D9-renderer specific methods
+ bool boxFilter(IDirect3DSurface9 *source, IDirect3DSurface9 *dest);
+
+ D3DPOOL getTexturePool(DWORD usage) const;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(Renderer9);
+
+ void applyUniformnfv(gl::Uniform *targetUniform, const GLfloat *v);
+ void applyUniformniv(gl::Uniform *targetUniform, const GLint *v);
+ void applyUniformnbv(gl::Uniform *targetUniform, const GLint *v);
+
+ void drawLineLoop(GLsizei count, GLenum type, const GLvoid *indices, int minIndex, gl::Buffer *elementArrayBuffer);
+ void drawIndexedPoints(GLsizei count, GLenum type, const GLvoid *indices, gl::Buffer *elementArrayBuffer);
+
+ void getMultiSampleSupport(D3DFORMAT format, bool *multiSampleArray);
+ bool copyToRenderTarget(IDirect3DSurface9 *dest, IDirect3DSurface9 *source, bool fromManaged);
+ gl::Renderbuffer *getNullColorbuffer(gl::Renderbuffer *depthbuffer);
+
+ D3DPOOL getBufferPool(DWORD usage) const;
+
+ HMODULE mD3d9Module;
+ HDC mDc;
+
+ void initializeDevice();
+ D3DPRESENT_PARAMETERS getDefaultPresentParameters();
+ void releaseDeviceResources();
+
+ UINT mAdapter;
+ D3DDEVTYPE mDeviceType;
+ bool mSoftwareDevice; // FIXME: Deprecate
+ IDirect3D9 *mD3d9; // Always valid after successful initialization.
+ IDirect3D9Ex *mD3d9Ex; // Might be null if D3D9Ex is not supported.
+ IDirect3DDevice9 *mDevice;
+ IDirect3DDevice9Ex *mDeviceEx; // Might be null if D3D9Ex is not supported.
+
+ Blit *mBlit;
+
+ HWND mDeviceWindow;
+
+ bool mDeviceLost;
+ D3DCAPS9 mDeviceCaps;
+ D3DADAPTER_IDENTIFIER9 mAdapterIdentifier;
+
+ D3DPRIMITIVETYPE mPrimitiveType;
+ int mPrimitiveCount;
+ GLsizei mRepeatDraw;
+
+ bool mSceneStarted;
+ bool mSupportsNonPower2Textures;
+ bool mSupportsTextureFilterAnisotropy;
+ int mMinSwapInterval;
+ int mMaxSwapInterval;
+
+ bool mOcclusionQuerySupport;
+ bool mEventQuerySupport;
+ bool mVertexTextureSupport;
+
+ bool mDepthTextureSupport;
+
+ bool mFloat32TextureSupport;
+ bool mFloat32FilterSupport;
+ bool mFloat32RenderSupport;
+
+ bool mFloat16TextureSupport;
+ bool mFloat16FilterSupport;
+ bool mFloat16RenderSupport;
+
+ bool mDXT1TextureSupport;
+ bool mDXT3TextureSupport;
+ bool mDXT5TextureSupport;
+
+ bool mLuminanceTextureSupport;
+ bool mLuminanceAlphaTextureSupport;
+
+ std::map<D3DFORMAT, bool *> mMultiSampleSupport;
+ GLsizei mMaxSupportedSamples;
+
+ // current render target states
+ unsigned int mAppliedRenderTargetSerial;
+ unsigned int mAppliedDepthbufferSerial;
+ unsigned int mAppliedStencilbufferSerial;
+ bool mDepthStencilInitialized;
+ bool mRenderTargetDescInitialized;
+ rx::RenderTarget::Desc mRenderTargetDesc;
+ unsigned int mCurStencilSize;
+ unsigned int mCurDepthSize;
+
+ IDirect3DStateBlock9 *mMaskedClearSavedState;
+
+ // previously set render states
+ bool mForceSetDepthStencilState;
+ gl::DepthStencilState mCurDepthStencilState;
+ int mCurStencilRef;
+ int mCurStencilBackRef;
+ bool mCurFrontFaceCCW;
+
+ bool mForceSetRasterState;
+ gl::RasterizerState mCurRasterState;
+
+ bool mForceSetScissor;
+ gl::Rectangle mCurScissor;
+ bool mScissorEnabled;
+
+ bool mForceSetViewport;
+ gl::Rectangle mCurViewport;
+ float mCurNear;
+ float mCurFar;
+
+ bool mForceSetBlendState;
+ gl::BlendState mCurBlendState;
+ gl::Color mCurBlendColor;
+ GLuint mCurSampleMask;
+
+ // Currently applied sampler states
+ bool mForceSetVertexSamplerStates[gl::IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS];
+ gl::SamplerState mCurVertexSamplerStates[gl::IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS];
+
+ bool mForceSetPixelSamplerStates[gl::MAX_TEXTURE_IMAGE_UNITS];
+ gl::SamplerState mCurPixelSamplerStates[gl::MAX_TEXTURE_IMAGE_UNITS];
+
+ // Currently applied textures
+ unsigned int mCurVertexTextureSerials[gl::IMPLEMENTATION_MAX_VERTEX_TEXTURE_IMAGE_UNITS];
+ unsigned int mCurPixelTextureSerials[gl::MAX_TEXTURE_IMAGE_UNITS];
+
+ unsigned int mAppliedIBSerial;
+ unsigned int mAppliedProgramBinarySerial;
+
+ rx::dx_VertexConstants mVertexConstants;
+ rx::dx_PixelConstants mPixelConstants;
+ bool mDxUniformsDirty;
+
+ // A pool of event queries that are currently unused.
+ std::vector<IDirect3DQuery9*> mEventQueryPool;
+ VertexShaderCache mVertexShaderCache;
+ PixelShaderCache mPixelShaderCache;
+
+ VertexDataManager *mVertexDataManager;
+ VertexDeclarationCache mVertexDeclarationCache;
+
+ IndexDataManager *mIndexDataManager;
+ StreamingIndexBufferInterface *mLineLoopIB;
+
+ enum { NUM_NULL_COLORBUFFER_CACHE_ENTRIES = 12 };
+ struct NullColorbufferCacheEntry
+ {
+ UINT lruCount;
+ int width;
+ int height;
+ gl::Renderbuffer *buffer;
+ } mNullColorbufferCache[NUM_NULL_COLORBUFFER_CACHE_ENTRIES];
+ UINT mMaxNullColorbufferLRU;
+
+};
+
+}
+#endif // LIBGLESV2_RENDERER_RENDERER9_H_
diff --git a/src/3rdparty/angle/src/libEGL/ShaderCache.h b/src/3rdparty/angle/src/libGLESv2/renderer/ShaderCache.h
index cfe523ba09..4391ac271a 100644
--- a/src/3rdparty/angle/src/libEGL/ShaderCache.h
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/ShaderCache.h
@@ -4,21 +4,15 @@
// found in the LICENSE file.
//
-// Display.h: Defines egl::ShaderCache, a cache of Direct3D shader objects
+// ShaderCache: Defines rx::ShaderCache, a cache of Direct3D shader objects
// keyed by their byte code.
-#ifndef LIBEGL_SHADER_CACHE_H_
-#define LIBEGL_SHADER_CACHE_H_
+#ifndef LIBGLESV2_RENDERER_SHADER_CACHE_H_
+#define LIBGLESV2_RENDERER_SHADER_CACHE_H_
-#include <d3d9.h>
+#include "common/debug.h"
-#ifdef _MSC_VER
-#include <hash_map>
-#else
-#include <unordered_map>
-#endif
-
-namespace egl
+namespace rx
{
template <typename ShaderObject>
class ShaderCache
@@ -48,7 +42,7 @@ class ShaderCache
it->second->AddRef();
return it->second;
}
-
+
ShaderObject *shader;
HRESULT result = createShader(function, &shader);
if (FAILED(result))
@@ -113,4 +107,4 @@ typedef ShaderCache<IDirect3DPixelShader9> PixelShaderCache;
}
-#endif // LIBEGL_SHADER_CACHE_H_
+#endif // LIBGLESV2_RENDERER_SHADER_CACHE_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable.h b/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable.h
new file mode 100644
index 0000000000..128d123fbe
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable.h
@@ -0,0 +1,51 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// ShaderExecutable.h: Defines a renderer-agnostic class to contain shader
+// executable implementation details.
+
+#ifndef LIBGLESV2_RENDERER_SHADEREXECUTABLE_H_
+#define LIBGLESV2_RENDERER_SHADEREXECUTABLE_H_
+
+#include "common/angleutils.h"
+
+namespace rx
+{
+
+class ShaderExecutable
+{
+ public:
+ ShaderExecutable(const void *function, size_t length) : mLength(length)
+ {
+ mFunction = new char[length];
+ memcpy(mFunction, function, length);
+ }
+
+ virtual ~ShaderExecutable()
+ {
+ delete mFunction;
+ }
+
+ void *getFunction() const
+ {
+ return mFunction;
+ }
+
+ size_t getLength() const
+ {
+ return mLength;
+ }
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(ShaderExecutable);
+
+ void *mFunction;
+ const size_t mLength;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_SHADEREXECUTABLE9_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable11.cpp
new file mode 100644
index 0000000000..e1eb560334
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable11.cpp
@@ -0,0 +1,109 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// ShaderExecutable11.cpp: Implements a D3D11-specific class to contain shader
+// executable implementation details.
+
+#include "libGLESv2/renderer/ShaderExecutable11.h"
+
+#include "common/debug.h"
+
+namespace rx
+{
+
+ShaderExecutable11::ShaderExecutable11(const void *function, size_t length, ID3D11PixelShader *executable)
+ : ShaderExecutable(function, length)
+{
+ mPixelExecutable = executable;
+ mVertexExecutable = NULL;
+ mGeometryExecutable = NULL;
+
+ mConstantBuffer = NULL;
+}
+
+ShaderExecutable11::ShaderExecutable11(const void *function, size_t length, ID3D11VertexShader *executable)
+ : ShaderExecutable(function, length)
+{
+ mVertexExecutable = executable;
+ mPixelExecutable = NULL;
+ mGeometryExecutable = NULL;
+
+ mConstantBuffer = NULL;
+}
+
+ShaderExecutable11::ShaderExecutable11(const void *function, size_t length, ID3D11GeometryShader *executable)
+ : ShaderExecutable(function, length)
+{
+ mGeometryExecutable = executable;
+ mVertexExecutable = NULL;
+ mPixelExecutable = NULL;
+
+ mConstantBuffer = NULL;
+}
+
+ShaderExecutable11::~ShaderExecutable11()
+{
+ if (mVertexExecutable)
+ {
+ mVertexExecutable->Release();
+ }
+ if (mPixelExecutable)
+ {
+ mPixelExecutable->Release();
+ }
+ if (mGeometryExecutable)
+ {
+ mGeometryExecutable->Release();
+ }
+
+ if (mConstantBuffer)
+ {
+ mConstantBuffer->Release();
+ }
+}
+
+ShaderExecutable11 *ShaderExecutable11::makeShaderExecutable11(ShaderExecutable *executable)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(ShaderExecutable11*, executable));
+ return static_cast<ShaderExecutable11*>(executable);
+}
+
+ID3D11VertexShader *ShaderExecutable11::getVertexShader() const
+{
+ return mVertexExecutable;
+}
+
+ID3D11PixelShader *ShaderExecutable11::getPixelShader() const
+{
+ return mPixelExecutable;
+}
+
+ID3D11GeometryShader *ShaderExecutable11::getGeometryShader() const
+{
+ return mGeometryExecutable;
+}
+
+ID3D11Buffer *ShaderExecutable11::getConstantBuffer(ID3D11Device *device, unsigned int registerCount)
+{
+ if (!mConstantBuffer && registerCount > 0)
+ {
+ D3D11_BUFFER_DESC constantBufferDescription = {0};
+ constantBufferDescription.ByteWidth = registerCount * sizeof(float[4]);
+ constantBufferDescription.Usage = D3D11_USAGE_DYNAMIC;
+ constantBufferDescription.BindFlags = D3D11_BIND_CONSTANT_BUFFER;
+ constantBufferDescription.CPUAccessFlags = D3D11_CPU_ACCESS_WRITE;
+ constantBufferDescription.MiscFlags = 0;
+ constantBufferDescription.StructureByteStride = 0;
+
+ HRESULT result = device->CreateBuffer(&constantBufferDescription, NULL, &mConstantBuffer);
+ ASSERT(SUCCEEDED(result));
+ }
+
+ return mConstantBuffer;
+}
+
+} \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable11.h b/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable11.h
new file mode 100644
index 0000000000..c6ec1cf7d2
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable11.h
@@ -0,0 +1,47 @@
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// ShaderExecutable11.h: Defines a D3D11-specific class to contain shader
+// executable implementation details.
+
+#ifndef LIBGLESV2_RENDERER_SHADEREXECUTABLE11_H_
+#define LIBGLESV2_RENDERER_SHADEREXECUTABLE11_H_
+
+#include "libGLESv2/renderer/ShaderExecutable.h"
+
+namespace rx
+{
+
+class ShaderExecutable11 : public ShaderExecutable
+{
+ public:
+ ShaderExecutable11(const void *function, size_t length, ID3D11PixelShader *executable);
+ ShaderExecutable11(const void *function, size_t length, ID3D11VertexShader *executable);
+ ShaderExecutable11(const void *function, size_t length, ID3D11GeometryShader *executable);
+
+ virtual ~ShaderExecutable11();
+
+ static ShaderExecutable11 *makeShaderExecutable11(ShaderExecutable *executable);
+
+ ID3D11PixelShader *getPixelShader() const;
+ ID3D11VertexShader *getVertexShader() const;
+ ID3D11GeometryShader *getGeometryShader() const;
+
+ ID3D11Buffer *getConstantBuffer(ID3D11Device *device, unsigned int registerCount);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(ShaderExecutable11);
+
+ ID3D11PixelShader *mPixelExecutable;
+ ID3D11VertexShader *mVertexExecutable;
+ ID3D11GeometryShader *mGeometryExecutable;
+
+ ID3D11Buffer *mConstantBuffer;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_SHADEREXECUTABLE11_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable9.cpp
new file mode 100644
index 0000000000..98868a3fbf
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable9.cpp
@@ -0,0 +1,60 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// ShaderExecutable9.cpp: Implements a D3D9-specific class to contain shader
+// executable implementation details.
+
+#include "libGLESv2/renderer/ShaderExecutable9.h"
+
+#include "common/debug.h"
+
+namespace rx
+{
+
+ShaderExecutable9::ShaderExecutable9(const void *function, size_t length, IDirect3DPixelShader9 *executable)
+ : ShaderExecutable(function, length)
+{
+ mPixelExecutable = executable;
+ mVertexExecutable = NULL;
+}
+
+ShaderExecutable9::ShaderExecutable9(const void *function, size_t length, IDirect3DVertexShader9 *executable)
+ : ShaderExecutable(function, length)
+{
+ mVertexExecutable = executable;
+ mPixelExecutable = NULL;
+}
+
+ShaderExecutable9::~ShaderExecutable9()
+{
+ if (mVertexExecutable)
+ {
+ mVertexExecutable->Release();
+ }
+ if (mPixelExecutable)
+ {
+ mPixelExecutable->Release();
+ }
+}
+
+ShaderExecutable9 *ShaderExecutable9::makeShaderExecutable9(ShaderExecutable *executable)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(ShaderExecutable9*, executable));
+ return static_cast<ShaderExecutable9*>(executable);
+}
+
+IDirect3DVertexShader9 *ShaderExecutable9::getVertexShader() const
+{
+ return mVertexExecutable;
+}
+
+IDirect3DPixelShader9 *ShaderExecutable9::getPixelShader() const
+{
+ return mPixelExecutable;
+}
+
+} \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable9.h b/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable9.h
new file mode 100644
index 0000000000..fa1e6c2844
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/ShaderExecutable9.h
@@ -0,0 +1,39 @@
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// ShaderExecutable9.h: Defines a D3D9-specific class to contain shader
+// executable implementation details.
+
+#ifndef LIBGLESV2_RENDERER_SHADEREXECUTABLE9_H_
+#define LIBGLESV2_RENDERER_SHADEREXECUTABLE9_H_
+
+#include "libGLESv2/renderer/ShaderExecutable.h"
+
+namespace rx
+{
+
+class ShaderExecutable9 : public ShaderExecutable
+{
+ public:
+ ShaderExecutable9(const void *function, size_t length, IDirect3DPixelShader9 *executable);
+ ShaderExecutable9(const void *function, size_t length, IDirect3DVertexShader9 *executable);
+ virtual ~ShaderExecutable9();
+
+ static ShaderExecutable9 *makeShaderExecutable9(ShaderExecutable *executable);
+
+ IDirect3DPixelShader9 *getPixelShader() const;
+ IDirect3DVertexShader9 *getVertexShader() const;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(ShaderExecutable9);
+
+ IDirect3DPixelShader9 *mPixelExecutable;
+ IDirect3DVertexShader9 *mVertexExecutable;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_SHADEREXECUTABLE9_H_ \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain.h b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain.h
new file mode 100644
index 0000000000..14c0515fc8
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain.h
@@ -0,0 +1,44 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// SwapChain.h: Defines a back-end specific class that hides the details of the
+// implementation-specific swapchain.
+
+#ifndef LIBGLESV2_RENDERER_SWAPCHAIN_H_
+#define LIBGLESV2_RENDERER_SWAPCHAIN_H_
+
+#include "common/angleutils.h"
+
+namespace rx
+{
+
+class SwapChain
+{
+ public:
+ SwapChain(HWND window, HANDLE shareHandle, GLenum backBufferFormat, GLenum depthBufferFormat)
+ : mWindow(window), mShareHandle(shareHandle), mBackBufferFormat(backBufferFormat), mDepthBufferFormat(depthBufferFormat)
+ {
+ }
+
+ virtual ~SwapChain() {};
+
+ virtual EGLint resize(EGLint backbufferWidth, EGLint backbufferSize) = 0;
+ virtual EGLint reset(EGLint backbufferWidth, EGLint backbufferHeight, EGLint swapInterval) = 0;
+ virtual EGLint swapRect(EGLint x, EGLint y, EGLint width, EGLint height) = 0;
+ virtual void recreate() = 0;
+
+ virtual HANDLE getShareHandle() {return mShareHandle;};
+
+ protected:
+ const HWND mWindow; // Window that the surface is created for.
+ const GLenum mBackBufferFormat;
+ const GLenum mDepthBufferFormat;
+
+ HANDLE mShareHandle;
+};
+
+}
+#endif // LIBGLESV2_RENDERER_SWAPCHAIN_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.cpp
new file mode 100644
index 0000000000..98f887587c
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.cpp
@@ -0,0 +1,770 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// SwapChain11.cpp: Implements a back-end specific class for the D3D11 swap chain.
+
+#include "libGLESv2/renderer/SwapChain11.h"
+
+#include "libGLESv2/renderer/renderer11_utils.h"
+#include "libGLESv2/renderer/Renderer11.h"
+#include "libGLESv2/renderer/shaders/compiled/passthrough11vs.h"
+#include "libGLESv2/renderer/shaders/compiled/passthroughrgba11ps.h"
+
+namespace rx
+{
+
+SwapChain11::SwapChain11(Renderer11 *renderer, HWND window, HANDLE shareHandle,
+ GLenum backBufferFormat, GLenum depthBufferFormat)
+ : mRenderer(renderer), SwapChain(window, shareHandle, backBufferFormat, depthBufferFormat)
+{
+ mSwapChain = NULL;
+ mBackBufferTexture = NULL;
+ mBackBufferRTView = NULL;
+ mOffscreenTexture = NULL;
+ mOffscreenRTView = NULL;
+ mOffscreenSRView = NULL;
+ mDepthStencilTexture = NULL;
+ mDepthStencilDSView = NULL;
+ mQuadVB = NULL;
+ mPassThroughSampler = NULL;
+ mPassThroughIL = NULL;
+ mPassThroughVS = NULL;
+ mPassThroughPS = NULL;
+ mWidth = -1;
+ mHeight = -1;
+ mSwapInterval = 0;
+ mAppCreatedShareHandle = mShareHandle != NULL;
+ mPassThroughResourcesInit = false;
+}
+
+SwapChain11::~SwapChain11()
+{
+ release();
+}
+
+void SwapChain11::release()
+{
+ if (mSwapChain)
+ {
+ mSwapChain->Release();
+ mSwapChain = NULL;
+ }
+
+ if (mBackBufferTexture)
+ {
+ mBackBufferTexture->Release();
+ mBackBufferTexture = NULL;
+ }
+
+ if (mBackBufferRTView)
+ {
+ mBackBufferRTView->Release();
+ mBackBufferRTView = NULL;
+ }
+
+ if (mOffscreenTexture)
+ {
+ mOffscreenTexture->Release();
+ mOffscreenTexture = NULL;
+ }
+
+ if (mOffscreenRTView)
+ {
+ mOffscreenRTView->Release();
+ mOffscreenRTView = NULL;
+ }
+
+ if (mOffscreenSRView)
+ {
+ mOffscreenSRView->Release();
+ mOffscreenSRView = NULL;
+ }
+
+ if (mDepthStencilTexture)
+ {
+ mDepthStencilTexture->Release();
+ mDepthStencilTexture = NULL;
+ }
+
+ if (mDepthStencilDSView)
+ {
+ mDepthStencilDSView->Release();
+ mDepthStencilDSView = NULL;
+ }
+
+ if (mQuadVB)
+ {
+ mQuadVB->Release();
+ mQuadVB = NULL;
+ }
+
+ if (mPassThroughSampler)
+ {
+ mPassThroughSampler->Release();
+ mPassThroughSampler = NULL;
+ }
+
+ if (mPassThroughIL)
+ {
+ mPassThroughIL->Release();
+ mPassThroughIL = NULL;
+ }
+
+ if (mPassThroughVS)
+ {
+ mPassThroughVS->Release();
+ mPassThroughVS = NULL;
+ }
+
+ if (mPassThroughPS)
+ {
+ mPassThroughPS->Release();
+ mPassThroughPS = NULL;
+ }
+
+ if (!mAppCreatedShareHandle)
+ {
+ mShareHandle = NULL;
+ }
+}
+
+void SwapChain11::releaseOffscreenTexture()
+{
+ if (mOffscreenTexture)
+ {
+ mOffscreenTexture->Release();
+ mOffscreenTexture = NULL;
+ }
+
+ if (mOffscreenRTView)
+ {
+ mOffscreenRTView->Release();
+ mOffscreenRTView = NULL;
+ }
+
+ if (mOffscreenSRView)
+ {
+ mOffscreenSRView->Release();
+ mOffscreenSRView = NULL;
+ }
+
+ if (mDepthStencilTexture)
+ {
+ mDepthStencilTexture->Release();
+ mDepthStencilTexture = NULL;
+ }
+
+ if (mDepthStencilDSView)
+ {
+ mDepthStencilDSView->Release();
+ mDepthStencilDSView = NULL;
+ }
+}
+
+EGLint SwapChain11::resetOffscreenTexture(int backbufferWidth, int backbufferHeight)
+{
+ ID3D11Device *device = mRenderer->getDevice();
+
+ ASSERT(device != NULL);
+
+ // D3D11 does not allow zero size textures
+ ASSERT(backbufferWidth >= 1);
+ ASSERT(backbufferHeight >= 1);
+
+ // Preserve the render target content
+ ID3D11Texture2D *previousOffscreenTexture = mOffscreenTexture;
+ if (previousOffscreenTexture)
+ {
+ previousOffscreenTexture->AddRef();
+ }
+ const int previousWidth = mWidth;
+ const int previousHeight = mHeight;
+
+ releaseOffscreenTexture();
+
+ // If the app passed in a share handle, open the resource
+ // See EGL_ANGLE_d3d_share_handle_client_buffer
+ if (mAppCreatedShareHandle)
+ {
+ ID3D11Resource *tempResource11;
+ HRESULT result = device->OpenSharedResource(mShareHandle, __uuidof(ID3D11Resource), (void**)&tempResource11);
+
+ if (FAILED(result))
+ {
+ ERR("Failed to open the swap chain pbuffer share handle: %08lX", result);
+ release();
+ return EGL_BAD_PARAMETER;
+ }
+
+ result = tempResource11->QueryInterface(__uuidof(ID3D11Texture2D), (void**)&mOffscreenTexture);
+ tempResource11->Release();
+
+ if (FAILED(result))
+ {
+ ERR("Failed to query texture2d interface in pbuffer share handle: %08lX", result);
+ release();
+ return EGL_BAD_PARAMETER;
+ }
+
+ // Validate offscreen texture parameters
+ D3D11_TEXTURE2D_DESC offscreenTextureDesc = {0};
+ mOffscreenTexture->GetDesc(&offscreenTextureDesc);
+
+ if (offscreenTextureDesc.Width != (UINT)backbufferWidth
+ || offscreenTextureDesc.Height != (UINT)backbufferHeight
+ || offscreenTextureDesc.Format != gl_d3d11::ConvertRenderbufferFormat(mBackBufferFormat)
+ || offscreenTextureDesc.MipLevels != 1
+ || offscreenTextureDesc.ArraySize != 1)
+ {
+ ERR("Invalid texture parameters in the shared offscreen texture pbuffer");
+ release();
+ return EGL_BAD_PARAMETER;
+ }
+ }
+ else
+ {
+ const bool useSharedResource = !mWindow && mRenderer->getShareHandleSupport();
+
+ D3D11_TEXTURE2D_DESC offscreenTextureDesc = {0};
+ offscreenTextureDesc.Width = backbufferWidth;
+ offscreenTextureDesc.Height = backbufferHeight;
+ offscreenTextureDesc.Format = gl_d3d11::ConvertRenderbufferFormat(mBackBufferFormat);
+ offscreenTextureDesc.MipLevels = 1;
+ offscreenTextureDesc.ArraySize = 1;
+ offscreenTextureDesc.SampleDesc.Count = 1;
+ offscreenTextureDesc.SampleDesc.Quality = 0;
+ offscreenTextureDesc.Usage = D3D11_USAGE_DEFAULT;
+ offscreenTextureDesc.BindFlags = D3D11_BIND_RENDER_TARGET | D3D11_BIND_SHADER_RESOURCE;
+ offscreenTextureDesc.CPUAccessFlags = 0;
+ offscreenTextureDesc.MiscFlags = useSharedResource ? D3D11_RESOURCE_MISC_SHARED : 0;
+
+ HRESULT result = device->CreateTexture2D(&offscreenTextureDesc, NULL, &mOffscreenTexture);
+
+ if (FAILED(result))
+ {
+ ERR("Could not create offscreen texture: %08lX", result);
+ release();
+
+ if (d3d11::isDeviceLostError(result))
+ {
+ return EGL_CONTEXT_LOST;
+ }
+ else
+ {
+ return EGL_BAD_ALLOC;
+ }
+ }
+
+ d3d11::SetDebugName(mOffscreenTexture, "Offscreen texture");
+
+ // EGL_ANGLE_surface_d3d_texture_2d_share_handle requires that we store a share handle for the client
+ if (useSharedResource)
+ {
+ IDXGIResource *offscreenTextureResource = NULL;
+ result = mOffscreenTexture->QueryInterface(__uuidof(IDXGIResource), (void**)&offscreenTextureResource);
+
+ // Fall back to no share handle on failure
+ if (FAILED(result))
+ {
+ ERR("Could not query offscreen texture resource: %08lX", result);
+ }
+ else
+ {
+ result = offscreenTextureResource->GetSharedHandle(&mShareHandle);
+
+ if (FAILED(result))
+ {
+ mShareHandle = NULL;
+ ERR("Could not get offscreen texture shared handle: %08lX", result);
+ }
+ }
+ }
+ }
+
+ HRESULT result = device->CreateRenderTargetView(mOffscreenTexture, NULL, &mOffscreenRTView);
+
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mOffscreenRTView, "Offscreen render target");
+
+ result = device->CreateShaderResourceView(mOffscreenTexture, NULL, &mOffscreenSRView);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mOffscreenSRView, "Offscreen shader resource");
+
+ if (mDepthBufferFormat != GL_NONE)
+ {
+ D3D11_TEXTURE2D_DESC depthStencilDesc = {0};
+ depthStencilDesc.Width = backbufferWidth;
+ depthStencilDesc.Height = backbufferHeight;
+ depthStencilDesc.Format = gl_d3d11::ConvertRenderbufferFormat(mDepthBufferFormat);
+ depthStencilDesc.MipLevels = 1;
+ depthStencilDesc.ArraySize = 1;
+ depthStencilDesc.SampleDesc.Count = 1;
+ depthStencilDesc.SampleDesc.Quality = 0;
+ depthStencilDesc.Usage = D3D11_USAGE_DEFAULT;
+ depthStencilDesc.BindFlags = D3D11_BIND_DEPTH_STENCIL;
+ depthStencilDesc.CPUAccessFlags = 0;
+ depthStencilDesc.MiscFlags = 0;
+
+ result = device->CreateTexture2D(&depthStencilDesc, NULL, &mDepthStencilTexture);
+ if (FAILED(result))
+ {
+ ERR("Could not create depthstencil surface for new swap chain: 0x%08X", result);
+ release();
+
+ if (d3d11::isDeviceLostError(result))
+ {
+ return EGL_CONTEXT_LOST;
+ }
+ else
+ {
+ return EGL_BAD_ALLOC;
+ }
+ }
+ d3d11::SetDebugName(mDepthStencilTexture, "Depth stencil texture");
+
+ result = device->CreateDepthStencilView(mDepthStencilTexture, NULL, &mDepthStencilDSView);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mDepthStencilDSView, "Depth stencil view");
+ }
+
+ mWidth = backbufferWidth;
+ mHeight = backbufferHeight;
+
+ if (previousOffscreenTexture != NULL)
+ {
+ D3D11_BOX sourceBox = {0};
+ sourceBox.left = 0;
+ sourceBox.right = std::min(previousWidth, mWidth);
+ sourceBox.top = std::max(previousHeight - mHeight, 0);
+ sourceBox.bottom = previousHeight;
+ sourceBox.front = 0;
+ sourceBox.back = 1;
+
+ ID3D11DeviceContext *deviceContext = mRenderer->getDeviceContext();
+ const int yoffset = std::max(mHeight - previousHeight, 0);
+ deviceContext->CopySubresourceRegion(mOffscreenTexture, 0, 0, yoffset, 0, previousOffscreenTexture, 0, &sourceBox);
+
+ previousOffscreenTexture->Release();
+
+ if (mSwapChain)
+ {
+ swapRect(0, 0, mWidth, mHeight);
+ }
+ }
+
+ return EGL_SUCCESS;
+}
+
+EGLint SwapChain11::resize(EGLint backbufferWidth, EGLint backbufferHeight)
+{
+ ID3D11Device *device = mRenderer->getDevice();
+
+ if (device == NULL)
+ {
+ return EGL_BAD_ACCESS;
+ }
+
+ if (!mSwapChain)
+ reset(backbufferWidth, backbufferHeight, mSwapInterval);
+
+ // Can only call resize if we have already created our swap buffer and resources
+ ASSERT(mSwapChain && mBackBufferTexture && mBackBufferRTView);
+
+ if (mBackBufferTexture)
+ {
+ mBackBufferTexture->Release();
+ mBackBufferTexture = NULL;
+ }
+
+ if (mBackBufferRTView)
+ {
+ mBackBufferRTView->Release();
+ mBackBufferRTView = NULL;
+ }
+
+ // Resize swap chain
+ DXGI_FORMAT backbufferDXGIFormat = gl_d3d11::ConvertRenderbufferFormat(mBackBufferFormat);
+ HRESULT result = mSwapChain->ResizeBuffers(2, backbufferWidth, backbufferHeight, backbufferDXGIFormat, 0);
+
+ if (FAILED(result))
+ {
+ ERR("Error resizing swap chain buffers: 0x%08X", result);
+ release();
+
+ if (d3d11::isDeviceLostError(result))
+ {
+ return EGL_CONTEXT_LOST;
+ }
+ else
+ {
+ return EGL_BAD_ALLOC;
+ }
+ }
+
+ result = mSwapChain->GetBuffer(0, __uuidof(ID3D11Texture2D), (LPVOID*)&mBackBufferTexture);
+ ASSERT(SUCCEEDED(result));
+ if (SUCCEEDED(result))
+ {
+ d3d11::SetDebugName(mBackBufferTexture, "Back buffer texture");
+ }
+
+ result = device->CreateRenderTargetView(mBackBufferTexture, NULL, &mBackBufferRTView);
+ ASSERT(SUCCEEDED(result));
+ if (SUCCEEDED(result))
+ {
+ d3d11::SetDebugName(mBackBufferRTView, "Back buffer render target");
+ }
+
+ return resetOffscreenTexture(backbufferWidth, backbufferHeight);
+}
+
+EGLint SwapChain11::reset(int backbufferWidth, int backbufferHeight, EGLint swapInterval)
+{
+ ID3D11Device *device = mRenderer->getDevice();
+
+ if (device == NULL)
+ {
+ return EGL_BAD_ACCESS;
+ }
+
+ // Release specific resources to free up memory for the new render target, while the
+ // old render target still exists for the purpose of preserving its contents.
+ if (mSwapChain)
+ {
+ mSwapChain->Release();
+ mSwapChain = NULL;
+ }
+
+ if (mBackBufferTexture)
+ {
+ mBackBufferTexture->Release();
+ mBackBufferTexture = NULL;
+ }
+
+ if (mBackBufferRTView)
+ {
+ mBackBufferRTView->Release();
+ mBackBufferRTView = NULL;
+ }
+
+ mSwapInterval = static_cast<unsigned int>(swapInterval);
+ if (mSwapInterval > 4)
+ {
+ // IDXGISwapChain::Present documentation states that valid sync intervals are in the [0,4] range
+ return EGL_BAD_PARAMETER;
+ }
+
+ // EGL allows creating a surface with 0x0 dimension, however, DXGI does not like 0x0 swapchains
+ if (backbufferWidth < 1 || backbufferHeight < 1)
+ {
+ releaseOffscreenTexture();
+ return EGL_SUCCESS;
+ }
+
+ if (mWindow)
+ {
+ // We cannot create a swap chain for an HWND that is owned by a different process
+ DWORD currentProcessId = GetCurrentProcessId();
+ DWORD wndProcessId;
+ GetWindowThreadProcessId(mWindow, &wndProcessId);
+
+ if (currentProcessId != wndProcessId)
+ {
+ ERR("Could not create swap chain, window owned by different process");
+ release();
+ return EGL_BAD_NATIVE_WINDOW;
+ }
+
+ IDXGIFactory *factory = mRenderer->getDxgiFactory();
+
+ DXGI_SWAP_CHAIN_DESC swapChainDesc = {0};
+ swapChainDesc.BufferCount = 2;
+ swapChainDesc.BufferDesc.Format = gl_d3d11::ConvertRenderbufferFormat(mBackBufferFormat);
+ swapChainDesc.BufferDesc.Width = backbufferWidth;
+ swapChainDesc.BufferDesc.Height = backbufferHeight;
+ swapChainDesc.BufferDesc.Scaling = DXGI_MODE_SCALING_UNSPECIFIED;
+ swapChainDesc.BufferDesc.ScanlineOrdering = DXGI_MODE_SCANLINE_ORDER_UNSPECIFIED;
+ swapChainDesc.BufferDesc.RefreshRate.Numerator = 0;
+ swapChainDesc.BufferDesc.RefreshRate.Denominator = 1;
+ swapChainDesc.BufferUsage = DXGI_USAGE_RENDER_TARGET_OUTPUT;
+ swapChainDesc.Flags = 0;
+ swapChainDesc.OutputWindow = mWindow;
+ swapChainDesc.SampleDesc.Count = 1;
+ swapChainDesc.SampleDesc.Quality = 0;
+ swapChainDesc.Windowed = TRUE;
+
+ HRESULT result = factory->CreateSwapChain(device, &swapChainDesc, &mSwapChain);
+
+ if (FAILED(result))
+ {
+ ERR("Could not create additional swap chains or offscreen surfaces: %08lX", result);
+ release();
+
+ if (d3d11::isDeviceLostError(result))
+ {
+ return EGL_CONTEXT_LOST;
+ }
+ else
+ {
+ return EGL_BAD_ALLOC;
+ }
+ }
+
+ result = mSwapChain->GetBuffer(0, __uuidof(ID3D11Texture2D), (LPVOID*)&mBackBufferTexture);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mBackBufferTexture, "Back buffer texture");
+
+ result = device->CreateRenderTargetView(mBackBufferTexture, NULL, &mBackBufferRTView);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mBackBufferRTView, "Back buffer render target");
+ }
+
+ // If we are resizing the swap chain, we don't wish to recreate all the static resources
+ if (!mPassThroughResourcesInit)
+ {
+ mPassThroughResourcesInit = true;
+ initPassThroughResources();
+ }
+
+ return resetOffscreenTexture(backbufferWidth, backbufferHeight);
+}
+
+void SwapChain11::initPassThroughResources()
+{
+ ID3D11Device *device = mRenderer->getDevice();
+
+ ASSERT(device != NULL);
+
+ // Make sure our resources are all not allocated, when we create
+ ASSERT(mQuadVB == NULL && mPassThroughSampler == NULL);
+ ASSERT(mPassThroughIL == NULL && mPassThroughVS == NULL && mPassThroughPS == NULL);
+
+ D3D11_BUFFER_DESC vbDesc;
+ vbDesc.ByteWidth = sizeof(d3d11::PositionTexCoordVertex) * 4;
+ vbDesc.Usage = D3D11_USAGE_DYNAMIC;
+ vbDesc.BindFlags = D3D11_BIND_VERTEX_BUFFER;
+ vbDesc.CPUAccessFlags = D3D11_CPU_ACCESS_WRITE;
+ vbDesc.MiscFlags = 0;
+ vbDesc.StructureByteStride = 0;
+
+ HRESULT result = device->CreateBuffer(&vbDesc, NULL, &mQuadVB);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mQuadVB, "Swap chain quad vertex buffer");
+
+ D3D11_SAMPLER_DESC samplerDesc;
+ samplerDesc.Filter = D3D11_FILTER_MIN_MAG_MIP_POINT;
+ samplerDesc.AddressU = D3D11_TEXTURE_ADDRESS_CLAMP;
+ samplerDesc.AddressV = D3D11_TEXTURE_ADDRESS_CLAMP;
+ samplerDesc.AddressW = D3D11_TEXTURE_ADDRESS_CLAMP;
+ samplerDesc.MipLODBias = 0.0f;
+ samplerDesc.MaxAnisotropy = 0;
+ samplerDesc.ComparisonFunc = D3D11_COMPARISON_NEVER;
+ samplerDesc.BorderColor[0] = 0.0f;
+ samplerDesc.BorderColor[1] = 0.0f;
+ samplerDesc.BorderColor[2] = 0.0f;
+ samplerDesc.BorderColor[3] = 0.0f;
+ samplerDesc.MinLOD = 0;
+ samplerDesc.MaxLOD = D3D11_FLOAT32_MAX;
+
+ result = device->CreateSamplerState(&samplerDesc, &mPassThroughSampler);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mPassThroughSampler, "Swap chain pass through sampler");
+
+ D3D11_INPUT_ELEMENT_DESC quadLayout[] =
+ {
+ { "POSITION", 0, DXGI_FORMAT_R32G32_FLOAT, 0, 0, D3D11_INPUT_PER_VERTEX_DATA, 0 },
+ { "TEXCOORD", 0, DXGI_FORMAT_R32G32_FLOAT, 0, 8, D3D11_INPUT_PER_VERTEX_DATA, 0 },
+ };
+
+ result = device->CreateInputLayout(quadLayout, 2, g_VS_Passthrough, sizeof(g_VS_Passthrough), &mPassThroughIL);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mPassThroughIL, "Swap chain pass through layout");
+
+ result = device->CreateVertexShader(g_VS_Passthrough, sizeof(g_VS_Passthrough), NULL, &mPassThroughVS);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mPassThroughVS, "Swap chain pass through vertex shader");
+
+ result = device->CreatePixelShader(g_PS_PassthroughRGBA, sizeof(g_PS_PassthroughRGBA), NULL, &mPassThroughPS);
+ ASSERT(SUCCEEDED(result));
+ d3d11::SetDebugName(mPassThroughPS, "Swap chain pass through pixel shader");
+}
+
+// parameters should be validated/clamped by caller
+EGLint SwapChain11::swapRect(EGLint x, EGLint y, EGLint width, EGLint height)
+{
+ if (!mSwapChain)
+ {
+ return EGL_SUCCESS;
+ }
+
+ ID3D11Device *device = mRenderer->getDevice();
+ ID3D11DeviceContext *deviceContext = mRenderer->getDeviceContext();
+
+ // Set vertices
+ D3D11_MAPPED_SUBRESOURCE mappedResource;
+ HRESULT result = deviceContext->Map(mQuadVB, 0, D3D11_MAP_WRITE_DISCARD, 0, &mappedResource);
+ if (FAILED(result))
+ {
+ return EGL_BAD_ACCESS;
+ }
+
+ d3d11::PositionTexCoordVertex *vertices = static_cast<d3d11::PositionTexCoordVertex*>(mappedResource.pData);
+
+ // Create a quad in homogeneous coordinates
+ float x1 = (x / float(mWidth)) * 2.0f - 1.0f;
+ float y1 = (y / float(mHeight)) * 2.0f - 1.0f;
+ float x2 = ((x + width) / float(mWidth)) * 2.0f - 1.0f;
+ float y2 = ((y + height) / float(mHeight)) * 2.0f - 1.0f;
+
+ float u1 = x / float(mWidth);
+ float v1 = y / float(mHeight);
+ float u2 = (x + width) / float(mWidth);
+ float v2 = (y + height) / float(mHeight);
+
+ d3d11::SetPositionTexCoordVertex(&vertices[0], x1, y1, u1, v1);
+ d3d11::SetPositionTexCoordVertex(&vertices[1], x1, y2, u1, v2);
+ d3d11::SetPositionTexCoordVertex(&vertices[2], x2, y1, u2, v1);
+ d3d11::SetPositionTexCoordVertex(&vertices[3], x2, y2, u2, v2);
+
+ deviceContext->Unmap(mQuadVB, 0);
+
+ static UINT stride = sizeof(d3d11::PositionTexCoordVertex);
+ static UINT startIdx = 0;
+ deviceContext->IASetVertexBuffers(0, 1, &mQuadVB, &stride, &startIdx);
+
+ // Apply state
+ deviceContext->OMSetDepthStencilState(NULL, 0xFFFFFFFF);
+
+ static const float blendFactor[4] = { 1.0f, 1.0f, 1.0f, 1.0f };
+ deviceContext->OMSetBlendState(NULL, blendFactor, 0xFFFFFFF);
+
+ deviceContext->RSSetState(NULL);
+
+ // Apply shaders
+ deviceContext->IASetInputLayout(mPassThroughIL);
+ deviceContext->IASetPrimitiveTopology(D3D_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP);
+ deviceContext->VSSetShader(mPassThroughVS, NULL, 0);
+ deviceContext->PSSetShader(mPassThroughPS, NULL, 0);
+ deviceContext->GSSetShader(NULL, NULL, 0);
+
+ // Apply render targets
+ mRenderer->setOneTimeRenderTarget(mBackBufferRTView);
+
+ // Set the viewport
+ D3D11_VIEWPORT viewport;
+ viewport.TopLeftX = 0;
+ viewport.TopLeftY = 0;
+ viewport.Width = mWidth;
+ viewport.Height = mHeight;
+ viewport.MinDepth = 0.0f;
+ viewport.MaxDepth = 1.0f;
+ deviceContext->RSSetViewports(1, &viewport);
+
+ // Apply textures
+ deviceContext->PSSetShaderResources(0, 1, &mOffscreenSRView);
+ deviceContext->PSSetSamplers(0, 1, &mPassThroughSampler);
+
+ // Draw
+ deviceContext->Draw(4, 0);
+ result = mSwapChain->Present(mSwapInterval, 0);
+
+ if (result == DXGI_ERROR_DEVICE_REMOVED)
+ {
+ HRESULT removedReason = device->GetDeviceRemovedReason();
+ ERR("Present failed: the D3D11 device was removed: 0x%08X", removedReason);
+ return EGL_CONTEXT_LOST;
+ }
+ else if (result == DXGI_ERROR_DEVICE_RESET)
+ {
+ ERR("Present failed: the D3D11 device was reset from a bad command.");
+ return EGL_CONTEXT_LOST;
+ }
+ else if (FAILED(result))
+ {
+ ERR("Present failed with error code 0x%08X", result);
+ }
+
+ // Unbind
+ static ID3D11ShaderResourceView *const nullSRV = NULL;
+ deviceContext->PSSetShaderResources(0, 1, &nullSRV);
+
+ mRenderer->unapplyRenderTargets();
+ mRenderer->markAllStateDirty();
+
+ return EGL_SUCCESS;
+}
+
+// Increments refcount on texture.
+// caller must Release() the returned texture
+ID3D11Texture2D *SwapChain11::getOffscreenTexture()
+{
+ if (mOffscreenTexture)
+ {
+ mOffscreenTexture->AddRef();
+ }
+
+ return mOffscreenTexture;
+}
+
+// Increments refcount on view.
+// caller must Release() the returned view
+ID3D11RenderTargetView *SwapChain11::getRenderTarget()
+{
+ if (mOffscreenRTView)
+ {
+ mOffscreenRTView->AddRef();
+ }
+
+ return mOffscreenRTView;
+}
+
+// Increments refcount on view.
+// caller must Release() the returned view
+ID3D11ShaderResourceView *SwapChain11::getRenderTargetShaderResource()
+{
+ if (mOffscreenSRView)
+ {
+ mOffscreenSRView->AddRef();
+ }
+
+ return mOffscreenSRView;
+}
+
+// Increments refcount on view.
+// caller must Release() the returned view
+ID3D11DepthStencilView *SwapChain11::getDepthStencil()
+{
+ if (mDepthStencilDSView)
+ {
+ mDepthStencilDSView->AddRef();
+ }
+
+ return mDepthStencilDSView;
+}
+
+ID3D11Texture2D *SwapChain11::getDepthStencilTexture()
+{
+ if (mDepthStencilTexture)
+ {
+ mDepthStencilTexture->AddRef();
+ }
+
+ return mDepthStencilTexture;
+}
+
+SwapChain11 *SwapChain11::makeSwapChain11(SwapChain *swapChain)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(rx::SwapChain11*, swapChain));
+ return static_cast<rx::SwapChain11*>(swapChain);
+}
+
+void SwapChain11::recreate()
+{
+ // possibly should use this method instead of reset
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.h b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.h
new file mode 100644
index 0000000000..800104602e
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.h
@@ -0,0 +1,78 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// SwapChain11.h: Defines a back-end specific class for the D3D11 swap chain.
+
+#ifndef LIBGLESV2_RENDERER_SWAPCHAIN11_H_
+#define LIBGLESV2_RENDERER_SWAPCHAIN11_H_
+
+#include "common/angleutils.h"
+#include "libGLESv2/renderer/SwapChain.h"
+
+namespace rx
+{
+class Renderer11;
+
+class SwapChain11 : public SwapChain
+{
+ public:
+ SwapChain11(Renderer11 *renderer, HWND window, HANDLE shareHandle,
+ GLenum backBufferFormat, GLenum depthBufferFormat);
+ virtual ~SwapChain11();
+
+ EGLint resize(EGLint backbufferWidth, EGLint backbufferHeight);
+ virtual EGLint reset(EGLint backbufferWidth, EGLint backbufferHeight, EGLint swapInterval);
+ virtual EGLint swapRect(EGLint x, EGLint y, EGLint width, EGLint height);
+ virtual void recreate();
+
+ virtual ID3D11Texture2D *getOffscreenTexture();
+ virtual ID3D11RenderTargetView *getRenderTarget();
+ virtual ID3D11ShaderResourceView *getRenderTargetShaderResource();
+
+ virtual ID3D11Texture2D *getDepthStencilTexture();
+ virtual ID3D11DepthStencilView *getDepthStencil();
+
+ EGLint getWidth() const { return mWidth; }
+ EGLint getHeight() const { return mHeight; }
+
+ static SwapChain11 *makeSwapChain11(SwapChain *swapChain);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(SwapChain11);
+
+ void release();
+ void initPassThroughResources();
+ void releaseOffscreenTexture();
+ EGLint resetOffscreenTexture(int backbufferWidth, int backbufferHeight);
+
+ Renderer11 *mRenderer;
+ EGLint mHeight;
+ EGLint mWidth;
+ bool mAppCreatedShareHandle;
+ unsigned int mSwapInterval;
+ bool mPassThroughResourcesInit;
+
+ IDXGISwapChain *mSwapChain;
+
+ ID3D11Texture2D *mBackBufferTexture;
+ ID3D11RenderTargetView *mBackBufferRTView;
+
+ ID3D11Texture2D *mOffscreenTexture;
+ ID3D11RenderTargetView *mOffscreenRTView;
+ ID3D11ShaderResourceView *mOffscreenSRView;
+
+ ID3D11Texture2D *mDepthStencilTexture;
+ ID3D11DepthStencilView *mDepthStencilDSView;
+
+ ID3D11Buffer *mQuadVB;
+ ID3D11SamplerState *mPassThroughSampler;
+ ID3D11InputLayout *mPassThroughIL;
+ ID3D11VertexShader *mPassThroughVS;
+ ID3D11PixelShader *mPassThroughPS;
+};
+
+}
+#endif // LIBGLESV2_RENDERER_SWAPCHAIN11_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.cpp
new file mode 100644
index 0000000000..f57a874688
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.cpp
@@ -0,0 +1,449 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012-2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// SwapChain9.cpp: Implements a back-end specific class for the D3D9 swap chain.
+
+#include "libGLESv2/renderer/SwapChain9.h"
+#include "libGLESv2/renderer/renderer9_utils.h"
+#include "libGLESv2/renderer/Renderer9.h"
+
+namespace rx
+{
+
+SwapChain9::SwapChain9(Renderer9 *renderer, HWND window, HANDLE shareHandle,
+ GLenum backBufferFormat, GLenum depthBufferFormat)
+ : mRenderer(renderer), SwapChain(window, shareHandle, backBufferFormat, depthBufferFormat)
+{
+ mSwapChain = NULL;
+ mBackBuffer = NULL;
+ mDepthStencil = NULL;
+ mRenderTarget = NULL;
+ mOffscreenTexture = NULL;
+ mWidth = -1;
+ mHeight = -1;
+ mSwapInterval = -1;
+}
+
+SwapChain9::~SwapChain9()
+{
+ release();
+}
+
+void SwapChain9::release()
+{
+ if (mSwapChain)
+ {
+ mSwapChain->Release();
+ mSwapChain = NULL;
+ }
+
+ if (mBackBuffer)
+ {
+ mBackBuffer->Release();
+ mBackBuffer = NULL;
+ }
+
+ if (mDepthStencil)
+ {
+ mDepthStencil->Release();
+ mDepthStencil = NULL;
+ }
+
+ if (mRenderTarget)
+ {
+ mRenderTarget->Release();
+ mRenderTarget = NULL;
+ }
+
+ if (mOffscreenTexture)
+ {
+ mOffscreenTexture->Release();
+ mOffscreenTexture = NULL;
+ }
+
+ if (mWindow)
+ mShareHandle = NULL;
+}
+
+static DWORD convertInterval(EGLint interval)
+{
+ switch(interval)
+ {
+ case 0: return D3DPRESENT_INTERVAL_IMMEDIATE;
+ case 1: return D3DPRESENT_INTERVAL_ONE;
+ case 2: return D3DPRESENT_INTERVAL_TWO;
+ case 3: return D3DPRESENT_INTERVAL_THREE;
+ case 4: return D3DPRESENT_INTERVAL_FOUR;
+ default: UNREACHABLE();
+ }
+
+ return D3DPRESENT_INTERVAL_DEFAULT;
+}
+
+EGLint SwapChain9::resize(int backbufferWidth, int backbufferHeight)
+{
+ // D3D9 does not support resizing swap chains without recreating them
+ return reset(backbufferWidth, backbufferHeight, mSwapInterval);
+}
+
+EGLint SwapChain9::reset(int backbufferWidth, int backbufferHeight, EGLint swapInterval)
+{
+ IDirect3DDevice9 *device = mRenderer->getDevice();
+
+ if (device == NULL)
+ {
+ return EGL_BAD_ACCESS;
+ }
+
+ // Evict all non-render target textures to system memory and release all resources
+ // before reallocating them to free up as much video memory as possible.
+ device->EvictManagedResources();
+
+ HRESULT result;
+
+ // Release specific resources to free up memory for the new render target, while the
+ // old render target still exists for the purpose of preserving its contents.
+ if (mSwapChain)
+ {
+ mSwapChain->Release();
+ mSwapChain = NULL;
+ }
+
+ if (mBackBuffer)
+ {
+ mBackBuffer->Release();
+ mBackBuffer = NULL;
+ }
+
+ if (mOffscreenTexture)
+ {
+ mOffscreenTexture->Release();
+ mOffscreenTexture = NULL;
+ }
+
+ if (mDepthStencil)
+ {
+ mDepthStencil->Release();
+ mDepthStencil = NULL;
+ }
+
+ HANDLE *pShareHandle = NULL;
+ if (!mWindow && mRenderer->getShareHandleSupport())
+ {
+ pShareHandle = &mShareHandle;
+ }
+
+ // CreateTexture will fail on zero dimensions, so just release old target
+ if (!backbufferWidth || !backbufferHeight)
+ {
+ if (mRenderTarget)
+ {
+ mRenderTarget->Release();
+ mRenderTarget = NULL;
+ }
+
+ mWidth = backbufferWidth;
+ mHeight = backbufferHeight;
+
+ return EGL_SUCCESS;
+ }
+
+ result = device->CreateTexture(backbufferWidth, backbufferHeight, 1, D3DUSAGE_RENDERTARGET,
+ gl_d3d9::ConvertRenderbufferFormat(mBackBufferFormat), D3DPOOL_DEFAULT,
+ &mOffscreenTexture, pShareHandle);
+ if (FAILED(result))
+ {
+ ERR("Could not create offscreen texture: %08lX", result);
+ release();
+
+ if (d3d9::isDeviceLostError(result))
+ {
+ return EGL_CONTEXT_LOST;
+ }
+ else
+ {
+ return EGL_BAD_ALLOC;
+ }
+ }
+
+ IDirect3DSurface9 *oldRenderTarget = mRenderTarget;
+
+ result = mOffscreenTexture->GetSurfaceLevel(0, &mRenderTarget);
+ ASSERT(SUCCEEDED(result));
+
+ if (oldRenderTarget)
+ {
+ RECT rect =
+ {
+ 0, 0,
+ mWidth, mHeight
+ };
+
+ if (rect.right > static_cast<LONG>(backbufferWidth))
+ {
+ rect.right = backbufferWidth;
+ }
+
+ if (rect.bottom > static_cast<LONG>(backbufferHeight))
+ {
+ rect.bottom = backbufferHeight;
+ }
+
+ mRenderer->endScene();
+
+ result = device->StretchRect(oldRenderTarget, &rect, mRenderTarget, &rect, D3DTEXF_NONE);
+ ASSERT(SUCCEEDED(result));
+
+ oldRenderTarget->Release();
+ }
+
+ if (mWindow)
+ {
+ D3DPRESENT_PARAMETERS presentParameters = {0};
+ presentParameters.AutoDepthStencilFormat = gl_d3d9::ConvertRenderbufferFormat(mDepthBufferFormat);
+ presentParameters.BackBufferCount = 1;
+ presentParameters.BackBufferFormat = gl_d3d9::ConvertRenderbufferFormat(mBackBufferFormat);
+ presentParameters.EnableAutoDepthStencil = FALSE;
+ presentParameters.Flags = 0;
+ presentParameters.hDeviceWindow = mWindow;
+ presentParameters.MultiSampleQuality = 0; // FIXME: Unimplemented
+ presentParameters.MultiSampleType = D3DMULTISAMPLE_NONE; // FIXME: Unimplemented
+ presentParameters.PresentationInterval = convertInterval(swapInterval);
+ presentParameters.SwapEffect = D3DSWAPEFFECT_DISCARD;
+ presentParameters.Windowed = TRUE;
+ presentParameters.BackBufferWidth = backbufferWidth;
+ presentParameters.BackBufferHeight = backbufferHeight;
+
+ // http://crbug.com/140239
+ // http://crbug.com/143434
+ //
+ // Some AMD/Intel switchable systems / drivers appear to round swap chain surfaces to a multiple of 64 pixels in width
+ // when using the integrated Intel. This rounds the width up rather than down.
+ //
+ // Some non-switchable AMD GPUs / drivers do not respect the source rectangle to Present. Therefore, when the vendor ID
+ // is not Intel, the back buffer width must be exactly the same width as the window or horizontal scaling will occur.
+ if (mRenderer->getAdapterVendor() == VENDOR_ID_INTEL)
+ {
+ presentParameters.BackBufferWidth = (presentParameters.BackBufferWidth + 63) / 64 * 64;
+ }
+
+ result = device->CreateAdditionalSwapChain(&presentParameters, &mSwapChain);
+
+ if (FAILED(result))
+ {
+ ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY || result == D3DERR_INVALIDCALL || result == D3DERR_DEVICELOST);
+
+ ERR("Could not create additional swap chains or offscreen surfaces: %08lX", result);
+ release();
+
+ if (d3d9::isDeviceLostError(result))
+ {
+ return EGL_CONTEXT_LOST;
+ }
+ else
+ {
+ return EGL_BAD_ALLOC;
+ }
+ }
+
+ result = mSwapChain->GetBackBuffer(0, D3DBACKBUFFER_TYPE_MONO, &mBackBuffer);
+ ASSERT(SUCCEEDED(result));
+ InvalidateRect(mWindow, NULL, FALSE);
+ }
+
+ if (mDepthBufferFormat != GL_NONE)
+ {
+ result = device->CreateDepthStencilSurface(backbufferWidth, backbufferHeight,
+ gl_d3d9::ConvertRenderbufferFormat(mDepthBufferFormat),
+ D3DMULTISAMPLE_NONE, 0, FALSE, &mDepthStencil, NULL);
+
+ if (FAILED(result))
+ {
+ ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY || result == D3DERR_INVALIDCALL);
+
+ ERR("Could not create depthstencil surface for new swap chain: 0x%08X", result);
+ release();
+
+ if (d3d9::isDeviceLostError(result))
+ {
+ return EGL_CONTEXT_LOST;
+ }
+ else
+ {
+ return EGL_BAD_ALLOC;
+ }
+ }
+ }
+
+ mWidth = backbufferWidth;
+ mHeight = backbufferHeight;
+ mSwapInterval = swapInterval;
+
+ return EGL_SUCCESS;
+}
+
+// parameters should be validated/clamped by caller
+EGLint SwapChain9::swapRect(EGLint x, EGLint y, EGLint width, EGLint height)
+{
+ if (!mSwapChain)
+ {
+ return EGL_SUCCESS;
+ }
+
+ IDirect3DDevice9 *device = mRenderer->getDevice();
+
+ // Disable all pipeline operations
+ device->SetRenderState(D3DRS_ZENABLE, D3DZB_FALSE);
+ device->SetRenderState(D3DRS_FILLMODE, D3DFILL_SOLID);
+ device->SetRenderState(D3DRS_ALPHATESTENABLE, FALSE);
+ device->SetRenderState(D3DRS_ALPHABLENDENABLE, FALSE);
+ device->SetRenderState(D3DRS_CULLMODE, D3DCULL_NONE);
+ device->SetRenderState(D3DRS_STENCILENABLE, FALSE);
+ device->SetRenderState(D3DRS_CLIPPLANEENABLE, 0);
+ device->SetRenderState(D3DRS_COLORWRITEENABLE, D3DCOLORWRITEENABLE_ALPHA | D3DCOLORWRITEENABLE_BLUE | D3DCOLORWRITEENABLE_GREEN | D3DCOLORWRITEENABLE_RED);
+ device->SetRenderState(D3DRS_SRGBWRITEENABLE, FALSE);
+ device->SetRenderState(D3DRS_SCISSORTESTENABLE, FALSE);
+ device->SetPixelShader(NULL);
+ device->SetVertexShader(NULL);
+
+ device->SetRenderTarget(0, mBackBuffer);
+ device->SetDepthStencilSurface(NULL);
+
+ device->SetTexture(0, mOffscreenTexture);
+ device->SetTextureStageState(0, D3DTSS_COLOROP, D3DTOP_SELECTARG1);
+ device->SetTextureStageState(0, D3DTSS_COLORARG1, D3DTA_TEXTURE);
+ device->SetTextureStageState(1, D3DTSS_COLOROP, D3DTOP_DISABLE);
+ device->SetSamplerState(0, D3DSAMP_MAGFILTER, D3DTEXF_POINT);
+ device->SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_POINT);
+ device->SetSamplerState(0, D3DSAMP_ADDRESSU, D3DTADDRESS_CLAMP);
+ device->SetSamplerState(0, D3DSAMP_ADDRESSV, D3DTADDRESS_CLAMP);
+ device->SetFVF(D3DFVF_XYZRHW | D3DFVF_TEX1);
+
+ D3DVIEWPORT9 viewport = {0, 0, mWidth, mHeight, 0.0f, 1.0f};
+ device->SetViewport(&viewport);
+
+ float x1 = x - 0.5f;
+ float y1 = (mHeight - y - height) - 0.5f;
+ float x2 = (x + width) - 0.5f;
+ float y2 = (mHeight - y) - 0.5f;
+
+ float u1 = x / float(mWidth);
+ float v1 = y / float(mHeight);
+ float u2 = (x + width) / float(mWidth);
+ float v2 = (y + height) / float(mHeight);
+
+ float quad[4][6] = {{x1, y1, 0.0f, 1.0f, u1, v2},
+ {x2, y1, 0.0f, 1.0f, u2, v2},
+ {x2, y2, 0.0f, 1.0f, u2, v1},
+ {x1, y2, 0.0f, 1.0f, u1, v1}}; // x, y, z, rhw, u, v
+
+ mRenderer->startScene();
+ device->DrawPrimitiveUP(D3DPT_TRIANGLEFAN, 2, quad, 6 * sizeof(float));
+ mRenderer->endScene();
+
+ device->SetTexture(0, NULL);
+
+ RECT rect =
+ {
+ x, mHeight - y - height,
+ x + width, mHeight - y
+ };
+
+ HRESULT result = mSwapChain->Present(&rect, &rect, NULL, NULL, 0);
+
+ mRenderer->markAllStateDirty();
+
+ if (d3d9::isDeviceLostError(result))
+ {
+ return EGL_CONTEXT_LOST;
+ }
+
+ if (result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY || result == D3DERR_DRIVERINTERNALERROR)
+ {
+ return EGL_BAD_ALLOC;
+ }
+
+ ASSERT(SUCCEEDED(result));
+
+ return EGL_SUCCESS;
+}
+
+// Increments refcount on surface.
+// caller must Release() the returned surface
+IDirect3DSurface9 *SwapChain9::getRenderTarget()
+{
+ if (mRenderTarget)
+ {
+ mRenderTarget->AddRef();
+ }
+
+ return mRenderTarget;
+}
+
+// Increments refcount on surface.
+// caller must Release() the returned surface
+IDirect3DSurface9 *SwapChain9::getDepthStencil()
+{
+ if (mDepthStencil)
+ {
+ mDepthStencil->AddRef();
+ }
+
+ return mDepthStencil;
+}
+
+// Increments refcount on texture.
+// caller must Release() the returned texture
+IDirect3DTexture9 *SwapChain9::getOffscreenTexture()
+{
+ if (mOffscreenTexture)
+ {
+ mOffscreenTexture->AddRef();
+ }
+
+ return mOffscreenTexture;
+}
+
+SwapChain9 *SwapChain9::makeSwapChain9(SwapChain *swapChain)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(rx::SwapChain9*, swapChain));
+ return static_cast<rx::SwapChain9*>(swapChain);
+}
+
+void SwapChain9::recreate()
+{
+ if (!mSwapChain)
+ {
+ return;
+ }
+
+ IDirect3DDevice9 *device = mRenderer->getDevice();
+ if (device == NULL)
+ {
+ return;
+ }
+
+ D3DPRESENT_PARAMETERS presentParameters;
+ HRESULT result = mSwapChain->GetPresentParameters(&presentParameters);
+ ASSERT(SUCCEEDED(result));
+
+ IDirect3DSwapChain9* newSwapChain = NULL;
+ result = device->CreateAdditionalSwapChain(&presentParameters, &newSwapChain);
+ if (FAILED(result))
+ {
+ return;
+ }
+
+ mSwapChain->Release();
+ mSwapChain = newSwapChain;
+
+ mBackBuffer->Release();
+ result = mSwapChain->GetBackBuffer(0, D3DBACKBUFFER_TYPE_MONO, &mBackBuffer);
+ ASSERT(SUCCEEDED(result));
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.h b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.h
new file mode 100644
index 0000000000..16a62bd86f
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.h
@@ -0,0 +1,55 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// SwapChain9.h: Defines a back-end specific class for the D3D9 swap chain.
+
+#ifndef LIBGLESV2_RENDERER_SWAPCHAIN9_H_
+#define LIBGLESV2_RENDERER_SWAPCHAIN9_H_
+
+#include "common/angleutils.h"
+#include "libGLESv2/renderer/SwapChain.h"
+
+namespace rx
+{
+class Renderer9;
+
+class SwapChain9 : public SwapChain
+{
+ public:
+ SwapChain9(Renderer9 *renderer, HWND window, HANDLE shareHandle,
+ GLenum backBufferFormat, GLenum depthBufferFormat);
+ virtual ~SwapChain9();
+
+ EGLint resize(EGLint backbufferWidth, EGLint backbufferHeight);
+ virtual EGLint reset(EGLint backbufferWidth, EGLint backbufferHeight, EGLint swapInterval);
+ virtual EGLint swapRect(EGLint x, EGLint y, EGLint width, EGLint height);
+ virtual void recreate();
+
+ virtual IDirect3DSurface9 *getRenderTarget();
+ virtual IDirect3DSurface9 *getDepthStencil();
+ virtual IDirect3DTexture9 *getOffscreenTexture();
+
+ static SwapChain9 *makeSwapChain9(SwapChain *swapChain);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(SwapChain9);
+
+ void release();
+
+ Renderer9 *mRenderer;
+ EGLint mHeight;
+ EGLint mWidth;
+ EGLint mSwapInterval;
+
+ IDirect3DSwapChain9 *mSwapChain;
+ IDirect3DSurface9 *mBackBuffer;
+ IDirect3DSurface9 *mRenderTarget;
+ IDirect3DSurface9 *mDepthStencil;
+ IDirect3DTexture9* mOffscreenTexture;
+};
+
+}
+#endif // LIBGLESV2_RENDERER_SWAPCHAIN9_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage.cpp
new file mode 100644
index 0000000000..00b316f1cc
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage.cpp
@@ -0,0 +1,122 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// TextureStorage.cpp: Implements the abstract rx::TextureStorageInterface class and its concrete derived
+// classes TextureStorageInterface2D and TextureStorageInterfaceCube, which act as the interface to the
+// GPU-side texture.
+
+#include "libGLESv2/renderer/TextureStorage.h"
+#include "libGLESv2/renderer/Renderer.h"
+#include "libGLESv2/Renderbuffer.h"
+#include "libGLESv2/Texture.h"
+
+#include "common/debug.h"
+
+namespace rx
+{
+unsigned int TextureStorageInterface::mCurrentTextureSerial = 1;
+
+TextureStorageInterface::TextureStorageInterface()
+ : mTextureSerial(issueTextureSerial()),
+ mInstance(NULL)
+{
+}
+
+TextureStorageInterface::~TextureStorageInterface()
+{
+ delete mInstance;
+}
+
+bool TextureStorageInterface::isRenderTarget() const
+{
+ return mInstance->isRenderTarget();
+}
+
+
+bool TextureStorageInterface::isManaged() const
+{
+ return mInstance->isManaged();
+}
+
+unsigned int TextureStorageInterface::getTextureSerial() const
+{
+ return mTextureSerial;
+}
+
+unsigned int TextureStorageInterface::issueTextureSerial()
+{
+ return mCurrentTextureSerial++;
+}
+
+int TextureStorageInterface::getLodOffset() const
+{
+ return mInstance->getLodOffset();
+}
+
+
+int TextureStorageInterface::levelCount()
+{
+ return mInstance->levelCount();
+}
+
+TextureStorageInterface2D::TextureStorageInterface2D(Renderer *renderer, SwapChain *swapchain)
+ : mRenderTargetSerial(gl::RenderbufferStorage::issueSerial())
+{
+ mInstance = renderer->createTextureStorage2D(swapchain);
+}
+
+TextureStorageInterface2D::TextureStorageInterface2D(Renderer *renderer, int levels, GLenum internalformat, GLenum usage, bool forceRenderable, GLsizei width, GLsizei height)
+ : mRenderTargetSerial(gl::RenderbufferStorage::issueSerial())
+{
+ mInstance = renderer->createTextureStorage2D(levels, internalformat, usage, forceRenderable, width, height);
+}
+
+TextureStorageInterface2D::~TextureStorageInterface2D()
+{
+}
+
+RenderTarget *TextureStorageInterface2D::getRenderTarget() const
+{
+ return mInstance->getRenderTarget();
+}
+
+void TextureStorageInterface2D::generateMipmap(int level)
+{
+ mInstance->generateMipmap(level);
+}
+
+unsigned int TextureStorageInterface2D::getRenderTargetSerial(GLenum target) const
+{
+ return mRenderTargetSerial;
+}
+
+TextureStorageInterfaceCube::TextureStorageInterfaceCube(Renderer *renderer, int levels, GLenum internalformat, GLenum usage, bool forceRenderable, int size)
+ : mFirstRenderTargetSerial(gl::RenderbufferStorage::issueCubeSerials())
+{
+ mInstance = renderer->createTextureStorageCube(levels, internalformat, usage, forceRenderable, size);
+}
+
+TextureStorageInterfaceCube::~TextureStorageInterfaceCube()
+{
+}
+
+RenderTarget *TextureStorageInterfaceCube::getRenderTarget(GLenum faceTarget) const
+{
+ return mInstance->getRenderTarget(faceTarget);
+}
+
+void TextureStorageInterfaceCube::generateMipmap(int face, int level)
+{
+ mInstance->generateMipmap(face, level);
+}
+
+unsigned int TextureStorageInterfaceCube::getRenderTargetSerial(GLenum target) const
+{
+ return mFirstRenderTargetSerial + gl::TextureCubeMap::faceIndex(target);
+}
+
+} \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage.h b/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage.h
new file mode 100644
index 0000000000..edddb75f3f
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage.h
@@ -0,0 +1,110 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// TextureStorage.h: Defines the abstract rx::TextureStorageInterface class and its concrete derived
+// classes TextureStorageInterface2D and TextureStorageInterfaceCube, which act as the interface to the
+// GPU-side texture.
+
+#ifndef LIBGLESV2_RENDERER_TEXTURESTORAGE_H_
+#define LIBGLESV2_RENDERER_TEXTURESTORAGE_H_
+
+#include "common/debug.h"
+
+namespace rx
+{
+class Renderer;
+class SwapChain;
+class RenderTarget;
+class Blit;
+
+class TextureStorage
+{
+ public:
+ TextureStorage() {};
+ virtual ~TextureStorage() {};
+
+ virtual int getLodOffset() const = 0;
+ virtual bool isRenderTarget() const = 0;
+ virtual bool isManaged() const = 0;
+ virtual int levelCount() = 0;
+
+ virtual RenderTarget *getRenderTarget() = 0;
+ virtual RenderTarget *getRenderTarget(GLenum faceTarget) = 0;
+ virtual void generateMipmap(int level) = 0;
+ virtual void generateMipmap(int face, int level) = 0;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(TextureStorage);
+
+};
+
+class TextureStorageInterface
+{
+ public:
+ TextureStorageInterface();
+ virtual ~TextureStorageInterface();
+
+ TextureStorage *getStorageInstance() { return mInstance; }
+
+ unsigned int getTextureSerial() const;
+ virtual unsigned int getRenderTargetSerial(GLenum target) const = 0;
+
+ virtual int getLodOffset() const;
+ virtual bool isRenderTarget() const;
+ virtual bool isManaged() const;
+ virtual int levelCount();
+
+ protected:
+ TextureStorage *mInstance;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(TextureStorageInterface);
+
+ const unsigned int mTextureSerial;
+ static unsigned int issueTextureSerial();
+
+ static unsigned int mCurrentTextureSerial;
+};
+
+class TextureStorageInterface2D : public TextureStorageInterface
+{
+ public:
+ TextureStorageInterface2D(Renderer *renderer, SwapChain *swapchain);
+ TextureStorageInterface2D(Renderer *renderer, int levels, GLenum internalformat, GLenum usage, bool forceRenderable, GLsizei width, GLsizei height);
+ virtual ~TextureStorageInterface2D();
+
+ void generateMipmap(int level);
+ RenderTarget *getRenderTarget() const;
+
+ virtual unsigned int getRenderTargetSerial(GLenum target) const;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(TextureStorageInterface2D);
+
+ const unsigned int mRenderTargetSerial;
+};
+
+class TextureStorageInterfaceCube : public TextureStorageInterface
+{
+ public:
+ TextureStorageInterfaceCube(Renderer *renderer, int levels, GLenum internalformat, GLenum usage, bool forceRenderable, int size);
+ virtual ~TextureStorageInterfaceCube();
+
+ void generateMipmap(int face, int level);
+ RenderTarget *getRenderTarget(GLenum faceTarget) const;
+
+ virtual unsigned int getRenderTargetSerial(GLenum target) const;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(TextureStorageInterfaceCube);
+
+ const unsigned int mFirstRenderTargetSerial;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_TEXTURESTORAGE_H_
+
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage11.cpp
new file mode 100644
index 0000000000..667dbff175
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage11.cpp
@@ -0,0 +1,676 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// TextureStorage11.cpp: Implements the abstract rx::TextureStorage11 class and its concrete derived
+// classes TextureStorage11_2D and TextureStorage11_Cube, which act as the interface to the D3D11 texture.
+
+#include "libGLESv2/renderer/TextureStorage11.h"
+
+#include "libGLESv2/renderer/Renderer11.h"
+#include "libGLESv2/renderer/RenderTarget11.h"
+#include "libGLESv2/renderer/SwapChain11.h"
+#include "libGLESv2/renderer/renderer11_utils.h"
+
+#include "libGLESv2/utilities.h"
+#include "libGLESv2/main.h"
+
+namespace rx
+{
+
+TextureStorage11::TextureStorage11(Renderer *renderer, UINT bindFlags)
+ : mBindFlags(bindFlags),
+ mLodOffset(0),
+ mMipLevels(0),
+ mTexture(NULL),
+ mTextureFormat(DXGI_FORMAT_UNKNOWN),
+ mShaderResourceFormat(DXGI_FORMAT_UNKNOWN),
+ mRenderTargetFormat(DXGI_FORMAT_UNKNOWN),
+ mDepthStencilFormat(DXGI_FORMAT_UNKNOWN),
+ mSRV(NULL),
+ mTextureWidth(0),
+ mTextureHeight(0)
+{
+ mRenderer = Renderer11::makeRenderer11(renderer);
+}
+
+TextureStorage11::~TextureStorage11()
+{
+}
+
+TextureStorage11 *TextureStorage11::makeTextureStorage11(TextureStorage *storage)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(TextureStorage11*, storage));
+ return static_cast<TextureStorage11*>(storage);
+}
+
+DWORD TextureStorage11::GetTextureBindFlags(DXGI_FORMAT format, GLenum glusage, bool forceRenderable)
+{
+ UINT bindFlags = D3D11_BIND_SHADER_RESOURCE;
+
+ if (d3d11::IsDepthStencilFormat(format))
+ {
+ bindFlags |= D3D11_BIND_DEPTH_STENCIL;
+ }
+ else if(forceRenderable || (TextureStorage11::IsTextureFormatRenderable(format) && (glusage == GL_FRAMEBUFFER_ATTACHMENT_ANGLE)))
+ {
+ bindFlags |= D3D11_BIND_RENDER_TARGET;
+ }
+ return bindFlags;
+}
+
+bool TextureStorage11::IsTextureFormatRenderable(DXGI_FORMAT format)
+{
+ switch(format)
+ {
+ case DXGI_FORMAT_R8G8B8A8_UNORM:
+ case DXGI_FORMAT_A8_UNORM:
+ case DXGI_FORMAT_R32G32B32A32_FLOAT:
+ case DXGI_FORMAT_R32G32B32_FLOAT:
+ case DXGI_FORMAT_R16G16B16A16_FLOAT:
+ case DXGI_FORMAT_B8G8R8A8_UNORM:
+ case DXGI_FORMAT_R8_UNORM:
+ case DXGI_FORMAT_R8G8_UNORM:
+ case DXGI_FORMAT_R16_FLOAT:
+ case DXGI_FORMAT_R16G16_FLOAT:
+ return true;
+ case DXGI_FORMAT_BC1_UNORM:
+ case DXGI_FORMAT_BC2_UNORM:
+ case DXGI_FORMAT_BC3_UNORM:
+ return false;
+ default:
+ UNREACHABLE();
+ return false;
+ }
+}
+
+UINT TextureStorage11::getBindFlags() const
+{
+ return mBindFlags;
+}
+
+ID3D11Texture2D *TextureStorage11::getBaseTexture() const
+{
+ return mTexture;
+}
+
+int TextureStorage11::getLodOffset() const
+{
+ return mLodOffset;
+}
+
+bool TextureStorage11::isRenderTarget() const
+{
+ return (mBindFlags & (D3D11_BIND_RENDER_TARGET | D3D11_BIND_DEPTH_STENCIL)) != 0;
+}
+
+bool TextureStorage11::isManaged() const
+{
+ return false;
+}
+
+int TextureStorage11::levelCount()
+{
+ int levels = 0;
+ if (getBaseTexture())
+ {
+ levels = mMipLevels - getLodOffset();
+ }
+ return levels;
+}
+
+UINT TextureStorage11::getSubresourceIndex(int level, int faceIndex)
+{
+ UINT index = 0;
+ if (getBaseTexture())
+ {
+ index = D3D11CalcSubresource(level, faceIndex, mMipLevels);
+ }
+ return index;
+}
+
+bool TextureStorage11::updateSubresourceLevel(ID3D11Texture2D *srcTexture, unsigned int sourceSubresource,
+ int level, int face, GLint xoffset, GLint yoffset,
+ GLsizei width, GLsizei height)
+{
+ if (srcTexture)
+ {
+ // Round up the width and height to the nearest multiple of dimension alignment
+ unsigned int dimensionAlignment = d3d11::GetTextureFormatDimensionAlignment(mTextureFormat);
+ width = width + dimensionAlignment - 1 - (width - 1) % dimensionAlignment;
+ height = height + dimensionAlignment - 1 - (height - 1) % dimensionAlignment;
+
+ D3D11_BOX srcBox;
+ srcBox.left = xoffset;
+ srcBox.top = yoffset;
+ srcBox.right = xoffset + width;
+ srcBox.bottom = yoffset + height;
+ srcBox.front = 0;
+ srcBox.back = 1;
+
+ ID3D11DeviceContext *context = mRenderer->getDeviceContext();
+
+ ASSERT(getBaseTexture());
+ context->CopySubresourceRegion(getBaseTexture(), getSubresourceIndex(level + mLodOffset, face),
+ xoffset, yoffset, 0, srcTexture, sourceSubresource, &srcBox);
+ return true;
+ }
+
+ return false;
+}
+
+void TextureStorage11::generateMipmapLayer(RenderTarget11 *source, RenderTarget11 *dest)
+{
+ if (source && dest)
+ {
+ ID3D11ShaderResourceView *sourceSRV = source->getShaderResourceView();
+ ID3D11RenderTargetView *destRTV = dest->getRenderTargetView();
+
+ if (sourceSRV && destRTV)
+ {
+ gl::Rectangle sourceArea;
+ sourceArea.x = 0;
+ sourceArea.y = 0;
+ sourceArea.width = source->getWidth();
+ sourceArea.height = source->getHeight();
+
+ gl::Rectangle destArea;
+ destArea.x = 0;
+ destArea.y = 0;
+ destArea.width = dest->getWidth();
+ destArea.height = dest->getHeight();
+
+ mRenderer->copyTexture(sourceSRV, sourceArea, source->getWidth(), source->getHeight(),
+ destRTV, destArea, dest->getWidth(), dest->getHeight(),
+ GL_RGBA);
+ }
+
+ if (sourceSRV)
+ {
+ sourceSRV->Release();
+ }
+ if (destRTV)
+ {
+ destRTV->Release();
+ }
+ }
+}
+
+TextureStorage11_2D::TextureStorage11_2D(Renderer *renderer, SwapChain11 *swapchain)
+ : TextureStorage11(renderer, D3D11_BIND_RENDER_TARGET | D3D11_BIND_SHADER_RESOURCE)
+{
+ mTexture = swapchain->getOffscreenTexture();
+ mSRV = swapchain->getRenderTargetShaderResource();
+
+ for (unsigned int i = 0; i < gl::IMPLEMENTATION_MAX_TEXTURE_LEVELS; i++)
+ {
+ mRenderTarget[i] = NULL;
+ }
+
+ D3D11_TEXTURE2D_DESC texDesc;
+ mTexture->GetDesc(&texDesc);
+ mMipLevels = texDesc.MipLevels;
+ mTextureFormat = texDesc.Format;
+ mTextureWidth = texDesc.Width;
+ mTextureHeight = texDesc.Height;
+
+ D3D11_SHADER_RESOURCE_VIEW_DESC srvDesc;
+ mSRV->GetDesc(&srvDesc);
+ mShaderResourceFormat = srvDesc.Format;
+
+ ID3D11RenderTargetView* offscreenRTV = swapchain->getRenderTarget();
+ D3D11_RENDER_TARGET_VIEW_DESC rtvDesc;
+ offscreenRTV->GetDesc(&rtvDesc);
+ mRenderTargetFormat = rtvDesc.Format;
+ offscreenRTV->Release();
+
+ mDepthStencilFormat = DXGI_FORMAT_UNKNOWN;
+}
+
+TextureStorage11_2D::TextureStorage11_2D(Renderer *renderer, int levels, GLenum internalformat, GLenum usage, bool forceRenderable, GLsizei width, GLsizei height)
+ : TextureStorage11(renderer, GetTextureBindFlags(gl_d3d11::ConvertTextureFormat(internalformat), usage, forceRenderable))
+{
+ for (unsigned int i = 0; i < gl::IMPLEMENTATION_MAX_TEXTURE_LEVELS; i++)
+ {
+ mRenderTarget[i] = NULL;
+ }
+
+ DXGI_FORMAT convertedFormat = gl_d3d11::ConvertTextureFormat(internalformat);
+ if (d3d11::IsDepthStencilFormat(convertedFormat))
+ {
+ mTextureFormat = d3d11::GetDepthTextureFormat(convertedFormat);
+ mShaderResourceFormat = d3d11::GetDepthShaderResourceFormat(convertedFormat);
+ mDepthStencilFormat = convertedFormat;
+ mRenderTargetFormat = DXGI_FORMAT_UNKNOWN;
+ }
+ else
+ {
+ mTextureFormat = convertedFormat;
+ mShaderResourceFormat = convertedFormat;
+ mDepthStencilFormat = DXGI_FORMAT_UNKNOWN;
+ mRenderTargetFormat = convertedFormat;
+ }
+
+ // if the width or height is not positive this should be treated as an incomplete texture
+ // we handle that here by skipping the d3d texture creation
+ if (width > 0 && height > 0)
+ {
+ // adjust size if needed for compressed textures
+ gl::MakeValidSize(false, gl::IsCompressed(internalformat), &width, &height, &mLodOffset);
+
+ ID3D11Device *device = mRenderer->getDevice();
+
+ D3D11_TEXTURE2D_DESC desc;
+ desc.Width = width; // Compressed texture size constraints?
+ desc.Height = height;
+ desc.MipLevels = (levels > 0) ? levels + mLodOffset : 0;
+ desc.ArraySize = 1;
+ desc.Format = mTextureFormat;
+ desc.SampleDesc.Count = 1;
+ desc.SampleDesc.Quality = 0;
+ desc.Usage = D3D11_USAGE_DEFAULT;
+ desc.BindFlags = getBindFlags();
+ desc.CPUAccessFlags = 0;
+ desc.MiscFlags = 0;
+
+ HRESULT result = device->CreateTexture2D(&desc, NULL, &mTexture);
+
+ // this can happen from windows TDR
+ if (d3d11::isDeviceLostError(result))
+ {
+ mRenderer->notifyDeviceLost();
+ gl::error(GL_OUT_OF_MEMORY);
+ }
+ else if (FAILED(result))
+ {
+ ASSERT(result == E_OUTOFMEMORY);
+ ERR("Creating image failed.");
+ gl::error(GL_OUT_OF_MEMORY);
+ }
+ else
+ {
+ mTexture->GetDesc(&desc);
+ mMipLevels = desc.MipLevels;
+ mTextureWidth = desc.Width;
+ mTextureHeight = desc.Height;
+ }
+ }
+}
+
+TextureStorage11_2D::~TextureStorage11_2D()
+{
+ if (mTexture)
+ {
+ mTexture->Release();
+ mTexture = NULL;
+ }
+
+ if (mSRV)
+ {
+ mSRV->Release();
+ mSRV = NULL;
+ }
+
+ for (unsigned int i = 0; i < gl::IMPLEMENTATION_MAX_TEXTURE_LEVELS; i++)
+ {
+ delete mRenderTarget[i];
+ mRenderTarget[i] = NULL;
+ }
+}
+
+TextureStorage11_2D *TextureStorage11_2D::makeTextureStorage11_2D(TextureStorage *storage)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(TextureStorage11_2D*, storage));
+ return static_cast<TextureStorage11_2D*>(storage);
+}
+
+RenderTarget *TextureStorage11_2D::getRenderTarget(int level)
+{
+ if (level >= 0 && level < static_cast<int>(mMipLevels))
+ {
+ if (!mRenderTarget[level])
+ {
+ ID3D11Device *device = mRenderer->getDevice();
+ HRESULT result;
+
+ D3D11_SHADER_RESOURCE_VIEW_DESC srvDesc;
+ srvDesc.Format = mShaderResourceFormat;
+ srvDesc.ViewDimension = D3D11_SRV_DIMENSION_TEXTURE2D;
+ srvDesc.Texture2D.MostDetailedMip = level;
+ srvDesc.Texture2D.MipLevels = 1;
+
+ ID3D11ShaderResourceView *srv;
+ result = device->CreateShaderResourceView(mTexture, &srvDesc, &srv);
+
+ if (result == E_OUTOFMEMORY)
+ {
+ return gl::error(GL_OUT_OF_MEMORY, static_cast<RenderTarget*>(NULL));
+ }
+ ASSERT(SUCCEEDED(result));
+
+ if (mRenderTargetFormat != DXGI_FORMAT_UNKNOWN)
+ {
+ D3D11_RENDER_TARGET_VIEW_DESC rtvDesc;
+ rtvDesc.Format = mRenderTargetFormat;
+ rtvDesc.ViewDimension = D3D11_RTV_DIMENSION_TEXTURE2D;
+ rtvDesc.Texture2D.MipSlice = level;
+
+ ID3D11RenderTargetView *rtv;
+ result = device->CreateRenderTargetView(mTexture, &rtvDesc, &rtv);
+
+ if (result == E_OUTOFMEMORY)
+ {
+ srv->Release();
+ return gl::error(GL_OUT_OF_MEMORY, static_cast<RenderTarget*>(NULL));
+ }
+ ASSERT(SUCCEEDED(result));
+
+ // RenderTarget11 expects to be the owner of the resources it is given but TextureStorage11
+ // also needs to keep a reference to the texture.
+ mTexture->AddRef();
+
+ mRenderTarget[level] = new RenderTarget11(mRenderer, rtv, mTexture, srv,
+ std::max(mTextureWidth >> level, 1U),
+ std::max(mTextureHeight >> level, 1U));
+ }
+ else if (mDepthStencilFormat != DXGI_FORMAT_UNKNOWN)
+ {
+ D3D11_DEPTH_STENCIL_VIEW_DESC dsvDesc;
+ dsvDesc.Format = mDepthStencilFormat;
+ dsvDesc.ViewDimension = D3D11_DSV_DIMENSION_TEXTURE2D;
+ dsvDesc.Texture2D.MipSlice = level;
+ dsvDesc.Flags = 0;
+
+ ID3D11DepthStencilView *dsv;
+ result = device->CreateDepthStencilView(mTexture, &dsvDesc, &dsv);
+
+ if (result == E_OUTOFMEMORY)
+ {
+ srv->Release();
+ return gl::error(GL_OUT_OF_MEMORY, static_cast<RenderTarget*>(NULL));
+ }
+ ASSERT(SUCCEEDED(result));
+
+ // RenderTarget11 expects to be the owner of the resources it is given but TextureStorage11
+ // also needs to keep a reference to the texture.
+ mTexture->AddRef();
+
+ mRenderTarget[level] = new RenderTarget11(mRenderer, dsv, mTexture, srv,
+ std::max(mTextureWidth >> level, 1U),
+ std::max(mTextureHeight >> level, 1U));
+ }
+ else
+ {
+ UNREACHABLE();
+ }
+ }
+
+ return mRenderTarget[level];
+ }
+ else
+ {
+ return NULL;
+ }
+}
+
+ID3D11ShaderResourceView *TextureStorage11_2D::getSRV()
+{
+ if (!mSRV)
+ {
+ ID3D11Device *device = mRenderer->getDevice();
+
+ D3D11_SHADER_RESOURCE_VIEW_DESC srvDesc;
+ srvDesc.Format = mShaderResourceFormat;
+ srvDesc.ViewDimension = D3D11_SRV_DIMENSION_TEXTURE2D;
+ srvDesc.Texture2D.MipLevels = (mMipLevels == 0 ? -1 : mMipLevels);
+ srvDesc.Texture2D.MostDetailedMip = 0;
+
+ HRESULT result = device->CreateShaderResourceView(mTexture, &srvDesc, &mSRV);
+
+ if (result == E_OUTOFMEMORY)
+ {
+ return gl::error(GL_OUT_OF_MEMORY, static_cast<ID3D11ShaderResourceView*>(NULL));
+ }
+ ASSERT(SUCCEEDED(result));
+ }
+
+ return mSRV;
+}
+
+void TextureStorage11_2D::generateMipmap(int level)
+{
+ RenderTarget11 *source = RenderTarget11::makeRenderTarget11(getRenderTarget(level - 1));
+ RenderTarget11 *dest = RenderTarget11::makeRenderTarget11(getRenderTarget(level));
+
+ generateMipmapLayer(source, dest);
+}
+
+TextureStorage11_Cube::TextureStorage11_Cube(Renderer *renderer, int levels, GLenum internalformat, GLenum usage, bool forceRenderable, int size)
+ : TextureStorage11(renderer, GetTextureBindFlags(gl_d3d11::ConvertTextureFormat(internalformat), usage, forceRenderable))
+{
+ for (unsigned int i = 0; i < 6; i++)
+ {
+ for (unsigned int j = 0; j < gl::IMPLEMENTATION_MAX_TEXTURE_LEVELS; j++)
+ {
+ mRenderTarget[i][j] = NULL;
+ }
+ }
+
+ DXGI_FORMAT convertedFormat = gl_d3d11::ConvertTextureFormat(internalformat);
+ if (d3d11::IsDepthStencilFormat(convertedFormat))
+ {
+ mTextureFormat = d3d11::GetDepthTextureFormat(convertedFormat);
+ mShaderResourceFormat = d3d11::GetDepthShaderResourceFormat(convertedFormat);
+ mDepthStencilFormat = convertedFormat;
+ mRenderTargetFormat = DXGI_FORMAT_UNKNOWN;
+ }
+ else
+ {
+ mTextureFormat = convertedFormat;
+ mShaderResourceFormat = convertedFormat;
+ mDepthStencilFormat = DXGI_FORMAT_UNKNOWN;
+ mRenderTargetFormat = convertedFormat;
+ }
+
+ // if the size is not positive this should be treated as an incomplete texture
+ // we handle that here by skipping the d3d texture creation
+ if (size > 0)
+ {
+ // adjust size if needed for compressed textures
+ int height = size;
+ gl::MakeValidSize(false, gl::IsCompressed(internalformat), &size, &height, &mLodOffset);
+
+ ID3D11Device *device = mRenderer->getDevice();
+
+ D3D11_TEXTURE2D_DESC desc;
+ desc.Width = size;
+ desc.Height = size;
+ desc.MipLevels = (levels > 0) ? levels + mLodOffset : 0;
+ desc.ArraySize = 6;
+ desc.Format = mTextureFormat;
+ desc.SampleDesc.Count = 1;
+ desc.SampleDesc.Quality = 0;
+ desc.Usage = D3D11_USAGE_DEFAULT;
+ desc.BindFlags = getBindFlags();
+ desc.CPUAccessFlags = 0;
+ desc.MiscFlags = D3D11_RESOURCE_MISC_TEXTURECUBE;
+
+ HRESULT result = device->CreateTexture2D(&desc, NULL, &mTexture);
+
+ if (FAILED(result))
+ {
+ ASSERT(result == E_OUTOFMEMORY);
+ ERR("Creating image failed.");
+ gl::error(GL_OUT_OF_MEMORY);
+ }
+ else
+ {
+ mTexture->GetDesc(&desc);
+ mMipLevels = desc.MipLevels;
+ mTextureWidth = desc.Width;
+ mTextureHeight = desc.Height;
+ }
+ }
+}
+
+TextureStorage11_Cube::~TextureStorage11_Cube()
+{
+ if (mTexture)
+ {
+ mTexture->Release();
+ mTexture = NULL;
+ }
+
+ if (mSRV)
+ {
+ mSRV->Release();
+ mSRV = NULL;
+ }
+
+ for (unsigned int i = 0; i < 6; i++)
+ {
+ for (unsigned int j = 0; j < gl::IMPLEMENTATION_MAX_TEXTURE_LEVELS; j++)
+ {
+ delete mRenderTarget[i][j];
+ mRenderTarget[i][j] = NULL;
+ }
+ }
+}
+
+TextureStorage11_Cube *TextureStorage11_Cube::makeTextureStorage11_Cube(TextureStorage *storage)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(TextureStorage11_Cube*, storage));
+ return static_cast<TextureStorage11_Cube*>(storage);
+}
+
+RenderTarget *TextureStorage11_Cube::getRenderTarget(GLenum faceTarget, int level)
+{
+ unsigned int faceIdx = gl::TextureCubeMap::faceIndex(faceTarget);
+ if (level >= 0 && level < static_cast<int>(mMipLevels))
+ {
+ if (!mRenderTarget[faceIdx][level])
+ {
+ ID3D11Device *device = mRenderer->getDevice();
+ HRESULT result;
+
+ D3D11_SHADER_RESOURCE_VIEW_DESC srvDesc;
+ srvDesc.Format = mShaderResourceFormat;
+ srvDesc.ViewDimension = D3D11_SRV_DIMENSION_TEXTURECUBE;
+ srvDesc.Texture2DArray.MostDetailedMip = level;
+ srvDesc.Texture2DArray.MipLevels = 1;
+ srvDesc.Texture2DArray.FirstArraySlice = faceIdx;
+ srvDesc.Texture2DArray.ArraySize = 1;
+
+ ID3D11ShaderResourceView *srv;
+ result = device->CreateShaderResourceView(mTexture, &srvDesc, &srv);
+
+ if (result == E_OUTOFMEMORY)
+ {
+ return gl::error(GL_OUT_OF_MEMORY, static_cast<RenderTarget*>(NULL));
+ }
+ ASSERT(SUCCEEDED(result));
+
+ if (mRenderTargetFormat != DXGI_FORMAT_UNKNOWN)
+ {
+ D3D11_RENDER_TARGET_VIEW_DESC rtvDesc;
+ rtvDesc.Format = mRenderTargetFormat;
+ rtvDesc.ViewDimension = D3D11_RTV_DIMENSION_TEXTURE2DARRAY;
+ rtvDesc.Texture2DArray.MipSlice = level;
+ rtvDesc.Texture2DArray.FirstArraySlice = faceIdx;
+ rtvDesc.Texture2DArray.ArraySize = 1;
+
+ ID3D11RenderTargetView *rtv;
+ result = device->CreateRenderTargetView(mTexture, &rtvDesc, &rtv);
+
+ if (result == E_OUTOFMEMORY)
+ {
+ srv->Release();
+ return gl::error(GL_OUT_OF_MEMORY, static_cast<RenderTarget*>(NULL));
+ }
+ ASSERT(SUCCEEDED(result));
+
+ // RenderTarget11 expects to be the owner of the resources it is given but TextureStorage11
+ // also needs to keep a reference to the texture.
+ mTexture->AddRef();
+
+ mRenderTarget[faceIdx][level] = new RenderTarget11(mRenderer, rtv, mTexture, srv,
+ std::max(mTextureWidth >> level, 1U),
+ std::max(mTextureHeight >> level, 1U));
+ }
+ else if (mDepthStencilFormat != DXGI_FORMAT_UNKNOWN)
+ {
+ D3D11_DEPTH_STENCIL_VIEW_DESC dsvDesc;
+ dsvDesc.Format = mRenderTargetFormat;
+ dsvDesc.ViewDimension = D3D11_DSV_DIMENSION_TEXTURE2DARRAY;
+ dsvDesc.Texture2DArray.MipSlice = level;
+ dsvDesc.Texture2DArray.FirstArraySlice = faceIdx;
+ dsvDesc.Texture2DArray.ArraySize = 1;
+
+ ID3D11DepthStencilView *dsv;
+ result = device->CreateDepthStencilView(mTexture, &dsvDesc, &dsv);
+
+ if (result == E_OUTOFMEMORY)
+ {
+ srv->Release();
+ return gl::error(GL_OUT_OF_MEMORY, static_cast<RenderTarget*>(NULL));
+ }
+ ASSERT(SUCCEEDED(result));
+
+ // RenderTarget11 expects to be the owner of the resources it is given but TextureStorage11
+ // also needs to keep a reference to the texture.
+ mTexture->AddRef();
+
+ mRenderTarget[faceIdx][level] = new RenderTarget11(mRenderer, dsv, mTexture, srv,
+ std::max(mTextureWidth >> level, 1U),
+ std::max(mTextureHeight >> level, 1U));
+ }
+ else
+ {
+ UNREACHABLE();
+ }
+ }
+
+ return mRenderTarget[faceIdx][level];
+ }
+ else
+ {
+ return NULL;
+ }
+}
+
+ID3D11ShaderResourceView *TextureStorage11_Cube::getSRV()
+{
+ if (!mSRV)
+ {
+ ID3D11Device *device = mRenderer->getDevice();
+
+ D3D11_SHADER_RESOURCE_VIEW_DESC srvDesc;
+ srvDesc.Format = mShaderResourceFormat;
+ srvDesc.ViewDimension = D3D11_SRV_DIMENSION_TEXTURECUBE;
+ srvDesc.TextureCube.MipLevels = (mMipLevels == 0 ? -1 : mMipLevels);
+ srvDesc.TextureCube.MostDetailedMip = 0;
+
+ HRESULT result = device->CreateShaderResourceView(mTexture, &srvDesc, &mSRV);
+
+ if (result == E_OUTOFMEMORY)
+ {
+ return gl::error(GL_OUT_OF_MEMORY, static_cast<ID3D11ShaderResourceView*>(NULL));
+ }
+ ASSERT(SUCCEEDED(result));
+ }
+
+ return mSRV;
+}
+
+void TextureStorage11_Cube::generateMipmap(int face, int level)
+{
+ RenderTarget11 *source = RenderTarget11::makeRenderTarget11(getRenderTarget(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, level - 1));
+ RenderTarget11 *dest = RenderTarget11::makeRenderTarget11(getRenderTarget(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, level));
+
+ generateMipmapLayer(source, dest);
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage11.h b/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage11.h
new file mode 100644
index 0000000000..3c5ded05b8
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage11.h
@@ -0,0 +1,120 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// TextureStorage11.h: Defines the abstract rx::TextureStorage11 class and its concrete derived
+// classes TextureStorage11_2D and TextureStorage11_Cube, which act as the interface to the D3D11 texture.
+
+#ifndef LIBGLESV2_RENDERER_TEXTURESTORAGE11_H_
+#define LIBGLESV2_RENDERER_TEXTURESTORAGE11_H_
+
+#include "libGLESv2/Texture.h"
+#include "libGLESv2/renderer/TextureStorage.h"
+
+namespace rx
+{
+class RenderTarget;
+class RenderTarget11;
+class Renderer;
+class Renderer11;
+class SwapChain11;
+
+class TextureStorage11 : public TextureStorage
+{
+ public:
+ TextureStorage11(Renderer *renderer, UINT bindFlags);
+ virtual ~TextureStorage11();
+
+ static TextureStorage11 *makeTextureStorage11(TextureStorage *storage);
+
+ static DWORD GetTextureBindFlags(DXGI_FORMAT d3dfmt, GLenum glusage, bool forceRenderable);
+ static bool IsTextureFormatRenderable(DXGI_FORMAT format);
+
+ UINT getBindFlags() const;
+
+ virtual ID3D11Texture2D *getBaseTexture() const;
+ virtual ID3D11ShaderResourceView *getSRV() = 0;
+ virtual RenderTarget *getRenderTarget() { return getRenderTarget(0); }
+ virtual RenderTarget *getRenderTarget(int level) { return NULL; }
+ virtual RenderTarget *getRenderTarget(GLenum faceTarget) { return getRenderTarget(faceTarget, 0); }
+ virtual RenderTarget *getRenderTarget(GLenum faceTarget, int level) { return NULL; }
+
+ virtual void generateMipmap(int level) {};
+ virtual void generateMipmap(int face, int level) {};
+
+ virtual int getLodOffset() const;
+ virtual bool isRenderTarget() const;
+ virtual bool isManaged() const;
+ virtual int levelCount();
+ UINT getSubresourceIndex(int level, int faceTarget);
+
+ bool updateSubresourceLevel(ID3D11Texture2D *texture, unsigned int sourceSubresource, int level,
+ int faceTarget, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height);
+
+ protected:
+ void generateMipmapLayer(RenderTarget11 *source, RenderTarget11 *dest);
+
+ Renderer11 *mRenderer;
+ int mLodOffset;
+ unsigned int mMipLevels;
+
+ ID3D11Texture2D *mTexture;
+ DXGI_FORMAT mTextureFormat;
+ DXGI_FORMAT mShaderResourceFormat;
+ DXGI_FORMAT mRenderTargetFormat;
+ DXGI_FORMAT mDepthStencilFormat;
+ unsigned int mTextureWidth;
+ unsigned int mTextureHeight;
+
+ ID3D11ShaderResourceView *mSRV;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(TextureStorage11);
+
+ const UINT mBindFlags;
+};
+
+class TextureStorage11_2D : public TextureStorage11
+{
+ public:
+ TextureStorage11_2D(Renderer *renderer, SwapChain11 *swapchain);
+ TextureStorage11_2D(Renderer *renderer, int levels, GLenum internalformat, GLenum usage, bool forceRenderable, GLsizei width, GLsizei height);
+ virtual ~TextureStorage11_2D();
+
+ static TextureStorage11_2D *makeTextureStorage11_2D(TextureStorage *storage);
+
+ virtual ID3D11ShaderResourceView *getSRV();
+ virtual RenderTarget *getRenderTarget(int level);
+
+ virtual void generateMipmap(int level);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(TextureStorage11_2D);
+
+ RenderTarget11 *mRenderTarget[gl::IMPLEMENTATION_MAX_TEXTURE_LEVELS];
+};
+
+class TextureStorage11_Cube : public TextureStorage11
+{
+ public:
+ TextureStorage11_Cube(Renderer *renderer, int levels, GLenum internalformat, GLenum usage, bool forceRenderable, int size);
+ virtual ~TextureStorage11_Cube();
+
+ static TextureStorage11_Cube *makeTextureStorage11_Cube(TextureStorage *storage);
+
+ virtual ID3D11ShaderResourceView *getSRV();
+ virtual RenderTarget *getRenderTarget(GLenum faceTarget, int level);
+
+ virtual void generateMipmap(int face, int level);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(TextureStorage11_Cube);
+
+ RenderTarget11 *mRenderTarget[6][gl::IMPLEMENTATION_MAX_TEXTURE_LEVELS];
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_TEXTURESTORAGE11_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage9.cpp
new file mode 100644
index 0000000000..8aa74a7cba
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage9.cpp
@@ -0,0 +1,328 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// TextureStorage9.cpp: Implements the abstract rx::TextureStorage9 class and its concrete derived
+// classes TextureStorage9_2D and TextureStorage9_Cube, which act as the interface to the
+// D3D9 texture.
+
+#include "libGLESv2/main.h"
+#include "libGLESv2/renderer/Renderer9.h"
+#include "libGLESv2/renderer/TextureStorage9.h"
+#include "libGLESv2/renderer/SwapChain9.h"
+#include "libGLESv2/renderer/RenderTarget9.h"
+#include "libGLESv2/renderer/renderer9_utils.h"
+#include "libGLESv2/Texture.h"
+
+namespace rx
+{
+TextureStorage9::TextureStorage9(Renderer *renderer, DWORD usage)
+ : mLodOffset(0),
+ mRenderer(Renderer9::makeRenderer9(renderer)),
+ mD3DUsage(usage),
+ mD3DPool(mRenderer->getTexturePool(usage))
+{
+}
+
+TextureStorage9::~TextureStorage9()
+{
+}
+
+TextureStorage9 *TextureStorage9::makeTextureStorage9(TextureStorage *storage)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(TextureStorage9*, storage));
+ return static_cast<TextureStorage9*>(storage);
+}
+
+DWORD TextureStorage9::GetTextureUsage(D3DFORMAT d3dfmt, GLenum glusage, bool forceRenderable)
+{
+ DWORD d3dusage = 0;
+
+ if (d3dfmt == D3DFMT_INTZ)
+ {
+ d3dusage |= D3DUSAGE_DEPTHSTENCIL;
+ }
+ else if(forceRenderable || (TextureStorage9::IsTextureFormatRenderable(d3dfmt) && (glusage == GL_FRAMEBUFFER_ATTACHMENT_ANGLE)))
+ {
+ d3dusage |= D3DUSAGE_RENDERTARGET;
+ }
+ return d3dusage;
+}
+
+bool TextureStorage9::IsTextureFormatRenderable(D3DFORMAT format)
+{
+ if (format == D3DFMT_INTZ)
+ {
+ return true;
+ }
+ switch(format)
+ {
+ case D3DFMT_L8:
+ case D3DFMT_A8L8:
+ case D3DFMT_DXT1:
+ case D3DFMT_DXT3:
+ case D3DFMT_DXT5:
+ return false;
+ case D3DFMT_A8R8G8B8:
+ case D3DFMT_X8R8G8B8:
+ case D3DFMT_A16B16G16R16F:
+ case D3DFMT_A32B32G32R32F:
+ return true;
+ default:
+ UNREACHABLE();
+ }
+
+ return false;
+}
+
+bool TextureStorage9::isRenderTarget() const
+{
+ return (mD3DUsage & (D3DUSAGE_RENDERTARGET | D3DUSAGE_DEPTHSTENCIL)) != 0;
+}
+
+bool TextureStorage9::isManaged() const
+{
+ return (mD3DPool == D3DPOOL_MANAGED);
+}
+
+D3DPOOL TextureStorage9::getPool() const
+{
+ return mD3DPool;
+}
+
+DWORD TextureStorage9::getUsage() const
+{
+ return mD3DUsage;
+}
+
+int TextureStorage9::getLodOffset() const
+{
+ return mLodOffset;
+}
+
+int TextureStorage9::levelCount()
+{
+ return getBaseTexture() ? getBaseTexture()->GetLevelCount() - getLodOffset() : 0;
+}
+
+TextureStorage9_2D::TextureStorage9_2D(Renderer *renderer, SwapChain9 *swapchain) : TextureStorage9(renderer, D3DUSAGE_RENDERTARGET)
+{
+ IDirect3DTexture9 *surfaceTexture = swapchain->getOffscreenTexture();
+ mTexture = surfaceTexture;
+ mRenderTarget = NULL;
+
+ initializeRenderTarget();
+}
+
+TextureStorage9_2D::TextureStorage9_2D(Renderer *renderer, int levels, GLenum internalformat, GLenum usage, bool forceRenderable, GLsizei width, GLsizei height)
+ : TextureStorage9(renderer, GetTextureUsage(Renderer9::makeRenderer9(renderer)->ConvertTextureInternalFormat(internalformat), usage, forceRenderable))
+{
+ mTexture = NULL;
+ mRenderTarget = NULL;
+ // if the width or height is not positive this should be treated as an incomplete texture
+ // we handle that here by skipping the d3d texture creation
+ if (width > 0 && height > 0)
+ {
+ IDirect3DDevice9 *device = mRenderer->getDevice();
+ gl::MakeValidSize(false, gl::IsCompressed(internalformat), &width, &height, &mLodOffset);
+ HRESULT result = device->CreateTexture(width, height, levels ? levels + mLodOffset : 0, getUsage(),
+ mRenderer->ConvertTextureInternalFormat(internalformat), getPool(), &mTexture, NULL);
+
+ if (FAILED(result))
+ {
+ ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
+ gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ initializeRenderTarget();
+}
+
+TextureStorage9_2D::~TextureStorage9_2D()
+{
+ if (mTexture)
+ {
+ mTexture->Release();
+ }
+
+ delete mRenderTarget;
+}
+
+TextureStorage9_2D *TextureStorage9_2D::makeTextureStorage9_2D(TextureStorage *storage)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(TextureStorage9_2D*, storage));
+ return static_cast<TextureStorage9_2D*>(storage);
+}
+
+// Increments refcount on surface.
+// caller must Release() the returned surface
+IDirect3DSurface9 *TextureStorage9_2D::getSurfaceLevel(int level, bool dirty)
+{
+ IDirect3DSurface9 *surface = NULL;
+
+ if (mTexture)
+ {
+ HRESULT result = mTexture->GetSurfaceLevel(level + mLodOffset, &surface);
+ ASSERT(SUCCEEDED(result));
+
+ // With managed textures the driver needs to be informed of updates to the lower mipmap levels
+ if (level + mLodOffset != 0 && isManaged() && dirty)
+ {
+ mTexture->AddDirtyRect(NULL);
+ }
+ }
+
+ return surface;
+}
+
+RenderTarget *TextureStorage9_2D::getRenderTarget()
+{
+ return mRenderTarget;
+}
+
+void TextureStorage9_2D::generateMipmap(int level)
+{
+ IDirect3DSurface9 *upper = getSurfaceLevel(level - 1, false);
+ IDirect3DSurface9 *lower = getSurfaceLevel(level, true);
+
+ if (upper != NULL && lower != NULL)
+ {
+ mRenderer->boxFilter(upper, lower);
+ }
+
+ if (upper != NULL) upper->Release();
+ if (lower != NULL) lower->Release();
+}
+
+IDirect3DBaseTexture9 *TextureStorage9_2D::getBaseTexture() const
+{
+ return mTexture;
+}
+
+void TextureStorage9_2D::initializeRenderTarget()
+{
+ ASSERT(mRenderTarget == NULL);
+
+ if (mTexture != NULL && isRenderTarget())
+ {
+ IDirect3DSurface9 *surface = getSurfaceLevel(0, false);
+
+ mRenderTarget = new RenderTarget9(mRenderer, surface);
+ }
+}
+
+TextureStorage9_Cube::TextureStorage9_Cube(Renderer *renderer, int levels, GLenum internalformat, GLenum usage, bool forceRenderable, int size)
+ : TextureStorage9(renderer, GetTextureUsage(Renderer9::makeRenderer9(renderer)->ConvertTextureInternalFormat(internalformat), usage, forceRenderable))
+{
+ mTexture = NULL;
+ for (int i = 0; i < 6; ++i)
+ {
+ mRenderTarget[i] = NULL;
+ }
+
+ // if the size is not positive this should be treated as an incomplete texture
+ // we handle that here by skipping the d3d texture creation
+ if (size > 0)
+ {
+ IDirect3DDevice9 *device = mRenderer->getDevice();
+ int height = size;
+ gl::MakeValidSize(false, gl::IsCompressed(internalformat), &size, &height, &mLodOffset);
+ HRESULT result = device->CreateCubeTexture(size, levels ? levels + mLodOffset : 0, getUsage(),
+ mRenderer->ConvertTextureInternalFormat(internalformat), getPool(), &mTexture, NULL);
+
+ if (FAILED(result))
+ {
+ ASSERT(result == D3DERR_OUTOFVIDEOMEMORY || result == E_OUTOFMEMORY);
+ gl::error(GL_OUT_OF_MEMORY);
+ }
+ }
+
+ initializeRenderTarget();
+}
+
+TextureStorage9_Cube::~TextureStorage9_Cube()
+{
+ if (mTexture)
+ {
+ mTexture->Release();
+ }
+
+ for (int i = 0; i < 6; ++i)
+ {
+ delete mRenderTarget[i];
+ }
+}
+
+TextureStorage9_Cube *TextureStorage9_Cube::makeTextureStorage9_Cube(TextureStorage *storage)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(TextureStorage9_Cube*, storage));
+ return static_cast<TextureStorage9_Cube*>(storage);
+}
+
+// Increments refcount on surface.
+// caller must Release() the returned surface
+IDirect3DSurface9 *TextureStorage9_Cube::getCubeMapSurface(GLenum faceTarget, int level, bool dirty)
+{
+ IDirect3DSurface9 *surface = NULL;
+
+ if (mTexture)
+ {
+ D3DCUBEMAP_FACES face = gl_d3d9::ConvertCubeFace(faceTarget);
+ HRESULT result = mTexture->GetCubeMapSurface(face, level + mLodOffset, &surface);
+ ASSERT(SUCCEEDED(result));
+
+ // With managed textures the driver needs to be informed of updates to the lower mipmap levels
+ if (level != 0 && isManaged() && dirty)
+ {
+ mTexture->AddDirtyRect(face, NULL);
+ }
+ }
+
+ return surface;
+}
+
+RenderTarget *TextureStorage9_Cube::getRenderTarget(GLenum faceTarget)
+{
+ return mRenderTarget[gl::TextureCubeMap::faceIndex(faceTarget)];
+}
+
+void TextureStorage9_Cube::generateMipmap(int face, int level)
+{
+ IDirect3DSurface9 *upper = getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, level - 1, false);
+ IDirect3DSurface9 *lower = getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + face, level, true);
+
+ if (upper != NULL && lower != NULL)
+ {
+ mRenderer->boxFilter(upper, lower);
+ }
+
+ if (upper != NULL) upper->Release();
+ if (lower != NULL) lower->Release();
+}
+
+IDirect3DBaseTexture9 *TextureStorage9_Cube::getBaseTexture() const
+{
+ return mTexture;
+}
+
+void TextureStorage9_Cube::initializeRenderTarget()
+{
+ if (mTexture != NULL && isRenderTarget())
+ {
+ IDirect3DSurface9 *surface = NULL;
+
+ for (int i = 0; i < 6; ++i)
+ {
+ ASSERT(mRenderTarget[i] == NULL);
+
+ surface = getCubeMapSurface(GL_TEXTURE_CUBE_MAP_POSITIVE_X + i, 0, false);
+
+ mRenderTarget[i] = new RenderTarget9(mRenderer, surface);
+ }
+ }
+}
+
+} \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage9.h b/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage9.h
new file mode 100644
index 0000000000..86f551a131
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/TextureStorage9.h
@@ -0,0 +1,109 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// TextureStorage9.h: Defines the abstract rx::TextureStorage9 class and its concrete derived
+// classes TextureStorage9_2D and TextureStorage9_Cube, which act as the interface to the
+// D3D9 texture.
+
+#ifndef LIBGLESV2_RENDERER_TEXTURESTORAGE9_H_
+#define LIBGLESV2_RENDERER_TEXTURESTORAGE9_H_
+
+#include "libGLESv2/renderer/TextureStorage.h"
+#include "common/debug.h"
+
+namespace rx
+{
+class Renderer9;
+class SwapChain9;
+class RenderTarget;
+class RenderTarget9;
+class Blit;
+
+class TextureStorage9 : public TextureStorage
+{
+ public:
+ TextureStorage9(Renderer *renderer, DWORD usage);
+ virtual ~TextureStorage9();
+
+ static TextureStorage9 *makeTextureStorage9(TextureStorage *storage);
+
+ static DWORD GetTextureUsage(D3DFORMAT d3dfmt, GLenum glusage, bool forceRenderable);
+ static bool IsTextureFormatRenderable(D3DFORMAT format);
+
+ D3DPOOL getPool() const;
+ DWORD getUsage() const;
+
+ virtual IDirect3DBaseTexture9 *getBaseTexture() const = 0;
+ virtual RenderTarget *getRenderTarget() { return NULL; }
+ virtual RenderTarget *getRenderTarget(GLenum faceTarget) { return NULL; }
+ virtual void generateMipmap(int level) {};
+ virtual void generateMipmap(int face, int level) {};
+
+ virtual int getLodOffset() const;
+ virtual bool isRenderTarget() const;
+ virtual bool isManaged() const;
+ virtual int levelCount();
+
+ protected:
+ int mLodOffset;
+ Renderer9 *mRenderer;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(TextureStorage9);
+
+ const DWORD mD3DUsage;
+ const D3DPOOL mD3DPool;
+};
+
+class TextureStorage9_2D : public TextureStorage9
+{
+ public:
+ TextureStorage9_2D(Renderer *renderer, SwapChain9 *swapchain);
+ TextureStorage9_2D(Renderer *renderer, int levels, GLenum internalformat, GLenum usage, bool forceRenderable, GLsizei width, GLsizei height);
+ virtual ~TextureStorage9_2D();
+
+ static TextureStorage9_2D *makeTextureStorage9_2D(TextureStorage *storage);
+
+ IDirect3DSurface9 *getSurfaceLevel(int level, bool dirty);
+ virtual RenderTarget *getRenderTarget();
+ virtual IDirect3DBaseTexture9 *getBaseTexture() const;
+ virtual void generateMipmap(int level);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(TextureStorage9_2D);
+
+ void initializeRenderTarget();
+
+ IDirect3DTexture9 *mTexture;
+ RenderTarget9 *mRenderTarget;
+};
+
+class TextureStorage9_Cube : public TextureStorage9
+{
+ public:
+ TextureStorage9_Cube(Renderer *renderer, int levels, GLenum internalformat, GLenum usage, bool forceRenderable, int size);
+ virtual ~TextureStorage9_Cube();
+
+ static TextureStorage9_Cube *makeTextureStorage9_Cube(TextureStorage *storage);
+
+ IDirect3DSurface9 *getCubeMapSurface(GLenum faceTarget, int level, bool dirty);
+ virtual RenderTarget *getRenderTarget(GLenum faceTarget);
+ virtual IDirect3DBaseTexture9 *getBaseTexture() const;
+ virtual void generateMipmap(int face, int level);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(TextureStorage9_Cube);
+
+ void initializeRenderTarget();
+
+ IDirect3DCubeTexture9 *mTexture;
+ RenderTarget9 *mRenderTarget[6];
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_TEXTURESTORAGE9_H_
+
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer.cpp
new file mode 100644
index 0000000000..16e1486511
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer.cpp
@@ -0,0 +1,229 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// VertexBuffer.cpp: Defines the abstract VertexBuffer class and VertexBufferInterface
+// class with derivations, classes that perform graphics API agnostic vertex buffer operations.
+
+#include "libGLESv2/renderer/VertexBuffer.h"
+#include "libGLESv2/renderer/Renderer.h"
+#include "libGLESv2/Context.h"
+
+namespace rx
+{
+
+unsigned int VertexBuffer::mNextSerial = 1;
+
+VertexBuffer::VertexBuffer()
+{
+ updateSerial();
+}
+
+VertexBuffer::~VertexBuffer()
+{
+}
+
+void VertexBuffer::updateSerial()
+{
+ mSerial = mNextSerial++;
+}
+
+unsigned int VertexBuffer::getSerial() const
+{
+ return mSerial;
+}
+
+VertexBufferInterface::VertexBufferInterface(rx::Renderer *renderer, bool dynamic) : mRenderer(renderer)
+{
+ mDynamic = dynamic;
+ mWritePosition = 0;
+ mReservedSpace = 0;
+
+ mVertexBuffer = renderer->createVertexBuffer();
+}
+
+VertexBufferInterface::~VertexBufferInterface()
+{
+ delete mVertexBuffer;
+}
+
+unsigned int VertexBufferInterface::getSerial() const
+{
+ return mVertexBuffer->getSerial();
+}
+
+unsigned int VertexBufferInterface::getBufferSize() const
+{
+ return mVertexBuffer->getBufferSize();
+}
+
+bool VertexBufferInterface::setBufferSize(unsigned int size)
+{
+ if (mVertexBuffer->getBufferSize() == 0)
+ {
+ return mVertexBuffer->initialize(size, mDynamic);
+ }
+ else
+ {
+ return mVertexBuffer->setBufferSize(size);
+ }
+}
+
+unsigned int VertexBufferInterface::getWritePosition() const
+{
+ return mWritePosition;
+}
+
+void VertexBufferInterface::setWritePosition(unsigned int writePosition)
+{
+ mWritePosition = writePosition;
+}
+
+bool VertexBufferInterface::discard()
+{
+ return mVertexBuffer->discard();
+}
+
+int VertexBufferInterface::storeVertexAttributes(const gl::VertexAttribute &attrib, GLint start, GLsizei count, GLsizei instances)
+{
+ if (!reserveSpace(mReservedSpace))
+ {
+ return -1;
+ }
+ mReservedSpace = 0;
+
+ if (!mVertexBuffer->storeVertexAttributes(attrib, start, count, instances, mWritePosition))
+ {
+ return -1;
+ }
+
+ int oldWritePos = static_cast<int>(mWritePosition);
+ mWritePosition += mVertexBuffer->getSpaceRequired(attrib, count, instances);
+
+ return oldWritePos;
+}
+
+int VertexBufferInterface::storeRawData(const void* data, unsigned int size)
+{
+ if (!reserveSpace(mReservedSpace))
+ {
+ return -1;
+ }
+ mReservedSpace = 0;
+
+ if (!mVertexBuffer->storeRawData(data, size, mWritePosition))
+ {
+ return -1;
+ }
+
+ int oldWritePos = static_cast<int>(mWritePosition);
+ mWritePosition += size;
+
+ return oldWritePos;
+}
+
+void VertexBufferInterface::reserveVertexSpace(const gl::VertexAttribute &attribute, GLsizei count, GLsizei instances)
+{
+ mReservedSpace += mVertexBuffer->getSpaceRequired(attribute, count, instances);
+}
+
+void VertexBufferInterface::reserveRawDataSpace(unsigned int size)
+{
+ mReservedSpace += size;
+}
+
+VertexBuffer* VertexBufferInterface::getVertexBuffer() const
+{
+ return mVertexBuffer;
+}
+
+
+StreamingVertexBufferInterface::StreamingVertexBufferInterface(rx::Renderer *renderer, std::size_t initialSize) : VertexBufferInterface(renderer, true)
+{
+ setBufferSize(initialSize);
+}
+
+StreamingVertexBufferInterface::~StreamingVertexBufferInterface()
+{
+}
+
+bool StreamingVertexBufferInterface::reserveSpace(unsigned int size)
+{
+ bool result = true;
+ unsigned int curBufferSize = getBufferSize();
+ if (size > curBufferSize)
+ {
+ result = setBufferSize(std::max(size, 3 * curBufferSize / 2));
+ setWritePosition(0);
+ }
+ else if (getWritePosition() + size > curBufferSize)
+ {
+ if (!discard())
+ {
+ return false;
+ }
+ setWritePosition(0);
+ }
+
+ return result;
+}
+
+StaticVertexBufferInterface::StaticVertexBufferInterface(rx::Renderer *renderer) : VertexBufferInterface(renderer, false)
+{
+}
+
+StaticVertexBufferInterface::~StaticVertexBufferInterface()
+{
+}
+
+int StaticVertexBufferInterface::lookupAttribute(const gl::VertexAttribute &attribute)
+{
+ for (unsigned int element = 0; element < mCache.size(); element++)
+ {
+ if (mCache[element].type == attribute.mType &&
+ mCache[element].size == attribute.mSize &&
+ mCache[element].stride == attribute.stride() &&
+ mCache[element].normalized == attribute.mNormalized)
+ {
+ if (mCache[element].attributeOffset == attribute.mOffset % attribute.stride())
+ {
+ return mCache[element].streamOffset;
+ }
+ }
+ }
+
+ return -1;
+}
+
+bool StaticVertexBufferInterface::reserveSpace(unsigned int size)
+{
+ unsigned int curSize = getBufferSize();
+ if (curSize == 0)
+ {
+ setBufferSize(size);
+ return true;
+ }
+ else if (curSize >= size)
+ {
+ return true;
+ }
+ else
+ {
+ UNREACHABLE(); // Static vertex buffers can't be resized
+ return false;
+ }
+}
+
+int StaticVertexBufferInterface::storeVertexAttributes(const gl::VertexAttribute &attrib, GLint start, GLsizei count, GLsizei instances)
+{
+ int attributeOffset = attrib.mOffset % attrib.stride();
+ VertexElement element = { attrib.mType, attrib.mSize, attrib.stride(), attrib.mNormalized, attributeOffset, getWritePosition() };
+ mCache.push_back(element);
+
+ return VertexBufferInterface::storeVertexAttributes(attrib, start, count, instances);
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer.h b/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer.h
new file mode 100644
index 0000000000..6ecffd0c0b
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer.h
@@ -0,0 +1,138 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// VertexBuffer.h: Defines the abstract VertexBuffer class and VertexBufferInterface
+// class with derivations, classes that perform graphics API agnostic vertex buffer operations.
+
+#ifndef LIBGLESV2_RENDERER_VERTEXBUFFER_H_
+#define LIBGLESV2_RENDERER_VERTEXBUFFER_H_
+
+#include "common/angleutils.h"
+
+namespace gl
+{
+class VertexAttribute;
+}
+
+namespace rx
+{
+class Renderer;
+
+class VertexBuffer
+{
+ public:
+ VertexBuffer();
+ virtual ~VertexBuffer();
+
+ virtual bool initialize(unsigned int size, bool dynamicUsage) = 0;
+
+ virtual bool storeVertexAttributes(const gl::VertexAttribute &attrib, GLint start, GLsizei count,
+ GLsizei instances, unsigned int offset) = 0;
+ virtual bool storeRawData(const void* data, unsigned int size, unsigned int offset) = 0;
+
+ virtual unsigned int getSpaceRequired(const gl::VertexAttribute &attrib, GLsizei count,
+ GLsizei instances) const = 0;
+
+ virtual bool requiresConversion(const gl::VertexAttribute &attrib) const = 0;
+
+ virtual unsigned int getBufferSize() const = 0;
+ virtual bool setBufferSize(unsigned int size) = 0;
+ virtual bool discard() = 0;
+
+ unsigned int getSerial() const;
+
+ protected:
+ void updateSerial();
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(VertexBuffer);
+
+ unsigned int mSerial;
+ static unsigned int mNextSerial;
+};
+
+class VertexBufferInterface
+{
+ public:
+ VertexBufferInterface(rx::Renderer *renderer, bool dynamic);
+ virtual ~VertexBufferInterface();
+
+ void reserveVertexSpace(const gl::VertexAttribute &attribute, GLsizei count, GLsizei instances);
+ void reserveRawDataSpace(unsigned int size);
+
+ unsigned int getBufferSize() const;
+
+ unsigned int getSerial() const;
+
+ virtual int storeVertexAttributes(const gl::VertexAttribute &attrib, GLint start, GLsizei count, GLsizei instances);
+ virtual int storeRawData(const void* data, unsigned int size);
+
+ VertexBuffer* getVertexBuffer() const;
+
+ protected:
+ virtual bool reserveSpace(unsigned int size) = 0;
+
+ unsigned int getWritePosition() const;
+ void setWritePosition(unsigned int writePosition);
+
+ bool discard();
+
+ bool setBufferSize(unsigned int size);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(VertexBufferInterface);
+
+ rx::Renderer *const mRenderer;
+
+ VertexBuffer* mVertexBuffer;
+
+ unsigned int mWritePosition;
+ unsigned int mReservedSpace;
+ bool mDynamic;
+};
+
+class StreamingVertexBufferInterface : public VertexBufferInterface
+{
+ public:
+ StreamingVertexBufferInterface(rx::Renderer *renderer, std::size_t initialSize);
+ ~StreamingVertexBufferInterface();
+
+ protected:
+ bool reserveSpace(unsigned int size);
+};
+
+class StaticVertexBufferInterface : public VertexBufferInterface
+{
+ public:
+ explicit StaticVertexBufferInterface(rx::Renderer *renderer);
+ ~StaticVertexBufferInterface();
+
+ int storeVertexAttributes(const gl::VertexAttribute &attrib, GLint start, GLsizei count, GLsizei instances);
+
+ // Returns the offset into the vertex buffer, or -1 if not found
+ int lookupAttribute(const gl::VertexAttribute &attribute);
+
+ protected:
+ bool reserveSpace(unsigned int size);
+
+ private:
+ struct VertexElement
+ {
+ GLenum type;
+ GLint size;
+ GLsizei stride;
+ bool normalized;
+ int attributeOffset;
+
+ unsigned int streamOffset;
+ };
+
+ std::vector<VertexElement> mCache;
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_VERTEXBUFFER_H_ \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer11.cpp
new file mode 100644
index 0000000000..92c8755e22
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer11.cpp
@@ -0,0 +1,418 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2013 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// VertexBuffer11.cpp: Defines the D3D11 VertexBuffer implementation.
+
+#include "libGLESv2/renderer/VertexBuffer11.h"
+#include "libGLESv2/renderer/BufferStorage.h"
+
+#include "libGLESv2/Buffer.h"
+#include "libGLESv2/renderer/Renderer11.h"
+#include "libGLESv2/Context.h"
+
+namespace rx
+{
+
+VertexBuffer11::VertexBuffer11(rx::Renderer11 *const renderer) : mRenderer(renderer)
+{
+ mBuffer = NULL;
+ mBufferSize = 0;
+ mDynamicUsage = false;
+}
+
+VertexBuffer11::~VertexBuffer11()
+{
+ if (mBuffer)
+ {
+ mBuffer->Release();
+ mBuffer = NULL;
+ }
+}
+
+bool VertexBuffer11::initialize(unsigned int size, bool dynamicUsage)
+{
+ if (mBuffer)
+ {
+ mBuffer->Release();
+ mBuffer = NULL;
+ }
+
+ updateSerial();
+
+ if (size > 0)
+ {
+ ID3D11Device* dxDevice = mRenderer->getDevice();
+
+ D3D11_BUFFER_DESC bufferDesc;
+ bufferDesc.ByteWidth = size;
+ bufferDesc.Usage = D3D11_USAGE_DYNAMIC;
+ bufferDesc.BindFlags = D3D11_BIND_VERTEX_BUFFER;
+ bufferDesc.CPUAccessFlags = D3D11_CPU_ACCESS_WRITE;
+ bufferDesc.MiscFlags = 0;
+ bufferDesc.StructureByteStride = 0;
+
+ HRESULT result = dxDevice->CreateBuffer(&bufferDesc, NULL, &mBuffer);
+ if (FAILED(result))
+ {
+ return false;
+ }
+ }
+
+ mBufferSize = size;
+ mDynamicUsage = dynamicUsage;
+ return true;
+}
+
+VertexBuffer11 *VertexBuffer11::makeVertexBuffer11(VertexBuffer *vetexBuffer)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(VertexBuffer11*, vetexBuffer));
+ return static_cast<VertexBuffer11*>(vetexBuffer);
+}
+
+bool VertexBuffer11::storeVertexAttributes(const gl::VertexAttribute &attrib, GLint start, GLsizei count,
+ GLsizei instances, unsigned int offset)
+{
+ if (mBuffer)
+ {
+ gl::Buffer *buffer = attrib.mBoundBuffer.get();
+
+ int inputStride = attrib.stride();
+ const VertexConverter &converter = getVertexConversion(attrib);
+
+ ID3D11DeviceContext *dxContext = mRenderer->getDeviceContext();
+
+ D3D11_MAPPED_SUBRESOURCE mappedResource;
+ HRESULT result = dxContext->Map(mBuffer, 0, D3D11_MAP_WRITE_NO_OVERWRITE, 0, &mappedResource);
+ if (FAILED(result))
+ {
+ ERR("Vertex buffer map failed with error 0x%08x", result);
+ return false;
+ }
+
+ char* output = reinterpret_cast<char*>(mappedResource.pData) + offset;
+
+ const char *input = NULL;
+ if (buffer)
+ {
+ BufferStorage *storage = buffer->getStorage();
+ input = static_cast<const char*>(storage->getData()) + static_cast<int>(attrib.mOffset);
+ }
+ else
+ {
+ input = static_cast<const char*>(attrib.mPointer);
+ }
+
+ if (instances == 0 || attrib.mDivisor == 0)
+ {
+ input += inputStride * start;
+ }
+
+ converter.conversionFunc(input, inputStride, count, output);
+
+ dxContext->Unmap(mBuffer, 0);
+
+ return true;
+ }
+ else
+ {
+ ERR("Vertex buffer not initialized.");
+ return false;
+ }
+}
+
+bool VertexBuffer11::storeRawData(const void* data, unsigned int size, unsigned int offset)
+{
+ if (mBuffer)
+ {
+ ID3D11DeviceContext *dxContext = mRenderer->getDeviceContext();
+
+ D3D11_MAPPED_SUBRESOURCE mappedResource;
+ HRESULT result = dxContext->Map(mBuffer, 0, D3D11_MAP_WRITE_NO_OVERWRITE, 0, &mappedResource);
+ if (FAILED(result))
+ {
+ ERR("Vertex buffer map failed with error 0x%08x", result);
+ return false;
+ }
+
+ char* bufferData = static_cast<char*>(mappedResource.pData);
+ memcpy(bufferData + offset, data, size);
+
+ dxContext->Unmap(mBuffer, 0);
+
+ return true;
+ }
+ else
+ {
+ ERR("Vertex buffer not initialized.");
+ return false;
+ }
+}
+
+unsigned int VertexBuffer11::getSpaceRequired(const gl::VertexAttribute &attrib, GLsizei count,
+ GLsizei instances) const
+{
+ unsigned int elementSize = getVertexConversion(attrib).outputElementSize;
+
+ if (instances == 0 || attrib.mDivisor == 0)
+ {
+ return elementSize * count;
+ }
+ else
+ {
+ return elementSize * ((instances + attrib.mDivisor - 1) / attrib.mDivisor);
+ }
+}
+
+bool VertexBuffer11::requiresConversion(const gl::VertexAttribute &attrib) const
+{
+ return !getVertexConversion(attrib).identity;
+}
+
+unsigned int VertexBuffer11::getBufferSize() const
+{
+ return mBufferSize;
+}
+
+bool VertexBuffer11::setBufferSize(unsigned int size)
+{
+ if (size > mBufferSize)
+ {
+ return initialize(size, mDynamicUsage);
+ }
+ else
+ {
+ return true;
+ }
+}
+
+bool VertexBuffer11::discard()
+{
+ if (mBuffer)
+ {
+ ID3D11DeviceContext *dxContext = mRenderer->getDeviceContext();
+
+ D3D11_MAPPED_SUBRESOURCE mappedResource;
+ HRESULT result = dxContext->Map(mBuffer, 0, D3D11_MAP_WRITE_DISCARD, 0, &mappedResource);
+ if (FAILED(result))
+ {
+ ERR("Vertex buffer map failed with error 0x%08x", result);
+ return false;
+ }
+
+ dxContext->Unmap(mBuffer, 0);
+
+ return true;
+ }
+ else
+ {
+ ERR("Vertex buffer not initialized.");
+ return false;
+ }
+}
+
+unsigned int VertexBuffer11::getVertexSize(const gl::VertexAttribute &attrib) const
+{
+ return getVertexConversion(attrib).outputElementSize;
+}
+
+DXGI_FORMAT VertexBuffer11::getDXGIFormat(const gl::VertexAttribute &attrib) const
+{
+ return getVertexConversion(attrib).dxgiFormat;
+}
+
+ID3D11Buffer *VertexBuffer11::getBuffer() const
+{
+ return mBuffer;
+}
+
+template <typename T, unsigned int componentCount, bool widen, bool normalized>
+static void copyVertexData(const void *input, unsigned int stride, unsigned int count, void *output)
+{
+ unsigned int attribSize = sizeof(T) * componentCount;
+
+ if (attribSize == stride && !widen)
+ {
+ memcpy(output, input, count * attribSize);
+ }
+ else
+ {
+ unsigned int outputStride = widen ? 4 : componentCount;
+ T defaultVal = normalized ? std::numeric_limits<T>::max() : T(1);
+
+ for (unsigned int i = 0; i < count; i++)
+ {
+ const T *offsetInput = reinterpret_cast<const T*>(reinterpret_cast<const char*>(input) + i * stride);
+ T *offsetOutput = reinterpret_cast<T*>(output) + i * outputStride;
+
+ for (unsigned int j = 0; j < componentCount; j++)
+ {
+ offsetOutput[j] = offsetInput[j];
+ }
+
+ if (widen)
+ {
+ offsetOutput[3] = defaultVal;
+ }
+ }
+ }
+}
+
+template <unsigned int componentCount>
+static void copyFixedVertexData(const void* input, unsigned int stride, unsigned int count, void* output)
+{
+ static const float divisor = 1.0f / (1 << 16);
+
+ for (unsigned int i = 0; i < count; i++)
+ {
+ const GLfixed* offsetInput = reinterpret_cast<const GLfixed*>(reinterpret_cast<const char*>(input) + stride * i);
+ float* offsetOutput = reinterpret_cast<float*>(output) + i * componentCount;
+
+ for (unsigned int j = 0; j < componentCount; j++)
+ {
+ offsetOutput[j] = static_cast<float>(offsetInput[j]) * divisor;
+ }
+ }
+}
+
+template <typename T, unsigned int componentCount, bool normalized>
+static void copyToFloatVertexData(const void* input, unsigned int stride, unsigned int count, void* output)
+{
+ typedef std::numeric_limits<T> NL;
+
+ for (unsigned int i = 0; i < count; i++)
+ {
+ const T *offsetInput = reinterpret_cast<const T*>(reinterpret_cast<const char*>(input) + stride * i);
+ float *offsetOutput = reinterpret_cast<float*>(output) + i * componentCount;
+
+ for (unsigned int j = 0; j < componentCount; j++)
+ {
+ if (normalized)
+ {
+ if (NL::is_signed)
+ {
+ const float divisor = 1.0f / (2 * static_cast<float>(NL::max()) + 1);
+ offsetOutput[j] = (2 * static_cast<float>(offsetInput[j]) + 1) * divisor;
+ }
+ else
+ {
+ offsetOutput[j] = static_cast<float>(offsetInput[j]) / NL::max();
+ }
+ }
+ else
+ {
+ offsetOutput[j] = static_cast<float>(offsetInput[j]);
+ }
+ }
+ }
+}
+
+const VertexBuffer11::VertexConverter VertexBuffer11::mPossibleTranslations[NUM_GL_VERTEX_ATTRIB_TYPES][2][4] =
+{
+ { // GL_BYTE
+ { // unnormalized
+ { &copyToFloatVertexData<GLbyte, 1, false>, false, DXGI_FORMAT_R32_FLOAT, 4 },
+ { &copyToFloatVertexData<GLbyte, 2, false>, false, DXGI_FORMAT_R32G32_FLOAT, 8 },
+ { &copyToFloatVertexData<GLbyte, 3, false>, false, DXGI_FORMAT_R32G32B32_FLOAT, 12 },
+ { &copyToFloatVertexData<GLbyte, 4, false>, false, DXGI_FORMAT_R32G32B32A32_FLOAT, 16 },
+ },
+ { // normalized
+ { &copyVertexData<GLbyte, 1, false, true>, true, DXGI_FORMAT_R8_SNORM, 1 },
+ { &copyVertexData<GLbyte, 2, false, true>, true, DXGI_FORMAT_R8G8_SNORM, 2 },
+ { &copyVertexData<GLbyte, 3, true, true>, false, DXGI_FORMAT_R8G8B8A8_SNORM, 4 },
+ { &copyVertexData<GLbyte, 4, false, true>, true, DXGI_FORMAT_R8G8B8A8_SNORM, 4 },
+ },
+ },
+ { // GL_UNSIGNED_BYTE
+ { // unnormalized
+ { &copyToFloatVertexData<GLubyte, 1, false>, false, DXGI_FORMAT_R32_FLOAT, 4 },
+ { &copyToFloatVertexData<GLubyte, 2, false>, false, DXGI_FORMAT_R32G32_FLOAT, 8 },
+ { &copyToFloatVertexData<GLubyte, 3, false>, false, DXGI_FORMAT_R32G32B32_FLOAT, 12 },
+ { &copyToFloatVertexData<GLubyte, 4, false>, false, DXGI_FORMAT_R32G32B32A32_FLOAT, 16 },
+ },
+ { // normalized
+ { &copyVertexData<GLubyte, 1, false, true>, true, DXGI_FORMAT_R8_UNORM, 1 },
+ { &copyVertexData<GLubyte, 2, false, true>, true, DXGI_FORMAT_R8G8_UNORM, 2 },
+ { &copyVertexData<GLubyte, 3, true, true>, false, DXGI_FORMAT_R8G8B8A8_UNORM, 4 },
+ { &copyVertexData<GLubyte, 4, false, true>, true, DXGI_FORMAT_R8G8B8A8_UNORM, 4 },
+ },
+ },
+ { // GL_SHORT
+ { // unnormalized
+ { &copyToFloatVertexData<GLshort, 1, false>, false, DXGI_FORMAT_R32_FLOAT, 4 },
+ { &copyToFloatVertexData<GLshort, 2, false>, false, DXGI_FORMAT_R32G32_FLOAT, 8 },
+ { &copyToFloatVertexData<GLshort, 3, false>, false, DXGI_FORMAT_R32G32B32_FLOAT, 12 },
+ { &copyToFloatVertexData<GLshort, 4, false>, false, DXGI_FORMAT_R32G32B32A32_FLOAT, 16 },
+ },
+ { // normalized
+ { &copyVertexData<GLshort, 1, false, true>, true, DXGI_FORMAT_R16_SNORM, 2 },
+ { &copyVertexData<GLshort, 2, false, true>, true, DXGI_FORMAT_R16G16_SNORM, 4 },
+ { &copyVertexData<GLshort, 3, true, true>, false, DXGI_FORMAT_R16G16B16A16_SNORM, 8 },
+ { &copyVertexData<GLshort, 4, false, true>, true, DXGI_FORMAT_R16G16B16A16_SNORM, 8 },
+ },
+ },
+ { // GL_UNSIGNED_SHORT
+ { // unnormalized
+ { &copyToFloatVertexData<GLushort, 1, false>, false, DXGI_FORMAT_R32_FLOAT, 4 },
+ { &copyToFloatVertexData<GLushort, 2, false>, false, DXGI_FORMAT_R32G32_FLOAT, 8 },
+ { &copyToFloatVertexData<GLushort, 3, false>, false, DXGI_FORMAT_R32G32B32_FLOAT, 12 },
+ { &copyToFloatVertexData<GLushort, 4, false>, false, DXGI_FORMAT_R32G32B32A32_FLOAT, 16 },
+ },
+ { // normalized
+ { &copyVertexData<GLushort, 1, false, true>, true, DXGI_FORMAT_R16_UNORM, 2 },
+ { &copyVertexData<GLushort, 2, false, true>, true, DXGI_FORMAT_R16G16_UNORM, 4 },
+ { &copyVertexData<GLushort, 3, true, true>, false, DXGI_FORMAT_R16G16B16A16_UNORM, 8 },
+ { &copyVertexData<GLushort, 4, false, true>, true, DXGI_FORMAT_R16G16B16A16_UNORM, 8 },
+ },
+ },
+ { // GL_FIXED
+ { // unnormalized
+ { &copyFixedVertexData<1>, false, DXGI_FORMAT_R32_FLOAT, 4 },
+ { &copyFixedVertexData<2>, false, DXGI_FORMAT_R32G32_FLOAT, 8 },
+ { &copyFixedVertexData<3>, false, DXGI_FORMAT_R32G32B32_FLOAT, 12 },
+ { &copyFixedVertexData<4>, false, DXGI_FORMAT_R32G32B32A32_FLOAT, 16 },
+ },
+ { // normalized
+ { &copyFixedVertexData<1>, false, DXGI_FORMAT_R32_FLOAT, 4 },
+ { &copyFixedVertexData<2>, false, DXGI_FORMAT_R32G32_FLOAT, 8 },
+ { &copyFixedVertexData<3>, false, DXGI_FORMAT_R32G32B32_FLOAT, 12 },
+ { &copyFixedVertexData<4>, false, DXGI_FORMAT_R32G32B32A32_FLOAT, 16 },
+ },
+ },
+ { // GL_FLOAT
+ { // unnormalized
+ { &copyVertexData<GLfloat, 1, false, false>, true, DXGI_FORMAT_R32_FLOAT, 4 },
+ { &copyVertexData<GLfloat, 2, false, false>, true, DXGI_FORMAT_R32G32_FLOAT, 8 },
+ { &copyVertexData<GLfloat, 3, false, false>, true, DXGI_FORMAT_R32G32B32_FLOAT, 12 },
+ { &copyVertexData<GLfloat, 4, false, false>, true, DXGI_FORMAT_R32G32B32A32_FLOAT, 16 },
+ },
+ { // normalized
+ { &copyVertexData<GLfloat, 1, false, false>, true, DXGI_FORMAT_R32_FLOAT, 4 },
+ { &copyVertexData<GLfloat, 2, false, false>, true, DXGI_FORMAT_R32G32_FLOAT, 8 },
+ { &copyVertexData<GLfloat, 3, false, false>, true, DXGI_FORMAT_R32G32B32_FLOAT, 12 },
+ { &copyVertexData<GLfloat, 4, false, false>, true, DXGI_FORMAT_R32G32B32A32_FLOAT, 16 },
+ },
+ },
+};
+
+const VertexBuffer11::VertexConverter &VertexBuffer11::getVertexConversion(const gl::VertexAttribute &attribute)
+{
+ unsigned int typeIndex = 0;
+ switch (attribute.mType)
+ {
+ case GL_BYTE: typeIndex = 0; break;
+ case GL_UNSIGNED_BYTE: typeIndex = 1; break;
+ case GL_SHORT: typeIndex = 2; break;
+ case GL_UNSIGNED_SHORT: typeIndex = 3; break;
+ case GL_FIXED: typeIndex = 4; break;
+ case GL_FLOAT: typeIndex = 5; break;
+ default: UNREACHABLE(); break;
+ }
+
+ return mPossibleTranslations[typeIndex][attribute.mNormalized ? 1 : 0][attribute.mSize - 1];
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer11.h b/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer11.h
new file mode 100644
index 0000000000..75e025075e
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer11.h
@@ -0,0 +1,73 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// VertexBuffer11.h: Defines the D3D11 VertexBuffer implementation.
+
+#ifndef LIBGLESV2_RENDERER_VERTEXBUFFER11_H_
+#define LIBGLESV2_RENDERER_VERTEXBUFFER11_H_
+
+#include "libGLESv2/renderer/VertexBuffer.h"
+
+namespace rx
+{
+class Renderer11;
+
+class VertexBuffer11 : public VertexBuffer
+{
+ public:
+ explicit VertexBuffer11(rx::Renderer11 *const renderer);
+ virtual ~VertexBuffer11();
+
+ virtual bool initialize(unsigned int size, bool dynamicUsage);
+
+ static VertexBuffer11 *makeVertexBuffer11(VertexBuffer *vetexBuffer);
+
+ virtual bool storeVertexAttributes(const gl::VertexAttribute &attrib, GLint start, GLsizei count, GLsizei instances,
+ unsigned int offset);
+ virtual bool storeRawData(const void* data, unsigned int size, unsigned int offset);
+
+ virtual unsigned int getSpaceRequired(const gl::VertexAttribute &attrib, GLsizei count, GLsizei instances) const;
+
+ virtual bool requiresConversion(const gl::VertexAttribute &attrib) const;
+
+ virtual unsigned int getBufferSize() const;
+ virtual bool setBufferSize(unsigned int size);
+ virtual bool discard();
+
+ unsigned int getVertexSize(const gl::VertexAttribute &attrib) const;
+ DXGI_FORMAT getDXGIFormat(const gl::VertexAttribute &attrib) const;
+
+ ID3D11Buffer *getBuffer() const;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(VertexBuffer11);
+
+ rx::Renderer11 *const mRenderer;
+
+ ID3D11Buffer *mBuffer;
+ unsigned int mBufferSize;
+ bool mDynamicUsage;
+
+ typedef void (*VertexConversionFunction)(const void *, unsigned int, unsigned int, void *);
+ struct VertexConverter
+ {
+ VertexConversionFunction conversionFunc;
+ bool identity;
+ DXGI_FORMAT dxgiFormat;
+ unsigned int outputElementSize;
+ };
+
+ enum { NUM_GL_VERTEX_ATTRIB_TYPES = 6 };
+
+ // This table is used to generate mAttributeTypes.
+ static const VertexConverter mPossibleTranslations[NUM_GL_VERTEX_ATTRIB_TYPES][2][4]; // [GL types as enumerated by typeIndex()][normalized][size - 1]
+
+ static const VertexConverter &getVertexConversion(const gl::VertexAttribute &attribute);
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_VERTEXBUFFER11_H_ \ No newline at end of file
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer9.cpp
new file mode 100644
index 0000000000..76dc73e391
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer9.cpp
@@ -0,0 +1,486 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// VertexBuffer9.cpp: Defines the D3D9 VertexBuffer implementation.
+
+#include "libGLESv2/renderer/VertexBuffer9.h"
+#include "libGLESv2/renderer/vertexconversion.h"
+#include "libGLESv2/renderer/BufferStorage.h"
+#include "libGLESv2/Context.h"
+#include "libGLESv2/renderer/Renderer9.h"
+
+#include "libGLESv2/Buffer.h"
+
+namespace rx
+{
+
+bool VertexBuffer9::mTranslationsInitialized = false;
+VertexBuffer9::FormatConverter VertexBuffer9::mFormatConverters[NUM_GL_VERTEX_ATTRIB_TYPES][2][4];
+
+VertexBuffer9::VertexBuffer9(rx::Renderer9 *const renderer) : mRenderer(renderer)
+{
+ mVertexBuffer = NULL;
+ mBufferSize = 0;
+ mDynamicUsage = false;
+
+ if (!mTranslationsInitialized)
+ {
+ initializeTranslations(renderer->getCapsDeclTypes());
+ mTranslationsInitialized = true;
+ }
+}
+
+VertexBuffer9::~VertexBuffer9()
+{
+ if (mVertexBuffer)
+ {
+ mVertexBuffer->Release();
+ mVertexBuffer = NULL;
+ }
+}
+
+bool VertexBuffer9::initialize(unsigned int size, bool dynamicUsage)
+{
+ if (mVertexBuffer)
+ {
+ mVertexBuffer->Release();
+ mVertexBuffer = NULL;
+ }
+
+ updateSerial();
+
+ if (size > 0)
+ {
+ DWORD flags = D3DUSAGE_WRITEONLY;
+ if (dynamicUsage)
+ {
+ flags |= D3DUSAGE_DYNAMIC;
+ }
+
+ HRESULT result = mRenderer->createVertexBuffer(size, flags, &mVertexBuffer);
+
+ if (FAILED(result))
+ {
+ ERR("Out of memory allocating a vertex buffer of size %lu.", size);
+ return false;
+ }
+ }
+
+ mBufferSize = size;
+ mDynamicUsage = dynamicUsage;
+ return true;
+}
+
+VertexBuffer9 *VertexBuffer9::makeVertexBuffer9(VertexBuffer *vertexBuffer)
+{
+ ASSERT(HAS_DYNAMIC_TYPE(VertexBuffer9*, vertexBuffer));
+ return static_cast<VertexBuffer9*>(vertexBuffer);
+}
+
+bool VertexBuffer9::storeVertexAttributes(const gl::VertexAttribute &attrib, GLint start, GLsizei count,
+ GLsizei instances, unsigned int offset)
+{
+ if (mVertexBuffer)
+ {
+ gl::Buffer *buffer = attrib.mBoundBuffer.get();
+
+ int inputStride = attrib.stride();
+ int elementSize = attrib.typeSize();
+ const FormatConverter &converter = formatConverter(attrib);
+
+ DWORD lockFlags = mDynamicUsage ? D3DLOCK_NOOVERWRITE : 0;
+
+ void *mapPtr = NULL;
+ HRESULT result = mVertexBuffer->Lock(offset, spaceRequired(attrib, count, instances), &mapPtr, lockFlags);
+
+ if (FAILED(result))
+ {
+ ERR("Lock failed with error 0x%08x", result);
+ return false;
+ }
+
+ const char *input = NULL;
+ if (buffer)
+ {
+ BufferStorage *storage = buffer->getStorage();
+ input = static_cast<const char*>(storage->getData()) + static_cast<int>(attrib.mOffset);
+ }
+ else
+ {
+ input = static_cast<const char*>(attrib.mPointer);
+ }
+
+ if (instances == 0 || attrib.mDivisor == 0)
+ {
+ input += inputStride * start;
+ }
+
+ if (converter.identity && inputStride == elementSize)
+ {
+ memcpy(mapPtr, input, count * inputStride);
+ }
+ else
+ {
+ converter.convertArray(input, inputStride, count, mapPtr);
+ }
+
+ mVertexBuffer->Unlock();
+
+ return true;
+ }
+ else
+ {
+ ERR("Vertex buffer not initialized.");
+ return false;
+ }
+}
+
+bool VertexBuffer9::storeRawData(const void* data, unsigned int size, unsigned int offset)
+{
+ if (mVertexBuffer)
+ {
+ DWORD lockFlags = mDynamicUsage ? D3DLOCK_NOOVERWRITE : 0;
+
+ void *mapPtr = NULL;
+ HRESULT result = mVertexBuffer->Lock(offset, size, &mapPtr, lockFlags);
+
+ if (FAILED(result))
+ {
+ ERR("Lock failed with error 0x%08x", result);
+ return false;
+ }
+
+ memcpy(mapPtr, data, size);
+
+ mVertexBuffer->Unlock();
+
+ return true;
+ }
+ else
+ {
+ ERR("Vertex buffer not initialized.");
+ return false;
+ }
+}
+
+unsigned int VertexBuffer9::getSpaceRequired(const gl::VertexAttribute &attrib, GLsizei count, GLsizei instances) const
+{
+ return spaceRequired(attrib, count, instances);
+}
+
+bool VertexBuffer9::requiresConversion(const gl::VertexAttribute &attrib) const
+{
+ return formatConverter(attrib).identity;
+}
+
+unsigned int VertexBuffer9::getVertexSize(const gl::VertexAttribute &attrib) const
+{
+ return spaceRequired(attrib, 1, 0);
+}
+
+D3DDECLTYPE VertexBuffer9::getDeclType(const gl::VertexAttribute &attrib) const
+{
+ return formatConverter(attrib).d3dDeclType;
+}
+
+unsigned int VertexBuffer9::getBufferSize() const
+{
+ return mBufferSize;
+}
+
+bool VertexBuffer9::setBufferSize(unsigned int size)
+{
+ if (size > mBufferSize)
+ {
+ return initialize(size, mDynamicUsage);
+ }
+ else
+ {
+ return true;
+ }
+}
+
+bool VertexBuffer9::discard()
+{
+ if (mVertexBuffer)
+ {
+ void *dummy;
+ HRESULT result;
+
+ result = mVertexBuffer->Lock(0, 1, &dummy, D3DLOCK_DISCARD);
+ if (FAILED(result))
+ {
+ ERR("Discard lock failed with error 0x%08x", result);
+ return false;
+ }
+
+ result = mVertexBuffer->Unlock();
+ if (FAILED(result))
+ {
+ ERR("Discard unlock failed with error 0x%08x", result);
+ return false;
+ }
+
+ return true;
+ }
+ else
+ {
+ ERR("Vertex buffer not initialized.");
+ return false;
+ }
+}
+
+IDirect3DVertexBuffer9 * VertexBuffer9::getBuffer() const
+{
+ return mVertexBuffer;
+}
+
+// Mapping from OpenGL-ES vertex attrib type to D3D decl type:
+//
+// BYTE SHORT (Cast)
+// BYTE-norm FLOAT (Normalize) (can't be exactly represented as SHORT-norm)
+// UNSIGNED_BYTE UBYTE4 (Identity) or SHORT (Cast)
+// UNSIGNED_BYTE-norm UBYTE4N (Identity) or FLOAT (Normalize)
+// SHORT SHORT (Identity)
+// SHORT-norm SHORT-norm (Identity) or FLOAT (Normalize)
+// UNSIGNED_SHORT FLOAT (Cast)
+// UNSIGNED_SHORT-norm USHORT-norm (Identity) or FLOAT (Normalize)
+// FIXED (not in WebGL) FLOAT (FixedToFloat)
+// FLOAT FLOAT (Identity)
+
+// GLToCType maps from GL type (as GLenum) to the C typedef.
+template <GLenum GLType> struct GLToCType { };
+
+template <> struct GLToCType<GL_BYTE> { typedef GLbyte type; };
+template <> struct GLToCType<GL_UNSIGNED_BYTE> { typedef GLubyte type; };
+template <> struct GLToCType<GL_SHORT> { typedef GLshort type; };
+template <> struct GLToCType<GL_UNSIGNED_SHORT> { typedef GLushort type; };
+template <> struct GLToCType<GL_FIXED> { typedef GLuint type; };
+template <> struct GLToCType<GL_FLOAT> { typedef GLfloat type; };
+
+// This differs from D3DDECLTYPE in that it is unsized. (Size expansion is applied last.)
+enum D3DVertexType
+{
+ D3DVT_FLOAT,
+ D3DVT_SHORT,
+ D3DVT_SHORT_NORM,
+ D3DVT_UBYTE,
+ D3DVT_UBYTE_NORM,
+ D3DVT_USHORT_NORM
+};
+
+// D3DToCType maps from D3D vertex type (as enum D3DVertexType) to the corresponding C type.
+template <unsigned int D3DType> struct D3DToCType { };
+
+template <> struct D3DToCType<D3DVT_FLOAT> { typedef float type; };
+template <> struct D3DToCType<D3DVT_SHORT> { typedef short type; };
+template <> struct D3DToCType<D3DVT_SHORT_NORM> { typedef short type; };
+template <> struct D3DToCType<D3DVT_UBYTE> { typedef unsigned char type; };
+template <> struct D3DToCType<D3DVT_UBYTE_NORM> { typedef unsigned char type; };
+template <> struct D3DToCType<D3DVT_USHORT_NORM> { typedef unsigned short type; };
+
+// Encode the type/size combinations that D3D permits. For each type/size it expands to a widener that will provide the appropriate final size.
+template <unsigned int type, int size> struct WidenRule { };
+
+template <int size> struct WidenRule<D3DVT_FLOAT, size> : NoWiden<size> { };
+template <int size> struct WidenRule<D3DVT_SHORT, size> : WidenToEven<size> { };
+template <int size> struct WidenRule<D3DVT_SHORT_NORM, size> : WidenToEven<size> { };
+template <int size> struct WidenRule<D3DVT_UBYTE, size> : WidenToFour<size> { };
+template <int size> struct WidenRule<D3DVT_UBYTE_NORM, size> : WidenToFour<size> { };
+template <int size> struct WidenRule<D3DVT_USHORT_NORM, size> : WidenToEven<size> { };
+
+// VertexTypeFlags encodes the D3DCAPS9::DeclType flag and vertex declaration flag for each D3D vertex type & size combination.
+template <unsigned int d3dtype, int size> struct VertexTypeFlags { };
+
+template <unsigned int _capflag, unsigned int _declflag>
+struct VertexTypeFlagsHelper
+{
+ enum { capflag = _capflag };
+ enum { declflag = _declflag };
+};
+
+template <> struct VertexTypeFlags<D3DVT_FLOAT, 1> : VertexTypeFlagsHelper<0, D3DDECLTYPE_FLOAT1> { };
+template <> struct VertexTypeFlags<D3DVT_FLOAT, 2> : VertexTypeFlagsHelper<0, D3DDECLTYPE_FLOAT2> { };
+template <> struct VertexTypeFlags<D3DVT_FLOAT, 3> : VertexTypeFlagsHelper<0, D3DDECLTYPE_FLOAT3> { };
+template <> struct VertexTypeFlags<D3DVT_FLOAT, 4> : VertexTypeFlagsHelper<0, D3DDECLTYPE_FLOAT4> { };
+template <> struct VertexTypeFlags<D3DVT_SHORT, 2> : VertexTypeFlagsHelper<0, D3DDECLTYPE_SHORT2> { };
+template <> struct VertexTypeFlags<D3DVT_SHORT, 4> : VertexTypeFlagsHelper<0, D3DDECLTYPE_SHORT4> { };
+template <> struct VertexTypeFlags<D3DVT_SHORT_NORM, 2> : VertexTypeFlagsHelper<D3DDTCAPS_SHORT2N, D3DDECLTYPE_SHORT2N> { };
+template <> struct VertexTypeFlags<D3DVT_SHORT_NORM, 4> : VertexTypeFlagsHelper<D3DDTCAPS_SHORT4N, D3DDECLTYPE_SHORT4N> { };
+template <> struct VertexTypeFlags<D3DVT_UBYTE, 4> : VertexTypeFlagsHelper<D3DDTCAPS_UBYTE4, D3DDECLTYPE_UBYTE4> { };
+template <> struct VertexTypeFlags<D3DVT_UBYTE_NORM, 4> : VertexTypeFlagsHelper<D3DDTCAPS_UBYTE4N, D3DDECLTYPE_UBYTE4N> { };
+template <> struct VertexTypeFlags<D3DVT_USHORT_NORM, 2> : VertexTypeFlagsHelper<D3DDTCAPS_USHORT2N, D3DDECLTYPE_USHORT2N> { };
+template <> struct VertexTypeFlags<D3DVT_USHORT_NORM, 4> : VertexTypeFlagsHelper<D3DDTCAPS_USHORT4N, D3DDECLTYPE_USHORT4N> { };
+
+
+// VertexTypeMapping maps GL type & normalized flag to preferred and fallback D3D vertex types (as D3DVertexType enums).
+template <GLenum GLtype, bool normalized> struct VertexTypeMapping { };
+
+template <D3DVertexType Preferred, D3DVertexType Fallback = Preferred>
+struct VertexTypeMappingBase
+{
+ enum { preferred = Preferred };
+ enum { fallback = Fallback };
+};
+
+template <> struct VertexTypeMapping<GL_BYTE, false> : VertexTypeMappingBase<D3DVT_SHORT> { }; // Cast
+template <> struct VertexTypeMapping<GL_BYTE, true> : VertexTypeMappingBase<D3DVT_FLOAT> { }; // Normalize
+template <> struct VertexTypeMapping<GL_UNSIGNED_BYTE, false> : VertexTypeMappingBase<D3DVT_UBYTE, D3DVT_FLOAT> { }; // Identity, Cast
+template <> struct VertexTypeMapping<GL_UNSIGNED_BYTE, true> : VertexTypeMappingBase<D3DVT_UBYTE_NORM, D3DVT_FLOAT> { }; // Identity, Normalize
+template <> struct VertexTypeMapping<GL_SHORT, false> : VertexTypeMappingBase<D3DVT_SHORT> { }; // Identity
+template <> struct VertexTypeMapping<GL_SHORT, true> : VertexTypeMappingBase<D3DVT_SHORT_NORM, D3DVT_FLOAT> { }; // Cast, Normalize
+template <> struct VertexTypeMapping<GL_UNSIGNED_SHORT, false> : VertexTypeMappingBase<D3DVT_FLOAT> { }; // Cast
+template <> struct VertexTypeMapping<GL_UNSIGNED_SHORT, true> : VertexTypeMappingBase<D3DVT_USHORT_NORM, D3DVT_FLOAT> { }; // Cast, Normalize
+template <bool normalized> struct VertexTypeMapping<GL_FIXED, normalized> : VertexTypeMappingBase<D3DVT_FLOAT> { }; // FixedToFloat
+template <bool normalized> struct VertexTypeMapping<GL_FLOAT, normalized> : VertexTypeMappingBase<D3DVT_FLOAT> { }; // Identity
+
+
+// Given a GL type & norm flag and a D3D type, ConversionRule provides the type conversion rule (Cast, Normalize, Identity, FixedToFloat).
+// The conversion rules themselves are defined in vertexconversion.h.
+
+// Almost all cases are covered by Cast (including those that are actually Identity since Cast<T,T> knows it's an identity mapping).
+template <GLenum fromType, bool normalized, unsigned int toType>
+struct ConversionRule : Cast<typename GLToCType<fromType>::type, typename D3DToCType<toType>::type> { };
+
+// All conversions from normalized types to float use the Normalize operator.
+template <GLenum fromType> struct ConversionRule<fromType, true, D3DVT_FLOAT> : Normalize<typename GLToCType<fromType>::type> { };
+
+// Use a full specialization for this so that it preferentially matches ahead of the generic normalize-to-float rules.
+template <> struct ConversionRule<GL_FIXED, true, D3DVT_FLOAT> : FixedToFloat<GLint, 16> { };
+template <> struct ConversionRule<GL_FIXED, false, D3DVT_FLOAT> : FixedToFloat<GLint, 16> { };
+
+// A 2-stage construction is used for DefaultVertexValues because float must use SimpleDefaultValues (i.e. 0/1)
+// whether it is normalized or not.
+template <class T, bool normalized> struct DefaultVertexValuesStage2 { };
+
+template <class T> struct DefaultVertexValuesStage2<T, true> : NormalizedDefaultValues<T> { };
+template <class T> struct DefaultVertexValuesStage2<T, false> : SimpleDefaultValues<T> { };
+
+// Work out the default value rule for a D3D type (expressed as the C type) and
+template <class T, bool normalized> struct DefaultVertexValues : DefaultVertexValuesStage2<T, normalized> { };
+template <bool normalized> struct DefaultVertexValues<float, normalized> : SimpleDefaultValues<float> { };
+
+// Policy rules for use with Converter, to choose whether to use the preferred or fallback conversion.
+// The fallback conversion produces an output that all D3D9 devices must support.
+template <class T> struct UsePreferred { enum { type = T::preferred }; };
+template <class T> struct UseFallback { enum { type = T::fallback }; };
+
+// Converter ties it all together. Given an OpenGL type/norm/size and choice of preferred/fallback conversion,
+// it provides all the members of the appropriate VertexDataConverter, the D3DCAPS9::DeclTypes flag in cap flag
+// and the D3DDECLTYPE member needed for the vertex declaration in declflag.
+template <GLenum fromType, bool normalized, int size, template <class T> class PreferenceRule>
+struct Converter
+ : VertexDataConverter<typename GLToCType<fromType>::type,
+ WidenRule<PreferenceRule< VertexTypeMapping<fromType, normalized> >::type, size>,
+ ConversionRule<fromType,
+ normalized,
+ PreferenceRule< VertexTypeMapping<fromType, normalized> >::type>,
+ DefaultVertexValues<typename D3DToCType<PreferenceRule< VertexTypeMapping<fromType, normalized> >::type>::type, normalized > >
+{
+private:
+ enum { d3dtype = PreferenceRule< VertexTypeMapping<fromType, normalized> >::type };
+ enum { d3dsize = WidenRule<d3dtype, size>::finalWidth };
+
+public:
+ enum { capflag = VertexTypeFlags<d3dtype, d3dsize>::capflag };
+ enum { declflag = VertexTypeFlags<d3dtype, d3dsize>::declflag };
+};
+
+// Initialize a TranslationInfo
+#define TRANSLATION(type, norm, size, preferred) \
+ { \
+ Converter<type, norm, size, preferred>::identity, \
+ Converter<type, norm, size, preferred>::finalSize, \
+ Converter<type, norm, size, preferred>::convertArray, \
+ static_cast<D3DDECLTYPE>(Converter<type, norm, size, preferred>::declflag) \
+ }
+
+#define TRANSLATION_FOR_TYPE_NORM_SIZE(type, norm, size) \
+ { \
+ Converter<type, norm, size, UsePreferred>::capflag, \
+ TRANSLATION(type, norm, size, UsePreferred), \
+ TRANSLATION(type, norm, size, UseFallback) \
+ }
+
+#define TRANSLATIONS_FOR_TYPE(type) \
+ { \
+ { TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 1), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 2), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 3), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 4) }, \
+ { TRANSLATION_FOR_TYPE_NORM_SIZE(type, true, 1), TRANSLATION_FOR_TYPE_NORM_SIZE(type, true, 2), TRANSLATION_FOR_TYPE_NORM_SIZE(type, true, 3), TRANSLATION_FOR_TYPE_NORM_SIZE(type, true, 4) }, \
+ }
+
+#define TRANSLATIONS_FOR_TYPE_NO_NORM(type) \
+ { \
+ { TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 1), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 2), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 3), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 4) }, \
+ { TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 1), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 2), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 3), TRANSLATION_FOR_TYPE_NORM_SIZE(type, false, 4) }, \
+ }
+
+const VertexBuffer9::TranslationDescription VertexBuffer9::mPossibleTranslations[NUM_GL_VERTEX_ATTRIB_TYPES][2][4] = // [GL types as enumerated by typeIndex()][normalized][size-1]
+{
+ TRANSLATIONS_FOR_TYPE(GL_BYTE),
+ TRANSLATIONS_FOR_TYPE(GL_UNSIGNED_BYTE),
+ TRANSLATIONS_FOR_TYPE(GL_SHORT),
+ TRANSLATIONS_FOR_TYPE(GL_UNSIGNED_SHORT),
+ TRANSLATIONS_FOR_TYPE_NO_NORM(GL_FIXED),
+ TRANSLATIONS_FOR_TYPE_NO_NORM(GL_FLOAT)
+};
+
+void VertexBuffer9::initializeTranslations(DWORD declTypes)
+{
+ for (unsigned int i = 0; i < NUM_GL_VERTEX_ATTRIB_TYPES; i++)
+ {
+ for (unsigned int j = 0; j < 2; j++)
+ {
+ for (unsigned int k = 0; k < 4; k++)
+ {
+ if (mPossibleTranslations[i][j][k].capsFlag == 0 || (declTypes & mPossibleTranslations[i][j][k].capsFlag) != 0)
+ {
+ mFormatConverters[i][j][k] = mPossibleTranslations[i][j][k].preferredConversion;
+ }
+ else
+ {
+ mFormatConverters[i][j][k] = mPossibleTranslations[i][j][k].fallbackConversion;
+ }
+ }
+ }
+ }
+}
+
+unsigned int VertexBuffer9::typeIndex(GLenum type)
+{
+ switch (type)
+ {
+ case GL_BYTE: return 0;
+ case GL_UNSIGNED_BYTE: return 1;
+ case GL_SHORT: return 2;
+ case GL_UNSIGNED_SHORT: return 3;
+ case GL_FIXED: return 4;
+ case GL_FLOAT: return 5;
+
+ default: UNREACHABLE(); return 5;
+ }
+}
+
+const VertexBuffer9::FormatConverter &VertexBuffer9::formatConverter(const gl::VertexAttribute &attribute)
+{
+ return mFormatConverters[typeIndex(attribute.mType)][attribute.mNormalized][attribute.mSize - 1];
+}
+
+unsigned int VertexBuffer9::spaceRequired(const gl::VertexAttribute &attrib, std::size_t count, GLsizei instances)
+{
+ unsigned int elementSize = formatConverter(attrib).outputElementSize;
+
+ if (instances == 0 || attrib.mDivisor == 0)
+ {
+ return elementSize * count;
+ }
+ else
+ {
+ return elementSize * ((instances + attrib.mDivisor - 1) / attrib.mDivisor);
+ }
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer9.h b/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer9.h
new file mode 100644
index 0000000000..f771635bda
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/VertexBuffer9.h
@@ -0,0 +1,90 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// VertexBuffer9.h: Defines the D3D9 VertexBuffer implementation.
+
+#ifndef LIBGLESV2_RENDERER_VERTEXBUFFER9_H_
+#define LIBGLESV2_RENDERER_VERTEXBUFFER9_H_
+
+#include "libGLESv2/renderer/VertexBuffer.h"
+
+namespace rx
+{
+class Renderer9;
+
+class VertexBuffer9 : public VertexBuffer
+{
+ public:
+ explicit VertexBuffer9(rx::Renderer9 *const renderer);
+ virtual ~VertexBuffer9();
+
+ virtual bool initialize(unsigned int size, bool dynamicUsage);
+
+ static VertexBuffer9 *makeVertexBuffer9(VertexBuffer *vertexBuffer);
+
+ virtual bool storeVertexAttributes(const gl::VertexAttribute &attrib, GLint start, GLsizei count, GLsizei instances,
+ unsigned int offset);
+ virtual bool storeRawData(const void* data, unsigned int size, unsigned int offset);
+
+ virtual unsigned int getSpaceRequired(const gl::VertexAttribute &attrib, GLsizei count, GLsizei instances) const;
+
+ virtual bool requiresConversion(const gl::VertexAttribute &attrib) const;
+
+ unsigned int getVertexSize(const gl::VertexAttribute &attrib) const;
+ D3DDECLTYPE getDeclType(const gl::VertexAttribute &attrib) const;
+
+ virtual unsigned int getBufferSize() const;
+ virtual bool setBufferSize(unsigned int size);
+ virtual bool discard();
+
+ IDirect3DVertexBuffer9 *getBuffer() const;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(VertexBuffer9);
+
+ rx::Renderer9 *const mRenderer;
+
+ IDirect3DVertexBuffer9 *mVertexBuffer;
+ unsigned int mBufferSize;
+ bool mDynamicUsage;
+
+ // Attribute format conversion
+ enum { NUM_GL_VERTEX_ATTRIB_TYPES = 6 };
+
+ struct FormatConverter
+ {
+ bool identity;
+ std::size_t outputElementSize;
+ void (*convertArray)(const void *in, std::size_t stride, std::size_t n, void *out);
+ D3DDECLTYPE d3dDeclType;
+ };
+
+ static bool mTranslationsInitialized;
+ static void initializeTranslations(DWORD declTypes);
+
+ // [GL types as enumerated by typeIndex()][normalized][size - 1]
+ static FormatConverter mFormatConverters[NUM_GL_VERTEX_ATTRIB_TYPES][2][4];
+
+ struct TranslationDescription
+ {
+ DWORD capsFlag;
+ FormatConverter preferredConversion;
+ FormatConverter fallbackConversion;
+ };
+
+ // This table is used to generate mFormatConverters.
+ // [GL types as enumerated by typeIndex()][normalized][size - 1]
+ static const TranslationDescription mPossibleTranslations[NUM_GL_VERTEX_ATTRIB_TYPES][2][4];
+
+ static unsigned int typeIndex(GLenum type);
+ static const FormatConverter &formatConverter(const gl::VertexAttribute &attribute);
+
+ static unsigned int spaceRequired(const gl::VertexAttribute &attrib, std::size_t count, GLsizei instances);
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_VERTEXBUFFER9_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/VertexDataManager.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/VertexDataManager.cpp
new file mode 100644
index 0000000000..ec85857264
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/VertexDataManager.cpp
@@ -0,0 +1,258 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// VertexDataManager.h: Defines the VertexDataManager, a class that
+// runs the Buffer translation process.
+
+#include "libGLESv2/renderer/VertexDataManager.h"
+#include "libGLESv2/renderer/BufferStorage.h"
+
+#include "libGLESv2/Buffer.h"
+#include "libGLESv2/ProgramBinary.h"
+#include "libGLESv2/Context.h"
+#include "libGLESv2/renderer/VertexBuffer.h"
+
+namespace
+{
+ enum { INITIAL_STREAM_BUFFER_SIZE = 1024*1024 };
+ // This has to be at least 4k or else it fails on ATI cards.
+ enum { CONSTANT_VERTEX_BUFFER_SIZE = 4096 };
+}
+
+namespace rx
+{
+
+static int elementsInBuffer(const gl::VertexAttribute &attribute, int size)
+{
+ int stride = attribute.stride();
+ return (size - attribute.mOffset % stride + (stride - attribute.typeSize())) / stride;
+}
+
+VertexDataManager::VertexDataManager(Renderer *renderer) : mRenderer(renderer)
+{
+ for (int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ mCurrentValue[i][0] = std::numeric_limits<float>::quiet_NaN();
+ mCurrentValue[i][1] = std::numeric_limits<float>::quiet_NaN();
+ mCurrentValue[i][2] = std::numeric_limits<float>::quiet_NaN();
+ mCurrentValue[i][3] = std::numeric_limits<float>::quiet_NaN();
+ mCurrentValueBuffer[i] = NULL;
+ mCurrentValueOffsets[i] = 0;
+ }
+
+ mStreamingBuffer = new StreamingVertexBufferInterface(renderer, INITIAL_STREAM_BUFFER_SIZE);
+
+ if (!mStreamingBuffer)
+ {
+ ERR("Failed to allocate the streaming vertex buffer.");
+ }
+}
+
+VertexDataManager::~VertexDataManager()
+{
+ delete mStreamingBuffer;
+
+ for (int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ delete mCurrentValueBuffer[i];
+ }
+}
+
+static bool directStoragePossible(VertexBufferInterface* vb, const gl::VertexAttribute& attrib)
+{
+ gl::Buffer *buffer = attrib.mBoundBuffer.get();
+ BufferStorage *storage = buffer ? buffer->getStorage() : NULL;
+
+ const bool isAligned = (attrib.stride() % 4 == 0) && (attrib.mOffset % 4 == 0);
+
+ return storage && storage->supportsDirectBinding() && !vb->getVertexBuffer()->requiresConversion(attrib) && isAligned;
+}
+
+GLenum VertexDataManager::prepareVertexData(const gl::VertexAttribute attribs[], gl::ProgramBinary *programBinary, GLint start, GLsizei count, TranslatedAttribute *translated, GLsizei instances)
+{
+ if (!mStreamingBuffer)
+ {
+ return GL_OUT_OF_MEMORY;
+ }
+
+ for (int attributeIndex = 0; attributeIndex < gl::MAX_VERTEX_ATTRIBS; attributeIndex++)
+ {
+ translated[attributeIndex].active = (programBinary->getSemanticIndex(attributeIndex) != -1);
+ }
+
+ // Invalidate static buffers that don't contain matching attributes
+ for (int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ if (translated[i].active && attribs[i].mArrayEnabled)
+ {
+ gl::Buffer *buffer = attribs[i].mBoundBuffer.get();
+ StaticVertexBufferInterface *staticBuffer = buffer ? buffer->getStaticVertexBuffer() : NULL;
+
+ if (staticBuffer && staticBuffer->getBufferSize() > 0 && staticBuffer->lookupAttribute(attribs[i]) == -1 &&
+ !directStoragePossible(staticBuffer, attribs[i]))
+ {
+ buffer->invalidateStaticData();
+ }
+ }
+ }
+
+ // Reserve the required space in the buffers
+ for (int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ if (translated[i].active && attribs[i].mArrayEnabled)
+ {
+ gl::Buffer *buffer = attribs[i].mBoundBuffer.get();
+ StaticVertexBufferInterface *staticBuffer = buffer ? buffer->getStaticVertexBuffer() : NULL;
+ VertexBufferInterface *vertexBuffer = staticBuffer ? staticBuffer : static_cast<VertexBufferInterface*>(mStreamingBuffer);
+
+ if (!directStoragePossible(vertexBuffer, attribs[i]))
+ {
+ if (staticBuffer)
+ {
+ if (staticBuffer->getBufferSize() == 0)
+ {
+ int totalCount = elementsInBuffer(attribs[i], buffer->size());
+ staticBuffer->reserveVertexSpace(attribs[i], totalCount, 0);
+ }
+ }
+ else
+ {
+ mStreamingBuffer->reserveVertexSpace(attribs[i], count, instances);
+ }
+ }
+ }
+ }
+
+ // Perform the vertex data translations
+ for (int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ if (translated[i].active)
+ {
+ if (attribs[i].mArrayEnabled)
+ {
+ gl::Buffer *buffer = attribs[i].mBoundBuffer.get();
+
+ if (!buffer && attribs[i].mPointer == NULL)
+ {
+ // This is an application error that would normally result in a crash, but we catch it and return an error
+ ERR("An enabled vertex array has no buffer and no pointer.");
+ return GL_INVALID_OPERATION;
+ }
+
+ StaticVertexBufferInterface *staticBuffer = buffer ? buffer->getStaticVertexBuffer() : NULL;
+ VertexBufferInterface *vertexBuffer = staticBuffer ? staticBuffer : static_cast<VertexBufferInterface*>(mStreamingBuffer);
+
+ BufferStorage *storage = buffer ? buffer->getStorage() : NULL;
+ bool directStorage = directStoragePossible(vertexBuffer, attribs[i]);
+
+ std::size_t streamOffset = -1;
+ unsigned int outputElementSize = 0;
+
+ if (directStorage)
+ {
+ outputElementSize = attribs[i].stride();
+ streamOffset = attribs[i].mOffset + outputElementSize * start;
+ storage->markBufferUsage();
+ }
+ else if (staticBuffer)
+ {
+ streamOffset = staticBuffer->lookupAttribute(attribs[i]);
+ outputElementSize = staticBuffer->getVertexBuffer()->getSpaceRequired(attribs[i], 1, 0);
+
+ if (streamOffset == -1)
+ {
+ // Convert the entire buffer
+ int totalCount = elementsInBuffer(attribs[i], storage->getSize());
+ int startIndex = attribs[i].mOffset / attribs[i].stride();
+
+ streamOffset = staticBuffer->storeVertexAttributes(attribs[i], -startIndex, totalCount, 0);
+ }
+
+ if (streamOffset != -1)
+ {
+ streamOffset += (attribs[i].mOffset / attribs[i].stride()) * outputElementSize;
+
+ if (instances == 0 || attribs[i].mDivisor == 0)
+ {
+ streamOffset += start * outputElementSize;
+ }
+ }
+ }
+ else
+ {
+ outputElementSize = mStreamingBuffer->getVertexBuffer()->getSpaceRequired(attribs[i], 1, 0);
+ streamOffset = mStreamingBuffer->storeVertexAttributes(attribs[i], start, count, instances);
+ }
+
+ if (streamOffset == -1)
+ {
+ return GL_OUT_OF_MEMORY;
+ }
+
+ translated[i].storage = directStorage ? storage : NULL;
+ translated[i].vertexBuffer = vertexBuffer->getVertexBuffer();
+ translated[i].serial = directStorage ? storage->getSerial() : vertexBuffer->getSerial();
+ translated[i].divisor = attribs[i].mDivisor;
+
+ translated[i].attribute = &attribs[i];
+ translated[i].stride = outputElementSize;
+ translated[i].offset = streamOffset;
+ }
+ else
+ {
+ if (!mCurrentValueBuffer[i])
+ {
+ mCurrentValueBuffer[i] = new StreamingVertexBufferInterface(mRenderer, CONSTANT_VERTEX_BUFFER_SIZE);
+ }
+
+ StreamingVertexBufferInterface *buffer = mCurrentValueBuffer[i];
+
+ if (mCurrentValue[i][0] != attribs[i].mCurrentValue[0] ||
+ mCurrentValue[i][1] != attribs[i].mCurrentValue[1] ||
+ mCurrentValue[i][2] != attribs[i].mCurrentValue[2] ||
+ mCurrentValue[i][3] != attribs[i].mCurrentValue[3])
+ {
+ unsigned int requiredSpace = sizeof(float) * 4;
+ buffer->reserveRawDataSpace(requiredSpace);
+ int streamOffset = buffer->storeRawData(attribs[i].mCurrentValue, requiredSpace);
+ if (streamOffset == -1)
+ {
+ return GL_OUT_OF_MEMORY;
+ }
+
+ mCurrentValueOffsets[i] = streamOffset;
+ }
+
+ translated[i].storage = NULL;
+ translated[i].vertexBuffer = mCurrentValueBuffer[i]->getVertexBuffer();
+ translated[i].serial = mCurrentValueBuffer[i]->getSerial();
+ translated[i].divisor = 0;
+
+ translated[i].attribute = &attribs[i];
+ translated[i].stride = 0;
+ translated[i].offset = mCurrentValueOffsets[i];
+ }
+ }
+ }
+
+ for (int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ if (translated[i].active && attribs[i].mArrayEnabled)
+ {
+ gl::Buffer *buffer = attribs[i].mBoundBuffer.get();
+
+ if (buffer)
+ {
+ buffer->promoteStaticUsage(count * attribs[i].typeSize());
+ }
+ }
+ }
+
+ return GL_NO_ERROR;
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/VertexDataManager.h b/src/3rdparty/angle/src/libGLESv2/renderer/VertexDataManager.h
new file mode 100644
index 0000000000..28387e6baf
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/VertexDataManager.h
@@ -0,0 +1,65 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// VertexDataManager.h: Defines the VertexDataManager, a class that
+// runs the Buffer translation process.
+
+#ifndef LIBGLESV2_RENDERER_VERTEXDATAMANAGER_H_
+#define LIBGLESV2_RENDERER_VERTEXDATAMANAGER_H_
+
+#include "libGLESv2/Constants.h"
+#include "common/angleutils.h"
+
+namespace gl
+{
+class VertexAttribute;
+class ProgramBinary;
+}
+
+namespace rx
+{
+class BufferStorage;
+class StreamingVertexBufferInterface;
+class VertexBuffer;
+class Renderer;
+
+struct TranslatedAttribute
+{
+ bool active;
+
+ const gl::VertexAttribute *attribute;
+ UINT offset;
+ UINT stride; // 0 means not to advance the read pointer at all
+
+ VertexBuffer *vertexBuffer;
+ BufferStorage *storage;
+ unsigned int serial;
+ unsigned int divisor;
+};
+
+class VertexDataManager
+{
+ public:
+ VertexDataManager(rx::Renderer *renderer);
+ virtual ~VertexDataManager();
+
+ GLenum prepareVertexData(const gl::VertexAttribute attribs[], gl::ProgramBinary *programBinary, GLint start, GLsizei count, TranslatedAttribute *outAttribs, GLsizei instances);
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(VertexDataManager);
+
+ rx::Renderer *const mRenderer;
+
+ StreamingVertexBufferInterface *mStreamingBuffer;
+
+ float mCurrentValue[gl::MAX_VERTEX_ATTRIBS][4];
+ StreamingVertexBufferInterface *mCurrentValueBuffer[gl::MAX_VERTEX_ATTRIBS];
+ std::size_t mCurrentValueOffsets[gl::MAX_VERTEX_ATTRIBS];
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_VERTEXDATAMANAGER_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/VertexDeclarationCache.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/VertexDeclarationCache.cpp
new file mode 100644
index 0000000000..9b83a6476e
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/VertexDeclarationCache.cpp
@@ -0,0 +1,217 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// VertexDeclarationCache.cpp: Implements a helper class to construct and cache vertex declarations.
+
+#include "libGLESv2/ProgramBinary.h"
+#include "libGLESv2/Context.h"
+#include "libGLESv2/renderer/VertexBuffer9.h"
+#include "libGLESv2/renderer/VertexDeclarationCache.h"
+
+namespace rx
+{
+
+VertexDeclarationCache::VertexDeclarationCache() : mMaxLru(0)
+{
+ for (int i = 0; i < NUM_VERTEX_DECL_CACHE_ENTRIES; i++)
+ {
+ mVertexDeclCache[i].vertexDeclaration = NULL;
+ mVertexDeclCache[i].lruCount = 0;
+ }
+
+ for (int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ mAppliedVBs[i].serial = 0;
+ }
+
+ mLastSetVDecl = NULL;
+ mInstancingEnabled = true;
+}
+
+VertexDeclarationCache::~VertexDeclarationCache()
+{
+ for (int i = 0; i < NUM_VERTEX_DECL_CACHE_ENTRIES; i++)
+ {
+ if (mVertexDeclCache[i].vertexDeclaration)
+ {
+ mVertexDeclCache[i].vertexDeclaration->Release();
+ }
+ }
+}
+
+GLenum VertexDeclarationCache::applyDeclaration(IDirect3DDevice9 *device, TranslatedAttribute attributes[], gl::ProgramBinary *programBinary, GLsizei instances, GLsizei *repeatDraw)
+{
+ *repeatDraw = 1;
+
+ int indexedAttribute = gl::MAX_VERTEX_ATTRIBS;
+ int instancedAttribute = gl::MAX_VERTEX_ATTRIBS;
+
+ if (instances > 0)
+ {
+ // Find an indexed attribute to be mapped to D3D stream 0
+ for (int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ if (attributes[i].active)
+ {
+ if (indexedAttribute == gl::MAX_VERTEX_ATTRIBS && attributes[i].divisor == 0)
+ {
+ indexedAttribute = i;
+ }
+ else if (instancedAttribute == gl::MAX_VERTEX_ATTRIBS && attributes[i].divisor != 0)
+ {
+ instancedAttribute = i;
+ }
+ if (indexedAttribute != gl::MAX_VERTEX_ATTRIBS && instancedAttribute != gl::MAX_VERTEX_ATTRIBS)
+ break; // Found both an indexed and instanced attribute
+ }
+ }
+
+ if (indexedAttribute == gl::MAX_VERTEX_ATTRIBS)
+ {
+ return GL_INVALID_OPERATION;
+ }
+ }
+
+ D3DVERTEXELEMENT9 elements[gl::MAX_VERTEX_ATTRIBS + 1];
+ D3DVERTEXELEMENT9 *element = &elements[0];
+
+ for (int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ if (attributes[i].active)
+ {
+ // Directly binding the storage buffer is not supported for d3d9
+ ASSERT(attributes[i].storage == NULL);
+
+ int stream = i;
+
+ if (instances > 0)
+ {
+ // Due to a bug on ATI cards we can't enable instancing when none of the attributes are instanced.
+ if (instancedAttribute == gl::MAX_VERTEX_ATTRIBS)
+ {
+ *repeatDraw = instances;
+ }
+ else
+ {
+ if (i == indexedAttribute)
+ {
+ stream = 0;
+ }
+ else if (i == 0)
+ {
+ stream = indexedAttribute;
+ }
+
+ UINT frequency = 1;
+
+ if (attributes[i].divisor == 0)
+ {
+ frequency = D3DSTREAMSOURCE_INDEXEDDATA | instances;
+ }
+ else
+ {
+ frequency = D3DSTREAMSOURCE_INSTANCEDATA | attributes[i].divisor;
+ }
+
+ device->SetStreamSourceFreq(stream, frequency);
+ mInstancingEnabled = true;
+ }
+ }
+
+ VertexBuffer9 *vertexBuffer = VertexBuffer9::makeVertexBuffer9(attributes[i].vertexBuffer);
+
+ if (mAppliedVBs[stream].serial != attributes[i].serial ||
+ mAppliedVBs[stream].stride != attributes[i].stride ||
+ mAppliedVBs[stream].offset != attributes[i].offset)
+ {
+ device->SetStreamSource(stream, vertexBuffer->getBuffer(), attributes[i].offset, attributes[i].stride);
+ mAppliedVBs[stream].serial = attributes[i].serial;
+ mAppliedVBs[stream].stride = attributes[i].stride;
+ mAppliedVBs[stream].offset = attributes[i].offset;
+ }
+
+ element->Stream = stream;
+ element->Offset = 0;
+ element->Type = attributes[i].attribute->mArrayEnabled ? vertexBuffer->getDeclType(*attributes[i].attribute) : D3DDECLTYPE_FLOAT4;
+ element->Method = D3DDECLMETHOD_DEFAULT;
+ element->Usage = D3DDECLUSAGE_TEXCOORD;
+ element->UsageIndex = programBinary->getSemanticIndex(i);
+ element++;
+ }
+ }
+
+ if (instances == 0 || instancedAttribute == gl::MAX_VERTEX_ATTRIBS)
+ {
+ if (mInstancingEnabled)
+ {
+ for (int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ device->SetStreamSourceFreq(i, 1);
+ }
+
+ mInstancingEnabled = false;
+ }
+ }
+
+ static const D3DVERTEXELEMENT9 end = D3DDECL_END();
+ *(element++) = end;
+
+ for (int i = 0; i < NUM_VERTEX_DECL_CACHE_ENTRIES; i++)
+ {
+ VertexDeclCacheEntry *entry = &mVertexDeclCache[i];
+ if (memcmp(entry->cachedElements, elements, (element - elements) * sizeof(D3DVERTEXELEMENT9)) == 0 && entry->vertexDeclaration)
+ {
+ entry->lruCount = ++mMaxLru;
+ if(entry->vertexDeclaration != mLastSetVDecl)
+ {
+ device->SetVertexDeclaration(entry->vertexDeclaration);
+ mLastSetVDecl = entry->vertexDeclaration;
+ }
+
+ return GL_NO_ERROR;
+ }
+ }
+
+ VertexDeclCacheEntry *lastCache = mVertexDeclCache;
+
+ for (int i = 0; i < NUM_VERTEX_DECL_CACHE_ENTRIES; i++)
+ {
+ if (mVertexDeclCache[i].lruCount < lastCache->lruCount)
+ {
+ lastCache = &mVertexDeclCache[i];
+ }
+ }
+
+ if (lastCache->vertexDeclaration != NULL)
+ {
+ lastCache->vertexDeclaration->Release();
+ lastCache->vertexDeclaration = NULL;
+ // mLastSetVDecl is set to the replacement, so we don't have to worry
+ // about it.
+ }
+
+ memcpy(lastCache->cachedElements, elements, (element - elements) * sizeof(D3DVERTEXELEMENT9));
+ device->CreateVertexDeclaration(elements, &lastCache->vertexDeclaration);
+ device->SetVertexDeclaration(lastCache->vertexDeclaration);
+ mLastSetVDecl = lastCache->vertexDeclaration;
+ lastCache->lruCount = ++mMaxLru;
+
+ return GL_NO_ERROR;
+}
+
+void VertexDeclarationCache::markStateDirty()
+{
+ for (int i = 0; i < gl::MAX_VERTEX_ATTRIBS; i++)
+ {
+ mAppliedVBs[i].serial = 0;
+ }
+
+ mLastSetVDecl = NULL;
+ mInstancingEnabled = true; // Forces it to be disabled when not used
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/VertexDeclarationCache.h b/src/3rdparty/angle/src/libGLESv2/renderer/VertexDeclarationCache.h
new file mode 100644
index 0000000000..3fc024a9ba
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/VertexDeclarationCache.h
@@ -0,0 +1,58 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// VertexDeclarationCache.h: Defines a helper class to construct and cache vertex declarations.
+
+#ifndef LIBGLESV2_RENDERER_VERTEXDECLARATIONCACHE_H_
+#define LIBGLESV2_RENDERER_VERTEXDECLARATIONCACHE_H_
+
+#include "libGLESv2/renderer/VertexDataManager.h"
+
+namespace gl
+{
+class VertexDataManager;
+}
+
+namespace rx
+{
+
+class VertexDeclarationCache
+{
+ public:
+ VertexDeclarationCache();
+ ~VertexDeclarationCache();
+
+ GLenum applyDeclaration(IDirect3DDevice9 *device, TranslatedAttribute attributes[], gl::ProgramBinary *programBinary, GLsizei instances, GLsizei *repeatDraw);
+
+ void markStateDirty();
+
+ private:
+ UINT mMaxLru;
+
+ enum { NUM_VERTEX_DECL_CACHE_ENTRIES = 32 };
+
+ struct VBData
+ {
+ unsigned int serial;
+ unsigned int stride;
+ unsigned int offset;
+ };
+
+ VBData mAppliedVBs[gl::MAX_VERTEX_ATTRIBS];
+ IDirect3DVertexDeclaration9 *mLastSetVDecl;
+ bool mInstancingEnabled;
+
+ struct VertexDeclCacheEntry
+ {
+ D3DVERTEXELEMENT9 cachedElements[gl::MAX_VERTEX_ATTRIBS + 1];
+ UINT lruCount;
+ IDirect3DVertexDeclaration9 *vertexDeclaration;
+ } mVertexDeclCache[NUM_VERTEX_DECL_CACHE_ENTRIES];
+};
+
+}
+
+#endif // LIBGLESV2_RENDERER_VERTEXDECLARATIONCACHE_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/generatemip.h b/src/3rdparty/angle/src/libGLESv2/renderer/generatemip.h
new file mode 100644
index 0000000000..8e1973605b
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/generatemip.h
@@ -0,0 +1,203 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// generatemip.h: Defines the GenerateMip function, templated on the format
+// type of the image for which mip levels are being generated.
+
+#ifndef LIBGLESV2_RENDERER_GENERATEMIP_H_
+#define LIBGLESV2_RENDERER_GENERATEMIP_H_
+
+#include "libGLESv2/mathutil.h"
+
+namespace rx
+{
+struct L8
+{
+ unsigned char L;
+
+ static void average(L8 *dst, const L8 *src1, const L8 *src2)
+ {
+ dst->L = ((src1->L ^ src2->L) >> 1) + (src1->L & src2->L);
+ }
+};
+
+typedef L8 R8; // R8 type is functionally equivalent for mip purposes
+typedef L8 A8; // A8 type is functionally equivalent for mip purposes
+
+struct A8L8
+{
+ unsigned char L;
+ unsigned char A;
+
+ static void average(A8L8 *dst, const A8L8 *src1, const A8L8 *src2)
+ {
+ *(unsigned short*)dst = (((*(unsigned short*)src1 ^ *(unsigned short*)src2) & 0xFEFE) >> 1) + (*(unsigned short*)src1 & *(unsigned short*)src2);
+ }
+};
+
+typedef A8L8 R8G8; // R8G8 type is functionally equivalent for mip purposes
+
+struct A8R8G8B8
+{
+ unsigned char B;
+ unsigned char G;
+ unsigned char R;
+ unsigned char A;
+
+ static void average(A8R8G8B8 *dst, const A8R8G8B8 *src1, const A8R8G8B8 *src2)
+ {
+ *(unsigned int*)dst = (((*(unsigned int*)src1 ^ *(unsigned int*)src2) & 0xFEFEFEFE) >> 1) + (*(unsigned int*)src1 & *(unsigned int*)src2);
+ }
+};
+
+typedef A8R8G8B8 R8G8B8A8; // R8G8B8A8 type is functionally equivalent for mip purposes
+
+struct A16B16G16R16F
+{
+ unsigned short R;
+ unsigned short G;
+ unsigned short B;
+ unsigned short A;
+
+ static void average(A16B16G16R16F *dst, const A16B16G16R16F *src1, const A16B16G16R16F *src2)
+ {
+ dst->R = gl::float32ToFloat16((gl::float16ToFloat32(src1->R) + gl::float16ToFloat32(src2->R)) * 0.5f);
+ dst->G = gl::float32ToFloat16((gl::float16ToFloat32(src1->G) + gl::float16ToFloat32(src2->G)) * 0.5f);
+ dst->B = gl::float32ToFloat16((gl::float16ToFloat32(src1->B) + gl::float16ToFloat32(src2->B)) * 0.5f);
+ dst->A = gl::float32ToFloat16((gl::float16ToFloat32(src1->A) + gl::float16ToFloat32(src2->A)) * 0.5f);
+ }
+};
+
+struct R16F
+{
+ unsigned short R;
+
+ static void average(R16F *dst, const R16F *src1, const R16F *src2)
+ {
+ dst->R = gl::float32ToFloat16((gl::float16ToFloat32(src1->R) + gl::float16ToFloat32(src2->R)) * 0.5f);
+ }
+};
+
+struct R16G16F
+{
+ unsigned short R;
+ unsigned short G;
+
+ static void average(R16G16F *dst, const R16G16F *src1, const R16G16F *src2)
+ {
+ dst->R = gl::float32ToFloat16((gl::float16ToFloat32(src1->R) + gl::float16ToFloat32(src2->R)) * 0.5f);
+ dst->G = gl::float32ToFloat16((gl::float16ToFloat32(src1->G) + gl::float16ToFloat32(src2->G)) * 0.5f);
+ }
+};
+
+struct A32B32G32R32F
+{
+ float R;
+ float G;
+ float B;
+ float A;
+
+ static void average(A32B32G32R32F *dst, const A32B32G32R32F *src1, const A32B32G32R32F *src2)
+ {
+ dst->R = (src1->R + src2->R) * 0.5f;
+ dst->G = (src1->G + src2->G) * 0.5f;
+ dst->B = (src1->B + src2->B) * 0.5f;
+ dst->A = (src1->A + src2->A) * 0.5f;
+ }
+};
+
+struct R32F
+{
+ float R;
+
+ static void average(R32F *dst, const R32F *src1, const R32F *src2)
+ {
+ dst->R = (src1->R + src2->R) * 0.5f;
+ }
+};
+
+struct R32G32F
+{
+ float R;
+ float G;
+
+ static void average(R32G32F *dst, const R32G32F *src1, const R32G32F *src2)
+ {
+ dst->R = (src1->R + src2->R) * 0.5f;
+ dst->G = (src1->G + src2->G) * 0.5f;
+ }
+};
+
+struct R32G32B32F
+{
+ float R;
+ float G;
+ float B;
+
+ static void average(R32G32B32F *dst, const R32G32B32F *src1, const R32G32B32F *src2)
+ {
+ dst->R = (src1->R + src2->R) * 0.5f;
+ dst->G = (src1->G + src2->G) * 0.5f;
+ dst->B = (src1->B + src2->B) * 0.5f;
+ }
+};
+
+template <typename T>
+static void GenerateMip(unsigned int sourceWidth, unsigned int sourceHeight,
+ const unsigned char *sourceData, int sourcePitch,
+ unsigned char *destData, int destPitch)
+{
+ unsigned int mipWidth = std::max(1U, sourceWidth >> 1);
+ unsigned int mipHeight = std::max(1U, sourceHeight >> 1);
+
+ if (sourceHeight == 1)
+ {
+ ASSERT(sourceWidth != 1);
+
+ const T *src = (const T*)sourceData;
+ T *dst = (T*)destData;
+
+ for (unsigned int x = 0; x < mipWidth; x++)
+ {
+ T::average(&dst[x], &src[x * 2], &src[x * 2 + 1]);
+ }
+ }
+ else if (sourceWidth == 1)
+ {
+ ASSERT(sourceHeight != 1);
+
+ for (unsigned int y = 0; y < mipHeight; y++)
+ {
+ const T *src0 = (const T*)(sourceData + y * 2 * sourcePitch);
+ const T *src1 = (const T*)(sourceData + y * 2 * sourcePitch + sourcePitch);
+ T *dst = (T*)(destData + y * destPitch);
+
+ T::average(dst, src0, src1);
+ }
+ }
+ else
+ {
+ for (unsigned int y = 0; y < mipHeight; y++)
+ {
+ const T *src0 = (const T*)(sourceData + y * 2 * sourcePitch);
+ const T *src1 = (const T*)(sourceData + y * 2 * sourcePitch + sourcePitch);
+ T *dst = (T*)(destData + y * destPitch);
+
+ for (unsigned int x = 0; x < mipWidth; x++)
+ {
+ T tmp0;
+ T tmp1;
+
+ T::average(&tmp0, &src0[x * 2], &src0[x * 2 + 1]);
+ T::average(&tmp1, &src1[x * 2], &src1[x * 2 + 1]);
+ T::average(&dst[x], &tmp0, &tmp1);
+ }
+ }
+ }
+}
+}
+
+#endif // LIBGLESV2_RENDERER_GENERATEMIP_H_
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/renderer11_utils.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/renderer11_utils.cpp
new file mode 100644
index 0000000000..5f01dc12ed
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/renderer11_utils.cpp
@@ -0,0 +1,688 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// renderer11_utils.cpp: Conversion functions and other utility routines
+// specific to the D3D11 renderer.
+
+#include "libGLESv2/renderer/renderer11_utils.h"
+
+#include "common/debug.h"
+
+namespace gl_d3d11
+{
+
+D3D11_BLEND ConvertBlendFunc(GLenum glBlend, bool isAlpha)
+{
+ D3D11_BLEND d3dBlend = D3D11_BLEND_ZERO;
+
+ switch (glBlend)
+ {
+ case GL_ZERO: d3dBlend = D3D11_BLEND_ZERO; break;
+ case GL_ONE: d3dBlend = D3D11_BLEND_ONE; break;
+ case GL_SRC_COLOR: d3dBlend = (isAlpha ? D3D11_BLEND_SRC_ALPHA : D3D11_BLEND_SRC_COLOR); break;
+ case GL_ONE_MINUS_SRC_COLOR: d3dBlend = (isAlpha ? D3D11_BLEND_INV_SRC_ALPHA : D3D11_BLEND_INV_SRC_COLOR); break;
+ case GL_DST_COLOR: d3dBlend = (isAlpha ? D3D11_BLEND_DEST_ALPHA : D3D11_BLEND_DEST_COLOR); break;
+ case GL_ONE_MINUS_DST_COLOR: d3dBlend = (isAlpha ? D3D11_BLEND_INV_DEST_ALPHA : D3D11_BLEND_INV_DEST_COLOR); break;
+ case GL_SRC_ALPHA: d3dBlend = D3D11_BLEND_SRC_ALPHA; break;
+ case GL_ONE_MINUS_SRC_ALPHA: d3dBlend = D3D11_BLEND_INV_SRC_ALPHA; break;
+ case GL_DST_ALPHA: d3dBlend = D3D11_BLEND_DEST_ALPHA; break;
+ case GL_ONE_MINUS_DST_ALPHA: d3dBlend = D3D11_BLEND_INV_DEST_ALPHA; break;
+ case GL_CONSTANT_COLOR: d3dBlend = D3D11_BLEND_BLEND_FACTOR; break;
+ case GL_ONE_MINUS_CONSTANT_COLOR: d3dBlend = D3D11_BLEND_INV_BLEND_FACTOR; break;
+ case GL_CONSTANT_ALPHA: d3dBlend = D3D11_BLEND_BLEND_FACTOR; break;
+ case GL_ONE_MINUS_CONSTANT_ALPHA: d3dBlend = D3D11_BLEND_INV_BLEND_FACTOR; break;
+ case GL_SRC_ALPHA_SATURATE: d3dBlend = D3D11_BLEND_SRC_ALPHA_SAT; break;
+ default: UNREACHABLE();
+ }
+
+ return d3dBlend;
+}
+
+D3D11_BLEND_OP ConvertBlendOp(GLenum glBlendOp)
+{
+ D3D11_BLEND_OP d3dBlendOp = D3D11_BLEND_OP_ADD;
+
+ switch (glBlendOp)
+ {
+ case GL_FUNC_ADD: d3dBlendOp = D3D11_BLEND_OP_ADD; break;
+ case GL_FUNC_SUBTRACT: d3dBlendOp = D3D11_BLEND_OP_SUBTRACT; break;
+ case GL_FUNC_REVERSE_SUBTRACT: d3dBlendOp = D3D11_BLEND_OP_REV_SUBTRACT; break;
+ default: UNREACHABLE();
+ }
+
+ return d3dBlendOp;
+}
+
+UINT8 ConvertColorMask(bool red, bool green, bool blue, bool alpha)
+{
+ UINT8 mask = 0;
+ if (red)
+ {
+ mask |= D3D11_COLOR_WRITE_ENABLE_RED;
+ }
+ if (green)
+ {
+ mask |= D3D11_COLOR_WRITE_ENABLE_GREEN;
+ }
+ if (blue)
+ {
+ mask |= D3D11_COLOR_WRITE_ENABLE_BLUE;
+ }
+ if (alpha)
+ {
+ mask |= D3D11_COLOR_WRITE_ENABLE_ALPHA;
+ }
+ return mask;
+}
+
+D3D11_CULL_MODE ConvertCullMode(bool cullEnabled, GLenum cullMode)
+{
+ D3D11_CULL_MODE cull = D3D11_CULL_NONE;
+
+ if (cullEnabled)
+ {
+ switch (cullMode)
+ {
+ case GL_FRONT: cull = D3D11_CULL_FRONT; break;
+ case GL_BACK: cull = D3D11_CULL_BACK; break;
+ case GL_FRONT_AND_BACK: cull = D3D11_CULL_NONE; break;
+ default: UNREACHABLE();
+ }
+ }
+ else
+ {
+ cull = D3D11_CULL_NONE;
+ }
+
+ return cull;
+}
+
+D3D11_COMPARISON_FUNC ConvertComparison(GLenum comparison)
+{
+ D3D11_COMPARISON_FUNC d3dComp = D3D11_COMPARISON_NEVER;
+ switch (comparison)
+ {
+ case GL_NEVER: d3dComp = D3D11_COMPARISON_NEVER; break;
+ case GL_ALWAYS: d3dComp = D3D11_COMPARISON_ALWAYS; break;
+ case GL_LESS: d3dComp = D3D11_COMPARISON_LESS; break;
+ case GL_LEQUAL: d3dComp = D3D11_COMPARISON_LESS_EQUAL; break;
+ case GL_EQUAL: d3dComp = D3D11_COMPARISON_EQUAL; break;
+ case GL_GREATER: d3dComp = D3D11_COMPARISON_GREATER; break;
+ case GL_GEQUAL: d3dComp = D3D11_COMPARISON_GREATER_EQUAL; break;
+ case GL_NOTEQUAL: d3dComp = D3D11_COMPARISON_NOT_EQUAL; break;
+ default: UNREACHABLE();
+ }
+
+ return d3dComp;
+}
+
+D3D11_DEPTH_WRITE_MASK ConvertDepthMask(bool depthWriteEnabled)
+{
+ return depthWriteEnabled ? D3D11_DEPTH_WRITE_MASK_ALL : D3D11_DEPTH_WRITE_MASK_ZERO;
+}
+
+UINT8 ConvertStencilMask(GLuint stencilmask)
+{
+ return static_cast<UINT8>(stencilmask);
+}
+
+D3D11_STENCIL_OP ConvertStencilOp(GLenum stencilOp)
+{
+ D3D11_STENCIL_OP d3dStencilOp = D3D11_STENCIL_OP_KEEP;
+
+ switch (stencilOp)
+ {
+ case GL_ZERO: d3dStencilOp = D3D11_STENCIL_OP_ZERO; break;
+ case GL_KEEP: d3dStencilOp = D3D11_STENCIL_OP_KEEP; break;
+ case GL_REPLACE: d3dStencilOp = D3D11_STENCIL_OP_REPLACE; break;
+ case GL_INCR: d3dStencilOp = D3D11_STENCIL_OP_INCR_SAT; break;
+ case GL_DECR: d3dStencilOp = D3D11_STENCIL_OP_DECR_SAT; break;
+ case GL_INVERT: d3dStencilOp = D3D11_STENCIL_OP_INVERT; break;
+ case GL_INCR_WRAP: d3dStencilOp = D3D11_STENCIL_OP_INCR; break;
+ case GL_DECR_WRAP: d3dStencilOp = D3D11_STENCIL_OP_DECR; break;
+ default: UNREACHABLE();
+ }
+
+ return d3dStencilOp;
+}
+
+D3D11_FILTER ConvertFilter(GLenum minFilter, GLenum magFilter, float maxAnisotropy)
+{
+ if (maxAnisotropy > 1.0f)
+ {
+ return D3D11_ENCODE_ANISOTROPIC_FILTER(false);
+ }
+ else
+ {
+ D3D11_FILTER_TYPE dxMin = D3D11_FILTER_TYPE_POINT;
+ D3D11_FILTER_TYPE dxMip = D3D11_FILTER_TYPE_POINT;
+ switch (minFilter)
+ {
+ case GL_NEAREST: dxMin = D3D11_FILTER_TYPE_POINT; dxMip = D3D11_FILTER_TYPE_POINT; break;
+ case GL_LINEAR: dxMin = D3D11_FILTER_TYPE_LINEAR; dxMip = D3D11_FILTER_TYPE_POINT; break;
+ case GL_NEAREST_MIPMAP_NEAREST: dxMin = D3D11_FILTER_TYPE_POINT; dxMip = D3D11_FILTER_TYPE_POINT; break;
+ case GL_LINEAR_MIPMAP_NEAREST: dxMin = D3D11_FILTER_TYPE_LINEAR; dxMip = D3D11_FILTER_TYPE_POINT; break;
+ case GL_NEAREST_MIPMAP_LINEAR: dxMin = D3D11_FILTER_TYPE_POINT; dxMip = D3D11_FILTER_TYPE_LINEAR; break;
+ case GL_LINEAR_MIPMAP_LINEAR: dxMin = D3D11_FILTER_TYPE_LINEAR; dxMip = D3D11_FILTER_TYPE_LINEAR; break;
+ default: UNREACHABLE();
+ }
+
+ D3D11_FILTER_TYPE dxMag = D3D11_FILTER_TYPE_POINT;
+ switch (magFilter)
+ {
+ case GL_NEAREST: dxMag = D3D11_FILTER_TYPE_POINT; break;
+ case GL_LINEAR: dxMag = D3D11_FILTER_TYPE_LINEAR; break;
+ default: UNREACHABLE();
+ }
+
+ return D3D11_ENCODE_BASIC_FILTER(dxMin, dxMag, dxMip, false);
+ }
+}
+
+D3D11_TEXTURE_ADDRESS_MODE ConvertTextureWrap(GLenum wrap)
+{
+ switch (wrap)
+ {
+ case GL_REPEAT: return D3D11_TEXTURE_ADDRESS_WRAP;
+ case GL_CLAMP_TO_EDGE: return D3D11_TEXTURE_ADDRESS_CLAMP;
+ case GL_MIRRORED_REPEAT: return D3D11_TEXTURE_ADDRESS_MIRROR;
+ default: UNREACHABLE();
+ }
+
+ return D3D11_TEXTURE_ADDRESS_WRAP;
+}
+
+FLOAT ConvertMinLOD(GLenum minFilter, unsigned int lodOffset)
+{
+ return (minFilter == GL_NEAREST || minFilter == GL_LINEAR) ? static_cast<float>(lodOffset) : -FLT_MAX;
+}
+
+FLOAT ConvertMaxLOD(GLenum minFilter, unsigned int lodOffset)
+{
+ return (minFilter == GL_NEAREST || minFilter == GL_LINEAR) ? static_cast<float>(lodOffset) : FLT_MAX;
+}
+
+}
+
+namespace d3d11_gl
+{
+
+GLenum ConvertBackBufferFormat(DXGI_FORMAT format)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_R8G8B8A8_UNORM: return GL_RGBA8_OES;
+ case DXGI_FORMAT_B8G8R8A8_UNORM: return GL_BGRA8_EXT;
+ default:
+ UNREACHABLE();
+ }
+
+ return GL_RGBA8_OES;
+}
+
+GLenum ConvertDepthStencilFormat(DXGI_FORMAT format)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_UNKNOWN: return GL_NONE;
+ case DXGI_FORMAT_D16_UNORM: return GL_DEPTH_COMPONENT16;
+ case DXGI_FORMAT_D24_UNORM_S8_UINT: return GL_DEPTH24_STENCIL8_OES;
+ default:
+ UNREACHABLE();
+ }
+
+ return GL_DEPTH24_STENCIL8_OES;
+}
+
+GLenum ConvertRenderbufferFormat(DXGI_FORMAT format)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_B8G8R8A8_UNORM:
+ return GL_BGRA8_EXT;
+ case DXGI_FORMAT_R8G8B8A8_UNORM:
+ return GL_RGBA8_OES;
+ case DXGI_FORMAT_D16_UNORM:
+ return GL_DEPTH_COMPONENT16;
+ case DXGI_FORMAT_D24_UNORM_S8_UINT:
+ return GL_DEPTH24_STENCIL8_OES;
+ default:
+ UNREACHABLE();
+ }
+
+ return GL_RGBA8_OES;
+}
+
+GLenum ConvertTextureInternalFormat(DXGI_FORMAT format)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_R8G8B8A8_UNORM:
+ return GL_RGBA8_OES;
+ case DXGI_FORMAT_A8_UNORM:
+ return GL_ALPHA8_EXT;
+ case DXGI_FORMAT_BC1_UNORM:
+ return GL_COMPRESSED_RGBA_S3TC_DXT1_EXT;
+ case DXGI_FORMAT_BC2_UNORM:
+ return GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE;
+ case DXGI_FORMAT_BC3_UNORM:
+ return GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE;
+ case DXGI_FORMAT_R32G32B32A32_FLOAT:
+ return GL_RGBA32F_EXT;
+ case DXGI_FORMAT_R32G32B32_FLOAT:
+ return GL_RGB32F_EXT;
+ case DXGI_FORMAT_R16G16B16A16_FLOAT:
+ return GL_RGBA16F_EXT;
+ case DXGI_FORMAT_B8G8R8A8_UNORM:
+ return GL_BGRA8_EXT;
+ case DXGI_FORMAT_R8_UNORM:
+ return GL_R8_EXT;
+ case DXGI_FORMAT_R8G8_UNORM:
+ return GL_RG8_EXT;
+ case DXGI_FORMAT_R16_FLOAT:
+ return GL_R16F_EXT;
+ case DXGI_FORMAT_R16G16_FLOAT:
+ return GL_RG16F_EXT;
+ case DXGI_FORMAT_D16_UNORM:
+ return GL_DEPTH_COMPONENT16;
+ case DXGI_FORMAT_D24_UNORM_S8_UINT:
+ return GL_DEPTH24_STENCIL8_OES;
+ case DXGI_FORMAT_UNKNOWN:
+ return GL_NONE;
+ default:
+ UNREACHABLE();
+ }
+
+ return GL_RGBA8_OES;
+}
+
+}
+
+namespace gl_d3d11
+{
+
+DXGI_FORMAT ConvertRenderbufferFormat(GLenum format)
+{
+ switch (format)
+ {
+ case GL_RGBA4:
+ case GL_RGB5_A1:
+ case GL_RGBA8_OES:
+ case GL_RGB565:
+ case GL_RGB8_OES:
+ return DXGI_FORMAT_R8G8B8A8_UNORM;
+ case GL_BGRA8_EXT:
+ return DXGI_FORMAT_B8G8R8A8_UNORM;
+ case GL_DEPTH_COMPONENT16:
+ return DXGI_FORMAT_D16_UNORM;
+ case GL_STENCIL_INDEX8:
+ case GL_DEPTH24_STENCIL8_OES:
+ return DXGI_FORMAT_D24_UNORM_S8_UINT;
+ default:
+ UNREACHABLE();
+ }
+
+ return DXGI_FORMAT_R8G8B8A8_UNORM;
+}
+
+DXGI_FORMAT ConvertTextureFormat(GLenum internalformat)
+{
+ switch (internalformat)
+ {
+ case GL_RGB565:
+ case GL_RGBA4:
+ case GL_RGB5_A1:
+ case GL_RGB8_OES:
+ case GL_RGBA8_OES:
+ case GL_LUMINANCE8_EXT:
+ case GL_LUMINANCE8_ALPHA8_EXT:
+ return DXGI_FORMAT_R8G8B8A8_UNORM;
+ case GL_ALPHA8_EXT:
+ return DXGI_FORMAT_A8_UNORM;
+ case GL_COMPRESSED_RGB_S3TC_DXT1_EXT:
+ case GL_COMPRESSED_RGBA_S3TC_DXT1_EXT:
+ return DXGI_FORMAT_BC1_UNORM;
+ case GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE:
+ return DXGI_FORMAT_BC2_UNORM;
+ case GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE:
+ return DXGI_FORMAT_BC3_UNORM;
+ case GL_RGBA32F_EXT:
+ case GL_ALPHA32F_EXT:
+ case GL_LUMINANCE_ALPHA32F_EXT:
+ return DXGI_FORMAT_R32G32B32A32_FLOAT;
+ case GL_RGB32F_EXT:
+ case GL_LUMINANCE32F_EXT:
+ return DXGI_FORMAT_R32G32B32_FLOAT;
+ case GL_RGBA16F_EXT:
+ case GL_ALPHA16F_EXT:
+ case GL_LUMINANCE_ALPHA16F_EXT:
+ case GL_RGB16F_EXT:
+ case GL_LUMINANCE16F_EXT:
+ return DXGI_FORMAT_R16G16B16A16_FLOAT;
+ case GL_BGRA8_EXT:
+ return DXGI_FORMAT_B8G8R8A8_UNORM;
+ case GL_R8_EXT:
+ return DXGI_FORMAT_R8_UNORM;
+ case GL_RG8_EXT:
+ return DXGI_FORMAT_R8G8_UNORM;
+ case GL_R16F_EXT:
+ return DXGI_FORMAT_R16_FLOAT;
+ case GL_RG16F_EXT:
+ return DXGI_FORMAT_R16G16_FLOAT;
+ case GL_DEPTH_COMPONENT16:
+ return DXGI_FORMAT_D16_UNORM;
+ case GL_DEPTH_COMPONENT32_OES:
+ case GL_DEPTH24_STENCIL8_OES:
+ return DXGI_FORMAT_D24_UNORM_S8_UINT;
+ case GL_NONE:
+ return DXGI_FORMAT_UNKNOWN;
+ default:
+ UNREACHABLE();
+ }
+
+ return DXGI_FORMAT_R8G8B8A8_UNORM;
+}
+
+}
+
+namespace d3d11
+{
+
+void SetPositionTexCoordVertex(PositionTexCoordVertex* vertex, float x, float y, float u, float v)
+{
+ vertex->x = x;
+ vertex->y = y;
+ vertex->u = u;
+ vertex->v = v;
+}
+
+void SetPositionDepthColorVertex(PositionDepthColorVertex* vertex, float x, float y, float z,
+ const gl::Color &color)
+{
+ vertex->x = x;
+ vertex->y = y;
+ vertex->z = z;
+ vertex->r = color.red;
+ vertex->g = color.green;
+ vertex->b = color.blue;
+ vertex->a = color.alpha;
+}
+
+size_t ComputePixelSizeBits(DXGI_FORMAT format)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_R1_UNORM:
+ return 1;
+
+ case DXGI_FORMAT_A8_UNORM:
+ case DXGI_FORMAT_R8_SINT:
+ case DXGI_FORMAT_R8_SNORM:
+ case DXGI_FORMAT_R8_TYPELESS:
+ case DXGI_FORMAT_R8_UINT:
+ case DXGI_FORMAT_R8_UNORM:
+ return 8;
+
+ case DXGI_FORMAT_B5G5R5A1_UNORM:
+ case DXGI_FORMAT_B5G6R5_UNORM:
+ case DXGI_FORMAT_D16_UNORM:
+ case DXGI_FORMAT_R16_FLOAT:
+ case DXGI_FORMAT_R16_SINT:
+ case DXGI_FORMAT_R16_SNORM:
+ case DXGI_FORMAT_R16_TYPELESS:
+ case DXGI_FORMAT_R16_UINT:
+ case DXGI_FORMAT_R16_UNORM:
+ case DXGI_FORMAT_R8G8_SINT:
+ case DXGI_FORMAT_R8G8_SNORM:
+ case DXGI_FORMAT_R8G8_TYPELESS:
+ case DXGI_FORMAT_R8G8_UINT:
+ case DXGI_FORMAT_R8G8_UNORM:
+ return 16;
+
+ case DXGI_FORMAT_B8G8R8X8_TYPELESS:
+ case DXGI_FORMAT_B8G8R8X8_UNORM:
+ case DXGI_FORMAT_B8G8R8X8_UNORM_SRGB:
+ case DXGI_FORMAT_D24_UNORM_S8_UINT:
+ case DXGI_FORMAT_D32_FLOAT:
+ case DXGI_FORMAT_D32_FLOAT_S8X24_UINT:
+ case DXGI_FORMAT_G8R8_G8B8_UNORM:
+ case DXGI_FORMAT_R10G10B10_XR_BIAS_A2_UNORM:
+ case DXGI_FORMAT_R10G10B10A2_TYPELESS:
+ case DXGI_FORMAT_R10G10B10A2_UINT:
+ case DXGI_FORMAT_R10G10B10A2_UNORM:
+ case DXGI_FORMAT_R11G11B10_FLOAT:
+ case DXGI_FORMAT_R16G16_FLOAT:
+ case DXGI_FORMAT_R16G16_SINT:
+ case DXGI_FORMAT_R16G16_SNORM:
+ case DXGI_FORMAT_R16G16_TYPELESS:
+ case DXGI_FORMAT_R16G16_UINT:
+ case DXGI_FORMAT_R16G16_UNORM:
+ case DXGI_FORMAT_R24_UNORM_X8_TYPELESS:
+ case DXGI_FORMAT_R24G8_TYPELESS:
+ case DXGI_FORMAT_R32_FLOAT:
+ case DXGI_FORMAT_R32_FLOAT_X8X24_TYPELESS:
+ case DXGI_FORMAT_R32_SINT:
+ case DXGI_FORMAT_R32_TYPELESS:
+ case DXGI_FORMAT_R32_UINT:
+ case DXGI_FORMAT_R8G8_B8G8_UNORM:
+ case DXGI_FORMAT_R8G8B8A8_SINT:
+ case DXGI_FORMAT_R8G8B8A8_SNORM:
+ case DXGI_FORMAT_R8G8B8A8_TYPELESS:
+ case DXGI_FORMAT_R8G8B8A8_UINT:
+ case DXGI_FORMAT_R8G8B8A8_UNORM:
+ case DXGI_FORMAT_R8G8B8A8_UNORM_SRGB:
+ case DXGI_FORMAT_B8G8R8A8_TYPELESS:
+ case DXGI_FORMAT_B8G8R8A8_UNORM:
+ case DXGI_FORMAT_B8G8R8A8_UNORM_SRGB:
+ case DXGI_FORMAT_R9G9B9E5_SHAREDEXP:
+ case DXGI_FORMAT_X24_TYPELESS_G8_UINT:
+ case DXGI_FORMAT_X32_TYPELESS_G8X24_UINT:
+ return 32;
+
+ case DXGI_FORMAT_R16G16B16A16_FLOAT:
+ case DXGI_FORMAT_R16G16B16A16_SINT:
+ case DXGI_FORMAT_R16G16B16A16_SNORM:
+ case DXGI_FORMAT_R16G16B16A16_TYPELESS:
+ case DXGI_FORMAT_R16G16B16A16_UINT:
+ case DXGI_FORMAT_R16G16B16A16_UNORM:
+ case DXGI_FORMAT_R32G32_FLOAT:
+ case DXGI_FORMAT_R32G32_SINT:
+ case DXGI_FORMAT_R32G32_TYPELESS:
+ case DXGI_FORMAT_R32G32_UINT:
+ case DXGI_FORMAT_R32G8X24_TYPELESS:
+ return 64;
+
+ case DXGI_FORMAT_R32G32B32_FLOAT:
+ case DXGI_FORMAT_R32G32B32_SINT:
+ case DXGI_FORMAT_R32G32B32_TYPELESS:
+ case DXGI_FORMAT_R32G32B32_UINT:
+ return 96;
+
+ case DXGI_FORMAT_R32G32B32A32_FLOAT:
+ case DXGI_FORMAT_R32G32B32A32_SINT:
+ case DXGI_FORMAT_R32G32B32A32_TYPELESS:
+ case DXGI_FORMAT_R32G32B32A32_UINT:
+ return 128;
+
+ case DXGI_FORMAT_BC1_TYPELESS:
+ case DXGI_FORMAT_BC1_UNORM:
+ case DXGI_FORMAT_BC1_UNORM_SRGB:
+ case DXGI_FORMAT_BC4_SNORM:
+ case DXGI_FORMAT_BC4_TYPELESS:
+ case DXGI_FORMAT_BC4_UNORM:
+ return 4;
+
+ case DXGI_FORMAT_BC2_TYPELESS:
+ case DXGI_FORMAT_BC2_UNORM:
+ case DXGI_FORMAT_BC2_UNORM_SRGB:
+ case DXGI_FORMAT_BC3_TYPELESS:
+ case DXGI_FORMAT_BC3_UNORM:
+ case DXGI_FORMAT_BC3_UNORM_SRGB:
+ case DXGI_FORMAT_BC5_SNORM:
+ case DXGI_FORMAT_BC5_TYPELESS:
+ case DXGI_FORMAT_BC5_UNORM:
+ case DXGI_FORMAT_BC6H_SF16:
+ case DXGI_FORMAT_BC6H_TYPELESS:
+ case DXGI_FORMAT_BC6H_UF16:
+ case DXGI_FORMAT_BC7_TYPELESS:
+ case DXGI_FORMAT_BC7_UNORM:
+ case DXGI_FORMAT_BC7_UNORM_SRGB:
+ return 8;
+
+ default:
+ return 0;
+ }
+}
+
+size_t ComputeBlockSizeBits(DXGI_FORMAT format)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_BC1_TYPELESS:
+ case DXGI_FORMAT_BC1_UNORM:
+ case DXGI_FORMAT_BC1_UNORM_SRGB:
+ case DXGI_FORMAT_BC4_SNORM:
+ case DXGI_FORMAT_BC4_TYPELESS:
+ case DXGI_FORMAT_BC4_UNORM:
+ case DXGI_FORMAT_BC2_TYPELESS:
+ case DXGI_FORMAT_BC2_UNORM:
+ case DXGI_FORMAT_BC2_UNORM_SRGB:
+ case DXGI_FORMAT_BC3_TYPELESS:
+ case DXGI_FORMAT_BC3_UNORM:
+ case DXGI_FORMAT_BC3_UNORM_SRGB:
+ case DXGI_FORMAT_BC5_SNORM:
+ case DXGI_FORMAT_BC5_TYPELESS:
+ case DXGI_FORMAT_BC5_UNORM:
+ case DXGI_FORMAT_BC6H_SF16:
+ case DXGI_FORMAT_BC6H_TYPELESS:
+ case DXGI_FORMAT_BC6H_UF16:
+ case DXGI_FORMAT_BC7_TYPELESS:
+ case DXGI_FORMAT_BC7_UNORM:
+ case DXGI_FORMAT_BC7_UNORM_SRGB:
+ return ComputePixelSizeBits(format) * 16;
+ default:
+ UNREACHABLE();
+ return 0;
+ }
+}
+
+bool IsCompressed(DXGI_FORMAT format)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_BC1_TYPELESS:
+ case DXGI_FORMAT_BC1_UNORM:
+ case DXGI_FORMAT_BC1_UNORM_SRGB:
+ case DXGI_FORMAT_BC4_SNORM:
+ case DXGI_FORMAT_BC4_TYPELESS:
+ case DXGI_FORMAT_BC4_UNORM:
+ case DXGI_FORMAT_BC2_TYPELESS:
+ case DXGI_FORMAT_BC2_UNORM:
+ case DXGI_FORMAT_BC2_UNORM_SRGB:
+ case DXGI_FORMAT_BC3_TYPELESS:
+ case DXGI_FORMAT_BC3_UNORM:
+ case DXGI_FORMAT_BC3_UNORM_SRGB:
+ case DXGI_FORMAT_BC5_SNORM:
+ case DXGI_FORMAT_BC5_TYPELESS:
+ case DXGI_FORMAT_BC5_UNORM:
+ case DXGI_FORMAT_BC6H_SF16:
+ case DXGI_FORMAT_BC6H_TYPELESS:
+ case DXGI_FORMAT_BC6H_UF16:
+ case DXGI_FORMAT_BC7_TYPELESS:
+ case DXGI_FORMAT_BC7_UNORM:
+ case DXGI_FORMAT_BC7_UNORM_SRGB:
+ return true;
+ case DXGI_FORMAT_UNKNOWN:
+ UNREACHABLE();
+ return false;
+ default:
+ return false;
+ }
+}
+
+unsigned int GetTextureFormatDimensionAlignment(DXGI_FORMAT format)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_BC1_TYPELESS:
+ case DXGI_FORMAT_BC1_UNORM:
+ case DXGI_FORMAT_BC1_UNORM_SRGB:
+ case DXGI_FORMAT_BC4_SNORM:
+ case DXGI_FORMAT_BC4_TYPELESS:
+ case DXGI_FORMAT_BC4_UNORM:
+ case DXGI_FORMAT_BC2_TYPELESS:
+ case DXGI_FORMAT_BC2_UNORM:
+ case DXGI_FORMAT_BC2_UNORM_SRGB:
+ case DXGI_FORMAT_BC3_TYPELESS:
+ case DXGI_FORMAT_BC3_UNORM:
+ case DXGI_FORMAT_BC3_UNORM_SRGB:
+ case DXGI_FORMAT_BC5_SNORM:
+ case DXGI_FORMAT_BC5_TYPELESS:
+ case DXGI_FORMAT_BC5_UNORM:
+ case DXGI_FORMAT_BC6H_SF16:
+ case DXGI_FORMAT_BC6H_TYPELESS:
+ case DXGI_FORMAT_BC6H_UF16:
+ case DXGI_FORMAT_BC7_TYPELESS:
+ case DXGI_FORMAT_BC7_UNORM:
+ case DXGI_FORMAT_BC7_UNORM_SRGB:
+ return 4;
+ case DXGI_FORMAT_UNKNOWN:
+ UNREACHABLE();
+ return 1;
+ default:
+ return 1;
+ }
+}
+
+bool IsDepthStencilFormat(DXGI_FORMAT format)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_D32_FLOAT_S8X24_UINT:
+ case DXGI_FORMAT_D32_FLOAT:
+ case DXGI_FORMAT_D24_UNORM_S8_UINT:
+ case DXGI_FORMAT_D16_UNORM:
+ return true;
+ default:
+ return false;
+ }
+}
+
+DXGI_FORMAT GetDepthTextureFormat(DXGI_FORMAT format)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_D32_FLOAT_S8X24_UINT: return DXGI_FORMAT_R32G8X24_TYPELESS;
+ case DXGI_FORMAT_D32_FLOAT: return DXGI_FORMAT_R32_TYPELESS;
+ case DXGI_FORMAT_D24_UNORM_S8_UINT: return DXGI_FORMAT_R24G8_TYPELESS;
+ case DXGI_FORMAT_D16_UNORM: return DXGI_FORMAT_R16_TYPELESS;
+ default: UNREACHABLE(); return DXGI_FORMAT_UNKNOWN;
+ }
+}
+
+DXGI_FORMAT GetDepthShaderResourceFormat(DXGI_FORMAT format)
+{
+ switch (format)
+ {
+ case DXGI_FORMAT_D32_FLOAT_S8X24_UINT: return DXGI_FORMAT_R32_FLOAT_X8X24_TYPELESS;
+ case DXGI_FORMAT_D32_FLOAT: return DXGI_FORMAT_R32_UINT;
+ case DXGI_FORMAT_D24_UNORM_S8_UINT: return DXGI_FORMAT_R24_UNORM_X8_TYPELESS;
+ case DXGI_FORMAT_D16_UNORM: return DXGI_FORMAT_R16_UNORM;
+ default: UNREACHABLE(); return DXGI_FORMAT_UNKNOWN;
+ }
+}
+
+HRESULT SetDebugName(ID3D11DeviceChild *resource, const char *name)
+{
+#if defined(_DEBUG)
+ return resource->SetPrivateData(WKPDID_D3DDebugObjectName, strlen(name), name);
+#else
+ return S_OK;
+#endif
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/renderer11_utils.h b/src/3rdparty/angle/src/libGLESv2/renderer/renderer11_utils.h
new file mode 100644
index 0000000000..1bc48c1a13
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/renderer11_utils.h
@@ -0,0 +1,95 @@
+//
+// Copyright (c) 2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// renderer11_utils.h: Conversion functions and other utility routines
+// specific to the D3D11 renderer.
+
+#ifndef LIBGLESV2_RENDERER_RENDERER11_UTILS_H
+#define LIBGLESV2_RENDERER_RENDERER11_UTILS_H
+
+#include "libGLESv2/angletypes.h"
+
+namespace gl_d3d11
+{
+
+D3D11_BLEND ConvertBlendFunc(GLenum glBlend, bool isAlpha);
+D3D11_BLEND_OP ConvertBlendOp(GLenum glBlendOp);
+UINT8 ConvertColorMask(bool maskRed, bool maskGreen, bool maskBlue, bool maskAlpha);
+
+D3D11_CULL_MODE ConvertCullMode(bool cullEnabled, GLenum cullMode);
+
+D3D11_COMPARISON_FUNC ConvertComparison(GLenum comparison);
+D3D11_DEPTH_WRITE_MASK ConvertDepthMask(bool depthWriteEnabled);
+UINT8 ConvertStencilMask(GLuint stencilmask);
+D3D11_STENCIL_OP ConvertStencilOp(GLenum stencilOp);
+
+D3D11_FILTER ConvertFilter(GLenum minFilter, GLenum magFilter, float maxAnisotropy);
+D3D11_TEXTURE_ADDRESS_MODE ConvertTextureWrap(GLenum wrap);
+FLOAT ConvertMinLOD(GLenum minFilter, unsigned int lodOffset);
+FLOAT ConvertMaxLOD(GLenum minFilter, unsigned int lodOffset);
+
+DXGI_FORMAT ConvertRenderbufferFormat(GLenum format);
+DXGI_FORMAT ConvertTextureFormat(GLenum format);
+}
+
+namespace d3d11_gl
+{
+
+GLenum ConvertBackBufferFormat(DXGI_FORMAT format);
+GLenum ConvertDepthStencilFormat(DXGI_FORMAT format);
+GLenum ConvertRenderbufferFormat(DXGI_FORMAT format);
+GLenum ConvertTextureInternalFormat(DXGI_FORMAT format);
+
+}
+
+namespace d3d11
+{
+
+struct PositionTexCoordVertex
+{
+ float x, y;
+ float u, v;
+};
+void SetPositionTexCoordVertex(PositionTexCoordVertex* vertex, float x, float y, float u, float v);
+
+struct PositionDepthColorVertex
+{
+ float x, y, z;
+ float r, g, b, a;
+};
+void SetPositionDepthColorVertex(PositionDepthColorVertex* vertex, float x, float y, float z,
+ const gl::Color &color);
+
+size_t ComputePixelSizeBits(DXGI_FORMAT format);
+size_t ComputeBlockSizeBits(DXGI_FORMAT format);
+
+bool IsCompressed(DXGI_FORMAT format);
+unsigned int GetTextureFormatDimensionAlignment(DXGI_FORMAT format);
+
+bool IsDepthStencilFormat(DXGI_FORMAT format);
+DXGI_FORMAT GetDepthTextureFormat(DXGI_FORMAT format);
+DXGI_FORMAT GetDepthShaderResourceFormat(DXGI_FORMAT format);
+
+HRESULT SetDebugName(ID3D11DeviceChild *resource, const char *name);
+
+inline bool isDeviceLostError(HRESULT errorCode)
+{
+ switch (errorCode)
+ {
+ case DXGI_ERROR_DEVICE_HUNG:
+ case DXGI_ERROR_DEVICE_REMOVED:
+ case DXGI_ERROR_DEVICE_RESET:
+ case DXGI_ERROR_DRIVER_INTERNAL_ERROR:
+ case DXGI_ERROR_NOT_CURRENTLY_AVAILABLE:
+ return true;
+ default:
+ return false;
+ }
+}
+
+}
+
+#endif // LIBGLESV2_RENDERER_RENDERER11_UTILS_H
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/renderer9_utils.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/renderer9_utils.cpp
new file mode 100644
index 0000000000..da75d465e3
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/renderer9_utils.cpp
@@ -0,0 +1,500 @@
+#include "precompiled.h"
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// renderer9_utils.cpp: Conversion functions and other utility routines
+// specific to the D3D9 renderer.
+
+#include "libGLESv2/renderer/renderer9_utils.h"
+#include "libGLESv2/mathutil.h"
+#include "libGLESv2/Context.h"
+
+#include "common/debug.h"
+
+namespace gl_d3d9
+{
+
+D3DCMPFUNC ConvertComparison(GLenum comparison)
+{
+ D3DCMPFUNC d3dComp = D3DCMP_ALWAYS;
+ switch (comparison)
+ {
+ case GL_NEVER: d3dComp = D3DCMP_NEVER; break;
+ case GL_ALWAYS: d3dComp = D3DCMP_ALWAYS; break;
+ case GL_LESS: d3dComp = D3DCMP_LESS; break;
+ case GL_LEQUAL: d3dComp = D3DCMP_LESSEQUAL; break;
+ case GL_EQUAL: d3dComp = D3DCMP_EQUAL; break;
+ case GL_GREATER: d3dComp = D3DCMP_GREATER; break;
+ case GL_GEQUAL: d3dComp = D3DCMP_GREATEREQUAL; break;
+ case GL_NOTEQUAL: d3dComp = D3DCMP_NOTEQUAL; break;
+ default: UNREACHABLE();
+ }
+
+ return d3dComp;
+}
+
+D3DCOLOR ConvertColor(gl::Color color)
+{
+ return D3DCOLOR_RGBA(gl::unorm<8>(color.red),
+ gl::unorm<8>(color.green),
+ gl::unorm<8>(color.blue),
+ gl::unorm<8>(color.alpha));
+}
+
+D3DBLEND ConvertBlendFunc(GLenum blend)
+{
+ D3DBLEND d3dBlend = D3DBLEND_ZERO;
+
+ switch (blend)
+ {
+ case GL_ZERO: d3dBlend = D3DBLEND_ZERO; break;
+ case GL_ONE: d3dBlend = D3DBLEND_ONE; break;
+ case GL_SRC_COLOR: d3dBlend = D3DBLEND_SRCCOLOR; break;
+ case GL_ONE_MINUS_SRC_COLOR: d3dBlend = D3DBLEND_INVSRCCOLOR; break;
+ case GL_DST_COLOR: d3dBlend = D3DBLEND_DESTCOLOR; break;
+ case GL_ONE_MINUS_DST_COLOR: d3dBlend = D3DBLEND_INVDESTCOLOR; break;
+ case GL_SRC_ALPHA: d3dBlend = D3DBLEND_SRCALPHA; break;
+ case GL_ONE_MINUS_SRC_ALPHA: d3dBlend = D3DBLEND_INVSRCALPHA; break;
+ case GL_DST_ALPHA: d3dBlend = D3DBLEND_DESTALPHA; break;
+ case GL_ONE_MINUS_DST_ALPHA: d3dBlend = D3DBLEND_INVDESTALPHA; break;
+ case GL_CONSTANT_COLOR: d3dBlend = D3DBLEND_BLENDFACTOR; break;
+ case GL_ONE_MINUS_CONSTANT_COLOR: d3dBlend = D3DBLEND_INVBLENDFACTOR; break;
+ case GL_CONSTANT_ALPHA: d3dBlend = D3DBLEND_BLENDFACTOR; break;
+ case GL_ONE_MINUS_CONSTANT_ALPHA: d3dBlend = D3DBLEND_INVBLENDFACTOR; break;
+ case GL_SRC_ALPHA_SATURATE: d3dBlend = D3DBLEND_SRCALPHASAT; break;
+ default: UNREACHABLE();
+ }
+
+ return d3dBlend;
+}
+
+D3DBLENDOP ConvertBlendOp(GLenum blendOp)
+{
+ D3DBLENDOP d3dBlendOp = D3DBLENDOP_ADD;
+
+ switch (blendOp)
+ {
+ case GL_FUNC_ADD: d3dBlendOp = D3DBLENDOP_ADD; break;
+ case GL_FUNC_SUBTRACT: d3dBlendOp = D3DBLENDOP_SUBTRACT; break;
+ case GL_FUNC_REVERSE_SUBTRACT: d3dBlendOp = D3DBLENDOP_REVSUBTRACT; break;
+ default: UNREACHABLE();
+ }
+
+ return d3dBlendOp;
+}
+
+D3DSTENCILOP ConvertStencilOp(GLenum stencilOp)
+{
+ D3DSTENCILOP d3dStencilOp = D3DSTENCILOP_KEEP;
+
+ switch (stencilOp)
+ {
+ case GL_ZERO: d3dStencilOp = D3DSTENCILOP_ZERO; break;
+ case GL_KEEP: d3dStencilOp = D3DSTENCILOP_KEEP; break;
+ case GL_REPLACE: d3dStencilOp = D3DSTENCILOP_REPLACE; break;
+ case GL_INCR: d3dStencilOp = D3DSTENCILOP_INCRSAT; break;
+ case GL_DECR: d3dStencilOp = D3DSTENCILOP_DECRSAT; break;
+ case GL_INVERT: d3dStencilOp = D3DSTENCILOP_INVERT; break;
+ case GL_INCR_WRAP: d3dStencilOp = D3DSTENCILOP_INCR; break;
+ case GL_DECR_WRAP: d3dStencilOp = D3DSTENCILOP_DECR; break;
+ default: UNREACHABLE();
+ }
+
+ return d3dStencilOp;
+}
+
+D3DTEXTUREADDRESS ConvertTextureWrap(GLenum wrap)
+{
+ D3DTEXTUREADDRESS d3dWrap = D3DTADDRESS_WRAP;
+
+ switch (wrap)
+ {
+ case GL_REPEAT: d3dWrap = D3DTADDRESS_WRAP; break;
+ case GL_CLAMP_TO_EDGE: d3dWrap = D3DTADDRESS_CLAMP; break;
+ case GL_MIRRORED_REPEAT: d3dWrap = D3DTADDRESS_MIRROR; break;
+ default: UNREACHABLE();
+ }
+
+ return d3dWrap;
+}
+
+D3DCULL ConvertCullMode(GLenum cullFace, GLenum frontFace)
+{
+ D3DCULL cull = D3DCULL_CCW;
+ switch (cullFace)
+ {
+ case GL_FRONT:
+ cull = (frontFace == GL_CCW ? D3DCULL_CW : D3DCULL_CCW);
+ break;
+ case GL_BACK:
+ cull = (frontFace == GL_CCW ? D3DCULL_CCW : D3DCULL_CW);
+ break;
+ case GL_FRONT_AND_BACK:
+ cull = D3DCULL_NONE; // culling will be handled during draw
+ break;
+ default: UNREACHABLE();
+ }
+
+ return cull;
+}
+
+D3DCUBEMAP_FACES ConvertCubeFace(GLenum cubeFace)
+{
+ D3DCUBEMAP_FACES face = D3DCUBEMAP_FACE_POSITIVE_X;
+
+ switch (cubeFace)
+ {
+ case GL_TEXTURE_CUBE_MAP_POSITIVE_X:
+ face = D3DCUBEMAP_FACE_POSITIVE_X;
+ break;
+ case GL_TEXTURE_CUBE_MAP_NEGATIVE_X:
+ face = D3DCUBEMAP_FACE_NEGATIVE_X;
+ break;
+ case GL_TEXTURE_CUBE_MAP_POSITIVE_Y:
+ face = D3DCUBEMAP_FACE_POSITIVE_Y;
+ break;
+ case GL_TEXTURE_CUBE_MAP_NEGATIVE_Y:
+ face = D3DCUBEMAP_FACE_NEGATIVE_Y;
+ break;
+ case GL_TEXTURE_CUBE_MAP_POSITIVE_Z:
+ face = D3DCUBEMAP_FACE_POSITIVE_Z;
+ break;
+ case GL_TEXTURE_CUBE_MAP_NEGATIVE_Z:
+ face = D3DCUBEMAP_FACE_NEGATIVE_Z;
+ break;
+ default: UNREACHABLE();
+ }
+
+ return face;
+}
+
+DWORD ConvertColorMask(bool red, bool green, bool blue, bool alpha)
+{
+ return (red ? D3DCOLORWRITEENABLE_RED : 0) |
+ (green ? D3DCOLORWRITEENABLE_GREEN : 0) |
+ (blue ? D3DCOLORWRITEENABLE_BLUE : 0) |
+ (alpha ? D3DCOLORWRITEENABLE_ALPHA : 0);
+}
+
+D3DTEXTUREFILTERTYPE ConvertMagFilter(GLenum magFilter, float maxAnisotropy)
+{
+ if (maxAnisotropy > 1.0f)
+ {
+ return D3DTEXF_ANISOTROPIC;
+ }
+
+ D3DTEXTUREFILTERTYPE d3dMagFilter = D3DTEXF_POINT;
+ switch (magFilter)
+ {
+ case GL_NEAREST: d3dMagFilter = D3DTEXF_POINT; break;
+ case GL_LINEAR: d3dMagFilter = D3DTEXF_LINEAR; break;
+ default: UNREACHABLE();
+ }
+
+ return d3dMagFilter;
+}
+
+void ConvertMinFilter(GLenum minFilter, D3DTEXTUREFILTERTYPE *d3dMinFilter, D3DTEXTUREFILTERTYPE *d3dMipFilter, float maxAnisotropy)
+{
+ switch (minFilter)
+ {
+ case GL_NEAREST:
+ *d3dMinFilter = D3DTEXF_POINT;
+ *d3dMipFilter = D3DTEXF_NONE;
+ break;
+ case GL_LINEAR:
+ *d3dMinFilter = D3DTEXF_LINEAR;
+ *d3dMipFilter = D3DTEXF_NONE;
+ break;
+ case GL_NEAREST_MIPMAP_NEAREST:
+ *d3dMinFilter = D3DTEXF_POINT;
+ *d3dMipFilter = D3DTEXF_POINT;
+ break;
+ case GL_LINEAR_MIPMAP_NEAREST:
+ *d3dMinFilter = D3DTEXF_LINEAR;
+ *d3dMipFilter = D3DTEXF_POINT;
+ break;
+ case GL_NEAREST_MIPMAP_LINEAR:
+ *d3dMinFilter = D3DTEXF_POINT;
+ *d3dMipFilter = D3DTEXF_LINEAR;
+ break;
+ case GL_LINEAR_MIPMAP_LINEAR:
+ *d3dMinFilter = D3DTEXF_LINEAR;
+ *d3dMipFilter = D3DTEXF_LINEAR;
+ break;
+ default:
+ *d3dMinFilter = D3DTEXF_POINT;
+ *d3dMipFilter = D3DTEXF_NONE;
+ UNREACHABLE();
+ }
+
+ if (maxAnisotropy > 1.0f)
+ {
+ *d3dMinFilter = D3DTEXF_ANISOTROPIC;
+ }
+}
+
+D3DFORMAT ConvertRenderbufferFormat(GLenum format)
+{
+ switch (format)
+ {
+ case GL_NONE: return D3DFMT_NULL;
+ case GL_RGBA4:
+ case GL_RGB5_A1:
+ case GL_RGBA8_OES: return D3DFMT_A8R8G8B8;
+ case GL_RGB565: return D3DFMT_R5G6B5;
+ case GL_RGB8_OES: return D3DFMT_X8R8G8B8;
+ case GL_DEPTH_COMPONENT16:
+ case GL_STENCIL_INDEX8:
+ case GL_DEPTH24_STENCIL8_OES: return D3DFMT_D24S8;
+ default: UNREACHABLE(); return D3DFMT_A8R8G8B8;
+ }
+}
+
+D3DMULTISAMPLE_TYPE GetMultisampleTypeFromSamples(GLsizei samples)
+{
+ if (samples <= 1)
+ return D3DMULTISAMPLE_NONE;
+ else
+ return (D3DMULTISAMPLE_TYPE)samples;
+}
+
+}
+
+namespace d3d9_gl
+{
+
+unsigned int GetStencilSize(D3DFORMAT stencilFormat)
+{
+ if (stencilFormat == D3DFMT_INTZ)
+ {
+ return 8;
+ }
+ switch(stencilFormat)
+ {
+ case D3DFMT_D24FS8:
+ case D3DFMT_D24S8:
+ return 8;
+ case D3DFMT_D24X4S4:
+ return 4;
+ case D3DFMT_D15S1:
+ return 1;
+ case D3DFMT_D16_LOCKABLE:
+ case D3DFMT_D32:
+ case D3DFMT_D24X8:
+ case D3DFMT_D32F_LOCKABLE:
+ case D3DFMT_D16:
+ return 0;
+ //case D3DFMT_D32_LOCKABLE: return 0; // DirectX 9Ex only
+ //case D3DFMT_S8_LOCKABLE: return 8; // DirectX 9Ex only
+ default:
+ return 0;
+ }
+}
+
+unsigned int GetAlphaSize(D3DFORMAT colorFormat)
+{
+ switch (colorFormat)
+ {
+ case D3DFMT_A16B16G16R16F:
+ return 16;
+ case D3DFMT_A32B32G32R32F:
+ return 32;
+ case D3DFMT_A2R10G10B10:
+ return 2;
+ case D3DFMT_A8R8G8B8:
+ return 8;
+ case D3DFMT_A1R5G5B5:
+ return 1;
+ case D3DFMT_X8R8G8B8:
+ case D3DFMT_R5G6B5:
+ return 0;
+ default:
+ return 0;
+ }
+}
+
+GLsizei GetSamplesFromMultisampleType(D3DMULTISAMPLE_TYPE type)
+{
+ if (type == D3DMULTISAMPLE_NONMASKABLE)
+ return 0;
+ else
+ return type;
+}
+
+bool IsFormatChannelEquivalent(D3DFORMAT d3dformat, GLenum format)
+{
+ switch (d3dformat)
+ {
+ case D3DFMT_L8:
+ return (format == GL_LUMINANCE);
+ case D3DFMT_A8L8:
+ return (format == GL_LUMINANCE_ALPHA);
+ case D3DFMT_DXT1:
+ return (format == GL_COMPRESSED_RGBA_S3TC_DXT1_EXT || format == GL_COMPRESSED_RGB_S3TC_DXT1_EXT);
+ case D3DFMT_DXT3:
+ return (format == GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE);
+ case D3DFMT_DXT5:
+ return (format == GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE);
+ case D3DFMT_A8R8G8B8:
+ case D3DFMT_A16B16G16R16F:
+ case D3DFMT_A32B32G32R32F:
+ return (format == GL_RGBA || format == GL_BGRA_EXT);
+ case D3DFMT_X8R8G8B8:
+ return (format == GL_RGB);
+ default:
+ if (d3dformat == D3DFMT_INTZ && gl::IsDepthTexture(format))
+ return true;
+ return false;
+ }
+}
+
+GLenum ConvertBackBufferFormat(D3DFORMAT format)
+{
+ switch (format)
+ {
+ case D3DFMT_A4R4G4B4: return GL_RGBA4;
+ case D3DFMT_A8R8G8B8: return GL_RGBA8_OES;
+ case D3DFMT_A1R5G5B5: return GL_RGB5_A1;
+ case D3DFMT_R5G6B5: return GL_RGB565;
+ case D3DFMT_X8R8G8B8: return GL_RGB8_OES;
+ default:
+ UNREACHABLE();
+ }
+
+ return GL_RGBA4;
+}
+
+GLenum ConvertDepthStencilFormat(D3DFORMAT format)
+{
+ if (format == D3DFMT_INTZ)
+ {
+ return GL_DEPTH24_STENCIL8_OES;
+ }
+ switch (format)
+ {
+ case D3DFMT_D16:
+ case D3DFMT_D24X8:
+ return GL_DEPTH_COMPONENT16;
+ case D3DFMT_D24S8:
+ return GL_DEPTH24_STENCIL8_OES;
+ case D3DFMT_UNKNOWN:
+ return GL_NONE;
+ default:
+ UNREACHABLE();
+ }
+
+ return GL_DEPTH24_STENCIL8_OES;
+}
+
+GLenum ConvertRenderTargetFormat(D3DFORMAT format)
+{
+ if (format == D3DFMT_INTZ)
+ {
+ return GL_DEPTH24_STENCIL8_OES;
+ }
+
+ switch (format)
+ {
+ case D3DFMT_A4R4G4B4: return GL_RGBA4;
+ case D3DFMT_A8R8G8B8: return GL_RGBA8_OES;
+ case D3DFMT_A1R5G5B5: return GL_RGB5_A1;
+ case D3DFMT_R5G6B5: return GL_RGB565;
+ case D3DFMT_X8R8G8B8: return GL_RGB8_OES;
+ case D3DFMT_D16:
+ case D3DFMT_D24X8:
+ return GL_DEPTH_COMPONENT16;
+ case D3DFMT_D24S8:
+ return GL_DEPTH24_STENCIL8_OES;
+ case D3DFMT_UNKNOWN:
+ return GL_NONE;
+ default:
+ UNREACHABLE();
+ }
+
+ return GL_RGBA4;
+}
+
+GLenum GetEquivalentFormat(D3DFORMAT format)
+{
+ if (format == D3DFMT_INTZ)
+ return GL_DEPTH24_STENCIL8_OES;
+ if (format == D3DFMT_NULL)
+ return GL_NONE;
+
+ switch (format)
+ {
+ case D3DFMT_A4R4G4B4: return GL_RGBA4;
+ case D3DFMT_A8R8G8B8: return GL_RGBA8_OES;
+ case D3DFMT_A1R5G5B5: return GL_RGB5_A1;
+ case D3DFMT_R5G6B5: return GL_RGB565;
+ case D3DFMT_X8R8G8B8: return GL_RGB8_OES;
+ case D3DFMT_D16: return GL_DEPTH_COMPONENT16;
+ case D3DFMT_D24S8: return GL_DEPTH24_STENCIL8_OES;
+ case D3DFMT_UNKNOWN: return GL_NONE;
+ case D3DFMT_DXT1: return GL_COMPRESSED_RGBA_S3TC_DXT1_EXT;
+ case D3DFMT_DXT3: return GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE;
+ case D3DFMT_DXT5: return GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE;
+ case D3DFMT_A32B32G32R32F: return GL_RGBA32F_EXT;
+ case D3DFMT_A16B16G16R16F: return GL_RGBA16F_EXT;
+ case D3DFMT_L8: return GL_LUMINANCE8_EXT;
+ case D3DFMT_A8L8: return GL_LUMINANCE8_ALPHA8_EXT;
+ default: UNREACHABLE();
+ return GL_NONE;
+ }
+}
+
+}
+
+namespace d3d9
+{
+
+bool IsCompressedFormat(D3DFORMAT surfaceFormat)
+{
+ switch(surfaceFormat)
+ {
+ case D3DFMT_DXT1:
+ case D3DFMT_DXT2:
+ case D3DFMT_DXT3:
+ case D3DFMT_DXT4:
+ case D3DFMT_DXT5:
+ return true;
+ default:
+ return false;
+ }
+}
+
+size_t ComputeRowSize(D3DFORMAT format, unsigned int width)
+{
+ if (format == D3DFMT_INTZ)
+ {
+ return 4 * width;
+ }
+ switch (format)
+ {
+ case D3DFMT_L8:
+ return 1 * width;
+ case D3DFMT_A8L8:
+ return 2 * width;
+ case D3DFMT_X8R8G8B8:
+ case D3DFMT_A8R8G8B8:
+ return 4 * width;
+ case D3DFMT_A16B16G16R16F:
+ return 8 * width;
+ case D3DFMT_A32B32G32R32F:
+ return 16 * width;
+ case D3DFMT_DXT1:
+ return 8 * ((width + 3) / 4);
+ case D3DFMT_DXT3:
+ case D3DFMT_DXT5:
+ return 16 * ((width + 3) / 4);
+ default:
+ UNREACHABLE();
+ return 0;
+ }
+}
+
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/renderer9_utils.h b/src/3rdparty/angle/src/libGLESv2/renderer/renderer9_utils.h
new file mode 100644
index 0000000000..bf6cdf1ea6
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/renderer9_utils.h
@@ -0,0 +1,74 @@
+//
+// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+//
+
+// renderer9_utils.h: Conversion functions and other utility routines
+// specific to the D3D9 renderer
+
+#ifndef LIBGLESV2_RENDERER_RENDERER9_UTILS_H
+#define LIBGLESV2_RENDERER_RENDERER9_UTILS_H
+
+#include "libGLESv2/utilities.h"
+
+const D3DFORMAT D3DFMT_INTZ = ((D3DFORMAT)(MAKEFOURCC('I','N','T','Z')));
+const D3DFORMAT D3DFMT_NULL = ((D3DFORMAT)(MAKEFOURCC('N','U','L','L')));
+
+namespace gl_d3d9
+{
+
+D3DCMPFUNC ConvertComparison(GLenum comparison);
+D3DCOLOR ConvertColor(gl::Color color);
+D3DBLEND ConvertBlendFunc(GLenum blend);
+D3DBLENDOP ConvertBlendOp(GLenum blendOp);
+D3DSTENCILOP ConvertStencilOp(GLenum stencilOp);
+D3DTEXTUREADDRESS ConvertTextureWrap(GLenum wrap);
+D3DCULL ConvertCullMode(GLenum cullFace, GLenum frontFace);
+D3DCUBEMAP_FACES ConvertCubeFace(GLenum cubeFace);
+DWORD ConvertColorMask(bool red, bool green, bool blue, bool alpha);
+D3DTEXTUREFILTERTYPE ConvertMagFilter(GLenum magFilter, float maxAnisotropy);
+void ConvertMinFilter(GLenum minFilter, D3DTEXTUREFILTERTYPE *d3dMinFilter, D3DTEXTUREFILTERTYPE *d3dMipFilter, float maxAnisotropy);
+D3DFORMAT ConvertRenderbufferFormat(GLenum format);
+D3DMULTISAMPLE_TYPE GetMultisampleTypeFromSamples(GLsizei samples);
+
+}
+
+namespace d3d9_gl
+{
+
+GLuint GetAlphaSize(D3DFORMAT colorFormat);
+GLuint GetStencilSize(D3DFORMAT stencilFormat);
+
+GLsizei GetSamplesFromMultisampleType(D3DMULTISAMPLE_TYPE type);
+
+bool IsFormatChannelEquivalent(D3DFORMAT d3dformat, GLenum format);
+GLenum ConvertBackBufferFormat(D3DFORMAT format);
+GLenum ConvertDepthStencilFormat(D3DFORMAT format);
+GLenum ConvertRenderTargetFormat(D3DFORMAT format);
+GLenum GetEquivalentFormat(D3DFORMAT format);
+
+}
+
+namespace d3d9
+{
+bool IsCompressedFormat(D3DFORMAT format);
+size_t ComputeRowSize(D3DFORMAT format, unsigned int width);
+
+inline bool isDeviceLostError(HRESULT errorCode)
+{
+ switch (errorCode)
+ {
+ case D3DERR_DRIVERINTERNALERROR:
+ case D3DERR_DEVICELOST:
+ case D3DERR_DEVICEHUNG:
+ case D3DERR_DEVICEREMOVED:
+ return true;
+ default:
+ return false;
+ }
+}
+
+}
+
+#endif // LIBGLESV2_RENDERER_RENDERER9_UTILS_H
diff --git a/src/3rdparty/angle/src/libGLESv2/shaders/Blit.ps b/src/3rdparty/angle/src/libGLESv2/renderer/shaders/Blit.ps
index dcb3bd0e76..dcb3bd0e76 100644
--- a/src/3rdparty/angle/src/libGLESv2/shaders/Blit.ps
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/shaders/Blit.ps
diff --git a/src/3rdparty/angle/src/libGLESv2/shaders/Blit.vs b/src/3rdparty/angle/src/libGLESv2/renderer/shaders/Blit.vs
index 3a36980b93..3a36980b93 100644
--- a/src/3rdparty/angle/src/libGLESv2/shaders/Blit.vs
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/shaders/Blit.vs
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/shaders/Clear11.hlsl b/src/3rdparty/angle/src/libGLESv2/renderer/shaders/Clear11.hlsl
new file mode 100644
index 0000000000..d2752601e9
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/shaders/Clear11.hlsl
@@ -0,0 +1,33 @@
+void VS_Clear( in float3 inPosition : POSITION, in float4 inColor : COLOR,
+ out float4 outPosition : SV_POSITION, out float4 outColor : COLOR)
+{
+ outPosition = float4(inPosition, 1.0f);
+ outColor = inColor;
+}
+
+// Assume we are in SM4+, which has 8 color outputs
+struct PS_Output
+{
+ float4 color0 : SV_TARGET0;
+ float4 color1 : SV_TARGET1;
+ float4 color2 : SV_TARGET2;
+ float4 color3 : SV_TARGET3;
+ float4 color4 : SV_TARGET4;
+ float4 color5 : SV_TARGET5;
+ float4 color6 : SV_TARGET6;
+ float4 color7 : SV_TARGET7;
+};
+
+PS_Output PS_Clear(in float4 inPosition : SV_POSITION, in float4 inColor : COLOR)
+{
+ PS_Output outColor;
+ outColor.color0 = inColor;
+ outColor.color1 = inColor;
+ outColor.color2 = inColor;
+ outColor.color3 = inColor;
+ outColor.color4 = inColor;
+ outColor.color5 = inColor;
+ outColor.color6 = inColor;
+ outColor.color7 = inColor;
+ return outColor;
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/shaders/Passthrough11.hlsl b/src/3rdparty/angle/src/libGLESv2/renderer/shaders/Passthrough11.hlsl
new file mode 100644
index 0000000000..43b7801efc
--- /dev/null
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/shaders/Passthrough11.hlsl
@@ -0,0 +1,29 @@
+Texture2D Texture : register(t0);
+SamplerState Sampler : register(s0);
+
+void VS_Passthrough( in float2 inPosition : POSITION, in float2 inTexCoord : TEXCOORD0,
+ out float4 outPosition : SV_POSITION, out float2 outTexCoord : TEXCOORD0)
+{
+ outPosition = float4(inPosition, 0.0f, 1.0f);
+ outTexCoord = inTexCoord;
+}
+
+float4 PS_PassthroughRGBA(in float4 inPosition : SV_POSITION, in float2 inTexCoord : TEXCOORD0) : SV_TARGET0
+{
+ return Texture.Sample(Sampler, inTexCoord).rgba;
+}
+
+float4 PS_PassthroughRGB(in float4 inPosition : SV_POSITION, in float2 inTexCoord : TEXCOORD0) : SV_TARGET0
+{
+ return float4(Texture.Sample(Sampler, inTexCoord).rgb, 1.0f);
+}
+
+float4 PS_PassthroughLum(in float4 inPosition : SV_POSITION, in float2 inTexCoord : TEXCOORD0) : SV_TARGET0
+{
+ return float4(Texture.Sample(Sampler, inTexCoord).rrr, 1.0f);
+}
+
+float4 PS_PassthroughLumAlpha(in float4 inPosition : SV_POSITION, in float2 inTexCoord : TEXCOORD0) : SV_TARGET0
+{
+ return Texture.Sample(Sampler, inTexCoord).rrra;
+}
diff --git a/src/3rdparty/angle/src/libGLESv2/vertexconversion.h b/src/3rdparty/angle/src/libGLESv2/renderer/vertexconversion.h
index 5bb8b8995e..590b9d48a3 100644
--- a/src/3rdparty/angle/src/libGLESv2/vertexconversion.h
+++ b/src/3rdparty/angle/src/libGLESv2/renderer/vertexconversion.h
@@ -10,12 +10,7 @@
#ifndef LIBGLESV2_VERTEXCONVERSION_H_
#define LIBGLESV2_VERTEXCONVERSION_H_
-#include <cstddef>
-#include <limits>
-
-#include "libGLESv2/Context.h" // Defines Index
-
-namespace gl
+namespace rx
{
// Conversion types:
diff --git a/src/3rdparty/angle/src/libGLESv2/utilities.cpp b/src/3rdparty/angle/src/libGLESv2/utilities.cpp
index a3eb27d392..9809b9d8e8 100644
--- a/src/3rdparty/angle/src/libGLESv2/utilities.cpp
+++ b/src/3rdparty/angle/src/libGLESv2/utilities.cpp
@@ -1,5 +1,6 @@
+#include "precompiled.h"
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -7,21 +8,12 @@
// utilities.cpp: Conversion functions and other utility routines.
#include "libGLESv2/utilities.h"
-
-#include <limits>
-#include <stdio.h>
-#include <windows.h>
-
-#include "common/debug.h"
-
#include "libGLESv2/mathutil.h"
-#include "libGLESv2/Context.h"
namespace gl
{
-// This is how much data the application expects for a uniform
-int UniformExternalComponentCount(GLenum type)
+int UniformComponentCount(GLenum type)
{
switch (type)
{
@@ -55,42 +47,6 @@ int UniformExternalComponentCount(GLenum type)
return 0;
}
-// This is how much data we actually store for a uniform
-int UniformInternalComponentCount(GLenum type)
-{
- switch (type)
- {
- case GL_BOOL:
- case GL_INT:
- case GL_SAMPLER_2D:
- case GL_SAMPLER_CUBE:
- return 1;
- case GL_BOOL_VEC2:
- case GL_INT_VEC2:
- return 2;
- case GL_INT_VEC3:
- case GL_BOOL_VEC3:
- return 3;
- case GL_FLOAT:
- case GL_FLOAT_VEC2:
- case GL_FLOAT_VEC3:
- case GL_BOOL_VEC4:
- case GL_FLOAT_VEC4:
- case GL_INT_VEC4:
- return 4;
- case GL_FLOAT_MAT2:
- return 8;
- case GL_FLOAT_MAT3:
- return 12;
- case GL_FLOAT_MAT4:
- return 16;
- default:
- UNREACHABLE();
- }
-
- return 0;
-}
-
GLenum UniformComponentType(GLenum type)
{
switch(type)
@@ -137,12 +93,13 @@ size_t UniformComponentSize(GLenum type)
size_t UniformInternalSize(GLenum type)
{
- return UniformComponentSize(UniformComponentType(type)) * UniformInternalComponentCount(type);
+ // Expanded to 4-element vectors
+ return UniformComponentSize(UniformComponentType(type)) * VariableRowCount(type) * 4;
}
size_t UniformExternalSize(GLenum type)
{
- return UniformComponentSize(UniformComponentType(type)) * UniformExternalComponentCount(type);
+ return UniformComponentSize(UniformComponentType(type)) * UniformComponentCount(type);
}
int VariableRowCount(GLenum type)
@@ -163,6 +120,8 @@ int VariableRowCount(GLenum type)
case GL_BOOL_VEC4:
case GL_FLOAT_VEC4:
case GL_INT_VEC4:
+ case GL_SAMPLER_2D:
+ case GL_SAMPLER_CUBE:
return 1;
case GL_FLOAT_MAT2:
return 2;
@@ -186,6 +145,8 @@ int VariableColumnCount(GLenum type)
case GL_BOOL:
case GL_FLOAT:
case GL_INT:
+ case GL_SAMPLER_2D:
+ case GL_SAMPLER_CUBE:
return 1;
case GL_BOOL_VEC2:
case GL_FLOAT_VEC2:
@@ -297,6 +258,27 @@ bool IsStencilTexture(GLenum format)
return false;
}
+void MakeValidSize(bool isImage, bool isCompressed, GLsizei *requestWidth, GLsizei *requestHeight, int *levelOffset)
+{
+ int upsampleCount = 0;
+
+ if (isCompressed)
+ {
+ // Don't expand the size of full textures that are at least 4x4
+ // already.
+ if (isImage || *requestWidth < 4 || *requestHeight < 4)
+ {
+ while (*requestWidth % 4 != 0 || *requestHeight % 4 != 0)
+ {
+ *requestWidth <<= 1;
+ *requestHeight <<= 1;
+ upsampleCount++;
+ }
+ }
+ }
+ *levelOffset = upsampleCount;
+}
+
// Returns the size, in bytes, of a single texel in an Image
int ComputePixelSize(GLint internalformat)
{
@@ -510,6 +492,8 @@ bool IsColorRenderable(GLenum internalformat)
case GL_STENCIL_INDEX8:
case GL_DEPTH24_STENCIL8_OES:
return false;
+ case GL_BGRA8_EXT:
+ return true;
default:
UNIMPLEMENTED();
}
@@ -589,597 +573,141 @@ bool IsFloat16Format(GLint internalformat)
}
}
-}
-
-namespace es2dx
-{
-
-D3DCMPFUNC ConvertComparison(GLenum comparison)
-{
- D3DCMPFUNC d3dComp = D3DCMP_ALWAYS;
- switch (comparison)
- {
- case GL_NEVER: d3dComp = D3DCMP_NEVER; break;
- case GL_ALWAYS: d3dComp = D3DCMP_ALWAYS; break;
- case GL_LESS: d3dComp = D3DCMP_LESS; break;
- case GL_LEQUAL: d3dComp = D3DCMP_LESSEQUAL; break;
- case GL_EQUAL: d3dComp = D3DCMP_EQUAL; break;
- case GL_GREATER: d3dComp = D3DCMP_GREATER; break;
- case GL_GEQUAL: d3dComp = D3DCMP_GREATEREQUAL; break;
- case GL_NOTEQUAL: d3dComp = D3DCMP_NOTEQUAL; break;
- default: UNREACHABLE();
- }
-
- return d3dComp;
-}
-
-D3DCOLOR ConvertColor(gl::Color color)
-{
- return D3DCOLOR_RGBA(gl::unorm<8>(color.red),
- gl::unorm<8>(color.green),
- gl::unorm<8>(color.blue),
- gl::unorm<8>(color.alpha));
-}
-
-D3DBLEND ConvertBlendFunc(GLenum blend)
-{
- D3DBLEND d3dBlend = D3DBLEND_ZERO;
-
- switch (blend)
- {
- case GL_ZERO: d3dBlend = D3DBLEND_ZERO; break;
- case GL_ONE: d3dBlend = D3DBLEND_ONE; break;
- case GL_SRC_COLOR: d3dBlend = D3DBLEND_SRCCOLOR; break;
- case GL_ONE_MINUS_SRC_COLOR: d3dBlend = D3DBLEND_INVSRCCOLOR; break;
- case GL_DST_COLOR: d3dBlend = D3DBLEND_DESTCOLOR; break;
- case GL_ONE_MINUS_DST_COLOR: d3dBlend = D3DBLEND_INVDESTCOLOR; break;
- case GL_SRC_ALPHA: d3dBlend = D3DBLEND_SRCALPHA; break;
- case GL_ONE_MINUS_SRC_ALPHA: d3dBlend = D3DBLEND_INVSRCALPHA; break;
- case GL_DST_ALPHA: d3dBlend = D3DBLEND_DESTALPHA; break;
- case GL_ONE_MINUS_DST_ALPHA: d3dBlend = D3DBLEND_INVDESTALPHA; break;
- case GL_CONSTANT_COLOR: d3dBlend = D3DBLEND_BLENDFACTOR; break;
- case GL_ONE_MINUS_CONSTANT_COLOR: d3dBlend = D3DBLEND_INVBLENDFACTOR; break;
- case GL_CONSTANT_ALPHA: d3dBlend = D3DBLEND_BLENDFACTOR; break;
- case GL_ONE_MINUS_CONSTANT_ALPHA: d3dBlend = D3DBLEND_INVBLENDFACTOR; break;
- case GL_SRC_ALPHA_SATURATE: d3dBlend = D3DBLEND_SRCALPHASAT; break;
- default: UNREACHABLE();
- }
-
- return d3dBlend;
-}
-
-D3DBLENDOP ConvertBlendOp(GLenum blendOp)
-{
- D3DBLENDOP d3dBlendOp = D3DBLENDOP_ADD;
-
- switch (blendOp)
- {
- case GL_FUNC_ADD: d3dBlendOp = D3DBLENDOP_ADD; break;
- case GL_FUNC_SUBTRACT: d3dBlendOp = D3DBLENDOP_SUBTRACT; break;
- case GL_FUNC_REVERSE_SUBTRACT: d3dBlendOp = D3DBLENDOP_REVSUBTRACT; break;
- default: UNREACHABLE();
- }
-
- return d3dBlendOp;
-}
-
-D3DSTENCILOP ConvertStencilOp(GLenum stencilOp)
-{
- D3DSTENCILOP d3dStencilOp = D3DSTENCILOP_KEEP;
-
- switch (stencilOp)
- {
- case GL_ZERO: d3dStencilOp = D3DSTENCILOP_ZERO; break;
- case GL_KEEP: d3dStencilOp = D3DSTENCILOP_KEEP; break;
- case GL_REPLACE: d3dStencilOp = D3DSTENCILOP_REPLACE; break;
- case GL_INCR: d3dStencilOp = D3DSTENCILOP_INCRSAT; break;
- case GL_DECR: d3dStencilOp = D3DSTENCILOP_DECRSAT; break;
- case GL_INVERT: d3dStencilOp = D3DSTENCILOP_INVERT; break;
- case GL_INCR_WRAP: d3dStencilOp = D3DSTENCILOP_INCR; break;
- case GL_DECR_WRAP: d3dStencilOp = D3DSTENCILOP_DECR; break;
- default: UNREACHABLE();
- }
-
- return d3dStencilOp;
-}
-
-D3DTEXTUREADDRESS ConvertTextureWrap(GLenum wrap)
-{
- D3DTEXTUREADDRESS d3dWrap = D3DTADDRESS_WRAP;
-
- switch (wrap)
- {
- case GL_REPEAT: d3dWrap = D3DTADDRESS_WRAP; break;
- case GL_CLAMP_TO_EDGE: d3dWrap = D3DTADDRESS_CLAMP; break;
- case GL_MIRRORED_REPEAT: d3dWrap = D3DTADDRESS_MIRROR; break;
- default: UNREACHABLE();
- }
-
- return d3dWrap;
-}
-
-D3DCULL ConvertCullMode(GLenum cullFace, GLenum frontFace)
-{
- D3DCULL cull = D3DCULL_CCW;
- switch (cullFace)
- {
- case GL_FRONT:
- cull = (frontFace == GL_CCW ? D3DCULL_CW : D3DCULL_CCW);
- break;
- case GL_BACK:
- cull = (frontFace == GL_CCW ? D3DCULL_CCW : D3DCULL_CW);
- break;
- case GL_FRONT_AND_BACK:
- cull = D3DCULL_NONE; // culling will be handled during draw
- break;
- default: UNREACHABLE();
- }
-
- return cull;
-}
-
-D3DCUBEMAP_FACES ConvertCubeFace(GLenum cubeFace)
-{
- D3DCUBEMAP_FACES face = D3DCUBEMAP_FACE_POSITIVE_X;
-
- switch (cubeFace)
- {
- case GL_TEXTURE_CUBE_MAP_POSITIVE_X:
- face = D3DCUBEMAP_FACE_POSITIVE_X;
- break;
- case GL_TEXTURE_CUBE_MAP_NEGATIVE_X:
- face = D3DCUBEMAP_FACE_NEGATIVE_X;
- break;
- case GL_TEXTURE_CUBE_MAP_POSITIVE_Y:
- face = D3DCUBEMAP_FACE_POSITIVE_Y;
- break;
- case GL_TEXTURE_CUBE_MAP_NEGATIVE_Y:
- face = D3DCUBEMAP_FACE_NEGATIVE_Y;
- break;
- case GL_TEXTURE_CUBE_MAP_POSITIVE_Z:
- face = D3DCUBEMAP_FACE_POSITIVE_Z;
- break;
- case GL_TEXTURE_CUBE_MAP_NEGATIVE_Z:
- face = D3DCUBEMAP_FACE_NEGATIVE_Z;
- break;
- default: UNREACHABLE();
- }
-
- return face;
-}
-
-DWORD ConvertColorMask(bool red, bool green, bool blue, bool alpha)
-{
- return (red ? D3DCOLORWRITEENABLE_RED : 0) |
- (green ? D3DCOLORWRITEENABLE_GREEN : 0) |
- (blue ? D3DCOLORWRITEENABLE_BLUE : 0) |
- (alpha ? D3DCOLORWRITEENABLE_ALPHA : 0);
-}
-
-D3DTEXTUREFILTERTYPE ConvertMagFilter(GLenum magFilter, float maxAnisotropy)
-{
- if (maxAnisotropy > 1.0f)
- {
- return D3DTEXF_ANISOTROPIC;
- }
-
- D3DTEXTUREFILTERTYPE d3dMagFilter = D3DTEXF_POINT;
- switch (magFilter)
- {
- case GL_NEAREST: d3dMagFilter = D3DTEXF_POINT; break;
- case GL_LINEAR: d3dMagFilter = D3DTEXF_LINEAR; break;
- default: UNREACHABLE();
- }
-
- return d3dMagFilter;
-}
-
-void ConvertMinFilter(GLenum minFilter, D3DTEXTUREFILTERTYPE *d3dMinFilter, D3DTEXTUREFILTERTYPE *d3dMipFilter, float maxAnisotropy)
-{
- switch (minFilter)
- {
- case GL_NEAREST:
- *d3dMinFilter = D3DTEXF_POINT;
- *d3dMipFilter = D3DTEXF_NONE;
- break;
- case GL_LINEAR:
- *d3dMinFilter = D3DTEXF_LINEAR;
- *d3dMipFilter = D3DTEXF_NONE;
- break;
- case GL_NEAREST_MIPMAP_NEAREST:
- *d3dMinFilter = D3DTEXF_POINT;
- *d3dMipFilter = D3DTEXF_POINT;
- break;
- case GL_LINEAR_MIPMAP_NEAREST:
- *d3dMinFilter = D3DTEXF_LINEAR;
- *d3dMipFilter = D3DTEXF_POINT;
- break;
- case GL_NEAREST_MIPMAP_LINEAR:
- *d3dMinFilter = D3DTEXF_POINT;
- *d3dMipFilter = D3DTEXF_LINEAR;
- break;
- case GL_LINEAR_MIPMAP_LINEAR:
- *d3dMinFilter = D3DTEXF_LINEAR;
- *d3dMipFilter = D3DTEXF_LINEAR;
- break;
- default:
- *d3dMinFilter = D3DTEXF_POINT;
- *d3dMipFilter = D3DTEXF_NONE;
- UNREACHABLE();
- }
-
- if (maxAnisotropy > 1.0f)
- {
- *d3dMinFilter = D3DTEXF_ANISOTROPIC;
- }
-}
-
-bool ConvertPrimitiveType(GLenum primitiveType, GLsizei elementCount,
- D3DPRIMITIVETYPE *d3dPrimitiveType, int *d3dPrimitiveCount)
-{
- switch (primitiveType)
- {
- case GL_POINTS:
- *d3dPrimitiveType = D3DPT_POINTLIST;
- *d3dPrimitiveCount = elementCount;
- break;
- case GL_LINES:
- *d3dPrimitiveType = D3DPT_LINELIST;
- *d3dPrimitiveCount = elementCount / 2;
- break;
- case GL_LINE_LOOP:
- *d3dPrimitiveType = D3DPT_LINESTRIP;
- *d3dPrimitiveCount = elementCount - 1; // D3D doesn't support line loops, so we draw the last line separately
- break;
- case GL_LINE_STRIP:
- *d3dPrimitiveType = D3DPT_LINESTRIP;
- *d3dPrimitiveCount = elementCount - 1;
- break;
- case GL_TRIANGLES:
- *d3dPrimitiveType = D3DPT_TRIANGLELIST;
- *d3dPrimitiveCount = elementCount / 3;
- break;
- case GL_TRIANGLE_STRIP:
- *d3dPrimitiveType = D3DPT_TRIANGLESTRIP;
- *d3dPrimitiveCount = elementCount - 2;
- break;
- case GL_TRIANGLE_FAN:
- *d3dPrimitiveType = D3DPT_TRIANGLEFAN;
- *d3dPrimitiveCount = elementCount - 2;
- break;
- default:
- return false;
- }
-
- return true;
-}
-
-D3DFORMAT ConvertRenderbufferFormat(GLenum format)
-{
- switch (format)
- {
- case GL_NONE: return D3DFMT_NULL;
- case GL_RGBA4:
- case GL_RGB5_A1:
- case GL_RGBA8_OES: return D3DFMT_A8R8G8B8;
- case GL_RGB565: return D3DFMT_R5G6B5;
- case GL_RGB8_OES: return D3DFMT_X8R8G8B8;
- case GL_DEPTH_COMPONENT16:
- case GL_STENCIL_INDEX8:
- case GL_DEPTH24_STENCIL8_OES: return D3DFMT_D24S8;
- default: UNREACHABLE(); return D3DFMT_A8R8G8B8;
- }
-}
-
-D3DMULTISAMPLE_TYPE GetMultisampleTypeFromSamples(GLsizei samples)
-{
- if (samples <= 1)
- return D3DMULTISAMPLE_NONE;
- else
- return (D3DMULTISAMPLE_TYPE)samples;
-}
-
-}
-
-namespace dx2es
-{
-
-unsigned int GetStencilSize(D3DFORMAT stencilFormat)
-{
- if (stencilFormat == D3DFMT_INTZ)
- {
- return 8;
- }
- switch(stencilFormat)
- {
- case D3DFMT_D24FS8:
- case D3DFMT_D24S8:
- return 8;
- case D3DFMT_D24X4S4:
- return 4;
- case D3DFMT_D15S1:
- return 1;
- case D3DFMT_D16_LOCKABLE:
- case D3DFMT_D32:
- case D3DFMT_D24X8:
- case D3DFMT_D32F_LOCKABLE:
- case D3DFMT_D16:
- return 0;
- //case D3DFMT_D32_LOCKABLE: return 0; // DirectX 9Ex only
- //case D3DFMT_S8_LOCKABLE: return 8; // DirectX 9Ex only
- default:
- return 0;
- }
-}
-
-unsigned int GetAlphaSize(D3DFORMAT colorFormat)
+unsigned int GetAlphaSize(GLenum colorFormat)
{
switch (colorFormat)
{
- case D3DFMT_A16B16G16R16F:
+ case GL_RGBA16F_EXT:
return 16;
- case D3DFMT_A32B32G32R32F:
+ case GL_RGBA32F_EXT:
return 32;
- case D3DFMT_A2R10G10B10:
- return 2;
- case D3DFMT_A8R8G8B8:
+ case GL_RGBA4:
+ return 4;
+ case GL_RGBA8_OES:
+ case GL_BGRA8_EXT:
return 8;
- case D3DFMT_A1R5G5B5:
+ case GL_RGB5_A1:
return 1;
- case D3DFMT_X8R8G8B8:
- case D3DFMT_R5G6B5:
+ case GL_RGB8_OES:
+ case GL_RGB565:
+ case GL_RGB32F_EXT:
+ case GL_RGB16F_EXT:
return 0;
default:
return 0;
}
}
-unsigned int GetRedSize(D3DFORMAT colorFormat)
+unsigned int GetRedSize(GLenum colorFormat)
{
switch (colorFormat)
{
- case D3DFMT_A16B16G16R16F:
+ case GL_RGBA16F_EXT:
+ case GL_RGB16F_EXT:
return 16;
- case D3DFMT_A32B32G32R32F:
+ case GL_RGBA32F_EXT:
+ case GL_RGB32F_EXT:
return 32;
- case D3DFMT_A2R10G10B10:
- return 10;
- case D3DFMT_A8R8G8B8:
- case D3DFMT_X8R8G8B8:
+ case GL_RGBA4:
+ return 4;
+ case GL_RGBA8_OES:
+ case GL_BGRA8_EXT:
+ case GL_RGB8_OES:
return 8;
- case D3DFMT_A1R5G5B5:
- case D3DFMT_R5G6B5:
+ case GL_RGB5_A1:
+ case GL_RGB565:
return 5;
default:
return 0;
}
}
-unsigned int GetGreenSize(D3DFORMAT colorFormat)
+unsigned int GetGreenSize(GLenum colorFormat)
{
switch (colorFormat)
{
- case D3DFMT_A16B16G16R16F:
+ case GL_RGBA16F_EXT:
+ case GL_RGB16F_EXT:
return 16;
- case D3DFMT_A32B32G32R32F:
+ case GL_RGBA32F_EXT:
+ case GL_RGB32F_EXT:
return 32;
- case D3DFMT_A2R10G10B10:
- return 10;
- case D3DFMT_A8R8G8B8:
- case D3DFMT_X8R8G8B8:
+ case GL_RGBA4:
+ return 4;
+ case GL_RGBA8_OES:
+ case GL_BGRA8_EXT:
+ case GL_RGB8_OES:
return 8;
- case D3DFMT_A1R5G5B5:
+ case GL_RGB5_A1:
return 5;
- case D3DFMT_R5G6B5:
+ case GL_RGB565:
return 6;
default:
return 0;
}
}
-unsigned int GetBlueSize(D3DFORMAT colorFormat)
+unsigned int GetBlueSize(GLenum colorFormat)
{
switch (colorFormat)
{
- case D3DFMT_A16B16G16R16F:
+ case GL_RGBA16F_EXT:
+ case GL_RGB16F_EXT:
return 16;
- case D3DFMT_A32B32G32R32F:
+ case GL_RGBA32F_EXT:
+ case GL_RGB32F_EXT:
return 32;
- case D3DFMT_A2R10G10B10:
- return 10;
- case D3DFMT_A8R8G8B8:
- case D3DFMT_X8R8G8B8:
+ case GL_RGBA4:
+ return 4;
+ case GL_RGBA8_OES:
+ case GL_BGRA8_EXT:
+ case GL_RGB8_OES:
return 8;
- case D3DFMT_A1R5G5B5:
- case D3DFMT_R5G6B5:
+ case GL_RGB5_A1:
+ case GL_RGB565:
return 5;
default:
return 0;
}
}
-unsigned int GetDepthSize(D3DFORMAT depthFormat)
+unsigned int GetDepthSize(GLenum depthFormat)
{
- if (depthFormat == D3DFMT_INTZ)
- {
- return 24;
- }
switch (depthFormat)
{
- case D3DFMT_D16_LOCKABLE: return 16;
- case D3DFMT_D32: return 32;
- case D3DFMT_D15S1: return 15;
- case D3DFMT_D24S8: return 24;
- case D3DFMT_D24X8: return 24;
- case D3DFMT_D24X4S4: return 24;
- case D3DFMT_D16: return 16;
- case D3DFMT_D32F_LOCKABLE: return 32;
- case D3DFMT_D24FS8: return 24;
- //case D3DFMT_D32_LOCKABLE: return 32; // D3D9Ex only
- //case D3DFMT_S8_LOCKABLE: return 0; // D3D9Ex only
- default: return 0;
- }
-}
-
-GLsizei GetSamplesFromMultisampleType(D3DMULTISAMPLE_TYPE type)
-{
- if (type == D3DMULTISAMPLE_NONMASKABLE)
- return 0;
- else
- return type;
-}
-
-bool IsFormatChannelEquivalent(D3DFORMAT d3dformat, GLenum format)
-{
- switch (d3dformat)
- {
- case D3DFMT_L8:
- return (format == GL_LUMINANCE);
- case D3DFMT_A8L8:
- return (format == GL_LUMINANCE_ALPHA);
- case D3DFMT_DXT1:
- return (format == GL_COMPRESSED_RGBA_S3TC_DXT1_EXT || format == GL_COMPRESSED_RGB_S3TC_DXT1_EXT);
- case D3DFMT_DXT3:
- return (format == GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE);
- case D3DFMT_DXT5:
- return (format == GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE);
- case D3DFMT_A8R8G8B8:
- case D3DFMT_A16B16G16R16F:
- case D3DFMT_A32B32G32R32F:
- return (format == GL_RGBA || format == GL_BGRA_EXT);
- case D3DFMT_X8R8G8B8:
- return (format == GL_RGB);
- default:
- if (d3dformat == D3DFMT_INTZ && gl::IsDepthTexture(format))
- return true;
- return false;
- }
-}
-
-bool ConvertReadBufferFormat(D3DFORMAT d3dformat, GLenum *format, GLenum *type)
-{
- switch (d3dformat)
- {
- case D3DFMT_A8R8G8B8:
- *type = GL_UNSIGNED_BYTE;
- *format = GL_BGRA_EXT;
- break;
- case D3DFMT_X8R8G8B8:
- *type = GL_UNSIGNED_BYTE;
- *format = GL_RGB;
- break;
- case D3DFMT_R5G6B5:
- *type = GL_UNSIGNED_SHORT_5_6_5;
- *format = GL_RGB;
- break;
- case D3DFMT_A16B16G16R16F:
- *type = GL_HALF_FLOAT_OES;
- *format = GL_RGBA;
- break;
- case D3DFMT_A32B32G32R32F:
- *type = GL_FLOAT;
- *format = GL_RGBA;
- break;
- case D3DFMT_A4R4G4B4:
- *type = GL_UNSIGNED_SHORT_4_4_4_4_REV_EXT;
- *format = GL_BGRA_EXT;
- break;
- case D3DFMT_A1R5G5B5:
- *type = GL_UNSIGNED_SHORT_1_5_5_5_REV_EXT;
- *format = GL_BGRA_EXT;
- break;
- default:
- *type = GL_NONE;
- *format = GL_NONE;
- return false;
- }
- return true;
-}
-
-GLenum ConvertBackBufferFormat(D3DFORMAT format)
-{
- switch (format)
- {
- case D3DFMT_A4R4G4B4: return GL_RGBA4;
- case D3DFMT_A8R8G8B8: return GL_RGBA8_OES;
- case D3DFMT_A1R5G5B5: return GL_RGB5_A1;
- case D3DFMT_R5G6B5: return GL_RGB565;
- case D3DFMT_X8R8G8B8: return GL_RGB8_OES;
- default:
- UNREACHABLE();
+ case GL_DEPTH_COMPONENT16: return 16;
+ case GL_DEPTH_COMPONENT32_OES: return 32;
+ case GL_DEPTH24_STENCIL8_OES: return 24;
+ default: return 0;
}
-
- return GL_RGBA4;
}
-GLenum ConvertDepthStencilFormat(D3DFORMAT format)
+unsigned int GetStencilSize(GLenum stencilFormat)
{
- if (format == D3DFMT_INTZ)
+ switch (stencilFormat)
{
- return GL_DEPTH24_STENCIL8_OES;
+ case GL_DEPTH24_STENCIL8_OES: return 8;
+ default: return 0;
}
- switch (format)
- {
- case D3DFMT_D16:
- case D3DFMT_D24X8:
- return GL_DEPTH_COMPONENT16;
- case D3DFMT_D24S8:
- return GL_DEPTH24_STENCIL8_OES;
- default:
- UNREACHABLE();
- }
-
- return GL_DEPTH24_STENCIL8_OES;
}
-}
-
-namespace dx
-{
-
-bool IsCompressedFormat(D3DFORMAT surfaceFormat)
+bool IsTriangleMode(GLenum drawMode)
{
- switch(surfaceFormat)
+ switch (drawMode)
{
- case D3DFMT_DXT1:
- case D3DFMT_DXT2:
- case D3DFMT_DXT3:
- case D3DFMT_DXT4:
- case D3DFMT_DXT5:
+ case GL_TRIANGLES:
+ case GL_TRIANGLE_FAN:
+ case GL_TRIANGLE_STRIP:
return true;
- default:
+ case GL_POINTS:
+ case GL_LINES:
+ case GL_LINE_LOOP:
+ case GL_LINE_STRIP:
return false;
+ default: UNREACHABLE();
}
-}
-size_t ComputeRowSize(D3DFORMAT format, unsigned int width)
-{
- if (format == D3DFMT_INTZ)
- {
- return 4 * width;
- }
- switch (format)
- {
- case D3DFMT_L8:
- return 1 * width;
- case D3DFMT_A8L8:
- return 2 * width;
- case D3DFMT_X8R8G8B8:
- case D3DFMT_A8R8G8B8:
- return 4 * width;
- case D3DFMT_A16B16G16R16F:
- return 8 * width;
- case D3DFMT_A32B32G32R32F:
- return 16 * width;
- case D3DFMT_DXT1:
- return 8 * ((width + 3) / 4);
- case D3DFMT_DXT3:
- case D3DFMT_DXT5:
- return 16 * ((width + 3) / 4);
- default:
- UNREACHABLE();
- return 0;
- }
+ return false;
}
}
diff --git a/src/3rdparty/angle/src/libGLESv2/utilities.h b/src/3rdparty/angle/src/libGLESv2/utilities.h
index 29ad207313..7a10767086 100644
--- a/src/3rdparty/angle/src/libGLESv2/utilities.h
+++ b/src/3rdparty/angle/src/libGLESv2/utilities.h
@@ -1,5 +1,5 @@
//
-// Copyright (c) 2002-2012 The ANGLE Project Authors. All rights reserved.
+// Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
@@ -12,20 +12,15 @@
#define GL_APICALL
#include <GLES2/gl2.h>
#include <GLES2/gl2ext.h>
-#include <d3d9.h>
#include <string>
-const D3DFORMAT D3DFMT_INTZ = ((D3DFORMAT)(MAKEFOURCC('I','N','T','Z')));
-const D3DFORMAT D3DFMT_NULL = ((D3DFORMAT)(MAKEFOURCC('N','U','L','L')));
-
namespace gl
{
struct Color;
-int UniformExternalComponentCount(GLenum type);
-int UniformInternalComponentCount(GLenum type);
+int UniformComponentCount(GLenum type);
GLenum UniformComponentType(GLenum type);
size_t UniformInternalSize(GLenum type);
size_t UniformExternalSize(GLenum type);
@@ -34,6 +29,7 @@ int VariableColumnCount(GLenum type);
int AllocateFirstFreeBits(unsigned int *bits, unsigned int allocationSize, unsigned int bitsSize);
+void MakeValidSize(bool isImage, bool isCompressed, GLsizei *requestWidth, GLsizei *requestHeight, int *levelOffset);
int ComputePixelSize(GLint internalformat);
GLsizei ComputePitch(GLsizei width, GLint internalformat, GLint alignment);
GLsizei ComputeCompressedPitch(GLsizei width, GLenum format);
@@ -53,69 +49,18 @@ bool IsStencilRenderable(GLenum internalformat);
bool IsFloat32Format(GLint internalformat);
bool IsFloat16Format(GLint internalformat);
-}
-
-namespace es2dx
-{
-
-D3DCMPFUNC ConvertComparison(GLenum comparison);
-D3DCOLOR ConvertColor(gl::Color color);
-D3DBLEND ConvertBlendFunc(GLenum blend);
-D3DBLENDOP ConvertBlendOp(GLenum blendOp);
-D3DSTENCILOP ConvertStencilOp(GLenum stencilOp);
-D3DTEXTUREADDRESS ConvertTextureWrap(GLenum wrap);
-D3DCULL ConvertCullMode(GLenum cullFace, GLenum frontFace);
-D3DCUBEMAP_FACES ConvertCubeFace(GLenum cubeFace);
-DWORD ConvertColorMask(bool red, bool green, bool blue, bool alpha);
-D3DTEXTUREFILTERTYPE ConvertMagFilter(GLenum magFilter, float maxAnisotropy);
-void ConvertMinFilter(GLenum minFilter, D3DTEXTUREFILTERTYPE *d3dMinFilter, D3DTEXTUREFILTERTYPE *d3dMipFilter, float maxAnisotropy);
-bool ConvertPrimitiveType(GLenum primitiveType, GLsizei elementCount,
- D3DPRIMITIVETYPE *d3dPrimitiveType, int *d3dPrimitiveCount);
-D3DFORMAT ConvertRenderbufferFormat(GLenum format);
-D3DMULTISAMPLE_TYPE GetMultisampleTypeFromSamples(GLsizei samples);
-
-}
-
-namespace dx2es
-{
-
-GLuint GetAlphaSize(D3DFORMAT colorFormat);
-GLuint GetRedSize(D3DFORMAT colorFormat);
-GLuint GetGreenSize(D3DFORMAT colorFormat);
-GLuint GetBlueSize(D3DFORMAT colorFormat);
-GLuint GetDepthSize(D3DFORMAT depthFormat);
-GLuint GetStencilSize(D3DFORMAT stencilFormat);
-
-GLsizei GetSamplesFromMultisampleType(D3DMULTISAMPLE_TYPE type);
-
-bool IsFormatChannelEquivalent(D3DFORMAT d3dformat, GLenum format);
-bool ConvertReadBufferFormat(D3DFORMAT d3dformat, GLenum *format, GLenum *type);
-GLenum ConvertBackBufferFormat(D3DFORMAT format);
-GLenum ConvertDepthStencilFormat(D3DFORMAT format);
-}
+GLuint GetAlphaSize(GLenum colorFormat);
+GLuint GetRedSize(GLenum colorFormat);
+GLuint GetGreenSize(GLenum colorFormat);
+GLuint GetBlueSize(GLenum colorFormat);
+GLuint GetDepthSize(GLenum depthFormat);
+GLuint GetStencilSize(GLenum stencilFormat);
+bool IsTriangleMode(GLenum drawMode);
-namespace dx
-{
-bool IsCompressedFormat(D3DFORMAT format);
-size_t ComputeRowSize(D3DFORMAT format, unsigned int width);
}
std::string getTempPath();
void writeFile(const char* path, const void* data, size_t size);
-inline bool isDeviceLostError(HRESULT errorCode)
-{
- switch (errorCode)
- {
- case D3DERR_DRIVERINTERNALERROR:
- case D3DERR_DEVICELOST:
- case D3DERR_DEVICEHUNG:
- case D3DERR_DEVICEREMOVED:
- return true;
- default:
- return false;
- }
-};
-
#endif // LIBGLESV2_UTILITIES_H
diff --git a/src/3rdparty/angle/src/third_party/compiler/ArrayBoundsClamper.cpp b/src/3rdparty/angle/src/third_party/compiler/ArrayBoundsClamper.cpp
new file mode 100644
index 0000000000..288f5529ad
--- /dev/null
+++ b/src/3rdparty/angle/src/third_party/compiler/ArrayBoundsClamper.cpp
@@ -0,0 +1,106 @@
+/*
+ * Copyright (C) 2012 Apple 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:
+ * 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 APPLE, INC. ``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 APPLE, INC. 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.
+ */
+
+#include "third_party/compiler/ArrayBoundsClamper.h"
+
+// The built-in 'clamp' instruction only accepts floats and returns a float. I
+// iterated a few times with our driver team who examined the output from our
+// compiler - they said the multiple casts generates more code than a single
+// function call. An inline ternary operator might have been better, but since
+// the index value might be an expression itself, we'd have to make temporary
+// variables to avoid evaluating the expression multiple times. And making
+// temporary variables was difficult because ANGLE would then need to make more
+// brutal changes to the expression tree.
+
+const char* kIntClampBegin = "// BEGIN: Generated code for array bounds clamping\n\n";
+const char* kIntClampEnd = "// END: Generated code for array bounds clamping\n\n";
+const char* kIntClampDefinition = "int webgl_int_clamp(int value, int minValue, int maxValue) { return ((value < minValue) ? minValue : ((value > maxValue) ? maxValue : value)); }\n\n";
+
+namespace {
+
+class ArrayBoundsClamperMarker : public TIntermTraverser {
+public:
+ ArrayBoundsClamperMarker()
+ : mNeedsClamp(false)
+ {
+ }
+
+ virtual bool visitBinary(Visit visit, TIntermBinary* node)
+ {
+ if (node->getOp() == EOpIndexIndirect)
+ {
+ TIntermTyped* left = node->getLeft();
+ if (left->isArray() || left->isVector() || left->isMatrix())
+ {
+ node->setAddIndexClamp();
+ mNeedsClamp = true;
+ }
+ }
+ return true;
+ }
+
+ bool GetNeedsClamp() { return mNeedsClamp; }
+
+private:
+ bool mNeedsClamp;
+};
+
+} // anonymous namespace
+
+ArrayBoundsClamper::ArrayBoundsClamper()
+ : mClampingStrategy(SH_CLAMP_WITH_CLAMP_INTRINSIC)
+ , mArrayBoundsClampDefinitionNeeded(false)
+{
+}
+
+void ArrayBoundsClamper::SetClampingStrategy(ShArrayIndexClampingStrategy clampingStrategy)
+{
+ mClampingStrategy = clampingStrategy;
+}
+
+void ArrayBoundsClamper::MarkIndirectArrayBoundsForClamping(TIntermNode* root)
+{
+ ASSERT(root);
+
+ ArrayBoundsClamperMarker clamper;
+ root->traverse(&clamper);
+ if (clamper.GetNeedsClamp())
+ {
+ SetArrayBoundsClampDefinitionNeeded();
+ }
+}
+
+void ArrayBoundsClamper::OutputClampingFunctionDefinition(TInfoSinkBase& out) const
+{
+ if (!mArrayBoundsClampDefinitionNeeded)
+ {
+ return;
+ }
+ if (mClampingStrategy != SH_CLAMP_WITH_USER_DEFINED_INT_CLAMP_FUNCTION)
+ {
+ return;
+ }
+ out << kIntClampBegin << kIntClampDefinition << kIntClampEnd;
+}
diff --git a/src/3rdparty/angle/src/third_party/compiler/ArrayBoundsClamper.h b/src/3rdparty/angle/src/third_party/compiler/ArrayBoundsClamper.h
new file mode 100644
index 0000000000..0d4e1a374c
--- /dev/null
+++ b/src/3rdparty/angle/src/third_party/compiler/ArrayBoundsClamper.h
@@ -0,0 +1,62 @@
+/*
+ * Copyright (C) 2012 Apple 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:
+ * 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 APPLE, INC. ``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 APPLE, INC. 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.
+ */
+
+#ifndef THIRD_PARTY_COMPILER_ARRAY_BOUNDS_CLAMPER_H_
+#define THIRD_PARTY_COMPILER_ARRAY_BOUNDS_CLAMPER_H_
+
+#include "GLSLANG/ShaderLang.h"
+
+#include "compiler/InfoSink.h"
+#include "compiler/intermediate.h"
+
+class ArrayBoundsClamper {
+public:
+ ArrayBoundsClamper();
+
+ // Must be set before compiling any shaders to ensure consistency
+ // between the translated shaders and any necessary prequel.
+ void SetClampingStrategy(ShArrayIndexClampingStrategy clampingStrategy);
+
+ // Marks nodes in the tree that index arrays indirectly as
+ // requiring clamping.
+ void MarkIndirectArrayBoundsForClamping(TIntermNode* root);
+
+ // If necessary, output array clamp function source into the shader source.
+ void OutputClampingFunctionDefinition(TInfoSinkBase& out) const;
+
+ void Cleanup()
+ {
+ mArrayBoundsClampDefinitionNeeded = false;
+ }
+
+private:
+ bool GetArrayBoundsClampDefinitionNeeded() const { return mArrayBoundsClampDefinitionNeeded; }
+ void SetArrayBoundsClampDefinitionNeeded() { mArrayBoundsClampDefinitionNeeded = true; }
+
+ ShArrayIndexClampingStrategy mClampingStrategy;
+ bool mArrayBoundsClampDefinitionNeeded;
+};
+
+#endif // THIRD_PARTY_COMPILER_ARRAY_BOUNDS_CLAMPER_H_
diff --git a/src/3rdparty/angle/src/third_party/compiler/LICENSE b/src/3rdparty/angle/src/third_party/compiler/LICENSE
new file mode 100644
index 0000000000..c2cb2125e9
--- /dev/null
+++ b/src/3rdparty/angle/src/third_party/compiler/LICENSE
@@ -0,0 +1,22 @@
+Copyright (C) 2012 Apple 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:
+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 APPLE, INC. ``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 APPLE, INC. 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/src/3rdparty/angle/src/third_party/compiler/README.angle b/src/3rdparty/angle/src/third_party/compiler/README.angle
new file mode 100644
index 0000000000..4fdf757ef4
--- /dev/null
+++ b/src/3rdparty/angle/src/third_party/compiler/README.angle
@@ -0,0 +1,12 @@
+Name: ANGLE array bounds clamper from WebKit
+Short Name: WebKit
+URL: http://webkit.org
+Version: 0
+License: BSD
+Security Critical: yes
+
+Description:
+Implements clamping of array indexing expressions during shader translation.
+
+Local Modifications:
+None
diff --git a/src/3rdparty/angle/src/third_party/murmurhash/LICENSE b/src/3rdparty/angle/src/third_party/murmurhash/LICENSE
new file mode 100644
index 0000000000..6a385f0f07
--- /dev/null
+++ b/src/3rdparty/angle/src/third_party/murmurhash/LICENSE
@@ -0,0 +1,2 @@
+// MurmurHash3 was written by Austin Appleby, and is placed in the public
+// domain. The author hereby disclaims copyright to this source code. \ No newline at end of file
diff --git a/src/3rdparty/angle/src/third_party/murmurhash/MurmurHash3.cpp b/src/3rdparty/angle/src/third_party/murmurhash/MurmurHash3.cpp
new file mode 100644
index 0000000000..dd86292649
--- /dev/null
+++ b/src/3rdparty/angle/src/third_party/murmurhash/MurmurHash3.cpp
@@ -0,0 +1,334 @@
+//-----------------------------------------------------------------------------
+// MurmurHash3 was written by Austin Appleby, and is placed in the public
+// domain. The author hereby disclaims copyright to this source code.
+
+// Note - The x86 and x64 versions do _not_ produce the same results, as the
+// algorithms are optimized for their respective platforms. You can still
+// compile and run any of them on any platform, but your performance with the
+// non-native version will be less than optimal.
+
+#include "MurmurHash3.h"
+
+//-----------------------------------------------------------------------------
+// Platform-specific functions and macros
+
+// Microsoft Visual Studio
+
+#if defined(_MSC_VER)
+
+#define FORCE_INLINE __forceinline
+
+#include <stdlib.h>
+
+#define ROTL32(x,y) _rotl(x,y)
+#define ROTL64(x,y) _rotl64(x,y)
+
+#define BIG_CONSTANT(x) (x)
+
+// Other compilers
+
+#else // defined(_MSC_VER)
+
+#define FORCE_INLINE __attribute__((always_inline))
+
+inline uint32_t rotl32 ( uint32_t x, int8_t r )
+{
+ return (x << r) | (x >> (32 - r));
+}
+
+inline uint64_t rotl64 ( uint64_t x, int8_t r )
+{
+ return (x << r) | (x >> (64 - r));
+}
+
+#define ROTL32(x,y) rotl32(x,y)
+#define ROTL64(x,y) rotl64(x,y)
+
+#define BIG_CONSTANT(x) (x##LLU)
+
+#endif // !defined(_MSC_VER)
+
+//-----------------------------------------------------------------------------
+// Block read - if your platform needs to do endian-swapping or can only
+// handle aligned reads, do the conversion here
+
+FORCE_INLINE uint32_t getblock ( const uint32_t * p, int i )
+{
+ return p[i];
+}
+
+FORCE_INLINE uint64_t getblock ( const uint64_t * p, int i )
+{
+ return p[i];
+}
+
+//-----------------------------------------------------------------------------
+// Finalization mix - force all bits of a hash block to avalanche
+
+FORCE_INLINE uint32_t fmix ( uint32_t h )
+{
+ h ^= h >> 16;
+ h *= 0x85ebca6b;
+ h ^= h >> 13;
+ h *= 0xc2b2ae35;
+ h ^= h >> 16;
+
+ return h;
+}
+
+//----------
+
+FORCE_INLINE uint64_t fmix ( uint64_t k )
+{
+ k ^= k >> 33;
+ k *= BIG_CONSTANT(0xff51afd7ed558ccd);
+ k ^= k >> 33;
+ k *= BIG_CONSTANT(0xc4ceb9fe1a85ec53);
+ k ^= k >> 33;
+
+ return k;
+}
+
+//-----------------------------------------------------------------------------
+
+void MurmurHash3_x86_32 ( const void * key, int len,
+ uint32_t seed, void * out )
+{
+ const uint8_t * data = (const uint8_t*)key;
+ const int nblocks = len / 4;
+
+ uint32_t h1 = seed;
+
+ const uint32_t c1 = 0xcc9e2d51;
+ const uint32_t c2 = 0x1b873593;
+
+ //----------
+ // body
+
+ const uint32_t * blocks = (const uint32_t *)(data + nblocks*4);
+
+ for(int i = -nblocks; i; i++)
+ {
+ uint32_t k1 = getblock(blocks,i);
+
+ k1 *= c1;
+ k1 = ROTL32(k1,15);
+ k1 *= c2;
+
+ h1 ^= k1;
+ h1 = ROTL32(h1,13);
+ h1 = h1*5+0xe6546b64;
+ }
+
+ //----------
+ // tail
+
+ const uint8_t * tail = (const uint8_t*)(data + nblocks*4);
+
+ uint32_t k1 = 0;
+
+ switch(len & 3)
+ {
+ case 3: k1 ^= tail[2] << 16;
+ case 2: k1 ^= tail[1] << 8;
+ case 1: k1 ^= tail[0];
+ k1 *= c1; k1 = ROTL32(k1,15); k1 *= c2; h1 ^= k1;
+ };
+
+ //----------
+ // finalization
+
+ h1 ^= len;
+
+ h1 = fmix(h1);
+
+ *(uint32_t*)out = h1;
+}
+
+//-----------------------------------------------------------------------------
+
+void MurmurHash3_x86_128 ( const void * key, const int len,
+ uint32_t seed, void * out )
+{
+ const uint8_t * data = (const uint8_t*)key;
+ const int nblocks = len / 16;
+
+ uint32_t h1 = seed;
+ uint32_t h2 = seed;
+ uint32_t h3 = seed;
+ uint32_t h4 = seed;
+
+ const uint32_t c1 = 0x239b961b;
+ const uint32_t c2 = 0xab0e9789;
+ const uint32_t c3 = 0x38b34ae5;
+ const uint32_t c4 = 0xa1e38b93;
+
+ //----------
+ // body
+
+ const uint32_t * blocks = (const uint32_t *)(data + nblocks*16);
+
+ for(int i = -nblocks; i; i++)
+ {
+ uint32_t k1 = getblock(blocks,i*4+0);
+ uint32_t k2 = getblock(blocks,i*4+1);
+ uint32_t k3 = getblock(blocks,i*4+2);
+ uint32_t k4 = getblock(blocks,i*4+3);
+
+ k1 *= c1; k1 = ROTL32(k1,15); k1 *= c2; h1 ^= k1;
+
+ h1 = ROTL32(h1,19); h1 += h2; h1 = h1*5+0x561ccd1b;
+
+ k2 *= c2; k2 = ROTL32(k2,16); k2 *= c3; h2 ^= k2;
+
+ h2 = ROTL32(h2,17); h2 += h3; h2 = h2*5+0x0bcaa747;
+
+ k3 *= c3; k3 = ROTL32(k3,17); k3 *= c4; h3 ^= k3;
+
+ h3 = ROTL32(h3,15); h3 += h4; h3 = h3*5+0x96cd1c35;
+
+ k4 *= c4; k4 = ROTL32(k4,18); k4 *= c1; h4 ^= k4;
+
+ h4 = ROTL32(h4,13); h4 += h1; h4 = h4*5+0x32ac3b17;
+ }
+
+ //----------
+ // tail
+
+ const uint8_t * tail = (const uint8_t*)(data + nblocks*16);
+
+ uint32_t k1 = 0;
+ uint32_t k2 = 0;
+ uint32_t k3 = 0;
+ uint32_t k4 = 0;
+
+ switch(len & 15)
+ {
+ case 15: k4 ^= tail[14] << 16;
+ case 14: k4 ^= tail[13] << 8;
+ case 13: k4 ^= tail[12] << 0;
+ k4 *= c4; k4 = ROTL32(k4,18); k4 *= c1; h4 ^= k4;
+
+ case 12: k3 ^= tail[11] << 24;
+ case 11: k3 ^= tail[10] << 16;
+ case 10: k3 ^= tail[ 9] << 8;
+ case 9: k3 ^= tail[ 8] << 0;
+ k3 *= c3; k3 = ROTL32(k3,17); k3 *= c4; h3 ^= k3;
+
+ case 8: k2 ^= tail[ 7] << 24;
+ case 7: k2 ^= tail[ 6] << 16;
+ case 6: k2 ^= tail[ 5] << 8;
+ case 5: k2 ^= tail[ 4] << 0;
+ k2 *= c2; k2 = ROTL32(k2,16); k2 *= c3; h2 ^= k2;
+
+ case 4: k1 ^= tail[ 3] << 24;
+ case 3: k1 ^= tail[ 2] << 16;
+ case 2: k1 ^= tail[ 1] << 8;
+ case 1: k1 ^= tail[ 0] << 0;
+ k1 *= c1; k1 = ROTL32(k1,15); k1 *= c2; h1 ^= k1;
+ };
+
+ //----------
+ // finalization
+
+ h1 ^= len; h2 ^= len; h3 ^= len; h4 ^= len;
+
+ h1 += h2; h1 += h3; h1 += h4;
+ h2 += h1; h3 += h1; h4 += h1;
+
+ h1 = fmix(h1);
+ h2 = fmix(h2);
+ h3 = fmix(h3);
+ h4 = fmix(h4);
+
+ h1 += h2; h1 += h3; h1 += h4;
+ h2 += h1; h3 += h1; h4 += h1;
+
+ ((uint32_t*)out)[0] = h1;
+ ((uint32_t*)out)[1] = h2;
+ ((uint32_t*)out)[2] = h3;
+ ((uint32_t*)out)[3] = h4;
+}
+
+//-----------------------------------------------------------------------------
+
+void MurmurHash3_x64_128 ( const void * key, const int len,
+ const uint32_t seed, void * out )
+{
+ const uint8_t * data = (const uint8_t*)key;
+ const int nblocks = len / 16;
+
+ uint64_t h1 = seed;
+ uint64_t h2 = seed;
+
+ const uint64_t c1 = BIG_CONSTANT(0x87c37b91114253d5);
+ const uint64_t c2 = BIG_CONSTANT(0x4cf5ad432745937f);
+
+ //----------
+ // body
+
+ const uint64_t * blocks = (const uint64_t *)(data);
+
+ for(int i = 0; i < nblocks; i++)
+ {
+ uint64_t k1 = getblock(blocks,i*2+0);
+ uint64_t k2 = getblock(blocks,i*2+1);
+
+ k1 *= c1; k1 = ROTL64(k1,31); k1 *= c2; h1 ^= k1;
+
+ h1 = ROTL64(h1,27); h1 += h2; h1 = h1*5+0x52dce729;
+
+ k2 *= c2; k2 = ROTL64(k2,33); k2 *= c1; h2 ^= k2;
+
+ h2 = ROTL64(h2,31); h2 += h1; h2 = h2*5+0x38495ab5;
+ }
+
+ //----------
+ // tail
+
+ const uint8_t * tail = (const uint8_t*)(data + nblocks*16);
+
+ uint64_t k1 = 0;
+ uint64_t k2 = 0;
+
+ switch(len & 15)
+ {
+ case 15: k2 ^= uint64_t(tail[14]) << 48;
+ case 14: k2 ^= uint64_t(tail[13]) << 40;
+ case 13: k2 ^= uint64_t(tail[12]) << 32;
+ case 12: k2 ^= uint64_t(tail[11]) << 24;
+ case 11: k2 ^= uint64_t(tail[10]) << 16;
+ case 10: k2 ^= uint64_t(tail[ 9]) << 8;
+ case 9: k2 ^= uint64_t(tail[ 8]) << 0;
+ k2 *= c2; k2 = ROTL64(k2,33); k2 *= c1; h2 ^= k2;
+
+ case 8: k1 ^= uint64_t(tail[ 7]) << 56;
+ case 7: k1 ^= uint64_t(tail[ 6]) << 48;
+ case 6: k1 ^= uint64_t(tail[ 5]) << 40;
+ case 5: k1 ^= uint64_t(tail[ 4]) << 32;
+ case 4: k1 ^= uint64_t(tail[ 3]) << 24;
+ case 3: k1 ^= uint64_t(tail[ 2]) << 16;
+ case 2: k1 ^= uint64_t(tail[ 1]) << 8;
+ case 1: k1 ^= uint64_t(tail[ 0]) << 0;
+ k1 *= c1; k1 = ROTL64(k1,31); k1 *= c2; h1 ^= k1;
+ };
+
+ //----------
+ // finalization
+
+ h1 ^= len; h2 ^= len;
+
+ h1 += h2;
+ h2 += h1;
+
+ h1 = fmix(h1);
+ h2 = fmix(h2);
+
+ h1 += h2;
+ h2 += h1;
+
+ ((uint64_t*)out)[0] = h1;
+ ((uint64_t*)out)[1] = h2;
+}
+
+//-----------------------------------------------------------------------------
diff --git a/src/3rdparty/angle/src/third_party/murmurhash/MurmurHash3.h b/src/3rdparty/angle/src/third_party/murmurhash/MurmurHash3.h
new file mode 100644
index 0000000000..c08f4f2585
--- /dev/null
+++ b/src/3rdparty/angle/src/third_party/murmurhash/MurmurHash3.h
@@ -0,0 +1,37 @@
+//-----------------------------------------------------------------------------
+// MurmurHash3 was written by Austin Appleby, and is placed in the public
+// domain. The author hereby disclaims copyright to this source code.
+
+#ifndef _MURMURHASH3_H_
+#define _MURMURHASH3_H_
+
+//-----------------------------------------------------------------------------
+// Platform-specific functions and macros
+
+// Microsoft Visual Studio
+
+#if defined(_MSC_VER)
+
+typedef unsigned char uint8_t;
+typedef unsigned long uint32_t;
+typedef unsigned __int64 uint64_t;
+
+// Other compilers
+
+#else // defined(_MSC_VER)
+
+#include <stdint.h>
+
+#endif // !defined(_MSC_VER)
+
+//-----------------------------------------------------------------------------
+
+void MurmurHash3_x86_32 ( const void * key, int len, uint32_t seed, void * out );
+
+void MurmurHash3_x86_128 ( const void * key, int len, uint32_t seed, void * out );
+
+void MurmurHash3_x64_128 ( const void * key, int len, uint32_t seed, void * out );
+
+//-----------------------------------------------------------------------------
+
+#endif // _MURMURHASH3_H_ \ No newline at end of file
diff --git a/src/3rdparty/freetype/ChangeLog b/src/3rdparty/freetype/ChangeLog
index 7de9ecfa7d..83a7d53c6d 100644
--- a/src/3rdparty/freetype/ChangeLog
+++ b/src/3rdparty/freetype/ChangeLog
@@ -1,3 +1,2995 @@
+2010-02-13 Werner Lemberg <wl@gnu.org>
+
+ * Version 2.3.12 released.
+ ==========================
+
+
+ Tag sources with `VER-2-3-12'.
+
+ * docs/CHANGES: Updated.
+
+ * docs/VERSION.DLL: Update documentation and bump version number to
+ 2.3.12.
+
+ * README, Jamfile (RefDoc),
+ builds/win32/vc2005/freetype.vcproj, builds/win32/vc2005/index.html,
+ builds/win32/vc2008/freetype.vcproj, builds/win32/vc2008/index.html,
+ builds/win32/visualc/freetype.dsp,
+ builds/win32/visualc/freetype.vcproj,
+ builds/win32/visualc/index.html, builds/win32/visualce/freetype.dsp,
+ builds/win32/visualce/freetype.vcproj,
+ builds/win32/visualce/index.html,
+ builds/wince/vc2005-ce/freetype.vcproj,
+ builds/wince/vc2005-ce/index.html,
+ builds/wince/vc2008-ce/freetype.vcproj,
+ builds/wince/vc2008-ce/index.html: s/2.3.11/2.3.12/, s/2311/2312/.
+
+ * include/freetype/freetype.h (FREETYPE_PATCH): Set to 12.
+
+ * builds/unix/configure.raw (version_info): Set to 10:0:4.
+
+2010-02-12 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Improve autotool version checking to work with beta releases.
+
+ * autogen.sh (check_tool_version): Improve the extraction of version
+ number from "tool --version" output. Some beta releases of
+ autotools have extra strings before version number.
+
+2010-02-12 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Fix overallocating bug in FT_Outline_New_Internal().
+
+ * src/base/ftoutln.c (FT_Outline_New_Internal): The length of
+ FT_Outline->points[] should be numPoints, not 2 * numPoints.
+ Found by Paul Messmer, see
+ http://lists.gnu.org/archive/html/freetype-devel/2010-02/msg00003.html
+
+2010-02-10 Ken Sharp <ken.sharp@artifex.com>
+
+ Really fix Savannah bug #28678 (part 2).
+
+ Since we consider `sbw' for the horizontal direction only, we still have
+ to synthesize vertical metrics if the user wants to use the vertical
+ writing direction.
+
+ * src/cff/cffgload.c (cff_slot_load), src/cid/cidgload.c
+ (cid_slot_load_glyph), src/type1/t1gload.c (T1_Load_Glyph):
+ Synthesize vertical metrics (only) if FT_LOAD_VERTICAL_LAYOUT is
+ set.
+
+2010-02-10 Ken Sharp <ken.sharp@artifex.com>
+
+ Really fix Savannah bug #28678 (part 1).
+
+ After long discussion, we now consider the character width vector
+ (wx,wy) returned by the `sbw' Type 1 operator as being part of *one*
+ direction only. For example, if you are using the horizontal
+ writing direction, you get the horizontal and vertical components of
+ the advance width for this direction. Note that OpenType and CFF fonts
+ don't have such a vertical component; instead, the GPOS table can be
+ used to generate two-dimensional advance widths (but this isn't
+ handled by FreeType).
+
+ * include/freetype/ftincrem.h (FT_Incremental_MetricsRec): Add
+ `advance_v' field to hold the vertical component of the advance
+ value.
+
+ * src/truetype/ttgload.c (tt_get_metrics), src/cff/cffgload.c
+ (cff_slot_load), src/type1/t1gload.c
+ (T1_Parse_Glyph_And_Get_Char_String), src/cid/cidgload.c
+ (cid_load_glyph): Use it.
+
+2010-02-08 Werner Lemberg <wl@gnu.org>
+
+ * devel/ftoption.h [FT_CONFIG_OPTION_PIC]: Define.
+
+2010-02-04 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Prevent NULL pointer dereference passed to FT_Module_Requester.
+
+ * src/sfnt/sfdriver.c (sfnt_get_interface): Don't use `module'.
+ * src/psnames/psmodule.c (psnames_get_interface): Ditto.
+
+ * src/cff/cffdrivr.c (cff_get_interface): Check NULL `driver'.
+ * src/truetype/ttdriver.c (tt_get_interface): Ditto.
+
+2010-01-29 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Fix memory leaks in previous patch.
+
+ * src/sfnt/sfobjs.c (sfnt_load_face): Don't overwrite the strings
+ allocated for face->root.family_name and style_name.
+
+2010-01-29 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ New parameters for FT_Open_Face() to ignore preferred family names.
+
+ Preferred family names should be used for legacy systems that
+ can hold only a few faces (<= 4) for a family name. Suggested by
+ Andreas Heinrich.
+ http://lists.gnu.org/archive/html/freetype/2010-01/msg00001.html
+
+ * include/freetype/ftsnames.h (FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY,
+ FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY): Define.
+
+ * src/sfnt/sfobjs.h (sfnt_load_face): Check the arguments and
+ ignore preferred family and subfamily names if requested.
+
+2010-01-27 Ken Sharp <ken.sharp@artifex.com>
+
+ Fix Savannah bug #28678.
+
+ * src/cff/cffgload.c (cff_slot_load), src/cid/cidgload.c
+ (cid_load_glyph): Handle vertical metrics correctly.
+
+ * src/type1/t1gload.c (T1_Parse_Glyph_And_Get_Char_String): Handle
+ vertical metrics correctly.
+ (T1_Load_Glyph): Don't synthesize vertical metrics.
+
+2010-01-14 Werner Lemberg <wl@gnu.org>
+
+ Make FT_Set_Transform work if no renderer is available.
+
+ * src/base/ftobjs.c (FT_Load_Glyph): Apply `standard' transformation
+ if no renderer is compiled into the library.
+
+2010-01-14 Werner Lemberg <wl@gnu.org>
+
+ Fix compilation warning.
+
+ * src/base/ftbase.h: s/LOCAL_DEF/LOCAL/.
+ * src/base/ftobjc.s: Include ftbase.h conditionally.
+
+2010-01-11 Kwang Yul Seo <skyul@company100.net>
+
+ Provide inline assembly code for RVCT compiler.
+ This is Savannah patch #7059.
+
+ * include/freetype/config/ftconfig.h (FT_MULFIX_ASSEMBLER,
+ FT_MulFix_arm) [__CC_ARM || __ARM_CC]: Define.
+
+2010-01-08 Ken Sharp <ken.sharp@artifex.com>
+
+ Fix Savannah bug #28521.
+
+ Issue #28226 involved a work-around for a font which used the
+ `setcurrentpoint' operator in an invalid way; this operator is only
+ supposed to be used with the result of OtherSubrs, and the font used
+ it directly. The supplied patch removed the block of code which
+ checked this usage entirely.
+
+ This turns out to be a Bad Thing. If `setcurrentpoint' is being
+ used correctly it should reset the flex flag in the decoder. If we
+ don't do this then the flag never gets reset and we omit any further
+ contours from the glyph (at least until we close the path or
+ similar).
+
+ * src/psaux/t1decode.c (t1_decoder_parse_charstrings)
+ <op_setcurrentpoint>: Handle `flex_state' correctly.
+
+2010-01-05 Werner Lemberg <wl@gnu.org>
+
+ Apply reports from clang static analyzer.
+
+ * src/lzw/ftlzw.c (ft_lzw_file_init), src/base/ftstroke.c
+ (FT_Stroker_ParseOutline), src/base/ftsynth.c
+ (FT_GlyphSlot_Embolden): Remove dead code.
+
+ * src/base/ftpatent.c (_tt_check_patents_in_table): Initialize
+ `offset_i' and `length_i'.
+
+2010-01-05 Ralph Giles <giles@ghostscript.com>
+
+ Enable the incremental font interface by default.
+
+ Ghostscript requires the incremental font interface for handling
+ some Postscript documents. It is moving to using FreeType as its
+ primary renderer; supporting this in the default build makes it
+ Ghostscript to be linked against the system FreeType when one is
+ available.
+
+ * include/freetype/config/ftoption.h (FT_CONFIG_OPTION_INCREMENTAL):
+ Uncomment.
+
+2010-01-05 Werner Lemberg <wl@gnu.org>
+
+ Fix Savannah bug #28395.
+
+ * src/truetype/ttdriver.c (Load_Glyph), src/type1/t1gload.c
+ (T1_Loada_Glyph): Don't check `num_glyphs' if incremental interface
+ is used.
+
+2010-01-05 Ken Sharp <ken.sharp@artifex.com>
+
+ Make Type 1 `seac' operator work with incremental interface.
+ This fixes Savannah bug #28480.
+
+ * src/psaux/t1decode.c (t1operator_seac): Don't check `glyph_names'
+ if incremental interface is used.
+
+2010-01-04 Ken Sharp <ken.sharp@artifex.com>
+
+ Make incremental interface work with TrueType fonts.
+ This fixes Savannah bug #28478.
+
+ * src/truetype/ttgload.c (load_truetype_glyph): Don't check
+ `glyf_offset' if incremental interface is used.
+
+2009-12-31 Lars Abrahamsson <wonko@opera.com>
+
+ Make compilation with FT_CONFIG_OPTION_PIC work again.
+
+ * src/base/ftglyph.c (FT_Glyph_To_Bitmap) [FT_CONFIG_OPTION_PIC]:
+ Declare `library' for FT_BITMAP_GLYPH_CLASS_GET.
+
+ * src/base/ftinit.c (ft_destroy_default_module_classes,
+ ft_create_default_module_classes): Use proper casts (needed for C++
+ compilation).
+
+ * src/sfnt/ttcmap.c (tt_cmap13_class_rec): Use FT_DEFINE_TT_CMAP.
+
+2009-12-22 Marc Kleine-Budde <mkl@pengutronix.de>
+
+ Make freetype-config aware of $SYSROOT.
+ This is Savannah patch #7040.
+
+ * builds/unix/freetype-config.in: Decorate with ${SYSROOT} where
+ appropriate.
+
+2009-12-20 Werner Lemberg <wl@gnu.org>
+
+ Fix compiler warning.
+ Reported by Sean.
+
+ * src/base/ftdbgmem.c [!FT_DEBUG_MEMORY]: ANSI C doesn't like empty
+ source files; however, some compilers warn about an unused variable
+ declaration. This is now replaced with a typedef.
+
+2009-12-18 Werner Lemberg <wl@gnu.org>
+
+ Fix Savannah bug #28320.
+
+ There exist corrupt, subsetted fonts (embedded in PDF files) which
+ contain a private dict that ends with an unterminated floating point
+ number (no operator following). We now ignore this error (as
+ acrobat does).
+
+ * src/cff/cffparse.c (cff_parser_run): Don't emit a syntax error for
+ unterminated floating point numbers.
+
+2009-12-16 Werner Lemberg <wl@gnu.org>
+
+ Really fix compiler warnings.
+ Reported by Sean.
+
+ * src/truetype/ttgxvar.c (GX_PT_POINTS_ARE_WORDS,
+ GX_PT_POINT_RUN_COUNT_MASK): Convert enum values to macros.
+
+2009-12-16 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Improve configure.raw to copy some options from CFLAGS to LDFLAGS.
+ The linker of Mac OS X 10.6 is sensitive to the architecture. If
+ the architectures are specified explicitly for the C compiler, the
+ linker requires the architecture specifications too.
+
+ * builds/unix/configure.raw: Replace `-isysroot' option parser by
+ more generic argument parser.
+
+2009-12-15 Werner Lemberg <wl@gnu.org>
+
+ Fix compiler warnings.
+ Reported by Sean.
+
+ * src/truetype/ttgxvar.c (ft_var_readpackeddeltas): Fix counter data
+ type.
+
+2009-12-14 Ken Sharp <ken.sharp@artifex.com>
+
+ Ignore invalid `setcurrentpoint' operations in Type 1 fonts.
+ This fixes Savannah bug #28226.
+
+ At least two wild PostScript files of unknown provenance contain
+ Type 1 fonts, apparently converted from TrueType fonts in earlier
+ PDF versions of the files, which use the `setcurrentpoint' operator
+ inappropriately.
+
+ FreeType currently throws an error in this case, but Ghostscript and
+ Adobe Distiller both accept the fonts and ignore the problem. This
+ commit #ifdefs out the check so PostScript interpreters using
+ FreeType can render these files.
+
+ The specification says `setcurrentpoint' should only be used to set
+ the point after a `Subr' call, but these fonts use it to set the
+ initial point to (0,0). Unnecessarily so, as they correctly use an
+ `hsbw' operation which implicitly sets the initial point.
+
+ * src/psaux/t1decode.c (t1_decoder_parse_charstrings)
+ <op_setcurrentpoint>: Comment out code.
+
+2009-12-14 Bram Tassyns <bramt@enfocus.be>
+
+ Fix parsing of /CIDFontVersion.
+ This fixes Savannah bug #28287.
+
+ * src/cid/cidtoken.h: `cid_version' in CID_FaceInfoRec (in
+ t1tables.h) is of type FT_Fixed.
+
+2009-12-14 Werner Lemberg <wl@gnu.org>
+
+ Trace glyph index in CID module.
+ Suggested in Savannah patch #7023.
+
+ * src/cid/cidgload.c (cid_load_glyph): Add tracing message.
+
+2009-12-03 Werner Lemberg <wl@gnu.org>
+
+ Fix compiler warnings.
+
+ * src/truetype/ttgload.c (tt_get_metrics): Put `Exit' label into the
+ proper preprocessor conditional.
+ * src/pfr/pfrobjs.c (pfr_slot_load): Pacify gcc.
+
+2009-11-25 John Tytgat <John.Tytgat@esko.com>
+
+ Better handling of start of `eexec' section.
+ This fixes Savannah bug #28090.
+
+ * src/type1/t1parse.c (T1_Get_Private_Dict): Skip all whitespace
+ characters before start of `eexec' section.
+
+2009-11-20 Werner Lemberg <wl@gnu.org>
+
+ Fix Savannah bug #27742.
+
+ * src/base/ftstroke.c (ft_stroker_outside): Avoid silent division by
+ zero, using a threshold for `theta'.
+
+2009-11-20 Werner Lemberg <wl@gnu.org>
+
+ Fix Savannah bug #28036.
+
+ * src/type1/t1afm.c (t1_get_index): Fix comparison.
+
+2009-11-16 Werner Lemberg <wl@gnu.org>
+
+ Fix compiler warnings.
+ Reported by Kevin Blenkinsopp <arqon@promode.org>.
+
+ * src/sfnt/ttload.c (check_table_dir): Use proper data type.
+
+2009-11-15 Werner Lemberg <wl@gnu.org>
+
+ Really fix FreeDesktop bug #21197.
+ This also fixes Savannah bug #28021.
+
+ * src/autofit/aflatin.c (af_latin_metrics_check_digits),
+ src/autofit/aflatin2.c (af_latin2_metrics_check_digits): Fix loop.
+
+2009-11-15 Werner Lemberg <wl@gnu.org>
+
+ Add tracing messages for advance values.
+
+ * src/base/ftobjs.c (FT_Load_Glyph), src/truetype/ttgload.c
+ (TT_Get_HMetrics, TT_Get_VMetrics): Do it.
+
+2009-11-08 Werner Lemberg <wl@gnu.org>
+
+ Fix compiler warning.
+ Reported by Jeremy Manson <jeremy.manson@gmail.com>.
+
+ * src/truetype/ttgload.c (load_truetype_glyph): Initialize `error'.
+
+2009-11-04 Werner Lemberg <wl@gnu.org>
+
+ Remove compiler warning.
+ Reported by Sean McBride <sean@rogue-research.com>.
+
+ * src/tools/apinames.c (read_header_file)<STATE_TYPE>: Use a cast to
+ `int', as specified in the printf(3) man page.
+
+2009-11-04 Werner Lemberg <wl@gnu.org>
+
+ Fix Savannah bug #27921.
+
+ * src/cff/cffobjs.c (cff_face_init), src/cid/cidobjs.c
+ (cid_face_init), src/type1/t1afm.c (T1_Read_Metrics),
+ src/type1/t1objs.c (T1_Face_Init): Don't use unsigned constant
+ values for rounding if the argument can be negative.
+
+2009-11-03 Bram Tassyns <bramt@enfocus.be>
+
+ Add basic support for Type1 charstrings in CFF.
+ This fixes Savannah bug #27922.
+
+ * src/cff/cffgload.c (CFF_Operator, cff_argument_counts): Handle
+ `seac', `sbw', and `setcurrentpoint' opcodes.
+ (cff_compute_bias): Add parameter to indicate the charstring type.
+ Update all callers.
+ (cff_operator_seac): Add parameter for side bearing.
+ (cff_decoder_parse_charstrings): Updated for more Type1 support.
+
+2009-11-03 Werner Lemberg <wl@gnu.org>
+
+ Return correct `linearHoriAdvance' value for embedded TT bitmaps too.
+ Reported by Jeremy Manson <jeremy.manson@gmail.com>.
+
+ src/truetype/ttgload.c (load_truetype_glyph): Add parameter to
+ quickly load the glyph header only.
+ Update all callers.
+ (tt_loader_init): Add parameter to quickly load the `glyf' table
+ only.
+ Update all callers.
+ (TT_Load_Glyph): Compute linear advance values for embedded bitmap
+ glyphs too.
+
+2009-11-03 Werner Lemberg <wl@gnu.org>
+
+ Improve code readability.
+
+ * src/ttgload.c (load_truetype_glyph): Move metrics calculation
+ to...
+ (tt_get_metrics): This new function.
+
+2009-10-26 Bram Tassyns <bramt@enfocus.be>
+
+ Fix Savannah bug #27811.
+
+ * src/truetype/ttxgvar.c (ft_var_readpackeddeltas): Fix
+ signed/unsigned mismatch.
+
+2009-10-19 Ning Dong <flintning@163.com>
+
+ Fix handling of `get' and `put' CFF instructions.
+
+ * src/cff/cffgload.c (cff_decoder_parse_charstrings) <cff_op_get,
+ cff_op_put>: Appendix B of Adobe Technote #5177 limits the number of
+ elements for the `get' and `put' operators to 32.
+ * src/cff/cffgload.h (CFF_MAX_TRANS_ELEMENTS): Define.
+ (CFF_Decoder): Use it for `buildchar' and remove `len_buildchar'.
+
+2009-10-18 Werner Lemberg <wl@gnu.org>
+
+ Fix handling of `dup' CFF instruction.
+ Problem and solution reported by Ning Dong <flintning@163.com>.
+
+ * src/cff/cffgload.c (cff_decoder_parse_charstrings) <cff_op_dup>:
+ Increase `args' by 2, not 1.
+
+2009-10-10 Werner Lemberg <wl@gnu.org>
+
+ * Version 2.3.11 released.
+ ==========================
+
+
+ Tag sources with `VER-2-3-11'.
+
+ * docs/VERSION.DLL: Update documentation and bump version number to
+ 2.3.11.
+
+ * README, Jamfile (RefDoc), builds/win32/visualc/index.html,
+ builds/win32/visualc/freetype.dsp,
+ builds/win32/visualc/freetype.vcproj,
+ builds/win32/visualce/index.html,
+ builds/win32/visualce/freetype.dsp,
+ builds/win32/visualce/freetype.vcproj: s/2.3.10/2.3.11/, s/2310/2311/.
+
+ * include/freetype/freetype.h (FREETYPE_PATCH): Set to 11.
+
+ * builds/unix/configure.raw (version_info): Set to 9:22:3.
+
+2009-10-10 Werner Lemberg <wl@gnu.org>
+
+ * docs/CHANGES, docs/release: Updated.
+
+2009-10-10 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ * src/pcf/pcfread.c (pcf_get_properties): Fix a bug in the nprops
+ truncation. Reported by Martin von Gagern and Peter Volkov.
+ https://bugs.gentoo.org/288357 and https://bugs.gentoo.org/288256
+
+2009-10-06 Werner Lemberg <wl@gnu.org>
+
+ * Version 2.3.10 released.
+ ==========================
+
+
+ Tag sources with `VER-2-3-10'.
+
+ * builds/toplevel.mk (major, minor, patch): Fix regexp to allow more
+ than a single digit.
+ (dist): We now use git.
+
+ * docs/VERSION.DLL: Update documentation and bump version number to
+ 2.3.10.
+
+ * README, Jamfile (RefDoc), builds/win32/visualc/index.html,
+ builds/win32/visualc/freetype.dsp,
+ builds/win32/visualc/freetype.vcproj,
+ builds/win32/visualce/index.html,
+ builds/win32/visualce/freetype.dsp,
+ builds/win32/visualce/freetype.vcproj: s/2.3.9/2.3.10/, s/239/2310/.
+
+ * include/freetype/freetype.h (FREETYPE_PATCH): Set to 10.
+
+ * builds/unix/configure.raw (version_info): Set to 9:21:3.
+
+2009-10-06 Werner Lemberg <wl@gnu.org>
+
+ Fix `make multi'.
+
+ * src/cache/ftccache.c, src/cache/ftcsbits.c (FT_COMPONENT): Define.
+
+ * src/sfnt/sfdriver.c: Include FT_INTERNAL_DEBUG_H.
+
+2009-09-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [cache] Fix Savannah bug #27441, clean up Redhat bugzilla #513582.
+ Tricky casts in FTC_{CACHE,GCACHE,MRULIST}_LOOKUP_CMP() are removed.
+ Now these functions should be called with FTC_Node or FTC_MruNode
+ variable, and the caller should cast them to appropriate pointers to
+ concrete data. These tricky casts can GCC-4.4 optimizer (-O2)
+ confused and the crashing binaries are generated.
+
+ * src/cache/ftcmru.h (FTC_MRULIST_LOOKUP_CMP): Drop tricky cast.
+ Now the 4th argument `node' of this function should be typed as
+ FTC_MruNode.
+
+ * src/cache/ftcglyph.h (FTC_GCACHE_LOOKUP_CMP): For inline
+ implementation, new temporal variable FTC_MruNode `_mrunode' to take
+ the pointer from FTC_MRULIST_LOOKUP_CMP(). For non-inline
+ implementation, tricky cast is dropped.
+
+ * src/cache/ftcmanag.c (FTC_SIZE_NODE): New macro casting
+ to FTC_SizeNode.
+ (FTC_Manager_LookupSize): Replace FTC_SizeNode `node' by FTC_MruNode
+ `mrunode', and FTC_SIZE_NODE() is inserted.
+ (FTC_FACE_NODE): New macro casting to FTC_FaceNode.
+ (FTC_Manager_LookupFace) Replace FTC_FaceNode `node' by FTC_MruNode
+ `mrunode', and FTC_FACE_NODE() is inserted.
+
+ * src/cache/ftcbasic.c (FTC_ImageCache_Lookup): Change the type of
+ `node' from FTC_INode to FTC_Node. Extra casting macro FTC_NODE()
+ is dropped.
+ (FTC_ImageCache_LookupScaler): Ditto.
+ (FTC_SBitCache_Lookup): Change the type of `node' from FTC_SNode to
+ FTC_Node. Extra casting macro FTC_NODE() is dropped. FTC_SNODE()
+ is inserted.
+ (FTC_SBitCache_LookupScaler): Ditto.
+
+ * src/cache/ftccmap.c (FTC_CMapCache_Lookup): Change the type of
+ `node' from FTC_CMapNode to FTC_Node. Extra casting macro
+ FTC_NODE() is dropped, FTC_CMAP_NODE() is inserted.
+
+2009-09-25 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [cache, psaux, type1] Fix for multi build.
+ In multi build, some cpp functions are left as unresolved symbols.
+
+ * src/cache/ftcbasic.c: Include FT_INTERNAL_DEBUG_H for FT_TRACE1().
+
+ * src/psaux/t1decode.c: Include FT_INTERNAL_CALC_H for
+ FIXED_TO_INT().
+ * src/type1/t1gload.c: Ditto.
+ * src/type1/t1objs.c: Ditto.
+
+2009-09-25 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [autofit] Fix for multi build.
+
+ * src/autofit/afmodule.h: Include FT_INTERNAL_OBJECTS_H to use
+ FT_DECLARE_MODULE() macro in multi build.
+
+ * src/autofit/aflatin.c: Include <ft2build.h> to handle
+ FT_ADVANCES_H correctly in multi build.
+
+2009-09-24 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [cache] Check the face filled by FTC_Manager_LookupFace().
+
+ * src/cache/ftcbasic.c (ftc_basic_family_get_count): Return
+ immediately if FTC_Manager_LookupFace() fills face by NULL. Such
+ case can occur when the code is optimized by GCC-4.2.x.
+
+2009-09-23 Werner Lemberg <wl@gnu.org>
+
+ * docs/CHANGES: Updated.
+
+2009-09-12 Werner Lemberg <wl@gnu.org>
+
+ [raster] Fix 5-levels grayscale output.
+ This was broken since version 2.3.0.
+
+ * src/raster/ftraster.c (count_table): Use pre-2.3.0 values (which
+ were then computed dynamically).
+ (Vertical_Gray_Sweep_Step): Updated.
+
+ (ft_black_render): Initialize `worker->gray_lines' (problem found by
+ valgrind).
+
+ (FT_RASTER_OPTION_ANTI_ALIASING, DEBUG_RASTER): Dont' #undef, just
+ comment out.
+
+2009-09-12 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Improve configure.raw for cross build.
+
+ * builds/unix/configure.raw: Remove temporal files created by the
+ suffix checking for CC_BUILD. Set XX_ANSIFLAGS and XX_CFLAGS when
+ cross compiler is GCC. AC_PROG_CC checks whether the cross compiler
+ is GCC, its result is stored in GCC.
+
+2009-09-12 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [BDF] Modify hash API to take size_t value instead of void *.
+
+ The hash API in BDF driver is designed to be generic, it takes
+ void * typed data. But BDF driver always gives an unsigned long
+ integer (the index to a property). To reduce non-essential
+ casts from unsigned long to void* and from void* to unsigned
+ long, the hash API is changed to take size_t integer.
+ The issue of incompatible cast between unsigned long and void*
+ on LLP64 platform is reported by NightStrike from MinGW-Win64
+ project. See
+ http://lists.gnu.org/archive/html/freetype/2009-09/msg00000.html
+
+ * src/bdf/bdf.h: The type of hashnode->data is changed from
+ void* to size_t.
+
+ * src/bdf/bdflib.c (hash_insert): Get size_t data, instead of
+ void* data.
+ (bdf_create_property): Get the name length of new property by
+ size_t variable, with a cut-off at FT_ULONG_MAX.
+ (_bdf_set_default_spacing): Get the name length of the face by
+ size_t variable, with a cut-off at 256.
+ (bdf_get_property): Get the property id by size_t variable to
+ reduce the casts between 32-bit prop ID & hashnode->data during
+ simple copying.
+ (_bdf_add_property): Ditto.
+ (_bdf_parse_start): Calculate the index to the property array
+ by size_t variable.
+ (bdf_get_font_property): Drop a cast to unsigned long.
+
+2009-09-10 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ [Win64] Improve the computation of random seed from stack address.
+
+ On LLP64 platform, the conversion from pointer to FT_Fixed need
+ to drop higher 32-bit. Explict casts are required. Reported by
+ NightStrike from MinGW-w64 project. See
+ http://lists.gnu.org/archive/html/freetype/2009-09/msg00000.html
+
+ * src/cff/cffgload.c: Convert the pointers to FT_Fixed explicitly.
+
+ * src/psaux/t1decode.c: Ditto.
+
+
+2009-09-03 Werner Lemberg <wl@gnu.org>
+
+ [raster] Improvements for stand-alone mode.
+
+ * src/raster/rules.mk: Don't handle ftmisc.h. It is needed for
+ stand-alone mode only.
+
+ * src/raster/ftmisc.h (FT_MemoryRec , FT_Alloc_Func, FT_Free_Func,
+ FT_Realloc_Func): Copy declarations from ftsystem.h.
+
+2009-09-02 Bram Tassyns <bramt@enfocus.be>
+
+ Improve vertical metrics calculation (Savannah bug #27364).
+
+ The calculation of `vertBearingX' is not defined in the OTF font
+ spec so FreeType does a `best effort' attempt. However, this value
+ is defined in the PDF and PostScript specs, and that algorithm is
+ better than the one FreeType currently uses:
+
+ FreeType: Use the middle of the bounding box as the X coordinate
+ of the vertical origin.
+
+ Adobe PDF spec: Use the middle of the horizontal advance vector as
+ the X coordinate of the vertical origin.
+
+ FreeType's algorithm goes wrong if you have a really small glyph
+ (like the full-width, circle-like dot at the end of the sentence, as
+ used in CJK scripts) with large bearings. With the FreeType
+ algorithm this dot gets centered on the baseline; with the PDF
+ algorithm it gets the correct location (in the top right). Note
+ that this is a serious issue, it's like printing the dot at the end
+ of a Roman sentence at the center of the textline instead of on the
+ baseline like it should. So i believe the PDF spec's algorithm
+ should be used in FreeType as well.
+
+ The `vertBearingY' value for such small glyphs is also very strange
+ if no `vmtx' information is present, since the height of the bbox is
+ not representable for the height of the glyph visually (the
+ whitespace up to the baseline is part of the glyph). The fix also
+ includes some code for a better estimate of `vertBearingY'.
+
+ * src/base/ftobjs.c (ft_synthesize_vertical_metrics): `vertBearingX'
+ is now calculated as described by the Adobe PDF Spec. Estimate for
+ `vertBearingY' now works better for small glyphs completely above or
+ below the baseline into account.
+
+ * src/cff/cffgload.c (cff_slot_load): `vertBearingX' is now
+ calculated as described by the Adobe PDF Spec. Vertical metrics
+ information was always ignored when FT_CONFIG_OPTION_OLD_INTERNALS
+ was not defined.
+
+ * src/truetype/ttgload.c (compute_glyph_metrics): `vertBearingX' is
+ now calculated as described by the Adobe PDF Spec.
+
+2009-09-01 John Tytgat <John.Tytgat@esko.com>
+
+ Fix custom cmap for empty Type 1 font (Savannah bug #27294).
+
+ * include/freetype/internal/t1types.h (T1_EncodingRecRec_): Update
+ comment to reflect revised code_last meaning.
+ * src/type1/t1load.c (T1_Open_Face), src/type42/t42objs.c
+ (T42_Open_Face): Assign max_char as highest character code + 1 and
+ use this for T1_EncodingRecRec_::code_last.
+ * src/psaux/t1cmap.c (t1_cmap_custom_init): Follow revised
+ T1_EncodingRecRec_::code_last meaning.
+
+2009-08-25 Werner Lemberg <wl@gnu.org>
+
+ Fix rendering of horizontally compressed CFFs.
+ Bug reported by Ivan Nincic <inincic@pdftron.com>.
+
+ * src/cff/cffgload.c (cff_slot_load): Thinko: Check `xx' element of
+ `font_matrix' also.
+
+ * docs/CHANGES: Updated.
+
+2009-08-03 suyu0925@gmail.com
+
+ Don't call `ft_fseek' every time when executing `ft_fread'.
+
+ * src/base/ftstream.c (FT_Stream_Seek), src/base/ftsystem.c
+ (ft_ansi_stream_io): Implement it.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ sfnt: Cast a charcode to 32-bit in cmap format 14 parser.
+
+ * src/sfnt/ttcmap.c (tt_cmap14_char_var_index,
+ tt_cmap14_char_var_isdefault, tt_cmap14_char_variants,
+ tt_cmap14_variant_chars): Correct mismatches from
+ FT_CMap_CharVarIndexFunc prototype, FT_ULong arguments
+ are replaced by FT_UInt32 arguments.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ sfnt: Cast a charcode to 32-bit in cmap format 12 parser.
+
+ * src/sfnt/ttcmap.c (tt_cmap12_char_next):
+ Insert explicit cast from FT_UFast to FT_UInt32
+ for return value.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ psaux: Fix a few casts to FT_Int32 value.
+
+ * src/psaux/t1decode.c (t1_decoder_parse_charstrings):
+ Fix a few casts setting `value' from FT_Long to FT_Int32,
+ because `value' is typed as FT_Int32 since 2009-06-22.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ sfnt: Fix a data type mismatching with its source.
+
+ * src/sfnt/ttcmap.c (tt_cmap13_char_next): Fix the
+ type of `gindex' from FT_ULong to FT_UInt because
+ it is set by FT_UInt tt_cmap13_char_map_binary() or
+ TT_CMap13->cur_gindex.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ sfnt: Extend a few local variables to load 32-bit values.
+
+ * src/sfnt/ttkern.c (tt_face_load_kern): Extend `count'
+ and `kern' to load 32-bit values.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ pfr: Extend `num_aux' to take 32-bit value.
+
+ * src/pfr/pfrload.c (pfr_phy_font_load): Extend
+ `num_aux' to load 32-bit value.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ pcf: Truncate FT_ULong `nprops' to fit to int PCF_Face->nprops.
+
+ * src/pcf/pcfread.c (pcf_get_properties): Load `nprops'
+ as FT_ULong value from PCF file, but truncate it as
+ int to fit PCF_Face->nprops. The number of truncated
+ properties is shown in the trace message.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ gxvalid: Extend a few local variables to reduce the casts.
+
+ * src/gxvalid/gxvmorx.c (gxv_morx_subtables_validate):
+ Extend `type' and `rest' to take FT_ULong values.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ gxvalid: Extend `settingTable' to take 32-bit offset.
+
+ * src/gxvalid/gxvfeat.c (gxv_feat_name_validate):
+ Extend `settingTable' to take 32-bit offset.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ autofit: Cast FT_Long glyph_count to compare with FT_UInt GID.
+
+ * src/autofit/afglobal.c (af_face_globals_is_digit,
+ af_face_globals_compute_script_coverage): Cast FT_Long
+ globals->glyph_count to FT_ULong, to compare with FT_UInt
+ gindex.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ smooth: Exclude 16-bit system in invalid pitch/height check.
+
+ * src/smooth/ftsmooth.c (ft_smooth_render_generic):
+ pitch and height are typed as FT_UInt but checked to fit
+ 16-bit range, to avoid the overflows. On 16-bit system,
+ this checking inserts a conditional that never occurs.
+
+2009-07-03 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cff: Type large constants > 0x7FFF as long for 16-bit systems.
+
+ * src/cff/cffload.c (cff_charset_load): Type large
+ constants > 0x7FFF as long, because normal constants
+ are typed signed integer that is less than 0x8000 on
+ 16-bit systems.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ base: Remove an unused variable.
+
+ * src/base/ftglyph.c (FT_Glyph_To_Bitmap): Remove an
+ unused variable `library'. glyph->library is used.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cache: Check higher bits in flags for non ILP32 systems.
+
+ 4 public functions ought to take FT_ULong flags, but take
+ FT_UInt flags. To keep binary compatibility, we drop higher
+ bits on non ILP32 platforms,
+ ILP64 systems: No drop occurs.
+ LP64 systems: Higher bits are not used.
+ 16-bit systems: Drop can occur.
+ See
+ http://lists.gnu.org/archive/html/freetype-devel/2008-12/msg00065.html
+ These functions will be refined to take FT_ULong flags in
+ next bump with incompatible API change.
+
+ * src/cache/ftcbasic.c (FTC_ImageCache_Lookup):
+ Check `flags' in `type', the 2nd argument.
+ (FTC_SBitCache_Lookup): Ditto.
+ (FTC_ImageCache_LookupScaler): Check `load_flags',
+ the 3rd argument.
+ (FTC_SBitCache_LookupScaler): Ditto.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ sfnt: Ignore invalid GIDs in glyph name lookup.
+
+ * include/freetype/internal/fttrace.h:
+ New trace module for sfdriver.c is added.
+
+ * src/sfnt/sfdriver.c (sfnt_get_name_index):
+ Restrict glyph name lookup to FT_UInt GID.
+ Genuine TrueType can hold 16-bit glyphs.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ pcf: Fix a comparison between FT_Long and FT_ULong.
+
+ * src/pcf/pcfread.c (pcf_get_bitmaps): Return an error
+ if PCF_Face->nemetrics is negative.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ gxvalid: Guarantee `nFeatureFlags' size up to 32-bit.
+
+ * src/gxvalid/gxvmort.c (gxv_mort_featurearray_validate):
+ Extend the 3rd argument `nFeatureFlags' to FT_ULong.
+ * src/gxvalid/gxvmort.h: Ditto.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ sfnt: Insert explicit cast for LP64 system.
+
+ * src/sfnt/ttkern.c (tt_face_load_kern): Insert
+ cast from unsigned long to FT_UInt32.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ gxvalid: Guarantee `just' table size upto 32-bit.
+
+ * src/gxvalid/gxvjust.c (gxv_just_validate):
+ The type of `offset' is changed from FT_UInt to
+ FT_Offset, for 16-bit platforms.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ gxvalid: Guarantee `trak' table size upto 32-bit.
+
+ * src/gxvalid/gxvtrak.c (gxv_trak_validate):
+ The type of `offset' is changed from FT_UInt to
+ FT_Offset, for 16-bit platforms.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ type1: Fix a data type mismatching with its source.
+
+ * include/freetype/internal/t1types.h: The type of
+ T1_Face->buildchar is matched with T1_Decorder->top.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ pfr: Fix a data type mismatching with its source.
+
+ * src/pfr/pfrtypes.h: The type of PFR_KernItem->offset
+ is extended from FT_UInt32 to FT_Offset, because it is
+ calculated with the pointer difference, in
+ pfr_extra_item_load_kerning_pairs().
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ pfr: Fix a data type mismatching with its source.
+
+ * src/pfr/pfrtypes.h: The type of PFR_PhysFont->chars_offset
+ is extended from FT_UInt32 to FT_Offset, because it is
+ calculated with the pointer difference in pfr_phy_font_load().
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ pfr: Fix a data type mismatching with its source.
+
+ * src/pfr/pfrtypes.h: The type of PFR_PhyFont->bct_offset
+ is extended from FT_UInt32 to FT_Long, because it is
+ loaded by FT_STREAM_POS() in pfr_phy_font_load().
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ smooth: Improve the format in debug message.
+
+ * src/smooth/ftgrays.c (gray_dump_cells): Improve the
+ format specifications to dump variables.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ sfnt: Fix a data type mismatching with its source.
+
+ * src/sfnt/sfobjs.c (sfnt_load_face): The type of
+ local `flags' is matched with FT_Face->face_flags.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ psaux: Fix a data type mismatching with its source.
+
+ * include/freetype/internal/psaux.h: The type of
+ T1_DecorderRec.buildchar is matched with
+ T1_DecorderRec.top.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ truetype: Extend TrueType GX packed deltas to FT_Offset.
+
+ * src/truetype/ttgxvar.c (ft_var_readpackeddeltas):
+ The type of 2nd argument `delta_cnt' is changed from
+ FT_Int to FT_Offset, because its source can be cvt
+ table size calculated from stream position.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ truetype: Extend mmvar_len to hold size_t values.
+
+ * src/truetype/ttgxvar.h: The type of
+ GX_BlendRec.mmvar_len is changed from FT_Int to
+ FT_Offset, because TT_Get_MM_Var() calculates it
+ by sizeof() results.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ truetype: Check invalid function number in IDEF instruction.
+
+ * src/truetype/ttinterp.c (Ins_IDEF): Check
+ if the operand fits to 8-bit opcode limitation.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ truetype: Check invalid function number in FDEF instruction.
+
+ * src/truetype/ttinterp.c (Ins_FDEF): Check
+ if the operand fits 16-bit function number.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ truetype: Truncate the deltas of composite glyph at 16-bit values.
+
+ * src/truetype/ttgload.c (load_truetype_glyph):
+ Insert cast from FT_Long (deltas[i].{x,y}) to
+ FT_Int16 in the summation of deltas[] for composite
+ glyphs. Because deltas[i] is typed as FT_Pos,
+ its component x, y are typed as FT_Long, but
+ their sources are always FT_Int16 when they are
+ loaded by ft_var_readpackeddeltas(). However,
+ the limitation about the summed deltas is unclear.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ truetype: Truncate the instructions upto 16-bit per a glyph.
+
+ * src/truetype/ttgload.c (TT_Hint_Glyph): Truncate
+ the instructions upto 16-bit length per a glyph.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ truetype: Cast the numerical operands to 32-bit for LP64 systems.
+
+ * src/truetype/ttinterp.c (Ins_SPHIX, INS_MIAP,
+ Ins_MIRP): Insert cast from long (args[], the
+ operands passed to TrueType operator) to FT_Int32
+ (the argument of TT_MulFix14()).
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ truetype: Cast the project vector to 32-bit for LP64 system.
+
+ * src/truetype/ttinterp.c (Project, DualProject):
+ Insert casts from FT_Pos (the arguments `dx', `dy')
+ to FT_UInt32 (the argument to TT_DotFix14()).
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ truetype: Cast the scaling params to 32-bit for LP64 system.
+
+ * src/truetype/ttgload.c (TT_Process_Composite_Component):
+ Insert casts from long (return value of FT_MulFix()) to
+ FT_Int32 (the argument to FT_SqrtFixed()).
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ sfnt: Cast a character code to FT_UInt32 for LP64 system.
+
+ * src/sfnt/ttcmap.c (tt_cmap14_char_map_nondef_binary,
+ tt_cmap14_variants, tt_cmap14_char_variants,
+ tt_cmap14_def_char_count, tt_cmap14_get_def_chars,
+ tt_cmap14_get_nondef_chars, tt_cmap14_variant_chars)
+ Insert casts when FT_UInt32 variable is loaded by
+ TT_NEXT_{UINT24|ULONG}. Because most of them are
+ compared with FT_UInt32 values in public API, replacing
+ FT_UFast is not recommended.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ sfnt: Cast a character code to FT_UInt32 for LP64 system.
+
+ * src/sfnt/ttcmap.c (tt_cmap4_init, tt_cmap4_next):
+ Insert the casts from unsigned long constant to
+ FT_UInt32.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ sfnt: Extend TT_BDF->strings_size to FT_ULong for huge BDF.
+
+ * include/freetype/internal/tttypes.h: The type
+ of TT_BDF->string_size is extended from FT_UInt32
+ to FT_ULong, because BDF specification does not
+ restrict the length of string.
+ * src/sfnt/ttbdf.c: The scratch variable `strings'
+ to load TT_BDF->string_size is matched with
+ TT_BDF->string_size.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ psaux: Handle the string length by FT_Offset variables.
+
+ * src/psaux/afmparse.c (afm_parser_next_key,
+ afm_tokenize, afm_parse_track_kern,
+ afm_parse_kern_pairs, afm_parse_kern_data,
+ afm_parser_skip_section, afm_parser_parse):
+ The length of key is handled by FT_Offset,
+ instead of FT_UInt. Although the length of
+ PostScript strings or name object is 16-bit,
+ AFM_STREAM_KEY_LEN() calculates the length
+ from the pointer difference.
+
+ * src/psaux/afmparse.h (afm_parser_next_key):
+ Ditto.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ pcf: Fix some data types mismatching with their sources.
+
+ * src/pcf/pcfread.c (pcf_get_bitmaps): The types
+ of `nbitmaps', `i', `sizebitmaps' are matched with
+ the type of area FT_Bitmap.pitch * FT_Bitmap.rows.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ pcf: Handle the string length by size_t variables.
+
+ * src/pcf/pcfread.c (pcf_interpret_style): The types
+ of nn, len, lengths[4] are changed to size_t, because
+ they are loaded by (or compared with) ft_strlen().
+
+ * src/pcf/pcfutil.c (BitOrderInvert, TwoByteSwap,
+ FourByteSwap): The type of the 2nd argument `nbytes'
+ is changed to size_t, for similarity with ANSI C
+ string functions.
+
+ * src/pcf/pcfdrivr.c (PCF_Glyph_Load): The type of
+ `bytes' is changed to FT_Offset, because it is passed
+ to FT_ALLOC(), via ft_glyphslot_alloc_bitmap(). At
+ least, using unsigned type is better.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ pcf: Fix some data types mismatching with their sources.
+
+ * src/pcf/pcfread.c (pcf_seek_to_table_type,
+ pcf_has_table_type): The type of 3rd argument
+ `ntables' is matched with PCF_Toc->count.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ otvalid: Truncate the glyph index to 16-bit.
+
+ * src/otvalid/otvalid.c (otv_validate): Checks
+ face->num_glyphs does not exceed 16-bit limit,
+ pass FT_UInt num_glyphs to backend functions
+ otv_{GPOS|GSUB|GDEF|JSTF|MATH}_validate().
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cache: Insert explict casts for LP64 systems.
+
+ * src/cache/ftcbasic.c (FTC_ImageCache_Lookup,
+ FTC_SBitCache_Lookup): The type of FTC_ImageType->width
+ is FT_Int, so the cast to unsigned larger type FT_ULong
+ is introduced for the comparisons with 0x10000L for
+ LP64 platform.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cache: Fix some data types mismatching with their sources.
+
+ * src/cache/ftccache.h: The type of return value
+ by FTC_Node_WeightFunc function is changed to
+ FT_Offset. The type of FTC_CacheClass->cache_size
+ is changed to FT_Offset, too.
+
+ * src/cache/ftccback.h (ft_inode_weight,
+ ftc_snode_weight): Ditto.
+
+ * src/cache/ftccmap.c (ftc_cmap_node_weight): Ditto.
+
+ * src/cache/ftcimage.c (ftc_inode_weight,
+ FTC_INode_Weight): Ditto.
+
+ * src/cache/ftcsbits.c (ftc_snode_weight,
+ FTC_SNode_Weight): Ditto.
+
+ * src/cache/ftcmru.h: The type of
+ FTC_MruListClass->node_size is changed to FT_Offset,
+ because it is passed to FT_ALLOC() to specify the
+ size of buffer.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ XXX_cmap_encoding_char_next() return FT_UInt32 values.
+
+ * include/freetype/internal/services/svpscmap.h:
+ The size of the charcode value returned by
+ the function typed PS_Unicodes_CharNextFunc is
+ matched with its input charcode value.
+
+ * src/cff/cffmap.c (cff_cmap_encoding_char_next,
+ cff_cmap_unicode_char_next): Ditto.
+
+ * src/pfr/pfrmap.c (pfr_cmap_encoding_char_next):
+ Ditto.
+
+ * src/psaux/t1cmap.c (t1_cmap_std_char_next,
+ t1_cmap_custom_char_next, t1_cmap_unicode_char_next):
+ Ditto.
+
+ * src/psnames/psmodule.c (ps_unicodes_char_next):
+ Ditto.
+
+ * src/winfonts/winfnt.c (fnt_cmap_char_next):
+ Ditto.
+
+ * src/sfnt/ttcmap.c (tt_cmap0_char_next,
+ tt_cmap2_char_next, tt_cmap4_char_next,
+ tt_cmap6_char_next, tt_cmap10_char_next,
+ tt_cmap12_char_next, tt_cmap13_char_next): Ditto.
+ (tt_cmap14_char_variants): Handle base unicode
+ codepoint by FT_UInt32 variable to avoid overflow
+ on 16-bit platforms.
+ (tt_cmap14_ensure): The type of `num_results' is
+ extend to FT_UInt32, to cover unsigned 32-bit
+ `numVarSelectorRecords' in cmap14 table header.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ truetype: Extend TT_Face->num_locations for broken TTFs.
+
+ * include/freetype/internal/tttypes.h:
+ TT_Face->num_locations are extended from FT_UInt
+ to FT_ULong, to stand with broken huge loca table.
+ Some people insists there are broken TTF including
+ the glyphs over 16-bit limitation, in PRC market.
+ * src/truetype/ttpload.c (tt_face_load_loca):
+ Remove unrequired 16-bit truncation for FT_UInt
+ TT_Face->num_locations.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ smooth: Fix some data types mismatching with their sources.
+
+ * src/smooth/ftgrays.c: The type of `TCoord' is
+ matched to `TPos', because they are mixed in
+ gray_set_cell(). The type of TCell->x is extended
+ to `TPos', because gray_find_cell() sets it by
+ TWorker.ex. The type of TCell->cover is extended
+ to `TCoord', because gray_render_scanline() adds
+ TCoord value to it. The type of TWork.cover is matched
+ with TCell->cover. The types of
+ TWork.{max_cells,num_cells} are changed to FT_PtrDist,
+ because they are calculated from the memory addresses.
+ The type of TWork.ycount is changed to TPos, because
+ it is calculated from TPos variables.
+ (gray_find_cell): The type of `x' is matched with
+ its initial value ras.ex.
+ (gray_render_scanline): The types of `mod', `lift'
+ and `rem' are changed to TCoord, because their values
+ are set with explicit casts to TCoord. When ras.area
+ is updated by the differential values including
+ `delta', they are explicitly cast to TArea, because
+ the type of `delta' is not TArea but TCoord.
+ (gray_render_line): The type of `mod' is extended
+ from int to TCoord, because (TCoord)dy is added to mod.
+ (gray_hline): The argument `acount' is extended to
+ TCoord, to match with the parameters in the callers.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cff: Fix some data types mismatching with their sources.
+
+ * src/cff/cffobjs.c (cff_face_init): The type of
+ `scaling' is matched with the scaling parameter
+ in FT_Matrix_Multiply_Scaled() and
+ FT_Vector_Transform_Scaled().
+
+ * src/cff/cffparse.c (cff_parse_real): The type of
+ `power_ten', `scaling', `exponent_add',
+ `integer_length', `fraction_length',
+ `new_fraction_length' and `shift' are matched with
+ the type of `exponent' to avoid unexpected truncation.
+ (cff_parse_fixed_scaled): The type of `scaling' is
+ matched with the `scaling' argument to
+ cff_parse_real().
+ (cff_parse_fixed_dynamic): Ditto.
+ (cff_parse_font_matrix): The type of `scaling' is
+ matched with the `scaling' argument to
+ cff_parse_dynamic().
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ autofit: Fix some data types mismatching with their sources.
+
+ * src/autofit/afglobal.c: Correct the type of
+ AF_FaceGlobalsRec.glyph_count to match with
+ FT_Face->num_glyphs.
+ (af_face_globals_compute_script_coverage):
+ Insert explicit cast to compare
+ FT_Long AF_FaceGlobalsRec.glyph_count versus
+ FT_UInt gindex. The type of `nn' is changed
+ to scan glyph index upto AF_FaceGlobalsRec.glyph_count.
+ (af_face_globals_get_metrics): The type of `script_max'
+ is changed to cover size_t value. Insert explicit cast
+ to compare FT_Long AF_FaceGlobalsRec.glyph_count versus
+ FT_UInt gindex.
+
+ * src/autofit/afhints.c (af_axis_hints_new_segment):
+ Insert explicit cast to calculate `big_max' from
+ integer and size_t values.
+ (af_axis_hints_new_edge): Ditto.
+
+ * src/autofit/aflatin.c (af_latin_metrics_init_blues):
+ The type of `best_y' is matched to FT_Vector.y.
+ (af_latin_compute_stem_width): The type of `delta' is
+ matched to `dist' and `org_dist'.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ autofit: Count the size of the memory object by ptrdiff_t.
+
+ * src/autofit/afcjk.c (af_cjk_hint_edges): The
+ number of edges `n_edges' should be counted by
+ FT_PtrDist variable instead of FT_Int.
+
+ * src/autofit/aflatin.c (af_latin_hint_edges):
+ Ditto.
+
+ * src/autofit/aftypes.h: In AF_ScriptClassRec,
+ the size of metric `script_metrics_size' should
+ be counted by FT_Offset variable instead of FT_UInt.
+
+ * src/autofit/afhints.c
+ (af_glyph_hints_align_strong_points): The cursors
+ for the edges `min', `max', `mid' in the memory
+ buffer should be typed FT_PtrDist.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ autofit: Fix for unused variable `first'.
+
+ * src/autofit/afhints.c (af_glyph_hints_reload): Insert
+ FT_UNUSED() to hide the unused variable warning.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Improve bitmap size or pixel variables for 16-bit systems.
+
+ * include/freetype/config/ftstdlib.h: Introduce
+ FT_INT_MIN, to use in signed integer overflow in
+ 16-bit and 64-bit platforms.
+
+ * include/freetype/internal/fttrace.h: Add a tracer
+ to ftsynth.c.
+
+ * src/base/ftbitmap.c (FT_Bitmap_Embolden): Check
+ invalid strength causing integer overflow on 16-bit
+ platform.
+
+ * src/base/ftcalc.c (ft_corner_orientation): Change
+ the internal calculation from FT_Int to FT_Long, to
+ avoid an overflow on 16-bit platforms. The caller of
+ this function should use only the sign of result,
+ so the cast to FT_Int is acceptable.
+
+ * src/base/ftsynth.c: Introduce a tracer for synth module.
+ (FT_GlyphSlot_Embolden): Check invalid strength causing
+ integer overflow on 16-bit platform.
+
+ * src/bdf/bdfdrivr.c (BDF_Face_Init): The glyph index
+ in FT2 API is typed as FT_UInt, although BDF driver
+ can handle unsigned long glyph index internally. To
+ avoid integer overflow on 16-bit platform, too large
+ glyph index should be excluded.
+ (BDF_Glyph_Load): The glyph pitch in FT2 is typed as
+ FT_UInt, although BDF driver can handle unsigned long
+ glyph pitch internally. To avoid integer overflow on
+ 16-bit platform, too large glyph pitch should not be
+ returned.
+
+ * src/pfr/pfrsbit.c (pfr_slot_load_bitmap): The glyph
+ pitch in FT2 is typed as FT_UInt, although PFR font
+ format can include huge bitmap glyph with 24-bit pitch
+ (however, a glyph spends 16.7 pixel, it's not realistic).
+ To avoid integer overflow on 16-bit platform, huge
+ bitmap glyph should be excluded.
+
+ * src/smooth/ftgrays.c (gray_hline): As FT_Span.x is
+ truncated to fit its type (16-bit short), FT_Span.y
+ should be truncated to fit its type (FT_Int).
+
+ * src/cff/cffdrivr.c (cff_get_ros): CFF specification
+ defines the supplement in ROS as a real number.
+ Truncate it to fit public FT2 API.
+
+ * src/cff/cffparse.c (cff_parse_cid_ros): Warn the
+ supplement if it is truncated or rounded in cff_get_ros().
+
+ * src/cff/cfftypes.h: Change the type of internal variable
+ `supplement' from FT_Long to FT_ULong to fit the signedness
+ to the type in public API.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ psaux: Prevent invalid arguments to afm_parser_read_vals().
+
+ * src/psaux/afmparse.c (afm_parser_read_vals): Change
+ the type of `n' to prevent negative number how many
+ arguments should be parsed.
+
+ * src/psaux/afmparse.h (afm_parser_read_vals): Ditto.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ base: Prevent some overflows on LP64 systems.
+
+ * src/base/ftadvance.c (FT_Get_Advances): Cast the
+ unsigned long constant FT_LOAD_ADVANCE_ONLY to FT_UInt32
+ for LP64 platforms.
+
+ * src/base/ftcalc.c (FT_Sqrt32): All internal variables
+ are changed to FT_UInt32 from FT_ULong.
+ (FT_MulDiv): Insert casts to FT_Int32 for LP64 platforms.
+ This function is designed for 32-bit integer, although
+ their arguments and return value are FT_Long.
+
+ * src/base/ftobjs.c (FT_Get_Char_Index): Check `charcode'
+ is within unsigned 32-bit integer for LP64 platforms.
+ (FT_Face_GetCharVariantIndex): Check `charcode' and
+ `variantSelector' are within 32-bit integer for LP64
+ platforms.
+ (FT_Face_GetCharsOfVariant): Check `variantSelector' is
+ within unsigned 32-bit integer for LP64 platforms.
+
+ * src/base/fttrigon.c (ft_trig_downscale): The FT_Fixed
+ variable `val' and unsigned long constant FT_TRIG_SCALE
+ are cast to FT_UInt32, when calculates FT_UInt32.
+ (FT_Vector_Rotate): The long constant 1L is cast to
+ FT_Int32 to calculate FT_Int32 `half'.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cff: Cast the long variables to 32-bit for LP64 systems.
+
+ * src/cff/cffdrivr.c (cff_get_advances): Insert
+ explicit cast to modify a 32-bit flag by unsigned
+ long constant.
+
+ * src/cff/cffobjs.c (cff_face_init): Ditto.
+
+ * src/cff/cffgload.c (cff_decoder_parse_charstrings):
+ Replace the casts to FT_Long by the casts to FT_Int32
+ for LP64 platforms.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ pcf: Improve PCF_PropertyRec.value names on LP64 platforms.
+
+ * src/pcf/pcf.h: In PCF_PropertyRec.value, the member
+ `integer' is replaced by `l', `cardinal' is replaced
+ by `ul', to fix the difference between the name and
+ the types on LP64 platforms.
+
+ * src/pcf/pcfdrivr.c (pcf_get_bdf_property): Reflect
+ PCF_PropertyRec.value change, with appropriate casts
+ to FT_Int32/FT_UInt32. Their destinations
+ BDF_PropertyRec.{integer|cardinal} are public and
+ explicitly defined as FT_Int32/FT_UInt32.
+
+ * src/pcf/pcfread.c (pcf_get_properties, pcf_load_font):
+ Reflect PCF_PropertyRec.value change.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ pcf: Fix some data types mismatching with their sources.
+
+ * src/pcf/pcfdrivr.c (pcf_cmap_char_index): The type of
+ `code' is matched to PCF_Encoding->enc.
+ (pcf_cmap_char_next): The type of `charcode' is matched
+ to PCF_Encoding->enc. When *acharcode is set by charcode,
+ an overflow is checked and cast to unsigned 32-bit
+ integer.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ bdf: Improve bdf_property_t.value names for LP64 platforms.
+
+ * src/bdf/bdf.h: In bdf_property_t.value, the member
+ `int32' is replaced by `l', `card32' is replaced by
+ `ul', to fix the difference between the name and the
+ types on LP64 platforms.
+
+ * src/bdf/bdfdrivr.c (BDF_Face_Init): Reflect
+ bdf_property_t.value change.
+ (bdf_get_bdf_property): Reflect bdf_property_t.value
+ change, with appropriate casts to FT_Int32/FT_UInt32.
+ Their destinations BDF_PropertyRec.{integer|cardinal}
+ are public and explicitly defined as FT_Int32/FT_UInt32.
+
+ * src/bdf/bdflib.c (_bdf_add_property): Reflect
+ bdf_property_t.value change.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ bdf: Fix some data types mismatching with their sources.
+
+ * src/bdf/bdrdrivr.c (bdf_cmap_char_index): The type
+ of `code' is matched with BDF_encoding_el->enc.
+ (bdf_cmap_char_next): The type of `charcode' is
+ matched with BDF_encoding_el->enc. When *acharcode
+ is set by charcode, an overflow is checked and
+ cast to unsigned 32-bit integer.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ autofit: Improve Unicode range definitions.
+
+ * src/autofit/aftypes.h (AF_UNIRANGE_REC): New macro
+ to declare a range by two unsigned 32-bit integer,
+ to avoid 64-bit range definition on LP64 platforms.
+
+ * src/autofit/aflatin.c (af_latin_uniranges): Ditto.
+
+ * src/autofit/aflatin2.c (af_latin2_uniranges): Ditto.
+
+ * src/autofit/afindic.c (af_indic_uniranges): Ditto.
+
+ * src/autofit/afcjk.c (af_cjk_uniranges): Declare
+ the ranges by AF_UNIRANGE_REC.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ smooth: Fix a data type mismatching with its source.
+
+ * src/smooth/ftgrays.c (gray_sweep): The type of
+ `area' is matched with the 3rd argument `area'
+ of gray_hline().
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ smooth: Fix a data type mismatching with its source.
+
+ * src/smooth/ftgrays.c (gray_render_line): The type
+ of `area' is matched with TWorker.area.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cache: Disable the legacy compatibility if 16-bit system.
+
+ * src/cache/ftcbasic.c (FTC_ImageCache_Lookup): Exclude
+ the legacy behaviour from 16-bit platform, because the
+ current hack cannot detect the caller uses this function
+ via legacy convension.
+ (FTC_SBitCache_Lookup): Ditto.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cache: Check 32-bit glyph index on 16-bit systems.
+
+ * src/cache/ftcbasic.c (ftc_basic_family_get_count):
+ Check overflow caused by the face including large
+ number of glyphs > 64k.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cache: Fix some data types mismatching with their sources.
+
+ * src/cache/ftccache.c (ftc_cache_resize): The types of
+ `p', `mask', `count' are matched with FTC_Cache->{p,mask}.
+ (FTC_Cache_Clear): The type of `old_index' is matched to
+ FTC_Cache->{p,mask}.
+
+ * src/cache/ftccache.h (FTC_CACHE_LOOKUP_CMP): The type
+ of `_idx' is matched with FTC_Cache->{p,mask}.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cache: Fix some data types mismatching with their sources.
+
+ * src/cache/ftcsbits.c (ftc_snode_load): The types
+ of `xadvance' and `yadvance' are matched with
+ FT_GlyphSlot->advance.{x|y}.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cache: Cast NULL to a required function type explicitly.
+
+ * src/cache/ftcmanag.c (FTC_Manager_RemoveFaceID):
+ Insert explicit cast from NULL to function type.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ fttypes.h: Cast FT_MAKE_TAG output to FT_Tag exlicitly.
+
+ * include/freetype/fttypes.h (FT_MAKE_TAG):
+ Cast the result to FT_Tag.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ psnames: Handle Unicode codepoints by FT_UInt32 variables.
+
+ * src/psnames/psmodule.c (BASE_GLYPH): Cast the result
+ to unsigned 32-bit integer for LP64 platform.
+ (ps_unicode_value): Return the value by unsigned 32-bit
+ integer instead of unsigned long.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ psaux: Use size_t variable to pass the buffer size.
+
+ * src/psaux/psaux.h (to_bytes): The type of `max_bytes'
+ (the argument to pass the buffer size) is changed to
+ size_t, to match with ANSI C string functions.
+
+ * src/psaux/psconv.h (PS_Conv_StringDecode,
+ PS_Conv_ASCIIHexDecode, PS_Conv_EexecDecode): Ditto.
+
+ * src/psaux/psconv.c (PS_Conv_StringDecode,
+ PS_Conv_ASCIIHexDecode, PS_Conv_EexecDecode): Ditto.
+
+ * src/psaux/psobjs.h (ps_parser_to_bytes): Ditto.
+
+ * src/psaux/psobjs.c (ps_parser_to_bytes): Ditto.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ type1: Use size_t variable to pass the string length.
+
+ * psaux.h: The type of `len' (the argument to pass
+ the buffer size to the function in AFM_ParserRec)
+ is changed to size_t, to match with ANSI C string
+ functions.
+
+ * t1afm.c (t1_get_index): Ditto.
+
+ * test_afm.c (dummy_get_index): Ditto.
+
+ * afmparse.c (afm_parser_read_vals): To call
+ AFM_ParserRec.get_index, the length of token
+ `len' is cast to size_t.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cid: Fix some data types mismatching with their sources.
+
+ * src/cid/cidparse.c (cid_parser_new): The types of
+ `read_len' and `stream_len' are matched to
+ FT_Stream->size. Unrequired cast is removed.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cff: Fix for unused variable `rest'.
+
+ * src/cff/cffparse.c (cff_parse_real): Insert
+ FT_UNUSED() to hide the unused variable warning.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ cff: Fix some data types mismatching with their sources.
+
+ * src/cff/cffgload.c (cff_slot_load): The types of
+ `top_upm' and `sub_upm' are matched with
+ CFF_FontRecDict->units_per_em.
+
+ * src/cff/cffobjs.c (cff_size_select): Ditto.
+ (cff_size_request): Ditto.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ bdf: Fix some data types mismatching with their sources.
+
+ * bdflib.c (_bdf_list_ensure): The type of `num_items'
+ is matched with _bdf_list_t.used. Also the types of
+ `oldsize', `newsize', `bigsize' are matched too.
+ (_bdf_readstream): `cursor' is used as an offset to
+ the pointer, it should be typed as FT_Offset. Also
+ the types of `bytes', `start', `end', `avail' are matched.
+
+ * bdfdrivr.c: The type of BDF_CMap->num_encodings is
+ matched with FT_CMap->clazz->size.
+ (bdf_cmap_char_index): The types of `min', `max', `mid'
+ are matched with BDF_CMap->num_encodings. The type of
+ `result' is matched with encoding->glyph.
+ (bdf_cmap_char_next): Ditto, the type of `code' is
+ matched with BDF_encoding_el.enc.
+ (bdf_interpret_style): The type of `lengths' is changed
+ to size_t, to take the value by ft_strlen(). Also the
+ types of `len', `nn', `mm' are matched.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ sfnt: Count the size of the memory object by ptrdiff_t.
+
+ * src/sfnt/ttbdf.c (tt_face_find_bdf_prop): The type of
+ `peroperty_len' is changed from FT_UInt to FT_Offset,
+ to match with size_t, which is appropriate type for the
+ object in the memory buffer.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ lzw: Count the size of the memory object by ptrdiff_t.
+
+ * src/lzw/ftzopen.h: The types of FT_LzwState->{buf_total,
+ stack_size} are changed from FT_UInt to FT_Offset, to match
+ with size_t, which is appropriate type for the object in
+ the memory buffer.
+
+ * src/lzw/ftzopen.c (ft_lzwstate_stack_grow): The types of
+ `old_size' and `new_size' are changed from FT_UInt to
+ FT_Offset, to match with size_t, which is appropriate type
+ for the object in the memory buffer.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ otvalid: Count the table size on memory by ptrdiff_t.
+
+ * src/otvalid/otvgpos.c (otv_ValueRecord_validate):
+ Change the type of table size from FT_UInt to
+ FT_PtrDist because it is calculated by the memory
+ addresses.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ otvalid: Prevent an overflow by GPOS/GSUB 32b-bit offset.
+
+ * src/otvalid/otvgpos.c (otv_ExtensionPos_validate):
+ Extend ExtensionOffset from FT_UInt to FT_ULong, to
+ cover 32-bit offset on 16-bit platform.
+
+ * src/otvalid/otvgsub.c (otv_ExtensionSubst_validate):
+ Ditto.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ ftobjs.c: Prevent an overflow in glyph index handling.
+
+ * src/base/ftobjs.c (FT_Face_GetCharsOfVariant):
+ Improve the cast in comparison to avoid the truncation.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Improve the variable types in raccess_make_file_name().
+
+ * src/base/ftrfork.c (raccess_make_file_name):
+ Change the type of cursor variable `tmp' to const char*,
+ to prevent the unexpected modification of original pathname.
+ (raccess_make_file_name): Change the type of new_length
+ to size_t.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ ftpatent.c: Fix for unused variable `error'.
+
+ * src/base/ftpatent.c (_tt_check_patents_in_range):
+ Fix warning for unused variable `error'.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ type1: Check invalid string longer than PostScript limit.
+
+ * src/type1/t1afm.c (t1_get_index): Check invalid string
+ which exceeds the limit of PostScript string/name objects.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ gzip: Use FT2 zcalloc() & zfree() in ftgzip.c by default.
+
+ * src/gzip/ftgzip.c (zcalloc, zcfree): Disable all
+ zcalloc() & zfree() by zlib in zutil.c, those in
+ ftgzip.c by FT2 are enabled by default. To use
+ zlib zcalloc() & zfree(), define USE_ZLIB_ZCALLOC.
+ See discussion:
+ http://lists.gnu.org/archive/html/freetype-devel/2009-02/msg00000.html
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ gzip: Distinguish PureC from TurboC on MSDOS.
+
+ * src/gzip/zutil.c (zcalloc, zcfree): Enable only for
+ MSDOS platform.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ gxvalid: Insert PureC pragma to allow unevaluated variables.
+
+ * builds/atari/ATARI.H: Insert PureC pragma not to
+ warn against set-but-unevaluated variable in gxvalid
+ module.
+
+2009-07-31 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ gxvalid: Pass the union by the pointer instead of the value.
+
+ * src/gxvalid/gxvcommn.h:
+ - Declare new type `GXV_LookupValueCPtr'.
+ - Update the type of the 2nd argument to pass GXV_LookupValueDesc
+ data to the function prototyped as GXV_Lookup_Value_Validate_Func,
+ from GXV_LookupValueDesc to GXV_LookupValueCPtr.
+ - Likewise for the function prototyped as
+ GXV_Lookup_Fmt4_Transit_Func.
+
+ - Declare new type `GXV_StateTable_GlyphOffsetCPtr'.
+ - Update the type of the 3rd argument to pass
+ GXV_StateTable_GlyphOffsetDesc data to the function prototyped
+ as GXV_StateTable_Entry_Validate_Func, from
+ GXV_StateTable_GlyphOffsetDesc to GXV_StateTable_GlyphOffsetCPtr.
+
+ - Declare new type `GXV_XStateTable_GlyphOffsetCPtr'.
+ - Update the type of the 3rd argument to pass
+ GXV_XStateTable_GlyphOffsetDesc data to the function prototyped
+ as GXV_XStateTable_Entry_Validate_Func,
+ from GXV_XStateTable_GlyphOffsetDesc
+ to GXV_XStateTable_GlyphOffsetCPtr.
+
+ * src/gxvalid/gxvcommn.c (gxv_LookupTable_fmt0_validate,
+ gxv_XClassTable_lookupval_validate,
+ gxv_XClassTable_lookupfmt4_transit):
+ Update from GXV_LookupValueDesc to GXV_LookupValueCPtr.
+
+ * src/gxvalid/gxvbsln.c (gxv_bsln_LookupValue_validate,
+ gxv_bsln_LookupFmt4_transit): Ditto.
+
+ * src/gxvalid/gxvjust.c
+ (gxv_just_pcTable_LookupValue_entry_validate,
+ gxv_just_classTable_entry_validate,
+ gxv_just_wdcTable_LookupValue_validate): Ditto.
+
+ * src/gxvalid/gxvkern.c
+ (gxv_kern_subtable_fmt1_entry_validate): Ditto.
+
+ * src/gxvalid/gxvlcar.c (gxv_lcar_LookupValue_validate,
+ gxv_lcar_LookupFmt4_transit): Ditto.
+
+ * src/gxvalid/gxvopbd.c (gxv_opbd_LookupValue_validate,
+ gxv_opbd_LookupFmt4_transit): Ditto.
+
+ * src/gxvalid/gxvprop.c (gxv_prop_LookupValue_validate,
+ gxv_prop_LookupFmt4_transit): Ditto.
+
+ * src/gxvalid/gxvmort4.c
+ (gxv_mort_subtable_type4_lookupval_validate): Ditto.
+
+ * src/gxvalid/gxvmort0.c
+ (gxv_mort_subtable_type0_entry_validate): Update
+ from GXV_StateTable_GlyphOffsetDesc
+ to GXV_StateTable_GlyphOffsetCPtr.
+
+ * src/gxvalid/gxvmort1.c
+ (gxv_mort_subtable_type1_entry_validate): Ditto.
+
+ * src/gxvalid/gxvmort2.c
+ (gxv_mort_subtable_type2_entry_validate): Ditto.
+
+ * src/gxvalid/gxvmort5.c
+ (gxv_mort_subtable_type5_entry_validate): Ditto.
+
+ * src/gxvalid/gxvmorx2.c
+ (gxv_morx_subtable_type2_entry_validate): Ditto.
+
+ * src/gxvalid/gxvmorx5.c
+ (gxv_morx_subtable_type5_entry_validate): Ditto.
+
+ * src/gxvalid/gxvmorx1.c
+ (gxv_morx_subtable_type1_entry_validate): Ditto.
+ (gxv_morx_subtable_type1_LookupValue_validate,
+ gxv_morx_subtable_type1_LookupFmt4_transit):
+ Update from GXV_LookupValueDesc to GXV_LookupValueCPtr.
+
+ * src/gxvalid/gxvmorx0.c
+ (gxv_morx_subtable_type0_entry_validate): Update
+ from GXV_XStateTable_GlyphOffsetDesc
+ to GXV_XStateTable_GlyphOffsetCPtr.
+
+2009-07-29 Fabrice Bellet <fabrice@bellet.info>
+
+ Fix Redhat bugzilla #513582 and Savannah bug #26849.
+
+ * src/cache/ftccache.h (FTC_CACHE_LOOKUP_CMP) <FTC_INLINE>: Fix
+ aliasing bug.
+
+2009-07-19 Werner Lemberg <wl@gnu.org>
+
+ Document recent library changes.
+
+ * docs/CHANGES: Do it.
+
+2009-07-17 Werner Lemberg <wl@gnu.org>
+
+ Fix Savannah bug #23786.
+
+ * src/truetype/ttobjs.c (tt_size_init_bytecode): Don't reset x_ppem
+ and y_ppem. Otherwise the `*_CVT_Stretched' functions in ttinterp.c
+ get never called.
+ An anonymous guy suggested this change on Savannah, and it seems to
+ be the right solution.
+
+2009-07-15 Werner Lemberg <wl@gnu.org>
+
+ * docs/release: Updated.
+
+2009-07-15 Werner Lemberg <wl@gnu.org>
+
+ README.CVS -> README.git
+
+ * README.CVS: Renamed to...
+ * README.git: This.
+ Updated.
+
+2009-07-15 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Borland C++ compiler patch proposed by Mirco Babin.
+ http://lists.gnu.org/archive/html/freetype/2009-07/msg00016.html.
+
+ * builds/exports.mk: Delete unused flags, CCexe_{CFLAGS,LDFLAGS}.
+ Fix APINAMES_C and APINAMES_EXE pathnames to reflect the platform
+ specific pathname syntax.
+ * builds/compiler/bcc.mk: Remove unused flag, CCexe_LDFLAGS.
+ Define TE = `-e' separately (bcc32 cannot specify the pathname of
+ binary executable by T = `-o').
+ Extend the large page size in linking freetype.lib.
+ Add extra CLEAN target to delete bcc specific temporary files.
+ * builds/compiler/bcc-dev.mk: Ditto.
+
+2009-07-14 Werner Lemberg <wl@gnu.org>
+
+ Fix Savannah bug #27026.
+
+ * builds/win32/vc2005/freetype.sln: Use correct version number.
+
+2009-07-12 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Add a script to check the undefined and unused trace macros.
+
+ * src/tools/chktrcmp.py: A script to check trace_XXXX macros
+ that are used in C source but undefined in fttrace.h, or
+ defined in fttrace.h but unused in C sources. See
+ http://lists.gnu.org/archive/html/freetype-devel/2009-07/msg00013.html.
+ * docs/DEBUG: Mention on chktrcmp.py.
+ * docs/release: Ditto.
+
+2009-07-09 Werner Lemberg <wl@gnu.org>
+
+ [ftraster] Make it compile again with -D_STANDALONE_.
+
+ * src/raster/ftraster.c [_STANDALONE_]: Define
+ FT_CONFIG_STANDARD_LIBRARY_H.
+ Include `string.h'.
+ Don't include `rastpic.h'.
+ Define FT_DEFINE_RASTER_FUNCS.
+
+2009-07-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ smooth: Check glyph size by width/height, instead of pitch/height.
+ Suggested by der Mouse <mouse@Rodents-Montreal.ORG>.
+
+ * src/smooth/ftsmooth.c (ft_smooth_render_generic): Improve
+ the check for too large glyph. Replace the pair of `pitch' and
+ `height' by the pair of `width' and `height'. `pitch' cannot
+ be greater than `height'. The required is checking the product
+ `pitch' * `height' <= FT_ULONG_MAX, but we use cheap checks for
+ the realistic case only.
+
+2009-07-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Register 2 missing trace components, t1afm and ttbdf.
+
+ * include/freetype/internal/fttrace.h: Add FT_TRACE_DEF( t1afm )
+ and FT_TRACE_DEF( ttbdf ). See
+ http://lists.gnu.org/archive/html/freetype-devel/2009-07/msg00013.html
+
+2009-07-09 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Register a trace component for ftgloadr.c.
+
+ * include/freetype/internal/fttrace.h: Add FT_TRACE_DEF( gloader ).
+ The macro `trace_gloader' was already used in the initial version
+ on 2002-02-24.
+
+2009-07-08 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Prevent the overflows by a glyph with too many points or contours.
+ The bug is reported by Boris Letocha <b.letocha@gmc.net>. See
+ http://lists.gnu.org/archive/html/freetype-devel/2009-06/msg00031.html
+ http://lists.gnu.org/archive/html/freetype-devel/2009-07/msg00002.html
+
+ * include/freetype/ftimage.h (FT_OUTLINE_CONTOURS_MAX,
+ FT_OUTLINE_POINTS_MAX): New macros to declare the maximum
+ values of FT_Outline.{n_contours,n_points}.
+ * src/base/ftgloadr.c (FT_GlyphLoader_CheckPoints): Check the
+ total numbers of points and contours cause no overflows in
+ FT_Outline.{n_contours,n_points}.
+
+ * include/freetype/internal/ftgloadr.h (FT_GLYPHLOADER_CHECK_P,
+ FT_GLYPHLOADER_CHECK_C): Compare the numbers of points and
+ contours as unsigned long number, instead of signed int, to
+ prevent the overflows on 16-bit systems.
+
+2009-07-05 Bram Tassyns <bramt@enfocus.be>
+
+ Improve compatibility to Acroread.
+ This fixes Savannah bug #26944.
+
+ * src/cff/cffload.c (cff_charset_compute_cids): For multiple GID to
+ single CID mappings, make the lowest value win.
+
+2009-06-28 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ ftpatent: Fix a bug by wrong usage of service->table_info().
+ http://lists.gnu.org/archive/html/freetype-devel/2008-12/msg00039.html
+
+ * include/freetype/internal/services/svsfnt.h: Extend
+ FT_SFNT_TableInfoFunc() to take new argument to obtain the offset
+ to the specified table.
+ * src/sfnt/sfdriver.c (sfnt_table_info): Extend to return the
+ table-offset to the caller function.
+ * src/base/ftpatent.c (_tt_check_patents_in_table): Use new
+ service->table_info().
+ * src/base/ftobjs.c (FT_Sfnt_Table_Info): Synchronize to new
+ service->table_info().
+
+2009-06-28 Werner Lemberg <wl@gnu.org>
+
+ [psaux, cff] Protect against nested `seac' calls.
+
+ * include/freetype/internal/psaux.h (T1_Decoder), src/cff/cffgload.h
+ (CFF_Decoder): Add `seac' boolean variable.
+
+ * src/cff/cffgload.c (cff_operator_seac), src/psaux/t1decode.c
+ (t1operator_seac): Use it.
+
+2009-06-28 Werner Lemberg <wl@gnu.org>
+
+ Thinko.
+
+ * src/psaux/t1decode.c (t1operator_seac)
+ [FT_CONFIG_OPTION_INCREMENTAL]: Test for existence of incremental
+ interface.
+
+2009-06-28 Werner Lemberg <wl@gnu.org>
+
+ * devel/ftoption.h [FT_CONFIG_OPTION_INCREMENTAL]: Define.
+
+2009-06-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Add tools to preprocess the source files for AtariST PureC.
+
+ * builds/atari/deflinejoiner.awk: New file to filter C source files
+ for broken C preprocessor of PureC compiler.
+
+ * builds/atari/gen-purec-patch.sh: New file to generate a patch set
+ for PureC, by using deflinejoiner.awk.
+
+2009-06-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Keep existing modules.cfg in the building tree.
+
+ * configure: If `configure' is executed outside of the source tree,
+ an existing `modules.cfg' file in the build directory should be
+ kept, not overwritten by the version in the source tree.
+
+2009-06-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Filter --srcdir= option before invoking builds/unix/configure.
+
+ * configure: If builds/unix/configure is invoked with --srcdir
+ option, the option should take `builds/unix' directory instead of
+ the top source directory. Thus the configure script in the top
+ directory should modify the --srcdir= option if
+ `builds/unix/configure' is invoked.
+
+2009-06-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
+
+ Improve configure.raw for cross-building on exe-suffixed systems.
+
+ * builds/unix/configure.raw: Fix a bug in sed script to extract
+ native suffix for binary executables, patch by Peter Breitenlohner.
+ http://lists.gnu.org/archive/html/freetype-devel/2009-04/msg00036.html
+
+2009-06-26 Werner Lemberg <wl@gnu.org>
+
+ [truetype] Remove TT_SubGlyphRec.
+
+ * src/truetype/ttobjs.h (TT_SubGlyphRec): Removed, unused.
+
+2009-06-26 Werner Lemberg <wl@gnu.org>
+
+ * */*: For warning messages, replace FT_ERROR with FT_TRACE0.
+
+ FT_ERROR is now used only if a function produces a non-zero `error'
+ value.
+
+ Formatting, improving and harmonizing debug strings.
+
+2009-06-25 Werner Lemberg <wl@gnu.org>
+
+ Provide version information better.
+
+ * src/base/ftinit.c (FT_Init_FreeType): Don't set version here
+ but...
+ * src/base/ftobjs.c (FT_New_Library): Here.
+
+2009-06-22 Werner Lemberg <wl@gnu.org>
+
+ Use 16.16 format while parsing Type 1 charstrings.
+ This fixes Savannah bug #26867.
+
+ Previously, only integers have been used which can lead to serious
+ rounding errors.
+
+ However, fractional values are only used internally; after the
+ charstrings (of either Type 1 or 2) have been processed, the
+ resulting coordinates get rounded to integers currently -- before
+ applying scaling. This should be fixed; at the same time a new load
+ flag should be introduced, to be used in combination with
+ FT_LOAD_NO_SCALE, which indicates that font units are returned in
+ 16.16 format. Similarly, the incremental interface should be
+ extended to allow fractional values for metrics.
+
+ * include/freetype/internal/psaux.h (T1_BuilderRec): Remove `shift'
+ field.
+ * include/freetype/internal/pshints.h (T1_Hints_SetStemFunc,
+ T1_Hints_SetStem3Func): Use FT_Fixed for coordinates.
+
+ * src/psaux/psobjs.c: Include FT_INTERNAL_CALC_H.
+ (t1_build_add_point): Always convert fixed to integer.
+ * src/psaux/t1decode.c (t1_decoder_parse_charstrings):
+ Use 16.16 format everywhere (except for large integers followed by a
+ `div').
+ [CAN_HANDLE_NON_INTEGRAL_T1_OPERANDS]: Remove #ifdef and activate
+ code uncoditionally.
+ Add support for random numbers and update remaining code
+ accordingly; this should work now.
+ (t1_operator_seac): Updated.
+ * src/psaux/pshrec.c: Include FT_INTERNAL_CALC_H.
+ (ps_hints_t1stem3, t1_hints_stem): Updated.
+
+ * src/cid/cidgload.c: Include FT_INTERNAL_CALC_H.
+ (cid_load_glyph) [FT_CONFIG_OPTION_INCREMENTAL],
+ (cid_face_compute_max_advance, cid_slot_load_glyph): Updated.
+
+ * src/type1/t1gload.c (T1_Parse_Glyph_And_Get_Char_String)
+ [FT_CONFIG_OPTION_INCREMENTAL], (T1_Get_Advances, T1_Load_Glyph):
+ Updated.
+ * src/type1/t1load.c: Include FT_INTERNAL_CALC_H.
+ * src/type1/t1objs.c (T1_Face_Init): Updated.
+
+2009-06-21 Werner Lemberg <wl@gnu.org>
+
+ * src/pshinter/pshrec.c: Use PSH_Err_Ok.
+
+2009-06-21 Werner Lemberg <wl@gnu.org>
+
+ Code beautification.
+
+ * src/type1/t1load.c (FT_INT_TO_FIXED): Removed.
+ Replace everywhere with INT_TO_FIXED.
+ (FT_FIXED_TO_INT): Move to ...
+ * include/freetype/internal/ftcalc.h (FIXED_TO_INT): Here.
+ Update all users.
+
+2009-06-20 Werner Lemberg <wl@gnu.org>
+
+ Remove unused variables.
+
+ * include/freetype/internal/psaux.h (T1_BuilderRec),
+ src/cff/cffgload.h (CFF_Builder): Remove `last'.
+ Update all users.
+
+2009-06-20 Werner Lemberg <wl@gnu.org>
+
+ [psaux] Check large integers while parsing charstrings.
+
+ * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Large
+ integers must be followed by a `div' operator.
+
+2009-06-20 Werner Lemberg <wl@gnu.org>
+
+ [cff] Revert last change.
+
+ * src/cff/cffgload.c (cff_decoder_parse_charstrings): Do it.
+ Next time, don't confuse Type 2 charstring opcodes with TOP DICT
+ values...
+
+2009-06-20 Werner Lemberg <wl@gnu.org>
+
+ * src/autofit/aflatin.c (af_latin_metrics_check_digits): Fix
+ compiler warning.
+
+2009-06-20 Werner Lemberg <wl@gnu.org>
+
+ * builds/compiler/gcc.mk (CFLAGS): Use -O3, not -O6.
+
+2009-06-19 Werner Lemberg <wl@gnu.org>
+
+ [cff] Fix handling of reserved byte 0xFF.
+
+ * src/cff/cffgload.c (cff_decoder_parse_charstrings): Abort if byte
+ 0xFF is encountered.
+
+2009-06-19 Werner Lemberg <wl@gnu.org>
+
+ Improve debug messages for Type1 charstrings.
+
+ * src/psaux/t1decode.c (t1_decoder_parse_charstrings): Emit newlines
+ after instructions.
+ Prettify output.
+
+2009-06-19 Werner Lemberg <wl@gnu.org>
+
+ More ftgray fixes for FT_STATIC_RASTER.
+ Problems reported by suyu@cooee.cn.
+
+ * src/smooth/ftgrays.c (gray_move_to, gray_raster_render): Use
+ RAS_VAR.
+
+2009-06-18 Werner Lemberg <wl@gnu.org>
+
+ * docs/CHANGES: Updated.
+
+2009-06-18 Werner Lemberg <wl@gnu.org>
+
+ Fix B/W rasterization of subglyphs with different drop-out modes.
+
+ Normally, the SCANMODE instruction (if present) to set the drop-out
+ mode in a TrueType font is located in the `prep' table only and thus
+ valid for all glyphs. However, there are fonts like `pala.ttf'
+ which additionally contain this instruction in the hinting code of
+ some glyphs (but not all). As a result it can happen that a
+ composite glyph needs multiple drop-out modes for its subglyphs
+ since the rendering state gets reset for each subglyph.
+
+ FreeType collects the hinted outlines from all subglyphs, then it
+ sends the data to the rasterizer. It also sends the drop-out mode
+ -- after hinting has been applied -- and here is the error: It sends
+ the drop-out mode of the last subglyph only; drop-out modes of all
+ other subglyphs are lost.
+
+ This patch fixes the problem; it adds a second, alternative
+ mechanism to pass the drop-out mode: For each contour, the
+ rasterizer now checks the first `tags' array element. If bit 2 is
+ set, bits 5-7 contain the contour's drop-out mode, overriding the
+ global drop-out mode.
+
+ * include/freetype/ftimage.h (FT_CURVE_TAG_HAS_SCANMODE): New macro.
+
+ * src/truetype/ttgload.c (TT_Hint_Glyph): Store drop-out mode in
+ `tags[0]'.
+
+ * src/raster/ftraster.c (Flow_Up, Overshoot_Top, Overshoot_Bottom):
+ Use bits 3-5 instead of 0-2.
+ (New_Profile): Set the drop-out mode in the profile's `flags' field.
+ (Decompose_Curve): Check `tags[0]' and set `dropOutControl' if
+ necessary.
+ (Vertical_Sweep_Drop, Horizontal_Sweep_Drop,
+ Horizontal_Gray_Sweep_Drop, Draw_Sweep): Use the profile's drop-out
+ mode.
+
+2009-06-16 Werner Lemberg <wl@gnu.org>
+
+ Improve scan conversion rules 4 and 6.
+
+ Two new constraints are introduced to better identify a `stub' -- a
+ concept which is only vaguely described in the OpenType
+ specification. The old code was too rigorous and suppressed more
+ pixel than it should.
+
+ . The intersection of the two profiles with the scanline is less
+ than a half pixel. Code related to this was already present in
+ the sources but has been commented out.
+
+ . The endpoint of the original contour forming a profile has a
+ distance (`overshoot') less than half a pixel to the scanline.
+
+ Note that the two additional conditions fix almost all differences
+ to the Windows rasterizer, but some problematic cases remain.
+
+ * src/raster/ftraster.c (Overshoot_Top, Overshoot_Bottom): New
+ macros for the `flags' field in the `TProfile' structure.
+ (IS_BOTTOM_OVERSHOOT, IS_TOP_OVERSHOOT): New macros.
+ (New_Profile, End_Profile): Pass overshoot flag as an argument and
+ set it accordingly.
+ Update callers.
+ (Vertical_Sweep_Drop, Horizontal_Sweep_Drop): Implement the two new
+ constraints.
+
+2009-06-11 Werner Lemberg <wl@gnu.org>
+
+ Increase precision for B/W rasterizer.
+
+ * src/raster/ftraster.c (Set_High_Precision): Add two more bits to
+ the precision. This corrects rendering of some small glyphs, for
+ example, glyph `xi' in verdana.ttf at 13 ppem. Testing with ftbench
+ on my GNU/Linux box I don't see a performance degradation.
+
+2009-06-08 Michael Zucchi <notzed@gmail.com>
+
+ Handle FT_STROKER_LINECAP_BUTT.
+ This fixes Savannah bug #26757.
+
+ * src/base/ftstroke.c (ft_stroker_cap): Implement it.
+
+2009-06-07 Harald Fernengel <harry@kdevelop.org>
+
+ Fix some potential out-of-memory crashes.
+
+ * src/base/ftobjs.c (ft_glyphslot_done): Check `slot->internal'.
+ * src/base/ftstream.c (FT_Stream_ReleaseFrame): Check `stream'.
+ * src/truetype/ttinterp.c (TT_New_Context): Avoid double-free of
+ `exec' in case of failure.
+
+2009-06-07 Werner Lemberg <wl@gnu.org>
+
+ Simplify math.
+ Suggested by Alexei Podtelezhnikov <apodtele@gmail.com>.
+
+ * src/raster/ftraster.c (Vertical_Sweep_Drop, Horizontal_Sweep_Drop,
+ Horizontal_Gray_Sweep_Drop): Do it.
+
+2009-06-04 Werner Lemberg <wl@gnu.org>
+
+ Preparation for fixing scan conversion rules 4 and 6.
+
+ * src/raster/ftraster.c (TFlow): Replace enumeration with...
+ (Flow_Up): This macro.
+ (TProfile): Replace `flow' member with `flags' bit field.
+ Update all affected code.
+
+2009-05-29 James Cloos <cloos@jhcloos.com>
+
+ Enable autohinting for glyphs rotated by multiples of 90°.
+
+ * src/base/ftobjs.c (FT_Load_Glyph): Alter check for permitted
+ matrices to allow rotations by multiples of 90°, not only unrotated,
+ possibly slanted matrices.
+
+2009-05-28 Werner Lemberg <wl@gnu.org>
+
+ Remove compiler warning.
+ Reported by Krzysztof Kowalczyk <kkowalczyk@gmail.com>.
+
+ * src/autofit/aflatin2.c (af_latin2_hint_edges): Move declaration of
+ `n_edges' into `#if' block.
+
+2009-05-28 Werner Lemberg <wl@gnu.org>
+
+ Make compilation work with FT_CONFIG_OPTION_USE_ZLIB not defined.
+ Reported by Krzysztof Kowalczyk <kkowalczyk@gmail.com>.
+
+ * src/pcf/pcfdrivr.c (PCF_Face_Init) [!FT_CONFIG_OPTION_USE_ZLIB]:
+ Make it work.
+ Simplify #ifdef logic.
+
+2009-05-22 Werner Lemberg <wl@gnu.org>
+
+ Improve b/w rasterizer.
+ Problem reported by Krzysztof Kotlenga <pocek@users.sf.net>.
+
+ * src/raster/raster.c (Vertical_Sweep_Drop, Horizontal_Sweep_Drop,
+ Horizontal_Gray_Sweep_Drop): For smart drop-out mode, if
+ intersections are equally distant relative to next pixel center,
+ select the left pixel, not the right one.
+
+2009-05-19 Werner Lemberg <wl@gnu.org>
+
+ Fix Savannah bug #26600.
+
+ * src/type42/t42parse.c (t42_load_keyword): Handle
+ T1_FIELD_LOCATION_FONT_EXTRA.
+
+2009-04-30 Werner Lemberg <wl@gnu.org>
+
+ Document recent changes to ftview.
+
+ * docs/CHANGES: Do it.
+
+2009-04-27 Werner Lemberg <wl@gnu.org>
+
+ autohinter: Don't change digit widths if all widths are the same.
+ This fixes FreeDesktop bug #21197.
+
+ * src/autofit/afglobal.c (AF_DIGIT): New macro.
+ (af_face_globals_compute_script_coverage): Mark ASCII digits in
+ `glyph_scripts' array.
+ (af_face_globals_get_metrics): Updated.
+ (af_face_globals_is_digit): New function.
+ * src/autofit/afglobal.h: Updated.
+ (AF_ScriptMetricsRec): Add `digits_have_same_width' flag.
+
+ * src/autofit/aflatin.c: Include FT_ADVANCES_H.
+ (af_latin_metrics_check_digits): New function.
+ (af_latin_metrics_init): Use it.
+ * src/autofit/aflatin.h: Updated.
+ * src/autofit/afcjk.c (af_cjk_metrics_init): Updated.
+
+ * src/autofit/aflatin2.c: Similar changes as with aflatin.c.
+
+ * src/autofit/afloader.c (af_loader_load_g): Test digit width.
+
+ * docs/CHANGES: Document it.
+
+2009-04-26 Werner Lemberg <wl@gnu.org>
+
+ Make ftgrays compile with _STANDALONE_ and FT_STATIC_RASTER again.
+ Problems reported by suyu@cooee.cn.
+
+ * src/smooth/ftgrays.c (FT_DEFINE_OUTLINE_FUNCS,
+ FT_DEFINE_RASTER_FUNCS) [_STANDALONE_]: Define.
+ [!_STANDALONE_]: Include ftspic.h only here.
+ (ras): Define/declare after definition of `TWorker'.
+ Use `RAS_VAR_' where necessary.
+
+2009-04-21 Karl Berry <karl@gnu.org>
+
+ Fix AC_CHECK_FT2.
+
+ * builds/unix/freetype2.m4: Only check PATH for freetype-config if
+ we did not already find it from a prefix option.
+
+2009-04-05 Oran Agra <oran@monfort.co.il>
+
+ Add #error to modules and files that do not support PIC yet.
+
+ When FT_CONFIG_OPTION_PIC is defined the following files will
+ create #error:
+ * src/bdf/bdfdrivr.h
+ * src/cache/ftcmanag.c
+ * src/cid/cidriver.h
+ * src/gxvalid/gxvmod.h
+ * src/gzip/ftgzip.c
+ * src/lzw/ftlzw.c
+ * src/otvalid/otvmod.h
+ * src/pcf/pcfdrivr.h
+ * src/pfr/pfrdrivr.h
+ * src/psaux/psauxmod.h
+ * src/type1/t1driver.h
+ * src/type42/t42drivr.h
+ * src/winfonts/winfnt.h
+
+2009-04-05 Oran Agra <oran@monfort.co.il>
+
+ Position Independent Code (PIC) support in autofit module.
+
+ * include/freetype/internal/autohint.h add macros to init
+ instances of FT_AutoHinter_ServiceRec.
+
+ * src/autofit/afmodule.h declare autofit_module_class
+ using macros from ftmodapi.h,
+ when FT_CONFIG_OPTION_PIC is defined create and destroy
+ functions will be declared.
+ * src/autofit/afmodule.c when FT_CONFIG_OPTION_PIC is defined
+ af_autofitter_service and autofit_module_class structs
+ will have functions to init or create and destroy them
+ instead of being allocated in the global scope.
+ And macros will be used from afpic.h in order to access them.
+
+ * src/autofit/aftypes.h add macros to init and declare
+ instances of AF_ScriptClassRec.
+
+ * src/autofit/afcjk.h declare af_cjk_script_class
+ using macros from aftypes.h,
+ when FT_CONFIG_OPTION_PIC is defined init function will be declared.
+ * src/autofit/afcjk.c when FT_CONFIG_OPTION_PIC is defined
+ af_cjk_script_class struct will have function to init it instead of
+ being allocated in the global scope.
+
+ * src/autofit/afdummy.h declare af_dummy_script_class
+ using macros from aftypes.h,
+ when FT_CONFIG_OPTION_PIC is defined init function will be declared.
+ * src/autofit/afdummy.c when FT_CONFIG_OPTION_PIC is defined
+ af_dummy_script_class struct will have function to init it instead of
+ being allocated in the global scope.
+
+ * src/autofit/afindic.h declare af_indic_script_class
+ using macros from aftypes.h,
+ when FT_CONFIG_OPTION_PIC is defined init function will be declared.
+ * src/autofit/afindic.c when FT_CONFIG_OPTION_PIC is defined
+ af_indic_script_class struct will have function to init it instead of
+ being allocated in the global scope.
+
+ * src/autofit/aflatin.h declare af_latin_script_class
+ using macros from aftypes.h,
+ when FT_CONFIG_OPTION_PIC is defined init function will be declared.
+ * src/autofit/aflatin.c when FT_CONFIG_OPTION_PIC is defined
+ af_latin_script_class struct will have function to init it instead of
+ being allocated in the global scope.
+ Change af_latin_blue_chars to be PIC-compatible by being a two
+ dimentional array rather than array of pointers.
+
+
+ * src/autofit/aflatin2.h declare af_latin2_script_class
+ using macros from aftypes.h,
+ when FT_CONFIG_OPTION_PIC is defined init function will be declared.
+ * src/autofit/aflatin2.c when FT_CONFIG_OPTION_PIC is defined
+ af_latin2_script_class struct will have function to init it instead of
+ being allocated in the global scope.
+ Change af_latin2_blue_chars to be PIC-compatible by being a two
+ dimentional array rather than array of pointers.
+
+ * src/autofit/afglobal.c when FT_CONFIG_OPTION_PIC is defined
+ af_script_classes array initialization was moved to afpic.c and
+ is later refered using macros defeined in afpic.h.
+
+ New Files:
+ * src/autofit/afpic.h declare struct to hold PIC globals for autofit
+ module and macros to access them.
+ * src/autofit/afpic.c implement functions to allocate, destroy and
+ initialize PIC globals for autofit module.
+
+ * src/autofit/autofit.c add new file to build: afpic.c.
+ * src/autofit/jamfile add new files to FT2_MULTI build: afpic.c.
+
+2009-04-05 Oran Agra <oran@monfort.co.il>
+
+ Position Independent Code (PIC) support in pshinter module.
+
+ * include/freetype/internal/pshints.h add macros to init
+ instances of PSHinter_Interface.
+
+ * src/pshinter/pshmod.h declare pshinter_module_class
+ using macros from ftmodapi.h,
+ when FT_CONFIG_OPTION_PIC is defined create and destroy
+ functions will be declared.
+ * src/pshinter/pshmod.c when FT_CONFIG_OPTION_PIC is defined
+ pshinter_interface and pshinter_module_class structs
+ will have functions to init or create and destroy them
+ instead of being allocated in the global scope.
+ And macros will be used from pshpic.h in order to access them.
+
+ New Files:
+ * src/pshinter/pshpic.h declare struct to hold PIC globals for pshinter
+ module and macros to access them.
+ * src/pshinter/pshpic.c implement functions to allocate, destroy and
+ initialize PIC globals for pshinter module.
+
+ * src/pshinter/pshinter.c add new file to build: pshpic.c.
+ * src/pshinter/jamfile add new files to FT2_MULTI build: pshpic.c.
+
+2009-04-05 Oran Agra <oran@monfort.co.il>
+
+ Position Independent Code (PIC) support in psnames module.
+
+ * include/freetype/internal/services/svpscmap.h add macros to init
+ instances of FT_Service_PsCMapsRec.
+
+ * src/psnames/psmodule.h declare psnames_module_class
+ using macros from ftmodapi.h,
+ when FT_CONFIG_OPTION_PIC is defined create and destroy
+ functions will be declared.
+ * src/psnames/psmodule.c when FT_CONFIG_OPTION_PIC is defined
+ pscmaps_interface and pscmaps_services structs
+ and psnames_module_class array
+ will have functions to init or create and destroy them
+ instead of being allocated in the global scope.
+ And macros will be used from pspic.h in order to access them.
+
+ New Files:
+ * src/psnames/pspic.h declare struct to hold PIC globals for psnames
+ module and macros to access them.
+ * src/psnames/pspic.c implement functions to allocate, destroy and
+ initialize PIC globals for psnames module.
+
+ * src/psnames/psnames.c add new file to build: pspic.c.
+ * src/psnames/jamfile add new files to FT2_MULTI build: pspic.c.
+
+2009-04-05 Oran Agra <oran@monfort.co.il>
+
+ Position Independent Code (PIC) support in raster renderer.
+
+ * src/raster/ftrend1.h declare ft_raster1_renderer_class
+ and ft_raster5_renderer_class
+ using macros from ftrender.h,
+ when FT_CONFIG_OPTION_PIC is defined create and destroy
+ functions will be declared.
+ * src/smooth/ftrend1.c when FT_CONFIG_OPTION_PIC is defined
+ ft_raster1_renderer_class and ft_raster5_renderer_class structs
+ will have functions to init or create and destroy them
+ instead of being allocated in the global scope.
+ Macros will be used from rastpic.h in order to access
+ ft_standard_raster from the pic_container (allocated in ftraster.c).
+ In ft_raster1_render when PIC is enabled, the last letter of
+ module_name is used to verfy the renderer class rather than the
+ class pointer.
+
+ * src/raster/ftraster.c when FT_CONFIG_OPTION_PIC is defined
+ ft_standard_raster struct will have function to init it
+ instead of being allocated in the global scope.
+
+ New Files:
+ * src/raster/rastpic.h declare struct to hold PIC globals for raster
+ renderer and macros to access them.
+ * src/raster/rastpic.c implement functions to allocate, destroy and
+ initialize PIC globals for raster renderer.
+
+ * src/raster/raster.c add new file to build: rastpic.c.
+ * src/raster/jamfile add new files to FT2_MULTI build: rastpic.c.
+
+2009-04-05 Oran Agra <oran@monfort.co.il>
+
+ Position Independent Code (PIC) support in smooth renderer.
+
+ * src/smooth/ftsmooth.h declare ft_smooth_renderer_class,
+ ft_smooth_lcd_renderer_class and ft_smooth_lcd_v_renderer_class
+ using macros from ftrender.h,
+ when FT_CONFIG_OPTION_PIC is defined create and destroy
+ functions will be declared.
+ * src/smooth/ftsmooth.c when FT_CONFIG_OPTION_PIC is defined
+ the following structs:
+ ft_smooth_renderer_class, ft_smooth_lcd_renderer_class
+ and ft_smooth_lcd_v_renderer_class
+ will have functions to init or create and destroy them
+ instead of being allocated in the global scope.
+ And macros will be used from ftspic.h in order to access
+ ft_grays_raster from the pic_container (allocated in ftgrays.c).
+
+ * src/smooth/ftgrays.h include FT_CONFIG_CONFIG_H
+ * src/smooth/ftgrays.c when FT_CONFIG_OPTION_PIC is NOT defined
+ func_interface was moved from gray_convert_glyph_inner function
+ to the global scope.
+ When FT_CONFIG_OPTION_PIC is defined
+ func_interface and ft_grays_raster structs
+ will have functions to init them
+ instead of being allocated in the global scope.
+ And func_interface will be allocated on the stack of
+ gray_convert_glyph_inner.
+
+ New Files:
+ * src/smooth/ftspic.h declare struct to hold PIC globals for smooth
+ renderer and macros to access them.
+ * src/smooth/ftspic.c implement functions to allocate, destroy and
+ initialize PIC globals for smooth renderer.
+
+ * src/smooth/smooth.c add new file to build: ftspic.c.
+ * src/smooth/jamfile add new files to FT2_MULTI build: ftspic.c.
+
+2009-04-05 Oran Agra <oran@monfort.co.il>
+
+ Position Independent Code (PIC) support in cff driver.
+
+ * include/freetype/internal/services/svcid.h add macros to init
+ instances of FT_Service_CIDRec.
+ * include/freetype/internal/services/svpsinfo.h add macros to init
+ instances of FT_Service_PsInfoRec.
+
+ * src/cff/cffcmap.h declare cff_cmap_encoding_class_rec
+ and cff_cmap_unicode_class_rec using macros from
+ ftobjs.h, when FT_CONFIG_OPTION_PIC is defined create and destroy
+ functions will be declared.
+ * src/cff/cffcmap.c when FT_CONFIG_OPTION_PIC is defined
+ the following structs:
+ cff_cmap_encoding_class_rec and cff_cmap_unicode_class_rec
+ will have functions to init or create and destroy them
+ instead of being allocated in the global scope.
+
+ * src/cff/cffdrivr.h declare cff_driver_class using macros from
+ ftdriver.h, when FT_CONFIG_OPTION_PIC is defined create and destroy
+ functions will be declared.
+ * src/cff/cffdrivr.c when FT_CONFIG_OPTION_PIC is defined
+ the following structs:
+ cff_service_glyph_dict, cff_service_ps_info, cff_service_ps_name
+ cff_service_get_cmap_info, cff_service_cid_info, cff_driver_class,
+ and cff_services array
+ will have functions to init or create and destroy them
+ instead of being allocated in the global scope.
+ And macros will be used from cffpic.h in order to access them
+ from the pic_container.
+ Use macros from cffpic.h in order to access the
+ structs allocated in cffcmap.c
+
+ * src/cff/cffobjs.c Use macros from cffpic.h in order to access the
+ structs allocated in cffcmap.c
+
+ * src/cff/parser.c when FT_CONFIG_OPTION_PIC is defined
+ implement functions to create and destroy cff_field_handlers array
+ instead of being allocated in the global scope.
+ And macros will be used from cffpic.h in order to access it
+ from the pic_container.
+
+ New Files:
+ * src/cff/cffpic.h declare struct to hold PIC globals for cff
+ driver and macros to access them.
+ * src/cff/cffpic.c implement functions to allocate, destroy and
+ initialize PIC globals for cff driver.
+
+ * src/cff/cff.c add new file to build: cffpic.c.
+ * src/cff/jamfile add new files to FT2_MULTI build: cffpic.c.
+
+2009-04-05 Oran Agra <oran@monfort.co.il>
+
+ Position Independent Code (PIC) support in sfnt driver.
+
+ * include/freetype/internal/services/svbdf.h add macros to init
+ instances of FT_Service_BDFRec.
+ * include/freetype/internal/services/svgldict.h add macros to init
+ instances of FT_Service_GlyphDictRec.
+ * include/freetype/internal/services/svpostnm.h add macros to init
+ instances of FT_Service_PsFontNameRec.
+ * include/freetype/internal/services/svsfnt.h add macros to init
+ instances of FT_Service_SFNT_TableRec.
+ * include/freetype/internal/services/svttcmap.h add macros to init
+ instances of FT_Service_TTCMapsRec.
+ * include/freetype/internal/sfnt.h add macros to init
+ instances of SFNT_Interface.
+
+ * src/sfnt/sfdriver.h declare sfnt_module_class using macros from
+ ftmodapi.h, when FT_CONFIG_OPTION_PIC is defined create and destroy
+ functions will be declared.
+ * src/sfnt/sfdriver.c when FT_CONFIG_OPTION_PIC is defined
+ the following structs:
+ sfnt_service_sfnt_table, sfnt_service_glyph_dict, sfnt_service_ps_name
+ tt_service_get_cmap_info, sfnt_service_bdf, sfnt_interface,
+ sfnt_module_class, and sfnt_services array
+ will have functions to init or create and destroy them
+ instead of being allocated in the global scope.
+ And macros will be used from sfntpic.h in order to access them
+ from the pic_container.
+
+ * src/sfnt/ttcmap.h add macros to init
+ instances of TT_CMap_ClassRec.
+ * src/sfnt/ttcmap.c when FT_CONFIG_OPTION_PIC is defined
+ the following structs:
+ tt_cmap0_class_rec, tt_cmap2_class_rec, tt_cmap4_class_rec
+ tt_cmap6_class_rec, tt_cmap8_class_rec, tt_cmap10_class_rec,
+ tt_cmap12_class_rec, tt_cmap14_class_rec and tt_cmap_classes array
+ will have functions to init or create and destroy them
+ instead of being allocated in the global scope.
+ And macros will be used from sfntpic.h in order to access them
+ from the pic_container.
+ The content of tt_cmap_classes is now described in the
+ new file 'ttcmapc.h'.
+
+ New Files:
+ * src/sfnt/sfntpic.h declare struct to hold PIC globals for sfnt
+ driver and macros to access them.
+ * src/sfnt/sfntpic.c implement functions to allocate, destroy and
+ initialize PIC globals for sfnt driver.
+ * src/sfnt/ttcmapc.h describing the content of
+ tt_cmap_classes allocated in ttcmap.c
+
+ * src/sfnt/sfnt.c add new file to build: sfntpic.c.
+ * src/sfnt/jamfile add new files to FT2_MULTI build: sfntpic.c.
+
+2009-04-05 Oran Agra <oran@monfort.co.il>
+
+ Position Independent Code (PIC) support in truetype driver.
+
+ * include/freetype/internal/services/svmm.h add macros to init
+ instances of FT_Service_MultiMastersRec.
+ * include/freetype/internal/services/svttglyf.h add macros to init
+ instances of FT_Service_TTGlyfRec.
+
+ * src/truetype/ttdriver.h declare tt_driver_class using macros from
+ ftdriver.h, when FT_CONFIG_OPTION_PIC is defined create and destroy
+ functions will be declared.
+ * src/truetype/ttdriver.c when FT_CONFIG_OPTION_PIC is defined
+ the following structs:
+ tt_service_gx_multi_masters, tt_service_truetype_glyf, tt_driver_class
+ and tt_services array,
+ will have functions to init or create and destroy them
+ instead of being allocated in the global scope.
+ And macros will be used from ttpic.h in order to access them
+ from the pic_container.
+ * src/truetype/ttobjs.c change trick_names array to be
+ PIC-compatible by being a two dimentional array rather than array
+ of pointers.
+
+ New Files:
+ * src/truetype/ttpic.h declare struct to hold PIC globals for truetype
+ driver and macros to access them.
+ * src/truetype/ttpic.c implement functions to allocate, destroy and
+ initialize PIC globals for truetype driver.
+
+ * src/truetype/truetype.c add new file to build: ttpic.c.
+ * src/truetype/jamfile add new files to FT2_MULTI build: ttpic.c.
+
+2009-04-05 Oran Agra <oran@monfort.co.il>
+
+ Position Independent Code (PIC) support and infrastructure in base.
+
+ * include/freetype/config/ftoption.h add FT_CONFIG_OPTION_PIC
+ * include/freetype/internal/ftobjs.h Add pic_container member to
+ FT_LibraryRec.
+ Add macros to declare and init instances of FT_CMap_ClassRec.
+ Add macros to init instances of FT_Outline_Funcs and FT_Raster_Funcs.
+ Add macros to declare, allocate and initialize modules
+ (FT_Module_Class).
+ Add macros to declare, allocate and initialize renderers
+ (FT_Renderer_Class).
+ Add macro to init instances of FT_Glyph_Class.
+ Add macros to declare, allocate and initialize drivers
+ (FT_Driver_ClassRec).
+ * include/freetype/internal/ftpic.h new file to declare the
+ FT_PIC_Container struct and the functions to allocate and detroy it.
+ * include/freetype/internal/ftserv.h add macros to allocate and
+ destory arrays of FT_ServiceDescRec.
+ * include/freetype/internal/internal.h define macro to include
+ ftpic.h.
+
+ New Files:
+ * src/base/ftpic.c implement functions to allocate and destory the
+ global pic_container.
+ * src/base/basepic.h declare struct to hold PIC globals for base and
+ macros to access them.
+ * src/base/basepic.c implement functions to allocate, destroy and
+ initialize PIC globals for base.
+
+ * src/base/ftinit.c when FT_CONFIG_OPTION_PIC is defined implement
+ functions that allocate and destroy ft_default_modules according to
+ FT_CONFIG_MODULES_H in the pic_container instead of the global scope
+ and use macro from basepic.h to access it.
+ * src/base/ftobjs.c add calls to the functions that allocate and
+ destroy the global pic_container when the library is created and
+ destroyed.
+
+ * src/base/jamfile add new files to FT2_MULTI build:
+ ftpic.c and basepic.c.
+ * src/base/ftbase.c add new files to build:
+ ftpic.c and basepic.c.
+
+ * src/base/ftglyph.c when FT_CONFIG_OPTION_PIC is defined
+ ft_bitmap_glyph_class and ft_outline_glyph_class will be allocated
+ in the pic_container instead of the global scope and use macros from
+ basepic.h to access them.
+ * src/base/ftbbox.c allocate bbox_interface stract on the stack
+ instead of the global scope when FT_CONFIG_OPTION_PIC is defined.
+ * src/base/ftstroke.c access ft_outline_glyph_class allocated in
+ ftglyph.c via macros from basepic.h
+
+2009-04-05 Oran Agra <oran@monfort.co.il>
+
+ Preparing changes in cff parser later needed for PIC version.
+
+ * src/cff/cffload.c, src/cff/cffload.h, src/cff/cffobjs.c,
+ src/cff/cffparse.c, src/cff/cffparse.h: Add library pointer to
+ 'CFF_ParserRec' set by `cff_parser_init'.
+ Route library pointer from 'cff_face_init' to 'cff_subfont_load'
+ for `cff_parser_init'.
+
+ * src/cff/cffparse.c (CFF_Field_Handler): Move it to...
+ * src/cff/cffparse.h: This file, to be used by other C files.
+
+2009-04-05 Oran Agra <oran@monfort.co.il>
+
+ Minor change in ftstroke.c.
+
+ * src/base/ftstroke.c (FT_StrokerRec): Replace `memory' member with
+ `library' needed for PIC version.
+ Update all callers.
+
+2009-04-04 Werner Lemberg <wl@gnu.org>
+
+ ftnames.c -> ftsnames.c
+
+ * src/base/ftnames.c: Rename to...
+ * src/base/ftsnames.c: This.
+ * src/base/Jamfile, src/base/rules.mk, src/base/ftbase.c: Updated.
+
+2009-04-04 Werner Lemberg <wl@gnu.org>
+
+ Add support for cmap type 13.
+
+ * devel/ftoption.h, include/freetype/config/ftoption.h
+ (TT_CONFIG_CMAP_FORMAT_13): New macro.
+
+ * src/sfnt/ttcmap.c (TT_CMap13Rec, tt_cmap13_init,
+ tt_cmap13_validate, tt_cmap13_char_index, tt_cmap13_char_next,
+ tt_cmap13_get_info, tt_cmap13_char_map_def_binary,
+ tt_cmap14_class_rec): New functions and structures for cmap 13
+ support.
+ (tt_cmap_classes): Register tt_cmap13_class_rec.
+
+ * docs/CHANGES: Mention cmap 13 support.
+
+2009-04-01 Werner Lemberg <wl@gnu.org>
+
+ Ignore empty contours in CFF glyphs.
+
+ Problem reported by Albert Astals Cid <aacid@kde.org>.
+
+ * src/cff/cffgload.c (cff_builder_close_contour): Synchronize with
+ t1_builder_close_contour.
+
+2009-03-21 Werner Lemberg <wl@gnu.org>
+
+ Another redundant header inclusion.
+
+ * src/truetype/ttgxvar.c: Fix Ghostscript Coverity issue #4041.
+
+2009-03-21 Werner Lemberg <wl@gnu.org>
+
+ Remove redundant header inclusions.
+
+ This covers many Ghostscript Coverity issues.
+
+ * src/*: Do it.
+
+2009-03-21 Werner Lemberg <wl@gnu.org>
+
+ Fix Ghostscript Coverity issue #3904.
+
+ * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Protect against
+ invalid values of `runcnt'.
+
+2009-03-20 Werner Lemberg <wl@gnu.org>
+
+ Fix `make multi' run.
+
+ * src/smooth/ftsmooth.h: Include FT_INTERNAL_DEBUG_H.
+
+2009-03-20 Werner Lemberg <wl@gnu.org>
+
+ Fix Savannah bug #25923.
+
+ * src/cache/ftccmap.c (FTC_CMAP_HASH): Fix typo.
+
+2009-03-20 Werner Lemberg <wl@gnu.org>
+
+ Protect against too large glyphs.
+
+ Problem reported by Tavis Ormandy <taviso@google.com>.
+
+ * src/smooth/ftsmooth.c (ft_smooth_render_generic): Don't allow
+ `pitch' or `height' to be larger than 0xFFFF.
+
+2009-03-20 Werner Lemberg <wl@gnu.org>
+ Tavis Ormandy <taviso@google.com>
+
+ Fix validation for various cmap table formats.
+
+ * src/sfnt/ttcmap.c (tt_cmap8_validate, tt_cmap10_validate,
+ tt_cmap12_validate): Check `length' correctly.
+ (tt_cmap_14_validate): Check `length' and `numMappings' correctly.
+
+2009-03-20 Werner Lemberg <wl@gnu.org>
+
+ Protect against malformed compressed data.
+
+ * src/lzw/ftzopen.c (ft_lzwstate_io): Test whether `state->prefix' is
+ zero.
+
+2009-03-20 Werner Lemberg <wl@gnu.org>
+
+ Protect against invalid SID values in CFFs.
+
+ Problem reported by Tavis Ormandy <taviso@google.com>.
+
+ * src/cff/cffload.c (cff_charset_load): Reject SID values larger
+ than 64999.
+
+2009-03-19 Vincent Richomme <richom.v@free.fr>
+
+ Update WinCE Visual C project files.
+
+ * builds/wince/vc2005-ce/freetype.vcproj,
+ builds/wince/vc2008-ce/freetype.vcproj: Add missing base extension
+ files.
+
+2009-03-19 Werner Lemberg <wl@gnu.org>
+
+ Remove unused Win32 code.
+
+ * builds/wince/ftdebug.c: Remove code guarded with `!_WIN32_WCE'.
+ Since Win32 is handled separately this is no longer needed.
+
+2009-03-19 Vincent Richomme <richom.v@free.fr>
+
+ Make `gzip' module compile on WinCE.
+
+ * src/gzip/zconf.h [_WIN32_WCE]: Define NO_ERRNO_H.
+
+2009-03-19 Werner Lemberg <wl@gnu.org>
+
+ Remove unused WinCE code.
+
+ * builds/win32/ftdebug.c: Remove code guarded with `_WIN32_WCE'.
+ Since WinCE is handled separately this is no longer needed.
+
+2009-03-16 Werner Lemberg <wl@gnu.org>
+
+ docmaker: Don't ignore single-line code blocks.
+
+ * src/tools/docmaker/content.py (DocBlock::_init__): Fix change from
+ 2009-01-31.
+
+2009-03-15 Steve Langasek <steve.langasek@canonical.com>
+
+ Use __asm__ for declaring assembly instead of asm.
+
+ * builds/unix/ftconfig.in (FT_MulFix_arm): Use __asm__ instead of
+ asm on arm, fixing a build failure on armel with -pedantic.
+
+2009-03-14 Werner Lemberg <wl@gnu.org>
+
+ Fix valgrind warning.
+
+ * src/sfnt/ttsbit0.c (tt_sbit_decoder_load_bit_aligned): Don't read
+ past the end of the frame.
+
2009-03-12 Werner Lemberg <wl@gnu.org>
* Version 2.3.9 released.
@@ -192,7 +3184,7 @@
Remove ABI-breaking field in public PS_InfoFontRec definition.
Instead, we define a new internal PS_FontExtraRec structure to
- hold the additionnal field, then place it in various internal
+ hold the additional field, then place it in various internal
positions of the corresponding FT_Face derived objects.
* include/freetype/t1tables.h (PS_FontInfoRec): Remove the
@@ -3908,8 +6900,8 @@
2006-12-08 Vladimir Volovich <vvv@vsu.ru>
- * src/tools/apinames (State): Remove final comma in structure -- xlc
- v5 under AIX 4.3 doesn't like this.
+ * src/tools/apinames.c (State): Remove final comma in structure --
+ xlc v5 under AIX 4.3 doesn't like this.
2006-12-07 David Turner <david@freetype.org>
@@ -4532,7 +7524,7 @@
`ft_validator_run' wrapping `setjmp' can cause a crash, as found by
Jens:
- http://lists.nongnu.org/archive/html/freetype-devel/2006-08/msg00004.htm.
+ http://lists.gnu.org/archive/html/freetype-devel/2006-08/msg00004.htm.
* src/otvalid/otvmod.c: Replace `ft_validator_run' by `ft_setjmp'.
It reverts the change introduced on 2005-08-20.
@@ -4729,7 +7721,7 @@
2006-06-24 Eugeniy Meshcheryakov <eugen@univ.kiev.ua>
Fix two hinting bugs as reported in
- http://lists.nongnu.org/archive/html/freetype-devel/2006-06/msg00057.html.
+ http://lists.gnu.org/archive/html/freetype-devel/2006-06/msg00057.html.
* include/freetype/internal/tttypes.h (TT_GlyphZoneRec): Add
`first_point' member.
@@ -4940,7 +7932,7 @@
----------------------------------------------------------------------------
-Copyright 2006, 2007, 2008, 2009 by
+Copyright 2006, 2007, 2008, 2009, 2010 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used, modified,
diff --git a/src/3rdparty/freetype/Jamfile b/src/3rdparty/freetype/Jamfile
index e5273d80bb..d8c1bbada2 100644
--- a/src/3rdparty/freetype/Jamfile
+++ b/src/3rdparty/freetype/Jamfile
@@ -194,7 +194,7 @@ rule RefDoc
actions RefDoc
{
- python $(FT2_SRC)/tools/docmaker/docmaker.py --prefix=ft2 --title=FreeType-2.3.9 --output=$(DOC_DIR) $(FT2_INCLUDE)/freetype/*.h $(FT2_INCLUDE)/freetype/config/*.h
+ python $(FT2_SRC)/tools/docmaker/docmaker.py --prefix=ft2 --title=FreeType-2.3.12 --output=$(DOC_DIR) $(FT2_INCLUDE)/freetype/*.h $(FT2_INCLUDE)/freetype/config/*.h
}
RefDoc refdoc ;
diff --git a/src/3rdparty/freetype/README b/src/3rdparty/freetype/README
index 6e5ad46b13..282791ef08 100644
--- a/src/3rdparty/freetype/README
+++ b/src/3rdparty/freetype/README
@@ -9,8 +9,8 @@
is called `libttf'. They are *not* compatible!
- FreeType 2.3.9
- ==============
+ FreeType 2.3.12
+ ===============
Please read the docs/CHANGES file, it contains IMPORTANT
INFORMATION.
@@ -26,9 +26,9 @@
and download one of the following files.
- freetype-doc-2.3.9.tar.bz2
- freetype-doc-2.3.9.tar.gz
- ftdoc239.zip
+ freetype-doc-2.3.12.tar.bz2
+ freetype-doc-2.3.12.tar.gz
+ ftdoc2312.zip
Bugs
@@ -51,7 +51,7 @@
----------------------------------------------------------------------
-Copyright 2006, 2007, 2008, 2009 by
+Copyright 2006, 2007, 2008, 2009, 2010 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used,
diff --git a/src/3rdparty/freetype/README.CVS b/src/3rdparty/freetype/README.git
index ff1a2d0580..89f290706c 100644
--- a/src/3rdparty/freetype/README.CVS
+++ b/src/3rdparty/freetype/README.git
@@ -1,4 +1,4 @@
-The CVS archive doesn't contain pre-built configuration scripts for
+The git archive doesn't contain pre-built configuration scripts for
UNIXish platforms. To generate them say
sh autogen.sh
@@ -33,7 +33,7 @@ should work on all platforms which have GNU make (or makepp).
----------------------------------------------------------------------
-Copyright 2005, 2006, 2007, 2008 by
+Copyright 2005, 2006, 2007, 2008, 2009 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used,
diff --git a/src/3rdparty/freetype/autogen.sh b/src/3rdparty/freetype/autogen.sh
index 16c335fd5c..c28a51c132 100644
--- a/src/3rdparty/freetype/autogen.sh
+++ b/src/3rdparty/freetype/autogen.sh
@@ -1,6 +1,6 @@
#!/bin/sh
-# Copyright 2005, 2006, 2007, 2008, 2009 by
+# Copyright 2005, 2006, 2007, 2008, 2009, 2010 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -95,10 +95,11 @@ compare_to_minimum_version ()
check_tool_version ()
{
field=$5
+ # assume the output of "[TOOL] --version" is "toolname (GNU toolname foo bar) version"
if test "$field"x = x; then
- field=4 # default to 4 for all GNU autotools
+ field=3 # default to 3 for all GNU autotools, after filtering enclosed string
fi
- version=`$1 --version | head -1 | cut -d ' ' -f $field`
+ version=`$1 --version | head -1 | sed 's/([^)]*)/()/g' | cut -d ' ' -f $field`
version_check=`compare_to_minimum_version $version $4`
if test "$version_check"x = 0x; then
echo "ERROR: Your version of the \`$2' tool is too old."
diff --git a/src/3rdparty/freetype/builds/atari/ATARI.H b/src/3rdparty/freetype/builds/atari/ATARI.H
index bb6913803c..9f78c924b8 100644
--- a/src/3rdparty/freetype/builds/atari/ATARI.H
+++ b/src/3rdparty/freetype/builds/atari/ATARI.H
@@ -1,3 +1,7 @@
+#if defined( __GXVALID_H__ )
+#pragma warn -aus /* too many unevaluated variables in gxvalid */
+#endif
+
#ifndef ATARI_H
#define ATARI_H
diff --git a/src/3rdparty/freetype/builds/atari/deflinejoiner.awk b/src/3rdparty/freetype/builds/atari/deflinejoiner.awk
new file mode 100644
index 0000000000..c872a70d86
--- /dev/null
+++ b/src/3rdparty/freetype/builds/atari/deflinejoiner.awk
@@ -0,0 +1,181 @@
+#!/usr/bin/env awk
+
+
+function shift( array, \
+ junk, elm0, l )
+{
+ elm0 = array[0]
+ for ( l = 0; l < asorti( array, junk ) - 1; l++ )
+ array[l] = array[l+1];
+ delete array[l]
+ return elm0
+}
+
+
+function init_cpp_src_line()
+{
+ logical_line = ""
+ delete break_pos
+}
+
+
+function shift_valid_bp( array, \
+ junk, elm )
+{
+ elm = -1
+
+ if ( 0 < asorti( array, junk ) )
+ do {
+ elm = shift( array )
+ } while ( 0 > elm );
+
+ return elm
+}
+
+
+function check_cpp_src_line_break_pos( \
+ i, junk )
+{
+ printf( "break_pos:" )
+ for ( i = 0; i < asorti( break_pos, junk ); i++ )
+ printf( " %d", break_pos[i] );
+ printf( "\n" )
+}
+
+
+function check_cpp_src_line()
+{
+ printf( "logical_line[%s]\n", logical_line )
+ check_cpp_src_line_break_pos()
+}
+
+
+function append_line( phys_line, \
+ filt_line, bp_len )
+{
+ filt_line = phys_line
+ sub( /\\$/, " ", filt_line )
+ logical_line = logical_line filt_line
+ bp_len = asorti( break_pos, junk )
+ break_pos[bp_len] = length( logical_line ) - 1
+}
+
+
+function print_line( \
+ c0, c1, i, junk, part_str )
+{
+ c0 = 0
+
+ while( asorti( break_pos, junk ) > 1 )
+ {
+ if ( ( c1 = shift_valid_bp( break_pos ) ) < 1 )
+ {
+ part_str = substr( logical_line, c0 + 1 )
+ printf( "%s\n", part_str )
+ return
+ }
+
+ part_str = substr( logical_line, c0 + 1, c1 - c0 + 1 )
+ gsub( / $/, "\\", part_str )
+ printf( "%s\n", part_str )
+ c0 = c1 + 1
+ }
+
+ part_str = substr( logical_line, c0 + 1 )
+ printf( "%s\n", part_str )
+}
+
+
+function shrink_spaces( pos, \
+ tail, removed_length, k )
+{
+ tail = substr( logical_line, pos )
+ sub( /^[ \t]+/, " ", tail )
+ removed_length = length( logical_line ) - pos - length( tail ) + 1
+ logical_line = substr( logical_line, 0, pos - 1 ) tail
+
+
+ for ( k = 0; k < asorti( break_pos, junk ); k++ )
+ if ( ( pos + removed_length ) <= break_pos[k] )
+ break_pos[k] = break_pos[k] - removed_length;
+ else if ( pos <= break_pos[k] )
+ break_pos[k] = -1;
+
+ return removed_length
+}
+
+
+function shrink_spaces_to_linebreak( pos, \
+ junk, part_str, removed_length, i )
+{
+ for ( i = 0; i < asorti( break_pos, junk ) && break_pos[i] < pos ; i++ )
+ ;
+
+ if ( break_pos[i] < 1 )
+ return;
+
+ part_str = substr( logical_line, pos, break_pos[i] - pos + 1 )
+ sub( /^[ \t]+/, " ", part_str )
+ removed_length = ( break_pos[i] - pos + 1 ) - length( part_str )
+
+ tail = substr( logical_line, pos + removed_length )
+ logical_line = substr( logical_line, 0, pos - 1 ) tail
+
+ for ( ; i < asorti( break_pos, junk ); i++ )
+ break_pos[i] -= removed_length;
+
+ return removed_length
+}
+
+
+function delete_linebreaks_in_2nd_token( \
+ tail, paren_depth, junk, i, j, k, l )
+{
+ if ( logical_line ~ /^[ \t]*#[ \t]*define[ \t]+[0-9A-Za-z_]+\(/ )
+ {
+ tail = logical_line
+ sub( /^[ \t]*#[ \t]*define[ \t]+[0-9A-Za-z_]+/, "", tail )
+
+ paren_depth = 0
+ l = 0
+ i = length( logical_line ) - length( tail ) + 1 # seek to the 1st op paren
+ j = i
+ do {
+ if ( substr( logical_line, j, 2 ) ~ /[ \t][ \t]/ )
+ l = shrink_spaces( j );
+ else if ( substr( logical_line, j, 1 ) == "(" )
+ paren_depth += 1;
+ else if ( substr( logical_line, j, 1 ) == ")" )
+ paren_depth -= 1;
+ j += 1
+ } while ( j < length( logical_line ) && paren_depth != 0 )
+
+ for ( k = 0; k < asorti( break_pos, junk ); k++ )
+ if ( i <= break_pos[k] && break_pos[k] < j )
+ break_pos[k] = -1;
+
+ if ( l > 0 )
+ shrink_spaces_to_linebreak( j );
+ }
+}
+
+
+BEGIN{
+ init_cpp_src_line()
+}
+{
+ append_line( $0 )
+ if ( $0 !~ /\\$/ )
+ {
+ delete_linebreaks_in_2nd_token()
+ print_line()
+ init_cpp_src_line()
+ }
+}
+END{
+ if ( 0 < length( logical_line ) )
+ {
+ delete_linebreaks_in_2nd_token()
+ print_line()
+ }
+}
diff --git a/src/3rdparty/freetype/builds/atari/gen-purec-patch.sh b/src/3rdparty/freetype/builds/atari/gen-purec-patch.sh
new file mode 100644
index 0000000000..1ec050c11f
--- /dev/null
+++ b/src/3rdparty/freetype/builds/atari/gen-purec-patch.sh
@@ -0,0 +1,40 @@
+#!/bin/sh
+
+TOP_DIR=.
+OBJ_DIR=.
+
+for x in "$@"
+do
+ case x"$x" in
+ x--srcdir=* | x--topdir=* )
+ TOP_DIR=`echo $x | sed 's/^--[a-z]*dir=//'`
+ ;;
+ x--builddir=* | x--objdir=* )
+ OBJ_DIR=`echo $x | sed 's/^--[a-z]*dir=//'`
+ ;;
+ esac
+done
+
+mkdir -p ${OBJ_DIR}/builds/atari/tmp/orig
+
+( cd ${TOP_DIR} && find . -name '*.[CHch]' -type f | fgrep -v builds/atari/tmp | cpio -o ) | \
+( cd ${OBJ_DIR}/builds/atari/tmp/orig && cpio -idum )
+cp ${TOP_DIR}/builds/atari/deflinejoiner.awk ${OBJ_DIR}/builds/atari/tmp
+
+pushd ${OBJ_DIR}/builds/atari/tmp
+
+ cp -pr orig purec
+ for f in `cd orig && find . -type f`
+ do
+ echo filter $f
+ env LANG=C awk -f deflinejoiner.awk < orig/$f > purec/$f
+ done
+
+ echo '#define FT2_BUILD_LIBRARY' > purec/include/ft2build.h
+ echo '#include "ATARI.H"' >> purec/include/ft2build.h
+ env LANG=C awk -f deflinejoiner.awk < orig/include/ft2build.h >> purec/include/ft2build.h
+
+ env LANG=C diff -ur orig purec > ../purec.diff
+
+popd
+rm -rf ${OBJ_DIR}/builds/atari/tmp
diff --git a/src/3rdparty/freetype/builds/compiler/bcc-dev.mk b/src/3rdparty/freetype/builds/compiler/bcc-dev.mk
index ba1a88a302..63a46ad168 100644
--- a/src/3rdparty/freetype/builds/compiler/bcc-dev.mk
+++ b/src/3rdparty/freetype/builds/compiler/bcc-dev.mk
@@ -52,7 +52,8 @@ L :=
# Target flag -- no trailing space.
#
-T := -o
+T := -o
+TE := -e
# C flags
@@ -72,7 +73,14 @@ ANSIFLAGS := -A
# Library linking
#
CLEAN_LIBRARY ?= $(DELETE) $(subst /,$(SEP),$(PROJECT_LIBRARY))
-LINK_LIBRARY = tlib /u $(subst /,$(COMPILER_SEP),$@ $(OBJECTS_LIST:%=+%))
+LINK_LIBRARY = tlib /u /P128 $(subst /,$(COMPILER_SEP),$@ $(OBJECTS_LIST:%=+%))
+
+
+# Borland C++ specific temporary files
+#
+CLEAN += \
+ $(subst /,$(SEP),$(TOP_DIR)/apinames.$(O)) \
+ $(subst /,$(SEP),$(OBJ_DIR)/apinames.tds)
# EOF
diff --git a/src/3rdparty/freetype/builds/compiler/bcc.mk b/src/3rdparty/freetype/builds/compiler/bcc.mk
index 509cb72483..855edadf0a 100644
--- a/src/3rdparty/freetype/builds/compiler/bcc.mk
+++ b/src/3rdparty/freetype/builds/compiler/bcc.mk
@@ -52,7 +52,8 @@ L :=
# Target flag -- no trailing space.
#
-T := -o
+T := -o
+TE := -e
# C flags
@@ -72,7 +73,14 @@ ANSIFLAGS := -A
# Library linking
#
CLEAN_LIBRARY ?= $(DELETE) $(subst /,$(SEP),$(PROJECT_LIBRARY))
-LINK_LIBRARY = tlib /u $(subst /,$(COMPILER_SEP),$@ $(OBJECTS_LIST:%=+%))
+LINK_LIBRARY = tlib /u /P128 $(subst /,$(COMPILER_SEP),$@ $(OBJECTS_LIST:%=+%))
+
+
+# Borland C++ specific temporary files
+#
+CLEAN += \
+ $(subst /,$(SEP),$(TOP_DIR)/apinames.$(O)) \
+ $(subst /,$(SEP),$(OBJ_DIR)/apinames.tds)
# EOF
diff --git a/src/3rdparty/freetype/builds/compiler/gcc.mk b/src/3rdparty/freetype/builds/compiler/gcc.mk
index e941443a02..f6b7101b38 100644
--- a/src/3rdparty/freetype/builds/compiler/gcc.mk
+++ b/src/3rdparty/freetype/builds/compiler/gcc.mk
@@ -3,7 +3,7 @@
#
-# Copyright 1996-2000, 2003, 2005, 2006 by
+# Copyright 1996-2000, 2003, 2005, 2006, 2009 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -61,7 +61,7 @@ T := -o$(space)
# Use the ANSIFLAGS variable to define the compiler flags used to enfore
# ANSI compliance.
#
-CFLAGS ?= -c -g -O6 -Wall
+CFLAGS ?= -c -g -O3 -Wall
# ANSIFLAGS: Put there the flags used to make your compiler ANSI-compliant.
#
diff --git a/src/3rdparty/freetype/builds/exports.mk b/src/3rdparty/freetype/builds/exports.mk
index 5452b35715..52f2912d39 100644
--- a/src/3rdparty/freetype/builds/exports.mk
+++ b/src/3rdparty/freetype/builds/exports.mk
@@ -47,8 +47,8 @@ ifneq ($(EXPORTS_LIST),)
#
# Note that $(APINAMES_OPTIONS) is empty, except for Windows compilers.
#
- APINAMES_SRC := $(TOP_DIR)/src/tools/apinames.c
- APINAMES_EXE := $(OBJ_DIR)/apinames$(E_BUILD)
+ APINAMES_SRC := $(subst /,$(SEP),$(TOP_DIR)/src/tools/apinames.c)
+ APINAMES_EXE := $(subst /,$(SEP),$(OBJ_DIR)/apinames$(E_BUILD))
$(APINAMES_EXE): $(APINAMES_SRC)
$(CCexe) $(TE)$@ $<
diff --git a/src/3rdparty/freetype/builds/mac/README b/src/3rdparty/freetype/builds/mac/README
index 3bedfcac32..bd3df8ada4 100644
--- a/src/3rdparty/freetype/builds/mac/README
+++ b/src/3rdparty/freetype/builds/mac/README
@@ -99,7 +99,7 @@ environment by Metrowerks. GCC for MPW and Symantec
System 7, MacOS 8, MacOS 9. So-called "Toolbox"
API is used.
- - FreeType.ppc_classic.make.txt
+ - FreeType.ppc_carbon.make.txt
CFM binary executable format for ppc MacOS:
MacOS 9. Carbon API is used.
@@ -392,7 +392,7 @@ ATSFontGetFileSpecification() | x | x | x | x |
ATS font manager is not published in these versions.
------------------------------------------------------------
-Last update: 2007-Feb-01, by Alexei Podtelezhnikov.
+Last update: 2009-Jul-25.
Currently maintained by
suzuki toshiya, <mpsuzuki@hiroshima-u.ac.jp>
diff --git a/src/3rdparty/freetype/builds/toplevel.mk b/src/3rdparty/freetype/builds/toplevel.mk
index e6a8e932f7..6a8280173d 100644
--- a/src/3rdparty/freetype/builds/toplevel.mk
+++ b/src/3rdparty/freetype/builds/toplevel.mk
@@ -177,9 +177,9 @@ include $(TOP_DIR)/builds/modules.mk
ifneq ($(findstring distx,$(MAKECMDGOALS)x),)
FT_H := include/freetype/freetype.h
- major := $(shell sed -n 's/.*FREETYPE_MAJOR.*\([0-9]\+\)/\1/p' < $(FT_H))
- minor := $(shell sed -n 's/.*FREETYPE_MINOR.*\([0-9]\+\)/\1/p' < $(FT_H))
- patch := $(shell sed -n 's/.*FREETYPE_PATCH.*\([0-9]\+\)/\1/p' < $(FT_H))
+ major := $(shell sed -n 's/.*FREETYPE_MAJOR[^0-9]*\([0-9]\+\)/\1/p' < $(FT_H))
+ minor := $(shell sed -n 's/.*FREETYPE_MINOR[^0-9]*\([0-9]\+\)/\1/p' < $(FT_H))
+ patch := $(shell sed -n 's/.*FREETYPE_PATCH[^0-9]*\([0-9]\+\)/\1/p' < $(FT_H))
version := $(major).$(minor).$(patch)
winversion := $(major)$(minor)$(patch)
@@ -191,14 +191,14 @@ dist:
rm -f freetype-$(version).tar.bz2
rm -f ft$(winversion).zip
- for d in `find . -wholename '*/CVS' -prune \
+ for d in `find . -wholename '*/.git' -prune \
-o -type f \
-o -print` ; do \
mkdir -p tmp/$$d ; \
done ;
currdir=`pwd` ; \
- for f in `find . -wholename '*/CVS' -prune \
+ for f in `find . -wholename '*/.git' -prune \
-o -name .cvsignore \
-o -type d \
-o -print` ; do \
diff --git a/src/3rdparty/freetype/builds/unix/aclocal.m4 b/src/3rdparty/freetype/builds/unix/aclocal.m4
index 36a524230e..492a669ecc 100644
--- a/src/3rdparty/freetype/builds/unix/aclocal.m4
+++ b/src/3rdparty/freetype/builds/unix/aclocal.m4
@@ -1,7 +1,7 @@
-# generated automatically by aclocal 1.10.1 -*- Autoconf -*-
+# generated automatically by aclocal 1.11.1 -*- Autoconf -*-
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-# 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+# 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
# This file is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@@ -691,7 +691,6 @@ _LT_CONFIG_SAVE_COMMANDS([
# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
-# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
#
_LT_COPYING
@@ -7851,15 +7850,15 @@ m4_define([lt_dict_filter],
# Generated from ltversion.in.
-# serial 3012 ltversion.m4
+# serial 3017 ltversion.m4
# This file is part of GNU Libtool
-m4_define([LT_PACKAGE_VERSION], [2.2.6])
-m4_define([LT_PACKAGE_REVISION], [1.3012])
+m4_define([LT_PACKAGE_VERSION], [2.2.6b])
+m4_define([LT_PACKAGE_REVISION], [1.3017])
AC_DEFUN([LTVERSION_VERSION],
-[macro_version='2.2.6'
-macro_revision='1.3012'
+[macro_version='2.2.6b'
+macro_revision='1.3017'
_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
_LT_DECL(, macro_revision, 0)
])
diff --git a/src/3rdparty/freetype/builds/unix/config.guess b/src/3rdparty/freetype/builds/unix/config.guess
index e5716eea73..c2246a4f7f 100755
--- a/src/3rdparty/freetype/builds/unix/config.guess
+++ b/src/3rdparty/freetype/builds/unix/config.guess
@@ -1,10 +1,10 @@
#! /bin/sh
# Attempt to guess a canonical system name.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
+# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
# Free Software Foundation, Inc.
-timestamp='2009-02-03'
+timestamp='2009-12-30'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -27,16 +27,16 @@ timestamp='2009-02-03'
# the same distribution terms that you use for the rest of that program.
-# Originally written by Per Bothner <per@bothner.com>.
-# Please send patches to <config-patches@gnu.org>. Submit a context
-# diff and a properly formatted ChangeLog entry.
+# Originally written by Per Bothner. Please send patches (context
+# diff format) to <config-patches@gnu.org> and include a ChangeLog
+# entry.
#
# This script attempts to guess a canonical system name similar to
# config.sub. If it succeeds, it prints the system name on stdout, and
# exits with 0. Otherwise, it exits with 1.
#
-# The plan is that this can be called by configure scripts if you
-# don't specify an explicit build system type.
+# You can get the latest version of this script from:
+# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
me=`echo "$0" | sed -e 's,.*/,,'`
@@ -56,8 +56,9 @@ version="\
GNU config.guess ($timestamp)
Originally written by Per Bothner.
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
-2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
+2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free
+Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -170,7 +171,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
arm*|i386|m68k|ns32k|sh3*|sparc|vax)
eval $set_cc_for_build
if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
- | grep __ELF__ >/dev/null
+ | grep -q __ELF__
then
# Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout).
# Return netbsd for either. FIX?
@@ -324,12 +325,18 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
case `/usr/bin/uname -p` in
sparc) echo sparc-icl-nx7; exit ;;
esac ;;
+ s390x:SunOS:*:*)
+ echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
+ exit ;;
sun4H:SunOS:5.*:*)
echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit ;;
sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit ;;
+ i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
+ echo i386-pc-auroraux${UNAME_RELEASE}
+ exit ;;
i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
eval $set_cc_for_build
SUN_ARCH="i386"
@@ -653,7 +660,7 @@ EOF
# => hppa64-hp-hpux11.23
if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) |
- grep __LP64__ >/dev/null
+ grep -q __LP64__
then
HP_ARCH="hppa2.0w"
else
@@ -804,12 +811,12 @@ EOF
i*:PW*:*)
echo ${UNAME_MACHINE}-pc-pw32
exit ;;
- *:Interix*:[3456]*)
+ *:Interix*:*)
case ${UNAME_MACHINE} in
x86)
echo i586-pc-interix${UNAME_RELEASE}
exit ;;
- EM64T | authenticamd | genuineintel)
+ authenticamd | genuineintel | EM64T)
echo x86_64-unknown-interix${UNAME_RELEASE}
exit ;;
IA64)
@@ -819,6 +826,9 @@ EOF
[345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
echo i${UNAME_MACHINE}-pc-mks
exit ;;
+ 8664:Windows_NT:*)
+ echo x86_64-pc-mks
+ exit ;;
i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
# How do we know it's Interix rather than the generic POSIX subsystem?
# It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
@@ -848,6 +858,20 @@ EOF
i*86:Minix:*:*)
echo ${UNAME_MACHINE}-pc-minix
exit ;;
+ alpha:Linux:*:*)
+ case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
+ EV5) UNAME_MACHINE=alphaev5 ;;
+ EV56) UNAME_MACHINE=alphaev56 ;;
+ PCA56) UNAME_MACHINE=alphapca56 ;;
+ PCA57) UNAME_MACHINE=alphapca56 ;;
+ EV6) UNAME_MACHINE=alphaev6 ;;
+ EV67) UNAME_MACHINE=alphaev67 ;;
+ EV68*) UNAME_MACHINE=alphaev68 ;;
+ esac
+ objdump --private-headers /bin/sh | grep -q ld.so.1
+ if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
+ echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
+ exit ;;
arm*:Linux:*:*)
eval $set_cc_for_build
if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
@@ -870,6 +894,17 @@ EOF
frv:Linux:*:*)
echo frv-unknown-linux-gnu
exit ;;
+ i*86:Linux:*:*)
+ LIBC=gnu
+ eval $set_cc_for_build
+ sed 's/^ //' << EOF >$dummy.c
+ #ifdef __dietlibc__
+ LIBC=dietlibc
+ #endif
+EOF
+ eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'`
+ echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
+ exit ;;
ia64:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
@@ -879,78 +914,34 @@ EOF
m68*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
- mips:Linux:*:*)
- eval $set_cc_for_build
- sed 's/^ //' << EOF >$dummy.c
- #undef CPU
- #undef mips
- #undef mipsel
- #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
- CPU=mipsel
- #else
- #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
- CPU=mips
- #else
- CPU=
- #endif
- #endif
-EOF
- eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
- /^CPU/{
- s: ::g
- p
- }'`"
- test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
- ;;
- mips64:Linux:*:*)
+ mips:Linux:*:* | mips64:Linux:*:*)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
#undef CPU
- #undef mips64
- #undef mips64el
+ #undef ${UNAME_MACHINE}
+ #undef ${UNAME_MACHINE}el
#if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
- CPU=mips64el
+ CPU=${UNAME_MACHINE}el
#else
#if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
- CPU=mips64
+ CPU=${UNAME_MACHINE}
#else
CPU=
#endif
#endif
EOF
- eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
- /^CPU/{
- s: ::g
- p
- }'`"
+ eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
;;
or32:Linux:*:*)
echo or32-unknown-linux-gnu
exit ;;
- ppc:Linux:*:*)
- echo powerpc-unknown-linux-gnu
- exit ;;
- ppc64:Linux:*:*)
- echo powerpc64-unknown-linux-gnu
- exit ;;
- alpha:Linux:*:*)
- case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
- EV5) UNAME_MACHINE=alphaev5 ;;
- EV56) UNAME_MACHINE=alphaev56 ;;
- PCA56) UNAME_MACHINE=alphapca56 ;;
- PCA57) UNAME_MACHINE=alphapca56 ;;
- EV6) UNAME_MACHINE=alphaev6 ;;
- EV67) UNAME_MACHINE=alphaev67 ;;
- EV68*) UNAME_MACHINE=alphaev68 ;;
- esac
- objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null
- if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
- echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
- exit ;;
padre:Linux:*:*)
echo sparc-unknown-linux-gnu
exit ;;
+ parisc64:Linux:*:* | hppa64:Linux:*:*)
+ echo hppa64-unknown-linux-gnu
+ exit ;;
parisc:Linux:*:* | hppa:Linux:*:*)
# Look for CPU level
case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
@@ -959,8 +950,11 @@ EOF
*) echo hppa-unknown-linux-gnu ;;
esac
exit ;;
- parisc64:Linux:*:* | hppa64:Linux:*:*)
- echo hppa64-unknown-linux-gnu
+ ppc64:Linux:*:*)
+ echo powerpc64-unknown-linux-gnu
+ exit ;;
+ ppc:Linux:*:*)
+ echo powerpc-unknown-linux-gnu
exit ;;
s390:Linux:*:* | s390x:Linux:*:*)
echo ${UNAME_MACHINE}-ibm-linux
@@ -983,66 +977,6 @@ EOF
xtensa*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit ;;
- i*86:Linux:*:*)
- # The BFD linker knows what the default object file format is, so
- # first see if it will tell us. cd to the root directory to prevent
- # problems with other programs or directories called `ld' in the path.
- # Set LC_ALL=C to ensure ld outputs messages in English.
- ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \
- | sed -ne '/supported targets:/!d
- s/[ ][ ]*/ /g
- s/.*supported targets: *//
- s/ .*//
- p'`
- case "$ld_supported_targets" in
- elf32-i386)
- TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu"
- ;;
- a.out-i386-linux)
- echo "${UNAME_MACHINE}-pc-linux-gnuaout"
- exit ;;
- "")
- # Either a pre-BFD a.out linker (linux-gnuoldld) or
- # one that does not give us useful --help.
- echo "${UNAME_MACHINE}-pc-linux-gnuoldld"
- exit ;;
- esac
- # Determine whether the default compiler is a.out or elf
- eval $set_cc_for_build
- sed 's/^ //' << EOF >$dummy.c
- #include <features.h>
- #ifdef __ELF__
- # ifdef __GLIBC__
- # if __GLIBC__ >= 2
- LIBC=gnu
- # else
- LIBC=gnulibc1
- # endif
- # else
- LIBC=gnulibc1
- # endif
- #else
- #if defined(__INTEL_COMPILER) || defined(__PGI) || defined(__SUNPRO_C) || defined(__SUNPRO_CC)
- LIBC=gnu
- #else
- LIBC=gnuaout
- #endif
- #endif
- #ifdef __dietlibc__
- LIBC=dietlibc
- #endif
-EOF
- eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
- /^LIBC/{
- s: ::g
- p
- }'`"
- test x"${LIBC}" != x && {
- echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
- exit
- }
- test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; }
- ;;
i*86:DYNIX/ptx:4*:*)
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
# earlier versions are messed up and put the nodename in both
@@ -1071,7 +1005,7 @@ EOF
i*86:syllable:*:*)
echo ${UNAME_MACHINE}-pc-syllable
exit ;;
- i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*)
+ i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*)
echo i386-unknown-lynxos${UNAME_RELEASE}
exit ;;
i*86:*DOS:*:*)
@@ -1115,8 +1049,11 @@ EOF
pc:*:*:*)
# Left here for compatibility:
# uname -m prints for DJGPP always 'pc', but it prints nothing about
- # the processor, so we play safe by assuming i386.
- echo i386-pc-msdosdjgpp
+ # the processor, so we play safe by assuming i586.
+ # Note: whatever this is, it MUST be the same as what config.sub
+ # prints for the "djgpp" host, or else GDB configury will decide that
+ # this is a cross-build.
+ echo i586-pc-msdosdjgpp
exit ;;
Intel:Mach:3*:*)
echo i386-pc-mach3
@@ -1176,7 +1113,7 @@ EOF
rs6000:LynxOS:2.*:*)
echo rs6000-unknown-lynxos${UNAME_RELEASE}
exit ;;
- PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*)
+ PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*)
echo powerpc-unknown-lynxos${UNAME_RELEASE}
exit ;;
SM[BE]S:UNIX_SV:*:*)
@@ -1269,6 +1206,16 @@ EOF
*:Darwin:*:*)
UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
case $UNAME_PROCESSOR in
+ i386)
+ eval $set_cc_for_build
+ if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
+ if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
+ (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
+ grep IS_64BIT_ARCH >/dev/null
+ then
+ UNAME_PROCESSOR="x86_64"
+ fi
+ fi ;;
unknown) UNAME_PROCESSOR=powerpc ;;
esac
echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
diff --git a/src/3rdparty/freetype/builds/unix/config.sub b/src/3rdparty/freetype/builds/unix/config.sub
index d546a94b95..c2d125724c 100755
--- a/src/3rdparty/freetype/builds/unix/config.sub
+++ b/src/3rdparty/freetype/builds/unix/config.sub
@@ -1,10 +1,10 @@
#! /bin/sh
# Configuration validation subroutine script.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
+# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010
# Free Software Foundation, Inc.
-timestamp='2009-02-03'
+timestamp='2010-01-22'
# This file is (in principle) common to ALL GNU software.
# The presence of a machine in this file suggests that SOME GNU software
@@ -32,13 +32,16 @@ timestamp='2009-02-03'
# Please send patches to <config-patches@gnu.org>. Submit a context
-# diff and a properly formatted ChangeLog entry.
+# diff and a properly formatted GNU ChangeLog entry.
#
# Configuration subroutine to validate and canonicalize a configuration type.
# Supply the specified configuration type as an argument.
# If it is invalid, we print an error message on stderr and exit with code 1.
# Otherwise, we print the canonical config type on stdout and succeed.
+# You can get the latest version of this script from:
+# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
+
# This file is supposed to be the same for all GNU packages
# and recognize all the CPU types, system types and aliases
# that are meaningful with *any* GNU software.
@@ -72,8 +75,9 @@ Report bugs and patches to <config-patches@gnu.org>."
version="\
GNU config.sub ($timestamp)
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
-2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
+2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free
+Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -149,10 +153,13 @@ case $os in
-convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
-c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
-harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
- -apple | -axis | -knuth | -cray)
+ -apple | -axis | -knuth | -cray | -microblaze)
os=
basic_machine=$1
;;
+ -bluegene*)
+ os=-cnk
+ ;;
-sim | -cisco | -oki | -wec | -winbond)
os=
basic_machine=$1
@@ -272,6 +279,7 @@ case $basic_machine in
| mipsisa64sr71k | mipsisa64sr71kel \
| mipstx39 | mipstx39el \
| mn10200 | mn10300 \
+ | moxie \
| mt \
| msp430 \
| nios | nios2 \
@@ -280,6 +288,7 @@ case $basic_machine in
| pdp10 | pdp11 | pj | pjl \
| powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
| pyramid \
+ | rx \
| score \
| sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
| sh64 | sh64le \
@@ -287,13 +296,14 @@ case $basic_machine in
| sparcv8 | sparcv9 | sparcv9b | sparcv9v \
| spu | strongarm \
| tahoe | thumb | tic4x | tic80 | tron \
+ | ubicom32 \
| v850 | v850e \
| we32k \
| x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \
| z8k | z80)
basic_machine=$basic_machine-unknown
;;
- m6811 | m68hc11 | m6812 | m68hc12)
+ m6811 | m68hc11 | m6812 | m68hc12 | picochip)
# Motorola 68HC11/12.
basic_machine=$basic_machine-unknown
os=-none
@@ -336,7 +346,7 @@ case $basic_machine in
| lm32-* \
| m32c-* | m32r-* | m32rle-* \
| m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
- | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \
+ | m88110-* | m88k-* | maxq-* | mcore-* | metag-* | microblaze-* \
| mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
| mips16-* \
| mips64-* | mips64el-* \
@@ -364,15 +374,17 @@ case $basic_machine in
| pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
| powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
| pyramid-* \
- | romp-* | rs6000-* \
+ | romp-* | rs6000-* | rx-* \
| sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
| shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
| sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \
| sparclite-* \
| sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \
| tahoe-* | thumb-* \
- | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* | tile-* \
+ | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
+ | tile-* | tilegx-* \
| tron-* \
+ | ubicom32-* \
| v850-* | v850e-* | vax-* \
| we32k-* \
| x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \
@@ -466,6 +478,10 @@ case $basic_machine in
basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'`
os=-linux
;;
+ bluegene*)
+ basic_machine=powerpc-ibm
+ os=-cnk
+ ;;
c90)
basic_machine=c90-cray
os=-unicos
@@ -718,6 +734,9 @@ case $basic_machine in
basic_machine=ns32k-utek
os=-sysv
;;
+ microblaze)
+ basic_machine=microblaze-xilinx
+ ;;
mingw32)
basic_machine=i386-pc
os=-mingw32
@@ -1068,6 +1087,11 @@ case $basic_machine in
basic_machine=tic6x-unknown
os=-coff
;;
+ # This must be matched before tile*.
+ tilegx*)
+ basic_machine=tilegx-unknown
+ os=-linux-gnu
+ ;;
tile*)
basic_machine=tile-unknown
os=-linux-gnu
@@ -1239,6 +1263,9 @@ case $os in
# First match some system type aliases
# that might get confused with valid system types.
# -solaris* is a basic system type, with this one exception.
+ -auroraux)
+ os=-auroraux
+ ;;
-solaris1 | -solaris1.*)
os=`echo $os | sed -e 's|solaris1|sunos4|'`
;;
@@ -1259,9 +1286,9 @@ case $os in
# Each alternative MUST END IN A *, to match a version number.
# -sysv* is not here because it comes later, after sysvr4.
-gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
- | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\
- | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \
- | -kopensolaris* \
+ | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\
+ | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \
+ | -sym* | -kopensolaris* \
| -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
| -aos* | -aros* \
| -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
@@ -1282,7 +1309,7 @@ case $os in
| -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
| -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
| -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
- | -skyos* | -haiku* | -rdos* | -toppers* | -drops*)
+ | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*)
# Remember, each alternative MUST END IN *, to match a version number.
;;
-qnx*)
@@ -1415,6 +1442,8 @@ case $os in
-dicos*)
os=-dicos
;;
+ -nacl*)
+ ;;
-none)
;;
*)
@@ -1612,7 +1641,7 @@ case $basic_machine in
-sunos*)
vendor=sun
;;
- -aix*)
+ -cnk*|-aix*)
vendor=ibm
;;
-beos*)
diff --git a/src/3rdparty/freetype/builds/unix/configure b/src/3rdparty/freetype/builds/unix/configure
index 97849a4352..0c949128f3 100755
--- a/src/3rdparty/freetype/builds/unix/configure
+++ b/src/3rdparty/freetype/builds/unix/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.63 for FreeType 2.3.9.
+# Generated by GNU Autoconf 2.63 for FreeType 2.3.12.
#
# Report bugs to <freetype@nongnu.org>.
#
@@ -745,8 +745,8 @@ SHELL=${CONFIG_SHELL-/bin/sh}
# Identity of this package.
PACKAGE_NAME='FreeType'
PACKAGE_TARNAME='freetype'
-PACKAGE_VERSION='2.3.9'
-PACKAGE_STRING='FreeType 2.3.9'
+PACKAGE_VERSION='2.3.12'
+PACKAGE_STRING='FreeType 2.3.12'
PACKAGE_BUGREPORT='freetype@nongnu.org'
ac_unique_file="ftconfig.in"
@@ -1461,7 +1461,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures FreeType 2.3.9 to adapt to many kinds of systems.
+\`configure' configures FreeType 2.3.12 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1526,7 +1526,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of FreeType 2.3.9:";;
+ short | recursive ) echo "Configuration of FreeType 2.3.12:";;
esac
cat <<\_ACEOF
@@ -1637,7 +1637,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-FreeType configure 2.3.9
+FreeType configure 2.3.12
generated by GNU Autoconf 2.63
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1651,7 +1651,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by FreeType $as_me 2.3.9, which was
+It was created by FreeType $as_me 2.3.12, which was
generated by GNU Autoconf 2.63. Invocation command line was
$ $0 $@
@@ -2024,7 +2024,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
# Don't forget to update docs/VERSION.DLL!
-version_info='9:20:3'
+version_info='10:0:4'
ft_version=`echo $version_info | tr : .`
@@ -3470,8 +3470,9 @@ $as_echo "$as_me: error: native C compiler is not working" >&2;}
elif test -x a_out.exe -o -x conftest.exe; then
EXEEXT_BUILD=".exe"
elif test -x conftest.* ; then
- EXEEXT_BUILD=`echo conftest.* | sed -n '1s/^.*\.//g'`
+ EXEEXT_BUILD=`echo conftest.* | sed -n '1s/^.*\././'`
fi
+ rm -f a.* b.* a_out.exe conftest.*
{ $as_echo "$as_me:$LINENO: result: $EXEEXT_BUILD" >&5
$as_echo "$EXEEXT_BUILD" >&6; }
else
@@ -3480,17 +3481,13 @@ else
fi
-if test ! -z ${EXEEXT_BUILD}; then
- EXEEXT_BUILD=."${EXEEXT_BUILD}"
-fi
-
# get compiler flags right
-if test "x$CC" = xgcc; then
+if test "x$GCC" = xyes; then
XX_CFLAGS="-Wall"
XX_ANSIFLAGS="-pedantic -ansi"
else
@@ -6051,37 +6048,54 @@ if test x$with_zlib != xno && test -n "$LIBZ"; then
fi
-# check Apple's `-isysroot' option and duplicate it to LDFLAGS if required --
-# Apple TechNote 2137 recommends to include it in CFLAGS but not in LDFLAGS
+# Some options handling SDKs/archs in CFLAGS should be copied
+# to LDFLAGS. Apple TechNote 2137 recommends to include these
+# options in CFLAGS but not in LDFLAGS.
-{ $as_echo "$as_me:$LINENO: checking whether CFLAGS includes -isysroot option" >&5
-$as_echo_n "checking whether CFLAGS includes -isysroot option... " >&6; }
-case "$CFLAGS" in
-*sysroot* )
- { $as_echo "$as_me:$LINENO: result: yes" >&5
-$as_echo "yes" >&6; }
- { $as_echo "$as_me:$LINENO: checking whether LDFLAGS includes -isysroot option" >&5
-$as_echo_n "checking whether LDFLAGS includes -isysroot option... " >&6; }
- case "$LDFLAGS" in
- *sysroot* )
- { $as_echo "$as_me:$LINENO: result: yes" >&5
+save_config_args=$*
+set dummy ${CFLAGS}
+i=1
+while test $i -lt $#
+do
+ c=$1
+
+ case "${c}" in
+ -isysroot|-arch) # options taking 1 argument
+ a=$2
+ { $as_echo "$as_me:$LINENO: checking whether CFLAGS and LDFLAGS share ${c} ${a}" >&5
+$as_echo_n "checking whether CFLAGS and LDFLAGS share ${c} ${a}... " >&6; }
+ if expr " ${LDFLAGS} " : ".* ${c} *${a}.*" > /dev/null
+ then
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
+ else
+ { $as_echo "$as_me:$LINENO: result: no, copy to LDFLAGS" >&5
+$as_echo "no, copy to LDFLAGS" >&6; }
+ LDFLAGS="${LDFLAGS} ${c} ${a}"
+ fi
+ shift 1
;;
- *)
- { $as_echo "$as_me:$LINENO: result: no" >&5
-$as_echo "no" >&6; }
- isysroot_dir=`echo ${CFLAGS} | tr '\t' ' ' | sed 's/^.*-isysroot *//;s/ .*//'`
- { $as_echo "$as_me:$LINENO: WARNING: -isysroot ${isysroot_dir} is added to LDFLAGS" >&5
-$as_echo "$as_me: WARNING: -isysroot ${isysroot_dir} is added to LDFLAGS" >&2;}
- LDFLAGS="-isysroot ${isysroot_dir} ${LDFLAGS}"
+ -m32|-m64) # options taking no argument
+ { $as_echo "$as_me:$LINENO: result: whether CFLAGS and LDFLAGS share ${c}" >&5
+$as_echo "whether CFLAGS and LDFLAGS share ${c}" >&6; }
+ if expr " ${LDFLAGS} " : ".* ${c} *${a}.*" > /dev/null
+ then
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
+ else
+ { $as_echo "$as_me:$LINENO: result: no, copy to LDFLAGS" >&5
+$as_echo "no, copy to LDFLAGS" >&6; }
+ LDFLAGS="${LDFLAGS} ${c}"
+ fi
;;
+ # *)
+ # AC_MSG_RESULT([${c} is not copied to LDFLAGS])
+ # ;;
esac
- ;;
-*)
- { $as_echo "$as_me:$LINENO: result: no" >&5
-$as_echo "no" >&6; }
- ;;
-esac
+
+ shift 1
+done
+set ${save_config_args}
# Whether to use Mac OS resource-based fonts.
@@ -6853,8 +6867,8 @@ esac
-macro_version='2.2.6'
-macro_revision='1.3012'
+macro_version='2.2.6b'
+macro_revision='1.3017'
@@ -7330,13 +7344,13 @@ if test "${lt_cv_nm_interface+set}" = set; then
else
lt_cv_nm_interface="BSD nm"
echo "int some_variable = 0;" > conftest.$ac_ext
- (eval echo "\"\$as_me:7333: $ac_compile\"" >&5)
+ (eval echo "\"\$as_me:7347: $ac_compile\"" >&5)
(eval "$ac_compile" 2>conftest.err)
cat conftest.err >&5
- (eval echo "\"\$as_me:7336: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
+ (eval echo "\"\$as_me:7350: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
(eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
cat conftest.err >&5
- (eval echo "\"\$as_me:7339: output\"" >&5)
+ (eval echo "\"\$as_me:7353: output\"" >&5)
cat conftest.out >&5
if $GREP 'External.*some_variable' conftest.out > /dev/null; then
lt_cv_nm_interface="MS dumpbin"
@@ -8538,7 +8552,7 @@ ia64-*-hpux*)
;;
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 8541 "configure"' > conftest.$ac_ext
+ echo '#line 8555 "configure"' > conftest.$ac_ext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
@@ -10201,11 +10215,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:10204: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:10218: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:10208: \$? = $ac_status" >&5
+ echo "$as_me:10222: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -10540,11 +10554,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:10543: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:10557: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:10547: \$? = $ac_status" >&5
+ echo "$as_me:10561: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -10645,11 +10659,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:10648: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:10662: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:10652: \$? = $ac_status" >&5
+ echo "$as_me:10666: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -10700,11 +10714,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:10703: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:10717: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:10707: \$? = $ac_status" >&5
+ echo "$as_me:10721: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -13500,7 +13514,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 13503 "configure"
+#line 13517 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -13596,7 +13610,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 13599 "configure"
+#line 13613 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -14266,7 +14280,7 @@ exec 6>&1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by FreeType $as_me 2.3.9, which was
+This file was extended by FreeType $as_me 2.3.12, which was
generated by GNU Autoconf 2.63. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -14329,7 +14343,7 @@ Report bugs to <bug-autoconf@gnu.org>."
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
-FreeType config.status 2.3.9
+FreeType config.status 2.3.12
configured by $0, generated by GNU Autoconf 2.63,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
@@ -15342,7 +15356,6 @@ $as_echo "$as_me: executing $ac_file commands" >&6;}
# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
-# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
#
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
diff --git a/src/3rdparty/freetype/builds/unix/configure.ac b/src/3rdparty/freetype/builds/unix/configure.ac
index 26f40ddfeb..762d43dd6f 100644
--- a/src/3rdparty/freetype/builds/unix/configure.ac
+++ b/src/3rdparty/freetype/builds/unix/configure.ac
@@ -2,7 +2,7 @@
#
# Process this file with autoconf to produce a configure script.
#
-# Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by
+# Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -11,13 +11,13 @@
# indicate that you have read the license and understand and accept it
# fully.
-AC_INIT([FreeType], [2.3.9], [freetype@nongnu.org], [freetype])
+AC_INIT([FreeType], [2.3.12], [freetype@nongnu.org], [freetype])
AC_CONFIG_SRCDIR([ftconfig.in])
# Don't forget to update docs/VERSION.DLL!
-version_info='9:20:3'
+version_info='10:0:4'
AC_SUBST([version_info])
ft_version=`echo $version_info | tr : .`
AC_SUBST([ft_version])
@@ -53,18 +53,15 @@ if test ${cross_compiling} = yes; then
elif test -x a_out.exe -o -x conftest.exe; then
EXEEXT_BUILD=".exe"
elif test -x conftest.* ; then
- EXEEXT_BUILD=`echo conftest.* | sed -n '1s/^.*\.//g'`
+ EXEEXT_BUILD=`echo conftest.* | sed -n '1s/^.*\././'`
fi
+ rm -f a.* b.* a_out.exe conftest.*
AC_MSG_RESULT($EXEEXT_BUILD)
else
CC_BUILD=${CC}
EXEEXT_BUILD=${EXEEXT}
fi
-
-if test ! -z ${EXEEXT_BUILD}; then
- EXEEXT_BUILD=."${EXEEXT_BUILD}"
-fi
AC_SUBST(CC_BUILD)
AC_SUBST(EXEEXT_BUILD)
@@ -72,7 +69,7 @@ AC_SUBST(EXEEXT_BUILD)
# get compiler flags right
-if test "x$CC" = xgcc; then
+if test "x$GCC" = xyes; then
XX_CFLAGS="-Wall"
XX_ANSIFLAGS="-pedantic -ansi"
else
@@ -233,30 +230,48 @@ if test x$with_zlib != xno && test -n "$LIBZ"; then
fi
-# check Apple's `-isysroot' option and duplicate it to LDFLAGS if required --
-# Apple TechNote 2137 recommends to include it in CFLAGS but not in LDFLAGS
-
-AC_MSG_CHECKING([whether CFLAGS includes -isysroot option])
-case "$CFLAGS" in
-*sysroot* )
- AC_MSG_RESULT([yes])
- AC_MSG_CHECKING([whether LDFLAGS includes -isysroot option])
- case "$LDFLAGS" in
- *sysroot* )
- AC_MSG_RESULT([yes])
+# Some options handling SDKs/archs in CFLAGS should be copied
+# to LDFLAGS. Apple TechNote 2137 recommends to include these
+# options in CFLAGS but not in LDFLAGS.
+
+save_config_args=$*
+set dummy ${CFLAGS}
+i=1
+while test $i -lt $#
+do
+ c=$1
+
+ case "${c}" in
+ -isysroot|-arch) # options taking 1 argument
+ a=$2
+ AC_MSG_CHECKING([whether CFLAGS and LDFLAGS share ${c} ${a}])
+ if expr " ${LDFLAGS} " : ".* ${c} *${a}.*" > /dev/null
+ then
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no, copy to LDFLAGS])
+ LDFLAGS="${LDFLAGS} ${c} ${a}"
+ fi
+ shift 1
;;
- *)
- AC_MSG_RESULT([no])
- isysroot_dir=`echo ${CFLAGS} | tr '\t' ' ' | sed 's/^.*-isysroot *//;s/ .*//'`
- AC_MSG_WARN(-isysroot ${isysroot_dir} is added to LDFLAGS)
- LDFLAGS="-isysroot ${isysroot_dir} ${LDFLAGS}"
+ -m32|-m64) # options taking no argument
+ AC_MSG_RESULT([whether CFLAGS and LDFLAGS share ${c}])
+ if expr " ${LDFLAGS} " : ".* ${c} *${a}.*" > /dev/null
+ then
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no, copy to LDFLAGS])
+ LDFLAGS="${LDFLAGS} ${c}"
+ fi
;;
+ # *)
+ # AC_MSG_RESULT([${c} is not copied to LDFLAGS])
+ # ;;
esac
- ;;
-*)
- AC_MSG_RESULT([no])
- ;;
-esac
+
+ shift 1
+done
+set ${save_config_args}
# Whether to use Mac OS resource-based fonts.
diff --git a/src/3rdparty/freetype/builds/unix/configure.raw b/src/3rdparty/freetype/builds/unix/configure.raw
index 38c5241cfb..ff16dfe330 100644
--- a/src/3rdparty/freetype/builds/unix/configure.raw
+++ b/src/3rdparty/freetype/builds/unix/configure.raw
@@ -2,7 +2,7 @@
#
# Process this file with autoconf to produce a configure script.
#
-# Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by
+# Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -17,7 +17,7 @@ AC_CONFIG_SRCDIR([ftconfig.in])
# Don't forget to update docs/VERSION.DLL!
-version_info='9:20:3'
+version_info='10:0:4'
AC_SUBST([version_info])
ft_version=`echo $version_info | tr : .`
AC_SUBST([ft_version])
@@ -53,18 +53,15 @@ if test ${cross_compiling} = yes; then
elif test -x a_out.exe -o -x conftest.exe; then
EXEEXT_BUILD=".exe"
elif test -x conftest.* ; then
- EXEEXT_BUILD=`echo conftest.* | sed -n '1s/^.*\.//g'`
+ EXEEXT_BUILD=`echo conftest.* | sed -n '1s/^.*\././'`
fi
+ rm -f a.* b.* a_out.exe conftest.*
AC_MSG_RESULT($EXEEXT_BUILD)
else
CC_BUILD=${CC}
EXEEXT_BUILD=${EXEEXT}
fi
-
-if test ! -z ${EXEEXT_BUILD}; then
- EXEEXT_BUILD=."${EXEEXT_BUILD}"
-fi
AC_SUBST(CC_BUILD)
AC_SUBST(EXEEXT_BUILD)
@@ -72,7 +69,7 @@ AC_SUBST(EXEEXT_BUILD)
# get compiler flags right
-if test "x$CC" = xgcc; then
+if test "x$GCC" = xyes; then
XX_CFLAGS="-Wall"
XX_ANSIFLAGS="-pedantic -ansi"
else
@@ -233,30 +230,48 @@ if test x$with_zlib != xno && test -n "$LIBZ"; then
fi
-# check Apple's `-isysroot' option and duplicate it to LDFLAGS if required --
-# Apple TechNote 2137 recommends to include it in CFLAGS but not in LDFLAGS
-
-AC_MSG_CHECKING([whether CFLAGS includes -isysroot option])
-case "$CFLAGS" in
-*sysroot* )
- AC_MSG_RESULT([yes])
- AC_MSG_CHECKING([whether LDFLAGS includes -isysroot option])
- case "$LDFLAGS" in
- *sysroot* )
- AC_MSG_RESULT([yes])
+# Some options handling SDKs/archs in CFLAGS should be copied
+# to LDFLAGS. Apple TechNote 2137 recommends to include these
+# options in CFLAGS but not in LDFLAGS.
+
+save_config_args=$*
+set dummy ${CFLAGS}
+i=1
+while test $i -lt $#
+do
+ c=$1
+
+ case "${c}" in
+ -isysroot|-arch) # options taking 1 argument
+ a=$2
+ AC_MSG_CHECKING([whether CFLAGS and LDFLAGS share ${c} ${a}])
+ if expr " ${LDFLAGS} " : ".* ${c} *${a}.*" > /dev/null
+ then
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no, copy to LDFLAGS])
+ LDFLAGS="${LDFLAGS} ${c} ${a}"
+ fi
+ shift 1
;;
- *)
- AC_MSG_RESULT([no])
- isysroot_dir=`echo ${CFLAGS} | tr '\t' ' ' | sed 's/^.*-isysroot *//;s/ .*//'`
- AC_MSG_WARN(-isysroot ${isysroot_dir} is added to LDFLAGS)
- LDFLAGS="-isysroot ${isysroot_dir} ${LDFLAGS}"
+ -m32|-m64) # options taking no argument
+ AC_MSG_RESULT([whether CFLAGS and LDFLAGS share ${c}])
+ if expr " ${LDFLAGS} " : ".* ${c} *${a}.*" > /dev/null
+ then
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no, copy to LDFLAGS])
+ LDFLAGS="${LDFLAGS} ${c}"
+ fi
;;
+ # *)
+ # AC_MSG_RESULT([${c} is not copied to LDFLAGS])
+ # ;;
esac
- ;;
-*)
- AC_MSG_RESULT([no])
- ;;
-esac
+
+ shift 1
+done
+set ${save_config_args}
# Whether to use Mac OS resource-based fonts.
diff --git a/src/3rdparty/freetype/builds/unix/freetype-config.in b/src/3rdparty/freetype/builds/unix/freetype-config.in
index 9606d318bd..0a7a767d6e 100644
--- a/src/3rdparty/freetype/builds/unix/freetype-config.in
+++ b/src/3rdparty/freetype/builds/unix/freetype-config.in
@@ -101,11 +101,11 @@ if test "$local_prefix" = "yes" ; then
fi
if test "$echo_prefix" = "yes" ; then
- echo $prefix
+ echo ${SYSROOT}$prefix
fi
if test "$echo_exec_prefix" = "yes" ; then
- echo $exec_prefix
+ echo ${SYSROOT}$exec_prefix
fi
if test "$exec_prefix_set" = "yes" ; then
@@ -118,22 +118,22 @@ else
fi
if test "$echo_ft_version" = "yes" ; then
- major=`grep define $includedir/freetype2/freetype/freetype.h \
+ major=`grep define ${SYSROOT}$includedir/freetype2/freetype/freetype.h \
| grep FREETYPE_MAJOR \
| sed 's/.*[ ]\([0-9][0-9]*\).*/\1/'`
- minor=`grep define $includedir/freetype2/freetype/freetype.h \
+ minor=`grep define ${SYSROOT}$includedir/freetype2/freetype/freetype.h \
| grep FREETYPE_MINOR \
| sed 's/.*[ ]\([0-9][0-9]*\).*/\1/'`
- patch=`grep define $includedir/freetype2/freetype/freetype.h \
+ patch=`grep define ${SYSROOT}$includedir/freetype2/freetype/freetype.h \
| grep FREETYPE_PATCH \
| sed 's/.*[ ]\([0-9][0-9]*\).*/\1/'`
echo $major.$minor.$patch
fi
if test "$echo_cflags" = "yes" ; then
- cflags="-I$includedir/freetype2"
- if test "$includedir" != "/usr/include" ; then
- echo $cflags -I$includedir
+ cflags="-I${SYSROOT}$includedir/freetype2"
+ if test "${SYSROOT}$includedir" != "/usr/include" ; then
+ echo $cflags -I${SYSROOT}$includedir
else
echo $cflags
fi
@@ -145,8 +145,8 @@ if test "$echo_libs" = "yes" ; then
eval "rpath=\"$hardcode_libdir_flag_spec\""
fi
libs="-lfreetype @LIBZ@ @FT2_EXTRA_LIBS@"
- if test "$libdir" != "/usr/lib" && test "$libdir" != "/usr/lib64"; then
- echo -L$libdir $rpath $libs
+ if test "${SYSROOT}$libdir" != "/usr/lib" && test "${SYSROOT}$libdir" != "/usr/lib64"; then
+ echo -L${SYSROOT}$libdir $libs
else
echo $libs
fi
@@ -154,7 +154,7 @@ fi
if test "$echo_libtool" = "yes" ; then
convlib="libfreetype.la"
- echo $libdir/$convlib
+ echo ${SYSROOT}$libdir/$convlib
fi
# EOF
diff --git a/src/3rdparty/freetype/builds/unix/freetype2.m4 b/src/3rdparty/freetype/builds/unix/freetype2.m4
index d1da07d9c1..3d0ecb3554 100644
--- a/src/3rdparty/freetype/builds/unix/freetype2.m4
+++ b/src/3rdparty/freetype/builds/unix/freetype2.m4
@@ -1,7 +1,7 @@
# Configure paths for FreeType2
# Marcelo Magallon 2001-10-26, based on gtk.m4 by Owen Taylor
#
-# Copyright 2001, 2003, 2007 by
+# Copyright 2001, 2003, 2007, 2009 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -15,7 +15,7 @@
# generated by Autoconf, under the same distribution terms as the rest of
# that program.
#
-# serial 2
+# serial 3
# AC_CHECK_FT2([MINIMUM-VERSION [, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]])
# Test for FreeType 2, and define FT2_CFLAGS and FT2_LIBS.
@@ -60,7 +60,9 @@ AC_DEFUN([AC_CHECK_FT2],
fi
fi
- AC_PATH_PROG([FT2_CONFIG], [freetype-config], [no])
+ if test "x$FT2_CONFIG" = x ; then
+ AC_PATH_PROG([FT2_CONFIG], [freetype-config], [no])
+ fi
min_ft_version=m4_if([$1], [], [7.0.1], [$1])
AC_MSG_CHECKING([for FreeType -- version >= $min_ft_version])
diff --git a/src/3rdparty/freetype/builds/unix/ftconfig.h b/src/3rdparty/freetype/builds/unix/ftconfig.h
index 2fca16c79c..8bd62f94d5 100644
--- a/src/3rdparty/freetype/builds/unix/ftconfig.h
+++ b/src/3rdparty/freetype/builds/unix/ftconfig.h
@@ -140,6 +140,13 @@ FT_BEGIN_HEADER
#endif /* FT_SIZEOF_LONG == 8 */
+#ifdef FT_CONFIG_OPTION_INLINE_MULFIX
+#ifdef FT_MULFIX_ASSEMBLER
+#define FT_MULFIX_INLINED FT_MULFIX_ASSEMBLER
+#endif
+#endif
+
+
#ifdef FT_MAKE_OPTION_SINGLE_OBJECT
#define FT_LOCAL( x ) static x
diff --git a/src/3rdparty/freetype/builds/unix/ftconfig.in b/src/3rdparty/freetype/builds/unix/ftconfig.in
index 0adfdcf64a..c5e4e46b40 100644
--- a/src/3rdparty/freetype/builds/unix/ftconfig.in
+++ b/src/3rdparty/freetype/builds/unix/ftconfig.in
@@ -298,7 +298,7 @@ FT_BEGIN_HEADER
register FT_Int32 t, t2;
- asm __volatile__ (
+ __asm__ __volatile__ (
"smull %1, %2, %4, %3\n\t" /* (lo=%1,hi=%2) = a*b */
"mov %0, %2, asr #31\n\t" /* %0 = (hi >> 31) */
"add %0, %0, #0x8000\n\t" /* %0 += 0x8000 */
diff --git a/src/3rdparty/freetype/builds/unix/ftsystem.c b/src/3rdparty/freetype/builds/unix/ftsystem.c
index 5c38090166..95f8271ec3 100644
--- a/src/3rdparty/freetype/builds/unix/ftsystem.c
+++ b/src/3rdparty/freetype/builds/unix/ftsystem.c
@@ -69,9 +69,6 @@
#include <string.h>
#include <errno.h>
-#ifdef VXWORKS
-#include <ioLib.h>
-#endif
/*************************************************************************/
/* */
@@ -241,7 +238,7 @@
return FT_Err_Invalid_Stream_Handle;
/* open the file */
- file = open( filepathname, O_RDONLY, 0);
+ file = open( filepathname, O_RDONLY );
if ( file < 0 )
{
FT_ERROR(( "FT_Stream_Open:" ));
@@ -325,11 +322,7 @@
read_count = read( file,
-#ifndef VXWORKS
stream->base + total_read_count,
-#else
- (char *) stream->base + total_read_count,
-#endif
stream->size - total_read_count );
if ( read_count <= 0 )
diff --git a/src/3rdparty/freetype/builds/unix/install-sh b/src/3rdparty/freetype/builds/unix/install-sh
index a5897de6ea..6781b987bd 100755
--- a/src/3rdparty/freetype/builds/unix/install-sh
+++ b/src/3rdparty/freetype/builds/unix/install-sh
@@ -1,7 +1,7 @@
#!/bin/sh
# install - install a program, script, or datafile
-scriptversion=2006-12-25.00
+scriptversion=2009-04-28.21; # UTC
# This originates from X11R5 (mit/util/scripts/install.sh), which was
# later released in X11R6 (xc/config/util/install.sh) with the
@@ -515,5 +515,6 @@ done
# eval: (add-hook 'write-file-hooks 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
-# time-stamp-end: "$"
+# time-stamp-time-zone: "UTC"
+# time-stamp-end: "; # UTC"
# End:
diff --git a/src/3rdparty/freetype/builds/unix/ltmain.sh b/src/3rdparty/freetype/builds/unix/ltmain.sh
index b36c4ad366..a72f2fd78b 100755
--- a/src/3rdparty/freetype/builds/unix/ltmain.sh
+++ b/src/3rdparty/freetype/builds/unix/ltmain.sh
@@ -1,6 +1,6 @@
# Generated from ltmain.m4sh.
-# ltmain.sh (GNU libtool) 2.2.6
+# ltmain.sh (GNU libtool) 2.2.6b
# Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007 2008 Free Software Foundation, Inc.
@@ -65,7 +65,7 @@
# compiler: $LTCC
# compiler flags: $LTCFLAGS
# linker: $LD (gnu? $with_gnu_ld)
-# $progname: (GNU libtool) 2.2.6
+# $progname: (GNU libtool) 2.2.6b
# automake: $automake_version
# autoconf: $autoconf_version
#
@@ -73,9 +73,9 @@
PROGRAM=ltmain.sh
PACKAGE=libtool
-VERSION=2.2.6
+VERSION=2.2.6b
TIMESTAMP=""
-package_revision=1.3012
+package_revision=1.3017
# Be Bourne compatible
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
@@ -116,15 +116,15 @@ $lt_unset CDPATH
: ${CP="cp -f"}
: ${ECHO="echo"}
-: ${EGREP="/usr/bin/grep -E"}
-: ${FGREP="/usr/bin/grep -F"}
-: ${GREP="/usr/bin/grep"}
+: ${EGREP="/bin/grep -E"}
+: ${FGREP="/bin/grep -F"}
+: ${GREP="/bin/grep"}
: ${LN_S="ln -s"}
: ${MAKE="make"}
: ${MKDIR="mkdir"}
: ${MV="mv -f"}
: ${RM="rm -f"}
-: ${SED="/opt/local/bin/gsed"}
+: ${SED="/bin/sed"}
: ${SHELL="${CONFIG_SHELL-/bin/sh}"}
: ${Xsed="$SED -e 1s/^X//"}
diff --git a/src/3rdparty/freetype/builds/win32/ftdebug.c b/src/3rdparty/freetype/builds/win32/ftdebug.c
index 8f7a9ab07d..d1ca15ac95 100644
--- a/src/3rdparty/freetype/builds/win32/ftdebug.c
+++ b/src/3rdparty/freetype/builds/win32/ftdebug.c
@@ -4,7 +4,7 @@
/* */
/* Debugging and logging component for Win32 (body). */
/* */
-/* Copyright 1996-2001, 2002, 2005, 2008 by */
+/* Copyright 1996-2001, 2002, 2005, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -55,29 +55,6 @@
#include <windows.h>
-#ifdef _WIN32_WCE
-
- void
- OutputDebugStringEx( const char* str )
- {
- static WCHAR buf[8192];
-
-
- int sz = MultiByteToWideChar( CP_ACP, 0, str, -1, buf,
- sizeof ( buf ) / sizeof ( *buf ) );
- if ( !sz )
- lstrcpyW( buf, L"OutputDebugStringEx: MultiByteToWideChar failed" );
-
- OutputDebugStringW( buf );
- }
-
-#else
-
-#define OutputDebugStringEx OutputDebugStringA
-
-#endif
-
-
FT_BASE_DEF( void )
FT_Message( const char* fmt, ... )
{
@@ -89,7 +66,7 @@
vprintf( fmt, ap );
/* send the string to the debugger as well */
vsprintf( buf, fmt, ap );
- OutputDebugStringEx( buf );
+ OutputDebugStringA( buf );
va_end( ap );
}
@@ -103,7 +80,7 @@
va_start( ap, fmt );
vsprintf( buf, fmt, ap );
- OutputDebugStringEx( buf );
+ OutputDebugStringA( buf );
va_end( ap );
exit( EXIT_FAILURE );
@@ -149,19 +126,8 @@
FT_BASE_DEF( void )
ft_debug_init( void )
{
-#ifdef _WIN32_WCE
-
- /* Windows Mobile doesn't have environment API: */
- /* GetEnvironmentStrings, GetEnvironmentVariable, getenv. */
- /* */
- /* FIXME!!! How to set debug mode? */
- const char* ft2_debug = 0;
-
-#else
-
const char* ft2_debug = getenv( "FT2_DEBUG" );
-#endif
if ( ft2_debug )
{
diff --git a/src/3rdparty/freetype/builds/win32/vc2005/freetype.sln b/src/3rdparty/freetype/builds/win32/vc2005/freetype.sln
index 20492031e0..b90da27bb3 100644
--- a/src/3rdparty/freetype/builds/win32/vc2005/freetype.sln
+++ b/src/3rdparty/freetype/builds/win32/vc2005/freetype.sln
@@ -1,4 +1,4 @@
-Microsoft Visual Studio Solution File, Format Version 10.00
+Microsoft Visual Studio Solution File, Format Version 9.00
# Visual Studio 2005
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "freetype", "freetype.vcproj", "{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}"
EndProject
diff --git a/src/3rdparty/freetype/builds/win32/vc2005/freetype.vcproj b/src/3rdparty/freetype/builds/win32/vc2005/freetype.vcproj
index bd8634c594..3dde2b672f 100644
--- a/src/3rdparty/freetype/builds/win32/vc2005/freetype.vcproj
+++ b/src/3rdparty/freetype/builds/win32/vc2005/freetype.vcproj
@@ -16,7 +16,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\win32\vc2005\freetype239.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\win32\vc2005\freetype2312.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -33,7 +33,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\win32\vc2005\freetype239MT.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\win32\vc2005\freetype2312MT.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -50,7 +50,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\win32\vc2005\freetype239ST.lib" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\win32\vc2005\freetype2312ST.lib" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -67,7 +67,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\win32\vc2005\freetype239_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\win32\vc2005\freetype2312_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -84,7 +84,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\win32\vc2005\freetype239ST_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\win32\vc2005\freetype2312ST_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -101,7 +101,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\win32\vc2005\freetype239MT_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\win32\vc2005\freetype2312MT_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -374,6 +374,14 @@
</File>
<File RelativePath="..\..\..\src\base\ftwinfnt.c">
</File>
+ <File RelativePath="..\..\..\src\base\ftlcdfil.c">
+ </File>
+ <File RelativePath="..\..\..\src\base\ftgxval.c">
+ </File>
+ <File RelativePath="..\..\..\src\base\ftotval.c">
+ </File>
+ <File RelativePath="..\..\..\src\base\ftpatent.c">
+ </File>
<File RelativePath="..\..\..\src\pcf\pcf.c">
<FileConfiguration Name="Release|Win32">
<Tool Name="VCCLCompilerTool" Optimization="2" AdditionalIncludeDirectories="" PreprocessorDefinitions="" />
diff --git a/src/3rdparty/freetype/builds/win32/vc2005/index.html b/src/3rdparty/freetype/builds/win32/vc2005/index.html
index 41d5e0a0a1..7773882282 100644
--- a/src/3rdparty/freetype/builds/win32/vc2005/index.html
+++ b/src/3rdparty/freetype/builds/win32/vc2005/index.html
@@ -11,14 +11,14 @@
<p>This directory contains project files for Visual C++, named
<tt>freetype.vcproj</tt>, and Visual Studio, called <tt>freetype.sln</tt>. It
-compiles the following libraries from the FreeType 2.3.9 sources:</p>
+compiles the following libraries from the FreeType 2.3.12 sources:</p>
<ul>
<pre>
- freetype239.lib - release build; single threaded
- freetype239_D.lib - debug build; single threaded
- freetype239MT.lib - release build; multi-threaded
- freetype239MT_D.lib - debug build; multi-threaded</pre>
+ freetype2312.lib - release build; single threaded
+ freetype2312_D.lib - debug build; single threaded
+ freetype2312MT.lib - release build; multi-threaded
+ freetype2312MT_D.lib - debug build; multi-threaded</pre>
</ul>
<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
diff --git a/src/3rdparty/freetype/builds/win32/vc2008/freetype.vcproj b/src/3rdparty/freetype/builds/win32/vc2008/freetype.vcproj
index 07d950b0fc..97e44e0a27 100644
--- a/src/3rdparty/freetype/builds/win32/vc2008/freetype.vcproj
+++ b/src/3rdparty/freetype/builds/win32/vc2008/freetype.vcproj
@@ -70,7 +70,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\win32\vc2008\freetype239.lib"
+ OutputFile="..\..\..\objs\win32\vc2008\freetype2312.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -145,7 +145,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\win32\vc2008\freetype239MT.lib"
+ OutputFile="..\..\..\objs\win32\vc2008\freetype2312MT.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -220,7 +220,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\win32\vc2008\freetype239ST.lib"
+ OutputFile="..\..\..\objs\win32\vc2008\freetype2312ST.lib"
/>
<Tool
Name="VCALinkTool"
@@ -292,7 +292,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\win32\vc2008\freetype239_D.lib"
+ OutputFile="..\..\..\objs\win32\vc2008\freetype2312_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -365,7 +365,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\win32\vc2008\freetype239ST_D.lib"
+ OutputFile="..\..\..\objs\win32\vc2008\freetype2312ST_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -439,7 +439,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\win32\vc2008\freetype239MT_D.lib"
+ OutputFile="..\..\..\objs\win32\vc2008\freetype2312MT_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -1320,6 +1320,22 @@
>
</File>
<File
+ RelativePath="..\..\..\src\base\ftlcdfil.c"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\src\base\ftgxval.c"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\src\base\ftotval.c"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\src\base\ftpatent.c"
+ >
+ </File>
+ <File
RelativePath="..\..\..\src\pcf\pcf.c"
>
<FileConfiguration
diff --git a/src/3rdparty/freetype/builds/win32/vc2008/index.html b/src/3rdparty/freetype/builds/win32/vc2008/index.html
index 5e349b7117..aa16c384c6 100644
--- a/src/3rdparty/freetype/builds/win32/vc2008/index.html
+++ b/src/3rdparty/freetype/builds/win32/vc2008/index.html
@@ -11,14 +11,14 @@
<p>This directory contains project files for Visual C++, named
<tt>freetype.vcproj</tt>, and Visual Studio, called <tt>freetype.sln</tt>. It
-compiles the following libraries from the FreeType 2.3.9 sources:</p>
+compiles the following libraries from the FreeType 2.3.12 sources:</p>
<ul>
<pre>
- freetype239.lib - release build; single threaded
- freetype239_D.lib - debug build; single threaded
- freetype239MT.lib - release build; multi-threaded
- freetype239MT_D.lib - debug build; multi-threaded</pre>
+ freetype2312.lib - release build; single threaded
+ freetype2312_D.lib - debug build; single threaded
+ freetype2312MT.lib - release build; multi-threaded
+ freetype2312MT_D.lib - debug build; multi-threaded</pre>
</ul>
<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
diff --git a/src/3rdparty/freetype/builds/win32/visualc/freetype.dsp b/src/3rdparty/freetype/builds/win32/visualc/freetype.dsp
index 556dfb6c75..6764ce1336 100644
--- a/src/3rdparty/freetype/builds/win32/visualc/freetype.dsp
+++ b/src/3rdparty/freetype/builds/win32/visualc/freetype.dsp
@@ -54,7 +54,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LIB32=link.exe -lib
# ADD BASE LIB32 /nologo
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype239.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2312.lib"
!ELSEIF "$(CFG)" == "freetype - Win32 Debug"
@@ -78,7 +78,7 @@ BSC32=bscmake.exe
# ADD BSC32 /nologo
LIB32=link.exe -lib
# ADD BASE LIB32 /nologo
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype239_D.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2312_D.lib"
!ELSEIF "$(CFG)" == "freetype - Win32 Debug Multithreaded"
@@ -102,8 +102,8 @@ BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
-# ADD BASE LIB32 /nologo /out:"lib\freetype239_D.lib"
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype239MT_D.lib"
+# ADD BASE LIB32 /nologo /out:"lib\freetype2312_D.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2312MT_D.lib"
!ELSEIF "$(CFG)" == "freetype - Win32 Release Multithreaded"
@@ -126,8 +126,8 @@ BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
-# ADD BASE LIB32 /nologo /out:"lib\freetype239.lib"
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype239MT.lib"
+# ADD BASE LIB32 /nologo /out:"lib\freetype2312.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2312MT.lib"
!ELSEIF "$(CFG)" == "freetype - Win32 Release Singlethreaded"
@@ -151,8 +151,8 @@ BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
-# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype239.lib"
-# ADD LIB32 /out:"..\..\..\objs\freetype239ST.lib"
+# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype2312.lib"
+# ADD LIB32 /out:"..\..\..\objs\freetype2312ST.lib"
# SUBTRACT LIB32 /nologo
!ELSEIF "$(CFG)" == "freetype - Win32 Debug Singlethreaded"
@@ -177,8 +177,8 @@ BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LIB32=link.exe -lib
-# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype239_D.lib"
-# ADD LIB32 /nologo /out:"..\..\..\objs\freetype239ST_D.lib"
+# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype2312_D.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2312ST_D.lib"
!ENDIF
diff --git a/src/3rdparty/freetype/builds/win32/visualc/index.html b/src/3rdparty/freetype/builds/win32/visualc/index.html
index fffcf4fdec..eaf3a5c5b7 100644
--- a/src/3rdparty/freetype/builds/win32/visualc/index.html
+++ b/src/3rdparty/freetype/builds/win32/visualc/index.html
@@ -11,14 +11,14 @@
<p>This directory contains project files for Visual C++, named
<tt>freetype.dsp</tt>, and Visual Studio, called <tt>freetype.sln</tt>. It
-compiles the following libraries from the FreeType 2.3.9 sources:</p>
+compiles the following libraries from the FreeType 2.3.12 sources:</p>
<ul>
<pre>
- freetype239.lib - release build; single threaded
- freetype239_D.lib - debug build; single threaded
- freetype239MT.lib - release build; multi-threaded
- freetype239MT_D.lib - debug build; multi-threaded</pre>
+ freetype2312.lib - release build; single threaded
+ freetype2312_D.lib - debug build; single threaded
+ freetype2312MT.lib - release build; multi-threaded
+ freetype2312MT_D.lib - debug build; multi-threaded</pre>
</ul>
<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
diff --git a/src/3rdparty/freetype/builds/win32/visualce/freetype.dsp b/src/3rdparty/freetype/builds/win32/visualce/freetype.dsp
new file mode 100644
index 0000000000..6764ce1336
--- /dev/null
+++ b/src/3rdparty/freetype/builds/win32/visualce/freetype.dsp
@@ -0,0 +1,400 @@
+# Microsoft Developer Studio Project File - Name="freetype" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Static Library" 0x0104
+
+CFG=freetype - Win32 Debug Singlethreaded
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "freetype.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "freetype.mak" CFG="freetype - Win32 Debug Singlethreaded"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "freetype - Win32 Release" (based on "Win32 (x86) Static Library")
+!MESSAGE "freetype - Win32 Debug" (based on "Win32 (x86) Static Library")
+!MESSAGE "freetype - Win32 Debug Multithreaded" (based on "Win32 (x86) Static Library")
+!MESSAGE "freetype - Win32 Release Multithreaded" (based on "Win32 (x86) Static Library")
+!MESSAGE "freetype - Win32 Release Singlethreaded" (based on "Win32 (x86) Static Library")
+!MESSAGE "freetype - Win32 Debug Singlethreaded" (based on "Win32 (x86) Static Library")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "freetype - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "..\..\..\objs\release"
+# PROP Intermediate_Dir "..\..\..\objs\release"
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /YX /FD /c
+# ADD CPP /MD /Za /W4 /GX /O2 /I "..\..\..\include" /D "NDEBUG" /D "WIN32" /D "_MBCS" /D "_LIB" /D "FT2_BUILD_LIBRARY" /FD /c
+# SUBTRACT CPP /nologo /Z<none> /YX
+# ADD BASE RSC /l 0x409 /d "NDEBUG"
+# ADD RSC /l 0x409 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LIB32=link.exe -lib
+# ADD BASE LIB32 /nologo
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2312.lib"
+
+!ELSEIF "$(CFG)" == "freetype - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "..\..\..\objs\debug"
+# PROP Intermediate_Dir "..\..\..\objs\debug"
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB" /YX /FD /GZ /c
+# ADD CPP /MDd /Za /W4 /GX /Z7 /Od /I "..\..\..\include" /D "_DEBUG" /D "FT_DEBUG_LEVEL_ERROR" /D "FT_DEBUG_LEVEL_TRACE" /D "WIN32" /D "_MBCS" /D "_LIB" /D "FT2_BUILD_LIBRARY" /FD /GZ /c
+# SUBTRACT CPP /nologo /X /YX
+# ADD BASE RSC /l 0x409 /d "_DEBUG"
+# ADD RSC /l 0x409 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LIB32=link.exe -lib
+# ADD BASE LIB32 /nologo
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2312_D.lib"
+
+!ELSEIF "$(CFG)" == "freetype - Win32 Debug Multithreaded"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "freetype___Win32_Debug_Multithreaded"
+# PROP BASE Intermediate_Dir "freetype___Win32_Debug_Multithreaded"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "..\..\..\objs\debug_mt"
+# PROP Intermediate_Dir "..\..\..\objs\debug_mt"
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /Za /W3 /Gm /GX /ZI /Od /I "..\freetype\include\\" /D "_DEBUG" /D "WIN32" /D "_MBCS" /D "_LIB" /D "FT_FLAT_COMPILE" /YX /FD /GZ /c
+# SUBTRACT BASE CPP /X
+# ADD CPP /MTd /Za /W4 /GX /Z7 /Od /I "..\..\..\include" /D "_DEBUG" /D "FT_DEBUG_LEVEL_ERROR" /D "FT_DEBUG_LEVEL_TRACE" /D "WIN32" /D "_MBCS" /D "_LIB" /D "FT2_BUILD_LIBRARY" /FD /GZ /c
+# SUBTRACT CPP /nologo /X /YX
+# ADD BASE RSC /l 0x409 /d "_DEBUG"
+# ADD RSC /l 0x409 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LIB32=link.exe -lib
+# ADD BASE LIB32 /nologo /out:"lib\freetype2312_D.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2312MT_D.lib"
+
+!ELSEIF "$(CFG)" == "freetype - Win32 Release Multithreaded"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "freetype___Win32_Release_Multithreaded"
+# PROP BASE Intermediate_Dir "freetype___Win32_Release_Multithreaded"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "..\..\..\objs\release_mt"
+# PROP Intermediate_Dir "..\..\..\objs\release_mt"
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /Za /W3 /GX /O2 /I "..\freetype\include\\" /D "NDEBUG" /D "WIN32" /D "_MBCS" /D "_LIB" /D "FT_FLAT_COMPILE" /YX /FD /c
+# ADD CPP /MT /Za /W4 /GX /O2 /I "..\..\..\include" /D "NDEBUG" /D "WIN32" /D "_MBCS" /D "_LIB" /D "FT2_BUILD_LIBRARY" /FD /c
+# SUBTRACT CPP /nologo /Z<none> /YX
+# ADD BASE RSC /l 0x409 /d "NDEBUG"
+# ADD RSC /l 0x409 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LIB32=link.exe -lib
+# ADD BASE LIB32 /nologo /out:"lib\freetype2312.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2312MT.lib"
+
+!ELSEIF "$(CFG)" == "freetype - Win32 Release Singlethreaded"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "freetype___Win32_Release_Singlethreaded"
+# PROP BASE Intermediate_Dir "freetype___Win32_Release_Singlethreaded"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "..\..\..\objs\release_st"
+# PROP Intermediate_Dir "..\..\..\objs\release_st"
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /MD /Za /W4 /GX /Zi /O2 /I "..\..\..\include" /D "NDEBUG" /D "WIN32" /D "_MBCS" /D "_LIB" /FD /c
+# SUBTRACT BASE CPP /YX
+# ADD CPP /Za /W4 /GX /O2 /I "..\..\..\include" /D "NDEBUG" /D "WIN32" /D "_MBCS" /D "_LIB" /D "FT2_BUILD_LIBRARY" /FD /c
+# SUBTRACT CPP /nologo /Z<none> /YX
+# ADD BASE RSC /l 0x409 /d "NDEBUG"
+# ADD RSC /l 0x409 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LIB32=link.exe -lib
+# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype2312.lib"
+# ADD LIB32 /out:"..\..\..\objs\freetype2312ST.lib"
+# SUBTRACT LIB32 /nologo
+
+!ELSEIF "$(CFG)" == "freetype - Win32 Debug Singlethreaded"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "freetype___Win32_Debug_Singlethreaded"
+# PROP BASE Intermediate_Dir "freetype___Win32_Debug_Singlethreaded"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "..\..\..\objs\debug_st"
+# PROP Intermediate_Dir "..\..\..\objs\debug_st"
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /MDd /Za /W4 /Gm /GX /Zi /Od /I "..\..\..\include" /D "_DEBUG" /D "WIN32" /D "_MBCS" /D "_LIB" /D "FT_DEBUG_LEVEL_ERROR" /D "FT_DEBUG_LEVEL_TRACE" /FD /GZ /c
+# SUBTRACT BASE CPP /X /YX
+# ADD CPP /Za /W4 /GX /Z7 /Od /I "..\..\..\include" /D "_DEBUG" /D "FT_DEBUG_LEVEL_ERROR" /D "FT_DEBUG_LEVEL_TRACE" /D "WIN32" /D "_MBCS" /D "_LIB" /D "FT2_BUILD_LIBRARY" /FD /GZ /c
+# SUBTRACT CPP /nologo /X /YX
+# ADD BASE RSC /l 0x409 /d "_DEBUG"
+# ADD RSC /l 0x409 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LIB32=link.exe -lib
+# ADD BASE LIB32 /nologo /out:"..\..\..\objs\freetype2312_D.lib"
+# ADD LIB32 /nologo /out:"..\..\..\objs\freetype2312ST_D.lib"
+
+!ENDIF
+
+# Begin Target
+
+# Name "freetype - Win32 Release"
+# Name "freetype - Win32 Debug"
+# Name "freetype - Win32 Debug Multithreaded"
+# Name "freetype - Win32 Release Multithreaded"
+# Name "freetype - Win32 Release Singlethreaded"
+# Name "freetype - Win32 Debug Singlethreaded"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# Begin Source File
+
+SOURCE=..\..\..\src\autofit\autofit.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\bdf\bdf.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\cff\cff.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftbase.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftbbox.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftbdf.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftbitmap.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftfstype.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftgasp.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\cache\ftcache.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\ftdebug.c
+# ADD CPP /Ze
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftglyph.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftgxval.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\gzip\ftgzip.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftinit.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\lzw\ftlzw.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftmm.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftotval.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftpfr.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftstroke.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftsynth.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftsystem.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\fttype1.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftwinfnt.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\base\ftxf86.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\pcf\pcf.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\pfr\pfr.c
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\psaux\psaux.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\pshinter\pshinter.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\psnames\psmodule.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\raster\raster.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\sfnt\sfnt.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\smooth\smooth.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\truetype\truetype.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\type1\type1.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\cid\type1cid.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\type42\type42.c
+# SUBTRACT CPP /Fr
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\src\winfonts\winfnt.c
+# SUBTRACT CPP /Fr
+# End Source File
+# End Group
+# Begin Group "Header Files"
+
+# PROP Default_Filter "h;hpp;hxx;hm;inl"
+# Begin Source File
+
+SOURCE=..\..\..\include\ft2build.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\include\freetype\config\ftconfig.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\include\freetype\config\ftheader.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\include\freetype\config\ftmodule.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\include\freetype\config\ftoption.h
+# End Source File
+# Begin Source File
+
+SOURCE=..\..\..\include\freetype\config\ftstdlib.h
+# End Source File
+# End Group
+# End Target
+# End Project
diff --git a/src/3rdparty/freetype/builds/win32/visualce/freetype.dsw b/src/3rdparty/freetype/builds/win32/visualce/freetype.dsw
new file mode 100644
index 0000000000..b1b375dbbc
--- /dev/null
+++ b/src/3rdparty/freetype/builds/win32/visualce/freetype.dsw
@@ -0,0 +1,29 @@
+Microsoft Developer Studio Workspace File, Format Version 6.00
+# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
+
+###############################################################################
+
+Project: "freetype"=.\freetype.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+}}}
+
+###############################################################################
+
+Global:
+
+Package=<5>
+{{{
+}}}
+
+Package=<3>
+{{{
+}}}
+
+###############################################################################
+
diff --git a/src/3rdparty/freetype/builds/win32/visualce/index.html b/src/3rdparty/freetype/builds/win32/visualce/index.html
new file mode 100644
index 0000000000..f4ac4945c1
--- /dev/null
+++ b/src/3rdparty/freetype/builds/win32/visualce/index.html
@@ -0,0 +1,47 @@
+<html>
+<header>
+<title>
+ FreeType&nbsp;2 Project Files for Visual&nbsp;C++ and VS.NET&nbsp;2005
+ (Pocket PC)
+</title>
+
+<body>
+<h1>
+ FreeType&nbsp;2 Project Files for Visual&nbsp;C++ and VS.NET&nbsp;2005
+ (Pocket PC)
+</h1>
+
+<p>This directory contains project files for Visual C++, named
+<tt>freetype.dsp</tt>, and Visual Studio, called <tt>freetype.sln</tt> for
+the following targets:
+
+<ul>
+ <li>PPC/SP 2003 (Pocket PC 2003)</li>
+ <li>PPC/SP WM5 (Windows Mobile 5)</li>
+ <li>PPC/SP WM6 (Windows Mobile 6)</li>
+</ul>
+
+It compiles the following libraries from the FreeType 2.3.12 sources:</p>
+
+<ul>
+ <pre>
+ freetype2312.lib - release build; single threaded
+ freetype2312_D.lib - debug build; single threaded
+ freetype2312MT.lib - release build; multi-threaded
+ freetype2312MT_D.lib - debug build; multi-threaded</pre>
+</ul>
+
+<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
+archives are already stored this way, so no further action is required. If
+you use some <tt>.tar.*z</tt> archives, be sure to configure your extracting
+tool to convert the line endings. For example, with <a
+href="http://www.winzip.com">WinZip</a>, you should activate the <it>TAR
+file smart CR/LF Conversion</it> option. Alternatively, you may consider
+using the <tt>unix2dos</tt> or <tt>u2d</tt> utilities that are floating
+around, which specifically deal with this particular problem.
+
+<p>Build directories are placed in the top-level <tt>objs</tt>
+directory.</p>
+
+</body>
+</html>
diff --git a/src/3rdparty/freetype/builds/win32/win32-def.mk b/src/3rdparty/freetype/builds/win32/win32-def.mk
index a82b146bf9..e6ae31c3b2 100644
--- a/src/3rdparty/freetype/builds/win32/win32-def.mk
+++ b/src/3rdparty/freetype/builds/win32/win32-def.mk
@@ -22,6 +22,7 @@ PLATFORM := win32
# The executable file extension (for tools). NOTE: WE INCLUDE THE DOT HERE !!
#
E := .exe
+E_BUILD := .exe
# The directory where all library files are placed.
diff --git a/src/3rdparty/freetype/builds/wince/ftdebug.c b/src/3rdparty/freetype/builds/wince/ftdebug.c
index 8f7a9ab07d..272415d3d0 100644
--- a/src/3rdparty/freetype/builds/wince/ftdebug.c
+++ b/src/3rdparty/freetype/builds/wince/ftdebug.c
@@ -2,9 +2,9 @@
/* */
/* ftdebug.c */
/* */
-/* Debugging and logging component for Win32 (body). */
+/* Debugging and logging component for WinCE (body). */
/* */
-/* Copyright 1996-2001, 2002, 2005, 2008 by */
+/* Copyright 1996-2001, 2002, 2005, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -55,8 +55,6 @@
#include <windows.h>
-#ifdef _WIN32_WCE
-
void
OutputDebugStringEx( const char* str )
{
@@ -71,12 +69,6 @@
OutputDebugStringW( buf );
}
-#else
-
-#define OutputDebugStringEx OutputDebugStringA
-
-#endif
-
FT_BASE_DEF( void )
FT_Message( const char* fmt, ... )
@@ -149,19 +141,15 @@
FT_BASE_DEF( void )
ft_debug_init( void )
{
-#ifdef _WIN32_WCE
-
/* Windows Mobile doesn't have environment API: */
/* GetEnvironmentStrings, GetEnvironmentVariable, getenv. */
/* */
/* FIXME!!! How to set debug mode? */
- const char* ft2_debug = 0;
-#else
+ /* const char* ft2_debug = getenv( "FT2_DEBUG" ); */
- const char* ft2_debug = getenv( "FT2_DEBUG" );
+ const char* ft2_debug = 0;
-#endif
if ( ft2_debug )
{
diff --git a/src/3rdparty/freetype/builds/wince/vc2005-ce/freetype.vcproj b/src/3rdparty/freetype/builds/wince/vc2005-ce/freetype.vcproj
index fcb9a8d626..14d00e7ccf 100644
--- a/src/3rdparty/freetype/builds/wince/vc2005-ce/freetype.vcproj
+++ b/src/3rdparty/freetype/builds/wince/vc2005-ce/freetype.vcproj
@@ -21,7 +21,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -41,7 +41,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -61,7 +61,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -81,7 +81,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -101,7 +101,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -121,7 +121,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -141,7 +141,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -161,7 +161,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -181,7 +181,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -201,7 +201,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -221,7 +221,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -241,7 +241,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -261,7 +261,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239ST.lib" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312ST.lib" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -281,7 +281,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239ST.lib" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312ST.lib" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -301,7 +301,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239ST.lib" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312ST.lib" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -321,7 +321,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239ST.lib" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312ST.lib" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -341,7 +341,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239ST.lib" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312ST.lib" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -361,7 +361,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239ST.lib" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312ST.lib" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -381,7 +381,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -401,7 +401,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -421,7 +421,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -441,7 +441,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -461,7 +461,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -481,7 +481,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -501,7 +501,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239ST_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312ST_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -521,7 +521,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239ST_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312ST_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -541,7 +541,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239ST_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312ST_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -561,7 +561,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239ST_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312ST_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -581,7 +581,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239ST_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312ST_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -601,7 +601,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239ST_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312ST_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -621,7 +621,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -641,7 +641,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -661,7 +661,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -681,7 +681,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -701,7 +701,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -721,7 +721,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -741,7 +741,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="NDEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -758,7 +758,7 @@
<Tool Name="VCManagedResourceCompilerTool" />
<Tool Name="VCResourceCompilerTool" PreprocessorDefinitions="_DEBUG" Culture="1033" />
<Tool Name="VCPreLinkEventTool" />
- <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype239MT_D.lib" SuppressStartupBanner="true" />
+ <Tool Name="VCLibrarianTool" OutputFile="..\..\..\objs\wince\vc2005-ce\freetype2312MT_D.lib" SuppressStartupBanner="true" />
<Tool Name="VCALinkTool" />
<Tool Name="VCXDCMakeTool" />
<Tool Name="VCBscMakeTool" />
@@ -2131,6 +2131,14 @@
<Filter Name="FT_MODULES">
<File RelativePath="..\..\..\src\base\ftbbox.c">
</File>
+ <File RelativePath="..\..\..\src\base\ftbdf.c">
+ </File>
+ <File RelativePath="..\..\..\src\base\ftcid.c">
+ </File>
+ <File RelativePath="..\..\..\src\base\ftgxval.c">
+ </File>
+ <File RelativePath="..\..\..\src\base\ftlcdfil.c">
+ </File>
<File RelativePath="..\..\..\src\base\ftmm.c">
<FileConfiguration Name="Release|Pocket PC 2003 (ARMV4)">
<Tool Name="VCCLCompilerTool" Optimization="2" AdditionalIncludeDirectories="" PreprocessorDefinitions="" />
@@ -2259,6 +2267,10 @@
<Tool Name="VCCLCompilerTool" Optimization="0" AdditionalIncludeDirectories="" PreprocessorDefinitions="" BasicRuntimeChecks="3" />
</FileConfiguration>
</File>
+ <File RelativePath="..\..\..\src\base\ftotval.c">
+ </File>
+ <File RelativePath="..\..\..\src\base\ftpatent.c">
+ </File>
<File RelativePath="..\..\..\src\base\ftpfr.c">
</File>
<File RelativePath="..\..\..\src\base\ftsynth.c">
@@ -2267,6 +2279,8 @@
</File>
<File RelativePath="..\..\..\src\base\ftwinfnt.c">
</File>
+ <File RelativePath="..\..\..\src\base\ftxf86.c">
+ </File>
<File RelativePath="..\..\..\src\pcf\pcf.c">
<FileConfiguration Name="Release|Pocket PC 2003 (ARMV4)">
<Tool Name="VCCLCompilerTool" Optimization="2" AdditionalIncludeDirectories="" PreprocessorDefinitions="" />
diff --git a/src/3rdparty/freetype/builds/wince/vc2005-ce/index.html b/src/3rdparty/freetype/builds/wince/vc2005-ce/index.html
index 780ce41a4a..5d0e2b7d30 100644
--- a/src/3rdparty/freetype/builds/wince/vc2005-ce/index.html
+++ b/src/3rdparty/freetype/builds/wince/vc2005-ce/index.html
@@ -21,14 +21,14 @@ the following targets:
<li>PPC/SP WM6 (Windows Mobile 6)</li>
</ul>
-It compiles the following libraries from the FreeType 2.3.9 sources:</p>
+It compiles the following libraries from the FreeType 2.3.12 sources:</p>
<ul>
<pre>
- freetype239.lib - release build; single threaded
- freetype239_D.lib - debug build; single threaded
- freetype239MT.lib - release build; multi-threaded
- freetype239MT_D.lib - debug build; multi-threaded</pre>
+ freetype2312.lib - release build; single threaded
+ freetype2312_D.lib - debug build; single threaded
+ freetype2312MT.lib - release build; multi-threaded
+ freetype2312MT_D.lib - debug build; multi-threaded</pre>
</ul>
<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
diff --git a/src/3rdparty/freetype/builds/wince/vc2008-ce/freetype.vcproj b/src/3rdparty/freetype/builds/wince/vc2008-ce/freetype.vcproj
index 2233577f97..2529f7e518 100644
--- a/src/3rdparty/freetype/builds/wince/vc2008-ce/freetype.vcproj
+++ b/src/3rdparty/freetype/builds/wince/vc2008-ce/freetype.vcproj
@@ -88,7 +88,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -177,7 +177,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -266,7 +266,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -355,7 +355,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -444,7 +444,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -533,7 +533,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -621,7 +621,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -709,7 +709,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -797,7 +797,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -885,7 +885,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -973,7 +973,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -1061,7 +1061,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -1149,7 +1149,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239ST.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312ST.lib"
/>
<Tool
Name="VCALinkTool"
@@ -1236,7 +1236,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239ST.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312ST.lib"
/>
<Tool
Name="VCALinkTool"
@@ -1323,7 +1323,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239ST.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312ST.lib"
/>
<Tool
Name="VCALinkTool"
@@ -1410,7 +1410,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239ST.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312ST.lib"
/>
<Tool
Name="VCALinkTool"
@@ -1497,7 +1497,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239ST.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312ST.lib"
/>
<Tool
Name="VCALinkTool"
@@ -1584,7 +1584,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239ST.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312ST.lib"
/>
<Tool
Name="VCALinkTool"
@@ -1668,7 +1668,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -1753,7 +1753,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -1838,7 +1838,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -1923,7 +1923,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -2008,7 +2008,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -2093,7 +2093,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -2178,7 +2178,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239ST_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312ST_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -2263,7 +2263,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239ST_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312ST_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -2348,7 +2348,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239ST_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312ST_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -2433,7 +2433,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239ST_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312ST_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -2518,7 +2518,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239ST_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312ST_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -2603,7 +2603,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239ST_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312ST_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -2689,7 +2689,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -2775,7 +2775,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -2861,7 +2861,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -2947,7 +2947,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -3033,7 +3033,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -3119,7 +3119,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -3205,7 +3205,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -3279,7 +3279,7 @@
/>
<Tool
Name="VCLibrarianTool"
- OutputFile="..\..\..\objs\wince\vc2008-ce\freetype239MT_D.lib"
+ OutputFile="..\..\..\objs\wince\vc2008-ce\freetype2312MT_D.lib"
SuppressStartupBanner="true"
/>
<Tool
@@ -7864,6 +7864,22 @@
>
</File>
<File
+ RelativePath="..\..\..\src\base\ftbdf.c"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\src\base\ftcid.c"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\src\base\ftgxval.c"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\src\base\ftlcdfil.c"
+ >
+ </File>
+ <File
RelativePath="..\..\..\src\base\ftmm.c"
>
<FileConfiguration
@@ -8291,6 +8307,14 @@
</FileConfiguration>
</File>
<File
+ RelativePath="..\..\..\src\base\ftotval.c"
+ >
+ </File>
+ <File
+ RelativePath="..\..\..\src\base\ftpatent.c"
+ >
+ </File>
+ <File
RelativePath="..\..\..\src\base\ftpfr.c"
>
</File>
@@ -8307,6 +8331,10 @@
>
</File>
<File
+ RelativePath="..\..\..\src\base\ftxf86.c"
+ >
+ </File>
+ <File
RelativePath="..\..\..\src\pcf\pcf.c"
>
<FileConfiguration
diff --git a/src/3rdparty/freetype/builds/wince/vc2008-ce/index.html b/src/3rdparty/freetype/builds/wince/vc2008-ce/index.html
index 20e576f85c..781e05f11d 100644
--- a/src/3rdparty/freetype/builds/wince/vc2008-ce/index.html
+++ b/src/3rdparty/freetype/builds/wince/vc2008-ce/index.html
@@ -21,14 +21,14 @@ the following targets:
<li>PPC/SP WM6 (Windows Mobile 6)</li>
</ul>
-It compiles the following libraries from the FreeType 2.3.9 sources:</p>
+It compiles the following libraries from the FreeType 2.3.12 sources:</p>
<ul>
<pre>
- freetype239.lib - release build; single threaded
- freetype239_D.lib - debug build; single threaded
- freetype239MT.lib - release build; multi-threaded
- freetype239MT_D.lib - debug build; multi-threaded</pre>
+ freetype2312.lib - release build; single threaded
+ freetype2312_D.lib - debug build; single threaded
+ freetype2312MT.lib - release build; multi-threaded
+ freetype2312MT_D.lib - debug build; multi-threaded</pre>
</ul>
<p>Be sure to extract the files with the Windows (CR+LF) line endings. ZIP
diff --git a/src/3rdparty/freetype/configure b/src/3rdparty/freetype/configure
index b59d35d07e..2efa269679 100755
--- a/src/3rdparty/freetype/configure
+++ b/src/3rdparty/freetype/configure
@@ -1,6 +1,6 @@
#!/bin/sh
#
-# Copyright 2002, 2003, 2004, 2005, 2006, 2008 by
+# Copyright 2002, 2003, 2004, 2005, 2006, 2008, 2009 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -67,12 +67,25 @@ ft2_dir=`(dirname "$0") 2>/dev/null ||
abs_curr_dir=`pwd`
abs_ft2_dir=`cd "$ft2_dir" && pwd`
+# `--srcdir=' option can override abs_ft2_dir
+
+if test $# -gt 0; then
+ for x in "$@"; do
+ case x"$x" in
+ x--srcdir=*)
+ abs_ft2_dir=`echo $x | sed 's/^--srcdir=//'` ;;
+ esac
+ done
+fi
+
# build a dummy Makefile if we are not building in the source tree
if test "$abs_curr_dir" != "$abs_ft2_dir"; then
mkdir reference
- echo "Copying \`modules.cfg'"
- cp $abs_ft2_dir/modules.cfg $abs_curr_dir
+ if test ! -r $abs_curr_dir/modules.cfg; then
+ echo "Copying \`modules.cfg'"
+ cp $abs_ft2_dir/modules.cfg $abs_curr_dir
+ fi
echo "Generating \`Makefile'"
echo "TOP_DIR := $abs_ft2_dir" > Makefile
echo "OBJ_DIR := $abs_curr_dir" >> Makefile
@@ -96,7 +109,10 @@ CFG=
case $# in
0) ;;
*) for x in "$@"; do
- CFG="$CFG '$x'"
+ case x"$x" in
+ x--srcdir=* ) CFG="$CFG '$x'/builds/unix" ;;
+ *) CFG="$CFG '$x'" ;;
+ esac
done ;;
esac
CFG=$CFG $GNUMAKE setup unix
diff --git a/src/3rdparty/freetype/devel/ftoption.h b/src/3rdparty/freetype/devel/ftoption.h
index f7f7fcc169..9c6c2fe459 100644
--- a/src/3rdparty/freetype/devel/ftoption.h
+++ b/src/3rdparty/freetype/devel/ftoption.h
@@ -4,7 +4,8 @@
/* */
/* User-selectable configuration macros (specification only). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, */
+/* 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -85,9 +86,9 @@ FT_BEGIN_HEADER
/* */
/* This macro has no impact on the FreeType API, only on its */
/* _implementation_. For example, using FT_RENDER_MODE_LCD when calling */
- /* FT_Render_Glyph still generates a bitmap that is 3 times larger than */
- /* the original size; the difference will be that each triplet of */
- /* subpixels has R=G=B. */
+ /* FT_Render_Glyph still generates a bitmap that is 3 times wider than */
+ /* the original size in case this macro isn't defined; however, each */
+ /* triplet of subpixels has R=G=B. */
/* */
/* This is done to allow FreeType clients to run unmodified, forcing */
/* them to display normal gray-level anti-aliased glyphs. */
@@ -112,7 +113,7 @@ FT_BEGIN_HEADER
/* file `ftconfig.h' either statically or through the */
/* `configure' script on supported platforms. */
/* */
-#undef FT_CONFIG_OPTION_FORCE_INT64
+#undef FT_CONFIG_OPTION_FORCE_INT64
/*************************************************************************/
@@ -184,7 +185,7 @@ FT_BEGIN_HEADER
/* Do not #undef this macro here since the build system might define */
/* it for certain configurations only. */
/* */
-/* #define FT_CONFIG_OPTION_SYSTEM_ZLIB */
+/* #define FT_CONFIG_OPTION_SYSTEM_ZLIB */
/*************************************************************************/
@@ -225,20 +226,20 @@ FT_BEGIN_HEADER
/* Do not #undef these macros here since the build system might define */
/* them for certain configurations only. */
/* */
-/* #define FT_EXPORT(x) extern x */
-/* #define FT_EXPORT_DEF(x) x */
+/* #define FT_EXPORT(x) extern x */
+/* #define FT_EXPORT_DEF(x) x */
/*************************************************************************/
/* */
/* Glyph Postscript Names handling */
/* */
- /* By default, FreeType 2 is compiled with the `PSNames' module. This */
+ /* By default, FreeType 2 is compiled with the `psnames' module. This */
/* module is in charge of converting a glyph name string into a */
/* Unicode value, or return a Macintosh standard glyph name for the */
/* use with the TrueType `post' table. */
/* */
- /* Undefine this macro if you do not want `PSNames' compiled in your */
+ /* Undefine this macro if you do not want `psnames' compiled in your */
/* build of FreeType. This has the following effects: */
/* */
/* - The TrueType driver will provide its own set of glyph names, */
@@ -312,10 +313,11 @@ FT_BEGIN_HEADER
/* */
/* Allow the use of FT_Incremental_Interface to load typefaces that */
/* contain no glyph data, but supply it via a callback function. */
- /* This allows FreeType to be used with the PostScript language, using */
- /* the GhostScript interpreter. */
+ /* This is required by clients supporting document formats which */
+ /* supply font data incrementally as the document is parsed, such */
+ /* as the Ghostscript interpreter for the PostScript language. */
/* */
-/* #define FT_CONFIG_OPTION_INCREMENTAL */
+#define FT_CONFIG_OPTION_INCREMENTAL
/*************************************************************************/
@@ -396,6 +398,20 @@ FT_BEGIN_HEADER
#undef FT_CONFIG_OPTION_USE_MODULE_ERRORS
+ /*************************************************************************/
+ /* */
+ /* Position Independent Code */
+ /* */
+ /* If this macro is set (which is _not_ the default), FreeType2 will */
+ /* avoid creating constants that require address fixups. Instead the */
+ /* constants will be moved into a struct and additional intialization */
+ /* code will be used. */
+ /* */
+ /* Setting this macro is needed for systems that prohibit address */
+ /* fixups, such as BREW. */
+ /* */
+/* #define FT_CONFIG_OPTION_PIC */
+
/*************************************************************************/
/*************************************************************************/
@@ -439,7 +455,7 @@ FT_BEGIN_HEADER
/* does not contain any glyph name though. */
/* */
/* Accessing SFNT names is done through the functions declared in */
- /* `freetype/ftnames.h'. */
+ /* `freetype/ftsnames.h'. */
/* */
#define TT_CONFIG_OPTION_SFNT_NAMES
@@ -457,6 +473,7 @@ FT_BEGIN_HEADER
#define TT_CONFIG_CMAP_FORMAT_8
#define TT_CONFIG_CMAP_FORMAT_10
#define TT_CONFIG_CMAP_FORMAT_12
+#define TT_CONFIG_CMAP_FORMAT_13
#define TT_CONFIG_CMAP_FORMAT_14
@@ -651,7 +668,6 @@ FT_BEGIN_HEADER
/* */
#define AF_CONFIG_OPTION_CJK
-
/*************************************************************************/
/* */
/* Compile autofit module with Indic script support. */
@@ -671,11 +687,11 @@ FT_BEGIN_HEADER
* is recommended to disable the macro since it reduces the library's code
* size and activates a few memory-saving optimizations as well.
*/
-#undef FT_CONFIG_OPTION_OLD_INTERNALS
+/* #define FT_CONFIG_OPTION_OLD_INTERNALS */
/*
- * This variable is defined if either unpatented or native TrueType
+ * This macro is defined if either unpatented or native TrueType
* hinting is requested by the definitions above.
*/
#ifdef TT_CONFIG_OPTION_BYTECODE_INTERPRETER
diff --git a/src/3rdparty/freetype/docs/CHANGES b/src/3rdparty/freetype/docs/CHANGES
index 9eb68c2924..018d16c577 100644
--- a/src/3rdparty/freetype/docs/CHANGES
+++ b/src/3rdparty/freetype/docs/CHANGES
@@ -1,3 +1,82 @@
+CHANGES BETWEEN 2.3.11 and 2.3.12
+
+ I. IMPORTANT CHANGES
+
+ - For `FT_Open_Face', new parameters are available to ignore
+ preferred family names: FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY and
+ FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY.
+
+ II. MISCELLANEOUS
+
+ - Support for incremental font loading (controlled with the
+ FT_CONFIG_OPTION_INCREMENTAL macro) is now active by default.
+
+ - Better support for vertical metrics.
+
+ - Various minor bug fixes.
+
+
+======================================================================
+
+CHANGES BETWEEN 2.3.10 and 2.3.11
+
+ I. IMPORTANT BUG FIXES
+
+ - Version 2.3.10 broke PCF support.
+
+
+======================================================================
+
+CHANGES BETWEEN 2.3.10 and 2.3.9
+
+ I. IMPORTANT BUG FIXES
+
+ - If all ASCII digits in a font have the same (unscaled) width,
+ the autohinter respects this and won't change it.
+
+ - TrueType fonts are now rasterized correctly if the horizontal
+ and vertical resolution differ.
+
+ - Type 1 fonts are now handled with increased precision internally
+ to avoid serious rounding issues if non-integral coordinates are
+ encountered.
+
+ - Horizontally condensed CFF fonts (using the font matrix) were
+ rendered incorrectly. This bug has been introduced after
+ release 2.3.5.
+
+
+ II. IMPORTANT CHANGES
+
+ - Support for the SFNT cmap 13 table format (as defined by the new
+ OpenType 1.6 specification) has been added.
+
+ - B/W rasterization of well-hinted TrueType fonts at small sizes
+ has been greatly improved.
+
+ - Calculation of vertical metrics in OpenType fonts has been
+ improved.
+
+
+ III. MISCELLANEOUS
+
+ - It is now possible to change the emboldening factor in the
+ `ftview' demo program with keys `e' and `E'.
+
+ - It is now possible to change the slant value in the `ftview'
+ demo program with keys `s' and `S'.
+
+ - The 5-levels grayscale mode of the `ftraster' module (which
+ FreeType doesn't use by default) was broken since version 2.3.0.
+
+ - Compilation of the `ftgrays' and `ftraster' modules was broken
+ in stand-alone mode.
+
+ - Various fixes for compilation on 64bit and 16bit architectures.
+
+
+======================================================================
+
CHANGES BETWEEN 2.3.9 and 2.3.8
I. IMPORTANT BUG FIXES
diff --git a/src/3rdparty/freetype/docs/DEBUG b/src/3rdparty/freetype/docs/DEBUG
index 1fccc21c46..3d6acd3bb0 100644
--- a/src/3rdparty/freetype/docs/DEBUG
+++ b/src/3rdparty/freetype/docs/DEBUG
@@ -92,7 +92,10 @@ its code:
The value of the FT_COMPONENT macro is an enumeration named
trace_XXXX where XXXX is one of the component names defined in the
- internal file `freetype/internal/fttrace.h'.
+ internal file `freetype/internal/fttrace.h'. If you modify FreeType
+ source and insert new trace_XXXX macro, you must register it in
+ fttrace.h. If you insert or remove many trace macros, you can check
+ the undefined or the unused trace macro by src/tools/chktrcmp.py.
Each such component is assigned a `debug level', ranging from 0
to 7, through the use of the FT2_DEBUG environment variable
@@ -186,7 +189,7 @@ behaviour of FreeType at runtime.
------------------------------------------------------------------------
-Copyright 2002, 2003, 2004, 2005 by
+Copyright 2002, 2003, 2004, 2005, 2009 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used,
diff --git a/src/3rdparty/freetype/docs/INSTALL.ANY b/src/3rdparty/freetype/docs/INSTALL.ANY
index 86e94d585f..44b785c67e 100644
--- a/src/3rdparty/freetype/docs/INSTALL.ANY
+++ b/src/3rdparty/freetype/docs/INSTALL.ANY
@@ -127,10 +127,10 @@ II. Support for flat-directory compilation
2. Compile sources
- cc -c -Ifreetype2/include ftsystem.c
- cc -c -Ifreetype2/include ftinit.c
- cc -c -Ifreetype2/include ftdebug.c
- cc -c -Ifreetype2/include ftbase.c
+ cc -c -Ifreetype2/include -DFT2_BUILD_LIBRARY ftsystem.c
+ cc -c -Ifreetype2/include -DFT2_BUILD_LIBRARY ftinit.c
+ cc -c -Ifreetype2/include -DFT2_BUILD_LIBRARY ftdebug.c
+ cc -c -Ifreetype2/include -DFT2_BUILD_LIBRARY ftbase.c
etc.
You don't need to define the FT_FLAT_COMPILATION macro (as this
@@ -138,7 +138,7 @@ II. Support for flat-directory compilation
----------------------------------------------------------------------
-Copyright 2003, 2005, 2006, 2009 by
+Copyright 2003, 2005, 2006, 2009, 2010 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used,
diff --git a/src/3rdparty/freetype/docs/LICENSE.TXT b/src/3rdparty/freetype/docs/LICENSE.TXT
index 102a03d651..abebbcc780 100644
--- a/src/3rdparty/freetype/docs/LICENSE.TXT
+++ b/src/3rdparty/freetype/docs/LICENSE.TXT
@@ -20,9 +20,12 @@ any of your projects or products.
GPL. Note that the FTL is incompatible with the GPL due to its
advertisement clause.
-The contributed PCF driver comes with a license similar to that of the X
-Window System. It is compatible to the above two licenses (see file
-src/pcf/readme).
+The contributed BDF and PCF drivers come with a license similar to that
+of the X Window System. It is compatible to the above two licenses (see
+file src/bdf/README and src/pcf/README).
+
+The gzip module uses the zlib license (see src/gzip/zlib.h) which too is
+compatible to the above two licenses.
--- end of LICENSE.TXT ---
diff --git a/src/3rdparty/freetype/docs/VERSION.DLL b/src/3rdparty/freetype/docs/VERSION.DLL
index 6b028b12f9..bb55c3dda9 100644
--- a/src/3rdparty/freetype/docs/VERSION.DLL
+++ b/src/3rdparty/freetype/docs/VERSION.DLL
@@ -53,6 +53,9 @@ systems, but not all of them:
release libtool so
-------------------------------
+ 2.3.12 10.0.4 6.4.0
+ 2.3.11 9.22.3 6.3.22
+ 2.3.10 9.21.3 6.3.21
2.3.9 9.20.3 6.3.20
2.3.8 9.19.3 6.3.19
2.3.7 9.18.3 6.3.18
@@ -122,7 +125,7 @@ other release numbers.
------------------------------------------------------------------------
-Copyright 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by
+Copyright 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used,
diff --git a/src/3rdparty/freetype/docs/reference/ft2-base_interface.html b/src/3rdparty/freetype/docs/reference/ft2-base_interface.html
index 27f454b675..08f2a81b84 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-base_interface.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-base_interface.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Base Interface
@@ -78,6 +78,14 @@ Base Interface
<table align=center width="75%"><tr><td>
<h4><a name="FT_Library">FT_Library</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_LibraryRec_ *<b>FT_Library</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a FreeType library instance. Each &lsquo;library&rsquo; is completely independent from the others; it is the &lsquo;root&rsquo; of a set of objects like fonts, faces, sizes, etc.</p>
<p>It also embeds a memory manager (see <a href="ft2-system_interface.html#FT_Memory">FT_Memory</a>), as well as a scan-line converter object (see <a href="ft2-raster.html#FT_Raster">FT_Raster</a>).</p>
<p>For multi-threading applications each thread should have its own FT_Library object.</p>
@@ -94,6 +102,14 @@ Base Interface
<table align=center width="75%"><tr><td>
<h4><a name="FT_Face">FT_Face</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_FaceRec_* <b>FT_Face</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a given typographic face object. A face object models a given typeface, in a given style.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
@@ -113,6 +129,14 @@ Base Interface
<table align=center width="75%"><tr><td>
<h4><a name="FT_Size">FT_Size</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_SizeRec_* <b>FT_Size</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to an object used to model a face scaled to a given character size.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
@@ -132,6 +156,14 @@ Base Interface
<table align=center width="75%"><tr><td>
<h4><a name="FT_GlyphSlot">FT_GlyphSlot</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_GlyphSlotRec_* <b>FT_GlyphSlot</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a given &lsquo;glyph slot&rsquo;. A slot is a container where it is possible to load any of the glyphs contained in its parent face.</p>
<p>In other words, each time you call <a href="ft2-base_interface.html#FT_Load_Glyph">FT_Load_Glyph</a> or <a href="ft2-base_interface.html#FT_Load_Char">FT_Load_Char</a>, the slot's content is erased by the new glyph data, i.e., the glyph's metrics, its image (bitmap or outline), and other control information.</p>
</td></tr></table><br>
@@ -147,6 +179,14 @@ Base Interface
<table align=center width="75%"><tr><td>
<h4><a name="FT_CharMap">FT_CharMap</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_CharMapRec_* <b>FT_CharMap</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a given character map. A charmap is used to translate character codes in a given encoding into glyph indexes for its parent's face. Some font formats may provide several charmaps per font.</p>
<p>Each face object owns zero or more charmaps, but only one of them can be &lsquo;active&rsquo; and used by <a href="ft2-base_interface.html#FT_Get_Char_Index">FT_Get_Char_Index</a> or <a href="ft2-base_interface.html#FT_Load_Char">FT_Load_Char</a>.</p>
<p>The list of available charmaps in a face is available through the &lsquo;face-&gt;num_charmaps&rsquo; and &lsquo;face-&gt;charmaps&rsquo; fields of <a href="ft2-base_interface.html#FT_FaceRec">FT_FaceRec</a>.</p>
@@ -207,8 +247,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<p>An enumeration used to specify character sets supported by charmaps. Used in the <a href="ft2-base_interface.html#FT_Select_Charmap">FT_Select_Charmap</a> API function.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
-<p>Despite the name, this enumeration lists specific character repertories (i.e., charsets), and not text encoding methods (e.g., UTF-8, UTF-16, GB2312_EUC, etc.).</p>
-<p>Because of 32-bit charcodes defined in Unicode (i.e., surrogates), all character codes must be expressed as FT_Longs.</p>
+<p>Despite the name, this enumeration lists specific character repertories (i.e., charsets), and not text encoding methods (e.g., UTF-8, UTF-16, etc.).</p>
<p>Other encodings might be defined in the future.</p>
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>values</b></em></td></tr><tr><td>
@@ -219,6 +258,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</td></tr>
<tr valign=top><td><b>FT_ENCODING_UNICODE</b></td><td>
<p>Corresponds to the Unicode character set. This value covers all versions of the Unicode repertoire, including ASCII and Latin-1. Most fonts include a Unicode charmap, but not all of them.</p>
+<p>For example, if you want to access Unicode value U+1F028 (and the font contains it), use value 0x1F028 as the input value for <a href="ft2-base_interface.html#FT_Get_Char_Index">FT_Get_Char_Index</a>.</p>
</td></tr>
<tr valign=top><td><b>FT_ENCODING_MS_SYMBOL</b></td><td>
<p>Corresponds to the Microsoft Symbol encoding, used to encode mathematical symbols in the 32..255 character code range. For more information, see &lsquo;http://www.ceviz.net/symbol.htm&rsquo;.</p>
@@ -349,6 +389,9 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</td></tr>
</table>
</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
+<p>If not disabled with <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_HINTING</a>, the values represent dimensions of the hinted glyph (in case hinting is applicable).</p>
+</td></tr></table>
</td></tr></table>
<hr width="75%">
<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
@@ -411,6 +454,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_Module">FT_Module</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_ModuleRec_* <b>FT_Module</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a given FreeType module object. Each module can be a font driver, a renderer, or anything else that provides services to the formers.</p>
</td></tr></table><br>
</td></tr></table>
@@ -422,6 +473,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_Driver">FT_Driver</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_DriverRec_* <b>FT_Driver</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a given FreeType font driver object. Each font driver is a special module capable of creating faces from font files.</p>
</td></tr></table><br>
</td></tr></table>
@@ -433,6 +492,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_Renderer">FT_Renderer</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_RendererRec_* <b>FT_Renderer</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a given FreeType renderer. A renderer is a special module in charge of converting a glyph image to a bitmap, when necessary. Each renderer supports a given glyph image format, and one or more target surface depths.</p>
</td></tr></table><br>
</td></tr></table>
@@ -553,6 +620,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_Face_Internal">FT_Face_Internal</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_Face_InternalRec_* <b>FT_Face_Internal</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>An opaque handle to an &lsquo;FT_Face_InternalRec&rsquo; structure, used to model private data of a given <a href="ft2-base_interface.html#FT_Face">FT_Face</a> object.</p>
<p>This structure might change between releases of FreeType&nbsp;2 and is not generally available to client applications.</p>
</td></tr></table><br>
@@ -955,6 +1030,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_HAS_FAST_GLYPHS">FT_HAS_FAST_GLYPHS</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_HAS_FAST_GLYPHS</b>( face ) 0
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>Deprecated.</p>
</td></tr></table><br>
</td></tr></table>
@@ -1081,6 +1164,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_Size_Internal">FT_Size_Internal</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_Size_InternalRec_* <b>FT_Size_Internal</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>An opaque handle to an &lsquo;FT_Size_InternalRec&rsquo; structure, used to model private data of a given <a href="ft2-base_interface.html#FT_Size">FT_Size</a> object.</p>
</td></tr></table><br>
</td></tr></table>
@@ -1199,6 +1290,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_SubGlyph">FT_SubGlyph</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_SubGlyphRec_* <b>FT_SubGlyph</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>The subglyph structure is an internal object used to describe subglyphs (for example, in the case of composites).</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
@@ -1214,6 +1313,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_Slot_Internal">FT_Slot_Internal</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_Slot_InternalRec_* <b>FT_Slot_Internal</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>An opaque handle to an &lsquo;FT_Slot_InternalRec&rsquo; structure, used to model private data of a given <a href="ft2-base_interface.html#FT_GlyphSlot">FT_GlyphSlot</a> object.</p>
</td></tr></table><br>
</td></tr></table>
@@ -1295,7 +1402,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<p>The advance height of the unhinted glyph. Its value is expressed in 16.16 fractional pixels, unless <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_LINEAR_DESIGN</a> is set when loading the glyph. This field can be important to perform correct WYSIWYG layout. Only relevant for outline glyphs.</p>
</td></tr>
<tr valign=top><td><b>advance</b></td><td>
-<p>This is the transformed advance width for the glyph (in 26.6 fractional pixel format).</p>
+<p>This shorthand is, depending on <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_TRANSFORM</a>, the transformed advance width for the glyph (in 26.6 fractional pixel format). As specified with <a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_VERTICAL_LAYOUT</a>, it uses either the &lsquo;horiAdvance&rsquo; or the &lsquo;vertAdvance&rsquo; value of &lsquo;metrics&rsquo; field.</p>
</td></tr>
<tr valign=top><td><b>format</b></td><td>
<p>This field indicates the format of the image contained in the glyph slot. Typically <a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_BITMAP</a>, <a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_OUTLINE</a>, or <a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_COMPOSITE</a>, but others are possible.</p>
@@ -1398,6 +1505,9 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>return</b></em></td></tr><tr><td>
<p>FreeType error code. 0&nbsp;means success.</p>
</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
+<p>In case you want to provide your own memory allocating routines, use <a href="ft2-module_management.html#FT_New_Library">FT_New_Library</a> instead, followed by a call to <a href="ft2-module_management.html#FT_Add_Default_Modules">FT_Add_Default_Modules</a> (or a series of calls to <a href="ft2-module_management.html#FT_Add_Module">FT_Add_Module</a>).</p>
+</td></tr></table>
</td></tr></table>
<hr width="75%">
<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
@@ -1532,7 +1642,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
</table>
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
-<p>The ID and function of parameters are driver-specific.</p>
+<p>The ID and function of parameters are driver-specific. See the various FT_PARAM_TAG_XXX flags for more information.</p>
</td></tr></table>
</td></tr></table>
<hr width="75%">
@@ -2045,6 +2155,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_Size_Request">FT_Size_Request</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_Size_RequestRec_ *<b>FT_Size_Request</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a size request structure.</p>
</td></tr></table><br>
</td></tr></table>
@@ -2457,6 +2575,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_LOAD_TARGET_MODE">FT_LOAD_TARGET_MODE</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_LOAD_TARGET_MODE</b>( x ) ( (<a href="ft2-base_interface.html#FT_Render_Mode">FT_Render_Mode</a>)( ( (x) &gt;&gt; 16 ) &amp; 15 ) )
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>Return the <a href="ft2-base_interface.html#FT_Render_Mode">FT_Render_Mode</a> corresponding to a given <a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_XXX</a> value.</p>
</td></tr></table><br>
</td></tr></table>
@@ -2678,6 +2804,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="ft_kerning_default">ft_kerning_default</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>ft_kerning_default</b> <a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_DEFAULT</a>
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>This constant is deprecated. Please use <a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_DEFAULT</a> instead.</p>
</td></tr></table><br>
</td></tr></table>
@@ -2689,6 +2823,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="ft_kerning_unfitted">ft_kerning_unfitted</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>ft_kerning_unfitted</b> <a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_UNFITTED</a>
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>This constant is deprecated. Please use <a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_UNFITTED</a> instead.</p>
</td></tr></table><br>
</td></tr></table>
@@ -2700,6 +2842,14 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
<table align=center width="75%"><tr><td>
<h4><a name="ft_kerning_unscaled">ft_kerning_unscaled</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_FREETYPE_H (freetype/freetype.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>ft_kerning_unscaled</b> <a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_UNSCALED</a>
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>This constant is deprecated. Please use <a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_UNSCALED</a> instead.</p>
</td></tr></table><br>
</td></tr></table>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-basic_types.html b/src/3rdparty/freetype/docs/reference/ft2-basic_types.html
index 9e77145b6a..8df510ffb8 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-basic_types.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-basic_types.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Basic Data Types
@@ -64,6 +64,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Byte">FT_Byte</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">unsigned</span> <span class="keyword">char</span> <b>FT_Byte</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A simple typedef for the <i>unsigned</i> char type.</p>
</td></tr></table><br>
</td></tr></table>
@@ -75,6 +83,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Bytes">FT_Bytes</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">const</span> <a href="ft2-basic_types.html#FT_Byte">FT_Byte</a>* <b>FT_Bytes</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A typedef for constant memory areas.</p>
</td></tr></table><br>
</td></tr></table>
@@ -86,6 +102,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Char">FT_Char</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">signed</span> <span class="keyword">char</span> <b>FT_Char</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A simple typedef for the <i>signed</i> char type.</p>
</td></tr></table><br>
</td></tr></table>
@@ -97,6 +121,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Int">FT_Int</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">signed</span> <span class="keyword">int</span> <b>FT_Int</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A typedef for the int type.</p>
</td></tr></table><br>
</td></tr></table>
@@ -108,6 +140,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_UInt">FT_UInt</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">unsigned</span> <span class="keyword">int</span> <b>FT_UInt</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A typedef for the unsigned int type.</p>
</td></tr></table><br>
</td></tr></table>
@@ -119,6 +159,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Int16">FT_Int16</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_CONFIG_CONFIG_H (freetype/config/ftconfig.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">signed</span> <span class="keyword">short</span> <b>FT_Int16</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A typedef for a 16bit signed integer type.</p>
</td></tr></table><br>
</td></tr></table>
@@ -130,6 +178,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_UInt16">FT_UInt16</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_CONFIG_CONFIG_H (freetype/config/ftconfig.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">unsigned</span> <span class="keyword">short</span> <b>FT_UInt16</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A typedef for a 16bit unsigned integer type.</p>
</td></tr></table><br>
</td></tr></table>
@@ -141,6 +197,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Int32">FT_Int32</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_CONFIG_CONFIG_H (freetype/config/ftconfig.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">signed</span> XXX <b>FT_Int32</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A typedef for a 32bit signed integer type. The size depends on the configuration.</p>
</td></tr></table><br>
</td></tr></table>
@@ -151,6 +215,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_UInt32">FT_UInt32</a></h4>
+<table align=center width="87%"><tr><td>
+Defined in FT_CONFIG_CONFIG_H (freetype/config/ftconfig.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">unsigned</span> XXX <b>FT_UInt32</b>;
+
+</pre></table><br>
</td></tr></table>
<hr width="75%">
<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
@@ -160,6 +232,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Short">FT_Short</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">signed</span> <span class="keyword">short</span> <b>FT_Short</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A typedef for signed short.</p>
</td></tr></table><br>
</td></tr></table>
@@ -171,6 +251,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_UShort">FT_UShort</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">unsigned</span> <span class="keyword">short</span> <b>FT_UShort</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A typedef for unsigned short.</p>
</td></tr></table><br>
</td></tr></table>
@@ -182,6 +270,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Long">FT_Long</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">signed</span> <span class="keyword">long</span> <b>FT_Long</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A typedef for signed long.</p>
</td></tr></table><br>
</td></tr></table>
@@ -193,6 +289,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_ULong">FT_ULong</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">unsigned</span> <span class="keyword">long</span> <b>FT_ULong</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A typedef for unsigned long.</p>
</td></tr></table><br>
</td></tr></table>
@@ -204,6 +308,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Bool">FT_Bool</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">unsigned</span> <span class="keyword">char</span> <b>FT_Bool</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A typedef of unsigned char, used for simple booleans. As usual, values 1 and&nbsp;0 represent true and false, respectively.</p>
</td></tr></table><br>
</td></tr></table>
@@ -215,6 +327,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Offset">FT_Offset</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> size_t <b>FT_Offset</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>This is equivalent to the ANSI&nbsp;C &lsquo;size_t&rsquo; type, i.e., the largest <i>unsigned</i> integer type used to express a file size or position, or a memory block size.</p>
</td></tr></table><br>
</td></tr></table>
@@ -226,6 +346,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_PtrDist">FT_PtrDist</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> ft_ptrdiff_t <b>FT_PtrDist</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>This is equivalent to the ANSI&nbsp;C &lsquo;ptrdiff_t&rsquo; type, i.e., the largest <i>signed</i> integer type used to express the distance between two pointers.</p>
</td></tr></table><br>
</td></tr></table>
@@ -237,6 +365,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_String">FT_String</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">char</span> <b>FT_String</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A simple typedef for the char type, usually used for strings.</p>
</td></tr></table><br>
</td></tr></table>
@@ -248,6 +384,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Tag">FT_Tag</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <a href="ft2-basic_types.html#FT_UInt32">FT_UInt32</a> <b>FT_Tag</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A typedef for 32-bit tags (as used in the SFNT format).</p>
</td></tr></table><br>
</td></tr></table>
@@ -259,6 +403,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Error">FT_Error</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">int</span> <b>FT_Error</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>The FreeType error code type. A value of&nbsp;0 is always interpreted as a successful operation.</p>
</td></tr></table><br>
</td></tr></table>
@@ -270,6 +422,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Fixed">FT_Fixed</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">signed</span> <span class="keyword">long</span> <b>FT_Fixed</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>This type is used to store 16.16 fixed float values, like scaling values or matrix coefficients.</p>
</td></tr></table><br>
</td></tr></table>
@@ -281,6 +441,14 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Pointer">FT_Pointer</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">void</span>* <b>FT_Pointer</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A simple typedef for a typeless pointer.</p>
</td></tr></table><br>
</td></tr></table>
@@ -292,7 +460,15 @@ Basic Data Types
<table align=center width="75%"><tr><td>
<h4><a name="FT_Pos">FT_Pos</a></h4>
<table align=center width="87%"><tr><td>
-<p>The type FT_Pos is a 32-bit integer used to store vectorial coordinates. Depending on the context, these can represent distances in integer font units, or 16.16, or 26.6 fixed float pixel coordinates.</p>
+Defined in FT_IMAGE_H (freetype/ftimage.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">signed</span> <span class="keyword">long</span> <b>FT_Pos</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
+<p>The type FT_Pos is used to store vectorial coordinates. Depending on the context, these can represent distances in integer font units, or 16.16, or 26.6 fixed float pixel coordinates.</p>
</td></tr></table><br>
</td></tr></table>
<hr width="75%">
@@ -370,6 +546,11 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
</td></tr>
</table>
</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
+<p>The bounding box is specified with the coordinates of the lower left and the upper right corner. In PostScript, those values are often called (llx,lly) and (urx,ury), respectively.</p>
+<p>If &lsquo;yMin&rsquo; is negative, this value gives the glyph's descender. Otherwise, the glyph doesn't descend below the baseline. Similarly, if &lsquo;ymax&rsquo; is positive, this value gives the glyph's ascender.</p>
+<p>&lsquo;xMin&rsquo; gives the horizontal distance from the glyph's origin to the left edge of the glyph's bounding box. If &lsquo;xMin&rsquo; is negative, the glyph extends to the left of the origin.</p>
+</td></tr></table>
</td></tr></table>
<hr width="75%">
<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
@@ -424,6 +605,14 @@ Defined in FT_TYPES_H (freetype/fttypes.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_FWord">FT_FWord</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">signed</span> <span class="keyword">short</span> <b>FT_FWord</b>; /* distance in FUnits */
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A signed 16-bit integer used to store a distance in original font units.</p>
</td></tr></table><br>
</td></tr></table>
@@ -435,6 +624,14 @@ Defined in FT_TYPES_H (freetype/fttypes.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_UFWord">FT_UFWord</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">unsigned</span> <span class="keyword">short</span> <b>FT_UFWord</b>; /* <span class="keyword">unsigned</span> distance */
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>An unsigned 16-bit integer used to store a distance in original font units.</p>
</td></tr></table><br>
</td></tr></table>
@@ -446,6 +643,14 @@ Defined in FT_TYPES_H (freetype/fttypes.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_F2Dot14">FT_F2Dot14</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">signed</span> <span class="keyword">short</span> <b>FT_F2Dot14</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A signed 2.14 fixed float type used for unit vectors.</p>
</td></tr></table><br>
</td></tr></table>
@@ -492,6 +697,14 @@ Defined in FT_TYPES_H (freetype/fttypes.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_F26Dot6">FT_F26Dot6</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">signed</span> <span class="keyword">long</span> <b>FT_F26Dot6</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A signed 26.6 fixed float type used for vectorial pixel coordinates.</p>
</td></tr></table><br>
</td></tr></table>
@@ -676,6 +889,7 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
</td></tr>
<tr valign=top><td><b>pitch</b></td><td>
<p>The pitch's absolute value is the number of bytes taken by one bitmap row, including padding. However, the pitch is positive when the bitmap has a &lsquo;down&rsquo; flow, and negative when it has an &lsquo;up&rsquo; flow. In all cases, the pitch is an offset to add to a bitmap pointer in order to go down one row.</p>
+<p>For the B/W rasterizer, &lsquo;pitch&rsquo; is always an even number.</p>
</td></tr>
<tr valign=top><td><b>buffer</b></td><td>
<p>A typeless pointer to the bitmap buffer. This value should be aligned on 32-bit boundaries in most cases.</p>
@@ -870,6 +1084,14 @@ Defined in FT_TYPES_H (freetype/fttypes.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_Generic_Finalizer">FT_Generic_Finalizer</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">void</span> (*<b>FT_Generic_Finalizer</b>)(<span class="keyword">void</span>* object);
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>Describe a function used to destroy the &lsquo;client&rsquo; data of any FreeType object. See the description of the <a href="ft2-basic_types.html#FT_Generic">FT_Generic</a> type for details of usage.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>input</b></em></td></tr><tr><td>
@@ -926,6 +1148,7 @@ Defined in FT_TYPES_H (freetype/fttypes.h).
<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
#define <b>FT_MAKE_TAG</b>( _x1, _x2, _x3, _x4 ) \
+ (<a href="ft2-basic_types.html#FT_Tag">FT_Tag</a>) \
( ( (<a href="ft2-basic_types.html#FT_ULong">FT_ULong</a>)_x1 &lt;&lt; 24 ) | \
( (<a href="ft2-basic_types.html#FT_ULong">FT_ULong</a>)_x2 &lt;&lt; 16 ) | \
( (<a href="ft2-basic_types.html#FT_ULong">FT_ULong</a>)_x3 &lt;&lt; 8 ) | \
diff --git a/src/3rdparty/freetype/docs/reference/ft2-bdf_fonts.html b/src/3rdparty/freetype/docs/reference/ft2-bdf_fonts.html
index e7bf5a09bd..293cd81a6f 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-bdf_fonts.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-bdf_fonts.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
BDF and PCF Files
@@ -97,6 +97,14 @@ Defined in FT_BDF_H (freetype/ftbdf.h).
<table align=center width="75%"><tr><td>
<h4><a name="BDF_Property">BDF_Property</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_BDF_H (freetype/ftbdf.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> BDF_PropertyRec_* <b>BDF_Property</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a <a href="ft2-bdf_fonts.html#BDF_PropertyRec">BDF_PropertyRec</a> structure to model a given BDF/PCF property.</p>
</td></tr></table><br>
</td></tr></table>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-bitmap_handling.html b/src/3rdparty/freetype/docs/reference/ft2-bitmap_handling.html
index 5fd64d7a00..dc1df69e95 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-bitmap_handling.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-bitmap_handling.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Bitmap Handling
diff --git a/src/3rdparty/freetype/docs/reference/ft2-cache_subsystem.html b/src/3rdparty/freetype/docs/reference/ft2-cache_subsystem.html
index 8cf3b5a855..96815a017d 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-cache_subsystem.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-cache_subsystem.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Cache Sub-System
@@ -76,6 +76,14 @@ Cache Sub-System
<table align=center width="75%"><tr><td>
<h4><a name="FTC_Manager">FTC_Manager</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_CACHE_H (freetype/ftcache.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FTC_ManagerRec_* <b>FTC_Manager</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>This object corresponds to one instance of the cache-subsystem. It is used to cache one or more <a href="ft2-base_interface.html#FT_Face">FT_Face</a> objects, along with corresponding <a href="ft2-base_interface.html#FT_Size">FT_Size</a> objects.</p>
<p>The manager intentionally limits the total number of opened <a href="ft2-base_interface.html#FT_Face">FT_Face</a> and <a href="ft2-base_interface.html#FT_Size">FT_Size</a> objects to control memory usage. See the &lsquo;max_faces&rsquo; and &lsquo;max_sizes&rsquo; parameters of <a href="ft2-cache_subsystem.html#FTC_Manager_New">FTC_Manager_New</a>.</p>
<p>The manager is also used to cache &lsquo;nodes&rsquo; of various types while limiting their total memory usage.</p>
@@ -90,6 +98,14 @@ Cache Sub-System
<table align=center width="75%"><tr><td>
<h4><a name="FTC_FaceID">FTC_FaceID</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_CACHE_H (freetype/ftcache.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <a href="ft2-basic_types.html#FT_Pointer">FT_Pointer</a> <b>FTC_FaceID</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>An opaque pointer type that is used to identity face objects. The contents of such objects is application-dependent.</p>
<p>These pointers are typically used to point to a user-defined structure containing a font file path, and face index.</p>
</td></tr></table><br>
@@ -160,6 +176,14 @@ Defined in FT_CACHE_H (freetype/ftcache.h).
<table align=center width="75%"><tr><td>
<h4><a name="FTC_Node">FTC_Node</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_CACHE_H (freetype/ftcache.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FTC_NodeRec_* <b>FTC_Node</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>An opaque handle to a cache node object. Each cache node is reference-counted. A node with a count of&nbsp;0 might be flushed out of a full cache whenever a lookup request is performed.</p>
<p>If you lookup nodes, you have the ability to &lsquo;acquire&rsquo; them, i.e., to increment their reference count. This will prevent the node from being flushed out of the cache until you explicitly &lsquo;release&rsquo; it (see <a href="ft2-cache_subsystem.html#FTC_Node_Unref">FTC_Node_Unref</a>).</p>
<p>See also <a href="ft2-cache_subsystem.html#FTC_SBitCache_Lookup">FTC_SBitCache_Lookup</a> and <a href="ft2-cache_subsystem.html#FTC_ImageCache_Lookup">FTC_ImageCache_Lookup</a>.</p>
@@ -394,6 +418,14 @@ Defined in FT_CACHE_H (freetype/ftcache.h).
<table align=center width="75%"><tr><td>
<h4><a name="FTC_Scaler">FTC_Scaler</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_CACHE_H (freetype/ftcache.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FTC_ScalerRec_* <b>FTC_Scaler</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to an <a href="ft2-cache_subsystem.html#FTC_ScalerRec">FTC_ScalerRec</a> structure.</p>
</td></tr></table><br>
</td></tr></table>
@@ -525,6 +557,14 @@ Defined in FT_CACHE_H (freetype/ftcache.h).
<table align=center width="75%"><tr><td>
<h4><a name="FTC_CMapCache">FTC_CMapCache</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_CACHE_H (freetype/ftcache.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FTC_CMapCacheRec_* <b>FTC_CMapCache</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>An opaque handle used to model a charmap cache. This cache is to hold character codes -&gt; glyph indices mappings.</p>
</td></tr></table><br>
</td></tr></table>
@@ -665,6 +705,14 @@ Defined in FT_CACHE_H (freetype/ftcache.h).
<table align=center width="75%"><tr><td>
<h4><a name="FTC_ImageType">FTC_ImageType</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_CACHE_H (freetype/ftcache.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FTC_ImageTypeRec_* <b>FTC_ImageType</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to an <a href="ft2-cache_subsystem.html#FTC_ImageTypeRec">FTC_ImageTypeRec</a> structure.</p>
</td></tr></table><br>
</td></tr></table>
@@ -676,6 +724,14 @@ Defined in FT_CACHE_H (freetype/ftcache.h).
<table align=center width="75%"><tr><td>
<h4><a name="FTC_ImageCache">FTC_ImageCache</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_CACHE_H (freetype/ftcache.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FTC_ImageCacheRec_* <b>FTC_ImageCache</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to an glyph image cache object. They are designed to hold many distinct glyph images while not exceeding a certain memory threshold.</p>
</td></tr></table><br>
</td></tr></table>
@@ -846,6 +902,14 @@ Defined in FT_CACHE_H (freetype/ftcache.h).
<table align=center width="75%"><tr><td>
<h4><a name="FTC_SBit">FTC_SBit</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_CACHE_H (freetype/ftcache.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FTC_SBitRec_* <b>FTC_SBit</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a small bitmap descriptor. See the <a href="ft2-cache_subsystem.html#FTC_SBitRec">FTC_SBitRec</a> structure for details.</p>
</td></tr></table><br>
</td></tr></table>
@@ -926,6 +990,14 @@ Defined in FT_CACHE_H (freetype/ftcache.h).
<table align=center width="75%"><tr><td>
<h4><a name="FTC_SBitCache">FTC_SBitCache</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_CACHE_H (freetype/ftcache.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FTC_SBitCacheRec_* <b>FTC_SBitCache</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a small bitmap cache. These are special cache objects used to store small glyph bitmaps (and anti-aliased pixmaps) in a much more efficient way than the traditional glyph image cache implemented by <a href="ft2-cache_subsystem.html#FTC_ImageCache">FTC_ImageCache</a>.</p>
</td></tr></table><br>
</td></tr></table>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-cid_fonts.html b/src/3rdparty/freetype/docs/reference/ft2-cid_fonts.html
index 2749e55047..37aa4b4bd9 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-cid_fonts.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-cid_fonts.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
CID Fonts
diff --git a/src/3rdparty/freetype/docs/reference/ft2-computations.html b/src/3rdparty/freetype/docs/reference/ft2-computations.html
index 608139011c..37db13cd28 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-computations.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-computations.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Computations
@@ -379,6 +379,14 @@ Defined in FT_GLYPH_H (freetype/ftglyph.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_Angle">FT_Angle</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TRIGONOMETRY_H (freetype/fttrigon.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <a href="ft2-basic_types.html#FT_Fixed">FT_Fixed</a> <b>FT_Angle</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>This type is used to model angle values in FreeType. Note that the angle is a 16.16 fixed float value expressed in degrees.</p>
</td></tr></table><br>
</td></tr></table>
@@ -390,6 +398,14 @@ Defined in FT_GLYPH_H (freetype/ftglyph.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_ANGLE_PI">FT_ANGLE_PI</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TRIGONOMETRY_H (freetype/fttrigon.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_ANGLE_PI</b> ( 180L &lt;&lt; 16 )
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>The angle pi expressed in <a href="ft2-computations.html#FT_Angle">FT_Angle</a> units.</p>
</td></tr></table><br>
</td></tr></table>
@@ -401,6 +417,14 @@ Defined in FT_GLYPH_H (freetype/ftglyph.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_ANGLE_2PI">FT_ANGLE_2PI</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TRIGONOMETRY_H (freetype/fttrigon.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_ANGLE_2PI</b> ( <a href="ft2-computations.html#FT_ANGLE_PI">FT_ANGLE_PI</a> * 2 )
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>The angle 2*pi expressed in <a href="ft2-computations.html#FT_Angle">FT_Angle</a> units.</p>
</td></tr></table><br>
</td></tr></table>
@@ -412,6 +436,14 @@ Defined in FT_GLYPH_H (freetype/ftglyph.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_ANGLE_PI2">FT_ANGLE_PI2</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TRIGONOMETRY_H (freetype/fttrigon.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_ANGLE_PI2</b> ( <a href="ft2-computations.html#FT_ANGLE_PI">FT_ANGLE_PI</a> / 2 )
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>The angle pi/2 expressed in <a href="ft2-computations.html#FT_Angle">FT_Angle</a> units.</p>
</td></tr></table><br>
</td></tr></table>
@@ -423,6 +455,14 @@ Defined in FT_GLYPH_H (freetype/ftglyph.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_ANGLE_PI4">FT_ANGLE_PI4</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TRIGONOMETRY_H (freetype/fttrigon.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_ANGLE_PI4</b> ( <a href="ft2-computations.html#FT_ANGLE_PI">FT_ANGLE_PI</a> / 4 )
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>The angle pi/4 expressed in <a href="ft2-computations.html#FT_Angle">FT_Angle</a> units.</p>
</td></tr></table><br>
</td></tr></table>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-font_formats.html b/src/3rdparty/freetype/docs/reference/ft2-font_formats.html
index 589d749f82..677f5c2ce5 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-font_formats.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-font_formats.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Font Formats
@@ -47,6 +47,7 @@ Font Formats
<table align=center width="87%"><tr><td>
<p>The single function in this section can be used to get the font format. Note that this information is not needed normally; however, there are special cases (like in PDF devices) where it is important to differentiate, in spite of FreeType's uniform API.</p>
+<p>This function is in the X11/xf86 namespace for historical reasons and in no way depends on that windowing system.</p>
</td></tr></table><br>
<table align=center width="75%"><tr><td>
<h4><a name="FT_Get_X11_Font_Format">FT_Get_X11_Font_Format</a></h4>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-gasp_table.html b/src/3rdparty/freetype/docs/reference/ft2-gasp_table.html
index 2f0d2f50c2..613cb65452 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-gasp_table.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-gasp_table.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Gasp Table
diff --git a/src/3rdparty/freetype/docs/reference/ft2-glyph_management.html b/src/3rdparty/freetype/docs/reference/ft2-glyph_management.html
index 79fc5b6d22..65335e8a4d 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-glyph_management.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-glyph_management.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Glyph Management
@@ -55,6 +55,14 @@ Glyph Management
<table align=center width="75%"><tr><td>
<h4><a name="FT_Glyph">FT_Glyph</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_GLYPH_H (freetype/ftglyph.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_GlyphRec_* <b>FT_Glyph</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>Handle to an object used to model generic glyph images. It is a pointer to the <a href="ft2-glyph_management.html#FT_GlyphRec">FT_GlyphRec</a> structure and can contain a glyph bitmap or pointer.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
@@ -112,6 +120,14 @@ Defined in FT_GLYPH_H (freetype/ftglyph.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_BitmapGlyph">FT_BitmapGlyph</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_GLYPH_H (freetype/ftglyph.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_BitmapGlyphRec_* <b>FT_BitmapGlyph</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to an object used to model a bitmap glyph image. This is a sub-class of <a href="ft2-glyph_management.html#FT_Glyph">FT_Glyph</a>, and a pointer to <a href="ft2-glyph_management.html#FT_BitmapGlyphRec">FT_BitmapGlyphRec</a>.</p>
</td></tr></table><br>
</td></tr></table>
@@ -170,6 +186,14 @@ Defined in FT_GLYPH_H (freetype/ftglyph.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_OutlineGlyph">FT_OutlineGlyph</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_GLYPH_H (freetype/ftglyph.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_OutlineGlyphRec_* <b>FT_OutlineGlyph</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to an object used to model an outline glyph image. This is a sub-class of <a href="ft2-glyph_management.html#FT_Glyph">FT_Glyph</a>, and a pointer to <a href="ft2-glyph_management.html#FT_OutlineGlyphRec">FT_OutlineGlyphRec</a>.</p>
</td></tr></table><br>
</td></tr></table>
@@ -558,7 +582,7 @@ Defined in FT_GLYPH_H (freetype/ftglyph.h).
// convert to a bitmap (default render mode + destroying old)
if ( glyph-&gt;format != FT_GLYPH_FORMAT_BITMAP )
{
- error = FT_Glyph_To_Bitmap( &amp;glyph, FT_RENDER_MODE_DEFAULT,
+ error = FT_Glyph_To_Bitmap( &amp;glyph, FT_RENDER_MODE_NORMAL,
0, 1 );
if ( error ) // `glyph' unchanged
...
diff --git a/src/3rdparty/freetype/docs/reference/ft2-glyph_stroker.html b/src/3rdparty/freetype/docs/reference/ft2-glyph_stroker.html
index f5f24e4467..9f0eb06663 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-glyph_stroker.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-glyph_stroker.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Glyph Stroker
@@ -62,6 +62,14 @@ Glyph Stroker
<table align=center width="75%"><tr><td>
<h4><a name="FT_Stroker">FT_Stroker</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_STROKER_H (freetype/ftstroke.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_StrokerRec_* <b>FT_Stroker</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>Opaque handler to a path stroker object.</p>
</td></tr></table><br>
</td></tr></table>
@@ -770,7 +778,7 @@ Defined in FT_STROKER_H (freetype/ftstroke.h).
</pre></table><br>
<table align=center width="87%"><tr><td>
-<p>Call this function after <a href="ft2-glyph_stroker.html#FT_Stroker_GetBorderCounts">FT_Stroker_GetBorderCounts</a> to export the all borders to your own <a href="ft2-outline_processing.html#FT_Outline">FT_Outline</a> structure.</p>
+<p>Call this function after <a href="ft2-glyph_stroker.html#FT_Stroker_GetBorderCounts">FT_Stroker_GetBorderCounts</a> to export all borders to your own <a href="ft2-outline_processing.html#FT_Outline">FT_Outline</a> structure.</p>
<p>Note that this function appends the border points and contours to your outline, but does not try to resize its arrays.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>input</b></em></td></tr><tr><td>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-glyph_variants.html b/src/3rdparty/freetype/docs/reference/ft2-glyph_variants.html
index 499c7e76fc..b59ce8a8d5 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-glyph_variants.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-glyph_variants.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Glyph Variants
diff --git a/src/3rdparty/freetype/docs/reference/ft2-gx_validation.html b/src/3rdparty/freetype/docs/reference/ft2-gx_validation.html
index 8c3a98f30d..cd7184ce4a 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-gx_validation.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-gx_validation.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
TrueTypeGX/AAT Validation
@@ -53,6 +53,14 @@ TrueTypeGX/AAT Validation
<table align=center width="75%"><tr><td>
<h4><a name="FT_VALIDATE_GX_LENGTH">FT_VALIDATE_GX_LENGTH</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_GX_VALIDATE_H (freetype/ftgxval.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_VALIDATE_GX_LENGTH</b> (FT_VALIDATE_GX_LAST_INDEX + 1)
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>The number of tables checked in this module. Use it as a parameter for the &lsquo;table-length&rsquo; argument of function <a href="ft2-gx_validation.html#FT_TrueTypeGX_Validate">FT_TrueTypeGX_Validate</a>.</p>
</td></tr></table><br>
</td></tr></table>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-gzip.html b/src/3rdparty/freetype/docs/reference/ft2-gzip.html
index f9eca6a338..2c442e8fc7 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-gzip.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-gzip.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
GZIP Streams
diff --git a/src/3rdparty/freetype/docs/reference/ft2-header_file_macros.html b/src/3rdparty/freetype/docs/reference/ft2-header_file_macros.html
index f81f2f915a..44593c31d5 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-header_file_macros.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-header_file_macros.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Header File Macros
@@ -151,6 +151,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_FREETYPE_H">FT_FREETYPE_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_FREETYPE_H</b> &lt;freetype/freetype.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the base FreeType&nbsp;2 API.</p>
</td></tr></table><br>
@@ -162,6 +167,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_ERRORS_H">FT_ERRORS_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_ERRORS_H</b> &lt;freetype/fterrors.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the list of FreeType&nbsp;2 error codes (and messages).</p>
<p>It is included by <a href="ft2-header_file_macros.html#FT_FREETYPE_H">FT_FREETYPE_H</a>.</p>
@@ -174,6 +184,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_MODULE_ERRORS_H">FT_MODULE_ERRORS_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_MODULE_ERRORS_H</b> &lt;freetype/ftmoderr.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the list of FreeType&nbsp;2 module error offsets (and messages).</p>
</td></tr></table><br>
@@ -185,6 +200,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_SYSTEM_H">FT_SYSTEM_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_SYSTEM_H</b> &lt;freetype/ftsystem.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the FreeType&nbsp;2 interface to low-level operations (i.e., memory management and stream i/o).</p>
<p>It is included by <a href="ft2-header_file_macros.html#FT_FREETYPE_H">FT_FREETYPE_H</a>.</p>
@@ -197,6 +217,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_IMAGE_H">FT_IMAGE_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_IMAGE_H</b> &lt;freetype/ftimage.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing type definitions related to glyph images (i.e., bitmaps, outlines, scan-converter parameters).</p>
<p>It is included by <a href="ft2-header_file_macros.html#FT_FREETYPE_H">FT_FREETYPE_H</a>.</p>
@@ -209,6 +234,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_TYPES_H">FT_TYPES_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_TYPES_H</b> &lt;freetype/fttypes.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the basic data types defined by FreeType&nbsp;2.</p>
<p>It is included by <a href="ft2-header_file_macros.html#FT_FREETYPE_H">FT_FREETYPE_H</a>.</p>
@@ -221,6 +251,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_LIST_H">FT_LIST_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_LIST_H</b> &lt;freetype/ftlist.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the list management API of FreeType&nbsp;2.</p>
<p>(Most applications will never need to include this file.)</p>
@@ -233,6 +268,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_OUTLINE_H">FT_OUTLINE_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_OUTLINE_H</b> &lt;freetype/ftoutln.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the scalable outline management API of FreeType&nbsp;2.</p>
</td></tr></table><br>
@@ -244,6 +284,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_SIZES_H">FT_SIZES_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_SIZES_H</b> &lt;freetype/ftsizes.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the API which manages multiple <a href="ft2-base_interface.html#FT_Size">FT_Size</a> objects per face.</p>
</td></tr></table><br>
@@ -255,6 +300,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_MODULE_H">FT_MODULE_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_MODULE_H</b> &lt;freetype/ftmodapi.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the module management API of FreeType&nbsp;2.</p>
</td></tr></table><br>
@@ -266,6 +316,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_RENDER_H">FT_RENDER_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_RENDER_H</b> &lt;freetype/ftrender.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the renderer module management API of FreeType&nbsp;2.</p>
</td></tr></table><br>
@@ -277,6 +332,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_TYPE1_TABLES_H">FT_TYPE1_TABLES_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_TYPE1_TABLES_H</b> &lt;freetype/t1tables.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the types and API specific to the Type&nbsp;1 format.</p>
</td></tr></table><br>
@@ -288,6 +348,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_TRUETYPE_IDS_H">FT_TRUETYPE_IDS_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_TRUETYPE_IDS_H</b> &lt;freetype/ttnameid.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the enumeration values which identify name strings, languages, encodings, etc. This file really contains a <i>large</i> set of constant macro definitions, taken from the TrueType and OpenType specifications.</p>
</td></tr></table><br>
@@ -299,6 +364,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_TRUETYPE_TABLES_H">FT_TRUETYPE_TABLES_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_TRUETYPE_TABLES_H</b> &lt;freetype/tttables.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the types and API specific to the TrueType (as well as OpenType) format.</p>
</td></tr></table><br>
@@ -310,6 +380,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_TRUETYPE_TAGS_H">FT_TRUETYPE_TAGS_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_TRUETYPE_TAGS_H</b> &lt;freetype/tttags.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the definitions of TrueType four-byte &lsquo;tags&rsquo; which identify blocks in SFNT-based font formats (i.e., TrueType and OpenType).</p>
</td></tr></table><br>
@@ -321,6 +396,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_BDF_H">FT_BDF_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_BDF_H</b> &lt;freetype/ftbdf.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the definitions of an API which accesses BDF-specific strings from a face.</p>
</td></tr></table><br>
@@ -332,6 +412,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_CID_H">FT_CID_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_CID_H</b> &lt;freetype/ftcid.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the definitions of an API which access CID font information from a face.</p>
</td></tr></table><br>
@@ -343,6 +428,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_GZIP_H">FT_GZIP_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_GZIP_H</b> &lt;freetype/ftgzip.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the definitions of an API which supports gzip-compressed files.</p>
</td></tr></table><br>
@@ -354,6 +444,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_LZW_H">FT_LZW_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_LZW_H</b> &lt;freetype/ftlzw.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the definitions of an API which supports LZW-compressed files.</p>
</td></tr></table><br>
@@ -365,6 +460,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_WINFONTS_H">FT_WINFONTS_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_WINFONTS_H</b> &lt;freetype/ftwinfnt.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the definitions of an API which supports Windows FNT files.</p>
</td></tr></table><br>
@@ -376,6 +476,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_GLYPH_H">FT_GLYPH_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_GLYPH_H</b> &lt;freetype/ftglyph.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the API of the optional glyph management component.</p>
</td></tr></table><br>
@@ -387,6 +492,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_BITMAP_H">FT_BITMAP_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_BITMAP_H</b> &lt;freetype/ftbitmap.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the API of the optional bitmap conversion component.</p>
</td></tr></table><br>
@@ -398,6 +508,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_BBOX_H">FT_BBOX_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_BBOX_H</b> &lt;freetype/ftbbox.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the API of the optional exact bounding box computation routines.</p>
</td></tr></table><br>
@@ -409,6 +524,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_CACHE_H">FT_CACHE_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_CACHE_H</b> &lt;freetype/ftcache.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the API of the optional FreeType&nbsp;2 cache sub-system.</p>
</td></tr></table><br>
@@ -420,6 +540,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_CACHE_IMAGE_H">FT_CACHE_IMAGE_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_CACHE_IMAGE_H</b> <a href="ft2-header_file_macros.html#FT_CACHE_H">FT_CACHE_H</a>
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the &lsquo;glyph image&rsquo; API of the FreeType&nbsp;2 cache sub-system.</p>
<p>It is used to define a cache for <a href="ft2-glyph_management.html#FT_Glyph">FT_Glyph</a> elements. You can also use the API defined in <a href="ft2-header_file_macros.html#FT_CACHE_SMALL_BITMAPS_H">FT_CACHE_SMALL_BITMAPS_H</a> if you only need to store small glyph bitmaps, as it will use less memory.</p>
@@ -433,6 +558,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_CACHE_SMALL_BITMAPS_H">FT_CACHE_SMALL_BITMAPS_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_CACHE_SMALL_BITMAPS_H</b> <a href="ft2-header_file_macros.html#FT_CACHE_H">FT_CACHE_H</a>
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the &lsquo;small bitmaps&rsquo; API of the FreeType&nbsp;2 cache sub-system.</p>
<p>It is used to define a cache for small glyph bitmaps in a relatively memory-efficient way. You can also use the API defined in <a href="ft2-header_file_macros.html#FT_CACHE_IMAGE_H">FT_CACHE_IMAGE_H</a> if you want to cache arbitrary glyph images, including scalable outlines.</p>
@@ -446,6 +576,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_CACHE_CHARMAP_H">FT_CACHE_CHARMAP_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_CACHE_CHARMAP_H</b> <a href="ft2-header_file_macros.html#FT_CACHE_H">FT_CACHE_H</a>
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the &lsquo;charmap&rsquo; API of the FreeType&nbsp;2 cache sub-system.</p>
<p>This macro is deprecated. Simply include <a href="ft2-header_file_macros.html#FT_CACHE_H">FT_CACHE_H</a> to have all charmap-based cache declarations.</p>
@@ -458,6 +593,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_MAC_H">FT_MAC_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_MAC_H</b> &lt;freetype/ftmac.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the Macintosh-specific FreeType&nbsp;2 API. The latter is used to access fonts embedded in resource forks.</p>
<p>This header file must be explicitly included by client applications compiled on the Mac (note that the base API still works though).</p>
@@ -470,6 +610,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_MULTIPLE_MASTERS_H">FT_MULTIPLE_MASTERS_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_MULTIPLE_MASTERS_H</b> &lt;freetype/ftmm.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the optional multiple-masters management API of FreeType&nbsp;2.</p>
</td></tr></table><br>
@@ -481,6 +626,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_SFNT_NAMES_H">FT_SFNT_NAMES_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_SFNT_NAMES_H</b> &lt;freetype/ftsnames.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the optional FreeType&nbsp;2 API which accesses embedded &lsquo;name&rsquo; strings in SFNT-based font formats (i.e., TrueType and OpenType).</p>
</td></tr></table><br>
@@ -492,6 +642,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_OPENTYPE_VALIDATE_H">FT_OPENTYPE_VALIDATE_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_OPENTYPE_VALIDATE_H</b> &lt;freetype/ftotval.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the optional FreeType&nbsp;2 API which validates OpenType tables (BASE, GDEF, GPOS, GSUB, JSTF).</p>
</td></tr></table><br>
@@ -503,6 +658,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_GX_VALIDATE_H">FT_GX_VALIDATE_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_GX_VALIDATE_H</b> &lt;freetype/ftgxval.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the optional FreeType&nbsp;2 API which validates TrueTypeGX/AAT tables (feat, mort, morx, bsln, just, kern, opbd, trak, prop).</p>
</td></tr></table><br>
@@ -514,6 +674,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_PFR_H">FT_PFR_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_PFR_H</b> &lt;freetype/ftpfr.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the FreeType&nbsp;2 API which accesses PFR-specific data.</p>
</td></tr></table><br>
@@ -525,6 +690,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_STROKER_H">FT_STROKER_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_STROKER_H</b> &lt;freetype/ftstroke.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the FreeType&nbsp;2 API which provides functions to stroke outline paths.</p>
</td></tr></table><br>
@@ -536,6 +706,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_SYNTHESIS_H">FT_SYNTHESIS_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_SYNTHESIS_H</b> &lt;freetype/ftsynth.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the FreeType&nbsp;2 API which performs artificial obliquing and emboldening.</p>
</td></tr></table><br>
@@ -547,6 +722,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_XFREE86_H">FT_XFREE86_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_XFREE86_H</b> &lt;freetype/ftxf86.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the FreeType&nbsp;2 API which provides functions specific to the XFree86 and X.Org X11 servers.</p>
</td></tr></table><br>
@@ -558,6 +738,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_TRIGONOMETRY_H">FT_TRIGONOMETRY_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_TRIGONOMETRY_H</b> &lt;freetype/fttrigon.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the FreeType&nbsp;2 API which performs trigonometric computations (e.g., cosines and arc tangents).</p>
</td></tr></table><br>
@@ -569,6 +754,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_LCD_FILTER_H">FT_LCD_FILTER_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_LCD_FILTER_H</b> &lt;freetype/ftlcdfil.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the FreeType&nbsp;2 API which performs color filtering for subpixel rendering.</p>
</td></tr></table><br>
@@ -580,6 +770,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_UNPATENTED_HINTING_H">FT_UNPATENTED_HINTING_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_UNPATENTED_HINTING_H</b> &lt;freetype/ttunpat.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the FreeType&nbsp;2 API which performs color filtering for subpixel rendering.</p>
</td></tr></table><br>
@@ -591,6 +786,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_INCREMENTAL_H">FT_INCREMENTAL_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_INCREMENTAL_H</b> &lt;freetype/ftincrem.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the FreeType&nbsp;2 API which performs color filtering for subpixel rendering.</p>
</td></tr></table><br>
@@ -602,6 +802,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_GASP_H">FT_GASP_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_GASP_H</b> &lt;freetype/ftgasp.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the FreeType&nbsp;2 API which returns entries from the TrueType GASP table.</p>
</td></tr></table><br>
@@ -613,6 +818,11 @@ Header File Macros
<table align=center width="75%"><tr><td>
<h4><a name="FT_ADVANCES_H">FT_ADVANCES_H</a></h4>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_ADVANCES_H</b> &lt;freetype/ftadvanc.h&gt;
+
+</pre></table><br>
<table align=center width="87%"><tr><td>
<p>A macro used in #include statements to name the file containing the FreeType&nbsp;2 API which returns individual and ranged glyph advances.</p>
</td></tr></table><br>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-incremental.html b/src/3rdparty/freetype/docs/reference/ft2-incremental.html
index 8fbc111faf..4fa3b10a31 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-incremental.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-incremental.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Incremental Loading
@@ -57,6 +57,14 @@ Incremental Loading
<table align=center width="75%"><tr><td>
<h4><a name="FT_Incremental">FT_Incremental</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_INCREMENTAL_H (freetype/ftincrem.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_IncrementalRec_* <b>FT_Incremental</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>An opaque type describing a user-provided object used to implement &lsquo;incremental&rsquo; glyph loading within FreeType. This is used to support embedded fonts in certain environments (e.g., PostScript interpreters), where the glyph data isn't in the font file, or must be overridden by different values.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
@@ -81,6 +89,7 @@ Defined in FT_INCREMENTAL_H (freetype/ftincrem.h).
<a href="ft2-basic_types.html#FT_Long">FT_Long</a> bearing_x;
<a href="ft2-basic_types.html#FT_Long">FT_Long</a> bearing_y;
<a href="ft2-basic_types.html#FT_Long">FT_Long</a> advance;
+ <a href="ft2-basic_types.html#FT_Long">FT_Long</a> advance_v; /* since 2.3.12 */
} <b>FT_Incremental_MetricsRec</b>;
@@ -98,7 +107,10 @@ Defined in FT_INCREMENTAL_H (freetype/ftincrem.h).
<p>Top bearing, in font units.</p>
</td></tr>
<tr valign=top><td><b>advance</b></td><td>
-<p>Glyph advance, in font units.</p>
+<p>Horizontal component of glyph advance, in font units.</p>
+</td></tr>
+<tr valign=top><td><b>advance_v</b></td><td>
+<p>Vertical component of glyph advance, in font units.</p>
</td></tr>
</table>
</td></tr></table>
@@ -114,6 +126,14 @@ Defined in FT_INCREMENTAL_H (freetype/ftincrem.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_Incremental_Metrics">FT_Incremental_Metrics</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_INCREMENTAL_H (freetype/ftincrem.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_Incremental_MetricsRec_* <b>FT_Incremental_Metrics</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to an <a href="ft2-incremental.html#FT_Incremental_MetricsRec">FT_Incremental_MetricsRec</a> structure.</p>
</td></tr></table><br>
</td></tr></table>
@@ -342,6 +362,14 @@ Defined in FT_INCREMENTAL_H (freetype/ftincrem.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_Incremental_Interface">FT_Incremental_Interface</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_INCREMENTAL_H (freetype/ftincrem.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <a href="ft2-incremental.html#FT_Incremental_InterfaceRec">FT_Incremental_InterfaceRec</a>* <b>FT_Incremental_Interface</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A pointer to an <a href="ft2-incremental.html#FT_Incremental_InterfaceRec">FT_Incremental_InterfaceRec</a> structure.</p>
</td></tr></table><br>
</td></tr></table>
@@ -353,6 +381,14 @@ Defined in FT_INCREMENTAL_H (freetype/ftincrem.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_PARAM_TAG_INCREMENTAL">FT_PARAM_TAG_INCREMENTAL</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_INCREMENTAL_H (freetype/ftincrem.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_PARAM_TAG_INCREMENTAL</b> <a href="ft2-basic_types.html#FT_MAKE_TAG">FT_MAKE_TAG</a>( 'i', 'n', 'c', 'r' )
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A constant used as the tag of <a href="ft2-base_interface.html#FT_Parameter">FT_Parameter</a> structures to indicate an incremental loading object to be used by FreeType.</p>
</td></tr></table><br>
</td></tr></table>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-index.html b/src/3rdparty/freetype/docs/reference/ft2-index.html
index ca4d1691d8..48dc736b19 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-index.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-index.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -34,257 +34,257 @@
<table align=center><tr><td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<table align=center border=0 cellpadding=0 cellspacing=0>
-<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_ATOM</a></td><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_LIGHT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Set">FT_Stroker_Set</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_CARDINAL</a></td><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_NONE</a></td><td><a href="ft2-glyph_stroker.html#FT_StrokerBorder">FT_StrokerBorder</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_INTEGER</a></td><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LcdFilter</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_2X2</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_NONE</a></td><td><a href="ft2-header_file_macros.html#FT_LIST_H">FT_LIST_H</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_ARGS_ARE_WORDS</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#BDF_Property">BDF_Property</a></td><td><a href="ft2-base_interface.html#FT_Library">FT_Library</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_ARGS_ARE_XY_VALUES</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#BDF_PropertyRec">BDF_PropertyRec</a></td><td><a href="ft2-lcd_filtering.html#FT_Library_SetLcdFilter">FT_Library_SetLcdFilter</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_ROUND_XY_TO_GRID</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#CID_FaceDict">CID_FaceDict</a></td><td><a href="ft2-version.html#FT_Library_Version">FT_Library_Version</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_SCALE</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#CID_FaceDictRec">CID_FaceDictRec</a></td><td><a href="ft2-list_processing.html#FT_List">FT_List</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_USE_MY_METRICS</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#CID_FaceInfo">CID_FaceInfo</a></td><td><a href="ft2-list_processing.html#FT_List_Add">FT_List_Add</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_XXX</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#CID_FaceInfoRec">CID_FaceInfoRec</a></td><td><a href="ft2-list_processing.html#FT_List_Destructor">FT_List_Destructor</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_XY_SCALE</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#CID_Info">CID_Info</a></td><td><a href="ft2-list_processing.html#FT_List_Finalize">FT_List_Finalize</a></td><td><a href="ft2-base_interface.html#FT_SubGlyph">FT_SubGlyph</a></td></tr>
-<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_MAJOR</a></td><td><a href="ft2-list_processing.html#FT_List_Find">FT_List_Find</a></td><td><a href="ft2-header_file_macros.html#FT_SYNTHESIS_H">FT_SYNTHESIS_H</a></td></tr>
-<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_MINOR</a></td><td><a href="ft2-list_processing.html#FT_List_Insert">FT_List_Insert</a></td><td><a href="ft2-header_file_macros.html#FT_SYSTEM_H">FT_SYSTEM_H</a></td></tr>
-<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_PATCH</a></td><td><a href="ft2-list_processing.html#FT_List_Iterate">FT_List_Iterate</a></td><td><a href="ft2-basic_types.html#FT_Tag">FT_Tag</a></td></tr>
-<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_XXX</a></td><td><a href="ft2-list_processing.html#FT_List_Iterator">FT_List_Iterator</a></td><td><a href="ft2-computations.html#FT_Tan">FT_Tan</a></td></tr>
-<tr><td><a href="ft2-sizes_management.html#FT_Activate_Size">FT_Activate_Size</a></td><td><a href="ft2-list_processing.html#FT_List_Remove">FT_List_Remove</a></td><td><a href="ft2-header_file_macros.html#FT_TRIGONOMETRY_H">FT_TRIGONOMETRY_H</a></td></tr>
-<tr><td><a href="ft2-quick_advance.html#FT_ADVANCE_FLAG_FAST_ONLY">FT_ADVANCE_FLAG_FAST_ONLY</a></td><td><a href="ft2-list_processing.html#FT_List_Up">FT_List_Up</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TRUETYPE_ENGINE_TYPE_NONE</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_ADVANCES_H">FT_ADVANCES_H</a></td><td><a href="ft2-list_processing.html#FT_ListNode">FT_ListNode</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TRUETYPE_ENGINE_TYPE_PATENTED</a></td></tr>
-<tr><td><a href="ft2-module_management.html#FT_Add_Default_Modules">FT_Add_Default_Modules</a></td><td><a href="ft2-list_processing.html#FT_ListNodeRec">FT_ListNodeRec</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TRUETYPE_ENGINE_TYPE_UNPATENTED</a></td></tr>
-<tr><td><a href="ft2-module_management.html#FT_Add_Module">FT_Add_Module</a></td><td><a href="ft2-list_processing.html#FT_ListRec">FT_ListRec</a></td><td><a href="ft2-header_file_macros.html#FT_TRUETYPE_IDS_H">FT_TRUETYPE_IDS_H</a></td></tr>
-<tr><td><a href="ft2-system_interface.html#FT_Alloc_Func">FT_Alloc_Func</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_CROP_BITMAP</a></td><td><a href="ft2-header_file_macros.html#FT_TRUETYPE_TABLES_H">FT_TRUETYPE_TABLES_H</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_ANGLE_2PI">FT_ANGLE_2PI</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_DEFAULT</a></td><td><a href="ft2-header_file_macros.html#FT_TRUETYPE_TAGS_H">FT_TRUETYPE_TAGS_H</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_ANGLE_PI">FT_ANGLE_PI</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_FORCE_AUTOHINT</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TrueTypeEngineType</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_ANGLE_PI2">FT_ANGLE_PI2</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH</a></td><td><a href="ft2-gx_validation.html#FT_TrueTypeGX_Free">FT_TrueTypeGX_Free</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_ANGLE_PI4">FT_ANGLE_PI4</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_TRANSFORM</a></td><td><a href="ft2-gx_validation.html#FT_TrueTypeGX_Validate">FT_TrueTypeGX_Validate</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_Angle">FT_Angle</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_LINEAR_DESIGN</a></td><td><a href="ft2-header_file_macros.html#FT_TYPE1_TABLES_H">FT_TYPE1_TABLES_H</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_Angle_Diff">FT_Angle_Diff</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_MONOCHROME</a></td><td><a href="ft2-header_file_macros.html#FT_TYPES_H">FT_TYPES_H</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_Atan2">FT_Atan2</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_AUTOHINT</a></td><td><a href="ft2-basic_types.html#FT_UFWord">FT_UFWord</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Attach_File">FT_Attach_File</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_BITMAP</a></td><td><a href="ft2-basic_types.html#FT_UInt">FT_UInt</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Attach_Stream">FT_Attach_Stream</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_HINTING</a></td><td><a href="ft2-basic_types.html#FT_UInt16">FT_UInt16</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_BBOX_H">FT_BBOX_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_RECURSE</a></td><td><a href="ft2-basic_types.html#FT_UInt32">FT_UInt32</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_BBox">FT_BBox</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_SCALE</a></td><td><a href="ft2-basic_types.html#FT_ULong">FT_ULong</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_BDF_H">FT_BDF_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_PEDANTIC</a></td><td><a href="ft2-header_file_macros.html#FT_UNPATENTED_HINTING_H">FT_UNPATENTED_HINTING_H</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_BITMAP_H">FT_BITMAP_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_RENDER</a></td><td><a href="ft2-basic_types.html#FT_UnitVector">FT_UnitVector</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Bitmap">FT_Bitmap</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_LCD</a></td><td><a href="ft2-basic_types.html#FT_UShort">FT_UShort</a></td></tr>
-<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Convert">FT_Bitmap_Convert</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_LCD_V</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_APPLE</a></td></tr>
-<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Copy">FT_Bitmap_Copy</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_LIGHT</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_BASE</a></td></tr>
-<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Done">FT_Bitmap_Done</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_MODE">FT_LOAD_TARGET_MODE</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_bsln</a></td></tr>
-<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Embolden">FT_Bitmap_Embolden</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_MONO</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_CKERN</a></td></tr>
-<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_New">FT_Bitmap_New</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_NORMAL</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_CKERNXXX</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Bitmap_Size">FT_Bitmap_Size</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_XXX</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_feat</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_BitmapGlyph">FT_BitmapGlyph</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_VERTICAL_LAYOUT</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_GDEF</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_BitmapGlyphRec">FT_BitmapGlyphRec</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_XXX</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_GPOS</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Bool">FT_Bool</a></td><td><a href="ft2-base_interface.html#FT_Load_Char">FT_Load_Char</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_GSUB</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Byte">FT_Byte</a></td><td><a href="ft2-base_interface.html#FT_Load_Glyph">FT_Load_Glyph</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_GX</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Bytes">FT_Bytes</a></td><td><a href="ft2-truetype_tables.html#FT_Load_Sfnt_Table">FT_Load_Sfnt_Table</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GX_LENGTH">FT_VALIDATE_GX_LENGTH</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_CHARMAP_H">FT_CACHE_CHARMAP_H</a></td><td><a href="ft2-basic_types.html#FT_Long">FT_Long</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_GXXXX</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_H">FT_CACHE_H</a></td><td><a href="ft2-header_file_macros.html#FT_LZW_H">FT_LZW_H</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_JSTF</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_IMAGE_H">FT_CACHE_IMAGE_H</a></td><td><a href="ft2-header_file_macros.html#FT_MAC_H">FT_MAC_H</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_just</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_SMALL_BITMAPS_H">FT_CACHE_SMALL_BITMAPS_H</a></td><td><a href="ft2-basic_types.html#FT_MAKE_TAG">FT_MAKE_TAG</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_kern</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_CeilFix">FT_CeilFix</a></td><td><a href="ft2-basic_types.html#FT_Matrix">FT_Matrix</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_lcar</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Char">FT_Char</a></td><td><a href="ft2-computations.html#FT_Matrix_Invert">FT_Matrix_Invert</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_MATH</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_CharMap">FT_CharMap</a></td><td><a href="ft2-computations.html#FT_Matrix_Multiply">FT_Matrix_Multiply</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_MS</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_CharMapRec">FT_CharMapRec</a></td><td><a href="ft2-system_interface.html#FT_Memory">FT_Memory</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_mort</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CID_H">FT_CID_H</a></td><td><a href="ft2-system_interface.html#FT_MemoryRec">FT_MemoryRec</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_morx</a></td></tr>
-<tr><td><a href="ft2-gx_validation.html#FT_ClassicKern_Free">FT_ClassicKern_Free</a></td><td><a href="ft2-multiple_masters.html#FT_MM_Axis">FT_MM_Axis</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_OT</a></td></tr>
-<tr><td><a href="ft2-gx_validation.html#FT_ClassicKern_Validate">FT_ClassicKern_Validate</a></td><td><a href="ft2-multiple_masters.html#FT_MM_Var">FT_MM_Var</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_OTXXX</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_CONFIG_H">FT_CONFIG_CONFIG_H</a></td><td><a href="ft2-header_file_macros.html#FT_MODULE_ERRORS_H">FT_MODULE_ERRORS_H</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_opbd</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_MODULES_H">FT_CONFIG_MODULES_H</a></td><td><a href="ft2-header_file_macros.html#FT_MODULE_H">FT_MODULE_H</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_prop</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_OPTIONS_H">FT_CONFIG_OPTIONS_H</a></td><td><a href="ft2-base_interface.html#FT_Module">FT_Module</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_trak</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_STANDARD_LIBRARY_H">FT_CONFIG_STANDARD_LIBRARY_H</a></td><td><a href="ft2-module_management.html#FT_Module_Class">FT_Module_Class</a></td><td><a href="ft2-multiple_masters.html#FT_Var_Axis">FT_Var_Axis</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_Cos">FT_Cos</a></td><td><a href="ft2-module_management.html#FT_Module_Constructor">FT_Module_Constructor</a></td><td><a href="ft2-multiple_masters.html#FT_Var_Named_Style">FT_Var_Named_Style</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Data">FT_Data</a></td><td><a href="ft2-module_management.html#FT_Module_Destructor">FT_Module_Destructor</a></td><td><a href="ft2-basic_types.html#FT_Vector">FT_Vector</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_DivFix">FT_DivFix</a></td><td><a href="ft2-module_management.html#FT_Module_Requester">FT_Module_Requester</a></td><td><a href="ft2-computations.html#FT_Vector_From_Polar">FT_Vector_From_Polar</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Done_Face">FT_Done_Face</a></td><td><a href="ft2-header_file_macros.html#FT_MULTIPLE_MASTERS_H">FT_MULTIPLE_MASTERS_H</a></td><td><a href="ft2-computations.html#FT_Vector_Length">FT_Vector_Length</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Done_FreeType">FT_Done_FreeType</a></td><td><a href="ft2-computations.html#FT_MulDiv">FT_MulDiv</a></td><td><a href="ft2-computations.html#FT_Vector_Polarize">FT_Vector_Polarize</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Done_Glyph">FT_Done_Glyph</a></td><td><a href="ft2-computations.html#FT_MulFix">FT_MulFix</a></td><td><a href="ft2-computations.html#FT_Vector_Rotate">FT_Vector_Rotate</a></td></tr>
-<tr><td><a href="ft2-module_management.html#FT_Done_Library">FT_Done_Library</a></td><td><a href="ft2-multiple_masters.html#FT_Multi_Master">FT_Multi_Master</a></td><td><a href="ft2-computations.html#FT_Vector_Transform">FT_Vector_Transform</a></td></tr>
-<tr><td><a href="ft2-sizes_management.html#FT_Done_Size">FT_Done_Size</a></td><td><a href="ft2-base_interface.html#FT_New_Face">FT_New_Face</a></td><td><a href="ft2-computations.html#FT_Vector_Unit">FT_Vector_Unit</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Driver">FT_Driver</a></td><td><a href="ft2-mac_specific.html#FT_New_Face_From_FOND">FT_New_Face_From_FOND</a></td><td><a href="ft2-header_file_macros.html#FT_WINFONTS_H">FT_WINFONTS_H</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_ENC_TAG">FT_ENC_TAG</a></td><td><a href="ft2-mac_specific.html#FT_New_Face_From_FSRef">FT_New_Face_From_FSRef</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_Header">FT_WinFNT_Header</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_CUSTOM</a></td><td><a href="ft2-mac_specific.html#FT_New_Face_From_FSSpec">FT_New_Face_From_FSSpec</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_HeaderRec">FT_WinFNT_HeaderRec</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_EXPERT</a></td><td><a href="ft2-module_management.html#FT_New_Library">FT_New_Library</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1250</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_LATIN_1</a></td><td><a href="ft2-base_interface.html#FT_New_Memory_Face">FT_New_Memory_Face</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1251</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_STANDARD</a></td><td><a href="ft2-sizes_management.html#FT_New_Size">FT_New_Size</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1252</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_APPLE_ROMAN</a></td><td><a href="ft2-basic_types.html#FT_Offset">FT_Offset</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1253</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_BIG5</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_DRIVER</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1254</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_GB2312</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_MEMORY</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1255</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_JOHAB</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_PARAMS</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1256</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_BIG5</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_PATHNAME</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1257</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_GB2312</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_STREAM</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1258</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_JOHAB</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_XXX</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1361</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_SJIS</a></td><td><a href="ft2-header_file_macros.html#FT_OPENTYPE_VALIDATE_H">FT_OPENTYPE_VALIDATE_H</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP874</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_SYMBOL</a></td><td><a href="ft2-base_interface.html#FT_Open_Args">FT_Open_Args</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP932</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_WANSUNG</a></td><td><a href="ft2-base_interface.html#FT_Open_Face">FT_Open_Face</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP936</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_NONE</a></td><td><a href="ft2-ot_validation.html#FT_OpenType_Free">FT_OpenType_Free</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP949</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_OLD_LATIN_2</a></td><td><a href="ft2-ot_validation.html#FT_OpenType_Validate">FT_OpenType_Validate</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP950</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_SJIS</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_FILL_LEFT</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_DEFAULT</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_UNICODE</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_FILL_RIGHT</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_MAC</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_WANSUNG</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_NONE</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_OEM</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_Encoding</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_POSTSCRIPT</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_SYMBOL</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_ERRORS_H">FT_ERRORS_H</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_TRUETYPE</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_XXX</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Error">FT_Error</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_Orientation</a></td><td><a href="ft2-header_file_macros.html#FT_XFREE86_H">FT_XFREE86_H</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_F26Dot6">FT_F26Dot6</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_EVEN_ODD_FILL</a></td><td><a href="ft2-cache_subsystem.html#FTC_CMapCache">FTC_CMapCache</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_F2Dot14">FT_F2Dot14</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_FLAGS</a></td><td><a href="ft2-cache_subsystem.html#FTC_CMapCache_Lookup">FTC_CMapCache_Lookup</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_CID_KEYED</a></td><td><a href="ft2-header_file_macros.html#FT_OUTLINE_H">FT_OUTLINE_H</a></td><td><a href="ft2-cache_subsystem.html#FTC_CMapCache_New">FTC_CMapCache_New</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_EXTERNAL_STREAM</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_HIGH_PRECISION</a></td><td><a href="ft2-cache_subsystem.html#FTC_Face_Requester">FTC_Face_Requester</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_FAST_GLYPHS</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_IGNORE_DROPOUTS</a></td><td><a href="ft2-cache_subsystem.html#FTC_FaceID">FTC_FaceID</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_FIXED_SIZES</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_INCLUDE_STUBS</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache">FTC_ImageCache</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_FIXED_WIDTH</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_NONE</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache_Lookup">FTC_ImageCache_Lookup</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_GLYPH_NAMES</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_OWNER</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache_LookupScaler">FTC_ImageCache_LookupScaler</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_HINTER</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_REVERSE_FILL</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache_New">FTC_ImageCache_New</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_HORIZONTAL</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_SINGLE_PASS</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageType">FTC_ImageType</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_KERNING</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_SMART_DROPOUTS</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageTypeRec">FTC_ImageTypeRec</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_MULTIPLE_MASTERS</a></td><td><a href="ft2-outline_processing.html#FT_Outline">FT_Outline</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager">FTC_Manager</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_SCALABLE</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Check">FT_Outline_Check</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_Done">FTC_Manager_Done</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_SFNT</a></td><td><a href="ft2-outline_processing.html#FT_Outline_ConicToFunc">FT_Outline_ConicToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_LookupFace">FTC_Manager_LookupFace</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_TRICKY</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Copy">FT_Outline_Copy</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_LookupSize">FTC_Manager_LookupSize</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_VERTICAL</a></td><td><a href="ft2-outline_processing.html#FT_Outline_CubicToFunc">FT_Outline_CubicToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_New">FTC_Manager_New</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_XXX</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Decompose">FT_Outline_Decompose</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_RemoveFaceID">FTC_Manager_RemoveFaceID</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Face">FT_Face</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Done">FT_Outline_Done</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_Reset">FTC_Manager_Reset</a></td></tr>
-<tr><td><a href="ft2-version.html#FT_Face_CheckTrueTypePatents">FT_Face_CheckTrueTypePatents</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Embolden">FT_Outline_Embolden</a></td><td><a href="ft2-cache_subsystem.html#FTC_Node">FTC_Node</a></td></tr>
-<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetCharsOfVariant">FT_Face_GetCharsOfVariant</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Funcs">FT_Outline_Funcs</a></td><td><a href="ft2-cache_subsystem.html#FTC_Node_Unref">FTC_Node_Unref</a></td></tr>
-<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetCharVariantIndex">FT_Face_GetCharVariantIndex</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_BBox">FT_Outline_Get_BBox</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBit">FTC_SBit</a></td></tr>
-<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetCharVariantIsDefault">FT_Face_GetCharVariantIsDefault</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_Bitmap">FT_Outline_Get_Bitmap</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache">FTC_SBitCache</a></td></tr>
-<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetVariantSelectors">FT_Face_GetVariantSelectors</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_CBox">FT_Outline_Get_CBox</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache_Lookup">FTC_SBitCache_Lookup</a></td></tr>
-<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetVariantsOfChar">FT_Face_GetVariantsOfChar</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_Orientation">FT_Outline_Get_Orientation</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache_LookupScaler">FTC_SBitCache_LookupScaler</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Face_Internal">FT_Face_Internal</a></td><td><a href="ft2-glyph_stroker.html#FT_Outline_GetInsideBorder">FT_Outline_GetInsideBorder</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache_New">FTC_SBitCache_New</a></td></tr>
-<tr><td><a href="ft2-version.html#FT_Face_SetUnpatentedHinting">FT_Face_SetUnpatentedHinting</a></td><td><a href="ft2-glyph_stroker.html#FT_Outline_GetOutsideBorder">FT_Outline_GetOutsideBorder</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitRec">FTC_SBitRec</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FaceRec">FT_FaceRec</a></td><td><a href="ft2-outline_processing.html#FT_Outline_LineToFunc">FT_Outline_LineToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_Scaler">FTC_Scaler</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Fixed">FT_Fixed</a></td><td><a href="ft2-outline_processing.html#FT_Outline_MoveToFunc">FT_Outline_MoveToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_ScalerRec">FTC_ScalerRec</a></td></tr>
-<tr><td><a href="ft2-computations.html#FT_FloorFix">FT_FloorFix</a></td><td><a href="ft2-outline_processing.html#FT_Outline_New">FT_Outline_New</a></td><td><a href="ft2-base_interface.html#ft_encoding_xxx">ft_encoding_xxx</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_FREETYPE_H">FT_FREETYPE_H</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Render">FT_Outline_Render</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_gridfit</a></td></tr>
-<tr><td><a href="ft2-system_interface.html#FT_Free_Func">FT_Free_Func</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Reverse">FT_Outline_Reverse</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_pixels</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_BITMAP_EMBEDDING_ONLY</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Transform">FT_Outline_Transform</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_subpixels</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_EDITABLE_EMBEDDING</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Translate">FT_Outline_Translate</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_truncate</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_INSTALLABLE_EMBEDDING</a></td><td><a href="ft2-glyph_management.html#FT_OutlineGlyph">FT_OutlineGlyph</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_unscaled</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_NO_SUBSETTING</a></td><td><a href="ft2-glyph_management.html#FT_OutlineGlyphRec">FT_OutlineGlyphRec</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_xxx</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_PREVIEW_AND_PRINT_EMBEDDING</a></td><td><a href="ft2-incremental.html#FT_PARAM_TAG_INCREMENTAL">FT_PARAM_TAG_INCREMENTAL</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_bitmap</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_RESTRICTED_LICENSE_EMBEDDING</a></td><td><a href="ft2-truetype_tables.html#FT_PARAM_TAG_UNPATENTED_HINTING">FT_PARAM_TAG_UNPATENTED_HINTING</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_composite</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_XXX</a></td><td><a href="ft2-basic_types.html#FT_Palette_Mode">FT_Palette_Mode</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_none</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_FWord">FT_FWord</a></td><td><a href="ft2-base_interface.html#FT_Parameter">FT_Parameter</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_outline</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_DO_GRAY</a></td><td><a href="ft2-header_file_macros.html#FT_PFR_H">FT_PFR_H</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_plotter</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_DO_GRIDFIT</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_GRAY</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_xxx</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_GASP_H">FT_GASP_H</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_GRAY2</a></td><td><a href="ft2-base_interface.html#ft_kerning_default">ft_kerning_default</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_NO_TABLE</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_GRAY4</a></td><td><a href="ft2-base_interface.html#ft_kerning_unfitted">ft_kerning_unfitted</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_SYMMETRIC_GRIDFIT</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_LCD</a></td><td><a href="ft2-base_interface.html#ft_kerning_unscaled">ft_kerning_unscaled</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_SYMMETRIC_SMOOTHING</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_LCD_V</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_driver</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_XXX</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_MONO</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_memory</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Generic">FT_Generic</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_NONE</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_params</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Generic_Finalizer">FT_Generic_Finalizer</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_Pixel_Mode</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_pathname</a></td></tr>
-<tr><td><a href="ft2-quick_advance.html#FT_Get_Advance">FT_Get_Advance</a></td><td><a href="ft2-basic_types.html#FT_Pointer">FT_Pointer</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_stream</a></td></tr>
-<tr><td><a href="ft2-quick_advance.html#FT_Get_Advances">FT_Get_Advances</a></td><td><a href="ft2-basic_types.html#FT_Pos">FT_Pos</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_even_odd_fill</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#FT_Get_BDF_Charset_ID">FT_Get_BDF_Charset_ID</a></td><td><a href="ft2-bdf_fonts.html#FT_PropertyType">FT_PropertyType</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_flags</a></td></tr>
-<tr><td><a href="ft2-bdf_fonts.html#FT_Get_BDF_Property">FT_Get_BDF_Property</a></td><td><a href="ft2-basic_types.html#FT_PtrDist">FT_PtrDist</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_high_precision</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Char_Index">FT_Get_Char_Index</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_AA</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_ignore_dropouts</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Charmap_Index">FT_Get_Charmap_Index</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_CLIP</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_none</a></td></tr>
-<tr><td><a href="ft2-cid_fonts.html#FT_Get_CID_From_Glyph_Index">FT_Get_CID_From_Glyph_Index</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_DEFAULT</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_owner</a></td></tr>
-<tr><td><a href="ft2-cid_fonts.html#FT_Get_CID_Is_Internally_CID_Keyed">FT_Get_CID_Is_Internally_CID_Keyed</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_DIRECT</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_reverse_fill</a></td></tr>
-<tr><td><a href="ft2-cid_fonts.html#FT_Get_CID_Registry_Ordering_Supplement">FT_Get_CID_Registry_Ordering_Supplement</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_XXX</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_single_pass</a></td></tr>
-<tr><td><a href="ft2-truetype_tables.html#FT_Get_CMap_Format">FT_Get_CMap_Format</a></td><td><a href="ft2-raster.html#FT_Raster">FT_Raster</a></td><td><a href="ft2-basic_types.html#FT_Palette_Mode">ft_palette_mode_rgb</a></td></tr>
-<tr><td><a href="ft2-truetype_tables.html#FT_Get_CMap_Language_ID">FT_Get_CMap_Language_ID</a></td><td><a href="ft2-raster.html#FT_Raster_BitSet_Func">FT_Raster_BitSet_Func</a></td><td><a href="ft2-basic_types.html#FT_Palette_Mode">ft_palette_mode_rgba</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_First_Char">FT_Get_First_Char</a></td><td><a href="ft2-raster.html#FT_Raster_BitTest_Func">FT_Raster_BitTest_Func</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_grays</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_FSType_Flags">FT_Get_FSType_Flags</a></td><td><a href="ft2-raster.html#FT_Raster_DoneFunc">FT_Raster_DoneFunc</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_mono</a></td></tr>
-<tr><td><a href="ft2-gasp_table.html#FT_Get_Gasp">FT_Get_Gasp</a></td><td><a href="ft2-raster.html#FT_Raster_Funcs">FT_Raster_Funcs</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_none</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Get_Glyph">FT_Get_Glyph</a></td><td><a href="ft2-raster.html#FT_Raster_NewFunc">FT_Raster_NewFunc</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_pal2</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Glyph_Name">FT_Get_Glyph_Name</a></td><td><a href="ft2-raster.html#FT_Raster_Params">FT_Raster_Params</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_pal4</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Kerning">FT_Get_Kerning</a></td><td><a href="ft2-raster.html#FT_Raster_RenderFunc">FT_Raster_RenderFunc</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_xxx</a></td></tr>
-<tr><td><a href="ft2-multiple_masters.html#FT_Get_MM_Var">FT_Get_MM_Var</a></td><td><a href="ft2-raster.html#FT_Raster_ResetFunc">FT_Raster_ResetFunc</a></td><td><a href="ft2-base_interface.html#ft_render_mode_xxx">ft_render_mode_mono</a></td></tr>
-<tr><td><a href="ft2-module_management.html#FT_Get_Module">FT_Get_Module</a></td><td><a href="ft2-raster.html#FT_Raster_SetModeFunc">FT_Raster_SetModeFunc</a></td><td><a href="ft2-base_interface.html#ft_render_mode_xxx">ft_render_mode_normal</a></td></tr>
-<tr><td><a href="ft2-multiple_masters.html#FT_Get_Multi_Master">FT_Get_Multi_Master</a></td><td><a href="ft2-header_file_macros.html#FT_RENDER_H">FT_RENDER_H</a></td><td><a href="ft2-base_interface.html#ft_render_mode_xxx">ft_render_mode_xxx</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Name_Index">FT_Get_Name_Index</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_LCD</a></td><td><a href="ft2-type1_tables.html#PS_FontInfo">PS_FontInfo</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Next_Char">FT_Get_Next_Char</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_LCD_V</a></td><td><a href="ft2-type1_tables.html#PS_FontInfoRec">PS_FontInfoRec</a></td></tr>
-<tr><td><a href="ft2-pfr_fonts.html#FT_Get_PFR_Advance">FT_Get_PFR_Advance</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_LIGHT</a></td><td><a href="ft2-type1_tables.html#PS_Private">PS_Private</a></td></tr>
-<tr><td><a href="ft2-pfr_fonts.html#FT_Get_PFR_Kerning">FT_Get_PFR_Kerning</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_MONO</a></td><td><a href="ft2-type1_tables.html#PS_PrivateRec">PS_PrivateRec</a></td></tr>
-<tr><td><a href="ft2-pfr_fonts.html#FT_Get_PFR_Metrics">FT_Get_PFR_Metrics</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_NORMAL</a></td><td><a href="ft2-type1_tables.html#T1_Blend_Flags">T1_Blend_Flags</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Postscript_Name">FT_Get_Postscript_Name</a></td><td><a href="ft2-system_interface.html#FT_Realloc_Func">FT_Realloc_Func</a></td><td><a href="ft2-type1_tables.html#T1_FontInfo">T1_FontInfo</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#FT_Get_PS_Font_Info">FT_Get_PS_Font_Info</a></td><td><a href="ft2-module_management.html#FT_Remove_Module">FT_Remove_Module</a></td><td><a href="ft2-type1_tables.html#T1_Private">T1_Private</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#FT_Get_PS_Font_Private">FT_Get_PS_Font_Private</a></td><td><a href="ft2-base_interface.html#FT_Render_Glyph">FT_Render_Glyph</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_CUSTOM</a></td></tr>
-<tr><td><a href="ft2-module_management.html#FT_Get_Renderer">FT_Get_Renderer</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_Render_Mode</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_EXPERT</a></td></tr>
-<tr><td><a href="ft2-sfnt_names.html#FT_Get_Sfnt_Name">FT_Get_Sfnt_Name</a></td><td><a href="ft2-base_interface.html#FT_Renderer">FT_Renderer</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_LATIN_1</a></td></tr>
-<tr><td><a href="ft2-sfnt_names.html#FT_Get_Sfnt_Name_Count">FT_Get_Sfnt_Name_Count</a></td><td><a href="ft2-module_management.html#FT_Renderer_Class">FT_Renderer_Class</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_STANDARD</a></td></tr>
-<tr><td><a href="ft2-truetype_tables.html#FT_Get_Sfnt_Table">FT_Get_Sfnt_Table</a></td><td><a href="ft2-base_interface.html#FT_Request_Size">FT_Request_Size</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_XXX</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_SubGlyph_Info">FT_Get_SubGlyph_Info</a></td><td><a href="ft2-computations.html#FT_RoundFix">FT_RoundFix</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_DEFAULT</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Get_Track_Kerning">FT_Get_Track_Kerning</a></td><td><a href="ft2-base_interface.html#FT_Select_Charmap">FT_Select_Charmap</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_ISO_10646</a></td></tr>
-<tr><td><a href="ft2-truetype_engine.html#FT_Get_TrueType_Engine_Type">FT_Get_TrueType_Engine_Type</a></td><td><a href="ft2-base_interface.html#FT_Select_Size">FT_Select_Size</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_UNICODE_1_1</a></td></tr>
-<tr><td><a href="ft2-winfnt_fonts.html#FT_Get_WinFNT_Header">FT_Get_WinFNT_Header</a></td><td><a href="ft2-base_interface.html#FT_Set_Char_Size">FT_Set_Char_Size</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_UNICODE_2_0</a></td></tr>
-<tr><td><a href="ft2-font_formats.html#FT_Get_X11_Font_Format">FT_Get_X11_Font_Format</a></td><td><a href="ft2-base_interface.html#FT_Set_Charmap">FT_Set_Charmap</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_UNICODE_32</a></td></tr>
-<tr><td><a href="ft2-mac_specific.html#FT_GetFile_From_Mac_ATS_Name">FT_GetFile_From_Mac_ATS_Name</a></td><td><a href="ft2-module_management.html#FT_Set_Debug_Hook">FT_Set_Debug_Hook</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_VARIANT_SELECTOR</a></td></tr>
-<tr><td><a href="ft2-mac_specific.html#FT_GetFile_From_Mac_Name">FT_GetFile_From_Mac_Name</a></td><td><a href="ft2-multiple_masters.html#FT_Set_MM_Blend_Coordinates">FT_Set_MM_Blend_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_XXX</a></td></tr>
-<tr><td><a href="ft2-mac_specific.html#FT_GetFilePath_From_Mac_ATS_Name">FT_GetFilePath_From_Mac_ATS_Name</a></td><td><a href="ft2-multiple_masters.html#FT_Set_MM_Design_Coordinates">FT_Set_MM_Design_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_Header">TT_Header</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_GRIDFIT</a></td><td><a href="ft2-base_interface.html#FT_Set_Pixel_Sizes">FT_Set_Pixel_Sizes</a></td><td><a href="ft2-truetype_tables.html#TT_HoriHeader">TT_HoriHeader</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_PIXELS</a></td><td><a href="ft2-module_management.html#FT_Set_Renderer">FT_Set_Renderer</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_10646</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_SUBPIXELS</a></td><td><a href="ft2-base_interface.html#FT_Set_Transform">FT_Set_Transform</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_7BIT_ASCII</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_TRUNCATE</a></td><td><a href="ft2-multiple_masters.html#FT_Set_Var_Blend_Coordinates">FT_Set_Var_Blend_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_8859_1</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_UNSCALED</a></td><td><a href="ft2-multiple_masters.html#FT_Set_Var_Design_Coordinates">FT_Set_Var_Design_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_XXX</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_BITMAP</a></td><td><a href="ft2-header_file_macros.html#FT_SFNT_NAMES_H">FT_SFNT_NAMES_H</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ARABIC</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_COMPOSITE</a></td><td><a href="ft2-truetype_tables.html#FT_Sfnt_Table_Info">FT_Sfnt_Table_Info</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ARMENIAN</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_NONE</a></td><td><a href="ft2-truetype_tables.html#FT_Sfnt_Tag">FT_Sfnt_Tag</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_BENGALI</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_OUTLINE</a></td><td><a href="ft2-sfnt_names.html#FT_SfntName">FT_SfntName</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_BURMESE</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_PLOTTER</a></td><td><a href="ft2-basic_types.html#FT_Short">FT_Short</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_DEVANAGARI</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_GLYPH_H">FT_GLYPH_H</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_BBOX</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GEEZ</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph">FT_Glyph</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_CELL</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GEORGIAN</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_Glyph_BBox_Mode</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_NOMINAL</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GREEK</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_Copy">FT_Glyph_Copy</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_REAL_DIM</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GUJARATI</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_Glyph_Format</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_SCALES</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GURMUKHI</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_Get_CBox">FT_Glyph_Get_CBox</a></td><td><a href="ft2-header_file_macros.html#FT_SIZES_H">FT_SIZES_H</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_HEBREW</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Glyph_Metrics">FT_Glyph_Metrics</a></td><td><a href="ft2-computations.html#FT_Sin">FT_Sin</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_JAPANESE</a></td></tr>
-<tr><td><a href="ft2-glyph_stroker.html#FT_Glyph_Stroke">FT_Glyph_Stroke</a></td><td><a href="ft2-base_interface.html#FT_Size">FT_Size</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_KANNADA</a></td></tr>
-<tr><td><a href="ft2-glyph_stroker.html#FT_Glyph_StrokeBorder">FT_Glyph_StrokeBorder</a></td><td><a href="ft2-base_interface.html#FT_Size_Internal">FT_Size_Internal</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_KHMER</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_To_Bitmap">FT_Glyph_To_Bitmap</a></td><td><a href="ft2-base_interface.html#FT_Size_Metrics">FT_Size_Metrics</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_KOREAN</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_Glyph_Transform">FT_Glyph_Transform</a></td><td><a href="ft2-base_interface.html#FT_Size_Request">FT_Size_Request</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_LAOTIAN</a></td></tr>
-<tr><td><a href="ft2-glyph_management.html#FT_GlyphRec">FT_GlyphRec</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_Size_Request_Type</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_MALAYALAM</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_GlyphSlot">FT_GlyphSlot</a></td><td><a href="ft2-base_interface.html#FT_Size_RequestRec">FT_Size_RequestRec</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_MALDIVIAN</a></td></tr>
-<tr><td><a href="ft2-bitmap_handling.html#FT_GlyphSlot_Own_Bitmap">FT_GlyphSlot_Own_Bitmap</a></td><td><a href="ft2-base_interface.html#FT_SizeRec">FT_SizeRec</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_MONGOLIAN</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_GlyphSlotRec">FT_GlyphSlotRec</a></td><td><a href="ft2-base_interface.html#FT_Slot_Internal">FT_Slot_Internal</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ORIYA</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_GX_VALIDATE_H">FT_GX_VALIDATE_H</a></td><td><a href="ft2-raster.html#FT_Span">FT_Span</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ROMAN</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_GZIP_H">FT_GZIP_H</a></td><td><a href="ft2-raster.html#FT_SpanFunc">FT_SpanFunc</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_RSYMBOL</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_FAST_GLYPHS">FT_HAS_FAST_GLYPHS</a></td><td><a href="ft2-glyph_stroker.html#FT_StrokerBorder">FT_STROKER_BORDER_LEFT</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_RUSSIAN</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_FIXED_SIZES">FT_HAS_FIXED_SIZES</a></td><td><a href="ft2-glyph_stroker.html#FT_StrokerBorder">FT_STROKER_BORDER_RIGHT</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SIMPLIFIED_CHINESE</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_GLYPH_NAMES">FT_HAS_GLYPH_NAMES</a></td><td><a href="ft2-header_file_macros.html#FT_STROKER_H">FT_STROKER_H</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SINDHI</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_HORIZONTAL">FT_HAS_HORIZONTAL</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_STROKER_LINECAP_BUTT</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SINHALESE</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_KERNING">FT_HAS_KERNING</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_STROKER_LINECAP_ROUND</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SLAVIC</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_MULTIPLE_MASTERS">FT_HAS_MULTIPLE_MASTERS</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_STROKER_LINECAP_SQUARE</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TAMIL</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_HAS_VERTICAL">FT_HAS_VERTICAL</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_BEVEL</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TELUGU</a></td></tr>
-<tr><td><a href="ft2-type1_tables.html#FT_Has_PS_Glyph_Names">FT_Has_PS_Glyph_Names</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_MITER</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_THAI</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_IMAGE_H">FT_IMAGE_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_ROUND</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TIBETAN</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_IMAGE_TAG">FT_IMAGE_TAG</a></td><td><a href="ft2-base_interface.html#FT_STYLE_FLAG_XXX">FT_STYLE_FLAG_BOLD</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TRADITIONAL_CHINESE</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_INCREMENTAL_H">FT_INCREMENTAL_H</a></td><td><a href="ft2-base_interface.html#FT_STYLE_FLAG_XXX">FT_STYLE_FLAG_ITALIC</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_UNINTERP</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental">FT_Incremental</a></td><td><a href="ft2-base_interface.html#FT_STYLE_FLAG_XXX">FT_STYLE_FLAG_XXX</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_VIETNAMESE</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_FreeGlyphDataFunc">FT_Incremental_FreeGlyphDataFunc</a></td><td><a href="ft2-system_interface.html#FT_Stream">FT_Stream</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_XXX</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_FuncsRec">FT_Incremental_FuncsRec</a></td><td><a href="ft2-system_interface.html#FT_Stream_CloseFunc">FT_Stream_CloseFunc</a></td><td><a href="ft2-truetype_tables.html#TT_MaxProfile">TT_MaxProfile</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_GetGlyphDataFunc">FT_Incremental_GetGlyphDataFunc</a></td><td><a href="ft2-system_interface.html#FT_Stream_IoFunc">FT_Stream_IoFunc</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_BIG_5</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_GetGlyphMetricsFunc">FT_Incremental_GetGlyphMetricsFunc</a></td><td><a href="ft2-gzip.html#FT_Stream_OpenGzip">FT_Stream_OpenGzip</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_GB2312</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_Interface">FT_Incremental_Interface</a></td><td><a href="ft2-lzw.html#FT_Stream_OpenLZW">FT_Stream_OpenLZW</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_JOHAB</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_InterfaceRec">FT_Incremental_InterfaceRec</a></td><td><a href="ft2-system_interface.html#FT_StreamDesc">FT_StreamDesc</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_SJIS</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_Metrics">FT_Incremental_Metrics</a></td><td><a href="ft2-system_interface.html#FT_StreamRec">FT_StreamRec</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_SYMBOL_CS</a></td></tr>
-<tr><td><a href="ft2-incremental.html#FT_Incremental_MetricsRec">FT_Incremental_MetricsRec</a></td><td><a href="ft2-basic_types.html#FT_String">FT_String</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_UCS_4</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Init_FreeType">FT_Init_FreeType</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker">FT_Stroker</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_UNICODE_CS</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Int">FT_Int</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_BeginSubPath">FT_Stroker_BeginSubPath</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_WANSUNG</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Int16">FT_Int16</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_ConicTo">FT_Stroker_ConicTo</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_XXX</a></td></tr>
-<tr><td><a href="ft2-basic_types.html#FT_Int32">FT_Int32</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_CubicTo">FT_Stroker_CubicTo</a></td><td><a href="ft2-truetype_tables.html#TT_OS2">TT_OS2</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_IS_CID_KEYED">FT_IS_CID_KEYED</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Done">FT_Stroker_Done</a></td><td><a href="ft2-truetype_tables.html#TT_PCLT">TT_PCLT</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_IS_FIXED_WIDTH">FT_IS_FIXED_WIDTH</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_EndSubPath">FT_Stroker_EndSubPath</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_ADOBE</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_IS_SCALABLE">FT_IS_SCALABLE</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Export">FT_Stroker_Export</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_APPLE_UNICODE</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_IS_SFNT">FT_IS_SFNT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_ExportBorder">FT_Stroker_ExportBorder</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_CUSTOM</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_IS_TRICKY">FT_IS_TRICKY</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_GetBorderCounts">FT_Stroker_GetBorderCounts</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_ISO</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_DEFAULT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_GetCounts">FT_Stroker_GetCounts</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_MACINTOSH</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_UNFITTED</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_Stroker_LineCap</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_MICROSOFT</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_UNSCALED</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_Stroker_LineJoin</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_XXX</a></td></tr>
-<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_Kerning_Mode</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineTo">FT_Stroker_LineTo</a></td><td><a href="ft2-truetype_tables.html#TT_Postscript">TT_Postscript</a></td></tr>
-<tr><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_DEFAULT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_New">FT_Stroker_New</a></td><td><a href="ft2-truetype_tables.html#TT_VertHeader">TT_VertHeader</a></td></tr>
-<tr><td><a href="ft2-header_file_macros.html#FT_LCD_FILTER_H">FT_LCD_FILTER_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_ParseOutline">FT_Stroker_ParseOutline</a></td><td></td></tr>
-<tr><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_LEGACY</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Rewind">FT_Stroker_Rewind</a></td><td></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_ATOM</a></td><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_LIGHT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_ParseOutline">FT_Stroker_ParseOutline</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_CARDINAL</a></td><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_NONE</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Rewind">FT_Stroker_Rewind</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_INTEGER</a></td><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LcdFilter</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Set">FT_Stroker_Set</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#FT_PropertyType">BDF_PROPERTY_TYPE_NONE</a></td><td><a href="ft2-header_file_macros.html#FT_LIST_H">FT_LIST_H</a></td><td><a href="ft2-glyph_stroker.html#FT_StrokerBorder">FT_StrokerBorder</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#BDF_Property">BDF_Property</a></td><td><a href="ft2-base_interface.html#FT_Library">FT_Library</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_2X2</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#BDF_PropertyRec">BDF_PropertyRec</a></td><td><a href="ft2-lcd_filtering.html#FT_Library_SetLcdFilter">FT_Library_SetLcdFilter</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_ARGS_ARE_WORDS</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#CID_FaceDict">CID_FaceDict</a></td><td><a href="ft2-version.html#FT_Library_Version">FT_Library_Version</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_ARGS_ARE_XY_VALUES</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#CID_FaceDictRec">CID_FaceDictRec</a></td><td><a href="ft2-list_processing.html#FT_List">FT_List</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_ROUND_XY_TO_GRID</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#CID_FaceInfo">CID_FaceInfo</a></td><td><a href="ft2-list_processing.html#FT_List_Add">FT_List_Add</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_SCALE</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#CID_FaceInfoRec">CID_FaceInfoRec</a></td><td><a href="ft2-list_processing.html#FT_List_Destructor">FT_List_Destructor</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_USE_MY_METRICS</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#CID_Info">CID_Info</a></td><td><a href="ft2-list_processing.html#FT_List_Finalize">FT_List_Finalize</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_XXX</a></td></tr>
+<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_MAJOR</a></td><td><a href="ft2-list_processing.html#FT_List_Find">FT_List_Find</a></td><td><a href="ft2-base_interface.html#FT_SUBGLYPH_FLAG_XXX">FT_SUBGLYPH_FLAG_XY_SCALE</a></td></tr>
+<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_MINOR</a></td><td><a href="ft2-list_processing.html#FT_List_Insert">FT_List_Insert</a></td><td><a href="ft2-base_interface.html#FT_SubGlyph">FT_SubGlyph</a></td></tr>
+<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_PATCH</a></td><td><a href="ft2-list_processing.html#FT_List_Iterate">FT_List_Iterate</a></td><td><a href="ft2-header_file_macros.html#FT_SYNTHESIS_H">FT_SYNTHESIS_H</a></td></tr>
+<tr><td><a href="ft2-version.html#FREETYPE_XXX">FREETYPE_XXX</a></td><td><a href="ft2-list_processing.html#FT_List_Iterator">FT_List_Iterator</a></td><td><a href="ft2-header_file_macros.html#FT_SYSTEM_H">FT_SYSTEM_H</a></td></tr>
+<tr><td><a href="ft2-sizes_management.html#FT_Activate_Size">FT_Activate_Size</a></td><td><a href="ft2-list_processing.html#FT_List_Remove">FT_List_Remove</a></td><td><a href="ft2-basic_types.html#FT_Tag">FT_Tag</a></td></tr>
+<tr><td><a href="ft2-quick_advance.html#FT_ADVANCE_FLAG_FAST_ONLY">FT_ADVANCE_FLAG_FAST_ONLY</a></td><td><a href="ft2-list_processing.html#FT_List_Up">FT_List_Up</a></td><td><a href="ft2-computations.html#FT_Tan">FT_Tan</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_ADVANCES_H">FT_ADVANCES_H</a></td><td><a href="ft2-list_processing.html#FT_ListNode">FT_ListNode</a></td><td><a href="ft2-header_file_macros.html#FT_TRIGONOMETRY_H">FT_TRIGONOMETRY_H</a></td></tr>
+<tr><td><a href="ft2-module_management.html#FT_Add_Default_Modules">FT_Add_Default_Modules</a></td><td><a href="ft2-list_processing.html#FT_ListNodeRec">FT_ListNodeRec</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TRUETYPE_ENGINE_TYPE_NONE</a></td></tr>
+<tr><td><a href="ft2-module_management.html#FT_Add_Module">FT_Add_Module</a></td><td><a href="ft2-list_processing.html#FT_ListRec">FT_ListRec</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TRUETYPE_ENGINE_TYPE_PATENTED</a></td></tr>
+<tr><td><a href="ft2-system_interface.html#FT_Alloc_Func">FT_Alloc_Func</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_CROP_BITMAP</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TRUETYPE_ENGINE_TYPE_UNPATENTED</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_ANGLE_2PI">FT_ANGLE_2PI</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_DEFAULT</a></td><td><a href="ft2-header_file_macros.html#FT_TRUETYPE_IDS_H">FT_TRUETYPE_IDS_H</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_ANGLE_PI">FT_ANGLE_PI</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_FORCE_AUTOHINT</a></td><td><a href="ft2-header_file_macros.html#FT_TRUETYPE_TABLES_H">FT_TRUETYPE_TABLES_H</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_ANGLE_PI2">FT_ANGLE_PI2</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH</a></td><td><a href="ft2-header_file_macros.html#FT_TRUETYPE_TAGS_H">FT_TRUETYPE_TAGS_H</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_ANGLE_PI4">FT_ANGLE_PI4</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_IGNORE_TRANSFORM</a></td><td><a href="ft2-truetype_engine.html#FT_TrueTypeEngineType">FT_TrueTypeEngineType</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_Angle">FT_Angle</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_LINEAR_DESIGN</a></td><td><a href="ft2-gx_validation.html#FT_TrueTypeGX_Free">FT_TrueTypeGX_Free</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_Angle_Diff">FT_Angle_Diff</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_MONOCHROME</a></td><td><a href="ft2-gx_validation.html#FT_TrueTypeGX_Validate">FT_TrueTypeGX_Validate</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_Atan2">FT_Atan2</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_AUTOHINT</a></td><td><a href="ft2-header_file_macros.html#FT_TYPE1_TABLES_H">FT_TYPE1_TABLES_H</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Attach_File">FT_Attach_File</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_BITMAP</a></td><td><a href="ft2-header_file_macros.html#FT_TYPES_H">FT_TYPES_H</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Attach_Stream">FT_Attach_Stream</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_HINTING</a></td><td><a href="ft2-basic_types.html#FT_UFWord">FT_UFWord</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_BBOX_H">FT_BBOX_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_RECURSE</a></td><td><a href="ft2-basic_types.html#FT_UInt">FT_UInt</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_BBox">FT_BBox</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_NO_SCALE</a></td><td><a href="ft2-basic_types.html#FT_UInt16">FT_UInt16</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_BDF_H">FT_BDF_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_PEDANTIC</a></td><td><a href="ft2-basic_types.html#FT_UInt32">FT_UInt32</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_BITMAP_H">FT_BITMAP_H</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_RENDER</a></td><td><a href="ft2-basic_types.html#FT_ULong">FT_ULong</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Bitmap">FT_Bitmap</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_LCD</a></td><td><a href="ft2-header_file_macros.html#FT_UNPATENTED_HINTING_H">FT_UNPATENTED_HINTING_H</a></td></tr>
+<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Convert">FT_Bitmap_Convert</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_LCD_V</a></td><td><a href="ft2-basic_types.html#FT_UnitVector">FT_UnitVector</a></td></tr>
+<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Copy">FT_Bitmap_Copy</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_LIGHT</a></td><td><a href="ft2-basic_types.html#FT_UShort">FT_UShort</a></td></tr>
+<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Done">FT_Bitmap_Done</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_MODE">FT_LOAD_TARGET_MODE</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_APPLE</a></td></tr>
+<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_Embolden">FT_Bitmap_Embolden</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_MONO</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_BASE</a></td></tr>
+<tr><td><a href="ft2-bitmap_handling.html#FT_Bitmap_New">FT_Bitmap_New</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_NORMAL</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_bsln</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Bitmap_Size">FT_Bitmap_Size</a></td><td><a href="ft2-base_interface.html#FT_LOAD_TARGET_XXX">FT_LOAD_TARGET_XXX</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_CKERN</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_BitmapGlyph">FT_BitmapGlyph</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_VERTICAL_LAYOUT</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_CKERNXXX</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_BitmapGlyphRec">FT_BitmapGlyphRec</a></td><td><a href="ft2-base_interface.html#FT_LOAD_XXX">FT_LOAD_XXX</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_feat</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Bool">FT_Bool</a></td><td><a href="ft2-base_interface.html#FT_Load_Char">FT_Load_Char</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_GDEF</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Byte">FT_Byte</a></td><td><a href="ft2-base_interface.html#FT_Load_Glyph">FT_Load_Glyph</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_GPOS</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Bytes">FT_Bytes</a></td><td><a href="ft2-truetype_tables.html#FT_Load_Sfnt_Table">FT_Load_Sfnt_Table</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_GSUB</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_CHARMAP_H">FT_CACHE_CHARMAP_H</a></td><td><a href="ft2-basic_types.html#FT_Long">FT_Long</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_GX</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_H">FT_CACHE_H</a></td><td><a href="ft2-header_file_macros.html#FT_LZW_H">FT_LZW_H</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GX_LENGTH">FT_VALIDATE_GX_LENGTH</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_IMAGE_H">FT_CACHE_IMAGE_H</a></td><td><a href="ft2-header_file_macros.html#FT_MAC_H">FT_MAC_H</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_GXXXX</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CACHE_SMALL_BITMAPS_H">FT_CACHE_SMALL_BITMAPS_H</a></td><td><a href="ft2-basic_types.html#FT_MAKE_TAG">FT_MAKE_TAG</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_JSTF</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_CeilFix">FT_CeilFix</a></td><td><a href="ft2-basic_types.html#FT_Matrix">FT_Matrix</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_just</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Char">FT_Char</a></td><td><a href="ft2-computations.html#FT_Matrix_Invert">FT_Matrix_Invert</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_kern</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_CharMap">FT_CharMap</a></td><td><a href="ft2-computations.html#FT_Matrix_Multiply">FT_Matrix_Multiply</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_lcar</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_CharMapRec">FT_CharMapRec</a></td><td><a href="ft2-system_interface.html#FT_Memory">FT_Memory</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_MATH</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CID_H">FT_CID_H</a></td><td><a href="ft2-system_interface.html#FT_MemoryRec">FT_MemoryRec</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_CKERNXXX">FT_VALIDATE_MS</a></td></tr>
+<tr><td><a href="ft2-gx_validation.html#FT_ClassicKern_Free">FT_ClassicKern_Free</a></td><td><a href="ft2-multiple_masters.html#FT_MM_Axis">FT_MM_Axis</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_mort</a></td></tr>
+<tr><td><a href="ft2-gx_validation.html#FT_ClassicKern_Validate">FT_ClassicKern_Validate</a></td><td><a href="ft2-multiple_masters.html#FT_MM_Var">FT_MM_Var</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_morx</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_CONFIG_H">FT_CONFIG_CONFIG_H</a></td><td><a href="ft2-header_file_macros.html#FT_MODULE_ERRORS_H">FT_MODULE_ERRORS_H</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_OT</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_MODULES_H">FT_CONFIG_MODULES_H</a></td><td><a href="ft2-header_file_macros.html#FT_MODULE_H">FT_MODULE_H</a></td><td><a href="ft2-ot_validation.html#FT_VALIDATE_OTXXX">FT_VALIDATE_OTXXX</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_OPTIONS_H">FT_CONFIG_OPTIONS_H</a></td><td><a href="ft2-base_interface.html#FT_Module">FT_Module</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_opbd</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_CONFIG_STANDARD_LIBRARY_H">FT_CONFIG_STANDARD_LIBRARY_H</a></td><td><a href="ft2-module_management.html#FT_Module_Class">FT_Module_Class</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_prop</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_Cos">FT_Cos</a></td><td><a href="ft2-module_management.html#FT_Module_Constructor">FT_Module_Constructor</a></td><td><a href="ft2-gx_validation.html#FT_VALIDATE_GXXXX">FT_VALIDATE_trak</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Data">FT_Data</a></td><td><a href="ft2-module_management.html#FT_Module_Destructor">FT_Module_Destructor</a></td><td><a href="ft2-multiple_masters.html#FT_Var_Axis">FT_Var_Axis</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_DivFix">FT_DivFix</a></td><td><a href="ft2-module_management.html#FT_Module_Requester">FT_Module_Requester</a></td><td><a href="ft2-multiple_masters.html#FT_Var_Named_Style">FT_Var_Named_Style</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Done_Face">FT_Done_Face</a></td><td><a href="ft2-header_file_macros.html#FT_MULTIPLE_MASTERS_H">FT_MULTIPLE_MASTERS_H</a></td><td><a href="ft2-basic_types.html#FT_Vector">FT_Vector</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Done_FreeType">FT_Done_FreeType</a></td><td><a href="ft2-computations.html#FT_MulDiv">FT_MulDiv</a></td><td><a href="ft2-computations.html#FT_Vector_From_Polar">FT_Vector_From_Polar</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Done_Glyph">FT_Done_Glyph</a></td><td><a href="ft2-computations.html#FT_MulFix">FT_MulFix</a></td><td><a href="ft2-computations.html#FT_Vector_Length">FT_Vector_Length</a></td></tr>
+<tr><td><a href="ft2-module_management.html#FT_Done_Library">FT_Done_Library</a></td><td><a href="ft2-multiple_masters.html#FT_Multi_Master">FT_Multi_Master</a></td><td><a href="ft2-computations.html#FT_Vector_Polarize">FT_Vector_Polarize</a></td></tr>
+<tr><td><a href="ft2-sizes_management.html#FT_Done_Size">FT_Done_Size</a></td><td><a href="ft2-base_interface.html#FT_New_Face">FT_New_Face</a></td><td><a href="ft2-computations.html#FT_Vector_Rotate">FT_Vector_Rotate</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Driver">FT_Driver</a></td><td><a href="ft2-mac_specific.html#FT_New_Face_From_FOND">FT_New_Face_From_FOND</a></td><td><a href="ft2-computations.html#FT_Vector_Transform">FT_Vector_Transform</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_ENC_TAG">FT_ENC_TAG</a></td><td><a href="ft2-mac_specific.html#FT_New_Face_From_FSRef">FT_New_Face_From_FSRef</a></td><td><a href="ft2-computations.html#FT_Vector_Unit">FT_Vector_Unit</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_CUSTOM</a></td><td><a href="ft2-mac_specific.html#FT_New_Face_From_FSSpec">FT_New_Face_From_FSSpec</a></td><td><a href="ft2-header_file_macros.html#FT_WINFONTS_H">FT_WINFONTS_H</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_EXPERT</a></td><td><a href="ft2-module_management.html#FT_New_Library">FT_New_Library</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_Header">FT_WinFNT_Header</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_LATIN_1</a></td><td><a href="ft2-base_interface.html#FT_New_Memory_Face">FT_New_Memory_Face</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_HeaderRec">FT_WinFNT_HeaderRec</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_ADOBE_STANDARD</a></td><td><a href="ft2-sizes_management.html#FT_New_Size">FT_New_Size</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1250</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_APPLE_ROMAN</a></td><td><a href="ft2-basic_types.html#FT_Offset">FT_Offset</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1251</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_BIG5</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_DRIVER</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1252</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_GB2312</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_MEMORY</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1253</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_JOHAB</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_PARAMS</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1254</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_BIG5</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_PATHNAME</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1255</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_GB2312</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_STREAM</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1256</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_JOHAB</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">FT_OPEN_XXX</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1257</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_SJIS</a></td><td><a href="ft2-header_file_macros.html#FT_OPENTYPE_VALIDATE_H">FT_OPENTYPE_VALIDATE_H</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1258</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_SYMBOL</a></td><td><a href="ft2-base_interface.html#FT_Open_Args">FT_Open_Args</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP1361</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_MS_WANSUNG</a></td><td><a href="ft2-base_interface.html#FT_Open_Face">FT_Open_Face</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP874</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_NONE</a></td><td><a href="ft2-ot_validation.html#FT_OpenType_Free">FT_OpenType_Free</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP932</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_OLD_LATIN_2</a></td><td><a href="ft2-ot_validation.html#FT_OpenType_Validate">FT_OpenType_Validate</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP936</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_SJIS</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_FILL_LEFT</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP949</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_UNICODE</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_FILL_RIGHT</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_CP950</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_ENCODING_WANSUNG</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_NONE</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_DEFAULT</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Encoding">FT_Encoding</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_POSTSCRIPT</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_MAC</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_ERRORS_H">FT_ERRORS_H</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_ORIENTATION_TRUETYPE</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_OEM</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Error">FT_Error</a></td><td><a href="ft2-outline_processing.html#FT_Orientation">FT_Orientation</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_SYMBOL</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_F26Dot6">FT_F26Dot6</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_EVEN_ODD_FILL</a></td><td><a href="ft2-winfnt_fonts.html#FT_WinFNT_ID_XXX">FT_WinFNT_ID_XXX</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_F2Dot14">FT_F2Dot14</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_FLAGS</a></td><td><a href="ft2-header_file_macros.html#FT_XFREE86_H">FT_XFREE86_H</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_CID_KEYED</a></td><td><a href="ft2-header_file_macros.html#FT_OUTLINE_H">FT_OUTLINE_H</a></td><td><a href="ft2-cache_subsystem.html#FTC_CMapCache">FTC_CMapCache</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_EXTERNAL_STREAM</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_HIGH_PRECISION</a></td><td><a href="ft2-cache_subsystem.html#FTC_CMapCache_Lookup">FTC_CMapCache_Lookup</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_FAST_GLYPHS</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_IGNORE_DROPOUTS</a></td><td><a href="ft2-cache_subsystem.html#FTC_CMapCache_New">FTC_CMapCache_New</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_FIXED_SIZES</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_INCLUDE_STUBS</a></td><td><a href="ft2-cache_subsystem.html#FTC_Face_Requester">FTC_Face_Requester</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_FIXED_WIDTH</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_NONE</a></td><td><a href="ft2-cache_subsystem.html#FTC_FaceID">FTC_FaceID</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_GLYPH_NAMES</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_OWNER</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache">FTC_ImageCache</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_HINTER</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_REVERSE_FILL</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache_Lookup">FTC_ImageCache_Lookup</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_HORIZONTAL</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_SINGLE_PASS</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache_LookupScaler">FTC_ImageCache_LookupScaler</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_KERNING</a></td><td><a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_SMART_DROPOUTS</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageCache_New">FTC_ImageCache_New</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_MULTIPLE_MASTERS</a></td><td><a href="ft2-outline_processing.html#FT_Outline">FT_Outline</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageType">FTC_ImageType</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_SCALABLE</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Check">FT_Outline_Check</a></td><td><a href="ft2-cache_subsystem.html#FTC_ImageTypeRec">FTC_ImageTypeRec</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_SFNT</a></td><td><a href="ft2-outline_processing.html#FT_Outline_ConicToFunc">FT_Outline_ConicToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager">FTC_Manager</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_TRICKY</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Copy">FT_Outline_Copy</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_Done">FTC_Manager_Done</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_VERTICAL</a></td><td><a href="ft2-outline_processing.html#FT_Outline_CubicToFunc">FT_Outline_CubicToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_LookupFace">FTC_Manager_LookupFace</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FACE_FLAG_XXX">FT_FACE_FLAG_XXX</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Decompose">FT_Outline_Decompose</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_LookupSize">FTC_Manager_LookupSize</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Face">FT_Face</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Done">FT_Outline_Done</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_New">FTC_Manager_New</a></td></tr>
+<tr><td><a href="ft2-version.html#FT_Face_CheckTrueTypePatents">FT_Face_CheckTrueTypePatents</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Embolden">FT_Outline_Embolden</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_RemoveFaceID">FTC_Manager_RemoveFaceID</a></td></tr>
+<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetCharsOfVariant">FT_Face_GetCharsOfVariant</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Funcs">FT_Outline_Funcs</a></td><td><a href="ft2-cache_subsystem.html#FTC_Manager_Reset">FTC_Manager_Reset</a></td></tr>
+<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetCharVariantIndex">FT_Face_GetCharVariantIndex</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_BBox">FT_Outline_Get_BBox</a></td><td><a href="ft2-cache_subsystem.html#FTC_Node">FTC_Node</a></td></tr>
+<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetCharVariantIsDefault">FT_Face_GetCharVariantIsDefault</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_Bitmap">FT_Outline_Get_Bitmap</a></td><td><a href="ft2-cache_subsystem.html#FTC_Node_Unref">FTC_Node_Unref</a></td></tr>
+<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetVariantSelectors">FT_Face_GetVariantSelectors</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_CBox">FT_Outline_Get_CBox</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBit">FTC_SBit</a></td></tr>
+<tr><td><a href="ft2-glyph_variants.html#FT_Face_GetVariantsOfChar">FT_Face_GetVariantsOfChar</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Get_Orientation">FT_Outline_Get_Orientation</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache">FTC_SBitCache</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Face_Internal">FT_Face_Internal</a></td><td><a href="ft2-glyph_stroker.html#FT_Outline_GetInsideBorder">FT_Outline_GetInsideBorder</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache_Lookup">FTC_SBitCache_Lookup</a></td></tr>
+<tr><td><a href="ft2-version.html#FT_Face_SetUnpatentedHinting">FT_Face_SetUnpatentedHinting</a></td><td><a href="ft2-glyph_stroker.html#FT_Outline_GetOutsideBorder">FT_Outline_GetOutsideBorder</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache_LookupScaler">FTC_SBitCache_LookupScaler</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FaceRec">FT_FaceRec</a></td><td><a href="ft2-outline_processing.html#FT_Outline_LineToFunc">FT_Outline_LineToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitCache_New">FTC_SBitCache_New</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Fixed">FT_Fixed</a></td><td><a href="ft2-outline_processing.html#FT_Outline_MoveToFunc">FT_Outline_MoveToFunc</a></td><td><a href="ft2-cache_subsystem.html#FTC_SBitRec">FTC_SBitRec</a></td></tr>
+<tr><td><a href="ft2-computations.html#FT_FloorFix">FT_FloorFix</a></td><td><a href="ft2-outline_processing.html#FT_Outline_New">FT_Outline_New</a></td><td><a href="ft2-cache_subsystem.html#FTC_Scaler">FTC_Scaler</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_FREETYPE_H">FT_FREETYPE_H</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Render">FT_Outline_Render</a></td><td><a href="ft2-cache_subsystem.html#FTC_ScalerRec">FTC_ScalerRec</a></td></tr>
+<tr><td><a href="ft2-system_interface.html#FT_Free_Func">FT_Free_Func</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Reverse">FT_Outline_Reverse</a></td><td><a href="ft2-base_interface.html#ft_encoding_xxx">ft_encoding_xxx</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_BITMAP_EMBEDDING_ONLY</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Transform">FT_Outline_Transform</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_gridfit</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_EDITABLE_EMBEDDING</a></td><td><a href="ft2-outline_processing.html#FT_Outline_Translate">FT_Outline_Translate</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_pixels</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_INSTALLABLE_EMBEDDING</a></td><td><a href="ft2-glyph_management.html#FT_OutlineGlyph">FT_OutlineGlyph</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_subpixels</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_NO_SUBSETTING</a></td><td><a href="ft2-glyph_management.html#FT_OutlineGlyphRec">FT_OutlineGlyphRec</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_truncate</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_PREVIEW_AND_PRINT_EMBEDDING</a></td><td><a href="ft2-sfnt_names.html#FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY">FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_unscaled</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_RESTRICTED_LICENSE_EMBEDDING</a></td><td><a href="ft2-sfnt_names.html#FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY">FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY</a></td><td><a href="ft2-glyph_management.html#ft_glyph_bbox_xxx">ft_glyph_bbox_xxx</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_FSTYPE_XXX">FT_FSTYPE_XXX</a></td><td><a href="ft2-incremental.html#FT_PARAM_TAG_INCREMENTAL">FT_PARAM_TAG_INCREMENTAL</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_bitmap</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_FWord">FT_FWord</a></td><td><a href="ft2-truetype_tables.html#FT_PARAM_TAG_UNPATENTED_HINTING">FT_PARAM_TAG_UNPATENTED_HINTING</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_composite</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_DO_GRAY</a></td><td><a href="ft2-basic_types.html#FT_Palette_Mode">FT_Palette_Mode</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_none</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_DO_GRIDFIT</a></td><td><a href="ft2-base_interface.html#FT_Parameter">FT_Parameter</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_outline</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_GASP_H">FT_GASP_H</a></td><td><a href="ft2-header_file_macros.html#FT_PFR_H">FT_PFR_H</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_plotter</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_NO_TABLE</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_GRAY</a></td><td><a href="ft2-basic_types.html#ft_glyph_format_xxx">ft_glyph_format_xxx</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_SYMMETRIC_GRIDFIT</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_GRAY2</a></td><td><a href="ft2-base_interface.html#ft_kerning_default">ft_kerning_default</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_SYMMETRIC_SMOOTHING</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_GRAY4</a></td><td><a href="ft2-base_interface.html#ft_kerning_unfitted">ft_kerning_unfitted</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_GASP_XXX">FT_GASP_XXX</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_LCD</a></td><td><a href="ft2-base_interface.html#ft_kerning_unscaled">ft_kerning_unscaled</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Generic">FT_Generic</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_LCD_V</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_driver</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Generic_Finalizer">FT_Generic_Finalizer</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_MONO</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_memory</a></td></tr>
+<tr><td><a href="ft2-quick_advance.html#FT_Get_Advance">FT_Get_Advance</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_PIXEL_MODE_NONE</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_params</a></td></tr>
+<tr><td><a href="ft2-quick_advance.html#FT_Get_Advances">FT_Get_Advances</a></td><td><a href="ft2-basic_types.html#FT_Pixel_Mode">FT_Pixel_Mode</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_pathname</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#FT_Get_BDF_Charset_ID">FT_Get_BDF_Charset_ID</a></td><td><a href="ft2-basic_types.html#FT_Pointer">FT_Pointer</a></td><td><a href="ft2-base_interface.html#FT_OPEN_XXX">ft_open_stream</a></td></tr>
+<tr><td><a href="ft2-bdf_fonts.html#FT_Get_BDF_Property">FT_Get_BDF_Property</a></td><td><a href="ft2-basic_types.html#FT_Pos">FT_Pos</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_even_odd_fill</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Char_Index">FT_Get_Char_Index</a></td><td><a href="ft2-bdf_fonts.html#FT_PropertyType">FT_PropertyType</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_flags</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Charmap_Index">FT_Get_Charmap_Index</a></td><td><a href="ft2-basic_types.html#FT_PtrDist">FT_PtrDist</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_high_precision</a></td></tr>
+<tr><td><a href="ft2-cid_fonts.html#FT_Get_CID_From_Glyph_Index">FT_Get_CID_From_Glyph_Index</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_AA</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_ignore_dropouts</a></td></tr>
+<tr><td><a href="ft2-cid_fonts.html#FT_Get_CID_Is_Internally_CID_Keyed">FT_Get_CID_Is_Internally_CID_Keyed</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_CLIP</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_none</a></td></tr>
+<tr><td><a href="ft2-cid_fonts.html#FT_Get_CID_Registry_Ordering_Supplement">FT_Get_CID_Registry_Ordering_Supplement</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_DEFAULT</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_owner</a></td></tr>
+<tr><td><a href="ft2-truetype_tables.html#FT_Get_CMap_Format">FT_Get_CMap_Format</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_DIRECT</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_reverse_fill</a></td></tr>
+<tr><td><a href="ft2-truetype_tables.html#FT_Get_CMap_Language_ID">FT_Get_CMap_Language_ID</a></td><td><a href="ft2-raster.html#FT_RASTER_FLAG_XXX">FT_RASTER_FLAG_XXX</a></td><td><a href="ft2-outline_processing.html#ft_outline_flags">ft_outline_single_pass</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_First_Char">FT_Get_First_Char</a></td><td><a href="ft2-raster.html#FT_Raster">FT_Raster</a></td><td><a href="ft2-basic_types.html#FT_Palette_Mode">ft_palette_mode_rgb</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_FSType_Flags">FT_Get_FSType_Flags</a></td><td><a href="ft2-raster.html#FT_Raster_BitSet_Func">FT_Raster_BitSet_Func</a></td><td><a href="ft2-basic_types.html#FT_Palette_Mode">ft_palette_mode_rgba</a></td></tr>
+<tr><td><a href="ft2-gasp_table.html#FT_Get_Gasp">FT_Get_Gasp</a></td><td><a href="ft2-raster.html#FT_Raster_BitTest_Func">FT_Raster_BitTest_Func</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_grays</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Get_Glyph">FT_Get_Glyph</a></td><td><a href="ft2-raster.html#FT_Raster_DoneFunc">FT_Raster_DoneFunc</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_mono</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Glyph_Name">FT_Get_Glyph_Name</a></td><td><a href="ft2-raster.html#FT_Raster_Funcs">FT_Raster_Funcs</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_none</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Kerning">FT_Get_Kerning</a></td><td><a href="ft2-raster.html#FT_Raster_NewFunc">FT_Raster_NewFunc</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_pal2</a></td></tr>
+<tr><td><a href="ft2-multiple_masters.html#FT_Get_MM_Var">FT_Get_MM_Var</a></td><td><a href="ft2-raster.html#FT_Raster_Params">FT_Raster_Params</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_pal4</a></td></tr>
+<tr><td><a href="ft2-module_management.html#FT_Get_Module">FT_Get_Module</a></td><td><a href="ft2-raster.html#FT_Raster_RenderFunc">FT_Raster_RenderFunc</a></td><td><a href="ft2-basic_types.html#ft_pixel_mode_xxx">ft_pixel_mode_xxx</a></td></tr>
+<tr><td><a href="ft2-multiple_masters.html#FT_Get_Multi_Master">FT_Get_Multi_Master</a></td><td><a href="ft2-raster.html#FT_Raster_ResetFunc">FT_Raster_ResetFunc</a></td><td><a href="ft2-base_interface.html#ft_render_mode_xxx">ft_render_mode_mono</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Name_Index">FT_Get_Name_Index</a></td><td><a href="ft2-raster.html#FT_Raster_SetModeFunc">FT_Raster_SetModeFunc</a></td><td><a href="ft2-base_interface.html#ft_render_mode_xxx">ft_render_mode_normal</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Next_Char">FT_Get_Next_Char</a></td><td><a href="ft2-header_file_macros.html#FT_RENDER_H">FT_RENDER_H</a></td><td><a href="ft2-base_interface.html#ft_render_mode_xxx">ft_render_mode_xxx</a></td></tr>
+<tr><td><a href="ft2-pfr_fonts.html#FT_Get_PFR_Advance">FT_Get_PFR_Advance</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_LCD</a></td><td><a href="ft2-type1_tables.html#PS_FontInfo">PS_FontInfo</a></td></tr>
+<tr><td><a href="ft2-pfr_fonts.html#FT_Get_PFR_Kerning">FT_Get_PFR_Kerning</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_LCD_V</a></td><td><a href="ft2-type1_tables.html#PS_FontInfoRec">PS_FontInfoRec</a></td></tr>
+<tr><td><a href="ft2-pfr_fonts.html#FT_Get_PFR_Metrics">FT_Get_PFR_Metrics</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_LIGHT</a></td><td><a href="ft2-type1_tables.html#PS_Private">PS_Private</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Postscript_Name">FT_Get_Postscript_Name</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_MONO</a></td><td><a href="ft2-type1_tables.html#PS_PrivateRec">PS_PrivateRec</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#FT_Get_PS_Font_Info">FT_Get_PS_Font_Info</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_RENDER_MODE_NORMAL</a></td><td><a href="ft2-type1_tables.html#T1_Blend_Flags">T1_Blend_Flags</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#FT_Get_PS_Font_Private">FT_Get_PS_Font_Private</a></td><td><a href="ft2-system_interface.html#FT_Realloc_Func">FT_Realloc_Func</a></td><td><a href="ft2-type1_tables.html#T1_FontInfo">T1_FontInfo</a></td></tr>
+<tr><td><a href="ft2-module_management.html#FT_Get_Renderer">FT_Get_Renderer</a></td><td><a href="ft2-module_management.html#FT_Remove_Module">FT_Remove_Module</a></td><td><a href="ft2-type1_tables.html#T1_Private">T1_Private</a></td></tr>
+<tr><td><a href="ft2-sfnt_names.html#FT_Get_Sfnt_Name">FT_Get_Sfnt_Name</a></td><td><a href="ft2-base_interface.html#FT_Render_Glyph">FT_Render_Glyph</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_CUSTOM</a></td></tr>
+<tr><td><a href="ft2-sfnt_names.html#FT_Get_Sfnt_Name_Count">FT_Get_Sfnt_Name_Count</a></td><td><a href="ft2-base_interface.html#FT_Render_Mode">FT_Render_Mode</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_EXPERT</a></td></tr>
+<tr><td><a href="ft2-truetype_tables.html#FT_Get_Sfnt_Table">FT_Get_Sfnt_Table</a></td><td><a href="ft2-base_interface.html#FT_Renderer">FT_Renderer</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_LATIN_1</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_SubGlyph_Info">FT_Get_SubGlyph_Info</a></td><td><a href="ft2-module_management.html#FT_Renderer_Class">FT_Renderer_Class</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_STANDARD</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Get_Track_Kerning">FT_Get_Track_Kerning</a></td><td><a href="ft2-base_interface.html#FT_Request_Size">FT_Request_Size</a></td><td><a href="ft2-truetype_tables.html#TT_ADOBE_ID_XXX">TT_ADOBE_ID_XXX</a></td></tr>
+<tr><td><a href="ft2-truetype_engine.html#FT_Get_TrueType_Engine_Type">FT_Get_TrueType_Engine_Type</a></td><td><a href="ft2-computations.html#FT_RoundFix">FT_RoundFix</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_DEFAULT</a></td></tr>
+<tr><td><a href="ft2-winfnt_fonts.html#FT_Get_WinFNT_Header">FT_Get_WinFNT_Header</a></td><td><a href="ft2-base_interface.html#FT_Select_Charmap">FT_Select_Charmap</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_ISO_10646</a></td></tr>
+<tr><td><a href="ft2-font_formats.html#FT_Get_X11_Font_Format">FT_Get_X11_Font_Format</a></td><td><a href="ft2-base_interface.html#FT_Select_Size">FT_Select_Size</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_UNICODE_1_1</a></td></tr>
+<tr><td><a href="ft2-mac_specific.html#FT_GetFile_From_Mac_ATS_Name">FT_GetFile_From_Mac_ATS_Name</a></td><td><a href="ft2-base_interface.html#FT_Set_Char_Size">FT_Set_Char_Size</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_UNICODE_2_0</a></td></tr>
+<tr><td><a href="ft2-mac_specific.html#FT_GetFile_From_Mac_Name">FT_GetFile_From_Mac_Name</a></td><td><a href="ft2-base_interface.html#FT_Set_Charmap">FT_Set_Charmap</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_UNICODE_32</a></td></tr>
+<tr><td><a href="ft2-mac_specific.html#FT_GetFilePath_From_Mac_ATS_Name">FT_GetFilePath_From_Mac_ATS_Name</a></td><td><a href="ft2-module_management.html#FT_Set_Debug_Hook">FT_Set_Debug_Hook</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_VARIANT_SELECTOR</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_GRIDFIT</a></td><td><a href="ft2-multiple_masters.html#FT_Set_MM_Blend_Coordinates">FT_Set_MM_Blend_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_APPLE_ID_XXX">TT_APPLE_ID_XXX</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_PIXELS</a></td><td><a href="ft2-multiple_masters.html#FT_Set_MM_Design_Coordinates">FT_Set_MM_Design_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_Header">TT_Header</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_SUBPIXELS</a></td><td><a href="ft2-base_interface.html#FT_Set_Pixel_Sizes">FT_Set_Pixel_Sizes</a></td><td><a href="ft2-truetype_tables.html#TT_HoriHeader">TT_HoriHeader</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_TRUNCATE</a></td><td><a href="ft2-module_management.html#FT_Set_Renderer">FT_Set_Renderer</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_10646</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_GLYPH_BBOX_UNSCALED</a></td><td><a href="ft2-base_interface.html#FT_Set_Transform">FT_Set_Transform</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_7BIT_ASCII</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_BITMAP</a></td><td><a href="ft2-multiple_masters.html#FT_Set_Var_Blend_Coordinates">FT_Set_Var_Blend_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_8859_1</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_COMPOSITE</a></td><td><a href="ft2-multiple_masters.html#FT_Set_Var_Design_Coordinates">FT_Set_Var_Design_Coordinates</a></td><td><a href="ft2-truetype_tables.html#TT_ISO_ID_XXX">TT_ISO_ID_XXX</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_NONE</a></td><td><a href="ft2-header_file_macros.html#FT_SFNT_NAMES_H">FT_SFNT_NAMES_H</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ARABIC</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_OUTLINE</a></td><td><a href="ft2-truetype_tables.html#FT_Sfnt_Table_Info">FT_Sfnt_Table_Info</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ARMENIAN</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_GLYPH_FORMAT_PLOTTER</a></td><td><a href="ft2-truetype_tables.html#FT_Sfnt_Tag">FT_Sfnt_Tag</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_BENGALI</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_GLYPH_H">FT_GLYPH_H</a></td><td><a href="ft2-sfnt_names.html#FT_SfntName">FT_SfntName</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_BURMESE</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph">FT_Glyph</a></td><td><a href="ft2-basic_types.html#FT_Short">FT_Short</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_DEVANAGARI</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_BBox_Mode">FT_Glyph_BBox_Mode</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_BBOX</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GEEZ</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_Copy">FT_Glyph_Copy</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_CELL</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GEORGIAN</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Glyph_Format">FT_Glyph_Format</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_NOMINAL</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GREEK</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_Get_CBox">FT_Glyph_Get_CBox</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_REAL_DIM</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GUJARATI</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Glyph_Metrics">FT_Glyph_Metrics</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_SIZE_REQUEST_TYPE_SCALES</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_GURMUKHI</a></td></tr>
+<tr><td><a href="ft2-glyph_stroker.html#FT_Glyph_Stroke">FT_Glyph_Stroke</a></td><td><a href="ft2-header_file_macros.html#FT_SIZES_H">FT_SIZES_H</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_HEBREW</a></td></tr>
+<tr><td><a href="ft2-glyph_stroker.html#FT_Glyph_StrokeBorder">FT_Glyph_StrokeBorder</a></td><td><a href="ft2-computations.html#FT_Sin">FT_Sin</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_JAPANESE</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_To_Bitmap">FT_Glyph_To_Bitmap</a></td><td><a href="ft2-base_interface.html#FT_Size">FT_Size</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_KANNADA</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_Glyph_Transform">FT_Glyph_Transform</a></td><td><a href="ft2-base_interface.html#FT_Size_Internal">FT_Size_Internal</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_KHMER</a></td></tr>
+<tr><td><a href="ft2-glyph_management.html#FT_GlyphRec">FT_GlyphRec</a></td><td><a href="ft2-base_interface.html#FT_Size_Metrics">FT_Size_Metrics</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_KOREAN</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_GlyphSlot">FT_GlyphSlot</a></td><td><a href="ft2-base_interface.html#FT_Size_Request">FT_Size_Request</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_LAOTIAN</a></td></tr>
+<tr><td><a href="ft2-bitmap_handling.html#FT_GlyphSlot_Own_Bitmap">FT_GlyphSlot_Own_Bitmap</a></td><td><a href="ft2-base_interface.html#FT_Size_Request_Type">FT_Size_Request_Type</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_MALAYALAM</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_GlyphSlotRec">FT_GlyphSlotRec</a></td><td><a href="ft2-base_interface.html#FT_Size_RequestRec">FT_Size_RequestRec</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_MALDIVIAN</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_GX_VALIDATE_H">FT_GX_VALIDATE_H</a></td><td><a href="ft2-base_interface.html#FT_SizeRec">FT_SizeRec</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_MONGOLIAN</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_GZIP_H">FT_GZIP_H</a></td><td><a href="ft2-base_interface.html#FT_Slot_Internal">FT_Slot_Internal</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ORIYA</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_FAST_GLYPHS">FT_HAS_FAST_GLYPHS</a></td><td><a href="ft2-raster.html#FT_Span">FT_Span</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_ROMAN</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_FIXED_SIZES">FT_HAS_FIXED_SIZES</a></td><td><a href="ft2-raster.html#FT_SpanFunc">FT_SpanFunc</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_RSYMBOL</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_GLYPH_NAMES">FT_HAS_GLYPH_NAMES</a></td><td><a href="ft2-glyph_stroker.html#FT_StrokerBorder">FT_STROKER_BORDER_LEFT</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_RUSSIAN</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_HORIZONTAL">FT_HAS_HORIZONTAL</a></td><td><a href="ft2-glyph_stroker.html#FT_StrokerBorder">FT_STROKER_BORDER_RIGHT</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SIMPLIFIED_CHINESE</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_KERNING">FT_HAS_KERNING</a></td><td><a href="ft2-header_file_macros.html#FT_STROKER_H">FT_STROKER_H</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SINDHI</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_MULTIPLE_MASTERS">FT_HAS_MULTIPLE_MASTERS</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_STROKER_LINECAP_BUTT</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SINHALESE</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_HAS_VERTICAL">FT_HAS_VERTICAL</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_STROKER_LINECAP_ROUND</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_SLAVIC</a></td></tr>
+<tr><td><a href="ft2-type1_tables.html#FT_Has_PS_Glyph_Names">FT_Has_PS_Glyph_Names</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_STROKER_LINECAP_SQUARE</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TAMIL</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_IMAGE_H">FT_IMAGE_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_BEVEL</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TELUGU</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_IMAGE_TAG">FT_IMAGE_TAG</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_MITER</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_THAI</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_INCREMENTAL_H">FT_INCREMENTAL_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_STROKER_LINEJOIN_ROUND</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TIBETAN</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental">FT_Incremental</a></td><td><a href="ft2-base_interface.html#FT_STYLE_FLAG_XXX">FT_STYLE_FLAG_BOLD</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_TRADITIONAL_CHINESE</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_FreeGlyphDataFunc">FT_Incremental_FreeGlyphDataFunc</a></td><td><a href="ft2-base_interface.html#FT_STYLE_FLAG_XXX">FT_STYLE_FLAG_ITALIC</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_UNINTERP</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_FuncsRec">FT_Incremental_FuncsRec</a></td><td><a href="ft2-base_interface.html#FT_STYLE_FLAG_XXX">FT_STYLE_FLAG_XXX</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_VIETNAMESE</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_GetGlyphDataFunc">FT_Incremental_GetGlyphDataFunc</a></td><td><a href="ft2-system_interface.html#FT_Stream">FT_Stream</a></td><td><a href="ft2-truetype_tables.html#TT_MAC_ID_XXX">TT_MAC_ID_XXX</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_GetGlyphMetricsFunc">FT_Incremental_GetGlyphMetricsFunc</a></td><td><a href="ft2-system_interface.html#FT_Stream_CloseFunc">FT_Stream_CloseFunc</a></td><td><a href="ft2-truetype_tables.html#TT_MaxProfile">TT_MaxProfile</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_Interface">FT_Incremental_Interface</a></td><td><a href="ft2-system_interface.html#FT_Stream_IoFunc">FT_Stream_IoFunc</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_BIG_5</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_InterfaceRec">FT_Incremental_InterfaceRec</a></td><td><a href="ft2-gzip.html#FT_Stream_OpenGzip">FT_Stream_OpenGzip</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_GB2312</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_Metrics">FT_Incremental_Metrics</a></td><td><a href="ft2-lzw.html#FT_Stream_OpenLZW">FT_Stream_OpenLZW</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_JOHAB</a></td></tr>
+<tr><td><a href="ft2-incremental.html#FT_Incremental_MetricsRec">FT_Incremental_MetricsRec</a></td><td><a href="ft2-system_interface.html#FT_StreamDesc">FT_StreamDesc</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_SJIS</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Init_FreeType">FT_Init_FreeType</a></td><td><a href="ft2-system_interface.html#FT_StreamRec">FT_StreamRec</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_SYMBOL_CS</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Int">FT_Int</a></td><td><a href="ft2-basic_types.html#FT_String">FT_String</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_UCS_4</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Int16">FT_Int16</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker">FT_Stroker</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_UNICODE_CS</a></td></tr>
+<tr><td><a href="ft2-basic_types.html#FT_Int32">FT_Int32</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_BeginSubPath">FT_Stroker_BeginSubPath</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_WANSUNG</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_IS_CID_KEYED">FT_IS_CID_KEYED</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_ConicTo">FT_Stroker_ConicTo</a></td><td><a href="ft2-truetype_tables.html#TT_MS_ID_XXX">TT_MS_ID_XXX</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_IS_FIXED_WIDTH">FT_IS_FIXED_WIDTH</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_CubicTo">FT_Stroker_CubicTo</a></td><td><a href="ft2-truetype_tables.html#TT_OS2">TT_OS2</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_IS_SCALABLE">FT_IS_SCALABLE</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Done">FT_Stroker_Done</a></td><td><a href="ft2-truetype_tables.html#TT_PCLT">TT_PCLT</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_IS_SFNT">FT_IS_SFNT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_EndSubPath">FT_Stroker_EndSubPath</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_ADOBE</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_IS_TRICKY">FT_IS_TRICKY</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_Export">FT_Stroker_Export</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_APPLE_UNICODE</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_DEFAULT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_ExportBorder">FT_Stroker_ExportBorder</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_CUSTOM</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_UNFITTED</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_GetBorderCounts">FT_Stroker_GetBorderCounts</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_ISO</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_KERNING_UNSCALED</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_GetCounts">FT_Stroker_GetCounts</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_MACINTOSH</a></td></tr>
+<tr><td><a href="ft2-base_interface.html#FT_Kerning_Mode">FT_Kerning_Mode</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineCap">FT_Stroker_LineCap</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_MICROSOFT</a></td></tr>
+<tr><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_DEFAULT</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineJoin">FT_Stroker_LineJoin</a></td><td><a href="ft2-truetype_tables.html#TT_PLATFORM_XXX">TT_PLATFORM_XXX</a></td></tr>
+<tr><td><a href="ft2-header_file_macros.html#FT_LCD_FILTER_H">FT_LCD_FILTER_H</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_LineTo">FT_Stroker_LineTo</a></td><td><a href="ft2-truetype_tables.html#TT_Postscript">TT_Postscript</a></td></tr>
+<tr><td><a href="ft2-lcd_filtering.html#FT_LcdFilter">FT_LCD_FILTER_LEGACY</a></td><td><a href="ft2-glyph_stroker.html#FT_Stroker_New">FT_Stroker_New</a></td><td><a href="ft2-truetype_tables.html#TT_VertHeader">TT_VertHeader</a></td></tr>
</table>
<hr>
<table><tr><td width="100%"></td>
<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><font size=-2>generated on Thu Mar 12 10:57:36 2009</font></center></body>
+<center><font size=-2>generated on Sat Feb 13 08:32:30 2010</font></center></body>
</html>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-lcd_filtering.html b/src/3rdparty/freetype/docs/reference/ft2-lcd_filtering.html
index 9ae6a5f992..04da06ffd8 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-lcd_filtering.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-lcd_filtering.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
LCD Filtering
diff --git a/src/3rdparty/freetype/docs/reference/ft2-list_processing.html b/src/3rdparty/freetype/docs/reference/ft2-list_processing.html
index bf0df50d0e..47552340fa 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-list_processing.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-list_processing.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
List Processing
@@ -55,6 +55,14 @@ List Processing
<table align=center width="75%"><tr><td>
<h4><a name="FT_List">FT_List</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_ListRec_* <b>FT_List</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a list record (see <a href="ft2-list_processing.html#FT_ListRec">FT_ListRec</a>).</p>
</td></tr></table><br>
</td></tr></table>
@@ -66,6 +74,14 @@ List Processing
<table align=center width="75%"><tr><td>
<h4><a name="FT_ListNode">FT_ListNode</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPES_H (freetype/fttypes.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_ListNodeRec_* <b>FT_ListNode</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>Many elements and objects in FreeType are listed through an <a href="ft2-list_processing.html#FT_List">FT_List</a> record (see <a href="ft2-list_processing.html#FT_ListRec">FT_ListRec</a>). As its name suggests, an FT_ListNode is a handle to a single list element.</p>
</td></tr></table><br>
</td></tr></table>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-lzw.html b/src/3rdparty/freetype/docs/reference/ft2-lzw.html
index 5ef0a5f7ab..fbd0f35953 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-lzw.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-lzw.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
LZW Streams
diff --git a/src/3rdparty/freetype/docs/reference/ft2-mac_specific.html b/src/3rdparty/freetype/docs/reference/ft2-mac_specific.html
index 3528c72db7..ff64964daa 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-mac_specific.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-mac_specific.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Mac Specific Interface
diff --git a/src/3rdparty/freetype/docs/reference/ft2-module_management.html b/src/3rdparty/freetype/docs/reference/ft2-module_management.html
index e621f27745..a571c87df8 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-module_management.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-module_management.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Module Management
@@ -340,6 +340,7 @@ Defined in FT_MODULE_H (freetype/ftmodapi.h).
</pre></table><br>
<table align=center width="87%"><tr><td>
<p>This function is used to create a new FreeType library instance from a given memory object. It is thus possible to use libraries with distinct memory allocators within the same program.</p>
+<p>Normally, you would call this function (followed by a call to <a href="ft2-module_management.html#FT_Add_Default_Modules">FT_Add_Default_Modules</a> or a series of calls to <a href="ft2-module_management.html#FT_Add_Module">FT_Add_Module</a>) instead of <a href="ft2-base_interface.html#FT_Init_FreeType">FT_Init_FreeType</a> to initialize the FreeType library.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>input</b></em></td></tr><tr><td>
<p></p>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-multiple_masters.html b/src/3rdparty/freetype/docs/reference/ft2-multiple_masters.html
index a977f87f79..ac2251536a 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-multiple_masters.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-multiple_masters.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Multiple Masters
diff --git a/src/3rdparty/freetype/docs/reference/ft2-ot_validation.html b/src/3rdparty/freetype/docs/reference/ft2-ot_validation.html
index e2289ef093..06c7db3753 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-ot_validation.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-ot_validation.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
OpenType Validation
diff --git a/src/3rdparty/freetype/docs/reference/ft2-outline_processing.html b/src/3rdparty/freetype/docs/reference/ft2-outline_processing.html
index d0b670ed96..c0c0bc8ea7 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-outline_processing.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-outline_processing.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Outline Processing
@@ -79,6 +79,11 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
} <b>FT_Outline</b>;
+ /* Following limits must be consistent with */
+ /* <b>FT_Outline</b>.{n_contours,n_points} */
+#define FT_OUTLINE_CONTOURS_MAX SHRT_MAX
+#define FT_OUTLINE_POINTS_MAX SHRT_MAX
+
</pre></table><br>
<table align=center width="87%"><tr><td>
<p>This structure is used to describe an outline to the scan-line converter.</p>
@@ -96,8 +101,11 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
<p>A pointer to an array of &lsquo;n_points&rsquo; <a href="ft2-basic_types.html#FT_Vector">FT_Vector</a> elements, giving the outline's point coordinates.</p>
</td></tr>
<tr valign=top><td><b>tags</b></td><td>
-<p>A pointer to an array of &lsquo;n_points&rsquo; chars, giving each outline point's type. If bit&nbsp;0 is unset, the point is &lsquo;off&rsquo; the curve, i.e., a Bézier control point, while it is &lsquo;on&rsquo; when set.</p>
+<p>A pointer to an array of &lsquo;n_points&rsquo; chars, giving each outline point's type.</p>
+<p>If bit&nbsp;0 is unset, the point is &lsquo;off&rsquo; the curve, i.e., a Bézier control point, while it is &lsquo;on&rsquo; if set.</p>
<p>Bit&nbsp;1 is meaningful for &lsquo;off&rsquo; points only. If set, it indicates a third-order Bézier arc control point; and a second-order control point if unset.</p>
+<p>If bit&nbsp;2 is set, bits 5-7 contain the drop-out mode (as defined in the OpenType specification; the value is the same as the argument to the SCANMODE instruction).</p>
+<p>Bits 3 and&nbsp;4 are reserved for internal purposes.</p>
</td></tr>
<tr valign=top><td><b>contours</b></td><td>
<p>An array of &lsquo;n_contours&rsquo; shorts, giving the end point of each contour within the outline. For example, the first contour is defined by the points &lsquo;0&rsquo; to &lsquo;contours[0]&rsquo;, the second one is defined by the points &lsquo;contours[0]+1&rsquo; to &lsquo;contours[1]&rsquo;, etc.</p>
@@ -107,6 +115,9 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
</td></tr>
</table>
</td></tr></table>
+<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
+<p>The B/W rasterizer only checks bit&nbsp;2 in the &lsquo;tags&rsquo; array for the first point of each contour. The drop-out mode as given with <a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_IGNORE_DROPOUTS</a>, <a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_SMART_DROPOUTS</a>, and <a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_INCLUDE_STUBS</a> in &lsquo;flags&rsquo; is then overridden.</p>
+</td></tr></table>
</td></tr></table>
<hr width="75%">
<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
@@ -146,7 +157,7 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
</td></tr>
<tr valign=top><td colspan=0><b>FT_OUTLINE_EVEN_ODD_FILL</b></td></tr>
<tr valign=top><td></td><td>
-<p>By default, outlines are filled using the non-zero winding rule. If set to 1, the outline will be filled using the even-odd fill rule (only works with the smooth raster).</p>
+<p>By default, outlines are filled using the non-zero winding rule. If set to 1, the outline will be filled using the even-odd fill rule (only works with the smooth rasterizer).</p>
</td></tr>
<tr valign=top><td colspan=0><b>FT_OUTLINE_REVERSE_FILL</b></td></tr>
<tr valign=top><td></td><td>
@@ -154,15 +165,15 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
</td></tr>
<tr valign=top><td colspan=0><b>FT_OUTLINE_IGNORE_DROPOUTS</b></td></tr>
<tr valign=top><td></td><td>
-<p>By default, the scan converter will try to detect drop-outs in an outline and correct the glyph bitmap to ensure consistent shape continuity. If set, this flag hints the scan-line converter to ignore such cases.</p>
+<p>By default, the scan converter will try to detect drop-outs in an outline and correct the glyph bitmap to ensure consistent shape continuity. If set, this flag hints the scan-line converter to ignore such cases. See below for more information.</p>
</td></tr>
<tr valign=top><td colspan=0><b>FT_OUTLINE_SMART_DROPOUTS</b></td></tr>
<tr valign=top><td></td><td>
-<p>Select smart dropout control. If unset, use simple dropout control. Ignored if <a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_IGNORE_DROPOUTS</a> is set.</p>
+<p>Select smart dropout control. If unset, use simple dropout control. Ignored if <a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_IGNORE_DROPOUTS</a> is set. See below for more information.</p>
</td></tr>
<tr valign=top><td colspan=0><b>FT_OUTLINE_INCLUDE_STUBS</b></td></tr>
<tr valign=top><td></td><td>
-<p>If set, turn pixels on for &lsquo;stubs&rsquo;, otherwise exclude them. Ignored if <a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_IGNORE_DROPOUTS</a> is set.</p>
+<p>If set, turn pixels on for &lsquo;stubs&rsquo;, otherwise exclude them. Ignored if <a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_IGNORE_DROPOUTS</a> is set. See below for more information.</p>
</td></tr>
<tr valign=top><td colspan=0><b>FT_OUTLINE_HIGH_PRECISION</b></td></tr>
<tr valign=top><td></td><td>
@@ -174,6 +185,8 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
</table>
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
+<p>The flags <a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_IGNORE_DROPOUTS</a>, <a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_SMART_DROPOUTS</a>, and <a href="ft2-outline_processing.html#FT_OUTLINE_FLAGS">FT_OUTLINE_INCLUDE_STUBS</a> are ignored by the smooth rasterizer.</p>
+<p>There exists a second mechanism to pass the drop-out mode to the B/W rasterizer; see the &lsquo;tags&rsquo; field in <a href="ft2-outline_processing.html#FT_Outline">FT_Outline</a>.</p>
<p>Please refer to the description of the &lsquo;SCANTYPE&rsquo; instruction in the OpenType specification (in file &lsquo;ttinst1.doc&rsquo;) how simple drop-outs, smart drop-outs, and stubs are defined.</p>
</td></tr></table>
</td></tr></table>
@@ -706,7 +719,7 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
</pre></table><br>
<table align=center width="87%"><tr><td>
-<p>A function pointer type use to describe the signature of a &lsquo;conic to&rsquo; function during outline walking/decomposition.</p>
+<p>A function pointer type used to describe the signature of a &lsquo;conic to&rsquo; function during outline walking or decomposition.</p>
<p>A &lsquo;conic to&rsquo; is emitted to indicate a second-order Bézier arc in the outline.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>input</b></em></td></tr><tr><td>
@@ -749,7 +762,7 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
</pre></table><br>
<table align=center width="87%"><tr><td>
-<p>A function pointer type used to describe the signature of a &lsquo;cubic to&rsquo; function during outline walking/decomposition.</p>
+<p>A function pointer type used to describe the signature of a &lsquo;cubic to&rsquo; function during outline walking or decomposition.</p>
<p>A &lsquo;cubic to&rsquo; is emitted to indicate a third-order Bézier arc.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>input</b></em></td></tr><tr><td>
@@ -799,7 +812,7 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
</pre></table><br>
<table align=center width="87%"><tr><td>
-<p>A structure to hold various function pointers used during outline decomposition in order to emit segments, conic, and cubic Béziers, as well as &lsquo;move to&rsquo; and &lsquo;close to&rsquo; operations.</p>
+<p>A structure to hold various function pointers used during outline decomposition in order to emit segments, conic, and cubic Béziers.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>fields</b></em></td></tr><tr><td>
<p></p>
@@ -830,7 +843,7 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
x' = (x &lt;&lt; shift) - delta
y' = (x &lt;&lt; shift) - delta
</pre>
-<p>Set the value of &lsquo;shift&rsquo; and &lsquo;delta&rsquo; to&nbsp;0 to get the original point coordinates.</p>
+<p>Set the values of &lsquo;shift&rsquo; and &lsquo;delta&rsquo; to&nbsp;0 to get the original point coordinates.</p>
</td></tr></table>
</td></tr></table>
<hr width="75%">
@@ -852,7 +865,7 @@ Defined in FT_OUTLINE_H (freetype/ftoutln.h).
</pre></table><br>
<table align=center width="87%"><tr><td>
-<p>Walk over an outline's structure to decompose it into individual segments and Bézier arcs. This function is also able to emit &lsquo;move to&rsquo; and &lsquo;close to&rsquo; operations to indicate the start and end of new contours in the outline.</p>
+<p>Walk over an outline's structure to decompose it into individual segments and Bézier arcs. This function also emits &lsquo;move to&rsquo; operations to indicate the start of new contours in the outline.</p>
</td></tr></table><br>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>input</b></em></td></tr><tr><td>
<p></p>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-pfr_fonts.html b/src/3rdparty/freetype/docs/reference/ft2-pfr_fonts.html
index 8edf34ea96..2b5e146e0b 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-pfr_fonts.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-pfr_fonts.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
PFR Fonts
diff --git a/src/3rdparty/freetype/docs/reference/ft2-quick_advance.html b/src/3rdparty/freetype/docs/reference/ft2-quick_advance.html
index c832d437cf..9a509484b7 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-quick_advance.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-quick_advance.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Quick retrieval of advance values
@@ -52,6 +52,14 @@ Quick retrieval of advance values
<table align=center width="75%"><tr><td>
<h4><a name="FT_ADVANCE_FLAG_FAST_ONLY">FT_ADVANCE_FLAG_FAST_ONLY</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_ADVANCES_H (freetype/ftadvanc.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_ADVANCE_FLAG_FAST_ONLY</b> 0x20000000UL
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A bit-flag to be OR-ed with the &lsquo;flags&rsquo; parameter of the <a href="ft2-quick_advance.html#FT_Get_Advance">FT_Get_Advance</a> and <a href="ft2-quick_advance.html#FT_Get_Advances">FT_Get_Advances</a> functions.</p>
<p>If set, it indicates that you want these functions to fail if the corresponding hinting mode or font driver doesn't allow for very quick advance computation.</p>
<p>Typically, glyphs which are either unscaled, unhinted, bitmapped, or light-hinted can have their advance width computed very quickly.</p>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-raster.html b/src/3rdparty/freetype/docs/reference/ft2-raster.html
index 9840eb4492..ee0e38bb3e 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-raster.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-raster.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Scanline Converter
@@ -55,6 +55,14 @@ Scanline Converter
<table align=center width="75%"><tr><td>
<h4><a name="FT_Raster">FT_Raster</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_IMAGE_H (freetype/ftimage.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_RasterRec_* <b>FT_Raster</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle (pointer) to a raster object. Each object can be used independently to convert an outline into a bitmap or pixmap.</p>
</td></tr></table><br>
</td></tr></table>
@@ -294,7 +302,7 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
<span class="keyword">const</span> <span class="keyword">void</span>* source;
<span class="keyword">int</span> flags;
<a href="ft2-raster.html#FT_SpanFunc">FT_SpanFunc</a> gray_spans;
- <a href="ft2-raster.html#FT_SpanFunc">FT_SpanFunc</a> black_spans;
+ <a href="ft2-raster.html#FT_SpanFunc">FT_SpanFunc</a> black_spans; /* doesn't work! */
<a href="ft2-raster.html#FT_Raster_BitTest_Func">FT_Raster_BitTest_Func</a> bit_test; /* doesn't work! */
<a href="ft2-raster.html#FT_Raster_BitSet_Func">FT_Raster_BitSet_Func</a> bit_set; /* doesn't work! */
<span class="keyword">void</span>* user;
@@ -322,7 +330,7 @@ Defined in FT_IMAGE_H (freetype/ftimage.h).
<p>The gray span drawing callback.</p>
</td></tr>
<tr valign=top><td><b>black_spans</b></td><td>
-<p>The black span drawing callback.</p>
+<p>The black span drawing callback. UNIMPLEMENTED!</p>
</td></tr>
<tr valign=top><td><b>bit_test</b></td><td>
<p>The bit test callback. UNIMPLEMENTED!</p>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-sfnt_names.html b/src/3rdparty/freetype/docs/reference/ft2-sfnt_names.html
index 94cddd8786..ff859bdccd 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-sfnt_names.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-sfnt_names.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,14 +35,18 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
SFNT Names
</h1></center>
<h2>Synopsis</h2>
<table align=center cellspacing=5 cellpadding=0 border=0>
-<tr><td></td><td><a href="#FT_SfntName">FT_SfntName</a></td><td></td><td><a href="#FT_Get_Sfnt_Name_Count">FT_Get_Sfnt_Name_Count</a></td><td></td><td><a href="#FT_Get_Sfnt_Name">FT_Get_Sfnt_Name</a></td></tr>
+<tr><td></td><td><a href="#FT_SfntName">FT_SfntName</a></td></tr>
+<tr><td></td><td><a href="#FT_Get_Sfnt_Name_Count">FT_Get_Sfnt_Name_Count</a></td></tr>
+<tr><td></td><td><a href="#FT_Get_Sfnt_Name">FT_Get_Sfnt_Name</a></td></tr>
+<tr><td></td><td><a href="#FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY">FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY</a></td></tr>
+<tr><td></td><td><a href="#FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY">FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY</a></td></tr>
</table><br><br>
<table align=center width="87%"><tr><td>
@@ -177,7 +181,7 @@ Defined in FT_SFNT_NAMES_H (freetype/ftsnames.h).
<p>FreeType error code. 0&nbsp;means success.</p>
</td></tr></table>
<table align=center width="87%" cellpadding=5><tr bgcolor="#EEEEFF"><td><em><b>note</b></em></td></tr><tr><td>
-<p>The &lsquo;string&rsquo; array returned in the &lsquo;aname&rsquo; structure is not null-terminated.</p>
+<p>The &lsquo;string&rsquo; array returned in the &lsquo;aname&rsquo; structure is not null-terminated. The application should deallocate it if it is no longer in use.</p>
<p>Use <a href="ft2-sfnt_names.html#FT_Get_Sfnt_Name_Count">FT_Get_Sfnt_Name_Count</a> to get the total number of available &lsquo;name&rsquo; table entries, then do a loop until you get the right platform, encoding, and name ID.</p>
</td></tr></table>
</td></tr></table>
@@ -186,5 +190,43 @@ Defined in FT_SFNT_NAMES_H (freetype/ftsnames.h).
<td width="100%"></td>
<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+<table align=center width="75%"><tr><td>
+<h4><a name="FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY">FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY</a></h4>
+<table align=center width="87%"><tr><td>
+Defined in FT_SFNT_NAMES_H (freetype/ftsnames.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY</b> <a href="ft2-basic_types.html#FT_MAKE_TAG">FT_MAKE_TAG</a>( 'i', 'g', 'p', 'f' )
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
+<p>A constant used as the tag of <a href="ft2-base_interface.html#FT_Parameter">FT_Parameter</a> structures to make FT_Open_Face() ignore preferred family subfamily names in &lsquo;name&rsquo; table since OpenType version 1.4. For backwards compatibility with legacy systems which has 4-face-per-family restriction.</p>
+</td></tr></table><br>
+</td></tr></table>
+<hr width="75%">
+<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+
+<table align=center width="75%"><tr><td>
+<h4><a name="FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY">FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY</a></h4>
+<table align=center width="87%"><tr><td>
+Defined in FT_SFNT_NAMES_H (freetype/ftsnames.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY</b> <a href="ft2-basic_types.html#FT_MAKE_TAG">FT_MAKE_TAG</a>( 'i', 'g', 'p', 's' )
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
+<p>A constant used as the tag of <a href="ft2-base_interface.html#FT_Parameter">FT_Parameter</a> structures to make FT_Open_Face() ignore preferred subfamily names in &lsquo;name&rsquo; table since OpenType version 1.4. For backwards compatibility with legacy systems which has 4-face-per-family restriction.</p>
+</td></tr></table><br>
+</td></tr></table>
+<hr width="75%">
+<table align=center width="75%"><tr><td><font size=-2>[<a href="ft2-index.html">Index</a>]</font></td>
+<td width="100%"></td>
+<td><font size=-2>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
+
</body>
</html>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-sizes_management.html b/src/3rdparty/freetype/docs/reference/ft2-sizes_management.html
index 324e584c50..1c48be997f 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-sizes_management.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-sizes_management.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Size Management
diff --git a/src/3rdparty/freetype/docs/reference/ft2-system_interface.html b/src/3rdparty/freetype/docs/reference/ft2-system_interface.html
index 809e2a7705..ed50f8ad5d 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-system_interface.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-system_interface.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
System Interface
@@ -54,6 +54,14 @@ System Interface
<table align=center width="75%"><tr><td>
<h4><a name="FT_Memory">FT_Memory</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_SYSTEM_H (freetype/ftsystem.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_MemoryRec_* <b>FT_Memory</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a given memory manager object, defined with an <a href="ft2-system_interface.html#FT_MemoryRec">FT_MemoryRec</a> structure.</p>
</td></tr></table><br>
</td></tr></table>
@@ -220,6 +228,14 @@ Defined in FT_SYSTEM_H (freetype/ftsystem.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_Stream">FT_Stream</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_SYSTEM_H (freetype/ftsystem.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_StreamRec_* <b>FT_Stream</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to an input stream.</p>
</td></tr></table><br>
</td></tr></table>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-toc.html b/src/3rdparty/freetype/docs/reference/ft2-toc.html
index cb51bdbea9..a2330f6380 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-toc.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-toc.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -34,7 +34,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>Table of Contents</h1></center>
<br><table align=center width="75%"><tr><td><h2>General Remarks</h2><ul class="empty"><li>
@@ -211,5 +211,5 @@
<td width="100%"></td>
</tr></table>
-<center><font size=-2>generated on Thu Mar 12 10:57:36 2009</font></center></body>
+<center><font size=-2>generated on Sat Feb 13 08:32:30 2010</font></center></body>
</html>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-truetype_engine.html b/src/3rdparty/freetype/docs/reference/ft2-truetype_engine.html
index 007e8331a5..45369ea882 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-truetype_engine.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-truetype_engine.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
The TrueType Engine
diff --git a/src/3rdparty/freetype/docs/reference/ft2-truetype_tables.html b/src/3rdparty/freetype/docs/reference/ft2-truetype_tables.html
index 6d83a1a505..c2bdb192b5 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-truetype_tables.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-truetype_tables.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
TrueType Tables
@@ -1197,6 +1197,14 @@ Defined in FT_TRUETYPE_TABLES_H (freetype/tttables.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_PARAM_TAG_UNPATENTED_HINTING">FT_PARAM_TAG_UNPATENTED_HINTING</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_UNPATENTED_HINTING_H (freetype/ttunpat.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+#define <b>FT_PARAM_TAG_UNPATENTED_HINTING</b> <a href="ft2-basic_types.html#FT_MAKE_TAG">FT_MAKE_TAG</a>( 'u', 'n', 'p', 'a' )
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A constant used as the tag of an <a href="ft2-base_interface.html#FT_Parameter">FT_Parameter</a> structure to indicate that unpatented methods only should be used by the TrueType bytecode interpreter for a typeface opened by <a href="ft2-base_interface.html#FT_Open_Face">FT_Open_Face</a>.</p>
</td></tr></table><br>
</td></tr></table>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-type1_tables.html b/src/3rdparty/freetype/docs/reference/ft2-type1_tables.html
index 8eaa3f9a10..44ca9772d0 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-type1_tables.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-type1_tables.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Type 1 Tables
@@ -86,6 +86,14 @@ Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
<table align=center width="75%"><tr><td>
<h4><a name="PS_FontInfo">PS_FontInfo</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> PS_FontInfoRec_* <b>PS_FontInfo</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a <a href="ft2-type1_tables.html#PS_FontInfoRec">PS_FontInfoRec</a> structure.</p>
</td></tr></table><br>
</td></tr></table>
@@ -97,6 +105,14 @@ Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
<table align=center width="75%"><tr><td>
<h4><a name="T1_FontInfo">T1_FontInfo</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <a href="ft2-type1_tables.html#PS_FontInfoRec">PS_FontInfoRec</a> <b>T1_FontInfo</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>This type is equivalent to <a href="ft2-type1_tables.html#PS_FontInfoRec">PS_FontInfoRec</a>. It is deprecated but kept to maintain source compatibility between various versions of FreeType.</p>
</td></tr></table><br>
</td></tr></table>
@@ -165,6 +181,14 @@ Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
<table align=center width="75%"><tr><td>
<h4><a name="PS_Private">PS_Private</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> PS_PrivateRec_* <b>PS_Private</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a <a href="ft2-type1_tables.html#PS_PrivateRec">PS_PrivateRec</a> structure.</p>
</td></tr></table><br>
</td></tr></table>
@@ -176,6 +200,14 @@ Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
<table align=center width="75%"><tr><td>
<h4><a name="T1_Private">T1_Private</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <a href="ft2-type1_tables.html#PS_PrivateRec">PS_PrivateRec</a> <b>T1_Private</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>This type is equivalent to <a href="ft2-type1_tables.html#PS_PrivateRec">PS_PrivateRec</a>. It is deprecated but kept to maintain source compatibility between various versions of FreeType.</p>
</td></tr></table><br>
</td></tr></table>
@@ -266,6 +298,14 @@ Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
<table align=center width="75%"><tr><td>
<h4><a name="CID_FaceDict">CID_FaceDict</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> CID_FaceDictRec_* <b>CID_FaceDict</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a <a href="ft2-type1_tables.html#CID_FaceDictRec">CID_FaceDictRec</a> structure.</p>
</td></tr></table><br>
</td></tr></table>
@@ -323,6 +363,14 @@ Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
<table align=center width="75%"><tr><td>
<h4><a name="CID_FaceInfo">CID_FaceInfo</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> CID_FaceInfoRec_* <b>CID_FaceInfo</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to a <a href="ft2-type1_tables.html#CID_FaceInfoRec">CID_FaceInfoRec</a> structure.</p>
</td></tr></table><br>
</td></tr></table>
@@ -334,6 +382,14 @@ Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
<table align=center width="75%"><tr><td>
<h4><a name="CID_Info">CID_Info</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_TYPE1_TABLES_H (freetype/t1tables.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <a href="ft2-type1_tables.html#CID_FaceInfoRec">CID_FaceInfoRec</a> <b>CID_Info</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>This type is equivalent to <a href="ft2-type1_tables.html#CID_FaceInfoRec">CID_FaceInfoRec</a>. It is deprecated but kept to maintain source compatibility between various versions of FreeType.</p>
</td></tr></table><br>
</td></tr></table>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-user_allocation.html b/src/3rdparty/freetype/docs/reference/ft2-user_allocation.html
index d3b48b1286..98ab2f9e1a 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-user_allocation.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-user_allocation.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
User allocation
diff --git a/src/3rdparty/freetype/docs/reference/ft2-version.html b/src/3rdparty/freetype/docs/reference/ft2-version.html
index 2c7d9c1ef7..9949b8f0b3 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-version.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-version.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
FreeType Version
@@ -58,7 +58,7 @@ Defined in FT_FREETYPE_H (freetype/freetype.h).
#define <a href="ft2-version.html#FREETYPE_XXX">FREETYPE_MAJOR</a> 2
#define <a href="ft2-version.html#FREETYPE_XXX">FREETYPE_MINOR</a> 3
-#define <a href="ft2-version.html#FREETYPE_XXX">FREETYPE_PATCH</a> 9
+#define <a href="ft2-version.html#FREETYPE_XXX">FREETYPE_PATCH</a> 12
</pre></table><br>
<table align=center width="87%"><tr><td>
diff --git a/src/3rdparty/freetype/docs/reference/ft2-winfnt_fonts.html b/src/3rdparty/freetype/docs/reference/ft2-winfnt_fonts.html
index 7c850d7691..82ada84323 100644
--- a/src/3rdparty/freetype/docs/reference/ft2-winfnt_fonts.html
+++ b/src/3rdparty/freetype/docs/reference/ft2-winfnt_fonts.html
@@ -3,7 +3,7 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-<title>FreeType-2.3.9 API Reference</title>
+<title>FreeType-2.3.12 API Reference</title>
<style type="text/css">
body { font-family: Verdana, Geneva, Arial, Helvetica, serif;
color: #000000;
@@ -35,7 +35,7 @@
<table align=center><tr><td><font size=-1>[<a href="ft2-index.html">Index</a>]</font></td>
<td width="100%"></td>
<td><font size=-1>[<a href="ft2-toc.html">TOC</a>]</font></td></tr></table>
-<center><h1>FreeType-2.3.9 API Reference</h1></center>
+<center><h1>FreeType-2.3.12 API Reference</h1></center>
<center><h1>
Window FNT Files
@@ -215,6 +215,14 @@ Defined in FT_WINFONTS_H (freetype/ftwinfnt.h).
<table align=center width="75%"><tr><td>
<h4><a name="FT_WinFNT_Header">FT_WinFNT_Header</a></h4>
<table align=center width="87%"><tr><td>
+Defined in FT_WINFONTS_H (freetype/ftwinfnt.h).
+</td></tr></table><br>
+<table align=center width="87%"><tr bgcolor="#D6E8FF"><td><pre>
+
+ <span class="keyword">typedef</span> <span class="keyword">struct</span> FT_WinFNT_HeaderRec_* <b>FT_WinFNT_Header</b>;
+
+</pre></table><br>
+<table align=center width="87%"><tr><td>
<p>A handle to an <a href="ft2-winfnt_fonts.html#FT_WinFNT_HeaderRec">FT_WinFNT_HeaderRec</a> structure.</p>
</td></tr></table><br>
</td></tr></table>
diff --git a/src/3rdparty/freetype/docs/release b/src/3rdparty/freetype/docs/release
index e93f430df8..5e2d51f880 100644
--- a/src/3rdparty/freetype/docs/release
+++ b/src/3rdparty/freetype/docs/release
@@ -15,10 +15,14 @@ How to prepare a new release
. docs/VERSION.DLL: Document changed `version_info'.
-. ChangeLog: Announce new release (both in freetype2 and ft2demos
- modules).
+. ChangeLog: Announce new release (both in the freetype2 and
+ freetype2-demos modules).
-. Copy the CVS archive to another directory and run
+. Clone the git archive to another directory with
+
+ git clone -l -s . ../freetype2.test
+
+ or something like this and run
make distclean; make devel; make
make distclean; make devel; make multi
@@ -29,16 +33,26 @@ How to prepare a new release
make distclean; ./configure; make
make distclean; ./configure CC=g++; make
- to test compilation with both gcc and g++.
+ in the cloned repository to test compilation with both gcc and g++.
+
+. Test C++ compilation for freetype2-demos too (using `git clone' as
+ above).
+
+. Run src/tools/chktrcmp.py and check that there are no undefined
+ trace_XXXX macros.
-. Test C++ compilation for ft2demos too.
+. Tag the git repositories (freetype2, freetype2-demos) with
-. Tag the CVS (freetype2, ft2demos).
+ git tag VER-<version> -m "" -u <committer>
+
+ and push the tags with
+
+ git push --tags
TODO: Tag the home page CVS on savannah.nongnu.org.
-. Say `make dist' in both the freetype2 and ft2demos modules to
- generate the .tar.gz, .tar.bz2, and .zip files.
+. Say `make dist' in both the freetype2 and freetype2-demos modules
+ to generate the .tar.gz, .tar.bz2, and .zip files.
. Create the doc bundles (freetype-doc-<version>.tar.gz,
freetype-doc-<version>.tar.bz2, ftdoc<version>.zip). This is
@@ -56,7 +70,7 @@ How to prepare a new release
#!/bin/sh
- VERSION=2.3.7
+ VERSION=2.3.11
SAVANNAH_USER=wl
SOURCEFORGE_USER=wlemb
@@ -66,22 +80,19 @@ How to prepare a new release
version=`echo $VERSION | sed "s/\\.//g"`
- UNIX_PACKAGES="freetype ft2demos freetype-doc"
- WINDOWS_PACKAGES="ft ftdmo ftdoc"
- UNIX_ZIP="tar.gz tar.bz2"
- WINDOWS_ZIP="zip"
+ FREETYPE_PACKAGES="freetype-$VERSION.tar.gz \
+ freetype-$VERSION.tar.bz2 \
+ ft$version.zip"
+ FT2DEMOS_PACKAGES="ft2demos-$VERSION.tar.gz \
+ ft2demos-$VERSION.tar.bz2 \
+ ftdmo$version.zip"
+ FTDOC_PACKAGES="freetype-doc-$VERSION.tar.gz \
+ freetype-doc-$VERSION.tar.bz2 \
+ ftdoc$version.zip"
- PACKAGE_LIST=
- for i in $UNIX_PACKAGES; do
- for j in $UNIX_ZIP; do
- PACKAGE_LIST="$PACKAGE_LIST $i-$VERSION.$j"
- done
- done
- for i in $WINDOWS_PACKAGES; do
- for j in $WINDOWS_ZIP; do
- PACKAGE_LIST="$PACKAGE_LIST $i$version.$j"
- done
- done
+ PACKAGE_LIST="$FREETYPE_PACKAGES \
+ $FT2DEMOS_PACKAGES \
+ $FTDOC_PACKAGES"
set -e
unset passphrase
@@ -107,16 +118,34 @@ How to prepare a new release
echo $passphrase | $GPG --passphrase-fd 0 -ba -o $f.sig $f
done
- SIGNATURE_LIST=
- for i in $PACKAGE_LIST; do
- SIGNATURE_LIST="$SIGNATURE_LIST $i.sig"
+ FREETYPE_SIGNATURES=
+ for i in $FREETYPE_PACKAGES; do
+ FREETYPE_SIGNATURES="$FREETYPE_SIGNATURES $i.sig"
+ done
+
+ FT2DEMOS_SIGNATURES=
+ for i in $FT2DEMOS_PACKAGES; do
+ FT2DEMOS_SIGNATURES="$FT2DEMOS_SIGNATURES $i.sig"
done
+ FTDOC_SIGNATURES=
+ for i in $FTDOC_PACKAGES; do
+ FTDOC_SIGNATURES="$FTDOC_SIGNATURES $i.sig"
+ done
+
+ SIGNATURE_LIST="$FREETYPE_SIGNATURES \
+ $FT2DEMOS_SIGNATURES \
+ $FTDOC_SIGNATURES"
+
scp $PACKAGE_LIST $SIGNATURE_LIST \
$SAVANNAH_USER@dl.sv.nongnu.org:/releases/freetype/
- rsync -avP -e ssh $PACKAGE_LIST $SIGNATURE_LIST \
- $SOURCEFORGE_USER@frs.sf.net:uploads/
+ rsync -avP -e ssh $FREETYPE_PACKAGES $FREETYPE_SIGNATURES \
+ $SOURCEFORGE_USER,freetype@frs.sf.net:/home/frs/project/f/fr/freetype/freetype2/$VERSION/
+ rsync -avP -e ssh $FT2DEMOS_PACKAGES $FT2DEMOS_SIGNATURES \
+ $SOURCEFORGE_USER,freetype@frs.sf.net:/home/frs/project/f/fr/freetype/freetype-demos/$VERSION/
+ rsync -avP -e ssh $FTDOC_PACKAGES $FTDOC_SIGNATURES \
+ $SOURCEFORGE_USER,freetype@frs.sf.net:/home/frs/project/f/fr/freetype/freetype-docs/$VERSION/
# EOF
@@ -153,7 +182,7 @@ How to prepare a new release
----------------------------------------------------------------------
-Copyright 2003, 2005, 2006, 2007 by
+Copyright 2003, 2005, 2006, 2007, 2009 by
David Turner, Robert Wilhelm, and Werner Lemberg.
This file is part of the FreeType project, and may only be used,
diff --git a/src/3rdparty/freetype/include/freetype/config/ftconfig.h b/src/3rdparty/freetype/include/freetype/config/ftconfig.h
index 3c0b8b1641..43d587e02b 100644
--- a/src/3rdparty/freetype/include/freetype/config/ftconfig.h
+++ b/src/3rdparty/freetype/include/freetype/config/ftconfig.h
@@ -4,7 +4,7 @@
/* */
/* ANSI-specific configuration file (specification only). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2006, 2007, 2008, 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -35,7 +35,6 @@
/* */
/*************************************************************************/
-
#ifndef __FTCONFIG_H__
#define __FTCONFIG_H__
@@ -306,9 +305,38 @@ FT_BEGIN_HEADER
/* Provide assembler fragments for performance-critical functions. */
/* These must be defined `static __inline__' with GCC. */
+#if defined( __CC_ARM ) || defined( __ARMCC__ ) /* RVCT */
+#define FT_MULFIX_ASSEMBLER FT_MulFix_arm
+
+ /* documentation is in freetype.h */
+
+ static __inline FT_Int32
+ FT_MulFix_arm( FT_Int32 a,
+ FT_Int32 b )
+ {
+ register FT_Int32 t, t2;
+
+
+ __asm
+ {
+ smull t2, t, b, a /* (lo=t2,hi=t) = a*b */
+ mov a, t, asr #31 /* a = (hi >> 31) */
+ add a, a, #0x8000 /* a += 0x8000 */
+ adds t2, t2, a /* t2 += a */
+ adc t, t, #0 /* t += carry */
+ mov a, t2, lsr #16 /* a = t2 >> 16 */
+ orr a, a, t, lsl #16 /* a |= t << 16 */
+ }
+ return a;
+ }
+
+#endif /* __CC_ARM || __ARMCC__ */
+
+
#ifdef __GNUC__
-#if defined( __arm__ ) && !defined( __thumb__ )
+#if defined( __arm__ ) && !defined( __thumb__ ) && \
+ !( defined( __CC_ARM ) || defined( __ARMCC__ ) )
#define FT_MULFIX_ASSEMBLER FT_MulFix_arm
/* documentation is in freetype.h */
@@ -333,7 +361,7 @@ FT_BEGIN_HEADER
return a;
}
-#endif /* __arm__ && !__thumb__ */
+#endif /* __arm__ && !__thumb__ && !( __CC_ARM || __ARMCC__ ) */
#if defined( i386 )
#define FT_MULFIX_ASSEMBLER FT_MulFix_i386
diff --git a/src/3rdparty/freetype/include/freetype/config/ftoption.h b/src/3rdparty/freetype/include/freetype/config/ftoption.h
index 597a2bb014..811dd3e38d 100644
--- a/src/3rdparty/freetype/include/freetype/config/ftoption.h
+++ b/src/3rdparty/freetype/include/freetype/config/ftoption.h
@@ -4,7 +4,8 @@
/* */
/* User-selectable configuration macros (specification only). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, */
+/* 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -85,9 +86,9 @@ FT_BEGIN_HEADER
/* */
/* This macro has no impact on the FreeType API, only on its */
/* _implementation_. For example, using FT_RENDER_MODE_LCD when calling */
- /* FT_Render_Glyph still generates a bitmap that is 3 times larger than */
- /* the original size; the difference will be that each triplet of */
- /* subpixels has R=G=B. */
+ /* FT_Render_Glyph still generates a bitmap that is 3 times wider than */
+ /* the original size in case this macro isn't defined; however, each */
+ /* triplet of subpixels has R=G=B. */
/* */
/* This is done to allow FreeType clients to run unmodified, forcing */
/* them to display normal gray-level anti-aliased glyphs. */
@@ -312,8 +313,9 @@ FT_BEGIN_HEADER
/* */
/* Allow the use of FT_Incremental_Interface to load typefaces that */
/* contain no glyph data, but supply it via a callback function. */
- /* This allows FreeType to be used with the PostScript language, using */
- /* the GhostScript interpreter. */
+ /* This is required by clients supporting document formats which */
+ /* supply font data incrementally as the document is parsed, such */
+ /* as the Ghostscript interpreter for the PostScript language. */
/* */
/* #define FT_CONFIG_OPTION_INCREMENTAL */
@@ -396,6 +398,20 @@ FT_BEGIN_HEADER
#undef FT_CONFIG_OPTION_USE_MODULE_ERRORS
+ /*************************************************************************/
+ /* */
+ /* Position Independent Code */
+ /* */
+ /* If this macro is set (which is _not_ the default), FreeType2 will */
+ /* avoid creating constants that require address fixups. Instead the */
+ /* constants will be moved into a struct and additional intialization */
+ /* code will be used. */
+ /* */
+ /* Setting this macro is needed for systems that prohibit address */
+ /* fixups, such as BREW. */
+ /* */
+/* #define FT_CONFIG_OPTION_PIC */
+
/*************************************************************************/
/*************************************************************************/
@@ -439,7 +455,7 @@ FT_BEGIN_HEADER
/* does not contain any glyph name though. */
/* */
/* Accessing SFNT names is done through the functions declared in */
- /* `freetype/ftnames.h'. */
+ /* `freetype/ftsnames.h'. */
/* */
#define TT_CONFIG_OPTION_SFNT_NAMES
@@ -457,6 +473,7 @@ FT_BEGIN_HEADER
#define TT_CONFIG_CMAP_FORMAT_8
#define TT_CONFIG_CMAP_FORMAT_10
#define TT_CONFIG_CMAP_FORMAT_12
+#define TT_CONFIG_CMAP_FORMAT_13
#define TT_CONFIG_CMAP_FORMAT_14
@@ -670,7 +687,7 @@ FT_BEGIN_HEADER
* is recommended to disable the macro since it reduces the library's code
* size and activates a few memory-saving optimizations as well.
*/
-#define FT_CONFIG_OPTION_OLD_INTERNALS
+/* #define FT_CONFIG_OPTION_OLD_INTERNALS */
/*
diff --git a/src/3rdparty/freetype/include/freetype/config/ftstdlib.h b/src/3rdparty/freetype/include/freetype/config/ftstdlib.h
index ce5557aef3..30ec14e74e 100644
--- a/src/3rdparty/freetype/include/freetype/config/ftstdlib.h
+++ b/src/3rdparty/freetype/include/freetype/config/ftstdlib.h
@@ -61,6 +61,7 @@
#define FT_CHAR_BIT CHAR_BIT
#define FT_INT_MAX INT_MAX
+#define FT_INT_MIN INT_MIN
#define FT_UINT_MAX UINT_MAX
#define FT_ULONG_MAX ULONG_MAX
diff --git a/src/3rdparty/freetype/include/freetype/freetype.h b/src/3rdparty/freetype/include/freetype/freetype.h
index 364388b5d6..942a740f00 100644
--- a/src/3rdparty/freetype/include/freetype/freetype.h
+++ b/src/3rdparty/freetype/include/freetype/freetype.h
@@ -4,7 +4,8 @@
/* */
/* FreeType high-level API and common types (specification only). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, */
+/* 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -231,6 +232,10 @@ FT_BEGIN_HEADER
/* vertAdvance :: */
/* Advance height for vertical layout. */
/* */
+ /* <Note> */
+ /* If not disabled with @FT_LOAD_NO_HINTING, the values represent */
+ /* dimensions of the hinted glyph (in case hinting is applicable). */
+ /* */
typedef struct FT_Glyph_Metrics_
{
FT_Pos width;
@@ -519,10 +524,7 @@ FT_BEGIN_HEADER
/* <Note> */
/* Despite the name, this enumeration lists specific character */
/* repertories (i.e., charsets), and not text encoding methods (e.g., */
- /* UTF-8, UTF-16, GB2312_EUC, etc.). */
- /* */
- /* Because of 32-bit charcodes defined in Unicode (i.e., surrogates), */
- /* all character codes must be expressed as FT_Longs. */
+ /* UTF-8, UTF-16, etc.). */
/* */
/* Other encodings might be defined in the future. */
/* */
@@ -536,6 +538,10 @@ FT_BEGIN_HEADER
/* Latin-1. Most fonts include a Unicode charmap, but not all */
/* of them. */
/* */
+ /* For example, if you want to access Unicode value U+1F028 (and */
+ /* the font contains it), use value 0x1F028 as the input value for */
+ /* @FT_Get_Char_Index. */
+ /* */
/* FT_ENCODING_MS_SYMBOL :: */
/* Corresponds to the Microsoft Symbol encoding, used to encode */
/* mathematical symbols in the 32..255 character code range. For */
@@ -1476,8 +1482,13 @@ FT_BEGIN_HEADER
/* important to perform correct WYSIWYG layout. */
/* Only relevant for outline glyphs. */
/* */
- /* advance :: This is the transformed advance width for the */
- /* glyph (in 26.6 fractional pixel format). */
+ /* advance :: This shorthand is, depending on */
+ /* @FT_LOAD_IGNORE_TRANSFORM, the transformed */
+ /* advance width for the glyph (in 26.6 */
+ /* fractional pixel format). As specified with */
+ /* @FT_LOAD_VERTICAL_LAYOUT, it uses either the */
+ /* `horiAdvance' or the `vertAdvance' value of */
+ /* `metrics' field. */
/* */
/* format :: This field indicates the format of the image */
/* contained in the glyph slot. Typically */
@@ -1651,6 +1662,11 @@ FT_BEGIN_HEADER
/* <Return> */
/* FreeType error code. 0~means success. */
/* */
+ /* <Note> */
+ /* In case you want to provide your own memory allocating routines, */
+ /* use @FT_New_Library instead, followed by a call to */
+ /* @FT_Add_Default_Modules (or a series of calls to @FT_Add_Module). */
+ /* */
FT_EXPORT( FT_Error )
FT_Init_FreeType( FT_Library *alibrary );
@@ -1737,7 +1753,8 @@ FT_BEGIN_HEADER
/* data :: A pointer to the parameter data. */
/* */
/* <Note> */
- /* The ID and function of parameters are driver-specific. */
+ /* The ID and function of parameters are driver-specific. See the */
+ /* various FT_PARAM_TAG_XXX flags for more information. */
/* */
typedef struct FT_Parameter_
{
@@ -3757,7 +3774,7 @@ FT_BEGIN_HEADER
*/
#define FREETYPE_MAJOR 2
#define FREETYPE_MINOR 3
-#define FREETYPE_PATCH 9
+#define FREETYPE_PATCH 12
/*************************************************************************/
diff --git a/src/3rdparty/freetype/include/freetype/ftbbox.h b/src/3rdparty/freetype/include/freetype/ftbbox.h
index 5cfb9ff052..01fe3fb0d1 100644
--- a/src/3rdparty/freetype/include/freetype/ftbbox.h
+++ b/src/3rdparty/freetype/include/freetype/ftbbox.h
@@ -61,7 +61,7 @@ FT_BEGIN_HEADER
/* Compute the exact bounding box of an outline. This is slower */
/* than computing the control box. However, it uses an advanced */
/* algorithm which returns _very_ quickly when the two boxes */
- /* coincide. Otherwise, the outline Bezier arcs are traversed to */
+ /* coincide. Otherwise, the outline Bézier arcs are traversed to */
/* extract their extrema. */
/* */
/* <Input> */
diff --git a/src/3rdparty/freetype/include/freetype/ftglyph.h b/src/3rdparty/freetype/include/freetype/ftglyph.h
index c3c57336c1..0b8f0c0444 100644
--- a/src/3rdparty/freetype/include/freetype/ftglyph.h
+++ b/src/3rdparty/freetype/include/freetype/ftglyph.h
@@ -355,10 +355,10 @@ FT_BEGIN_HEADER
/* */
/* <Description> */
/* Return a glyph's `control box'. The control box encloses all the */
- /* outline's points, including Bezier control points. Though it */
+ /* outline's points, including Bézier control points. Though it */
/* coincides with the exact bounding box for most glyphs, it can be */
/* slightly larger in some situations (like when rotating an outline */
- /* which contains Bezier outside arcs). */
+ /* which contains Bézier outside arcs). */
/* */
/* Computing the control box is very fast, while getting the bounding */
/* box can take much more time as it needs to walk over all segments */
@@ -468,7 +468,7 @@ FT_BEGIN_HEADER
/* // convert to a bitmap (default render mode + destroying old) */
/* if ( glyph->format != FT_GLYPH_FORMAT_BITMAP ) */
/* { */
- /* error = FT_Glyph_To_Bitmap( &glyph, FT_RENDER_MODE_DEFAULT, */
+ /* error = FT_Glyph_To_Bitmap( &glyph, FT_RENDER_MODE_NORMAL, */
/* 0, 1 ); */
/* if ( error ) // `glyph' unchanged */
/* ... */
diff --git a/src/3rdparty/freetype/include/freetype/ftimage.h b/src/3rdparty/freetype/include/freetype/ftimage.h
index 25a9b1b7ee..0272e92d2b 100644
--- a/src/3rdparty/freetype/include/freetype/ftimage.h
+++ b/src/3rdparty/freetype/include/freetype/ftimage.h
@@ -5,7 +5,8 @@
/* FreeType glyph image formats and default raster interface */
/* (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, */
+/* 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -51,10 +52,9 @@ FT_BEGIN_HEADER
/* FT_Pos */
/* */
/* <Description> */
- /* The type FT_Pos is a 32-bit integer used to store vectorial */
- /* coordinates. Depending on the context, these can represent */
- /* distances in integer font units, or 16.16, or 26.6 fixed float */
- /* pixel coordinates. */
+ /* The type FT_Pos is used to store vectorial coordinates. Depending */
+ /* on the context, these can represent distances in integer font */
+ /* units, or 16.16, or 26.6 fixed float pixel coordinates. */
/* */
typedef signed long FT_Pos;
@@ -99,6 +99,20 @@ FT_BEGIN_HEADER
/* */
/* yMax :: The vertical maximum (top-most). */
/* */
+ /* <Note> */
+ /* The bounding box is specified with the coordinates of the lower */
+ /* left and the upper right corner. In PostScript, those values are */
+ /* often called (llx,lly) and (urx,ury), respectively. */
+ /* */
+ /* If `yMin' is negative, this value gives the glyph's descender. */
+ /* Otherwise, the glyph doesn't descend below the baseline. */
+ /* Similarly, if `ymax' is positive, this value gives the glyph's */
+ /* ascender. */
+ /* */
+ /* `xMin' gives the horizontal distance from the glyph's origin to */
+ /* the left edge of the glyph's bounding box. If `xMin' is negative, */
+ /* the glyph extends to the left of the origin. */
+ /* */
typedef struct FT_BBox_
{
FT_Pos xMin, yMin;
@@ -254,6 +268,9 @@ FT_BEGIN_HEADER
/* flow. In all cases, the pitch is an offset to add */
/* to a bitmap pointer in order to go down one row. */
/* */
+ /* For the B/W rasterizer, `pitch' is always an even */
+ /* number. */
+ /* */
/* buffer :: A typeless pointer to the bitmap buffer. This */
/* value should be aligned on 32-bit boundaries in */
/* most cases. */
@@ -318,14 +335,23 @@ FT_BEGIN_HEADER
/* elements, giving the outline's point coordinates. */
/* */
/* tags :: A pointer to an array of `n_points' chars, giving */
- /* each outline point's type. If bit~0 is unset, the */
- /* point is `off' the curve, i.e., a Bezier control */
- /* point, while it is `on' when set. */
+ /* each outline point's type. */
+ /* */
+ /* If bit~0 is unset, the point is `off' the curve, */
+ /* i.e., a Bézier control point, while it is `on' if */
+ /* set. */
/* */
/* Bit~1 is meaningful for `off' points only. If set, */
- /* it indicates a third-order Bezier arc control point; */
+ /* it indicates a third-order Bézier arc control point; */
/* and a second-order control point if unset. */
/* */
+ /* If bit~2 is set, bits 5-7 contain the drop-out mode */
+ /* (as defined in the OpenType specification; the value */
+ /* is the same as the argument to the SCANMODE */
+ /* instruction). */
+ /* */
+ /* Bits 3 and~4 are reserved for internal purposes. */
+ /* */
/* contours :: An array of `n_contours' shorts, giving the end */
/* point of each contour within the outline. For */
/* example, the first contour is defined by the points */
@@ -336,6 +362,12 @@ FT_BEGIN_HEADER
/* and give hints to the scan-converter and hinter on */
/* how to convert/grid-fit it. See @FT_OUTLINE_FLAGS. */
/* */
+ /* <Note> */
+ /* The B/W rasterizer only checks bit~2 in the `tags' array for the */
+ /* first point of each contour. The drop-out mode as given with */
+ /* @FT_OUTLINE_IGNORE_DROPOUTS, @FT_OUTLINE_SMART_DROPOUTS, and */
+ /* @FT_OUTLINE_INCLUDE_STUBS in `flags' is then overridden. */
+ /* */
typedef struct FT_Outline_
{
short n_contours; /* number of contours in glyph */
@@ -349,6 +381,11 @@ FT_BEGIN_HEADER
} FT_Outline;
+ /* Following limits must be consistent with */
+ /* FT_Outline.{n_contours,n_points} */
+#define FT_OUTLINE_CONTOURS_MAX SHRT_MAX
+#define FT_OUTLINE_POINTS_MAX SHRT_MAX
+
/*************************************************************************/
/* */
@@ -371,7 +408,7 @@ FT_BEGIN_HEADER
/* FT_OUTLINE_EVEN_ODD_FILL :: */
/* By default, outlines are filled using the non-zero winding rule. */
/* If set to 1, the outline will be filled using the even-odd fill */
- /* rule (only works with the smooth raster). */
+ /* rule (only works with the smooth rasterizer). */
/* */
/* FT_OUTLINE_REVERSE_FILL :: */
/* By default, outside contours of an outline are oriented in */
@@ -384,15 +421,17 @@ FT_BEGIN_HEADER
/* By default, the scan converter will try to detect drop-outs in */
/* an outline and correct the glyph bitmap to ensure consistent */
/* shape continuity. If set, this flag hints the scan-line */
- /* converter to ignore such cases. */
+ /* converter to ignore such cases. See below for more information. */
/* */
/* FT_OUTLINE_SMART_DROPOUTS :: */
/* Select smart dropout control. If unset, use simple dropout */
- /* control. Ignored if @FT_OUTLINE_IGNORE_DROPOUTS is set. */
+ /* control. Ignored if @FT_OUTLINE_IGNORE_DROPOUTS is set. See */
+ /* below for more information. */
/* */
/* FT_OUTLINE_INCLUDE_STUBS :: */
/* If set, turn pixels on for `stubs', otherwise exclude them. */
- /* Ignored if @FT_OUTLINE_IGNORE_DROPOUTS is set. */
+ /* Ignored if @FT_OUTLINE_IGNORE_DROPOUTS is set. See below for */
+ /* more information. */
/* */
/* FT_OUTLINE_HIGH_PRECISION :: */
/* This flag indicates that the scan-line converter should try to */
@@ -409,6 +448,13 @@ FT_BEGIN_HEADER
/* scan-converter. */
/* */
/* <Note> */
+ /* The flags @FT_OUTLINE_IGNORE_DROPOUTS, @FT_OUTLINE_SMART_DROPOUTS, */
+ /* and @FT_OUTLINE_INCLUDE_STUBS are ignored by the smooth */
+ /* rasterizer. */
+ /* */
+ /* There exists a second mechanism to pass the drop-out mode to the */
+ /* B/W rasterizer; see the `tags' field in @FT_Outline. */
+ /* */
/* Please refer to the description of the `SCANTYPE' instruction in */
/* the OpenType specification (in file `ttinst1.doc') how simple */
/* drop-outs, smart drop-outs, and stubs are defined. */
@@ -455,15 +501,17 @@ FT_BEGIN_HEADER
#define FT_CURVE_TAG( flag ) ( flag & 3 )
-#define FT_CURVE_TAG_ON 1
-#define FT_CURVE_TAG_CONIC 0
-#define FT_CURVE_TAG_CUBIC 2
+#define FT_CURVE_TAG_ON 1
+#define FT_CURVE_TAG_CONIC 0
+#define FT_CURVE_TAG_CUBIC 2
+
+#define FT_CURVE_TAG_HAS_SCANMODE 4
-#define FT_CURVE_TAG_TOUCH_X 8 /* reserved for the TrueType hinter */
-#define FT_CURVE_TAG_TOUCH_Y 16 /* reserved for the TrueType hinter */
+#define FT_CURVE_TAG_TOUCH_X 8 /* reserved for the TrueType hinter */
+#define FT_CURVE_TAG_TOUCH_Y 16 /* reserved for the TrueType hinter */
-#define FT_CURVE_TAG_TOUCH_BOTH ( FT_CURVE_TAG_TOUCH_X | \
- FT_CURVE_TAG_TOUCH_Y )
+#define FT_CURVE_TAG_TOUCH_BOTH ( FT_CURVE_TAG_TOUCH_X | \
+ FT_CURVE_TAG_TOUCH_Y )
#define FT_Curve_Tag_On FT_CURVE_TAG_ON
#define FT_Curve_Tag_Conic FT_CURVE_TAG_CONIC
@@ -532,10 +580,10 @@ FT_BEGIN_HEADER
/* FT_Outline_ConicToFunc */
/* */
/* <Description> */
- /* A function pointer type use to describe the signature of a `conic */
- /* to' function during outline walking/decomposition. */
+ /* A function pointer type used to describe the signature of a `conic */
+ /* to' function during outline walking or decomposition. */
/* */
- /* A `conic to' is emitted to indicate a second-order Bezier arc in */
+ /* A `conic to' is emitted to indicate a second-order Bézier arc in */
/* the outline. */
/* */
/* <Input> */
@@ -565,14 +613,14 @@ FT_BEGIN_HEADER
/* */
/* <Description> */
/* A function pointer type used to describe the signature of a `cubic */
- /* to' function during outline walking/decomposition. */
+ /* to' function during outline walking or decomposition. */
/* */
- /* A `cubic to' is emitted to indicate a third-order Bezier arc. */
+ /* A `cubic to' is emitted to indicate a third-order Bézier arc. */
/* */
/* <Input> */
- /* control1 :: A pointer to the first Bezier control point. */
+ /* control1 :: A pointer to the first Bézier control point. */
/* */
- /* control2 :: A pointer to the second Bezier control point. */
+ /* control2 :: A pointer to the second Bézier control point. */
/* */
/* to :: A pointer to the target end point. */
/* */
@@ -598,17 +646,16 @@ FT_BEGIN_HEADER
/* */
/* <Description> */
/* A structure to hold various function pointers used during outline */
- /* decomposition in order to emit segments, conic, and cubic Beziers, */
- /* as well as `move to' and `close to' operations. */
+ /* decomposition in order to emit segments, conic, and cubic Béziers. */
/* */
/* <Fields> */
/* move_to :: The `move to' emitter. */
/* */
/* line_to :: The segment emitter. */
/* */
- /* conic_to :: The second-order Bezier arc emitter. */
+ /* conic_to :: The second-order Bézier arc emitter. */
/* */
- /* cubic_to :: The third-order Bezier arc emitter. */
+ /* cubic_to :: The third-order Bézier arc emitter. */
/* */
/* shift :: The shift that is applied to coordinates before they */
/* are sent to the emitter. */
@@ -626,7 +673,7 @@ FT_BEGIN_HEADER
/* y' = (x << shift) - delta */
/* } */
/* */
- /* Set the value of `shift' and `delta' to~0 to get the original */
+ /* Set the values of `shift' and `delta' to~0 to get the original */
/* point coordinates. */
/* */
typedef struct FT_Outline_Funcs_
@@ -705,7 +752,7 @@ FT_BEGIN_HEADER
/* */
/* FT_GLYPH_FORMAT_OUTLINE :: */
/* The glyph image is a vectorial outline made of line segments */
- /* and Bezier arcs; it can be described as an @FT_Outline; you */
+ /* and Bézier arcs; it can be described as an @FT_Outline; you */
/* generally want to access the `outline' field of the */
/* @FT_GlyphSlotRec structure to read it. */
/* */
@@ -1011,7 +1058,7 @@ FT_BEGIN_HEADER
/* */
/* gray_spans :: The gray span drawing callback. */
/* */
- /* black_spans :: The black span drawing callback. */
+ /* black_spans :: The black span drawing callback. UNIMPLEMENTED! */
/* */
/* bit_test :: The bit test callback. UNIMPLEMENTED! */
/* */
@@ -1048,7 +1095,7 @@ FT_BEGIN_HEADER
const void* source;
int flags;
FT_SpanFunc gray_spans;
- FT_SpanFunc black_spans;
+ FT_SpanFunc black_spans; /* doesn't work! */
FT_Raster_BitTest_Func bit_test; /* doesn't work! */
FT_Raster_BitSet_Func bit_set; /* doesn't work! */
void* user;
diff --git a/src/3rdparty/freetype/include/freetype/ftincrem.h b/src/3rdparty/freetype/include/freetype/ftincrem.h
index 96abedea7b..aaf689ff16 100644
--- a/src/3rdparty/freetype/include/freetype/ftincrem.h
+++ b/src/3rdparty/freetype/include/freetype/ftincrem.h
@@ -4,7 +4,7 @@
/* */
/* FreeType incremental loading (specification). */
/* */
-/* Copyright 2002, 2003, 2006, 2007, 2008 by */
+/* Copyright 2002, 2003, 2006, 2007, 2008, 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -101,7 +101,10 @@ FT_BEGIN_HEADER
* Top bearing, in font units.
*
* advance ::
- * Glyph advance, in font units.
+ * Horizontal component of glyph advance, in font units.
+ *
+ * advance_v ::
+ * Vertical component of glyph advance, in font units.
*
* @note:
* These correspond to horizontal or vertical metrics depending on the
@@ -114,6 +117,7 @@ FT_BEGIN_HEADER
FT_Long bearing_x;
FT_Long bearing_y;
FT_Long advance;
+ FT_Long advance_v; /* since 2.3.12 */
} FT_Incremental_MetricsRec;
diff --git a/src/3rdparty/freetype/include/freetype/ftmodapi.h b/src/3rdparty/freetype/include/freetype/ftmodapi.h
index b051d34a88..3c9b876dfe 100644
--- a/src/3rdparty/freetype/include/freetype/ftmodapi.h
+++ b/src/3rdparty/freetype/include/freetype/ftmodapi.h
@@ -4,7 +4,7 @@
/* */
/* FreeType modules public interface (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2006, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2006, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -259,6 +259,10 @@ FT_BEGIN_HEADER
/* from a given memory object. It is thus possible to use libraries */
/* with distinct memory allocators within the same program. */
/* */
+ /* Normally, you would call this function (followed by a call to */
+ /* @FT_Add_Default_Modules or a series of calls to @FT_Add_Module) */
+ /* instead of @FT_Init_FreeType to initialize the FreeType library. */
+ /* */
/* <Input> */
/* memory :: A handle to the original memory object. */
/* */
diff --git a/src/3rdparty/freetype/include/freetype/ftoutln.h b/src/3rdparty/freetype/include/freetype/ftoutln.h
index ea60d43e8e..2829a05ca3 100644
--- a/src/3rdparty/freetype/include/freetype/ftoutln.h
+++ b/src/3rdparty/freetype/include/freetype/ftoutln.h
@@ -5,7 +5,7 @@
/* Support for the FT_Outline type used to store glyph shapes of */
/* most scalable font formats (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2005, 2006, 2007, 2008, 2009 by */
+/* Copyright 1996-2001, 2002, 2003, 2005, 2006, 2007, 2008, 2009, 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -85,9 +85,8 @@ FT_BEGIN_HEADER
/* */
/* <Description> */
/* Walk over an outline's structure to decompose it into individual */
- /* segments and Bezier arcs. This function is also able to emit */
- /* `move to' and `close to' operations to indicate the start and end */
- /* of new contours in the outline. */
+ /* segments and Bézier arcs. This function also emits `move to' */
+ /* operations to indicate the start of new contours in the outline. */
/* */
/* <Input> */
/* outline :: A pointer to the source target. */
@@ -212,10 +211,10 @@ FT_BEGIN_HEADER
/* */
/* <Description> */
/* Return an outline's `control box'. The control box encloses all */
- /* the outline's points, including Bezier control points. Though it */
+ /* the outline's points, including Bézier control points. Though it */
/* coincides with the exact bounding box for most glyphs, it can be */
/* slightly larger in some situations (like when rotating an outline */
- /* which contains Bezier outside arcs). */
+ /* which contains Bézier outside arcs). */
/* */
/* Computing the control box is very fast, while getting the bounding */
/* box can take much more time as it needs to walk over all segments */
diff --git a/src/3rdparty/freetype/include/freetype/ftsnames.h b/src/3rdparty/freetype/include/freetype/ftsnames.h
index 477e1e3ce8..485e4e162e 100644
--- a/src/3rdparty/freetype/include/freetype/ftsnames.h
+++ b/src/3rdparty/freetype/include/freetype/ftsnames.h
@@ -7,7 +7,7 @@
/* */
/* This is _not_ used to retrieve glyph names! */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2006 by */
+/* Copyright 1996-2001, 2002, 2003, 2006, 2009, 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -147,7 +147,8 @@ FT_BEGIN_HEADER
/* */
/* <Note> */
/* The `string' array returned in the `aname' structure is not */
- /* null-terminated. */
+ /* null-terminated. The application should deallocate it if it is no */
+ /* longer in use. */
/* */
/* Use @FT_Get_Sfnt_Name_Count to get the total number of available */
/* `name' table entries, then do a loop until you get the right */
@@ -159,6 +160,35 @@ FT_BEGIN_HEADER
FT_SfntName *aname );
+ /***************************************************************************
+ *
+ * @constant:
+ * FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY
+ *
+ * @description:
+ * A constant used as the tag of @FT_Parameter structures to make
+ * FT_Open_Face() ignore preferred family subfamily names in `name'
+ * table since OpenType version 1.4. For backwards compatibility with
+ * legacy systems which has 4-face-per-family restriction.
+ *
+ */
+#define FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY FT_MAKE_TAG( 'i', 'g', 'p', 'f' )
+
+
+ /***************************************************************************
+ *
+ * @constant:
+ * FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY
+ *
+ * @description:
+ * A constant used as the tag of @FT_Parameter structures to make
+ * FT_Open_Face() ignore preferred subfamily names in `name' table since
+ * OpenType version 1.4. For backwards compatibility with legacy
+ * systems which has 4-face-per-family restriction.
+ *
+ */
+#define FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY FT_MAKE_TAG( 'i', 'g', 'p', 's' )
+
/* */
diff --git a/src/3rdparty/freetype/include/freetype/ftstroke.h b/src/3rdparty/freetype/include/freetype/ftstroke.h
index 0c10122a88..3afb87df88 100644
--- a/src/3rdparty/freetype/include/freetype/ftstroke.h
+++ b/src/3rdparty/freetype/include/freetype/ftstroke.h
@@ -407,7 +407,7 @@ FT_BEGIN_HEADER
* FT_Stroker_ConicTo
*
* @description:
- * `Draw' a single quadratic Bezier in the stroker's current sub-path,
+ * `Draw' a single quadratic Bézier in the stroker's current sub-path,
* from the last position.
*
* @input:
@@ -415,7 +415,7 @@ FT_BEGIN_HEADER
* The target stroker handle.
*
* control ::
- * A pointer to a Bezier control point.
+ * A pointer to a Bézier control point.
*
* to ::
* A pointer to the destination point.
@@ -439,7 +439,7 @@ FT_BEGIN_HEADER
* FT_Stroker_CubicTo
*
* @description:
- * `Draw' a single cubic Bezier in the stroker's current sub-path,
+ * `Draw' a single cubic Bézier in the stroker's current sub-path,
* from the last position.
*
* @input:
@@ -447,10 +447,10 @@ FT_BEGIN_HEADER
* The target stroker handle.
*
* control1 ::
- * A pointer to the first Bezier control point.
+ * A pointer to the first Bézier control point.
*
* control2 ::
- * A pointer to second Bezier control point.
+ * A pointer to second Bézier control point.
*
* to ::
* A pointer to the destination point.
@@ -598,7 +598,7 @@ FT_BEGIN_HEADER
*
* @description:
* Call this function after @FT_Stroker_GetBorderCounts to
- * export the all borders to your own @FT_Outline structure.
+ * export all borders to your own @FT_Outline structure.
*
* Note that this function appends the border points and
* contours to your outline, but does not try to resize its
diff --git a/src/3rdparty/freetype/include/freetype/fttypes.h b/src/3rdparty/freetype/include/freetype/fttypes.h
index 54f08e3e5a..a57ffa69bd 100644
--- a/src/3rdparty/freetype/include/freetype/fttypes.h
+++ b/src/3rdparty/freetype/include/freetype/fttypes.h
@@ -167,7 +167,7 @@ FT_BEGIN_HEADER
/* FT_Tag */
/* */
/* <Description> */
- /* A typedef for 32-bit tags (as used in the SFNT format). */
+ /* A typedef for 32-bit tags (as used in the SFNT format). */
/* */
typedef FT_UInt32 FT_Tag;
@@ -474,6 +474,7 @@ FT_BEGIN_HEADER
/* this macro. */
/* */
#define FT_MAKE_TAG( _x1, _x2, _x3, _x4 ) \
+ (FT_Tag) \
( ( (FT_ULong)_x1 << 24 ) | \
( (FT_ULong)_x2 << 16 ) | \
( (FT_ULong)_x3 << 8 ) | \
diff --git a/src/3rdparty/freetype/include/freetype/ftwinfnt.h b/src/3rdparty/freetype/include/freetype/ftwinfnt.h
index 9a4cf58939..ea33353536 100644
--- a/src/3rdparty/freetype/include/freetype/ftwinfnt.h
+++ b/src/3rdparty/freetype/include/freetype/ftwinfnt.h
@@ -77,7 +77,7 @@ FT_BEGIN_HEADER
* Mac Roman encoding.
*
* FT_WinFNT_ID_OEM ::
- * From Michael Poettgen <michael@poettgen.de>:
+ * From Michael Pöttgen <michael@poettgen.de>:
*
* The `Windows Font Mapping' article says that FT_WinFNT_ID_OEM
* is used for the charset of vector fonts, like `modern.fon',
diff --git a/src/3rdparty/freetype/include/freetype/ftxf86.h b/src/3rdparty/freetype/include/freetype/ftxf86.h
index ae9ff076fa..8c68afdcc5 100644
--- a/src/3rdparty/freetype/include/freetype/ftxf86.h
+++ b/src/3rdparty/freetype/include/freetype/ftxf86.h
@@ -49,6 +49,9 @@ FT_BEGIN_HEADER
/* however, there are special cases (like in PDF devices) where it is */
/* important to differentiate, in spite of FreeType's uniform API. */
/* */
+ /* This function is in the X11/xf86 namespace for historical reasons */
+ /* and in no way depends on that windowing system. */
+ /* */
/*************************************************************************/
diff --git a/src/3rdparty/freetype/include/freetype/internal/autohint.h b/src/3rdparty/freetype/include/freetype/internal/autohint.h
index ee004022f9..7e3a08a051 100644
--- a/src/3rdparty/freetype/include/freetype/internal/autohint.h
+++ b/src/3rdparty/freetype/include/freetype/internal/autohint.h
@@ -196,6 +196,32 @@ FT_BEGIN_HEADER
} FT_AutoHinter_ServiceRec, *FT_AutoHinter_Service;
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_AUTOHINTER_SERVICE(class_, reset_face_, get_global_hints_, \
+ done_global_hints_, load_glyph_) \
+ FT_CALLBACK_TABLE_DEF \
+ const FT_AutoHinter_ServiceRec class_ = \
+ { \
+ reset_face_, get_global_hints_, done_global_hints_, load_glyph_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_AUTOHINTER_SERVICE(class_, reset_face_, get_global_hints_, \
+ done_global_hints_, load_glyph_) \
+ void \
+ FT_Init_Class_##class_( FT_Library library, \
+ FT_AutoHinter_ServiceRec* clazz) \
+ { \
+ FT_UNUSED(library); \
+ clazz->reset_face = reset_face_; \
+ clazz->get_global_hints = get_global_hints_; \
+ clazz->done_global_hints = done_global_hints_; \
+ clazz->load_glyph = load_glyph_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
FT_END_HEADER
diff --git a/src/3rdparty/freetype/include/freetype/internal/ftcalc.h b/src/3rdparty/freetype/include/freetype/internal/ftcalc.h
index 58def34cab..f8b4324777 100644
--- a/src/3rdparty/freetype/include/freetype/internal/ftcalc.h
+++ b/src/3rdparty/freetype/include/freetype/internal/ftcalc.h
@@ -4,7 +4,7 @@
/* */
/* Arithmetic computations (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -165,6 +165,7 @@ FT_BEGIN_HEADER
#define INT_TO_FIXED( x ) ( (FT_Long)(x) << 16 )
#define F2DOT14_TO_FIXED( x ) ( (FT_Long)(x) << 2 )
#define FLOAT_TO_FIXED( x ) ( (FT_Long)( x * 65536.0 ) )
+#define FIXED_TO_INT( x ) ( FT_RoundFix( x ) >> 16 )
#define ROUND_F26DOT6( x ) ( x >= 0 ? ( ( (x) + 32 ) & -64 ) \
: ( -( ( 32 - (x) ) & -64 ) ) )
diff --git a/src/3rdparty/freetype/include/freetype/internal/ftdriver.h b/src/3rdparty/freetype/include/freetype/internal/ftdriver.h
index 854abad085..1d06997bd1 100644
--- a/src/3rdparty/freetype/include/freetype/internal/ftdriver.h
+++ b/src/3rdparty/freetype/include/freetype/internal/ftdriver.h
@@ -240,6 +240,179 @@ FT_BEGIN_HEADER
#endif /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ /*************************************************************************/
+ /* */
+ /* <Macro> */
+ /* FT_DECLARE_DRIVER */
+ /* */
+ /* <Description> */
+ /* Used to create a forward declaration of a */
+ /* FT_Driver_ClassRec stract instance. */
+ /* */
+ /* <Macro> */
+ /* FT_DEFINE_DRIVER */
+ /* */
+ /* <Description> */
+ /* Used to initialize an instance of FT_Driver_ClassRec struct. */
+ /* */
+ /* When FT_CONFIG_OPTION_PIC is defined a Create funtion will need */
+ /* to called with a pointer where the allocated stracture is returned.*/
+ /* And when it is no longer needed a Destroy function needs */
+ /* to be called to release that allocation. */
+ /* fcinit.c (ft_create_default_module_classes) already contains */
+ /* a mechanism to call these functions for the default modules */
+ /* described in ftmodule.h */
+ /* */
+ /* Notice that the created Create and Destroy functions call */
+ /* pic_init and pic_free function to allow you to manually allocate */
+ /* and initialize any additional global data, like module specific */
+ /* interface, and put them in the global pic container defined in */
+ /* ftpic.h. if you don't need them just implement the functions as */
+ /* empty to resolve the link error. */
+ /* */
+ /* When FT_CONFIG_OPTION_PIC is not defined the struct will be */
+ /* allocated in the global scope (or the scope where the macro */
+ /* is used). */
+ /* */
+#ifndef FT_CONFIG_OPTION_PIC
+
+#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
+#define FT_DEFINE_DRIVERS_OLD_INTERNALS(a_,b_) \
+ a_, b_,
+#else
+ #define FT_DEFINE_DRIVERS_OLD_INTERNALS(a_,b_)
+#endif
+
+#define FT_DECLARE_DRIVER(class_) \
+ FT_CALLBACK_TABLE \
+ const FT_Driver_ClassRec class_;
+
+#define FT_DEFINE_DRIVER(class_, \
+ flags_, size_, name_, version_, requires_, \
+ interface_, init_, done_, get_interface_, \
+ face_object_size_, size_object_size_, \
+ slot_object_size_, init_face_, done_face_, \
+ init_size_, done_size_, init_slot_, done_slot_, \
+ old_set_char_sizes_, old_set_pixel_sizes_, \
+ load_glyph_, get_kerning_, attach_file_, \
+ get_advances_, request_size_, select_size_ ) \
+ FT_CALLBACK_TABLE_DEF \
+ const FT_Driver_ClassRec class_ = \
+ { \
+ FT_DEFINE_ROOT_MODULE(flags_,size_,name_,version_,requires_,interface_, \
+ init_,done_,get_interface_) \
+ \
+ face_object_size_, \
+ size_object_size_, \
+ slot_object_size_, \
+ \
+ init_face_, \
+ done_face_, \
+ \
+ init_size_, \
+ done_size_, \
+ \
+ init_slot_, \
+ done_slot_, \
+ \
+ FT_DEFINE_DRIVERS_OLD_INTERNALS(old_set_char_sizes_, old_set_pixel_sizes_) \
+ \
+ load_glyph_, \
+ \
+ get_kerning_, \
+ attach_file_, \
+ get_advances_, \
+ \
+ request_size_, \
+ select_size_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
+#define FT_DEFINE_DRIVERS_OLD_INTERNALS(a_,b_) \
+ clazz->set_char_sizes = a_; \
+ clazz->set_pixel_sizes = b_;
+#else
+ #define FT_DEFINE_DRIVERS_OLD_INTERNALS(a_,b_)
+#endif
+
+#define FT_DECLARE_DRIVER(class_) FT_DECLARE_MODULE(class_)
+
+#define FT_DEFINE_DRIVER(class_, \
+ flags_, size_, name_, version_, requires_, \
+ interface_, init_, done_, get_interface_, \
+ face_object_size_, size_object_size_, \
+ slot_object_size_, init_face_, done_face_, \
+ init_size_, done_size_, init_slot_, done_slot_, \
+ old_set_char_sizes_, old_set_pixel_sizes_, \
+ load_glyph_, get_kerning_, attach_file_, \
+ get_advances_, request_size_, select_size_ ) \
+ void class_##_pic_free( FT_Library library ); \
+ FT_Error class_##_pic_init( FT_Library library ); \
+ \
+ void \
+ FT_Destroy_Class_##class_( FT_Library library, \
+ FT_Module_Class* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ FT_Driver_Class dclazz = (FT_Driver_Class)clazz; \
+ class_##_pic_free( library ); \
+ if ( dclazz ) \
+ FT_FREE( dclazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_##class_( FT_Library library, \
+ FT_Module_Class** output_class ) \
+ { \
+ FT_Driver_Class clazz; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ if ( FT_ALLOC( clazz, sizeof(*clazz) ) ) \
+ return error; \
+ \
+ error = class_##_pic_init( library ); \
+ if(error) \
+ { \
+ FT_FREE( clazz ); \
+ return error; \
+ } \
+ \
+ FT_DEFINE_ROOT_MODULE(flags_,size_,name_,version_,requires_,interface_, \
+ init_,done_,get_interface_) \
+ \
+ clazz->face_object_size = face_object_size_; \
+ clazz->size_object_size = size_object_size_; \
+ clazz->slot_object_size = slot_object_size_; \
+ \
+ clazz->init_face = init_face_; \
+ clazz->done_face = done_face_; \
+ \
+ clazz->init_size = init_size_; \
+ clazz->done_size = done_size_; \
+ \
+ clazz->init_slot = init_slot_; \
+ clazz->done_slot = done_slot_; \
+ \
+ FT_DEFINE_DRIVERS_OLD_INTERNALS(old_set_char_sizes_, old_set_pixel_sizes_) \
+ \
+ clazz->load_glyph = load_glyph_; \
+ \
+ clazz->get_kerning = get_kerning_; \
+ clazz->attach_file = attach_file_; \
+ clazz->get_advances = get_advances_; \
+ \
+ clazz->request_size = request_size_; \
+ clazz->select_size = select_size_; \
+ \
+ *output_class = (FT_Module_Class*)clazz; \
+ return FT_Err_Ok; \
+ }
+
+
+#endif /* FT_CONFIG_OPTION_PIC */
FT_END_HEADER
diff --git a/src/3rdparty/freetype/include/freetype/internal/ftgloadr.h b/src/3rdparty/freetype/include/freetype/internal/ftgloadr.h
index 548481ac80..ce4dc6c9cc 100644
--- a/src/3rdparty/freetype/include/freetype/internal/ftgloadr.h
+++ b/src/3rdparty/freetype/include/freetype/internal/ftgloadr.h
@@ -121,15 +121,15 @@ FT_BEGIN_HEADER
FT_UInt n_contours );
-#define FT_GLYPHLOADER_CHECK_P( _loader, _count ) \
- ( (_count) == 0 || (int)((_loader)->base.outline.n_points + \
- (_loader)->current.outline.n_points + \
- (_count)) <= (int)(_loader)->max_points )
-
-#define FT_GLYPHLOADER_CHECK_C( _loader, _count ) \
- ( (_count) == 0 || (int)((_loader)->base.outline.n_contours + \
- (_loader)->current.outline.n_contours + \
- (_count)) <= (int)(_loader)->max_contours )
+#define FT_GLYPHLOADER_CHECK_P( _loader, _count ) \
+ ( (_count) == 0 || ((_loader)->base.outline.n_points + \
+ (_loader)->current.outline.n_points + \
+ (unsigned long)(_count)) <= (_loader)->max_points )
+
+#define FT_GLYPHLOADER_CHECK_C( _loader, _count ) \
+ ( (_count) == 0 || ((_loader)->base.outline.n_contours + \
+ (_loader)->current.outline.n_contours + \
+ (unsigned long)(_count)) <= (_loader)->max_contours )
#define FT_GLYPHLOADER_CHECK_POINTS( _loader, _points,_contours ) \
( ( FT_GLYPHLOADER_CHECK_P( _loader, _points ) && \
diff --git a/src/3rdparty/freetype/include/freetype/internal/ftobjs.h b/src/3rdparty/freetype/include/freetype/internal/ftobjs.h
index 1f22343a59..574cf58296 100644
--- a/src/3rdparty/freetype/include/freetype/internal/ftobjs.h
+++ b/src/3rdparty/freetype/include/freetype/internal/ftobjs.h
@@ -35,6 +35,7 @@
#include FT_INTERNAL_DRIVER_H
#include FT_INTERNAL_AUTOHINT_H
#include FT_INTERNAL_SERVICE_H
+#include FT_INTERNAL_PIC_H
#ifdef FT_CONFIG_OPTION_INCREMENTAL
#include FT_INCREMENTAL_H
@@ -205,6 +206,45 @@ FT_BEGIN_HEADER
} FT_CMap_ClassRec;
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DECLARE_CMAP_CLASS(class_) \
+ FT_CALLBACK_TABLE const FT_CMap_ClassRec class_;
+
+#define FT_DEFINE_CMAP_CLASS(class_, size_, init_, done_, char_index_, \
+ char_next_, char_var_index_, char_var_default_, variant_list_, \
+ charvariant_list_, variantchar_list_) \
+ FT_CALLBACK_TABLE_DEF \
+ const FT_CMap_ClassRec class_ = \
+ { \
+ size_, init_, done_, char_index_, char_next_, char_var_index_, \
+ char_var_default_, variant_list_, charvariant_list_, variantchar_list_ \
+ };
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DECLARE_CMAP_CLASS(class_) \
+ void FT_Init_Class_##class_( FT_Library library, FT_CMap_ClassRec* clazz);
+
+#define FT_DEFINE_CMAP_CLASS(class_, size_, init_, done_, char_index_, \
+ char_next_, char_var_index_, char_var_default_, variant_list_, \
+ charvariant_list_, variantchar_list_) \
+ void \
+ FT_Init_Class_##class_( FT_Library library, \
+ FT_CMap_ClassRec* clazz) \
+ { \
+ FT_UNUSED(library); \
+ clazz->size = size_; \
+ clazz->init = init_; \
+ clazz->done = done_; \
+ clazz->char_index = char_index_; \
+ clazz->char_next = char_next_; \
+ clazz->char_var_index = char_var_index_; \
+ clazz->char_var_default = char_var_default_; \
+ clazz->variant_list = variant_list_; \
+ clazz->charvariant_list = charvariant_list_; \
+ clazz->variantchar_list = variantchar_list_; \
+ }
+#endif /* FT_CONFIG_OPTION_PIC */
/* create a new charmap and add it to charmap->face */
FT_BASE( FT_Error )
@@ -765,6 +805,10 @@ FT_BEGIN_HEADER
/* */
/* debug_hooks :: XXX */
/* */
+ /* pic_container :: Contains global structs and tables, instead */
+ /* of defining them globallly. */
+ /* */
+
typedef struct FT_LibraryRec_
{
FT_Memory memory; /* library's memory manager */
@@ -795,6 +839,10 @@ FT_BEGIN_HEADER
FT_Bitmap_LcdFilterFunc lcd_filter_func; /* filtering callback */
#endif
+#ifdef FT_CONFIG_OPTION_PIC
+ FT_PIC_Container pic_container;
+#endif
+
} FT_LibraryRec;
@@ -866,6 +914,484 @@ FT_BEGIN_HEADER
FT_EXPORT_VAR( FT_Raster_Funcs ) ft_default_raster;
#endif
+ /*************************************************************************/
+ /*************************************************************************/
+ /*************************************************************************/
+ /**** ****/
+ /**** ****/
+ /**** PIC-Support Macros for ftimage.h ****/
+ /**** ****/
+ /**** ****/
+ /*************************************************************************/
+ /*************************************************************************/
+ /*************************************************************************/
+
+
+ /*************************************************************************/
+ /* */
+ /* <Macro> */
+ /* FT_DEFINE_OUTLINE_FUNCS */
+ /* */
+ /* <Description> */
+ /* Used to initialize an instance of FT_Outline_Funcs struct. */
+ /* When FT_CONFIG_OPTION_PIC is defined an init funtion will need to */
+ /* called with a pre-allocated stracture to be filled. */
+ /* When FT_CONFIG_OPTION_PIC is not defined the struct will be */
+ /* allocated in the global scope (or the scope where the macro */
+ /* is used). */
+ /* */
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_OUTLINE_FUNCS(class_, move_to_, line_to_, conic_to_, \
+ cubic_to_, shift_, delta_) \
+ static const FT_Outline_Funcs class_ = \
+ { \
+ move_to_, line_to_, conic_to_, cubic_to_, shift_, delta_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_OUTLINE_FUNCS(class_, move_to_, line_to_, conic_to_, \
+ cubic_to_, shift_, delta_) \
+ static FT_Error \
+ Init_Class_##class_( FT_Outline_Funcs* clazz ) \
+ { \
+ clazz->move_to = move_to_; \
+ clazz->line_to = line_to_; \
+ clazz->conic_to = conic_to_; \
+ clazz->cubic_to = cubic_to_; \
+ clazz->shift = shift_; \
+ clazz->delta = delta_; \
+ return FT_Err_Ok; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /*************************************************************************/
+ /* */
+ /* <Macro> */
+ /* FT_DEFINE_RASTER_FUNCS */
+ /* */
+ /* <Description> */
+ /* Used to initialize an instance of FT_Raster_Funcs struct. */
+ /* When FT_CONFIG_OPTION_PIC is defined an init funtion will need to */
+ /* called with a pre-allocated stracture to be filled. */
+ /* When FT_CONFIG_OPTION_PIC is not defined the struct will be */
+ /* allocated in the global scope (or the scope where the macro */
+ /* is used). */
+ /* */
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_RASTER_FUNCS(class_, glyph_format_, raster_new_, \
+ raster_reset_, raster_set_mode_, \
+ raster_render_, raster_done_) \
+ const FT_Raster_Funcs class_ = \
+ { \
+ glyph_format_, raster_new_, raster_reset_, \
+ raster_set_mode_, raster_render_, raster_done_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_RASTER_FUNCS(class_, glyph_format_, raster_new_, \
+ raster_reset_, raster_set_mode_, raster_render_, raster_done_) \
+ void \
+ FT_Init_Class_##class_( FT_Raster_Funcs* clazz ) \
+ { \
+ clazz->glyph_format = glyph_format_; \
+ clazz->raster_new = raster_new_; \
+ clazz->raster_reset = raster_reset_; \
+ clazz->raster_set_mode = raster_set_mode_; \
+ clazz->raster_render = raster_render_; \
+ clazz->raster_done = raster_done_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /*************************************************************************/
+ /*************************************************************************/
+ /*************************************************************************/
+ /**** ****/
+ /**** ****/
+ /**** PIC-Support Macros for ftrender.h ****/
+ /**** ****/
+ /**** ****/
+ /*************************************************************************/
+ /*************************************************************************/
+ /*************************************************************************/
+
+
+
+ /*************************************************************************/
+ /* */
+ /* <Macro> */
+ /* FT_DEFINE_GLYPH */
+ /* */
+ /* <Description> */
+ /* Used to initialize an instance of FT_Glyph_Class struct. */
+ /* When FT_CONFIG_OPTION_PIC is defined an init funtion will need to */
+ /* called with a pre-allocated stracture to be filled. */
+ /* When FT_CONFIG_OPTION_PIC is not defined the struct will be */
+ /* allocated in the global scope (or the scope where the macro */
+ /* is used). */
+ /* */
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_GLYPH(class_, size_, format_, init_, done_, copy_, \
+ transform_, bbox_, prepare_) \
+ FT_CALLBACK_TABLE_DEF \
+ const FT_Glyph_Class class_ = \
+ { \
+ size_, format_, init_, done_, copy_, transform_, bbox_, prepare_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_GLYPH(class_, size_, format_, init_, done_, copy_, \
+ transform_, bbox_, prepare_) \
+ void \
+ FT_Init_Class_##class_( FT_Glyph_Class* clazz ) \
+ { \
+ clazz->glyph_size = size_; \
+ clazz->glyph_format = format_; \
+ clazz->glyph_init = init_; \
+ clazz->glyph_done = done_; \
+ clazz->glyph_copy = copy_; \
+ clazz->glyph_transform = transform_; \
+ clazz->glyph_bbox = bbox_; \
+ clazz->glyph_prepare = prepare_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /*************************************************************************/
+ /* */
+ /* <Macro> */
+ /* FT_DECLARE_RENDERER */
+ /* */
+ /* <Description> */
+ /* Used to create a forward declaration of a */
+ /* FT_Renderer_Class stract instance. */
+ /* */
+ /* <Macro> */
+ /* FT_DEFINE_RENDERER */
+ /* */
+ /* <Description> */
+ /* Used to initialize an instance of FT_Renderer_Class struct. */
+ /* */
+ /* When FT_CONFIG_OPTION_PIC is defined a Create funtion will need */
+ /* to called with a pointer where the allocated stracture is returned.*/
+ /* And when it is no longer needed a Destroy function needs */
+ /* to be called to release that allocation. */
+ /* fcinit.c (ft_create_default_module_classes) already contains */
+ /* a mechanism to call these functions for the default modules */
+ /* described in ftmodule.h */
+ /* */
+ /* Notice that the created Create and Destroy functions call */
+ /* pic_init and pic_free function to allow you to manually allocate */
+ /* and initialize any additional global data, like module specific */
+ /* interface, and put them in the global pic container defined in */
+ /* ftpic.h. if you don't need them just implement the functions as */
+ /* empty to resolve the link error. */
+ /* */
+ /* When FT_CONFIG_OPTION_PIC is not defined the struct will be */
+ /* allocated in the global scope (or the scope where the macro */
+ /* is used). */
+ /* */
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DECLARE_RENDERER(class_) \
+ FT_EXPORT_VAR( const FT_Renderer_Class ) class_;
+
+#define FT_DEFINE_RENDERER(class_, \
+ flags_, size_, name_, version_, requires_, \
+ interface_, init_, done_, get_interface_, \
+ glyph_format_, render_glyph_, transform_glyph_, \
+ get_glyph_cbox_, set_mode_, raster_class_ ) \
+ FT_CALLBACK_TABLE_DEF \
+ const FT_Renderer_Class class_ = \
+ { \
+ FT_DEFINE_ROOT_MODULE(flags_,size_,name_,version_,requires_, \
+ interface_,init_,done_,get_interface_) \
+ glyph_format_, \
+ \
+ render_glyph_, \
+ transform_glyph_, \
+ get_glyph_cbox_, \
+ set_mode_, \
+ \
+ raster_class_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DECLARE_RENDERER(class_) FT_DECLARE_MODULE(class_)
+
+#define FT_DEFINE_RENDERER(class_, \
+ flags_, size_, name_, version_, requires_, \
+ interface_, init_, done_, get_interface_, \
+ glyph_format_, render_glyph_, transform_glyph_, \
+ get_glyph_cbox_, set_mode_, raster_class_ ) \
+ void class_##_pic_free( FT_Library library ); \
+ FT_Error class_##_pic_init( FT_Library library ); \
+ \
+ void \
+ FT_Destroy_Class_##class_( FT_Library library, \
+ FT_Module_Class* clazz ) \
+ { \
+ FT_Renderer_Class* rclazz = (FT_Renderer_Class*)clazz; \
+ FT_Memory memory = library->memory; \
+ class_##_pic_free( library ); \
+ if ( rclazz ) \
+ FT_FREE( rclazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_##class_( FT_Library library, \
+ FT_Module_Class** output_class ) \
+ { \
+ FT_Renderer_Class* clazz; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ if ( FT_ALLOC( clazz, sizeof(*clazz) ) ) \
+ return error; \
+ \
+ error = class_##_pic_init( library ); \
+ if(error) \
+ { \
+ FT_FREE( clazz ); \
+ return error; \
+ } \
+ \
+ FT_DEFINE_ROOT_MODULE(flags_,size_,name_,version_,requires_, \
+ interface_,init_,done_,get_interface_) \
+ \
+ clazz->glyph_format = glyph_format_; \
+ \
+ clazz->render_glyph = render_glyph_; \
+ clazz->transform_glyph = transform_glyph_; \
+ clazz->get_glyph_cbox = get_glyph_cbox_; \
+ clazz->set_mode = set_mode_; \
+ \
+ clazz->raster_class = raster_class_; \
+ \
+ *output_class = (FT_Module_Class*)clazz; \
+ return FT_Err_Ok; \
+ }
+
+
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /*************************************************************************/
+ /*************************************************************************/
+ /*************************************************************************/
+ /**** ****/
+ /**** ****/
+ /**** PIC-Support Macros for ftmodapi.h ****/
+ /**** ****/
+ /**** ****/
+ /*************************************************************************/
+ /*************************************************************************/
+ /*************************************************************************/
+
+
+#ifdef FT_CONFIG_OPTION_PIC
+
+ /*************************************************************************/
+ /* */
+ /* <FuncType> */
+ /* FT_Module_Creator */
+ /* */
+ /* <Description> */
+ /* A function used to create (allocate) a new module class object. */
+ /* The object's members are initialized, but the module itself is */
+ /* not. */
+ /* */
+ /* <Input> */
+ /* memory :: A handle to the memory manager. */
+ /* output_class :: Initialized with the newly allocated class. */
+ /* */
+ typedef FT_Error
+ (*FT_Module_Creator)( FT_Memory memory,
+ FT_Module_Class** output_class );
+
+ /*************************************************************************/
+ /* */
+ /* <FuncType> */
+ /* FT_Module_Destroyer */
+ /* */
+ /* <Description> */
+ /* A function used to destroy (deallocate) a module class object. */
+ /* */
+ /* <Input> */
+ /* memory :: A handle to the memory manager. */
+ /* clazz :: Module class to destroy. */
+ /* */
+ typedef void
+ (*FT_Module_Destroyer)( FT_Memory memory,
+ FT_Module_Class* clazz );
+
+#endif
+
+ /*************************************************************************/
+ /* */
+ /* <Macro> */
+ /* FT_DECLARE_MODULE */
+ /* */
+ /* <Description> */
+ /* Used to create a forward declaration of a */
+ /* FT_Module_Class stract instance. */
+ /* */
+ /* <Macro> */
+ /* FT_DEFINE_MODULE */
+ /* */
+ /* <Description> */
+ /* Used to initialize an instance of FT_Module_Class struct. */
+ /* */
+ /* When FT_CONFIG_OPTION_PIC is defined a Create funtion will need */
+ /* to called with a pointer where the allocated stracture is returned.*/
+ /* And when it is no longer needed a Destroy function needs */
+ /* to be called to release that allocation. */
+ /* fcinit.c (ft_create_default_module_classes) already contains */
+ /* a mechanism to call these functions for the default modules */
+ /* described in ftmodule.h */
+ /* */
+ /* Notice that the created Create and Destroy functions call */
+ /* pic_init and pic_free function to allow you to manually allocate */
+ /* and initialize any additional global data, like module specific */
+ /* interface, and put them in the global pic container defined in */
+ /* ftpic.h. if you don't need them just implement the functions as */
+ /* empty to resolve the link error. */
+ /* */
+ /* When FT_CONFIG_OPTION_PIC is not defined the struct will be */
+ /* allocated in the global scope (or the scope where the macro */
+ /* is used). */
+ /* */
+ /* <Macro> */
+ /* FT_DEFINE_ROOT_MODULE */
+ /* */
+ /* <Description> */
+ /* Used to initialize an instance of FT_Module_Class struct inside */
+ /* another stract that contains it or in a function that initializes */
+ /* that containing stract */
+ /* */
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DECLARE_MODULE(class_) \
+ FT_CALLBACK_TABLE \
+ const FT_Module_Class class_; \
+
+#define FT_DEFINE_ROOT_MODULE(flags_, size_, name_, version_, requires_, \
+ interface_, init_, done_, get_interface_) \
+ { \
+ flags_, \
+ size_, \
+ \
+ name_, \
+ version_, \
+ requires_, \
+ \
+ interface_, \
+ \
+ init_, \
+ done_, \
+ get_interface_, \
+ },
+
+#define FT_DEFINE_MODULE(class_, flags_, size_, name_, version_, requires_, \
+ interface_, init_, done_, get_interface_) \
+ FT_CALLBACK_TABLE_DEF \
+ const FT_Module_Class class_ = \
+ { \
+ flags_, \
+ size_, \
+ \
+ name_, \
+ version_, \
+ requires_, \
+ \
+ interface_, \
+ \
+ init_, \
+ done_, \
+ get_interface_, \
+ };
+
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DECLARE_MODULE(class_) \
+ FT_Error FT_Create_Class_##class_( FT_Library library, \
+ FT_Module_Class** output_class ); \
+ void FT_Destroy_Class_##class_( FT_Library library, \
+ FT_Module_Class* clazz );
+
+#define FT_DEFINE_ROOT_MODULE(flags_, size_, name_, version_, requires_, \
+ interface_, init_, done_, get_interface_) \
+ clazz->root.module_flags = flags_; \
+ clazz->root.module_size = size_; \
+ clazz->root.module_name = name_; \
+ clazz->root.module_version = version_; \
+ clazz->root.module_requires = requires_; \
+ \
+ clazz->root.module_interface = interface_; \
+ \
+ clazz->root.module_init = init_; \
+ clazz->root.module_done = done_; \
+ clazz->root.get_interface = get_interface_;
+
+#define FT_DEFINE_MODULE(class_, flags_, size_, name_, version_, requires_, \
+ interface_, init_, done_, get_interface_) \
+ void class_##_pic_free( FT_Library library ); \
+ FT_Error class_##_pic_init( FT_Library library ); \
+ \
+ void \
+ FT_Destroy_Class_##class_( FT_Library library, \
+ FT_Module_Class* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ class_##_pic_free( library ); \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_##class_( FT_Library library, \
+ FT_Module_Class** output_class ) \
+ { \
+ FT_Memory memory = library->memory; \
+ FT_Module_Class* clazz; \
+ FT_Error error; \
+ \
+ if ( FT_ALLOC( clazz, sizeof(*clazz) ) ) \
+ return error; \
+ error = class_##_pic_init( library ); \
+ if(error) \
+ { \
+ FT_FREE( clazz ); \
+ return error; \
+ } \
+ \
+ clazz->module_flags = flags_; \
+ clazz->module_size = size_; \
+ clazz->module_name = name_; \
+ clazz->module_version = version_; \
+ clazz->module_requires = requires_; \
+ \
+ clazz->module_interface = interface_; \
+ \
+ clazz->module_init = init_; \
+ clazz->module_done = done_; \
+ clazz->get_interface = get_interface_; \
+ \
+ *output_class = clazz; \
+ return FT_Err_Ok; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
FT_END_HEADER
diff --git a/src/3rdparty/freetype/include/freetype/internal/ftpic.h b/src/3rdparty/freetype/include/freetype/internal/ftpic.h
new file mode 100644
index 0000000000..1b31957d70
--- /dev/null
+++ b/src/3rdparty/freetype/include/freetype/internal/ftpic.h
@@ -0,0 +1,67 @@
+/***************************************************************************/
+/* */
+/* ftpic.h */
+/* */
+/* The FreeType position independent code services (declaration). */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+ /*************************************************************************/
+ /* */
+ /* Modules that ordinarily have const global data that need address */
+ /* can instead define pointers here. */
+ /* */
+ /*************************************************************************/
+
+
+#ifndef __FTPIC_H__
+#define __FTPIC_H__
+
+
+FT_BEGIN_HEADER
+
+#ifdef FT_CONFIG_OPTION_PIC
+
+ typedef struct FT_PIC_Container_
+ {
+ /* pic containers for base */
+ void* base;
+ /* pic containers for modules */
+ void* autofit;
+ void* cff;
+ void* pshinter;
+ void* psnames;
+ void* raster;
+ void* sfnt;
+ void* smooth;
+ void* truetype;
+ } FT_PIC_Container;
+
+ /* Initialize the various function tables, structs, etc. stored in the container. */
+ FT_BASE( FT_Error )
+ ft_pic_container_init( FT_Library library );
+
+
+ /* Destroy the contents of the container. */
+ FT_BASE( void )
+ ft_pic_container_destroy( FT_Library library );
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /* */
+
+FT_END_HEADER
+
+#endif /* __FTPIC_H__ */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/include/freetype/internal/ftserv.h b/src/3rdparty/freetype/include/freetype/internal/ftserv.h
index 2db3e8790d..569b9f7e0e 100644
--- a/src/3rdparty/freetype/include/freetype/internal/ftserv.h
+++ b/src/3rdparty/freetype/include/freetype/internal/ftserv.h
@@ -163,6 +163,298 @@ FT_BEGIN_HEADER
typedef const FT_ServiceDescRec* FT_ServiceDesc;
+ /*************************************************************************/
+ /* */
+ /* <Macro> */
+ /* FT_DEFINE_SERVICEDESCREC1 .. FT_DEFINE_SERVICEDESCREC6 */
+ /* */
+ /* <Description> */
+ /* Used to initialize an array of FT_ServiceDescRec structs. */
+ /* */
+ /* When FT_CONFIG_OPTION_PIC is defined a Create funtion will need */
+ /* to called with a pointer where the allocated array is returned. */
+ /* And when it is no longer needed a Destroy function needs */
+ /* to be called to release that allocation. */
+ /* */
+ /* These functions should be manyally called from the pic_init and */
+ /* pic_free functions of your module (see FT_DEFINE_MODULE) */
+ /* */
+ /* When FT_CONFIG_OPTION_PIC is not defined the array will be */
+ /* allocated in the global scope (or the scope where the macro */
+ /* is used). */
+ /* */
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_SERVICEDESCREC1(class_, serv_id_1, serv_data_1) \
+ static const FT_ServiceDescRec class_[] = \
+ { \
+ {serv_id_1, serv_data_1}, \
+ {NULL, NULL} \
+ };
+#define FT_DEFINE_SERVICEDESCREC2(class_, serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2) \
+ static const FT_ServiceDescRec class_[] = \
+ { \
+ {serv_id_1, serv_data_1}, \
+ {serv_id_2, serv_data_2}, \
+ {NULL, NULL} \
+ };
+#define FT_DEFINE_SERVICEDESCREC3(class_, serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, serv_id_3, serv_data_3) \
+ static const FT_ServiceDescRec class_[] = \
+ { \
+ {serv_id_1, serv_data_1}, \
+ {serv_id_2, serv_data_2}, \
+ {serv_id_3, serv_data_3}, \
+ {NULL, NULL} \
+ };
+#define FT_DEFINE_SERVICEDESCREC4(class_, serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, serv_id_3, serv_data_3, \
+ serv_id_4, serv_data_4) \
+ static const FT_ServiceDescRec class_[] = \
+ { \
+ {serv_id_1, serv_data_1}, \
+ {serv_id_2, serv_data_2}, \
+ {serv_id_3, serv_data_3}, \
+ {serv_id_4, serv_data_4}, \
+ {NULL, NULL} \
+ };
+#define FT_DEFINE_SERVICEDESCREC5(class_, serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, serv_id_3, serv_data_3, \
+ serv_id_4, serv_data_4, serv_id_5, serv_data_5) \
+ static const FT_ServiceDescRec class_[] = \
+ { \
+ {serv_id_1, serv_data_1}, \
+ {serv_id_2, serv_data_2}, \
+ {serv_id_3, serv_data_3}, \
+ {serv_id_4, serv_data_4}, \
+ {serv_id_5, serv_data_5}, \
+ {NULL, NULL} \
+ };
+#define FT_DEFINE_SERVICEDESCREC6(class_, serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, serv_id_3, serv_data_3, \
+ serv_id_4, serv_data_4, serv_id_5, serv_data_5, \
+ serv_id_6, serv_data_6) \
+ static const FT_ServiceDescRec class_[] = \
+ { \
+ {serv_id_1, serv_data_1}, \
+ {serv_id_2, serv_data_2}, \
+ {serv_id_3, serv_data_3}, \
+ {serv_id_4, serv_data_4}, \
+ {serv_id_5, serv_data_5}, \
+ {serv_id_6, serv_data_6}, \
+ {NULL, NULL} \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICEDESCREC1(class_, serv_id_1, serv_data_1) \
+ void \
+ FT_Destroy_Class_##class_( FT_Library library, \
+ FT_ServiceDescRec* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_##class_( FT_Library library, \
+ FT_ServiceDescRec** output_class) \
+ { \
+ FT_ServiceDescRec* clazz; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ if ( FT_ALLOC( clazz, sizeof(*clazz)*2 ) ) \
+ return error; \
+ clazz[0].serv_id = serv_id_1; \
+ clazz[0].serv_data = serv_data_1; \
+ clazz[1].serv_id = NULL; \
+ clazz[1].serv_data = NULL; \
+ *output_class = clazz; \
+ return FT_Err_Ok; \
+ }
+
+#define FT_DEFINE_SERVICEDESCREC2(class_, serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2) \
+ void \
+ FT_Destroy_Class_##class_( FT_Library library, \
+ FT_ServiceDescRec* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_##class_( FT_Library library, \
+ FT_ServiceDescRec** output_class) \
+ { \
+ FT_ServiceDescRec* clazz; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ if ( FT_ALLOC( clazz, sizeof(*clazz)*3 ) ) \
+ return error; \
+ clazz[0].serv_id = serv_id_1; \
+ clazz[0].serv_data = serv_data_1; \
+ clazz[1].serv_id = serv_id_2; \
+ clazz[1].serv_data = serv_data_2; \
+ clazz[2].serv_id = NULL; \
+ clazz[2].serv_data = NULL; \
+ *output_class = clazz; \
+ return FT_Err_Ok; \
+ }
+
+#define FT_DEFINE_SERVICEDESCREC3(class_, serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, serv_id_3, serv_data_3) \
+ void \
+ FT_Destroy_Class_##class_( FT_Library library, \
+ FT_ServiceDescRec* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_##class_( FT_Library library, \
+ FT_ServiceDescRec** output_class) \
+ { \
+ FT_ServiceDescRec* clazz; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ if ( FT_ALLOC( clazz, sizeof(*clazz)*4 ) ) \
+ return error; \
+ clazz[0].serv_id = serv_id_1; \
+ clazz[0].serv_data = serv_data_1; \
+ clazz[1].serv_id = serv_id_2; \
+ clazz[1].serv_data = serv_data_2; \
+ clazz[2].serv_id = serv_id_3; \
+ clazz[2].serv_data = serv_data_3; \
+ clazz[3].serv_id = NULL; \
+ clazz[3].serv_data = NULL; \
+ *output_class = clazz; \
+ return FT_Err_Ok; \
+ }
+
+#define FT_DEFINE_SERVICEDESCREC4(class_, serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, serv_id_3, serv_data_3, \
+ serv_id_4, serv_data_4) \
+ void \
+ FT_Destroy_Class_##class_( FT_Library library, \
+ FT_ServiceDescRec* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_##class_( FT_Library library, \
+ FT_ServiceDescRec** output_class) \
+ { \
+ FT_ServiceDescRec* clazz; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ if ( FT_ALLOC( clazz, sizeof(*clazz)*5 ) ) \
+ return error; \
+ clazz[0].serv_id = serv_id_1; \
+ clazz[0].serv_data = serv_data_1; \
+ clazz[1].serv_id = serv_id_2; \
+ clazz[1].serv_data = serv_data_2; \
+ clazz[2].serv_id = serv_id_3; \
+ clazz[2].serv_data = serv_data_3; \
+ clazz[3].serv_id = serv_id_4; \
+ clazz[3].serv_data = serv_data_4; \
+ clazz[4].serv_id = NULL; \
+ clazz[4].serv_data = NULL; \
+ *output_class = clazz; \
+ return FT_Err_Ok; \
+ }
+
+#define FT_DEFINE_SERVICEDESCREC5(class_, serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, serv_id_3, serv_data_3, serv_id_4, \
+ serv_data_4, serv_id_5, serv_data_5) \
+ void \
+ FT_Destroy_Class_##class_( FT_Library library, \
+ FT_ServiceDescRec* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_##class_( FT_Library library, \
+ FT_ServiceDescRec** output_class) \
+ { \
+ FT_ServiceDescRec* clazz; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ if ( FT_ALLOC( clazz, sizeof(*clazz)*6 ) ) \
+ return error; \
+ clazz[0].serv_id = serv_id_1; \
+ clazz[0].serv_data = serv_data_1; \
+ clazz[1].serv_id = serv_id_2; \
+ clazz[1].serv_data = serv_data_2; \
+ clazz[2].serv_id = serv_id_3; \
+ clazz[2].serv_data = serv_data_3; \
+ clazz[3].serv_id = serv_id_4; \
+ clazz[3].serv_data = serv_data_4; \
+ clazz[4].serv_id = serv_id_5; \
+ clazz[4].serv_data = serv_data_5; \
+ clazz[5].serv_id = NULL; \
+ clazz[5].serv_data = NULL; \
+ *output_class = clazz; \
+ return FT_Err_Ok; \
+ }
+
+#define FT_DEFINE_SERVICEDESCREC6(class_, serv_id_1, serv_data_1, \
+ serv_id_2, serv_data_2, serv_id_3, serv_data_3, \
+ serv_id_4, serv_data_4, serv_id_5, serv_data_5, \
+ serv_id_6, serv_data_6) \
+ void \
+ FT_Destroy_Class_##class_( FT_Library library, \
+ FT_ServiceDescRec* clazz ) \
+ { \
+ FT_Memory memory = library->memory; \
+ if ( clazz ) \
+ FT_FREE( clazz ); \
+ } \
+ \
+ FT_Error \
+ FT_Create_Class_##class_( FT_Library library, \
+ FT_ServiceDescRec** output_class) \
+ { \
+ FT_ServiceDescRec* clazz; \
+ FT_Error error; \
+ FT_Memory memory = library->memory; \
+ \
+ if ( FT_ALLOC( clazz, sizeof(*clazz)*7 ) ) \
+ return error; \
+ clazz[0].serv_id = serv_id_1; \
+ clazz[0].serv_data = serv_data_1; \
+ clazz[1].serv_id = serv_id_2; \
+ clazz[1].serv_data = serv_data_2; \
+ clazz[2].serv_id = serv_id_3; \
+ clazz[2].serv_data = serv_data_3; \
+ clazz[3].serv_id = serv_id_4; \
+ clazz[3].serv_data = serv_data_4; \
+ clazz[4].serv_id = serv_id_5; \
+ clazz[4].serv_data = serv_data_5; \
+ clazz[5].serv_id = serv_id_6; \
+ clazz[5].serv_data = serv_data_6; \
+ clazz[6].serv_id = NULL; \
+ clazz[6].serv_data = NULL; \
+ *output_class = clazz; \
+ return FT_Err_Ok; \
+ }
+#endif /* FT_CONFIG_OPTION_PIC */
/*
* Parse a list of FT_ServiceDescRec descriptors and look for
diff --git a/src/3rdparty/freetype/include/freetype/internal/fttrace.h b/src/3rdparty/freetype/include/freetype/internal/fttrace.h
index 4d38a4628a..e9b383a588 100644
--- a/src/3rdparty/freetype/include/freetype/internal/fttrace.h
+++ b/src/3rdparty/freetype/include/freetype/internal/fttrace.h
@@ -31,16 +31,19 @@ FT_TRACE_DEF( init ) /* initialization (ftinit.c) */
FT_TRACE_DEF( objs ) /* base objects (ftobjs.c) */
FT_TRACE_DEF( outline ) /* outline management (ftoutln.c) */
FT_TRACE_DEF( glyph ) /* glyph management (ftglyph.c) */
+FT_TRACE_DEF( gloader ) /* glyph loader (ftgloadr.c) */
FT_TRACE_DEF( raster ) /* monochrome rasterizer (ftraster.c) */
FT_TRACE_DEF( smooth ) /* anti-aliasing raster (ftgrays.c) */
FT_TRACE_DEF( mm ) /* MM interface (ftmm.c) */
FT_TRACE_DEF( raccess ) /* resource fork accessor (ftrfork.c) */
+FT_TRACE_DEF( synth ) /* bold/slant synthesizer (ftsynth.c) */
/* Cache sub-system */
FT_TRACE_DEF( cache ) /* cache sub-system (ftcache.c, etc.) */
/* SFNT driver components */
+FT_TRACE_DEF( sfdriver ) /* SFNT font driver (sfdriver.c) */
FT_TRACE_DEF( sfobjs ) /* SFNT object handler (sfobjs.c) */
FT_TRACE_DEF( ttcmap ) /* charmap handler (ttcmap.c) */
FT_TRACE_DEF( ttkern ) /* kerning handler (ttkern.c) */
@@ -48,6 +51,7 @@ FT_TRACE_DEF( ttload ) /* basic TrueType tables (ttload.c) */
FT_TRACE_DEF( ttmtx ) /* metrics-related tables (ttmtx.c) */
FT_TRACE_DEF( ttpost ) /* PS table processing (ttpost.c) */
FT_TRACE_DEF( ttsbit ) /* TrueType sbit handling (ttsbit.c) */
+FT_TRACE_DEF( ttbdf ) /* TrueType embedded BDF (ttbdf.c) */
/* TrueType driver components */
FT_TRACE_DEF( ttdriver ) /* TT font driver (ttdriver.c) */
@@ -58,6 +62,7 @@ FT_TRACE_DEF( ttpload ) /* TT data/program loader (ttpload.c) */
FT_TRACE_DEF( ttgxvar ) /* TrueType GX var handler (ttgxvar.c) */
/* Type 1 driver components */
+FT_TRACE_DEF( t1afm )
FT_TRACE_DEF( t1driver )
FT_TRACE_DEF( t1gload )
FT_TRACE_DEF( t1hint )
diff --git a/src/3rdparty/freetype/include/freetype/internal/internal.h b/src/3rdparty/freetype/include/freetype/internal/internal.h
index 27d5dc585d..f500a651c2 100644
--- a/src/3rdparty/freetype/include/freetype/internal/internal.h
+++ b/src/3rdparty/freetype/include/freetype/internal/internal.h
@@ -25,6 +25,7 @@
#define FT_INTERNAL_OBJECTS_H <freetype/internal/ftobjs.h>
+#define FT_INTERNAL_PIC_H <freetype/internal/ftpic.h>
#define FT_INTERNAL_STREAM_H <freetype/internal/ftstream.h>
#define FT_INTERNAL_MEMORY_H <freetype/internal/ftmemory.h>
#define FT_INTERNAL_DEBUG_H <freetype/internal/ftdebug.h>
diff --git a/src/3rdparty/freetype/include/freetype/internal/psaux.h b/src/3rdparty/freetype/include/freetype/internal/psaux.h
index 7fb4c9916d..a96e0dfa86 100644
--- a/src/3rdparty/freetype/include/freetype/internal/psaux.h
+++ b/src/3rdparty/freetype/include/freetype/internal/psaux.h
@@ -360,7 +360,7 @@ FT_BEGIN_HEADER
FT_Error
(*to_bytes)( PS_Parser parser,
FT_Byte* bytes,
- FT_Long max_bytes,
+ FT_Offset max_bytes,
FT_Long* pnum_bytes,
FT_Bool delimiters );
@@ -533,8 +533,6 @@ FT_BEGIN_HEADER
/* */
/* max_contours :: Maximal number of contours in builder outline. */
/* */
- /* last :: The last point position. */
- /* */
/* pos_x :: The horizontal translation (if composite glyph). */
/* */
/* pos_y :: The vertical translation (if composite glyph). */
@@ -567,8 +565,6 @@ FT_BEGIN_HEADER
FT_Outline* base;
FT_Outline* current;
- FT_Vector last;
-
FT_Pos pos_x;
FT_Pos pos_y;
@@ -579,7 +575,6 @@ FT_BEGIN_HEADER
T1_ParseState parse_state;
FT_Bool load_points;
FT_Bool no_recurse;
- FT_Bool shift;
FT_Bool metrics_only;
@@ -694,9 +689,11 @@ FT_BEGIN_HEADER
T1_Decoder_Callback parse_callback;
T1_Decoder_FuncsRec funcs;
- FT_Int* buildchar;
+ FT_Long* buildchar;
FT_UInt len_buildchar;
+ FT_Bool seac;
+
} T1_DecoderRec;
@@ -758,7 +755,7 @@ FT_BEGIN_HEADER
FT_Int
(*get_index)( const char* name,
- FT_UInt len,
+ FT_Offset len,
void* user_data );
void* user_data;
diff --git a/src/3rdparty/freetype/include/freetype/internal/pshints.h b/src/3rdparty/freetype/include/freetype/internal/pshints.h
index 48452c0cf3..0c357651be 100644
--- a/src/3rdparty/freetype/include/freetype/internal/pshints.h
+++ b/src/3rdparty/freetype/include/freetype/internal/pshints.h
@@ -6,7 +6,7 @@
/* recorders (specification only). These are used to support native */
/* T1/T2 hints in the `type1', `cid', and `cff' font drivers. */
/* */
-/* Copyright 2001, 2002, 2003, 2005, 2006, 2007 by */
+/* Copyright 2001, 2002, 2003, 2005, 2006, 2007, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -157,7 +157,8 @@ FT_BEGIN_HEADER
* 0 for horizontal stems (hstem), 1 for vertical ones (vstem).
*
* coords ::
- * Array of 2 integers, used as (position,length) stem descriptor.
+ * Array of 2 coordinates in 16.16 format, used as (position,length)
+ * stem descriptor.
*
* @note:
* Use vertical coordinates (y) for horizontal stems (dim=0). Use
@@ -175,9 +176,9 @@ FT_BEGIN_HEADER
*
*/
typedef void
- (*T1_Hints_SetStemFunc)( T1_Hints hints,
- FT_UInt dimension,
- FT_Long* coords );
+ (*T1_Hints_SetStemFunc)( T1_Hints hints,
+ FT_UInt dimension,
+ FT_Fixed* coords );
/*************************************************************************
@@ -197,8 +198,8 @@ FT_BEGIN_HEADER
* 0 for horizontal stems, 1 for vertical ones.
*
* coords ::
- * An array of 6 integers, holding 3 (position,length) pairs for the
- * counter-controlled stems.
+ * An array of 6 values in 16.16 format, holding 3 (position,length)
+ * pairs for the counter-controlled stems.
*
* @note:
* Use vertical coordinates (y) for horizontal stems (dim=0). Use
@@ -209,9 +210,9 @@ FT_BEGIN_HEADER
*
*/
typedef void
- (*T1_Hints_SetStem3Func)( T1_Hints hints,
- FT_UInt dimension,
- FT_Long* coords );
+ (*T1_Hints_SetStem3Func)( T1_Hints hints,
+ FT_UInt dimension,
+ FT_Fixed* coords );
/*************************************************************************
@@ -446,7 +447,7 @@ FT_BEGIN_HEADER
* The number of stems.
*
* coords ::
- * An array of `count' (position,length) pairs.
+ * An array of `count' (position,length) pairs in 16.16 format.
*
* @note:
* Use vertical coordinates (y) for horizontal stems (dim=0). Use
@@ -678,6 +679,30 @@ FT_BEGIN_HEADER
typedef PSHinter_Interface* PSHinter_Service;
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_PSHINTER_INTERFACE(class_, get_globals_funcs_, \
+ get_t1_funcs_, get_t2_funcs_) \
+ static const PSHinter_Interface class_ = \
+ { \
+ get_globals_funcs_, get_t1_funcs_, get_t2_funcs_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_PSHINTER_INTERFACE(class_, get_globals_funcs_, \
+ get_t1_funcs_, get_t2_funcs_) \
+ void \
+ FT_Init_Class_##class_( FT_Library library, \
+ PSHinter_Interface* clazz) \
+ { \
+ FT_UNUSED(library); \
+ clazz->get_globals_funcs = get_globals_funcs_; \
+ clazz->get_t1_funcs = get_t1_funcs_; \
+ clazz->get_t2_funcs = get_t2_funcs_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
FT_END_HEADER
diff --git a/src/3rdparty/freetype/include/freetype/internal/services/svbdf.h b/src/3rdparty/freetype/include/freetype/internal/services/svbdf.h
index 0f7fc6115d..9264239146 100644
--- a/src/3rdparty/freetype/include/freetype/internal/services/svbdf.h
+++ b/src/3rdparty/freetype/include/freetype/internal/services/svbdf.h
@@ -45,6 +45,26 @@ FT_BEGIN_HEADER
FT_BDF_GetPropertyFunc get_property;
};
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_SERVICE_BDFRec(class_, get_charset_id_, get_property_) \
+ static const FT_Service_BDFRec class_ = \
+ { \
+ get_charset_id_, get_property_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_BDFRec(class_, get_charset_id_, get_property_) \
+ void \
+ FT_Init_Class_##class_( FT_Service_BDFRec* clazz ) \
+ { \
+ clazz->get_charset_id = get_charset_id_; \
+ clazz->get_property = get_property_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
/* */
diff --git a/src/3rdparty/freetype/include/freetype/internal/services/svcid.h b/src/3rdparty/freetype/include/freetype/internal/services/svcid.h
index 2e391f2888..9b874b5e72 100644
--- a/src/3rdparty/freetype/include/freetype/internal/services/svcid.h
+++ b/src/3rdparty/freetype/include/freetype/internal/services/svcid.h
@@ -46,6 +46,31 @@ FT_BEGIN_HEADER
FT_CID_GetCIDFromGlyphIndexFunc get_cid_from_glyph_index;
};
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_SERVICE_CIDREC(class_, get_ros_, \
+ get_is_cid_, get_cid_from_glyph_index_ ) \
+ static const FT_Service_CIDRec class_ = \
+ { \
+ get_ros_, get_is_cid_, get_cid_from_glyph_index_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_CIDREC(class_, get_ros_, \
+ get_is_cid_, get_cid_from_glyph_index_ ) \
+ void \
+ FT_Init_Class_##class_( FT_Library library, \
+ FT_Service_CIDRec* clazz) \
+ { \
+ FT_UNUSED(library); \
+ clazz->get_ros = get_ros_; \
+ clazz->get_is_cid = get_is_cid_; \
+ clazz->get_cid_from_glyph_index = get_cid_from_glyph_index_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
/* */
diff --git a/src/3rdparty/freetype/include/freetype/internal/services/svgldict.h b/src/3rdparty/freetype/include/freetype/internal/services/svgldict.h
index e5e56b253c..d66a41d5ae 100644
--- a/src/3rdparty/freetype/include/freetype/internal/services/svgldict.h
+++ b/src/3rdparty/freetype/include/freetype/internal/services/svgldict.h
@@ -51,6 +51,28 @@ FT_BEGIN_HEADER
FT_GlyphDict_NameIndexFunc name_index; /* optional */
};
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_SERVICE_GLYPHDICTREC(class_, get_name_, name_index_) \
+ static const FT_Service_GlyphDictRec class_ = \
+ { \
+ get_name_, name_index_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_GLYPHDICTREC(class_, get_name_, name_index_) \
+ void \
+ FT_Init_Class_##class_( FT_Library library, \
+ FT_Service_GlyphDictRec* clazz) \
+ { \
+ FT_UNUSED(library); \
+ clazz->get_name = get_name_; \
+ clazz->name_index = name_index_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
/* */
diff --git a/src/3rdparty/freetype/include/freetype/internal/services/svmm.h b/src/3rdparty/freetype/include/freetype/internal/services/svmm.h
index 8a99ec4b1a..66e1da22f1 100644
--- a/src/3rdparty/freetype/include/freetype/internal/services/svmm.h
+++ b/src/3rdparty/freetype/include/freetype/internal/services/svmm.h
@@ -68,6 +68,31 @@ FT_BEGIN_HEADER
FT_Set_Var_Design_Func set_var_design;
};
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_SERVICE_MULTIMASTERSREC(class_, get_mm_, set_mm_design_, \
+ set_mm_blend_, get_mm_var_, set_var_design_) \
+ static const FT_Service_MultiMastersRec class_ = \
+ { \
+ get_mm_, set_mm_design_, set_mm_blend_, get_mm_var_, set_var_design_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_MULTIMASTERSREC(class_, get_mm_, set_mm_design_, \
+ set_mm_blend_, get_mm_var_, set_var_design_) \
+ void \
+ FT_Init_Class_##class_( FT_Service_MultiMastersRec* clazz ) \
+ { \
+ clazz->get_mm = get_mm_; \
+ clazz->set_mm_design = set_mm_design_; \
+ clazz->set_mm_blend = set_mm_blend_; \
+ clazz->get_mm_var = get_mm_var_; \
+ clazz->set_var_design = set_var_design_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
/* */
diff --git a/src/3rdparty/freetype/include/freetype/internal/services/svpostnm.h b/src/3rdparty/freetype/include/freetype/internal/services/svpostnm.h
index 282da68d13..106c54f853 100644
--- a/src/3rdparty/freetype/include/freetype/internal/services/svpostnm.h
+++ b/src/3rdparty/freetype/include/freetype/internal/services/svpostnm.h
@@ -46,6 +46,27 @@ FT_BEGIN_HEADER
FT_PsName_GetFunc get_ps_font_name;
};
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_SERVICE_PSFONTNAMEREC(class_, get_ps_font_name_) \
+ static const FT_Service_PsFontNameRec class_ = \
+ { \
+ get_ps_font_name_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_PSFONTNAMEREC(class_, get_ps_font_name_) \
+ void \
+ FT_Init_Class_##class_( FT_Library library, \
+ FT_Service_PsFontNameRec* clazz) \
+ { \
+ FT_UNUSED(library); \
+ clazz->get_ps_font_name = get_ps_font_name_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
/* */
diff --git a/src/3rdparty/freetype/include/freetype/internal/services/svpscmap.h b/src/3rdparty/freetype/include/freetype/internal/services/svpscmap.h
index c4e25ed635..961030cc39 100644
--- a/src/3rdparty/freetype/include/freetype/internal/services/svpscmap.h
+++ b/src/3rdparty/freetype/include/freetype/internal/services/svpscmap.h
@@ -98,7 +98,7 @@ FT_BEGIN_HEADER
(*PS_Unicodes_CharIndexFunc)( PS_Unicodes unicodes,
FT_UInt32 unicode );
- typedef FT_ULong
+ typedef FT_UInt32
(*PS_Unicodes_CharNextFunc)( PS_Unicodes unicodes,
FT_UInt32 *unicode );
@@ -117,6 +117,41 @@ FT_BEGIN_HEADER
const unsigned short* adobe_expert_encoding;
};
+
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_SERVICE_PSCMAPSREC(class_, unicode_value_, unicodes_init_, \
+ unicodes_char_index_, unicodes_char_next_, macintosh_name_, \
+ adobe_std_strings_, adobe_std_encoding_, adobe_expert_encoding_) \
+ static const FT_Service_PsCMapsRec class_ = \
+ { \
+ unicode_value_, unicodes_init_, \
+ unicodes_char_index_, unicodes_char_next_, macintosh_name_, \
+ adobe_std_strings_, adobe_std_encoding_, adobe_expert_encoding_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_PSCMAPSREC(class_, unicode_value_, unicodes_init_, \
+ unicodes_char_index_, unicodes_char_next_, macintosh_name_, \
+ adobe_std_strings_, adobe_std_encoding_, adobe_expert_encoding_) \
+ void \
+ FT_Init_Class_##class_( FT_Library library, \
+ FT_Service_PsCMapsRec* clazz) \
+ { \
+ FT_UNUSED(library); \
+ clazz->unicode_value = unicode_value_; \
+ clazz->unicodes_init = unicodes_init_; \
+ clazz->unicodes_char_index = unicodes_char_index_; \
+ clazz->unicodes_char_next = unicodes_char_next_; \
+ clazz->macintosh_name = macintosh_name_; \
+ clazz->adobe_std_strings = adobe_std_strings_; \
+ clazz->adobe_std_encoding = adobe_std_encoding_; \
+ clazz->adobe_expert_encoding = adobe_expert_encoding_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
/* */
diff --git a/src/3rdparty/freetype/include/freetype/internal/services/svpsinfo.h b/src/3rdparty/freetype/include/freetype/internal/services/svpsinfo.h
index 124c6f9f9f..91ba91e5dc 100644
--- a/src/3rdparty/freetype/include/freetype/internal/services/svpsinfo.h
+++ b/src/3rdparty/freetype/include/freetype/internal/services/svpsinfo.h
@@ -53,6 +53,33 @@ FT_BEGIN_HEADER
PS_GetFontPrivateFunc ps_get_font_private;
};
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_SERVICE_PSINFOREC(class_, get_font_info_, \
+ ps_get_font_extra_, has_glyph_names_, get_font_private_) \
+ static const FT_Service_PsInfoRec class_ = \
+ { \
+ get_font_info_, ps_get_font_extra_, has_glyph_names_, \
+ get_font_private_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_PSINFOREC(class_, get_font_info_, \
+ ps_get_font_extra_, has_glyph_names_, get_font_private_) \
+ void \
+ FT_Init_Class_##class_( FT_Library library, \
+ FT_Service_PsInfoRec* clazz) \
+ { \
+ FT_UNUSED(library); \
+ clazz->ps_get_font_info = get_font_info_; \
+ clazz->ps_get_font_extra = ps_get_font_extra_; \
+ clazz->ps_has_glyph_names = has_glyph_names_; \
+ clazz->ps_get_font_private = get_font_private_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
/* */
diff --git a/src/3rdparty/freetype/include/freetype/internal/services/svsfnt.h b/src/3rdparty/freetype/include/freetype/internal/services/svsfnt.h
index b4a85d97ec..30bb1620fe 100644
--- a/src/3rdparty/freetype/include/freetype/internal/services/svsfnt.h
+++ b/src/3rdparty/freetype/include/freetype/internal/services/svsfnt.h
@@ -58,6 +58,7 @@ FT_BEGIN_HEADER
(*FT_SFNT_TableInfoFunc)( FT_Face face,
FT_UInt idx,
FT_ULong *tag,
+ FT_ULong *offset,
FT_ULong *length );
@@ -68,6 +69,27 @@ FT_BEGIN_HEADER
FT_SFNT_TableInfoFunc table_info;
};
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_SERVICE_SFNT_TABLEREC(class_, load_, get_, info_) \
+ static const FT_Service_SFNT_TableRec class_ = \
+ { \
+ load_, get_, info_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_SFNT_TABLEREC(class_, load_, get_, info_) \
+ void \
+ FT_Init_Class_##class_( FT_Service_SFNT_TableRec* clazz ) \
+ { \
+ clazz->load_table = load_; \
+ clazz->get_table = get_; \
+ clazz->table_info = info_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
/* */
diff --git a/src/3rdparty/freetype/include/freetype/internal/services/svttcmap.h b/src/3rdparty/freetype/include/freetype/internal/services/svttcmap.h
index 553ecb074e..8af00351d9 100644
--- a/src/3rdparty/freetype/include/freetype/internal/services/svttcmap.h
+++ b/src/3rdparty/freetype/include/freetype/internal/services/svttcmap.h
@@ -1,6 +1,6 @@
/***************************************************************************/
/* */
-/* svsttcmap.h */
+/* svttcmap.h */
/* */
/* The FreeType TrueType/sfnt cmap extra information service. */
/* */
@@ -74,6 +74,27 @@ FT_BEGIN_HEADER
TT_CMap_Info_GetFunc get_cmap_info;
};
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_SERVICE_TTCMAPSREC(class_, get_cmap_info_) \
+ static const FT_Service_TTCMapsRec class_ = \
+ { \
+ get_cmap_info_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_TTCMAPSREC(class_, get_cmap_info_) \
+ void \
+ FT_Init_Class_##class_( FT_Library library, \
+ FT_Service_TTCMapsRec* clazz) \
+ { \
+ FT_UNUSED(library); \
+ clazz->get_cmap_info = get_cmap_info_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
/* */
diff --git a/src/3rdparty/freetype/include/freetype/internal/services/svttglyf.h b/src/3rdparty/freetype/include/freetype/internal/services/svttglyf.h
index e57d484b7e..ab2dc9a9fe 100644
--- a/src/3rdparty/freetype/include/freetype/internal/services/svttglyf.h
+++ b/src/3rdparty/freetype/include/freetype/internal/services/svttglyf.h
@@ -37,6 +37,25 @@ FT_BEGIN_HEADER
TT_Glyf_GetLocationFunc get_location;
};
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_SERVICE_TTGLYFREC(class_, get_location_ ) \
+ static const FT_Service_TTGlyfRec class_ = \
+ { \
+ get_location_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_SERVICE_TTGLYFREC(class_, get_location_ ) \
+ void \
+ FT_Init_Class_##class_( FT_Service_TTGlyfRec* clazz ) \
+ { \
+ clazz->get_location = get_location_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
/* */
diff --git a/src/3rdparty/freetype/include/freetype/internal/sfnt.h b/src/3rdparty/freetype/include/freetype/internal/sfnt.h
index 7e8f6847c9..6326debd00 100644
--- a/src/3rdparty/freetype/include/freetype/internal/sfnt.h
+++ b/src/3rdparty/freetype/include/freetype/internal/sfnt.h
@@ -753,6 +753,141 @@ FT_BEGIN_HEADER
/* transitional */
typedef SFNT_Interface* SFNT_Service;
+#ifndef FT_CONFIG_OPTION_PIC
+
+#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
+#define FT_DEFINE_DRIVERS_OLD_INTERNAL(a) \
+ a,
+#else
+ #define FT_DEFINE_DRIVERS_OLD_INTERNAL(a)
+#endif
+#define FT_INTERNAL(a) \
+ a,
+
+#define FT_DEFINE_SFNT_INTERFACE(class_, \
+ goto_table_, init_face_, load_face_, done_face_, get_interface_, \
+ load_any_, load_sfnt_header_, load_directory_, load_head_, \
+ load_hhea_, load_cmap_, load_maxp_, load_os2_, load_post_, \
+ load_name_, free_name_, load_hdmx_stub_, free_hdmx_stub_, \
+ load_kern_, load_gasp_, load_pclt_, load_bhed_, \
+ set_sbit_strike_stub_, load_sbits_stub_, find_sbit_image_, \
+ load_sbit_metrics_, load_sbit_image_, free_sbits_stub_, \
+ get_psname_, free_psnames_, load_charmap_stub_, free_charmap_stub_, \
+ get_kerning_, load_font_dir_, load_hmtx_, load_eblc_, free_eblc_, \
+ set_sbit_strike_, load_strike_metrics_, get_metrics_ ) \
+ static const SFNT_Interface class_ = \
+ { \
+ FT_INTERNAL(goto_table_) \
+ FT_INTERNAL(init_face_) \
+ FT_INTERNAL(load_face_) \
+ FT_INTERNAL(done_face_) \
+ FT_INTERNAL(get_interface_) \
+ FT_INTERNAL(load_any_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(load_sfnt_header_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(load_directory_) \
+ FT_INTERNAL(load_head_) \
+ FT_INTERNAL(load_hhea_) \
+ FT_INTERNAL(load_cmap_) \
+ FT_INTERNAL(load_maxp_) \
+ FT_INTERNAL(load_os2_) \
+ FT_INTERNAL(load_post_) \
+ FT_INTERNAL(load_name_) \
+ FT_INTERNAL(free_name_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(load_hdmx_stub_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(free_hdmx_stub_) \
+ FT_INTERNAL(load_kern_) \
+ FT_INTERNAL(load_gasp_) \
+ FT_INTERNAL(load_pclt_) \
+ FT_INTERNAL(load_bhed_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(set_sbit_strike_stub_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(load_sbits_stub_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(find_sbit_image_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(load_sbit_metrics_) \
+ FT_INTERNAL(load_sbit_image_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(free_sbits_stub_) \
+ FT_INTERNAL(get_psname_) \
+ FT_INTERNAL(free_psnames_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(load_charmap_stub_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(free_charmap_stub_) \
+ FT_INTERNAL(get_kerning_) \
+ FT_INTERNAL(load_font_dir_) \
+ FT_INTERNAL(load_hmtx_) \
+ FT_INTERNAL(load_eblc_) \
+ FT_INTERNAL(free_eblc_) \
+ FT_INTERNAL(set_sbit_strike_) \
+ FT_INTERNAL(load_strike_metrics_) \
+ FT_INTERNAL(get_metrics_) \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
+#define FT_DEFINE_DRIVERS_OLD_INTERNAL(a, a_) \
+ clazz->a = a_;
+#else
+ #define FT_DEFINE_DRIVERS_OLD_INTERNAL(a, a_)
+#endif
+#define FT_INTERNAL(a, a_) \
+ clazz->a = a_;
+
+#define FT_DEFINE_SFNT_INTERFACE(class_, \
+ goto_table_, init_face_, load_face_, done_face_, get_interface_, \
+ load_any_, load_sfnt_header_, load_directory_, load_head_, \
+ load_hhea_, load_cmap_, load_maxp_, load_os2_, load_post_, \
+ load_name_, free_name_, load_hdmx_stub_, free_hdmx_stub_, \
+ load_kern_, load_gasp_, load_pclt_, load_bhed_, \
+ set_sbit_strike_stub_, load_sbits_stub_, find_sbit_image_, \
+ load_sbit_metrics_, load_sbit_image_, free_sbits_stub_, \
+ get_psname_, free_psnames_, load_charmap_stub_, free_charmap_stub_, \
+ get_kerning_, load_font_dir_, load_hmtx_, load_eblc_, free_eblc_, \
+ set_sbit_strike_, load_strike_metrics_, get_metrics_ ) \
+ void \
+ FT_Init_Class_##class_( FT_Library library, SFNT_Interface* clazz ) \
+ { \
+ FT_UNUSED(library); \
+ FT_INTERNAL(goto_table,goto_table_) \
+ FT_INTERNAL(init_face,init_face_) \
+ FT_INTERNAL(load_face,load_face_) \
+ FT_INTERNAL(done_face,done_face_) \
+ FT_INTERNAL(get_interface,get_interface_) \
+ FT_INTERNAL(load_any,load_any_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(load_sfnt_header,load_sfnt_header_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(load_directory,load_directory_) \
+ FT_INTERNAL(load_head,load_head_) \
+ FT_INTERNAL(load_hhea,load_hhea_) \
+ FT_INTERNAL(load_cmap,load_cmap_) \
+ FT_INTERNAL(load_maxp,load_maxp_) \
+ FT_INTERNAL(load_os2,load_os2_) \
+ FT_INTERNAL(load_post,load_post_) \
+ FT_INTERNAL(load_name,load_name_) \
+ FT_INTERNAL(free_name,free_name_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(load_hdmx_stub,load_hdmx_stub_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(free_hdmx_stub,free_hdmx_stub_) \
+ FT_INTERNAL(load_kern,load_kern_) \
+ FT_INTERNAL(load_gasp,load_gasp_) \
+ FT_INTERNAL(load_pclt,load_pclt_) \
+ FT_INTERNAL(load_bhed,load_bhed_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(set_sbit_strike_stub,set_sbit_strike_stub_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(load_sbits_stub,load_sbits_stub_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(find_sbit_image,find_sbit_image_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(load_sbit_metrics,load_sbit_metrics_) \
+ FT_INTERNAL(load_sbit_image,load_sbit_image_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(free_sbits_stub,free_sbits_stub_) \
+ FT_INTERNAL(get_psname,get_psname_) \
+ FT_INTERNAL(free_psnames,free_psnames_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(load_charmap_stub,load_charmap_stub_) \
+ FT_DEFINE_DRIVERS_OLD_INTERNAL(free_charmap_stub,free_charmap_stub_) \
+ FT_INTERNAL(get_kerning,get_kerning_) \
+ FT_INTERNAL(load_font_dir,load_font_dir_) \
+ FT_INTERNAL(load_hmtx,load_hmtx_) \
+ FT_INTERNAL(load_eblc,load_eblc_) \
+ FT_INTERNAL(free_eblc,free_eblc_) \
+ FT_INTERNAL(set_sbit_strike,set_sbit_strike_) \
+ FT_INTERNAL(load_strike_metrics,load_strike_metrics_) \
+ FT_INTERNAL(get_metrics,get_metrics_) \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
FT_END_HEADER
diff --git a/src/3rdparty/freetype/include/freetype/internal/t1types.h b/src/3rdparty/freetype/include/freetype/internal/t1types.h
index ff021b0fef..5f730637b5 100644
--- a/src/3rdparty/freetype/include/freetype/internal/t1types.h
+++ b/src/3rdparty/freetype/include/freetype/internal/t1types.h
@@ -58,7 +58,9 @@ FT_BEGIN_HEADER
/* */
/* code_first :: The lowest valid character code in the encoding. */
/* */
- /* code_last :: The highest valid character code in the encoding. */
+ /* code_last :: The highest valid character code in the encoding */
+ /* + 1. When equal to code_first there are no valid */
+ /* character codes. */
/* */
/* char_index :: An array of corresponding glyph indices. */
/* */
@@ -230,7 +232,7 @@ FT_BEGIN_HEADER
/* undocumented, optional: has the same meaning as len_buildchar */
/* for Type 2 fonts; manipulated by othersubrs 19, 24, and 25 */
FT_UInt len_buildchar;
- FT_Int* buildchar;
+ FT_Long* buildchar;
/* since version 2.1 - interface to PostScript hinter */
const void* pshinter;
diff --git a/src/3rdparty/freetype/include/freetype/internal/tttypes.h b/src/3rdparty/freetype/include/freetype/internal/tttypes.h
index 85fc27f74e..acbb863b0f 100644
--- a/src/3rdparty/freetype/include/freetype/internal/tttypes.h
+++ b/src/3rdparty/freetype/include/freetype/internal/tttypes.h
@@ -902,7 +902,7 @@ FT_BEGIN_HEADER
FT_Byte* table;
FT_Byte* table_end;
FT_Byte* strings;
- FT_UInt32 strings_size;
+ FT_ULong strings_size;
FT_UInt num_strikes;
FT_Bool loaded;
@@ -1401,7 +1401,7 @@ FT_BEGIN_HEADER
FT_Byte* vert_metrics;
FT_ULong vert_metrics_size;
- FT_UInt num_locations;
+ FT_ULong num_locations; /* in broken TTF, gid > 0xFFFF */
FT_Byte* glyph_locations;
FT_Byte* hdmx_table;
diff --git a/src/3rdparty/freetype/src/autofit/Jamfile b/src/3rdparty/freetype/src/autofit/Jamfile
index acee8bf2cb..2714765b5b 100644
--- a/src/3rdparty/freetype/src/autofit/Jamfile
+++ b/src/3rdparty/freetype/src/autofit/Jamfile
@@ -1,6 +1,6 @@
# FreeType 2 src/autofit Jamfile
#
-# Copyright 2003, 2004, 2005, 2006, 2007 by
+# Copyright 2003, 2004, 2005, 2006, 2007, 2009 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -14,14 +14,14 @@ SubDir FT2_TOP src autofit ;
{
local _sources ;
- # define FT2_AUTOFIT2 do enable to experimental latin hinter replacement
+ # define FT2_AUTOFIT2 to enable experimental latin hinter replacement
if $(FT2_AUTOFIT2)
{
DEFINES += FT_OPTION_AUTOFIT2 ;
}
if $(FT2_MULTI)
{
- _sources = afangles afglobal afhints aflatin afcjk afindic afloader afmodule afdummy afwarp ;
+ _sources = afangles afglobal afhints aflatin afcjk afindic afloader afmodule afdummy afwarp afpic ;
if $(FT2_AUTOFIT2)
{
diff --git a/src/3rdparty/freetype/src/autofit/afcjk.c b/src/3rdparty/freetype/src/autofit/afcjk.c
index de3ce11d54..bab0c42bad 100644
--- a/src/3rdparty/freetype/src/autofit/afcjk.c
+++ b/src/3rdparty/freetype/src/autofit/afcjk.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines for CJK script (body). */
/* */
-/* Copyright 2006, 2007, 2008 by */
+/* Copyright 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -58,9 +58,12 @@
if ( FT_Select_Charmap( face, FT_ENCODING_UNICODE ) )
face->charmap = NULL;
-
- /* latin's version would suffice */
- af_latin_metrics_init_widths( metrics, face, 0x7530 );
+ else
+ {
+ /* latin's version would suffice */
+ af_latin_metrics_init_widths( metrics, face, 0x7530 );
+ af_latin_metrics_check_digits( metrics, face );
+ }
FT_Set_Charmap( face, oldmap );
@@ -1017,7 +1020,7 @@
AF_AxisHints axis = &hints->axis[dim];
AF_Edge edges = axis->edges;
AF_Edge edge_limit = edges + axis->num_edges;
- FT_Int n_edges;
+ FT_PtrDist n_edges;
AF_Edge edge;
AF_Edge anchor = 0;
FT_Pos delta = 0;
@@ -1441,35 +1444,33 @@
static const AF_Script_UniRangeRec af_cjk_uniranges[] =
{
#if 0
- { 0x0100UL, 0xFFFFUL }, /* why this? */
+ AF_UNIRANGE_REC( 0x0100UL, 0xFFFFUL ), /* why this? */
#endif
- { 0x2E80UL, 0x2EFFUL }, /* CJK Radicals Supplement */
- { 0x2F00UL, 0x2FDFUL }, /* Kangxi Radicals */
- { 0x3000UL, 0x303FUL }, /* CJK Symbols and Punctuation */
- { 0x3040UL, 0x309FUL }, /* Hiragana */
- { 0x30A0UL, 0x30FFUL }, /* Katakana */
- { 0x3100UL, 0x312FUL }, /* Bopomofo */
- { 0x3130UL, 0x318FUL }, /* Hangul Compatibility Jamo */
- { 0x31A0UL, 0x31BFUL }, /* Bopomofo Extended */
- { 0x31C0UL, 0x31EFUL }, /* CJK Strokes */
- { 0x31F0UL, 0x31FFUL }, /* Katakana Phonetic Extensions */
- { 0x3200UL, 0x32FFUL }, /* Enclosed CJK Letters and Months */
- { 0x3300UL, 0x33FFUL }, /* CJK Compatibility */
- { 0x3400UL, 0x4DBFUL }, /* CJK Unified Ideographs Extension A */
- { 0x4DC0UL, 0x4DFFUL }, /* Yijing Hexagram Symbols */
- { 0x4E00UL, 0x9FFFUL }, /* CJK Unified Ideographs */
- { 0xF900UL, 0xFAFFUL }, /* CJK Compatibility Ideographs */
- { 0xFE30UL, 0xFE4FUL }, /* CJK Compatibility Forms */
- { 0xFF00UL, 0xFFEFUL }, /* Halfwidth and Fullwidth Forms */
- { 0x20000UL, 0x2A6DFUL }, /* CJK Unified Ideographs Extension B */
- { 0x2F800UL, 0x2FA1FUL }, /* CJK Compatibility Ideographs Supplement */
- { 0UL, 0UL }
+ AF_UNIRANGE_REC( 0x2E80UL, 0x2EFFUL ), /* CJK Radicals Supplement */
+ AF_UNIRANGE_REC( 0x2F00UL, 0x2FDFUL ), /* Kangxi Radicals */
+ AF_UNIRANGE_REC( 0x3000UL, 0x303FUL ), /* CJK Symbols and Punctuation */
+ AF_UNIRANGE_REC( 0x3040UL, 0x309FUL ), /* Hiragana */
+ AF_UNIRANGE_REC( 0x30A0UL, 0x30FFUL ), /* Katakana */
+ AF_UNIRANGE_REC( 0x3100UL, 0x312FUL ), /* Bopomofo */
+ AF_UNIRANGE_REC( 0x3130UL, 0x318FUL ), /* Hangul Compatibility Jamo */
+ AF_UNIRANGE_REC( 0x31A0UL, 0x31BFUL ), /* Bopomofo Extended */
+ AF_UNIRANGE_REC( 0x31C0UL, 0x31EFUL ), /* CJK Strokes */
+ AF_UNIRANGE_REC( 0x31F0UL, 0x31FFUL ), /* Katakana Phonetic Extensions */
+ AF_UNIRANGE_REC( 0x3200UL, 0x32FFUL ), /* Enclosed CJK Letters and Months */
+ AF_UNIRANGE_REC( 0x3300UL, 0x33FFUL ), /* CJK Compatibility */
+ AF_UNIRANGE_REC( 0x3400UL, 0x4DBFUL ), /* CJK Unified Ideographs Extension A */
+ AF_UNIRANGE_REC( 0x4DC0UL, 0x4DFFUL ), /* Yijing Hexagram Symbols */
+ AF_UNIRANGE_REC( 0x4E00UL, 0x9FFFUL ), /* CJK Unified Ideographs */
+ AF_UNIRANGE_REC( 0xF900UL, 0xFAFFUL ), /* CJK Compatibility Ideographs */
+ AF_UNIRANGE_REC( 0xFE30UL, 0xFE4FUL ), /* CJK Compatibility Forms */
+ AF_UNIRANGE_REC( 0xFF00UL, 0xFFEFUL ), /* Halfwidth and Fullwidth Forms */
+ AF_UNIRANGE_REC( 0x20000UL, 0x2A6DFUL ), /* CJK Unified Ideographs Extension B */
+ AF_UNIRANGE_REC( 0x2F800UL, 0x2FA1FUL ), /* CJK Compatibility Ideographs Supplement */
+ AF_UNIRANGE_REC( 0UL, 0UL )
};
- FT_CALLBACK_TABLE_DEF const AF_ScriptClassRec
- af_cjk_script_class =
- {
+ AF_DEFINE_SCRIPT_CLASS(af_cjk_script_class,
AF_SCRIPT_CJK,
af_cjk_uniranges,
@@ -1481,19 +1482,17 @@
(AF_Script_InitHintsFunc) af_cjk_hints_init,
(AF_Script_ApplyHintsFunc) af_cjk_hints_apply
- };
+ )
#else /* !AF_CONFIG_OPTION_CJK */
static const AF_Script_UniRangeRec af_cjk_uniranges[] =
{
- { 0, 0 }
+ AF_UNIRANGE_REC( 0UL, 0UL )
};
- FT_CALLBACK_TABLE_DEF const AF_ScriptClassRec
- af_cjk_script_class =
- {
+ AF_DEFINE_SCRIPT_CLASS(af_cjk_script_class,
AF_SCRIPT_CJK,
af_cjk_uniranges,
@@ -1505,7 +1504,7 @@
(AF_Script_InitHintsFunc) NULL,
(AF_Script_ApplyHintsFunc) NULL
- };
+ )
#endif /* !AF_CONFIG_OPTION_CJK */
diff --git a/src/3rdparty/freetype/src/autofit/afcjk.h b/src/3rdparty/freetype/src/autofit/afcjk.h
index 9f77fda143..0b20d4ae35 100644
--- a/src/3rdparty/freetype/src/autofit/afcjk.h
+++ b/src/3rdparty/freetype/src/autofit/afcjk.h
@@ -27,8 +27,7 @@ FT_BEGIN_HEADER
/* the CJK-specific script class */
- FT_CALLBACK_TABLE const AF_ScriptClassRec
- af_cjk_script_class;
+ AF_DECLARE_SCRIPT_CLASS(af_cjk_script_class)
FT_LOCAL( FT_Error )
diff --git a/src/3rdparty/freetype/src/autofit/afdummy.c b/src/3rdparty/freetype/src/autofit/afdummy.c
index ed96e96410..42b2fcb216 100644
--- a/src/3rdparty/freetype/src/autofit/afdummy.c
+++ b/src/3rdparty/freetype/src/autofit/afdummy.c
@@ -42,9 +42,7 @@
}
- FT_CALLBACK_TABLE_DEF const AF_ScriptClassRec
- af_dummy_script_class =
- {
+ AF_DEFINE_SCRIPT_CLASS(af_dummy_script_class,
AF_SCRIPT_NONE,
NULL,
@@ -56,7 +54,7 @@
(AF_Script_InitHintsFunc) af_dummy_hints_init,
(AF_Script_ApplyHintsFunc) af_dummy_hints_apply
- };
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/autofit/afdummy.h b/src/3rdparty/freetype/src/autofit/afdummy.h
index 2a5faf8f85..b69ef437fe 100644
--- a/src/3rdparty/freetype/src/autofit/afdummy.h
+++ b/src/3rdparty/freetype/src/autofit/afdummy.h
@@ -29,8 +29,7 @@ FT_BEGIN_HEADER
* be performed. This is the default for non-latin glyphs!
*/
- FT_CALLBACK_TABLE const AF_ScriptClassRec
- af_dummy_script_class;
+ AF_DECLARE_SCRIPT_CLASS(af_dummy_script_class)
/* */
diff --git a/src/3rdparty/freetype/src/autofit/afglobal.c b/src/3rdparty/freetype/src/autofit/afglobal.c
index bfb9091bfd..ac293619d3 100644
--- a/src/3rdparty/freetype/src/autofit/afglobal.c
+++ b/src/3rdparty/freetype/src/autofit/afglobal.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter routines to compute global hinting values (body). */
/* */
-/* Copyright 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -21,6 +21,7 @@
#include "aflatin.h"
#include "afcjk.h"
#include "afindic.h"
+#include "afpic.h"
#include "aferrors.h"
@@ -28,6 +29,11 @@
#include "aflatin2.h"
#endif
+#ifndef FT_CONFIG_OPTION_PIC
+
+/* when updating this table, don't forget to update
+ AF_SCRIPT_CLASSES_COUNT and autofit_module_class_pic_init */
+
/* populate this list when you add new scripts */
static AF_ScriptClass const af_script_classes[] =
{
@@ -41,10 +47,14 @@
NULL /* do not remove */
};
+#endif /* FT_CONFIG_OPTION_PIC */
+
/* index of default script in `af_script_classes' */
#define AF_SCRIPT_LIST_DEFAULT 2
- /* indicates an uncovered glyph */
-#define AF_SCRIPT_LIST_NONE 255
+ /* a bit mask indicating an uncovered glyph */
+#define AF_SCRIPT_LIST_NONE 0x7F
+ /* if this flag is set, we have an ASCII digit */
+#define AF_DIGIT 0x80
/*
@@ -55,7 +65,7 @@
typedef struct AF_FaceGlobalsRec_
{
FT_Face face;
- FT_UInt glyph_count; /* same as face->num_glyphs */
+ FT_Long glyph_count; /* same as face->num_glyphs */
FT_Byte* glyph_scripts;
AF_ScriptMetrics metrics[AF_SCRIPT_MAX];
@@ -72,7 +82,7 @@
FT_Face face = globals->face;
FT_CharMap old_charmap = face->charmap;
FT_Byte* gscripts = globals->glyph_scripts;
- FT_UInt ss;
+ FT_UInt ss, i;
/* the value 255 means `uncovered glyph' */
@@ -92,9 +102,9 @@
}
/* scan each script in a Unicode charmap */
- for ( ss = 0; af_script_classes[ss]; ss++ )
+ for ( ss = 0; AF_SCRIPT_CLASSES_GET[ss]; ss++ )
{
- AF_ScriptClass clazz = af_script_classes[ss];
+ AF_ScriptClass clazz = AF_SCRIPT_CLASSES_GET[ss];
AF_Script_UniRange range;
@@ -114,7 +124,7 @@
gindex = FT_Get_Char_Index( face, charcode );
if ( gindex != 0 &&
- gindex < globals->glyph_count &&
+ gindex < (FT_ULong)globals->glyph_count &&
gscripts[gindex] == AF_SCRIPT_LIST_NONE )
{
gscripts[gindex] = (FT_Byte)ss;
@@ -127,7 +137,7 @@
if ( gindex == 0 || charcode > range->last )
break;
- if ( gindex < globals->glyph_count &&
+ if ( gindex < (FT_ULong)globals->glyph_count &&
gscripts[gindex] == AF_SCRIPT_LIST_NONE )
{
gscripts[gindex] = (FT_Byte)ss;
@@ -136,13 +146,23 @@
}
}
+ /* mark ASCII digits */
+ for ( i = 0x30; i <= 0x39; i++ )
+ {
+ FT_UInt gindex = FT_Get_Char_Index( face, i );
+
+
+ if ( gindex != 0 && gindex < (FT_ULong)globals->glyph_count )
+ gscripts[gindex] |= AF_DIGIT;
+ }
+
Exit:
/*
* By default, all uncovered glyphs are set to the latin script.
* XXX: Shouldn't we disable hinting or do something similar?
*/
{
- FT_UInt nn;
+ FT_Long nn;
for ( nn = 0; nn < globals->glyph_count; nn++ )
@@ -201,7 +221,7 @@
{
if ( globals->metrics[nn] )
{
- AF_ScriptClass clazz = af_script_classes[nn];
+ AF_ScriptClass clazz = AF_SCRIPT_CLASSES_GET[nn];
FT_ASSERT( globals->metrics[nn]->clazz == clazz );
@@ -232,12 +252,12 @@
FT_UInt gidx;
AF_ScriptClass clazz;
FT_UInt script = options & 15;
- const FT_UInt script_max = sizeof ( af_script_classes ) /
- sizeof ( af_script_classes[0] );
+ const FT_Offset script_max = sizeof ( AF_SCRIPT_CLASSES_GET ) /
+ sizeof ( AF_SCRIPT_CLASSES_GET[0] );
FT_Error error = AF_Err_Ok;
- if ( gindex >= globals->glyph_count )
+ if ( gindex >= (FT_ULong)globals->glyph_count )
{
error = AF_Err_Invalid_Argument;
goto Exit;
@@ -245,9 +265,9 @@
gidx = script;
if ( gidx == 0 || gidx + 1 >= script_max )
- gidx = globals->glyph_scripts[gindex];
+ gidx = globals->glyph_scripts[gindex] & AF_SCRIPT_LIST_NONE;
- clazz = af_script_classes[gidx];
+ clazz = AF_SCRIPT_CLASSES_GET[gidx];
if ( script == 0 )
script = clazz->script;
@@ -286,4 +306,15 @@
}
+ FT_LOCAL_DEF( FT_Bool )
+ af_face_globals_is_digit( AF_FaceGlobals globals,
+ FT_UInt gindex )
+ {
+ if ( gindex < (FT_ULong)globals->glyph_count )
+ return (FT_Bool)( globals->glyph_scripts[gindex] & AF_DIGIT );
+
+ return (FT_Bool)0;
+ }
+
+
/* END */
diff --git a/src/3rdparty/freetype/src/autofit/afglobal.h b/src/3rdparty/freetype/src/autofit/afglobal.h
index cf52c08756..2a68e19607 100644
--- a/src/3rdparty/freetype/src/autofit/afglobal.h
+++ b/src/3rdparty/freetype/src/autofit/afglobal.h
@@ -5,7 +5,7 @@
/* Auto-fitter routines to compute global hinting values */
/* (specification). */
/* */
-/* Copyright 2003, 2004, 2005, 2007 by */
+/* Copyright 2003, 2004, 2005, 2007, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -56,7 +56,11 @@ FT_BEGIN_HEADER
FT_LOCAL( void )
af_face_globals_free( AF_FaceGlobals globals );
- /* */
+ FT_LOCAL_DEF( FT_Bool )
+ af_face_globals_is_digit( AF_FaceGlobals globals,
+ FT_UInt gindex );
+
+ /* */
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/autofit/afhints.c b/src/3rdparty/freetype/src/autofit/afhints.c
index 8ab1761488..fe38fba995 100644
--- a/src/3rdparty/freetype/src/autofit/afhints.c
+++ b/src/3rdparty/freetype/src/autofit/afhints.c
@@ -34,7 +34,7 @@
{
FT_Int old_max = axis->max_segments;
FT_Int new_max = old_max;
- FT_Int big_max = FT_INT_MAX / sizeof ( *segment );
+ FT_Int big_max = (FT_Int)( FT_INT_MAX / sizeof ( *segment ) );
if ( old_max >= big_max )
@@ -77,7 +77,7 @@
{
FT_Int old_max = axis->max_edges;
FT_Int new_max = old_max;
- FT_Int big_max = FT_INT_MAX / sizeof ( *edge );
+ FT_Int big_max = (FT_Int)( FT_INT_MAX / sizeof ( *edge ) );
if ( old_max >= big_max )
@@ -645,6 +645,7 @@
FT_Int contour_index = 0;
+ FT_UNUSED( first );
for ( point = points; point < point_limit; point++, vec++, tag++ )
{
point->fx = (FT_Short)vec->x;
@@ -940,8 +941,8 @@
}
{
- FT_UInt min, max, mid;
- FT_Pos fpos;
+ FT_PtrDist min, max, mid;
+ FT_Pos fpos;
/* find enclosing edges */
@@ -952,7 +953,7 @@
/* for small edge counts, a linear search is better */
if ( max <= 8 )
{
- FT_UInt nn;
+ FT_PtrDist nn;
for ( nn = 0; nn < max; nn++ )
if ( edges[nn].fpos >= u )
diff --git a/src/3rdparty/freetype/src/autofit/afindic.c b/src/3rdparty/freetype/src/autofit/afindic.c
index 3d27f521b6..1d9e9eafba 100644
--- a/src/3rdparty/freetype/src/autofit/afindic.c
+++ b/src/3rdparty/freetype/src/autofit/afindic.c
@@ -81,16 +81,14 @@
static const AF_Script_UniRangeRec af_indic_uniranges[] =
{
#if 0
- { 0x0100, 0xFFFF }, /* why this? */
+ AF_UNIRANGE_REC( 0x0100UL, 0xFFFFUL ), /* why this? */
#endif
- { 0x0900, 0x0DFF}, /* Indic Range */
- { 0, 0 }
+ AF_UNIRANGE_REC( 0x0900UL, 0x0DFFUL), /* Indic Range */
+ AF_UNIRANGE_REC( 0UL, 0UL)
};
- FT_CALLBACK_TABLE_DEF const AF_ScriptClassRec
- af_indic_script_class =
- {
+ AF_DEFINE_SCRIPT_CLASS(af_indic_script_class,
AF_SCRIPT_INDIC,
af_indic_uniranges,
@@ -102,7 +100,7 @@
(AF_Script_InitHintsFunc) af_indic_hints_init,
(AF_Script_ApplyHintsFunc) af_indic_hints_apply
- };
+ )
#else /* !AF_CONFIG_OPTION_INDIC */
@@ -112,9 +110,7 @@
};
- FT_CALLBACK_TABLE_DEF const AF_ScriptClassRec
- af_indic_script_class =
- {
+ AF_DEFINE_SCRIPT_CLASS(af_indic_script_class,
AF_SCRIPT_INDIC,
af_indic_uniranges,
@@ -126,7 +122,7 @@
(AF_Script_InitHintsFunc) NULL,
(AF_Script_ApplyHintsFunc) NULL
- };
+ )
#endif /* !AF_CONFIG_OPTION_INDIC */
diff --git a/src/3rdparty/freetype/src/autofit/afindic.h b/src/3rdparty/freetype/src/autofit/afindic.h
index b242b26144..662a982200 100644
--- a/src/3rdparty/freetype/src/autofit/afindic.h
+++ b/src/3rdparty/freetype/src/autofit/afindic.h
@@ -27,8 +27,7 @@ FT_BEGIN_HEADER
/* the Indic-specific script class */
- FT_CALLBACK_TABLE const AF_ScriptClassRec
- af_indic_script_class;
+ AF_DECLARE_SCRIPT_CLASS(af_indic_script_class)
/* */
diff --git a/src/3rdparty/freetype/src/autofit/aflatin.c b/src/3rdparty/freetype/src/autofit/aflatin.c
index ba59e5b38c..e6882d5e7b 100644
--- a/src/3rdparty/freetype/src/autofit/aflatin.c
+++ b/src/3rdparty/freetype/src/autofit/aflatin.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines for latin script (body). */
/* */
-/* Copyright 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -16,6 +16,9 @@
/***************************************************************************/
+#include <ft2build.h>
+#include FT_ADVANCES_H
+
#include "aflatin.h"
#include "aferrors.h"
@@ -146,7 +149,8 @@
#define AF_LATIN_MAX_TEST_CHARACTERS 12
- static const char* const af_latin_blue_chars[AF_LATIN_MAX_BLUES] =
+ static const char af_latin_blue_chars[AF_LATIN_MAX_BLUES]
+ [AF_LATIN_MAX_TEST_CHARACTERS + 1] =
{
"THEZOCQS",
"HEZLOCUS",
@@ -195,7 +199,8 @@
for ( ; p < limit && *p; p++ )
{
FT_UInt glyph_index;
- FT_Int best_point, best_y, best_first, best_last;
+ FT_Pos best_y; /* same as points.y */
+ FT_Int best_point, best_first, best_last;
FT_Vector* points;
FT_Bool round = 0;
@@ -328,7 +333,7 @@
* we couldn't find a single glyph to compute this blue zone,
* we will simply ignore it then
*/
- AF_LOG(( "empty!\n" ));
+ AF_LOG(( "empty\n" ));
continue;
}
@@ -379,7 +384,7 @@
blue->flags |= AF_LATIN_BLUE_TOP;
/*
- * The following flags is used later to adjust the y and x scales
+ * The following flag is used later to adjust the y and x scales
* in order to optimize the pixel grid alignment of the top of small
* letters.
*/
@@ -393,6 +398,52 @@
}
+ FT_LOCAL_DEF( void )
+ af_latin_metrics_check_digits( AF_LatinMetrics metrics,
+ FT_Face face )
+ {
+ FT_UInt i;
+ FT_Bool started = 0, same_width = 1;
+ FT_Fixed advance, old_advance = 0;
+
+
+ /* check whether all ASCII digits have the same advance width; */
+ /* digit `0' is 0x30 in all supported charmaps */
+ for ( i = 0x30; i <= 0x39; i++ )
+ {
+ FT_UInt glyph_index;
+
+
+ glyph_index = FT_Get_Char_Index( face, i );
+ if ( glyph_index == 0 )
+ continue;
+
+ if ( FT_Get_Advance( face, glyph_index,
+ FT_LOAD_NO_SCALE |
+ FT_LOAD_NO_HINTING |
+ FT_LOAD_IGNORE_TRANSFORM,
+ &advance ) )
+ continue;
+
+ if ( started )
+ {
+ if ( advance != old_advance )
+ {
+ same_width = 0;
+ break;
+ }
+ }
+ else
+ {
+ old_advance = advance;
+ started = 1;
+ }
+ }
+
+ metrics->root.digits_have_same_width = same_width;
+ }
+
+
FT_LOCAL_DEF( FT_Error )
af_latin_metrics_init( AF_LatinMetrics metrics,
FT_Face face )
@@ -426,6 +477,7 @@
/* For now, compute the standard width and height from the `o'. */
af_latin_metrics_init_widths( metrics, face, 'o' );
af_latin_metrics_init_blues( metrics, face );
+ af_latin_metrics_check_digits( metrics, face );
}
FT_Set_Charmap( face, oldmap );
@@ -1567,7 +1619,7 @@
/* not hinted, appear a lot bolder or thinner than the */
/* vertical stems. */
- FT_Int delta;
+ FT_Pos delta;
dist = ( dist + 22 ) & ~63;
@@ -1651,7 +1703,7 @@
AF_AxisHints axis = &hints->axis[dim];
AF_Edge edges = axis->edges;
AF_Edge edge_limit = edges + axis->num_edges;
- FT_Int n_edges;
+ FT_PtrDist n_edges;
AF_Edge edge;
AF_Edge anchor = 0;
FT_Int has_serifs = 0;
@@ -2127,39 +2179,37 @@
static const AF_Script_UniRangeRec af_latin_uniranges[] =
{
- { 0x0020 , 0x007F }, /* Basic Latin (no control chars) */
- { 0x00A0 , 0x00FF }, /* Latin-1 Supplement (no control chars) */
- { 0x0100 , 0x017F }, /* Latin Extended-A */
- { 0x0180 , 0x024F }, /* Latin Extended-B */
- { 0x0250 , 0x02AF }, /* IPA Extensions */
- { 0x02B0 , 0x02FF }, /* Spacing Modifier Letters */
- { 0x0300 , 0x036F }, /* Combining Diacritical Marks */
- { 0x0370 , 0x03FF }, /* Greek and Coptic */
- { 0x0400 , 0x04FF }, /* Cyrillic */
- { 0x0500 , 0x052F }, /* Cyrillic Supplement */
- { 0x1D00 , 0x1D7F }, /* Phonetic Extensions */
- { 0x1D80 , 0x1DBF }, /* Phonetic Extensions Supplement */
- { 0x1DC0 , 0x1DFF }, /* Combining Diacritical Marks Supplement */
- { 0x1E00 , 0x1EFF }, /* Latin Extended Additional */
- { 0x1F00 , 0x1FFF }, /* Greek Extended */
- { 0x2000 , 0x206F }, /* General Punctuation */
- { 0x2070 , 0x209F }, /* Superscripts and Subscripts */
- { 0x20A0 , 0x20CF }, /* Currency Symbols */
- { 0x2150 , 0x218F }, /* Number Forms */
- { 0x2460 , 0x24FF }, /* Enclosed Alphanumerics */
- { 0x2C60 , 0x2C7F }, /* Latin Extended-C */
- { 0x2DE0 , 0x2DFF }, /* Cyrillic Extended-A */
- { 0xA640U , 0xA69FU }, /* Cyrillic Extended-B */
- { 0xA720U , 0xA7FFU }, /* Latin Extended-D */
- { 0xFB00U , 0xFB06U }, /* Alphab. Present. Forms (Latin Ligs) */
- { 0x1D400UL, 0x1D7FFUL }, /* Mathematical Alphanumeric Symbols */
- { 0 , 0 }
+ AF_UNIRANGE_REC( 0x0020UL, 0x007FUL ), /* Basic Latin (no control chars) */
+ AF_UNIRANGE_REC( 0x00A0UL, 0x00FFUL ), /* Latin-1 Supplement (no control chars) */
+ AF_UNIRANGE_REC( 0x0100UL, 0x017FUL ), /* Latin Extended-A */
+ AF_UNIRANGE_REC( 0x0180UL, 0x024FUL ), /* Latin Extended-B */
+ AF_UNIRANGE_REC( 0x0250UL, 0x02AFUL ), /* IPA Extensions */
+ AF_UNIRANGE_REC( 0x02B0UL, 0x02FFUL ), /* Spacing Modifier Letters */
+ AF_UNIRANGE_REC( 0x0300UL, 0x036FUL ), /* Combining Diacritical Marks */
+ AF_UNIRANGE_REC( 0x0370UL, 0x03FFUL ), /* Greek and Coptic */
+ AF_UNIRANGE_REC( 0x0400UL, 0x04FFUL ), /* Cyrillic */
+ AF_UNIRANGE_REC( 0x0500UL, 0x052FUL ), /* Cyrillic Supplement */
+ AF_UNIRANGE_REC( 0x1D00UL, 0x1D7FUL ), /* Phonetic Extensions */
+ AF_UNIRANGE_REC( 0x1D80UL, 0x1DBFUL ), /* Phonetic Extensions Supplement */
+ AF_UNIRANGE_REC( 0x1DC0UL, 0x1DFFUL ), /* Combining Diacritical Marks Supplement */
+ AF_UNIRANGE_REC( 0x1E00UL, 0x1EFFUL ), /* Latin Extended Additional */
+ AF_UNIRANGE_REC( 0x1F00UL, 0x1FFFUL ), /* Greek Extended */
+ AF_UNIRANGE_REC( 0x2000UL, 0x206FUL ), /* General Punctuation */
+ AF_UNIRANGE_REC( 0x2070UL, 0x209FUL ), /* Superscripts and Subscripts */
+ AF_UNIRANGE_REC( 0x20A0UL, 0x20CFUL ), /* Currency Symbols */
+ AF_UNIRANGE_REC( 0x2150UL, 0x218FUL ), /* Number Forms */
+ AF_UNIRANGE_REC( 0x2460UL, 0x24FFUL ), /* Enclosed Alphanumerics */
+ AF_UNIRANGE_REC( 0x2C60UL, 0x2C7FUL ), /* Latin Extended-C */
+ AF_UNIRANGE_REC( 0x2DE0UL, 0x2DFFUL ), /* Cyrillic Extended-A */
+ AF_UNIRANGE_REC( 0xA640UL, 0xA69FUL ), /* Cyrillic Extended-B */
+ AF_UNIRANGE_REC( 0xA720UL, 0xA7FFUL ), /* Latin Extended-D */
+ AF_UNIRANGE_REC( 0xFB00UL, 0xFB06UL ), /* Alphab. Present. Forms (Latin Ligs) */
+ AF_UNIRANGE_REC( 0x1D400UL, 0x1D7FFUL ), /* Mathematical Alphanumeric Symbols */
+ AF_UNIRANGE_REC( 0UL, 0UL )
};
- FT_CALLBACK_TABLE_DEF const AF_ScriptClassRec
- af_latin_script_class =
- {
+ AF_DEFINE_SCRIPT_CLASS(af_latin_script_class,
AF_SCRIPT_LATIN,
af_latin_uniranges,
@@ -2171,7 +2221,7 @@
(AF_Script_InitHintsFunc) af_latin_hints_init,
(AF_Script_ApplyHintsFunc) af_latin_hints_apply
- };
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/autofit/aflatin.h b/src/3rdparty/freetype/src/autofit/aflatin.h
index 3251d3783f..660b10c83f 100644
--- a/src/3rdparty/freetype/src/autofit/aflatin.h
+++ b/src/3rdparty/freetype/src/autofit/aflatin.h
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines for latin script (specification). */
/* */
-/* Copyright 2003, 2004, 2005, 2006, 2007 by */
+/* Copyright 2003, 2004, 2005, 2006, 2007, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -27,8 +27,7 @@ FT_BEGIN_HEADER
/* the latin-specific script class */
- FT_CALLBACK_TABLE const AF_ScriptClassRec
- af_latin_script_class;
+ AF_DECLARE_SCRIPT_CLASS(af_latin_script_class)
/* constants are given with units_per_em == 2048 in mind */
@@ -138,6 +137,10 @@ FT_BEGIN_HEADER
FT_Face face,
FT_ULong charcode );
+ FT_LOCAL( void )
+ af_latin_metrics_check_digits( AF_LatinMetrics metrics,
+ FT_Face face );
+
/*************************************************************************/
/*************************************************************************/
diff --git a/src/3rdparty/freetype/src/autofit/aflatin2.c b/src/3rdparty/freetype/src/autofit/aflatin2.c
index 14327b172b..5cbeb296b5 100644
--- a/src/3rdparty/freetype/src/autofit/aflatin2.c
+++ b/src/3rdparty/freetype/src/autofit/aflatin2.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter hinting routines for latin script (body). */
/* */
-/* Copyright 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -16,6 +16,8 @@
/***************************************************************************/
+#include FT_ADVANCES_H
+
#include "aflatin.h"
#include "aflatin2.h"
#include "aferrors.h"
@@ -154,7 +156,7 @@
#define AF_LATIN_MAX_TEST_CHARACTERS 12
- static const char* const af_latin2_blue_chars[AF_LATIN_MAX_BLUES] =
+ static const char af_latin2_blue_chars[AF_LATIN_MAX_BLUES][AF_LATIN_MAX_TEST_CHARACTERS+1] =
{
"THEZOCQS",
"HEZLOCUS",
@@ -336,7 +338,7 @@
* we couldn't find a single glyph to compute this blue zone,
* we will simply ignore it then
*/
- AF_LOG(( "empty!\n" ));
+ AF_LOG(( "empty\n" ));
continue;
}
@@ -401,6 +403,52 @@
}
+ FT_LOCAL_DEF( void )
+ af_latin2_metrics_check_digits( AF_LatinMetrics metrics,
+ FT_Face face )
+ {
+ FT_UInt i;
+ FT_Bool started = 0, same_width = 1;
+ FT_Fixed advance, old_advance = 0;
+
+
+ /* check whether all ASCII digits have the same advance width; */
+ /* digit `0' is 0x30 in all supported charmaps */
+ for ( i = 0x30; i <= 0x39; i++ )
+ {
+ FT_UInt glyph_index;
+
+
+ glyph_index = FT_Get_Char_Index( face, i );
+ if ( glyph_index == 0 )
+ continue;
+
+ if ( FT_Get_Advance( face, glyph_index,
+ FT_LOAD_NO_SCALE |
+ FT_LOAD_NO_HINTING |
+ FT_LOAD_IGNORE_TRANSFORM,
+ &advance ) )
+ continue;
+
+ if ( started )
+ {
+ if ( advance != old_advance )
+ {
+ same_width = 0;
+ break;
+ }
+ }
+ else
+ {
+ old_advance = advance;
+ started = 1;
+ }
+ }
+
+ metrics->root.digits_have_same_width = same_width;
+ }
+
+
FT_LOCAL_DEF( FT_Error )
af_latin2_metrics_init( AF_LatinMetrics metrics,
FT_Face face )
@@ -434,6 +482,7 @@
/* For now, compute the standard width and height from the `o'. */
af_latin2_metrics_init_widths( metrics, face, 'o' );
af_latin2_metrics_init_blues( metrics, face );
+ af_latin2_metrics_check_digits( metrics, face );
}
FT_Set_Charmap( face, oldmap );
@@ -1739,7 +1788,6 @@
AF_AxisHints axis = &hints->axis[dim];
AF_Edge edges = axis->edges;
AF_Edge edge_limit = edges + axis->num_edges;
- FT_Int n_edges;
AF_Edge edge;
AF_Edge anchor = 0;
FT_Int has_serifs = 0;
@@ -2050,54 +2098,60 @@
/* We don't handle horizontal edges since we can't easily assure that */
/* the third (lowest) stem aligns with the base line; it might end up */
/* one pixel higher or lower. */
+
#if 0
- n_edges = edge_limit - edges;
- if ( dim == AF_DIMENSION_HORZ && ( n_edges == 6 || n_edges == 12 ) )
{
- AF_Edge edge1, edge2, edge3;
- FT_Pos dist1, dist2, span, delta;
+ FT_Int n_edges = edge_limit - edges;
- if ( n_edges == 6 )
- {
- edge1 = edges;
- edge2 = edges + 2;
- edge3 = edges + 4;
- }
- else
+ if ( dim == AF_DIMENSION_HORZ && ( n_edges == 6 || n_edges == 12 ) )
{
- edge1 = edges + 1;
- edge2 = edges + 5;
- edge3 = edges + 9;
- }
+ AF_Edge edge1, edge2, edge3;
+ FT_Pos dist1, dist2, span, delta;
- dist1 = edge2->opos - edge1->opos;
- dist2 = edge3->opos - edge2->opos;
- span = dist1 - dist2;
- if ( span < 0 )
- span = -span;
+ if ( n_edges == 6 )
+ {
+ edge1 = edges;
+ edge2 = edges + 2;
+ edge3 = edges + 4;
+ }
+ else
+ {
+ edge1 = edges + 1;
+ edge2 = edges + 5;
+ edge3 = edges + 9;
+ }
- if ( span < 8 )
- {
- delta = edge3->pos - ( 2 * edge2->pos - edge1->pos );
- edge3->pos -= delta;
- if ( edge3->link )
- edge3->link->pos -= delta;
+ dist1 = edge2->opos - edge1->opos;
+ dist2 = edge3->opos - edge2->opos;
+
+ span = dist1 - dist2;
+ if ( span < 0 )
+ span = -span;
- /* move the serifs along with the stem */
- if ( n_edges == 12 )
+ if ( span < 8 )
{
- ( edges + 8 )->pos -= delta;
- ( edges + 11 )->pos -= delta;
- }
+ delta = edge3->pos - ( 2 * edge2->pos - edge1->pos );
+ edge3->pos -= delta;
+ if ( edge3->link )
+ edge3->link->pos -= delta;
- edge3->flags |= AF_EDGE_DONE;
- if ( edge3->link )
- edge3->link->flags |= AF_EDGE_DONE;
+ /* move the serifs along with the stem */
+ if ( n_edges == 12 )
+ {
+ ( edges + 8 )->pos -= delta;
+ ( edges + 11 )->pos -= delta;
+ }
+
+ edge3->flags |= AF_EDGE_DONE;
+ if ( edge3->link )
+ edge3->link->flags |= AF_EDGE_DONE;
+ }
}
}
#endif
+
if ( has_serifs || !anchor )
{
/*
@@ -2266,15 +2320,13 @@
static const AF_Script_UniRangeRec af_latin2_uniranges[] =
{
- { 32, 127 }, /* XXX: TODO: Add new Unicode ranges here! */
- { 160, 255 },
- { 0, 0 }
+ AF_UNIRANGE_REC( 32UL, 127UL ), /* XXX: TODO: Add new Unicode ranges here! */
+ AF_UNIRANGE_REC( 160UL, 255UL ),
+ AF_UNIRANGE_REC( 0UL, 0UL )
};
- FT_CALLBACK_TABLE_DEF const AF_ScriptClassRec
- af_latin2_script_class =
- {
+ AF_DEFINE_SCRIPT_CLASS(af_latin2_script_class,
AF_SCRIPT_LATIN2,
af_latin2_uniranges,
@@ -2286,7 +2338,7 @@
(AF_Script_InitHintsFunc) af_latin2_hints_init,
(AF_Script_ApplyHintsFunc) af_latin2_hints_apply
- };
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/autofit/aflatin2.h b/src/3rdparty/freetype/src/autofit/aflatin2.h
index 34eda05822..925c6214db 100644
--- a/src/3rdparty/freetype/src/autofit/aflatin2.h
+++ b/src/3rdparty/freetype/src/autofit/aflatin2.h
@@ -27,8 +27,7 @@ FT_BEGIN_HEADER
/* the latin-specific script class */
- FT_CALLBACK_TABLE const AF_ScriptClassRec
- af_latin2_script_class;
+ AF_DECLARE_SCRIPT_CLASS(af_latin2_script_class)
/* */
diff --git a/src/3rdparty/freetype/src/autofit/afloader.c b/src/3rdparty/freetype/src/autofit/afloader.c
index 4e48c2fe97..6dd9f2a314 100644
--- a/src/3rdparty/freetype/src/autofit/afloader.c
+++ b/src/3rdparty/freetype/src/autofit/afloader.c
@@ -4,7 +4,7 @@
/* */
/* Auto-fitter glyph loading routines (body). */
/* */
-/* Copyright 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -19,7 +19,6 @@
#include "afloader.h"
#include "afhints.h"
#include "afglobal.h"
-#include "aflatin.h"
#include "aferrors.h"
@@ -184,9 +183,9 @@
if ( axis->num_edges > 1 && AF_HINTS_DO_ADVANCE( hints ) )
{
- old_rsb = loader->pp2.x - edge2->opos;
- old_lsb = edge1->opos;
- new_lsb = edge1->pos;
+ old_rsb = loader->pp2.x - edge2->opos;
+ old_lsb = edge1->opos;
+ new_lsb = edge1->pos;
/* remember unhinted values to later account */
/* for rounding errors */
@@ -217,8 +216,9 @@
}
else
{
- FT_Pos pp1x = loader->pp1.x;
- FT_Pos pp2x = loader->pp2.x;
+ FT_Pos pp1x = loader->pp1.x;
+ FT_Pos pp2x = loader->pp2.x;
+
loader->pp1.x = FT_PIX_ROUND( pp1x );
loader->pp2.x = FT_PIX_ROUND( pp2x );
@@ -229,8 +229,9 @@
}
else
{
- FT_Pos pp1x = loader->pp1.x;
- FT_Pos pp2x = loader->pp2.x;
+ FT_Pos pp1x = loader->pp1.x;
+ FT_Pos pp2x = loader->pp2.x;
+
loader->pp1.x = FT_PIX_ROUND( pp1x + hints->xmin_delta );
loader->pp2.x = FT_PIX_ROUND( pp2x + hints->xmax_delta );
@@ -413,7 +414,8 @@
slot->metrics.vertBearingY = FT_PIX_FLOOR( bbox.yMax + vvector.y );
/* for mono-width fonts (like Andale, Courier, etc.) we need */
- /* to keep the original rounded advance width */
+ /* to keep the original rounded advance width; ditto for */
+ /* digits if all have the same advance width */
#if 0
if ( !FT_IS_FIXED_WIDTH( slot->face ) )
slot->metrics.horiAdvance = loader->pp2.x - loader->pp1.x;
@@ -421,13 +423,9 @@
slot->metrics.horiAdvance = FT_MulFix( slot->metrics.horiAdvance,
x_scale );
#else
- if ( !FT_IS_FIXED_WIDTH( slot->face ) )
- {
- /* non-spacing glyphs must stay as-is */
- if ( slot->metrics.horiAdvance )
- slot->metrics.horiAdvance = loader->pp2.x - loader->pp1.x;
- }
- else
+ if ( FT_IS_FIXED_WIDTH( slot->face ) ||
+ ( af_face_globals_is_digit( loader->globals, glyph_index ) &&
+ metrics->digits_have_same_width ) )
{
slot->metrics.horiAdvance = FT_MulFix( slot->metrics.horiAdvance,
metrics->scaler.x_scale );
@@ -437,6 +435,12 @@
slot->lsb_delta = 0;
slot->rsb_delta = 0;
}
+ else
+ {
+ /* non-spacing glyphs must stay as-is */
+ if ( slot->metrics.horiAdvance )
+ slot->metrics.horiAdvance = loader->pp2.x - loader->pp1.x;
+ }
#endif
slot->metrics.vertAdvance = FT_MulFix( slot->metrics.vertAdvance,
diff --git a/src/3rdparty/freetype/src/autofit/afmodule.c b/src/3rdparty/freetype/src/autofit/afmodule.c
index cd5e1cc218..ec2d707c9f 100644
--- a/src/3rdparty/freetype/src/autofit/afmodule.c
+++ b/src/3rdparty/freetype/src/autofit/afmodule.c
@@ -18,6 +18,7 @@
#include "afmodule.h"
#include "afloader.h"
+#include "afpic.h"
#ifdef AF_DEBUG
int _af_debug;
@@ -66,19 +67,15 @@
}
- FT_CALLBACK_TABLE_DEF
- const FT_AutoHinter_ServiceRec af_autofitter_service =
- {
+ FT_DEFINE_AUTOHINTER_SERVICE(af_autofitter_service,
NULL,
NULL,
NULL,
(FT_AutoHinter_GlyphLoadFunc)af_autofitter_load_glyph
- };
+ )
+ FT_DEFINE_MODULE(autofit_module_class,
- FT_CALLBACK_TABLE_DEF
- const FT_Module_Class autofit_module_class =
- {
FT_MODULE_HINTER,
sizeof ( FT_AutofitterRec ),
@@ -86,12 +83,12 @@
0x10000L, /* version 1.0 of the autofitter */
0x20000L, /* requires FreeType 2.0 or above */
- (const void*)&af_autofitter_service,
+ (const void*)&AF_AF_AUTOFITTER_SERVICE_GET,
(FT_Module_Constructor)af_autofitter_init,
(FT_Module_Destructor) af_autofitter_done,
(FT_Module_Requester) NULL
- };
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/autofit/afmodule.h b/src/3rdparty/freetype/src/autofit/afmodule.h
index 36268a0890..d9792399b6 100644
--- a/src/3rdparty/freetype/src/autofit/afmodule.h
+++ b/src/3rdparty/freetype/src/autofit/afmodule.h
@@ -20,13 +20,13 @@
#define __AFMODULE_H__
#include <ft2build.h>
+#include FT_INTERNAL_OBJECTS_H
#include FT_MODULE_H
FT_BEGIN_HEADER
- FT_CALLBACK_TABLE
- const FT_Module_Class autofit_module_class;
+FT_DECLARE_MODULE(autofit_module_class)
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/autofit/afpic.c b/src/3rdparty/freetype/src/autofit/afpic.c
new file mode 100644
index 0000000000..76822c301a
--- /dev/null
+++ b/src/3rdparty/freetype/src/autofit/afpic.c
@@ -0,0 +1,92 @@
+/***************************************************************************/
+/* */
+/* afpic.c */
+/* */
+/* The FreeType position independent code services for autofit module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#include <ft2build.h>
+#include FT_FREETYPE_H
+#include FT_INTERNAL_OBJECTS_H
+#include "afpic.h"
+
+#ifdef FT_CONFIG_OPTION_PIC
+
+ /* forward declaration of PIC init functions from afmodule.c */
+ void FT_Init_Class_af_autofitter_service( FT_Library, FT_AutoHinter_ServiceRec*);
+
+ /* forward declaration of PIC init functions from script classes */
+#include "aflatin.h"
+#include "aflatin2.h"
+#include "afcjk.h"
+#include "afdummy.h"
+#include "afindic.h"
+
+ void
+ autofit_module_class_pic_free( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+ if ( pic_container->autofit )
+ {
+ FT_FREE( pic_container->autofit );
+ pic_container->autofit = NULL;
+ }
+ }
+
+ FT_Error
+ autofit_module_class_pic_init( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_UInt ss;
+ FT_Error error = FT_Err_Ok;
+ AFModulePIC* container;
+ FT_Memory memory = library->memory;
+
+ /* allocate pointer, clear and set global container pointer */
+ if ( FT_ALLOC ( container, sizeof ( *container ) ) )
+ return error;
+ FT_MEM_SET( container, 0, sizeof(*container) );
+ pic_container->autofit = container;
+
+ /* initialize pointer table - this is how the module usually expects this data */
+ for ( ss = 0 ; ss < AF_SCRIPT_CLASSES_REC_COUNT ; ss++ )
+ {
+ container->af_script_classes[ss] = &container->af_script_classes_rec[ss];
+ }
+ container->af_script_classes[AF_SCRIPT_CLASSES_COUNT-1] = NULL;
+
+ /* add call to initialization function when you add new scripts */
+ ss = 0;
+ FT_Init_Class_af_dummy_script_class(&container->af_script_classes_rec[ss++]);
+#ifdef FT_OPTION_AUTOFIT2
+ FT_Init_Class_af_latin2_script_class(&container->af_script_classes_rec[ss++]);
+#endif
+ FT_Init_Class_af_latin_script_class(&container->af_script_classes_rec[ss++]);
+ FT_Init_Class_af_cjk_script_class(&container->af_script_classes_rec[ss++]);
+ FT_Init_Class_af_indic_script_class(&container->af_script_classes_rec[ss++]);
+
+ FT_Init_Class_af_autofitter_service(library, &container->af_autofitter_service);
+
+/*Exit:*/
+ if(error)
+ autofit_module_class_pic_free(library);
+ return error;
+ }
+
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/autofit/afpic.h b/src/3rdparty/freetype/src/autofit/afpic.h
new file mode 100644
index 0000000000..80e62d39a9
--- /dev/null
+++ b/src/3rdparty/freetype/src/autofit/afpic.h
@@ -0,0 +1,64 @@
+/***************************************************************************/
+/* */
+/* afpic.h */
+/* */
+/* The FreeType position independent code services for autofit module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifndef __AFPIC_H__
+#define __AFPIC_H__
+
+
+FT_BEGIN_HEADER
+
+#include FT_INTERNAL_PIC_H
+
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define AF_SCRIPT_CLASSES_GET af_script_classes
+#define AF_AF_AUTOFITTER_SERVICE_GET af_autofitter_service
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#include "aftypes.h"
+
+/* increase these when you add new scripts, and update autofit_module_class_pic_init */
+#ifdef FT_OPTION_AUTOFIT2
+ #define AF_SCRIPT_CLASSES_COUNT 6
+#else
+ #define AF_SCRIPT_CLASSES_COUNT 5
+#endif
+#define AF_SCRIPT_CLASSES_REC_COUNT (AF_SCRIPT_CLASSES_COUNT-1)
+
+ typedef struct AFModulePIC_
+ {
+ AF_ScriptClass af_script_classes[AF_SCRIPT_CLASSES_COUNT];
+ AF_ScriptClassRec af_script_classes_rec[AF_SCRIPT_CLASSES_REC_COUNT];
+ FT_AutoHinter_ServiceRec af_autofitter_service;
+ } AFModulePIC;
+
+#define GET_PIC(lib) ((AFModulePIC*)((lib)->pic_container.autofit))
+#define AF_SCRIPT_CLASSES_GET (GET_PIC(FT_FACE_LIBRARY(globals->face))->af_script_classes)
+#define AF_AF_AUTOFITTER_SERVICE_GET (GET_PIC(library)->af_autofitter_service)
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /* */
+
+FT_END_HEADER
+
+#endif /* __AFPIC_H__ */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/autofit/aftypes.h b/src/3rdparty/freetype/src/autofit/aftypes.h
index 626a38865e..5574f0c302 100644
--- a/src/3rdparty/freetype/src/autofit/aftypes.h
+++ b/src/3rdparty/freetype/src/autofit/aftypes.h
@@ -285,6 +285,7 @@ extern void* _af_debug_hints;
{
AF_ScriptClass clazz;
AF_ScalerRec scaler;
+ FT_Bool digits_have_same_width;
} AF_ScriptMetricsRec, *AF_ScriptMetrics;
@@ -321,6 +322,8 @@ extern void* _af_debug_hints;
} AF_Script_UniRangeRec;
+#define AF_UNIRANGE_REC( a, b ) { (FT_UInt32)(a), (FT_UInt32)(b) }
+
typedef const AF_Script_UniRangeRec *AF_Script_UniRange;
@@ -329,7 +332,7 @@ extern void* _af_debug_hints;
AF_Script script;
AF_Script_UniRange script_uni_ranges; /* last must be { 0, 0 } */
- FT_UInt script_metrics_size;
+ FT_Offset script_metrics_size;
AF_Script_InitMetricsFunc script_metrics_init;
AF_Script_ScaleMetricsFunc script_metrics_scale;
AF_Script_DoneMetricsFunc script_metrics_done;
@@ -339,6 +342,56 @@ extern void* _af_debug_hints;
} AF_ScriptClassRec;
+/* Declare and define vtables for classes */
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define AF_DECLARE_SCRIPT_CLASS(script_class) \
+ FT_CALLBACK_TABLE const AF_ScriptClassRec \
+ script_class;
+
+#define AF_DEFINE_SCRIPT_CLASS(script_class, script_, ranges, m_size, \
+ m_init, m_scale, m_done, h_init, h_apply) \
+ FT_CALLBACK_TABLE_DEF const AF_ScriptClassRec \
+ script_class = \
+ { \
+ script_, \
+ ranges, \
+ \
+ m_size, \
+ \
+ m_init, \
+ m_scale, \
+ m_done, \
+ \
+ h_init, \
+ h_apply \
+ };
+
+#else
+
+#define AF_DECLARE_SCRIPT_CLASS(script_class) \
+ FT_LOCAL(void) \
+ FT_Init_Class_##script_class(AF_ScriptClassRec* ac);
+
+#define AF_DEFINE_SCRIPT_CLASS(script_class, script_, ranges, m_size, \
+ m_init, m_scale, m_done, h_init, h_apply) \
+ FT_LOCAL_DEF(void) \
+ FT_Init_Class_##script_class(AF_ScriptClassRec* ac) \
+ { \
+ ac->script = script_; \
+ ac->script_uni_ranges = ranges; \
+ \
+ ac->script_metrics_size = m_size; \
+ \
+ ac->script_metrics_init = m_init; \
+ ac->script_metrics_scale = m_scale; \
+ ac->script_metrics_done = m_done; \
+ \
+ ac->script_hints_init = h_init; \
+ ac->script_hints_apply = h_apply; \
+ }
+#endif
+
/* */
diff --git a/src/3rdparty/freetype/src/autofit/autofit.c b/src/3rdparty/freetype/src/autofit/autofit.c
index 2fe66a990e..83b613e79b 100644
--- a/src/3rdparty/freetype/src/autofit/autofit.c
+++ b/src/3rdparty/freetype/src/autofit/autofit.c
@@ -18,6 +18,7 @@
#define FT_MAKE_OPTION_SINGLE_OBJECT
#include <ft2build.h>
+#include "afpic.c"
#include "afangles.c"
#include "afglobal.c"
#include "afhints.c"
diff --git a/src/3rdparty/freetype/src/base/Jamfile b/src/3rdparty/freetype/src/base/Jamfile
index aba60fbe0c..832e8b8424 100644
--- a/src/3rdparty/freetype/src/base/Jamfile
+++ b/src/3rdparty/freetype/src/base/Jamfile
@@ -18,8 +18,9 @@ SubDir FT2_TOP $(FT2_SRC_DIR) base ;
if $(FT2_MULTI)
{
_sources = ftadvanc ftcalc ftdbgmem ftgloadr
- ftnames ftobjs ftoutln ftrfork
+ ftobjs ftoutln ftrfork ftsnames
ftstream fttrigon ftutil
+ basepic ftpic
;
}
else
diff --git a/src/3rdparty/freetype/src/base/basepic.c b/src/3rdparty/freetype/src/base/basepic.c
new file mode 100644
index 0000000000..c0bccb6959
--- /dev/null
+++ b/src/3rdparty/freetype/src/base/basepic.c
@@ -0,0 +1,83 @@
+/***************************************************************************/
+/* */
+/* basepic.c */
+/* */
+/* The FreeType position independent code services for base. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#include <ft2build.h>
+#include FT_FREETYPE_H
+#include FT_INTERNAL_OBJECTS_H
+#include "basepic.h"
+
+#ifdef FT_CONFIG_OPTION_PIC
+
+ /* forward declaration of PIC init functions from ftglyph.c */
+ void FT_Init_Class_ft_outline_glyph_class(FT_Glyph_Class*);
+ void FT_Init_Class_ft_bitmap_glyph_class(FT_Glyph_Class*);
+
+ /* forward declaration of PIC init functions from ftinit.c */
+ FT_Error ft_create_default_module_classes(FT_Library);
+ void ft_destroy_default_module_classes(FT_Library);
+
+ void
+ ft_base_pic_free( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+ if ( pic_container->base )
+ {
+ /* Destroy default module classes (in case FT_Add_Default_Modules was used) */
+ ft_destroy_default_module_classes( library );
+
+ FT_FREE( pic_container->base );
+ pic_container->base = NULL;
+ }
+ }
+
+
+ FT_Error
+ ft_base_pic_init( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Error error = FT_Err_Ok;
+ BasePIC* container;
+ FT_Memory memory = library->memory;
+
+ /* allocate pointer, clear and set global container pointer */
+ if ( FT_ALLOC ( container, sizeof ( *container ) ) )
+ return error;
+ FT_MEM_SET( container, 0, sizeof(*container) );
+ pic_container->base = container;
+
+ /* initialize default modules list and pointers */
+ error = ft_create_default_module_classes( library );
+ if ( error )
+ goto Exit;
+
+ /* initialize pointer table - this is how the module usually expects this data */
+ FT_Init_Class_ft_outline_glyph_class(&container->ft_outline_glyph_class);
+ FT_Init_Class_ft_bitmap_glyph_class(&container->ft_bitmap_glyph_class);
+
+Exit:
+ if(error)
+ ft_base_pic_free(library);
+ return error;
+ }
+
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/base/basepic.h b/src/3rdparty/freetype/src/base/basepic.h
new file mode 100644
index 0000000000..bb17745769
--- /dev/null
+++ b/src/3rdparty/freetype/src/base/basepic.h
@@ -0,0 +1,62 @@
+/***************************************************************************/
+/* */
+/* basepic.h */
+/* */
+/* The FreeType position independent code services for base. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifndef __BASEPIC_H__
+#define __BASEPIC_H__
+
+
+FT_BEGIN_HEADER
+
+#include FT_INTERNAL_PIC_H
+
+#ifndef FT_CONFIG_OPTION_PIC
+#define FT_OUTLINE_GLYPH_CLASS_GET &ft_outline_glyph_class
+#define FT_BITMAP_GLYPH_CLASS_GET &ft_bitmap_glyph_class
+#define FT_DEFAULT_MODULES_GET ft_default_modules
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#include FT_GLYPH_H
+
+ typedef struct BasePIC_
+ {
+ FT_Module_Class** default_module_classes;
+ FT_Glyph_Class ft_outline_glyph_class;
+ FT_Glyph_Class ft_bitmap_glyph_class;
+ } BasePIC;
+
+#define GET_PIC(lib) ((BasePIC*)((lib)->pic_container.base))
+#define FT_OUTLINE_GLYPH_CLASS_GET (&GET_PIC(library)->ft_outline_glyph_class)
+#define FT_BITMAP_GLYPH_CLASS_GET (&GET_PIC(library)->ft_bitmap_glyph_class)
+#define FT_DEFAULT_MODULES_GET (GET_PIC(library)->default_module_classes)
+
+ void
+ ft_base_pic_free( FT_Library library );
+
+ FT_Error
+ ft_base_pic_init( FT_Library library );
+
+#endif /* FT_CONFIG_OPTION_PIC */
+ /* */
+
+FT_END_HEADER
+
+#endif /* __BASEPIC_H__ */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/base/ftadvanc.c b/src/3rdparty/freetype/src/base/ftadvanc.c
index 504f9d2309..8ab7fcb927 100644
--- a/src/3rdparty/freetype/src/base/ftadvanc.c
+++ b/src/3rdparty/freetype/src/base/ftadvanc.c
@@ -140,7 +140,7 @@
if ( flags & FT_ADVANCE_FLAG_FAST_ONLY )
return FT_Err_Unimplemented_Feature;
- flags |= FT_LOAD_ADVANCE_ONLY;
+ flags |= (FT_UInt32)FT_LOAD_ADVANCE_ONLY;
for ( nn = 0; nn < count; nn++ )
{
error = FT_Load_Glyph( face, start + nn, flags );
diff --git a/src/3rdparty/freetype/src/base/ftbase.c b/src/3rdparty/freetype/src/base/ftbase.c
index d1fe6e6088..6a27ea95a6 100644
--- a/src/3rdparty/freetype/src/base/ftbase.c
+++ b/src/3rdparty/freetype/src/base/ftbase.c
@@ -4,7 +4,7 @@
/* */
/* Single object library component (body only). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -20,14 +20,16 @@
#define FT_MAKE_OPTION_SINGLE_OBJECT
+#include "ftpic.c"
+#include "basepic.c"
#include "ftadvanc.c"
#include "ftcalc.c"
#include "ftdbgmem.c"
#include "ftgloadr.c"
-#include "ftnames.c"
#include "ftobjs.c"
#include "ftoutln.c"
#include "ftrfork.c"
+#include "ftsnames.c"
#include "ftstream.c"
#include "fttrigon.c"
#include "ftutil.c"
diff --git a/src/3rdparty/freetype/src/base/ftbase.h b/src/3rdparty/freetype/src/base/ftbase.h
index 9cae85da9e..1dc49f3bdf 100644
--- a/src/3rdparty/freetype/src/base/ftbase.h
+++ b/src/3rdparty/freetype/src/base/ftbase.h
@@ -4,7 +4,7 @@
/* */
/* The FreeType private functions used in base module (specification). */
/* */
-/* Copyright 2008 by */
+/* Copyright 2008, 2010 by */
/* David Turner, Robert Wilhelm, Werner Lemberg, and suzuki toshiya. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -29,7 +29,7 @@ FT_BEGIN_HEADER
/* Assume the stream is sfnt-wrapped PS Type1 or sfnt-wrapped CID-keyed */
/* font, and try to load a face specified by the face_index. */
- FT_LOCAL_DEF( FT_Error )
+ FT_LOCAL( FT_Error )
open_face_PS_from_sfnt_stream( FT_Library library,
FT_Stream stream,
FT_Long face_index,
@@ -40,7 +40,7 @@ FT_BEGIN_HEADER
/* Create a new FT_Face given a buffer and a driver name. */
/* From ftmac.c. */
- FT_LOCAL_DEF( FT_Error )
+ FT_LOCAL( FT_Error )
open_face_from_buffer( FT_Library library,
FT_Byte* base,
FT_ULong size,
diff --git a/src/3rdparty/freetype/src/base/ftbbox.c b/src/3rdparty/freetype/src/base/ftbbox.c
index 532ab13579..4b8e9112fe 100644
--- a/src/3rdparty/freetype/src/base/ftbbox.c
+++ b/src/3rdparty/freetype/src/base/ftbbox.c
@@ -4,7 +4,7 @@
/* */
/* FreeType bbox computation (body). */
/* */
-/* Copyright 1996-2001, 2002, 2004, 2006 by */
+/* Copyright 1996-2001, 2002, 2004, 2006, 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used */
@@ -29,6 +29,7 @@
#include FT_IMAGE_H
#include FT_OUTLINE_H
#include FT_INTERNAL_CALC_H
+#include FT_INTERNAL_OBJECTS_H
typedef struct TBBox_Rec_
@@ -139,7 +140,7 @@
/* */
/* <Description> */
/* This function is used as a `conic_to' emitter during */
- /* FT_Raster_Decompose(). It checks a conic Bezier curve with the */
+ /* FT_Outline_Decompose(). It checks a conic Bezier curve with the */
/* current bounding box, and computes its extrema if necessary to */
/* update it. */
/* */
@@ -506,7 +507,7 @@
/* */
/* <Description> */
/* This function is used as a `cubic_to' emitter during */
- /* FT_Raster_Decompose(). It checks a cubic Bezier curve with the */
+ /* FT_Outline_Decompose(). It checks a cubic Bezier curve with the */
/* current bounding box, and computes its extrema if necessary to */
/* update it. */
/* */
@@ -559,6 +560,13 @@
return 0;
}
+FT_DEFINE_OUTLINE_FUNCS(bbox_interface,
+ (FT_Outline_MoveTo_Func) BBox_Move_To,
+ (FT_Outline_LineTo_Func) BBox_Move_To,
+ (FT_Outline_ConicTo_Func)BBox_Conic_To,
+ (FT_Outline_CubicTo_Func)BBox_Cubic_To,
+ 0, 0
+ )
/* documentation is in ftbbox.h */
@@ -628,18 +636,13 @@
/* the two boxes are different, now walk over the outline to */
/* get the Bezier arc extrema. */
- static const FT_Outline_Funcs bbox_interface =
- {
- (FT_Outline_MoveTo_Func) BBox_Move_To,
- (FT_Outline_LineTo_Func) BBox_Move_To,
- (FT_Outline_ConicTo_Func)BBox_Conic_To,
- (FT_Outline_CubicTo_Func)BBox_Cubic_To,
- 0, 0
- };
-
FT_Error error;
TBBox_Rec user;
+#ifdef FT_CONFIG_OPTION_PIC
+ FT_Outline_Funcs bbox_interface;
+ Init_Class_bbox_interface(&bbox_interface);
+#endif
user.bbox = bbox;
diff --git a/src/3rdparty/freetype/src/base/ftbitmap.c b/src/3rdparty/freetype/src/base/ftbitmap.c
index 8810cfadf3..46fcce6136 100644
--- a/src/3rdparty/freetype/src/base/ftbitmap.c
+++ b/src/3rdparty/freetype/src/base/ftbitmap.c
@@ -228,8 +228,12 @@
if ( !bitmap || !bitmap->buffer )
return FT_Err_Invalid_Argument;
- xstr = FT_PIX_ROUND( xStrength ) >> 6;
- ystr = FT_PIX_ROUND( yStrength ) >> 6;
+ if ( ( ( FT_PIX_ROUND( xStrength ) >> 6 ) > FT_INT_MAX ) ||
+ ( ( FT_PIX_ROUND( yStrength ) >> 6 ) > FT_INT_MAX ) )
+ return FT_Err_Invalid_Argument;
+
+ xstr = (FT_Int)FT_PIX_ROUND( xStrength ) >> 6;
+ ystr = (FT_Int)FT_PIX_ROUND( yStrength ) >> 6;
if ( xstr == 0 && ystr == 0 )
return FT_Err_Ok;
diff --git a/src/3rdparty/freetype/src/base/ftcalc.c b/src/3rdparty/freetype/src/base/ftcalc.c
index 04295a6931..3892fabfe9 100644
--- a/src/3rdparty/freetype/src/base/ftcalc.c
+++ b/src/3rdparty/freetype/src/base/ftcalc.c
@@ -110,12 +110,12 @@
FT_EXPORT_DEF( FT_Int32 )
FT_Sqrt32( FT_Int32 x )
{
- FT_ULong val, root, newroot, mask;
+ FT_UInt32 val, root, newroot, mask;
root = 0;
- mask = 0x40000000L;
- val = (FT_ULong)x;
+ mask = (FT_UInt32)0x40000000UL;
+ val = (FT_UInt32)x;
do
{
@@ -362,6 +362,7 @@
long s;
+ /* XXX: this function does not allow 64-bit arguments */
if ( a == 0 || b == c )
return a;
@@ -377,12 +378,12 @@
FT_Int64 temp, temp2;
- ft_multo64( a, b, &temp );
+ ft_multo64( (FT_Int32)a, (FT_Int32)b, &temp );
temp2.hi = 0;
temp2.lo = (FT_UInt32)(c >> 1);
FT_Add64( &temp, &temp2, &temp );
- a = ft_div64by32( temp.hi, temp.lo, c );
+ a = ft_div64by32( temp.hi, temp.lo, (FT_Int32)c );
}
else
a = 0x7FFFFFFFL;
@@ -416,8 +417,8 @@
FT_Int64 temp;
- ft_multo64( a, b, &temp );
- a = ft_div64by32( temp.hi, temp.lo, c );
+ ft_multo64( (FT_Int32)a, (FT_Int32)b, &temp );
+ a = ft_div64by32( temp.hi, temp.lo, (FT_Int32)c );
}
else
a = 0x7FFFFFFFL;
@@ -539,13 +540,14 @@
FT_UInt32 q;
- s = a; a = FT_ABS( a );
- s ^= b; b = FT_ABS( b );
+ /* XXX: this function does not allow 64-bit arguments */
+ s = (FT_Int32)a; a = FT_ABS( a );
+ s ^= (FT_Int32)b; b = FT_ABS( b );
if ( b == 0 )
{
/* check for division by 0 */
- q = 0x7FFFFFFFL;
+ q = (FT_UInt32)0x7FFFFFFFL;
}
else if ( ( a >> 16 ) == 0 )
{
@@ -562,7 +564,7 @@
temp2.hi = 0;
temp2.lo = (FT_UInt32)( b >> 1 );
FT_Add64( &temp, &temp2, &temp );
- q = ft_div64by32( temp.hi, temp.lo, b );
+ q = ft_div64by32( temp.hi, temp.lo, (FT_Int32)b );
}
return ( s < 0 ? -(FT_Int32)q : (FT_Int32)q );
@@ -840,7 +842,7 @@
FT_Pos out_x,
FT_Pos out_y )
{
- FT_Int result;
+ FT_Long result; /* avoid overflow on 16-bit system */
/* deal with the trivial cases quickly */
@@ -889,8 +891,9 @@
FT_Int64 z1, z2;
- ft_multo64( in_x, out_y, &z1 );
- ft_multo64( in_y, out_x, &z2 );
+ /* XXX: this function does not allow 64-bit arguments */
+ ft_multo64( (FT_Int32)in_x, (FT_Int32)out_y, &z1 );
+ ft_multo64( (FT_Int32)in_y, (FT_Int32)out_x, &z2 );
if ( z1.hi > z2.hi )
result = +1;
@@ -906,7 +909,8 @@
#endif
}
- return result;
+ /* XXX: only the sign of return value, +1/0/-1 must be used */
+ return (FT_Int)result;
}
diff --git a/src/3rdparty/freetype/src/base/ftdbgmem.c b/src/3rdparty/freetype/src/base/ftdbgmem.c
index 8b2a3304f0..160269d192 100644
--- a/src/3rdparty/freetype/src/base/ftdbgmem.c
+++ b/src/3rdparty/freetype/src/base/ftdbgmem.c
@@ -421,7 +421,7 @@
"FreeType: %ld bytes of memory leaked in %ld blocks\n",
leaks, leak_count );
- printf( "FreeType: No memory leaks detected!\n" );
+ printf( "FreeType: no memory leaks detected\n" );
}
}
@@ -989,7 +989,7 @@
#else /* !FT_DEBUG_MEMORY */
/* ANSI C doesn't like empty source files */
- static const FT_Byte _debug_mem_dummy = 0;
+ typedef int _debug_mem_dummy;
#endif /* !FT_DEBUG_MEMORY */
diff --git a/src/3rdparty/freetype/src/base/ftgloadr.c b/src/3rdparty/freetype/src/base/ftgloadr.c
index ab52621ea6..ac0010ddd8 100644
--- a/src/3rdparty/freetype/src/base/ftgloadr.c
+++ b/src/3rdparty/freetype/src/base/ftgloadr.c
@@ -218,6 +218,9 @@
{
new_max = FT_PAD_CEIL( new_max, 8 );
+ if ( new_max > FT_OUTLINE_POINTS_MAX )
+ return FT_Err_Array_Too_Large;
+
if ( FT_RENEW_ARRAY( base->points, old_max, new_max ) ||
FT_RENEW_ARRAY( base->tags, old_max, new_max ) )
goto Exit;
@@ -246,6 +249,10 @@
if ( new_max > old_max )
{
new_max = FT_PAD_CEIL( new_max, 4 );
+
+ if ( new_max > FT_OUTLINE_CONTOURS_MAX )
+ return FT_Err_Array_Too_Large;
+
if ( FT_RENEW_ARRAY( base->contours, old_max, new_max ) )
goto Exit;
diff --git a/src/3rdparty/freetype/src/base/ftglyph.c b/src/3rdparty/freetype/src/base/ftglyph.c
index 4130cb1102..3505d6dde9 100644
--- a/src/3rdparty/freetype/src/base/ftglyph.c
+++ b/src/3rdparty/freetype/src/base/ftglyph.c
@@ -34,6 +34,7 @@
#include FT_BITMAP_H
#include FT_INTERNAL_OBJECTS_H
+#include "basepic.h"
/*************************************************************************/
/* */
@@ -129,9 +130,7 @@
}
- FT_CALLBACK_TABLE_DEF
- const FT_Glyph_Class ft_bitmap_glyph_class =
- {
+ FT_DEFINE_GLYPH(ft_bitmap_glyph_class,
sizeof ( FT_BitmapGlyphRec ),
FT_GLYPH_FORMAT_BITMAP,
@@ -141,7 +140,7 @@
0, /* FT_Glyph_TransformFunc */
ft_bitmap_glyph_bbox,
0 /* FT_Glyph_PrepareFunc */
- };
+ )
/*************************************************************************/
@@ -255,9 +254,7 @@
}
- FT_CALLBACK_TABLE_DEF
- const FT_Glyph_Class ft_outline_glyph_class =
- {
+ FT_DEFINE_GLYPH( ft_outline_glyph_class,
sizeof ( FT_OutlineGlyphRec ),
FT_GLYPH_FORMAT_OUTLINE,
@@ -267,7 +264,7 @@
ft_outline_glyph_transform,
ft_outline_glyph_bbox,
ft_outline_glyph_prepare
- };
+ )
/*************************************************************************/
@@ -373,11 +370,11 @@
/* if it is a bitmap, that's easy :-) */
if ( slot->format == FT_GLYPH_FORMAT_BITMAP )
- clazz = &ft_bitmap_glyph_class;
+ clazz = FT_BITMAP_GLYPH_CLASS_GET;
- /* it it is an outline too */
+ /* if it is an outline */
else if ( slot->format == FT_GLYPH_FORMAT_OUTLINE )
- clazz = &ft_outline_glyph_class;
+ clazz = FT_OUTLINE_GLYPH_CLASS_GET;
else
{
@@ -518,6 +515,10 @@
const FT_Glyph_Class* clazz;
+#ifdef FT_CONFIG_OPTION_PIC
+ FT_Library library = FT_GLYPH( glyph )->library;
+#endif
+
/* check argument */
if ( !the_glyph )
@@ -533,7 +534,7 @@
clazz = glyph->clazz;
/* when called with a bitmap glyph, do nothing and return successfully */
- if ( clazz == &ft_bitmap_glyph_class )
+ if ( clazz == FT_BITMAP_GLYPH_CLASS_GET )
goto Exit;
if ( !clazz || !clazz->glyph_prepare )
@@ -546,7 +547,7 @@
dummy.format = clazz->glyph_format;
/* create result bitmap glyph */
- error = ft_new_glyph( glyph->library, &ft_bitmap_glyph_class,
+ error = ft_new_glyph( glyph->library, FT_BITMAP_GLYPH_CLASS_GET,
(FT_Glyph*)(void*)&bitmap );
if ( error )
goto Exit;
diff --git a/src/3rdparty/freetype/src/base/ftinit.c b/src/3rdparty/freetype/src/base/ftinit.c
index dac30b0d86..f94f25a83c 100644
--- a/src/3rdparty/freetype/src/base/ftinit.c
+++ b/src/3rdparty/freetype/src/base/ftinit.c
@@ -4,7 +4,7 @@
/* */
/* FreeType initialization layer (body). */
/* */
-/* Copyright 1996-2001, 2002, 2005, 2007 by */
+/* Copyright 1996-2001, 2002, 2005, 2007, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -42,6 +42,7 @@
#include FT_INTERNAL_OBJECTS_H
#include FT_INTERNAL_DEBUG_H
#include FT_MODULE_H
+#include "basepic.h"
/*************************************************************************/
@@ -53,6 +54,8 @@
#undef FT_COMPONENT
#define FT_COMPONENT trace_init
+#ifndef FT_CONFIG_OPTION_PIC
+
#undef FT_USE_MODULE
#ifdef __cplusplus
#define FT_USE_MODULE( type, x ) extern "C" const type x;
@@ -74,6 +77,99 @@
0
};
+#else /* FT_CONFIG_OPTION_PIC */
+
+#ifdef __cplusplus
+#define FT_EXTERNC extern "C"
+#else
+#define FT_EXTERNC extern
+#endif
+
+ /* declare the module's class creation/destruction functions */
+#undef FT_USE_MODULE
+#define FT_USE_MODULE( type, x ) \
+ FT_EXTERNC FT_Error FT_Create_Class_##x( FT_Library library, FT_Module_Class** output_class ); \
+ FT_EXTERNC void FT_Destroy_Class_##x( FT_Library library, FT_Module_Class* clazz );
+
+#include FT_CONFIG_MODULES_H
+
+
+ /* count all module classes */
+#undef FT_USE_MODULE
+#define FT_USE_MODULE( type, x ) MODULE_CLASS_##x,
+
+ enum {
+#include FT_CONFIG_MODULES_H
+ FT_NUM_MODULE_CLASSES
+ };
+
+ /* destroy all module classes */
+#undef FT_USE_MODULE
+#define FT_USE_MODULE( type, x ) \
+ if ( classes[i] ) { FT_Destroy_Class_##x(library, classes[i]); } \
+ i++; \
+
+ FT_BASE_DEF( void )
+ ft_destroy_default_module_classes( FT_Library library )
+ {
+ FT_Module_Class** classes;
+ FT_Memory memory;
+ FT_UInt i;
+ BasePIC* pic_container = (BasePIC*)library->pic_container.base;
+
+ if ( !pic_container->default_module_classes )
+ return;
+
+ memory = library->memory;
+ classes = pic_container->default_module_classes;
+ i = 0;
+
+#include FT_CONFIG_MODULES_H
+
+ FT_FREE( classes );
+ pic_container->default_module_classes = 0;
+ }
+
+ /* initialize all module classes and the pointer table */
+#undef FT_USE_MODULE
+#define FT_USE_MODULE( type, x ) \
+ error = FT_Create_Class_##x(library, &clazz); \
+ if (error) goto Exit; \
+ classes[i++] = clazz;
+
+ FT_BASE_DEF( FT_Error )
+ ft_create_default_module_classes( FT_Library library )
+ {
+ FT_Error error;
+ FT_Memory memory;
+ FT_Module_Class** classes;
+ FT_Module_Class* clazz;
+ FT_UInt i;
+ BasePIC* pic_container = (BasePIC*)library->pic_container.base;
+
+ memory = library->memory;
+ pic_container->default_module_classes = 0;
+
+ if ( FT_ALLOC(classes, sizeof(FT_Module_Class*) * (FT_NUM_MODULE_CLASSES + 1) ) )
+ return error;
+ /* initialize all pointers to 0, especially the last one */
+ for (i = 0; i < FT_NUM_MODULE_CLASSES; i++)
+ classes[i] = 0;
+ classes[FT_NUM_MODULE_CLASSES] = 0;
+
+ i = 0;
+
+#include FT_CONFIG_MODULES_H
+
+Exit:
+ if (error) ft_destroy_default_module_classes( library );
+ else pic_container->default_module_classes = classes;
+
+ return error;
+ }
+
+
+#endif /* FT_CONFIG_OPTION_PIC */
/* documentation is in ftmodapi.h */
@@ -86,16 +182,15 @@
/* test for valid `library' delayed to FT_Add_Module() */
- cur = ft_default_modules;
+ cur = FT_DEFAULT_MODULES_GET;
while ( *cur )
{
error = FT_Add_Module( library, *cur );
/* notify errors, but don't stop */
if ( error )
- {
- FT_ERROR(( "FT_Add_Default_Module: Cannot install `%s', error = 0x%x\n",
- (*cur)->module_name, error ));
- }
+ FT_TRACE0(( "FT_Add_Default_Module:"
+ " Cannot install `%s', error = 0x%x\n",
+ (*cur)->module_name, error ));
cur++;
}
}
@@ -127,13 +222,7 @@
if ( error )
FT_Done_Memory( memory );
else
- {
- (*alibrary)->version_major = FREETYPE_MAJOR;
- (*alibrary)->version_minor = FREETYPE_MINOR;
- (*alibrary)->version_patch = FREETYPE_PATCH;
-
FT_Add_Default_Modules( *alibrary );
- }
return error;
}
diff --git a/src/3rdparty/freetype/src/base/ftobjs.c b/src/3rdparty/freetype/src/base/ftobjs.c
index 086237a79d..3403188594 100644
--- a/src/3rdparty/freetype/src/base/ftobjs.c
+++ b/src/3rdparty/freetype/src/base/ftobjs.c
@@ -4,7 +4,8 @@
/* */
/* The FreeType private base classes (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, */
+/* 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -37,7 +38,9 @@
#include FT_SERVICE_KERNING_H
#include FT_SERVICE_TRUETYPE_ENGINE_H
+#ifdef FT_CONFIG_OPTION_MAC_FONTS
#include "ftbase.h"
+#endif
#define GRID_FIT_METRICS
@@ -348,7 +351,7 @@
/* free bitmap buffer if needed */
ft_glyphslot_free_bitmap( slot );
- /* slot->internal might be 0 in out-of-memory situations */
+ /* slot->internal might be NULL in out-of-memory situations */
if ( slot->internal )
{
/* free glyph loader */
@@ -592,27 +595,29 @@
* Determine whether we need to auto-hint or not.
* The general rules are:
*
- * - Do only auto-hinting if we have a hinter module,
- * a scalable font format dealing with outlines,
- * and no transforms except simple slants.
+ * - Do only auto-hinting if we have a hinter module, a scalable font
+ * format dealing with outlines, and no transforms except simple
+ * slants and/or rotations by integer multiples of 90 degrees.
*
- * - Then, autohint if FT_LOAD_FORCE_AUTOHINT is set
- * or if we don't have a native font hinter.
+ * - Then, auto-hint if FT_LOAD_FORCE_AUTOHINT is set or if we don't
+ * have a native font hinter.
*
* - Otherwise, auto-hint for LIGHT hinting mode.
*
- * - Exception: The font is `tricky' and requires
- * the native hinter to load properly.
+ * - Exception: The font is `tricky' and requires the native hinter to
+ * load properly.
*/
- if ( hinter &&
- !( load_flags & FT_LOAD_NO_HINTING ) &&
- !( load_flags & FT_LOAD_NO_AUTOHINT ) &&
- FT_DRIVER_IS_SCALABLE( driver ) &&
- FT_DRIVER_USES_OUTLINES( driver ) &&
- !FT_IS_TRICKY( face ) &&
- face->internal->transform_matrix.yy > 0 &&
- face->internal->transform_matrix.yx == 0 )
+ if ( hinter &&
+ !( load_flags & FT_LOAD_NO_HINTING ) &&
+ !( load_flags & FT_LOAD_NO_AUTOHINT ) &&
+ FT_DRIVER_IS_SCALABLE( driver ) &&
+ FT_DRIVER_USES_OUTLINES( driver ) &&
+ !FT_IS_TRICKY( face ) &&
+ ( ( face->internal->transform_matrix.yx == 0 &&
+ face->internal->transform_matrix.xx != 0 ) ||
+ ( face->internal->transform_matrix.xx == 0 &&
+ face->internal->transform_matrix.yx != 0 ) ) )
{
if ( ( load_flags & FT_LOAD_FORCE_AUTOHINT ) ||
!FT_DRIVER_HAS_HINTER( driver ) )
@@ -706,8 +711,8 @@
}
/* compute the linear advance in 16.16 pixels */
- if ( ( load_flags & FT_LOAD_LINEAR_DESIGN ) == 0 &&
- ( FT_IS_SCALABLE( face ) ) )
+ if ( ( load_flags & FT_LOAD_LINEAR_DESIGN ) == 0 &&
+ ( FT_IS_SCALABLE( face ) ) )
{
FT_Size_Metrics* metrics = &face->size->metrics;
@@ -737,11 +742,30 @@
renderer, slot,
&internal->transform_matrix,
&internal->transform_delta );
+ else if ( slot->format == FT_GLYPH_FORMAT_OUTLINE )
+ {
+ /* apply `standard' transformation if no renderer is available */
+ if ( &internal->transform_matrix )
+ FT_Outline_Transform( &slot->outline,
+ &internal->transform_matrix );
+
+ if ( &internal->transform_delta )
+ FT_Outline_Translate( &slot->outline,
+ internal->transform_delta.x,
+ internal->transform_delta.y );
+ }
+
/* transform advance */
FT_Vector_Transform( &slot->advance, &internal->transform_matrix );
}
}
+ FT_TRACE5(( " x advance: %d\n" , slot->advance.x ));
+ FT_TRACE5(( " y advance: %d\n" , slot->advance.y ));
+
+ FT_TRACE5(( " linear x advance: %d\n" , slot->linearHoriAdvance ));
+ FT_TRACE5(( " linear y advance: %d\n" , slot->linearVertAdvance ));
+
/* do we need to render the image now? */
if ( !error &&
slot->format != FT_GLYPH_FORMAT_BITMAP &&
@@ -2402,12 +2426,24 @@
ft_synthesize_vertical_metrics( FT_Glyph_Metrics* metrics,
FT_Pos advance )
{
+ FT_Pos height = metrics->height;
+
+
+ /* compensate for glyph with bbox above/below the baseline */
+ if ( metrics->horiBearingY < 0 )
+ {
+ if ( height < metrics->horiBearingY )
+ height = metrics->horiBearingY;
+ }
+ else if ( metrics->horiBearingY > 0 )
+ height -= metrics->horiBearingY;
+
/* the factor 1.2 is a heuristical value */
if ( !advance )
- advance = metrics->height * 12 / 10;
+ advance = height * 12 / 10;
- metrics->vertBearingX = -( metrics->width / 2 );
- metrics->vertBearingY = ( advance - metrics->height ) / 2;
+ metrics->vertBearingX = metrics->horiBearingX - metrics->horiAdvance / 2;
+ metrics->vertBearingY = ( advance - height ) / 2;
metrics->vertAdvance = advance;
}
@@ -3052,7 +3088,12 @@
FT_CMap cmap = FT_CMAP( face->charmap );
- result = cmap->clazz->char_index( cmap, charcode );
+ if ( charcode > 0xFFFFFFFFUL )
+ {
+ FT_TRACE1(( "FT_Get_Char_Index: too large charcode" ));
+ FT_TRACE1(( " 0x%x is truncated\n", charcode ));
+ }
+ result = cmap->clazz->char_index( cmap, (FT_UInt32)charcode );
}
return result;
}
@@ -3132,8 +3173,20 @@
FT_CMap vcmap = FT_CMAP( charmap );
- result = vcmap->clazz->char_var_index( vcmap, ucmap, charcode,
- variantSelector );
+ if ( charcode > 0xFFFFFFFFUL )
+ {
+ FT_TRACE1(( "FT_Get_Char_Index: too large charcode" ));
+ FT_TRACE1(( " 0x%x is truncated\n", charcode ));
+ }
+ if ( variantSelector > 0xFFFFFFFFUL )
+ {
+ FT_TRACE1(( "FT_Get_Char_Index: too large variantSelector" ));
+ FT_TRACE1(( " 0x%x is truncated\n", variantSelector ));
+ }
+
+ result = vcmap->clazz->char_var_index( vcmap, ucmap,
+ (FT_UInt32)charcode,
+ (FT_UInt32)variantSelector );
}
}
@@ -3161,8 +3214,20 @@
FT_CMap vcmap = FT_CMAP( charmap );
- result = vcmap->clazz->char_var_default( vcmap, charcode,
- variantSelector );
+ if ( charcode > 0xFFFFFFFFUL )
+ {
+ FT_TRACE1(( "FT_Get_Char_Index: too large charcode" ));
+ FT_TRACE1(( " 0x%x is truncated\n", charcode ));
+ }
+ if ( variantSelector > 0xFFFFFFFFUL )
+ {
+ FT_TRACE1(( "FT_Get_Char_Index: too large variantSelector" ));
+ FT_TRACE1(( " 0x%x is truncated\n", variantSelector ));
+ }
+
+ result = vcmap->clazz->char_var_default( vcmap,
+ (FT_UInt32)charcode,
+ (FT_UInt32)variantSelector );
}
}
@@ -3217,7 +3282,14 @@
FT_Memory memory = FT_FACE_MEMORY( face );
- result = vcmap->clazz->charvariant_list( vcmap, memory, charcode );
+ if ( charcode > 0xFFFFFFFFUL )
+ {
+ FT_TRACE1(( "FT_Get_Char_Index: too large charcode" ));
+ FT_TRACE1(( " 0x%x is truncated\n", charcode ));
+ }
+
+ result = vcmap->clazz->charvariant_list( vcmap, memory,
+ (FT_UInt32)charcode );
}
}
return result;
@@ -3244,8 +3316,14 @@
FT_Memory memory = FT_FACE_MEMORY( face );
+ if ( variantSelector > 0xFFFFFFFFUL )
+ {
+ FT_TRACE1(( "FT_Get_Char_Index: too large variantSelector" ));
+ FT_TRACE1(( " 0x%x is truncated\n", variantSelector ));
+ }
+
result = vcmap->clazz->variantchar_list( vcmap, memory,
- variantSelector );
+ (FT_UInt32)variantSelector );
}
}
@@ -3295,7 +3373,7 @@
((FT_Byte*)buffer)[0] = 0;
if ( face &&
- glyph_index <= (FT_UInt)face->num_glyphs &&
+ (FT_Long)glyph_index <= face->num_glyphs &&
FT_HAS_GLYPH_NAMES( face ) )
{
FT_Service_GlyphDict service;
@@ -3395,6 +3473,7 @@
FT_ULong *length )
{
FT_Service_SFNT_Table service;
+ FT_ULong offset;
if ( !face || !FT_IS_SFNT( face ) )
@@ -3404,7 +3483,7 @@
if ( service == NULL )
return FT_Err_Unimplemented_Feature;
- return service->table_info( face, table_index, tag, length );
+ return service->table_info( face, table_index, tag, &offset, length );
}
@@ -3729,7 +3808,7 @@
while ( renderer )
{
error = renderer->render( renderer, slot, render_mode, NULL );
- if ( !error ||
+ if ( !error ||
FT_ERROR_BASE( error ) != FT_Err_Cannot_Render_Glyph )
break;
@@ -4127,6 +4206,13 @@
library->memory = memory;
+#ifdef FT_CONFIG_OPTION_PIC
+ /* initialize position independent code containers */
+ error = ft_pic_container_init( library );
+ if ( error )
+ goto Fail;
+#endif
+
/* allocate the render pool */
library->raster_pool_size = FT_RENDER_POOL_SIZE;
#if FT_RENDER_POOL_SIZE > 0
@@ -4134,12 +4220,19 @@
goto Fail;
#endif
+ library->version_major = FREETYPE_MAJOR;
+ library->version_minor = FREETYPE_MINOR;
+ library->version_patch = FREETYPE_PATCH;
+
/* That's ok now */
*alibrary = library;
return FT_Err_Ok;
Fail:
+#ifdef FT_CONFIG_OPTION_PIC
+ ft_pic_container_destroy( library );
+#endif
FT_FREE( library );
return error;
}
@@ -4220,7 +4313,7 @@
{
FT_Done_Face( FT_FACE( faces->head->data ) );
if ( faces->head )
- FT_ERROR(( "FT_Done_Library: failed to free some faces\n" ));
+ FT_TRACE0(( "FT_Done_Library: failed to free some faces\n" ));
}
}
}
@@ -4256,6 +4349,11 @@
FT_FREE( library->raster_pool );
library->raster_pool_size = 0;
+#ifdef FT_CONFIG_OPTION_PIC
+ /* Destroy pic container contents */
+ ft_pic_container_destroy( library );
+#endif
+
FT_FREE( library );
return FT_Err_Ok;
}
diff --git a/src/3rdparty/freetype/src/base/ftoutln.c b/src/3rdparty/freetype/src/base/ftoutln.c
index 49ef82e27d..b69df84c04 100644
--- a/src/3rdparty/freetype/src/base/ftoutln.c
+++ b/src/3rdparty/freetype/src/base/ftoutln.c
@@ -4,7 +4,7 @@
/* */
/* FreeType outline management (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -304,9 +304,9 @@
*anoutline = null_outline;
- if ( FT_NEW_ARRAY( anoutline->points, numPoints * 2L ) ||
- FT_NEW_ARRAY( anoutline->tags, numPoints ) ||
- FT_NEW_ARRAY( anoutline->contours, numContours ) )
+ if ( FT_NEW_ARRAY( anoutline->points, numPoints ) ||
+ FT_NEW_ARRAY( anoutline->tags, numPoints ) ||
+ FT_NEW_ARRAY( anoutline->contours, numContours ) )
goto Fail;
anoutline->n_points = (FT_UShort)numPoints;
diff --git a/src/3rdparty/freetype/src/base/ftpatent.c b/src/3rdparty/freetype/src/base/ftpatent.c
index 9f129d8f0d..501cab52ca 100644
--- a/src/3rdparty/freetype/src/base/ftpatent.c
+++ b/src/3rdparty/freetype/src/base/ftpatent.c
@@ -5,7 +5,7 @@
/* FreeType API for checking patented TrueType bytecode instructions */
/* (body). */
/* */
-/* Copyright 2007, 2008 by David Turner. */
+/* Copyright 2007, 2008, 2010 by David Turner. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
@@ -103,6 +103,7 @@
}
Exit:
+ FT_UNUSED( error );
FT_FRAME_EXIT();
return result;
}
@@ -113,7 +114,7 @@
FT_ULong tag )
{
FT_Stream stream = face->stream;
- FT_Error error;
+ FT_Error error = FT_Err_Ok;
FT_Service_SFNT_Table service;
FT_Bool result = FALSE;
@@ -122,15 +123,19 @@
if ( service )
{
- FT_ULong offset, size;
+ FT_UInt i = 0;
+ FT_ULong tag_i = 0, offset_i = 0, length_i = 0;
- error = service->table_info( face, tag, &offset, &size );
- if ( error ||
- FT_STREAM_SEEK( offset ) )
+ for ( i = 0; !error && tag_i != tag ; i++ )
+ error = service->table_info( face, i,
+ &tag_i, &offset_i, &length_i );
+
+ if ( error ||
+ FT_STREAM_SEEK( offset_i ) )
goto Exit;
- result = _tt_check_patents_in_range( stream, size );
+ result = _tt_check_patents_in_range( stream, length_i );
}
Exit:
diff --git a/src/3rdparty/freetype/src/base/ftpic.c b/src/3rdparty/freetype/src/base/ftpic.c
new file mode 100644
index 0000000000..d5271a9726
--- /dev/null
+++ b/src/3rdparty/freetype/src/base/ftpic.c
@@ -0,0 +1,54 @@
+/***************************************************************************/
+/* */
+/* ftpic.c */
+/* */
+/* The FreeType position independent code services (body). */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#include <ft2build.h>
+#include FT_FREETYPE_H
+#include FT_INTERNAL_OBJECTS_H
+#include "basepic.h"
+
+#ifdef FT_CONFIG_OPTION_PIC
+
+ /* documentation is in ftpic.h */
+
+ FT_BASE_DEF( FT_Error )
+ ft_pic_container_init( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Error error = FT_Err_Ok;
+
+ FT_MEM_SET( pic_container, 0, sizeof(*pic_container) );
+
+ error = ft_base_pic_init( library );
+ if(error)
+ return error;
+
+ return FT_Err_Ok;
+ }
+
+
+ /* Destroy the contents of the container. */
+ FT_BASE_DEF( void )
+ ft_pic_container_destroy( FT_Library library )
+ {
+ ft_base_pic_free( library );
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/base/ftrfork.c b/src/3rdparty/freetype/src/base/ftrfork.c
index d59a07611c..133c2de057 100644
--- a/src/3rdparty/freetype/src/base/ftrfork.c
+++ b/src/3rdparty/freetype/src/base/ftrfork.c
@@ -752,9 +752,9 @@
const char *insertion )
{
char* new_name;
- char* tmp;
+ const char* tmp;
const char* slash;
- unsigned new_length;
+ size_t new_length;
FT_Error error = FT_Err_Ok;
FT_UNUSED( error );
diff --git a/src/3rdparty/freetype/src/base/ftnames.c b/src/3rdparty/freetype/src/base/ftsnames.c
index 7fde5c40bf..3447888ca2 100644
--- a/src/3rdparty/freetype/src/base/ftnames.c
+++ b/src/3rdparty/freetype/src/base/ftsnames.c
@@ -1,13 +1,13 @@
/***************************************************************************/
/* */
-/* ftnames.c */
+/* ftsnames.c */
/* */
/* Simple interface to access SFNT name tables (which are used */
/* to hold font names, copyright info, notices, etc.) (body). */
/* */
/* This is _not_ used to retrieve glyph names! */
/* */
-/* Copyright 1996-2001, 2002 by */
+/* Copyright 1996-2001, 2002, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -28,16 +28,16 @@
#ifdef TT_CONFIG_OPTION_SFNT_NAMES
- /* documentation is in ftnames.h */
+ /* documentation is in ftsnames.h */
FT_EXPORT_DEF( FT_UInt )
FT_Get_Sfnt_Name_Count( FT_Face face )
{
- return (face && FT_IS_SFNT( face )) ? ((TT_Face)face)->num_names : 0;
+ return ( face && FT_IS_SFNT( face ) ) ? ((TT_Face)face)->num_names : 0;
}
- /* documentation is in ftnames.h */
+ /* documentation is in ftsnames.h */
FT_EXPORT_DEF( FT_Error )
FT_Get_Sfnt_Name( FT_Face face,
diff --git a/src/3rdparty/freetype/src/base/ftstream.c b/src/3rdparty/freetype/src/base/ftstream.c
index 901b6835ba..b638599dbc 100644
--- a/src/3rdparty/freetype/src/base/ftstream.c
+++ b/src/3rdparty/freetype/src/base/ftstream.c
@@ -4,7 +4,7 @@
/* */
/* I/O stream support (body). */
/* */
-/* Copyright 2000-2001, 2002, 2004, 2005, 2006, 2008 by */
+/* Copyright 2000-2001, 2002, 2004, 2005, 2006, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -60,13 +60,12 @@
FT_Error error = FT_Err_Ok;
- stream->pos = pos;
-
if ( stream->read )
{
if ( stream->read( stream, pos, 0, 0 ) )
{
- FT_ERROR(( "FT_Stream_Seek: invalid i/o; pos = 0x%lx, size = 0x%lx\n",
+ FT_ERROR(( "FT_Stream_Seek:"
+ " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
pos, stream->size ));
error = FT_Err_Invalid_Stream_Operation;
@@ -75,12 +74,16 @@
/* note that seeking to the first position after the file is valid */
else if ( pos > stream->size )
{
- FT_ERROR(( "FT_Stream_Seek: invalid i/o; pos = 0x%lx, size = 0x%lx\n",
+ FT_ERROR(( "FT_Stream_Seek:"
+ " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
pos, stream->size ));
error = FT_Err_Invalid_Stream_Operation;
}
+ if ( !error )
+ stream->pos = pos;
+
return error;
}
@@ -124,7 +127,8 @@
if ( pos >= stream->size )
{
- FT_ERROR(( "FT_Stream_ReadAt: invalid i/o; pos = 0x%lx, size = 0x%lx\n",
+ FT_ERROR(( "FT_Stream_ReadAt:"
+ " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
pos, stream->size ));
return FT_Err_Invalid_Stream_Operation;
@@ -145,8 +149,8 @@
if ( read_bytes < count )
{
- FT_ERROR(( "FT_Stream_ReadAt:" ));
- FT_ERROR(( " invalid read; expected %lu bytes, got %lu\n",
+ FT_ERROR(( "FT_Stream_ReadAt:"
+ " invalid read; expected %lu bytes, got %lu\n",
count, read_bytes ));
error = FT_Err_Invalid_Stream_Operation;
@@ -256,8 +260,8 @@
stream->base, count );
if ( read_bytes < count )
{
- FT_ERROR(( "FT_Stream_EnterFrame:" ));
- FT_ERROR(( " invalid read; expected %lu bytes, got %lu\n",
+ FT_ERROR(( "FT_Stream_EnterFrame:"
+ " invalid read; expected %lu bytes, got %lu\n",
count, read_bytes ));
FT_FREE( stream->base );
@@ -273,8 +277,8 @@
if ( stream->pos >= stream->size ||
stream->pos + count > stream->size )
{
- FT_ERROR(( "FT_Stream_EnterFrame:" ));
- FT_ERROR(( " invalid i/o; pos = 0x%lx, count = %lu, size = 0x%lx\n",
+ FT_ERROR(( "FT_Stream_EnterFrame:"
+ " invalid i/o; pos = 0x%lx, count = %lu, size = 0x%lx\n",
stream->pos, count, stream->size ));
error = FT_Err_Invalid_Stream_Operation;
@@ -459,7 +463,8 @@
Fail:
*error = FT_Err_Invalid_Stream_Operation;
- FT_ERROR(( "FT_Stream_ReadChar: invalid i/o; pos = 0x%lx, size = 0x%lx\n",
+ FT_ERROR(( "FT_Stream_ReadChar:"
+ " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
stream->pos, stream->size ));
return 0;
@@ -505,8 +510,8 @@
Fail:
*error = FT_Err_Invalid_Stream_Operation;
- FT_ERROR(( "FT_Stream_ReadShort:" ));
- FT_ERROR(( " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
+ FT_ERROR(( "FT_Stream_ReadShort:"
+ " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
stream->pos, stream->size ));
return 0;
@@ -552,8 +557,8 @@
Fail:
*error = FT_Err_Invalid_Stream_Operation;
- FT_ERROR(( "FT_Stream_ReadShortLE:" ));
- FT_ERROR(( " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
+ FT_ERROR(( "FT_Stream_ReadShortLE:"
+ " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
stream->pos, stream->size ));
return 0;
@@ -599,8 +604,8 @@
Fail:
*error = FT_Err_Invalid_Stream_Operation;
- FT_ERROR(( "FT_Stream_ReadOffset:" ));
- FT_ERROR(( " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
+ FT_ERROR(( "FT_Stream_ReadOffset:"
+ " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
stream->pos, stream->size ));
return 0;
@@ -645,9 +650,10 @@
return result;
Fail:
- FT_ERROR(( "FT_Stream_ReadLong: invalid i/o; pos = 0x%lx, size = 0x%lx\n",
- stream->pos, stream->size ));
*error = FT_Err_Invalid_Stream_Operation;
+ FT_ERROR(( "FT_Stream_ReadLong:"
+ " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
+ stream->pos, stream->size ));
return 0;
}
@@ -691,10 +697,10 @@
return result;
Fail:
- FT_ERROR(( "FT_Stream_ReadLongLE:" ));
- FT_ERROR(( " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
- stream->pos, stream->size ));
*error = FT_Err_Invalid_Stream_Operation;
+ FT_ERROR(( "FT_Stream_ReadLongLE:"
+ " invalid i/o; pos = 0x%lx, size = 0x%lx\n",
+ stream->pos, stream->size ));
return 0;
}
diff --git a/src/3rdparty/freetype/src/base/ftstroke.c b/src/3rdparty/freetype/src/base/ftstroke.c
index 3f5421fa57..75bcbded6a 100644
--- a/src/3rdparty/freetype/src/base/ftstroke.c
+++ b/src/3rdparty/freetype/src/base/ftstroke.c
@@ -4,7 +4,7 @@
/* */
/* FreeType path stroker (body). */
/* */
-/* Copyright 2002, 2003, 2004, 2005, 2006, 2008, 2009 by */
+/* Copyright 2002, 2003, 2004, 2005, 2006, 2008, 2009, 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -706,7 +706,7 @@
FT_Bool valid;
FT_StrokeBorderRec borders[2];
- FT_Memory memory;
+ FT_Library library;
} FT_StrokerRec;
@@ -729,7 +729,7 @@
if ( !FT_NEW( stroker ) )
{
- stroker->memory = memory;
+ stroker->library = library;
ft_stroke_border_init( &stroker->borders[0], memory );
ft_stroke_border_init( &stroker->borders[1], memory );
@@ -777,13 +777,13 @@
{
if ( stroker )
{
- FT_Memory memory = stroker->memory;
+ FT_Memory memory = stroker->library->memory;
ft_stroke_border_done( &stroker->borders[0] );
ft_stroke_border_done( &stroker->borders[1] );
- stroker->memory = NULL;
+ stroker->library = NULL;
FT_FREE( stroker );
}
}
@@ -859,6 +859,31 @@
error = ft_stroke_border_lineto( border, &delta, FALSE );
}
+ else if ( stroker->line_cap == FT_STROKER_LINECAP_BUTT )
+ {
+ /* add a butt ending */
+ FT_Vector delta;
+ FT_Angle rotate = FT_SIDE_TO_ROTATE( side );
+ FT_Fixed radius = stroker->radius;
+ FT_StrokeBorder border = stroker->borders + side;
+
+
+ FT_Vector_From_Polar( &delta, radius, angle + rotate );
+
+ delta.x += stroker->center.x;
+ delta.y += stroker->center.y;
+
+ error = ft_stroke_border_lineto( border, &delta, FALSE );
+ if ( error )
+ goto Exit;
+
+ FT_Vector_From_Polar( &delta, radius, angle - rotate );
+
+ delta.x += stroker->center.x;
+ delta.y += stroker->center.y;
+
+ error = ft_stroke_border_lineto( border, &delta, FALSE );
+ }
Exit:
return error;
@@ -954,7 +979,8 @@
thcos = FT_Cos( theta );
sigma = FT_MulFix( stroker->miter_limit, thcos );
- if ( sigma >= 0x10000L )
+ /* FT_Sin(x) = 0 for x <= 57 */
+ if ( sigma >= 0x10000L || ft_pos_abs( theta ) <= 57 )
miter = FALSE;
if ( miter ) /* this is a miter (broken angle) */
@@ -1335,7 +1361,7 @@
phi1 = (angle_mid + angle_in ) / 2;
phi2 = (angle_mid + angle_out ) / 2;
length1 = FT_DivFix( stroker->radius, FT_Cos( theta1 ) );
- length2 = FT_DivFix( stroker->radius, FT_Cos(theta2) );
+ length2 = FT_DivFix( stroker->radius, FT_Cos( theta2 ) );
for ( side = 0; side <= 1; side++ )
{
@@ -1710,13 +1736,10 @@
}
else
{
- /* if both first and last points are conic, */
- /* start at their middle and record its position */
- /* for closure */
+ /* if both first and last points are conic, */
+ /* start at their middle */
v_start.x = ( v_start.x + v_last.x ) / 2;
v_start.y = ( v_start.y + v_last.y ) / 2;
-
- v_last = v_start;
}
point--;
tags--;
@@ -1844,8 +1867,13 @@
return FT_Err_Invalid_Outline;
}
-
+/* declare an extern to access ft_outline_glyph_class global allocated
+ in ftglyph.c, and use the FT_OUTLINE_GLYPH_CLASS_GET macro to access
+ it when FT_CONFIG_OPTION_PIC is defined */
+#ifndef FT_CONFIG_OPTION_PIC
extern const FT_Glyph_Class ft_outline_glyph_class;
+#endif
+#include "basepic.h"
/* documentation is in ftstroke.h */
@@ -1857,13 +1885,14 @@
{
FT_Error error = FT_Err_Invalid_Argument;
FT_Glyph glyph = NULL;
-
+ FT_Library library = stroker->library;
+ FT_UNUSED(library);
if ( pglyph == NULL )
goto Exit;
glyph = *pglyph;
- if ( glyph == NULL || glyph->clazz != &ft_outline_glyph_class )
+ if ( glyph == NULL || glyph->clazz != FT_OUTLINE_GLYPH_CLASS_GET )
goto Exit;
{
@@ -1930,13 +1959,14 @@
{
FT_Error error = FT_Err_Invalid_Argument;
FT_Glyph glyph = NULL;
-
+ FT_Library library = stroker->library;
+ FT_UNUSED(library);
if ( pglyph == NULL )
goto Exit;
glyph = *pglyph;
- if ( glyph == NULL || glyph->clazz != &ft_outline_glyph_class )
+ if ( glyph == NULL || glyph->clazz != FT_OUTLINE_GLYPH_CLASS_GET )
goto Exit;
{
diff --git a/src/3rdparty/freetype/src/base/ftsynth.c b/src/3rdparty/freetype/src/base/ftsynth.c
index 443d272602..ba3c633e28 100644
--- a/src/3rdparty/freetype/src/base/ftsynth.c
+++ b/src/3rdparty/freetype/src/base/ftsynth.c
@@ -4,7 +4,7 @@
/* */
/* FreeType synthesizing code for emboldening and slanting (body). */
/* */
-/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006 by */
+/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006, 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -18,12 +18,22 @@
#include <ft2build.h>
#include FT_SYNTHESIS_H
+#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_OBJECTS_H
#include FT_OUTLINE_H
#include FT_BITMAP_H
/*************************************************************************/
+ /* */
+ /* The macro FT_COMPONENT is used in trace mode. It is an implicit */
+ /* parameter of the FT_TRACE() and FT_ERROR() macros, used to print/log */
+ /* messages during execution. */
+ /* */
+#undef FT_COMPONENT
+#define FT_COMPONENT trace_synth
+
+ /*************************************************************************/
/*************************************************************************/
/**** ****/
/**** EXPERIMENTAL OBLIQUING SUPPORT ****/
@@ -90,8 +100,8 @@
if ( slot->format == FT_GLYPH_FORMAT_OUTLINE )
{
- error = FT_Outline_Embolden( &slot->outline, xstr );
/* ignore error */
+ (void)FT_Outline_Embolden( &slot->outline, xstr );
/* this is more than enough for most glyphs; if you need accurate */
/* values, you have to call FT_Outline_Get_CBox */
@@ -106,6 +116,18 @@
xstr = 1 << 6;
ystr &= ~63;
+ /*
+ * XXX: overflow check for 16-bit system, for compatibility
+ * with FT_GlyphSlot_Embolden() since freetype-2.1.10.
+ * unfortunately, this function return no informations
+ * about the cause of error.
+ */
+ if ( ( ystr >> 6 ) > FT_INT_MAX || ( ystr >> 6 ) < FT_INT_MIN )
+ {
+ FT_TRACE1(( "FT_GlyphSlot_Embolden:" ));
+ FT_TRACE1(( "too strong embolding parameter ystr=%d\n", ystr ));
+ return;
+ }
error = FT_GlyphSlot_Own_Bitmap( slot );
if ( error )
return;
@@ -129,8 +151,9 @@
slot->metrics.vertBearingY += ystr;
slot->metrics.vertAdvance += ystr;
+ /* XXX: 16-bit overflow case must be excluded before here */
if ( slot->format == FT_GLYPH_FORMAT_BITMAP )
- slot->bitmap_top += ystr >> 6;
+ slot->bitmap_top += (FT_Int)( ystr >> 6 );
}
diff --git a/src/3rdparty/freetype/src/base/ftsystem.c b/src/3rdparty/freetype/src/base/ftsystem.c
index f64908fd22..4d06d6db5c 100644
--- a/src/3rdparty/freetype/src/base/ftsystem.c
+++ b/src/3rdparty/freetype/src/base/ftsystem.c
@@ -4,7 +4,7 @@
/* */
/* ANSI-specific FreeType low-level system interface (body). */
/* */
-/* Copyright 1996-2001, 2002, 2006, 2008 by */
+/* Copyright 1996-2001, 2002, 2006, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -205,7 +205,8 @@
file = STREAM_FILE( stream );
- ft_fseek( file, offset, SEEK_SET );
+ if ( stream->pos != offset )
+ ft_fseek( file, offset, SEEK_SET );
return (unsigned long)ft_fread( buffer, 1, count, file );
}
@@ -226,8 +227,8 @@
file = ft_fopen( filepathname, "rb" );
if ( !file )
{
- FT_ERROR(( "FT_Stream_Open:" ));
- FT_ERROR(( " could not open `%s'\n", filepathname ));
+ FT_ERROR(( "FT_Stream_Open:"
+ " could not open `%s'\n", filepathname ));
return FT_Err_Cannot_Open_Resource;
}
diff --git a/src/3rdparty/freetype/src/base/fttrigon.c b/src/3rdparty/freetype/src/base/fttrigon.c
index 9f513946b8..fdf433ab86 100644
--- a/src/3rdparty/freetype/src/base/fttrigon.c
+++ b/src/3rdparty/freetype/src/base/fttrigon.c
@@ -72,10 +72,10 @@
val = ( val >= 0 ) ? val : -val;
v1 = (FT_UInt32)val >> 16;
- v2 = (FT_UInt32)val & 0xFFFFL;
+ v2 = (FT_UInt32)(val & 0xFFFFL);
- k1 = FT_TRIG_SCALE >> 16; /* constant */
- k2 = FT_TRIG_SCALE & 0xFFFFL; /* constant */
+ k1 = (FT_UInt32)FT_TRIG_SCALE >> 16; /* constant */
+ k2 = (FT_UInt32)(FT_TRIG_SCALE & 0xFFFFL); /* constant */
hi = k1 * v1;
lo1 = k1 * v2 + k2 * v1; /* can't overflow */
@@ -86,7 +86,7 @@
hi += lo1 >> 16;
if ( lo1 < lo3 )
- hi += 0x10000UL;
+ hi += (FT_UInt32)0x10000UL;
val = (FT_Fixed)hi;
@@ -433,7 +433,7 @@
if ( shift > 0 )
{
- FT_Int32 half = 1L << ( shift - 1 );
+ FT_Int32 half = (FT_Int32)1L << ( shift - 1 );
vec->x = ( v.x + half + FT_SIGN_LONG( v.x ) ) >> shift;
diff --git a/src/3rdparty/freetype/src/base/rules.mk b/src/3rdparty/freetype/src/base/rules.mk
index 66260e6777..10f578abc8 100644
--- a/src/3rdparty/freetype/src/base/rules.mk
+++ b/src/3rdparty/freetype/src/base/rules.mk
@@ -37,10 +37,10 @@ BASE_SRC := $(BASE_DIR)/ftadvanc.c \
$(BASE_DIR)/ftcalc.c \
$(BASE_DIR)/ftdbgmem.c \
$(BASE_DIR)/ftgloadr.c \
- $(BASE_DIR)/ftnames.c \
$(BASE_DIR)/ftobjs.c \
$(BASE_DIR)/ftoutln.c \
$(BASE_DIR)/ftrfork.c \
+ $(BASE_DIR)/ftsnames.c \
$(BASE_DIR)/ftstream.c \
$(BASE_DIR)/fttrigon.c \
$(BASE_DIR)/ftutil.c
diff --git a/src/3rdparty/freetype/src/bdf/bdf.h b/src/3rdparty/freetype/src/bdf/bdf.h
index 1b64426aad..561b4158a5 100644
--- a/src/3rdparty/freetype/src/bdf/bdf.h
+++ b/src/3rdparty/freetype/src/bdf/bdf.h
@@ -114,8 +114,8 @@ FT_BEGIN_HEADER
union
{
char* atom;
- long int32;
- unsigned long card32;
+ long l;
+ unsigned long ul;
} value; /* Value of the property. */
@@ -160,7 +160,7 @@ FT_BEGIN_HEADER
typedef struct _hashnode_
{
const char* key;
- void* data;
+ size_t data;
} _hashnode, *hashnode;
diff --git a/src/3rdparty/freetype/src/bdf/bdfdrivr.c b/src/3rdparty/freetype/src/bdf/bdfdrivr.c
index 0b736b5ceb..631ec460e7 100644
--- a/src/3rdparty/freetype/src/bdf/bdfdrivr.c
+++ b/src/3rdparty/freetype/src/bdf/bdfdrivr.c
@@ -53,7 +53,7 @@ THE SOFTWARE.
typedef struct BDF_CMapRec_
{
FT_CMapRec cmap;
- FT_UInt num_encodings;
+ FT_ULong num_encodings; /* ftobjs.h: FT_CMap->clazz->size */
BDF_encoding_el* encodings;
} BDF_CMapRec, *BDF_CMap;
@@ -92,8 +92,8 @@ THE SOFTWARE.
{
BDF_CMap cmap = (BDF_CMap)bdfcmap;
BDF_encoding_el* encodings = cmap->encodings;
- FT_UInt min, max, mid;
- FT_UInt result = 0;
+ FT_ULong min, max, mid; /* num_encodings */
+ FT_UShort result = 0; /* encodings->glyph */
min = 0;
@@ -101,7 +101,7 @@ THE SOFTWARE.
while ( min < max )
{
- FT_UInt32 code;
+ FT_ULong code;
mid = ( min + max ) >> 1;
@@ -131,9 +131,9 @@ THE SOFTWARE.
{
BDF_CMap cmap = (BDF_CMap)bdfcmap;
BDF_encoding_el* encodings = cmap->encodings;
- FT_UInt min, max, mid;
- FT_UInt32 charcode = *acharcode + 1;
- FT_UInt result = 0;
+ FT_ULong min, max, mid; /* num_encodings */
+ FT_UShort result = 0; /* encodings->glyph */
+ FT_ULong charcode = *acharcode + 1;
min = 0;
@@ -141,7 +141,7 @@ THE SOFTWARE.
while ( min < max )
{
- FT_UInt32 code;
+ FT_ULong code; /* same as BDF_encoding_el.enc */
mid = ( min + max ) >> 1;
@@ -169,7 +169,14 @@ THE SOFTWARE.
}
Exit:
- *acharcode = charcode;
+ if ( charcode > 0xFFFFFFFFUL )
+ {
+ FT_TRACE1(( "bdf_cmap_char_next: charcode 0x%x > 32bit API" ));
+ *acharcode = 0;
+ /* XXX: result should be changed to indicate an overflow error */
+ }
+ else
+ *acharcode = (FT_UInt32)charcode;
return result;
}
@@ -196,9 +203,8 @@ THE SOFTWARE.
bdf_font_t* font = bdf->bdffont;
bdf_property_t* prop;
- int nn, len;
- char* strings[4] = { NULL, NULL, NULL, NULL };
- int lengths[4];
+ char* strings[4] = { NULL, NULL, NULL, NULL };
+ size_t nn, len, lengths[4];
face->style_flags = 0;
@@ -284,7 +290,7 @@ THE SOFTWARE.
/* add_style_name and setwidth_name */
if ( nn == 0 || nn == 3 )
{
- int mm;
+ size_t mm;
for ( mm = 0; mm < len; mm++ )
@@ -426,7 +432,7 @@ THE SOFTWARE.
prop = bdf_get_font_property( font, "AVERAGE_WIDTH" );
if ( prop )
- bsize->width = (FT_Short)( ( prop->value.int32 + 5 ) / 10 );
+ bsize->width = (FT_Short)( ( prop->value.l + 5 ) / 10 );
else
bsize->width = (FT_Short)( bsize->height * 2/3 );
@@ -434,21 +440,21 @@ THE SOFTWARE.
if ( prop )
/* convert from 722.7 decipoints to 72 points per inch */
bsize->size =
- (FT_Pos)( ( prop->value.int32 * 64 * 7200 + 36135L ) / 72270L );
+ (FT_Pos)( ( prop->value.l * 64 * 7200 + 36135L ) / 72270L );
else
bsize->size = bsize->width << 6;
prop = bdf_get_font_property( font, "PIXEL_SIZE" );
if ( prop )
- bsize->y_ppem = (FT_Short)prop->value.int32 << 6;
+ bsize->y_ppem = (FT_Short)prop->value.l << 6;
prop = bdf_get_font_property( font, "RESOLUTION_X" );
if ( prop )
- resolution_x = (FT_Short)prop->value.int32;
+ resolution_x = (FT_Short)prop->value.l;
prop = bdf_get_font_property( font, "RESOLUTION_Y" );
if ( prop )
- resolution_y = (FT_Short)prop->value.int32;
+ resolution_y = (FT_Short)prop->value.l;
if ( bsize->y_ppem == 0 )
{
@@ -479,7 +485,12 @@ THE SOFTWARE.
(face->en_table[n]).glyph = (FT_Short)n;
if ( cur[n].encoding == font->default_char )
- face->default_glyph = n;
+ {
+ if ( n < FT_UINT_MAX )
+ face->default_glyph = (FT_UInt)n;
+ else
+ FT_TRACE1(( "idx %d is too large for this system\n", n ));
+ }
}
}
@@ -671,7 +682,10 @@ THE SOFTWARE.
bitmap->rows = glyph.bbx.height;
bitmap->width = glyph.bbx.width;
- bitmap->pitch = glyph.bpr;
+ if ( glyph.bpr > INT_MAX )
+ FT_TRACE1(( "BDF_Glyph_Load: too large pitch %d is truncated\n",
+ glyph.bpr ));
+ bitmap->pitch = (int)glyph.bpr; /* same as FT_Bitmap.pitch */
/* note: we don't allocate a new array to hold the bitmap; */
/* we can simply point to it */
@@ -743,13 +757,23 @@ THE SOFTWARE.
break;
case BDF_INTEGER:
+ if ( prop->value.l > 0x7FFFFFFFL || prop->value.l < ( -1 - 0x7FFFFFFFL ) )
+ {
+ FT_TRACE1(( "bdf_get_bdf_property: " ));
+ FT_TRACE1(( "too large integer 0x%x is truncated\n" ));
+ }
aproperty->type = BDF_PROPERTY_TYPE_INTEGER;
- aproperty->u.integer = prop->value.int32;
+ aproperty->u.integer = (FT_Int32)prop->value.l;
break;
case BDF_CARDINAL:
+ if ( prop->value.ul > 0xFFFFFFFFUL )
+ {
+ FT_TRACE1(( "bdf_get_bdf_property: " ));
+ FT_TRACE1(( "too large cardinal 0x%x is truncated\n" ));
+ }
aproperty->type = BDF_PROPERTY_TYPE_CARDINAL;
- aproperty->u.cardinal = prop->value.card32;
+ aproperty->u.cardinal = (FT_UInt32)prop->value.ul;
break;
default:
diff --git a/src/3rdparty/freetype/src/bdf/bdfdrivr.h b/src/3rdparty/freetype/src/bdf/bdfdrivr.h
index 86f40ee4af..db7093bb45 100644
--- a/src/3rdparty/freetype/src/bdf/bdfdrivr.h
+++ b/src/3rdparty/freetype/src/bdf/bdfdrivr.h
@@ -36,6 +36,10 @@ THE SOFTWARE.
FT_BEGIN_HEADER
+#ifdef FT_CONFIG_OPTION_PIC
+#error "this module does not support PIC yet"
+#endif
+
typedef struct BDF_encoding_el_
{
diff --git a/src/3rdparty/freetype/src/bdf/bdflib.c b/src/3rdparty/freetype/src/bdf/bdflib.c
index 5435b20e69..5fa5868c71 100644
--- a/src/3rdparty/freetype/src/bdf/bdflib.c
+++ b/src/3rdparty/freetype/src/bdf/bdflib.c
@@ -281,7 +281,7 @@
static FT_Error
hash_insert( char* key,
- void* data,
+ size_t data,
hashtable* ht,
FT_Memory memory )
{
@@ -415,18 +415,18 @@
static FT_Error
- _bdf_list_ensure( _bdf_list_t* list,
- int num_items )
+ _bdf_list_ensure( _bdf_list_t* list,
+ unsigned long num_items ) /* same as _bdf_list_t.used */
{
FT_Error error = BDF_Err_Ok;
- if ( num_items > (int)list->size )
+ if ( num_items > list->size )
{
- int oldsize = list->size;
- int newsize = oldsize + ( oldsize >> 1 ) + 4;
- int bigsize = FT_INT_MAX / sizeof ( char* );
- FT_Memory memory = list->memory;
+ unsigned long oldsize = list->size; /* same as _bdf_list_t.size */
+ unsigned long newsize = oldsize + ( oldsize >> 1 ) + 4;
+ unsigned long bigsize = (unsigned long)( FT_INT_MAX / sizeof ( char* ) );
+ FT_Memory memory = list->memory;
if ( oldsize == bigsize )
@@ -614,8 +614,8 @@
{
_bdf_line_func_t cb;
unsigned long lineno, buf_size;
- int refill, bytes, hold, to_skip;
- int start, end, cursor, avail;
+ int refill, hold, to_skip;
+ ptrdiff_t bytes, start, end, cursor, avail;
char* buf = 0;
FT_Memory memory = stream->memory;
FT_Error error = BDF_Err_Ok;
@@ -648,8 +648,8 @@
{
if ( refill )
{
- bytes = (int)FT_Stream_TryRead( stream, (FT_Byte*)buf + cursor,
- (FT_ULong)(buf_size - cursor) );
+ bytes = (ptrdiff_t)FT_Stream_TryRead( stream, (FT_Byte*)buf + cursor,
+ (FT_ULong)(buf_size - cursor) );
avail = cursor + bytes;
cursor = 0;
refill = 0;
@@ -971,7 +971,7 @@
int format,
bdf_font_t* font )
{
- unsigned long n;
+ size_t n;
bdf_property_t* p;
FT_Memory memory = font->memory;
FT_Error error = BDF_Err_Ok;
@@ -991,7 +991,9 @@
p = font->user_props + font->nuser_props;
FT_ZERO( p );
- n = (unsigned long)( ft_strlen( name ) + 1 );
+ n = ft_strlen( name ) + 1;
+ if ( n > FT_ULONG_MAX )
+ return BDF_Err_Invalid_Argument;
if ( FT_NEW_ARRAY( p->name, n ) )
goto Exit;
@@ -1003,7 +1005,7 @@
n = _num_bdf_properties + font->nuser_props;
- error = hash_insert( p->name, (void *)n, &(font->proptbl), memory );
+ error = hash_insert( p->name, n, &(font->proptbl), memory );
if ( error )
goto Exit;
@@ -1018,8 +1020,8 @@
bdf_get_property( char* name,
bdf_font_t* font )
{
- hashnode hn;
- unsigned long propid;
+ hashnode hn;
+ size_t propid;
if ( name == 0 || *name == 0 )
@@ -1028,7 +1030,7 @@
if ( ( hn = hash_lookup( name, &(font->proptbl) ) ) == 0 )
return 0;
- propid = (unsigned long)hn->data;
+ propid = hn->data;
if ( propid >= _num_bdf_properties )
return font->user_props + ( propid - _num_bdf_properties );
@@ -1131,11 +1133,11 @@
_bdf_set_default_spacing( bdf_font_t* font,
bdf_options_t* opts )
{
- unsigned long len;
- char name[256];
- _bdf_list_t list;
- FT_Memory memory;
- FT_Error error = BDF_Err_Ok;
+ size_t len;
+ char name[256];
+ _bdf_list_t list;
+ FT_Memory memory;
+ FT_Error error = BDF_Err_Ok;
if ( font == 0 || font->name == 0 || font->name[0] == 0 )
@@ -1150,7 +1152,7 @@
font->spacing = opts->font_spacing;
- len = (unsigned long)( ft_strlen( font->name ) + 1 );
+ len = ft_strlen( font->name ) + 1;
/* Limit ourselves to 256 characters in the font name. */
if ( len >= 256 )
{
@@ -1261,7 +1263,7 @@
char* name,
char* value )
{
- unsigned long propid;
+ size_t propid;
hashnode hn;
bdf_property_t *prop, *fp;
FT_Memory memory = font->memory;
@@ -1273,7 +1275,7 @@
{
/* The property already exists in the font, so simply replace */
/* the value of the property with the current value. */
- fp = font->props + (unsigned long)hn->data;
+ fp = font->props + hn->data;
switch ( fp->format )
{
@@ -1289,11 +1291,11 @@
break;
case BDF_INTEGER:
- fp->value.int32 = _bdf_atol( value, 0, 10 );
+ fp->value.l = _bdf_atol( value, 0, 10 );
break;
case BDF_CARDINAL:
- fp->value.card32 = _bdf_atoul( value, 0, 10 );
+ fp->value.ul = _bdf_atoul( value, 0, 10 );
break;
default:
@@ -1335,7 +1337,7 @@
font->props_size++;
}
- propid = (unsigned long)hn->data;
+ propid = hn->data;
if ( propid >= _num_bdf_properties )
prop = font->user_props + ( propid - _num_bdf_properties );
else
@@ -1359,11 +1361,11 @@
break;
case BDF_INTEGER:
- fp->value.int32 = _bdf_atol( value, 0, 10 );
+ fp->value.l = _bdf_atol( value, 0, 10 );
break;
case BDF_CARDINAL:
- fp->value.card32 = _bdf_atoul( value, 0, 10 );
+ fp->value.ul = _bdf_atoul( value, 0, 10 );
break;
}
@@ -1372,7 +1374,7 @@
if ( ft_memcmp( name, "COMMENT", 7 ) != 0 ) {
/* Add the property to the font property table. */
error = hash_insert( fp->name,
- (void *)font->props_used,
+ font->props_used,
(hashtable *)font->internal,
memory );
if ( error )
@@ -1387,11 +1389,11 @@
/* present, and the SPACING property should override the default */
/* spacing. */
if ( ft_memcmp( name, "DEFAULT_CHAR", 12 ) == 0 )
- font->default_char = fp->value.int32;
+ font->default_char = fp->value.l;
else if ( ft_memcmp( name, "FONT_ASCENT", 11 ) == 0 )
- font->font_ascent = fp->value.int32;
+ font->font_ascent = fp->value.l;
else if ( ft_memcmp( name, "FONT_DESCENT", 12 ) == 0 )
- font->font_descent = fp->value.int32;
+ font->font_descent = fp->value.l;
else if ( ft_memcmp( name, "SPACING", 7 ) == 0 )
{
if ( !fp->value.atom )
@@ -2044,7 +2046,7 @@
p->memory = 0;
{ /* setup */
- unsigned long i;
+ size_t i;
bdf_property_t* prop;
@@ -2054,7 +2056,7 @@
for ( i = 0, prop = (bdf_property_t*)_bdf_properties;
i < _num_bdf_properties; i++, prop++ )
{
- error = hash_insert( prop->name, (void *)i,
+ error = hash_insert( prop->name, i,
&(font->proptbl), memory );
if ( error )
goto Exit;
@@ -2472,7 +2474,7 @@
hn = hash_lookup( name, (hashtable *)font->internal );
- return hn ? ( font->props + (unsigned long)hn->data ) : 0;
+ return hn ? ( font->props + hn->data ) : 0;
}
diff --git a/src/3rdparty/freetype/src/cache/ftcbasic.c b/src/3rdparty/freetype/src/cache/ftcbasic.c
index a568b975bb..ebc8871ccc 100644
--- a/src/3rdparty/freetype/src/cache/ftcbasic.c
+++ b/src/3rdparty/freetype/src/cache/ftcbasic.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType basic cache interface (body). */
/* */
-/* Copyright 2003, 2004, 2005, 2006, 2007 by */
+/* Copyright 2003, 2004, 2005, 2006, 2007, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -17,15 +17,17 @@
#include <ft2build.h>
+#include FT_INTERNAL_DEBUG_H
#include FT_CACHE_H
#include "ftcglyph.h"
#include "ftcimage.h"
#include "ftcsbits.h"
-#include FT_INTERNAL_MEMORY_H
#include "ftccback.h"
#include "ftcerror.h"
+#define FT_COMPONENT trace_cache
+
#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
@@ -140,8 +142,18 @@
error = FTC_Manager_LookupFace( manager, family->attrs.scaler.face_id,
&face );
+
+ if ( error || !face )
+ return result;
+
+ if ( (FT_ULong)face->num_glyphs > FT_UINT_MAX || 0 > face->num_glyphs )
+ {
+ FT_TRACE1(( "ftc_basic_family_get_count: too large number of glyphs " ));
+ FT_TRACE1(( "in this face, truncated\n", face->num_glyphs ));
+ }
+
if ( !error )
- result = face->num_glyphs;
+ result = (FT_UInt)face->num_glyphs;
return result;
}
@@ -304,7 +316,7 @@
FTC_Node *anode )
{
FTC_BasicQueryRec query;
- FTC_INode node = 0; /* make compiler happy */
+ FTC_Node node = 0; /* make compiler happy */
FT_Error error;
FT_UInt32 hash;
@@ -320,13 +332,13 @@
if ( anode )
*anode = NULL;
-#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
+#if defined( FT_CONFIG_OPTION_OLD_INTERNALS ) && ( FT_INT_MAX > 0xFFFFU )
/*
* This one is a major hack used to detect whether we are passed a
* regular FTC_ImageType handle, or a legacy FTC_OldImageDesc one.
*/
- if ( type->width >= 0x10000 )
+ if ( (FT_ULong)type->width >= 0x10000L )
{
FTC_OldImageDesc desc = (FTC_OldImageDesc)type;
@@ -341,10 +353,16 @@
#endif /* FT_CONFIG_OPTION_OLD_INTERNALS */
{
+ if ( (FT_ULong)(type->flags - FT_INT_MIN) > FT_UINT_MAX )
+ {
+ FT_TRACE1(( "FTC_ImageCache_Lookup: higher bits in load_flags" ));
+ FT_TRACE1(( "0x%x are dropped\n", (type->flags & ~((FT_ULong)FT_UINT_MAX)) ));
+ }
+
query.attrs.scaler.face_id = type->face_id;
query.attrs.scaler.width = type->width;
query.attrs.scaler.height = type->height;
- query.attrs.load_flags = type->flags;
+ query.attrs.load_flags = (FT_UInt)type->flags;
}
query.attrs.scaler.pixel = 1;
@@ -365,7 +383,7 @@
error = FTC_GCache_Lookup( FTC_GCACHE( cache ),
hash, gindex,
FTC_GQUERY( &query ),
- (FTC_Node*) &node );
+ &node );
#endif
if ( !error )
{
@@ -373,8 +391,8 @@
if ( anode )
{
- *anode = FTC_NODE( node );
- FTC_NODE( node )->ref_count++;
+ *anode = node;
+ node->ref_count++;
}
}
@@ -394,7 +412,7 @@
FTC_Node *anode )
{
FTC_BasicQueryRec query;
- FTC_INode node = 0; /* make compiler happy */
+ FTC_Node node = 0; /* make compiler happy */
FT_Error error;
FT_UInt32 hash;
@@ -410,8 +428,15 @@
if ( anode )
*anode = NULL;
+ /* FT_Load_Glyph(), FT_Load_Char() take FT_UInt flags */
+ if ( load_flags > FT_UINT_MAX )
+ {
+ FT_TRACE1(( "FTC_ImageCache_LookupScaler: higher bits in load_flags" ));
+ FT_TRACE1(( "0x%x are dropped\n", (load_flags & ~((FT_ULong)FT_UINT_MAX)) ));
+ }
+
query.attrs.scaler = scaler[0];
- query.attrs.load_flags = load_flags;
+ query.attrs.load_flags = (FT_UInt)load_flags;
hash = FTC_BASIC_ATTR_HASH( &query.attrs ) + gindex;
@@ -428,8 +453,8 @@
if ( anode )
{
- *anode = FTC_NODE( node );
- FTC_NODE( node )->ref_count++;
+ *anode = node;
+ node->ref_count++;
}
}
@@ -630,7 +655,7 @@
{
FT_Error error;
FTC_BasicQueryRec query;
- FTC_SNode node = 0; /* make compiler happy */
+ FTC_Node node = 0; /* make compiler happy */
FT_UInt32 hash;
@@ -643,12 +668,12 @@
*ansbit = NULL;
-#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
+#if defined( FT_CONFIG_OPTION_OLD_INTERNALS ) && ( FT_INT_MAX > 0xFFFFU )
/* This one is a major hack used to detect whether we are passed a
* regular FTC_ImageType handle, or a legacy FTC_OldImageDesc one.
*/
- if ( type->width >= 0x10000 )
+ if ( (FT_ULong)type->width >= 0x10000L )
{
FTC_OldImageDesc desc = (FTC_OldImageDesc)type;
@@ -663,10 +688,16 @@
#endif /* FT_CONFIG_OPTION_OLD_INTERNALS */
{
+ if ( (FT_ULong)(type->flags - FT_INT_MIN) > FT_UINT_MAX )
+ {
+ FT_TRACE1(( "FTC_ImageCache_Lookup: higher bits in load_flags" ));
+ FT_TRACE1(( "0x%x are dropped\n", (type->flags & ~((FT_ULong)FT_UINT_MAX)) ));
+ }
+
query.attrs.scaler.face_id = type->face_id;
query.attrs.scaler.width = type->width;
query.attrs.scaler.height = type->height;
- query.attrs.load_flags = type->flags;
+ query.attrs.load_flags = (FT_UInt)type->flags;
}
query.attrs.scaler.pixel = 1;
@@ -690,17 +721,18 @@
hash,
gindex,
FTC_GQUERY( &query ),
- (FTC_Node*)&node );
+ &node );
#endif
if ( error )
goto Exit;
- *ansbit = node->sbits + ( gindex - FTC_GNODE( node )->gindex );
+ *ansbit = FTC_SNODE( node )->sbits +
+ ( gindex - FTC_GNODE( node )->gindex );
if ( anode )
{
- *anode = FTC_NODE( node );
- FTC_NODE( node )->ref_count++;
+ *anode = node;
+ node->ref_count++;
}
Exit:
@@ -720,7 +752,7 @@
{
FT_Error error;
FTC_BasicQueryRec query;
- FTC_SNode node = 0; /* make compiler happy */
+ FTC_Node node = 0; /* make compiler happy */
FT_UInt32 hash;
@@ -733,8 +765,15 @@
*ansbit = NULL;
+ /* FT_Load_Glyph(), FT_Load_Char() take FT_UInt flags */
+ if ( load_flags > FT_UINT_MAX )
+ {
+ FT_TRACE1(( "FTC_ImageCache_LookupScaler: higher bits in load_flags" ));
+ FT_TRACE1(( "0x%x are dropped\n", (load_flags & ~((FT_ULong)FT_UINT_MAX)) ));
+ }
+
query.attrs.scaler = scaler[0];
- query.attrs.load_flags = load_flags;
+ query.attrs.load_flags = (FT_UInt)load_flags;
/* beware, the hash must be the same for all glyph ranges! */
hash = FTC_BASIC_ATTR_HASH( &query.attrs ) +
@@ -750,12 +789,13 @@
if ( error )
goto Exit;
- *ansbit = node->sbits + ( gindex - FTC_GNODE( node )->gindex );
+ *ansbit = FTC_SNODE( node )->sbits +
+ ( gindex - FTC_GNODE( node )->gindex );
if ( anode )
{
- *anode = FTC_NODE( node );
- FTC_NODE( node )->ref_count++;
+ *anode = node;
+ node->ref_count++;
}
Exit:
diff --git a/src/3rdparty/freetype/src/cache/ftccache.c b/src/3rdparty/freetype/src/cache/ftccache.c
index f3e699c385..463addd99b 100644
--- a/src/3rdparty/freetype/src/cache/ftccache.c
+++ b/src/3rdparty/freetype/src/cache/ftccache.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType internal cache interface (body). */
/* */
-/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006, 2007 by */
+/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -24,6 +24,9 @@
#include "ftccback.h"
#include "ftcerror.h"
+#undef FT_COMPONENT
+#define FT_COMPONENT trace_cache
+
#define FTC_HASH_MAX_LOAD 2
#define FTC_HASH_MIN_LOAD 1
@@ -93,9 +96,9 @@
for (;;)
{
FTC_Node node, *pnode;
- FT_UInt p = cache->p;
- FT_UInt mask = cache->mask;
- FT_UInt count = mask + p + 1; /* number of buckets */
+ FT_UFast p = cache->p;
+ FT_UFast mask = cache->mask;
+ FT_UFast count = mask + p + 1; /* number of buckets */
/* do we need to shrink the buckets array? */
@@ -153,7 +156,7 @@
/* do we need to expand the buckets array? */
else if ( cache->slack > (FT_Long)count * FTC_HASH_SUB_LOAD )
{
- FT_UInt old_index = p + mask;
+ FT_UFast old_index = p + mask;
FTC_Node* pold;
@@ -216,7 +219,7 @@
if ( node == NULL )
{
- FT_ERROR(( "ftc_node_hash_unlink: unknown node!\n" ));
+ FT_TRACE0(( "ftc_node_hash_unlink: unknown node\n" ));
return;
}
@@ -273,7 +276,7 @@
/* find node's cache */
if ( node->cache_index >= manager->num_caches )
{
- FT_ERROR(( "ftc_node_destroy: invalid node handle\n" ));
+ FT_TRACE0(( "ftc_node_destroy: invalid node handle\n" ));
return;
}
#endif
@@ -283,7 +286,7 @@
#ifdef FT_DEBUG_ERROR
if ( cache == NULL )
{
- FT_ERROR(( "ftc_node_destroy: invalid node handle\n" ));
+ FT_TRACE0(( "ftc_node_destroy: invalid node handle\n" ));
return;
}
#endif
@@ -302,7 +305,7 @@
#if 0
/* check, just in case of general corruption :-) */
if ( manager->num_nodes == 0 )
- FT_ERROR(( "ftc_node_destroy: invalid cache node count! = %d\n",
+ FT_TRACE0(( "ftc_node_destroy: invalid cache node count (%d)\n",
manager->num_nodes ));
#endif
}
@@ -347,7 +350,7 @@
{
FTC_Manager manager = cache->manager;
FT_UFast i;
- FT_UInt count;
+ FT_UFast count;
count = cache->p + cache->mask + 1;
diff --git a/src/3rdparty/freetype/src/cache/ftccache.h b/src/3rdparty/freetype/src/cache/ftccache.h
index 8c0a7c94fe..2082bc4f4f 100644
--- a/src/3rdparty/freetype/src/cache/ftccache.h
+++ b/src/3rdparty/freetype/src/cache/ftccache.h
@@ -4,7 +4,7 @@
/* */
/* FreeType internal cache interface (specification). */
/* */
-/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006, 2007 by */
+/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -91,7 +91,7 @@ FT_BEGIN_HEADER
FT_Pointer query,
FTC_Cache cache );
- typedef FT_ULong
+ typedef FT_Offset
(*FTC_Node_WeightFunc)( FTC_Node node,
FTC_Cache cache );
@@ -121,7 +121,7 @@ FT_BEGIN_HEADER
FTC_Node_CompareFunc node_remove_faceid;
FTC_Node_FreeFunc node_free;
- FT_UInt cache_size;
+ FT_Offset cache_size;
FTC_Cache_InitFunc cache_init;
FTC_Cache_DoneFunc cache_done;
@@ -202,7 +202,7 @@ FT_BEGIN_HEADER
FTC_Cache _cache = FTC_CACHE(cache); \
FT_UInt32 _hash = (FT_UInt32)(hash); \
FTC_Node_CompareFunc _nodcomp = (FTC_Node_CompareFunc)(nodecmp); \
- FT_UInt _idx; \
+ FT_UFast _idx; \
\
\
error = 0; \
@@ -246,8 +246,7 @@ FT_BEGIN_HEADER
error = FTC_Cache_NewNode( _cache, _hash, query, &_node ); \
\
_Ok: \
- _pnode = (FTC_Node*)(void*)&(node); \
- *_pnode = _node; \
+ node = _node; \
FT_END_STMNT
#else /* !FTC_INLINE */
diff --git a/src/3rdparty/freetype/src/cache/ftccback.h b/src/3rdparty/freetype/src/cache/ftccback.h
index 86e72a7514..4d0818db27 100644
--- a/src/3rdparty/freetype/src/cache/ftccback.h
+++ b/src/3rdparty/freetype/src/cache/ftccback.h
@@ -36,7 +36,7 @@
FT_Pointer gquery,
FTC_Cache cache );
- FT_LOCAL( FT_ULong )
+ FT_LOCAL( FT_Offset )
ftc_inode_weight( FTC_Node inode,
FTC_Cache cache );
@@ -50,7 +50,7 @@
FT_Pointer gquery,
FTC_Cache cache );
- FT_LOCAL( FT_ULong )
+ FT_LOCAL( FT_Offset )
ftc_snode_weight( FTC_Node snode,
FTC_Cache cache );
diff --git a/src/3rdparty/freetype/src/cache/ftccmap.c b/src/3rdparty/freetype/src/cache/ftccmap.c
index 4c6a7fd960..a802b0557c 100644
--- a/src/3rdparty/freetype/src/cache/ftccmap.c
+++ b/src/3rdparty/freetype/src/cache/ftccmap.c
@@ -4,7 +4,7 @@
/* */
/* FreeType CharMap cache (body) */
/* */
-/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -22,7 +22,6 @@
#include "ftcmanag.h"
#include FT_INTERNAL_MEMORY_H
#include FT_INTERNAL_DEBUG_H
-#include FT_TRUETYPE_IDS_H
#include "ftccback.h"
#include "ftcerror.h"
@@ -86,9 +85,9 @@
#define FTC_CMAP_INDICES_MAX 128
/* compute a query/node hash */
-#define FTC_CMAP_HASH( faceid, index, charcode ) \
- ( FTC_FACE_ID_HASH( faceid ) + 211 * ( index ) + \
- ( (char_code) / FTC_CMAP_INDICES_MAX ) )
+#define FTC_CMAP_HASH( faceid, index, charcode ) \
+ ( FTC_FACE_ID_HASH( faceid ) + 211 * (index) + \
+ ( (charcode) / FTC_CMAP_INDICES_MAX ) )
/* the charmap query */
typedef struct FTC_CMapQueryRec_
@@ -175,7 +174,7 @@
/* compute the weight of a given cmap node */
- FT_CALLBACK_DEF( FT_ULong )
+ FT_CALLBACK_DEF( FT_Offset )
ftc_cmap_node_weight( FTC_Node cnode,
FTC_Cache cache )
{
@@ -284,7 +283,7 @@
{
FTC_Cache cache = FTC_CACHE( cmap_cache );
FTC_CMapQueryRec query;
- FTC_CMapNode node;
+ FTC_Node node;
FT_Error error;
FT_UInt gindex = 0;
FT_UInt32 hash;
@@ -304,7 +303,7 @@
if ( !cache )
{
- FT_ERROR(( "FTC_CMapCache_Lookup: bad arguments, returning 0!\n" ));
+ FT_TRACE0(( "FTC_CMapCache_Lookup: bad arguments, returning 0\n" ));
return 0;
}
@@ -374,18 +373,21 @@
FTC_CACHE_LOOKUP_CMP( cache, ftc_cmap_node_compare, hash, &query,
node, error );
#else
- error = FTC_Cache_Lookup( cache, hash, &query, (FTC_Node*) &node );
+ error = FTC_Cache_Lookup( cache, hash, &query, &node );
#endif
if ( error )
goto Exit;
- FT_ASSERT( (FT_UInt)( char_code - node->first ) < FTC_CMAP_INDICES_MAX );
+ FT_ASSERT( (FT_UInt)( char_code - FTC_CMAP_NODE( node )->first ) <
+ FTC_CMAP_INDICES_MAX );
/* something rotten can happen with rogue clients */
- if ( (FT_UInt)( char_code - node->first >= FTC_CMAP_INDICES_MAX ) )
+ if ( (FT_UInt)( char_code - FTC_CMAP_NODE( node )->first >=
+ FTC_CMAP_INDICES_MAX ) )
return 0;
- gindex = node->indices[char_code - node->first];
+ gindex = FTC_CMAP_NODE( node )->indices[char_code -
+ FTC_CMAP_NODE( node )->first];
if ( gindex == FTC_CMAP_UNKNOWN )
{
FT_Face face;
@@ -393,7 +395,9 @@
gindex = 0;
- error = FTC_Manager_LookupFace( cache->manager, node->face_id, &face );
+ error = FTC_Manager_LookupFace( cache->manager,
+ FTC_CMAP_NODE( node )->face_id,
+ &face );
if ( error )
goto Exit;
@@ -414,7 +418,9 @@
FT_Set_Charmap( face, old );
}
- node->indices[char_code - node->first] = (FT_UShort)gindex;
+ FTC_CMAP_NODE( node )->indices[char_code -
+ FTC_CMAP_NODE( node )->first]
+ = (FT_UShort)gindex;
}
Exit:
diff --git a/src/3rdparty/freetype/src/cache/ftcglyph.c b/src/3rdparty/freetype/src/cache/ftcglyph.c
index 5c03abe055..a9ab0c319f 100644
--- a/src/3rdparty/freetype/src/cache/ftcglyph.c
+++ b/src/3rdparty/freetype/src/cache/ftcglyph.c
@@ -4,7 +4,7 @@
/* */
/* FreeType Glyph Image (FT_Glyph) cache (body). */
/* */
-/* Copyright 2000-2001, 2003, 2004, 2006 by */
+/* Copyright 2000-2001, 2003, 2004, 2006, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -20,8 +20,6 @@
#include FT_CACHE_H
#include "ftcglyph.h"
#include FT_ERRORS_H
-#include FT_INTERNAL_OBJECTS_H
-#include FT_INTERNAL_DEBUG_H
#include "ftccback.h"
#include "ftcerror.h"
@@ -73,8 +71,8 @@
FT_UNUSED( cache );
- return FT_BOOL( gnode->family == gquery->family &&
- gnode->gindex == gquery->gindex );
+ return FT_BOOL( gnode->family == gquery->family &&
+ gnode->gindex == gquery->gindex );
}
diff --git a/src/3rdparty/freetype/src/cache/ftcglyph.h b/src/3rdparty/freetype/src/cache/ftcglyph.h
index 87a4199bfd..c18f9c3af3 100644
--- a/src/3rdparty/freetype/src/cache/ftcglyph.h
+++ b/src/3rdparty/freetype/src/cache/ftcglyph.h
@@ -277,12 +277,14 @@ FT_BEGIN_HEADER
FTC_GCache _gcache = FTC_GCACHE( cache ); \
FTC_GQuery _gquery = (FTC_GQuery)( query ); \
FTC_MruNode_CompareFunc _fcompare = (FTC_MruNode_CompareFunc)(famcmp); \
+ FTC_MruNode _mrunode; \
\
\
_gquery->gindex = (gindex); \
\
FTC_MRULIST_LOOKUP_CMP( &_gcache->families, _gquery, _fcompare, \
- _gquery->family, error ); \
+ _mrunode, error ); \
+ _gquery->family = FTC_FAMILY( _mrunode ); \
if ( !error ) \
{ \
FTC_Family _gqfamily = _gquery->family; \
@@ -303,11 +305,10 @@ FT_BEGIN_HEADER
#define FTC_GCACHE_LOOKUP_CMP( cache, famcmp, nodecmp, hash, \
gindex, query, node, error ) \
FT_BEGIN_STMNT \
- void* _n = &(node); \
- \
\
error = FTC_GCache_Lookup( FTC_GCACHE( cache ), hash, gindex, \
- FTC_GQUERY( query ), (FTC_Node*)_n ); \
+ FTC_GQUERY( query ), node ); \
+ \
FT_END_STMNT
#endif /* !FTC_INLINE */
diff --git a/src/3rdparty/freetype/src/cache/ftcimage.c b/src/3rdparty/freetype/src/cache/ftcimage.c
index 15d4e80c8c..417daf2aae 100644
--- a/src/3rdparty/freetype/src/cache/ftcimage.c
+++ b/src/3rdparty/freetype/src/cache/ftcimage.c
@@ -103,12 +103,12 @@
}
- FT_LOCAL_DEF( FT_ULong )
+ FT_LOCAL_DEF( FT_Offset )
ftc_inode_weight( FTC_Node ftcinode,
FTC_Cache ftccache )
{
FTC_INode inode = (FTC_INode)ftcinode;
- FT_ULong size = 0;
+ FT_Offset size = 0;
FT_Glyph glyph = inode->glyph;
FT_UNUSED( ftccache );
@@ -151,7 +151,7 @@
#if 0
- FT_LOCAL_DEF( FT_ULong )
+ FT_LOCAL_DEF( FT_Offset )
FTC_INode_Weight( FTC_INode inode )
{
return ftc_inode_weight( FTC_NODE( inode ), NULL );
diff --git a/src/3rdparty/freetype/src/cache/ftcmanag.c b/src/3rdparty/freetype/src/cache/ftcmanag.c
index 4d44094ce3..f2a298e7d9 100644
--- a/src/3rdparty/freetype/src/cache/ftcmanag.c
+++ b/src/3rdparty/freetype/src/cache/ftcmanag.c
@@ -26,6 +26,10 @@
#include "ftccback.h"
#include "ftcerror.h"
+#ifdef FT_CONFIG_OPTION_PIC
+#error "cache system does not support PIC yet"
+#endif
+
#undef FT_COMPONENT
#define FT_COMPONENT trace_cache
@@ -78,6 +82,8 @@
} FTC_SizeNodeRec, *FTC_SizeNode;
+#define FTC_SIZE_NODE( x ) ( (FTC_SizeNode)( x ) )
+
FT_CALLBACK_DEF( void )
ftc_size_node_done( FTC_MruNode ftcnode,
@@ -176,8 +182,8 @@
FTC_Scaler scaler,
FT_Size *asize )
{
- FT_Error error;
- FTC_SizeNode node;
+ FT_Error error;
+ FTC_MruNode mrunode;
if ( asize == NULL )
@@ -191,14 +197,14 @@
#ifdef FTC_INLINE
FTC_MRULIST_LOOKUP_CMP( &manager->sizes, scaler, ftc_size_node_compare,
- node, error );
+ mrunode, error );
#else
- error = FTC_MruList_Lookup( &manager->sizes, scaler, (FTC_MruNode*)&node );
+ error = FTC_MruList_Lookup( &manager->sizes, scaler, &mrunode );
#endif
if ( !error )
- *asize = node->size;
+ *asize = FTC_SIZE_NODE( mrunode )->size;
return error;
}
@@ -220,6 +226,8 @@
} FTC_FaceNodeRec, *FTC_FaceNode;
+#define FTC_FACE_NODE( x ) ( ( FTC_FaceNode )( x ) )
+
FT_CALLBACK_DEF( FT_Error )
ftc_face_node_init( FTC_MruNode ftcnode,
@@ -301,8 +309,8 @@
FTC_FaceID face_id,
FT_Face *aface )
{
- FT_Error error;
- FTC_FaceNode node;
+ FT_Error error;
+ FTC_MruNode mrunode;
if ( aface == NULL )
@@ -317,14 +325,14 @@
#ifdef FTC_INLINE
FTC_MRULIST_LOOKUP_CMP( &manager->faces, face_id, ftc_face_node_compare,
- node, error );
+ mrunode, error );
#else
- error = FTC_MruList_Lookup( &manager->faces, face_id, (FTC_MruNode*)&node );
+ error = FTC_MruList_Lookup( &manager->faces, face_id, &mrunode );
#endif
if ( !error )
- *aface = node->face;
+ *aface = FTC_FACE_NODE( mrunode )->face;
return error;
}
@@ -476,8 +484,8 @@
if ( (FT_UInt)node->cache_index >= manager->num_caches )
- FT_ERROR(( "FTC_Manager_Check: invalid node (cache index = %ld\n",
- node->cache_index ));
+ FT_TRACE0(( "FTC_Manager_Check: invalid node (cache index = %ld\n",
+ node->cache_index ));
else
weight += cache->clazz.node_weight( node, cache );
@@ -486,8 +494,8 @@
} while ( node != first );
if ( weight != manager->cur_weight )
- FT_ERROR(( "FTC_Manager_Check: invalid weight %ld instead of %ld\n",
- manager->cur_weight, weight ));
+ FT_TRACE0(( "FTC_Manager_Check: invalid weight %ld instead of %ld\n",
+ manager->cur_weight, weight ));
}
/* check circular list */
@@ -505,9 +513,9 @@
} while ( node != first );
if ( count != manager->num_nodes )
- FT_ERROR((
- "FTC_Manager_Check: invalid cache node count %d instead of %d\n",
- manager->num_nodes, count ));
+ FT_TRACE0(( "FTC_Manager_Check:"
+ " invalid cache node count %d instead of %d\n",
+ manager->num_nodes, count ));
}
}
@@ -534,9 +542,9 @@
#ifdef FT_DEBUG_ERROR
FTC_Manager_Check( manager );
- FT_ERROR(( "compressing, weight = %ld, max = %ld, nodes = %d\n",
- manager->cur_weight, manager->max_weight,
- manager->num_nodes ));
+ FT_TRACE0(( "compressing, weight = %ld, max = %ld, nodes = %d\n",
+ manager->cur_weight, manager->max_weight,
+ manager->num_nodes ));
#endif
if ( manager->cur_weight < manager->max_weight || first == NULL )
@@ -579,8 +587,8 @@
if ( manager->num_caches >= FTC_MAX_CACHES )
{
error = FTC_Err_Too_Many_Caches;
- FT_ERROR(( "%s: too many registered caches\n",
- "FTC_Manager_Register_Cache" ));
+ FT_ERROR(( "FTC_Manager_RegisterCache:"
+ " too many registered caches\n" ));
goto Exit;
}
@@ -661,7 +669,9 @@
/* this will remove all FTC_SizeNode that correspond to
* the face_id as well
*/
- FTC_MruList_RemoveSelection( &manager->faces, NULL, face_id );
+ FTC_MruList_RemoveSelection( &manager->faces,
+ (FTC_MruNode_CompareFunc)NULL,
+ face_id );
for ( nn = 0; nn < manager->num_caches; nn++ )
FTC_Cache_RemoveFaceID( manager->caches[nn], face_id );
diff --git a/src/3rdparty/freetype/src/cache/ftcmru.c b/src/3rdparty/freetype/src/cache/ftcmru.c
index 3a6c625afa..9944b58980 100644
--- a/src/3rdparty/freetype/src/cache/ftcmru.c
+++ b/src/3rdparty/freetype/src/cache/ftcmru.c
@@ -4,7 +4,7 @@
/* */
/* FreeType MRU support (body). */
/* */
-/* Copyright 2003, 2004, 2006 by */
+/* Copyright 2003, 2004, 2006, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -46,7 +46,7 @@
{
if ( cnode == node )
{
- fprintf( stderr, "FTC_MruNode_Prepend: invalid action!\n" );
+ fprintf( stderr, "FTC_MruNode_Prepend: invalid action\n" );
exit( 2 );
}
cnode = cnode->next;
@@ -94,7 +94,7 @@
} while ( cnode != first );
- fprintf( stderr, "FTC_MruNode_Up: invalid action!\n" );
+ fprintf( stderr, "FTC_MruNode_Up: invalid action\n" );
exit( 2 );
Ok:
}
@@ -141,7 +141,7 @@
} while ( cnode != first );
- fprintf( stderr, "FTC_MruNode_Remove: invalid action!\n" );
+ fprintf( stderr, "FTC_MruNode_Remove: invalid action\n" );
exit( 2 );
Ok:
}
diff --git a/src/3rdparty/freetype/src/cache/ftcmru.h b/src/3rdparty/freetype/src/cache/ftcmru.h
index c8f0c6ef6e..5739439f45 100644
--- a/src/3rdparty/freetype/src/cache/ftcmru.h
+++ b/src/3rdparty/freetype/src/cache/ftcmru.h
@@ -107,7 +107,7 @@ FT_BEGIN_HEADER
typedef struct FTC_MruListClassRec_
{
- FT_UInt node_size;
+ FT_Offset node_size;
FTC_MruNode_CompareFunc node_compare;
FTC_MruNode_InitFunc node_init;
FTC_MruNode_ResetFunc node_reset;
@@ -163,7 +163,7 @@ FT_BEGIN_HEADER
FT_BEGIN_STMNT \
FTC_MruNode* _pfirst = &(list)->nodes; \
FTC_MruNode_CompareFunc _compare = (FTC_MruNode_CompareFunc)(compare); \
- FTC_MruNode _first, _node, *_pnode; \
+ FTC_MruNode _first, _node; \
\
\
error = 0; \
@@ -180,8 +180,7 @@ FT_BEGIN_HEADER
if ( _node != _first ) \
FTC_MruNode_Up( _pfirst, _node ); \
\
- _pnode = (FTC_MruNode*)(void*)&(node); \
- *_pnode = _node; \
+ node = _node; \
goto _MruOk; \
} \
_node = _node->next; \
diff --git a/src/3rdparty/freetype/src/cache/ftcsbits.c b/src/3rdparty/freetype/src/cache/ftcsbits.c
index 72f139d565..60d46aa7a0 100644
--- a/src/3rdparty/freetype/src/cache/ftcsbits.c
+++ b/src/3rdparty/freetype/src/cache/ftcsbits.c
@@ -4,7 +4,7 @@
/* */
/* FreeType sbits manager (body). */
/* */
-/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006 by */
+/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -26,6 +26,9 @@
#include "ftccback.h"
#include "ftcerror.h"
+#undef FT_COMPONENT
+#define FT_COMPONENT trace_cache
+
/*************************************************************************/
/*************************************************************************/
@@ -129,13 +132,13 @@
FT_Int temp;
FT_GlyphSlot slot = face->glyph;
FT_Bitmap* bitmap = &slot->bitmap;
- FT_Int xadvance, yadvance;
+ FT_Pos xadvance, yadvance; /* FT_GlyphSlot->advance.{x|y} */
if ( slot->format != FT_GLYPH_FORMAT_BITMAP )
{
- FT_ERROR(( "%s: glyph loaded didn't return a bitmap!\n",
- "ftc_snode_load" ));
+ FT_TRACE0(( "ftc_snode_load:"
+ " glyph loaded didn't return a bitmap\n" ));
goto BadGlyph;
}
@@ -263,7 +266,7 @@
}
- FT_LOCAL_DEF( FT_ULong )
+ FT_LOCAL_DEF( FT_Offset )
ftc_snode_weight( FTC_Node ftcsnode,
FTC_Cache cache )
{
@@ -271,7 +274,7 @@
FT_UInt count = snode->count;
FTC_SBit sbit = snode->sbits;
FT_Int pitch;
- FT_ULong size;
+ FT_Offset size;
FT_UNUSED( cache );
@@ -300,7 +303,7 @@
#if 0
- FT_LOCAL_DEF( FT_ULong )
+ FT_LOCAL_DEF( FT_Offset )
FTC_SNode_Weight( FTC_SNode snode )
{
return ftc_snode_weight( FTC_NODE( snode ), NULL );
diff --git a/src/3rdparty/freetype/src/cff/Jamfile b/src/3rdparty/freetype/src/cff/Jamfile
index 6d0bb1b867..6705d3cfdb 100644
--- a/src/3rdparty/freetype/src/cff/Jamfile
+++ b/src/3rdparty/freetype/src/cff/Jamfile
@@ -16,7 +16,7 @@ SubDir FT2_TOP $(FT2_SRC_DIR) cff ;
if $(FT2_MULTI)
{
- _sources = cffdrivr cffgload cffload cffobjs cffparse cffcmap ;
+ _sources = cffdrivr cffgload cffload cffobjs cffparse cffcmap cffpic ;
}
else
{
diff --git a/src/3rdparty/freetype/src/cff/cff.c b/src/3rdparty/freetype/src/cff/cff.c
index e6d8954c9a..fccfd442f5 100644
--- a/src/3rdparty/freetype/src/cff/cff.c
+++ b/src/3rdparty/freetype/src/cff/cff.c
@@ -19,6 +19,7 @@
#define FT_MAKE_OPTION_SINGLE_OBJECT
#include <ft2build.h>
+#include "cffpic.c"
#include "cffdrivr.c"
#include "cffparse.c"
#include "cffload.c"
diff --git a/src/3rdparty/freetype/src/cff/cffcmap.c b/src/3rdparty/freetype/src/cff/cffcmap.c
index 578d048bed..46d603e3a8 100644
--- a/src/3rdparty/freetype/src/cff/cffcmap.c
+++ b/src/3rdparty/freetype/src/cff/cffcmap.c
@@ -65,7 +65,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
cff_cmap_encoding_char_next( CFF_CMapStd cmap,
FT_UInt32 *pchar_code )
{
@@ -99,9 +99,7 @@
}
- FT_CALLBACK_TABLE_DEF const FT_CMap_ClassRec
- cff_cmap_encoding_class_rec =
- {
+ FT_DEFINE_CMAP_CLASS(cff_cmap_encoding_class_rec,
sizeof ( CFF_CMapStdRec ),
(FT_CMap_InitFunc) cff_cmap_encoding_init,
@@ -110,7 +108,7 @@
(FT_CMap_CharNextFunc) cff_cmap_encoding_char_next,
NULL, NULL, NULL, NULL, NULL
- };
+ )
/*************************************************************************/
@@ -194,7 +192,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
cff_cmap_unicode_char_next( PS_Unicodes unicodes,
FT_UInt32 *pchar_code )
{
@@ -207,9 +205,7 @@
}
- FT_CALLBACK_TABLE_DEF const FT_CMap_ClassRec
- cff_cmap_unicode_class_rec =
- {
+ FT_DEFINE_CMAP_CLASS(cff_cmap_unicode_class_rec,
sizeof ( PS_UnicodesRec ),
(FT_CMap_InitFunc) cff_cmap_unicode_init,
@@ -218,7 +214,6 @@
(FT_CMap_CharNextFunc) cff_cmap_unicode_char_next,
NULL, NULL, NULL, NULL, NULL
- };
-
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/cff/cffcmap.h b/src/3rdparty/freetype/src/cff/cffcmap.h
index 3809b85611..3f7f67bbe0 100644
--- a/src/3rdparty/freetype/src/cff/cffcmap.h
+++ b/src/3rdparty/freetype/src/cff/cffcmap.h
@@ -43,8 +43,7 @@ FT_BEGIN_HEADER
} CFF_CMapStdRec;
- FT_CALLBACK_TABLE const FT_CMap_ClassRec
- cff_cmap_encoding_class_rec;
+ FT_DECLARE_CMAP_CLASS(cff_cmap_encoding_class_rec)
/*************************************************************************/
@@ -57,8 +56,7 @@ FT_BEGIN_HEADER
/* unicode (synthetic) cmaps */
- FT_CALLBACK_TABLE const FT_CMap_ClassRec
- cff_cmap_unicode_class_rec;
+ FT_DECLARE_CMAP_CLASS(cff_cmap_unicode_class_rec)
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/cff/cffdrivr.c b/src/3rdparty/freetype/src/cff/cffdrivr.c
index 3dd86f2aa8..dad0b65d8b 100644
--- a/src/3rdparty/freetype/src/cff/cffdrivr.c
+++ b/src/3rdparty/freetype/src/cff/cffdrivr.c
@@ -21,7 +21,6 @@
#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_STREAM_H
#include FT_INTERNAL_SFNT_H
-#include FT_TRUETYPE_IDS_H
#include FT_SERVICE_CID_H
#include FT_SERVICE_POSTSCRIPT_CMAPS_H
#include FT_SERVICE_POSTSCRIPT_INFO_H
@@ -32,8 +31,10 @@
#include "cffgload.h"
#include "cffload.h"
#include "cffcmap.h"
+#include "cffparse.h"
#include "cfferrs.h"
+#include "cffpic.h"
#include FT_SERVICE_XFREE86_NAME_H
#include FT_SERVICE_GLYPH_DICT_H
@@ -199,7 +200,7 @@
FT_GlyphSlot slot = face->glyph;
- flags |= FT_LOAD_ADVANCE_ONLY;
+ flags |= (FT_UInt32)FT_LOAD_ADVANCE_ONLY;
for ( nn = 0; nn < count; nn++ )
{
@@ -238,10 +239,10 @@
FT_FACE_FIND_GLOBAL_SERVICE( face, psnames, POSTSCRIPT_CMAPS );
if ( !psnames )
{
- FT_ERROR(( "cff_get_glyph_name:" ));
- FT_ERROR(( " cannot get glyph name from CFF & CEF fonts\n" ));
- FT_ERROR(( " " ));
- FT_ERROR(( " without the `PSNames' module\n" ));
+ FT_ERROR(( "cff_get_glyph_name:"
+ " cannot get glyph name from CFF & CEF fonts\n"
+ " "
+ " without the `PSNames' module\n" ));
error = CFF_Err_Unknown_File_Format;
goto Exit;
}
@@ -309,11 +310,10 @@
}
- static const FT_Service_GlyphDictRec cff_service_glyph_dict =
- {
+ FT_DEFINE_SERVICE_GLYPHDICTREC(cff_service_glyph_dict,
(FT_GlyphDict_GetNameFunc) cff_get_glyph_name,
- (FT_GlyphDict_NameIndexFunc)cff_get_name_index,
- };
+ (FT_GlyphDict_NameIndexFunc)cff_get_name_index
+ )
/*
@@ -378,13 +378,12 @@
}
- static const FT_Service_PsInfoRec cff_service_ps_info =
- {
+ FT_DEFINE_SERVICE_PSINFOREC(cff_service_ps_info,
(PS_GetFontInfoFunc) cff_ps_get_font_info,
(PS_GetFontExtraFunc) NULL,
(PS_HasGlyphNamesFunc) cff_ps_has_glyph_names,
(PS_GetFontPrivateFunc)NULL /* unsupported with CFF fonts */
- };
+ )
/*
@@ -402,10 +401,9 @@
}
- static const FT_Service_PsFontNameRec cff_service_ps_name =
- {
+ FT_DEFINE_SERVICE_PSFONTNAMEREC(cff_service_ps_name,
(FT_PsName_GetFunc)cff_get_ps_name
- };
+ )
/*
@@ -424,16 +422,16 @@
{
FT_CMap cmap = FT_CMAP( charmap );
FT_Error error = CFF_Err_Ok;
+ FT_Face face = FT_CMAP_FACE( cmap );
+ FT_Library library = FT_FACE_LIBRARY( face );
cmap_info->language = 0;
cmap_info->format = 0;
- if ( cmap->clazz != &cff_cmap_encoding_class_rec &&
- cmap->clazz != &cff_cmap_unicode_class_rec )
+ if ( cmap->clazz != &FT_CFF_CMAP_ENCODING_CLASS_REC_GET &&
+ cmap->clazz != &FT_CFF_CMAP_UNICODE_CLASS_REC_GET )
{
- FT_Face face = FT_CMAP_FACE( cmap );
- FT_Library library = FT_FACE_LIBRARY( face );
FT_Module sfnt = FT_Get_Module( library, "sfnt" );
FT_Service_TTCMaps service =
(FT_Service_TTCMaps)ft_module_get_service( sfnt,
@@ -448,10 +446,9 @@
}
- static const FT_Service_TTCMapsRec cff_service_get_cmap_info =
- {
+ FT_DEFINE_SERVICE_TTCMAPSREC(cff_service_get_cmap_info,
(TT_CMap_Info_GetFunc)cff_get_cmap_info
- };
+ )
/*
@@ -498,8 +495,19 @@
*ordering = cff->ordering;
}
+ /*
+ * XXX: According to Adobe TechNote #5176, the supplement in CFF
+ * can be a real number. We truncate it to fit public API
+ * since freetype-2.3.6.
+ */
if ( supplement )
- *supplement = dict->cid_supplement;
+ {
+ if ( dict->cid_supplement < FT_INT_MIN ||
+ dict->cid_supplement > FT_INT_MAX )
+ FT_TRACE1(( "cff_get_ros: too large supplement %d is truncated\n",
+ dict->cid_supplement ));
+ *supplement = (FT_Int)dict->cid_supplement;
+ }
}
Fail:
@@ -570,12 +578,11 @@
}
- static const FT_Service_CIDRec cff_service_cid_info =
- {
+ FT_DEFINE_SERVICE_CIDREC(cff_service_cid_info,
(FT_CID_GetRegistryOrderingSupplementFunc)cff_get_ros,
(FT_CID_GetIsInternallyCIDKeyedFunc) cff_get_is_cid,
(FT_CID_GetCIDFromGlyphIndexFunc) cff_get_cid_from_glyph_index
- };
+ )
/*************************************************************************/
@@ -589,20 +596,24 @@
/*************************************************************************/
/*************************************************************************/
/*************************************************************************/
-
- static const FT_ServiceDescRec cff_services[] =
- {
- { FT_SERVICE_ID_XF86_NAME, FT_XF86_FORMAT_CFF },
- { FT_SERVICE_ID_POSTSCRIPT_INFO, &cff_service_ps_info },
- { FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &cff_service_ps_name },
#ifndef FT_CONFIG_OPTION_NO_GLYPH_NAMES
- { FT_SERVICE_ID_GLYPH_DICT, &cff_service_glyph_dict },
+ FT_DEFINE_SERVICEDESCREC6(cff_services,
+ FT_SERVICE_ID_XF86_NAME, FT_XF86_FORMAT_CFF,
+ FT_SERVICE_ID_POSTSCRIPT_INFO, &FT_CFF_SERVICE_PS_INFO_GET,
+ FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &FT_CFF_SERVICE_PS_NAME_GET,
+ FT_SERVICE_ID_GLYPH_DICT, &FT_CFF_SERVICE_GLYPH_DICT_GET,
+ FT_SERVICE_ID_TT_CMAP, &FT_CFF_SERVICE_GET_CMAP_INFO_GET,
+ FT_SERVICE_ID_CID, &FT_CFF_SERVICE_CID_INFO_GET
+ )
+#else
+ FT_DEFINE_SERVICEDESCREC5(cff_services,
+ FT_SERVICE_ID_XF86_NAME, FT_XF86_FORMAT_CFF,
+ FT_SERVICE_ID_POSTSCRIPT_INFO, &FT_CFF_SERVICE_PS_INFO_GET,
+ FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &FT_CFF_SERVICE_PS_NAME_GET,
+ FT_SERVICE_ID_TT_CMAP, &FT_CFF_SERVICE_GET_CMAP_INFO_GET,
+ FT_SERVICE_ID_CID, &FT_CFF_SERVICE_CID_INFO_GET
+ )
#endif
- { FT_SERVICE_ID_TT_CMAP, &cff_service_get_cmap_info },
- { FT_SERVICE_ID_CID, &cff_service_cid_info },
- { NULL, NULL }
- };
-
FT_CALLBACK_DEF( FT_Module_Interface )
cff_get_interface( FT_Module driver, /* CFF_Driver */
@@ -612,10 +623,13 @@
FT_Module_Interface result;
- result = ft_service_list_lookup( cff_services, module_interface );
+ result = ft_service_list_lookup( FT_CFF_SERVICES_GET, module_interface );
if ( result != NULL )
return result;
+ if ( !driver )
+ return NULL;
+
/* we pass our request to the `sfnt' module */
sfnt = FT_Get_Module( driver->library, "sfnt" );
@@ -625,11 +639,13 @@
/* The FT_DriverInterface structure is defined in ftdriver.h. */
- FT_CALLBACK_TABLE_DEF
- const FT_Driver_ClassRec cff_driver_class =
- {
- /* begin with the FT_Module_Class fields */
- {
+#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
+#define CFF_SIZE_SELECT cff_size_select
+#else
+#define CFF_SIZE_SELECT 0
+#endif
+
+ FT_DEFINE_DRIVER(cff_driver_class,
FT_MODULE_FONT_DRIVER |
FT_MODULE_DRIVER_SCALABLE |
FT_MODULE_DRIVER_HAS_HINTER,
@@ -644,7 +660,6 @@
cff_driver_init,
cff_driver_done,
cff_get_interface,
- },
/* now the specific driver fields */
sizeof( TT_FaceRec ),
@@ -658,10 +673,8 @@
cff_slot_init,
cff_slot_done,
-#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
- ft_stub_set_char_sizes,
- ft_stub_set_pixel_sizes,
-#endif
+ ft_stub_set_char_sizes, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ ft_stub_set_pixel_sizes, /* FT_CONFIG_OPTION_OLD_INTERNALS */
Load_Glyph,
@@ -671,12 +684,8 @@
cff_size_request,
-#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
- cff_size_select
-#else
- 0 /* FT_Size_SelectFunc */
-#endif
- };
+ CFF_SIZE_SELECT
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/cff/cffdrivr.h b/src/3rdparty/freetype/src/cff/cffdrivr.h
index 553848c0a9..50e8138701 100644
--- a/src/3rdparty/freetype/src/cff/cffdrivr.h
+++ b/src/3rdparty/freetype/src/cff/cffdrivr.h
@@ -27,8 +27,7 @@
FT_BEGIN_HEADER
- FT_CALLBACK_TABLE
- const FT_Driver_ClassRec cff_driver_class;
+ FT_DECLARE_DRIVER( cff_driver_class )
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/cff/cffgload.c b/src/3rdparty/freetype/src/cff/cffgload.c
index 2718a277b4..9330c05882 100644
--- a/src/3rdparty/freetype/src/cff/cffgload.c
+++ b/src/3rdparty/freetype/src/cff/cffgload.c
@@ -4,7 +4,8 @@
/* */
/* OpenType Glyph Loader (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, */
+/* 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -18,11 +19,9 @@
#include <ft2build.h>
#include FT_INTERNAL_DEBUG_H
-#include FT_INTERNAL_CALC_H
#include FT_INTERNAL_STREAM_H
#include FT_INTERNAL_SFNT_H
#include FT_OUTLINE_H
-#include FT_TRUETYPE_TAGS_H
#include FT_INTERNAL_POSTSCRIPT_HINTS_H
#include "cffobjs.h"
@@ -115,6 +114,9 @@
cff_op_closepath,
cff_op_callothersubr,
cff_op_pop,
+ cff_op_seac,
+ cff_op_sbw,
+ cff_op_setcurrentpoint,
/* do not remove */
cff_op_max
@@ -203,7 +205,10 @@
2, /* hsbw */
0,
0,
- 0
+ 0,
+ 5, /* seac */
+ 4, /* sbw */
+ 2 /* setcurrentpoint */
};
@@ -321,17 +326,23 @@
/* subroutines. */
/* */
/* <Input> */
- /* num_subrs :: The number of glyph subroutines. */
+ /* in_charstring_type :: The `CharstringType' value of the top DICT */
+ /* dictionary. */
+ /* */
+ /* num_subrs :: The number of glyph subroutines. */
/* */
/* <Return> */
/* The bias value. */
static FT_Int
- cff_compute_bias( FT_UInt num_subrs )
+ cff_compute_bias( FT_Int in_charstring_type,
+ FT_UInt num_subrs )
{
FT_Int result;
- if ( num_subrs < 1240 )
+ if ( in_charstring_type == 1 )
+ result = 0;
+ else if ( num_subrs < 1240 )
result = 107;
else if ( num_subrs < 33900U )
result = 1131;
@@ -382,9 +393,12 @@
cff_builder_init( &decoder->builder, face, size, slot, hinting );
/* initialize Type2 decoder */
+ decoder->cff = cff;
decoder->num_globals = cff->num_global_subrs;
decoder->globals = cff->global_subrs;
- decoder->globals_bias = cff_compute_bias( decoder->num_globals );
+ decoder->globals_bias = cff_compute_bias(
+ cff->top_font.font_dict.charstring_type,
+ decoder->num_globals );
decoder->hint_mode = hint_mode;
}
@@ -436,7 +450,9 @@
decoder->num_locals = sub->num_local_subrs;
decoder->locals = sub->local_subrs;
- decoder->locals_bias = cff_compute_bias( decoder->num_locals );
+ decoder->locals_bias = cff_compute_bias(
+ decoder->cff->top_font.font_dict.charstring_type,
+ decoder->num_locals );
decoder->glyph_width = sub->private_dict.default_width;
decoder->nominal_width = sub->private_dict.nominal_width;
@@ -474,8 +490,6 @@
point->x = x >> 16;
point->y = y >> 16;
*control = (FT_Byte)( flag ? FT_CURVE_TAG_ON : FT_CURVE_TAG_CUBIC );
-
- builder->last = *point;
}
outline->n_points++;
@@ -554,27 +568,24 @@
cff_builder_close_contour( CFF_Builder* builder )
{
FT_Outline* outline = builder->current;
+ FT_Int first;
if ( !outline )
return;
- /* XXXX: We must not include the last point in the path if it */
- /* is located on the first point. */
+ first = outline->n_contours <= 1
+ ? 0 : outline->contours[outline->n_contours - 2] + 1;
+
+ /* We must not include the last point in the path if it */
+ /* is located on the first point. */
if ( outline->n_points > 1 )
{
- FT_Int first = 0;
FT_Vector* p1 = outline->points + first;
FT_Vector* p2 = outline->points + outline->n_points - 1;
FT_Byte* control = (FT_Byte*)outline->tags + outline->n_points - 1;
- if ( outline->n_contours > 1 )
- {
- first = outline->contours[outline->n_contours - 2] + 1;
- p1 = outline->points + first;
- }
-
/* `delete' last point only if it coincides with the first */
/* point and if it is not a control point (which can happen). */
if ( p1->x == p2->x && p1->y == p2->y )
@@ -583,8 +594,18 @@
}
if ( outline->n_contours > 0 )
- outline->contours[outline->n_contours - 1] =
- (short)( outline->n_points - 1 );
+ {
+ /* Don't add contours only consisting of one point, i.e., */
+ /* check whether begin point and last point are the same. */
+ if ( first == outline->n_points - 1 )
+ {
+ outline->n_contours--;
+ outline->n_points--;
+ }
+ else
+ outline->contours[outline->n_contours - 1] =
+ (short)( outline->n_points - 1 );
+ }
}
@@ -674,7 +695,7 @@
data.length = length;
face->root.internal->incremental_interface->funcs->free_glyph_data(
- face->root.internal->incremental_interface->object,&data );
+ face->root.internal->incremental_interface->object, &data );
}
else
#endif /* FT_CONFIG_OPTION_INCREMENTAL */
@@ -690,6 +711,7 @@
static FT_Error
cff_operator_seac( CFF_Decoder* decoder,
+ FT_Pos asb,
FT_Pos adx,
FT_Pos ady,
FT_Int bchar,
@@ -702,8 +724,18 @@
FT_Vector left_bearing, advance;
FT_Byte* charstring;
FT_ULong charstring_len;
+ FT_Pos glyph_width;
+ if ( decoder->seac )
+ {
+ FT_ERROR(( "cff_operator_seac: invalid nested seac\n" ));
+ return CFF_Err_Syntax_Error;
+ }
+
+ adx += decoder->builder.left_bearing.x;
+ ady += decoder->builder.left_bearing.y;
+
#ifdef FT_CONFIG_OPTION_INCREMENTAL
/* Incremental fonts don't necessarily have valid charsets. */
/* They use the character code, not the glyph index, in this case. */
@@ -724,8 +756,8 @@
if ( bchar_index < 0 || achar_index < 0 )
{
- FT_ERROR(( "cff_operator_seac:" ));
- FT_ERROR(( " invalid seac character code arguments\n" ));
+ FT_ERROR(( "cff_operator_seac:"
+ " invalid seac character code arguments\n" ));
return CFF_Err_Syntax_Error;
}
@@ -774,8 +806,11 @@
&charstring, &charstring_len );
if ( !error )
{
+ /* the seac operator must not be nested */
+ decoder->seac = TRUE;
error = cff_decoder_parse_charstrings( decoder, charstring,
charstring_len );
+ decoder->seac = FALSE;
if ( error )
goto Exit;
@@ -783,16 +818,17 @@
cff_free_glyph_data( face, &charstring, charstring_len );
}
- /* Save the left bearing and width of the base character */
- /* as they will be erased by the next load. */
+ /* Save the left bearing, advance and glyph width of the base */
+ /* character as they will be erased by the next load. */
left_bearing = builder->left_bearing;
advance = builder->advance;
+ glyph_width = decoder->glyph_width;
builder->left_bearing.x = 0;
builder->left_bearing.y = 0;
- builder->pos_x = adx;
+ builder->pos_x = adx - asb;
builder->pos_y = ady;
/* Now load `achar' on top of the base outline. */
@@ -800,8 +836,11 @@
&charstring, &charstring_len );
if ( !error )
{
+ /* the seac operator must not be nested */
+ decoder->seac = TRUE;
error = cff_decoder_parse_charstrings( decoder, charstring,
charstring_len );
+ decoder->seac = FALSE;
if ( error )
goto Exit;
@@ -809,10 +848,11 @@
cff_free_glyph_data( face, &charstring, charstring_len );
}
- /* Restore the left side bearing and advance width */
- /* of the base character. */
+ /* Restore the left side bearing, advance and glyph width */
+ /* of the base character. */
builder->left_bearing = left_bearing;
builder->advance = advance;
+ decoder->glyph_width = glyph_width;
builder->pos_x = 0;
builder->pos_y = 0;
@@ -854,6 +894,8 @@
FT_Pos x, y;
FT_Fixed seed;
FT_Fixed* stack;
+ FT_Int charstring_type =
+ decoder->cff->top_font.font_dict.charstring_type;
T2_Hints_Funcs hinter;
@@ -863,9 +905,10 @@
decoder->read_width = 1;
/* compute random seed from stack address of parameter */
- seed = (FT_Fixed)(char*)&seed ^
- (FT_Fixed)(char*)&decoder ^
- (FT_Fixed)(char*)&charstring_base;
+ seed = (FT_Fixed)( ( (FT_PtrDist)(char*)&seed ^
+ (FT_PtrDist)(char*)&decoder ^
+ (FT_PtrDist)(char*)&charstring_base ) &
+ FT_ULONG_MAX ) ;
seed = ( seed ^ ( seed >> 10 ) ^ ( seed >> 20 ) ) & 0xFFFFL;
if ( seed == 0 )
seed = 0x7384;
@@ -920,18 +963,18 @@
ip += 2;
}
else if ( v < 247 )
- val = (FT_Long)v - 139;
+ val = (FT_Int32)v - 139;
else if ( v < 251 )
{
if ( ip >= limit )
goto Syntax_Error;
- val = ( (FT_Long)v - 247 ) * 256 + *ip++ + 108;
+ val = ( (FT_Int32)v - 247 ) * 256 + *ip++ + 108;
}
else if ( v < 255 )
{
if ( ip >= limit )
goto Syntax_Error;
- val = -( (FT_Long)v - 251 ) * 256 - *ip++ - 108;
+ val = -( (FT_Int32)v - 251 ) * 256 - *ip++ - 108;
}
else
{
@@ -942,7 +985,8 @@
( (FT_Int32)ip[2] << 8 ) |
ip[3];
ip += 4;
- shift = 0;
+ if ( charstring_type == 2 )
+ shift = 0;
}
if ( decoder->top - stack >= CFF_MAX_OPERANDS )
goto Stack_Overflow;
@@ -1016,6 +1060,12 @@
case 0:
op = cff_op_dotsection;
break;
+ case 1: /* this is actually the Type1 vstem3 operator */
+ op = cff_op_vstem;
+ break;
+ case 2: /* this is actually the Type1 hstem3 operator */
+ op = cff_op_hstem;
+ break;
case 3:
op = cff_op_and;
break;
@@ -1025,6 +1075,12 @@
case 5:
op = cff_op_not;
break;
+ case 6:
+ op = cff_op_seac;
+ break;
+ case 7:
+ op = cff_op_sbw;
+ break;
case 8:
op = cff_op_store;
break;
@@ -1088,6 +1144,9 @@
case 30:
op = cff_op_roll;
break;
+ case 33:
+ op = cff_op_setcurrentpoint;
+ break;
case 34:
op = cff_op_hflex;
break;
@@ -1155,7 +1214,7 @@
op = cff_op_hvcurveto;
break;
default:
- ;
+ break;
}
if ( op == cff_op_unknown )
@@ -1870,6 +1929,21 @@
}
break;
+ case cff_op_seac:
+ FT_TRACE4(( " seac\n" ));
+
+ error = cff_operator_seac( decoder,
+ args[0], args[1], args[2],
+ (FT_Int)( args[3] >> 16 ),
+ (FT_Int)( args[4] >> 16 ) );
+
+ /* add current outline to the glyph slot */
+ FT_GlyphLoader_Add( builder->loader );
+
+ /* return now! */
+ FT_TRACE4(( "\n" ));
+ return error;
+
case cff_op_endchar:
FT_TRACE4(( " endchar\n" ));
@@ -1879,10 +1953,8 @@
/* Save glyph width so that the subglyphs don't overwrite it. */
FT_Pos glyph_width = decoder->glyph_width;
-
error = cff_operator_seac( decoder,
- args[-4],
- args[-3],
+ 0L, args[-4], args[-3],
(FT_Int)( args[-2] >> 16 ),
(FT_Int)( args[-1] >> 16 ) );
@@ -2090,7 +2162,7 @@
FT_TRACE4(( " dup\n" ));
args[1] = args[0];
- args++;
+ args += 2;
break;
case cff_op_put:
@@ -2101,7 +2173,7 @@
FT_TRACE4(( " put\n" ));
- if ( idx >= 0 && idx < decoder->len_buildchar )
+ if ( idx >= 0 && idx < CFF_MAX_TRANS_ELEMENTS )
decoder->buildchar[idx] = val;
}
break;
@@ -2114,7 +2186,7 @@
FT_TRACE4(( " get\n" ));
- if ( idx >= 0 && idx < decoder->len_buildchar )
+ if ( idx >= 0 && idx < CFF_MAX_TRANS_ELEMENTS )
val = decoder->buildchar[idx];
args[0] = val;
@@ -2154,10 +2226,42 @@
FT_TRACE4(( " hsbw (invalid op)\n" ));
- decoder->glyph_width = decoder->nominal_width +
- (args[1] >> 16);
- x = args[0];
- y = 0;
+ decoder->glyph_width = decoder->nominal_width + ( args[1] >> 16 );
+
+ decoder->builder.left_bearing.x = args[0];
+ decoder->builder.left_bearing.y = 0;
+
+ x = decoder->builder.pos_x + args[0];
+ y = decoder->builder.pos_y;
+ args = stack;
+ break;
+
+ case cff_op_sbw:
+ /* this is an invalid Type 2 operator; however, there */
+ /* exist fonts which are incorrectly converted from probably */
+ /* Type 1 to CFF, and some parsers seem to accept it */
+
+ FT_TRACE4(( " sbw (invalid op)\n" ));
+
+ decoder->glyph_width = decoder->nominal_width + ( args[2] >> 16 );
+
+ decoder->builder.left_bearing.x = args[0];
+ decoder->builder.left_bearing.y = args[1];
+
+ x = decoder->builder.pos_x + args[0];
+ y = decoder->builder.pos_y + args[1];
+ args = stack;
+ break;
+
+ case cff_op_setcurrentpoint:
+ /* this is an invalid Type 2 operator; however, there */
+ /* exist fonts which are incorrectly converted from probably */
+ /* Type 1 to CFF, and some parsers seem to accept it */
+
+ FT_TRACE4(( " setcurrentpoint (invalid op)\n" ));
+
+ x = decoder->builder.pos_x + args[0];
+ y = decoder->builder.pos_y + args[1];
args = stack;
break;
@@ -2168,8 +2272,10 @@
FT_TRACE4(( " callothersubr (invalid op)\n" ));
- /* don't modify stack; handle the subr as `unknown' so that */
- /* following `pop' operands use the arguments on stack */
+ /* subsequent `pop' operands should add the arguments, */
+ /* this is the implementation described for `unknown' other */
+ /* subroutines in the Type1 spec. */
+ args -= 2 + ( args[-2] >> 16 );
break;
case cff_op_pop:
@@ -2241,8 +2347,8 @@
if ( idx >= decoder->num_locals )
{
- FT_ERROR(( "cff_decoder_parse_charstrings:" ));
- FT_ERROR(( " invalid local subr index\n" ));
+ FT_ERROR(( "cff_decoder_parse_charstrings:"
+ " invalid local subr index\n" ));
goto Syntax_Error;
}
@@ -2263,7 +2369,7 @@
if ( !zone->base || zone->limit == zone->base )
{
FT_ERROR(( "cff_decoder_parse_charstrings:"
- " invoking empty subrs!\n" ));
+ " invoking empty subrs\n" ));
goto Syntax_Error;
}
@@ -2283,8 +2389,8 @@
if ( idx >= decoder->num_globals )
{
- FT_ERROR(( "cff_decoder_parse_charstrings:" ));
- FT_ERROR(( " invalid global subr index\n" ));
+ FT_ERROR(( "cff_decoder_parse_charstrings:"
+ " invalid global subr index\n" ));
goto Syntax_Error;
}
@@ -2305,7 +2411,7 @@
if ( !zone->base || zone->limit == zone->base )
{
FT_ERROR(( "cff_decoder_parse_charstrings:"
- " invoking empty subrs!\n" ));
+ " invoking empty subrs\n" ));
goto Syntax_Error;
}
@@ -2354,15 +2460,15 @@
return error;
Syntax_Error:
- FT_TRACE4(( "cff_decoder_parse_charstrings: syntax error!\n" ));
+ FT_TRACE4(( "cff_decoder_parse_charstrings: syntax error\n" ));
return CFF_Err_Invalid_File_Format;
Stack_Underflow:
- FT_TRACE4(( "cff_decoder_parse_charstrings: stack underflow!\n" ));
+ FT_TRACE4(( "cff_decoder_parse_charstrings: stack underflow\n" ));
return CFF_Err_Too_Few_Arguments;
Stack_Overflow:
- FT_TRACE4(( "cff_decoder_parse_charstrings: stack overflow!\n" ));
+ FT_TRACE4(( "cff_decoder_parse_charstrings: stack overflow\n" ));
return CFF_Err_Stack_Overflow;
}
@@ -2565,8 +2671,8 @@
FT_Byte fd_index = cff_fd_select_get( &cff->fd_select,
glyph_index );
- FT_Int top_upm = cff->top_font.font_dict.units_per_em;
- FT_Int sub_upm = cff->subfonts[fd_index]->font_dict.units_per_em;
+ FT_ULong top_upm = cff->top_font.font_dict.units_per_em;
+ FT_ULong sub_upm = cff->subfonts[fd_index]->font_dict.units_per_em;
font_matrix = cff->subfonts[fd_index]->font_dict.font_matrix;
@@ -2658,23 +2764,25 @@
#ifdef FT_CONFIG_OPTION_INCREMENTAL
/* Incremental fonts can optionally override the metrics. */
- if ( !error &&
- face->root.internal->incremental_interface &&
+ if ( !error &&
+ face->root.internal->incremental_interface &&
face->root.internal->incremental_interface->funcs->get_glyph_metrics )
{
FT_Incremental_MetricsRec metrics;
metrics.bearing_x = decoder.builder.left_bearing.x;
- metrics.bearing_y = decoder.builder.left_bearing.y;
+ metrics.bearing_y = 0;
metrics.advance = decoder.builder.advance.x;
+ metrics.advance_v = decoder.builder.advance.y;
+
error = face->root.internal->incremental_interface->funcs->get_glyph_metrics(
face->root.internal->incremental_interface->object,
glyph_index, FALSE, &metrics );
+
decoder.builder.left_bearing.x = metrics.bearing_x;
- decoder.builder.left_bearing.y = metrics.bearing_y;
decoder.builder.advance.x = metrics.advance;
- decoder.builder.advance.y = 0;
+ decoder.builder.advance.y = metrics.advance_v;
}
#endif /* FT_CONFIG_OPTION_INCREMENTAL */
@@ -2711,9 +2819,14 @@
glyph->root.linearHoriAdvance = decoder.glyph_width;
glyph->root.internal->glyph_transformed = 0;
+#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
has_vertical_info = FT_BOOL( face->vertical_info &&
face->vertical.number_Of_VMetrics > 0 &&
face->vertical.long_metrics );
+#else
+ has_vertical_info = FT_BOOL( face->vertical_info &&
+ face->vertical.number_Of_VMetrics > 0 );
+#endif
/* get the vertical metrics from the vtmx table if we have one */
if ( has_vertical_info )
@@ -2750,8 +2863,8 @@
glyph->root.outline.flags |= FT_OUTLINE_REVERSE_FILL;
- /* apply the font matrix -- `xx' has already been normalized */
- if ( !( font_matrix.yy == 0x10000L &&
+ if ( !( font_matrix.xx == 0x10000L &&
+ font_matrix.yy == 0x10000L &&
font_matrix.xy == 0 &&
font_matrix.yx == 0 ) )
FT_Outline_Transform( &glyph->root.outline, &font_matrix );
@@ -2804,10 +2917,14 @@
metrics->horiBearingY = cbox.yMax;
if ( has_vertical_info )
- metrics->vertBearingX = -metrics->width / 2;
- else
- ft_synthesize_vertical_metrics( metrics,
- metrics->vertAdvance );
+ metrics->vertBearingX = metrics->horiBearingX -
+ metrics->horiAdvance / 2;
+ else
+ {
+ if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
+ ft_synthesize_vertical_metrics( metrics,
+ metrics->vertAdvance );
+ }
}
}
diff --git a/src/3rdparty/freetype/src/cff/cffgload.h b/src/3rdparty/freetype/src/cff/cffgload.h
index 667134e3b5..38937be5c1 100644
--- a/src/3rdparty/freetype/src/cff/cffgload.h
+++ b/src/3rdparty/freetype/src/cff/cffgload.h
@@ -4,7 +4,7 @@
/* */
/* OpenType Glyph Loader (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -28,8 +28,9 @@
FT_BEGIN_HEADER
-#define CFF_MAX_OPERANDS 48
-#define CFF_MAX_SUBRS_CALLS 32
+#define CFF_MAX_OPERANDS 48
+#define CFF_MAX_SUBRS_CALLS 32
+#define CFF_MAX_TRANS_ELEMENTS 32
/*************************************************************************/
@@ -53,8 +54,6 @@ FT_BEGIN_HEADER
/* */
/* current :: The current glyph outline. */
/* */
- /* last :: The last point position. */
- /* */
/* pos_x :: The horizontal translation (if composite glyph). */
/* */
/* pos_y :: The vertical translation (if composite glyph). */
@@ -88,8 +87,6 @@ FT_BEGIN_HEADER
FT_Outline* base;
FT_Outline* current;
- FT_Vector last;
-
FT_Pos pos_x;
FT_Pos pos_y;
@@ -141,8 +138,7 @@ FT_BEGIN_HEADER
FT_Bool read_width;
FT_Bool width_only;
FT_Int num_hints;
- FT_Fixed* buildchar;
- FT_Int len_buildchar;
+ FT_Fixed buildchar[CFF_MAX_TRANS_ELEMENTS];
FT_UInt num_locals;
FT_UInt num_globals;
@@ -158,6 +154,8 @@ FT_BEGIN_HEADER
FT_Render_Mode hint_mode;
+ FT_Bool seac;
+
} CFF_Decoder;
diff --git a/src/3rdparty/freetype/src/cff/cffload.c b/src/3rdparty/freetype/src/cff/cffload.c
index 22163fb75c..64d1395723 100644
--- a/src/3rdparty/freetype/src/cff/cffload.c
+++ b/src/3rdparty/freetype/src/cff/cffload.c
@@ -736,6 +736,7 @@
{
FT_Error error = FT_Err_Ok;
FT_UInt i;
+ FT_Long j;
FT_UShort max_cid = 0;
@@ -750,8 +751,11 @@
if ( FT_NEW_ARRAY( charset->cids, max_cid ) )
goto Exit;
- for ( i = 0; i < num_glyphs; i++ )
- charset->cids[charset->sids[i]] = (FT_UShort)i;
+ /* When multiple GIDs map to the same CID, we choose the lowest */
+ /* GID. This is not described in any spec, but it matches the */
+ /* behaviour of recent Acroread versions. */
+ for ( j = num_glyphs - 1; j >= 0 ; j-- )
+ charset->cids[charset->sids[j]] = (FT_UShort)j;
charset->max_cid = max_cid;
charset->num_glyphs = num_glyphs;
@@ -842,7 +846,20 @@
goto Exit;
for ( j = 1; j < num_glyphs; j++ )
- charset->sids[j] = FT_GET_USHORT();
+ {
+ FT_UShort sid = FT_GET_USHORT();
+
+
+ /* this constant is given in the CFF specification */
+ if ( sid < 65000L )
+ charset->sids[j] = sid;
+ else
+ {
+ FT_TRACE0(( "cff_charset_load:"
+ " invalid SID value %d set to zero\n", sid ));
+ charset->sids[j] = 0;
+ }
+ }
FT_FRAME_EXIT();
}
@@ -875,6 +892,20 @@
goto Exit;
}
+ /* check whether the range contains at least one valid glyph; */
+ /* the constant is given in the CFF specification */
+ if ( glyph_sid >= 65000L ) {
+ FT_ERROR(( "cff_charset_load: invalid SID range\n" ));
+ error = CFF_Err_Invalid_File_Format;
+ goto Exit;
+ }
+
+ /* try to rescue some of the SIDs if `nleft' is too large */
+ if ( nleft > 65000L - 1L || glyph_sid >= 65000L - nleft ) {
+ FT_ERROR(( "cff_charset_load: invalid SID range trimmed\n" ));
+ nleft = ( FT_UInt )( 65000L - 1L - glyph_sid );
+ }
+
/* Fill in the range of sids -- `nleft + 1' glyphs. */
for ( i = 0; j < num_glyphs && i <= nleft; i++, j++, glyph_sid++ )
charset->sids[j] = glyph_sid;
@@ -883,7 +914,7 @@
break;
default:
- FT_ERROR(( "cff_charset_load: invalid table format!\n" ));
+ FT_ERROR(( "cff_charset_load: invalid table format\n" ));
error = CFF_Err_Invalid_File_Format;
goto Exit;
}
@@ -906,7 +937,7 @@
if ( num_glyphs > 229 )
{
FT_ERROR(( "cff_charset_load: implicit charset larger than\n"
- "predefined charset (Adobe ISO-Latin)!\n" ));
+ "predefined charset (Adobe ISO-Latin)\n" ));
error = CFF_Err_Invalid_File_Format;
goto Exit;
}
@@ -924,7 +955,7 @@
if ( num_glyphs > 166 )
{
FT_ERROR(( "cff_charset_load: implicit charset larger than\n"
- "predefined charset (Adobe Expert)!\n" ));
+ "predefined charset (Adobe Expert)\n" ));
error = CFF_Err_Invalid_File_Format;
goto Exit;
}
@@ -942,7 +973,7 @@
if ( num_glyphs > 87 )
{
FT_ERROR(( "cff_charset_load: implicit charset larger than\n"
- "predefined charset (Adobe Expert Subset)!\n" ));
+ "predefined charset (Adobe Expert Subset)\n" ));
error = CFF_Err_Invalid_File_Format;
goto Exit;
}
@@ -1127,7 +1158,7 @@
break;
default:
- FT_ERROR(( "cff_encoding_load: invalid table format!\n" ));
+ FT_ERROR(( "cff_encoding_load: invalid table format\n" ));
error = CFF_Err_Invalid_File_Format;
goto Exit;
}
@@ -1222,7 +1253,7 @@
break;
default:
- FT_ERROR(( "cff_encoding_load: invalid table format!\n" ));
+ FT_ERROR(( "cff_encoding_load: invalid table format\n" ));
error = CFF_Err_Invalid_File_Format;
goto Exit;
}
@@ -1240,7 +1271,8 @@
CFF_Index idx,
FT_UInt font_index,
FT_Stream stream,
- FT_ULong base_offset )
+ FT_ULong base_offset,
+ FT_Library library )
{
FT_Error error;
CFF_ParserRec parser;
@@ -1250,7 +1282,7 @@
CFF_Private priv = &font->private_dict;
- cff_parser_init( &parser, CFF_CODE_TOPDICT, &font->font_dict );
+ cff_parser_init( &parser, CFF_CODE_TOPDICT, &font->font_dict, library );
/* set defaults */
FT_MEM_ZERO( top, sizeof ( *top ) );
@@ -1301,7 +1333,7 @@
priv->expansion_factor = (FT_Fixed)( 0.06 * 0x10000L );
priv->blue_scale = (FT_Fixed)( 0.039625 * 0x10000L * 1000 );
- cff_parser_init( &parser, CFF_CODE_PRIVATE, priv );
+ cff_parser_init( &parser, CFF_CODE_PRIVATE, priv, library );
if ( FT_STREAM_SEEK( base_offset + font->font_dict.private_offset ) ||
FT_FRAME_ENTER( font->font_dict.private_size ) )
@@ -1354,7 +1386,8 @@
FT_LOCAL_DEF( FT_Error )
- cff_font_load( FT_Stream stream,
+ cff_font_load( FT_Library library,
+ FT_Stream stream,
FT_Int face_index,
CFF_Font font,
FT_Bool pure_cff )
@@ -1394,7 +1427,7 @@
font->header_size < 4 ||
font->absolute_offsize > 4 )
{
- FT_TRACE2(( "[not a CFF font header!]\n" ));
+ FT_TRACE2(( "[not a CFF font header]\n" ));
error = CFF_Err_Unknown_File_Format;
goto Exit;
}
@@ -1432,7 +1465,8 @@
&font->font_dict_index,
face_index,
stream,
- base_offset );
+ base_offset,
+ library );
if ( error )
goto Exit;
@@ -1462,7 +1496,7 @@
if ( fd_index.count > CFF_MAX_CID_FONTS )
{
- FT_ERROR(( "cff_font_load: FD array too large in CID font\n" ));
+ FT_TRACE0(( "cff_font_load: FD array too large in CID font\n" ));
goto Fail_CID;
}
@@ -1480,7 +1514,7 @@
{
sub = font->subfonts[idx];
error = cff_subfont_load( sub, &fd_index, idx,
- stream, base_offset );
+ stream, base_offset, library );
if ( error )
goto Fail_CID;
}
@@ -1503,7 +1537,7 @@
/* read the charstrings index now */
if ( dict->charstrings_offset == 0 )
{
- FT_ERROR(( "cff_font_load: no charstrings offset!\n" ));
+ FT_ERROR(( "cff_font_load: no charstrings offset\n" ));
error = CFF_Err_Unknown_File_Format;
goto Exit;
}
diff --git a/src/3rdparty/freetype/src/cff/cffload.h b/src/3rdparty/freetype/src/cff/cffload.h
index 02498bd5e0..2b313acf06 100644
--- a/src/3rdparty/freetype/src/cff/cffload.h
+++ b/src/3rdparty/freetype/src/cff/cffload.h
@@ -58,7 +58,8 @@ FT_BEGIN_HEADER
FT_LOCAL( FT_Error )
- cff_font_load( FT_Stream stream,
+ cff_font_load( FT_Library library,
+ FT_Stream stream,
FT_Int face_index,
CFF_Font font,
FT_Bool pure_cff );
diff --git a/src/3rdparty/freetype/src/cff/cffobjs.c b/src/3rdparty/freetype/src/cff/cffobjs.c
index 3525ea3b7d..bd56c4ba11 100644
--- a/src/3rdparty/freetype/src/cff/cffobjs.c
+++ b/src/3rdparty/freetype/src/cff/cffobjs.c
@@ -4,7 +4,7 @@
/* */
/* OpenType objects manager (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -30,6 +30,7 @@
#include "cffload.h"
#include "cffcmap.h"
#include "cfferrs.h"
+#include "cffpic.h"
/*************************************************************************/
@@ -223,8 +224,8 @@
CFF_Font font = (CFF_Font)face->extra.data;
CFF_Internal internal = (CFF_Internal)size->internal;
- FT_Int top_upm = font->top_font.font_dict.units_per_em;
- FT_UInt i;
+ FT_ULong top_upm = font->top_font.font_dict.units_per_em;
+ FT_UInt i;
funcs->set_scale( internal->topfont,
@@ -234,7 +235,7 @@
for ( i = font->num_subfonts; i > 0; i-- )
{
CFF_SubFont sub = font->subfonts[i - 1];
- FT_Int sub_upm = sub->font_dict.units_per_em;
+ FT_ULong sub_upm = sub->font_dict.units_per_em;
FT_Pos x_scale, y_scale;
@@ -295,8 +296,8 @@
CFF_Font font = (CFF_Font)cffface->extra.data;
CFF_Internal internal = (CFF_Internal)size->internal;
- FT_Int top_upm = font->top_font.font_dict.units_per_em;
- FT_UInt i;
+ FT_ULong top_upm = font->top_font.font_dict.units_per_em;
+ FT_UInt i;
funcs->set_scale( internal->topfont,
@@ -306,7 +307,7 @@
for ( i = font->num_subfonts; i > 0; i-- )
{
CFF_SubFont sub = font->subfonts[i - 1];
- FT_Int sub_upm = sub->font_dict.units_per_em;
+ FT_ULong sub_upm = sub->font_dict.units_per_em;
FT_Pos x_scale, y_scale;
@@ -408,6 +409,7 @@
PSHinter_Service pshinter;
FT_Bool pure_cff = 1;
FT_Bool sfnt_format = 0;
+ FT_Library library = cffface->driver->root.library;
#if 0
@@ -419,14 +421,14 @@
goto Bad_Format;
#else
sfnt = (SFNT_Service)FT_Get_Module_Interface(
- cffface->driver->root.library, "sfnt" );
+ library, "sfnt" );
if ( !sfnt )
goto Bad_Format;
FT_FACE_FIND_GLOBAL_SERVICE( face, psnames, POSTSCRIPT_CMAPS );
pshinter = (PSHinter_Service)FT_Get_Module_Interface(
- cffface->driver->root.library, "pshinter" );
+ library, "pshinter" );
#endif
/* create input stream from resource */
@@ -507,7 +509,7 @@
goto Exit;
face->extra.data = cff;
- error = cff_font_load( stream, face_index, cff, pure_cff );
+ error = cff_font_load( library, stream, face_index, cff, pure_cff );
if ( error )
goto Exit;
@@ -528,10 +530,10 @@
/* which aren't CID-keyed */
if ( dict->cid_registry == 0xFFFFU && !psnames )
{
- FT_ERROR(( "cff_face_init:" ));
- FT_ERROR(( " cannot open CFF & CEF fonts\n" ));
- FT_ERROR(( " " ));
- FT_ERROR(( " without the `PSNames' module\n" ));
+ FT_ERROR(( "cff_face_init:"
+ " cannot open CFF & CEF fonts\n"
+ " "
+ " without the `PSNames' module\n" ));
goto Bad_Format;
}
@@ -582,7 +584,7 @@
if ( sub->units_per_em )
{
- FT_Int scaling;
+ FT_Long scaling;
if ( top->units_per_em > 1 && sub->units_per_em > 1 )
@@ -655,10 +657,11 @@
cffface->num_glyphs = cff->charstrings_index.count;
/* set global bbox, as well as EM size */
- cffface->bbox.xMin = dict->font_bbox.xMin >> 16;
- cffface->bbox.yMin = dict->font_bbox.yMin >> 16;
- cffface->bbox.xMax = ( dict->font_bbox.xMax + 0xFFFFU ) >> 16;
- cffface->bbox.yMax = ( dict->font_bbox.yMax + 0xFFFFU ) >> 16;
+ cffface->bbox.xMin = dict->font_bbox.xMin >> 16;
+ cffface->bbox.yMin = dict->font_bbox.yMin >> 16;
+ /* no `U' suffix here to 0xFFFF! */
+ cffface->bbox.xMax = ( dict->font_bbox.xMax + 0xFFFF ) >> 16;
+ cffface->bbox.yMax = ( dict->font_bbox.yMax + 0xFFFF ) >> 16;
cffface->units_per_EM = (FT_UShort)( dict->units_per_em );
@@ -764,22 +767,22 @@
/* */
/* Compute face flags. */
/* */
- flags = FT_FACE_FLAG_SCALABLE | /* scalable outlines */
- FT_FACE_FLAG_HORIZONTAL | /* horizontal data */
- FT_FACE_FLAG_HINTER; /* has native hinter */
+ flags = (FT_UInt32)( FT_FACE_FLAG_SCALABLE | /* scalable outlines */
+ FT_FACE_FLAG_HORIZONTAL | /* horizontal data */
+ FT_FACE_FLAG_HINTER ); /* has native hinter */
if ( sfnt_format )
- flags |= FT_FACE_FLAG_SFNT;
+ flags |= (FT_UInt32)FT_FACE_FLAG_SFNT;
/* fixed width font? */
if ( dict->is_fixed_pitch )
- flags |= FT_FACE_FLAG_FIXED_WIDTH;
+ flags |= (FT_UInt32)FT_FACE_FLAG_FIXED_WIDTH;
/* XXX: WE DO NOT SUPPORT KERNING METRICS IN THE GPOS TABLE FOR NOW */
#if 0
/* kerning available? */
if ( face->kern_pairs )
- flags |= FT_FACE_FLAG_KERNING;
+ flags |= (FT_UInt32)FT_FACE_FLAG_KERNING;
#endif
cffface->face_flags = flags;
@@ -868,7 +871,7 @@
nn = (FT_UInt)cffface->num_charmaps;
- FT_CMap_New( &cff_cmap_unicode_class_rec, NULL, &cmaprec, NULL );
+ FT_CMap_New( &FT_CFF_CMAP_UNICODE_CLASS_REC_GET, NULL, &cmaprec, NULL );
/* if no Unicode charmap was previously selected, select this one */
if ( cffface->charmap == NULL && nn != (FT_UInt)cffface->num_charmaps )
@@ -887,19 +890,19 @@
{
cmaprec.encoding_id = TT_ADOBE_ID_STANDARD;
cmaprec.encoding = FT_ENCODING_ADOBE_STANDARD;
- clazz = &cff_cmap_encoding_class_rec;
+ clazz = &FT_CFF_CMAP_ENCODING_CLASS_REC_GET;
}
else if ( encoding->offset == 1 )
{
cmaprec.encoding_id = TT_ADOBE_ID_EXPERT;
cmaprec.encoding = FT_ENCODING_ADOBE_EXPERT;
- clazz = &cff_cmap_encoding_class_rec;
+ clazz = &FT_CFF_CMAP_ENCODING_CLASS_REC_GET;
}
else
{
cmaprec.encoding_id = TT_ADOBE_ID_CUSTOM;
cmaprec.encoding = FT_ENCODING_ADOBE_CUSTOM;
- clazz = &cff_cmap_encoding_class_rec;
+ clazz = &FT_CFF_CMAP_ENCODING_CLASS_REC_GET;
}
FT_CMap_New( clazz, NULL, &cmaprec, NULL );
diff --git a/src/3rdparty/freetype/src/cff/cffparse.c b/src/3rdparty/freetype/src/cff/cffparse.c
index 290595f9e8..01266a193d 100644
--- a/src/3rdparty/freetype/src/cff/cffparse.c
+++ b/src/3rdparty/freetype/src/cff/cffparse.c
@@ -22,6 +22,7 @@
#include FT_INTERNAL_DEBUG_H
#include "cfferrs.h"
+#include "cffpic.h"
/*************************************************************************/
@@ -34,47 +35,20 @@
#define FT_COMPONENT trace_cffparse
- enum
- {
- cff_kind_none = 0,
- cff_kind_num,
- cff_kind_fixed,
- cff_kind_fixed_thousand,
- cff_kind_string,
- cff_kind_bool,
- cff_kind_delta,
- cff_kind_callback,
-
- cff_kind_max /* do not remove */
- };
-
-
- /* now generate handlers for the most simple fields */
- typedef FT_Error (*CFF_Field_Reader)( CFF_Parser parser );
-
- typedef struct CFF_Field_Handler_
- {
- int kind;
- int code;
- FT_UInt offset;
- FT_Byte size;
- CFF_Field_Reader reader;
- FT_UInt array_max;
- FT_UInt count_offset;
-
- } CFF_Field_Handler;
FT_LOCAL_DEF( void )
cff_parser_init( CFF_Parser parser,
FT_UInt code,
- void* object )
+ void* object,
+ FT_Library library)
{
FT_MEM_ZERO( parser, sizeof ( *parser ) );
parser->top = parser->stack;
parser->object_code = code;
parser->object = object;
+ parser->library = library;
}
@@ -156,8 +130,8 @@
static FT_Fixed
cff_parse_real( FT_Byte* start,
FT_Byte* limit,
- FT_Int power_ten,
- FT_Int* scaling )
+ FT_Long power_ten,
+ FT_Long* scaling )
{
FT_Byte* p = start;
FT_UInt nib;
@@ -165,7 +139,7 @@
FT_Long result, number, rest, exponent;
FT_Int sign = 0, exponent_sign = 0;
- FT_Int exponent_add, integer_length, fraction_length;
+ FT_Long exponent_add, integer_length, fraction_length;
if ( scaling )
@@ -181,6 +155,8 @@
integer_length = 0;
fraction_length = 0;
+ FT_UNUSED( rest );
+
/* First of all, read the integer part. */
phase = 4;
@@ -310,7 +286,7 @@
{
if ( exponent > 0 )
{
- FT_Int new_fraction_length, shift;
+ FT_Long new_fraction_length, shift;
/* Make `scaling' as small as possible. */
@@ -410,7 +386,7 @@
/* but return `10^scaling' times the number read in */
static FT_Fixed
cff_parse_fixed_scaled( FT_Byte** d,
- FT_Int scaling )
+ FT_Long scaling )
{
return **d == 30 ? cff_parse_real( d[0], d[1], scaling, NULL )
: ( cff_parse_integer( d[0], d[1] ) *
@@ -423,7 +399,7 @@
/* the scaling factor (as a power of 10) */
static FT_Fixed
cff_parse_fixed_dynamic( FT_Byte** d,
- FT_Int* scaling )
+ FT_Long* scaling )
{
FT_ASSERT( scaling );
@@ -476,7 +452,7 @@
if ( parser->top >= parser->stack + 6 )
{
- FT_Int scaling;
+ FT_Long scaling;
error = CFF_Err_Ok;
@@ -578,7 +554,12 @@
{
dict->cid_registry = (FT_UInt)cff_parse_num ( data++ );
dict->cid_ordering = (FT_UInt)cff_parse_num ( data++ );
- dict->cid_supplement = (FT_ULong)cff_parse_num( data );
+ if ( **data == 30 )
+ FT_TRACE1(( "cff_parse_cid_ros: real supplement is rounded\n" ));
+ dict->cid_supplement = cff_parse_num( data );
+ if ( dict->cid_supplement < 0 )
+ FT_TRACE1(( "cff_parse_cid_ros: negative supplement %d is found\n",
+ dict->cid_supplement ));
error = CFF_Err_Ok;
}
@@ -599,6 +580,11 @@
#define CFF_FIELD_DELTA( code, name, max ) \
CFF_FIELD( code, name, cff_kind_delta )
+#define CFFCODE_TOPDICT 0x1000
+#define CFFCODE_PRIVATE 0x2000
+
+#ifndef FT_CONFIG_OPTION_PIC
+
#define CFF_FIELD_CALLBACK( code, name ) \
{ \
cff_kind_callback, \
@@ -630,9 +616,6 @@
FT_FIELD_OFFSET( num_ ## name ) \
},
-#define CFFCODE_TOPDICT 0x1000
-#define CFFCODE_PRIVATE 0x2000
-
static const CFF_Field_Handler cff_field_handlers[] =
{
@@ -642,13 +625,99 @@
};
+#else /* FT_CONFIG_OPTION_PIC */
+
+ void FT_Destroy_Class_cff_field_handlers(FT_Library library, CFF_Field_Handler* clazz)
+ {
+ FT_Memory memory = library->memory;
+ if ( clazz )
+ FT_FREE( clazz );
+ }
+
+ FT_Error FT_Create_Class_cff_field_handlers(FT_Library library, CFF_Field_Handler** output_class)
+ {
+ CFF_Field_Handler* clazz;
+ FT_Error error;
+ FT_Memory memory = library->memory;
+ int i=0;
+
+#undef CFF_FIELD
+#undef CFF_FIELD_DELTA
+#undef CFF_FIELD_CALLBACK
+#define CFF_FIELD_CALLBACK( code, name ) i++;
+#define CFF_FIELD( code, name, kind ) i++;
+#define CFF_FIELD_DELTA( code, name, max ) i++;
+
+#include "cfftoken.h"
+ i++;/*{ 0, 0, 0, 0, 0, 0, 0 }*/
+
+ if ( FT_ALLOC( clazz, sizeof(CFF_Field_Handler)*i ) )
+ return error;
+
+ i=0;
+#undef CFF_FIELD
+#undef CFF_FIELD_DELTA
+#undef CFF_FIELD_CALLBACK
+
+#define CFF_FIELD_CALLBACK( code_, name_ ) \
+ clazz[i].kind = cff_kind_callback; \
+ clazz[i].code = code_ | CFFCODE; \
+ clazz[i].offset = 0; \
+ clazz[i].size = 0; \
+ clazz[i].reader = cff_parse_ ## name_; \
+ clazz[i].array_max = 0; \
+ clazz[i].count_offset = 0; \
+ i++;
+
+#undef CFF_FIELD
+#define CFF_FIELD( code_, name_, kind_ ) \
+ clazz[i].kind = kind_; \
+ clazz[i].code = code_ | CFFCODE; \
+ clazz[i].offset = FT_FIELD_OFFSET( name_ ); \
+ clazz[i].size = FT_FIELD_SIZE( name_ ); \
+ clazz[i].reader = 0; \
+ clazz[i].array_max = 0; \
+ clazz[i].count_offset = 0; \
+ i++; \
+
+#undef CFF_FIELD_DELTA
+#define CFF_FIELD_DELTA( code_, name_, max_ ) \
+ clazz[i].kind = cff_kind_delta; \
+ clazz[i].code = code_ | CFFCODE; \
+ clazz[i].offset = FT_FIELD_OFFSET( name_ ); \
+ clazz[i].size = FT_FIELD_SIZE_DELTA( name_ ); \
+ clazz[i].reader = 0; \
+ clazz[i].array_max = max_; \
+ clazz[i].count_offset = FT_FIELD_OFFSET( num_ ## name_ ); \
+ i++;
+
+#include "cfftoken.h"
+
+ clazz[i].kind = 0;
+ clazz[i].code = 0;
+ clazz[i].offset = 0;
+ clazz[i].size = 0;
+ clazz[i].reader = 0;
+ clazz[i].array_max = 0;
+ clazz[i].count_offset = 0;
+
+ *output_class = clazz;
+ return FT_Err_Ok;
+ }
+
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+
FT_LOCAL_DEF( FT_Error )
cff_parser_run( CFF_Parser parser,
FT_Byte* start,
FT_Byte* limit )
{
- FT_Byte* p = start;
- FT_Error error = CFF_Err_Ok;
+ FT_Byte* p = start;
+ FT_Error error = CFF_Err_Ok;
+ FT_Library library = parser->library;
+ FT_UNUSED(library);
parser->top = parser->stack;
@@ -676,8 +745,10 @@
p++;
for (;;)
{
+ /* An unterminated floating point number at the */
+ /* end of a dictionary is invalid but harmless. */
if ( p >= limit )
- goto Syntax_Error;
+ goto Exit;
v = p[0] >> 4;
if ( v == 15 )
break;
@@ -718,7 +789,7 @@
}
code = code | parser->object_code;
- for ( field = cff_field_handlers; field->kind; field++ )
+ for ( field = FT_CFF_FIELD_HANDLERS_GET; field->kind; field++ )
{
if ( field->code == (FT_Int)code )
{
diff --git a/src/3rdparty/freetype/src/cff/cffparse.h b/src/3rdparty/freetype/src/cff/cffparse.h
index 8f3fa58859..7e2c00a044 100644
--- a/src/3rdparty/freetype/src/cff/cffparse.h
+++ b/src/3rdparty/freetype/src/cff/cffparse.h
@@ -36,6 +36,7 @@ FT_BEGIN_HEADER
typedef struct CFF_ParserRec_
{
+ FT_Library library;
FT_Byte* start;
FT_Byte* limit;
FT_Byte* cursor;
@@ -52,7 +53,8 @@ FT_BEGIN_HEADER
FT_LOCAL( void )
cff_parser_init( CFF_Parser parser,
FT_UInt code,
- void* object );
+ void* object,
+ FT_Library library);
FT_LOCAL( FT_Error )
cff_parser_run( CFF_Parser parser,
@@ -60,6 +62,37 @@ FT_BEGIN_HEADER
FT_Byte* limit );
+ enum
+ {
+ cff_kind_none = 0,
+ cff_kind_num,
+ cff_kind_fixed,
+ cff_kind_fixed_thousand,
+ cff_kind_string,
+ cff_kind_bool,
+ cff_kind_delta,
+ cff_kind_callback,
+
+ cff_kind_max /* do not remove */
+ };
+
+
+ /* now generate handlers for the most simple fields */
+ typedef FT_Error (*CFF_Field_Reader)( CFF_Parser parser );
+
+ typedef struct CFF_Field_Handler_
+ {
+ int kind;
+ int code;
+ FT_UInt offset;
+ FT_Byte size;
+ CFF_Field_Reader reader;
+ FT_UInt array_max;
+ FT_UInt count_offset;
+
+ } CFF_Field_Handler;
+
+
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/cff/cffpic.c b/src/3rdparty/freetype/src/cff/cffpic.c
new file mode 100644
index 0000000000..568956d6a9
--- /dev/null
+++ b/src/3rdparty/freetype/src/cff/cffpic.c
@@ -0,0 +1,99 @@
+/***************************************************************************/
+/* */
+/* cffpic.c */
+/* */
+/* The FreeType position independent code services for cff module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#include <ft2build.h>
+#include FT_FREETYPE_H
+#include FT_INTERNAL_OBJECTS_H
+#include "cffpic.h"
+
+#ifdef FT_CONFIG_OPTION_PIC
+
+ /* forward declaration of PIC init functions from cffdrivr.c */
+ FT_Error FT_Create_Class_cff_services( FT_Library, FT_ServiceDescRec**);
+ void FT_Destroy_Class_cff_services( FT_Library, FT_ServiceDescRec*);
+ void FT_Init_Class_cff_service_ps_info( FT_Library, FT_Service_PsInfoRec*);
+ void FT_Init_Class_cff_service_glyph_dict( FT_Library, FT_Service_GlyphDictRec*);
+ void FT_Init_Class_cff_service_ps_name( FT_Library, FT_Service_PsFontNameRec*);
+ void FT_Init_Class_cff_service_get_cmap_info( FT_Library, FT_Service_TTCMapsRec*);
+ void FT_Init_Class_cff_service_cid_info( FT_Library, FT_Service_CIDRec*);
+
+ /* forward declaration of PIC init functions from cffparse.c */
+ FT_Error FT_Create_Class_cff_field_handlers( FT_Library, CFF_Field_Handler**);
+ void FT_Destroy_Class_cff_field_handlers( FT_Library, CFF_Field_Handler*);
+
+ /* forward declaration of PIC init functions from cffcmap.c */
+ void FT_Init_Class_cff_cmap_encoding_class_rec( FT_Library, FT_CMap_ClassRec*);
+ void FT_Init_Class_cff_cmap_unicode_class_rec( FT_Library, FT_CMap_ClassRec*);
+
+ void
+ cff_driver_class_pic_free( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+ if ( pic_container->cff )
+ {
+ CffModulePIC* container = (CffModulePIC*)pic_container->cff;
+ if(container->cff_services)
+ FT_Destroy_Class_cff_services(library, container->cff_services);
+ container->cff_services = NULL;
+ if(container->cff_field_handlers)
+ FT_Destroy_Class_cff_field_handlers(library, container->cff_field_handlers);
+ container->cff_field_handlers = NULL;
+ FT_FREE( container );
+ pic_container->cff = NULL;
+ }
+ }
+
+ FT_Error
+ cff_driver_class_pic_init( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Error error = FT_Err_Ok;
+ CffModulePIC* container;
+ FT_Memory memory = library->memory;
+
+ /* allocate pointer, clear and set global container pointer */
+ if ( FT_ALLOC ( container, sizeof ( *container ) ) )
+ return error;
+ FT_MEM_SET( container, 0, sizeof(*container) );
+ pic_container->cff = container;
+
+ /* initialize pointer table - this is how the module usually expects this data */
+ error = FT_Create_Class_cff_services(library, &container->cff_services);
+ if(error)
+ goto Exit;
+ error = FT_Create_Class_cff_field_handlers(library, &container->cff_field_handlers);
+ if(error)
+ goto Exit;
+ FT_Init_Class_cff_service_ps_info(library, &container->cff_service_ps_info);
+ FT_Init_Class_cff_service_glyph_dict(library, &container->cff_service_glyph_dict);
+ FT_Init_Class_cff_service_ps_name(library, &container->cff_service_ps_name);
+ FT_Init_Class_cff_service_get_cmap_info(library, &container->cff_service_get_cmap_info);
+ FT_Init_Class_cff_service_cid_info(library, &container->cff_service_cid_info);
+ FT_Init_Class_cff_cmap_encoding_class_rec(library, &container->cff_cmap_encoding_class_rec);
+ FT_Init_Class_cff_cmap_unicode_class_rec(library, &container->cff_cmap_unicode_class_rec);
+Exit:
+ if(error)
+ cff_driver_class_pic_free(library);
+ return error;
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/cff/cffpic.h b/src/3rdparty/freetype/src/cff/cffpic.h
new file mode 100644
index 0000000000..e29d068134
--- /dev/null
+++ b/src/3rdparty/freetype/src/cff/cffpic.h
@@ -0,0 +1,80 @@
+/***************************************************************************/
+/* */
+/* cffpic.h */
+/* */
+/* The FreeType position independent code services for cff module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifndef __CFFPIC_H__
+#define __CFFPIC_H__
+
+
+FT_BEGIN_HEADER
+
+#include FT_INTERNAL_PIC_H
+
+#ifndef FT_CONFIG_OPTION_PIC
+#define FT_CFF_SERVICE_PS_INFO_GET cff_service_ps_info
+#define FT_CFF_SERVICE_GLYPH_DICT_GET cff_service_glyph_dict
+#define FT_CFF_SERVICE_PS_NAME_GET cff_service_ps_name
+#define FT_CFF_SERVICE_GET_CMAP_INFO_GET cff_service_get_cmap_info
+#define FT_CFF_SERVICE_CID_INFO_GET cff_service_cid_info
+#define FT_CFF_SERVICES_GET cff_services
+#define FT_CFF_CMAP_ENCODING_CLASS_REC_GET cff_cmap_encoding_class_rec
+#define FT_CFF_CMAP_UNICODE_CLASS_REC_GET cff_cmap_unicode_class_rec
+#define FT_CFF_FIELD_HANDLERS_GET cff_field_handlers
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#include FT_SERVICE_GLYPH_DICT_H
+#include "cffparse.h"
+#include FT_SERVICE_POSTSCRIPT_INFO_H
+#include FT_SERVICE_POSTSCRIPT_NAME_H
+#include FT_SERVICE_TT_CMAP_H
+#include FT_SERVICE_CID_H
+
+ typedef struct CffModulePIC_
+ {
+ FT_ServiceDescRec* cff_services;
+ CFF_Field_Handler* cff_field_handlers;
+ FT_Service_PsInfoRec cff_service_ps_info;
+ FT_Service_GlyphDictRec cff_service_glyph_dict;
+ FT_Service_PsFontNameRec cff_service_ps_name;
+ FT_Service_TTCMapsRec cff_service_get_cmap_info;
+ FT_Service_CIDRec cff_service_cid_info;
+ FT_CMap_ClassRec cff_cmap_encoding_class_rec;
+ FT_CMap_ClassRec cff_cmap_unicode_class_rec;
+ } CffModulePIC;
+
+#define GET_PIC(lib) ((CffModulePIC*)((lib)->pic_container.cff))
+#define FT_CFF_SERVICE_PS_INFO_GET (GET_PIC(library)->cff_service_ps_info)
+#define FT_CFF_SERVICE_GLYPH_DICT_GET (GET_PIC(library)->cff_service_glyph_dict)
+#define FT_CFF_SERVICE_PS_NAME_GET (GET_PIC(library)->cff_service_ps_name)
+#define FT_CFF_SERVICE_GET_CMAP_INFO_GET (GET_PIC(library)->cff_service_get_cmap_info)
+#define FT_CFF_SERVICE_CID_INFO_GET (GET_PIC(library)->cff_service_cid_info)
+#define FT_CFF_SERVICES_GET (GET_PIC(library)->cff_services)
+#define FT_CFF_CMAP_ENCODING_CLASS_REC_GET (GET_PIC(library)->cff_cmap_encoding_class_rec)
+#define FT_CFF_CMAP_UNICODE_CLASS_REC_GET (GET_PIC(library)->cff_cmap_unicode_class_rec)
+#define FT_CFF_FIELD_HANDLERS_GET (GET_PIC(library)->cff_field_handlers)
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /* */
+
+FT_END_HEADER
+
+#endif /* __CFFPIC_H__ */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/cff/cfftypes.h b/src/3rdparty/freetype/src/cff/cfftypes.h
index 546ea3b99d..df92e9a1ac 100644
--- a/src/3rdparty/freetype/src/cff/cfftypes.h
+++ b/src/3rdparty/freetype/src/cff/cfftypes.h
@@ -130,7 +130,7 @@ FT_BEGIN_HEADER
/* these should only be used for the top-level font dictionary */
FT_UInt cid_registry;
FT_UInt cid_ordering;
- FT_ULong cid_supplement;
+ FT_Long cid_supplement;
FT_Long cid_font_version;
FT_Long cid_font_revision;
diff --git a/src/3rdparty/freetype/src/cid/cidgload.c b/src/3rdparty/freetype/src/cid/cidgload.c
index 64994b4419..ea61b4e128 100644
--- a/src/3rdparty/freetype/src/cid/cidgload.c
+++ b/src/3rdparty/freetype/src/cid/cidgload.c
@@ -4,7 +4,7 @@
/* */
/* CID-keyed Type1 Glyph Loader (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2009, 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -22,6 +22,7 @@
#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_STREAM_H
#include FT_OUTLINE_H
+#include FT_INTERNAL_CALC_H
#include "ciderrs.h"
@@ -51,20 +52,25 @@
FT_ULong glyph_length = 0;
PSAux_Service psaux = (PSAux_Service)face->psaux;
+#ifdef FT_CONFIG_OPTION_INCREMENTAL
+ FT_Incremental_InterfaceRec *inc =
+ face->root.internal->incremental_interface;
+#endif
+
+
+ FT_TRACE4(( "cid_load_glyph: glyph index %d\n", glyph_index ));
#ifdef FT_CONFIG_OPTION_INCREMENTAL
/* For incremental fonts get the character data using */
/* the callback function. */
- if ( face->root.internal->incremental_interface )
+ if ( inc )
{
FT_Data glyph_data;
- error = face->root.internal->incremental_interface->funcs->get_glyph_data(
- face->root.internal->incremental_interface->object,
- glyph_index,
- &glyph_data );
+ error = inc->funcs->get_glyph_data( inc->object,
+ glyph_index, &glyph_data );
if ( error )
goto Exit;
@@ -80,9 +86,7 @@
glyph_length );
}
- face->root.internal->incremental_interface->funcs->free_glyph_data(
- face->root.internal->incremental_interface->object,
- &glyph_data );
+ inc->funcs->free_glyph_data( inc->object, &glyph_data );
if ( error )
goto Exit;
@@ -163,23 +167,22 @@
#ifdef FT_CONFIG_OPTION_INCREMENTAL
/* Incremental fonts can optionally override the metrics. */
- if ( !error &&
- face->root.internal->incremental_interface &&
- face->root.internal->incremental_interface->funcs->get_glyph_metrics )
+ if ( !error && inc && inc->funcs->get_glyph_metrics )
{
FT_Incremental_MetricsRec metrics;
- metrics.bearing_x = decoder->builder.left_bearing.x;
- metrics.bearing_y = decoder->builder.left_bearing.y;
- metrics.advance = decoder->builder.advance.x;
- error = face->root.internal->incremental_interface->funcs->get_glyph_metrics(
- face->root.internal->incremental_interface->object,
- glyph_index, FALSE, &metrics );
- decoder->builder.left_bearing.x = metrics.bearing_x;
- decoder->builder.left_bearing.y = metrics.bearing_y;
- decoder->builder.advance.x = metrics.advance;
- decoder->builder.advance.y = 0;
+ metrics.bearing_x = FIXED_TO_INT( decoder->builder.left_bearing.x );
+ metrics.bearing_y = 0;
+ metrics.advance = FIXED_TO_INT( decoder->builder.advance.x );
+ metrics.advance_v = FIXED_TO_INT( decoder->builder.advance.y );
+
+ error = inc->funcs->get_glyph_metrics( inc->object,
+ glyph_index, FALSE, &metrics );
+
+ decoder->builder.left_bearing.x = INT_TO_FIXED( metrics.bearing_x );
+ decoder->builder.advance.x = INT_TO_FIXED( metrics.advance );
+ decoder->builder.advance.y = INT_TO_FIXED( metrics.advance_v );
}
#endif /* FT_CONFIG_OPTION_INCREMENTAL */
@@ -251,7 +254,7 @@
/* ignore the error if one occurred - skip to next glyph */
}
- *max_advance = decoder.builder.advance.x;
+ *max_advance = FIXED_TO_INT( decoder.builder.advance.x );
psaux->t1_decoder_funcs->done( &decoder );
@@ -342,8 +345,10 @@
FT_Slot_Internal internal = cidglyph->internal;
- cidglyph->metrics.horiBearingX = decoder.builder.left_bearing.x;
- cidglyph->metrics.horiAdvance = decoder.builder.advance.x;
+ cidglyph->metrics.horiBearingX =
+ FIXED_TO_INT( decoder.builder.left_bearing.x );
+ cidglyph->metrics.horiAdvance =
+ FIXED_TO_INT( decoder.builder.advance.x );
internal->glyph_matrix = font_matrix;
internal->glyph_delta = font_offset;
@@ -357,8 +362,10 @@
/* copy the _unscaled_ advance width */
- metrics->horiAdvance = decoder.builder.advance.x;
- cidglyph->linearHoriAdvance = decoder.builder.advance.x;
+ metrics->horiAdvance =
+ FIXED_TO_INT( decoder.builder.advance.x );
+ cidglyph->linearHoriAdvance =
+ FIXED_TO_INT( decoder.builder.advance.x );
cidglyph->internal->glyph_transformed = 0;
/* make up vertical ones */
@@ -420,9 +427,12 @@
metrics->horiBearingX = cbox.xMin;
metrics->horiBearingY = cbox.yMax;
- /* make up vertical ones */
- ft_synthesize_vertical_metrics( metrics,
- metrics->vertAdvance );
+ if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
+ {
+ /* make up vertical ones */
+ ft_synthesize_vertical_metrics( metrics,
+ metrics->vertAdvance );
+ }
}
Exit:
diff --git a/src/3rdparty/freetype/src/cid/cidload.c b/src/3rdparty/freetype/src/cid/cidload.c
index a43a00e01a..3bb359446f 100644
--- a/src/3rdparty/freetype/src/cid/cidload.c
+++ b/src/3rdparty/freetype/src/cid/cidload.c
@@ -112,7 +112,7 @@
if ( parser->num_dict < 0 )
{
- FT_ERROR(( "cid_load_keyword: invalid use of `%s'!\n",
+ FT_ERROR(( "cid_load_keyword: invalid use of `%s'\n",
keyword->ident ));
error = CID_Err_Syntax_Error;
goto Exit;
diff --git a/src/3rdparty/freetype/src/cid/cidobjs.c b/src/3rdparty/freetype/src/cid/cidobjs.c
index 9647d87016..82678af0d4 100644
--- a/src/3rdparty/freetype/src/cid/cidobjs.c
+++ b/src/3rdparty/freetype/src/cid/cidobjs.c
@@ -413,10 +413,11 @@
cidface->num_fixed_sizes = 0;
cidface->available_sizes = 0;
- cidface->bbox.xMin = cid->font_bbox.xMin >> 16;
- cidface->bbox.yMin = cid->font_bbox.yMin >> 16;
- cidface->bbox.xMax = ( cid->font_bbox.xMax + 0xFFFFU ) >> 16;
- cidface->bbox.yMax = ( cid->font_bbox.yMax + 0xFFFFU ) >> 16;
+ cidface->bbox.xMin = cid->font_bbox.xMin >> 16;
+ cidface->bbox.yMin = cid->font_bbox.yMin >> 16;
+ /* no `U' suffix here to 0xFFFF! */
+ cidface->bbox.xMax = ( cid->font_bbox.xMax + 0xFFFF ) >> 16;
+ cidface->bbox.yMax = ( cid->font_bbox.yMax + 0xFFFF ) >> 16;
if ( !cidface->units_per_EM )
cidface->units_per_EM = 1000;
diff --git a/src/3rdparty/freetype/src/cid/cidparse.c b/src/3rdparty/freetype/src/cid/cidparse.c
index bb87afc589..efed618f5a 100644
--- a/src/3rdparty/freetype/src/cid/cidparse.c
+++ b/src/3rdparty/freetype/src/cid/cidparse.c
@@ -4,7 +4,7 @@
/* */
/* CID-keyed Type1 parser (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -18,7 +18,6 @@
#include <ft2build.h>
#include FT_INTERNAL_DEBUG_H
-#include FT_INTERNAL_CALC_H
#include FT_INTERNAL_OBJECTS_H
#include FT_INTERNAL_STREAM_H
@@ -87,13 +86,13 @@
/* `StartData' or `/sfnts' */
{
FT_Byte buffer[256 + 10];
- FT_Int read_len = 256 + 10;
+ FT_Long read_len = 256 + 10; /* same as signed FT_Stream->size */
FT_Byte* p = buffer;
- for ( offset = (FT_ULong)FT_STREAM_POS(); ; offset += 256 )
+ for ( offset = FT_STREAM_POS(); ; offset += 256 )
{
- FT_Int stream_len;
+ FT_Long stream_len; /* same as signed FT_Stream->size */
stream_len = stream->size - FT_STREAM_POS();
diff --git a/src/3rdparty/freetype/src/cid/cidriver.c b/src/3rdparty/freetype/src/cid/cidriver.c
index b41d5d6f05..3a2d22532a 100644
--- a/src/3rdparty/freetype/src/cid/cidriver.c
+++ b/src/3rdparty/freetype/src/cid/cidriver.c
@@ -20,7 +20,6 @@
#include "cidriver.h"
#include "cidgload.h"
#include FT_INTERNAL_DEBUG_H
-#include FT_INTERNAL_STREAM_H
#include "ciderrs.h"
diff --git a/src/3rdparty/freetype/src/cid/cidriver.h b/src/3rdparty/freetype/src/cid/cidriver.h
index d5a80f6f9f..c7f424bb38 100644
--- a/src/3rdparty/freetype/src/cid/cidriver.h
+++ b/src/3rdparty/freetype/src/cid/cidriver.h
@@ -26,6 +26,10 @@
FT_BEGIN_HEADER
+#ifdef FT_CONFIG_OPTION_PIC
+#error "this module does not support PIC yet"
+#endif
+
FT_CALLBACK_TABLE
const FT_Driver_ClassRec t1cid_driver_class;
diff --git a/src/3rdparty/freetype/src/cid/cidtoken.h b/src/3rdparty/freetype/src/cid/cidtoken.h
index 94a3657b02..904cb09cf4 100644
--- a/src/3rdparty/freetype/src/cid/cidtoken.h
+++ b/src/3rdparty/freetype/src/cid/cidtoken.h
@@ -22,7 +22,7 @@
#define T1CODE T1_FIELD_LOCATION_CID_INFO
T1_FIELD_KEY ( "CIDFontName", cid_font_name, 0 )
- T1_FIELD_NUM ( "CIDFontVersion", cid_version, 0 )
+ T1_FIELD_FIXED ( "CIDFontVersion", cid_version, 0 )
T1_FIELD_NUM ( "CIDFontType", cid_font_type, 0 )
T1_FIELD_STRING( "Registry", registry, 0 )
T1_FIELD_STRING( "Ordering", ordering, 0 )
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvbsln.c b/src/3rdparty/freetype/src/gxvalid/gxvbsln.c
index 6cca65831e..3d10031563 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvbsln.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvbsln.c
@@ -71,10 +71,10 @@
static void
gxv_bsln_LookupValue_validate( FT_UShort glyph,
- GXV_LookupValueDesc value,
+ GXV_LookupValueCPtr value_p,
GXV_Validator valid )
{
- FT_UShort v = value.u;
+ FT_UShort v = value_p->u;
FT_UShort* ctlPoints;
FT_UNUSED( glyph );
@@ -122,7 +122,7 @@
static GXV_LookupValueDesc
gxv_bsln_LookupFmt4_transit( FT_UShort relative_gindex,
- GXV_LookupValueDesc base_value,
+ GXV_LookupValueCPtr base_value_p,
FT_Bytes lookuptbl_limit,
GXV_Validator valid )
{
@@ -132,7 +132,7 @@
GXV_LookupValueDesc value;
/* XXX: check range ? */
- offset = (FT_UShort)( base_value.u +
+ offset = (FT_UShort)( base_value_p->u +
( relative_gindex * sizeof ( FT_UShort ) ) );
p = valid->lookuptbl_head + offset;
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvcommn.c b/src/3rdparty/freetype/src/gxvalid/gxvcommn.c
index 46fc123fe4..de7ce6fdef 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvcommn.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvcommn.c
@@ -4,7 +4,8 @@
/* */
/* TrueTypeGX/AAT common tables validation (body). */
/* */
-/* Copyright 2004, 2005 by suzuki toshiya, Masatake YAMATO, Red Hat K.K., */
+/* Copyright 2004, 2005, 2009 */
+/* by suzuki toshiya, Masatake YAMATO, Red Hat K.K., */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -404,8 +405,8 @@
if ( UNITSIZE != CORRECTSIZE ) \
{ \
FT_ERROR(( "unitSize=%d differs from" \
- "expected unitSize=%d" \
- "in LookupTable %s", \
+ " expected unitSize=%d" \
+ " in LookupTable %s\n", \
UNITSIZE, CORRECTSIZE, FORMAT )); \
if ( UNITSIZE != 0 && NUNITS != 0 ) \
{ \
@@ -447,7 +448,7 @@
}
value = GXV_LOOKUP_VALUE_LOAD( p, valid->lookupval_sign );
- valid->lookupval_func( i, value, valid );
+ valid->lookupval_func( i, &value, valid );
}
valid->subtable_length = p - table;
@@ -552,7 +553,7 @@
}
for ( gid = firstGlyph; gid <= lastGlyph; gid++ )
- valid->lookupval_func( gid, value, valid );
+ valid->lookupval_func( gid, &value, valid );
}
gxv_LookupTable_fmt2_skip_endmarkers( p, unitSize, valid );
@@ -630,11 +631,11 @@
for ( gid = firstGlyph; gid <= lastGlyph; gid++ )
{
value = valid->lookupfmt4_trans( (FT_UShort)( gid - firstGlyph ),
- base_value,
+ &base_value,
limit,
valid );
- valid->lookupval_func( gid, value, valid );
+ valid->lookupval_func( gid, &value, valid );
}
}
@@ -709,7 +710,7 @@
}
prev_glyph = glyph;
- valid->lookupval_func( glyph, value, valid );
+ valid->lookupval_func( glyph, &value, valid );
}
gxv_LookupTable_fmt6_skip_endmarkers( p, unitSize, valid );
@@ -749,7 +750,7 @@
{
GXV_LIMIT_CHECK( 2 );
value = GXV_LOOKUP_VALUE_LOAD( p, valid->lookupval_sign );
- valid->lookupval_func( (FT_UShort)( firstGlyph + i ), value, valid );
+ valid->lookupval_func( (FT_UShort)( firstGlyph + i ), &value, valid );
}
valid->subtable_length = p - table;
@@ -1180,7 +1181,7 @@
if ( NULL != valid->statetable.entry_validate_func )
valid->statetable.entry_validate_func( state,
flags,
- glyphOffset,
+ &glyphOffset,
statetable_table,
statetable_limit,
valid );
@@ -1351,15 +1352,15 @@
static void
gxv_XClassTable_lookupval_validate( FT_UShort glyph,
- GXV_LookupValueDesc value,
+ GXV_LookupValueCPtr value_p,
GXV_Validator valid )
{
FT_UNUSED( glyph );
- if ( value.u >= valid->xstatetable.nClasses )
+ if ( value_p->u >= valid->xstatetable.nClasses )
FT_INVALID_DATA;
- if ( value.u > valid->xstatetable.maxClassID )
- valid->xstatetable.maxClassID = value.u;
+ if ( value_p->u > valid->xstatetable.maxClassID )
+ valid->xstatetable.maxClassID = value_p->u;
}
@@ -1391,7 +1392,7 @@
*/
static GXV_LookupValueDesc
gxv_XClassTable_lookupfmt4_transit( FT_UShort relative_gindex,
- GXV_LookupValueDesc base_value,
+ GXV_LookupValueCPtr base_value_p,
FT_Bytes lookuptbl_limit,
GXV_Validator valid )
{
@@ -1401,7 +1402,7 @@
GXV_LookupValueDesc value;
/* XXX: check range? */
- offset = (FT_UShort)( base_value.u +
+ offset = (FT_UShort)( base_value_p->u +
relative_gindex * sizeof ( FT_UShort ) );
p = valid->lookuptbl_head + offset;
@@ -1555,7 +1556,7 @@
if ( NULL != valid->xstatetable.entry_validate_func )
valid->xstatetable.entry_validate_func( state,
flags,
- glyphOffset,
+ &glyphOffset,
xstatetable_table,
xstatetable_limit,
valid );
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvcommn.h b/src/3rdparty/freetype/src/gxvalid/gxvcommn.h
index 198d8e4fc5..404c07ffad 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvcommn.h
+++ b/src/3rdparty/freetype/src/gxvalid/gxvcommn.h
@@ -79,6 +79,8 @@ FT_BEGIN_HEADER
} GXV_LookupValueDesc;
+ typedef const GXV_LookupValueDesc* GXV_LookupValueCPtr;
+
typedef enum GXV_LookupValue_SignSpec_
{
GXV_LOOKUPVALUE_UNSIGNED = 0,
@@ -89,12 +91,12 @@ FT_BEGIN_HEADER
typedef void
(*GXV_Lookup_Value_Validate_Func)( FT_UShort glyph,
- GXV_LookupValueDesc value,
+ GXV_LookupValueCPtr value_p,
GXV_Validator valid );
typedef GXV_LookupValueDesc
(*GXV_Lookup_Fmt4_Transit_Func)( FT_UShort relative_gindex,
- GXV_LookupValueDesc base_value,
+ GXV_LookupValueCPtr base_value_p,
FT_Bytes lookuptbl_limit,
GXV_Validator valid );
@@ -134,6 +136,7 @@ FT_BEGIN_HEADER
} GXV_StateTable_GlyphOffsetDesc;
+ typedef const GXV_StateTable_GlyphOffsetDesc* GXV_StateTable_GlyphOffsetCPtr;
typedef void
(*GXV_StateTable_Subtable_Setup_Func)( FT_UShort table_size,
@@ -149,7 +152,7 @@ FT_BEGIN_HEADER
(*GXV_StateTable_Entry_Validate_Func)(
FT_Byte state,
FT_UShort flags,
- GXV_StateTable_GlyphOffsetDesc glyphOffset,
+ GXV_StateTable_GlyphOffsetCPtr glyphOffset_p,
FT_Bytes statetable_table,
FT_Bytes statetable_limit,
GXV_Validator valid );
@@ -175,6 +178,8 @@ FT_BEGIN_HEADER
typedef GXV_StateTable_GlyphOffsetDesc GXV_XStateTable_GlyphOffsetDesc;
+ typedef const GXV_XStateTable_GlyphOffsetDesc* GXV_XStateTable_GlyphOffsetCPtr;
+
typedef void
(*GXV_XStateTable_Subtable_Setup_Func)( FT_ULong table_size,
FT_ULong classTable,
@@ -189,7 +194,7 @@ FT_BEGIN_HEADER
(*GXV_XStateTable_Entry_Validate_Func)(
FT_UShort state,
FT_UShort flags,
- GXV_StateTable_GlyphOffsetDesc glyphOffset,
+ GXV_StateTable_GlyphOffsetCPtr glyphOffset_p,
FT_Bytes xstatetable_table,
FT_Bytes xstatetable_limit,
GXV_Validator valid );
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvfeat.c b/src/3rdparty/freetype/src/gxvalid/gxvfeat.c
index ad30a764c6..002fec6d6b 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvfeat.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvfeat.c
@@ -199,7 +199,7 @@
FT_UShort feature;
FT_UShort nSettings;
- FT_UInt settingTable;
+ FT_ULong settingTable;
FT_UShort featureFlags;
FT_Bool exclusive;
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvjust.c b/src/3rdparty/freetype/src/gxvalid/gxvjust.c
index 29bf840b57..e14f946f2d 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvjust.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvjust.c
@@ -323,15 +323,15 @@
static void
gxv_just_pcTable_LookupValue_entry_validate( FT_UShort glyph,
- GXV_LookupValueDesc value,
+ GXV_LookupValueCPtr value_p,
GXV_Validator valid )
{
FT_UNUSED( glyph );
- if ( value.u > GXV_JUST_DATA( pc_offset_max ) )
- GXV_JUST_DATA( pc_offset_max ) = value.u;
- if ( value.u < GXV_JUST_DATA( pc_offset_max ) )
- GXV_JUST_DATA( pc_offset_min ) = value.u;
+ if ( value_p->u > GXV_JUST_DATA( pc_offset_max ) )
+ GXV_JUST_DATA( pc_offset_max ) = value_p->u;
+ if ( value_p->u < GXV_JUST_DATA( pc_offset_max ) )
+ GXV_JUST_DATA( pc_offset_min ) = value_p->u;
}
@@ -384,7 +384,7 @@
gxv_just_classTable_entry_validate(
FT_Byte state,
FT_UShort flags,
- GXV_StateTable_GlyphOffsetDesc glyphOffset,
+ GXV_StateTable_GlyphOffsetCPtr glyphOffset_p,
FT_Bytes table,
FT_Bytes limit,
GXV_Validator valid )
@@ -395,7 +395,7 @@
FT_UShort currentClass;
FT_UNUSED( state );
- FT_UNUSED( glyphOffset );
+ FT_UNUSED( glyphOffset_p );
FT_UNUSED( table );
FT_UNUSED( limit );
FT_UNUSED( valid );
@@ -449,15 +449,15 @@
static void
gxv_just_wdcTable_LookupValue_validate( FT_UShort glyph,
- GXV_LookupValueDesc value,
+ GXV_LookupValueCPtr value_p,
GXV_Validator valid )
{
FT_UNUSED( glyph );
- if ( value.u > GXV_JUST_DATA( wdc_offset_max ) )
- GXV_JUST_DATA( wdc_offset_max ) = value.u;
- if ( value.u < GXV_JUST_DATA( wdc_offset_min ) )
- GXV_JUST_DATA( wdc_offset_min ) = value.u;
+ if ( value_p->u > GXV_JUST_DATA( wdc_offset_max ) )
+ GXV_JUST_DATA( wdc_offset_max ) = value_p->u;
+ if ( value_p->u < GXV_JUST_DATA( wdc_offset_min ) )
+ GXV_JUST_DATA( wdc_offset_min ) = value_p->u;
}
@@ -557,7 +557,7 @@
{
FT_Bytes p = table;
FT_Bytes limit = 0;
- FT_UInt table_size;
+ FT_Offset table_size;
GXV_ValidatorRec validrec;
GXV_Validator valid = &validrec;
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvkern.c b/src/3rdparty/freetype/src/gxvalid/gxvkern.c
index bfb405f65b..2137db842a 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvkern.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvkern.c
@@ -256,7 +256,7 @@
gxv_kern_subtable_fmt1_entry_validate(
FT_Byte state,
FT_UShort flags,
- GXV_StateTable_GlyphOffsetDesc glyphOffset,
+ GXV_StateTable_GlyphOffsetCPtr glyphOffset_p,
FT_Bytes table,
FT_Bytes limit,
GXV_Validator valid )
@@ -268,7 +268,7 @@
FT_UShort kernValue;
FT_UNUSED( state );
- FT_UNUSED( glyphOffset );
+ FT_UNUSED( glyphOffset_p );
push = (FT_UShort)( ( flags >> 15 ) & 1 );
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvlcar.c b/src/3rdparty/freetype/src/gxvalid/gxvlcar.c
index 48821ea879..f14fa5b131 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvlcar.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvlcar.c
@@ -83,10 +83,10 @@
static void
gxv_lcar_LookupValue_validate( FT_UShort glyph,
- GXV_LookupValueDesc value,
+ GXV_LookupValueCPtr value_p,
GXV_Validator valid )
{
- FT_Bytes p = valid->root->base + value.u;
+ FT_Bytes p = valid->root->base + value_p->u;
FT_Bytes limit = valid->root->limit;
FT_UShort count;
FT_Short partial;
@@ -146,7 +146,7 @@
static GXV_LookupValueDesc
gxv_lcar_LookupFmt4_transit( FT_UShort relative_gindex,
- GXV_LookupValueDesc base_value,
+ GXV_LookupValueCPtr base_value_p,
FT_Bytes lookuptbl_limit,
GXV_Validator valid )
{
@@ -158,7 +158,7 @@
FT_UNUSED( lookuptbl_limit );
/* XXX: check range? */
- offset = (FT_UShort)( base_value.u +
+ offset = (FT_UShort)( base_value_p->u +
relative_gindex * sizeof ( FT_UShort ) );
p = valid->root->base + offset;
limit = valid->root->limit;
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmod.h b/src/3rdparty/freetype/src/gxvalid/gxvmod.h
index 466584ef4f..d912a8f838 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmod.h
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmod.h
@@ -34,6 +34,10 @@
FT_BEGIN_HEADER
+#ifdef FT_CONFIG_OPTION_PIC
+#error "this module does not support PIC yet"
+#endif
+
FT_EXPORT_VAR( const FT_Module_Class ) gxv_module_class;
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmort.c b/src/3rdparty/freetype/src/gxvalid/gxvmort.c
index f4fbd30e41..0aa066339d 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmort.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmort.c
@@ -85,17 +85,17 @@
/*
- * nFeatureFlags is typed to FT_UInt to accept that in
+ * nFeatureFlags is typed to FT_ULong to accept that in
* mort (typed FT_UShort) and morx (typed FT_ULong).
*/
FT_LOCAL_DEF( void )
gxv_mort_featurearray_validate( FT_Bytes table,
FT_Bytes limit,
- FT_UInt nFeatureFlags,
+ FT_ULong nFeatureFlags,
GXV_Validator valid )
{
FT_Bytes p = table;
- FT_UInt i;
+ FT_ULong i;
GXV_mort_featureRec f = GXV_MORT_FEATURE_OFF;
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmort.h b/src/3rdparty/freetype/src/gxvalid/gxvmort.h
index 1d64e69c47..1e5a1f5ab6 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmort.h
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmort.h
@@ -54,7 +54,7 @@
FT_LOCAL( void )
gxv_mort_featurearray_validate( FT_Bytes table,
FT_Bytes limit,
- FT_UInt nFeatureFlags,
+ FT_ULong nFeatureFlags,
GXV_Validator valid );
FT_LOCAL( void )
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmort0.c b/src/3rdparty/freetype/src/gxvalid/gxvmort0.c
index 0902056c62..0453062f63 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmort0.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmort0.c
@@ -64,7 +64,7 @@
gxv_mort_subtable_type0_entry_validate(
FT_Byte state,
FT_UShort flags,
- GXV_StateTable_GlyphOffsetDesc glyphOffset,
+ GXV_StateTable_GlyphOffsetCPtr glyphOffset_p,
FT_Bytes table,
FT_Bytes limit,
GXV_Validator valid )
@@ -80,7 +80,7 @@
FT_UNUSED( limit );
FT_UNUSED( GXV_Mort_IndicScript_Msg[verb] ); /* for the non-debugging */
- FT_UNUSED( glyphOffset ); /* case */
+ FT_UNUSED( glyphOffset_p ); /* case */
markFirst = (FT_UShort)( ( flags >> 15 ) & 1 );
@@ -91,7 +91,7 @@
verb = (FT_UShort)( flags & 0x000F );
GXV_TRACE(( " IndicScript MorphRule for glyphOffset 0x%04x",
- glyphOffset.u ));
+ glyphOffset_p->u ));
GXV_TRACE(( " markFirst=%01d", markFirst ));
GXV_TRACE(( " dontAdvance=%01d", dontAdvance ));
GXV_TRACE(( " markLast=%01d", markLast ));
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmort1.c b/src/3rdparty/freetype/src/gxvalid/gxvmort1.c
index 711bbd0baa..696d85032d 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmort1.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmort1.c
@@ -135,7 +135,7 @@
gxv_mort_subtable_type1_entry_validate(
FT_Byte state,
FT_UShort flags,
- GXV_StateTable_GlyphOffsetDesc glyphOffset,
+ GXV_StateTable_GlyphOffsetCPtr glyphOffset_p,
FT_Bytes table,
FT_Bytes limit,
GXV_Validator valid )
@@ -154,8 +154,8 @@
dontAdvance = (FT_UShort)( ( flags >> 14 ) & 1 );
reserved = (FT_Short)( flags & 0x3FFF );
- markOffset = (FT_Short)( glyphOffset.ul >> 16 );
- currentOffset = (FT_Short)( glyphOffset.ul );
+ markOffset = (FT_Short)( glyphOffset_p->ul >> 16 );
+ currentOffset = (FT_Short)( glyphOffset_p->ul );
if ( 0 < reserved )
{
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmort2.c b/src/3rdparty/freetype/src/gxvalid/gxvmort2.c
index f19d15dab5..6f77cf39ce 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmort2.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmort2.c
@@ -189,7 +189,7 @@
gxv_mort_subtable_type2_entry_validate(
FT_Byte state,
FT_UShort flags,
- GXV_StateTable_GlyphOffsetDesc glyphOffset,
+ GXV_StateTable_GlyphOffsetCPtr glyphOffset_p,
FT_Bytes table,
FT_Bytes limit,
GXV_Validator valid )
@@ -199,7 +199,7 @@
FT_UShort offset;
FT_UNUSED( state );
- FT_UNUSED( glyphOffset );
+ FT_UNUSED( glyphOffset_p );
FT_UNUSED( limit );
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmort4.c b/src/3rdparty/freetype/src/gxvalid/gxvmort4.c
index a04bc1efaf..83470988c0 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmort4.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmort4.c
@@ -40,12 +40,12 @@
static void
gxv_mort_subtable_type4_lookupval_validate( FT_UShort glyph,
- GXV_LookupValueDesc value,
+ GXV_LookupValueCPtr value_p,
GXV_Validator valid )
{
FT_UNUSED( glyph );
- gxv_glyphid_validate( value.u, valid );
+ gxv_glyphid_validate( value_p->u, valid );
}
/*
@@ -78,7 +78,7 @@
static GXV_LookupValueDesc
gxv_mort_subtable_type4_lookupfmt4_transit(
FT_UShort relative_gindex,
- GXV_LookupValueDesc base_value,
+ GXV_LookupValueCPtr base_value_p,
FT_Bytes lookuptbl_limit,
GXV_Validator valid )
{
@@ -88,7 +88,7 @@
GXV_LookupValueDesc value;
/* XXX: check range? */
- offset = (FT_UShort)( base_value.u +
+ offset = (FT_UShort)( base_value_p->u +
relative_gindex * sizeof ( FT_UShort ) );
p = valid->lookuptbl_head + offset;
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmort5.c b/src/3rdparty/freetype/src/gxvalid/gxvmort5.c
index a7cabc359f..ec0bcb634d 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmort5.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmort5.c
@@ -139,7 +139,7 @@
gxv_mort_subtable_type5_entry_validate(
FT_Byte state,
FT_UShort flags,
- GXV_StateTable_GlyphOffsetDesc glyphOffset,
+ GXV_StateTable_GlyphOffsetCPtr glyphOffset,
FT_Bytes table,
FT_Bytes limit,
GXV_Validator valid )
@@ -168,8 +168,8 @@
currentInsertCount = (FT_Byte)( ( flags >> 5 ) & 0x1F );
markedInsertCount = (FT_Byte)( flags & 0x001F );
- currentInsertList = (FT_UShort)( glyphOffset.ul >> 16 );
- markedInsertList = (FT_UShort)( glyphOffset.ul );
+ currentInsertList = (FT_UShort)( glyphOffset->ul >> 16 );
+ markedInsertList = (FT_UShort)( glyphOffset->ul );
if ( 0 != currentInsertList && 0 != currentInsertCount )
{
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmorx.c b/src/3rdparty/freetype/src/gxvalid/gxvmorx.c
index d217940eab..f8ba5b985d 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmorx.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmorx.c
@@ -69,8 +69,8 @@
FT_ULong length;
FT_ULong coverage;
FT_ULong subFeatureFlags;
- FT_UInt type;
- FT_UInt rest;
+ FT_ULong type;
+ FT_ULong rest;
GXV_LIMIT_CHECK( 4 + 4 + 4 );
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmorx0.c b/src/3rdparty/freetype/src/gxvalid/gxvmorx0.c
index ca92b6c392..0159c5aef7 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmorx0.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmorx0.c
@@ -42,7 +42,7 @@
gxv_morx_subtable_type0_entry_validate(
FT_UShort state,
FT_UShort flags,
- GXV_XStateTable_GlyphOffsetDesc glyphOffset,
+ GXV_XStateTable_GlyphOffsetCPtr glyphOffset_p,
FT_Bytes table,
FT_Bytes limit,
GXV_Validator valid )
@@ -54,7 +54,7 @@
FT_UShort verb;
FT_UNUSED( state );
- FT_UNUSED( glyphOffset );
+ FT_UNUSED( glyphOffset_p );
FT_UNUSED( table );
FT_UNUSED( limit );
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmorx1.c b/src/3rdparty/freetype/src/gxvalid/gxvmorx1.c
index 331d4ccdab..e1c162fa0c 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmorx1.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmorx1.c
@@ -103,7 +103,7 @@
gxv_morx_subtable_type1_entry_validate(
FT_UShort state,
FT_UShort flags,
- GXV_StateTable_GlyphOffsetDesc glyphOffset,
+ GXV_StateTable_GlyphOffsetCPtr glyphOffset_p,
FT_Bytes table,
FT_Bytes limit,
GXV_Validator valid )
@@ -127,8 +127,8 @@
reserved = (FT_UShort)( flags & 0x3FFF );
- markIndex = (FT_Short)( glyphOffset.ul >> 16 );
- currentIndex = (FT_Short)( glyphOffset.ul );
+ markIndex = (FT_Short)( glyphOffset_p->ul >> 16 );
+ currentIndex = (FT_Short)( glyphOffset_p->ul );
GXV_TRACE(( " setMark=%01d dontAdvance=%01d\n",
setMark, dontAdvance ));
@@ -155,14 +155,14 @@
static void
gxv_morx_subtable_type1_LookupValue_validate( FT_UShort glyph,
- GXV_LookupValueDesc value,
+ GXV_LookupValueCPtr value_p,
GXV_Validator valid )
{
FT_UNUSED( glyph ); /* for the non-debugging case */
- GXV_TRACE(( "morx subtable type1 subst.: %d -> %d\n", glyph, value.u ));
+ GXV_TRACE(( "morx subtable type1 subst.: %d -> %d\n", glyph, value_p->u ));
- if ( value.u > valid->face->num_glyphs )
+ if ( value_p->u > valid->face->num_glyphs )
FT_INVALID_GLYPH_ID;
}
@@ -170,7 +170,7 @@
static GXV_LookupValueDesc
gxv_morx_subtable_type1_LookupFmt4_transit(
FT_UShort relative_gindex,
- GXV_LookupValueDesc base_value,
+ GXV_LookupValueCPtr base_value_p,
FT_Bytes lookuptbl_limit,
GXV_Validator valid )
{
@@ -180,7 +180,7 @@
GXV_LookupValueDesc value;
/* XXX: check range? */
- offset = (FT_UShort)( base_value.u +
+ offset = (FT_UShort)( base_value_p->u +
relative_gindex * sizeof ( FT_UShort ) );
p = valid->lookuptbl_head + offset;
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmorx2.c b/src/3rdparty/freetype/src/gxvalid/gxvmorx2.c
index 5cad5169c2..b4bb3353f6 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmorx2.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmorx2.c
@@ -186,7 +186,7 @@
gxv_morx_subtable_type2_entry_validate(
FT_UShort state,
FT_UShort flags,
- GXV_StateTable_GlyphOffsetDesc glyphOffset,
+ GXV_StateTable_GlyphOffsetCPtr glyphOffset_p,
FT_Bytes table,
FT_Bytes limit,
GXV_Validator valid )
@@ -206,7 +206,7 @@
performAction = (FT_UShort)( ( flags >> 13 ) & 1 );
reserved = (FT_UShort)( flags & 0x1FFF );
- ligActionIndex = glyphOffset.u;
+ ligActionIndex = glyphOffset_p->u;
if ( reserved > 0 )
GXV_TRACE(( " reserved 14bit is non-zero\n" ));
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvmorx5.c b/src/3rdparty/freetype/src/gxvalid/gxvmorx5.c
index d9115618c0..5e3a16437e 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvmorx5.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvmorx5.c
@@ -136,7 +136,7 @@
gxv_morx_subtable_type5_entry_validate(
FT_UShort state,
FT_UShort flags,
- GXV_StateTable_GlyphOffsetDesc glyphOffset,
+ GXV_StateTable_GlyphOffsetCPtr glyphOffset_p,
FT_Bytes table,
FT_Bytes limit,
GXV_Validator valid )
@@ -165,8 +165,8 @@
currentInsertCount = (FT_Byte)( ( flags >> 5 ) & 0x1F );
markedInsertCount = (FT_Byte)( flags & 0x001F );
- currentInsertList = (FT_Byte) ( glyphOffset.ul >> 16 );
- markedInsertList = (FT_UShort)( glyphOffset.ul );
+ currentInsertList = (FT_Byte) ( glyphOffset_p->ul >> 16 );
+ markedInsertList = (FT_UShort)( glyphOffset_p->ul );
if ( currentInsertList && 0 != currentInsertCount )
gxv_morx_subtable_type5_InsertList_validate( currentInsertList,
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvopbd.c b/src/3rdparty/freetype/src/gxvalid/gxvopbd.c
index 8d6fe669f3..e125060946 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvopbd.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvopbd.c
@@ -67,18 +67,18 @@
static void
gxv_opbd_LookupValue_validate( FT_UShort glyph,
- GXV_LookupValueDesc value,
+ GXV_LookupValueCPtr value_p,
GXV_Validator valid )
{
/* offset in LookupTable is measured from the head of opbd table */
- FT_Bytes p = valid->root->base + value.u;
+ FT_Bytes p = valid->root->base + value_p->u;
FT_Bytes limit = valid->root->limit;
FT_Short delta_value;
int i;
- if ( value.u < GXV_OPBD_DATA( valueOffset_min ) )
- GXV_OPBD_DATA( valueOffset_min ) = value.u;
+ if ( value_p->u < GXV_OPBD_DATA( valueOffset_min ) )
+ GXV_OPBD_DATA( valueOffset_min ) = value_p->u;
for ( i = 0; i < 4; i++ )
{
@@ -132,7 +132,7 @@
static GXV_LookupValueDesc
gxv_opbd_LookupFmt4_transit( FT_UShort relative_gindex,
- GXV_LookupValueDesc base_value,
+ GXV_LookupValueCPtr base_value_p,
FT_Bytes lookuptbl_limit,
GXV_Validator valid )
{
@@ -142,7 +142,7 @@
FT_UNUSED( valid );
/* XXX: check range? */
- value.u = (FT_UShort)( base_value.u +
+ value.u = (FT_UShort)( base_value_p->u +
relative_gindex * 4 * sizeof ( FT_Short ) );
return value;
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvprop.c b/src/3rdparty/freetype/src/gxvalid/gxvprop.c
index 010eeda426..66c3ab7404 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvprop.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvprop.c
@@ -168,10 +168,10 @@
static void
gxv_prop_LookupValue_validate( FT_UShort glyph,
- GXV_LookupValueDesc value,
+ GXV_LookupValueCPtr value_p,
GXV_Validator valid )
{
- gxv_prop_property_validate( value.u, glyph, valid );
+ gxv_prop_property_validate( value_p->u, glyph, valid );
}
@@ -204,7 +204,7 @@
static GXV_LookupValueDesc
gxv_prop_LookupFmt4_transit( FT_UShort relative_gindex,
- GXV_LookupValueDesc base_value,
+ GXV_LookupValueCPtr base_value_p,
FT_Bytes lookuptbl_limit,
GXV_Validator valid )
{
@@ -214,7 +214,7 @@
GXV_LookupValueDesc value;
/* XXX: check range? */
- offset = (FT_UShort)( base_value.u +
+ offset = (FT_UShort)( base_value_p->u +
relative_gindex * sizeof( FT_UShort ) );
p = valid->lookuptbl_head + offset;
limit = lookuptbl_limit;
diff --git a/src/3rdparty/freetype/src/gxvalid/gxvtrak.c b/src/3rdparty/freetype/src/gxvalid/gxvtrak.c
index 432ee4e271..df3fd15c0b 100644
--- a/src/3rdparty/freetype/src/gxvalid/gxvtrak.c
+++ b/src/3rdparty/freetype/src/gxvalid/gxvtrak.c
@@ -198,7 +198,7 @@
{
FT_Bytes p = table;
FT_Bytes limit = 0;
- FT_UInt table_size;
+ FT_Offset table_size;
GXV_ValidatorRec validrec;
GXV_Validator valid = &validrec;
diff --git a/src/3rdparty/freetype/src/gzip/adler32.c b/src/3rdparty/freetype/src/gzip/adler32.c
index 36f6a432ea..c53f9dd125 100644
--- a/src/3rdparty/freetype/src/gzip/adler32.c
+++ b/src/3rdparty/freetype/src/gzip/adler32.c
@@ -3,7 +3,7 @@
* For conditions of distribution and use, see copyright notice in zlib.h
*/
-/* @(#) $Id: adler32.c,v 1.5 2007/06/01 06:56:17 wl Exp $ */
+/* @(#) $Id$ */
#include "zlib.h"
diff --git a/src/3rdparty/freetype/src/gzip/ftgzip.c b/src/3rdparty/freetype/src/gzip/ftgzip.c
index 0d6bd34956..6f0c515723 100644
--- a/src/3rdparty/freetype/src/gzip/ftgzip.c
+++ b/src/3rdparty/freetype/src/gzip/ftgzip.c
@@ -40,6 +40,10 @@
#ifdef FT_CONFIG_OPTION_USE_ZLIB
+#ifdef FT_CONFIG_OPTION_PIC
+#error "gzip code does not support PIC yet"
+#endif
+
#ifdef FT_CONFIG_OPTION_SYSTEM_ZLIB
#include <zlib.h>
@@ -54,7 +58,9 @@
/* original ZLib. */
#define NO_DUMMY_DECL
-#define MY_ZCALLOC
+#ifndef USE_ZLIB_ZCALLOC
+#define MY_ZCALLOC /* prevent all zcalloc() & zfree() in zutils.c */
+#endif
#include "zlib.h"
@@ -117,7 +123,7 @@
}
-#ifndef FT_CONFIG_OPTION_SYSTEM_ZLIB
+#if !defined( FT_CONFIG_OPTION_SYSTEM_ZLIB ) && !defined( USE_ZLIB_ZCALLOC )
local voidpf
zcalloc ( voidpf opaque,
@@ -134,7 +140,7 @@
ft_gzip_free( (FT_Memory)opaque, ptr );
}
-#endif /* !SYSTEM_ZLIB */
+#endif /* !SYSTEM_ZLIB && !USE_ZLIB_ZCALLOC */
/***************************************************************************/
diff --git a/src/3rdparty/freetype/src/gzip/zconf.h b/src/3rdparty/freetype/src/gzip/zconf.h
index 2030a7e8d4..bdaf57e300 100644
--- a/src/3rdparty/freetype/src/gzip/zconf.h
+++ b/src/3rdparty/freetype/src/gzip/zconf.h
@@ -3,7 +3,7 @@
* For conditions of distribution and use, see copyright notice in zlib.h
*/
-/* @(#) $Id: zconf.h,v 1.4 2007/06/01 06:56:17 wl Exp $ */
+/* @(#) $Id$ */
#if defined(__ARMCC__) || defined(__CC_ARM)
/* Ultra ugly hack that convinces RVCT to use the systems zlib */
@@ -65,6 +65,12 @@
# define MSDOS
#endif
+/* WinCE doesn't have errno.h */
+#ifdef _WIN32_WCE
+# define NO_ERRNO_H
+#endif
+
+
/*
* Compile with -DMAXSEG_64K if the alloc function cannot allocate more
* than 64k bytes at a time (needed on systems with 16-bit int).
diff --git a/src/3rdparty/freetype/src/gzip/zutil.c b/src/3rdparty/freetype/src/gzip/zutil.c
index 5ed2da0871..7ad0c1f81b 100644
--- a/src/3rdparty/freetype/src/gzip/zutil.c
+++ b/src/3rdparty/freetype/src/gzip/zutil.c
@@ -3,7 +3,7 @@
* For conditions of distribution and use, see copyright notice in zlib.h
*/
-/* @(#) $Id: zutil.c,v 1.3 2006/04/29 07:31:16 wl Exp $ */
+/* @(#) $Id$ */
#include "zutil.h"
@@ -49,7 +49,7 @@ void zmemzero(dest, len)
}
#endif
-#ifdef __TURBOC__
+#if defined( MSDOS ) && defined( __TURBOC__ ) && !defined( MY_ZCALLOC )
#if (defined( __BORLANDC__) || !defined(SMALL_MEDIUM)) && !defined(__32BIT__)
/* Small and medium model in Turbo C are for now limited to near allocation
* with reduced MAX_WBITS and MAX_MEM_LEVEL
@@ -126,10 +126,10 @@ void zcfree (voidpf opaque, voidpf ptr)
Assert(0, "zcfree: ptr not found");
}
#endif
-#endif /* __TURBOC__ */
+#endif /* MSDOS && __TURBOC__ */
-#if defined(M_I86) && !defined(__32BIT__)
+#if defined(M_I86) && !defined(__32BIT__) && !defined( MY_ZCALLOC )
/* Microsoft C in 16-bit mode */
# define MY_ZCALLOC
diff --git a/src/3rdparty/freetype/src/gzip/zutil.h b/src/3rdparty/freetype/src/gzip/zutil.h
index 9560b48203..1949270998 100644
--- a/src/3rdparty/freetype/src/gzip/zutil.h
+++ b/src/3rdparty/freetype/src/gzip/zutil.h
@@ -8,7 +8,7 @@
subject to change. Applications should only use zlib.h.
*/
-/* @(#) $Id: zutil.h,v 1.6 2007/06/01 06:56:17 wl Exp $ */
+/* @(#) $Id$ */
#ifndef _Z_UTIL_H
#define _Z_UTIL_H
diff --git a/src/3rdparty/freetype/src/lzw/ftlzw.c b/src/3rdparty/freetype/src/lzw/ftlzw.c
index a00bd5012f..6e57dedb97 100644
--- a/src/3rdparty/freetype/src/lzw/ftlzw.c
+++ b/src/3rdparty/freetype/src/lzw/ftlzw.c
@@ -8,7 +8,7 @@
/* be used to parse compressed PCF fonts, as found with many X11 server */
/* distributions. */
/* */
-/* Copyright 2004, 2005, 2006, 2009 by */
+/* Copyright 2004, 2005, 2006, 2009, 2010 by */
/* Albert Chin-A-Young. */
/* */
/* Based on code in src/gzip/ftgzip.c, Copyright 2004 by */
@@ -42,6 +42,10 @@
#ifdef FT_CONFIG_OPTION_USE_LZW
+#ifdef FT_CONFIG_OPTION_PIC
+#error "lzw code does not support PIC yet"
+#endif
+
#include "ftzopen.h"
@@ -118,13 +122,9 @@
zip->pos = 0;
/* check and skip .Z header */
- {
- stream = source;
-
- error = ft_lzw_check_header( source );
- if ( error )
- goto Exit;
- }
+ error = ft_lzw_check_header( source );
+ if ( error )
+ goto Exit;
/* initialize internal lzw variable */
ft_lzwstate_init( lzw, source );
diff --git a/src/3rdparty/freetype/src/lzw/ftzopen.c b/src/3rdparty/freetype/src/lzw/ftzopen.c
index fc7831510d..8bc65c8f57 100644
--- a/src/3rdparty/freetype/src/lzw/ftzopen.c
+++ b/src/3rdparty/freetype/src/lzw/ftzopen.c
@@ -8,7 +8,7 @@
/* be used to parse compressed PCF fonts, as found with many X11 server */
/* distributions. */
/* */
-/* Copyright 2005, 2006, 2007 by David Turner. */
+/* Copyright 2005, 2006, 2007, 2009 by David Turner. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
@@ -113,8 +113,8 @@
{
FT_Memory memory = state->memory;
FT_Error error;
- FT_UInt old_size = state->stack_size;
- FT_UInt new_size = old_size;
+ FT_Offset old_size = state->stack_size;
+ FT_Offset new_size = old_size;
new_size = new_size + ( new_size >> 1 ) + 4;
@@ -332,6 +332,9 @@
while ( code >= 256U )
{
+ if ( !state->prefix )
+ goto Eof;
+
FTLZW_STACK_PUSH( state->suffix[code - 256] );
code = state->prefix[code - 256];
}
diff --git a/src/3rdparty/freetype/src/lzw/ftzopen.h b/src/3rdparty/freetype/src/lzw/ftzopen.h
index dd602402ac..f7d2936be2 100644
--- a/src/3rdparty/freetype/src/lzw/ftzopen.h
+++ b/src/3rdparty/freetype/src/lzw/ftzopen.h
@@ -118,7 +118,7 @@
FT_Int buf_offset;
FT_Int buf_size;
FT_Bool buf_clear;
- FT_Int buf_total;
+ FT_Offset buf_total;
FT_UInt max_bits; /* max code bits, from file header */
FT_Int block_mode; /* block mode flag, from file header */
@@ -137,7 +137,7 @@
FT_Byte* stack; /* character stack */
FT_UInt stack_top;
- FT_UInt stack_size;
+ FT_Offset stack_size;
FT_Byte stack_0[FT_LZW_DEFAULT_STACK_SIZE]; /* minimize heap alloc */
FT_Stream source; /* source stream */
diff --git a/src/3rdparty/freetype/src/otvalid/otvcommn.h b/src/3rdparty/freetype/src/otvalid/otvcommn.h
index 71726d5b2e..898887fc95 100644
--- a/src/3rdparty/freetype/src/otvalid/otvcommn.h
+++ b/src/3rdparty/freetype/src/otvalid/otvcommn.h
@@ -4,7 +4,7 @@
/* */
/* OpenType common tables validation (specification). */
/* */
-/* Copyright 2004, 2005, 2007 by */
+/* Copyright 2004, 2005, 2007, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -85,27 +85,27 @@ FT_BEGIN_HEADER
FT_INVALID_TOO_SHORT; \
FT_END_STMNT
-#define OTV_SIZE_CHECK( _size ) \
- FT_BEGIN_STMNT \
- if ( _size > 0 && _size < table_size ) \
- { \
- if ( valid->root->level == FT_VALIDATE_PARANOID ) \
- FT_INVALID_OFFSET; \
- else \
- { \
- /* strip off `const' */ \
- FT_Byte* pp = (FT_Byte*)_size ## _p; \
- \
- \
- FT_TRACE3(( "\n" \
- "Invalid offset to optional table `%s'!\n" \
- "Set to zero.\n" \
- "\n", #_size )); \
- \
- /* always assume 16bit entities */ \
- _size = pp[0] = pp[1] = 0; \
- } \
- } \
+#define OTV_SIZE_CHECK( _size ) \
+ FT_BEGIN_STMNT \
+ if ( _size > 0 && _size < table_size ) \
+ { \
+ if ( valid->root->level == FT_VALIDATE_PARANOID ) \
+ FT_INVALID_OFFSET; \
+ else \
+ { \
+ /* strip off `const' */ \
+ FT_Byte* pp = (FT_Byte*)_size ## _p; \
+ \
+ \
+ FT_TRACE3(( "\n" \
+ "Invalid offset to optional table `%s'" \
+ " set to zero.\n" \
+ "\n", #_size )); \
+ \
+ /* always assume 16bit entities */ \
+ _size = pp[0] = pp[1] = 0; \
+ } \
+ } \
FT_END_STMNT
diff --git a/src/3rdparty/freetype/src/otvalid/otvgpos.c b/src/3rdparty/freetype/src/otvalid/otvgpos.c
index 53025ec5e6..49b46183a3 100644
--- a/src/3rdparty/freetype/src/otvalid/otvgpos.c
+++ b/src/3rdparty/freetype/src/otvalid/otvgpos.c
@@ -209,7 +209,7 @@
{
if ( format & 1 )
{
- FT_UInt table_size;
+ FT_PtrDist table_size;
OTV_OPTIONAL_TABLE( device );
@@ -911,7 +911,8 @@
{
case 1: /* ExtensionPosFormat1 */
{
- FT_UInt ExtensionLookupType, ExtensionOffset;
+ FT_UInt ExtensionLookupType;
+ FT_ULong ExtensionOffset;
OTV_Validate_Func validate;
diff --git a/src/3rdparty/freetype/src/otvalid/otvgsub.c b/src/3rdparty/freetype/src/otvalid/otvgsub.c
index f01fca1e89..ed499d1e92 100644
--- a/src/3rdparty/freetype/src/otvalid/otvgsub.c
+++ b/src/3rdparty/freetype/src/otvalid/otvgsub.c
@@ -415,7 +415,8 @@
{
case 1: /* ExtensionSubstFormat1 */
{
- FT_UInt ExtensionLookupType, ExtensionOffset;
+ FT_UInt ExtensionLookupType;
+ FT_ULong ExtensionOffset;
OTV_Validate_Func validate;
diff --git a/src/3rdparty/freetype/src/otvalid/otvmod.c b/src/3rdparty/freetype/src/otvalid/otvmod.c
index 63c25f690c..3248564560 100644
--- a/src/3rdparty/freetype/src/otvalid/otvmod.c
+++ b/src/3rdparty/freetype/src/otvalid/otvmod.c
@@ -82,12 +82,25 @@
FT_Byte* volatile math;
FT_ULong len_base, len_gdef, len_gpos, len_gsub, len_jstf;
FT_ULong len_math;
+ FT_UInt num_glyphs = (FT_UInt)face->num_glyphs;
FT_ValidatorRec volatile valid;
base = gdef = gpos = gsub = jstf = math = NULL;
len_base = len_gdef = len_gpos = len_gsub = len_jstf = len_math = 0;
+ /*
+ * XXX: OpenType tables cannot handle 32-bit glyph index,
+ * although broken TrueType can have 32-bit glyph index.
+ */
+ if ( face->num_glyphs > 0xFFFFL )
+ {
+ FT_TRACE1(( "otv_validate: Invalid glyphs index (0x0000FFFF - 0x%08x) ",
+ face->num_glyphs ));
+ FT_TRACE1(( "are not handled by OpenType tables\n" ));
+ num_glyphs = 0xFFFF;
+ }
+
/* load tables */
if ( ot_flags & FT_VALIDATE_BASE )
@@ -148,7 +161,7 @@
{
ft_validator_init( &valid, gpos, gpos + len_gpos, FT_VALIDATE_DEFAULT );
if ( ft_setjmp( valid.jump_buffer ) == 0 )
- otv_GPOS_validate( gpos, face->num_glyphs, &valid );
+ otv_GPOS_validate( gpos, num_glyphs, &valid );
error = valid.error;
if ( error )
goto Exit;
@@ -158,7 +171,7 @@
{
ft_validator_init( &valid, gsub, gsub + len_gsub, FT_VALIDATE_DEFAULT );
if ( ft_setjmp( valid.jump_buffer ) == 0 )
- otv_GSUB_validate( gsub, face->num_glyphs, &valid );
+ otv_GSUB_validate( gsub, num_glyphs, &valid );
error = valid.error;
if ( error )
goto Exit;
@@ -168,7 +181,7 @@
{
ft_validator_init( &valid, gdef, gdef + len_gdef, FT_VALIDATE_DEFAULT );
if ( ft_setjmp( valid.jump_buffer ) == 0 )
- otv_GDEF_validate( gdef, gsub, gpos, face->num_glyphs, &valid );
+ otv_GDEF_validate( gdef, gsub, gpos, num_glyphs, &valid );
error = valid.error;
if ( error )
goto Exit;
@@ -178,7 +191,7 @@
{
ft_validator_init( &valid, jstf, jstf + len_jstf, FT_VALIDATE_DEFAULT );
if ( ft_setjmp( valid.jump_buffer ) == 0 )
- otv_JSTF_validate( jstf, gsub, gpos, face->num_glyphs, &valid );
+ otv_JSTF_validate( jstf, gsub, gpos, num_glyphs, &valid );
error = valid.error;
if ( error )
goto Exit;
@@ -188,7 +201,7 @@
{
ft_validator_init( &valid, math, math + len_math, FT_VALIDATE_DEFAULT );
if ( ft_setjmp( valid.jump_buffer ) == 0 )
- otv_MATH_validate( math, face->num_glyphs, &valid );
+ otv_MATH_validate( math, num_glyphs, &valid );
error = valid.error;
if ( error )
goto Exit;
diff --git a/src/3rdparty/freetype/src/otvalid/otvmod.h b/src/3rdparty/freetype/src/otvalid/otvmod.h
index 1bfc1899fe..573b2a0c4b 100644
--- a/src/3rdparty/freetype/src/otvalid/otvmod.h
+++ b/src/3rdparty/freetype/src/otvalid/otvmod.h
@@ -27,6 +27,10 @@
FT_BEGIN_HEADER
+#ifdef FT_CONFIG_OPTION_PIC
+#error "this module does not support PIC yet"
+#endif
+
FT_EXPORT_VAR( const FT_Module_Class ) otv_module_class;
diff --git a/src/3rdparty/freetype/src/pcf/pcf.h b/src/3rdparty/freetype/src/pcf/pcf.h
index 9d2d8e0e42..1cd56c13a4 100644
--- a/src/3rdparty/freetype/src/pcf/pcf.h
+++ b/src/3rdparty/freetype/src/pcf/pcf.h
@@ -72,8 +72,8 @@ FT_BEGIN_HEADER
union
{
FT_String* atom;
- FT_Long integer;
- FT_ULong cardinal;
+ FT_Long l;
+ FT_ULong ul;
} value;
diff --git a/src/3rdparty/freetype/src/pcf/pcfdrivr.c b/src/3rdparty/freetype/src/pcf/pcfdrivr.c
index e2d4d3d874..b34e542aeb 100644
--- a/src/3rdparty/freetype/src/pcf/pcfdrivr.c
+++ b/src/3rdparty/freetype/src/pcf/pcfdrivr.c
@@ -111,7 +111,7 @@ THE SOFTWARE.
while ( min < max )
{
- FT_UInt32 code;
+ FT_ULong code;
mid = ( min + max ) >> 1;
@@ -140,7 +140,7 @@ THE SOFTWARE.
PCF_CMap cmap = (PCF_CMap)pcfcmap;
PCF_Encoding encodings = cmap->encodings;
FT_UInt min, max, mid;
- FT_UInt32 charcode = *acharcode + 1;
+ FT_ULong charcode = *acharcode + 1;
FT_UInt result = 0;
@@ -149,7 +149,7 @@ THE SOFTWARE.
while ( min < max )
{
- FT_UInt32 code;
+ FT_ULong code;
mid = ( min + max ) >> 1;
@@ -175,7 +175,14 @@ THE SOFTWARE.
}
Exit:
- *acharcode = charcode;
+ if ( charcode > 0xFFFFFFFFUL )
+ {
+ FT_TRACE1(( "pcf_cmap_char_next: charcode 0x%x > 32bit API" ));
+ *acharcode = 0;
+ /* XXX: result should be changed to indicate an overflow error */
+ }
+ else
+ *acharcode = (FT_UInt32)charcode;
return result;
}
@@ -266,19 +273,27 @@ THE SOFTWARE.
error = pcf_load_font( stream, face );
if ( error )
{
- FT_Error error2;
+ PCF_Face_Done( pcfface );
+#if defined( FT_CONFIG_OPTION_USE_ZLIB ) || \
+ defined( FT_CONFIG_OPTION_USE_LZW )
- PCF_Face_Done( pcfface );
+#ifdef FT_CONFIG_OPTION_USE_ZLIB
+ {
+ FT_Error error2;
- /* this didn't work, try gzip support! */
- error2 = FT_Stream_OpenGzip( &face->gzip_stream, stream );
- if ( FT_ERROR_BASE( error2 ) == FT_Err_Unimplemented_Feature )
- goto Fail;
- error = error2;
- if ( error )
+ /* this didn't work, try gzip support! */
+ error2 = FT_Stream_OpenGzip( &face->gzip_stream, stream );
+ if ( FT_ERROR_BASE( error2 ) == FT_Err_Unimplemented_Feature )
+ goto Fail;
+
+ error = error2;
+ }
+#endif /* FT_CONFIG_OPTION_USE_ZLIB */
+
#ifdef FT_CONFIG_OPTION_USE_LZW
+ if ( error )
{
FT_Error error3;
@@ -289,32 +304,26 @@ THE SOFTWARE.
goto Fail;
error = error3;
- if ( error )
- goto Fail;
+ }
+#endif /* FT_CONFIG_OPTION_USE_LZW */
- face->gzip_source = stream;
- pcfface->stream = &face->gzip_stream;
+ if ( error )
+ goto Fail;
- stream = pcfface->stream;
+ face->gzip_source = stream;
+ pcfface->stream = &face->gzip_stream;
- error = pcf_load_font( stream, face );
- if ( error )
- goto Fail;
- }
-#else
+ stream = pcfface->stream;
+
+ error = pcf_load_font( stream, face );
+ if ( error )
goto Fail;
-#endif
- else
- {
- face->gzip_source = stream;
- pcfface->stream = &face->gzip_stream;
- stream = pcfface->stream;
+#else /* !(FT_CONFIG_OPTION_USE_ZLIB || FT_CONFIG_OPTION_USE_LZW) */
- error = pcf_load_font( stream, face );
- if ( error )
- goto Fail;
- }
+ goto Fail;
+
+#endif
}
/* set up charmap */
@@ -446,7 +455,7 @@ THE SOFTWARE.
FT_Error error = PCF_Err_Ok;
FT_Bitmap* bitmap = &slot->bitmap;
PCF_Metric metric;
- int bytes;
+ FT_Offset bytes;
FT_UNUSED( load_flags );
@@ -576,12 +585,17 @@ THE SOFTWARE.
}
else
{
+ if ( prop->value.l > 0x7FFFFFFFL || prop->value.l < ( -1 - 0x7FFFFFFFL ) )
+ {
+ FT_TRACE1(( "pcf_get_bdf_property: " ));
+ FT_TRACE1(( "too large integer 0x%x is truncated\n" ));
+ }
/* Apparently, the PCF driver loads all properties as signed integers!
* This really doesn't seem to be a problem, because this is
* sufficient for any meaningful values.
*/
aproperty->type = BDF_PROPERTY_TYPE_INTEGER;
- aproperty->u.integer = prop->value.integer;
+ aproperty->u.integer = (FT_Int32)prop->value.l;
}
return 0;
}
diff --git a/src/3rdparty/freetype/src/pcf/pcfdrivr.h b/src/3rdparty/freetype/src/pcf/pcfdrivr.h
index 7ddf697e16..a81d7309e5 100644
--- a/src/3rdparty/freetype/src/pcf/pcfdrivr.h
+++ b/src/3rdparty/freetype/src/pcf/pcfdrivr.h
@@ -33,6 +33,10 @@ THE SOFTWARE.
FT_BEGIN_HEADER
+#ifdef FT_CONFIG_OPTION_PIC
+#error "this module does not support PIC yet"
+#endif
+
FT_EXPORT_VAR( const FT_Driver_ClassRec ) pcf_driver_class;
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/pcf/pcfread.c b/src/3rdparty/freetype/src/pcf/pcfread.c
index 8e04c57b31..08becf99ce 100644
--- a/src/3rdparty/freetype/src/pcf/pcfread.c
+++ b/src/3rdparty/freetype/src/pcf/pcfread.c
@@ -32,7 +32,6 @@ THE SOFTWARE.
#include FT_INTERNAL_OBJECTS_H
#include "pcf.h"
-#include "pcfdrivr.h"
#include "pcfread.h"
#include "pcferror.h"
@@ -290,13 +289,13 @@ THE SOFTWARE.
static FT_Error
pcf_seek_to_table_type( FT_Stream stream,
PCF_Table tables,
- FT_Int ntables,
+ FT_ULong ntables, /* same as PCF_Toc->count */
FT_ULong type,
FT_ULong *aformat,
FT_ULong *asize )
{
FT_Error error = PCF_Err_Invalid_File_Format;
- FT_Int i;
+ FT_ULong i;
for ( i = 0; i < ntables; i++ )
@@ -328,10 +327,10 @@ THE SOFTWARE.
static FT_Bool
pcf_has_table_type( PCF_Table tables,
- FT_Int ntables,
+ FT_ULong ntables, /* same as PCF_Toc->count */
FT_ULong type )
{
- FT_Int i;
+ FT_ULong i;
for ( i = 0; i < ntables; i++ )
@@ -400,7 +399,7 @@ THE SOFTWARE.
{
PCF_ParseProperty props = 0;
PCF_Property properties;
- FT_UInt nprops, i;
+ FT_ULong nprops, i;
FT_ULong format, size;
FT_Error error;
FT_Memory memory = FT_FACE(face)->memory;
@@ -434,7 +433,10 @@ THE SOFTWARE.
if ( error )
goto Bail;
- FT_TRACE4(( " nprop = %d\n", nprops ));
+ FT_TRACE4(( " nprop = %d (truncate %d props)\n",
+ (int)nprops, nprops - (int)nprops ));
+
+ nprops = (int)nprops;
/* rough estimate */
if ( nprops > size / PCF_PROPERTY_SIZE )
@@ -443,7 +445,7 @@ THE SOFTWARE.
goto Bail;
}
- face->nprops = nprops;
+ face->nprops = (int)nprops;
if ( FT_NEW_ARRAY( props, nprops ) )
goto Bail;
@@ -543,9 +545,9 @@ THE SOFTWARE.
}
else
{
- properties[i].value.integer = props[i].value;
+ properties[i].value.l = props[i].value;
- FT_TRACE4(( " %d\n", properties[i].value.integer ));
+ FT_TRACE4(( " %d\n", properties[i].value.l ));
}
}
@@ -662,7 +664,7 @@ THE SOFTWARE.
FT_Long* offsets;
FT_Long bitmapSizes[GLYPHPADOPTIONS];
FT_ULong format, size;
- int nbitmaps, i, sizebitmaps = 0;
+ FT_ULong nbitmaps, i, sizebitmaps = 0;
error = pcf_seek_to_table_type( stream,
@@ -693,7 +695,8 @@ THE SOFTWARE.
FT_TRACE4(( " number of bitmaps: %d\n", nbitmaps ));
- if ( nbitmaps != face->nmetrics )
+ /* XXX: PCF_Face->nmetrics is singed FT_Long, see pcf.h */
+ if ( face->nmetrics < 0 || nbitmaps != ( FT_ULong )face->nmetrics )
return PCF_Err_Invalid_File_Format;
if ( FT_NEW_ARRAY( offsets, nbitmaps ) )
@@ -739,8 +742,8 @@ THE SOFTWARE.
if ( ( offsets[i] < 0 ) ||
( (FT_ULong)offsets[i] > size ) )
{
- FT_ERROR(( "pcf_get_bitmaps:"));
- FT_ERROR(( " invalid offset to bitmap data of glyph %d\n", i ));
+ FT_TRACE0(( "pcf_get_bitmaps:"
+ " invalid offset to bitmap data of glyph %d\n", i ));
}
else
face->metrics[i].bits = stream->pos + offsets[i];
@@ -993,9 +996,9 @@ THE SOFTWARE.
PCF_Property prop;
- int nn, len;
- char* strings[4] = { NULL, NULL, NULL, NULL };
- int lengths[4];
+ size_t nn, len;
+ char* strings[4] = { NULL, NULL, NULL, NULL };
+ size_t lengths[4];
face->style_flags = 0;
@@ -1077,7 +1080,7 @@ THE SOFTWARE.
/* add_style_name and setwidth_name */
if ( nn == 0 || nn == 3 )
{
- int mm;
+ size_t mm;
for ( mm = 0; mm < len; mm++ )
@@ -1202,7 +1205,7 @@ THE SOFTWARE.
prop = pcf_find_property( face, "AVERAGE_WIDTH" );
if ( prop )
- bsize->width = (FT_Short)( ( prop->value.integer + 5 ) / 10 );
+ bsize->width = (FT_Short)( ( prop->value.l + 5 ) / 10 );
else
bsize->width = (FT_Short)( bsize->height * 2/3 );
@@ -1210,19 +1213,19 @@ THE SOFTWARE.
if ( prop )
/* convert from 722.7 decipoints to 72 points per inch */
bsize->size =
- (FT_Pos)( ( prop->value.integer * 64 * 7200 + 36135L ) / 72270L );
+ (FT_Pos)( ( prop->value.l * 64 * 7200 + 36135L ) / 72270L );
prop = pcf_find_property( face, "PIXEL_SIZE" );
if ( prop )
- bsize->y_ppem = (FT_Short)prop->value.integer << 6;
+ bsize->y_ppem = (FT_Short)prop->value.l << 6;
prop = pcf_find_property( face, "RESOLUTION_X" );
if ( prop )
- resolution_x = (FT_Short)prop->value.integer;
+ resolution_x = (FT_Short)prop->value.l;
prop = pcf_find_property( face, "RESOLUTION_Y" );
if ( prop )
- resolution_y = (FT_Short)prop->value.integer;
+ resolution_y = (FT_Short)prop->value.l;
if ( bsize->y_ppem == 0 )
{
diff --git a/src/3rdparty/freetype/src/pcf/pcfutil.c b/src/3rdparty/freetype/src/pcf/pcfutil.c
index 67ddbe8890..b91274f935 100644
--- a/src/3rdparty/freetype/src/pcf/pcfutil.c
+++ b/src/3rdparty/freetype/src/pcf/pcfutil.c
@@ -42,9 +42,9 @@ in this Software without prior written authorization from The Open Group.
FT_LOCAL_DEF( void )
BitOrderInvert( unsigned char* buf,
- int nbytes )
+ size_t nbytes )
{
- for ( ; --nbytes >= 0; buf++ )
+ for ( ; nbytes > 0; nbytes--, buf++ )
{
unsigned int val = *buf;
@@ -64,7 +64,7 @@ in this Software without prior written authorization from The Open Group.
FT_LOCAL_DEF( void )
TwoByteSwap( unsigned char* buf,
- int nbytes )
+ size_t nbytes )
{
unsigned char c;
@@ -83,7 +83,7 @@ in this Software without prior written authorization from The Open Group.
FT_LOCAL_DEF( void )
FourByteSwap( unsigned char* buf,
- int nbytes )
+ size_t nbytes )
{
unsigned char c;
diff --git a/src/3rdparty/freetype/src/pcf/pcfutil.h b/src/3rdparty/freetype/src/pcf/pcfutil.h
index 1557be3e80..ce10fb541d 100644
--- a/src/3rdparty/freetype/src/pcf/pcfutil.h
+++ b/src/3rdparty/freetype/src/pcf/pcfutil.h
@@ -37,15 +37,15 @@ FT_BEGIN_HEADER
FT_LOCAL( void )
BitOrderInvert( unsigned char* buf,
- int nbytes );
+ size_t nbytes );
FT_LOCAL( void )
TwoByteSwap( unsigned char* buf,
- int nbytes );
+ size_t nbytes );
FT_LOCAL( void )
FourByteSwap( unsigned char* buf,
- int nbytes );
+ size_t nbytes );
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/pfr/pfrcmap.c b/src/3rdparty/freetype/src/pfr/pfrcmap.c
index d4656d1b5e..9c8f9ed8eb 100644
--- a/src/3rdparty/freetype/src/pfr/pfrcmap.c
+++ b/src/3rdparty/freetype/src/pfr/pfrcmap.c
@@ -4,7 +4,7 @@
/* */
/* FreeType PFR cmap handling (body). */
/* */
-/* Copyright 2002, 2007 by */
+/* Copyright 2002, 2007, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -18,7 +18,6 @@
#include "pfrcmap.h"
#include "pfrobjs.h"
-#include FT_INTERNAL_DEBUG_H
#include "pfrerror.h"
@@ -89,7 +88,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
pfr_cmap_char_next( PFR_CMap cmap,
FT_UInt32 *pchar_code )
{
diff --git a/src/3rdparty/freetype/src/pfr/pfrdrivr.h b/src/3rdparty/freetype/src/pfr/pfrdrivr.h
index 36f1205b77..da0a1aa634 100644
--- a/src/3rdparty/freetype/src/pfr/pfrdrivr.h
+++ b/src/3rdparty/freetype/src/pfr/pfrdrivr.h
@@ -26,6 +26,10 @@
FT_BEGIN_HEADER
+#ifdef FT_CONFIG_OPTION_PIC
+#error "this module does not support PIC yet"
+#endif
+
FT_EXPORT_VAR( const FT_Driver_ClassRec ) pfr_driver_class;
diff --git a/src/3rdparty/freetype/src/pfr/pfrload.c b/src/3rdparty/freetype/src/pfr/pfrload.c
index 1ee2c1f8c8..bc5c035f3d 100644
--- a/src/3rdparty/freetype/src/pfr/pfrload.c
+++ b/src/3rdparty/freetype/src/pfr/pfrload.c
@@ -4,7 +4,7 @@
/* */
/* FreeType PFR loader (body). */
/* */
-/* Copyright 2002, 2003, 2004, 2005, 2007 by */
+/* Copyright 2002, 2003, 2004, 2005, 2007, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -428,7 +428,8 @@
Too_Short:
error = PFR_Err_Invalid_Table;
- FT_ERROR(( "pfr_extra_item_load_bitmap_info: invalid bitmap info table\n" ));
+ FT_ERROR(( "pfr_extra_item_load_bitmap_info:"
+ " invalid bitmap info table\n" ));
goto Exit;
}
@@ -506,7 +507,8 @@
Too_Short:
error = PFR_Err_Invalid_Table;
- FT_ERROR(( "pfr_exta_item_load_stem_snaps: invalid stem snaps table\n" ));
+ FT_ERROR(( "pfr_exta_item_load_stem_snaps:"
+ " invalid stem snaps table\n" ));
goto Exit;
}
@@ -603,8 +605,8 @@
FT_FREE( item );
error = PFR_Err_Invalid_Table;
- FT_ERROR(( "pfr_extra_item_load_kerning_pairs: "
- "invalid kerning pairs table\n" ));
+ FT_ERROR(( "pfr_extra_item_load_kerning_pairs:"
+ " invalid kerning pairs table\n" ));
goto Exit;
}
@@ -714,7 +716,8 @@
{
FT_Error error;
FT_Memory memory = stream->memory;
- FT_UInt flags, num_aux;
+ FT_UInt flags;
+ FT_ULong num_aux;
FT_Byte* p;
FT_Byte* limit;
diff --git a/src/3rdparty/freetype/src/pfr/pfrsbit.c b/src/3rdparty/freetype/src/pfr/pfrsbit.c
index 45ff6663b3..d2f17dc9ce 100644
--- a/src/3rdparty/freetype/src/pfr/pfrsbit.c
+++ b/src/3rdparty/freetype/src/pfr/pfrsbit.c
@@ -4,7 +4,7 @@
/* */
/* FreeType PFR bitmap loader (body). */
/* */
-/* Copyright 2002, 2003, 2006 by */
+/* Copyright 2002, 2003, 2006, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -600,8 +600,8 @@
/* get the bitmap metrics */
{
- FT_Long xpos, ypos, advance;
- FT_UInt xsize, ysize, format;
+ FT_Long xpos = 0, ypos = 0, advance = 0;
+ FT_UInt xsize = 0, ysize = 0, format = 0;
FT_Byte* p;
@@ -630,18 +630,35 @@
&xpos, &ypos,
&xsize, &ysize,
&advance, &format );
+
+ /*
+ * XXX: on 16bit system, we return an error for huge bitmap
+ * which causes a size truncation, because truncated
+ * size properties makes bitmap glyph broken.
+ */
+ if ( xpos > FT_INT_MAX || ( ypos + ysize ) > FT_INT_MAX )
+ {
+ FT_TRACE1(( "pfr_slot_load_bitmap:" ));
+ FT_TRACE1(( "huge bitmap glyph %dx%d over FT_GlyphSlot\n",
+ xpos, ypos ));
+ error = PFR_Err_Invalid_Pixel_Size;
+ }
+
if ( !error )
{
glyph->root.format = FT_GLYPH_FORMAT_BITMAP;
/* Set up glyph bitmap and metrics */
+
+ /* XXX: needs casts to fit FT_Bitmap.{width|rows|pitch} */
glyph->root.bitmap.width = (FT_Int)xsize;
glyph->root.bitmap.rows = (FT_Int)ysize;
- glyph->root.bitmap.pitch = (FT_Long)( xsize + 7 ) >> 3;
+ glyph->root.bitmap.pitch = (FT_Int)( xsize + 7 ) >> 3;
glyph->root.bitmap.pixel_mode = FT_PIXEL_MODE_MONO;
- glyph->root.metrics.width = (FT_Long)xsize << 6;
- glyph->root.metrics.height = (FT_Long)ysize << 6;
+ /* XXX: needs casts to fit FT_Glyph_Metrics.{width|height} */
+ glyph->root.metrics.width = (FT_Pos)xsize << 6;
+ glyph->root.metrics.height = (FT_Pos)ysize << 6;
glyph->root.metrics.horiBearingX = xpos << 6;
glyph->root.metrics.horiBearingY = ypos << 6;
glyph->root.metrics.horiAdvance = FT_PIX_ROUND( ( advance >> 2 ) );
@@ -649,8 +666,9 @@
glyph->root.metrics.vertBearingY = 0;
glyph->root.metrics.vertAdvance = size->root.metrics.height;
- glyph->root.bitmap_left = xpos;
- glyph->root.bitmap_top = ypos + ysize;
+ /* XXX: needs casts fit FT_GlyphSlotRec.bitmap_{left|top} */
+ glyph->root.bitmap_left = (FT_Int)xpos;
+ glyph->root.bitmap_top = (FT_Int)(ypos + ysize);
/* Allocate and read bitmap data */
{
diff --git a/src/3rdparty/freetype/src/pfr/pfrtypes.h b/src/3rdparty/freetype/src/pfr/pfrtypes.h
index c0ae04253a..918310814c 100644
--- a/src/3rdparty/freetype/src/pfr/pfrtypes.h
+++ b/src/3rdparty/freetype/src/pfr/pfrtypes.h
@@ -200,7 +200,7 @@ FT_BEGIN_HEADER
FT_Byte flags;
FT_Short base_adj;
FT_UInt pair_size;
- FT_UInt32 offset;
+ FT_Offset offset;
FT_UInt32 pair1;
FT_UInt32 pair2;
@@ -252,7 +252,7 @@ FT_BEGIN_HEADER
FT_UInt blue_scale;
FT_UInt num_chars;
- FT_UInt32 chars_offset;
+ FT_Offset chars_offset;
PFR_Char chars;
FT_UInt num_kern_pairs;
@@ -260,7 +260,7 @@ FT_BEGIN_HEADER
PFR_KernItem* kern_items_tail;
/* not part of the spec, but used during load */
- FT_UInt32 bct_offset;
+ FT_Long bct_offset;
FT_Byte* cursor;
} PFR_PhyFontRec, *PFR_PhyFont;
diff --git a/src/3rdparty/freetype/src/psaux/afmparse.c b/src/3rdparty/freetype/src/psaux/afmparse.c
index 63a786e888..91a17e2362 100644
--- a/src/3rdparty/freetype/src/psaux/afmparse.c
+++ b/src/3rdparty/freetype/src/psaux/afmparse.c
@@ -4,7 +4,7 @@
/* */
/* AFM parser (body). */
/* */
-/* Copyright 2006, 2007, 2008 by */
+/* Copyright 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -18,7 +18,6 @@
#include <ft2build.h>
#include FT_FREETYPE_H
#include FT_INTERNAL_POSTSCRIPT_AUX_H
-#include FT_INTERNAL_DEBUG_H
#include "afmparse.h"
#include "psconv.h"
@@ -367,11 +366,11 @@
FT_LOCAL_DEF( FT_Int )
afm_parser_read_vals( AFM_Parser parser,
AFM_Value vals,
- FT_Int n )
+ FT_UInt n )
{
AFM_Stream stream = parser->stream;
char* str;
- FT_Int i;
+ FT_UInt i;
if ( n > AFM_MAX_ARGUMENTS )
@@ -379,7 +378,7 @@
for ( i = 0; i < n; i++ )
{
- FT_UInt len;
+ FT_Offset len;
AFM_Value val = vals + i;
@@ -441,7 +440,7 @@
FT_LOCAL_DEF( char* )
afm_parser_next_key( AFM_Parser parser,
FT_Bool line,
- FT_UInt* len )
+ FT_Offset* len )
{
AFM_Stream stream = parser->stream;
char* key = 0; /* make stupid compiler happy */
@@ -489,7 +488,7 @@
}
if ( len )
- *len = ( key ) ? AFM_STREAM_KEY_LEN( stream, key )
+ *len = ( key ) ? (FT_Offset)AFM_STREAM_KEY_LEN( stream, key )
: 0;
return key;
@@ -498,7 +497,7 @@
static AFM_Token
afm_tokenize( const char* key,
- FT_UInt len )
+ FT_Offset len )
{
int n;
@@ -586,7 +585,7 @@
AFM_FontInfo fi = parser->FontInfo;
AFM_TrackKern tk;
char* key;
- FT_UInt len;
+ FT_Offset len;
int n = -1;
@@ -687,7 +686,7 @@
AFM_FontInfo fi = parser->FontInfo;
AFM_KernPair kp;
char* key;
- FT_UInt len;
+ FT_Offset len;
int n = -1;
@@ -775,9 +774,9 @@
static FT_Error
afm_parse_kern_data( AFM_Parser parser )
{
- FT_Error error;
- char* key;
- FT_UInt len;
+ FT_Error error;
+ char* key;
+ FT_Offset len;
while ( ( key = afm_parser_next_key( parser, 1, &len ) ) != 0 )
@@ -819,8 +818,8 @@
FT_UInt n,
AFM_Token end_section )
{
- char* key;
- FT_UInt len;
+ char* key;
+ FT_Offset len;
while ( n-- > 0 )
@@ -851,7 +850,7 @@
AFM_FontInfo fi = parser->FontInfo;
FT_Error error = PSaux_Err_Syntax_Error;
char* key;
- FT_UInt len;
+ FT_Offset len;
FT_Int metrics_sets = 0;
diff --git a/src/3rdparty/freetype/src/psaux/afmparse.h b/src/3rdparty/freetype/src/psaux/afmparse.h
index c2fce75c86..de2a530b2f 100644
--- a/src/3rdparty/freetype/src/psaux/afmparse.h
+++ b/src/3rdparty/freetype/src/psaux/afmparse.h
@@ -71,13 +71,13 @@ FT_BEGIN_HEADER
FT_LOCAL( FT_Int )
afm_parser_read_vals( AFM_Parser parser,
AFM_Value vals,
- FT_Int n );
+ FT_UInt n );
/* read the next key from the next line or column */
FT_LOCAL( char* )
afm_parser_next_key( AFM_Parser parser,
FT_Bool line,
- FT_UInt* len );
+ FT_Offset* len );
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/psaux/psauxmod.h b/src/3rdparty/freetype/src/psaux/psauxmod.h
index 92ac056048..35e042dbce 100644
--- a/src/3rdparty/freetype/src/psaux/psauxmod.h
+++ b/src/3rdparty/freetype/src/psaux/psauxmod.h
@@ -26,6 +26,10 @@
FT_BEGIN_HEADER
+#ifdef FT_CONFIG_OPTION_PIC
+#error "this module does not support PIC yet"
+#endif
+
FT_EXPORT_VAR( const FT_Module_Class ) psaux_driver_class;
diff --git a/src/3rdparty/freetype/src/psaux/psconv.c b/src/3rdparty/freetype/src/psaux/psconv.c
index d824b59139..1531d8f0fb 100644
--- a/src/3rdparty/freetype/src/psaux/psconv.c
+++ b/src/3rdparty/freetype/src/psaux/psconv.c
@@ -4,7 +4,7 @@
/* */
/* Some convenience conversions (body). */
/* */
-/* Copyright 2006, 2008 by */
+/* Copyright 2006, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -18,10 +18,8 @@
#include <ft2build.h>
#include FT_INTERNAL_POSTSCRIPT_AUX_H
-#include FT_INTERNAL_DEBUG_H
#include "psconv.h"
-#include "psobjs.h"
#include "psauxerr.h"
@@ -241,7 +239,7 @@
PS_Conv_StringDecode( FT_Byte** cursor,
FT_Byte* limit,
FT_Byte* buffer,
- FT_UInt n )
+ FT_Offset n )
{
FT_Byte* p;
FT_UInt r = 0;
@@ -336,7 +334,7 @@
PS_Conv_ASCIIHexDecode( FT_Byte** cursor,
FT_Byte* limit,
FT_Byte* buffer,
- FT_UInt n )
+ FT_Offset n )
{
FT_Byte* p;
FT_UInt r = 0;
@@ -425,7 +423,7 @@
PS_Conv_EexecDecode( FT_Byte** cursor,
FT_Byte* limit,
FT_Byte* buffer,
- FT_UInt n,
+ FT_Offset n,
FT_UShort* seed )
{
FT_Byte* p;
diff --git a/src/3rdparty/freetype/src/psaux/psconv.h b/src/3rdparty/freetype/src/psaux/psconv.h
index e51124185d..84854ba0d1 100644
--- a/src/3rdparty/freetype/src/psaux/psconv.h
+++ b/src/3rdparty/freetype/src/psaux/psconv.h
@@ -46,20 +46,20 @@ FT_BEGIN_HEADER
PS_Conv_StringDecode( FT_Byte** cursor,
FT_Byte* limit,
FT_Byte* buffer,
- FT_UInt n );
+ FT_Offset n );
#endif
FT_LOCAL( FT_UInt )
PS_Conv_ASCIIHexDecode( FT_Byte** cursor,
FT_Byte* limit,
FT_Byte* buffer,
- FT_UInt n );
+ FT_Offset n );
FT_LOCAL( FT_UInt )
PS_Conv_EexecDecode( FT_Byte** cursor,
FT_Byte* limit,
FT_Byte* buffer,
- FT_UInt n,
+ FT_Offset n,
FT_UShort* seed );
diff --git a/src/3rdparty/freetype/src/psaux/psobjs.c b/src/3rdparty/freetype/src/psaux/psobjs.c
index 52e30a4136..fe8398ae38 100644
--- a/src/3rdparty/freetype/src/psaux/psobjs.c
+++ b/src/3rdparty/freetype/src/psaux/psobjs.c
@@ -19,6 +19,7 @@
#include <ft2build.h>
#include FT_INTERNAL_POSTSCRIPT_AUX_H
#include FT_INTERNAL_DEBUG_H
+#include FT_INTERNAL_CALC_H
#include "psobjs.h"
#include "psconv.h"
@@ -564,8 +565,8 @@
cur++;
if ( cur >= limit || *cur != '>' ) /* >> */
{
- FT_ERROR(( "ps_parser_skip_PS_token: "
- "unexpected closing delimiter `>'\n" ));
+ FT_ERROR(( "ps_parser_skip_PS_token:"
+ " unexpected closing delimiter `>'\n" ));
error = PSaux_Err_Invalid_File_Format;
goto Exit;
}
@@ -590,9 +591,10 @@
Exit:
if ( cur == parser->cursor )
{
- FT_ERROR(( "ps_parser_skip_PS_token: "
- "current token is `%c', which is self-delimiting "
- "but invalid at this point\n",
+ FT_ERROR(( "ps_parser_skip_PS_token:"
+ " current token is `%c' which is self-delimiting\n"
+ " "
+ " but invalid at this point\n",
*cur ));
error = PSaux_Err_Invalid_File_Format;
@@ -1153,8 +1155,10 @@
}
else
{
- FT_ERROR(( "ps_parser_load_field: expected a name or string "
- "but found token of type %d instead\n",
+ FT_ERROR(( "ps_parser_load_field:"
+ " expected a name or string\n"
+ " "
+ " but found token of type %d instead\n",
token.type ));
error = PSaux_Err_Invalid_File_Format;
goto Exit;
@@ -1191,8 +1195,8 @@
if ( result < 0 )
{
- FT_ERROR(( "ps_parser_load_field: "
- "expected four integers in bounding box\n" ));
+ FT_ERROR(( "ps_parser_load_field:"
+ " expected four integers in bounding box\n" ));
error = PSaux_Err_Invalid_File_Format;
goto Exit;
}
@@ -1309,7 +1313,7 @@
FT_LOCAL_DEF( FT_Error )
ps_parser_to_bytes( PS_Parser parser,
FT_Byte* bytes,
- FT_Long max_bytes,
+ FT_Offset max_bytes,
FT_Long* pnum_bytes,
FT_Bool delimiters )
{
@@ -1551,16 +1555,9 @@
FT_Byte* control = (FT_Byte*)outline->tags + outline->n_points;
- if ( builder->shift )
- {
- x >>= 16;
- y >>= 16;
- }
- point->x = x;
- point->y = y;
+ point->x = FIXED_TO_INT( x );
+ point->y = FIXED_TO_INT( y );
*control = (FT_Byte)( flag ? FT_CURVE_TAG_ON : FT_CURVE_TAG_CUBIC );
-
- builder->last = *point;
}
outline->n_points++;
}
@@ -1668,8 +1665,8 @@
if ( outline->n_contours > 0 )
{
- /* Don't add contours only consisting of one point, i.e., */
- /* check whether begin point and last point are the same. */
+ /* Don't add contours only consisting of one point, i.e., */
+ /* check whether the first and the last point is the same. */
if ( first == outline->n_points - 1 )
{
outline->n_contours--;
diff --git a/src/3rdparty/freetype/src/psaux/psobjs.h b/src/3rdparty/freetype/src/psaux/psobjs.h
index c2cbf2c79b..e380c60dab 100644
--- a/src/3rdparty/freetype/src/psaux/psobjs.h
+++ b/src/3rdparty/freetype/src/psaux/psobjs.h
@@ -111,7 +111,7 @@ FT_BEGIN_HEADER
FT_LOCAL( FT_Error )
ps_parser_to_bytes( PS_Parser parser,
FT_Byte* bytes,
- FT_Long max_bytes,
+ FT_Offset max_bytes,
FT_Long* pnum_bytes,
FT_Bool delimiters );
diff --git a/src/3rdparty/freetype/src/psaux/t1cmap.c b/src/3rdparty/freetype/src/psaux/t1cmap.c
index 67a23db569..f933e4da88 100644
--- a/src/3rdparty/freetype/src/psaux/t1cmap.c
+++ b/src/3rdparty/freetype/src/psaux/t1cmap.c
@@ -95,7 +95,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
t1_cmap_std_char_next( T1_CMapStd cmap,
FT_UInt32 *pchar_code )
{
@@ -179,7 +179,7 @@
cmap->first = encoding->code_first;
- cmap->count = (FT_UInt)( encoding->code_last - cmap->first + 1 );
+ cmap->count = (FT_UInt)( encoding->code_last - cmap->first );
cmap->indices = encoding->char_index;
FT_ASSERT( cmap->indices != NULL );
@@ -213,7 +213,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
t1_cmap_custom_char_next( T1_CMapCustom cmap,
FT_UInt32 *pchar_code )
{
@@ -312,7 +312,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
t1_cmap_unicode_char_next( PS_Unicodes unicodes,
FT_UInt32 *pchar_code )
{
diff --git a/src/3rdparty/freetype/src/psaux/t1decode.c b/src/3rdparty/freetype/src/psaux/t1decode.c
index bda2324d78..31554ff1ba 100644
--- a/src/3rdparty/freetype/src/psaux/t1decode.c
+++ b/src/3rdparty/freetype/src/psaux/t1decode.c
@@ -4,7 +4,8 @@
/* */
/* PostScript Type 1 decoding routines (body). */
/* */
-/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
+/* Copyright 2000-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 */
+/* 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -17,6 +18,7 @@
#include <ft2build.h>
+#include FT_INTERNAL_CALC_H
#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_POSTSCRIPT_HINTS_H
#include FT_OUTLINE_H
@@ -144,7 +146,8 @@
FT_String* name = (FT_String*)decoder->glyph_names[n];
- if ( name && name[0] == glyph_name[0] &&
+ if ( name &&
+ name[0] == glyph_name[0] &&
ft_strcmp( name, glyph_name ) == 0 )
return n;
}
@@ -193,26 +196,52 @@
#endif
FT_Vector left_bearing, advance;
+#ifdef FT_CONFIG_OPTION_INCREMENTAL
+ T1_Face face = (T1_Face)decoder->builder.face;
+#endif
+
+
+ if ( decoder->seac )
+ {
+ FT_ERROR(( "t1operator_seac: invalid nested seac\n" ));
+ return PSaux_Err_Syntax_Error;
+ }
/* seac weirdness */
adx += decoder->builder.left_bearing.x;
/* `glyph_names' is set to 0 for CID fonts which do not */
/* include an encoding. How can we deal with these? */
+#ifdef FT_CONFIG_OPTION_INCREMENTAL
+ if ( decoder->glyph_names == 0 &&
+ !face->root.internal->incremental_interface )
+#else
if ( decoder->glyph_names == 0 )
+#endif /* FT_CONFIG_OPTION_INCREMENTAL */
{
- FT_ERROR(( "t1operator_seac:" ));
- FT_ERROR(( " glyph names table not available in this font!\n" ));
+ FT_ERROR(( "t1operator_seac:"
+ " glyph names table not available in this font\n" ));
return PSaux_Err_Syntax_Error;
}
- bchar_index = t1_lookup_glyph_by_stdcharcode( decoder, bchar );
- achar_index = t1_lookup_glyph_by_stdcharcode( decoder, achar );
+#ifdef FT_CONFIG_OPTION_INCREMENTAL
+ if ( face->root.internal->incremental_interface )
+ {
+ /* the caller must handle the font encoding also */
+ bchar_index = bchar;
+ achar_index = achar;
+ }
+ else
+#endif
+ {
+ bchar_index = t1_lookup_glyph_by_stdcharcode( decoder, bchar );
+ achar_index = t1_lookup_glyph_by_stdcharcode( decoder, achar );
+ }
if ( bchar_index < 0 || achar_index < 0 )
{
- FT_ERROR(( "t1operator_seac:" ));
- FT_ERROR(( " invalid seac character code arguments\n" ));
+ FT_ERROR(( "t1operator_seac:"
+ " invalid seac character code arguments\n" ));
return PSaux_Err_Syntax_Error;
}
@@ -243,8 +272,8 @@
/* subglyph 1 = accent character */
subg->index = achar_index;
subg->flags = FT_SUBGLYPH_FLAG_ARGS_ARE_XY_VALUES;
- subg->arg1 = (FT_Int)( adx - asb );
- subg->arg2 = (FT_Int)ady;
+ subg->arg1 = (FT_Int)FIXED_TO_INT( adx - asb );
+ subg->arg2 = (FT_Int)FIXED_TO_INT( ady );
/* set up remaining glyph fields */
glyph->num_subglyphs = 2;
@@ -260,7 +289,10 @@
FT_GlyphLoader_Prepare( decoder->builder.loader ); /* prepare loader */
+ /* the seac operator must not be nested */
+ decoder->seac = TRUE;
error = t1_decoder_parse_glyph( decoder, bchar_index );
+ decoder->seac = FALSE;
if ( error )
goto Exit;
@@ -278,7 +310,11 @@
/* Now load `achar' on top of */
/* the base outline */
+
+ /* the seac operator must not be nested */
+ decoder->seac = TRUE;
error = t1_decoder_parse_glyph( decoder, achar_index );
+ decoder->seac = FALSE;
if ( error )
goto Exit;
@@ -327,9 +363,15 @@
FT_Pos x, y, orig_x, orig_y;
FT_Int known_othersubr_result_cnt = 0;
FT_Int unknown_othersubr_result_cnt = 0;
+ FT_Bool large_int;
+ FT_Fixed seed;
T1_Hints_Funcs hinter;
+#ifdef FT_DEBUG_LEVEL_TRACE
+ FT_Bool bol = TRUE;
+#endif
+
/* we don't want to touch the source code -- use macro trick */
#define start_point t1_builder_start_point
@@ -339,6 +381,16 @@
#define add_contour t1_builder_add_contour
#define close_contour t1_builder_close_contour
+
+ /* compute random seed from stack address of parameter */
+ seed = (FT_Fixed)( ( (FT_PtrDist)(char*)&seed ^
+ (FT_PtrDist)(char*)&decoder ^
+ (FT_PtrDist)(char*)&charstring_base ) &
+ FT_ULONG_MAX ) ;
+ seed = ( seed ^ ( seed >> 10 ) ^ ( seed >> 20 ) ) & 0xFFFFL;
+ if ( seed == 0 )
+ seed = 0x7384;
+
/* First of all, initialize the decoder */
decoder->top = decoder->stack;
decoder->zone = decoder->zones;
@@ -351,14 +403,15 @@
/* a font that reads BuildCharArray without setting */
/* its values first is buggy, but ... */
FT_ASSERT( ( decoder->len_buildchar == 0 ) ==
- ( decoder->buildchar == NULL ) );
+ ( decoder->buildchar == NULL ) );
if ( decoder->len_buildchar > 0 )
ft_memset( &decoder->buildchar[0],
0,
sizeof( decoder->buildchar[0] ) * decoder->len_buildchar );
- FT_TRACE4(( "\nStart charstring\n" ));
+ FT_TRACE4(( "\n"
+ "Start charstring\n" ));
zone->base = charstring_base;
limit = zone->limit = charstring_base + charstring_len;
@@ -373,18 +426,26 @@
if ( hinter )
hinter->open( hinter->hints );
+ large_int = FALSE;
+
/* now, execute loop */
while ( ip < limit )
{
FT_Long* top = decoder->top;
T1_Operator op = op_none;
- FT_Long value = 0;
+ FT_Int32 value = 0;
FT_ASSERT( known_othersubr_result_cnt == 0 ||
unknown_othersubr_result_cnt == 0 );
- FT_TRACE5(( " (%d)", decoder->top - decoder->stack ));
+#ifdef FT_DEBUG_LEVEL_TRACE
+ if ( bol )
+ {
+ FT_TRACE5(( " (%d)", decoder->top - decoder->stack ));
+ bol = FALSE;
+ }
+#endif
/*********************************************************************/
/* */
@@ -455,8 +516,8 @@
case 12:
if ( ip > limit )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: "
- "invalid escape (12+EOF)\n" ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " invalid escape (12+EOF)\n" ));
goto Syntax_Error;
}
@@ -491,8 +552,8 @@
break;
default:
- FT_ERROR(( "t1_decoder_parse_charstrings: "
- "invalid escape (12+%d)\n",
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " invalid escape (12+%d)\n",
ip[-1] ));
goto Syntax_Error;
}
@@ -501,42 +562,69 @@
case 255: /* four bytes integer */
if ( ip + 4 > limit )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: "
- "unexpected EOF in integer\n" ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " unexpected EOF in integer\n" ));
goto Syntax_Error;
}
- value = (FT_Int32)( ((FT_Long)ip[0] << 24) |
- ((FT_Long)ip[1] << 16) |
- ((FT_Long)ip[2] << 8 ) |
- ip[3] );
+ value = (FT_Int32)( ( (FT_Long)ip[0] << 24 ) |
+ ( (FT_Long)ip[1] << 16 ) |
+ ( (FT_Long)ip[2] << 8 ) |
+ ip[3] );
ip += 4;
+
+ /* According to the specification, values > 32000 or < -32000 must */
+ /* be followed by a `div' operator to make the result be in the */
+ /* range [-32000;32000]. We expect that the second argument of */
+ /* `div' is not a large number. Additionally, we don't handle */
+ /* stuff like `<large1> <large2> <num> div <num> div' or */
+ /* <large1> <large2> <num> div div'. This is probably not allowed */
+ /* anyway. */
+ if ( value > 32000 || value < -32000 )
+ {
+ if ( large_int )
+ {
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " no `div' after large integer\n" ));
+ }
+ else
+ large_int = TRUE;
+ }
+ else
+ {
+ if ( !large_int )
+ value <<= 16;
+ }
+
break;
default:
if ( ip[-1] >= 32 )
{
if ( ip[-1] < 247 )
- value = (FT_Long)ip[-1] - 139;
+ value = (FT_Int32)ip[-1] - 139;
else
{
if ( ++ip > limit )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: " ));
- FT_ERROR(( "unexpected EOF in integer\n" ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " unexpected EOF in integer\n" ));
goto Syntax_Error;
}
if ( ip[-2] < 251 )
- value = ( ( (FT_Long)ip[-2] - 247 ) << 8 ) + ip[-1] + 108;
+ value = ( ( (FT_Int32)ip[-2] - 247 ) << 8 ) + ip[-1] + 108;
else
- value = -( ( ( (FT_Long)ip[-2] - 251 ) << 8 ) + ip[-1] + 108 );
+ value = -( ( ( (FT_Int32)ip[-2] - 251 ) << 8 ) + ip[-1] + 108 );
}
+
+ if ( !large_int )
+ value <<= 16;
}
else
{
- FT_ERROR(( "t1_decoder_parse_charstrings: "
- "invalid byte (%d)\n", ip[-1] ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " invalid byte (%d)\n", ip[-1] ));
goto Syntax_Error;
}
}
@@ -558,6 +646,14 @@
}
}
+ if ( large_int && !( op == op_none || op == op_div ) )
+ {
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " no `div' after large integer\n" ));
+
+ large_int = FALSE;
+ }
+
/*********************************************************************/
/* */
/* Push value on stack, or process operator */
@@ -567,11 +663,16 @@
{
if ( top - decoder->stack >= T1_MAX_CHARSTRINGS_OPERANDS )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: stack overflow!\n" ));
+ FT_ERROR(( "t1_decoder_parse_charstrings: stack overflow\n" ));
goto Syntax_Error;
}
- FT_TRACE4(( " %ld", value ));
+#ifdef FT_DEBUG_LEVEL_TRACE
+ if ( large_int )
+ FT_TRACE4(( " %ld", value ));
+ else
+ FT_TRACE4(( " %ld", (FT_Int32)( value >> 16 ) ));
+#endif
*top++ = value;
decoder->top = top;
@@ -582,15 +683,18 @@
FT_Int arg_cnt;
- FT_TRACE4(( " callothersubr" ));
+#ifdef FT_DEBUG_LEVEL_TRACE
+ FT_TRACE4(( " callothersubr\n" ));
+ bol = TRUE;
+#endif
if ( top - decoder->stack < 2 )
goto Stack_Underflow;
top -= 2;
- subr_no = (FT_Int)top[1];
- arg_cnt = (FT_Int)top[0];
+ subr_no = (FT_Int)( top[1] >> 16 );
+ arg_cnt = (FT_Int)( top[0] >> 16 );
/***********************************************************/
/* */
@@ -667,8 +771,8 @@
if ( decoder->flex_state == 0 ||
decoder->num_flex_vectors != 7 )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: "
- "unexpected flex end\n" ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " unexpected flex end\n" ));
goto Syntax_Error;
}
@@ -684,7 +788,6 @@
if ( hinter )
hinter->reset( hinter->hints, builder->current->n_points );
-
break;
case 12:
@@ -707,16 +810,16 @@
if ( !blend )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: " ));
- FT_ERROR(( "unexpected multiple masters operator!\n" ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " unexpected multiple masters operator\n" ));
goto Syntax_Error;
}
num_points = (FT_UInt)subr_no - 13 + ( subr_no == 18 );
if ( arg_cnt != (FT_Int)( num_points * blend->num_designs ) )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: " ));
- FT_ERROR(( "incorrect number of mm arguments\n" ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " incorrect number of multiple masters arguments\n" ));
goto Syntax_Error;
}
@@ -752,12 +855,6 @@
break;
}
-#ifdef CAN_HANDLE_NON_INTEGRAL_T1_OPERANDS
-
- /* We cannot yet enable these since currently */
- /* our T1 stack stores integers which lack the */
- /* precision to express the values */
-
case 19:
/* <idx> 1 19 callothersubr */
/* => replace elements starting from index cvi( <idx> ) */
@@ -770,10 +867,10 @@
if ( arg_cnt != 1 || blend == NULL )
goto Unexpected_OtherSubr;
- idx = top[0];
+ idx = (FT_Int)( top[0] >> 16 );
- if ( idx < 0 ||
- idx + blend->num_designs > decoder->face->len_buildchar )
+ if ( idx < 0 ||
+ idx + blend->num_designs > decoder->len_buildchar )
goto Unexpected_OtherSubr;
ft_memcpy( &decoder->buildchar[idx],
@@ -811,7 +908,7 @@
if ( arg_cnt != 2 )
goto Unexpected_OtherSubr;
- top[0] *= top[1]; /* XXX (over|under)flow */
+ top[0] = FT_MulFix( top[0], top[1] );
known_othersubr_result_cnt = 1;
break;
@@ -822,24 +919,23 @@
if ( arg_cnt != 2 || top[1] == 0 )
goto Unexpected_OtherSubr;
- top[0] /= top[1]; /* XXX (over|under)flow */
+ top[0] = FT_DivFix( top[0], top[1] );
known_othersubr_result_cnt = 1;
break;
-#endif /* CAN_HANDLE_NON_INTEGRAL_T1_OPERANDS */
-
case 24:
- /* <val> <idx> 2 24 callothersubr */
- /* => set BuildCharArray[cvi( <idx> )] = <val> */
+ /* <val> <idx> 2 24 callothersubr */
+ /* ==> set BuildCharArray[cvi( <idx> )] = <val> */
{
FT_Int idx;
PS_Blend blend = decoder->blend;
+
if ( arg_cnt != 2 || blend == NULL )
goto Unexpected_OtherSubr;
- idx = top[1];
+ idx = (FT_Int)( top[1] >> 16 );
if ( idx < 0 || (FT_UInt) idx >= decoder->len_buildchar )
goto Unexpected_OtherSubr;
@@ -849,17 +945,18 @@
break;
case 25:
- /* <idx> 1 25 callothersubr pop */
- /* => push BuildCharArray[cvi( idx )] */
- /* onto T1 stack */
+ /* <idx> 1 25 callothersubr pop */
+ /* ==> push BuildCharArray[cvi( idx )] */
+ /* onto T1 stack */
{
FT_Int idx;
PS_Blend blend = decoder->blend;
+
if ( arg_cnt != 1 || blend == NULL )
goto Unexpected_OtherSubr;
- idx = top[0];
+ idx = (FT_Int)( top[0] >> 16 );
if ( idx < 0 || (FT_UInt) idx >= decoder->len_buildchar )
goto Unexpected_OtherSubr;
@@ -875,13 +972,13 @@
/* <val> mark <idx> ==> set BuildCharArray[cvi( <idx> )] = <val>, */
/* leave mark on T1 stack */
/* <val> <idx> ==> set BuildCharArray[cvi( <idx> )] = <val> */
- XXX who has left his mark on the (PostScript) stack ?;
+ XXX which routine has left its mark on the (PostScript) stack?;
break;
#endif
case 27:
/* <res1> <res2> <val1> <val2> 4 27 callothersubr pop */
- /* ==> push <res1> onto T1 stack if <val1> <= <val2>, */
+ /* ==> push <res1> onto T1 stack if <val1> <= <val2>, */
/* otherwise push <res2> */
if ( arg_cnt != 4 )
goto Unexpected_OtherSubr;
@@ -892,28 +989,40 @@
known_othersubr_result_cnt = 1;
break;
-#ifdef CAN_HANDLE_NON_INTEGRAL_T1_OPERANDS
case 28:
/* 0 28 callothersubr pop */
/* => push random value from interval [0, 1) onto stack */
if ( arg_cnt != 0 )
goto Unexpected_OtherSubr;
- top[0] = FT_rand();
+ {
+ FT_Fixed Rand;
+
+
+ Rand = seed;
+ if ( Rand >= 0x8000L )
+ Rand++;
+
+ top[0] = Rand;
+
+ seed = FT_MulFix( seed, 0x10000L - seed );
+ if ( seed == 0 )
+ seed += 0x2873;
+ }
+
known_othersubr_result_cnt = 1;
break;
-#endif
default:
- FT_ERROR(( "t1_decoder_parse_charstrings: "
- "unknown othersubr [%d %d], wish me luck!\n",
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " unknown othersubr [%d %d], wish me luck\n",
arg_cnt, subr_no ));
unknown_othersubr_result_cnt = arg_cnt;
break;
Unexpected_OtherSubr:
- FT_ERROR(( "t1_decoder_parse_charstrings: "
- "invalid othersubr [%d %d]!\n", arg_cnt, subr_no ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " invalid othersubr [%d %d]\n", arg_cnt, subr_no ));
goto Syntax_Error;
}
@@ -950,9 +1059,9 @@
default:
if ( top - decoder->stack != num_args )
- FT_TRACE0(( "t1_decoder_parse_charstrings: "
- "too much operands on the stack "
- "(seen %d, expected %d)\n",
+ FT_TRACE0(( "t1_decoder_parse_charstrings:"
+ " too much operands on the stack"
+ " (seen %d, expected %d)\n",
top - decoder->stack, num_args ));
break;
}
@@ -964,28 +1073,26 @@
switch ( op )
{
case op_endchar:
- FT_TRACE4(( " endchar" ));
+ FT_TRACE4(( " endchar\n" ));
close_contour( builder );
/* close hints recording session */
if ( hinter )
{
- if (hinter->close( hinter->hints, builder->current->n_points ))
+ if ( hinter->close( hinter->hints, builder->current->n_points ) )
goto Syntax_Error;
/* apply hints to the loaded glyph outline now */
hinter->apply( hinter->hints,
builder->current,
- (PSH_Globals) builder->hints_globals,
+ (PSH_Globals)builder->hints_globals,
decoder->hint_mode );
}
/* add current outline to the glyph slot */
FT_GlyphLoader_Add( builder->loader );
- FT_TRACE4(( "\n" ));
-
/* the compiler should optimize away this empty loop but ... */
#ifdef FT_DEBUG_LEVEL_TRACE
@@ -1019,8 +1126,8 @@
builder->advance.x = top[1];
builder->advance.y = 0;
- orig_x = builder->last.x = x = builder->pos_x + top[0];
- orig_y = builder->last.y = y = builder->pos_y;
+ orig_x = x = builder->pos_x + top[0];
+ orig_y = y = builder->pos_y;
FT_UNUSED( orig_y );
@@ -1033,9 +1140,12 @@
break;
case op_seac:
- /* return immediately after the processing */
- return t1operator_seac( decoder, top[0], top[1], top[2],
- (FT_Int)top[3], (FT_Int)top[4] );
+ return t1operator_seac( decoder,
+ top[0],
+ top[1],
+ top[2],
+ (FT_Int)( top[3] >> 16 ),
+ (FT_Int)( top[4] >> 16 ) );
case op_sbw:
FT_TRACE4(( " sbw" ));
@@ -1047,8 +1157,8 @@
builder->advance.x = top[2];
builder->advance.y = top[3];
- builder->last.x = x = builder->pos_x + top[0];
- builder->last.y = y = builder->pos_y + top[1];
+ x = builder->pos_x + top[0];
+ y = builder->pos_y + top[1];
/* the `metrics_only' indicates that we only want to compute */
/* the glyph's metrics (lsb + advance width), not load the */
@@ -1134,7 +1244,7 @@
break;
case op_rrcurveto:
- FT_TRACE4(( " rcurveto" ));
+ FT_TRACE4(( " rrcurveto" ));
if ( start_point( builder, x, y ) ||
check_points( builder, 3 ) )
@@ -1193,16 +1303,13 @@
case op_div:
FT_TRACE4(( " div" ));
- if ( top[1] )
- {
- *top = top[0] / top[1];
- ++top;
- }
- else
- {
- FT_ERROR(( "t1_decoder_parse_charstrings: division by 0\n" ));
- goto Syntax_Error;
- }
+ /* if `large_int' is set, we divide unscaled numbers; */
+ /* otherwise, we divide numbers in 16.16 format -- */
+ /* in both cases, it is the same operation */
+ *top = FT_DivFix( top[0], top[1] );
+ ++top;
+
+ large_int = FALSE;
break;
case op_callsubr:
@@ -1212,18 +1319,18 @@
FT_TRACE4(( " callsubr" ));
- idx = (FT_Int)top[0];
+ idx = (FT_Int)( top[0] >> 16 );
if ( idx < 0 || idx >= (FT_Int)decoder->num_subrs )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: "
- "invalid subrs index\n" ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " invalid subrs index\n" ));
goto Syntax_Error;
}
if ( zone - decoder->zones >= T1_MAX_SUBRS_CALLS )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: "
- "too many nested subrs\n" ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " too many nested subrs\n" ));
goto Syntax_Error;
}
@@ -1250,8 +1357,8 @@
if ( !zone->base )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: "
- "invoking empty subrs!\n" ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " invoking empty subrs\n" ));
goto Syntax_Error;
}
@@ -1273,8 +1380,8 @@
if ( unknown_othersubr_result_cnt == 0 )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: "
- "no more operands for othersubr!\n" ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " no more operands for othersubr\n" ));
goto Syntax_Error;
}
@@ -1287,7 +1394,8 @@
if ( zone <= decoder->zones )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: unexpected return\n" ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " unexpected return\n" ));
goto Syntax_Error;
}
@@ -1311,7 +1419,6 @@
/* top[0] += builder->left_bearing.y; */
hinter->stem( hinter->hints, 1, top );
}
-
break;
case op_hstem3:
@@ -1320,19 +1427,17 @@
/* record horizontal counter-controlled hints */
if ( hinter )
hinter->stem3( hinter->hints, 1, top );
-
break;
case op_vstem:
FT_TRACE4(( " vstem" ));
- /* record vertical hint */
+ /* record vertical hint */
if ( hinter )
{
top[0] += orig_x;
hinter->stem( hinter->hints, 0, top );
}
-
break;
case op_vstem3:
@@ -1354,20 +1459,28 @@
case op_setcurrentpoint:
FT_TRACE4(( " setcurrentpoint" ));
- /* From the T1 specs, section 6.4: */
+ /* From the T1 specification, section 6.4: */
/* */
/* The setcurrentpoint command is used only in */
/* conjunction with results from OtherSubrs procedures. */
- /* known_othersubr_result_cnt != 0 is already handled above */
+ /* known_othersubr_result_cnt != 0 is already handled */
+ /* above. */
+
+ /* Note, however, that both Ghostscript and Adobe */
+ /* Distiller handle this situation by silently ignoring */
+ /* the inappropriate `setcurrentpoint' instruction. So */
+ /* we do the same. */
+#if 0
+
if ( decoder->flex_state != 1 )
{
- FT_ERROR(( "t1_decoder_parse_charstrings: " ));
- FT_ERROR(( "unexpected `setcurrentpoint'\n" ));
-
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " unexpected `setcurrentpoint'\n" ));
goto Syntax_Error;
}
else
+#endif
decoder->flex_state = 0;
break;
@@ -1377,8 +1490,8 @@
break;
default:
- FT_ERROR(( "t1_decoder_parse_charstrings: "
- "unhandled opcode %d\n", op ));
+ FT_ERROR(( "t1_decoder_parse_charstrings:"
+ " unhandled opcode %d\n", op ));
goto Syntax_Error;
}
@@ -1389,6 +1502,11 @@
decoder->top = top;
+#ifdef FT_DEBUG_LEVEL_TRACE
+ FT_TRACE4(( "\n" ));
+ bol = TRUE;
+#endif
+
} /* general operator processing */
} /* while ip < limit */
@@ -1437,8 +1555,8 @@
FT_FACE_FIND_GLOBAL_SERVICE( face, psnames, POSTSCRIPT_CMAPS );
if ( !psnames )
{
- FT_ERROR(( "t1_decoder_init: " ));
- FT_ERROR(( "the `psnames' module is not available\n" ));
+ FT_ERROR(( "t1_decoder_init:"
+ " the `psnames' module is not available\n" ));
return PSaux_Err_Unimplemented_Feature;
}
diff --git a/src/3rdparty/freetype/src/pshinter/Jamfile b/src/3rdparty/freetype/src/pshinter/Jamfile
index 769dcc4b29..779f1b0b82 100644
--- a/src/3rdparty/freetype/src/pshinter/Jamfile
+++ b/src/3rdparty/freetype/src/pshinter/Jamfile
@@ -16,7 +16,7 @@ SubDir FT2_TOP $(FT2_SRC_DIR) pshinter ;
if $(FT2_MULTI)
{
- _sources = pshrec pshglob pshalgo pshmod ;
+ _sources = pshrec pshglob pshalgo pshmod pshpic ;
}
else
{
diff --git a/src/3rdparty/freetype/src/pshinter/pshalgo.c b/src/3rdparty/freetype/src/pshinter/pshalgo.c
index f9ab3dae58..417dcee547 100644
--- a/src/3rdparty/freetype/src/pshinter/pshalgo.c
+++ b/src/3rdparty/freetype/src/pshinter/pshalgo.c
@@ -103,7 +103,7 @@
if ( idx >= table->max_hints )
{
- FT_ERROR(( "psh_hint_table_record: invalid hint index %d\n", idx ));
+ FT_TRACE0(( "psh_hint_table_record: invalid hint index %d\n", idx ));
return;
}
@@ -137,7 +137,7 @@
if ( table->num_hints < table->max_hints )
table->sort_global[table->num_hints++] = hint;
else
- FT_ERROR(( "psh_hint_table_record: too many sorted hints! BUG!\n" ));
+ FT_TRACE0(( "psh_hint_table_record: too many sorted hints! BUG!\n" ));
}
@@ -230,7 +230,7 @@
FT_UInt idx;
- FT_ERROR(( "psh_hint_table_init: missing/incorrect hint masks!\n" ));
+ FT_TRACE0(( "psh_hint_table_init: missing/incorrect hint masks\n" ));
count = table->max_hints;
for ( idx = 0; idx < count; idx++ )
@@ -282,8 +282,8 @@
{
hint2 = sort[0];
if ( psh_hint_overlap( hint, hint2 ) )
- FT_ERROR(( "psh_hint_table_activate_mask:"
- " found overlapping hints\n" ))
+ FT_TRACE0(( "psh_hint_table_activate_mask:"
+ " found overlapping hints\n" ))
}
#else
count2 = 0;
@@ -295,8 +295,8 @@
if ( count < table->max_hints )
table->sort[count++] = hint;
else
- FT_ERROR(( "psh_hint_tableactivate_mask:"
- " too many active hints\n" ));
+ FT_TRACE0(( "psh_hint_tableactivate_mask:"
+ " too many active hints\n" ));
}
}
}
diff --git a/src/3rdparty/freetype/src/pshinter/pshinter.c b/src/3rdparty/freetype/src/pshinter/pshinter.c
index 8e3f193093..b35a2a91c5 100644
--- a/src/3rdparty/freetype/src/pshinter/pshinter.c
+++ b/src/3rdparty/freetype/src/pshinter/pshinter.c
@@ -19,6 +19,7 @@
#define FT_MAKE_OPTION_SINGLE_OBJECT
#include <ft2build.h>
+#include "pshpic.c"
#include "pshrec.c"
#include "pshglob.c"
#include "pshalgo.c"
diff --git a/src/3rdparty/freetype/src/pshinter/pshmod.c b/src/3rdparty/freetype/src/pshinter/pshmod.c
index 4eb3d91272..91da5d7e6b 100644
--- a/src/3rdparty/freetype/src/pshinter/pshmod.c
+++ b/src/3rdparty/freetype/src/pshinter/pshmod.c
@@ -20,6 +20,7 @@
#include FT_INTERNAL_OBJECTS_H
#include "pshrec.h"
#include "pshalgo.h"
+#include "pshpic.h"
/* the Postscript Hinter module structure */
@@ -92,30 +93,26 @@
}
- static
- const PSHinter_Interface pshinter_interface =
- {
+ FT_DEFINE_PSHINTER_INTERFACE(pshinter_interface,
pshinter_get_globals_funcs,
pshinter_get_t1_funcs,
pshinter_get_t2_funcs
- };
+ )
- FT_CALLBACK_TABLE_DEF
- const FT_Module_Class pshinter_module_class =
- {
+ FT_DEFINE_MODULE(pshinter_module_class,
+
0,
sizeof ( PS_Hinter_ModuleRec ),
"pshinter",
0x10000L,
0x20000L,
- &pshinter_interface, /* module-specific interface */
+ &FTPSHINTER_INTERFACE_GET, /* module-specific interface */
(FT_Module_Constructor)ps_hinter_init,
(FT_Module_Destructor) ps_hinter_done,
(FT_Module_Requester) 0 /* no additional interface for now */
- };
-
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/pshinter/pshmod.h b/src/3rdparty/freetype/src/pshinter/pshmod.h
index 1a91025b26..0ae7e96f54 100644
--- a/src/3rdparty/freetype/src/pshinter/pshmod.h
+++ b/src/3rdparty/freetype/src/pshinter/pshmod.h
@@ -27,7 +27,7 @@
FT_BEGIN_HEADER
- FT_EXPORT_VAR( const FT_Module_Class ) pshinter_module_class;
+ FT_DECLARE_MODULE( pshinter_module_class )
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/pshinter/pshpic.c b/src/3rdparty/freetype/src/pshinter/pshpic.c
new file mode 100644
index 0000000000..51a0879888
--- /dev/null
+++ b/src/3rdparty/freetype/src/pshinter/pshpic.c
@@ -0,0 +1,67 @@
+/***************************************************************************/
+/* */
+/* pshpic.c */
+/* */
+/* The FreeType position independent code services for pshinter module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#include <ft2build.h>
+#include FT_FREETYPE_H
+#include FT_INTERNAL_OBJECTS_H
+#include "pshpic.h"
+
+#ifdef FT_CONFIG_OPTION_PIC
+
+ /* forward declaration of PIC init functions from pshmod.c */
+ void FT_Init_Class_pshinter_interface( FT_Library, PSHinter_Interface*);
+
+ void
+ pshinter_module_class_pic_free( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+ if ( pic_container->pshinter )
+ {
+ FT_FREE( pic_container->pshinter );
+ pic_container->pshinter = NULL;
+ }
+ }
+
+ FT_Error
+ pshinter_module_class_pic_init( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Error error = FT_Err_Ok;
+ PSHinterPIC* container;
+ FT_Memory memory = library->memory;
+
+ /* allocate pointer, clear and set global container pointer */
+ if ( FT_ALLOC ( container, sizeof ( *container ) ) )
+ return error;
+ FT_MEM_SET( container, 0, sizeof(*container) );
+ pic_container->pshinter = container;
+
+ /* add call to initialization function when you add new scripts */
+ FT_Init_Class_pshinter_interface(library, &container->pshinter_interface);
+
+/*Exit:*/
+ if(error)
+ pshinter_module_class_pic_free(library);
+ return error;
+ }
+
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+/* END */
diff --git a/src/3rdparty/freetype/src/pshinter/pshpic.h b/src/3rdparty/freetype/src/pshinter/pshpic.h
new file mode 100644
index 0000000000..3555d8e851
--- /dev/null
+++ b/src/3rdparty/freetype/src/pshinter/pshpic.h
@@ -0,0 +1,53 @@
+/***************************************************************************/
+/* */
+/* pshpic.h */
+/* */
+/* The FreeType position independent code services for pshinter module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifndef __PSHPIC_H__
+#define __PSHPIC_H__
+
+
+FT_BEGIN_HEADER
+
+#include FT_INTERNAL_PIC_H
+
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FTPSHINTER_INTERFACE_GET pshinter_interface
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#include FT_INTERNAL_POSTSCRIPT_HINTS_H
+
+ typedef struct PSHinterPIC_
+ {
+ PSHinter_Interface pshinter_interface;
+ } PSHinterPIC;
+
+#define GET_PIC(lib) ((PSHinterPIC*)((lib)->pic_container.autofit))
+#define FTPSHINTER_INTERFACE_GET (GET_PIC(library)->pshinter_interface)
+
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /* */
+
+FT_END_HEADER
+
+#endif /* __PSHPIC_H__ */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/pshinter/pshrec.c b/src/3rdparty/freetype/src/pshinter/pshrec.c
index 2a885ef276..0910cc5e6a 100644
--- a/src/3rdparty/freetype/src/pshinter/pshrec.c
+++ b/src/3rdparty/freetype/src/pshinter/pshrec.c
@@ -4,7 +4,7 @@
/* */
/* FreeType PostScript hints recorder (body). */
/* */
-/* Copyright 2001, 2002, 2003, 2004, 2007 by */
+/* Copyright 2001, 2002, 2003, 2004, 2007, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -20,6 +20,8 @@
#include FT_FREETYPE_H
#include FT_INTERNAL_OBJECTS_H
#include FT_INTERNAL_DEBUG_H
+#include FT_INTERNAL_CALC_H
+
#include "pshrec.h"
#include "pshalgo.h"
@@ -62,7 +64,7 @@
{
FT_UInt old_max = table->max_hints;
FT_UInt new_max = count;
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
if ( new_max > old_max )
@@ -81,7 +83,7 @@
FT_Memory memory,
PS_Hint *ahint )
{
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
FT_UInt count;
PS_Hint hint = 0;
@@ -137,7 +139,7 @@
{
FT_UInt old_max = ( mask->max_bits + 7 ) >> 3;
FT_UInt new_max = ( count + 7 ) >> 3;
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
if ( new_max > old_max )
@@ -184,7 +186,7 @@
FT_Int idx,
FT_Memory memory )
{
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
FT_Byte* p;
@@ -234,7 +236,7 @@
{
FT_UInt old_max = table->max_masks;
FT_UInt new_max = count;
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
if ( new_max > old_max )
@@ -254,7 +256,7 @@
PS_Mask *amask )
{
FT_UInt count;
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
PS_Mask mask = 0;
@@ -285,7 +287,7 @@
FT_Memory memory,
PS_Mask *amask )
{
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
FT_UInt count;
PS_Mask mask;
@@ -314,7 +316,7 @@
FT_UInt bit_count,
FT_Memory memory )
{
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
PS_Mask mask;
@@ -407,7 +409,7 @@
FT_Memory memory )
{
FT_UInt temp;
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
/* swap index1 and index2 so that index1 < index2 */
@@ -481,8 +483,8 @@
table->num_masks--;
}
else
- FT_ERROR(( "ps_mask_table_merge: ignoring invalid indices (%d,%d)\n",
- index1, index2 ));
+ FT_TRACE0(( "ps_mask_table_merge: ignoring invalid indices (%d,%d)\n",
+ index1, index2 ));
Exit:
return error;
@@ -497,7 +499,7 @@
FT_Memory memory )
{
FT_Int index1, index2;
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
for ( index1 = table->num_masks - 1; index1 > 0; index1-- )
@@ -558,8 +560,8 @@
FT_UInt idx,
FT_Memory memory )
{
- PS_Mask mask;
- FT_Error error = 0;
+ PS_Mask mask;
+ FT_Error error = PSH_Err_Ok;
/* get last hint mask */
@@ -619,7 +621,7 @@
FT_UInt end_point,
FT_Memory memory )
{
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
/* reset current mask, if any */
@@ -644,7 +646,7 @@
FT_Memory memory,
FT_Int *aindex )
{
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
FT_UInt flags = 0;
@@ -715,7 +717,7 @@
FT_Int hint3,
FT_Memory memory )
{
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
FT_UInt count = dim->counters.num_masks;
PS_Mask counter = dim->counters.masks;
@@ -789,7 +791,7 @@
ps_dimension_done( &hints->dimension[0], memory );
ps_dimension_done( &hints->dimension[1], memory );
- hints->error = 0;
+ hints->error = PSH_Err_Ok;
hints->memory = 0;
}
@@ -800,7 +802,7 @@
{
FT_MEM_ZERO( hints, sizeof ( *hints ) );
hints->memory = memory;
- return 0;
+ return PSH_Err_Ok;
}
@@ -813,7 +815,7 @@
{
case PS_HINT_TYPE_1:
case PS_HINT_TYPE_2:
- hints->error = 0;
+ hints->error = PSH_Err_Ok;
hints->hint_type = hint_type;
ps_dimension_init( &hints->dimension[0] );
@@ -824,7 +826,7 @@
hints->error = PSH_Err_Invalid_Argument;
hints->hint_type = hint_type;
- FT_ERROR(( "ps_hints_open: invalid charstring type!\n" ));
+ FT_TRACE0(( "ps_hints_open: invalid charstring type\n" ));
break;
}
}
@@ -842,8 +844,8 @@
/* limit "dimension" to 0..1 */
if ( dimension < 0 || dimension > 1 )
{
- FT_ERROR(( "ps_hints_stem: invalid dimension (%d) used\n",
- dimension ));
+ FT_TRACE0(( "ps_hints_stem: invalid dimension (%d) used\n",
+ dimension ));
dimension = ( dimension != 0 );
}
@@ -878,8 +880,8 @@
}
default:
- FT_ERROR(( "ps_hints_stem: called with invalid hint type (%d)\n",
- hints->hint_type ));
+ FT_TRACE0(( "ps_hints_stem: called with invalid hint type (%d)\n",
+ hints->hint_type ));
break;
}
}
@@ -888,11 +890,11 @@
/* add one Type1 counter stem to the current hints table */
static void
- ps_hints_t1stem3( PS_Hints hints,
- FT_Int dimension,
- FT_Long* stems )
+ ps_hints_t1stem3( PS_Hints hints,
+ FT_Int dimension,
+ FT_Fixed* stems )
{
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
if ( !hints->error )
@@ -906,8 +908,8 @@
/* limit "dimension" to 0..1 */
if ( dimension < 0 || dimension > 1 )
{
- FT_ERROR(( "ps_hints_t1stem3: invalid dimension (%d) used\n",
- dimension ));
+ FT_TRACE0(( "ps_hints_t1stem3: invalid dimension (%d) used\n",
+ dimension ));
dimension = ( dimension != 0 );
}
@@ -919,9 +921,10 @@
/* add the three stems to our hints/masks table */
for ( count = 0; count < 3; count++, stems += 2 )
{
- error = ps_dimension_add_t1stem(
- dim, (FT_Int)stems[0], (FT_Int)stems[1],
- memory, &idx[count] );
+ error = ps_dimension_add_t1stem( dim,
+ (FT_Int)FIXED_TO_INT( stems[0] ),
+ (FT_Int)FIXED_TO_INT( stems[1] ),
+ memory, &idx[count] );
if ( error )
goto Fail;
}
@@ -934,7 +937,7 @@
}
else
{
- FT_ERROR(( "ps_hints_t1stem3: called with invalid hint type!\n" ));
+ FT_ERROR(( "ps_hints_t1stem3: called with invalid hint type\n" ));
error = PSH_Err_Invalid_Argument;
goto Fail;
}
@@ -953,7 +956,7 @@
ps_hints_t1reset( PS_Hints hints,
FT_UInt end_point )
{
- FT_Error error = 0;
+ FT_Error error = PSH_Err_Ok;
if ( !hints->error )
@@ -1008,8 +1011,8 @@
/* check bit count; must be equal to current total hint count */
if ( bit_count != count1 + count2 )
{
- FT_ERROR(( "ps_hints_t2mask: "
- "called with invalid bitcount %d (instead of %d)\n",
+ FT_TRACE0(( "ps_hints_t2mask:"
+ " called with invalid bitcount %d (instead of %d)\n",
bit_count, count1 + count2 ));
/* simply ignore the operator */
@@ -1053,8 +1056,8 @@
/* check bit count, must be equal to current total hint count */
if ( bit_count != count1 + count2 )
{
- FT_ERROR(( "ps_hints_t2counter: "
- "called with invalid bitcount %d (instead of %d)\n",
+ FT_TRACE0(( "ps_hints_t2counter:"
+ " called with invalid bitcount %d (instead of %d)\n",
bit_count, count1 + count2 ));
/* simply ignore the operator */
@@ -1124,11 +1127,17 @@
}
static void
- t1_hints_stem( T1_Hints hints,
- FT_Int dimension,
- FT_Long* coords )
+ t1_hints_stem( T1_Hints hints,
+ FT_Int dimension,
+ FT_Fixed* coords )
{
- ps_hints_stem( (PS_Hints)hints, dimension, 1, coords );
+ FT_Pos stems[2];
+
+
+ stems[0] = FIXED_TO_INT( coords[0] );
+ stems[1] = FIXED_TO_INT( coords[1] );
+
+ ps_hints_stem( (PS_Hints)hints, dimension, 1, stems );
}
@@ -1183,7 +1192,7 @@
for ( n = 0; n < count * 2; n++ )
{
y += coords[n];
- stems[n] = ( y + 0x8000L ) >> 16;
+ stems[n] = FIXED_TO_INT( y );
}
/* compute lengths */
diff --git a/src/3rdparty/freetype/src/psnames/Jamfile b/src/3rdparty/freetype/src/psnames/Jamfile
index d85c1e97de..06c0dda66f 100644
--- a/src/3rdparty/freetype/src/psnames/Jamfile
+++ b/src/3rdparty/freetype/src/psnames/Jamfile
@@ -16,7 +16,7 @@ SubDir FT2_TOP $(FT2_SRC_DIR) psnames ;
if $(FT2_MULTI)
{
- _sources = psmodule ;
+ _sources = psmodule pspic ;
}
else
{
diff --git a/src/3rdparty/freetype/src/psnames/psmodule.c b/src/3rdparty/freetype/src/psnames/psmodule.c
index 41942a9b46..00b363f8bb 100644
--- a/src/3rdparty/freetype/src/psnames/psmodule.c
+++ b/src/3rdparty/freetype/src/psnames/psmodule.c
@@ -24,6 +24,7 @@
#include "pstables.h"
#include "psnamerr.h"
+#include "pspic.h"
#ifdef FT_CONFIG_OPTION_POSTSCRIPT_NAMES
@@ -33,7 +34,7 @@
#define VARIANT_BIT 0x80000000UL
-#define BASE_GLYPH( code ) ( (code) & ~VARIANT_BIT )
+#define BASE_GLYPH( code ) ( (FT_UInt32)( (code) & ~VARIANT_BIT ) )
/* Return the Unicode value corresponding to a given glyph. Note that */
@@ -57,7 +58,7 @@
/* `uniXXXXYYYYZZZZ'... */
FT_Int count;
- FT_ULong value = 0;
+ FT_UInt32 value = 0;
const char* p = glyph_name + 3;
@@ -92,7 +93,7 @@
if ( *p == '\0' )
return value;
if ( *p == '.' )
- return value | VARIANT_BIT;
+ return (FT_UInt32)( value | VARIANT_BIT );
}
}
@@ -101,7 +102,7 @@
if ( glyph_name[0] == 'u' )
{
FT_Int count;
- FT_ULong value = 0;
+ FT_UInt32 value = 0;
const char* p = glyph_name + 1;
@@ -132,7 +133,7 @@
if ( *p == '\0' )
return value;
if ( *p == '.' )
- return value | VARIANT_BIT;
+ return (FT_UInt32)( value | VARIANT_BIT );
}
}
@@ -154,9 +155,10 @@
/* now look up the glyph in the Adobe Glyph List */
if ( !dot )
- return ft_get_adobe_glyph_index( glyph_name, p );
+ return (FT_UInt32)ft_get_adobe_glyph_index( glyph_name, p );
else
- return ft_get_adobe_glyph_index( glyph_name, dot ) | VARIANT_BIT;
+ return (FT_UInt32)( ft_get_adobe_glyph_index( glyph_name, dot ) |
+ VARIANT_BIT );
}
}
@@ -435,7 +437,7 @@
}
- static FT_ULong
+ static FT_UInt32
ps_unicodes_char_next( PS_Unicodes table,
FT_UInt32 *unicode )
{
@@ -516,38 +518,43 @@
}
- static
- const FT_Service_PsCMapsRec pscmaps_interface =
- {
#ifdef FT_CONFIG_OPTION_ADOBE_GLYPH_LIST
-
+ FT_DEFINE_SERVICE_PSCMAPSREC(pscmaps_interface,
(PS_Unicode_ValueFunc) ps_unicode_value,
(PS_Unicodes_InitFunc) ps_unicodes_init,
(PS_Unicodes_CharIndexFunc)ps_unicodes_char_index,
(PS_Unicodes_CharNextFunc) ps_unicodes_char_next,
+ (PS_Macintosh_NameFunc) ps_get_macintosh_name,
+ (PS_Adobe_Std_StringsFunc) ps_get_standard_strings,
+
+ t1_standard_encoding,
+ t1_expert_encoding
+ )
+
#else
+ FT_DEFINE_SERVICE_PSCMAPSREC(pscmaps_interface,
0,
0,
0,
0,
-#endif /* FT_CONFIG_OPTION_ADOBE_GLYPH_LIST */
-
(PS_Macintosh_NameFunc) ps_get_macintosh_name,
(PS_Adobe_Std_StringsFunc) ps_get_standard_strings,
t1_standard_encoding,
t1_expert_encoding
- };
+ )
+
+#endif /* FT_CONFIG_OPTION_ADOBE_GLYPH_LIST */
+
+
+ FT_DEFINE_SERVICEDESCREC1(pscmaps_services,
+ FT_SERVICE_ID_POSTSCRIPT_CMAPS, &FT_PSCMAPS_INTERFACE_GET
+ )
- static const FT_ServiceDescRec pscmaps_services[] =
- {
- { FT_SERVICE_ID_POSTSCRIPT_CMAPS, &pscmaps_interface },
- { NULL, NULL }
- };
static FT_Pointer
@@ -556,16 +563,20 @@
{
FT_UNUSED( module );
- return ft_service_list_lookup( pscmaps_services, service_id );
+ return ft_service_list_lookup( FT_PSCMAPS_SERVICES_GET, service_id );
}
#endif /* FT_CONFIG_OPTION_POSTSCRIPT_NAMES */
+#ifndef FT_CONFIG_OPTION_POSTSCRIPT_NAMES
+#define PUT_PS_NAMES_SERVICE(a) 0
+#else
+#define PUT_PS_NAMES_SERVICE(a) a
+#endif
- FT_CALLBACK_TABLE_DEF
- const FT_Module_Class psnames_module_class =
- {
+ FT_DEFINE_MODULE(psnames_module_class,
+
0, /* this is not a font driver, nor a renderer */
sizeof ( FT_ModuleRec ),
@@ -573,18 +584,12 @@
0x10000L, /* driver version */
0x20000L, /* driver requires FreeType 2 or above */
-#ifndef FT_CONFIG_OPTION_POSTSCRIPT_NAMES
- 0,
- (FT_Module_Constructor)0,
- (FT_Module_Destructor) 0,
- (FT_Module_Requester) 0
-#else
- (void*)&pscmaps_interface, /* module specific interface */
+ PUT_PS_NAMES_SERVICE((void*)&FT_PSCMAPS_INTERFACE_GET), /* module specific interface */
(FT_Module_Constructor)0,
(FT_Module_Destructor) 0,
- (FT_Module_Requester) psnames_get_service
-#endif
- };
+ (FT_Module_Requester) PUT_PS_NAMES_SERVICE(psnames_get_service)
+ )
+
/* END */
diff --git a/src/3rdparty/freetype/src/psnames/psmodule.h b/src/3rdparty/freetype/src/psnames/psmodule.h
index 232fdfb9a9..28fa14807c 100644
--- a/src/3rdparty/freetype/src/psnames/psmodule.h
+++ b/src/3rdparty/freetype/src/psnames/psmodule.h
@@ -27,7 +27,7 @@
FT_BEGIN_HEADER
- FT_EXPORT_VAR( const FT_Module_Class ) psnames_module_class;
+ FT_DECLARE_MODULE( psnames_module_class )
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/psnames/psnames.c b/src/3rdparty/freetype/src/psnames/psnames.c
index d6ed998bfb..1ede225dc9 100644
--- a/src/3rdparty/freetype/src/psnames/psnames.c
+++ b/src/3rdparty/freetype/src/psnames/psnames.c
@@ -19,6 +19,7 @@
#define FT_MAKE_OPTION_SINGLE_OBJECT
#include <ft2build.h>
+#include "pspic.c"
#include "psmodule.c"
diff --git a/src/3rdparty/freetype/src/psnames/pspic.c b/src/3rdparty/freetype/src/psnames/pspic.c
new file mode 100644
index 0000000000..ed7dadda39
--- /dev/null
+++ b/src/3rdparty/freetype/src/psnames/pspic.c
@@ -0,0 +1,77 @@
+/***************************************************************************/
+/* */
+/* pspic.c */
+/* */
+/* The FreeType position independent code services for psnames module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#include <ft2build.h>
+#include FT_FREETYPE_H
+#include FT_INTERNAL_OBJECTS_H
+#include "pspic.h"
+
+#ifdef FT_CONFIG_OPTION_PIC
+
+ /* forward declaration of PIC init functions from psmodule.c */
+ FT_Error FT_Create_Class_pscmaps_services( FT_Library, FT_ServiceDescRec**);
+ void FT_Destroy_Class_pscmaps_services( FT_Library, FT_ServiceDescRec*);
+ void FT_Init_Class_pscmaps_interface( FT_Library, FT_Service_PsCMapsRec*);
+
+ void
+ psnames_module_class_pic_free( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+ if ( pic_container->psnames )
+ {
+ PSModulePIC* container = (PSModulePIC*)pic_container->psnames;
+ if(container->pscmaps_services)
+ FT_Destroy_Class_pscmaps_services(library, container->pscmaps_services);
+ container->pscmaps_services = NULL;
+ FT_FREE( container );
+ pic_container->psnames = NULL;
+ }
+ }
+
+ FT_Error
+ psnames_module_class_pic_init( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Error error = FT_Err_Ok;
+ PSModulePIC* container;
+ FT_Memory memory = library->memory;
+
+ /* allocate pointer, clear and set global container pointer */
+ if ( FT_ALLOC ( container, sizeof ( *container ) ) )
+ return error;
+ FT_MEM_SET( container, 0, sizeof(*container) );
+ pic_container->psnames = container;
+
+ /* initialize pointer table - this is how the module usually expects this data */
+ error = FT_Create_Class_pscmaps_services(library, &container->pscmaps_services);
+ if(error)
+ goto Exit;
+ FT_Init_Class_pscmaps_interface(library, &container->pscmaps_interface);
+
+Exit:
+ if(error)
+ psnames_module_class_pic_free(library);
+ return error;
+ }
+
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/psnames/pspic.h b/src/3rdparty/freetype/src/psnames/pspic.h
new file mode 100644
index 0000000000..75a14fdcb9
--- /dev/null
+++ b/src/3rdparty/freetype/src/psnames/pspic.h
@@ -0,0 +1,54 @@
+/***************************************************************************/
+/* */
+/* pspic.h */
+/* */
+/* The FreeType position independent code services for psnames module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifndef __PSPIC_H__
+#define __PSPIC_H__
+
+
+FT_BEGIN_HEADER
+
+#include FT_INTERNAL_PIC_H
+
+#ifndef FT_CONFIG_OPTION_PIC
+#define FT_PSCMAPS_SERVICES_GET pscmaps_services
+#define FT_PSCMAPS_INTERFACE_GET pscmaps_interface
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#include FT_SERVICE_POSTSCRIPT_CMAPS_H
+
+ typedef struct PSModulePIC_
+ {
+ FT_ServiceDescRec* pscmaps_services;
+ FT_Service_PsCMapsRec pscmaps_interface;
+ } PSModulePIC;
+
+#define GET_PIC(lib) ((PSModulePIC*)((lib)->pic_container.psnames))
+#define FT_PSCMAPS_SERVICES_GET (GET_PIC(library)->pscmaps_services)
+#define FT_PSCMAPS_INTERFACE_GET (GET_PIC(library)->pscmaps_interface)
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /* */
+
+FT_END_HEADER
+
+#endif /* __PSPIC_H__ */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/raster/Jamfile b/src/3rdparty/freetype/src/raster/Jamfile
index f6e4251cb8..4f60e87c78 100644
--- a/src/3rdparty/freetype/src/raster/Jamfile
+++ b/src/3rdparty/freetype/src/raster/Jamfile
@@ -16,7 +16,7 @@ SubDir FT2_TOP $(FT2_SRC_DIR) raster ;
if $(FT2_MULTI)
{
- _sources = ftraster ftrend1 ;
+ _sources = ftraster ftrend1 rastpic ;
}
else
{
diff --git a/src/3rdparty/freetype/src/raster/ftmisc.h b/src/3rdparty/freetype/src/raster/ftmisc.h
index d9d73e3373..f04b5404bb 100644
--- a/src/3rdparty/freetype/src/raster/ftmisc.h
+++ b/src/3rdparty/freetype/src/raster/ftmisc.h
@@ -52,6 +52,31 @@
(FT_ULong)_x4 )
+ /* from include/freetype2/ftsystem.h */
+
+ typedef struct FT_MemoryRec_* FT_Memory;
+
+ typedef void* (*FT_Alloc_Func)( FT_Memory memory,
+ long size );
+
+ typedef void (*FT_Free_Func)( FT_Memory memory,
+ void* block );
+
+ typedef void* (*FT_Realloc_Func)( FT_Memory memory,
+ long cur_size,
+ long new_size,
+ void* block );
+
+ typedef struct FT_MemoryRec_
+ {
+ void* user;
+
+ FT_Alloc_Func alloc;
+ FT_Free_Func free;
+ FT_Realloc_Func realloc;
+
+ } FT_MemoryRec;
+
/* from src/ftcalc.c */
#include <inttypes.h>
diff --git a/src/3rdparty/freetype/src/raster/ftraster.c b/src/3rdparty/freetype/src/raster/ftraster.c
index eb9c4a45f2..23ad592653 100644
--- a/src/3rdparty/freetype/src/raster/ftraster.c
+++ b/src/3rdparty/freetype/src/raster/ftraster.c
@@ -49,6 +49,10 @@
#ifdef _STANDALONE_
+#define FT_CONFIG_STANDARD_LIBRARY_H <stdlib.h>
+
+#include <string.h> /* for memset */
+
#include "ftmisc.h"
#include "ftimage.h"
@@ -58,6 +62,8 @@
#include "ftraster.h"
#include FT_INTERNAL_CALC_H /* for FT_MulDiv only */
+#include "rastpic.h"
+
#endif /* !_STANDALONE_ */
@@ -72,13 +78,15 @@
/* profile is simply an array of scanline intersections on a given */
/* dimension. A profile's main attributes are */
/* */
- /* o its scanline position boundaries, i.e. `Ymin' and `Ymax'. */
+ /* o its scanline position boundaries, i.e. `Ymin' and `Ymax' */
/* */
/* o an array of intersection coordinates for each scanline */
- /* between `Ymin' and `Ymax'. */
+ /* between `Ymin' and `Ymax' */
/* */
/* o a direction, indicating whether it was built going `up' or */
- /* `down', as this is very important for filling rules. */
+ /* `down', as this is very important for filling rules */
+ /* */
+ /* o its drop-out mode */
/* */
/* 2 - Sweeping the target map's scanlines in order to compute segment */
/* `spans' which are then filled. Additionally, this pass */
@@ -88,15 +96,15 @@
/* built from the bottom of the render pool, used as a stack. The */
/* following graphics shows the profile list under construction: */
/* */
- /* ____________________________________________________________ _ _ */
- /* | | | | | */
- /* | profile | coordinates for | profile | coordinates for |--> */
- /* | 1 | profile 1 | 2 | profile 2 |--> */
- /* |_________|___________________|_________|_________________|__ _ _ */
+ /* __________________________________________________________ _ _ */
+ /* | | | | | */
+ /* | profile | coordinates for | profile | coordinates for |--> */
+ /* | 1 | profile 1 | 2 | profile 2 |--> */
+ /* |_________|_________________|_________|_________________|__ _ _ */
/* */
- /* ^ ^ */
- /* | | */
- /* start of render pool top */
+ /* ^ ^ */
+ /* | | */
+ /* start of render pool top */
/* */
/* The top of the profile stack is kept in the `top' variable. */
/* */
@@ -140,11 +148,11 @@
/*************************************************************************/
/* define DEBUG_RASTER if you want to compile a debugging version */
-#define xxxDEBUG_RASTER
+/* #define DEBUG_RASTER */
- /* undefine FT_RASTER_OPTION_ANTI_ALIASING if you do not want to support */
- /* 5-levels anti-aliasing */
-#undef FT_RASTER_OPTION_ANTI_ALIASING
+ /* define FT_RASTER_OPTION_ANTI_ALIASING if you want to support */
+ /* 5-levels anti-aliasing */
+/* #define FT_RASTER_OPTION_ANTI_ALIASING */
/* The size of the two-lines intermediate bitmap used */
/* for anti-aliasing, in bytes. */
@@ -197,9 +205,22 @@
#define Raster_Err_Invalid -4
#define Raster_Err_Unsupported -5
-#define ft_memset memset
+#define ft_memset memset
+
+#define FT_DEFINE_RASTER_FUNCS( class_, glyph_format_, raster_new_, \
+ raster_reset_, raster_set_mode_, \
+ raster_render_, raster_done_ ) \
+ const FT_Raster_Funcs class_ = \
+ { \
+ glyph_format_, \
+ raster_new_, \
+ raster_reset_, \
+ raster_set_mode_, \
+ raster_render_, \
+ raster_done_ \
+ };
-#else /* _STANDALONE_ */
+#else /* !_STANDALONE_ */
#include FT_INTERNAL_OBJECTS_H
@@ -215,7 +236,7 @@
#define Raster_Err_Unsupported Raster_Err_Cannot_Render_Glyph
-#endif /* _STANDALONE_ */
+#endif /* !_STANDALONE_ */
#ifndef FT_MEM_SET
@@ -304,13 +325,10 @@
} TPoint;
- typedef enum TFlow_
- {
- Flow_None = 0,
- Flow_Up = 1,
- Flow_Down = -1
-
- } TFlow;
+ /* values for the `flags' bit field */
+#define Flow_Up 0x8
+#define Overshoot_Top 0x10
+#define Overshoot_Bottom 0x20
/* States of each line, arc, and profile */
@@ -329,18 +347,21 @@
struct TProfile_
{
- FT_F26Dot6 X; /* current coordinate during sweep */
- PProfile link; /* link to next profile - various purpose */
- PLong offset; /* start of profile's data in render pool */
- int flow; /* Profile orientation: Asc/Descending */
- long height; /* profile's height in scanlines */
- long start; /* profile's starting scanline */
-
- unsigned countL; /* number of lines to step before this */
- /* profile becomes drawable */
-
- PProfile next; /* next profile in same contour, used */
- /* during drop-out control */
+ FT_F26Dot6 X; /* current coordinate during sweep */
+ PProfile link; /* link to next profile (various purposes) */
+ PLong offset; /* start of profile's data in render pool */
+ unsigned flags; /* Bit 0-2: drop-out mode */
+ /* Bit 3: profile orientation (up/down) */
+ /* Bit 4: is top profile? */
+ /* Bit 5: is bottom profile? */
+ long height; /* profile's height in scanlines */
+ long start; /* profile's starting scanline */
+
+ unsigned countL; /* number of lines to step before this */
+ /* profile becomes drawable */
+
+ PProfile next; /* next profile in same contour, used */
+ /* during drop-out control */
};
typedef PProfile TProfileList;
@@ -373,7 +394,7 @@
#define FT_UNUSED_RASTER do { } while ( 0 )
-#else /* FT_STATIC_RASTER */
+#else /* !FT_STATIC_RASTER */
#define RAS_ARGS PWorker worker,
@@ -385,7 +406,7 @@
#define FT_UNUSED_RASTER FT_UNUSED( worker )
-#endif /* FT_STATIC_RASTER */
+#endif /* !FT_STATIC_RASTER */
typedef struct TWorker_ TWorker, *PWorker;
@@ -415,65 +436,68 @@
#define FRAC( x ) ( (x) & ( ras.precision - 1 ) )
#define SCALED( x ) ( ( (x) << ras.scale_shift ) - ras.precision_half )
- /* Note that I have moved the location of some fields in the */
- /* structure to ensure that the most used variables are used */
- /* at the top. Thus, their offset can be coded with less */
- /* opcodes, and it results in a smaller executable. */
+#define IS_BOTTOM_OVERSHOOT( x ) ( CEILING( x ) - x >= ras.precision_half )
+#define IS_TOP_OVERSHOOT( x ) ( x - FLOOR( x ) >= ras.precision_half )
+
+ /* The most used variables are positioned at the top of the structure. */
+ /* Thus, their offset can be coded with less opcodes, resulting in a */
+ /* smaller executable. */
struct TWorker_
{
- Int precision_bits; /* precision related variables */
- Int precision;
- Int precision_half;
- Long precision_mask;
- Int precision_shift;
- Int precision_step;
- Int precision_jitter;
-
- Int scale_shift; /* == precision_shift for bitmaps */
+ Int precision_bits; /* precision related variables */
+ Int precision;
+ Int precision_half;
+ Long precision_mask;
+ Int precision_shift;
+ Int precision_step;
+ Int precision_jitter;
+
+ Int scale_shift; /* == precision_shift for bitmaps */
/* == precision_shift+1 for pixmaps */
- PLong buff; /* The profiles buffer */
- PLong sizeBuff; /* Render pool size */
- PLong maxBuff; /* Profiles buffer size */
- PLong top; /* Current cursor in buffer */
+ PLong buff; /* The profiles buffer */
+ PLong sizeBuff; /* Render pool size */
+ PLong maxBuff; /* Profiles buffer size */
+ PLong top; /* Current cursor in buffer */
- FT_Error error;
+ FT_Error error;
- Int numTurns; /* number of Y-turns in outline */
+ Int numTurns; /* number of Y-turns in outline */
- TPoint* arc; /* current Bezier arc pointer */
+ TPoint* arc; /* current Bezier arc pointer */
- UShort bWidth; /* target bitmap width */
- PByte bTarget; /* target bitmap buffer */
- PByte gTarget; /* target pixmap buffer */
+ UShort bWidth; /* target bitmap width */
+ PByte bTarget; /* target bitmap buffer */
+ PByte gTarget; /* target pixmap buffer */
- Long lastX, lastY, minY, maxY;
+ Long lastX, lastY;
+ Long minY, maxY;
- UShort num_Profs; /* current number of profiles */
+ UShort num_Profs; /* current number of profiles */
- Bool fresh; /* signals a fresh new profile which */
- /* 'start' field must be completed */
- Bool joint; /* signals that the last arc ended */
+ Bool fresh; /* signals a fresh new profile which */
+ /* `start' field must be completed */
+ Bool joint; /* signals that the last arc ended */
/* exactly on a scanline. Allows */
/* removal of doublets */
- PProfile cProfile; /* current profile */
- PProfile fProfile; /* head of linked list of profiles */
- PProfile gProfile; /* contour's first profile in case */
+ PProfile cProfile; /* current profile */
+ PProfile fProfile; /* head of linked list of profiles */
+ PProfile gProfile; /* contour's first profile in case */
/* of impact */
- TStates state; /* rendering state */
+ TStates state; /* rendering state */
FT_Bitmap target; /* description of target bit/pixmap */
FT_Outline outline;
- Long traceOfs; /* current offset in target bitmap */
- Long traceG; /* current offset in target pixmap */
+ Long traceOfs; /* current offset in target bitmap */
+ Long traceG; /* current offset in target pixmap */
- Short traceIncr; /* sweep's increment in target bitmap */
+ Short traceIncr; /* sweep's increment in target bitmap */
- Short gray_min_x; /* current min x during gray rendering */
- Short gray_max_x; /* current max x during gray rendering */
+ Short gray_min_x; /* current min x during gray rendering */
+ Short gray_max_x; /* current max x during gray rendering */
/* dispatch variables */
@@ -482,31 +506,31 @@
Function_Sweep_Span* Proc_Sweep_Drop;
Function_Sweep_Step* Proc_Sweep_Step;
- Byte dropOutControl; /* current drop_out control method */
+ Byte dropOutControl; /* current drop_out control method */
- Bool second_pass; /* indicates whether a horizontal pass */
+ Bool second_pass; /* indicates whether a horizontal pass */
/* should be performed to control */
/* drop-out accurately when calling */
/* Render_Glyph. Note that there is */
/* no horizontal pass during gray */
/* rendering. */
- TPoint arcs[3 * MaxBezier + 1]; /* The Bezier stack */
+ TPoint arcs[3 * MaxBezier + 1]; /* The Bezier stack */
- TBand band_stack[16]; /* band stack used for sub-banding */
- Int band_top; /* band stack top */
+ TBand band_stack[16]; /* band stack used for sub-banding */
+ Int band_top; /* band stack top */
#ifdef FT_RASTER_OPTION_ANTI_ALIASING
- Byte* grays;
+ Byte* grays;
- Byte gray_lines[RASTER_GRAY_LINES];
+ Byte gray_lines[RASTER_GRAY_LINES];
/* Intermediate table used to render the */
/* graylevels pixmaps. */
/* gray_lines is a buffer holding two */
/* monochrome scanlines */
- Short gray_width; /* width in bytes of one monochrome */
+ Short gray_width; /* width in bytes of one monochrome */
/* intermediate scanline of gray_lines. */
/* Each gray pixel takes 2 bits long there */
@@ -520,12 +544,12 @@
typedef struct TRaster_
{
- char* buffer;
- long buffer_size;
- void* memory;
- PWorker worker;
- Byte grays[5];
- Short gray_width;
+ char* buffer;
+ long buffer_size;
+ void* memory;
+ PWorker worker;
+ Byte grays[5];
+ Short gray_width;
} TRaster, *PRaster;
@@ -534,34 +558,72 @@
static TWorker cur_ras;
#define ras cur_ras
-#else
+#else /* !FT_STATIC_RASTER */
#define ras (*worker)
-#endif /* FT_STATIC_RASTER */
+#endif /* !FT_STATIC_RASTER */
#ifdef FT_RASTER_OPTION_ANTI_ALIASING
- static const char count_table[256] =
+ /* A lookup table used to quickly count set bits in four gray 2x2 */
+ /* cells. The values of the table have been produced with the */
+ /* following code: */
+ /* */
+ /* for ( i = 0; i < 256; i++ ) */
+ /* { */
+ /* l = 0; */
+ /* j = i; */
+ /* */
+ /* for ( c = 0; c < 4; c++ ) */
+ /* { */
+ /* l <<= 4; */
+ /* */
+ /* if ( j & 0x80 ) l++; */
+ /* if ( j & 0x40 ) l++; */
+ /* */
+ /* j = ( j << 2 ) & 0xFF; */
+ /* } */
+ /* printf( "0x%04X", l ); */
+ /* } */
+ /* */
+
+ static const short count_table[256] =
{
- 0 , 1 , 1 , 2 , 1 , 2 , 2 , 3 , 1 , 2 , 2 , 3 , 2 , 3 , 3 , 4,
- 1 , 2 , 2 , 3 , 2 , 3 , 3 , 4 , 2 , 3 , 3 , 4 , 3 , 4 , 4 , 5,
- 1 , 2 , 2 , 3 , 2 , 3 , 3 , 4 , 2 , 3 , 3 , 4 , 3 , 4 , 4 , 5,
- 2 , 3 , 3 , 4 , 3 , 4 , 4 , 5 , 3 , 4 , 4 , 5 , 4 , 5 , 5 , 6,
- 1 , 2 , 2 , 3 , 2 , 3 , 3 , 4 , 2 , 3 , 3 , 4 , 3 , 4 , 4 , 5,
- 2 , 3 , 3 , 4 , 3 , 4 , 4 , 5 , 3 , 4 , 4 , 5 , 4 , 5 , 5 , 6,
- 2 , 3 , 3 , 4 , 3 , 4 , 4 , 5 , 3 , 4 , 4 , 5 , 4 , 5 , 5 , 6,
- 3 , 4 , 4 , 5 , 4 , 5 , 5 , 6 , 4 , 5 , 5 , 6 , 5 , 6 , 6 , 7,
- 1 , 2 , 2 , 3 , 2 , 3 , 3 , 4 , 2 , 3 , 3 , 4 , 3 , 4 , 4 , 5,
- 2 , 3 , 3 , 4 , 3 , 4 , 4 , 5 , 3 , 4 , 4 , 5 , 4 , 5 , 5 , 6,
- 2 , 3 , 3 , 4 , 3 , 4 , 4 , 5 , 3 , 4 , 4 , 5 , 4 , 5 , 5 , 6,
- 3 , 4 , 4 , 5 , 4 , 5 , 5 , 6 , 4 , 5 , 5 , 6 , 5 , 6 , 6 , 7,
- 2 , 3 , 3 , 4 , 3 , 4 , 4 , 5 , 3 , 4 , 4 , 5 , 4 , 5 , 5 , 6,
- 3 , 4 , 4 , 5 , 4 , 5 , 5 , 6 , 4 , 5 , 5 , 6 , 5 , 6 , 6 , 7,
- 3 , 4 , 4 , 5 , 4 , 5 , 5 , 6 , 4 , 5 , 5 , 6 , 5 , 6 , 6 , 7,
- 4 , 5 , 5 , 6 , 5 , 6 , 6 , 7 , 5 , 6 , 6 , 7 , 6 , 7 , 7 , 8
-a };
+ 0x0000, 0x0001, 0x0001, 0x0002, 0x0010, 0x0011, 0x0011, 0x0012,
+ 0x0010, 0x0011, 0x0011, 0x0012, 0x0020, 0x0021, 0x0021, 0x0022,
+ 0x0100, 0x0101, 0x0101, 0x0102, 0x0110, 0x0111, 0x0111, 0x0112,
+ 0x0110, 0x0111, 0x0111, 0x0112, 0x0120, 0x0121, 0x0121, 0x0122,
+ 0x0100, 0x0101, 0x0101, 0x0102, 0x0110, 0x0111, 0x0111, 0x0112,
+ 0x0110, 0x0111, 0x0111, 0x0112, 0x0120, 0x0121, 0x0121, 0x0122,
+ 0x0200, 0x0201, 0x0201, 0x0202, 0x0210, 0x0211, 0x0211, 0x0212,
+ 0x0210, 0x0211, 0x0211, 0x0212, 0x0220, 0x0221, 0x0221, 0x0222,
+ 0x1000, 0x1001, 0x1001, 0x1002, 0x1010, 0x1011, 0x1011, 0x1012,
+ 0x1010, 0x1011, 0x1011, 0x1012, 0x1020, 0x1021, 0x1021, 0x1022,
+ 0x1100, 0x1101, 0x1101, 0x1102, 0x1110, 0x1111, 0x1111, 0x1112,
+ 0x1110, 0x1111, 0x1111, 0x1112, 0x1120, 0x1121, 0x1121, 0x1122,
+ 0x1100, 0x1101, 0x1101, 0x1102, 0x1110, 0x1111, 0x1111, 0x1112,
+ 0x1110, 0x1111, 0x1111, 0x1112, 0x1120, 0x1121, 0x1121, 0x1122,
+ 0x1200, 0x1201, 0x1201, 0x1202, 0x1210, 0x1211, 0x1211, 0x1212,
+ 0x1210, 0x1211, 0x1211, 0x1212, 0x1220, 0x1221, 0x1221, 0x1222,
+ 0x1000, 0x1001, 0x1001, 0x1002, 0x1010, 0x1011, 0x1011, 0x1012,
+ 0x1010, 0x1011, 0x1011, 0x1012, 0x1020, 0x1021, 0x1021, 0x1022,
+ 0x1100, 0x1101, 0x1101, 0x1102, 0x1110, 0x1111, 0x1111, 0x1112,
+ 0x1110, 0x1111, 0x1111, 0x1112, 0x1120, 0x1121, 0x1121, 0x1122,
+ 0x1100, 0x1101, 0x1101, 0x1102, 0x1110, 0x1111, 0x1111, 0x1112,
+ 0x1110, 0x1111, 0x1111, 0x1112, 0x1120, 0x1121, 0x1121, 0x1122,
+ 0x1200, 0x1201, 0x1201, 0x1202, 0x1210, 0x1211, 0x1211, 0x1212,
+ 0x1210, 0x1211, 0x1211, 0x1212, 0x1220, 0x1221, 0x1221, 0x1222,
+ 0x2000, 0x2001, 0x2001, 0x2002, 0x2010, 0x2011, 0x2011, 0x2012,
+ 0x2010, 0x2011, 0x2011, 0x2012, 0x2020, 0x2021, 0x2021, 0x2022,
+ 0x2100, 0x2101, 0x2101, 0x2102, 0x2110, 0x2111, 0x2111, 0x2112,
+ 0x2110, 0x2111, 0x2111, 0x2112, 0x2120, 0x2121, 0x2121, 0x2122,
+ 0x2100, 0x2101, 0x2101, 0x2102, 0x2110, 0x2111, 0x2111, 0x2112,
+ 0x2110, 0x2111, 0x2111, 0x2112, 0x2120, 0x2121, 0x2121, 0x2122,
+ 0x2200, 0x2201, 0x2201, 0x2202, 0x2210, 0x2211, 0x2211, 0x2212,
+ 0x2210, 0x2211, 0x2211, 0x2212, 0x2220, 0x2221, 0x2221, 0x2222
+ };
#endif /* FT_RASTER_OPTION_ANTI_ALIASING */
@@ -593,9 +655,9 @@ a };
{
if ( High )
{
- ras.precision_bits = 10;
- ras.precision_step = 128;
- ras.precision_jitter = 24;
+ ras.precision_bits = 12;
+ ras.precision_step = 256;
+ ras.precision_jitter = 50;
}
else
{
@@ -622,14 +684,18 @@ a };
/* Create a new profile in the render pool. */
/* */
/* <Input> */
- /* aState :: The state/orientation of the new profile. */
+ /* aState :: The state/orientation of the new profile. */
+ /* */
+ /* overshoot :: Whether the profile's unrounded start position */
+ /* differs by at least a half pixel. */
/* */
/* <Return> */
/* SUCCESS on success. FAILURE in case of overflow or of incoherent */
/* profile. */
/* */
static Bool
- New_Profile( RAS_ARGS TStates aState )
+ New_Profile( RAS_ARGS TStates aState,
+ Bool overshoot )
{
if ( !ras.fProfile )
{
@@ -644,30 +710,36 @@ a };
return FAILURE;
}
+ ras.cProfile->flags = 0;
+ ras.cProfile->start = 0;
+ ras.cProfile->height = 0;
+ ras.cProfile->offset = ras.top;
+ ras.cProfile->link = (PProfile)0;
+ ras.cProfile->next = (PProfile)0;
+ ras.cProfile->flags = ras.dropOutControl;
+
switch ( aState )
{
case Ascending_State:
- ras.cProfile->flow = Flow_Up;
+ ras.cProfile->flags |= Flow_Up;
+ if ( overshoot )
+ ras.cProfile->flags |= Overshoot_Bottom;
+
FT_TRACE6(( "New ascending profile = %lx\n", (long)ras.cProfile ));
break;
case Descending_State:
- ras.cProfile->flow = Flow_Down;
+ if ( overshoot )
+ ras.cProfile->flags |= Overshoot_Top;
FT_TRACE6(( "New descending profile = %lx\n", (long)ras.cProfile ));
break;
default:
- FT_ERROR(( "New_Profile: invalid profile direction!\n" ));
+ FT_ERROR(( "New_Profile: invalid profile direction\n" ));
ras.error = Raster_Err_Invalid;
return FAILURE;
}
- ras.cProfile->start = 0;
- ras.cProfile->height = 0;
- ras.cProfile->offset = ras.top;
- ras.cProfile->link = (PProfile)0;
- ras.cProfile->next = (PProfile)0;
-
if ( !ras.gProfile )
ras.gProfile = ras.cProfile;
@@ -687,11 +759,15 @@ a };
/* <Description> */
/* Finalize the current profile. */
/* */
+ /* <Input> */
+ /* overshoot :: Whether the profile's unrounded end position differs */
+ /* by at least a half pixel. */
+ /* */
/* <Return> */
/* SUCCESS on success. FAILURE in case of overflow or incoherency. */
/* */
static Bool
- End_Profile( RAS_ARG )
+ End_Profile( RAS_ARGS Bool overshoot )
{
Long h;
PProfile oldProfile;
@@ -701,7 +777,7 @@ a };
if ( h < 0 )
{
- FT_ERROR(( "End_Profile: negative height encountered!\n" ));
+ FT_ERROR(( "End_Profile: negative height encountered\n" ));
ras.error = Raster_Err_Neg_Height;
return FAILURE;
}
@@ -711,15 +787,24 @@ a };
FT_TRACE6(( "Ending profile %lx, start = %ld, height = %ld\n",
(long)ras.cProfile, ras.cProfile->start, h ));
- oldProfile = ras.cProfile;
ras.cProfile->height = h;
- ras.cProfile = (PProfile)ras.top;
+ if ( overshoot )
+ {
+ if ( ras.cProfile->flags & Flow_Up )
+ ras.cProfile->flags |= Overshoot_Top;
+ else
+ ras.cProfile->flags |= Overshoot_Bottom;
+ }
- ras.top += AlignProfileSize;
+ oldProfile = ras.cProfile;
+ ras.cProfile = (PProfile)ras.top;
+
+ ras.top += AlignProfileSize;
ras.cProfile->height = 0;
ras.cProfile->offset = ras.top;
- oldProfile->next = ras.cProfile;
+
+ oldProfile->next = ras.cProfile;
ras.num_Profs++;
}
@@ -822,23 +907,21 @@ a };
else
p->link = NULL;
- switch ( p->flow )
+ if ( p->flags & Flow_Up )
+ {
+ bottom = (Int)p->start;
+ top = (Int)( p->start + p->height - 1 );
+ }
+ else
{
- case Flow_Down:
bottom = (Int)( p->start - p->height + 1 );
top = (Int)p->start;
p->start = bottom;
p->offset += p->height - 1;
- break;
-
- case Flow_Up:
- default:
- bottom = (Int)p->start;
- top = (Int)( p->start + p->height - 1 );
}
- if ( Insert_Y_Turn( RAS_VARS bottom ) ||
- Insert_Y_Turn( RAS_VARS top + 1 ) )
+ if ( Insert_Y_Turn( RAS_VARS bottom ) ||
+ Insert_Y_Turn( RAS_VARS top + 1 ) )
return FAILURE;
p = p->link;
@@ -1230,7 +1313,7 @@ a };
}
else
{
- *top++ = arc[degree].x + FMulDiv( arc[0].x-arc[degree].x,
+ *top++ = arc[degree].x + FMulDiv( arc[0].x - arc[degree].x,
e - y1, y2 - y1 );
arc -= degree;
e += ras.precision;
@@ -1335,13 +1418,15 @@ a };
case Unknown_State:
if ( y > ras.lastY )
{
- if ( New_Profile( RAS_VARS Ascending_State ) )
+ if ( New_Profile( RAS_VARS Ascending_State,
+ IS_BOTTOM_OVERSHOOT( ras.lastY ) ) )
return FAILURE;
}
else
{
if ( y < ras.lastY )
- if ( New_Profile( RAS_VARS Descending_State ) )
+ if ( New_Profile( RAS_VARS Descending_State,
+ IS_TOP_OVERSHOOT( ras.lastY ) ) )
return FAILURE;
}
break;
@@ -1349,8 +1434,9 @@ a };
case Ascending_State:
if ( y < ras.lastY )
{
- if ( End_Profile( RAS_VAR ) ||
- New_Profile( RAS_VARS Descending_State ) )
+ if ( End_Profile( RAS_VARS IS_TOP_OVERSHOOT( ras.lastY ) ) ||
+ New_Profile( RAS_VARS Descending_State,
+ IS_TOP_OVERSHOOT( ras.lastY ) ) )
return FAILURE;
}
break;
@@ -1358,8 +1444,9 @@ a };
case Descending_State:
if ( y > ras.lastY )
{
- if ( End_Profile( RAS_VAR ) ||
- New_Profile( RAS_VARS Ascending_State ) )
+ if ( End_Profile( RAS_VARS IS_BOTTOM_OVERSHOOT( ras.lastY ) ) ||
+ New_Profile( RAS_VARS Ascending_State,
+ IS_BOTTOM_OVERSHOOT( ras.lastY ) ) )
return FAILURE;
}
break;
@@ -1374,13 +1461,13 @@ a };
{
case Ascending_State:
if ( Line_Up( RAS_VARS ras.lastX, ras.lastY,
- x, y, ras.minY, ras.maxY ) )
+ x, y, ras.minY, ras.maxY ) )
return FAILURE;
break;
case Descending_State:
if ( Line_Down( RAS_VARS ras.lastX, ras.lastY,
- x, y, ras.minY, ras.maxY ) )
+ x, y, ras.minY, ras.maxY ) )
return FAILURE;
break;
@@ -1431,8 +1518,10 @@ a };
ras.arc = ras.arcs;
ras.arc[2].x = ras.lastX;
ras.arc[2].y = ras.lastY;
- ras.arc[1].x = cx; ras.arc[1].y = cy;
- ras.arc[0].x = x; ras.arc[0].y = y;
+ ras.arc[1].x = cx;
+ ras.arc[1].y = cy;
+ ras.arc[0].x = x;
+ ras.arc[0].y = y;
do
{
@@ -1472,13 +1561,17 @@ a };
state_bez = y1 < y3 ? Ascending_State : Descending_State;
if ( ras.state != state_bez )
{
+ Bool o = state_bez == Ascending_State ? IS_BOTTOM_OVERSHOOT( y1 )
+ : IS_TOP_OVERSHOOT( y1 );
+
+
/* finalize current profile if any */
- if ( ras.state != Unknown_State &&
- End_Profile( RAS_VAR ) )
+ if ( ras.state != Unknown_State &&
+ End_Profile( RAS_VARS o ) )
goto Fail;
/* create a new profile */
- if ( New_Profile( RAS_VARS state_bez ) )
+ if ( New_Profile( RAS_VARS state_bez, o ) )
goto Fail;
}
@@ -1547,9 +1640,12 @@ a };
ras.arc = ras.arcs;
ras.arc[3].x = ras.lastX;
ras.arc[3].y = ras.lastY;
- ras.arc[2].x = cx1; ras.arc[2].y = cy1;
- ras.arc[1].x = cx2; ras.arc[1].y = cy2;
- ras.arc[0].x = x; ras.arc[0].y = y;
+ ras.arc[2].x = cx1;
+ ras.arc[2].y = cy1;
+ ras.arc[1].x = cx2;
+ ras.arc[1].y = cy2;
+ ras.arc[0].x = x;
+ ras.arc[0].y = y;
do
{
@@ -1601,11 +1697,16 @@ a };
/* detect a change of direction */
if ( ras.state != state_bez )
{
- if ( ras.state != Unknown_State &&
- End_Profile( RAS_VAR ) )
+ Bool o = state_bez == Ascending_State ? IS_BOTTOM_OVERSHOOT( y1 )
+ : IS_TOP_OVERSHOOT( y1 );
+
+
+ /* finalize current profile if any */
+ if ( ras.state != Unknown_State &&
+ End_Profile( RAS_VARS o ) )
goto Fail;
- if ( New_Profile( RAS_VARS state_bez ) )
+ if ( New_Profile( RAS_VARS state_bez, o ) )
goto Fail;
}
@@ -1698,8 +1799,13 @@ a };
v_control = v_start;
point = points + first;
- tags = ras.outline.tags + first;
- tag = FT_CURVE_TAG( tags[0] );
+ tags = ras.outline.tags + first;
+
+ /* set scan mode if necessary */
+ if ( tags[0] & FT_CURVE_TAG_HAS_SCANMODE )
+ ras.dropOutControl = (Byte)tags[0] >> 5;
+
+ tag = FT_CURVE_TAG( tags[0] );
/* A contour cannot start with a cubic control point! */
if ( tag == FT_CURVE_TAG_CUBIC )
@@ -1905,27 +2011,36 @@ a };
for ( i = 0; i < ras.outline.n_contours; i++ )
{
+ Bool o;
+
+
ras.state = Unknown_State;
ras.gProfile = NULL;
if ( Decompose_Curve( RAS_VARS (unsigned short)start,
- ras.outline.contours[i],
- flipped ) )
+ ras.outline.contours[i],
+ flipped ) )
return FAILURE;
start = ras.outline.contours[i] + 1;
- /* We must now see whether the extreme arcs join or not */
+ /* we must now check whether the extreme arcs join or not */
if ( FRAC( ras.lastY ) == 0 &&
ras.lastY >= ras.minY &&
ras.lastY <= ras.maxY )
- if ( ras.gProfile && ras.gProfile->flow == ras.cProfile->flow )
+ if ( ras.gProfile &&
+ ( ras.gProfile->flags & Flow_Up ) ==
+ ( ras.cProfile->flags & Flow_Up ) )
ras.top--;
/* Note that ras.gProfile can be nil if the contour was too small */
/* to be drawn. */
lastProfile = ras.cProfile;
- if ( End_Profile( RAS_VAR ) )
+ if ( ras.cProfile->flags & Flow_Up )
+ o = IS_TOP_OVERSHOOT( ras.lastY );
+ else
+ o = IS_BOTTOM_OVERSHOOT( ras.lastY );
+ if ( End_Profile( RAS_VARS o ) )
return FAILURE;
/* close the `next profile in contour' linked list */
@@ -2045,7 +2160,7 @@ a };
while ( current )
{
current->X = *current->offset;
- current->offset += current->flow;
+ current->offset += current->flags & Flow_Up ? 1 : -1;
current->height--;
current = current->link;
}
@@ -2220,16 +2335,19 @@ a };
if ( e1 > e2 )
{
+ Int dropOutControl = left->flags & 7;
+
+
if ( e1 == e2 + ras.precision )
{
- switch ( ras.dropOutControl )
+ switch ( dropOutControl )
{
case 0: /* simple drop-outs including stubs */
pxl = e2;
break;
case 4: /* smart drop-outs including stubs */
- pxl = FLOOR( ( x1 + x2 + 1 ) / 2 + ras.precision_half );
+ pxl = FLOOR( ( x1 + x2 - 1 ) / 2 + ras.precision_half );
break;
case 1: /* simple drop-outs excluding stubs */
@@ -2237,11 +2355,10 @@ a };
/* Drop-out Control Rules #4 and #6 */
- /* The spec is not very clear regarding those rules. It */
- /* presents a method that is way too costly to implement */
- /* while the general idea seems to get rid of `stubs'. */
+ /* The specification neither provides an exact definition */
+ /* of a `stub' nor gives exact rules to exclude them. */
/* */
- /* Here, we only get rid of stubs recognized if: */
+ /* Here the constraints we use to recognize a stub. */
/* */
/* upper stub: */
/* */
@@ -2255,27 +2372,31 @@ a };
/* - P_Left is the successor of P_Right in that contour */
/* - y is the bottom of P_Left */
/* */
+ /* We draw a stub if the following constraints are met. */
+ /* */
+ /* - for an upper or lower stub, there is top or bottom */
+ /* overshoot, respectively */
+ /* - the covered interval is greater or equal to a half */
+ /* pixel */
+
+ /* upper stub test */
+ if ( left->next == right &&
+ left->height <= 0 &&
+ !( left->flags & Overshoot_Top &&
+ x2 - x1 >= ras.precision_half ) )
+ return;
- /* FIXXXME: uncommenting this line solves the disappearing */
- /* bit problem in the `7' of verdana 10pts, but */
- /* makes a new one in the `C' of arial 14pts */
-#if 0
- if ( x2 - x1 < ras.precision_half )
-#endif
- {
- /* upper stub test */
- if ( left->next == right && left->height <= 0 )
- return;
-
- /* lower stub test */
- if ( right->next == left && left->start == y )
- return;
- }
+ /* lower stub test */
+ if ( right->next == left &&
+ left->start == y &&
+ !( left->flags & Overshoot_Bottom &&
+ x2 - x1 >= ras.precision_half ) )
+ return;
- if ( ras.dropOutControl == 1 )
+ if ( dropOutControl == 1 )
pxl = e2;
else
- pxl = FLOOR( ( x1 + x2 + 1 ) / 2 + ras.precision_half );
+ pxl = FLOOR( ( x1 + x2 - 1 ) / 2 + ras.precision_half );
break;
default: /* modes 2, 3, 6, 7 */
@@ -2415,16 +2536,19 @@ a };
if ( e1 > e2 )
{
+ Int dropOutControl = left->flags & 7;
+
+
if ( e1 == e2 + ras.precision )
{
- switch ( ras.dropOutControl )
+ switch ( dropOutControl )
{
case 0: /* simple drop-outs including stubs */
pxl = e2;
break;
case 4: /* smart drop-outs including stubs */
- pxl = FLOOR( ( x1 + x2 + 1 ) / 2 + ras.precision_half );
+ pxl = FLOOR( ( x1 + x2 - 1 ) / 2 + ras.precision_half );
break;
case 1: /* simple drop-outs excluding stubs */
@@ -2432,17 +2556,23 @@ a };
/* see Vertical_Sweep_Drop for details */
/* rightmost stub test */
- if ( left->next == right && left->height <= 0 )
+ if ( left->next == right &&
+ left->height <= 0 &&
+ !( left->flags & Overshoot_Top &&
+ x2 - x1 >= ras.precision_half ) )
return;
/* leftmost stub test */
- if ( right->next == left && left->start == y )
+ if ( right->next == left &&
+ left->start == y &&
+ !( left->flags & Overshoot_Bottom &&
+ x2 - x1 >= ras.precision_half ) )
return;
- if ( ras.dropOutControl == 1 )
+ if ( dropOutControl == 1 )
pxl = e2;
else
- pxl = FLOOR( ( x1 + x2 + 1 ) / 2 + ras.precision_half );
+ pxl = FLOOR( ( x1 + x2 - 1 ) / 2 + ras.precision_half );
break;
default: /* modes 2, 3, 6, 7 */
@@ -2543,10 +2673,10 @@ a };
static void
Vertical_Gray_Sweep_Step( RAS_ARG )
{
- Int c1, c2;
- PByte pix, bit, bit2;
- char* count = (char*)count_table;
- Byte* grays;
+ Int c1, c2;
+ PByte pix, bit, bit2;
+ short* count = (short*)count_table;
+ Byte* grays;
ras.traceOfs += ras.gray_width;
@@ -2665,16 +2795,19 @@ a };
if ( e1 > e2 )
{
+ Int dropOutControl = left->flags & 7;
+
+
if ( e1 == e2 + ras.precision )
{
- switch ( ras.dropOutControl )
+ switch ( dropOutControl )
{
case 0: /* simple drop-outs including stubs */
e1 = e2;
break;
case 4: /* smart drop-outs including stubs */
- e1 = FLOOR( ( x1 + x2 + 1 ) / 2 + ras.precision_half );
+ e1 = FLOOR( ( x1 + x2 - 1 ) / 2 + ras.precision_half );
break;
case 1: /* simple drop-outs excluding stubs */
@@ -2689,10 +2822,10 @@ a };
if ( right->next == left && left->start == y )
return;
- if ( ras.dropOutControl == 1 )
+ if ( dropOutControl == 1 )
e1 = e2;
else
- e1 = FLOOR( ( x1 + x2 + 1 ) / 2 + ras.precision_half );
+ e1 = FLOOR( ( x1 + x2 - 1 ) / 2 + ras.precision_half );
break;
@@ -2806,7 +2939,7 @@ a };
y = min_Y;
y_height = 0;
- if ( ras.numTurns > 0 &&
+ if ( ras.numTurns > 0 &&
ras.sizeBuff[-ras.numTurns] == min_Y )
ras.numTurns--;
@@ -2824,16 +2957,10 @@ a };
{
DelOld( &waiting, P );
- switch ( P->flow )
- {
- case Flow_Up:
+ if ( P->flags & Flow_Up )
InsNew( &draw_left, P );
- break;
-
- case Flow_Down:
+ else
InsNew( &draw_right, P );
- break;
- }
}
P = Q;
@@ -2876,7 +3003,10 @@ a };
{
if ( e1 > e2 || e2 == e1 + ras.precision )
{
- if ( ras.dropOutControl != 2 )
+ Int dropOutControl = P_Left->flags & 7;
+
+
+ if ( dropOutControl != 2 )
{
/* a drop-out was detected */
@@ -3070,7 +3200,7 @@ a };
Set_High_Precision( RAS_VARS ras.outline.flags &
- FT_OUTLINE_HIGH_PRECISION );
+ FT_OUTLINE_HIGH_PRECISION );
ras.scale_shift = ras.precision_shift;
if ( ras.outline.flags & FT_OUTLINE_IGNORE_DROPOUTS )
@@ -3146,7 +3276,7 @@ a };
Set_High_Precision( RAS_VARS ras.outline.flags &
- FT_OUTLINE_HIGH_PRECISION );
+ FT_OUTLINE_HIGH_PRECISION );
ras.scale_shift = ras.precision_shift + 1;
if ( ras.outline.flags & FT_OUTLINE_IGNORE_DROPOUTS )
@@ -3234,7 +3364,6 @@ a };
raster->grays[n] = n * 255 / 4;
raster->gray_width = RASTER_GRAY_LINES / 2;
-
#else
FT_UNUSED( raster );
#endif
@@ -3411,23 +3540,24 @@ a };
#ifdef FT_RASTER_OPTION_ANTI_ALIASING
worker->grays = raster->grays;
worker->gray_width = raster->gray_width;
+
+ FT_MEM_ZERO( worker->gray_lines, worker->gray_width * 2 );
#endif
- return ( ( params->flags & FT_RASTER_FLAG_AA )
- ? Render_Gray_Glyph( RAS_VAR )
- : Render_Glyph( RAS_VAR ) );
+ return ( params->flags & FT_RASTER_FLAG_AA )
+ ? Render_Gray_Glyph( RAS_VAR )
+ : Render_Glyph( RAS_VAR );
}
- const FT_Raster_Funcs ft_standard_raster =
- {
+ FT_DEFINE_RASTER_FUNCS( ft_standard_raster,
FT_GLYPH_FORMAT_OUTLINE,
(FT_Raster_New_Func) ft_black_new,
(FT_Raster_Reset_Func) ft_black_reset,
(FT_Raster_Set_Mode_Func)ft_black_set_mode,
(FT_Raster_Render_Func) ft_black_render,
(FT_Raster_Done_Func) ft_black_done
- };
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/raster/ftrend1.c b/src/3rdparty/freetype/src/raster/ftrend1.c
index 3cc8d07413..1ed8af6121 100644
--- a/src/3rdparty/freetype/src/raster/ftrend1.c
+++ b/src/3rdparty/freetype/src/raster/ftrend1.c
@@ -21,6 +21,7 @@
#include FT_OUTLINE_H
#include "ftrend1.h"
#include "ftraster.h"
+#include "rastpic.h"
#include "rasterrs.h"
@@ -118,6 +119,7 @@
}
/* check rendering mode */
+#ifndef FT_CONFIG_OPTION_PIC
if ( mode != FT_RENDER_MODE_MONO )
{
/* raster1 is only capable of producing monochrome bitmaps */
@@ -130,6 +132,25 @@
if ( render->clazz == &ft_raster5_renderer_class )
return Raster_Err_Cannot_Render_Glyph;
}
+#else /* FT_CONFIG_OPTION_PIC */
+ /* When PIC is enabled, we cannot get to the class object */
+ /* so instead we check the final character in the class name */
+ /* ("raster5" or "raster1"). Yes this is a hack. */
+ /* The "correct" thing to do is have different render function */
+ /* for each of the classes. */
+ if ( mode != FT_RENDER_MODE_MONO )
+ {
+ /* raster1 is only capable of producing monochrome bitmaps */
+ if ( render->clazz->root.module_name[6] == '1' )
+ return Raster_Err_Cannot_Render_Glyph;
+ }
+ else
+ {
+ /* raster5 is only capable of producing 5-gray-levels bitmaps */
+ if ( render->clazz->root.module_name[6] == '5' )
+ return Raster_Err_Cannot_Render_Glyph;
+ }
+#endif /* FT_CONFIG_OPTION_PIC */
outline = &slot->outline;
@@ -208,10 +229,8 @@
}
- FT_CALLBACK_TABLE_DEF
- const FT_Renderer_Class ft_raster1_renderer_class =
- {
- {
+ FT_DEFINE_RENDERER(ft_raster1_renderer_class,
+
FT_MODULE_RENDERER,
sizeof( FT_RendererRec ),
@@ -224,7 +243,7 @@
(FT_Module_Constructor)ft_raster1_init,
(FT_Module_Destructor) 0,
(FT_Module_Requester) 0
- },
+ ,
FT_GLYPH_FORMAT_OUTLINE,
@@ -233,18 +252,17 @@
(FT_Renderer_GetCBoxFunc) ft_raster1_get_cbox,
(FT_Renderer_SetModeFunc) ft_raster1_set_mode,
- (FT_Raster_Funcs*) &ft_standard_raster
- };
+ (FT_Raster_Funcs*) &FT_STANDARD_RASTER_GET
+ )
/* This renderer is _NOT_ part of the default modules; you will need */
/* to register it by hand in your application. It should only be */
/* used for backwards-compatibility with FT 1.x anyway. */
/* */
- FT_CALLBACK_TABLE_DEF
- const FT_Renderer_Class ft_raster5_renderer_class =
- {
- {
+ FT_DEFINE_RENDERER(ft_raster5_renderer_class,
+
+
FT_MODULE_RENDERER,
sizeof( FT_RendererRec ),
@@ -257,7 +275,7 @@
(FT_Module_Constructor)ft_raster1_init,
(FT_Module_Destructor) 0,
(FT_Module_Requester) 0
- },
+ ,
FT_GLYPH_FORMAT_OUTLINE,
@@ -266,8 +284,8 @@
(FT_Renderer_GetCBoxFunc) ft_raster1_get_cbox,
(FT_Renderer_SetModeFunc) ft_raster1_set_mode,
- (FT_Raster_Funcs*) &ft_standard_raster
- };
+ (FT_Raster_Funcs*) &FT_STANDARD_RASTER_GET
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/raster/ftrend1.h b/src/3rdparty/freetype/src/raster/ftrend1.h
index 76e9a5f581..4cf128622a 100644
--- a/src/3rdparty/freetype/src/raster/ftrend1.h
+++ b/src/3rdparty/freetype/src/raster/ftrend1.h
@@ -27,13 +27,13 @@
FT_BEGIN_HEADER
- FT_EXPORT_VAR( const FT_Renderer_Class ) ft_raster1_renderer_class;
+ FT_DECLARE_RENDERER( ft_raster1_renderer_class )
/* this renderer is _NOT_ part of the default modules, you'll need */
/* to register it by hand in your application. It should only be */
/* used for backwards-compatibility with FT 1.x anyway. */
/* */
- FT_EXPORT_VAR( const FT_Renderer_Class ) ft_raster5_renderer_class;
+ FT_DECLARE_RENDERER( ft_raster5_renderer_class )
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/raster/raster.c b/src/3rdparty/freetype/src/raster/raster.c
index f13a67a209..1202a116cd 100644
--- a/src/3rdparty/freetype/src/raster/raster.c
+++ b/src/3rdparty/freetype/src/raster/raster.c
@@ -19,6 +19,7 @@
#define FT_MAKE_OPTION_SINGLE_OBJECT
#include <ft2build.h>
+#include "rastpic.c"
#include "ftraster.c"
#include "ftrend1.c"
diff --git a/src/3rdparty/freetype/src/raster/rastpic.c b/src/3rdparty/freetype/src/raster/rastpic.c
new file mode 100644
index 0000000000..3c264877b6
--- /dev/null
+++ b/src/3rdparty/freetype/src/raster/rastpic.c
@@ -0,0 +1,89 @@
+/***************************************************************************/
+/* */
+/* rastpic.c */
+/* */
+/* The FreeType position independent code services for raster module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#include <ft2build.h>
+#include FT_FREETYPE_H
+#include FT_INTERNAL_OBJECTS_H
+#include "rastpic.h"
+
+#ifdef FT_CONFIG_OPTION_PIC
+
+ /* forward declaration of PIC init functions from ftraster.c */
+ void FT_Init_Class_ft_standard_raster(FT_Raster_Funcs*);
+
+ void
+ ft_raster1_renderer_class_pic_free( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+ if ( pic_container->raster )
+ {
+ RasterPIC* container = (RasterPIC*)pic_container->raster;
+ if(--container->ref_count)
+ return;
+ FT_FREE( container );
+ pic_container->raster = NULL;
+ }
+ }
+
+
+ FT_Error
+ ft_raster1_renderer_class_pic_init( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Error error = FT_Err_Ok;
+ RasterPIC* container;
+ FT_Memory memory = library->memory;
+
+ /* since this function also serve raster5 renderer,
+ it implements reference counting */
+ if(pic_container->raster)
+ {
+ ((RasterPIC*)pic_container->raster)->ref_count++;
+ return error;
+ }
+
+ /* allocate pointer, clear and set global container pointer */
+ if ( FT_ALLOC ( container, sizeof ( *container ) ) )
+ return error;
+ FT_MEM_SET( container, 0, sizeof(*container) );
+ pic_container->raster = container;
+ container->ref_count = 1;
+
+ /* initialize pointer table - this is how the module usually expects this data */
+ FT_Init_Class_ft_standard_raster(&container->ft_standard_raster);
+/*Exit:*/
+ if(error)
+ ft_raster1_renderer_class_pic_free(library);
+ return error;
+ }
+
+ /* re-route these init and free functions to the above functions */
+ FT_Error ft_raster5_renderer_class_pic_init(FT_Library library)
+ {
+ return ft_raster1_renderer_class_pic_init(library);
+ }
+ void ft_raster5_renderer_class_pic_free(FT_Library library)
+ {
+ ft_raster1_renderer_class_pic_free(library);
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/raster/rastpic.h b/src/3rdparty/freetype/src/raster/rastpic.h
new file mode 100644
index 0000000000..dcd82b8ca8
--- /dev/null
+++ b/src/3rdparty/freetype/src/raster/rastpic.h
@@ -0,0 +1,50 @@
+/***************************************************************************/
+/* */
+/* rastpic.h */
+/* */
+/* The FreeType position independent code services for raster module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifndef __RASTPIC_H__
+#define __RASTPIC_H__
+
+
+FT_BEGIN_HEADER
+
+#include FT_INTERNAL_PIC_H
+
+#ifndef FT_CONFIG_OPTION_PIC
+#define FT_STANDARD_RASTER_GET ft_standard_raster
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+ typedef struct RasterPIC_
+ {
+ int ref_count;
+ FT_Raster_Funcs ft_standard_raster;
+ } RasterPIC;
+
+#define GET_PIC(lib) ((RasterPIC*)((lib)->pic_container.raster))
+#define FT_STANDARD_RASTER_GET (GET_PIC(library)->ft_standard_raster)
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /* */
+
+FT_END_HEADER
+
+#endif /* __RASTPIC_H__ */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/raster/rules.mk b/src/3rdparty/freetype/src/raster/rules.mk
index 43a9af2b79..9703b1298a 100644
--- a/src/3rdparty/freetype/src/raster/rules.mk
+++ b/src/3rdparty/freetype/src/raster/rules.mk
@@ -3,7 +3,7 @@
#
-# Copyright 1996-2000, 2001, 2003, 2008 by
+# Copyright 1996-2000, 2001, 2003, 2008, 2009 by
# David Turner, Robert Wilhelm, and Werner Lemberg.
#
# This file is part of the FreeType project, and may only be used, modified,
@@ -31,7 +31,6 @@ RASTER_DRV_SRC := $(RASTER_DIR)/ftraster.c \
# raster driver headers
#
RASTER_DRV_H := $(RASTER_DRV_SRC:%.c=%.h) \
- $(RASTER_DIR)/ftmisc.h \
$(RASTER_DIR)/rasterrs.h
diff --git a/src/3rdparty/freetype/src/sfnt/Jamfile b/src/3rdparty/freetype/src/sfnt/Jamfile
index ad467bebec..cb20b1b04b 100644
--- a/src/3rdparty/freetype/src/sfnt/Jamfile
+++ b/src/3rdparty/freetype/src/sfnt/Jamfile
@@ -16,7 +16,7 @@ SubDir FT2_TOP $(FT2_SRC_DIR) sfnt ;
if $(FT2_MULTI)
{
- _sources = sfobjs sfdriver ttcmap ttmtx ttpost ttload ttsbit ttkern ttbdf ;
+ _sources = sfobjs sfdriver ttcmap ttmtx ttpost ttload ttsbit ttkern ttbdf sfntpic ;
}
else
{
diff --git a/src/3rdparty/freetype/src/sfnt/sfdriver.c b/src/3rdparty/freetype/src/sfnt/sfdriver.c
index 142ef767da..1097efb86d 100644
--- a/src/3rdparty/freetype/src/sfnt/sfdriver.c
+++ b/src/3rdparty/freetype/src/sfnt/sfdriver.c
@@ -17,12 +17,14 @@
#include <ft2build.h>
+#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_SFNT_H
#include FT_INTERNAL_OBJECTS_H
#include "sfdriver.h"
#include "ttload.h"
#include "sfobjs.h"
+#include "sfntpic.h"
#include "sferrors.h"
@@ -48,6 +50,15 @@
#include FT_SERVICE_SFNT_H
#include FT_SERVICE_TT_CMAP_H
+ /*************************************************************************/
+ /* */
+ /* The macro FT_COMPONENT is used in trace mode. It is an implicit */
+ /* parameter of the FT_TRACE() and FT_ERROR() macros, used to print/log */
+ /* messages during execution. */
+ /* */
+#undef FT_COMPONENT
+#define FT_COMPONENT trace_sfdriver
+
/*
* SFNT TABLE SERVICE
@@ -103,27 +114,28 @@
sfnt_table_info( TT_Face face,
FT_UInt idx,
FT_ULong *tag,
+ FT_ULong *offset,
FT_ULong *length )
{
- if ( !tag || !length )
+ if ( !tag || !offset || !length )
return SFNT_Err_Invalid_Argument;
if ( idx >= face->num_tables )
return SFNT_Err_Table_Missing;
*tag = face->dir_tables[idx].Tag;
+ *offset = face->dir_tables[idx].Offset;
*length = face->dir_tables[idx].Length;
return SFNT_Err_Ok;
}
- static const FT_Service_SFNT_TableRec sfnt_service_sfnt_table =
- {
+ FT_DEFINE_SERVICE_SFNT_TABLEREC(sfnt_service_sfnt_table,
(FT_SFNT_TableLoadFunc)tt_face_load_any,
(FT_SFNT_TableGetFunc) get_sfnt_table,
(FT_SFNT_TableInfoFunc)sfnt_table_info
- };
+ )
#ifdef TT_CONFIG_OPTION_POSTSCRIPT_NAMES
@@ -155,11 +167,19 @@
sfnt_get_name_index( TT_Face face,
FT_String* glyph_name )
{
- FT_Face root = &face->root;
- FT_Long i;
+ FT_Face root = &face->root;
+ FT_UInt i, max_gid = FT_UINT_MAX;
+
+ if ( root->num_glyphs < 0 )
+ return 0;
+ else if ( ( FT_ULong ) root->num_glyphs < FT_UINT_MAX )
+ max_gid = ( FT_UInt ) root->num_glyphs;
+ else
+ FT_TRACE0(( "Ignore glyph names for invalid GID 0x%08x - 0x%08x\n",
+ FT_UINT_MAX, root->num_glyphs ));
- for ( i = 0; i < root->num_glyphs; i++ )
+ for ( i = 0; i < max_gid; i++ )
{
FT_String* gname;
FT_Error error = tt_face_get_ps_name( face, i, &gname );
@@ -169,18 +189,17 @@
continue;
if ( !ft_strcmp( glyph_name, gname ) )
- return (FT_UInt)i;
+ return i;
}
return 0;
}
- static const FT_Service_GlyphDictRec sfnt_service_glyph_dict =
- {
+ FT_DEFINE_SERVICE_GLYPHDICTREC(sfnt_service_glyph_dict,
(FT_GlyphDict_GetNameFunc) sfnt_get_glyph_name,
(FT_GlyphDict_NameIndexFunc)sfnt_get_name_index
- };
+ )
#endif /* TT_CONFIG_OPTION_POSTSCRIPT_NAMES */
@@ -300,19 +319,17 @@
return result;
}
- static const FT_Service_PsFontNameRec sfnt_service_ps_name =
- {
+ FT_DEFINE_SERVICE_PSFONTNAMEREC(sfnt_service_ps_name,
(FT_PsName_GetFunc)sfnt_get_ps_name
- };
+ )
/*
* TT CMAP INFO
*/
- static const FT_Service_TTCMapsRec tt_service_get_cmap_info =
- {
+ FT_DEFINE_SERVICE_TTCMAPSREC(tt_service_get_cmap_info,
(TT_CMap_Info_GetFunc)tt_get_cmap_info
- };
+ )
#ifdef TT_CONFIG_OPTION_BDF
@@ -353,11 +370,10 @@
}
- static const FT_Service_BDFRec sfnt_service_bdf =
- {
+ FT_DEFINE_SERVICE_BDFRec(sfnt_service_bdf,
(FT_BDF_GetCharsetIdFunc) sfnt_get_charset_id,
- (FT_BDF_GetPropertyFunc) tt_face_find_bdf_prop,
- };
+ (FT_BDF_GetPropertyFunc) tt_face_find_bdf_prop
+ )
#endif /* TT_CONFIG_OPTION_BDF */
@@ -366,20 +382,35 @@
* SERVICE LIST
*/
- static const FT_ServiceDescRec sfnt_services[] =
- {
- { FT_SERVICE_ID_SFNT_TABLE, &sfnt_service_sfnt_table },
- { FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &sfnt_service_ps_name },
-#ifdef TT_CONFIG_OPTION_POSTSCRIPT_NAMES
- { FT_SERVICE_ID_GLYPH_DICT, &sfnt_service_glyph_dict },
-#endif
-#ifdef TT_CONFIG_OPTION_BDF
- { FT_SERVICE_ID_BDF, &sfnt_service_bdf },
+#if defined TT_CONFIG_OPTION_POSTSCRIPT_NAMES && defined TT_CONFIG_OPTION_BDF
+ FT_DEFINE_SERVICEDESCREC5(sfnt_services,
+ FT_SERVICE_ID_SFNT_TABLE, &FT_SFNT_SERVICE_SFNT_TABLE_GET,
+ FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &FT_SFNT_SERVICE_PS_NAME_GET,
+ FT_SERVICE_ID_GLYPH_DICT, &FT_SFNT_SERVICE_GLYPH_DICT_GET,
+ FT_SERVICE_ID_BDF, &FT_SFNT_SERVICE_BDF_GET,
+ FT_SERVICE_ID_TT_CMAP, &FT_TT_SERVICE_GET_CMAP_INFO_GET
+ )
+#elif defined TT_CONFIG_OPTION_POSTSCRIPT_NAMES
+ FT_DEFINE_SERVICEDESCREC4(sfnt_services,
+ FT_SERVICE_ID_SFNT_TABLE, &FT_SFNT_SERVICE_SFNT_TABLE_GET,
+ FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &FT_SFNT_SERVICE_PS_NAME_GET,
+ FT_SERVICE_ID_GLYPH_DICT, &FT_SFNT_SERVICE_GLYPH_DICT_GET,
+ FT_SERVICE_ID_TT_CMAP, &FT_TT_SERVICE_GET_CMAP_INFO_GET
+ )
+#elif defined TT_CONFIG_OPTION_BDF
+ FT_DEFINE_SERVICEDESCREC4(sfnt_services,
+ FT_SERVICE_ID_SFNT_TABLE, &FT_SFNT_SERVICE_SFNT_TABLE_GET,
+ FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &FT_SFNT_SERVICE_PS_NAME_GET,
+ FT_SERVICE_ID_BDF, &FT_SFNT_SERVICE_BDF_GET,
+ FT_SERVICE_ID_TT_CMAP, &FT_TT_SERVICE_GET_CMAP_INFO_GET
+ )
+#else
+ FT_DEFINE_SERVICEDESCREC3(sfnt_services,
+ FT_SERVICE_ID_SFNT_TABLE, &FT_SFNT_SERVICE_SFNT_TABLE_GET,
+ FT_SERVICE_ID_POSTSCRIPT_FONT_NAME, &FT_SFNT_SERVICE_PS_NAME_GET,
+ FT_SERVICE_ID_TT_CMAP, &FT_TT_SERVICE_GET_CMAP_INFO_GET
+ )
#endif
- { FT_SERVICE_ID_TT_CMAP, &tt_service_get_cmap_info },
-
- { NULL, NULL }
- };
FT_CALLBACK_DEF( FT_Module_Interface )
@@ -388,7 +419,7 @@
{
FT_UNUSED( module );
- return ft_service_list_lookup( sfnt_services, module_interface );
+ return ft_service_list_lookup( FT_SFNT_SERVICES_GET, module_interface );
}
@@ -519,10 +550,18 @@
#endif /* FT_CONFIG_OPTION_OLD_INTERNALS */
+#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
+#define PUT_EMBEDDED_BITMAPS(a) a
+#else
+#define PUT_EMBEDDED_BITMAPS(a) 0
+#endif
+#ifdef TT_CONFIG_OPTION_POSTSCRIPT_NAMES
+#define PUT_PS_NAMES(a) a
+#else
+#define PUT_PS_NAMES(a) 0
+#endif
- static
- const SFNT_Interface sfnt_interface =
- {
+ FT_DEFINE_SFNT_INTERFACE(sfnt_interface,
tt_face_goto_table,
sfnt_init_face,
@@ -532,10 +571,8 @@
tt_face_load_any,
-#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
- tt_face_load_sfnt_header_stub,
- tt_face_load_directory_stub,
-#endif
+ tt_face_load_sfnt_header_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ tt_face_load_directory_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
tt_face_load_head,
tt_face_load_hhea,
@@ -547,53 +584,32 @@
tt_face_load_name,
tt_face_free_name,
-#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
- tt_face_load_hdmx_stub,
- tt_face_free_hdmx_stub,
-#endif
+ tt_face_load_hdmx_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ tt_face_free_hdmx_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
tt_face_load_kern,
tt_face_load_gasp,
tt_face_load_pclt,
-#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
/* see `ttload.h' */
- tt_face_load_bhed,
-#else
- 0,
-#endif
+ PUT_EMBEDDED_BITMAPS(tt_face_load_bhed),
-#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
- tt_face_set_sbit_strike_stub,
- tt_face_load_sbit_stub,
+ tt_face_set_sbit_strike_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ tt_face_load_sbit_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
- tt_find_sbit_image,
- tt_load_sbit_metrics,
-#endif
+ tt_find_sbit_image, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ tt_load_sbit_metrics, /* FT_CONFIG_OPTION_OLD_INTERNALS */
-#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
- tt_face_load_sbit_image,
-#else
- 0,
-#endif
+ PUT_EMBEDDED_BITMAPS(tt_face_load_sbit_image),
-#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
- tt_face_free_sbit_stub,
-#endif
+ tt_face_free_sbit_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
-#ifdef TT_CONFIG_OPTION_POSTSCRIPT_NAMES
/* see `ttpost.h' */
- tt_face_get_ps_name,
- tt_face_free_ps_names,
-#else
- 0,
- 0,
-#endif
+ PUT_PS_NAMES(tt_face_get_ps_name),
+ PUT_PS_NAMES(tt_face_free_ps_names),
-#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
- tt_face_load_charmap_stub,
- tt_face_free_charmap_stub,
-#endif
+ tt_face_load_charmap_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ tt_face_free_charmap_stub, /* FT_CONFIG_OPTION_OLD_INTERNALS */
/* since version 2.1.8 */
@@ -604,27 +620,19 @@
tt_face_load_font_dir,
tt_face_load_hmtx,
-#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
/* see `ttsbit.h' and `sfnt.h' */
- tt_face_load_eblc,
- tt_face_free_eblc,
+ PUT_EMBEDDED_BITMAPS(tt_face_load_eblc),
+ PUT_EMBEDDED_BITMAPS(tt_face_free_eblc),
- tt_face_set_sbit_strike,
- tt_face_load_strike_metrics,
-#else
- 0,
- 0,
- 0,
- 0,
-#endif
+ PUT_EMBEDDED_BITMAPS(tt_face_set_sbit_strike),
+ PUT_EMBEDDED_BITMAPS(tt_face_load_strike_metrics),
tt_face_get_metrics
- };
+ )
- FT_CALLBACK_TABLE_DEF
- const FT_Module_Class sfnt_module_class =
- {
+ FT_DEFINE_MODULE(sfnt_module_class,
+
0, /* not a font driver or renderer */
sizeof( FT_ModuleRec ),
@@ -632,12 +640,12 @@
0x10000L, /* driver version 1.0 */
0x20000L, /* driver requires FreeType 2.0 or higher */
- (const void*)&sfnt_interface, /* module specific interface */
+ (const void*)&FT_SFNT_INTERFACE_GET, /* module specific interface */
(FT_Module_Constructor)0,
(FT_Module_Destructor) 0,
(FT_Module_Requester) sfnt_get_interface
- };
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/sfnt/sfdriver.h b/src/3rdparty/freetype/src/sfnt/sfdriver.h
index 92db79694d..5de25d51ca 100644
--- a/src/3rdparty/freetype/src/sfnt/sfdriver.h
+++ b/src/3rdparty/freetype/src/sfnt/sfdriver.h
@@ -27,7 +27,7 @@
FT_BEGIN_HEADER
- FT_EXPORT_VAR( const FT_Module_Class ) sfnt_module_class;
+ FT_DECLARE_MODULE( sfnt_module_class )
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/sfnt/sfnt.c b/src/3rdparty/freetype/src/sfnt/sfnt.c
index 45a820b718..fc507b4961 100644
--- a/src/3rdparty/freetype/src/sfnt/sfnt.c
+++ b/src/3rdparty/freetype/src/sfnt/sfnt.c
@@ -19,6 +19,7 @@
#define FT_MAKE_OPTION_SINGLE_OBJECT
#include <ft2build.h>
+#include "sfntpic.c"
#include "ttload.c"
#include "ttmtx.c"
#include "ttcmap.c"
diff --git a/src/3rdparty/freetype/src/sfnt/sfntpic.c b/src/3rdparty/freetype/src/sfnt/sfntpic.c
new file mode 100644
index 0000000000..fd3cf4e923
--- /dev/null
+++ b/src/3rdparty/freetype/src/sfnt/sfntpic.c
@@ -0,0 +1,101 @@
+/***************************************************************************/
+/* */
+/* sfntpic.c */
+/* */
+/* The FreeType position independent code services for sfnt module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#include <ft2build.h>
+#include FT_FREETYPE_H
+#include FT_INTERNAL_OBJECTS_H
+#include "sfntpic.h"
+
+#ifdef FT_CONFIG_OPTION_PIC
+
+ /* forward declaration of PIC init functions from sfdriver.c */
+ FT_Error FT_Create_Class_sfnt_services( FT_Library, FT_ServiceDescRec**);
+ void FT_Destroy_Class_sfnt_services( FT_Library, FT_ServiceDescRec*);
+ void FT_Init_Class_sfnt_service_bdf( FT_Service_BDFRec*);
+ void FT_Init_Class_sfnt_interface( FT_Library, SFNT_Interface*);
+ void FT_Init_Class_sfnt_service_glyph_dict( FT_Library, FT_Service_GlyphDictRec*);
+ void FT_Init_Class_sfnt_service_ps_name( FT_Library, FT_Service_PsFontNameRec*);
+ void FT_Init_Class_tt_service_get_cmap_info( FT_Library, FT_Service_TTCMapsRec*);
+ void FT_Init_Class_sfnt_service_sfnt_table( FT_Service_SFNT_TableRec*);
+
+ /* forward declaration of PIC init functions from ttcmap.c */
+ FT_Error FT_Create_Class_tt_cmap_classes( FT_Library, TT_CMap_Class**);
+ void FT_Destroy_Class_tt_cmap_classes( FT_Library, TT_CMap_Class*);
+
+ void
+ sfnt_module_class_pic_free( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+ if ( pic_container->sfnt )
+ {
+ sfntModulePIC* container = (sfntModulePIC*)pic_container->sfnt;
+ if(container->sfnt_services)
+ FT_Destroy_Class_sfnt_services(library, container->sfnt_services);
+ container->sfnt_services = NULL;
+ if(container->tt_cmap_classes)
+ FT_Destroy_Class_tt_cmap_classes(library, container->tt_cmap_classes);
+ container->tt_cmap_classes = NULL;
+ FT_FREE( container );
+ pic_container->sfnt = NULL;
+ }
+ }
+
+
+ FT_Error
+ sfnt_module_class_pic_init( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Error error = FT_Err_Ok;
+ sfntModulePIC* container;
+ FT_Memory memory = library->memory;
+
+ /* allocate pointer, clear and set global container pointer */
+ if ( FT_ALLOC ( container, sizeof ( *container ) ) )
+ return error;
+ FT_MEM_SET( container, 0, sizeof(*container) );
+ pic_container->sfnt = container;
+
+ /* initialize pointer table - this is how the module usually expects this data */
+ error = FT_Create_Class_sfnt_services(library, &container->sfnt_services);
+ if(error)
+ goto Exit;
+ error = FT_Create_Class_tt_cmap_classes(library, &container->tt_cmap_classes);
+ if(error)
+ goto Exit;
+ FT_Init_Class_sfnt_service_glyph_dict(library, &container->sfnt_service_glyph_dict);
+ FT_Init_Class_sfnt_service_ps_name(library, &container->sfnt_service_ps_name);
+ FT_Init_Class_tt_service_get_cmap_info(library, &container->tt_service_get_cmap_info);
+ FT_Init_Class_sfnt_service_sfnt_table(&container->sfnt_service_sfnt_table);
+#ifdef TT_CONFIG_OPTION_BDF
+ FT_Init_Class_sfnt_service_bdf(&container->sfnt_service_bdf);
+#endif
+ FT_Init_Class_sfnt_interface(library, &container->sfnt_interface);
+
+Exit:
+ if(error)
+ sfnt_module_class_pic_free(library);
+ return error;
+ }
+
+
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/sfnt/sfntpic.h b/src/3rdparty/freetype/src/sfnt/sfntpic.h
new file mode 100644
index 0000000000..6943b4250a
--- /dev/null
+++ b/src/3rdparty/freetype/src/sfnt/sfntpic.h
@@ -0,0 +1,88 @@
+/***************************************************************************/
+/* */
+/* sfntpic.h */
+/* */
+/* The FreeType position independent code services for sfnt module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifndef __SFNTPIC_H__
+#define __SFNTPIC_H__
+
+
+FT_BEGIN_HEADER
+
+#include FT_INTERNAL_PIC_H
+
+ #ifndef FT_CONFIG_OPTION_PIC
+#define FT_SFNT_SERVICES_GET sfnt_services
+#define FT_SFNT_SERVICE_GLYPH_DICT_GET sfnt_service_glyph_dict
+#define FT_SFNT_SERVICE_PS_NAME_GET sfnt_service_ps_name
+#define FT_TT_SERVICE_GET_CMAP_INFO_GET tt_service_get_cmap_info
+#define FT_SFNT_SERVICES_GET sfnt_services
+#define FT_TT_CMAP_CLASSES_GET tt_cmap_classes
+#define FT_SFNT_SERVICE_SFNT_TABLE_GET sfnt_service_sfnt_table
+#define FT_SFNT_SERVICE_BDF_GET sfnt_service_bdf
+#define FT_SFNT_INTERFACE_GET sfnt_interface
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+/* some include files required for members of sfntModulePIC */
+#include FT_SERVICE_GLYPH_DICT_H
+#include FT_SERVICE_POSTSCRIPT_NAME_H
+#include FT_SERVICE_SFNT_H
+#include FT_SERVICE_TT_CMAP_H
+#ifdef TT_CONFIG_OPTION_BDF
+#include "ttbdf.h"
+#include FT_SERVICE_BDF_H
+#endif
+#include FT_INTERNAL_DEBUG_H
+#include FT_INTERNAL_STREAM_H
+#include FT_INTERNAL_SFNT_H
+#include "ttcmap.h"
+
+typedef struct sfntModulePIC_
+ {
+ FT_ServiceDescRec* sfnt_services;
+ FT_Service_GlyphDictRec sfnt_service_glyph_dict;
+ FT_Service_PsFontNameRec sfnt_service_ps_name;
+ FT_Service_TTCMapsRec tt_service_get_cmap_info;
+ TT_CMap_Class* tt_cmap_classes;
+ FT_Service_SFNT_TableRec sfnt_service_sfnt_table;
+#ifdef TT_CONFIG_OPTION_BDF
+ FT_Service_BDFRec sfnt_service_bdf;
+#endif
+ SFNT_Interface sfnt_interface;
+ } sfntModulePIC;
+
+#define GET_PIC(lib) ((sfntModulePIC*)((lib)->pic_container.sfnt))
+#define FT_SFNT_SERVICES_GET (GET_PIC(library)->sfnt_services)
+#define FT_SFNT_SERVICE_GLYPH_DICT_GET (GET_PIC(library)->sfnt_service_glyph_dict)
+#define FT_SFNT_SERVICE_PS_NAME_GET (GET_PIC(library)->sfnt_service_ps_name)
+#define FT_TT_SERVICE_GET_CMAP_INFO_GET (GET_PIC(library)->tt_service_get_cmap_info)
+#define FT_SFNT_SERVICES_GET (GET_PIC(library)->sfnt_services)
+#define FT_TT_CMAP_CLASSES_GET (GET_PIC(library)->tt_cmap_classes)
+#define FT_SFNT_SERVICE_SFNT_TABLE_GET (GET_PIC(library)->sfnt_service_sfnt_table)
+#define FT_SFNT_SERVICE_BDF_GET (GET_PIC(library)->sfnt_service_bdf)
+#define FT_SFNT_INTERFACE_GET (GET_PIC(library)->sfnt_interface)
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+/* */
+
+FT_END_HEADER
+
+#endif /* __SFNTPIC_H__ */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/sfnt/sfobjs.c b/src/3rdparty/freetype/src/sfnt/sfobjs.c
index c826b92aa3..b74b1a93a9 100644
--- a/src/3rdparty/freetype/src/sfnt/sfobjs.c
+++ b/src/3rdparty/freetype/src/sfnt/sfobjs.c
@@ -26,6 +26,7 @@
#include FT_TRUETYPE_IDS_H
#include FT_TRUETYPE_TAGS_H
#include FT_SERVICE_POSTSCRIPT_CMAPS_H
+#include FT_SFNT_NAMES_H
#include "sferrors.h"
#ifdef TT_CONFIG_OPTION_BDF
@@ -527,13 +528,27 @@
#endif
FT_Bool has_outline;
FT_Bool is_apple_sbit;
+ FT_Bool ignore_preferred_family = FALSE;
+ FT_Bool ignore_preferred_subfamily = FALSE;
SFNT_Service sfnt = (SFNT_Service)face->sfnt;
FT_UNUSED( face_index );
- FT_UNUSED( num_params );
- FT_UNUSED( params );
+ /* Check parameters */
+
+ {
+ FT_Int i;
+
+
+ for ( i = 0; i < num_params; i++ )
+ {
+ if ( params[i].tag == FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY )
+ ignore_preferred_family = TRUE;
+ else if ( params[i].tag == FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY )
+ ignore_preferred_subfamily = TRUE;
+ }
+ }
/* Load tables */
@@ -722,26 +737,30 @@
/* Foundation (WPF). This flag has been introduced in version */
/* 1.5 of the OpenType specification (May 2008). */
+ face->root.family_name = NULL;
+ face->root.style_name = NULL;
if ( face->os2.version != 0xFFFFU && face->os2.fsSelection & 256 )
{
- GET_NAME( PREFERRED_FAMILY, &face->root.family_name );
+ if ( !ignore_preferred_family )
+ GET_NAME( PREFERRED_FAMILY, &face->root.family_name );
if ( !face->root.family_name )
GET_NAME( FONT_FAMILY, &face->root.family_name );
- GET_NAME( PREFERRED_SUBFAMILY, &face->root.style_name );
+ if ( !ignore_preferred_subfamily )
+ GET_NAME( PREFERRED_SUBFAMILY, &face->root.style_name );
if ( !face->root.style_name )
GET_NAME( FONT_SUBFAMILY, &face->root.style_name );
}
else
{
GET_NAME( WWS_FAMILY, &face->root.family_name );
- if ( !face->root.family_name )
+ if ( !face->root.family_name && !ignore_preferred_family )
GET_NAME( PREFERRED_FAMILY, &face->root.family_name );
if ( !face->root.family_name )
GET_NAME( FONT_FAMILY, &face->root.family_name );
GET_NAME( WWS_SUBFAMILY, &face->root.style_name );
- if ( !face->root.style_name )
+ if ( !face->root.style_name && !ignore_preferred_subfamily )
GET_NAME( PREFERRED_SUBFAMILY, &face->root.style_name );
if ( !face->root.style_name )
GET_NAME( FONT_SUBFAMILY, &face->root.style_name );
@@ -749,8 +768,8 @@
/* now set up root fields */
{
- FT_Face root = &face->root;
- FT_Int32 flags = root->face_flags;
+ FT_Face root = &face->root;
+ FT_Long flags = root->face_flags;
/*********************************************************************/
diff --git a/src/3rdparty/freetype/src/sfnt/ttbdf.c b/src/3rdparty/freetype/src/sfnt/ttbdf.c
index 6c95387adb..206cecee5e 100644
--- a/src/3rdparty/freetype/src/sfnt/ttbdf.c
+++ b/src/3rdparty/freetype/src/sfnt/ttbdf.c
@@ -84,7 +84,7 @@
FT_Byte* p = bdf->table;
FT_UInt version = FT_NEXT_USHORT( p );
FT_UInt num_strikes = FT_NEXT_USHORT( p );
- FT_UInt32 strings = FT_NEXT_ULONG ( p );
+ FT_ULong strings = FT_NEXT_ULONG ( p );
FT_UInt count;
FT_Byte* strike;
@@ -141,13 +141,13 @@
const char* property_name,
BDF_PropertyRec *aprop )
{
- TT_BDF bdf = &face->bdf;
- FT_Size size = FT_FACE(face)->size;
- FT_Error error = 0;
- FT_Byte* p;
- FT_UInt count;
- FT_Byte* strike;
- FT_UInt property_len;
+ TT_BDF bdf = &face->bdf;
+ FT_Size size = FT_FACE(face)->size;
+ FT_Error error = 0;
+ FT_Byte* p;
+ FT_UInt count;
+ FT_Byte* strike;
+ FT_Offset property_len;
aprop->type = BDF_PROPERTY_TYPE_NONE;
diff --git a/src/3rdparty/freetype/src/sfnt/ttcmap.c b/src/3rdparty/freetype/src/sfnt/ttcmap.c
index 683039153b..b283f6d162 100644
--- a/src/3rdparty/freetype/src/sfnt/ttcmap.c
+++ b/src/3rdparty/freetype/src/sfnt/ttcmap.c
@@ -25,6 +25,7 @@
#include FT_INTERNAL_STREAM_H
#include "ttload.h"
#include "ttcmap.h"
+#include "sfntpic.h"
/*************************************************************************/
@@ -124,7 +125,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
tt_cmap0_char_next( TT_CMap cmap,
FT_UInt32 *pchar_code )
{
@@ -157,17 +158,14 @@
FT_Byte* p = cmap->data + 4;
- cmap_info->format = 0;
+ cmap_info->format = 0;
cmap_info->language = (FT_ULong)TT_PEEK_USHORT( p );
return SFNT_Err_Ok;
}
- FT_CALLBACK_TABLE_DEF
- const TT_CMap_ClassRec tt_cmap0_class_rec =
- {
- {
+ FT_DEFINE_TT_CMAP(tt_cmap0_class_rec,
sizeof ( TT_CMapRec ),
(FT_CMap_InitFunc) tt_cmap_init,
@@ -176,11 +174,11 @@
(FT_CMap_CharNextFunc) tt_cmap0_char_next,
NULL, NULL, NULL, NULL, NULL
- },
+ ,
0,
(TT_CMap_ValidateFunc) tt_cmap0_validate,
(TT_CMap_Info_GetFunc) tt_cmap0_get_info
- };
+ )
#endif /* TT_CONFIG_CMAP_FORMAT_0 */
@@ -462,7 +460,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
tt_cmap2_char_next( TT_CMap cmap,
FT_UInt32 *pcharcode )
{
@@ -536,17 +534,14 @@
FT_Byte* p = cmap->data + 4;
- cmap_info->format = 2;
+ cmap_info->format = 2;
cmap_info->language = (FT_ULong)TT_PEEK_USHORT( p );
return SFNT_Err_Ok;
}
- FT_CALLBACK_TABLE_DEF
- const TT_CMap_ClassRec tt_cmap2_class_rec =
- {
- {
+ FT_DEFINE_TT_CMAP(tt_cmap2_class_rec,
sizeof ( TT_CMapRec ),
(FT_CMap_InitFunc) tt_cmap_init,
@@ -555,11 +550,11 @@
(FT_CMap_CharNextFunc) tt_cmap2_char_next,
NULL, NULL, NULL, NULL, NULL
- },
+ ,
2,
(TT_CMap_ValidateFunc) tt_cmap2_validate,
(TT_CMap_Info_GetFunc) tt_cmap2_get_info
- };
+ )
#endif /* TT_CONFIG_CMAP_FORMAT_2 */
@@ -664,7 +659,7 @@
p = table + 6;
cmap->num_ranges = FT_PEEK_USHORT( p ) >> 1;
- cmap->cur_charcode = 0xFFFFFFFFUL;
+ cmap->cur_charcode = (FT_UInt32)0xFFFFFFFFUL;
cmap->cur_gindex = 0;
return SFNT_Err_Ok;
@@ -742,7 +737,7 @@
if ( cmap->cur_charcode >= 0xFFFFUL )
goto Fail;
- charcode = cmap->cur_charcode + 1;
+ charcode = (FT_UInt)cmap->cur_charcode + 1;
if ( charcode < cmap->cur_start )
charcode = cmap->cur_start;
@@ -804,7 +799,7 @@
}
Fail:
- cmap->cur_charcode = 0xFFFFFFFFUL;
+ cmap->cur_charcode = (FT_UInt32)0xFFFFFFFFUL;
cmap->cur_gindex = 0;
}
@@ -1093,7 +1088,7 @@
FT_UInt num_segs2, start, end, offset;
FT_Int delta;
FT_UInt max, min, mid, num_segs;
- FT_UInt charcode = *pcharcode;
+ FT_UInt charcode = (FT_UInt)*pcharcode;
FT_UInt gindex = 0;
FT_Byte* p;
@@ -1335,7 +1330,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
tt_cmap4_char_next( TT_CMap cmap,
FT_UInt32 *pchar_code )
{
@@ -1375,17 +1370,14 @@
FT_Byte* p = cmap->data + 4;
- cmap_info->format = 4;
+ cmap_info->format = 4;
cmap_info->language = (FT_ULong)TT_PEEK_USHORT( p );
return SFNT_Err_Ok;
}
- FT_CALLBACK_TABLE_DEF
- const TT_CMap_ClassRec tt_cmap4_class_rec =
- {
- {
+ FT_DEFINE_TT_CMAP(tt_cmap4_class_rec,
sizeof ( TT_CMap4Rec ),
(FT_CMap_InitFunc) tt_cmap4_init,
(FT_CMap_DoneFunc) NULL,
@@ -1393,11 +1385,11 @@
(FT_CMap_CharNextFunc) tt_cmap4_char_next,
NULL, NULL, NULL, NULL, NULL
- },
+ ,
4,
(TT_CMap_ValidateFunc) tt_cmap4_validate,
(TT_CMap_Info_GetFunc) tt_cmap4_get_info
- };
+ )
#endif /* TT_CONFIG_CMAP_FORMAT_4 */
@@ -1489,7 +1481,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
tt_cmap6_char_next( TT_CMap cmap,
FT_UInt32 *pchar_code )
{
@@ -1537,17 +1529,14 @@
FT_Byte* p = cmap->data + 4;
- cmap_info->format = 6;
+ cmap_info->format = 6;
cmap_info->language = (FT_ULong)TT_PEEK_USHORT( p );
return SFNT_Err_Ok;
}
- FT_CALLBACK_TABLE_DEF
- const TT_CMap_ClassRec tt_cmap6_class_rec =
- {
- {
+ FT_DEFINE_TT_CMAP(tt_cmap6_class_rec,
sizeof ( TT_CMapRec ),
(FT_CMap_InitFunc) tt_cmap_init,
@@ -1556,11 +1545,11 @@
(FT_CMap_CharNextFunc) tt_cmap6_char_next,
NULL, NULL, NULL, NULL, NULL
- },
+ ,
6,
(TT_CMap_ValidateFunc) tt_cmap6_validate,
(TT_CMap_Info_GetFunc) tt_cmap6_get_info
- };
+ )
#endif /* TT_CONFIG_CMAP_FORMAT_6 */
@@ -1635,7 +1624,7 @@
FT_INVALID_TOO_SHORT;
length = TT_NEXT_ULONG( p );
- if ( table + length > valid->limit || length < 8208 )
+ if ( length > (FT_UInt32)( valid->limit - table ) || length < 8192 + 16 )
FT_INVALID_TOO_SHORT;
is32 = table + 12;
@@ -1745,7 +1734,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
tt_cmap8_char_next( TT_CMap cmap,
FT_UInt32 *pchar_code )
{
@@ -1793,17 +1782,14 @@
FT_Byte* p = cmap->data + 8;
- cmap_info->format = 8;
+ cmap_info->format = 8;
cmap_info->language = (FT_ULong)TT_PEEK_ULONG( p );
return SFNT_Err_Ok;
}
- FT_CALLBACK_TABLE_DEF
- const TT_CMap_ClassRec tt_cmap8_class_rec =
- {
- {
+ FT_DEFINE_TT_CMAP(tt_cmap8_class_rec,
sizeof ( TT_CMapRec ),
(FT_CMap_InitFunc) tt_cmap_init,
@@ -1812,11 +1798,11 @@
(FT_CMap_CharNextFunc) tt_cmap8_char_next,
NULL, NULL, NULL, NULL, NULL
- },
+ ,
8,
(TT_CMap_ValidateFunc) tt_cmap8_validate,
(TT_CMap_Info_GetFunc) tt_cmap8_get_info
- };
+ )
#endif /* TT_CONFIG_CMAP_FORMAT_8 */
@@ -1863,7 +1849,8 @@
p = table + 16;
count = TT_NEXT_ULONG( p );
- if ( table + length > valid->limit || length < 20 + count * 2 )
+ if ( length > (FT_ULong)( valid->limit - table ) ||
+ length < 20 + count * 2 )
FT_INVALID_TOO_SHORT;
/* check glyph indices */
@@ -1905,7 +1892,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
tt_cmap10_char_next( TT_CMap cmap,
FT_UInt32 *pchar_code )
{
@@ -1944,17 +1931,14 @@
FT_Byte* p = cmap->data + 8;
- cmap_info->format = 10;
+ cmap_info->format = 10;
cmap_info->language = (FT_ULong)TT_PEEK_ULONG( p );
return SFNT_Err_Ok;
}
- FT_CALLBACK_TABLE_DEF
- const TT_CMap_ClassRec tt_cmap10_class_rec =
- {
- {
+ FT_DEFINE_TT_CMAP(tt_cmap10_class_rec,
sizeof ( TT_CMapRec ),
(FT_CMap_InitFunc) tt_cmap_init,
@@ -1963,11 +1947,11 @@
(FT_CMap_CharNextFunc) tt_cmap10_char_next,
NULL, NULL, NULL, NULL, NULL
- },
+ ,
10,
(TT_CMap_ValidateFunc) tt_cmap10_validate,
(TT_CMap_Info_GetFunc) tt_cmap10_get_info
- };
+ )
#endif /* TT_CONFIG_CMAP_FORMAT_10 */
@@ -2048,7 +2032,8 @@
p = table + 12;
num_groups = TT_NEXT_ULONG( p );
- if ( table + length > valid->limit || length < 16 + 12 * num_groups )
+ if ( length > (FT_ULong)( valid->limit - table ) ||
+ length < 16 + 12 * num_groups )
FT_INVALID_TOO_SHORT;
/* check groups, they must be in increasing order */
@@ -2225,7 +2210,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
tt_cmap12_char_next( TT_CMap cmap,
FT_UInt32 *pchar_code )
{
@@ -2243,8 +2228,10 @@
if ( cmap12->valid )
{
gindex = cmap12->cur_gindex;
+
+ /* XXX: check cur_charcode overflow is expected */
if ( gindex )
- *pchar_code = cmap12->cur_charcode;
+ *pchar_code = (FT_UInt32)cmap12->cur_charcode;
}
else
gindex = 0;
@@ -2252,7 +2239,8 @@
else
gindex = tt_cmap12_char_map_binary( cmap, pchar_code, 1 );
- return gindex;
+ /* XXX: check gindex overflow is expected */
+ return (FT_UInt32)gindex;
}
@@ -2263,17 +2251,14 @@
FT_Byte* p = cmap->data + 8;
- cmap_info->format = 12;
+ cmap_info->format = 12;
cmap_info->language = (FT_ULong)TT_PEEK_ULONG( p );
return SFNT_Err_Ok;
}
- FT_CALLBACK_TABLE_DEF
- const TT_CMap_ClassRec tt_cmap12_class_rec =
- {
- {
+ FT_DEFINE_TT_CMAP(tt_cmap12_class_rec,
sizeof ( TT_CMap12Rec ),
(FT_CMap_InitFunc) tt_cmap12_init,
@@ -2282,11 +2267,11 @@
(FT_CMap_CharNextFunc) tt_cmap12_char_next,
NULL, NULL, NULL, NULL, NULL
- },
+ ,
12,
(TT_CMap_ValidateFunc) tt_cmap12_validate,
(TT_CMap_Info_GetFunc) tt_cmap12_get_info
- };
+ )
#endif /* TT_CONFIG_CMAP_FORMAT_12 */
@@ -2294,6 +2279,322 @@
/*************************************************************************/
/*************************************************************************/
/***** *****/
+ /***** FORMAT 13 *****/
+ /***** *****/
+ /*************************************************************************/
+ /*************************************************************************/
+
+ /*************************************************************************/
+ /* */
+ /* TABLE OVERVIEW */
+ /* -------------- */
+ /* */
+ /* NAME OFFSET TYPE DESCRIPTION */
+ /* */
+ /* format 0 USHORT must be 13 */
+ /* reserved 2 USHORT reserved */
+ /* length 4 ULONG length in bytes */
+ /* language 8 ULONG Mac language code */
+ /* count 12 ULONG number of groups */
+ /* 16 */
+ /* */
+ /* This header is followed by `count' groups of the following format: */
+ /* */
+ /* start 0 ULONG first charcode */
+ /* end 4 ULONG last charcode */
+ /* glyphId 8 ULONG glyph ID for the whole group */
+ /* */
+
+#ifdef TT_CONFIG_CMAP_FORMAT_13
+
+ typedef struct TT_CMap13Rec_
+ {
+ TT_CMapRec cmap;
+ FT_Bool valid;
+ FT_ULong cur_charcode;
+ FT_UInt cur_gindex;
+ FT_ULong cur_group;
+ FT_ULong num_groups;
+
+ } TT_CMap13Rec, *TT_CMap13;
+
+
+ FT_CALLBACK_DEF( FT_Error )
+ tt_cmap13_init( TT_CMap13 cmap,
+ FT_Byte* table )
+ {
+ cmap->cmap.data = table;
+
+ table += 12;
+ cmap->num_groups = FT_PEEK_ULONG( table );
+
+ cmap->valid = 0;
+
+ return SFNT_Err_Ok;
+ }
+
+
+ FT_CALLBACK_DEF( FT_Error )
+ tt_cmap13_validate( FT_Byte* table,
+ FT_Validator valid )
+ {
+ FT_Byte* p;
+ FT_ULong length;
+ FT_ULong num_groups;
+
+
+ if ( table + 16 > valid->limit )
+ FT_INVALID_TOO_SHORT;
+
+ p = table + 4;
+ length = TT_NEXT_ULONG( p );
+
+ p = table + 12;
+ num_groups = TT_NEXT_ULONG( p );
+
+ if ( length > (FT_ULong)( valid->limit - table ) ||
+ length < 16 + 12 * num_groups )
+ FT_INVALID_TOO_SHORT;
+
+ /* check groups, they must be in increasing order */
+ {
+ FT_ULong n, start, end, glyph_id, last = 0;
+
+
+ for ( n = 0; n < num_groups; n++ )
+ {
+ start = TT_NEXT_ULONG( p );
+ end = TT_NEXT_ULONG( p );
+ glyph_id = TT_NEXT_ULONG( p );
+
+ if ( start > end )
+ FT_INVALID_DATA;
+
+ if ( n > 0 && start <= last )
+ FT_INVALID_DATA;
+
+ if ( valid->level >= FT_VALIDATE_TIGHT )
+ {
+ if ( glyph_id >= TT_VALID_GLYPH_COUNT( valid ) )
+ FT_INVALID_GLYPH_ID;
+ }
+
+ last = end;
+ }
+ }
+
+ return SFNT_Err_Ok;
+ }
+
+
+ /* search the index of the charcode next to cmap->cur_charcode */
+ /* cmap->cur_group should be set up properly by caller */
+ /* */
+ static void
+ tt_cmap13_next( TT_CMap13 cmap )
+ {
+ FT_Byte* p;
+ FT_ULong start, end, glyph_id, char_code;
+ FT_ULong n;
+ FT_UInt gindex;
+
+
+ if ( cmap->cur_charcode >= 0xFFFFFFFFUL )
+ goto Fail;
+
+ char_code = cmap->cur_charcode + 1;
+
+ n = cmap->cur_group;
+
+ for ( n = cmap->cur_group; n < cmap->num_groups; n++ )
+ {
+ p = cmap->cmap.data + 16 + 12 * n;
+ start = TT_NEXT_ULONG( p );
+ end = TT_NEXT_ULONG( p );
+ glyph_id = TT_PEEK_ULONG( p );
+
+ if ( char_code < start )
+ char_code = start;
+
+ if ( char_code <= end )
+ {
+ gindex = (FT_UInt)glyph_id;
+
+ if ( gindex )
+ {
+ cmap->cur_charcode = char_code;;
+ cmap->cur_gindex = gindex;
+ cmap->cur_group = n;
+
+ return;
+ }
+ }
+ }
+
+ Fail:
+ cmap->valid = 0;
+ }
+
+
+ static FT_UInt
+ tt_cmap13_char_map_binary( TT_CMap cmap,
+ FT_UInt32* pchar_code,
+ FT_Bool next )
+ {
+ FT_UInt gindex = 0;
+ FT_Byte* p = cmap->data + 12;
+ FT_UInt32 num_groups = TT_PEEK_ULONG( p );
+ FT_UInt32 char_code = *pchar_code;
+ FT_UInt32 start, end;
+ FT_UInt32 max, min, mid;
+
+
+ if ( !num_groups )
+ return 0;
+
+ /* make compiler happy */
+ mid = num_groups;
+ end = 0xFFFFFFFFUL;
+
+ if ( next )
+ char_code++;
+
+ min = 0;
+ max = num_groups;
+
+ /* binary search */
+ while ( min < max )
+ {
+ mid = ( min + max ) >> 1;
+ p = cmap->data + 16 + 12 * mid;
+
+ start = TT_NEXT_ULONG( p );
+ end = TT_NEXT_ULONG( p );
+
+ if ( char_code < start )
+ max = mid;
+ else if ( char_code > end )
+ min = mid + 1;
+ else
+ {
+ gindex = (FT_UInt)TT_PEEK_ULONG( p );
+
+ break;
+ }
+ }
+
+ if ( next )
+ {
+ TT_CMap13 cmap13 = (TT_CMap13)cmap;
+
+
+ /* if `char_code' is not in any group, then `mid' is */
+ /* the group nearest to `char_code' */
+ /* */
+
+ if ( char_code > end )
+ {
+ mid++;
+ if ( mid == num_groups )
+ return 0;
+ }
+
+ cmap13->valid = 1;
+ cmap13->cur_charcode = char_code;
+ cmap13->cur_group = mid;
+
+ if ( !gindex )
+ {
+ tt_cmap13_next( cmap13 );
+
+ if ( cmap13->valid )
+ gindex = cmap13->cur_gindex;
+ }
+ else
+ cmap13->cur_gindex = gindex;
+
+ if ( gindex )
+ *pchar_code = cmap13->cur_charcode;
+ }
+
+ return gindex;
+ }
+
+
+ FT_CALLBACK_DEF( FT_UInt )
+ tt_cmap13_char_index( TT_CMap cmap,
+ FT_UInt32 char_code )
+ {
+ return tt_cmap13_char_map_binary( cmap, &char_code, 0 );
+ }
+
+
+ FT_CALLBACK_DEF( FT_UInt32 )
+ tt_cmap13_char_next( TT_CMap cmap,
+ FT_UInt32 *pchar_code )
+ {
+ TT_CMap13 cmap13 = (TT_CMap13)cmap;
+ FT_UInt gindex;
+
+
+ if ( cmap13->cur_charcode >= 0xFFFFFFFFUL )
+ return 0;
+
+ /* no need to search */
+ if ( cmap13->valid && cmap13->cur_charcode == *pchar_code )
+ {
+ tt_cmap13_next( cmap13 );
+ if ( cmap13->valid )
+ {
+ gindex = cmap13->cur_gindex;
+ if ( gindex )
+ *pchar_code = cmap13->cur_charcode;
+ }
+ else
+ gindex = 0;
+ }
+ else
+ gindex = tt_cmap13_char_map_binary( cmap, pchar_code, 1 );
+
+ return gindex;
+ }
+
+
+ FT_CALLBACK_DEF( FT_Error )
+ tt_cmap13_get_info( TT_CMap cmap,
+ TT_CMapInfo *cmap_info )
+ {
+ FT_Byte* p = cmap->data + 8;
+
+
+ cmap_info->format = 13;
+ cmap_info->language = (FT_ULong)TT_PEEK_ULONG( p );
+
+ return SFNT_Err_Ok;
+ }
+
+
+ FT_DEFINE_TT_CMAP(tt_cmap13_class_rec,
+ sizeof ( TT_CMap13Rec ),
+
+ (FT_CMap_InitFunc) tt_cmap13_init,
+ (FT_CMap_DoneFunc) NULL,
+ (FT_CMap_CharIndexFunc)tt_cmap13_char_index,
+ (FT_CMap_CharNextFunc) tt_cmap13_char_next,
+
+ NULL, NULL, NULL, NULL, NULL
+ ,
+ 13,
+ (TT_CMap_ValidateFunc) tt_cmap13_validate,
+ (TT_CMap_Info_GetFunc) tt_cmap13_get_info
+ )
+
+#endif /* TT_CONFIG_CMAP_FORMAT_13 */
+
+
+ /*************************************************************************/
+ /*************************************************************************/
+ /***** *****/
/***** FORMAT 14 *****/
/***** *****/
/*************************************************************************/
@@ -2363,7 +2664,7 @@
* cmap 14 query functions. The data is overwritten
* on each call to these functions.
*/
- FT_UInt max_results;
+ FT_UInt32 max_results;
FT_UInt32* results;
FT_Memory memory;
@@ -2384,10 +2685,10 @@
static FT_Error
tt_cmap14_ensure( TT_CMap14 cmap,
- FT_UInt num_results,
+ FT_UInt32 num_results,
FT_Memory memory )
{
- FT_UInt old_max = cmap->max_results;
+ FT_UInt32 old_max = cmap->max_results;
FT_Error error = 0;
@@ -2429,7 +2730,8 @@
FT_ULong num_selectors = TT_NEXT_ULONG( p );
- if ( table + length > valid->limit || length < 10 + 11 * num_selectors )
+ if ( length > (FT_ULong)( valid->limit - table ) ||
+ length < 10 + 11 * num_selectors )
FT_INVALID_TOO_SHORT;
/* check selectors, they must be in increasing order */
@@ -2491,7 +2793,7 @@
FT_ULong i, lastUni = 0;
- if ( ndp + numMappings * 4 > valid->limit )
+ if ( numMappings * 4 > (FT_ULong)( valid->limit - ndp ) )
FT_INVALID_TOO_SHORT;
for ( i = 0; i < numMappings; ++i )
@@ -2532,7 +2834,7 @@
}
- FT_CALLBACK_DEF( FT_UInt )
+ FT_CALLBACK_DEF( FT_UInt32 )
tt_cmap14_char_next( TT_CMap cmap,
FT_UInt32 *pchar_code )
{
@@ -2550,7 +2852,7 @@
{
FT_UNUSED( cmap );
- cmap_info->format = 14;
+ cmap_info->format = 14;
/* subtable 14 does not define a language field */
cmap_info->language = 0xFFFFFFFFUL;
@@ -2610,7 +2912,7 @@
{
FT_UInt32 mid = ( min + max ) >> 1;
FT_Byte* p = base + 5 * mid;
- FT_UInt32 uni = TT_NEXT_UINT24( p );
+ FT_UInt32 uni = (FT_UInt32)TT_NEXT_UINT24( p );
if ( char_code < uni )
@@ -2659,10 +2961,10 @@
FT_CALLBACK_DEF( FT_UInt )
- tt_cmap14_char_var_index( TT_CMap cmap,
- TT_CMap ucmap,
- FT_ULong charcode,
- FT_ULong variantSelector)
+ tt_cmap14_char_var_index( TT_CMap cmap,
+ TT_CMap ucmap,
+ FT_UInt32 charcode,
+ FT_UInt32 variantSelector)
{
FT_Byte* p = tt_cmap14_find_variant( cmap->data + 6, variantSelector );
FT_ULong defOff;
@@ -2692,9 +2994,9 @@
FT_CALLBACK_DEF( FT_Int )
- tt_cmap14_char_var_isdefault( TT_CMap cmap,
- FT_ULong charcode,
- FT_ULong variantSelector )
+ tt_cmap14_char_var_isdefault( TT_CMap cmap,
+ FT_UInt32 charcode,
+ FT_UInt32 variantSelector )
{
FT_Byte* p = tt_cmap14_find_variant( cmap->data + 6, variantSelector );
FT_ULong defOff;
@@ -2725,10 +3027,10 @@
FT_Memory memory )
{
TT_CMap14 cmap14 = (TT_CMap14)cmap;
- FT_UInt count = cmap14->num_selectors;
+ FT_UInt32 count = cmap14->num_selectors;
FT_Byte* p = cmap->data + 10;
FT_UInt32* result;
- FT_UInt i;
+ FT_UInt32 i;
if ( tt_cmap14_ensure( cmap14, ( count + 1 ), memory ) )
@@ -2737,7 +3039,7 @@
result = cmap14->results;
for ( i = 0; i < count; ++i )
{
- result[i] = TT_NEXT_UINT24( p );
+ result[i] = (FT_UInt32)TT_NEXT_UINT24( p );
p += 8;
}
result[i] = 0;
@@ -2749,10 +3051,10 @@
FT_CALLBACK_DEF( FT_UInt32 * )
tt_cmap14_char_variants( TT_CMap cmap,
FT_Memory memory,
- FT_ULong charCode )
+ FT_UInt32 charCode )
{
TT_CMap14 cmap14 = (TT_CMap14) cmap;
- FT_UInt count = cmap14->num_selectors;
+ FT_UInt32 count = cmap14->num_selectors;
FT_Byte* p = cmap->data + 10;
FT_UInt32* q;
@@ -2787,7 +3089,7 @@
static FT_UInt
tt_cmap14_def_char_count( FT_Byte *p )
{
- FT_UInt32 numRanges = TT_NEXT_ULONG( p );
+ FT_UInt32 numRanges = (FT_UInt32)TT_NEXT_ULONG( p );
FT_UInt tot = 0;
@@ -2814,14 +3116,14 @@
cnt = tt_cmap14_def_char_count( p );
- numRanges = TT_NEXT_ULONG( p );
+ numRanges = (FT_UInt32)TT_NEXT_ULONG( p );
if ( tt_cmap14_ensure( cmap14, ( cnt + 1 ), memory ) )
return NULL;
for ( q = cmap14->results; numRanges > 0; --numRanges )
{
- FT_UInt uni = TT_NEXT_UINT24( p );
+ FT_UInt32 uni = (FT_UInt32)TT_NEXT_UINT24( p );
cnt = FT_NEXT_BYTE( p ) + 1;
@@ -2849,7 +3151,7 @@
FT_UInt32 *ret;
- numMappings = TT_NEXT_ULONG( p );
+ numMappings = (FT_UInt32)TT_NEXT_ULONG( p );
if ( tt_cmap14_ensure( cmap14, ( numMappings + 1 ), memory ) )
return NULL;
@@ -2857,7 +3159,7 @@
ret = cmap14->results;
for ( i = 0; i < numMappings; ++i )
{
- ret[i] = TT_NEXT_UINT24( p );
+ ret[i] = (FT_UInt32)TT_NEXT_UINT24( p );
p += 2;
}
ret[i] = 0;
@@ -2869,7 +3171,7 @@
FT_CALLBACK_DEF( FT_UInt32 * )
tt_cmap14_variant_chars( TT_CMap cmap,
FT_Memory memory,
- FT_ULong variantSelector )
+ FT_UInt32 variantSelector )
{
FT_Byte *p = tt_cmap14_find_variant( cmap->data + 6,
variantSelector );
@@ -2911,9 +3213,9 @@
p = cmap->data + nondefOff;
dp = cmap->data + defOff;
- numMappings = TT_NEXT_ULONG( p );
+ numMappings = (FT_UInt32)TT_NEXT_ULONG( p );
dcnt = tt_cmap14_def_char_count( dp );
- numRanges = TT_NEXT_ULONG( dp );
+ numRanges = (FT_UInt32)TT_NEXT_ULONG( dp );
if ( numMappings == 0 )
return tt_cmap14_get_def_chars( cmap, cmap->data + defOff,
@@ -2926,10 +3228,10 @@
return NULL;
ret = cmap14->results;
- duni = TT_NEXT_UINT24( dp );
+ duni = (FT_UInt32)TT_NEXT_UINT24( dp );
dcnt = FT_NEXT_BYTE( dp );
di = 1;
- nuni = TT_NEXT_UINT24( p );
+ nuni = (FT_UInt32)TT_NEXT_UINT24( p );
p += 2;
ni = 1;
i = 0;
@@ -2946,7 +3248,7 @@
if ( di > numRanges )
break;
- duni = TT_NEXT_UINT24( dp );
+ duni = (FT_UInt32)TT_NEXT_UINT24( dp );
dcnt = FT_NEXT_BYTE( dp );
}
else
@@ -2959,7 +3261,7 @@
if ( ni > numMappings )
break;
- nuni = TT_NEXT_UINT24( p );
+ nuni = (FT_UInt32)TT_NEXT_UINT24( p );
p += 2;
}
}
@@ -2972,7 +3274,7 @@
ret[i++] = nuni;
while ( ni < numMappings )
{
- ret[i++] = TT_NEXT_UINT24( p );
+ ret[i++] = (FT_UInt32)TT_NEXT_UINT24( p );
p += 2;
++ni;
}
@@ -2987,7 +3289,7 @@
while ( di < numRanges )
{
- duni = TT_NEXT_UINT24( dp );
+ duni = (FT_UInt32)TT_NEXT_UINT24( dp );
dcnt = FT_NEXT_BYTE( dp );
for ( k = 0; k <= dcnt; ++k )
@@ -3003,10 +3305,7 @@
}
- FT_CALLBACK_TABLE_DEF
- const TT_CMap_ClassRec tt_cmap14_class_rec =
- {
- {
+ FT_DEFINE_TT_CMAP(tt_cmap14_class_rec,
sizeof ( TT_CMap14Rec ),
(FT_CMap_InitFunc) tt_cmap14_init,
@@ -3020,51 +3319,66 @@
(FT_CMap_VariantListFunc) tt_cmap14_variants,
(FT_CMap_CharVariantListFunc) tt_cmap14_char_variants,
(FT_CMap_VariantCharListFunc) tt_cmap14_variant_chars
- },
+ ,
14,
(TT_CMap_ValidateFunc)tt_cmap14_validate,
(TT_CMap_Info_GetFunc)tt_cmap14_get_info
- };
+ )
#endif /* TT_CONFIG_CMAP_FORMAT_14 */
+#ifndef FT_CONFIG_OPTION_PIC
+
static const TT_CMap_Class tt_cmap_classes[] =
{
-#ifdef TT_CONFIG_CMAP_FORMAT_0
- &tt_cmap0_class_rec,
-#endif
+#define TTCMAPCITEM(a) &a,
+#include "ttcmapc.h"
+ NULL,
+ };
-#ifdef TT_CONFIG_CMAP_FORMAT_2
- &tt_cmap2_class_rec,
-#endif
+#else /*FT_CONFIG_OPTION_PIC*/
-#ifdef TT_CONFIG_CMAP_FORMAT_4
- &tt_cmap4_class_rec,
-#endif
+ void FT_Destroy_Class_tt_cmap_classes(FT_Library library, TT_CMap_Class* clazz)
+ {
+ FT_Memory memory = library->memory;
+ if ( clazz )
+ FT_FREE( clazz );
+ }
-#ifdef TT_CONFIG_CMAP_FORMAT_6
- &tt_cmap6_class_rec,
-#endif
+ FT_Error FT_Create_Class_tt_cmap_classes(FT_Library library, TT_CMap_Class** output_class)
+ {
+ TT_CMap_Class* clazz;
+ TT_CMap_ClassRec* recs;
+ FT_Error error;
+ FT_Memory memory = library->memory;
+ int i = 0;
-#ifdef TT_CONFIG_CMAP_FORMAT_8
- &tt_cmap8_class_rec,
-#endif
+#define TTCMAPCITEM(a) i++;
+#include "ttcmapc.h"
-#ifdef TT_CONFIG_CMAP_FORMAT_10
- &tt_cmap10_class_rec,
-#endif
+ /* allocate enough space for both the pointers +terminator and the class instances */
+ if ( FT_ALLOC( clazz, sizeof(*clazz)*(i+1)+sizeof(TT_CMap_ClassRec)*i ) )
+ return error;
-#ifdef TT_CONFIG_CMAP_FORMAT_12
- &tt_cmap12_class_rec,
-#endif
+ /* the location of the class instances follows the array of pointers */
+ recs = (TT_CMap_ClassRec*) (((char*)clazz)+(sizeof(*clazz)*(i+1)));
+ i=0;
-#ifdef TT_CONFIG_CMAP_FORMAT_14
- &tt_cmap14_class_rec,
-#endif
+#undef TTCMAPCITEM
+#define TTCMAPCITEM(a) \
+ FT_Init_Class_##a(&recs[i]); \
+ clazz[i] = &recs[i]; \
+ i++;
+#include "ttcmapc.h"
- NULL,
- };
+ clazz[i] = NULL;
+
+ *output_class = clazz;
+ return FT_Err_Ok;
+ }
+
+#endif /*FT_CONFIG_OPTION_PIC*/
/* parse the `cmap' table and build the corresponding TT_CMap objects */
@@ -3077,6 +3391,8 @@
FT_Byte* limit = table + face->cmap_size;
FT_UInt volatile num_cmaps;
FT_Byte* volatile p = table;
+ FT_Library library = FT_FACE_LIBRARY(face);
+ FT_UNUSED(library);
if ( p + 4 > limit )
@@ -3086,7 +3402,8 @@
if ( TT_NEXT_USHORT( p ) != 0 )
{
p -= 2;
- FT_ERROR(( "tt_face_build_cmaps: unsupported `cmap' table format = %d\n",
+ FT_ERROR(( "tt_face_build_cmaps:"
+ " unsupported `cmap' table format = %d\n",
TT_PEEK_USHORT( p ) ));
return SFNT_Err_Invalid_Table;
}
@@ -3109,7 +3426,7 @@
{
FT_Byte* volatile cmap = table + offset;
volatile FT_UInt format = TT_PEEK_USHORT( cmap );
- const TT_CMap_Class* volatile pclazz = tt_cmap_classes;
+ const TT_CMap_Class* volatile pclazz = FT_TT_CMAP_CLASSES_GET;
TT_CMap_Class volatile clazz;
@@ -3153,8 +3470,8 @@
}
else
{
- FT_ERROR(( "tt_face_build_cmaps:" ));
- FT_ERROR(( " broken cmap sub-table ignored!\n" ));
+ FT_TRACE0(( "tt_face_build_cmaps:"
+ " broken cmap sub-table ignored\n" ));
}
break;
}
@@ -3162,8 +3479,8 @@
if ( *pclazz == NULL )
{
- FT_ERROR(( "tt_face_build_cmaps:" ));
- FT_ERROR(( " unsupported cmap sub-table ignored!\n" ));
+ FT_TRACE0(( "tt_face_build_cmaps:"
+ " unsupported cmap sub-table ignored\n" ));
}
}
}
diff --git a/src/3rdparty/freetype/src/sfnt/ttcmap.h b/src/3rdparty/freetype/src/sfnt/ttcmap.h
index a10a3e2502..15a4a21e50 100644
--- a/src/3rdparty/freetype/src/sfnt/ttcmap.h
+++ b/src/3rdparty/freetype/src/sfnt/ttcmap.h
@@ -55,6 +55,46 @@ FT_BEGIN_HEADER
} TT_CMap_ClassRec;
+#ifndef FT_CONFIG_OPTION_PIC
+
+#define FT_DEFINE_TT_CMAP(class_, size_, init_, done_, char_index_, \
+ char_next_, char_var_index_, char_var_default_, variant_list_, \
+ charvariant_list_,variantchar_list_, \
+ format_, validate_, get_cmap_info_) \
+ FT_CALLBACK_TABLE_DEF \
+ const TT_CMap_ClassRec class_ = \
+ { \
+ {size_, init_, done_, char_index_, \
+ char_next_, char_var_index_, char_var_default_, variant_list_, \
+ charvariant_list_, variantchar_list_}, \
+ format_, validate_, get_cmap_info_ \
+ };
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#define FT_DEFINE_TT_CMAP(class_, size_, init_, done_, char_index_, \
+ char_next_, char_var_index_, char_var_default_, variant_list_, \
+ charvariant_list_,variantchar_list_, \
+ format_, validate_, get_cmap_info_) \
+ void \
+ FT_Init_Class_##class_( TT_CMap_ClassRec* clazz ) \
+ { \
+ clazz->clazz.size = size_; \
+ clazz->clazz.init = init_; \
+ clazz->clazz.done = done_; \
+ clazz->clazz.char_index = char_index_; \
+ clazz->clazz.char_next = char_next_; \
+ clazz->clazz.char_var_index = char_var_index_; \
+ clazz->clazz.char_var_default = char_var_default_; \
+ clazz->clazz.variant_list = variant_list_; \
+ clazz->clazz.charvariant_list = charvariant_list_; \
+ clazz->clazz.variantchar_list = variantchar_list_; \
+ clazz->format = format_; \
+ clazz->validate = validate_; \
+ clazz->get_cmap_info = get_cmap_info_; \
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
typedef struct TT_ValidatorRec_
{
diff --git a/src/3rdparty/freetype/src/sfnt/ttcmapc.h b/src/3rdparty/freetype/src/sfnt/ttcmapc.h
new file mode 100644
index 0000000000..4c9c6a56f7
--- /dev/null
+++ b/src/3rdparty/freetype/src/sfnt/ttcmapc.h
@@ -0,0 +1,55 @@
+/***************************************************************************/
+/* */
+/* ttcmapc.h */
+/* */
+/* TT CMAP classes definitions (specification only). */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifdef TT_CONFIG_CMAP_FORMAT_0
+ TTCMAPCITEM(tt_cmap0_class_rec)
+#endif
+
+#ifdef TT_CONFIG_CMAP_FORMAT_2
+ TTCMAPCITEM(tt_cmap2_class_rec)
+#endif
+
+#ifdef TT_CONFIG_CMAP_FORMAT_4
+ TTCMAPCITEM(tt_cmap4_class_rec)
+#endif
+
+#ifdef TT_CONFIG_CMAP_FORMAT_6
+ TTCMAPCITEM(tt_cmap6_class_rec)
+#endif
+
+#ifdef TT_CONFIG_CMAP_FORMAT_8
+ TTCMAPCITEM(tt_cmap8_class_rec)
+#endif
+
+#ifdef TT_CONFIG_CMAP_FORMAT_10
+ TTCMAPCITEM(tt_cmap10_class_rec)
+#endif
+
+#ifdef TT_CONFIG_CMAP_FORMAT_12
+ TTCMAPCITEM(tt_cmap12_class_rec)
+#endif
+
+#ifdef TT_CONFIG_CMAP_FORMAT_13
+ TTCMAPCITEM(tt_cmap13_class_rec)
+#endif
+
+#ifdef TT_CONFIG_CMAP_FORMAT_14
+ TTCMAPCITEM(tt_cmap14_class_rec)
+#endif
+
+ /* END */
diff --git a/src/3rdparty/freetype/src/sfnt/ttkern.c b/src/3rdparty/freetype/src/sfnt/ttkern.c
index 67d5115e87..c1540802b8 100644
--- a/src/3rdparty/freetype/src/sfnt/ttkern.c
+++ b/src/3rdparty/freetype/src/sfnt/ttkern.c
@@ -22,7 +22,6 @@
#include FT_INTERNAL_STREAM_H
#include FT_TRUETYPE_TAGS_H
#include "ttkern.h"
-#include "ttload.h"
#include "sferrors.h"
@@ -60,14 +59,16 @@
if ( table_size < 4 ) /* the case of a malformed table */
{
- FT_ERROR(( "kerning table is too small - ignored\n" ));
+ FT_ERROR(( "tt_face_load_kern:"
+ " kerning table is too small - ignored\n" ));
error = SFNT_Err_Table_Missing;
goto Exit;
}
if ( FT_FRAME_EXTRACT( table_size, face->kern_table ) )
{
- FT_ERROR(( "could not extract kerning table\n" ));
+ FT_ERROR(( "tt_face_load_kern:"
+ " could not extract kerning table\n" ));
goto Exit;
}
@@ -86,7 +87,7 @@
{
FT_UInt num_pairs, length, coverage;
FT_Byte* p_next;
- FT_UInt32 mask = 1UL << nn;
+ FT_UInt32 mask = (FT_UInt32)1UL << nn;
if ( p + 6 > p_limit )
@@ -125,8 +126,8 @@
*/
if ( num_pairs > 0 )
{
- FT_UInt count;
- FT_UInt old_pair;
+ FT_ULong count;
+ FT_ULong old_pair;
old_pair = FT_NEXT_ULONG( p );
diff --git a/src/3rdparty/freetype/src/sfnt/ttload.c b/src/3rdparty/freetype/src/sfnt/ttload.c
index c45a1ed556..3ad33bd6d8 100644
--- a/src/3rdparty/freetype/src/sfnt/ttload.c
+++ b/src/3rdparty/freetype/src/sfnt/ttload.c
@@ -5,7 +5,7 @@
/* Load the basic TrueType tables, i.e., tables that can be either in */
/* TTF or OTF fonts (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -91,9 +91,9 @@
#ifdef FT_DEBUG_LEVEL_TRACE
if ( zero_length )
- FT_TRACE4(( "ignoring empty table!\n" ));
+ FT_TRACE4(( "ignoring empty table\n" ));
else
- FT_TRACE4(( "could not find table!\n" ));
+ FT_TRACE4(( "could not find table\n" ));
#endif
return NULL;
@@ -168,10 +168,10 @@
check_table_dir( SFNT_Header sfnt,
FT_Stream stream )
{
- FT_Error error;
- FT_UInt nn, valid_entries = 0;
- FT_UInt has_head = 0, has_sing = 0, has_meta = 0;
- FT_ULong offset = sfnt->offset + 12;
+ FT_Error error;
+ FT_UShort nn, valid_entries = 0;
+ FT_UInt has_head = 0, has_sing = 0, has_meta = 0;
+ FT_ULong offset = sfnt->offset + 12;
static const FT_Frame_Field table_dir_entry_fields[] =
{
@@ -364,7 +364,8 @@
error = check_table_dir( &sfnt, stream );
if ( error )
{
- FT_TRACE2(( "tt_face_load_font_dir: invalid table directory for TrueType!\n" ));
+ FT_TRACE2(( "tt_face_load_font_dir:"
+ " invalid table directory for TrueType\n" ));
goto Exit;
}
@@ -685,8 +686,10 @@
/* we add 4 phantom points later */
if ( maxProfile->maxTwilightPoints > ( 0xFFFFU - 4 ) )
{
- FT_ERROR(( "Too much twilight points in `maxp' table;\n" ));
- FT_ERROR(( " some glyphs might be rendered incorrectly.\n" ));
+ FT_TRACE0(( "tt_face_load_maxp:"
+ " too much twilight points in `maxp' table;\n"
+ " "
+ " some glyphs might be rendered incorrectly\n" ));
maxProfile->maxTwilightPoints = 0xFFFFU - 4;
}
@@ -779,7 +782,7 @@
if ( storage_start > storage_limit )
{
- FT_ERROR(( "invalid `name' table\n" ));
+ FT_ERROR(( "tt_face_load_name: invalid `name' table\n" ));
error = SFNT_Err_Name_Table_Missing;
goto Exit;
}
diff --git a/src/3rdparty/freetype/src/sfnt/ttmtx.c b/src/3rdparty/freetype/src/sfnt/ttmtx.c
index 2a7d22c072..53e6ac7881 100644
--- a/src/3rdparty/freetype/src/sfnt/ttmtx.c
+++ b/src/3rdparty/freetype/src/sfnt/ttmtx.c
@@ -4,7 +4,7 @@
/* */
/* Load the metrics tables common to TTF and OTF fonts (body). */
/* */
-/* Copyright 2006, 2007, 2008 by */
+/* Copyright 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -161,7 +161,9 @@
if ( num_shorts < 0 )
{
- FT_ERROR(( "%cmtx has more metrics than glyphs.\n" ));
+ FT_TRACE0(( "tt_face_load_hmtx:"
+ " %cmtx has more metrics than glyphs.\n",
+ vertical ? "v" : "h" ));
/* Adobe simply ignores this problem. So we shall do the same. */
#if 0
diff --git a/src/3rdparty/freetype/src/sfnt/ttpost.c b/src/3rdparty/freetype/src/sfnt/ttpost.c
index ce628e210d..aa0bf1ec41 100644
--- a/src/3rdparty/freetype/src/sfnt/ttpost.c
+++ b/src/3rdparty/freetype/src/sfnt/ttpost.c
@@ -5,7 +5,7 @@
/* Postcript name table processing for TrueType and OpenType fonts */
/* (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -29,7 +29,6 @@
#include FT_INTERNAL_STREAM_H
#include FT_TRUETYPE_TAGS_H
#include "ttpost.h"
-#include "ttload.h"
#include "sferrors.h"
diff --git a/src/3rdparty/freetype/src/sfnt/ttsbit.c b/src/3rdparty/freetype/src/sfnt/ttsbit.c
index eadaade71e..833bb2add2 100644
--- a/src/3rdparty/freetype/src/sfnt/ttsbit.c
+++ b/src/3rdparty/freetype/src/sfnt/ttsbit.c
@@ -494,7 +494,7 @@
if ( version != 0x00020000L ||
num_strikes >= 0x10000L )
{
- FT_ERROR(( "tt_face_load_sbit_strikes: invalid table version!\n" ));
+ FT_ERROR(( "tt_face_load_sbit_strikes: invalid table version\n" ));
error = SFNT_Err_Invalid_File_Format;
goto Exit;
diff --git a/src/3rdparty/freetype/src/sfnt/ttsbit0.c b/src/3rdparty/freetype/src/sfnt/ttsbit0.c
index 3ebcbbd740..38bcf210ea 100644
--- a/src/3rdparty/freetype/src/sfnt/ttsbit0.c
+++ b/src/3rdparty/freetype/src/sfnt/ttsbit0.c
@@ -62,7 +62,7 @@
if ( table_size < 8 )
{
- FT_ERROR(( "tt_face_load_sbit_strikes: table too short!\n" ));
+ FT_ERROR(( "tt_face_load_sbit_strikes: table too short\n" ));
error = SFNT_Err_Invalid_File_Format;
goto Exit;
}
@@ -80,7 +80,7 @@
if ( version != 0x00020000UL || num_strikes >= 0x10000UL )
{
- FT_ERROR(( "tt_face_load_sbit_strikes: invalid table version!\n" ));
+ FT_ERROR(( "tt_face_load_sbit_strikes: invalid table version\n" ));
error = SFNT_Err_Invalid_File_Format;
goto Fail;
}
@@ -469,6 +469,41 @@
}
+ /*
+ * Load a bit-aligned bitmap (with pointer `p') into a line-aligned bitmap
+ * (with pointer `write'). In the example below, the width is 3 pixel,
+ * and `x_pos' is 1 pixel.
+ *
+ * p p+1
+ * | | |
+ * | 7 6 5 4 3 2 1 0 | 7 6 5 4 3 2 1 0 |...
+ * | | |
+ * +-------+ +-------+ +-------+ ...
+ * . . .
+ * . . .
+ * v . .
+ * +-------+ . .
+ * | | .
+ * | 7 6 5 4 3 2 1 0 | .
+ * | | .
+ * write . .
+ * . .
+ * v .
+ * +-------+ .
+ * | |
+ * | 7 6 5 4 3 2 1 0 |
+ * | |
+ * write+1 .
+ * .
+ * v
+ * +-------+
+ * | |
+ * | 7 6 5 4 3 2 1 0 |
+ * | |
+ * write+2
+ *
+ */
+
static FT_Error
tt_sbit_decoder_load_bit_aligned( TT_SBitDecoder decoder,
FT_Byte* p,
@@ -514,6 +549,8 @@
}
/* now do the blit */
+
+ /* adjust `line' to point to the first byte of the bitmap */
line += y_pos * pitch + ( x_pos >> 3 );
x_pos &= 7;
@@ -524,21 +561,23 @@
for ( h = height; h > 0; h--, line += pitch )
{
FT_Byte* write = line;
- FT_Int w = width;
+ FT_Int w = width;
+ /* handle initial byte (in target bitmap) specially if necessary */
if ( x_pos )
{
w = ( width < 8 - x_pos ) ? width : 8 - x_pos;
if ( h == height )
{
- rval |= *p++;
- nbits += x_pos;
+ rval = *p++;
+ nbits = x_pos;
}
else if ( nbits < w )
{
- rval |= *p++;
+ if ( p < limit )
+ rval |= *p++;
nbits += 8 - w;
}
else
@@ -554,6 +593,7 @@
w = width - w;
}
+ /* handle medial bytes */
for ( ; w >= 8; w -= 8 )
{
rval |= *p++;
@@ -562,11 +602,13 @@
rval <<= 8;
}
+ /* handle final byte if necessary */
if ( w > 0 )
{
if ( nbits < w )
{
- rval |= *p++;
+ if ( p < limit )
+ rval |= *p++;
*write |= ( ( rval >> nbits ) & 0xFF ) & ( 0xFF00U >> w );
nbits += 8 - w;
diff --git a/src/3rdparty/freetype/src/smooth/Jamfile b/src/3rdparty/freetype/src/smooth/Jamfile
index 8a792df056..a8496aa2c2 100644
--- a/src/3rdparty/freetype/src/smooth/Jamfile
+++ b/src/3rdparty/freetype/src/smooth/Jamfile
@@ -16,7 +16,7 @@ SubDir FT2_TOP $(FT2_SRC_DIR) smooth ;
if $(FT2_MULTI)
{
- _sources = ftgrays ftsmooth ;
+ _sources = ftgrays ftsmooth ftspic ;
}
else
{
diff --git a/src/3rdparty/freetype/src/smooth/ftgrays.c b/src/3rdparty/freetype/src/smooth/ftgrays.c
index 10fa2ae727..846e454e66 100644
--- a/src/3rdparty/freetype/src/smooth/ftgrays.c
+++ b/src/3rdparty/freetype/src/smooth/ftgrays.c
@@ -4,7 +4,7 @@
/* */
/* A new `perfect' anti-aliasing renderer (body). */
/* */
-/* Copyright 2000-2001, 2002, 2003, 2005, 2006, 2007, 2008 by */
+/* Copyright 2000-2001, 2002, 2003, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -170,6 +170,34 @@
#endif /* !FT_DEBUG_LEVEL_TRACE */
+#define FT_DEFINE_OUTLINE_FUNCS( class_, \
+ move_to_, line_to_, \
+ conic_to_, cubic_to_, \
+ shift_, delta_ ) \
+ static const FT_Outline_Funcs class_ = \
+ { \
+ move_to_, \
+ line_to_, \
+ conic_to_, \
+ cubic_to_, \
+ shift_, \
+ delta_ \
+ };
+
+#define FT_DEFINE_RASTER_FUNCS( class_, glyph_format_, \
+ raster_new_, raster_reset_, \
+ raster_set_mode_, raster_render_, \
+ raster_done_ ) \
+ const FT_Raster_Funcs class_ = \
+ { \
+ glyph_format_, \
+ raster_new_, \
+ raster_reset_, \
+ raster_set_mode_, \
+ raster_render_, \
+ raster_done_ \
+ };
+
#else /* !_STANDALONE_ */
@@ -181,6 +209,8 @@
#include "ftsmerrs.h"
+#include "ftspic.h"
+
#define ErrRaster_Invalid_Mode Smooth_Err_Cannot_Render_Glyph
#define ErrRaster_Invalid_Outline Smooth_Err_Invalid_Outline
#define ErrRaster_Memory_Overflow Smooth_Err_Out_Of_Memory
@@ -188,7 +218,6 @@
#endif /* !_STANDALONE_ */
-
#ifndef FT_MEM_SET
#define FT_MEM_SET( d, s, c ) ft_memset( d, s, c )
#endif
@@ -201,27 +230,19 @@
#ifndef FT_STATIC_RASTER
-
#define RAS_ARG PWorker worker
#define RAS_ARG_ PWorker worker,
#define RAS_VAR worker
#define RAS_VAR_ worker,
-#define ras (*worker)
-
-
#else /* FT_STATIC_RASTER */
-
#define RAS_ARG /* empty */
#define RAS_ARG_ /* empty */
#define RAS_VAR /* empty */
#define RAS_VAR_ /* empty */
- static TWorker ras;
-
-
#endif /* FT_STATIC_RASTER */
@@ -254,7 +275,7 @@
/* need to define them to "float" or "double" when experimenting with */
/* new algorithms */
- typedef int TCoord; /* integer scanline/pixel coordinate */
+ typedef long TCoord; /* integer scanline/pixel coordinate */
typedef long TPos; /* sub-pixel coordinate */
/* determine the type used to store cell areas. This normally takes at */
@@ -285,8 +306,8 @@
typedef struct TCell_
{
- int x;
- int cover;
+ TPos x; /* same with TWorker.ex */
+ TCoord cover; /* same with TWorker.cover */
TArea area;
PCell next;
@@ -301,12 +322,12 @@
TPos count_ex, count_ey;
TArea area;
- int cover;
+ TCoord cover;
int invalid;
PCell cells;
- int max_cells;
- int num_cells;
+ FT_PtrDist max_cells;
+ FT_PtrDist num_cells;
TCoord cx, cy;
TPos x, y;
@@ -338,11 +359,18 @@
long buffer_size;
PCell* ycells;
- int ycount;
+ TPos ycount;
} TWorker, *PWorker;
+#ifndef FT_STATIC_RASTER
+#define ras (*worker)
+#else
+ static TWorker ras;
+#endif
+
+
typedef struct TRaster_
{
void* buffer;
@@ -428,7 +456,7 @@
gray_find_cell( RAS_ARG )
{
PCell *pcell, cell;
- int x = ras.ex;
+ TPos x = ras.ex;
if ( x > ras.count_ex )
@@ -560,9 +588,9 @@
TPos x2,
TCoord y2 )
{
- TCoord ex1, ex2, fx1, fx2, delta;
+ TCoord ex1, ex2, fx1, fx2, delta, mod, lift, rem;
long p, first, dx;
- int incr, lift, mod, rem;
+ int incr;
dx = x2 - x1;
@@ -584,7 +612,7 @@
if ( ex1 == ex2 )
{
delta = y2 - y1;
- ras.area += (TArea)( fx1 + fx2 ) * delta;
+ ras.area += (TArea)(( fx1 + fx2 ) * delta);
ras.cover += delta;
return;
}
@@ -612,7 +640,7 @@
mod += (TCoord)dx;
}
- ras.area += (TArea)( fx1 + first ) * delta;
+ ras.area += (TArea)(( fx1 + first ) * delta);
ras.cover += delta;
ex1 += incr;
@@ -642,7 +670,7 @@
delta++;
}
- ras.area += (TArea)ONE_PIXEL * delta;
+ ras.area += (TArea)(ONE_PIXEL * delta);
ras.cover += delta;
y1 += delta;
ex1 += incr;
@@ -651,7 +679,7 @@
}
delta = y2 - y1;
- ras.area += (TArea)( fx2 + ONE_PIXEL - first ) * delta;
+ ras.area += (TArea)(( fx2 + ONE_PIXEL - first ) * delta);
ras.cover += delta;
}
@@ -664,10 +692,10 @@
gray_render_line( RAS_ARG_ TPos to_x,
TPos to_y )
{
- TCoord ey1, ey2, fy1, fy2;
+ TCoord ey1, ey2, fy1, fy2, mod;
TPos dx, dy, x, x2;
long p, first;
- int delta, rem, mod, lift, incr;
+ int delta, rem, lift, incr;
ey1 = TRUNC( ras.last_ey );
@@ -711,7 +739,7 @@
{
TCoord ex = TRUNC( ras.x );
TCoord two_fx = (TCoord)( ( ras.x - SUBPIXELS( ex ) ) << 1 );
- TPos area;
+ TArea area;
first = ONE_PIXEL;
@@ -726,7 +754,7 @@
ras.cover += delta;
ey1 += incr;
- gray_set_cell( &ras, ex, ey1 );
+ gray_set_cell( RAS_VAR_ ex, ey1 );
delta = (int)( first + first - ONE_PIXEL );
area = (TArea)two_fx * delta;
@@ -736,7 +764,7 @@
ras.cover += delta;
ey1 += incr;
- gray_set_cell( &ras, ex, ey1 );
+ gray_set_cell( RAS_VAR_ ex, ey1 );
}
delta = (int)( fy2 - ONE_PIXEL + first );
@@ -1104,13 +1132,13 @@
/* record current cell, if any */
- gray_record_cell( worker );
+ gray_record_cell( RAS_VAR );
/* start to a new position */
x = UPSCALE( to->x );
y = UPSCALE( to->y );
- gray_start_cell( worker, TRUNC( x ), TRUNC( y ) );
+ gray_start_cell( RAS_VAR_ TRUNC( x ), TRUNC( y ) );
worker->x = x;
worker->y = y;
@@ -1122,7 +1150,7 @@
gray_line_to( const FT_Vector* to,
PWorker worker )
{
- gray_render_line( worker, UPSCALE( to->x ), UPSCALE( to->y ) );
+ gray_render_line( RAS_VAR_ UPSCALE( to->x ), UPSCALE( to->y ) );
return 0;
}
@@ -1132,7 +1160,7 @@
const FT_Vector* to,
PWorker worker )
{
- gray_render_conic( worker, control, to );
+ gray_render_conic( RAS_VAR_ control, to );
return 0;
}
@@ -1143,7 +1171,7 @@
const FT_Vector* to,
PWorker worker )
{
- gray_render_cubic( worker, control1, control2, to );
+ gray_render_cubic( RAS_VAR_ control1, control2, to );
return 0;
}
@@ -1203,7 +1231,7 @@
gray_hline( RAS_ARG_ TCoord x,
TCoord y,
TPos area,
- int acount )
+ TCoord acount )
{
FT_Span* span;
int count;
@@ -1243,6 +1271,10 @@
if ( x >= 32767 )
x = 32767;
+ /* FT_Span.y is an integer, so limit our coordinates appropriately */
+ if ( y >= FT_INT_MAX )
+ y = FT_INT_MAX;
+
if ( coverage )
{
/* see whether we can add this span to the current list */
@@ -1281,7 +1313,7 @@
#endif /* FT_DEBUG_LEVEL_TRACE */
ras.num_gray_spans = 0;
- ras.span_y = y;
+ ras.span_y = (int)y;
count = 0;
span = ras.gray_spans;
@@ -1317,7 +1349,7 @@
printf( "%3d:", yindex );
for ( cell = ras.ycells[yindex]; cell != NULL; cell = cell->next )
- printf( " (%3d, c:%4d, a:%6d)", cell->x, cell->cover, cell->area );
+ printf( " (%3ld, c:%4ld, a:%6d)", cell->x, cell->cover, cell->area );
printf( "\n" );
}
}
@@ -1349,7 +1381,7 @@
for ( ; cell != NULL; cell = cell->next )
{
- TArea area;
+ TPos area;
if ( cell->x > x && cover != 0 )
@@ -1666,23 +1698,25 @@
} TBand;
-
- static int
- gray_convert_glyph_inner( RAS_ARG )
- {
- static
- const FT_Outline_Funcs func_interface =
- {
+ FT_DEFINE_OUTLINE_FUNCS(func_interface,
(FT_Outline_MoveTo_Func) gray_move_to,
(FT_Outline_LineTo_Func) gray_line_to,
(FT_Outline_ConicTo_Func)gray_conic_to,
(FT_Outline_CubicTo_Func)gray_cubic_to,
0,
0
- };
+ )
+
+ static int
+ gray_convert_glyph_inner( RAS_ARG )
+ {
volatile int error = 0;
+#ifdef FT_CONFIG_OPTION_PIC
+ FT_Outline_Funcs func_interface;
+ Init_Class_func_interface(&func_interface);
+#endif
if ( ft_setjmp( ras.jump_buffer ) == 0 )
{
@@ -1829,7 +1863,7 @@
if ( middle == bottom )
{
#ifdef FT_DEBUG_LEVEL_TRACE
- FT_TRACE7(( "gray_convert_glyph: Rotten glyph!\n" ));
+ FT_TRACE7(( "gray_convert_glyph: rotten glyph\n" ));
#endif
return 1;
}
@@ -1917,7 +1951,7 @@
ras.clip_box.yMax = 32767L;
}
- gray_init_cells( worker, raster->buffer, raster->buffer_size );
+ gray_init_cells( RAS_VAR_ raster->buffer, raster->buffer_size );
ras.outline = *outline;
ras.num_cells = 0;
@@ -1937,7 +1971,7 @@
ras.render_span_data = &ras;
}
- return gray_convert_glyph( worker );
+ return gray_convert_glyph( RAS_VAR );
}
@@ -2037,8 +2071,7 @@
}
- const FT_Raster_Funcs ft_grays_raster =
- {
+ FT_DEFINE_RASTER_FUNCS(ft_grays_raster,
FT_GLYPH_FORMAT_OUTLINE,
(FT_Raster_New_Func) gray_raster_new,
@@ -2046,7 +2079,7 @@
(FT_Raster_Set_Mode_Func)0,
(FT_Raster_Render_Func) gray_raster_render,
(FT_Raster_Done_Func) gray_raster_done
- };
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/smooth/ftgrays.h b/src/3rdparty/freetype/src/smooth/ftgrays.h
index 2d409543dc..f20f55f14b 100644
--- a/src/3rdparty/freetype/src/smooth/ftgrays.h
+++ b/src/3rdparty/freetype/src/smooth/ftgrays.h
@@ -28,6 +28,7 @@
#include "ftimage.h"
#else
#include <ft2build.h>
+#include FT_CONFIG_CONFIG_H /* for FT_CONFIG_OPTION_PIC */
#include FT_IMAGE_H
#endif
diff --git a/src/3rdparty/freetype/src/smooth/ftsmooth.c b/src/3rdparty/freetype/src/smooth/ftsmooth.c
index a6db5048d3..eed6353157 100644
--- a/src/3rdparty/freetype/src/smooth/ftsmooth.c
+++ b/src/3rdparty/freetype/src/smooth/ftsmooth.c
@@ -17,10 +17,12 @@
#include <ft2build.h>
+#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_OBJECTS_H
#include FT_OUTLINE_H
#include "ftsmooth.h"
#include "ftgrays.h"
+#include "ftspic.h"
#include "ftsmerrs.h"
@@ -153,7 +155,7 @@
slot->internal->flags &= ~FT_GLYPH_OWN_BITMAP;
}
- /* allocate new one, depends on pixel format */
+ /* allocate new one */
pitch = width;
if ( hmul )
{
@@ -194,6 +196,19 @@
#endif
+#if FT_UINT_MAX > 0xFFFFU
+
+ /* Required check is ( pitch * height < FT_ULONG_MAX ), */
+ /* but we care realistic cases only. Always pitch <= width. */
+ if ( width > 0xFFFFU || height > 0xFFFFU )
+ {
+ FT_ERROR(( "ft_smooth_render_generic: glyph too large: %d x %d\n",
+ width, height ));
+ return Smooth_Err_Raster_Overflow;
+ }
+
+#endif
+
bitmap->pixel_mode = FT_PIXEL_MODE_GRAY;
bitmap->num_grays = 256;
bitmap->width = width;
@@ -310,12 +325,19 @@
FT_Outline_Translate( outline, x_shift, y_shift );
+ /*
+ * XXX: on 16bit system, we return an error for huge bitmap
+ * to prevent an overflow.
+ */
+ if ( x_left > FT_INT_MAX || y_top > FT_INT_MAX )
+ return Smooth_Err_Invalid_Pixel_Size;
+
if ( error )
goto Exit;
slot->format = FT_GLYPH_FORMAT_BITMAP;
- slot->bitmap_left = x_left;
- slot->bitmap_top = y_top;
+ slot->bitmap_left = (FT_Int)x_left;
+ slot->bitmap_top = (FT_Int)y_top;
Exit:
if ( outline && origin )
@@ -376,10 +398,8 @@
}
- FT_CALLBACK_TABLE_DEF
- const FT_Renderer_Class ft_smooth_renderer_class =
- {
- {
+ FT_DEFINE_RENDERER(ft_smooth_renderer_class,
+
FT_MODULE_RENDERER,
sizeof( FT_RendererRec ),
@@ -392,7 +412,7 @@
(FT_Module_Constructor)ft_smooth_init,
(FT_Module_Destructor) 0,
(FT_Module_Requester) 0
- },
+ ,
FT_GLYPH_FORMAT_OUTLINE,
@@ -401,14 +421,12 @@
(FT_Renderer_GetCBoxFunc) ft_smooth_get_cbox,
(FT_Renderer_SetModeFunc) ft_smooth_set_mode,
- (FT_Raster_Funcs*) &ft_grays_raster
- };
+ (FT_Raster_Funcs*) &FT_GRAYS_RASTER_GET
+ )
- FT_CALLBACK_TABLE_DEF
- const FT_Renderer_Class ft_smooth_lcd_renderer_class =
- {
- {
+ FT_DEFINE_RENDERER(ft_smooth_lcd_renderer_class,
+
FT_MODULE_RENDERER,
sizeof( FT_RendererRec ),
@@ -421,7 +439,7 @@
(FT_Module_Constructor)ft_smooth_init,
(FT_Module_Destructor) 0,
(FT_Module_Requester) 0
- },
+ ,
FT_GLYPH_FORMAT_OUTLINE,
@@ -430,15 +448,11 @@
(FT_Renderer_GetCBoxFunc) ft_smooth_get_cbox,
(FT_Renderer_SetModeFunc) ft_smooth_set_mode,
- (FT_Raster_Funcs*) &ft_grays_raster
- };
+ (FT_Raster_Funcs*) &FT_GRAYS_RASTER_GET
+ )
+ FT_DEFINE_RENDERER(ft_smooth_lcdv_renderer_class,
-
- FT_CALLBACK_TABLE_DEF
- const FT_Renderer_Class ft_smooth_lcdv_renderer_class =
- {
- {
FT_MODULE_RENDERER,
sizeof( FT_RendererRec ),
@@ -451,7 +465,7 @@
(FT_Module_Constructor)ft_smooth_init,
(FT_Module_Destructor) 0,
(FT_Module_Requester) 0
- },
+ ,
FT_GLYPH_FORMAT_OUTLINE,
@@ -460,8 +474,8 @@
(FT_Renderer_GetCBoxFunc) ft_smooth_get_cbox,
(FT_Renderer_SetModeFunc) ft_smooth_set_mode,
- (FT_Raster_Funcs*) &ft_grays_raster
- };
+ (FT_Raster_Funcs*) &FT_GRAYS_RASTER_GET
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/smooth/ftsmooth.h b/src/3rdparty/freetype/src/smooth/ftsmooth.h
index 62cced4487..3708790df1 100644
--- a/src/3rdparty/freetype/src/smooth/ftsmooth.h
+++ b/src/3rdparty/freetype/src/smooth/ftsmooth.h
@@ -28,15 +28,15 @@ FT_BEGIN_HEADER
#ifndef FT_CONFIG_OPTION_NO_STD_RASTER
- FT_EXPORT_VAR( const FT_Renderer_Class ) ft_std_renderer_class;
+ FT_DECLARE_RENDERER( ft_std_renderer_class )
#endif
#ifndef FT_CONFIG_OPTION_NO_SMOOTH_RASTER
- FT_EXPORT_VAR( const FT_Renderer_Class ) ft_smooth_renderer_class;
+ FT_DECLARE_RENDERER( ft_smooth_renderer_class )
- FT_EXPORT_VAR( const FT_Renderer_Class ) ft_smooth_lcd_renderer_class;
+ FT_DECLARE_RENDERER( ft_smooth_lcd_renderer_class )
- FT_EXPORT_VAR( const FT_Renderer_Class ) ft_smooth_lcd_v_renderer_class;
+ FT_DECLARE_RENDERER( ft_smooth_lcd_v_renderer_class )
#endif
diff --git a/src/3rdparty/freetype/src/smooth/ftspic.c b/src/3rdparty/freetype/src/smooth/ftspic.c
new file mode 100644
index 0000000000..aa547fceb6
--- /dev/null
+++ b/src/3rdparty/freetype/src/smooth/ftspic.c
@@ -0,0 +1,97 @@
+/***************************************************************************/
+/* */
+/* ftspic.c */
+/* */
+/* The FreeType position independent code services for smooth module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#include <ft2build.h>
+#include FT_FREETYPE_H
+#include FT_INTERNAL_OBJECTS_H
+#include "ftspic.h"
+
+#ifdef FT_CONFIG_OPTION_PIC
+
+ /* forward declaration of PIC init functions from ftgrays.c */
+ void FT_Init_Class_ft_grays_raster(FT_Raster_Funcs*);
+
+ void
+ ft_smooth_renderer_class_pic_free( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+ if ( pic_container->smooth )
+ {
+ SmoothPIC* container = (SmoothPIC*)pic_container->smooth;
+ if(--container->ref_count)
+ return;
+ FT_FREE( container );
+ pic_container->smooth = NULL;
+ }
+ }
+
+
+ FT_Error
+ ft_smooth_renderer_class_pic_init( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Error error = FT_Err_Ok;
+ SmoothPIC* container;
+ FT_Memory memory = library->memory;
+
+ /* since this function also serve smooth_lcd and smooth_lcdv renderers,
+ it implements reference counting */
+ if(pic_container->smooth)
+ {
+ ((SmoothPIC*)pic_container->smooth)->ref_count++;
+ return error;
+ }
+
+ /* allocate pointer, clear and set global container pointer */
+ if ( FT_ALLOC ( container, sizeof ( *container ) ) )
+ return error;
+ FT_MEM_SET( container, 0, sizeof(*container) );
+ pic_container->smooth = container;
+ container->ref_count = 1;
+
+ /* initialize pointer table - this is how the module usually expects this data */
+ FT_Init_Class_ft_grays_raster(&container->ft_grays_raster);
+/*Exit:*/
+ if(error)
+ ft_smooth_renderer_class_pic_free(library);
+ return error;
+ }
+
+ /* re-route these init and free functions to the above functions */
+ FT_Error ft_smooth_lcd_renderer_class_pic_init(FT_Library library)
+ {
+ return ft_smooth_renderer_class_pic_init(library);
+ }
+ void ft_smooth_lcd_renderer_class_pic_free(FT_Library library)
+ {
+ ft_smooth_renderer_class_pic_free(library);
+ }
+ FT_Error ft_smooth_lcdv_renderer_class_pic_init(FT_Library library)
+ {
+ return ft_smooth_renderer_class_pic_init(library);
+ }
+ void ft_smooth_lcdv_renderer_class_pic_free(FT_Library library)
+ {
+ ft_smooth_renderer_class_pic_free(library);
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/smooth/ftspic.h b/src/3rdparty/freetype/src/smooth/ftspic.h
new file mode 100644
index 0000000000..c7e0ce9d89
--- /dev/null
+++ b/src/3rdparty/freetype/src/smooth/ftspic.h
@@ -0,0 +1,50 @@
+/***************************************************************************/
+/* */
+/* ftspic.h */
+/* */
+/* The FreeType position independent code services for smooth module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifndef __FTSPIC_H__
+#define __FTSPIC_H__
+
+
+FT_BEGIN_HEADER
+
+#include FT_INTERNAL_PIC_H
+
+#ifndef FT_CONFIG_OPTION_PIC
+#define FT_GRAYS_RASTER_GET ft_grays_raster
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+ typedef struct SmoothPIC_
+ {
+ int ref_count;
+ FT_Raster_Funcs ft_grays_raster;
+ } SmoothPIC;
+
+#define GET_PIC(lib) ((SmoothPIC*)((lib)->pic_container.smooth))
+#define FT_GRAYS_RASTER_GET (GET_PIC(library)->ft_grays_raster)
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /* */
+
+FT_END_HEADER
+
+#endif /* __FTSPIC_H__ */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/smooth/smooth.c b/src/3rdparty/freetype/src/smooth/smooth.c
index ff6be3e400..a8ac51f9f8 100644
--- a/src/3rdparty/freetype/src/smooth/smooth.c
+++ b/src/3rdparty/freetype/src/smooth/smooth.c
@@ -19,6 +19,7 @@
#define FT_MAKE_OPTION_SINGLE_OBJECT
#include <ft2build.h>
+#include "ftspic.c"
#include "ftgrays.c"
#include "ftsmooth.c"
diff --git a/src/3rdparty/freetype/src/tools/apinames.c b/src/3rdparty/freetype/src/tools/apinames.c
index 19aec500bf..7f191e19c9 100644
--- a/src/3rdparty/freetype/src/tools/apinames.c
+++ b/src/3rdparty/freetype/src/tools/apinames.c
@@ -10,7 +10,7 @@
* accepted if you are using GCC for compilation (and probably by
* other compilers too).
*
- * Author: David Turner, 2005, 2006, 2008
+ * Author: David Turner, 2005, 2006, 2008, 2009
*
* This code is explicitly placed into the public domain.
*
@@ -265,7 +265,7 @@ read_header_file( FILE* file, int verbose )
if ( p > name )
{
if ( verbose )
- fprintf( stderr, ">>> %.*s\n", p-name, name );
+ fprintf( stderr, ">>> %.*s\n", (int)(p - name), name );
names_add( name, p );
}
diff --git a/src/3rdparty/freetype/src/tools/chktrcmp.py b/src/3rdparty/freetype/src/tools/chktrcmp.py
new file mode 100644
index 0000000000..d0f342e6bd
--- /dev/null
+++ b/src/3rdparty/freetype/src/tools/chktrcmp.py
@@ -0,0 +1,114 @@
+#!/usr/bin/env python
+#
+# Check trace components in FreeType 2 source.
+# Author: suzuki toshiya, 2009
+#
+# This code is explicitly into the public domain.
+
+
+import sys
+import os
+import re
+
+SRC_FILE_LIST = []
+USED_COMPONENT = {}
+KNOWN_COMPONENT = {}
+
+SRC_FILE_DIRS = [ "src" ]
+TRACE_DEF_FILES = [ "include/freetype/internal/fttrace.h" ]
+
+
+# --------------------------------------------------------------
+# Parse command line options
+#
+
+for i in range( 1, len( sys.argv ) ):
+ if sys.argv[i].startswith( "--help" ):
+ print "Usage: %s [option]" % sys.argv[0]
+ print "Search used-but-defined and defined-but-not-used trace_XXX macros"
+ print ""
+ print " --help:"
+ print " Show this help"
+ print ""
+ print " --src-dirs=dir1:dir2:..."
+ print " Specify the directories of C source files to be checked"
+ print " Default is %s" % ":".join( SRC_FILE_DIRS )
+ print ""
+ print " --def-files=file1:file2:..."
+ print " Specify the header files including FT_TRACE_DEF()"
+ print " Default is %s" % ":".join( TRACE_DEF_FILES )
+ print ""
+ exit(0)
+ if sys.argv[i].startswith( "--src-dirs=" ):
+ SRC_FILE_DIRS = sys.argv[i].replace( "--src-dirs=", "", 1 ).split( ":" )
+ elif sys.argv[i].startswith( "--def-files=" ):
+ TRACE_DEF_FILES = sys.argv[i].replace( "--def-files=", "", 1 ).split( ":" )
+
+
+# --------------------------------------------------------------
+# Scan C source and header files using trace macros.
+#
+
+c_pathname_pat = re.compile( '^.*\.[ch]$', re.IGNORECASE )
+trace_use_pat = re.compile( '^[ \t]*#define[ \t]+FT_COMPONENT[ \t]+trace_' )
+
+for d in SRC_FILE_DIRS:
+ for ( p, dlst, flst ) in os.walk( d ):
+ for f in flst:
+ if c_pathname_pat.match( f ) != None:
+ src_pathname = os.path.join( p, f )
+
+ line_num = 0
+ for src_line in open( src_pathname, 'r' ):
+ line_num = line_num + 1
+ src_line = src_line.strip()
+ if trace_use_pat.match( src_line ) != None:
+ component_name = trace_use_pat.sub( '', src_line )
+ if component_name in USED_COMPONENT:
+ USED_COMPONENT[component_name].append( "%s:%d" % ( src_pathname, line_num ) )
+ else:
+ USED_COMPONENT[component_name] = [ "%s:%d" % ( src_pathname, line_num ) ]
+
+
+# --------------------------------------------------------------
+# Scan header file(s) defining trace macros.
+#
+
+trace_def_pat_opn = re.compile( '^.*FT_TRACE_DEF[ \t]*\([ \t]*' )
+trace_def_pat_cls = re.compile( '[ \t\)].*$' )
+
+for f in TRACE_DEF_FILES:
+ line_num = 0
+ for hdr_line in open( f, 'r' ):
+ line_num = line_num + 1
+ hdr_line = hdr_line.strip()
+ if trace_def_pat_opn.match( hdr_line ) != None:
+ component_name = trace_def_pat_opn.sub( '', hdr_line )
+ component_name = trace_def_pat_cls.sub( '', component_name )
+ if component_name in KNOWN_COMPONENT:
+ print "trace component %s is defined twice, see %s and fttrace.h:%d" % \
+ ( component_name, KNOWN_COMPONENT[component_name], line_num )
+ else:
+ KNOWN_COMPONENT[component_name] = "%s:%d" % \
+ ( os.path.basename( f ), line_num )
+
+
+# --------------------------------------------------------------
+# Compare the used and defined trace macros.
+#
+
+print "# Trace component used in the implementations but not defined in fttrace.h."
+cmpnt = USED_COMPONENT.keys()
+cmpnt.sort()
+for c in cmpnt:
+ if c not in KNOWN_COMPONENT:
+ print "Trace component %s (used in %s) is not defined." % ( c, ", ".join( USED_COMPONENT[c] ) )
+
+print "# Trace component is defined but not used in the implementations."
+cmpnt = KNOWN_COMPONENT.keys()
+cmpnt.sort()
+for c in cmpnt:
+ if c not in USED_COMPONENT:
+ if c != "any":
+ print "Trace component %s (defined in %s) is not used." % ( c, KNOWN_COMPONENT[c] )
+
diff --git a/src/3rdparty/freetype/src/tools/docmaker/content.py b/src/3rdparty/freetype/src/tools/docmaker/content.py
index 0d76d19de3..b398955b81 100644
--- a/src/3rdparty/freetype/src/tools/docmaker/content.py
+++ b/src/3rdparty/freetype/src/tools/docmaker/content.py
@@ -540,7 +540,7 @@ class DocBlock:
while start < end and not string.strip( source[end] ):
end = end - 1
- if start == end:
+ if start == end and not string.strip( source[start] ):
self.code = []
else:
self.code = source[start:end + 1]
diff --git a/src/3rdparty/freetype/src/tools/test_afm.c b/src/3rdparty/freetype/src/tools/test_afm.c
index d53cb33256..f5f99363ca 100644
--- a/src/3rdparty/freetype/src/tools/test_afm.c
+++ b/src/3rdparty/freetype/src/tools/test_afm.c
@@ -63,7 +63,7 @@
int
dummy_get_index( const char* name,
- FT_UInt len,
+ FT_Offset len,
void* user_data )
{
if ( len )
diff --git a/src/3rdparty/freetype/src/truetype/Jamfile b/src/3rdparty/freetype/src/truetype/Jamfile
index a166909f4c..a8cccfe137 100644
--- a/src/3rdparty/freetype/src/truetype/Jamfile
+++ b/src/3rdparty/freetype/src/truetype/Jamfile
@@ -16,7 +16,7 @@ SubDir FT2_TOP $(FT2_SRC_DIR) truetype ;
if $(FT2_MULTI)
{
- _sources = ttdriver ttobjs ttpload ttgload ttinterp ttgxvar ;
+ _sources = ttdriver ttobjs ttpload ttgload ttinterp ttgxvar ttpic ;
}
else
{
diff --git a/src/3rdparty/freetype/src/truetype/truetype.c b/src/3rdparty/freetype/src/truetype/truetype.c
index b36473a72d..4bd1209787 100644
--- a/src/3rdparty/freetype/src/truetype/truetype.c
+++ b/src/3rdparty/freetype/src/truetype/truetype.c
@@ -19,6 +19,7 @@
#define FT_MAKE_OPTION_SINGLE_OBJECT
#include <ft2build.h>
+#include "ttpic.c"
#include "ttdriver.c" /* driver interface */
#include "ttpload.c" /* tables loader */
#include "ttgload.c" /* glyph loader */
diff --git a/src/3rdparty/freetype/src/truetype/ttdriver.c b/src/3rdparty/freetype/src/truetype/ttdriver.c
index 42feb05ede..d723b57ae9 100644
--- a/src/3rdparty/freetype/src/truetype/ttdriver.c
+++ b/src/3rdparty/freetype/src/truetype/ttdriver.c
@@ -4,7 +4,8 @@
/* */
/* TrueType font driver implementation (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 */
+/* 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -20,7 +21,6 @@
#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_STREAM_H
#include FT_INTERNAL_SFNT_H
-#include FT_TRUETYPE_IDS_H
#include FT_SERVICE_XFREE86_NAME_H
#ifdef TT_CONFIG_OPTION_GX_VAR_SUPPORT
@@ -41,6 +41,7 @@
#include "tterrors.h"
+#include "ttpic.h"
/*************************************************************************/
/* */
@@ -298,7 +299,15 @@
if ( !size )
return TT_Err_Invalid_Size_Handle;
- if ( !face || glyph_index >= (FT_UInt)face->num_glyphs )
+ if ( !face )
+ return TT_Err_Invalid_Argument;
+
+#ifdef FT_CONFIG_OPTION_INCREMENTAL
+ if ( glyph_index >= (FT_UInt)face->num_glyphs &&
+ !face->internal->incremental_interface )
+#else
+ if ( glyph_index >= (FT_UInt)face->num_glyphs )
+#endif
return TT_Err_Invalid_Argument;
if ( load_flags & FT_LOAD_NO_HINTING )
@@ -344,14 +353,13 @@
/*************************************************************************/
#ifdef TT_CONFIG_OPTION_GX_VAR_SUPPORT
- static const FT_Service_MultiMastersRec tt_service_gx_multi_masters =
- {
+ FT_DEFINE_SERVICE_MULTIMASTERSREC(tt_service_gx_multi_masters,
(FT_Get_MM_Func) NULL,
(FT_Set_MM_Design_Func) NULL,
(FT_Set_MM_Blend_Func) TT_Set_MM_Blend,
(FT_Get_MM_Var_Func) TT_Get_MM_Var,
(FT_Set_Var_Design_Func)TT_Set_Var_Design
- };
+ )
#endif
static const FT_Service_TrueTypeEngineRec tt_service_truetype_engine =
@@ -371,22 +379,24 @@
#endif /* TT_USE_BYTECODE_INTERPRETER */
};
- static const FT_Service_TTGlyfRec tt_service_truetype_glyf =
- {
+ FT_DEFINE_SERVICE_TTGLYFREC(tt_service_truetype_glyf,
(TT_Glyf_GetLocationFunc)tt_face_get_location
- };
+ )
- static const FT_ServiceDescRec tt_services[] =
- {
- { FT_SERVICE_ID_XF86_NAME, FT_XF86_FORMAT_TRUETYPE },
#ifdef TT_CONFIG_OPTION_GX_VAR_SUPPORT
- { FT_SERVICE_ID_MULTI_MASTERS, &tt_service_gx_multi_masters },
+ FT_DEFINE_SERVICEDESCREC4(tt_services,
+ FT_SERVICE_ID_XF86_NAME, FT_XF86_FORMAT_TRUETYPE,
+ FT_SERVICE_ID_MULTI_MASTERS, &FT_TT_SERVICE_GX_MULTI_MASTERS_GET,
+ FT_SERVICE_ID_TRUETYPE_ENGINE, &tt_service_truetype_engine,
+ FT_SERVICE_ID_TT_GLYF, &FT_TT_SERVICE_TRUETYPE_GLYF_GET
+ )
+#else
+ FT_DEFINE_SERVICEDESCREC3(tt_services,
+ FT_SERVICE_ID_XF86_NAME, FT_XF86_FORMAT_TRUETYPE,
+ FT_SERVICE_ID_TRUETYPE_ENGINE, &tt_service_truetype_engine,
+ FT_SERVICE_ID_TT_GLYF, &FT_TT_SERVICE_TRUETYPE_GLYF_GET
+ )
#endif
- { FT_SERVICE_ID_TRUETYPE_ENGINE, &tt_service_truetype_engine },
- { FT_SERVICE_ID_TT_GLYF, &tt_service_truetype_glyf },
- { NULL, NULL }
- };
-
FT_CALLBACK_DEF( FT_Module_Interface )
tt_get_interface( FT_Module driver, /* TT_Driver */
@@ -396,11 +406,13 @@
FT_Module sfntd;
SFNT_Service sfnt;
-
- result = ft_service_list_lookup( tt_services, tt_interface );
+ result = ft_service_list_lookup( FT_TT_SERVICES_GET, tt_interface );
if ( result != NULL )
return result;
+ if ( !driver )
+ return NULL;
+
/* only return the default interface from the SFNT module */
sfntd = FT_Get_Module( driver->library, "sfnt" );
if ( sfntd )
@@ -416,18 +428,25 @@
/* The FT_DriverInterface structure is defined in ftdriver.h. */
- FT_CALLBACK_TABLE_DEF
- const FT_Driver_ClassRec tt_driver_class =
- {
- {
- FT_MODULE_FONT_DRIVER |
- FT_MODULE_DRIVER_SCALABLE |
#ifdef TT_USE_BYTECODE_INTERPRETER
- FT_MODULE_DRIVER_HAS_HINTER,
+#define TT_HINTER_FLAG FT_MODULE_DRIVER_HAS_HINTER
+#else
+#define TT_HINTER_FLAG 0
+#endif
+
+#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
+#define TT_SIZE_SELECT tt_size_select
#else
- 0,
+#define TT_SIZE_SELECT 0
#endif
+ FT_DEFINE_DRIVER(tt_driver_class,
+
+
+ FT_MODULE_FONT_DRIVER |
+ FT_MODULE_DRIVER_SCALABLE |
+ TT_HINTER_FLAG,
+
sizeof ( TT_DriverRec ),
"truetype", /* driver name */
@@ -439,7 +458,6 @@
tt_driver_init,
tt_driver_done,
tt_get_interface,
- },
sizeof ( TT_FaceRec ),
sizeof ( TT_SizeRec ),
@@ -452,10 +470,9 @@
tt_slot_init,
0, /* FT_Slot_DoneFunc */
-#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
- ft_stub_set_char_sizes,
- ft_stub_set_pixel_sizes,
-#endif
+ ft_stub_set_char_sizes, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+ ft_stub_set_pixel_sizes, /* FT_CONFIG_OPTION_OLD_INTERNALS */
+
Load_Glyph,
tt_get_kerning,
@@ -463,12 +480,8 @@
tt_get_advances,
tt_size_request,
-#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
- tt_size_select
-#else
- 0 /* FT_Size_SelectFunc */
-#endif
- };
+ TT_SIZE_SELECT
+ )
/* END */
diff --git a/src/3rdparty/freetype/src/truetype/ttdriver.h b/src/3rdparty/freetype/src/truetype/ttdriver.h
index f6f26e4b59..aae00f2617 100644
--- a/src/3rdparty/freetype/src/truetype/ttdriver.h
+++ b/src/3rdparty/freetype/src/truetype/ttdriver.h
@@ -27,7 +27,7 @@
FT_BEGIN_HEADER
- FT_EXPORT_VAR( const FT_Driver_ClassRec ) tt_driver_class;
+ FT_DECLARE_DRIVER( tt_driver_class )
FT_END_HEADER
diff --git a/src/3rdparty/freetype/src/truetype/ttgload.c b/src/3rdparty/freetype/src/truetype/ttgload.c
index 06e9ccd1d8..57ea0baa77 100644
--- a/src/3rdparty/freetype/src/truetype/ttgload.c
+++ b/src/3rdparty/freetype/src/truetype/ttgload.c
@@ -4,7 +4,8 @@
/* */
/* TrueType Glyph Loader (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, */
+/* 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -69,7 +70,7 @@
/* `check' is true, take care of monospaced fonts by returning the */
/* advance width maximum. */
/* */
- FT_LOCAL_DEF(void)
+ FT_LOCAL_DEF( void )
TT_Get_HMetrics( TT_Face face,
FT_UInt idx,
FT_Bool check,
@@ -80,6 +81,9 @@
if ( check && face->postscript.isFixedPitch )
*aw = face->horizontal.advance_Width_Max;
+
+ FT_TRACE5(( " advance width (font units): %d\n", *aw ));
+ FT_TRACE5(( " left side bearing (font units): %d\n", *lsb ));
}
@@ -96,7 +100,7 @@
/* The monospace `check' is probably not meaningful here, but we leave */
/* it in for a consistent interface. */
/* */
- FT_LOCAL_DEF(void)
+ FT_LOCAL_DEF( void )
TT_Get_VMetrics( TT_Face face,
FT_UInt idx,
FT_Bool check,
@@ -131,6 +135,91 @@
#endif
+ FT_TRACE5(( " advance height (font units): %d\n", *ah ));
+ FT_TRACE5(( " top side bearing (font units): %d\n", *tsb ));
+ }
+
+
+ static void
+ tt_get_metrics( TT_Loader loader,
+ FT_UInt glyph_index )
+ {
+ TT_Face face = (TT_Face)loader->face;
+
+ FT_Short left_bearing = 0, top_bearing = 0;
+ FT_UShort advance_width = 0, advance_height = 0;
+
+
+ TT_Get_HMetrics( face, glyph_index,
+ (FT_Bool)!( loader->load_flags &
+ FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH ),
+ &left_bearing,
+ &advance_width );
+ TT_Get_VMetrics( face, glyph_index,
+ (FT_Bool)!( loader->load_flags &
+ FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH ),
+ &top_bearing,
+ &advance_height );
+
+#ifdef FT_CONFIG_OPTION_INCREMENTAL
+
+ /* If this is an incrementally loaded font check whether there are */
+ /* overriding metrics for this glyph. */
+ if ( face->root.internal->incremental_interface &&
+ face->root.internal->incremental_interface->funcs->get_glyph_metrics )
+ {
+ FT_Incremental_MetricsRec metrics;
+ FT_Error error;
+
+
+ metrics.bearing_x = left_bearing;
+ metrics.bearing_y = 0;
+ metrics.advance = advance_width;
+ metrics.advance_v = 0;
+
+ error = face->root.internal->incremental_interface->funcs->get_glyph_metrics(
+ face->root.internal->incremental_interface->object,
+ glyph_index, FALSE, &metrics );
+ if ( error )
+ goto Exit;
+
+ left_bearing = (FT_Short)metrics.bearing_x;
+ advance_width = (FT_UShort)metrics.advance;
+
+#if 0
+
+ /* GWW: Do I do the same for vertical metrics? */
+ metrics.bearing_x = 0;
+ metrics.bearing_y = top_bearing;
+ metrics.advance = advance_height;
+
+ error = face->root.internal->incremental_interface->funcs->get_glyph_metrics(
+ face->root.internal->incremental_interface->object,
+ glyph_index, TRUE, &metrics );
+ if ( error )
+ goto Exit;
+
+ top_bearing = (FT_Short)metrics.bearing_y;
+ advance_height = (FT_UShort)metrics.advance;
+
+#endif /* 0 */
+
+ }
+
+ Exit:
+
+#endif /* FT_CONFIG_OPTION_INCREMENTAL */
+
+ loader->left_bearing = left_bearing;
+ loader->advance = advance_width;
+ loader->top_bearing = top_bearing;
+ loader->vadvance = advance_height;
+
+ if ( !loader->linear_def )
+ {
+ loader->linear_def = 1;
+ loader->linear = advance_width;
+ }
}
@@ -317,7 +406,7 @@
if ( n_ins > face->max_profile.maxSizeOfInstructions )
{
- FT_TRACE0(( "TT_Load_Simple_Glyph: Too many instructions (%d)\n",
+ FT_TRACE0(( "TT_Load_Simple_Glyph: too many instructions (%d)\n",
n_ins ));
error = TT_Err_Too_Many_Hints;
goto Fail;
@@ -325,7 +414,7 @@
if ( ( limit - p ) < n_ins )
{
- FT_TRACE0(( "TT_Load_Simple_Glyph: Instruction count mismatch!\n" ));
+ FT_TRACE0(( "TT_Load_Simple_Glyph: instruction count mismatch\n" ));
error = TT_Err_Too_Many_Hints;
goto Fail;
}
@@ -633,7 +722,13 @@
#ifdef TT_USE_BYTECODE_INTERPRETER
- n_ins = loader->glyph->control_len;
+ if ( loader->glyph->control_len > 0xFFFFL )
+ {
+ FT_TRACE1(( "TT_Hint_Glyph: too long instructions " ));
+ FT_TRACE1(( "(0x%lx byte) is truncated\n",
+ loader->glyph->control_len ));
+ }
+ n_ins = (FT_UInt)( loader->glyph->control_len );
#endif
origin = zone->cur[zone->n_points - 4].x;
@@ -680,6 +775,9 @@
FT_Bool debug;
FT_Error error;
+ FT_GlyphLoader gloader = loader->gloader;
+ FT_Outline current_outline = gloader->current.outline;
+
error = TT_Set_CodeRange( loader->exec, tt_coderange_glyph,
loader->exec->glyphIns, n_ins );
@@ -695,6 +793,10 @@
error = TT_Run_Context( loader->exec, debug );
if ( error && loader->exec->pedantic_hinting )
return error;
+
+ /* store drop-out mode in bits 5-7; set bit 2 also as a marker */
+ current_outline.tags[0] |=
+ ( loader->exec->GS.scan_type << 5 ) | FT_CURVE_TAG_HAS_SCANMODE;
}
#endif
@@ -929,15 +1031,15 @@
/* This algorithm is a guess and works much better than the above. */
/* */
FT_Fixed mac_xscale = FT_SqrtFixed(
- FT_MulFix( subglyph->transform.xx,
- subglyph->transform.xx ) +
- FT_MulFix( subglyph->transform.xy,
- subglyph->transform.xy ) );
+ (FT_Int32)FT_MulFix( subglyph->transform.xx,
+ subglyph->transform.xx ) +
+ (FT_Int32)FT_MulFix( subglyph->transform.xy,
+ subglyph->transform.xy ) );
FT_Fixed mac_yscale = FT_SqrtFixed(
- FT_MulFix( subglyph->transform.yy,
- subglyph->transform.yy ) +
- FT_MulFix( subglyph->transform.yx,
- subglyph->transform.yx ) );
+ (FT_Int32)FT_MulFix( subglyph->transform.yy,
+ subglyph->transform.yy ) +
+ (FT_Int32)FT_MulFix( subglyph->transform.yx,
+ subglyph->transform.yx ) );
x = FT_MulFix( x, mac_xscale );
@@ -1030,7 +1132,7 @@
/* check it */
if ( n_ins > ((TT_Face)loader->face)->max_profile.maxSizeOfInstructions )
{
- FT_TRACE0(( "TT_Process_Composite_Glyph: Too many instructions (%d)\n",
+ FT_TRACE0(( "TT_Process_Composite_Glyph: too many instructions (%d)\n",
n_ins ));
return TT_Err_Too_Many_Hints;
@@ -1053,8 +1155,7 @@
/* Some points are likely touched during execution of */
/* instructions on components. So let's untouch them. */
for ( i = start_point; i < loader->zone.n_points; i++ )
- loader->zone.tags[i] &= ~( FT_CURVE_TAG_TOUCH_X |
- FT_CURVE_TAG_TOUCH_Y );
+ loader->zone.tags[i] &= ~FT_CURVE_TAG_TOUCH_BOTH;
loader->zone.n_points += 4;
@@ -1090,9 +1191,10 @@
static FT_Error
load_truetype_glyph( TT_Loader loader,
FT_UInt glyph_index,
- FT_UInt recurse_count )
+ FT_UInt recurse_count,
+ FT_Bool header_only )
{
- FT_Error error;
+ FT_Error error = TT_Err_Ok;
FT_Fixed x_scale, y_scale;
FT_ULong offset;
TT_Face face = (TT_Face)loader->face;
@@ -1139,75 +1241,7 @@
y_scale = 0x10000L;
}
- /* get metrics, horizontal and vertical */
- {
- FT_Short left_bearing = 0, top_bearing = 0;
- FT_UShort advance_width = 0, advance_height = 0;
-
-
- TT_Get_HMetrics( face, glyph_index,
- (FT_Bool)!( loader->load_flags &
- FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH ),
- &left_bearing,
- &advance_width );
- TT_Get_VMetrics( face, glyph_index,
- (FT_Bool)!( loader->load_flags &
- FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH ),
- &top_bearing,
- &advance_height );
-
-#ifdef FT_CONFIG_OPTION_INCREMENTAL
-
- /* If this is an incrementally loaded font see if there are */
- /* overriding metrics for this glyph. */
- if ( face->root.internal->incremental_interface &&
- face->root.internal->incremental_interface->funcs->get_glyph_metrics )
- {
- FT_Incremental_MetricsRec metrics;
-
-
- metrics.bearing_x = left_bearing;
- metrics.bearing_y = 0;
- metrics.advance = advance_width;
- error = face->root.internal->incremental_interface->funcs->get_glyph_metrics(
- face->root.internal->incremental_interface->object,
- glyph_index, FALSE, &metrics );
- if ( error )
- goto Exit;
- left_bearing = (FT_Short)metrics.bearing_x;
- advance_width = (FT_UShort)metrics.advance;
-
-#if 0
-
- /* GWW: Do I do the same for vertical metrics? */
- metrics.bearing_x = 0;
- metrics.bearing_y = top_bearing;
- metrics.advance = advance_height;
- error = face->root.internal->incremental_interface->funcs->get_glyph_metrics(
- face->root.internal->incremental_interface->object,
- glyph_index, TRUE, &metrics );
- if ( error )
- goto Exit;
- top_bearing = (FT_Short)metrics.bearing_y;
- advance_height = (FT_UShort)metrics.advance;
-
-#endif /* 0 */
-
- }
-
-#endif /* FT_CONFIG_OPTION_INCREMENTAL */
-
- loader->left_bearing = left_bearing;
- loader->advance = advance_width;
- loader->top_bearing = top_bearing;
- loader->vadvance = advance_height;
-
- if ( !loader->linear_def )
- {
- loader->linear_def = 1;
- loader->linear = advance_width;
- }
- }
+ tt_get_metrics( loader, glyph_index );
/* Set `offset' to the start of the glyph relative to the start of */
/* the `glyf' table, and `byte_len' to the length of the glyph in */
@@ -1245,9 +1279,15 @@
if ( loader->byte_len > 0 )
{
+#ifdef FT_CONFIG_OPTION_INCREMENTAL
+ /* for the incremental interface, `glyf_offset' is always zero */
+ if ( !loader->glyf_offset &&
+ !face->root.internal->incremental_interface )
+#else
if ( !loader->glyf_offset )
+#endif /* FT_CONFIG_OPTION_INCREMENTAL */
{
- FT_TRACE2(( "no `glyf' table but non-zero `loca' entry!\n" ));
+ FT_TRACE2(( "no `glyf' table but non-zero `loca' entry\n" ));
error = TT_Err_Invalid_Table;
goto Exit;
}
@@ -1260,9 +1300,9 @@
opened_frame = 1;
- /* read first glyph header */
+ /* read glyph header first */
error = face->read_glyph_header( loader );
- if ( error )
+ if ( error || header_only )
goto Exit;
}
@@ -1273,6 +1313,9 @@
loader->bbox.yMin = 0;
loader->bbox.yMax = 0;
+ if ( header_only )
+ goto Exit;
+
TT_LOADER_SET_PP( loader );
#ifdef TT_CONFIG_OPTION_GX_VAR_SUPPORT
@@ -1388,8 +1431,11 @@
{
if ( subglyph->flags & ARGS_ARE_XY_VALUES )
{
- subglyph->arg1 += deltas[i].x;
- subglyph->arg2 += deltas[i].y;
+ /* XXX: overflow check for subglyph->{arg1,arg2}. */
+ /* deltas[i].{x,y} must be within signed 16-bit, */
+ /* but the restriction of summed delta is not clear */
+ subglyph->arg1 += (FT_Int16)deltas[i].x;
+ subglyph->arg2 += (FT_Int16)deltas[i].y;
}
}
@@ -1459,7 +1505,7 @@
num_base_points = gloader->base.outline.n_points;
error = load_truetype_glyph( loader, subglyph->index,
- recurse_count + 1 );
+ recurse_count + 1, FALSE );
if ( error )
goto Exit;
@@ -1579,17 +1625,35 @@
glyph->metrics.horiBearingY = bbox.yMax;
glyph->metrics.horiAdvance = loader->pp2.x - loader->pp1.x;
- /* Now take care of vertical metrics. In the case where there is */
- /* no vertical information within the font (relatively common), make */
- /* up some metrics by `hand'... */
+ /* adjust advance width to the value contained in the hdmx table */
+ if ( !face->postscript.isFixedPitch &&
+ IS_HINTED( loader->load_flags ) )
+ {
+ FT_Byte* widthp;
+
+
+ widthp = tt_face_get_device_metrics( face,
+ size->root.metrics.x_ppem,
+ glyph_index );
+
+ if ( widthp )
+ glyph->metrics.horiAdvance = *widthp << 6;
+ }
+ /* set glyph dimensions */
+ glyph->metrics.width = bbox.xMax - bbox.xMin;
+ glyph->metrics.height = bbox.yMax - bbox.yMin;
+
+ /* Now take care of vertical metrics. In the case where there is */
+ /* no vertical information within the font (relatively common), */
+ /* create some metrics manually */
{
FT_Pos top; /* scaled vertical top side bearing */
FT_Pos advance; /* scaled vertical advance height */
/* Get the unscaled top bearing and advance height. */
- if ( face->vertical_info &&
+ if ( face->vertical_info &&
face->vertical.number_Of_VMetrics > 0 )
{
top = (FT_Short)FT_DivFix( loader->pp3.y - bbox.yMax,
@@ -1664,37 +1728,19 @@
/* scale the metrics */
if ( !( loader->load_flags & FT_LOAD_NO_SCALE ) )
{
- top = FT_MulFix( top, y_scale );
+ top = FT_MulFix( top, y_scale );
advance = FT_MulFix( advance, y_scale );
}
/* XXX: for now, we have no better algorithm for the lsb, but it */
/* should work fine. */
/* */
- glyph->metrics.vertBearingX = ( bbox.xMin - bbox.xMax ) / 2;
+ glyph->metrics.vertBearingX = glyph->metrics.horiBearingX -
+ glyph->metrics.horiAdvance / 2;
glyph->metrics.vertBearingY = top;
glyph->metrics.vertAdvance = advance;
}
- /* adjust advance width to the value contained in the hdmx table */
- if ( !face->postscript.isFixedPitch &&
- IS_HINTED( loader->load_flags ) )
- {
- FT_Byte* widthp;
-
-
- widthp = tt_face_get_device_metrics( face,
- size->root.metrics.x_ppem,
- glyph_index );
-
- if ( widthp )
- glyph->metrics.horiAdvance = *widthp << 6;
- }
-
- /* set glyph dimensions */
- glyph->metrics.width = bbox.xMax - bbox.xMin;
- glyph->metrics.height = bbox.yMax - bbox.yMin;
-
return 0;
}
@@ -1742,6 +1788,7 @@
glyph->metrics.vertAdvance = (FT_Pos)metrics.vertAdvance << 6;
glyph->format = FT_GLYPH_FORMAT_BITMAP;
+
if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
{
glyph->bitmap_left = metrics.vertBearingX;
@@ -1764,7 +1811,8 @@
tt_loader_init( TT_Loader loader,
TT_Size size,
TT_GlyphSlot glyph,
- FT_Int32 load_flags )
+ FT_Int32 load_flags,
+ FT_Bool glyf_table_only )
{
TT_Face face;
FT_Stream stream;
@@ -1778,7 +1826,7 @@
#ifdef TT_USE_BYTECODE_INTERPRETER
/* load execution context */
- if ( IS_HINTED( load_flags ) )
+ if ( IS_HINTED( load_flags ) && !glyf_table_only )
{
TT_ExecContext exec;
FT_Bool grayscale;
@@ -1851,7 +1899,7 @@
loader->glyf_offset = 0;
else if ( error )
{
- FT_ERROR(( "TT_Load_Glyph: could not access glyph table\n" ));
+ FT_ERROR(( "tt_loader_init: could not access glyph table\n" ));
return error;
}
else
@@ -1859,6 +1907,7 @@
}
/* get face's glyph loader */
+ if ( !glyf_table_only )
{
FT_GlyphLoader gloader = glyph->internal->loader;
@@ -1930,7 +1979,25 @@
{
error = load_sbit_image( size, glyph, glyph_index, load_flags );
if ( !error )
+ {
+ FT_Face root = &face->root;
+
+
+ if ( FT_IS_SCALABLE( root ) )
+ {
+ /* for the bbox we need the header only */
+ (void)tt_loader_init( &loader, size, glyph, load_flags, TRUE );
+ (void)load_truetype_glyph( &loader, glyph_index, 0, TRUE );
+ glyph->linearHoriAdvance = loader.linear;
+ glyph->linearVertAdvance = loader.top_bearing + loader.bbox.yMax -
+ loader.vadvance;
+ if ( face->postscript.isFixedPitch &&
+ ( load_flags & FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH ) == 0 )
+ glyph->linearHoriAdvance = face->horizontal.advance_Width_Max;
+ }
+
return TT_Err_Ok;
+ }
}
#endif /* TT_CONFIG_OPTION_EMBEDDED_BITMAPS */
@@ -1942,7 +2009,7 @@
if ( load_flags & FT_LOAD_SBITS_ONLY )
return TT_Err_Invalid_Argument;
- error = tt_loader_init( &loader, size, glyph, load_flags );
+ error = tt_loader_init( &loader, size, glyph, load_flags, FALSE );
if ( error )
return error;
@@ -1951,7 +2018,7 @@
glyph->outline.flags = 0;
/* main loading loop */
- error = load_truetype_glyph( &loader, glyph_index, 0 );
+ error = load_truetype_glyph( &loader, glyph_index, 0, FALSE );
if ( !error )
{
if ( glyph->format == FT_GLYPH_FORMAT_COMPOSITE )
@@ -1998,7 +2065,7 @@
break;
}
}
- else
+ else
glyph->outline.flags |= FT_OUTLINE_IGNORE_DROPOUTS;
}
diff --git a/src/3rdparty/freetype/src/truetype/ttgxvar.c b/src/3rdparty/freetype/src/truetype/ttgxvar.c
index 515e734b8a..ef25aafb5b 100644
--- a/src/3rdparty/freetype/src/truetype/ttgxvar.c
+++ b/src/3rdparty/freetype/src/truetype/ttgxvar.c
@@ -4,7 +4,7 @@
/* */
/* TrueType GX Font Variation loader */
/* */
-/* Copyright 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 2004, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, Werner Lemberg, and George Williams. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -16,30 +16,31 @@
/***************************************************************************/
-/***************************************************************************/
-/* */
-/* Apple documents the `fvar', `gvar', `cvar', and `avar' tables at */
-/* */
-/* http://developer.apple.com/fonts/TTRefMan/RM06/Chap6[fgca]var.html */
-/* */
-/* The documentation for `fvar' is inconsistent. At one point it says */
-/* that `countSizePairs' should be 3, at another point 2. It should be 2. */
-/* */
-/* The documentation for `gvar' is not intelligible; `cvar' refers you to */
-/* `gvar' and is thus also incomprehensible. */
-/* */
-/* The documentation for `avar' appears correct, but Apple has no fonts */
-/* with an `avar' table, so it is hard to test. */
-/* */
-/* Many thanks to John Jenkins (at Apple) in figuring this out. */
-/* */
-/* */
-/* Apple's `kern' table has some references to tuple indices, but as there */
-/* is no indication where these indices are defined, nor how to */
-/* interpolate the kerning values (different tuples have different */
-/* classes) this issue is ignored. */
-/* */
-/***************************************************************************/
+ /*************************************************************************/
+ /* */
+ /* Apple documents the `fvar', `gvar', `cvar', and `avar' tables at */
+ /* */
+ /* http://developer.apple.com/fonts/TTRefMan/RM06/Chap6[fgca]var.html */
+ /* */
+ /* The documentation for `fvar' is inconsistent. At one point it says */
+ /* that `countSizePairs' should be 3, at another point 2. It should */
+ /* be 2. */
+ /* */
+ /* The documentation for `gvar' is not intelligible; `cvar' refers you */
+ /* to `gvar' and is thus also incomprehensible. */
+ /* */
+ /* The documentation for `avar' appears correct, but Apple has no fonts */
+ /* with an `avar' table, so it is hard to test. */
+ /* */
+ /* Many thanks to John Jenkins (at Apple) in figuring this out. */
+ /* */
+ /* */
+ /* Apple's `kern' table has some references to tuple indices, but as */
+ /* there is no indication where these indices are defined, nor how to */
+ /* interpolate the kerning values (different tuples have different */
+ /* classes) this issue is ignored. */
+ /* */
+ /*************************************************************************/
#include <ft2build.h>
@@ -47,11 +48,9 @@
#include FT_CONFIG_CONFIG_H
#include FT_INTERNAL_STREAM_H
#include FT_INTERNAL_SFNT_H
-#include FT_TRUETYPE_IDS_H
#include FT_TRUETYPE_TAGS_H
#include FT_MULTIPLE_MASTERS_H
-#include "ttdriver.h"
#include "ttpload.h"
#include "ttgxvar.h"
@@ -95,11 +94,8 @@
#define ALL_POINTS (FT_UShort*)( -1 )
- enum
- {
- GX_PT_POINTS_ARE_WORDS = 0x80,
- GX_PT_POINT_RUN_COUNT_MASK = 0x7F
- };
+#define GX_PT_POINTS_ARE_WORDS 0x80
+#define GX_PT_POINT_RUN_COUNT_MASK 0x7F
/*************************************************************************/
@@ -158,6 +154,9 @@
runcnt = runcnt & GX_PT_POINT_RUN_COUNT_MASK;
first = points[i++] = FT_GET_USHORT();
+ if ( runcnt < 1 )
+ goto Exit;
+
/* first point not included in runcount */
for ( j = 0; j < runcnt; ++j )
points[i++] = (FT_UShort)( first += FT_GET_USHORT() );
@@ -166,11 +165,15 @@
{
first = points[i++] = FT_GET_BYTE();
+ if ( runcnt < 1 )
+ goto Exit;
+
for ( j = 0; j < runcnt; ++j )
points[i++] = (FT_UShort)( first += FT_GET_BYTE() );
}
}
+ Exit:
return points;
}
@@ -205,12 +208,12 @@
/* */
static FT_Short*
ft_var_readpackeddeltas( FT_Stream stream,
- FT_Int delta_cnt )
+ FT_Offset delta_cnt )
{
FT_Short *deltas;
- FT_Int runcnt;
- FT_Int i;
- FT_Int j;
+ FT_UInt runcnt;
+ FT_Offset i;
+ FT_UInt j;
FT_Memory memory = stream->memory;
FT_Error error = TT_Err_Ok;
@@ -1132,7 +1135,7 @@
if ( blend == NULL )
{
- FT_TRACE2(( "no blend specified!\n" ));
+ FT_TRACE2(( "tt_face_vary_cvt: no blend specified\n" ));
error = TT_Err_Ok;
goto Exit;
@@ -1140,7 +1143,7 @@
if ( face->cvt == NULL )
{
- FT_TRACE2(( "no `cvt ' table!\n" ));
+ FT_TRACE2(( "tt_face_vary_cvt: no `cvt ' table\n" ));
error = TT_Err_Ok;
goto Exit;
@@ -1149,7 +1152,7 @@
error = face->goto_table( face, TTAG_cvar, stream, &table_len );
if ( error )
{
- FT_TRACE2(( "is missing!\n" ));
+ FT_TRACE2(( "is missing\n" ));
error = TT_Err_Ok;
goto Exit;
@@ -1164,7 +1167,7 @@
table_start = FT_Stream_FTell( stream );
if ( FT_GET_LONG() != 0x00010000L )
{
- FT_TRACE2(( "bad table version!\n" ));
+ FT_TRACE2(( "bad table version\n" ));
error = TT_Err_Ok;
goto FExit;
diff --git a/src/3rdparty/freetype/src/truetype/ttgxvar.h b/src/3rdparty/freetype/src/truetype/ttgxvar.h
index 706cb4d369..82dfc4431f 100644
--- a/src/3rdparty/freetype/src/truetype/ttgxvar.h
+++ b/src/3rdparty/freetype/src/truetype/ttgxvar.h
@@ -84,7 +84,7 @@ FT_BEGIN_HEADER
FT_Fixed* normalizedcoords;
FT_MM_Var* mmvar;
- FT_Int mmvar_len;
+ FT_Offset mmvar_len;
FT_Bool avar_checked;
GX_AVarSegment avar_segment;
diff --git a/src/3rdparty/freetype/src/truetype/ttinterp.c b/src/3rdparty/freetype/src/truetype/ttinterp.c
index 3be2502b1f..d1769b8d2a 100644
--- a/src/3rdparty/freetype/src/truetype/ttinterp.c
+++ b/src/3rdparty/freetype/src/truetype/ttinterp.c
@@ -791,9 +791,9 @@
/* allocate object */
if ( FT_NEW( exec ) )
- goto Exit;
+ goto Fail;
- /* initialize it */
+ /* initialize it; in case of error this deallocates `exec' too */
error = Init_Context( exec, memory );
if ( error )
goto Fail;
@@ -802,11 +802,11 @@
driver->context = exec;
}
- Exit:
return driver->context;
Fail:
- return 0;
+ FT_FREE( exec );
+ return NULL;
}
@@ -2195,7 +2195,7 @@
FT_ASSERT( !CUR.face->unpatented_hinting );
#endif
- return TT_DotFix14( dx, dy,
+ return TT_DotFix14( (FT_UInt32)dx, (FT_UInt32)dy,
CUR.GS.projVector.x,
CUR.GS.projVector.y );
}
@@ -2221,7 +2221,7 @@
Dual_Project( EXEC_OP_ FT_Pos dx,
FT_Pos dy )
{
- return TT_DotFix14( dx, dy,
+ return TT_DotFix14( (FT_UInt32)dx, (FT_UInt32)dy,
CUR.GS.dualVector.x,
CUR.GS.dualVector.y );
}
@@ -4291,13 +4291,21 @@
CUR.numFDefs++;
}
+ /* Although FDEF takes unsigned 32-bit integer, */
+ /* func # must be within unsigned 16-bit integer */
+ if ( n > 0xFFFFU )
+ {
+ CUR.error = TT_Err_Too_Many_Function_Defs;
+ return;
+ }
+
rec->range = CUR.curRange;
- rec->opc = n;
+ rec->opc = (FT_UInt16)n;
rec->start = CUR.IP + 1;
rec->active = TRUE;
if ( n > CUR.maxFunc )
- CUR.maxFunc = n;
+ CUR.maxFunc = (FT_UInt16)n;
/* Now skip the whole function definition. */
/* We don't allow nested IDEFS & FDEFs. */
@@ -4554,13 +4562,20 @@
CUR.numIDefs++;
}
- def->opc = args[0];
+ /* opcode must be unsigned 8-bit integer */
+ if ( 0 > args[0] || args[0] > 0x00FF )
+ {
+ CUR.error = TT_Err_Too_Many_Instruction_Defs;
+ return;
+ }
+
+ def->opc = (FT_Byte)args[0];
def->start = CUR.IP+1;
def->range = CUR.curRange;
def->active = TRUE;
if ( (FT_ULong)args[0] > CUR.maxIns )
- CUR.maxIns = args[0];
+ CUR.maxIns = (FT_Byte)args[0];
/* Now skip the whole function definition. */
/* We don't allow nested IDEFs & FDEFs. */
@@ -5528,20 +5543,20 @@
{
if ( CUR.GS.both_x_axis )
{
- dx = TT_MulFix14( args[0], 0x4000 );
+ dx = TT_MulFix14( (FT_UInt32)args[0], 0x4000 );
dy = 0;
}
else
{
dx = 0;
- dy = TT_MulFix14( args[0], 0x4000 );
+ dy = TT_MulFix14( (FT_UInt32)args[0], 0x4000 );
}
}
else
#endif
{
- dx = TT_MulFix14( args[0], CUR.GS.freeVector.x );
- dy = TT_MulFix14( args[0], CUR.GS.freeVector.y );
+ dx = TT_MulFix14( (FT_UInt32)args[0], CUR.GS.freeVector.x );
+ dy = TT_MulFix14( (FT_UInt32)args[0], CUR.GS.freeVector.y );
}
while ( CUR.GS.loop > 0 )
@@ -5707,8 +5722,8 @@
if ( CUR.GS.gep0 == 0 ) /* If in twilight zone */
{
- CUR.zp0.org[point].x = TT_MulFix14( distance, CUR.GS.freeVector.x );
- CUR.zp0.org[point].y = TT_MulFix14( distance, CUR.GS.freeVector.y ),
+ CUR.zp0.org[point].x = TT_MulFix14( (FT_UInt32)distance, CUR.GS.freeVector.x );
+ CUR.zp0.org[point].y = TT_MulFix14( (FT_UInt32)distance, CUR.GS.freeVector.y ),
CUR.zp0.cur[point] = CUR.zp0.org[point];
}
@@ -5895,10 +5910,12 @@
if ( CUR.GS.gep1 == 0 )
{
CUR.zp1.org[point].x = CUR.zp0.org[CUR.GS.rp0].x +
- TT_MulFix14( cvt_dist, CUR.GS.freeVector.x );
+ TT_MulFix14( (FT_UInt32)cvt_dist,
+ CUR.GS.freeVector.x );
CUR.zp1.org[point].y = CUR.zp0.org[CUR.GS.rp0].y +
- TT_MulFix14( cvt_dist, CUR.GS.freeVector.y );
+ TT_MulFix14( (FT_UInt32)cvt_dist,
+ CUR.GS.freeVector.y );
CUR.zp1.cur[point] = CUR.zp0.cur[point];
}
diff --git a/src/3rdparty/freetype/src/truetype/ttobjs.c b/src/3rdparty/freetype/src/truetype/ttobjs.c
index 2649a670dd..11d662d2d4 100644
--- a/src/3rdparty/freetype/src/truetype/ttobjs.c
+++ b/src/3rdparty/freetype/src/truetype/ttobjs.c
@@ -18,9 +18,7 @@
#include <ft2build.h>
#include FT_INTERNAL_DEBUG_H
-#include FT_INTERNAL_CALC_H
#include FT_INTERNAL_STREAM_H
-#include FT_TRUETYPE_IDS_H
#include FT_TRUETYPE_TAGS_H
#include FT_INTERNAL_SFNT_H
@@ -150,7 +148,9 @@
static FT_Bool
tt_check_trickyness( FT_String* name )
{
- static const char* const trick_names[] =
+#define TRICK_NAMES_MAX_CHARACTERS 16
+#define TRICK_NAMES_COUNT 7
+ static const char trick_names[TRICK_NAMES_COUNT][TRICK_NAMES_MAX_CHARACTERS+1] =
{
"DFKaiSho-SB", /* dfkaisb.ttf */
"DFKaiShu",
@@ -159,7 +159,6 @@
"MingLiU", /* mingliu.ttf & mingliu.ttc */
"PMingLiU", /* mingliu.ttc */
"MingLi43", /* mingli.ttf */
- NULL
};
int nn;
@@ -169,7 +168,7 @@
/* Note that we only check the face name at the moment; it might */
/* be worth to do more checks for a few special cases. */
- for ( nn = 0; trick_names[nn] != NULL; nn++ )
+ for ( nn = 0; nn < TRICK_NAMES_COUNT; nn++ )
if ( ft_strstr( name, trick_names[nn] ) )
return TRUE;
@@ -612,18 +611,15 @@
/* Set default metrics */
{
- FT_Size_Metrics* metrics = &size->metrics;
- TT_Size_Metrics* metrics2 = &size->ttmetrics;
+ TT_Size_Metrics* metrics = &size->ttmetrics;
- metrics->x_ppem = 0;
- metrics->y_ppem = 0;
- metrics2->rotated = FALSE;
- metrics2->stretched = FALSE;
+ metrics->rotated = FALSE;
+ metrics->stretched = FALSE;
/* set default compensation (all 0) */
for ( i = 0; i < 4; i++ )
- metrics2->compensations[i] = 0;
+ metrics->compensations[i] = 0;
}
/* allocate function defs, instruction defs, cvt, and storage area */
diff --git a/src/3rdparty/freetype/src/truetype/ttobjs.h b/src/3rdparty/freetype/src/truetype/ttobjs.h
index d4b82285e5..30c8669cb2 100644
--- a/src/3rdparty/freetype/src/truetype/ttobjs.h
+++ b/src/3rdparty/freetype/src/truetype/ttobjs.h
@@ -4,7 +4,7 @@
/* */
/* Objects manager (specification). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -196,43 +196,11 @@ FT_BEGIN_HEADER
/*************************************************************************/
/* */
- /* Subglyph loading record. Used to load composite components. */
- /* */
- typedef struct TT_SubglyphRec_
- {
- FT_Long index; /* subglyph index; initialized with -1 */
- FT_Bool is_scaled; /* is the subglyph scaled? */
- FT_Bool is_hinted; /* should it be hinted? */
- FT_Bool preserve_pps; /* preserve phantom points? */
-
- FT_Long file_offset;
-
- FT_BBox bbox;
- FT_Pos left_bearing;
- FT_Pos advance;
-
- TT_GlyphZoneRec zone;
-
- FT_Long arg1; /* first argument */
- FT_Long arg2; /* second argument */
-
- FT_UShort element_flag; /* current load element flag */
-
- TT_Transform transform; /* transformation matrix */
-
- FT_Vector pp1, pp2; /* phantom points (horizontal) */
- FT_Vector pp3, pp4; /* phantom points (vertical) */
-
- } TT_SubGlyphRec, *TT_SubGlyph_Stack;
-
-
- /*************************************************************************/
- /* */
/* A note regarding non-squared pixels: */
/* */
/* (This text will probably go into some docs at some time; for now, it */
- /* is kept here to explain some definitions in the TIns_Metrics */
- /* record). */
+ /* is kept here to explain some definitions in the TT_Size_Metrics */
+ /* record). */
/* */
/* The CVT is a one-dimensional array containing values that control */
/* certain important characteristics in a font, like the height of all */
diff --git a/src/3rdparty/freetype/src/truetype/ttpic.c b/src/3rdparty/freetype/src/truetype/ttpic.c
new file mode 100644
index 0000000000..27ec4a1d5e
--- /dev/null
+++ b/src/3rdparty/freetype/src/truetype/ttpic.c
@@ -0,0 +1,79 @@
+/***************************************************************************/
+/* */
+/* ttpic.c */
+/* */
+/* The FreeType position independent code services for truetype module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#include <ft2build.h>
+#include FT_FREETYPE_H
+#include FT_INTERNAL_OBJECTS_H
+#include "ttpic.h"
+
+#ifdef FT_CONFIG_OPTION_PIC
+
+ /* forward declaration of PIC init functions from ttdriver.c */
+ FT_Error FT_Create_Class_tt_services( FT_Library, FT_ServiceDescRec**);
+ void FT_Destroy_Class_tt_services( FT_Library, FT_ServiceDescRec*);
+ void FT_Init_Class_tt_service_gx_multi_masters(FT_Service_MultiMastersRec*);
+ void FT_Init_Class_tt_service_truetype_glyf(FT_Service_TTGlyfRec*);
+
+ void
+ tt_driver_class_pic_free( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Memory memory = library->memory;
+ if ( pic_container->truetype )
+ {
+ TTModulePIC* container = (TTModulePIC*)pic_container->truetype;
+ if(container->tt_services)
+ FT_Destroy_Class_tt_services(library, container->tt_services);
+ container->tt_services = NULL;
+ FT_FREE( container );
+ pic_container->truetype = NULL;
+ }
+ }
+
+ FT_Error
+ tt_driver_class_pic_init( FT_Library library )
+ {
+ FT_PIC_Container* pic_container = &library->pic_container;
+ FT_Error error = FT_Err_Ok;
+ TTModulePIC* container;
+ FT_Memory memory = library->memory;
+
+ /* allocate pointer, clear and set global container pointer */
+ if ( FT_ALLOC ( container, sizeof ( *container ) ) )
+ return error;
+ FT_MEM_SET( container, 0, sizeof(*container) );
+ pic_container->truetype = container;
+
+ /* initialize pointer table - this is how the module usually expects this data */
+ error = FT_Create_Class_tt_services(library, &container->tt_services);
+ if(error)
+ goto Exit;
+#ifdef TT_CONFIG_OPTION_GX_VAR_SUPPORT
+ FT_Init_Class_tt_service_gx_multi_masters(&container->tt_service_gx_multi_masters);
+#endif
+ FT_Init_Class_tt_service_truetype_glyf(&container->tt_service_truetype_glyf);
+Exit:
+ if(error)
+ tt_driver_class_pic_free(library);
+ return error;
+ }
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/truetype/ttpic.h b/src/3rdparty/freetype/src/truetype/ttpic.h
new file mode 100644
index 0000000000..84de0fee9e
--- /dev/null
+++ b/src/3rdparty/freetype/src/truetype/ttpic.h
@@ -0,0 +1,59 @@
+/***************************************************************************/
+/* */
+/* ttpic.h */
+/* */
+/* The FreeType position independent code services for truetype module. */
+/* */
+/* Copyright 2009 by */
+/* Oran Agra and Mickey Gabel. */
+/* */
+/* This file is part of the FreeType project, and may only be used, */
+/* modified, and distributed under the terms of the FreeType project */
+/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
+/* this file you indicate that you have read the license and */
+/* understand and accept it fully. */
+/* */
+/***************************************************************************/
+
+
+#ifndef __TTPIC_H__
+#define __TTPIC_H__
+
+
+FT_BEGIN_HEADER
+
+#ifndef FT_CONFIG_OPTION_PIC
+#define FT_TT_SERVICES_GET tt_services
+#define FT_TT_SERVICE_GX_MULTI_MASTERS_GET tt_service_gx_multi_masters
+#define FT_TT_SERVICE_TRUETYPE_GLYF_GET tt_service_truetype_glyf
+
+#else /* FT_CONFIG_OPTION_PIC */
+
+#include FT_MULTIPLE_MASTERS_H
+#include FT_SERVICE_MULTIPLE_MASTERS_H
+#include FT_SERVICE_TRUETYPE_GLYF_H
+
+ typedef struct TTModulePIC_
+ {
+ FT_ServiceDescRec* tt_services;
+#ifdef TT_CONFIG_OPTION_GX_VAR_SUPPORT
+ FT_Service_MultiMastersRec tt_service_gx_multi_masters;
+#endif
+ FT_Service_TTGlyfRec tt_service_truetype_glyf;
+ } TTModulePIC;
+
+#define GET_PIC(lib) ((TTModulePIC*)((lib)->pic_container.truetype))
+#define FT_TT_SERVICES_GET (GET_PIC(library)->tt_services)
+#define FT_TT_SERVICE_GX_MULTI_MASTERS_GET (GET_PIC(library)->tt_service_gx_multi_masters)
+#define FT_TT_SERVICE_TRUETYPE_GLYF_GET (GET_PIC(library)->tt_service_truetype_glyf)
+
+#endif /* FT_CONFIG_OPTION_PIC */
+
+ /* */
+
+FT_END_HEADER
+
+#endif /* __TTPIC_H__ */
+
+
+/* END */
diff --git a/src/3rdparty/freetype/src/truetype/ttpload.c b/src/3rdparty/freetype/src/truetype/ttpload.c
index f5d985eb48..ecdd7376e1 100644
--- a/src/3rdparty/freetype/src/truetype/ttpload.c
+++ b/src/3rdparty/freetype/src/truetype/ttpload.c
@@ -4,7 +4,7 @@
/* */
/* TrueType-specific tables loader (body). */
/* */
-/* Copyright 1996-2001, 2002, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2004, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -58,7 +58,6 @@
/* <Return> */
/* FreeType error code. 0 means success. */
/* */
-
FT_LOCAL_DEF( FT_Error )
tt_face_load_loca( TT_Face face,
FT_Stream stream )
@@ -92,11 +91,11 @@
if ( table_len >= 0x40000L )
{
- FT_TRACE2(( "table too large!\n" ));
+ FT_TRACE2(( "table too large\n" ));
error = TT_Err_Invalid_Table;
goto Exit;
}
- face->num_locations = (FT_UInt)( table_len >> shift );
+ face->num_locations = table_len >> shift;
}
else
{
@@ -104,20 +103,20 @@
if ( table_len >= 0x20000L )
{
- FT_TRACE2(( "table too large!\n" ));
+ FT_TRACE2(( "table too large\n" ));
error = TT_Err_Invalid_Table;
goto Exit;
}
- face->num_locations = (FT_UInt)( table_len >> shift );
+ face->num_locations = table_len >> shift;
}
- if ( face->num_locations != (FT_UInt)face->root.num_glyphs )
+ if ( face->num_locations != (FT_ULong)face->root.num_glyphs )
{
FT_TRACE2(( "glyph count mismatch! loca: %d, maxp: %d\n",
face->num_locations, face->root.num_glyphs ));
/* we only handle the case where `maxp' gives a larger value */
- if ( face->num_locations < (FT_UInt)face->root.num_glyphs )
+ if ( face->num_locations < (FT_ULong)face->root.num_glyphs )
{
FT_Long new_loca_len = (FT_Long)face->root.num_glyphs << shift;
@@ -140,7 +139,7 @@
if ( new_loca_len <= dist )
{
- face->num_locations = (FT_Long)face->root.num_glyphs;
+ face->num_locations = face->root.num_glyphs;
table_len = new_loca_len;
FT_TRACE2(( "adjusting num_locations to %d\n",
@@ -204,12 +203,11 @@
}
}
- /* It isn't mentioned explicitly that the `loca' table must be */
- /* ordered, but implicitly it refers to the length of an entry */
- /* as the difference between the current and the next position. */
- /* Anyway, there do exist (malformed) fonts which don't obey */
- /* this rule, so we are only able to provide an upper bound for */
- /* the size. */
+ /* The `loca' table must be ordered; it refers to the length of */
+ /* an entry as the difference between the current and the next */
+ /* position. However, there do exist (malformed) fonts which */
+ /* don't obey this rule, so we are only able to provide an */
+ /* upper bound for the size. */
/* */
/* We get (intentionally) a wrong, non-zero result in case the */
/* `glyf' table is missing. */
@@ -267,7 +265,7 @@
error = face->goto_table( face, TTAG_cvt, stream, &table_len );
if ( error )
{
- FT_TRACE2(( "is missing!\n" ));
+ FT_TRACE2(( "is missing\n" ));
face->cvt_size = 0;
face->cvt = NULL;
@@ -352,7 +350,7 @@
face->font_program_size = 0;
error = TT_Err_Ok;
- FT_TRACE2(( "is missing!\n" ));
+ FT_TRACE2(( "is missing\n" ));
}
else
{
@@ -413,7 +411,7 @@
face->cvt_program_size = 0;
error = TT_Err_Ok;
- FT_TRACE2(( "is missing!\n" ));
+ FT_TRACE2(( "is missing\n" ));
}
else
{
@@ -537,7 +535,7 @@
FT_Memory memory = stream ? stream->memory : NULL;
if ( face->hdmx_record_sizes )
- FT_FREE( face->hdmx_record_sizes );
+ FT_FREE( face->hdmx_record_sizes );
FT_FRAME_RELEASE( face->hdmx_table );
}
diff --git a/src/3rdparty/freetype/src/type1/t1afm.c b/src/3rdparty/freetype/src/type1/t1afm.c
index 5aea58820e..ef343901a4 100644
--- a/src/3rdparty/freetype/src/type1/t1afm.c
+++ b/src/3rdparty/freetype/src/type1/t1afm.c
@@ -4,7 +4,7 @@
/* */
/* AFM support for Type 1 fonts (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -50,13 +50,17 @@
/* read a glyph name and return the equivalent glyph index */
static FT_Int
t1_get_index( const char* name,
- FT_UInt len,
+ FT_Offset len,
void* user_data )
{
T1_Font type1 = (T1_Font)user_data;
FT_Int n;
+ /* PS string/name length must be < 16-bit */
+ if ( len > 0xFFFFU )
+ return 0;
+
for ( n = 0; n < type1->num_glyphs; n++ )
{
char* gname = (char*)type1->glyph_names[n];
@@ -281,13 +285,15 @@
{
t1_font->font_bbox = fi->FontBBox;
- t1_face->bbox.xMin = fi->FontBBox.xMin >> 16;
- t1_face->bbox.yMin = fi->FontBBox.yMin >> 16;
- t1_face->bbox.xMax = ( fi->FontBBox.xMax + 0xFFFFU ) >> 16;
- t1_face->bbox.yMax = ( fi->FontBBox.yMax + 0xFFFFU ) >> 16;
+ t1_face->bbox.xMin = fi->FontBBox.xMin >> 16;
+ t1_face->bbox.yMin = fi->FontBBox.yMin >> 16;
+ /* no `U' suffix here to 0xFFFF! */
+ t1_face->bbox.xMax = ( fi->FontBBox.xMax + 0xFFFF ) >> 16;
+ t1_face->bbox.yMax = ( fi->FontBBox.yMax + 0xFFFF ) >> 16;
- t1_face->ascender = (FT_Short)( ( fi->Ascender + 0x8000U ) >> 16 );
- t1_face->descender = (FT_Short)( ( fi->Descender + 0x8000U ) >> 16 );
+ /* no `U' suffix here to 0x8000! */
+ t1_face->ascender = (FT_Short)( ( fi->Ascender + 0x8000 ) >> 16 );
+ t1_face->descender = (FT_Short)( ( fi->Descender + 0x8000 ) >> 16 );
if ( fi->NumKernPair )
{
diff --git a/src/3rdparty/freetype/src/type1/t1driver.h b/src/3rdparty/freetype/src/type1/t1driver.h
index ad429440de..9fecbeb0f8 100644
--- a/src/3rdparty/freetype/src/type1/t1driver.h
+++ b/src/3rdparty/freetype/src/type1/t1driver.h
@@ -26,6 +26,10 @@
FT_BEGIN_HEADER
+#ifdef FT_CONFIG_OPTION_PIC
+#error "this module does not support PIC yet"
+#endif
+
FT_EXPORT_VAR( const FT_Driver_ClassRec ) t1_driver_class;
diff --git a/src/3rdparty/freetype/src/type1/t1gload.c b/src/3rdparty/freetype/src/type1/t1gload.c
index c3ac13f59f..f3fad4f5df 100644
--- a/src/3rdparty/freetype/src/type1/t1gload.c
+++ b/src/3rdparty/freetype/src/type1/t1gload.c
@@ -4,7 +4,7 @@
/* */
/* Type 1 Glyph Loader (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2008, 2009 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2008, 2009, 2010 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -18,6 +18,7 @@
#include <ft2build.h>
#include "t1gload.h"
+#include FT_INTERNAL_CALC_H
#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_STREAM_H
#include FT_OUTLINE_H
@@ -62,6 +63,11 @@
T1_Font type1 = &face->type1;
FT_Error error = T1_Err_Ok;
+#ifdef FT_CONFIG_OPTION_INCREMENTAL
+ FT_Incremental_InterfaceRec *inc =
+ face->root.internal->incremental_interface;
+#endif
+
decoder->font_matrix = type1->font_matrix;
decoder->font_offset = type1->font_offset;
@@ -70,10 +76,9 @@
/* For incremental fonts get the character data using the */
/* callback function. */
- if ( face->root.internal->incremental_interface )
- error = face->root.internal->incremental_interface->funcs->get_glyph_data(
- face->root.internal->incremental_interface->object,
- glyph_index, char_string );
+ if ( inc )
+ error = inc->funcs->get_glyph_data( inc->object,
+ glyph_index, char_string );
else
#endif /* FT_CONFIG_OPTION_INCREMENTAL */
@@ -92,22 +97,22 @@
#ifdef FT_CONFIG_OPTION_INCREMENTAL
/* Incremental fonts can optionally override the metrics. */
- if ( !error && face->root.internal->incremental_interface &&
- face->root.internal->incremental_interface->funcs->get_glyph_metrics )
+ if ( !error && inc && inc->funcs->get_glyph_metrics )
{
FT_Incremental_MetricsRec metrics;
- metrics.bearing_x = decoder->builder.left_bearing.x;
- metrics.bearing_y = decoder->builder.left_bearing.y;
- metrics.advance = decoder->builder.advance.x;
- error = face->root.internal->incremental_interface->funcs->get_glyph_metrics(
- face->root.internal->incremental_interface->object,
- glyph_index, FALSE, &metrics );
- decoder->builder.left_bearing.x = metrics.bearing_x;
- decoder->builder.left_bearing.y = metrics.bearing_y;
- decoder->builder.advance.x = metrics.advance;
- decoder->builder.advance.y = 0;
+ metrics.bearing_x = FIXED_TO_INT( decoder->builder.left_bearing.x );
+ metrics.bearing_y = 0;
+ metrics.advance = FIXED_TO_INT( decoder->builder.advance.x );
+ metrics.advance_v = FIXED_TO_INT( decoder->builder.advance.y );
+
+ error = inc->funcs->get_glyph_metrics( inc->object,
+ glyph_index, FALSE, &metrics );
+
+ decoder->builder.left_bearing.x = INT_TO_FIXED( metrics.bearing_x );
+ decoder->builder.advance.x = INT_TO_FIXED( metrics.advance );
+ decoder->builder.advance.y = INT_TO_FIXED( metrics.advance_v );
}
#endif /* FT_CONFIG_OPTION_INCREMENTAL */
@@ -215,8 +220,6 @@
FT_UInt nn;
FT_Error error;
- FT_UNUSED( load_flags );
-
if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
{
@@ -252,7 +255,7 @@
{
error = T1_Parse_Glyph( &decoder, first + nn );
if ( !error )
- advances[nn] = decoder.builder.advance.x;
+ advances[nn] = FIXED_TO_INT( decoder.builder.advance.x );
else
advances[nn] = 0;
}
@@ -284,7 +287,12 @@
#endif
+#ifdef FT_CONFIG_OPTION_INCREMENTAL
+ if ( glyph_index >= (FT_UInt)face->root.num_glyphs &&
+ !face->root.internal->incremental_interface )
+#else
if ( glyph_index >= (FT_UInt)face->root.num_glyphs )
+#endif /* FT_CONFIG_OPTION_INCREMENTAL */
{
error = T1_Err_Invalid_Argument;
goto Exit;
@@ -370,11 +378,14 @@
FT_Slot_Internal internal = glyph->root.internal;
- glyph->root.metrics.horiBearingX = decoder.builder.left_bearing.x;
- glyph->root.metrics.horiAdvance = decoder.builder.advance.x;
- internal->glyph_matrix = font_matrix;
- internal->glyph_delta = font_offset;
- internal->glyph_transformed = 1;
+ glyph->root.metrics.horiBearingX =
+ FIXED_TO_INT( decoder.builder.left_bearing.x );
+ glyph->root.metrics.horiAdvance =
+ FIXED_TO_INT( decoder.builder.advance.x );
+
+ internal->glyph_matrix = font_matrix;
+ internal->glyph_delta = font_offset;
+ internal->glyph_transformed = 1;
}
else
{
@@ -384,14 +395,26 @@
/* copy the _unscaled_ advance width */
- metrics->horiAdvance = decoder.builder.advance.x;
- glyph->root.linearHoriAdvance = decoder.builder.advance.x;
+ metrics->horiAdvance =
+ FIXED_TO_INT( decoder.builder.advance.x );
+ glyph->root.linearHoriAdvance =
+ FIXED_TO_INT( decoder.builder.advance.x );
glyph->root.internal->glyph_transformed = 0;
- /* make up vertical ones */
- metrics->vertAdvance = ( face->type1.font_bbox.yMax -
- face->type1.font_bbox.yMin ) >> 16;
- glyph->root.linearVertAdvance = metrics->vertAdvance;
+ if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
+ {
+ /* make up vertical ones */
+ metrics->vertAdvance = ( face->type1.font_bbox.yMax -
+ face->type1.font_bbox.yMin ) >> 16;
+ glyph->root.linearVertAdvance = metrics->vertAdvance;
+ }
+ else
+ {
+ metrics->vertAdvance =
+ FIXED_TO_INT( decoder.builder.advance.y );
+ glyph->root.linearVertAdvance =
+ FIXED_TO_INT( decoder.builder.advance.y );
+ }
glyph->root.format = FT_GLYPH_FORMAT_OUTLINE;
@@ -451,9 +474,12 @@
metrics->horiBearingX = cbox.xMin;
metrics->horiBearingY = cbox.yMax;
- /* make up vertical ones */
- ft_synthesize_vertical_metrics( metrics,
- metrics->vertAdvance );
+ if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
+ {
+ /* make up vertical ones */
+ ft_synthesize_vertical_metrics( metrics,
+ metrics->vertAdvance );
+ }
}
/* Set control data to the glyph charstrings. Note that this is */
diff --git a/src/3rdparty/freetype/src/type1/t1load.c b/src/3rdparty/freetype/src/type1/t1load.c
index 06e72cca68..d867e942c9 100644
--- a/src/3rdparty/freetype/src/type1/t1load.c
+++ b/src/3rdparty/freetype/src/type1/t1load.c
@@ -65,6 +65,7 @@
#include FT_CONFIG_CONFIG_H
#include FT_MULTIPLE_MASTERS_H
#include FT_INTERNAL_TYPE1_TYPES_H
+#include FT_INTERNAL_CALC_H
#include "t1load.h"
#include "t1errors.h"
@@ -213,10 +214,6 @@
}
-#define FT_INT_TO_FIXED( a ) ( (a) << 16 )
-#define FT_FIXED_TO_INT( a ) ( FT_RoundFix( a ) >> 16 )
-
-
/*************************************************************************/
/* */
/* Given a normalized (blend) coordinate, figure out the design */
@@ -230,7 +227,7 @@
if ( ncv <= axismap->blend_points[0] )
- return FT_INT_TO_FIXED( axismap->design_points[0] );
+ return INT_TO_FIXED( axismap->design_points[0] );
for ( j = 1; j < axismap->num_points; ++j )
{
@@ -241,7 +238,7 @@
axismap->blend_points[j] -
axismap->blend_points[j - 1] );
- return FT_INT_TO_FIXED( axismap->design_points[j - 1] ) +
+ return INT_TO_FIXED( axismap->design_points[j - 1] ) +
FT_MulDiv( t,
axismap->design_points[j] -
axismap->design_points[j - 1],
@@ -249,7 +246,7 @@
}
}
- return FT_INT_TO_FIXED( axismap->design_points[axismap->num_points - 1] );
+ return INT_TO_FIXED( axismap->design_points[axismap->num_points - 1] );
}
@@ -331,8 +328,8 @@
for ( i = 0 ; i < mmaster.num_axis; ++i )
{
mmvar->axis[i].name = mmaster.axis[i].name;
- mmvar->axis[i].minimum = FT_INT_TO_FIXED( mmaster.axis[i].minimum);
- mmvar->axis[i].maximum = FT_INT_TO_FIXED( mmaster.axis[i].maximum);
+ mmvar->axis[i].minimum = INT_TO_FIXED( mmaster.axis[i].minimum);
+ mmvar->axis[i].maximum = INT_TO_FIXED( mmaster.axis[i].maximum);
mmvar->axis[i].def = ( mmvar->axis[i].minimum +
mmvar->axis[i].maximum ) / 2;
/* Does not apply. But this value is in range */
@@ -502,7 +499,7 @@
if ( num_coords <= 4 && num_coords > 0 )
{
for ( i = 0; i < num_coords; ++i )
- lcoords[i] = FT_FIXED_TO_INT( coords[i] );
+ lcoords[i] = FIXED_TO_INT( coords[i] );
error = T1_Set_MM_Design( face, num_coords, lcoords );
}
@@ -654,8 +651,8 @@
}
if ( num_designs == 0 || num_designs > T1_MAX_MM_DESIGNS )
{
- FT_ERROR(( "parse_blend_design_positions:" ));
- FT_ERROR(( " incorrect number of designs: %d\n",
+ FT_ERROR(( "parse_blend_design_positions:"
+ " incorrect number of designs: %d\n",
num_designs ));
error = T1_Err_Invalid_File_Format;
goto Exit;
@@ -687,8 +684,8 @@
{
if ( n_axis <= 0 || n_axis > T1_MAX_MM_AXIS )
{
- FT_ERROR(( "parse_blend_design_positions:" ));
- FT_ERROR(( " invalid number of axes: %d\n",
+ FT_ERROR(( "parse_blend_design_positions:"
+ " invalid number of axes: %d\n",
n_axis ));
error = T1_Err_Invalid_File_Format;
goto Exit;
@@ -842,8 +839,8 @@
}
if ( num_designs == 0 || num_designs > T1_MAX_MM_DESIGNS )
{
- FT_ERROR(( "parse_weight_vector:" ));
- FT_ERROR(( " incorrect number of designs: %d\n",
+ FT_ERROR(( "parse_weight_vector:"
+ " incorrect number of designs: %d\n",
num_designs ));
error = T1_Err_Invalid_File_Format;
goto Exit;
@@ -859,9 +856,9 @@
else if ( blend->num_designs != (FT_UInt)num_designs )
{
FT_ERROR(( "parse_weight_vector:"
- " /BlendDesignPosition and /WeightVector have\n" ));
- FT_ERROR(( " "
- " different number of elements!\n" ));
+ " /BlendDesignPosition and /WeightVector have\n"
+ " "
+ " different number of elements\n" ));
error = T1_Err_Invalid_File_Format;
goto Exit;
}
@@ -1143,7 +1140,7 @@
cur = parser->root.cursor;
if ( cur >= limit )
{
- FT_ERROR(( "parse_encoding: out of bounds!\n" ));
+ FT_ERROR(( "parse_encoding: out of bounds\n" ));
parser->root.error = T1_Err_Invalid_File_Format;
return;
}
@@ -2156,7 +2153,7 @@
#endif
if ( !loader.charstrings.init )
{
- FT_ERROR(( "T1_Open_Face: no `/CharStrings' array in face!\n" ));
+ FT_ERROR(( "T1_Open_Face: no `/CharStrings' array in face\n" ));
error = T1_Err_Invalid_File_Format;
}
@@ -2185,8 +2182,8 @@
/* the index is then stored in type1.encoding.char_index, and */
/* a the name to type1.encoding.char_name */
- min_char = +32000;
- max_char = -32000;
+ min_char = 0;
+ max_char = 0;
charcode = 0;
for ( ; charcode < loader.encoding_table.max_elems; charcode++ )
@@ -2212,25 +2209,14 @@
{
if ( charcode < min_char )
min_char = charcode;
- if ( charcode > max_char )
- max_char = charcode;
+ if ( charcode >= max_char )
+ max_char = charcode + 1;
}
break;
}
}
}
- /*
- * Yes, this happens: Certain PDF-embedded fonts have only a
- * `.notdef' glyph defined!
- */
-
- if ( min_char > max_char )
- {
- min_char = 0;
- max_char = loader.encoding_table.max_elems;
- }
-
type1->encoding.code_first = min_char;
type1->encoding.code_last = max_char;
type1->encoding.num_chars = loader.num_chars;
diff --git a/src/3rdparty/freetype/src/type1/t1objs.c b/src/3rdparty/freetype/src/type1/t1objs.c
index 2f90dd62f6..b1de687196 100644
--- a/src/3rdparty/freetype/src/type1/t1objs.c
+++ b/src/3rdparty/freetype/src/type1/t1objs.c
@@ -4,7 +4,7 @@
/* */
/* Type 1 objects manager (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -17,6 +17,7 @@
#include <ft2build.h>
+#include FT_INTERNAL_CALC_H
#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_STREAM_H
#include FT_TRUETYPE_IDS_H
@@ -440,10 +441,11 @@
root->num_fixed_sizes = 0;
root->available_sizes = 0;
- root->bbox.xMin = type1->font_bbox.xMin >> 16;
- root->bbox.yMin = type1->font_bbox.yMin >> 16;
- root->bbox.xMax = ( type1->font_bbox.xMax + 0xFFFFU ) >> 16;
- root->bbox.yMax = ( type1->font_bbox.yMax + 0xFFFFU ) >> 16;
+ root->bbox.xMin = type1->font_bbox.xMin >> 16;
+ root->bbox.yMin = type1->font_bbox.yMin >> 16;
+ /* no `U' suffix here to 0xFFFF! */
+ root->bbox.xMax = ( type1->font_bbox.xMax + 0xFFFF ) >> 16;
+ root->bbox.yMax = ( type1->font_bbox.yMax + 0xFFFF ) >> 16;
/* Set units_per_EM if we didn't set it in parse_font_matrix. */
if ( !root->units_per_EM )
@@ -467,7 +469,7 @@
/* in case of error, keep the standard width */
if ( !error )
- root->max_advance_width = (FT_Short)max_advance;
+ root->max_advance_width = (FT_Short)FIXED_TO_INT( max_advance );
else
error = T1_Err_Ok; /* clear error */
}
diff --git a/src/3rdparty/freetype/src/type1/t1parse.c b/src/3rdparty/freetype/src/type1/t1parse.c
index 36f5c82c86..2a762279fd 100644
--- a/src/3rdparty/freetype/src/type1/t1parse.c
+++ b/src/3rdparty/freetype/src/type1/t1parse.c
@@ -4,7 +4,7 @@
/* */
/* Type 1 parser (body). */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -35,7 +35,6 @@
#include <ft2build.h>
#include FT_INTERNAL_DEBUG_H
-#include FT_INTERNAL_CALC_H
#include FT_INTERNAL_STREAM_H
#include FT_INTERNAL_POSTSCRIPT_AUX_H
@@ -298,8 +297,8 @@
/* and allocate private dictionary buffer */
if ( parser->private_len == 0 )
{
- FT_ERROR(( "T1_Get_Private_Dict:" ));
- FT_ERROR(( " invalid private dictionary section\n" ));
+ FT_ERROR(( "T1_Get_Private_Dict:"
+ " invalid private dictionary section\n" ));
error = T1_Err_Invalid_File_Format;
goto Fail;
}
@@ -354,8 +353,8 @@
cur++;
if ( cur >= limit )
{
- FT_ERROR(( "T1_Get_Private_Dict:" ));
- FT_ERROR(( " could not find `eexec' keyword\n" ));
+ FT_ERROR(( "T1_Get_Private_Dict:"
+ " could not find `eexec' keyword\n" ));
error = T1_Err_Invalid_File_Format;
goto Exit;
}
@@ -398,18 +397,21 @@
T1_Skip_PS_Token( parser );
cur = parser->root.cursor;
- if ( *cur == '\r' )
- {
- cur++;
- if ( *cur == '\n' )
- cur++;
- }
- else if ( *cur == '\n' )
- cur++;
- else
+
+ /* according to the Type1 spec, the first cipher byte must not be */
+ /* an ASCII whitespace character code (blank, tab, carriage return */
+ /* or line feed). We have seen Type 1 fonts with two line feed */
+ /* characters... So skip now all whitespace character codes. */
+ while ( cur < limit &&
+ ( *cur == ' ' ||
+ *cur == '\t' ||
+ *cur == '\r' ||
+ *cur == '\n' ) )
+ ++cur;
+ if ( cur >= limit )
{
- FT_ERROR(( "T1_Get_Private_Dict:" ));
- FT_ERROR(( " `eexec' not properly terminated\n" ));
+ FT_ERROR(( "T1_Get_Private_Dict:"
+ " `eexec' not properly terminated\n" ));
error = T1_Err_Invalid_File_Format;
goto Exit;
}
diff --git a/src/3rdparty/freetype/src/type42/t42drivr.h b/src/3rdparty/freetype/src/type42/t42drivr.h
index 98b7410b67..4717e4613f 100644
--- a/src/3rdparty/freetype/src/type42/t42drivr.h
+++ b/src/3rdparty/freetype/src/type42/t42drivr.h
@@ -25,6 +25,10 @@
FT_BEGIN_HEADER
+#ifdef FT_CONFIG_OPTION_PIC
+#error "this module does not support PIC yet"
+#endif
+
FT_EXPORT_VAR( const FT_Driver_ClassRec ) t42_driver_class;
diff --git a/src/3rdparty/freetype/src/type42/t42objs.c b/src/3rdparty/freetype/src/type42/t42objs.c
index 16e9809ce1..9081ffc6d2 100644
--- a/src/3rdparty/freetype/src/type42/t42objs.c
+++ b/src/3rdparty/freetype/src/type42/t42objs.c
@@ -4,7 +4,8 @@
/* */
/* Type 42 objects manager (body). */
/* */
-/* Copyright 2002, 2003, 2004, 2005, 2006, 2007, 2008 by Roberto Alameda. */
+/* Copyright 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 */
+/* by Roberto Alameda. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
@@ -19,7 +20,6 @@
#include "t42parse.h"
#include "t42error.h"
#include FT_INTERNAL_DEBUG_H
-#include FT_INTERNAL_STREAM_H
#include FT_LIST_H
@@ -70,7 +70,7 @@
if ( !loader.charstrings.init )
{
- FT_ERROR(( "T42_Open_Face: no charstrings array in face!\n" ));
+ FT_ERROR(( "T42_Open_Face: no charstrings array in face\n" ));
error = T42_Err_Invalid_File_Format;
}
@@ -100,8 +100,8 @@
/* The index is then stored in type1.encoding.char_index, and */
/* the name in type1.encoding.char_name */
- min_char = +32000;
- max_char = -32000;
+ min_char = 0;
+ max_char = 0;
charcode = 0;
for ( ; charcode < loader.encoding_table.max_elems; charcode++ )
@@ -127,13 +127,14 @@
{
if ( charcode < min_char )
min_char = charcode;
- if ( charcode > max_char )
- max_char = charcode;
+ if ( charcode >= max_char )
+ max_char = charcode + 1;
}
break;
}
}
}
+
type1->encoding.code_first = min_char;
type1->encoding.code_last = max_char;
type1->encoding.num_chars = loader.num_chars;
diff --git a/src/3rdparty/freetype/src/type42/t42parse.c b/src/3rdparty/freetype/src/type42/t42parse.c
index b9e408c452..13bda64c83 100644
--- a/src/3rdparty/freetype/src/type42/t42parse.c
+++ b/src/3rdparty/freetype/src/type42/t42parse.c
@@ -20,7 +20,6 @@
#include "t42error.h"
#include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_STREAM_H
-#include FT_LIST_H
#include FT_INTERNAL_POSTSCRIPT_AUX_H
@@ -304,7 +303,7 @@
cur = parser->root.cursor;
if ( cur >= limit )
{
- FT_ERROR(( "t42_parse_encoding: out of bounds!\n" ));
+ FT_ERROR(( "t42_parse_encoding: out of bounds\n" ));
parser->root.error = T42_Err_Invalid_File_Format;
return;
}
@@ -472,7 +471,7 @@
else
{
- FT_ERROR(( "t42_parse_encoding: invalid token!\n" ));
+ FT_ERROR(( "t42_parse_encoding: invalid token\n" ));
parser->root.error = T42_Err_Invalid_File_Format;
}
}
@@ -525,7 +524,7 @@
if ( parser->root.cursor >= limit || *parser->root.cursor++ != '[' )
{
- FT_ERROR(( "t42_parse_sfnts: can't find begin of sfnts vector!\n" ));
+ FT_ERROR(( "t42_parse_sfnts: can't find begin of sfnts vector\n" ));
error = T42_Err_Invalid_File_Format;
goto Fail;
}
@@ -570,7 +569,7 @@
if ( allocated )
{
FT_ERROR(( "t42_parse_sfnts: "
- "can't handle mixed binary and hex strings!\n" ));
+ "can't handle mixed binary and hex strings\n" ));
error = T42_Err_Invalid_File_Format;
goto Fail;
}
@@ -586,7 +585,7 @@
parser->root.cursor += string_size + 1;
if ( parser->root.cursor >= limit )
{
- FT_ERROR(( "t42_parse_sfnts: too many binary data!\n" ));
+ FT_ERROR(( "t42_parse_sfnts: too many binary data\n" ));
error = T42_Err_Invalid_File_Format;
goto Fail;
}
@@ -594,7 +593,7 @@
if ( !string_buf )
{
- FT_ERROR(( "t42_parse_sfnts: invalid data in sfnts array!\n" ));
+ FT_ERROR(( "t42_parse_sfnts: invalid data in sfnts array\n" ));
error = T42_Err_Invalid_File_Format;
goto Fail;
}
@@ -605,7 +604,7 @@
if ( !string_size )
{
- FT_ERROR(( "t42_parse_sfnts: invalid string!\n" ));
+ FT_ERROR(( "t42_parse_sfnts: invalid string\n" ));
error = T42_Err_Invalid_File_Format;
goto Fail;
}
@@ -670,7 +669,7 @@
/* all other tables are just copied */
if ( count >= ttf_size )
{
- FT_ERROR(( "t42_parse_sfnts: too many binary data!\n" ));
+ FT_ERROR(( "t42_parse_sfnts: too many binary data\n" ));
error = T42_Err_Invalid_File_Format;
goto Fail;
}
@@ -717,7 +716,7 @@
if ( parser->root.cursor >= limit )
{
- FT_ERROR(( "t42_parse_charstrings: out of bounds!\n" ));
+ FT_ERROR(( "t42_parse_charstrings: out of bounds\n" ));
error = T42_Err_Invalid_File_Format;
goto Fail;
}
@@ -759,14 +758,14 @@
}
else
{
- FT_ERROR(( "t42_parse_charstrings: invalid token!\n" ));
+ FT_ERROR(( "t42_parse_charstrings: invalid token\n" ));
error = T42_Err_Invalid_File_Format;
goto Fail;
}
if ( parser->root.cursor >= limit )
{
- FT_ERROR(( "t42_parse_charstrings: out of bounds!\n" ));
+ FT_ERROR(( "t42_parse_charstrings: out of bounds\n" ));
error = T42_Err_Invalid_File_Format;
goto Fail;
}
@@ -826,7 +825,7 @@
if ( cur + 1 >= limit )
{
- FT_ERROR(( "t42_parse_charstrings: out of bounds!\n" ));
+ FT_ERROR(( "t42_parse_charstrings: out of bounds\n" ));
error = T42_Err_Invalid_File_Format;
goto Fail;
}
@@ -857,7 +856,7 @@
(void)T1_ToInt( parser );
if ( parser->root.cursor >= limit )
{
- FT_ERROR(( "t42_parse_charstrings: out of bounds!\n" ));
+ FT_ERROR(( "t42_parse_charstrings: out of bounds\n" ));
error = T42_Err_Invalid_File_Format;
goto Fail;
}
@@ -880,7 +879,7 @@
if ( !notdef_found )
{
- FT_ERROR(( "t42_parse_charstrings: no /.notdef glyph!\n" ));
+ FT_ERROR(( "t42_parse_charstrings: no /.notdef glyph\n" ));
error = T42_Err_Invalid_File_Format;
goto Fail;
}
@@ -984,6 +983,10 @@
dummy_object = &face->type1.font_info;
break;
+ case T1_FIELD_LOCATION_FONT_EXTRA:
+ dummy_object = &face->type1.font_extra;
+ break;
+
case T1_FIELD_LOCATION_BBOX:
dummy_object = &face->type1.font_bbox;
break;
diff --git a/src/3rdparty/freetype/src/winfonts/winfnt.c b/src/3rdparty/freetype/src/winfonts/winfnt.c
index f6e9859b44..6b3a4e17f2 100644
--- a/src/3rdparty/freetype/src/winfonts/winfnt.c
+++ b/src/3rdparty/freetype/src/winfonts/winfnt.c
@@ -4,7 +4,7 @@
/* */
/* FreeType font driver for Windows FNT/FON files */
/* */
-/* Copyright 1996-2001, 2002, 2003, 2004, 2006, 2007, 2008 by */
+/* Copyright 1996-2001, 2002, 2003, 2004, 2006, 2007, 2008, 2009 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* Copyright 2003 Huw D M Davies for Codeweavers */
/* Copyright 2007 Dmitry Timoshkov for Codeweavers */
@@ -342,7 +342,7 @@
if ( !font_count || !font_offset )
{
- FT_TRACE2(( "this file doesn't contain any FNT resources!\n" ));
+ FT_TRACE2(( "this file doesn't contain any FNT resources\n" ));
error = FNT_Err_Invalid_File_Format;
goto Exit;
}
@@ -619,7 +619,7 @@
}
- static FT_UInt
+ static FT_UInt32
fnt_cmap_char_next( FNT_CMap cmap,
FT_UInt32 *pchar_code )
{
@@ -833,7 +833,7 @@
if ( font->header.face_name_offset >= font->header.file_size )
{
- FT_TRACE2(( "invalid family name offset!\n" ));
+ FT_TRACE2(( "invalid family name offset\n" ));
error = FNT_Err_Invalid_File_Format;
goto Fail;
}
@@ -980,7 +980,7 @@
if ( offset >= font->header.file_size )
{
- FT_TRACE2(( "invalid FNT offset!\n" ));
+ FT_TRACE2(( "invalid FNT offset\n" ));
error = FNT_Err_Invalid_File_Format;
goto Exit;
}
diff --git a/src/3rdparty/freetype/src/winfonts/winfnt.h b/src/3rdparty/freetype/src/winfonts/winfnt.h
index ca75c9501a..70a90861ab 100644
--- a/src/3rdparty/freetype/src/winfonts/winfnt.h
+++ b/src/3rdparty/freetype/src/winfonts/winfnt.h
@@ -28,6 +28,10 @@
FT_BEGIN_HEADER
+#ifdef FT_CONFIG_OPTION_PIC
+#error "this module does not support PIC yet"
+#endif
+
typedef struct WinMZ_HeaderRec_
{
FT_UShort magic;
diff --git a/src/3rdparty/harfbuzz/src/harfbuzz-arabic.c b/src/3rdparty/harfbuzz/src/harfbuzz-arabic.c
index 0293a5dadf..660939415b 100644
--- a/src/3rdparty/harfbuzz/src/harfbuzz-arabic.c
+++ b/src/3rdparty/harfbuzz/src/harfbuzz-arabic.c
@@ -1114,16 +1114,22 @@ HB_Bool HB_ArabicShape(HB_ShaperItem *item)
if (HB_SelectScript(item, item->item.script == HB_Script_Arabic ? arabic_features : syriac_features)) {
HB_Bool ot_ok;
- if (arabicSyriacOpenTypeShape(item, &ot_ok))
+ if (arabicSyriacOpenTypeShape(item, &ot_ok)) {
+ HB_FREE_STACKARRAY(shapedChars);
return TRUE;
- if (ot_ok)
+ }
+ if (ot_ok) {
+ HB_FREE_STACKARRAY(shapedChars);
return FALSE;
/* fall through to the non OT code*/
+ }
}
#endif
- if (item->item.script != HB_Script_Arabic)
+ if (item->item.script != HB_Script_Arabic) {
+ HB_FREE_STACKARRAY(shapedChars);
return HB_BasicShape(item);
+ }
shapedString(item->string, item->stringLength, item->item.pos, item->item.length, shapedChars, &slen,
item->item.bidiLevel % 2,
diff --git a/src/3rdparty/harfbuzz/src/harfbuzz-gpos.c b/src/3rdparty/harfbuzz/src/harfbuzz-gpos.c
index 21ffe84ab3..90e31a589c 100644
--- a/src/3rdparty/harfbuzz/src/harfbuzz-gpos.c
+++ b/src/3rdparty/harfbuzz/src/harfbuzz-gpos.c
@@ -3193,6 +3193,9 @@ static HB_Error Lookup_MarkMarkPos( GPOS_Instance* gpi,
j--;
}
+ if ( i > buffer->in_pos )
+ return HB_Err_Not_Covered;
+
error = _HB_OPEN_Coverage_Index( &mmp->Mark2Coverage, IN_GLYPH( j ),
&mark2_index );
if ( error )
@@ -3779,7 +3782,7 @@ static HB_Error Load_ContextPos2( HB_ContextPosFormat2* cpf2,
return HB_Err_Ok;
Fail1:
- for ( m = 0; m < n; n++ )
+ for ( m = 0; m < n; m++ )
Free_PosClassSet( &pcs[m] );
FREE( pcs );
@@ -5349,13 +5352,13 @@ static HB_Error Lookup_ChainContextPos2(
if ( error )
return error;
+ if (ccpf2->MaxInputLength < 1)
+ return HB_Err_Not_Covered;
+
if ( ALLOC_ARRAY( backtrack_classes, ccpf2->MaxBacktrackLength, HB_UShort ) )
return error;
known_backtrack_classes = 0;
- if (ccpf2->MaxInputLength < 1)
- return HB_Err_Not_Covered;
-
if ( ALLOC_ARRAY( input_classes, ccpf2->MaxInputLength, HB_UShort ) )
goto End3;
known_input_classes = 1;
diff --git a/src/3rdparty/harfbuzz/src/harfbuzz-gsub.c b/src/3rdparty/harfbuzz/src/harfbuzz-gsub.c
index 9b6b59875a..89875d1d24 100644
--- a/src/3rdparty/harfbuzz/src/harfbuzz-gsub.c
+++ b/src/3rdparty/harfbuzz/src/harfbuzz-gsub.c
@@ -3158,13 +3158,13 @@ static HB_Error Lookup_ChainContextSubst2( HB_GSUBHeader* gsub,
if ( error )
return error;
+ if (ccsf2->MaxInputLength < 1)
+ return HB_Err_Not_Covered;
+
if ( ALLOC_ARRAY( backtrack_classes, ccsf2->MaxBacktrackLength, HB_UShort ) )
return error;
known_backtrack_classes = 0;
- if (ccsf2->MaxInputLength < 1)
- return HB_Err_Not_Covered;
-
if ( ALLOC_ARRAY( input_classes, ccsf2->MaxInputLength, HB_UShort ) )
goto End3;
known_input_classes = 1;
diff --git a/src/3rdparty/harfbuzz/src/harfbuzz-indic.cpp b/src/3rdparty/harfbuzz/src/harfbuzz-indic.cpp
index 021d1ff4ae..31026829dd 100644
--- a/src/3rdparty/harfbuzz/src/harfbuzz-indic.cpp
+++ b/src/3rdparty/harfbuzz/src/harfbuzz-indic.cpp
@@ -37,7 +37,7 @@ static HB_Bool isLetter(HB_UChar16 ucs)
FLAG(HB_Letter_Titlecase) |
FLAG(HB_Letter_Modifier) |
FLAG(HB_Letter_Other);
- return (FLAG(HB_GetUnicodeCharCategory(ucs)) & test) != 0;
+ return !!(FLAG(HB_GetUnicodeCharCategory(ucs)) & test);
}
static HB_Bool isMark(HB_UChar16 ucs)
@@ -45,7 +45,7 @@ static HB_Bool isMark(HB_UChar16 ucs)
const int test = FLAG(HB_Mark_NonSpacing) |
FLAG(HB_Mark_SpacingCombining) |
FLAG(HB_Mark_Enclosing);
- return FLAG(HB_GetUnicodeCharCategory(ucs)) & test;
+ return !!(FLAG(HB_GetUnicodeCharCategory(ucs)) & test);
}
enum Form {
@@ -1683,6 +1683,7 @@ static bool indic_shape_syllable(HB_Bool openType, HB_ShaperItem *item, bool inv
}
item->glyphs[j] = item->glyphs[i];
item->attributes[j] = item->attributes[i];
+ item->offsets[j] = item->offsets[i];
item->advances[j] = item->advances[i];
++i;
++j;
diff --git a/src/3rdparty/harfbuzz/src/harfbuzz-myanmar.c b/src/3rdparty/harfbuzz/src/harfbuzz-myanmar.c
index 14a963a540..91a353f5c0 100644
--- a/src/3rdparty/harfbuzz/src/harfbuzz-myanmar.c
+++ b/src/3rdparty/harfbuzz/src/harfbuzz-myanmar.c
@@ -359,7 +359,8 @@ static HB_Bool myanmar_shape_syllable(HB_Bool openType, HB_ShaperItem *item, HB_
if (kinzi >= 0 && i > base && (cc & Mymr_CF_AFTER_KINZI)) {
reordered[len] = Mymr_C_NGA;
reordered[len+1] = Mymr_C_VIRAMA;
- properties[len-1] = AboveForm;
+ if (len > 0)
+ properties[len-1] = AboveForm;
properties[len] = AboveForm;
len += 2;
kinzi = -1;
diff --git a/src/3rdparty/harfbuzz/src/harfbuzz-shaper-private.h b/src/3rdparty/harfbuzz/src/harfbuzz-shaper-private.h
index e5ed380fe7..cd53c12ac6 100644
--- a/src/3rdparty/harfbuzz/src/harfbuzz-shaper-private.h
+++ b/src/3rdparty/harfbuzz/src/harfbuzz-shaper-private.h
@@ -142,7 +142,7 @@ void HB_HeuristicSetGlyphAttributes(HB_ShaperItem *item);
#define HB_IsControlChar(uc) \
((uc >= 0x200b && uc <= 0x200f /* ZW Space, ZWNJ, ZWJ, LRM and RLM */) \
- || (uc >= 0x2028 && uc <= 0x202f /* LS, PS, LRE, RLE, PDF, LRO, RLO, NNBSP */) \
+ || (uc >= 0x2028 && uc <= 0x202e /* LS, PS, LRE, RLE, PDF, LRO, RLO */) \
|| (uc >= 0x206a && uc <= 0x206f /* ISS, ASS, IAFS, AFS, NADS, NODS */))
HB_Bool HB_ConvertStringToGlyphIndices(HB_ShaperItem *shaper_item);
diff --git a/src/3rdparty/harfbuzz/src/harfbuzz-shaper.cpp b/src/3rdparty/harfbuzz/src/harfbuzz-shaper.cpp
index 70efc76d7e..4ffaaee235 100644
--- a/src/3rdparty/harfbuzz/src/harfbuzz-shaper.cpp
+++ b/src/3rdparty/harfbuzz/src/harfbuzz-shaper.cpp
@@ -1033,7 +1033,7 @@ HB_Bool HB_OpenTypePosition(HB_ShaperItem *item, int availableGlyphs, HB_Bool do
adjustment = HB_FIXED_ROUND(adjustment);
if (positions[i].new_advance) {
- advances[i] = adjustment;
+ ; //advances[i] = adjustment;
} else {
advances[i] += adjustment;
}
diff --git a/src/3rdparty/harfbuzz/src/harfbuzz-tibetan.c b/src/3rdparty/harfbuzz/src/harfbuzz-tibetan.c
index b745f22332..7dc4cebfb2 100644
--- a/src/3rdparty/harfbuzz/src/harfbuzz-tibetan.c
+++ b/src/3rdparty/harfbuzz/src/harfbuzz-tibetan.c
@@ -90,7 +90,7 @@ static const unsigned char tibetanForm[0x80] = {
#define tibetan_form(c) \
- (TibetanForm)tibetanForm[c - 0x0f40]
+ ((c) >= 0x0f40 && (c) < 0x0fc0 ? (TibetanForm)tibetanForm[(c) - 0x0f40] : TibetanOther)
#ifndef NO_OPENTYPE
static const HB_OpenTypeFeature tibetan_features[] = {
@@ -115,6 +115,7 @@ static HB_Bool tibetan_shape_syllable(HB_Bool openType, HB_ShaperItem *item, HB_
if (item->num_glyphs < item->item.length + 4) {
item->num_glyphs = item->item.length + 4;
+ HB_FREE_STACKARRAY(reordered);
return FALSE;
}
diff --git a/src/3rdparty/pcre.pri b/src/3rdparty/pcre.pri
index 6ab9d4dc87..8928c045fa 100644
--- a/src/3rdparty/pcre.pri
+++ b/src/3rdparty/pcre.pri
@@ -1,6 +1,8 @@
DEFINES += PCRE_HAVE_CONFIG_H
win32:DEFINES += PCRE_STATIC
+ios:DEFINES += PCRE_DISABLE_JIT
+qnx:DEFINES += PCRE_DISABLE_JIT
INCLUDEPATH += $$PWD/pcre
SOURCES += \
diff --git a/src/3rdparty/pcre/config.h b/src/3rdparty/pcre/config.h
index 6dda704f68..ed388fc9ba 100644
--- a/src/3rdparty/pcre/config.h
+++ b/src/3rdparty/pcre/config.h
@@ -20,7 +20,7 @@
- x86/x86-64
- MIPS 32bit (__GNUC__ compilers only)
*/
-#if \
+#if !defined(PCRE_DISABLE_JIT) && (\
/* ARM */ \
(defined(__GNUC__) && (defined(__arm__) || defined(__TARGET_ARCH_ARM))) \
/* x86 32/64 */ \
@@ -29,6 +29,6 @@
/* MIPS32 */ \
|| (defined(__GNUC__) \
&& (defined(__mips) || defined(__mips__)) \
- && !(defined(_MIPS_ARCH_MIPS64) || defined(__mips64)))
+ && !(defined(_MIPS_ARCH_MIPS64) || defined(__mips64))))
# define SUPPORT_JIT
#endif
diff --git a/src/3rdparty/pcre/import_from_pcre_tarball.sh b/src/3rdparty/pcre/import_from_pcre_tarball.sh
index 137dc9432a..5710e36a0f 100755
--- a/src/3rdparty/pcre/import_from_pcre_tarball.sh
+++ b/src/3rdparty/pcre/import_from_pcre_tarball.sh
@@ -131,22 +131,24 @@ FILES="
pcre16_valid_utf16.c
pcre16_version.c
pcre16_xclass.c
+ sljit/sljitConfig.h
+ sljit/sljitConfigInternal.h
+ sljit/sljitExecAllocator.c
sljit/sljitLir.c
sljit/sljitLir.h
- sljit/sljitNativePPC_common.c
- sljit/sljitNativeX86_common.c
+ sljit/sljitNativeARM_Thumb2.c
sljit/sljitNativeARM_v5.c
- sljit/sljitNativeX86_32.c
- sljit/sljitNativeX86_64.c
+ sljit/sljitNativeMIPS_32.c
+ sljit/sljitNativeMIPS_common.c
sljit/sljitNativePPC_32.c
sljit/sljitNativePPC_64.c
- sljit/sljitConfig.h
- sljit/sljitNativeMIPS_32.c
+ sljit/sljitNativePPC_common.c
+ sljit/sljitNativeSPARC_32.c
+ sljit/sljitNativeSPARC_common.c
+ sljit/sljitNativeX86_32.c
+ sljit/sljitNativeX86_64.c
+ sljit/sljitNativeX86_common.c
sljit/sljitUtils.c
- sljit/sljitNativeMIPS_common.c
- sljit/sljitExecAllocator.c
- sljit/sljitConfigInternal.h
- sljit/sljitNativeARM_Thumb2.c
"
for i in $FILES; do
diff --git a/src/3rdparty/pcre/pcre.h b/src/3rdparty/pcre/pcre.h
index 712bd3d714..a6aa4e934b 100644
--- a/src/3rdparty/pcre/pcre.h
+++ b/src/3rdparty/pcre/pcre.h
@@ -42,9 +42,9 @@ POSSIBILITY OF SUCH DAMAGE.
/* The current PCRE version information. */
#define PCRE_MAJOR 8
-#define PCRE_MINOR 30
+#define PCRE_MINOR 32
#define PCRE_PRERELEASE
-#define PCRE_DATE 2012-02-04
+#define PCRE_DATE 2012-11-30
/* When an application links to a PCRE DLL in Windows, the symbols that are
imported have to be identified as such. When building PCRE, the appropriate
@@ -95,54 +95,70 @@ it is needed here for malloc. */
extern "C" {
#endif
-/* Options. Some are compile-time only, some are run-time only, and some are
-both, so we keep them all distinct. However, almost all the bits in the options
-word are now used. In the long run, we may have to re-use some of the
-compile-time only bits for runtime options, or vice versa. In the comments
-below, "compile", "exec", and "DFA exec" mean that the option is permitted to
-be set for those functions; "used in" means that an option may be set only for
-compile, but is subsequently referenced in exec and/or DFA exec. Any of the
+/* Public options. Some are compile-time only, some are run-time only, and some
+are both, so we keep them all distinct. However, almost all the bits in the
+options word are now used. In the long run, we may have to re-use some of the
+compile-time only bits for runtime options, or vice versa. Any of the
compile-time options may be inspected during studying (and therefore JIT
-compiling). */
-
-#define PCRE_CASELESS 0x00000001 /* Compile */
-#define PCRE_MULTILINE 0x00000002 /* Compile */
-#define PCRE_DOTALL 0x00000004 /* Compile */
-#define PCRE_EXTENDED 0x00000008 /* Compile */
-#define PCRE_ANCHORED 0x00000010 /* Compile, exec, DFA exec */
-#define PCRE_DOLLAR_ENDONLY 0x00000020 /* Compile, used in exec, DFA exec */
-#define PCRE_EXTRA 0x00000040 /* Compile */
-#define PCRE_NOTBOL 0x00000080 /* Exec, DFA exec */
-#define PCRE_NOTEOL 0x00000100 /* Exec, DFA exec */
-#define PCRE_UNGREEDY 0x00000200 /* Compile */
-#define PCRE_NOTEMPTY 0x00000400 /* Exec, DFA exec */
-/* The next two are also used in exec and DFA exec */
-#define PCRE_UTF8 0x00000800 /* Compile (same as PCRE_UTF16) */
-#define PCRE_UTF16 0x00000800 /* Compile (same as PCRE_UTF8) */
-#define PCRE_NO_AUTO_CAPTURE 0x00001000 /* Compile */
-/* The next two are also used in exec and DFA exec */
-#define PCRE_NO_UTF8_CHECK 0x00002000 /* Compile (same as PCRE_NO_UTF16_CHECK) */
-#define PCRE_NO_UTF16_CHECK 0x00002000 /* Compile (same as PCRE_NO_UTF8_CHECK) */
-#define PCRE_AUTO_CALLOUT 0x00004000 /* Compile */
-#define PCRE_PARTIAL_SOFT 0x00008000 /* Exec, DFA exec */
-#define PCRE_PARTIAL 0x00008000 /* Backwards compatible synonym */
-#define PCRE_DFA_SHORTEST 0x00010000 /* DFA exec */
-#define PCRE_DFA_RESTART 0x00020000 /* DFA exec */
-#define PCRE_FIRSTLINE 0x00040000 /* Compile, used in exec, DFA exec */
-#define PCRE_DUPNAMES 0x00080000 /* Compile */
-#define PCRE_NEWLINE_CR 0x00100000 /* Compile, exec, DFA exec */
-#define PCRE_NEWLINE_LF 0x00200000 /* Compile, exec, DFA exec */
-#define PCRE_NEWLINE_CRLF 0x00300000 /* Compile, exec, DFA exec */
-#define PCRE_NEWLINE_ANY 0x00400000 /* Compile, exec, DFA exec */
-#define PCRE_NEWLINE_ANYCRLF 0x00500000 /* Compile, exec, DFA exec */
-#define PCRE_BSR_ANYCRLF 0x00800000 /* Compile, exec, DFA exec */
-#define PCRE_BSR_UNICODE 0x01000000 /* Compile, exec, DFA exec */
-#define PCRE_JAVASCRIPT_COMPAT 0x02000000 /* Compile, used in exec */
-#define PCRE_NO_START_OPTIMIZE 0x04000000 /* Compile, exec, DFA exec */
-#define PCRE_NO_START_OPTIMISE 0x04000000 /* Synonym */
-#define PCRE_PARTIAL_HARD 0x08000000 /* Exec, DFA exec */
-#define PCRE_NOTEMPTY_ATSTART 0x10000000 /* Exec, DFA exec */
-#define PCRE_UCP 0x20000000 /* Compile, used in exec, DFA exec */
+compiling).
+
+Some options for pcre_compile() change its behaviour but do not affect the
+behaviour of the execution functions. Other options are passed through to the
+execution functions and affect their behaviour, with or without affecting the
+behaviour of pcre_compile().
+
+Options that can be passed to pcre_compile() are tagged Cx below, with these
+variants:
+
+C1 Affects compile only
+C2 Does not affect compile; affects exec, dfa_exec
+C3 Affects compile, exec, dfa_exec
+C4 Affects compile, exec, dfa_exec, study
+C5 Affects compile, exec, study
+
+Options that can be set for pcre_exec() and/or pcre_dfa_exec() are flagged with
+E and D, respectively. They take precedence over C3, C4, and C5 settings passed
+from pcre_compile(). Those that are compatible with JIT execution are flagged
+with J. */
+
+#define PCRE_CASELESS 0x00000001 /* C1 */
+#define PCRE_MULTILINE 0x00000002 /* C1 */
+#define PCRE_DOTALL 0x00000004 /* C1 */
+#define PCRE_EXTENDED 0x00000008 /* C1 */
+#define PCRE_ANCHORED 0x00000010 /* C4 E D */
+#define PCRE_DOLLAR_ENDONLY 0x00000020 /* C2 */
+#define PCRE_EXTRA 0x00000040 /* C1 */
+#define PCRE_NOTBOL 0x00000080 /* E D J */
+#define PCRE_NOTEOL 0x00000100 /* E D J */
+#define PCRE_UNGREEDY 0x00000200 /* C1 */
+#define PCRE_NOTEMPTY 0x00000400 /* E D J */
+#define PCRE_UTF8 0x00000800 /* C4 ) */
+#define PCRE_UTF16 0x00000800 /* C4 ) Synonyms */
+#define PCRE_UTF32 0x00000800 /* C4 ) */
+#define PCRE_NO_AUTO_CAPTURE 0x00001000 /* C1 */
+#define PCRE_NO_UTF8_CHECK 0x00002000 /* C1 E D J ) */
+#define PCRE_NO_UTF16_CHECK 0x00002000 /* C1 E D J ) Synonyms */
+#define PCRE_NO_UTF32_CHECK 0x00002000 /* C1 E D J ) */
+#define PCRE_AUTO_CALLOUT 0x00004000 /* C1 */
+#define PCRE_PARTIAL_SOFT 0x00008000 /* E D J ) Synonyms */
+#define PCRE_PARTIAL 0x00008000 /* E D J ) */
+#define PCRE_DFA_SHORTEST 0x00010000 /* D */
+#define PCRE_DFA_RESTART 0x00020000 /* D */
+#define PCRE_FIRSTLINE 0x00040000 /* C3 */
+#define PCRE_DUPNAMES 0x00080000 /* C1 */
+#define PCRE_NEWLINE_CR 0x00100000 /* C3 E D */
+#define PCRE_NEWLINE_LF 0x00200000 /* C3 E D */
+#define PCRE_NEWLINE_CRLF 0x00300000 /* C3 E D */
+#define PCRE_NEWLINE_ANY 0x00400000 /* C3 E D */
+#define PCRE_NEWLINE_ANYCRLF 0x00500000 /* C3 E D */
+#define PCRE_BSR_ANYCRLF 0x00800000 /* C3 E D */
+#define PCRE_BSR_UNICODE 0x01000000 /* C3 E D */
+#define PCRE_JAVASCRIPT_COMPAT 0x02000000 /* C5 */
+#define PCRE_NO_START_OPTIMIZE 0x04000000 /* C2 E D ) Synonyms */
+#define PCRE_NO_START_OPTIMISE 0x04000000 /* C2 E D ) */
+#define PCRE_PARTIAL_HARD 0x08000000 /* E D J */
+#define PCRE_NOTEMPTY_ATSTART 0x10000000 /* E D J */
+#define PCRE_UCP 0x20000000 /* C3 */
/* Exec-time and get/set-time error codes */
@@ -156,8 +172,9 @@ compiling). */
#define PCRE_ERROR_NOSUBSTRING (-7)
#define PCRE_ERROR_MATCHLIMIT (-8)
#define PCRE_ERROR_CALLOUT (-9) /* Never used by PCRE itself */
-#define PCRE_ERROR_BADUTF8 (-10) /* Same for 8/16 */
-#define PCRE_ERROR_BADUTF16 (-10) /* Same for 8/16 */
+#define PCRE_ERROR_BADUTF8 (-10) /* Same for 8/16/32 */
+#define PCRE_ERROR_BADUTF16 (-10) /* Same for 8/16/32 */
+#define PCRE_ERROR_BADUTF32 (-10) /* Same for 8/16/32 */
#define PCRE_ERROR_BADUTF8_OFFSET (-11) /* Same for 8/16 */
#define PCRE_ERROR_BADUTF16_OFFSET (-11) /* Same for 8/16 */
#define PCRE_ERROR_PARTIAL (-12)
@@ -179,6 +196,9 @@ compiling). */
#define PCRE_ERROR_JIT_STACKLIMIT (-27)
#define PCRE_ERROR_BADMODE (-28)
#define PCRE_ERROR_BADENDIANNESS (-29)
+#define PCRE_ERROR_DFA_BADRESTART (-30)
+#define PCRE_ERROR_JIT_BADOPTION (-31)
+#define PCRE_ERROR_BADLENGTH (-32)
/* Specific error codes for UTF-8 validity checks */
@@ -204,6 +224,7 @@ compiling). */
#define PCRE_UTF8_ERR19 19
#define PCRE_UTF8_ERR20 20
#define PCRE_UTF8_ERR21 21
+#define PCRE_UTF8_ERR22 22
/* Specific error codes for UTF-16 validity checks */
@@ -213,6 +234,13 @@ compiling). */
#define PCRE_UTF16_ERR3 3
#define PCRE_UTF16_ERR4 4
+/* Specific error codes for UTF-32 validity checks */
+
+#define PCRE_UTF32_ERR0 0
+#define PCRE_UTF32_ERR1 1
+#define PCRE_UTF32_ERR2 2
+#define PCRE_UTF32_ERR3 3
+
/* Request types for pcre_fullinfo() */
#define PCRE_INFO_OPTIONS 0
@@ -234,6 +262,11 @@ compiling). */
#define PCRE_INFO_MINLENGTH 15
#define PCRE_INFO_JIT 16
#define PCRE_INFO_JITSIZE 17
+#define PCRE_INFO_MAXLOOKBEHIND 18
+#define PCRE_INFO_FIRSTCHARACTER 19
+#define PCRE_INFO_FIRSTCHARACTERFLAGS 20
+#define PCRE_INFO_REQUIREDCHAR 21
+#define PCRE_INFO_REQUIREDCHARFLAGS 22
/* Request types for pcre_config(). Do not re-arrange, in order to remain
compatible. */
@@ -250,13 +283,17 @@ compatible. */
#define PCRE_CONFIG_JIT 9
#define PCRE_CONFIG_UTF16 10
#define PCRE_CONFIG_JITTARGET 11
+#define PCRE_CONFIG_UTF32 12
/* Request types for pcre_study(). Do not re-arrange, in order to remain
compatible. */
-#define PCRE_STUDY_JIT_COMPILE 0x0001
+#define PCRE_STUDY_JIT_COMPILE 0x0001
+#define PCRE_STUDY_JIT_PARTIAL_SOFT_COMPILE 0x0002
+#define PCRE_STUDY_JIT_PARTIAL_HARD_COMPILE 0x0004
+#define PCRE_STUDY_EXTRA_NEEDED 0x0008
-/* Bit flags for the pcre[16]_extra structure. Do not re-arrange or redefine
+/* Bit flags for the pcre[16|32]_extra structure. Do not re-arrange or redefine
these bits, just add new ones on the end, in order to remain compatible. */
#define PCRE_EXTRA_STUDY_DATA 0x0001
@@ -275,12 +312,18 @@ typedef struct real_pcre pcre;
struct real_pcre16; /* declaration; the definition is private */
typedef struct real_pcre16 pcre16;
+struct real_pcre32; /* declaration; the definition is private */
+typedef struct real_pcre32 pcre32;
+
struct real_pcre_jit_stack; /* declaration; the definition is private */
typedef struct real_pcre_jit_stack pcre_jit_stack;
struct real_pcre16_jit_stack; /* declaration; the definition is private */
typedef struct real_pcre16_jit_stack pcre16_jit_stack;
+struct real_pcre32_jit_stack; /* declaration; the definition is private */
+typedef struct real_pcre32_jit_stack pcre32_jit_stack;
+
/* If PCRE is compiled with 16 bit character support, PCRE_UCHAR16 must contain
a 16 bit wide signed data type. Otherwise it can be a dummy data type since
pcre16 functions are not implemented. There is a check for this in pcre_internal.h. */
@@ -292,6 +335,17 @@ pcre16 functions are not implemented. There is a check for this in pcre_internal
#define PCRE_SPTR16 const PCRE_UCHAR16 *
#endif
+/* If PCRE is compiled with 32 bit character support, PCRE_UCHAR32 must contain
+a 32 bit wide signed data type. Otherwise it can be a dummy data type since
+pcre32 functions are not implemented. There is a check for this in pcre_internal.h. */
+#ifndef PCRE_UCHAR32
+#define PCRE_UCHAR32 unsigned int
+#endif
+
+#ifndef PCRE_SPTR32
+#define PCRE_SPTR32 const PCRE_UCHAR32 *
+#endif
+
/* When PCRE is compiled as a C++ library, the subject pointer type can be
replaced with a custom type. For conventional use, the public interface is a
const char *. */
@@ -328,6 +382,19 @@ typedef struct pcre16_extra {
void *executable_jit; /* Contains a pointer to a compiled jit code */
} pcre16_extra;
+/* Same structure as above, but with 32 bit char pointers. */
+
+typedef struct pcre32_extra {
+ unsigned long int flags; /* Bits for which fields are set */
+ void *study_data; /* Opaque data from pcre_study() */
+ unsigned long int match_limit; /* Maximum number of calls to match() */
+ void *callout_data; /* Data passed back in callouts */
+ const unsigned char *tables; /* Pointer to character tables */
+ unsigned long int match_limit_recursion; /* Max recursive calls to match() */
+ PCRE_UCHAR32 **mark; /* For passing back a mark pointer */
+ void *executable_jit; /* Contains a pointer to a compiled jit code */
+} pcre32_extra;
+
/* The structure for passing out data via the pcre_callout_function. We use a
structure so that new fields can be added on the end in future versions,
without changing the API of the function, thereby allowing old clients to work
@@ -375,6 +442,28 @@ typedef struct pcre16_callout_block {
/* ------------------------------------------------------------------ */
} pcre16_callout_block;
+/* Same structure as above, but with 32 bit char pointers. */
+
+typedef struct pcre32_callout_block {
+ int version; /* Identifies version of block */
+ /* ------------------------ Version 0 ------------------------------- */
+ int callout_number; /* Number compiled into pattern */
+ int *offset_vector; /* The offset vector */
+ PCRE_SPTR32 subject; /* The subject being matched */
+ int subject_length; /* The length of the subject */
+ int start_match; /* Offset to start of this match attempt */
+ int current_position; /* Where we currently are in the subject */
+ int capture_top; /* Max current capture */
+ int capture_last; /* Most recently closed capture */
+ void *callout_data; /* Data passed in with the call */
+ /* ------------------- Added for Version 1 -------------------------- */
+ int pattern_position; /* Offset to next item in the pattern */
+ int next_item_length; /* Length of next item in the pattern */
+ /* ------------------- Added for Version 2 -------------------------- */
+ const PCRE_UCHAR32 *mark; /* Pointer to current mark or NULL */
+ /* ------------------------------------------------------------------ */
+} pcre32_callout_block;
+
/* Indirection for store get and free functions. These can be set to
alternative malloc/free functions if required. Special ones are used in the
non-recursive case for "frames". There is also an optional callout function
@@ -393,6 +482,12 @@ PCRE_EXP_DECL void (*pcre16_free)(void *);
PCRE_EXP_DECL void *(*pcre16_stack_malloc)(size_t);
PCRE_EXP_DECL void (*pcre16_stack_free)(void *);
PCRE_EXP_DECL int (*pcre16_callout)(pcre16_callout_block *);
+
+PCRE_EXP_DECL void *(*pcre32_malloc)(size_t);
+PCRE_EXP_DECL void (*pcre32_free)(void *);
+PCRE_EXP_DECL void *(*pcre32_stack_malloc)(size_t);
+PCRE_EXP_DECL void (*pcre32_stack_free)(void *);
+PCRE_EXP_DECL int (*pcre32_callout)(pcre32_callout_block *);
#else /* VPCOMPAT */
PCRE_EXP_DECL void *pcre_malloc(size_t);
PCRE_EXP_DECL void pcre_free(void *);
@@ -405,12 +500,19 @@ PCRE_EXP_DECL void pcre16_free(void *);
PCRE_EXP_DECL void *pcre16_stack_malloc(size_t);
PCRE_EXP_DECL void pcre16_stack_free(void *);
PCRE_EXP_DECL int pcre16_callout(pcre16_callout_block *);
+
+PCRE_EXP_DECL void *pcre32_malloc(size_t);
+PCRE_EXP_DECL void pcre32_free(void *);
+PCRE_EXP_DECL void *pcre32_stack_malloc(size_t);
+PCRE_EXP_DECL void pcre32_stack_free(void *);
+PCRE_EXP_DECL int pcre32_callout(pcre32_callout_block *);
#endif /* VPCOMPAT */
/* User defined callback which provides a stack just before the match starts. */
typedef pcre_jit_stack *(*pcre_jit_callback)(void *);
typedef pcre16_jit_stack *(*pcre16_jit_callback)(void *);
+typedef pcre32_jit_stack *(*pcre32_jit_callback)(void *);
/* Exported PCRE functions */
@@ -418,83 +520,131 @@ PCRE_EXP_DECL pcre *pcre_compile(const char *, int, const char **, int *,
const unsigned char *);
PCRE_EXP_DECL pcre16 *pcre16_compile(PCRE_SPTR16, int, const char **, int *,
const unsigned char *);
+PCRE_EXP_DECL pcre32 *pcre32_compile(PCRE_SPTR32, int, const char **, int *,
+ const unsigned char *);
PCRE_EXP_DECL pcre *pcre_compile2(const char *, int, int *, const char **,
int *, const unsigned char *);
PCRE_EXP_DECL pcre16 *pcre16_compile2(PCRE_SPTR16, int, int *, const char **,
int *, const unsigned char *);
+PCRE_EXP_DECL pcre32 *pcre32_compile2(PCRE_SPTR32, int, int *, const char **,
+ int *, const unsigned char *);
PCRE_EXP_DECL int pcre_config(int, void *);
PCRE_EXP_DECL int pcre16_config(int, void *);
+PCRE_EXP_DECL int pcre32_config(int, void *);
PCRE_EXP_DECL int pcre_copy_named_substring(const pcre *, const char *,
int *, int, const char *, char *, int);
PCRE_EXP_DECL int pcre16_copy_named_substring(const pcre16 *, PCRE_SPTR16,
int *, int, PCRE_SPTR16, PCRE_UCHAR16 *, int);
+PCRE_EXP_DECL int pcre32_copy_named_substring(const pcre32 *, PCRE_SPTR32,
+ int *, int, PCRE_SPTR32, PCRE_UCHAR32 *, int);
PCRE_EXP_DECL int pcre_copy_substring(const char *, int *, int, int,
char *, int);
PCRE_EXP_DECL int pcre16_copy_substring(PCRE_SPTR16, int *, int, int,
PCRE_UCHAR16 *, int);
+PCRE_EXP_DECL int pcre32_copy_substring(PCRE_SPTR32, int *, int, int,
+ PCRE_UCHAR32 *, int);
PCRE_EXP_DECL int pcre_dfa_exec(const pcre *, const pcre_extra *,
const char *, int, int, int, int *, int , int *, int);
PCRE_EXP_DECL int pcre16_dfa_exec(const pcre16 *, const pcre16_extra *,
PCRE_SPTR16, int, int, int, int *, int , int *, int);
+PCRE_EXP_DECL int pcre32_dfa_exec(const pcre32 *, const pcre32_extra *,
+ PCRE_SPTR32, int, int, int, int *, int , int *, int);
PCRE_EXP_DECL int pcre_exec(const pcre *, const pcre_extra *, PCRE_SPTR,
int, int, int, int *, int);
PCRE_EXP_DECL int pcre16_exec(const pcre16 *, const pcre16_extra *,
PCRE_SPTR16, int, int, int, int *, int);
+PCRE_EXP_DECL int pcre32_exec(const pcre32 *, const pcre32_extra *,
+ PCRE_SPTR32, int, int, int, int *, int);
+PCRE_EXP_DECL int pcre_jit_exec(const pcre *, const pcre_extra *,
+ PCRE_SPTR, int, int, int, int *, int,
+ pcre_jit_stack *);
+PCRE_EXP_DECL int pcre16_jit_exec(const pcre16 *, const pcre16_extra *,
+ PCRE_SPTR16, int, int, int, int *, int,
+ pcre16_jit_stack *);
+PCRE_EXP_DECL int pcre32_jit_exec(const pcre32 *, const pcre32_extra *,
+ PCRE_SPTR32, int, int, int, int *, int,
+ pcre32_jit_stack *);
PCRE_EXP_DECL void pcre_free_substring(const char *);
PCRE_EXP_DECL void pcre16_free_substring(PCRE_SPTR16);
+PCRE_EXP_DECL void pcre32_free_substring(PCRE_SPTR32);
PCRE_EXP_DECL void pcre_free_substring_list(const char **);
PCRE_EXP_DECL void pcre16_free_substring_list(PCRE_SPTR16 *);
+PCRE_EXP_DECL void pcre32_free_substring_list(PCRE_SPTR32 *);
PCRE_EXP_DECL int pcre_fullinfo(const pcre *, const pcre_extra *, int,
void *);
PCRE_EXP_DECL int pcre16_fullinfo(const pcre16 *, const pcre16_extra *, int,
void *);
+PCRE_EXP_DECL int pcre32_fullinfo(const pcre32 *, const pcre32_extra *, int,
+ void *);
PCRE_EXP_DECL int pcre_get_named_substring(const pcre *, const char *,
int *, int, const char *, const char **);
PCRE_EXP_DECL int pcre16_get_named_substring(const pcre16 *, PCRE_SPTR16,
int *, int, PCRE_SPTR16, PCRE_SPTR16 *);
+PCRE_EXP_DECL int pcre32_get_named_substring(const pcre32 *, PCRE_SPTR32,
+ int *, int, PCRE_SPTR32, PCRE_SPTR32 *);
PCRE_EXP_DECL int pcre_get_stringnumber(const pcre *, const char *);
PCRE_EXP_DECL int pcre16_get_stringnumber(const pcre16 *, PCRE_SPTR16);
+PCRE_EXP_DECL int pcre32_get_stringnumber(const pcre32 *, PCRE_SPTR32);
PCRE_EXP_DECL int pcre_get_stringtable_entries(const pcre *, const char *,
char **, char **);
PCRE_EXP_DECL int pcre16_get_stringtable_entries(const pcre16 *, PCRE_SPTR16,
PCRE_UCHAR16 **, PCRE_UCHAR16 **);
+PCRE_EXP_DECL int pcre32_get_stringtable_entries(const pcre32 *, PCRE_SPTR32,
+ PCRE_UCHAR32 **, PCRE_UCHAR32 **);
PCRE_EXP_DECL int pcre_get_substring(const char *, int *, int, int,
const char **);
PCRE_EXP_DECL int pcre16_get_substring(PCRE_SPTR16, int *, int, int,
PCRE_SPTR16 *);
+PCRE_EXP_DECL int pcre32_get_substring(PCRE_SPTR32, int *, int, int,
+ PCRE_SPTR32 *);
PCRE_EXP_DECL int pcre_get_substring_list(const char *, int *, int,
const char ***);
PCRE_EXP_DECL int pcre16_get_substring_list(PCRE_SPTR16, int *, int,
PCRE_SPTR16 **);
+PCRE_EXP_DECL int pcre32_get_substring_list(PCRE_SPTR32, int *, int,
+ PCRE_SPTR32 **);
PCRE_EXP_DECL const unsigned char *pcre_maketables(void);
PCRE_EXP_DECL const unsigned char *pcre16_maketables(void);
+PCRE_EXP_DECL const unsigned char *pcre32_maketables(void);
PCRE_EXP_DECL int pcre_refcount(pcre *, int);
PCRE_EXP_DECL int pcre16_refcount(pcre16 *, int);
+PCRE_EXP_DECL int pcre32_refcount(pcre32 *, int);
PCRE_EXP_DECL pcre_extra *pcre_study(const pcre *, int, const char **);
PCRE_EXP_DECL pcre16_extra *pcre16_study(const pcre16 *, int, const char **);
+PCRE_EXP_DECL pcre32_extra *pcre32_study(const pcre32 *, int, const char **);
PCRE_EXP_DECL void pcre_free_study(pcre_extra *);
PCRE_EXP_DECL void pcre16_free_study(pcre16_extra *);
+PCRE_EXP_DECL void pcre32_free_study(pcre32_extra *);
PCRE_EXP_DECL const char *pcre_version(void);
PCRE_EXP_DECL const char *pcre16_version(void);
+PCRE_EXP_DECL const char *pcre32_version(void);
/* Utility functions for byte order swaps. */
PCRE_EXP_DECL int pcre_pattern_to_host_byte_order(pcre *, pcre_extra *,
const unsigned char *);
PCRE_EXP_DECL int pcre16_pattern_to_host_byte_order(pcre16 *, pcre16_extra *,
const unsigned char *);
+PCRE_EXP_DECL int pcre32_pattern_to_host_byte_order(pcre32 *, pcre32_extra *,
+ const unsigned char *);
PCRE_EXP_DECL int pcre16_utf16_to_host_byte_order(PCRE_UCHAR16 *,
PCRE_SPTR16, int, int *, int);
+PCRE_EXP_DECL int pcre32_utf32_to_host_byte_order(PCRE_UCHAR32 *,
+ PCRE_SPTR32, int, int *, int);
/* JIT compiler related functions. */
PCRE_EXP_DECL pcre_jit_stack *pcre_jit_stack_alloc(int, int);
PCRE_EXP_DECL pcre16_jit_stack *pcre16_jit_stack_alloc(int, int);
+PCRE_EXP_DECL pcre32_jit_stack *pcre32_jit_stack_alloc(int, int);
PCRE_EXP_DECL void pcre_jit_stack_free(pcre_jit_stack *);
PCRE_EXP_DECL void pcre16_jit_stack_free(pcre16_jit_stack *);
+PCRE_EXP_DECL void pcre32_jit_stack_free(pcre32_jit_stack *);
PCRE_EXP_DECL void pcre_assign_jit_stack(pcre_extra *,
pcre_jit_callback, void *);
PCRE_EXP_DECL void pcre16_assign_jit_stack(pcre16_extra *,
pcre16_jit_callback, void *);
+PCRE_EXP_DECL void pcre32_assign_jit_stack(pcre32_extra *,
+ pcre32_jit_callback, void *);
#ifdef __cplusplus
} /* extern "C" */
diff --git a/src/3rdparty/pcre/pcre16_ord2utf16.c b/src/3rdparty/pcre/pcre16_ord2utf16.c
index 9f7db8661f..be91cb4477 100644
--- a/src/3rdparty/pcre/pcre16_ord2utf16.c
+++ b/src/3rdparty/pcre/pcre16_ord2utf16.c
@@ -64,16 +64,11 @@ Arguments:
Returns: number of characters placed in the buffer
*/
-int
+unsigned int
PRIV(ord2utf)(pcre_uint32 cvalue, pcre_uchar *buffer)
{
#ifdef SUPPORT_UTF
-/* Checking invalid cvalue character, encoded as invalid UTF-16 character.
-Should never happen in practice. */
-if ((cvalue & 0xf800) == 0xd800 || cvalue >= 0x110000)
- cvalue = 0xfffe;
-
if (cvalue <= 0xffff)
{
*buffer = (pcre_uchar)cvalue;
diff --git a/src/3rdparty/pcre/pcre16_utf16_utils.c b/src/3rdparty/pcre/pcre16_utf16_utils.c
index 7cfdbdd5ee..6cd6c3ea63 100644
--- a/src/3rdparty/pcre/pcre16_utf16_utils.c
+++ b/src/3rdparty/pcre/pcre16_utf16_utils.c
@@ -118,10 +118,11 @@ while (iptr < end)
if (host_byte_order != NULL)
*host_byte_order = host_bo;
-#else /* SUPPORT_UTF */
+#else /* Not SUPPORT_UTF */
(void)(output); /* Keep picky compilers happy */
(void)(input);
(void)(keep_boms);
+(void)(host_byte_order);
#endif /* SUPPORT_UTF */
return length;
}
diff --git a/src/3rdparty/pcre/pcre16_valid_utf16.c b/src/3rdparty/pcre/pcre16_valid_utf16.c
index 90b9f86770..1486dfac09 100644
--- a/src/3rdparty/pcre/pcre16_valid_utf16.c
+++ b/src/3rdparty/pcre/pcre16_valid_utf16.c
@@ -69,7 +69,7 @@ PCRE_UTF16_ERR0 No error
PCRE_UTF16_ERR1 Missing low surrogate at the end of the string
PCRE_UTF16_ERR2 Invalid low surrogate
PCRE_UTF16_ERR3 Isolated low surrogate
-PCRE_UTF16_ERR4 Not allowed character
+PCRE_UTF16_ERR4 Non-character
Arguments:
string points to the string
@@ -85,7 +85,7 @@ PRIV(valid_utf)(PCRE_PUCHAR string, int length, int *erroroffset)
{
#ifdef SUPPORT_UTF
register PCRE_PUCHAR p;
-register pcre_uchar c;
+register pcre_uint32 c;
if (length < 0)
{
@@ -101,9 +101,8 @@ for (p = string; length-- > 0; p++)
{
/* Normal UTF-16 code point. Neither high nor low surrogate. */
- /* This is probably a BOM from a different byte-order.
- Regardless, the string is rejected. */
- if (c == 0xfffe)
+ /* Check for non-characters */
+ if ((c & 0xfffeu) == 0xfffeu || (c >= 0xfdd0u && c <= 0xfdefu))
{
*erroroffset = p - string;
return PCRE_UTF16_ERR4;
@@ -126,6 +125,16 @@ for (p = string; length-- > 0; p++)
*erroroffset = p - string;
return PCRE_UTF16_ERR2;
}
+ else
+ {
+ /* Valid surrogate, but check for non-characters */
+ c = (((c & 0x3ffu) << 10) | (*p & 0x3ffu)) + 0x10000u;
+ if ((c & 0xfffeu) == 0xfffeu)
+ {
+ *erroroffset = p - string;
+ return PCRE_UTF16_ERR4;
+ }
+ }
}
else
{
@@ -138,6 +147,7 @@ for (p = string; length-- > 0; p++)
#else /* SUPPORT_UTF */
(void)(string); /* Keep picky compilers happy */
(void)(length);
+(void)(erroroffset);
#endif /* SUPPORT_UTF */
return PCRE_UTF16_ERR0; /* This indicates success */
diff --git a/src/3rdparty/pcre/pcre_byte_order.c b/src/3rdparty/pcre/pcre_byte_order.c
index 6f5fa742d6..9f8eec87a5 100644
--- a/src/3rdparty/pcre/pcre_byte_order.c
+++ b/src/3rdparty/pcre/pcre_byte_order.c
@@ -95,12 +95,15 @@ Arguments:
Returns: 0 if the swap is successful, negative on error
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DECL int pcre_pattern_to_host_byte_order(pcre *argument_re,
pcre_extra *extra_data, const unsigned char *tables)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DECL int pcre16_pattern_to_host_byte_order(pcre16 *argument_re,
pcre16_extra *extra_data, const unsigned char *tables)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DECL int pcre32_pattern_to_host_byte_order(pcre32 *argument_re,
+ pcre32_extra *extra_data, const unsigned char *tables)
#endif
{
REAL_PCRE *re = (REAL_PCRE *)argument_re;
@@ -108,10 +111,10 @@ pcre_study_data *study;
#ifndef COMPILE_PCRE8
pcre_uchar *ptr;
int length;
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && defined COMPILE_PCRE16
BOOL utf;
BOOL utf16_char;
-#endif /* SUPPORT_UTF */
+#endif /* SUPPORT_UTF && COMPILE_PCRE16 */
#endif /* !COMPILE_PCRE8 */
if (re == NULL) return PCRE_ERROR_NULL;
@@ -131,13 +134,22 @@ re->options = swap_uint32(re->options);
re->flags = swap_uint16(re->flags);
re->top_bracket = swap_uint16(re->top_bracket);
re->top_backref = swap_uint16(re->top_backref);
+#if defined COMPILE_PCRE8 || defined COMPILE_PCRE16
re->first_char = swap_uint16(re->first_char);
re->req_char = swap_uint16(re->req_char);
+#elif defined COMPILE_PCRE32
+re->first_char = swap_uint32(re->first_char);
+re->req_char = swap_uint32(re->req_char);
+#endif
re->name_table_offset = swap_uint16(re->name_table_offset);
re->name_entry_size = swap_uint16(re->name_entry_size);
re->name_count = swap_uint16(re->name_count);
re->ref_count = swap_uint16(re->ref_count);
re->tables = tables;
+#ifdef COMPILE_PCRE32
+re->dummy1 = swap_uint16(re->dummy1);
+re->dummy2 = swap_uint16(re->dummy2);
+#endif
if (extra_data != NULL && (extra_data->flags & PCRE_EXTRA_STUDY_DATA) != 0)
{
@@ -150,20 +162,24 @@ if (extra_data != NULL && (extra_data->flags & PCRE_EXTRA_STUDY_DATA) != 0)
#ifndef COMPILE_PCRE8
ptr = (pcre_uchar *)re + re->name_table_offset;
length = re->name_count * re->name_entry_size;
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && defined COMPILE_PCRE16
utf = (re->options & PCRE_UTF16) != 0;
utf16_char = FALSE;
-#endif
+#endif /* SUPPORT_UTF && COMPILE_PCRE16 */
while(TRUE)
{
/* Swap previous characters. */
while (length-- > 0)
{
+#if defined COMPILE_PCRE16
*ptr = swap_uint16(*ptr);
+#elif defined COMPILE_PCRE32
+ *ptr = swap_uint32(*ptr);
+#endif
ptr++;
}
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && defined COMPILE_PCRE16
if (utf16_char)
{
if (HAS_EXTRALEN(ptr[-1]))
@@ -178,13 +194,17 @@ while(TRUE)
/* Get next opcode. */
length = 0;
+#if defined COMPILE_PCRE16
*ptr = swap_uint16(*ptr);
+#elif defined COMPILE_PCRE32
+ *ptr = swap_uint32(*ptr);
+#endif
switch (*ptr)
{
case OP_END:
return 0;
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && defined COMPILE_PCRE16
case OP_CHAR:
case OP_CHARI:
case OP_NOT:
@@ -259,16 +279,26 @@ while(TRUE)
case OP_XCLASS:
/* Reverse the size of the XCLASS instance. */
ptr++;
+#if defined COMPILE_PCRE16
*ptr = swap_uint16(*ptr);
+#elif defined COMPILE_PCRE32
+ *ptr = swap_uint32(*ptr);
+#endif
+#ifndef COMPILE_PCRE32
if (LINK_SIZE > 1)
{
/* LINK_SIZE can be 1 or 2 in 16 bit mode. */
ptr++;
*ptr = swap_uint16(*ptr);
}
+#endif
ptr++;
length = (GET(ptr, -LINK_SIZE)) - (1 + LINK_SIZE + 1);
+#if defined COMPILE_PCRE16
*ptr = swap_uint16(*ptr);
+#elif defined COMPILE_PCRE32
+ *ptr = swap_uint32(*ptr);
+#endif
if ((*ptr & XCL_MAP) != 0)
{
/* Skip the character bit map. */
@@ -279,7 +309,7 @@ while(TRUE)
}
ptr++;
}
-/* Control should never reach here in 16 bit mode. */
+/* Control should never reach here in 16/32 bit mode. */
#endif /* !COMPILE_PCRE8 */
return 0;
diff --git a/src/3rdparty/pcre/pcre_compile.c b/src/3rdparty/pcre/pcre_compile.c
index b0c57ca122..b3b64fb7a0 100644
--- a/src/3rdparty/pcre/pcre_compile.c
+++ b/src/3rdparty/pcre/pcre_compile.c
@@ -53,7 +53,7 @@ supporting internal functions that are not used by other modules. */
#include "pcre_internal.h"
-/* When PCRE_DEBUG is defined, we need the pcre(16)_printint() function, which
+/* When PCRE_DEBUG is defined, we need the pcre(16|32)_printint() function, which
is also used by pcretest. PCRE_DEBUG is not defined when building a production
library. We do not need to select pcre16_printint.c specially, because the
COMPILE_PCREx macro will already be appropriately set. */
@@ -68,7 +68,7 @@ COMPILE_PCREx macro will already be appropriately set. */
/* Macro for setting individual bits in class bitmaps. */
-#define SETBIT(a,b) a[b/8] |= (1 << (b%8))
+#define SETBIT(a,b) a[(b)/8] |= (1 << ((b)&7))
/* Maximum length value to check against when making sure that the integer that
holds the compiled pattern length does not overflow. We make it a bit less than
@@ -77,6 +77,18 @@ to check them every time. */
#define OFLOW_MAX (INT_MAX - 20)
+/* Definitions to allow mutual recursion */
+
+static int
+ add_list_to_class(pcre_uint8 *, pcre_uchar **, int, compile_data *,
+ const pcre_uint32 *, unsigned int);
+
+static BOOL
+ compile_regex(int, pcre_uchar **, const pcre_uchar **, int *, BOOL, BOOL, int, int,
+ pcre_uint32 *, pcre_int32 *, pcre_uint32 *, pcre_int32 *, branch_chain *,
+ compile_data *, int *);
+
+
/*************************************************
* Code parameters and static tables *
@@ -110,8 +122,11 @@ overrun before it actually does run off the end of the data block. */
/* Private flags added to firstchar and reqchar. */
-#define REQ_CASELESS 0x10000000l /* Indicates caselessness */
-#define REQ_VARY 0x20000000l /* Reqchar followed non-literal item */
+#define REQ_CASELESS (1 << 0) /* Indicates caselessness */
+#define REQ_VARY (1 << 1) /* Reqchar followed non-literal item */
+/* Negative values for the firstchar and reqchar flags */
+#define REQ_UNSET (-2)
+#define REQ_NONE (-1)
/* Repeated character flags. */
@@ -489,6 +504,10 @@ static const char error_texts[] =
"too many forward references\0"
"disallowed Unicode code point (>= 0xd800 && <= 0xdfff)\0"
"invalid UTF-16 string\0"
+ /* 75 */
+ "name is too long in (*MARK), (*PRUNE), (*SKIP), or (*THEN)\0"
+ "character value in \\u.... sequence is too large\0"
+ "invalid UTF-32 string\0"
;
/* Table to identify digits and hex digits. This is used when compiling
@@ -628,13 +647,6 @@ static const pcre_uint8 ebcdic_chartab[] = { /* chartable partial dup */
#endif
-/* Definition to allow mutual recursion */
-
-static BOOL
- compile_regex(int, pcre_uchar **, const pcre_uchar **, int *, BOOL, BOOL, int, int,
- int *, int *, branch_chain *, compile_data *, int *);
-
-
/*************************************************
* Find an error text *
@@ -655,8 +667,8 @@ find_error_text(int n)
const char *s = error_texts;
for (; n > 0; n--)
{
- while (*s++ != 0) {};
- if (*s == 0) return "Error text not found (please report)";
+ while (*s++ != CHAR_NULL) {};
+ if (*s == CHAR_NULL) return "Error text not found (please report)";
}
return s;
}
@@ -739,33 +751,36 @@ return (*p == CHAR_RIGHT_CURLY_BRACKET);
*************************************************/
/* This function is called when a \ has been encountered. It either returns a
-positive value for a simple escape such as \n, or a negative value which
-encodes one of the more complicated things such as \d. A backreference to group
-n is returned as -(ESC_REF + n); ESC_REF is the highest ESC_xxx macro. When
-UTF-8 is enabled, a positive value greater than 255 may be returned. On entry,
-ptr is pointing at the \. On exit, it is on the final character of the escape
-sequence.
+positive value for a simple escape such as \n, or 0 for a data character
+which will be placed in chptr. A backreference to group n is returned as
+negative n. When UTF-8 is enabled, a positive value greater than 255 may
+be returned in chptr.
+On entry,ptr is pointing at the \. On exit, it is on the final character of the
+escape sequence.
Arguments:
ptrptr points to the pattern position pointer
+ chptr points to the data character
errorcodeptr points to the errorcode variable
bracount number of previous extracting brackets
options the options bits
isclass TRUE if inside a character class
-Returns: zero or positive => a data character
- negative => a special escape sequence
+Returns: zero => a data character
+ positive => a special escape sequence
+ negative => a back reference
on error, errorcodeptr is set
*/
static int
-check_escape(const pcre_uchar **ptrptr, int *errorcodeptr, int bracount,
- int options, BOOL isclass)
+check_escape(const pcre_uchar **ptrptr, pcre_uint32 *chptr, int *errorcodeptr,
+ int bracount, int options, BOOL isclass)
{
/* PCRE_UTF16 has the same value as PCRE_UTF8. */
BOOL utf = (options & PCRE_UTF8) != 0;
const pcre_uchar *ptr = *ptrptr + 1;
-pcre_int32 c;
+pcre_uint32 c;
+int escape = 0;
int i;
GETCHARINCTEST(c, ptr); /* Get character value, increment pointer */
@@ -773,7 +788,7 @@ ptr--; /* Set pointer back to the last byte */
/* If backslash is at the end of the pattern, it's an error. */
-if (c == 0) *errorcodeptr = ERR1;
+if (c == CHAR_NULL) *errorcodeptr = ERR1;
/* Non-alphanumerics are literals. For digits or letters, do an initial lookup
in a table. A non-zero result is something that can be returned immediately.
@@ -782,12 +797,12 @@ Otherwise further processing may be required. */
#ifndef EBCDIC /* ASCII/UTF-8 coding */
/* Not alphanumeric */
else if (c < CHAR_0 || c > CHAR_z) {}
-else if ((i = escapes[c - CHAR_0]) != 0) c = i;
+else if ((i = escapes[c - CHAR_0]) != 0) { if (i > 0) c = (pcre_uint32)i; else escape = -i; }
#else /* EBCDIC coding */
/* Not alphanumeric */
-else if (c < 'a' || (!MAX_255(c) || (ebcdic_chartab[c] & 0x0E) == 0)) {}
-else if ((i = escapes[c - 0x48]) != 0) c = i;
+else if (c < CHAR_a || (!MAX_255(c) || (ebcdic_chartab[c] & 0x0E) == 0)) {}
+else if ((i = escapes[c - 0x48]) != 0) { if (i > 0) c = (pcre_uint32)i; else escape = -i; }
#endif
/* Escapes that need further processing, or are illegal. */
@@ -795,7 +810,8 @@ else if ((i = escapes[c - 0x48]) != 0) c = i;
else
{
const pcre_uchar *oldptr;
- BOOL braced, negated;
+ BOOL braced, negated, overflow;
+ int s;
switch (c)
{
@@ -820,7 +836,7 @@ else
c = 0;
for (i = 0; i < 4; ++i)
{
- register int cc = *(++ptr);
+ register pcre_uint32 cc = *(++ptr);
#ifndef EBCDIC /* ASCII/UTF-8 coding */
if (cc >= CHAR_a) cc -= 32; /* Convert to upper case */
c = (c << 4) + cc - ((cc < CHAR_A)? CHAR_0 : (CHAR_A - 10));
@@ -829,6 +845,18 @@ else
c = (c << 4) + cc - ((cc >= CHAR_0)? CHAR_0 : (CHAR_A - 10));
#endif
}
+
+#if defined COMPILE_PCRE8
+ if (c > (utf ? 0x10ffff : 0xff))
+#elif defined COMPILE_PCRE16
+ if (c > (utf ? 0x10ffff : 0xffff))
+#elif defined COMPILE_PCRE32
+ if (utf && c > 0x10ffff)
+#endif
+ {
+ *errorcodeptr = ERR76;
+ }
+ else if (utf && c >= 0xd800 && c <= 0xdfff) *errorcodeptr = ERR73;
}
}
else
@@ -855,13 +883,13 @@ else
(3) For Oniguruma compatibility we also support \g followed by a name or a
number either in angle brackets or in single quotes. However, these are
(possibly recursive) subroutine calls, _not_ backreferences. Just return
- the -ESC_g code (cf \k). */
+ the ESC_g code (cf \k). */
case CHAR_g:
if (isclass) break;
if (ptr[1] == CHAR_LESS_THAN_SIGN || ptr[1] == CHAR_APOSTROPHE)
{
- c = -ESC_g;
+ escape = ESC_g;
break;
}
@@ -870,11 +898,11 @@ else
if (ptr[1] == CHAR_LEFT_CURLY_BRACKET)
{
const pcre_uchar *p;
- for (p = ptr+2; *p != 0 && *p != CHAR_RIGHT_CURLY_BRACKET; p++)
+ for (p = ptr+2; *p != CHAR_NULL && *p != CHAR_RIGHT_CURLY_BRACKET; p++)
if (*p != CHAR_MINUS && !IS_DIGIT(*p)) break;
- if (*p != 0 && *p != CHAR_RIGHT_CURLY_BRACKET)
+ if (*p != CHAR_NULL && *p != CHAR_RIGHT_CURLY_BRACKET)
{
- c = -ESC_k;
+ escape = ESC_k;
break;
}
braced = TRUE;
@@ -890,17 +918,18 @@ else
else negated = FALSE;
/* The integer range is limited by the machine's int representation. */
- c = 0;
+ s = 0;
+ overflow = FALSE;
while (IS_DIGIT(ptr[1]))
{
- if (((unsigned int)c) > INT_MAX / 10) /* Integer overflow */
+ if (s > INT_MAX / 10 - 1) /* Integer overflow */
{
- c = -1;
+ overflow = TRUE;
break;
}
- c = c * 10 + *(++ptr) - CHAR_0;
+ s = s * 10 + (int)(*(++ptr) - CHAR_0);
}
- if (((unsigned int)c) > INT_MAX) /* Integer overflow */
+ if (overflow) /* Integer overflow */
{
while (IS_DIGIT(ptr[1]))
ptr++;
@@ -914,7 +943,7 @@ else
break;
}
- if (c == 0)
+ if (s == 0)
{
*errorcodeptr = ERR58;
break;
@@ -922,15 +951,15 @@ else
if (negated)
{
- if (c > bracount)
+ if (s > bracount)
{
*errorcodeptr = ERR15;
break;
}
- c = bracount - (c - 1);
+ s = bracount - (s - 1);
}
- c = -(ESC_REF + c);
+ escape = -s;
break;
/* The handling of escape sequences consisting of a string of digits
@@ -952,26 +981,27 @@ else
{
oldptr = ptr;
/* The integer range is limited by the machine's int representation. */
- c -= CHAR_0;
+ s = (int)(c -CHAR_0);
+ overflow = FALSE;
while (IS_DIGIT(ptr[1]))
{
- if (((unsigned int)c) > INT_MAX / 10) /* Integer overflow */
+ if (s > INT_MAX / 10 - 1) /* Integer overflow */
{
- c = -1;
+ overflow = TRUE;
break;
}
- c = c * 10 + *(++ptr) - CHAR_0;
+ s = s * 10 + (int)(*(++ptr) - CHAR_0);
}
- if (((unsigned int)c) > INT_MAX) /* Integer overflow */
+ if (overflow) /* Integer overflow */
{
while (IS_DIGIT(ptr[1]))
ptr++;
*errorcodeptr = ERR61;
break;
}
- if (c < 10 || c <= bracount)
+ if (s < 10 || s <= bracount)
{
- c = -(ESC_REF + c);
+ escape = -s;
break;
}
ptr = oldptr; /* Put the pointer back and fall through */
@@ -1018,7 +1048,7 @@ else
c = 0;
for (i = 0; i < 2; ++i)
{
- register int cc = *(++ptr);
+ register pcre_uint32 cc = *(++ptr);
#ifndef EBCDIC /* ASCII/UTF-8 coding */
if (cc >= CHAR_a) cc -= 32; /* Convert to upper case */
c = (c << 4) + cc - ((cc < CHAR_A)? CHAR_0 : (CHAR_A - 10));
@@ -1036,11 +1066,16 @@ else
const pcre_uchar *pt = ptr + 2;
c = 0;
+ overflow = FALSE;
while (MAX_255(*pt) && (digitab[*pt] & ctype_xdigit) != 0)
{
- register int cc = *pt++;
+ register pcre_uint32 cc = *pt++;
if (c == 0 && cc == CHAR_0) continue; /* Leading zeroes */
+#ifdef COMPILE_PCRE32
+ if (c >= 0x10000000l) { overflow = TRUE; break; }
+#endif
+
#ifndef EBCDIC /* ASCII/UTF-8 coding */
if (cc >= CHAR_a) cc -= 32; /* Convert to upper case */
c = (c << 4) + cc - ((cc < CHAR_A)? CHAR_0 : (CHAR_A - 10));
@@ -1049,16 +1084,16 @@ else
c = (c << 4) + cc - ((cc >= CHAR_0)? CHAR_0 : (CHAR_A - 10));
#endif
-#ifdef COMPILE_PCRE8
- if (c > (utf ? 0x10ffff : 0xff)) { c = -1; break; }
-#else
-#ifdef COMPILE_PCRE16
- if (c > (utf ? 0x10ffff : 0xffff)) { c = -1; break; }
-#endif
+#if defined COMPILE_PCRE8
+ if (c > (utf ? 0x10ffff : 0xff)) { overflow = TRUE; break; }
+#elif defined COMPILE_PCRE16
+ if (c > (utf ? 0x10ffff : 0xffff)) { overflow = TRUE; break; }
+#elif defined COMPILE_PCRE32
+ if (utf && c > 0x10ffff) { overflow = TRUE; break; }
#endif
}
- if (c < 0)
+ if (overflow)
{
while (MAX_255(*pt) && (digitab[*pt] & ctype_xdigit) != 0) pt++;
*errorcodeptr = ERR34;
@@ -1080,7 +1115,7 @@ else
c = 0;
while (i++ < 2 && MAX_255(ptr[1]) && (digitab[ptr[1]] & ctype_xdigit) != 0)
{
- int cc; /* Some compilers don't like */
+ pcre_uint32 cc; /* Some compilers don't like */
cc = *(++ptr); /* ++ in initializers */
#ifndef EBCDIC /* ASCII/UTF-8 coding */
if (cc >= CHAR_a) cc -= 32; /* Convert to upper case */
@@ -1099,7 +1134,7 @@ else
case CHAR_c:
c = *(++ptr);
- if (c == 0)
+ if (c == CHAR_NULL)
{
*errorcodeptr = ERR2;
break;
@@ -1139,23 +1174,22 @@ else
newline". PCRE does not support \N{name}. However, it does support
quantification such as \N{2,3}. */
-if (c == -ESC_N && ptr[1] == CHAR_LEFT_CURLY_BRACKET &&
+if (escape == ESC_N && ptr[1] == CHAR_LEFT_CURLY_BRACKET &&
!is_counted_repeat(ptr+2))
*errorcodeptr = ERR37;
/* If PCRE_UCP is set, we change the values for \d etc. */
-if ((options & PCRE_UCP) != 0 && c <= -ESC_D && c >= -ESC_w)
- c -= (ESC_DU - ESC_D);
+if ((options & PCRE_UCP) != 0 && escape >= ESC_D && escape <= ESC_w)
+ escape += (ESC_DU - ESC_D);
/* Set the pointer to the final character before returning. */
*ptrptr = ptr;
-return c;
+*chptr = c;
+return escape;
}
-
-
#ifdef SUPPORT_UCP
/*************************************************
* Handle \P and \p *
@@ -1169,21 +1203,24 @@ escape sequence.
Argument:
ptrptr points to the pattern position pointer
negptr points to a boolean that is set TRUE for negation else FALSE
- dptr points to an int that is set to the detailed property value
+ ptypeptr points to an unsigned int that is set to the type value
+ pdataptr points to an unsigned int that is set to the detailed property value
errorcodeptr points to the error code variable
-Returns: type value from ucp_type_table, or -1 for an invalid type
+Returns: TRUE if the type value was found, or FALSE for an invalid type
*/
-static int
-get_ucp(const pcre_uchar **ptrptr, BOOL *negptr, int *dptr, int *errorcodeptr)
+static BOOL
+get_ucp(const pcre_uchar **ptrptr, BOOL *negptr, unsigned int *ptypeptr,
+ unsigned int *pdataptr, int *errorcodeptr)
{
-int c, i, bot, top;
+pcre_uchar c;
+int i, bot, top;
const pcre_uchar *ptr = *ptrptr;
pcre_uchar name[32];
c = *(++ptr);
-if (c == 0) goto ERROR_RETURN;
+if (c == CHAR_NULL) goto ERROR_RETURN;
*negptr = FALSE;
@@ -1200,7 +1237,7 @@ if (c == CHAR_LEFT_CURLY_BRACKET)
for (i = 0; i < (int)(sizeof(name) / sizeof(pcre_uchar)) - 1; i++)
{
c = *(++ptr);
- if (c == 0) goto ERROR_RETURN;
+ if (c == CHAR_NULL) goto ERROR_RETURN;
if (c == CHAR_RIGHT_CURLY_BRACKET) break;
name[i] = c;
}
@@ -1225,24 +1262,26 @@ top = PRIV(utt_size);
while (bot < top)
{
+ int r;
i = (bot + top) >> 1;
- c = STRCMP_UC_C8(name, PRIV(utt_names) + PRIV(utt)[i].name_offset);
- if (c == 0)
+ r = STRCMP_UC_C8(name, PRIV(utt_names) + PRIV(utt)[i].name_offset);
+ if (r == 0)
{
- *dptr = PRIV(utt)[i].value;
- return PRIV(utt)[i].type;
+ *ptypeptr = PRIV(utt)[i].type;
+ *pdataptr = PRIV(utt)[i].value;
+ return TRUE;
}
- if (c > 0) bot = i + 1; else top = i;
+ if (r > 0) bot = i + 1; else top = i;
}
*errorcodeptr = ERR47;
*ptrptr = ptr;
-return -1;
+return FALSE;
ERROR_RETURN:
*errorcodeptr = ERR46;
*ptrptr = ptr;
-return -1;
+return FALSE;
}
#endif
@@ -1277,7 +1316,7 @@ int max = -1;
/* Read the minimum value and do a paranoid check: a negative value indicates
an integer overflow. */
-while (IS_DIGIT(*p)) min = min * 10 + *p++ - CHAR_0;
+while (IS_DIGIT(*p)) min = min * 10 + (int)(*p++ - CHAR_0);
if (min < 0 || min > 65535)
{
*errorcodeptr = ERR5;
@@ -1292,7 +1331,7 @@ if (*p == CHAR_RIGHT_CURLY_BRACKET) max = min; else
if (*(++p) != CHAR_RIGHT_CURLY_BRACKET)
{
max = 0;
- while(IS_DIGIT(*p)) max = max * 10 + *p++ - CHAR_0;
+ while(IS_DIGIT(*p)) max = max * 10 + (int)(*p++ - CHAR_0);
if (max < 0 || max > 65535)
{
*errorcodeptr = ERR5;
@@ -1347,7 +1386,7 @@ Arguments:
name name to seek, or NULL if seeking a numbered subpattern
lorn name length, or subpattern number if name is NULL
xmode TRUE if we are in /x mode
- utf TRUE if we are in UTF-8 / UTF-16 mode
+ utf TRUE if we are in UTF-8 / UTF-16 / UTF-32 mode
count pointer to the current capturing subpattern number (updated)
Returns: the number of the named subpattern, or -1 if not found
@@ -1393,7 +1432,8 @@ if (ptr[0] == CHAR_LEFT_PARENTHESIS)
else if (ptr[2] == CHAR_NUMBER_SIGN)
{
- for (ptr += 3; *ptr != 0; ptr++) if (*ptr == CHAR_RIGHT_PARENTHESIS) break;
+ for (ptr += 3; *ptr != CHAR_NULL; ptr++)
+ if (*ptr == CHAR_RIGHT_PARENTHESIS) break;
goto FAIL_EXIT;
}
@@ -1406,8 +1446,8 @@ if (ptr[0] == CHAR_LEFT_PARENTHESIS)
ptr += 2;
if (ptr[1] != CHAR_QUESTION_MARK)
{
- while (*ptr != 0 && *ptr != CHAR_RIGHT_PARENTHESIS) ptr++;
- if (*ptr != 0) ptr++;
+ while (*ptr != CHAR_NULL && *ptr != CHAR_RIGHT_PARENTHESIS) ptr++;
+ if (*ptr != CHAR_NULL) ptr++;
}
}
@@ -1423,7 +1463,7 @@ if (ptr[0] == CHAR_LEFT_PARENTHESIS)
if ((*ptr == CHAR_LESS_THAN_SIGN && ptr[1] != CHAR_EXCLAMATION_MARK &&
ptr[1] != CHAR_EQUALS_SIGN) || *ptr == CHAR_APOSTROPHE)
{
- int term;
+ pcre_uchar term;
const pcre_uchar *thisname;
*count += 1;
if (name == NULL && *count == lorn) return *count;
@@ -1431,8 +1471,8 @@ if (ptr[0] == CHAR_LEFT_PARENTHESIS)
if (term == CHAR_LESS_THAN_SIGN) term = CHAR_GREATER_THAN_SIGN;
thisname = ptr;
while (*ptr != term) ptr++;
- if (name != NULL && lorn == ptr - thisname &&
- STRNCMP_UC_UC(name, thisname, lorn) == 0)
+ if (name != NULL && lorn == (int)(ptr - thisname) &&
+ STRNCMP_UC_UC(name, thisname, (unsigned int)lorn) == 0)
return *count;
term++;
}
@@ -1450,11 +1490,11 @@ for (; ptr < cd->end_pattern; ptr++)
if (*ptr == CHAR_BACKSLASH)
{
- if (*(++ptr) == 0) goto FAIL_EXIT;
+ if (*(++ptr) == CHAR_NULL) goto FAIL_EXIT;
if (*ptr == CHAR_Q) for (;;)
{
- while (*(++ptr) != 0 && *ptr != CHAR_BACKSLASH) {};
- if (*ptr == 0) goto FAIL_EXIT;
+ while (*(++ptr) != CHAR_NULL && *ptr != CHAR_BACKSLASH) {};
+ if (*ptr == CHAR_NULL) goto FAIL_EXIT;
if (*(++ptr) == CHAR_E) break;
}
continue;
@@ -1498,14 +1538,14 @@ for (; ptr < cd->end_pattern; ptr++)
while (*(++ptr) != CHAR_RIGHT_SQUARE_BRACKET)
{
- if (*ptr == 0) return -1;
+ if (*ptr == CHAR_NULL) return -1;
if (*ptr == CHAR_BACKSLASH)
{
- if (*(++ptr) == 0) goto FAIL_EXIT;
+ if (*(++ptr) == CHAR_NULL) goto FAIL_EXIT;
if (*ptr == CHAR_Q) for (;;)
{
- while (*(++ptr) != 0 && *ptr != CHAR_BACKSLASH) {};
- if (*ptr == 0) goto FAIL_EXIT;
+ while (*(++ptr) != CHAR_NULL && *ptr != CHAR_BACKSLASH) {};
+ if (*ptr == CHAR_NULL) goto FAIL_EXIT;
if (*(++ptr) == CHAR_E) break;
}
continue;
@@ -1519,7 +1559,7 @@ for (; ptr < cd->end_pattern; ptr++)
if (xmode && *ptr == CHAR_NUMBER_SIGN)
{
ptr++;
- while (*ptr != 0)
+ while (*ptr != CHAR_NULL)
{
if (IS_NEWLINE(ptr)) { ptr += cd->nllen - 1; break; }
ptr++;
@@ -1527,7 +1567,7 @@ for (; ptr < cd->end_pattern; ptr++)
if (utf) FORWARDCHAR(ptr);
#endif
}
- if (*ptr == 0) goto FAIL_EXIT;
+ if (*ptr == CHAR_NULL) goto FAIL_EXIT;
continue;
}
@@ -1537,7 +1577,7 @@ for (; ptr < cd->end_pattern; ptr++)
{
int rc = find_parens_sub(&ptr, cd, name, lorn, xmode, utf, count);
if (rc > 0) return rc;
- if (*ptr == 0) goto FAIL_EXIT;
+ if (*ptr == CHAR_NULL) goto FAIL_EXIT;
}
else if (*ptr == CHAR_RIGHT_PARENTHESIS)
@@ -1581,7 +1621,7 @@ Arguments:
name name to seek, or NULL if seeking a numbered subpattern
lorn name length, or subpattern number if name is NULL
xmode TRUE if we are in /x mode
- utf TRUE if we are in UTF-8 / UTF-16 mode
+ utf TRUE if we are in UTF-8 / UTF-16 / UTF-32 mode
Returns: the number of the found subpattern, or -1 if not found
*/
@@ -1602,7 +1642,7 @@ matching closing parens. That is why we have to have a loop. */
for (;;)
{
rc = find_parens_sub(&ptr, cd, name, lorn, xmode, utf, &count);
- if (rc > 0 || *ptr++ == 0) break;
+ if (rc > 0 || *ptr++ == CHAR_NULL) break;
}
return rc;
@@ -1684,7 +1724,7 @@ and doing the check at the end; a flag specifies which mode we are running in.
Arguments:
code points to the start of the pattern (the bracket)
- utf TRUE in UTF-8 / UTF-16 mode
+ utf TRUE in UTF-8 / UTF-16 / UTF-32 mode
atend TRUE if called when the pattern is complete
cd the "compile data" structure
@@ -1710,7 +1750,7 @@ for (;;)
{
int d;
pcre_uchar *ce, *cs;
- register int op = *cc;
+ register pcre_uchar op = *cc;
switch (op)
{
@@ -1830,7 +1870,7 @@ for (;;)
case OP_EXACTI:
case OP_NOTEXACT:
case OP_NOTEXACTI:
- branchlength += GET2(cc,1);
+ branchlength += (int)GET2(cc,1);
cc += 2 + IMM2_SIZE;
#ifdef SUPPORT_UTF
if (utf && HAS_EXTRALEN(cc[-1])) cc += GET_EXTRALEN(cc[-1]);
@@ -1839,7 +1879,8 @@ for (;;)
case OP_TYPEEXACT:
branchlength += GET2(cc,1);
- if (cc[1 + IMM2_SIZE] == OP_PROP || cc[1 + IMM2_SIZE] == OP_NOTPROP) cc += 2;
+ if (cc[1 + IMM2_SIZE] == OP_PROP || cc[1 + IMM2_SIZE] == OP_NOTPROP)
+ cc += 2;
cc += 1 + IMM2_SIZE + 1;
break;
@@ -1874,15 +1915,19 @@ for (;;)
/* Check a class for variable quantification */
-#if defined SUPPORT_UTF || defined COMPILE_PCRE16
- case OP_XCLASS:
- cc += GET(cc, 1) - PRIV(OP_lengths)[OP_CLASS];
- /* Fall through */
-#endif
-
case OP_CLASS:
case OP_NCLASS:
+#if defined SUPPORT_UTF || defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ case OP_XCLASS:
+ /* The original code caused an unsigned overflow in 64 bit systems,
+ so now we use a conditional statement. */
+ if (op == OP_XCLASS)
+ cc += GET(cc, 1);
+ else
+ cc += PRIV(OP_lengths)[OP_CLASS];
+#else
cc += PRIV(OP_lengths)[OP_CLASS];
+#endif
switch (*cc)
{
@@ -1897,7 +1942,7 @@ for (;;)
case OP_CRRANGE:
case OP_CRMINRANGE:
if (GET2(cc,1) != GET2(cc,1+IMM2_SIZE)) return -1;
- branchlength += GET2(cc,1);
+ branchlength += (int)GET2(cc,1);
cc += 1 + 2 * IMM2_SIZE;
break;
@@ -2013,7 +2058,7 @@ length.
Arguments:
code points to start of expression
- utf TRUE in UTF-8 / UTF-16 mode
+ utf TRUE in UTF-8 / UTF-16 / UTF-32 mode
number the required bracket number or negative to find a lookbehind
Returns: pointer to the opcode for the bracket, or NULL if not found
@@ -2024,7 +2069,7 @@ PRIV(find_bracket)(const pcre_uchar *code, BOOL utf, int number)
{
for (;;)
{
- register int c = *code;
+ register pcre_uchar c = *code;
if (c == OP_END) return NULL;
@@ -2047,7 +2092,7 @@ for (;;)
else if (c == OP_CBRA || c == OP_SCBRA ||
c == OP_CBRAPOS || c == OP_SCBRAPOS)
{
- int n = GET2(code, 1+LINK_SIZE);
+ int n = (int)GET2(code, 1+LINK_SIZE);
if (n == number) return (pcre_uchar *)code;
code += PRIV(OP_lengths)[c];
}
@@ -2077,8 +2122,8 @@ for (;;)
case OP_TYPEMINUPTO:
case OP_TYPEEXACT:
case OP_TYPEPOSUPTO:
- if (code[1 + IMM2_SIZE] == OP_PROP
- || code[1 + IMM2_SIZE] == OP_NOTPROP) code += 2;
+ if (code[1 + IMM2_SIZE] == OP_PROP || code[1 + IMM2_SIZE] == OP_NOTPROP)
+ code += 2;
break;
case OP_MARK:
@@ -2100,7 +2145,7 @@ for (;;)
a multi-byte character. The length in the table is a minimum, so we have to
arrange to skip the extra bytes. */
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
if (utf) switch(c)
{
case OP_CHAR:
@@ -2152,7 +2197,7 @@ instance of OP_RECURSE.
Arguments:
code points to start of expression
- utf TRUE in UTF-8 / UTF-16 mode
+ utf TRUE in UTF-8 / UTF-16 / UTF-32 mode
Returns: pointer to the opcode for OP_RECURSE, or NULL if not found
*/
@@ -2162,7 +2207,7 @@ find_recurse(const pcre_uchar *code, BOOL utf)
{
for (;;)
{
- register int c = *code;
+ register pcre_uchar c = *code;
if (c == OP_END) return NULL;
if (c == OP_RECURSE) return code;
@@ -2197,8 +2242,8 @@ for (;;)
case OP_TYPEUPTO:
case OP_TYPEMINUPTO:
case OP_TYPEEXACT:
- if (code[1 + IMM2_SIZE] == OP_PROP
- || code[1 + IMM2_SIZE] == OP_NOTPROP) code += 2;
+ if (code[1 + IMM2_SIZE] == OP_PROP || code[1 + IMM2_SIZE] == OP_NOTPROP)
+ code += 2;
break;
case OP_MARK:
@@ -2220,37 +2265,65 @@ for (;;)
by a multi-byte character. The length in the table is a minimum, so we have
to arrange to skip the extra bytes. */
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
if (utf) switch(c)
{
case OP_CHAR:
case OP_CHARI:
+ case OP_NOT:
+ case OP_NOTI:
case OP_EXACT:
case OP_EXACTI:
+ case OP_NOTEXACT:
+ case OP_NOTEXACTI:
case OP_UPTO:
case OP_UPTOI:
+ case OP_NOTUPTO:
+ case OP_NOTUPTOI:
case OP_MINUPTO:
case OP_MINUPTOI:
+ case OP_NOTMINUPTO:
+ case OP_NOTMINUPTOI:
case OP_POSUPTO:
case OP_POSUPTOI:
+ case OP_NOTPOSUPTO:
+ case OP_NOTPOSUPTOI:
case OP_STAR:
case OP_STARI:
+ case OP_NOTSTAR:
+ case OP_NOTSTARI:
case OP_MINSTAR:
case OP_MINSTARI:
+ case OP_NOTMINSTAR:
+ case OP_NOTMINSTARI:
case OP_POSSTAR:
case OP_POSSTARI:
+ case OP_NOTPOSSTAR:
+ case OP_NOTPOSSTARI:
case OP_PLUS:
case OP_PLUSI:
+ case OP_NOTPLUS:
+ case OP_NOTPLUSI:
case OP_MINPLUS:
case OP_MINPLUSI:
+ case OP_NOTMINPLUS:
+ case OP_NOTMINPLUSI:
case OP_POSPLUS:
case OP_POSPLUSI:
+ case OP_NOTPOSPLUS:
+ case OP_NOTPOSPLUSI:
case OP_QUERY:
case OP_QUERYI:
+ case OP_NOTQUERY:
+ case OP_NOTQUERYI:
case OP_MINQUERY:
case OP_MINQUERYI:
+ case OP_NOTMINQUERY:
+ case OP_NOTMINQUERYI:
case OP_POSQUERY:
case OP_POSQUERYI:
+ case OP_NOTPOSQUERY:
+ case OP_NOTPOSQUERYI:
if (HAS_EXTRALEN(code[-1])) code += GET_EXTRALEN(code[-1]);
break;
}
@@ -2278,7 +2351,7 @@ bracket whose current branch will already have been scanned.
Arguments:
code points to start of search
endcode points to where to stop
- utf TRUE if in UTF-8 / UTF-16 mode
+ utf TRUE if in UTF-8 / UTF-16 / UTF-32 mode
cd contains pointers to tables etc.
Returns: TRUE if what is matched could be empty
@@ -2288,7 +2361,7 @@ static BOOL
could_be_empty_branch(const pcre_uchar *code, const pcre_uchar *endcode,
BOOL utf, compile_data *cd)
{
-register int c;
+register pcre_uchar c;
for (code = first_significant_code(code + PRIV(OP_lengths)[*code], TRUE);
code < endcode;
code = first_significant_code(code + PRIV(OP_lengths)[c], TRUE))
@@ -2322,7 +2395,7 @@ for (code = first_significant_code(code + PRIV(OP_lengths)[*code], TRUE);
/* Test for forward reference */
for (scode = cd->start_workspace; scode < cd->hwm; scode += LINK_SIZE)
- if (GET(scode, 0) == code + 1 - cd->start_code) return TRUE;
+ if ((int)GET(scode, 0) == (int)(code + 1 - cd->start_code)) return TRUE;
/* Not a forward reference, test for completed backward reference */
@@ -2495,8 +2568,8 @@ for (code = first_significant_code(code + PRIV(OP_lengths)[*code], TRUE);
case OP_TYPEUPTO:
case OP_TYPEMINUPTO:
case OP_TYPEPOSUPTO:
- if (code[1 + IMM2_SIZE] == OP_PROP
- || code[1 + IMM2_SIZE] == OP_NOTPROP) code += 2;
+ if (code[1 + IMM2_SIZE] == OP_PROP || code[1 + IMM2_SIZE] == OP_NOTPROP)
+ code += 2;
break;
/* End of branch */
@@ -2511,7 +2584,7 @@ for (code = first_significant_code(code + PRIV(OP_lengths)[*code], TRUE);
/* In UTF-8 mode, STAR, MINSTAR, POSSTAR, QUERY, MINQUERY, POSQUERY, UPTO,
MINUPTO, and POSUPTO may be followed by a multibyte character */
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
case OP_STAR:
case OP_STARI:
case OP_MINSTAR:
@@ -2577,7 +2650,7 @@ Arguments:
code points to start of the recursion
endcode points to where to stop (current RECURSE item)
bcptr points to the chain of current (unclosed) branch starts
- utf TRUE if in UTF-8 / UTF-16 mode
+ utf TRUE if in UTF-8 / UTF-16 / UTF-32 mode
cd pointers to tables etc
Returns: TRUE if what is matched could be empty
@@ -2643,9 +2716,9 @@ Returns: TRUE or FALSE
static BOOL
check_posix_syntax(const pcre_uchar *ptr, const pcre_uchar **endptr)
{
-int terminator; /* Don't combine these lines; the Solaris cc */
+pcre_uchar terminator; /* Don't combine these lines; the Solaris cc */
terminator = *(++ptr); /* compiler warns about "non-constant" initializer. */
-for (++ptr; *ptr != 0; ptr++)
+for (++ptr; *ptr != CHAR_NULL; ptr++)
{
if (*ptr == CHAR_BACKSLASH && ptr[1] == CHAR_RIGHT_SQUARE_BRACKET)
ptr++;
@@ -2692,7 +2765,7 @@ register int yield = 0;
while (posix_name_lengths[yield] != 0)
{
if (len == posix_name_lengths[yield] &&
- STRNCMP_UC_C8(ptr, pn, len) == 0) return yield;
+ STRNCMP_UC_C8(ptr, pn, (unsigned int)len) == 0) return yield;
pn += posix_name_lengths[yield] + 1;
yield++;
}
@@ -2724,7 +2797,7 @@ value in the reference (which is a group number).
Arguments:
group points to the start of the group
adjust the amount by which the group is to be moved
- utf TRUE in UTF-8 / UTF-16 mode
+ utf TRUE in UTF-8 / UTF-16 / UTF-32 mode
cd contains pointers to tables etc.
save_hwm the hwm forward reference pointer at the start of the group
@@ -2747,7 +2820,7 @@ while ((ptr = (pcre_uchar *)find_recurse(ptr, utf)) != NULL)
for (hc = save_hwm; hc < cd->hwm; hc += LINK_SIZE)
{
- offset = GET(hc, 0);
+ offset = (int)GET(hc, 0);
if (cd->start_code + offset == ptr + 1)
{
PUT(hc, 0, offset + adjust);
@@ -2760,7 +2833,7 @@ while ((ptr = (pcre_uchar *)find_recurse(ptr, utf)) != NULL)
if (hc >= cd->hwm)
{
- offset = GET(ptr, 1);
+ offset = (int)GET(ptr, 1);
if (cd->start_code + offset >= group) PUT(ptr, 1, offset + adjust);
}
@@ -2828,9 +2901,10 @@ PUT(previous_callout, 2 + LINK_SIZE, length);
*************************************************/
/* This function is passed the start and end of a class range, in UTF-8 mode
-with UCP support. It searches up the characters, looking for internal ranges of
+with UCP support. It searches up the characters, looking for ranges of
characters in the "other" case. Each call returns the next one, updating the
-start address.
+start address. A character with multiple other cases is returned on its own
+with a special return value.
Arguments:
cptr points to starting character value; updated
@@ -2838,19 +2912,34 @@ Arguments:
ocptr where to put start of othercase range
odptr where to put end of othercase range
-Yield: TRUE when range returned; FALSE when no more
+Yield: -1 when no more
+ 0 when a range is returned
+ >0 the CASESET offset for char with multiple other cases
+ in this case, ocptr contains the original
*/
-static BOOL
-get_othercase_range(unsigned int *cptr, unsigned int d, unsigned int *ocptr,
- unsigned int *odptr)
+static int
+get_othercase_range(pcre_uint32 *cptr, pcre_uint32 d, pcre_uint32 *ocptr,
+ pcre_uint32 *odptr)
{
-unsigned int c, othercase, next;
+pcre_uint32 c, othercase, next;
+unsigned int co;
+
+/* Find the first character that has an other case. If it has multiple other
+cases, return its case offset value. */
for (c = *cptr; c <= d; c++)
- { if ((othercase = UCD_OTHERCASE(c)) != c) break; }
+ {
+ if ((co = UCD_CASESET(c)) != 0)
+ {
+ *ocptr = c++; /* Character that has the set */
+ *cptr = c; /* Rest of input range */
+ return (int)co;
+ }
+ if ((othercase = UCD_OTHERCASE(c)) != c) break;
+ }
-if (c > d) return FALSE;
+if (c > d) return -1; /* Reached end of range */
*ocptr = othercase;
next = othercase + 1;
@@ -2861,10 +2950,9 @@ for (++c; c <= d; c++)
next++;
}
-*odptr = next - 1;
-*cptr = c;
-
-return TRUE;
+*odptr = next - 1; /* End of othercase range */
+*cptr = c; /* Rest of input range */
+return 0;
}
@@ -2886,9 +2974,14 @@ Returns: TRUE if auto-possessifying is OK
*/
static BOOL
-check_char_prop(int c, int ptype, int pdata, BOOL negated)
+check_char_prop(pcre_uint32 c, unsigned int ptype, unsigned int pdata, BOOL negated)
{
+#ifdef SUPPORT_UCP
+const pcre_uint32 *p;
+#endif
+
const ucd_record *prop = GET_UCD(c);
+
switch(ptype)
{
case PT_LAMP:
@@ -2926,7 +3019,19 @@ switch(ptype)
return (PRIV(ucp_gentype)[prop->chartype] == ucp_L ||
PRIV(ucp_gentype)[prop->chartype] == ucp_N ||
c == CHAR_UNDERSCORE) == negated;
+
+#ifdef SUPPORT_UCP
+ case PT_CLIST:
+ p = PRIV(ucd_caseless_sets) + prop->caseset;
+ for (;;)
+ {
+ if (c < *p) return !negated;
+ if (c == *p++) return negated;
+ }
+ break; /* Control never reaches here */
+#endif
}
+
return FALSE;
}
#endif /* SUPPORT_UCP */
@@ -2943,7 +3048,7 @@ sense to automatically possessify the repeated item.
Arguments:
previous pointer to the repeated opcode
- utf TRUE in UTF-8 / UTF-16 mode
+ utf TRUE in UTF-8 / UTF-16 / UTF-32 mode
ptr next character in pattern
options options bits
cd contains pointers to tables etc.
@@ -2955,8 +3060,10 @@ static BOOL
check_auto_possessive(const pcre_uchar *previous, BOOL utf,
const pcre_uchar *ptr, int options, compile_data *cd)
{
-pcre_int32 c, next;
-int op_code = *previous++;
+pcre_uint32 c = NOTACHAR;
+pcre_uint32 next;
+int escape;
+pcre_uchar op_code = *previous++;
/* Skip whitespace and comments in extended mode */
@@ -2968,7 +3075,7 @@ if ((options & PCRE_EXTENDED) != 0)
if (*ptr == CHAR_NUMBER_SIGN)
{
ptr++;
- while (*ptr != 0)
+ while (*ptr != CHAR_NULL)
{
if (IS_NEWLINE(ptr)) { ptr += cd->nllen; break; }
ptr++;
@@ -2987,12 +3094,13 @@ value is a character, a negative value is an escape value. */
if (*ptr == CHAR_BACKSLASH)
{
int temperrorcode = 0;
- next = check_escape(&ptr, &temperrorcode, cd->bracount, options, FALSE);
+ escape = check_escape(&ptr, &next, &temperrorcode, cd->bracount, options, FALSE);
if (temperrorcode != 0) return FALSE;
ptr++; /* Point after the escape sequence */
}
else if (!MAX_255(*ptr) || (cd->ctypes[*ptr] & ctype_meta) == 0)
{
+ escape = 0;
#ifdef SUPPORT_UTF
if (utf) { GETCHARINC(next, ptr); } else
#endif
@@ -3010,7 +3118,7 @@ if ((options & PCRE_EXTENDED) != 0)
if (*ptr == CHAR_NUMBER_SIGN)
{
ptr++;
- while (*ptr != 0)
+ while (*ptr != CHAR_NULL)
{
if (IS_NEWLINE(ptr)) { ptr += cd->nllen; break; }
ptr++;
@@ -3029,150 +3137,140 @@ if (*ptr == CHAR_ASTERISK || *ptr == CHAR_QUESTION_MARK ||
STRNCMP_UC_C8(ptr, STR_LEFT_CURLY_BRACKET STR_0 STR_COMMA, 3) == 0)
return FALSE;
-/* Now compare the next item with the previous opcode. First, handle cases when
-the next item is a character. */
+/* If the previous item is a character, get its value. */
-if (next >= 0) switch(op_code)
+if (op_code == OP_CHAR || op_code == OP_CHARI ||
+ op_code == OP_NOT || op_code == OP_NOTI)
{
- case OP_CHAR:
#ifdef SUPPORT_UTF
GETCHARTEST(c, previous);
#else
c = *previous;
#endif
- return c != next;
+ }
- /* For CHARI (caseless character) we must check the other case. If we have
- Unicode property support, we can use it to test the other case of
- high-valued characters. */
+/* Now compare the next item with the previous opcode. First, handle cases when
+the next item is a character. */
- case OP_CHARI:
-#ifdef SUPPORT_UTF
- GETCHARTEST(c, previous);
-#else
- c = *previous;
+if (escape == 0)
+ {
+ /* For a caseless UTF match, the next character may have more than one other
+ case, which maps to the special PT_CLIST property. Check this first. */
+
+#ifdef SUPPORT_UCP
+ if (utf && c != NOTACHAR && (options & PCRE_CASELESS) != 0)
+ {
+ unsigned int ocs = UCD_CASESET(next);
+ if (ocs > 0) return check_char_prop(c, PT_CLIST, ocs, op_code >= OP_NOT);
+ }
#endif
- if (c == next) return FALSE;
-#ifdef SUPPORT_UTF
- if (utf)
+
+ switch(op_code)
{
- unsigned int othercase;
- if (next < 128) othercase = cd->fcc[next]; else
+ case OP_CHAR:
+ return c != next;
+
+ /* For CHARI (caseless character) we must check the other case. If we have
+ Unicode property support, we can use it to test the other case of
+ high-valued characters. We know that next can have only one other case,
+ because multi-other-case characters are dealt with above. */
+
+ case OP_CHARI:
+ if (c == next) return FALSE;
+#ifdef SUPPORT_UTF
+ if (utf)
+ {
+ pcre_uint32 othercase;
+ if (next < 128) othercase = cd->fcc[next]; else
#ifdef SUPPORT_UCP
- othercase = UCD_OTHERCASE((unsigned int)next);
+ othercase = UCD_OTHERCASE(next);
#else
- othercase = NOTACHAR;
+ othercase = NOTACHAR;
#endif
- return (unsigned int)c != othercase;
- }
- else
+ return c != othercase;
+ }
+ else
#endif /* SUPPORT_UTF */
- return (c != TABLE_GET((unsigned int)next, cd->fcc, next)); /* Non-UTF-8 mode */
-
- /* For OP_NOT and OP_NOTI, the data is always a single-byte character. These
- opcodes are not used for multi-byte characters, because they are coded using
- an XCLASS instead. */
+ return (c != TABLE_GET(next, cd->fcc, next)); /* Not UTF */
- case OP_NOT:
- return (c = *previous) == next;
+ case OP_NOT:
+ return c == next;
- case OP_NOTI:
- if ((c = *previous) == next) return TRUE;
+ case OP_NOTI:
+ if (c == next) return TRUE;
#ifdef SUPPORT_UTF
- if (utf)
- {
- unsigned int othercase;
- if (next < 128) othercase = cd->fcc[next]; else
+ if (utf)
+ {
+ pcre_uint32 othercase;
+ if (next < 128) othercase = cd->fcc[next]; else
#ifdef SUPPORT_UCP
- othercase = UCD_OTHERCASE(next);
+ othercase = UCD_OTHERCASE(next);
#else
- othercase = NOTACHAR;
+ othercase = NOTACHAR;
#endif
- return (unsigned int)c == othercase;
- }
- else
+ return c == othercase;
+ }
+ else
#endif /* SUPPORT_UTF */
- return (c == (int)(TABLE_GET((unsigned int)next, cd->fcc, next))); /* Non-UTF-8 mode */
+ return (c == TABLE_GET(next, cd->fcc, next)); /* Not UTF */
- /* Note that OP_DIGIT etc. are generated only when PCRE_UCP is *not* set.
- When it is set, \d etc. are converted into OP_(NOT_)PROP codes. */
+ /* Note that OP_DIGIT etc. are generated only when PCRE_UCP is *not* set.
+ When it is set, \d etc. are converted into OP_(NOT_)PROP codes. */
- case OP_DIGIT:
- return next > 127 || (cd->ctypes[next] & ctype_digit) == 0;
+ case OP_DIGIT:
+ return next > 255 || (cd->ctypes[next] & ctype_digit) == 0;
- case OP_NOT_DIGIT:
- return next <= 127 && (cd->ctypes[next] & ctype_digit) != 0;
+ case OP_NOT_DIGIT:
+ return next <= 255 && (cd->ctypes[next] & ctype_digit) != 0;
- case OP_WHITESPACE:
- return next > 127 || (cd->ctypes[next] & ctype_space) == 0;
+ case OP_WHITESPACE:
+ return next > 255 || (cd->ctypes[next] & ctype_space) == 0;
- case OP_NOT_WHITESPACE:
- return next <= 127 && (cd->ctypes[next] & ctype_space) != 0;
+ case OP_NOT_WHITESPACE:
+ return next <= 255 && (cd->ctypes[next] & ctype_space) != 0;
- case OP_WORDCHAR:
- return next > 127 || (cd->ctypes[next] & ctype_word) == 0;
+ case OP_WORDCHAR:
+ return next > 255 || (cd->ctypes[next] & ctype_word) == 0;
- case OP_NOT_WORDCHAR:
- return next <= 127 && (cd->ctypes[next] & ctype_word) != 0;
+ case OP_NOT_WORDCHAR:
+ return next <= 255 && (cd->ctypes[next] & ctype_word) != 0;
- case OP_HSPACE:
- case OP_NOT_HSPACE:
- switch(next)
- {
- case 0x09:
- case 0x20:
- case 0xa0:
- case 0x1680:
- case 0x180e:
- case 0x2000:
- case 0x2001:
- case 0x2002:
- case 0x2003:
- case 0x2004:
- case 0x2005:
- case 0x2006:
- case 0x2007:
- case 0x2008:
- case 0x2009:
- case 0x200A:
- case 0x202f:
- case 0x205f:
- case 0x3000:
- return op_code == OP_NOT_HSPACE;
- default:
- return op_code != OP_NOT_HSPACE;
- }
+ case OP_HSPACE:
+ case OP_NOT_HSPACE:
+ switch(next)
+ {
+ HSPACE_CASES:
+ return op_code == OP_NOT_HSPACE;
- case OP_ANYNL:
- case OP_VSPACE:
- case OP_NOT_VSPACE:
- switch(next)
- {
- case 0x0a:
- case 0x0b:
- case 0x0c:
- case 0x0d:
- case 0x85:
- case 0x2028:
- case 0x2029:
- return op_code == OP_NOT_VSPACE;
- default:
- return op_code != OP_NOT_VSPACE;
- }
+ default:
+ return op_code != OP_NOT_HSPACE;
+ }
+
+ case OP_ANYNL:
+ case OP_VSPACE:
+ case OP_NOT_VSPACE:
+ switch(next)
+ {
+ VSPACE_CASES:
+ return op_code == OP_NOT_VSPACE;
+
+ default:
+ return op_code != OP_NOT_VSPACE;
+ }
#ifdef SUPPORT_UCP
- case OP_PROP:
- return check_char_prop(next, previous[0], previous[1], FALSE);
+ case OP_PROP:
+ return check_char_prop(next, previous[0], previous[1], FALSE);
- case OP_NOTPROP:
- return check_char_prop(next, previous[0], previous[1], TRUE);
+ case OP_NOTPROP:
+ return check_char_prop(next, previous[0], previous[1], TRUE);
#endif
- default:
- return FALSE;
+ default:
+ return FALSE;
+ }
}
-
/* Handle the case when the next item is \d, \s, etc. Note that when PCRE_UCP
is set, \d turns into ESC_du rather than ESC_d, etc., so ESC_d etc. are
generated only when PCRE_UCP is *not* set, that is, when only ASCII
@@ -3183,78 +3281,51 @@ switch(op_code)
{
case OP_CHAR:
case OP_CHARI:
-#ifdef SUPPORT_UTF
- GETCHARTEST(c, previous);
-#else
- c = *previous;
-#endif
- switch(-next)
+ switch(escape)
{
case ESC_d:
- return c > 127 || (cd->ctypes[c] & ctype_digit) == 0;
+ return c > 255 || (cd->ctypes[c] & ctype_digit) == 0;
case ESC_D:
- return c <= 127 && (cd->ctypes[c] & ctype_digit) != 0;
+ return c <= 255 && (cd->ctypes[c] & ctype_digit) != 0;
case ESC_s:
- return c > 127 || (cd->ctypes[c] & ctype_space) == 0;
+ return c > 255 || (cd->ctypes[c] & ctype_space) == 0;
case ESC_S:
- return c <= 127 && (cd->ctypes[c] & ctype_space) != 0;
+ return c <= 255 && (cd->ctypes[c] & ctype_space) != 0;
case ESC_w:
- return c > 127 || (cd->ctypes[c] & ctype_word) == 0;
+ return c > 255 || (cd->ctypes[c] & ctype_word) == 0;
case ESC_W:
- return c <= 127 && (cd->ctypes[c] & ctype_word) != 0;
+ return c <= 255 && (cd->ctypes[c] & ctype_word) != 0;
case ESC_h:
case ESC_H:
switch(c)
{
- case 0x09:
- case 0x20:
- case 0xa0:
- case 0x1680:
- case 0x180e:
- case 0x2000:
- case 0x2001:
- case 0x2002:
- case 0x2003:
- case 0x2004:
- case 0x2005:
- case 0x2006:
- case 0x2007:
- case 0x2008:
- case 0x2009:
- case 0x200A:
- case 0x202f:
- case 0x205f:
- case 0x3000:
- return -next != ESC_h;
+ HSPACE_CASES:
+ return escape != ESC_h;
+
default:
- return -next == ESC_h;
+ return escape == ESC_h;
}
case ESC_v:
case ESC_V:
switch(c)
{
- case 0x0a:
- case 0x0b:
- case 0x0c:
- case 0x0d:
- case 0x85:
- case 0x2028:
- case 0x2029:
- return -next != ESC_v;
+ VSPACE_CASES:
+ return escape != ESC_v;
+
default:
- return -next == ESC_v;
+ return escape == ESC_v;
}
/* When PCRE_UCP is set, these values get generated for \d etc. Find
their substitutions and process them. The result will always be either
- -ESC_p or -ESC_P. Then fall through to process those values. */
+ ESC_p or ESC_P. Then fall through to process those values. */
#ifdef SUPPORT_UCP
case ESC_du:
@@ -3265,8 +3336,8 @@ switch(op_code)
case ESC_SU:
{
int temperrorcode = 0;
- ptr = substitutes[-next - ESC_DU];
- next = check_escape(&ptr, &temperrorcode, 0, options, FALSE);
+ ptr = substitutes[escape - ESC_DU];
+ escape = check_escape(&ptr, &next, &temperrorcode, 0, options, FALSE);
if (temperrorcode != 0) return FALSE;
ptr++; /* For compatibility */
}
@@ -3275,12 +3346,13 @@ switch(op_code)
case ESC_p:
case ESC_P:
{
- int ptype, pdata, errorcodeptr;
+ unsigned int ptype = 0, pdata = 0;
+ int errorcodeptr;
BOOL negated;
ptr--; /* Make ptr point at the p or P */
- ptype = get_ucp(&ptr, &negated, &pdata, &errorcodeptr);
- if (ptype < 0) return FALSE;
+ if (!get_ucp(&ptr, &negated, &ptype, &pdata, &errorcodeptr))
+ return FALSE;
ptr++; /* Point past the final curly ket */
/* If the property item is optional, we have to give up. (When generated
@@ -3293,7 +3365,7 @@ switch(op_code)
/* Do the property check. */
- return check_char_prop(c, ptype, pdata, (next == -ESC_P) != negated);
+ return check_char_prop(c, ptype, pdata, (escape == ESC_P) != negated);
}
#endif
@@ -3308,39 +3380,39 @@ switch(op_code)
these op-codes are never generated.) */
case OP_DIGIT:
- return next == -ESC_D || next == -ESC_s || next == -ESC_W ||
- next == -ESC_h || next == -ESC_v || next == -ESC_R;
+ return escape == ESC_D || escape == ESC_s || escape == ESC_W ||
+ escape == ESC_h || escape == ESC_v || escape == ESC_R;
case OP_NOT_DIGIT:
- return next == -ESC_d;
+ return escape == ESC_d;
case OP_WHITESPACE:
- return next == -ESC_S || next == -ESC_d || next == -ESC_w || next == -ESC_R;
+ return escape == ESC_S || escape == ESC_d || escape == ESC_w;
case OP_NOT_WHITESPACE:
- return next == -ESC_s || next == -ESC_h || next == -ESC_v;
+ return escape == ESC_s || escape == ESC_h || escape == ESC_v || escape == ESC_R;
case OP_HSPACE:
- return next == -ESC_S || next == -ESC_H || next == -ESC_d ||
- next == -ESC_w || next == -ESC_v || next == -ESC_R;
+ return escape == ESC_S || escape == ESC_H || escape == ESC_d ||
+ escape == ESC_w || escape == ESC_v || escape == ESC_R;
case OP_NOT_HSPACE:
- return next == -ESC_h;
+ return escape == ESC_h;
/* Can't have \S in here because VT matches \S (Perl anomaly) */
case OP_ANYNL:
case OP_VSPACE:
- return next == -ESC_V || next == -ESC_d || next == -ESC_w;
+ return escape == ESC_V || escape == ESC_d || escape == ESC_w;
case OP_NOT_VSPACE:
- return next == -ESC_v || next == -ESC_R;
+ return escape == ESC_v || escape == ESC_R;
case OP_WORDCHAR:
- return next == -ESC_W || next == -ESC_s || next == -ESC_h ||
- next == -ESC_v || next == -ESC_R;
+ return escape == ESC_W || escape == ESC_s || escape == ESC_h ||
+ escape == ESC_v || escape == ESC_R;
case OP_NOT_WORDCHAR:
- return next == -ESC_w || next == -ESC_d;
+ return escape == ESC_w || escape == ESC_d;
default:
return FALSE;
@@ -3352,6 +3424,244 @@ switch(op_code)
/*************************************************
+* Add a character or range to a class *
+*************************************************/
+
+/* This function packages up the logic of adding a character or range of
+characters to a class. The character values in the arguments will be within the
+valid values for the current mode (8-bit, 16-bit, UTF, etc). This function is
+mutually recursive with the function immediately below.
+
+Arguments:
+ classbits the bit map for characters < 256
+ uchardptr points to the pointer for extra data
+ options the options word
+ cd contains pointers to tables etc.
+ start start of range character
+ end end of range character
+
+Returns: the number of < 256 characters added
+ the pointer to extra data is updated
+*/
+
+static int
+add_to_class(pcre_uint8 *classbits, pcre_uchar **uchardptr, int options,
+ compile_data *cd, pcre_uint32 start, pcre_uint32 end)
+{
+pcre_uint32 c;
+int n8 = 0;
+
+/* If caseless matching is required, scan the range and process alternate
+cases. In Unicode, there are 8-bit characters that have alternate cases that
+are greater than 255 and vice-versa. Sometimes we can just extend the original
+range. */
+
+if ((options & PCRE_CASELESS) != 0)
+ {
+#ifdef SUPPORT_UCP
+ if ((options & PCRE_UTF8) != 0)
+ {
+ int rc;
+ pcre_uint32 oc, od;
+
+ options &= ~PCRE_CASELESS; /* Remove for recursive calls */
+ c = start;
+
+ while ((rc = get_othercase_range(&c, end, &oc, &od)) >= 0)
+ {
+ /* Handle a single character that has more than one other case. */
+
+ if (rc > 0) n8 += add_list_to_class(classbits, uchardptr, options, cd,
+ PRIV(ucd_caseless_sets) + rc, oc);
+
+ /* Do nothing if the other case range is within the original range. */
+
+ else if (oc >= start && od <= end) continue;
+
+ /* Extend the original range if there is overlap, noting that if oc < c, we
+ can't have od > end because a subrange is always shorter than the basic
+ range. Otherwise, use a recursive call to add the additional range. */
+
+ else if (oc < start && od >= start - 1) start = oc; /* Extend downwards */
+ else if (od > end && oc <= end + 1) end = od; /* Extend upwards */
+ else n8 += add_to_class(classbits, uchardptr, options, cd, oc, od);
+ }
+ }
+ else
+#endif /* SUPPORT_UCP */
+
+ /* Not UTF-mode, or no UCP */
+
+ for (c = start; c <= end && c < 256; c++)
+ {
+ SETBIT(classbits, cd->fcc[c]);
+ n8++;
+ }
+ }
+
+/* Now handle the original range. Adjust the final value according to the bit
+length - this means that the same lists of (e.g.) horizontal spaces can be used
+in all cases. */
+
+#if defined COMPILE_PCRE8
+#ifdef SUPPORT_UTF
+ if ((options & PCRE_UTF8) == 0)
+#endif
+ if (end > 0xff) end = 0xff;
+
+#elif defined COMPILE_PCRE16
+#ifdef SUPPORT_UTF
+ if ((options & PCRE_UTF16) == 0)
+#endif
+ if (end > 0xffff) end = 0xffff;
+
+#endif /* COMPILE_PCRE[8|16] */
+
+/* If all characters are less than 256, use the bit map. Otherwise use extra
+data. */
+
+if (end < 0x100)
+ {
+ for (c = start; c <= end; c++)
+ {
+ n8++;
+ SETBIT(classbits, c);
+ }
+ }
+
+else
+ {
+ pcre_uchar *uchardata = *uchardptr;
+
+#ifdef SUPPORT_UTF
+ if ((options & PCRE_UTF8) != 0) /* All UTFs use the same flag bit */
+ {
+ if (start < end)
+ {
+ *uchardata++ = XCL_RANGE;
+ uchardata += PRIV(ord2utf)(start, uchardata);
+ uchardata += PRIV(ord2utf)(end, uchardata);
+ }
+ else if (start == end)
+ {
+ *uchardata++ = XCL_SINGLE;
+ uchardata += PRIV(ord2utf)(start, uchardata);
+ }
+ }
+ else
+#endif /* SUPPORT_UTF */
+
+ /* Without UTF support, character values are constrained by the bit length,
+ and can only be > 256 for 16-bit and 32-bit libraries. */
+
+#ifdef COMPILE_PCRE8
+ {}
+#else
+ if (start < end)
+ {
+ *uchardata++ = XCL_RANGE;
+ *uchardata++ = start;
+ *uchardata++ = end;
+ }
+ else if (start == end)
+ {
+ *uchardata++ = XCL_SINGLE;
+ *uchardata++ = start;
+ }
+#endif
+
+ *uchardptr = uchardata; /* Updata extra data pointer */
+ }
+
+return n8; /* Number of 8-bit characters */
+}
+
+
+
+
+/*************************************************
+* Add a list of characters to a class *
+*************************************************/
+
+/* This function is used for adding a list of case-equivalent characters to a
+class, and also for adding a list of horizontal or vertical whitespace. If the
+list is in order (which it should be), ranges of characters are detected and
+handled appropriately. This function is mutually recursive with the function
+above.
+
+Arguments:
+ classbits the bit map for characters < 256
+ uchardptr points to the pointer for extra data
+ options the options word
+ cd contains pointers to tables etc.
+ p points to row of 32-bit values, terminated by NOTACHAR
+ except character to omit; this is used when adding lists of
+ case-equivalent characters to avoid including the one we
+ already know about
+
+Returns: the number of < 256 characters added
+ the pointer to extra data is updated
+*/
+
+static int
+add_list_to_class(pcre_uint8 *classbits, pcre_uchar **uchardptr, int options,
+ compile_data *cd, const pcre_uint32 *p, unsigned int except)
+{
+int n8 = 0;
+while (p[0] < NOTACHAR)
+ {
+ int n = 0;
+ if (p[0] != except)
+ {
+ while(p[n+1] == p[0] + n + 1) n++;
+ n8 += add_to_class(classbits, uchardptr, options, cd, p[0], p[n]);
+ }
+ p += n + 1;
+ }
+return n8;
+}
+
+
+
+/*************************************************
+* Add characters not in a list to a class *
+*************************************************/
+
+/* This function is used for adding the complement of a list of horizontal or
+vertical whitespace to a class. The list must be in order.
+
+Arguments:
+ classbits the bit map for characters < 256
+ uchardptr points to the pointer for extra data
+ options the options word
+ cd contains pointers to tables etc.
+ p points to row of 32-bit values, terminated by NOTACHAR
+
+Returns: the number of < 256 characters added
+ the pointer to extra data is updated
+*/
+
+static int
+add_not_list_to_class(pcre_uint8 *classbits, pcre_uchar **uchardptr,
+ int options, compile_data *cd, const pcre_uint32 *p)
+{
+BOOL utf = (options & PCRE_UTF8) != 0;
+int n8 = 0;
+if (p[0] > 0)
+ n8 += add_to_class(classbits, uchardptr, options, cd, 0, p[0] - 1);
+while (p[0] < NOTACHAR)
+ {
+ while (p[1] == p[0] + 1) p++;
+ n8 += add_to_class(classbits, uchardptr, options, cd, p[0] + 1,
+ (p[1] == NOTACHAR) ? (utf ? 0x10ffffu : 0xffffffffu) : p[1] - 1);
+ p++;
+ }
+return n8;
+}
+
+
+
+/*************************************************
* Compile one branch *
*************************************************/
@@ -3366,8 +3676,10 @@ Arguments:
codeptr points to the pointer to the current code point
ptrptr points to the current pattern pointer
errorcodeptr points to error code variable
- firstcharptr set to initial literal character, or < 0 (REQ_UNSET, REQ_NONE)
- reqcharptr set to the last literal character required, else < 0
+ firstcharptr place to put the first required character
+ firstcharflagsptr place to put the first character flags, or a negative number
+ reqcharptr place to put the last required character
+ reqcharflagsptr place to put the last required character flags, or a negative number
bcptr points to current branch chain
cond_depth conditional nesting depth
cd contains pointers to tables etc.
@@ -3380,21 +3692,26 @@ Returns: TRUE on success
static BOOL
compile_branch(int *optionsptr, pcre_uchar **codeptr,
- const pcre_uchar **ptrptr, int *errorcodeptr, pcre_int32 *firstcharptr,
- pcre_int32 *reqcharptr, branch_chain *bcptr, int cond_depth,
+ const pcre_uchar **ptrptr, int *errorcodeptr,
+ pcre_uint32 *firstcharptr, pcre_int32 *firstcharflagsptr,
+ pcre_uint32 *reqcharptr, pcre_int32 *reqcharflagsptr,
+ branch_chain *bcptr, int cond_depth,
compile_data *cd, int *lengthptr)
{
int repeat_type, op_type;
int repeat_min = 0, repeat_max = 0; /* To please picky compilers */
int bravalue = 0;
int greedy_default, greedy_non_default;
-pcre_int32 firstchar, reqchar;
-pcre_int32 zeroreqchar, zerofirstchar;
+pcre_uint32 firstchar, reqchar;
+pcre_int32 firstcharflags, reqcharflags;
+pcre_uint32 zeroreqchar, zerofirstchar;
+pcre_int32 zeroreqcharflags, zerofirstcharflags;
pcre_int32 req_caseopt, reqvary, tempreqvary;
int options = *optionsptr; /* May change dynamically */
int after_manual_callout = 0;
int length_prevgroup = 0;
-register int c;
+register pcre_uint32 c;
+int escape;
register pcre_uchar *code = *codeptr;
pcre_uchar *last_code = code;
pcre_uchar *orig_code = code;
@@ -3414,18 +3731,23 @@ must not do this for other options (e.g. PCRE_EXTENDED) because they may change
dynamically as we process the pattern. */
#ifdef SUPPORT_UTF
-/* PCRE_UTF16 has the same value as PCRE_UTF8. */
+/* PCRE_UTF[16|32] have the same value as PCRE_UTF8. */
BOOL utf = (options & PCRE_UTF8) != 0;
+#ifndef COMPILE_PCRE32
pcre_uchar utf_chars[6];
+#endif
#else
BOOL utf = FALSE;
#endif
-/* Helper variables for OP_XCLASS opcode (for characters > 255). */
+/* Helper variables for OP_XCLASS opcode (for characters > 255). We define
+class_uchardata always so that it can be passed to add_to_class() always,
+though it will not be used in non-UTF 8-bit cases. This avoids having to supply
+alternative calls for the different cases. */
+pcre_uchar *class_uchardata;
#if defined SUPPORT_UTF || !defined COMPILE_PCRE8
BOOL xclass;
-pcre_uchar *class_uchardata;
pcre_uchar *class_uchardata_base;
#endif
@@ -3448,7 +3770,8 @@ to take the zero repeat into account. This is implemented by setting them to
zerofirstbyte and zeroreqchar when such a repeat is encountered. The individual
item types that can be repeated set these backoff variables appropriately. */
-firstchar = reqchar = zerofirstchar = zeroreqchar = REQ_UNSET;
+firstchar = reqchar = zerofirstchar = zeroreqchar = 0;
+firstcharflags = reqcharflags = zerofirstcharflags = zeroreqcharflags = REQ_UNSET;
/* The variable req_caseopt contains either the REQ_CASELESS value
or zero, according to the current setting of the caseless flag. The
@@ -3469,16 +3792,17 @@ for (;; ptr++)
BOOL is_recurse;
BOOL reset_bracount;
int class_has_8bitchar;
- int class_single_char;
+ int class_one_char;
int newoptions;
int recno;
int refsign;
int skipbytes;
- int subreqchar;
- int subfirstchar;
+ pcre_uint32 subreqchar, subfirstchar;
+ pcre_int32 subreqcharflags, subfirstcharflags;
int terminator;
- int mclength;
- int tempbracount;
+ unsigned int mclength;
+ unsigned int tempbracount;
+ pcre_uint32 ec;
pcre_uchar mcbuffer[8];
/* Get next character in the pattern */
@@ -3488,7 +3812,7 @@ for (;; ptr++)
/* If we are at the end of a nested substitution, revert to the outer level
string. Nesting only happens one level deep. */
- if (c == 0 && nestptr != NULL)
+ if (c == CHAR_NULL && nestptr != NULL)
{
ptr = nestptr;
nestptr = NULL;
@@ -3563,7 +3887,7 @@ for (;; ptr++)
/* If in \Q...\E, check for the end; if not, we have a literal */
- if (inescq && c != 0)
+ if (inescq && c != CHAR_NULL)
{
if (c == CHAR_BACKSLASH && ptr[1] == CHAR_E)
{
@@ -3611,7 +3935,7 @@ for (;; ptr++)
if (c == CHAR_NUMBER_SIGN)
{
ptr++;
- while (*ptr != 0)
+ while (*ptr != CHAR_NULL)
{
if (IS_NEWLINE(ptr)) { ptr += cd->nllen - 1; break; }
ptr++;
@@ -3619,7 +3943,7 @@ for (;; ptr++)
if (utf) FORWARDCHAR(ptr);
#endif
}
- if (*ptr != 0) continue;
+ if (*ptr != CHAR_NULL) continue;
/* Else fall through to handle end of string */
c = 0;
@@ -3641,7 +3965,9 @@ for (;; ptr++)
case CHAR_VERTICAL_LINE: /* or | or ) */
case CHAR_RIGHT_PARENTHESIS:
*firstcharptr = firstchar;
+ *firstcharflagsptr = firstcharflags;
*reqcharptr = reqchar;
+ *reqcharflagsptr = reqcharflags;
*codeptr = code;
*ptrptr = ptr;
if (lengthptr != NULL)
@@ -3665,7 +3991,7 @@ for (;; ptr++)
previous = NULL;
if ((options & PCRE_MULTILINE) != 0)
{
- if (firstchar == REQ_UNSET) firstchar = REQ_NONE;
+ if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE;
*code++ = OP_CIRCM;
}
else *code++ = OP_CIRC;
@@ -3680,9 +4006,11 @@ for (;; ptr++)
repeats. The value of reqchar doesn't change either. */
case CHAR_DOT:
- if (firstchar == REQ_UNSET) firstchar = REQ_NONE;
+ if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE;
zerofirstchar = firstchar;
+ zerofirstcharflags = firstcharflags;
zeroreqchar = reqchar;
+ zeroreqcharflags = reqcharflags;
previous = code;
*code++ = ((options & PCRE_DOTALL) != 0)? OP_ALLANY: OP_ANY;
break;
@@ -3756,8 +4084,9 @@ for (;; ptr++)
(cd->external_options & PCRE_JAVASCRIPT_COMPAT) != 0)
{
*code++ = negate_class? OP_ALLANY : OP_FAIL;
- if (firstchar == REQ_UNSET) firstchar = REQ_NONE;
+ if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE;
zerofirstchar = firstchar;
+ zerofirstcharflags = firstcharflags;
break;
}
@@ -3767,32 +4096,32 @@ for (;; ptr++)
should_flip_negation = FALSE;
- /* For optimization purposes, we track some properties of the class.
- class_has_8bitchar will be non-zero, if the class contains at least one
- < 256 character. class_single_char will be 1 if the class contains only
- a single character. */
+ /* For optimization purposes, we track some properties of the class:
+ class_has_8bitchar will be non-zero if the class contains at least one <
+ 256 character; class_one_char will be 1 if the class contains just one
+ character. */
class_has_8bitchar = 0;
- class_single_char = 0;
+ class_one_char = 0;
/* Initialize the 32-char bit map to all zeros. We build the map in a
- temporary bit of memory, in case the class contains only 1 character (less
- than 256), because in that case the compiled code doesn't use the bit map.
- */
+ temporary bit of memory, in case the class contains fewer than two
+ 8-bit characters because in that case the compiled code doesn't use the bit
+ map. */
memset(classbits, 0, 32 * sizeof(pcre_uint8));
#if defined SUPPORT_UTF || !defined COMPILE_PCRE8
- xclass = FALSE; /* No chars >= 256 */
- class_uchardata = code + LINK_SIZE + 2; /* For UTF-8 items */
- class_uchardata_base = class_uchardata; /* For resetting in pass 1 */
+ xclass = FALSE;
+ class_uchardata = code + LINK_SIZE + 2; /* For XCLASS items */
+ class_uchardata_base = class_uchardata; /* Save the start */
#endif
/* Process characters until ] is reached. By writing this as a "do" it
means that an initial ] is taken as a data character. At the start of the
loop, c contains the first byte of the character. */
- if (c != 0) do
+ if (c != CHAR_NULL) do
{
const pcre_uchar *oldptr;
@@ -3807,10 +4136,12 @@ for (;; ptr++)
/* In the pre-compile phase, accumulate the length of any extra
data and reset the pointer. This is so that very large classes that
contain a zillion > 255 characters no longer overwrite the work space
- (which is on the stack). */
+ (which is on the stack). We have to remember that there was XCLASS data,
+ however. */
- if (lengthptr != NULL)
+ if (lengthptr != NULL && class_uchardata > class_uchardata_base)
{
+ xclass = TRUE;
*lengthptr += class_uchardata - class_uchardata_base;
class_uchardata = class_uchardata_base;
}
@@ -3912,7 +4243,7 @@ for (;; ptr++)
for (c = 0; c < 32; c++) pbits[c] &= ~cbits[c + taboffset];
}
- /* Not see if we need to remove any special characters. An option
+ /* Now see if we need to remove any special characters. An option
value of 1 removes vertical space and 2 removes underscore. */
if (tabopt < 0) tabopt = -tabopt;
@@ -3928,10 +4259,10 @@ for (;; ptr++)
for (c = 0; c < 32; c++) classbits[c] |= pbits[c];
ptr = tempptr + 1;
- /* Every class contains at least one < 256 characters. */
+ /* Every class contains at least one < 256 character. */
class_has_8bitchar = 1;
/* Every class contains at least two characters. */
- class_single_char = 2;
+ class_one_char = 2;
continue; /* End of POSIX syntax handling */
}
@@ -3939,23 +4270,26 @@ for (;; ptr++)
of the specials, which just set a flag. The sequence \b is a special
case. Inside a class (and only there) it is treated as backspace. We
assume that other escapes have more than one character in them, so
- speculatively set both class_has_8bitchar and class_single_char bigger
+ speculatively set both class_has_8bitchar and class_one_char bigger
than one. Unrecognized escapes fall through and are either treated
as literal characters (by default), or are faulted if
PCRE_EXTRA is set. */
if (c == CHAR_BACKSLASH)
{
- c = check_escape(&ptr, errorcodeptr, cd->bracount, options, TRUE);
+ escape = check_escape(&ptr, &ec, errorcodeptr, cd->bracount, options, TRUE);
+
if (*errorcodeptr != 0) goto FAILED;
- if (-c == ESC_b) c = CHAR_BS; /* \b is backspace in a class */
- else if (-c == ESC_N) /* \N is not supported in a class */
+ if (escape == 0)
+ c = ec;
+ else if (escape == ESC_b) c = CHAR_BS; /* \b is backspace in a class */
+ else if (escape == ESC_N) /* \N is not supported in a class */
{
*errorcodeptr = ERR71;
goto FAILED;
}
- else if (-c == ESC_Q) /* Handle start of quoted string */
+ else if (escape == ESC_Q) /* Handle start of quoted string */
{
if (ptr[1] == CHAR_BACKSLASH && ptr[2] == CHAR_E)
{
@@ -3964,17 +4298,17 @@ for (;; ptr++)
else inescq = TRUE;
continue;
}
- else if (-c == ESC_E) continue; /* Ignore orphan \E */
+ else if (escape == ESC_E) continue; /* Ignore orphan \E */
- if (c < 0)
+ else
{
register const pcre_uint8 *cbits = cd->cbits;
/* Every class contains at least two < 256 characters. */
class_has_8bitchar++;
/* Every class contains at least two characters. */
- class_single_char += 2;
+ class_one_char += 2;
- switch (-c)
+ switch (escape)
{
#ifdef SUPPORT_UCP
case ESC_du: /* These are the values given for \d etc */
@@ -3984,7 +4318,7 @@ for (;; ptr++)
case ESC_su: /* of the default ASCII testing. */
case ESC_SU:
nestptr = ptr;
- ptr = substitutes[-c - ESC_DU] - 1; /* Just before substitute */
+ ptr = substitutes[escape - ESC_DU] - 1; /* Just before substitute */
class_has_8bitchar--; /* Undo! */
continue;
#endif
@@ -4008,7 +4342,8 @@ for (;; ptr++)
/* Perl 5.004 onwards omits VT from \s, but we must preserve it
if it was previously set by something earlier in the character
- class. */
+ class. Luckily, the value of CHAR_VT is 0x0b in both ASCII and
+ EBCDIC, so we lazily just adjust the appropriate bit. */
case ESC_s:
classbits[0] |= cbits[cbit_space];
@@ -4022,180 +4357,26 @@ for (;; ptr++)
classbits[1] |= 0x08; /* Perl 5.004 onwards omits VT from \s */
continue;
+ /* The rest apply in both UCP and non-UCP cases. */
+
case ESC_h:
- SETBIT(classbits, 0x09); /* VT */
- SETBIT(classbits, 0x20); /* SPACE */
- SETBIT(classbits, 0xa0); /* NSBP */
-#ifndef COMPILE_PCRE8
- xclass = TRUE;
- *class_uchardata++ = XCL_SINGLE;
- *class_uchardata++ = 0x1680;
- *class_uchardata++ = XCL_SINGLE;
- *class_uchardata++ = 0x180e;
- *class_uchardata++ = XCL_RANGE;
- *class_uchardata++ = 0x2000;
- *class_uchardata++ = 0x200a;
- *class_uchardata++ = XCL_SINGLE;
- *class_uchardata++ = 0x202f;
- *class_uchardata++ = XCL_SINGLE;
- *class_uchardata++ = 0x205f;
- *class_uchardata++ = XCL_SINGLE;
- *class_uchardata++ = 0x3000;
-#elif defined SUPPORT_UTF
- if (utf)
- {
- xclass = TRUE;
- *class_uchardata++ = XCL_SINGLE;
- class_uchardata += PRIV(ord2utf)(0x1680, class_uchardata);
- *class_uchardata++ = XCL_SINGLE;
- class_uchardata += PRIV(ord2utf)(0x180e, class_uchardata);
- *class_uchardata++ = XCL_RANGE;
- class_uchardata += PRIV(ord2utf)(0x2000, class_uchardata);
- class_uchardata += PRIV(ord2utf)(0x200a, class_uchardata);
- *class_uchardata++ = XCL_SINGLE;
- class_uchardata += PRIV(ord2utf)(0x202f, class_uchardata);
- *class_uchardata++ = XCL_SINGLE;
- class_uchardata += PRIV(ord2utf)(0x205f, class_uchardata);
- *class_uchardata++ = XCL_SINGLE;
- class_uchardata += PRIV(ord2utf)(0x3000, class_uchardata);
- }
-#endif
+ (void)add_list_to_class(classbits, &class_uchardata, options, cd,
+ PRIV(hspace_list), NOTACHAR);
continue;
case ESC_H:
- for (c = 0; c < 32; c++)
- {
- int x = 0xff;
- switch (c)
- {
- case 0x09/8: x ^= 1 << (0x09%8); break;
- case 0x20/8: x ^= 1 << (0x20%8); break;
- case 0xa0/8: x ^= 1 << (0xa0%8); break;
- default: break;
- }
- classbits[c] |= x;
- }
-#ifndef COMPILE_PCRE8
- xclass = TRUE;
- *class_uchardata++ = XCL_RANGE;
- *class_uchardata++ = 0x0100;
- *class_uchardata++ = 0x167f;
- *class_uchardata++ = XCL_RANGE;
- *class_uchardata++ = 0x1681;
- *class_uchardata++ = 0x180d;
- *class_uchardata++ = XCL_RANGE;
- *class_uchardata++ = 0x180f;
- *class_uchardata++ = 0x1fff;
- *class_uchardata++ = XCL_RANGE;
- *class_uchardata++ = 0x200b;
- *class_uchardata++ = 0x202e;
- *class_uchardata++ = XCL_RANGE;
- *class_uchardata++ = 0x2030;
- *class_uchardata++ = 0x205e;
- *class_uchardata++ = XCL_RANGE;
- *class_uchardata++ = 0x2060;
- *class_uchardata++ = 0x2fff;
- *class_uchardata++ = XCL_RANGE;
- *class_uchardata++ = 0x3001;
-#ifdef SUPPORT_UTF
- if (utf)
- class_uchardata += PRIV(ord2utf)(0x10ffff, class_uchardata);
- else
-#endif
- *class_uchardata++ = 0xffff;
-#elif defined SUPPORT_UTF
- if (utf)
- {
- xclass = TRUE;
- *class_uchardata++ = XCL_RANGE;
- class_uchardata += PRIV(ord2utf)(0x0100, class_uchardata);
- class_uchardata += PRIV(ord2utf)(0x167f, class_uchardata);
- *class_uchardata++ = XCL_RANGE;
- class_uchardata += PRIV(ord2utf)(0x1681, class_uchardata);
- class_uchardata += PRIV(ord2utf)(0x180d, class_uchardata);
- *class_uchardata++ = XCL_RANGE;
- class_uchardata += PRIV(ord2utf)(0x180f, class_uchardata);
- class_uchardata += PRIV(ord2utf)(0x1fff, class_uchardata);
- *class_uchardata++ = XCL_RANGE;
- class_uchardata += PRIV(ord2utf)(0x200b, class_uchardata);
- class_uchardata += PRIV(ord2utf)(0x202e, class_uchardata);
- *class_uchardata++ = XCL_RANGE;
- class_uchardata += PRIV(ord2utf)(0x2030, class_uchardata);
- class_uchardata += PRIV(ord2utf)(0x205e, class_uchardata);
- *class_uchardata++ = XCL_RANGE;
- class_uchardata += PRIV(ord2utf)(0x2060, class_uchardata);
- class_uchardata += PRIV(ord2utf)(0x2fff, class_uchardata);
- *class_uchardata++ = XCL_RANGE;
- class_uchardata += PRIV(ord2utf)(0x3001, class_uchardata);
- class_uchardata += PRIV(ord2utf)(0x10ffff, class_uchardata);
- }
-#endif
+ (void)add_not_list_to_class(classbits, &class_uchardata, options,
+ cd, PRIV(hspace_list));
continue;
case ESC_v:
- SETBIT(classbits, 0x0a); /* LF */
- SETBIT(classbits, 0x0b); /* VT */
- SETBIT(classbits, 0x0c); /* FF */
- SETBIT(classbits, 0x0d); /* CR */
- SETBIT(classbits, 0x85); /* NEL */
-#ifndef COMPILE_PCRE8
- xclass = TRUE;
- *class_uchardata++ = XCL_RANGE;
- *class_uchardata++ = 0x2028;
- *class_uchardata++ = 0x2029;
-#elif defined SUPPORT_UTF
- if (utf)
- {
- xclass = TRUE;
- *class_uchardata++ = XCL_RANGE;
- class_uchardata += PRIV(ord2utf)(0x2028, class_uchardata);
- class_uchardata += PRIV(ord2utf)(0x2029, class_uchardata);
- }
-#endif
+ (void)add_list_to_class(classbits, &class_uchardata, options, cd,
+ PRIV(vspace_list), NOTACHAR);
continue;
case ESC_V:
- for (c = 0; c < 32; c++)
- {
- int x = 0xff;
- switch (c)
- {
- case 0x0a/8: x ^= 1 << (0x0a%8);
- x ^= 1 << (0x0b%8);
- x ^= 1 << (0x0c%8);
- x ^= 1 << (0x0d%8);
- break;
- case 0x85/8: x ^= 1 << (0x85%8); break;
- default: break;
- }
- classbits[c] |= x;
- }
-
-#ifndef COMPILE_PCRE8
- xclass = TRUE;
- *class_uchardata++ = XCL_RANGE;
- *class_uchardata++ = 0x0100;
- *class_uchardata++ = 0x2027;
- *class_uchardata++ = XCL_RANGE;
- *class_uchardata++ = 0x202a;
-#ifdef SUPPORT_UTF
- if (utf)
- class_uchardata += PRIV(ord2utf)(0x10ffff, class_uchardata);
- else
-#endif
- *class_uchardata++ = 0xffff;
-#elif defined SUPPORT_UTF
- if (utf)
- {
- xclass = TRUE;
- *class_uchardata++ = XCL_RANGE;
- class_uchardata += PRIV(ord2utf)(0x0100, class_uchardata);
- class_uchardata += PRIV(ord2utf)(0x2027, class_uchardata);
- *class_uchardata++ = XCL_RANGE;
- class_uchardata += PRIV(ord2utf)(0x202a, class_uchardata);
- class_uchardata += PRIV(ord2utf)(0x10ffff, class_uchardata);
- }
-#endif
+ (void)add_not_list_to_class(classbits, &class_uchardata, options,
+ cd, PRIV(vspace_list));
continue;
#ifdef SUPPORT_UCP
@@ -4203,11 +4384,10 @@ for (;; ptr++)
case ESC_P:
{
BOOL negated;
- int pdata;
- int ptype = get_ucp(&ptr, &negated, &pdata, errorcodeptr);
- if (ptype < 0) goto FAILED;
- xclass = TRUE;
- *class_uchardata++ = ((-c == ESC_p) != negated)?
+ unsigned int ptype = 0, pdata = 0;
+ if (!get_ucp(&ptr, &negated, &ptype, &pdata, errorcodeptr))
+ goto FAILED;
+ *class_uchardata++ = ((escape == ESC_p) != negated)?
XCL_PROP : XCL_NOTPROP;
*class_uchardata++ = ptype;
*class_uchardata++ = pdata;
@@ -4226,21 +4406,23 @@ for (;; ptr++)
goto FAILED;
}
class_has_8bitchar--; /* Undo the speculative increase. */
- class_single_char -= 2; /* Undo the speculative increase. */
+ class_one_char -= 2; /* Undo the speculative increase. */
c = *ptr; /* Get the final character and fall through */
break;
}
}
- /* Fall through if we have a single character (c >= 0). This may be
- greater than 256. */
+ /* Fall through if the escape just defined a single character (c >= 0).
+ This may be greater than 256. */
+
+ escape = 0;
} /* End of backslash handling */
- /* A single character may be followed by '-' to form a range. However,
- Perl does not permit ']' to be the end of the range. A '-' character
- at the end is treated as a literal. Perl ignores orphaned \E sequences
- entirely. The code for handling \Q and \E is messy. */
+ /* A character may be followed by '-' to form a range. However, Perl does
+ not permit ']' to be the end of the range. A '-' character at the end is
+ treated as a literal. Perl ignores orphaned \E sequences entirely. The
+ code for handling \Q and \E is messy. */
CHECK_RANGE:
while (ptr[1] == CHAR_BACKSLASH && ptr[2] == CHAR_E)
@@ -4248,10 +4430,9 @@ for (;; ptr++)
inescq = FALSE;
ptr += 2;
}
-
oldptr = ptr;
- /* Remember \r or \n */
+ /* Remember if \r or \n were explicitly used */
if (c == CHAR_CR || c == CHAR_NL) cd->external_flags |= PCRE_HASCRORLF;
@@ -4259,7 +4440,7 @@ for (;; ptr++)
if (!inescq && ptr[1] == CHAR_MINUS)
{
- int d;
+ pcre_uint32 d;
ptr += 2;
while (*ptr == CHAR_BACKSLASH && ptr[1] == CHAR_E) ptr += 2;
@@ -4275,12 +4456,17 @@ for (;; ptr++)
break;
}
- if (*ptr == 0 || (!inescq && *ptr == CHAR_RIGHT_SQUARE_BRACKET))
+ /* Minus (hyphen) at the end of a class is treated as a literal, so put
+ back the pointer and jump to handle the character that preceded it. */
+
+ if (*ptr == CHAR_NULL || (!inescq && *ptr == CHAR_RIGHT_SQUARE_BRACKET))
{
ptr = oldptr;
- goto LONE_SINGLE_CHARACTER;
+ goto CLASS_SINGLE_CHARACTER;
}
+ /* Otherwise, we have a potential range; pick up the next character */
+
#ifdef SUPPORT_UTF
if (utf)
{ /* Braces are required because the */
@@ -4296,235 +4482,116 @@ for (;; ptr++)
if (!inescq && d == CHAR_BACKSLASH)
{
- d = check_escape(&ptr, errorcodeptr, cd->bracount, options, TRUE);
+ int descape;
+ descape = check_escape(&ptr, &d, errorcodeptr, cd->bracount, options, TRUE);
if (*errorcodeptr != 0) goto FAILED;
- /* \b is backspace; any other special means the '-' was literal */
+ /* \b is backspace; any other special means the '-' was literal. */
- if (d < 0)
+ if (descape != 0)
{
- if (d == -ESC_b) d = CHAR_BS; else
+ if (descape == ESC_b) d = CHAR_BS; else
{
ptr = oldptr;
- goto LONE_SINGLE_CHARACTER; /* A few lines below */
+ goto CLASS_SINGLE_CHARACTER; /* A few lines below */
}
}
}
/* Check that the two values are in the correct order. Optimize
- one-character ranges */
+ one-character ranges. */
if (d < c)
{
*errorcodeptr = ERR8;
goto FAILED;
}
+ if (d == c) goto CLASS_SINGLE_CHARACTER; /* A few lines below */
- if (d == c) goto LONE_SINGLE_CHARACTER; /* A few lines below */
+ /* We have found a character range, so single character optimizations
+ cannot be done anymore. Any value greater than 1 indicates that there
+ is more than one character. */
- /* Remember \r or \n */
+ class_one_char = 2;
- if (d == CHAR_CR || d == CHAR_NL) cd->external_flags |= PCRE_HASCRORLF;
+ /* Remember an explicit \r or \n, and add the range to the class. */
- /* Since we found a character range, single character optimizations
- cannot be done anymore. */
- class_single_char = 2;
-
- /* In UTF-8 mode, if the upper limit is > 255, or > 127 for caseless
- matching, we have to use an XCLASS with extra data items. Caseless
- matching for characters > 127 is available only if UCP support is
- available. */
-
-#if defined SUPPORT_UTF && !(defined COMPILE_PCRE8)
- if ((d > 255) || (utf && ((options & PCRE_CASELESS) != 0 && d > 127)))
-#elif defined SUPPORT_UTF
- if (utf && (d > 255 || ((options & PCRE_CASELESS) != 0 && d > 127)))
-#elif !(defined COMPILE_PCRE8)
- if (d > 255)
-#endif
-#if defined SUPPORT_UTF || !(defined COMPILE_PCRE8)
- {
- xclass = TRUE;
+ if (d == CHAR_CR || d == CHAR_NL) cd->external_flags |= PCRE_HASCRORLF;
- /* With UCP support, we can find the other case equivalents of
- the relevant characters. There may be several ranges. Optimize how
- they fit with the basic range. */
+ class_has_8bitchar +=
+ add_to_class(classbits, &class_uchardata, options, cd, c, d);
-#ifdef SUPPORT_UCP
-#ifndef COMPILE_PCRE8
- if (utf && (options & PCRE_CASELESS) != 0)
-#else
- if ((options & PCRE_CASELESS) != 0)
-#endif
- {
- unsigned int occ, ocd;
- unsigned int cc = c;
- unsigned int origd = d;
- while (get_othercase_range(&cc, origd, &occ, &ocd))
- {
- if (occ >= (unsigned int)c &&
- ocd <= (unsigned int)d)
- continue; /* Skip embedded ranges */
-
- if (occ < (unsigned int)c &&
- ocd >= (unsigned int)c - 1) /* Extend the basic range */
- { /* if there is overlap, */
- c = occ; /* noting that if occ < c */
- continue; /* we can't have ocd > d */
- } /* because a subrange is */
- if (ocd > (unsigned int)d &&
- occ <= (unsigned int)d + 1) /* always shorter than */
- { /* the basic range. */
- d = ocd;
- continue;
- }
-
- if (occ == ocd)
- {
- *class_uchardata++ = XCL_SINGLE;
- }
- else
- {
- *class_uchardata++ = XCL_RANGE;
- class_uchardata += PRIV(ord2utf)(occ, class_uchardata);
- }
- class_uchardata += PRIV(ord2utf)(ocd, class_uchardata);
- }
- }
-#endif /* SUPPORT_UCP */
+ continue; /* Go get the next char in the class */
+ }
- /* Now record the original range, possibly modified for UCP caseless
- overlapping ranges. */
+ /* Handle a single character - we can get here for a normal non-escape
+ char, or after \ that introduces a single character or for an apparent
+ range that isn't. Only the value 1 matters for class_one_char, so don't
+ increase it if it is already 2 or more ... just in case there's a class
+ with a zillion characters in it. */
+
+ CLASS_SINGLE_CHARACTER:
+ if (class_one_char < 2) class_one_char++;
+
+ /* If class_one_char is 1, we have the first single character in the
+ class, and there have been no prior ranges, or XCLASS items generated by
+ escapes. If this is the final character in the class, we can optimize by
+ turning the item into a 1-character OP_CHAR[I] if it's positive, or
+ OP_NOT[I] if it's negative. In the positive case, it can cause firstchar
+ to be set. Otherwise, there can be no first char if this item is first,
+ whatever repeat count may follow. In the case of reqchar, save the
+ previous value for reinstating. */
+
+ if (class_one_char == 1 && ptr[1] == CHAR_RIGHT_SQUARE_BRACKET)
+ {
+ ptr++;
+ zeroreqchar = reqchar;
+ zeroreqcharflags = reqcharflags;
- *class_uchardata++ = XCL_RANGE;
-#ifdef SUPPORT_UTF
-#ifndef COMPILE_PCRE8
- if (utf)
- {
- class_uchardata += PRIV(ord2utf)(c, class_uchardata);
- class_uchardata += PRIV(ord2utf)(d, class_uchardata);
- }
- else
- {
- *class_uchardata++ = c;
- *class_uchardata++ = d;
- }
-#else
- class_uchardata += PRIV(ord2utf)(c, class_uchardata);
- class_uchardata += PRIV(ord2utf)(d, class_uchardata);
+ if (negate_class)
+ {
+#ifdef SUPPORT_UCP
+ int d;
#endif
-#else /* SUPPORT_UTF */
- *class_uchardata++ = c;
- *class_uchardata++ = d;
-#endif /* SUPPORT_UTF */
+ if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE;
+ zerofirstchar = firstchar;
+ zerofirstcharflags = firstcharflags;
- /* With UCP support, we are done. Without UCP support, there is no
- caseless matching for UTF characters > 127; we can use the bit map
- for the smaller ones. As for 16 bit characters without UTF, we
- can still use */
+ /* For caseless UTF-8 mode when UCP support is available, check
+ whether this character has more than one other case. If so, generate
+ a special OP_NOTPROP item instead of OP_NOTI. */
#ifdef SUPPORT_UCP
-#ifndef COMPILE_PCRE8
- if (utf)
-#endif
- continue; /* With next character in the class */
-#endif /* SUPPORT_UCP */
-
-#if defined SUPPORT_UTF && !defined(SUPPORT_UCP) && !(defined COMPILE_PCRE8)
- if (utf)
+ if (utf && (options & PCRE_CASELESS) != 0 &&
+ (d = UCD_CASESET(c)) != 0)
{
- if ((options & PCRE_CASELESS) == 0 || c > 127) continue;
- /* Adjust upper limit and fall through to set up the map */
- d = 127;
+ *code++ = OP_NOTPROP;
+ *code++ = PT_CLIST;
+ *code++ = d;
}
else
- {
- if (c > 255) continue;
- /* Adjust upper limit and fall through to set up the map */
- d = 255;
- }
-#elif defined SUPPORT_UTF && !defined(SUPPORT_UCP)
- if ((options & PCRE_CASELESS) == 0 || c > 127) continue;
- /* Adjust upper limit and fall through to set up the map */
- d = 127;
-#else
- if (c > 255) continue;
- /* Adjust upper limit and fall through to set up the map */
- d = 255;
-#endif /* SUPPORT_UTF && !SUPPORT_UCP && !COMPILE_PCRE8 */
- }
-#endif /* SUPPORT_UTF || !COMPILE_PCRE8 */
-
- /* We use the bit map for 8 bit mode, or when the characters fall
- partially or entirely to [0-255] ([0-127] for UCP) ranges. */
-
- class_has_8bitchar = 1;
-
- /* We can save a bit of time by skipping this in the pre-compile. */
+#endif
+ /* Char has only one other case, or UCP not available */
- if (lengthptr == NULL) for (; c <= d; c++)
- {
- classbits[c/8] |= (1 << (c&7));
- if ((options & PCRE_CASELESS) != 0)
{
- int uc = cd->fcc[c]; /* flip case */
- classbits[uc/8] |= (1 << (uc&7));
- }
- }
-
- continue; /* Go get the next char in the class */
- }
-
- /* Handle a lone single character - we can get here for a normal
- non-escape char, or after \ that introduces a single character or for an
- apparent range that isn't. */
-
- LONE_SINGLE_CHARACTER:
-
- /* Only the value of 1 matters for class_single_char. */
- if (class_single_char < 2) class_single_char++;
-
- /* If class_charcount is 1, we saw precisely one character. As long as
- there were no negated characters >= 128 and there was no use of \p or \P,
- in other words, no use of any XCLASS features, we can optimize.
-
- In UTF-8 mode, we can optimize the negative case only if there were no
- characters >= 128 because OP_NOT and the related opcodes like OP_NOTSTAR
- operate on single-bytes characters only. This is an historical hangover.
- Maybe one day we can tidy these opcodes to handle multi-byte characters.
-
- The optimization throws away the bit map. We turn the item into a
- 1-character OP_CHAR[I] if it's positive, or OP_NOT[I] if it's negative.
- Note that OP_NOT[I] does not support multibyte characters. In the positive
- case, it can cause firstchar to be set. Otherwise, there can be no first
- char if this item is first, whatever repeat count may follow. In the case
- of reqchar, save the previous value for reinstating. */
-
-#ifdef SUPPORT_UTF
- if (class_single_char == 1 && ptr[1] == CHAR_RIGHT_SQUARE_BRACKET
- && (!utf || !negate_class || c < (MAX_VALUE_FOR_SINGLE_CHAR + 1)))
-#else
- if (class_single_char == 1 && ptr[1] == CHAR_RIGHT_SQUARE_BRACKET)
+ *code++ = ((options & PCRE_CASELESS) != 0)? OP_NOTI: OP_NOT;
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
+ if (utf && c > MAX_VALUE_FOR_SINGLE_CHAR)
+ code += PRIV(ord2utf)(c, code);
+ else
#endif
- {
- ptr++;
- zeroreqchar = reqchar;
+ *code++ = c;
+ }
- /* The OP_NOT[I] opcodes work on single characters only. */
+ /* We are finished with this character class */
- if (negate_class)
- {
- if (firstchar == REQ_UNSET) firstchar = REQ_NONE;
- zerofirstchar = firstchar;
- *code++ = ((options & PCRE_CASELESS) != 0)? OP_NOTI: OP_NOT;
- *code++ = c;
- goto NOT_CHAR;
+ goto END_CLASS;
}
/* For a single, positive character, get the value into mcbuffer, and
then we can handle this with the normal one-character code. */
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
if (utf && c > MAX_VALUE_FOR_SINGLE_CHAR)
mclength = PRIV(ord2utf)(c, mcbuffer);
else
@@ -4536,89 +4603,51 @@ for (;; ptr++)
goto ONE_CHAR;
} /* End of 1-char optimization */
- /* Handle a character that cannot go in the bit map. */
+ /* There is more than one character in the class, or an XCLASS item
+ has been generated. Add this character to the class. */
-#if defined SUPPORT_UTF && !(defined COMPILE_PCRE8)
- if ((c > 255) || (utf && ((options & PCRE_CASELESS) != 0 && c > 127)))
-#elif defined SUPPORT_UTF
- if (utf && (c > 255 || ((options & PCRE_CASELESS) != 0 && c > 127)))
-#elif !(defined COMPILE_PCRE8)
- if (c > 255)
-#endif
-
-#if defined SUPPORT_UTF || !(defined COMPILE_PCRE8)
- {
- xclass = TRUE;
- *class_uchardata++ = XCL_SINGLE;
-#ifdef SUPPORT_UTF
-#ifndef COMPILE_PCRE8
- /* In non 8 bit mode, we can get here even if we are not in UTF mode. */
- if (!utf)
- *class_uchardata++ = c;
- else
-#endif
- class_uchardata += PRIV(ord2utf)(c, class_uchardata);
-#else /* SUPPORT_UTF */
- *class_uchardata++ = c;
-#endif /* SUPPORT_UTF */
-
-#ifdef SUPPORT_UCP
-#ifdef COMPILE_PCRE8
- if ((options & PCRE_CASELESS) != 0)
-#else
- /* In non 8 bit mode, we can get here even if we are not in UTF mode. */
- if (utf && (options & PCRE_CASELESS) != 0)
-#endif
- {
- unsigned int othercase;
- if ((int)(othercase = UCD_OTHERCASE(c)) != c)
- {
- *class_uchardata++ = XCL_SINGLE;
- class_uchardata += PRIV(ord2utf)(othercase, class_uchardata);
- }
- }
-#endif /* SUPPORT_UCP */
-
- }
- else
-#endif /* SUPPORT_UTF || COMPILE_PCRE16 */
-
- /* Handle a single-byte character */
- {
- class_has_8bitchar = 1;
- classbits[c/8] |= (1 << (c&7));
- if ((options & PCRE_CASELESS) != 0)
- {
- c = cd->fcc[c]; /* flip case */
- classbits[c/8] |= (1 << (c&7));
- }
- }
+ class_has_8bitchar +=
+ add_to_class(classbits, &class_uchardata, options, cd, c, c);
}
/* Loop until ']' reached. This "while" is the end of the "do" far above.
If we are at the end of an internal nested string, revert to the outer
string. */
- while (((c = *(++ptr)) != 0 ||
+ while (((c = *(++ptr)) != CHAR_NULL ||
(nestptr != NULL &&
- (ptr = nestptr, nestptr = NULL, c = *(++ptr)) != 0)) &&
+ (ptr = nestptr, nestptr = NULL, c = *(++ptr)) != CHAR_NULL)) &&
(c != CHAR_RIGHT_SQUARE_BRACKET || inescq));
/* Check for missing terminating ']' */
- if (c == 0)
+ if (c == CHAR_NULL)
{
*errorcodeptr = ERR6;
goto FAILED;
}
+ /* We will need an XCLASS if data has been placed in class_uchardata. In
+ the second phase this is a sufficient test. However, in the pre-compile
+ phase, class_uchardata gets emptied to prevent workspace overflow, so it
+ only if the very last character in the class needs XCLASS will it contain
+ anything at this point. For this reason, xclass gets set TRUE above when
+ uchar_classdata is emptied, and that's why this code is the way it is here
+ instead of just doing a test on class_uchardata below. */
+
+#if defined SUPPORT_UTF || !defined COMPILE_PCRE8
+ if (class_uchardata > class_uchardata_base) xclass = TRUE;
+#endif
+
/* If this is the first thing in the branch, there can be no first char
setting, whatever the repeat count. Any reqchar setting must remain
unchanged after any kind of repeat. */
- if (firstchar == REQ_UNSET) firstchar = REQ_NONE;
+ if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE;
zerofirstchar = firstchar;
+ zerofirstcharflags = firstcharflags;
zeroreqchar = reqchar;
+ zeroreqcharflags = reqcharflags;
/* If there are characters with values > 255, we have to compile an
extended class, with its own opcode, unless there was a negated special
@@ -4674,7 +4703,8 @@ for (;; ptr++)
memcpy(code, classbits, 32);
}
code += 32 / sizeof(pcre_uchar);
- NOT_CHAR:
+
+ END_CLASS:
break;
@@ -4712,7 +4742,9 @@ for (;; ptr++)
if (repeat_min == 0)
{
firstchar = zerofirstchar; /* Adjust for zero repeat */
+ firstcharflags = zerofirstcharflags;
reqchar = zeroreqchar; /* Ditto */
+ reqcharflags = zeroreqcharflags;
}
/* Remember whether this is a variable length repeat */
@@ -4775,22 +4807,30 @@ for (;; ptr++)
/* Now handle repetition for the different types of item. */
- /* If previous was a character match, abolish the item and generate a
- repeat item instead. If a char item has a minumum of more than one, ensure
- that it is set in reqchar - it might not be if a sequence such as x{3} is
- the first thing in a branch because the x will have gone into firstchar
- instead. */
+ /* If previous was a character or negated character match, abolish the item
+ and generate a repeat item instead. If a char item has a minimum of more
+ than one, ensure that it is set in reqchar - it might not be if a sequence
+ such as x{3} is the first thing in a branch because the x will have gone
+ into firstchar instead. */
- if (*previous == OP_CHAR || *previous == OP_CHARI)
+ if (*previous == OP_CHAR || *previous == OP_CHARI
+ || *previous == OP_NOT || *previous == OP_NOTI)
{
- op_type = (*previous == OP_CHAR)? 0 : OP_STARI - OP_STAR;
+ switch (*previous)
+ {
+ default: /* Make compiler happy. */
+ case OP_CHAR: op_type = OP_STAR - OP_STAR; break;
+ case OP_CHARI: op_type = OP_STARI - OP_STAR; break;
+ case OP_NOT: op_type = OP_NOTSTAR - OP_STAR; break;
+ case OP_NOTI: op_type = OP_NOTSTARI - OP_STAR; break;
+ }
/* Deal with UTF characters that take up more than one character. It's
easier to write this out separately than try to macrify it. Use c to
hold the length of the character in bytes, plus UTF_LENGTH to flag that
it's a length rather than a small character. */
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
if (utf && NOT_FIRSTCHAR(code[-1]))
{
pcre_uchar *lastchar = code - 1;
@@ -4806,7 +4846,11 @@ for (;; ptr++)
with UTF disabled, or for a single character UTF character. */
{
c = code[-1];
- if (repeat_min > 1) reqchar = c | req_caseopt | cd->req_varyopt;
+ if (*previous <= OP_CHARI && repeat_min > 1)
+ {
+ reqchar = c;
+ reqcharflags = req_caseopt | cd->req_varyopt;
+ }
}
/* If the repetition is unlimited, it pays to see if the next thing on
@@ -4825,26 +4869,6 @@ for (;; ptr++)
goto OUTPUT_SINGLE_REPEAT; /* Code shared with single character types */
}
- /* If previous was a single negated character ([^a] or similar), we use
- one of the special opcodes, replacing it. The code is shared with single-
- character repeats by setting opt_type to add a suitable offset into
- repeat_type. We can also test for auto-possessification. OP_NOT and OP_NOTI
- are currently used only for single-byte chars. */
-
- else if (*previous == OP_NOT || *previous == OP_NOTI)
- {
- op_type = ((*previous == OP_NOT)? OP_NOTSTAR : OP_NOTSTARI) - OP_STAR;
- c = previous[1];
- if (!possessive_quantifier &&
- repeat_max < 0 &&
- check_auto_possessive(previous, utf, ptr + 1, options, cd))
- {
- repeat_type = 0; /* Force greedy */
- possessive_quantifier = TRUE;
- }
- goto OUTPUT_SINGLE_REPEAT;
- }
-
/* If previous was a character type match (\d or similar), abolish it and
create a suitable repeat item. The code is shared with single-character
repeats by setting op_type to add a suitable offset into repeat_type. Note
@@ -4945,7 +4969,7 @@ for (;; ptr++)
if (repeat_max < 0)
{
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
if (utf && (c & UTF_LENGTH) != 0)
{
memcpy(code, utf_chars, IN_UCHARS(c & 7));
@@ -4970,7 +4994,7 @@ for (;; ptr++)
else if (repeat_max != repeat_min)
{
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
if (utf && (c & UTF_LENGTH) != 0)
{
memcpy(code, utf_chars, IN_UCHARS(c & 7));
@@ -5000,7 +5024,7 @@ for (;; ptr++)
/* The character or character type itself comes last in all cases. */
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
if (utf && (c & UTF_LENGTH) != 0)
{
memcpy(code, utf_chars, IN_UCHARS(c & 7));
@@ -5208,7 +5232,11 @@ for (;; ptr++)
else
{
- if (groupsetfirstchar && reqchar < 0) reqchar = firstchar;
+ if (groupsetfirstchar && reqcharflags < 0)
+ {
+ reqchar = firstchar;
+ reqcharflags = firstcharflags;
+ }
for (i = 1; i < repeat_min; i++)
{
@@ -5583,8 +5611,13 @@ for (;; ptr++)
if (*ptr == CHAR_COLON)
{
arg = ++ptr;
- while (*ptr != 0 && *ptr != CHAR_RIGHT_PARENTHESIS) ptr++;
+ while (*ptr != CHAR_NULL && *ptr != CHAR_RIGHT_PARENTHESIS) ptr++;
arglen = (int)(ptr - arg);
+ if ((unsigned int)arglen > MAX_MARK)
+ {
+ *errorcodeptr = ERR75;
+ goto FAILED;
+ }
}
if (*ptr != CHAR_RIGHT_PARENTHESIS)
@@ -5600,6 +5633,8 @@ for (;; ptr++)
if (namelen == verbs[i].len &&
STRNCMP_UC_C8(name, vn, namelen) == 0)
{
+ int setverb;
+
/* Check for open captures before ACCEPT and convert it to
ASSERT_ACCEPT if in an assertion. */
@@ -5617,10 +5652,11 @@ for (;; ptr++)
*code++ = OP_CLOSE;
PUT2INC(code, 0, oc->number);
}
- *code++ = (cd->assert_depth > 0)? OP_ASSERT_ACCEPT : OP_ACCEPT;
+ setverb = *code++ =
+ (cd->assert_depth > 0)? OP_ASSERT_ACCEPT : OP_ACCEPT;
/* Do not set firstchar after *ACCEPT */
- if (firstchar == REQ_UNSET) firstchar = REQ_NONE;
+ if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE;
}
/* Handle other cases with/without an argument */
@@ -5632,8 +5668,7 @@ for (;; ptr++)
*errorcodeptr = ERR66;
goto FAILED;
}
- *code = verbs[i].op;
- if (*code++ == OP_THEN) cd->external_flags |= PCRE_HASTHEN;
+ setverb = *code++ = verbs[i].op;
}
else
@@ -5643,14 +5678,28 @@ for (;; ptr++)
*errorcodeptr = ERR59;
goto FAILED;
}
- *code = verbs[i].op_arg;
- if (*code++ == OP_THEN_ARG) cd->external_flags |= PCRE_HASTHEN;
+ setverb = *code++ = verbs[i].op_arg;
*code++ = arglen;
memcpy(code, arg, IN_UCHARS(arglen));
code += arglen;
*code++ = 0;
}
+ switch (setverb)
+ {
+ case OP_THEN:
+ case OP_THEN_ARG:
+ cd->external_flags |= PCRE_HASTHEN;
+ break;
+
+ case OP_PRUNE:
+ case OP_PRUNE_ARG:
+ case OP_SKIP:
+ case OP_SKIP_ARG:
+ cd->had_pruneorskip = TRUE;
+ break;
+ }
+
break; /* Found verb, exit loop */
}
@@ -5676,8 +5725,8 @@ for (;; ptr++)
{
case CHAR_NUMBER_SIGN: /* Comment; skip to ket */
ptr++;
- while (*ptr != 0 && *ptr != CHAR_RIGHT_PARENTHESIS) ptr++;
- if (*ptr == 0)
+ while (*ptr != CHAR_NULL && *ptr != CHAR_RIGHT_PARENTHESIS) ptr++;
+ if (*ptr == CHAR_NULL)
{
*errorcodeptr = ERR18;
goto FAILED;
@@ -5753,7 +5802,7 @@ for (;; ptr++)
}
else
{
- terminator = 0;
+ terminator = CHAR_NULL;
if (ptr[1] == CHAR_MINUS || ptr[1] == CHAR_PLUS) refsign = *(++ptr);
}
@@ -5773,12 +5822,12 @@ for (;; ptr++)
while (MAX_255(*ptr) && (cd->ctypes[*ptr] & ctype_word) != 0)
{
if (recno >= 0)
- recno = (IS_DIGIT(*ptr))? recno * 10 + *ptr - CHAR_0 : -1;
+ recno = (IS_DIGIT(*ptr))? recno * 10 + (int)(*ptr - CHAR_0) : -1;
ptr++;
}
namelen = (int)(ptr - name);
- if ((terminator > 0 && *ptr++ != terminator) ||
+ if ((terminator > 0 && *ptr++ != (pcre_uchar)terminator) ||
*ptr++ != CHAR_RIGHT_PARENTHESIS)
{
ptr--; /* Error offset */
@@ -5843,13 +5892,13 @@ for (;; ptr++)
code[1+LINK_SIZE]++;
}
- /* If terminator == 0 it means that the name followed directly after
- the opening parenthesis [e.g. (?(abc)...] and in this case there are
- some further alternatives to try. For the cases where terminator != 0
- [things like (?(<name>... or (?('name')... or (?(R&name)... ] we have
+ /* If terminator == CHAR_NULL it means that the name followed directly
+ after the opening parenthesis [e.g. (?(abc)...] and in this case there
+ are some further alternatives to try. For the cases where terminator !=
+ 0 [things like (?(<name>... or (?('name')... or (?(R&name)... ] we have
now checked all the possibilities, so give an error. */
- else if (terminator != 0)
+ else if (terminator != CHAR_NULL)
{
*errorcodeptr = ERR15;
goto FAILED;
@@ -6018,7 +6067,7 @@ for (;; ptr++)
if (lengthptr != NULL)
{
- if (*ptr != terminator)
+ if (*ptr != (pcre_uchar)terminator)
{
*errorcodeptr = ERR42;
goto FAILED;
@@ -6160,7 +6209,7 @@ for (;; ptr++)
*errorcodeptr = ERR62;
goto FAILED;
}
- if (*ptr != terminator)
+ if (*ptr != (pcre_uchar)terminator)
{
*errorcodeptr = ERR42;
goto FAILED;
@@ -6266,7 +6315,7 @@ for (;; ptr++)
while(IS_DIGIT(*ptr))
recno = recno * 10 + *ptr++ - CHAR_0;
- if (*ptr != terminator)
+ if (*ptr != (pcre_uchar)terminator)
{
*errorcodeptr = ERR29;
goto FAILED;
@@ -6370,7 +6419,7 @@ for (;; ptr++)
/* Can't determine a first byte now */
- if (firstchar == REQ_UNSET) firstchar = REQ_NONE;
+ if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE;
continue;
@@ -6504,7 +6553,9 @@ for (;; ptr++)
cond_depth +
((bravalue == OP_COND)?1:0), /* Depth of condition subpatterns */
&subfirstchar, /* For possible first char */
+ &subfirstcharflags,
&subreqchar, /* For possible last char */
+ &subreqcharflags,
bcptr, /* Current branch chain */
cd, /* Tables block */
(lengthptr == NULL)? NULL : /* Actual compile phase */
@@ -6565,7 +6616,7 @@ for (;; ptr++)
*errorcodeptr = ERR27;
goto FAILED;
}
- if (condcount == 1) subfirstchar = subreqchar = REQ_NONE;
+ if (condcount == 1) subfirstcharflags = subreqcharflags = REQ_NONE;
}
}
@@ -6614,7 +6665,9 @@ for (;; ptr++)
back off. */
zeroreqchar = reqchar;
+ zeroreqcharflags = reqcharflags;
zerofirstchar = firstchar;
+ zerofirstcharflags = firstcharflags;
groupsetfirstchar = FALSE;
if (bravalue >= OP_ONCE)
@@ -6625,28 +6678,36 @@ for (;; ptr++)
no firstchar, set "none" for the whole branch. In both cases, a zero
repeat forces firstchar to "none". */
- if (firstchar == REQ_UNSET)
+ if (firstcharflags == REQ_UNSET)
{
- if (subfirstchar >= 0)
+ if (subfirstcharflags >= 0)
{
firstchar = subfirstchar;
+ firstcharflags = subfirstcharflags;
groupsetfirstchar = TRUE;
}
- else firstchar = REQ_NONE;
- zerofirstchar = REQ_NONE;
+ else firstcharflags = REQ_NONE;
+ zerofirstcharflags = REQ_NONE;
}
/* If firstchar was previously set, convert the subpattern's firstchar
into reqchar if there wasn't one, using the vary flag that was in
existence beforehand. */
- else if (subfirstchar >= 0 && subreqchar < 0)
- subreqchar = subfirstchar | tempreqvary;
+ else if (subfirstcharflags >= 0 && subreqcharflags < 0)
+ {
+ subreqchar = subfirstchar;
+ subreqcharflags = subfirstcharflags | tempreqvary;
+ }
/* If the subpattern set a required byte (or set a first byte that isn't
really the first byte - see above), set it. */
- if (subreqchar >= 0) reqchar = subreqchar;
+ if (subreqcharflags >= 0)
+ {
+ reqchar = subreqchar;
+ reqcharflags = subreqcharflags;
+ }
}
/* For a forward assertion, we take the reqchar, if set. This can be
@@ -6657,7 +6718,11 @@ for (;; ptr++)
of a firstchar. This is overcome by a scan at the end if there's no
firstchar, looking for an asserted first char. */
- else if (bravalue == OP_ASSERT && subreqchar >= 0) reqchar = subreqchar;
+ else if (bravalue == OP_ASSERT && subreqcharflags >= 0)
+ {
+ reqchar = subreqchar;
+ reqcharflags = subreqcharflags;
+ }
break; /* End of processing '(' */
@@ -6665,19 +6730,22 @@ for (;; ptr++)
/* Handle metasequences introduced by \. For ones like \d, the ESC_ values
are arranged to be the negation of the corresponding OP_values in the
default case when PCRE_UCP is not set. For the back references, the values
- are ESC_REF plus the reference number. Only back references and those types
+ are negative the reference number. Only back references and those types
that consume a character may be repeated. We can test for values between
ESC_b and ESC_Z for the latter; this may have to change if any new ones are
ever created. */
case CHAR_BACKSLASH:
tempptr = ptr;
- c = check_escape(&ptr, errorcodeptr, cd->bracount, options, FALSE);
+ escape = check_escape(&ptr, &ec, errorcodeptr, cd->bracount, options, FALSE);
+
if (*errorcodeptr != 0) goto FAILED;
- if (c < 0)
+ if (escape == 0)
+ c = ec;
+ else
{
- if (-c == ESC_Q) /* Handle start of quoted string */
+ if (escape == ESC_Q) /* Handle start of quoted string */
{
if (ptr[1] == CHAR_BACKSLASH && ptr[2] == CHAR_E)
ptr += 2; /* avoid empty string */
@@ -6685,27 +6753,29 @@ for (;; ptr++)
continue;
}
- if (-c == ESC_E) continue; /* Perl ignores an orphan \E */
+ if (escape == ESC_E) continue; /* Perl ignores an orphan \E */
/* For metasequences that actually match a character, we disable the
setting of a first character if it hasn't already been set. */
- if (firstchar == REQ_UNSET && -c > ESC_b && -c < ESC_Z)
- firstchar = REQ_NONE;
+ if (firstcharflags == REQ_UNSET && escape > ESC_b && escape < ESC_Z)
+ firstcharflags = REQ_NONE;
/* Set values to reset to if this is followed by a zero repeat. */
zerofirstchar = firstchar;
+ zerofirstcharflags = firstcharflags;
zeroreqchar = reqchar;
+ zeroreqcharflags = reqcharflags;
/* \g<name> or \g'name' is a subroutine call by name and \g<n> or \g'n'
is a subroutine call by number (Oniguruma syntax). In fact, the value
- -ESC_g is returned only for these cases. So we don't need to check for <
- or ' if the value is -ESC_g. For the Perl syntax \g{n} the value is
- -ESC_REF+n, and for the Perl syntax \g{name} the result is -ESC_k (as
+ ESC_g is returned only for these cases. So we don't need to check for <
+ or ' if the value is ESC_g. For the Perl syntax \g{n} the value is
+ -n, and for the Perl syntax \g{name} the result is ESC_k (as
that is a synonym for a named back reference). */
- if (-c == ESC_g)
+ if (escape == ESC_g)
{
const pcre_uchar *p;
save_hwm = cd->hwm; /* Normally this is set when '(' is read */
@@ -6725,13 +6795,13 @@ for (;; ptr++)
if (ptr[1] != CHAR_PLUS && ptr[1] != CHAR_MINUS)
{
BOOL is_a_number = TRUE;
- for (p = ptr + 1; *p != 0 && *p != terminator; p++)
+ for (p = ptr + 1; *p != CHAR_NULL && *p != (pcre_uchar)terminator; p++)
{
if (!MAX_255(*p)) { is_a_number = FALSE; break; }
if ((cd->ctypes[*p] & ctype_digit) == 0) is_a_number = FALSE;
if ((cd->ctypes[*p] & ctype_word) == 0) break;
}
- if (*p != terminator)
+ if (*p != (pcre_uchar)terminator)
{
*errorcodeptr = ERR57;
break;
@@ -6749,7 +6819,7 @@ for (;; ptr++)
p = ptr + 2;
while (IS_DIGIT(*p)) p++;
- if (*p != terminator)
+ if (*p != (pcre_uchar)terminator)
{
*errorcodeptr = ERR57;
break;
@@ -6761,7 +6831,7 @@ for (;; ptr++)
/* \k<name> or \k'name' is a back reference by name (Perl syntax).
We also support \k{name} (.NET syntax). */
- if (-c == ESC_k)
+ if (escape == ESC_k)
{
if ((ptr[1] != CHAR_LESS_THAN_SIGN &&
ptr[1] != CHAR_APOSTROPHE && ptr[1] != CHAR_LEFT_CURLY_BRACKET))
@@ -6780,13 +6850,13 @@ for (;; ptr++)
not set to cope with cases like (?=(\w+))\1: which would otherwise set
':' later. */
- if (-c >= ESC_REF)
+ if (escape < 0)
{
open_capitem *oc;
- recno = -c - ESC_REF;
+ recno = -escape;
HANDLE_REFERENCE: /* Come here from named backref handling */
- if (firstchar == REQ_UNSET) firstchar = REQ_NONE;
+ if (firstcharflags == REQ_UNSET) firstcharflags = REQ_NONE;
previous = code;
*code++ = ((options & PCRE_CASELESS) != 0)? OP_REFI : OP_REF;
PUT2INC(code, 0, recno);
@@ -6810,14 +6880,14 @@ for (;; ptr++)
/* So are Unicode property matches, if supported. */
#ifdef SUPPORT_UCP
- else if (-c == ESC_P || -c == ESC_p)
+ else if (escape == ESC_P || escape == ESC_p)
{
BOOL negated;
- int pdata;
- int ptype = get_ucp(&ptr, &negated, &pdata, errorcodeptr);
- if (ptype < 0) goto FAILED;
+ unsigned int ptype = 0, pdata = 0;
+ if (!get_ucp(&ptr, &negated, &ptype, &pdata, errorcodeptr))
+ goto FAILED;
previous = code;
- *code++ = ((-c == ESC_p) != negated)? OP_PROP : OP_NOTPROP;
+ *code++ = ((escape == ESC_p) != negated)? OP_PROP : OP_NOTPROP;
*code++ = ptype;
*code++ = pdata;
}
@@ -6826,7 +6896,7 @@ for (;; ptr++)
/* If Unicode properties are not supported, \X, \P, and \p are not
allowed. */
- else if (-c == ESC_X || -c == ESC_P || -c == ESC_p)
+ else if (escape == ESC_X || escape == ESC_P || escape == ESC_p)
{
*errorcodeptr = ERR45;
goto FAILED;
@@ -6836,15 +6906,18 @@ for (;; ptr++)
/* For the rest (including \X when Unicode properties are supported), we
can obtain the OP value by negating the escape value in the default
situation when PCRE_UCP is not set. When it *is* set, we substitute
- Unicode property tests. */
+ Unicode property tests. Note that \b and \B do a one-character
+ lookbehind. */
else
{
+ if ((escape == ESC_b || escape == ESC_B) && cd->max_lookbehind == 0)
+ cd->max_lookbehind = 1;
#ifdef SUPPORT_UCP
- if (-c >= ESC_DU && -c <= ESC_wu)
+ if (escape >= ESC_DU && escape <= ESC_wu)
{
nestptr = ptr + 1; /* Where to resume */
- ptr = substitutes[-c - ESC_DU] - 1; /* Just before substitute */
+ ptr = substitutes[escape - ESC_DU] - 1; /* Just before substitute */
}
else
#endif
@@ -6852,8 +6925,8 @@ for (;; ptr++)
so that it works in DFA mode and in lookbehinds. */
{
- previous = (-c > ESC_b && -c < ESC_Z)? code : NULL;
- *code++ = (!utf && c == -ESC_C)? OP_ALLANY : -c;
+ previous = (escape > ESC_b && escape < ESC_Z)? code : NULL;
+ *code++ = (!utf && escape == ESC_C)? OP_ALLANY : escape;
}
}
continue;
@@ -6863,7 +6936,7 @@ for (;; ptr++)
a value > 127. We set its representation in the length/buffer, and then
handle it as a data character. */
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
if (utf && c > MAX_VALUE_FOR_SINGLE_CHAR)
mclength = PRIV(ord2utf)(c, mcbuffer);
else
@@ -6896,6 +6969,28 @@ for (;; ptr++)
ONE_CHAR:
previous = code;
+
+ /* For caseless UTF-8 mode when UCP support is available, check whether
+ this character has more than one other case. If so, generate a special
+ OP_PROP item instead of OP_CHARI. */
+
+#ifdef SUPPORT_UCP
+ if (utf && (options & PCRE_CASELESS) != 0)
+ {
+ GETCHAR(c, mcbuffer);
+ if ((c = UCD_CASESET(c)) != 0)
+ {
+ *code++ = OP_PROP;
+ *code++ = PT_CLIST;
+ *code++ = c;
+ if (firstcharflags == REQ_UNSET) firstcharflags = zerofirstcharflags = REQ_NONE;
+ break;
+ }
+ }
+#endif
+
+ /* Caseful matches, or not one of the multicase characters. */
+
*code++ = ((options & PCRE_CASELESS) != 0)? OP_CHARI : OP_CHAR;
for (c = 0; c < mclength; c++) *code++ = mcbuffer[c];
@@ -6909,10 +7004,11 @@ for (;; ptr++)
Otherwise, leave the firstchar value alone, and don't change it on a zero
repeat. */
- if (firstchar == REQ_UNSET)
+ if (firstcharflags == REQ_UNSET)
{
- zerofirstchar = REQ_NONE;
+ zerofirstcharflags = REQ_NONE;
zeroreqchar = reqchar;
+ zeroreqcharflags = reqcharflags;
/* If the character is more than one byte long, we can set firstchar
only if it is not to be matched caselessly. */
@@ -6920,9 +7016,16 @@ for (;; ptr++)
if (mclength == 1 || req_caseopt == 0)
{
firstchar = mcbuffer[0] | req_caseopt;
- if (mclength != 1) reqchar = code[-1] | cd->req_varyopt;
+ firstchar = mcbuffer[0];
+ firstcharflags = req_caseopt;
+
+ if (mclength != 1)
+ {
+ reqchar = code[-1];
+ reqcharflags = cd->req_varyopt;
+ }
}
- else firstchar = reqchar = REQ_NONE;
+ else firstcharflags = reqcharflags = REQ_NONE;
}
/* firstchar was previously set; we can set reqchar only if the length is
@@ -6931,9 +7034,14 @@ for (;; ptr++)
else
{
zerofirstchar = firstchar;
+ zerofirstcharflags = firstcharflags;
zeroreqchar = reqchar;
+ zeroreqcharflags = reqcharflags;
if (mclength == 1 || req_caseopt == 0)
- reqchar = code[-1] | req_caseopt | cd->req_varyopt;
+ {
+ reqchar = code[-1];
+ reqcharflags = req_caseopt | cd->req_varyopt;
+ }
}
break; /* End of literal character handling */
@@ -6952,7 +7060,6 @@ return FALSE;
-
/*************************************************
* Compile sequence of alternatives *
*************************************************/
@@ -6973,8 +7080,10 @@ Arguments:
reset_bracount TRUE to reset the count for each branch
skipbytes skip this many bytes at start (for brackets and OP_COND)
cond_depth depth of nesting for conditional subpatterns
- firstcharptr place to put the first required character, or a negative number
- reqcharptr place to put the last required character, or a negative number
+ firstcharptr place to put the first required character
+ firstcharflagsptr place to put the first character flags, or a negative number
+ reqcharptr place to put the last required character
+ reqcharflagsptr place to put the last required character flags, or a negative number
bcptr pointer to the chain of currently open branches
cd points to the data block with tables pointers etc.
lengthptr NULL during the real compile phase
@@ -6986,7 +7095,9 @@ Returns: TRUE on success
static BOOL
compile_regex(int options, pcre_uchar **codeptr, const pcre_uchar **ptrptr,
int *errorcodeptr, BOOL lookbehind, BOOL reset_bracount, int skipbytes,
- int cond_depth, pcre_int32 *firstcharptr, pcre_int32 *reqcharptr,
+ int cond_depth,
+ pcre_uint32 *firstcharptr, pcre_int32 *firstcharflagsptr,
+ pcre_uint32 *reqcharptr, pcre_int32 *reqcharflagsptr,
branch_chain *bcptr, compile_data *cd, int *lengthptr)
{
const pcre_uchar *ptr = *ptrptr;
@@ -6996,17 +7107,20 @@ pcre_uchar *start_bracket = code;
pcre_uchar *reverse_count = NULL;
open_capitem capitem;
int capnumber = 0;
-pcre_int32 firstchar, reqchar;
-pcre_int32 branchfirstchar, branchreqchar;
+pcre_uint32 firstchar, reqchar;
+pcre_int32 firstcharflags, reqcharflags;
+pcre_uint32 branchfirstchar, branchreqchar;
+pcre_int32 branchfirstcharflags, branchreqcharflags;
int length;
-int orig_bracount;
-int max_bracount;
+unsigned int orig_bracount;
+unsigned int max_bracount;
branch_chain bc;
bc.outer = bcptr;
bc.current_branch = code;
-firstchar = reqchar = REQ_UNSET;
+firstchar = reqchar = 0;
+firstcharflags = reqcharflags = REQ_UNSET;
/* Accumulate the length for use in the pre-compile phase. Start with the
length of the BRA and KET and any extra bytes that are required at the
@@ -7066,8 +7180,8 @@ for (;;)
into the length. */
if (!compile_branch(&options, &code, &ptr, errorcodeptr, &branchfirstchar,
- &branchreqchar, &bc, cond_depth, cd,
- (lengthptr == NULL)? NULL : &length))
+ &branchfirstcharflags, &branchreqchar, &branchreqcharflags, &bc,
+ cond_depth, cd, (lengthptr == NULL)? NULL : &length))
{
*ptrptr = ptr;
return FALSE;
@@ -7088,7 +7202,9 @@ for (;;)
if (*last_branch != OP_ALT)
{
firstchar = branchfirstchar;
+ firstcharflags = branchfirstcharflags;
reqchar = branchreqchar;
+ reqcharflags = branchreqcharflags;
}
/* If this is not the first branch, the first char and reqchar have to
@@ -7102,23 +7218,36 @@ for (;;)
we have to abandon the firstchar for the regex, but if there was
previously no reqchar, it takes on the value of the old firstchar. */
- if (firstchar >= 0 && firstchar != branchfirstchar)
+ if (firstcharflags >= 0 &&
+ (firstcharflags != branchfirstcharflags || firstchar != branchfirstchar))
{
- if (reqchar < 0) reqchar = firstchar;
- firstchar = REQ_NONE;
+ if (reqcharflags < 0)
+ {
+ reqchar = firstchar;
+ reqcharflags = firstcharflags;
+ }
+ firstcharflags = REQ_NONE;
}
/* If we (now or from before) have no firstchar, a firstchar from the
branch becomes a reqchar if there isn't a branch reqchar. */
- if (firstchar < 0 && branchfirstchar >= 0 && branchreqchar < 0)
- branchreqchar = branchfirstchar;
+ if (firstcharflags < 0 && branchfirstcharflags >= 0 && branchreqcharflags < 0)
+ {
+ branchreqchar = branchfirstchar;
+ branchreqcharflags = branchfirstcharflags;
+ }
/* Now ensure that the reqchars match */
- if ((reqchar & ~REQ_VARY) != (branchreqchar & ~REQ_VARY))
- reqchar = REQ_NONE;
- else reqchar |= branchreqchar; /* To "or" REQ_VARY */
+ if (((reqcharflags & ~REQ_VARY) != (branchreqcharflags & ~REQ_VARY)) ||
+ reqchar != branchreqchar)
+ reqcharflags = REQ_NONE;
+ else
+ {
+ reqchar = branchreqchar;
+ reqcharflags |= branchreqcharflags; /* To "or" REQ_VARY */
+ }
}
/* If lookbehind, check that this branch matches a fixed-length string, and
@@ -7147,7 +7276,12 @@ for (;;)
*ptrptr = ptr;
return FALSE;
}
- else { PUT(reverse_count, 0, fixed_length); }
+ else
+ {
+ if (fixed_length > cd->max_lookbehind)
+ cd->max_lookbehind = fixed_length;
+ PUT(reverse_count, 0, fixed_length);
+ }
}
}
@@ -7209,7 +7343,9 @@ for (;;)
*codeptr = code;
*ptrptr = ptr;
*firstcharptr = firstchar;
+ *firstcharflagsptr = firstcharflags;
*reqcharptr = reqchar;
+ *reqcharflagsptr = reqcharflags;
if (lengthptr != NULL)
{
if (OFLOW_MAX - *lengthptr < length)
@@ -7279,19 +7415,23 @@ and the highest back reference was greater than or equal to that level.
However, by keeping a bitmap of the first 31 back references, we can catch some
of the more common cases more precisely.
+... A second exception is when the .* appears inside an atomic group, because
+this prevents the number of characters it matches from being adjusted.
+
Arguments:
code points to start of expression (the bracket)
bracket_map a bitmap of which brackets we are inside while testing; this
handles up to substring 31; after that we just have to take
the less precise approach
- backref_map the back reference bitmap
+ cd points to the compile data block
+ atomcount atomic group level
Returns: TRUE or FALSE
*/
static BOOL
is_anchored(register const pcre_uchar *code, unsigned int bracket_map,
- unsigned int backref_map)
+ compile_data *cd, int atomcount)
{
do {
const pcre_uchar *scode = first_significant_code(
@@ -7303,7 +7443,7 @@ do {
if (op == OP_BRA || op == OP_BRAPOS ||
op == OP_SBRA || op == OP_SBRAPOS)
{
- if (!is_anchored(scode, bracket_map, backref_map)) return FALSE;
+ if (!is_anchored(scode, bracket_map, cd, atomcount)) return FALSE;
}
/* Capturing brackets */
@@ -7313,30 +7453,40 @@ do {
{
int n = GET2(scode, 1+LINK_SIZE);
int new_map = bracket_map | ((n < 32)? (1 << n) : 1);
- if (!is_anchored(scode, new_map, backref_map)) return FALSE;
+ if (!is_anchored(scode, new_map, cd, atomcount)) return FALSE;
+ }
+
+ /* Positive forward assertions and conditions */
+
+ else if (op == OP_ASSERT || op == OP_COND)
+ {
+ if (!is_anchored(scode, bracket_map, cd, atomcount)) return FALSE;
}
- /* Other brackets */
+ /* Atomic groups */
- else if (op == OP_ASSERT || op == OP_ONCE || op == OP_ONCE_NC ||
- op == OP_COND)
+ else if (op == OP_ONCE || op == OP_ONCE_NC)
{
- if (!is_anchored(scode, bracket_map, backref_map)) return FALSE;
+ if (!is_anchored(scode, bracket_map, cd, atomcount + 1))
+ return FALSE;
}
/* .* is not anchored unless DOTALL is set (which generates OP_ALLANY) and
- it isn't in brackets that are or may be referenced. */
+ it isn't in brackets that are or may be referenced or inside an atomic
+ group. */
else if ((op == OP_TYPESTAR || op == OP_TYPEMINSTAR ||
op == OP_TYPEPOSSTAR))
{
- if (scode[1] != OP_ALLANY || (bracket_map & backref_map) != 0)
+ if (scode[1] != OP_ALLANY || (bracket_map & cd->backref_map) != 0 ||
+ atomcount > 0 || cd->had_pruneorskip)
return FALSE;
}
/* Check for explicit anchoring */
else if (op != OP_SOD && op != OP_SOM && op != OP_CIRC) return FALSE;
+
code += GET(code, 1);
}
while (*code == OP_ALT); /* Loop for each alternative */
@@ -7354,21 +7504,24 @@ return TRUE;
matching and for non-DOTALL patterns that start with .* (which must start at
the beginning or after \n). As in the case of is_anchored() (see above), we
have to take account of back references to capturing brackets that contain .*
-because in that case we can't make the assumption.
+because in that case we can't make the assumption. Also, the appearance of .*
+inside atomic brackets or in a pattern that contains *PRUNE or *SKIP does not
+count, because once again the assumption no longer holds.
Arguments:
code points to start of expression (the bracket)
bracket_map a bitmap of which brackets we are inside while testing; this
handles up to substring 31; after that we just have to take
the less precise approach
- backref_map the back reference bitmap
+ cd points to the compile data
+ atomcount atomic group level
Returns: TRUE or FALSE
*/
static BOOL
is_startline(const pcre_uchar *code, unsigned int bracket_map,
- unsigned int backref_map)
+ compile_data *cd, int atomcount)
{
do {
const pcre_uchar *scode = first_significant_code(
@@ -7394,7 +7547,7 @@ do {
return FALSE;
default: /* Assertion */
- if (!is_startline(scode, bracket_map, backref_map)) return FALSE;
+ if (!is_startline(scode, bracket_map, cd, atomcount)) return FALSE;
do scode += GET(scode, 1); while (*scode == OP_ALT);
scode += 1 + LINK_SIZE;
break;
@@ -7408,7 +7561,7 @@ do {
if (op == OP_BRA || op == OP_BRAPOS ||
op == OP_SBRA || op == OP_SBRAPOS)
{
- if (!is_startline(scode, bracket_map, backref_map)) return FALSE;
+ if (!is_startline(scode, bracket_map, cd, atomcount)) return FALSE;
}
/* Capturing brackets */
@@ -7418,25 +7571,40 @@ do {
{
int n = GET2(scode, 1+LINK_SIZE);
int new_map = bracket_map | ((n < 32)? (1 << n) : 1);
- if (!is_startline(scode, new_map, backref_map)) return FALSE;
+ if (!is_startline(scode, new_map, cd, atomcount)) return FALSE;
+ }
+
+ /* Positive forward assertions */
+
+ else if (op == OP_ASSERT)
+ {
+ if (!is_startline(scode, bracket_map, cd, atomcount)) return FALSE;
}
- /* Other brackets */
+ /* Atomic brackets */
- else if (op == OP_ASSERT || op == OP_ONCE || op == OP_ONCE_NC)
+ else if (op == OP_ONCE || op == OP_ONCE_NC)
{
- if (!is_startline(scode, bracket_map, backref_map)) return FALSE;
+ if (!is_startline(scode, bracket_map, cd, atomcount + 1)) return FALSE;
}
- /* .* means "start at start or after \n" if it isn't in brackets that
- may be referenced. */
+ /* .* means "start at start or after \n" if it isn't in atomic brackets or
+ brackets that may be referenced, as long as the pattern does not contain
+ *PRUNE or *SKIP, because these break the feature. Consider, for example,
+ /.*?a(*PRUNE)b/ with the subject "aab", which matches "ab", i.e. not at the
+ start of a line. */
else if (op == OP_TYPESTAR || op == OP_TYPEMINSTAR || op == OP_TYPEPOSSTAR)
{
- if (scode[1] != OP_ANY || (bracket_map & backref_map) != 0) return FALSE;
+ if (scode[1] != OP_ANY || (bracket_map & cd->backref_map) != 0 ||
+ atomcount > 0 || cd->had_pruneorskip)
+ return FALSE;
}
- /* Check for explicit circumflex */
+ /* Check for explicit circumflex; anything else gives a FALSE result. Note
+ in particular that this includes atomic brackets OP_ONCE and OP_ONCE_NC
+ because the number of characters matched by .* cannot be adjusted inside
+ them. */
else if (op != OP_CIRC && op != OP_CIRCM) return FALSE;
@@ -7464,27 +7632,33 @@ we return that char, otherwise -1.
Arguments:
code points to start of expression (the bracket)
+ flags points to the first char flags, or to REQ_NONE
inassert TRUE if in an assertion
-Returns: -1 or the fixed first char
+Returns: the fixed first char, or 0 with REQ_NONE in flags
*/
-static int
-find_firstassertedchar(const pcre_uchar *code, BOOL inassert)
+static pcre_uint32
+find_firstassertedchar(const pcre_uchar *code, pcre_int32 *flags,
+ BOOL inassert)
{
-register int c = -1;
+register pcre_uint32 c = 0;
+int cflags = REQ_NONE;
+
+*flags = REQ_NONE;
do {
- int d;
+ pcre_uint32 d;
+ int dflags;
int xl = (*code == OP_CBRA || *code == OP_SCBRA ||
*code == OP_CBRAPOS || *code == OP_SCBRAPOS)? IMM2_SIZE:0;
const pcre_uchar *scode = first_significant_code(code + 1+LINK_SIZE + xl,
TRUE);
- register int op = *scode;
+ register pcre_uchar op = *scode;
switch(op)
{
default:
- return -1;
+ return 0;
case OP_BRA:
case OP_BRAPOS:
@@ -7496,9 +7670,10 @@ do {
case OP_ONCE:
case OP_ONCE_NC:
case OP_COND:
- if ((d = find_firstassertedchar(scode, op == OP_ASSERT)) < 0)
- return -1;
- if (c < 0) c = d; else if (c != d) return -1;
+ d = find_firstassertedchar(scode, &dflags, op == OP_ASSERT);
+ if (dflags < 0)
+ return 0;
+ if (cflags < 0) { c = d; cflags = dflags; } else if (c != d || cflags != dflags) return 0;
break;
case OP_EXACT:
@@ -7509,9 +7684,9 @@ do {
case OP_PLUS:
case OP_MINPLUS:
case OP_POSPLUS:
- if (!inassert) return -1;
- if (c < 0) c = scode[1];
- else if (c != scode[1]) return -1;
+ if (!inassert) return 0;
+ if (cflags < 0) { c = scode[1]; cflags = 0; }
+ else if (c != scode[1]) return 0;
break;
case OP_EXACTI:
@@ -7522,15 +7697,17 @@ do {
case OP_PLUSI:
case OP_MINPLUSI:
case OP_POSPLUSI:
- if (!inassert) return -1;
- if (c < 0) c = scode[1] | REQ_CASELESS;
- else if (c != scode[1]) return -1;
+ if (!inassert) return 0;
+ if (cflags < 0) { c = scode[1]; cflags = REQ_CASELESS; }
+ else if (c != scode[1]) return 0;
break;
}
code += GET(code, 1);
}
while (*code == OP_ALT);
+
+*flags = cflags;
return c;
}
@@ -7558,37 +7735,48 @@ Returns: pointer to compiled data block, or NULL on error,
with errorptr and erroroffset set
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN pcre * PCRE_CALL_CONVENTION
pcre_compile(const char *pattern, int options, const char **errorptr,
int *erroroffset, const unsigned char *tables)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN pcre16 * PCRE_CALL_CONVENTION
pcre16_compile(PCRE_SPTR16 pattern, int options, const char **errorptr,
int *erroroffset, const unsigned char *tables)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN pcre32 * PCRE_CALL_CONVENTION
+pcre32_compile(PCRE_SPTR32 pattern, int options, const char **errorptr,
+ int *erroroffset, const unsigned char *tables)
#endif
{
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
return pcre_compile2(pattern, options, NULL, errorptr, erroroffset, tables);
-#else
+#elif defined COMPILE_PCRE16
return pcre16_compile2(pattern, options, NULL, errorptr, erroroffset, tables);
+#elif defined COMPILE_PCRE32
+return pcre32_compile2(pattern, options, NULL, errorptr, erroroffset, tables);
#endif
}
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN pcre * PCRE_CALL_CONVENTION
pcre_compile2(const char *pattern, int options, int *errorcodeptr,
const char **errorptr, int *erroroffset, const unsigned char *tables)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN pcre16 * PCRE_CALL_CONVENTION
pcre16_compile2(PCRE_SPTR16 pattern, int options, int *errorcodeptr,
const char **errorptr, int *erroroffset, const unsigned char *tables)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN pcre32 * PCRE_CALL_CONVENTION
+pcre32_compile2(PCRE_SPTR32 pattern, int options, int *errorcodeptr,
+ const char **errorptr, int *erroroffset, const unsigned char *tables)
#endif
{
REAL_PCRE *re;
int length = 1; /* For final END opcode */
-pcre_int32 firstchar, reqchar;
+pcre_uint32 firstchar, reqchar;
+pcre_int32 firstcharflags, reqcharflags;
int newline;
int errorcode = 0;
int skipatstart = 0;
@@ -7661,14 +7849,25 @@ while (ptr[skipatstart] == CHAR_LEFT_PARENTHESIS &&
int newnl = 0;
int newbsr = 0;
+/* For completeness and backward compatibility, (*UTFn) is supported in the
+relevant libraries, but (*UTF) is generic and always supported. Note that
+PCRE_UTF8 == PCRE_UTF16 == PCRE_UTF32. */
+
#ifdef COMPILE_PCRE8
- if (STRNCMP_UC_C8(ptr+skipatstart+2, STRING_UTF_RIGHTPAR, 5) == 0)
+ if (STRNCMP_UC_C8(ptr+skipatstart+2, STRING_UTF8_RIGHTPAR, 5) == 0)
{ skipatstart += 7; options |= PCRE_UTF8; continue; }
#endif
#ifdef COMPILE_PCRE16
- if (STRNCMP_UC_C8(ptr+skipatstart+2, STRING_UTF_RIGHTPAR, 6) == 0)
+ if (STRNCMP_UC_C8(ptr+skipatstart+2, STRING_UTF16_RIGHTPAR, 6) == 0)
{ skipatstart += 8; options |= PCRE_UTF16; continue; }
#endif
+#ifdef COMPILE_PCRE32
+ if (STRNCMP_UC_C8(ptr+skipatstart+2, STRING_UTF32_RIGHTPAR, 6) == 0)
+ { skipatstart += 8; options |= PCRE_UTF32; continue; }
+#endif
+
+ else if (STRNCMP_UC_C8(ptr+skipatstart+2, STRING_UTF_RIGHTPAR, 4) == 0)
+ { skipatstart += 6; options |= PCRE_UTF8; continue; }
else if (STRNCMP_UC_C8(ptr+skipatstart+2, STRING_UCP_RIGHTPAR, 4) == 0)
{ skipatstart += 6; options |= PCRE_UCP; continue; }
else if (STRNCMP_UC_C8(ptr+skipatstart+2, STRING_NO_START_OPT_RIGHTPAR, 13) == 0)
@@ -7697,7 +7896,7 @@ while (ptr[skipatstart] == CHAR_LEFT_PARENTHESIS &&
else break;
}
-/* PCRE_UTF16 has the same value as PCRE_UTF8. */
+/* PCRE_UTF(16|32) have the same value as PCRE_UTF8. */
utf = (options & PCRE_UTF8) != 0;
/* Can't support UTF unless PCRE has been compiled to include the code. The
@@ -7709,10 +7908,12 @@ not used here. */
if (utf && (options & PCRE_NO_UTF8_CHECK) == 0 &&
(errorcode = PRIV(valid_utf)((PCRE_PUCHAR)pattern, -1, erroroffset)) != 0)
{
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
errorcode = ERR44;
-#else
+#elif defined COMPILE_PCRE16
errorcode = ERR74;
+#elif defined COMPILE_PCRE32
+ errorcode = ERR77;
#endif
goto PCRE_EARLY_ERROR_RETURN2;
}
@@ -7817,6 +8018,7 @@ cd->start_pattern = (const pcre_uchar *)pattern;
cd->end_pattern = (const pcre_uchar *)(pattern + STRLEN_UC((const pcre_uchar *)pattern));
cd->req_varyopt = 0;
cd->assert_depth = 0;
+cd->max_lookbehind = 0;
cd->external_options = options;
cd->external_flags = 0;
cd->open_caps = NULL;
@@ -7831,7 +8033,8 @@ ptr += skipatstart;
code = cworkspace;
*code = OP_BRA;
(void)compile_regex(cd->external_options, &code, &ptr, &errorcode, FALSE,
- FALSE, 0, 0, &firstchar, &reqchar, NULL, cd, &length);
+ FALSE, 0, 0, &firstchar, &firstcharflags, &reqchar, &reqcharflags, NULL,
+ cd, &length);
if (errorcode != 0) goto PCRE_EARLY_ERROR_RETURN;
DPRINTF(("end pre-compile: length=%d workspace=%d\n", length,
@@ -7867,7 +8070,6 @@ re->magic_number = MAGIC_NUMBER;
re->size = (int)size;
re->options = cd->external_options;
re->flags = cd->external_flags;
-re->dummy1 = 0;
re->first_char = 0;
re->req_char = 0;
re->name_table_offset = sizeof(REAL_PCRE) / sizeof(pcre_uchar);
@@ -7876,6 +8078,9 @@ re->name_count = cd->names_found;
re->ref_count = 0;
re->tables = (tables == PRIV(default_tables))? NULL : tables;
re->nullpad = NULL;
+#ifdef COMPILE_PCRE32
+re->dummy1 = re->dummy2 = 0;
+#endif
/* The starting points of the name/number translation table and of the code are
passed around in the compile data block. The start/end pattern and initial
@@ -7887,6 +8092,7 @@ field; this time it's used for remembering forward references to subpatterns.
cd->final_bracount = cd->bracount; /* Save for checking forward references */
cd->assert_depth = 0;
cd->bracount = 0;
+cd->max_lookbehind = 0;
cd->names_found = 0;
cd->name_table = (pcre_uchar *)re + re->name_table_offset;
codestart = cd->name_table + re->name_entry_size * re->name_count;
@@ -7894,6 +8100,7 @@ cd->start_code = codestart;
cd->hwm = (pcre_uchar *)(cd->start_workspace);
cd->req_varyopt = 0;
cd->had_accept = FALSE;
+cd->had_pruneorskip = FALSE;
cd->check_lookbehind = FALSE;
cd->open_caps = NULL;
@@ -7905,16 +8112,21 @@ ptr = (const pcre_uchar *)pattern + skipatstart;
code = (pcre_uchar *)codestart;
*code = OP_BRA;
(void)compile_regex(re->options, &code, &ptr, &errorcode, FALSE, FALSE, 0, 0,
- &firstchar, &reqchar, NULL, cd, NULL);
+ &firstchar, &firstcharflags, &reqchar, &reqcharflags, NULL, cd, NULL);
re->top_bracket = cd->bracount;
re->top_backref = cd->top_backref;
+re->max_lookbehind = cd->max_lookbehind;
re->flags = cd->external_flags | PCRE_MODE;
-if (cd->had_accept) reqchar = REQ_NONE; /* Must disable after (*ACCEPT) */
+if (cd->had_accept)
+ {
+ reqchar = 0; /* Must disable after (*ACCEPT) */
+ reqcharflags = REQ_NONE;
+ }
/* If not reached end of pattern on success, there's an excess bracket. */
-if (errorcode == 0 && *ptr != 0) errorcode = ERR22;
+if (errorcode == 0 && *ptr != CHAR_NULL) errorcode = ERR22;
/* Fill in the terminating state and check for disastrous overflow, but
if debugging, leave the test till after things are printed out. */
@@ -7925,6 +8137,13 @@ if debugging, leave the test till after things are printed out. */
if (code - codestart > length) errorcode = ERR23;
#endif
+#ifdef SUPPORT_VALGRIND
+/* If the estimated length exceeds the really used length, mark the extra
+allocated memory as unadressable, so that any out-of-bound reads can be
+detected. */
+VALGRIND_MAKE_MEM_NOACCESS(code, (length - (code - codestart)) * sizeof(pcre_uchar));
+#endif
+
/* Fill in any forward references that are required. There may be repeated
references; optimize for them, as searching a large regex takes time. */
@@ -7960,7 +8179,7 @@ if (errorcode == 0 && re->top_backref > re->top_bracket) errorcode = ERR15;
/* If there were any lookbehind assertions that contained OP_RECURSE
(recursions or subroutine calls), a flag is set for them to be checked here,
-because they may contain forward references. Actual recursions can't be fixed
+because they may contain forward references. Actual recursions cannot be fixed
length, but subroutine calls can. It is done like this so that those without
OP_RECURSE that are not fixed length get a diagnosic with a useful offset. The
exceptional ones forgo this. We scan the pattern to check that they are fixed
@@ -7995,6 +8214,7 @@ if (cd->check_lookbehind)
(fixed_length == -4)? ERR70 : ERR25;
break;
}
+ if (fixed_length > cd->max_lookbehind) cd->max_lookbehind = fixed_length;
PUT(cc, 1, fixed_length);
}
cc += 1 + LINK_SIZE;
@@ -8015,33 +8235,33 @@ if (errorcode != 0)
}
/* If the anchored option was not passed, set the flag if we can determine that
-the pattern is anchored by virtue of ^ characters or \A or anything else (such
-as starting with .* when DOTALL is set).
+the pattern is anchored by virtue of ^ characters or \A or anything else, such
+as starting with non-atomic .* when DOTALL is set and there are no occurrences
+of *PRUNE or *SKIP.
Otherwise, if we know what the first byte has to be, save it, because that
speeds up unanchored matches no end. If not, see if we can set the
PCRE_STARTLINE flag. This is helpful for multiline matches when all branches
-start with ^. and also when all branches start with .* for non-DOTALL matches.
-*/
+start with ^. and also when all branches start with non-atomic .* for
+non-DOTALL matches when *PRUNE and SKIP are not present. */
if ((re->options & PCRE_ANCHORED) == 0)
{
- if (is_anchored(codestart, 0, cd->backref_map))
- re->options |= PCRE_ANCHORED;
+ if (is_anchored(codestart, 0, cd, 0)) re->options |= PCRE_ANCHORED;
else
{
- if (firstchar < 0)
- firstchar = find_firstassertedchar(codestart, FALSE);
- if (firstchar >= 0) /* Remove caseless flag for non-caseable chars */
+ if (firstcharflags < 0)
+ firstchar = find_firstassertedchar(codestart, &firstcharflags, FALSE);
+ if (firstcharflags >= 0) /* Remove caseless flag for non-caseable chars */
{
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
re->first_char = firstchar & 0xff;
-#else
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
re->first_char = firstchar & 0xffff;
+#elif defined COMPILE_PCRE32
+ re->first_char = firstchar;
#endif
-#endif
- if ((firstchar & REQ_CASELESS) != 0)
+ if ((firstcharflags & REQ_CASELESS) != 0)
{
#if defined SUPPORT_UCP && !(defined COMPILE_PCRE8)
/* We ignore non-ASCII first chars in 8 bit mode. */
@@ -8064,8 +8284,8 @@ if ((re->options & PCRE_ANCHORED) == 0)
re->flags |= PCRE_FIRSTSET;
}
- else if (is_startline(codestart, 0, cd->backref_map))
- re->flags |= PCRE_STARTLINE;
+
+ else if (is_startline(codestart, 0, cd, 0)) re->flags |= PCRE_STARTLINE;
}
}
@@ -8073,17 +8293,17 @@ if ((re->options & PCRE_ANCHORED) == 0)
variable length item in the regex. Remove the caseless flag for non-caseable
bytes. */
-if (reqchar >= 0 &&
- ((re->options & PCRE_ANCHORED) == 0 || (reqchar & REQ_VARY) != 0))
+if (reqcharflags >= 0 &&
+ ((re->options & PCRE_ANCHORED) == 0 || (reqcharflags & REQ_VARY) != 0))
{
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
re->req_char = reqchar & 0xff;
-#else
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
re->req_char = reqchar & 0xffff;
+#elif defined COMPILE_PCRE32
+ re->req_char = reqchar;
#endif
-#endif
- if ((reqchar & REQ_CASELESS) != 0)
+ if ((reqcharflags & REQ_CASELESS) != 0)
{
#if defined SUPPORT_UCP && !(defined COMPILE_PCRE8)
/* We ignore non-ASCII first chars in 8 bit mode. */
@@ -8133,10 +8353,12 @@ if ((re->flags & PCRE_REQCHSET) != 0)
else printf("Req char = \\x%02x%s\n", ch, caseless);
}
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
pcre_printint((pcre *)re, stdout, TRUE);
-#else
+#elif defined COMPILE_PCRE16
pcre16_printint((pcre *)re, stdout, TRUE);
+#elif defined COMPILE_PCRE32
+pcre32_printint((pcre *)re, stdout, TRUE);
#endif
/* This check is done here in the debugging case so that the code that
@@ -8152,10 +8374,12 @@ if (code - codestart > length)
}
#endif /* PCRE_DEBUG */
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
return (pcre *)re;
-#else
+#elif defined COMPILE_PCRE16
return (pcre16 *)re;
+#elif defined COMPILE_PCRE32
+return (pcre32 *)re;
#endif
}
diff --git a/src/3rdparty/pcre/pcre_config.c b/src/3rdparty/pcre/pcre_config.c
index 6ebafaf06a..db46c77a74 100644
--- a/src/3rdparty/pcre/pcre_config.c
+++ b/src/3rdparty/pcre/pcre_config.c
@@ -65,18 +65,21 @@ Arguments:
Returns: 0 if data returned, negative on error
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre_config(int what, void *where)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre16_config(int what, void *where)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_config(int what, void *where)
#endif
{
switch (what)
{
case PCRE_CONFIG_UTF8:
-#if defined COMPILE_PCRE16
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
*((int *)where) = 0;
return PCRE_ERROR_BADOPTION;
#else
@@ -89,7 +92,20 @@ switch (what)
#endif
case PCRE_CONFIG_UTF16:
-#if defined COMPILE_PCRE8
+#if defined COMPILE_PCRE8 || defined COMPILE_PCRE32
+ *((int *)where) = 0;
+ return PCRE_ERROR_BADOPTION;
+#else
+#if defined SUPPORT_UTF
+ *((int *)where) = 1;
+#else
+ *((int *)where) = 0;
+#endif
+ break;
+#endif
+
+ case PCRE_CONFIG_UTF32:
+#if defined COMPILE_PCRE8 || defined COMPILE_PCRE16
*((int *)where) = 0;
return PCRE_ERROR_BADOPTION;
#else
diff --git a/src/3rdparty/pcre/pcre_dfa_exec.c b/src/3rdparty/pcre/pcre_dfa_exec.c
index bc89c0de41..adb1bbf3f5 100644
--- a/src/3rdparty/pcre/pcre_dfa_exec.c
+++ b/src/3rdparty/pcre/pcre_dfa_exec.c
@@ -38,10 +38,9 @@ POSSIBILITY OF SUCH DAMAGE.
-----------------------------------------------------------------------------
*/
-
/* This module contains the external function pcre_dfa_exec(), which is an
alternative matching function that uses a sort of DFA algorithm (not a true
-FSM). This is NOT Perl- compatible, but it has advantages in certain
+FSM). This is NOT Perl-compatible, but it has advantages in certain
applications. */
@@ -282,7 +281,7 @@ typedef struct stateblock {
int data; /* Some use extra data */
} stateblock;
-#define INTS_PER_STATEBLOCK (sizeof(stateblock)/sizeof(int))
+#define INTS_PER_STATEBLOCK (int)(sizeof(stateblock)/sizeof(int))
#ifdef PCRE_DEBUG
@@ -303,13 +302,13 @@ Returns: nothing
static void
pchars(const pcre_uchar *p, int length, FILE *f)
{
-int c;
+pcre_uint32 c;
while (length-- > 0)
{
if (isprint(c = *(p++)))
fprintf(f, "%c", c);
else
- fprintf(f, "\\x%02x", c);
+ fprintf(f, "\\x{%02x}", c);
}
}
#endif
@@ -382,7 +381,8 @@ for the current character, one for the following character). */
next_new_state->count = (y); \
next_new_state->data = (z); \
next_new_state++; \
- DPRINTF(("%.*sADD_NEW_DATA(%d,%d,%d)\n", rlevel*2-2, SP, (x), (y), (z))); \
+ DPRINTF(("%.*sADD_NEW_DATA(%d,%d,%d) line %d\n", rlevel*2-2, SP, \
+ (x), (y), (z), __LINE__)); \
} \
else return PCRE_ERROR_DFA_WSSIZE
@@ -424,6 +424,8 @@ BOOL utf = (md->poptions & PCRE_UTF8) != 0;
BOOL utf = FALSE;
#endif
+BOOL reset_could_continue = FALSE;
+
rlevel++;
offsetcount &= (-2);
@@ -569,9 +571,11 @@ for (;;)
{
int i, j;
int clen, dlen;
- unsigned int c, d;
+ pcre_uint32 c, d;
int forced_fail = 0;
- BOOL could_continue = FALSE;
+ BOOL partial_newline = FALSE;
+ BOOL could_continue = reset_could_continue;
+ reset_could_continue = FALSE;
/* Make the new state list into the active state list and empty the
new state list. */
@@ -607,11 +611,12 @@ for (;;)
if (ptr < end_subject)
{
- clen = 1; /* Number of bytes in the character */
+ clen = 1; /* Number of data items in the character */
#ifdef SUPPORT_UTF
- if (utf) { GETCHARLEN(c, ptr, clen); } else
-#endif /* SUPPORT_UTF */
+ GETCHARLENTEST(c, ptr, clen);
+#else
c = *ptr;
+#endif /* SUPPORT_UTF */
}
else
{
@@ -630,7 +635,8 @@ for (;;)
BOOL caseless = FALSE;
const pcre_uchar *code;
int state_offset = current_state->offset;
- int count, codevalue, rrc;
+ int codevalue, rrc;
+ unsigned int count;
#ifdef PCRE_DEBUG
printf ("%.*sProcessing state %d c=", rlevel*2-2, SP, state_offset);
@@ -641,7 +647,8 @@ for (;;)
/* A negative offset is a special case meaning "hold off going to this
(negated) state until the number of characters in the data field have
- been skipped". */
+ been skipped". If the could_continue flag was passed over from a previous
+ state, arrange for it to passed on. */
if (state_offset < 0)
{
@@ -650,6 +657,7 @@ for (;;)
DPRINTF(("%.*sSkipping this character\n", rlevel*2-2, SP));
ADD_NEW_DATA(state_offset, current_state->count,
current_state->data - 1);
+ if (could_continue) reset_could_continue = TRUE;
continue;
}
else
@@ -689,10 +697,10 @@ for (;;)
permitted.
We also use this mechanism for opcodes such as OP_TYPEPLUS that take an
- argument that is not a data character - but is always one byte long. We
- have to take special action to deal with \P, \p, \H, \h, \V, \v and \X in
- this case. To keep the other cases fast, convert these ones to new opcodes.
- */
+ argument that is not a data character - but is always one byte long because
+ the values are small. We have to take special action to deal with \P, \p,
+ \H, \h, \V, \v and \X in this case. To keep the other cases fast, convert
+ these ones to new opcodes. */
if (coptable[codevalue] > 0)
{
@@ -783,7 +791,7 @@ for (;;)
offsets[0] = (int)(current_subject - start_subject);
offsets[1] = (int)(ptr - start_subject);
DPRINTF(("%.*sSet matched string = \"%.*s\"\n", rlevel*2-2, SP,
- offsets[1] - offsets[0], current_subject));
+ offsets[1] - offsets[0], (char *)current_subject));
}
if ((md->moptions & PCRE_DFA_SHORTEST) != 0)
{
@@ -888,7 +896,20 @@ for (;;)
/*-----------------------------------------------------------------*/
case OP_ANY:
if (clen > 0 && !IS_NEWLINE(ptr))
- { ADD_NEW(state_offset + 1, 0); }
+ {
+ if (ptr + 1 >= md->end_subject &&
+ (md->moptions & (PCRE_PARTIAL_HARD)) != 0 &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ c == NLBLOCK->nl[0])
+ {
+ could_continue = partial_newline = TRUE;
+ }
+ else
+ {
+ ADD_NEW(state_offset + 1, 0);
+ }
+ }
break;
/*-----------------------------------------------------------------*/
@@ -916,6 +937,19 @@ for (;;)
(ptr == end_subject - md->nllen)
))
{ ADD_ACTIVE(state_offset + 1, 0); }
+ else if (ptr + 1 >= md->end_subject &&
+ (md->moptions & (PCRE_PARTIAL_HARD|PCRE_PARTIAL_SOFT)) != 0 &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ c == NLBLOCK->nl[0])
+ {
+ if ((md->moptions & PCRE_PARTIAL_HARD) != 0)
+ {
+ reset_could_continue = TRUE;
+ ADD_NEW_DATA(-(state_offset + 1), 0, 1);
+ }
+ else could_continue = partial_newline = TRUE;
+ }
}
break;
@@ -928,6 +962,19 @@ for (;;)
else if (clen == 0 ||
((md->poptions & PCRE_DOLLAR_ENDONLY) == 0 && IS_NEWLINE(ptr)))
{ ADD_ACTIVE(state_offset + 1, 0); }
+ else if (ptr + 1 >= md->end_subject &&
+ (md->moptions & (PCRE_PARTIAL_HARD|PCRE_PARTIAL_SOFT)) != 0 &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ c == NLBLOCK->nl[0])
+ {
+ if ((md->moptions & PCRE_PARTIAL_HARD) != 0)
+ {
+ reset_could_continue = TRUE;
+ ADD_NEW_DATA(-(state_offset + 1), 0, 1);
+ }
+ else could_continue = partial_newline = TRUE;
+ }
}
else if (IS_NEWLINE(ptr))
{ ADD_ACTIVE(state_offset + 1, 0); }
@@ -962,7 +1009,7 @@ for (;;)
{
const pcre_uchar *temp = ptr - 1;
if (temp < md->start_used_ptr) md->start_used_ptr = temp;
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
if (utf) { BACKCHAR(temp); }
#endif
GETCHARTEST(d, temp);
@@ -1015,6 +1062,7 @@ for (;;)
if (clen > 0)
{
BOOL OK;
+ const pcre_uint32 *cp;
const ucd_record * prop = GET_UCD(c);
switch(code[1])
{
@@ -1063,6 +1111,15 @@ for (;;)
c == CHAR_UNDERSCORE;
break;
+ case PT_CLIST:
+ cp = PRIV(ucd_caseless_sets) + code[2];
+ for (;;)
+ {
+ if (c < *cp) { OK = FALSE; break; }
+ if (c == *cp++) { OK = TRUE; break; }
+ }
+ break;
+
/* Should never occur, but keep compilers from grumbling. */
default:
@@ -1090,7 +1147,15 @@ for (;;)
if (count > 0) { ADD_ACTIVE(state_offset + 2, 0); }
if (clen > 0)
{
- if ((c >= 256 && d != OP_DIGIT && d != OP_WHITESPACE && d != OP_WORDCHAR) ||
+ if (d == OP_ANY && ptr + 1 >= md->end_subject &&
+ (md->moptions & (PCRE_PARTIAL_HARD)) != 0 &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ c == NLBLOCK->nl[0])
+ {
+ could_continue = partial_newline = TRUE;
+ }
+ else if ((c >= 256 && d != OP_DIGIT && d != OP_WHITESPACE && d != OP_WORDCHAR) ||
(c < 256 &&
(d != OP_ANY || !IS_NEWLINE(ptr)) &&
((ctypes[c] & toptable1[d]) ^ toptable2[d]) != 0))
@@ -1113,7 +1178,15 @@ for (;;)
ADD_ACTIVE(state_offset + 2, 0);
if (clen > 0)
{
- if ((c >= 256 && d != OP_DIGIT && d != OP_WHITESPACE && d != OP_WORDCHAR) ||
+ if (d == OP_ANY && ptr + 1 >= md->end_subject &&
+ (md->moptions & (PCRE_PARTIAL_HARD)) != 0 &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ c == NLBLOCK->nl[0])
+ {
+ could_continue = partial_newline = TRUE;
+ }
+ else if ((c >= 256 && d != OP_DIGIT && d != OP_WHITESPACE && d != OP_WORDCHAR) ||
(c < 256 &&
(d != OP_ANY || !IS_NEWLINE(ptr)) &&
((ctypes[c] & toptable1[d]) ^ toptable2[d]) != 0))
@@ -1135,7 +1208,15 @@ for (;;)
ADD_ACTIVE(state_offset + 2, 0);
if (clen > 0)
{
- if ((c >= 256 && d != OP_DIGIT && d != OP_WHITESPACE && d != OP_WORDCHAR) ||
+ if (d == OP_ANY && ptr + 1 >= md->end_subject &&
+ (md->moptions & (PCRE_PARTIAL_HARD)) != 0 &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ c == NLBLOCK->nl[0])
+ {
+ could_continue = partial_newline = TRUE;
+ }
+ else if ((c >= 256 && d != OP_DIGIT && d != OP_WHITESPACE && d != OP_WORDCHAR) ||
(c < 256 &&
(d != OP_ANY || !IS_NEWLINE(ptr)) &&
((ctypes[c] & toptable1[d]) ^ toptable2[d]) != 0))
@@ -1155,7 +1236,15 @@ for (;;)
count = current_state->count; /* Number already matched */
if (clen > 0)
{
- if ((c >= 256 && d != OP_DIGIT && d != OP_WHITESPACE && d != OP_WORDCHAR) ||
+ if (d == OP_ANY && ptr + 1 >= md->end_subject &&
+ (md->moptions & (PCRE_PARTIAL_HARD)) != 0 &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ c == NLBLOCK->nl[0])
+ {
+ could_continue = partial_newline = TRUE;
+ }
+ else if ((c >= 256 && d != OP_DIGIT && d != OP_WHITESPACE && d != OP_WORDCHAR) ||
(c < 256 &&
(d != OP_ANY || !IS_NEWLINE(ptr)) &&
((ctypes[c] & toptable1[d]) ^ toptable2[d]) != 0))
@@ -1176,7 +1265,15 @@ for (;;)
count = current_state->count; /* Number already matched */
if (clen > 0)
{
- if ((c >= 256 && d != OP_DIGIT && d != OP_WHITESPACE && d != OP_WORDCHAR) ||
+ if (d == OP_ANY && ptr + 1 >= md->end_subject &&
+ (md->moptions & (PCRE_PARTIAL_HARD)) != 0 &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ c == NLBLOCK->nl[0])
+ {
+ could_continue = partial_newline = TRUE;
+ }
+ else if ((c >= 256 && d != OP_DIGIT && d != OP_WHITESPACE && d != OP_WORDCHAR) ||
(c < 256 &&
(d != OP_ANY || !IS_NEWLINE(ptr)) &&
((ctypes[c] & toptable1[d]) ^ toptable2[d]) != 0))
@@ -1209,6 +1306,7 @@ for (;;)
if (clen > 0)
{
BOOL OK;
+ const pcre_uint32 *cp;
const ucd_record * prop = GET_UCD(c);
switch(code[2])
{
@@ -1257,6 +1355,15 @@ for (;;)
c == CHAR_UNDERSCORE;
break;
+ case PT_CLIST:
+ cp = PRIV(ucd_caseless_sets) + code[3];
+ for (;;)
+ {
+ if (c < *cp) { OK = FALSE; break; }
+ if (c == *cp++) { OK = TRUE; break; }
+ }
+ break;
+
/* Should never occur, but keep compilers from grumbling. */
default:
@@ -1283,8 +1390,9 @@ for (;;)
case OP_EXTUNI_EXTRA + OP_TYPEPOSPLUS:
count = current_state->count; /* Already matched */
if (count > 0) { ADD_ACTIVE(state_offset + 2, 0); }
- if (clen > 0 && UCD_CATEGORY(c) != ucp_M)
+ if (clen > 0)
{
+ int lgb, rgb;
const pcre_uchar *nptr = ptr + clen;
int ncount = 0;
if (count > 0 && codevalue == OP_EXTUNI_EXTRA + OP_TYPEPOSPLUS)
@@ -1292,14 +1400,16 @@ for (;;)
active_count--; /* Remove non-match possibility */
next_active_state--;
}
+ lgb = UCD_GRAPHBREAK(c);
while (nptr < end_subject)
{
- int nd;
- int ndlen = 1;
- GETCHARLEN(nd, nptr, ndlen);
- if (UCD_CATEGORY(nd) != ucp_M) break;
+ dlen = 1;
+ if (!utf) d = *nptr; else { GETCHARLEN(d, nptr, dlen); }
+ rgb = UCD_GRAPHBREAK(d);
+ if ((PRIV(ucp_gbtable)[lgb] & (1 << rgb)) == 0) break;
ncount++;
- nptr += ndlen;
+ lgb = rgb;
+ nptr += dlen;
}
count++;
ADD_NEW_DATA(-state_offset, count, ncount);
@@ -1318,20 +1428,22 @@ for (;;)
int ncount = 0;
switch (c)
{
- case 0x000b:
- case 0x000c:
- case 0x0085:
+ case CHAR_VT:
+ case CHAR_FF:
+ case CHAR_NEL:
+#ifndef EBCDIC
case 0x2028:
case 0x2029:
+#endif /* Not EBCDIC */
if ((md->moptions & PCRE_BSR_ANYCRLF) != 0) break;
goto ANYNL01;
- case 0x000d:
- if (ptr + 1 < end_subject && ptr[1] == 0x0a) ncount = 1;
+ case CHAR_CR:
+ if (ptr + 1 < end_subject && RAWUCHARTEST(ptr + 1) == CHAR_LF) ncount = 1;
/* Fall through */
ANYNL01:
- case 0x000a:
+ case CHAR_LF:
if (count > 0 && codevalue == OP_ANYNL_EXTRA + OP_TYPEPOSPLUS)
{
active_count--; /* Remove non-match possibility */
@@ -1358,13 +1470,7 @@ for (;;)
BOOL OK;
switch (c)
{
- case 0x000a:
- case 0x000b:
- case 0x000c:
- case 0x000d:
- case 0x0085:
- case 0x2028:
- case 0x2029:
+ VSPACE_CASES:
OK = TRUE;
break;
@@ -1397,25 +1503,7 @@ for (;;)
BOOL OK;
switch (c)
{
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
+ HSPACE_CASES:
OK = TRUE;
break;
@@ -1456,6 +1544,7 @@ for (;;)
if (clen > 0)
{
BOOL OK;
+ const pcre_uint32 *cp;
const ucd_record * prop = GET_UCD(c);
switch(code[2])
{
@@ -1504,6 +1593,15 @@ for (;;)
c == CHAR_UNDERSCORE;
break;
+ case PT_CLIST:
+ cp = PRIV(ucd_caseless_sets) + code[3];
+ for (;;)
+ {
+ if (c < *cp) { OK = FALSE; break; }
+ if (c == *cp++) { OK = TRUE; break; }
+ }
+ break;
+
/* Should never occur, but keep compilers from grumbling. */
default:
@@ -1539,8 +1637,9 @@ for (;;)
QS2:
ADD_ACTIVE(state_offset + 2, 0);
- if (clen > 0 && UCD_CATEGORY(c) != ucp_M)
+ if (clen > 0)
{
+ int lgb, rgb;
const pcre_uchar *nptr = ptr + clen;
int ncount = 0;
if (codevalue == OP_EXTUNI_EXTRA + OP_TYPEPOSSTAR ||
@@ -1549,14 +1648,16 @@ for (;;)
active_count--; /* Remove non-match possibility */
next_active_state--;
}
+ lgb = UCD_GRAPHBREAK(c);
while (nptr < end_subject)
{
- int nd;
- int ndlen = 1;
- GETCHARLEN(nd, nptr, ndlen);
- if (UCD_CATEGORY(nd) != ucp_M) break;
+ dlen = 1;
+ if (!utf) d = *nptr; else { GETCHARLEN(d, nptr, dlen); }
+ rgb = UCD_GRAPHBREAK(d);
+ if ((PRIV(ucp_gbtable)[lgb] & (1 << rgb)) == 0) break;
ncount++;
- nptr += ndlen;
+ lgb = rgb;
+ nptr += dlen;
}
ADD_NEW_DATA(-(state_offset + count), 0, ncount);
}
@@ -1582,20 +1683,22 @@ for (;;)
int ncount = 0;
switch (c)
{
- case 0x000b:
- case 0x000c:
- case 0x0085:
+ case CHAR_VT:
+ case CHAR_FF:
+ case CHAR_NEL:
+#ifndef EBCDIC
case 0x2028:
case 0x2029:
+#endif /* Not EBCDIC */
if ((md->moptions & PCRE_BSR_ANYCRLF) != 0) break;
goto ANYNL02;
- case 0x000d:
- if (ptr + 1 < end_subject && ptr[1] == 0x0a) ncount = 1;
+ case CHAR_CR:
+ if (ptr + 1 < end_subject && RAWUCHARTEST(ptr + 1) == CHAR_LF) ncount = 1;
/* Fall through */
ANYNL02:
- case 0x000a:
+ case CHAR_LF:
if (codevalue == OP_ANYNL_EXTRA + OP_TYPEPOSSTAR ||
codevalue == OP_ANYNL_EXTRA + OP_TYPEPOSQUERY)
{
@@ -1630,13 +1733,7 @@ for (;;)
BOOL OK;
switch (c)
{
- case 0x000a:
- case 0x000b:
- case 0x000c:
- case 0x000d:
- case 0x0085:
- case 0x2028:
- case 0x2029:
+ VSPACE_CASES:
OK = TRUE;
break;
@@ -1676,25 +1773,7 @@ for (;;)
BOOL OK;
switch (c)
{
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
+ HSPACE_CASES:
OK = TRUE;
break;
@@ -1728,6 +1807,7 @@ for (;;)
if (clen > 0)
{
BOOL OK;
+ const pcre_uint32 *cp;
const ucd_record * prop = GET_UCD(c);
switch(code[1 + IMM2_SIZE + 1])
{
@@ -1776,6 +1856,15 @@ for (;;)
c == CHAR_UNDERSCORE;
break;
+ case PT_CLIST:
+ cp = PRIV(ucd_caseless_sets) + code[1 + IMM2_SIZE + 2];
+ for (;;)
+ {
+ if (c < *cp) { OK = FALSE; break; }
+ if (c == *cp++) { OK = TRUE; break; }
+ }
+ break;
+
/* Should never occur, but keep compilers from grumbling. */
default:
@@ -1806,8 +1895,9 @@ for (;;)
if (codevalue != OP_EXTUNI_EXTRA + OP_TYPEEXACT)
{ ADD_ACTIVE(state_offset + 2 + IMM2_SIZE, 0); }
count = current_state->count; /* Number already matched */
- if (clen > 0 && UCD_CATEGORY(c) != ucp_M)
+ if (clen > 0)
{
+ int lgb, rgb;
const pcre_uchar *nptr = ptr + clen;
int ncount = 0;
if (codevalue == OP_EXTUNI_EXTRA + OP_TYPEPOSUPTO)
@@ -1815,15 +1905,19 @@ for (;;)
active_count--; /* Remove non-match possibility */
next_active_state--;
}
+ lgb = UCD_GRAPHBREAK(c);
while (nptr < end_subject)
{
- int nd;
- int ndlen = 1;
- GETCHARLEN(nd, nptr, ndlen);
- if (UCD_CATEGORY(nd) != ucp_M) break;
+ dlen = 1;
+ if (!utf) d = *nptr; else { GETCHARLEN(d, nptr, dlen); }
+ rgb = UCD_GRAPHBREAK(d);
+ if ((PRIV(ucp_gbtable)[lgb] & (1 << rgb)) == 0) break;
ncount++;
- nptr += ndlen;
+ lgb = rgb;
+ nptr += dlen;
}
+ if (nptr >= end_subject && (md->moptions & PCRE_PARTIAL_HARD) != 0)
+ reset_could_continue = TRUE;
if (++count >= GET2(code, 1))
{ ADD_NEW_DATA(-(state_offset + 2 + IMM2_SIZE), 0, ncount); }
else
@@ -1845,20 +1939,22 @@ for (;;)
int ncount = 0;
switch (c)
{
- case 0x000b:
- case 0x000c:
- case 0x0085:
+ case CHAR_VT:
+ case CHAR_FF:
+ case CHAR_NEL:
+#ifndef EBCDIC
case 0x2028:
case 0x2029:
+#endif /* Not EBCDIC */
if ((md->moptions & PCRE_BSR_ANYCRLF) != 0) break;
goto ANYNL03;
- case 0x000d:
- if (ptr + 1 < end_subject && ptr[1] == 0x0a) ncount = 1;
+ case CHAR_CR:
+ if (ptr + 1 < end_subject && RAWUCHARTEST(ptr + 1) == CHAR_LF) ncount = 1;
/* Fall through */
ANYNL03:
- case 0x000a:
+ case CHAR_LF:
if (codevalue == OP_ANYNL_EXTRA + OP_TYPEPOSUPTO)
{
active_count--; /* Remove non-match possibility */
@@ -1889,13 +1985,7 @@ for (;;)
BOOL OK;
switch (c)
{
- case 0x000a:
- case 0x000b:
- case 0x000c:
- case 0x000d:
- case 0x0085:
- case 0x2028:
- case 0x2029:
+ VSPACE_CASES:
OK = TRUE;
break;
@@ -1931,25 +2021,7 @@ for (;;)
BOOL OK;
switch (c)
{
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
+ HSPACE_CASES:
OK = TRUE;
break;
@@ -2025,18 +2097,24 @@ for (;;)
to wait for them to pass before continuing. */
case OP_EXTUNI:
- if (clen > 0 && UCD_CATEGORY(c) != ucp_M)
+ if (clen > 0)
{
+ int lgb, rgb;
const pcre_uchar *nptr = ptr + clen;
int ncount = 0;
+ lgb = UCD_GRAPHBREAK(c);
while (nptr < end_subject)
{
- int nclen = 1;
- GETCHARLEN(c, nptr, nclen);
- if (UCD_CATEGORY(c) != ucp_M) break;
+ dlen = 1;
+ if (!utf) d = *nptr; else { GETCHARLEN(d, nptr, dlen); }
+ rgb = UCD_GRAPHBREAK(d);
+ if ((PRIV(ucp_gbtable)[lgb] & (1 << rgb)) == 0) break;
ncount++;
- nptr += nclen;
+ lgb = rgb;
+ nptr += dlen;
}
+ if (nptr >= end_subject && (md->moptions & PCRE_PARTIAL_HARD) != 0)
+ reset_could_continue = TRUE;
ADD_NEW_DATA(-(state_offset + 1), 0, ncount);
}
break;
@@ -2050,19 +2128,27 @@ for (;;)
case OP_ANYNL:
if (clen > 0) switch(c)
{
- case 0x000b:
- case 0x000c:
- case 0x0085:
+ case CHAR_VT:
+ case CHAR_FF:
+ case CHAR_NEL:
+#ifndef EBCDIC
case 0x2028:
case 0x2029:
+#endif /* Not EBCDIC */
if ((md->moptions & PCRE_BSR_ANYCRLF) != 0) break;
- case 0x000a:
+ case CHAR_LF:
ADD_NEW(state_offset + 1, 0);
break;
- case 0x000d:
- if (ptr + 1 < end_subject && ptr[1] == 0x0a)
+ case CHAR_CR:
+ if (ptr + 1 >= end_subject)
+ {
+ ADD_NEW(state_offset + 1, 0);
+ if ((md->moptions & PCRE_PARTIAL_HARD) != 0)
+ reset_could_continue = TRUE;
+ }
+ else if (RAWUCHARTEST(ptr + 1) == CHAR_LF)
{
ADD_NEW_DATA(-(state_offset + 1), 0, 1);
}
@@ -2078,13 +2164,7 @@ for (;;)
case OP_NOT_VSPACE:
if (clen > 0) switch(c)
{
- case 0x000a:
- case 0x000b:
- case 0x000c:
- case 0x000d:
- case 0x0085:
- case 0x2028:
- case 0x2029:
+ VSPACE_CASES:
break;
default:
@@ -2097,17 +2177,12 @@ for (;;)
case OP_VSPACE:
if (clen > 0) switch(c)
{
- case 0x000a:
- case 0x000b:
- case 0x000c:
- case 0x000d:
- case 0x0085:
- case 0x2028:
- case 0x2029:
+ VSPACE_CASES:
ADD_NEW(state_offset + 1, 0);
break;
- default: break;
+ default:
+ break;
}
break;
@@ -2115,25 +2190,7 @@ for (;;)
case OP_NOT_HSPACE:
if (clen > 0) switch(c)
{
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
+ HSPACE_CASES:
break;
default:
@@ -2146,47 +2203,42 @@ for (;;)
case OP_HSPACE:
if (clen > 0) switch(c)
{
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
+ HSPACE_CASES:
ADD_NEW(state_offset + 1, 0);
break;
+
+ default:
+ break;
}
break;
/*-----------------------------------------------------------------*/
- /* Match a negated single character casefully. This is only used for
- one-byte characters, that is, we know that d < 256. The character we are
- checking (c) can be multibyte. */
+ /* Match a negated single character casefully. */
case OP_NOT:
if (clen > 0 && c != d) { ADD_NEW(state_offset + dlen + 1, 0); }
break;
/*-----------------------------------------------------------------*/
- /* Match a negated single character caselessly. This is only used for
- one-byte characters, that is, we know that d < 256. The character we are
- checking (c) can be multibyte. */
+ /* Match a negated single character caselessly. */
case OP_NOTI:
- if (clen > 0 && c != d && c != fcc[d])
- { ADD_NEW(state_offset + dlen + 1, 0); }
+ if (clen > 0)
+ {
+ unsigned int otherd;
+#ifdef SUPPORT_UTF
+ if (utf && d >= 128)
+ {
+#ifdef SUPPORT_UCP
+ otherd = UCD_OTHERCASE(d);
+#endif /* SUPPORT_UCP */
+ }
+ else
+#endif /* SUPPORT_UTF */
+ otherd = TABLE_GET(d, fcc, d);
+ if (c != d && c != otherd)
+ { ADD_NEW(state_offset + dlen + 1, 0); }
+ }
break;
/*-----------------------------------------------------------------*/
@@ -2210,7 +2262,7 @@ for (;;)
if (count > 0) { ADD_ACTIVE(state_offset + dlen + 1, 0); }
if (clen > 0)
{
- unsigned int otherd = NOTACHAR;
+ pcre_uint32 otherd = NOTACHAR;
if (caseless)
{
#ifdef SUPPORT_UTF
@@ -2257,7 +2309,7 @@ for (;;)
ADD_ACTIVE(state_offset + dlen + 1, 0);
if (clen > 0)
{
- unsigned int otherd = NOTACHAR;
+ pcre_uint32 otherd = NOTACHAR;
if (caseless)
{
#ifdef SUPPORT_UTF
@@ -2302,7 +2354,7 @@ for (;;)
ADD_ACTIVE(state_offset + dlen + 1, 0);
if (clen > 0)
{
- unsigned int otherd = NOTACHAR;
+ pcre_uint32 otherd = NOTACHAR;
if (caseless)
{
#ifdef SUPPORT_UTF
@@ -2339,7 +2391,7 @@ for (;;)
count = current_state->count; /* Number already matched */
if (clen > 0)
{
- unsigned int otherd = NOTACHAR;
+ pcre_uint32 otherd = NOTACHAR;
if (caseless)
{
#ifdef SUPPORT_UTF
@@ -2383,7 +2435,7 @@ for (;;)
count = current_state->count; /* Number already matched */
if (clen > 0)
{
- unsigned int otherd = NOTACHAR;
+ pcre_uint32 otherd = NOTACHAR;
if (caseless)
{
#ifdef SUPPORT_UTF
@@ -2481,7 +2533,7 @@ for (;;)
{ ADD_ACTIVE(next_state_offset + 1 + 2 * IMM2_SIZE, 0); }
if (isinclass)
{
- int max = GET2(ecode, 1 + IMM2_SIZE);
+ unsigned int max = GET2(ecode, 1 + IMM2_SIZE);
if (++count >= max && max != 0) /* Max 0 => no limit */
{ ADD_NEW(next_state_offset + 1 + 2 * IMM2_SIZE, 0); }
else
@@ -2557,10 +2609,12 @@ for (;;)
cb.version = 1; /* Version 1 of the callout block */
cb.callout_number = code[LINK_SIZE+2];
cb.offset_vector = offsets;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
cb.subject = (PCRE_SPTR)start_subject;
-#else
+#elif defined COMPILE_PCRE16
cb.subject = (PCRE_SPTR16)start_subject;
+#elif defined COMPILE_PCRE32
+ cb.subject = (PCRE_SPTR32)start_subject;
#endif
cb.subject_length = (int)(end_subject - start_subject);
cb.start_match = (int)(current_subject - start_subject);
@@ -2691,10 +2745,13 @@ for (;;)
for (rc = rc*2 - 2; rc >= 0; rc -= 2)
{
int charcount = local_offsets[rc+1] - local_offsets[rc];
-#ifdef SUPPORT_UTF
- const pcre_uchar *p = start_subject + local_offsets[rc];
- const pcre_uchar *pp = start_subject + local_offsets[rc+1];
- while (p < pp) if (NOT_FIRSTCHAR(*p++)) charcount--;
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
+ if (utf)
+ {
+ const pcre_uchar *p = start_subject + local_offsets[rc];
+ const pcre_uchar *pp = start_subject + local_offsets[rc+1];
+ while (p < pp) if (NOT_FIRSTCHAR(*p++)) charcount--;
+ }
#endif
if (charcount > 0)
{
@@ -2792,8 +2849,8 @@ for (;;)
const pcre_uchar *p = ptr;
const pcre_uchar *pp = local_ptr;
charcount = (int)(pp - p);
-#ifdef SUPPORT_UTF
- while (p < pp) if (NOT_FIRSTCHAR(*p++)) charcount--;
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
+ if (utf) while (p < pp) if (NOT_FIRSTCHAR(*p++)) charcount--;
#endif
ADD_NEW_DATA(-next_state_offset, 0, (charcount - 1));
}
@@ -2874,10 +2931,13 @@ for (;;)
}
else
{
-#ifdef SUPPORT_UTF
- const pcre_uchar *p = start_subject + local_offsets[0];
- const pcre_uchar *pp = start_subject + local_offsets[1];
- while (p < pp) if (NOT_FIRSTCHAR(*p++)) charcount--;
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
+ if (utf)
+ {
+ const pcre_uchar *p = start_subject + local_offsets[0];
+ const pcre_uchar *pp = start_subject + local_offsets[1];
+ while (p < pp) if (NOT_FIRSTCHAR(*p++)) charcount--;
+ }
#endif
ADD_NEW_DATA(-next_state_offset, 0, (charcount - 1));
if (repeat_state_offset >= 0)
@@ -2900,10 +2960,12 @@ for (;;)
cb.version = 1; /* Version 1 of the callout block */
cb.callout_number = code[1];
cb.offset_vector = offsets;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
cb.subject = (PCRE_SPTR)start_subject;
-#else
+#elif defined COMPILE_PCRE16
cb.subject = (PCRE_SPTR16)start_subject;
+#elif defined COMPILE_PCRE32
+ cb.subject = (PCRE_SPTR32)start_subject;
#endif
cb.subject_length = (int)(end_subject - start_subject);
cb.start_match = (int)(current_subject - start_subject);
@@ -2946,7 +3008,7 @@ for (;;)
if (new_count <= 0)
{
if (rlevel == 1 && /* Top level, and */
- could_continue && /* Some could go on */
+ could_continue && /* Some could go on, and */
forced_fail != workspace[1] && /* Not all forced fail & */
( /* either... */
(md->moptions & PCRE_PARTIAL_HARD) != 0 /* Hard partial */
@@ -2954,8 +3016,13 @@ for (;;)
((md->moptions & PCRE_PARTIAL_SOFT) != 0 && /* Soft partial and */
match_count < 0) /* no matches */
) && /* And... */
- ptr >= end_subject && /* Reached end of subject */
- ptr > md->start_used_ptr) /* Inspected non-empty string */
+ (
+ partial_newline || /* Either partial NL */
+ ( /* or ... */
+ ptr >= end_subject && /* End of subject and */
+ ptr > md->start_used_ptr) /* Inspected non-empty string */
+ )
+ )
{
if (offsetcount >= 2)
{
@@ -3014,16 +3081,21 @@ Returns: > 0 => number of match offset pairs placed in offsets
< -1 => some kind of unexpected problem
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre_dfa_exec(const pcre *argument_re, const pcre_extra *extra_data,
const char *subject, int length, int start_offset, int options, int *offsets,
int offsetcount, int *workspace, int wscount)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre16_dfa_exec(const pcre16 *argument_re, const pcre16_extra *extra_data,
PCRE_SPTR16 subject, int length, int start_offset, int options, int *offsets,
int offsetcount, int *workspace, int wscount)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_dfa_exec(const pcre32 *argument_re, const pcre32_extra *extra_data,
+ PCRE_SPTR32 subject, int length, int start_offset, int options, int *offsets,
+ int offsetcount, int *workspace, int wscount)
#endif
{
REAL_PCRE *re = (REAL_PCRE *)argument_re;
@@ -3050,12 +3122,30 @@ if (re == NULL || subject == NULL || workspace == NULL ||
(offsets == NULL && offsetcount > 0)) return PCRE_ERROR_NULL;
if (offsetcount < 0) return PCRE_ERROR_BADCOUNT;
if (wscount < 20) return PCRE_ERROR_DFA_WSSIZE;
+if (length < 0) return PCRE_ERROR_BADLENGTH;
if (start_offset < 0 || start_offset > length) return PCRE_ERROR_BADOFFSET;
-/* We need to find the pointer to any study data before we test for byte
-flipping, so we scan the extra_data block first. This may set two fields in the
-match block, so we must initialize them beforehand. However, the other fields
-in the match block must not be set until after the byte flipping. */
+/* Check that the first field in the block is the magic number. If it is not,
+return with PCRE_ERROR_BADMAGIC. However, if the magic number is equal to
+REVERSED_MAGIC_NUMBER we return with PCRE_ERROR_BADENDIANNESS, which
+means that the pattern is likely compiled with different endianness. */
+
+if (re->magic_number != MAGIC_NUMBER)
+ return re->magic_number == REVERSED_MAGIC_NUMBER?
+ PCRE_ERROR_BADENDIANNESS:PCRE_ERROR_BADMAGIC;
+if ((re->flags & PCRE_MODE) == 0) return PCRE_ERROR_BADMODE;
+
+/* If restarting after a partial match, do some sanity checks on the contents
+of the workspace. */
+
+if ((options & PCRE_DFA_RESTART) != 0)
+ {
+ if ((workspace[0] & (-2)) != 0 || workspace[1] < 1 ||
+ workspace[1] > (wscount - 2)/INTS_PER_STATEBLOCK)
+ return PCRE_ERROR_DFA_BADRESTART;
+ }
+
+/* Set up study, callout, and table data */
md->tables = re->tables;
md->callout_data = NULL;
@@ -3074,16 +3164,6 @@ if (extra_data != NULL)
md->tables = extra_data->tables;
}
-/* Check that the first field in the block is the magic number. If it is not,
-return with PCRE_ERROR_BADMAGIC. However, if the magic number is equal to
-REVERSED_MAGIC_NUMBER we return with PCRE_ERROR_BADENDIANNESS, which
-means that the pattern is likely compiled with different endianness. */
-
-if (re->magic_number != MAGIC_NUMBER)
- return re->magic_number == REVERSED_MAGIC_NUMBER?
- PCRE_ERROR_BADENDIANNESS:PCRE_ERROR_BADMAGIC;
-if ((re->flags & PCRE_MODE) == 0) return PCRE_ERROR_BADMODE;
-
/* Set some local values */
current_subject = (const pcre_uchar *)subject + start_offset;
@@ -3091,7 +3171,7 @@ end_subject = (const pcre_uchar *)subject + length;
req_char_ptr = current_subject - 1;
#ifdef SUPPORT_UTF
-/* PCRE_UTF16 has the same value as PCRE_UTF8. */
+/* PCRE_UTF(16|32) have the same value as PCRE_UTF8. */
utf = (re->options & PCRE_UTF8) != 0;
#else
utf = FALSE;
@@ -3177,12 +3257,21 @@ if (utf && (options & PCRE_NO_UTF8_CHECK) == 0)
offsets[0] = erroroffset;
offsets[1] = errorcode;
}
- return (errorcode <= PCRE_UTF8_ERR5 && (options & PCRE_PARTIAL_HARD) != 0)?
+#if defined COMPILE_PCRE8
+ return (errorcode <= PCRE_UTF8_ERR5 && (options & PCRE_PARTIAL_HARD) != 0) ?
PCRE_ERROR_SHORTUTF8 : PCRE_ERROR_BADUTF8;
+#elif defined COMPILE_PCRE16
+ return (errorcode <= PCRE_UTF16_ERR1 && (options & PCRE_PARTIAL_HARD) != 0) ?
+ PCRE_ERROR_SHORTUTF16 : PCRE_ERROR_BADUTF16;
+#elif defined COMPILE_PCRE32
+ return PCRE_ERROR_BADUTF32;
+#endif
}
+#if defined COMPILE_PCRE8 || defined COMPILE_PCRE16
if (start_offset > 0 && start_offset < length &&
NOT_FIRSTCHAR(((PCRE_PUCHAR)subject)[start_offset]))
return PCRE_ERROR_BADUTF8_OFFSET;
+#endif
}
#endif
@@ -3292,12 +3381,15 @@ for (;;)
if (has_first_char)
{
if (first_char != first_char2)
+ {
+ pcre_uchar csc;
while (current_subject < end_subject &&
- *current_subject != first_char && *current_subject != first_char2)
+ (csc = RAWUCHARTEST(current_subject)) != first_char && csc != first_char2)
current_subject++;
+ }
else
while (current_subject < end_subject &&
- *current_subject != first_char)
+ RAWUCHARTEST(current_subject) != first_char)
current_subject++;
}
@@ -3327,10 +3419,10 @@ for (;;)
ANYCRLF, and we are now at a LF, advance the match position by one
more character. */
- if (current_subject[-1] == CHAR_CR &&
+ if (RAWUCHARTEST(current_subject - 1) == CHAR_CR &&
(md->nltype == NLTYPE_ANY || md->nltype == NLTYPE_ANYCRLF) &&
current_subject < end_subject &&
- *current_subject == CHAR_NL)
+ RAWUCHARTEST(current_subject) == CHAR_NL)
current_subject++;
}
}
@@ -3341,7 +3433,7 @@ for (;;)
{
while (current_subject < end_subject)
{
- register unsigned int c = *current_subject;
+ register pcre_uint32 c = RAWUCHARTEST(current_subject);
#ifndef COMPILE_PCRE8
if (c > 255) c = 255;
#endif
@@ -3407,7 +3499,7 @@ for (;;)
{
while (p < end_subject)
{
- register int pp = *p++;
+ register pcre_uint32 pp = RAWUCHARINCTEST(p);
if (pp == req_char || pp == req_char2) { p--; break; }
}
}
@@ -3415,7 +3507,7 @@ for (;;)
{
while (p < end_subject)
{
- if (*p++ == req_char) { p--; break; }
+ if (RAWUCHARINCTEST(p) == req_char) { p--; break; }
}
}
@@ -3473,9 +3565,9 @@ for (;;)
not contain any explicit matches for \r or \n, and the newline option is CRLF
or ANY or ANYCRLF, advance the match position by one more character. */
- if (current_subject[-1] == CHAR_CR &&
+ if (RAWUCHARTEST(current_subject - 1) == CHAR_CR &&
current_subject < end_subject &&
- *current_subject == CHAR_NL &&
+ RAWUCHARTEST(current_subject) == CHAR_NL &&
(re->flags & PCRE_HASCRORLF) == 0 &&
(md->nltype == NLTYPE_ANY ||
md->nltype == NLTYPE_ANYCRLF ||
diff --git a/src/3rdparty/pcre/pcre_exec.c b/src/3rdparty/pcre/pcre_exec.c
index 2905808c83..c888468a25 100644
--- a/src/3rdparty/pcre/pcre_exec.c
+++ b/src/3rdparty/pcre/pcre_exec.c
@@ -37,7 +37,6 @@ POSSIBILITY OF SUCH DAMAGE.
-----------------------------------------------------------------------------
*/
-
/* This module contains pcre_exec(), the externally visible function that does
pattern matching using an NFA algorithm, trying to mimic Perl as closely as
possible. There are also some static supporting functions. */
@@ -93,8 +92,6 @@ because the offset vector is always a multiple of 3 long. */
static const char rep_min[] = { 0, 0, 1, 1, 0, 0 };
static const char rep_max[] = { 0, 0, 0, 0, 1, 1 };
-
-
#ifdef PCRE_DEBUG
/*************************************************
* Debugging function to print chars *
@@ -115,10 +112,11 @@ Returns: nothing
static void
pchars(const pcre_uchar *p, int length, BOOL is_subject, match_data *md)
{
-unsigned int c;
+pcre_uint32 c;
+BOOL utf = md->utf;
if (is_subject && length > md->end_subject - p) length = md->end_subject - p;
while (length-- > 0)
- if (isprint(c = *(p++))) printf("%c", c); else printf("\\x%02x", c);
+ if (isprint(c = RAWUCHARINCTEST(p))) printf("%c", (char)c); else printf("\\x{%02x}", c);
}
#endif
@@ -140,7 +138,9 @@ Arguments:
md points to match data block
caseless TRUE if caseless
-Returns: < 0 if not matched, otherwise the number of subject bytes matched
+Returns: >= 0 the number of subject bytes matched
+ -1 no match
+ -2 partial match; always given if at end subject
*/
static int
@@ -149,6 +149,9 @@ match_ref(int offset, register PCRE_PUCHAR eptr, int length, match_data *md,
{
PCRE_PUCHAR eptr_start = eptr;
register PCRE_PUCHAR p = md->start_subject + md->offset_vector[offset];
+#ifdef SUPPORT_UTF
+BOOL utf = md->utf;
+#endif
#ifdef PCRE_DEBUG
if (eptr >= md->end_subject)
@@ -163,7 +166,8 @@ pchars(p, length, FALSE, md);
printf("\n");
#endif
-/* Always fail if reference not set (and not JavaScript compatible). */
+/* Always fail if reference not set (and not JavaScript compatible - in that
+case the length is passed as zero). */
if (length < 0) return -1;
@@ -175,24 +179,35 @@ if (caseless)
{
#ifdef SUPPORT_UTF
#ifdef SUPPORT_UCP
- if (md->utf)
+ if (utf)
{
/* Match characters up to the end of the reference. NOTE: the number of
- bytes matched may differ, because there are some characters whose upper and
- lower case versions code as different numbers of bytes. For example, U+023A
- (2 bytes in UTF-8) is the upper case version of U+2C65 (3 bytes in UTF-8);
- a sequence of 3 of the former uses 6 bytes, as does a sequence of two of
- the latter. It is important, therefore, to check the length along the
- reference, not along the subject (earlier code did this wrong). */
+ data units matched may differ, because in UTF-8 there are some characters
+ whose upper and lower case versions code have different numbers of bytes.
+ For example, U+023A (2 bytes in UTF-8) is the upper case version of U+2C65
+ (3 bytes in UTF-8); a sequence of 3 of the former uses 6 bytes, as does a
+ sequence of two of the latter. It is important, therefore, to check the
+ length along the reference, not along the subject (earlier code did this
+ wrong). */
PCRE_PUCHAR endptr = p + length;
while (p < endptr)
{
- int c, d;
- if (eptr >= md->end_subject) return -1;
+ pcre_uint32 c, d;
+ const ucd_record *ur;
+ if (eptr >= md->end_subject) return -2; /* Partial match */
GETCHARINC(c, eptr);
GETCHARINC(d, p);
- if (c != d && c != UCD_OTHERCASE(d)) return -1;
+ ur = GET_UCD(d);
+ if (c != d && c != d + ur->other_case)
+ {
+ const pcre_uint32 *pp = PRIV(ucd_caseless_sets) + ur->caseset;
+ for (;;)
+ {
+ if (c < *pp) return -1;
+ if (c == *pp++) break;
+ }
+ }
}
}
else
@@ -202,10 +217,13 @@ if (caseless)
/* The same code works when not in UTF-8 mode and in UTF-8 mode when there
is no UCP support. */
{
- if (eptr + length > md->end_subject) return -1;
while (length-- > 0)
{
- if (TABLE_GET(*p, md->lcc, *p) != TABLE_GET(*eptr, md->lcc, *eptr)) return -1;
+ pcre_uchar cc, cp;
+ if (eptr >= md->end_subject) return -2; /* Partial match */
+ cc = RAWUCHARTEST(eptr);
+ cp = RAWUCHARTEST(p);
+ if (TABLE_GET(cp, md->lcc, cp) != TABLE_GET(cc, md->lcc, cc)) return -1;
p++;
eptr++;
}
@@ -217,8 +235,11 @@ are in UTF-8 mode. */
else
{
- if (eptr + length > md->end_subject) return -1;
- while (length-- > 0) if (*p++ != *eptr++) return -1;
+ while (length-- > 0)
+ {
+ if (eptr >= md->end_subject) return -2; /* Partial match */
+ if (RAWUCHARINCTEST(p) != RAWUCHARINCTEST(eptr)) return -1;
+ }
}
return (int)(eptr - eptr_start);
@@ -273,7 +294,7 @@ enum { RM1=1, RM2, RM3, RM4, RM5, RM6, RM7, RM8, RM9, RM10,
RM31, RM32, RM33, RM34, RM35, RM36, RM37, RM38, RM39, RM40,
RM41, RM42, RM43, RM44, RM45, RM46, RM47, RM48, RM49, RM50,
RM51, RM52, RM53, RM54, RM55, RM56, RM57, RM58, RM59, RM60,
- RM61, RM62, RM63, RM64, RM65, RM66 };
+ RM61, RM62, RM63, RM64, RM65, RM66, RM67 };
/* These versions of the macros use the stack, as normal. There are debugging
versions and production versions. Note that the "rw" argument of RMATCH isn't
@@ -291,7 +312,7 @@ actually used in this definition. */
}
#define RRETURN(ra) \
{ \
- printf("match() returned %d from line %d ", ra, __LINE__); \
+ printf("match() returned %d from line %d\n", ra, __LINE__); \
return ra; \
}
#else
@@ -311,9 +332,15 @@ argument of match(), which never changes. */
#define RMATCH(ra,rb,rc,rd,re,rw)\
{\
- heapframe *newframe = (heapframe *)(PUBL(stack_malloc))(sizeof(heapframe));\
- if (newframe == NULL) RRETURN(PCRE_ERROR_NOMEMORY);\
- frame->Xwhere = rw; \
+ heapframe *newframe = frame->Xnextframe;\
+ if (newframe == NULL)\
+ {\
+ newframe = (heapframe *)(PUBL(stack_malloc))(sizeof(heapframe));\
+ if (newframe == NULL) RRETURN(PCRE_ERROR_NOMEMORY);\
+ newframe->Xnextframe = NULL;\
+ frame->Xnextframe = newframe;\
+ }\
+ frame->Xwhere = rw;\
newframe->Xeptr = ra;\
newframe->Xecode = rb;\
newframe->Xmstart = mstart;\
@@ -332,7 +359,6 @@ argument of match(), which never changes. */
{\
heapframe *oldframe = frame;\
frame = oldframe->Xprevframe;\
- if (oldframe != &frame_zero) (PUBL(stack_free))(oldframe);\
if (frame != NULL)\
{\
rrc = ra;\
@@ -346,6 +372,7 @@ argument of match(), which never changes. */
typedef struct heapframe {
struct heapframe *Xprevframe;
+ struct heapframe *Xnextframe;
/* Function arguments that may change */
@@ -376,7 +403,7 @@ typedef struct heapframe {
#ifdef SUPPORT_UCP
int Xprop_type;
- int Xprop_value;
+ unsigned int Xprop_value;
int Xprop_fail_result;
int Xoclength;
pcre_uchar Xocchars[6];
@@ -477,7 +504,7 @@ so they can be ordinary variables in all cases. Mark some of them with
register int rrc; /* Returns from recursive calls */
register int i; /* Used for loops not involving calls to RMATCH() */
-register unsigned int c; /* Character values not kept over RMATCH() calls */
+register pcre_uint32 c; /* Character values not kept over RMATCH() calls */
register BOOL utf; /* Local copy of UTF flag for speed */
BOOL minimize, possessive; /* Quantifier options */
@@ -492,9 +519,7 @@ the top-level on the stack rather than malloc-ing them all gives a performance
boost in many cases where there is not much "recursion". */
#ifdef NO_RECURSE
-heapframe frame_zero;
-heapframe *frame = &frame_zero;
-frame->Xprevframe = NULL; /* Marks the top level */
+heapframe *frame = (heapframe *)md->match_frames_base;
/* Copy in the original argument variables */
@@ -596,7 +621,7 @@ BOOL prev_is_word;
#ifdef SUPPORT_UCP
int prop_type;
-int prop_value;
+unsigned int prop_value;
int prop_fail_result;
int oclength;
pcre_uchar occhars[6];
@@ -607,9 +632,9 @@ int ctype;
int length;
int max;
int min;
-int number;
+unsigned int number;
int offset;
-int op;
+pcre_uchar op;
int save_capture_last;
int save_offset1, save_offset2, save_offset3;
int stacksave[REC_STACK_SAVE_MAX];
@@ -728,7 +753,7 @@ for (;;)
unaltered. */
else if (rrc == MATCH_SKIP_ARG &&
- STRCMP_UC_UC(ecode + 2, md->start_match_ptr) == 0)
+ STRCMP_UC_UC_TEST(ecode + 2, md->start_match_ptr) == 0)
{
md->start_match_ptr = eptr;
RRETURN(MATCH_SKIP);
@@ -897,7 +922,6 @@ for (;;)
}
else /* OP_KETRMAX */
{
- md->match_function_type = MATCH_CBEGROUP;
RMATCH(eptr, prev, offset_top, md, eptrb, RM66);
if (rrc != MATCH_NOMATCH) RRETURN(rrc);
ecode += 1 + LINK_SIZE;
@@ -1026,7 +1050,8 @@ for (;;)
for (;;)
{
- if (op >= OP_SBRA || op == OP_ONCE) md->match_function_type = MATCH_CBEGROUP;
+ if (op >= OP_SBRA || op == OP_ONCE)
+ md->match_function_type = MATCH_CBEGROUP;
/* If this is not a possibly empty group, and there are no (*THEN)s in
the pattern, and this is the final alternative, optimize as described
@@ -1253,10 +1278,12 @@ for (;;)
cb.version = 2; /* Version 1 of the callout block */
cb.callout_number = ecode[LINK_SIZE+2];
cb.offset_vector = md->offset_vector;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
cb.subject = (PCRE_SPTR)md->start_subject;
-#else
+#elif defined COMPILE_PCRE16
cb.subject = (PCRE_SPTR16)md->start_subject;
+#elif defined COMPILE_PCRE32
+ cb.subject = (PCRE_SPTR32)md->start_subject;
#endif
cb.subject_length = (int)(md->end_subject - md->start_subject);
cb.start_match = (int)(mstart - md->start_subject);
@@ -1286,7 +1313,7 @@ for (;;)
}
else
{
- int recno = GET2(ecode, LINK_SIZE + 2); /* Recursion group number*/
+ unsigned int recno = GET2(ecode, LINK_SIZE + 2); /* Recursion group number*/
condition = (recno == RREF_ANY || recno == md->recursive->group_num);
/* If the test is for recursion into a specific subpattern, and it is
@@ -1358,7 +1385,7 @@ for (;;)
if (!condition && condcode == OP_NCREF)
{
- int refno = offset >> 1;
+ unsigned int refno = offset >> 1;
pcre_uchar *slotA = md->name_table;
for (i = 0; i < md->name_count; i++)
@@ -1565,13 +1592,18 @@ for (;;)
mstart = md->start_match_ptr; /* In case \K reset it */
break;
}
+ md->mark = save_mark;
- /* PCRE does not allow THEN to escape beyond an assertion; it is treated
- as NOMATCH. */
+ /* A COMMIT failure must fail the entire assertion, without trying any
+ subsequent branches. */
+
+ if (rrc == MATCH_COMMIT) RRETURN(MATCH_NOMATCH);
+
+ /* PCRE does not allow THEN to escape beyond an assertion; it
+ is treated as NOMATCH. */
if (rrc != MATCH_NOMATCH && rrc != MATCH_THEN) RRETURN(rrc);
ecode += GET(ecode, 1);
- md->mark = save_mark;
}
while (*ecode == OP_ALT);
@@ -1671,10 +1703,12 @@ for (;;)
cb.version = 2; /* Version 1 of the callout block */
cb.callout_number = ecode[1];
cb.offset_vector = md->offset_vector;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
cb.subject = (PCRE_SPTR)md->start_subject;
-#else
+#elif defined COMPILE_PCRE16
cb.subject = (PCRE_SPTR16)md->start_subject;
+#elif defined COMPILE_PCRE32
+ cb.subject = (PCRE_SPTR32)md->start_subject;
#endif
cb.subject_length = (int)(md->end_subject - md->start_subject);
cb.start_match = (int)(mstart - md->start_subject);
@@ -1711,7 +1745,7 @@ for (;;)
case OP_RECURSE:
{
recursion_info *ri;
- int recno;
+ unsigned int recno;
callpat = md->start_code + GET(ecode, 1);
recno = (callpat == md->start_code)? 0 :
@@ -1779,10 +1813,11 @@ for (;;)
goto RECURSION_MATCHED; /* Exit loop; end processing */
}
- /* PCRE does not allow THEN to escape beyond a recursion; it is treated
- as NOMATCH. */
+ /* PCRE does not allow THEN or COMMIT to escape beyond a recursion; it
+ is treated as NOMATCH. */
- else if (rrc != MATCH_NOMATCH && rrc != MATCH_THEN)
+ else if (rrc != MATCH_NOMATCH && rrc != MATCH_THEN &&
+ rrc != MATCH_COMMIT)
{
DPRINTF(("Recursion gave error %d\n", rrc));
if (new_recursive.offset_save != stacksave)
@@ -1993,7 +2028,6 @@ for (;;)
}
if (*prev >= OP_SBRA) /* Could match an empty string */
{
- md->match_function_type = MATCH_CBEGROUP;
RMATCH(eptr, prev, offset_top, md, eptrb, RM50);
RRETURN(rrc);
}
@@ -2002,7 +2036,6 @@ for (;;)
}
else /* OP_KETRMAX */
{
- if (*prev >= OP_SBRA) md->match_function_type = MATCH_CBEGROUP;
RMATCH(eptr, prev, offset_top, md, eptrb, RM13);
if (rrc == MATCH_ONCE && md->once_target == prev) rrc = MATCH_NOMATCH;
if (rrc != MATCH_NOMATCH) RRETURN(rrc);
@@ -2059,7 +2092,21 @@ for (;;)
case OP_DOLLM:
if (eptr < md->end_subject)
- { if (!IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH); }
+ {
+ if (!IS_NEWLINE(eptr))
+ {
+ if (md->partial != 0 &&
+ eptr + 1 >= md->end_subject &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ RAWUCHARTEST(eptr) == NLBLOCK->nl[0])
+ {
+ md->hitend = TRUE;
+ if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
+ }
+ RRETURN(MATCH_NOMATCH);
+ }
+ }
else
{
if (md->noteol) RRETURN(MATCH_NOMATCH);
@@ -2091,7 +2138,18 @@ for (;;)
ASSERT_NL_OR_EOS:
if (eptr < md->end_subject &&
(!IS_NEWLINE(eptr) || eptr != md->end_subject - md->nllen))
+ {
+ if (md->partial != 0 &&
+ eptr + 1 >= md->end_subject &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ RAWUCHARTEST(eptr) == NLBLOCK->nl[0])
+ {
+ md->hitend = TRUE;
+ if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
+ }
RRETURN(MATCH_NOMATCH);
+ }
/* Either at end of string or \n before end. */
@@ -2219,12 +2277,25 @@ for (;;)
}
break;
- /* Match a single character type; inline for speed */
+ /* Match any single character type except newline; have to take care with
+ CRLF newlines and partial matching. */
case OP_ANY:
if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
+ if (md->partial != 0 &&
+ eptr + 1 >= md->end_subject &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ RAWUCHARTEST(eptr) == NLBLOCK->nl[0])
+ {
+ md->hitend = TRUE;
+ if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
+ }
+
/* Fall through */
+ /* Match any single character whatsoever. */
+
case OP_ALLANY:
if (eptr >= md->end_subject) /* DO NOT merge the eptr++ here; it must */
{ /* not be updated before SCHECK_PARTIAL. */
@@ -2364,18 +2435,24 @@ for (;;)
{
default: RRETURN(MATCH_NOMATCH);
- case 0x000d:
- if (eptr < md->end_subject && *eptr == 0x0a) eptr++;
+ case CHAR_CR:
+ if (eptr >= md->end_subject)
+ {
+ SCHECK_PARTIAL();
+ }
+ else if (RAWUCHARTEST(eptr) == CHAR_LF) eptr++;
break;
- case 0x000a:
+ case CHAR_LF:
break;
- case 0x000b:
- case 0x000c:
- case 0x0085:
+ case CHAR_VT:
+ case CHAR_FF:
+ case CHAR_NEL:
+#ifndef EBCDIC
case 0x2028:
case 0x2029:
+#endif /* Not EBCDIC */
if (md->bsr_anycrlf) RRETURN(MATCH_NOMATCH);
break;
}
@@ -2391,27 +2468,8 @@ for (;;)
GETCHARINCTEST(c, eptr);
switch(c)
{
+ HSPACE_CASES: RRETURN(MATCH_NOMATCH); /* Byte and multibyte cases */
default: break;
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
- RRETURN(MATCH_NOMATCH);
}
ecode++;
break;
@@ -2425,27 +2483,8 @@ for (;;)
GETCHARINCTEST(c, eptr);
switch(c)
{
+ HSPACE_CASES: break; /* Byte and multibyte cases */
default: RRETURN(MATCH_NOMATCH);
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
- break;
}
ecode++;
break;
@@ -2459,15 +2498,8 @@ for (;;)
GETCHARINCTEST(c, eptr);
switch(c)
{
+ VSPACE_CASES: RRETURN(MATCH_NOMATCH);
default: break;
- case 0x0a: /* LF */
- case 0x0b: /* VT */
- case 0x0c: /* FF */
- case 0x0d: /* CR */
- case 0x85: /* NEL */
- case 0x2028: /* LINE SEPARATOR */
- case 0x2029: /* PARAGRAPH SEPARATOR */
- RRETURN(MATCH_NOMATCH);
}
ecode++;
break;
@@ -2481,15 +2513,8 @@ for (;;)
GETCHARINCTEST(c, eptr);
switch(c)
{
+ VSPACE_CASES: break;
default: RRETURN(MATCH_NOMATCH);
- case 0x0a: /* LF */
- case 0x0b: /* VT */
- case 0x0c: /* FF */
- case 0x0d: /* CR */
- case 0x85: /* NEL */
- case 0x2028: /* LINE SEPARATOR */
- case 0x2029: /* PARAGRAPH SEPARATOR */
- break;
}
ecode++;
break;
@@ -2507,6 +2532,7 @@ for (;;)
}
GETCHARINCTEST(c, eptr);
{
+ const pcre_uint32 *cp;
const ucd_record *prop = GET_UCD(c);
switch(ecode[1])
@@ -2567,6 +2593,17 @@ for (;;)
RRETURN(MATCH_NOMATCH);
break;
+ case PT_CLIST:
+ cp = PRIV(ucd_caseless_sets) + ecode[2];
+ for (;;)
+ {
+ if (c < *cp)
+ { if (op == OP_PROP) { RRETURN(MATCH_NOMATCH); } else break; }
+ if (c == *cp++)
+ { if (op == OP_PROP) break; else { RRETURN(MATCH_NOMATCH); } }
+ }
+ break;
+
/* This should never occur */
default:
@@ -2586,18 +2623,25 @@ for (;;)
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- GETCHARINCTEST(c, eptr);
- if (UCD_CATEGORY(c) == ucp_M) RRETURN(MATCH_NOMATCH);
- while (eptr < md->end_subject)
+ else
{
- int len = 1;
- if (!utf) c = *eptr; else { GETCHARLEN(c, eptr, len); }
- if (UCD_CATEGORY(c) != ucp_M) break;
- eptr += len;
+ int lgb, rgb;
+ GETCHARINCTEST(c, eptr);
+ lgb = UCD_GRAPHBREAK(c);
+ while (eptr < md->end_subject)
+ {
+ int len = 1;
+ if (!utf) c = *eptr; else { GETCHARLEN(c, eptr, len); }
+ rgb = UCD_GRAPHBREAK(c);
+ if ((PRIV(ucp_gbtable)[lgb] & (1 << rgb)) == 0) break;
+ lgb = rgb;
+ eptr += len;
+ }
}
+ CHECK_PARTIAL();
ecode++;
break;
-#endif
+#endif /* SUPPORT_UCP */
/* Match a back reference, possibly repeatedly. Look past the end of the
@@ -2660,6 +2704,7 @@ for (;;)
default: /* No repeat follows */
if ((length = match_ref(offset, eptr, length, md, caseless)) < 0)
{
+ if (length == -2) eptr = md->end_subject; /* Partial match */
CHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
@@ -2685,6 +2730,7 @@ for (;;)
int slength;
if ((slength = match_ref(offset, eptr, length, md, caseless)) < 0)
{
+ if (slength == -2) eptr = md->end_subject; /* Partial match */
CHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
@@ -2708,6 +2754,7 @@ for (;;)
if (fi >= max) RRETURN(MATCH_NOMATCH);
if ((slength = match_ref(offset, eptr, length, md, caseless)) < 0)
{
+ if (slength == -2) eptr = md->end_subject; /* Partial match */
CHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
@@ -2726,11 +2773,20 @@ for (;;)
int slength;
if ((slength = match_ref(offset, eptr, length, md, caseless)) < 0)
{
- CHECK_PARTIAL();
+ /* Can't use CHECK_PARTIAL because we don't want to update eptr in
+ the soft partial matching case. */
+
+ if (slength == -2 && md->partial != 0 &&
+ md->end_subject > md->start_used_ptr)
+ {
+ md->hitend = TRUE;
+ if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
+ }
break;
}
eptr += slength;
}
+
while (eptr >= pp)
{
RMATCH(eptr, ecode, offset_top, md, eptrb, RM15);
@@ -3094,7 +3150,7 @@ for (;;)
CHECK_PARTIAL(); /* Not SCHECK_PARTIAL() */
RRETURN(MATCH_NOMATCH);
}
- while (length-- > 0) if (*ecode++ != *eptr++) RRETURN(MATCH_NOMATCH);
+ while (length-- > 0) if (*ecode++ != RAWUCHARINC(eptr)) RRETURN(MATCH_NOMATCH);
}
else
#endif
@@ -3134,8 +3190,8 @@ for (;;)
if (fc < 128)
{
- if (md->lcc[fc]
- != TABLE_GET(*eptr, md->lcc, *eptr)) RRETURN(MATCH_NOMATCH);
+ pcre_uchar cc = RAWUCHAR(eptr);
+ if (md->lcc[fc] != TABLE_GET(cc, md->lcc, cc)) RRETURN(MATCH_NOMATCH);
ecode++;
eptr++;
}
@@ -3146,7 +3202,7 @@ for (;;)
else
{
- unsigned int dc;
+ pcre_uint32 dc;
GETCHARINC(dc, eptr);
ecode += length;
@@ -3256,7 +3312,7 @@ for (;;)
if (length > 1)
{
#ifdef SUPPORT_UCP
- unsigned int othercase;
+ pcre_uint32 othercase;
if (op >= OP_STARI && /* Caseless */
(othercase = UCD_OTHERCASE(fc)) != fc)
oclength = PRIV(ord2utf)(othercase, occhars);
@@ -3360,7 +3416,7 @@ for (;;)
maximizing, find the maximum number of characters and work backwards. */
DPRINTF(("matching %c{%d,%d} against subject %.*s\n", fc, min, max,
- max, eptr));
+ max, (char *)eptr));
if (op >= OP_STARI) /* Caseless */
{
@@ -3383,12 +3439,15 @@ for (;;)
for (i = 1; i <= min; i++)
{
+ pcre_uchar cc;
+
if (eptr >= md->end_subject)
{
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- if (fc != *eptr && foc != *eptr) RRETURN(MATCH_NOMATCH);
+ cc = RAWUCHARTEST(eptr);
+ if (fc != cc && foc != cc) RRETURN(MATCH_NOMATCH);
eptr++;
}
if (min == max) continue;
@@ -3396,6 +3455,8 @@ for (;;)
{
for (fi = min;; fi++)
{
+ pcre_uchar cc;
+
RMATCH(eptr, ecode, offset_top, md, eptrb, RM24);
if (rrc != MATCH_NOMATCH) RRETURN(rrc);
if (fi >= max) RRETURN(MATCH_NOMATCH);
@@ -3404,7 +3465,8 @@ for (;;)
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- if (fc != *eptr && foc != *eptr) RRETURN(MATCH_NOMATCH);
+ cc = RAWUCHARTEST(eptr);
+ if (fc != cc && foc != cc) RRETURN(MATCH_NOMATCH);
eptr++;
}
/* Control never gets here */
@@ -3414,12 +3476,15 @@ for (;;)
pp = eptr;
for (i = min; i < max; i++)
{
+ pcre_uchar cc;
+
if (eptr >= md->end_subject)
{
SCHECK_PARTIAL();
break;
}
- if (fc != *eptr && foc != *eptr) break;
+ cc = RAWUCHARTEST(eptr);
+ if (fc != cc && foc != cc) break;
eptr++;
}
@@ -3447,7 +3512,7 @@ for (;;)
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- if (fc != *eptr++) RRETURN(MATCH_NOMATCH);
+ if (fc != RAWUCHARINCTEST(eptr)) RRETURN(MATCH_NOMATCH);
}
if (min == max) continue;
@@ -3464,7 +3529,7 @@ for (;;)
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- if (fc != *eptr++) RRETURN(MATCH_NOMATCH);
+ if (fc != RAWUCHARINCTEST(eptr)) RRETURN(MATCH_NOMATCH);
}
/* Control never gets here */
}
@@ -3478,7 +3543,7 @@ for (;;)
SCHECK_PARTIAL();
break;
}
- if (fc != *eptr) break;
+ if (fc != RAWUCHARTEST(eptr)) break;
eptr++;
}
if (possessive) continue;
@@ -3504,33 +3569,41 @@ for (;;)
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- ecode++;
- GETCHARINCTEST(c, eptr);
- if (op == OP_NOTI) /* The caseless case */
- {
- register unsigned int ch, och;
- ch = *ecode++;
-#ifdef COMPILE_PCRE8
- /* ch must be < 128 if UTF is enabled. */
- och = md->fcc[ch];
-#else
#ifdef SUPPORT_UTF
+ if (utf)
+ {
+ register pcre_uint32 ch, och;
+
+ ecode++;
+ GETCHARINC(ch, ecode);
+ GETCHARINC(c, eptr);
+
+ if (op == OP_NOT)
+ {
+ if (ch == c) RRETURN(MATCH_NOMATCH);
+ }
+ else
+ {
#ifdef SUPPORT_UCP
- if (utf && ch > 127)
- och = UCD_OTHERCASE(ch);
+ if (ch > 127)
+ och = UCD_OTHERCASE(ch);
#else
- if (utf && ch > 127)
- och = ch;
+ if (ch > 127)
+ och = ch;
#endif /* SUPPORT_UCP */
- else
-#endif /* SUPPORT_UTF */
- och = TABLE_GET(ch, md->fcc, ch);
-#endif /* COMPILE_PCRE8 */
- if (ch == c || och == c) RRETURN(MATCH_NOMATCH);
+ else
+ och = TABLE_GET(ch, md->fcc, ch);
+ if (ch == c || och == c) RRETURN(MATCH_NOMATCH);
+ }
}
- else /* Caseful */
+ else
+#endif
{
- if (*ecode++ == c) RRETURN(MATCH_NOMATCH);
+ register pcre_uint32 ch = ecode[1];
+ c = *eptr++;
+ if (ch == c || (op == OP_NOTI && TABLE_GET(ch, md->fcc, ch) == c))
+ RRETURN(MATCH_NOMATCH);
+ ecode += 2;
}
break;
@@ -3610,7 +3683,7 @@ for (;;)
/* Common code for all repeated single-byte matches. */
REPEATNOTCHAR:
- fc = *ecode++;
+ GETCHARINCTEST(fc, ecode);
/* The code is duplicated for the caseless and caseful cases, for speed,
since matching characters is likely to be quite common. First, ensure the
@@ -3621,14 +3694,10 @@ for (;;)
characters and work backwards. */
DPRINTF(("negative matching %c{%d,%d} against subject %.*s\n", fc, min, max,
- max, eptr));
+ max, (char *)eptr));
if (op >= OP_NOTSTARI) /* Caseless */
{
-#ifdef COMPILE_PCRE8
- /* fc must be < 128 if UTF is enabled. */
- foc = md->fcc[fc];
-#else
#ifdef SUPPORT_UTF
#ifdef SUPPORT_UCP
if (utf && fc > 127)
@@ -3640,12 +3709,11 @@ for (;;)
else
#endif /* SUPPORT_UTF */
foc = TABLE_GET(fc, md->fcc, fc);
-#endif /* COMPILE_PCRE8 */
#ifdef SUPPORT_UTF
if (utf)
{
- register unsigned int d;
+ register pcre_uint32 d;
for (i = 1; i <= min; i++)
{
if (eptr >= md->end_subject)
@@ -3654,7 +3722,7 @@ for (;;)
RRETURN(MATCH_NOMATCH);
}
GETCHARINC(d, eptr);
- if (fc == d || (unsigned int) foc == d) RRETURN(MATCH_NOMATCH);
+ if (fc == d || (unsigned int)foc == d) RRETURN(MATCH_NOMATCH);
}
}
else
@@ -3680,7 +3748,7 @@ for (;;)
#ifdef SUPPORT_UTF
if (utf)
{
- register unsigned int d;
+ register pcre_uint32 d;
for (fi = min;; fi++)
{
RMATCH(eptr, ecode, offset_top, md, eptrb, RM28);
@@ -3725,7 +3793,7 @@ for (;;)
#ifdef SUPPORT_UTF
if (utf)
{
- register unsigned int d;
+ register pcre_uint32 d;
for (i = min; i < max; i++)
{
int len = 1;
@@ -3782,7 +3850,7 @@ for (;;)
#ifdef SUPPORT_UTF
if (utf)
{
- register unsigned int d;
+ register pcre_uint32 d;
for (i = 1; i <= min; i++)
{
if (eptr >= md->end_subject)
@@ -3816,7 +3884,7 @@ for (;;)
#ifdef SUPPORT_UTF
if (utf)
{
- register unsigned int d;
+ register pcre_uint32 d;
for (fi = min;; fi++)
{
RMATCH(eptr, ecode, offset_top, md, eptrb, RM32);
@@ -3860,7 +3928,7 @@ for (;;)
#ifdef SUPPORT_UTF
if (utf)
{
- register unsigned int d;
+ register pcre_uint32 d;
for (i = min; i < max; i++)
{
int len = 1;
@@ -4136,6 +4204,27 @@ for (;;)
}
break;
+ case PT_CLIST:
+ for (i = 1; i <= min; i++)
+ {
+ const pcre_uint32 *cp;
+ if (eptr >= md->end_subject)
+ {
+ SCHECK_PARTIAL();
+ RRETURN(MATCH_NOMATCH);
+ }
+ GETCHARINCTEST(c, eptr);
+ cp = PRIV(ucd_caseless_sets) + prop_value;
+ for (;;)
+ {
+ if (c < *cp)
+ { if (prop_fail_result) break; else { RRETURN(MATCH_NOMATCH); } }
+ if (c == *cp++)
+ { if (prop_fail_result) { RRETURN(MATCH_NOMATCH); } else break; }
+ }
+ }
+ break;
+
/* This should not occur */
default:
@@ -4155,15 +4244,22 @@ for (;;)
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- GETCHARINCTEST(c, eptr);
- if (UCD_CATEGORY(c) == ucp_M) RRETURN(MATCH_NOMATCH);
- while (eptr < md->end_subject)
+ else
{
- int len = 1;
- if (!utf) c = *eptr; else { GETCHARLEN(c, eptr, len); }
- if (UCD_CATEGORY(c) != ucp_M) break;
- eptr += len;
+ int lgb, rgb;
+ GETCHARINCTEST(c, eptr);
+ lgb = UCD_GRAPHBREAK(c);
+ while (eptr < md->end_subject)
+ {
+ int len = 1;
+ if (!utf) c = *eptr; else { GETCHARLEN(c, eptr, len); }
+ rgb = UCD_GRAPHBREAK(c);
+ if ((PRIV(ucp_gbtable)[lgb] & (1 << rgb)) == 0) break;
+ lgb = rgb;
+ eptr += len;
+ }
}
+ CHECK_PARTIAL();
}
}
@@ -4184,6 +4280,15 @@ for (;;)
RRETURN(MATCH_NOMATCH);
}
if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
+ if (md->partial != 0 &&
+ eptr + 1 >= md->end_subject &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ RAWUCHAR(eptr) == NLBLOCK->nl[0])
+ {
+ md->hitend = TRUE;
+ if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
+ }
eptr++;
ACROSSCHAR(eptr < md->end_subject, *eptr, eptr++);
}
@@ -4220,18 +4325,20 @@ for (;;)
{
default: RRETURN(MATCH_NOMATCH);
- case 0x000d:
- if (eptr < md->end_subject && *eptr == 0x0a) eptr++;
+ case CHAR_CR:
+ if (eptr < md->end_subject && RAWUCHAR(eptr) == CHAR_LF) eptr++;
break;
- case 0x000a:
+ case CHAR_LF:
break;
- case 0x000b:
- case 0x000c:
- case 0x0085:
+ case CHAR_VT:
+ case CHAR_FF:
+ case CHAR_NEL:
+#ifndef EBCDIC
case 0x2028:
case 0x2029:
+#endif /* Not EBCDIC */
if (md->bsr_anycrlf) RRETURN(MATCH_NOMATCH);
break;
}
@@ -4249,27 +4356,8 @@ for (;;)
GETCHARINC(c, eptr);
switch(c)
{
+ HSPACE_CASES: RRETURN(MATCH_NOMATCH); /* Byte and multibyte cases */
default: break;
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
- RRETURN(MATCH_NOMATCH);
}
}
break;
@@ -4285,27 +4373,8 @@ for (;;)
GETCHARINC(c, eptr);
switch(c)
{
+ HSPACE_CASES: break; /* Byte and multibyte cases */
default: RRETURN(MATCH_NOMATCH);
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
- break;
}
}
break;
@@ -4321,15 +4390,8 @@ for (;;)
GETCHARINC(c, eptr);
switch(c)
{
+ VSPACE_CASES: RRETURN(MATCH_NOMATCH);
default: break;
- case 0x0a: /* LF */
- case 0x0b: /* VT */
- case 0x0c: /* FF */
- case 0x0d: /* CR */
- case 0x85: /* NEL */
- case 0x2028: /* LINE SEPARATOR */
- case 0x2029: /* PARAGRAPH SEPARATOR */
- RRETURN(MATCH_NOMATCH);
}
}
break;
@@ -4345,15 +4407,8 @@ for (;;)
GETCHARINC(c, eptr);
switch(c)
{
+ VSPACE_CASES: break;
default: RRETURN(MATCH_NOMATCH);
- case 0x0a: /* LF */
- case 0x0b: /* VT */
- case 0x0c: /* FF */
- case 0x0d: /* CR */
- case 0x85: /* NEL */
- case 0x2028: /* LINE SEPARATOR */
- case 0x2029: /* PARAGRAPH SEPARATOR */
- break;
}
}
break;
@@ -4375,12 +4430,15 @@ for (;;)
case OP_DIGIT:
for (i = 1; i <= min; i++)
{
+ pcre_uchar cc;
+
if (eptr >= md->end_subject)
{
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- if (*eptr >= 128 || (md->ctypes[*eptr] & ctype_digit) == 0)
+ cc = RAWUCHAR(eptr);
+ if (cc >= 128 || (md->ctypes[cc] & ctype_digit) == 0)
RRETURN(MATCH_NOMATCH);
eptr++;
/* No need to skip more bytes - we know it's a 1-byte character */
@@ -4390,12 +4448,15 @@ for (;;)
case OP_NOT_WHITESPACE:
for (i = 1; i <= min; i++)
{
+ pcre_uchar cc;
+
if (eptr >= md->end_subject)
{
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- if (*eptr < 128 && (md->ctypes[*eptr] & ctype_space) != 0)
+ cc = RAWUCHAR(eptr);
+ if (cc < 128 && (md->ctypes[cc] & ctype_space) != 0)
RRETURN(MATCH_NOMATCH);
eptr++;
ACROSSCHAR(eptr < md->end_subject, *eptr, eptr++);
@@ -4405,12 +4466,15 @@ for (;;)
case OP_WHITESPACE:
for (i = 1; i <= min; i++)
{
+ pcre_uchar cc;
+
if (eptr >= md->end_subject)
{
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- if (*eptr >= 128 || (md->ctypes[*eptr] & ctype_space) == 0)
+ cc = RAWUCHAR(eptr);
+ if (cc >= 128 || (md->ctypes[cc] & ctype_space) == 0)
RRETURN(MATCH_NOMATCH);
eptr++;
/* No need to skip more bytes - we know it's a 1-byte character */
@@ -4420,12 +4484,15 @@ for (;;)
case OP_NOT_WORDCHAR:
for (i = 1; i <= min; i++)
{
+ pcre_uchar cc;
+
if (eptr >= md->end_subject)
{
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- if (*eptr < 128 && (md->ctypes[*eptr] & ctype_word) != 0)
+ cc = RAWUCHAR(eptr);
+ if (cc < 128 && (md->ctypes[cc] & ctype_word) != 0)
RRETURN(MATCH_NOMATCH);
eptr++;
ACROSSCHAR(eptr < md->end_subject, *eptr, eptr++);
@@ -4435,12 +4502,15 @@ for (;;)
case OP_WORDCHAR:
for (i = 1; i <= min; i++)
{
+ pcre_uchar cc;
+
if (eptr >= md->end_subject)
{
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- if (*eptr >= 128 || (md->ctypes[*eptr] & ctype_word) == 0)
+ cc = RAWUCHAR(eptr);
+ if (cc >= 128 || (md->ctypes[cc] & ctype_word) == 0)
RRETURN(MATCH_NOMATCH);
eptr++;
/* No need to skip more bytes - we know it's a 1-byte character */
@@ -4468,6 +4538,15 @@ for (;;)
RRETURN(MATCH_NOMATCH);
}
if (IS_NEWLINE(eptr)) RRETURN(MATCH_NOMATCH);
+ if (md->partial != 0 &&
+ eptr + 1 >= md->end_subject &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ *eptr == NLBLOCK->nl[0])
+ {
+ md->hitend = TRUE;
+ if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
+ }
eptr++;
}
break;
@@ -4502,17 +4581,17 @@ for (;;)
{
default: RRETURN(MATCH_NOMATCH);
- case 0x000d:
- if (eptr < md->end_subject && *eptr == 0x0a) eptr++;
+ case CHAR_CR:
+ if (eptr < md->end_subject && *eptr == CHAR_LF) eptr++;
break;
- case 0x000a:
+ case CHAR_LF:
break;
- case 0x000b:
- case 0x000c:
- case 0x0085:
-#ifdef COMPILE_PCRE16
+ case CHAR_VT:
+ case CHAR_FF:
+ case CHAR_NEL:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
case 0x2028:
case 0x2029:
#endif
@@ -4533,26 +4612,9 @@ for (;;)
switch(*eptr++)
{
default: break;
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
-#ifdef COMPILE_PCRE16
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
+ HSPACE_BYTE_CASES:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ HSPACE_MULTIBYTE_CASES:
#endif
RRETURN(MATCH_NOMATCH);
}
@@ -4570,26 +4632,9 @@ for (;;)
switch(*eptr++)
{
default: RRETURN(MATCH_NOMATCH);
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
-#ifdef COMPILE_PCRE16
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
+ HSPACE_BYTE_CASES:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ HSPACE_MULTIBYTE_CASES:
#endif
break;
}
@@ -4606,17 +4651,12 @@ for (;;)
}
switch(*eptr++)
{
- default: break;
- case 0x0a: /* LF */
- case 0x0b: /* VT */
- case 0x0c: /* FF */
- case 0x0d: /* CR */
- case 0x85: /* NEL */
-#ifdef COMPILE_PCRE16
- case 0x2028: /* LINE SEPARATOR */
- case 0x2029: /* PARAGRAPH SEPARATOR */
+ VSPACE_BYTE_CASES:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ VSPACE_MULTIBYTE_CASES:
#endif
RRETURN(MATCH_NOMATCH);
+ default: break;
}
}
break;
@@ -4632,14 +4672,9 @@ for (;;)
switch(*eptr++)
{
default: RRETURN(MATCH_NOMATCH);
- case 0x0a: /* LF */
- case 0x0b: /* VT */
- case 0x0c: /* FF */
- case 0x0d: /* CR */
- case 0x85: /* NEL */
-#ifdef COMPILE_PCRE16
- case 0x2028: /* LINE SEPARATOR */
- case 0x2029: /* PARAGRAPH SEPARATOR */
+ VSPACE_BYTE_CASES:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ VSPACE_MULTIBYTE_CASES:
#endif
break;
}
@@ -4917,8 +4952,31 @@ for (;;)
}
/* Control never gets here */
- /* This should never occur */
+ case PT_CLIST:
+ for (fi = min;; fi++)
+ {
+ const pcre_uint32 *cp;
+ RMATCH(eptr, ecode, offset_top, md, eptrb, RM67);
+ if (rrc != MATCH_NOMATCH) RRETURN(rrc);
+ if (fi >= max) RRETURN(MATCH_NOMATCH);
+ if (eptr >= md->end_subject)
+ {
+ SCHECK_PARTIAL();
+ RRETURN(MATCH_NOMATCH);
+ }
+ GETCHARINCTEST(c, eptr);
+ cp = PRIV(ucd_caseless_sets) + prop_value;
+ for (;;)
+ {
+ if (c < *cp)
+ { if (prop_fail_result) break; else { RRETURN(MATCH_NOMATCH); } }
+ if (c == *cp++)
+ { if (prop_fail_result) { RRETURN(MATCH_NOMATCH); } else break; }
+ }
+ }
+ /* Control never gets here */
+ /* This should never occur */
default:
RRETURN(PCRE_ERROR_INTERNAL);
}
@@ -4939,15 +4997,22 @@ for (;;)
SCHECK_PARTIAL();
RRETURN(MATCH_NOMATCH);
}
- GETCHARINCTEST(c, eptr);
- if (UCD_CATEGORY(c) == ucp_M) RRETURN(MATCH_NOMATCH);
- while (eptr < md->end_subject)
+ else
{
- int len = 1;
- if (!utf) c = *eptr; else { GETCHARLEN(c, eptr, len); }
- if (UCD_CATEGORY(c) != ucp_M) break;
- eptr += len;
+ int lgb, rgb;
+ GETCHARINCTEST(c, eptr);
+ lgb = UCD_GRAPHBREAK(c);
+ while (eptr < md->end_subject)
+ {
+ int len = 1;
+ if (!utf) c = *eptr; else { GETCHARLEN(c, eptr, len); }
+ rgb = UCD_GRAPHBREAK(c);
+ if ((PRIV(ucp_gbtable)[lgb] & (1 << rgb)) == 0) break;
+ lgb = rgb;
+ eptr += len;
+ }
}
+ CHECK_PARTIAL();
}
}
else
@@ -4971,7 +5036,18 @@ for (;;)
GETCHARINC(c, eptr);
switch(ctype)
{
- case OP_ANY: /* This is the non-NL case */
+ case OP_ANY: /* This is the non-NL case */
+ if (md->partial != 0 && /* Take care with CRLF partial */
+ eptr >= md->end_subject &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ c == NLBLOCK->nl[0])
+ {
+ md->hitend = TRUE;
+ if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
+ }
+ break;
+
case OP_ALLANY:
case OP_ANYBYTE:
break;
@@ -4980,17 +5056,20 @@ for (;;)
switch(c)
{
default: RRETURN(MATCH_NOMATCH);
- case 0x000d:
- if (eptr < md->end_subject && *eptr == 0x0a) eptr++;
+ case CHAR_CR:
+ if (eptr < md->end_subject && RAWUCHAR(eptr) == CHAR_LF) eptr++;
break;
- case 0x000a:
+
+ case CHAR_LF:
break;
- case 0x000b:
- case 0x000c:
- case 0x0085:
+ case CHAR_VT:
+ case CHAR_FF:
+ case CHAR_NEL:
+#ifndef EBCDIC
case 0x2028:
case 0x2029:
+#endif /* Not EBCDIC */
if (md->bsr_anycrlf) RRETURN(MATCH_NOMATCH);
break;
}
@@ -4999,84 +5078,32 @@ for (;;)
case OP_NOT_HSPACE:
switch(c)
{
+ HSPACE_CASES: RRETURN(MATCH_NOMATCH);
default: break;
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
- RRETURN(MATCH_NOMATCH);
}
break;
case OP_HSPACE:
switch(c)
{
+ HSPACE_CASES: break;
default: RRETURN(MATCH_NOMATCH);
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
- break;
}
break;
case OP_NOT_VSPACE:
switch(c)
{
+ VSPACE_CASES: RRETURN(MATCH_NOMATCH);
default: break;
- case 0x0a: /* LF */
- case 0x0b: /* VT */
- case 0x0c: /* FF */
- case 0x0d: /* CR */
- case 0x85: /* NEL */
- case 0x2028: /* LINE SEPARATOR */
- case 0x2029: /* PARAGRAPH SEPARATOR */
- RRETURN(MATCH_NOMATCH);
}
break;
case OP_VSPACE:
switch(c)
{
+ VSPACE_CASES: break;
default: RRETURN(MATCH_NOMATCH);
- case 0x0a: /* LF */
- case 0x0b: /* VT */
- case 0x0c: /* FF */
- case 0x0d: /* CR */
- case 0x85: /* NEL */
- case 0x2028: /* LINE SEPARATOR */
- case 0x2029: /* PARAGRAPH SEPARATOR */
- break;
}
break;
@@ -5134,7 +5161,18 @@ for (;;)
c = *eptr++;
switch(ctype)
{
- case OP_ANY: /* This is the non-NL case */
+ case OP_ANY: /* This is the non-NL case */
+ if (md->partial != 0 && /* Take care with CRLF partial */
+ eptr >= md->end_subject &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ c == NLBLOCK->nl[0])
+ {
+ md->hitend = TRUE;
+ if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
+ }
+ break;
+
case OP_ALLANY:
case OP_ANYBYTE:
break;
@@ -5143,17 +5181,17 @@ for (;;)
switch(c)
{
default: RRETURN(MATCH_NOMATCH);
- case 0x000d:
- if (eptr < md->end_subject && *eptr == 0x0a) eptr++;
+ case CHAR_CR:
+ if (eptr < md->end_subject && *eptr == CHAR_LF) eptr++;
break;
- case 0x000a:
+ case CHAR_LF:
break;
- case 0x000b:
- case 0x000c:
- case 0x0085:
-#ifdef COMPILE_PCRE16
+ case CHAR_VT:
+ case CHAR_FF:
+ case CHAR_NEL:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
case 0x2028:
case 0x2029:
#endif
@@ -5166,26 +5204,9 @@ for (;;)
switch(c)
{
default: break;
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
-#ifdef COMPILE_PCRE16
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
+ HSPACE_BYTE_CASES:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ HSPACE_MULTIBYTE_CASES:
#endif
RRETURN(MATCH_NOMATCH);
}
@@ -5195,26 +5216,9 @@ for (;;)
switch(c)
{
default: RRETURN(MATCH_NOMATCH);
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
-#ifdef COMPILE_PCRE16
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
+ HSPACE_BYTE_CASES:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ HSPACE_MULTIBYTE_CASES:
#endif
break;
}
@@ -5224,14 +5228,9 @@ for (;;)
switch(c)
{
default: break;
- case 0x0a: /* LF */
- case 0x0b: /* VT */
- case 0x0c: /* FF */
- case 0x0d: /* CR */
- case 0x85: /* NEL */
-#ifdef COMPILE_PCRE16
- case 0x2028: /* LINE SEPARATOR */
- case 0x2029: /* PARAGRAPH SEPARATOR */
+ VSPACE_BYTE_CASES:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ VSPACE_MULTIBYTE_CASES:
#endif
RRETURN(MATCH_NOMATCH);
}
@@ -5241,14 +5240,9 @@ for (;;)
switch(c)
{
default: RRETURN(MATCH_NOMATCH);
- case 0x0a: /* LF */
- case 0x0b: /* VT */
- case 0x0c: /* FF */
- case 0x0d: /* CR */
- case 0x85: /* NEL */
-#ifdef COMPILE_PCRE16
- case 0x2028: /* LINE SEPARATOR */
- case 0x2029: /* PARAGRAPH SEPARATOR */
+ VSPACE_BYTE_CASES:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ VSPACE_MULTIBYTE_CASES:
#endif
break;
}
@@ -5452,6 +5446,30 @@ for (;;)
}
break;
+ case PT_CLIST:
+ for (i = min; i < max; i++)
+ {
+ const pcre_uint32 *cp;
+ int len = 1;
+ if (eptr >= md->end_subject)
+ {
+ SCHECK_PARTIAL();
+ break;
+ }
+ GETCHARLENTEST(c, eptr, len);
+ cp = PRIV(ucd_caseless_sets) + prop_value;
+ for (;;)
+ {
+ if (c < *cp)
+ { if (prop_fail_result) break; else goto GOT_MAX; }
+ if (c == *cp++)
+ { if (prop_fail_result) goto GOT_MAX; else break; }
+ }
+ eptr += len;
+ }
+ GOT_MAX:
+ break;
+
default:
RRETURN(PCRE_ERROR_INTERNAL);
}
@@ -5475,22 +5493,27 @@ for (;;)
{
for (i = min; i < max; i++)
{
- int len = 1;
if (eptr >= md->end_subject)
{
SCHECK_PARTIAL();
break;
}
- if (!utf) c = *eptr; else { GETCHARLEN(c, eptr, len); }
- if (UCD_CATEGORY(c) == ucp_M) break;
- eptr += len;
- while (eptr < md->end_subject)
+ else
{
- len = 1;
- if (!utf) c = *eptr; else { GETCHARLEN(c, eptr, len); }
- if (UCD_CATEGORY(c) != ucp_M) break;
- eptr += len;
+ int lgb, rgb;
+ GETCHARINCTEST(c, eptr);
+ lgb = UCD_GRAPHBREAK(c);
+ while (eptr < md->end_subject)
+ {
+ int len = 1;
+ if (!utf) c = *eptr; else { GETCHARLEN(c, eptr, len); }
+ rgb = UCD_GRAPHBREAK(c);
+ if ((PRIV(ucp_gbtable)[lgb] & (1 << rgb)) == 0) break;
+ lgb = rgb;
+ eptr += len;
+ }
}
+ CHECK_PARTIAL();
}
/* eptr is now past the end of the maximum run */
@@ -5534,6 +5557,15 @@ for (;;)
break;
}
if (IS_NEWLINE(eptr)) break;
+ if (md->partial != 0 && /* Take care with CRLF partial */
+ eptr + 1 >= md->end_subject &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ RAWUCHAR(eptr) == NLBLOCK->nl[0])
+ {
+ md->hitend = TRUE;
+ if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
+ }
eptr++;
ACROSSCHAR(eptr < md->end_subject, *eptr, eptr++);
}
@@ -5551,6 +5583,15 @@ for (;;)
break;
}
if (IS_NEWLINE(eptr)) break;
+ if (md->partial != 0 && /* Take care with CRLF partial */
+ eptr + 1 >= md->end_subject &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ RAWUCHAR(eptr) == NLBLOCK->nl[0])
+ {
+ md->hitend = TRUE;
+ if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
+ }
eptr++;
ACROSSCHAR(eptr < md->end_subject, *eptr, eptr++);
}
@@ -5600,17 +5641,20 @@ for (;;)
break;
}
GETCHARLEN(c, eptr, len);
- if (c == 0x000d)
+ if (c == CHAR_CR)
{
if (++eptr >= md->end_subject) break;
- if (*eptr == 0x000a) eptr++;
+ if (RAWUCHAR(eptr) == CHAR_LF) eptr++;
}
else
{
- if (c != 0x000a &&
+ if (c != CHAR_LF &&
(md->bsr_anycrlf ||
- (c != 0x000b && c != 0x000c &&
- c != 0x0085 && c != 0x2028 && c != 0x2029)))
+ (c != CHAR_VT && c != CHAR_FF && c != CHAR_NEL
+#ifndef EBCDIC
+ && c != 0x2028 && c != 0x2029
+#endif /* Not EBCDIC */
+ )))
break;
eptr += len;
}
@@ -5631,28 +5675,8 @@ for (;;)
GETCHARLEN(c, eptr, len);
switch(c)
{
+ HSPACE_CASES: gotspace = TRUE; break;
default: gotspace = FALSE; break;
- case 0x09: /* HT */
- case 0x20: /* SPACE */
- case 0xa0: /* NBSP */
- case 0x1680: /* OGHAM SPACE MARK */
- case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */
- case 0x2000: /* EN QUAD */
- case 0x2001: /* EM QUAD */
- case 0x2002: /* EN SPACE */
- case 0x2003: /* EM SPACE */
- case 0x2004: /* THREE-PER-EM SPACE */
- case 0x2005: /* FOUR-PER-EM SPACE */
- case 0x2006: /* SIX-PER-EM SPACE */
- case 0x2007: /* FIGURE SPACE */
- case 0x2008: /* PUNCTUATION SPACE */
- case 0x2009: /* THIN SPACE */
- case 0x200A: /* HAIR SPACE */
- case 0x202f: /* NARROW NO-BREAK SPACE */
- case 0x205f: /* MEDIUM MATHEMATICAL SPACE */
- case 0x3000: /* IDEOGRAPHIC SPACE */
- gotspace = TRUE;
- break;
}
if (gotspace == (ctype == OP_NOT_HSPACE)) break;
eptr += len;
@@ -5673,16 +5697,8 @@ for (;;)
GETCHARLEN(c, eptr, len);
switch(c)
{
+ VSPACE_CASES: gotspace = TRUE; break;
default: gotspace = FALSE; break;
- case 0x0a: /* LF */
- case 0x0b: /* VT */
- case 0x0c: /* FF */
- case 0x0d: /* CR */
- case 0x85: /* NEL */
- case 0x2028: /* LINE SEPARATOR */
- case 0x2029: /* PARAGRAPH SEPARATOR */
- gotspace = TRUE;
- break;
}
if (gotspace == (ctype == OP_NOT_VSPACE)) break;
eptr += len;
@@ -5796,8 +5812,8 @@ for (;;)
if (rrc != MATCH_NOMATCH) RRETURN(rrc);
if (eptr-- == pp) break; /* Stop if tried at original pos */
BACKCHAR(eptr);
- if (ctype == OP_ANYNL && eptr > pp && *eptr == '\n' &&
- eptr[-1] == '\r') eptr--;
+ if (ctype == OP_ANYNL && eptr > pp && RAWUCHAR(eptr) == CHAR_NL &&
+ RAWUCHAR(eptr - 1) == CHAR_CR) eptr--;
}
}
else
@@ -5815,6 +5831,15 @@ for (;;)
break;
}
if (IS_NEWLINE(eptr)) break;
+ if (md->partial != 0 && /* Take care with CRLF partial */
+ eptr + 1 >= md->end_subject &&
+ NLBLOCK->nltype == NLTYPE_FIXED &&
+ NLBLOCK->nllen == 2 &&
+ *eptr == NLBLOCK->nl[0])
+ {
+ md->hitend = TRUE;
+ if (md->partial > 1) RRETURN(PCRE_ERROR_PARTIAL);
+ }
eptr++;
}
break;
@@ -5839,19 +5864,19 @@ for (;;)
break;
}
c = *eptr;
- if (c == 0x000d)
+ if (c == CHAR_CR)
{
if (++eptr >= md->end_subject) break;
- if (*eptr == 0x000a) eptr++;
+ if (*eptr == CHAR_LF) eptr++;
}
else
{
- if (c != 0x000a && (md->bsr_anycrlf ||
- (c != 0x000b && c != 0x000c && c != 0x0085
-#ifdef COMPILE_PCRE16
- && c != 0x2028 && c != 0x2029
+ if (c != CHAR_LF && (md->bsr_anycrlf ||
+ (c != CHAR_VT && c != CHAR_FF && c != CHAR_NEL
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ && c != 0x2028 && c != 0x2029
#endif
- ))) break;
+ ))) break;
eptr++;
}
}
@@ -5865,15 +5890,17 @@ for (;;)
SCHECK_PARTIAL();
break;
}
- c = *eptr;
- if (c == 0x09 || c == 0x20 || c == 0xa0
-#ifdef COMPILE_PCRE16
- || c == 0x1680 || c == 0x180e || (c >= 0x2000 && c <= 0x200A)
- || c == 0x202f || c == 0x205f || c == 0x3000
+ switch(*eptr)
+ {
+ default: eptr++; break;
+ HSPACE_BYTE_CASES:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ HSPACE_MULTIBYTE_CASES:
#endif
- ) break;
- eptr++;
+ goto ENDLOOP00;
+ }
}
+ ENDLOOP00:
break;
case OP_HSPACE:
@@ -5884,15 +5911,17 @@ for (;;)
SCHECK_PARTIAL();
break;
}
- c = *eptr;
- if (c != 0x09 && c != 0x20 && c != 0xa0
-#ifdef COMPILE_PCRE16
- && c != 0x1680 && c != 0x180e && (c < 0x2000 || c > 0x200A)
- && c != 0x202f && c != 0x205f && c != 0x3000
+ switch(*eptr)
+ {
+ default: goto ENDLOOP01;
+ HSPACE_BYTE_CASES:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ HSPACE_MULTIBYTE_CASES:
#endif
- ) break;
- eptr++;
+ eptr++; break;
+ }
}
+ ENDLOOP01:
break;
case OP_NOT_VSPACE:
@@ -5903,14 +5932,17 @@ for (;;)
SCHECK_PARTIAL();
break;
}
- c = *eptr;
- if (c == 0x0a || c == 0x0b || c == 0x0c || c == 0x0d || c == 0x85
-#ifdef COMPILE_PCRE16
- || c == 0x2028 || c == 0x2029
+ switch(*eptr)
+ {
+ default: eptr++; break;
+ VSPACE_BYTE_CASES:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ VSPACE_MULTIBYTE_CASES:
#endif
- ) break;
- eptr++;
+ goto ENDLOOP02;
+ }
}
+ ENDLOOP02:
break;
case OP_VSPACE:
@@ -5921,14 +5953,17 @@ for (;;)
SCHECK_PARTIAL();
break;
}
- c = *eptr;
- if (c != 0x0a && c != 0x0b && c != 0x0c && c != 0x0d && c != 0x85
-#ifdef COMPILE_PCRE16
- && c != 0x2028 && c != 0x2029
+ switch(*eptr)
+ {
+ default: goto ENDLOOP03;
+ VSPACE_BYTE_CASES:
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ VSPACE_MULTIBYTE_CASES:
#endif
- ) break;
- eptr++;
+ eptr++; break;
+ }
}
+ ENDLOOP03:
break;
case OP_NOT_DIGIT:
@@ -6025,8 +6060,8 @@ for (;;)
RMATCH(eptr, ecode, offset_top, md, eptrb, RM47);
if (rrc != MATCH_NOMATCH) RRETURN(rrc);
eptr--;
- if (ctype == OP_ANYNL && eptr > pp && *eptr == '\n' &&
- eptr[-1] == '\r') eptr--;
+ if (ctype == OP_ANYNL && eptr > pp && *eptr == CHAR_LF &&
+ eptr[-1] == CHAR_CR) eptr--;
}
}
@@ -6076,14 +6111,11 @@ switch (frame->Xwhere)
LBL(32) LBL(34) LBL(42) LBL(46)
#ifdef SUPPORT_UCP
LBL(36) LBL(37) LBL(38) LBL(39) LBL(40) LBL(41) LBL(44) LBL(45)
- LBL(59) LBL(60) LBL(61) LBL(62)
+ LBL(59) LBL(60) LBL(61) LBL(62) LBL(67)
#endif /* SUPPORT_UCP */
#endif /* SUPPORT_UTF */
default:
DPRINTF(("jump error in pcre match: label %d non-existent\n", frame->Xwhere));
-
-printf("+++jump error in pcre match: label %d non-existent\n", frame->Xwhere);
-
return PCRE_ERROR_INTERNAL;
}
#undef LBL
@@ -6145,6 +6177,31 @@ Undefine all the macros that were defined above to handle this. */
***************************************************************************/
+#ifdef NO_RECURSE
+/*************************************************
+* Release allocated heap frames *
+*************************************************/
+
+/* This function releases all the allocated frames. The base frame is on the
+machine stack, and so must not be freed.
+
+Argument: the address of the base frame
+Returns: nothing
+*/
+
+static void
+release_match_heapframes (heapframe *frame_base)
+{
+heapframe *nextframe = frame_base->Xnextframe;
+while (nextframe != NULL)
+ {
+ heapframe *oldframe = nextframe;
+ nextframe = nextframe->Xnextframe;
+ (PUBL(stack_free))(oldframe);
+ }
+}
+#endif
+
/*************************************************
* Execute a Regular Expression *
@@ -6170,16 +6227,21 @@ Returns: > 0 => success; value is the number of elements filled in
< -1 => some kind of unexpected problem
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre_exec(const pcre *argument_re, const pcre_extra *extra_data,
PCRE_SPTR subject, int length, int start_offset, int options, int *offsets,
int offsetcount)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre16_exec(const pcre16 *argument_re, const pcre16_extra *extra_data,
PCRE_SPTR16 subject, int length, int start_offset, int options, int *offsets,
int offsetcount)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_exec(const pcre32 *argument_re, const pcre32_extra *extra_data,
+ PCRE_SPTR32 subject, int length, int start_offset, int options, int *offsets,
+ int offsetcount)
#endif
{
int rc, ocount, arg_offset_max;
@@ -6207,13 +6269,22 @@ PCRE_PUCHAR req_char_ptr = start_match - 1;
const pcre_study_data *study;
const REAL_PCRE *re = (const REAL_PCRE *)argument_re;
+#ifdef NO_RECURSE
+heapframe frame_zero;
+frame_zero.Xprevframe = NULL; /* Marks the top level */
+frame_zero.Xnextframe = NULL; /* None are allocated yet */
+md->match_frames_base = &frame_zero;
+#endif
+
/* Check for the special magic call that measures the size of the stack used
-per recursive call of match(). */
+per recursive call of match(). Without the funny casting for sizeof, a Windows
+compiler gave this error: "unary minus operator applied to unsigned type,
+result still unsigned". Hopefully the cast fixes that. */
if (re == NULL && extra_data == NULL && subject == NULL && length == -999 &&
start_offset == -999)
#ifdef NO_RECURSE
- return -sizeof(heapframe);
+ return -((int)sizeof(heapframe));
#else
return match(NULL, NULL, NULL, 0, NULL, NULL, 0);
#endif
@@ -6224,6 +6295,7 @@ if ((options & ~PUBLIC_EXEC_OPTIONS) != 0) return PCRE_ERROR_BADOPTION;
if (re == NULL || subject == NULL || (offsets == NULL && offsetcount > 0))
return PCRE_ERROR_NULL;
if (offsetcount < 0) return PCRE_ERROR_BADCOUNT;
+if (length < 0) return PCRE_ERROR_BADLENGTH;
if (start_offset < 0 || start_offset > length) return PCRE_ERROR_BADOFFSET;
/* Check that the first field in the block is the magic number. If it is not,
@@ -6261,39 +6333,45 @@ if (utf && (options & PCRE_NO_UTF8_CHECK) == 0)
offsets[0] = erroroffset;
offsets[1] = errorcode;
}
-#ifdef COMPILE_PCRE16
- return (errorcode <= PCRE_UTF16_ERR1 && md->partial > 1)?
- PCRE_ERROR_SHORTUTF16 : PCRE_ERROR_BADUTF16;
-#else
+#if defined COMPILE_PCRE8
return (errorcode <= PCRE_UTF8_ERR5 && md->partial > 1)?
PCRE_ERROR_SHORTUTF8 : PCRE_ERROR_BADUTF8;
+#elif defined COMPILE_PCRE16
+ return (errorcode <= PCRE_UTF16_ERR1 && md->partial > 1)?
+ PCRE_ERROR_SHORTUTF16 : PCRE_ERROR_BADUTF16;
+#elif defined COMPILE_PCRE32
+ return PCRE_ERROR_BADUTF32;
#endif
}
-
+#if defined COMPILE_PCRE8 || defined COMPILE_PCRE16
/* Check that a start_offset points to the start of a UTF character. */
if (start_offset > 0 && start_offset < length &&
NOT_FIRSTCHAR(((PCRE_PUCHAR)subject)[start_offset]))
return PCRE_ERROR_BADUTF8_OFFSET;
+#endif
}
#endif
/* If the pattern was successfully studied with JIT support, run the JIT
executable instead of the rest of this function. Most options must be set at
compile time for the JIT code to be usable. Fallback to the normal code path if
-an unsupported flag is set. In particular, JIT does not support partial
-matching. */
+an unsupported flag is set. */
#ifdef SUPPORT_JIT
if (extra_data != NULL
- && (extra_data->flags & PCRE_EXTRA_EXECUTABLE_JIT) != 0
+ && (extra_data->flags & (PCRE_EXTRA_EXECUTABLE_JIT |
+ PCRE_EXTRA_TABLES)) == PCRE_EXTRA_EXECUTABLE_JIT
&& extra_data->executable_jit != NULL
- && (extra_data->flags & PCRE_EXTRA_TABLES) == 0
- && (options & ~(PCRE_NO_UTF8_CHECK | PCRE_NOTBOL | PCRE_NOTEOL |
- PCRE_NOTEMPTY | PCRE_NOTEMPTY_ATSTART)) == 0)
- return PRIV(jit_exec)(re, extra_data->executable_jit,
- (const pcre_uchar *)subject, length, start_offset, options,
- ((extra_data->flags & PCRE_EXTRA_MATCH_LIMIT) == 0)
- ? MATCH_LIMIT : extra_data->match_limit, offsets, offsetcount);
+ && (options & ~PUBLIC_JIT_EXEC_OPTIONS) == 0)
+ {
+ rc = PRIV(jit_exec)(extra_data, (const pcre_uchar *)subject, length,
+ start_offset, options, offsets, offsetcount);
+
+ /* PCRE_ERROR_NULL means that the selected normal or partial matching
+ mode is not compiled. In this case we simply fallback to interpreter. */
+
+ if (rc != PCRE_ERROR_JIT_BADOPTION) return rc;
+ }
#endif
/* Carry on with non-JIT matching. This information is for finding all the
@@ -6576,12 +6654,14 @@ for(;;)
if (has_first_char)
{
+ pcre_uchar smc;
+
if (first_char != first_char2)
while (start_match < end_subject &&
- *start_match != first_char && *start_match != first_char2)
+ (smc = RAWUCHARTEST(start_match)) != first_char && smc != first_char2)
start_match++;
else
- while (start_match < end_subject && *start_match != first_char)
+ while (start_match < end_subject && RAWUCHARTEST(start_match) != first_char)
start_match++;
}
@@ -6613,7 +6693,7 @@ for(;;)
if (start_match[-1] == CHAR_CR &&
(md->nltype == NLTYPE_ANY || md->nltype == NLTYPE_ANYCRLF) &&
start_match < end_subject &&
- *start_match == CHAR_NL)
+ RAWUCHARTEST(start_match) == CHAR_NL)
start_match++;
}
}
@@ -6624,7 +6704,7 @@ for(;;)
{
while (start_match < end_subject)
{
- register unsigned int c = *start_match;
+ register pcre_uint32 c = RAWUCHARTEST(start_match);
#ifndef COMPILE_PCRE8
if (c > 255) c = 255;
#endif
@@ -6692,7 +6772,7 @@ for(;;)
{
while (p < end_subject)
{
- register int pp = *p++;
+ register pcre_uint32 pp = RAWUCHARINCTEST(p);
if (pp == req_char || pp == req_char2) { p--; break; }
}
}
@@ -6700,7 +6780,7 @@ for(;;)
{
while (p < end_subject)
{
- if (*p++ == req_char) { p--; break; }
+ if (RAWUCHARINCTEST(p) == req_char) { p--; break; }
}
}
@@ -6887,7 +6967,7 @@ if (rc == MATCH_MATCH || rc == MATCH_ACCEPT)
{
register int *iptr, *iend;
int resetcount = 2 + re->top_bracket * 2;
- if (resetcount > offsetcount) resetcount = ocount;
+ if (resetcount > offsetcount) resetcount = offsetcount;
iptr = offsets + md->end_offset_top;
iend = offsets + resetcount;
while (iptr < iend) *iptr++ = -1;
@@ -6908,6 +6988,9 @@ if (rc == MATCH_MATCH || rc == MATCH_ACCEPT)
if (extra_data != NULL && (extra_data->flags & PCRE_EXTRA_MARK) != 0)
*(extra_data->mark) = (pcre_uchar *)md->mark;
DPRINTF((">>>> returning %d\n", rc));
+#ifdef NO_RECURSE
+ release_match_heapframes(&frame_zero);
+#endif
return rc;
}
@@ -6925,6 +7008,9 @@ if (using_temporary_offsets)
if (rc != MATCH_NOMATCH && rc != PCRE_ERROR_PARTIAL)
{
DPRINTF((">>>> error: returning %d\n", rc));
+#ifdef NO_RECURSE
+ release_match_heapframes(&frame_zero);
+#endif
return rc;
}
@@ -6954,6 +7040,9 @@ else
if (extra_data != NULL && (extra_data->flags & PCRE_EXTRA_MARK) != 0)
*(extra_data->mark) = (pcre_uchar *)md->nomatch_mark;
+#ifdef NO_RECURSE
+ release_match_heapframes(&frame_zero);
+#endif
return rc;
}
diff --git a/src/3rdparty/pcre/pcre_fullinfo.c b/src/3rdparty/pcre/pcre_fullinfo.c
index e5e68f3f29..e64da06eb4 100644
--- a/src/3rdparty/pcre/pcre_fullinfo.c
+++ b/src/3rdparty/pcre/pcre_fullinfo.c
@@ -65,14 +65,18 @@ Arguments:
Returns: 0 if data returned, negative on error
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre_fullinfo(const pcre *argument_re, const pcre_extra *extra_data,
int what, void *where)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre16_fullinfo(const pcre16 *argument_re, const pcre16_extra *extra_data,
int what, void *where)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_fullinfo(const pcre32 *argument_re, const pcre32_extra *extra_data,
+ int what, void *where)
#endif
{
const REAL_PCRE *re = (const REAL_PCRE *)argument_re;
@@ -132,10 +136,21 @@ switch (what)
case PCRE_INFO_FIRSTBYTE:
*((int *)where) =
- ((re->flags & PCRE_FIRSTSET) != 0)? re->first_char :
+ ((re->flags & PCRE_FIRSTSET) != 0)? (int)re->first_char :
((re->flags & PCRE_STARTLINE) != 0)? -1 : -2;
break;
+ case PCRE_INFO_FIRSTCHARACTER:
+ *((pcre_uint32 *)where) =
+ (re->flags & PCRE_FIRSTSET) != 0 ? re->first_char : 0;
+ break;
+
+ case PCRE_INFO_FIRSTCHARACTERFLAGS:
+ *((int *)where) =
+ ((re->flags & PCRE_FIRSTSET) != 0) ? 1 :
+ ((re->flags & PCRE_STARTLINE) != 0) ? 2 : 0;
+ break;
+
/* Make sure we pass back the pointer to the bit vector in the external
block, not the internal copy (with flipped integer fields). */
@@ -159,9 +174,19 @@ switch (what)
case PCRE_INFO_LASTLITERAL:
*((int *)where) =
- ((re->flags & PCRE_REQCHSET) != 0)? re->req_char : -1;
+ ((re->flags & PCRE_REQCHSET) != 0)? (int)re->req_char : -1;
break;
+ case PCRE_INFO_REQUIREDCHAR:
+ *((pcre_uint32 *)where) =
+ ((re->flags & PCRE_REQCHSET) != 0) ? re->req_char : 0;
+ break;
+
+ case PCRE_INFO_REQUIREDCHARFLAGS:
+ *((int *)where) =
+ ((re->flags & PCRE_REQCHSET) != 0);
+ break;
+
case PCRE_INFO_NAMEENTRYSIZE:
*((int *)where) = re->name_entry_size;
break;
@@ -193,6 +218,10 @@ switch (what)
*((int *)where) = (re->flags & PCRE_HASCRORLF) != 0;
break;
+ case PCRE_INFO_MAXLOOKBEHIND:
+ *((int *)where) = re->max_lookbehind;
+ break;
+
default: return PCRE_ERROR_BADOPTION;
}
diff --git a/src/3rdparty/pcre/pcre_get.c b/src/3rdparty/pcre/pcre_get.c
index daecb695fe..6f885ac07d 100644
--- a/src/3rdparty/pcre/pcre_get.c
+++ b/src/3rdparty/pcre/pcre_get.c
@@ -65,12 +65,15 @@ Returns: the number of the named parentheses, or a negative number
(PCRE_ERROR_NOSUBSTRING) if not found
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre_get_stringnumber(const pcre *code, const char *stringname)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre16_get_stringnumber(const pcre16 *code, PCRE_SPTR16 stringname)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_get_stringnumber(const pcre32 *code, PCRE_SPTR32 stringname)
#endif
{
int rc;
@@ -98,6 +101,16 @@ if ((rc = pcre16_fullinfo(code, NULL, PCRE_INFO_NAMEENTRYSIZE, &entrysize)) != 0
if ((rc = pcre16_fullinfo(code, NULL, PCRE_INFO_NAMETABLE, &nametable)) != 0)
return rc;
#endif
+#ifdef COMPILE_PCRE32
+if ((rc = pcre32_fullinfo(code, NULL, PCRE_INFO_NAMECOUNT, &top)) != 0)
+ return rc;
+if (top <= 0) return PCRE_ERROR_NOSUBSTRING;
+
+if ((rc = pcre32_fullinfo(code, NULL, PCRE_INFO_NAMEENTRYSIZE, &entrysize)) != 0)
+ return rc;
+if ((rc = pcre32_fullinfo(code, NULL, PCRE_INFO_NAMETABLE, &nametable)) != 0)
+ return rc;
+#endif
bot = 0;
while (top > bot)
@@ -132,14 +145,18 @@ Returns: the length of each entry, or a negative number
(PCRE_ERROR_NOSUBSTRING) if not found
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre_get_stringtable_entries(const pcre *code, const char *stringname,
char **firstptr, char **lastptr)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre16_get_stringtable_entries(const pcre16 *code, PCRE_SPTR16 stringname,
PCRE_UCHAR16 **firstptr, PCRE_UCHAR16 **lastptr)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_get_stringtable_entries(const pcre32 *code, PCRE_SPTR32 stringname,
+ PCRE_UCHAR32 **firstptr, PCRE_UCHAR32 **lastptr)
#endif
{
int rc;
@@ -167,6 +184,16 @@ if ((rc = pcre16_fullinfo(code, NULL, PCRE_INFO_NAMEENTRYSIZE, &entrysize)) != 0
if ((rc = pcre16_fullinfo(code, NULL, PCRE_INFO_NAMETABLE, &nametable)) != 0)
return rc;
#endif
+#ifdef COMPILE_PCRE32
+if ((rc = pcre32_fullinfo(code, NULL, PCRE_INFO_NAMECOUNT, &top)) != 0)
+ return rc;
+if (top <= 0) return PCRE_ERROR_NOSUBSTRING;
+
+if ((rc = pcre32_fullinfo(code, NULL, PCRE_INFO_NAMEENTRYSIZE, &entrysize)) != 0)
+ return rc;
+if ((rc = pcre32_fullinfo(code, NULL, PCRE_INFO_NAMETABLE, &nametable)) != 0)
+ return rc;
+#endif
lastentry = nametable + entrysize * (top - 1);
bot = 0;
@@ -192,12 +219,15 @@ while (top > bot)
(pcre_uchar *)(last + entrysize + IMM2_SIZE)) != 0) break;
last += entrysize;
}
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
*firstptr = (char *)first;
*lastptr = (char *)last;
-#else
+#elif defined COMPILE_PCRE16
*firstptr = (PCRE_UCHAR16 *)first;
*lastptr = (PCRE_UCHAR16 *)last;
+#elif defined COMPILE_PCRE32
+ *firstptr = (PCRE_UCHAR32 *)first;
+ *lastptr = (PCRE_UCHAR32 *)last;
#endif
return entrysize;
}
@@ -226,31 +256,40 @@ Returns: the number of the first that is set,
or a negative number on error
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
static int
get_first_set(const pcre *code, const char *stringname, int *ovector)
-#else
+#elif defined COMPILE_PCRE16
static int
get_first_set(const pcre16 *code, PCRE_SPTR16 stringname, int *ovector)
+#elif defined COMPILE_PCRE32
+static int
+get_first_set(const pcre32 *code, PCRE_SPTR32 stringname, int *ovector)
#endif
{
const REAL_PCRE *re = (const REAL_PCRE *)code;
int entrysize;
pcre_uchar *entry;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
char *first, *last;
-#else
+#elif defined COMPILE_PCRE16
PCRE_UCHAR16 *first, *last;
+#elif defined COMPILE_PCRE32
+PCRE_UCHAR32 *first, *last;
#endif
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
if ((re->options & PCRE_DUPNAMES) == 0 && (re->flags & PCRE_JCHANGED) == 0)
return pcre_get_stringnumber(code, stringname);
entrysize = pcre_get_stringtable_entries(code, stringname, &first, &last);
-#else
+#elif defined COMPILE_PCRE16
if ((re->options & PCRE_DUPNAMES) == 0 && (re->flags & PCRE_JCHANGED) == 0)
return pcre16_get_stringnumber(code, stringname);
entrysize = pcre16_get_stringtable_entries(code, stringname, &first, &last);
+#elif defined COMPILE_PCRE32
+if ((re->options & PCRE_DUPNAMES) == 0 && (re->flags & PCRE_JCHANGED) == 0)
+ return pcre32_get_stringnumber(code, stringname);
+entrysize = pcre32_get_stringtable_entries(code, stringname, &first, &last);
#endif
if (entrysize <= 0) return entrysize;
for (entry = (pcre_uchar *)first; entry <= (pcre_uchar *)last; entry += entrysize)
@@ -291,14 +330,18 @@ Returns: if successful:
PCRE_ERROR_NOSUBSTRING (-7) no such captured substring
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre_copy_substring(const char *subject, int *ovector, int stringcount,
int stringnumber, char *buffer, int size)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre16_copy_substring(PCRE_SPTR16 subject, int *ovector, int stringcount,
int stringnumber, PCRE_UCHAR16 *buffer, int size)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_copy_substring(PCRE_SPTR32 subject, int *ovector, int stringcount,
+ int stringnumber, PCRE_UCHAR32 *buffer, int size)
#endif
{
int yield;
@@ -342,24 +385,31 @@ Returns: if successful:
PCRE_ERROR_NOSUBSTRING (-7) no such captured substring
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre_copy_named_substring(const pcre *code, const char *subject,
int *ovector, int stringcount, const char *stringname,
char *buffer, int size)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre16_copy_named_substring(const pcre16 *code, PCRE_SPTR16 subject,
int *ovector, int stringcount, PCRE_SPTR16 stringname,
PCRE_UCHAR16 *buffer, int size)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_copy_named_substring(const pcre32 *code, PCRE_SPTR32 subject,
+ int *ovector, int stringcount, PCRE_SPTR32 stringname,
+ PCRE_UCHAR32 *buffer, int size)
#endif
{
int n = get_first_set(code, stringname, ovector);
if (n <= 0) return n;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
return pcre_copy_substring(subject, ovector, stringcount, n, buffer, size);
-#else
+#elif defined COMPILE_PCRE16
return pcre16_copy_substring(subject, ovector, stringcount, n, buffer, size);
+#elif defined COMPILE_PCRE32
+return pcre32_copy_substring(subject, ovector, stringcount, n, buffer, size);
#endif
}
@@ -386,14 +436,18 @@ Returns: if successful: 0
PCRE_ERROR_NOMEMORY (-6) failed to get store
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre_get_substring_list(const char *subject, int *ovector, int stringcount,
const char ***listptr)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre16_get_substring_list(PCRE_SPTR16 subject, int *ovector, int stringcount,
PCRE_SPTR16 **listptr)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_get_substring_list(PCRE_SPTR32 subject, int *ovector, int stringcount,
+ PCRE_SPTR32 **listptr)
#endif
{
int i;
@@ -408,10 +462,12 @@ for (i = 0; i < double_count; i += 2)
stringlist = (pcre_uchar **)(PUBL(malloc))(size);
if (stringlist == NULL) return PCRE_ERROR_NOMEMORY;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
*listptr = (const char **)stringlist;
-#else
+#elif defined COMPILE_PCRE16
*listptr = (PCRE_SPTR16 *)stringlist;
+#elif defined COMPILE_PCRE32
+*listptr = (PCRE_SPTR32 *)stringlist;
#endif
p = (pcre_uchar *)(stringlist + stringcount + 1);
@@ -442,12 +498,15 @@ Argument: the result of a previous pcre_get_substring_list()
Returns: nothing
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN void PCRE_CALL_CONVENTION
pcre_free_substring_list(const char **pointer)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN void PCRE_CALL_CONVENTION
pcre16_free_substring_list(PCRE_SPTR16 *pointer)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN void PCRE_CALL_CONVENTION
+pcre32_free_substring_list(PCRE_SPTR32 *pointer)
#endif
{
(PUBL(free))((void *)pointer);
@@ -480,14 +539,18 @@ Returns: if successful:
PCRE_ERROR_NOSUBSTRING (-7) substring not present
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre_get_substring(const char *subject, int *ovector, int stringcount,
int stringnumber, const char **stringptr)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre16_get_substring(PCRE_SPTR16 subject, int *ovector, int stringcount,
int stringnumber, PCRE_SPTR16 *stringptr)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_get_substring(PCRE_SPTR32 subject, int *ovector, int stringcount,
+ int stringnumber, PCRE_SPTR32 *stringptr)
#endif
{
int yield;
@@ -500,10 +563,12 @@ substring = (pcre_uchar *)(PUBL(malloc))(IN_UCHARS(yield + 1));
if (substring == NULL) return PCRE_ERROR_NOMEMORY;
memcpy(substring, subject + ovector[stringnumber], IN_UCHARS(yield));
substring[yield] = 0;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
*stringptr = (const char *)substring;
-#else
+#elif defined COMPILE_PCRE16
*stringptr = (PCRE_SPTR16)substring;
+#elif defined COMPILE_PCRE32
+*stringptr = (PCRE_SPTR32)substring;
#endif
return yield;
}
@@ -537,24 +602,31 @@ Returns: if successful:
PCRE_ERROR_NOSUBSTRING (-7) no such captured substring
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre_get_named_substring(const pcre *code, const char *subject,
int *ovector, int stringcount, const char *stringname,
const char **stringptr)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre16_get_named_substring(const pcre16 *code, PCRE_SPTR16 subject,
int *ovector, int stringcount, PCRE_SPTR16 stringname,
PCRE_SPTR16 *stringptr)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_get_named_substring(const pcre32 *code, PCRE_SPTR32 subject,
+ int *ovector, int stringcount, PCRE_SPTR32 stringname,
+ PCRE_SPTR32 *stringptr)
#endif
{
int n = get_first_set(code, stringname, ovector);
if (n <= 0) return n;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
return pcre_get_substring(subject, ovector, stringcount, n, stringptr);
-#else
+#elif defined COMPILE_PCRE16
return pcre16_get_substring(subject, ovector, stringcount, n, stringptr);
+#elif defined COMPILE_PCRE32
+return pcre32_get_substring(subject, ovector, stringcount, n, stringptr);
#endif
}
@@ -573,12 +645,15 @@ Argument: the result of a previous pcre_get_substring()
Returns: nothing
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN void PCRE_CALL_CONVENTION
pcre_free_substring(const char *pointer)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN void PCRE_CALL_CONVENTION
pcre16_free_substring(PCRE_SPTR16 pointer)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN void PCRE_CALL_CONVENTION
+pcre32_free_substring(PCRE_SPTR32 pointer)
#endif
{
(PUBL(free))((void *)pointer);
diff --git a/src/3rdparty/pcre/pcre_internal.h b/src/3rdparty/pcre/pcre_internal.h
index e5a4b6a526..f3cb001fea 100644
--- a/src/3rdparty/pcre/pcre_internal.h
+++ b/src/3rdparty/pcre/pcre_internal.h
@@ -40,8 +40,8 @@ POSSIBILITY OF SUCH DAMAGE.
/* This header contains definitions that are shared between the different
modules, but which are not relevant to the exported API. This includes some
-functions whose names all begin with "_pcre_" or "_pcre16_" depending on
-the PRIV macro. */
+functions whose names all begin with "_pcre_", "_pcre16_" or "_pcre32_"
+depending on the PRIV macro. */
#ifndef PCRE_INTERNAL_H
#define PCRE_INTERNAL_H
@@ -53,7 +53,8 @@ the PRIV macro. */
#endif
/* PCRE is compiled as an 8 bit library if it is not requested otherwise. */
-#ifndef COMPILE_PCRE16
+
+#if !defined COMPILE_PCRE16 && !defined COMPILE_PCRE32
#define COMPILE_PCRE8
#endif
@@ -78,11 +79,11 @@ Until then we define it if SUPPORT_UTF is defined. */
#define SUPPORT_UTF8 1
#endif
-/* We do not support both EBCDIC and UTF-8/16 at the same time. The "configure"
+/* We do not support both EBCDIC and UTF-8/16/32 at the same time. The "configure"
script prevents both being selected, but not everybody uses "configure". */
#if defined EBCDIC && defined SUPPORT_UTF
-#error The use of both EBCDIC and SUPPORT_UTF8/16 is not supported.
+#error The use of both EBCDIC and SUPPORT_UTF is not supported.
#endif
/* Use a macro for debugging printing, 'cause that eliminates the use of #ifdef
@@ -111,6 +112,12 @@ setjmp and stdarg are used is when NO_RECURSE is set. */
#include <stdlib.h>
#include <string.h>
+/* Valgrind (memcheck) support */
+
+#ifdef SUPPORT_VALGRIND
+#include <valgrind/memcheck.h>
+#endif
+
/* When compiling a DLL for Windows, the exported symbols have to be declared
using some MS magic. I found some useful information on this web page:
http://msdn2.microsoft.com/en-us/library/y4h7bcy6(VS.80).aspx. According to the
@@ -193,7 +200,7 @@ typedef unsigned char pcre_uint8;
typedef unsigned int pcre_uint16;
typedef int pcre_int16;
#else
- #error Cannot determine a type for 16-bit unsigned integers
+# error Cannot determine a type for 16-bit unsigned integers
#endif
#if UINT_MAX == 4294967295
@@ -203,7 +210,7 @@ typedef unsigned char pcre_uint8;
typedef unsigned long int pcre_uint32;
typedef long int pcre_int32;
#else
- #error Cannot determine a type for 32-bit unsigned integers
+# error Cannot determine a type for 32-bit unsigned integers
#endif
/* When checking for integer overflow in pcre_compile(), we need to handle
@@ -214,9 +221,9 @@ stdint.h is available, include it; it may define INT64_MAX. Systems that do not
have stdint.h (e.g. Solaris) may have inttypes.h. The macro int64_t may be set
by "configure". */
-#if HAVE_STDINT_H
+#if defined HAVE_STDINT_H
#include <stdint.h>
-#elif HAVE_INTTYPES_H
+#elif defined HAVE_INTTYPES_H
#include <inttypes.h>
#endif
@@ -243,16 +250,15 @@ exactly 256 items. When the character is able to contain more than 256
items, some check is needed before accessing these tables.
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
typedef unsigned char pcre_uchar;
#define IN_UCHARS(x) (x)
#define MAX_255(c) 1
#define TABLE_GET(c, table, default) ((table)[c])
-#else
+#elif defined COMPILE_PCRE16
-#ifdef COMPILE_PCRE16
#if USHRT_MAX != 65535
/* This is a warning message. Change PCRE_UCHAR16 to a 16 bit data type in
pcre.h(.in) and disable (comment out) this message. */
@@ -260,15 +266,22 @@ pcre.h(.in) and disable (comment out) this message. */
#endif
typedef pcre_uint16 pcre_uchar;
-#define IN_UCHARS(x) ((x) << 1)
+#define UCHAR_SHIFT (1)
+#define IN_UCHARS(x) ((x) << UCHAR_SHIFT)
+#define MAX_255(c) ((c) <= 255u)
+#define TABLE_GET(c, table, default) (MAX_255(c)? ((table)[c]):(default))
+
+#elif defined COMPILE_PCRE32
+
+typedef pcre_uint32 pcre_uchar;
+#define UCHAR_SHIFT (2)
+#define IN_UCHARS(x) ((x) << UCHAR_SHIFT)
#define MAX_255(c) ((c) <= 255u)
#define TABLE_GET(c, table, default) (MAX_255(c)? ((table)[c]):(default))
#else
#error Unsupported compiling mode
-#endif /* COMPILE_PCRE16 */
-
-#endif /* COMPILE_PCRE8 */
+#endif /* COMPILE_PCRE[8|16|32] */
/* This is an unsigned int value that no character can ever have. UTF-8
characters only go up to 0x7fffffff (though Unicode doesn't go beyond
@@ -295,8 +308,8 @@ start/end of string field names are. */
&(NLBLOCK->nllen), utf)) \
: \
((p) <= NLBLOCK->PSEND - NLBLOCK->nllen && \
- (p)[0] == NLBLOCK->nl[0] && \
- (NLBLOCK->nllen == 1 || (p)[1] == NLBLOCK->nl[1]) \
+ RAWUCHARTEST(p) == NLBLOCK->nl[0] && \
+ (NLBLOCK->nllen == 1 || RAWUCHARTEST(p+1) == NLBLOCK->nl[1]) \
) \
)
@@ -309,8 +322,8 @@ start/end of string field names are. */
&(NLBLOCK->nllen), utf)) \
: \
((p) >= NLBLOCK->PSSTART + NLBLOCK->nllen && \
- (p)[-NLBLOCK->nllen] == NLBLOCK->nl[0] && \
- (NLBLOCK->nllen == 1 || (p)[-NLBLOCK->nllen+1] == NLBLOCK->nl[1]) \
+ RAWUCHARTEST(p - NLBLOCK->nllen) == NLBLOCK->nl[0] && \
+ (NLBLOCK->nllen == 1 || RAWUCHARTEST(p - NLBLOCK->nllen + 1) == NLBLOCK->nl[1]) \
) \
)
@@ -335,6 +348,11 @@ values. */
#include "pcre.h"
#include "ucp.h"
+#ifdef COMPILE_PCRE32
+/* Assert that the public PCRE_UCHAR32 is a 32-bit type */
+typedef int __assert_pcre_uchar32_size[sizeof(PCRE_UCHAR32) == 4 ? 1 : -1];
+#endif
+
/* When compiling for use with the Virtual Pascal compiler, these functions
need to have their names changed. PCRE must be compiled with the -DVPCOMPAT
option on the command line. */
@@ -396,7 +414,7 @@ The macros are controlled by the value of LINK_SIZE. This defaults to 2 in
the config.h file, but can be overridden by using -D on the command line. This
is automated on Unix systems via the "configure" command. */
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
#if LINK_SIZE == 2
@@ -441,12 +459,11 @@ is automated on Unix systems via the "configure" command. */
#error LINK_SIZE must be either 2, 3, or 4
#endif
-#else /* COMPILE_PCRE8 */
-
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
#if LINK_SIZE == 2
+/* Redefine LINK_SIZE as a multiple of sizeof(pcre_uchar) */
#undef LINK_SIZE
#define LINK_SIZE 1
@@ -460,6 +477,7 @@ is automated on Unix systems via the "configure" command. */
#elif LINK_SIZE == 3 || LINK_SIZE == 4
+/* Redefine LINK_SIZE as a multiple of sizeof(pcre_uchar) */
#undef LINK_SIZE
#define LINK_SIZE 2
@@ -477,11 +495,25 @@ is automated on Unix systems via the "configure" command. */
#error LINK_SIZE must be either 2, 3, or 4
#endif
+#elif defined COMPILE_PCRE32
+
+/* Only supported LINK_SIZE is 4 */
+/* Redefine LINK_SIZE as a multiple of sizeof(pcre_uchar) */
+#undef LINK_SIZE
+#define LINK_SIZE 1
+
+#define PUT(a,n,d) \
+ (a[n] = (d))
+
+#define GET(a,n) \
+ (a[n])
+
+/* Keep it positive */
+#define MAX_PATTERN_SIZE (1 << 30)
+
#else
#error Unsupported compiling mode
-#endif /* COMPILE_PCRE16 */
-
-#endif /* COMPILE_PCRE8 */
+#endif /* COMPILE_PCRE[8|16|32] */
/* Convenience macro defined in terms of the others */
@@ -492,7 +524,7 @@ is automated on Unix systems via the "configure" command. */
offsets changes. There are used for repeat counts and for other things such as
capturing parenthesis numbers in back references. */
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
#define IMM2_SIZE 2
@@ -500,12 +532,24 @@ capturing parenthesis numbers in back references. */
a[n] = (d) >> 8; \
a[(n)+1] = (d) & 255
+/* For reasons that I do not understand, the expression in this GET2 macro is
+treated by gcc as a signed expression, even when a is declared as unsigned. It
+seems that any kind of arithmetic results in a signed value. */
+
#define GET2(a,n) \
- (((a)[n] << 8) | (a)[(n)+1])
+ (unsigned int)(((a)[n] << 8) | (a)[(n)+1])
+
+#elif defined COMPILE_PCRE16
+
+#define IMM2_SIZE 1
-#else /* COMPILE_PCRE8 */
+#define PUT2(a,n,d) \
+ a[n] = d
-#ifdef COMPILE_PCRE16
+#define GET2(a,n) \
+ a[n]
+
+#elif defined COMPILE_PCRE32
#define IMM2_SIZE 1
@@ -517,18 +561,25 @@ capturing parenthesis numbers in back references. */
#else
#error Unsupported compiling mode
-#endif /* COMPILE_PCRE16 */
-
-#endif /* COMPILE_PCRE8 */
+#endif /* COMPILE_PCRE[8|16|32] */
#define PUT2INC(a,n,d) PUT2(a,n,d), a += IMM2_SIZE
+/* The maximum length of a MARK name is currently one data unit; it may be
+changed in future to be a fixed number of bytes or to depend on LINK_SIZE. */
+
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+#define MAX_MARK ((1u << 16) - 1)
+#else
+#define MAX_MARK ((1u << 8) - 1)
+#endif
+
/* When UTF encoding is being used, a character is no longer just a single
-character. The macros for character handling generate simple sequences when
-used in character-mode, and more complicated ones for UTF characters.
-GETCHARLENTEST and other macros are not used when UTF is not supported,
-so they are not defined. To make sure they can never even appear when
-UTF support is omitted, we don't even define them. */
+byte. The macros for character handling generate simple sequences when used in
+character-mode, and more complicated ones for UTF characters. GETCHARLENTEST
+and other macros are not used when UTF is not supported, so they are not
+defined. To make sure they can never even appear when UTF support is omitted,
+we don't even define them. */
#ifndef SUPPORT_UTF
@@ -541,6 +592,10 @@ UTF support is omitted, we don't even define them. */
#define GETCHARINC(c, eptr) c = *eptr++;
#define GETCHARINCTEST(c, eptr) c = *eptr++;
#define GETCHARLEN(c, eptr, len) c = *eptr;
+#define RAWUCHAR(eptr) (*(eptr))
+#define RAWUCHARINC(eptr) (*(eptr)++)
+#define RAWUCHARTEST(eptr) (*(eptr))
+#define RAWUCHARINCTEST(eptr) (*(eptr)++)
/* #define GETCHARLENTEST(c, eptr, len) */
/* #define BACKCHAR(eptr) */
/* #define FORWARDCHAR(eptr) */
@@ -548,30 +603,9 @@ UTF support is omitted, we don't even define them. */
#else /* SUPPORT_UTF */
-#ifdef COMPILE_PCRE8
-
-/* These macros were originally written in the form of loops that used data
-from the tables whose names start with PRIV(utf8_table). They were rewritten by
-a user so as not to use loops, because in some environments this gives a
-significant performance advantage, and it seems never to do any harm. */
-
-/* Tells the biggest code point which can be encoded as a single character. */
-
-#define MAX_VALUE_FOR_SINGLE_CHAR 127
-
/* Tests whether the code point needs extra characters to decode. */
-#define HAS_EXTRALEN(c) ((c) >= 0xc0)
-
-/* Returns with the additional number of characters if IS_MULTICHAR(c) is TRUE.
-Otherwise it has an undefined behaviour. */
-
-#define GET_EXTRALEN(c) (PRIV(utf8_table4)[(c) & 0x3f])
-
-/* Returns TRUE, if the given character is not the first character
-of a UTF sequence. */
-
-#define NOT_FIRSTCHAR(c) (((c) & 0xc0) == 0x80)
+#define HASUTF8EXTRALEN(c) ((c) >= 0xc0)
/* Base macro to pick up the remaining bytes of a UTF-8 character, not
advancing the pointer. */
@@ -595,20 +629,6 @@ advancing the pointer. */
((eptr[4] & 0x3f) << 6) | (eptr[5] & 0x3f); \
}
-/* Get the next UTF-8 character, not advancing the pointer. This is called when
-we know we are in UTF-8 mode. */
-
-#define GETCHAR(c, eptr) \
- c = *eptr; \
- if (c >= 0xc0) GETUTF8(c, eptr);
-
-/* Get the next UTF-8 character, testing for UTF-8 mode, and not advancing the
-pointer. */
-
-#define GETCHARTEST(c, eptr) \
- c = *eptr; \
- if (utf && c >= 0xc0) GETUTF8(c, eptr);
-
/* Base macro to pick up the remaining bytes of a UTF-8 character, advancing
the pointer. */
@@ -643,6 +663,45 @@ the pointer. */
} \
}
+#if defined COMPILE_PCRE8
+
+/* These macros were originally written in the form of loops that used data
+from the tables whose names start with PRIV(utf8_table). They were rewritten by
+a user so as not to use loops, because in some environments this gives a
+significant performance advantage, and it seems never to do any harm. */
+
+/* Tells the biggest code point which can be encoded as a single character. */
+
+#define MAX_VALUE_FOR_SINGLE_CHAR 127
+
+/* Tests whether the code point needs extra characters to decode. */
+
+#define HAS_EXTRALEN(c) ((c) >= 0xc0)
+
+/* Returns with the additional number of characters if IS_MULTICHAR(c) is TRUE.
+Otherwise it has an undefined behaviour. */
+
+#define GET_EXTRALEN(c) (PRIV(utf8_table4)[(c) & 0x3f])
+
+/* Returns TRUE, if the given character is not the first character
+of a UTF sequence. */
+
+#define NOT_FIRSTCHAR(c) (((c) & 0xc0) == 0x80)
+
+/* Get the next UTF-8 character, not advancing the pointer. This is called when
+we know we are in UTF-8 mode. */
+
+#define GETCHAR(c, eptr) \
+ c = *eptr; \
+ if (c >= 0xc0) GETUTF8(c, eptr);
+
+/* Get the next UTF-8 character, testing for UTF-8 mode, and not advancing the
+pointer. */
+
+#define GETCHARTEST(c, eptr) \
+ c = *eptr; \
+ if (utf && c >= 0xc0) GETUTF8(c, eptr);
+
/* Get the next UTF-8 character, advancing the pointer. This is called when we
know we are in UTF-8 mode. */
@@ -709,6 +768,30 @@ do not know if we are in UTF-8 mode. */
c = *eptr; \
if (utf && c >= 0xc0) GETUTF8LEN(c, eptr, len);
+/* Returns the next uchar, not advancing the pointer. This is called when
+we know we are in UTF mode. */
+
+#define RAWUCHAR(eptr) \
+ (*(eptr))
+
+/* Returns the next uchar, advancing the pointer. This is called when
+we know we are in UTF mode. */
+
+#define RAWUCHARINC(eptr) \
+ (*((eptr)++))
+
+/* Returns the next uchar, testing for UTF mode, and not advancing the
+pointer. */
+
+#define RAWUCHARTEST(eptr) \
+ (*(eptr))
+
+/* Returns the next uchar, testing for UTF mode, advancing the
+pointer. */
+
+#define RAWUCHARINCTEST(eptr) \
+ (*((eptr)++))
+
/* If the pointer is not at the start of a character, move it back until
it is. This is called only in UTF-8 mode - we don't put a test within the macro
because almost all calls are already within a block of UTF-8 only code. */
@@ -722,9 +805,7 @@ because almost all calls are already within a block of UTF-8 only code. */
#define ACROSSCHAR(condition, eptr, action) \
while((condition) && ((eptr) & 0xc0) == 0x80) action
-#else /* COMPILE_PCRE8 */
-
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
/* Tells the biggest code point which can be encoded as a single character. */
@@ -806,6 +887,30 @@ we do not know if we are in UTF-16 mode. */
c = *eptr; \
if (utf && (c & 0xfc00) == 0xd800) GETUTF16LEN(c, eptr, len);
+/* Returns the next uchar, not advancing the pointer. This is called when
+we know we are in UTF mode. */
+
+#define RAWUCHAR(eptr) \
+ (*(eptr))
+
+/* Returns the next uchar, advancing the pointer. This is called when
+we know we are in UTF mode. */
+
+#define RAWUCHARINC(eptr) \
+ (*((eptr)++))
+
+/* Returns the next uchar, testing for UTF mode, and not advancing the
+pointer. */
+
+#define RAWUCHARTEST(eptr) \
+ (*(eptr))
+
+/* Returns the next uchar, testing for UTF mode, advancing the
+pointer. */
+
+#define RAWUCHARINCTEST(eptr) \
+ (*((eptr)++))
+
/* If the pointer is not at the start of a character, move it back until
it is. This is called only in UTF-16 mode - we don't put a test within the
macro because almost all calls are already within a block of UTF-16 only
@@ -820,20 +925,200 @@ code. */
#define ACROSSCHAR(condition, eptr, action) \
if ((condition) && ((eptr) & 0xfc00) == 0xdc00) action
-#endif
+#elif defined COMPILE_PCRE32
-#endif /* COMPILE_PCRE8 */
+/* These are trivial for the 32-bit library, since all UTF-32 characters fit
+into one pcre_uchar unit. */
+#define MAX_VALUE_FOR_SINGLE_CHAR (0x10ffffu)
+#define HAS_EXTRALEN(c) (0)
+#define GET_EXTRALEN(c) (0)
+#define NOT_FIRSTCHAR(c) (0)
+
+/* Get the next UTF-32 character, not advancing the pointer. This is called when
+we know we are in UTF-32 mode. */
+
+#define GETCHAR(c, eptr) \
+ c = *(eptr);
+
+/* Get the next UTF-32 character, testing for UTF-32 mode, and not advancing the
+pointer. */
+
+#define GETCHARTEST(c, eptr) \
+ c = *(eptr);
+
+/* Get the next UTF-32 character, advancing the pointer. This is called when we
+know we are in UTF-32 mode. */
+
+#define GETCHARINC(c, eptr) \
+ c = *((eptr)++);
+
+/* Get the next character, testing for UTF-32 mode, and advancing the pointer.
+This is called when we don't know if we are in UTF-32 mode. */
+
+#define GETCHARINCTEST(c, eptr) \
+ c = *((eptr)++);
+
+/* Get the next UTF-32 character, not advancing the pointer, not incrementing
+length (since all UTF-32 is of length 1). This is called when we know we are in
+UTF-32 mode. */
+
+#define GETCHARLEN(c, eptr, len) \
+ GETCHAR(c, eptr)
+
+/* Get the next UTF-32character, testing for UTF-32 mode, not advancing the
+pointer, not incrementing the length (since all UTF-32 is of length 1).
+This is called when we do not know if we are in UTF-32 mode. */
+
+#define GETCHARLENTEST(c, eptr, len) \
+ GETCHARTEST(c, eptr)
+
+/* Returns the next uchar, not advancing the pointer. This is called when
+we know we are in UTF mode. */
+
+#define RAWUCHAR(eptr) \
+ (*(eptr))
+
+/* Returns the next uchar, advancing the pointer. This is called when
+we know we are in UTF mode. */
+
+#define RAWUCHARINC(eptr) \
+ (*((eptr)++))
+
+/* Returns the next uchar, testing for UTF mode, and not advancing the
+pointer. */
+
+#define RAWUCHARTEST(eptr) \
+ (*(eptr))
+
+/* Returns the next uchar, testing for UTF mode, advancing the
+pointer. */
+
+#define RAWUCHARINCTEST(eptr) \
+ (*((eptr)++))
+
+/* If the pointer is not at the start of a character, move it back until
+it is. This is called only in UTF-32 mode - we don't put a test within the
+macro because almost all calls are already within a block of UTF-32 only
+code.
+These are all no-ops since all UTF-32 characters fit into one pcre_uchar. */
+
+#define BACKCHAR(eptr) do { } while (0)
+
+/* Same as above, just in the other direction. */
+#define FORWARDCHAR(eptr) do { } while (0)
+
+/* Same as above, but it allows a fully customizable form. */
+#define ACROSSCHAR(condition, eptr, action) do { } while (0)
+
+#else
+#error Unsupported compiling mode
+#endif /* COMPILE_PCRE[8|16|32] */
#endif /* SUPPORT_UTF */
+/* Tests for Unicode horizontal and vertical whitespace characters must check a
+number of different values. Using a switch statement for this generates the
+fastest code (no loop, no memory access), and there are several places in the
+interpreter code where this happens. In order to ensure that all the case lists
+remain in step, we use macros so that there is only one place where the lists
+are defined.
+
+These values are also required as lists in pcre_compile.c when processing \h,
+\H, \v and \V in a character class. The lists are defined in pcre_tables.c, but
+macros that define the values are here so that all the definitions are
+together. The lists must be in ascending character order, terminated by
+NOTACHAR (which is 0xffffffff).
+
+Any changes should ensure that the various macros are kept in step with each
+other. NOTE: The values also appear in pcre_jit_compile.c. */
+
+/* ------ ASCII/Unicode environments ------ */
+
+#ifndef EBCDIC
+
+#define HSPACE_LIST \
+ CHAR_HT, CHAR_SPACE, 0xa0, \
+ 0x1680, 0x180e, 0x2000, 0x2001, 0x2002, 0x2003, 0x2004, 0x2005, \
+ 0x2006, 0x2007, 0x2008, 0x2009, 0x200A, 0x202f, 0x205f, 0x3000, \
+ NOTACHAR
+
+#define HSPACE_MULTIBYTE_CASES \
+ case 0x1680: /* OGHAM SPACE MARK */ \
+ case 0x180e: /* MONGOLIAN VOWEL SEPARATOR */ \
+ case 0x2000: /* EN QUAD */ \
+ case 0x2001: /* EM QUAD */ \
+ case 0x2002: /* EN SPACE */ \
+ case 0x2003: /* EM SPACE */ \
+ case 0x2004: /* THREE-PER-EM SPACE */ \
+ case 0x2005: /* FOUR-PER-EM SPACE */ \
+ case 0x2006: /* SIX-PER-EM SPACE */ \
+ case 0x2007: /* FIGURE SPACE */ \
+ case 0x2008: /* PUNCTUATION SPACE */ \
+ case 0x2009: /* THIN SPACE */ \
+ case 0x200A: /* HAIR SPACE */ \
+ case 0x202f: /* NARROW NO-BREAK SPACE */ \
+ case 0x205f: /* MEDIUM MATHEMATICAL SPACE */ \
+ case 0x3000 /* IDEOGRAPHIC SPACE */
+
+#define HSPACE_BYTE_CASES \
+ case CHAR_HT: \
+ case CHAR_SPACE: \
+ case 0xa0 /* NBSP */
+
+#define HSPACE_CASES \
+ HSPACE_BYTE_CASES: \
+ HSPACE_MULTIBYTE_CASES
+
+#define VSPACE_LIST \
+ CHAR_LF, CHAR_VT, CHAR_FF, CHAR_CR, CHAR_NEL, 0x2028, 0x2029, NOTACHAR
+
+#define VSPACE_MULTIBYTE_CASES \
+ case 0x2028: /* LINE SEPARATOR */ \
+ case 0x2029 /* PARAGRAPH SEPARATOR */
+
+#define VSPACE_BYTE_CASES \
+ case CHAR_LF: \
+ case CHAR_VT: \
+ case CHAR_FF: \
+ case CHAR_CR: \
+ case CHAR_NEL
+
+#define VSPACE_CASES \
+ VSPACE_BYTE_CASES: \
+ VSPACE_MULTIBYTE_CASES
+
+/* ------ EBCDIC environments ------ */
-/* In case there is no definition of offsetof() provided - though any proper
-Standard C system should have one. */
+#else
+#define HSPACE_LIST CHAR_HT, CHAR_SPACE
+
+#define HSPACE_BYTE_CASES \
+ case CHAR_HT: \
+ case CHAR_SPACE
-#ifndef offsetof
-#define offsetof(p_type,field) ((size_t)&(((p_type *)0)->field))
+#define HSPACE_CASES HSPACE_BYTE_CASES
+
+#ifdef EBCDIC_NL25
+#define VSPACE_LIST \
+ CHAR_VT, CHAR_FF, CHAR_CR, CHAR_NEL, CHAR_LF, NOTACHAR
+#else
+#define VSPACE_LIST \
+ CHAR_VT, CHAR_FF, CHAR_CR, CHAR_LF, CHAR_NEL, NOTACHAR
#endif
+#define VSPACE_BYTE_CASES \
+ case CHAR_LF: \
+ case CHAR_VT: \
+ case CHAR_FF: \
+ case CHAR_CR: \
+ case CHAR_NEL
+
+#define VSPACE_CASES VSPACE_BYTE_CASES
+#endif /* EBCDIC */
+
+/* ------ End of whitespace macros ------ */
+
+
/* Private flags containing information about the compiled regex. They used to
live at the top end of the options word, but that got almost full, so now they
@@ -841,12 +1126,9 @@ are in a 16-bit flags word. From release 8.00, PCRE_NOPARTIAL is unused, as
the restrictions on partial matching have been lifted. It remains for backwards
compatibility. */
-#ifdef COMPILE_PCRE8
-#define PCRE_MODE 0x0001 /* compiled in 8 bit mode */
-#endif
-#ifdef COMPILE_PCRE16
-#define PCRE_MODE 0x0002 /* compiled in 16 bit mode */
-#endif
+#define PCRE_MODE8 0x0001 /* compiled in 8 bit mode */
+#define PCRE_MODE16 0x0002 /* compiled in 16 bit mode */
+#define PCRE_MODE32 0x0004 /* compiled in 32 bit mode */
#define PCRE_FIRSTSET 0x0010 /* first_char is set */
#define PCRE_FCH_CASELESS 0x0020 /* caseless first char */
#define PCRE_REQCHSET 0x0040 /* req_byte is set */
@@ -857,6 +1139,15 @@ compatibility. */
#define PCRE_HASCRORLF 0x0800 /* explicit \r or \n in pattern */
#define PCRE_HASTHEN 0x1000 /* pattern contains (*THEN) */
+#if defined COMPILE_PCRE8
+#define PCRE_MODE PCRE_MODE8
+#elif defined COMPILE_PCRE16
+#define PCRE_MODE PCRE_MODE16
+#elif defined COMPILE_PCRE32
+#define PCRE_MODE PCRE_MODE32
+#endif
+#define PCRE_MODE_MASK (PCRE_MODE8 | PCRE_MODE16 | PCRE_MODE32)
+
/* Flags for the "extra" block produced by pcre_study(). */
#define PCRE_STUDY_MAPPED 0x0001 /* a map of starting chars exists */
@@ -887,7 +1178,12 @@ time, run time, or study time, respectively. */
PCRE_NO_START_OPTIMIZE)
#define PUBLIC_STUDY_OPTIONS \
- PCRE_STUDY_JIT_COMPILE
+ (PCRE_STUDY_JIT_COMPILE|PCRE_STUDY_JIT_PARTIAL_SOFT_COMPILE| \
+ PCRE_STUDY_JIT_PARTIAL_HARD_COMPILE|PCRE_STUDY_EXTRA_NEEDED)
+
+#define PUBLIC_JIT_EXEC_OPTIONS \
+ (PCRE_NO_UTF8_CHECK|PCRE_NOTBOL|PCRE_NOTEOL|PCRE_NOTEMPTY|\
+ PCRE_NOTEMPTY_ATSTART|PCRE_PARTIAL_SOFT|PCRE_PARTIAL_HARD)
/* Magic number to provide a small check against being handed junk. */
@@ -898,11 +1194,6 @@ in different endianness. */
#define REVERSED_MAGIC_NUMBER 0x45524350UL /* 'ERCP' */
-/* Negative values for the firstchar and reqchar variables */
-
-#define REQ_UNSET (-2)
-#define REQ_NONE (-1)
-
/* The maximum remaining length of subject we are prepared to search for a
req_byte match. */
@@ -939,22 +1230,71 @@ macros to give the functions distinct names. */
#ifndef SUPPORT_UTF
/* UTF-8 support is not enabled; use the platform-dependent character literals
-so that PCRE works on both ASCII and EBCDIC platforms, in non-UTF-mode only. */
+so that PCRE works in both ASCII and EBCDIC environments, but only in non-UTF
+mode. Newline characters are problematic in EBCDIC. Though it has CR and LF
+characters, a common practice has been to use its NL (0x15) character as the
+line terminator in C-like processing environments. However, sometimes the LF
+(0x25) character is used instead, according to this Unicode document:
+
+http://unicode.org/standard/reports/tr13/tr13-5.html
+
+PCRE defaults EBCDIC NL to 0x15, but has a build-time option to select 0x25
+instead. Whichever is *not* chosen is defined as NEL.
+
+In both ASCII and EBCDIC environments, CHAR_NL and CHAR_LF are synonyms for the
+same code point. */
+
+#ifdef EBCDIC
+
+#ifndef EBCDIC_NL25
+#define CHAR_NL '\x15'
+#define CHAR_NEL '\x25'
+#define STR_NL "\x15"
+#define STR_NEL "\x25"
+#else
+#define CHAR_NL '\x25'
+#define CHAR_NEL '\x15'
+#define STR_NL "\x25"
+#define STR_NEL "\x15"
+#endif
+
+#define CHAR_LF CHAR_NL
+#define STR_LF STR_NL
+
+#define CHAR_ESC '\047'
+#define CHAR_DEL '\007'
+#define STR_ESC "\047"
+#define STR_DEL "\007"
+#else /* Not EBCDIC */
+
+/* In ASCII/Unicode, linefeed is '\n' and we equate this to NL for
+compatibility. NEL is the Unicode newline character; make sure it is
+a positive value. */
+
+#define CHAR_LF '\n'
+#define CHAR_NL CHAR_LF
+#define CHAR_NEL ((unsigned char)'\x85')
+#define CHAR_ESC '\033'
+#define CHAR_DEL '\177'
+
+#define STR_LF "\n"
+#define STR_NL STR_LF
+#define STR_NEL "\x85"
+#define STR_ESC "\033"
+#define STR_DEL "\177"
+
+#endif /* EBCDIC */
+
+/* The remaining definitions work in both environments. */
+
+#define CHAR_NULL '\0'
#define CHAR_HT '\t'
#define CHAR_VT '\v'
#define CHAR_FF '\f'
#define CHAR_CR '\r'
-#define CHAR_NL '\n'
#define CHAR_BS '\b'
#define CHAR_BEL '\a'
-#ifdef EBCDIC
-#define CHAR_ESC '\047'
-#define CHAR_DEL '\007'
-#else
-#define CHAR_ESC '\033'
-#define CHAR_DEL '\177'
-#endif
#define CHAR_SPACE ' '
#define CHAR_EXCLAMATION_MARK '!'
@@ -1056,16 +1396,8 @@ so that PCRE works on both ASCII and EBCDIC platforms, in non-UTF-mode only. */
#define STR_VT "\v"
#define STR_FF "\f"
#define STR_CR "\r"
-#define STR_NL "\n"
#define STR_BS "\b"
#define STR_BEL "\a"
-#ifdef EBCDIC
-#define STR_ESC "\047"
-#define STR_DEL "\007"
-#else
-#define STR_ESC "\033"
-#define STR_DEL "\177"
-#endif
#define STR_SPACE " "
#define STR_EXCLAMATION_MARK "!"
@@ -1196,12 +1528,10 @@ so that PCRE works on both ASCII and EBCDIC platforms, in non-UTF-mode only. */
#define STRING_ANYCRLF_RIGHTPAR "ANYCRLF)"
#define STRING_BSR_ANYCRLF_RIGHTPAR "BSR_ANYCRLF)"
#define STRING_BSR_UNICODE_RIGHTPAR "BSR_UNICODE)"
-#ifdef COMPILE_PCRE8
-#define STRING_UTF_RIGHTPAR "UTF8)"
-#endif
-#ifdef COMPILE_PCRE16
-#define STRING_UTF_RIGHTPAR "UTF16)"
-#endif
+#define STRING_UTF8_RIGHTPAR "UTF8)"
+#define STRING_UTF16_RIGHTPAR "UTF16)"
+#define STRING_UTF32_RIGHTPAR "UTF32)"
+#define STRING_UTF_RIGHTPAR "UTF)"
#define STRING_UCP_RIGHTPAR "UCP)"
#define STRING_NO_START_OPT_RIGHTPAR "NO_START_OPT)"
@@ -1215,12 +1545,15 @@ only. */
#define CHAR_VT '\013'
#define CHAR_FF '\014'
#define CHAR_CR '\015'
-#define CHAR_NL '\012'
+#define CHAR_LF '\012'
+#define CHAR_NL CHAR_LF
+#define CHAR_NEL ((unsigned char)'\x85')
#define CHAR_BS '\010'
#define CHAR_BEL '\007'
#define CHAR_ESC '\033'
#define CHAR_DEL '\177'
+#define CHAR_NULL '\0'
#define CHAR_SPACE '\040'
#define CHAR_EXCLAMATION_MARK '\041'
#define CHAR_QUOTATION_MARK '\042'
@@ -1456,12 +1789,10 @@ only. */
#define STRING_ANYCRLF_RIGHTPAR STR_A STR_N STR_Y STR_C STR_R STR_L STR_F STR_RIGHT_PARENTHESIS
#define STRING_BSR_ANYCRLF_RIGHTPAR STR_B STR_S STR_R STR_UNDERSCORE STR_A STR_N STR_Y STR_C STR_R STR_L STR_F STR_RIGHT_PARENTHESIS
#define STRING_BSR_UNICODE_RIGHTPAR STR_B STR_S STR_R STR_UNDERSCORE STR_U STR_N STR_I STR_C STR_O STR_D STR_E STR_RIGHT_PARENTHESIS
-#ifdef COMPILE_PCRE8
-#define STRING_UTF_RIGHTPAR STR_U STR_T STR_F STR_8 STR_RIGHT_PARENTHESIS
-#endif
-#ifdef COMPILE_PCRE16
-#define STRING_UTF_RIGHTPAR STR_U STR_T STR_F STR_1 STR_6 STR_RIGHT_PARENTHESIS
-#endif
+#define STRING_UTF8_RIGHTPAR STR_U STR_T STR_F STR_8 STR_RIGHT_PARENTHESIS
+#define STRING_UTF16_RIGHTPAR STR_U STR_T STR_F STR_1 STR_6 STR_RIGHT_PARENTHESIS
+#define STRING_UTF32_RIGHTPAR STR_U STR_T STR_F STR_3 STR_2 STR_RIGHT_PARENTHESIS
+#define STRING_UTF_RIGHTPAR STR_U STR_T STR_F STR_RIGHT_PARENTHESIS
#define STRING_UCP_RIGHTPAR STR_U STR_C STR_P STR_RIGHT_PARENTHESIS
#define STRING_NO_START_OPT_RIGHTPAR STR_N STR_O STR_UNDERSCORE STR_S STR_T STR_A STR_R STR_T STR_UNDERSCORE STR_O STR_P STR_T STR_RIGHT_PARENTHESIS
@@ -1478,7 +1809,7 @@ only. */
#endif
#ifndef ESC_n
-#define ESC_n CHAR_NL
+#define ESC_n CHAR_LF
#endif
#ifndef ESC_r
@@ -1503,6 +1834,7 @@ only. */
#define PT_SPACE 6 /* Perl space - Z plus 9,10,12,13 */
#define PT_PXSPACE 7 /* POSIX space - Z plus 9,10,11,12,13 */
#define PT_WORD 8 /* Word - L plus N plus underscore */
+#define PT_CLIST 9 /* Pseudo-property: match character list */
/* Flag bits and data types for the extended class (OP_XCLASS) for classes that
contain characters with values greater than 255. */
@@ -1518,19 +1850,19 @@ contain characters with values greater than 255. */
/* These are escaped items that aren't just an encoding of a particular data
value such as \n. They must have non-zero values, as check_escape() returns
-their negation. Also, they must appear in the same order as in the opcode
+0 for a data character. Also, they must appear in the same order as in the opcode
definitions below, up to ESC_z. There's a dummy for OP_ALLANY because it
corresponds to "." in DOTALL mode rather than an escape sequence. It is also
used for [^] in JavaScript compatibility mode, and for \C in non-utf mode. In
non-DOTALL mode, "." behaves like \N.
The special values ESC_DU, ESC_du, etc. are used instead of ESC_D, ESC_d, etc.
-when PCRE_UCP is set, when replacement of \d etc by \p sequences is required.
+when PCRE_UCP is set and replacement of \d etc by \p sequences is required.
They must be contiguous, and remain in order so that the replacements can be
looked up from a table.
-The final escape must be ESC_REF as subsequent values are used for
-backreferences (\1, \2, \3, etc). There are two tests in the code for an escape
+Negative numbers are used to encode a backreference (\1, \2, \3, etc.) in
+check_escape(). There are two tests in the code for an escape
greater than ESC_b and less than ESC_Z to detect the types that may be
repeated. These are the types that consume characters. If any new escapes are
put in between that don't consume a character, that code will have to change.
@@ -1540,8 +1872,7 @@ enum { ESC_A = 1, ESC_G, ESC_K, ESC_B, ESC_b, ESC_D, ESC_d, ESC_S, ESC_s,
ESC_W, ESC_w, ESC_N, ESC_dum, ESC_C, ESC_P, ESC_p, ESC_R, ESC_H,
ESC_h, ESC_V, ESC_v, ESC_X, ESC_Z, ESC_z,
ESC_E, ESC_Q, ESC_g, ESC_k,
- ESC_DU, ESC_du, ESC_SU, ESC_su, ESC_WU, ESC_wu,
- ESC_REF };
+ ESC_DU, ESC_du, ESC_SU, ESC_su, ESC_WU, ESC_wu };
/* Opcode table: Starting from 1 (i.e. after OP_END), the values up to
OP_EOD must correspond in order to the list of escapes immediately above.
@@ -1567,7 +1898,7 @@ enum {
OP_NOT_WORDCHAR, /* 10 \W */
OP_WORDCHAR, /* 11 \w */
- OP_ANY, /* 12 Match any character except newline */
+ OP_ANY, /* 12 Match any character except newline (\N) */
OP_ALLANY, /* 13 Match any character */
OP_ANYBYTE, /* 14 Match any byte (\C); different to OP_ANY for UTF-8 */
OP_NOTPROP, /* 15 \P (not Unicode property) */
@@ -1578,8 +1909,8 @@ enum {
OP_NOT_VSPACE, /* 20 \V (not vertical whitespace) */
OP_VSPACE, /* 21 \v (vertical whitespace) */
OP_EXTUNI, /* 22 \X (extended Unicode sequence */
- OP_EODN, /* 23 End of data or \n at end of data: \Z. */
- OP_EOD, /* 24 End of data: \z */
+ OP_EODN, /* 23 End of data or \n at end of data (\Z) */
+ OP_EOD, /* 24 End of data (\z) */
OP_CIRC, /* 25 Start of line - not multiline */
OP_CIRCM, /* 26 Start of line - multiline */
@@ -1939,7 +2270,11 @@ enum { ERR0, ERR1, ERR2, ERR3, ERR4, ERR5, ERR6, ERR7, ERR8, ERR9,
ERR40, ERR41, ERR42, ERR43, ERR44, ERR45, ERR46, ERR47, ERR48, ERR49,
ERR50, ERR51, ERR52, ERR53, ERR54, ERR55, ERR56, ERR57, ERR58, ERR59,
ERR60, ERR61, ERR62, ERR63, ERR64, ERR65, ERR66, ERR67, ERR68, ERR69,
- ERR70, ERR71, ERR72, ERR73, ERR74, ERRCOUNT };
+ ERR70, ERR71, ERR72, ERR73, ERR74, ERR75, ERR76, ERR77, ERRCOUNT };
+
+/* JIT compiling modes. The function list is indexed by them. */
+enum { JIT_COMPILE, JIT_PARTIAL_SOFT_COMPILE, JIT_PARTIAL_HARD_COMPILE,
+ JIT_NUMBER_OF_COMPILE_MODES };
/* The real format of the start of the pcre block; the index of names and the
code vector run on as long as necessary after the end. We store an explicit
@@ -1958,30 +2293,71 @@ fields are present. Currently PCRE always sets the dummy fields to zero.
NOTE NOTE NOTE
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
#define REAL_PCRE real_pcre
-#else
+#elif defined COMPILE_PCRE16
#define REAL_PCRE real_pcre16
+#elif defined COMPILE_PCRE32
+#define REAL_PCRE real_pcre32
#endif
-typedef struct REAL_PCRE {
+/* It is necessary to fork the struct for 32 bit, since it needs to use
+ * pcre_uchar for first_char and req_char. Can't put an ifdef inside the
+ * typedef since pcretest needs access to the struct of the 8-, 16-
+ * and 32-bit variants. */
+
+typedef struct real_pcre8_or_16 {
pcre_uint32 magic_number;
pcre_uint32 size; /* Total that was malloced */
pcre_uint32 options; /* Public options */
pcre_uint16 flags; /* Private flags */
- pcre_uint16 dummy1; /* For future use */
- pcre_uint16 top_bracket;
- pcre_uint16 top_backref;
+ pcre_uint16 max_lookbehind; /* Longest lookbehind (characters) */
+ pcre_uint16 top_bracket; /* Highest numbered group */
+ pcre_uint16 top_backref; /* Highest numbered back reference */
pcre_uint16 first_char; /* Starting character */
pcre_uint16 req_char; /* This character must be seen */
pcre_uint16 name_table_offset; /* Offset to name table that follows */
pcre_uint16 name_entry_size; /* Size of any name items */
pcre_uint16 name_count; /* Number of name items */
pcre_uint16 ref_count; /* Reference count */
-
const pcre_uint8 *tables; /* Pointer to tables or NULL for std */
const pcre_uint8 *nullpad; /* NULL padding */
-} REAL_PCRE;
+} real_pcre8_or_16;
+
+typedef struct real_pcre8_or_16 real_pcre;
+typedef struct real_pcre8_or_16 real_pcre16;
+
+typedef struct real_pcre32 {
+ pcre_uint32 magic_number;
+ pcre_uint32 size; /* Total that was malloced */
+ pcre_uint32 options; /* Public options */
+ pcre_uint16 flags; /* Private flags */
+ pcre_uint16 max_lookbehind; /* Longest lookbehind (characters) */
+ pcre_uint16 top_bracket; /* Highest numbered group */
+ pcre_uint16 top_backref; /* Highest numbered back reference */
+ pcre_uint32 first_char; /* Starting character */
+ pcre_uint32 req_char; /* This character must be seen */
+ pcre_uint16 name_table_offset; /* Offset to name table that follows */
+ pcre_uint16 name_entry_size; /* Size of any name items */
+ pcre_uint16 name_count; /* Number of name items */
+ pcre_uint16 ref_count; /* Reference count */
+ pcre_uint16 dummy1; /* for later expansion */
+ pcre_uint16 dummy2; /* for later expansion */
+ const pcre_uint8 *tables; /* Pointer to tables or NULL for std */
+ void *nullpad; /* for later expansion */
+} real_pcre32;
+
+/* Assert that the size of REAL_PCRE is divisible by 8 */
+typedef int __assert_real_pcre_size_divisible_8[(sizeof(REAL_PCRE) % 8) == 0 ? 1 : -1];
+
+/* Needed in pcretest to access some fields in the real_pcre* structures
+ * directly. They're unified for 8/16/32 bits since the structs only differ
+ * after these fields; if that ever changes, need to fork those defines into
+ * 8/16 and 32 bit versions. */
+#define REAL_PCRE_MAGIC(re) (((REAL_PCRE*)re)->magic_number)
+#define REAL_PCRE_SIZE(re) (((REAL_PCRE*)re)->size)
+#define REAL_PCRE_OPTIONS(re) (((REAL_PCRE*)re)->options)
+#define REAL_PCRE_FLAGS(re) (((REAL_PCRE*)re)->flags)
/* The format of the block used to store data from pcre_study(). The same
remark (see NOTE above) about extending this structure applies. */
@@ -2022,8 +2398,9 @@ typedef struct compile_data {
int names_found; /* Number of entries so far */
int name_entry_size; /* Size of each entry */
int workspace_size; /* Size of workspace */
- int bracount; /* Count of capturing parens as we compile */
+ unsigned int bracount; /* Count of capturing parens as we compile */
int final_bracount; /* Saved value after first pass */
+ int max_lookbehind; /* Maximum lookbehind (characters) */
int top_backref; /* Maximum back reference */
unsigned int backref_map; /* Bitmap of low back refs */
int assert_depth; /* Depth of nested assertions */
@@ -2031,6 +2408,7 @@ typedef struct compile_data {
int external_flags; /* External flag bits to be set */
int req_varyopt; /* "After variable item" flag for reqbyte */
BOOL had_accept; /* (*ACCEPT) encountered */
+ BOOL had_pruneorskip; /* (*PRUNE) or (*SKIP) encountered */
BOOL check_lookbehind; /* Lookbehinds need later checking */
int nltype; /* Newline type */
int nllen; /* Newline string length */
@@ -2050,7 +2428,7 @@ call within the pattern; used by pcre_exec(). */
typedef struct recursion_info {
struct recursion_info *prevrec; /* Previous recursion record (or NULL) */
- int group_num; /* Number of group that was called */
+ unsigned int group_num; /* Number of group that was called */
int *offset_save; /* Pointer to start of saved offsets */
int saved_max; /* Number of saved offsets */
PCRE_PUCHAR subject_position; /* Position at start of recursion */
@@ -2125,6 +2503,9 @@ typedef struct match_data {
const pcre_uchar *mark; /* Mark pointer to pass back on success */
const pcre_uchar *nomatch_mark;/* Mark pointer to pass back on failure */
const pcre_uchar *once_target; /* Where to back up to for atomic groups */
+#ifdef NO_RECURSE
+ void *match_frames_base; /* For remembering malloc'd frames */
+#endif
} match_data;
/* A similar structure is used for the same purpose by the DFA matching
@@ -2179,27 +2560,32 @@ total length. */
#define ctypes_offset (cbits_offset + cbit_length)
#define tables_length (ctypes_offset + 256)
-/* Internal function prefix */
+/* Internal function and data prefixes. */
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
#ifndef PUBL
#define PUBL(name) pcre_##name
#endif
#ifndef PRIV
#define PRIV(name) _pcre_##name
#endif
-#else /* COMPILE_PCRE8 */
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
#ifndef PUBL
#define PUBL(name) pcre16_##name
#endif
#ifndef PRIV
#define PRIV(name) _pcre16_##name
#endif
+#elif defined COMPILE_PCRE32
+#ifndef PUBL
+#define PUBL(name) pcre32_##name
+#endif
+#ifndef PRIV
+#define PRIV(name) _pcre32_##name
+#endif
#else
#error Unsupported compiling mode
-#endif /* COMPILE_PCRE16 */
-#endif /* COMPILE_PCRE8 */
+#endif /* COMPILE_PCRE[8|16|32] */
/* Layout of the UCP type table that translates property names into types and
codes. Each entry used to point directly to a name, but to reduce the number of
@@ -2219,22 +2605,22 @@ but are not part of the PCRE public API. The data for these tables is in the
pcre_tables.c module. */
#ifdef COMPILE_PCRE8
-
extern const int PRIV(utf8_table1)[];
extern const int PRIV(utf8_table1_size);
extern const int PRIV(utf8_table2)[];
extern const int PRIV(utf8_table3)[];
extern const pcre_uint8 PRIV(utf8_table4)[];
-
#endif /* COMPILE_PCRE8 */
extern const char PRIV(utt_names)[];
extern const ucp_type_table PRIV(utt)[];
extern const int PRIV(utt_size);
+extern const pcre_uint8 PRIV(OP_lengths)[];
extern const pcre_uint8 PRIV(default_tables)[];
-extern const pcre_uint8 PRIV(OP_lengths)[];
+extern const pcre_uint32 PRIV(hspace_list)[];
+extern const pcre_uint32 PRIV(vspace_list)[];
/* Internal shared functions. These are functions that are used by more than
@@ -2242,7 +2628,7 @@ one of the exported public functions. They have to be "external" in the C
sense, but are not part of the PCRE public API. */
/* String comparison functions. */
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
#define STRCMP_UC_UC(str1, str2) \
strcmp((char *)(str1), (char *)(str2))
@@ -2254,7 +2640,7 @@ sense, but are not part of the PCRE public API. */
strncmp((char *)(str1), (str2), (num))
#define STRLEN_UC(str) strlen((const char *)str)
-#else
+#elif defined COMPILE_PCRE16 || defined COMPILE_PCRE32
extern int PRIV(strcmp_uc_uc)(const pcre_uchar *,
const pcre_uchar *);
@@ -2276,21 +2662,41 @@ extern unsigned int PRIV(strlen_uc)(const pcre_uchar *str);
PRIV(strncmp_uc_c8)((str1), (str2), (num))
#define STRLEN_UC(str) PRIV(strlen_uc)(str)
-#endif /* COMPILE_PCRE8 */
+#endif /* COMPILE_PCRE[8|16|32] */
+
+#if defined COMPILE_PCRE8 || defined COMPILE_PCRE16
+
+#define STRCMP_UC_UC_TEST(str1, str2) STRCMP_UC_UC(str1, str2)
+#define STRCMP_UC_C8_TEST(str1, str2) STRCMP_UC_C8(str1, str2)
+
+#elif defined COMPILE_PCRE32
+
+extern int PRIV(strcmp_uc_uc_utf)(const pcre_uchar *,
+ const pcre_uchar *);
+extern int PRIV(strcmp_uc_c8_utf)(const pcre_uchar *,
+ const char *);
+
+#define STRCMP_UC_UC_TEST(str1, str2) \
+ (utf ? PRIV(strcmp_uc_uc_utf)((str1), (str2)) : PRIV(strcmp_uc_uc)((str1), (str2)))
+#define STRCMP_UC_C8_TEST(str1, str2) \
+ (utf ? PRIV(strcmp_uc_c8_utf)((str1), (str2)) : PRIV(strcmp_uc_c8)((str1), (str2)))
+
+#endif /* COMPILE_PCRE[8|16|32] */
extern const pcre_uchar *PRIV(find_bracket)(const pcre_uchar *, BOOL, int);
extern BOOL PRIV(is_newline)(PCRE_PUCHAR, int, PCRE_PUCHAR,
int *, BOOL);
-extern int PRIV(ord2utf)(pcre_uint32, pcre_uchar *);
+extern unsigned int PRIV(ord2utf)(pcre_uint32, pcre_uchar *);
extern int PRIV(valid_utf)(PCRE_PUCHAR, int, int *);
extern BOOL PRIV(was_newline)(PCRE_PUCHAR, int, PCRE_PUCHAR,
int *, BOOL);
-extern BOOL PRIV(xclass)(int, const pcre_uchar *, BOOL);
+extern BOOL PRIV(xclass)(pcre_uint32, const pcre_uchar *, BOOL);
#ifdef SUPPORT_JIT
-extern void PRIV(jit_compile)(const REAL_PCRE *, PUBL(extra) *);
-extern int PRIV(jit_exec)(const REAL_PCRE *, void *,
- const pcre_uchar *, int, int, int, int, int *, int);
+extern void PRIV(jit_compile)(const REAL_PCRE *,
+ PUBL(extra) *, int);
+extern int PRIV(jit_exec)(const PUBL(extra) *,
+ const pcre_uchar *, int, int, int, int *, int);
extern void PRIV(jit_free)(void *);
extern int PRIV(jit_get_size)(void *);
extern const char* PRIV(jit_get_target)(void);
@@ -2299,15 +2705,19 @@ extern const char* PRIV(jit_get_target)(void);
/* Unicode character database (UCD) */
typedef struct {
- pcre_uint8 script;
- pcre_uint8 chartype;
- pcre_int32 other_case;
+ pcre_uint8 script; /* ucp_Arabic, etc. */
+ pcre_uint8 chartype; /* ucp_Cc, etc. (general categories) */
+ pcre_uint8 gbprop; /* ucp_gbControl, etc. (grapheme break property) */
+ pcre_uint8 caseset; /* offset to multichar other cases or zero */
+ pcre_int32 other_case; /* offset to other case, or zero if none */
} ucd_record;
+extern const pcre_uint32 PRIV(ucd_caseless_sets)[];
extern const ucd_record PRIV(ucd_records)[];
extern const pcre_uint8 PRIV(ucd_stage1)[];
extern const pcre_uint16 PRIV(ucd_stage2)[];
-extern const int PRIV(ucp_gentype)[];
+extern const pcre_uint32 PRIV(ucp_gentype)[];
+extern const pcre_uint32 PRIV(ucp_gbtable)[];
#ifdef SUPPORT_JIT
extern const int PRIV(ucp_typerange)[];
#endif
@@ -2317,13 +2727,15 @@ extern const int PRIV(ucp_typerange)[];
#define UCD_BLOCK_SIZE 128
#define GET_UCD(ch) (PRIV(ucd_records) + \
- PRIV(ucd_stage2)[PRIV(ucd_stage1)[(ch) / UCD_BLOCK_SIZE] * \
- UCD_BLOCK_SIZE + (ch) % UCD_BLOCK_SIZE])
-
-#define UCD_CHARTYPE(ch) GET_UCD(ch)->chartype
-#define UCD_SCRIPT(ch) GET_UCD(ch)->script
-#define UCD_CATEGORY(ch) PRIV(ucp_gentype)[UCD_CHARTYPE(ch)]
-#define UCD_OTHERCASE(ch) (ch + GET_UCD(ch)->other_case)
+ PRIV(ucd_stage2)[PRIV(ucd_stage1)[(int)(ch) / UCD_BLOCK_SIZE] * \
+ UCD_BLOCK_SIZE + (int)(ch) % UCD_BLOCK_SIZE])
+
+#define UCD_CHARTYPE(ch) GET_UCD(ch)->chartype
+#define UCD_SCRIPT(ch) GET_UCD(ch)->script
+#define UCD_CATEGORY(ch) PRIV(ucp_gentype)[UCD_CHARTYPE(ch)]
+#define UCD_GRAPHBREAK(ch) GET_UCD(ch)->gbprop
+#define UCD_CASESET(ch) GET_UCD(ch)->caseset
+#define UCD_OTHERCASE(ch) ((pcre_uint32)((int)ch + (int)(GET_UCD(ch)->other_case)))
#endif /* SUPPORT_UCP */
diff --git a/src/3rdparty/pcre/pcre_jit_compile.c b/src/3rdparty/pcre/pcre_jit_compile.c
index f3d240d100..78fe75d57e 100644
--- a/src/3rdparty/pcre/pcre_jit_compile.c
+++ b/src/3rdparty/pcre/pcre_jit_compile.c
@@ -46,7 +46,7 @@ POSSIBILITY OF SUCH DAMAGE.
#include "pcre_internal.h"
-#ifdef SUPPORT_JIT
+#if defined SUPPORT_JIT
/* All-in-one: Since we use the JIT compiler only from here,
we just include it. This way we don't need to touch the build
@@ -65,9 +65,12 @@ system files. */
#error Unsupported architecture
#endif
-/* Allocate memory on the stack. Fast, but limited size. */
-#define LOCAL_SPACE_SIZE 32768
+/* Allocate memory for the regex stack on the real machine stack.
+Fast, but limited size. */
+#define MACHINE_STACK_SIZE 32768
+/* Growth rate for stack allocated by the OS. Should be the multiply
+of page size. */
#define STACK_GROWTH_RATE 8192
/* Enable to check that the allocation could destroy temporaries. */
@@ -82,23 +85,23 @@ The code generator follows the recursive nature of the PERL compatible regular
expressions. The basic blocks of regular expressions are condition checkers
whose execute different commands depending on the result of the condition check.
The relationship between the operators can be horizontal (concatenation) and
-vertical (sub-expression) (See struct fallback_common for more details).
+vertical (sub-expression) (See struct backtrack_common for more details).
'ab' - 'a' and 'b' regexps are concatenated
'a+' - 'a' is the sub-expression of the '+' operator
The condition checkers are boolean (true/false) checkers. Machine code is generated
for the checker itself and for the actions depending on the result of the checker.
-The 'true' case is called as the hot path (expected path), and the other is called as
-the 'fallback' path. Branch instructions are expesive for all CPUs, so we avoid taken
-branches on the hot path.
+The 'true' case is called as the matching path (expected path), and the other is called as
+the 'backtrack' path. Branch instructions are expesive for all CPUs, so we avoid taken
+branches on the matching path.
Greedy star operator (*) :
- Hot path: match happens.
- Fallback path: match failed.
+ Matching path: match happens.
+ Backtrack path: match failed.
Non-greedy star operator (*?) :
- Hot path: no need to perform a match.
- Fallback path: match is required.
+ Matching path: no need to perform a match.
+ Backtrack path: match is required.
The following example shows how the code generated for a capturing bracket
with two alternatives. Let A, B, C, D are arbirary regular expressions, and
@@ -108,41 +111,41 @@ we have the following regular expression:
The generated code will be the following:
- A hot path
- '(' hot path (pushing arguments to the stack)
- B hot path
- ')' hot path (pushing arguments to the stack)
- D hot path
+ A matching path
+ '(' matching path (pushing arguments to the stack)
+ B matching path
+ ')' matching path (pushing arguments to the stack)
+ D matching path
return with successful match
- D fallback path
- ')' fallback path (If we arrived from "C" jump to the fallback of "C")
- B fallback path
+ D backtrack path
+ ')' backtrack path (If we arrived from "C" jump to the backtrack of "C")
+ B backtrack path
C expected path
- jump to D hot path
- C fallback path
- A fallback path
+ jump to D matching path
+ C backtrack path
+ A backtrack path
- Notice, that the order of fallback code paths are the opposite of the fast
+ Notice, that the order of backtrack code paths are the opposite of the fast
code paths. In this way the topmost value on the stack is always belong
- to the current fallback code path. The fallback code path must check
+ to the current backtrack code path. The backtrack path must check
whether there is a next alternative. If so, it needs to jump back to
- the hot path eventually. Otherwise it needs to clear out its own stack
- frame and continue the execution on the fallback code paths.
+ the matching path eventually. Otherwise it needs to clear out its own stack
+ frame and continue the execution on the backtrack code paths.
*/
/*
Saved stack frames:
-Atomic blocks and asserts require reloading the values of local variables
-when the fallback mechanism performed. Because of OP_RECURSE, the locals
+Atomic blocks and asserts require reloading the values of private data
+when the backtrack mechanism performed. Because of OP_RECURSE, the data
are not necessarly known in compile time, thus we need a dynamic restore
mechanism.
The stack frames are stored in a chain list, and have the following format:
([ capturing bracket offset ][ start value ][ end value ])+ ... [ 0 ] [ previous head ]
-Thus we can restore the locals to a particular point in the stack.
+Thus we can restore the private data to a particular point in the stack.
*/
typedef struct jit_arguments {
@@ -152,7 +155,8 @@ typedef struct jit_arguments {
const pcre_uchar *begin;
const pcre_uchar *end;
int *offsets;
- pcre_uchar *ptr;
+ pcre_uchar *uchar_ptr;
+ pcre_uchar *mark_ptr;
/* Everything else after. */
int offsetcount;
int calllimit;
@@ -162,12 +166,13 @@ typedef struct jit_arguments {
pcre_uint8 notempty_atstart;
} jit_arguments;
-typedef struct executable_function {
- void *executable_func;
+typedef struct executable_functions {
+ void *executable_funcs[JIT_NUMBER_OF_COMPILE_MODES];
PUBL(jit_callback) callback;
void *userdata;
- sljit_uw executable_size;
-} executable_function;
+ pcre_uint32 top_bracket;
+ sljit_uw executable_sizes[JIT_NUMBER_OF_COMPILE_MODES];
+} executable_functions;
typedef struct jump_list {
struct sljit_jump *jump;
@@ -180,78 +185,78 @@ typedef struct stub_list {
enum stub_types type;
int data;
struct sljit_jump *start;
- struct sljit_label *leave;
+ struct sljit_label *quit;
struct stub_list *next;
} stub_list;
typedef int (SLJIT_CALL *jit_function)(jit_arguments *args);
/* The following structure is the key data type for the recursive
-code generator. It is allocated by compile_hotpath, and contains
-the aguments for compile_fallbackpath. Must be the first member
+code generator. It is allocated by compile_matchingpath, and contains
+the aguments for compile_backtrackingpath. Must be the first member
of its descendants. */
-typedef struct fallback_common {
+typedef struct backtrack_common {
/* Concatenation stack. */
- struct fallback_common *prev;
- jump_list *nextfallbacks;
+ struct backtrack_common *prev;
+ jump_list *nextbacktracks;
/* Internal stack (for component operators). */
- struct fallback_common *top;
- jump_list *topfallbacks;
+ struct backtrack_common *top;
+ jump_list *topbacktracks;
/* Opcode pointer. */
pcre_uchar *cc;
-} fallback_common;
+} backtrack_common;
-typedef struct assert_fallback {
- fallback_common common;
+typedef struct assert_backtrack {
+ backtrack_common common;
jump_list *condfailed;
/* Less than 0 (-1) if a frame is not needed. */
int framesize;
/* Points to our private memory word on the stack. */
- int localptr;
+ int private_data_ptr;
/* For iterators. */
- struct sljit_label *hotpath;
-} assert_fallback;
+ struct sljit_label *matchingpath;
+} assert_backtrack;
-typedef struct bracket_fallback {
- fallback_common common;
+typedef struct bracket_backtrack {
+ backtrack_common common;
/* Where to coninue if an alternative is successfully matched. */
- struct sljit_label *althotpath;
+ struct sljit_label *alternative_matchingpath;
/* For rmin and rmax iterators. */
- struct sljit_label *recursivehotpath;
+ struct sljit_label *recursive_matchingpath;
/* For greedy ? operator. */
- struct sljit_label *zerohotpath;
+ struct sljit_label *zero_matchingpath;
/* Contains the branches of a failed condition. */
union {
/* Both for OP_COND, OP_SCOND. */
jump_list *condfailed;
- assert_fallback *assert;
+ assert_backtrack *assert;
/* For OP_ONCE. -1 if not needed. */
int framesize;
} u;
/* Points to our private memory word on the stack. */
- int localptr;
-} bracket_fallback;
+ int private_data_ptr;
+} bracket_backtrack;
-typedef struct bracketpos_fallback {
- fallback_common common;
+typedef struct bracketpos_backtrack {
+ backtrack_common common;
/* Points to our private memory word on the stack. */
- int localptr;
+ int private_data_ptr;
/* Reverting stack is needed. */
int framesize;
/* Allocated stack size. */
int stacksize;
-} bracketpos_fallback;
+} bracketpos_backtrack;
-typedef struct braminzero_fallback {
- fallback_common common;
- struct sljit_label *hotpath;
-} braminzero_fallback;
+typedef struct braminzero_backtrack {
+ backtrack_common common;
+ struct sljit_label *matchingpath;
+} braminzero_backtrack;
-typedef struct iterator_fallback {
- fallback_common common;
+typedef struct iterator_backtrack {
+ backtrack_common common;
/* Next iteration. */
- struct sljit_label *hotpath;
-} iterator_fallback;
+ struct sljit_label *matchingpath;
+} iterator_backtrack;
typedef struct recurse_entry {
struct recurse_entry *next;
@@ -263,30 +268,66 @@ typedef struct recurse_entry {
int start;
} recurse_entry;
-typedef struct recurse_fallback {
- fallback_common common;
-} recurse_fallback;
+typedef struct recurse_backtrack {
+ backtrack_common common;
+} recurse_backtrack;
+
+#define MAX_RANGE_SIZE 6
typedef struct compiler_common {
struct sljit_compiler *compiler;
pcre_uchar *start;
- int localsize;
- int *localptrs;
- const pcre_uint8 *fcc;
- sljit_w lcc;
+
+ /* Maps private data offset to each opcode. */
+ int *private_data_ptrs;
+ /* Tells whether the capturing bracket is optimized. */
+ pcre_uint8 *optimized_cbracket;
+ /* Starting offset of private data for capturing brackets. */
int cbraptr;
+ /* OVector starting point. Must be divisible by 2. */
+ int ovector_start;
+ /* Last known position of the requested byte. */
+ int req_char_ptr;
+ /* Head of the last recursion. */
+ int recursive_head;
+ /* First inspected character for partial matching. */
+ int start_used_ptr;
+ /* Starting pointer for partial soft matches. */
+ int hit_start;
+ /* End pointer of the first line. */
+ int first_line_end;
+ /* Points to the marked string. */
+ int mark_ptr;
+
+ /* Flipped and lower case tables. */
+ const pcre_uint8 *fcc;
+ sljit_sw lcc;
+ /* Mode can be PCRE_STUDY_JIT_COMPILE and others. */
+ int mode;
+ /* Newline control. */
int nltype;
int newline;
int bsr_nltype;
+ /* Dollar endonly. */
int endonly;
- sljit_w ctypes;
+ BOOL has_set_som;
+ /* Tables. */
+ sljit_sw ctypes;
+ int digits[2 + MAX_RANGE_SIZE];
+ /* Named capturing brackets. */
sljit_uw name_table;
- sljit_w name_count;
- sljit_w name_entry_size;
+ sljit_sw name_count;
+ sljit_sw name_entry_size;
+
+ /* Labels and jump lists. */
+ struct sljit_label *partialmatchlabel;
+ struct sljit_label *quitlabel;
struct sljit_label *acceptlabel;
stub_list *stubs;
recurse_entry *entries;
recurse_entry *currententry;
+ jump_list *partialmatch;
+ jump_list *quit;
jump_list *accept;
jump_list *calllimit;
jump_list *stackalloc;
@@ -303,7 +344,9 @@ typedef struct compiler_common {
#ifdef SUPPORT_UCP
BOOL use_ucp;
#endif
+#ifndef COMPILE_PCRE32
jump_list *utfreadchar;
+#endif
#ifdef COMPILE_PCRE8
jump_list *utfreadtype8;
#endif
@@ -321,27 +364,27 @@ typedef struct compare_context {
#if defined SLJIT_UNALIGNED && SLJIT_UNALIGNED
int ucharptr;
union {
- sljit_i asint;
+ sljit_si asint;
sljit_uh asushort;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
sljit_ub asbyte;
sljit_ub asuchars[4];
-#else
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
sljit_uh asuchars[2];
-#endif
+#elif defined COMPILE_PCRE32
+ sljit_ui asuchars[1];
#endif
} c;
union {
- sljit_i asint;
+ sljit_si asint;
sljit_uh asushort;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
sljit_ub asbyte;
sljit_ub asuchars[4];
-#else
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
sljit_uh asuchars[2];
-#endif
+#elif defined COMPILE_PCRE32
+ sljit_ui asuchars[1];
#endif
} oc;
#endif
@@ -349,61 +392,57 @@ typedef struct compare_context {
enum {
frame_end = 0,
- frame_setstrbegin = -1
+ frame_setstrbegin = -1,
+ frame_setmark = -2
};
/* Undefine sljit macros. */
#undef CMP
/* Used for accessing the elements of the stack. */
-#define STACK(i) ((-(i) - 1) * (int)sizeof(sljit_w))
+#define STACK(i) ((-(i) - 1) * (int)sizeof(sljit_sw))
-#define TMP1 SLJIT_TEMPORARY_REG1
-#define TMP2 SLJIT_TEMPORARY_REG3
+#define TMP1 SLJIT_SCRATCH_REG1
+#define TMP2 SLJIT_SCRATCH_REG3
#define TMP3 SLJIT_TEMPORARY_EREG2
#define STR_PTR SLJIT_SAVED_REG1
#define STR_END SLJIT_SAVED_REG2
-#define STACK_TOP SLJIT_TEMPORARY_REG2
+#define STACK_TOP SLJIT_SCRATCH_REG2
#define STACK_LIMIT SLJIT_SAVED_REG3
#define ARGUMENTS SLJIT_SAVED_EREG1
#define CALL_COUNT SLJIT_SAVED_EREG2
#define RETURN_ADDR SLJIT_TEMPORARY_EREG1
-/* Locals layout. */
+/* Local space layout. */
/* These two locals can be used by the current opcode. */
-#define LOCALS0 (0 * sizeof(sljit_w))
-#define LOCALS1 (1 * sizeof(sljit_w))
+#define LOCALS0 (0 * sizeof(sljit_sw))
+#define LOCALS1 (1 * sizeof(sljit_sw))
/* Two local variables for possessive quantifiers (char1 cannot use them). */
-#define POSSESSIVE0 (2 * sizeof(sljit_w))
-#define POSSESSIVE1 (3 * sizeof(sljit_w))
-/* Head of the last recursion. */
-#define RECURSIVE_HEAD (4 * sizeof(sljit_w))
+#define POSSESSIVE0 (2 * sizeof(sljit_sw))
+#define POSSESSIVE1 (3 * sizeof(sljit_sw))
/* Max limit of recursions. */
-#define CALL_LIMIT (5 * sizeof(sljit_w))
-/* Last known position of the requested byte. */
-#define REQ_CHAR_PTR (6 * sizeof(sljit_w))
-/* End pointer of the first line. */
-#define FIRSTLINE_END (7 * sizeof(sljit_w))
+#define CALL_LIMIT (4 * sizeof(sljit_sw))
/* The output vector is stored on the stack, and contains pointers
to characters. The vector data is divided into two groups: the first
group contains the start / end character pointers, and the second is
the start pointers when the end of the capturing group has not yet reached. */
-#define OVECTOR_START (8 * sizeof(sljit_w))
-#define OVECTOR(i) (OVECTOR_START + (i) * sizeof(sljit_w))
-#define OVECTOR_PRIV(i) (common->cbraptr + (i) * sizeof(sljit_w))
-#define PRIV_DATA(cc) (common->localptrs[(cc) - common->start])
+#define OVECTOR_START (common->ovector_start)
+#define OVECTOR(i) (OVECTOR_START + (i) * sizeof(sljit_sw))
+#define OVECTOR_PRIV(i) (common->cbraptr + (i) * sizeof(sljit_sw))
+#define PRIVATE_DATA(cc) (common->private_data_ptrs[(cc) - common->start])
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
#define MOV_UCHAR SLJIT_MOV_UB
#define MOVU_UCHAR SLJIT_MOVU_UB
-#else
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
#define MOV_UCHAR SLJIT_MOV_UH
#define MOVU_UCHAR SLJIT_MOVU_UH
+#elif defined COMPILE_PCRE32
+#define MOV_UCHAR SLJIT_MOV_UI
+#define MOVU_UCHAR SLJIT_MOVU_UI
#else
#error Unsupported compiling mode
#endif
-#endif
/* Shortcuts. */
#define DEFINE_COMPILER \
@@ -424,8 +463,10 @@ the start pointers when the end of the capturing group has not yet reached. */
sljit_emit_cmp(compiler, (type), (src1), (src1w), (src2), (src2w))
#define CMPTO(type, src1, src1w, src2, src2w, label) \
sljit_set_label(sljit_emit_cmp(compiler, (type), (src1), (src1w), (src2), (src2w)), (label))
-#define COND_VALUE(op, dst, dstw, type) \
- sljit_emit_cond_value(compiler, (op), (dst), (dstw), (type))
+#define OP_FLAGS(op, dst, dstw, src, srcw, type) \
+ sljit_emit_op_flags(compiler, (op), (dst), (dstw), (src), (srcw), (type))
+#define GET_LOCAL_BASE(dst, dstw, offset) \
+ sljit_get_local_base(compiler, (dst), (dstw), (offset))
static pcre_uchar* bracketend(pcre_uchar* cc)
{
@@ -438,14 +479,14 @@ return cc;
/* Functions whose might need modification for all new supported opcodes:
next_opcode
- get_localspace
- set_localptrs
+ get_private_data_length
+ set_private_data_ptrs
get_framesize
init_frame
- get_localsize
- copy_locals
- compile_hotpath
- compile_fallbackpath
+ get_private_data_length_for_copy
+ copy_private_data
+ compile_matchingpath
+ compile_backtrackingpath
*/
static pcre_uchar *next_opcode(compiler_common *common, pcre_uchar *cc)
@@ -497,6 +538,7 @@ switch(*cc)
case OP_BRAZERO:
case OP_BRAMINZERO:
case OP_BRAPOSZERO:
+ case OP_COMMIT:
case OP_FAIL:
case OP_ACCEPT:
case OP_ASSERT_ACCEPT:
@@ -635,20 +677,119 @@ switch(*cc)
case OP_SCBRAPOS:
return cc + 1 + LINK_SIZE + IMM2_SIZE;
+ case OP_MARK:
+ return cc + 1 + 2 + cc[1];
+
default:
return NULL;
}
}
-static int get_localspace(compiler_common *common, pcre_uchar *cc, pcre_uchar *ccend)
+#define CASE_ITERATOR_PRIVATE_DATA_1 \
+ case OP_MINSTAR: \
+ case OP_MINPLUS: \
+ case OP_QUERY: \
+ case OP_MINQUERY: \
+ case OP_MINSTARI: \
+ case OP_MINPLUSI: \
+ case OP_QUERYI: \
+ case OP_MINQUERYI: \
+ case OP_NOTMINSTAR: \
+ case OP_NOTMINPLUS: \
+ case OP_NOTQUERY: \
+ case OP_NOTMINQUERY: \
+ case OP_NOTMINSTARI: \
+ case OP_NOTMINPLUSI: \
+ case OP_NOTQUERYI: \
+ case OP_NOTMINQUERYI:
+
+#define CASE_ITERATOR_PRIVATE_DATA_2A \
+ case OP_STAR: \
+ case OP_PLUS: \
+ case OP_STARI: \
+ case OP_PLUSI: \
+ case OP_NOTSTAR: \
+ case OP_NOTPLUS: \
+ case OP_NOTSTARI: \
+ case OP_NOTPLUSI:
+
+#define CASE_ITERATOR_PRIVATE_DATA_2B \
+ case OP_UPTO: \
+ case OP_MINUPTO: \
+ case OP_UPTOI: \
+ case OP_MINUPTOI: \
+ case OP_NOTUPTO: \
+ case OP_NOTMINUPTO: \
+ case OP_NOTUPTOI: \
+ case OP_NOTMINUPTOI:
+
+#define CASE_ITERATOR_TYPE_PRIVATE_DATA_1 \
+ case OP_TYPEMINSTAR: \
+ case OP_TYPEMINPLUS: \
+ case OP_TYPEQUERY: \
+ case OP_TYPEMINQUERY:
+
+#define CASE_ITERATOR_TYPE_PRIVATE_DATA_2A \
+ case OP_TYPESTAR: \
+ case OP_TYPEPLUS:
+
+#define CASE_ITERATOR_TYPE_PRIVATE_DATA_2B \
+ case OP_TYPEUPTO: \
+ case OP_TYPEMINUPTO:
+
+static int get_class_iterator_size(pcre_uchar *cc)
+{
+switch(*cc)
+ {
+ case OP_CRSTAR:
+ case OP_CRPLUS:
+ return 2;
+
+ case OP_CRMINSTAR:
+ case OP_CRMINPLUS:
+ case OP_CRQUERY:
+ case OP_CRMINQUERY:
+ return 1;
+
+ case OP_CRRANGE:
+ case OP_CRMINRANGE:
+ if (GET2(cc, 1) == GET2(cc, 1 + IMM2_SIZE))
+ return 0;
+ return 2;
+
+ default:
+ return 0;
+ }
+}
+
+static int get_private_data_length(compiler_common *common, pcre_uchar *cc, pcre_uchar *ccend)
{
-int localspace = 0;
+int private_data_length = 0;
pcre_uchar *alternative;
+pcre_uchar *name;
+pcre_uchar *end = NULL;
+int space, size, i;
+pcre_uint32 bracketlen;
+
/* Calculate important variables (like stack size) and checks whether all opcodes are supported. */
while (cc < ccend)
{
+ space = 0;
+ size = 0;
+ bracketlen = 0;
switch(*cc)
{
+ case OP_SET_SOM:
+ common->has_set_som = TRUE;
+ cc += 1;
+ break;
+
+ case OP_REF:
+ case OP_REFI:
+ common->optimized_cbracket[GET2(cc, 1)] = 0;
+ cc += 1 + IMM2_SIZE;
+ break;
+
case OP_ASSERT:
case OP_ASSERT_NOT:
case OP_ASSERTBACK:
@@ -658,41 +799,179 @@ while (cc < ccend)
case OP_BRAPOS:
case OP_SBRA:
case OP_SBRAPOS:
- case OP_SCOND:
- localspace += sizeof(sljit_w);
- cc += 1 + LINK_SIZE;
+ private_data_length += sizeof(sljit_sw);
+ bracketlen = 1 + LINK_SIZE;
break;
case OP_CBRAPOS:
case OP_SCBRAPOS:
- localspace += sizeof(sljit_w);
- cc += 1 + LINK_SIZE + IMM2_SIZE;
+ private_data_length += sizeof(sljit_sw);
+ common->optimized_cbracket[GET2(cc, 1 + LINK_SIZE)] = 0;
+ bracketlen = 1 + LINK_SIZE + IMM2_SIZE;
break;
case OP_COND:
- /* Might be a hidden SCOND. */
- alternative = cc + GET(cc, 1);
- if (*alternative == OP_KETRMAX || *alternative == OP_KETRMIN)
- localspace += sizeof(sljit_w);
+ case OP_SCOND:
+ bracketlen = cc[1 + LINK_SIZE];
+ if (bracketlen == OP_CREF)
+ {
+ bracketlen = GET2(cc, 1 + LINK_SIZE + 1);
+ common->optimized_cbracket[bracketlen] = 0;
+ }
+ else if (bracketlen == OP_NCREF)
+ {
+ bracketlen = GET2(cc, 1 + LINK_SIZE + 1);
+ name = (pcre_uchar *)common->name_table;
+ alternative = name;
+ for (i = 0; i < common->name_count; i++)
+ {
+ if (GET2(name, 0) == bracketlen) break;
+ name += common->name_entry_size;
+ }
+ SLJIT_ASSERT(i != common->name_count);
+
+ for (i = 0; i < common->name_count; i++)
+ {
+ if (STRCMP_UC_UC(alternative + IMM2_SIZE, name + IMM2_SIZE) == 0)
+ common->optimized_cbracket[GET2(alternative, 0)] = 0;
+ alternative += common->name_entry_size;
+ }
+ }
+
+ if (*cc == OP_COND)
+ {
+ /* Might be a hidden SCOND. */
+ alternative = cc + GET(cc, 1);
+ if (*alternative == OP_KETRMAX || *alternative == OP_KETRMIN)
+ private_data_length += sizeof(sljit_sw);
+ }
+ else
+ private_data_length += sizeof(sljit_sw);
+ bracketlen = 1 + LINK_SIZE;
+ break;
+
+ case OP_BRA:
+ bracketlen = 1 + LINK_SIZE;
+ break;
+
+ case OP_CBRA:
+ case OP_SCBRA:
+ bracketlen = 1 + LINK_SIZE + IMM2_SIZE;
+ break;
+
+ CASE_ITERATOR_PRIVATE_DATA_1
+ space = 1;
+ size = -2;
+ break;
+
+ CASE_ITERATOR_PRIVATE_DATA_2A
+ space = 2;
+ size = -2;
+ break;
+
+ CASE_ITERATOR_PRIVATE_DATA_2B
+ space = 2;
+ size = -(2 + IMM2_SIZE);
+ break;
+
+ CASE_ITERATOR_TYPE_PRIVATE_DATA_1
+ space = 1;
+ size = 1;
+ break;
+
+ CASE_ITERATOR_TYPE_PRIVATE_DATA_2A
+ if (cc[1] != OP_ANYNL && cc[1] != OP_EXTUNI)
+ space = 2;
+ size = 1;
+ break;
+
+ CASE_ITERATOR_TYPE_PRIVATE_DATA_2B
+ if (cc[1 + IMM2_SIZE] != OP_ANYNL && cc[1 + IMM2_SIZE] != OP_EXTUNI)
+ space = 2;
+ size = 1 + IMM2_SIZE;
+ break;
+
+ case OP_CLASS:
+ case OP_NCLASS:
+ size += 1 + 32 / sizeof(pcre_uchar);
+ space = get_class_iterator_size(cc + size);
+ break;
+
+#if defined SUPPORT_UTF || !defined COMPILE_PCRE8
+ case OP_XCLASS:
+ size = GET(cc, 1);
+ space = get_class_iterator_size(cc + size);
+ break;
+#endif
+
+ case OP_RECURSE:
+ /* Set its value only once. */
+ if (common->recursive_head == 0)
+ {
+ common->recursive_head = common->ovector_start;
+ common->ovector_start += sizeof(sljit_sw);
+ }
cc += 1 + LINK_SIZE;
break;
+ case OP_MARK:
+ if (common->mark_ptr == 0)
+ {
+ common->mark_ptr = common->ovector_start;
+ common->ovector_start += sizeof(sljit_sw);
+ }
+ cc += 1 + 2 + cc[1];
+ break;
+
default:
cc = next_opcode(common, cc);
if (cc == NULL)
return -1;
break;
}
+
+ if (space > 0 && cc >= end)
+ private_data_length += sizeof(sljit_sw) * space;
+
+ if (size != 0)
+ {
+ if (size < 0)
+ {
+ cc += -size;
+#ifdef SUPPORT_UTF
+ if (common->utf && HAS_EXTRALEN(cc[-1])) cc += GET_EXTRALEN(cc[-1]);
+#endif
+ }
+ else
+ cc += size;
+ }
+
+ if (bracketlen != 0)
+ {
+ if (cc >= end)
+ {
+ end = bracketend(cc);
+ if (end[-1 - LINK_SIZE] == OP_KET)
+ end = NULL;
+ }
+ cc += bracketlen;
+ }
}
-return localspace;
+return private_data_length;
}
-static void set_localptrs(compiler_common *common, int localptr, pcre_uchar *ccend)
+static void set_private_data_ptrs(compiler_common *common, int private_data_ptr, pcre_uchar *ccend)
{
pcre_uchar *cc = common->start;
pcre_uchar *alternative;
+pcre_uchar *end = NULL;
+int space, size, bracketlen;
+
while (cc < ccend)
{
+ space = 0;
+ size = 0;
+ bracketlen = 0;
switch(*cc)
{
case OP_ASSERT:
@@ -705,16 +984,16 @@ while (cc < ccend)
case OP_SBRA:
case OP_SBRAPOS:
case OP_SCOND:
- common->localptrs[cc - common->start] = localptr;
- localptr += sizeof(sljit_w);
- cc += 1 + LINK_SIZE;
+ common->private_data_ptrs[cc - common->start] = private_data_ptr;
+ private_data_ptr += sizeof(sljit_sw);
+ bracketlen = 1 + LINK_SIZE;
break;
case OP_CBRAPOS:
case OP_SCBRAPOS:
- common->localptrs[cc - common->start] = localptr;
- localptr += sizeof(sljit_w);
- cc += 1 + LINK_SIZE + IMM2_SIZE;
+ common->private_data_ptrs[cc - common->start] = private_data_ptr;
+ private_data_ptr += sizeof(sljit_sw);
+ bracketlen = 1 + LINK_SIZE + IMM2_SIZE;
break;
case OP_COND:
@@ -722,17 +1001,101 @@ while (cc < ccend)
alternative = cc + GET(cc, 1);
if (*alternative == OP_KETRMAX || *alternative == OP_KETRMIN)
{
- common->localptrs[cc - common->start] = localptr;
- localptr += sizeof(sljit_w);
+ common->private_data_ptrs[cc - common->start] = private_data_ptr;
+ private_data_ptr += sizeof(sljit_sw);
}
- cc += 1 + LINK_SIZE;
+ bracketlen = 1 + LINK_SIZE;
+ break;
+
+ case OP_BRA:
+ bracketlen = 1 + LINK_SIZE;
+ break;
+
+ case OP_CBRA:
+ case OP_SCBRA:
+ bracketlen = 1 + LINK_SIZE + IMM2_SIZE;
+ break;
+
+ CASE_ITERATOR_PRIVATE_DATA_1
+ space = 1;
+ size = -2;
+ break;
+
+ CASE_ITERATOR_PRIVATE_DATA_2A
+ space = 2;
+ size = -2;
+ break;
+
+ CASE_ITERATOR_PRIVATE_DATA_2B
+ space = 2;
+ size = -(2 + IMM2_SIZE);
+ break;
+
+ CASE_ITERATOR_TYPE_PRIVATE_DATA_1
+ space = 1;
+ size = 1;
+ break;
+
+ CASE_ITERATOR_TYPE_PRIVATE_DATA_2A
+ if (cc[1] != OP_ANYNL && cc[1] != OP_EXTUNI)
+ space = 2;
+ size = 1;
break;
+ CASE_ITERATOR_TYPE_PRIVATE_DATA_2B
+ if (cc[1 + IMM2_SIZE] != OP_ANYNL && cc[1 + IMM2_SIZE] != OP_EXTUNI)
+ space = 2;
+ size = 1 + IMM2_SIZE;
+ break;
+
+ case OP_CLASS:
+ case OP_NCLASS:
+ size += 1 + 32 / sizeof(pcre_uchar);
+ space = get_class_iterator_size(cc + size);
+ break;
+
+#if defined SUPPORT_UTF || !defined COMPILE_PCRE8
+ case OP_XCLASS:
+ size = GET(cc, 1);
+ space = get_class_iterator_size(cc + size);
+ break;
+#endif
+
default:
cc = next_opcode(common, cc);
SLJIT_ASSERT(cc != NULL);
break;
}
+
+ if (space > 0 && cc >= end)
+ {
+ common->private_data_ptrs[cc - common->start] = private_data_ptr;
+ private_data_ptr += sizeof(sljit_sw) * space;
+ }
+
+ if (size != 0)
+ {
+ if (size < 0)
+ {
+ cc += -size;
+#ifdef SUPPORT_UTF
+ if (common->utf && HAS_EXTRALEN(cc[-1])) cc += GET_EXTRALEN(cc[-1]);
+#endif
+ }
+ else
+ cc += size;
+ }
+
+ if (bracketlen > 0)
+ {
+ if (cc >= end)
+ {
+ end = bracketend(cc);
+ if (end[-1 - LINK_SIZE] == OP_KET)
+ end = NULL;
+ }
+ cc += bracketlen;
+ }
}
}
@@ -742,7 +1105,8 @@ static int get_framesize(compiler_common *common, pcre_uchar *cc, BOOL recursive
pcre_uchar *ccend = bracketend(cc);
int length = 0;
BOOL possessive = FALSE;
-BOOL setsom_found = FALSE;
+BOOL setsom_found = recursive;
+BOOL setmark_found = recursive;
if (!recursive && (*cc == OP_CBRAPOS || *cc == OP_SCBRAPOS))
{
@@ -756,13 +1120,37 @@ while (cc < ccend)
switch(*cc)
{
case OP_SET_SOM:
- case OP_RECURSE:
+ SLJIT_ASSERT(common->has_set_som);
if (!setsom_found)
{
length += 2;
setsom_found = TRUE;
}
- cc += (*cc == OP_SET_SOM) ? 1 : 1 + LINK_SIZE;
+ cc += 1;
+ break;
+
+ case OP_MARK:
+ SLJIT_ASSERT(common->mark_ptr != 0);
+ if (!setmark_found)
+ {
+ length += 2;
+ setmark_found = TRUE;
+ }
+ cc += 1 + 2 + cc[1];
+ break;
+
+ case OP_RECURSE:
+ if (common->has_set_som && !setsom_found)
+ {
+ length += 2;
+ setsom_found = TRUE;
+ }
+ if (common->mark_ptr != 0 && !setmark_found)
+ {
+ length += 2;
+ setmark_found = TRUE;
+ }
+ cc += 1 + LINK_SIZE;
break;
case OP_CBRA:
@@ -792,7 +1180,8 @@ static void init_frame(compiler_common *common, pcre_uchar *cc, int stackpos, in
{
DEFINE_COMPILER;
pcre_uchar *ccend = bracketend(cc);
-BOOL setsom_found = FALSE;
+BOOL setsom_found = recursive;
+BOOL setmark_found = recursive;
int offset;
/* >= 1 + shortest item size (2) */
@@ -807,17 +1196,53 @@ while (cc < ccend)
switch(*cc)
{
case OP_SET_SOM:
- case OP_RECURSE:
+ SLJIT_ASSERT(common->has_set_som);
if (!setsom_found)
{
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0));
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackpos, SLJIT_IMM, frame_setstrbegin);
- stackpos += (int)sizeof(sljit_w);
+ stackpos += (int)sizeof(sljit_sw);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackpos, TMP1, 0);
- stackpos += (int)sizeof(sljit_w);
+ stackpos += (int)sizeof(sljit_sw);
setsom_found = TRUE;
}
- cc += (*cc == OP_SET_SOM) ? 1 : 1 + LINK_SIZE;
+ cc += 1;
+ break;
+
+ case OP_MARK:
+ SLJIT_ASSERT(common->mark_ptr != 0);
+ if (!setmark_found)
+ {
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->mark_ptr);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackpos, SLJIT_IMM, frame_setmark);
+ stackpos += (int)sizeof(sljit_sw);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackpos, TMP1, 0);
+ stackpos += (int)sizeof(sljit_sw);
+ setmark_found = TRUE;
+ }
+ cc += 1 + 2 + cc[1];
+ break;
+
+ case OP_RECURSE:
+ if (common->has_set_som && !setsom_found)
+ {
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0));
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackpos, SLJIT_IMM, frame_setstrbegin);
+ stackpos += (int)sizeof(sljit_sw);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackpos, TMP1, 0);
+ stackpos += (int)sizeof(sljit_sw);
+ setsom_found = TRUE;
+ }
+ if (common->mark_ptr != 0 && !setmark_found)
+ {
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->mark_ptr);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackpos, SLJIT_IMM, frame_setmark);
+ stackpos += (int)sizeof(sljit_sw);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackpos, TMP1, 0);
+ stackpos += (int)sizeof(sljit_sw);
+ setmark_found = TRUE;
+ }
+ cc += 1 + LINK_SIZE;
break;
case OP_CBRA:
@@ -826,13 +1251,13 @@ while (cc < ccend)
case OP_SCBRAPOS:
offset = (GET2(cc, 1 + LINK_SIZE)) << 1;
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackpos, SLJIT_IMM, OVECTOR(offset));
- stackpos += (int)sizeof(sljit_w);
+ stackpos += (int)sizeof(sljit_sw);
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset));
OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1));
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackpos, TMP1, 0);
- stackpos += (int)sizeof(sljit_w);
+ stackpos += (int)sizeof(sljit_sw);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackpos, TMP2, 0);
- stackpos += (int)sizeof(sljit_w);
+ stackpos += (int)sizeof(sljit_sw);
cc += 1 + LINK_SIZE + IMM2_SIZE;
break;
@@ -847,13 +1272,15 @@ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackpos, SLJIT_IMM, frame_end);
SLJIT_ASSERT(stackpos == STACK(stacktop));
}
-static SLJIT_INLINE int get_localsize(compiler_common *common, pcre_uchar *cc, pcre_uchar *ccend)
+static SLJIT_INLINE int get_private_data_length_for_copy(compiler_common *common, pcre_uchar *cc, pcre_uchar *ccend)
{
-int localsize = 2;
+int private_data_length = 2;
+int size;
pcre_uchar *alternative;
-/* Calculate the sum of the local variables. */
+/* Calculate the sum of the private machine words. */
while (cc < ccend)
{
+ size = 0;
switch(*cc)
{
case OP_ASSERT:
@@ -866,19 +1293,20 @@ while (cc < ccend)
case OP_SBRA:
case OP_SBRAPOS:
case OP_SCOND:
- localsize++;
+ private_data_length++;
cc += 1 + LINK_SIZE;
break;
case OP_CBRA:
case OP_SCBRA:
- localsize++;
+ if (common->optimized_cbracket[GET2(cc, 1 + LINK_SIZE)] == 0)
+ private_data_length++;
cc += 1 + LINK_SIZE + IMM2_SIZE;
break;
case OP_CBRAPOS:
case OP_SCBRAPOS:
- localsize += 2;
+ private_data_length += 2;
cc += 1 + LINK_SIZE + IMM2_SIZE;
break;
@@ -886,10 +1314,68 @@ while (cc < ccend)
/* Might be a hidden SCOND. */
alternative = cc + GET(cc, 1);
if (*alternative == OP_KETRMAX || *alternative == OP_KETRMIN)
- localsize++;
+ private_data_length++;
cc += 1 + LINK_SIZE;
break;
+ CASE_ITERATOR_PRIVATE_DATA_1
+ if (PRIVATE_DATA(cc))
+ private_data_length++;
+ cc += 2;
+#ifdef SUPPORT_UTF
+ if (common->utf && HAS_EXTRALEN(cc[-1])) cc += GET_EXTRALEN(cc[-1]);
+#endif
+ break;
+
+ CASE_ITERATOR_PRIVATE_DATA_2A
+ if (PRIVATE_DATA(cc))
+ private_data_length += 2;
+ cc += 2;
+#ifdef SUPPORT_UTF
+ if (common->utf && HAS_EXTRALEN(cc[-1])) cc += GET_EXTRALEN(cc[-1]);
+#endif
+ break;
+
+ CASE_ITERATOR_PRIVATE_DATA_2B
+ if (PRIVATE_DATA(cc))
+ private_data_length += 2;
+ cc += 2 + IMM2_SIZE;
+#ifdef SUPPORT_UTF
+ if (common->utf && HAS_EXTRALEN(cc[-1])) cc += GET_EXTRALEN(cc[-1]);
+#endif
+ break;
+
+ CASE_ITERATOR_TYPE_PRIVATE_DATA_1
+ if (PRIVATE_DATA(cc))
+ private_data_length++;
+ cc += 1;
+ break;
+
+ CASE_ITERATOR_TYPE_PRIVATE_DATA_2A
+ if (PRIVATE_DATA(cc))
+ private_data_length += 2;
+ cc += 1;
+ break;
+
+ CASE_ITERATOR_TYPE_PRIVATE_DATA_2B
+ if (PRIVATE_DATA(cc))
+ private_data_length += 2;
+ cc += 1 + IMM2_SIZE;
+ break;
+
+ case OP_CLASS:
+ case OP_NCLASS:
+#if defined SUPPORT_UTF || !defined COMPILE_PCRE8
+ case OP_XCLASS:
+ size = (*cc == OP_XCLASS) ? GET(cc, 1) : 1 + 32 / (int)sizeof(pcre_uchar);
+#else
+ size = 1 + 32 / (int)sizeof(pcre_uchar);
+#endif
+ if (PRIVATE_DATA(cc))
+ private_data_length += get_class_iterator_size(cc + size);
+ cc += size;
+ break;
+
default:
cc = next_opcode(common, cc);
SLJIT_ASSERT(cc != NULL);
@@ -897,15 +1383,15 @@ while (cc < ccend)
}
}
SLJIT_ASSERT(cc == ccend);
-return localsize;
+return private_data_length;
}
-static void copy_locals(compiler_common *common, pcre_uchar *cc, pcre_uchar *ccend,
+static void copy_private_data(compiler_common *common, pcre_uchar *cc, pcre_uchar *ccend,
BOOL save, int stackptr, int stacktop)
{
DEFINE_COMPILER;
int srcw[2];
-int count;
+int count, size;
BOOL tmp1next = TRUE;
BOOL tmp1empty = TRUE;
BOOL tmp2empty = TRUE;
@@ -922,17 +1408,17 @@ stacktop = STACK(stacktop - 1);
if (!save)
{
- stackptr += sizeof(sljit_w);
+ stackptr += sizeof(sljit_sw);
if (stackptr < stacktop)
{
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), stackptr);
- stackptr += sizeof(sljit_w);
+ stackptr += sizeof(sljit_sw);
tmp1empty = FALSE;
}
if (stackptr < stacktop)
{
OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(STACK_TOP), stackptr);
- stackptr += sizeof(sljit_w);
+ stackptr += sizeof(sljit_sw);
tmp2empty = FALSE;
}
/* The tmp1next must be TRUE in either way. */
@@ -944,9 +1430,9 @@ while (status != end)
switch(status)
{
case start:
- SLJIT_ASSERT(save);
+ SLJIT_ASSERT(save && common->recursive_head != 0);
count = 1;
- srcw[0] = RECURSIVE_HEAD;
+ srcw[0] = common->recursive_head;
status = loop;
break;
@@ -970,24 +1456,27 @@ while (status != end)
case OP_SBRAPOS:
case OP_SCOND:
count = 1;
- srcw[0] = PRIV_DATA(cc);
+ srcw[0] = PRIVATE_DATA(cc);
SLJIT_ASSERT(srcw[0] != 0);
cc += 1 + LINK_SIZE;
break;
case OP_CBRA:
case OP_SCBRA:
- count = 1;
- srcw[0] = OVECTOR_PRIV(GET2(cc, 1 + LINK_SIZE));
+ if (common->optimized_cbracket[GET2(cc, 1 + LINK_SIZE)] == 0)
+ {
+ count = 1;
+ srcw[0] = OVECTOR_PRIV(GET2(cc, 1 + LINK_SIZE));
+ }
cc += 1 + LINK_SIZE + IMM2_SIZE;
break;
case OP_CBRAPOS:
case OP_SCBRAPOS:
count = 2;
+ srcw[0] = PRIVATE_DATA(cc);
srcw[1] = OVECTOR_PRIV(GET2(cc, 1 + LINK_SIZE));
- srcw[0] = PRIV_DATA(cc);
- SLJIT_ASSERT(srcw[0] != 0);
+ SLJIT_ASSERT(srcw[0] != 0 && srcw[1] != 0);
cc += 1 + LINK_SIZE + IMM2_SIZE;
break;
@@ -997,12 +1486,108 @@ while (status != end)
if (*alternative == OP_KETRMAX || *alternative == OP_KETRMIN)
{
count = 1;
- srcw[0] = PRIV_DATA(cc);
+ srcw[0] = PRIVATE_DATA(cc);
SLJIT_ASSERT(srcw[0] != 0);
}
cc += 1 + LINK_SIZE;
break;
+ CASE_ITERATOR_PRIVATE_DATA_1
+ if (PRIVATE_DATA(cc))
+ {
+ count = 1;
+ srcw[0] = PRIVATE_DATA(cc);
+ }
+ cc += 2;
+#ifdef SUPPORT_UTF
+ if (common->utf && HAS_EXTRALEN(cc[-1])) cc += GET_EXTRALEN(cc[-1]);
+#endif
+ break;
+
+ CASE_ITERATOR_PRIVATE_DATA_2A
+ if (PRIVATE_DATA(cc))
+ {
+ count = 2;
+ srcw[0] = PRIVATE_DATA(cc);
+ srcw[1] = PRIVATE_DATA(cc) + sizeof(sljit_sw);
+ }
+ cc += 2;
+#ifdef SUPPORT_UTF
+ if (common->utf && HAS_EXTRALEN(cc[-1])) cc += GET_EXTRALEN(cc[-1]);
+#endif
+ break;
+
+ CASE_ITERATOR_PRIVATE_DATA_2B
+ if (PRIVATE_DATA(cc))
+ {
+ count = 2;
+ srcw[0] = PRIVATE_DATA(cc);
+ srcw[1] = PRIVATE_DATA(cc) + sizeof(sljit_sw);
+ }
+ cc += 2 + IMM2_SIZE;
+#ifdef SUPPORT_UTF
+ if (common->utf && HAS_EXTRALEN(cc[-1])) cc += GET_EXTRALEN(cc[-1]);
+#endif
+ break;
+
+ CASE_ITERATOR_TYPE_PRIVATE_DATA_1
+ if (PRIVATE_DATA(cc))
+ {
+ count = 1;
+ srcw[0] = PRIVATE_DATA(cc);
+ }
+ cc += 1;
+ break;
+
+ CASE_ITERATOR_TYPE_PRIVATE_DATA_2A
+ if (PRIVATE_DATA(cc))
+ {
+ count = 2;
+ srcw[0] = PRIVATE_DATA(cc);
+ srcw[1] = srcw[0] + sizeof(sljit_sw);
+ }
+ cc += 1;
+ break;
+
+ CASE_ITERATOR_TYPE_PRIVATE_DATA_2B
+ if (PRIVATE_DATA(cc))
+ {
+ count = 2;
+ srcw[0] = PRIVATE_DATA(cc);
+ srcw[1] = srcw[0] + sizeof(sljit_sw);
+ }
+ cc += 1 + IMM2_SIZE;
+ break;
+
+ case OP_CLASS:
+ case OP_NCLASS:
+#if defined SUPPORT_UTF || !defined COMPILE_PCRE8
+ case OP_XCLASS:
+ size = (*cc == OP_XCLASS) ? GET(cc, 1) : 1 + 32 / (int)sizeof(pcre_uchar);
+#else
+ size = 1 + 32 / (int)sizeof(pcre_uchar);
+#endif
+ if (PRIVATE_DATA(cc))
+ switch(get_class_iterator_size(cc + size))
+ {
+ case 1:
+ count = 1;
+ srcw[0] = PRIVATE_DATA(cc);
+ break;
+
+ case 2:
+ count = 2;
+ srcw[0] = PRIVATE_DATA(cc);
+ srcw[1] = srcw[0] + sizeof(sljit_sw);
+ break;
+
+ default:
+ SLJIT_ASSERT_STOP();
+ break;
+ }
+ cc += size;
+ break;
+
default:
cc = next_opcode(common, cc);
SLJIT_ASSERT(cc != NULL);
@@ -1025,7 +1610,7 @@ while (status != end)
if (!tmp1empty)
{
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackptr, TMP1, 0);
- stackptr += sizeof(sljit_w);
+ stackptr += sizeof(sljit_sw);
}
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), srcw[count]);
tmp1empty = FALSE;
@@ -1036,7 +1621,7 @@ while (status != end)
if (!tmp2empty)
{
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackptr, TMP2, 0);
- stackptr += sizeof(sljit_w);
+ stackptr += sizeof(sljit_sw);
}
OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), srcw[count]);
tmp2empty = FALSE;
@@ -1053,7 +1638,7 @@ while (status != end)
if (!tmp1empty)
{
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), stackptr);
- stackptr += sizeof(sljit_w);
+ stackptr += sizeof(sljit_sw);
}
tmp1next = FALSE;
}
@@ -1065,7 +1650,7 @@ while (status != end)
if (!tmp2empty)
{
OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(STACK_TOP), stackptr);
- stackptr += sizeof(sljit_w);
+ stackptr += sizeof(sljit_sw);
}
tmp1next = TRUE;
}
@@ -1080,12 +1665,12 @@ if (save)
if (!tmp1empty)
{
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackptr, TMP1, 0);
- stackptr += sizeof(sljit_w);
+ stackptr += sizeof(sljit_sw);
}
if (!tmp2empty)
{
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackptr, TMP2, 0);
- stackptr += sizeof(sljit_w);
+ stackptr += sizeof(sljit_sw);
}
}
else
@@ -1093,19 +1678,26 @@ if (save)
if (!tmp2empty)
{
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackptr, TMP2, 0);
- stackptr += sizeof(sljit_w);
+ stackptr += sizeof(sljit_sw);
}
if (!tmp1empty)
{
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), stackptr, TMP1, 0);
- stackptr += sizeof(sljit_w);
+ stackptr += sizeof(sljit_sw);
}
}
}
SLJIT_ASSERT(cc == ccend && stackptr == stacktop && (save || (tmp1empty && tmp2empty)));
}
-static SLJIT_INLINE BOOL ispowerof2(unsigned int value)
+#undef CASE_ITERATOR_PRIVATE_DATA_1
+#undef CASE_ITERATOR_PRIVATE_DATA_2A
+#undef CASE_ITERATOR_PRIVATE_DATA_2B
+#undef CASE_ITERATOR_TYPE_PRIVATE_DATA_1
+#undef CASE_ITERATOR_TYPE_PRIVATE_DATA_2A
+#undef CASE_ITERATOR_TYPE_PRIVATE_DATA_2B
+
+static SLJIT_INLINE BOOL is_powerof2(unsigned int value)
{
return (value & (value - 1)) == 0;
}
@@ -1115,7 +1707,7 @@ static SLJIT_INLINE void set_jumps(jump_list *list, struct sljit_label *label)
while (list)
{
/* sljit_set_label is clever enough to do nothing
- if either the jump or the label is NULL */
+ if either the jump or the label is NULL. */
sljit_set_label(list->jump, label);
list = list->next;
}
@@ -1142,7 +1734,7 @@ if (list_item)
list_item->type = type;
list_item->data = data;
list_item->start = start;
- list_item->leave = LABEL();
+ list_item->quit = LABEL();
list_item->next = common->stubs;
common->stubs = list_item;
}
@@ -1162,7 +1754,7 @@ while (list_item)
add_jump(compiler, &common->stackalloc, JUMP(SLJIT_FAST_CALL));
break;
}
- JUMPTO(SLJIT_JUMP, list_item->leave);
+ JUMPTO(SLJIT_JUMP, list_item->quit);
list_item = list_item->next;
}
common->stubs = NULL;
@@ -1181,7 +1773,7 @@ static SLJIT_INLINE void allocate_stack(compiler_common *common, int size)
/* May destroy all locals and registers except TMP2. */
DEFINE_COMPILER;
-OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, size * sizeof(sljit_w));
+OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, size * sizeof(sljit_sw));
#ifdef DESTROY_REGISTERS
OP1(SLJIT_MOV, TMP1, 0, SLJIT_IMM, 12345);
OP1(SLJIT_MOV, TMP3, 0, TMP1, 0);
@@ -1195,7 +1787,7 @@ add_stub(common, stack_alloc, 0, CMP(SLJIT_C_GREATER, STACK_TOP, 0, STACK_LIMIT,
static SLJIT_INLINE void free_stack(compiler_common *common, int size)
{
DEFINE_COMPILER;
-OP2(SLJIT_SUB, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, size * sizeof(sljit_w));
+OP2(SLJIT_SUB, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, size * sizeof(sljit_sw));
}
static SLJIT_INLINE void reset_ovector(compiler_common *common, int length)
@@ -1205,19 +1797,19 @@ struct sljit_label *loop;
int i;
/* At this point we can freely use all temporary registers. */
/* TMP1 returns with begin - 1. */
-OP2(SLJIT_SUB, SLJIT_TEMPORARY_REG1, 0, SLJIT_MEM1(SLJIT_SAVED_REG1), SLJIT_OFFSETOF(jit_arguments, begin), SLJIT_IMM, IN_UCHARS(1));
+OP2(SLJIT_SUB, SLJIT_SCRATCH_REG1, 0, SLJIT_MEM1(SLJIT_SAVED_REG1), SLJIT_OFFSETOF(jit_arguments, begin), SLJIT_IMM, IN_UCHARS(1));
if (length < 8)
{
for (i = 0; i < length; i++)
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(i), SLJIT_TEMPORARY_REG1, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(i), SLJIT_SCRATCH_REG1, 0);
}
else
{
- OP2(SLJIT_ADD, SLJIT_TEMPORARY_REG2, 0, SLJIT_LOCALS_REG, 0, SLJIT_IMM, OVECTOR_START - sizeof(sljit_w));
- OP1(SLJIT_MOV, SLJIT_TEMPORARY_REG3, 0, SLJIT_IMM, length);
+ GET_LOCAL_BASE(SLJIT_SCRATCH_REG2, 0, OVECTOR_START - sizeof(sljit_sw));
+ OP1(SLJIT_MOV, SLJIT_SCRATCH_REG3, 0, SLJIT_IMM, length);
loop = LABEL();
- OP1(SLJIT_MOVU, SLJIT_MEM1(SLJIT_TEMPORARY_REG2), sizeof(sljit_w), SLJIT_TEMPORARY_REG1, 0);
- OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_TEMPORARY_REG3, 0, SLJIT_TEMPORARY_REG3, 0, SLJIT_IMM, 1);
+ OP1(SLJIT_MOVU, SLJIT_MEM1(SLJIT_SCRATCH_REG2), sizeof(sljit_sw), SLJIT_SCRATCH_REG1, 0);
+ OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_SCRATCH_REG3, 0, SLJIT_SCRATCH_REG3, 0, SLJIT_IMM, 1);
JUMPTO(SLJIT_C_NOT_ZERO, loop);
}
}
@@ -1232,42 +1824,101 @@ struct sljit_jump *earlyexit;
OP1(SLJIT_MOV, SLJIT_SAVED_REG3, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(1));
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(1), STR_PTR, 0);
-OP1(SLJIT_MOV, SLJIT_TEMPORARY_REG1, 0, ARGUMENTS, 0);
-OP1(SLJIT_MOV_SI, SLJIT_TEMPORARY_REG2, 0, SLJIT_MEM1(SLJIT_TEMPORARY_REG1), SLJIT_OFFSETOF(jit_arguments, offsetcount));
-OP2(SLJIT_SUB, SLJIT_TEMPORARY_REG3, 0, SLJIT_MEM1(SLJIT_TEMPORARY_REG1), SLJIT_OFFSETOF(jit_arguments, offsets), SLJIT_IMM, sizeof(int));
-OP1(SLJIT_MOV, SLJIT_TEMPORARY_REG1, 0, SLJIT_MEM1(SLJIT_TEMPORARY_REG1), SLJIT_OFFSETOF(jit_arguments, begin));
-OP2(SLJIT_ADD, SLJIT_SAVED_REG1, 0, SLJIT_LOCALS_REG, 0, SLJIT_IMM, OVECTOR_START);
+OP1(SLJIT_MOV, SLJIT_SCRATCH_REG1, 0, ARGUMENTS, 0);
+if (common->mark_ptr != 0)
+ OP1(SLJIT_MOV, SLJIT_SCRATCH_REG3, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->mark_ptr);
+OP1(SLJIT_MOV_SI, SLJIT_SCRATCH_REG2, 0, SLJIT_MEM1(SLJIT_SCRATCH_REG1), SLJIT_OFFSETOF(jit_arguments, offsetcount));
+if (common->mark_ptr != 0)
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_SCRATCH_REG1), SLJIT_OFFSETOF(jit_arguments, mark_ptr), SLJIT_SCRATCH_REG3, 0);
+OP2(SLJIT_SUB, SLJIT_SCRATCH_REG3, 0, SLJIT_MEM1(SLJIT_SCRATCH_REG1), SLJIT_OFFSETOF(jit_arguments, offsets), SLJIT_IMM, sizeof(int));
+OP1(SLJIT_MOV, SLJIT_SCRATCH_REG1, 0, SLJIT_MEM1(SLJIT_SCRATCH_REG1), SLJIT_OFFSETOF(jit_arguments, begin));
+GET_LOCAL_BASE(SLJIT_SAVED_REG1, 0, OVECTOR_START);
/* Unlikely, but possible */
-earlyexit = CMP(SLJIT_C_EQUAL, SLJIT_TEMPORARY_REG2, 0, SLJIT_IMM, 0);
+earlyexit = CMP(SLJIT_C_EQUAL, SLJIT_SCRATCH_REG2, 0, SLJIT_IMM, 0);
loop = LABEL();
-OP2(SLJIT_SUB, SLJIT_SAVED_REG2, 0, SLJIT_MEM1(SLJIT_SAVED_REG1), 0, SLJIT_TEMPORARY_REG1, 0);
-OP2(SLJIT_ADD, SLJIT_SAVED_REG1, 0, SLJIT_SAVED_REG1, 0, SLJIT_IMM, sizeof(sljit_w));
+OP2(SLJIT_SUB, SLJIT_SAVED_REG2, 0, SLJIT_MEM1(SLJIT_SAVED_REG1), 0, SLJIT_SCRATCH_REG1, 0);
+OP2(SLJIT_ADD, SLJIT_SAVED_REG1, 0, SLJIT_SAVED_REG1, 0, SLJIT_IMM, sizeof(sljit_sw));
/* Copy the integer value to the output buffer */
-#ifdef COMPILE_PCRE16
-OP2(SLJIT_ASHR, SLJIT_SAVED_REG2, 0, SLJIT_SAVED_REG2, 0, SLJIT_IMM, 1);
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+OP2(SLJIT_ASHR, SLJIT_SAVED_REG2, 0, SLJIT_SAVED_REG2, 0, SLJIT_IMM, UCHAR_SHIFT);
#endif
-OP1(SLJIT_MOVU_SI, SLJIT_MEM1(SLJIT_TEMPORARY_REG3), sizeof(int), SLJIT_SAVED_REG2, 0);
-OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_TEMPORARY_REG2, 0, SLJIT_TEMPORARY_REG2, 0, SLJIT_IMM, 1);
+OP1(SLJIT_MOVU_SI, SLJIT_MEM1(SLJIT_SCRATCH_REG3), sizeof(int), SLJIT_SAVED_REG2, 0);
+OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_SCRATCH_REG2, 0, SLJIT_SCRATCH_REG2, 0, SLJIT_IMM, 1);
JUMPTO(SLJIT_C_NOT_ZERO, loop);
JUMPHERE(earlyexit);
/* Calculate the return value, which is the maximum ovector value. */
if (topbracket > 1)
{
- OP2(SLJIT_ADD, SLJIT_TEMPORARY_REG1, 0, SLJIT_LOCALS_REG, 0, SLJIT_IMM, OVECTOR_START + topbracket * 2 * sizeof(sljit_w));
- OP1(SLJIT_MOV, SLJIT_TEMPORARY_REG2, 0, SLJIT_IMM, topbracket + 1);
+ GET_LOCAL_BASE(SLJIT_SCRATCH_REG1, 0, OVECTOR_START + topbracket * 2 * sizeof(sljit_sw));
+ OP1(SLJIT_MOV, SLJIT_SCRATCH_REG2, 0, SLJIT_IMM, topbracket + 1);
/* OVECTOR(0) is never equal to SLJIT_SAVED_REG3. */
loop = LABEL();
- OP1(SLJIT_MOVU, SLJIT_TEMPORARY_REG3, 0, SLJIT_MEM1(SLJIT_TEMPORARY_REG1), -(2 * (sljit_w)sizeof(sljit_w)));
- OP2(SLJIT_SUB, SLJIT_TEMPORARY_REG2, 0, SLJIT_TEMPORARY_REG2, 0, SLJIT_IMM, 1);
- CMPTO(SLJIT_C_EQUAL, SLJIT_TEMPORARY_REG3, 0, SLJIT_SAVED_REG3, 0, loop);
- OP1(SLJIT_MOV, SLJIT_RETURN_REG, 0, SLJIT_TEMPORARY_REG2, 0);
+ OP1(SLJIT_MOVU, SLJIT_SCRATCH_REG3, 0, SLJIT_MEM1(SLJIT_SCRATCH_REG1), -(2 * (sljit_sw)sizeof(sljit_sw)));
+ OP2(SLJIT_SUB, SLJIT_SCRATCH_REG2, 0, SLJIT_SCRATCH_REG2, 0, SLJIT_IMM, 1);
+ CMPTO(SLJIT_C_EQUAL, SLJIT_SCRATCH_REG3, 0, SLJIT_SAVED_REG3, 0, loop);
+ OP1(SLJIT_MOV, SLJIT_RETURN_REG, 0, SLJIT_SCRATCH_REG2, 0);
}
else
OP1(SLJIT_MOV, SLJIT_RETURN_REG, 0, SLJIT_IMM, 1);
}
+static SLJIT_INLINE void return_with_partial_match(compiler_common *common, struct sljit_label *quit)
+{
+DEFINE_COMPILER;
+
+SLJIT_COMPILE_ASSERT(STR_END == SLJIT_SAVED_REG2, str_end_must_be_saved_reg2);
+SLJIT_ASSERT(common->start_used_ptr != 0 && (common->mode == JIT_PARTIAL_SOFT_COMPILE ? common->hit_start != 0 : common->hit_start == 0));
+
+OP1(SLJIT_MOV, SLJIT_SCRATCH_REG2, 0, ARGUMENTS, 0);
+OP1(SLJIT_MOV, SLJIT_RETURN_REG, 0, SLJIT_IMM, PCRE_ERROR_PARTIAL);
+OP1(SLJIT_MOV_SI, SLJIT_SCRATCH_REG3, 0, SLJIT_MEM1(SLJIT_SCRATCH_REG2), SLJIT_OFFSETOF(jit_arguments, offsetcount));
+CMPTO(SLJIT_C_LESS, SLJIT_SCRATCH_REG3, 0, SLJIT_IMM, 2, quit);
+
+/* Store match begin and end. */
+OP1(SLJIT_MOV, SLJIT_SAVED_REG1, 0, SLJIT_MEM1(SLJIT_SCRATCH_REG2), SLJIT_OFFSETOF(jit_arguments, begin));
+OP1(SLJIT_MOV, SLJIT_SCRATCH_REG2, 0, SLJIT_MEM1(SLJIT_SCRATCH_REG2), SLJIT_OFFSETOF(jit_arguments, offsets));
+OP1(SLJIT_MOV, SLJIT_SCRATCH_REG3, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->mode == JIT_PARTIAL_HARD_COMPILE ? common->start_used_ptr : common->hit_start);
+OP2(SLJIT_SUB, SLJIT_SAVED_REG2, 0, STR_END, 0, SLJIT_SAVED_REG1, 0);
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+OP2(SLJIT_ASHR, SLJIT_SAVED_REG2, 0, SLJIT_SAVED_REG2, 0, SLJIT_IMM, UCHAR_SHIFT);
+#endif
+OP1(SLJIT_MOV_SI, SLJIT_MEM1(SLJIT_SCRATCH_REG2), sizeof(int), SLJIT_SAVED_REG2, 0);
+
+OP2(SLJIT_SUB, SLJIT_SCRATCH_REG3, 0, SLJIT_SCRATCH_REG3, 0, SLJIT_SAVED_REG1, 0);
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+OP2(SLJIT_ASHR, SLJIT_SCRATCH_REG3, 0, SLJIT_SCRATCH_REG3, 0, SLJIT_IMM, UCHAR_SHIFT);
+#endif
+OP1(SLJIT_MOV_SI, SLJIT_MEM1(SLJIT_SCRATCH_REG2), 0, SLJIT_SCRATCH_REG3, 0);
+
+JUMPTO(SLJIT_JUMP, quit);
+}
+
+static SLJIT_INLINE void check_start_used_ptr(compiler_common *common)
+{
+/* May destroy TMP1. */
+DEFINE_COMPILER;
+struct sljit_jump *jump;
+
+if (common->mode == JIT_PARTIAL_SOFT_COMPILE)
+ {
+ /* The value of -1 must be kept for start_used_ptr! */
+ OP2(SLJIT_ADD, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr, SLJIT_IMM, 1);
+ /* Jumps if start_used_ptr < STR_PTR, or start_used_ptr == -1. Although overwriting
+ is not necessary if start_used_ptr == STR_PTR, it does not hurt as well. */
+ jump = CMP(SLJIT_C_LESS_EQUAL, TMP1, 0, STR_PTR, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr, STR_PTR, 0);
+ JUMPHERE(jump);
+ }
+else if (common->mode == JIT_PARTIAL_HARD_COMPILE)
+ {
+ jump = CMP(SLJIT_C_LESS_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr, STR_PTR, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr, STR_PTR, 0);
+ JUMPHERE(jump);
+ }
+}
+
static SLJIT_INLINE BOOL char_has_othercase(compiler_common *common, pcre_uchar* cc)
{
/* Detects if the character has an othercase. */
@@ -1352,10 +2003,10 @@ if (c <= 127 && bit == 0x20)
return (0 << 8) | 0x20;
/* Since c != oc, they must have at least 1 bit difference. */
-if (!ispowerof2(bit))
+if (!is_powerof2(bit))
return 0;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
#ifdef SUPPORT_UTF
if (common->utf && c > 127)
@@ -1371,9 +2022,8 @@ if (common->utf && c > 127)
#endif /* SUPPORT_UTF */
return (0 << 8) | bit;
-#else /* COMPILE_PCRE8 */
+#elif defined COMPILE_PCRE16 || defined COMPILE_PCRE32
-#ifdef COMPILE_PCRE16
#ifdef SUPPORT_UTF
if (common->utf && c > 65535)
{
@@ -1384,15 +2034,98 @@ if (common->utf && c > 65535)
}
#endif /* SUPPORT_UTF */
return (bit < 256) ? ((0 << 8) | bit) : ((1 << 8) | (bit >> 8));
-#endif /* COMPILE_PCRE16 */
-#endif /* COMPILE_PCRE8 */
+#endif /* COMPILE_PCRE[8|16|32] */
+}
+
+static void check_partial(compiler_common *common, BOOL force)
+{
+/* Checks whether a partial matching is occured. Does not modify registers. */
+DEFINE_COMPILER;
+struct sljit_jump *jump = NULL;
+
+SLJIT_ASSERT(!force || common->mode != JIT_COMPILE);
+
+if (common->mode == JIT_COMPILE)
+ return;
+
+if (!force)
+ jump = CMP(SLJIT_C_GREATER_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr, STR_PTR, 0);
+else if (common->mode == JIT_PARTIAL_SOFT_COMPILE)
+ jump = CMP(SLJIT_C_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr, SLJIT_IMM, -1);
+
+if (common->mode == JIT_PARTIAL_SOFT_COMPILE)
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->hit_start, SLJIT_IMM, -1);
+else
+ {
+ if (common->partialmatchlabel != NULL)
+ JUMPTO(SLJIT_JUMP, common->partialmatchlabel);
+ else
+ add_jump(compiler, &common->partialmatch, JUMP(SLJIT_JUMP));
+ }
+
+if (jump != NULL)
+ JUMPHERE(jump);
+}
+
+static struct sljit_jump *check_str_end(compiler_common *common)
+{
+/* Does not affect registers. Usually used in a tight spot. */
+DEFINE_COMPILER;
+struct sljit_jump *jump;
+struct sljit_jump *nohit;
+struct sljit_jump *return_value;
+
+if (common->mode == JIT_COMPILE)
+ return CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
+
+jump = CMP(SLJIT_C_LESS, STR_PTR, 0, STR_END, 0);
+if (common->mode == JIT_PARTIAL_SOFT_COMPILE)
+ {
+ nohit = CMP(SLJIT_C_GREATER_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr, STR_PTR, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->hit_start, SLJIT_IMM, -1);
+ JUMPHERE(nohit);
+ return_value = JUMP(SLJIT_JUMP);
+ }
+else
+ {
+ return_value = CMP(SLJIT_C_GREATER_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr, STR_PTR, 0);
+ if (common->partialmatchlabel != NULL)
+ JUMPTO(SLJIT_JUMP, common->partialmatchlabel);
+ else
+ add_jump(compiler, &common->partialmatch, JUMP(SLJIT_JUMP));
+ }
+JUMPHERE(jump);
+return return_value;
}
-static SLJIT_INLINE void check_input_end(compiler_common *common, jump_list **fallbacks)
+static void detect_partial_match(compiler_common *common, jump_list **backtracks)
{
DEFINE_COMPILER;
-add_jump(compiler, fallbacks, CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0));
+struct sljit_jump *jump;
+
+if (common->mode == JIT_COMPILE)
+ {
+ add_jump(compiler, backtracks, CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0));
+ return;
+ }
+
+/* Partial matching mode. */
+jump = CMP(SLJIT_C_LESS, STR_PTR, 0, STR_END, 0);
+add_jump(compiler, backtracks, CMP(SLJIT_C_GREATER_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr, STR_PTR, 0));
+if (common->mode == JIT_PARTIAL_SOFT_COMPILE)
+ {
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->hit_start, SLJIT_IMM, -1);
+ add_jump(compiler, backtracks, JUMP(SLJIT_JUMP));
+ }
+else
+ {
+ if (common->partialmatchlabel != NULL)
+ JUMPTO(SLJIT_JUMP, common->partialmatchlabel);
+ else
+ add_jump(compiler, &common->partialmatch, JUMP(SLJIT_JUMP));
+ }
+JUMPHERE(jump);
}
static void read_char(compiler_common *common)
@@ -1400,25 +2133,23 @@ static void read_char(compiler_common *common)
/* Reads the character into TMP1, updates STR_PTR.
Does not check STR_END. TMP2 Destroyed. */
DEFINE_COMPILER;
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
struct sljit_jump *jump;
#endif
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), 0);
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
if (common->utf)
{
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
jump = CMP(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xc0);
-#else
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
jump = CMP(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xd800);
-#endif
-#endif /* COMPILE_PCRE8 */
+#endif /* COMPILE_PCRE[8|16] */
add_jump(compiler, &common->utfreadchar, JUMP(SLJIT_FAST_CALL));
JUMPHERE(jump);
}
-#endif
+#endif /* SUPPORT_UTF && !COMPILE_PCRE32 */
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
}
@@ -1427,33 +2158,31 @@ static void peek_char(compiler_common *common)
/* Reads the character into TMP1, keeps STR_PTR.
Does not check STR_END. TMP2 Destroyed. */
DEFINE_COMPILER;
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
struct sljit_jump *jump;
#endif
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), 0);
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
if (common->utf)
{
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
jump = CMP(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xc0);
-#else
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
jump = CMP(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xd800);
-#endif
-#endif /* COMPILE_PCRE8 */
+#endif /* COMPILE_PCRE[8|16] */
add_jump(compiler, &common->utfreadchar, JUMP(SLJIT_FAST_CALL));
OP2(SLJIT_SUB, STR_PTR, 0, STR_PTR, 0, TMP2, 0);
JUMPHERE(jump);
}
-#endif
+#endif /* SUPPORT_UTF && !COMPILE_PCRE32 */
}
static void read_char8_type(compiler_common *common)
{
/* Reads the character type into TMP1, updates STR_PTR. Does not check STR_END. */
DEFINE_COMPILER;
-#if defined SUPPORT_UTF || defined COMPILE_PCRE16
+#if defined SUPPORT_UTF || defined COMPILE_PCRE16 || defined COMPILE_PCRE32
struct sljit_jump *jump;
#endif
@@ -1462,15 +2191,14 @@ if (common->utf)
{
OP1(MOV_UCHAR, TMP2, 0, SLJIT_MEM1(STR_PTR), 0);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
/* This can be an extra read in some situations, but hopefully
it is needed in most cases. */
OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP2), common->ctypes);
jump = CMP(SLJIT_C_LESS, TMP2, 0, SLJIT_IMM, 0xc0);
add_jump(compiler, &common->utfreadtype8, JUMP(SLJIT_FAST_CALL));
JUMPHERE(jump);
-#else
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
OP1(SLJIT_MOV, TMP1, 0, SLJIT_IMM, 0);
jump = CMP(SLJIT_C_GREATER, TMP2, 0, SLJIT_IMM, 255);
OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP2), common->ctypes);
@@ -1478,23 +2206,27 @@ if (common->utf)
/* Skip low surrogate if necessary. */
OP2(SLJIT_AND, TMP2, 0, TMP2, 0, SLJIT_IMM, 0xfc00);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP2, 0, SLJIT_IMM, 0xd800);
- COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SHL, TMP2, 0, TMP2, 0, SLJIT_IMM, 1);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP2, 0);
-#endif
-#endif /* COMPILE_PCRE8 */
+#elif defined COMPILE_PCRE32
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_IMM, 0);
+ jump = CMP(SLJIT_C_GREATER, TMP2, 0, SLJIT_IMM, 255);
+ OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP2), common->ctypes);
+ JUMPHERE(jump);
+#endif /* COMPILE_PCRE[8|16|32] */
return;
}
-#endif
+#endif /* SUPPORT_UTF */
OP1(MOV_UCHAR, TMP2, 0, SLJIT_MEM1(STR_PTR), 0);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
-#ifdef COMPILE_PCRE16
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
/* The ctypes array contains only 256 values. */
OP1(SLJIT_MOV, TMP1, 0, SLJIT_IMM, 0);
jump = CMP(SLJIT_C_GREATER, TMP2, 0, SLJIT_IMM, 255);
#endif
OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP2), common->ctypes);
-#ifdef COMPILE_PCRE16
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
JUMPHERE(jump);
#endif
}
@@ -1503,7 +2235,8 @@ static void skip_char_back(compiler_common *common)
{
/* Goes one character back. Affects STR_PTR and TMP1. Does not check begin. */
DEFINE_COMPILER;
-#if defined SUPPORT_UTF && defined COMPILE_PCRE8
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
+#if defined COMPILE_PCRE8
struct sljit_label *label;
if (common->utf)
@@ -1515,8 +2248,7 @@ if (common->utf)
CMPTO(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, 0x80, label);
return;
}
-#endif
-#if defined SUPPORT_UTF && defined COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
if (common->utf)
{
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), -IN_UCHARS(1));
@@ -1524,16 +2256,17 @@ if (common->utf)
/* Skip low surrogate if necessary. */
OP2(SLJIT_AND, TMP1, 0, TMP1, 0, SLJIT_IMM, 0xfc00);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0xdc00);
- COND_VALUE(SLJIT_MOV, TMP1, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP1, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SHL, TMP1, 0, TMP1, 0, SLJIT_IMM, 1);
OP2(SLJIT_SUB, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
return;
}
-#endif
+#endif /* COMPILE_PCRE[8|16] */
+#endif /* SUPPORT_UTF && !COMPILE_PCRE32 */
OP2(SLJIT_SUB, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
}
-static void check_newlinechar(compiler_common *common, int nltype, jump_list **fallbacks, BOOL jumpiftrue)
+static void check_newlinechar(compiler_common *common, int nltype, jump_list **backtracks, BOOL jumpiftrue)
{
/* Character comes in TMP1. Checks if it is a newline. TMP2 may be destroyed. */
DEFINE_COMPILER;
@@ -1541,26 +2274,26 @@ DEFINE_COMPILER;
if (nltype == NLTYPE_ANY)
{
add_jump(compiler, &common->anynewline, JUMP(SLJIT_FAST_CALL));
- add_jump(compiler, fallbacks, JUMP(jumpiftrue ? SLJIT_C_NOT_ZERO : SLJIT_C_ZERO));
+ add_jump(compiler, backtracks, JUMP(jumpiftrue ? SLJIT_C_NOT_ZERO : SLJIT_C_ZERO));
}
else if (nltype == NLTYPE_ANYCRLF)
{
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, CHAR_CR);
- COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, CHAR_NL);
- COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_EQUAL);
- add_jump(compiler, fallbacks, JUMP(jumpiftrue ? SLJIT_C_NOT_ZERO : SLJIT_C_ZERO));
+ OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
+ add_jump(compiler, backtracks, JUMP(jumpiftrue ? SLJIT_C_NOT_ZERO : SLJIT_C_ZERO));
}
else
{
SLJIT_ASSERT(nltype == NLTYPE_FIXED && common->newline < 256);
- add_jump(compiler, fallbacks, CMP(jumpiftrue ? SLJIT_C_EQUAL : SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, common->newline));
+ add_jump(compiler, backtracks, CMP(jumpiftrue ? SLJIT_C_EQUAL : SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, common->newline));
}
}
#ifdef SUPPORT_UTF
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
static void do_utfreadchar(compiler_common *common)
{
/* Fast decoding a UTF-8 character. TMP1 contains the first byte
@@ -1568,7 +2301,7 @@ of the character (>= 0xc0). Return char value in TMP1, length - 1 in TMP2. */
DEFINE_COMPILER;
struct sljit_jump *jump;
-sljit_emit_fast_enter(compiler, RETURN_ADDR, 0, 1, 5, 5, common->localsize);
+sljit_emit_fast_enter(compiler, RETURN_ADDR, 0);
/* Searching for the first zero. */
OP2(SLJIT_AND | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x20);
jump = JUMP(SLJIT_C_NOT_ZERO);
@@ -1627,7 +2360,7 @@ DEFINE_COMPILER;
struct sljit_jump *jump;
struct sljit_jump *compare;
-sljit_emit_fast_enter(compiler, RETURN_ADDR, 0, 1, 5, 5, common->localsize);
+sljit_emit_fast_enter(compiler, RETURN_ADDR, 0);
OP2(SLJIT_AND | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP2, 0, SLJIT_IMM, 0x20);
jump = JUMP(SLJIT_C_NOT_ZERO);
@@ -1648,15 +2381,14 @@ sljit_emit_fast_return(compiler, RETURN_ADDR, 0);
JUMPHERE(jump);
/* We only have types for characters less than 256. */
-OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP2), (sljit_w)PRIV(utf8_table4) - 0xc0);
+OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP2), (sljit_sw)PRIV(utf8_table4) - 0xc0);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
OP1(SLJIT_MOV, TMP1, 0, SLJIT_IMM, 0);
sljit_emit_fast_return(compiler, RETURN_ADDR, 0);
}
-#else /* COMPILE_PCRE8 */
+#elif defined COMPILE_PCRE16
-#ifdef COMPILE_PCRE16
static void do_utfreadchar(compiler_common *common)
{
/* Fast decoding a UTF-16 character. TMP1 contains the first 16 bit char
@@ -1664,7 +2396,7 @@ of the character (>= 0xd800). Return char value in TMP1, length - 1 in TMP2. */
DEFINE_COMPILER;
struct sljit_jump *jump;
-sljit_emit_fast_enter(compiler, RETURN_ADDR, 0, 1, 5, 5, common->localsize);
+sljit_emit_fast_enter(compiler, RETURN_ADDR, 0);
jump = CMP(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xdc00);
/* Do nothing, only return. */
sljit_emit_fast_return(compiler, RETURN_ADDR, 0);
@@ -1681,9 +2413,8 @@ OP1(SLJIT_MOV, TMP2, 0, SLJIT_IMM, IN_UCHARS(1));
OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 0x10000);
sljit_emit_fast_return(compiler, RETURN_ADDR, 0);
}
-#endif /* COMPILE_PCRE16 */
-#endif /* COMPILE_PCRE8 */
+#endif /* COMPILE_PCRE[8|16] */
#endif /* SUPPORT_UTF */
@@ -1701,15 +2432,15 @@ DEFINE_COMPILER;
SLJIT_ASSERT(UCD_BLOCK_SIZE == 128 && sizeof(ucd_record) == 8);
-sljit_emit_fast_enter(compiler, RETURN_ADDR, 0, 1, 5, 5, common->localsize);
+sljit_emit_fast_enter(compiler, RETURN_ADDR, 0);
OP2(SLJIT_LSHR, TMP2, 0, TMP1, 0, SLJIT_IMM, UCD_BLOCK_SHIFT);
-OP1(SLJIT_MOV_UB, TMP2, 0, SLJIT_MEM1(TMP2), (sljit_w)PRIV(ucd_stage1));
+OP1(SLJIT_MOV_UB, TMP2, 0, SLJIT_MEM1(TMP2), (sljit_sw)PRIV(ucd_stage1));
OP2(SLJIT_AND, TMP1, 0, TMP1, 0, SLJIT_IMM, UCD_BLOCK_MASK);
OP2(SLJIT_SHL, TMP2, 0, TMP2, 0, SLJIT_IMM, UCD_BLOCK_SHIFT);
OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, TMP2, 0);
-OP1(SLJIT_MOV, TMP2, 0, SLJIT_IMM, (sljit_w)PRIV(ucd_stage2));
+OP1(SLJIT_MOV, TMP2, 0, SLJIT_IMM, (sljit_sw)PRIV(ucd_stage2));
OP1(SLJIT_MOV_UH, TMP2, 0, SLJIT_MEM2(TMP2, TMP1), 1);
-OP1(SLJIT_MOV, TMP1, 0, SLJIT_IMM, (sljit_w)PRIV(ucd_records) + SLJIT_OFFSETOF(ucd_record, chartype));
+OP1(SLJIT_MOV, TMP1, 0, SLJIT_IMM, (sljit_sw)PRIV(ucd_records) + SLJIT_OFFSETOF(ucd_record, chartype));
OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM2(TMP1, TMP2), 3);
sljit_emit_fast_return(compiler, RETURN_ADDR, 0);
}
@@ -1723,7 +2454,7 @@ struct sljit_label *newlinelabel = NULL;
struct sljit_jump *start;
struct sljit_jump *end = NULL;
struct sljit_jump *nl = NULL;
-#ifdef SUPPORT_UTF
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
struct sljit_jump *singlechar;
#endif
jump_list *newline = NULL;
@@ -1737,8 +2468,8 @@ if (!(hascrorlf || firstline) && (common->nltype == NLTYPE_ANY ||
if (firstline)
{
/* Search for the end of the first line. */
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0, STR_PTR, 0);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), FIRSTLINE_END, STR_END, 0);
+ SLJIT_ASSERT(common->first_line_end != 0);
+ OP1(SLJIT_MOV, TMP3, 0, STR_PTR, 0);
if (common->nltype == NLTYPE_FIXED && common->newline > 255)
{
@@ -1749,23 +2480,24 @@ if (firstline)
OP1(MOV_UCHAR, TMP2, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(0));
CMPTO(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, (common->newline >> 8) & 0xff, mainloop);
CMPTO(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, common->newline & 0xff, mainloop);
- OP2(SLJIT_SUB, SLJIT_MEM1(SLJIT_LOCALS_REG), FIRSTLINE_END, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
+ JUMPHERE(end);
+ OP2(SLJIT_SUB, SLJIT_MEM1(SLJIT_LOCALS_REG), common->first_line_end, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
}
else
{
end = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
mainloop = LABEL();
/* Continual stores does not cause data dependency. */
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), FIRSTLINE_END, STR_PTR, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->first_line_end, STR_PTR, 0);
read_char(common);
check_newlinechar(common, common->nltype, &newline, TRUE);
CMPTO(SLJIT_C_LESS, STR_PTR, 0, STR_END, 0, mainloop);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), FIRSTLINE_END, STR_PTR, 0);
+ JUMPHERE(end);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->first_line_end, STR_PTR, 0);
set_jumps(newline, LABEL());
}
- JUMPHERE(end);
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0);
+ OP1(SLJIT_MOV, STR_PTR, 0, TMP3, 0);
}
start = JUMP(SLJIT_JUMP);
@@ -1777,9 +2509,9 @@ if (newlinecheck)
end = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), 0);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, common->newline & 0xff);
- COND_VALUE(SLJIT_MOV, TMP1, 0, SLJIT_C_EQUAL);
-#ifdef COMPILE_PCRE16
- OP2(SLJIT_SHL, TMP1, 0, TMP1, 0, SLJIT_IMM, 1);
+ OP_FLAGS(SLJIT_MOV, TMP1, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ OP2(SLJIT_SHL, TMP1, 0, TMP1, 0, SLJIT_IMM, UCHAR_SHIFT);
#endif
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
nl = JUMP(SLJIT_JUMP);
@@ -1800,27 +2532,28 @@ if (newlinecheck)
CMPTO(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, (common->newline >> 8) & 0xff, newlinelabel);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
-#if defined SUPPORT_UTF && defined COMPILE_PCRE8
+#if defined SUPPORT_UTF && !defined COMPILE_PCRE32
+#if defined COMPILE_PCRE8
if (common->utf)
{
singlechar = CMP(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xc0);
- OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_w)PRIV(utf8_table4) - 0xc0);
+ OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_sw)PRIV(utf8_table4) - 0xc0);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
JUMPHERE(singlechar);
}
-#endif
-#if defined SUPPORT_UTF && defined COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
if (common->utf)
{
singlechar = CMP(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xd800);
OP2(SLJIT_AND, TMP1, 0, TMP1, 0, SLJIT_IMM, 0xfc00);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0xd800);
- COND_VALUE(SLJIT_MOV, TMP1, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP1, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SHL, TMP1, 0, TMP1, 0, SLJIT_IMM, 1);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
JUMPHERE(singlechar);
}
-#endif
+#endif /* COMPILE_PCRE[8|16] */
+#endif /* SUPPORT_UTF && !COMPILE_PCRE32 */
JUMPHERE(start);
if (newlinecheck)
@@ -1832,22 +2565,192 @@ if (newlinecheck)
return mainloop;
}
+#define MAX_N_CHARS 3
+
+static SLJIT_INLINE BOOL fast_forward_first_n_chars(compiler_common *common, BOOL firstline)
+{
+DEFINE_COMPILER;
+struct sljit_label *start;
+struct sljit_jump *quit;
+pcre_uint32 chars[MAX_N_CHARS * 2];
+pcre_uchar *cc = common->start + 1 + IMM2_SIZE;
+int location = 0;
+pcre_int32 len, c, bit, caseless;
+int must_stop;
+
+/* We do not support alternatives now. */
+if (*(common->start + GET(common->start, 1)) == OP_ALT)
+ return FALSE;
+
+while (TRUE)
+ {
+ caseless = 0;
+ must_stop = 1;
+ switch(*cc)
+ {
+ case OP_CHAR:
+ must_stop = 0;
+ cc++;
+ break;
+
+ case OP_CHARI:
+ caseless = 1;
+ must_stop = 0;
+ cc++;
+ break;
+
+ case OP_SOD:
+ case OP_SOM:
+ case OP_SET_SOM:
+ case OP_NOT_WORD_BOUNDARY:
+ case OP_WORD_BOUNDARY:
+ case OP_EODN:
+ case OP_EOD:
+ case OP_CIRC:
+ case OP_CIRCM:
+ case OP_DOLL:
+ case OP_DOLLM:
+ /* Zero width assertions. */
+ cc++;
+ continue;
+
+ case OP_PLUS:
+ case OP_MINPLUS:
+ case OP_POSPLUS:
+ cc++;
+ break;
+
+ case OP_EXACT:
+ cc += 1 + IMM2_SIZE;
+ break;
+
+ case OP_PLUSI:
+ case OP_MINPLUSI:
+ case OP_POSPLUSI:
+ caseless = 1;
+ cc++;
+ break;
+
+ case OP_EXACTI:
+ caseless = 1;
+ cc += 1 + IMM2_SIZE;
+ break;
+
+ default:
+ must_stop = 2;
+ break;
+ }
+
+ if (must_stop == 2)
+ break;
+
+ len = 1;
+#ifdef SUPPORT_UTF
+ if (common->utf && HAS_EXTRALEN(cc[0])) len += GET_EXTRALEN(cc[0]);
+#endif
+
+ if (caseless && char_has_othercase(common, cc))
+ {
+ caseless = char_get_othercase_bit(common, cc);
+ if (caseless == 0)
+ return FALSE;
+#ifdef COMPILE_PCRE8
+ caseless = ((caseless & 0xff) << 8) | (len - (caseless >> 8));
+#else
+ if ((caseless & 0x100) != 0)
+ caseless = ((caseless & 0xff) << 16) | (len - (caseless >> 9));
+ else
+ caseless = ((caseless & 0xff) << 8) | (len - (caseless >> 9));
+#endif
+ }
+ else
+ caseless = 0;
+
+ while (len > 0 && location < MAX_N_CHARS * 2)
+ {
+ c = *cc;
+ bit = 0;
+ if (len == (caseless & 0xff))
+ {
+ bit = caseless >> 8;
+ c |= bit;
+ }
+
+ chars[location] = c;
+ chars[location + 1] = bit;
+
+ len--;
+ location += 2;
+ cc++;
+ }
+
+ if (location >= MAX_N_CHARS * 2 || must_stop != 0)
+ break;
+ }
+
+/* At least two characters are required. */
+if (location < 2 * 2)
+ return FALSE;
+
+if (firstline)
+ {
+ SLJIT_ASSERT(common->first_line_end != 0);
+ OP1(SLJIT_MOV, TMP3, 0, STR_END, 0);
+ OP2(SLJIT_SUB, STR_END, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->first_line_end, SLJIT_IMM, (location >> 1) - 1);
+ }
+else
+ OP2(SLJIT_SUB, STR_END, 0, STR_END, 0, SLJIT_IMM, (location >> 1) - 1);
+
+start = LABEL();
+quit = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
+
+OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(0));
+OP1(MOV_UCHAR, TMP2, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(1));
+OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
+if (chars[1] != 0)
+ OP2(SLJIT_OR, TMP1, 0, TMP1, 0, SLJIT_IMM, chars[1]);
+CMPTO(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, chars[0], start);
+if (location > 2 * 2)
+ OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(1));
+if (chars[3] != 0)
+ OP2(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_IMM, chars[3]);
+CMPTO(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, chars[2], start);
+if (location > 2 * 2)
+ {
+ if (chars[5] != 0)
+ OP2(SLJIT_OR, TMP1, 0, TMP1, 0, SLJIT_IMM, chars[5]);
+ CMPTO(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, chars[4], start);
+ }
+OP2(SLJIT_SUB, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
+
+JUMPHERE(quit);
+
+if (firstline)
+ OP1(SLJIT_MOV, STR_END, 0, TMP3, 0);
+else
+ OP2(SLJIT_ADD, STR_END, 0, STR_END, 0, SLJIT_IMM, (location >> 1) - 1);
+return TRUE;
+}
+
+#undef MAX_N_CHARS
+
static SLJIT_INLINE void fast_forward_first_char(compiler_common *common, pcre_uchar first_char, BOOL caseless, BOOL firstline)
{
DEFINE_COMPILER;
struct sljit_label *start;
-struct sljit_jump *leave;
+struct sljit_jump *quit;
struct sljit_jump *found;
pcre_uchar oc, bit;
if (firstline)
{
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, STR_END, 0);
- OP1(SLJIT_MOV, STR_END, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), FIRSTLINE_END);
+ SLJIT_ASSERT(common->first_line_end != 0);
+ OP1(SLJIT_MOV, TMP3, 0, STR_END, 0);
+ OP1(SLJIT_MOV, STR_END, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->first_line_end);
}
start = LABEL();
-leave = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
+quit = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), 0);
oc = first_char;
@@ -1864,7 +2767,7 @@ if (first_char == oc)
else
{
bit = first_char ^ oc;
- if (ispowerof2(bit))
+ if (is_powerof2(bit))
{
OP2(SLJIT_OR, TMP2, 0, TMP1, 0, SLJIT_IMM, bit);
found = CMP(SLJIT_C_EQUAL, TMP2, 0, SLJIT_IMM, first_char | bit);
@@ -1872,39 +2775,20 @@ else
else
{
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, first_char);
- COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, oc);
- COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
found = JUMP(SLJIT_C_NOT_ZERO);
}
}
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
-#if defined SUPPORT_UTF && defined COMPILE_PCRE8
-if (common->utf)
- {
- CMPTO(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xc0, start);
- OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_w)PRIV(utf8_table4) - 0xc0);
- OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
- }
-#endif
-#if defined SUPPORT_UTF && defined COMPILE_PCRE16
-if (common->utf)
- {
- CMPTO(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xd800, start);
- OP2(SLJIT_AND, TMP1, 0, TMP1, 0, SLJIT_IMM, 0xfc00);
- OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0xd800);
- COND_VALUE(SLJIT_MOV, TMP1, 0, SLJIT_C_EQUAL);
- OP2(SLJIT_SHL, TMP1, 0, TMP1, 0, SLJIT_IMM, 1);
- OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
- }
-#endif
JUMPTO(SLJIT_JUMP, start);
JUMPHERE(found);
-JUMPHERE(leave);
+JUMPHERE(quit);
if (firstline)
- OP1(SLJIT_MOV, STR_END, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0);
+ OP1(SLJIT_MOV, STR_END, 0, TMP3, 0);
}
static SLJIT_INLINE void fast_forward_newline(compiler_common *common, BOOL firstline)
@@ -1913,15 +2797,16 @@ DEFINE_COMPILER;
struct sljit_label *loop;
struct sljit_jump *lastchar;
struct sljit_jump *firstchar;
-struct sljit_jump *leave;
+struct sljit_jump *quit;
struct sljit_jump *foundcr = NULL;
struct sljit_jump *notfoundnl;
jump_list *newline = NULL;
if (firstline)
{
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, STR_END, 0);
- OP1(SLJIT_MOV, STR_END, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), FIRSTLINE_END);
+ SLJIT_ASSERT(common->first_line_end != 0);
+ OP1(SLJIT_MOV, TMP3, 0, STR_END, 0);
+ OP1(SLJIT_MOV, STR_END, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->first_line_end);
}
if (common->nltype == NLTYPE_FIXED && common->newline > 255)
@@ -1934,21 +2819,21 @@ if (common->nltype == NLTYPE_FIXED && common->newline > 255)
OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, IN_UCHARS(2));
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, STR_PTR, 0, TMP1, 0);
- COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_GREATER_EQUAL);
-#ifdef COMPILE_PCRE16
- OP2(SLJIT_SHL, TMP2, 0, TMP2, 0, SLJIT_IMM, 1);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_GREATER_EQUAL);
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ OP2(SLJIT_SHL, TMP2, 0, TMP2, 0, SLJIT_IMM, UCHAR_SHIFT);
#endif
OP2(SLJIT_SUB, STR_PTR, 0, STR_PTR, 0, TMP2, 0);
loop = LABEL();
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
- leave = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
+ quit = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(-2));
OP1(MOV_UCHAR, TMP2, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(-1));
CMPTO(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, (common->newline >> 8) & 0xff, loop);
CMPTO(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, common->newline & 0xff, loop);
- JUMPHERE(leave);
+ JUMPHERE(quit);
JUMPHERE(firstchar);
JUMPHERE(lastchar);
@@ -1972,31 +2857,31 @@ set_jumps(newline, loop);
if (common->nltype == NLTYPE_ANY || common->nltype == NLTYPE_ANYCRLF)
{
- leave = JUMP(SLJIT_JUMP);
+ quit = JUMP(SLJIT_JUMP);
JUMPHERE(foundcr);
notfoundnl = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), 0);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, CHAR_NL);
- COND_VALUE(SLJIT_MOV, TMP1, 0, SLJIT_C_EQUAL);
-#ifdef COMPILE_PCRE16
- OP2(SLJIT_SHL, TMP1, 0, TMP1, 0, SLJIT_IMM, 1);
+ OP_FLAGS(SLJIT_MOV, TMP1, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ OP2(SLJIT_SHL, TMP1, 0, TMP1, 0, SLJIT_IMM, UCHAR_SHIFT);
#endif
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
JUMPHERE(notfoundnl);
- JUMPHERE(leave);
+ JUMPHERE(quit);
}
JUMPHERE(lastchar);
JUMPHERE(firstchar);
if (firstline)
- OP1(SLJIT_MOV, STR_END, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0);
+ OP1(SLJIT_MOV, STR_END, 0, TMP3, 0);
}
static SLJIT_INLINE void fast_forward_start_bits(compiler_common *common, sljit_uw start_bits, BOOL firstline)
{
DEFINE_COMPILER;
struct sljit_label *start;
-struct sljit_jump *leave;
+struct sljit_jump *quit;
struct sljit_jump *found;
#ifndef COMPILE_PCRE8
struct sljit_jump *jump;
@@ -2004,12 +2889,13 @@ struct sljit_jump *jump;
if (firstline)
{
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, STR_END, 0);
- OP1(SLJIT_MOV, STR_END, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), FIRSTLINE_END);
+ SLJIT_ASSERT(common->first_line_end != 0);
+ OP1(SLJIT_MOV, RETURN_ADDR, 0, STR_END, 0);
+ OP1(SLJIT_MOV, STR_END, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->first_line_end);
}
start = LABEL();
-leave = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
+quit = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), 0);
#ifdef SUPPORT_UTF
if (common->utf)
@@ -2032,31 +2918,32 @@ if (common->utf)
OP1(SLJIT_MOV, TMP1, 0, TMP3, 0);
#endif
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
-#if defined SUPPORT_UTF && defined COMPILE_PCRE8
+#ifdef SUPPORT_UTF
+#if defined COMPILE_PCRE8
if (common->utf)
{
CMPTO(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xc0, start);
- OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_w)PRIV(utf8_table4) - 0xc0);
+ OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_sw)PRIV(utf8_table4) - 0xc0);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
}
-#endif
-#if defined SUPPORT_UTF && defined COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
if (common->utf)
{
CMPTO(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xd800, start);
OP2(SLJIT_AND, TMP1, 0, TMP1, 0, SLJIT_IMM, 0xfc00);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0xd800);
- COND_VALUE(SLJIT_MOV, TMP1, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP1, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SHL, TMP1, 0, TMP1, 0, SLJIT_IMM, 1);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
}
-#endif
+#endif /* COMPILE_PCRE[8|16] */
+#endif /* SUPPORT_UTF */
JUMPTO(SLJIT_JUMP, start);
JUMPHERE(found);
-JUMPHERE(leave);
+JUMPHERE(quit);
if (firstline)
- OP1(SLJIT_MOV, STR_END, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0);
+ OP1(SLJIT_MOV, STR_END, 0, RETURN_ADDR, 0);
}
static SLJIT_INLINE struct sljit_jump *search_requested_char(compiler_common *common, pcre_uchar req_char, BOOL caseless, BOOL has_firstchar)
@@ -2068,9 +2955,10 @@ struct sljit_jump *alreadyfound;
struct sljit_jump *found;
struct sljit_jump *foundoc = NULL;
struct sljit_jump *notfound;
-pcre_uchar oc, bit;
+pcre_uint32 oc, bit;
-OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), REQ_CHAR_PTR);
+SLJIT_ASSERT(common->req_char_ptr != 0);
+OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->req_char_ptr);
OP2(SLJIT_ADD, TMP1, 0, STR_PTR, 0, SLJIT_IMM, REQ_BYTE_MAX);
toolong = CMP(SLJIT_C_LESS, TMP1, 0, STR_END, 0);
alreadyfound = CMP(SLJIT_C_LESS, STR_PTR, 0, TMP2, 0);
@@ -2098,7 +2986,7 @@ if (req_char == oc)
else
{
bit = req_char ^ oc;
- if (ispowerof2(bit))
+ if (is_powerof2(bit))
{
OP2(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_IMM, bit);
found = CMP(SLJIT_C_EQUAL, TMP2, 0, SLJIT_IMM, req_char | bit);
@@ -2115,7 +3003,7 @@ JUMPTO(SLJIT_JUMP, loop);
JUMPHERE(found);
if (foundoc)
JUMPHERE(foundoc);
-OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), REQ_CHAR_PTR, TMP1, 0);
+OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->req_char_ptr, TMP1, 0);
JUMPHERE(alreadyfound);
JUMPHERE(toolong);
return notfound;
@@ -2127,17 +3015,18 @@ DEFINE_COMPILER;
struct sljit_jump *jump;
struct sljit_label *mainloop;
-sljit_emit_fast_enter(compiler, RETURN_ADDR, 0, 1, 5, 5, common->localsize);
+sljit_emit_fast_enter(compiler, RETURN_ADDR, 0);
OP1(SLJIT_MOV, TMP1, 0, STACK_TOP, 0);
+GET_LOCAL_BASE(TMP3, 0, 0);
/* Drop frames until we reach STACK_TOP. */
mainloop = LABEL();
OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(TMP1), 0);
jump = CMP(SLJIT_C_SIG_LESS_EQUAL, TMP2, 0, SLJIT_IMM, frame_end);
-OP2(SLJIT_ADD, TMP2, 0, TMP2, 0, SLJIT_LOCALS_REG, 0);
-OP1(SLJIT_MOV, SLJIT_MEM1(TMP2), 0, SLJIT_MEM1(TMP1), sizeof(sljit_w));
-OP1(SLJIT_MOV, SLJIT_MEM1(TMP2), sizeof(sljit_w), SLJIT_MEM1(TMP1), 2 * sizeof(sljit_w));
-OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 3 * sizeof(sljit_w));
+OP2(SLJIT_ADD, TMP2, 0, TMP2, 0, TMP3, 0);
+OP1(SLJIT_MOV, SLJIT_MEM1(TMP2), 0, SLJIT_MEM1(TMP1), sizeof(sljit_sw));
+OP1(SLJIT_MOV, SLJIT_MEM1(TMP2), sizeof(sljit_sw), SLJIT_MEM1(TMP1), 2 * sizeof(sljit_sw));
+OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 3 * sizeof(sljit_sw));
JUMPTO(SLJIT_JUMP, mainloop);
JUMPHERE(jump);
@@ -2148,34 +3037,46 @@ sljit_emit_fast_return(compiler, RETURN_ADDR, 0);
JUMPHERE(jump);
jump = CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, frame_setstrbegin);
/* Set string begin. */
-OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(TMP1), sizeof(sljit_w));
-OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 2 * sizeof(sljit_w));
+OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(TMP1), sizeof(sljit_sw));
+OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 2 * sizeof(sljit_sw));
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0), TMP2, 0);
JUMPTO(SLJIT_JUMP, mainloop);
JUMPHERE(jump);
+if (common->mark_ptr != 0)
+ {
+ jump = CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, frame_setmark);
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(TMP1), sizeof(sljit_sw));
+ OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 2 * sizeof(sljit_sw));
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->mark_ptr, TMP2, 0);
+ JUMPTO(SLJIT_JUMP, mainloop);
+
+ JUMPHERE(jump);
+ }
+
/* Unknown command. */
-OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 2 * sizeof(sljit_w));
+OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 2 * sizeof(sljit_sw));
JUMPTO(SLJIT_JUMP, mainloop);
}
static void check_wordboundary(compiler_common *common)
{
DEFINE_COMPILER;
-struct sljit_jump *beginend;
+struct sljit_jump *skipread;
#if !(defined COMPILE_PCRE8) || defined SUPPORT_UTF
struct sljit_jump *jump;
#endif
SLJIT_COMPILE_ASSERT(ctype_word == 0x10, ctype_word_must_be_16);
-sljit_emit_fast_enter(compiler, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0, 1, 5, 5, common->localsize);
+sljit_emit_fast_enter(compiler, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0);
/* Get type of the previous char, and put it to LOCALS1. */
OP1(SLJIT_MOV, TMP1, 0, ARGUMENTS, 0);
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, begin));
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS1, SLJIT_IMM, 0);
-beginend = CMP(SLJIT_C_LESS_EQUAL, STR_PTR, 0, TMP1, 0);
+skipread = CMP(SLJIT_C_LESS_EQUAL, STR_PTR, 0, TMP1, 0);
skip_char_back(common);
+check_start_used_ptr(common);
read_char(common);
/* Testing char type. */
@@ -2187,10 +3088,10 @@ if (common->use_ucp)
add_jump(compiler, &common->getucd, JUMP(SLJIT_FAST_CALL));
OP2(SLJIT_SUB, TMP1, 0, TMP1, 0, SLJIT_IMM, ucp_Ll);
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, ucp_Lu - ucp_Ll);
- COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_LESS_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_LESS_EQUAL);
OP2(SLJIT_SUB, TMP1, 0, TMP1, 0, SLJIT_IMM, ucp_Nd - ucp_Ll);
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, ucp_No - ucp_Nd);
- COND_VALUE(SLJIT_OR, TMP2, 0, SLJIT_C_LESS_EQUAL);
+ OP_FLAGS(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_C_LESS_EQUAL);
JUMPHERE(jump);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS1, TMP2, 0);
}
@@ -2216,10 +3117,10 @@ else
JUMPHERE(jump);
#endif /* COMPILE_PCRE8 */
}
-JUMPHERE(beginend);
+JUMPHERE(skipread);
OP1(SLJIT_MOV, TMP2, 0, SLJIT_IMM, 0);
-beginend = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
+skipread = check_str_end(common);
peek_char(common);
/* Testing char type. This is a code duplication. */
@@ -2231,10 +3132,10 @@ if (common->use_ucp)
add_jump(compiler, &common->getucd, JUMP(SLJIT_FAST_CALL));
OP2(SLJIT_SUB, TMP1, 0, TMP1, 0, SLJIT_IMM, ucp_Ll);
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, ucp_Lu - ucp_Ll);
- COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_LESS_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_LESS_EQUAL);
OP2(SLJIT_SUB, TMP1, 0, TMP1, 0, SLJIT_IMM, ucp_Nd - ucp_Ll);
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, ucp_No - ucp_Nd);
- COND_VALUE(SLJIT_OR, TMP2, 0, SLJIT_C_LESS_EQUAL);
+ OP_FLAGS(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_C_LESS_EQUAL);
JUMPHERE(jump);
}
else
@@ -2260,36 +3161,175 @@ else
JUMPHERE(jump);
#endif /* COMPILE_PCRE8 */
}
-JUMPHERE(beginend);
+JUMPHERE(skipread);
OP2(SLJIT_XOR | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS1);
sljit_emit_fast_return(compiler, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0);
}
+/*
+ range format:
+
+ ranges[0] = length of the range (max MAX_RANGE_SIZE, -1 means invalid range).
+ ranges[1] = first bit (0 or 1)
+ ranges[2-length] = position of the bit change (when the current bit is not equal to the previous)
+*/
+
+static BOOL check_ranges(compiler_common *common, int *ranges, jump_list **backtracks, BOOL readch)
+{
+DEFINE_COMPILER;
+struct sljit_jump *jump;
+
+if (ranges[0] < 0)
+ return FALSE;
+
+switch(ranges[0])
+ {
+ case 1:
+ if (readch)
+ read_char(common);
+ add_jump(compiler, backtracks, CMP(ranges[1] == 0 ? SLJIT_C_LESS : SLJIT_C_GREATER_EQUAL, TMP1, 0, SLJIT_IMM, ranges[2]));
+ return TRUE;
+
+ case 2:
+ if (readch)
+ read_char(common);
+ OP2(SLJIT_SUB, TMP1, 0, TMP1, 0, SLJIT_IMM, ranges[2]);
+ add_jump(compiler, backtracks, CMP(ranges[1] != 0 ? SLJIT_C_LESS : SLJIT_C_GREATER_EQUAL, TMP1, 0, SLJIT_IMM, ranges[3] - ranges[2]));
+ return TRUE;
+
+ case 4:
+ if (ranges[2] + 1 == ranges[3] && ranges[4] + 1 == ranges[5])
+ {
+ if (readch)
+ read_char(common);
+ if (ranges[1] != 0)
+ {
+ add_jump(compiler, backtracks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, ranges[2]));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, ranges[4]));
+ }
+ else
+ {
+ jump = CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, ranges[2]);
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, ranges[4]));
+ JUMPHERE(jump);
+ }
+ return TRUE;
+ }
+ if ((ranges[3] - ranges[2]) == (ranges[5] - ranges[4]) && is_powerof2(ranges[4] - ranges[2]))
+ {
+ if (readch)
+ read_char(common);
+ OP2(SLJIT_OR, TMP1, 0, TMP1, 0, SLJIT_IMM, ranges[4] - ranges[2]);
+ OP2(SLJIT_SUB, TMP1, 0, TMP1, 0, SLJIT_IMM, ranges[4]);
+ add_jump(compiler, backtracks, CMP(ranges[1] != 0 ? SLJIT_C_LESS : SLJIT_C_GREATER_EQUAL, TMP1, 0, SLJIT_IMM, ranges[5] - ranges[4]));
+ return TRUE;
+ }
+ return FALSE;
+
+ default:
+ return FALSE;
+ }
+}
+
+static void get_ctype_ranges(compiler_common *common, int flag, int *ranges)
+{
+int i, bit, length;
+const pcre_uint8 *ctypes = (const pcre_uint8*)common->ctypes;
+
+bit = ctypes[0] & flag;
+ranges[0] = -1;
+ranges[1] = bit != 0 ? 1 : 0;
+length = 0;
+
+for (i = 1; i < 256; i++)
+ if ((ctypes[i] & flag) != bit)
+ {
+ if (length >= MAX_RANGE_SIZE)
+ return;
+ ranges[2 + length] = i;
+ length++;
+ bit ^= flag;
+ }
+
+if (bit != 0)
+ {
+ if (length >= MAX_RANGE_SIZE)
+ return;
+ ranges[2 + length] = 256;
+ length++;
+ }
+ranges[0] = length;
+}
+
+static BOOL check_class_ranges(compiler_common *common, const pcre_uint8 *bits, BOOL nclass, jump_list **backtracks)
+{
+int ranges[2 + MAX_RANGE_SIZE];
+pcre_uint8 bit, cbit, all;
+int i, byte, length = 0;
+
+bit = bits[0] & 0x1;
+ranges[1] = bit;
+/* Can be 0 or 255. */
+all = -bit;
+
+for (i = 0; i < 256; )
+ {
+ byte = i >> 3;
+ if ((i & 0x7) == 0 && bits[byte] == all)
+ i += 8;
+ else
+ {
+ cbit = (bits[byte] >> (i & 0x7)) & 0x1;
+ if (cbit != bit)
+ {
+ if (length >= MAX_RANGE_SIZE)
+ return FALSE;
+ ranges[2 + length] = i;
+ length++;
+ bit = cbit;
+ all = -cbit;
+ }
+ i++;
+ }
+ }
+
+if (((bit == 0) && nclass) || ((bit == 1) && !nclass))
+ {
+ if (length >= MAX_RANGE_SIZE)
+ return FALSE;
+ ranges[2 + length] = 256;
+ length++;
+ }
+ranges[0] = length;
+
+return check_ranges(common, ranges, backtracks, FALSE);
+}
+
static void check_anynewline(compiler_common *common)
{
/* Check whether TMP1 contains a newline character. TMP2 destroyed. */
DEFINE_COMPILER;
-sljit_emit_fast_enter(compiler, RETURN_ADDR, 0, 1, 5, 5, common->localsize);
+sljit_emit_fast_enter(compiler, RETURN_ADDR, 0);
OP2(SLJIT_SUB, TMP1, 0, TMP1, 0, SLJIT_IMM, 0x0a);
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x0d - 0x0a);
-COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_LESS_EQUAL);
+OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_LESS_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x85 - 0x0a);
-#if defined SUPPORT_UTF || defined COMPILE_PCRE16
+#if defined SUPPORT_UTF || defined COMPILE_PCRE16 || defined COMPILE_PCRE32
#ifdef COMPILE_PCRE8
if (common->utf)
{
#endif
- COND_VALUE(SLJIT_OR, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
OP2(SLJIT_OR, TMP1, 0, TMP1, 0, SLJIT_IMM, 0x1);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x2029 - 0x0a);
#ifdef COMPILE_PCRE8
}
#endif
-#endif /* SUPPORT_UTF || COMPILE_PCRE16 */
-COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_EQUAL);
+#endif /* SUPPORT_UTF || COMPILE_PCRE16 || COMPILE_PCRE32 */
+OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
sljit_emit_fast_return(compiler, RETURN_ADDR, 0);
}
@@ -2298,36 +3338,36 @@ static void check_hspace(compiler_common *common)
/* Check whether TMP1 contains a newline character. TMP2 destroyed. */
DEFINE_COMPILER;
-sljit_emit_fast_enter(compiler, RETURN_ADDR, 0, 1, 5, 5, common->localsize);
+sljit_emit_fast_enter(compiler, RETURN_ADDR, 0);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x09);
-COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_EQUAL);
+OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x20);
-COND_VALUE(SLJIT_OR, TMP2, 0, SLJIT_C_EQUAL);
+OP_FLAGS(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0xa0);
-#if defined SUPPORT_UTF || defined COMPILE_PCRE16
+#if defined SUPPORT_UTF || defined COMPILE_PCRE16 || defined COMPILE_PCRE32
#ifdef COMPILE_PCRE8
if (common->utf)
{
#endif
- COND_VALUE(SLJIT_OR, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x1680);
- COND_VALUE(SLJIT_OR, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x180e);
- COND_VALUE(SLJIT_OR, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SUB, TMP1, 0, TMP1, 0, SLJIT_IMM, 0x2000);
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x200A - 0x2000);
- COND_VALUE(SLJIT_OR, TMP2, 0, SLJIT_C_LESS_EQUAL);
+ OP_FLAGS(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_C_LESS_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x202f - 0x2000);
- COND_VALUE(SLJIT_OR, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x205f - 0x2000);
- COND_VALUE(SLJIT_OR, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x3000 - 0x2000);
#ifdef COMPILE_PCRE8
}
#endif
-#endif /* SUPPORT_UTF || COMPILE_PCRE16 */
-COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_EQUAL);
+#endif /* SUPPORT_UTF || COMPILE_PCRE16 || COMPILE_PCRE32 */
+OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
sljit_emit_fast_return(compiler, RETURN_ADDR, 0);
}
@@ -2337,25 +3377,25 @@ static void check_vspace(compiler_common *common)
/* Check whether TMP1 contains a newline character. TMP2 destroyed. */
DEFINE_COMPILER;
-sljit_emit_fast_enter(compiler, RETURN_ADDR, 0, 1, 5, 5, common->localsize);
+sljit_emit_fast_enter(compiler, RETURN_ADDR, 0);
OP2(SLJIT_SUB, TMP1, 0, TMP1, 0, SLJIT_IMM, 0x0a);
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x0d - 0x0a);
-COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_LESS_EQUAL);
+OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_LESS_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x85 - 0x0a);
-#if defined SUPPORT_UTF || defined COMPILE_PCRE16
+#if defined SUPPORT_UTF || defined COMPILE_PCRE16 || defined COMPILE_PCRE32
#ifdef COMPILE_PCRE8
if (common->utf)
{
#endif
- COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
OP2(SLJIT_OR, TMP1, 0, TMP1, 0, SLJIT_IMM, 0x1);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0x2029 - 0x0a);
#ifdef COMPILE_PCRE8
}
#endif
-#endif /* SUPPORT_UTF || COMPILE_PCRE16 */
-COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_EQUAL);
+#endif /* SUPPORT_UTF || COMPILE_PCRE16 || COMPILE_PCRE32 */
+OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
sljit_emit_fast_return(compiler, RETURN_ADDR, 0);
}
@@ -2369,7 +3409,7 @@ DEFINE_COMPILER;
struct sljit_jump *jump;
struct sljit_label *label;
-sljit_emit_fast_enter(compiler, RETURN_ADDR, 0, 1, 5, 5, common->localsize);
+sljit_emit_fast_enter(compiler, RETURN_ADDR, 0);
OP2(SLJIT_SUB, STR_PTR, 0, STR_PTR, 0, TMP2, 0);
OP1(SLJIT_MOV, TMP3, 0, CHAR1, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0, CHAR2, 0);
@@ -2398,7 +3438,7 @@ DEFINE_COMPILER;
struct sljit_jump *jump;
struct sljit_label *label;
-sljit_emit_fast_enter(compiler, RETURN_ADDR, 0, 1, 5, 5, common->localsize);
+sljit_emit_fast_enter(compiler, RETURN_ADDR, 0);
OP2(SLJIT_SUB, STR_PTR, 0, STR_PTR, 0, TMP2, 0);
OP1(SLJIT_MOV, TMP3, 0, LCC_TABLE, 0);
@@ -2444,17 +3484,28 @@ sljit_emit_fast_return(compiler, RETURN_ADDR, 0);
static const pcre_uchar *SLJIT_CALL do_utf_caselesscmp(pcre_uchar *src1, jit_arguments *args, pcre_uchar *end1)
{
/* This function would be ineffective to do in JIT level. */
-int c1, c2;
-const pcre_uchar *src2 = args->ptr;
+pcre_uint32 c1, c2;
+const pcre_uchar *src2 = args->uchar_ptr;
const pcre_uchar *end2 = args->end;
+const ucd_record *ur;
+const pcre_uint32 *pp;
while (src1 < end1)
{
if (src2 >= end2)
- return 0;
+ return (pcre_uchar*)1;
GETCHARINC(c1, src1);
GETCHARINC(c2, src2);
- if (c1 != c2 && c1 != UCD_OTHERCASE(c2)) return 0;
+ ur = GET_UCD(c2);
+ if (c1 != c2 && c1 != c2 + ur->other_case)
+ {
+ pp = PRIV(ucd_caseless_sets) + ur->caseset;
+ for (;;)
+ {
+ if (c1 < *pp) return NULL;
+ if (c1 == *pp++) break;
+ }
+ }
}
return src2;
}
@@ -2462,7 +3513,7 @@ return src2;
#endif /* SUPPORT_UTF && SUPPORT_UCP */
static pcre_uchar *byte_sequence_compare(compiler_common *common, BOOL caseless, pcre_uchar *cc,
- compare_context* context, jump_list **fallbacks)
+ compare_context* context, jump_list **backtracks)
{
DEFINE_COMPILER;
unsigned int othercasebit = 0;
@@ -2476,23 +3527,25 @@ if (caseless && char_has_othercase(common, cc))
othercasebit = char_get_othercase_bit(common, cc);
SLJIT_ASSERT(othercasebit);
/* Extracting bit difference info. */
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
othercasechar = cc + (othercasebit >> 8);
othercasebit &= 0xff;
-#else
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ /* Note that this code only handles characters in the BMP. If there
+ ever are characters outside the BMP whose othercase differs in only one
+ bit from itself (there currently are none), this code will need to be
+ revised for COMPILE_PCRE32. */
othercasechar = cc + (othercasebit >> 9);
if ((othercasebit & 0x100) != 0)
othercasebit = (othercasebit & 0xff) << 8;
else
othercasebit &= 0xff;
-#endif
-#endif
+#endif /* COMPILE_PCRE[8|16|32] */
}
if (context->sourcereg == -1)
{
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
#if defined SLJIT_UNALIGNED && SLJIT_UNALIGNED
if (context->length >= 4)
OP1(SLJIT_MOV_SI, TMP1, 0, SLJIT_MEM1(STR_PTR), -context->length);
@@ -2501,16 +3554,16 @@ if (context->sourcereg == -1)
else
#endif
OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(STR_PTR), -context->length);
-#else
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
#if defined SLJIT_UNALIGNED && SLJIT_UNALIGNED
if (context->length >= 4)
OP1(SLJIT_MOV_SI, TMP1, 0, SLJIT_MEM1(STR_PTR), -context->length);
else
#endif
- OP1(SLJIT_MOV_UH, TMP1, 0, SLJIT_MEM1(STR_PTR), -context->length);
-#endif
-#endif /* COMPILE_PCRE8 */
+ OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), -context->length);
+#elif defined COMPILE_PCRE32
+ OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), -context->length);
+#endif /* COMPILE_PCRE[8|16|32] */
context->sourcereg = TMP2;
}
@@ -2539,23 +3592,29 @@ do
}
context->ucharptr++;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
if (context->ucharptr >= 4 || context->length == 0 || (context->ucharptr == 2 && context->length == 1))
-#else
+#elif defined COMPILE_PCRE16
if (context->ucharptr >= 2 || context->length == 0)
+#elif defined COMPILE_PCRE32
+ if (1 /* context->ucharptr >= 1 || context->length == 0 */)
#endif
{
+#if defined COMPILE_PCRE8 || defined COMPILE_PCRE16
if (context->length >= 4)
OP1(SLJIT_MOV_SI, context->sourcereg, 0, SLJIT_MEM1(STR_PTR), -context->length);
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
else if (context->length >= 2)
OP1(SLJIT_MOV_UH, context->sourcereg, 0, SLJIT_MEM1(STR_PTR), -context->length);
else if (context->length >= 1)
OP1(SLJIT_MOV_UB, context->sourcereg, 0, SLJIT_MEM1(STR_PTR), -context->length);
-#else
+#elif defined COMPILE_PCRE16
else if (context->length >= 2)
OP1(SLJIT_MOV_UH, context->sourcereg, 0, SLJIT_MEM1(STR_PTR), -context->length);
-#endif
+#endif /* COMPILE_PCRE[8|16] */
+#elif defined COMPILE_PCRE32
+ OP1(MOV_UCHAR, context->sourcereg, 0, SLJIT_MEM1(STR_PTR), -context->length);
+#endif /* COMPILE_PCRE[8|16|32] */
context->sourcereg = context->sourcereg == TMP1 ? TMP2 : TMP1;
switch(context->ucharptr)
@@ -2563,23 +3622,26 @@ do
case 4 / sizeof(pcre_uchar):
if (context->oc.asint != 0)
OP2(SLJIT_OR, context->sourcereg, 0, context->sourcereg, 0, SLJIT_IMM, context->oc.asint);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, context->sourcereg, 0, SLJIT_IMM, context->c.asint | context->oc.asint));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, context->sourcereg, 0, SLJIT_IMM, context->c.asint | context->oc.asint));
break;
+#if defined COMPILE_PCRE8 || defined COMPILE_PCRE16
case 2 / sizeof(pcre_uchar):
if (context->oc.asushort != 0)
OP2(SLJIT_OR, context->sourcereg, 0, context->sourcereg, 0, SLJIT_IMM, context->oc.asushort);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, context->sourcereg, 0, SLJIT_IMM, context->c.asushort | context->oc.asushort));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, context->sourcereg, 0, SLJIT_IMM, context->c.asushort | context->oc.asushort));
break;
#ifdef COMPILE_PCRE8
case 1:
if (context->oc.asbyte != 0)
OP2(SLJIT_OR, context->sourcereg, 0, context->sourcereg, 0, SLJIT_IMM, context->oc.asbyte);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, context->sourcereg, 0, SLJIT_IMM, context->c.asbyte | context->oc.asbyte));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, context->sourcereg, 0, SLJIT_IMM, context->c.asbyte | context->oc.asbyte));
break;
#endif
+#endif /* COMPILE_PCRE[8|16] */
+
default:
SLJIT_ASSERT_STOP();
break;
@@ -2590,22 +3652,18 @@ do
#else
/* Unaligned read is unsupported. */
-#ifdef COMPILE_PCRE8
- if (context->length > 0)
- OP1(SLJIT_MOV_UB, context->sourcereg, 0, SLJIT_MEM1(STR_PTR), -context->length);
-#else
if (context->length > 0)
- OP1(SLJIT_MOV_UH, context->sourcereg, 0, SLJIT_MEM1(STR_PTR), -context->length);
-#endif
+ OP1(MOV_UCHAR, context->sourcereg, 0, SLJIT_MEM1(STR_PTR), -context->length);
+
context->sourcereg = context->sourcereg == TMP1 ? TMP2 : TMP1;
if (othercasebit != 0 && othercasechar == cc)
{
OP2(SLJIT_OR, context->sourcereg, 0, context->sourcereg, 0, SLJIT_IMM, othercasebit);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, context->sourcereg, 0, SLJIT_IMM, *cc | othercasebit));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, context->sourcereg, 0, SLJIT_IMM, *cc | othercasebit));
}
else
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, context->sourcereg, 0, SLJIT_IMM, *cc));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, context->sourcereg, 0, SLJIT_IMM, *cc));
#endif
@@ -2641,26 +3699,26 @@ return cc;
} \
charoffset = (value);
-static void compile_xclass_hotpath(compiler_common *common, pcre_uchar *cc, jump_list **fallbacks)
+static void compile_xclass_matchingpath(compiler_common *common, pcre_uchar *cc, jump_list **backtracks)
{
DEFINE_COMPILER;
jump_list *found = NULL;
-jump_list **list = (*cc & XCL_NOT) == 0 ? &found : fallbacks;
-unsigned int c;
-int compares;
+jump_list **list = (*cc & XCL_NOT) == 0 ? &found : backtracks;
+pcre_int32 c, charoffset;
+const pcre_uint32 *other_cases;
struct sljit_jump *jump = NULL;
pcre_uchar *ccbegin;
+int compares, invertcmp, numberofcmps;
#ifdef SUPPORT_UCP
BOOL needstype = FALSE, needsscript = FALSE, needschar = FALSE;
BOOL charsaved = FALSE;
int typereg = TMP1, scriptreg = TMP1;
-unsigned int typeoffset;
+pcre_int32 typeoffset;
#endif
-int invertcmp, numberofcmps;
-unsigned int charoffset;
-/* Although SUPPORT_UTF must be defined, we are not necessary in utf mode. */
-check_input_end(common, fallbacks);
+/* Although SUPPORT_UTF must be defined, we are
+ not necessary in utf mode even in 8 bit mode. */
+detect_partial_match(common, backtracks);
read_char(common);
if ((*cc++ & XCL_MAP) != 0)
@@ -2673,12 +3731,15 @@ if ((*cc++ & XCL_MAP) != 0)
jump = CMP(SLJIT_C_GREATER, TMP1, 0, SLJIT_IMM, 255);
#endif
- OP2(SLJIT_AND, TMP2, 0, TMP1, 0, SLJIT_IMM, 0x7);
- OP2(SLJIT_LSHR, TMP1, 0, TMP1, 0, SLJIT_IMM, 3);
- OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_w)cc);
- OP2(SLJIT_SHL, TMP2, 0, SLJIT_IMM, 1, TMP2, 0);
- OP2(SLJIT_AND | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, TMP2, 0);
- add_jump(compiler, list, JUMP(SLJIT_C_NOT_ZERO));
+ if (!check_class_ranges(common, (const pcre_uint8 *)cc, TRUE, list))
+ {
+ OP2(SLJIT_AND, TMP2, 0, TMP1, 0, SLJIT_IMM, 0x7);
+ OP2(SLJIT_LSHR, TMP1, 0, TMP1, 0, SLJIT_IMM, 3);
+ OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_sw)cc);
+ OP2(SLJIT_SHL, TMP2, 0, SLJIT_IMM, 1, TMP2, 0);
+ OP2(SLJIT_AND | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, TMP2, 0);
+ add_jump(compiler, list, JUMP(SLJIT_C_NOT_ZERO));
+ }
#ifndef COMPILE_PCRE8
JUMPHERE(jump);
@@ -2751,6 +3812,10 @@ while (*cc != XCL_END)
needschar = TRUE;
break;
+ case PT_CLIST:
+ needschar = TRUE;
+ break;
+
default:
SLJIT_ASSERT_STOP();
break;
@@ -2787,13 +3852,13 @@ if (needstype || needsscript)
{
if (scriptreg == TMP1)
{
- OP1(SLJIT_MOV, scriptreg, 0, SLJIT_IMM, (sljit_w)PRIV(ucd_records) + SLJIT_OFFSETOF(ucd_record, script));
+ OP1(SLJIT_MOV, scriptreg, 0, SLJIT_IMM, (sljit_sw)PRIV(ucd_records) + SLJIT_OFFSETOF(ucd_record, script));
OP1(SLJIT_MOV_UB, scriptreg, 0, SLJIT_MEM2(scriptreg, TMP2), 3);
}
else
{
OP2(SLJIT_SHL, TMP2, 0, TMP2, 0, SLJIT_IMM, 3);
- OP2(SLJIT_ADD, TMP2, 0, TMP2, 0, SLJIT_IMM, (sljit_w)PRIV(ucd_records) + SLJIT_OFFSETOF(ucd_record, script));
+ OP2(SLJIT_ADD, TMP2, 0, TMP2, 0, SLJIT_IMM, (sljit_sw)PRIV(ucd_records) + SLJIT_OFFSETOF(ucd_record, script));
OP1(SLJIT_MOV_UB, scriptreg, 0, SLJIT_MEM1(TMP2), 0);
}
}
@@ -2811,7 +3876,7 @@ typeoffset = 0;
while (*cc != XCL_END)
{
compares--;
- invertcmp = (compares == 0 && list != fallbacks);
+ invertcmp = (compares == 0 && list != backtracks);
jump = NULL;
if (*cc == XCL_SINGLE)
@@ -2829,13 +3894,13 @@ while (*cc != XCL_END)
if (numberofcmps < 3 && (*cc == XCL_SINGLE || *cc == XCL_RANGE))
{
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, c - charoffset);
- COND_VALUE(numberofcmps == 0 ? SLJIT_MOV : SLJIT_OR, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(numberofcmps == 0 ? SLJIT_MOV : SLJIT_OR, TMP2, 0, numberofcmps == 0 ? SLJIT_UNUSED : TMP2, 0, SLJIT_C_EQUAL);
numberofcmps++;
}
else if (numberofcmps > 0)
{
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, c - charoffset);
- COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
jump = JUMP(SLJIT_C_NOT_ZERO ^ invertcmp);
numberofcmps = 0;
}
@@ -2868,13 +3933,13 @@ while (*cc != XCL_END)
if (numberofcmps < 3 && (*cc == XCL_SINGLE || *cc == XCL_RANGE))
{
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, c - charoffset);
- COND_VALUE(numberofcmps == 0 ? SLJIT_MOV : SLJIT_OR, TMP2, 0, SLJIT_C_LESS_EQUAL);
+ OP_FLAGS(numberofcmps == 0 ? SLJIT_MOV : SLJIT_OR, TMP2, 0, numberofcmps == 0 ? SLJIT_UNUSED : TMP2, 0, SLJIT_C_LESS_EQUAL);
numberofcmps++;
}
else if (numberofcmps > 0)
{
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, c - charoffset);
- COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_LESS_EQUAL);
+ OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_LESS_EQUAL);
jump = JUMP(SLJIT_C_NOT_ZERO ^ invertcmp);
numberofcmps = 0;
}
@@ -2893,7 +3958,7 @@ while (*cc != XCL_END)
switch(*cc)
{
case PT_ANY:
- if (list != fallbacks)
+ if (list != backtracks)
{
if ((cc[-1] == XCL_NOTPROP && compares > 0) || (cc[-1] == XCL_PROP && compares == 0))
continue;
@@ -2905,11 +3970,11 @@ while (*cc != XCL_END)
case PT_LAMP:
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, typereg, 0, SLJIT_IMM, ucp_Lu - typeoffset);
- COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, typereg, 0, SLJIT_IMM, ucp_Ll - typeoffset);
- COND_VALUE(SLJIT_OR, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, typereg, 0, SLJIT_IMM, ucp_Lt - typeoffset);
- COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
jump = JUMP(SLJIT_C_NOT_ZERO ^ invertcmp);
break;
@@ -2936,28 +4001,81 @@ while (*cc != XCL_END)
}
SET_CHAR_OFFSET(9);
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 13 - 9);
- COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_LESS_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_LESS_EQUAL);
if (*cc == PT_SPACE)
JUMPHERE(jump);
SET_TYPE_OFFSET(ucp_Zl);
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, typereg, 0, SLJIT_IMM, ucp_Zs - ucp_Zl);
- COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_LESS_EQUAL);
+ OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_LESS_EQUAL);
jump = JUMP(SLJIT_C_NOT_ZERO ^ invertcmp);
break;
case PT_WORD:
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, CHAR_UNDERSCORE - charoffset);
- COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
/* ... fall through */
case PT_ALNUM:
SET_TYPE_OFFSET(ucp_Ll);
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, typereg, 0, SLJIT_IMM, ucp_Lu - ucp_Ll);
- COND_VALUE((*cc == PT_ALNUM) ? SLJIT_MOV : SLJIT_OR, TMP2, 0, SLJIT_C_LESS_EQUAL);
+ OP_FLAGS((*cc == PT_ALNUM) ? SLJIT_MOV : SLJIT_OR, TMP2, 0, (*cc == PT_ALNUM) ? SLJIT_UNUSED : TMP2, 0, SLJIT_C_LESS_EQUAL);
SET_TYPE_OFFSET(ucp_Nd);
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, typereg, 0, SLJIT_IMM, ucp_No - ucp_Nd);
- COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_LESS_EQUAL);
+ OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_LESS_EQUAL);
+ jump = JUMP(SLJIT_C_NOT_ZERO ^ invertcmp);
+ break;
+
+ case PT_CLIST:
+ other_cases = PRIV(ucd_caseless_sets) + cc[1];
+
+ /* At least three characters are required.
+ Otherwise this case would be handled by the normal code path. */
+ SLJIT_ASSERT(other_cases[0] != NOTACHAR && other_cases[1] != NOTACHAR && other_cases[2] != NOTACHAR);
+ SLJIT_ASSERT(other_cases[0] < other_cases[1] && other_cases[1] < other_cases[2]);
+
+ /* Optimizing character pairs, if their difference is power of 2. */
+ if (is_powerof2(other_cases[1] ^ other_cases[0]))
+ {
+ if (charoffset == 0)
+ OP2(SLJIT_OR, TMP2, 0, TMP1, 0, SLJIT_IMM, other_cases[1] ^ other_cases[0]);
+ else
+ {
+ OP2(SLJIT_ADD, TMP2, 0, TMP1, 0, SLJIT_IMM, (sljit_sw)charoffset);
+ OP2(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_IMM, other_cases[1] ^ other_cases[0]);
+ }
+ OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP2, 0, SLJIT_IMM, other_cases[1]);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
+ other_cases += 2;
+ }
+ else if (is_powerof2(other_cases[2] ^ other_cases[1]))
+ {
+ if (charoffset == 0)
+ OP2(SLJIT_OR, TMP2, 0, TMP1, 0, SLJIT_IMM, other_cases[2] ^ other_cases[1]);
+ else
+ {
+ OP2(SLJIT_ADD, TMP2, 0, TMP1, 0, SLJIT_IMM, (sljit_sw)charoffset);
+ OP2(SLJIT_OR, TMP2, 0, TMP2, 0, SLJIT_IMM, other_cases[1] ^ other_cases[0]);
+ }
+ OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP2, 0, SLJIT_IMM, other_cases[2]);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
+
+ OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, other_cases[0] - charoffset);
+ OP_FLAGS(SLJIT_OR | ((other_cases[3] == NOTACHAR) ? SLJIT_SET_E : 0), TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
+
+ other_cases += 3;
+ }
+ else
+ {
+ OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, *other_cases++ - charoffset);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
+ }
+
+ while (*other_cases != NOTACHAR)
+ {
+ OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, *other_cases++ - charoffset);
+ OP_FLAGS(SLJIT_OR | ((*other_cases == NOTACHAR) ? SLJIT_SET_E : 0), TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
+ }
jump = JUMP(SLJIT_C_NOT_ZERO ^ invertcmp);
break;
}
@@ -2966,7 +4084,7 @@ while (*cc != XCL_END)
#endif
if (jump != NULL)
- add_jump(compiler, compares > 0 ? list : fallbacks, jump);
+ add_jump(compiler, compares > 0 ? list : backtracks, jump);
}
if (found != NULL)
@@ -2978,7 +4096,7 @@ if (found != NULL)
#endif
-static pcre_uchar *compile_char1_hotpath(compiler_common *common, pcre_uchar type, pcre_uchar *cc, jump_list **fallbacks)
+static pcre_uchar *compile_char1_matchingpath(compiler_common *common, pcre_uchar type, pcre_uchar *cc, jump_list **backtracks)
{
DEFINE_COMPILER;
int length;
@@ -2997,83 +4115,99 @@ switch(type)
case OP_SOD:
OP1(SLJIT_MOV, TMP1, 0, ARGUMENTS, 0);
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, begin));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, STR_PTR, 0, TMP1, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, STR_PTR, 0, TMP1, 0));
return cc;
case OP_SOM:
OP1(SLJIT_MOV, TMP1, 0, ARGUMENTS, 0);
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, str));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, STR_PTR, 0, TMP1, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, STR_PTR, 0, TMP1, 0));
return cc;
case OP_NOT_WORD_BOUNDARY:
case OP_WORD_BOUNDARY:
add_jump(compiler, &common->wordboundary, JUMP(SLJIT_FAST_CALL));
- add_jump(compiler, fallbacks, JUMP(type == OP_NOT_WORD_BOUNDARY ? SLJIT_C_NOT_ZERO : SLJIT_C_ZERO));
+ add_jump(compiler, backtracks, JUMP(type == OP_NOT_WORD_BOUNDARY ? SLJIT_C_NOT_ZERO : SLJIT_C_ZERO));
return cc;
case OP_NOT_DIGIT:
case OP_DIGIT:
- check_input_end(common, fallbacks);
- read_char8_type(common);
- OP2(SLJIT_AND | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, ctype_digit);
- add_jump(compiler, fallbacks, JUMP(type == OP_DIGIT ? SLJIT_C_ZERO : SLJIT_C_NOT_ZERO));
+ /* Digits are usually 0-9, so it is worth to optimize them. */
+ if (common->digits[0] == -2)
+ get_ctype_ranges(common, ctype_digit, common->digits);
+ detect_partial_match(common, backtracks);
+ /* Flip the starting bit in the negative case. */
+ if (type == OP_NOT_DIGIT)
+ common->digits[1] ^= 1;
+ if (!check_ranges(common, common->digits, backtracks, TRUE))
+ {
+ read_char8_type(common);
+ OP2(SLJIT_AND | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, ctype_digit);
+ add_jump(compiler, backtracks, JUMP(type == OP_DIGIT ? SLJIT_C_ZERO : SLJIT_C_NOT_ZERO));
+ }
+ if (type == OP_NOT_DIGIT)
+ common->digits[1] ^= 1;
return cc;
case OP_NOT_WHITESPACE:
case OP_WHITESPACE:
- check_input_end(common, fallbacks);
+ detect_partial_match(common, backtracks);
read_char8_type(common);
OP2(SLJIT_AND | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, ctype_space);
- add_jump(compiler, fallbacks, JUMP(type == OP_WHITESPACE ? SLJIT_C_ZERO : SLJIT_C_NOT_ZERO));
+ add_jump(compiler, backtracks, JUMP(type == OP_WHITESPACE ? SLJIT_C_ZERO : SLJIT_C_NOT_ZERO));
return cc;
case OP_NOT_WORDCHAR:
case OP_WORDCHAR:
- check_input_end(common, fallbacks);
+ detect_partial_match(common, backtracks);
read_char8_type(common);
OP2(SLJIT_AND | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, ctype_word);
- add_jump(compiler, fallbacks, JUMP(type == OP_WORDCHAR ? SLJIT_C_ZERO : SLJIT_C_NOT_ZERO));
+ add_jump(compiler, backtracks, JUMP(type == OP_WORDCHAR ? SLJIT_C_ZERO : SLJIT_C_NOT_ZERO));
return cc;
case OP_ANY:
- check_input_end(common, fallbacks);
+ detect_partial_match(common, backtracks);
read_char(common);
if (common->nltype == NLTYPE_FIXED && common->newline > 255)
{
jump[0] = CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, (common->newline >> 8) & 0xff);
- jump[1] = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
+ if (common->mode != JIT_PARTIAL_HARD_COMPILE)
+ jump[1] = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
+ else
+ jump[1] = check_str_end(common);
+
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), 0);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, common->newline & 0xff));
- JUMPHERE(jump[1]);
+ add_jump(compiler, backtracks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, common->newline & 0xff));
+ if (jump[1] != NULL)
+ JUMPHERE(jump[1]);
JUMPHERE(jump[0]);
}
else
- check_newlinechar(common, common->nltype, fallbacks, TRUE);
+ check_newlinechar(common, common->nltype, backtracks, TRUE);
return cc;
case OP_ALLANY:
- check_input_end(common, fallbacks);
+ detect_partial_match(common, backtracks);
#ifdef SUPPORT_UTF
if (common->utf)
{
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), 0);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8 || defined COMPILE_PCRE16
+#if defined COMPILE_PCRE8
jump[0] = CMP(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xc0);
- OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_w)PRIV(utf8_table4) - 0xc0);
+ OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_sw)PRIV(utf8_table4) - 0xc0);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
-#else /* COMPILE_PCRE8 */
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
jump[0] = CMP(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xd800);
OP2(SLJIT_AND, TMP1, 0, TMP1, 0, SLJIT_IMM, 0xfc00);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, 0xd800);
- COND_VALUE(SLJIT_MOV, TMP1, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP1, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SHL, TMP1, 0, TMP1, 0, SLJIT_IMM, 1);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
-#endif /* COMPILE_PCRE16 */
-#endif /* COMPILE_PCRE8 */
+#endif
JUMPHERE(jump[0]);
+#endif /* COMPILE_PCRE[8|16] */
return cc;
}
#endif
@@ -3081,7 +4215,7 @@ switch(type)
return cc;
case OP_ANYBYTE:
- check_input_end(common, fallbacks);
+ detect_partial_match(common, backtracks);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
return cc;
@@ -3094,22 +4228,26 @@ switch(type)
propdata[2] = cc[0];
propdata[3] = cc[1];
propdata[4] = XCL_END;
- compile_xclass_hotpath(common, propdata, fallbacks);
+ compile_xclass_matchingpath(common, propdata, backtracks);
return cc + 2;
#endif
#endif
case OP_ANYNL:
- check_input_end(common, fallbacks);
+ detect_partial_match(common, backtracks);
read_char(common);
jump[0] = CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, CHAR_CR);
- jump[1] = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
+ /* We don't need to handle soft partial matching case. */
+ if (common->mode != JIT_PARTIAL_HARD_COMPILE)
+ jump[1] = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
+ else
+ jump[1] = check_str_end(common);
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), 0);
jump[2] = CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, CHAR_NL);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
jump[3] = JUMP(SLJIT_JUMP);
JUMPHERE(jump[0]);
- check_newlinechar(common, common->bsr_nltype, fallbacks, FALSE);
+ check_newlinechar(common, common->bsr_nltype, backtracks, FALSE);
JUMPHERE(jump[1]);
JUMPHERE(jump[2]);
JUMPHERE(jump[3]);
@@ -3117,58 +4255,90 @@ switch(type)
case OP_NOT_HSPACE:
case OP_HSPACE:
- check_input_end(common, fallbacks);
+ detect_partial_match(common, backtracks);
read_char(common);
add_jump(compiler, &common->hspace, JUMP(SLJIT_FAST_CALL));
- add_jump(compiler, fallbacks, JUMP(type == OP_NOT_HSPACE ? SLJIT_C_NOT_ZERO : SLJIT_C_ZERO));
+ add_jump(compiler, backtracks, JUMP(type == OP_NOT_HSPACE ? SLJIT_C_NOT_ZERO : SLJIT_C_ZERO));
return cc;
case OP_NOT_VSPACE:
case OP_VSPACE:
- check_input_end(common, fallbacks);
+ detect_partial_match(common, backtracks);
read_char(common);
add_jump(compiler, &common->vspace, JUMP(SLJIT_FAST_CALL));
- add_jump(compiler, fallbacks, JUMP(type == OP_NOT_VSPACE ? SLJIT_C_NOT_ZERO : SLJIT_C_ZERO));
+ add_jump(compiler, backtracks, JUMP(type == OP_NOT_VSPACE ? SLJIT_C_NOT_ZERO : SLJIT_C_ZERO));
return cc;
#ifdef SUPPORT_UCP
case OP_EXTUNI:
- check_input_end(common, fallbacks);
+ detect_partial_match(common, backtracks);
read_char(common);
add_jump(compiler, &common->getucd, JUMP(SLJIT_FAST_CALL));
- OP2(SLJIT_SUB, TMP1, 0, TMP1, 0, SLJIT_IMM, ucp_Mc);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_LESS_EQUAL, TMP1, 0, SLJIT_IMM, ucp_Mn - ucp_Mc));
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_IMM, (sljit_sw)PRIV(ucd_records) + SLJIT_OFFSETOF(ucd_record, gbprop));
+ /* Optimize register allocation: use a real register. */
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0, STACK_TOP, 0);
+ OP1(SLJIT_MOV_UB, STACK_TOP, 0, SLJIT_MEM2(TMP1, TMP2), 3);
label = LABEL();
jump[0] = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
OP1(SLJIT_MOV, TMP3, 0, STR_PTR, 0);
read_char(common);
add_jump(compiler, &common->getucd, JUMP(SLJIT_FAST_CALL));
- OP2(SLJIT_SUB, TMP1, 0, TMP1, 0, SLJIT_IMM, ucp_Mc);
- CMPTO(SLJIT_C_LESS_EQUAL, TMP1, 0, SLJIT_IMM, ucp_Mn - ucp_Mc, label);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_IMM, (sljit_sw)PRIV(ucd_records) + SLJIT_OFFSETOF(ucd_record, gbprop));
+ OP1(SLJIT_MOV_UB, TMP2, 0, SLJIT_MEM2(TMP1, TMP2), 3);
+
+ OP2(SLJIT_SHL, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, 2);
+ OP1(SLJIT_MOV_UI, TMP1, 0, SLJIT_MEM1(STACK_TOP), (sljit_sw)PRIV(ucp_gbtable));
+ OP1(SLJIT_MOV, STACK_TOP, 0, TMP2, 0);
+ OP2(SLJIT_SHL, TMP2, 0, SLJIT_IMM, 1, TMP2, 0);
+ OP2(SLJIT_AND | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, TMP2, 0);
+ JUMPTO(SLJIT_C_NOT_ZERO, label);
OP1(SLJIT_MOV, STR_PTR, 0, TMP3, 0);
JUMPHERE(jump[0]);
+ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0);
+
+ if (common->mode == JIT_PARTIAL_HARD_COMPILE)
+ {
+ jump[0] = CMP(SLJIT_C_LESS, STR_PTR, 0, STR_END, 0);
+ /* Since we successfully read a char above, partial matching must occure. */
+ check_partial(common, TRUE);
+ JUMPHERE(jump[0]);
+ }
return cc;
#endif
case OP_EODN:
+ /* Requires rather complex checks. */
jump[0] = CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0);
if (common->nltype == NLTYPE_FIXED && common->newline > 255)
{
OP2(SLJIT_ADD, TMP2, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(2));
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(0));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, STR_END, 0));
+ if (common->mode == JIT_COMPILE)
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, STR_END, 0));
+ else
+ {
+ jump[1] = CMP(SLJIT_C_EQUAL, TMP2, 0, STR_END, 0);
+ OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP2, 0, STR_END, 0);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_LESS);
+ OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, (common->newline >> 8) & 0xff);
+ OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_NOT_EQUAL);
+ add_jump(compiler, backtracks, JUMP(SLJIT_C_NOT_EQUAL));
+ check_partial(common, TRUE);
+ add_jump(compiler, backtracks, JUMP(SLJIT_JUMP));
+ JUMPHERE(jump[1]);
+ }
OP1(MOV_UCHAR, TMP2, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(1));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, (common->newline >> 8) & 0xff));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, common->newline & 0xff));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, (common->newline >> 8) & 0xff));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, common->newline & 0xff));
}
else if (common->nltype == NLTYPE_FIXED)
{
OP2(SLJIT_ADD, TMP2, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(0));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, STR_END, 0));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, common->newline));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, STR_END, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, common->newline));
}
else
{
@@ -3177,44 +4347,46 @@ switch(type)
OP2(SLJIT_ADD, TMP2, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(2));
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP2, 0, STR_END, 0);
jump[2] = JUMP(SLJIT_C_GREATER);
- add_jump(compiler, fallbacks, JUMP(SLJIT_C_LESS));
+ add_jump(compiler, backtracks, JUMP(SLJIT_C_LESS));
/* Equal. */
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(1));
jump[3] = CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, CHAR_NL);
- add_jump(compiler, fallbacks, JUMP(SLJIT_JUMP));
+ add_jump(compiler, backtracks, JUMP(SLJIT_JUMP));
JUMPHERE(jump[1]);
if (common->nltype == NLTYPE_ANYCRLF)
{
OP2(SLJIT_ADD, TMP2, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_LESS, TMP2, 0, STR_END, 0));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, CHAR_NL));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_LESS, TMP2, 0, STR_END, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, CHAR_NL));
}
else
{
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS1, STR_PTR, 0);
read_char(common);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, STR_PTR, 0, STR_END, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, STR_PTR, 0, STR_END, 0));
add_jump(compiler, &common->anynewline, JUMP(SLJIT_FAST_CALL));
- add_jump(compiler, fallbacks, JUMP(SLJIT_C_ZERO));
+ add_jump(compiler, backtracks, JUMP(SLJIT_C_ZERO));
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS1);
}
JUMPHERE(jump[2]);
JUMPHERE(jump[3]);
}
JUMPHERE(jump[0]);
+ check_partial(common, FALSE);
return cc;
case OP_EOD:
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, STR_PTR, 0, STR_END, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_LESS, STR_PTR, 0, STR_END, 0));
+ check_partial(common, FALSE);
return cc;
case OP_CIRC:
OP1(SLJIT_MOV, TMP2, 0, ARGUMENTS, 0);
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(TMP2), SLJIT_OFFSETOF(jit_arguments, begin));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_GREATER, STR_PTR, 0, TMP1, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_GREATER, STR_PTR, 0, TMP1, 0));
OP1(SLJIT_MOV_UB, TMP2, 0, SLJIT_MEM1(TMP2), SLJIT_OFFSETOF(jit_arguments, notbol));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
return cc;
case OP_CIRCM:
@@ -3222,25 +4394,25 @@ switch(type)
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(TMP2), SLJIT_OFFSETOF(jit_arguments, begin));
jump[1] = CMP(SLJIT_C_GREATER, STR_PTR, 0, TMP1, 0);
OP1(SLJIT_MOV_UB, TMP2, 0, SLJIT_MEM1(TMP2), SLJIT_OFFSETOF(jit_arguments, notbol));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
jump[0] = JUMP(SLJIT_JUMP);
JUMPHERE(jump[1]);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_EQUAL, STR_PTR, 0, STR_END, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_GREATER_EQUAL, STR_PTR, 0, STR_END, 0));
if (common->nltype == NLTYPE_FIXED && common->newline > 255)
{
OP2(SLJIT_SUB, TMP2, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(2));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_LESS, TMP2, 0, TMP1, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_LESS, TMP2, 0, TMP1, 0));
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(-2));
OP1(MOV_UCHAR, TMP2, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(-1));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, (common->newline >> 8) & 0xff));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, common->newline & 0xff));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, (common->newline >> 8) & 0xff));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, common->newline & 0xff));
}
else
{
skip_char_back(common);
read_char(common);
- check_newlinechar(common, common->nltype, fallbacks, FALSE);
+ check_newlinechar(common, common->nltype, backtracks, FALSE);
}
JUMPHERE(jump[0]);
return cc;
@@ -3248,35 +4420,50 @@ switch(type)
case OP_DOLL:
OP1(SLJIT_MOV, TMP2, 0, ARGUMENTS, 0);
OP1(SLJIT_MOV_UB, TMP2, 0, SLJIT_MEM1(TMP2), SLJIT_OFFSETOF(jit_arguments, noteol));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
if (!common->endonly)
- compile_char1_hotpath(common, OP_EODN, cc, fallbacks);
+ compile_char1_matchingpath(common, OP_EODN, cc, backtracks);
else
- add_jump(compiler, fallbacks, CMP(SLJIT_C_LESS, STR_PTR, 0, STR_END, 0));
+ {
+ add_jump(compiler, backtracks, CMP(SLJIT_C_LESS, STR_PTR, 0, STR_END, 0));
+ check_partial(common, FALSE);
+ }
return cc;
case OP_DOLLM:
jump[1] = CMP(SLJIT_C_LESS, STR_PTR, 0, STR_END, 0);
OP1(SLJIT_MOV, TMP2, 0, ARGUMENTS, 0);
OP1(SLJIT_MOV_UB, TMP2, 0, SLJIT_MEM1(TMP2), SLJIT_OFFSETOF(jit_arguments, noteol));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
+ check_partial(common, FALSE);
jump[0] = JUMP(SLJIT_JUMP);
JUMPHERE(jump[1]);
if (common->nltype == NLTYPE_FIXED && common->newline > 255)
{
OP2(SLJIT_ADD, TMP2, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(2));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_GREATER, TMP2, 0, STR_END, 0));
OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(0));
+ if (common->mode == JIT_COMPILE)
+ add_jump(compiler, backtracks, CMP(SLJIT_C_GREATER, TMP2, 0, STR_END, 0));
+ else
+ {
+ jump[1] = CMP(SLJIT_C_LESS_EQUAL, TMP2, 0, STR_END, 0);
+ /* STR_PTR = STR_END - IN_UCHARS(1) */
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, (common->newline >> 8) & 0xff));
+ check_partial(common, TRUE);
+ add_jump(compiler, backtracks, JUMP(SLJIT_JUMP));
+ JUMPHERE(jump[1]);
+ }
+
OP1(MOV_UCHAR, TMP2, 0, SLJIT_MEM1(STR_PTR), IN_UCHARS(1));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, (common->newline >> 8) & 0xff));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, common->newline & 0xff));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, (common->newline >> 8) & 0xff));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, common->newline & 0xff));
}
else
{
peek_char(common);
- check_newlinechar(common, common->nltype, fallbacks, FALSE);
+ check_newlinechar(common, common->nltype, backtracks, FALSE);
}
JUMPHERE(jump[0]);
return cc;
@@ -3287,19 +4474,19 @@ switch(type)
#ifdef SUPPORT_UTF
if (common->utf && HAS_EXTRALEN(*cc)) length += GET_EXTRALEN(*cc);
#endif
- if (type == OP_CHAR || !char_has_othercase(common, cc) || char_get_othercase_bit(common, cc) != 0)
+ if (common->mode == JIT_COMPILE && (type == OP_CHAR || !char_has_othercase(common, cc) || char_get_othercase_bit(common, cc) != 0))
{
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(length));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_GREATER, STR_PTR, 0, STR_END, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_GREATER, STR_PTR, 0, STR_END, 0));
context.length = IN_UCHARS(length);
context.sourcereg = -1;
#if defined SLJIT_UNALIGNED && SLJIT_UNALIGNED
context.ucharptr = 0;
#endif
- return byte_sequence_compare(common, type == OP_CHARI, cc, &context, fallbacks);
+ return byte_sequence_compare(common, type == OP_CHARI, cc, &context, backtracks);
}
- check_input_end(common, fallbacks);
+ detect_partial_match(common, backtracks);
read_char(common);
#ifdef SUPPORT_UTF
if (common->utf)
@@ -3309,16 +4496,29 @@ switch(type)
else
#endif
c = *cc;
+ if (type == OP_CHAR || !char_has_othercase(common, cc))
+ {
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, c));
+ return cc + length;
+ }
+ oc = char_othercase(common, c);
+ bit = c ^ oc;
+ if (is_powerof2(bit))
+ {
+ OP2(SLJIT_OR, TMP1, 0, TMP1, 0, SLJIT_IMM, bit);
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP1, 0, SLJIT_IMM, c | bit));
+ return cc + length;
+ }
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, c);
- COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_EQUAL);
- OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, char_othercase(common, c));
- COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_EQUAL);
- add_jump(compiler, fallbacks, JUMP(SLJIT_C_ZERO));
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
+ OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_IMM, oc);
+ OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
+ add_jump(compiler, backtracks, JUMP(SLJIT_C_ZERO));
return cc + length;
case OP_NOT:
case OP_NOTI:
- check_input_end(common, fallbacks);
+ detect_partial_match(common, backtracks);
length = 1;
#ifdef SUPPORT_UTF
if (common->utf)
@@ -3329,17 +4529,17 @@ switch(type)
{
OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(STR_PTR), 0);
if (type == OP_NOT || !char_has_othercase(common, cc))
- add_jump(compiler, fallbacks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, c));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, c));
else
{
/* Since UTF8 code page is fixed, we know that c is in [a-z] or [A-Z] range. */
OP2(SLJIT_OR, TMP2, 0, TMP1, 0, SLJIT_IMM, 0x20);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_EQUAL, TMP2, 0, SLJIT_IMM, c | 0x20));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_EQUAL, TMP2, 0, SLJIT_IMM, c | 0x20));
}
/* Skip the variable-length character. */
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(1));
jump[0] = CMP(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, 0xc0);
- OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_w)PRIV(utf8_table4) - 0xc0);
+ OP1(MOV_UCHAR, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_sw)PRIV(utf8_table4) - 0xc0);
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP1, 0);
JUMPHERE(jump[0]);
return cc + 1;
@@ -3359,28 +4559,31 @@ switch(type)
}
if (type == OP_NOT || !char_has_othercase(common, cc))
- add_jump(compiler, fallbacks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, c));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, c));
else
{
oc = char_othercase(common, c);
bit = c ^ oc;
- if (ispowerof2(bit))
+ if (is_powerof2(bit))
{
OP2(SLJIT_OR, TMP1, 0, TMP1, 0, SLJIT_IMM, bit);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, c | bit));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, c | bit));
}
else
{
- add_jump(compiler, fallbacks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, c));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, oc));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, c));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, oc));
}
}
- return cc + 1;
+ return cc + length;
case OP_CLASS:
case OP_NCLASS:
- check_input_end(common, fallbacks);
+ detect_partial_match(common, backtracks);
read_char(common);
+ if (check_class_ranges(common, (const pcre_uint8 *)cc, type == OP_NCLASS, backtracks))
+ return cc + 32 / sizeof(pcre_uchar);
+
#if defined SUPPORT_UTF || !defined COMPILE_PCRE8
jump[0] = NULL;
#ifdef COMPILE_PCRE8
@@ -3392,32 +4595,33 @@ switch(type)
jump[0] = CMP(SLJIT_C_GREATER, TMP1, 0, SLJIT_IMM, 255);
if (type == OP_CLASS)
{
- add_jump(compiler, fallbacks, jump[0]);
+ add_jump(compiler, backtracks, jump[0]);
jump[0] = NULL;
}
}
#endif /* SUPPORT_UTF || !COMPILE_PCRE8 */
OP2(SLJIT_AND, TMP2, 0, TMP1, 0, SLJIT_IMM, 0x7);
OP2(SLJIT_LSHR, TMP1, 0, TMP1, 0, SLJIT_IMM, 3);
- OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_w)cc);
+ OP1(SLJIT_MOV_UB, TMP1, 0, SLJIT_MEM1(TMP1), (sljit_sw)cc);
OP2(SLJIT_SHL, TMP2, 0, SLJIT_IMM, 1, TMP2, 0);
OP2(SLJIT_AND | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, TMP2, 0);
- add_jump(compiler, fallbacks, JUMP(SLJIT_C_ZERO));
+ add_jump(compiler, backtracks, JUMP(SLJIT_C_ZERO));
#if defined SUPPORT_UTF || !defined COMPILE_PCRE8
if (jump[0] != NULL)
JUMPHERE(jump[0]);
#endif /* SUPPORT_UTF || !COMPILE_PCRE8 */
return cc + 32 / sizeof(pcre_uchar);
-#if defined SUPPORT_UTF || defined COMPILE_PCRE16
+#if defined SUPPORT_UTF || defined COMPILE_PCRE16 || defined COMPILE_PCRE32
case OP_XCLASS:
- compile_xclass_hotpath(common, cc + LINK_SIZE, fallbacks);
+ compile_xclass_matchingpath(common, cc + LINK_SIZE, backtracks);
return cc + GET(cc, 0) - 1;
#endif
case OP_REVERSE:
length = GET(cc, 0);
- SLJIT_ASSERT(length > 0);
+ if (length == 0)
+ return cc + LINK_SIZE;
OP1(SLJIT_MOV, TMP1, 0, ARGUMENTS, 0);
#ifdef SUPPORT_UTF
if (common->utf)
@@ -3425,23 +4629,26 @@ switch(type)
OP1(SLJIT_MOV, TMP3, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, begin));
OP1(SLJIT_MOV, TMP2, 0, SLJIT_IMM, length);
label = LABEL();
- add_jump(compiler, fallbacks, CMP(SLJIT_C_LESS_EQUAL, STR_PTR, 0, TMP3, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_LESS_EQUAL, STR_PTR, 0, TMP3, 0));
skip_char_back(common);
OP2(SLJIT_SUB | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_IMM, 1);
JUMPTO(SLJIT_C_NOT_ZERO, label);
- return cc + LINK_SIZE;
}
+ else
#endif
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, begin));
- OP2(SLJIT_SUB, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(length));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_LESS, STR_PTR, 0, TMP1, 0));
+ {
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, begin));
+ OP2(SLJIT_SUB, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(length));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_LESS, STR_PTR, 0, TMP1, 0));
+ }
+ check_start_used_ptr(common);
return cc + LINK_SIZE;
}
SLJIT_ASSERT_STOP();
return cc;
}
-static SLJIT_INLINE pcre_uchar *compile_charn_hotpath(compiler_common *common, pcre_uchar *cc, pcre_uchar *ccend, jump_list **fallbacks)
+static SLJIT_INLINE pcre_uchar *compile_charn_matchingpath(compiler_common *common, pcre_uchar *cc, pcre_uchar *ccend, jump_list **backtracks)
{
/* This function consumes at least one input character. */
/* To decrease the number of length checks, we try to concatenate the fixed length character sequences. */
@@ -3493,21 +4700,21 @@ if (context.length > 0)
{
/* We have a fixed-length byte sequence. */
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, SLJIT_IMM, context.length);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_GREATER, STR_PTR, 0, STR_END, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_GREATER, STR_PTR, 0, STR_END, 0));
context.sourcereg = -1;
#if defined SLJIT_UNALIGNED && SLJIT_UNALIGNED
context.ucharptr = 0;
#endif
- do cc = byte_sequence_compare(common, *cc == OP_CHARI, cc + 1, &context, fallbacks); while (context.length > 0);
+ do cc = byte_sequence_compare(common, *cc == OP_CHARI, cc + 1, &context, backtracks); while (context.length > 0);
return cc;
}
/* A non-fixed length character will be checked if length == 0. */
-return compile_char1_hotpath(common, *cc, cc + 1, fallbacks);
+return compile_char1_matchingpath(common, *cc, cc + 1, backtracks);
}
-static struct sljit_jump *compile_ref_checks(compiler_common *common, pcre_uchar *cc, jump_list **fallbacks)
+static struct sljit_jump *compile_ref_checks(compiler_common *common, pcre_uchar *cc, jump_list **backtracks)
{
DEFINE_COMPILER;
int offset = GET2(cc, 1) << 1;
@@ -3515,76 +4722,89 @@ int offset = GET2(cc, 1) << 1;
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset));
if (!common->jscript_compat)
{
- if (fallbacks == NULL)
+ if (backtracks == NULL)
{
+ /* OVECTOR(1) contains the "string begin - 1" constant. */
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(1));
- COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_EQUAL);
OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_UNUSED, 0, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1));
- COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_EQUAL);
+ OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_EQUAL);
return JUMP(SLJIT_C_NOT_ZERO);
}
- add_jump(compiler, fallbacks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(1)));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(1)));
}
return CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1));
}
/* Forward definitions. */
-static void compile_hotpath(compiler_common *, pcre_uchar *, pcre_uchar *, fallback_common *);
-static void compile_fallbackpath(compiler_common *, struct fallback_common *);
+static void compile_matchingpath(compiler_common *, pcre_uchar *, pcre_uchar *, backtrack_common *);
+static void compile_backtrackingpath(compiler_common *, struct backtrack_common *);
-#define PUSH_FALLBACK(size, ccstart, error) \
+#define PUSH_BACKTRACK(size, ccstart, error) \
do \
{ \
- fallback = sljit_alloc_memory(compiler, (size)); \
+ backtrack = sljit_alloc_memory(compiler, (size)); \
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler))) \
return error; \
- memset(fallback, 0, size); \
- fallback->prev = parent->top; \
- fallback->cc = (ccstart); \
- parent->top = fallback; \
+ memset(backtrack, 0, size); \
+ backtrack->prev = parent->top; \
+ backtrack->cc = (ccstart); \
+ parent->top = backtrack; \
} \
while (0)
-#define PUSH_FALLBACK_NOVALUE(size, ccstart) \
+#define PUSH_BACKTRACK_NOVALUE(size, ccstart) \
do \
{ \
- fallback = sljit_alloc_memory(compiler, (size)); \
+ backtrack = sljit_alloc_memory(compiler, (size)); \
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler))) \
return; \
- memset(fallback, 0, size); \
- fallback->prev = parent->top; \
- fallback->cc = (ccstart); \
- parent->top = fallback; \
+ memset(backtrack, 0, size); \
+ backtrack->prev = parent->top; \
+ backtrack->cc = (ccstart); \
+ parent->top = backtrack; \
} \
while (0)
-#define FALLBACK_AS(type) ((type*)fallback)
+#define BACKTRACK_AS(type) ((type *)backtrack)
-static pcre_uchar *compile_ref_hotpath(compiler_common *common, pcre_uchar *cc, jump_list **fallbacks, BOOL withchecks, BOOL emptyfail)
+static pcre_uchar *compile_ref_matchingpath(compiler_common *common, pcre_uchar *cc, jump_list **backtracks, BOOL withchecks, BOOL emptyfail)
{
DEFINE_COMPILER;
int offset = GET2(cc, 1) << 1;
struct sljit_jump *jump = NULL;
+struct sljit_jump *partial;
+struct sljit_jump *nopartial;
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset));
+/* OVECTOR(1) contains the "string begin - 1" constant. */
if (withchecks && !common->jscript_compat)
- add_jump(compiler, fallbacks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(1)));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(1)));
#if defined SUPPORT_UTF && defined SUPPORT_UCP
if (common->utf && *cc == OP_REFI)
{
- SLJIT_ASSERT(TMP1 == SLJIT_TEMPORARY_REG1 && STACK_TOP == SLJIT_TEMPORARY_REG2 && TMP2 == SLJIT_TEMPORARY_REG3);
+ SLJIT_ASSERT(TMP1 == SLJIT_SCRATCH_REG1 && STACK_TOP == SLJIT_SCRATCH_REG2 && TMP2 == SLJIT_SCRATCH_REG3);
OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1));
if (withchecks)
jump = CMP(SLJIT_C_EQUAL, TMP1, 0, TMP2, 0);
/* Needed to save important temporary registers. */
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0, STACK_TOP, 0);
- OP1(SLJIT_MOV, SLJIT_TEMPORARY_REG2, 0, ARGUMENTS, 0);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_TEMPORARY_REG2), SLJIT_OFFSETOF(jit_arguments, ptr), STR_PTR, 0);
+ OP1(SLJIT_MOV, SLJIT_SCRATCH_REG2, 0, ARGUMENTS, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_SCRATCH_REG2), SLJIT_OFFSETOF(jit_arguments, uchar_ptr), STR_PTR, 0);
sljit_emit_ijump(compiler, SLJIT_CALL3, SLJIT_IMM, SLJIT_FUNC_OFFSET(do_utf_caselesscmp));
OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_EQUAL, SLJIT_RETURN_REG, 0, SLJIT_IMM, 0));
+ if (common->mode == JIT_COMPILE)
+ add_jump(compiler, backtracks, CMP(SLJIT_C_LESS_EQUAL, SLJIT_RETURN_REG, 0, SLJIT_IMM, 1));
+ else
+ {
+ add_jump(compiler, backtracks, CMP(SLJIT_C_EQUAL, SLJIT_RETURN_REG, 0, SLJIT_IMM, 0));
+ nopartial = CMP(SLJIT_C_NOT_EQUAL, SLJIT_RETURN_REG, 0, SLJIT_IMM, 1);
+ check_partial(common, FALSE);
+ add_jump(compiler, backtracks, JUMP(SLJIT_JUMP));
+ JUMPHERE(nopartial);
+ }
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_RETURN_REG, 0);
}
else
@@ -3593,27 +4813,47 @@ else
OP2(SLJIT_SUB | SLJIT_SET_E, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1), TMP1, 0);
if (withchecks)
jump = JUMP(SLJIT_C_ZERO);
+
OP2(SLJIT_ADD, STR_PTR, 0, STR_PTR, 0, TMP2, 0);
+ partial = CMP(SLJIT_C_GREATER, STR_PTR, 0, STR_END, 0);
+ if (common->mode == JIT_COMPILE)
+ add_jump(compiler, backtracks, partial);
- add_jump(compiler, fallbacks, CMP(SLJIT_C_GREATER, STR_PTR, 0, STR_END, 0));
add_jump(compiler, *cc == OP_REF ? &common->casefulcmp : &common->caselesscmp, JUMP(SLJIT_FAST_CALL));
- add_jump(compiler, fallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
+
+ if (common->mode != JIT_COMPILE)
+ {
+ nopartial = JUMP(SLJIT_JUMP);
+ JUMPHERE(partial);
+ /* TMP2 -= STR_END - STR_PTR */
+ OP2(SLJIT_SUB, TMP2, 0, TMP2, 0, STR_PTR, 0);
+ OP2(SLJIT_ADD, TMP2, 0, TMP2, 0, STR_END, 0);
+ partial = CMP(SLJIT_C_EQUAL, TMP2, 0, SLJIT_IMM, 0);
+ OP1(SLJIT_MOV, STR_PTR, 0, STR_END, 0);
+ add_jump(compiler, *cc == OP_REF ? &common->casefulcmp : &common->caselesscmp, JUMP(SLJIT_FAST_CALL));
+ add_jump(compiler, backtracks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
+ JUMPHERE(partial);
+ check_partial(common, FALSE);
+ add_jump(compiler, backtracks, JUMP(SLJIT_JUMP));
+ JUMPHERE(nopartial);
+ }
}
if (jump != NULL)
{
if (emptyfail)
- add_jump(compiler, fallbacks, jump);
+ add_jump(compiler, backtracks, jump);
else
JUMPHERE(jump);
}
return cc + 1 + IMM2_SIZE;
}
-static SLJIT_INLINE pcre_uchar *compile_ref_iterator_hotpath(compiler_common *common, pcre_uchar *cc, fallback_common *parent)
+static SLJIT_INLINE pcre_uchar *compile_ref_iterator_matchingpath(compiler_common *common, pcre_uchar *cc, backtrack_common *parent)
{
DEFINE_COMPILER;
-fallback_common *fallback;
+backtrack_common *backtrack;
pcre_uchar type;
struct sljit_label *label;
struct sljit_jump *zerolength;
@@ -3622,7 +4862,7 @@ pcre_uchar *ccbegin = cc;
int min = 0, max = 0;
BOOL minimize;
-PUSH_FALLBACK(sizeof(iterator_fallback), cc, NULL);
+PUSH_BACKTRACK(sizeof(iterator_backtrack), cc, NULL);
type = cc[1 + IMM2_SIZE];
minimize = (type & 0x1) != 0;
@@ -3665,23 +4905,23 @@ if (!minimize)
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_IMM, 0);
/* Temporary release of STR_PTR. */
- OP2(SLJIT_SUB, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_w));
+ OP2(SLJIT_SUB, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_sw));
zerolength = compile_ref_checks(common, ccbegin, NULL);
/* Restore if not zero length. */
- OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_w));
+ OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_sw));
}
else
{
allocate_stack(common, 1);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), SLJIT_IMM, 0);
- zerolength = compile_ref_checks(common, ccbegin, &fallback->topfallbacks);
+ zerolength = compile_ref_checks(common, ccbegin, &backtrack->topbacktracks);
}
if (min > 1 || max > 1)
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, SLJIT_IMM, 0);
label = LABEL();
- compile_ref_hotpath(common, ccbegin, &fallback->topfallbacks, FALSE, FALSE);
+ compile_ref_matchingpath(common, ccbegin, &backtrack->topbacktracks, FALSE, FALSE);
if (min > 1 || max > 1)
{
@@ -3709,7 +4949,7 @@ if (!minimize)
}
JUMPHERE(zerolength);
- FALLBACK_AS(iterator_fallback)->hotpath = LABEL();
+ BACKTRACK_AS(iterator_backtrack)->matchingpath = LABEL();
decrease_call_count(common);
return cc;
@@ -3727,13 +4967,13 @@ if (min == 0)
jump = JUMP(SLJIT_JUMP);
}
else
- zerolength = compile_ref_checks(common, ccbegin, &fallback->topfallbacks);
+ zerolength = compile_ref_checks(common, ccbegin, &backtrack->topbacktracks);
-FALLBACK_AS(iterator_fallback)->hotpath = LABEL();
+BACKTRACK_AS(iterator_backtrack)->matchingpath = LABEL();
if (max > 0)
- add_jump(compiler, &fallback->topfallbacks, CMP(SLJIT_C_GREATER_EQUAL, SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_IMM, max));
+ add_jump(compiler, &backtrack->topbacktracks, CMP(SLJIT_C_GREATER_EQUAL, SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_IMM, max));
-compile_ref_hotpath(common, ccbegin, &fallback->topfallbacks, TRUE, TRUE);
+compile_ref_matchingpath(common, ccbegin, &backtrack->topbacktracks, TRUE, TRUE);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
if (min > 1)
@@ -3741,7 +4981,7 @@ if (min > 1)
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), STACK(1));
OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 1);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), TMP1, 0);
- CMPTO(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, min, FALLBACK_AS(iterator_fallback)->hotpath);
+ CMPTO(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, min, BACKTRACK_AS(iterator_backtrack)->matchingpath);
}
else if (max > 0)
OP2(SLJIT_ADD, SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_IMM, 1);
@@ -3754,15 +4994,15 @@ decrease_call_count(common);
return cc;
}
-static SLJIT_INLINE pcre_uchar *compile_recurse_hotpath(compiler_common *common, pcre_uchar *cc, fallback_common *parent)
+static SLJIT_INLINE pcre_uchar *compile_recurse_matchingpath(compiler_common *common, pcre_uchar *cc, backtrack_common *parent)
{
DEFINE_COMPILER;
-fallback_common *fallback;
+backtrack_common *backtrack;
recurse_entry *entry = common->entries;
recurse_entry *prev = NULL;
int start = GET(cc, 1);
-PUSH_FALLBACK(sizeof(recurse_fallback), cc, NULL);
+PUSH_BACKTRACK(sizeof(recurse_backtrack), cc, NULL);
while (entry != NULL)
{
if (entry->start == start)
@@ -3787,36 +5027,49 @@ if (entry == NULL)
common->entries = entry;
}
-OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0));
-allocate_stack(common, 1);
-OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), TMP2, 0);
+if (common->has_set_som && common->mark_ptr != 0)
+ {
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0));
+ allocate_stack(common, 2);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->mark_ptr);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), TMP2, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), TMP1, 0);
+ }
+else if (common->has_set_som || common->mark_ptr != 0)
+ {
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->has_set_som ? (int)(OVECTOR(0)) : common->mark_ptr);
+ allocate_stack(common, 1);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), TMP2, 0);
+ }
if (entry->entry == NULL)
add_jump(compiler, &entry->calls, JUMP(SLJIT_FAST_CALL));
else
JUMPTO(SLJIT_FAST_CALL, entry->entry);
/* Leave if the match is failed. */
-add_jump(compiler, &fallback->topfallbacks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, 0));
+add_jump(compiler, &backtrack->topbacktracks, CMP(SLJIT_C_EQUAL, TMP1, 0, SLJIT_IMM, 0));
return cc + 1 + LINK_SIZE;
}
-static pcre_uchar *compile_assert_hotpath(compiler_common *common, pcre_uchar *cc, assert_fallback *fallback, BOOL conditional)
+static pcre_uchar *compile_assert_matchingpath(compiler_common *common, pcre_uchar *cc, assert_backtrack *backtrack, BOOL conditional)
{
DEFINE_COMPILER;
int framesize;
-int localptr;
-fallback_common altfallback;
+int private_data_ptr;
+backtrack_common altbacktrack;
pcre_uchar *ccbegin;
pcre_uchar opcode;
pcre_uchar bra = OP_BRA;
jump_list *tmp = NULL;
-jump_list **target = (conditional) ? &fallback->condfailed : &fallback->common.topfallbacks;
+jump_list **target = (conditional) ? &backtrack->condfailed : &backtrack->common.topbacktracks;
jump_list **found;
/* Saving previous accept variables. */
+struct sljit_label *save_quitlabel = common->quitlabel;
struct sljit_label *save_acceptlabel = common->acceptlabel;
+jump_list *save_quit = common->quit;
+jump_list *save_accept = common->accept;
struct sljit_jump *jump;
struct sljit_jump *brajump = NULL;
-jump_list *save_accept = common->accept;
if (*cc == OP_BRAZERO || *cc == OP_BRAMINZERO)
{
@@ -3824,11 +5077,11 @@ if (*cc == OP_BRAZERO || *cc == OP_BRAMINZERO)
bra = *cc;
cc++;
}
-localptr = PRIV_DATA(cc);
-SLJIT_ASSERT(localptr != 0);
+private_data_ptr = PRIVATE_DATA(cc);
+SLJIT_ASSERT(private_data_ptr != 0);
framesize = get_framesize(common, cc, FALSE);
-fallback->framesize = framesize;
-fallback->localptr = localptr;
+backtrack->framesize = framesize;
+backtrack->private_data_ptr = private_data_ptr;
opcode = *cc;
SLJIT_ASSERT(opcode >= OP_ASSERT && opcode <= OP_ASSERTBACK_NOT);
found = (opcode == OP_ASSERT || opcode == OP_ASSERTBACK) ? &tmp : target;
@@ -3837,7 +5090,7 @@ cc += GET(cc, 1);
if (bra == OP_BRAMINZERO)
{
- /* This is a braminzero fallback path. */
+ /* This is a braminzero backtrack path. */
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
free_stack(common, 1);
brajump = CMP(SLJIT_C_EQUAL, STR_PTR, 0, SLJIT_IMM, 0);
@@ -3845,37 +5098,41 @@ if (bra == OP_BRAMINZERO)
if (framesize < 0)
{
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, STACK_TOP, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, STACK_TOP, 0);
allocate_stack(common, 1);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
}
else
{
allocate_stack(common, framesize + 2);
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
OP2(SLJIT_SUB, TMP2, 0, STACK_TOP, 0, SLJIT_IMM, -STACK(framesize + 1));
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, TMP2, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, TMP2, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), TMP1, 0);
init_frame(common, ccbegin, framesize + 1, 2, FALSE);
}
-memset(&altfallback, 0, sizeof(fallback_common));
+memset(&altbacktrack, 0, sizeof(backtrack_common));
+common->quitlabel = NULL;
+common->quit = NULL;
while (1)
{
common->acceptlabel = NULL;
common->accept = NULL;
- altfallback.top = NULL;
- altfallback.topfallbacks = NULL;
+ altbacktrack.top = NULL;
+ altbacktrack.topbacktracks = NULL;
if (*ccbegin == OP_ALT)
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
- altfallback.cc = ccbegin;
- compile_hotpath(common, ccbegin + 1 + LINK_SIZE, cc, &altfallback);
+ altbacktrack.cc = ccbegin;
+ compile_matchingpath(common, ccbegin + 1 + LINK_SIZE, cc, &altbacktrack);
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler)))
{
+ common->quitlabel = save_quitlabel;
common->acceptlabel = save_acceptlabel;
+ common->quit = save_quit;
common->accept = save_accept;
return NULL;
}
@@ -3885,16 +5142,16 @@ while (1)
/* Reset stack. */
if (framesize < 0)
- OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
else {
if ((opcode != OP_ASSERT_NOT && opcode != OP_ASSERTBACK_NOT) || conditional)
{
- /* We don't need to keep the STR_PTR, only the previous localptr. */
- OP2(SLJIT_ADD, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_IMM, (framesize + 1) * sizeof(sljit_w));
+ /* We don't need to keep the STR_PTR, only the previous private_data_ptr. */
+ OP2(SLJIT_ADD, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, SLJIT_IMM, (framesize + 1) * sizeof(sljit_sw));
}
else
{
- OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
add_jump(compiler, &common->revertframes, JUMP(SLJIT_FAST_CALL));
}
}
@@ -3910,29 +5167,31 @@ while (1)
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), 0);
else
{
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), framesize * sizeof(sljit_w));
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), (framesize + 1) * sizeof(sljit_w));
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, TMP1, 0);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), framesize * sizeof(sljit_sw));
+ OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), (framesize + 1) * sizeof(sljit_sw));
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, TMP1, 0);
}
- OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_w));
+ OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_sw));
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), SLJIT_IMM, 0);
}
else if (framesize >= 0)
{
/* For OP_BRA and OP_BRAMINZERO. */
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_MEM1(STACK_TOP), framesize * sizeof(sljit_w));
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, SLJIT_MEM1(STACK_TOP), framesize * sizeof(sljit_sw));
}
}
add_jump(compiler, found, JUMP(SLJIT_JUMP));
- compile_fallbackpath(common, altfallback.top);
+ compile_backtrackingpath(common, altbacktrack.top);
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler)))
{
+ common->quitlabel = save_quitlabel;
common->acceptlabel = save_acceptlabel;
+ common->quit = save_quit;
common->accept = save_accept;
return NULL;
}
- set_jumps(altfallback.topfallbacks, LABEL());
+ set_jumps(altbacktrack.topbacktracks, LABEL());
if (*cc != OP_ALT)
break;
@@ -3941,6 +5200,8 @@ while (1)
cc += GET(cc, 1);
}
/* None of them matched. */
+if (common->quit != NULL)
+ set_jumps(common->quit, LABEL());
if (opcode == OP_ASSERT || opcode == OP_ASSERTBACK)
{
@@ -3967,7 +5228,7 @@ if (opcode == OP_ASSERT || opcode == OP_ASSERTBACK)
}
else
free_stack(common, framesize + 2);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, TMP1, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, TMP1, 0);
}
jump = JUMP(SLJIT_JUMP);
if (bra != OP_BRAZERO)
@@ -3981,10 +5242,10 @@ if (opcode == OP_ASSERT || opcode == OP_ASSERTBACK)
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), 0);
/* Keep the STR_PTR on the top of the stack. */
if (bra == OP_BRAZERO)
- OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_w));
+ OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_sw));
else if (bra == OP_BRAMINZERO)
{
- OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_w));
+ OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_sw));
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), SLJIT_IMM, 0);
}
}
@@ -3992,14 +5253,14 @@ if (opcode == OP_ASSERT || opcode == OP_ASSERTBACK)
{
if (bra == OP_BRA)
{
- /* We don't need to keep the STR_PTR, only the previous localptr. */
- OP2(SLJIT_ADD, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_IMM, (framesize + 1) * sizeof(sljit_w));
+ /* We don't need to keep the STR_PTR, only the previous private_data_ptr. */
+ OP2(SLJIT_ADD, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, SLJIT_IMM, (framesize + 1) * sizeof(sljit_sw));
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), 0);
}
else
{
- /* We don't need to keep the STR_PTR, only the previous localptr. */
- OP2(SLJIT_ADD, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_IMM, (framesize + 2) * sizeof(sljit_w));
+ /* We don't need to keep the STR_PTR, only the previous private_data_ptr. */
+ OP2(SLJIT_ADD, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, SLJIT_IMM, (framesize + 2) * sizeof(sljit_sw));
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), bra == OP_BRAZERO ? STR_PTR : SLJIT_IMM, 0);
}
@@ -4007,20 +5268,20 @@ if (opcode == OP_ASSERT || opcode == OP_ASSERTBACK)
if (bra == OP_BRAZERO)
{
- fallback->hotpath = LABEL();
- sljit_set_label(jump, fallback->hotpath);
+ backtrack->matchingpath = LABEL();
+ sljit_set_label(jump, backtrack->matchingpath);
}
else if (bra == OP_BRAMINZERO)
{
- JUMPTO(SLJIT_JUMP, fallback->hotpath);
+ JUMPTO(SLJIT_JUMP, backtrack->matchingpath);
JUMPHERE(brajump);
if (framesize >= 0)
{
- OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
add_jump(compiler, &common->revertframes, JUMP(SLJIT_FAST_CALL));
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_MEM1(STACK_TOP), framesize * sizeof(sljit_w));
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, SLJIT_MEM1(STACK_TOP), framesize * sizeof(sljit_sw));
}
- set_jumps(fallback->common.topfallbacks, LABEL());
+ set_jumps(backtrack->common.topbacktracks, LABEL());
}
}
else
@@ -4046,41 +5307,44 @@ else
}
else
free_stack(common, framesize + 2);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, TMP1, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, TMP1, 0);
}
if (bra == OP_BRAZERO)
- fallback->hotpath = LABEL();
+ backtrack->matchingpath = LABEL();
else if (bra == OP_BRAMINZERO)
{
- JUMPTO(SLJIT_JUMP, fallback->hotpath);
+ JUMPTO(SLJIT_JUMP, backtrack->matchingpath);
JUMPHERE(brajump);
}
if (bra != OP_BRA)
{
- SLJIT_ASSERT(found == &fallback->common.topfallbacks);
- set_jumps(fallback->common.topfallbacks, LABEL());
- fallback->common.topfallbacks = NULL;
+ SLJIT_ASSERT(found == &backtrack->common.topbacktracks);
+ set_jumps(backtrack->common.topbacktracks, LABEL());
+ backtrack->common.topbacktracks = NULL;
}
}
+common->quitlabel = save_quitlabel;
common->acceptlabel = save_acceptlabel;
+common->quit = save_quit;
common->accept = save_accept;
return cc + 1 + LINK_SIZE;
}
-static sljit_w SLJIT_CALL do_searchovector(sljit_w refno, sljit_w* locals, pcre_uchar *name_table)
+static sljit_sw SLJIT_CALL do_searchovector(sljit_uw refno, sljit_sw* locals, pcre_uchar *name_table)
{
int condition = FALSE;
pcre_uchar *slotA = name_table;
pcre_uchar *slotB;
-sljit_w name_count = locals[LOCALS0 / sizeof(sljit_w)];
-sljit_w name_entry_size = locals[LOCALS1 / sizeof(sljit_w)];
-sljit_w no_capture;
+sljit_sw name_count = locals[LOCALS0 / sizeof(sljit_sw)];
+sljit_sw name_entry_size = locals[LOCALS1 / sizeof(sljit_sw)];
+sljit_sw no_capture;
int i;
-locals += OVECTOR_START / sizeof(sljit_w);
+locals += refno & 0xff;
+refno >>= 8;
no_capture = locals[1];
for (i = 0; i < name_count; i++)
@@ -4126,15 +5390,15 @@ if (i < name_count)
return condition;
}
-static sljit_w SLJIT_CALL do_searchgroups(sljit_w recno, sljit_w* locals, pcre_uchar *name_table)
+static sljit_sw SLJIT_CALL do_searchgroups(sljit_uw recno, sljit_uw* locals, pcre_uchar *name_table)
{
int condition = FALSE;
pcre_uchar *slotA = name_table;
pcre_uchar *slotB;
-sljit_w name_count = locals[LOCALS0 / sizeof(sljit_w)];
-sljit_w name_entry_size = locals[LOCALS1 / sizeof(sljit_w)];
-sljit_w group_num = locals[POSSESSIVE0 / sizeof(sljit_w)];
-int i;
+sljit_uw name_count = locals[LOCALS0 / sizeof(sljit_sw)];
+sljit_uw name_entry_size = locals[LOCALS1 / sizeof(sljit_sw)];
+sljit_uw group_num = locals[POSSESSIVE0 / sizeof(sljit_sw)];
+sljit_uw i;
for (i = 0; i < name_count; i++)
{
@@ -4233,26 +5497,26 @@ return condition;
Or nothing, if trace is unnecessary
*/
-static pcre_uchar *compile_bracket_hotpath(compiler_common *common, pcre_uchar *cc, fallback_common *parent)
+static pcre_uchar *compile_bracket_matchingpath(compiler_common *common, pcre_uchar *cc, backtrack_common *parent)
{
DEFINE_COMPILER;
-fallback_common *fallback;
+backtrack_common *backtrack;
pcre_uchar opcode;
-int localptr = 0;
+int private_data_ptr = 0;
int offset = 0;
int stacksize;
pcre_uchar *ccbegin;
-pcre_uchar *hotpath;
+pcre_uchar *matchingpath;
pcre_uchar bra = OP_BRA;
pcre_uchar ket;
-assert_fallback *assert;
+assert_backtrack *assert;
BOOL has_alternatives;
struct sljit_jump *jump;
struct sljit_jump *skip;
struct sljit_label *rmaxlabel = NULL;
struct sljit_jump *braminzerojump = NULL;
-PUSH_FALLBACK(sizeof(bracket_fallback), cc, NULL);
+PUSH_BACKTRACK(sizeof(bracket_backtrack), cc, NULL);
if (*cc == OP_BRAZERO || *cc == OP_BRAMINZERO)
{
@@ -4263,12 +5527,12 @@ if (*cc == OP_BRAZERO || *cc == OP_BRAMINZERO)
opcode = *cc;
ccbegin = cc;
-hotpath = ccbegin + 1 + LINK_SIZE;
+matchingpath = ccbegin + 1 + LINK_SIZE;
if ((opcode == OP_COND || opcode == OP_SCOND) && cc[1 + LINK_SIZE] == OP_DEF)
{
- /* Drop this bracket_fallback. */
- parent->top = fallback->prev;
+ /* Drop this bracket_backtrack. */
+ parent->top = backtrack->prev;
return bracketend(cc);
}
@@ -4280,16 +5544,16 @@ cc += GET(cc, 1);
has_alternatives = *cc == OP_ALT;
if (SLJIT_UNLIKELY(opcode == OP_COND) || SLJIT_UNLIKELY(opcode == OP_SCOND))
{
- has_alternatives = (*hotpath == OP_RREF) ? FALSE : TRUE;
- if (*hotpath == OP_NRREF)
+ has_alternatives = (*matchingpath == OP_RREF) ? FALSE : TRUE;
+ if (*matchingpath == OP_NRREF)
{
- stacksize = GET2(hotpath, 1);
+ stacksize = GET2(matchingpath, 1);
if (common->currententry == NULL || stacksize == RREF_ANY)
has_alternatives = FALSE;
else if (common->currententry->start == 0)
has_alternatives = stacksize != 0;
else
- has_alternatives = stacksize != GET2(common->start, common->currententry->start + 1 + LINK_SIZE);
+ has_alternatives = stacksize != (int)GET2(common->start, common->currententry->start + 1 + LINK_SIZE);
}
}
@@ -4302,19 +5566,27 @@ if (opcode == OP_CBRA || opcode == OP_SCBRA)
{
/* Capturing brackets has a pre-allocated space. */
offset = GET2(ccbegin, 1 + LINK_SIZE);
- localptr = OVECTOR_PRIV(offset);
- offset <<= 1;
- FALLBACK_AS(bracket_fallback)->localptr = localptr;
- hotpath += IMM2_SIZE;
+ if (common->optimized_cbracket[offset] == 0)
+ {
+ private_data_ptr = OVECTOR_PRIV(offset);
+ offset <<= 1;
+ }
+ else
+ {
+ offset <<= 1;
+ private_data_ptr = OVECTOR(offset);
+ }
+ BACKTRACK_AS(bracket_backtrack)->private_data_ptr = private_data_ptr;
+ matchingpath += IMM2_SIZE;
}
else if (opcode == OP_ONCE || opcode == OP_SBRA || opcode == OP_SCOND)
{
/* Other brackets simply allocate the next entry. */
- localptr = PRIV_DATA(ccbegin);
- SLJIT_ASSERT(localptr != 0);
- FALLBACK_AS(bracket_fallback)->localptr = localptr;
+ private_data_ptr = PRIVATE_DATA(ccbegin);
+ SLJIT_ASSERT(private_data_ptr != 0);
+ BACKTRACK_AS(bracket_backtrack)->private_data_ptr = private_data_ptr;
if (opcode == OP_ONCE)
- FALLBACK_AS(bracket_fallback)->u.framesize = get_framesize(common, ccbegin, FALSE);
+ BACKTRACK_AS(bracket_backtrack)->u.framesize = get_framesize(common, ccbegin, FALSE);
}
/* Instructions before the first alternative. */
@@ -4339,7 +5611,7 @@ if (bra == OP_BRAZERO)
if (bra == OP_BRAMINZERO)
{
- /* This is a fallback path! (Since the hot-path of OP_BRAMINZERO matches to the empty string) */
+ /* This is a backtrack path! (Since the try-path of OP_BRAMINZERO matches to the empty string) */
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
if (ket != OP_KETRMIN)
{
@@ -4356,16 +5628,16 @@ if (bra == OP_BRAMINZERO)
skip = JUMP(SLJIT_JUMP);
JUMPHERE(jump);
/* Checking zero-length iteration. */
- if (opcode != OP_ONCE || FALLBACK_AS(bracket_fallback)->u.framesize < 0)
+ if (opcode != OP_ONCE || BACKTRACK_AS(bracket_backtrack)->u.framesize < 0)
{
- /* When we come from outside, localptr contains the previous STR_PTR. */
- braminzerojump = CMP(SLJIT_C_EQUAL, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ /* When we come from outside, private_data_ptr contains the previous STR_PTR. */
+ braminzerojump = CMP(SLJIT_C_EQUAL, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
}
else
{
/* Except when the whole stack frame must be saved. */
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
- braminzerojump = CMP(SLJIT_C_EQUAL, STR_PTR, 0, SLJIT_MEM1(TMP1), (FALLBACK_AS(bracket_fallback)->u.framesize + 1) * sizeof(sljit_w));
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
+ braminzerojump = CMP(SLJIT_C_EQUAL, STR_PTR, 0, SLJIT_MEM1(TMP1), (BACKTRACK_AS(bracket_backtrack)->u.framesize + 1) * sizeof(sljit_sw));
}
JUMPHERE(skip);
}
@@ -4379,79 +5651,92 @@ if (bra == OP_BRAMINZERO)
}
if (ket == OP_KETRMIN)
- FALLBACK_AS(bracket_fallback)->recursivehotpath = LABEL();
+ BACKTRACK_AS(bracket_backtrack)->recursive_matchingpath = LABEL();
if (ket == OP_KETRMAX)
{
rmaxlabel = LABEL();
if (has_alternatives && opcode != OP_ONCE && opcode < OP_SBRA)
- FALLBACK_AS(bracket_fallback)->althotpath = rmaxlabel;
+ BACKTRACK_AS(bracket_backtrack)->alternative_matchingpath = rmaxlabel;
}
/* Handling capturing brackets and alternatives. */
if (opcode == OP_ONCE)
{
- if (FALLBACK_AS(bracket_fallback)->u.framesize < 0)
+ if (BACKTRACK_AS(bracket_backtrack)->u.framesize < 0)
{
/* Neither capturing brackets nor recursions are not found in the block. */
if (ket == OP_KETRMIN)
{
- OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
allocate_stack(common, 2);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), TMP2, 0);
- OP2(SLJIT_SUB, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_w));
+ OP2(SLJIT_SUB, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_sw));
}
else if (ket == OP_KETRMAX || has_alternatives)
{
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, STACK_TOP, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, STACK_TOP, 0);
allocate_stack(common, 1);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
}
else
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, STACK_TOP, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, STACK_TOP, 0);
}
else
{
if (ket == OP_KETRMIN || ket == OP_KETRMAX || has_alternatives)
{
- allocate_stack(common, FALLBACK_AS(bracket_fallback)->u.framesize + 2);
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
- OP2(SLJIT_SUB, TMP2, 0, STACK_TOP, 0, SLJIT_IMM, -STACK(FALLBACK_AS(bracket_fallback)->u.framesize + 1));
+ allocate_stack(common, BACKTRACK_AS(bracket_backtrack)->u.framesize + 2);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
+ OP2(SLJIT_SUB, TMP2, 0, STACK_TOP, 0, SLJIT_IMM, -STACK(BACKTRACK_AS(bracket_backtrack)->u.framesize + 1));
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, TMP2, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, TMP2, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), TMP1, 0);
- init_frame(common, ccbegin, FALLBACK_AS(bracket_fallback)->u.framesize + 1, 2, FALSE);
+ init_frame(common, ccbegin, BACKTRACK_AS(bracket_backtrack)->u.framesize + 1, 2, FALSE);
}
else
{
- allocate_stack(common, FALLBACK_AS(bracket_fallback)->u.framesize + 1);
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
- OP2(SLJIT_SUB, TMP2, 0, STACK_TOP, 0, SLJIT_IMM, -STACK(FALLBACK_AS(bracket_fallback)->u.framesize));
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, TMP2, 0);
+ allocate_stack(common, BACKTRACK_AS(bracket_backtrack)->u.framesize + 1);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
+ OP2(SLJIT_SUB, TMP2, 0, STACK_TOP, 0, SLJIT_IMM, -STACK(BACKTRACK_AS(bracket_backtrack)->u.framesize));
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, TMP2, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), TMP1, 0);
- init_frame(common, ccbegin, FALLBACK_AS(bracket_fallback)->u.framesize, 1, FALSE);
+ init_frame(common, ccbegin, BACKTRACK_AS(bracket_backtrack)->u.framesize, 1, FALSE);
}
}
}
else if (opcode == OP_CBRA || opcode == OP_SCBRA)
{
/* Saving the previous values. */
- allocate_stack(common, 3);
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset));
- OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1));
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), TMP1, 0);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), TMP2, 0);
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, STR_PTR, 0);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(2), TMP1, 0);
+ if (common->optimized_cbracket[offset >> 1] == 0)
+ {
+ allocate_stack(common, 3);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset));
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1));
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), TMP1, 0);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), TMP2, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, STR_PTR, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(2), TMP1, 0);
+ }
+ else
+ {
+ SLJIT_ASSERT(private_data_ptr == OVECTOR(offset));
+ allocate_stack(common, 2);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr + sizeof(sljit_sw));
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, STR_PTR, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), TMP1, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), TMP2, 0);
+ }
}
else if (opcode == OP_SBRA || opcode == OP_SCOND)
{
/* Saving the previous value. */
- OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
allocate_stack(common, 1);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, STR_PTR, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, STR_PTR, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), TMP2, 0);
}
else if (has_alternatives)
@@ -4464,38 +5749,38 @@ else if (has_alternatives)
/* Generating code for the first alternative. */
if (opcode == OP_COND || opcode == OP_SCOND)
{
- if (*hotpath == OP_CREF)
+ if (*matchingpath == OP_CREF)
{
SLJIT_ASSERT(has_alternatives);
- add_jump(compiler, &(FALLBACK_AS(bracket_fallback)->u.condfailed),
- CMP(SLJIT_C_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(GET2(hotpath, 1) << 1), SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(1)));
- hotpath += 1 + IMM2_SIZE;
+ add_jump(compiler, &(BACKTRACK_AS(bracket_backtrack)->u.condfailed),
+ CMP(SLJIT_C_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(GET2(matchingpath, 1) << 1), SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(1)));
+ matchingpath += 1 + IMM2_SIZE;
}
- else if (*hotpath == OP_NCREF)
+ else if (*matchingpath == OP_NCREF)
{
SLJIT_ASSERT(has_alternatives);
- stacksize = GET2(hotpath, 1);
+ stacksize = GET2(matchingpath, 1);
jump = CMP(SLJIT_C_NOT_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(stacksize << 1), SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(1));
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1, STACK_TOP, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0, SLJIT_IMM, common->name_count);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS1, SLJIT_IMM, common->name_entry_size);
- OP1(SLJIT_MOV, SLJIT_TEMPORARY_REG1, 0, SLJIT_IMM, stacksize);
- OP1(SLJIT_MOV, SLJIT_TEMPORARY_REG2, 0, SLJIT_LOCALS_REG, 0);
- OP1(SLJIT_MOV, SLJIT_TEMPORARY_REG3, 0, SLJIT_IMM, common->name_table);
+ OP1(SLJIT_MOV, SLJIT_SCRATCH_REG1, 0, SLJIT_IMM, (stacksize << 8) | (common->ovector_start / sizeof(sljit_sw)));
+ GET_LOCAL_BASE(SLJIT_SCRATCH_REG2, 0, 0);
+ OP1(SLJIT_MOV, SLJIT_SCRATCH_REG3, 0, SLJIT_IMM, common->name_table);
sljit_emit_ijump(compiler, SLJIT_CALL3, SLJIT_IMM, SLJIT_FUNC_OFFSET(do_searchovector));
OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1);
- add_jump(compiler, &(FALLBACK_AS(bracket_fallback)->u.condfailed), CMP(SLJIT_C_EQUAL, SLJIT_TEMPORARY_REG1, 0, SLJIT_IMM, 0));
+ add_jump(compiler, &(BACKTRACK_AS(bracket_backtrack)->u.condfailed), CMP(SLJIT_C_EQUAL, SLJIT_SCRATCH_REG1, 0, SLJIT_IMM, 0));
JUMPHERE(jump);
- hotpath += 1 + IMM2_SIZE;
+ matchingpath += 1 + IMM2_SIZE;
}
- else if (*hotpath == OP_RREF || *hotpath == OP_NRREF)
+ else if (*matchingpath == OP_RREF || *matchingpath == OP_NRREF)
{
/* Never has other case. */
- FALLBACK_AS(bracket_fallback)->u.condfailed = NULL;
+ BACKTRACK_AS(bracket_backtrack)->u.condfailed = NULL;
- stacksize = GET2(hotpath, 1);
+ stacksize = GET2(matchingpath, 1);
if (common->currententry == NULL)
stacksize = 0;
else if (stacksize == RREF_ANY)
@@ -4503,78 +5788,78 @@ if (opcode == OP_COND || opcode == OP_SCOND)
else if (common->currententry->start == 0)
stacksize = stacksize == 0;
else
- stacksize = stacksize == GET2(common->start, common->currententry->start + 1 + LINK_SIZE);
+ stacksize = stacksize == (int)GET2(common->start, common->currententry->start + 1 + LINK_SIZE);
- if (*hotpath == OP_RREF || stacksize || common->currententry == NULL)
+ if (*matchingpath == OP_RREF || stacksize || common->currententry == NULL)
{
SLJIT_ASSERT(!has_alternatives);
if (stacksize != 0)
- hotpath += 1 + IMM2_SIZE;
+ matchingpath += 1 + IMM2_SIZE;
else
{
if (*cc == OP_ALT)
{
- hotpath = cc + 1 + LINK_SIZE;
+ matchingpath = cc + 1 + LINK_SIZE;
cc += GET(cc, 1);
}
else
- hotpath = cc;
+ matchingpath = cc;
}
}
else
{
SLJIT_ASSERT(has_alternatives);
- stacksize = GET2(hotpath, 1);
+ stacksize = GET2(matchingpath, 1);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1, STACK_TOP, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0, SLJIT_IMM, common->name_count);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS1, SLJIT_IMM, common->name_entry_size);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, SLJIT_IMM, GET2(common->start, common->currententry->start + 1 + LINK_SIZE));
- OP1(SLJIT_MOV, SLJIT_TEMPORARY_REG1, 0, SLJIT_IMM, stacksize);
- OP1(SLJIT_MOV, SLJIT_TEMPORARY_REG2, 0, SLJIT_LOCALS_REG, 0);
- OP1(SLJIT_MOV, SLJIT_TEMPORARY_REG3, 0, SLJIT_IMM, common->name_table);
+ OP1(SLJIT_MOV, SLJIT_SCRATCH_REG1, 0, SLJIT_IMM, stacksize);
+ GET_LOCAL_BASE(SLJIT_SCRATCH_REG2, 0, 0);
+ OP1(SLJIT_MOV, SLJIT_SCRATCH_REG3, 0, SLJIT_IMM, common->name_table);
sljit_emit_ijump(compiler, SLJIT_CALL3, SLJIT_IMM, SLJIT_FUNC_OFFSET(do_searchgroups));
OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1);
- add_jump(compiler, &(FALLBACK_AS(bracket_fallback)->u.condfailed), CMP(SLJIT_C_EQUAL, SLJIT_TEMPORARY_REG1, 0, SLJIT_IMM, 0));
- hotpath += 1 + IMM2_SIZE;
+ add_jump(compiler, &(BACKTRACK_AS(bracket_backtrack)->u.condfailed), CMP(SLJIT_C_EQUAL, SLJIT_SCRATCH_REG1, 0, SLJIT_IMM, 0));
+ matchingpath += 1 + IMM2_SIZE;
}
}
else
{
- SLJIT_ASSERT(has_alternatives && *hotpath >= OP_ASSERT && *hotpath <= OP_ASSERTBACK_NOT);
- /* Similar code as PUSH_FALLBACK macro. */
- assert = sljit_alloc_memory(compiler, sizeof(assert_fallback));
+ SLJIT_ASSERT(has_alternatives && *matchingpath >= OP_ASSERT && *matchingpath <= OP_ASSERTBACK_NOT);
+ /* Similar code as PUSH_BACKTRACK macro. */
+ assert = sljit_alloc_memory(compiler, sizeof(assert_backtrack));
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler)))
return NULL;
- memset(assert, 0, sizeof(assert_fallback));
- assert->common.cc = hotpath;
- FALLBACK_AS(bracket_fallback)->u.assert = assert;
- hotpath = compile_assert_hotpath(common, hotpath, assert, TRUE);
+ memset(assert, 0, sizeof(assert_backtrack));
+ assert->common.cc = matchingpath;
+ BACKTRACK_AS(bracket_backtrack)->u.assert = assert;
+ matchingpath = compile_assert_matchingpath(common, matchingpath, assert, TRUE);
}
}
-compile_hotpath(common, hotpath, cc, fallback);
+compile_matchingpath(common, matchingpath, cc, backtrack);
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler)))
return NULL;
if (opcode == OP_ONCE)
{
- if (FALLBACK_AS(bracket_fallback)->u.framesize < 0)
+ if (BACKTRACK_AS(bracket_backtrack)->u.framesize < 0)
{
- OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
/* TMP2 which is set here used by OP_KETRMAX below. */
if (ket == OP_KETRMAX)
OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(STACK_TOP), 0);
else if (ket == OP_KETRMIN)
{
- /* Move the STR_PTR to the localptr. */
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_MEM1(STACK_TOP), 0);
+ /* Move the STR_PTR to the private_data_ptr. */
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, SLJIT_MEM1(STACK_TOP), 0);
}
}
else
{
stacksize = (ket == OP_KETRMIN || ket == OP_KETRMAX || has_alternatives) ? 2 : 1;
- OP2(SLJIT_ADD, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_IMM, (FALLBACK_AS(bracket_fallback)->u.framesize + stacksize) * sizeof(sljit_w));
+ OP2(SLJIT_ADD, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, SLJIT_IMM, (BACKTRACK_AS(bracket_backtrack)->u.framesize + stacksize) * sizeof(sljit_sw));
if (ket == OP_KETRMAX)
{
/* TMP2 which is set here used by OP_KETRMAX below. */
@@ -4609,13 +5894,13 @@ if (has_alternatives)
if (opcode != OP_ONCE)
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(stacksize), SLJIT_IMM, 0);
if (ket != OP_KETRMAX)
- FALLBACK_AS(bracket_fallback)->althotpath = LABEL();
+ BACKTRACK_AS(bracket_backtrack)->alternative_matchingpath = LABEL();
}
-/* Must be after the hotpath label. */
+/* Must be after the matchingpath label. */
if (offset != 0)
{
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1), STR_PTR, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 0), TMP1, 0);
}
@@ -4625,41 +5910,46 @@ if (ket == OP_KETRMAX)
if (opcode == OP_ONCE || opcode >= OP_SBRA)
{
if (has_alternatives)
- FALLBACK_AS(bracket_fallback)->althotpath = LABEL();
+ BACKTRACK_AS(bracket_backtrack)->alternative_matchingpath = LABEL();
/* Checking zero-length iteration. */
if (opcode != OP_ONCE)
- CMPTO(SLJIT_C_NOT_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, STR_PTR, 0, rmaxlabel);
+ {
+ CMPTO(SLJIT_C_NOT_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, STR_PTR, 0, rmaxlabel);
+ /* Drop STR_PTR for greedy plus quantifier. */
+ if (bra != OP_BRAZERO)
+ free_stack(common, 1);
+ }
else
/* TMP2 must contain the starting STR_PTR. */
CMPTO(SLJIT_C_NOT_EQUAL, TMP2, 0, STR_PTR, 0, rmaxlabel);
}
else
JUMPTO(SLJIT_JUMP, rmaxlabel);
- FALLBACK_AS(bracket_fallback)->recursivehotpath = LABEL();
+ BACKTRACK_AS(bracket_backtrack)->recursive_matchingpath = LABEL();
}
if (bra == OP_BRAZERO)
- FALLBACK_AS(bracket_fallback)->zerohotpath = LABEL();
+ BACKTRACK_AS(bracket_backtrack)->zero_matchingpath = LABEL();
if (bra == OP_BRAMINZERO)
{
- /* This is a fallback path! (From the viewpoint of OP_BRAMINZERO) */
- JUMPTO(SLJIT_JUMP, ((braminzero_fallback*)parent)->hotpath);
+ /* This is a backtrack path! (From the viewpoint of OP_BRAMINZERO) */
+ JUMPTO(SLJIT_JUMP, ((braminzero_backtrack *)parent)->matchingpath);
if (braminzerojump != NULL)
{
JUMPHERE(braminzerojump);
/* We need to release the end pointer to perform the
- fallback for the zero-length iteration. When
+ backtrack for the zero-length iteration. When
framesize is < 0, OP_ONCE will do the release itself. */
- if (opcode == OP_ONCE && FALLBACK_AS(bracket_fallback)->u.framesize >= 0)
+ if (opcode == OP_ONCE && BACKTRACK_AS(bracket_backtrack)->u.framesize >= 0)
{
- OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
add_jump(compiler, &common->revertframes, JUMP(SLJIT_FAST_CALL));
}
else if (ket == OP_KETRMIN && opcode != OP_ONCE)
free_stack(common, 1);
}
- /* Continue to the normal fallback. */
+ /* Continue to the normal backtrack. */
}
if ((ket != OP_KET && bra != OP_BRAMINZERO) || bra == OP_BRAZERO)
@@ -4672,12 +5962,12 @@ cc += 1 + LINK_SIZE;
return cc;
}
-static pcre_uchar *compile_bracketpos_hotpath(compiler_common *common, pcre_uchar *cc, fallback_common *parent)
+static pcre_uchar *compile_bracketpos_matchingpath(compiler_common *common, pcre_uchar *cc, backtrack_common *parent)
{
DEFINE_COMPILER;
-fallback_common *fallback;
+backtrack_common *backtrack;
pcre_uchar opcode;
-int localptr;
+int private_data_ptr;
int cbraprivptr = 0;
int framesize;
int stacksize;
@@ -4688,7 +5978,7 @@ int stack;
struct sljit_label *loop = NULL;
struct jump_list *emptymatch = NULL;
-PUSH_FALLBACK(sizeof(bracketpos_fallback), cc, NULL);
+PUSH_BACKTRACK(sizeof(bracketpos_backtrack), cc, NULL);
if (*cc == OP_BRAPOSZERO)
{
zero = TRUE;
@@ -4696,9 +5986,9 @@ if (*cc == OP_BRAPOSZERO)
}
opcode = *cc;
-localptr = PRIV_DATA(cc);
-SLJIT_ASSERT(localptr != 0);
-FALLBACK_AS(bracketpos_fallback)->localptr = localptr;
+private_data_ptr = PRIVATE_DATA(cc);
+SLJIT_ASSERT(private_data_ptr != 0);
+BACKTRACK_AS(bracketpos_backtrack)->private_data_ptr = private_data_ptr;
switch(opcode)
{
case OP_BRAPOS:
@@ -4709,6 +5999,9 @@ switch(opcode)
case OP_CBRAPOS:
case OP_SCBRAPOS:
offset = GET2(cc, 1 + LINK_SIZE);
+ /* This case cannot be optimized in the same was as
+ normal capturing brackets. */
+ SLJIT_ASSERT(common->optimized_cbracket[offset] == 0);
cbraprivptr = OVECTOR_PRIV(offset);
offset <<= 1;
ccbegin = cc + 1 + LINK_SIZE + IMM2_SIZE;
@@ -4720,15 +6013,15 @@ switch(opcode)
}
framesize = get_framesize(common, cc, FALSE);
-FALLBACK_AS(bracketpos_fallback)->framesize = framesize;
+BACKTRACK_AS(bracketpos_backtrack)->framesize = framesize;
if (framesize < 0)
{
stacksize = (opcode == OP_CBRAPOS || opcode == OP_SCBRAPOS) ? 2 : 1;
if (!zero)
stacksize++;
- FALLBACK_AS(bracketpos_fallback)->stacksize = stacksize;
+ BACKTRACK_AS(bracketpos_backtrack)->stacksize = stacksize;
allocate_stack(common, stacksize);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, STACK_TOP, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, STACK_TOP, 0);
if (opcode == OP_CBRAPOS || opcode == OP_SCBRAPOS)
{
@@ -4750,12 +6043,12 @@ else
stacksize++;
if (opcode == OP_BRAPOS || opcode == OP_SBRAPOS)
stacksize++;
- FALLBACK_AS(bracketpos_fallback)->stacksize = stacksize;
+ BACKTRACK_AS(bracketpos_backtrack)->stacksize = stacksize;
allocate_stack(common, stacksize);
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
OP2(SLJIT_SUB, TMP2, 0, STACK_TOP, 0, SLJIT_IMM, -STACK(stacksize - 1));
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, TMP2, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, TMP2, 0);
stack = 0;
if (!zero)
{
@@ -4777,17 +6070,17 @@ if (opcode == OP_CBRAPOS || opcode == OP_SCBRAPOS)
loop = LABEL();
while (*cc != OP_KETRPOS)
{
- fallback->top = NULL;
- fallback->topfallbacks = NULL;
+ backtrack->top = NULL;
+ backtrack->topbacktracks = NULL;
cc += GET(cc, 1);
- compile_hotpath(common, ccbegin, cc, fallback);
+ compile_matchingpath(common, ccbegin, cc, backtrack);
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler)))
return NULL;
if (framesize < 0)
{
- OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
if (opcode == OP_CBRAPOS || opcode == OP_SCBRAPOS)
{
@@ -4813,7 +6106,7 @@ while (*cc != OP_KETRPOS)
{
if (opcode == OP_CBRAPOS || opcode == OP_SCBRAPOS)
{
- OP2(SLJIT_ADD, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_IMM, stacksize * sizeof(sljit_w));
+ OP2(SLJIT_ADD, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, SLJIT_IMM, stacksize * sizeof(sljit_sw));
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), cbraprivptr);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1), STR_PTR, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), cbraprivptr, STR_PTR, 0);
@@ -4821,11 +6114,11 @@ while (*cc != OP_KETRPOS)
}
else
{
- OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
- OP2(SLJIT_ADD, STACK_TOP, 0, TMP2, 0, SLJIT_IMM, stacksize * sizeof(sljit_w));
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
+ OP2(SLJIT_ADD, STACK_TOP, 0, TMP2, 0, SLJIT_IMM, stacksize * sizeof(sljit_sw));
if (opcode == OP_SBRAPOS)
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(TMP2), (framesize + 1) * sizeof(sljit_w));
- OP1(SLJIT_MOV, SLJIT_MEM1(TMP2), (framesize + 1) * sizeof(sljit_w), STR_PTR, 0);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(TMP2), (framesize + 1) * sizeof(sljit_sw));
+ OP1(SLJIT_MOV, SLJIT_MEM1(TMP2), (framesize + 1) * sizeof(sljit_sw), STR_PTR, 0);
}
if (opcode == OP_SBRAPOS || opcode == OP_SCBRAPOS)
@@ -4842,10 +6135,10 @@ while (*cc != OP_KETRPOS)
JUMPTO(SLJIT_JUMP, loop);
flush_stubs(common);
- compile_fallbackpath(common, fallback->top);
+ compile_backtrackingpath(common, backtrack->top);
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler)))
return NULL;
- set_jumps(fallback->topfallbacks, LABEL());
+ set_jumps(backtrack->topbacktracks, LABEL());
if (framesize < 0)
{
@@ -4860,13 +6153,13 @@ while (*cc != OP_KETRPOS)
{
/* Last alternative. */
if (*cc == OP_KETRPOS)
- OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), cbraprivptr);
}
else
{
- OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(TMP2), (framesize + 1) * sizeof(sljit_w));
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
+ OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(TMP2), (framesize + 1) * sizeof(sljit_sw));
}
}
@@ -4875,13 +6168,13 @@ while (*cc != OP_KETRPOS)
ccbegin = cc + 1 + LINK_SIZE;
}
-fallback->topfallbacks = NULL;
+backtrack->topbacktracks = NULL;
if (!zero)
{
if (framesize < 0)
- add_jump(compiler, &fallback->topfallbacks, CMP(SLJIT_C_NOT_EQUAL, SLJIT_MEM1(STACK_TOP), STACK(stacksize - 1), SLJIT_IMM, 0));
- else /* TMP2 is set to [localptr] above. */
- add_jump(compiler, &fallback->topfallbacks, CMP(SLJIT_C_NOT_EQUAL, SLJIT_MEM1(TMP2), (stacksize - 1) * sizeof(sljit_w), SLJIT_IMM, 0));
+ add_jump(compiler, &backtrack->topbacktracks, CMP(SLJIT_C_NOT_EQUAL, SLJIT_MEM1(STACK_TOP), STACK(stacksize - 1), SLJIT_IMM, 0));
+ else /* TMP2 is set to [private_data_ptr] above. */
+ add_jump(compiler, &backtrack->topbacktracks, CMP(SLJIT_C_NOT_EQUAL, SLJIT_MEM1(TMP2), (stacksize - 1) * sizeof(sljit_sw), SLJIT_IMM, 0));
}
/* None of them matched. */
@@ -4982,10 +6275,10 @@ if (end != NULL)
return cc;
}
-static pcre_uchar *compile_iterator_hotpath(compiler_common *common, pcre_uchar *cc, fallback_common *parent)
+static pcre_uchar *compile_iterator_matchingpath(compiler_common *common, pcre_uchar *cc, backtrack_common *parent)
{
DEFINE_COMPILER;
-fallback_common *fallback;
+backtrack_common *backtrack;
pcre_uchar opcode;
pcre_uchar type;
int arg1 = -1, arg2 = -1;
@@ -4993,11 +6286,55 @@ pcre_uchar* end;
jump_list *nomatch = NULL;
struct sljit_jump *jump = NULL;
struct sljit_label *label;
+int private_data_ptr = PRIVATE_DATA(cc);
+int base = (private_data_ptr == 0) ? SLJIT_MEM1(STACK_TOP) : SLJIT_MEM1(SLJIT_LOCALS_REG);
+int offset0 = (private_data_ptr == 0) ? STACK(0) : private_data_ptr;
+int offset1 = (private_data_ptr == 0) ? STACK(1) : private_data_ptr + (int)sizeof(sljit_sw);
+int tmp_base, tmp_offset;
-PUSH_FALLBACK(sizeof(iterator_fallback), cc, NULL);
+PUSH_BACKTRACK(sizeof(iterator_backtrack), cc, NULL);
cc = get_iterator_parameters(common, cc, &opcode, &type, &arg1, &arg2, &end);
+switch (type)
+ {
+ case OP_NOT_DIGIT:
+ case OP_DIGIT:
+ case OP_NOT_WHITESPACE:
+ case OP_WHITESPACE:
+ case OP_NOT_WORDCHAR:
+ case OP_WORDCHAR:
+ case OP_ANY:
+ case OP_ALLANY:
+ case OP_ANYBYTE:
+ case OP_ANYNL:
+ case OP_NOT_HSPACE:
+ case OP_HSPACE:
+ case OP_NOT_VSPACE:
+ case OP_VSPACE:
+ case OP_CHAR:
+ case OP_CHARI:
+ case OP_NOT:
+ case OP_NOTI:
+ case OP_CLASS:
+ case OP_NCLASS:
+ tmp_base = TMP3;
+ tmp_offset = 0;
+ break;
+
+ default:
+ SLJIT_ASSERT_STOP();
+ /* Fall through. */
+
+ case OP_EXTUNI:
+ case OP_XCLASS:
+ case OP_NOTPROP:
+ case OP_PROP:
+ tmp_base = SLJIT_MEM1(SLJIT_LOCALS_REG);
+ tmp_offset = POSSESSIVE0;
+ break;
+ }
+
switch(opcode)
{
case OP_STAR:
@@ -5006,6 +6343,7 @@ switch(opcode)
case OP_CRRANGE:
if (type == OP_ANYNL || type == OP_EXTUNI)
{
+ SLJIT_ASSERT(private_data_ptr == 0);
if (opcode == OP_STAR || opcode == OP_UPTO)
{
allocate_stack(common, 2);
@@ -5017,11 +6355,12 @@ switch(opcode)
allocate_stack(common, 1);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), SLJIT_IMM, 0);
}
+
if (opcode == OP_UPTO || opcode == OP_CRRANGE)
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, SLJIT_IMM, 0);
label = LABEL();
- compile_char1_hotpath(common, type, cc, &fallback->topfallbacks);
+ compile_char1_matchingpath(common, type, cc, &backtrack->topbacktracks);
if (opcode == OP_UPTO || opcode == OP_CRRANGE)
{
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0);
@@ -5033,6 +6372,7 @@ switch(opcode)
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, TMP1, 0);
}
+ /* We cannot use TMP3 because of this allocate_stack. */
allocate_stack(common, 1);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
JUMPTO(SLJIT_JUMP, label);
@@ -5041,105 +6381,107 @@ switch(opcode)
}
else
{
- allocate_stack(common, 2);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_IMM, 1);
+ if (opcode == OP_PLUS)
+ compile_char1_matchingpath(common, type, cc, &backtrack->topbacktracks);
+ if (private_data_ptr == 0)
+ allocate_stack(common, 2);
+ OP1(SLJIT_MOV, base, offset0, STR_PTR, 0);
+ if (opcode <= OP_PLUS)
+ OP1(SLJIT_MOV, base, offset1, STR_PTR, 0);
+ else
+ OP1(SLJIT_MOV, base, offset1, SLJIT_IMM, 1);
label = LABEL();
- compile_char1_hotpath(common, type, cc, &nomatch);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
- if (opcode <= OP_PLUS || (opcode == OP_CRRANGE && arg1 == 0))
+ compile_char1_matchingpath(common, type, cc, &nomatch);
+ OP1(SLJIT_MOV, base, offset0, STR_PTR, 0);
+ if (opcode <= OP_PLUS)
+ JUMPTO(SLJIT_JUMP, label);
+ else if (opcode == OP_CRRANGE && arg1 == 0)
{
- OP2(SLJIT_ADD, SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_IMM, 1);
+ OP2(SLJIT_ADD, base, offset1, base, offset1, SLJIT_IMM, 1);
JUMPTO(SLJIT_JUMP, label);
}
else
{
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), STACK(1));
+ OP1(SLJIT_MOV, TMP1, 0, base, offset1);
OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 1);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), TMP1, 0);
+ OP1(SLJIT_MOV, base, offset1, TMP1, 0);
CMPTO(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, arg1 + 1, label);
}
set_jumps(nomatch, LABEL());
- if (opcode == OP_PLUS || opcode == OP_CRRANGE)
- add_jump(compiler, &fallback->topfallbacks,
- CMP(SLJIT_C_LESS, SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_IMM, opcode == OP_PLUS ? 2 : arg2 + 1));
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
+ if (opcode == OP_CRRANGE)
+ add_jump(compiler, &backtrack->topbacktracks, CMP(SLJIT_C_LESS, base, offset1, SLJIT_IMM, arg2 + 1));
+ OP1(SLJIT_MOV, STR_PTR, 0, base, offset0);
}
- FALLBACK_AS(iterator_fallback)->hotpath = LABEL();
+ BACKTRACK_AS(iterator_backtrack)->matchingpath = LABEL();
break;
case OP_MINSTAR:
case OP_MINPLUS:
- allocate_stack(common, 1);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
if (opcode == OP_MINPLUS)
- add_jump(compiler, &fallback->topfallbacks, JUMP(SLJIT_JUMP));
- FALLBACK_AS(iterator_fallback)->hotpath = LABEL();
+ compile_char1_matchingpath(common, type, cc, &backtrack->topbacktracks);
+ if (private_data_ptr == 0)
+ allocate_stack(common, 1);
+ OP1(SLJIT_MOV, base, offset0, STR_PTR, 0);
+ BACKTRACK_AS(iterator_backtrack)->matchingpath = LABEL();
break;
case OP_MINUPTO:
case OP_CRMINRANGE:
- allocate_stack(common, 2);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_IMM, 1);
+ if (private_data_ptr == 0)
+ allocate_stack(common, 2);
+ OP1(SLJIT_MOV, base, offset0, STR_PTR, 0);
+ OP1(SLJIT_MOV, base, offset1, SLJIT_IMM, 1);
if (opcode == OP_CRMINRANGE)
- add_jump(compiler, &fallback->topfallbacks, JUMP(SLJIT_JUMP));
- FALLBACK_AS(iterator_fallback)->hotpath = LABEL();
+ add_jump(compiler, &backtrack->topbacktracks, JUMP(SLJIT_JUMP));
+ BACKTRACK_AS(iterator_backtrack)->matchingpath = LABEL();
break;
case OP_QUERY:
case OP_MINQUERY:
- allocate_stack(common, 1);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
+ if (private_data_ptr == 0)
+ allocate_stack(common, 1);
+ OP1(SLJIT_MOV, base, offset0, STR_PTR, 0);
if (opcode == OP_QUERY)
- compile_char1_hotpath(common, type, cc, &fallback->topfallbacks);
- FALLBACK_AS(iterator_fallback)->hotpath = LABEL();
+ compile_char1_matchingpath(common, type, cc, &backtrack->topbacktracks);
+ BACKTRACK_AS(iterator_backtrack)->matchingpath = LABEL();
break;
case OP_EXACT:
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, SLJIT_IMM, 1);
+ OP1(SLJIT_MOV, tmp_base, tmp_offset, SLJIT_IMM, arg1);
label = LABEL();
- compile_char1_hotpath(common, type, cc, &fallback->topfallbacks);
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0);
- OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 1);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, TMP1, 0);
- CMPTO(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, arg1 + 1, label);
+ compile_char1_matchingpath(common, type, cc, &backtrack->topbacktracks);
+ OP2(SLJIT_SUB | SLJIT_SET_E, tmp_base, tmp_offset, tmp_base, tmp_offset, SLJIT_IMM, 1);
+ JUMPTO(SLJIT_C_NOT_ZERO, label);
break;
case OP_POSSTAR:
case OP_POSPLUS:
case OP_POSUPTO:
- if (opcode != OP_POSSTAR)
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, SLJIT_IMM, 1);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1, STR_PTR, 0);
+ if (opcode == OP_POSPLUS)
+ compile_char1_matchingpath(common, type, cc, &backtrack->topbacktracks);
+ if (opcode == OP_POSUPTO)
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1, SLJIT_IMM, arg1);
+ OP1(SLJIT_MOV, tmp_base, tmp_offset, STR_PTR, 0);
label = LABEL();
- compile_char1_hotpath(common, type, cc, &nomatch);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1, STR_PTR, 0);
+ compile_char1_matchingpath(common, type, cc, &nomatch);
+ OP1(SLJIT_MOV, tmp_base, tmp_offset, STR_PTR, 0);
if (opcode != OP_POSUPTO)
- {
- if (opcode == OP_POSPLUS)
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, SLJIT_IMM, 2);
JUMPTO(SLJIT_JUMP, label);
- }
else
{
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0);
- OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 1);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, TMP1, 0);
- CMPTO(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, arg1 + 1, label);
+ OP2(SLJIT_SUB | SLJIT_SET_E, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1, SLJIT_IMM, 1);
+ JUMPTO(SLJIT_C_NOT_ZERO, label);
}
set_jumps(nomatch, LABEL());
- if (opcode == OP_POSPLUS)
- add_jump(compiler, &fallback->topfallbacks, CMP(SLJIT_C_LESS, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE0, SLJIT_IMM, 2));
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1);
+ OP1(SLJIT_MOV, STR_PTR, 0, tmp_base, tmp_offset);
break;
case OP_POSQUERY:
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1, STR_PTR, 0);
- compile_char1_hotpath(common, type, cc, &nomatch);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1, STR_PTR, 0);
+ OP1(SLJIT_MOV, tmp_base, tmp_offset, STR_PTR, 0);
+ compile_char1_matchingpath(common, type, cc, &nomatch);
+ OP1(SLJIT_MOV, tmp_base, tmp_offset, STR_PTR, 0);
set_jumps(nomatch, LABEL());
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), POSSESSIVE1);
+ OP1(SLJIT_MOV, STR_PTR, 0, tmp_base, tmp_offset);
break;
default:
@@ -5151,16 +6493,16 @@ decrease_call_count(common);
return end;
}
-static SLJIT_INLINE pcre_uchar *compile_fail_accept_hotpath(compiler_common *common, pcre_uchar *cc, fallback_common *parent)
+static SLJIT_INLINE pcre_uchar *compile_fail_accept_matchingpath(compiler_common *common, pcre_uchar *cc, backtrack_common *parent)
{
DEFINE_COMPILER;
-fallback_common *fallback;
+backtrack_common *backtrack;
-PUSH_FALLBACK(sizeof(bracket_fallback), cc, NULL);
+PUSH_BACKTRACK(sizeof(bracket_backtrack), cc, NULL);
if (*cc == OP_FAIL)
{
- add_jump(compiler, &fallback->topfallbacks, JUMP(SLJIT_JUMP));
+ add_jump(compiler, &backtrack->topbacktracks, JUMP(SLJIT_JUMP));
return cc + 1;
}
@@ -5180,7 +6522,7 @@ else
CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0), common->acceptlabel);
OP1(SLJIT_MOV, TMP1, 0, ARGUMENTS, 0);
OP1(SLJIT_MOV_UB, TMP2, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, notempty));
-add_jump(compiler, &fallback->topfallbacks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
+add_jump(compiler, &backtrack->topbacktracks, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0));
OP1(SLJIT_MOV_UB, TMP2, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, notempty_atstart));
if (common->acceptlabel == NULL)
add_jump(compiler, &common->accept, CMP(SLJIT_C_EQUAL, TMP2, 0, SLJIT_IMM, 0));
@@ -5191,30 +6533,33 @@ if (common->acceptlabel == NULL)
add_jump(compiler, &common->accept, CMP(SLJIT_C_NOT_EQUAL, TMP2, 0, STR_PTR, 0));
else
CMPTO(SLJIT_C_NOT_EQUAL, TMP2, 0, STR_PTR, 0, common->acceptlabel);
-add_jump(compiler, &fallback->topfallbacks, JUMP(SLJIT_JUMP));
+add_jump(compiler, &backtrack->topbacktracks, JUMP(SLJIT_JUMP));
return cc + 1;
}
-static SLJIT_INLINE pcre_uchar *compile_close_hotpath(compiler_common *common, pcre_uchar *cc)
+static SLJIT_INLINE pcre_uchar *compile_close_matchingpath(compiler_common *common, pcre_uchar *cc)
{
DEFINE_COMPILER;
int offset = GET2(cc, 1);
+BOOL optimized_cbracket = common->optimized_cbracket[offset] != 0;
/* Data will be discarded anyway... */
if (common->currententry != NULL)
return cc + 1 + IMM2_SIZE;
-OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR_PRIV(offset));
+if (!optimized_cbracket)
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR_PRIV(offset));
offset <<= 1;
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1), STR_PTR, 0);
-OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset), TMP1, 0);
+if (!optimized_cbracket)
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset), TMP1, 0);
return cc + 1 + IMM2_SIZE;
}
-static void compile_hotpath(compiler_common *common, pcre_uchar *cc, pcre_uchar *ccend, fallback_common *parent)
+static void compile_matchingpath(compiler_common *common, pcre_uchar *cc, pcre_uchar *ccend, backtrack_common *parent)
{
DEFINE_COMPILER;
-fallback_common *fallback;
+backtrack_common *backtrack;
while (cc < ccend)
{
@@ -5250,21 +6595,24 @@ while (cc < ccend)
case OP_NOT:
case OP_NOTI:
case OP_REVERSE:
- cc = compile_char1_hotpath(common, *cc, cc + 1, parent->top != NULL ? &parent->top->nextfallbacks : &parent->topfallbacks);
+ cc = compile_char1_matchingpath(common, *cc, cc + 1, parent->top != NULL ? &parent->top->nextbacktracks : &parent->topbacktracks);
break;
case OP_SET_SOM:
- PUSH_FALLBACK_NOVALUE(sizeof(fallback_common), cc);
+ PUSH_BACKTRACK_NOVALUE(sizeof(backtrack_common), cc);
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0));
allocate_stack(common, 1);
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0));
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0), STR_PTR, 0);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), TMP1, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), TMP2, 0);
cc++;
break;
case OP_CHAR:
case OP_CHARI:
- cc = compile_charn_hotpath(common, cc, ccend, parent->top != NULL ? &parent->top->nextfallbacks : &parent->topfallbacks);
+ if (common->mode == JIT_COMPILE)
+ cc = compile_charn_matchingpath(common, cc, ccend, parent->top != NULL ? &parent->top->nextbacktracks : &parent->topbacktracks);
+ else
+ cc = compile_char1_matchingpath(common, *cc, cc + 1, parent->top != NULL ? &parent->top->nextbacktracks : &parent->topbacktracks);
break;
case OP_STAR:
@@ -5332,48 +6680,48 @@ while (cc < ccend)
case OP_TYPEPOSPLUS:
case OP_TYPEPOSQUERY:
case OP_TYPEPOSUPTO:
- cc = compile_iterator_hotpath(common, cc, parent);
+ cc = compile_iterator_matchingpath(common, cc, parent);
break;
case OP_CLASS:
case OP_NCLASS:
if (cc[1 + (32 / sizeof(pcre_uchar))] >= OP_CRSTAR && cc[1 + (32 / sizeof(pcre_uchar))] <= OP_CRMINRANGE)
- cc = compile_iterator_hotpath(common, cc, parent);
+ cc = compile_iterator_matchingpath(common, cc, parent);
else
- cc = compile_char1_hotpath(common, *cc, cc + 1, parent->top != NULL ? &parent->top->nextfallbacks : &parent->topfallbacks);
+ cc = compile_char1_matchingpath(common, *cc, cc + 1, parent->top != NULL ? &parent->top->nextbacktracks : &parent->topbacktracks);
break;
-#if defined SUPPORT_UTF || defined COMPILE_PCRE16
+#if defined SUPPORT_UTF || defined COMPILE_PCRE16 || defined COMPILE_PCRE32
case OP_XCLASS:
if (*(cc + GET(cc, 1)) >= OP_CRSTAR && *(cc + GET(cc, 1)) <= OP_CRMINRANGE)
- cc = compile_iterator_hotpath(common, cc, parent);
+ cc = compile_iterator_matchingpath(common, cc, parent);
else
- cc = compile_char1_hotpath(common, *cc, cc + 1, parent->top != NULL ? &parent->top->nextfallbacks : &parent->topfallbacks);
+ cc = compile_char1_matchingpath(common, *cc, cc + 1, parent->top != NULL ? &parent->top->nextbacktracks : &parent->topbacktracks);
break;
#endif
case OP_REF:
case OP_REFI:
if (cc[1 + IMM2_SIZE] >= OP_CRSTAR && cc[1 + IMM2_SIZE] <= OP_CRMINRANGE)
- cc = compile_ref_iterator_hotpath(common, cc, parent);
+ cc = compile_ref_iterator_matchingpath(common, cc, parent);
else
- cc = compile_ref_hotpath(common, cc, parent->top != NULL ? &parent->top->nextfallbacks : &parent->topfallbacks, TRUE, FALSE);
+ cc = compile_ref_matchingpath(common, cc, parent->top != NULL ? &parent->top->nextbacktracks : &parent->topbacktracks, TRUE, FALSE);
break;
case OP_RECURSE:
- cc = compile_recurse_hotpath(common, cc, parent);
+ cc = compile_recurse_matchingpath(common, cc, parent);
break;
case OP_ASSERT:
case OP_ASSERT_NOT:
case OP_ASSERTBACK:
case OP_ASSERTBACK_NOT:
- PUSH_FALLBACK_NOVALUE(sizeof(assert_fallback), cc);
- cc = compile_assert_hotpath(common, cc, FALLBACK_AS(assert_fallback), FALSE);
+ PUSH_BACKTRACK_NOVALUE(sizeof(assert_backtrack), cc);
+ cc = compile_assert_matchingpath(common, cc, BACKTRACK_AS(assert_backtrack), FALSE);
break;
case OP_BRAMINZERO:
- PUSH_FALLBACK_NOVALUE(sizeof(braminzero_fallback), cc);
+ PUSH_BACKTRACK_NOVALUE(sizeof(braminzero_backtrack), cc);
cc = bracketend(cc + 1);
if (*(cc - 1 - LINK_SIZE) != OP_KETRMIN)
{
@@ -5386,7 +6734,7 @@ while (cc < ccend)
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), SLJIT_IMM, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), STR_PTR, 0);
}
- FALLBACK_AS(braminzero_fallback)->hotpath = LABEL();
+ BACKTRACK_AS(braminzero_backtrack)->matchingpath = LABEL();
if (cc[1] > OP_ASSERTBACK_NOT)
decrease_call_count(common);
break;
@@ -5399,16 +6747,16 @@ while (cc < ccend)
case OP_SBRA:
case OP_SCBRA:
case OP_SCOND:
- cc = compile_bracket_hotpath(common, cc, parent);
+ cc = compile_bracket_matchingpath(common, cc, parent);
break;
case OP_BRAZERO:
if (cc[1] > OP_ASSERTBACK_NOT)
- cc = compile_bracket_hotpath(common, cc, parent);
+ cc = compile_bracket_matchingpath(common, cc, parent);
else
{
- PUSH_FALLBACK_NOVALUE(sizeof(assert_fallback), cc);
- cc = compile_assert_hotpath(common, cc, FALLBACK_AS(assert_fallback), FALSE);
+ PUSH_BACKTRACK_NOVALUE(sizeof(assert_backtrack), cc);
+ cc = compile_assert_matchingpath(common, cc, BACKTRACK_AS(assert_backtrack), FALSE);
}
break;
@@ -5417,17 +6765,35 @@ while (cc < ccend)
case OP_SBRAPOS:
case OP_SCBRAPOS:
case OP_BRAPOSZERO:
- cc = compile_bracketpos_hotpath(common, cc, parent);
+ cc = compile_bracketpos_matchingpath(common, cc, parent);
+ break;
+
+ case OP_MARK:
+ PUSH_BACKTRACK_NOVALUE(sizeof(backtrack_common), cc);
+ SLJIT_ASSERT(common->mark_ptr != 0);
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->mark_ptr);
+ allocate_stack(common, 1);
+ OP1(SLJIT_MOV, TMP1, 0, ARGUMENTS, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), TMP2, 0);
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_IMM, (sljit_sw)(cc + 2));
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->mark_ptr, TMP2, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, mark_ptr), TMP2, 0);
+ cc += 1 + 2 + cc[1];
+ break;
+
+ case OP_COMMIT:
+ PUSH_BACKTRACK_NOVALUE(sizeof(backtrack_common), cc);
+ cc += 1;
break;
case OP_FAIL:
case OP_ACCEPT:
case OP_ASSERT_ACCEPT:
- cc = compile_fail_accept_hotpath(common, cc, parent);
+ cc = compile_fail_accept_matchingpath(common, cc, parent);
break;
case OP_CLOSE:
- cc = compile_close_hotpath(common, cc);
+ cc = compile_close_matchingpath(common, cc);
break;
case OP_SKIPZERO:
@@ -5444,22 +6810,22 @@ while (cc < ccend)
SLJIT_ASSERT(cc == ccend);
}
-#undef PUSH_FALLBACK
-#undef PUSH_FALLBACK_NOVALUE
-#undef FALLBACK_AS
+#undef PUSH_BACKTRACK
+#undef PUSH_BACKTRACK_NOVALUE
+#undef BACKTRACK_AS
-#define COMPILE_FALLBACKPATH(current) \
+#define COMPILE_BACKTRACKINGPATH(current) \
do \
{ \
- compile_fallbackpath(common, (current)); \
+ compile_backtrackingpath(common, (current)); \
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler))) \
return; \
} \
while (0)
-#define CURRENT_AS(type) ((type*)current)
+#define CURRENT_AS(type) ((type *)current)
-static void compile_iterator_fallbackpath(compiler_common *common, struct fallback_common *current)
+static void compile_iterator_backtrackingpath(compiler_common *common, struct backtrack_common *current)
{
DEFINE_COMPILER;
pcre_uchar *cc = current->cc;
@@ -5468,6 +6834,11 @@ pcre_uchar type;
int arg1 = -1, arg2 = -1;
struct sljit_label *label = NULL;
struct sljit_jump *jump = NULL;
+jump_list *jumplist = NULL;
+int private_data_ptr = PRIVATE_DATA(cc);
+int base = (private_data_ptr == 0) ? SLJIT_MEM1(STACK_TOP) : SLJIT_MEM1(SLJIT_LOCALS_REG);
+int offset0 = (private_data_ptr == 0) ? STACK(0) : private_data_ptr;
+int offset1 = (private_data_ptr == 0) ? STACK(1) : private_data_ptr + (int)sizeof(sljit_sw);
cc = get_iterator_parameters(common, cc, &opcode, &type, &arg1, &arg2, NULL);
@@ -5479,100 +6850,111 @@ switch(opcode)
case OP_CRRANGE:
if (type == OP_ANYNL || type == OP_EXTUNI)
{
- set_jumps(current->topfallbacks, LABEL());
+ SLJIT_ASSERT(private_data_ptr == 0);
+ set_jumps(current->topbacktracks, LABEL());
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
free_stack(common, 1);
- CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(iterator_fallback)->hotpath);
+ CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(iterator_backtrack)->matchingpath);
}
else
{
- if (opcode == OP_STAR || opcode == OP_UPTO)
+ if (opcode == OP_UPTO)
arg2 = 0;
- else if (opcode == OP_PLUS)
- arg2 = 1;
- jump = CMP(SLJIT_C_LESS_EQUAL, SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_IMM, arg2 + 1);
- OP2(SLJIT_SUB, SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_MEM1(STACK_TOP), STACK(1), SLJIT_IMM, 1);
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
+ if (opcode <= OP_PLUS)
+ {
+ OP1(SLJIT_MOV, STR_PTR, 0, base, offset0);
+ jump = CMP(SLJIT_C_LESS_EQUAL, STR_PTR, 0, base, offset1);
+ }
+ else
+ {
+ OP1(SLJIT_MOV, TMP1, 0, base, offset1);
+ OP1(SLJIT_MOV, STR_PTR, 0, base, offset0);
+ jump = CMP(SLJIT_C_LESS_EQUAL, TMP1, 0, SLJIT_IMM, arg2 + 1);
+ OP2(SLJIT_SUB, base, offset1, TMP1, 0, SLJIT_IMM, 1);
+ }
skip_char_back(common);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
- JUMPTO(SLJIT_JUMP, CURRENT_AS(iterator_fallback)->hotpath);
- if (opcode == OP_PLUS || opcode == OP_CRRANGE)
- set_jumps(current->topfallbacks, LABEL());
+ OP1(SLJIT_MOV, base, offset0, STR_PTR, 0);
+ JUMPTO(SLJIT_JUMP, CURRENT_AS(iterator_backtrack)->matchingpath);
+ if (opcode == OP_CRRANGE)
+ set_jumps(current->topbacktracks, LABEL());
JUMPHERE(jump);
- free_stack(common, 2);
+ if (private_data_ptr == 0)
+ free_stack(common, 2);
+ if (opcode == OP_PLUS)
+ set_jumps(current->topbacktracks, LABEL());
}
break;
case OP_MINSTAR:
case OP_MINPLUS:
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
+ OP1(SLJIT_MOV, STR_PTR, 0, base, offset0);
+ compile_char1_matchingpath(common, type, cc, &jumplist);
+ OP1(SLJIT_MOV, base, offset0, STR_PTR, 0);
+ JUMPTO(SLJIT_JUMP, CURRENT_AS(iterator_backtrack)->matchingpath);
+ set_jumps(jumplist, LABEL());
+ if (private_data_ptr == 0)
+ free_stack(common, 1);
if (opcode == OP_MINPLUS)
- {
- set_jumps(current->topfallbacks, LABEL());
- current->topfallbacks = NULL;
- }
- compile_char1_hotpath(common, type, cc, &current->topfallbacks);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
- JUMPTO(SLJIT_JUMP, CURRENT_AS(iterator_fallback)->hotpath);
- set_jumps(current->topfallbacks, LABEL());
- free_stack(common, 1);
+ set_jumps(current->topbacktracks, LABEL());
break;
case OP_MINUPTO:
case OP_CRMINRANGE:
if (opcode == OP_CRMINRANGE)
{
- set_jumps(current->topfallbacks, LABEL());
- current->topfallbacks = NULL;
label = LABEL();
+ set_jumps(current->topbacktracks, label);
}
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
- compile_char1_hotpath(common, type, cc, &current->topfallbacks);
+ OP1(SLJIT_MOV, STR_PTR, 0, base, offset0);
+ compile_char1_matchingpath(common, type, cc, &jumplist);
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), STACK(1));
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
+ OP1(SLJIT_MOV, TMP1, 0, base, offset1);
+ OP1(SLJIT_MOV, base, offset0, STR_PTR, 0);
OP2(SLJIT_ADD, TMP1, 0, TMP1, 0, SLJIT_IMM, 1);
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(1), TMP1, 0);
+ OP1(SLJIT_MOV, base, offset1, TMP1, 0);
if (opcode == OP_CRMINRANGE)
CMPTO(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, arg2 + 1, label);
if (opcode == OP_CRMINRANGE && arg1 == 0)
- JUMPTO(SLJIT_JUMP, CURRENT_AS(iterator_fallback)->hotpath);
+ JUMPTO(SLJIT_JUMP, CURRENT_AS(iterator_backtrack)->matchingpath);
else
- CMPTO(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, arg1 + 2, CURRENT_AS(iterator_fallback)->hotpath);
+ CMPTO(SLJIT_C_LESS, TMP1, 0, SLJIT_IMM, arg1 + 2, CURRENT_AS(iterator_backtrack)->matchingpath);
- set_jumps(current->topfallbacks, LABEL());
- free_stack(common, 2);
+ set_jumps(jumplist, LABEL());
+ if (private_data_ptr == 0)
+ free_stack(common, 2);
break;
case OP_QUERY:
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), SLJIT_IMM, 0);
- CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(iterator_fallback)->hotpath);
+ OP1(SLJIT_MOV, STR_PTR, 0, base, offset0);
+ OP1(SLJIT_MOV, base, offset0, SLJIT_IMM, 0);
+ CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(iterator_backtrack)->matchingpath);
jump = JUMP(SLJIT_JUMP);
- set_jumps(current->topfallbacks, LABEL());
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), SLJIT_IMM, 0);
- JUMPTO(SLJIT_JUMP, CURRENT_AS(iterator_fallback)->hotpath);
+ set_jumps(current->topbacktracks, LABEL());
+ OP1(SLJIT_MOV, STR_PTR, 0, base, offset0);
+ OP1(SLJIT_MOV, base, offset0, SLJIT_IMM, 0);
+ JUMPTO(SLJIT_JUMP, CURRENT_AS(iterator_backtrack)->matchingpath);
JUMPHERE(jump);
- free_stack(common, 1);
+ if (private_data_ptr == 0)
+ free_stack(common, 1);
break;
case OP_MINQUERY:
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
- OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), SLJIT_IMM, 0);
+ OP1(SLJIT_MOV, STR_PTR, 0, base, offset0);
+ OP1(SLJIT_MOV, base, offset0, SLJIT_IMM, 0);
jump = CMP(SLJIT_C_EQUAL, STR_PTR, 0, SLJIT_IMM, 0);
- compile_char1_hotpath(common, type, cc, &current->topfallbacks);
- JUMPTO(SLJIT_JUMP, CURRENT_AS(iterator_fallback)->hotpath);
- set_jumps(current->topfallbacks, LABEL());
+ compile_char1_matchingpath(common, type, cc, &jumplist);
+ JUMPTO(SLJIT_JUMP, CURRENT_AS(iterator_backtrack)->matchingpath);
+ set_jumps(jumplist, LABEL());
JUMPHERE(jump);
- free_stack(common, 1);
+ if (private_data_ptr == 0)
+ free_stack(common, 1);
break;
case OP_EXACT:
case OP_POSPLUS:
- set_jumps(current->topfallbacks, LABEL());
+ set_jumps(current->topbacktracks, LABEL());
break;
case OP_POSSTAR:
@@ -5586,7 +6968,7 @@ switch(opcode)
}
}
-static void compile_ref_iterator_fallbackpath(compiler_common *common, struct fallback_common *current)
+static void compile_ref_iterator_backtrackingpath(compiler_common *common, struct backtrack_common *current)
{
DEFINE_COMPILER;
pcre_uchar *cc = current->cc;
@@ -5595,30 +6977,42 @@ pcre_uchar type;
type = cc[1 + IMM2_SIZE];
if ((type & 0x1) == 0)
{
- set_jumps(current->topfallbacks, LABEL());
+ set_jumps(current->topbacktracks, LABEL());
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
free_stack(common, 1);
- CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(iterator_fallback)->hotpath);
+ CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(iterator_backtrack)->matchingpath);
return;
}
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
-CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(iterator_fallback)->hotpath);
-set_jumps(current->topfallbacks, LABEL());
+CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(iterator_backtrack)->matchingpath);
+set_jumps(current->topbacktracks, LABEL());
free_stack(common, 2);
}
-static void compile_recurse_fallbackpath(compiler_common *common, struct fallback_common *current)
+static void compile_recurse_backtrackingpath(compiler_common *common, struct backtrack_common *current)
{
DEFINE_COMPILER;
-set_jumps(current->topfallbacks, LABEL());
-OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
-free_stack(common, 1);
-OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0), TMP2, 0);
+set_jumps(current->topbacktracks, LABEL());
+
+if (common->has_set_som && common->mark_ptr != 0)
+ {
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), STACK(1));
+ free_stack(common, 2);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0), TMP2, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->mark_ptr, TMP1, 0);
+ }
+else if (common->has_set_som || common->mark_ptr != 0)
+ {
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
+ free_stack(common, 1);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->has_set_som ? (int)(OVECTOR(0)) : common->mark_ptr, TMP2, 0);
+ }
}
-static void compile_assert_fallbackpath(compiler_common *common, struct fallback_common *current)
+static void compile_assert_backtrackingpath(compiler_common *common, struct backtrack_common *current)
{
DEFINE_COMPILER;
pcre_uchar *cc = current->cc;
@@ -5634,18 +7028,18 @@ if (*cc == OP_BRAZERO)
if (bra == OP_BRAZERO)
{
- SLJIT_ASSERT(current->topfallbacks == NULL);
+ SLJIT_ASSERT(current->topbacktracks == NULL);
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
}
-if (CURRENT_AS(assert_fallback)->framesize < 0)
+if (CURRENT_AS(assert_backtrack)->framesize < 0)
{
- set_jumps(current->topfallbacks, LABEL());
+ set_jumps(current->topbacktracks, LABEL());
if (bra == OP_BRAZERO)
{
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), SLJIT_IMM, 0);
- CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(assert_fallback)->hotpath);
+ CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(assert_backtrack)->matchingpath);
free_stack(common, 1);
}
return;
@@ -5656,7 +7050,7 @@ if (bra == OP_BRAZERO)
if (*cc == OP_ASSERT_NOT || *cc == OP_ASSERTBACK_NOT)
{
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), SLJIT_IMM, 0);
- CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(assert_fallback)->hotpath);
+ CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(assert_backtrack)->matchingpath);
free_stack(common, 1);
return;
}
@@ -5666,31 +7060,31 @@ if (bra == OP_BRAZERO)
if (*cc == OP_ASSERT || *cc == OP_ASSERTBACK)
{
- OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), CURRENT_AS(assert_fallback)->localptr);
+ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), CURRENT_AS(assert_backtrack)->private_data_ptr);
add_jump(compiler, &common->revertframes, JUMP(SLJIT_FAST_CALL));
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), CURRENT_AS(assert_fallback)->localptr, SLJIT_MEM1(STACK_TOP), CURRENT_AS(assert_fallback)->framesize * sizeof(sljit_w));
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), CURRENT_AS(assert_backtrack)->private_data_ptr, SLJIT_MEM1(STACK_TOP), CURRENT_AS(assert_backtrack)->framesize * sizeof(sljit_sw));
- set_jumps(current->topfallbacks, LABEL());
+ set_jumps(current->topbacktracks, LABEL());
}
else
- set_jumps(current->topfallbacks, LABEL());
+ set_jumps(current->topbacktracks, LABEL());
if (bra == OP_BRAZERO)
{
/* We know there is enough place on the stack. */
- OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_w));
+ OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_sw));
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), SLJIT_IMM, 0);
- JUMPTO(SLJIT_JUMP, CURRENT_AS(assert_fallback)->hotpath);
+ JUMPTO(SLJIT_JUMP, CURRENT_AS(assert_backtrack)->matchingpath);
JUMPHERE(brajump);
}
}
-static void compile_bracket_fallbackpath(compiler_common *common, struct fallback_common *current)
+static void compile_bracket_backtrackingpath(compiler_common *common, struct backtrack_common *current)
{
DEFINE_COMPILER;
int opcode;
int offset = 0;
-int localptr = CURRENT_AS(bracket_fallback)->localptr;
+int private_data_ptr = CURRENT_AS(bracket_backtrack)->private_data_ptr;
int stacksize;
int count;
pcre_uchar *cc = current->cc;
@@ -5700,7 +7094,7 @@ jump_list *jumplist = NULL;
jump_list *jumplistitem = NULL;
pcre_uchar bra = OP_BRA;
pcre_uchar ket;
-assert_fallback *assert;
+assert_backtrack *assert;
BOOL has_alternatives;
struct sljit_jump *brazero = NULL;
struct sljit_jump *once = NULL;
@@ -5719,7 +7113,7 @@ ket = *(bracketend(ccbegin) - 1 - LINK_SIZE);
cc += GET(cc, 1);
has_alternatives = *cc == OP_ALT;
if (SLJIT_UNLIKELY(opcode == OP_COND) || SLJIT_UNLIKELY(opcode == OP_SCOND))
- has_alternatives = (ccbegin[1 + LINK_SIZE] >= OP_ASSERT && ccbegin[1 + LINK_SIZE] <= OP_ASSERTBACK_NOT) || CURRENT_AS(bracket_fallback)->u.condfailed != NULL;
+ has_alternatives = (ccbegin[1 + LINK_SIZE] >= OP_ASSERT && ccbegin[1 + LINK_SIZE] <= OP_ASSERTBACK_NOT) || CURRENT_AS(bracket_backtrack)->u.condfailed != NULL;
if (opcode == OP_CBRA || opcode == OP_SCBRA)
offset = (GET2(ccbegin, 1 + LINK_SIZE)) << 1;
if (SLJIT_UNLIKELY(opcode == OP_COND) && (*cc == OP_KETRMAX || *cc == OP_KETRMIN))
@@ -5729,9 +7123,7 @@ if (SLJIT_UNLIKELY(opcode == OP_ONCE_NC))
if (ket == OP_KETRMAX)
{
- if (bra != OP_BRAZERO)
- free_stack(common, 1);
- else
+ if (bra == OP_BRAZERO)
{
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
free_stack(common, 1);
@@ -5746,18 +7138,18 @@ else if (ket == OP_KETRMIN)
if (opcode >= OP_SBRA || opcode == OP_ONCE)
{
/* Checking zero-length iteration. */
- if (opcode != OP_ONCE || CURRENT_AS(bracket_fallback)->u.framesize < 0)
- CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, CURRENT_AS(bracket_fallback)->recursivehotpath);
+ if (opcode != OP_ONCE || CURRENT_AS(bracket_backtrack)->u.framesize < 0)
+ CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, CURRENT_AS(bracket_backtrack)->recursive_matchingpath);
else
{
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
- CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_MEM1(TMP1), (CURRENT_AS(bracket_fallback)->u.framesize + 1) * sizeof(sljit_w), CURRENT_AS(bracket_fallback)->recursivehotpath);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
+ CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_MEM1(TMP1), (CURRENT_AS(bracket_backtrack)->u.framesize + 1) * sizeof(sljit_sw), CURRENT_AS(bracket_backtrack)->recursive_matchingpath);
}
if (opcode != OP_ONCE)
free_stack(common, 1);
}
else
- JUMPTO(SLJIT_JUMP, CURRENT_AS(bracket_fallback)->recursivehotpath);
+ JUMPTO(SLJIT_JUMP, CURRENT_AS(bracket_backtrack)->recursive_matchingpath);
}
rminlabel = LABEL();
}
@@ -5770,9 +7162,9 @@ else if (bra == OP_BRAZERO)
if (SLJIT_UNLIKELY(opcode == OP_ONCE))
{
- if (CURRENT_AS(bracket_fallback)->u.framesize >= 0)
+ if (CURRENT_AS(bracket_backtrack)->u.framesize >= 0)
{
- OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
add_jump(compiler, &common->revertframes, JUMP(SLJIT_FAST_CALL));
}
once = JUMP(SLJIT_JUMP);
@@ -5825,9 +7217,9 @@ else if (*cc == OP_ALT)
cc = ccbegin + GET(ccbegin, 1);
}
-COMPILE_FALLBACKPATH(current->top);
-if (current->topfallbacks)
- set_jumps(current->topfallbacks, LABEL());
+COMPILE_BACKTRACKINGPATH(current->top);
+if (current->topbacktracks)
+ set_jumps(current->topbacktracks, LABEL());
if (SLJIT_UNLIKELY(opcode == OP_COND) || SLJIT_UNLIKELY(opcode == OP_SCOND))
{
@@ -5835,21 +7227,21 @@ if (SLJIT_UNLIKELY(opcode == OP_COND) || SLJIT_UNLIKELY(opcode == OP_SCOND))
if (ccbegin[1 + LINK_SIZE] >= OP_ASSERT && ccbegin[1 + LINK_SIZE] <= OP_ASSERTBACK_NOT)
{
SLJIT_ASSERT(has_alternatives);
- assert = CURRENT_AS(bracket_fallback)->u.assert;
+ assert = CURRENT_AS(bracket_backtrack)->u.assert;
if (assert->framesize >= 0 && (ccbegin[1 + LINK_SIZE] == OP_ASSERT || ccbegin[1 + LINK_SIZE] == OP_ASSERTBACK))
{
- OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), assert->localptr);
+ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), assert->private_data_ptr);
add_jump(compiler, &common->revertframes, JUMP(SLJIT_FAST_CALL));
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), assert->localptr, SLJIT_MEM1(STACK_TOP), assert->framesize * sizeof(sljit_w));
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), assert->private_data_ptr, SLJIT_MEM1(STACK_TOP), assert->framesize * sizeof(sljit_sw));
}
cond = JUMP(SLJIT_JUMP);
- set_jumps(CURRENT_AS(bracket_fallback)->u.assert->condfailed, LABEL());
+ set_jumps(CURRENT_AS(bracket_backtrack)->u.assert->condfailed, LABEL());
}
- else if (CURRENT_AS(bracket_fallback)->u.condfailed != NULL)
+ else if (CURRENT_AS(bracket_backtrack)->u.condfailed != NULL)
{
SLJIT_ASSERT(has_alternatives);
cond = JUMP(SLJIT_JUMP);
- set_jumps(CURRENT_AS(bracket_fallback)->u.condfailed, LABEL());
+ set_jumps(CURRENT_AS(bracket_backtrack)->u.condfailed, LABEL());
}
else
SLJIT_ASSERT(!has_alternatives);
@@ -5861,43 +7253,43 @@ if (has_alternatives)
do
{
current->top = NULL;
- current->topfallbacks = NULL;
- current->nextfallbacks = NULL;
+ current->topbacktracks = NULL;
+ current->nextbacktracks = NULL;
if (*cc == OP_ALT)
{
ccprev = cc + 1 + LINK_SIZE;
cc += GET(cc, 1);
if (opcode != OP_COND && opcode != OP_SCOND)
{
- if (localptr != 0 && opcode != OP_ONCE)
- OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ if (private_data_ptr != 0 && opcode != OP_ONCE)
+ OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
else
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
}
- compile_hotpath(common, ccprev, cc, current);
+ compile_matchingpath(common, ccprev, cc, current);
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler)))
return;
}
/* Instructions after the current alternative is succesfully matched. */
- /* There is a similar code in compile_bracket_hotpath. */
+ /* There is a similar code in compile_bracket_matchingpath. */
if (opcode == OP_ONCE)
{
- if (CURRENT_AS(bracket_fallback)->u.framesize < 0)
+ if (CURRENT_AS(bracket_backtrack)->u.framesize < 0)
{
- OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
/* TMP2 which is set here used by OP_KETRMAX below. */
if (ket == OP_KETRMAX)
OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(STACK_TOP), 0);
else if (ket == OP_KETRMIN)
{
- /* Move the STR_PTR to the localptr. */
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_MEM1(STACK_TOP), 0);
+ /* Move the STR_PTR to the private_data_ptr. */
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, SLJIT_MEM1(STACK_TOP), 0);
}
}
else
{
- OP2(SLJIT_ADD, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_IMM, (CURRENT_AS(bracket_fallback)->u.framesize + 2) * sizeof(sljit_w));
+ OP2(SLJIT_ADD, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, SLJIT_IMM, (CURRENT_AS(bracket_backtrack)->u.framesize + 2) * sizeof(sljit_sw));
if (ket == OP_KETRMAX)
{
/* TMP2 which is set here used by OP_KETRMAX below. */
@@ -5913,13 +7305,13 @@ if (has_alternatives)
stacksize++;
if (stacksize > 0) {
- if (opcode != OP_ONCE || CURRENT_AS(bracket_fallback)->u.framesize >= 0)
+ if (opcode != OP_ONCE || CURRENT_AS(bracket_backtrack)->u.framesize >= 0)
allocate_stack(common, stacksize);
else
{
/* We know we have place at least for one item on the top of the stack. */
SLJIT_ASSERT(stacksize == 1);
- OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_w));
+ OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, sizeof(sljit_sw));
}
}
@@ -5938,12 +7330,12 @@ if (has_alternatives)
if (offset != 0)
{
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1), STR_PTR, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 0), TMP1, 0);
}
- JUMPTO(SLJIT_JUMP, CURRENT_AS(bracket_fallback)->althotpath);
+ JUMPTO(SLJIT_JUMP, CURRENT_AS(bracket_backtrack)->alternative_matchingpath);
if (opcode != OP_ONCE)
{
@@ -5952,10 +7344,10 @@ if (has_alternatives)
jumplist = jumplist->next;
}
- COMPILE_FALLBACKPATH(current->top);
- if (current->topfallbacks)
- set_jumps(current->topfallbacks, LABEL());
- SLJIT_ASSERT(!current->nextfallbacks);
+ COMPILE_BACKTRACKINGPATH(current->top);
+ if (current->topbacktracks)
+ set_jumps(current->topbacktracks, LABEL());
+ SLJIT_ASSERT(!current->nextbacktracks);
}
while (*cc == OP_ALT);
SLJIT_ASSERT(!jumplist);
@@ -5963,45 +7355,57 @@ if (has_alternatives)
if (cond != NULL)
{
SLJIT_ASSERT(opcode == OP_COND || opcode == OP_SCOND);
- assert = CURRENT_AS(bracket_fallback)->u.assert;
+ assert = CURRENT_AS(bracket_backtrack)->u.assert;
if ((ccbegin[1 + LINK_SIZE] == OP_ASSERT_NOT || ccbegin[1 + LINK_SIZE] == OP_ASSERTBACK_NOT) && assert->framesize >= 0)
{
- OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), assert->localptr);
+ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), assert->private_data_ptr);
add_jump(compiler, &common->revertframes, JUMP(SLJIT_FAST_CALL));
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), assert->localptr, SLJIT_MEM1(STACK_TOP), assert->framesize * sizeof(sljit_w));
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), assert->private_data_ptr, SLJIT_MEM1(STACK_TOP), assert->framesize * sizeof(sljit_sw));
}
JUMPHERE(cond);
}
/* Free the STR_PTR. */
- if (localptr == 0)
+ if (private_data_ptr == 0)
free_stack(common, 1);
}
if (offset != 0)
{
/* Using both tmp register is better for instruction scheduling. */
- OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
- OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(STACK_TOP), STACK(1));
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset), TMP1, 0);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1), TMP2, 0);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_MEM1(STACK_TOP), STACK(2));
- free_stack(common, 3);
+ if (common->optimized_cbracket[offset >> 1] == 0)
+ {
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(STACK_TOP), STACK(1));
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset), TMP1, 0);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), STACK(2));
+ free_stack(common, 3);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1), TMP2, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, TMP1, 0);
+ }
+ else
+ {
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
+ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(STACK_TOP), STACK(1));
+ free_stack(common, 2);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset), TMP1, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1), TMP2, 0);
+ }
}
else if (opcode == OP_SBRA || opcode == OP_SCOND)
{
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_MEM1(STACK_TOP), STACK(0));
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, SLJIT_MEM1(STACK_TOP), STACK(0));
free_stack(common, 1);
}
else if (opcode == OP_ONCE)
{
cc = ccbegin + GET(ccbegin, 1);
- if (CURRENT_AS(bracket_fallback)->u.framesize >= 0)
+ if (CURRENT_AS(bracket_backtrack)->u.framesize >= 0)
{
/* Reset head and drop saved frame. */
stacksize = (ket == OP_KETRMAX || ket == OP_KETRMIN || *cc == OP_ALT) ? 2 : 1;
- free_stack(common, CURRENT_AS(bracket_fallback)->u.framesize + stacksize);
+ free_stack(common, CURRENT_AS(bracket_backtrack)->u.framesize + stacksize);
}
else if (ket == OP_KETRMAX || (*cc == OP_ALT && ket != OP_KETRMIN))
{
@@ -6010,35 +7414,37 @@ else if (opcode == OP_ONCE)
}
JUMPHERE(once);
- /* Restore previous localptr */
- if (CURRENT_AS(bracket_fallback)->u.framesize >= 0)
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, SLJIT_MEM1(STACK_TOP), CURRENT_AS(bracket_fallback)->u.framesize * sizeof(sljit_w));
+ /* Restore previous private_data_ptr */
+ if (CURRENT_AS(bracket_backtrack)->u.framesize >= 0)
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, SLJIT_MEM1(STACK_TOP), CURRENT_AS(bracket_backtrack)->u.framesize * sizeof(sljit_sw));
else if (ket == OP_KETRMIN)
{
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), STACK(1));
/* See the comment below. */
free_stack(common, 2);
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), localptr, TMP1, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), private_data_ptr, TMP1, 0);
}
}
if (ket == OP_KETRMAX)
{
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
- CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(bracket_fallback)->recursivehotpath);
+ if (bra != OP_BRAZERO)
+ free_stack(common, 1);
+ CMPTO(SLJIT_C_NOT_EQUAL, STR_PTR, 0, SLJIT_IMM, 0, CURRENT_AS(bracket_backtrack)->recursive_matchingpath);
if (bra == OP_BRAZERO)
{
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(1));
- JUMPTO(SLJIT_JUMP, CURRENT_AS(bracket_fallback)->zerohotpath);
+ JUMPTO(SLJIT_JUMP, CURRENT_AS(bracket_backtrack)->zero_matchingpath);
JUMPHERE(brazero);
+ free_stack(common, 1);
}
- free_stack(common, 1);
}
else if (ket == OP_KETRMIN)
{
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
- /* OP_ONCE removes everything in case of a fallback, so we don't
+ /* OP_ONCE removes everything in case of a backtrack, so we don't
need to explicitly release the STR_PTR. The extra release would
affect badly the free_stack(2) above. */
if (opcode != OP_ONCE)
@@ -6052,18 +7458,18 @@ else if (ket == OP_KETRMIN)
else if (bra == OP_BRAZERO)
{
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
- JUMPTO(SLJIT_JUMP, CURRENT_AS(bracket_fallback)->zerohotpath);
+ JUMPTO(SLJIT_JUMP, CURRENT_AS(bracket_backtrack)->zero_matchingpath);
JUMPHERE(brazero);
}
}
-static void compile_bracketpos_fallbackpath(compiler_common *common, struct fallback_common *current)
+static void compile_bracketpos_backtrackingpath(compiler_common *common, struct backtrack_common *current)
{
DEFINE_COMPILER;
int offset;
struct sljit_jump *jump;
-if (CURRENT_AS(bracketpos_fallback)->framesize < 0)
+if (CURRENT_AS(bracketpos_backtrack)->framesize < 0)
{
if (*current->cc == OP_CBRAPOS || *current->cc == OP_SCBRAPOS)
{
@@ -6073,57 +7479,57 @@ if (CURRENT_AS(bracketpos_fallback)->framesize < 0)
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset), TMP1, 0);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(offset + 1), TMP2, 0);
}
- set_jumps(current->topfallbacks, LABEL());
- free_stack(common, CURRENT_AS(bracketpos_fallback)->stacksize);
+ set_jumps(current->topbacktracks, LABEL());
+ free_stack(common, CURRENT_AS(bracketpos_backtrack)->stacksize);
return;
}
-OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), CURRENT_AS(bracketpos_fallback)->localptr);
+OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), CURRENT_AS(bracketpos_backtrack)->private_data_ptr);
add_jump(compiler, &common->revertframes, JUMP(SLJIT_FAST_CALL));
-if (current->topfallbacks)
+if (current->topbacktracks)
{
jump = JUMP(SLJIT_JUMP);
- set_jumps(current->topfallbacks, LABEL());
+ set_jumps(current->topbacktracks, LABEL());
/* Drop the stack frame. */
- free_stack(common, CURRENT_AS(bracketpos_fallback)->stacksize);
+ free_stack(common, CURRENT_AS(bracketpos_backtrack)->stacksize);
JUMPHERE(jump);
}
-OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), CURRENT_AS(bracketpos_fallback)->localptr, SLJIT_MEM1(STACK_TOP), CURRENT_AS(bracketpos_fallback)->framesize * sizeof(sljit_w));
+OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), CURRENT_AS(bracketpos_backtrack)->private_data_ptr, SLJIT_MEM1(STACK_TOP), CURRENT_AS(bracketpos_backtrack)->framesize * sizeof(sljit_sw));
}
-static void compile_braminzero_fallbackpath(compiler_common *common, struct fallback_common *current)
+static void compile_braminzero_backtrackingpath(compiler_common *common, struct backtrack_common *current)
{
-assert_fallback fallback;
+assert_backtrack backtrack;
current->top = NULL;
-current->topfallbacks = NULL;
-current->nextfallbacks = NULL;
+current->topbacktracks = NULL;
+current->nextbacktracks = NULL;
if (current->cc[1] > OP_ASSERTBACK_NOT)
{
- /* Manual call of compile_bracket_hotpath and compile_bracket_fallbackpath. */
- compile_bracket_hotpath(common, current->cc, current);
- compile_bracket_fallbackpath(common, current->top);
+ /* Manual call of compile_bracket_matchingpath and compile_bracket_backtrackingpath. */
+ compile_bracket_matchingpath(common, current->cc, current);
+ compile_bracket_backtrackingpath(common, current->top);
}
else
{
- memset(&fallback, 0, sizeof(fallback));
- fallback.common.cc = current->cc;
- fallback.hotpath = CURRENT_AS(braminzero_fallback)->hotpath;
- /* Manual call of compile_assert_hotpath. */
- compile_assert_hotpath(common, current->cc, &fallback, FALSE);
+ memset(&backtrack, 0, sizeof(backtrack));
+ backtrack.common.cc = current->cc;
+ backtrack.matchingpath = CURRENT_AS(braminzero_backtrack)->matchingpath;
+ /* Manual call of compile_assert_matchingpath. */
+ compile_assert_matchingpath(common, current->cc, &backtrack, FALSE);
}
-SLJIT_ASSERT(!current->nextfallbacks && !current->topfallbacks);
+SLJIT_ASSERT(!current->nextbacktracks && !current->topbacktracks);
}
-static void compile_fallbackpath(compiler_common *common, struct fallback_common *current)
+static void compile_backtrackingpath(compiler_common *common, struct backtrack_common *current)
{
DEFINE_COMPILER;
while (current)
{
- if (current->nextfallbacks != NULL)
- set_jumps(current->nextfallbacks, LABEL());
+ if (current->nextbacktracks != NULL)
+ set_jumps(current->nextbacktracks, LABEL());
switch(*current->cc)
{
case OP_SET_SOM:
@@ -6202,23 +7608,23 @@ while (current)
#if defined SUPPORT_UTF || !defined COMPILE_PCRE8
case OP_XCLASS:
#endif
- compile_iterator_fallbackpath(common, current);
+ compile_iterator_backtrackingpath(common, current);
break;
case OP_REF:
case OP_REFI:
- compile_ref_iterator_fallbackpath(common, current);
+ compile_ref_iterator_backtrackingpath(common, current);
break;
case OP_RECURSE:
- compile_recurse_fallbackpath(common, current);
+ compile_recurse_backtrackingpath(common, current);
break;
case OP_ASSERT:
case OP_ASSERT_NOT:
case OP_ASSERTBACK:
case OP_ASSERTBACK_NOT:
- compile_assert_fallbackpath(common, current);
+ compile_assert_backtrackingpath(common, current);
break;
case OP_ONCE:
@@ -6229,14 +7635,14 @@ while (current)
case OP_SBRA:
case OP_SCBRA:
case OP_SCOND:
- compile_bracket_fallbackpath(common, current);
+ compile_bracket_backtrackingpath(common, current);
break;
case OP_BRAZERO:
if (current->cc[1] > OP_ASSERTBACK_NOT)
- compile_bracket_fallbackpath(common, current);
+ compile_bracket_backtrackingpath(common, current);
else
- compile_assert_fallbackpath(common, current);
+ compile_assert_backtrackingpath(common, current);
break;
case OP_BRAPOS:
@@ -6244,17 +7650,31 @@ while (current)
case OP_SBRAPOS:
case OP_SCBRAPOS:
case OP_BRAPOSZERO:
- compile_bracketpos_fallbackpath(common, current);
+ compile_bracketpos_backtrackingpath(common, current);
break;
case OP_BRAMINZERO:
- compile_braminzero_fallbackpath(common, current);
+ compile_braminzero_backtrackingpath(common, current);
+ break;
+
+ case OP_MARK:
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
+ free_stack(common, 1);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->mark_ptr, TMP1, 0);
+ break;
+
+ case OP_COMMIT:
+ OP1(SLJIT_MOV, SLJIT_RETURN_REG, 0, SLJIT_IMM, PCRE_ERROR_NOMATCH);
+ if (common->quitlabel == NULL)
+ add_jump(compiler, &common->quit, JUMP(SLJIT_JUMP));
+ else
+ JUMPTO(SLJIT_JUMP, common->quitlabel);
break;
case OP_FAIL:
case OP_ACCEPT:
case OP_ASSERT_ACCEPT:
- set_jumps(current->topfallbacks, LABEL());
+ set_jumps(current->topbacktracks, LABEL());
break;
default:
@@ -6271,11 +7691,13 @@ DEFINE_COMPILER;
pcre_uchar *cc = common->start + common->currententry->start;
pcre_uchar *ccbegin = cc + 1 + LINK_SIZE + (*cc == OP_BRA ? 0 : IMM2_SIZE);
pcre_uchar *ccend = bracketend(cc);
-int localsize = get_localsize(common, ccbegin, ccend);
+int private_data_size = get_private_data_length_for_copy(common, ccbegin, ccend);
int framesize = get_framesize(common, cc, TRUE);
int alternativesize;
BOOL needsframe;
-fallback_common altfallback;
+backtrack_common altbacktrack;
+struct sljit_label *save_quitlabel = common->quitlabel;
+jump_list *save_quit = common->quit;
struct sljit_jump *jump;
SLJIT_ASSERT(*cc == OP_BRA || *cc == OP_CBRA || *cc == OP_CBRAPOS || *cc == OP_SCBRA || *cc == OP_SCBRAPOS);
@@ -6284,97 +7706,111 @@ if (!needsframe)
framesize = 0;
alternativesize = *(cc + GET(cc, 1)) == OP_ALT ? 1 : 0;
-SLJIT_ASSERT(common->currententry->entry == NULL);
+SLJIT_ASSERT(common->currententry->entry == NULL && common->recursive_head != 0);
common->currententry->entry = LABEL();
set_jumps(common->currententry->calls, common->currententry->entry);
-sljit_emit_fast_enter(compiler, TMP2, 0, 1, 5, 5, common->localsize);
-allocate_stack(common, localsize + framesize + alternativesize);
-OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(localsize + framesize + alternativesize - 1), TMP2, 0);
-copy_locals(common, ccbegin, ccend, TRUE, localsize + framesize + alternativesize, framesize + alternativesize);
-OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), RECURSIVE_HEAD, STACK_TOP, 0);
+sljit_emit_fast_enter(compiler, TMP2, 0);
+allocate_stack(common, private_data_size + framesize + alternativesize);
+OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(private_data_size + framesize + alternativesize - 1), TMP2, 0);
+copy_private_data(common, ccbegin, ccend, TRUE, private_data_size + framesize + alternativesize, framesize + alternativesize);
+OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->recursive_head, STACK_TOP, 0);
if (needsframe)
- init_frame(common, cc, framesize + alternativesize - 1, alternativesize, FALSE);
+ init_frame(common, cc, framesize + alternativesize - 1, alternativesize, TRUE);
if (alternativesize > 0)
OP1(SLJIT_MOV, SLJIT_MEM1(STACK_TOP), STACK(0), STR_PTR, 0);
-memset(&altfallback, 0, sizeof(fallback_common));
+memset(&altbacktrack, 0, sizeof(backtrack_common));
+common->quitlabel = NULL;
common->acceptlabel = NULL;
+common->quit = NULL;
common->accept = NULL;
-altfallback.cc = ccbegin;
+altbacktrack.cc = ccbegin;
cc += GET(cc, 1);
while (1)
{
- altfallback.top = NULL;
- altfallback.topfallbacks = NULL;
+ altbacktrack.top = NULL;
+ altbacktrack.topbacktracks = NULL;
- if (altfallback.cc != ccbegin)
+ if (altbacktrack.cc != ccbegin)
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(STACK_TOP), STACK(0));
- compile_hotpath(common, altfallback.cc, cc, &altfallback);
+ compile_matchingpath(common, altbacktrack.cc, cc, &altbacktrack);
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler)))
+ {
+ common->quitlabel = save_quitlabel;
+ common->quit = save_quit;
return;
+ }
add_jump(compiler, &common->accept, JUMP(SLJIT_JUMP));
- compile_fallbackpath(common, altfallback.top);
+ compile_backtrackingpath(common, altbacktrack.top);
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler)))
+ {
+ common->quitlabel = save_quitlabel;
+ common->quit = save_quit;
return;
- set_jumps(altfallback.topfallbacks, LABEL());
+ }
+ set_jumps(altbacktrack.topbacktracks, LABEL());
if (*cc != OP_ALT)
break;
- altfallback.cc = cc + 1 + LINK_SIZE;
+ altbacktrack.cc = cc + 1 + LINK_SIZE;
cc += GET(cc, 1);
}
/* None of them matched. */
+if (common->quit != NULL)
+ set_jumps(common->quit, LABEL());
+
OP1(SLJIT_MOV, TMP3, 0, SLJIT_IMM, 0);
jump = JUMP(SLJIT_JUMP);
set_jumps(common->accept, LABEL());
-OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), RECURSIVE_HEAD);
+OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->recursive_head);
if (needsframe)
{
- OP1(SLJIT_MOV, TMP3, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0));
- OP2(SLJIT_SUB, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, (framesize + alternativesize) * sizeof(sljit_w));
+ OP2(SLJIT_SUB, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, (framesize + alternativesize) * sizeof(sljit_sw));
add_jump(compiler, &common->revertframes, JUMP(SLJIT_FAST_CALL));
- OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, (framesize + alternativesize) * sizeof(sljit_w));
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0), TMP3, 0);
+ OP2(SLJIT_ADD, STACK_TOP, 0, STACK_TOP, 0, SLJIT_IMM, (framesize + alternativesize) * sizeof(sljit_sw));
}
OP1(SLJIT_MOV, TMP3, 0, SLJIT_IMM, 1);
JUMPHERE(jump);
-copy_locals(common, ccbegin, ccend, FALSE, localsize + framesize + alternativesize, framesize + alternativesize);
-free_stack(common, localsize + framesize + alternativesize);
-OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(STACK_TOP), sizeof(sljit_w));
+copy_private_data(common, ccbegin, ccend, FALSE, private_data_size + framesize + alternativesize, framesize + alternativesize);
+free_stack(common, private_data_size + framesize + alternativesize);
+OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(STACK_TOP), sizeof(sljit_sw));
OP1(SLJIT_MOV, TMP1, 0, TMP3, 0);
-OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), RECURSIVE_HEAD, TMP2, 0);
+OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->recursive_head, TMP2, 0);
sljit_emit_fast_return(compiler, SLJIT_MEM1(STACK_TOP), 0);
+
+common->quitlabel = save_quitlabel;
+common->quit = save_quit;
}
-#undef COMPILE_FALLBACKPATH
+#undef COMPILE_BACKTRACKINGPATH
#undef CURRENT_AS
void
-PRIV(jit_compile)(const REAL_PCRE *re, PUBL(extra) *extra)
+PRIV(jit_compile)(const REAL_PCRE *re, PUBL(extra) *extra, int mode)
{
struct sljit_compiler *compiler;
-fallback_common rootfallback;
+backtrack_common rootbacktrack;
compiler_common common_data;
compiler_common *common = &common_data;
const pcre_uint8 *tables = re->tables;
pcre_study_data *study;
+int private_data_size;
pcre_uchar *ccend;
-executable_function *function;
+executable_functions *functions;
void *executable_func;
sljit_uw executable_size;
-struct sljit_label *leave;
struct sljit_label *mainloop = NULL;
struct sljit_label *empty_match_found;
-struct sljit_label *empty_match_fallback;
-struct sljit_jump *alloc_error;
+struct sljit_label *empty_match_backtrack;
+struct sljit_jump *jump;
struct sljit_jump *reqbyte_notfound = NULL;
struct sljit_jump *empty_match;
@@ -6384,20 +7820,20 @@ study = extra->study_data;
if (!tables)
tables = PRIV(default_tables);
-memset(&rootfallback, 0, sizeof(fallback_common));
-rootfallback.cc = (pcre_uchar *)re + re->name_table_offset + re->name_count * re->name_entry_size;
+memset(&rootbacktrack, 0, sizeof(backtrack_common));
+memset(common, 0, sizeof(compiler_common));
+rootbacktrack.cc = (pcre_uchar *)re + re->name_table_offset + re->name_count * re->name_entry_size;
-common->compiler = NULL;
-common->start = rootfallback.cc;
-common->cbraptr = OVECTOR_START + (re->top_bracket + 1) * 2 * sizeof(sljit_w);
+common->start = rootbacktrack.cc;
common->fcc = tables + fcc_offset;
-common->lcc = (sljit_w)(tables + lcc_offset);
+common->lcc = (sljit_sw)(tables + lcc_offset);
+common->mode = mode;
common->nltype = NLTYPE_FIXED;
switch(re->options & PCRE_NEWLINE_BITS)
{
case 0:
/* Compile-time default */
- switch (NEWLINE)
+ switch(NEWLINE)
{
case -1: common->newline = (CHAR_CR << 8) | CHAR_NL; common->nltype = NLTYPE_ANY; break;
case -2: common->newline = (CHAR_CR << 8) | CHAR_NL; common->nltype = NLTYPE_ANYCRLF; break;
@@ -6425,68 +7861,95 @@ else
#endif
}
common->endonly = (re->options & PCRE_DOLLAR_ENDONLY) != 0;
-common->ctypes = (sljit_w)(tables + ctypes_offset);
-common->name_table = (sljit_w)((pcre_uchar *)re + re->name_table_offset);
+common->ctypes = (sljit_sw)(tables + ctypes_offset);
+common->digits[0] = -2;
+common->name_table = (sljit_sw)((pcre_uchar *)re + re->name_table_offset);
common->name_count = re->name_count;
common->name_entry_size = re->name_entry_size;
-common->acceptlabel = NULL;
-common->stubs = NULL;
-common->entries = NULL;
-common->currententry = NULL;
-common->accept = NULL;
-common->calllimit = NULL;
-common->stackalloc = NULL;
-common->revertframes = NULL;
-common->wordboundary = NULL;
-common->anynewline = NULL;
-common->hspace = NULL;
-common->vspace = NULL;
-common->casefulcmp = NULL;
-common->caselesscmp = NULL;
common->jscript_compat = (re->options & PCRE_JAVASCRIPT_COMPAT) != 0;
#ifdef SUPPORT_UTF
-/* PCRE_UTF16 has the same value as PCRE_UTF8. */
+/* PCRE_UTF[16|32] have the same value as PCRE_UTF8. */
common->utf = (re->options & PCRE_UTF8) != 0;
#ifdef SUPPORT_UCP
common->use_ucp = (re->options & PCRE_UCP) != 0;
#endif
-common->utfreadchar = NULL;
-#ifdef COMPILE_PCRE8
-common->utfreadtype8 = NULL;
-#endif
#endif /* SUPPORT_UTF */
-#ifdef SUPPORT_UCP
-common->getucd = NULL;
-#endif
-ccend = bracketend(rootfallback.cc);
-SLJIT_ASSERT(*rootfallback.cc == OP_BRA && ccend[-(1 + LINK_SIZE)] == OP_KET);
-common->localsize = get_localspace(common, rootfallback.cc, ccend);
-if (common->localsize < 0)
+ccend = bracketend(rootbacktrack.cc);
+
+/* Calculate the local space size on the stack. */
+common->ovector_start = CALL_LIMIT + sizeof(sljit_sw);
+common->optimized_cbracket = (pcre_uint8 *)SLJIT_MALLOC(re->top_bracket + 1);
+if (!common->optimized_cbracket)
+ return;
+memset(common->optimized_cbracket, 1, re->top_bracket + 1);
+
+SLJIT_ASSERT(*rootbacktrack.cc == OP_BRA && ccend[-(1 + LINK_SIZE)] == OP_KET);
+private_data_size = get_private_data_length(common, rootbacktrack.cc, ccend);
+if (private_data_size < 0)
+ {
+ SLJIT_FREE(common->optimized_cbracket);
return;
-common->localsize += common->cbraptr + (re->top_bracket + 1) * sizeof(sljit_w);
-if (common->localsize > SLJIT_MAX_LOCAL_SIZE)
+ }
+
+/* Checking flags and updating ovector_start. */
+if (mode == JIT_COMPILE && (re->flags & PCRE_REQCHSET) != 0 && (re->options & PCRE_NO_START_OPTIMIZE) == 0)
+ {
+ common->req_char_ptr = common->ovector_start;
+ common->ovector_start += sizeof(sljit_sw);
+ }
+if (mode != JIT_COMPILE)
+ {
+ common->start_used_ptr = common->ovector_start;
+ common->ovector_start += sizeof(sljit_sw);
+ if (mode == JIT_PARTIAL_SOFT_COMPILE)
+ {
+ common->hit_start = common->ovector_start;
+ common->ovector_start += sizeof(sljit_sw);
+ }
+ }
+if ((re->options & PCRE_FIRSTLINE) != 0)
+ {
+ common->first_line_end = common->ovector_start;
+ common->ovector_start += sizeof(sljit_sw);
+ }
+
+/* Aligning ovector to even number of sljit words. */
+if ((common->ovector_start & sizeof(sljit_sw)) != 0)
+ common->ovector_start += sizeof(sljit_sw);
+
+SLJIT_ASSERT(!(common->req_char_ptr != 0 && common->start_used_ptr != 0));
+common->cbraptr = OVECTOR_START + (re->top_bracket + 1) * 2 * sizeof(sljit_sw);
+private_data_size += common->cbraptr + (re->top_bracket + 1) * sizeof(sljit_sw);
+if (private_data_size > SLJIT_MAX_LOCAL_SIZE)
+ {
+ SLJIT_FREE(common->optimized_cbracket);
return;
-common->localptrs = (int*)SLJIT_MALLOC((ccend - rootfallback.cc) * sizeof(int));
-if (!common->localptrs)
+ }
+common->private_data_ptrs = (int *)SLJIT_MALLOC((ccend - rootbacktrack.cc) * sizeof(int));
+if (!common->private_data_ptrs)
+ {
+ SLJIT_FREE(common->optimized_cbracket);
return;
-memset(common->localptrs, 0, (ccend - rootfallback.cc) * sizeof(int));
-set_localptrs(common, common->cbraptr + (re->top_bracket + 1) * sizeof(sljit_w), ccend);
+ }
+memset(common->private_data_ptrs, 0, (ccend - rootbacktrack.cc) * sizeof(int));
+set_private_data_ptrs(common, common->cbraptr + (re->top_bracket + 1) * sizeof(sljit_sw), ccend);
compiler = sljit_create_compiler();
if (!compiler)
{
- SLJIT_FREE(common->localptrs);
+ SLJIT_FREE(common->optimized_cbracket);
+ SLJIT_FREE(common->private_data_ptrs);
return;
}
common->compiler = compiler;
/* Main pcre_jit_exec entry. */
-sljit_emit_enter(compiler, 1, 5, 5, common->localsize);
+sljit_emit_enter(compiler, 1, 5, 5, private_data_size);
/* Register init. */
reset_ovector(common, (re->top_bracket + 1) * 2);
-if ((re->flags & PCRE_REQCHSET) != 0)
- OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), REQ_CHAR_PTR, SLJIT_TEMPORARY_REG1, 0);
+if (common->req_char_ptr != 0)
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->req_char_ptr, SLJIT_SCRATCH_REG1, 0);
OP1(SLJIT_MOV, ARGUMENTS, 0, SLJIT_SAVED_REG1, 0);
OP1(SLJIT_MOV, TMP1, 0, SLJIT_SAVED_REG1, 0);
@@ -6498,31 +7961,51 @@ OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(TMP2), SLJIT_OFFSETOF(struct sljit_stack
OP1(SLJIT_MOV, STACK_LIMIT, 0, SLJIT_MEM1(TMP2), SLJIT_OFFSETOF(struct sljit_stack, limit));
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), CALL_LIMIT, TMP1, 0);
+if (mode == JIT_PARTIAL_SOFT_COMPILE)
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->hit_start, SLJIT_IMM, 0);
+
/* Main part of the matching */
if ((re->options & PCRE_ANCHORED) == 0)
{
mainloop = mainloop_entry(common, (re->flags & PCRE_HASCRORLF) != 0, (re->options & PCRE_FIRSTLINE) != 0);
/* Forward search if possible. */
- if ((re->flags & PCRE_FIRSTSET) != 0)
- fast_forward_first_char(common, re->first_char, (re->flags & PCRE_FCH_CASELESS) != 0, (re->options & PCRE_FIRSTLINE) != 0);
- else if ((re->flags & PCRE_STARTLINE) != 0)
- fast_forward_newline(common, (re->options & PCRE_FIRSTLINE) != 0);
- else if ((re->flags & PCRE_STARTLINE) == 0 && study != NULL && (study->flags & PCRE_STUDY_MAPPED) != 0)
- fast_forward_start_bits(common, (sljit_uw)study->start_bits, (re->options & PCRE_FIRSTLINE) != 0);
+ if ((re->options & PCRE_NO_START_OPTIMIZE) == 0)
+ {
+ if (mode == JIT_COMPILE && fast_forward_first_n_chars(common, (re->options & PCRE_FIRSTLINE) != 0))
+ { /* Do nothing */ }
+ else if ((re->flags & PCRE_FIRSTSET) != 0)
+ fast_forward_first_char(common, (pcre_uchar)re->first_char, (re->flags & PCRE_FCH_CASELESS) != 0, (re->options & PCRE_FIRSTLINE) != 0);
+ else if ((re->flags & PCRE_STARTLINE) != 0)
+ fast_forward_newline(common, (re->options & PCRE_FIRSTLINE) != 0);
+ else if ((re->flags & PCRE_STARTLINE) == 0 && study != NULL && (study->flags & PCRE_STUDY_MAPPED) != 0)
+ fast_forward_start_bits(common, (sljit_uw)study->start_bits, (re->options & PCRE_FIRSTLINE) != 0);
+ }
}
-if ((re->flags & PCRE_REQCHSET) != 0)
- reqbyte_notfound = search_requested_char(common, re->req_char, (re->flags & PCRE_RCH_CASELESS) != 0, (re->flags & PCRE_FIRSTSET) != 0);
+if (common->req_char_ptr != 0)
+ reqbyte_notfound = search_requested_char(common, (pcre_uchar)re->req_char, (re->flags & PCRE_RCH_CASELESS) != 0, (re->flags & PCRE_FIRSTSET) != 0);
/* Store the current STR_PTR in OVECTOR(0). */
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0), STR_PTR, 0);
/* Copy the limit of allowed recursions. */
OP1(SLJIT_MOV, CALL_COUNT, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), CALL_LIMIT);
+if (common->mark_ptr != 0)
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->mark_ptr, SLJIT_IMM, 0);
+/* Copy the beginning of the string. */
+if (mode == JIT_PARTIAL_SOFT_COMPILE)
+ {
+ jump = CMP(SLJIT_C_NOT_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), common->hit_start, SLJIT_IMM, 0);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr, STR_PTR, 0);
+ JUMPHERE(jump);
+ }
+else if (mode == JIT_PARTIAL_HARD_COMPILE)
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr, STR_PTR, 0);
-compile_hotpath(common, rootfallback.cc, ccend, &rootfallback);
+compile_matchingpath(common, rootbacktrack.cc, ccend, &rootbacktrack);
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler)))
{
sljit_free_compiler(compiler);
- SLJIT_FREE(common->localptrs);
+ SLJIT_FREE(common->optimized_cbracket);
+ SLJIT_FREE(common->private_data_ptrs);
return;
}
@@ -6535,19 +8018,39 @@ if (common->accept != NULL)
/* This means we have a match. Update the ovector. */
copy_ovector(common, re->top_bracket + 1);
-leave = LABEL();
+common->quitlabel = LABEL();
+if (common->quit != NULL)
+ set_jumps(common->quit, common->quitlabel);
sljit_emit_return(compiler, SLJIT_MOV, SLJIT_RETURN_REG, 0);
-empty_match_fallback = LABEL();
-compile_fallbackpath(common, rootfallback.top);
+if (mode != JIT_COMPILE)
+ {
+ common->partialmatchlabel = LABEL();
+ set_jumps(common->partialmatch, common->partialmatchlabel);
+ return_with_partial_match(common, common->quitlabel);
+ }
+
+empty_match_backtrack = LABEL();
+compile_backtrackingpath(common, rootbacktrack.top);
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler)))
{
sljit_free_compiler(compiler);
- SLJIT_FREE(common->localptrs);
+ SLJIT_FREE(common->optimized_cbracket);
+ SLJIT_FREE(common->private_data_ptrs);
return;
}
-SLJIT_ASSERT(rootfallback.prev == NULL);
+SLJIT_ASSERT(rootbacktrack.prev == NULL);
+
+if (mode == JIT_PARTIAL_SOFT_COMPILE)
+ {
+ /* Update hit_start only in the first time. */
+ jump = CMP(SLJIT_C_NOT_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), common->hit_start, SLJIT_IMM, -1);
+ OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->start_used_ptr, SLJIT_IMM, -1);
+ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), common->hit_start, TMP1, 0);
+ JUMPHERE(jump);
+ }
/* Check we have remaining characters. */
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0));
@@ -6556,9 +8059,9 @@ if ((re->options & PCRE_ANCHORED) == 0)
{
if ((re->options & PCRE_FIRSTLINE) == 0)
{
- if (study != NULL && study->minlength > 1)
+ if (mode == JIT_COMPILE && study != NULL && study->minlength > 1 && (re->options & PCRE_NO_START_OPTIMIZE) == 0)
{
- OP2(SLJIT_ADD, TMP1, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(study->minlength));
+ OP2(SLJIT_ADD, TMP1, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(study->minlength + 1));
CMPTO(SLJIT_C_LESS_EQUAL, TMP1, 0, STR_END, 0, mainloop);
}
else
@@ -6566,38 +8069,42 @@ if ((re->options & PCRE_ANCHORED) == 0)
}
else
{
- if (study != NULL && study->minlength > 1)
+ SLJIT_ASSERT(common->first_line_end != 0);
+ if (mode == JIT_COMPILE && study != NULL && study->minlength > 1 && (re->options & PCRE_NO_START_OPTIMIZE) == 0)
{
- OP2(SLJIT_ADD, TMP1, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(study->minlength));
+ OP2(SLJIT_ADD, TMP1, 0, STR_PTR, 0, SLJIT_IMM, IN_UCHARS(study->minlength + 1));
OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, TMP1, 0, STR_END, 0);
- COND_VALUE(SLJIT_MOV, TMP2, 0, SLJIT_C_GREATER);
- OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), FIRSTLINE_END);
- COND_VALUE(SLJIT_OR | SLJIT_SET_E, TMP2, 0, SLJIT_C_GREATER_EQUAL);
+ OP_FLAGS(SLJIT_MOV, TMP2, 0, SLJIT_UNUSED, 0, SLJIT_C_GREATER);
+ OP2(SLJIT_SUB | SLJIT_SET_U, SLJIT_UNUSED, 0, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->first_line_end);
+ OP_FLAGS(SLJIT_OR | SLJIT_SET_E, TMP2, 0, TMP2, 0, SLJIT_C_GREATER_EQUAL);
JUMPTO(SLJIT_C_ZERO, mainloop);
}
else
- CMPTO(SLJIT_C_LESS, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), FIRSTLINE_END, mainloop);
+ CMPTO(SLJIT_C_LESS, STR_PTR, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), common->first_line_end, mainloop);
}
}
+/* No more remaining characters. */
if (reqbyte_notfound != NULL)
JUMPHERE(reqbyte_notfound);
-/* Copy OVECTOR(1) to OVECTOR(0) */
-OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(0), SLJIT_MEM1(SLJIT_LOCALS_REG), OVECTOR(1));
+
+if (mode == JIT_PARTIAL_SOFT_COMPILE)
+ CMPTO(SLJIT_C_NOT_EQUAL, SLJIT_MEM1(SLJIT_LOCALS_REG), common->hit_start, SLJIT_IMM, 0, common->partialmatchlabel);
+
OP1(SLJIT_MOV, SLJIT_RETURN_REG, 0, SLJIT_IMM, PCRE_ERROR_NOMATCH);
-JUMPTO(SLJIT_JUMP, leave);
+JUMPTO(SLJIT_JUMP, common->quitlabel);
flush_stubs(common);
JUMPHERE(empty_match);
OP1(SLJIT_MOV, TMP1, 0, ARGUMENTS, 0);
OP1(SLJIT_MOV_UB, TMP2, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, notempty));
-CMPTO(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0, empty_match_fallback);
+CMPTO(SLJIT_C_NOT_EQUAL, TMP2, 0, SLJIT_IMM, 0, empty_match_backtrack);
OP1(SLJIT_MOV_UB, TMP2, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, notempty_atstart));
CMPTO(SLJIT_C_EQUAL, TMP2, 0, SLJIT_IMM, 0, empty_match_found);
OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, str));
CMPTO(SLJIT_C_NOT_EQUAL, TMP2, 0, STR_PTR, 0, empty_match_found);
-JUMPTO(SLJIT_JUMP, empty_match_fallback);
+JUMPTO(SLJIT_JUMP, empty_match_backtrack);
common->currententry = common->entries;
while (common->currententry != NULL)
@@ -6607,7 +8114,8 @@ while (common->currententry != NULL)
if (SLJIT_UNLIKELY(sljit_get_compiler_error(compiler)))
{
sljit_free_compiler(compiler);
- SLJIT_FREE(common->localptrs);
+ SLJIT_FREE(common->optimized_cbracket);
+ SLJIT_FREE(common->private_data_ptrs);
return;
}
flush_stubs(common);
@@ -6618,7 +8126,7 @@ while (common->currententry != NULL)
/* This is a (really) rare case. */
set_jumps(common->stackalloc, LABEL());
/* RETURN_ADDR is not a saved register. */
-sljit_emit_fast_enter(compiler, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0, 1, 5, 5, common->localsize);
+sljit_emit_fast_enter(compiler, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0);
OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS1, TMP2, 0);
OP1(SLJIT_MOV, TMP1, 0, ARGUMENTS, 0);
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, stack));
@@ -6626,7 +8134,7 @@ OP1(SLJIT_MOV, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(struct sljit_stack, top), STACK_
OP2(SLJIT_ADD, TMP2, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(struct sljit_stack, limit), SLJIT_IMM, STACK_GROWTH_RATE);
sljit_emit_ijump(compiler, SLJIT_CALL2, SLJIT_IMM, SLJIT_FUNC_OFFSET(sljit_stack_resize));
-alloc_error = CMP(SLJIT_C_NOT_EQUAL, SLJIT_RETURN_REG, 0, SLJIT_IMM, 0);
+jump = CMP(SLJIT_C_NOT_EQUAL, SLJIT_RETURN_REG, 0, SLJIT_IMM, 0);
OP1(SLJIT_MOV, TMP1, 0, ARGUMENTS, 0);
OP1(SLJIT_MOV, TMP1, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(jit_arguments, stack));
OP1(SLJIT_MOV, STACK_TOP, 0, SLJIT_MEM1(TMP1), SLJIT_OFFSETOF(struct sljit_stack, top));
@@ -6635,15 +8143,15 @@ OP1(SLJIT_MOV, TMP2, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS1);
sljit_emit_fast_return(compiler, SLJIT_MEM1(SLJIT_LOCALS_REG), LOCALS0);
/* Allocation failed. */
-JUMPHERE(alloc_error);
+JUMPHERE(jump);
/* We break the return address cache here, but this is a really rare case. */
OP1(SLJIT_MOV, SLJIT_RETURN_REG, 0, SLJIT_IMM, PCRE_ERROR_JIT_STACKLIMIT);
-JUMPTO(SLJIT_JUMP, leave);
+JUMPTO(SLJIT_JUMP, common->quitlabel);
/* Call limit reached. */
set_jumps(common->calllimit, LABEL());
OP1(SLJIT_MOV, SLJIT_RETURN_REG, 0, SLJIT_IMM, PCRE_ERROR_MATCHLIMIT);
-JUMPTO(SLJIT_JUMP, leave);
+JUMPTO(SLJIT_JUMP, common->quitlabel);
if (common->revertframes != NULL)
{
@@ -6681,19 +8189,21 @@ if (common->caselesscmp != NULL)
do_caselesscmp(common);
}
#ifdef SUPPORT_UTF
+#ifndef COMPILE_PCRE32
if (common->utfreadchar != NULL)
{
set_jumps(common->utfreadchar, LABEL());
do_utfreadchar(common);
}
+#endif /* !COMPILE_PCRE32 */
#ifdef COMPILE_PCRE8
if (common->utfreadtype8 != NULL)
{
set_jumps(common->utfreadtype8, LABEL());
do_utfreadtype8(common);
}
-#endif
#endif /* COMPILE_PCRE8 */
+#endif /* SUPPORT_UTF */
#ifdef SUPPORT_UCP
if (common->getucd != NULL)
{
@@ -6702,54 +8212,69 @@ if (common->getucd != NULL)
}
#endif
-SLJIT_FREE(common->localptrs);
+SLJIT_FREE(common->optimized_cbracket);
+SLJIT_FREE(common->private_data_ptrs);
executable_func = sljit_generate_code(compiler);
executable_size = sljit_get_generated_code_size(compiler);
sljit_free_compiler(compiler);
if (executable_func == NULL)
return;
-function = SLJIT_MALLOC(sizeof(executable_function));
-if (function == NULL)
+/* Reuse the function descriptor if possible. */
+if ((extra->flags & PCRE_EXTRA_EXECUTABLE_JIT) != 0 && extra->executable_jit != NULL)
+ functions = (executable_functions *)extra->executable_jit;
+else
{
- /* This case is highly unlikely since we just recently
- freed a lot of memory. Although not impossible. */
- sljit_free_code(executable_func);
- return;
+ /* Note: If your memory-checker has flagged the allocation below as a
+ * memory leak, it is probably because you either forgot to call
+ * pcre_free_study() (or pcre16_free_study()) on the pcre_extra (or
+ * pcre16_extra) object, or you called said function after having
+ * cleared the PCRE_EXTRA_EXECUTABLE_JIT bit from the "flags" field
+ * of the object. (The function will only free the JIT data if the
+ * bit remains set, as the bit indicates that the pointer to the data
+ * is valid.)
+ */
+ functions = SLJIT_MALLOC(sizeof(executable_functions));
+ if (functions == NULL)
+ {
+ /* This case is highly unlikely since we just recently
+ freed a lot of memory. Although not impossible. */
+ sljit_free_code(executable_func);
+ return;
+ }
+ memset(functions, 0, sizeof(executable_functions));
+ functions->top_bracket = (re->top_bracket + 1) * 2;
+ extra->executable_jit = functions;
+ extra->flags |= PCRE_EXTRA_EXECUTABLE_JIT;
}
-function->executable_func = executable_func;
-function->executable_size = executable_size;
-function->callback = NULL;
-function->userdata = NULL;
-extra->executable_jit = function;
-extra->flags |= PCRE_EXTRA_EXECUTABLE_JIT;
+functions->executable_funcs[mode] = executable_func;
+functions->executable_sizes[mode] = executable_size;
}
-static int jit_machine_stack_exec(jit_arguments *arguments, executable_function *function)
+static int jit_machine_stack_exec(jit_arguments *arguments, void* executable_func)
{
union {
void* executable_func;
jit_function call_executable_func;
} convert_executable_func;
-pcre_uint8 local_area[LOCAL_SPACE_SIZE];
+pcre_uint8 local_space[MACHINE_STACK_SIZE];
struct sljit_stack local_stack;
-local_stack.top = (sljit_w)&local_area;
+local_stack.top = (sljit_sw)&local_space;
local_stack.base = local_stack.top;
-local_stack.limit = local_stack.base + LOCAL_SPACE_SIZE;
+local_stack.limit = local_stack.base + MACHINE_STACK_SIZE;
local_stack.max_limit = local_stack.limit;
arguments->stack = &local_stack;
-convert_executable_func.executable_func = function->executable_func;
+convert_executable_func.executable_func = executable_func;
return convert_executable_func.call_executable_func(arguments);
}
int
-PRIV(jit_exec)(const REAL_PCRE *re, void *executable_func,
- const pcre_uchar *subject, int length, int start_offset, int options,
- int match_limit, int *offsets, int offsetcount)
+PRIV(jit_exec)(const PUBL(extra) *extra_data, const pcre_uchar *subject,
+ int length, int start_offset, int options, int *offsets, int offsetcount)
{
-executable_function *function = (executable_function*)executable_func;
+executable_functions *functions = (executable_functions *)extra_data->executable_jit;
union {
void* executable_func;
jit_function call_executable_func;
@@ -6757,13 +8282,23 @@ union {
jit_arguments arguments;
int maxoffsetcount;
int retval;
+int mode = JIT_COMPILE;
+
+if ((options & PCRE_PARTIAL_HARD) != 0)
+ mode = JIT_PARTIAL_HARD_COMPILE;
+else if ((options & PCRE_PARTIAL_SOFT) != 0)
+ mode = JIT_PARTIAL_SOFT_COMPILE;
+
+if (functions->executable_funcs[mode] == NULL)
+ return PCRE_ERROR_JIT_BADOPTION;
/* Sanity checks should be handled by pcre_exec. */
-arguments.stack = NULL;
arguments.str = subject + start_offset;
arguments.begin = subject;
arguments.end = subject + length;
-arguments.calllimit = match_limit; /* JIT decreases this value less times. */
+arguments.mark_ptr = NULL;
+/* JIT decreases this value less frequently than the interpreter. */
+arguments.calllimit = ((extra_data->flags & PCRE_EXTRA_MATCH_LIMIT) == 0) ? MATCH_LIMIT : extra_data->match_limit;
arguments.notbol = (options & PCRE_NOTBOL) != 0;
arguments.noteol = (options & PCRE_NOTEOL) != 0;
arguments.notempty = (options & PCRE_NOTEMPTY) != 0;
@@ -6778,41 +8313,133 @@ gets the same result with and without JIT. */
if (offsetcount != 2)
offsetcount = ((offsetcount - (offsetcount % 3)) * 2) / 3;
-maxoffsetcount = (re->top_bracket + 1) * 2;
+maxoffsetcount = functions->top_bracket;
if (offsetcount > maxoffsetcount)
offsetcount = maxoffsetcount;
arguments.offsetcount = offsetcount;
-if (function->callback)
- arguments.stack = (struct sljit_stack*)function->callback(function->userdata);
+if (functions->callback)
+ arguments.stack = (struct sljit_stack *)functions->callback(functions->userdata);
else
- arguments.stack = (struct sljit_stack*)function->userdata;
+ arguments.stack = (struct sljit_stack *)functions->userdata;
if (arguments.stack == NULL)
- retval = jit_machine_stack_exec(&arguments, function);
+ retval = jit_machine_stack_exec(&arguments, functions->executable_funcs[mode]);
else
{
- convert_executable_func.executable_func = function->executable_func;
+ convert_executable_func.executable_func = functions->executable_funcs[mode];
retval = convert_executable_func.call_executable_func(&arguments);
}
if (retval * 2 > offsetcount)
retval = 0;
+if ((extra_data->flags & PCRE_EXTRA_MARK) != 0)
+ *(extra_data->mark) = arguments.mark_ptr;
+
+return retval;
+}
+
+#if defined COMPILE_PCRE8
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre_jit_exec(const pcre *argument_re, const pcre_extra *extra_data,
+ PCRE_SPTR subject, int length, int start_offset, int options,
+ int *offsets, int offsetcount, pcre_jit_stack *stack)
+#elif defined COMPILE_PCRE16
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre16_jit_exec(const pcre16 *argument_re, const pcre16_extra *extra_data,
+ PCRE_SPTR16 subject, int length, int start_offset, int options,
+ int *offsets, int offsetcount, pcre16_jit_stack *stack)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_jit_exec(const pcre32 *argument_re, const pcre32_extra *extra_data,
+ PCRE_SPTR32 subject, int length, int start_offset, int options,
+ int *offsets, int offsetcount, pcre32_jit_stack *stack)
+#endif
+{
+pcre_uchar *subject_ptr = (pcre_uchar *)subject;
+executable_functions *functions = (executable_functions *)extra_data->executable_jit;
+union {
+ void* executable_func;
+ jit_function call_executable_func;
+} convert_executable_func;
+jit_arguments arguments;
+int maxoffsetcount;
+int retval;
+int mode = JIT_COMPILE;
+
+SLJIT_UNUSED_ARG(argument_re);
+
+/* Plausibility checks */
+if ((options & ~PUBLIC_JIT_EXEC_OPTIONS) != 0) return PCRE_ERROR_JIT_BADOPTION;
+
+if ((options & PCRE_PARTIAL_HARD) != 0)
+ mode = JIT_PARTIAL_HARD_COMPILE;
+else if ((options & PCRE_PARTIAL_SOFT) != 0)
+ mode = JIT_PARTIAL_SOFT_COMPILE;
+
+if (functions->executable_funcs[mode] == NULL)
+ return PCRE_ERROR_JIT_BADOPTION;
+
+/* Sanity checks should be handled by pcre_exec. */
+arguments.stack = (struct sljit_stack *)stack;
+arguments.str = subject_ptr + start_offset;
+arguments.begin = subject_ptr;
+arguments.end = subject_ptr + length;
+arguments.mark_ptr = NULL;
+/* JIT decreases this value less frequently than the interpreter. */
+arguments.calllimit = ((extra_data->flags & PCRE_EXTRA_MATCH_LIMIT) == 0) ? MATCH_LIMIT : extra_data->match_limit;
+arguments.notbol = (options & PCRE_NOTBOL) != 0;
+arguments.noteol = (options & PCRE_NOTEOL) != 0;
+arguments.notempty = (options & PCRE_NOTEMPTY) != 0;
+arguments.notempty_atstart = (options & PCRE_NOTEMPTY_ATSTART) != 0;
+arguments.offsets = offsets;
+
+/* pcre_exec() rounds offsetcount to a multiple of 3, and then uses only 2/3 of
+the output vector for storing captured strings, with the remainder used as
+workspace. We don't need the workspace here. For compatibility, we limit the
+number of captured strings in the same way as pcre_exec(), so that the user
+gets the same result with and without JIT. */
+
+if (offsetcount != 2)
+ offsetcount = ((offsetcount - (offsetcount % 3)) * 2) / 3;
+maxoffsetcount = functions->top_bracket;
+if (offsetcount > maxoffsetcount)
+ offsetcount = maxoffsetcount;
+arguments.offsetcount = offsetcount;
+
+convert_executable_func.executable_func = functions->executable_funcs[mode];
+retval = convert_executable_func.call_executable_func(&arguments);
+
+if (retval * 2 > offsetcount)
+ retval = 0;
+if ((extra_data->flags & PCRE_EXTRA_MARK) != 0)
+ *(extra_data->mark) = arguments.mark_ptr;
+
return retval;
}
void
-PRIV(jit_free)(void *executable_func)
+PRIV(jit_free)(void *executable_funcs)
{
-executable_function *function = (executable_function*)executable_func;
-sljit_free_code(function->executable_func);
-SLJIT_FREE(function);
+int i;
+executable_functions *functions = (executable_functions *)executable_funcs;
+for (i = 0; i < JIT_NUMBER_OF_COMPILE_MODES; i++)
+ {
+ if (functions->executable_funcs[i] != NULL)
+ sljit_free_code(functions->executable_funcs[i]);
+ }
+SLJIT_FREE(functions);
}
int
-PRIV(jit_get_size)(void *executable_func)
+PRIV(jit_get_size)(void *executable_funcs)
{
-return ((executable_function*)executable_func)->executable_size;
+int i;
+sljit_uw size = 0;
+sljit_uw *executable_sizes = ((executable_functions *)executable_funcs)->executable_sizes;
+for (i = 0; i < JIT_NUMBER_OF_COMPILE_MODES; i++)
+ size += executable_sizes[i];
+return (int)size;
}
const char*
@@ -6821,12 +8448,15 @@ PRIV(jit_get_target)(void)
return sljit_get_platform_name();
}
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DECL pcre_jit_stack *
pcre_jit_stack_alloc(int startsize, int maxsize)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DECL pcre16_jit_stack *
pcre16_jit_stack_alloc(int startsize, int maxsize)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DECL pcre32_jit_stack *
+pcre32_jit_stack_alloc(int startsize, int maxsize)
#endif
{
if (startsize < 1 || maxsize < 1)
@@ -6838,33 +8468,39 @@ maxsize = (maxsize + STACK_GROWTH_RATE - 1) & ~(STACK_GROWTH_RATE - 1);
return (PUBL(jit_stack)*)sljit_allocate_stack(startsize, maxsize);
}
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DECL void
pcre_jit_stack_free(pcre_jit_stack *stack)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DECL void
pcre16_jit_stack_free(pcre16_jit_stack *stack)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DECL void
+pcre32_jit_stack_free(pcre32_jit_stack *stack)
#endif
{
-sljit_free_stack((struct sljit_stack*)stack);
+sljit_free_stack((struct sljit_stack *)stack);
}
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DECL void
pcre_assign_jit_stack(pcre_extra *extra, pcre_jit_callback callback, void *userdata)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DECL void
pcre16_assign_jit_stack(pcre16_extra *extra, pcre16_jit_callback callback, void *userdata)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DECL void
+pcre32_assign_jit_stack(pcre32_extra *extra, pcre32_jit_callback callback, void *userdata)
#endif
{
-executable_function *function;
+executable_functions *functions;
if (extra != NULL &&
(extra->flags & PCRE_EXTRA_EXECUTABLE_JIT) != 0 &&
extra->executable_jit != NULL)
{
- function = (executable_function*)extra->executable_jit;
- function->callback = callback;
- function->userdata = userdata;
+ functions = (executable_functions *)extra->executable_jit;
+ functions->callback = callback;
+ functions->userdata = userdata;
}
}
@@ -6873,12 +8509,15 @@ if (extra != NULL &&
/* These are dummy functions to avoid linking errors when JIT support is not
being compiled. */
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DECL pcre_jit_stack *
pcre_jit_stack_alloc(int startsize, int maxsize)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DECL pcre16_jit_stack *
pcre16_jit_stack_alloc(int startsize, int maxsize)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DECL pcre32_jit_stack *
+pcre32_jit_stack_alloc(int startsize, int maxsize)
#endif
{
(void)startsize;
@@ -6886,23 +8525,29 @@ pcre16_jit_stack_alloc(int startsize, int maxsize)
return NULL;
}
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DECL void
pcre_jit_stack_free(pcre_jit_stack *stack)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DECL void
pcre16_jit_stack_free(pcre16_jit_stack *stack)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DECL void
+pcre32_jit_stack_free(pcre32_jit_stack *stack)
#endif
{
(void)stack;
}
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DECL void
pcre_assign_jit_stack(pcre_extra *extra, pcre_jit_callback callback, void *userdata)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DECL void
pcre16_assign_jit_stack(pcre16_extra *extra, pcre16_jit_callback callback, void *userdata)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DECL void
+pcre32_assign_jit_stack(pcre32_extra *extra, pcre32_jit_callback callback, void *userdata)
#endif
{
(void)extra;
diff --git a/src/3rdparty/pcre/pcre_maketables.c b/src/3rdparty/pcre/pcre_maketables.c
index caacdba3e6..de1ea65cf6 100644
--- a/src/3rdparty/pcre/pcre_maketables.c
+++ b/src/3rdparty/pcre/pcre_maketables.c
@@ -66,12 +66,15 @@ Arguments: none
Returns: pointer to the contiguous block of data
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
const unsigned char *
pcre_maketables(void)
-#else
+#elif defined COMPILE_PCRE16
const unsigned char *
pcre16_maketables(void)
+#elif defined COMPILE_PCRE32
+const unsigned char *
+pcre32_maketables(void)
#endif
{
unsigned char *yield, *p;
@@ -127,7 +130,7 @@ within regexes. */
for (i = 0; i < 256; i++)
{
int x = 0;
- if (i != 0x0b && isspace(i)) x += ctype_space;
+ if (i != CHAR_VT && isspace(i)) x += ctype_space;
if (isalpha(i)) x += ctype_letter;
if (isdigit(i)) x += ctype_digit;
if (isxdigit(i)) x += ctype_xdigit;
diff --git a/src/3rdparty/pcre/pcre_newline.c b/src/3rdparty/pcre/pcre_newline.c
index 8ee2a6e588..71535b83e1 100644
--- a/src/3rdparty/pcre/pcre_newline.c
+++ b/src/3rdparty/pcre/pcre_newline.c
@@ -76,7 +76,7 @@ BOOL
PRIV(is_newline)(PCRE_PUCHAR ptr, int type, PCRE_PUCHAR endptr, int *lenptr,
BOOL utf)
{
-int c;
+pcre_uint32 c;
(void)utf;
#ifdef SUPPORT_UTF
if (utf)
@@ -87,11 +87,13 @@ else
#endif /* SUPPORT_UTF */
c = *ptr;
+/* Note that this function is called only for ANY or ANYCRLF. */
+
if (type == NLTYPE_ANYCRLF) switch(c)
{
- case 0x000a: *lenptr = 1; return TRUE; /* LF */
- case 0x000d: *lenptr = (ptr < endptr - 1 && ptr[1] == 0x0a)? 2 : 1;
- return TRUE; /* CR */
+ case CHAR_LF: *lenptr = 1; return TRUE;
+ case CHAR_CR: *lenptr = (ptr < endptr - 1 && ptr[1] == CHAR_LF)? 2 : 1;
+ return TRUE;
default: return FALSE;
}
@@ -99,20 +101,29 @@ if (type == NLTYPE_ANYCRLF) switch(c)
else switch(c)
{
- case 0x000a: /* LF */
- case 0x000b: /* VT */
- case 0x000c: *lenptr = 1; return TRUE; /* FF */
- case 0x000d: *lenptr = (ptr < endptr - 1 && ptr[1] == 0x0a)? 2 : 1;
- return TRUE; /* CR */
+#ifdef EBCDIC
+ case CHAR_NEL:
+#endif
+ case CHAR_LF:
+ case CHAR_VT:
+ case CHAR_FF: *lenptr = 1; return TRUE;
+
+ case CHAR_CR:
+ *lenptr = (ptr < endptr - 1 && ptr[1] == CHAR_LF)? 2 : 1;
+ return TRUE;
+
+#ifndef EBCDIC
#ifdef COMPILE_PCRE8
- case 0x0085: *lenptr = utf? 2 : 1; return TRUE; /* NEL */
+ case CHAR_NEL: *lenptr = utf? 2 : 1; return TRUE;
case 0x2028: /* LS */
case 0x2029: *lenptr = 3; return TRUE; /* PS */
-#else
- case 0x0085: /* NEL */
+#else /* COMPILE_PCRE16 || COMPILE_PCRE32 */
+ case CHAR_NEL:
case 0x2028: /* LS */
case 0x2029: *lenptr = 1; return TRUE; /* PS */
-#endif /* COMPILE_PCRE8 */
+#endif /* COMPILE_PCRE8 */
+#endif /* Not EBCDIC */
+
default: return FALSE;
}
}
@@ -140,7 +151,7 @@ BOOL
PRIV(was_newline)(PCRE_PUCHAR ptr, int type, PCRE_PUCHAR startptr, int *lenptr,
BOOL utf)
{
-int c;
+pcre_uint32 c;
(void)utf;
ptr--;
#ifdef SUPPORT_UTF
@@ -153,30 +164,45 @@ else
#endif /* SUPPORT_UTF */
c = *ptr;
+/* Note that this function is called only for ANY or ANYCRLF. */
+
if (type == NLTYPE_ANYCRLF) switch(c)
{
- case 0x000a: *lenptr = (ptr > startptr && ptr[-1] == 0x0d)? 2 : 1;
- return TRUE; /* LF */
- case 0x000d: *lenptr = 1; return TRUE; /* CR */
+ case CHAR_LF:
+ *lenptr = (ptr > startptr && ptr[-1] == CHAR_CR)? 2 : 1;
+ return TRUE;
+
+ case CHAR_CR: *lenptr = 1; return TRUE;
default: return FALSE;
}
+/* NLTYPE_ANY */
+
else switch(c)
{
- case 0x000a: *lenptr = (ptr > startptr && ptr[-1] == 0x0d)? 2 : 1;
- return TRUE; /* LF */
- case 0x000b: /* VT */
- case 0x000c: /* FF */
- case 0x000d: *lenptr = 1; return TRUE; /* CR */
+ case CHAR_LF:
+ *lenptr = (ptr > startptr && ptr[-1] == CHAR_CR)? 2 : 1;
+ return TRUE;
+
+#ifdef EBCDIC
+ case CHAR_NEL:
+#endif
+ case CHAR_VT:
+ case CHAR_FF:
+ case CHAR_CR: *lenptr = 1; return TRUE;
+
+#ifndef EBCDIC
#ifdef COMPILE_PCRE8
- case 0x0085: *lenptr = utf? 2 : 1; return TRUE; /* NEL */
- case 0x2028: /* LS */
- case 0x2029: *lenptr = 3; return TRUE; /* PS */
-#else
- case 0x0085: /* NEL */
+ case CHAR_NEL: *lenptr = utf? 2 : 1; return TRUE;
+ case 0x2028: /* LS */
+ case 0x2029: *lenptr = 3; return TRUE; /* PS */
+#else /* COMPILE_PCRE16 || COMPILE_PCRE32 */
+ case CHAR_NEL:
case 0x2028: /* LS */
case 0x2029: *lenptr = 1; return TRUE; /* PS */
-#endif /* COMPILE_PCRE8 */
+#endif /* COMPILE_PCRE8 */
+#endif /* NotEBCDIC */
+
default: return FALSE;
}
}
diff --git a/src/3rdparty/pcre/pcre_ord2utf8.c b/src/3rdparty/pcre/pcre_ord2utf8.c
index 6afd235f79..dc250c8ca8 100644
--- a/src/3rdparty/pcre/pcre_ord2utf8.c
+++ b/src/3rdparty/pcre/pcre_ord2utf8.c
@@ -45,15 +45,16 @@ character value into a UTF8 string. */
#include "config.h"
#endif
-#include "pcre_internal.h"
+#define COMPILE_PCRE8
+#include "pcre_internal.h"
/*************************************************
* Convert character value to UTF-8 *
*************************************************/
/* This function takes an integer value in the range 0 - 0x10ffff
-and encodes it as a UTF-8 character in 1 to 6 pcre_uchars.
+and encodes it as a UTF-8 character in 1 to 4 pcre_uchars.
Arguments:
cvalue the character value
@@ -62,6 +63,7 @@ Arguments:
Returns: number of characters placed in the buffer
*/
+unsigned
int
PRIV(ord2utf)(pcre_uint32 cvalue, pcre_uchar *buffer)
{
@@ -69,11 +71,6 @@ PRIV(ord2utf)(pcre_uint32 cvalue, pcre_uchar *buffer)
register int i, j;
-/* Checking invalid cvalue character, encoded as invalid UTF-16 character.
-Should never happen in practice. */
-if ((cvalue & 0xf800) == 0xd800 || cvalue >= 0x110000)
- cvalue = 0xfffe;
-
for (i = 0; i < PRIV(utf8_table1_size); i++)
if ((int)cvalue <= PRIV(utf8_table1)[i]) break;
buffer += i;
diff --git a/src/3rdparty/pcre/pcre_refcount.c b/src/3rdparty/pcre/pcre_refcount.c
index 263a1e11dc..d1855a3736 100644
--- a/src/3rdparty/pcre/pcre_refcount.c
+++ b/src/3rdparty/pcre/pcre_refcount.c
@@ -68,12 +68,15 @@ Returns: the (possibly updated) count value (a non-negative number), or
a negative error number
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre_refcount(pcre *argument_re, int adjust)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
pcre16_refcount(pcre16 *argument_re, int adjust)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN int PCRE_CALL_CONVENTION
+pcre32_refcount(pcre32 *argument_re, int adjust)
#endif
{
REAL_PCRE *re = (REAL_PCRE *)argument_re;
diff --git a/src/3rdparty/pcre/pcre_string_utils.c b/src/3rdparty/pcre/pcre_string_utils.c
index d4545532a7..a9b4e77c00 100644
--- a/src/3rdparty/pcre/pcre_string_utils.c
+++ b/src/3rdparty/pcre/pcre_string_utils.c
@@ -81,6 +81,27 @@ while (*str1 != '\0' || *str2 != '\0')
return 0;
}
+#ifdef COMPILE_PCRE32
+
+int
+PRIV(strcmp_uc_uc_utf)(const pcre_uchar *str1, const pcre_uchar *str2)
+{
+pcre_uchar c1;
+pcre_uchar c2;
+
+while (*str1 != '\0' || *str2 != '\0')
+ {
+ c1 = RAWUCHARINC(str1);
+ c2 = RAWUCHARINC(str2);
+ if (c1 != c2)
+ return ((c1 > c2) << 1) - 1;
+ }
+/* Both length and characters must be equal. */
+return 0;
+}
+
+#endif /* COMPILE_PCRE32 */
+
int
PRIV(strcmp_uc_c8)(const pcre_uchar *str1, const char *str2)
{
@@ -99,6 +120,28 @@ while (*str1 != '\0' || *ustr2 != '\0')
return 0;
}
+#ifdef COMPILE_PCRE32
+
+int
+PRIV(strcmp_uc_c8_utf)(const pcre_uchar *str1, const char *str2)
+{
+const pcre_uint8 *ustr2 = (pcre_uint8 *)str2;
+pcre_uchar c1;
+pcre_uchar c2;
+
+while (*str1 != '\0' || *ustr2 != '\0')
+ {
+ c1 = RAWUCHARINC(str1);
+ c2 = (pcre_uchar)*ustr2++;
+ if (c1 != c2)
+ return ((c1 > c2) << 1) - 1;
+ }
+/* Both length and characters must be equal. */
+return 0;
+}
+
+#endif /* COMPILE_PCRE32 */
+
/* The following two functions compares two, fixed length
strings. Basically an strncmp for non 8 bit characters.
@@ -163,6 +206,6 @@ while (*str++ != 0)
return len;
}
-#endif /* COMPILE_PCRE8 */
+#endif /* !COMPILE_PCRE8 */
/* End of pcre_string_utils.c */
diff --git a/src/3rdparty/pcre/pcre_study.c b/src/3rdparty/pcre/pcre_study.c
index 6b6edc3f31..6040e4dbdc 100644
--- a/src/3rdparty/pcre/pcre_study.c
+++ b/src/3rdparty/pcre/pcre_study.c
@@ -98,7 +98,7 @@ for (;;)
{
int d, min;
pcre_uchar *cs, *ce;
- register int op = *cc;
+ register pcre_uchar op = *cc;
switch (op)
{
@@ -323,15 +323,19 @@ for (;;)
/* Check a class for variable quantification */
-#if defined SUPPORT_UTF || !defined COMPILE_PCRE8
- case OP_XCLASS:
- cc += GET(cc, 1) - PRIV(OP_lengths)[OP_CLASS];
- /* Fall through */
-#endif
-
case OP_CLASS:
case OP_NCLASS:
+#if defined SUPPORT_UTF || defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ case OP_XCLASS:
+ /* The original code caused an unsigned overflow in 64 bit systems,
+ so now we use a conditional statement. */
+ if (op == OP_XCLASS)
+ cc += GET(cc, 1);
+ else
+ cc += PRIV(OP_lengths)[OP_CLASS];
+#else
cc += PRIV(OP_lengths)[OP_CLASS];
+#endif
switch (*cc)
{
@@ -538,7 +542,7 @@ Arguments:
p points to the character
caseless the caseless flag
cd the block with char table pointers
- utf TRUE for UTF-8 / UTF-16 mode
+ utf TRUE for UTF-8 / UTF-16 / UTF-32 mode
Returns: pointer after the character
*/
@@ -547,7 +551,7 @@ static const pcre_uchar *
set_table_bit(pcre_uint8 *start_bits, const pcre_uchar *p, BOOL caseless,
compile_data *cd, BOOL utf)
{
-unsigned int c = *p;
+pcre_uint32 c = *p;
#ifdef COMPILE_PCRE8
SET_BIT(c);
@@ -564,18 +568,20 @@ if (utf && c > 127)
(void)PRIV(ord2utf)(c, buff);
SET_BIT(buff[0]);
}
-#endif
+#endif /* Not SUPPORT_UCP */
return p;
}
-#endif
+#else /* Not SUPPORT_UTF */
+(void)(utf); /* Stops warning for unused parameter */
+#endif /* SUPPORT_UTF */
/* Not UTF-8 mode, or character is less than 127. */
if (caseless && (cd->ctypes[c] & ctype_letter) != 0) SET_BIT(cd->fcc[c]);
return p + 1;
-#endif
+#endif /* COMPILE_PCRE8 */
-#ifdef COMPILE_PCRE16
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
if (c > 0xff)
{
c = 0xff;
@@ -595,10 +601,12 @@ if (utf && c > 127)
c = 0xff;
SET_BIT(c);
}
-#endif
+#endif /* SUPPORT_UCP */
return p;
}
-#endif
+#else /* Not SUPPORT_UTF */
+(void)(utf); /* Stops warning for unused parameter */
+#endif /* SUPPORT_UTF */
if (caseless && (cd->ctypes[c] & ctype_letter) != 0) SET_BIT(cd->fcc[c]);
return p + 1;
@@ -628,10 +636,10 @@ Returns: nothing
*/
static void
-set_type_bits(pcre_uint8 *start_bits, int cbit_type, int table_limit,
+set_type_bits(pcre_uint8 *start_bits, int cbit_type, unsigned int table_limit,
compile_data *cd)
{
-register int c;
+register pcre_uint32 c;
for (c = 0; c < table_limit; c++) start_bits[c] |= cd->cbits[c+cbit_type];
#if defined SUPPORT_UTF && defined COMPILE_PCRE8
if (table_limit == 32) return;
@@ -670,10 +678,10 @@ Returns: nothing
*/
static void
-set_nottype_bits(pcre_uint8 *start_bits, int cbit_type, int table_limit,
+set_nottype_bits(pcre_uint8 *start_bits, int cbit_type, unsigned int table_limit,
compile_data *cd)
{
-register int c;
+register pcre_uint32 c;
for (c = 0; c < table_limit; c++) start_bits[c] |= ~cd->cbits[c+cbit_type];
#if defined SUPPORT_UTF && defined COMPILE_PCRE8
if (table_limit != 32) for (c = 24; c < 32; c++) start_bits[c] = 0xff;
@@ -697,7 +705,7 @@ function fails unless the result is SSB_DONE.
Arguments:
code points to an expression
start_bits points to a 32-byte table, initialized to 0
- utf TRUE if in UTF-8 / UTF-16 mode
+ utf TRUE if in UTF-8 / UTF-16 / UTF-32 mode
cd the block with char table pointers
Returns: SSB_FAIL => Failed to find any starting bytes
@@ -710,7 +718,7 @@ static int
set_start_bits(const pcre_uchar *code, pcre_uint8 *start_bits, BOOL utf,
compile_data *cd)
{
-register int c;
+register pcre_uint32 c;
int yield = SSB_DONE;
#if defined SUPPORT_UTF && defined COMPILE_PCRE8
int table_limit = utf? 16:32;
@@ -986,8 +994,8 @@ do
identical. */
case OP_HSPACE:
- SET_BIT(0x09);
- SET_BIT(0x20);
+ SET_BIT(CHAR_HT);
+ SET_BIT(CHAR_SPACE);
#ifdef SUPPORT_UTF
if (utf)
{
@@ -996,46 +1004,46 @@ do
SET_BIT(0xE1); /* For U+1680, U+180E */
SET_BIT(0xE2); /* For U+2000 - U+200A, U+202F, U+205F */
SET_BIT(0xE3); /* For U+3000 */
-#endif
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16 || defined COMPILE_PCRE32
SET_BIT(0xA0);
SET_BIT(0xFF); /* For characters > 255 */
-#endif
+#endif /* COMPILE_PCRE[8|16|32] */
}
else
#endif /* SUPPORT_UTF */
{
+#ifndef EBCDIC
SET_BIT(0xA0);
-#ifdef COMPILE_PCRE16
+#endif /* Not EBCDIC */
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
SET_BIT(0xFF); /* For characters > 255 */
-#endif
+#endif /* COMPILE_PCRE[16|32] */
}
try_next = FALSE;
break;
case OP_ANYNL:
case OP_VSPACE:
- SET_BIT(0x0A);
- SET_BIT(0x0B);
- SET_BIT(0x0C);
- SET_BIT(0x0D);
+ SET_BIT(CHAR_LF);
+ SET_BIT(CHAR_VT);
+ SET_BIT(CHAR_FF);
+ SET_BIT(CHAR_CR);
#ifdef SUPPORT_UTF
if (utf)
{
#ifdef COMPILE_PCRE8
SET_BIT(0xC2); /* For U+0085 */
SET_BIT(0xE2); /* For U+2028, U+2029 */
-#endif
-#ifdef COMPILE_PCRE16
- SET_BIT(0x85);
+#elif defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ SET_BIT(CHAR_NEL);
SET_BIT(0xFF); /* For characters > 255 */
-#endif
+#endif /* COMPILE_PCRE[8|16|32] */
}
else
#endif /* SUPPORT_UTF */
{
- SET_BIT(0x85);
-#ifdef COMPILE_PCRE16
+ SET_BIT(CHAR_NEL);
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
SET_BIT(0xFF); /* For characters > 255 */
#endif
}
@@ -1058,7 +1066,8 @@ do
break;
/* The cbit_space table has vertical tab as whitespace; we have to
- ensure it is set as not whitespace. */
+ ensure it is set as not whitespace. Luckily, the code value is the same
+ (0x0b) in ASCII and EBCDIC, so we can just adjust the appropriate bit. */
case OP_NOT_WHITESPACE:
set_nottype_bits(start_bits, cbit_space, table_limit, cd);
@@ -1066,8 +1075,9 @@ do
try_next = FALSE;
break;
- /* The cbit_space table has vertical tab as whitespace; we have to
- not set it from the table. */
+ /* The cbit_space table has vertical tab as whitespace; we have to not
+ set it from the table. Luckily, the code value is the same (0x0b) in
+ ASCII and EBCDIC, so we can just adjust the appropriate bit. */
case OP_WHITESPACE:
c = start_bits[1]; /* Save in case it was already set */
@@ -1121,9 +1131,9 @@ do
return SSB_FAIL;
case OP_HSPACE:
- SET_BIT(0x09);
- SET_BIT(0x20);
-#ifdef COMPILE_PCRE8
+ SET_BIT(CHAR_HT);
+ SET_BIT(CHAR_SPACE);
+#ifdef SUPPORT_UTF
if (utf)
{
#ifdef COMPILE_PCRE8
@@ -1131,38 +1141,38 @@ do
SET_BIT(0xE1); /* For U+1680, U+180E */
SET_BIT(0xE2); /* For U+2000 - U+200A, U+202F, U+205F */
SET_BIT(0xE3); /* For U+3000 */
-#endif
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16 || defined COMPILE_PCRE32
SET_BIT(0xA0);
SET_BIT(0xFF); /* For characters > 255 */
-#endif
+#endif /* COMPILE_PCRE[8|16|32] */
}
else
#endif /* SUPPORT_UTF */
+#ifndef EBCDIC
SET_BIT(0xA0);
+#endif /* Not EBCDIC */
break;
case OP_ANYNL:
case OP_VSPACE:
- SET_BIT(0x0A);
- SET_BIT(0x0B);
- SET_BIT(0x0C);
- SET_BIT(0x0D);
-#ifdef COMPILE_PCRE8
+ SET_BIT(CHAR_LF);
+ SET_BIT(CHAR_VT);
+ SET_BIT(CHAR_FF);
+ SET_BIT(CHAR_CR);
+#ifdef SUPPORT_UTF
if (utf)
{
#ifdef COMPILE_PCRE8
SET_BIT(0xC2); /* For U+0085 */
SET_BIT(0xE2); /* For U+2028, U+2029 */
-#endif
-#ifdef COMPILE_PCRE16
- SET_BIT(0x85);
+#elif defined COMPILE_PCRE16 || defined COMPILE_PCRE32
+ SET_BIT(CHAR_NEL);
SET_BIT(0xFF); /* For characters > 255 */
-#endif
+#endif /* COMPILE_PCRE16 */
}
else
#endif /* SUPPORT_UTF */
- SET_BIT(0x85);
+ SET_BIT(CHAR_NEL);
break;
case OP_NOT_DIGIT:
@@ -1174,7 +1184,9 @@ do
break;
/* The cbit_space table has vertical tab as whitespace; we have to
- ensure it gets set as not whitespace. */
+ ensure it gets set as not whitespace. Luckily, the code value is the
+ same (0x0b) in ASCII and EBCDIC, so we can just adjust the appropriate
+ bit. */
case OP_NOT_WHITESPACE:
set_nottype_bits(start_bits, cbit_space, table_limit, cd);
@@ -1182,7 +1194,8 @@ do
break;
/* The cbit_space table has vertical tab as whitespace; we have to
- avoid setting it. */
+ avoid setting it. Luckily, the code value is the same (0x0b) in ASCII
+ and EBCDIC, so we can just adjust the appropriate bit. */
case OP_WHITESPACE:
c = start_bits[1]; /* Save in case it was already set */
@@ -1216,7 +1229,7 @@ do
memset(start_bits+25, 0xff, 7); /* Bits for 0xc9 - 0xff */
}
#endif
-#ifdef COMPILE_PCRE16
+#if defined COMPILE_PCRE16 || defined COMPILE_PCRE32
SET_BIT(0xFF); /* For characters > 255 */
#endif
/* Fall through */
@@ -1312,12 +1325,15 @@ Returns: pointer to a pcre[16]_extra block, with study_data filled in and
NULL on error or if no optimization possible
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN pcre_extra * PCRE_CALL_CONVENTION
pcre_study(const pcre *external_re, int options, const char **errorptr)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN pcre16_extra * PCRE_CALL_CONVENTION
pcre16_study(const pcre16 *external_re, int options, const char **errorptr)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN pcre32_extra * PCRE_CALL_CONVENTION
+pcre32_study(const pcre32 *external_re, int options, const char **errorptr)
#endif
{
int min;
@@ -1340,10 +1356,12 @@ if (re == NULL || re->magic_number != MAGIC_NUMBER)
if ((re->flags & PCRE_MODE) == 0)
{
-#ifdef COMPILE_PCRE8
- *errorptr = "argument is compiled in 16 bit mode";
-#else
- *errorptr = "argument is compiled in 8 bit mode";
+#if defined COMPILE_PCRE8
+ *errorptr = "argument not compiled in 8 bit mode";
+#elif defined COMPILE_PCRE16
+ *errorptr = "argument not compiled in 16 bit mode";
+#elif defined COMPILE_PCRE32
+ *errorptr = "argument not compiled in 32 bit mode";
#endif
return NULL;
}
@@ -1370,14 +1388,18 @@ if ((re->options & PCRE_ANCHORED) == 0 &&
tables = re->tables;
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
if (tables == NULL)
(void)pcre_fullinfo(external_re, NULL, PCRE_INFO_DEFAULT_TABLES,
(void *)(&tables));
-#else
+#elif defined COMPILE_PCRE16
if (tables == NULL)
(void)pcre16_fullinfo(external_re, NULL, PCRE_INFO_DEFAULT_TABLES,
(void *)(&tables));
+#elif defined COMPILE_PCRE32
+ if (tables == NULL)
+ (void)pcre32_fullinfo(external_re, NULL, PCRE_INFO_DEFAULT_TABLES,
+ (void *)(&tables));
#endif
compile_block.lcc = tables + lcc_offset;
@@ -1408,19 +1430,20 @@ switch(min = find_minlength(code, code, re->options, 0))
}
/* If a set of starting bytes has been identified, or if the minimum length is
-greater than zero, or if JIT optimization has been requested, get a
-pcre[16]_extra block and a pcre_study_data block. The study data is put in the
-latter, which is pointed to by the former, which may also get additional data
-set later by the calling program. At the moment, the size of pcre_study_data
-is fixed. We nevertheless save it in a field for returning via the
-pcre_fullinfo() function so that if it becomes variable in the future,
-we don't have to change that code. */
-
-if (bits_set || min > 0
+greater than zero, or if JIT optimization has been requested, or if
+PCRE_STUDY_EXTRA_NEEDED is set, get a pcre[16]_extra block and a
+pcre_study_data block. The study data is put in the latter, which is pointed to
+by the former, which may also get additional data set later by the calling
+program. At the moment, the size of pcre_study_data is fixed. We nevertheless
+save it in a field for returning via the pcre_fullinfo() function so that if it
+becomes variable in the future, we don't have to change that code. */
+
+if (bits_set || min > 0 || (options & (
#ifdef SUPPORT_JIT
- || (options & PCRE_STUDY_JIT_COMPILE) != 0
+ PCRE_STUDY_JIT_COMPILE | PCRE_STUDY_JIT_PARTIAL_SOFT_COMPILE |
+ PCRE_STUDY_JIT_PARTIAL_HARD_COMPILE |
#endif
- )
+ PCRE_STUDY_EXTRA_NEEDED)) != 0)
{
extra = (PUBL(extra) *)(PUBL(malloc))
(sizeof(PUBL(extra)) + sizeof(pcre_study_data));
@@ -1474,18 +1497,27 @@ if (bits_set || min > 0
/* If JIT support was compiled and requested, attempt the JIT compilation.
If no starting bytes were found, and the minimum length is zero, and JIT
- compilation fails, abandon the extra block and return NULL. */
+ compilation fails, abandon the extra block and return NULL, unless
+ PCRE_STUDY_EXTRA_NEEDED is set. */
#ifdef SUPPORT_JIT
extra->executable_jit = NULL;
- if ((options & PCRE_STUDY_JIT_COMPILE) != 0) PRIV(jit_compile)(re, extra);
- if (study->flags == 0 && (extra->flags & PCRE_EXTRA_EXECUTABLE_JIT) == 0)
+ if ((options & PCRE_STUDY_JIT_COMPILE) != 0)
+ PRIV(jit_compile)(re, extra, JIT_COMPILE);
+ if ((options & PCRE_STUDY_JIT_PARTIAL_SOFT_COMPILE) != 0)
+ PRIV(jit_compile)(re, extra, JIT_PARTIAL_SOFT_COMPILE);
+ if ((options & PCRE_STUDY_JIT_PARTIAL_HARD_COMPILE) != 0)
+ PRIV(jit_compile)(re, extra, JIT_PARTIAL_HARD_COMPILE);
+
+ if (study->flags == 0 && (extra->flags & PCRE_EXTRA_EXECUTABLE_JIT) == 0 &&
+ (options & PCRE_STUDY_EXTRA_NEEDED) == 0)
{
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
pcre_free_study(extra);
-#endif
-#ifdef COMPILE_PCRE16
+#elif defined COMPILE_PCRE16
pcre16_free_study(extra);
+#elif defined COMPILE_PCRE32
+ pcre32_free_study(extra);
#endif
extra = NULL;
}
@@ -1506,12 +1538,15 @@ Argument: a pointer to the pcre[16]_extra block
Returns: nothing
*/
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN void
pcre_free_study(pcre_extra *extra)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN void
pcre16_free_study(pcre16_extra *extra)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN void
+pcre32_free_study(pcre32_extra *extra)
#endif
{
if (extra == NULL)
diff --git a/src/3rdparty/pcre/pcre_tables.c b/src/3rdparty/pcre/pcre_tables.c
index 9e449f8888..a50b87371c 100644
--- a/src/3rdparty/pcre/pcre_tables.c
+++ b/src/3rdparty/pcre/pcre_tables.c
@@ -58,6 +58,12 @@ the definition is next to the definition of the opcodes in pcre_internal.h. */
const pcre_uint8 PRIV(OP_lengths)[] = { OP_LENGTHS };
+/* Tables of horizontal and vertical whitespace characters, suitable for
+adding to classes. */
+
+const pcre_uint32 PRIV(hspace_list)[] = { HSPACE_LIST };
+const pcre_uint32 PRIV(vspace_list)[] = { VSPACE_LIST };
+
/*************************************************
@@ -68,9 +74,9 @@ const pcre_uint8 PRIV(OP_lengths)[] = { OP_LENGTHS };
character. */
#if (defined SUPPORT_UTF && defined COMPILE_PCRE8) \
- || (defined PCRE_INCLUDED && defined SUPPORT_PCRE16)
+ || (defined PCRE_INCLUDED && (defined SUPPORT_PCRE16 || defined SUPPORT_PCRE32))
-/* These tables are also required by pcretest in 16 bit mode. */
+/* These tables are also required by pcretest in 16- or 32-bit mode. */
const int PRIV(utf8_table1)[] =
{ 0x7f, 0x7ff, 0xffff, 0x1fffff, 0x3ffffff, 0x7fffffff};
@@ -92,13 +98,13 @@ const pcre_uint8 PRIV(utf8_table4)[] = {
2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,
3,3,3,3,3,3,3,3,4,4,4,4,5,5,5,5 };
-#endif /* (SUPPORT_UTF && COMPILE_PCRE8) || (PCRE_INCLUDED && SUPPORT_PCRE16)*/
+#endif /* (SUPPORT_UTF && COMPILE_PCRE8) || (PCRE_INCLUDED && SUPPORT_PCRE[16|32])*/
#ifdef SUPPORT_UTF
/* Table to translate from particular type value to the general value. */
-const int PRIV(ucp_gentype)[] = {
+const pcre_uint32 PRIV(ucp_gentype)[] = {
ucp_C, ucp_C, ucp_C, ucp_C, ucp_C, /* Cc, Cf, Cn, Co, Cs */
ucp_L, ucp_L, ucp_L, ucp_L, ucp_L, /* Ll, Lu, Lm, Lo, Lt */
ucp_M, ucp_M, ucp_M, /* Mc, Me, Mn */
@@ -109,6 +115,66 @@ const int PRIV(ucp_gentype)[] = {
ucp_Z, ucp_Z, ucp_Z /* Zl, Zp, Zs */
};
+/* This table encodes the rules for finding the end of an extended grapheme
+cluster. Every code point has a grapheme break property which is one of the
+ucp_gbXX values defined in ucp.h. The 2-dimensional table is indexed by the
+properties of two adjacent code points. The left property selects a word from
+the table, and the right property selects a bit from that word like this:
+
+ ucp_gbtable[left-property] & (1 << right-property)
+
+The value is non-zero if a grapheme break is NOT permitted between the relevant
+two code points. The breaking rules are as follows:
+
+1. Break at the start and end of text (pretty obviously).
+
+2. Do not break between a CR and LF; otherwise, break before and after
+ controls.
+
+3. Do not break Hangul syllable sequences, the rules for which are:
+
+ L may be followed by L, V, LV or LVT
+ LV or V may be followed by V or T
+ LVT or T may be followed by T
+
+4. Do not break before extending characters.
+
+The next two rules are only for extended grapheme clusters (but that's what we
+are implementing).
+
+5. Do not break before SpacingMarks.
+
+6. Do not break after Prepend characters.
+
+7. Otherwise, break everywhere.
+*/
+
+const pcre_uint32 PRIV(ucp_gbtable[]) = {
+ (1<<ucp_gbLF), /* 0 CR */
+ 0, /* 1 LF */
+ 0, /* 2 Control */
+ (1<<ucp_gbExtend)|(1<<ucp_gbSpacingMark), /* 3 Extend */
+ (1<<ucp_gbExtend)|(1<<ucp_gbPrepend)| /* 4 Prepend */
+ (1<<ucp_gbSpacingMark)|(1<<ucp_gbL)|
+ (1<<ucp_gbV)|(1<<ucp_gbT)|(1<<ucp_gbLV)|
+ (1<<ucp_gbLVT)|(1<<ucp_gbOther),
+
+ (1<<ucp_gbExtend)|(1<<ucp_gbSpacingMark), /* 5 SpacingMark */
+ (1<<ucp_gbExtend)|(1<<ucp_gbSpacingMark)|(1<<ucp_gbL)| /* 6 L */
+ (1<<ucp_gbL)|(1<<ucp_gbV)|(1<<ucp_gbLV)|(1<<ucp_gbLVT),
+
+ (1<<ucp_gbExtend)|(1<<ucp_gbSpacingMark)|(1<<ucp_gbV)| /* 7 V */
+ (1<<ucp_gbT),
+
+ (1<<ucp_gbExtend)|(1<<ucp_gbSpacingMark)|(1<<ucp_gbT), /* 8 T */
+ (1<<ucp_gbExtend)|(1<<ucp_gbSpacingMark)|(1<<ucp_gbV)| /* 9 LV */
+ (1<<ucp_gbT),
+
+ (1<<ucp_gbExtend)|(1<<ucp_gbSpacingMark)|(1<<ucp_gbT), /* 10 LVT */
+ (1<<ucp_gbRegionalIndicator), /* 11 RegionalIndicator */
+ (1<<ucp_gbExtend)|(1<<ucp_gbSpacingMark) /* 12 Other */
+};
+
#ifdef SUPPORT_JIT
/* This table reverses PRIV(ucp_gentype). We can save the cost
of a memory load. */
@@ -159,6 +225,7 @@ strings to make sure that UTF-8 support works on EBCDIC platforms. */
#define STRING_Carian0 STR_C STR_a STR_r STR_i STR_a STR_n "\0"
#define STRING_Cc0 STR_C STR_c "\0"
#define STRING_Cf0 STR_C STR_f "\0"
+#define STRING_Chakma0 STR_C STR_h STR_a STR_k STR_m STR_a "\0"
#define STRING_Cham0 STR_C STR_h STR_a STR_m "\0"
#define STRING_Cherokee0 STR_C STR_h STR_e STR_r STR_o STR_k STR_e STR_e "\0"
#define STRING_Cn0 STR_C STR_n "\0"
@@ -216,6 +283,9 @@ strings to make sure that UTF-8 support works on EBCDIC platforms. */
#define STRING_Mc0 STR_M STR_c "\0"
#define STRING_Me0 STR_M STR_e "\0"
#define STRING_Meetei_Mayek0 STR_M STR_e STR_e STR_t STR_e STR_i STR_UNDERSCORE STR_M STR_a STR_y STR_e STR_k "\0"
+#define STRING_Meroitic_Cursive0 STR_M STR_e STR_r STR_o STR_i STR_t STR_i STR_c STR_UNDERSCORE STR_C STR_u STR_r STR_s STR_i STR_v STR_e "\0"
+#define STRING_Meroitic_Hieroglyphs0 STR_M STR_e STR_r STR_o STR_i STR_t STR_i STR_c STR_UNDERSCORE STR_H STR_i STR_e STR_r STR_o STR_g STR_l STR_y STR_p STR_h STR_s "\0"
+#define STRING_Miao0 STR_M STR_i STR_a STR_o "\0"
#define STRING_Mn0 STR_M STR_n "\0"
#define STRING_Mongolian0 STR_M STR_o STR_n STR_g STR_o STR_l STR_i STR_a STR_n "\0"
#define STRING_Myanmar0 STR_M STR_y STR_a STR_n STR_m STR_a STR_r "\0"
@@ -249,11 +319,13 @@ strings to make sure that UTF-8 support works on EBCDIC platforms. */
#define STRING_Samaritan0 STR_S STR_a STR_m STR_a STR_r STR_i STR_t STR_a STR_n "\0"
#define STRING_Saurashtra0 STR_S STR_a STR_u STR_r STR_a STR_s STR_h STR_t STR_r STR_a "\0"
#define STRING_Sc0 STR_S STR_c "\0"
+#define STRING_Sharada0 STR_S STR_h STR_a STR_r STR_a STR_d STR_a "\0"
#define STRING_Shavian0 STR_S STR_h STR_a STR_v STR_i STR_a STR_n "\0"
#define STRING_Sinhala0 STR_S STR_i STR_n STR_h STR_a STR_l STR_a "\0"
#define STRING_Sk0 STR_S STR_k "\0"
#define STRING_Sm0 STR_S STR_m "\0"
#define STRING_So0 STR_S STR_o "\0"
+#define STRING_Sora_Sompeng0 STR_S STR_o STR_r STR_a STR_UNDERSCORE STR_S STR_o STR_m STR_p STR_e STR_n STR_g "\0"
#define STRING_Sundanese0 STR_S STR_u STR_n STR_d STR_a STR_n STR_e STR_s STR_e "\0"
#define STRING_Syloti_Nagri0 STR_S STR_y STR_l STR_o STR_t STR_i STR_UNDERSCORE STR_N STR_a STR_g STR_r STR_i "\0"
#define STRING_Syriac0 STR_S STR_y STR_r STR_i STR_a STR_c "\0"
@@ -262,6 +334,7 @@ strings to make sure that UTF-8 support works on EBCDIC platforms. */
#define STRING_Tai_Le0 STR_T STR_a STR_i STR_UNDERSCORE STR_L STR_e "\0"
#define STRING_Tai_Tham0 STR_T STR_a STR_i STR_UNDERSCORE STR_T STR_h STR_a STR_m "\0"
#define STRING_Tai_Viet0 STR_T STR_a STR_i STR_UNDERSCORE STR_V STR_i STR_e STR_t "\0"
+#define STRING_Takri0 STR_T STR_a STR_k STR_r STR_i "\0"
#define STRING_Tamil0 STR_T STR_a STR_m STR_i STR_l "\0"
#define STRING_Telugu0 STR_T STR_e STR_l STR_u STR_g STR_u "\0"
#define STRING_Thaana0 STR_T STR_h STR_a STR_a STR_n STR_a "\0"
@@ -299,6 +372,7 @@ const char PRIV(utt_names)[] =
STRING_Carian0
STRING_Cc0
STRING_Cf0
+ STRING_Chakma0
STRING_Cham0
STRING_Cherokee0
STRING_Cn0
@@ -356,6 +430,9 @@ const char PRIV(utt_names)[] =
STRING_Mc0
STRING_Me0
STRING_Meetei_Mayek0
+ STRING_Meroitic_Cursive0
+ STRING_Meroitic_Hieroglyphs0
+ STRING_Miao0
STRING_Mn0
STRING_Mongolian0
STRING_Myanmar0
@@ -389,11 +466,13 @@ const char PRIV(utt_names)[] =
STRING_Samaritan0
STRING_Saurashtra0
STRING_Sc0
+ STRING_Sharada0
STRING_Shavian0
STRING_Sinhala0
STRING_Sk0
STRING_Sm0
STRING_So0
+ STRING_Sora_Sompeng0
STRING_Sundanese0
STRING_Syloti_Nagri0
STRING_Syriac0
@@ -402,6 +481,7 @@ const char PRIV(utt_names)[] =
STRING_Tai_Le0
STRING_Tai_Tham0
STRING_Tai_Viet0
+ STRING_Takri0
STRING_Tamil0
STRING_Telugu0
STRING_Thaana0
@@ -439,126 +519,133 @@ const ucp_type_table PRIV(utt)[] = {
{ 118, PT_SC, ucp_Carian },
{ 125, PT_PC, ucp_Cc },
{ 128, PT_PC, ucp_Cf },
- { 131, PT_SC, ucp_Cham },
- { 136, PT_SC, ucp_Cherokee },
- { 145, PT_PC, ucp_Cn },
- { 148, PT_PC, ucp_Co },
- { 151, PT_SC, ucp_Common },
- { 158, PT_SC, ucp_Coptic },
- { 165, PT_PC, ucp_Cs },
- { 168, PT_SC, ucp_Cuneiform },
- { 178, PT_SC, ucp_Cypriot },
- { 186, PT_SC, ucp_Cyrillic },
- { 195, PT_SC, ucp_Deseret },
- { 203, PT_SC, ucp_Devanagari },
- { 214, PT_SC, ucp_Egyptian_Hieroglyphs },
- { 235, PT_SC, ucp_Ethiopic },
- { 244, PT_SC, ucp_Georgian },
- { 253, PT_SC, ucp_Glagolitic },
- { 264, PT_SC, ucp_Gothic },
- { 271, PT_SC, ucp_Greek },
- { 277, PT_SC, ucp_Gujarati },
- { 286, PT_SC, ucp_Gurmukhi },
- { 295, PT_SC, ucp_Han },
- { 299, PT_SC, ucp_Hangul },
- { 306, PT_SC, ucp_Hanunoo },
- { 314, PT_SC, ucp_Hebrew },
- { 321, PT_SC, ucp_Hiragana },
- { 330, PT_SC, ucp_Imperial_Aramaic },
- { 347, PT_SC, ucp_Inherited },
- { 357, PT_SC, ucp_Inscriptional_Pahlavi },
- { 379, PT_SC, ucp_Inscriptional_Parthian },
- { 402, PT_SC, ucp_Javanese },
- { 411, PT_SC, ucp_Kaithi },
- { 418, PT_SC, ucp_Kannada },
- { 426, PT_SC, ucp_Katakana },
- { 435, PT_SC, ucp_Kayah_Li },
- { 444, PT_SC, ucp_Kharoshthi },
- { 455, PT_SC, ucp_Khmer },
- { 461, PT_GC, ucp_L },
- { 463, PT_LAMP, 0 },
- { 466, PT_SC, ucp_Lao },
- { 470, PT_SC, ucp_Latin },
- { 476, PT_SC, ucp_Lepcha },
- { 483, PT_SC, ucp_Limbu },
- { 489, PT_SC, ucp_Linear_B },
- { 498, PT_SC, ucp_Lisu },
- { 503, PT_PC, ucp_Ll },
- { 506, PT_PC, ucp_Lm },
- { 509, PT_PC, ucp_Lo },
- { 512, PT_PC, ucp_Lt },
- { 515, PT_PC, ucp_Lu },
- { 518, PT_SC, ucp_Lycian },
- { 525, PT_SC, ucp_Lydian },
- { 532, PT_GC, ucp_M },
- { 534, PT_SC, ucp_Malayalam },
- { 544, PT_SC, ucp_Mandaic },
- { 552, PT_PC, ucp_Mc },
- { 555, PT_PC, ucp_Me },
- { 558, PT_SC, ucp_Meetei_Mayek },
- { 571, PT_PC, ucp_Mn },
- { 574, PT_SC, ucp_Mongolian },
- { 584, PT_SC, ucp_Myanmar },
- { 592, PT_GC, ucp_N },
- { 594, PT_PC, ucp_Nd },
- { 597, PT_SC, ucp_New_Tai_Lue },
- { 609, PT_SC, ucp_Nko },
- { 613, PT_PC, ucp_Nl },
- { 616, PT_PC, ucp_No },
- { 619, PT_SC, ucp_Ogham },
- { 625, PT_SC, ucp_Ol_Chiki },
- { 634, PT_SC, ucp_Old_Italic },
- { 645, PT_SC, ucp_Old_Persian },
- { 657, PT_SC, ucp_Old_South_Arabian },
- { 675, PT_SC, ucp_Old_Turkic },
- { 686, PT_SC, ucp_Oriya },
- { 692, PT_SC, ucp_Osmanya },
- { 700, PT_GC, ucp_P },
- { 702, PT_PC, ucp_Pc },
- { 705, PT_PC, ucp_Pd },
- { 708, PT_PC, ucp_Pe },
- { 711, PT_PC, ucp_Pf },
- { 714, PT_SC, ucp_Phags_Pa },
- { 723, PT_SC, ucp_Phoenician },
- { 734, PT_PC, ucp_Pi },
- { 737, PT_PC, ucp_Po },
- { 740, PT_PC, ucp_Ps },
- { 743, PT_SC, ucp_Rejang },
- { 750, PT_SC, ucp_Runic },
- { 756, PT_GC, ucp_S },
- { 758, PT_SC, ucp_Samaritan },
- { 768, PT_SC, ucp_Saurashtra },
- { 779, PT_PC, ucp_Sc },
- { 782, PT_SC, ucp_Shavian },
- { 790, PT_SC, ucp_Sinhala },
- { 798, PT_PC, ucp_Sk },
- { 801, PT_PC, ucp_Sm },
- { 804, PT_PC, ucp_So },
- { 807, PT_SC, ucp_Sundanese },
- { 817, PT_SC, ucp_Syloti_Nagri },
- { 830, PT_SC, ucp_Syriac },
- { 837, PT_SC, ucp_Tagalog },
- { 845, PT_SC, ucp_Tagbanwa },
- { 854, PT_SC, ucp_Tai_Le },
- { 861, PT_SC, ucp_Tai_Tham },
- { 870, PT_SC, ucp_Tai_Viet },
- { 879, PT_SC, ucp_Tamil },
- { 885, PT_SC, ucp_Telugu },
- { 892, PT_SC, ucp_Thaana },
- { 899, PT_SC, ucp_Thai },
- { 904, PT_SC, ucp_Tibetan },
- { 912, PT_SC, ucp_Tifinagh },
- { 921, PT_SC, ucp_Ugaritic },
- { 930, PT_SC, ucp_Vai },
- { 934, PT_ALNUM, 0 },
- { 938, PT_PXSPACE, 0 },
- { 942, PT_SPACE, 0 },
- { 946, PT_WORD, 0 },
- { 950, PT_SC, ucp_Yi },
- { 953, PT_GC, ucp_Z },
- { 955, PT_PC, ucp_Zl },
- { 958, PT_PC, ucp_Zp },
- { 961, PT_PC, ucp_Zs }
+ { 131, PT_SC, ucp_Chakma },
+ { 138, PT_SC, ucp_Cham },
+ { 143, PT_SC, ucp_Cherokee },
+ { 152, PT_PC, ucp_Cn },
+ { 155, PT_PC, ucp_Co },
+ { 158, PT_SC, ucp_Common },
+ { 165, PT_SC, ucp_Coptic },
+ { 172, PT_PC, ucp_Cs },
+ { 175, PT_SC, ucp_Cuneiform },
+ { 185, PT_SC, ucp_Cypriot },
+ { 193, PT_SC, ucp_Cyrillic },
+ { 202, PT_SC, ucp_Deseret },
+ { 210, PT_SC, ucp_Devanagari },
+ { 221, PT_SC, ucp_Egyptian_Hieroglyphs },
+ { 242, PT_SC, ucp_Ethiopic },
+ { 251, PT_SC, ucp_Georgian },
+ { 260, PT_SC, ucp_Glagolitic },
+ { 271, PT_SC, ucp_Gothic },
+ { 278, PT_SC, ucp_Greek },
+ { 284, PT_SC, ucp_Gujarati },
+ { 293, PT_SC, ucp_Gurmukhi },
+ { 302, PT_SC, ucp_Han },
+ { 306, PT_SC, ucp_Hangul },
+ { 313, PT_SC, ucp_Hanunoo },
+ { 321, PT_SC, ucp_Hebrew },
+ { 328, PT_SC, ucp_Hiragana },
+ { 337, PT_SC, ucp_Imperial_Aramaic },
+ { 354, PT_SC, ucp_Inherited },
+ { 364, PT_SC, ucp_Inscriptional_Pahlavi },
+ { 386, PT_SC, ucp_Inscriptional_Parthian },
+ { 409, PT_SC, ucp_Javanese },
+ { 418, PT_SC, ucp_Kaithi },
+ { 425, PT_SC, ucp_Kannada },
+ { 433, PT_SC, ucp_Katakana },
+ { 442, PT_SC, ucp_Kayah_Li },
+ { 451, PT_SC, ucp_Kharoshthi },
+ { 462, PT_SC, ucp_Khmer },
+ { 468, PT_GC, ucp_L },
+ { 470, PT_LAMP, 0 },
+ { 473, PT_SC, ucp_Lao },
+ { 477, PT_SC, ucp_Latin },
+ { 483, PT_SC, ucp_Lepcha },
+ { 490, PT_SC, ucp_Limbu },
+ { 496, PT_SC, ucp_Linear_B },
+ { 505, PT_SC, ucp_Lisu },
+ { 510, PT_PC, ucp_Ll },
+ { 513, PT_PC, ucp_Lm },
+ { 516, PT_PC, ucp_Lo },
+ { 519, PT_PC, ucp_Lt },
+ { 522, PT_PC, ucp_Lu },
+ { 525, PT_SC, ucp_Lycian },
+ { 532, PT_SC, ucp_Lydian },
+ { 539, PT_GC, ucp_M },
+ { 541, PT_SC, ucp_Malayalam },
+ { 551, PT_SC, ucp_Mandaic },
+ { 559, PT_PC, ucp_Mc },
+ { 562, PT_PC, ucp_Me },
+ { 565, PT_SC, ucp_Meetei_Mayek },
+ { 578, PT_SC, ucp_Meroitic_Cursive },
+ { 595, PT_SC, ucp_Meroitic_Hieroglyphs },
+ { 616, PT_SC, ucp_Miao },
+ { 621, PT_PC, ucp_Mn },
+ { 624, PT_SC, ucp_Mongolian },
+ { 634, PT_SC, ucp_Myanmar },
+ { 642, PT_GC, ucp_N },
+ { 644, PT_PC, ucp_Nd },
+ { 647, PT_SC, ucp_New_Tai_Lue },
+ { 659, PT_SC, ucp_Nko },
+ { 663, PT_PC, ucp_Nl },
+ { 666, PT_PC, ucp_No },
+ { 669, PT_SC, ucp_Ogham },
+ { 675, PT_SC, ucp_Ol_Chiki },
+ { 684, PT_SC, ucp_Old_Italic },
+ { 695, PT_SC, ucp_Old_Persian },
+ { 707, PT_SC, ucp_Old_South_Arabian },
+ { 725, PT_SC, ucp_Old_Turkic },
+ { 736, PT_SC, ucp_Oriya },
+ { 742, PT_SC, ucp_Osmanya },
+ { 750, PT_GC, ucp_P },
+ { 752, PT_PC, ucp_Pc },
+ { 755, PT_PC, ucp_Pd },
+ { 758, PT_PC, ucp_Pe },
+ { 761, PT_PC, ucp_Pf },
+ { 764, PT_SC, ucp_Phags_Pa },
+ { 773, PT_SC, ucp_Phoenician },
+ { 784, PT_PC, ucp_Pi },
+ { 787, PT_PC, ucp_Po },
+ { 790, PT_PC, ucp_Ps },
+ { 793, PT_SC, ucp_Rejang },
+ { 800, PT_SC, ucp_Runic },
+ { 806, PT_GC, ucp_S },
+ { 808, PT_SC, ucp_Samaritan },
+ { 818, PT_SC, ucp_Saurashtra },
+ { 829, PT_PC, ucp_Sc },
+ { 832, PT_SC, ucp_Sharada },
+ { 840, PT_SC, ucp_Shavian },
+ { 848, PT_SC, ucp_Sinhala },
+ { 856, PT_PC, ucp_Sk },
+ { 859, PT_PC, ucp_Sm },
+ { 862, PT_PC, ucp_So },
+ { 865, PT_SC, ucp_Sora_Sompeng },
+ { 878, PT_SC, ucp_Sundanese },
+ { 888, PT_SC, ucp_Syloti_Nagri },
+ { 901, PT_SC, ucp_Syriac },
+ { 908, PT_SC, ucp_Tagalog },
+ { 916, PT_SC, ucp_Tagbanwa },
+ { 925, PT_SC, ucp_Tai_Le },
+ { 932, PT_SC, ucp_Tai_Tham },
+ { 941, PT_SC, ucp_Tai_Viet },
+ { 950, PT_SC, ucp_Takri },
+ { 956, PT_SC, ucp_Tamil },
+ { 962, PT_SC, ucp_Telugu },
+ { 969, PT_SC, ucp_Thaana },
+ { 976, PT_SC, ucp_Thai },
+ { 981, PT_SC, ucp_Tibetan },
+ { 989, PT_SC, ucp_Tifinagh },
+ { 998, PT_SC, ucp_Ugaritic },
+ { 1007, PT_SC, ucp_Vai },
+ { 1011, PT_ALNUM, 0 },
+ { 1015, PT_PXSPACE, 0 },
+ { 1019, PT_SPACE, 0 },
+ { 1023, PT_WORD, 0 },
+ { 1027, PT_SC, ucp_Yi },
+ { 1030, PT_GC, ucp_Z },
+ { 1032, PT_PC, ucp_Zl },
+ { 1035, PT_PC, ucp_Zp },
+ { 1038, PT_PC, ucp_Zs }
};
const int PRIV(utt_size) = sizeof(PRIV(utt)) / sizeof(ucp_type_table);
diff --git a/src/3rdparty/pcre/pcre_ucd.c b/src/3rdparty/pcre/pcre_ucd.c
index 48fa486635..003f04d3d7 100644
--- a/src/3rdparty/pcre/pcre_ucd.c
+++ b/src/3rdparty/pcre/pcre_ucd.c
@@ -1,2977 +1,3292 @@
+/* This module is generated by the maint/MultiStage2.py script.
+Do not modify it by hand. Instead modify the script and run it
+to regenerate this code.
+
+As well as being part of the PCRE library, this module is #included
+by the pcretest program, which redefines the PRIV macro to change
+table names from _pcre_xxx to xxxx, thereby avoiding name clashes
+with the library. At present, just one of these tables is actually
+needed. */
+
+#ifndef PCRE_INCLUDED
+
#ifdef PCRE_HAVE_CONFIG_H
#include "config.h"
#endif
#include "pcre_internal.h"
+#endif /* PCRE_INCLUDED */
+
/* Unicode character database. */
/* This file was autogenerated by the MultiStage2.py script. */
-/* Total size: 60384 bytes, block size: 128. */
+/* Total size: 65696 bytes, block size: 128. */
-/* The tables herein are needed only when UCP support is built */
-/* into PCRE. This module should not be referenced otherwise, so */
-/* it should not matter whether it is compiled or not. However */
-/* a comment was received about space saving - maybe the guy linked */
-/* all the modules rather than using a library - so we include a */
-/* condition to cut out the tables when not needed. But don't leave */
-/* a totally empty module because some compilers barf at that. */
-/* Instead, just supply small dummy tables. */
+/* The tables herein are needed only when UCP support is built
+into PCRE. This module should not be referenced otherwise, so
+it should not matter whether it is compiled or not. However
+a comment was received about space saving - maybe the guy linked
+all the modules rather than using a library - so we include a
+condition to cut out the tables when not needed. But don't leave
+a totally empty module because some compilers barf at that.
+Instead, just supply small dummy tables. */
#ifndef SUPPORT_UCP
-const ucd_record PRIV(ucd_records)[] = {{0,0,0 }};
+const ucd_record PRIV(ucd_records)[] = {{0,0,0,0,0 }};
const pcre_uint8 PRIV(ucd_stage1)[] = {0};
const pcre_uint16 PRIV(ucd_stage2)[] = {0};
+const pcre_uint32 PRIV(ucd_caseless_sets)[] = {0};
#else
-/* When recompiling tables with a new Unicode version,
-please check types in the structure definition from pcre_internal.h:
+/* When recompiling tables with a new Unicode version, please check the
+types in this structure definition from pcre_internal.h (the actual
+field names will be different):
+
typedef struct {
pcre_uint8 property_0;
pcre_uint8 property_1;
-pcre_int32 property_2;
-} ucd_record; */
-
-
-const ucd_record PRIV(ucd_records)[] = { /* 4320 bytes, record size 8 */
- { 9, 0, 0, }, /* 0 */
- { 9, 29, 0, }, /* 1 */
- { 9, 21, 0, }, /* 2 */
- { 9, 23, 0, }, /* 3 */
- { 9, 22, 0, }, /* 4 */
- { 9, 18, 0, }, /* 5 */
- { 9, 25, 0, }, /* 6 */
- { 9, 17, 0, }, /* 7 */
- { 9, 13, 0, }, /* 8 */
- { 33, 9, 32, }, /* 9 */
- { 9, 24, 0, }, /* 10 */
- { 9, 16, 0, }, /* 11 */
- { 33, 5, -32, }, /* 12 */
- { 9, 26, 0, }, /* 13 */
- { 33, 5, 0, }, /* 14 */
- { 9, 20, 0, }, /* 15 */
- { 9, 1, 0, }, /* 16 */
- { 9, 15, 0, }, /* 17 */
- { 9, 5, 743, }, /* 18 */
- { 9, 19, 0, }, /* 19 */
- { 33, 5, 121, }, /* 20 */
- { 33, 9, 1, }, /* 21 */
- { 33, 5, -1, }, /* 22 */
- { 33, 9, -199, }, /* 23 */
- { 33, 5, -232, }, /* 24 */
- { 33, 9, -121, }, /* 25 */
- { 33, 5, -300, }, /* 26 */
- { 33, 5, 195, }, /* 27 */
- { 33, 9, 210, }, /* 28 */
- { 33, 9, 206, }, /* 29 */
- { 33, 9, 205, }, /* 30 */
- { 33, 9, 79, }, /* 31 */
- { 33, 9, 202, }, /* 32 */
- { 33, 9, 203, }, /* 33 */
- { 33, 9, 207, }, /* 34 */
- { 33, 5, 97, }, /* 35 */
- { 33, 9, 211, }, /* 36 */
- { 33, 9, 209, }, /* 37 */
- { 33, 5, 163, }, /* 38 */
- { 33, 9, 213, }, /* 39 */
- { 33, 5, 130, }, /* 40 */
- { 33, 9, 214, }, /* 41 */
- { 33, 9, 218, }, /* 42 */
- { 33, 9, 217, }, /* 43 */
- { 33, 9, 219, }, /* 44 */
- { 33, 7, 0, }, /* 45 */
- { 33, 5, 56, }, /* 46 */
- { 33, 9, 2, }, /* 47 */
- { 33, 8, -1, }, /* 48 */
- { 33, 5, -2, }, /* 49 */
- { 33, 5, -79, }, /* 50 */
- { 33, 9, -97, }, /* 51 */
- { 33, 9, -56, }, /* 52 */
- { 33, 9, -130, }, /* 53 */
- { 33, 9, 10795, }, /* 54 */
- { 33, 9, -163, }, /* 55 */
- { 33, 9, 10792, }, /* 56 */
- { 33, 5, 10815, }, /* 57 */
- { 33, 9, -195, }, /* 58 */
- { 33, 9, 69, }, /* 59 */
- { 33, 9, 71, }, /* 60 */
- { 33, 5, 10783, }, /* 61 */
- { 33, 5, 10780, }, /* 62 */
- { 33, 5, 10782, }, /* 63 */
- { 33, 5, -210, }, /* 64 */
- { 33, 5, -206, }, /* 65 */
- { 33, 5, -205, }, /* 66 */
- { 33, 5, -202, }, /* 67 */
- { 33, 5, -203, }, /* 68 */
- { 33, 5, -207, }, /* 69 */
- { 33, 5, 42280, }, /* 70 */
- { 33, 5, -209, }, /* 71 */
- { 33, 5, -211, }, /* 72 */
- { 33, 5, 10743, }, /* 73 */
- { 33, 5, 10749, }, /* 74 */
- { 33, 5, -213, }, /* 75 */
- { 33, 5, -214, }, /* 76 */
- { 33, 5, 10727, }, /* 77 */
- { 33, 5, -218, }, /* 78 */
- { 33, 5, -69, }, /* 79 */
- { 33, 5, -217, }, /* 80 */
- { 33, 5, -71, }, /* 81 */
- { 33, 5, -219, }, /* 82 */
- { 33, 6, 0, }, /* 83 */
- { 9, 6, 0, }, /* 84 */
- { 3, 24, 0, }, /* 85 */
- { 27, 12, 0, }, /* 86 */
- { 27, 12, 84, }, /* 87 */
- { 19, 9, 1, }, /* 88 */
- { 19, 5, -1, }, /* 89 */
- { 19, 24, 0, }, /* 90 */
- { 9, 2, 0, }, /* 91 */
- { 19, 6, 0, }, /* 92 */
- { 19, 5, 130, }, /* 93 */
- { 19, 9, 38, }, /* 94 */
- { 19, 9, 37, }, /* 95 */
- { 19, 9, 64, }, /* 96 */
- { 19, 9, 63, }, /* 97 */
- { 19, 5, 0, }, /* 98 */
- { 19, 9, 32, }, /* 99 */
- { 19, 5, -38, }, /* 100 */
- { 19, 5, -37, }, /* 101 */
- { 19, 5, -32, }, /* 102 */
- { 19, 5, -31, }, /* 103 */
- { 19, 5, -64, }, /* 104 */
- { 19, 5, -63, }, /* 105 */
- { 19, 9, 8, }, /* 106 */
- { 19, 5, -62, }, /* 107 */
- { 19, 5, -57, }, /* 108 */
- { 19, 9, 0, }, /* 109 */
- { 19, 5, -47, }, /* 110 */
- { 19, 5, -54, }, /* 111 */
- { 19, 5, -8, }, /* 112 */
- { 10, 9, 1, }, /* 113 */
- { 10, 5, -1, }, /* 114 */
- { 19, 5, -86, }, /* 115 */
- { 19, 5, -80, }, /* 116 */
- { 19, 5, 7, }, /* 117 */
- { 19, 9, -60, }, /* 118 */
- { 19, 5, -96, }, /* 119 */
- { 19, 25, 0, }, /* 120 */
- { 19, 9, -7, }, /* 121 */
- { 19, 9, -130, }, /* 122 */
- { 12, 9, 80, }, /* 123 */
- { 12, 9, 32, }, /* 124 */
- { 12, 5, -32, }, /* 125 */
- { 12, 5, -80, }, /* 126 */
- { 12, 9, 1, }, /* 127 */
- { 12, 5, -1, }, /* 128 */
- { 12, 26, 0, }, /* 129 */
- { 12, 12, 0, }, /* 130 */
- { 12, 11, 0, }, /* 131 */
- { 12, 9, 15, }, /* 132 */
- { 12, 5, -15, }, /* 133 */
- { 1, 9, 48, }, /* 134 */
- { 1, 6, 0, }, /* 135 */
- { 1, 21, 0, }, /* 136 */
- { 1, 5, -48, }, /* 137 */
- { 1, 5, 0, }, /* 138 */
- { 1, 17, 0, }, /* 139 */
- { 25, 12, 0, }, /* 140 */
- { 25, 17, 0, }, /* 141 */
- { 25, 21, 0, }, /* 142 */
- { 25, 7, 0, }, /* 143 */
- { 0, 1, 0, }, /* 144 */
- { 0, 25, 0, }, /* 145 */
- { 0, 21, 0, }, /* 146 */
- { 0, 23, 0, }, /* 147 */
- { 0, 26, 0, }, /* 148 */
- { 0, 12, 0, }, /* 149 */
- { 0, 7, 0, }, /* 150 */
- { 0, 6, 0, }, /* 151 */
- { 0, 13, 0, }, /* 152 */
- { 49, 21, 0, }, /* 153 */
- { 49, 1, 0, }, /* 154 */
- { 49, 7, 0, }, /* 155 */
- { 49, 12, 0, }, /* 156 */
- { 55, 7, 0, }, /* 157 */
- { 55, 12, 0, }, /* 158 */
- { 63, 13, 0, }, /* 159 */
- { 63, 7, 0, }, /* 160 */
- { 63, 12, 0, }, /* 161 */
- { 63, 6, 0, }, /* 162 */
- { 63, 26, 0, }, /* 163 */
- { 63, 21, 0, }, /* 164 */
- { 89, 7, 0, }, /* 165 */
- { 89, 12, 0, }, /* 166 */
- { 89, 6, 0, }, /* 167 */
- { 89, 21, 0, }, /* 168 */
- { 94, 7, 0, }, /* 169 */
- { 94, 12, 0, }, /* 170 */
- { 94, 21, 0, }, /* 171 */
- { 14, 12, 0, }, /* 172 */
- { 14, 10, 0, }, /* 173 */
- { 14, 7, 0, }, /* 174 */
- { 14, 13, 0, }, /* 175 */
- { 14, 6, 0, }, /* 176 */
- { 2, 12, 0, }, /* 177 */
- { 2, 10, 0, }, /* 178 */
- { 2, 7, 0, }, /* 179 */
- { 2, 13, 0, }, /* 180 */
- { 2, 23, 0, }, /* 181 */
- { 2, 15, 0, }, /* 182 */
- { 2, 26, 0, }, /* 183 */
- { 21, 12, 0, }, /* 184 */
- { 21, 10, 0, }, /* 185 */
- { 21, 7, 0, }, /* 186 */
- { 21, 13, 0, }, /* 187 */
- { 20, 12, 0, }, /* 188 */
- { 20, 10, 0, }, /* 189 */
- { 20, 7, 0, }, /* 190 */
- { 20, 13, 0, }, /* 191 */
- { 20, 23, 0, }, /* 192 */
- { 43, 12, 0, }, /* 193 */
- { 43, 10, 0, }, /* 194 */
- { 43, 7, 0, }, /* 195 */
- { 43, 13, 0, }, /* 196 */
- { 43, 26, 0, }, /* 197 */
- { 43, 15, 0, }, /* 198 */
- { 53, 12, 0, }, /* 199 */
- { 53, 7, 0, }, /* 200 */
- { 53, 10, 0, }, /* 201 */
- { 53, 13, 0, }, /* 202 */
- { 53, 15, 0, }, /* 203 */
- { 53, 26, 0, }, /* 204 */
- { 53, 23, 0, }, /* 205 */
- { 54, 10, 0, }, /* 206 */
- { 54, 7, 0, }, /* 207 */
- { 54, 12, 0, }, /* 208 */
- { 54, 13, 0, }, /* 209 */
- { 54, 15, 0, }, /* 210 */
- { 54, 26, 0, }, /* 211 */
- { 28, 10, 0, }, /* 212 */
- { 28, 7, 0, }, /* 213 */
- { 28, 12, 0, }, /* 214 */
- { 28, 13, 0, }, /* 215 */
- { 36, 10, 0, }, /* 216 */
- { 36, 7, 0, }, /* 217 */
- { 36, 12, 0, }, /* 218 */
- { 36, 13, 0, }, /* 219 */
- { 36, 15, 0, }, /* 220 */
- { 36, 26, 0, }, /* 221 */
- { 47, 10, 0, }, /* 222 */
- { 47, 7, 0, }, /* 223 */
- { 47, 12, 0, }, /* 224 */
- { 47, 21, 0, }, /* 225 */
- { 56, 7, 0, }, /* 226 */
- { 56, 12, 0, }, /* 227 */
- { 56, 6, 0, }, /* 228 */
- { 56, 21, 0, }, /* 229 */
- { 56, 13, 0, }, /* 230 */
- { 32, 7, 0, }, /* 231 */
- { 32, 12, 0, }, /* 232 */
- { 32, 6, 0, }, /* 233 */
- { 32, 13, 0, }, /* 234 */
- { 57, 7, 0, }, /* 235 */
- { 57, 26, 0, }, /* 236 */
- { 57, 21, 0, }, /* 237 */
- { 57, 12, 0, }, /* 238 */
- { 57, 13, 0, }, /* 239 */
- { 57, 15, 0, }, /* 240 */
- { 57, 22, 0, }, /* 241 */
- { 57, 18, 0, }, /* 242 */
- { 57, 10, 0, }, /* 243 */
- { 38, 7, 0, }, /* 244 */
- { 38, 10, 0, }, /* 245 */
- { 38, 12, 0, }, /* 246 */
- { 38, 13, 0, }, /* 247 */
- { 38, 21, 0, }, /* 248 */
- { 38, 26, 0, }, /* 249 */
- { 16, 9, 7264, }, /* 250 */
- { 16, 7, 0, }, /* 251 */
- { 16, 6, 0, }, /* 252 */
- { 23, 7, 0, }, /* 253 */
- { 15, 7, 0, }, /* 254 */
- { 15, 12, 0, }, /* 255 */
- { 15, 26, 0, }, /* 256 */
- { 15, 21, 0, }, /* 257 */
- { 15, 15, 0, }, /* 258 */
- { 8, 7, 0, }, /* 259 */
- { 7, 17, 0, }, /* 260 */
- { 7, 7, 0, }, /* 261 */
- { 7, 21, 0, }, /* 262 */
- { 40, 29, 0, }, /* 263 */
- { 40, 7, 0, }, /* 264 */
- { 40, 22, 0, }, /* 265 */
- { 40, 18, 0, }, /* 266 */
- { 45, 7, 0, }, /* 267 */
- { 45, 14, 0, }, /* 268 */
- { 50, 7, 0, }, /* 269 */
- { 50, 12, 0, }, /* 270 */
- { 24, 7, 0, }, /* 271 */
- { 24, 12, 0, }, /* 272 */
- { 6, 7, 0, }, /* 273 */
- { 6, 12, 0, }, /* 274 */
- { 51, 7, 0, }, /* 275 */
- { 51, 12, 0, }, /* 276 */
- { 31, 7, 0, }, /* 277 */
- { 31, 1, 0, }, /* 278 */
- { 31, 10, 0, }, /* 279 */
- { 31, 12, 0, }, /* 280 */
- { 31, 21, 0, }, /* 281 */
- { 31, 6, 0, }, /* 282 */
- { 31, 23, 0, }, /* 283 */
- { 31, 13, 0, }, /* 284 */
- { 31, 15, 0, }, /* 285 */
- { 37, 21, 0, }, /* 286 */
- { 37, 17, 0, }, /* 287 */
- { 37, 12, 0, }, /* 288 */
- { 37, 29, 0, }, /* 289 */
- { 37, 13, 0, }, /* 290 */
- { 37, 7, 0, }, /* 291 */
- { 37, 6, 0, }, /* 292 */
- { 34, 7, 0, }, /* 293 */
- { 34, 12, 0, }, /* 294 */
- { 34, 10, 0, }, /* 295 */
- { 34, 26, 0, }, /* 296 */
- { 34, 21, 0, }, /* 297 */
- { 34, 13, 0, }, /* 298 */
- { 52, 7, 0, }, /* 299 */
- { 39, 7, 0, }, /* 300 */
- { 39, 10, 0, }, /* 301 */
- { 39, 13, 0, }, /* 302 */
- { 39, 15, 0, }, /* 303 */
- { 39, 26, 0, }, /* 304 */
- { 31, 26, 0, }, /* 305 */
- { 5, 7, 0, }, /* 306 */
- { 5, 12, 0, }, /* 307 */
- { 5, 10, 0, }, /* 308 */
- { 5, 21, 0, }, /* 309 */
- { 90, 7, 0, }, /* 310 */
- { 90, 10, 0, }, /* 311 */
- { 90, 12, 0, }, /* 312 */
- { 90, 13, 0, }, /* 313 */
- { 90, 21, 0, }, /* 314 */
- { 90, 6, 0, }, /* 315 */
- { 61, 12, 0, }, /* 316 */
- { 61, 10, 0, }, /* 317 */
- { 61, 7, 0, }, /* 318 */
- { 61, 13, 0, }, /* 319 */
- { 61, 21, 0, }, /* 320 */
- { 61, 26, 0, }, /* 321 */
- { 75, 12, 0, }, /* 322 */
- { 75, 10, 0, }, /* 323 */
- { 75, 7, 0, }, /* 324 */
- { 75, 13, 0, }, /* 325 */
- { 92, 7, 0, }, /* 326 */
- { 92, 12, 0, }, /* 327 */
- { 92, 10, 0, }, /* 328 */
- { 92, 21, 0, }, /* 329 */
- { 69, 7, 0, }, /* 330 */
- { 69, 10, 0, }, /* 331 */
- { 69, 12, 0, }, /* 332 */
- { 69, 21, 0, }, /* 333 */
- { 69, 13, 0, }, /* 334 */
- { 72, 13, 0, }, /* 335 */
- { 72, 7, 0, }, /* 336 */
- { 72, 6, 0, }, /* 337 */
- { 72, 21, 0, }, /* 338 */
- { 9, 10, 0, }, /* 339 */
- { 9, 7, 0, }, /* 340 */
- { 12, 5, 0, }, /* 341 */
- { 12, 6, 0, }, /* 342 */
- { 33, 5, 35332, }, /* 343 */
- { 33, 5, 3814, }, /* 344 */
- { 33, 5, -59, }, /* 345 */
- { 33, 9, -7615, }, /* 346 */
- { 19, 5, 8, }, /* 347 */
- { 19, 9, -8, }, /* 348 */
- { 19, 5, 74, }, /* 349 */
- { 19, 5, 86, }, /* 350 */
- { 19, 5, 100, }, /* 351 */
- { 19, 5, 128, }, /* 352 */
- { 19, 5, 112, }, /* 353 */
- { 19, 5, 126, }, /* 354 */
- { 19, 8, -8, }, /* 355 */
- { 19, 5, 9, }, /* 356 */
- { 19, 9, -74, }, /* 357 */
- { 19, 8, -9, }, /* 358 */
- { 19, 5, -7205, }, /* 359 */
- { 19, 9, -86, }, /* 360 */
- { 19, 9, -100, }, /* 361 */
- { 19, 9, -112, }, /* 362 */
- { 19, 9, -128, }, /* 363 */
- { 19, 9, -126, }, /* 364 */
- { 27, 1, 0, }, /* 365 */
- { 9, 27, 0, }, /* 366 */
- { 9, 28, 0, }, /* 367 */
- { 27, 11, 0, }, /* 368 */
- { 9, 9, 0, }, /* 369 */
- { 9, 5, 0, }, /* 370 */
- { 19, 9, -7517, }, /* 371 */
- { 33, 9, -8383, }, /* 372 */
- { 33, 9, -8262, }, /* 373 */
- { 33, 9, 28, }, /* 374 */
- { 33, 5, -28, }, /* 375 */
- { 33, 14, 16, }, /* 376 */
- { 33, 14, -16, }, /* 377 */
- { 33, 14, 0, }, /* 378 */
- { 9, 26, 26, }, /* 379 */
- { 9, 26, -26, }, /* 380 */
- { 4, 26, 0, }, /* 381 */
- { 17, 9, 48, }, /* 382 */
- { 17, 5, -48, }, /* 383 */
- { 33, 9, -10743, }, /* 384 */
- { 33, 9, -3814, }, /* 385 */
- { 33, 9, -10727, }, /* 386 */
- { 33, 5, -10795, }, /* 387 */
- { 33, 5, -10792, }, /* 388 */
- { 33, 9, -10780, }, /* 389 */
- { 33, 9, -10749, }, /* 390 */
- { 33, 9, -10783, }, /* 391 */
- { 33, 9, -10782, }, /* 392 */
- { 33, 9, -10815, }, /* 393 */
- { 10, 5, 0, }, /* 394 */
- { 10, 26, 0, }, /* 395 */
- { 10, 12, 0, }, /* 396 */
- { 10, 21, 0, }, /* 397 */
- { 10, 15, 0, }, /* 398 */
- { 16, 5, -7264, }, /* 399 */
- { 58, 7, 0, }, /* 400 */
- { 58, 6, 0, }, /* 401 */
- { 58, 21, 0, }, /* 402 */
- { 58, 12, 0, }, /* 403 */
- { 22, 26, 0, }, /* 404 */
- { 22, 6, 0, }, /* 405 */
- { 22, 14, 0, }, /* 406 */
- { 23, 12, 0, }, /* 407 */
- { 26, 7, 0, }, /* 408 */
- { 26, 6, 0, }, /* 409 */
- { 29, 7, 0, }, /* 410 */
- { 29, 6, 0, }, /* 411 */
- { 3, 7, 0, }, /* 412 */
- { 23, 26, 0, }, /* 413 */
- { 29, 26, 0, }, /* 414 */
- { 22, 7, 0, }, /* 415 */
- { 60, 7, 0, }, /* 416 */
- { 60, 6, 0, }, /* 417 */
- { 60, 26, 0, }, /* 418 */
- { 85, 7, 0, }, /* 419 */
- { 85, 6, 0, }, /* 420 */
- { 85, 21, 0, }, /* 421 */
- { 76, 7, 0, }, /* 422 */
- { 76, 6, 0, }, /* 423 */
- { 76, 21, 0, }, /* 424 */
- { 76, 13, 0, }, /* 425 */
- { 12, 7, 0, }, /* 426 */
- { 12, 21, 0, }, /* 427 */
- { 78, 7, 0, }, /* 428 */
- { 78, 14, 0, }, /* 429 */
- { 78, 12, 0, }, /* 430 */
- { 78, 21, 0, }, /* 431 */
- { 33, 9, -35332, }, /* 432 */
- { 33, 9, -42280, }, /* 433 */
- { 48, 7, 0, }, /* 434 */
- { 48, 12, 0, }, /* 435 */
- { 48, 10, 0, }, /* 436 */
- { 48, 26, 0, }, /* 437 */
- { 64, 7, 0, }, /* 438 */
- { 64, 21, 0, }, /* 439 */
- { 74, 10, 0, }, /* 440 */
- { 74, 7, 0, }, /* 441 */
- { 74, 12, 0, }, /* 442 */
- { 74, 21, 0, }, /* 443 */
- { 74, 13, 0, }, /* 444 */
- { 14, 21, 0, }, /* 445 */
- { 68, 13, 0, }, /* 446 */
- { 68, 7, 0, }, /* 447 */
- { 68, 12, 0, }, /* 448 */
- { 68, 21, 0, }, /* 449 */
- { 73, 7, 0, }, /* 450 */
- { 73, 12, 0, }, /* 451 */
- { 73, 10, 0, }, /* 452 */
- { 73, 21, 0, }, /* 453 */
- { 83, 12, 0, }, /* 454 */
- { 83, 10, 0, }, /* 455 */
- { 83, 7, 0, }, /* 456 */
- { 83, 21, 0, }, /* 457 */
- { 83, 6, 0, }, /* 458 */
- { 83, 13, 0, }, /* 459 */
- { 67, 7, 0, }, /* 460 */
- { 67, 12, 0, }, /* 461 */
- { 67, 10, 0, }, /* 462 */
- { 67, 13, 0, }, /* 463 */
- { 67, 21, 0, }, /* 464 */
- { 38, 6, 0, }, /* 465 */
- { 91, 7, 0, }, /* 466 */
- { 91, 12, 0, }, /* 467 */
- { 91, 6, 0, }, /* 468 */
- { 91, 21, 0, }, /* 469 */
- { 86, 7, 0, }, /* 470 */
- { 86, 10, 0, }, /* 471 */
- { 86, 12, 0, }, /* 472 */
- { 86, 21, 0, }, /* 473 */
- { 86, 13, 0, }, /* 474 */
- { 9, 4, 0, }, /* 475 */
- { 9, 3, 0, }, /* 476 */
- { 25, 25, 0, }, /* 477 */
- { 0, 24, 0, }, /* 478 */
- { 35, 7, 0, }, /* 479 */
- { 19, 14, 0, }, /* 480 */
- { 19, 15, 0, }, /* 481 */
- { 19, 26, 0, }, /* 482 */
- { 70, 7, 0, }, /* 483 */
- { 66, 7, 0, }, /* 484 */
- { 41, 7, 0, }, /* 485 */
- { 41, 15, 0, }, /* 486 */
- { 18, 7, 0, }, /* 487 */
- { 18, 14, 0, }, /* 488 */
- { 59, 7, 0, }, /* 489 */
- { 59, 21, 0, }, /* 490 */
- { 42, 7, 0, }, /* 491 */
- { 42, 21, 0, }, /* 492 */
- { 42, 14, 0, }, /* 493 */
- { 13, 9, 40, }, /* 494 */
- { 13, 5, -40, }, /* 495 */
- { 46, 7, 0, }, /* 496 */
- { 44, 7, 0, }, /* 497 */
- { 44, 13, 0, }, /* 498 */
- { 11, 7, 0, }, /* 499 */
- { 80, 7, 0, }, /* 500 */
- { 80, 21, 0, }, /* 501 */
- { 80, 15, 0, }, /* 502 */
- { 65, 7, 0, }, /* 503 */
- { 65, 15, 0, }, /* 504 */
- { 65, 21, 0, }, /* 505 */
- { 71, 7, 0, }, /* 506 */
- { 71, 21, 0, }, /* 507 */
- { 30, 7, 0, }, /* 508 */
- { 30, 12, 0, }, /* 509 */
- { 30, 15, 0, }, /* 510 */
- { 30, 21, 0, }, /* 511 */
- { 87, 7, 0, }, /* 512 */
- { 87, 15, 0, }, /* 513 */
- { 87, 21, 0, }, /* 514 */
- { 77, 7, 0, }, /* 515 */
- { 77, 21, 0, }, /* 516 */
- { 82, 7, 0, }, /* 517 */
- { 82, 15, 0, }, /* 518 */
- { 81, 7, 0, }, /* 519 */
- { 81, 15, 0, }, /* 520 */
- { 88, 7, 0, }, /* 521 */
- { 0, 15, 0, }, /* 522 */
- { 93, 10, 0, }, /* 523 */
- { 93, 12, 0, }, /* 524 */
- { 93, 7, 0, }, /* 525 */
- { 93, 21, 0, }, /* 526 */
- { 93, 15, 0, }, /* 527 */
- { 93, 13, 0, }, /* 528 */
- { 84, 12, 0, }, /* 529 */
- { 84, 10, 0, }, /* 530 */
- { 84, 7, 0, }, /* 531 */
- { 84, 21, 0, }, /* 532 */
- { 84, 1, 0, }, /* 533 */
- { 62, 7, 0, }, /* 534 */
- { 62, 14, 0, }, /* 535 */
- { 62, 21, 0, }, /* 536 */
- { 79, 7, 0, }, /* 537 */
- { 19, 12, 0, }, /* 538 */
- { 26, 26, 0, }, /* 539 */
+pcre_uint8 property_2;
+pcre_uint8 property_3;
+pcre_int32 property_4;
+} ucd_record;
+*/
+
+
+const pcre_uint32 PRIV(ucd_caseless_sets)[] = {
+ NOTACHAR,
+ 0x0053, 0x0073, 0x017f, NOTACHAR,
+ 0x01c4, 0x01c5, 0x01c6, NOTACHAR,
+ 0x01c7, 0x01c8, 0x01c9, NOTACHAR,
+ 0x01ca, 0x01cb, 0x01cc, NOTACHAR,
+ 0x01f1, 0x01f2, 0x01f3, NOTACHAR,
+ 0x0345, 0x0399, 0x03b9, 0x1fbe, NOTACHAR,
+ 0x00b5, 0x039c, 0x03bc, NOTACHAR,
+ 0x03a3, 0x03c2, 0x03c3, NOTACHAR,
+ 0x0392, 0x03b2, 0x03d0, NOTACHAR,
+ 0x0398, 0x03b8, 0x03d1, 0x03f4, NOTACHAR,
+ 0x03a6, 0x03c6, 0x03d5, NOTACHAR,
+ 0x03a0, 0x03c0, 0x03d6, NOTACHAR,
+ 0x039a, 0x03ba, 0x03f0, NOTACHAR,
+ 0x03a1, 0x03c1, 0x03f1, NOTACHAR,
+ 0x0395, 0x03b5, 0x03f5, NOTACHAR,
+ 0x1e60, 0x1e61, 0x1e9b, NOTACHAR,
+ 0x03a9, 0x03c9, 0x2126, NOTACHAR,
+ 0x004b, 0x006b, 0x212a, NOTACHAR,
+ 0x00c5, 0x00e5, 0x212b, NOTACHAR,
+};
+
+/* When #included in pcretest, we don't need this large table. */
+
+#ifndef PCRE_INCLUDED
+
+const ucd_record PRIV(ucd_records)[] = { /* 5024 bytes, record size 8 */
+ { 9, 0, 2, 0, 0, }, /* 0 */
+ { 9, 0, 1, 0, 0, }, /* 1 */
+ { 9, 0, 0, 0, 0, }, /* 2 */
+ { 9, 29, 12, 0, 0, }, /* 3 */
+ { 9, 21, 12, 0, 0, }, /* 4 */
+ { 9, 23, 12, 0, 0, }, /* 5 */
+ { 9, 22, 12, 0, 0, }, /* 6 */
+ { 9, 18, 12, 0, 0, }, /* 7 */
+ { 9, 25, 12, 0, 0, }, /* 8 */
+ { 9, 17, 12, 0, 0, }, /* 9 */
+ { 9, 13, 12, 0, 0, }, /* 10 */
+ { 33, 9, 12, 0, 32, }, /* 11 */
+ { 33, 9, 12, 71, 32, }, /* 12 */
+ { 33, 9, 12, 1, 32, }, /* 13 */
+ { 9, 24, 12, 0, 0, }, /* 14 */
+ { 9, 16, 12, 0, 0, }, /* 15 */
+ { 33, 5, 12, 0, -32, }, /* 16 */
+ { 33, 5, 12, 71, -32, }, /* 17 */
+ { 33, 5, 12, 1, -32, }, /* 18 */
+ { 9, 26, 12, 0, 0, }, /* 19 */
+ { 33, 7, 12, 0, 0, }, /* 20 */
+ { 9, 20, 12, 0, 0, }, /* 21 */
+ { 9, 1, 2, 0, 0, }, /* 22 */
+ { 9, 15, 12, 0, 0, }, /* 23 */
+ { 9, 5, 12, 26, 775, }, /* 24 */
+ { 9, 19, 12, 0, 0, }, /* 25 */
+ { 33, 9, 12, 75, 32, }, /* 26 */
+ { 33, 5, 12, 0, 7615, }, /* 27 */
+ { 33, 5, 12, 75, -32, }, /* 28 */
+ { 33, 5, 12, 0, 121, }, /* 29 */
+ { 33, 9, 12, 0, 1, }, /* 30 */
+ { 33, 5, 12, 0, -1, }, /* 31 */
+ { 33, 9, 12, 0, 0, }, /* 32 */
+ { 33, 5, 12, 0, 0, }, /* 33 */
+ { 33, 9, 12, 0, -121, }, /* 34 */
+ { 33, 5, 12, 1, -268, }, /* 35 */
+ { 33, 5, 12, 0, 195, }, /* 36 */
+ { 33, 9, 12, 0, 210, }, /* 37 */
+ { 33, 9, 12, 0, 206, }, /* 38 */
+ { 33, 9, 12, 0, 205, }, /* 39 */
+ { 33, 9, 12, 0, 79, }, /* 40 */
+ { 33, 9, 12, 0, 202, }, /* 41 */
+ { 33, 9, 12, 0, 203, }, /* 42 */
+ { 33, 9, 12, 0, 207, }, /* 43 */
+ { 33, 5, 12, 0, 97, }, /* 44 */
+ { 33, 9, 12, 0, 211, }, /* 45 */
+ { 33, 9, 12, 0, 209, }, /* 46 */
+ { 33, 5, 12, 0, 163, }, /* 47 */
+ { 33, 9, 12, 0, 213, }, /* 48 */
+ { 33, 5, 12, 0, 130, }, /* 49 */
+ { 33, 9, 12, 0, 214, }, /* 50 */
+ { 33, 9, 12, 0, 218, }, /* 51 */
+ { 33, 9, 12, 0, 217, }, /* 52 */
+ { 33, 9, 12, 0, 219, }, /* 53 */
+ { 33, 5, 12, 0, 56, }, /* 54 */
+ { 33, 9, 12, 5, 2, }, /* 55 */
+ { 33, 8, 12, 5, 1, }, /* 56 */
+ { 33, 5, 12, 5, -2, }, /* 57 */
+ { 33, 9, 12, 9, 2, }, /* 58 */
+ { 33, 8, 12, 9, 1, }, /* 59 */
+ { 33, 5, 12, 9, -2, }, /* 60 */
+ { 33, 9, 12, 13, 2, }, /* 61 */
+ { 33, 8, 12, 13, 1, }, /* 62 */
+ { 33, 5, 12, 13, -2, }, /* 63 */
+ { 33, 5, 12, 0, -79, }, /* 64 */
+ { 33, 9, 12, 17, 2, }, /* 65 */
+ { 33, 8, 12, 17, 1, }, /* 66 */
+ { 33, 5, 12, 17, -2, }, /* 67 */
+ { 33, 9, 12, 0, -97, }, /* 68 */
+ { 33, 9, 12, 0, -56, }, /* 69 */
+ { 33, 9, 12, 0, -130, }, /* 70 */
+ { 33, 9, 12, 0, 10795, }, /* 71 */
+ { 33, 9, 12, 0, -163, }, /* 72 */
+ { 33, 9, 12, 0, 10792, }, /* 73 */
+ { 33, 5, 12, 0, 10815, }, /* 74 */
+ { 33, 9, 12, 0, -195, }, /* 75 */
+ { 33, 9, 12, 0, 69, }, /* 76 */
+ { 33, 9, 12, 0, 71, }, /* 77 */
+ { 33, 5, 12, 0, 10783, }, /* 78 */
+ { 33, 5, 12, 0, 10780, }, /* 79 */
+ { 33, 5, 12, 0, 10782, }, /* 80 */
+ { 33, 5, 12, 0, -210, }, /* 81 */
+ { 33, 5, 12, 0, -206, }, /* 82 */
+ { 33, 5, 12, 0, -205, }, /* 83 */
+ { 33, 5, 12, 0, -202, }, /* 84 */
+ { 33, 5, 12, 0, -203, }, /* 85 */
+ { 33, 5, 12, 0, -207, }, /* 86 */
+ { 33, 5, 12, 0, 42280, }, /* 87 */
+ { 33, 5, 12, 0, 42308, }, /* 88 */
+ { 33, 5, 12, 0, -209, }, /* 89 */
+ { 33, 5, 12, 0, -211, }, /* 90 */
+ { 33, 5, 12, 0, 10743, }, /* 91 */
+ { 33, 5, 12, 0, 10749, }, /* 92 */
+ { 33, 5, 12, 0, -213, }, /* 93 */
+ { 33, 5, 12, 0, -214, }, /* 94 */
+ { 33, 5, 12, 0, 10727, }, /* 95 */
+ { 33, 5, 12, 0, -218, }, /* 96 */
+ { 33, 5, 12, 0, -69, }, /* 97 */
+ { 33, 5, 12, 0, -217, }, /* 98 */
+ { 33, 5, 12, 0, -71, }, /* 99 */
+ { 33, 5, 12, 0, -219, }, /* 100 */
+ { 33, 6, 12, 0, 0, }, /* 101 */
+ { 9, 6, 12, 0, 0, }, /* 102 */
+ { 3, 24, 12, 0, 0, }, /* 103 */
+ { 27, 12, 3, 0, 0, }, /* 104 */
+ { 27, 12, 3, 21, 116, }, /* 105 */
+ { 19, 9, 12, 0, 1, }, /* 106 */
+ { 19, 5, 12, 0, -1, }, /* 107 */
+ { 19, 24, 12, 0, 0, }, /* 108 */
+ { 9, 2, 12, 0, 0, }, /* 109 */
+ { 19, 6, 12, 0, 0, }, /* 110 */
+ { 19, 5, 12, 0, 130, }, /* 111 */
+ { 19, 9, 12, 0, 38, }, /* 112 */
+ { 19, 9, 12, 0, 37, }, /* 113 */
+ { 19, 9, 12, 0, 64, }, /* 114 */
+ { 19, 9, 12, 0, 63, }, /* 115 */
+ { 19, 5, 12, 0, 0, }, /* 116 */
+ { 19, 9, 12, 0, 32, }, /* 117 */
+ { 19, 9, 12, 34, 32, }, /* 118 */
+ { 19, 9, 12, 59, 32, }, /* 119 */
+ { 19, 9, 12, 38, 32, }, /* 120 */
+ { 19, 9, 12, 21, 32, }, /* 121 */
+ { 19, 9, 12, 51, 32, }, /* 122 */
+ { 19, 9, 12, 26, 32, }, /* 123 */
+ { 19, 9, 12, 47, 32, }, /* 124 */
+ { 19, 9, 12, 55, 32, }, /* 125 */
+ { 19, 9, 12, 30, 32, }, /* 126 */
+ { 19, 9, 12, 43, 32, }, /* 127 */
+ { 19, 9, 12, 67, 32, }, /* 128 */
+ { 19, 5, 12, 0, -38, }, /* 129 */
+ { 19, 5, 12, 0, -37, }, /* 130 */
+ { 19, 5, 12, 0, -32, }, /* 131 */
+ { 19, 5, 12, 34, -32, }, /* 132 */
+ { 19, 5, 12, 59, -32, }, /* 133 */
+ { 19, 5, 12, 38, -32, }, /* 134 */
+ { 19, 5, 12, 21, -116, }, /* 135 */
+ { 19, 5, 12, 51, -32, }, /* 136 */
+ { 19, 5, 12, 26, -775, }, /* 137 */
+ { 19, 5, 12, 47, -32, }, /* 138 */
+ { 19, 5, 12, 55, -32, }, /* 139 */
+ { 19, 5, 12, 30, 1, }, /* 140 */
+ { 19, 5, 12, 30, -32, }, /* 141 */
+ { 19, 5, 12, 43, -32, }, /* 142 */
+ { 19, 5, 12, 67, -32, }, /* 143 */
+ { 19, 5, 12, 0, -64, }, /* 144 */
+ { 19, 5, 12, 0, -63, }, /* 145 */
+ { 19, 9, 12, 0, 8, }, /* 146 */
+ { 19, 5, 12, 34, -30, }, /* 147 */
+ { 19, 5, 12, 38, -25, }, /* 148 */
+ { 19, 9, 12, 0, 0, }, /* 149 */
+ { 19, 5, 12, 43, -15, }, /* 150 */
+ { 19, 5, 12, 47, -22, }, /* 151 */
+ { 19, 5, 12, 0, -8, }, /* 152 */
+ { 10, 9, 12, 0, 1, }, /* 153 */
+ { 10, 5, 12, 0, -1, }, /* 154 */
+ { 19, 5, 12, 51, -54, }, /* 155 */
+ { 19, 5, 12, 55, -48, }, /* 156 */
+ { 19, 5, 12, 0, 7, }, /* 157 */
+ { 19, 9, 12, 38, -60, }, /* 158 */
+ { 19, 5, 12, 59, -64, }, /* 159 */
+ { 19, 25, 12, 0, 0, }, /* 160 */
+ { 19, 9, 12, 0, -7, }, /* 161 */
+ { 19, 9, 12, 0, -130, }, /* 162 */
+ { 12, 9, 12, 0, 80, }, /* 163 */
+ { 12, 9, 12, 0, 32, }, /* 164 */
+ { 12, 5, 12, 0, -32, }, /* 165 */
+ { 12, 5, 12, 0, -80, }, /* 166 */
+ { 12, 9, 12, 0, 1, }, /* 167 */
+ { 12, 5, 12, 0, -1, }, /* 168 */
+ { 12, 26, 12, 0, 0, }, /* 169 */
+ { 12, 12, 3, 0, 0, }, /* 170 */
+ { 12, 11, 3, 0, 0, }, /* 171 */
+ { 12, 9, 12, 0, 15, }, /* 172 */
+ { 12, 5, 12, 0, -15, }, /* 173 */
+ { 1, 9, 12, 0, 48, }, /* 174 */
+ { 1, 6, 12, 0, 0, }, /* 175 */
+ { 1, 21, 12, 0, 0, }, /* 176 */
+ { 1, 5, 12, 0, -48, }, /* 177 */
+ { 1, 5, 12, 0, 0, }, /* 178 */
+ { 1, 17, 12, 0, 0, }, /* 179 */
+ { 1, 23, 12, 0, 0, }, /* 180 */
+ { 25, 12, 3, 0, 0, }, /* 181 */
+ { 25, 17, 12, 0, 0, }, /* 182 */
+ { 25, 21, 12, 0, 0, }, /* 183 */
+ { 25, 7, 12, 0, 0, }, /* 184 */
+ { 0, 1, 2, 0, 0, }, /* 185 */
+ { 0, 25, 12, 0, 0, }, /* 186 */
+ { 0, 21, 12, 0, 0, }, /* 187 */
+ { 0, 23, 12, 0, 0, }, /* 188 */
+ { 0, 26, 12, 0, 0, }, /* 189 */
+ { 0, 12, 3, 0, 0, }, /* 190 */
+ { 0, 7, 12, 0, 0, }, /* 191 */
+ { 0, 6, 12, 0, 0, }, /* 192 */
+ { 0, 13, 12, 0, 0, }, /* 193 */
+ { 49, 21, 12, 0, 0, }, /* 194 */
+ { 49, 1, 2, 0, 0, }, /* 195 */
+ { 49, 7, 12, 0, 0, }, /* 196 */
+ { 49, 12, 3, 0, 0, }, /* 197 */
+ { 55, 7, 12, 0, 0, }, /* 198 */
+ { 55, 12, 3, 0, 0, }, /* 199 */
+ { 63, 13, 12, 0, 0, }, /* 200 */
+ { 63, 7, 12, 0, 0, }, /* 201 */
+ { 63, 12, 3, 0, 0, }, /* 202 */
+ { 63, 6, 12, 0, 0, }, /* 203 */
+ { 63, 26, 12, 0, 0, }, /* 204 */
+ { 63, 21, 12, 0, 0, }, /* 205 */
+ { 89, 7, 12, 0, 0, }, /* 206 */
+ { 89, 12, 3, 0, 0, }, /* 207 */
+ { 89, 6, 12, 0, 0, }, /* 208 */
+ { 89, 21, 12, 0, 0, }, /* 209 */
+ { 94, 7, 12, 0, 0, }, /* 210 */
+ { 94, 12, 3, 0, 0, }, /* 211 */
+ { 94, 21, 12, 0, 0, }, /* 212 */
+ { 14, 12, 3, 0, 0, }, /* 213 */
+ { 14, 10, 5, 0, 0, }, /* 214 */
+ { 14, 7, 12, 0, 0, }, /* 215 */
+ { 14, 13, 12, 0, 0, }, /* 216 */
+ { 14, 21, 12, 0, 0, }, /* 217 */
+ { 14, 6, 12, 0, 0, }, /* 218 */
+ { 2, 12, 3, 0, 0, }, /* 219 */
+ { 2, 10, 5, 0, 0, }, /* 220 */
+ { 2, 7, 12, 0, 0, }, /* 221 */
+ { 2, 10, 3, 0, 0, }, /* 222 */
+ { 2, 13, 12, 0, 0, }, /* 223 */
+ { 2, 23, 12, 0, 0, }, /* 224 */
+ { 2, 15, 12, 0, 0, }, /* 225 */
+ { 2, 26, 12, 0, 0, }, /* 226 */
+ { 21, 12, 3, 0, 0, }, /* 227 */
+ { 21, 10, 5, 0, 0, }, /* 228 */
+ { 21, 7, 12, 0, 0, }, /* 229 */
+ { 21, 13, 12, 0, 0, }, /* 230 */
+ { 20, 12, 3, 0, 0, }, /* 231 */
+ { 20, 10, 5, 0, 0, }, /* 232 */
+ { 20, 7, 12, 0, 0, }, /* 233 */
+ { 20, 13, 12, 0, 0, }, /* 234 */
+ { 20, 21, 12, 0, 0, }, /* 235 */
+ { 20, 23, 12, 0, 0, }, /* 236 */
+ { 43, 12, 3, 0, 0, }, /* 237 */
+ { 43, 10, 5, 0, 0, }, /* 238 */
+ { 43, 7, 12, 0, 0, }, /* 239 */
+ { 43, 10, 3, 0, 0, }, /* 240 */
+ { 43, 13, 12, 0, 0, }, /* 241 */
+ { 43, 26, 12, 0, 0, }, /* 242 */
+ { 43, 15, 12, 0, 0, }, /* 243 */
+ { 53, 12, 3, 0, 0, }, /* 244 */
+ { 53, 7, 12, 0, 0, }, /* 245 */
+ { 53, 10, 3, 0, 0, }, /* 246 */
+ { 53, 10, 5, 0, 0, }, /* 247 */
+ { 53, 13, 12, 0, 0, }, /* 248 */
+ { 53, 15, 12, 0, 0, }, /* 249 */
+ { 53, 26, 12, 0, 0, }, /* 250 */
+ { 53, 23, 12, 0, 0, }, /* 251 */
+ { 54, 10, 5, 0, 0, }, /* 252 */
+ { 54, 7, 12, 0, 0, }, /* 253 */
+ { 54, 12, 3, 0, 0, }, /* 254 */
+ { 54, 13, 12, 0, 0, }, /* 255 */
+ { 54, 15, 12, 0, 0, }, /* 256 */
+ { 54, 26, 12, 0, 0, }, /* 257 */
+ { 28, 10, 5, 0, 0, }, /* 258 */
+ { 28, 7, 12, 0, 0, }, /* 259 */
+ { 28, 12, 3, 0, 0, }, /* 260 */
+ { 28, 10, 3, 0, 0, }, /* 261 */
+ { 28, 13, 12, 0, 0, }, /* 262 */
+ { 36, 10, 5, 0, 0, }, /* 263 */
+ { 36, 7, 12, 0, 0, }, /* 264 */
+ { 36, 10, 3, 0, 0, }, /* 265 */
+ { 36, 12, 3, 0, 0, }, /* 266 */
+ { 36, 13, 12, 0, 0, }, /* 267 */
+ { 36, 15, 12, 0, 0, }, /* 268 */
+ { 36, 26, 12, 0, 0, }, /* 269 */
+ { 47, 10, 5, 0, 0, }, /* 270 */
+ { 47, 7, 12, 0, 0, }, /* 271 */
+ { 47, 12, 3, 0, 0, }, /* 272 */
+ { 47, 10, 3, 0, 0, }, /* 273 */
+ { 47, 21, 12, 0, 0, }, /* 274 */
+ { 56, 7, 12, 0, 0, }, /* 275 */
+ { 56, 12, 3, 0, 0, }, /* 276 */
+ { 56, 7, 5, 0, 0, }, /* 277 */
+ { 56, 6, 12, 0, 0, }, /* 278 */
+ { 56, 21, 12, 0, 0, }, /* 279 */
+ { 56, 13, 12, 0, 0, }, /* 280 */
+ { 32, 7, 12, 0, 0, }, /* 281 */
+ { 32, 12, 3, 0, 0, }, /* 282 */
+ { 32, 7, 5, 0, 0, }, /* 283 */
+ { 32, 6, 12, 0, 0, }, /* 284 */
+ { 32, 13, 12, 0, 0, }, /* 285 */
+ { 57, 7, 12, 0, 0, }, /* 286 */
+ { 57, 26, 12, 0, 0, }, /* 287 */
+ { 57, 21, 12, 0, 0, }, /* 288 */
+ { 57, 12, 3, 0, 0, }, /* 289 */
+ { 57, 13, 12, 0, 0, }, /* 290 */
+ { 57, 15, 12, 0, 0, }, /* 291 */
+ { 57, 22, 12, 0, 0, }, /* 292 */
+ { 57, 18, 12, 0, 0, }, /* 293 */
+ { 57, 10, 5, 0, 0, }, /* 294 */
+ { 38, 7, 12, 0, 0, }, /* 295 */
+ { 38, 10, 12, 0, 0, }, /* 296 */
+ { 38, 12, 3, 0, 0, }, /* 297 */
+ { 38, 10, 5, 0, 0, }, /* 298 */
+ { 38, 13, 12, 0, 0, }, /* 299 */
+ { 38, 21, 12, 0, 0, }, /* 300 */
+ { 38, 26, 12, 0, 0, }, /* 301 */
+ { 16, 9, 12, 0, 7264, }, /* 302 */
+ { 16, 7, 12, 0, 0, }, /* 303 */
+ { 16, 6, 12, 0, 0, }, /* 304 */
+ { 23, 7, 6, 0, 0, }, /* 305 */
+ { 23, 7, 7, 0, 0, }, /* 306 */
+ { 23, 7, 8, 0, 0, }, /* 307 */
+ { 15, 7, 12, 0, 0, }, /* 308 */
+ { 15, 12, 3, 0, 0, }, /* 309 */
+ { 15, 21, 12, 0, 0, }, /* 310 */
+ { 15, 15, 12, 0, 0, }, /* 311 */
+ { 15, 26, 12, 0, 0, }, /* 312 */
+ { 8, 7, 12, 0, 0, }, /* 313 */
+ { 7, 17, 12, 0, 0, }, /* 314 */
+ { 7, 7, 12, 0, 0, }, /* 315 */
+ { 7, 21, 12, 0, 0, }, /* 316 */
+ { 40, 29, 12, 0, 0, }, /* 317 */
+ { 40, 7, 12, 0, 0, }, /* 318 */
+ { 40, 22, 12, 0, 0, }, /* 319 */
+ { 40, 18, 12, 0, 0, }, /* 320 */
+ { 45, 7, 12, 0, 0, }, /* 321 */
+ { 45, 14, 12, 0, 0, }, /* 322 */
+ { 50, 7, 12, 0, 0, }, /* 323 */
+ { 50, 12, 3, 0, 0, }, /* 324 */
+ { 24, 7, 12, 0, 0, }, /* 325 */
+ { 24, 12, 3, 0, 0, }, /* 326 */
+ { 6, 7, 12, 0, 0, }, /* 327 */
+ { 6, 12, 3, 0, 0, }, /* 328 */
+ { 51, 7, 12, 0, 0, }, /* 329 */
+ { 51, 12, 3, 0, 0, }, /* 330 */
+ { 31, 7, 12, 0, 0, }, /* 331 */
+ { 31, 12, 3, 0, 0, }, /* 332 */
+ { 31, 10, 5, 0, 0, }, /* 333 */
+ { 31, 21, 12, 0, 0, }, /* 334 */
+ { 31, 6, 12, 0, 0, }, /* 335 */
+ { 31, 23, 12, 0, 0, }, /* 336 */
+ { 31, 13, 12, 0, 0, }, /* 337 */
+ { 31, 15, 12, 0, 0, }, /* 338 */
+ { 37, 21, 12, 0, 0, }, /* 339 */
+ { 37, 17, 12, 0, 0, }, /* 340 */
+ { 37, 12, 3, 0, 0, }, /* 341 */
+ { 37, 29, 12, 0, 0, }, /* 342 */
+ { 37, 13, 12, 0, 0, }, /* 343 */
+ { 37, 7, 12, 0, 0, }, /* 344 */
+ { 37, 6, 12, 0, 0, }, /* 345 */
+ { 34, 7, 12, 0, 0, }, /* 346 */
+ { 34, 12, 3, 0, 0, }, /* 347 */
+ { 34, 10, 5, 0, 0, }, /* 348 */
+ { 34, 26, 12, 0, 0, }, /* 349 */
+ { 34, 21, 12, 0, 0, }, /* 350 */
+ { 34, 13, 12, 0, 0, }, /* 351 */
+ { 52, 7, 12, 0, 0, }, /* 352 */
+ { 39, 7, 12, 0, 0, }, /* 353 */
+ { 39, 10, 12, 0, 0, }, /* 354 */
+ { 39, 10, 5, 0, 0, }, /* 355 */
+ { 39, 13, 12, 0, 0, }, /* 356 */
+ { 39, 15, 12, 0, 0, }, /* 357 */
+ { 39, 26, 12, 0, 0, }, /* 358 */
+ { 31, 26, 12, 0, 0, }, /* 359 */
+ { 5, 7, 12, 0, 0, }, /* 360 */
+ { 5, 12, 3, 0, 0, }, /* 361 */
+ { 5, 10, 5, 0, 0, }, /* 362 */
+ { 5, 21, 12, 0, 0, }, /* 363 */
+ { 90, 7, 12, 0, 0, }, /* 364 */
+ { 90, 10, 5, 0, 0, }, /* 365 */
+ { 90, 12, 3, 0, 0, }, /* 366 */
+ { 90, 10, 12, 0, 0, }, /* 367 */
+ { 90, 13, 12, 0, 0, }, /* 368 */
+ { 90, 21, 12, 0, 0, }, /* 369 */
+ { 90, 6, 12, 0, 0, }, /* 370 */
+ { 61, 12, 3, 0, 0, }, /* 371 */
+ { 61, 10, 5, 0, 0, }, /* 372 */
+ { 61, 7, 12, 0, 0, }, /* 373 */
+ { 61, 13, 12, 0, 0, }, /* 374 */
+ { 61, 21, 12, 0, 0, }, /* 375 */
+ { 61, 26, 12, 0, 0, }, /* 376 */
+ { 75, 12, 3, 0, 0, }, /* 377 */
+ { 75, 10, 5, 0, 0, }, /* 378 */
+ { 75, 7, 12, 0, 0, }, /* 379 */
+ { 75, 13, 12, 0, 0, }, /* 380 */
+ { 92, 7, 12, 0, 0, }, /* 381 */
+ { 92, 12, 3, 0, 0, }, /* 382 */
+ { 92, 10, 5, 0, 0, }, /* 383 */
+ { 92, 21, 12, 0, 0, }, /* 384 */
+ { 69, 7, 12, 0, 0, }, /* 385 */
+ { 69, 10, 5, 0, 0, }, /* 386 */
+ { 69, 12, 3, 0, 0, }, /* 387 */
+ { 69, 21, 12, 0, 0, }, /* 388 */
+ { 69, 13, 12, 0, 0, }, /* 389 */
+ { 72, 13, 12, 0, 0, }, /* 390 */
+ { 72, 7, 12, 0, 0, }, /* 391 */
+ { 72, 6, 12, 0, 0, }, /* 392 */
+ { 72, 21, 12, 0, 0, }, /* 393 */
+ { 75, 21, 12, 0, 0, }, /* 394 */
+ { 9, 10, 5, 0, 0, }, /* 395 */
+ { 9, 7, 12, 0, 0, }, /* 396 */
+ { 12, 5, 12, 0, 0, }, /* 397 */
+ { 12, 6, 12, 0, 0, }, /* 398 */
+ { 33, 5, 12, 0, 35332, }, /* 399 */
+ { 33, 5, 12, 0, 3814, }, /* 400 */
+ { 33, 9, 12, 63, 1, }, /* 401 */
+ { 33, 5, 12, 63, -1, }, /* 402 */
+ { 33, 5, 12, 63, -58, }, /* 403 */
+ { 33, 9, 12, 0, -7615, }, /* 404 */
+ { 19, 5, 12, 0, 8, }, /* 405 */
+ { 19, 9, 12, 0, -8, }, /* 406 */
+ { 19, 5, 12, 0, 74, }, /* 407 */
+ { 19, 5, 12, 0, 86, }, /* 408 */
+ { 19, 5, 12, 0, 100, }, /* 409 */
+ { 19, 5, 12, 0, 128, }, /* 410 */
+ { 19, 5, 12, 0, 112, }, /* 411 */
+ { 19, 5, 12, 0, 126, }, /* 412 */
+ { 19, 8, 12, 0, -8, }, /* 413 */
+ { 19, 5, 12, 0, 9, }, /* 414 */
+ { 19, 9, 12, 0, -74, }, /* 415 */
+ { 19, 8, 12, 0, -9, }, /* 416 */
+ { 19, 5, 12, 21, -7173, }, /* 417 */
+ { 19, 9, 12, 0, -86, }, /* 418 */
+ { 19, 9, 12, 0, -100, }, /* 419 */
+ { 19, 9, 12, 0, -112, }, /* 420 */
+ { 19, 9, 12, 0, -128, }, /* 421 */
+ { 19, 9, 12, 0, -126, }, /* 422 */
+ { 27, 1, 3, 0, 0, }, /* 423 */
+ { 9, 27, 2, 0, 0, }, /* 424 */
+ { 9, 28, 2, 0, 0, }, /* 425 */
+ { 9, 2, 2, 0, 0, }, /* 426 */
+ { 27, 11, 3, 0, 0, }, /* 427 */
+ { 9, 9, 12, 0, 0, }, /* 428 */
+ { 9, 5, 12, 0, 0, }, /* 429 */
+ { 19, 9, 12, 67, -7517, }, /* 430 */
+ { 33, 9, 12, 71, -8383, }, /* 431 */
+ { 33, 9, 12, 75, -8262, }, /* 432 */
+ { 33, 9, 12, 0, 28, }, /* 433 */
+ { 33, 5, 12, 0, -28, }, /* 434 */
+ { 33, 14, 12, 0, 16, }, /* 435 */
+ { 33, 14, 12, 0, -16, }, /* 436 */
+ { 33, 14, 12, 0, 0, }, /* 437 */
+ { 9, 26, 12, 0, 26, }, /* 438 */
+ { 9, 26, 12, 0, -26, }, /* 439 */
+ { 4, 26, 12, 0, 0, }, /* 440 */
+ { 17, 9, 12, 0, 48, }, /* 441 */
+ { 17, 5, 12, 0, -48, }, /* 442 */
+ { 33, 9, 12, 0, -10743, }, /* 443 */
+ { 33, 9, 12, 0, -3814, }, /* 444 */
+ { 33, 9, 12, 0, -10727, }, /* 445 */
+ { 33, 5, 12, 0, -10795, }, /* 446 */
+ { 33, 5, 12, 0, -10792, }, /* 447 */
+ { 33, 9, 12, 0, -10780, }, /* 448 */
+ { 33, 9, 12, 0, -10749, }, /* 449 */
+ { 33, 9, 12, 0, -10783, }, /* 450 */
+ { 33, 9, 12, 0, -10782, }, /* 451 */
+ { 33, 9, 12, 0, -10815, }, /* 452 */
+ { 10, 5, 12, 0, 0, }, /* 453 */
+ { 10, 26, 12, 0, 0, }, /* 454 */
+ { 10, 12, 3, 0, 0, }, /* 455 */
+ { 10, 21, 12, 0, 0, }, /* 456 */
+ { 10, 15, 12, 0, 0, }, /* 457 */
+ { 16, 5, 12, 0, -7264, }, /* 458 */
+ { 58, 7, 12, 0, 0, }, /* 459 */
+ { 58, 6, 12, 0, 0, }, /* 460 */
+ { 58, 21, 12, 0, 0, }, /* 461 */
+ { 58, 12, 3, 0, 0, }, /* 462 */
+ { 22, 26, 12, 0, 0, }, /* 463 */
+ { 22, 6, 12, 0, 0, }, /* 464 */
+ { 22, 14, 12, 0, 0, }, /* 465 */
+ { 23, 10, 3, 0, 0, }, /* 466 */
+ { 26, 7, 12, 0, 0, }, /* 467 */
+ { 26, 6, 12, 0, 0, }, /* 468 */
+ { 29, 7, 12, 0, 0, }, /* 469 */
+ { 29, 6, 12, 0, 0, }, /* 470 */
+ { 3, 7, 12, 0, 0, }, /* 471 */
+ { 23, 7, 12, 0, 0, }, /* 472 */
+ { 23, 26, 12, 0, 0, }, /* 473 */
+ { 29, 26, 12, 0, 0, }, /* 474 */
+ { 22, 7, 12, 0, 0, }, /* 475 */
+ { 60, 7, 12, 0, 0, }, /* 476 */
+ { 60, 6, 12, 0, 0, }, /* 477 */
+ { 60, 26, 12, 0, 0, }, /* 478 */
+ { 85, 7, 12, 0, 0, }, /* 479 */
+ { 85, 6, 12, 0, 0, }, /* 480 */
+ { 85, 21, 12, 0, 0, }, /* 481 */
+ { 76, 7, 12, 0, 0, }, /* 482 */
+ { 76, 6, 12, 0, 0, }, /* 483 */
+ { 76, 21, 12, 0, 0, }, /* 484 */
+ { 76, 13, 12, 0, 0, }, /* 485 */
+ { 12, 7, 12, 0, 0, }, /* 486 */
+ { 12, 21, 12, 0, 0, }, /* 487 */
+ { 78, 7, 12, 0, 0, }, /* 488 */
+ { 78, 14, 12, 0, 0, }, /* 489 */
+ { 78, 12, 3, 0, 0, }, /* 490 */
+ { 78, 21, 12, 0, 0, }, /* 491 */
+ { 33, 9, 12, 0, -35332, }, /* 492 */
+ { 33, 9, 12, 0, -42280, }, /* 493 */
+ { 33, 9, 12, 0, -42308, }, /* 494 */
+ { 48, 7, 12, 0, 0, }, /* 495 */
+ { 48, 12, 3, 0, 0, }, /* 496 */
+ { 48, 10, 5, 0, 0, }, /* 497 */
+ { 48, 26, 12, 0, 0, }, /* 498 */
+ { 64, 7, 12, 0, 0, }, /* 499 */
+ { 64, 21, 12, 0, 0, }, /* 500 */
+ { 74, 10, 5, 0, 0, }, /* 501 */
+ { 74, 7, 12, 0, 0, }, /* 502 */
+ { 74, 12, 3, 0, 0, }, /* 503 */
+ { 74, 21, 12, 0, 0, }, /* 504 */
+ { 74, 13, 12, 0, 0, }, /* 505 */
+ { 68, 13, 12, 0, 0, }, /* 506 */
+ { 68, 7, 12, 0, 0, }, /* 507 */
+ { 68, 12, 3, 0, 0, }, /* 508 */
+ { 68, 21, 12, 0, 0, }, /* 509 */
+ { 73, 7, 12, 0, 0, }, /* 510 */
+ { 73, 12, 3, 0, 0, }, /* 511 */
+ { 73, 10, 5, 0, 0, }, /* 512 */
+ { 73, 21, 12, 0, 0, }, /* 513 */
+ { 83, 12, 3, 0, 0, }, /* 514 */
+ { 83, 10, 5, 0, 0, }, /* 515 */
+ { 83, 7, 12, 0, 0, }, /* 516 */
+ { 83, 21, 12, 0, 0, }, /* 517 */
+ { 83, 6, 12, 0, 0, }, /* 518 */
+ { 83, 13, 12, 0, 0, }, /* 519 */
+ { 67, 7, 12, 0, 0, }, /* 520 */
+ { 67, 12, 3, 0, 0, }, /* 521 */
+ { 67, 10, 5, 0, 0, }, /* 522 */
+ { 67, 13, 12, 0, 0, }, /* 523 */
+ { 67, 21, 12, 0, 0, }, /* 524 */
+ { 38, 6, 12, 0, 0, }, /* 525 */
+ { 91, 7, 12, 0, 0, }, /* 526 */
+ { 91, 12, 3, 0, 0, }, /* 527 */
+ { 91, 6, 12, 0, 0, }, /* 528 */
+ { 91, 21, 12, 0, 0, }, /* 529 */
+ { 86, 7, 12, 0, 0, }, /* 530 */
+ { 86, 10, 5, 0, 0, }, /* 531 */
+ { 86, 12, 3, 0, 0, }, /* 532 */
+ { 86, 21, 12, 0, 0, }, /* 533 */
+ { 86, 6, 12, 0, 0, }, /* 534 */
+ { 86, 13, 12, 0, 0, }, /* 535 */
+ { 23, 7, 9, 0, 0, }, /* 536 */
+ { 23, 7, 10, 0, 0, }, /* 537 */
+ { 9, 4, 2, 0, 0, }, /* 538 */
+ { 9, 3, 12, 0, 0, }, /* 539 */
+ { 25, 25, 12, 0, 0, }, /* 540 */
+ { 0, 24, 12, 0, 0, }, /* 541 */
+ { 9, 6, 3, 0, 0, }, /* 542 */
+ { 35, 7, 12, 0, 0, }, /* 543 */
+ { 19, 14, 12, 0, 0, }, /* 544 */
+ { 19, 15, 12, 0, 0, }, /* 545 */
+ { 19, 26, 12, 0, 0, }, /* 546 */
+ { 70, 7, 12, 0, 0, }, /* 547 */
+ { 66, 7, 12, 0, 0, }, /* 548 */
+ { 41, 7, 12, 0, 0, }, /* 549 */
+ { 41, 15, 12, 0, 0, }, /* 550 */
+ { 18, 7, 12, 0, 0, }, /* 551 */
+ { 18, 14, 12, 0, 0, }, /* 552 */
+ { 59, 7, 12, 0, 0, }, /* 553 */
+ { 59, 21, 12, 0, 0, }, /* 554 */
+ { 42, 7, 12, 0, 0, }, /* 555 */
+ { 42, 21, 12, 0, 0, }, /* 556 */
+ { 42, 14, 12, 0, 0, }, /* 557 */
+ { 13, 9, 12, 0, 40, }, /* 558 */
+ { 13, 5, 12, 0, -40, }, /* 559 */
+ { 46, 7, 12, 0, 0, }, /* 560 */
+ { 44, 7, 12, 0, 0, }, /* 561 */
+ { 44, 13, 12, 0, 0, }, /* 562 */
+ { 11, 7, 12, 0, 0, }, /* 563 */
+ { 80, 7, 12, 0, 0, }, /* 564 */
+ { 80, 21, 12, 0, 0, }, /* 565 */
+ { 80, 15, 12, 0, 0, }, /* 566 */
+ { 65, 7, 12, 0, 0, }, /* 567 */
+ { 65, 15, 12, 0, 0, }, /* 568 */
+ { 65, 21, 12, 0, 0, }, /* 569 */
+ { 71, 7, 12, 0, 0, }, /* 570 */
+ { 71, 21, 12, 0, 0, }, /* 571 */
+ { 97, 7, 12, 0, 0, }, /* 572 */
+ { 96, 7, 12, 0, 0, }, /* 573 */
+ { 30, 7, 12, 0, 0, }, /* 574 */
+ { 30, 12, 3, 0, 0, }, /* 575 */
+ { 30, 15, 12, 0, 0, }, /* 576 */
+ { 30, 21, 12, 0, 0, }, /* 577 */
+ { 87, 7, 12, 0, 0, }, /* 578 */
+ { 87, 15, 12, 0, 0, }, /* 579 */
+ { 87, 21, 12, 0, 0, }, /* 580 */
+ { 77, 7, 12, 0, 0, }, /* 581 */
+ { 77, 21, 12, 0, 0, }, /* 582 */
+ { 82, 7, 12, 0, 0, }, /* 583 */
+ { 82, 15, 12, 0, 0, }, /* 584 */
+ { 81, 7, 12, 0, 0, }, /* 585 */
+ { 81, 15, 12, 0, 0, }, /* 586 */
+ { 88, 7, 12, 0, 0, }, /* 587 */
+ { 0, 15, 12, 0, 0, }, /* 588 */
+ { 93, 10, 5, 0, 0, }, /* 589 */
+ { 93, 12, 3, 0, 0, }, /* 590 */
+ { 93, 7, 12, 0, 0, }, /* 591 */
+ { 93, 21, 12, 0, 0, }, /* 592 */
+ { 93, 15, 12, 0, 0, }, /* 593 */
+ { 93, 13, 12, 0, 0, }, /* 594 */
+ { 84, 12, 3, 0, 0, }, /* 595 */
+ { 84, 10, 5, 0, 0, }, /* 596 */
+ { 84, 7, 12, 0, 0, }, /* 597 */
+ { 84, 21, 12, 0, 0, }, /* 598 */
+ { 84, 1, 2, 0, 0, }, /* 599 */
+ { 100, 7, 12, 0, 0, }, /* 600 */
+ { 100, 13, 12, 0, 0, }, /* 601 */
+ { 95, 12, 3, 0, 0, }, /* 602 */
+ { 95, 7, 12, 0, 0, }, /* 603 */
+ { 95, 10, 5, 0, 0, }, /* 604 */
+ { 95, 13, 12, 0, 0, }, /* 605 */
+ { 95, 21, 12, 0, 0, }, /* 606 */
+ { 99, 12, 3, 0, 0, }, /* 607 */
+ { 99, 10, 5, 0, 0, }, /* 608 */
+ { 99, 7, 12, 0, 0, }, /* 609 */
+ { 99, 21, 12, 0, 0, }, /* 610 */
+ { 99, 13, 12, 0, 0, }, /* 611 */
+ { 101, 7, 12, 0, 0, }, /* 612 */
+ { 101, 12, 3, 0, 0, }, /* 613 */
+ { 101, 10, 5, 0, 0, }, /* 614 */
+ { 101, 13, 12, 0, 0, }, /* 615 */
+ { 62, 7, 12, 0, 0, }, /* 616 */
+ { 62, 14, 12, 0, 0, }, /* 617 */
+ { 62, 21, 12, 0, 0, }, /* 618 */
+ { 79, 7, 12, 0, 0, }, /* 619 */
+ { 98, 7, 12, 0, 0, }, /* 620 */
+ { 98, 10, 5, 0, 0, }, /* 621 */
+ { 98, 12, 3, 0, 0, }, /* 622 */
+ { 98, 6, 12, 0, 0, }, /* 623 */
+ { 9, 10, 3, 0, 0, }, /* 624 */
+ { 19, 12, 3, 0, 0, }, /* 625 */
+ { 9, 26, 11, 0, 0, }, /* 626 */
+ { 26, 26, 12, 0, 0, }, /* 627 */
};
const pcre_uint8 PRIV(ucd_stage1)[] = { /* 8704 bytes */
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, /* U+0000 */
16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, /* U+0800 */
- 32, 33, 34, 34, 35, 36, 37, 38, 39, 40, 40, 40, 41, 42, 43, 44, /* U+1000 */
- 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, /* U+1800 */
- 61, 62, 63, 64, 65, 65, 66, 67, 68, 69, 70, 71, 72, 70, 73, 74, /* U+2000 */
- 75, 75, 65, 76, 65, 65, 77, 17, 78, 79, 80, 81, 82, 83, 84, 85, /* U+2800 */
- 86, 87, 88, 89, 90, 91, 92, 70, 93, 93, 93, 93, 93, 93, 93, 93, /* U+3000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+3800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+4000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 94, 93, 93, 93, 93, /* U+4800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+5000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+5800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+6000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+6800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+7000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+7800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+8000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+8800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+9000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 95, /* U+9800 */
- 96, 97, 97, 97, 97, 97, 97, 97, 97, 98, 99, 99,100,101,102,103, /* U+A000 */
-104,105,106,107,108,109,110,111, 34, 34, 34, 34, 34, 34, 34, 34, /* U+A800 */
- 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, /* U+B000 */
- 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, /* U+B800 */
- 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, /* U+C000 */
- 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, /* U+C800 */
- 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34,112, /* U+D000 */
-113,113,113,113,113,113,113,113,113,113,113,113,113,113,113,113, /* U+D800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+E000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+E800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F000 */
-114,114, 93, 93,115,116,117,118,119,119,120,121,122,123,124,125, /* U+F800 */
-126,127,128,129, 17,130,131,132,133,134, 17, 17, 17, 17, 17, 17, /* U+10000 */
-135, 17,136, 17,137, 17,138, 17,139, 17, 17, 17,140, 17, 17, 17, /* U+10800 */
-141,142, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+11000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+11800 */
-143,143,143,143,143,143,144, 17,145, 17, 17, 17, 17, 17, 17, 17, /* U+12000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+12800 */
-146,146,146,146,146,146,146,146,147, 17, 17, 17, 17, 17, 17, 17, /* U+13000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+13800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+14000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+14800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+15000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+15800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+16000 */
-148,148,148,148,149, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+16800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+17000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+17800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+18000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+18800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+19000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+19800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+1A000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+1A800 */
-150, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+1B000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+1B800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+1C000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+1C800 */
- 70,151,152,153,154, 17,155, 17,156,157,158,159,160,161,162,163, /* U+1D000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+1D800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+1E000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+1E800 */
-164,165,166,167,168, 17,169,170,171,172,173,174,175,176,177, 17, /* U+1F000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+1F800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+20000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+20800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+21000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+21800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+22000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+22800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+23000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+23800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+24000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+24800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+25000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+25800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+26000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+26800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+27000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+27800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+28000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+28800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+29000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+29800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,178, 93, 93, /* U+2A000 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, /* U+2A800 */
- 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93, 93,179, 93, /* U+2B000 */
-180, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+2B800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+2C000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+2C800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+2D000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+2D800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+2E000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+2E800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+2F000 */
- 93, 93, 93, 93,180, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+2F800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+30000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+30800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+31000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+31800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+32000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+32800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+33000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+33800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+34000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+34800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+35000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+35800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+36000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+36800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+37000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+37800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+38000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+38800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+39000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+39800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+3A000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+3A800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+3B000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+3B800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+3C000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+3C800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+3D000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+3D800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+3E000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+3E800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+3F000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+3F800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+40000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+40800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+41000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+41800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+42000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+42800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+43000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+43800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+44000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+44800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+45000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+45800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+46000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+46800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+47000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+47800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+48000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+48800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+49000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+49800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+4A000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+4A800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+4B000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+4B800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+4C000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+4C800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+4D000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+4D800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+4E000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+4E800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+4F000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+4F800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+50000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+50800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+51000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+51800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+52000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+52800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+53000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+53800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+54000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+54800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+55000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+55800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+56000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+56800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+57000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+57800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+58000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+58800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+59000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+59800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+5A000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+5A800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+5B000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+5B800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+5C000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+5C800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+5D000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+5D800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+5E000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+5E800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+5F000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+5F800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+60000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+60800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+61000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+61800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+62000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+62800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+63000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+63800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+64000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+64800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+65000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+65800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+66000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+66800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+67000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+67800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+68000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+68800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+69000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+69800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+6A000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+6A800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+6B000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+6B800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+6C000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+6C800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+6D000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+6D800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+6E000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+6E800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+6F000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+6F800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+70000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+70800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+71000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+71800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+72000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+72800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+73000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+73800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+74000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+74800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+75000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+75800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+76000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+76800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+77000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+77800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+78000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+78800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+79000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+79800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+7A000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+7A800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+7B000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+7B800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+7C000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+7C800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+7D000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+7D800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+7E000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+7E800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+7F000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+7F800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+80000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+80800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+81000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+81800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+82000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+82800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+83000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+83800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+84000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+84800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+85000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+85800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+86000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+86800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+87000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+87800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+88000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+88800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+89000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+89800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+8A000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+8A800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+8B000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+8B800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+8C000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+8C800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+8D000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+8D800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+8E000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+8E800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+8F000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+8F800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+90000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+90800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+91000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+91800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+92000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+92800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+93000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+93800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+94000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+94800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+95000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+95800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+96000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+96800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+97000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+97800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+98000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+98800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+99000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+99800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+9A000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+9A800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+9B000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+9B800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+9C000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+9C800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+9D000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+9D800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+9E000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+9E800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+9F000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+9F800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A0000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A0800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A1000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A1800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A2000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A2800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A3000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A3800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A4000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A4800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A5000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A5800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A6000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A6800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A7000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A7800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A8000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A8800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A9000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+A9800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+AA000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+AA800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+AB000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+AB800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+AC000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+AC800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+AD000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+AD800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+AE000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+AE800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+AF000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+AF800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B0000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B0800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B1000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B1800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B2000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B2800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B3000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B3800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B4000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B4800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B5000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B5800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B6000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B6800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B7000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B7800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B8000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B8800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B9000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+B9800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+BA000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+BA800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+BB000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+BB800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+BC000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+BC800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+BD000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+BD800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+BE000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+BE800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+BF000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+BF800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C0000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C0800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C1000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C1800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C2000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C2800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C3000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C3800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C4000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C4800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C5000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C5800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C6000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C6800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C7000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C7800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C8000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C8800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C9000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+C9800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+CA000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+CA800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+CB000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+CB800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+CC000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+CC800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+CD000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+CD800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+CE000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+CE800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+CF000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+CF800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D0000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D0800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D1000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D1800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D2000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D2800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D3000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D3800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D4000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D4800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D5000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D5800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D6000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D6800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D7000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D7800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D8000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D8800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D9000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+D9800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+DA000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+DA800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+DB000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+DB800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+DC000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+DC800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+DD000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+DD800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+DE000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+DE800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+DF000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+DF800 */
-181, 17,182,183, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E0000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E0800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E1000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E1800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E2000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E2800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E3000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E3800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E4000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E4800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E5000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E5800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E6000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E6800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E7000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E7800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E8000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E8800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E9000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+E9800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+EA000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+EA800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+EB000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+EB800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+EC000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+EC800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+ED000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+ED800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+EE000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+EE800 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+EF000 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, /* U+EF800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F0000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F0800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F1000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F1800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F2000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F2800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F3000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F3800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F4000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F4800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F5000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F5800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F6000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F6800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F7000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F7800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F8000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F8800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F9000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+F9800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+FA000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+FA800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+FB000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+FB800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+FC000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+FC800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+FD000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+FD800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+FE000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+FE800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+FF000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,184, /* U+FF800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+100000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+100800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+101000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+101800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+102000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+102800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+103000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+103800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+104000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+104800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+105000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+105800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+106000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+106800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+107000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+107800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+108000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+108800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+109000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+109800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+10A000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+10A800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+10B000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+10B800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+10C000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+10C800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+10D000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+10D800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+10E000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+10E800 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,114, /* U+10F000 */
-114,114,114,114,114,114,114,114,114,114,114,114,114,114,114,184, /* U+10F800 */
+ 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 41, 41, 42, 43, 44, 45, /* U+1000 */
+ 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, /* U+1800 */
+ 62, 63, 64, 65, 66, 66, 67, 68, 69, 70, 71, 72, 73, 71, 74, 75, /* U+2000 */
+ 76, 76, 66, 77, 66, 66, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, /* U+2800 */
+ 88, 89, 90, 91, 92, 93, 94, 71, 95, 95, 95, 95, 95, 95, 95, 95, /* U+3000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+3800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+4000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 96, 95, 95, 95, 95, /* U+4800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+5000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+5800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+6000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+6800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+7000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+7800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+8000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+8800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+9000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 97, /* U+9800 */
+ 98, 99, 99, 99, 99, 99, 99, 99, 99,100,101,101,102,103,104,105, /* U+A000 */
+106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,114, /* U+A800 */
+115,116,117,118,119,120,114,115,116,117,118,119,120,114,115,116, /* U+B000 */
+117,118,119,120,114,115,116,117,118,119,120,114,115,116,117,118, /* U+B800 */
+119,120,114,115,116,117,118,119,120,114,115,116,117,118,119,120, /* U+C000 */
+114,115,116,117,118,119,120,114,115,116,117,118,119,120,114,115, /* U+C800 */
+116,117,118,119,120,114,115,116,117,118,119,120,114,115,116,121, /* U+D000 */
+122,122,122,122,122,122,122,122,122,122,122,122,122,122,122,122, /* U+D800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+E000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+E800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F000 */
+123,123, 95, 95,124,125,126,127,128,128,129,130,131,132,133,134, /* U+F800 */
+135,136,137,138, 79,139,140,141,142,143, 79, 79, 79, 79, 79, 79, /* U+10000 */
+144, 79,145,146,147, 79,148, 79,149, 79, 79, 79,150, 79, 79, 79, /* U+10800 */
+151,152,153,154, 79, 79, 79, 79, 79, 79, 79, 79, 79,155, 79, 79, /* U+11000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+11800 */
+156,156,156,156,156,156,157, 79,158, 79, 79, 79, 79, 79, 79, 79, /* U+12000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+12800 */
+159,159,159,159,159,159,159,159,160, 79, 79, 79, 79, 79, 79, 79, /* U+13000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+13800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+14000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+14800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+15000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+15800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+16000 */
+161,161,161,161,162, 79, 79, 79, 79, 79, 79, 79, 79, 79,163,164, /* U+16800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+17000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+17800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+18000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+18800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+19000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+19800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+1A000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+1A800 */
+165, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+1B000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+1B800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+1C000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+1C800 */
+ 71,166,167,168,169, 79,170, 79,171,172,173,174,175,176,177,178, /* U+1D000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+1D800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+1E000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79,179,180, 79, 79, /* U+1E800 */
+181,182,183,184,185, 79,186,187,188,189,190,191,192,193,194, 79, /* U+1F000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+1F800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+20000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+20800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+21000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+21800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+22000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+22800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+23000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+23800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+24000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+24800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+25000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+25800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+26000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+26800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+27000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+27800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+28000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+28800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+29000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+29800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95,195, 95, 95, /* U+2A000 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, /* U+2A800 */
+ 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95, 95,196, 95, /* U+2B000 */
+197, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+2B800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+2C000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+2C800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+2D000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+2D800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+2E000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+2E800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+2F000 */
+ 95, 95, 95, 95,197, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+2F800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+30000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+30800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+31000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+31800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+32000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+32800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+33000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+33800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+34000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+34800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+35000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+35800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+36000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+36800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+37000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+37800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+38000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+38800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+39000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+39800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+3A000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+3A800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+3B000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+3B800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+3C000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+3C800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+3D000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+3D800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+3E000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+3E800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+3F000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+3F800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+40000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+40800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+41000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+41800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+42000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+42800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+43000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+43800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+44000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+44800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+45000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+45800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+46000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+46800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+47000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+47800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+48000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+48800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+49000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+49800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+4A000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+4A800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+4B000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+4B800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+4C000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+4C800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+4D000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+4D800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+4E000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+4E800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+4F000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+4F800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+50000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+50800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+51000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+51800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+52000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+52800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+53000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+53800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+54000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+54800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+55000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+55800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+56000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+56800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+57000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+57800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+58000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+58800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+59000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+59800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+5A000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+5A800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+5B000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+5B800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+5C000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+5C800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+5D000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+5D800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+5E000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+5E800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+5F000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+5F800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+60000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+60800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+61000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+61800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+62000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+62800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+63000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+63800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+64000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+64800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+65000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+65800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+66000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+66800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+67000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+67800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+68000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+68800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+69000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+69800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+6A000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+6A800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+6B000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+6B800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+6C000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+6C800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+6D000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+6D800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+6E000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+6E800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+6F000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+6F800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+70000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+70800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+71000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+71800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+72000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+72800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+73000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+73800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+74000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+74800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+75000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+75800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+76000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+76800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+77000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+77800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+78000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+78800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+79000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+79800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+7A000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+7A800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+7B000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+7B800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+7C000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+7C800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+7D000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+7D800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+7E000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+7E800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+7F000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+7F800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+80000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+80800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+81000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+81800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+82000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+82800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+83000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+83800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+84000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+84800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+85000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+85800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+86000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+86800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+87000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+87800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+88000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+88800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+89000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+89800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+8A000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+8A800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+8B000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+8B800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+8C000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+8C800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+8D000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+8D800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+8E000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+8E800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+8F000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+8F800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+90000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+90800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+91000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+91800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+92000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+92800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+93000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+93800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+94000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+94800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+95000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+95800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+96000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+96800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+97000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+97800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+98000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+98800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+99000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+99800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+9A000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+9A800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+9B000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+9B800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+9C000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+9C800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+9D000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+9D800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+9E000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+9E800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+9F000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+9F800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A0000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A0800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A1000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A1800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A2000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A2800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A3000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A3800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A4000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A4800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A5000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A5800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A6000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A6800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A7000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A7800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A8000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A8800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A9000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+A9800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+AA000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+AA800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+AB000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+AB800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+AC000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+AC800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+AD000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+AD800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+AE000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+AE800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+AF000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+AF800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B0000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B0800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B1000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B1800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B2000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B2800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B3000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B3800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B4000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B4800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B5000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B5800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B6000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B6800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B7000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B7800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B8000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B8800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B9000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+B9800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+BA000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+BA800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+BB000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+BB800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+BC000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+BC800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+BD000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+BD800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+BE000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+BE800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+BF000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+BF800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C0000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C0800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C1000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C1800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C2000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C2800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C3000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C3800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C4000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C4800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C5000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C5800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C6000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C6800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C7000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C7800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C8000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C8800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C9000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+C9800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+CA000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+CA800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+CB000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+CB800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+CC000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+CC800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+CD000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+CD800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+CE000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+CE800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+CF000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+CF800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D0000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D0800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D1000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D1800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D2000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D2800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D3000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D3800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D4000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D4800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D5000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D5800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D6000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D6800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D7000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D7800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D8000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D8800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D9000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+D9800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+DA000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+DA800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+DB000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+DB800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+DC000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+DC800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+DD000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+DD800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+DE000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+DE800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+DF000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+DF800 */
+198,199,200,201,199,199,199,199,199,199,199,199,199,199,199,199, /* U+E0000 */
+199,199,199,199,199,199,199,199,199,199,199,199,199,199,199,199, /* U+E0800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E1000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E1800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E2000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E2800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E3000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E3800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E4000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E4800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E5000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E5800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E6000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E6800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E7000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E7800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E8000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E8800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E9000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+E9800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+EA000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+EA800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+EB000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+EB800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+EC000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+EC800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+ED000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+ED800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+EE000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+EE800 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+EF000 */
+ 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, 79, /* U+EF800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F0000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F0800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F1000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F1800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F2000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F2800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F3000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F3800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F4000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F4800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F5000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F5800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F6000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F6800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F7000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F7800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F8000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F8800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F9000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+F9800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+FA000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+FA800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+FB000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+FB800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+FC000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+FC800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+FD000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+FD800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+FE000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+FE800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+FF000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,202, /* U+FF800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+100000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+100800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+101000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+101800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+102000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+102800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+103000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+103800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+104000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+104800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+105000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+105800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+106000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+106800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+107000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+107800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+108000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+108800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+109000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+109800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+10A000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+10A800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+10B000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+10B800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+10C000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+10C800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+10D000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+10D800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+10E000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+10E800 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123, /* U+10F000 */
+123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,202, /* U+10F800 */
};
-const pcre_uint16 PRIV(ucd_stage2)[] = { /* 47360 bytes, block = 128 */
+const pcre_uint16 PRIV(ucd_stage2)[] = { /* 51968 bytes, block = 128 */
/* block 0 */
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 2, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 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, 2, 2, 3, 2, 2, 2, 4, 5, 2, 6, 2, 7, 2, 2,
- 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 2, 2, 6, 6, 6, 2,
- 2, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 4, 2, 5, 10, 11,
- 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,
- 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 4, 6, 5, 6, 0,
+ 3, 4, 4, 4, 5, 4, 4, 4, 6, 7, 4, 8, 4, 9, 4, 4,
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 4, 4, 8, 8, 8, 4,
+ 4, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 11, 11, 11, 11,
+ 11, 11, 11, 13, 11, 11, 11, 11, 11, 11, 11, 6, 4, 7, 14, 15,
+ 14, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 17, 16, 16, 16, 16,
+ 16, 16, 16, 18, 16, 16, 16, 16, 16, 16, 16, 6, 8, 7, 8, 0,
/* block 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,
- 1, 2, 3, 3, 3, 3, 13, 13, 10, 13, 14, 15, 6, 16, 13, 10,
- 13, 6, 17, 17, 10, 18, 13, 2, 10, 17, 14, 19, 17, 17, 17, 2,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 6, 9, 9, 9, 9, 9, 9, 9, 14,
- 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,
- 12, 12, 12, 12, 12, 12, 12, 6, 12, 12, 12, 12, 12, 12, 12, 20,
+ 3, 4, 5, 5, 5, 5, 19, 4, 14, 19, 20, 21, 8, 22, 19, 14,
+ 19, 8, 23, 23, 14, 24, 4, 4, 14, 23, 20, 25, 23, 23, 23, 4,
+ 11, 11, 11, 11, 11, 26, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
+ 11, 11, 11, 11, 11, 11, 11, 8, 11, 11, 11, 11, 11, 11, 11, 27,
+ 16, 16, 16, 16, 16, 28, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
+ 16, 16, 16, 16, 16, 16, 16, 8, 16, 16, 16, 16, 16, 16, 16, 29,
/* block 2 */
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 23, 24, 21, 22, 21, 22, 21, 22, 14, 21, 22, 21, 22, 21, 22, 21,
- 22, 21, 22, 21, 22, 21, 22, 21, 22, 14, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 25, 21, 22, 21, 22, 21, 22, 26,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 32, 33, 30, 31, 30, 31, 30, 31, 33, 30, 31, 30, 31, 30, 31, 30,
+ 31, 30, 31, 30, 31, 30, 31, 30, 31, 33, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 34, 30, 31, 30, 31, 30, 31, 35,
/* block 3 */
- 27, 28, 21, 22, 21, 22, 29, 21, 22, 30, 30, 21, 22, 14, 31, 32,
- 33, 21, 22, 30, 34, 35, 36, 37, 21, 22, 38, 14, 36, 39, 40, 41,
- 21, 22, 21, 22, 21, 22, 42, 21, 22, 42, 14, 14, 21, 22, 42, 21,
- 22, 43, 43, 21, 22, 21, 22, 44, 21, 22, 14, 45, 21, 22, 14, 46,
- 45, 45, 45, 45, 47, 48, 49, 47, 48, 49, 47, 48, 49, 21, 22, 21,
- 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 50, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 14, 47, 48, 49, 21, 22, 51, 52, 21, 22, 21, 22, 21, 22, 21, 22,
+ 36, 37, 30, 31, 30, 31, 38, 30, 31, 39, 39, 30, 31, 33, 40, 41,
+ 42, 30, 31, 39, 43, 44, 45, 46, 30, 31, 47, 33, 45, 48, 49, 50,
+ 30, 31, 30, 31, 30, 31, 51, 30, 31, 51, 33, 33, 30, 31, 51, 30,
+ 31, 52, 52, 30, 31, 30, 31, 53, 30, 31, 33, 20, 30, 31, 33, 54,
+ 20, 20, 20, 20, 55, 56, 57, 58, 59, 60, 61, 62, 63, 30, 31, 30,
+ 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 64, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 33, 65, 66, 67, 30, 31, 68, 69, 30, 31, 30, 31, 30, 31, 30, 31,
/* block 4 */
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 53, 14, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 14, 14, 14, 14, 14, 14, 54, 21, 22, 55, 56, 57,
- 57, 21, 22, 58, 59, 60, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 61, 62, 63, 64, 65, 14, 66, 66, 14, 67, 14, 68, 14, 14, 14, 14,
- 66, 14, 14, 69, 14, 70, 14, 14, 71, 72, 14, 73, 14, 14, 14, 72,
- 14, 74, 75, 14, 14, 76, 14, 14, 14, 14, 14, 14, 14, 77, 14, 14,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 70, 33, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 33, 33, 33, 33, 33, 33, 71, 30, 31, 72, 73, 74,
+ 74, 30, 31, 75, 76, 77, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 78, 79, 80, 81, 82, 33, 83, 83, 33, 84, 33, 85, 33, 33, 33, 33,
+ 83, 33, 33, 86, 33, 87, 88, 33, 89, 90, 33, 91, 33, 33, 33, 90,
+ 33, 92, 93, 33, 33, 94, 33, 33, 33, 33, 33, 33, 33, 95, 33, 33,
/* block 5 */
- 78, 14, 14, 78, 14, 14, 14, 14, 78, 79, 80, 80, 81, 14, 14, 14,
- 14, 14, 82, 14, 45, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 96, 33, 33, 96, 33, 33, 33, 33, 96, 97, 98, 98, 99, 33, 33, 33,
+ 33, 33,100, 33, 20, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
+ 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
+101,101,101,101,101,101,101,101,101,102,102,102,102,102,102,102,
+102,102, 14, 14, 14, 14,102,102,102,102,102,102,102,102,102,102,
+102,102, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+101,101,101,101,101, 14, 14, 14, 14, 14,103,103,102, 14,102, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 83, 83, 83, 83, 83, 83, 83, 83, 83, 84, 84, 84, 84, 84, 84, 84,
- 84, 84, 10, 10, 10, 10, 84, 84, 84, 84, 84, 84, 84, 84, 84, 84,
- 84, 84, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
- 83, 83, 83, 83, 83, 10, 10, 10, 10, 10, 85, 85, 84, 10, 84, 10,
- 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
/* block 6 */
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 87, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 88, 89, 88, 89, 84, 90, 88, 89, 91, 91, 92, 93, 93, 93, 2, 91,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,105,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+106,107,106,107,102,108,106,107,109,109,110,111,111,111, 4,109,
/* block 7 */
- 91, 91, 91, 91, 90, 10, 94, 2, 95, 95, 95, 91, 96, 91, 97, 97,
- 98, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99,
- 99, 99, 91, 99, 99, 99, 99, 99, 99, 99, 99, 99,100,101,101,101,
- 98,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102,
-102,102,103,102,102,102,102,102,102,102,102,102,104,105,105,106,
-107,108,109,109,109,110,111,112, 88, 89, 88, 89, 88, 89, 88, 89,
- 88, 89,113,114,113,114,113,114,113,114,113,114,113,114,113,114,
-115,116,117, 98,118,119,120, 88, 89,121, 88, 89, 98,122,122,122,
+109,109,109,109,108, 14,112, 4,113,113,113,109,114,109,115,115,
+116,117,118,117,117,119,117,117,120,121,122,117,123,117,117,117,
+124,125,109,126,117,117,127,117,117,128,117,117,129,130,130,130,
+116,131,132,131,131,133,131,131,134,135,136,131,137,131,131,131,
+138,139,140,141,131,131,142,131,131,143,131,131,144,145,145,146,
+147,148,149,149,149,150,151,152,106,107,106,107,106,107,106,107,
+106,107,153,154,153,154,153,154,153,154,153,154,153,154,153,154,
+155,156,157,116,158,159,160,106,107,161,106,107,116,162,162,162,
/* block 8 */
-123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,123,
-124,124,124,124,124,124,124,124,124,124,124,124,124,124,124,124,
-124,124,124,124,124,124,124,124,124,124,124,124,124,124,124,124,
-125,125,125,125,125,125,125,125,125,125,125,125,125,125,125,125,
-125,125,125,125,125,125,125,125,125,125,125,125,125,125,125,125,
-126,126,126,126,126,126,126,126,126,126,126,126,126,126,126,126,
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
+163,163,163,163,163,163,163,163,163,163,163,163,163,163,163,163,
+164,164,164,164,164,164,164,164,164,164,164,164,164,164,164,164,
+164,164,164,164,164,164,164,164,164,164,164,164,164,164,164,164,
+165,165,165,165,165,165,165,165,165,165,165,165,165,165,165,165,
+165,165,165,165,165,165,165,165,165,165,165,165,165,165,165,165,
+166,166,166,166,166,166,166,166,166,166,166,166,166,166,166,166,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
/* block 9 */
-127,128,129,130,130, 86, 86,130,131,131,127,128,127,128,127,128,
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
-132,127,128,127,128,127,128,127,128,127,128,127,128,127,128,133,
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
+167,168,169,170,170,104,104,170,171,171,167,168,167,168,167,168,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
+172,167,168,167,168,167,168,167,168,167,168,167,168,167,168,173,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
/* block 10 */
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
-127,128,127,128,127,128,127,128, 91, 91, 91, 91, 91, 91, 91, 91,
- 91,134,134,134,134,134,134,134,134,134,134,134,134,134,134,134,
-134,134,134,134,134,134,134,134,134,134,134,134,134,134,134,134,
-134,134,134,134,134,134,134, 91, 91,135,136,136,136,136,136,136,
- 91,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,
-137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,137,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
+167,168,167,168,167,168,167,168,109,109,109,109,109,109,109,109,
+109,174,174,174,174,174,174,174,174,174,174,174,174,174,174,174,
+174,174,174,174,174,174,174,174,174,174,174,174,174,174,174,174,
+174,174,174,174,174,174,174,109,109,175,176,176,176,176,176,176,
+109,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,
+177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,177,
/* block 11 */
-137,137,137,137,137,137,137,138, 91, 2,139, 91, 91, 91, 91, 91,
- 91,140,140,140,140,140,140,140,140,140,140,140,140,140,140,140,
-140,140,140,140,140,140,140,140,140,140,140,140,140,140,140,140,
-140,140,140,140,140,140,140,140,140,140,140,140,140,140,141,140,
-142,140,140,142,140,140,142,140, 91, 91, 91, 91, 91, 91, 91, 91,
-143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,
-143,143,143,143,143,143,143,143,143,143,143, 91, 91, 91, 91, 91,
-143,143,143,142,142, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+177,177,177,177,177,177,177,178,109, 4,179,109,109,109,109,180,
+109,181,181,181,181,181,181,181,181,181,181,181,181,181,181,181,
+181,181,181,181,181,181,181,181,181,181,181,181,181,181,181,181,
+181,181,181,181,181,181,181,181,181,181,181,181,181,181,182,181,
+183,181,181,183,181,181,183,181,109,109,109,109,109,109,109,109,
+184,184,184,184,184,184,184,184,184,184,184,184,184,184,184,184,
+184,184,184,184,184,184,184,184,184,184,184,109,109,109,109,109,
+184,184,184,183,183,109,109,109,109,109,109,109,109,109,109,109,
/* block 12 */
-144,144,144,144, 91, 91,145,145,145,146,146,147, 2,146,148,148,
-149,149,149,149,149,149,149,149,149,149,149, 2, 91, 91,146, 2,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
- 84,150,150,150,150,150,150,150,150,150,150, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86,149,149,149,149,149,149,149,149,149, 86,
- 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,146,146,146,146,150,150,
- 86,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
+185,185,185,185,185,109,186,186,186,187,187,188, 4,187,189,189,
+190,190,190,190,190,190,190,190,190,190,190, 4,109,109,187, 4,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+102,191,191,191,191,191,191,191,191,191,191,104,104,104,104,104,
+104,104,104,104,104,104,190,190,190,190,190,190,190,190,190,190,
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,187,187,187,187,191,191,
+104,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
/* block 13 */
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,146,150,149,149,149,149,149,149,149, 16,148,149,
-149,149,149,149,149,151,151,149,149,148,149,149,149,149,150,150,
-152,152,152,152,152,152,152,152,152,152,150,150,150,148,148,150,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,187,191,190,190,190,190,190,190,190, 22,189,190,
+190,190,190,190,190,192,192,190,190,189,190,190,190,190,191,191,
+193,193,193,193,193,193,193,193,193,193,191,191,191,189,189,191,
/* block 14 */
-153,153,153,153,153,153,153,153,153,153,153,153,153,153, 91,154,
-155,156,155,155,155,155,155,155,155,155,155,155,155,155,155,155,
-155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,155,
-156,156,156,156,156,156,156,156,156,156,156,156,156,156,156,156,
-156,156,156,156,156,156,156,156,156,156,156, 91, 91,155,155,155,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
+194,194,194,194,194,194,194,194,194,194,194,194,194,194,109,195,
+196,197,196,196,196,196,196,196,196,196,196,196,196,196,196,196,
+196,196,196,196,196,196,196,196,196,196,196,196,196,196,196,196,
+197,197,197,197,197,197,197,197,197,197,197,197,197,197,197,197,
+197,197,197,197,197,197,197,197,197,197,197,109,109,196,196,196,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
/* block 15 */
-157,157,157,157,157,157,157,157,157,157,157,157,157,157,157,157,
-157,157,157,157,157,157,157,157,157,157,157,157,157,157,157,157,
-157,157,157,157,157,157,158,158,158,158,158,158,158,158,158,158,
-158,157, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-159,159,159,159,159,159,159,159,159,159,160,160,160,160,160,160,
-160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,160,
-160,160,160,160,160,160,160,160,160,160,160,161,161,161,161,161,
-161,161,161,161,162,162,163,164,164,164,162, 91, 91, 91, 91, 91,
+198,198,198,198,198,198,198,198,198,198,198,198,198,198,198,198,
+198,198,198,198,198,198,198,198,198,198,198,198,198,198,198,198,
+198,198,198,198,198,198,199,199,199,199,199,199,199,199,199,199,
+199,198,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+200,200,200,200,200,200,200,200,200,200,201,201,201,201,201,201,
+201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,
+201,201,201,201,201,201,201,201,201,201,201,202,202,202,202,202,
+202,202,202,202,203,203,204,205,205,205,203,109,109,109,109,109,
/* block 16 */
-165,165,165,165,165,165,165,165,165,165,165,165,165,165,165,165,
-165,165,165,165,165,165,166,166,166,166,167,166,166,166,166,166,
-166,166,166,166,167,166,166,166,167,166,166,166,166,166, 91, 91,
-168,168,168,168,168,168,168,168,168,168,168,168,168,168,168, 91,
-169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,169,
-169,169,169,169,169,169,169,169,169,170,170,170, 91, 91,171, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+206,206,206,206,206,206,206,206,206,206,206,206,206,206,206,206,
+206,206,206,206,206,206,207,207,207,207,208,207,207,207,207,207,
+207,207,207,207,208,207,207,207,208,207,207,207,207,207,109,109,
+209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,109,
+210,210,210,210,210,210,210,210,210,210,210,210,210,210,210,210,
+210,210,210,210,210,210,210,210,210,211,211,211,109,109,212,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 17 */
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+191,109,191,191,191,191,191,191,191,191,191,191,191,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,190,190,190,190,190,190,190,190,190,190,190,190,
+190,190,190,190,190,190,190,190,190,190,190,190,190,190,190,109,
/* block 18 */
-172,172,172,173,174,174,174,174,174,174,174,174,174,174,174,174,
-174,174,174,174,174,174,174,174,174,174,174,174,174,174,174,174,
-174,174,174,174,174,174,174,174,174,174,174,174,174,174,174,174,
-174,174,174,174,174,174,174,174,174,174,172,173,172,174,173,173,
-173,172,172,172,172,172,172,172,172,173,173,173,173,172,173,173,
-174, 86, 86,172,172,172,172,172,174,174,174,174,174,174,174,174,
-174,174,172,172, 2, 2,175,175,175,175,175,175,175,175,175,175,
- 2,176,174,174,174,174,174,174, 91,174,174,174,174,174,174,174,
+213,213,213,214,215,215,215,215,215,215,215,215,215,215,215,215,
+215,215,215,215,215,215,215,215,215,215,215,215,215,215,215,215,
+215,215,215,215,215,215,215,215,215,215,215,215,215,215,215,215,
+215,215,215,215,215,215,215,215,215,215,213,214,213,215,214,214,
+214,213,213,213,213,213,213,213,213,214,214,214,214,213,214,214,
+215,104,104,213,213,213,213,213,215,215,215,215,215,215,215,215,
+215,215,213,213, 4, 4,216,216,216,216,216,216,216,216,216,216,
+217,218,215,215,215,215,215,215,109,215,215,215,215,215,215,215,
/* block 19 */
- 91,177,178,178, 91,179,179,179,179,179,179,179,179, 91, 91,179,
-179, 91, 91,179,179,179,179,179,179,179,179,179,179,179,179,179,
-179,179,179,179,179,179,179,179,179, 91,179,179,179,179,179,179,
-179, 91,179, 91, 91, 91,179,179,179,179, 91, 91,177,179,178,178,
-178,177,177,177,177, 91, 91,178,178, 91, 91,178,178,177,179, 91,
- 91, 91, 91, 91, 91, 91, 91,178, 91, 91, 91, 91,179,179, 91,179,
-179,179,177,177, 91, 91,180,180,180,180,180,180,180,180,180,180,
-179,179,181,181,182,182,182,182,182,182,183,181, 91, 91, 91, 91,
+109,219,220,220,109,221,221,221,221,221,221,221,221,109,109,221,
+221,109,109,221,221,221,221,221,221,221,221,221,221,221,221,221,
+221,221,221,221,221,221,221,221,221,109,221,221,221,221,221,221,
+221,109,221,109,109,109,221,221,221,221,109,109,219,221,222,220,
+220,219,219,219,219,109,109,220,220,109,109,220,220,219,221,109,
+109,109,109,109,109,109,109,222,109,109,109,109,221,221,109,221,
+221,221,219,219,109,109,223,223,223,223,223,223,223,223,223,223,
+221,221,224,224,225,225,225,225,225,225,226,224,109,109,109,109,
/* block 20 */
- 91,184,184,185, 91,186,186,186,186,186,186, 91, 91, 91, 91,186,
-186, 91, 91,186,186,186,186,186,186,186,186,186,186,186,186,186,
-186,186,186,186,186,186,186,186,186, 91,186,186,186,186,186,186,
-186, 91,186,186, 91,186,186, 91,186,186, 91, 91,184, 91,185,185,
-185,184,184, 91, 91, 91, 91,184,184, 91, 91,184,184,184, 91, 91,
- 91,184, 91, 91, 91, 91, 91, 91, 91,186,186,186,186, 91,186, 91,
- 91, 91, 91, 91, 91, 91,187,187,187,187,187,187,187,187,187,187,
-184,184,186,186,186,184, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+109,227,227,228,109,229,229,229,229,229,229,109,109,109,109,229,
+229,109,109,229,229,229,229,229,229,229,229,229,229,229,229,229,
+229,229,229,229,229,229,229,229,229,109,229,229,229,229,229,229,
+229,109,229,229,109,229,229,109,229,229,109,109,227,109,228,228,
+228,227,227,109,109,109,109,227,227,109,109,227,227,227,109,109,
+109,227,109,109,109,109,109,109,109,229,229,229,229,109,229,109,
+109,109,109,109,109,109,230,230,230,230,230,230,230,230,230,230,
+227,227,229,229,229,227,109,109,109,109,109,109,109,109,109,109,
/* block 21 */
- 91,188,188,189, 91,190,190,190,190,190,190,190,190,190, 91,190,
-190,190, 91,190,190,190,190,190,190,190,190,190,190,190,190,190,
-190,190,190,190,190,190,190,190,190, 91,190,190,190,190,190,190,
-190, 91,190,190, 91,190,190,190,190,190, 91, 91,188,190,189,189,
-189,188,188,188,188,188, 91,188,188,189, 91,189,189,188, 91, 91,
-190, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-190,190,188,188, 91, 91,191,191,191,191,191,191,191,191,191,191,
- 91,192, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+109,231,231,232,109,233,233,233,233,233,233,233,233,233,109,233,
+233,233,109,233,233,233,233,233,233,233,233,233,233,233,233,233,
+233,233,233,233,233,233,233,233,233,109,233,233,233,233,233,233,
+233,109,233,233,109,233,233,233,233,233,109,109,231,233,232,232,
+232,231,231,231,231,231,109,231,231,232,109,232,232,231,109,109,
+233,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+233,233,231,231,109,109,234,234,234,234,234,234,234,234,234,234,
+235,236,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 22 */
- 91,193,194,194, 91,195,195,195,195,195,195,195,195, 91, 91,195,
-195, 91, 91,195,195,195,195,195,195,195,195,195,195,195,195,195,
-195,195,195,195,195,195,195,195,195, 91,195,195,195,195,195,195,
-195, 91,195,195, 91,195,195,195,195,195, 91, 91,193,195,194,193,
-194,193,193,193,193, 91, 91,194,194, 91, 91,194,194,193, 91, 91,
- 91, 91, 91, 91, 91, 91,193,194, 91, 91, 91, 91,195,195, 91,195,
-195,195,193,193, 91, 91,196,196,196,196,196,196,196,196,196,196,
-197,195,198,198,198,198,198,198, 91, 91, 91, 91, 91, 91, 91, 91,
+109,237,238,238,109,239,239,239,239,239,239,239,239,109,109,239,
+239,109,109,239,239,239,239,239,239,239,239,239,239,239,239,239,
+239,239,239,239,239,239,239,239,239,109,239,239,239,239,239,239,
+239,109,239,239,109,239,239,239,239,239,109,109,237,239,240,237,
+238,237,237,237,237,109,109,238,238,109,109,238,238,237,109,109,
+109,109,109,109,109,109,237,240,109,109,109,109,239,239,109,239,
+239,239,237,237,109,109,241,241,241,241,241,241,241,241,241,241,
+242,239,243,243,243,243,243,243,109,109,109,109,109,109,109,109,
/* block 23 */
- 91, 91,199,200, 91,200,200,200,200,200,200, 91, 91, 91,200,200,
-200, 91,200,200,200,200, 91, 91, 91,200,200, 91,200, 91,200,200,
- 91, 91, 91,200,200, 91, 91, 91,200,200,200, 91, 91, 91,200,200,
-200,200,200,200,200,200,200,200,200,200, 91, 91, 91, 91,201,201,
-199,201,201, 91, 91, 91,201,201,201, 91,201,201,201,199, 91, 91,
-200, 91, 91, 91, 91, 91, 91,201, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91,202,202,202,202,202,202,202,202,202,202,
-203,203,203,204,204,204,204,204,204,205,204, 91, 91, 91, 91, 91,
+109,109,244,245,109,245,245,245,245,245,245,109,109,109,245,245,
+245,109,245,245,245,245,109,109,109,245,245,109,245,109,245,245,
+109,109,109,245,245,109,109,109,245,245,245,109,109,109,245,245,
+245,245,245,245,245,245,245,245,245,245,109,109,109,109,246,247,
+244,247,247,109,109,109,247,247,247,109,247,247,247,244,109,109,
+245,109,109,109,109,109,109,246,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,248,248,248,248,248,248,248,248,248,248,
+249,249,249,250,250,250,250,250,250,251,250,109,109,109,109,109,
/* block 24 */
- 91,206,206,206, 91,207,207,207,207,207,207,207,207, 91,207,207,
-207, 91,207,207,207,207,207,207,207,207,207,207,207,207,207,207,
-207,207,207,207,207,207,207,207,207, 91,207,207,207,207,207,207,
-207,207,207,207, 91,207,207,207,207,207, 91, 91, 91,207,208,208,
-208,206,206,206,206, 91,208,208,208, 91,208,208,208,208, 91, 91,
- 91, 91, 91, 91, 91,208,208, 91,207,207, 91, 91, 91, 91, 91, 91,
-207,207,208,208, 91, 91,209,209,209,209,209,209,209,209,209,209,
- 91, 91, 91, 91, 91, 91, 91, 91,210,210,210,210,210,210,210,211,
+109,252,252,252,109,253,253,253,253,253,253,253,253,109,253,253,
+253,109,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
+253,253,253,253,253,253,253,253,253,109,253,253,253,253,253,253,
+253,253,253,253,109,253,253,253,253,253,109,109,109,253,254,254,
+254,252,252,252,252,109,254,254,254,109,254,254,254,254,109,109,
+109,109,109,109,109,254,254,109,253,253,109,109,109,109,109,109,
+253,253,254,254,109,109,255,255,255,255,255,255,255,255,255,255,
+109,109,109,109,109,109,109,109,256,256,256,256,256,256,256,257,
/* block 25 */
- 91, 91,212,212, 91,213,213,213,213,213,213,213,213, 91,213,213,
-213, 91,213,213,213,213,213,213,213,213,213,213,213,213,213,213,
-213,213,213,213,213,213,213,213,213, 91,213,213,213,213,213,213,
-213,213,213,213, 91,213,213,213,213,213, 91, 91,214,213,212,214,
-212,212,212,212,212, 91,214,212,212, 91,212,212,214,214, 91, 91,
- 91, 91, 91, 91, 91,212,212, 91, 91, 91, 91, 91, 91, 91,213, 91,
-213,213,214,214, 91, 91,215,215,215,215,215,215,215,215,215,215,
- 91,213,213, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+109,109,258,258,109,259,259,259,259,259,259,259,259,109,259,259,
+259,109,259,259,259,259,259,259,259,259,259,259,259,259,259,259,
+259,259,259,259,259,259,259,259,259,109,259,259,259,259,259,259,
+259,259,259,259,109,259,259,259,259,259,109,109,260,259,258,260,
+258,258,261,258,258,109,260,258,258,109,258,258,260,260,109,109,
+109,109,109,109,109,261,261,109,109,109,109,109,109,109,259,109,
+259,259,260,260,109,109,262,262,262,262,262,262,262,262,262,262,
+109,259,259,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 26 */
- 91, 91,216,216, 91,217,217,217,217,217,217,217,217, 91,217,217,
-217, 91,217,217,217,217,217,217,217,217,217,217,217,217,217,217,
-217,217,217,217,217,217,217,217,217,217,217,217,217,217,217,217,
-217,217,217,217,217,217,217,217,217,217,217, 91, 91,217,216,216,
-216,218,218,218,218, 91,216,216,216, 91,216,216,216,218,217, 91,
- 91, 91, 91, 91, 91, 91, 91,216, 91, 91, 91, 91, 91, 91, 91, 91,
-217,217,218,218, 91, 91,219,219,219,219,219,219,219,219,219,219,
-220,220,220,220,220,220, 91, 91, 91,221,217,217,217,217,217,217,
+109,109,263,263,109,264,264,264,264,264,264,264,264,109,264,264,
+264,109,264,264,264,264,264,264,264,264,264,264,264,264,264,264,
+264,264,264,264,264,264,264,264,264,264,264,264,264,264,264,264,
+264,264,264,264,264,264,264,264,264,264,264,109,109,264,265,263,
+263,266,266,266,266,109,263,263,263,109,263,263,263,266,264,109,
+109,109,109,109,109,109,109,265,109,109,109,109,109,109,109,109,
+264,264,266,266,109,109,267,267,267,267,267,267,267,267,267,267,
+268,268,268,268,268,268,109,109,109,269,264,264,264,264,264,264,
/* block 27 */
- 91, 91,222,222, 91,223,223,223,223,223,223,223,223,223,223,223,
-223,223,223,223,223,223,223, 91, 91, 91,223,223,223,223,223,223,
-223,223,223,223,223,223,223,223,223,223,223,223,223,223,223,223,
-223,223, 91,223,223,223,223,223,223,223,223,223, 91,223, 91, 91,
-223,223,223,223,223,223,223, 91, 91, 91,224, 91, 91, 91, 91,222,
-222,222,224,224,224, 91,224, 91,222,222,222,222,222,222,222,222,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91,222,222,225, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+109,109,270,270,109,271,271,271,271,271,271,271,271,271,271,271,
+271,271,271,271,271,271,271,109,109,109,271,271,271,271,271,271,
+271,271,271,271,271,271,271,271,271,271,271,271,271,271,271,271,
+271,271,109,271,271,271,271,271,271,271,271,271,109,271,109,109,
+271,271,271,271,271,271,271,109,109,109,272,109,109,109,109,273,
+270,270,272,272,272,109,272,109,270,270,270,270,270,270,270,273,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,270,270,274,109,109,109,109,109,109,109,109,109,109,109,
/* block 28 */
- 91,226,226,226,226,226,226,226,226,226,226,226,226,226,226,226,
-226,226,226,226,226,226,226,226,226,226,226,226,226,226,226,226,
-226,226,226,226,226,226,226,226,226,226,226,226,226,226,226,226,
-226,227,226,226,227,227,227,227,227,227,227, 91, 91, 91, 91, 3,
-226,226,226,226,226,226,228,227,227,227,227,227,227,227,227,229,
-230,230,230,230,230,230,230,230,230,230,229,229, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+109,275,275,275,275,275,275,275,275,275,275,275,275,275,275,275,
+275,275,275,275,275,275,275,275,275,275,275,275,275,275,275,275,
+275,275,275,275,275,275,275,275,275,275,275,275,275,275,275,275,
+275,276,275,277,276,276,276,276,276,276,276,109,109,109,109, 5,
+275,275,275,275,275,275,278,276,276,276,276,276,276,276,276,279,
+280,280,280,280,280,280,280,280,280,280,279,279,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 29 */
- 91,231,231, 91,231, 91, 91,231,231, 91,231, 91, 91,231, 91, 91,
- 91, 91, 91, 91,231,231,231,231, 91,231,231,231,231,231,231,231,
- 91,231,231,231, 91,231, 91,231, 91, 91,231,231, 91,231,231,231,
-231,232,231,231,232,232,232,232,232,232, 91,232,232,231, 91, 91,
-231,231,231,231,231, 91,233, 91,232,232,232,232,232,232, 91, 91,
-234,234,234,234,234,234,234,234,234,234, 91, 91,231,231, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+109,281,281,109,281,109,109,281,281,109,281,109,109,281,109,109,
+109,109,109,109,281,281,281,281,109,281,281,281,281,281,281,281,
+109,281,281,281,109,281,109,281,109,109,281,281,109,281,281,281,
+281,282,281,283,282,282,282,282,282,282,109,282,282,281,109,109,
+281,281,281,281,281,109,284,109,282,282,282,282,282,282,109,109,
+285,285,285,285,285,285,285,285,285,285,109,109,281,281,281,281,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 30 */
-235,236,236,236,237,237,237,237,237,237,237,237,237,237,237,237,
-237,237,237,236,236,236,236,236,238,238,236,236,236,236,236,236,
-239,239,239,239,239,239,239,239,239,239,240,240,240,240,240,240,
-240,240,240,240,236,238,236,238,236,238,241,242,241,242,243,243,
-235,235,235,235,235,235,235,235, 91,235,235,235,235,235,235,235,
-235,235,235,235,235,235,235,235,235,235,235,235,235,235,235,235,
-235,235,235,235,235,235,235,235,235,235,235,235,235, 91, 91, 91,
- 91,238,238,238,238,238,238,238,238,238,238,238,238,238,238,243,
+286,287,287,287,288,288,288,288,288,288,288,288,288,288,288,288,
+288,288,288,287,288,287,287,287,289,289,287,287,287,287,287,287,
+290,290,290,290,290,290,290,290,290,290,291,291,291,291,291,291,
+291,291,291,291,287,289,287,289,287,289,292,293,292,293,294,294,
+286,286,286,286,286,286,286,286,109,286,286,286,286,286,286,286,
+286,286,286,286,286,286,286,286,286,286,286,286,286,286,286,286,
+286,286,286,286,286,286,286,286,286,286,286,286,286,109,109,109,
+109,289,289,289,289,289,289,289,289,289,289,289,289,289,289,294,
/* block 31 */
-238,238,238,238,238,237,238,238,235,235,235,235,235,238,238,238,
-238,238,238,238,238,238,238,238, 91,238,238,238,238,238,238,238,
-238,238,238,238,238,238,238,238,238,238,238,238,238,238,238,238,
-238,238,238,238,238,238,238,238,238,238,238,238,238, 91,236,236,
-236,236,236,236,236,236,238,236,236,236,236,236,236, 91,236,236,
-237,237,237,237,237, 13, 13, 13, 13,237,237, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+289,289,289,289,289,288,289,289,286,286,286,286,286,289,289,289,
+289,289,289,289,289,289,289,289,109,289,289,289,289,289,289,289,
+289,289,289,289,289,289,289,289,289,289,289,289,289,289,289,289,
+289,289,289,289,289,289,289,289,289,289,289,289,289,109,287,287,
+287,287,287,287,287,287,289,287,287,287,287,287,287,109,287,287,
+288,288,288,288,288, 19, 19, 19, 19,288,288,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 32 */
-244,244,244,244,244,244,244,244,244,244,244,244,244,244,244,244,
-244,244,244,244,244,244,244,244,244,244,244,244,244,244,244,244,
-244,244,244,244,244,244,244,244,244,244,244,245,245,246,246,246,
-246,245,246,246,246,246,246,246,245,246,246,245,245,246,246,244,
-247,247,247,247,247,247,247,247,247,247,248,248,248,248,248,248,
-244,244,244,244,244,244,245,245,246,246,244,244,244,244,246,246,
-246,244,245,245,245,244,244,245,245,245,245,245,245,245,244,244,
-244,246,246,246,246,244,244,244,244,244,244,244,244,244,244,244,
+295,295,295,295,295,295,295,295,295,295,295,295,295,295,295,295,
+295,295,295,295,295,295,295,295,295,295,295,295,295,295,295,295,
+295,295,295,295,295,295,295,295,295,295,295,296,296,297,297,297,
+297,298,297,297,297,297,297,297,296,297,297,298,298,297,297,295,
+299,299,299,299,299,299,299,299,299,299,300,300,300,300,300,300,
+295,295,295,295,295,295,298,298,297,297,295,295,295,295,297,297,
+297,295,296,296,296,295,295,296,296,296,296,296,296,296,295,295,
+295,297,297,297,297,295,295,295,295,295,295,295,295,295,295,295,
/* block 33 */
-244,244,246,245,245,246,246,245,245,245,245,245,245,246,244,245,
-247,247,247,247,247,247,247,247,247,247,245,245,245,246,249,249,
-250,250,250,250,250,250,250,250,250,250,250,250,250,250,250,250,
-250,250,250,250,250,250,250,250,250,250,250,250,250,250,250,250,
-250,250,250,250,250,250, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-251,251,251,251,251,251,251,251,251,251,251,251,251,251,251,251,
-251,251,251,251,251,251,251,251,251,251,251,251,251,251,251,251,
-251,251,251,251,251,251,251,251,251,251,251, 2,252, 91, 91, 91,
+295,295,297,296,298,297,297,296,296,296,296,296,296,297,295,296,
+299,299,299,299,299,299,299,299,299,299,296,296,296,297,301,301,
+302,302,302,302,302,302,302,302,302,302,302,302,302,302,302,302,
+302,302,302,302,302,302,302,302,302,302,302,302,302,302,302,302,
+302,302,302,302,302,302,109,302,109,109,109,109,109,302,109,109,
+303,303,303,303,303,303,303,303,303,303,303,303,303,303,303,303,
+303,303,303,303,303,303,303,303,303,303,303,303,303,303,303,303,
+303,303,303,303,303,303,303,303,303,303,303, 4,304,303,303,303,
/* block 34 */
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
+305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,
+305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,
+305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,
+305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,
+305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,
+305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,
+306,306,306,306,306,306,306,306,306,306,306,306,306,306,306,306,
+306,306,306,306,306,306,306,306,306,306,306,306,306,306,306,306,
/* block 35 */
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254,254,254, 91,254,254,254,254, 91, 91,
-254,254,254,254,254,254,254, 91,254, 91,254,254,254,254, 91, 91,
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
+306,306,306,306,306,306,306,306,306,306,306,306,306,306,306,306,
+306,306,306,306,306,306,306,306,306,306,306,306,306,306,306,306,
+306,306,306,306,306,306,306,306,307,307,307,307,307,307,307,307,
+307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,
+307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,
+307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,
+307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,
+307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,
/* block 36 */
-254,254,254,254,254,254,254,254,254, 91,254,254,254,254, 91, 91,
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254, 91,254,254,254,254, 91, 91,254,254,254,254,254,254,254, 91,
-254, 91,254,254,254,254, 91, 91,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254, 91,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,308,308,109,308,308,308,308,109,109,
+308,308,308,308,308,308,308,109,308,109,308,308,308,308,109,109,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
/* block 37 */
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254, 91,254,254,254,254, 91, 91,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254,254,254,254,254, 91, 91,255,255,255,
-256,257,257,257,257,257,257,257,257,258,258,258,258,258,258,258,
-258,258,258,258,258,258,258,258,258,258,258,258,258, 91, 91, 91,
+308,308,308,308,308,308,308,308,308,109,308,308,308,308,109,109,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,109,308,308,308,308,109,109,308,308,308,308,308,308,308,109,
+308,109,308,308,308,308,109,109,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,109,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
/* block 38 */
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-256,256,256,256,256,256,256,256,256,256, 91, 91, 91, 91, 91, 91,
-259,259,259,259,259,259,259,259,259,259,259,259,259,259,259,259,
-259,259,259,259,259,259,259,259,259,259,259,259,259,259,259,259,
-259,259,259,259,259,259,259,259,259,259,259,259,259,259,259,259,
-259,259,259,259,259,259,259,259,259,259,259,259,259,259,259,259,
-259,259,259,259,259,259,259,259,259,259,259,259,259,259,259,259,
-259,259,259,259,259, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,109,308,308,308,308,109,109,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,308,308,308,308,109,109,309,309,309,
+310,310,310,310,310,310,310,310,310,311,311,311,311,311,311,311,
+311,311,311,311,311,311,311,311,311,311,311,311,311,109,109,109,
/* block 39 */
-260,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+312,312,312,312,312,312,312,312,312,312,109,109,109,109,109,109,
+313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,
+313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,
+313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,
+313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,
+313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,313,
+313,313,313,313,313,109,109,109,109,109,109,109,109,109,109,109,
/* block 40 */
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
+314,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
/* block 41 */
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,262,262,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
/* block 42 */
-263,264,264,264,264,264,264,264,264,264,264,264,264,264,264,264,
-264,264,264,264,264,264,264,264,264,264,264,265,266, 91, 91, 91,
-267,267,267,267,267,267,267,267,267,267,267,267,267,267,267,267,
-267,267,267,267,267,267,267,267,267,267,267,267,267,267,267,267,
-267,267,267,267,267,267,267,267,267,267,267,267,267,267,267,267,
-267,267,267,267,267,267,267,267,267,267,267,267,267,267,267,267,
-267,267,267,267,267,267,267,267,267,267,267, 2, 2, 2,268,268,
-268, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,316,316,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
/* block 43 */
-269,269,269,269,269,269,269,269,269,269,269,269,269, 91,269,269,
-269,269,270,270,270, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-271,271,271,271,271,271,271,271,271,271,271,271,271,271,271,271,
-271,271,272,272,272, 2, 2, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-273,273,273,273,273,273,273,273,273,273,273,273,273,273,273,273,
-273,273,274,274, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-275,275,275,275,275,275,275,275,275,275,275,275,275, 91,275,275,
-275, 91,276,276, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+317,318,318,318,318,318,318,318,318,318,318,318,318,318,318,318,
+318,318,318,318,318,318,318,318,318,318,318,319,320,109,109,109,
+321,321,321,321,321,321,321,321,321,321,321,321,321,321,321,321,
+321,321,321,321,321,321,321,321,321,321,321,321,321,321,321,321,
+321,321,321,321,321,321,321,321,321,321,321,321,321,321,321,321,
+321,321,321,321,321,321,321,321,321,321,321,321,321,321,321,321,
+321,321,321,321,321,321,321,321,321,321,321, 4, 4, 4,322,322,
+322,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 44 */
-277,277,277,277,277,277,277,277,277,277,277,277,277,277,277,277,
-277,277,277,277,277,277,277,277,277,277,277,277,277,277,277,277,
-277,277,277,277,277,277,277,277,277,277,277,277,277,277,277,277,
-277,277,277,277,278,278,279,280,280,280,280,280,280,280,279,279,
-279,279,279,279,279,279,280,279,279,280,280,280,280,280,280,280,
-280,280,280,280,281,281,281,282,281,281,281,283,277,280, 91, 91,
-284,284,284,284,284,284,284,284,284,284, 91, 91, 91, 91, 91, 91,
-285,285,285,285,285,285,285,285,285,285, 91, 91, 91, 91, 91, 91,
+323,323,323,323,323,323,323,323,323,323,323,323,323,109,323,323,
+323,323,324,324,324,109,109,109,109,109,109,109,109,109,109,109,
+325,325,325,325,325,325,325,325,325,325,325,325,325,325,325,325,
+325,325,326,326,326, 4, 4,109,109,109,109,109,109,109,109,109,
+327,327,327,327,327,327,327,327,327,327,327,327,327,327,327,327,
+327,327,328,328,109,109,109,109,109,109,109,109,109,109,109,109,
+329,329,329,329,329,329,329,329,329,329,329,329,329,109,329,329,
+329,109,330,330,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 45 */
-286,286, 2, 2,286, 2,287,286,286,286,286,288,288,288,289, 91,
-290,290,290,290,290,290,290,290,290,290, 91, 91, 91, 91, 91, 91,
-291,291,291,291,291,291,291,291,291,291,291,291,291,291,291,291,
-291,291,291,291,291,291,291,291,291,291,291,291,291,291,291,291,
-291,291,291,292,291,291,291,291,291,291,291,291,291,291,291,291,
-291,291,291,291,291,291,291,291,291,291,291,291,291,291,291,291,
-291,291,291,291,291,291,291,291,291,291,291,291,291,291,291,291,
-291,291,291,291,291,291,291,291, 91, 91, 91, 91, 91, 91, 91, 91,
+331,331,331,331,331,331,331,331,331,331,331,331,331,331,331,331,
+331,331,331,331,331,331,331,331,331,331,331,331,331,331,331,331,
+331,331,331,331,331,331,331,331,331,331,331,331,331,331,331,331,
+331,331,331,331,332,332,333,332,332,332,332,332,332,332,333,333,
+333,333,333,333,333,333,332,333,333,332,332,332,332,332,332,332,
+332,332,332,332,334,334,334,335,334,334,334,336,331,332,109,109,
+337,337,337,337,337,337,337,337,337,337,109,109,109,109,109,109,
+338,338,338,338,338,338,338,338,338,338,109,109,109,109,109,109,
/* block 46 */
-291,291,291,291,291,291,291,291,291,291,291,291,291,291,291,291,
-291,291,291,291,291,291,291,291,291,291,291,291,291,291,291,291,
-291,291,291,291,291,291,291,291,291,288,291, 91, 91, 91, 91, 91,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,261,
-261,261,261,261,261,261, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+339,339, 4, 4,339, 4,340,339,339,339,339,341,341,341,342,109,
+343,343,343,343,343,343,343,343,343,343,109,109,109,109,109,109,
+344,344,344,344,344,344,344,344,344,344,344,344,344,344,344,344,
+344,344,344,344,344,344,344,344,344,344,344,344,344,344,344,344,
+344,344,344,345,344,344,344,344,344,344,344,344,344,344,344,344,
+344,344,344,344,344,344,344,344,344,344,344,344,344,344,344,344,
+344,344,344,344,344,344,344,344,344,344,344,344,344,344,344,344,
+344,344,344,344,344,344,344,344,109,109,109,109,109,109,109,109,
/* block 47 */
-293,293,293,293,293,293,293,293,293,293,293,293,293,293,293,293,
-293,293,293,293,293,293,293,293,293,293,293,293,293, 91, 91, 91,
-294,294,294,295,295,295,295,294,294,295,295,295, 91, 91, 91, 91,
-295,295,294,295,295,295,295,295,295,294,294,294, 91, 91, 91, 91,
-296, 91, 91, 91,297,297,298,298,298,298,298,298,298,298,298,298,
-299,299,299,299,299,299,299,299,299,299,299,299,299,299,299,299,
-299,299,299,299,299,299,299,299,299,299,299,299,299,299, 91, 91,
-299,299,299,299,299, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+344,344,344,344,344,344,344,344,344,344,344,344,344,344,344,344,
+344,344,344,344,344,344,344,344,344,344,344,344,344,344,344,344,
+344,344,344,344,344,344,344,344,344,341,344,109,109,109,109,109,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,315,
+315,315,315,315,315,315,109,109,109,109,109,109,109,109,109,109,
/* block 48 */
-300,300,300,300,300,300,300,300,300,300,300,300,300,300,300,300,
-300,300,300,300,300,300,300,300,300,300,300,300,300,300,300,300,
-300,300,300,300,300,300,300,300,300,300,300,300, 91, 91, 91, 91,
-301,301,301,301,301,301,301,301,301,301,301,301,301,301,301,301,
-301,300,300,300,300,300,300,300,301,301, 91, 91, 91, 91, 91, 91,
-302,302,302,302,302,302,302,302,302,302,303, 91, 91, 91,304,304,
-305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,
-305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,
+346,346,346,346,346,346,346,346,346,346,346,346,346,346,346,346,
+346,346,346,346,346,346,346,346,346,346,346,346,346,109,109,109,
+347,347,347,348,348,348,348,347,347,348,348,348,109,109,109,109,
+348,348,347,348,348,348,348,348,348,347,347,347,109,109,109,109,
+349,109,109,109,350,350,351,351,351,351,351,351,351,351,351,351,
+352,352,352,352,352,352,352,352,352,352,352,352,352,352,352,352,
+352,352,352,352,352,352,352,352,352,352,352,352,352,352,109,109,
+352,352,352,352,352,109,109,109,109,109,109,109,109,109,109,109,
/* block 49 */
-306,306,306,306,306,306,306,306,306,306,306,306,306,306,306,306,
-306,306,306,306,306,306,306,307,307,308,308,308, 91, 91,309,309,
-310,310,310,310,310,310,310,310,310,310,310,310,310,310,310,310,
-310,310,310,310,310,310,310,310,310,310,310,310,310,310,310,310,
-310,310,310,310,310,310,310,310,310,310,310,310,310,310,310,310,
-310,310,310,310,310,311,312,311,312,312,312,312,312,312,312, 91,
-312,311,312,311,311,312,312,312,312,312,312,312,312,311,311,311,
-311,311,311,312,312,312,312,312,312,312,312,312,312, 91, 91,312,
+353,353,353,353,353,353,353,353,353,353,353,353,353,353,353,353,
+353,353,353,353,353,353,353,353,353,353,353,353,353,353,353,353,
+353,353,353,353,353,353,353,353,353,353,353,353,109,109,109,109,
+354,354,354,354,354,355,355,355,354,354,355,354,354,354,354,354,
+354,353,353,353,353,353,353,353,354,354,109,109,109,109,109,109,
+356,356,356,356,356,356,356,356,356,356,357,109,109,109,358,358,
+359,359,359,359,359,359,359,359,359,359,359,359,359,359,359,359,
+359,359,359,359,359,359,359,359,359,359,359,359,359,359,359,359,
/* block 50 */
-313,313,313,313,313,313,313,313,313,313, 91, 91, 91, 91, 91, 91,
-313,313,313,313,313,313,313,313,313,313, 91, 91, 91, 91, 91, 91,
-314,314,314,314,314,314,314,315,314,314,314,314,314,314, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+360,360,360,360,360,360,360,360,360,360,360,360,360,360,360,360,
+360,360,360,360,360,360,360,361,361,362,362,362,109,109,363,363,
+364,364,364,364,364,364,364,364,364,364,364,364,364,364,364,364,
+364,364,364,364,364,364,364,364,364,364,364,364,364,364,364,364,
+364,364,364,364,364,364,364,364,364,364,364,364,364,364,364,364,
+364,364,364,364,364,365,366,365,366,366,366,366,366,366,366,109,
+366,367,366,367,367,366,366,366,366,366,366,366,366,365,365,365,
+365,365,365,366,366,366,366,366,366,366,366,366,366,109,109,366,
/* block 51 */
-316,316,316,316,317,318,318,318,318,318,318,318,318,318,318,318,
-318,318,318,318,318,318,318,318,318,318,318,318,318,318,318,318,
-318,318,318,318,318,318,318,318,318,318,318,318,318,318,318,318,
-318,318,318,318,316,317,316,316,316,316,316,317,316,317,317,317,
-317,317,316,317,317,318,318,318,318,318,318,318, 91, 91, 91, 91,
-319,319,319,319,319,319,319,319,319,319,320,320,320,320,320,320,
-320,321,321,321,321,321,321,321,321,321,321,316,316,316,316,316,
-316,316,316,316,321,321,321,321,321,321,321,321,321, 91, 91, 91,
+368,368,368,368,368,368,368,368,368,368,109,109,109,109,109,109,
+368,368,368,368,368,368,368,368,368,368,109,109,109,109,109,109,
+369,369,369,369,369,369,369,370,369,369,369,369,369,369,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 52 */
-322,322,323,324,324,324,324,324,324,324,324,324,324,324,324,324,
-324,324,324,324,324,324,324,324,324,324,324,324,324,324,324,324,
-324,323,322,322,322,322,323,323,322,322,323, 91, 91, 91,324,324,
-325,325,325,325,325,325,325,325,325,325, 91, 91, 91, 91, 91, 91,
-326,326,326,326,326,326,326,326,326,326,326,326,326,326,326,326,
-326,326,326,326,326,326,326,326,326,326,326,326,326,326,326,326,
-326,326,326,326,326,326,327,328,327,327,328,328,328,327,328,327,
-327,327,328,328, 91, 91, 91, 91, 91, 91, 91, 91,329,329,329,329,
+371,371,371,371,372,373,373,373,373,373,373,373,373,373,373,373,
+373,373,373,373,373,373,373,373,373,373,373,373,373,373,373,373,
+373,373,373,373,373,373,373,373,373,373,373,373,373,373,373,373,
+373,373,373,373,371,372,371,371,371,371,371,372,371,372,372,372,
+372,372,371,372,372,373,373,373,373,373,373,373,109,109,109,109,
+374,374,374,374,374,374,374,374,374,374,375,375,375,375,375,375,
+375,376,376,376,376,376,376,376,376,376,376,371,371,371,371,371,
+371,371,371,371,376,376,376,376,376,376,376,376,376,109,109,109,
/* block 53 */
-330,330,330,330,330,330,330,330,330,330,330,330,330,330,330,330,
-330,330,330,330,330,330,330,330,330,330,330,330,330,330,330,330,
-330,330,330,330,331,331,331,331,331,331,331,331,332,332,332,332,
-332,332,332,332,331,331,332,332, 91, 91, 91,333,333,333,333,333,
-334,334,334,334,334,334,334,334,334,334, 91, 91, 91,330,330,330,
-335,335,335,335,335,335,335,335,335,335,336,336,336,336,336,336,
-336,336,336,336,336,336,336,336,336,336,336,336,336,336,336,336,
-336,336,336,336,336,336,336,336,337,337,337,337,337,337,338,338,
+377,377,378,379,379,379,379,379,379,379,379,379,379,379,379,379,
+379,379,379,379,379,379,379,379,379,379,379,379,379,379,379,379,
+379,378,377,377,377,377,378,378,377,377,378,377,378,378,379,379,
+380,380,380,380,380,380,380,380,380,380,379,379,379,379,379,379,
+381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,
+381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,
+381,381,381,381,381,381,382,383,382,382,383,383,383,382,383,382,
+382,382,383,383,109,109,109,109,109,109,109,109,384,384,384,384,
/* block 54 */
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 86, 86, 86, 2, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86,339, 86, 86, 86, 86, 86, 86, 86,340,340,340,340, 86,340,340,
-340,340,339, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+385,385,385,385,385,385,385,385,385,385,385,385,385,385,385,385,
+385,385,385,385,385,385,385,385,385,385,385,385,385,385,385,385,
+385,385,385,385,386,386,386,386,386,386,386,386,387,387,387,387,
+387,387,387,387,386,386,387,387,109,109,109,388,388,388,388,388,
+389,389,389,389,389,389,389,389,389,389,109,109,109,385,385,385,
+390,390,390,390,390,390,390,390,390,390,391,391,391,391,391,391,
+391,391,391,391,391,391,391,391,391,391,391,391,391,391,391,391,
+391,391,391,391,391,391,391,391,392,392,392,392,392,392,393,393,
/* block 55 */
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 98, 98, 98, 98, 98,341, 83, 83, 83, 83,
- 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83,
- 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83,
- 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 92, 92, 92,
- 92, 92, 14, 14, 14, 14, 98, 98, 98, 98, 98, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14,342,343, 14, 14, 14,344, 14, 14,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+394,394,394,394,394,394,394,394,109,109,109,109,109,109,109,109,
+104,104,104, 4,104,104,104,104,104,104,104,104,104,104,104,104,
+104,395,104,104,104,104,104,104,104,396,396,396,396,104,396,396,
+396,396,395,395,104,396,396,109,109,109,109,109,109,109,109,109,
/* block 56 */
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 83, 83, 83, 83, 83,
- 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83,
- 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 92,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 86, 86, 86, 86,
+ 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
+ 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
+ 33, 33, 33, 33, 33, 33,116,116,116,116,116,397,101,101,101,101,
+101,101,101,101,101,101,101,101,101,101,101,101,101,101,101,101,
+101,101,101,101,101,101,101,101,101,101,101,101,101,101,101,101,
+101,101,101,101,101,101,101,101,101,101,101,101,101,110,110,110,
+110,110,101,101,101,101,110,110,110,110,110, 33, 33, 33, 33, 33,
+ 33, 33, 33, 33, 33, 33, 33, 33,398,399, 33, 33, 33,400, 33, 33,
/* block 57 */
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
+ 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,
+ 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33,101,101,101,101,101,
+101,101,101,101,101,101,101,101,101,101,101,101,101,101,101,101,
+101,101,101,101,101,101,101,101,101,101,101,101,101,101,101,110,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,104,104,104,104,
/* block 58 */
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 14, 14, 14, 14, 14,345, 14, 14,346, 14,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+401,402, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
/* block 59 */
-347,347,347,347,347,347,347,347,348,348,348,348,348,348,348,348,
-347,347,347,347,347,347, 91, 91,348,348,348,348,348,348, 91, 91,
-347,347,347,347,347,347,347,347,348,348,348,348,348,348,348,348,
-347,347,347,347,347,347,347,347,348,348,348,348,348,348,348,348,
-347,347,347,347,347,347, 91, 91,348,348,348,348,348,348, 91, 91,
- 98,347, 98,347, 98,347, 98,347, 91,348, 91,348, 91,348, 91,348,
-347,347,347,347,347,347,347,347,348,348,348,348,348,348,348,348,
-349,349,350,350,350,350,351,351,352,352,353,353,354,354, 91, 91,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 33, 33, 33, 33, 33,403, 33, 33,404, 33,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
/* block 60 */
-347,347,347,347,347,347,347,347,355,355,355,355,355,355,355,355,
-347,347,347,347,347,347,347,347,355,355,355,355,355,355,355,355,
-347,347,347,347,347,347,347,347,355,355,355,355,355,355,355,355,
-347,347, 98,356, 98, 91, 98, 98,348,348,357,357,358, 90,359, 90,
- 90, 90, 98,356, 98, 91, 98, 98,360,360,360,360,358, 90, 90, 90,
-347,347, 98, 98, 91, 91, 98, 98,348,348,361,361, 91, 90, 90, 90,
-347,347, 98, 98, 98,117, 98, 98,348,348,362,362,121, 90, 90, 90,
- 91, 91, 98,356, 98, 91, 98, 98,363,363,364,364,358, 90, 90, 91,
+405,405,405,405,405,405,405,405,406,406,406,406,406,406,406,406,
+405,405,405,405,405,405,109,109,406,406,406,406,406,406,109,109,
+405,405,405,405,405,405,405,405,406,406,406,406,406,406,406,406,
+405,405,405,405,405,405,405,405,406,406,406,406,406,406,406,406,
+405,405,405,405,405,405,109,109,406,406,406,406,406,406,109,109,
+116,405,116,405,116,405,116,405,109,406,109,406,109,406,109,406,
+405,405,405,405,405,405,405,405,406,406,406,406,406,406,406,406,
+407,407,408,408,408,408,409,409,410,410,411,411,412,412,109,109,
/* block 61 */
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 16,365,365, 16, 16,
- 7, 7, 7, 7, 7, 7, 2, 2, 15, 19, 4, 15, 15, 19, 4, 15,
- 2, 2, 2, 2, 2, 2, 2, 2,366,367, 16, 16, 16, 16, 16, 1,
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 15, 19, 2, 2, 2, 2, 11,
- 11, 2, 2, 2, 6, 4, 5, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 6, 2, 11, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1,
- 16, 16, 16, 16, 16, 91, 91, 91, 91, 91, 16, 16, 16, 16, 16, 16,
- 17, 83, 91, 91, 17, 17, 17, 17, 17, 17, 6, 6, 6, 4, 5, 83,
+405,405,405,405,405,405,405,405,413,413,413,413,413,413,413,413,
+405,405,405,405,405,405,405,405,413,413,413,413,413,413,413,413,
+405,405,405,405,405,405,405,405,413,413,413,413,413,413,413,413,
+405,405,116,414,116,109,116,116,406,406,415,415,416,108,417,108,
+108,108,116,414,116,109,116,116,418,418,418,418,416,108,108,108,
+405,405,116,116,109,109,116,116,406,406,419,419,109,108,108,108,
+405,405,116,116,116,157,116,116,406,406,420,420,161,108,108,108,
+109,109,116,414,116,109,116,116,421,421,422,422,416,108,108,109,
/* block 62 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 6, 6, 6, 4, 5, 91,
- 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 83, 91, 91, 91,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,368,368,368,
-368, 86,368,368,368, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+ 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 22,423,423, 22, 22,
+ 9, 9, 9, 9, 9, 9, 4, 4, 21, 25, 6, 21, 21, 25, 6, 21,
+ 4, 4, 4, 4, 4, 4, 4, 4,424,425, 22, 22, 22, 22, 22, 3,
+ 4, 4, 4, 4, 4, 4, 4, 4, 4, 21, 25, 4, 4, 4, 4, 15,
+ 15, 4, 4, 4, 8, 6, 7, 4, 4, 4, 4, 4, 4, 4, 4, 4,
+ 4, 4, 8, 4, 15, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 3,
+ 22, 22, 22, 22, 22,426,426,426,426,426, 22, 22, 22, 22, 22, 22,
+ 23,101,109,109, 23, 23, 23, 23, 23, 23, 8, 8, 8, 6, 7,101,
/* block 63 */
- 13, 13,369, 13, 13, 13, 13,369, 13, 13,370,369,369,369,370,370,
-369,369,369,370, 13,369, 13, 13, 6,369,369,369,369,369, 13, 13,
- 13, 13, 13, 13,369, 13,371, 13,369, 13,372,373,369,369, 13,370,
-369,369,374,369,370,340,340,340,340,370, 13, 13,370,370,369,369,
- 6, 6, 6, 6, 6,369,370,370,370,370, 13, 6, 13, 13,375, 13,
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
-376,376,376,376,376,376,376,376,376,376,376,376,376,376,376,376,
-377,377,377,377,377,377,377,377,377,377,377,377,377,377,377,377,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 8, 8, 8, 6, 7,109,
+101,101,101,101,101,101,101,101,101,101,101,101,101,109,109,109,
+ 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
+ 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+104,104,104,104,104,104,104,104,104,104,104,104,104,427,427,427,
+427,104,427,427,427,104,104,104,104,104,104,104,104,104,104,104,
+104,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 64 */
-378,378,378, 21, 22,378,378,378,378, 17, 91, 91, 91, 91, 91, 91,
- 6, 6, 6, 6, 6, 13, 13, 13, 13, 13, 6, 6, 13, 13, 13, 13,
- 6, 13, 13, 6, 13, 13, 6, 13, 13, 13, 13, 13, 13, 13, 6, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 6, 6,
- 13, 13, 6, 13, 6, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
+ 19, 19,428, 19, 19, 19, 19,428, 19, 19,429,428,428,428,429,429,
+428,428,428,429, 19,428, 19, 19, 8,428,428,428,428,428, 19, 19,
+ 19, 19, 19, 19,428, 19,430, 19,428, 19,431,432,428,428, 19,429,
+428,428,433,428,429,396,396,396,396,429, 19, 19,429,429,428,428,
+ 8, 8, 8, 8, 8,428,429,429,429,429, 19, 8, 19, 19,434, 19,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+435,435,435,435,435,435,435,435,435,435,435,435,435,435,435,435,
+436,436,436,436,436,436,436,436,436,436,436,436,436,436,436,436,
/* block 65 */
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
+437,437,437, 30, 31,437,437,437,437, 23,109,109,109,109,109,109,
+ 8, 8, 8, 8, 8, 19, 19, 19, 19, 19, 8, 8, 19, 19, 19, 19,
+ 8, 19, 19, 8, 19, 19, 8, 19, 19, 19, 19, 19, 19, 19, 8, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 8, 8,
+ 19, 19, 8, 19, 8, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
/* block 66 */
- 13, 13, 13, 13, 13, 13, 13, 13, 6, 6, 6, 6, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 6, 6, 13, 13, 13, 13, 13, 13, 13, 4, 5, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 6, 13, 13, 13,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
/* block 67 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 6, 6, 6, 6,
- 6, 6, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+ 19, 19, 19, 19, 19, 19, 19, 19, 8, 8, 8, 8, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 8, 8, 19, 19, 19, 19, 19, 19, 19, 6, 7, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 8, 19, 19, 19,
/* block 68 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 8, 8, 8, 8,
+ 8, 8, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 69 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13,379,379,379,379,379,379,379,379,379,379,
-379,379,379,379,379,379,379,379,379,379,379,379,379,379,379,379,
-380,380,380,380,380,380,380,380,380,380,380,380,380,380,380,380,
-380,380,380,380,380,380,380,380,380,380, 17, 17, 17, 17, 17, 17,
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
/* block 70 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19,438,438,438,438,438,438,438,438,438,438,
+438,438,438,438,438,438,438,438,438,438,438,438,438,438,438,438,
+439,439,439,439,439,439,439,439,439,439,439,439,439,439,439,439,
+439,439,439,439,439,439,439,439,439,439, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
/* block 71 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 6, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 6, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 6, 6, 6, 6, 6, 6, 6, 6,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
/* block 72 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 6,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 8, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 8, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 8, 8, 8, 8, 8, 8, 8, 8,
/* block 73 */
- 91, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 4, 5, 4, 5, 4, 5, 4, 5,
- 4, 5, 4, 5, 4, 5, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 8,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
/* block 74 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
- 17, 17, 17, 17, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 6, 6, 6, 6, 6, 4, 5, 6, 6, 6, 6, 91, 6, 91, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 4, 5, 4, 5, 4, 5, 4, 5, 4, 5,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
+109, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 6, 7, 6, 7, 6, 7, 6, 7,
+ 6, 7, 6, 7, 6, 7, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
/* block 75 */
-381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,
-381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,
-381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,
-381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,
-381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,
-381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,
-381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,
-381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,381,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 8, 8, 8, 8, 8, 6, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 6, 7, 6, 7, 6, 7, 6, 7, 6, 7,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
/* block 76 */
- 6, 6, 6, 4, 5, 4, 5, 4, 5, 4, 5, 4, 5, 4, 5, 4,
- 5, 4, 5, 4, 5, 4, 5, 4, 5, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 4, 5, 4, 5, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 4, 5, 6, 6,
+440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,
+440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,
+440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,
+440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,
+440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,
+440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,
+440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,
+440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,440,
/* block 77 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
- 6, 6, 6, 6, 6, 13, 13, 6, 6, 6, 6, 6, 6, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+ 8, 8, 8, 6, 7, 6, 7, 6, 7, 6, 7, 6, 7, 6, 7, 6,
+ 7, 6, 7, 6, 7, 6, 7, 6, 7, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 6, 7, 6, 7, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 6, 7, 8, 8,
/* block 78 */
-382,382,382,382,382,382,382,382,382,382,382,382,382,382,382,382,
-382,382,382,382,382,382,382,382,382,382,382,382,382,382,382,382,
-382,382,382,382,382,382,382,382,382,382,382,382,382,382,382, 91,
-383,383,383,383,383,383,383,383,383,383,383,383,383,383,383,383,
-383,383,383,383,383,383,383,383,383,383,383,383,383,383,383,383,
-383,383,383,383,383,383,383,383,383,383,383,383,383,383,383, 91,
- 21, 22,384,385,386,387,388, 21, 22, 21, 22, 21, 22,389,390,391,
-392, 14, 21, 22, 14, 21, 22, 14, 14, 14, 14, 14, 14, 83,393,393,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+ 8, 8, 8, 8, 8, 19, 19, 8, 8, 8, 8, 8, 8,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 79 */
-113,114,113,114,113,114,113,114,113,114,113,114,113,114,113,114,
-113,114,113,114,113,114,113,114,113,114,113,114,113,114,113,114,
-113,114,113,114,113,114,113,114,113,114,113,114,113,114,113,114,
-113,114,113,114,113,114,113,114,113,114,113,114,113,114,113,114,
-113,114,113,114,113,114,113,114,113,114,113,114,113,114,113,114,
-113,114,113,114,113,114,113,114,113,114,113,114,113,114,113,114,
-113,114,113,114,394,395,395,395,395,395,395,113,114,113,114,396,
-396,396, 91, 91, 91, 91, 91, 91, 91,397,397,397,397,398,397,397,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 80 */
-399,399,399,399,399,399,399,399,399,399,399,399,399,399,399,399,
-399,399,399,399,399,399,399,399,399,399,399,399,399,399,399,399,
-399,399,399,399,399,399, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-400,400,400,400,400,400,400,400,400,400,400,400,400,400,400,400,
-400,400,400,400,400,400,400,400,400,400,400,400,400,400,400,400,
-400,400,400,400,400,400,400,400,400,400,400,400,400,400,400,400,
-400,400,400,400,400,400, 91, 91, 91, 91, 91, 91, 91, 91, 91,401,
-402, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,403,
+441,441,441,441,441,441,441,441,441,441,441,441,441,441,441,441,
+441,441,441,441,441,441,441,441,441,441,441,441,441,441,441,441,
+441,441,441,441,441,441,441,441,441,441,441,441,441,441,441,109,
+442,442,442,442,442,442,442,442,442,442,442,442,442,442,442,442,
+442,442,442,442,442,442,442,442,442,442,442,442,442,442,442,442,
+442,442,442,442,442,442,442,442,442,442,442,442,442,442,442,109,
+ 30, 31,443,444,445,446,447, 30, 31, 30, 31, 30, 31,448,449,450,
+451, 33, 30, 31, 33, 30, 31, 33, 33, 33, 33, 33,101,101,452,452,
/* block 81 */
-254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,254,
-254,254,254,254,254,254,254, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-254,254,254,254,254,254,254, 91,254,254,254,254,254,254,254, 91,
-254,254,254,254,254,254,254, 91,254,254,254,254,254,254,254, 91,
-254,254,254,254,254,254,254, 91,254,254,254,254,254,254,254, 91,
-254,254,254,254,254,254,254, 91,254,254,254,254,254,254,254, 91,
-130,130,130,130,130,130,130,130,130,130,130,130,130,130,130,130,
-130,130,130,130,130,130,130,130,130,130,130,130,130,130,130,130,
+153,154,153,154,153,154,153,154,153,154,153,154,153,154,153,154,
+153,154,153,154,153,154,153,154,153,154,153,154,153,154,153,154,
+153,154,153,154,153,154,153,154,153,154,153,154,153,154,153,154,
+153,154,153,154,153,154,153,154,153,154,153,154,153,154,153,154,
+153,154,153,154,153,154,153,154,153,154,153,154,153,154,153,154,
+153,154,153,154,153,154,153,154,153,154,153,154,153,154,153,154,
+153,154,153,154,453,454,454,454,454,454,454,153,154,153,154,455,
+455,455,153,154,109,109,109,109,109,456,456,456,456,457,456,456,
/* block 82 */
- 2, 2, 15, 19, 15, 19, 2, 2, 2, 15, 19, 2, 15, 19, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 7, 2, 2, 7, 2, 15, 19, 2, 2,
- 15, 19, 4, 5, 4, 5, 4, 5, 4, 5, 2, 2, 2, 2, 2, 84,
- 2, 2, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+458,458,458,458,458,458,458,458,458,458,458,458,458,458,458,458,
+458,458,458,458,458,458,458,458,458,458,458,458,458,458,458,458,
+458,458,458,458,458,458,109,458,109,109,109,109,109,458,109,109,
+459,459,459,459,459,459,459,459,459,459,459,459,459,459,459,459,
+459,459,459,459,459,459,459,459,459,459,459,459,459,459,459,459,
+459,459,459,459,459,459,459,459,459,459,459,459,459,459,459,459,
+459,459,459,459,459,459,459,459,109,109,109,109,109,109,109,460,
+461,109,109,109,109,109,109,109,109,109,109,109,109,109,109,462,
/* block 83 */
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404, 91,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,308,
+308,308,308,308,308,308,308,109,109,109,109,109,109,109,109,109,
+308,308,308,308,308,308,308,109,308,308,308,308,308,308,308,109,
+308,308,308,308,308,308,308,109,308,308,308,308,308,308,308,109,
+308,308,308,308,308,308,308,109,308,308,308,308,308,308,308,109,
+308,308,308,308,308,308,308,109,308,308,308,308,308,308,308,109,
+170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,
+170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,170,
/* block 84 */
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
+ 4, 4, 21, 25, 21, 25, 4, 4, 4, 21, 25, 4, 21, 25, 4, 4,
+ 4, 4, 4, 4, 4, 4, 4, 9, 4, 4, 9, 4, 21, 25, 4, 4,
+ 21, 25, 6, 7, 6, 7, 6, 7, 6, 7, 4, 4, 4, 4, 4,102,
+ 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 9, 9,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 85 */
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,404,
-404,404,404,404,404,404, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91, 91, 91, 91,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,109,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 86 */
- 1, 2, 2, 2, 13,405,340,406, 4, 5, 4, 5, 4, 5, 4, 5,
- 4, 5, 13, 13, 4, 5, 4, 5, 4, 5, 4, 5, 7, 4, 5, 5,
- 13,406,406,406,406,406,406,406,406,406, 86, 86, 86, 86,407,407,
- 7, 84, 84, 84, 84, 84, 13, 13,406,406,406,405,340, 2, 13, 13,
- 91,408,408,408,408,408,408,408,408,408,408,408,408,408,408,408,
-408,408,408,408,408,408,408,408,408,408,408,408,408,408,408,408,
-408,408,408,408,408,408,408,408,408,408,408,408,408,408,408,408,
-408,408,408,408,408,408,408,408,408,408,408,408,408,408,408,408,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
/* block 87 */
-408,408,408,408,408,408,408,408,408,408,408,408,408,408,408,408,
-408,408,408,408,408,408,408, 91, 91, 86, 86, 10, 10,409,409,408,
- 7,410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,
-410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,
-410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,
-410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,
-410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,
-410,410,410,410,410,410,410,410,410,410,410, 2, 84,411,411,410,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,463,
+463,463,463,463,463,463,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,109,109,109,
/* block 88 */
- 91, 91, 91, 91, 91,412,412,412,412,412,412,412,412,412,412,412,
-412,412,412,412,412,412,412,412,412,412,412,412,412,412,412,412,
-412,412,412,412,412,412,412,412,412,412,412,412,412,412, 91, 91,
- 91,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
+ 3, 4, 4, 4, 19,464,396,465, 6, 7, 6, 7, 6, 7, 6, 7,
+ 6, 7, 19, 19, 6, 7, 6, 7, 6, 7, 6, 7, 9, 6, 7, 7,
+ 19,465,465,465,465,465,465,465,465,465,104,104,104,104,466,466,
+ 9,102,102,102,102,102, 19, 19,465,465,465,464,396, 4, 19, 19,
+109,467,467,467,467,467,467,467,467,467,467,467,467,467,467,467,
+467,467,467,467,467,467,467,467,467,467,467,467,467,467,467,467,
+467,467,467,467,467,467,467,467,467,467,467,467,467,467,467,467,
+467,467,467,467,467,467,467,467,467,467,467,467,467,467,467,467,
/* block 89 */
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, 91,
- 13, 13, 17, 17, 17, 17, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
-412,412,412,412,412,412,412,412,412,412,412,412,412,412,412,412,
-412,412,412,412,412,412,412,412,412,412,412, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,
+467,467,467,467,467,467,467,467,467,467,467,467,467,467,467,467,
+467,467,467,467,467,467,467,109,109,104,104, 14, 14,468,468,467,
+ 9,469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,
+469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,
+469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,
+469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,
+469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,
+469,469,469,469,469,469,469,469,469,469,469, 4,102,470,470,469,
/* block 90 */
-413,413,413,413,413,413,413,413,413,413,413,413,413,413,413,413,
-413,413,413,413,413,413,413,413,413,413,413,413,413,413,413, 91,
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
-413,413,413,413,413,413,413,413,413,413,413,413,413,413,413,413,
-413,413,413,413,413,413,413,413,413,413,413,413,413,413,413, 13,
+109,109,109,109,109,471,471,471,471,471,471,471,471,471,471,471,
+471,471,471,471,471,471,471,471,471,471,471,471,471,471,471,471,
+471,471,471,471,471,471,471,471,471,471,471,471,471,471,109,109,
+109,472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,
+472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,
+472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,
+472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,
+472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,
/* block 91 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
-414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,
-414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,
-414,414,414,414,414,414,414,414,414,414,414,414,414,414,414, 91,
+472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,109,
+ 19, 19, 23, 23, 23, 23, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+471,471,471,471,471,471,471,471,471,471,471,471,471,471,471,471,
+471,471,471,471,471,471,471,471,471,471,471,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19,109,109,109,109,109,109,109,109,109,109,109,109,
+469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,
/* block 92 */
-414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,
-414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,
-414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,
-414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,
-414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,414,
-414,414,414,414,414,414,414,414, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
+473,473,473,473,473,473,473,473,473,473,473,473,473,473,473,473,
+473,473,473,473,473,473,473,473,473,473,473,473,473,473,473,109,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 23, 23, 23, 23, 23, 23, 23, 23,
+ 19, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+473,473,473,473,473,473,473,473,473,473,473,473,473,473,473,473,
+473,473,473,473,473,473,473,473,473,473,473,473,473,473,473, 19,
/* block 93 */
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,
+474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,
+474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,109,
/* block 94 */
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
+474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,
+474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,
+474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,
+474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,
+474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,474,
+474,474,474,474,474,474,474,474, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
/* block 95 */
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
/* block 96 */
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,417,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,109,109,109,109,109,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
/* block 97 */
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
-416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,416,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 98 */
-416,416,416,416,416,416,416,416,416,416,416,416,416, 91, 91, 91,
-418,418,418,418,418,418,418,418,418,418,418,418,418,418,418,418,
-418,418,418,418,418,418,418,418,418,418,418,418,418,418,418,418,
-418,418,418,418,418,418,418,418,418,418,418,418,418,418,418,418,
-418,418,418,418,418,418,418, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-419,419,419,419,419,419,419,419,419,419,419,419,419,419,419,419,
-419,419,419,419,419,419,419,419,419,419,419,419,419,419,419,419,
-419,419,419,419,419,419,419,419,420,420,420,420,420,420,421,421,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,477,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
/* block 99 */
-422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,
-422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,
-422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,
-422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,
-422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,
-422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,
-422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,
-422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
/* block 100 */
-422,422,422,422,422,422,422,422,422,422,422,422,423,424,424,424,
-422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,422,
-425,425,425,425,425,425,425,425,425,425,422,422, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,426,130,
-131,131,131,427, 91, 91, 91, 91, 91, 91, 91, 91,130,130,427,342,
+476,476,476,476,476,476,476,476,476,476,476,476,476,109,109,109,
+478,478,478,478,478,478,478,478,478,478,478,478,478,478,478,478,
+478,478,478,478,478,478,478,478,478,478,478,478,478,478,478,478,
+478,478,478,478,478,478,478,478,478,478,478,478,478,478,478,478,
+478,478,478,478,478,478,478,109,109,109,109,109,109,109,109,109,
+479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,
+479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,
+479,479,479,479,479,479,479,479,480,480,480,480,480,480,481,481,
/* block 101 */
-127,128,127,128,127,128,127,128,127,128,127,128,127,128,127,128,
-127,128,127,128,127,128,127,128, 91, 91, 91, 91, 91, 91, 91, 91,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,429,429,429,429,429,429,429,429,429,429,
-430,430,431,431,431,431,431,431, 91, 91, 91, 91, 91, 91, 91, 91,
+482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
+482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
+482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
+482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
+482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
+482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
+482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
+482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
/* block 102 */
- 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
- 10, 10, 10, 10, 10, 10, 10, 84, 84, 84, 84, 84, 84, 84, 84, 84,
- 10, 10, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 14, 14, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 21, 22,
- 83, 14, 14, 14, 14, 14, 14, 14, 14, 21, 22, 21, 22,432, 21, 22,
+482,482,482,482,482,482,482,482,482,482,482,482,483,484,484,484,
+482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
+485,485,485,485,485,485,485,485,485,485,482,482,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,486,170,
+171,171,171,487,170,170,170,170,170,170,170,170,170,170,487,398,
/* block 103 */
- 21, 22, 21, 22, 21, 22, 21, 22, 84, 10, 10, 21, 22,433, 14, 91,
- 21, 22, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 21, 22, 21, 22, 21, 22, 21, 22, 21, 22, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 14, 45, 45, 45, 45, 45,
+167,168,167,168,167,168,167,168,167,168,167,168,167,168,167,168,
+167,168,167,168,167,168,167,168,109,109,109,109,109,109,109,170,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,489,489,489,489,489,489,489,489,489,489,
+490,490,491,491,491,491,491,491,109,109,109,109,109,109,109,109,
/* block 104 */
-434,434,435,434,434,434,435,434,434,434,434,435,434,434,434,434,
-434,434,434,434,434,434,434,434,434,434,434,434,434,434,434,434,
-434,434,434,436,436,435,435,436,437,437,437,437, 91, 91, 91, 91,
- 17, 17, 17, 17, 17, 17, 13, 13, 3, 13, 91, 91, 91, 91, 91, 91,
-438,438,438,438,438,438,438,438,438,438,438,438,438,438,438,438,
-438,438,438,438,438,438,438,438,438,438,438,438,438,438,438,438,
-438,438,438,438,438,438,438,438,438,438,438,438,438,438,438,438,
-438,438,438,438,439,439,439,439, 91, 91, 91, 91, 91, 91, 91, 91,
+ 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
+ 14, 14, 14, 14, 14, 14, 14,102,102,102,102,102,102,102,102,102,
+ 14, 14, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 33, 33, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,
+101, 33, 33, 33, 33, 33, 33, 33, 33, 30, 31, 30, 31,492, 30, 31,
/* block 105 */
-440,440,441,441,441,441,441,441,441,441,441,441,441,441,441,441,
-441,441,441,441,441,441,441,441,441,441,441,441,441,441,441,441,
-441,441,441,441,441,441,441,441,441,441,441,441,441,441,441,441,
-441,441,441,441,440,440,440,440,440,440,440,440,440,440,440,440,
-440,440,440,440,442, 91, 91, 91, 91, 91, 91, 91, 91, 91,443,443,
-444,444,444,444,444,444,444,444,444,444, 91, 91, 91, 91, 91, 91,
-172,172,172,172,172,172,172,172,172,172,172,172,172,172,172,172,
-172,172,174,174,174,174,174,174,445,445,445,174, 91, 91, 91, 91,
+ 30, 31, 30, 31, 30, 31, 30, 31,102, 14, 14, 30, 31,493, 33,109,
+ 30, 31, 30, 31,109,109,109,109,109,109,109,109,109,109,109,109,
+ 30, 31, 30, 31, 30, 31, 30, 31, 30, 31,494,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,101,101, 33, 20, 20, 20, 20, 20,
/* block 106 */
-446,446,446,446,446,446,446,446,446,446,447,447,447,447,447,447,
-447,447,447,447,447,447,447,447,447,447,447,447,447,447,447,447,
-447,447,447,447,447,447,448,448,448,448,448,448,448,448,449,449,
-450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,450,
-450,450,450,450,450,450,450,451,451,451,451,451,451,451,451,451,
-451,451,452,452, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,453,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253, 91, 91, 91,
+495,495,496,495,495,495,496,495,495,495,495,496,495,495,495,495,
+495,495,495,495,495,495,495,495,495,495,495,495,495,495,495,495,
+495,495,495,497,497,496,496,497,498,498,498,498,109,109,109,109,
+ 23, 23, 23, 23, 23, 23, 19, 19, 5, 19,109,109,109,109,109,109,
+499,499,499,499,499,499,499,499,499,499,499,499,499,499,499,499,
+499,499,499,499,499,499,499,499,499,499,499,499,499,499,499,499,
+499,499,499,499,499,499,499,499,499,499,499,499,499,499,499,499,
+499,499,499,499,500,500,500,500,109,109,109,109,109,109,109,109,
/* block 107 */
-454,454,454,455,456,456,456,456,456,456,456,456,456,456,456,456,
-456,456,456,456,456,456,456,456,456,456,456,456,456,456,456,456,
-456,456,456,456,456,456,456,456,456,456,456,456,456,456,456,456,
-456,456,456,454,455,455,454,454,454,454,455,455,454,455,455,455,
-455,457,457,457,457,457,457,457,457,457,457,457,457,457, 91,458,
-459,459,459,459,459,459,459,459,459,459, 91, 91, 91, 91,457,457,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+501,501,502,502,502,502,502,502,502,502,502,502,502,502,502,502,
+502,502,502,502,502,502,502,502,502,502,502,502,502,502,502,502,
+502,502,502,502,502,502,502,502,502,502,502,502,502,502,502,502,
+502,502,502,502,501,501,501,501,501,501,501,501,501,501,501,501,
+501,501,501,501,503,109,109,109,109,109,109,109,109,109,504,504,
+505,505,505,505,505,505,505,505,505,505,109,109,109,109,109,109,
+213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,213,
+213,213,215,215,215,215,215,215,217,217,217,215,109,109,109,109,
/* block 108 */
-460,460,460,460,460,460,460,460,460,460,460,460,460,460,460,460,
-460,460,460,460,460,460,460,460,460,460,460,460,460,460,460,460,
-460,460,460,460,460,460,460,460,460,461,461,461,461,461,461,462,
-462,461,461,462,462,461,461, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-460,460,460,461,460,460,460,460,460,460,460,460,461,462, 91, 91,
-463,463,463,463,463,463,463,463,463,463, 91, 91,464,464,464,464,
-244,244,244,244,244,244,244,244,244,244,244,244,244,244,244,244,
-465,244,244,244,244,244,244,249,249,249,244,245, 91, 91, 91, 91,
+506,506,506,506,506,506,506,506,506,506,507,507,507,507,507,507,
+507,507,507,507,507,507,507,507,507,507,507,507,507,507,507,507,
+507,507,507,507,507,507,508,508,508,508,508,508,508,508,509,509,
+510,510,510,510,510,510,510,510,510,510,510,510,510,510,510,510,
+510,510,510,510,510,510,510,511,511,511,511,511,511,511,511,511,
+511,511,512,512,109,109,109,109,109,109,109,109,109,109,109,513,
+305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,305,
+305,305,305,305,305,305,305,305,305,305,305,305,305,109,109,109,
/* block 109 */
-466,466,466,466,466,466,466,466,466,466,466,466,466,466,466,466,
-466,466,466,466,466,466,466,466,466,466,466,466,466,466,466,466,
-466,466,466,466,466,466,466,466,466,466,466,466,466,466,466,466,
-467,466,467,467,467,466,466,467,467,466,466,466,466,466,467,467,
-466,467,466, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,466,466,468,469,469,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+514,514,514,515,516,516,516,516,516,516,516,516,516,516,516,516,
+516,516,516,516,516,516,516,516,516,516,516,516,516,516,516,516,
+516,516,516,516,516,516,516,516,516,516,516,516,516,516,516,516,
+516,516,516,514,515,515,514,514,514,514,515,515,514,515,515,515,
+515,517,517,517,517,517,517,517,517,517,517,517,517,517,109,518,
+519,519,519,519,519,519,519,519,519,519,109,109,109,109,517,517,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 110 */
- 91,254,254,254,254,254,254, 91, 91,254,254,254,254,254,254, 91,
- 91,254,254,254,254,254,254, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-254,254,254,254,254,254,254, 91,254,254,254,254,254,254,254, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+520,520,520,520,520,520,520,520,520,520,520,520,520,520,520,520,
+520,520,520,520,520,520,520,520,520,520,520,520,520,520,520,520,
+520,520,520,520,520,520,520,520,520,521,521,521,521,521,521,522,
+522,521,521,522,522,521,521,109,109,109,109,109,109,109,109,109,
+520,520,520,521,520,520,520,520,520,520,520,520,521,522,109,109,
+523,523,523,523,523,523,523,523,523,523,109,109,524,524,524,524,
+295,295,295,295,295,295,295,295,295,295,295,295,295,295,295,295,
+525,295,295,295,295,295,295,301,301,301,295,296,109,109,109,109,
/* block 111 */
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-470,470,470,470,470,470,470,470,470,470,470,470,470,470,470,470,
-470,470,470,470,470,470,470,470,470,470,470,470,470,470,470,470,
-470,470,470,471,471,472,471,471,472,471,471,473,471,472, 91, 91,
-474,474,474,474,474,474,474,474,474,474, 91, 91, 91, 91, 91, 91,
+526,526,526,526,526,526,526,526,526,526,526,526,526,526,526,526,
+526,526,526,526,526,526,526,526,526,526,526,526,526,526,526,526,
+526,526,526,526,526,526,526,526,526,526,526,526,526,526,526,526,
+527,526,527,527,527,526,526,527,527,526,526,526,526,526,527,527,
+526,527,526,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,526,526,528,529,529,
+530,530,530,530,530,530,530,530,530,530,530,531,532,532,531,531,
+533,533,530,534,534,531,532,109,109,109,109,109,109,109,109,109,
/* block 112 */
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253, 91, 91, 91, 91,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253, 91, 91, 91, 91,
+109,308,308,308,308,308,308,109,109,308,308,308,308,308,308,109,
+109,308,308,308,308,308,308,109,109,109,109,109,109,109,109,109,
+308,308,308,308,308,308,308,109,308,308,308,308,308,308,308,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 113 */
-475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
-475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
-475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
-475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
-475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
-475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
-475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
-475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+530,530,530,530,530,530,530,530,530,530,530,530,530,530,530,530,
+530,530,530,530,530,530,530,530,530,530,530,530,530,530,530,530,
+530,530,530,531,531,532,531,531,532,531,531,533,531,532,109,109,
+535,535,535,535,535,535,535,535,535,535,109,109,109,109,109,109,
/* block 114 */
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
+536,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,536,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,536,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,536,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+536,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
/* block 115 */
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415, 91, 91,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415, 91, 91,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
+537,537,537,537,537,537,537,537,537,537,537,537,536,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,536,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,536,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+536,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,536,537,537,537,
/* block 116 */
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,536,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,536,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+536,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,536,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
/* block 117 */
- 14, 14, 14, 14, 14, 14, 14, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91,138,138,138,138,138, 91, 91, 91, 91, 91,143,140,143,
-143,143,143,143,143,143,143,143,143,477,143,143,143,143,143,143,
-143,143,143,143,143,143,143, 91,143,143,143,143,143, 91,143, 91,
-143,143, 91,143,143, 91,143,143,143,143,143,143,143,143,143,143,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
+537,537,537,537,537,537,537,537,536,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,536,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+536,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,536,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,536,537,537,537,537,537,537,537,
/* block 118 */
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,478,478,478,478,478,478,478,478,478,478,478,478,478,478,
-478,478, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,536,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+536,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,536,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,536,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
/* block 119 */
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
+537,537,537,537,536,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+536,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,536,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,536,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,536,537,537,537,537,537,537,537,537,537,537,537,
/* block 120 */
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150, 4, 5,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+536,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,536,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,536,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,536,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
/* block 121 */
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
- 91, 91,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-150,150,150,150,150,150,150,150,150,150,150,150,147, 13, 91, 91,
+537,537,537,537,537,537,537,537,536,537,537,537,537,537,537,537,
+537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+537,537,537,537,109,109,109,109,109,109,109,109,109,109,109,109,
+306,306,306,306,306,306,306,306,306,306,306,306,306,306,306,306,
+306,306,306,306,306,306,306,109,109,109,109,307,307,307,307,307,
+307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,
+307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,307,
+307,307,307,307,307,307,307,307,307,307,307,307,109,109,109,109,
/* block 122 */
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 2, 2, 2, 2, 2, 2, 2, 4, 5, 2, 91, 91, 91, 91, 91, 91,
- 86, 86, 86, 86, 86, 86, 86, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 2, 7, 7, 11, 11, 4, 5, 4, 5, 4, 5, 4, 5, 4, 5, 4,
- 5, 4, 5, 4, 5, 2, 2, 4, 5, 2, 2, 2, 2, 11, 11, 11,
- 2, 2, 2, 91, 2, 2, 2, 2, 7, 4, 5, 4, 5, 4, 5, 2,
- 2, 2, 6, 7, 6, 6, 6, 91, 2, 3, 2, 2, 91, 91, 91, 91,
-150,150,150,150,150, 91,150,150,150,150,150,150,150,150,150,150,
+538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,
+538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,
+538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,
+538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,
+538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,
+538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,
+538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,
+538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,538,
/* block 123 */
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,150,
-150,150,150,150,150,150,150,150,150,150,150,150,150, 91, 91, 16,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
/* block 124 */
- 91, 2, 2, 2, 3, 2, 2, 2, 4, 5, 2, 6, 2, 7, 2, 2,
- 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 2, 2, 6, 6, 6, 2,
- 2, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9,
- 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 4, 2, 5, 10, 11,
- 10, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12,
- 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 4, 6, 5, 6, 4,
- 5, 2, 4, 5, 2, 2,410,410,410,410,410,410,410,410,410,410,
- 84,410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,109,109,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
/* block 125 */
-410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,410,
-410,410,410,410,410,410,410,410,410,410,410,410,410,410, 84, 84,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,253,
-253,253,253,253,253,253,253,253,253,253,253,253,253,253,253, 91,
- 91, 91,253,253,253,253,253,253, 91, 91,253,253,253,253,253,253,
- 91, 91,253,253,253,253,253,253, 91, 91,253,253,253, 91, 91, 91,
- 3, 3, 6, 10, 13, 3, 3, 91, 13, 6, 6, 6, 6, 13, 13, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 16, 16, 16, 13, 13, 91, 91,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 126 */
-479,479,479,479,479,479,479,479,479,479,479,479, 91,479,479,479,
-479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,
-479,479,479,479,479,479,479, 91,479,479,479,479,479,479,479,479,
-479,479,479,479,479,479,479,479,479,479,479, 91,479,479, 91,479,
-479,479,479,479,479,479,479,479,479,479,479,479,479,479, 91, 91,
-479,479,479,479,479,479,479,479,479,479,479,479,479,479, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+ 33, 33, 33, 33, 33, 33, 33,109,109,109,109,109,109,109,109,109,
+109,109,109,178,178,178,178,178,109,109,109,109,109,184,181,184,
+184,184,184,184,184,184,184,184,184,540,184,184,184,184,184,184,
+184,184,184,184,184,184,184,109,184,184,184,184,184,109,184,109,
+184,184,109,184,184,109,184,184,184,184,184,184,184,184,184,184,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
/* block 127 */
-479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,
-479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,
-479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,
-479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,
-479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,
-479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,
-479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,479,
-479,479,479,479,479,479,479,479,479,479,479, 91, 91, 91, 91, 91,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,541,541,541,541,541,541,541,541,541,541,541,541,541,541,
+541,541,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
/* block 128 */
- 2, 2, 13, 91, 91, 91, 91, 17, 17, 17, 17, 17, 17, 17, 17, 17,
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
- 17, 17, 17, 17, 91, 91, 91, 13, 13, 13, 13, 13, 13, 13, 13, 13,
-480,480,480,480,480,480,480,480,480,480,480,480,480,480,480,480,
-480,480,480,480,480,480,480,480,480,480,480,480,480,480,480,480,
-480,480,480,480,480,480,480,480,480,480,480,480,480,480,480,480,
-480,480,480,480,480,481,481,481,481,482,482,482,482,482,482,482,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
/* block 129 */
-482,482,482,482,482,482,482,482,482,482,481, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 86, 91, 91,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191, 6, 7,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
/* block 130 */
-483,483,483,483,483,483,483,483,483,483,483,483,483,483,483,483,
-483,483,483,483,483,483,483,483,483,483,483,483,483, 91, 91, 91,
-484,484,484,484,484,484,484,484,484,484,484,484,484,484,484,484,
-484,484,484,484,484,484,484,484,484,484,484,484,484,484,484,484,
-484,484,484,484,484,484,484,484,484,484,484,484,484,484,484,484,
-484, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+109,109,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+191,191,191,191,191,191,191,191,191,191,191,191,188, 19,109,109,
/* block 131 */
-485,485,485,485,485,485,485,485,485,485,485,485,485,485,485,485,
-485,485,485,485,485,485,485,485,485,485,485,485,485,485,485, 91,
-486,486,486,486, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-487,487,487,487,487,487,487,487,487,487,487,487,487,487,487,487,
-487,488,487,487,487,487,487,487,487,487,488, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+ 4, 4, 4, 4, 4, 4, 4, 6, 7, 4,109,109,109,109,109,109,
+104,104,104,104,104,104,104,109,109,109,109,109,109,109,109,109,
+ 4, 9, 9, 15, 15, 6, 7, 6, 7, 6, 7, 6, 7, 6, 7, 6,
+ 7, 6, 7, 6, 7, 4, 4, 6, 7, 4, 4, 4, 4, 15, 15, 15,
+ 4, 4, 4,109, 4, 4, 4, 4, 9, 6, 7, 6, 7, 6, 7, 4,
+ 4, 4, 8, 9, 8, 8, 8,109, 4, 5, 4, 4,109,109,109,109,
+191,191,191,191,191,109,191,191,191,191,191,191,191,191,191,191,
/* block 132 */
-489,489,489,489,489,489,489,489,489,489,489,489,489,489,489,489,
-489,489,489,489,489,489,489,489,489,489,489,489,489,489, 91,490,
-491,491,491,491,491,491,491,491,491,491,491,491,491,491,491,491,
-491,491,491,491,491,491,491,491,491,491,491,491,491,491,491,491,
-491,491,491,491, 91, 91, 91, 91,491,491,491,491,491,491,491,491,
-492,493,493,493,493,493, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,109,109, 22,
/* block 133 */
-494,494,494,494,494,494,494,494,494,494,494,494,494,494,494,494,
-494,494,494,494,494,494,494,494,494,494,494,494,494,494,494,494,
-494,494,494,494,494,494,494,494,495,495,495,495,495,495,495,495,
-495,495,495,495,495,495,495,495,495,495,495,495,495,495,495,495,
-495,495,495,495,495,495,495,495,495,495,495,495,495,495,495,495,
-496,496,496,496,496,496,496,496,496,496,496,496,496,496,496,496,
-496,496,496,496,496,496,496,496,496,496,496,496,496,496,496,496,
-496,496,496,496,496,496,496,496,496,496,496,496,496,496,496,496,
+109, 4, 4, 4, 5, 4, 4, 4, 6, 7, 4, 8, 4, 9, 4, 4,
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 4, 4, 8, 8, 8, 4,
+ 4, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
+ 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 6, 4, 7, 14, 15,
+ 14, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
+ 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 6, 8, 7, 8, 6,
+ 7, 4, 6, 7, 4, 4,469,469,469,469,469,469,469,469,469,469,
+102,469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,
/* block 134 */
-497,497,497,497,497,497,497,497,497,497,497,497,497,497,497,497,
-497,497,497,497,497,497,497,497,497,497,497,497,497,497, 91, 91,
-498,498,498,498,498,498,498,498,498,498, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,469,
+469,469,469,469,469,469,469,469,469,469,469,469,469,469,542,542,
+472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,
+472,472,472,472,472,472,472,472,472,472,472,472,472,472,472,109,
+109,109,472,472,472,472,472,472,109,109,472,472,472,472,472,472,
+109,109,472,472,472,472,472,472,109,109,472,472,472,109,109,109,
+ 5, 5, 8, 14, 19, 5, 5,109, 19, 8, 8, 8, 8, 19, 19,109,
+426,426,426,426,426,426,426,426,426, 22, 22, 22, 19, 19,109,109,
/* block 135 */
-499,499,499,499,499,499, 91, 91,499, 91,499,499,499,499,499,499,
-499,499,499,499,499,499,499,499,499,499,499,499,499,499,499,499,
-499,499,499,499,499,499,499,499,499,499,499,499,499,499,499,499,
-499,499,499,499,499,499, 91,499,499, 91, 91, 91,499, 91, 91,499,
-500,500,500,500,500,500,500,500,500,500,500,500,500,500,500,500,
-500,500,500,500,500,500, 91,501,502,502,502,502,502,502,502,502,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+543,543,543,543,543,543,543,543,543,543,543,543,109,543,543,543,
+543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,
+543,543,543,543,543,543,543,109,543,543,543,543,543,543,543,543,
+543,543,543,543,543,543,543,543,543,543,543,109,543,543,109,543,
+543,543,543,543,543,543,543,543,543,543,543,543,543,543,109,109,
+543,543,543,543,543,543,543,543,543,543,543,543,543,543,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 136 */
-503,503,503,503,503,503,503,503,503,503,503,503,503,503,503,503,
-503,503,503,503,503,503,504,504,504,504,504,504, 91, 91, 91,505,
-506,506,506,506,506,506,506,506,506,506,506,506,506,506,506,506,
-506,506,506,506,506,506,506,506,506,506, 91, 91, 91, 91, 91,507,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,
+543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,
+543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,
+543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,
+543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,
+543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,
+543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,543,
+543,543,543,543,543,543,543,543,543,543,543,109,109,109,109,109,
/* block 137 */
-508,509,509,509, 91,509,509, 91, 91, 91, 91, 91,509,509,509,509,
-508,508,508,508, 91,508,508,508, 91,508,508,508,508,508,508,508,
-508,508,508,508,508,508,508,508,508,508,508,508,508,508,508,508,
-508,508,508,508, 91, 91, 91, 91,509,509,509, 91, 91, 91, 91,509,
-510,510,510,510,510,510,510,510, 91, 91, 91, 91, 91, 91, 91, 91,
-511,511,511,511,511,511,511,511,511, 91, 91, 91, 91, 91, 91, 91,
-512,512,512,512,512,512,512,512,512,512,512,512,512,512,512,512,
-512,512,512,512,512,512,512,512,512,512,512,512,512,513,513,514,
+ 4, 4, 4,109,109,109,109, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23, 23, 23,109,109,109, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+544,544,544,544,544,544,544,544,544,544,544,544,544,544,544,544,
+544,544,544,544,544,544,544,544,544,544,544,544,544,544,544,544,
+544,544,544,544,544,544,544,544,544,544,544,544,544,544,544,544,
+544,544,544,544,544,545,545,545,545,546,546,546,546,546,546,546,
/* block 138 */
-515,515,515,515,515,515,515,515,515,515,515,515,515,515,515,515,
-515,515,515,515,515,515,515,515,515,515,515,515,515,515,515,515,
-515,515,515,515,515,515,515,515,515,515,515,515,515,515,515,515,
-515,515,515,515,515,515, 91, 91, 91,516,516,516,516,516,516,516,
-517,517,517,517,517,517,517,517,517,517,517,517,517,517,517,517,
-517,517,517,517,517,517, 91, 91,518,518,518,518,518,518,518,518,
-519,519,519,519,519,519,519,519,519,519,519,519,519,519,519,519,
-519,519,519, 91, 91, 91, 91, 91,520,520,520,520,520,520,520,520,
+546,546,546,546,546,546,546,546,546,546,545,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,104,109,109,
/* block 139 */
-521,521,521,521,521,521,521,521,521,521,521,521,521,521,521,521,
-521,521,521,521,521,521,521,521,521,521,521,521,521,521,521,521,
-521,521,521,521,521,521,521,521,521,521,521,521,521,521,521,521,
-521,521,521,521,521,521,521,521,521,521,521,521,521,521,521,521,
-521,521,521,521,521,521,521,521,521, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+547,547,547,547,547,547,547,547,547,547,547,547,547,547,547,547,
+547,547,547,547,547,547,547,547,547,547,547,547,547,109,109,109,
+548,548,548,548,548,548,548,548,548,548,548,548,548,548,548,548,
+548,548,548,548,548,548,548,548,548,548,548,548,548,548,548,548,
+548,548,548,548,548,548,548,548,548,548,548,548,548,548,548,548,
+548,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 140 */
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,522,
-522,522,522,522,522,522,522,522,522,522,522,522,522,522,522, 91,
+549,549,549,549,549,549,549,549,549,549,549,549,549,549,549,549,
+549,549,549,549,549,549,549,549,549,549,549,549,549,549,549,109,
+550,550,550,550,109,109,109,109,109,109,109,109,109,109,109,109,
+551,551,551,551,551,551,551,551,551,551,551,551,551,551,551,551,
+551,552,551,551,551,551,551,551,551,551,552,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 141 */
-523,524,523,525,525,525,525,525,525,525,525,525,525,525,525,525,
-525,525,525,525,525,525,525,525,525,525,525,525,525,525,525,525,
-525,525,525,525,525,525,525,525,525,525,525,525,525,525,525,525,
-525,525,525,525,525,525,525,525,524,524,524,524,524,524,524,524,
-524,524,524,524,524,524,524,526,526,526,526,526,526,526, 91, 91,
- 91, 91,527,527,527,527,527,527,527,527,527,527,527,527,527,527,
-527,527,527,527,527,527,528,528,528,528,528,528,528,528,528,528,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+553,553,553,553,553,553,553,553,553,553,553,553,553,553,553,553,
+553,553,553,553,553,553,553,553,553,553,553,553,553,553,109,554,
+555,555,555,555,555,555,555,555,555,555,555,555,555,555,555,555,
+555,555,555,555,555,555,555,555,555,555,555,555,555,555,555,555,
+555,555,555,555,109,109,109,109,555,555,555,555,555,555,555,555,
+556,557,557,557,557,557,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 142 */
-529,529,530,531,531,531,531,531,531,531,531,531,531,531,531,531,
-531,531,531,531,531,531,531,531,531,531,531,531,531,531,531,531,
-531,531,531,531,531,531,531,531,531,531,531,531,531,531,531,531,
-530,530,530,529,529,529,529,530,530,529,529,532,532,533,532,532,
-532,532, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+558,558,558,558,558,558,558,558,558,558,558,558,558,558,558,558,
+558,558,558,558,558,558,558,558,558,558,558,558,558,558,558,558,
+558,558,558,558,558,558,558,558,559,559,559,559,559,559,559,559,
+559,559,559,559,559,559,559,559,559,559,559,559,559,559,559,559,
+559,559,559,559,559,559,559,559,559,559,559,559,559,559,559,559,
+560,560,560,560,560,560,560,560,560,560,560,560,560,560,560,560,
+560,560,560,560,560,560,560,560,560,560,560,560,560,560,560,560,
+560,560,560,560,560,560,560,560,560,560,560,560,560,560,560,560,
/* block 143 */
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
+561,561,561,561,561,561,561,561,561,561,561,561,561,561,561,561,
+561,561,561,561,561,561,561,561,561,561,561,561,561,561,109,109,
+562,562,562,562,562,562,562,562,562,562,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 144 */
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,534,
-534,534,534,534,534,534,534,534,534,534,534,534,534,534,534, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+563,563,563,563,563,563,109,109,563,109,563,563,563,563,563,563,
+563,563,563,563,563,563,563,563,563,563,563,563,563,563,563,563,
+563,563,563,563,563,563,563,563,563,563,563,563,563,563,563,563,
+563,563,563,563,563,563,109,563,563,109,109,109,563,109,109,563,
+564,564,564,564,564,564,564,564,564,564,564,564,564,564,564,564,
+564,564,564,564,564,564,109,565,566,566,566,566,566,566,566,566,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 145 */
-535,535,535,535,535,535,535,535,535,535,535,535,535,535,535,535,
-535,535,535,535,535,535,535,535,535,535,535,535,535,535,535,535,
-535,535,535,535,535,535,535,535,535,535,535,535,535,535,535,535,
-535,535,535,535,535,535,535,535,535,535,535,535,535,535,535,535,
-535,535,535,535,535,535,535,535,535,535,535,535,535,535,535,535,
-535,535,535,535,535,535,535,535,535,535,535,535,535,535,535,535,
-535,535,535, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-536,536,536,536, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+567,567,567,567,567,567,567,567,567,567,567,567,567,567,567,567,
+567,567,567,567,567,567,568,568,568,568,568,568,109,109,109,569,
+570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,570,
+570,570,570,570,570,570,570,570,570,570,109,109,109,109,109,571,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 146 */
-537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
-537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
-537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
-537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
-537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
-537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
-537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
-537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
+572,572,572,572,572,572,572,572,572,572,572,572,572,572,572,572,
+572,572,572,572,572,572,572,572,572,572,572,572,572,572,572,572,
+573,573,573,573,573,573,573,573,573,573,573,573,573,573,573,573,
+573,573,573,573,573,573,573,573,109,109,109,109,109,109,573,573,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 147 */
-537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
-537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,537,
-537,537,537,537,537,537,537,537,537,537,537,537,537,537,537, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+574,575,575,575,109,575,575,109,109,109,109,109,575,575,575,575,
+574,574,574,574,109,574,574,574,109,574,574,574,574,574,574,574,
+574,574,574,574,574,574,574,574,574,574,574,574,574,574,574,574,
+574,574,574,574,109,109,109,109,575,575,575,109,109,109,109,575,
+576,576,576,576,576,576,576,576,109,109,109,109,109,109,109,109,
+577,577,577,577,577,577,577,577,577,109,109,109,109,109,109,109,
+578,578,578,578,578,578,578,578,578,578,578,578,578,578,578,578,
+578,578,578,578,578,578,578,578,578,578,578,578,578,579,579,580,
/* block 148 */
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
+581,581,581,581,581,581,581,581,581,581,581,581,581,581,581,581,
+581,581,581,581,581,581,581,581,581,581,581,581,581,581,581,581,
+581,581,581,581,581,581,581,581,581,581,581,581,581,581,581,581,
+581,581,581,581,581,581,109,109,109,582,582,582,582,582,582,582,
+583,583,583,583,583,583,583,583,583,583,583,583,583,583,583,583,
+583,583,583,583,583,583,109,109,584,584,584,584,584,584,584,584,
+585,585,585,585,585,585,585,585,585,585,585,585,585,585,585,585,
+585,585,585,109,109,109,109,109,586,586,586,586,586,586,586,586,
/* block 149 */
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
-428,428,428,428,428,428,428,428,428, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+587,587,587,587,587,587,587,587,587,587,587,587,587,587,587,587,
+587,587,587,587,587,587,587,587,587,587,587,587,587,587,587,587,
+587,587,587,587,587,587,587,587,587,587,587,587,587,587,587,587,
+587,587,587,587,587,587,587,587,587,587,587,587,587,587,587,587,
+587,587,587,587,587,587,587,587,587,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 150 */
-410,408, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+588,588,588,588,588,588,588,588,588,588,588,588,588,588,588,588,
+588,588,588,588,588,588,588,588,588,588,588,588,588,588,588,109,
/* block 151 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+589,590,589,591,591,591,591,591,591,591,591,591,591,591,591,591,
+591,591,591,591,591,591,591,591,591,591,591,591,591,591,591,591,
+591,591,591,591,591,591,591,591,591,591,591,591,591,591,591,591,
+591,591,591,591,591,591,591,591,590,590,590,590,590,590,590,590,
+590,590,590,590,590,590,590,592,592,592,592,592,592,592,109,109,
+109,109,593,593,593,593,593,593,593,593,593,593,593,593,593,593,
+593,593,593,593,593,593,594,594,594,594,594,594,594,594,594,594,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 152 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 91, 91, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13,339,339, 86, 86, 86, 13, 13, 13,339,339,339,
-339,339,339, 16, 16, 16, 16, 16, 16, 16, 16, 86, 86, 86, 86, 86,
+595,595,596,597,597,597,597,597,597,597,597,597,597,597,597,597,
+597,597,597,597,597,597,597,597,597,597,597,597,597,597,597,597,
+597,597,597,597,597,597,597,597,597,597,597,597,597,597,597,597,
+596,596,596,595,595,595,595,596,596,595,595,598,598,599,598,598,
+598,598,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+600,600,600,600,600,600,600,600,600,600,600,600,600,600,600,600,
+600,600,600,600,600,600,600,600,600,109,109,109,109,109,109,109,
+601,601,601,601,601,601,601,601,601,601,109,109,109,109,109,109,
/* block 153 */
- 86, 86, 86, 13, 13, 86, 86, 86, 86, 86, 86, 86, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 86, 86, 86, 86, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+602,602,602,603,603,603,603,603,603,603,603,603,603,603,603,603,
+603,603,603,603,603,603,603,603,603,603,603,603,603,603,603,603,
+603,603,603,603,603,603,603,602,602,602,602,602,604,602,602,602,
+602,602,602,602,602,109,605,605,605,605,605,605,605,605,605,605,
+606,606,606,606,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 154 */
-482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
-482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
-482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
-482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,482,
-482,482,538,538,538,482, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+607,607,608,609,609,609,609,609,609,609,609,609,609,609,609,609,
+609,609,609,609,609,609,609,609,609,609,609,609,609,609,609,609,
+609,609,609,609,609,609,609,609,609,609,609,609,609,609,609,609,
+609,609,609,608,608,608,607,607,607,607,607,607,607,607,607,608,
+608,609,609,609,609,610,610,610,610,109,109,109,109,109,109,109,
+611,611,611,611,611,611,611,611,611,611,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 155 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17,
- 17, 17, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+612,612,612,612,612,612,612,612,612,612,612,612,612,612,612,612,
+612,612,612,612,612,612,612,612,612,612,612,612,612,612,612,612,
+612,612,612,612,612,612,612,612,612,612,612,613,614,613,614,614,
+613,613,613,613,613,613,614,613,109,109,109,109,109,109,109,109,
+615,615,615,615,615,615,615,615,615,615,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 156 */
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,369,369,369,369,369,369,369,369,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,370,370,
-370,370,370,370,370, 91,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,369,369,369,369,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
/* block 157 */
-369,369,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,369, 91,369,369,
- 91, 91,369, 91, 91,369,369, 91, 91,369,369,369,369, 91,369,369,
-369,369,369,369,369,369,370,370,370,370, 91,370, 91,370,370,370,
-370,370,370,370, 91,370,370,370,370,370,370,370,370,370,370,370,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,
+616,616,616,616,616,616,616,616,616,616,616,616,616,616,616,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 158 */
-370,370,370,370,369,369, 91,369,369,369,369, 91, 91,369,369,369,
-369,369,369,369,369, 91,369,369,369,369,369,369,369, 91,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,369,369, 91,369,369,369,369, 91,
-369,369,369,369,369, 91,369, 91, 91, 91,369,369,369,369,369,369,
-369, 91,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,
+617,617,617,617,617,617,617,617,617,617,617,617,617,617,617,617,
+617,617,617,617,617,617,617,617,617,617,617,617,617,617,617,617,
+617,617,617,617,617,617,617,617,617,617,617,617,617,617,617,617,
+617,617,617,617,617,617,617,617,617,617,617,617,617,617,617,617,
+617,617,617,617,617,617,617,617,617,617,617,617,617,617,617,617,
+617,617,617,617,617,617,617,617,617,617,617,617,617,617,617,617,
+617,617,617,109,109,109,109,109,109,109,109,109,109,109,109,109,
+618,618,618,618,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 159 */
-369,369,369,369,369,369,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,369,369,369,369,369,369,369,369,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
+619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,
+619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,
+619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,
+619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,
+619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,
+619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,
+619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,
+619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,
/* block 160 */
-370,370,370,370,370,370,370,370,369,369,369,369,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,
-369,369,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,
-369,369,369,369,369,369,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,
+619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,
+619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,
+619,619,619,619,619,619,619,619,619,619,619,619,619,619,619,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 161 */
-369,369,369,369,369,369,369,369,369,369,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,370,370, 91, 91,369,369,369,369,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,
-369, 6,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,370,370,370, 6,370,370,370,370,
-370,370,369,369,369,369,369,369,369,369,369,369,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,369, 6,370,370,370,370,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
/* block 162 */
-370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,370, 6,370,370,370,370,370,370,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,
-369,369,369,369,369, 6,370,370,370,370,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,370,370,370, 6,
-370,370,370,370,370,370,369,369,369,369,369,369,369,369,369,369,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,369, 6,
-370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,488,
+488,488,488,488,488,488,488,488,488,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 163 */
-370,370,370,370,370,370,370,370,370, 6,370,370,370,370,370,370,
-369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,369,
-369,369,369,369,369,369,369,369,369, 6,370,370,370,370,370,370,
-370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,370,
-370,370,370, 6,370,370,370,370,370,370,369,370, 91, 91, 8, 8,
- 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
- 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
- 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
+620,620,620,620,620,620,620,620,620,620,620,620,620,620,620,620,
+620,620,620,620,620,620,620,620,620,620,620,620,620,620,620,620,
+620,620,620,620,620,620,620,620,620,620,620,620,620,620,620,620,
+620,620,620,620,620,620,620,620,620,620,620,620,620,620,620,620,
+620,620,620,620,620,109,109,109,109,109,109,109,109,109,109,109,
+620,621,621,621,621,621,621,621,621,621,621,621,621,621,621,621,
+621,621,621,621,621,621,621,621,621,621,621,621,621,621,621,621,
+621,621,621,621,621,621,621,621,621,621,621,621,621,621,621,109,
/* block 164 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,622,
+622,622,622,623,623,623,623,623,623,623,623,623,623,623,623,623,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 165 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91,
- 91, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91,
- 91, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 91, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+469,467,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 166 */
- 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19,109,109,109,109,109,109,109,109,109,109,
/* block 167 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19,109,109, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19,624,395,104,104,104, 19, 19, 19,395,624,624,
+624,624,624, 22, 22, 22, 22, 22, 22, 22, 22,104,104,104,104,104,
/* block 168 */
-539, 13, 13, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 91, 91, 91, 91, 91, 91, 91,
- 13, 13, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+104,104,104, 19, 19,104,104,104,104,104,104,104, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,104,104,104,104, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 169 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 91, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91, 91, 91,
+546,546,546,546,546,546,546,546,546,546,546,546,546,546,546,546,
+546,546,546,546,546,546,546,546,546,546,546,546,546,546,546,546,
+546,546,546,546,546,546,546,546,546,546,546,546,546,546,546,546,
+546,546,546,546,546,546,546,546,546,546,546,546,546,546,546,546,
+546,546,625,625,625,546,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 170 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 91, 13, 13, 13, 13, 13, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19,109,109,109,109,109,109,109,109,109,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
+ 23, 23,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 171 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91,
- 13, 91, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,428,428,428,428,428,428,428,428,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,429,429,
+429,429,429,429,429,109,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,428,428,428,428,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
/* block 172 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 91, 13, 13, 13, 13, 91, 91, 91,
+428,428,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,428,109,428,428,
+109,109,428,109,109,428,428,109,109,428,428,428,428,109,428,428,
+428,428,428,428,428,428,429,429,429,429,109,429,109,429,429,429,
+429,429,429,429,109,429,429,429,429,429,429,429,429,429,429,429,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
/* block 173 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+429,429,429,429,428,428,109,428,428,428,428,109,109,428,428,428,
+428,428,428,428,428,109,428,428,428,428,428,428,428,109,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,428,428,109,428,428,428,428,109,
+428,428,428,428,428,109,428,109,109,109,428,428,428,428,428,428,
+428,109,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
/* block 174 */
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 13, 13, 13, 13, 13,
+428,428,428,428,428,428,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,428,428,428,428,428,428,428,428,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
/* block 175 */
- 91, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 91, 13, 13, 13, 91, 13, 91, 13, 91, 13, 91, 13, 13, 13, 91,
- 13, 13, 13, 13, 13, 13, 91, 91, 13, 13, 13, 13, 91, 13, 91, 91,
- 13, 13, 13, 13, 91, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 91, 91, 91, 91, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+429,429,429,429,429,429,429,429,428,428,428,428,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
+428,428,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
+428,428,428,428,428,428,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
/* block 176 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+428,428,428,428,428,428,428,428,428,428,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,429,429,109,109,428,428,428,428,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
+428, 8,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,429,429,429, 8,429,429,429,429,
+429,429,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,428, 8,429,429,429,429,
/* block 177 */
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
- 13, 13, 13, 13, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,429, 8,429,429,429,429,429,429,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
+428,428,428,428,428, 8,429,429,429,429,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,429,429,429, 8,
+429,429,429,429,429,429,428,428,428,428,428,428,428,428,428,428,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,428, 8,
+429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
/* block 178 */
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+429,429,429,429,429,429,429,429,429, 8,429,429,429,429,429,429,
+428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,428,
+428,428,428,428,428,428,428,428,428, 8,429,429,429,429,429,429,
+429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,429,
+429,429,429, 8,429,429,429,429,429,429,428,429,109,109, 10, 10,
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
/* block 179 */
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
+191,191,191,191,109,191,191,191,191,191,191,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,191,
+109,191,191,109,191,109,109,191,109,191,191,191,191,191,191,191,
+191,191,191,109,191,191,191,191,109,191,109,191,109,109,109,109,
+109,109,191,109,109,109,109,191,109,191,109,191,109,191,191,191,
+109,191,191,109,191,109,109,191,109,191,109,191,109,191,109,191,
+109,191,191,109,191,109,109,191,191,191,191,109,191,191,191,191,
+191,191,191,109,191,191,191,191,109,191,191,191,191,109,191,109,
/* block 180 */
-415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,415,
-415,415,415,415,415,415,415,415,415,415,415,415,415,415, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+191,191,191,191,191,191,191,191,191,191,109,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,109,109,109,109,
+109,191,191,191,109,191,191,191,191,191,109,191,191,191,191,191,
+191,191,191,191,191,191,191,191,191,191,191,191,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+186,186,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 181 */
- 91, 16, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
- 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
- 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
- 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
- 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
- 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
/* block 182 */
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19,109,109,109,109,109,109,109,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,
+109, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,
+109, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+109, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
/* block 183 */
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86, 86,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
+ 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
/* block 184 */
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,476,
-476,476,476,476,476,476,476,476,476,476,476,476,476,476, 91, 91,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,626,626,626,626,626,626,626,626,626,626,
+626,626,626,626,626,626,626,626,626,626,626,626,626,626,626,626,
+
+/* block 185 */
+627, 19, 19,109,109,109,109,109,109,109,109,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19,109,109,109,109,109,109,109,
+ 19, 19,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+
+/* block 186 */
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19,109, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,109,109,
+
+/* block 187 */
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19,109,109,109,109,109,109,109,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19,109, 19, 19, 19, 19, 19,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+
+/* block 188 */
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,
+ 19,109, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+
+/* block 189 */
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19,109, 19, 19, 19, 19,109,109,109,
+
+/* block 190 */
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,109,109,
+ 19, 19, 19, 19,109,109,109,109,109,109,109,109,109,109,109,109,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+
+/* block 191 */
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109, 19, 19, 19, 19, 19,
+
+/* block 192 */
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19,109,109,109,109, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+
+/* block 193 */
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+
+/* block 194 */
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19,
+ 19, 19, 19, 19,109,109,109,109,109,109,109,109,109,109,109,109,
+
+/* block 195 */
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+
+/* block 196 */
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,109,109,109,109,109,109,109,109,109,109,109,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+
+/* block 197 */
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,475,
+475,475,475,475,475,475,475,475,475,475,475,475,475,475,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,109,
+
+/* block 198 */
+426, 22,426,426,426,426,426,426,426,426,426,426,426,426,426,426,
+426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,
+ 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22,
+ 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22,
+ 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22,
+ 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22,
+ 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22,
+ 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22,
+
+/* block 199 */
+426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,
+426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,
+426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,
+426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,
+426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,
+426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,
+426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,
+426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,
+
+/* block 200 */
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+
+/* block 201 */
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,104,
+426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,426,
+
+/* block 202 */
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,539,
+539,539,539,539,539,539,539,539,539,539,539,539,539,539,109,109,
};
@@ -2979,3 +3294,5 @@ const pcre_uint16 PRIV(ucd_stage2)[] = { /* 47360 bytes, block = 128 */
#error Please correct UCD_BLOCK_SIZE in pcre_internal.h
#endif
#endif /* SUPPORT_UCP */
+
+#endif /* PCRE_INCLUDED */
diff --git a/src/3rdparty/pcre/pcre_valid_utf8.c b/src/3rdparty/pcre/pcre_valid_utf8.c
index b2dc5c9f1a..e5b533467d 100644
--- a/src/3rdparty/pcre/pcre_valid_utf8.c
+++ b/src/3rdparty/pcre/pcre_valid_utf8.c
@@ -92,6 +92,7 @@ PCRE_UTF8_ERR18 Overlong 5-byte sequence (won't ever occur)
PCRE_UTF8_ERR19 Overlong 6-byte sequence (won't ever occur)
PCRE_UTF8_ERR20 Isolated 0x80 byte (not within UTF-8 character)
PCRE_UTF8_ERR21 Byte with the illegal value 0xfe or 0xff
+PCRE_UTF8_ERR22 Non-character
Arguments:
string points to the string
@@ -116,7 +117,8 @@ if (length < 0)
for (p = string; length-- > 0; p++)
{
- register int ab, c, d;
+ register pcre_uchar ab, c, d;
+ pcre_uint32 v = 0;
c = *p;
if (c < 128) continue; /* ASCII character */
@@ -185,6 +187,7 @@ for (p = string; length-- > 0; p++)
*erroroffset = (int)(p - string) - 2;
return PCRE_UTF8_ERR14;
}
+ v = ((c & 0x0f) << 12) | ((d & 0x3f) << 6) | (*p & 0x3f);
break;
/* 4-byte character. Check 3rd and 4th bytes for 0x80. Then check first 2
@@ -212,6 +215,7 @@ for (p = string; length-- > 0; p++)
*erroroffset = (int)(p - string) - 3;
return PCRE_UTF8_ERR13;
}
+ v = ((c & 0x07) << 18) | ((d & 0x3f) << 12) | ((p[-1] & 0x3f) << 6) | (*p & 0x3f);
break;
/* 5-byte and 6-byte characters are not allowed by RFC 3629, and will be
@@ -286,11 +290,20 @@ for (p = string; length-- > 0; p++)
*erroroffset = (int)(p - string) - ab;
return (ab == 4)? PCRE_UTF8_ERR11 : PCRE_UTF8_ERR12;
}
+
+ /* Reject non-characters. The pointer p is currently at the last byte of the
+ character. */
+ if ((v & 0xfffeu) == 0xfffeu || (v >= 0xfdd0 && v <= 0xfdef))
+ {
+ *erroroffset = (int)(p - string) - ab;
+ return PCRE_UTF8_ERR22;
+ }
}
-#else /* SUPPORT_UTF */
+#else /* Not SUPPORT_UTF */
(void)(string); /* Keep picky compilers happy */
(void)(length);
+(void)(erroroffset);
#endif
return PCRE_UTF8_ERR0; /* This indicates success */
diff --git a/src/3rdparty/pcre/pcre_version.c b/src/3rdparty/pcre/pcre_version.c
index 915ae8764c..cb57bf34a5 100644
--- a/src/3rdparty/pcre/pcre_version.c
+++ b/src/3rdparty/pcre/pcre_version.c
@@ -79,12 +79,15 @@ I could find no way of detecting that a macro is defined as an empty string at
pre-processor time. This hack uses a standard trick for avoiding calling
the STRING macro with an empty argument when doing the test. */
-#ifdef COMPILE_PCRE8
+#if defined COMPILE_PCRE8
PCRE_EXP_DEFN const char * PCRE_CALL_CONVENTION
pcre_version(void)
-#else
+#elif defined COMPILE_PCRE16
PCRE_EXP_DEFN const char * PCRE_CALL_CONVENTION
pcre16_version(void)
+#elif defined COMPILE_PCRE32
+PCRE_EXP_DEFN const char * PCRE_CALL_CONVENTION
+pcre32_version(void)
#endif
{
return (XSTRING(Z PCRE_PRERELEASE)[1] == 0)?
diff --git a/src/3rdparty/pcre/pcre_xclass.c b/src/3rdparty/pcre/pcre_xclass.c
index 45f1c5b152..595cafb2aa 100644
--- a/src/3rdparty/pcre/pcre_xclass.c
+++ b/src/3rdparty/pcre/pcre_xclass.c
@@ -64,9 +64,9 @@ Returns: TRUE if character matches, else FALSE
*/
BOOL
-PRIV(xclass)(int c, const pcre_uchar *data, BOOL utf)
+PRIV(xclass)(pcre_uint32 c, const pcre_uchar *data, BOOL utf)
{
-int t;
+pcre_uchar t;
BOOL negated = (*data & XCL_NOT) != 0;
(void)utf;
@@ -94,7 +94,7 @@ if ((*data++ & XCL_MAP) != 0) data += 32 / sizeof(pcre_uchar);
while ((t = *data++) != XCL_END)
{
- int x, y;
+ pcre_uint32 x, y;
if (t == XCL_SINGLE)
{
#ifdef SUPPORT_UTF
diff --git a/src/3rdparty/pcre/sljit/sljitConfig.h b/src/3rdparty/pcre/sljit/sljitConfig.h
index c832dfe60d..68bc59d089 100644
--- a/src/3rdparty/pcre/sljit/sljitConfig.h
+++ b/src/3rdparty/pcre/sljit/sljitConfig.h
@@ -28,10 +28,17 @@
#define _SLJIT_CONFIG_H_
/* --------------------------------------------------------------------- */
+/* Custom defines */
+/* --------------------------------------------------------------------- */
+
+/* Put your custom defines here. This empty section will never change
+ which helps maintaining patches (with diff / patch utilities). */
+
+/* --------------------------------------------------------------------- */
/* Architecture */
/* --------------------------------------------------------------------- */
-/* Architecture selection */
+/* Architecture selection. */
/* #define SLJIT_CONFIG_X86_32 1 */
/* #define SLJIT_CONFIG_X86_64 1 */
/* #define SLJIT_CONFIG_ARM_V5 1 */
@@ -40,6 +47,7 @@
/* #define SLJIT_CONFIG_PPC_32 1 */
/* #define SLJIT_CONFIG_PPC_64 1 */
/* #define SLJIT_CONFIG_MIPS_32 1 */
+/* #define SLJIT_CONFIG_SPARC_32 1 */
/* #define SLJIT_CONFIG_AUTO 1 */
/* #define SLJIT_CONFIG_UNSUPPORTED 1 */
@@ -60,6 +68,12 @@
#define SLJIT_UTIL_STACK 1
#endif
+/* Single threaded application. Does not require any locks. */
+#ifndef SLJIT_SINGLE_THREADED
+/* Disabled by default. */
+#define SLJIT_SINGLE_THREADED 0
+#endif
+
/* --------------------------------------------------------------------- */
/* Configuration */
/* --------------------------------------------------------------------- */
diff --git a/src/3rdparty/pcre/sljit/sljitConfigInternal.h b/src/3rdparty/pcre/sljit/sljitConfigInternal.h
index de6e9f07e2..2b6616ef66 100644
--- a/src/3rdparty/pcre/sljit/sljitConfigInternal.h
+++ b/src/3rdparty/pcre/sljit/sljitConfigInternal.h
@@ -33,18 +33,23 @@
Feature detection (boolean) macros:
SLJIT_32BIT_ARCHITECTURE : 32 bit architecture
SLJIT_64BIT_ARCHITECTURE : 64 bit architecture
- SLJIT_WORD_SHIFT : the shift required to apply when accessing a sljit_w/sljit_uw array by index
- SLJIT_FLOAT_SHIFT : the shift required to apply when accessing a double array by index
+ SLJIT_WORD_SHIFT : the shift required to apply when accessing a sljit_sw/sljit_uw array by index
+ SLJIT_DOUBLE_SHIFT : the shift required to apply when accessing a double array by index
SLJIT_LITTLE_ENDIAN : little endian architecture
SLJIT_BIG_ENDIAN : big endian architecture
SLJIT_UNALIGNED : allows unaligned memory accesses for non-fpu operations (only!)
SLJIT_INDIRECT_CALL : see SLJIT_FUNC_OFFSET() for more information
+ SLJIT_RETURN_ADDRESS_OFFSET : a return instruction always adds this offset to the return address
Types and useful macros:
- sljit_b, sljit_ub : signed and unsigned 8 bit byte
- sljit_h, sljit_uh : signed and unsigned 16 bit half-word (short) type
- sljit_i, sljit_ui : signed and unsigned 32 bit integer type
- sljit_w, sljit_uw : signed and unsigned machine word, enough to store a pointer (same as intptr_t)
+ sljit_sb, sljit_ub : signed and unsigned 8 bit byte
+ sljit_sh, sljit_uh : signed and unsigned 16 bit half-word (short) type
+ sljit_si, sljit_ui : signed and unsigned 32 bit integer type
+ sljit_sw, sljit_uw : signed and unsigned machine word, enough to store a pointer
+ sljit_p : unsgined pointer value (usually the same as sljit_uw, but
+ some 64 bit ABIs may use 32 bit pointers)
+ sljit_s : single precision floating point value
+ sljit_d : double precision floating point value
SLJIT_CALL : C calling convention define for both calling JIT form C and C callbacks for JIT
SLJIT_W(number) : defining 64 bit constants on 64 bit architectures (compiler independent helper)
*/
@@ -57,6 +62,7 @@
|| (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32) \
|| (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64) \
|| (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32) \
+ || (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32) \
|| (defined SLJIT_CONFIG_AUTO && SLJIT_CONFIG_AUTO) \
|| (defined SLJIT_CONFIG_UNSUPPORTED && SLJIT_CONFIG_UNSUPPORTED))
#error "An architecture must be selected"
@@ -71,6 +77,7 @@
+ (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32) \
+ (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64) \
+ (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32) \
+ + (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32) \
+ (defined SLJIT_CONFIG_AUTO && SLJIT_CONFIG_AUTO) \
+ (defined SLJIT_CONFIG_UNSUPPORTED && SLJIT_CONFIG_UNSUPPORTED) >= 2
#error "Multiple architectures are selected"
@@ -93,12 +100,14 @@
#else
#define SLJIT_CONFIG_ARM_V5 1
#endif
-#elif defined(__ppc64__) || defined(__powerpc64__)
+#elif defined(__ppc64__) || defined(__powerpc64__) || defined(_ARCH_PPC64) || (defined(_POWER) && defined(__64BIT__))
#define SLJIT_CONFIG_PPC_64 1
-#elif defined(__ppc__) || defined(__powerpc__)
+#elif defined(__ppc__) || defined(__powerpc__) || defined(_ARCH_PPC) || defined(_ARCH_PWR) || defined(_ARCH_PWR2) || defined(_POWER)
#define SLJIT_CONFIG_PPC_32 1
#elif defined(__mips__)
#define SLJIT_CONFIG_MIPS_32 1
+#elif defined(__sparc__) || defined(__sparc)
+#define SLJIT_CONFIG_SPARC_32 1
#else
/* Unsupported architecture */
#define SLJIT_CONFIG_UNSUPPORTED 1
@@ -194,16 +203,31 @@
#ifndef SLJIT_CACHE_FLUSH
-#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32) || (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
+#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
+
+/* Not required to implement on archs with unified caches. */
+#define SLJIT_CACHE_FLUSH(from, to)
+
+#elif defined __APPLE__
+
+/* Supported by all macs since Mac OS 10.5.
+ However, it does not work on non-jailbroken iOS devices,
+ although the compilation is successful. */
+
+#define SLJIT_CACHE_FLUSH(from, to) \
+ sys_icache_invalidate((char*)(from), (char*)(to) - (char*)(from))
+
+#elif (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32) || (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
/* The __clear_cache() implementation of GCC is a dummy function on PowerPC. */
#define SLJIT_CACHE_FLUSH(from, to) \
ppc_cache_flush((from), (to))
-#elif (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
+#elif (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
-/* Not required to implement on archs with unified caches. */
-#define SLJIT_CACHE_FLUSH(from, to)
+/* The __clear_cache() implementation of GCC is a dummy function on Sparc. */
+#define SLJIT_CACHE_FLUSH(from, to) \
+ sparc_cache_flush((from), (to))
#else
@@ -217,15 +241,15 @@
/* 8 bit byte type. */
typedef unsigned char sljit_ub;
-typedef signed char sljit_b;
+typedef signed char sljit_sb;
/* 16 bit half-word type. */
typedef unsigned short int sljit_uh;
-typedef signed short int sljit_h;
+typedef signed short int sljit_sh;
/* 32 bit integer type. */
typedef unsigned int sljit_ui;
-typedef signed int sljit_i;
+typedef signed int sljit_si;
/* Machine word type. Can encapsulate a pointer.
32 bit for 32 bit machines.
@@ -234,26 +258,35 @@ typedef signed int sljit_i;
/* Just to have something. */
#define SLJIT_WORD_SHIFT 0
typedef unsigned long int sljit_uw;
-typedef long int sljit_w;
+typedef long int sljit_sw;
#elif !(defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) && !(defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
#define SLJIT_32BIT_ARCHITECTURE 1
#define SLJIT_WORD_SHIFT 2
typedef unsigned int sljit_uw;
-typedef int sljit_w;
+typedef int sljit_sw;
#else
#define SLJIT_64BIT_ARCHITECTURE 1
#define SLJIT_WORD_SHIFT 3
#ifdef _WIN32
typedef unsigned __int64 sljit_uw;
-typedef __int64 sljit_w;
+typedef __int64 sljit_sw;
#else
typedef unsigned long int sljit_uw;
-typedef long int sljit_w;
+typedef long int sljit_sw;
#endif
#endif
-/* Double precision. */
-#define SLJIT_FLOAT_SHIFT 3
+typedef sljit_uw sljit_p;
+
+/* Floating point types. */
+typedef float sljit_s;
+typedef double sljit_d;
+
+/* Shift for pointer sized data. */
+#define SLJIT_POINTER_SHIFT SLJIT_WORD_SHIFT
+
+/* Shift for double precision sized data. */
+#define SLJIT_DOUBLE_SHIFT 3
#ifndef SLJIT_W
@@ -276,20 +309,24 @@ typedef long int sljit_w;
#define SLJIT_CALL __attribute__ ((fastcall))
#define SLJIT_X86_32_FASTCALL 1
-#elif defined(_WIN32)
+#elif defined(_MSC_VER)
-#ifdef __BORLANDC__
-#define SLJIT_CALL __msfastcall
-#else /* __BORLANDC__ */
#define SLJIT_CALL __fastcall
-#endif /* __BORLANDC__ */
#define SLJIT_X86_32_FASTCALL 1
-#else /* defined(_WIN32) */
-#define SLJIT_CALL __stdcall
+#elif defined(__BORLANDC__)
+
+#define SLJIT_CALL __msfastcall
+#define SLJIT_X86_32_FASTCALL 1
+
+#else /* Unknown compiler. */
+
+/* The cdecl attribute is the default. */
+#define SLJIT_CALL
+
#endif
-#else /* Other architectures. */
+#else /* Non x86-32 architectures. */
#define SLJIT_CALL
@@ -300,7 +337,9 @@ typedef long int sljit_w;
#if !defined(SLJIT_BIG_ENDIAN) && !defined(SLJIT_LITTLE_ENDIAN)
/* These macros are useful for the application. */
-#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32) || (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
+#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32) \
+ || (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64) \
+ || (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
#define SLJIT_BIG_ENDIAN 1
#elif (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
@@ -326,23 +365,32 @@ typedef long int sljit_w;
#error "Exactly one endianness must be selected"
#endif
-#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
-/* It seems ppc64 compilers use an indirect addressing for functions.
- It makes things really complicated. */
+#ifndef SLJIT_INDIRECT_CALL
+#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64) || (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32 && defined _AIX)
+/* It seems certain ppc compilers use an indirect addressing for functions
+ which makes things complicated. */
#define SLJIT_INDIRECT_CALL 1
#endif
+#endif /* SLJIT_INDIRECT_CALL */
+
+#ifndef SLJIT_RETURN_ADDRESS_OFFSET
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+#define SLJIT_RETURN_ADDRESS_OFFSET 8
+#else
+#define SLJIT_RETURN_ADDRESS_OFFSET 0
+#endif
+#endif /* SLJIT_RETURN_ADDRESS_OFFSET */
#ifndef SLJIT_SSE2
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
-/* Turn on SSE2 support on x86 (operating on doubles).
- (Better performance than legacy fpu instructions). */
+/* Turn on SSE2 support on x86. */
#define SLJIT_SSE2 1
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
/* Auto detect SSE2 support using CPUID.
On 64 bit x86 cpus, sse2 must be present. */
-#define SLJIT_SSE2_AUTO 1
+#define SLJIT_DETECT_SSE2 1
#endif
#endif /* (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) */
@@ -369,17 +417,28 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_free_exec(void* ptr);
#define SLJIT_FREE_EXEC(ptr) sljit_free_exec(ptr)
#endif
-#if (defined SLJIT_DEBUG && SLJIT_DEBUG) || (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
+#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
#include <stdio.h>
#endif
#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
-/* Feel free to redefine these two macros. */
-#ifndef SLJIT_ASSERT
+#if !defined(SLJIT_ASSERT) || !defined(SLJIT_ASSERT_STOP)
+
+/* SLJIT_HALT_PROCESS must halt the process. */
+#ifndef SLJIT_HALT_PROCESS
+#include <stdlib.h>
#define SLJIT_HALT_PROCESS() \
- *((int*)0) = 0
+ abort();
+#endif /* !SLJIT_HALT_PROCESS */
+
+#include <stdio.h>
+
+#endif /* !SLJIT_ASSERT || !SLJIT_ASSERT_STOP */
+
+/* Feel free to redefine these two macros. */
+#ifndef SLJIT_ASSERT
#define SLJIT_ASSERT(x) \
do { \
@@ -403,6 +462,7 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_free_exec(void* ptr);
#else /* (defined SLJIT_DEBUG && SLJIT_DEBUG) */
+/* Forcing empty, but valid statements. */
#undef SLJIT_ASSERT
#undef SLJIT_ASSERT_STOP
diff --git a/src/3rdparty/pcre/sljit/sljitExecAllocator.c b/src/3rdparty/pcre/sljit/sljitExecAllocator.c
index f66744df82..75a38991d5 100644
--- a/src/3rdparty/pcre/sljit/sljitExecAllocator.c
+++ b/src/3rdparty/pcre/sljit/sljitExecAllocator.c
@@ -52,7 +52,7 @@
The unused blocks are stored in a chain list pointed by free_blocks. This
list is useful if we need to find a suitable memory area when the allocator
is called.
-
+
When a block is freed, the new free block is connected to its adjacent free
blocks if possible.
@@ -83,7 +83,7 @@
static SLJIT_INLINE void* alloc_chunk(sljit_uw size)
{
- return VirtualAlloc(0, size, MEM_COMMIT | MEM_RESERVE, PAGE_EXECUTE_READWRITE);
+ return VirtualAlloc(NULL, size, MEM_COMMIT | MEM_RESERVE, PAGE_EXECUTE_READWRITE);
}
static SLJIT_INLINE void free_chunk(void* chunk, sljit_uw size)
@@ -94,11 +94,20 @@ static SLJIT_INLINE void free_chunk(void* chunk, sljit_uw size)
#else
-#include <sys/mman.h>
-
static SLJIT_INLINE void* alloc_chunk(sljit_uw size)
{
- void* retval = mmap(0, size, PROT_READ | PROT_WRITE | PROT_EXEC, MAP_PRIVATE | MAP_ANON, -1, 0);
+ void* retval;
+
+#ifdef MAP_ANON
+ retval = mmap(NULL, size, PROT_READ | PROT_WRITE | PROT_EXEC, MAP_PRIVATE | MAP_ANON, -1, 0);
+#else
+ if (dev_zero < 0) {
+ if (open_dev_zero())
+ return NULL;
+ }
+ retval = mmap(NULL, size, PROT_READ | PROT_WRITE | PROT_EXEC, MAP_PRIVATE, dev_zero, 0);
+#endif
+
return (retval != MAP_FAILED) ? retval : NULL;
}
@@ -202,7 +211,10 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_malloc_exec(sljit_uw size)
chunk_size = (size + sizeof(struct block_header) + CHUNK_SIZE - 1) & CHUNK_MASK;
header = (struct block_header*)alloc_chunk(chunk_size);
- PTR_FAIL_IF(!header);
+ if (!header) {
+ allocator_release_lock();
+ return NULL;
+ }
chunk_size -= sizeof(struct block_header);
total_size += chunk_size;
@@ -237,14 +249,14 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_free_exec(void* ptr)
struct free_block* free_block;
allocator_grab_lock();
- header = AS_BLOCK_HEADER(ptr, -(sljit_w)sizeof(struct block_header));
+ header = AS_BLOCK_HEADER(ptr, -(sljit_sw)sizeof(struct block_header));
allocated_size -= header->size;
/* Connecting free blocks together if possible. */
/* If header->prev_size == 0, free_block will equal to header.
In this case, free_block->header.size will be > 0. */
- free_block = AS_FREE_BLOCK(header, -(sljit_w)header->prev_size);
+ free_block = AS_FREE_BLOCK(header, -(sljit_sw)header->prev_size);
if (SLJIT_UNLIKELY(!free_block->header.size)) {
free_block->size += header->size;
header = AS_BLOCK_HEADER(free_block, free_block->size);
diff --git a/src/3rdparty/pcre/sljit/sljitLir.c b/src/3rdparty/pcre/sljit/sljitLir.c
index c1fa5e4af9..6979841070 100644
--- a/src/3rdparty/pcre/sljit/sljitLir.c
+++ b/src/3rdparty/pcre/sljit/sljitLir.c
@@ -89,7 +89,10 @@
((op) & (SLJIT_SET_E | SLJIT_SET_S | SLJIT_SET_U | SLJIT_SET_O | SLJIT_SET_C))
#define GET_ALL_FLAGS(op) \
- ((op) & (SLJIT_SET_E | SLJIT_SET_S | SLJIT_SET_U | SLJIT_SET_O | SLJIT_SET_C | SLJIT_KEEP_FLAGS))
+ ((op) & (SLJIT_INT_OP | SLJIT_SET_E | SLJIT_SET_S | SLJIT_SET_U | SLJIT_SET_O | SLJIT_SET_C | SLJIT_KEEP_FLAGS))
+
+#define TYPE_CAST_NEEDED(op) \
+ (((op) >= SLJIT_MOV_UB && (op) <= SLJIT_MOV_SH) || ((op) >= SLJIT_MOVU_UB && (op) <= SLJIT_MOVU_SH))
#define BUF_SIZE 4096
@@ -105,65 +108,145 @@
/* SLJIT_REWRITABLE_JUMP is 0x1000. */
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- #define PATCH_MB 0x4
- #define PATCH_MW 0x8
+# define PATCH_MB 0x4
+# define PATCH_MW 0x8
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- #define PATCH_MD 0x10
+# define PATCH_MD 0x10
#endif
#endif
#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5) || (defined SLJIT_CONFIG_ARM_V7 && SLJIT_CONFIG_ARM_V7)
- #define IS_BL 0x4
- #define PATCH_B 0x8
+# define IS_BL 0x4
+# define PATCH_B 0x8
#endif
#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5)
- #define CPOOL_SIZE 512
+# define CPOOL_SIZE 512
#endif
#if (defined SLJIT_CONFIG_ARM_THUMB2 && SLJIT_CONFIG_ARM_THUMB2)
- #define IS_CONDITIONAL 0x04
- #define IS_BL 0x08
+# define IS_COND 0x04
+# define IS_BL 0x08
/* cannot be encoded as branch */
- #define B_TYPE0 0x00
+# define B_TYPE0 0x00
/* conditional + imm8 */
- #define B_TYPE1 0x10
+# define B_TYPE1 0x10
/* conditional + imm20 */
- #define B_TYPE2 0x20
+# define B_TYPE2 0x20
/* IT + imm24 */
- #define B_TYPE3 0x30
+# define B_TYPE3 0x30
/* imm11 */
- #define B_TYPE4 0x40
+# define B_TYPE4 0x40
/* imm24 */
- #define B_TYPE5 0x50
+# define B_TYPE5 0x50
/* BL + imm24 */
- #define BL_TYPE6 0x60
+# define BL_TYPE6 0x60
/* 0xf00 cc code for branches */
#endif
#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32) || (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
- #define UNCOND_B 0x04
- #define PATCH_B 0x08
- #define ABSOLUTE_B 0x10
+# define UNCOND_B 0x04
+# define PATCH_B 0x08
+# define ABSOLUTE_B 0x10
#endif
#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
- #define IS_MOVABLE 0x04
- #define IS_JAL 0x08
- #define IS_BIT26_COND 0x10
- #define IS_BIT16_COND 0x20
+# define IS_MOVABLE 0x04
+# define IS_JAL 0x08
+# define IS_BIT26_COND 0x10
+# define IS_BIT16_COND 0x20
- #define IS_COND (IS_BIT26_COND | IS_BIT16_COND)
+# define IS_COND (IS_BIT26_COND | IS_BIT16_COND)
- #define PATCH_B 0x40
- #define PATCH_J 0x80
+# define PATCH_B 0x40
+# define PATCH_J 0x80
/* instruction types */
- #define UNMOVABLE_INS 0
+# define MOVABLE_INS 0
/* 1 - 31 last destination register */
- #define FCSR_FCC 32
/* no destination (i.e: store) */
- #define MOVABLE_INS 33
+# define UNMOVABLE_INS 32
+ /* FPU status register */
+# define FCSR_FCC 33
+#endif
+
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+# define IS_MOVABLE 0x04
+# define IS_COND 0x08
+# define IS_CALL 0x10
+
+# define PATCH_B 0x20
+# define PATCH_CALL 0x40
+
+ /* instruction types */
+# define MOVABLE_INS 0
+ /* 1 - 31 last destination register */
+ /* no destination (i.e: store) */
+# define UNMOVABLE_INS 32
+
+# define DST_INS_MASK 0xff
+
+ /* ICC_SET is the same as SET_FLAGS. */
+# define ICC_IS_SET (1 << 23)
+# define FCC_IS_SET (1 << 24)
+#endif
+
+#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
+#define SLJIT_HAS_VARIABLE_LOCALS_OFFSET 1
+#if !(defined SLJIT_X86_32_FASTCALL && SLJIT_X86_32_FASTCALL)
+#define FIXED_LOCALS_OFFSET (3 * sizeof(sljit_sw))
+#endif
+#endif
+
+#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
+#define SLJIT_HAS_FIXED_LOCALS_OFFSET 1
+#ifdef _WIN64
+#define FIXED_LOCALS_OFFSET ((4 + 2) * sizeof(sljit_sw))
+#else
+#define FIXED_LOCALS_OFFSET (sizeof(sljit_sw))
+#endif
+#endif
+
+#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32)
+#define SLJIT_HAS_FIXED_LOCALS_OFFSET 1
+#if (defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL)
+#define FIXED_LOCALS_OFFSET ((6 + 8) * sizeof(sljit_sw))
+#else
+#define FIXED_LOCALS_OFFSET (2 * sizeof(sljit_sw))
+#endif
+#endif
+
+#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
+#define SLJIT_HAS_FIXED_LOCALS_OFFSET 1
+#define FIXED_LOCALS_OFFSET ((6 + 8) * sizeof(sljit_sw))
+#endif
+
+#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
+#define SLJIT_HAS_FIXED_LOCALS_OFFSET 1
+#define FIXED_LOCALS_OFFSET (4 * sizeof(sljit_sw))
+#endif
+
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+#define SLJIT_HAS_FIXED_LOCALS_OFFSET 1
+#define FIXED_LOCALS_OFFSET (23 * sizeof(sljit_sw))
+#endif
+
+#if (defined SLJIT_HAS_VARIABLE_LOCALS_OFFSET && SLJIT_HAS_VARIABLE_LOCALS_OFFSET)
+
+#define ADJUST_LOCAL_OFFSET(p, i) \
+ if ((p) == (SLJIT_MEM1(SLJIT_LOCALS_REG))) \
+ (i) += compiler->locals_offset;
+
+#elif (defined SLJIT_HAS_FIXED_LOCALS_OFFSET && SLJIT_HAS_FIXED_LOCALS_OFFSET)
+
+#define ADJUST_LOCAL_OFFSET(p, i) \
+ if ((p) == (SLJIT_MEM1(SLJIT_LOCALS_REG))) \
+ (i) += FIXED_LOCALS_OFFSET;
+
+#else
+
+#define ADJUST_LOCAL_OFFSET(p, i)
+
#endif
#endif /* !(defined SLJIT_CONFIG_UNSUPPORTED && SLJIT_CONFIG_UNSUPPORTED) */
@@ -187,12 +270,11 @@
#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5) || ((defined SLJIT_SSE2 && SLJIT_SSE2) && ((defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)))
#define SLJIT_NEEDS_COMPILER_INIT 1
-static int compiler_initialized = 0;
+static sljit_si compiler_initialized = 0;
/* A thread safe initialization. */
static void init_compiler(void);
#endif
-
SLJIT_API_FUNC_ATTRIBUTE struct sljit_compiler* sljit_create_compiler(void)
{
struct sljit_compiler *compiler = (struct sljit_compiler*)SLJIT_MALLOC(sizeof(struct sljit_compiler));
@@ -201,11 +283,18 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_compiler* sljit_create_compiler(void)
SLJIT_ZEROMEM(compiler, sizeof(struct sljit_compiler));
SLJIT_COMPILE_ASSERT(
- sizeof(sljit_b) == 1 && sizeof(sljit_ub) == 1
- && sizeof(sljit_h) == 2 && sizeof(sljit_uh) == 2
- && sizeof(sljit_i) == 4 && sizeof(sljit_ui) == 4
- && ((sizeof(sljit_w) == 4 && sizeof(sljit_uw) == 4) || (sizeof(sljit_w) == 8 && sizeof(sljit_uw) == 8)),
+ sizeof(sljit_sb) == 1 && sizeof(sljit_ub) == 1
+ && sizeof(sljit_sh) == 2 && sizeof(sljit_uh) == 2
+ && sizeof(sljit_si) == 4 && sizeof(sljit_ui) == 4
+ && (sizeof(sljit_p) == 4 || sizeof(sljit_p) == 8)
+ && sizeof(sljit_p) <= sizeof(sljit_sw)
+ && (sizeof(sljit_sw) == 4 || sizeof(sljit_sw) == 8)
+ && (sizeof(sljit_uw) == 4 || sizeof(sljit_uw) == 8),
invalid_integer_types);
+ SLJIT_COMPILE_ASSERT(SLJIT_INT_OP == SLJIT_SINGLE_OP,
+ int_op_and_single_op_must_be_the_same);
+ SLJIT_COMPILE_ASSERT(SLJIT_REWRITABLE_JUMP != SLJIT_SINGLE_OP,
+ rewritable_jump_and_single_op_must_not_be_the_same);
/* Only the non-zero members must be set. */
compiler->error = SLJIT_SUCCESS;
@@ -227,7 +316,7 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_compiler* sljit_create_compiler(void)
compiler->abuf->next = NULL;
compiler->abuf->used_size = 0;
- compiler->temporaries = -1;
+ compiler->scratches = -1;
compiler->saveds = -1;
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
@@ -250,6 +339,10 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_compiler* sljit_create_compiler(void)
compiler->delay_slot = UNMOVABLE_INS;
#endif
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+ compiler->delay_slot = UNMOVABLE_INS;
+#endif
+
#if (defined SLJIT_NEEDS_COMPILER_INIT && SLJIT_NEEDS_COMPILER_INIT)
if (!compiler_initialized) {
init_compiler();
@@ -291,7 +384,7 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_free_code(void* code)
/* Remove thumb mode flag. */
SLJIT_FREE_EXEC((void*)((sljit_uw)code & ~0x1));
}
-#elif (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
+#elif (defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL)
SLJIT_API_FUNC_ATTRIBUTE void sljit_free_code(void* code)
{
/* Resolve indirection. */
@@ -329,12 +422,13 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_set_target(struct sljit_jump *jump, sljit_uw
/* Private functions */
/* --------------------------------------------------------------------- */
-static void* ensure_buf(struct sljit_compiler *compiler, int size)
+static void* ensure_buf(struct sljit_compiler *compiler, sljit_uw size)
{
sljit_ub *ret;
struct sljit_memory_fragment *new_frag;
- if (compiler->buf->used_size + size <= (int)(BUF_SIZE - sizeof(sljit_uw) - sizeof(void*))) {
+ SLJIT_ASSERT(size <= 256);
+ if (compiler->buf->used_size + size <= (BUF_SIZE - (sljit_uw)SLJIT_OFFSETOF(struct sljit_memory_fragment, memory))) {
ret = compiler->buf->memory + compiler->buf->used_size;
compiler->buf->used_size += size;
return ret;
@@ -347,12 +441,13 @@ static void* ensure_buf(struct sljit_compiler *compiler, int size)
return new_frag->memory;
}
-static void* ensure_abuf(struct sljit_compiler *compiler, int size)
+static void* ensure_abuf(struct sljit_compiler *compiler, sljit_uw size)
{
sljit_ub *ret;
struct sljit_memory_fragment *new_frag;
- if (compiler->abuf->used_size + size <= (int)(ABUF_SIZE - sizeof(sljit_uw) - sizeof(void*))) {
+ SLJIT_ASSERT(size <= 256);
+ if (compiler->abuf->used_size + size <= (ABUF_SIZE - (sljit_uw)SLJIT_OFFSETOF(struct sljit_memory_fragment, memory))) {
ret = compiler->abuf->memory + compiler->abuf->used_size;
compiler->abuf->used_size += size;
return ret;
@@ -365,7 +460,7 @@ static void* ensure_abuf(struct sljit_compiler *compiler, int size)
return new_frag->memory;
}
-SLJIT_API_FUNC_ATTRIBUTE void* sljit_alloc_memory(struct sljit_compiler *compiler, int size)
+SLJIT_API_FUNC_ATTRIBUTE void* sljit_alloc_memory(struct sljit_compiler *compiler, sljit_si size)
{
CHECK_ERROR_PTR();
@@ -408,7 +503,7 @@ static SLJIT_INLINE void set_label(struct sljit_label *label, struct sljit_compi
compiler->last_label = label;
}
-static SLJIT_INLINE void set_jump(struct sljit_jump *jump, struct sljit_compiler *compiler, int flags)
+static SLJIT_INLINE void set_jump(struct sljit_jump *jump, struct sljit_compiler *compiler, sljit_si flags)
{
jump->next = NULL;
jump->flags = flags;
@@ -453,8 +548,8 @@ static SLJIT_INLINE void set_const(struct sljit_const *const_, struct sljit_comp
case SLJIT_MUL: \
SLJIT_ASSERT(!(op & (SLJIT_SET_E | SLJIT_SET_S | SLJIT_SET_U | SLJIT_SET_C))); \
break; \
- case SLJIT_FCMP: \
- SLJIT_ASSERT(!(op & (SLJIT_INT_OP | SLJIT_SET_U | SLJIT_SET_O | SLJIT_SET_C | SLJIT_KEEP_FLAGS))); \
+ case SLJIT_CMPD: \
+ SLJIT_ASSERT(!(op & (SLJIT_SET_U | SLJIT_SET_O | SLJIT_SET_C | SLJIT_KEEP_FLAGS))); \
SLJIT_ASSERT((op & (SLJIT_SET_E | SLJIT_SET_S))); \
break; \
case SLJIT_ADD: \
@@ -466,57 +561,66 @@ static SLJIT_INLINE void set_const(struct sljit_const *const_, struct sljit_comp
case SLJIT_SUBC: \
SLJIT_ASSERT(!(op & (SLJIT_SET_E | SLJIT_SET_S | SLJIT_SET_U | SLJIT_SET_O))); \
break; \
- default: \
+ case SLJIT_BREAKPOINT: \
+ case SLJIT_NOP: \
+ case SLJIT_UMUL: \
+ case SLJIT_SMUL: \
+ case SLJIT_MOV: \
+ case SLJIT_MOV_P: \
+ case SLJIT_MOVU: \
+ case SLJIT_MOVU_P: \
/* Nothing allowed */ \
SLJIT_ASSERT(!(op & (SLJIT_INT_OP | SLJIT_SET_E | SLJIT_SET_S | SLJIT_SET_U | SLJIT_SET_O | SLJIT_SET_C | SLJIT_KEEP_FLAGS))); \
break; \
+ default: \
+ /* Only SLJIT_INT_OP or SLJIT_SINGLE_OP is allowed. */ \
+ SLJIT_ASSERT(!(op & (SLJIT_SET_E | SLJIT_SET_S | SLJIT_SET_U | SLJIT_SET_O | SLJIT_SET_C | SLJIT_KEEP_FLAGS))); \
+ break; \
}
#define FUNCTION_CHECK_IS_REG(r) \
- ((r) == SLJIT_UNUSED || (r) == SLJIT_LOCALS_REG || \
- ((r) >= SLJIT_TEMPORARY_REG1 && (r) <= SLJIT_TEMPORARY_REG3 && (r) <= SLJIT_TEMPORARY_REG1 - 1 + compiler->temporaries) || \
- ((r) >= SLJIT_SAVED_REG1 && (r) <= SLJIT_SAVED_REG3 && (r) <= SLJIT_SAVED_REG1 - 1 + compiler->saveds)) \
+ ((r) == SLJIT_UNUSED || \
+ ((r) >= SLJIT_SCRATCH_REG1 && (r) <= SLJIT_SCRATCH_REG1 - 1 + compiler->scratches) || \
+ ((r) >= SLJIT_SAVED_REG1 && (r) <= SLJIT_SAVED_REG1 - 1 + compiler->saveds))
#define FUNCTION_CHECK_SRC(p, i) \
- SLJIT_ASSERT(compiler->temporaries != -1 && compiler->saveds != -1); \
- if (((p) >= SLJIT_TEMPORARY_REG1 && (p) <= SLJIT_TEMPORARY_REG1 - 1 + compiler->temporaries) || \
- ((p) >= SLJIT_SAVED_REG1 && (p) <= SLJIT_SAVED_REG1 - 1 + compiler->saveds) || \
- (p) == SLJIT_LOCALS_REG) \
- SLJIT_ASSERT(i == 0); \
+ SLJIT_ASSERT(compiler->scratches != -1 && compiler->saveds != -1); \
+ if (FUNCTION_CHECK_IS_REG(p)) \
+ SLJIT_ASSERT((i) == 0 && (p) != SLJIT_UNUSED); \
else if ((p) == SLJIT_IMM) \
; \
+ else if ((p) == (SLJIT_MEM1(SLJIT_LOCALS_REG))) \
+ SLJIT_ASSERT((i) >= 0 && (i) < compiler->logical_local_size); \
else if ((p) & SLJIT_MEM) { \
SLJIT_ASSERT(FUNCTION_CHECK_IS_REG((p) & 0xf)); \
if ((p) & 0xf0) { \
SLJIT_ASSERT(FUNCTION_CHECK_IS_REG(((p) >> 4) & 0xf)); \
- SLJIT_ASSERT(((p) & 0xf0) != (SLJIT_LOCALS_REG << 4) && !(i & ~0x3)); \
- } else \
- SLJIT_ASSERT((((p) >> 4) & 0xf) == 0); \
+ SLJIT_ASSERT(!((i) & ~0x3)); \
+ } \
SLJIT_ASSERT(((p) >> 9) == 0); \
} \
else \
SLJIT_ASSERT_STOP();
#define FUNCTION_CHECK_DST(p, i) \
- SLJIT_ASSERT(compiler->temporaries != -1 && compiler->saveds != -1); \
- if (((p) >= SLJIT_TEMPORARY_REG1 && (p) <= SLJIT_TEMPORARY_REG1 - 1 + compiler->temporaries) || \
- ((p) >= SLJIT_SAVED_REG1 && (p) <= SLJIT_SAVED_REG1 - 1 + compiler->saveds) || \
- (p) == SLJIT_UNUSED) \
- SLJIT_ASSERT(i == 0); \
+ SLJIT_ASSERT(compiler->scratches != -1 && compiler->saveds != -1); \
+ if (FUNCTION_CHECK_IS_REG(p)) \
+ SLJIT_ASSERT((i) == 0); \
+ else if ((p) == (SLJIT_MEM1(SLJIT_LOCALS_REG))) \
+ SLJIT_ASSERT((i) >= 0 && (i) < compiler->logical_local_size); \
else if ((p) & SLJIT_MEM) { \
SLJIT_ASSERT(FUNCTION_CHECK_IS_REG((p) & 0xf)); \
if ((p) & 0xf0) { \
SLJIT_ASSERT(FUNCTION_CHECK_IS_REG(((p) >> 4) & 0xf)); \
- SLJIT_ASSERT(((p) & 0xf0) != (SLJIT_LOCALS_REG << 4) && !(i & ~0x3)); \
- } else \
- SLJIT_ASSERT((((p) >> 4) & 0xf) == 0); \
+ SLJIT_ASSERT(!((i) & ~0x3)); \
+ } \
SLJIT_ASSERT(((p) >> 9) == 0); \
} \
else \
SLJIT_ASSERT_STOP();
#define FUNCTION_FCHECK(p, i) \
- if ((p) >= SLJIT_FLOAT_REG1 && (p) <= SLJIT_FLOAT_REG4) \
+ if ((p) >= SLJIT_FLOAT_REG1 && (p) <= SLJIT_FLOAT_REG6) \
SLJIT_ASSERT(i == 0); \
else if ((p) & SLJIT_MEM) { \
SLJIT_ASSERT(FUNCTION_CHECK_IS_REG((p) & 0xf)); \
@@ -531,10 +635,7 @@ static SLJIT_INLINE void set_const(struct sljit_const *const_, struct sljit_comp
SLJIT_ASSERT_STOP();
#define FUNCTION_CHECK_OP1() \
- if (GET_OPCODE(op) >= SLJIT_MOV && GET_OPCODE(op) <= SLJIT_MOVU_SI) { \
- SLJIT_ASSERT(!GET_ALL_FLAGS(op)); \
- } \
- if (GET_OPCODE(op) >= SLJIT_MOVU && GET_OPCODE(op) <= SLJIT_MOVU_SI) { \
+ if (GET_OPCODE(op) >= SLJIT_MOVU && GET_OPCODE(op) <= SLJIT_MOVU_P) { \
SLJIT_ASSERT(!(src & SLJIT_MEM) || (src & 0xf) != SLJIT_LOCALS_REG); \
SLJIT_ASSERT(!(dst & SLJIT_MEM) || (dst & 0xf) != SLJIT_LOCALS_REG); \
if ((src & SLJIT_MEM) && (src & 0xf)) \
@@ -557,29 +658,30 @@ static char* reg_names[] = {
};
static char* freg_names[] = {
- (char*)"<noreg>", (char*)"float_r1", (char*)"float_r2", (char*)"float_r3", (char*)"float_r4"
+ (char*)"<noreg>", (char*)"float_r1", (char*)"float_r2", (char*)"float_r3",
+ (char*)"float_r4", (char*)"float_r5", (char*)"float_r6"
};
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) || (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
#ifdef _WIN64
- #define SLJIT_PRINT_D "I64"
+# define SLJIT_PRINT_D "I64"
#else
- #define SLJIT_PRINT_D "l"
+# define SLJIT_PRINT_D "l"
#endif
#else
- #define SLJIT_PRINT_D ""
+# define SLJIT_PRINT_D ""
#endif
#define sljit_verbose_param(p, i) \
if ((p) & SLJIT_IMM) \
- fprintf(compiler->verbose, "#%"SLJIT_PRINT_D"d", (i)); \
+ fprintf(compiler->verbose, "#%" SLJIT_PRINT_D "d", (i)); \
else if ((p) & SLJIT_MEM) { \
if ((p) & 0xf) { \
if (i) { \
if (((p) >> 4) & 0xf) \
fprintf(compiler->verbose, "[%s + %s * %d]", reg_names[(p) & 0xF], reg_names[((p) >> 4)& 0xF], 1 << (i)); \
else \
- fprintf(compiler->verbose, "[%s + #%"SLJIT_PRINT_D"d]", reg_names[(p) & 0xF], (i)); \
+ fprintf(compiler->verbose, "[%s + #%" SLJIT_PRINT_D "d]", reg_names[(p) & 0xF], (i)); \
} \
else { \
if (((p) >> 4) & 0xf) \
@@ -589,7 +691,7 @@ static char* freg_names[] = {
} \
} \
else \
- fprintf(compiler->verbose, "[#%"SLJIT_PRINT_D"d]", (i)); \
+ fprintf(compiler->verbose, "[#%" SLJIT_PRINT_D "d]", (i)); \
} else \
fprintf(compiler->verbose, "%s", reg_names[p]);
#define sljit_verbose_fparam(p, i) \
@@ -599,7 +701,7 @@ static char* freg_names[] = {
if (((p) >> 4) & 0xf) \
fprintf(compiler->verbose, "[%s + %s * %d]", reg_names[(p) & 0xF], reg_names[((p) >> 4)& 0xF], 1 << (i)); \
else \
- fprintf(compiler->verbose, "[%s + #%"SLJIT_PRINT_D"d]", reg_names[(p) & 0xF], (i)); \
+ fprintf(compiler->verbose, "[%s + #%" SLJIT_PRINT_D "d]", reg_names[(p) & 0xF], (i)); \
} \
else { \
if (((p) >> 4) & 0xF) \
@@ -609,7 +711,7 @@ static char* freg_names[] = {
} \
} \
else \
- fprintf(compiler->verbose, "[#%"SLJIT_PRINT_D"d]", (i)); \
+ fprintf(compiler->verbose, "[#%" SLJIT_PRINT_D "d]", (i)); \
} else \
fprintf(compiler->verbose, "%s", freg_names[p]);
@@ -619,18 +721,18 @@ static SLJIT_CONST char* op_names[] = {
(char*)"umul", (char*)"smul", (char*)"udiv", (char*)"sdiv",
/* op1 */
(char*)"mov", (char*)"mov.ub", (char*)"mov.sb", (char*)"mov.uh",
- (char*)"mov.sh", (char*)"mov.ui", (char*)"mov.si", (char*)"movu",
- (char*)"movu.ub", (char*)"movu.sb", (char*)"movu.uh", (char*)"movu.sh",
- (char*)"movu.ui", (char*)"movu.si", (char*)"not", (char*)"neg",
- (char*)"clz",
+ (char*)"mov.sh", (char*)"mov.ui", (char*)"mov.si", (char*)"mov.p",
+ (char*)"movu", (char*)"movu.ub", (char*)"movu.sb", (char*)"movu.uh",
+ (char*)"movu.sh", (char*)"movu.ui", (char*)"movu.si", (char*)"movu.p",
+ (char*)"not", (char*)"neg", (char*)"clz",
/* op2 */
(char*)"add", (char*)"addc", (char*)"sub", (char*)"subc",
(char*)"mul", (char*)"and", (char*)"or", (char*)"xor",
(char*)"shl", (char*)"lshr", (char*)"ashr",
/* fop1 */
- (char*)"fcmp", (char*)"fmov", (char*)"fneg", (char*)"fabs",
+ (char*)"cmp", (char*)"mov", (char*)"neg", (char*)"abs",
/* fop2 */
- (char*)"fadd", (char*)"fsub", (char*)"fmul", (char*)"fdiv"
+ (char*)"add", (char*)"sub", (char*)"mul", (char*)"div"
};
static char* jump_names[] = {
@@ -644,7 +746,7 @@ static char* jump_names[] = {
(char*)"c_float_equal", (char*)"c_float_not_equal",
(char*)"c_float_less", (char*)"c_float_greater_equal",
(char*)"c_float_greater", (char*)"c_float_less_equal",
- (char*)"c_float_nan", (char*)"c_float_not_nan",
+ (char*)"c_float_unordered", (char*)"c_float_ordered",
(char*)"jump", (char*)"fast_call",
(char*)"call0", (char*)"call1", (char*)"call2", (char*)"call3"
};
@@ -674,47 +776,54 @@ static SLJIT_INLINE void check_sljit_generate_code(struct sljit_compiler *compil
#endif
}
-static SLJIT_INLINE void check_sljit_emit_enter(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+static SLJIT_INLINE void check_sljit_emit_enter(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(args);
- SLJIT_UNUSED_ARG(temporaries);
+ SLJIT_UNUSED_ARG(scratches);
SLJIT_UNUSED_ARG(saveds);
SLJIT_UNUSED_ARG(local_size);
SLJIT_ASSERT(args >= 0 && args <= 3);
- SLJIT_ASSERT(temporaries >= 0 && temporaries <= SLJIT_NO_TMP_REGISTERS);
+ SLJIT_ASSERT(scratches >= 0 && scratches <= SLJIT_NO_TMP_REGISTERS);
SLJIT_ASSERT(saveds >= 0 && saveds <= SLJIT_NO_GEN_REGISTERS);
SLJIT_ASSERT(args <= saveds);
SLJIT_ASSERT(local_size >= 0 && local_size <= SLJIT_MAX_LOCAL_SIZE);
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
if (SLJIT_UNLIKELY(!!compiler->verbose))
- fprintf(compiler->verbose, " enter args=%d temporaries=%d saveds=%d local_size=%d\n", args, temporaries, saveds, local_size);
+ fprintf(compiler->verbose, " enter args=%d scratches=%d saveds=%d local_size=%d\n", args, scratches, saveds, local_size);
#endif
}
-static SLJIT_INLINE void check_sljit_set_context(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+static SLJIT_INLINE void check_sljit_set_context(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(args);
- SLJIT_UNUSED_ARG(temporaries);
+ SLJIT_UNUSED_ARG(scratches);
SLJIT_UNUSED_ARG(saveds);
SLJIT_UNUSED_ARG(local_size);
+#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ if (SLJIT_UNLIKELY(compiler->skip_checks)) {
+ compiler->skip_checks = 0;
+ return;
+ }
+#endif
+
SLJIT_ASSERT(args >= 0 && args <= 3);
- SLJIT_ASSERT(temporaries >= 0 && temporaries <= SLJIT_NO_TMP_REGISTERS);
+ SLJIT_ASSERT(scratches >= 0 && scratches <= SLJIT_NO_TMP_REGISTERS);
SLJIT_ASSERT(saveds >= 0 && saveds <= SLJIT_NO_GEN_REGISTERS);
SLJIT_ASSERT(args <= saveds);
SLJIT_ASSERT(local_size >= 0 && local_size <= SLJIT_MAX_LOCAL_SIZE);
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
if (SLJIT_UNLIKELY(!!compiler->verbose))
- fprintf(compiler->verbose, " fake_enter args=%d temporaries=%d saveds=%d local_size=%d\n", args, temporaries, saveds, local_size);
+ fprintf(compiler->verbose, " set_context args=%d scratches=%d saveds=%d local_size=%d\n", args, scratches, saveds, local_size);
#endif
}
-static SLJIT_INLINE void check_sljit_emit_return(struct sljit_compiler *compiler, int op, int src, sljit_w srcw)
+static SLJIT_INLINE void check_sljit_emit_return(struct sljit_compiler *compiler, sljit_si op, sljit_si src, sljit_sw srcw)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
@@ -724,7 +833,7 @@ static SLJIT_INLINE void check_sljit_emit_return(struct sljit_compiler *compiler
#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
if (op != SLJIT_UNUSED) {
- SLJIT_ASSERT(op >= SLJIT_MOV && op <= SLJIT_MOV_SI);
+ SLJIT_ASSERT(op >= SLJIT_MOV && op <= SLJIT_MOV_P);
FUNCTION_CHECK_SRC(src, srcw);
}
else
@@ -743,39 +852,26 @@ static SLJIT_INLINE void check_sljit_emit_return(struct sljit_compiler *compiler
#endif
}
-static SLJIT_INLINE void check_sljit_emit_fast_enter(struct sljit_compiler *compiler, int dst, sljit_w dstw, int args, int temporaries, int saveds, int local_size)
+static SLJIT_INLINE void check_sljit_emit_fast_enter(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(dst);
SLJIT_UNUSED_ARG(dstw);
- SLJIT_UNUSED_ARG(args);
- SLJIT_UNUSED_ARG(temporaries);
- SLJIT_UNUSED_ARG(saveds);
- SLJIT_UNUSED_ARG(local_size);
- SLJIT_ASSERT(args >= 0 && args <= 3);
- SLJIT_ASSERT(temporaries >= 0 && temporaries <= SLJIT_NO_TMP_REGISTERS);
- SLJIT_ASSERT(saveds >= 0 && saveds <= SLJIT_NO_GEN_REGISTERS);
- SLJIT_ASSERT(args <= saveds);
- SLJIT_ASSERT(local_size >= 0 && local_size <= SLJIT_MAX_LOCAL_SIZE);
#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
- compiler->temporaries = temporaries;
- compiler->saveds = saveds;
FUNCTION_CHECK_DST(dst, dstw);
- compiler->temporaries = -1;
- compiler->saveds = -1;
#endif
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
if (SLJIT_UNLIKELY(!!compiler->verbose)) {
fprintf(compiler->verbose, " fast_enter ");
sljit_verbose_param(dst, dstw);
- fprintf(compiler->verbose, " args=%d temporaries=%d saveds=%d local_size=%d\n", args, temporaries, saveds, local_size);
+ fprintf(compiler->verbose, "\n");
}
#endif
}
-static SLJIT_INLINE void check_sljit_emit_fast_return(struct sljit_compiler *compiler, int src, sljit_w srcw)
+static SLJIT_INLINE void check_sljit_emit_fast_return(struct sljit_compiler *compiler, sljit_si src, sljit_sw srcw)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
@@ -794,7 +890,7 @@ static SLJIT_INLINE void check_sljit_emit_fast_return(struct sljit_compiler *com
#endif
}
-static SLJIT_INLINE void check_sljit_emit_op0(struct sljit_compiler *compiler, int op)
+static SLJIT_INLINE void check_sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
@@ -808,9 +904,9 @@ static SLJIT_INLINE void check_sljit_emit_op0(struct sljit_compiler *compiler, i
#endif
}
-static SLJIT_INLINE void check_sljit_emit_op1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+static SLJIT_INLINE void check_sljit_emit_op1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
@@ -837,7 +933,8 @@ static SLJIT_INLINE void check_sljit_emit_op1(struct sljit_compiler *compiler, i
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
if (SLJIT_UNLIKELY(!!compiler->verbose)) {
fprintf(compiler->verbose, " %s%s%s%s%s%s%s%s ", !(op & SLJIT_INT_OP) ? "" : "i", op_names[GET_OPCODE(op)],
- !(op & SLJIT_SET_E) ? "" : "E", !(op & SLJIT_SET_S) ? "" : "S", !(op & SLJIT_SET_U) ? "" : "U", !(op & SLJIT_SET_O) ? "" : "O", !(op & SLJIT_SET_C) ? "" : "C", !(op & SLJIT_KEEP_FLAGS) ? "" : "K");
+ !(op & SLJIT_SET_E) ? "" : ".e", !(op & SLJIT_SET_S) ? "" : ".s", !(op & SLJIT_SET_U) ? "" : ".u",
+ !(op & SLJIT_SET_O) ? "" : ".o", !(op & SLJIT_SET_C) ? "" : ".c", !(op & SLJIT_KEEP_FLAGS) ? "" : ".k");
sljit_verbose_param(dst, dstw);
fprintf(compiler->verbose, ", ");
sljit_verbose_param(src, srcw);
@@ -846,10 +943,10 @@ static SLJIT_INLINE void check_sljit_emit_op1(struct sljit_compiler *compiler, i
#endif
}
-static SLJIT_INLINE void check_sljit_emit_op2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+static SLJIT_INLINE void check_sljit_emit_op2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
@@ -878,7 +975,8 @@ static SLJIT_INLINE void check_sljit_emit_op2(struct sljit_compiler *compiler, i
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
if (SLJIT_UNLIKELY(!!compiler->verbose)) {
fprintf(compiler->verbose, " %s%s%s%s%s%s%s%s ", !(op & SLJIT_INT_OP) ? "" : "i", op_names[GET_OPCODE(op)],
- !(op & SLJIT_SET_E) ? "" : "E", !(op & SLJIT_SET_S) ? "" : "S", !(op & SLJIT_SET_U) ? "" : "U", !(op & SLJIT_SET_O) ? "" : "O", !(op & SLJIT_SET_C) ? "" : "C", !(op & SLJIT_KEEP_FLAGS) ? "" : "K");
+ !(op & SLJIT_SET_E) ? "" : ".e", !(op & SLJIT_SET_S) ? "" : ".s", !(op & SLJIT_SET_U) ? "" : ".u",
+ !(op & SLJIT_SET_O) ? "" : ".o", !(op & SLJIT_SET_C) ? "" : ".c", !(op & SLJIT_KEEP_FLAGS) ? "" : ".k");
sljit_verbose_param(dst, dstw);
fprintf(compiler->verbose, ", ");
sljit_verbose_param(src1, src1w);
@@ -889,14 +987,14 @@ static SLJIT_INLINE void check_sljit_emit_op2(struct sljit_compiler *compiler, i
#endif
}
-static SLJIT_INLINE void check_sljit_get_register_index(int reg)
+static SLJIT_INLINE void check_sljit_get_register_index(sljit_si reg)
{
SLJIT_UNUSED_ARG(reg);
SLJIT_ASSERT(reg > 0 && reg <= SLJIT_NO_REGISTERS);
}
static SLJIT_INLINE void check_sljit_emit_op_custom(struct sljit_compiler *compiler,
- void *instruction, int size)
+ void *instruction, sljit_si size)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(instruction);
@@ -904,9 +1002,9 @@ static SLJIT_INLINE void check_sljit_emit_op_custom(struct sljit_compiler *compi
SLJIT_ASSERT(instruction);
}
-static SLJIT_INLINE void check_sljit_emit_fop1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+static SLJIT_INLINE void check_sljit_emit_fop1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
@@ -924,7 +1022,7 @@ static SLJIT_INLINE void check_sljit_emit_fop1(struct sljit_compiler *compiler,
#endif
SLJIT_ASSERT(sljit_is_fpu_available());
- SLJIT_ASSERT(GET_OPCODE(op) >= SLJIT_FCMP && GET_OPCODE(op) <= SLJIT_FABS);
+ SLJIT_ASSERT(GET_OPCODE(op) >= SLJIT_CMPD && GET_OPCODE(op) <= SLJIT_ABSD);
#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
FUNCTION_CHECK_OP();
FUNCTION_FCHECK(src, srcw);
@@ -932,8 +1030,8 @@ static SLJIT_INLINE void check_sljit_emit_fop1(struct sljit_compiler *compiler,
#endif
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
if (SLJIT_UNLIKELY(!!compiler->verbose)) {
- fprintf(compiler->verbose, " %s%s%s ", op_names[GET_OPCODE(op)],
- !(op & SLJIT_SET_E) ? "" : "E", !(op & SLJIT_SET_S) ? "" : "S");
+ fprintf(compiler->verbose, " %s%s%s%s ", op_names[GET_OPCODE(op)], (op & SLJIT_SINGLE_OP) ? "s" : "d",
+ !(op & SLJIT_SET_E) ? "" : ".e", !(op & SLJIT_SET_S) ? "" : ".s");
sljit_verbose_fparam(dst, dstw);
fprintf(compiler->verbose, ", ");
sljit_verbose_fparam(src, srcw);
@@ -942,10 +1040,10 @@ static SLJIT_INLINE void check_sljit_emit_fop1(struct sljit_compiler *compiler,
#endif
}
-static SLJIT_INLINE void check_sljit_emit_fop2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+static SLJIT_INLINE void check_sljit_emit_fop2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
@@ -958,7 +1056,7 @@ static SLJIT_INLINE void check_sljit_emit_fop2(struct sljit_compiler *compiler,
SLJIT_UNUSED_ARG(src2w);
SLJIT_ASSERT(sljit_is_fpu_available());
- SLJIT_ASSERT(GET_OPCODE(op) >= SLJIT_FADD && GET_OPCODE(op) <= SLJIT_FDIV);
+ SLJIT_ASSERT(GET_OPCODE(op) >= SLJIT_ADDD && GET_OPCODE(op) <= SLJIT_DIVD);
#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
FUNCTION_CHECK_OP();
FUNCTION_FCHECK(src1, src1w);
@@ -967,7 +1065,7 @@ static SLJIT_INLINE void check_sljit_emit_fop2(struct sljit_compiler *compiler,
#endif
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
if (SLJIT_UNLIKELY(!!compiler->verbose)) {
- fprintf(compiler->verbose, " %s ", op_names[GET_OPCODE(op)]);
+ fprintf(compiler->verbose, " %s%s ", op_names[GET_OPCODE(op)], (op & SLJIT_SINGLE_OP) ? "s" : "d");
sljit_verbose_fparam(dst, dstw);
fprintf(compiler->verbose, ", ");
sljit_verbose_fparam(src1, src1w);
@@ -989,7 +1087,7 @@ static SLJIT_INLINE void check_sljit_emit_label(struct sljit_compiler *compiler)
#endif
}
-static SLJIT_INLINE void check_sljit_emit_jump(struct sljit_compiler *compiler, int type)
+static SLJIT_INLINE void check_sljit_emit_jump(struct sljit_compiler *compiler, sljit_si type)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
@@ -1006,13 +1104,13 @@ static SLJIT_INLINE void check_sljit_emit_jump(struct sljit_compiler *compiler,
SLJIT_ASSERT((type & 0xff) >= SLJIT_C_EQUAL && (type & 0xff) <= SLJIT_CALL3);
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
if (SLJIT_UNLIKELY(!!compiler->verbose))
- fprintf(compiler->verbose, " jump%s <%s>\n", !(type & SLJIT_REWRITABLE_JUMP) ? "" : "R", jump_names[type & 0xff]);
+ fprintf(compiler->verbose, " jump%s<%s>\n", !(type & SLJIT_REWRITABLE_JUMP) ? "" : ".r", jump_names[type & 0xff]);
#endif
}
-static SLJIT_INLINE void check_sljit_emit_cmp(struct sljit_compiler *compiler, int type,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+static SLJIT_INLINE void check_sljit_emit_cmp(struct sljit_compiler *compiler, sljit_si type,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(type);
@@ -1021,7 +1119,7 @@ static SLJIT_INLINE void check_sljit_emit_cmp(struct sljit_compiler *compiler, i
SLJIT_UNUSED_ARG(src2);
SLJIT_UNUSED_ARG(src2w);
- SLJIT_ASSERT(!(type & ~(0xff | SLJIT_INT_OP | SLJIT_REWRITABLE_JUMP)));
+ SLJIT_ASSERT(!(type & ~(0xff | SLJIT_REWRITABLE_JUMP | SLJIT_INT_OP)));
SLJIT_ASSERT((type & 0xff) >= SLJIT_C_EQUAL && (type & 0xff) <= SLJIT_C_SIG_LESS_EQUAL);
#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
FUNCTION_CHECK_SRC(src1, src1w);
@@ -1029,7 +1127,7 @@ static SLJIT_INLINE void check_sljit_emit_cmp(struct sljit_compiler *compiler, i
#endif
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
if (SLJIT_UNLIKELY(!!compiler->verbose)) {
- fprintf(compiler->verbose, " %scmp%s <%s> ", !(type & SLJIT_INT_OP) ? "" : "i", !(type & SLJIT_REWRITABLE_JUMP) ? "" : "R", jump_names[type & 0xff]);
+ fprintf(compiler->verbose, " %scmp%s<%s> ", !(type & SLJIT_INT_OP) ? "" : "i", !(type & SLJIT_REWRITABLE_JUMP) ? "" : ".r", jump_names[type & 0xff]);
sljit_verbose_param(src1, src1w);
fprintf(compiler->verbose, ", ");
sljit_verbose_param(src2, src2w);
@@ -1038,9 +1136,9 @@ static SLJIT_INLINE void check_sljit_emit_cmp(struct sljit_compiler *compiler, i
#endif
}
-static SLJIT_INLINE void check_sljit_emit_fcmp(struct sljit_compiler *compiler, int type,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+static SLJIT_INLINE void check_sljit_emit_fcmp(struct sljit_compiler *compiler, sljit_si type,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(type);
@@ -1050,15 +1148,16 @@ static SLJIT_INLINE void check_sljit_emit_fcmp(struct sljit_compiler *compiler,
SLJIT_UNUSED_ARG(src2w);
SLJIT_ASSERT(sljit_is_fpu_available());
- SLJIT_ASSERT(!(type & ~(0xff | SLJIT_REWRITABLE_JUMP)));
- SLJIT_ASSERT((type & 0xff) >= SLJIT_C_FLOAT_EQUAL && (type & 0xff) <= SLJIT_C_FLOAT_NOT_NAN);
+ SLJIT_ASSERT(!(type & ~(0xff | SLJIT_REWRITABLE_JUMP | SLJIT_SINGLE_OP)));
+ SLJIT_ASSERT((type & 0xff) >= SLJIT_C_FLOAT_EQUAL && (type & 0xff) <= SLJIT_C_FLOAT_ORDERED);
#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
FUNCTION_FCHECK(src1, src1w);
FUNCTION_FCHECK(src2, src2w);
#endif
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
if (SLJIT_UNLIKELY(!!compiler->verbose)) {
- fprintf(compiler->verbose, " fcmp%s <%s> ", !(type & SLJIT_REWRITABLE_JUMP) ? "" : "R", jump_names[type & 0xff]);
+ fprintf(compiler->verbose, " %scmp%s<%s> ", (type & SLJIT_SINGLE_OP) ? "s" : "d",
+ !(type & SLJIT_REWRITABLE_JUMP) ? "" : ".r", jump_names[type & 0xff]);
sljit_verbose_fparam(src1, src1w);
fprintf(compiler->verbose, ", ");
sljit_verbose_fparam(src2, src2w);
@@ -1067,7 +1166,7 @@ static SLJIT_INLINE void check_sljit_emit_fcmp(struct sljit_compiler *compiler,
#endif
}
-static SLJIT_INLINE void check_sljit_emit_ijump(struct sljit_compiler *compiler, int type, int src, sljit_w srcw)
+static SLJIT_INLINE void check_sljit_emit_ijump(struct sljit_compiler *compiler, sljit_si type, sljit_si src, sljit_sw srcw)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
@@ -1075,45 +1174,87 @@ static SLJIT_INLINE void check_sljit_emit_ijump(struct sljit_compiler *compiler,
SLJIT_UNUSED_ARG(src);
SLJIT_UNUSED_ARG(srcw);
+#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ if (SLJIT_UNLIKELY(compiler->skip_checks)) {
+ compiler->skip_checks = 0;
+ return;
+ }
+#endif
+
SLJIT_ASSERT(type >= SLJIT_JUMP && type <= SLJIT_CALL3);
#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
FUNCTION_CHECK_SRC(src, srcw);
#endif
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
if (SLJIT_UNLIKELY(!!compiler->verbose)) {
- fprintf(compiler->verbose, " ijump <%s> ", jump_names[type]);
+ fprintf(compiler->verbose, " ijump<%s> ", jump_names[type]);
sljit_verbose_param(src, srcw);
fprintf(compiler->verbose, "\n");
}
#endif
}
-static SLJIT_INLINE void check_sljit_emit_cond_value(struct sljit_compiler *compiler, int op, int dst, sljit_w dstw, int type)
+static SLJIT_INLINE void check_sljit_emit_op_flags(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw,
+ sljit_si type)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(op);
SLJIT_UNUSED_ARG(dst);
SLJIT_UNUSED_ARG(dstw);
+ SLJIT_UNUSED_ARG(src);
+ SLJIT_UNUSED_ARG(srcw);
SLJIT_UNUSED_ARG(type);
SLJIT_ASSERT(type >= SLJIT_C_EQUAL && type < SLJIT_JUMP);
- SLJIT_ASSERT(op == SLJIT_MOV || GET_OPCODE(op) == SLJIT_OR);
- SLJIT_ASSERT(GET_ALL_FLAGS(op) == 0 || GET_ALL_FLAGS(op) == SLJIT_SET_E || GET_ALL_FLAGS(op) == SLJIT_KEEP_FLAGS);
+ SLJIT_ASSERT(op == SLJIT_MOV || GET_OPCODE(op) == SLJIT_MOV_UI || GET_OPCODE(op) == SLJIT_MOV_SI
+ || (GET_OPCODE(op) >= SLJIT_AND && GET_OPCODE(op) <= SLJIT_XOR));
+ SLJIT_ASSERT((op & (SLJIT_SET_S | SLJIT_SET_U | SLJIT_SET_O | SLJIT_SET_C)) == 0);
+ SLJIT_ASSERT((op & (SLJIT_SET_E | SLJIT_KEEP_FLAGS)) != (SLJIT_SET_E | SLJIT_KEEP_FLAGS));
#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ if (GET_OPCODE(op) < SLJIT_ADD) {
+ SLJIT_ASSERT(src == SLJIT_UNUSED && srcw == 0);
+ } else {
+ SLJIT_ASSERT(src == dst && srcw == dstw);
+ }
FUNCTION_CHECK_DST(dst, dstw);
#endif
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
if (SLJIT_UNLIKELY(!!compiler->verbose)) {
- fprintf(compiler->verbose, " cond_set%s%s <%s> ", !(op & SLJIT_SET_E) ? "" : "E",
- !(op & SLJIT_KEEP_FLAGS) ? "" : "K", op_names[GET_OPCODE(op)]);
+ fprintf(compiler->verbose, " op_flags<%s%s%s%s> ", !(op & SLJIT_INT_OP) ? "" : "i",
+ op_names[GET_OPCODE(op)], !(op & SLJIT_SET_E) ? "" : ".e", !(op & SLJIT_KEEP_FLAGS) ? "" : ".k");
sljit_verbose_param(dst, dstw);
+ if (src != SLJIT_UNUSED) {
+ fprintf(compiler->verbose, ", ");
+ sljit_verbose_param(src, srcw);
+ }
fprintf(compiler->verbose, ", <%s>\n", jump_names[type]);
}
#endif
}
-static SLJIT_INLINE void check_sljit_emit_const(struct sljit_compiler *compiler, int dst, sljit_w dstw, sljit_w init_value)
+static SLJIT_INLINE void check_sljit_get_local_base(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw offset)
+{
+ SLJIT_UNUSED_ARG(compiler);
+ SLJIT_UNUSED_ARG(dst);
+ SLJIT_UNUSED_ARG(dstw);
+ SLJIT_UNUSED_ARG(offset);
+
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ FUNCTION_CHECK_DST(dst, dstw);
+#endif
+#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
+ if (SLJIT_UNLIKELY(!!compiler->verbose)) {
+ fprintf(compiler->verbose, " local_base ");
+ sljit_verbose_param(dst, dstw);
+ fprintf(compiler->verbose, ", #%" SLJIT_PRINT_D "d\n", offset);
+ }
+#endif
+}
+
+static SLJIT_INLINE void check_sljit_emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw init_value)
{
/* If debug and verbose are disabled, all arguments are unused. */
SLJIT_UNUSED_ARG(compiler);
@@ -1128,22 +1269,23 @@ static SLJIT_INLINE void check_sljit_emit_const(struct sljit_compiler *compiler,
if (SLJIT_UNLIKELY(!!compiler->verbose)) {
fprintf(compiler->verbose, " const ");
sljit_verbose_param(dst, dstw);
- fprintf(compiler->verbose, ", #%"SLJIT_PRINT_D"d\n", init_value);
+ fprintf(compiler->verbose, ", #%" SLJIT_PRINT_D "d\n", init_value);
}
#endif
}
-static SLJIT_INLINE int emit_mov_before_return(struct sljit_compiler *compiler, int op, int src, sljit_w srcw)
+static SLJIT_INLINE sljit_si emit_mov_before_return(struct sljit_compiler *compiler, sljit_si op, sljit_si src, sljit_sw srcw)
{
/* Return if don't need to do anything. */
if (op == SLJIT_UNUSED)
return SLJIT_SUCCESS;
#if (defined SLJIT_64BIT_ARCHITECTURE && SLJIT_64BIT_ARCHITECTURE)
- if (src == SLJIT_RETURN_REG && op == SLJIT_MOV)
+ /* At the moment the pointer size is always equal to sljit_sw. May be changed in the future. */
+ if (src == SLJIT_RETURN_REG && (op == SLJIT_MOV || op == SLJIT_MOV_P))
return SLJIT_SUCCESS;
#else
- if (src == SLJIT_RETURN_REG && (op == SLJIT_MOV || op == SLJIT_MOV_UI || op == SLJIT_MOV_SI))
+ if (src == SLJIT_RETURN_REG && (op == SLJIT_MOV || op == SLJIT_MOV_UI || op == SLJIT_MOV_SI || op == SLJIT_MOV_P))
return SLJIT_SUCCESS;
#endif
@@ -1180,32 +1322,34 @@ static SLJIT_INLINE int emit_mov_before_return(struct sljit_compiler *compiler,
#define SLJIT_CPUINFO SLJIT_CPUINFO_PART1 SLJIT_CPUINFO_PART2 SLJIT_CPUINFO_PART3
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- #include "sljitNativeX86_common.c"
+# include "sljitNativeX86_common.c"
#elif (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- #include "sljitNativeX86_common.c"
+# include "sljitNativeX86_common.c"
#elif (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5)
- #include "sljitNativeARM_v5.c"
+# include "sljitNativeARM_v5.c"
#elif (defined SLJIT_CONFIG_ARM_V7 && SLJIT_CONFIG_ARM_V7)
- #include "sljitNativeARM_v5.c"
+# include "sljitNativeARM_v5.c"
#elif (defined SLJIT_CONFIG_ARM_THUMB2 && SLJIT_CONFIG_ARM_THUMB2)
- #include "sljitNativeARM_Thumb2.c"
+# include "sljitNativeARM_Thumb2.c"
#elif (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32)
- #include "sljitNativePPC_common.c"
+# include "sljitNativePPC_common.c"
#elif (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
- #include "sljitNativePPC_common.c"
+# include "sljitNativePPC_common.c"
#elif (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
- #include "sljitNativeMIPS_common.c"
+# include "sljitNativeMIPS_common.c"
+#elif (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+# include "sljitNativeSPARC_common.c"
#endif
#if !(defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_cmp(struct sljit_compiler *compiler, int type,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_cmp(struct sljit_compiler *compiler, sljit_si type,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
/* Default compare for most architectures. */
- int flags, tmp_src, condition;
- sljit_w tmp_srcw;
+ sljit_si flags, tmp_src, condition;
+ sljit_sw tmp_srcw;
CHECK_ERROR_PTR();
check_sljit_emit_cmp(compiler, type, src1, src1w, src2, src2w);
@@ -1266,24 +1410,23 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_cmp(struct sljit_compiler
return sljit_emit_jump(compiler, condition | (type & SLJIT_REWRITABLE_JUMP));
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_fcmp(struct sljit_compiler *compiler, int type,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_fcmp(struct sljit_compiler *compiler, sljit_si type,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- int flags, condition;
+ sljit_si flags, condition;
check_sljit_emit_fcmp(compiler, type, src1, src1w, src2, src2w);
condition = type & 0xff;
- if (condition <= SLJIT_C_FLOAT_NOT_EQUAL)
- flags = SLJIT_SET_E;
- else
- flags = SLJIT_SET_S;
+ flags = (condition <= SLJIT_C_FLOAT_NOT_EQUAL) ? SLJIT_SET_E : SLJIT_SET_S;
+ if (type & SLJIT_SINGLE_OP)
+ flags |= SLJIT_SINGLE_OP;
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
compiler->skip_checks = 1;
#endif
- sljit_emit_fop1(compiler, SLJIT_FCMP | flags, src1, src1w, src2, src2w);
+ sljit_emit_fop1(compiler, SLJIT_CMPD | flags, src1, src1w, src2, src2w);
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
compiler->skip_checks = 1;
@@ -1293,11 +1436,29 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_fcmp(struct sljit_compile
#endif
+#if !(defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) && !(defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_local_base(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw offset)
+{
+ CHECK_ERROR();
+ check_sljit_get_local_base(compiler, dst, dstw, offset);
+
+ ADJUST_LOCAL_OFFSET(SLJIT_MEM1(SLJIT_LOCALS_REG), offset);
+#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->skip_checks = 1;
+#endif
+ if (offset != 0)
+ return sljit_emit_op2(compiler, SLJIT_ADD | SLJIT_KEEP_FLAGS, dst, dstw, SLJIT_LOCALS_REG, 0, SLJIT_IMM, offset);
+ return sljit_emit_op1(compiler, SLJIT_MOV, dst, dstw, SLJIT_LOCALS_REG, 0);
+}
+
+#endif
+
#else /* SLJIT_CONFIG_UNSUPPORTED */
/* Empty function bodies for those machines, which are not (yet) supported. */
-SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name()
+SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name(void)
{
return "unsupported";
}
@@ -1314,7 +1475,7 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_free_compiler(struct sljit_compiler *compile
SLJIT_ASSERT_STOP();
}
-SLJIT_API_FUNC_ATTRIBUTE void* sljit_alloc_memory(struct sljit_compiler *compiler, int size)
+SLJIT_API_FUNC_ATTRIBUTE void* sljit_alloc_memory(struct sljit_compiler *compiler, sljit_si size)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(size);
@@ -1344,28 +1505,28 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_free_code(void* code)
SLJIT_ASSERT_STOP();
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_enter(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(args);
- SLJIT_UNUSED_ARG(temporaries);
+ SLJIT_UNUSED_ARG(scratches);
SLJIT_UNUSED_ARG(saveds);
SLJIT_UNUSED_ARG(local_size);
SLJIT_ASSERT_STOP();
return SLJIT_ERR_UNSUPPORTED;
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(args);
- SLJIT_UNUSED_ARG(temporaries);
+ SLJIT_UNUSED_ARG(scratches);
SLJIT_UNUSED_ARG(saveds);
SLJIT_UNUSED_ARG(local_size);
SLJIT_ASSERT_STOP();
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler, int op, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_return(struct sljit_compiler *compiler, sljit_si op, sljit_si src, sljit_sw srcw)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(op);
@@ -1375,20 +1536,16 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
return SLJIT_ERR_UNSUPPORTED;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_enter(struct sljit_compiler *compiler, int dst, sljit_w dstw, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_enter(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(dst);
SLJIT_UNUSED_ARG(dstw);
- SLJIT_UNUSED_ARG(args);
- SLJIT_UNUSED_ARG(temporaries);
- SLJIT_UNUSED_ARG(saveds);
- SLJIT_UNUSED_ARG(local_size);
SLJIT_ASSERT_STOP();
return SLJIT_ERR_UNSUPPORTED;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compiler, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_return(struct sljit_compiler *compiler, sljit_si src, sljit_sw srcw)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(src);
@@ -1397,7 +1554,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compi
return SLJIT_ERR_UNSUPPORTED;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int op)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(op);
@@ -1405,9 +1562,9 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
return SLJIT_ERR_UNSUPPORTED;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(op);
@@ -1419,10 +1576,10 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int
return SLJIT_ERR_UNSUPPORTED;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(op);
@@ -1436,14 +1593,14 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int
return SLJIT_ERR_UNSUPPORTED;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_get_register_index(int reg)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg)
{
SLJIT_ASSERT_STOP();
return reg;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compiler,
- void *instruction, int size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler,
+ void *instruction, sljit_si size)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(instruction);
@@ -1452,15 +1609,15 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compile
return SLJIT_ERR_UNSUPPORTED;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fpu_available(void)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_is_fpu_available(void)
{
SLJIT_ASSERT_STOP();
return 0;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(op);
@@ -1472,10 +1629,10 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop1(struct sljit_compiler *compiler, in
return SLJIT_ERR_UNSUPPORTED;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(op);
@@ -1496,7 +1653,7 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_label* sljit_emit_label(struct sljit_compi
return NULL;
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, int type)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, sljit_si type)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(type);
@@ -1504,9 +1661,9 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compile
return NULL;
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_cmp(struct sljit_compiler *compiler, int type,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_cmp(struct sljit_compiler *compiler, sljit_si type,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(type);
@@ -1518,9 +1675,9 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_cmp(struct sljit_compiler
return NULL;
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_fcmp(struct sljit_compiler *compiler, int type,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_fcmp(struct sljit_compiler *compiler, sljit_si type,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(type);
@@ -1546,7 +1703,7 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_set_target(struct sljit_jump *jump, sljit_uw
SLJIT_ASSERT_STOP();
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, int type, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_ijump(struct sljit_compiler *compiler, sljit_si type, sljit_si src, sljit_sw srcw)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(type);
@@ -1556,18 +1713,33 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, i
return SLJIT_ERR_UNSUPPORTED;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_cond_value(struct sljit_compiler *compiler, int op, int dst, sljit_w dstw, int type)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_flags(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw,
+ sljit_si type)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(op);
SLJIT_UNUSED_ARG(dst);
SLJIT_UNUSED_ARG(dstw);
+ SLJIT_UNUSED_ARG(src);
+ SLJIT_UNUSED_ARG(srcw);
SLJIT_UNUSED_ARG(type);
SLJIT_ASSERT_STOP();
return SLJIT_ERR_UNSUPPORTED;
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, int dst, sljit_w dstw, sljit_w initval)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_local_base(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw offset)
+{
+ SLJIT_UNUSED_ARG(compiler);
+ SLJIT_UNUSED_ARG(dst);
+ SLJIT_UNUSED_ARG(dstw);
+ SLJIT_UNUSED_ARG(offset);
+ SLJIT_ASSERT_STOP();
+ return SLJIT_ERR_UNSUPPORTED;
+}
+
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw initval)
{
SLJIT_UNUSED_ARG(compiler);
SLJIT_UNUSED_ARG(dst);
@@ -1584,7 +1756,7 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_set_jump_addr(sljit_uw addr, sljit_uw new_ad
SLJIT_ASSERT_STOP();
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_w new_constant)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_sw new_constant)
{
SLJIT_UNUSED_ARG(addr);
SLJIT_UNUSED_ARG(new_constant);
diff --git a/src/3rdparty/pcre/sljit/sljitLir.h b/src/3rdparty/pcre/sljit/sljitLir.h
index 0cb1c1e589..3171d1557c 100644
--- a/src/3rdparty/pcre/sljit/sljitLir.h
+++ b/src/3rdparty/pcre/sljit/sljitLir.h
@@ -34,28 +34,39 @@
Short description
Advantages:
- - The execution can be continued from any LIR instruction
- In other words, jump into and out of the code is safe
- - Both target of (conditional) jump and call instructions
- and constants can be dynamically modified during runtime
+ - The execution can be continued from any LIR instruction. In other
+ words, it is possible to jump to any label from anywhere, even from
+ a code fragment, which is compiled later, if both compiled code
+ shares the same context. See sljit_emit_enter for more details
+ - Supports self modifying code: target of (conditional) jump and call
+ instructions and some constant values can be dynamically modified
+ during runtime
- although it is not suggested to do it frequently
- - very effective to cache an important value once
+ - can be used for inline caching: save an important value once
+ in the instruction stream
+ - since this feature limits the optimization possibilities, a
+ special flag must be passed at compile time when these
+ instructions are emitted
- A fixed stack space can be allocated for local variables
- The compiler is thread-safe
+ - The compiler is highly configurable through preprocessor macros.
+ You can disable unneeded features (multithreading in single
+ threaded applications), and you can use your own system functions
+ (including memory allocators). See sljitConfig.h
Disadvantages:
+ - No automatic register allocation, and temporary results are
+ not stored on the stack. (hence the name comes)
- Limited number of registers (only 6+4 integer registers, max 3+2
- temporary, max 3+2 saved and 4 floating point registers)
+ scratch, max 3+2 saved and 6 floating point registers)
In practice:
- This approach is very effective for interpreters
- One of the saved registers typically points to a stack interface
- - It can jump to any exception handler anytime (even for another
- function. It is safe for SLJIT.)
- - Fast paths can be modified during runtime reflecting the changes
+ - It can jump to any exception handler anytime (even if it belongs
+ to another function)
+ - Hot paths can be modified during runtime reflecting the changes
of the fastest execution path of the dynamic language
- SLJIT supports complex memory addressing modes
- - mainly position independent code
- - Optimizations (perhaps later)
- - Only for basic blocks (when no labels inserted between LIR instructions)
+ - mainly position and context independent code (except some cases)
For valgrind users:
- pass --smc-check=all argument to valgrind, since JIT is a "self-modifying code"
@@ -95,12 +106,14 @@ of sljitConfigInternal.h */
#define SLJIT_UNUSED 0
-/* Temporary (scratch) registers may not preserve their values across function calls. */
-#define SLJIT_TEMPORARY_REG1 1
-#define SLJIT_TEMPORARY_REG2 2
-#define SLJIT_TEMPORARY_REG3 3
-/* Note: Extra Registers cannot be used for memory addressing. */
-/* Note: on x86-32, these registers are emulated (using stack loads & stores). */
+/* Scratch (temporary) registers whose may not preserve their values
+ across function calls. */
+#define SLJIT_SCRATCH_REG1 1
+#define SLJIT_SCRATCH_REG2 2
+#define SLJIT_SCRATCH_REG3 3
+/* Note: extra registers cannot be used for memory addressing. */
+/* Note: on x86-32, these registers are emulated (using stack
+ loads & stores). */
#define SLJIT_TEMPORARY_EREG1 4
#define SLJIT_TEMPORARY_EREG2 5
@@ -108,14 +121,17 @@ of sljitConfigInternal.h */
#define SLJIT_SAVED_REG1 6
#define SLJIT_SAVED_REG2 7
#define SLJIT_SAVED_REG3 8
-/* Note: Extra Registers cannot be used for memory addressing. */
-/* Note: on x86-32, these registers are emulated (using stack loads & stores). */
+/* Note: extra registers cannot be used for memory addressing. */
+/* Note: on x86-32, these registers are emulated (using stack
+ loads & stores). */
#define SLJIT_SAVED_EREG1 9
#define SLJIT_SAVED_EREG2 10
-/* Read-only register (cannot be the destination of an operation). */
-/* Note: SLJIT_MEM2( ... , SLJIT_LOCALS_REG) is not supported (x86 limitation). */
-/* Note: SLJIT_LOCALS_REG is not necessary the real stack pointer. See sljit_emit_enter. */
+/* Read-only register (cannot be the destination of an operation).
+ Only SLJIT_MEM1(SLJIT_LOCALS_REG) addressing mode is allowed since
+ several ABIs has certain limitations about the stack layout. However
+ sljit_get_local_base() can be used to obtain the offset of a value
+ on the stack. */
#define SLJIT_LOCALS_REG 11
/* Number of registers. */
@@ -125,15 +141,15 @@ of sljitConfigInternal.h */
/* Return with machine word. */
-#define SLJIT_RETURN_REG SLJIT_TEMPORARY_REG1
+#define SLJIT_RETURN_REG SLJIT_SCRATCH_REG1
/* x86 prefers specific registers for special purposes. In case of shift
- by register it supports only SLJIT_TEMPORARY_REG3 for shift argument
+ by register it supports only SLJIT_SCRATCH_REG3 for shift argument
(which is the src2 argument of sljit_emit_op2). If another register is
used, sljit must exchange data between registers which cause a minor
slowdown. Other architectures has no such limitation. */
-#define SLJIT_PREF_SHIFT_REG SLJIT_TEMPORARY_REG3
+#define SLJIT_PREF_SHIFT_REG SLJIT_SCRATCH_REG3
/* --------------------------------------------------------------------- */
/* Floating point registers */
@@ -142,12 +158,15 @@ of sljitConfigInternal.h */
/* Note: SLJIT_UNUSED as destination is not valid for floating point
operations, since they cannot be used for setting flags. */
-/* Floating point operations are performed on double precision values. */
+/* Floating point operations are performed on double or
+ single precision values. */
#define SLJIT_FLOAT_REG1 1
#define SLJIT_FLOAT_REG2 2
#define SLJIT_FLOAT_REG3 3
#define SLJIT_FLOAT_REG4 4
+#define SLJIT_FLOAT_REG5 5
+#define SLJIT_FLOAT_REG6 6
/* --------------------------------------------------------------------- */
/* Main structures and functions */
@@ -156,6 +175,7 @@ of sljitConfigInternal.h */
struct sljit_memory_fragment {
struct sljit_memory_fragment *next;
sljit_uw used_size;
+ /* Must be aligned to sljit_sw. */
sljit_ub memory[1];
};
@@ -169,7 +189,7 @@ struct sljit_label {
struct sljit_jump {
struct sljit_jump *next;
sljit_uw addr;
- sljit_w flags;
+ sljit_sw flags;
union {
sljit_uw target;
struct sljit_label* label;
@@ -182,7 +202,7 @@ struct sljit_const {
};
struct sljit_compiler {
- int error;
+ sljit_si error;
struct sljit_label *labels;
struct sljit_jump *jumps;
@@ -195,31 +215,29 @@ struct sljit_compiler {
struct sljit_memory_fragment *abuf;
/* Used local registers. */
- int temporaries;
+ sljit_si scratches;
/* Used saved registers. */
- int saveds;
+ sljit_si saveds;
/* Local stack size. */
- int local_size;
+ sljit_si local_size;
/* Code size. */
sljit_uw size;
/* For statistical purposes. */
sljit_uw executable_size;
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- int args;
- int temporaries_start;
- int saveds_start;
+ sljit_si args;
+ sljit_si locals_offset;
+ sljit_si scratches_start;
+ sljit_si saveds_start;
#endif
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- int mode32;
-#ifdef _WIN64
- int has_locals;
-#endif
+ sljit_si mode32;
#endif
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- int flags_saved;
+ sljit_si flags_saved;
#endif
#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5)
@@ -236,35 +254,44 @@ struct sljit_compiler {
#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5) || (defined SLJIT_CONFIG_ARM_V7 && SLJIT_CONFIG_ARM_V7)
/* Temporary fields. */
sljit_uw shift_imm;
- int cache_arg;
- sljit_w cache_argw;
+ sljit_si cache_arg;
+ sljit_sw cache_argw;
#endif
#if (defined SLJIT_CONFIG_ARM_THUMB2 && SLJIT_CONFIG_ARM_THUMB2)
- int cache_arg;
- sljit_w cache_argw;
+ sljit_si cache_arg;
+ sljit_sw cache_argw;
#endif
#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32) || (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
- int has_locals;
- sljit_w imm;
- int cache_arg;
- sljit_w cache_argw;
+ sljit_sw imm;
+ sljit_si cache_arg;
+ sljit_sw cache_argw;
#endif
#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
- int has_locals;
- int delay_slot;
- int cache_arg;
- sljit_w cache_argw;
+ sljit_si delay_slot;
+ sljit_si cache_arg;
+ sljit_sw cache_argw;
+#endif
+
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+ sljit_si delay_slot;
+ sljit_si cache_arg;
+ sljit_sw cache_argw;
#endif
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
FILE* verbose;
#endif
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ /* Local size passed to the functions. */
+ sljit_si logical_local_size;
+#endif
+
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
- int skip_checks;
+ sljit_si skip_checks;
#endif
};
@@ -275,22 +302,29 @@ struct sljit_compiler {
/* Creates an sljit compiler.
Returns NULL if failed. */
SLJIT_API_FUNC_ATTRIBUTE struct sljit_compiler* sljit_create_compiler(void);
-/* Free everything except the codes. */
+
+/* Free everything except the compiled machine code. */
SLJIT_API_FUNC_ATTRIBUTE void sljit_free_compiler(struct sljit_compiler *compiler);
-static SLJIT_INLINE int sljit_get_compiler_error(struct sljit_compiler *compiler) { return compiler->error; }
+/* Returns the current error code. If an error is occured, future sljit
+ calls which uses the same compiler argument returns early with the same
+ error code. Thus there is no need for checking the error after every
+ call, it is enough to do it before the code is compiled. Removing
+ these checks increases the performance of the compiling process. */
+static SLJIT_INLINE sljit_si sljit_get_compiler_error(struct sljit_compiler *compiler) { return compiler->error; }
/*
Allocate a small amount of memory. The size must be <= 64 bytes on 32 bit,
- and <= 128 bytes on 64 bit architectures. The memory area is owned by the compiler,
- and freed by sljit_free_compiler. The returned pointer is sizeof(sljit_w) aligned.
- Excellent for allocating small blocks during the compiling, and no need to worry
- about freeing them. The size is enough to contain at most 16 pointers.
- If the size is outside of the range, the function will return with NULL,
- but this return value does not indicate that there is no more memory (does
- not set the compiler to out-of-memory status).
+ and <= 128 bytes on 64 bit architectures. The memory area is owned by the
+ compiler, and freed by sljit_free_compiler. The returned pointer is
+ sizeof(sljit_sw) aligned. Excellent for allocating small blocks during
+ the compiling, and no need to worry about freeing them. The size is
+ enough to contain at most 16 pointers. If the size is outside of the range,
+ the function will return with NULL. However, this return value does not
+ indicate that there is no more memory (does not set the current error code
+ of the compiler to out-of-memory status).
*/
-SLJIT_API_FUNC_ATTRIBUTE void* sljit_alloc_memory(struct sljit_compiler *compiler, int size);
+SLJIT_API_FUNC_ATTRIBUTE void* sljit_alloc_memory(struct sljit_compiler *compiler, sljit_si size);
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE)
/* Passing NULL disables verbose. */
@@ -301,15 +335,17 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
SLJIT_API_FUNC_ATTRIBUTE void sljit_free_code(void* code);
/*
- After the code generation we can retrieve the allocated executable memory size,
- although this area may not be fully filled with instructions depending on some
- optimizations. This function is useful only for statistical purposes.
+ After the machine code generation is finished we can retrieve the allocated
+ executable memory size, although this area may not be fully filled with
+ instructions depending on some optimizations. This function is useful only
+ for statistical purposes.
Before a successful code generation, this function returns with 0.
*/
static SLJIT_INLINE sljit_uw sljit_get_generated_code_size(struct sljit_compiler *compiler) { return compiler->executable_size; }
-/* Instruction generation. Returns with error code. */
+/* Instruction generation. Returns with any error code. If there is no
+ error, they return with SLJIT_SUCCESS. */
/*
The executable code is basically a function call from the viewpoint of
@@ -320,8 +356,8 @@ static SLJIT_INLINE sljit_uw sljit_get_generated_code_size(struct sljit_compiler
for the executable code and moves function arguments to the saved
registers. The number of arguments are specified in the "args"
parameter and the first argument goes to SLJIT_SAVED_REG1, the second
- goes to SLJIT_SAVED_REG2 and so on. The number of temporary and
- saved registers are passed in "temporaries" and "saveds" arguments
+ goes to SLJIT_SAVED_REG2 and so on. The number of scratch and
+ saved registers are passed in "scratches" and "saveds" arguments
respectively. Since the saved registers contains the arguments,
"args" must be less or equal than "saveds". The sljit_emit_enter
is also capable of allocating a stack space for local variables. The
@@ -332,54 +368,53 @@ static SLJIT_INLINE sljit_uw sljit_get_generated_code_size(struct sljit_compiler
SLJIT_LOCALS_REG + local_size (exclusive) can be modified freely
until the function returns. The stack space is uninitialized.
- Note: every call of sljit_emit_enter and sljit_set_context overwrites
- the previous context. */
+ Note: every call of sljit_emit_enter and sljit_set_context
+ overwrites the previous context. */
#define SLJIT_MAX_LOCAL_SIZE 65536
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler,
- int args, int temporaries, int saveds, int local_size);
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_enter(struct sljit_compiler *compiler,
+ sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size);
/* The machine code has a context (which contains the local stack space size,
number of used registers, etc.) which initialized by sljit_emit_enter. Several
functions (like sljit_emit_return) requres this context to be able to generate
the appropriate code. However, some code fragments (like inline cache) may have
no normal entry point so their context is unknown for the compiler. Using the
- function below we can specify thir context.
+ function below we can specify their context.
Note: every call of sljit_emit_enter and sljit_set_context overwrites
the previous context. */
-/* Note: multiple calls of this function overwrites the previous call. */
-
SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler,
- int args, int temporaries, int saveds, int local_size);
+ sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size);
/* Return from machine code. The op argument can be SLJIT_UNUSED which means the
function does not return with anything or any opcode between SLJIT_MOV and
- SLJIT_MOV_SI (see sljit_emit_op1). As for src and srcw they must be 0 if op
+ SLJIT_MOV_P (see sljit_emit_op1). As for src and srcw they must be 0 if op
is SLJIT_UNUSED, otherwise see below the description about source and
destination arguments. */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler, int op,
- int src, sljit_w srcw);
-/* Really fast calling method for utility functions inside sljit (see SLJIT_FAST_CALL).
- All registers and even the stack frame is passed to the callee. The return address is
- preserved in dst/dstw by sljit_emit_fast_enter, and sljit_emit_fast_return can
- use this as a return value later. */
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_return(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si src, sljit_sw srcw);
-/* Note: only for sljit specific, non ABI compilant calls. Fast, since only a few machine instructions
- are needed. Excellent for small uility functions, where saving registers and setting up
- a new stack frame would cost too much performance. However, it is still possible to return
- to the address of the caller (or anywhere else). */
+/* Fast calling mechanism for utility functions (see SLJIT_FAST_CALL). All registers and
+ even the stack frame is passed to the callee. The return address is preserved in
+ dst/dstw by sljit_emit_fast_enter (the type of the value stored by this function
+ is sljit_p), and sljit_emit_fast_return can use this as a return value later. */
+
+/* Note: only for sljit specific, non ABI compilant calls. Fast, since only a few machine
+ instructions are needed. Excellent for small uility functions, where saving registers
+ and setting up a new stack frame would cost too much performance. However, it is still
+ possible to return to the address of the caller (or anywhere else). */
/* Note: flags are not changed (unlike sljit_emit_enter / sljit_emit_return). */
/* Note: although sljit_emit_fast_return could be replaced by an ijump, it is not suggested,
since many architectures do clever branch prediction on call / return instruction pairs. */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_enter(struct sljit_compiler *compiler, int dst, sljit_w dstw, int args, int temporaries, int saveds, int local_size);
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compiler, int src, sljit_w srcw);
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_enter(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw);
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_return(struct sljit_compiler *compiler, sljit_si src, sljit_sw srcw);
/*
Source and destination values for arithmetical instructions
@@ -388,7 +423,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compi
[imm] - absolute immediate memory address
[reg+imm] - indirect memory address
[reg+(reg<<imm)] - indirect indexed memory address (shift must be between 0 and 3)
- useful for (byte, half, int, sljit_w) array access
+ useful for (byte, half, int, sljit_sw) array access
(fully supported by both x86 and ARM architectures, and cheap operation on others)
*/
@@ -398,24 +433,40 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compi
length | alignment
---------+-----------
- byte | 1 byte (not aligned)
- half | 2 byte (real_address & 0x1 == 0)
- int | 4 byte (real_address & 0x3 == 0)
- sljit_w | 4 byte if SLJIT_32BIT_ARCHITECTURE is defined and its value is 1
+ byte | 1 byte (any physical_address is accepted)
+ half | 2 byte (physical_address & 0x1 == 0)
+ int | 4 byte (physical_address & 0x3 == 0)
+ word | 4 byte if SLJIT_32BIT_ARCHITECTURE is defined and its value is 1
| 8 byte if SLJIT_64BIT_ARCHITECTURE is defined and its value is 1
-
- Note: different architectures have different addressing limitations
- Thus sljit may generate several instructions for other addressing modes
- x86: all addressing modes supported, but write-back is not supported
- (requires an extra instruction). On x86-64 only 32 bit signed
- integers are supported by the architecture.
- arm: [reg+imm] supported for small immediates (-4095 <= imm <= 4095
- or -255 <= imm <= 255 for loading signed bytes, any halfs or doubles)
- [reg+(reg<<imm)] are supported or requires only two instructions
- Write back is limited to small immediates on thumb2
- ppc: [reg+imm], -65535 <= imm <= 65535. 64 bit moves requires immediates
- divisible by 4. [reg+reg] supported, write-back supported
- [reg+(reg<<imm)] (imm != 0) is cheap (requires two instructions)
+ pointer | size of sljit_p type (4 byte on 32 bit machines, 4 or 8 byte
+ | on 64 bit machines)
+
+ Note: Different architectures have different addressing limitations.
+ A single instruction is enough for the following addressing
+ modes. Other adrressing modes are emulated by instruction
+ sequences. This information could help to improve those code
+ generators which focuses only a few architectures.
+
+ x86: [reg+imm], -2^32+1 <= imm <= 2^32-1 (full adress space on x86-32)
+ [reg+(reg<<imm)] is supported
+ [imm], -2^32+1 <= imm <= 2^32-1 is supported
+ Write-back is not supported
+ arm: [reg+imm], -4095 <= imm <= 4095 or -255 <= imm <= 255 for signed
+ bytes, any halfs or floating point values)
+ [reg+(reg<<imm)] is supported
+ Write-back is supported
+ arm-t2: [reg+imm], -255 <= imm <= 4095
+ [reg+(reg<<imm)] is supported
+ Write back is supported only for [reg+imm], where -255 <= imm <= 255
+ ppc: [reg+imm], -65536 <= imm <= 65535. 64 bit loads/stores and 32 bit
+ signed load on 64 bit requires immediates divisible by 4.
+ [reg+imm] is not supported for signed 8 bit values.
+ [reg+reg] is supported
+ Write-back is supported except for one instruction: 32 bit signed
+ load with [reg+imm] addressing mode on 64 bit.
+ mips: [reg+imm], -65536 <= imm <= 65535
+ sparc: [reg+imm], -4096 <= imm <= 4095
+ [reg+reg] is supported
*/
/* Register output: simply the name of the register.
@@ -427,12 +478,31 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compi
#define SLJIT_IMM 0x200
/* Set 32 bit operation mode (I) on 64 bit CPUs. The flag is totally ignored on
- 32 bit CPUs. The arithmetic instruction uses only the lower 32 bit of the
- input register(s), and set the flags according to the 32 bit result. If the
- destination is a register, the higher 32 bit of the result is undefined.
- The addressing modes (SLJIT_MEM1/SLJIT_MEM2 macros) are unaffected by this flag. */
+ 32 bit CPUs. If this flag is set for an arithmetic operation, it uses only the
+ lower 32 bit of the input register(s), and set the CPU status flags according
+ to the 32 bit result. The higher 32 bits are undefined for both the input and
+ output. However, the CPU might not ignore those higher 32 bits, like MIPS, which
+ expects it to be the sign extension of the lower 32 bit. All 32 bit operations
+ are undefined, if this condition is not fulfilled. Therefore, when SLJIT_INT_OP
+ is specified, all register arguments must be the result of other operations with
+ the same SLJIT_INT_OP flag. In other words, although a register can hold either
+ a 64 or 32 bit value, these values cannot be mixed. The only exceptions are
+ SLJIT_IMOV and SLJIT_IMOVU (SLJIT_MOV_SI/SLJIT_MOV_UI/SLJIT_MOVU_SI/SLJIT_MOV_UI
+ with SLJIT_INT_OP flag) which can convert any source argument to SLJIT_INT_OP
+ compatible result. This conversion might be unnecessary on some CPUs like x86-64,
+ since the upper 32 bit is always ignored. In this case SLJIT is clever enough
+ to not generate any instructions if the source and destination operands are the
+ same registers. Affects sljit_emit_op0, sljit_emit_op1 and sljit_emit_op2. */
#define SLJIT_INT_OP 0x100
+/* Single precision mode (SP). This flag is similar to SLJIT_INT_OP, just
+ it applies to floating point registers (it is even the same bit). When
+ this flag is passed, the CPU performs single precision floating point
+ operations. Similar to SLJIT_INT_OP, all register arguments must be the
+ result of other floating point operations with this flag. Affects
+ sljit_emit_fop1, sljit_emit_fop2 and sljit_emit_fcmp. */
+#define SLJIT_SINGLE_OP 0x100
+
/* Common CPU status flags for all architectures (x86, ARM, PPC)
- carry flag
- overflow flag
@@ -474,124 +544,165 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compi
Note: may or may not cause an extra cycle wait
it can even decrease the runtime in a few cases. */
#define SLJIT_NOP 1
-/* Flags: may destroy flags
- Unsigned multiplication of SLJIT_TEMPORARY_REG1 and SLJIT_TEMPORARY_REG2.
- Result goes to SLJIT_TEMPORARY_REG2:SLJIT_TEMPORARY_REG1 (high:low) word */
+/* Flags: - (may destroy flags)
+ Unsigned multiplication of SLJIT_SCRATCH_REG1 and SLJIT_SCRATCH_REG2.
+ Result goes to SLJIT_SCRATCH_REG2:SLJIT_SCRATCH_REG1 (high:low) word */
#define SLJIT_UMUL 2
-/* Flags: may destroy flags
- Signed multiplication of SLJIT_TEMPORARY_REG1 and SLJIT_TEMPORARY_REG2.
- Result goes to SLJIT_TEMPORARY_REG2:SLJIT_TEMPORARY_REG1 (high:low) word */
+/* Flags: - (may destroy flags)
+ Signed multiplication of SLJIT_SCRATCH_REG1 and SLJIT_SCRATCH_REG2.
+ Result goes to SLJIT_SCRATCH_REG2:SLJIT_SCRATCH_REG1 (high:low) word */
#define SLJIT_SMUL 3
-/* Flags: I | may destroy flags
- Unsigned divide of the value in SLJIT_TEMPORARY_REG1 by the value in SLJIT_TEMPORARY_REG2.
- The result is placed in SLJIT_TEMPORARY_REG1 and the remainder goes to SLJIT_TEMPORARY_REG2.
- Note: if SLJIT_TEMPORARY_REG2 contains 0, the behaviour is undefined. */
+/* Flags: I - (may destroy flags)
+ Unsigned divide of the value in SLJIT_SCRATCH_REG1 by the value in SLJIT_SCRATCH_REG2.
+ The result is placed in SLJIT_SCRATCH_REG1 and the remainder goes to SLJIT_SCRATCH_REG2.
+ Note: if SLJIT_SCRATCH_REG2 contains 0, the behaviour is undefined. */
#define SLJIT_UDIV 4
-/* Flags: I | may destroy flags
- Signed divide of the value in SLJIT_TEMPORARY_REG1 by the value in SLJIT_TEMPORARY_REG2.
- The result is placed in SLJIT_TEMPORARY_REG1 and the remainder goes to SLJIT_TEMPORARY_REG2.
- Note: if SLJIT_TEMPORARY_REG2 contains 0, the behaviour is undefined. */
+#define SLJIT_IUDIV (SLJIT_UDIV | SLJIT_INT_OP)
+/* Flags: I - (may destroy flags)
+ Signed divide of the value in SLJIT_SCRATCH_REG1 by the value in SLJIT_SCRATCH_REG2.
+ The result is placed in SLJIT_SCRATCH_REG1 and the remainder goes to SLJIT_SCRATCH_REG2.
+ Note: if SLJIT_SCRATCH_REG2 contains 0, the behaviour is undefined. */
#define SLJIT_SDIV 5
+#define SLJIT_ISDIV (SLJIT_SDIV | SLJIT_INT_OP)
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int op);
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op);
/* Notes for MOV instructions:
U = Mov with update (post form). If source or destination defined as SLJIT_MEM1(r1)
or SLJIT_MEM2(r1, r2), r1 is increased by the sum of r2 and the constant argument
UB = unsigned byte (8 bit)
SB = signed byte (8 bit)
- UH = unsgined half (16 bit)
- SH = unsgined half (16 bit) */
+ UH = unsigned half (16 bit)
+ SH = signed half (16 bit)
+ UI = unsigned int (32 bit)
+ SI = signed int (32 bit)
+ P = pointer (sljit_p) size */
/* Flags: - (never set any flags) */
#define SLJIT_MOV 6
-/* Flags: - (never set any flags) */
+/* Flags: I - (never set any flags) */
#define SLJIT_MOV_UB 7
-/* Flags: - (never set any flags) */
+#define SLJIT_IMOV_UB (SLJIT_MOV_UB | SLJIT_INT_OP)
+/* Flags: I - (never set any flags) */
#define SLJIT_MOV_SB 8
-/* Flags: - (never set any flags) */
+#define SLJIT_IMOV_SB (SLJIT_MOV_SB | SLJIT_INT_OP)
+/* Flags: I - (never set any flags) */
#define SLJIT_MOV_UH 9
-/* Flags: - (never set any flags) */
+#define SLJIT_IMOV_UH (SLJIT_MOV_UH | SLJIT_INT_OP)
+/* Flags: I - (never set any flags) */
#define SLJIT_MOV_SH 10
-/* Flags: - (never set any flags) */
+#define SLJIT_IMOV_SH (SLJIT_MOV_SH | SLJIT_INT_OP)
+/* Flags: I - (never set any flags)
+ Note: see SLJIT_INT_OP for further details. */
#define SLJIT_MOV_UI 11
-/* Flags: - (never set any flags) */
+/* No SLJIT_INT_OP form, since it the same as SLJIT_IMOVU. */
+/* Flags: I - (never set any flags)
+ Note: see SLJIT_INT_OP for further details. */
#define SLJIT_MOV_SI 12
+#define SLJIT_IMOV (SLJIT_MOV_SI | SLJIT_INT_OP)
/* Flags: - (never set any flags) */
-#define SLJIT_MOVU 13
+#define SLJIT_MOV_P 13
/* Flags: - (never set any flags) */
-#define SLJIT_MOVU_UB 14
+#define SLJIT_MOVU 14
+/* Flags: I - (never set any flags) */
+#define SLJIT_MOVU_UB 15
+#define SLJIT_IMOVU_UB (SLJIT_MOVU_UB | SLJIT_INT_OP)
+/* Flags: I - (never set any flags) */
+#define SLJIT_MOVU_SB 16
+#define SLJIT_IMOVU_SB (SLJIT_MOVU_SB | SLJIT_INT_OP)
+/* Flags: I - (never set any flags) */
+#define SLJIT_MOVU_UH 17
+#define SLJIT_IMOVU_UH (SLJIT_MOVU_UH | SLJIT_INT_OP)
+/* Flags: I - (never set any flags) */
+#define SLJIT_MOVU_SH 18
+#define SLJIT_IMOVU_SH (SLJIT_MOVU_SH | SLJIT_INT_OP)
+/* Flags: I - (never set any flags)
+ Note: see SLJIT_INT_OP for further details. */
+#define SLJIT_MOVU_UI 19
+/* No SLJIT_INT_OP form, since it the same as SLJIT_IMOVU. */
+/* Flags: I - (never set any flags)
+ Note: see SLJIT_INT_OP for further details. */
+#define SLJIT_MOVU_SI 20
+#define SLJIT_IMOVU (SLJIT_MOVU_SI | SLJIT_INT_OP)
/* Flags: - (never set any flags) */
-#define SLJIT_MOVU_SB 15
-/* Flags: - (never set any flags) */
-#define SLJIT_MOVU_UH 16
-/* Flags: - (never set any flags) */
-#define SLJIT_MOVU_SH 17
-/* Flags: - (never set any flags) */
-#define SLJIT_MOVU_UI 18
-/* Flags: - (never set any flags) */
-#define SLJIT_MOVU_SI 19
+#define SLJIT_MOVU_P 21
/* Flags: I | E | K */
-#define SLJIT_NOT 20
+#define SLJIT_NOT 22
+#define SLJIT_INOT (SLJIT_NOT | SLJIT_INT_OP)
/* Flags: I | E | O | K */
-#define SLJIT_NEG 21
+#define SLJIT_NEG 23
+#define SLJIT_INEG (SLJIT_NEG | SLJIT_INT_OP)
/* Count leading zeroes
- Flags: I | E | K */
-#define SLJIT_CLZ 22
+ Flags: I | E | K
+ Important note! Sparc 32 does not support K flag, since
+ the required popc instruction is introduced only in sparc 64. */
+#define SLJIT_CLZ 24
+#define SLJIT_ICLZ (SLJIT_CLZ | SLJIT_INT_OP)
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw);
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw);
/* Flags: I | E | O | C | K */
-#define SLJIT_ADD 23
+#define SLJIT_ADD 25
+#define SLJIT_IADD (SLJIT_ADD | SLJIT_INT_OP)
/* Flags: I | C | K */
-#define SLJIT_ADDC 24
+#define SLJIT_ADDC 26
+#define SLJIT_IADDC (SLJIT_ADDC | SLJIT_INT_OP)
/* Flags: I | E | S | U | O | C | K */
-#define SLJIT_SUB 25
+#define SLJIT_SUB 27
+#define SLJIT_ISUB (SLJIT_SUB | SLJIT_INT_OP)
/* Flags: I | C | K */
-#define SLJIT_SUBC 26
+#define SLJIT_SUBC 28
+#define SLJIT_ISUBC (SLJIT_SUBC | SLJIT_INT_OP)
/* Note: integer mul
Flags: I | O (see SLJIT_C_MUL_*) | K */
-#define SLJIT_MUL 27
+#define SLJIT_MUL 29
+#define SLJIT_IMUL (SLJIT_MUL | SLJIT_INT_OP)
/* Flags: I | E | K */
-#define SLJIT_AND 28
+#define SLJIT_AND 30
+#define SLJIT_IAND (SLJIT_AND | SLJIT_INT_OP)
/* Flags: I | E | K */
-#define SLJIT_OR 29
+#define SLJIT_OR 31
+#define SLJIT_IOR (SLJIT_OR | SLJIT_INT_OP)
/* Flags: I | E | K */
-#define SLJIT_XOR 30
+#define SLJIT_XOR 32
+#define SLJIT_IXOR (SLJIT_XOR | SLJIT_INT_OP)
/* Flags: I | E | K
Let bit_length be the length of the shift operation: 32 or 64.
If src2 is immediate, src2w is masked by (bit_length - 1).
Otherwise, if the content of src2 is outside the range from 0
to bit_length - 1, the operation is undefined. */
-#define SLJIT_SHL 31
+#define SLJIT_SHL 33
+#define SLJIT_ISHL (SLJIT_SHL | SLJIT_INT_OP)
/* Flags: I | E | K
Let bit_length be the length of the shift operation: 32 or 64.
If src2 is immediate, src2w is masked by (bit_length - 1).
Otherwise, if the content of src2 is outside the range from 0
to bit_length - 1, the operation is undefined. */
-#define SLJIT_LSHR 32
+#define SLJIT_LSHR 34
+#define SLJIT_ILSHR (SLJIT_LSHR | SLJIT_INT_OP)
/* Flags: I | E | K
Let bit_length be the length of the shift operation: 32 or 64.
If src2 is immediate, src2w is masked by (bit_length - 1).
Otherwise, if the content of src2 is outside the range from 0
to bit_length - 1, the operation is undefined. */
-#define SLJIT_ASHR 33
+#define SLJIT_ASHR 35
+#define SLJIT_IASHR (SLJIT_ASHR | SLJIT_INT_OP)
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w);
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w);
/* The following function is a helper function for sljit_emit_op_custom.
- It returns with the real machine register index of any SLJIT_TEMPORARY
+ It returns with the real machine register index of any SLJIT_SCRATCH
SLJIT_SAVED or SLJIT_LOCALS register.
Note: it returns with -1 for virtual registers (all EREGs on x86-32).
Note: register returned by SLJIT_LOCALS_REG is not necessary the real
stack pointer register of the target architecture. */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_get_register_index(int reg);
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg);
/* Any instruction can be inserted into the instruction stream by
sljit_emit_op_custom. It has a similar purpose as inline assembly.
@@ -603,42 +714,50 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_get_register_index(int reg);
if size == 4, the instruction argument must be 4 byte aligned.
Otherwise: size must be 4 and instruction argument must be 4 byte aligned. */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compiler,
- void *instruction, int size);
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler,
+ void *instruction, sljit_si size);
/* Returns with non-zero if fpu is available. */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fpu_available(void);
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_is_fpu_available(void);
/* Note: dst is the left and src is the right operand for SLJIT_FCMP.
- Note: NaN check is always performed. If SLJIT_C_FLOAT_NAN is set,
+ Note: NaN check is always performed. If SLJIT_C_FLOAT_UNORDERED is set,
the comparison result is unpredictable.
- Flags: E | S (see SLJIT_C_FLOAT_*) */
-#define SLJIT_FCMP 34
-/* Flags: - (never set any flags) */
-#define SLJIT_FMOV 35
-/* Flags: - (never set any flags) */
-#define SLJIT_FNEG 36
-/* Flags: - (never set any flags) */
-#define SLJIT_FABS 37
-
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw);
-
-/* Flags: - (never set any flags) */
-#define SLJIT_FADD 38
-/* Flags: - (never set any flags) */
-#define SLJIT_FSUB 39
-/* Flags: - (never set any flags) */
-#define SLJIT_FMUL 40
-/* Flags: - (never set any flags) */
-#define SLJIT_FDIV 41
-
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w);
+ Flags: SP | E | S (see SLJIT_C_FLOAT_*) */
+#define SLJIT_CMPD 36
+#define SLJIT_CMPS (SLJIT_CMPD | SLJIT_SINGLE_OP)
+/* Flags: SP - (never set any flags) */
+#define SLJIT_MOVD 37
+#define SLJIT_MOVS (SLJIT_MOVD | SLJIT_SINGLE_OP)
+/* Flags: SP - (never set any flags) */
+#define SLJIT_NEGD 38
+#define SLJIT_NEGS (SLJIT_NEGD | SLJIT_SINGLE_OP)
+/* Flags: SP - (never set any flags) */
+#define SLJIT_ABSD 39
+#define SLJIT_ABSS (SLJIT_ABSD | SLJIT_SINGLE_OP)
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw);
+
+/* Flags: SP - (never set any flags) */
+#define SLJIT_ADDD 40
+#define SLJIT_ADDS (SLJIT_ADDD | SLJIT_SINGLE_OP)
+/* Flags: SP - (never set any flags) */
+#define SLJIT_SUBD 41
+#define SLJIT_SUBS (SLJIT_SUBD | SLJIT_SINGLE_OP)
+/* Flags: SP - (never set any flags) */
+#define SLJIT_MULD 42
+#define SLJIT_MULS (SLJIT_MULD | SLJIT_SINGLE_OP)
+/* Flags: SP - (never set any flags) */
+#define SLJIT_DIVD 43
+#define SLJIT_DIVS (SLJIT_DIVD | SLJIT_SINGLE_OP)
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w);
/* Label and jump instructions. */
@@ -671,8 +790,8 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_label* sljit_emit_label(struct sljit_compi
#define SLJIT_C_FLOAT_GREATER_EQUAL 17
#define SLJIT_C_FLOAT_GREATER 18
#define SLJIT_C_FLOAT_LESS_EQUAL 19
-#define SLJIT_C_FLOAT_NAN 20
-#define SLJIT_C_FLOAT_NOT_NAN 21
+#define SLJIT_C_FLOAT_UNORDERED 20
+#define SLJIT_C_FLOAT_ORDERED 21
#define SLJIT_JUMP 22
#define SLJIT_FAST_CALL 23
@@ -691,7 +810,7 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_label* sljit_emit_label(struct sljit_compi
type can be combined (or'ed) with SLJIT_REWRITABLE_JUMP
Flags: - (never set any flags) for both conditional and unconditional jumps.
Flags: destroy all flags for calls. */
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, int type);
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, sljit_si type);
/* Basic arithmetic comparison. In most architectures it is implemented as
an SLJIT_SUB operation (with SLJIT_UNUSED destination and setting
@@ -701,23 +820,23 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compile
type must be between SLJIT_C_EQUAL and SLJIT_C_SIG_LESS_EQUAL
type can be combined (or'ed) with SLJIT_REWRITABLE_JUMP or SLJIT_INT_OP
Flags: destroy flags. */
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_cmp(struct sljit_compiler *compiler, int type,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w);
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_cmp(struct sljit_compiler *compiler, sljit_si type,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w);
/* Basic floating point comparison. In most architectures it is implemented as
an SLJIT_FCMP operation (setting appropriate flags) followed by a
sljit_emit_jump. However some architectures (i.e: MIPS) may employ
special optimizations here. It is suggested to use this comparison form
when appropriate.
- type must be between SLJIT_C_FLOAT_EQUAL and SLJIT_C_FLOAT_NOT_NAN
- type can be combined (or'ed) with SLJIT_REWRITABLE_JUMP
+ type must be between SLJIT_C_FLOAT_EQUAL and SLJIT_C_FLOAT_ORDERED
+ type can be combined (or'ed) with SLJIT_REWRITABLE_JUMP and SLJIT_SINGLE_OP
Flags: destroy flags.
Note: if either operand is NaN, the behaviour is undefined for
type <= SLJIT_C_FLOAT_LESS_EQUAL. */
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_fcmp(struct sljit_compiler *compiler, int type,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w);
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_fcmp(struct sljit_compiler *compiler, sljit_si type,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w);
/* Set the destination of the jump to this label. */
SLJIT_API_FUNC_ATTRIBUTE void sljit_set_label(struct sljit_jump *jump, struct sljit_label* label);
@@ -731,25 +850,38 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_set_target(struct sljit_jump *jump, sljit_uw
Indirect form: any other valid addressing mode
Flags: - (never set any flags) for unconditional jumps.
Flags: destroy all flags for calls. */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, int type, int src, sljit_w srcw);
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_ijump(struct sljit_compiler *compiler, sljit_si type, sljit_si src, sljit_sw srcw);
-/* If op == SLJIT_MOV:
- Set dst to 1 if condition is fulfilled, 0 otherwise
- type must be between SLJIT_C_EQUAL and SLJIT_C_FLOAT_NOT_NAN
+/* Perform the operation using the conditional flags as the second argument.
+ Type must always be between SLJIT_C_EQUAL and SLJIT_C_FLOAT_ORDERED. The
+ value represented by the type is 1, if the condition represented by the type
+ is fulfilled, and 0 otherwise.
+
+ If op == SLJIT_MOV, SLJIT_MOV_SI, SLJIT_MOV_UI:
+ Set dst to the value represented by the type (0 or 1).
+ Src must be SLJIT_UNUSED, and srcw must be 0
Flags: - (never set any flags)
- If op == SLJIT_OR
- Dst is used as src as well, and set its lowest bit to 1 if
- the condition is fulfilled. Otherwise it does nothing.
- Flags: E | K
- Note: sljit_emit_cond_value does nothing, if dst is SLJIT_UNUSED (regardless of op). */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_cond_value(struct sljit_compiler *compiler, int op, int dst, sljit_w dstw, int type);
+ If op == SLJIT_OR, op == SLJIT_AND, op == SLJIT_XOR
+ Performs the binary operation using src as the first, and the value
+ represented by type as the second argument.
+ Important note: only dst=src and dstw=srcw is supported at the moment!
+ Flags: I | E | K
+ Note: sljit_emit_op_flags does nothing, if dst is SLJIT_UNUSED (regardless of op). */
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_flags(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw,
+ sljit_si type);
+
+/* Copies the base address of SLJIT_LOCALS_REG+offset to dst.
+ Flags: - (never set any flags) */
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_local_base(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw offset);
/* The constant can be changed runtime (see: sljit_set_const)
Flags: - (never set any flags) */
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, int dst, sljit_w dstw, sljit_w init_value);
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw init_value);
/* After the code generation the address for label, jump and const instructions
- are computed. Since these structures are freed sljit_free_compiler, the
+ are computed. Since these structures are freed by sljit_free_compiler, the
addresses must be preserved by the user program elsewere. */
static SLJIT_INLINE sljit_uw sljit_get_label_addr(struct sljit_label *label) { return label->addr; }
static SLJIT_INLINE sljit_uw sljit_get_jump_addr(struct sljit_jump *jump) { return jump->addr; }
@@ -757,22 +889,22 @@ static SLJIT_INLINE sljit_uw sljit_get_const_addr(struct sljit_const *const_) {
/* Only the address is required to rewrite the code. */
SLJIT_API_FUNC_ATTRIBUTE void sljit_set_jump_addr(sljit_uw addr, sljit_uw new_addr);
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_w new_constant);
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_sw new_constant);
/* --------------------------------------------------------------------- */
/* Miscellaneous utility functions */
/* --------------------------------------------------------------------- */
#define SLJIT_MAJOR_VERSION 0
-#define SLJIT_MINOR_VERSION 87
+#define SLJIT_MINOR_VERSION 90
-/* Get the human readable name of the platfrom.
- Can be useful for debugging on platforms like ARM, where ARM and
- Thumb2 functions can be mixed. */
+/* Get the human readable name of the platform. Can be useful on platforms
+ like ARM, where ARM and Thumb2 functions can be mixed, and
+ it is useful to know the type of the code generator. */
SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name(void);
-/* Portble helper function to get an offset of a member. */
-#define SLJIT_OFFSETOF(base, member) ((sljit_w)(&((base*)0x10)->member) - 0x10)
+/* Portable helper function to get an offset of a member. */
+#define SLJIT_OFFSETOF(base, member) ((sljit_sw)(&((base*)0x10)->member) - 0x10)
#if (defined SLJIT_UTIL_GLOBAL_LOCK && SLJIT_UTIL_GLOBAL_LOCK)
/* This global lock is useful to compile common functions. */
@@ -821,32 +953,32 @@ SLJIT_API_FUNC_ATTRIBUTE void SLJIT_CALL sljit_free_stack(struct sljit_stack* st
since the growth ratio can be added to the current limit, and sljit_stack_resize
will do all the necessary checks. The fields of the stack are not changed if
sljit_stack_resize fails. */
-SLJIT_API_FUNC_ATTRIBUTE sljit_w SLJIT_CALL sljit_stack_resize(struct sljit_stack* stack, sljit_uw new_limit);
+SLJIT_API_FUNC_ATTRIBUTE sljit_sw SLJIT_CALL sljit_stack_resize(struct sljit_stack* stack, sljit_uw new_limit);
#endif /* (defined SLJIT_UTIL_STACK && SLJIT_UTIL_STACK) */
#if !(defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL)
/* Get the entry address of a given function. */
-#define SLJIT_FUNC_OFFSET(func_name) ((sljit_w)func_name)
+#define SLJIT_FUNC_OFFSET(func_name) ((sljit_sw)func_name)
#else /* !(defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL) */
/* All JIT related code should be placed in the same context (library, binary, etc.). */
-#define SLJIT_FUNC_OFFSET(func_name) ((sljit_w)*(void**)func_name)
+#define SLJIT_FUNC_OFFSET(func_name) (*(sljit_sw*)(void*)func_name)
/* For powerpc64, the function pointers point to a context descriptor. */
struct sljit_function_context {
- sljit_w addr;
- sljit_w r2;
- sljit_w r11;
+ sljit_sw addr;
+ sljit_sw r2;
+ sljit_sw r11;
};
/* Fill the context arguments using the addr and the function.
If func_ptr is NULL, it will not be set to the address of context
If addr is NULL, the function address also comes from the func pointer. */
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_function_context(void** func_ptr, struct sljit_function_context* context, sljit_w addr, void* func);
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_function_context(void** func_ptr, struct sljit_function_context* context, sljit_sw addr, void* func);
#endif /* !(defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL) */
diff --git a/src/3rdparty/pcre/sljit/sljitNativeARM_Thumb2.c b/src/3rdparty/pcre/sljit/sljitNativeARM_Thumb2.c
index a51536b4a7..0a60dc2a67 100644
--- a/src/3rdparty/pcre/sljit/sljitNativeARM_Thumb2.c
+++ b/src/3rdparty/pcre/sljit/sljitNativeARM_Thumb2.c
@@ -24,23 +24,26 @@
* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name()
+SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name(void)
{
return "ARM-Thumb2" SLJIT_CPUINFO;
}
+/* Length of an instruction word. */
+typedef sljit_ui sljit_ins;
+
/* Last register + 1. */
#define TMP_REG1 (SLJIT_NO_REGISTERS + 1)
#define TMP_REG2 (SLJIT_NO_REGISTERS + 2)
#define TMP_REG3 (SLJIT_NO_REGISTERS + 3)
#define TMP_PC (SLJIT_NO_REGISTERS + 4)
-#define TMP_FREG1 (SLJIT_FLOAT_REG4 + 1)
-#define TMP_FREG2 (SLJIT_FLOAT_REG4 + 2)
+#define TMP_FREG1 (0)
+#define TMP_FREG2 (SLJIT_FLOAT_REG6 + 1)
/* See sljit_emit_enter and sljit_emit_op0 if you want to change them. */
static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 5] = {
- 0, 0, 1, 2, 12, 5, 6, 7, 8, 10, 11, 13, 3, 4, 14, 15
+ 0, 0, 1, 2, 12, 5, 6, 7, 8, 10, 11, 13, 3, 4, 14, 15
};
#define COPY_BITS(src, from, to, bits) \
@@ -75,8 +78,6 @@ static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 5] = {
#define IMM12(imm) \
(COPY_BITS(imm, 11, 26, 1) | COPY_BITS(imm, 8, 12, 3) | (imm & 0xff))
-typedef sljit_ui sljit_ins;
-
/* --------------------------------------------------------------------- */
/* Instrucion forms */
/* --------------------------------------------------------------------- */
@@ -165,18 +166,18 @@ typedef sljit_ui sljit_ins;
#define UXTB_W 0xfa5ff080
#define UXTH 0xb280
#define UXTH_W 0xfa1ff080
-#define VABS_F64 0xeeb00bc0
-#define VADD_F64 0xee300b00
-#define VCMP_F64 0xeeb40b40
-#define VDIV_F64 0xee800b00
-#define VMOV_F64 0xeeb00b40
+#define VABS_F32 0xeeb00ac0
+#define VADD_F32 0xee300a00
+#define VCMP_F32 0xeeb40a40
+#define VDIV_F32 0xee800a00
+#define VMOV_F32 0xeeb00a40
#define VMRS 0xeef1fa10
-#define VMUL_F64 0xee200b00
-#define VNEG_F64 0xeeb10b40
-#define VSTR 0xed000b00
-#define VSUB_F64 0xee300b40
+#define VMUL_F32 0xee200a00
+#define VNEG_F32 0xeeb10a40
+#define VSTR_F32 0xed000a00
+#define VSUB_F32 0xee300a40
-static int push_inst16(struct sljit_compiler *compiler, sljit_ins inst)
+static sljit_si push_inst16(struct sljit_compiler *compiler, sljit_ins inst)
{
sljit_uh *ptr;
SLJIT_ASSERT(!(inst & 0xffff0000));
@@ -188,7 +189,7 @@ static int push_inst16(struct sljit_compiler *compiler, sljit_ins inst)
return SLJIT_SUCCESS;
}
-static int push_inst32(struct sljit_compiler *compiler, sljit_ins inst)
+static sljit_si push_inst32(struct sljit_compiler *compiler, sljit_ins inst)
{
sljit_uh *ptr = (sljit_uh*)ensure_buf(compiler, sizeof(sljit_ins));
FAIL_IF(!ptr);
@@ -198,7 +199,7 @@ static int push_inst32(struct sljit_compiler *compiler, sljit_ins inst)
return SLJIT_SUCCESS;
}
-static SLJIT_INLINE int emit_imm32_const(struct sljit_compiler *compiler, int dst, sljit_uw imm)
+static SLJIT_INLINE sljit_si emit_imm32_const(struct sljit_compiler *compiler, sljit_si dst, sljit_uw imm)
{
FAIL_IF(push_inst32(compiler, MOVW | RD4(dst) |
COPY_BITS(imm, 12, 16, 4) | COPY_BITS(imm, 11, 26, 1) | COPY_BITS(imm, 8, 12, 3) | (imm & 0xff)));
@@ -208,7 +209,7 @@ static SLJIT_INLINE int emit_imm32_const(struct sljit_compiler *compiler, int ds
static SLJIT_INLINE void modify_imm32_const(sljit_uh* inst, sljit_uw new_imm)
{
- int dst = inst[1] & 0x0f00;
+ sljit_si dst = inst[1] & 0x0f00;
SLJIT_ASSERT(((inst[0] & 0xfbf0) == (MOVW >> 16)) && ((inst[2] & 0xfbf0) == (MOVT >> 16)) && dst == (inst[3] & 0x0f00));
inst[0] = (MOVW >> 16) | COPY_BITS(new_imm, 12, 0, 4) | COPY_BITS(new_imm, 11, 10, 1);
inst[1] = dst | COPY_BITS(new_imm, 8, 12, 3) | (new_imm & 0xff);
@@ -216,9 +217,9 @@ static SLJIT_INLINE void modify_imm32_const(sljit_uh* inst, sljit_uw new_imm)
inst[3] = dst | COPY_BITS(new_imm, 8 + 16, 12, 3) | ((new_imm & 0xff0000) >> 16);
}
-static SLJIT_INLINE int detect_jump_type(struct sljit_jump *jump, sljit_uh *code_ptr, sljit_uh *code)
+static SLJIT_INLINE sljit_si detect_jump_type(struct sljit_jump *jump, sljit_uh *code_ptr, sljit_uh *code)
{
- sljit_w diff;
+ sljit_sw diff;
if (jump->flags & SLJIT_REWRITABLE_JUMP)
return 0;
@@ -227,14 +228,14 @@ static SLJIT_INLINE int detect_jump_type(struct sljit_jump *jump, sljit_uh *code
/* Branch to ARM code is not optimized yet. */
if (!(jump->u.target & 0x1))
return 0;
- diff = ((sljit_w)jump->u.target - (sljit_w)(code_ptr + 2)) >> 1;
+ diff = ((sljit_sw)jump->u.target - (sljit_sw)(code_ptr + 2)) >> 1;
}
else {
SLJIT_ASSERT(jump->flags & JUMP_LABEL);
- diff = ((sljit_w)(code + jump->u.label->size) - (sljit_w)(code_ptr + 2)) >> 1;
+ diff = ((sljit_sw)(code + jump->u.label->size) - (sljit_sw)(code_ptr + 2)) >> 1;
}
- if (jump->flags & IS_CONDITIONAL) {
+ if (jump->flags & IS_COND) {
SLJIT_ASSERT(!(jump->flags & IS_BL));
if (diff <= 127 && diff >= -128) {
jump->flags |= B_TYPE1;
@@ -271,7 +272,7 @@ static SLJIT_INLINE int detect_jump_type(struct sljit_jump *jump, sljit_uh *code
return 0;
}
-static SLJIT_INLINE void inline_set_jump_addr(sljit_uw addr, sljit_uw new_addr, int flush)
+static SLJIT_INLINE void inline_set_jump_addr(sljit_uw addr, sljit_uw new_addr, sljit_si flush)
{
sljit_uh* inst = (sljit_uh*)addr;
modify_imm32_const(inst, new_addr);
@@ -282,10 +283,10 @@ static SLJIT_INLINE void inline_set_jump_addr(sljit_uw addr, sljit_uw new_addr,
static SLJIT_INLINE void set_jump_instruction(struct sljit_jump *jump)
{
- int type = (jump->flags >> 4) & 0xf;
- sljit_w diff;
+ sljit_si type = (jump->flags >> 4) & 0xf;
+ sljit_sw diff;
sljit_uh *jump_inst;
- int s, j1, j2;
+ sljit_si s, j1, j2;
if (SLJIT_UNLIKELY(type == 0)) {
inline_set_jump_addr(jump->addr, (jump->flags & JUMP_LABEL) ? jump->u.label->addr : jump->u.target, 0);
@@ -294,33 +295,33 @@ static SLJIT_INLINE void set_jump_instruction(struct sljit_jump *jump)
if (jump->flags & JUMP_ADDR) {
SLJIT_ASSERT(jump->u.target & 0x1);
- diff = ((sljit_w)jump->u.target - (sljit_w)(jump->addr + 4)) >> 1;
+ diff = ((sljit_sw)jump->u.target - (sljit_sw)(jump->addr + 4)) >> 1;
}
else
- diff = ((sljit_w)(jump->u.label->addr) - (sljit_w)(jump->addr + 4)) >> 1;
+ diff = ((sljit_sw)(jump->u.label->addr) - (sljit_sw)(jump->addr + 4)) >> 1;
jump_inst = (sljit_uh*)jump->addr;
switch (type) {
case 1:
/* Encoding T1 of 'B' instruction */
- SLJIT_ASSERT(diff <= 127 && diff >= -128 && (jump->flags & IS_CONDITIONAL));
+ SLJIT_ASSERT(diff <= 127 && diff >= -128 && (jump->flags & IS_COND));
jump_inst[0] = 0xd000 | (jump->flags & 0xf00) | (diff & 0xff);
return;
case 2:
/* Encoding T3 of 'B' instruction */
- SLJIT_ASSERT(diff <= 524287 && diff >= -524288 && (jump->flags & IS_CONDITIONAL));
+ SLJIT_ASSERT(diff <= 524287 && diff >= -524288 && (jump->flags & IS_COND));
jump_inst[0] = 0xf000 | COPY_BITS(jump->flags, 8, 6, 4) | COPY_BITS(diff, 11, 0, 6) | COPY_BITS(diff, 19, 10, 1);
jump_inst[1] = 0x8000 | COPY_BITS(diff, 17, 13, 1) | COPY_BITS(diff, 18, 11, 1) | (diff & 0x7ff);
return;
case 3:
- SLJIT_ASSERT(jump->flags & IS_CONDITIONAL);
+ SLJIT_ASSERT(jump->flags & IS_COND);
*jump_inst++ = IT | ((jump->flags >> 4) & 0xf0) | 0x8;
diff--;
type = 5;
break;
case 4:
/* Encoding T2 of 'B' instruction */
- SLJIT_ASSERT(diff <= 1023 && diff >= -1024 && !(jump->flags & IS_CONDITIONAL));
+ SLJIT_ASSERT(diff <= 1023 && diff >= -1024 && !(jump->flags & IS_COND));
jump_inst[0] = 0xe000 | (diff & 0x7ff);
return;
}
@@ -385,7 +386,7 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
label = label->next;
}
if (jump && jump->addr == half_count) {
- jump->addr = (sljit_uw)code_ptr - ((jump->flags & IS_CONDITIONAL) ? 10 : 8);
+ jump->addr = (sljit_uw)code_ptr - ((jump->flags & IS_COND) ? 10 : 8);
code_ptr -= detect_jump_type(jump, code_ptr, code);
jump = jump->next;
}
@@ -409,7 +410,7 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
SLJIT_ASSERT(!label);
SLJIT_ASSERT(!jump);
SLJIT_ASSERT(!const_);
- SLJIT_ASSERT(code_ptr - code <= (int)compiler->size);
+ SLJIT_ASSERT(code_ptr - code <= (sljit_sw)compiler->size);
jump = compiler->jumps;
while (jump) {
@@ -428,7 +429,7 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
static sljit_uw get_imm(sljit_uw imm)
{
/* Thumb immediate form. */
- int counter;
+ sljit_si counter;
if (imm <= 0xff)
return imm;
@@ -474,7 +475,7 @@ static sljit_uw get_imm(sljit_uw imm)
return ((imm >> 24) & 0x7f) | COPY_BITS(counter, 4, 26, 1) | COPY_BITS(counter, 1, 12, 3) | COPY_BITS(counter, 0, 7, 1);
}
-static int load_immediate(struct sljit_compiler *compiler, int dst, sljit_uw imm)
+static sljit_si load_immediate(struct sljit_compiler *compiler, sljit_si dst, sljit_uw imm)
{
sljit_uw tmp;
@@ -509,13 +510,13 @@ static int load_immediate(struct sljit_compiler *compiler, int dst, sljit_uw imm
#define SLOW_SRC1 0x0800000
#define SLOW_SRC2 0x1000000
-static int emit_op_imm(struct sljit_compiler *compiler, int flags, int dst, sljit_uw arg1, sljit_uw arg2)
+static sljit_si emit_op_imm(struct sljit_compiler *compiler, sljit_si flags, sljit_si dst, sljit_uw arg1, sljit_uw arg2)
{
/* dst must be register, TMP_REG1
arg1 must be register, TMP_REG1, imm
arg2 must be register, TMP_REG2, imm */
- int reg;
- sljit_uw imm;
+ sljit_si reg;
+ sljit_uw imm, negated_imm;
if (SLJIT_UNLIKELY((flags & (ARG1_IMM | ARG2_IMM)) == (ARG1_IMM | ARG2_IMM))) {
/* Both are immediates. */
@@ -542,14 +543,25 @@ static int emit_op_imm(struct sljit_compiler *compiler, int flags, int dst, slji
/* No form with immediate operand. */
break;
case SLJIT_ADD:
+ negated_imm = (sljit_uw)-(sljit_sw)imm;
if (!(flags & KEEP_FLAGS) && IS_2_LO_REGS(reg, dst)) {
if (imm <= 0x7)
return push_inst16(compiler, ADDSI3 | IMM3(imm) | RD3(dst) | RN3(reg));
- if (reg == dst && imm <= 0xff)
- return push_inst16(compiler, ADDSI8 | IMM8(imm) | RDN3(dst));
+ if (negated_imm <= 0x7)
+ return push_inst16(compiler, SUBSI3 | IMM3(negated_imm) | RD3(dst) | RN3(reg));
+ if (reg == dst) {
+ if (imm <= 0xff)
+ return push_inst16(compiler, ADDSI8 | IMM8(imm) | RDN3(dst));
+ if (negated_imm <= 0xff)
+ return push_inst16(compiler, SUBSI8 | IMM8(negated_imm) | RDN3(dst));
+ }
+ }
+ if (!(flags & SET_FLAGS)) {
+ if (imm <= 0xfff)
+ return push_inst32(compiler, ADDWI | RD4(dst) | RN4(reg) | IMM12(imm));
+ if (negated_imm <= 0xfff)
+ return push_inst32(compiler, SUBWI | RD4(dst) | RN4(reg) | IMM12(negated_imm));
}
- if (imm <= 0xfff && !(flags & SET_FLAGS))
- return push_inst32(compiler, ADDWI | RD4(dst) | RN4(reg) | IMM12(imm));
imm = get_imm(imm);
if (imm != INVALID_IMM)
return push_inst32(compiler, ADD_WI | (flags & SET_FLAGS) | RD4(dst) | RN4(reg) | imm);
@@ -561,18 +573,27 @@ static int emit_op_imm(struct sljit_compiler *compiler, int flags, int dst, slji
break;
case SLJIT_SUB:
if (flags & ARG2_IMM) {
+ negated_imm = (sljit_uw)-(sljit_sw)imm;
if (!(flags & KEEP_FLAGS) && IS_2_LO_REGS(reg, dst)) {
if (imm <= 0x7)
return push_inst16(compiler, SUBSI3 | IMM3(imm) | RD3(dst) | RN3(reg));
- if (imm <= 0xff) {
- if (reg == dst)
+ if (negated_imm <= 0x7)
+ return push_inst16(compiler, ADDSI3 | IMM3(negated_imm) | RD3(dst) | RN3(reg));
+ if (reg == dst) {
+ if (imm <= 0xff)
return push_inst16(compiler, SUBSI8 | IMM8(imm) | RDN3(dst));
- if (flags & UNUSED_RETURN)
- return push_inst16(compiler, CMPI | IMM8(imm) | RDN3(reg));
+ if (negated_imm <= 0xff)
+ return push_inst16(compiler, ADDSI8 | IMM8(negated_imm) | RDN3(dst));
}
+ if (imm <= 0xff && (flags & UNUSED_RETURN))
+ return push_inst16(compiler, CMPI | IMM8(imm) | RDN3(reg));
+ }
+ if (!(flags & SET_FLAGS)) {
+ if (imm <= 0xfff)
+ return push_inst32(compiler, SUBWI | RD4(dst) | RN4(reg) | IMM12(imm));
+ if (negated_imm <= 0xfff)
+ return push_inst32(compiler, ADDWI | RD4(dst) | RN4(reg) | IMM12(negated_imm));
}
- if (imm <= 0xfff && !(flags & SET_FLAGS))
- return push_inst32(compiler, SUBWI | RD4(dst) | RN4(reg) | IMM12(imm));
imm = get_imm(imm);
if (imm != INVALID_IMM)
return push_inst32(compiler, SUB_WI | (flags & SET_FLAGS) | RD4(dst) | RN4(reg) | imm);
@@ -681,9 +702,11 @@ static int emit_op_imm(struct sljit_compiler *compiler, int flags, int dst, slji
case SLJIT_MOV:
case SLJIT_MOV_UI:
case SLJIT_MOV_SI:
+ case SLJIT_MOV_P:
case SLJIT_MOVU:
case SLJIT_MOVU_UI:
case SLJIT_MOVU_SI:
+ case SLJIT_MOVU_P:
SLJIT_ASSERT(!(flags & SET_FLAGS) && arg1 == TMP_REG1);
return push_inst16(compiler, MOV | SET_REGS44(dst, arg2));
case SLJIT_MOV_UB:
@@ -865,7 +888,7 @@ static SLJIT_CONST sljit_uw sljit_mem32[12] = {
};
/* Helper function. Dst should be reg + value, using at most 1 instruction, flags does not set. */
-static int emit_set_delta(struct sljit_compiler *compiler, int dst, int reg, sljit_w value)
+static sljit_si emit_set_delta(struct sljit_compiler *compiler, sljit_si dst, sljit_si reg, sljit_sw value)
{
if (value >= 0) {
if (value <= 0xfff)
@@ -886,9 +909,9 @@ static int emit_set_delta(struct sljit_compiler *compiler, int dst, int reg, slj
}
/* Can perform an operation using at most 1 instruction. */
-static int getput_arg_fast(struct sljit_compiler *compiler, int flags, int reg, int arg, sljit_w argw)
+static sljit_si getput_arg_fast(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg, sljit_sw argw)
{
- int tmp;
+ sljit_si tmp;
SLJIT_ASSERT(arg & SLJIT_MEM);
@@ -971,7 +994,7 @@ static int getput_arg_fast(struct sljit_compiler *compiler, int flags, int reg,
/* see getput_arg below.
Note: can_cache is called only for binary operators. Those
operators always uses word arguments without write back. */
-static int can_cache(int arg, sljit_w argw, int next_arg, sljit_w next_argw)
+static sljit_si can_cache(sljit_si arg, sljit_sw argw, sljit_si next_arg, sljit_sw next_argw)
{
/* Simple operation except for updates. */
if ((arg & 0xf0) || !(next_arg & SLJIT_MEM))
@@ -993,10 +1016,10 @@ static int can_cache(int arg, sljit_w argw, int next_arg, sljit_w next_argw)
}
/* Emit the necessary instructions. See can_cache above. */
-static int getput_arg(struct sljit_compiler *compiler, int flags, int reg, int arg, sljit_w argw, int next_arg, sljit_w next_argw)
+static sljit_si getput_arg(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg, sljit_sw argw, sljit_si next_arg, sljit_sw next_argw)
{
- int tmp_r;
- sljit_w tmp;
+ sljit_si tmp_r;
+ sljit_sw tmp;
SLJIT_ASSERT(arg & SLJIT_MEM);
if (!(next_arg & SLJIT_MEM)) {
@@ -1092,7 +1115,7 @@ static int getput_arg(struct sljit_compiler *compiler, int flags, int reg, int a
return push_inst32(compiler, sljit_mem32[flags] | MEM_IMM12 | RT4(reg) | RN4(TMP_REG3) | 0);
}
-static SLJIT_INLINE int emit_op_mem(struct sljit_compiler *compiler, int flags, int reg, int arg, sljit_w argw)
+static SLJIT_INLINE sljit_si emit_op_mem(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg, sljit_sw argw)
{
if (getput_arg_fast(compiler, flags, reg, arg, argw))
return compiler->error;
@@ -1101,16 +1124,30 @@ static SLJIT_INLINE int emit_op_mem(struct sljit_compiler *compiler, int flags,
return getput_arg(compiler, flags, reg, arg, argw, 0, 0);
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+static SLJIT_INLINE sljit_si emit_op_mem2(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg1, sljit_sw arg1w, sljit_si arg2, sljit_sw arg2w)
{
- int size;
+ if (getput_arg_fast(compiler, flags, reg, arg1, arg1w))
+ return compiler->error;
+ return getput_arg(compiler, flags, reg, arg1, arg1w, arg2, arg2w);
+}
+
+/* --------------------------------------------------------------------- */
+/* Entry, exit */
+/* --------------------------------------------------------------------- */
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_enter(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
+{
+ sljit_si size;
sljit_ins push;
CHECK_ERROR();
- check_sljit_emit_enter(compiler, args, temporaries, saveds, local_size);
+ check_sljit_emit_enter(compiler, args, scratches, saveds, local_size);
- compiler->temporaries = temporaries;
+ compiler->scratches = scratches;
compiler->saveds = saveds;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
push = (1 << 4);
if (saveds >= 5)
@@ -1123,7 +1160,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, i
push |= 1 << 7;
if (saveds >= 1)
push |= 1 << 6;
- if (temporaries >= 5)
+ if (scratches >= 5)
push |= 1 << 5;
FAIL_IF(saveds >= 3
? push_inst32(compiler, PUSH_W | (1 << 14) | push)
@@ -1143,24 +1180,27 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, i
}
if (args >= 1)
- FAIL_IF(push_inst16(compiler, MOV | SET_REGS44(SLJIT_SAVED_REG1, SLJIT_TEMPORARY_REG1)));
+ FAIL_IF(push_inst16(compiler, MOV | SET_REGS44(SLJIT_SAVED_REG1, SLJIT_SCRATCH_REG1)));
if (args >= 2)
- FAIL_IF(push_inst16(compiler, MOV | SET_REGS44(SLJIT_SAVED_REG2, SLJIT_TEMPORARY_REG2)));
+ FAIL_IF(push_inst16(compiler, MOV | SET_REGS44(SLJIT_SAVED_REG2, SLJIT_SCRATCH_REG2)));
if (args >= 3)
- FAIL_IF(push_inst16(compiler, MOV | SET_REGS44(SLJIT_SAVED_REG3, SLJIT_TEMPORARY_REG3)));
+ FAIL_IF(push_inst16(compiler, MOV | SET_REGS44(SLJIT_SAVED_REG3, SLJIT_SCRATCH_REG3)));
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
- int size;
+ sljit_si size;
CHECK_ERROR_VOID();
- check_sljit_set_context(compiler, args, temporaries, saveds, local_size);
+ check_sljit_set_context(compiler, args, scratches, saveds, local_size);
- compiler->temporaries = temporaries;
+ compiler->scratches = scratches;
compiler->saveds = saveds;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
size = (3 + saveds) * sizeof(sljit_uw);
local_size += size;
@@ -1169,7 +1209,7 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler,
compiler->local_size = local_size;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler, int op, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_return(struct sljit_compiler *compiler, sljit_si op, sljit_si src, sljit_sw srcw)
{
sljit_ins pop;
@@ -1196,7 +1236,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
pop |= 1 << 7;
if (compiler->saveds >= 1)
pop |= 1 << 6;
- if (compiler->temporaries >= 5)
+ if (compiler->scratches >= 5)
pop |= 1 << 5;
return compiler->saveds >= 3
? push_inst32(compiler, POP_W | (1 << 15) | pop)
@@ -1212,8 +1252,8 @@ extern "C" {
#endif
#if defined(__GNUC__)
-extern unsigned int __aeabi_uidivmod(unsigned numerator, unsigned denominator);
-extern unsigned int __aeabi_idivmod(unsigned numerator, unsigned denominator);
+extern unsigned int __aeabi_uidivmod(unsigned int numerator, int unsigned denominator);
+extern int __aeabi_idivmod(int numerator, int denominator);
#else
#error "Software divmod functions are needed"
#endif
@@ -1222,7 +1262,7 @@ extern unsigned int __aeabi_idivmod(unsigned numerator, unsigned denominator);
}
#endif
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int op)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op)
{
CHECK_ERROR();
check_sljit_emit_op0(compiler, op);
@@ -1238,16 +1278,16 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
case SLJIT_UMUL:
case SLJIT_SMUL:
return push_inst32(compiler, (op == SLJIT_UMUL ? UMULL : SMULL)
- | (reg_map[SLJIT_TEMPORARY_REG2] << 8)
- | (reg_map[SLJIT_TEMPORARY_REG1] << 12)
- | (reg_map[SLJIT_TEMPORARY_REG1] << 16)
- | reg_map[SLJIT_TEMPORARY_REG2]);
+ | (reg_map[SLJIT_SCRATCH_REG2] << 8)
+ | (reg_map[SLJIT_SCRATCH_REG1] << 12)
+ | (reg_map[SLJIT_SCRATCH_REG1] << 16)
+ | reg_map[SLJIT_SCRATCH_REG2]);
case SLJIT_UDIV:
case SLJIT_SDIV:
- if (compiler->temporaries >= 4) {
+ if (compiler->scratches >= 4) {
FAIL_IF(push_inst32(compiler, 0xf84d2d04 /* str r2, [sp, #-4]! */));
FAIL_IF(push_inst32(compiler, 0xf84dcd04 /* str ip, [sp, #-4]! */));
- } else if (compiler->temporaries >= 3)
+ } else if (compiler->scratches >= 3)
FAIL_IF(push_inst32(compiler, 0xf84d2d08 /* str r2, [sp, #-8]! */));
#if defined(__GNUC__)
FAIL_IF(sljit_emit_ijump(compiler, SLJIT_FAST_CALL, SLJIT_IMM,
@@ -1255,10 +1295,10 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
#else
#error "Software divmod functions are needed"
#endif
- if (compiler->temporaries >= 4) {
+ if (compiler->scratches >= 4) {
FAIL_IF(push_inst32(compiler, 0xf85dcb04 /* ldr ip, [sp], #4 */));
return push_inst32(compiler, 0xf85d2b04 /* ldr r2, [sp], #4 */);
- } else if (compiler->temporaries >= 3)
+ } else if (compiler->scratches >= 3)
return push_inst32(compiler, 0xf85d2b08 /* ldr r2, [sp], #8 */);
return SLJIT_SUCCESS;
}
@@ -1266,72 +1306,77 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- int op_type, dst_r, flags;
+ sljit_si dst_r, flags;
+ sljit_si op_flags = GET_ALL_FLAGS(op);
CHECK_ERROR();
check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
compiler->cache_arg = 0;
compiler->cache_argw = 0;
- op_type = GET_OPCODE(op);
- dst_r = (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REG1;
+ dst_r = (dst >= SLJIT_SCRATCH_REG1 && dst <= TMP_REG3) ? dst : TMP_REG1;
- if (op_type >= SLJIT_MOV && op_type <= SLJIT_MOVU_SI) {
- switch (op_type) {
+ op = GET_OPCODE(op);
+ if (op >= SLJIT_MOV && op <= SLJIT_MOVU_P) {
+ switch (op) {
case SLJIT_MOV:
case SLJIT_MOV_UI:
case SLJIT_MOV_SI:
+ case SLJIT_MOV_P:
flags = WORD_SIZE;
break;
case SLJIT_MOV_UB:
flags = BYTE_SIZE;
if (src & SLJIT_IMM)
- srcw = (unsigned char)srcw;
+ srcw = (sljit_ub)srcw;
break;
case SLJIT_MOV_SB:
flags = BYTE_SIZE | SIGNED;
if (src & SLJIT_IMM)
- srcw = (signed char)srcw;
+ srcw = (sljit_sb)srcw;
break;
case SLJIT_MOV_UH:
flags = HALF_SIZE;
if (src & SLJIT_IMM)
- srcw = (unsigned short)srcw;
+ srcw = (sljit_uh)srcw;
break;
case SLJIT_MOV_SH:
flags = HALF_SIZE | SIGNED;
if (src & SLJIT_IMM)
- srcw = (signed short)srcw;
+ srcw = (sljit_sh)srcw;
break;
case SLJIT_MOVU:
case SLJIT_MOVU_UI:
case SLJIT_MOVU_SI:
+ case SLJIT_MOVU_P:
flags = WORD_SIZE | UPDATE;
break;
case SLJIT_MOVU_UB:
flags = BYTE_SIZE | UPDATE;
if (src & SLJIT_IMM)
- srcw = (unsigned char)srcw;
+ srcw = (sljit_ub)srcw;
break;
case SLJIT_MOVU_SB:
flags = BYTE_SIZE | SIGNED | UPDATE;
if (src & SLJIT_IMM)
- srcw = (signed char)srcw;
+ srcw = (sljit_sb)srcw;
break;
case SLJIT_MOVU_UH:
flags = HALF_SIZE | UPDATE;
if (src & SLJIT_IMM)
- srcw = (unsigned short)srcw;
+ srcw = (sljit_uh)srcw;
break;
case SLJIT_MOVU_SH:
flags = HALF_SIZE | SIGNED | UPDATE;
if (src & SLJIT_IMM)
- srcw = (signed short)srcw;
+ srcw = (sljit_sh)srcw;
break;
default:
SLJIT_ASSERT_STOP();
@@ -1348,7 +1393,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int
FAIL_IF(getput_arg(compiler, flags, dst_r, src, srcw, dst, dstw));
} else {
if (dst_r != TMP_REG1)
- return emit_op_imm(compiler, op_type, dst_r, TMP_REG1, src);
+ return emit_op_imm(compiler, op, dst_r, TMP_REG1, src);
dst_r = src;
}
@@ -1361,14 +1406,14 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int
return SLJIT_SUCCESS;
}
- if (op_type == SLJIT_NEG) {
+ if (op == SLJIT_NEG) {
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
compiler->skip_checks = 1;
#endif
- return sljit_emit_op2(compiler, GET_FLAGS(op) | SLJIT_SUB, dst, dstw, SLJIT_IMM, 0, src, srcw);
+ return sljit_emit_op2(compiler, SLJIT_SUB | op_flags, dst, dstw, SLJIT_IMM, 0, src, srcw);
}
- flags = (GET_FLAGS(op) ? SET_FLAGS : 0) | ((op & SLJIT_KEEP_FLAGS) ? KEEP_FLAGS : 0);
+ flags = (GET_FLAGS(op_flags) ? SET_FLAGS : 0) | ((op_flags & SLJIT_KEEP_FLAGS) ? KEEP_FLAGS : 0);
if (src & SLJIT_MEM) {
if (getput_arg_fast(compiler, WORD_SIZE, TMP_REG2, src, srcw))
FAIL_IF(compiler->error);
@@ -1382,7 +1427,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int
else
srcw = src;
- emit_op_imm(compiler, flags | op_type, dst_r, TMP_REG1, srcw);
+ emit_op_imm(compiler, flags | op, dst_r, TMP_REG1, srcw);
if (dst & SLJIT_MEM) {
if (getput_arg_fast(compiler, flags | STORE, dst_r, dst, dstw))
@@ -1393,20 +1438,23 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- int dst_r, flags;
+ sljit_si dst_r, flags;
CHECK_ERROR();
check_sljit_emit_op2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src1, src1w);
+ ADJUST_LOCAL_OFFSET(src2, src2w);
compiler->cache_arg = 0;
compiler->cache_argw = 0;
- dst_r = (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REG1;
+ dst_r = (dst >= SLJIT_SCRATCH_REG1 && dst <= TMP_REG3) ? dst : TMP_REG1;
flags = (GET_FLAGS(op) ? SET_FLAGS : 0) | ((op & SLJIT_KEEP_FLAGS) ? KEEP_FLAGS : 0);
if ((dst & SLJIT_MEM) && !getput_arg_fast(compiler, WORD_SIZE | STORE | ARG_TEST, TMP_REG1, dst, dstw))
@@ -1472,14 +1520,14 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_get_register_index(int reg)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg)
{
check_sljit_get_register_index(reg);
return reg_map[reg];
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compiler,
- void *instruction, int size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler,
+ void *instruction, sljit_si size)
{
CHECK_ERROR();
check_sljit_emit_op_custom(compiler, instruction, size);
@@ -1494,15 +1542,18 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compile
/* Floating point operators */
/* --------------------------------------------------------------------- */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fpu_available(void)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_is_fpu_available(void)
{
return 1;
}
-static int emit_fop_mem(struct sljit_compiler *compiler, int flags, int reg, int arg, sljit_w argw)
+#define FPU_LOAD (1 << 20)
+
+static sljit_si emit_fop_mem(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg, sljit_sw argw)
{
- sljit_w tmp;
- sljit_w inst = VSTR | ((flags & STORE) ? 0 : 0x00100000);
+ sljit_sw tmp;
+ sljit_uw imm;
+ sljit_sw inst = VSTR_F32 | (flags & (SLJIT_SINGLE_OP | FPU_LOAD));
SLJIT_ASSERT(arg & SLJIT_MEM);
@@ -1513,7 +1564,7 @@ static int emit_fop_mem(struct sljit_compiler *compiler, int flags, int reg, int
argw = 0;
}
- if (arg & 0xf) {
+ if ((arg & 0xf) && (argw & 0x3) == 0) {
if (!(argw & ~0x3fc))
return push_inst32(compiler, inst | 0x800000 | RN4(arg & 0xf) | DD4(reg) | (argw >> 2));
if (!(-argw & ~0x3fc))
@@ -1534,13 +1585,29 @@ static int emit_fop_mem(struct sljit_compiler *compiler, int flags, int reg, int
}
}
+ if (arg & 0xf) {
+ if (emit_set_delta(compiler, TMP_REG1, arg & 0xf, argw) != SLJIT_ERR_UNSUPPORTED) {
+ FAIL_IF(compiler->error);
+ return push_inst32(compiler, inst | 0x800000 | RN4(TMP_REG1) | DD4(reg));
+ }
+ imm = get_imm(argw & ~0x3fc);
+ if (imm != INVALID_IMM) {
+ FAIL_IF(push_inst32(compiler, ADD_WI | RD4(TMP_REG1) | RN4(arg & 0xf) | imm));
+ return push_inst32(compiler, inst | 0x800000 | RN4(TMP_REG1) | DD4(reg) | ((argw & 0x3fc) >> 2));
+ }
+ imm = get_imm(-argw & ~0x3fc);
+ if (imm != INVALID_IMM) {
+ argw = -argw;
+ FAIL_IF(push_inst32(compiler, SUB_WI | RD4(TMP_REG1) | RN4(arg & 0xf) | imm));
+ return push_inst32(compiler, inst | RN4(TMP_REG1) | DD4(reg) | ((argw & 0x3fc) >> 2));
+ }
+ }
+
compiler->cache_arg = arg;
compiler->cache_argw = argw;
if (SLJIT_UNLIKELY(!(arg & 0xf)))
FAIL_IF(load_immediate(compiler, TMP_REG3, argw));
- else if (emit_set_delta(compiler, TMP_REG3, arg & 0xf, argw) != SLJIT_ERR_UNSUPPORTED)
- FAIL_IF(compiler->error);
else {
FAIL_IF(load_immediate(compiler, TMP_REG3, argw));
if (arg & 0xf)
@@ -1549,138 +1616,137 @@ static int emit_fop_mem(struct sljit_compiler *compiler, int flags, int reg, int
return push_inst32(compiler, inst | 0x800000 | RN4(TMP_REG3) | DD4(reg));
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- int dst_r;
+ sljit_si dst_r;
CHECK_ERROR();
check_sljit_emit_fop1(compiler, op, dst, dstw, src, srcw);
+ SLJIT_COMPILE_ASSERT((SLJIT_SINGLE_OP == 0x100), float_transfer_bit_error);
compiler->cache_arg = 0;
compiler->cache_argw = 0;
+ op ^= SLJIT_SINGLE_OP;
- if (GET_OPCODE(op) == SLJIT_FCMP) {
+ if (GET_OPCODE(op) == SLJIT_CMPD) {
if (dst & SLJIT_MEM) {
- emit_fop_mem(compiler, 0, TMP_FREG1, dst, dstw);
+ emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP) | FPU_LOAD, TMP_FREG1, dst, dstw);
dst = TMP_FREG1;
}
if (src & SLJIT_MEM) {
- emit_fop_mem(compiler, 0, TMP_FREG2, src, srcw);
+ emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP) | FPU_LOAD, TMP_FREG2, src, srcw);
src = TMP_FREG2;
}
- FAIL_IF(push_inst32(compiler, VCMP_F64 | DD4(dst) | DM4(src)));
+ FAIL_IF(push_inst32(compiler, VCMP_F32 | (op & SLJIT_SINGLE_OP) | DD4(dst) | DM4(src)));
return push_inst32(compiler, VMRS);
}
- dst_r = (dst >= SLJIT_FLOAT_REG1 && dst <= SLJIT_FLOAT_REG4) ? dst : TMP_FREG1;
+ dst_r = (dst > SLJIT_FLOAT_REG6) ? TMP_FREG1 : dst;
if (src & SLJIT_MEM) {
- emit_fop_mem(compiler, 0, dst_r, src, srcw);
+ emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP) | FPU_LOAD, dst_r, src, srcw);
src = dst_r;
}
switch (GET_OPCODE(op)) {
- case SLJIT_FMOV:
+ case SLJIT_MOVD:
if (src != dst_r)
- FAIL_IF(push_inst32(compiler, VMOV_F64 | DD4(dst_r) | DM4(src)));
+ FAIL_IF(push_inst32(compiler, VMOV_F32 | (op & SLJIT_SINGLE_OP) | DD4(dst_r) | DM4(src)));
break;
- case SLJIT_FNEG:
- FAIL_IF(push_inst32(compiler, VNEG_F64 | DD4(dst_r) | DM4(src)));
+ case SLJIT_NEGD:
+ FAIL_IF(push_inst32(compiler, VNEG_F32 | (op & SLJIT_SINGLE_OP) | DD4(dst_r) | DM4(src)));
break;
- case SLJIT_FABS:
- FAIL_IF(push_inst32(compiler, VABS_F64 | DD4(dst_r) | DM4(src)));
+ case SLJIT_ABSD:
+ FAIL_IF(push_inst32(compiler, VABS_F32 | (op & SLJIT_SINGLE_OP) | DD4(dst_r) | DM4(src)));
break;
}
if (dst & SLJIT_MEM)
- return emit_fop_mem(compiler, STORE, TMP_FREG1, dst, dstw);
+ return emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP), TMP_FREG1, dst, dstw);
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- int dst_r;
+ sljit_si dst_r;
CHECK_ERROR();
check_sljit_emit_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
compiler->cache_arg = 0;
compiler->cache_argw = 0;
+ op ^= SLJIT_SINGLE_OP;
- dst_r = (dst >= SLJIT_FLOAT_REG1 && dst <= SLJIT_FLOAT_REG4) ? dst : TMP_FREG1;
+ dst_r = (dst > SLJIT_FLOAT_REG6) ? TMP_FREG1 : dst;
if (src1 & SLJIT_MEM) {
- emit_fop_mem(compiler, 0, TMP_FREG1, src1, src1w);
+ emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP) | FPU_LOAD, TMP_FREG1, src1, src1w);
src1 = TMP_FREG1;
}
if (src2 & SLJIT_MEM) {
- emit_fop_mem(compiler, 0, TMP_FREG2, src2, src2w);
+ emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP) | FPU_LOAD, TMP_FREG2, src2, src2w);
src2 = TMP_FREG2;
}
switch (GET_OPCODE(op)) {
- case SLJIT_FADD:
- FAIL_IF(push_inst32(compiler, VADD_F64 | DD4(dst_r) | DN4(src1) | DM4(src2)));
+ case SLJIT_ADDD:
+ FAIL_IF(push_inst32(compiler, VADD_F32 | (op & SLJIT_SINGLE_OP) | DD4(dst_r) | DN4(src1) | DM4(src2)));
break;
- case SLJIT_FSUB:
- FAIL_IF(push_inst32(compiler, VSUB_F64 | DD4(dst_r) | DN4(src1) | DM4(src2)));
+ case SLJIT_SUBD:
+ FAIL_IF(push_inst32(compiler, VSUB_F32 | (op & SLJIT_SINGLE_OP) | DD4(dst_r) | DN4(src1) | DM4(src2)));
break;
- case SLJIT_FMUL:
- FAIL_IF(push_inst32(compiler, VMUL_F64 | DD4(dst_r) | DN4(src1) | DM4(src2)));
+ case SLJIT_MULD:
+ FAIL_IF(push_inst32(compiler, VMUL_F32 | (op & SLJIT_SINGLE_OP) | DD4(dst_r) | DN4(src1) | DM4(src2)));
break;
- case SLJIT_FDIV:
- FAIL_IF(push_inst32(compiler, VDIV_F64 | DD4(dst_r) | DN4(src1) | DM4(src2)));
+ case SLJIT_DIVD:
+ FAIL_IF(push_inst32(compiler, VDIV_F32 | (op & SLJIT_SINGLE_OP) | DD4(dst_r) | DN4(src1) | DM4(src2)));
break;
}
if (dst & SLJIT_MEM)
- return emit_fop_mem(compiler, STORE, TMP_FREG1, dst, dstw);
+ return emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP), TMP_FREG1, dst, dstw);
return SLJIT_SUCCESS;
}
+#undef FPU_LOAD
+
/* --------------------------------------------------------------------- */
/* Other instructions */
/* --------------------------------------------------------------------- */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_enter(struct sljit_compiler *compiler, int dst, sljit_w dstw, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_enter(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw)
{
- int size;
-
CHECK_ERROR();
- check_sljit_emit_fast_enter(compiler, dst, dstw, args, temporaries, saveds, local_size);
+ check_sljit_emit_fast_enter(compiler, dst, dstw);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
- compiler->temporaries = temporaries;
- compiler->saveds = saveds;
-
- size = (3 + saveds) * sizeof(sljit_uw);
- local_size += size;
- local_size = (local_size + 7) & ~7;
- local_size -= size;
- compiler->local_size = local_size;
+ /* For UNUSED dst. Uncommon, but possible. */
+ if (dst == SLJIT_UNUSED)
+ return SLJIT_SUCCESS;
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS)
+ if (dst <= TMP_REG3)
return push_inst16(compiler, MOV | SET_REGS44(dst, TMP_REG3));
- else if (dst & SLJIT_MEM) {
- if (getput_arg_fast(compiler, WORD_SIZE | STORE, TMP_REG3, dst, dstw))
- return compiler->error;
- FAIL_IF(push_inst16(compiler, MOV | SET_REGS44(TMP_REG2, TMP_REG3)));
- compiler->cache_arg = 0;
- compiler->cache_argw = 0;
- return getput_arg(compiler, WORD_SIZE | STORE, TMP_REG2, dst, dstw, 0, 0);
- }
- return SLJIT_SUCCESS;
+ /* Memory. */
+ if (getput_arg_fast(compiler, WORD_SIZE | STORE, TMP_REG3, dst, dstw))
+ return compiler->error;
+ /* TMP_REG3 is used for caching. */
+ FAIL_IF(push_inst16(compiler, MOV | SET_REGS44(TMP_REG2, TMP_REG3)));
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+ return getput_arg(compiler, WORD_SIZE | STORE, TMP_REG2, dst, dstw, 0, 0);
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compiler, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_return(struct sljit_compiler *compiler, sljit_si src, sljit_sw srcw)
{
CHECK_ERROR();
check_sljit_emit_fast_return(compiler, src, srcw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
- if (src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_NO_REGISTERS)
+ if (src <= TMP_REG3)
FAIL_IF(push_inst16(compiler, MOV | SET_REGS44(TMP_REG3, src)));
else if (src & SLJIT_MEM) {
if (getput_arg_fast(compiler, WORD_SIZE, TMP_REG3, src, srcw))
@@ -1701,7 +1767,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compi
/* Conditional instructions */
/* --------------------------------------------------------------------- */
-static sljit_uw get_cc(int type)
+static sljit_uw get_cc(sljit_si type)
{
switch (type) {
case SLJIT_C_EQUAL:
@@ -1743,11 +1809,11 @@ static sljit_uw get_cc(int type)
return 0xd;
case SLJIT_C_OVERFLOW:
- case SLJIT_C_FLOAT_NAN:
+ case SLJIT_C_FLOAT_UNORDERED:
return 0x6;
case SLJIT_C_NOT_OVERFLOW:
- case SLJIT_C_FLOAT_NOT_NAN:
+ case SLJIT_C_FLOAT_ORDERED:
return 0x7;
default: /* SLJIT_JUMP */
@@ -1771,10 +1837,10 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_label* sljit_emit_label(struct sljit_compi
return label;
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, int type)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, sljit_si type)
{
struct sljit_jump *jump;
- int cc;
+ sljit_si cc;
CHECK_ERROR_PTR();
check_sljit_emit_jump(compiler, type);
@@ -1787,7 +1853,7 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compile
/* In ARM, we don't need to touch the arguments. */
PTR_FAIL_IF(emit_imm32_const(compiler, TMP_REG1, 0));
if (type < SLJIT_JUMP) {
- jump->flags |= IS_CONDITIONAL;
+ jump->flags |= IS_COND;
cc = get_cc(type);
jump->flags |= cc << 8;
PTR_FAIL_IF(push_inst16(compiler, IT | (cc << 4) | 0x8));
@@ -1804,12 +1870,13 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compile
return jump;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, int type, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_ijump(struct sljit_compiler *compiler, sljit_si type, sljit_si src, sljit_sw srcw)
{
struct sljit_jump *jump;
CHECK_ERROR();
check_sljit_emit_ijump(compiler, type, src, srcw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
/* In ARM, we don't need to touch the arguments. */
if (src & SLJIT_IMM) {
@@ -1823,7 +1890,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, i
FAIL_IF(push_inst16(compiler, (type <= SLJIT_JUMP ? BX : BLX) | RN3(TMP_REG1)));
}
else {
- if (src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_NO_REGISTERS)
+ if (src <= TMP_REG3)
return push_inst16(compiler, (type <= SLJIT_JUMP ? BX : BLX) | RN3(src));
FAIL_IF(emit_op_mem(compiler, WORD_SIZE, type <= SLJIT_JUMP ? TMP_PC : TMP_REG1, src, srcw));
@@ -1833,66 +1900,94 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, i
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_cond_value(struct sljit_compiler *compiler, int op, int dst, sljit_w dstw, int type)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_flags(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw,
+ sljit_si type)
{
- int dst_r;
+ sljit_si dst_r, flags = GET_ALL_FLAGS(op);
+ sljit_ins ins;
sljit_uw cc;
CHECK_ERROR();
- check_sljit_emit_cond_value(compiler, op, dst, dstw, type);
+ check_sljit_emit_op_flags(compiler, op, dst, dstw, src, srcw, type);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
if (dst == SLJIT_UNUSED)
return SLJIT_SUCCESS;
+ op = GET_OPCODE(op);
cc = get_cc(type);
- if (GET_OPCODE(op) == SLJIT_OR && dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) {
+ dst_r = (dst <= TMP_REG3) ? dst : TMP_REG2;
+
+ if (op < SLJIT_ADD) {
+ FAIL_IF(push_inst16(compiler, IT | (cc << 4) | (((cc & 0x1) ^ 0x1) << 3) | 0x4));
+ if (reg_map[dst_r] > 7) {
+ FAIL_IF(push_inst32(compiler, MOV_WI | RD4(dst_r) | 1));
+ FAIL_IF(push_inst32(compiler, MOV_WI | RD4(dst_r) | 0));
+ } else {
+ FAIL_IF(push_inst16(compiler, MOVSI | RDN3(dst_r) | 1));
+ FAIL_IF(push_inst16(compiler, MOVSI | RDN3(dst_r) | 0));
+ }
+ return dst_r == TMP_REG2 ? emit_op_mem(compiler, WORD_SIZE | STORE, TMP_REG2, dst, dstw) : SLJIT_SUCCESS;
+ }
+
+ ins = (op == SLJIT_AND ? ANDI : (op == SLJIT_OR ? ORRI : EORI));
+ if ((op == SLJIT_OR || op == SLJIT_XOR) && dst <= TMP_REG3 && dst == src) {
+ /* Does not change the other bits. */
FAIL_IF(push_inst16(compiler, IT | (cc << 4) | 0x8));
- FAIL_IF(push_inst32(compiler, ORRI | RN4(dst) | RD4(dst) | 0x1));
- if (op & SLJIT_SET_E) {
+ FAIL_IF(push_inst32(compiler, ins | RN4(src) | RD4(dst) | 1));
+ if (flags & SLJIT_SET_E) {
+ /* The condition must always be set, even if the ORRI/EORI is not executed above. */
if (reg_map[dst] <= 7)
- return push_inst16(compiler, ORRS | RD3(dst) | RN3(dst));
- return push_inst32(compiler, ORR_W | SET_FLAGS | RD4(TMP_REG1) | RN4(dst) | RM4(dst));
+ return push_inst16(compiler, MOVS | RD3(TMP_REG1) | RN3(dst));
+ return push_inst32(compiler, MOV_W | SET_FLAGS | RD4(TMP_REG1) | RM4(dst));
}
return SLJIT_SUCCESS;
}
- dst_r = TMP_REG2;
- if (op == SLJIT_MOV && dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS && reg_map[dst] <= 7)
- dst_r = dst;
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+ if (src & SLJIT_MEM) {
+ FAIL_IF(emit_op_mem2(compiler, WORD_SIZE, TMP_REG1, src, srcw, dst, dstw));
+ src = TMP_REG1;
+ srcw = 0;
+ } else if (src & SLJIT_IMM) {
+ FAIL_IF(load_immediate(compiler, TMP_REG1, srcw));
+ src = TMP_REG1;
+ srcw = 0;
+ }
FAIL_IF(push_inst16(compiler, IT | (cc << 4) | (((cc & 0x1) ^ 0x1) << 3) | 0x4));
- FAIL_IF(push_inst16(compiler, MOVSI | 0x1 | RDN3(dst_r)));
- FAIL_IF(push_inst16(compiler, MOVSI | 0x0 | RDN3(dst_r)));
-
- if (dst_r == TMP_REG2) {
- if (GET_OPCODE(op) == SLJIT_OR) {
-#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
- compiler->skip_checks = 1;
-#endif
- return sljit_emit_op2(compiler, op, dst, dstw, dst, dstw, TMP_REG2, 0);
- }
- if (dst & SLJIT_MEM)
- return emit_op_mem(compiler, WORD_SIZE | STORE, TMP_REG2, dst, dstw);
- else
- return push_inst16(compiler, MOV | SET_REGS44(dst, TMP_REG2));
+ FAIL_IF(push_inst32(compiler, ins | RN4(src) | RD4(dst_r) | 1));
+ FAIL_IF(push_inst32(compiler, ins | RN4(src) | RD4(dst_r) | 0));
+ if (dst_r == TMP_REG2)
+ FAIL_IF(emit_op_mem2(compiler, WORD_SIZE | STORE, TMP_REG2, dst, dstw, 0, 0));
+
+ if (flags & SLJIT_SET_E) {
+ /* The condition must always be set, even if the ORR/EORI is not executed above. */
+ if (reg_map[dst_r] <= 7)
+ return push_inst16(compiler, MOVS | RD3(TMP_REG1) | RN3(dst_r));
+ return push_inst32(compiler, MOV_W | SET_FLAGS | RD4(TMP_REG1) | RM4(dst_r));
}
-
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, int dst, sljit_w dstw, sljit_w init_value)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw init_value)
{
struct sljit_const *const_;
- int dst_r;
+ sljit_si dst_r;
CHECK_ERROR_PTR();
check_sljit_emit_const(compiler, dst, dstw, init_value);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
const_ = (struct sljit_const*)ensure_abuf(compiler, sizeof(struct sljit_const));
PTR_FAIL_IF(!const_);
set_const(const_, compiler);
- dst_r = (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REG1;
+ dst_r = (dst <= TMP_REG3) ? dst : TMP_REG1;
PTR_FAIL_IF(emit_imm32_const(compiler, dst_r, init_value));
if (dst & SLJIT_MEM)
@@ -1905,7 +2000,7 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_set_jump_addr(sljit_uw addr, sljit_uw new_ad
inline_set_jump_addr(addr, new_addr, 1);
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_w new_constant)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_sw new_constant)
{
sljit_uh* inst = (sljit_uh*)addr;
modify_imm32_const(inst, new_constant);
diff --git a/src/3rdparty/pcre/sljit/sljitNativeARM_v5.c b/src/3rdparty/pcre/sljit/sljitNativeARM_v5.c
index e3a5873247..23a45a4c6a 100644
--- a/src/3rdparty/pcre/sljit/sljitNativeARM_v5.c
+++ b/src/3rdparty/pcre/sljit/sljitNativeARM_v5.c
@@ -24,7 +24,7 @@
* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name()
+SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name(void)
{
#if (defined SLJIT_CONFIG_ARM_V7 && SLJIT_CONFIG_ARM_V7)
return "ARMv7" SLJIT_CPUINFO;
@@ -41,8 +41,8 @@ SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name()
#define TMP_REG3 (SLJIT_NO_REGISTERS + 3)
#define TMP_PC (SLJIT_NO_REGISTERS + 4)
-#define TMP_FREG1 (SLJIT_FLOAT_REG4 + 1)
-#define TMP_FREG2 (SLJIT_FLOAT_REG4 + 2)
+#define TMP_FREG1 (0)
+#define TMP_FREG2 (SLJIT_FLOAT_REG6 + 1)
/* In ARM instruction words.
Cache lines are usually 32 byte aligned. */
@@ -52,11 +52,11 @@ SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name()
#define ALIGN_INSTRUCTION(ptr) \
(sljit_uw*)(((sljit_uw)(ptr) + (CONST_POOL_ALIGNMENT * sizeof(sljit_uw)) - 1) & ~((CONST_POOL_ALIGNMENT * sizeof(sljit_uw)) - 1))
#define MAX_DIFFERENCE(max_diff) \
- (((max_diff) / (int)sizeof(sljit_uw)) - (CONST_POOL_ALIGNMENT - 1))
+ (((max_diff) / (sljit_si)sizeof(sljit_uw)) - (CONST_POOL_ALIGNMENT - 1))
/* See sljit_emit_enter and sljit_emit_op0 if you want to change them. */
static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 5] = {
- 0, 0, 1, 2, 10, 11, 4, 5, 6, 7, 8, 13, 3, 12, 14, 15
+ 0, 0, 1, 2, 10, 11, 4, 5, 6, 7, 8, 13, 3, 12, 14, 15
};
#define RM(rm) (reg_map[rm])
@@ -99,16 +99,16 @@ static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 5] = {
#define SMULL 0xe0c00090
#define SUB_DP 0x2
#define UMULL 0xe0800090
-#define VABS_F64 0xeeb00bc0
-#define VADD_F64 0xee300b00
-#define VCMP_F64 0xeeb40b40
-#define VDIV_F64 0xee800b00
-#define VMOV_F64 0xeeb00b40
+#define VABS_F32 0xeeb00ac0
+#define VADD_F32 0xee300a00
+#define VCMP_F32 0xeeb40a40
+#define VDIV_F32 0xee800a00
+#define VMOV_F32 0xeeb00a40
#define VMRS 0xeef1fa10
-#define VMUL_F64 0xee200b00
-#define VNEG_F64 0xeeb10b40
-#define VSTR 0xed000b00
-#define VSUB_F64 0xee300b40
+#define VMUL_F32 0xee200a00
+#define VNEG_F32 0xeeb10a40
+#define VSTR_F32 0xed000a00
+#define VSUB_F32 0xee300a40
#if (defined SLJIT_CONFIG_ARM_V7 && SLJIT_CONFIG_ARM_V7)
/* Arm v7 specific instructions. */
@@ -122,13 +122,13 @@ static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 5] = {
#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5)
-static int push_cpool(struct sljit_compiler *compiler)
+static sljit_si push_cpool(struct sljit_compiler *compiler)
{
/* Pushing the constant pool into the instruction stream. */
sljit_uw* inst;
sljit_uw* cpool_ptr;
sljit_uw* cpool_end;
- int i;
+ sljit_si i;
/* The label could point the address after the constant pool. */
if (compiler->last_label && compiler->last_label->size == compiler->size)
@@ -160,7 +160,7 @@ static int push_cpool(struct sljit_compiler *compiler)
return SLJIT_SUCCESS;
}
-static int push_inst(struct sljit_compiler *compiler, sljit_uw inst)
+static sljit_si push_inst(struct sljit_compiler *compiler, sljit_uw inst)
{
sljit_uw* ptr;
@@ -174,7 +174,7 @@ static int push_inst(struct sljit_compiler *compiler, sljit_uw inst)
return SLJIT_SUCCESS;
}
-static int push_inst_with_literal(struct sljit_compiler *compiler, sljit_uw inst, sljit_uw literal)
+static sljit_si push_inst_with_literal(struct sljit_compiler *compiler, sljit_uw inst, sljit_uw literal)
{
sljit_uw* ptr;
sljit_uw cpool_index = CPOOL_SIZE;
@@ -224,7 +224,7 @@ static int push_inst_with_literal(struct sljit_compiler *compiler, sljit_uw inst
return SLJIT_SUCCESS;
}
-static int push_inst_with_unique_literal(struct sljit_compiler *compiler, sljit_uw inst, sljit_uw literal)
+static sljit_si push_inst_with_unique_literal(struct sljit_compiler *compiler, sljit_uw inst, sljit_uw literal)
{
sljit_uw* ptr;
if (SLJIT_UNLIKELY((compiler->cpool_diff != CONST_POOL_EMPTY && compiler->size - compiler->cpool_diff >= MAX_DIFFERENCE(4092)) || compiler->cpool_fill >= CPOOL_SIZE))
@@ -244,7 +244,7 @@ static int push_inst_with_unique_literal(struct sljit_compiler *compiler, sljit_
return SLJIT_SUCCESS;
}
-static SLJIT_INLINE int prepare_blx(struct sljit_compiler *compiler)
+static SLJIT_INLINE sljit_si prepare_blx(struct sljit_compiler *compiler)
{
/* Place for at least two instruction (doesn't matter whether the first has a literal). */
if (SLJIT_UNLIKELY(compiler->cpool_diff != CONST_POOL_EMPTY && compiler->size - compiler->cpool_diff >= MAX_DIFFERENCE(4088)))
@@ -252,7 +252,7 @@ static SLJIT_INLINE int prepare_blx(struct sljit_compiler *compiler)
return SLJIT_SUCCESS;
}
-static SLJIT_INLINE int emit_blx(struct sljit_compiler *compiler)
+static SLJIT_INLINE sljit_si emit_blx(struct sljit_compiler *compiler)
{
/* Must follow tightly the previous instruction (to be able to convert it to bl instruction). */
SLJIT_ASSERT(compiler->cpool_diff == CONST_POOL_EMPTY || compiler->size - compiler->cpool_diff < MAX_DIFFERENCE(4092));
@@ -282,7 +282,7 @@ static sljit_uw patch_pc_relative_loads(sljit_uw *last_pc_patch, sljit_uw *code_
/* Must be a load instruction with immediate offset. */
SLJIT_ASSERT(ind < cpool_size && !(*last_pc_patch & (1 << 25)) && (*last_pc_patch & (1 << 20)));
- if ((int)const_pool[ind] < 0) {
+ if ((sljit_si)const_pool[ind] < 0) {
const_pool[ind] = counter;
ind = counter;
counter++;
@@ -307,24 +307,24 @@ static sljit_uw patch_pc_relative_loads(sljit_uw *last_pc_patch, sljit_uw *code_
/* In some rare ocasions we may need future patches. The probability is close to 0 in practice. */
struct future_patch {
struct future_patch* next;
- int index;
- int value;
+ sljit_si index;
+ sljit_si value;
};
-static SLJIT_INLINE int resolve_const_pool_index(struct future_patch **first_patch, sljit_uw cpool_current_index, sljit_uw *cpool_start_address, sljit_uw *buf_ptr)
+static SLJIT_INLINE sljit_si resolve_const_pool_index(struct future_patch **first_patch, sljit_uw cpool_current_index, sljit_uw *cpool_start_address, sljit_uw *buf_ptr)
{
- int value;
+ sljit_si value;
struct future_patch *curr_patch, *prev_patch;
/* Using the values generated by patch_pc_relative_loads. */
if (!*first_patch)
- value = (int)cpool_start_address[cpool_current_index];
+ value = (sljit_si)cpool_start_address[cpool_current_index];
else {
curr_patch = *first_patch;
prev_patch = 0;
while (1) {
if (!curr_patch) {
- value = (int)cpool_start_address[cpool_current_index];
+ value = (sljit_si)cpool_start_address[cpool_current_index];
break;
}
if ((sljit_uw)curr_patch->index == cpool_current_index) {
@@ -364,7 +364,7 @@ static SLJIT_INLINE int resolve_const_pool_index(struct future_patch **first_pat
#else
-static int push_inst(struct sljit_compiler *compiler, sljit_uw inst)
+static sljit_si push_inst(struct sljit_compiler *compiler, sljit_uw inst)
{
sljit_uw* ptr;
@@ -375,7 +375,7 @@ static int push_inst(struct sljit_compiler *compiler, sljit_uw inst)
return SLJIT_SUCCESS;
}
-static SLJIT_INLINE int emit_imm(struct sljit_compiler *compiler, int reg, sljit_w imm)
+static SLJIT_INLINE sljit_si emit_imm(struct sljit_compiler *compiler, sljit_si reg, sljit_sw imm)
{
FAIL_IF(push_inst(compiler, MOVW | RD(reg) | ((imm << 4) & 0xf0000) | (imm & 0xfff)));
return push_inst(compiler, MOVT | RD(reg) | ((imm >> 12) & 0xf0000) | ((imm >> 16) & 0xfff));
@@ -383,9 +383,9 @@ static SLJIT_INLINE int emit_imm(struct sljit_compiler *compiler, int reg, sljit
#endif
-static SLJIT_INLINE int detect_jump_type(struct sljit_jump *jump, sljit_uw *code_ptr, sljit_uw *code)
+static SLJIT_INLINE sljit_si detect_jump_type(struct sljit_jump *jump, sljit_uw *code_ptr, sljit_uw *code)
{
- sljit_w diff;
+ sljit_sw diff;
if (jump->flags & SLJIT_REWRITABLE_JUMP)
return 0;
@@ -395,10 +395,10 @@ static SLJIT_INLINE int detect_jump_type(struct sljit_jump *jump, sljit_uw *code
code_ptr--;
if (jump->flags & JUMP_ADDR)
- diff = ((sljit_w)jump->u.target - (sljit_w)(code_ptr + 2));
+ diff = ((sljit_sw)jump->u.target - (sljit_sw)(code_ptr + 2));
else {
SLJIT_ASSERT(jump->flags & JUMP_LABEL);
- diff = ((sljit_w)(code + jump->u.label->size) - (sljit_w)(code_ptr + 2));
+ diff = ((sljit_sw)(code + jump->u.label->size) - (sljit_sw)(code_ptr + 2));
}
/* Branch to Thumb code has not been optimized yet. */
@@ -421,10 +421,10 @@ static SLJIT_INLINE int detect_jump_type(struct sljit_jump *jump, sljit_uw *code
}
#else
if (jump->flags & JUMP_ADDR)
- diff = ((sljit_w)jump->u.target - (sljit_w)code_ptr);
+ diff = ((sljit_sw)jump->u.target - (sljit_sw)code_ptr);
else {
SLJIT_ASSERT(jump->flags & JUMP_LABEL);
- diff = ((sljit_w)(code + jump->u.label->size) - (sljit_w)code_ptr);
+ diff = ((sljit_sw)(code + jump->u.label->size) - (sljit_sw)code_ptr);
}
/* Branch to Thumb code has not been optimized yet. */
@@ -442,14 +442,14 @@ static SLJIT_INLINE int detect_jump_type(struct sljit_jump *jump, sljit_uw *code
return 0;
}
-static SLJIT_INLINE void inline_set_jump_addr(sljit_uw addr, sljit_uw new_addr, int flush)
+static SLJIT_INLINE void inline_set_jump_addr(sljit_uw addr, sljit_uw new_addr, sljit_si flush)
{
#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5)
sljit_uw *ptr = (sljit_uw*)addr;
sljit_uw *inst = (sljit_uw*)ptr[0];
sljit_uw mov_pc = ptr[1];
- int bl = (mov_pc & 0x0000f000) != RD(TMP_PC);
- sljit_w diff = (sljit_w)(((sljit_w)new_addr - (sljit_w)(inst + 2)) >> 2);
+ sljit_si bl = (mov_pc & 0x0000f000) != RD(TMP_PC);
+ sljit_sw diff = (sljit_sw)(((sljit_sw)new_addr - (sljit_sw)(inst + 2)) >> 2);
if (diff <= 0x7fffff && diff >= -0x800000) {
/* Turn to branch. */
@@ -498,9 +498,9 @@ static SLJIT_INLINE void inline_set_jump_addr(sljit_uw addr, sljit_uw new_addr,
#endif
}
-static sljit_uw get_immediate(sljit_uw imm);
+static sljit_uw get_imm(sljit_uw imm);
-static SLJIT_INLINE void inline_set_const(sljit_uw addr, sljit_w new_constant, int flush)
+static SLJIT_INLINE void inline_set_const(sljit_uw addr, sljit_sw new_constant, sljit_si flush)
{
#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5)
sljit_uw *ptr = (sljit_uw*)addr;
@@ -508,7 +508,7 @@ static SLJIT_INLINE void inline_set_const(sljit_uw addr, sljit_w new_constant, i
sljit_uw ldr_literal = ptr[1];
sljit_uw src2;
- src2 = get_immediate(new_constant);
+ src2 = get_imm(new_constant);
if (src2) {
*inst = 0xe3a00000 | (ldr_literal & 0xf000) | src2;
if (flush) {
@@ -517,7 +517,7 @@ static SLJIT_INLINE void inline_set_const(sljit_uw addr, sljit_w new_constant, i
return;
}
- src2 = get_immediate(~new_constant);
+ src2 = get_imm(~new_constant);
if (src2) {
*inst = 0xe3e00000 | (ldr_literal & 0xf000) | src2;
if (flush) {
@@ -730,12 +730,12 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
if (jump->flags & PATCH_B) {
if (!(jump->flags & JUMP_ADDR)) {
SLJIT_ASSERT(jump->flags & JUMP_LABEL);
- SLJIT_ASSERT(((sljit_w)jump->u.label->addr - (sljit_w)(buf_ptr + 2)) <= 0x01ffffff && ((sljit_w)jump->u.label->addr - (sljit_w)(buf_ptr + 2)) >= -0x02000000);
- *buf_ptr |= (((sljit_w)jump->u.label->addr - (sljit_w)(buf_ptr + 2)) >> 2) & 0x00ffffff;
+ SLJIT_ASSERT(((sljit_sw)jump->u.label->addr - (sljit_sw)(buf_ptr + 2)) <= 0x01ffffff && ((sljit_sw)jump->u.label->addr - (sljit_sw)(buf_ptr + 2)) >= -0x02000000);
+ *buf_ptr |= (((sljit_sw)jump->u.label->addr - (sljit_sw)(buf_ptr + 2)) >> 2) & 0x00ffffff;
}
else {
- SLJIT_ASSERT(((sljit_w)jump->u.target - (sljit_w)(buf_ptr + 2)) <= 0x01ffffff && ((sljit_w)jump->u.target - (sljit_w)(buf_ptr + 2)) >= -0x02000000);
- *buf_ptr |= (((sljit_w)jump->u.target - (sljit_w)(buf_ptr + 2)) >> 2) & 0x00ffffff;
+ SLJIT_ASSERT(((sljit_sw)jump->u.target - (sljit_sw)(buf_ptr + 2)) <= 0x01ffffff && ((sljit_sw)jump->u.target - (sljit_sw)(buf_ptr + 2)) >= -0x02000000);
+ *buf_ptr |= (((sljit_sw)jump->u.target - (sljit_sw)(buf_ptr + 2)) >> 2) & 0x00ffffff;
}
}
else if (jump->flags & SLJIT_REWRITABLE_JUMP) {
@@ -785,7 +785,7 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
}
#endif
- SLJIT_ASSERT(code_ptr - code <= (int)size);
+ SLJIT_ASSERT(code_ptr - code <= (sljit_si)size);
SLJIT_CACHE_FLUSH(code, code_ptr);
compiler->error = SLJIT_ERR_COMPILED;
@@ -793,6 +793,10 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
return code;
}
+/* --------------------------------------------------------------------- */
+/* Entry, exit */
+/* --------------------------------------------------------------------- */
+
/* emit_op inp_flags.
WRITE_BACK must be the first, since it is a flag. */
#define WRITE_BACK 0x01
@@ -815,28 +819,31 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
#define EMIT_DATA_PROCESS_INS(opcode, set_flags, dst, src1, src2) \
(0xe0000000 | ((opcode) << 21) | (set_flags) | RD(dst) | RN(src1) | (src2))
-static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w);
+static sljit_si emit_op(struct sljit_compiler *compiler, sljit_si op, sljit_si inp_flags,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w);
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_enter(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
- int size;
+ sljit_si size;
sljit_uw push;
CHECK_ERROR();
- check_sljit_emit_enter(compiler, args, temporaries, saveds, local_size);
+ check_sljit_emit_enter(compiler, args, scratches, saveds, local_size);
- compiler->temporaries = temporaries;
+ compiler->scratches = scratches;
compiler->saveds = saveds;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
/* Push saved registers, temporary registers
stmdb sp!, {..., lr} */
push = PUSH | (1 << 14);
- if (temporaries >= 5)
+ if (scratches >= 5)
push |= 1 << 11;
- if (temporaries >= 4)
+ if (scratches >= 4)
push |= 1 << 10;
if (saveds >= 5)
push |= 1 << 8;
@@ -852,8 +859,8 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, i
/* Stack must be aligned to 8 bytes: */
size = (1 + saveds) * sizeof(sljit_uw);
- if (temporaries >= 4)
- size += (temporaries - 3) * sizeof(sljit_uw);
+ if (scratches >= 4)
+ size += (scratches - 3) * sizeof(sljit_uw);
local_size += size;
local_size = (local_size + 7) & ~7;
local_size -= size;
@@ -862,35 +869,38 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, i
FAIL_IF(emit_op(compiler, SLJIT_SUB, ALLOW_IMM, SLJIT_LOCALS_REG, 0, SLJIT_LOCALS_REG, 0, SLJIT_IMM, local_size));
if (args >= 1)
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, SLJIT_SAVED_REG1, SLJIT_UNUSED, RM(SLJIT_TEMPORARY_REG1)));
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, SLJIT_SAVED_REG1, SLJIT_UNUSED, RM(SLJIT_SCRATCH_REG1)));
if (args >= 2)
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, SLJIT_SAVED_REG2, SLJIT_UNUSED, RM(SLJIT_TEMPORARY_REG2)));
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, SLJIT_SAVED_REG2, SLJIT_UNUSED, RM(SLJIT_SCRATCH_REG2)));
if (args >= 3)
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, SLJIT_SAVED_REG3, SLJIT_UNUSED, RM(SLJIT_TEMPORARY_REG3)));
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, SLJIT_SAVED_REG3, SLJIT_UNUSED, RM(SLJIT_SCRATCH_REG3)));
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
- int size;
+ sljit_si size;
CHECK_ERROR_VOID();
- check_sljit_set_context(compiler, args, temporaries, saveds, local_size);
+ check_sljit_set_context(compiler, args, scratches, saveds, local_size);
- compiler->temporaries = temporaries;
+ compiler->scratches = scratches;
compiler->saveds = saveds;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
size = (1 + saveds) * sizeof(sljit_uw);
- if (temporaries >= 4)
- size += (temporaries - 3) * sizeof(sljit_uw);
+ if (scratches >= 4)
+ size += (scratches - 3) * sizeof(sljit_uw);
local_size += size;
local_size = (local_size + 7) & ~7;
local_size -= size;
compiler->local_size = local_size;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler, int op, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_return(struct sljit_compiler *compiler, sljit_si op, sljit_si src, sljit_sw srcw)
{
sljit_uw pop;
@@ -905,9 +915,9 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
pop = POP | (1 << 15);
/* Push saved registers, temporary registers
ldmia sp!, {..., pc} */
- if (compiler->temporaries >= 5)
+ if (compiler->scratches >= 5)
pop |= 1 << 11;
- if (compiler->temporaries >= 4)
+ if (compiler->scratches >= 4)
pop |= 1 << 10;
if (compiler->saveds >= 5)
pop |= 1 << 8;
@@ -932,7 +942,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
w/b/h/N - word/byte/half/NOT allowed (2 bit)
It contans 16 items, but not all are different. */
-static sljit_w data_transfer_insts[16] = {
+static sljit_sw data_transfer_insts[16] = {
/* s u w */ 0xe5000000 /* str */,
/* s u b */ 0xe5400000 /* strb */,
/* s u h */ 0xe10000b0 /* strh */,
@@ -998,12 +1008,80 @@ static sljit_w data_transfer_insts[16] = {
} \
return push_inst(compiler, EMIT_DATA_PROCESS_INS(MOV_DP, flags & SET_FLAGS, dst, SLJIT_UNUSED, (reg_map[(flags & ARGS_SWAPPED) ? src1 : src2] << 8) | (opcode << 5) | 0x10 | ((flags & ARGS_SWAPPED) ? reg_map[src2] : reg_map[src1])));
-static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op, int flags,
- int dst, int src1, int src2)
+static SLJIT_INLINE sljit_si emit_single_op(struct sljit_compiler *compiler, sljit_si op, sljit_si flags,
+ sljit_si dst, sljit_si src1, sljit_si src2)
{
- sljit_w mul_inst;
+ sljit_sw mul_inst;
switch (GET_OPCODE(op)) {
+ case SLJIT_MOV:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & ARGS_SWAPPED));
+ if (dst != src2) {
+ if (src2 & SRC2_IMM) {
+ if (flags & INV_IMM)
+ EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MVN_DP, dst, SLJIT_UNUSED, src2);
+ EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MOV_DP, dst, SLJIT_UNUSED, src2);
+ }
+ EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MOV_DP, dst, SLJIT_UNUSED, reg_map[src2]);
+ }
+ return SLJIT_SUCCESS;
+
+ case SLJIT_MOV_UB:
+ case SLJIT_MOV_SB:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & ARGS_SWAPPED));
+ if ((flags & (REG_DEST | REG_SOURCE)) == (REG_DEST | REG_SOURCE)) {
+#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5)
+ if (op == SLJIT_MOV_UB)
+ return push_inst(compiler, EMIT_DATA_PROCESS_INS(AND_DP, 0, dst, src2, SRC2_IMM | 0xff));
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, dst, SLJIT_UNUSED, (24 << 7) | reg_map[src2]));
+ return push_inst(compiler, EMIT_DATA_PROCESS_INS(MOV_DP, 0, dst, SLJIT_UNUSED, (24 << 7) | (op == SLJIT_MOV_UB ? 0x20 : 0x40) | reg_map[dst]));
+#else
+ return push_inst(compiler, (op == SLJIT_MOV_UB ? UXTB : SXTB) | RD(dst) | RM(src2));
+#endif
+ }
+ else if (dst != src2) {
+ SLJIT_ASSERT(src2 & SRC2_IMM);
+ if (flags & INV_IMM)
+ EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MVN_DP, dst, SLJIT_UNUSED, src2);
+ EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MOV_DP, dst, SLJIT_UNUSED, src2);
+ }
+ return SLJIT_SUCCESS;
+
+ case SLJIT_MOV_UH:
+ case SLJIT_MOV_SH:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & ARGS_SWAPPED));
+ if ((flags & (REG_DEST | REG_SOURCE)) == (REG_DEST | REG_SOURCE)) {
+#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5)
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, dst, SLJIT_UNUSED, (16 << 7) | reg_map[src2]));
+ return push_inst(compiler, EMIT_DATA_PROCESS_INS(MOV_DP, 0, dst, SLJIT_UNUSED, (16 << 7) | (op == SLJIT_MOV_UH ? 0x20 : 0x40) | reg_map[dst]));
+#else
+ return push_inst(compiler, (op == SLJIT_MOV_UH ? UXTH : SXTH) | RD(dst) | RM(src2));
+#endif
+ }
+ else if (dst != src2) {
+ SLJIT_ASSERT(src2 & SRC2_IMM);
+ if (flags & INV_IMM)
+ EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MVN_DP, dst, SLJIT_UNUSED, src2);
+ EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MOV_DP, dst, SLJIT_UNUSED, src2);
+ }
+ return SLJIT_SUCCESS;
+
+ case SLJIT_NOT:
+ if (src2 & SRC2_IMM) {
+ if (flags & INV_IMM)
+ EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MOV_DP, dst, SLJIT_UNUSED, src2);
+ EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MVN_DP, dst, SLJIT_UNUSED, src2);
+ }
+ EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MVN_DP, dst, SLJIT_UNUSED, RM(src2));
+
+ case SLJIT_CLZ:
+ SLJIT_ASSERT(!(flags & INV_IMM));
+ SLJIT_ASSERT(!(src2 & SRC2_IMM));
+ FAIL_IF(push_inst(compiler, CLZ | RD(dst) | RM(src2)));
+ if (flags & SET_FLAGS)
+ EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(CMP_DP, SLJIT_UNUSED, dst, SRC2_IMM);
+ return SLJIT_SUCCESS;
+
case SLJIT_ADD:
SLJIT_ASSERT(!(flags & INV_IMM));
EMIT_DATA_PROCESS_INS_AND_RETURN(ADD_DP);
@@ -1073,74 +1151,6 @@ static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op,
case SLJIT_ASHR:
EMIT_SHIFT_INS_AND_RETURN(2);
-
- case SLJIT_MOV:
- SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & ARGS_SWAPPED));
- if (dst != src2) {
- if (src2 & SRC2_IMM) {
- if (flags & INV_IMM)
- EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MVN_DP, dst, SLJIT_UNUSED, src2);
- EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MOV_DP, dst, SLJIT_UNUSED, src2);
- }
- EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MOV_DP, dst, SLJIT_UNUSED, reg_map[src2]);
- }
- return SLJIT_SUCCESS;
-
- case SLJIT_MOV_UB:
- case SLJIT_MOV_SB:
- SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & ARGS_SWAPPED));
- if ((flags & (REG_DEST | REG_SOURCE)) == (REG_DEST | REG_SOURCE)) {
-#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5)
- if (op == SLJIT_MOV_UB)
- return push_inst(compiler, EMIT_DATA_PROCESS_INS(AND_DP, 0, dst, src2, SRC2_IMM | 0xff));
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, dst, SLJIT_UNUSED, (24 << 7) | reg_map[src2]));
- return push_inst(compiler, EMIT_DATA_PROCESS_INS(MOV_DP, 0, dst, SLJIT_UNUSED, (24 << 7) | (op == SLJIT_MOV_UB ? 0x20 : 0x40) | reg_map[dst]));
-#else
- return push_inst(compiler, (op == SLJIT_MOV_UB ? UXTB : SXTB) | RD(dst) | RM(src2));
-#endif
- }
- else if (dst != src2) {
- SLJIT_ASSERT(src2 & SRC2_IMM);
- if (flags & INV_IMM)
- EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MVN_DP, dst, SLJIT_UNUSED, src2);
- EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MOV_DP, dst, SLJIT_UNUSED, src2);
- }
- return SLJIT_SUCCESS;
-
- case SLJIT_MOV_UH:
- case SLJIT_MOV_SH:
- SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & ARGS_SWAPPED));
- if ((flags & (REG_DEST | REG_SOURCE)) == (REG_DEST | REG_SOURCE)) {
-#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5)
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, dst, SLJIT_UNUSED, (16 << 7) | reg_map[src2]));
- return push_inst(compiler, EMIT_DATA_PROCESS_INS(MOV_DP, 0, dst, SLJIT_UNUSED, (16 << 7) | (op == SLJIT_MOV_UH ? 0x20 : 0x40) | reg_map[dst]));
-#else
- return push_inst(compiler, (op == SLJIT_MOV_UH ? UXTH : SXTH) | RD(dst) | RM(src2));
-#endif
- }
- else if (dst != src2) {
- SLJIT_ASSERT(src2 & SRC2_IMM);
- if (flags & INV_IMM)
- EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MVN_DP, dst, SLJIT_UNUSED, src2);
- EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MOV_DP, dst, SLJIT_UNUSED, src2);
- }
- return SLJIT_SUCCESS;
-
- case SLJIT_NOT:
- if (src2 & SRC2_IMM) {
- if (flags & INV_IMM)
- EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MOV_DP, dst, SLJIT_UNUSED, src2);
- EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MVN_DP, dst, SLJIT_UNUSED, src2);
- }
- EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(MVN_DP, dst, SLJIT_UNUSED, RM(src2));
-
- case SLJIT_CLZ:
- SLJIT_ASSERT(!(flags & INV_IMM));
- SLJIT_ASSERT(!(src2 & SRC2_IMM));
- FAIL_IF(push_inst(compiler, CLZ | RD(dst) | RM(src2)));
- if (flags & SET_FLAGS)
- EMIT_FULL_DATA_PROCESS_INS_AND_RETURN(CMP_DP, SLJIT_UNUSED, dst, SRC2_IMM);
- return SLJIT_SUCCESS;
}
SLJIT_ASSERT_STOP();
return SLJIT_SUCCESS;
@@ -1152,9 +1162,9 @@ static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op,
/* Tests whether the immediate can be stored in the 12 bit imm field.
Returns with 0 if not possible. */
-static sljit_uw get_immediate(sljit_uw imm)
+static sljit_uw get_imm(sljit_uw imm)
{
- int rol;
+ sljit_si rol;
if (imm <= 0xff)
return SRC2_IMM | imm;
@@ -1190,12 +1200,12 @@ static sljit_uw get_immediate(sljit_uw imm)
}
#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5)
-static int generate_int(struct sljit_compiler *compiler, int reg, sljit_uw imm, int positive)
+static sljit_si generate_int(struct sljit_compiler *compiler, sljit_si reg, sljit_uw imm, sljit_si positive)
{
sljit_uw mask;
sljit_uw imm1;
sljit_uw imm2;
- int rol;
+ sljit_si rol;
/* Step1: Search a zero byte (8 continous zero bit). */
mask = 0xff000000;
@@ -1301,7 +1311,7 @@ static int generate_int(struct sljit_compiler *compiler, int reg, sljit_uw imm,
}
#endif
-static int load_immediate(struct sljit_compiler *compiler, int reg, sljit_uw imm)
+static sljit_si load_immediate(struct sljit_compiler *compiler, sljit_si reg, sljit_uw imm)
{
sljit_uw tmp;
@@ -1311,13 +1321,13 @@ static int load_immediate(struct sljit_compiler *compiler, int reg, sljit_uw imm
#endif
/* Create imm by 1 inst. */
- tmp = get_immediate(imm);
+ tmp = get_imm(imm);
if (tmp) {
EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, reg, SLJIT_UNUSED, tmp));
return SLJIT_SUCCESS;
}
- tmp = get_immediate(~imm);
+ tmp = get_imm(~imm);
if (tmp) {
EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MVN_DP, 0, reg, SLJIT_UNUSED, tmp));
return SLJIT_SUCCESS;
@@ -1335,20 +1345,36 @@ static int load_immediate(struct sljit_compiler *compiler, int reg, sljit_uw imm
#endif
}
+/* Helper function. Dst should be reg + value, using at most 1 instruction, flags does not set. */
+static sljit_si emit_set_delta(struct sljit_compiler *compiler, sljit_si dst, sljit_si reg, sljit_sw value)
+{
+ if (value >= 0) {
+ value = get_imm(value);
+ if (value)
+ return push_inst(compiler, EMIT_DATA_PROCESS_INS(ADD_DP, 0, dst, reg, value));
+ }
+ else {
+ value = get_imm(-value);
+ if (value)
+ return push_inst(compiler, EMIT_DATA_PROCESS_INS(SUB_DP, 0, dst, reg, value));
+ }
+ return SLJIT_ERR_UNSUPPORTED;
+}
+
/* Can perform an operation using at most 1 instruction. */
-static int getput_arg_fast(struct sljit_compiler *compiler, int inp_flags, int reg, int arg, sljit_w argw)
+static sljit_si getput_arg_fast(struct sljit_compiler *compiler, sljit_si inp_flags, sljit_si reg, sljit_si arg, sljit_sw argw)
{
sljit_uw imm;
if (arg & SLJIT_IMM) {
- imm = get_immediate(argw);
+ imm = get_imm(argw);
if (imm) {
if (inp_flags & ARG_TEST)
return 1;
EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, reg, SLJIT_UNUSED, imm));
return -1;
}
- imm = get_immediate(~argw);
+ imm = get_imm(~argw);
if (imm) {
if (inp_flags & ARG_TEST)
return 1;
@@ -1408,7 +1434,7 @@ static int getput_arg_fast(struct sljit_compiler *compiler, int inp_flags, int r
/* See getput_arg below.
Note: can_cache is called only for binary operators. Those
operators always uses word arguments without write back. */
-static int can_cache(int arg, sljit_w argw, int next_arg, sljit_w next_argw)
+static sljit_si can_cache(sljit_si arg, sljit_sw argw, sljit_si next_arg, sljit_sw next_argw)
{
/* Immediate caching is not supported as it would be an operation on constant arguments. */
if (arg & SLJIT_IMM)
@@ -1456,11 +1482,12 @@ static int can_cache(int arg, sljit_w argw, int next_arg, sljit_w next_argw)
}
/* Emit the necessary instructions. See can_cache above. */
-static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, int arg, sljit_w argw, int next_arg, sljit_w next_argw)
+static sljit_si getput_arg(struct sljit_compiler *compiler, sljit_si inp_flags, sljit_si reg, sljit_si arg, sljit_sw argw, sljit_si next_arg, sljit_sw next_argw)
{
- int tmp_r;
- sljit_w max_delta;
- sljit_w sign;
+ sljit_si tmp_r;
+ sljit_sw max_delta;
+ sljit_sw sign;
+ sljit_uw imm;
if (arg & SLJIT_IMM) {
SLJIT_ASSERT(inp_flags & LOAD_DATA);
@@ -1474,8 +1501,9 @@ static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, i
if ((arg & 0xf) == SLJIT_UNUSED) {
/* Write back is not used. */
- if ((compiler->cache_arg & SLJIT_IMM) && (((sljit_uw)argw - (sljit_uw)compiler->cache_argw) <= (sljit_uw)max_delta || ((sljit_uw)compiler->cache_argw - (sljit_uw)argw) <= (sljit_uw)max_delta)) {
- if (((sljit_uw)argw - (sljit_uw)compiler->cache_argw) <= (sljit_uw)max_delta) {
+ imm = (sljit_uw)(argw - compiler->cache_argw);
+ if ((compiler->cache_arg & SLJIT_IMM) && (imm <= (sljit_uw)max_delta || imm >= (sljit_uw)-max_delta)) {
+ if (imm <= (sljit_uw)max_delta) {
sign = 1;
argw = argw - compiler->cache_argw;
}
@@ -1484,18 +1512,14 @@ static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, i
argw = compiler->cache_argw - argw;
}
- if (max_delta & 0xf00) {
- EMIT_INSTRUCTION(EMIT_DATA_TRANSFER(inp_flags, sign, 0, reg, TMP_REG3, argw));
- }
- else {
- EMIT_INSTRUCTION(EMIT_DATA_TRANSFER(inp_flags, sign, 0, reg, TMP_REG3, TYPE2_TRANSFER_IMM(argw)));
- }
+ GETPUT_ARG_DATA_TRANSFER(sign, 0, reg, TMP_REG3, argw);
return SLJIT_SUCCESS;
}
/* With write back, we can create some sophisticated loads, but
it is hard to decide whether we should convert downward (0s) or upward (1s). */
- if ((next_arg & SLJIT_MEM) && ((sljit_uw)argw - (sljit_uw)next_argw <= (sljit_uw)max_delta || (sljit_uw)next_argw - (sljit_uw)argw <= (sljit_uw)max_delta)) {
+ imm = (sljit_uw)(argw - next_argw);
+ if ((next_arg & SLJIT_MEM) && (imm <= (sljit_uw)max_delta || imm >= (sljit_uw)-max_delta)) {
SLJIT_ASSERT(inp_flags & LOAD_DATA);
compiler->cache_arg = SLJIT_IMM;
@@ -1508,29 +1532,6 @@ static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, i
return SLJIT_SUCCESS;
}
- /* Extended imm addressing for [reg+imm] format. */
- sign = (max_delta << 8) | 0xff;
- if (!(arg & 0xf0) && argw <= sign && argw >= -sign) {
- TEST_WRITE_BACK();
- if (argw >= 0) {
- sign = 1;
- }
- else {
- sign = 0;
- argw = -argw;
- }
-
- /* Optimization: add is 0x4, sub is 0x2. Sign is 1 for add and 0 for sub. */
- if (max_delta & 0xf00)
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(SUB_DP << sign, 0, tmp_r, arg & 0xf, SRC2_IMM | (argw >> 12) | 0xa00));
- else
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(SUB_DP << sign, 0, tmp_r, arg & 0xf, SRC2_IMM | (argw >> 8) | 0xc00));
-
- argw &= max_delta;
- GETPUT_ARG_DATA_TRANSFER(sign, inp_flags & WRITE_BACK, reg, tmp_r, argw);
- return SLJIT_SUCCESS;
- }
-
if (arg & 0xf0) {
SLJIT_ASSERT((argw & 0x3) && !(max_delta & 0xf00));
if (inp_flags & WRITE_BACK)
@@ -1540,17 +1541,33 @@ static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, i
return SLJIT_SUCCESS;
}
- if (compiler->cache_arg == arg && ((sljit_uw)argw - (sljit_uw)compiler->cache_argw) <= (sljit_uw)max_delta) {
+ imm = (sljit_uw)(argw - compiler->cache_argw);
+ if (compiler->cache_arg == arg && imm <= (sljit_uw)max_delta) {
SLJIT_ASSERT(!(inp_flags & WRITE_BACK));
- argw = argw - compiler->cache_argw;
- GETPUT_ARG_DATA_TRANSFER(1, 0, reg, TMP_REG3, argw);
+ GETPUT_ARG_DATA_TRANSFER(1, 0, reg, TMP_REG3, imm);
return SLJIT_SUCCESS;
}
-
- if (compiler->cache_arg == arg && ((sljit_uw)compiler->cache_argw - (sljit_uw)argw) <= (sljit_uw)max_delta) {
+ if (compiler->cache_arg == arg && imm >= (sljit_uw)-max_delta) {
SLJIT_ASSERT(!(inp_flags & WRITE_BACK));
- argw = compiler->cache_argw - argw;
- GETPUT_ARG_DATA_TRANSFER(0, 0, reg, TMP_REG3, argw);
+ imm = (sljit_uw)-(sljit_sw)imm;
+ GETPUT_ARG_DATA_TRANSFER(0, 0, reg, TMP_REG3, imm);
+ return SLJIT_SUCCESS;
+ }
+
+ imm = get_imm(argw & ~max_delta);
+ if (imm) {
+ TEST_WRITE_BACK();
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(ADD_DP, 0, tmp_r, arg & 0xf, imm));
+ GETPUT_ARG_DATA_TRANSFER(1, inp_flags & WRITE_BACK, reg, tmp_r, argw & max_delta);
+ return SLJIT_SUCCESS;
+ }
+
+ imm = get_imm(-argw & ~max_delta);
+ if (imm) {
+ argw = -argw;
+ TEST_WRITE_BACK();
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(SUB_DP, 0, tmp_r, arg & 0xf, imm));
+ GETPUT_ARG_DATA_TRANSFER(0, inp_flags & WRITE_BACK, reg, tmp_r, argw & max_delta);
return SLJIT_SUCCESS;
}
@@ -1572,7 +1589,8 @@ static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, i
return SLJIT_SUCCESS;
}
- if (arg == next_arg && !(inp_flags & WRITE_BACK) && ((sljit_uw)argw - (sljit_uw)next_argw <= (sljit_uw)max_delta || (sljit_uw)next_argw - (sljit_uw)argw <= (sljit_uw)max_delta)) {
+ imm = (sljit_uw)(argw - next_argw);
+ if (arg == next_arg && !(inp_flags & WRITE_BACK) && (imm <= (sljit_uw)max_delta || imm >= (sljit_uw)-max_delta)) {
SLJIT_ASSERT(inp_flags & LOAD_DATA);
FAIL_IF(load_immediate(compiler, TMP_REG3, argw));
EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(ADD_DP, 0, TMP_REG3, TMP_REG3, reg_map[arg & 0xf]));
@@ -1595,10 +1613,26 @@ static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, i
return SLJIT_SUCCESS;
}
-static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+static SLJIT_INLINE sljit_si emit_op_mem(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg, sljit_sw argw)
+{
+ if (getput_arg_fast(compiler, flags, reg, arg, argw))
+ return compiler->error;
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+ return getput_arg(compiler, flags, reg, arg, argw, 0, 0);
+}
+
+static SLJIT_INLINE sljit_si emit_op_mem2(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg1, sljit_sw arg1w, sljit_si arg2, sljit_sw arg2w)
+{
+ if (getput_arg_fast(compiler, flags, reg, arg1, arg1w))
+ return compiler->error;
+ return getput_arg(compiler, flags, reg, arg1, arg1w, arg2, arg2w);
+}
+
+static sljit_si emit_op(struct sljit_compiler *compiler, sljit_si op, sljit_si inp_flags,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
/* arg1 goes to TMP_REG1 or src reg
arg2 goes to TMP_REG2, imm or src reg
@@ -1606,27 +1640,27 @@ static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
result goes to TMP_REG2, so put result can use TMP_REG1 and TMP_REG3. */
/* We prefers register and simple consts. */
- int dst_r;
- int src1_r;
- int src2_r = 0;
- int sugg_src2_r = TMP_REG2;
- int flags = GET_FLAGS(op) ? SET_FLAGS : 0;
+ sljit_si dst_r;
+ sljit_si src1_r;
+ sljit_si src2_r = 0;
+ sljit_si sugg_src2_r = TMP_REG2;
+ sljit_si flags = GET_FLAGS(op) ? SET_FLAGS : 0;
compiler->cache_arg = 0;
compiler->cache_argw = 0;
/* Destination check. */
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= TMP_REG3) {
+ if (SLJIT_UNLIKELY(dst == SLJIT_UNUSED)) {
+ if (op >= SLJIT_MOV && op <= SLJIT_MOVU_SI && !(src2 & SLJIT_MEM))
+ return SLJIT_SUCCESS;
+ dst_r = TMP_REG2;
+ }
+ else if (dst <= TMP_REG3) {
dst_r = dst;
flags |= REG_DEST;
if (op >= SLJIT_MOV && op <= SLJIT_MOVU_SI)
sugg_src2_r = dst_r;
}
- else if (dst == SLJIT_UNUSED) {
- if (op >= SLJIT_MOV && op <= SLJIT_MOVU_SI && !(src2 & SLJIT_MEM))
- return SLJIT_SUCCESS;
- dst_r = TMP_REG2;
- }
else {
SLJIT_ASSERT(dst & SLJIT_MEM);
if (getput_arg_fast(compiler, inp_flags | ARG_TEST, TMP_REG2, dst, dstw)) {
@@ -1640,43 +1674,55 @@ static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
}
/* Source 1. */
- if (src1 >= SLJIT_TEMPORARY_REG1 && src1 <= TMP_REG3)
+ if (src1 <= TMP_REG3)
src1_r = src1;
- else if (src2 >= SLJIT_TEMPORARY_REG1 && src2 <= TMP_REG3) {
+ else if (src2 <= TMP_REG3) {
flags |= ARGS_SWAPPED;
src1_r = src2;
src2 = src1;
src2w = src1w;
}
- else {
+ else do { /* do { } while(0) is used because of breaks. */
+ src1_r = 0;
if ((inp_flags & ALLOW_ANY_IMM) && (src1 & SLJIT_IMM)) {
/* The second check will generate a hit. */
- src2_r = get_immediate(src1w);
+ src2_r = get_imm(src1w);
if (src2_r) {
flags |= ARGS_SWAPPED;
src1 = src2;
src1w = src2w;
+ break;
}
if (inp_flags & ALLOW_INV_IMM) {
- src2_r = get_immediate(~src1w);
+ src2_r = get_imm(~src1w);
if (src2_r) {
flags |= ARGS_SWAPPED | INV_IMM;
src1 = src2;
src1w = src2w;
+ break;
+ }
+ }
+ if (GET_OPCODE(op) == SLJIT_ADD) {
+ src2_r = get_imm(-src1w);
+ if (src2_r) {
+ /* Note: ARGS_SWAPPED is intentionally not applied! */
+ src1 = src2;
+ src1w = src2w;
+ op = SLJIT_SUB | GET_ALL_FLAGS(op);
+ break;
}
}
}
- src1_r = 0;
if (getput_arg_fast(compiler, inp_flags | LOAD_DATA, TMP_REG1, src1, src1w)) {
FAIL_IF(compiler->error);
src1_r = TMP_REG1;
}
- }
+ } while (0);
/* Source 2. */
if (src2_r == 0) {
- if (src2 >= SLJIT_TEMPORARY_REG1 && src2 <= TMP_REG3) {
+ if (src2 <= TMP_REG3) {
src2_r = src2;
flags |= REG_SOURCE;
if (!(flags & REG_DEST) && op >= SLJIT_MOV && op <= SLJIT_MOVU_SI)
@@ -1684,16 +1730,32 @@ static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
}
else do { /* do { } while(0) is used because of breaks. */
if ((inp_flags & ALLOW_ANY_IMM) && (src2 & SLJIT_IMM)) {
- src2_r = get_immediate(src2w);
+ src2_r = get_imm(src2w);
if (src2_r)
break;
if (inp_flags & ALLOW_INV_IMM) {
- src2_r = get_immediate(~src2w);
+ src2_r = get_imm(~src2w);
if (src2_r) {
flags |= INV_IMM;
break;
}
}
+ if (GET_OPCODE(op) == SLJIT_ADD) {
+ src2_r = get_imm(-src2w);
+ if (src2_r) {
+ op = SLJIT_SUB | GET_ALL_FLAGS(op);
+ flags &= ~ARGS_SWAPPED;
+ break;
+ }
+ }
+ if (GET_OPCODE(op) == SLJIT_SUB && !(flags & ARGS_SWAPPED)) {
+ src2_r = get_imm(-src2w);
+ if (src2_r) {
+ op = SLJIT_ADD | GET_ALL_FLAGS(op);
+ flags &= ~ARGS_SWAPPED;
+ break;
+ }
+ }
}
/* src2_r is 0. */
@@ -1762,8 +1824,8 @@ extern "C" {
#endif
#if defined(__GNUC__)
-extern unsigned int __aeabi_uidivmod(unsigned numerator, unsigned denominator);
-extern unsigned int __aeabi_idivmod(unsigned numerator, unsigned denominator);
+extern unsigned int __aeabi_uidivmod(unsigned int numerator, unsigned int denominator);
+extern int __aeabi_idivmod(int numerator, int denominator);
#else
#error "Software divmod functions are needed"
#endif
@@ -1772,7 +1834,7 @@ extern unsigned int __aeabi_idivmod(unsigned numerator, unsigned denominator);
}
#endif
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int op)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op)
{
CHECK_ERROR();
check_sljit_emit_op0(compiler, op);
@@ -1789,21 +1851,21 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
case SLJIT_SMUL:
#if (defined SLJIT_CONFIG_ARM_V7 && SLJIT_CONFIG_ARM_V7)
return push_inst(compiler, (op == SLJIT_UMUL ? UMULL : SMULL)
- | (reg_map[SLJIT_TEMPORARY_REG2] << 16)
- | (reg_map[SLJIT_TEMPORARY_REG1] << 12)
- | (reg_map[SLJIT_TEMPORARY_REG1] << 8)
- | reg_map[SLJIT_TEMPORARY_REG2]);
+ | (reg_map[SLJIT_SCRATCH_REG2] << 16)
+ | (reg_map[SLJIT_SCRATCH_REG1] << 12)
+ | (reg_map[SLJIT_SCRATCH_REG1] << 8)
+ | reg_map[SLJIT_SCRATCH_REG2]);
#else
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, TMP_REG1, SLJIT_UNUSED, RM(SLJIT_TEMPORARY_REG2)));
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, TMP_REG1, SLJIT_UNUSED, RM(SLJIT_SCRATCH_REG2)));
return push_inst(compiler, (op == SLJIT_UMUL ? UMULL : SMULL)
- | (reg_map[SLJIT_TEMPORARY_REG2] << 16)
- | (reg_map[SLJIT_TEMPORARY_REG1] << 12)
- | (reg_map[SLJIT_TEMPORARY_REG1] << 8)
+ | (reg_map[SLJIT_SCRATCH_REG2] << 16)
+ | (reg_map[SLJIT_SCRATCH_REG1] << 12)
+ | (reg_map[SLJIT_SCRATCH_REG1] << 8)
| reg_map[TMP_REG1]);
#endif
case SLJIT_UDIV:
case SLJIT_SDIV:
- if (compiler->temporaries >= 3)
+ if (compiler->scratches >= 3)
EMIT_INSTRUCTION(0xe52d2008 /* str r2, [sp, #-8]! */);
#if defined(__GNUC__)
FAIL_IF(sljit_emit_ijump(compiler, SLJIT_FAST_CALL, SLJIT_IMM,
@@ -1811,7 +1873,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
#else
#error "Software divmod functions are needed"
#endif
- if (compiler->temporaries >= 3)
+ if (compiler->scratches >= 3)
return push_inst(compiler, 0xe49d2008 /* ldr r2, [sp], #8 */);
return SLJIT_SUCCESS;
}
@@ -1819,47 +1881,51 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
CHECK_ERROR();
check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
switch (GET_OPCODE(op)) {
case SLJIT_MOV:
case SLJIT_MOV_UI:
case SLJIT_MOV_SI:
+ case SLJIT_MOV_P:
return emit_op(compiler, SLJIT_MOV, ALLOW_ANY_IMM, dst, dstw, TMP_REG1, 0, src, srcw);
case SLJIT_MOV_UB:
- return emit_op(compiler, SLJIT_MOV_UB, ALLOW_ANY_IMM | BYTE_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (unsigned char)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_UB, ALLOW_ANY_IMM | BYTE_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_ub)srcw : srcw);
case SLJIT_MOV_SB:
- return emit_op(compiler, SLJIT_MOV_SB, ALLOW_ANY_IMM | SIGNED_DATA | BYTE_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (signed char)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_SB, ALLOW_ANY_IMM | SIGNED_DATA | BYTE_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_sb)srcw : srcw);
case SLJIT_MOV_UH:
- return emit_op(compiler, SLJIT_MOV_UH, ALLOW_ANY_IMM | HALF_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (unsigned short)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_UH, ALLOW_ANY_IMM | HALF_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_uh)srcw : srcw);
case SLJIT_MOV_SH:
- return emit_op(compiler, SLJIT_MOV_SH, ALLOW_ANY_IMM | SIGNED_DATA | HALF_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (signed short)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_SH, ALLOW_ANY_IMM | SIGNED_DATA | HALF_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_sh)srcw : srcw);
case SLJIT_MOVU:
case SLJIT_MOVU_UI:
case SLJIT_MOVU_SI:
+ case SLJIT_MOVU_P:
return emit_op(compiler, SLJIT_MOV, ALLOW_ANY_IMM | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
case SLJIT_MOVU_UB:
- return emit_op(compiler, SLJIT_MOV_UB, ALLOW_ANY_IMM | BYTE_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (unsigned char)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_UB, ALLOW_ANY_IMM | BYTE_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_ub)srcw : srcw);
case SLJIT_MOVU_SB:
- return emit_op(compiler, SLJIT_MOV_SB, ALLOW_ANY_IMM | SIGNED_DATA | BYTE_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (signed char)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_SB, ALLOW_ANY_IMM | SIGNED_DATA | BYTE_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_sb)srcw : srcw);
case SLJIT_MOVU_UH:
- return emit_op(compiler, SLJIT_MOV_UH, ALLOW_ANY_IMM | HALF_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (unsigned short)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_UH, ALLOW_ANY_IMM | HALF_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_uh)srcw : srcw);
case SLJIT_MOVU_SH:
- return emit_op(compiler, SLJIT_MOV_SH, ALLOW_ANY_IMM | SIGNED_DATA | HALF_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (signed short)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_SH, ALLOW_ANY_IMM | SIGNED_DATA | HALF_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_sh)srcw : srcw);
case SLJIT_NOT:
return emit_op(compiler, op, ALLOW_ANY_IMM, dst, dstw, TMP_REG1, 0, src, srcw);
@@ -1868,7 +1934,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
compiler->skip_checks = 1;
#endif
- return sljit_emit_op2(compiler, SLJIT_SUB | GET_FLAGS(op), dst, dstw, SLJIT_IMM, 0, src, srcw);
+ return sljit_emit_op2(compiler, SLJIT_SUB | GET_ALL_FLAGS(op), dst, dstw, SLJIT_IMM, 0, src, srcw);
case SLJIT_CLZ:
return emit_op(compiler, op, 0, dst, dstw, TMP_REG1, 0, src, srcw);
@@ -1877,13 +1943,16 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
CHECK_ERROR();
check_sljit_emit_op2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src1, src1w);
+ ADJUST_LOCAL_OFFSET(src2, src2w);
switch (GET_OPCODE(op)) {
case SLJIT_ADD:
@@ -1916,14 +1985,14 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_get_register_index(int reg)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg)
{
check_sljit_get_register_index(reg);
return reg_map[reg];
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compiler,
- void *instruction, int size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler,
+ void *instruction, sljit_si size)
{
CHECK_ERROR();
check_sljit_emit_op_custom(compiler, instruction, size);
@@ -1940,9 +2009,9 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compile
/* 0 - no fpu
1 - vfp */
-static int arm_fpu_type = -1;
+static sljit_si arm_fpu_type = -1;
-static void init_compiler()
+static void init_compiler(void)
{
if (arm_fpu_type != -1)
return;
@@ -1951,7 +2020,7 @@ static void init_compiler()
arm_fpu_type = 1;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fpu_available(void)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_is_fpu_available(void)
{
if (arm_fpu_type == -1)
init_compiler();
@@ -1962,7 +2031,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fpu_available(void)
#define arm_fpu_type 1
-SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fpu_available(void)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_is_fpu_available(void)
{
/* Always available. */
return 1;
@@ -1970,56 +2039,61 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fpu_available(void)
#endif
-#define EMIT_FPU_DATA_TRANSFER(add, load, base, freg, offs) \
- (VSTR | ((add) << 23) | ((load) << 20) | (reg_map[base] << 16) | (freg << 12) | (offs))
-#define EMIT_FPU_OPERATION(opcode, dst, src1, src2) \
- ((opcode) | ((dst) << 12) | (src1) | ((src2) << 16))
+#define FPU_LOAD (1 << 20)
+#define EMIT_FPU_DATA_TRANSFER(inst, add, base, freg, offs) \
+ ((inst) | ((add) << 23) | (reg_map[base] << 16) | (freg << 12) | (offs))
+#define EMIT_FPU_OPERATION(opcode, mode, dst, src1, src2) \
+ ((opcode) | (mode) | ((dst) << 12) | (src1) | ((src2) << 16))
-static int emit_fpu_data_transfer(struct sljit_compiler *compiler, int fpu_reg, int load, int arg, sljit_w argw)
+static sljit_si emit_fop_mem(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg, sljit_sw argw)
{
+ sljit_sw tmp;
+ sljit_uw imm;
+ sljit_sw inst = VSTR_F32 | (flags & (SLJIT_SINGLE_OP | FPU_LOAD));
SLJIT_ASSERT(arg & SLJIT_MEM);
- /* Fast loads and stores. */
- if ((arg & 0xf) && !(arg & 0xf0) && (argw & 0x3) == 0) {
- if (argw >= 0 && argw <= 0x3ff) {
- EMIT_INSTRUCTION(EMIT_FPU_DATA_TRANSFER(1, load, arg & 0xf, fpu_reg, argw >> 2));
- return SLJIT_SUCCESS;
- }
- if (argw < 0 && argw >= -0x3ff) {
- EMIT_INSTRUCTION(EMIT_FPU_DATA_TRANSFER(0, load, arg & 0xf, fpu_reg, (-argw) >> 2));
- return SLJIT_SUCCESS;
- }
- if (argw >= 0 && argw <= 0x3ffff) {
- SLJIT_ASSERT(get_immediate(argw & 0x3fc00));
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(ADD_DP, 0, TMP_REG1, arg & 0xf, get_immediate(argw & 0x3fc00)));
- argw &= 0x3ff;
- EMIT_INSTRUCTION(EMIT_FPU_DATA_TRANSFER(1, load, TMP_REG1, fpu_reg, argw >> 2));
- return SLJIT_SUCCESS;
- }
- if (argw < 0 && argw >= -0x3ffff) {
- argw = -argw;
- SLJIT_ASSERT(get_immediate(argw & 0x3fc00));
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(SUB_DP, 0, TMP_REG1, arg & 0xf, get_immediate(argw & 0x3fc00)));
- argw &= 0x3ff;
- EMIT_INSTRUCTION(EMIT_FPU_DATA_TRANSFER(0, load, TMP_REG1, fpu_reg, argw >> 2));
- return SLJIT_SUCCESS;
- }
+ if (SLJIT_UNLIKELY(arg & 0xf0)) {
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(ADD_DP, 0, TMP_REG1, arg & 0xf, RM((arg >> 4) & 0xf) | ((argw & 0x3) << 7)));
+ arg = SLJIT_MEM | TMP_REG1;
+ argw = 0;
}
- if (arg & 0xf0) {
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(ADD_DP, 0, TMP_REG1, arg & 0xf, RM((arg >> 4) & 0xf) | ((argw & 0x3) << 7)));
- EMIT_INSTRUCTION(EMIT_FPU_DATA_TRANSFER(1, load, TMP_REG1, fpu_reg, 0));
- return SLJIT_SUCCESS;
+ /* Fast loads and stores. */
+ if ((arg & 0xf)) {
+ if (!(argw & ~0x3fc))
+ return push_inst(compiler, EMIT_FPU_DATA_TRANSFER(inst, 1, arg & 0xf, reg, argw >> 2));
+ if (!(-argw & ~0x3fc))
+ return push_inst(compiler, EMIT_FPU_DATA_TRANSFER(inst, 0, arg & 0xf, reg, (-argw) >> 2));
+ }
+
+ if (compiler->cache_arg == arg) {
+ tmp = argw - compiler->cache_argw;
+ if (!(tmp & ~0x3fc))
+ return push_inst(compiler, EMIT_FPU_DATA_TRANSFER(inst, 1, TMP_REG3, reg, tmp >> 2));
+ if (!(-tmp & ~0x3fc))
+ return push_inst(compiler, EMIT_FPU_DATA_TRANSFER(inst, 0, TMP_REG3, reg, -tmp >> 2));
+ if (emit_set_delta(compiler, TMP_REG3, TMP_REG3, tmp) != SLJIT_ERR_UNSUPPORTED) {
+ FAIL_IF(compiler->error);
+ compiler->cache_argw = argw;
+ return push_inst(compiler, EMIT_FPU_DATA_TRANSFER(inst, 1, TMP_REG3, reg, 0));
+ }
}
- if (compiler->cache_arg == arg && ((argw - compiler->cache_argw) & 0x3) == 0) {
- if (((sljit_uw)argw - (sljit_uw)compiler->cache_argw) <= 0x3ff) {
- EMIT_INSTRUCTION(EMIT_FPU_DATA_TRANSFER(1, load, TMP_REG3, fpu_reg, (argw - compiler->cache_argw) >> 2));
- return SLJIT_SUCCESS;
+ if (arg & 0xf) {
+ if (emit_set_delta(compiler, TMP_REG1, arg & 0xf, argw) != SLJIT_ERR_UNSUPPORTED) {
+ FAIL_IF(compiler->error);
+ return push_inst(compiler, EMIT_FPU_DATA_TRANSFER(inst, 1, TMP_REG1, reg, 0));
}
- if (((sljit_uw)compiler->cache_argw - (sljit_uw)argw) <= 0x3ff) {
- EMIT_INSTRUCTION(EMIT_FPU_DATA_TRANSFER(0, load, TMP_REG3, fpu_reg, (compiler->cache_argw - argw) >> 2));
- return SLJIT_SUCCESS;
+ imm = get_imm(argw & ~0x3fc);
+ if (imm) {
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(ADD_DP, 0, TMP_REG1, arg & 0xf, imm));
+ return push_inst(compiler, EMIT_FPU_DATA_TRANSFER(inst, 1, TMP_REG1, reg, (argw & 0x3fc) >> 2));
+ }
+ imm = get_imm(-argw & ~0x3fc);
+ if (imm) {
+ argw = -argw;
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(SUB_DP, 0, TMP_REG1, arg & 0xf, imm));
+ return push_inst(compiler, EMIT_FPU_DATA_TRANSFER(inst, 0, TMP_REG1, reg, (argw & 0x3fc) >> 2));
}
}
@@ -2032,153 +2106,154 @@ static int emit_fpu_data_transfer(struct sljit_compiler *compiler, int fpu_reg,
else
FAIL_IF(load_immediate(compiler, TMP_REG3, argw));
- EMIT_INSTRUCTION(EMIT_FPU_DATA_TRANSFER(1, load, TMP_REG3, fpu_reg, 0));
- return SLJIT_SUCCESS;
+ return push_inst(compiler, EMIT_FPU_DATA_TRANSFER(inst, 1, TMP_REG3, reg, 0));
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- int dst_freg;
+ sljit_si dst_fr;
CHECK_ERROR();
check_sljit_emit_fop1(compiler, op, dst, dstw, src, srcw);
+ SLJIT_COMPILE_ASSERT((SLJIT_SINGLE_OP == 0x100), float_transfer_bit_error);
compiler->cache_arg = 0;
compiler->cache_argw = 0;
+ op ^= SLJIT_SINGLE_OP;
- if (GET_OPCODE(op) == SLJIT_FCMP) {
- if (dst > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG1, 1, dst, dstw));
+ if (GET_OPCODE(op) == SLJIT_CMPD) {
+ if (dst > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP) | FPU_LOAD, TMP_FREG1, dst, dstw));
dst = TMP_FREG1;
}
- if (src > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG2, 1, src, srcw));
+ if (src > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP) | FPU_LOAD, TMP_FREG2, src, srcw));
src = TMP_FREG2;
}
- EMIT_INSTRUCTION(VCMP_F64 | (dst << 12) | src);
+ EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VCMP_F32, op & SLJIT_SINGLE_OP, dst, src, 0));
EMIT_INSTRUCTION(VMRS);
return SLJIT_SUCCESS;
}
- dst_freg = (dst > SLJIT_FLOAT_REG4) ? TMP_FREG1 : dst;
+ dst_fr = (dst > SLJIT_FLOAT_REG6) ? TMP_FREG1 : dst;
- if (src > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, dst_freg, 1, src, srcw));
- src = dst_freg;
+ if (src > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP) | FPU_LOAD, dst_fr, src, srcw));
+ src = dst_fr;
}
- switch (op) {
- case SLJIT_FMOV:
- if (src != dst_freg && dst_freg != TMP_FREG1)
- EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VMOV_F64, dst_freg, src, 0));
+ switch (GET_OPCODE(op)) {
+ case SLJIT_MOVD:
+ if (src != dst_fr && dst_fr != TMP_FREG1)
+ EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VMOV_F32, op & SLJIT_SINGLE_OP, dst_fr, src, 0));
break;
- case SLJIT_FNEG:
- EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VNEG_F64, dst_freg, src, 0));
+ case SLJIT_NEGD:
+ EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VNEG_F32, op & SLJIT_SINGLE_OP, dst_fr, src, 0));
break;
- case SLJIT_FABS:
- EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VABS_F64, dst_freg, src, 0));
+ case SLJIT_ABSD:
+ EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VABS_F32, op & SLJIT_SINGLE_OP, dst_fr, src, 0));
break;
}
- if (dst_freg == TMP_FREG1)
- FAIL_IF(emit_fpu_data_transfer(compiler, src, 0, dst, dstw));
+ if (dst_fr == TMP_FREG1) {
+ if (GET_OPCODE(op) == SLJIT_MOVD)
+ dst_fr = src;
+ FAIL_IF(emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP), dst_fr, dst, dstw));
+ }
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- int dst_freg;
+ sljit_si dst_fr;
CHECK_ERROR();
check_sljit_emit_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
compiler->cache_arg = 0;
compiler->cache_argw = 0;
+ op ^= SLJIT_SINGLE_OP;
- dst_freg = (dst > SLJIT_FLOAT_REG4) ? TMP_FREG1 : dst;
+ dst_fr = (dst > SLJIT_FLOAT_REG6) ? TMP_FREG1 : dst;
- if (src2 > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG2, 1, src2, src2w));
+ if (src2 > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP) | FPU_LOAD, TMP_FREG2, src2, src2w));
src2 = TMP_FREG2;
}
- if (src1 > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG1, 1, src1, src1w));
+ if (src1 > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP) | FPU_LOAD, TMP_FREG1, src1, src1w));
src1 = TMP_FREG1;
}
- switch (op) {
- case SLJIT_FADD:
- EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VADD_F64, dst_freg, src2, src1));
+ switch (GET_OPCODE(op)) {
+ case SLJIT_ADDD:
+ EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VADD_F32, op & SLJIT_SINGLE_OP, dst_fr, src2, src1));
break;
- case SLJIT_FSUB:
- EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VSUB_F64, dst_freg, src2, src1));
+ case SLJIT_SUBD:
+ EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VSUB_F32, op & SLJIT_SINGLE_OP, dst_fr, src2, src1));
break;
- case SLJIT_FMUL:
- EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VMUL_F64, dst_freg, src2, src1));
+ case SLJIT_MULD:
+ EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VMUL_F32, op & SLJIT_SINGLE_OP, dst_fr, src2, src1));
break;
- case SLJIT_FDIV:
- EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VDIV_F64, dst_freg, src2, src1));
+ case SLJIT_DIVD:
+ EMIT_INSTRUCTION(EMIT_FPU_OPERATION(VDIV_F32, op & SLJIT_SINGLE_OP, dst_fr, src2, src1));
break;
}
- if (dst_freg == TMP_FREG1)
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG1, 0, dst, dstw));
+ if (dst_fr == TMP_FREG1)
+ FAIL_IF(emit_fop_mem(compiler, (op & SLJIT_SINGLE_OP), TMP_FREG1, dst, dstw));
return SLJIT_SUCCESS;
}
+#undef FPU_LOAD
+#undef EMIT_FPU_DATA_TRANSFER
+#undef EMIT_FPU_OPERATION
+
/* --------------------------------------------------------------------- */
/* Other instructions */
/* --------------------------------------------------------------------- */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_enter(struct sljit_compiler *compiler, int dst, sljit_w dstw, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_enter(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw)
{
- int size;
-
CHECK_ERROR();
- check_sljit_emit_fast_enter(compiler, dst, dstw, args, temporaries, saveds, local_size);
-
- compiler->temporaries = temporaries;
- compiler->saveds = saveds;
+ check_sljit_emit_fast_enter(compiler, dst, dstw);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
- size = (1 + saveds) * sizeof(sljit_uw);
- if (temporaries >= 4)
- size += (temporaries - 3) * sizeof(sljit_uw);
- local_size += size;
- local_size = (local_size + 7) & ~7;
- local_size -= size;
- compiler->local_size = local_size;
+ /* For UNUSED dst. Uncommon, but possible. */
+ if (dst == SLJIT_UNUSED)
+ return SLJIT_SUCCESS;
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS)
+ if (dst <= TMP_REG3)
return push_inst(compiler, EMIT_DATA_PROCESS_INS(MOV_DP, 0, dst, SLJIT_UNUSED, RM(TMP_REG3)));
- else if (dst & SLJIT_MEM) {
- if (getput_arg_fast(compiler, WORD_DATA, TMP_REG3, dst, dstw))
- return compiler->error;
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, TMP_REG2, SLJIT_UNUSED, RM(TMP_REG3)));
- compiler->cache_arg = 0;
- compiler->cache_argw = 0;
- return getput_arg(compiler, WORD_DATA, TMP_REG2, dst, dstw, 0, 0);
- }
- return SLJIT_SUCCESS;
+ /* Memory. */
+ if (getput_arg_fast(compiler, WORD_DATA, TMP_REG3, dst, dstw))
+ return compiler->error;
+ /* TMP_REG3 is used for caching. */
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, TMP_REG2, SLJIT_UNUSED, RM(TMP_REG3)));
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+ return getput_arg(compiler, WORD_DATA, TMP_REG2, dst, dstw, 0, 0);
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compiler, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_return(struct sljit_compiler *compiler, sljit_si src, sljit_sw srcw)
{
CHECK_ERROR();
check_sljit_emit_fast_return(compiler, src, srcw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
- if (src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_NO_REGISTERS)
+ if (src <= TMP_REG3)
EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, TMP_REG3, SLJIT_UNUSED, RM(src)));
else if (src & SLJIT_MEM) {
if (getput_arg_fast(compiler, WORD_DATA | LOAD_DATA, TMP_REG3, src, srcw))
@@ -2199,7 +2274,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compi
/* Conditional instructions */
/* --------------------------------------------------------------------- */
-static sljit_uw get_cc(int type)
+static sljit_uw get_cc(sljit_si type)
{
switch (type) {
case SLJIT_C_EQUAL:
@@ -2241,11 +2316,11 @@ static sljit_uw get_cc(int type)
return 0xd0000000;
case SLJIT_C_OVERFLOW:
- case SLJIT_C_FLOAT_NAN:
+ case SLJIT_C_FLOAT_UNORDERED:
return 0x60000000;
case SLJIT_C_NOT_OVERFLOW:
- case SLJIT_C_FLOAT_NOT_NAN:
+ case SLJIT_C_FLOAT_ORDERED:
return 0x70000000;
default: /* SLJIT_JUMP */
@@ -2269,7 +2344,7 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_label* sljit_emit_label(struct sljit_compi
return label;
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, int type)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, sljit_si type)
{
struct sljit_jump *jump;
@@ -2310,12 +2385,13 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compile
return jump;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, int type, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_ijump(struct sljit_compiler *compiler, sljit_si type, sljit_si src, sljit_sw srcw)
{
struct sljit_jump *jump;
CHECK_ERROR();
check_sljit_emit_ijump(compiler, type, src, srcw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
/* In ARM, we don't need to touch the arguments. */
if (src & SLJIT_IMM) {
@@ -2337,67 +2413,83 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, i
jump->addr = compiler->size;
}
else {
- if (src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_NO_REGISTERS)
+ if (src <= TMP_REG3)
return push_inst(compiler, (type <= SLJIT_JUMP ? BX : BLX) | RM(src));
SLJIT_ASSERT(src & SLJIT_MEM);
- FAIL_IF(emit_op(compiler, SLJIT_MOV, ALLOW_ANY_IMM, TMP_REG2, 0, TMP_REG1, 0, src, srcw));
+ FAIL_IF(emit_op_mem(compiler, WORD_DATA | LOAD_DATA, TMP_REG2, src, srcw));
return push_inst(compiler, (type <= SLJIT_JUMP ? BX : BLX) | RM(TMP_REG2));
}
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_cond_value(struct sljit_compiler *compiler, int op, int dst, sljit_w dstw, int type)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_flags(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw,
+ sljit_si type)
{
- int reg;
- sljit_uw cc;
+ sljit_si dst_r, flags = GET_ALL_FLAGS(op);
+ sljit_uw cc, ins;
CHECK_ERROR();
- check_sljit_emit_cond_value(compiler, op, dst, dstw, type);
+ check_sljit_emit_op_flags(compiler, op, dst, dstw, src, srcw, type);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
if (dst == SLJIT_UNUSED)
return SLJIT_SUCCESS;
+ op = GET_OPCODE(op);
cc = get_cc(type);
- if (GET_OPCODE(op) == SLJIT_OR) {
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) {
- EMIT_INSTRUCTION((EMIT_DATA_PROCESS_INS(ORR_DP, 0, dst, dst, SRC2_IMM | 1) & ~COND_MASK) | cc);
- if (op & SLJIT_SET_E)
- return push_inst(compiler, EMIT_DATA_PROCESS_INS(MOV_DP, SET_FLAGS, TMP_REG1, SLJIT_UNUSED, RM(dst)));
- return SLJIT_SUCCESS;
- }
+ dst_r = (dst <= TMP_REG3) ? dst : TMP_REG2;
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, TMP_REG1, SLJIT_UNUSED, SRC2_IMM | 0));
- EMIT_INSTRUCTION((EMIT_DATA_PROCESS_INS(MOV_DP, 0, TMP_REG1, SLJIT_UNUSED, SRC2_IMM | 1) & ~COND_MASK) | cc);
-#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
- compiler->skip_checks = 1;
-#endif
- return emit_op(compiler, op, ALLOW_IMM, dst, dstw, TMP_REG1, 0, dst, dstw);
+ if (op < SLJIT_ADD) {
+ EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, dst_r, SLJIT_UNUSED, SRC2_IMM | 0));
+ EMIT_INSTRUCTION((EMIT_DATA_PROCESS_INS(MOV_DP, 0, dst_r, SLJIT_UNUSED, SRC2_IMM | 1) & ~COND_MASK) | cc);
+ return (dst_r == TMP_REG2) ? emit_op_mem(compiler, WORD_DATA, TMP_REG2, dst, dstw) : SLJIT_SUCCESS;
}
- reg = (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REG2;
-
- EMIT_INSTRUCTION(EMIT_DATA_PROCESS_INS(MOV_DP, 0, reg, SLJIT_UNUSED, SRC2_IMM | 0));
- EMIT_INSTRUCTION((EMIT_DATA_PROCESS_INS(MOV_DP, 0, reg, SLJIT_UNUSED, SRC2_IMM | 1) & ~COND_MASK) | cc);
+ ins = (op == SLJIT_AND ? AND_DP : (op == SLJIT_OR ? ORR_DP : EOR_DP));
+ if ((op == SLJIT_OR || op == SLJIT_XOR) && dst <= TMP_REG3 && dst == src) {
+ EMIT_INSTRUCTION((EMIT_DATA_PROCESS_INS(ins, 0, dst, dst, SRC2_IMM | 1) & ~COND_MASK) | cc);
+ /* The condition must always be set, even if the ORR/EOR is not executed above. */
+ return (flags & SLJIT_SET_E) ? push_inst(compiler, EMIT_DATA_PROCESS_INS(MOV_DP, SET_FLAGS, TMP_REG1, SLJIT_UNUSED, RM(dst))) : SLJIT_SUCCESS;
+ }
- if (reg == TMP_REG2)
- return emit_op(compiler, SLJIT_MOV, ALLOW_ANY_IMM, dst, dstw, TMP_REG1, 0, TMP_REG2, 0);
- return SLJIT_SUCCESS;
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+ if (src & SLJIT_MEM) {
+ FAIL_IF(emit_op_mem2(compiler, WORD_DATA | LOAD_DATA, TMP_REG1, src, srcw, dst, dstw));
+ src = TMP_REG1;
+ srcw = 0;
+ } else if (src & SLJIT_IMM) {
+ FAIL_IF(load_immediate(compiler, TMP_REG1, srcw));
+ src = TMP_REG1;
+ srcw = 0;
+ }
+
+ EMIT_INSTRUCTION((EMIT_DATA_PROCESS_INS(ins, 0, dst_r, src, SRC2_IMM | 1) & ~COND_MASK) | cc);
+ EMIT_INSTRUCTION((EMIT_DATA_PROCESS_INS(ins, 0, dst_r, src, SRC2_IMM | 0) & ~COND_MASK) | (cc ^ 0x10000000));
+ if (dst_r == TMP_REG2)
+ FAIL_IF(emit_op_mem2(compiler, WORD_DATA, TMP_REG2, dst, dstw, 0, 0));
+
+ return (flags & SLJIT_SET_E) ? push_inst(compiler, EMIT_DATA_PROCESS_INS(MOV_DP, SET_FLAGS, TMP_REG1, SLJIT_UNUSED, RM(dst_r))) : SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, int dst, sljit_w dstw, sljit_w init_value)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw init_value)
{
struct sljit_const *const_;
- int reg;
+ sljit_si reg;
CHECK_ERROR_PTR();
check_sljit_emit_const(compiler, dst, dstw, init_value);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
const_ = (struct sljit_const*)ensure_abuf(compiler, sizeof(struct sljit_const));
PTR_FAIL_IF(!const_);
- reg = (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REG2;
+ reg = (dst <= TMP_REG3) ? dst : TMP_REG2;
#if (defined SLJIT_CONFIG_ARM_V5 && SLJIT_CONFIG_ARM_V5)
PTR_FAIL_IF(push_inst_with_unique_literal(compiler, EMIT_DATA_TRANSFER(WORD_DATA | LOAD_DATA, 1, 0, reg, TMP_PC, 0), init_value));
@@ -2408,8 +2500,7 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compi
set_const(const_, compiler);
if (reg == TMP_REG2 && dst != SLJIT_UNUSED)
- if (emit_op(compiler, SLJIT_MOV, ALLOW_ANY_IMM, dst, dstw, TMP_REG1, 0, TMP_REG2, 0))
- return NULL;
+ PTR_FAIL_IF(emit_op_mem(compiler, WORD_DATA, TMP_REG2, dst, dstw));
return const_;
}
@@ -2418,7 +2509,7 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_set_jump_addr(sljit_uw addr, sljit_uw new_ad
inline_set_jump_addr(addr, new_addr, 1);
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_w new_constant)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_sw new_constant)
{
inline_set_const(addr, new_constant, 1);
}
diff --git a/src/3rdparty/pcre/sljit/sljitNativeMIPS_32.c b/src/3rdparty/pcre/sljit/sljitNativeMIPS_32.c
index c0cc8b58bb..f8c214863d 100644
--- a/src/3rdparty/pcre/sljit/sljitNativeMIPS_32.c
+++ b/src/3rdparty/pcre/sljit/sljitNativeMIPS_32.c
@@ -26,7 +26,7 @@
/* mips 32-bit arch dependent functions. */
-static int load_immediate(struct sljit_compiler *compiler, int dst_ar, sljit_w imm)
+static sljit_si load_immediate(struct sljit_compiler *compiler, sljit_si dst_ar, sljit_sw imm)
{
if (!(imm & ~0xffff))
return push_inst(compiler, ORI | SA(0) | TA(dst_ar) | IMM(imm), dst_ar);
@@ -66,12 +66,92 @@ static int load_immediate(struct sljit_compiler *compiler, int dst_ar, sljit_w i
FAIL_IF(push_inst(compiler, op_norm | S(src2) | T(src1) | D(dst), DR(dst))); \
}
-static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op, int flags,
- int dst, int src1, sljit_w src2)
+static SLJIT_INLINE sljit_si emit_single_op(struct sljit_compiler *compiler, sljit_si op, sljit_si flags,
+ sljit_si dst, sljit_si src1, sljit_sw src2)
{
- int overflow_ra = 0;
+ sljit_si overflow_ra = 0;
switch (GET_OPCODE(op)) {
+ case SLJIT_MOV:
+ case SLJIT_MOV_UI:
+ case SLJIT_MOV_SI:
+ case SLJIT_MOV_P:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & SRC2_IMM));
+ if (dst != src2)
+ return push_inst(compiler, ADDU | S(src2) | TA(0) | D(dst), DR(dst));
+ return SLJIT_SUCCESS;
+
+ case SLJIT_MOV_UB:
+ case SLJIT_MOV_SB:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & SRC2_IMM));
+ if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
+ if (op == SLJIT_MOV_SB) {
+#if (defined SLJIT_MIPS_32_64 && SLJIT_MIPS_32_64)
+ return push_inst(compiler, SEB | T(src2) | D(dst), DR(dst));
+#else
+ FAIL_IF(push_inst(compiler, SLL | T(src2) | D(dst) | SH_IMM(24), DR(dst)));
+ return push_inst(compiler, SRA | T(dst) | D(dst) | SH_IMM(24), DR(dst));
+#endif
+ }
+ return push_inst(compiler, ANDI | S(src2) | T(dst) | IMM(0xff), DR(dst));
+ }
+ else if (dst != src2)
+ SLJIT_ASSERT_STOP();
+ return SLJIT_SUCCESS;
+
+ case SLJIT_MOV_UH:
+ case SLJIT_MOV_SH:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & SRC2_IMM));
+ if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
+ if (op == SLJIT_MOV_SH) {
+#if (defined SLJIT_MIPS_32_64 && SLJIT_MIPS_32_64)
+ return push_inst(compiler, SEH | T(src2) | D(dst), DR(dst));
+#else
+ FAIL_IF(push_inst(compiler, SLL | T(src2) | D(dst) | SH_IMM(16), DR(dst)));
+ return push_inst(compiler, SRA | T(dst) | D(dst) | SH_IMM(16), DR(dst));
+#endif
+ }
+ return push_inst(compiler, ANDI | S(src2) | T(dst) | IMM(0xffff), DR(dst));
+ }
+ else if (dst != src2)
+ SLJIT_ASSERT_STOP();
+ return SLJIT_SUCCESS;
+
+ case SLJIT_NOT:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & SRC2_IMM));
+ if (op & SLJIT_SET_E)
+ FAIL_IF(push_inst(compiler, NOR | S(src2) | T(src2) | DA(EQUAL_FLAG), EQUAL_FLAG));
+ if (CHECK_FLAGS(SLJIT_SET_E))
+ FAIL_IF(push_inst(compiler, NOR | S(src2) | T(src2) | D(dst), DR(dst)));
+ return SLJIT_SUCCESS;
+
+ case SLJIT_CLZ:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & SRC2_IMM));
+#if (defined SLJIT_MIPS_32_64 && SLJIT_MIPS_32_64)
+ if (op & SLJIT_SET_E)
+ FAIL_IF(push_inst(compiler, CLZ | S(src2) | TA(EQUAL_FLAG) | DA(EQUAL_FLAG), EQUAL_FLAG));
+ if (CHECK_FLAGS(SLJIT_SET_E))
+ FAIL_IF(push_inst(compiler, CLZ | S(src2) | T(dst) | D(dst), DR(dst)));
+#else
+ if (SLJIT_UNLIKELY(flags & UNUSED_DEST)) {
+ FAIL_IF(push_inst(compiler, SRL | T(src2) | DA(EQUAL_FLAG) | SH_IMM(31), EQUAL_FLAG));
+ return push_inst(compiler, XORI | SA(EQUAL_FLAG) | TA(EQUAL_FLAG) | IMM(1), EQUAL_FLAG);
+ }
+ /* Nearly all instructions are unmovable in the following sequence. */
+ FAIL_IF(push_inst(compiler, ADDU_W | S(src2) | TA(0) | D(TMP_REG1), DR(TMP_REG1)));
+ /* Check zero. */
+ FAIL_IF(push_inst(compiler, BEQ | S(TMP_REG1) | TA(0) | IMM(5), UNMOVABLE_INS));
+ FAIL_IF(push_inst(compiler, ORI | SA(0) | T(dst) | IMM(32), UNMOVABLE_INS));
+ FAIL_IF(push_inst(compiler, ADDIU_W | SA(0) | T(dst) | IMM(-1), DR(dst)));
+ /* Loop for searching the highest bit. */
+ FAIL_IF(push_inst(compiler, ADDIU_W | S(dst) | T(dst) | IMM(1), DR(dst)));
+ FAIL_IF(push_inst(compiler, BGEZ | S(TMP_REG1) | IMM(-2), UNMOVABLE_INS));
+ FAIL_IF(push_inst(compiler, SLL | T(TMP_REG1) | D(TMP_REG1) | SH_IMM(1), UNMOVABLE_INS));
+ if (op & SLJIT_SET_E)
+ return push_inst(compiler, ADDU_W | S(dst) | TA(0) | DA(EQUAL_FLAG), EQUAL_FLAG);
+#endif
+ return SLJIT_SUCCESS;
+
case SLJIT_ADD:
if (flags & SRC2_IMM) {
if (op & SLJIT_SET_O) {
@@ -293,97 +373,16 @@ static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op,
case SLJIT_ASHR:
EMIT_SHIFT(SRA, SRAV);
return SLJIT_SUCCESS;
-
- case SLJIT_MOV:
- case SLJIT_MOV_UI:
- case SLJIT_MOV_SI:
- SLJIT_ASSERT(src1 == TMP_REG1);
- if (dst != src2)
- return push_inst(compiler, ADDU | S(src2) | TA(0) | D(dst), DR(dst));
- return SLJIT_SUCCESS;
-
- case SLJIT_MOV_UB:
- case SLJIT_MOV_SB:
- SLJIT_ASSERT(src1 == TMP_REG1);
- if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
- if (op == SLJIT_MOV_SB) {
-#if (defined SLJIT_MIPS_32_64 && SLJIT_MIPS_32_64)
- return push_inst(compiler, SEB | T(src2) | D(dst), DR(dst));
-#else
- FAIL_IF(push_inst(compiler, SLL | T(src2) | D(dst) | SH_IMM(24), DR(dst)));
- return push_inst(compiler, SRA | T(dst) | D(dst) | SH_IMM(24), DR(dst));
-#endif
- }
- return push_inst(compiler, ANDI | S(src2) | T(dst) | IMM(0xff), DR(dst));
- }
- else if (dst != src2)
- SLJIT_ASSERT_STOP();
- return SLJIT_SUCCESS;
-
- case SLJIT_MOV_UH:
- case SLJIT_MOV_SH:
- SLJIT_ASSERT(src1 == TMP_REG1);
- if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
- if (op == SLJIT_MOV_SH) {
-#if (defined SLJIT_MIPS_32_64 && SLJIT_MIPS_32_64)
- return push_inst(compiler, SEH | T(src2) | D(dst), DR(dst));
-#else
- FAIL_IF(push_inst(compiler, SLL | T(src2) | D(dst) | SH_IMM(16), DR(dst)));
- return push_inst(compiler, SRA | T(dst) | D(dst) | SH_IMM(16), DR(dst));
-#endif
- }
- return push_inst(compiler, ANDI | S(src2) | T(dst) | IMM(0xffff), DR(dst));
- }
- else if (dst != src2)
- SLJIT_ASSERT_STOP();
- return SLJIT_SUCCESS;
-
- case SLJIT_NOT:
- SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & SRC2_IMM));
- if (op & SLJIT_SET_E)
- FAIL_IF(push_inst(compiler, NOR | S(src2) | T(src2) | DA(EQUAL_FLAG), EQUAL_FLAG));
- if (CHECK_FLAGS(SLJIT_SET_E))
- FAIL_IF(push_inst(compiler, NOR | S(src2) | T(src2) | D(dst), DR(dst)));
- return SLJIT_SUCCESS;
-
- case SLJIT_CLZ:
- SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & SRC2_IMM));
-#if (defined SLJIT_MIPS_32_64 && SLJIT_MIPS_32_64)
- if (op & SLJIT_SET_E)
- FAIL_IF(push_inst(compiler, CLZ | S(src2) | TA(EQUAL_FLAG) | DA(EQUAL_FLAG), EQUAL_FLAG));
- if (CHECK_FLAGS(SLJIT_SET_E))
- FAIL_IF(push_inst(compiler, CLZ | S(src2) | T(dst) | D(dst), DR(dst)));
-#else
- if (SLJIT_UNLIKELY(flags & UNUSED_DEST)) {
- FAIL_IF(push_inst(compiler, SRL | T(src2) | DA(EQUAL_FLAG) | SH_IMM(31), EQUAL_FLAG));
- return push_inst(compiler, XORI | SA(EQUAL_FLAG) | TA(EQUAL_FLAG) | IMM(1), EQUAL_FLAG);
- }
- /* Nearly all instructions are unmovable in the following sequence. */
- FAIL_IF(push_inst(compiler, ADDU_W | S(src2) | TA(0) | D(TMP_REG1), DR(TMP_REG1)));
- /* Check zero. */
- FAIL_IF(push_inst(compiler, BEQ | S(TMP_REG1) | TA(0) | IMM(6), UNMOVABLE_INS));
- FAIL_IF(push_inst(compiler, ORI | SA(0) | T(dst) | IMM(32), UNMOVABLE_INS));
- /* Check sign bit. */
- FAIL_IF(push_inst(compiler, BLTZ | S(TMP_REG1) | IMM(4), UNMOVABLE_INS));
- FAIL_IF(push_inst(compiler, ORI | SA(0) | T(dst) | IMM(0), UNMOVABLE_INS));
- /* Loop for searching the highest bit. */
- FAIL_IF(push_inst(compiler, SLL | T(TMP_REG1) | D(TMP_REG1) | SH_IMM(1), DR(TMP_REG1)));
- FAIL_IF(push_inst(compiler, BGEZ | S(TMP_REG1) | IMM(-2), UNMOVABLE_INS));
- FAIL_IF(push_inst(compiler, ADDIU_W | S(dst) | T(dst) | IMM(1), UNMOVABLE_INS));
- if (op & SLJIT_SET_E)
- return push_inst(compiler, ADDU_W | S(dst) | TA(0) | DA(EQUAL_FLAG), EQUAL_FLAG);
-#endif
- return SLJIT_SUCCESS;
}
SLJIT_ASSERT_STOP();
return SLJIT_SUCCESS;
}
-static SLJIT_INLINE int emit_const(struct sljit_compiler *compiler, int reg, sljit_w init_value)
+static SLJIT_INLINE sljit_si emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw init_value)
{
- FAIL_IF(push_inst(compiler, LUI | T(reg) | IMM(init_value >> 16), DR(reg)));
- return push_inst(compiler, ORI | S(reg) | T(reg) | IMM(init_value), DR(reg));
+ FAIL_IF(push_inst(compiler, LUI | T(dst) | IMM(init_value >> 16), DR(dst)));
+ return push_inst(compiler, ORI | S(dst) | T(dst) | IMM(init_value), DR(dst));
}
SLJIT_API_FUNC_ATTRIBUTE void sljit_set_jump_addr(sljit_uw addr, sljit_uw new_addr)
@@ -395,7 +394,7 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_set_jump_addr(sljit_uw addr, sljit_uw new_ad
SLJIT_CACHE_FLUSH(inst, inst + 2);
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_w new_constant)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_sw new_constant)
{
sljit_ins *inst = (sljit_ins*)addr;
diff --git a/src/3rdparty/pcre/sljit/sljitNativeMIPS_common.c b/src/3rdparty/pcre/sljit/sljitNativeMIPS_common.c
index 3c6ee663e1..9559ec32de 100644
--- a/src/3rdparty/pcre/sljit/sljitNativeMIPS_common.c
+++ b/src/3rdparty/pcre/sljit/sljitNativeMIPS_common.c
@@ -24,14 +24,18 @@
* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name()
+/* Latest MIPS architecture. */
+/* Automatically detect SLJIT_MIPS_32_64 */
+
+SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name(void)
{
+#if (defined SLJIT_MIPS_32_64 && SLJIT_MIPS_32_64)
return "MIPS" SLJIT_CPUINFO;
+#else
+ return "MIPS III" SLJIT_CPUINFO;
+#endif
}
-/* Latest MIPS architecture. */
-/* Detect SLJIT_MIPS_32_64 */
-
/* Length of an instruction word
Both for mips-32 and mips-64 */
typedef sljit_ui sljit_ins;
@@ -39,18 +43,17 @@ typedef sljit_ui sljit_ins;
#define TMP_REG1 (SLJIT_NO_REGISTERS + 1)
#define TMP_REG2 (SLJIT_NO_REGISTERS + 2)
#define TMP_REG3 (SLJIT_NO_REGISTERS + 3)
-#define REAL_STACK_PTR (SLJIT_NO_REGISTERS + 4)
/* For position independent code, t9 must contain the function address. */
-#define PIC_ADDR_REG TMP_REG2
+#define PIC_ADDR_REG TMP_REG2
/* TMP_EREG1 is used mainly for literal encoding on 64 bit. */
-#define TMP_EREG1 15
-#define TMP_EREG2 24
+#define TMP_EREG1 15
+#define TMP_EREG2 24
/* Floating point status register. */
-#define FCSR_REG 31
+#define FCSR_REG 31
/* Return address register. */
-#define RETURN_ADDR_REG 31
+#define RETURN_ADDR_REG 31
/* Flags are keept in volatile registers. */
#define EQUAL_FLAG 7
@@ -61,8 +64,12 @@ typedef sljit_ui sljit_ins;
#define GREATER_FLAG 13
#define OVERFLOW_FLAG 14
-#define TMP_FREG1 (SLJIT_FLOAT_REG4 + 1)
-#define TMP_FREG2 (SLJIT_FLOAT_REG4 + 2)
+#define TMP_FREG1 (0)
+#define TMP_FREG2 ((SLJIT_FLOAT_REG6 + 1) << 1)
+
+static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 4] = {
+ 0, 2, 5, 6, 3, 8, 16, 17, 18, 19, 20, 29, 4, 25, 9
+};
/* --------------------------------------------------------------------- */
/* Instrucion forms */
@@ -75,19 +82,20 @@ typedef sljit_ui sljit_ins;
#define SA(s) ((s) << 21)
#define TA(t) ((t) << 16)
#define DA(d) ((d) << 11)
-#define FT(t) ((t) << (16 + 1))
-#define FS(s) ((s) << (11 + 1))
-#define FD(d) ((d) << (6 + 1))
+#define FT(t) ((t) << 16)
+#define FS(s) ((s) << 11)
+#define FD(d) ((d) << 6)
#define IMM(imm) ((imm) & 0xffff)
#define SH_IMM(imm) ((imm & 0x1f) << 6)
#define DR(dr) (reg_map[dr])
#define HI(opcode) ((opcode) << 26)
#define LO(opcode) (opcode)
-#define FMT_D (17 << 21)
+/* S = (16 << 21) D = (17 << 21) */
+#define FMT_SD (16 << 21)
-#define ABS_D (HI(17) | FMT_D | LO(5))
-#define ADD_D (HI(17) | FMT_D | LO(0))
+#define ABS_fmt (HI(17) | FMT_SD | LO(5))
+#define ADD_fmt (HI(17) | FMT_SD | LO(0))
#define ADDU (HI(0) | LO(33))
#define ADDIU (HI(9))
#define AND (HI(0) | LO(36))
@@ -103,37 +111,35 @@ typedef sljit_ui sljit_ins;
#define BLTZ (HI(1) | (0 << 16))
#define BNE (HI(5))
#define BREAK (HI(0) | LO(13))
-#define C_UN_D (HI(17) | FMT_D | LO(49))
-#define C_UEQ_D (HI(17) | FMT_D | LO(51))
-#define C_ULE_D (HI(17) | FMT_D | LO(55))
-#define C_ULT_D (HI(17) | FMT_D | LO(53))
+#define CFC1 (HI(17) | (2 << 21))
+#define C_UN_fmt (HI(17) | FMT_SD | LO(49))
+#define C_UEQ_fmt (HI(17) | FMT_SD | LO(51))
+#define C_ULE_fmt (HI(17) | FMT_SD | LO(55))
+#define C_ULT_fmt (HI(17) | FMT_SD | LO(53))
#define DIV (HI(0) | LO(26))
#define DIVU (HI(0) | LO(27))
-#define DIV_D (HI(17) | FMT_D | LO(3))
+#define DIV_fmt (HI(17) | FMT_SD | LO(3))
#define J (HI(2))
#define JAL (HI(3))
#define JALR (HI(0) | LO(9))
#define JR (HI(0) | LO(8))
#define LD (HI(55))
-#define LDC1 (HI(53))
#define LUI (HI(15))
#define LW (HI(35))
-#define NEG_D (HI(17) | FMT_D | LO(7))
#define MFHI (HI(0) | LO(16))
#define MFLO (HI(0) | LO(18))
-#define MOV_D (HI(17) | FMT_D | LO(6))
-#define CFC1 (HI(17) | (2 << 21))
+#define MOV_fmt (HI(17) | FMT_SD | LO(6))
#define MOVN (HI(0) | LO(11))
#define MOVZ (HI(0) | LO(10))
-#define MUL_D (HI(17) | FMT_D | LO(2))
+#define MUL_fmt (HI(17) | FMT_SD | LO(2))
#define MULT (HI(0) | LO(24))
#define MULTU (HI(0) | LO(25))
+#define NEG_fmt (HI(17) | FMT_SD | LO(7))
#define NOP (HI(0) | LO(0))
#define NOR (HI(0) | LO(39))
#define OR (HI(0) | LO(37))
#define ORI (HI(13))
#define SD (HI(63))
-#define SDC1 (HI(61))
#define SLT (HI(0) | LO(42))
#define SLTI (HI(10))
#define SLTIU (HI(11))
@@ -144,7 +150,7 @@ typedef sljit_ui sljit_ins;
#define SRLV (HI(0) | LO(6))
#define SRA (HI(0) | LO(3))
#define SRAV (HI(0) | LO(7))
-#define SUB_D (HI(17) | FMT_D | LO(1))
+#define SUB_fmt (HI(17) | FMT_SD | LO(1))
#define SUBU (HI(0) | LO(35))
#define SW (HI(43))
#define XOR (HI(0) | LO(38))
@@ -173,14 +179,12 @@ typedef sljit_ui sljit_ins;
#define SIMM_MIN (-0x8000)
#define UIMM_MAX (0xffff)
-static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 6] = {
- 0, 2, 5, 6, 3, 8, 17, 18, 19, 20, 21, 16, 4, 25, 9, 29
-};
-
/* dest_reg is the absolute name of the register
Useful for reordering instructions in the delay slot. */
-static int push_inst(struct sljit_compiler *compiler, sljit_ins ins, int delay_slot)
+static sljit_si push_inst(struct sljit_compiler *compiler, sljit_ins ins, sljit_si delay_slot)
{
+ SLJIT_ASSERT(delay_slot == MOVABLE_INS || delay_slot >= UNMOVABLE_INS
+ || delay_slot == ((ins >> 11) & 0x1f) || delay_slot == ((ins >> 16) & 0x1f));
sljit_ins *ptr = (sljit_ins*)ensure_buf(compiler, sizeof(sljit_ins));
FAIL_IF(!ptr);
*ptr = ins;
@@ -189,14 +193,14 @@ static int push_inst(struct sljit_compiler *compiler, sljit_ins ins, int delay_s
return SLJIT_SUCCESS;
}
-static SLJIT_INLINE sljit_ins invert_branch(int flags)
+static SLJIT_INLINE sljit_ins invert_branch(sljit_si flags)
{
return (flags & IS_BIT26_COND) ? (1 << 26) : (1 << 16);
}
static SLJIT_INLINE sljit_ins* optimize_jump(struct sljit_jump *jump, sljit_ins *code_ptr, sljit_ins *code)
{
- sljit_w diff;
+ sljit_sw diff;
sljit_uw target_addr;
sljit_ins *inst;
sljit_ins saved_inst;
@@ -216,7 +220,7 @@ static SLJIT_INLINE sljit_ins* optimize_jump(struct sljit_jump *jump, sljit_ins
/* B instructions. */
if (jump->flags & IS_MOVABLE) {
- diff = ((sljit_w)target_addr - (sljit_w)(inst)) >> 2;
+ diff = ((sljit_sw)target_addr - (sljit_sw)(inst)) >> 2;
if (diff <= SIMM_MAX && diff >= SIMM_MIN) {
jump->flags |= PATCH_B;
@@ -234,7 +238,7 @@ static SLJIT_INLINE sljit_ins* optimize_jump(struct sljit_jump *jump, sljit_ins
}
}
- diff = ((sljit_w)target_addr - (sljit_w)(inst + 1)) >> 2;
+ diff = ((sljit_sw)target_addr - (sljit_sw)(inst + 1)) >> 2;
if (diff <= SIMM_MAX && diff >= SIMM_MIN) {
jump->flags |= PATCH_B;
@@ -336,7 +340,7 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
jump->addr = (sljit_uw)(code_ptr - 3);
#else
- jump->addr = (sljit_uw)(code_ptr - 6);
+#error "Implementation required"
#endif
code_ptr = optimize_jump(jump, code_ptr, code);
jump = jump->next;
@@ -362,7 +366,7 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
SLJIT_ASSERT(!label);
SLJIT_ASSERT(!jump);
SLJIT_ASSERT(!const_);
- SLJIT_ASSERT(code_ptr - code <= (int)compiler->size);
+ SLJIT_ASSERT(code_ptr - code <= (sljit_sw)compiler->size);
jump = compiler->jumps;
while (jump) {
@@ -371,8 +375,8 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
buf_ptr = (sljit_ins*)jump->addr;
if (jump->flags & PATCH_B) {
- addr = (sljit_w)(addr - (jump->addr + sizeof(sljit_ins))) >> 2;
- SLJIT_ASSERT((sljit_w)addr <= SIMM_MAX && (sljit_w)addr >= SIMM_MIN);
+ addr = (sljit_sw)(addr - (jump->addr + sizeof(sljit_ins))) >> 2;
+ SLJIT_ASSERT((sljit_sw)addr <= SIMM_MAX && (sljit_sw)addr >= SIMM_MIN);
buf_ptr[0] = (buf_ptr[0] & 0xffff0000) | (addr & 0xffff);
break;
}
@@ -387,10 +391,7 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
buf_ptr[0] = (buf_ptr[0] & 0xffff0000) | ((addr >> 16) & 0xffff);
buf_ptr[1] = (buf_ptr[1] & 0xffff0000) | (addr & 0xffff);
#else
- buf_ptr[0] = (buf_ptr[0] & 0xffff0000) | ((addr >> 48) & 0xffff);
- buf_ptr[1] = (buf_ptr[1] & 0xffff0000) | ((addr >> 32) & 0xffff);
- buf_ptr[3] = (buf_ptr[3] & 0xffff0000) | ((addr >> 16) & 0xffff);
- buf_ptr[4] = (buf_ptr[4] & 0xffff0000) | (addr & 0xffff);
+#error "Implementation required"
#endif
} while (0);
jump = jump->next;
@@ -407,42 +408,44 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
return code;
}
+/* --------------------------------------------------------------------- */
+/* Entry, exit */
+/* --------------------------------------------------------------------- */
+
/* Creates an index in data_transfer_insts array. */
+#define LOAD_DATA 0x01
#define WORD_DATA 0x00
-#define BYTE_DATA 0x01
-#define HALF_DATA 0x02
-#define INT_DATA 0x03
-#define SIGNED_DATA 0x04
-#define LOAD_DATA 0x08
-
-#define MEM_MASK 0x0f
-
-#define WRITE_BACK 0x00010
-#define ARG_TEST 0x00020
-#define CUMULATIVE_OP 0x00040
-#define LOGICAL_OP 0x00080
-#define IMM_OP 0x00100
-#define SRC2_IMM 0x00200
-
-#define UNUSED_DEST 0x00400
-#define REG_DEST 0x00800
-#define REG1_SOURCE 0x01000
-#define REG2_SOURCE 0x02000
-#define SLOW_SRC1 0x04000
-#define SLOW_SRC2 0x08000
-#define SLOW_DEST 0x10000
+#define BYTE_DATA 0x02
+#define HALF_DATA 0x04
+#define INT_DATA 0x06
+#define SIGNED_DATA 0x08
+/* Separates integer and floating point registers */
+#define GPR_REG 0x0f
+#define DOUBLE_DATA 0x10
+
+#define MEM_MASK 0x1f
+
+#define WRITE_BACK 0x00020
+#define ARG_TEST 0x00040
+#define ALT_KEEP_CACHE 0x00080
+#define CUMULATIVE_OP 0x00100
+#define LOGICAL_OP 0x00200
+#define IMM_OP 0x00400
+#define SRC2_IMM 0x00800
+
+#define UNUSED_DEST 0x01000
+#define REG_DEST 0x02000
+#define REG1_SOURCE 0x04000
+#define REG2_SOURCE 0x08000
+#define SLOW_SRC1 0x10000
+#define SLOW_SRC2 0x20000
+#define SLOW_DEST 0x40000
/* Only these flags are set. UNUSED_DEST is not set when no flags should be set. */
#define CHECK_FLAGS(list) \
(!(flags & UNUSED_DEST) || (op & GET_FLAGS(~(list))))
#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
-#include "sljitNativeMIPS_32.c"
-#else
-#include "sljitNativeMIPS_64.c"
-#endif
-
-#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
#define STACK_STORE SW
#define STACK_LOAD LW
#else
@@ -450,55 +453,53 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
#define STACK_LOAD LD
#endif
-static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w);
+#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
+#include "sljitNativeMIPS_32.c"
+#else
+#include "sljitNativeMIPS_64.c"
+#endif
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_enter(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
sljit_ins base;
CHECK_ERROR();
- check_sljit_emit_enter(compiler, args, temporaries, saveds, local_size);
+ check_sljit_emit_enter(compiler, args, scratches, saveds, local_size);
- compiler->temporaries = temporaries;
+ compiler->scratches = scratches;
compiler->saveds = saveds;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
- compiler->has_locals = local_size > 0;
- local_size += (saveds + 2 + 4) * sizeof(sljit_w);
+ local_size += (saveds + 1 + 4) * sizeof(sljit_sw);
local_size = (local_size + 15) & ~0xf;
compiler->local_size = local_size;
if (local_size <= SIMM_MAX) {
/* Frequent case. */
- FAIL_IF(push_inst(compiler, ADDIU_W | S(REAL_STACK_PTR) | T(REAL_STACK_PTR) | IMM(-local_size), DR(REAL_STACK_PTR)));
- base = S(REAL_STACK_PTR);
+ FAIL_IF(push_inst(compiler, ADDIU_W | S(SLJIT_LOCALS_REG) | T(SLJIT_LOCALS_REG) | IMM(-local_size), DR(SLJIT_LOCALS_REG)));
+ base = S(SLJIT_LOCALS_REG);
}
else {
FAIL_IF(load_immediate(compiler, DR(TMP_REG1), local_size));
- FAIL_IF(push_inst(compiler, ADDU_W | S(REAL_STACK_PTR) | TA(0) | D(TMP_REG2), DR(TMP_REG2)));
- FAIL_IF(push_inst(compiler, SUBU_W | S(REAL_STACK_PTR) | T(TMP_REG1) | D(REAL_STACK_PTR), DR(REAL_STACK_PTR)));
+ FAIL_IF(push_inst(compiler, ADDU_W | S(SLJIT_LOCALS_REG) | TA(0) | D(TMP_REG2), DR(TMP_REG2)));
+ FAIL_IF(push_inst(compiler, SUBU_W | S(SLJIT_LOCALS_REG) | T(TMP_REG1) | D(SLJIT_LOCALS_REG), DR(SLJIT_LOCALS_REG)));
base = S(TMP_REG2);
local_size = 0;
}
- FAIL_IF(push_inst(compiler, STACK_STORE | base | TA(RETURN_ADDR_REG) | IMM(local_size - 1 * (int)sizeof(sljit_w)), MOVABLE_INS));
- if (compiler->has_locals)
- FAIL_IF(push_inst(compiler, STACK_STORE | base | T(SLJIT_LOCALS_REG) | IMM(local_size - 2 * (int)sizeof(sljit_w)), MOVABLE_INS));
+ FAIL_IF(push_inst(compiler, STACK_STORE | base | TA(RETURN_ADDR_REG) | IMM(local_size - 1 * (sljit_si)sizeof(sljit_sw)), MOVABLE_INS));
if (saveds >= 1)
- FAIL_IF(push_inst(compiler, STACK_STORE | base | T(SLJIT_SAVED_REG1) | IMM(local_size - 3 * (int)sizeof(sljit_w)), MOVABLE_INS));
+ FAIL_IF(push_inst(compiler, STACK_STORE | base | T(SLJIT_SAVED_REG1) | IMM(local_size - 2 * (sljit_si)sizeof(sljit_sw)), MOVABLE_INS));
if (saveds >= 2)
- FAIL_IF(push_inst(compiler, STACK_STORE | base | T(SLJIT_SAVED_REG2) | IMM(local_size - 4 * (int)sizeof(sljit_w)), MOVABLE_INS));
+ FAIL_IF(push_inst(compiler, STACK_STORE | base | T(SLJIT_SAVED_REG2) | IMM(local_size - 3 * (sljit_si)sizeof(sljit_sw)), MOVABLE_INS));
if (saveds >= 3)
- FAIL_IF(push_inst(compiler, STACK_STORE | base | T(SLJIT_SAVED_REG3) | IMM(local_size - 5 * (int)sizeof(sljit_w)), MOVABLE_INS));
+ FAIL_IF(push_inst(compiler, STACK_STORE | base | T(SLJIT_SAVED_REG3) | IMM(local_size - 4 * (sljit_si)sizeof(sljit_sw)), MOVABLE_INS));
if (saveds >= 4)
- FAIL_IF(push_inst(compiler, STACK_STORE | base | T(SLJIT_SAVED_EREG1) | IMM(local_size - 6 * (int)sizeof(sljit_w)), MOVABLE_INS));
+ FAIL_IF(push_inst(compiler, STACK_STORE | base | T(SLJIT_SAVED_EREG1) | IMM(local_size - 5 * (sljit_si)sizeof(sljit_sw)), MOVABLE_INS));
if (saveds >= 5)
- FAIL_IF(push_inst(compiler, STACK_STORE | base | T(SLJIT_SAVED_EREG2) | IMM(local_size - 7 * (int)sizeof(sljit_w)), MOVABLE_INS));
-
- if (compiler->has_locals)
- FAIL_IF(push_inst(compiler, ADDIU_W | S(REAL_STACK_PTR) | T(SLJIT_LOCALS_REG) | IMM(4 * sizeof(sljit_w)), DR(SLJIT_LOCALS_REG)));
+ FAIL_IF(push_inst(compiler, STACK_STORE | base | T(SLJIT_SAVED_EREG2) | IMM(local_size - 6 * (sljit_si)sizeof(sljit_sw)), MOVABLE_INS));
if (args >= 1)
FAIL_IF(push_inst(compiler, ADDU_W | SA(4) | TA(0) | D(SLJIT_SAVED_REG1), DR(SLJIT_SAVED_REG1)));
@@ -510,22 +511,24 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, i
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
CHECK_ERROR_VOID();
- check_sljit_set_context(compiler, args, temporaries, saveds, local_size);
+ check_sljit_set_context(compiler, args, scratches, saveds, local_size);
- compiler->temporaries = temporaries;
+ compiler->scratches = scratches;
compiler->saveds = saveds;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
- compiler->has_locals = local_size > 0;
- local_size += (saveds + 2 + 4) * sizeof(sljit_w);
+ local_size += (saveds + 1 + 4) * sizeof(sljit_sw);
compiler->local_size = (local_size + 15) & ~0xf;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler, int op, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_return(struct sljit_compiler *compiler, sljit_si op, sljit_si src, sljit_sw srcw)
{
- int local_size;
+ sljit_si local_size;
sljit_ins base;
CHECK_ERROR();
@@ -535,33 +538,31 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
local_size = compiler->local_size;
if (local_size <= SIMM_MAX)
- base = S(REAL_STACK_PTR);
+ base = S(SLJIT_LOCALS_REG);
else {
FAIL_IF(load_immediate(compiler, DR(TMP_REG1), local_size));
- FAIL_IF(push_inst(compiler, ADDU_W | S(REAL_STACK_PTR) | T(TMP_REG1) | D(TMP_REG1), DR(TMP_REG1)));
+ FAIL_IF(push_inst(compiler, ADDU_W | S(SLJIT_LOCALS_REG) | T(TMP_REG1) | D(TMP_REG1), DR(TMP_REG1)));
base = S(TMP_REG1);
local_size = 0;
}
- FAIL_IF(push_inst(compiler, STACK_LOAD | base | TA(RETURN_ADDR_REG) | IMM(local_size - 1 * (int)sizeof(sljit_w)), RETURN_ADDR_REG));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | base | TA(RETURN_ADDR_REG) | IMM(local_size - 1 * (sljit_si)sizeof(sljit_sw)), RETURN_ADDR_REG));
if (compiler->saveds >= 5)
- FAIL_IF(push_inst(compiler, STACK_LOAD | base | T(SLJIT_SAVED_EREG2) | IMM(local_size - 7 * (int)sizeof(sljit_w)), DR(SLJIT_SAVED_EREG2)));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | base | T(SLJIT_SAVED_EREG2) | IMM(local_size - 6 * (sljit_si)sizeof(sljit_sw)), DR(SLJIT_SAVED_EREG2)));
if (compiler->saveds >= 4)
- FAIL_IF(push_inst(compiler, STACK_LOAD | base | T(SLJIT_SAVED_EREG1) | IMM(local_size - 6 * (int)sizeof(sljit_w)), DR(SLJIT_SAVED_EREG1)));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | base | T(SLJIT_SAVED_EREG1) | IMM(local_size - 5 * (sljit_si)sizeof(sljit_sw)), DR(SLJIT_SAVED_EREG1)));
if (compiler->saveds >= 3)
- FAIL_IF(push_inst(compiler, STACK_LOAD | base | T(SLJIT_SAVED_REG3) | IMM(local_size - 5 * (int)sizeof(sljit_w)), DR(SLJIT_SAVED_REG3)));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | base | T(SLJIT_SAVED_REG3) | IMM(local_size - 4 * (sljit_si)sizeof(sljit_sw)), DR(SLJIT_SAVED_REG3)));
if (compiler->saveds >= 2)
- FAIL_IF(push_inst(compiler, STACK_LOAD | base | T(SLJIT_SAVED_REG2) | IMM(local_size - 4 * (int)sizeof(sljit_w)), DR(SLJIT_SAVED_REG2)));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | base | T(SLJIT_SAVED_REG2) | IMM(local_size - 3 * (sljit_si)sizeof(sljit_sw)), DR(SLJIT_SAVED_REG2)));
if (compiler->saveds >= 1)
- FAIL_IF(push_inst(compiler, STACK_LOAD | base | T(SLJIT_SAVED_REG1) | IMM(local_size - 3 * (int)sizeof(sljit_w)), DR(SLJIT_SAVED_REG1)));
- if (compiler->has_locals)
- FAIL_IF(push_inst(compiler, STACK_LOAD | base | T(SLJIT_LOCALS_REG) | IMM(local_size - 2 * (int)sizeof(sljit_w)), DR(SLJIT_LOCALS_REG)));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | base | T(SLJIT_SAVED_REG1) | IMM(local_size - 2 * (sljit_si)sizeof(sljit_sw)), DR(SLJIT_SAVED_REG1)));
FAIL_IF(push_inst(compiler, JR | SA(RETURN_ADDR_REG), UNMOVABLE_INS));
if (compiler->local_size <= SIMM_MAX)
- return push_inst(compiler, ADDIU_W | S(REAL_STACK_PTR) | T(REAL_STACK_PTR) | IMM(compiler->local_size), UNMOVABLE_INS);
+ return push_inst(compiler, ADDIU_W | S(SLJIT_LOCALS_REG) | T(SLJIT_LOCALS_REG) | IMM(compiler->local_size), UNMOVABLE_INS);
else
- return push_inst(compiler, ADDU_W | S(TMP_REG1) | TA(0) | D(REAL_STACK_PTR), UNMOVABLE_INS);
+ return push_inst(compiler, ADDU_W | S(TMP_REG1) | TA(0) | D(SLJIT_LOCALS_REG), UNMOVABLE_INS);
}
#undef STACK_STORE
@@ -572,57 +573,62 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
/* --------------------------------------------------------------------- */
#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
-#define ARCH_DEPEND(a, b) a
+#define ARCH_32_64(a, b) a
#else
-#define ARCH_DEPEND(a, b) b
+#define ARCH_32_64(a, b) b
#endif
-static SLJIT_CONST sljit_ins data_transfer_insts[16] = {
-/* s u w */ ARCH_DEPEND(HI(43) /* sw */, HI(63) /* sd */),
-/* s u b */ HI(40) /* sb */,
-/* s u h */ HI(41) /* sh*/,
-/* s u i */ HI(43) /* sw */,
-
-/* s s w */ ARCH_DEPEND(HI(43) /* sw */, HI(63) /* sd */),
-/* s s b */ HI(40) /* sb */,
-/* s s h */ HI(41) /* sh*/,
-/* s s i */ HI(43) /* sw */,
-
-/* l u w */ ARCH_DEPEND(HI(35) /* lw */, HI(55) /* ld */),
-/* l u b */ HI(36) /* lbu */,
-/* l u h */ HI(37) /* lhu */,
-/* l u i */ ARCH_DEPEND(HI(35) /* lw */, HI(39) /* lwu */),
-
-/* l s w */ ARCH_DEPEND(HI(35) /* lw */, HI(55) /* ld */),
-/* l s b */ HI(32) /* lb */,
-/* l s h */ HI(33) /* lh */,
-/* l s i */ HI(35) /* lw */,
+static SLJIT_CONST sljit_ins data_transfer_insts[16 + 4] = {
+/* u w s */ ARCH_32_64(HI(43) /* sw */, HI(63) /* sd */),
+/* u w l */ ARCH_32_64(HI(35) /* lw */, HI(55) /* ld */),
+/* u b s */ HI(40) /* sb */,
+/* u b l */ HI(36) /* lbu */,
+/* u h s */ HI(41) /* sh */,
+/* u h l */ HI(37) /* lhu */,
+/* u i s */ HI(43) /* sw */,
+/* u i l */ ARCH_32_64(HI(35) /* lw */, HI(39) /* lwu */),
+
+/* s w s */ ARCH_32_64(HI(43) /* sw */, HI(63) /* sd */),
+/* s w l */ ARCH_32_64(HI(35) /* lw */, HI(55) /* ld */),
+/* s b s */ HI(40) /* sb */,
+/* s b l */ HI(32) /* lb */,
+/* s h s */ HI(41) /* sh */,
+/* s h l */ HI(33) /* lh */,
+/* s i s */ HI(43) /* sw */,
+/* s i l */ HI(35) /* lw */,
+
+/* d s */ HI(61) /* sdc1 */,
+/* d l */ HI(53) /* ldc1 */,
+/* s s */ HI(57) /* swc1 */,
+/* s l */ HI(49) /* lwc1 */,
};
+#undef ARCH_32_64
+
/* reg_ar is an absoulute register! */
/* Can perform an operation using at most 1 instruction. */
-static int getput_arg_fast(struct sljit_compiler *compiler, int flags, int reg_ar, int arg, sljit_w argw)
+static sljit_si getput_arg_fast(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg_ar, sljit_si arg, sljit_sw argw)
{
SLJIT_ASSERT(arg & SLJIT_MEM);
- if (!(flags & WRITE_BACK) && !(arg & 0xf0) && argw <= SIMM_MAX && argw >= SIMM_MIN) {
+ if ((!(flags & WRITE_BACK) || !(arg & 0xf)) && !(arg & 0xf0) && argw <= SIMM_MAX && argw >= SIMM_MIN) {
/* Works for both absoulte and relative addresses. */
if (SLJIT_UNLIKELY(flags & ARG_TEST))
return 1;
- FAIL_IF(push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(arg & 0xf) | TA(reg_ar) | IMM(argw), (flags & LOAD_DATA) ? reg_ar : MOVABLE_INS));
+ FAIL_IF(push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(arg & 0xf)
+ | TA(reg_ar) | IMM(argw), ((flags & MEM_MASK) <= GPR_REG && (flags & LOAD_DATA)) ? reg_ar : MOVABLE_INS));
return -1;
}
- return (flags & ARG_TEST) ? SLJIT_SUCCESS : 0;
+ return 0;
}
/* See getput_arg below.
Note: can_cache is called only for binary operators. Those
operators always uses word arguments without write back. */
-static int can_cache(int arg, sljit_w argw, int next_arg, sljit_w next_argw)
+static sljit_si can_cache(sljit_si arg, sljit_sw argw, sljit_si next_arg, sljit_sw next_argw)
{
- if (!(next_arg & SLJIT_MEM))
- return 0;
+ SLJIT_ASSERT((arg & SLJIT_MEM) && (next_arg & SLJIT_MEM));
/* Simple operation except for updates. */
if (arg & 0xf0) {
@@ -634,7 +640,7 @@ static int can_cache(int arg, sljit_w argw, int next_arg, sljit_w next_argw)
}
if (arg == next_arg) {
- if (((sljit_uw)(next_argw - argw) <= SIMM_MAX && (sljit_uw)(next_argw - argw) >= SIMM_MIN))
+ if (((next_argw - argw) <= SIMM_MAX && (next_argw - argw) >= SIMM_MIN))
return 1;
return 0;
}
@@ -643,10 +649,9 @@ static int can_cache(int arg, sljit_w argw, int next_arg, sljit_w next_argw)
}
/* Emit the necessary instructions. See can_cache above. */
-static int getput_arg(struct sljit_compiler *compiler, int flags, int reg_ar, int arg, sljit_w argw, int next_arg, sljit_w next_argw)
+static sljit_si getput_arg(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg_ar, sljit_si arg, sljit_sw argw, sljit_si next_arg, sljit_sw next_argw)
{
- int tmp_ar;
- int base;
+ sljit_si tmp_ar, base, delay_slot;
SLJIT_ASSERT(arg & SLJIT_MEM);
if (!(next_arg & SLJIT_MEM)) {
@@ -654,7 +659,13 @@ static int getput_arg(struct sljit_compiler *compiler, int flags, int reg_ar, in
next_argw = 0;
}
- tmp_ar = (flags & LOAD_DATA) ? reg_ar : DR(TMP_REG3);
+ if ((flags & MEM_MASK) <= GPR_REG && (flags & LOAD_DATA)) {
+ tmp_ar = reg_ar;
+ delay_slot = reg_ar;
+ } else {
+ tmp_ar = DR(TMP_REG1);
+ delay_slot = MOVABLE_INS;
+ }
base = arg & 0xf;
if (SLJIT_UNLIKELY(arg & 0xf0)) {
@@ -669,22 +680,22 @@ static int getput_arg(struct sljit_compiler *compiler, int flags, int reg_ar, in
if (argw == compiler->cache_argw) {
if (!(flags & WRITE_BACK)) {
if (arg == compiler->cache_arg)
- return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(TMP_REG3) | TA(reg_ar), (flags & LOAD_DATA) ? reg_ar : MOVABLE_INS);
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(TMP_REG3) | TA(reg_ar), delay_slot);
if ((SLJIT_MEM | (arg & 0xf0)) == compiler->cache_arg) {
if (arg == next_arg && argw == (next_argw & 0x3)) {
compiler->cache_arg = arg;
compiler->cache_argw = argw;
FAIL_IF(push_inst(compiler, ADDU_W | S(base) | T(TMP_REG3) | D(TMP_REG3), DR(TMP_REG3)));
- return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(TMP_REG3) | TA(reg_ar), (flags & LOAD_DATA) ? reg_ar : MOVABLE_INS);
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(TMP_REG3) | TA(reg_ar), delay_slot);
}
FAIL_IF(push_inst(compiler, ADDU_W | S(base) | T(TMP_REG3) | DA(tmp_ar), tmp_ar));
- return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | SA(tmp_ar) | TA(reg_ar), (flags & LOAD_DATA) ? reg_ar : MOVABLE_INS);
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | SA(tmp_ar) | TA(reg_ar), delay_slot);
}
}
else {
if ((SLJIT_MEM | (arg & 0xf0)) == compiler->cache_arg) {
FAIL_IF(push_inst(compiler, ADDU_W | S(base) | T(TMP_REG3) | D(base), DR(base)));
- return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(base) | TA(reg_ar), (flags & LOAD_DATA) ? reg_ar : MOVABLE_INS);
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(base) | TA(reg_ar), delay_slot);
}
}
}
@@ -704,10 +715,10 @@ static int getput_arg(struct sljit_compiler *compiler, int flags, int reg_ar, in
}
else
FAIL_IF(push_inst(compiler, ADDU_W | S(base) | T(!argw ? ((arg >> 4) & 0xf) : TMP_REG3) | DA(tmp_ar), tmp_ar));
- return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | SA(tmp_ar) | TA(reg_ar), (flags & LOAD_DATA) ? reg_ar : MOVABLE_INS);
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | SA(tmp_ar) | TA(reg_ar), delay_slot);
}
FAIL_IF(push_inst(compiler, ADDU_W | S(base) | T(!argw ? ((arg >> 4) & 0xf) : TMP_REG3) | D(base), DR(base)));
- return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(base) | TA(reg_ar), (flags & LOAD_DATA) ? reg_ar : MOVABLE_INS);
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(base) | TA(reg_ar), delay_slot);
}
if (SLJIT_UNLIKELY(flags & WRITE_BACK) && base) {
@@ -743,7 +754,7 @@ static int getput_arg(struct sljit_compiler *compiler, int flags, int reg_ar, in
FAIL_IF(push_inst(compiler, ADDU_W | S(base) | T(TMP_REG3) | D(base), DR(base)));
}
}
- return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(base) | TA(reg_ar), (flags & LOAD_DATA) ? reg_ar : MOVABLE_INS);
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(base) | TA(reg_ar), delay_slot);
}
if (compiler->cache_arg == arg && argw - compiler->cache_argw <= SIMM_MAX && argw - compiler->cache_argw >= SIMM_MIN) {
@@ -751,7 +762,7 @@ static int getput_arg(struct sljit_compiler *compiler, int flags, int reg_ar, in
FAIL_IF(push_inst(compiler, ADDIU_W | S(TMP_REG3) | T(TMP_REG3) | IMM(argw - compiler->cache_argw), DR(TMP_REG3)));
compiler->cache_argw = argw;
}
- return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(TMP_REG3) | TA(reg_ar), (flags & LOAD_DATA) ? reg_ar : MOVABLE_INS);
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(TMP_REG3) | TA(reg_ar), delay_slot);
}
if (compiler->cache_arg == SLJIT_MEM && argw - compiler->cache_argw <= SIMM_MAX && argw - compiler->cache_argw >= SIMM_MIN) {
@@ -765,19 +776,19 @@ static int getput_arg(struct sljit_compiler *compiler, int flags, int reg_ar, in
compiler->cache_argw = argw;
if (!base)
- return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(TMP_REG3) | TA(reg_ar), (flags & LOAD_DATA) ? reg_ar : MOVABLE_INS);
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(TMP_REG3) | TA(reg_ar), delay_slot);
if (arg == next_arg && next_argw - argw <= SIMM_MAX && next_argw - argw >= SIMM_MIN) {
compiler->cache_arg = arg;
FAIL_IF(push_inst(compiler, ADDU_W | S(TMP_REG3) | T(base) | D(TMP_REG3), DR(TMP_REG3)));
- return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(TMP_REG3) | TA(reg_ar), (flags & LOAD_DATA) ? reg_ar : MOVABLE_INS);
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | S(TMP_REG3) | TA(reg_ar), delay_slot);
}
FAIL_IF(push_inst(compiler, ADDU_W | S(TMP_REG3) | T(base) | DA(tmp_ar), tmp_ar));
- return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | SA(tmp_ar) | TA(reg_ar), (flags & LOAD_DATA) ? reg_ar : MOVABLE_INS);
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | SA(tmp_ar) | TA(reg_ar), delay_slot);
}
-static SLJIT_INLINE int emit_op_mem(struct sljit_compiler *compiler, int flags, int reg_ar, int arg, sljit_w argw)
+static SLJIT_INLINE sljit_si emit_op_mem(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg_ar, sljit_si arg, sljit_sw argw)
{
if (getput_arg_fast(compiler, flags, reg_ar, arg, argw))
return compiler->error;
@@ -786,35 +797,44 @@ static SLJIT_INLINE int emit_op_mem(struct sljit_compiler *compiler, int flags,
return getput_arg(compiler, flags, reg_ar, arg, argw, 0, 0);
}
-static int emit_op(struct sljit_compiler *compiler, int op, int flags,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+static SLJIT_INLINE sljit_si emit_op_mem2(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg1, sljit_sw arg1w, sljit_si arg2, sljit_sw arg2w)
+{
+ if (getput_arg_fast(compiler, flags, reg, arg1, arg1w))
+ return compiler->error;
+ return getput_arg(compiler, flags, reg, arg1, arg1w, arg2, arg2w);
+}
+
+static sljit_si emit_op(struct sljit_compiler *compiler, sljit_si op, sljit_si flags,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
/* arg1 goes to TMP_REG1 or src reg
arg2 goes to TMP_REG2, imm or src reg
TMP_REG3 can be used for caching
result goes to TMP_REG2, so put result can use TMP_REG1 and TMP_REG3. */
- int dst_r = TMP_REG2;
- int src1_r;
- sljit_w src2_r = 0;
- int sugg_src2_r = TMP_REG2;
-
- compiler->cache_arg = 0;
- compiler->cache_argw = 0;
-
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= TMP_REG3) {
- dst_r = dst;
- flags |= REG_DEST;
- if (GET_OPCODE(op) >= SLJIT_MOV && GET_OPCODE(op) <= SLJIT_MOVU_SI)
- sugg_src2_r = dst_r;
+ sljit_si dst_r = TMP_REG2;
+ sljit_si src1_r;
+ sljit_sw src2_r = 0;
+ sljit_si sugg_src2_r = TMP_REG2;
+
+ if (!(flags & ALT_KEEP_CACHE)) {
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
}
- else if (dst == SLJIT_UNUSED) {
+
+ if (SLJIT_UNLIKELY(dst == SLJIT_UNUSED)) {
if (op >= SLJIT_MOV && op <= SLJIT_MOVU_SI && !(src2 & SLJIT_MEM))
return SLJIT_SUCCESS;
if (GET_FLAGS(op))
flags |= UNUSED_DEST;
}
+ else if (dst <= TMP_REG3) {
+ dst_r = dst;
+ flags |= REG_DEST;
+ if (op >= SLJIT_MOV && op <= SLJIT_MOVU_SI)
+ sugg_src2_r = dst_r;
+ }
else if ((dst & SLJIT_MEM) && !getput_arg_fast(compiler, flags | ARG_TEST, DR(TMP_REG1), dst, dstw))
flags |= SLOW_DEST;
@@ -826,7 +846,7 @@ static int emit_op(struct sljit_compiler *compiler, int op, int flags,
src2_r = src2w;
}
}
- if ((src1 & SLJIT_IMM) && src1w && (flags & CUMULATIVE_OP) && !(flags & SRC2_IMM)) {
+ if (!(flags & SRC2_IMM) && (flags & CUMULATIVE_OP) && (src1 & SLJIT_IMM) && src1w) {
if ((!(flags & LOGICAL_OP) && (src1w <= SIMM_MAX && src1w >= SIMM_MIN))
|| ((flags & LOGICAL_OP) && !(src1w & ~UIMM_MAX))) {
flags |= SRC2_IMM;
@@ -842,7 +862,7 @@ static int emit_op(struct sljit_compiler *compiler, int op, int flags,
}
/* Source 1. */
- if (src1 >= SLJIT_TEMPORARY_REG1 && src1 <= TMP_REG3) {
+ if (src1 <= TMP_REG3) {
src1_r = src1;
flags |= REG1_SOURCE;
}
@@ -863,20 +883,23 @@ static int emit_op(struct sljit_compiler *compiler, int op, int flags,
}
/* Source 2. */
- if (src2 >= SLJIT_TEMPORARY_REG1 && src2 <= TMP_REG3) {
+ if (src2 <= TMP_REG3) {
src2_r = src2;
flags |= REG2_SOURCE;
- if (!(flags & REG_DEST) && GET_OPCODE(op) >= SLJIT_MOV && GET_OPCODE(op) <= SLJIT_MOVU_SI)
+ if (!(flags & REG_DEST) && op >= SLJIT_MOV && op <= SLJIT_MOVU_SI)
dst_r = src2_r;
}
else if (src2 & SLJIT_IMM) {
if (!(flags & SRC2_IMM)) {
- if (src2w || (GET_OPCODE(op) >= SLJIT_MOV && GET_OPCODE(op) <= SLJIT_MOVU_SI)) {
+ if (src2w) {
FAIL_IF(load_immediate(compiler, DR(sugg_src2_r), src2w));
src2_r = sugg_src2_r;
}
- else
+ else {
src2_r = 0;
+ if ((op >= SLJIT_MOV && op <= SLJIT_MOVU_SI) && (dst & SLJIT_MEM))
+ dst_r = 0;
+ }
}
}
else {
@@ -916,7 +939,7 @@ static int emit_op(struct sljit_compiler *compiler, int op, int flags,
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int op)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op)
{
CHECK_ERROR();
check_sljit_emit_op0(compiler, op);
@@ -929,123 +952,128 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
return push_inst(compiler, NOP, UNMOVABLE_INS);
case SLJIT_UMUL:
case SLJIT_SMUL:
- FAIL_IF(push_inst(compiler, (op == SLJIT_UMUL ? MULTU : MULT) | S(SLJIT_TEMPORARY_REG1) | T(SLJIT_TEMPORARY_REG2), MOVABLE_INS));
- FAIL_IF(push_inst(compiler, MFLO | D(SLJIT_TEMPORARY_REG1), DR(SLJIT_TEMPORARY_REG1)));
- return push_inst(compiler, MFHI | D(SLJIT_TEMPORARY_REG2), DR(SLJIT_TEMPORARY_REG2));
+ FAIL_IF(push_inst(compiler, (op == SLJIT_UMUL ? MULTU : MULT) | S(SLJIT_SCRATCH_REG1) | T(SLJIT_SCRATCH_REG2), MOVABLE_INS));
+ FAIL_IF(push_inst(compiler, MFLO | D(SLJIT_SCRATCH_REG1), DR(SLJIT_SCRATCH_REG1)));
+ return push_inst(compiler, MFHI | D(SLJIT_SCRATCH_REG2), DR(SLJIT_SCRATCH_REG2));
case SLJIT_UDIV:
case SLJIT_SDIV:
#if !(defined SLJIT_MIPS_32_64 && SLJIT_MIPS_32_64)
FAIL_IF(push_inst(compiler, NOP, UNMOVABLE_INS));
FAIL_IF(push_inst(compiler, NOP, UNMOVABLE_INS));
#endif
- FAIL_IF(push_inst(compiler, (op == SLJIT_UDIV ? DIVU : DIV) | S(SLJIT_TEMPORARY_REG1) | T(SLJIT_TEMPORARY_REG2), MOVABLE_INS));
- FAIL_IF(push_inst(compiler, MFLO | D(SLJIT_TEMPORARY_REG1), DR(SLJIT_TEMPORARY_REG1)));
- return push_inst(compiler, MFHI | D(SLJIT_TEMPORARY_REG2), DR(SLJIT_TEMPORARY_REG2));
+ FAIL_IF(push_inst(compiler, (op == SLJIT_UDIV ? DIVU : DIV) | S(SLJIT_SCRATCH_REG1) | T(SLJIT_SCRATCH_REG2), MOVABLE_INS));
+ FAIL_IF(push_inst(compiler, MFLO | D(SLJIT_SCRATCH_REG1), DR(SLJIT_SCRATCH_REG1)));
+ return push_inst(compiler, MFHI | D(SLJIT_SCRATCH_REG2), DR(SLJIT_SCRATCH_REG2));
}
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
- #define inp_flags 0
+# define flags 0
#endif
CHECK_ERROR();
check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw);
-
- SLJIT_COMPILE_ASSERT(SLJIT_MOV + 7 == SLJIT_MOVU, movu_offset);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
switch (GET_OPCODE(op)) {
case SLJIT_MOV:
- return emit_op(compiler, SLJIT_MOV, inp_flags | WORD_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
+ case SLJIT_MOV_P:
+ return emit_op(compiler, SLJIT_MOV, flags | WORD_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
case SLJIT_MOV_UI:
- return emit_op(compiler, SLJIT_MOV_UI, inp_flags | INT_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
+ return emit_op(compiler, SLJIT_MOV_UI, flags | INT_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
case SLJIT_MOV_SI:
- return emit_op(compiler, SLJIT_MOV_SI, inp_flags | INT_DATA | SIGNED_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
+ return emit_op(compiler, SLJIT_MOV_SI, flags | INT_DATA | SIGNED_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
case SLJIT_MOV_UB:
- return emit_op(compiler, SLJIT_MOV_UB, inp_flags | BYTE_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (unsigned char)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_UB, flags | BYTE_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_ub)srcw : srcw);
case SLJIT_MOV_SB:
- return emit_op(compiler, SLJIT_MOV_SB, inp_flags | BYTE_DATA | SIGNED_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (signed char)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_SB, flags | BYTE_DATA | SIGNED_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_sb)srcw : srcw);
case SLJIT_MOV_UH:
- return emit_op(compiler, SLJIT_MOV_UH, inp_flags | HALF_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (unsigned short)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_UH, flags | HALF_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_uh)srcw : srcw);
case SLJIT_MOV_SH:
- return emit_op(compiler, SLJIT_MOV_SH, inp_flags | HALF_DATA | SIGNED_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (signed short)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_SH, flags | HALF_DATA | SIGNED_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_sh)srcw : srcw);
case SLJIT_MOVU:
- return emit_op(compiler, SLJIT_MOV, inp_flags | WORD_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
+ case SLJIT_MOVU_P:
+ return emit_op(compiler, SLJIT_MOV, flags | WORD_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
case SLJIT_MOVU_UI:
- return emit_op(compiler, SLJIT_MOV_UI, inp_flags | INT_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
+ return emit_op(compiler, SLJIT_MOV_UI, flags | INT_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
case SLJIT_MOVU_SI:
- return emit_op(compiler, SLJIT_MOV_SI, inp_flags | INT_DATA | SIGNED_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
+ return emit_op(compiler, SLJIT_MOV_SI, flags | INT_DATA | SIGNED_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
case SLJIT_MOVU_UB:
- return emit_op(compiler, SLJIT_MOV_UB, inp_flags | BYTE_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (unsigned char)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_UB, flags | BYTE_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_ub)srcw : srcw);
case SLJIT_MOVU_SB:
- return emit_op(compiler, SLJIT_MOV_SB, inp_flags | BYTE_DATA | SIGNED_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (signed char)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_SB, flags | BYTE_DATA | SIGNED_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_sb)srcw : srcw);
case SLJIT_MOVU_UH:
- return emit_op(compiler, SLJIT_MOV_UH, inp_flags | HALF_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (unsigned short)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_UH, flags | HALF_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_uh)srcw : srcw);
case SLJIT_MOVU_SH:
- return emit_op(compiler, SLJIT_MOV_SH, inp_flags | HALF_DATA | SIGNED_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (signed short)srcw : srcw);
+ return emit_op(compiler, SLJIT_MOV_SH, flags | HALF_DATA | SIGNED_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_sh)srcw : srcw);
case SLJIT_NOT:
- return emit_op(compiler, op, inp_flags, dst, dstw, TMP_REG1, 0, src, srcw);
+ return emit_op(compiler, op, flags, dst, dstw, TMP_REG1, 0, src, srcw);
case SLJIT_NEG:
- return emit_op(compiler, SLJIT_SUB | GET_ALL_FLAGS(op), inp_flags | IMM_OP, dst, dstw, SLJIT_IMM, 0, src, srcw);
+ return emit_op(compiler, SLJIT_SUB | GET_ALL_FLAGS(op), flags | IMM_OP, dst, dstw, SLJIT_IMM, 0, src, srcw);
case SLJIT_CLZ:
- return emit_op(compiler, op, inp_flags, dst, dstw, TMP_REG1, 0, src, srcw);
+ return emit_op(compiler, op, flags, dst, dstw, TMP_REG1, 0, src, srcw);
}
return SLJIT_SUCCESS;
#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
- #undef inp_flags
+# undef flags
#endif
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
- #define inp_flags 0
+# define flags 0
#endif
CHECK_ERROR();
check_sljit_emit_op2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src1, src1w);
+ ADJUST_LOCAL_OFFSET(src2, src2w);
switch (GET_OPCODE(op)) {
case SLJIT_ADD:
case SLJIT_ADDC:
- return emit_op(compiler, op, inp_flags | CUMULATIVE_OP | IMM_OP, dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, op, flags | CUMULATIVE_OP | IMM_OP, dst, dstw, src1, src1w, src2, src2w);
case SLJIT_SUB:
case SLJIT_SUBC:
- return emit_op(compiler, op, inp_flags | IMM_OP, dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, op, flags | IMM_OP, dst, dstw, src1, src1w, src2, src2w);
case SLJIT_MUL:
- return emit_op(compiler, op, inp_flags | CUMULATIVE_OP, dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, op, flags | CUMULATIVE_OP, dst, dstw, src1, src1w, src2, src2w);
case SLJIT_AND:
case SLJIT_OR:
case SLJIT_XOR:
- return emit_op(compiler, op, inp_flags | CUMULATIVE_OP | LOGICAL_OP | IMM_OP, dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, op, flags | CUMULATIVE_OP | LOGICAL_OP | IMM_OP, dst, dstw, src1, src1w, src2, src2w);
case SLJIT_SHL:
case SLJIT_LSHR:
@@ -1054,26 +1082,25 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int
if (src2 & SLJIT_IMM)
src2w &= 0x1f;
#else
- if (src2 & SLJIT_IMM)
- src2w &= 0x3f;
+ SLJIT_ASSERT_STOP();
#endif
- return emit_op(compiler, op, inp_flags | IMM_OP, dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, op, flags | IMM_OP, dst, dstw, src1, src1w, src2, src2w);
}
return SLJIT_SUCCESS;
#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
- #undef inp_flags
+# undef flags
#endif
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_get_register_index(int reg)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg)
{
check_sljit_get_register_index(reg);
return reg_map[reg];
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compiler,
- void *instruction, int size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler,
+ void *instruction, sljit_si size)
{
CHECK_ERROR();
check_sljit_emit_op_custom(compiler, instruction, size);
@@ -1086,13 +1113,13 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compile
/* Floating point operators */
/* --------------------------------------------------------------------- */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fpu_available(void)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_is_fpu_available(void)
{
#if (defined SLJIT_QEMU && SLJIT_QEMU)
/* Qemu says fir is 0 by default. */
return 1;
#elif defined(__GNUC__)
- sljit_w fir;
+ sljit_sw fir;
asm ("cfc1 %0, $0" : "=r"(fir));
return (fir >> 22) & 0x1;
#else
@@ -1100,119 +1127,95 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fpu_available(void)
#endif
}
-static int emit_fpu_data_transfer(struct sljit_compiler *compiler, int fpu_reg, int load, int arg, sljit_w argw)
-{
- int hi_reg;
+#define FLOAT_DATA(op) (DOUBLE_DATA | ((op & SLJIT_SINGLE_OP) >> 7))
+#define FMT(op) (((op & SLJIT_SINGLE_OP) ^ SLJIT_SINGLE_OP) << (21 - 8))
- SLJIT_ASSERT(arg & SLJIT_MEM);
-
- /* Fast loads and stores. */
- if (!(arg & 0xf0)) {
- /* Both for (arg & 0xf) == SLJIT_UNUSED and (arg & 0xf) != SLJIT_UNUSED. */
- if (argw <= SIMM_MAX && argw >= SIMM_MIN)
- return push_inst(compiler, (load ? LDC1 : SDC1) | S(arg & 0xf) | FT(fpu_reg) | IMM(argw), MOVABLE_INS);
- }
-
- if (arg & 0xf0) {
- argw &= 0x3;
- hi_reg = (arg >> 4) & 0xf;
- if (argw) {
- FAIL_IF(push_inst(compiler, SLL_W | T(hi_reg) | D(TMP_REG1) | SH_IMM(argw), DR(TMP_REG1)));
- hi_reg = TMP_REG1;
- }
- FAIL_IF(push_inst(compiler, ADDU_W | S(hi_reg) | T(arg & 0xf) | D(TMP_REG1), DR(TMP_REG1)));
- return push_inst(compiler, (load ? LDC1 : SDC1) | S(TMP_REG1) | FT(fpu_reg) | IMM(0), MOVABLE_INS);
- }
-
- /* Use cache. */
- if (compiler->cache_arg == arg && argw - compiler->cache_argw <= SIMM_MAX && argw - compiler->cache_argw >= SIMM_MIN)
- return push_inst(compiler, (load ? LDC1 : SDC1) | S(TMP_REG3) | FT(fpu_reg) | IMM(argw - compiler->cache_argw), MOVABLE_INS);
-
- /* Put value to cache. */
- compiler->cache_arg = arg;
- compiler->cache_argw = argw;
-
- FAIL_IF(load_immediate(compiler, DR(TMP_REG3), argw));
- if (arg & 0xf)
- FAIL_IF(push_inst(compiler, ADDU_W | S(TMP_REG3) | T(arg & 0xf) | D(TMP_REG3), DR(TMP_REG3)));
- return push_inst(compiler, (load ? LDC1 : SDC1) | S(TMP_REG3) | FT(fpu_reg) | IMM(0), MOVABLE_INS);
-}
-
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- int dst_fr;
+ sljit_si dst_fr;
CHECK_ERROR();
check_sljit_emit_fop1(compiler, op, dst, dstw, src, srcw);
+ SLJIT_COMPILE_ASSERT((SLJIT_SINGLE_OP == 0x100) && !(DOUBLE_DATA & 0x2), float_transfer_bit_error);
compiler->cache_arg = 0;
compiler->cache_argw = 0;
- if (GET_OPCODE(op) == SLJIT_FCMP) {
- if (dst > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG1, 1, dst, dstw));
+ if (GET_OPCODE(op) == SLJIT_CMPD) {
+ if (dst > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, dst, dstw, src, srcw));
dst = TMP_FREG1;
}
- if (src > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG2, 1, src, srcw));
+ else
+ dst <<= 1;
+
+ if (src > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src, srcw, 0, 0));
src = TMP_FREG2;
}
+ else
+ src <<= 1;
/* src and dst are swapped. */
if (op & SLJIT_SET_E) {
- FAIL_IF(push_inst(compiler, C_UEQ_D | FT(src) | FS(dst), UNMOVABLE_INS));
+ FAIL_IF(push_inst(compiler, C_UEQ_fmt | FMT(op) | FT(src) | FS(dst), UNMOVABLE_INS));
FAIL_IF(push_inst(compiler, CFC1 | TA(EQUAL_FLAG) | DA(FCSR_REG), EQUAL_FLAG));
FAIL_IF(push_inst(compiler, SRL | TA(EQUAL_FLAG) | DA(EQUAL_FLAG) | SH_IMM(23), EQUAL_FLAG));
FAIL_IF(push_inst(compiler, ANDI | SA(EQUAL_FLAG) | TA(EQUAL_FLAG) | IMM(1), EQUAL_FLAG));
}
if (op & SLJIT_SET_S) {
/* Mixing the instructions for the two checks. */
- FAIL_IF(push_inst(compiler, C_ULT_D | FT(src) | FS(dst), UNMOVABLE_INS));
+ FAIL_IF(push_inst(compiler, C_ULT_fmt | FMT(op) | FT(src) | FS(dst), UNMOVABLE_INS));
FAIL_IF(push_inst(compiler, CFC1 | TA(ULESS_FLAG) | DA(FCSR_REG), ULESS_FLAG));
- FAIL_IF(push_inst(compiler, C_ULT_D | FT(dst) | FS(src), UNMOVABLE_INS));
+ FAIL_IF(push_inst(compiler, C_ULT_fmt | FMT(op) | FT(dst) | FS(src), UNMOVABLE_INS));
FAIL_IF(push_inst(compiler, SRL | TA(ULESS_FLAG) | DA(ULESS_FLAG) | SH_IMM(23), ULESS_FLAG));
FAIL_IF(push_inst(compiler, ANDI | SA(ULESS_FLAG) | TA(ULESS_FLAG) | IMM(1), ULESS_FLAG));
FAIL_IF(push_inst(compiler, CFC1 | TA(UGREATER_FLAG) | DA(FCSR_REG), UGREATER_FLAG));
FAIL_IF(push_inst(compiler, SRL | TA(UGREATER_FLAG) | DA(UGREATER_FLAG) | SH_IMM(23), UGREATER_FLAG));
FAIL_IF(push_inst(compiler, ANDI | SA(UGREATER_FLAG) | TA(UGREATER_FLAG) | IMM(1), UGREATER_FLAG));
}
- return push_inst(compiler, C_UN_D | FT(src) | FS(dst), FCSR_FCC);
+ return push_inst(compiler, C_UN_fmt | FMT(op) | FT(src) | FS(dst), FCSR_FCC);
}
- dst_fr = (dst > SLJIT_FLOAT_REG4) ? TMP_FREG1 : dst;
+ dst_fr = (dst > SLJIT_FLOAT_REG6) ? TMP_FREG1 : (dst << 1);
- if (src > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, dst_fr, 1, src, srcw));
+ if (src > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, dst_fr, src, srcw, dst, dstw));
src = dst_fr;
}
+ else
+ src <<= 1;
- switch (op) {
- case SLJIT_FMOV:
+ switch (GET_OPCODE(op)) {
+ case SLJIT_MOVD:
if (src != dst_fr && dst_fr != TMP_FREG1)
- FAIL_IF(push_inst(compiler, MOV_D | FS(src) | FD(dst_fr), MOVABLE_INS));
+ FAIL_IF(push_inst(compiler, MOV_fmt | FMT(op) | FS(src) | FD(dst_fr), MOVABLE_INS));
break;
- case SLJIT_FNEG:
- FAIL_IF(push_inst(compiler, NEG_D | FS(src) | FD(dst_fr), MOVABLE_INS));
+ case SLJIT_NEGD:
+ FAIL_IF(push_inst(compiler, NEG_fmt | FMT(op) | FS(src) | FD(dst_fr), MOVABLE_INS));
break;
- case SLJIT_FABS:
- FAIL_IF(push_inst(compiler, ABS_D | FS(src) | FD(dst_fr), MOVABLE_INS));
+ case SLJIT_ABSD:
+ FAIL_IF(push_inst(compiler, ABS_fmt | FMT(op) | FS(src) | FD(dst_fr), MOVABLE_INS));
break;
}
- if (dst_fr == TMP_FREG1)
- FAIL_IF(emit_fpu_data_transfer(compiler, src, 0, dst, dstw));
+ if (dst_fr == TMP_FREG1) {
+ if (GET_OPCODE(op) == SLJIT_MOVD)
+ dst_fr = src;
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op), dst_fr, dst, dstw, 0, 0));
+ }
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- int dst_fr;
+ sljit_si dst_fr, flags = 0;
CHECK_ERROR();
check_sljit_emit_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
@@ -1220,38 +1223,68 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, in
compiler->cache_arg = 0;
compiler->cache_argw = 0;
- dst_fr = (dst > SLJIT_FLOAT_REG4) ? TMP_FREG1 : dst;
+ dst_fr = (dst > SLJIT_FLOAT_REG6) ? TMP_FREG2 : (dst << 1);
- if (src2 > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG2, 1, src2, src2w));
- src2 = TMP_FREG2;
+ if (src1 > SLJIT_FLOAT_REG6) {
+ if (getput_arg_fast(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, src1, src1w)) {
+ FAIL_IF(compiler->error);
+ src1 = TMP_FREG1;
+ } else
+ flags |= SLOW_SRC1;
}
+ else
+ src1 <<= 1;
- if (src1 > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG1, 1, src1, src1w));
- src1 = TMP_FREG1;
+ if (src2 > SLJIT_FLOAT_REG6) {
+ if (getput_arg_fast(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src2, src2w)) {
+ FAIL_IF(compiler->error);
+ src2 = TMP_FREG2;
+ } else
+ flags |= SLOW_SRC2;
}
+ else
+ src2 <<= 1;
- switch (op) {
- case SLJIT_FADD:
- FAIL_IF(push_inst(compiler, ADD_D | FT(src2) | FS(src1) | FD(dst_fr), MOVABLE_INS));
+ if ((flags & (SLOW_SRC1 | SLOW_SRC2)) == (SLOW_SRC1 | SLOW_SRC2)) {
+ if (!can_cache(src1, src1w, src2, src2w) && can_cache(src1, src1w, dst, dstw)) {
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src2, src2w, src1, src1w));
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, src1, src1w, dst, dstw));
+ }
+ else {
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, src1, src1w, src2, src2w));
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src2, src2w, dst, dstw));
+ }
+ }
+ else if (flags & SLOW_SRC1)
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, src1, src1w, dst, dstw));
+ else if (flags & SLOW_SRC2)
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src2, src2w, dst, dstw));
+
+ if (flags & SLOW_SRC1)
+ src1 = TMP_FREG1;
+ if (flags & SLOW_SRC2)
+ src2 = TMP_FREG2;
+
+ switch (GET_OPCODE(op)) {
+ case SLJIT_ADDD:
+ FAIL_IF(push_inst(compiler, ADD_fmt | FMT(op) | FT(src2) | FS(src1) | FD(dst_fr), MOVABLE_INS));
break;
- case SLJIT_FSUB:
- FAIL_IF(push_inst(compiler, SUB_D | FT(src2) | FS(src1) | FD(dst_fr), MOVABLE_INS));
+ case SLJIT_SUBD:
+ FAIL_IF(push_inst(compiler, SUB_fmt | FMT(op) | FT(src2) | FS(src1) | FD(dst_fr), MOVABLE_INS));
break;
- case SLJIT_FMUL:
- FAIL_IF(push_inst(compiler, MUL_D | FT(src2) | FS(src1) | FD(dst_fr), MOVABLE_INS));
+ case SLJIT_MULD:
+ FAIL_IF(push_inst(compiler, MUL_fmt | FMT(op) | FT(src2) | FS(src1) | FD(dst_fr), MOVABLE_INS));
break;
- case SLJIT_FDIV:
- FAIL_IF(push_inst(compiler, DIV_D | FT(src2) | FS(src1) | FD(dst_fr), MOVABLE_INS));
+ case SLJIT_DIVD:
+ FAIL_IF(push_inst(compiler, DIV_fmt | FMT(op) | FT(src2) | FS(src1) | FD(dst_fr), MOVABLE_INS));
break;
}
- if (dst_fr == TMP_FREG1)
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG1, 0, dst, dstw));
+ if (dst_fr == TMP_FREG2)
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op), TMP_FREG2, dst, dstw, 0, 0));
return SLJIT_SUCCESS;
}
@@ -1260,31 +1293,30 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, in
/* Other instructions */
/* --------------------------------------------------------------------- */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_enter(struct sljit_compiler *compiler, int dst, sljit_w dstw, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_enter(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw)
{
CHECK_ERROR();
- check_sljit_emit_fast_enter(compiler, dst, dstw, args, temporaries, saveds, local_size);
-
- compiler->temporaries = temporaries;
- compiler->saveds = saveds;
+ check_sljit_emit_fast_enter(compiler, dst, dstw);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
- compiler->has_locals = local_size > 0;
- local_size += (saveds + 2 + 4) * sizeof(sljit_w);
- compiler->local_size = (local_size + 15) & ~0xf;
+ /* For UNUSED dst. Uncommon, but possible. */
+ if (dst == SLJIT_UNUSED)
+ return SLJIT_SUCCESS;
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS)
+ if (dst <= TMP_REG3)
return push_inst(compiler, ADDU_W | SA(RETURN_ADDR_REG) | TA(0) | D(dst), DR(dst));
- else if (dst & SLJIT_MEM)
- return emit_op_mem(compiler, WORD_DATA, RETURN_ADDR_REG, dst, dstw);
- return SLJIT_SUCCESS;
+
+ /* Memory. */
+ return emit_op_mem(compiler, WORD_DATA, RETURN_ADDR_REG, dst, dstw);
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compiler, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_return(struct sljit_compiler *compiler, sljit_si src, sljit_sw srcw)
{
CHECK_ERROR();
check_sljit_emit_fast_return(compiler, src, srcw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
- if (src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_NO_REGISTERS)
+ if (src <= TMP_REG3)
FAIL_IF(push_inst(compiler, ADDU_W | S(src) | TA(0) | DA(RETURN_ADDR_REG), RETURN_ADDR_REG));
else if (src & SLJIT_MEM)
FAIL_IF(emit_op_mem(compiler, WORD_DATA | LOAD_DATA, RETURN_ADDR_REG, src, srcw));
@@ -1319,7 +1351,7 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_label* sljit_emit_label(struct sljit_compi
#if (defined SLJIT_CONFIG_MIPS_32 && SLJIT_CONFIG_MIPS_32)
#define JUMP_LENGTH 4
#else
-#define JUMP_LENGTH 7
+#error "Implementation required"
#endif
#define BR_Z(src) \
@@ -1342,12 +1374,12 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_label* sljit_emit_label(struct sljit_compi
flags = IS_BIT16_COND; \
delay_check = FCSR_FCC;
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, int type)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, sljit_si type)
{
struct sljit_jump *jump;
sljit_ins inst;
- int flags = 0;
- int delay_check = UNMOVABLE_INS;
+ sljit_si flags = 0;
+ sljit_si delay_check = UNMOVABLE_INS;
CHECK_ERROR_PTR();
check_sljit_emit_jump(compiler, type);
@@ -1402,10 +1434,10 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compile
case SLJIT_C_MUL_NOT_OVERFLOW:
BR_NZ(OVERFLOW_FLAG);
break;
- case SLJIT_C_FLOAT_NAN:
+ case SLJIT_C_FLOAT_UNORDERED:
BR_F();
break;
- case SLJIT_C_FLOAT_NOT_NAN:
+ case SLJIT_C_FLOAT_ORDERED:
BR_T();
break;
default:
@@ -1433,7 +1465,7 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compile
PTR_FAIL_IF(push_inst(compiler, JALR | S(TMP_REG2) | DA(RETURN_ADDR_REG), UNMOVABLE_INS));
jump->addr = compiler->size;
/* A NOP if type < CALL1. */
- PTR_FAIL_IF(push_inst(compiler, ADDU_W | S(SLJIT_TEMPORARY_REG1) | TA(0) | DA(4), UNMOVABLE_INS));
+ PTR_FAIL_IF(push_inst(compiler, ADDU_W | S(SLJIT_SCRATCH_REG1) | TA(0) | DA(4), UNMOVABLE_INS));
}
return jump;
}
@@ -1458,32 +1490,28 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compile
src2 = 0; \
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_cmp(struct sljit_compiler *compiler, int type,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_cmp(struct sljit_compiler *compiler, sljit_si type,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
struct sljit_jump *jump;
- int flags;
+ sljit_si flags;
sljit_ins inst;
CHECK_ERROR_PTR();
check_sljit_emit_cmp(compiler, type, src1, src1w, src2, src2w);
+ ADJUST_LOCAL_OFFSET(src1, src1w);
+ ADJUST_LOCAL_OFFSET(src2, src2w);
compiler->cache_arg = 0;
compiler->cache_argw = 0;
flags = ((type & SLJIT_INT_OP) ? INT_DATA : WORD_DATA) | LOAD_DATA;
if (src1 & SLJIT_MEM) {
- if (getput_arg_fast(compiler, flags, DR(TMP_REG1), src1, src1w))
- PTR_FAIL_IF(compiler->error);
- else
- PTR_FAIL_IF(getput_arg(compiler, flags, DR(TMP_REG1), src1, src1w, src2, src2w));
+ PTR_FAIL_IF(emit_op_mem2(compiler, flags, DR(TMP_REG1), src1, src1w, src2, src2w));
src1 = TMP_REG1;
}
if (src2 & SLJIT_MEM) {
- if (getput_arg_fast(compiler, flags, DR(TMP_REG2), src2, src2w))
- PTR_FAIL_IF(compiler->error);
- else
- PTR_FAIL_IF(getput_arg(compiler, flags, DR(TMP_REG2), src2, src2w, 0, 0));
+ PTR_FAIL_IF(emit_op_mem2(compiler, flags, DR(TMP_REG2), src2, src2w, 0, 0));
src2 = TMP_REG2;
}
@@ -1583,13 +1611,13 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_cmp(struct sljit_compiler
#undef RESOLVE_IMM1
#undef RESOLVE_IMM2
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_fcmp(struct sljit_compiler *compiler, int type,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_fcmp(struct sljit_compiler *compiler, sljit_si type,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
struct sljit_jump *jump;
sljit_ins inst;
- int if_true;
+ sljit_si if_true;
CHECK_ERROR_PTR();
check_sljit_emit_fcmp(compiler, type, src1, src1w, src2, src2w);
@@ -1597,58 +1625,62 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_fcmp(struct sljit_compile
compiler->cache_arg = 0;
compiler->cache_argw = 0;
- if (src1 > SLJIT_FLOAT_REG4) {
- PTR_FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG1, 1, src1, src1w));
+ if (src1 > SLJIT_FLOAT_REG6) {
+ PTR_FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(type) | LOAD_DATA, TMP_FREG1, src1, src1w, src2, src2w));
src1 = TMP_FREG1;
}
- if (src2 > SLJIT_FLOAT_REG4) {
- PTR_FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG2, 1, src2, src2w));
+ else
+ src1 <<= 1;
+
+ if (src2 > SLJIT_FLOAT_REG6) {
+ PTR_FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(type) | LOAD_DATA, TMP_FREG2, src2, src2w, 0, 0));
src2 = TMP_FREG2;
}
+ else
+ src2 <<= 1;
jump = (struct sljit_jump*)ensure_abuf(compiler, sizeof(struct sljit_jump));
PTR_FAIL_IF(!jump);
set_jump(jump, compiler, type & SLJIT_REWRITABLE_JUMP);
jump->flags |= IS_BIT16_COND;
- type &= 0xff;
- switch (type) {
+ switch (type & 0xff) {
case SLJIT_C_FLOAT_EQUAL:
- inst = C_UEQ_D;
+ inst = C_UEQ_fmt;
if_true = 1;
break;
case SLJIT_C_FLOAT_NOT_EQUAL:
- inst = C_UEQ_D;
+ inst = C_UEQ_fmt;
if_true = 0;
break;
case SLJIT_C_FLOAT_LESS:
- inst = C_ULT_D;
+ inst = C_ULT_fmt;
if_true = 1;
break;
case SLJIT_C_FLOAT_GREATER_EQUAL:
- inst = C_ULT_D;
+ inst = C_ULT_fmt;
if_true = 0;
break;
case SLJIT_C_FLOAT_GREATER:
- inst = C_ULE_D;
+ inst = C_ULE_fmt;
if_true = 0;
break;
case SLJIT_C_FLOAT_LESS_EQUAL:
- inst = C_ULE_D;
+ inst = C_ULE_fmt;
if_true = 1;
break;
- case SLJIT_C_FLOAT_NAN:
- inst = C_UN_D;
+ case SLJIT_C_FLOAT_UNORDERED:
+ inst = C_UN_fmt;
if_true = 1;
break;
- case SLJIT_C_FLOAT_NOT_NAN:
+ case SLJIT_C_FLOAT_ORDERED:
default: /* Make compilers happy. */
- inst = C_UN_D;
+ inst = C_UN_fmt;
if_true = 0;
break;
}
- PTR_FAIL_IF(push_inst(compiler, inst | FT(src2) | FS(src1), UNMOVABLE_INS));
+ PTR_FAIL_IF(push_inst(compiler, inst | FMT(type) | FT(src2) | FS(src1), UNMOVABLE_INS));
/* Intentionally the other opcode. */
PTR_FAIL_IF(push_inst(compiler, (if_true ? BC1F : BC1T) | JUMP_LENGTH, UNMOVABLE_INS));
PTR_FAIL_IF(emit_const(compiler, TMP_REG2, 0));
@@ -1664,15 +1696,19 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_fcmp(struct sljit_compile
#undef BR_T
#undef BR_F
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, int type, int src, sljit_w srcw)
+#undef FLOAT_DATA
+#undef FMT
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_ijump(struct sljit_compiler *compiler, sljit_si type, sljit_si src, sljit_sw srcw)
{
- int src_r = TMP_REG2;
+ sljit_si src_r = TMP_REG2;
struct sljit_jump *jump = NULL;
CHECK_ERROR();
check_sljit_emit_ijump(compiler, type, src, srcw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
- if (src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_NO_REGISTERS) {
+ if (src <= TMP_REG3) {
if (DR(src) != 4)
src_r = src;
else
@@ -1690,12 +1726,12 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, i
}
FAIL_IF(push_inst(compiler, JALR | S(PIC_ADDR_REG) | DA(RETURN_ADDR_REG), UNMOVABLE_INS));
/* We need an extra instruction in any case. */
- return push_inst(compiler, ADDU_W | S(SLJIT_TEMPORARY_REG1) | TA(0) | DA(4), UNMOVABLE_INS);
+ return push_inst(compiler, ADDU_W | S(SLJIT_SCRATCH_REG1) | TA(0) | DA(4), UNMOVABLE_INS);
}
/* Register input. */
if (type >= SLJIT_CALL1)
- FAIL_IF(push_inst(compiler, ADDU_W | S(SLJIT_TEMPORARY_REG1) | TA(0) | DA(4), 4));
+ FAIL_IF(push_inst(compiler, ADDU_W | S(SLJIT_SCRATCH_REG1) | TA(0) | DA(4), 4));
FAIL_IF(push_inst(compiler, JALR | S(src_r) | DA(RETURN_ADDR_REG), UNMOVABLE_INS));
return push_inst(compiler, ADDU_W | S(src_r) | TA(0) | D(PIC_ADDR_REG), UNMOVABLE_INS);
}
@@ -1721,17 +1757,32 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, i
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_cond_value(struct sljit_compiler *compiler, int op, int dst, sljit_w dstw, int type)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_flags(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw,
+ sljit_si type)
{
- int sugg_dst_ar, dst_ar;
+ sljit_si sugg_dst_ar, dst_ar;
+ sljit_si flags = GET_ALL_FLAGS(op);
CHECK_ERROR();
- check_sljit_emit_cond_value(compiler, op, dst, dstw, type);
+ check_sljit_emit_op_flags(compiler, op, dst, dstw, src, srcw, type);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
if (dst == SLJIT_UNUSED)
return SLJIT_SUCCESS;
- sugg_dst_ar = DR((op == SLJIT_MOV && dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REG2);
+ op = GET_OPCODE(op);
+ sugg_dst_ar = DR((op < SLJIT_ADD && dst <= TMP_REG3) ? dst : TMP_REG2);
+
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+ if (op >= SLJIT_ADD && (src & SLJIT_MEM)) {
+ ADJUST_LOCAL_OFFSET(src, srcw);
+ FAIL_IF(emit_op_mem2(compiler, WORD_DATA | LOAD_DATA, DR(TMP_REG1), src, srcw, dst, dstw));
+ src = TMP_REG1;
+ srcw = 0;
+ }
switch (type) {
case SLJIT_C_EQUAL:
@@ -1774,8 +1825,8 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_cond_value(struct sljit_compiler *compil
dst_ar = EQUAL_FLAG;
break;
- case SLJIT_C_FLOAT_NAN:
- case SLJIT_C_FLOAT_NOT_NAN:
+ case SLJIT_C_FLOAT_UNORDERED:
+ case SLJIT_C_FLOAT_ORDERED:
FAIL_IF(push_inst(compiler, CFC1 | TA(sugg_dst_ar) | DA(FCSR_REG), sugg_dst_ar));
FAIL_IF(push_inst(compiler, SRL | TA(sugg_dst_ar) | DA(sugg_dst_ar) | SH_IMM(23), sugg_dst_ar));
FAIL_IF(push_inst(compiler, ANDI | SA(sugg_dst_ar) | TA(sugg_dst_ar) | IMM(1), sugg_dst_ar));
@@ -1793,10 +1844,10 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_cond_value(struct sljit_compiler *compil
dst_ar = sugg_dst_ar;
}
- if (GET_OPCODE(op) == SLJIT_OR) {
+ if (op >= SLJIT_ADD) {
if (DR(TMP_REG2) != dst_ar)
FAIL_IF(push_inst(compiler, ADDU_W | SA(dst_ar) | TA(0) | D(TMP_REG2), DR(TMP_REG2)));
- return emit_op(compiler, op, CUMULATIVE_OP | LOGICAL_OP | IMM_OP, dst, dstw, dst, dstw, TMP_REG2, 0);
+ return emit_op(compiler, op | flags, CUMULATIVE_OP | LOGICAL_OP | IMM_OP | ALT_KEEP_CACHE, dst, dstw, src, srcw, TMP_REG2, 0);
}
if (dst & SLJIT_MEM)
@@ -1807,19 +1858,20 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_cond_value(struct sljit_compiler *compil
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, int dst, sljit_w dstw, sljit_w init_value)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw init_value)
{
struct sljit_const *const_;
- int reg;
+ sljit_si reg;
CHECK_ERROR_PTR();
check_sljit_emit_const(compiler, dst, dstw, init_value);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
const_ = (struct sljit_const*)ensure_abuf(compiler, sizeof(struct sljit_const));
PTR_FAIL_IF(!const_);
set_const(const_, compiler);
- reg = (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REG2;
+ reg = (dst <= TMP_REG3) ? dst : TMP_REG2;
PTR_FAIL_IF(emit_const(compiler, reg, init_value));
diff --git a/src/3rdparty/pcre/sljit/sljitNativePPC_32.c b/src/3rdparty/pcre/sljit/sljitNativePPC_32.c
index 82d0508ac1..0bd35a6e0e 100644
--- a/src/3rdparty/pcre/sljit/sljitNativePPC_32.c
+++ b/src/3rdparty/pcre/sljit/sljitNativePPC_32.c
@@ -26,7 +26,7 @@
/* ppc 32-bit arch dependent functions. */
-static int load_immediate(struct sljit_compiler *compiler, int reg, sljit_w imm)
+static sljit_si load_immediate(struct sljit_compiler *compiler, sljit_si reg, sljit_sw imm)
{
if (imm <= SIMM_MAX && imm >= SIMM_MIN)
return push_inst(compiler, ADDI | D(reg) | A(0) | IMM(imm));
@@ -41,10 +41,59 @@ static int load_immediate(struct sljit_compiler *compiler, int reg, sljit_w imm)
#define INS_CLEAR_LEFT(dst, src, from) \
(RLWINM | S(src) | A(dst) | ((from) << 6) | (31 << 1))
-static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op, int flags,
- int dst, int src1, int src2)
+static SLJIT_INLINE sljit_si emit_single_op(struct sljit_compiler *compiler, sljit_si op, sljit_si flags,
+ sljit_si dst, sljit_si src1, sljit_si src2)
{
switch (op) {
+ case SLJIT_MOV:
+ case SLJIT_MOV_UI:
+ case SLJIT_MOV_SI:
+ case SLJIT_MOV_P:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ if (dst != src2)
+ return push_inst(compiler, OR | S(src2) | A(dst) | B(src2));
+ return SLJIT_SUCCESS;
+
+ case SLJIT_MOV_UB:
+ case SLJIT_MOV_SB:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
+ if (op == SLJIT_MOV_SB)
+ return push_inst(compiler, EXTSB | S(src2) | A(dst));
+ return push_inst(compiler, INS_CLEAR_LEFT(dst, src2, 24));
+ }
+ else if ((flags & REG_DEST) && op == SLJIT_MOV_SB)
+ return push_inst(compiler, EXTSB | S(src2) | A(dst));
+ else {
+ SLJIT_ASSERT(dst == src2);
+ }
+ return SLJIT_SUCCESS;
+
+ case SLJIT_MOV_UH:
+ case SLJIT_MOV_SH:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
+ if (op == SLJIT_MOV_SH)
+ return push_inst(compiler, EXTSH | S(src2) | A(dst));
+ return push_inst(compiler, INS_CLEAR_LEFT(dst, src2, 16));
+ }
+ else {
+ SLJIT_ASSERT(dst == src2);
+ }
+ return SLJIT_SUCCESS;
+
+ case SLJIT_NOT:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ return push_inst(compiler, NOR | RC(flags) | S(src2) | A(dst) | B(src2));
+
+ case SLJIT_NEG:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ return push_inst(compiler, NEG | OERC(flags) | D(dst) | A(src2));
+
+ case SLJIT_CLZ:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ return push_inst(compiler, CNTLZW | RC(flags) | S(src2) | A(dst));
+
case SLJIT_ADD:
if (flags & ALT_FORM1) {
/* Flags does not set: BIN_IMM_EXTS unnecessary. */
@@ -71,7 +120,7 @@ static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op,
case SLJIT_ADDC:
if (flags & ALT_FORM1) {
- FAIL_IF(push_inst(compiler, MFXER | S(0)));
+ FAIL_IF(push_inst(compiler, MFXER | D(0)));
FAIL_IF(push_inst(compiler, ADDE | D(dst) | A(src1) | B(src2)));
return push_inst(compiler, MTXER | S(0));
}
@@ -106,7 +155,7 @@ static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op,
case SLJIT_SUBC:
if (flags & ALT_FORM1) {
- FAIL_IF(push_inst(compiler, MFXER | S(0)));
+ FAIL_IF(push_inst(compiler, MFXER | D(0)));
FAIL_IF(push_inst(compiler, SUBFE | D(dst) | A(src2) | B(src1)));
return push_inst(compiler, MTXER | S(0));
}
@@ -179,65 +228,23 @@ static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op,
return push_inst(compiler, SRW | RC(flags) | S(src1) | A(dst) | B(src2));
case SLJIT_ASHR:
+ if (flags & ALT_FORM3)
+ FAIL_IF(push_inst(compiler, MFXER | D(0)));
if (flags & ALT_FORM1) {
SLJIT_ASSERT(src2 == TMP_REG2);
compiler->imm &= 0x1f;
- return push_inst(compiler, SRAWI | RC(flags) | S(src1) | A(dst) | (compiler->imm << 11));
- }
- return push_inst(compiler, SRAW | RC(flags) | S(src1) | A(dst) | B(src2));
-
- case SLJIT_MOV:
- case SLJIT_MOV_UI:
- case SLJIT_MOV_SI:
- SLJIT_ASSERT(src1 == TMP_REG1);
- if (dst != src2)
- return push_inst(compiler, OR | S(src2) | A(dst) | B(src2));
- return SLJIT_SUCCESS;
-
- case SLJIT_MOV_UB:
- case SLJIT_MOV_SB:
- SLJIT_ASSERT(src1 == TMP_REG1);
- if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
- if (op == SLJIT_MOV_SB)
- return push_inst(compiler, EXTSB | S(src2) | A(dst));
- return push_inst(compiler, INS_CLEAR_LEFT(dst, src2, 24));
+ FAIL_IF(push_inst(compiler, SRAWI | RC(flags) | S(src1) | A(dst) | (compiler->imm << 11)));
}
- else if ((flags & REG_DEST) && op == SLJIT_MOV_SB)
- return push_inst(compiler, EXTSB | S(src2) | A(dst));
- else if (dst != src2)
- SLJIT_ASSERT_STOP();
- return SLJIT_SUCCESS;
-
- case SLJIT_MOV_UH:
- case SLJIT_MOV_SH:
- SLJIT_ASSERT(src1 == TMP_REG1);
- if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
- if (op == SLJIT_MOV_SH)
- return push_inst(compiler, EXTSH | S(src2) | A(dst));
- return push_inst(compiler, INS_CLEAR_LEFT(dst, src2, 16));
- }
- else if (dst != src2)
- SLJIT_ASSERT_STOP();
- return SLJIT_SUCCESS;
-
- case SLJIT_NOT:
- SLJIT_ASSERT(src1 == TMP_REG1);
- return push_inst(compiler, NOR | RC(flags) | S(src2) | A(dst) | B(src2));
-
- case SLJIT_NEG:
- SLJIT_ASSERT(src1 == TMP_REG1);
- return push_inst(compiler, NEG | OERC(flags) | D(dst) | A(src2));
-
- case SLJIT_CLZ:
- SLJIT_ASSERT(src1 == TMP_REG1);
- return push_inst(compiler, CNTLZW | RC(flags) | S(src2) | A(dst));
+ else
+ FAIL_IF(push_inst(compiler, SRAW | RC(flags) | S(src1) | A(dst) | B(src2)));
+ return (flags & ALT_FORM3) ? push_inst(compiler, MTXER | S(0)) : SLJIT_SUCCESS;
}
SLJIT_ASSERT_STOP();
return SLJIT_SUCCESS;
}
-static SLJIT_INLINE int emit_const(struct sljit_compiler *compiler, int reg, sljit_w init_value)
+static SLJIT_INLINE sljit_si emit_const(struct sljit_compiler *compiler, sljit_si reg, sljit_sw init_value)
{
FAIL_IF(push_inst(compiler, ADDIS | D(reg) | A(0) | IMM(init_value >> 16)));
return push_inst(compiler, ORI | S(reg) | A(reg) | IMM(init_value));
@@ -252,7 +259,7 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_set_jump_addr(sljit_uw addr, sljit_uw new_ad
SLJIT_CACHE_FLUSH(inst, inst + 2);
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_w new_constant)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_sw new_constant)
{
sljit_ins *inst = (sljit_ins*)addr;
diff --git a/src/3rdparty/pcre/sljit/sljitNativePPC_64.c b/src/3rdparty/pcre/sljit/sljitNativePPC_64.c
index cc2ae37eb9..8eaeb41f4e 100644
--- a/src/3rdparty/pcre/sljit/sljitNativePPC_64.c
+++ b/src/3rdparty/pcre/sljit/sljitNativePPC_64.c
@@ -26,9 +26,11 @@
/* ppc 64-bit arch dependent functions. */
-#ifdef __GNUC__
+#if defined(__GNUC__) || (defined(__IBM_GCC_ASM) && __IBM_GCC_ASM)
#define ASM_SLJIT_CLZ(src, dst) \
- asm volatile ( "cntlzd %0, %1" : "=r"(dst) : "r"(src) )
+ __asm__ volatile ( "cntlzd %0, %1" : "=r"(dst) : "r"(src) )
+#elif defined(__xlc__)
+#error "Please enable GCC syntax for inline assembly statements"
#else
#error "Must implement count leading zeroes"
#endif
@@ -39,7 +41,7 @@
#define PUSH_RLDICR(reg, shift) \
push_inst(compiler, RLDI(reg, reg, 63 - shift, shift, 1))
-static int load_immediate(struct sljit_compiler *compiler, int reg, sljit_w imm)
+static sljit_si load_immediate(struct sljit_compiler *compiler, sljit_si reg, sljit_sw imm)
{
sljit_uw tmp;
sljit_uw shift;
@@ -143,10 +145,74 @@ static int load_immediate(struct sljit_compiler *compiler, int reg, sljit_w imm)
src1 = TMP_REG1; \
}
-static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op, int flags,
- int dst, int src1, int src2)
+static SLJIT_INLINE sljit_si emit_single_op(struct sljit_compiler *compiler, sljit_si op, sljit_si flags,
+ sljit_si dst, sljit_si src1, sljit_si src2)
{
switch (op) {
+ case SLJIT_MOV:
+ case SLJIT_MOV_P:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ if (dst != src2)
+ return push_inst(compiler, OR | S(src2) | A(dst) | B(src2));
+ return SLJIT_SUCCESS;
+
+ case SLJIT_MOV_UI:
+ case SLJIT_MOV_SI:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
+ if (op == SLJIT_MOV_SI)
+ return push_inst(compiler, EXTSW | S(src2) | A(dst));
+ return push_inst(compiler, INS_CLEAR_LEFT(dst, src2, 0));
+ }
+ else {
+ SLJIT_ASSERT(dst == src2);
+ }
+ return SLJIT_SUCCESS;
+
+ case SLJIT_MOV_UB:
+ case SLJIT_MOV_SB:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
+ if (op == SLJIT_MOV_SB)
+ return push_inst(compiler, EXTSB | S(src2) | A(dst));
+ return push_inst(compiler, INS_CLEAR_LEFT(dst, src2, 24));
+ }
+ else if ((flags & REG_DEST) && op == SLJIT_MOV_SB)
+ return push_inst(compiler, EXTSB | S(src2) | A(dst));
+ else {
+ SLJIT_ASSERT(dst == src2);
+ }
+ return SLJIT_SUCCESS;
+
+ case SLJIT_MOV_UH:
+ case SLJIT_MOV_SH:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
+ if (op == SLJIT_MOV_SH)
+ return push_inst(compiler, EXTSH | S(src2) | A(dst));
+ return push_inst(compiler, INS_CLEAR_LEFT(dst, src2, 16));
+ }
+ else {
+ SLJIT_ASSERT(dst == src2);
+ }
+ return SLJIT_SUCCESS;
+
+ case SLJIT_NOT:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ UN_EXTS();
+ return push_inst(compiler, NOR | RC(flags) | S(src2) | A(dst) | B(src2));
+
+ case SLJIT_NEG:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ UN_EXTS();
+ return push_inst(compiler, NEG | OERC(flags) | D(dst) | A(src2));
+
+ case SLJIT_CLZ:
+ SLJIT_ASSERT(src1 == TMP_REG1);
+ if (flags & ALT_FORM1)
+ return push_inst(compiler, CNTLZW | RC(flags) | S(src2) | A(dst));
+ return push_inst(compiler, CNTLZD | RC(flags) | S(src2) | A(dst));
+
case SLJIT_ADD:
if (flags & ALT_FORM1) {
/* Flags does not set: BIN_IMM_EXTS unnecessary. */
@@ -175,7 +241,7 @@ static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op,
case SLJIT_ADDC:
if (flags & ALT_FORM1) {
- FAIL_IF(push_inst(compiler, MFXER | S(0)));
+ FAIL_IF(push_inst(compiler, MFXER | D(0)));
FAIL_IF(push_inst(compiler, ADDE | D(dst) | A(src1) | B(src2)));
return push_inst(compiler, MTXER | S(0));
}
@@ -212,7 +278,7 @@ static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op,
case SLJIT_SUBC:
if (flags & ALT_FORM1) {
- FAIL_IF(push_inst(compiler, MFXER | S(0)));
+ FAIL_IF(push_inst(compiler, MFXER | D(0)));
FAIL_IF(push_inst(compiler, SUBFE | D(dst) | A(src2) | B(src1)));
return push_inst(compiler, MTXER | S(0));
}
@@ -284,9 +350,7 @@ static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op,
return push_inst(compiler, RLDI(dst, src1, compiler->imm, 63 - compiler->imm, 1) | RC(flags));
}
}
- if (flags & ALT_FORM2)
- return push_inst(compiler, SLW | RC(flags) | S(src1) | A(dst) | B(src2));
- return push_inst(compiler, SLD | RC(flags) | S(src1) | A(dst) | B(src2));
+ return push_inst(compiler, ((flags & ALT_FORM2) ? SLW : SLD) | RC(flags) | S(src1) | A(dst) | B(src2));
case SLJIT_LSHR:
if (flags & ALT_FORM1) {
@@ -300,92 +364,32 @@ static SLJIT_INLINE int emit_single_op(struct sljit_compiler *compiler, int op,
return push_inst(compiler, RLDI(dst, src1, 64 - compiler->imm, compiler->imm, 0) | RC(flags));
}
}
- if (flags & ALT_FORM2)
- return push_inst(compiler, SRW | RC(flags) | S(src1) | A(dst) | B(src2));
- return push_inst(compiler, SRD | RC(flags) | S(src1) | A(dst) | B(src2));
+ return push_inst(compiler, ((flags & ALT_FORM2) ? SRW : SRD) | RC(flags) | S(src1) | A(dst) | B(src2));
case SLJIT_ASHR:
+ if (flags & ALT_FORM3)
+ FAIL_IF(push_inst(compiler, MFXER | D(0)));
if (flags & ALT_FORM1) {
SLJIT_ASSERT(src2 == TMP_REG2);
if (flags & ALT_FORM2) {
compiler->imm &= 0x1f;
- return push_inst(compiler, SRAWI | RC(flags) | S(src1) | A(dst) | (compiler->imm << 11));
+ FAIL_IF(push_inst(compiler, SRAWI | RC(flags) | S(src1) | A(dst) | (compiler->imm << 11)));
}
else {
compiler->imm &= 0x3f;
- return push_inst(compiler, SRADI | RC(flags) | S(src1) | A(dst) | ((compiler->imm & 0x1f) << 11) | ((compiler->imm & 0x20) >> 4));
+ FAIL_IF(push_inst(compiler, SRADI | RC(flags) | S(src1) | A(dst) | ((compiler->imm & 0x1f) << 11) | ((compiler->imm & 0x20) >> 4)));
}
}
- if (flags & ALT_FORM2)
- return push_inst(compiler, SRAW | RC(flags) | S(src1) | A(dst) | B(src2));
- return push_inst(compiler, SRAD | RC(flags) | S(src1) | A(dst) | B(src2));
-
- case SLJIT_MOV:
- SLJIT_ASSERT(src1 == TMP_REG1);
- if (dst != src2)
- return push_inst(compiler, OR | S(src2) | A(dst) | B(src2));
- return SLJIT_SUCCESS;
-
- case SLJIT_MOV_UI:
- case SLJIT_MOV_SI:
- SLJIT_ASSERT(src1 == TMP_REG1);
- if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
- if (op == SLJIT_MOV_SI)
- return push_inst(compiler, EXTSW | S(src2) | A(dst));
- return push_inst(compiler, INS_CLEAR_LEFT(dst, src2, 0));
- }
- else if (dst != src2)
- SLJIT_ASSERT_STOP();
- return SLJIT_SUCCESS;
-
- case SLJIT_MOV_UB:
- case SLJIT_MOV_SB:
- SLJIT_ASSERT(src1 == TMP_REG1);
- if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
- if (op == SLJIT_MOV_SB)
- return push_inst(compiler, EXTSB | S(src2) | A(dst));
- return push_inst(compiler, INS_CLEAR_LEFT(dst, src2, 24));
- }
- else if ((flags & REG_DEST) && op == SLJIT_MOV_SB)
- return push_inst(compiler, EXTSB | S(src2) | A(dst));
- else if (dst != src2)
- SLJIT_ASSERT_STOP();
- return SLJIT_SUCCESS;
-
- case SLJIT_MOV_UH:
- case SLJIT_MOV_SH:
- SLJIT_ASSERT(src1 == TMP_REG1);
- if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
- if (op == SLJIT_MOV_SH)
- return push_inst(compiler, EXTSH | S(src2) | A(dst));
- return push_inst(compiler, INS_CLEAR_LEFT(dst, src2, 16));
- }
- else if (dst != src2)
- SLJIT_ASSERT_STOP();
- return SLJIT_SUCCESS;
-
- case SLJIT_NOT:
- SLJIT_ASSERT(src1 == TMP_REG1);
- UN_EXTS();
- return push_inst(compiler, NOR | RC(flags) | S(src2) | A(dst) | B(src2));
-
- case SLJIT_NEG:
- SLJIT_ASSERT(src1 == TMP_REG1);
- UN_EXTS();
- return push_inst(compiler, NEG | OERC(flags) | D(dst) | A(src2));
-
- case SLJIT_CLZ:
- SLJIT_ASSERT(src1 == TMP_REG1);
- if (flags & ALT_FORM1)
- return push_inst(compiler, CNTLZW | RC(flags) | S(src2) | A(dst));
- return push_inst(compiler, CNTLZD | RC(flags) | S(src2) | A(dst));
+ else
+ FAIL_IF(push_inst(compiler, ((flags & ALT_FORM2) ? SRAW : SRAD) | RC(flags) | S(src1) | A(dst) | B(src2)));
+ return (flags & ALT_FORM3) ? push_inst(compiler, MTXER | S(0)) : SLJIT_SUCCESS;
}
SLJIT_ASSERT_STOP();
return SLJIT_SUCCESS;
}
-static SLJIT_INLINE int emit_const(struct sljit_compiler *compiler, int reg, sljit_w init_value)
+static SLJIT_INLINE sljit_si emit_const(struct sljit_compiler *compiler, sljit_si reg, sljit_sw init_value)
{
FAIL_IF(push_inst(compiler, ADDIS | D(reg) | A(0) | IMM(init_value >> 48)));
FAIL_IF(push_inst(compiler, ORI | S(reg) | A(reg) | IMM(init_value >> 32)));
@@ -405,7 +409,7 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_set_jump_addr(sljit_uw addr, sljit_uw new_ad
SLJIT_CACHE_FLUSH(inst, inst + 5);
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_w new_constant)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_sw new_constant)
{
sljit_ins *inst = (sljit_ins*)addr;
@@ -415,14 +419,3 @@ SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_w new_constan
inst[4] = (inst[4] & 0xffff0000) | (new_constant & 0xffff);
SLJIT_CACHE_FLUSH(inst, inst + 5);
}
-
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_function_context(void** func_ptr, struct sljit_function_context* context, sljit_w addr, void* func)
-{
- sljit_w* ptrs;
- if (func_ptr)
- *func_ptr = (void*)context;
- ptrs = (sljit_w*)func;
- context->addr = addr ? addr : ptrs[0];
- context->r2 = ptrs[1];
- context->r11 = ptrs[2];
-}
diff --git a/src/3rdparty/pcre/sljit/sljitNativePPC_common.c b/src/3rdparty/pcre/sljit/sljitNativePPC_common.c
index f0f191de1f..f7c75a7906 100644
--- a/src/3rdparty/pcre/sljit/sljitNativePPC_common.c
+++ b/src/3rdparty/pcre/sljit/sljitNativePPC_common.c
@@ -24,7 +24,7 @@
* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name()
+SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name(void)
{
return "PowerPC" SLJIT_CPUINFO;
}
@@ -33,26 +33,62 @@ SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name()
Both for ppc-32 and ppc-64. */
typedef sljit_ui sljit_ins;
+#ifdef _AIX
+#include <sys/cache.h>
+#endif
+
static void ppc_cache_flush(sljit_ins *from, sljit_ins *to)
{
+#ifdef _AIX
+ _sync_cache_range((caddr_t)from, (int)((size_t)to - (size_t)from));
+#elif defined(__GNUC__) || (defined(__IBM_GCC_ASM) && __IBM_GCC_ASM)
+# if defined(_ARCH_PWR) || defined(_ARCH_PWR2)
+ /* Cache flush for POWER architecture. */
while (from < to) {
-#ifdef __GNUC__
- asm volatile ( "icbi 0, %0" : : "r"(from) );
-#else
-#error "Must implement icbi"
-#endif
+ __asm__ volatile (
+ "clf 0, %0\n"
+ "dcs\n"
+ : : "r"(from)
+ );
from++;
}
+ __asm__ volatile ( "ics" );
+# elif defined(_ARCH_COM) && !defined(_ARCH_PPC)
+# error "Cache flush is not implemented for PowerPC/POWER common mode."
+# else
+ /* Cache flush for PowerPC architecture. */
+ while (from < to) {
+ __asm__ volatile (
+ "dcbf 0, %0\n"
+ "sync\n"
+ "icbi 0, %0\n"
+ : : "r"(from)
+ );
+ from++;
+ }
+ __asm__ volatile ( "isync" );
+# endif
+# ifdef __xlc__
+# warning "This file may fail to compile if -qfuncsect is used"
+# endif
+#elif defined(__xlc__)
+#error "Please enable GCC syntax for inline assembly statements with -qasm=gcc"
+#else
+#error "This platform requires a cache flush implementation."
+#endif /* _AIX */
}
#define TMP_REG1 (SLJIT_NO_REGISTERS + 1)
#define TMP_REG2 (SLJIT_NO_REGISTERS + 2)
#define TMP_REG3 (SLJIT_NO_REGISTERS + 3)
#define ZERO_REG (SLJIT_NO_REGISTERS + 4)
-#define REAL_STACK_PTR (SLJIT_NO_REGISTERS + 5)
-#define TMP_FREG1 (SLJIT_FLOAT_REG4 + 1)
-#define TMP_FREG2 (SLJIT_FLOAT_REG4 + 2)
+#define TMP_FREG1 (0)
+#define TMP_FREG2 (SLJIT_FLOAT_REG6 + 1)
+
+static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 5] = {
+ 0, 3, 4, 5, 6, 7, 30, 29, 28, 27, 26, 1, 8, 9, 10, 31
+};
/* --------------------------------------------------------------------- */
/* Instrucion forms */
@@ -107,16 +143,17 @@ static void ppc_cache_flush(sljit_ins *from, sljit_ins *to)
#define EXTSW (HI(31) | LO(986))
#define FABS (HI(63) | LO(264))
#define FADD (HI(63) | LO(21))
+#define FADDS (HI(59) | LO(21))
#define FCMPU (HI(63) | LO(0))
#define FDIV (HI(63) | LO(18))
+#define FDIVS (HI(59) | LO(18))
#define FMR (HI(63) | LO(72))
#define FMUL (HI(63) | LO(25))
+#define FMULS (HI(59) | LO(25))
#define FNEG (HI(63) | LO(40))
#define FSUB (HI(63) | LO(20))
+#define FSUBS (HI(59) | LO(20))
#define LD (HI(58) | 0)
-#define LFD (HI(50))
-#define LFDUX (HI(31) | LO(631))
-#define LFDX (HI(31) | LO(599))
#define LWZ (HI(32))
#define MFCR (HI(31) | LO(19))
#define MFLR (HI(31) | LO(339) | 0x80000)
@@ -150,9 +187,6 @@ static void ppc_cache_flush(sljit_ins *from, sljit_ins *to)
#define STD (HI(62) | 0)
#define STDU (HI(62) | 1)
#define STDUX (HI(31) | LO(181))
-#define STFD (HI(54))
-#define STFDUX (HI(31) | LO(759))
-#define STFDX (HI(31) | LO(727))
#define STW (HI(36))
#define STWU (HI(37))
#define STWUX (HI(31) | LO(183))
@@ -168,13 +202,20 @@ static void ppc_cache_flush(sljit_ins *from, sljit_ins *to)
#define SIMM_MIN (-0x8000)
#define UIMM_MAX (0xffff)
-/* SLJIT_LOCALS_REG is not the real stack register, since it must
- point to the head of the stack chain. */
-static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 6] = {
- 0, 3, 4, 5, 6, 7, 29, 28, 27, 26, 25, 31, 8, 9, 10, 30, 1
-};
+#if (defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_function_context(void** func_ptr, struct sljit_function_context* context, sljit_sw addr, void* func)
+{
+ sljit_sw* ptrs;
+ if (func_ptr)
+ *func_ptr = (void*)context;
+ ptrs = (sljit_sw*)func;
+ context->addr = addr ? addr : ptrs[0];
+ context->r2 = ptrs[1];
+ context->r11 = ptrs[2];
+}
+#endif
-static int push_inst(struct sljit_compiler *compiler, sljit_ins ins)
+static sljit_si push_inst(struct sljit_compiler *compiler, sljit_ins ins)
{
sljit_ins *ptr = (sljit_ins*)ensure_buf(compiler, sizeof(sljit_ins));
FAIL_IF(!ptr);
@@ -183,9 +224,9 @@ static int push_inst(struct sljit_compiler *compiler, sljit_ins ins)
return SLJIT_SUCCESS;
}
-static SLJIT_INLINE int optimize_jump(struct sljit_jump *jump, sljit_ins *code_ptr, sljit_ins *code)
+static SLJIT_INLINE sljit_si optimize_jump(struct sljit_jump *jump, sljit_ins *code_ptr, sljit_ins *code)
{
- sljit_w diff;
+ sljit_sw diff;
sljit_uw target_addr;
if (jump->flags & SLJIT_REWRITABLE_JUMP)
@@ -197,7 +238,7 @@ static SLJIT_INLINE int optimize_jump(struct sljit_jump *jump, sljit_ins *code_p
SLJIT_ASSERT(jump->flags & JUMP_LABEL);
target_addr = (sljit_uw)(code + jump->u.label->size);
}
- diff = ((sljit_w)target_addr - (sljit_w)(code_ptr)) & ~0x3l;
+ diff = ((sljit_sw)target_addr - (sljit_sw)(code_ptr)) & ~0x3l;
if (jump->flags & UNCOND_B) {
if (diff <= 0x01ffffff && diff >= -0x02000000) {
@@ -240,8 +281,12 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
check_sljit_generate_code(compiler);
reverse_buf(compiler);
+#if (defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL)
#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
compiler->size += (compiler->size & 0x1) + (sizeof(struct sljit_function_context) / sizeof(sljit_ins));
+#else
+ compiler->size += (sizeof(struct sljit_function_context) / sizeof(sljit_ins));
+#endif
#endif
code = (sljit_ins*)SLJIT_MALLOC_EXEC(compiler->size * sizeof(sljit_ins));
PTR_FAIL_WITH_EXEC_IF(code);
@@ -305,10 +350,10 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
SLJIT_ASSERT(!label);
SLJIT_ASSERT(!jump);
SLJIT_ASSERT(!const_);
-#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
- SLJIT_ASSERT(code_ptr - code <= (int)compiler->size - ((compiler->size & 0x1) ? 3 : 2));
+#if (defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL)
+ SLJIT_ASSERT(code_ptr - code <= (sljit_sw)compiler->size - (sizeof(struct sljit_function_context) / sizeof(sljit_ins)));
#else
- SLJIT_ASSERT(code_ptr - code <= (int)compiler->size);
+ SLJIT_ASSERT(code_ptr - code <= (sljit_sw)compiler->size);
#endif
jump = compiler->jumps;
@@ -320,7 +365,7 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
if (jump->flags & UNCOND_B) {
if (!(jump->flags & ABSOLUTE_B)) {
addr = addr - jump->addr;
- SLJIT_ASSERT((sljit_w)addr <= 0x01ffffff && (sljit_w)addr >= -0x02000000);
+ SLJIT_ASSERT((sljit_sw)addr <= 0x01ffffff && (sljit_sw)addr >= -0x02000000);
*buf_ptr = Bx | (addr & 0x03fffffc) | ((*buf_ptr) & 0x1);
}
else {
@@ -331,7 +376,7 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
else {
if (!(jump->flags & ABSOLUTE_B)) {
addr = addr - jump->addr;
- SLJIT_ASSERT((sljit_w)addr <= 0x7fff && (sljit_w)addr >= -0x8000);
+ SLJIT_ASSERT((sljit_sw)addr <= 0x7fff && (sljit_sw)addr >= -0x8000);
*buf_ptr = BCx | (addr & 0xfffc) | ((*buf_ptr) & 0x03ff0001);
}
else {
@@ -361,29 +406,41 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
compiler->error = SLJIT_ERR_COMPILED;
compiler->executable_size = compiler->size * sizeof(sljit_ins);
+#if (defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL)
#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
- if (((sljit_w)code_ptr) & 0x4)
+ if (((sljit_sw)code_ptr) & 0x4)
code_ptr++;
- sljit_set_function_context(NULL, (struct sljit_function_context*)code_ptr, (sljit_w)code, sljit_generate_code);
+ sljit_set_function_context(NULL, (struct sljit_function_context*)code_ptr, (sljit_sw)code, (void*)sljit_generate_code);
return code_ptr;
#else
+ sljit_set_function_context(NULL, (struct sljit_function_context*)code_ptr, (sljit_sw)code, (void*)sljit_generate_code);
+ return code_ptr;
+#endif
+#else
return code;
#endif
}
+/* --------------------------------------------------------------------- */
+/* Entry, exit */
+/* --------------------------------------------------------------------- */
+
/* inp_flags: */
/* Creates an index in data_transfer_insts array. */
+#define LOAD_DATA 0x01
+#define INDEXED 0x02
+#define WRITE_BACK 0x04
#define WORD_DATA 0x00
-#define BYTE_DATA 0x01
-#define HALF_DATA 0x02
-#define INT_DATA 0x03
-#define SIGNED_DATA 0x04
-#define LOAD_DATA 0x08
-#define WRITE_BACK 0x10
-#define INDEXED 0x20
+#define BYTE_DATA 0x08
+#define HALF_DATA 0x10
+#define INT_DATA 0x18
+#define SIGNED_DATA 0x20
+/* Separates integer and floating point registers */
+#define GPR_REG 0x3f
+#define DOUBLE_DATA 0x40
-#define MEM_MASK 0x3f
+#define MEM_MASK 0x7f
/* Other inp_flags. */
@@ -392,6 +449,7 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
#define ALT_SIGN_EXT 0x000200
/* This flag affects the RC() and OERC() macros. */
#define ALT_SET_FLAGS 0x000400
+#define ALT_KEEP_CACHE 0x000800
#define ALT_FORM1 0x010000
#define ALT_FORM2 0x020000
#define ALT_FORM3 0x040000
@@ -428,92 +486,85 @@ ALT_FORM6 0x200000 */
#define STACK_LOAD LD
#endif
-static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w);
-
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_enter(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
CHECK_ERROR();
- check_sljit_emit_enter(compiler, args, temporaries, saveds, local_size);
+ check_sljit_emit_enter(compiler, args, scratches, saveds, local_size);
- compiler->temporaries = temporaries;
+ compiler->scratches = scratches;
compiler->saveds = saveds;
- compiler->has_locals = local_size > 0;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
FAIL_IF(push_inst(compiler, MFLR | D(0)));
- if (compiler->has_locals)
- FAIL_IF(push_inst(compiler, STACK_STORE | S(SLJIT_LOCALS_REG) | A(REAL_STACK_PTR) | IMM(-(int)(sizeof(sljit_w))) ));
- FAIL_IF(push_inst(compiler, STACK_STORE | S(ZERO_REG) | A(REAL_STACK_PTR) | IMM(-2 * (int)(sizeof(sljit_w))) ));
+ FAIL_IF(push_inst(compiler, STACK_STORE | S(ZERO_REG) | A(SLJIT_LOCALS_REG) | IMM(-(sljit_si)(sizeof(sljit_sw))) ));
if (saveds >= 1)
- FAIL_IF(push_inst(compiler, STACK_STORE | S(SLJIT_SAVED_REG1) | A(REAL_STACK_PTR) | IMM(-3 * (int)(sizeof(sljit_w))) ));
+ FAIL_IF(push_inst(compiler, STACK_STORE | S(SLJIT_SAVED_REG1) | A(SLJIT_LOCALS_REG) | IMM(-2 * (sljit_si)(sizeof(sljit_sw))) ));
if (saveds >= 2)
- FAIL_IF(push_inst(compiler, STACK_STORE | S(SLJIT_SAVED_REG2) | A(REAL_STACK_PTR) | IMM(-4 * (int)(sizeof(sljit_w))) ));
+ FAIL_IF(push_inst(compiler, STACK_STORE | S(SLJIT_SAVED_REG2) | A(SLJIT_LOCALS_REG) | IMM(-3 * (sljit_si)(sizeof(sljit_sw))) ));
if (saveds >= 3)
- FAIL_IF(push_inst(compiler, STACK_STORE | S(SLJIT_SAVED_REG3) | A(REAL_STACK_PTR) | IMM(-5 * (int)(sizeof(sljit_w))) ));
+ FAIL_IF(push_inst(compiler, STACK_STORE | S(SLJIT_SAVED_REG3) | A(SLJIT_LOCALS_REG) | IMM(-4 * (sljit_si)(sizeof(sljit_sw))) ));
if (saveds >= 4)
- FAIL_IF(push_inst(compiler, STACK_STORE | S(SLJIT_SAVED_EREG1) | A(REAL_STACK_PTR) | IMM(-6 * (int)(sizeof(sljit_w))) ));
+ FAIL_IF(push_inst(compiler, STACK_STORE | S(SLJIT_SAVED_EREG1) | A(SLJIT_LOCALS_REG) | IMM(-5 * (sljit_si)(sizeof(sljit_sw))) ));
if (saveds >= 5)
- FAIL_IF(push_inst(compiler, STACK_STORE | S(SLJIT_SAVED_EREG2) | A(REAL_STACK_PTR) | IMM(-7 * (int)(sizeof(sljit_w))) ));
- FAIL_IF(push_inst(compiler, STACK_STORE | S(0) | A(REAL_STACK_PTR) | IMM(sizeof(sljit_w)) ));
+ FAIL_IF(push_inst(compiler, STACK_STORE | S(SLJIT_SAVED_EREG2) | A(SLJIT_LOCALS_REG) | IMM(-6 * (sljit_si)(sizeof(sljit_sw))) ));
+ FAIL_IF(push_inst(compiler, STACK_STORE | S(0) | A(SLJIT_LOCALS_REG) | IMM(sizeof(sljit_sw)) ));
FAIL_IF(push_inst(compiler, ADDI | D(ZERO_REG) | A(0) | 0));
if (args >= 1)
- FAIL_IF(push_inst(compiler, OR | S(SLJIT_TEMPORARY_REG1) | A(SLJIT_SAVED_REG1) | B(SLJIT_TEMPORARY_REG1)));
+ FAIL_IF(push_inst(compiler, OR | S(SLJIT_SCRATCH_REG1) | A(SLJIT_SAVED_REG1) | B(SLJIT_SCRATCH_REG1)));
if (args >= 2)
- FAIL_IF(push_inst(compiler, OR | S(SLJIT_TEMPORARY_REG2) | A(SLJIT_SAVED_REG2) | B(SLJIT_TEMPORARY_REG2)));
+ FAIL_IF(push_inst(compiler, OR | S(SLJIT_SCRATCH_REG2) | A(SLJIT_SAVED_REG2) | B(SLJIT_SCRATCH_REG2)));
if (args >= 3)
- FAIL_IF(push_inst(compiler, OR | S(SLJIT_TEMPORARY_REG3) | A(SLJIT_SAVED_REG3) | B(SLJIT_TEMPORARY_REG3)));
+ FAIL_IF(push_inst(compiler, OR | S(SLJIT_SCRATCH_REG3) | A(SLJIT_SAVED_REG3) | B(SLJIT_SCRATCH_REG3)));
-#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32)
- compiler->local_size = (2 + saveds + 2) * sizeof(sljit_w) + local_size;
+#if (defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL)
+ compiler->local_size = (1 + saveds + 6 + 8) * sizeof(sljit_sw) + local_size;
#else
- compiler->local_size = (2 + saveds + 7 + 8) * sizeof(sljit_w) + local_size;
+ compiler->local_size = (1 + saveds + 2) * sizeof(sljit_sw) + local_size;
#endif
compiler->local_size = (compiler->local_size + 15) & ~0xf;
#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32)
if (compiler->local_size <= SIMM_MAX)
- FAIL_IF(push_inst(compiler, STWU | S(REAL_STACK_PTR) | A(REAL_STACK_PTR) | IMM(-compiler->local_size)));
+ FAIL_IF(push_inst(compiler, STWU | S(SLJIT_LOCALS_REG) | A(SLJIT_LOCALS_REG) | IMM(-compiler->local_size)));
else {
FAIL_IF(load_immediate(compiler, 0, -compiler->local_size));
- FAIL_IF(push_inst(compiler, STWUX | S(REAL_STACK_PTR) | A(REAL_STACK_PTR) | B(0)));
+ FAIL_IF(push_inst(compiler, STWUX | S(SLJIT_LOCALS_REG) | A(SLJIT_LOCALS_REG) | B(0)));
}
- if (compiler->has_locals)
- FAIL_IF(push_inst(compiler, ADDI | D(SLJIT_LOCALS_REG) | A(REAL_STACK_PTR) | IMM(2 * sizeof(sljit_w))));
#else
if (compiler->local_size <= SIMM_MAX)
- FAIL_IF(push_inst(compiler, STDU | S(REAL_STACK_PTR) | A(REAL_STACK_PTR) | IMM(-compiler->local_size)));
+ FAIL_IF(push_inst(compiler, STDU | S(SLJIT_LOCALS_REG) | A(SLJIT_LOCALS_REG) | IMM(-compiler->local_size)));
else {
FAIL_IF(load_immediate(compiler, 0, -compiler->local_size));
- FAIL_IF(push_inst(compiler, STDUX | S(REAL_STACK_PTR) | A(REAL_STACK_PTR) | B(0)));
+ FAIL_IF(push_inst(compiler, STDUX | S(SLJIT_LOCALS_REG) | A(SLJIT_LOCALS_REG) | B(0)));
}
- if (compiler->has_locals)
- FAIL_IF(push_inst(compiler, ADDI | D(SLJIT_LOCALS_REG) | A(REAL_STACK_PTR) | IMM((7 + 8) * sizeof(sljit_w))));
#endif
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
CHECK_ERROR_VOID();
- check_sljit_set_context(compiler, args, temporaries, saveds, local_size);
+ check_sljit_set_context(compiler, args, scratches, saveds, local_size);
- compiler->temporaries = temporaries;
+ compiler->scratches = scratches;
compiler->saveds = saveds;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
- compiler->has_locals = local_size > 0;
-#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32)
- compiler->local_size = (2 + saveds + 2) * sizeof(sljit_w) + local_size;
+#if (defined SLJIT_INDIRECT_CALL && SLJIT_INDIRECT_CALL)
+ compiler->local_size = (1 + saveds + 6 + 8) * sizeof(sljit_sw) + local_size;
#else
- compiler->local_size = (2 + saveds + 7 + 8) * sizeof(sljit_w) + local_size;
+ compiler->local_size = (1 + saveds + 2) * sizeof(sljit_sw) + local_size;
#endif
compiler->local_size = (compiler->local_size + 15) & ~0xf;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler, int op, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_return(struct sljit_compiler *compiler, sljit_si op, sljit_si src, sljit_sw srcw)
{
CHECK_ERROR();
check_sljit_emit_return(compiler, op, src, srcw);
@@ -521,26 +572,24 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
FAIL_IF(emit_mov_before_return(compiler, op, src, srcw));
if (compiler->local_size <= SIMM_MAX)
- FAIL_IF(push_inst(compiler, ADDI | D(REAL_STACK_PTR) | A(REAL_STACK_PTR) | IMM(compiler->local_size)));
+ FAIL_IF(push_inst(compiler, ADDI | D(SLJIT_LOCALS_REG) | A(SLJIT_LOCALS_REG) | IMM(compiler->local_size)));
else {
FAIL_IF(load_immediate(compiler, 0, compiler->local_size));
- FAIL_IF(push_inst(compiler, ADD | D(REAL_STACK_PTR) | A(REAL_STACK_PTR) | B(0)));
+ FAIL_IF(push_inst(compiler, ADD | D(SLJIT_LOCALS_REG) | A(SLJIT_LOCALS_REG) | B(0)));
}
- FAIL_IF(push_inst(compiler, STACK_LOAD | D(0) | A(REAL_STACK_PTR) | IMM(sizeof(sljit_w))));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | D(0) | A(SLJIT_LOCALS_REG) | IMM(sizeof(sljit_sw))));
if (compiler->saveds >= 5)
- FAIL_IF(push_inst(compiler, STACK_LOAD | D(SLJIT_SAVED_EREG2) | A(REAL_STACK_PTR) | IMM(-7 * (int)(sizeof(sljit_w))) ));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | D(SLJIT_SAVED_EREG2) | A(SLJIT_LOCALS_REG) | IMM(-6 * (sljit_si)(sizeof(sljit_sw))) ));
if (compiler->saveds >= 4)
- FAIL_IF(push_inst(compiler, STACK_LOAD | D(SLJIT_SAVED_EREG1) | A(REAL_STACK_PTR) | IMM(-6 * (int)(sizeof(sljit_w))) ));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | D(SLJIT_SAVED_EREG1) | A(SLJIT_LOCALS_REG) | IMM(-5 * (sljit_si)(sizeof(sljit_sw))) ));
if (compiler->saveds >= 3)
- FAIL_IF(push_inst(compiler, STACK_LOAD | D(SLJIT_SAVED_REG3) | A(REAL_STACK_PTR) | IMM(-5 * (int)(sizeof(sljit_w))) ));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | D(SLJIT_SAVED_REG3) | A(SLJIT_LOCALS_REG) | IMM(-4 * (sljit_si)(sizeof(sljit_sw))) ));
if (compiler->saveds >= 2)
- FAIL_IF(push_inst(compiler, STACK_LOAD | D(SLJIT_SAVED_REG2) | A(REAL_STACK_PTR) | IMM(-4 * (int)(sizeof(sljit_w))) ));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | D(SLJIT_SAVED_REG2) | A(SLJIT_LOCALS_REG) | IMM(-3 * (sljit_si)(sizeof(sljit_sw))) ));
if (compiler->saveds >= 1)
- FAIL_IF(push_inst(compiler, STACK_LOAD | D(SLJIT_SAVED_REG1) | A(REAL_STACK_PTR) | IMM(-3 * (int)(sizeof(sljit_w))) ));
- FAIL_IF(push_inst(compiler, STACK_LOAD | D(ZERO_REG) | A(REAL_STACK_PTR) | IMM(-2 * (int)(sizeof(sljit_w))) ));
- if (compiler->has_locals)
- FAIL_IF(push_inst(compiler, STACK_LOAD | D(SLJIT_LOCALS_REG) | A(REAL_STACK_PTR) | IMM(-(int)(sizeof(sljit_w))) ));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | D(SLJIT_SAVED_REG1) | A(SLJIT_LOCALS_REG) | IMM(-2 * (sljit_si)(sizeof(sljit_sw))) ));
+ FAIL_IF(push_inst(compiler, STACK_LOAD | D(ZERO_REG) | A(SLJIT_LOCALS_REG) | IMM(-(sljit_si)(sizeof(sljit_sw))) ));
FAIL_IF(push_inst(compiler, MTLR | S(0)));
FAIL_IF(push_inst(compiler, BLR));
@@ -568,117 +617,139 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
#define UPDATE_REQ 0x20000
#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32)
-#define ARCH_DEPEND(a, b) a
-#define GET_INST_CODE(inst) (inst)
+#define ARCH_32_64(a, b) a
+#define INST_CODE_AND_DST(inst, flags, reg) \
+ ((inst) | (((flags) & MEM_MASK) <= GPR_REG ? D(reg) : FD(reg)))
#else
-#define ARCH_DEPEND(a, b) b
-#define GET_INST_CODE(index) ((inst) & ~(ADDR_MODE2 | UPDATE_REQ))
+#define ARCH_32_64(a, b) b
+#define INST_CODE_AND_DST(inst, flags, reg) \
+ (((inst) & ~(ADDR_MODE2 | UPDATE_REQ)) | (((flags) & MEM_MASK) <= GPR_REG ? D(reg) : FD(reg)))
#endif
-static SLJIT_CONST sljit_ins data_transfer_insts[64] = {
+static SLJIT_CONST sljit_ins data_transfer_insts[64 + 8] = {
+
+/* -------- Unsigned -------- */
+
+/* Word. */
+
+/* u w n i s */ ARCH_32_64(HI(36) /* stw */, HI(62) | ADDR_MODE2 | 0x0 /* std */),
+/* u w n i l */ ARCH_32_64(HI(32) /* lwz */, HI(58) | ADDR_MODE2 | 0x0 /* ld */),
+/* u w n x s */ ARCH_32_64(HI(31) | LO(151) /* stwx */, HI(31) | LO(149) /* stdx */),
+/* u w n x l */ ARCH_32_64(HI(31) | LO(23) /* lwzx */, HI(31) | LO(21) /* ldx */),
+
+/* u w w i s */ ARCH_32_64(HI(37) /* stwu */, HI(62) | ADDR_MODE2 | 0x1 /* stdu */),
+/* u w w i l */ ARCH_32_64(HI(33) /* lwzu */, HI(58) | ADDR_MODE2 | 0x1 /* ldu */),
+/* u w w x s */ ARCH_32_64(HI(31) | LO(183) /* stwux */, HI(31) | LO(181) /* stdux */),
+/* u w w x l */ ARCH_32_64(HI(31) | LO(55) /* lwzux */, HI(31) | LO(53) /* ldux */),
+
+/* Byte. */
-/* No write-back. */
+/* u b n i s */ HI(38) /* stb */,
+/* u b n i l */ HI(34) /* lbz */,
+/* u b n x s */ HI(31) | LO(215) /* stbx */,
+/* u b n x l */ HI(31) | LO(87) /* lbzx */,
-/* i n s u w */ ARCH_DEPEND(HI(36) /* stw */, HI(62) | ADDR_MODE2 | 0x0 /* std */),
-/* i n s u b */ HI(38) /* stb */,
-/* i n s u h */ HI(44) /* sth*/,
-/* i n s u i */ HI(36) /* stw */,
+/* u b w i s */ HI(39) /* stbu */,
+/* u b w i l */ HI(35) /* lbzu */,
+/* u b w x s */ HI(31) | LO(247) /* stbux */,
+/* u b w x l */ HI(31) | LO(119) /* lbzux */,
-/* i n s s w */ ARCH_DEPEND(HI(36) /* stw */, HI(62) | ADDR_MODE2 | 0x0 /* std */),
-/* i n s s b */ HI(38) /* stb */,
-/* i n s s h */ HI(44) /* sth*/,
-/* i n s s i */ HI(36) /* stw */,
+/* Half. */
-/* i n l u w */ ARCH_DEPEND(HI(32) /* lwz */, HI(58) | ADDR_MODE2 | 0x0 /* ld */),
-/* i n l u b */ HI(34) /* lbz */,
-/* i n l u h */ HI(40) /* lhz */,
-/* i n l u i */ HI(32) /* lwz */,
+/* u h n i s */ HI(44) /* sth */,
+/* u h n i l */ HI(40) /* lhz */,
+/* u h n x s */ HI(31) | LO(407) /* sthx */,
+/* u h n x l */ HI(31) | LO(279) /* lhzx */,
-/* i n l s w */ ARCH_DEPEND(HI(32) /* lwz */, HI(58) | ADDR_MODE2 | 0x0 /* ld */),
-/* i n l s b */ HI(34) /* lbz */ /* EXTS_REQ */,
-/* i n l s h */ HI(42) /* lha */,
-/* i n l s i */ ARCH_DEPEND(HI(32) /* lwz */, HI(58) | ADDR_MODE2 | 0x2 /* lwa */),
+/* u h w i s */ HI(45) /* sthu */,
+/* u h w i l */ HI(41) /* lhzu */,
+/* u h w x s */ HI(31) | LO(439) /* sthux */,
+/* u h w x l */ HI(31) | LO(311) /* lhzux */,
-/* Write-back. */
+/* Int. */
-/* i w s u w */ ARCH_DEPEND(HI(37) /* stwu */, HI(62) | ADDR_MODE2 | 0x1 /* stdu */),
-/* i w s u b */ HI(39) /* stbu */,
-/* i w s u h */ HI(45) /* sthu */,
-/* i w s u i */ HI(37) /* stwu */,
+/* u i n i s */ HI(36) /* stw */,
+/* u i n i l */ HI(32) /* lwz */,
+/* u i n x s */ HI(31) | LO(151) /* stwx */,
+/* u i n x l */ HI(31) | LO(23) /* lwzx */,
-/* i w s s w */ ARCH_DEPEND(HI(37) /* stwu */, HI(62) | ADDR_MODE2 | 0x1 /* stdu */),
-/* i w s s b */ HI(39) /* stbu */,
-/* i w s s h */ HI(45) /* sthu */,
-/* i w s s i */ HI(37) /* stwu */,
+/* u i w i s */ HI(37) /* stwu */,
+/* u i w i l */ HI(33) /* lwzu */,
+/* u i w x s */ HI(31) | LO(183) /* stwux */,
+/* u i w x l */ HI(31) | LO(55) /* lwzux */,
-/* i w l u w */ ARCH_DEPEND(HI(33) /* lwzu */, HI(58) | ADDR_MODE2 | 0x1 /* ldu */),
-/* i w l u b */ HI(35) /* lbzu */,
-/* i w l u h */ HI(41) /* lhzu */,
-/* i w l u i */ HI(33) /* lwzu */,
+/* -------- Signed -------- */
-/* i w l s w */ ARCH_DEPEND(HI(33) /* lwzu */, HI(58) | ADDR_MODE2 | 0x1 /* ldu */),
-/* i w l s b */ HI(35) /* lbzu */ /* EXTS_REQ */,
-/* i w l s h */ HI(43) /* lhau */,
-/* i w l s i */ ARCH_DEPEND(HI(33) /* lwzu */, HI(58) | ADDR_MODE2 | UPDATE_REQ | 0x2 /* lwa */),
+/* Word. */
-/* ---------- */
-/* Indexed */
-/* ---------- */
+/* s w n i s */ ARCH_32_64(HI(36) /* stw */, HI(62) | ADDR_MODE2 | 0x0 /* std */),
+/* s w n i l */ ARCH_32_64(HI(32) /* lwz */, HI(58) | ADDR_MODE2 | 0x0 /* ld */),
+/* s w n x s */ ARCH_32_64(HI(31) | LO(151) /* stwx */, HI(31) | LO(149) /* stdx */),
+/* s w n x l */ ARCH_32_64(HI(31) | LO(23) /* lwzx */, HI(31) | LO(21) /* ldx */),
-/* No write-back. */
+/* s w w i s */ ARCH_32_64(HI(37) /* stwu */, HI(62) | ADDR_MODE2 | 0x1 /* stdu */),
+/* s w w i l */ ARCH_32_64(HI(33) /* lwzu */, HI(58) | ADDR_MODE2 | 0x1 /* ldu */),
+/* s w w x s */ ARCH_32_64(HI(31) | LO(183) /* stwux */, HI(31) | LO(181) /* stdux */),
+/* s w w x l */ ARCH_32_64(HI(31) | LO(55) /* lwzux */, HI(31) | LO(53) /* ldux */),
-/* x n s u w */ ARCH_DEPEND(HI(31) | LO(151) /* stwx */, HI(31) | LO(149) /* stdx */),
-/* x n s u b */ HI(31) | LO(215) /* stbx */,
-/* x n s u h */ HI(31) | LO(407) /* sthx */,
-/* x n s u i */ HI(31) | LO(151) /* stwx */,
+/* Byte. */
-/* x n s s w */ ARCH_DEPEND(HI(31) | LO(151) /* stwx */, HI(31) | LO(149) /* stdx */),
-/* x n s s b */ HI(31) | LO(215) /* stbx */,
-/* x n s s h */ HI(31) | LO(407) /* sthx */,
-/* x n s s i */ HI(31) | LO(151) /* stwx */,
+/* s b n i s */ HI(38) /* stb */,
+/* s b n i l */ HI(34) /* lbz */ /* EXTS_REQ */,
+/* s b n x s */ HI(31) | LO(215) /* stbx */,
+/* s b n x l */ HI(31) | LO(87) /* lbzx */ /* EXTS_REQ */,
-/* x n l u w */ ARCH_DEPEND(HI(31) | LO(23) /* lwzx */, HI(31) | LO(21) /* ldx */),
-/* x n l u b */ HI(31) | LO(87) /* lbzx */,
-/* x n l u h */ HI(31) | LO(279) /* lhzx */,
-/* x n l u i */ HI(31) | LO(23) /* lwzx */,
+/* s b w i s */ HI(39) /* stbu */,
+/* s b w i l */ HI(35) /* lbzu */ /* EXTS_REQ */,
+/* s b w x s */ HI(31) | LO(247) /* stbux */,
+/* s b w x l */ HI(31) | LO(119) /* lbzux */ /* EXTS_REQ */,
-/* x n l s w */ ARCH_DEPEND(HI(31) | LO(23) /* lwzx */, HI(31) | LO(21) /* ldx */),
-/* x n l s b */ HI(31) | LO(87) /* lbzx */ /* EXTS_REQ */,
-/* x n l s h */ HI(31) | LO(343) /* lhax */,
-/* x n l s i */ ARCH_DEPEND(HI(31) | LO(23) /* lwzx */, HI(31) | LO(341) /* lwax */),
+/* Half. */
-/* Write-back. */
+/* s h n i s */ HI(44) /* sth */,
+/* s h n i l */ HI(42) /* lha */,
+/* s h n x s */ HI(31) | LO(407) /* sthx */,
+/* s h n x l */ HI(31) | LO(343) /* lhax */,
-/* x w s u w */ ARCH_DEPEND(HI(31) | LO(183) /* stwux */, HI(31) | LO(181) /* stdux */),
-/* x w s u b */ HI(31) | LO(247) /* stbux */,
-/* x w s u h */ HI(31) | LO(439) /* sthux */,
-/* x w s u i */ HI(31) | LO(183) /* stwux */,
+/* s h w i s */ HI(45) /* sthu */,
+/* s h w i l */ HI(43) /* lhau */,
+/* s h w x s */ HI(31) | LO(439) /* sthux */,
+/* s h w x l */ HI(31) | LO(375) /* lhaux */,
-/* x w s s w */ ARCH_DEPEND(HI(31) | LO(183) /* stwux */, HI(31) | LO(181) /* stdux */),
-/* x w s s b */ HI(31) | LO(247) /* stbux */,
-/* x w s s h */ HI(31) | LO(439) /* sthux */,
-/* x w s s i */ HI(31) | LO(183) /* stwux */,
+/* Int. */
-/* x w l u w */ ARCH_DEPEND(HI(31) | LO(55) /* lwzux */, HI(31) | LO(53) /* ldux */),
-/* x w l u b */ HI(31) | LO(119) /* lbzux */,
-/* x w l u h */ HI(31) | LO(311) /* lhzux */,
-/* x w l u i */ HI(31) | LO(55) /* lwzux */,
+/* s i n i s */ HI(36) /* stw */,
+/* s i n i l */ ARCH_32_64(HI(32) /* lwz */, HI(58) | ADDR_MODE2 | 0x2 /* lwa */),
+/* s i n x s */ HI(31) | LO(151) /* stwx */,
+/* s i n x l */ ARCH_32_64(HI(31) | LO(23) /* lwzx */, HI(31) | LO(341) /* lwax */),
-/* x w l s w */ ARCH_DEPEND(HI(31) | LO(55) /* lwzux */, HI(31) | LO(53) /* ldux */),
-/* x w l s b */ HI(31) | LO(119) /* lbzux */ /* EXTS_REQ */,
-/* x w l s h */ HI(31) | LO(375) /* lhaux */,
-/* x w l s i */ ARCH_DEPEND(HI(31) | LO(55) /* lwzux */, HI(31) | LO(373) /* lwaux */)
+/* s i w i s */ HI(37) /* stwu */,
+/* s i w i l */ ARCH_32_64(HI(33) /* lwzu */, HI(58) | ADDR_MODE2 | UPDATE_REQ | 0x2 /* lwa */),
+/* s i w x s */ HI(31) | LO(183) /* stwux */,
+/* s i w x l */ ARCH_32_64(HI(31) | LO(55) /* lwzux */, HI(31) | LO(373) /* lwaux */),
+
+/* -------- Double -------- */
+
+/* d n i s */ HI(54) /* stfd */,
+/* d n i l */ HI(50) /* lfd */,
+/* d n x s */ HI(31) | LO(727) /* stfdx */,
+/* d n x l */ HI(31) | LO(599) /* lfdx */,
+
+/* s n i s */ HI(52) /* stfs */,
+/* s n i l */ HI(48) /* lfs */,
+/* s n x s */ HI(31) | LO(663) /* stfsx */,
+/* s n x l */ HI(31) | LO(535) /* lfsx */,
};
-#undef ARCH_DEPEND
+#undef ARCH_32_64
/* Simple cases, (no caching is required). */
-static int getput_arg_fast(struct sljit_compiler *compiler, int inp_flags, int reg, int arg, sljit_w argw)
+static sljit_si getput_arg_fast(struct sljit_compiler *compiler, sljit_si inp_flags, sljit_si reg, sljit_si arg, sljit_sw argw)
{
sljit_ins inst;
#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
- int tmp_reg;
+ sljit_si tmp_reg;
#endif
SLJIT_ASSERT(arg & SLJIT_MEM);
@@ -690,7 +761,7 @@ static int getput_arg_fast(struct sljit_compiler *compiler, int inp_flags, int r
inst = data_transfer_insts[(inp_flags & ~WRITE_BACK) & MEM_MASK];
SLJIT_ASSERT(!(inst & (ADDR_MODE2 | UPDATE_REQ)));
- push_inst(compiler, GET_INST_CODE(inst) | D(reg) | IMM(argw));
+ push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | IMM(argw));
return -1;
}
#else
@@ -700,11 +771,11 @@ static int getput_arg_fast(struct sljit_compiler *compiler, int inp_flags, int r
if (inp_flags & ARG_TEST)
return 1;
- push_inst(compiler, GET_INST_CODE(inst) | D(reg) | IMM(argw));
+ push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | IMM(argw));
return -1;
}
#endif
- return (inp_flags & ARG_TEST) ? SLJIT_SUCCESS : 0;
+ return 0;
}
if (!(arg & 0xf0)) {
@@ -715,7 +786,7 @@ static int getput_arg_fast(struct sljit_compiler *compiler, int inp_flags, int r
inst = data_transfer_insts[inp_flags & MEM_MASK];
SLJIT_ASSERT(!(inst & (ADDR_MODE2 | UPDATE_REQ)));
- push_inst(compiler, GET_INST_CODE(inst) | D(reg) | A(arg & 0xf) | IMM(argw));
+ push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | A(arg & 0xf) | IMM(argw));
return -1;
}
#else
@@ -731,7 +802,7 @@ static int getput_arg_fast(struct sljit_compiler *compiler, int inp_flags, int r
arg = tmp_reg | SLJIT_MEM;
argw = 0;
}
- push_inst(compiler, GET_INST_CODE(inst) | D(reg) | A(arg & 0xf) | IMM(argw));
+ push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | A(arg & 0xf) | IMM(argw));
return -1;
}
#endif
@@ -741,28 +812,24 @@ static int getput_arg_fast(struct sljit_compiler *compiler, int inp_flags, int r
return 1;
inst = data_transfer_insts[(inp_flags | INDEXED) & MEM_MASK];
SLJIT_ASSERT(!(inst & (ADDR_MODE2 | UPDATE_REQ)));
- push_inst(compiler, GET_INST_CODE(inst) | D(reg) | A(arg & 0xf) | B((arg >> 4) & 0xf));
+ push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | A(arg & 0xf) | B((arg >> 4) & 0xf));
return -1;
}
- return (inp_flags & ARG_TEST) ? SLJIT_SUCCESS : 0;
+ return 0;
}
/* See getput_arg below.
Note: can_cache is called only for binary operators. Those operator always
uses word arguments without write back. */
-static int can_cache(int arg, sljit_w argw, int next_arg, sljit_w next_argw)
+static sljit_si can_cache(sljit_si arg, sljit_sw argw, sljit_si next_arg, sljit_sw next_argw)
{
- SLJIT_ASSERT(arg & SLJIT_MEM);
- SLJIT_ASSERT(next_arg & SLJIT_MEM);
+ SLJIT_ASSERT((arg & SLJIT_MEM) && (next_arg & SLJIT_MEM));
- if (!(arg & 0xf)) {
- if ((next_arg & SLJIT_MEM) && ((sljit_uw)argw - (sljit_uw)next_argw <= SIMM_MAX || (sljit_uw)next_argw - (sljit_uw)argw <= SIMM_MAX))
- return 1;
- return 0;
- }
+ if (!(arg & 0xf))
+ return (next_arg & SLJIT_MEM) && ((sljit_uw)argw - (sljit_uw)next_argw <= SIMM_MAX || (sljit_uw)next_argw - (sljit_uw)argw <= SIMM_MAX);
if (arg & 0xf0)
- return 0;
+ return ((arg & 0xf0) == (next_arg & 0xf0) && (argw & 0x3) == (next_argw & 0x3));
if (argw <= SIMM_MAX && argw >= SIMM_MIN) {
if (arg == next_arg && (next_argw >= SIMM_MAX && next_argw <= SIMM_MIN))
@@ -788,21 +855,17 @@ static int can_cache(int arg, sljit_w argw, int next_arg, sljit_w next_argw)
#endif
/* Emit the necessary instructions. See can_cache above. */
-static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, int arg, sljit_w argw, int next_arg, sljit_w next_argw)
+static sljit_si getput_arg(struct sljit_compiler *compiler, sljit_si inp_flags, sljit_si reg, sljit_si arg, sljit_sw argw, sljit_si next_arg, sljit_sw next_argw)
{
- int tmp_r;
+ sljit_si tmp_r;
sljit_ins inst;
SLJIT_ASSERT(arg & SLJIT_MEM);
- tmp_r = (inp_flags & LOAD_DATA) ? reg : TMP_REG3;
- if ((arg & 0xf) == tmp_r) {
- /* Special case for "mov reg, [reg, ... ]".
- Caching would not happen anyway. */
- tmp_r = TMP_REG3;
- compiler->cache_arg = 0;
- compiler->cache_argw = 0;
- }
+ tmp_r = ((inp_flags & LOAD_DATA) && ((inp_flags) & MEM_MASK) <= GPR_REG) ? reg : TMP_REG1;
+ /* Special case for "mov reg, [reg, ... ]". */
+ if ((arg & 0xf) == tmp_r)
+ tmp_r = TMP_REG1;
if (!(arg & 0xf)) {
inst = data_transfer_insts[(inp_flags & ~WRITE_BACK) & MEM_MASK];
@@ -810,7 +873,7 @@ static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, i
argw = argw - compiler->cache_argw;
ADJUST_CACHED_IMM(argw);
SLJIT_ASSERT(!(inst & UPDATE_REQ));
- return push_inst(compiler, GET_INST_CODE(inst) | D(reg) | A(TMP_REG3) | IMM(argw));
+ return push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | A(TMP_REG3) | IMM(argw));
}
if ((next_arg & SLJIT_MEM) && (argw - next_argw <= SIMM_MAX || next_argw - argw <= SIMM_MAX)) {
@@ -822,21 +885,31 @@ static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, i
}
FAIL_IF(load_immediate(compiler, tmp_r, argw));
- return push_inst(compiler, GET_INST_CODE(inst) | D(reg) | A(tmp_r));
+ return push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | A(tmp_r));
}
if (SLJIT_UNLIKELY(arg & 0xf0)) {
argw &= 0x3;
/* Otherwise getput_arg_fast would capture it. */
SLJIT_ASSERT(argw);
+
+ if ((SLJIT_MEM | (arg & 0xf0)) == compiler->cache_arg && argw == compiler->cache_argw)
+ tmp_r = TMP_REG3;
+ else {
+ if ((arg & 0xf0) == (next_arg & 0xf0) && argw == (next_argw & 0x3)) {
+ compiler->cache_arg = SLJIT_MEM | (arg & 0xf0);
+ compiler->cache_argw = argw;
+ tmp_r = TMP_REG3;
+ }
#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32)
- FAIL_IF(push_inst(compiler, RLWINM | S((arg >> 4) & 0xf) | A(tmp_r) | (argw << 11) | ((31 - argw) << 1)));
+ FAIL_IF(push_inst(compiler, RLWINM | S((arg >> 4) & 0xf) | A(tmp_r) | (argw << 11) | ((31 - argw) << 1)));
#else
- FAIL_IF(push_inst(compiler, RLDI(tmp_r, (arg >> 4) & 0xf, argw, 63 - argw, 1)));
+ FAIL_IF(push_inst(compiler, RLDI(tmp_r, (arg >> 4) & 0xf, argw, 63 - argw, 1)));
#endif
+ }
inst = data_transfer_insts[(inp_flags | INDEXED) & MEM_MASK];
SLJIT_ASSERT(!(inst & (ADDR_MODE2 | UPDATE_REQ)));
- return push_inst(compiler, GET_INST_CODE(inst) | D(reg) | A(arg & 0xf) | B(tmp_r));
+ return push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | A(arg & 0xf) | B(tmp_r));
}
inst = data_transfer_insts[inp_flags & MEM_MASK];
@@ -845,13 +918,13 @@ static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, i
SLJIT_ASSERT(!(inp_flags & WRITE_BACK));
argw = argw - compiler->cache_argw;
ADJUST_CACHED_IMM(argw);
- return push_inst(compiler, GET_INST_CODE(inst) | D(reg) | A(TMP_REG3) | IMM(argw));
+ return push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | A(TMP_REG3) | IMM(argw));
}
if ((compiler->cache_arg & SLJIT_IMM) && compiler->cache_argw == argw) {
inst = data_transfer_insts[(inp_flags | INDEXED) & MEM_MASK];
SLJIT_ASSERT(!(inst & (ADDR_MODE2 | UPDATE_REQ)));
- return push_inst(compiler, GET_INST_CODE(inst) | D(reg) | A(arg & 0xf) | B(TMP_REG3));
+ return push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | A(arg & 0xf) | B(TMP_REG3));
}
if (argw == next_argw && (next_arg & SLJIT_MEM)) {
@@ -863,7 +936,7 @@ static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, i
inst = data_transfer_insts[(inp_flags | INDEXED) & MEM_MASK];
SLJIT_ASSERT(!(inst & (ADDR_MODE2 | UPDATE_REQ)));
- return push_inst(compiler, GET_INST_CODE(inst) | D(reg) | A(arg & 0xf) | B(TMP_REG3));
+ return push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | A(arg & 0xf) | B(TMP_REG3));
}
if (arg == next_arg && !(inp_flags & WRITE_BACK) && ((sljit_uw)argw - (sljit_uw)next_argw <= SIMM_MAX || (sljit_uw)next_argw - (sljit_uw)argw <= SIMM_MAX)) {
@@ -874,49 +947,58 @@ static int getput_arg(struct sljit_compiler *compiler, int inp_flags, int reg, i
compiler->cache_arg = arg;
compiler->cache_argw = argw;
- return push_inst(compiler, GET_INST_CODE(inst) | D(reg) | A(TMP_REG3));
+ return push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | A(TMP_REG3));
}
/* Get the indexed version instead of the normal one. */
inst = data_transfer_insts[(inp_flags | INDEXED) & MEM_MASK];
SLJIT_ASSERT(!(inst & (ADDR_MODE2 | UPDATE_REQ)));
FAIL_IF(load_immediate(compiler, tmp_r, argw));
- return push_inst(compiler, GET_INST_CODE(inst) | D(reg) | A(arg & 0xf) | B(tmp_r));
+ return push_inst(compiler, INST_CODE_AND_DST(inst, inp_flags, reg) | A(arg & 0xf) | B(tmp_r));
}
-static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+static SLJIT_INLINE sljit_si emit_op_mem2(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg1, sljit_sw arg1w, sljit_si arg2, sljit_sw arg2w)
+{
+ if (getput_arg_fast(compiler, flags, reg, arg1, arg1w))
+ return compiler->error;
+ return getput_arg(compiler, flags, reg, arg1, arg1w, arg2, arg2w);
+}
+
+static sljit_si emit_op(struct sljit_compiler *compiler, sljit_si op, sljit_si input_flags,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
/* arg1 goes to TMP_REG1 or src reg
arg2 goes to TMP_REG2, imm or src reg
TMP_REG3 can be used for caching
result goes to TMP_REG2, so put result can use TMP_REG1 and TMP_REG3. */
- int dst_r;
- int src1_r;
- int src2_r;
- int sugg_src2_r = TMP_REG2;
- int flags = inp_flags & (ALT_FORM1 | ALT_FORM2 | ALT_FORM3 | ALT_FORM4 | ALT_FORM5 | ALT_FORM6 | ALT_SIGN_EXT | ALT_SET_FLAGS);
+ sljit_si dst_r;
+ sljit_si src1_r;
+ sljit_si src2_r;
+ sljit_si sugg_src2_r = TMP_REG2;
+ sljit_si flags = input_flags & (ALT_FORM1 | ALT_FORM2 | ALT_FORM3 | ALT_FORM4 | ALT_FORM5 | ALT_FORM6 | ALT_SIGN_EXT | ALT_SET_FLAGS);
- compiler->cache_arg = 0;
- compiler->cache_argw = 0;
+ if (!(input_flags & ALT_KEEP_CACHE)) {
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+ }
/* Destination check. */
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= ZERO_REG) {
+ if (SLJIT_UNLIKELY(dst == SLJIT_UNUSED)) {
+ if (op >= SLJIT_MOV && op <= SLJIT_MOVU_SI && !(src2 & SLJIT_MEM))
+ return SLJIT_SUCCESS;
+ dst_r = TMP_REG2;
+ }
+ else if (dst <= ZERO_REG) {
dst_r = dst;
flags |= REG_DEST;
if (op >= SLJIT_MOV && op <= SLJIT_MOVU_SI)
sugg_src2_r = dst_r;
}
- else if (dst == SLJIT_UNUSED) {
- if (op >= SLJIT_MOV && op <= SLJIT_MOVU_SI && !(src2 & SLJIT_MEM))
- return SLJIT_SUCCESS;
- dst_r = TMP_REG2;
- }
else {
SLJIT_ASSERT(dst & SLJIT_MEM);
- if (getput_arg_fast(compiler, inp_flags | ARG_TEST, TMP_REG2, dst, dstw)) {
+ if (getput_arg_fast(compiler, input_flags | ARG_TEST, TMP_REG2, dst, dstw)) {
flags |= FAST_DEST;
dst_r = TMP_REG2;
}
@@ -927,23 +1009,15 @@ static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
}
/* Source 1. */
- if (src1 >= SLJIT_TEMPORARY_REG1 && src1 <= ZERO_REG) {
+ if (src1 <= ZERO_REG) {
src1_r = src1;
flags |= REG1_SOURCE;
}
else if (src1 & SLJIT_IMM) {
-#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
- if ((inp_flags & 0x3) == INT_DATA) {
- if (inp_flags & SIGNED_DATA)
- src1w = (signed int)src1w;
- else
- src1w = (unsigned int)src1w;
- }
-#endif
FAIL_IF(load_immediate(compiler, TMP_REG1, src1w));
src1_r = TMP_REG1;
}
- else if (getput_arg_fast(compiler, inp_flags | LOAD_DATA, TMP_REG1, src1, src1w)) {
+ else if (getput_arg_fast(compiler, input_flags | LOAD_DATA, TMP_REG1, src1, src1w)) {
FAIL_IF(compiler->error);
src1_r = TMP_REG1;
}
@@ -951,25 +1025,17 @@ static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
src1_r = 0;
/* Source 2. */
- if (src2 >= SLJIT_TEMPORARY_REG1 && src2 <= ZERO_REG) {
+ if (src2 <= ZERO_REG) {
src2_r = src2;
flags |= REG2_SOURCE;
if (!(flags & REG_DEST) && op >= SLJIT_MOV && op <= SLJIT_MOVU_SI)
dst_r = src2_r;
}
else if (src2 & SLJIT_IMM) {
-#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
- if ((inp_flags & 0x3) == INT_DATA) {
- if (inp_flags & SIGNED_DATA)
- src2w = (signed int)src2w;
- else
- src2w = (unsigned int)src2w;
- }
-#endif
FAIL_IF(load_immediate(compiler, sugg_src2_r, src2w));
src2_r = sugg_src2_r;
}
- else if (getput_arg_fast(compiler, inp_flags | LOAD_DATA, sugg_src2_r, src2, src2w)) {
+ else if (getput_arg_fast(compiler, input_flags | LOAD_DATA, sugg_src2_r, src2, src2w)) {
FAIL_IF(compiler->error);
src2_r = sugg_src2_r;
}
@@ -980,26 +1046,26 @@ static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
All arguments are complex addressing modes, and it is a binary operator. */
if (src1_r == 0 && src2_r == 0 && dst_r == 0) {
if (!can_cache(src1, src1w, src2, src2w) && can_cache(src1, src1w, dst, dstw)) {
- FAIL_IF(getput_arg(compiler, inp_flags | LOAD_DATA, TMP_REG2, src2, src2w, src1, src1w));
- FAIL_IF(getput_arg(compiler, inp_flags | LOAD_DATA, TMP_REG1, src1, src1w, dst, dstw));
+ FAIL_IF(getput_arg(compiler, input_flags | LOAD_DATA, TMP_REG2, src2, src2w, src1, src1w));
+ FAIL_IF(getput_arg(compiler, input_flags | LOAD_DATA, TMP_REG1, src1, src1w, dst, dstw));
}
else {
- FAIL_IF(getput_arg(compiler, inp_flags | LOAD_DATA, TMP_REG1, src1, src1w, src2, src2w));
- FAIL_IF(getput_arg(compiler, inp_flags | LOAD_DATA, TMP_REG2, src2, src2w, dst, dstw));
+ FAIL_IF(getput_arg(compiler, input_flags | LOAD_DATA, TMP_REG1, src1, src1w, src2, src2w));
+ FAIL_IF(getput_arg(compiler, input_flags | LOAD_DATA, TMP_REG2, src2, src2w, dst, dstw));
}
src1_r = TMP_REG1;
src2_r = TMP_REG2;
}
else if (src1_r == 0 && src2_r == 0) {
- FAIL_IF(getput_arg(compiler, inp_flags | LOAD_DATA, TMP_REG1, src1, src1w, src2, src2w));
+ FAIL_IF(getput_arg(compiler, input_flags | LOAD_DATA, TMP_REG1, src1, src1w, src2, src2w));
src1_r = TMP_REG1;
}
else if (src1_r == 0 && dst_r == 0) {
- FAIL_IF(getput_arg(compiler, inp_flags | LOAD_DATA, TMP_REG1, src1, src1w, dst, dstw));
+ FAIL_IF(getput_arg(compiler, input_flags | LOAD_DATA, TMP_REG1, src1, src1w, dst, dstw));
src1_r = TMP_REG1;
}
else if (src2_r == 0 && dst_r == 0) {
- FAIL_IF(getput_arg(compiler, inp_flags | LOAD_DATA, sugg_src2_r, src2, src2w, dst, dstw));
+ FAIL_IF(getput_arg(compiler, input_flags | LOAD_DATA, sugg_src2_r, src2, src2w, dst, dstw));
src2_r = sugg_src2_r;
}
@@ -1007,12 +1073,12 @@ static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
dst_r = TMP_REG2;
if (src1_r == 0) {
- FAIL_IF(getput_arg(compiler, inp_flags | LOAD_DATA, TMP_REG1, src1, src1w, 0, 0));
+ FAIL_IF(getput_arg(compiler, input_flags | LOAD_DATA, TMP_REG1, src1, src1w, 0, 0));
src1_r = TMP_REG1;
}
if (src2_r == 0) {
- FAIL_IF(getput_arg(compiler, inp_flags | LOAD_DATA, sugg_src2_r, src2, src2w, 0, 0));
+ FAIL_IF(getput_arg(compiler, input_flags | LOAD_DATA, sugg_src2_r, src2, src2w, 0, 0));
src2_r = sugg_src2_r;
}
@@ -1020,14 +1086,14 @@ static int emit_op(struct sljit_compiler *compiler, int op, int inp_flags,
if (flags & (FAST_DEST | SLOW_DEST)) {
if (flags & FAST_DEST)
- FAIL_IF(getput_arg_fast(compiler, inp_flags, dst_r, dst, dstw));
+ FAIL_IF(getput_arg_fast(compiler, input_flags, dst_r, dst, dstw));
else
- FAIL_IF(getput_arg(compiler, inp_flags, dst_r, dst, dstw, 0, 0));
+ FAIL_IF(getput_arg(compiler, input_flags, dst_r, dst, dstw, 0, 0));
}
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int op)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op)
{
CHECK_ERROR();
check_sljit_emit_op0(compiler, op);
@@ -1039,118 +1105,161 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
break;
case SLJIT_UMUL:
case SLJIT_SMUL:
- FAIL_IF(push_inst(compiler, OR | S(SLJIT_TEMPORARY_REG1) | A(TMP_REG1) | B(SLJIT_TEMPORARY_REG1)));
+ FAIL_IF(push_inst(compiler, OR | S(SLJIT_SCRATCH_REG1) | A(TMP_REG1) | B(SLJIT_SCRATCH_REG1)));
#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
- FAIL_IF(push_inst(compiler, MULLD | D(SLJIT_TEMPORARY_REG1) | A(TMP_REG1) | B(SLJIT_TEMPORARY_REG2)));
- return push_inst(compiler, (GET_OPCODE(op) == SLJIT_UMUL ? MULHDU : MULHD) | D(SLJIT_TEMPORARY_REG2) | A(TMP_REG1) | B(SLJIT_TEMPORARY_REG2));
+ FAIL_IF(push_inst(compiler, MULLD | D(SLJIT_SCRATCH_REG1) | A(TMP_REG1) | B(SLJIT_SCRATCH_REG2)));
+ return push_inst(compiler, (GET_OPCODE(op) == SLJIT_UMUL ? MULHDU : MULHD) | D(SLJIT_SCRATCH_REG2) | A(TMP_REG1) | B(SLJIT_SCRATCH_REG2));
#else
- FAIL_IF(push_inst(compiler, MULLW | D(SLJIT_TEMPORARY_REG1) | A(TMP_REG1) | B(SLJIT_TEMPORARY_REG2)));
- return push_inst(compiler, (GET_OPCODE(op) == SLJIT_UMUL ? MULHWU : MULHW) | D(SLJIT_TEMPORARY_REG2) | A(TMP_REG1) | B(SLJIT_TEMPORARY_REG2));
+ FAIL_IF(push_inst(compiler, MULLW | D(SLJIT_SCRATCH_REG1) | A(TMP_REG1) | B(SLJIT_SCRATCH_REG2)));
+ return push_inst(compiler, (GET_OPCODE(op) == SLJIT_UMUL ? MULHWU : MULHW) | D(SLJIT_SCRATCH_REG2) | A(TMP_REG1) | B(SLJIT_SCRATCH_REG2));
#endif
case SLJIT_UDIV:
case SLJIT_SDIV:
- FAIL_IF(push_inst(compiler, OR | S(SLJIT_TEMPORARY_REG1) | A(TMP_REG1) | B(SLJIT_TEMPORARY_REG1)));
+ FAIL_IF(push_inst(compiler, OR | S(SLJIT_SCRATCH_REG1) | A(TMP_REG1) | B(SLJIT_SCRATCH_REG1)));
#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
if (op & SLJIT_INT_OP) {
- FAIL_IF(push_inst(compiler, (GET_OPCODE(op) == SLJIT_UDIV ? DIVWU : DIVW) | D(SLJIT_TEMPORARY_REG1) | A(TMP_REG1) | B(SLJIT_TEMPORARY_REG2)));
- FAIL_IF(push_inst(compiler, MULLW | D(SLJIT_TEMPORARY_REG2) | A(SLJIT_TEMPORARY_REG1) | B(SLJIT_TEMPORARY_REG2)));
- return push_inst(compiler, SUBF | D(SLJIT_TEMPORARY_REG2) | A(SLJIT_TEMPORARY_REG2) | B(TMP_REG1));
+ FAIL_IF(push_inst(compiler, (GET_OPCODE(op) == SLJIT_UDIV ? DIVWU : DIVW) | D(SLJIT_SCRATCH_REG1) | A(TMP_REG1) | B(SLJIT_SCRATCH_REG2)));
+ FAIL_IF(push_inst(compiler, MULLW | D(SLJIT_SCRATCH_REG2) | A(SLJIT_SCRATCH_REG1) | B(SLJIT_SCRATCH_REG2)));
+ return push_inst(compiler, SUBF | D(SLJIT_SCRATCH_REG2) | A(SLJIT_SCRATCH_REG2) | B(TMP_REG1));
}
- FAIL_IF(push_inst(compiler, (GET_OPCODE(op) == SLJIT_UDIV ? DIVDU : DIVD) | D(SLJIT_TEMPORARY_REG1) | A(TMP_REG1) | B(SLJIT_TEMPORARY_REG2)));
- FAIL_IF(push_inst(compiler, MULLD | D(SLJIT_TEMPORARY_REG2) | A(SLJIT_TEMPORARY_REG1) | B(SLJIT_TEMPORARY_REG2)));
- return push_inst(compiler, SUBF | D(SLJIT_TEMPORARY_REG2) | A(SLJIT_TEMPORARY_REG2) | B(TMP_REG1));
+ FAIL_IF(push_inst(compiler, (GET_OPCODE(op) == SLJIT_UDIV ? DIVDU : DIVD) | D(SLJIT_SCRATCH_REG1) | A(TMP_REG1) | B(SLJIT_SCRATCH_REG2)));
+ FAIL_IF(push_inst(compiler, MULLD | D(SLJIT_SCRATCH_REG2) | A(SLJIT_SCRATCH_REG1) | B(SLJIT_SCRATCH_REG2)));
+ return push_inst(compiler, SUBF | D(SLJIT_SCRATCH_REG2) | A(SLJIT_SCRATCH_REG2) | B(TMP_REG1));
#else
- FAIL_IF(push_inst(compiler, (GET_OPCODE(op) == SLJIT_UDIV ? DIVWU : DIVW) | D(SLJIT_TEMPORARY_REG1) | A(TMP_REG1) | B(SLJIT_TEMPORARY_REG2)));
- FAIL_IF(push_inst(compiler, MULLW | D(SLJIT_TEMPORARY_REG2) | A(SLJIT_TEMPORARY_REG1) | B(SLJIT_TEMPORARY_REG2)));
- return push_inst(compiler, SUBF | D(SLJIT_TEMPORARY_REG2) | A(SLJIT_TEMPORARY_REG2) | B(TMP_REG1));
+ FAIL_IF(push_inst(compiler, (GET_OPCODE(op) == SLJIT_UDIV ? DIVWU : DIVW) | D(SLJIT_SCRATCH_REG1) | A(TMP_REG1) | B(SLJIT_SCRATCH_REG2)));
+ FAIL_IF(push_inst(compiler, MULLW | D(SLJIT_SCRATCH_REG2) | A(SLJIT_SCRATCH_REG1) | B(SLJIT_SCRATCH_REG2)));
+ return push_inst(compiler, SUBF | D(SLJIT_SCRATCH_REG2) | A(SLJIT_SCRATCH_REG2) | B(TMP_REG1));
#endif
}
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+#define EMIT_MOV(type, type_flags, type_cast) \
+ emit_op(compiler, (src & SLJIT_IMM) ? SLJIT_MOV : type, flags | (type_flags), dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? type_cast srcw : srcw)
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- int inp_flags = GET_FLAGS(op) ? ALT_SET_FLAGS : 0;
+ sljit_si flags = GET_FLAGS(op) ? ALT_SET_FLAGS : 0;
+ sljit_si op_flags = GET_ALL_FLAGS(op);
CHECK_ERROR();
check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
+ op = GET_OPCODE(op);
if ((src & SLJIT_IMM) && srcw == 0)
src = ZERO_REG;
+ if (op_flags & SLJIT_SET_O)
+ FAIL_IF(push_inst(compiler, MTXER | S(ZERO_REG)));
+
+ if (op_flags & SLJIT_INT_OP) {
+ if (op >= SLJIT_MOV && op <= SLJIT_MOVU_P) {
+ if (src <= ZERO_REG && src == dst) {
+ if (!TYPE_CAST_NEEDED(op))
+ return SLJIT_SUCCESS;
+ }
#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
- if (op & SLJIT_INT_OP) {
- inp_flags |= INT_DATA | SIGNED_DATA;
- if (src & SLJIT_IMM)
- srcw = (int)srcw;
- }
+ if (op == SLJIT_MOV_SI && (src & SLJIT_MEM))
+ op = SLJIT_MOV_UI;
+ if (op == SLJIT_MOVU_SI && (src & SLJIT_MEM))
+ op = SLJIT_MOVU_UI;
+ if (op == SLJIT_MOV_UI && (src & SLJIT_IMM))
+ op = SLJIT_MOV_SI;
+ if (op == SLJIT_MOVU_UI && (src & SLJIT_IMM))
+ op = SLJIT_MOVU_SI;
#endif
- if (op & SLJIT_SET_O)
- FAIL_IF(push_inst(compiler, MTXER | S(ZERO_REG)));
+ }
+#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
+ else {
+ /* Most operations expect sign extended arguments. */
+ flags |= INT_DATA | SIGNED_DATA;
+ if (src & SLJIT_IMM)
+ srcw = (sljit_si)srcw;
+ }
+#endif
+ }
- switch (GET_OPCODE(op)) {
+ switch (op) {
case SLJIT_MOV:
- return emit_op(compiler, SLJIT_MOV, inp_flags | WORD_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
+ case SLJIT_MOV_P:
+#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32)
+ case SLJIT_MOV_UI:
+ case SLJIT_MOV_SI:
+#endif
+ return emit_op(compiler, SLJIT_MOV, flags | WORD_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
+#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
case SLJIT_MOV_UI:
- return emit_op(compiler, SLJIT_MOV_UI, inp_flags | INT_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
+ return EMIT_MOV(SLJIT_MOV_UI, INT_DATA, (sljit_ui));
case SLJIT_MOV_SI:
- return emit_op(compiler, SLJIT_MOV_SI, inp_flags | INT_DATA | SIGNED_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
+ return EMIT_MOV(SLJIT_MOV_SI, INT_DATA | SIGNED_DATA, (sljit_si));
+#endif
case SLJIT_MOV_UB:
- return emit_op(compiler, SLJIT_MOV_UB, inp_flags | BYTE_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (unsigned char)srcw : srcw);
+ return EMIT_MOV(SLJIT_MOV_UB, BYTE_DATA, (sljit_ub));
case SLJIT_MOV_SB:
- return emit_op(compiler, SLJIT_MOV_SB, inp_flags | BYTE_DATA | SIGNED_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (signed char)srcw : srcw);
+ return EMIT_MOV(SLJIT_MOV_SB, BYTE_DATA | SIGNED_DATA, (sljit_sb));
case SLJIT_MOV_UH:
- return emit_op(compiler, SLJIT_MOV_UH, inp_flags | HALF_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (unsigned short)srcw : srcw);
+ return EMIT_MOV(SLJIT_MOV_UH, HALF_DATA, (sljit_uh));
case SLJIT_MOV_SH:
- return emit_op(compiler, SLJIT_MOV_SH, inp_flags | HALF_DATA | SIGNED_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (signed short)srcw : srcw);
+ return EMIT_MOV(SLJIT_MOV_SH, HALF_DATA | SIGNED_DATA, (sljit_sh));
case SLJIT_MOVU:
- return emit_op(compiler, SLJIT_MOV, inp_flags | WORD_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
+ case SLJIT_MOVU_P:
+#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32)
+ case SLJIT_MOVU_UI:
+ case SLJIT_MOVU_SI:
+#endif
+ return emit_op(compiler, SLJIT_MOV, flags | WORD_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
+#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
case SLJIT_MOVU_UI:
- return emit_op(compiler, SLJIT_MOV_UI, inp_flags | INT_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
+ return EMIT_MOV(SLJIT_MOV_UI, INT_DATA | WRITE_BACK, (sljit_ui));
case SLJIT_MOVU_SI:
- return emit_op(compiler, SLJIT_MOV_SI, inp_flags | INT_DATA | SIGNED_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
+ return EMIT_MOV(SLJIT_MOV_SI, INT_DATA | SIGNED_DATA | WRITE_BACK, (sljit_si));
+#endif
case SLJIT_MOVU_UB:
- return emit_op(compiler, SLJIT_MOV_UB, inp_flags | BYTE_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (unsigned char)srcw : srcw);
+ return EMIT_MOV(SLJIT_MOV_UB, BYTE_DATA | WRITE_BACK, (sljit_ub));
case SLJIT_MOVU_SB:
- return emit_op(compiler, SLJIT_MOV_SB, inp_flags | BYTE_DATA | SIGNED_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (signed char)srcw : srcw);
+ return EMIT_MOV(SLJIT_MOV_SB, BYTE_DATA | SIGNED_DATA | WRITE_BACK, (sljit_sb));
case SLJIT_MOVU_UH:
- return emit_op(compiler, SLJIT_MOV_UH, inp_flags | HALF_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (unsigned short)srcw : srcw);
+ return EMIT_MOV(SLJIT_MOV_UH, HALF_DATA | WRITE_BACK, (sljit_uh));
case SLJIT_MOVU_SH:
- return emit_op(compiler, SLJIT_MOV_SH, inp_flags | HALF_DATA | SIGNED_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (signed short)srcw : srcw);
+ return EMIT_MOV(SLJIT_MOV_SH, HALF_DATA | SIGNED_DATA | WRITE_BACK, (sljit_sh));
case SLJIT_NOT:
- return emit_op(compiler, SLJIT_NOT, inp_flags, dst, dstw, TMP_REG1, 0, src, srcw);
+ return emit_op(compiler, SLJIT_NOT, flags, dst, dstw, TMP_REG1, 0, src, srcw);
case SLJIT_NEG:
- return emit_op(compiler, SLJIT_NEG, inp_flags, dst, dstw, TMP_REG1, 0, src, srcw);
+ return emit_op(compiler, SLJIT_NEG, flags, dst, dstw, TMP_REG1, 0, src, srcw);
case SLJIT_CLZ:
#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
- return emit_op(compiler, SLJIT_CLZ, inp_flags | (!(op & SLJIT_INT_OP) ? 0 : ALT_FORM1), dst, dstw, TMP_REG1, 0, src, srcw);
+ return emit_op(compiler, SLJIT_CLZ, flags | (!(op_flags & SLJIT_INT_OP) ? 0 : ALT_FORM1), dst, dstw, TMP_REG1, 0, src, srcw);
#else
- return emit_op(compiler, SLJIT_CLZ, inp_flags, dst, dstw, TMP_REG1, 0, src, srcw);
+ return emit_op(compiler, SLJIT_CLZ, flags, dst, dstw, TMP_REG1, 0, src, srcw);
#endif
}
return SLJIT_SUCCESS;
}
+#undef EMIT_MOV
+
#define TEST_SL_IMM(src, srcw) \
(((src) & SLJIT_IMM) && (srcw) <= SIMM_MAX && (srcw) >= SIMM_MIN)
@@ -1184,15 +1293,18 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int
((src) & SLJIT_IMM)
#endif
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- int inp_flags = GET_FLAGS(op) ? ALT_SET_FLAGS : 0;
+ sljit_si flags = GET_FLAGS(op) ? ALT_SET_FLAGS : 0;
CHECK_ERROR();
check_sljit_emit_op2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src1, src1w);
+ ADJUST_LOCAL_OFFSET(src2, src2w);
if ((src1 & SLJIT_IMM) && src1w == 0)
src1 = ZERO_REG;
@@ -1201,80 +1313,83 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int
#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
if (op & SLJIT_INT_OP) {
- inp_flags |= INT_DATA | SIGNED_DATA;
+ /* Most operations expect sign extended arguments. */
+ flags |= INT_DATA | SIGNED_DATA;
if (src1 & SLJIT_IMM)
- src1w = (src1w << 32) >> 32;
+ src1w = (sljit_si)(src1w);
if (src2 & SLJIT_IMM)
- src2w = (src2w << 32) >> 32;
+ src2w = (sljit_si)(src2w);
if (GET_FLAGS(op))
- inp_flags |= ALT_SIGN_EXT;
+ flags |= ALT_SIGN_EXT;
}
#endif
if (op & SLJIT_SET_O)
FAIL_IF(push_inst(compiler, MTXER | S(ZERO_REG)));
+ if (src2 == TMP_REG2)
+ flags |= ALT_KEEP_CACHE;
switch (GET_OPCODE(op)) {
case SLJIT_ADD:
if (!GET_FLAGS(op) && ((src1 | src2) & SLJIT_IMM)) {
if (TEST_SL_IMM(src2, src2w)) {
compiler->imm = src2w & 0xffff;
- return emit_op(compiler, SLJIT_ADD, inp_flags | ALT_FORM1, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_ADD, flags | ALT_FORM1, dst, dstw, src1, src1w, TMP_REG2, 0);
}
if (TEST_SL_IMM(src1, src1w)) {
compiler->imm = src1w & 0xffff;
- return emit_op(compiler, SLJIT_ADD, inp_flags | ALT_FORM1, dst, dstw, src2, src2w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_ADD, flags | ALT_FORM1, dst, dstw, src2, src2w, TMP_REG2, 0);
}
if (TEST_SH_IMM(src2, src2w)) {
compiler->imm = (src2w >> 16) & 0xffff;
- return emit_op(compiler, SLJIT_ADD, inp_flags | ALT_FORM2, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_ADD, flags | ALT_FORM2, dst, dstw, src1, src1w, TMP_REG2, 0);
}
if (TEST_SH_IMM(src1, src1w)) {
compiler->imm = (src1w >> 16) & 0xffff;
- return emit_op(compiler, SLJIT_ADD, inp_flags | ALT_FORM2, dst, dstw, src2, src2w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_ADD, flags | ALT_FORM2, dst, dstw, src2, src2w, TMP_REG2, 0);
}
/* Range between -1 and -32768 is covered above. */
if (TEST_ADD_IMM(src2, src2w)) {
compiler->imm = src2w & 0xffffffff;
- return emit_op(compiler, SLJIT_ADD, inp_flags | ALT_FORM4, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_ADD, flags | ALT_FORM4, dst, dstw, src1, src1w, TMP_REG2, 0);
}
if (TEST_ADD_IMM(src1, src1w)) {
compiler->imm = src1w & 0xffffffff;
- return emit_op(compiler, SLJIT_ADD, inp_flags | ALT_FORM4, dst, dstw, src2, src2w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_ADD, flags | ALT_FORM4, dst, dstw, src2, src2w, TMP_REG2, 0);
}
}
if (!(GET_FLAGS(op) & (SLJIT_SET_E | SLJIT_SET_O))) {
if (TEST_SL_IMM(src2, src2w)) {
compiler->imm = src2w & 0xffff;
- return emit_op(compiler, SLJIT_ADD, inp_flags | ALT_FORM3, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_ADD, flags | ALT_FORM3, dst, dstw, src1, src1w, TMP_REG2, 0);
}
if (TEST_SL_IMM(src1, src1w)) {
compiler->imm = src1w & 0xffff;
- return emit_op(compiler, SLJIT_ADD, inp_flags | ALT_FORM3, dst, dstw, src2, src2w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_ADD, flags | ALT_FORM3, dst, dstw, src2, src2w, TMP_REG2, 0);
}
}
- return emit_op(compiler, SLJIT_ADD, inp_flags, dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, SLJIT_ADD, flags, dst, dstw, src1, src1w, src2, src2w);
case SLJIT_ADDC:
- return emit_op(compiler, SLJIT_ADDC, inp_flags | (!(op & SLJIT_KEEP_FLAGS) ? 0 : ALT_FORM1), dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, SLJIT_ADDC, flags | (!(op & SLJIT_KEEP_FLAGS) ? 0 : ALT_FORM1), dst, dstw, src1, src1w, src2, src2w);
case SLJIT_SUB:
if (!GET_FLAGS(op) && ((src1 | src2) & SLJIT_IMM)) {
if (TEST_SL_IMM(src2, -src2w)) {
compiler->imm = (-src2w) & 0xffff;
- return emit_op(compiler, SLJIT_ADD, inp_flags | ALT_FORM1, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_ADD, flags | ALT_FORM1, dst, dstw, src1, src1w, TMP_REG2, 0);
}
if (TEST_SL_IMM(src1, src1w)) {
compiler->imm = src1w & 0xffff;
- return emit_op(compiler, SLJIT_SUB, inp_flags | ALT_FORM1, dst, dstw, src2, src2w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_SUB, flags | ALT_FORM1, dst, dstw, src2, src2w, TMP_REG2, 0);
}
if (TEST_SH_IMM(src2, -src2w)) {
compiler->imm = ((-src2w) >> 16) & 0xffff;
- return emit_op(compiler, SLJIT_ADD, inp_flags | ALT_FORM2, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_ADD, flags | ALT_FORM2, dst, dstw, src1, src1w, TMP_REG2, 0);
}
/* Range between -1 and -32768 is covered above. */
if (TEST_ADD_IMM(src2, -src2w)) {
compiler->imm = -src2w & 0xffffffff;
- return emit_op(compiler, SLJIT_ADD, inp_flags | ALT_FORM4, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_ADD, flags | ALT_FORM4, dst, dstw, src1, src1w, TMP_REG2, 0);
}
}
if (dst == SLJIT_UNUSED && (op & (SLJIT_SET_E | SLJIT_SET_S | SLJIT_SET_U)) && !(op & (SLJIT_SET_O | SLJIT_SET_C))) {
@@ -1282,55 +1397,55 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int
/* We know ALT_SIGN_EXT is set if it is an SLJIT_INT_OP on 64 bit systems. */
if (TEST_SL_IMM(src2, src2w)) {
compiler->imm = src2w & 0xffff;
- return emit_op(compiler, SLJIT_SUB, inp_flags | ALT_FORM2, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_SUB, flags | ALT_FORM2, dst, dstw, src1, src1w, TMP_REG2, 0);
}
if (GET_FLAGS(op) == SLJIT_SET_E && TEST_SL_IMM(src1, src1w)) {
compiler->imm = src1w & 0xffff;
- return emit_op(compiler, SLJIT_SUB, inp_flags | ALT_FORM2, dst, dstw, src2, src2w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_SUB, flags | ALT_FORM2, dst, dstw, src2, src2w, TMP_REG2, 0);
}
}
if (!(op & (SLJIT_SET_E | SLJIT_SET_S))) {
/* We know ALT_SIGN_EXT is set if it is an SLJIT_INT_OP on 64 bit systems. */
if (TEST_UL_IMM(src2, src2w)) {
compiler->imm = src2w & 0xffff;
- return emit_op(compiler, SLJIT_SUB, inp_flags | ALT_FORM3, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_SUB, flags | ALT_FORM3, dst, dstw, src1, src1w, TMP_REG2, 0);
}
- return emit_op(compiler, SLJIT_SUB, inp_flags | ALT_FORM4, dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, SLJIT_SUB, flags | ALT_FORM4, dst, dstw, src1, src1w, src2, src2w);
}
if ((src2 & SLJIT_IMM) && src2w >= 0 && src2w <= 0x7fff) {
compiler->imm = src2w;
- return emit_op(compiler, SLJIT_SUB, inp_flags | ALT_FORM2 | ALT_FORM3, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_SUB, flags | ALT_FORM2 | ALT_FORM3, dst, dstw, src1, src1w, TMP_REG2, 0);
}
- return emit_op(compiler, SLJIT_SUB, inp_flags | ((op & SLJIT_SET_U) ? ALT_FORM4 : 0) | ((op & (SLJIT_SET_E | SLJIT_SET_S)) ? ALT_FORM5 : 0), dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, SLJIT_SUB, flags | ((op & SLJIT_SET_U) ? ALT_FORM4 : 0) | ((op & (SLJIT_SET_E | SLJIT_SET_S)) ? ALT_FORM5 : 0), dst, dstw, src1, src1w, src2, src2w);
}
if (!(op & (SLJIT_SET_E | SLJIT_SET_S | SLJIT_SET_U | SLJIT_SET_O))) {
if (TEST_SL_IMM(src2, -src2w)) {
compiler->imm = (-src2w) & 0xffff;
- return emit_op(compiler, SLJIT_ADD, inp_flags | ALT_FORM3, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_ADD, flags | ALT_FORM3, dst, dstw, src1, src1w, TMP_REG2, 0);
}
}
/* We know ALT_SIGN_EXT is set if it is an SLJIT_INT_OP on 64 bit systems. */
- return emit_op(compiler, SLJIT_SUB, inp_flags | (!(op & SLJIT_SET_U) ? 0 : ALT_FORM6), dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, SLJIT_SUB, flags | (!(op & SLJIT_SET_U) ? 0 : ALT_FORM6), dst, dstw, src1, src1w, src2, src2w);
case SLJIT_SUBC:
- return emit_op(compiler, SLJIT_SUBC, inp_flags | (!(op & SLJIT_KEEP_FLAGS) ? 0 : ALT_FORM1), dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, SLJIT_SUBC, flags | (!(op & SLJIT_KEEP_FLAGS) ? 0 : ALT_FORM1), dst, dstw, src1, src1w, src2, src2w);
case SLJIT_MUL:
#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
if (op & SLJIT_INT_OP)
- inp_flags |= ALT_FORM2;
+ flags |= ALT_FORM2;
#endif
if (!GET_FLAGS(op)) {
if (TEST_SL_IMM(src2, src2w)) {
compiler->imm = src2w & 0xffff;
- return emit_op(compiler, SLJIT_MUL, inp_flags | ALT_FORM1, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_MUL, flags | ALT_FORM1, dst, dstw, src1, src1w, TMP_REG2, 0);
}
if (TEST_SL_IMM(src1, src1w)) {
compiler->imm = src1w & 0xffff;
- return emit_op(compiler, SLJIT_MUL, inp_flags | ALT_FORM1, dst, dstw, src2, src2w, TMP_REG2, 0);
+ return emit_op(compiler, SLJIT_MUL, flags | ALT_FORM1, dst, dstw, src2, src2w, TMP_REG2, 0);
}
}
- return emit_op(compiler, SLJIT_MUL, inp_flags, dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, SLJIT_MUL, flags, dst, dstw, src1, src1w, src2, src2w);
case SLJIT_AND:
case SLJIT_OR:
@@ -1339,58 +1454,61 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int
if (!GET_FLAGS(op) || GET_OPCODE(op) == SLJIT_AND) {
if (TEST_UL_IMM(src2, src2w)) {
compiler->imm = src2w;
- return emit_op(compiler, GET_OPCODE(op), inp_flags | ALT_FORM1, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, GET_OPCODE(op), flags | ALT_FORM1, dst, dstw, src1, src1w, TMP_REG2, 0);
}
if (TEST_UL_IMM(src1, src1w)) {
compiler->imm = src1w;
- return emit_op(compiler, GET_OPCODE(op), inp_flags | ALT_FORM1, dst, dstw, src2, src2w, TMP_REG2, 0);
+ return emit_op(compiler, GET_OPCODE(op), flags | ALT_FORM1, dst, dstw, src2, src2w, TMP_REG2, 0);
}
if (TEST_UH_IMM(src2, src2w)) {
compiler->imm = (src2w >> 16) & 0xffff;
- return emit_op(compiler, GET_OPCODE(op), inp_flags | ALT_FORM2, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, GET_OPCODE(op), flags | ALT_FORM2, dst, dstw, src1, src1w, TMP_REG2, 0);
}
if (TEST_UH_IMM(src1, src1w)) {
compiler->imm = (src1w >> 16) & 0xffff;
- return emit_op(compiler, GET_OPCODE(op), inp_flags | ALT_FORM2, dst, dstw, src2, src2w, TMP_REG2, 0);
+ return emit_op(compiler, GET_OPCODE(op), flags | ALT_FORM2, dst, dstw, src2, src2w, TMP_REG2, 0);
}
}
if (!GET_FLAGS(op) && GET_OPCODE(op) != SLJIT_AND) {
if (TEST_UI_IMM(src2, src2w)) {
compiler->imm = src2w;
- return emit_op(compiler, GET_OPCODE(op), inp_flags | ALT_FORM3, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, GET_OPCODE(op), flags | ALT_FORM3, dst, dstw, src1, src1w, TMP_REG2, 0);
}
if (TEST_UI_IMM(src1, src1w)) {
compiler->imm = src1w;
- return emit_op(compiler, GET_OPCODE(op), inp_flags | ALT_FORM3, dst, dstw, src2, src2w, TMP_REG2, 0);
+ return emit_op(compiler, GET_OPCODE(op), flags | ALT_FORM3, dst, dstw, src2, src2w, TMP_REG2, 0);
}
}
- return emit_op(compiler, GET_OPCODE(op), inp_flags, dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, GET_OPCODE(op), flags, dst, dstw, src1, src1w, src2, src2w);
+ case SLJIT_ASHR:
+ if (op & SLJIT_KEEP_FLAGS)
+ flags |= ALT_FORM3;
+ /* Fall through. */
case SLJIT_SHL:
case SLJIT_LSHR:
- case SLJIT_ASHR:
#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
if (op & SLJIT_INT_OP)
- inp_flags |= ALT_FORM2;
+ flags |= ALT_FORM2;
#endif
if (src2 & SLJIT_IMM) {
compiler->imm = src2w;
- return emit_op(compiler, GET_OPCODE(op), inp_flags | ALT_FORM1, dst, dstw, src1, src1w, TMP_REG2, 0);
+ return emit_op(compiler, GET_OPCODE(op), flags | ALT_FORM1, dst, dstw, src1, src1w, TMP_REG2, 0);
}
- return emit_op(compiler, GET_OPCODE(op), inp_flags, dst, dstw, src1, src1w, src2, src2w);
+ return emit_op(compiler, GET_OPCODE(op), flags, dst, dstw, src1, src1w, src2, src2w);
}
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_get_register_index(int reg)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg)
{
check_sljit_get_register_index(reg);
return reg_map[reg];
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compiler,
- void *instruction, int size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler,
+ void *instruction, sljit_si size)
{
CHECK_ERROR();
check_sljit_emit_op_custom(compiler, instruction, size);
@@ -1403,106 +1521,77 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compile
/* Floating point operators */
/* --------------------------------------------------------------------- */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fpu_available(void)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_is_fpu_available(void)
{
/* Always available. */
return 1;
}
-static int emit_fpu_data_transfer(struct sljit_compiler *compiler, int fpu_reg, int load, int arg, sljit_w argw)
-{
- SLJIT_ASSERT(arg & SLJIT_MEM);
-
- /* Fast loads and stores. */
- if (!(arg & 0xf0)) {
- /* Both for (arg & 0xf) == SLJIT_UNUSED and (arg & 0xf) != SLJIT_UNUSED. */
- if (argw <= SIMM_MAX && argw >= SIMM_MIN)
- return push_inst(compiler, (load ? LFD : STFD) | FD(fpu_reg) | A(arg & 0xf) | IMM(argw));
- }
+#define FLOAT_DATA(op) (DOUBLE_DATA | ((op & SLJIT_SINGLE_OP) >> 6))
+#define SELECT_FOP(op, single, double) ((op & SLJIT_SINGLE_OP) ? single : double)
- if (arg & 0xf0) {
- argw &= 0x3;
- if (argw) {
-#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32)
- FAIL_IF(push_inst(compiler, RLWINM | S((arg >> 4) & 0xf) | A(TMP_REG2) | (argw << 11) | ((31 - argw) << 1)));
-#else
- FAIL_IF(push_inst(compiler, RLDI(TMP_REG2, (arg >> 4) & 0xf, argw, 63 - argw, 1)));
-#endif
- return push_inst(compiler, (load ? LFDX : STFDX) | FD(fpu_reg) | A(arg & 0xf) | B(TMP_REG2));
- }
- return push_inst(compiler, (load ? LFDX : STFDX) | FD(fpu_reg) | A(arg & 0xf) | B((arg >> 4) & 0xf));
- }
-
- /* Use cache. */
- if (compiler->cache_arg == arg && argw - compiler->cache_argw <= SIMM_MAX && argw - compiler->cache_argw >= SIMM_MIN)
- return push_inst(compiler, (load ? LFD : STFD) | FD(fpu_reg) | A(TMP_REG3) | IMM(argw - compiler->cache_argw));
-
- /* Put value to cache. */
- compiler->cache_arg = arg;
- compiler->cache_argw = argw;
-
- FAIL_IF(load_immediate(compiler, TMP_REG3, argw));
- if (!(arg & 0xf))
- return push_inst(compiler, (load ? LFDX : STFDX) | FD(fpu_reg) | A(0) | B(TMP_REG3));
- return push_inst(compiler, (load ? LFDUX : STFDUX) | FD(fpu_reg) | A(TMP_REG3) | B(arg & 0xf));
-}
-
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- int dst_fr;
+ sljit_si dst_fr;
CHECK_ERROR();
check_sljit_emit_fop1(compiler, op, dst, dstw, src, srcw);
+ SLJIT_COMPILE_ASSERT((SLJIT_SINGLE_OP == 0x100) && !(DOUBLE_DATA & 0x4), float_transfer_bit_error);
compiler->cache_arg = 0;
compiler->cache_argw = 0;
- if (GET_OPCODE(op) == SLJIT_FCMP) {
- if (dst > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG1, 1, dst, dstw));
+ if (GET_OPCODE(op) == SLJIT_CMPD) {
+ if (dst > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, dst, dstw, src, srcw));
dst = TMP_FREG1;
}
- if (src > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG2, 1, src, srcw));
+
+ if (src > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src, srcw, 0, 0));
src = TMP_FREG2;
}
+
return push_inst(compiler, FCMPU | CRD(4) | FA(dst) | FB(src));
}
- dst_fr = (dst > SLJIT_FLOAT_REG4) ? TMP_FREG1 : dst;
+ dst_fr = (dst > SLJIT_FLOAT_REG6) ? TMP_FREG1 : dst;
- if (src > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, dst_fr, 1, src, srcw));
+ if (src > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, dst_fr, src, srcw, dst, dstw));
src = dst_fr;
}
- switch (op) {
- case SLJIT_FMOV:
+ switch (GET_OPCODE(op)) {
+ case SLJIT_MOVD:
if (src != dst_fr && dst_fr != TMP_FREG1)
FAIL_IF(push_inst(compiler, FMR | FD(dst_fr) | FB(src)));
break;
- case SLJIT_FNEG:
+ case SLJIT_NEGD:
FAIL_IF(push_inst(compiler, FNEG | FD(dst_fr) | FB(src)));
break;
- case SLJIT_FABS:
+ case SLJIT_ABSD:
FAIL_IF(push_inst(compiler, FABS | FD(dst_fr) | FB(src)));
break;
}
- if (dst_fr == TMP_FREG1)
- FAIL_IF(emit_fpu_data_transfer(compiler, src, 0, dst, dstw));
+ if (dst_fr == TMP_FREG1) {
+ if (GET_OPCODE(op) == SLJIT_MOVD)
+ dst_fr = src;
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op), dst_fr, dst, dstw, 0, 0));
+ }
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- int dst_fr;
+ sljit_si dst_fr, flags = 0;
CHECK_ERROR();
check_sljit_emit_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
@@ -1510,78 +1599,100 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, in
compiler->cache_arg = 0;
compiler->cache_argw = 0;
- dst_fr = (dst > SLJIT_FLOAT_REG4) ? TMP_FREG1 : dst;
+ dst_fr = (dst > SLJIT_FLOAT_REG6) ? TMP_FREG2 : dst;
- if (src2 > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG2, 1, src2, src2w));
- src2 = TMP_FREG2;
+ if (src1 > SLJIT_FLOAT_REG6) {
+ if (getput_arg_fast(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, src1, src1w)) {
+ FAIL_IF(compiler->error);
+ src1 = TMP_FREG1;
+ } else
+ flags |= ALT_FORM1;
}
- if (src1 > SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG1, 1, src1, src1w));
- src1 = TMP_FREG1;
+ if (src2 > SLJIT_FLOAT_REG6) {
+ if (getput_arg_fast(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src2, src2w)) {
+ FAIL_IF(compiler->error);
+ src2 = TMP_FREG2;
+ } else
+ flags |= ALT_FORM2;
}
- switch (op) {
- case SLJIT_FADD:
- FAIL_IF(push_inst(compiler, FADD | FD(dst_fr) | FA(src1) | FB(src2)));
+ if ((flags & (ALT_FORM1 | ALT_FORM2)) == (ALT_FORM1 | ALT_FORM2)) {
+ if (!can_cache(src1, src1w, src2, src2w) && can_cache(src1, src1w, dst, dstw)) {
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src2, src2w, src1, src1w));
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, src1, src1w, dst, dstw));
+ }
+ else {
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, src1, src1w, src2, src2w));
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src2, src2w, dst, dstw));
+ }
+ }
+ else if (flags & ALT_FORM1)
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, src1, src1w, dst, dstw));
+ else if (flags & ALT_FORM2)
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src2, src2w, dst, dstw));
+
+ if (flags & ALT_FORM1)
+ src1 = TMP_FREG1;
+ if (flags & ALT_FORM2)
+ src2 = TMP_FREG2;
+
+ switch (GET_OPCODE(op)) {
+ case SLJIT_ADDD:
+ FAIL_IF(push_inst(compiler, SELECT_FOP(op, FADDS, FADD) | FD(dst_fr) | FA(src1) | FB(src2)));
break;
- case SLJIT_FSUB:
- FAIL_IF(push_inst(compiler, FSUB | FD(dst_fr) | FA(src1) | FB(src2)));
+ case SLJIT_SUBD:
+ FAIL_IF(push_inst(compiler, SELECT_FOP(op, FSUBS, FSUB) | FD(dst_fr) | FA(src1) | FB(src2)));
break;
- case SLJIT_FMUL:
- FAIL_IF(push_inst(compiler, FMUL | FD(dst_fr) | FA(src1) | FC(src2) /* FMUL use FC as src2 */));
+ case SLJIT_MULD:
+ FAIL_IF(push_inst(compiler, SELECT_FOP(op, FMULS, FMUL) | FD(dst_fr) | FA(src1) | FC(src2) /* FMUL use FC as src2 */));
break;
- case SLJIT_FDIV:
- FAIL_IF(push_inst(compiler, FDIV | FD(dst_fr) | FA(src1) | FB(src2)));
+ case SLJIT_DIVD:
+ FAIL_IF(push_inst(compiler, SELECT_FOP(op, FDIVS, FDIV) | FD(dst_fr) | FA(src1) | FB(src2)));
break;
}
- if (dst_fr == TMP_FREG1)
- FAIL_IF(emit_fpu_data_transfer(compiler, TMP_FREG1, 0, dst, dstw));
+ if (dst_fr == TMP_FREG2)
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op), TMP_FREG2, dst, dstw, 0, 0));
return SLJIT_SUCCESS;
}
+#undef FLOAT_DATA
+#undef SELECT_FOP
+
/* --------------------------------------------------------------------- */
/* Other instructions */
/* --------------------------------------------------------------------- */
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_enter(struct sljit_compiler *compiler, int dst, sljit_w dstw, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_enter(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw)
{
CHECK_ERROR();
- check_sljit_emit_fast_enter(compiler, dst, dstw, args, temporaries, saveds, local_size);
-
- compiler->temporaries = temporaries;
- compiler->saveds = saveds;
+ check_sljit_emit_fast_enter(compiler, dst, dstw);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
- compiler->has_locals = local_size > 0;
-#if (defined SLJIT_CONFIG_PPC_32 && SLJIT_CONFIG_PPC_32)
- compiler->local_size = (2 + saveds + 2) * sizeof(sljit_w) + local_size;
-#else
- compiler->local_size = (2 + saveds + 7 + 8) * sizeof(sljit_w) + local_size;
-#endif
- compiler->local_size = (compiler->local_size + 15) & ~0xf;
+ /* For UNUSED dst. Uncommon, but possible. */
+ if (dst == SLJIT_UNUSED)
+ return SLJIT_SUCCESS;
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS)
+ if (dst <= ZERO_REG)
return push_inst(compiler, MFLR | D(dst));
- else if (dst & SLJIT_MEM) {
- FAIL_IF(push_inst(compiler, MFLR | D(TMP_REG2)));
- return emit_op(compiler, SLJIT_MOV, WORD_DATA, dst, dstw, TMP_REG1, 0, TMP_REG2, 0);
- }
- return SLJIT_SUCCESS;
+ /* Memory. */
+ FAIL_IF(push_inst(compiler, MFLR | D(TMP_REG2)));
+ return emit_op(compiler, SLJIT_MOV, WORD_DATA, dst, dstw, TMP_REG1, 0, TMP_REG2, 0);
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compiler, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_return(struct sljit_compiler *compiler, sljit_si src, sljit_sw srcw)
{
CHECK_ERROR();
check_sljit_emit_fast_return(compiler, src, srcw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
- if (src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_NO_REGISTERS)
+ if (src <= ZERO_REG)
FAIL_IF(push_inst(compiler, MTLR | S(src)));
else {
if (src & SLJIT_MEM)
@@ -1613,7 +1724,7 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_label* sljit_emit_label(struct sljit_compi
return label;
}
-static sljit_ins get_bo_bi_flags(struct sljit_compiler *compiler, int type)
+static sljit_ins get_bo_bi_flags(sljit_si type)
{
switch (type) {
case SLJIT_C_EQUAL:
@@ -1664,10 +1775,10 @@ static sljit_ins get_bo_bi_flags(struct sljit_compiler *compiler, int type)
case SLJIT_C_FLOAT_NOT_EQUAL:
return (4 << 21) | ((4 + 2) << 16);
- case SLJIT_C_FLOAT_NAN:
+ case SLJIT_C_FLOAT_UNORDERED:
return (12 << 21) | ((4 + 3) << 16);
- case SLJIT_C_FLOAT_NOT_NAN:
+ case SLJIT_C_FLOAT_ORDERED:
return (4 << 21) | ((4 + 3) << 16);
default:
@@ -1676,7 +1787,7 @@ static sljit_ins get_bo_bi_flags(struct sljit_compiler *compiler, int type)
}
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, int type)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, sljit_si type)
{
struct sljit_jump *jump;
sljit_ins bo_bi_flags;
@@ -1684,7 +1795,7 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compile
CHECK_ERROR_PTR();
check_sljit_emit_jump(compiler, type);
- bo_bi_flags = get_bo_bi_flags(compiler, type & 0xff);
+ bo_bi_flags = get_bo_bi_flags(type & 0xff);
if (!bo_bi_flags)
return NULL;
@@ -1704,19 +1815,16 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compile
return jump;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, int type, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_ijump(struct sljit_compiler *compiler, sljit_si type, sljit_si src, sljit_sw srcw)
{
- sljit_ins bo_bi_flags;
struct sljit_jump *jump = NULL;
- int src_r;
+ sljit_si src_r;
CHECK_ERROR();
check_sljit_emit_ijump(compiler, type, src, srcw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
- bo_bi_flags = get_bo_bi_flags(compiler, type);
- FAIL_IF(!bo_bi_flags);
-
- if (src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_NO_REGISTERS)
+ if (src <= ZERO_REG)
src_r = src;
else if (src & SLJIT_IMM) {
jump = (struct sljit_jump*)ensure_abuf(compiler, sizeof(struct sljit_jump));
@@ -1735,7 +1843,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, i
FAIL_IF(push_inst(compiler, MTCTR | S(src_r)));
if (jump)
jump->addr = compiler->size;
- return push_inst(compiler, BCCTR | bo_bi_flags | (type >= SLJIT_FAST_CALL ? 1 : 0));
+ return push_inst(compiler, BCCTR | (20 << 21) | (type >= SLJIT_FAST_CALL ? 1 : 0));
}
/* Get a bit from CR, all other bits are zeroed. */
@@ -1746,17 +1854,37 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, i
#define INVERT_BIT(dst) \
FAIL_IF(push_inst(compiler, XORI | S(dst) | A(dst) | 0x1));
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_cond_value(struct sljit_compiler *compiler, int op, int dst, sljit_w dstw, int type)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_flags(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw,
+ sljit_si type)
{
- int reg;
+ sljit_si reg, input_flags;
+ sljit_si flags = GET_ALL_FLAGS(op);
CHECK_ERROR();
- check_sljit_emit_cond_value(compiler, op, dst, dstw, type);
+ check_sljit_emit_op_flags(compiler, op, dst, dstw, src, srcw, type);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
if (dst == SLJIT_UNUSED)
return SLJIT_SUCCESS;
- reg = (op == SLJIT_MOV && dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REG2;
+ op = GET_OPCODE(op);
+ reg = (op < SLJIT_ADD && dst <= ZERO_REG) ? dst : TMP_REG2;
+
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+ if (op >= SLJIT_ADD && (src & SLJIT_MEM)) {
+ ADJUST_LOCAL_OFFSET(src, srcw);
+#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
+ input_flags = (flags & SLJIT_INT_OP) ? INT_DATA : WORD_DATA;
+#else
+ input_flags = WORD_DATA;
+#endif
+ FAIL_IF(emit_op_mem2(compiler, input_flags | LOAD_DATA, TMP_REG1, src, srcw, dst, dstw));
+ src = TMP_REG1;
+ srcw = 0;
+ }
switch (type) {
case SLJIT_C_EQUAL:
@@ -1828,11 +1956,11 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_cond_value(struct sljit_compiler *compil
INVERT_BIT(reg);
break;
- case SLJIT_C_FLOAT_NAN:
+ case SLJIT_C_FLOAT_UNORDERED:
GET_CR_BIT(4 + 3, reg);
break;
- case SLJIT_C_FLOAT_NOT_NAN:
+ case SLJIT_C_FLOAT_ORDERED:
GET_CR_BIT(4 + 3, reg);
INVERT_BIT(reg);
break;
@@ -1842,27 +1970,41 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_cond_value(struct sljit_compiler *compil
break;
}
- if (GET_OPCODE(op) == SLJIT_OR)
- return emit_op(compiler, GET_OPCODE(op), GET_FLAGS(op) ? ALT_SET_FLAGS : 0, dst, dstw, dst, dstw, TMP_REG2, 0);
+ if (op < SLJIT_ADD) {
+#if (defined SLJIT_CONFIG_PPC_64 && SLJIT_CONFIG_PPC_64)
+ if (op == SLJIT_MOV)
+ input_flags = WORD_DATA;
+ else {
+ op = SLJIT_MOV_UI;
+ input_flags = INT_DATA;
+ }
+#else
+ op = SLJIT_MOV;
+ input_flags = WORD_DATA;
+#endif
+ return (reg == TMP_REG2) ? emit_op(compiler, op, input_flags, dst, dstw, TMP_REG1, 0, TMP_REG2, 0) : SLJIT_SUCCESS;
+ }
- if (reg == TMP_REG2)
- return emit_op(compiler, SLJIT_MOV, WORD_DATA, dst, dstw, TMP_REG1, 0, TMP_REG2, 0);
- return SLJIT_SUCCESS;
+#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->skip_checks = 1;
+#endif
+ return sljit_emit_op2(compiler, op | flags, dst, dstw, src, srcw, TMP_REG2, 0);
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, int dst, sljit_w dstw, sljit_w init_value)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw init_value)
{
struct sljit_const *const_;
- int reg;
+ sljit_si reg;
CHECK_ERROR_PTR();
check_sljit_emit_const(compiler, dst, dstw, init_value);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
const_ = (struct sljit_const*)ensure_abuf(compiler, sizeof(struct sljit_const));
PTR_FAIL_IF(!const_);
set_const(const_, compiler);
- reg = (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REG2;
+ reg = (dst <= ZERO_REG) ? dst : TMP_REG2;
PTR_FAIL_IF(emit_const(compiler, reg, init_value));
diff --git a/src/3rdparty/pcre/sljit/sljitNativeSPARC_32.c b/src/3rdparty/pcre/sljit/sljitNativeSPARC_32.c
new file mode 100644
index 0000000000..80479bfe2b
--- /dev/null
+++ b/src/3rdparty/pcre/sljit/sljitNativeSPARC_32.c
@@ -0,0 +1,164 @@
+/*
+ * Stack-less Just-In-Time compiler
+ *
+ * Copyright 2009-2012 Zoltan Herczeg (hzmester@freemail.hu). 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 HOLDER(S) 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(S) 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.
+ */
+
+static sljit_si load_immediate(struct sljit_compiler *compiler, sljit_si dst, sljit_sw imm)
+{
+ if (imm <= SIMM_MAX && imm >= SIMM_MIN)
+ return push_inst(compiler, OR | D(dst) | S1(0) | IMM(imm), DR(dst));
+
+ FAIL_IF(push_inst(compiler, SETHI | D(dst) | ((imm >> 10) & 0x3fffff), DR(dst)));
+ return (imm & 0x3ff) ? push_inst(compiler, OR | D(dst) | S1(dst) | IMM_ARG | (imm & 0x3ff), DR(dst)) : SLJIT_SUCCESS;
+}
+
+#define ARG2(flags, src2) ((flags & SRC2_IMM) ? IMM(src2) : S2(src2))
+
+static SLJIT_INLINE sljit_si emit_single_op(struct sljit_compiler *compiler, sljit_si op, sljit_si flags,
+ sljit_si dst, sljit_si src1, sljit_sw src2)
+{
+ SLJIT_COMPILE_ASSERT(ICC_IS_SET == SET_FLAGS, icc_is_set_and_set_flags_must_be_the_same);
+
+ switch (op) {
+ case SLJIT_MOV:
+ case SLJIT_MOV_UI:
+ case SLJIT_MOV_SI:
+ case SLJIT_MOV_P:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & SRC2_IMM));
+ if (dst != src2)
+ return push_inst(compiler, OR | D(dst) | S1(0) | S2(src2), DR(dst));
+ return SLJIT_SUCCESS;
+
+ case SLJIT_MOV_UB:
+ case SLJIT_MOV_SB:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & SRC2_IMM));
+ if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
+ if (op == SLJIT_MOV_UB)
+ return push_inst(compiler, AND | D(dst) | S1(src2) | IMM(0xff), DR(dst));
+ FAIL_IF(push_inst(compiler, SLL | D(dst) | S1(src2) | IMM(24), DR(dst)));
+ return push_inst(compiler, SRA | D(dst) | S1(dst) | IMM(24), DR(dst));
+ }
+ else if (dst != src2)
+ SLJIT_ASSERT_STOP();
+ return SLJIT_SUCCESS;
+
+ case SLJIT_MOV_UH:
+ case SLJIT_MOV_SH:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & SRC2_IMM));
+ if ((flags & (REG_DEST | REG2_SOURCE)) == (REG_DEST | REG2_SOURCE)) {
+ FAIL_IF(push_inst(compiler, SLL | D(dst) | S1(src2) | IMM(16), DR(dst)));
+ return push_inst(compiler, (op == SLJIT_MOV_SH ? SRA : SRL) | D(dst) | S1(dst) | IMM(16), DR(dst));
+ }
+ else if (dst != src2)
+ SLJIT_ASSERT_STOP();
+ return SLJIT_SUCCESS;
+
+ case SLJIT_NOT:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & SRC2_IMM));
+ return push_inst(compiler, XNOR | (flags & SET_FLAGS) | D(dst) | S1(0) | S2(src2), DR(dst) | (flags & SET_FLAGS));
+
+ case SLJIT_CLZ:
+ SLJIT_ASSERT(src1 == TMP_REG1 && !(flags & SRC2_IMM));
+ /* sparc 32 does not support SLJIT_KEEP_FLAGS. Not sure I can fix this. */
+ FAIL_IF(push_inst(compiler, SUB | SET_FLAGS | D(0) | S1(src2) | S2(0), SET_FLAGS));
+ FAIL_IF(push_inst(compiler, OR | D(TMP_REG1) | S1(0) | S2(src2), DR(TMP_REG1)));
+ FAIL_IF(push_inst(compiler, BICC | DA(0x1) | (7 & DISP_MASK), UNMOVABLE_INS));
+ FAIL_IF(push_inst(compiler, OR | (flags & SET_FLAGS) | D(dst) | S1(0) | IMM(32), UNMOVABLE_INS | (flags & SET_FLAGS)));
+ FAIL_IF(push_inst(compiler, OR | D(dst) | S1(0) | IMM(-1), DR(dst)));
+
+ /* Loop. */
+ FAIL_IF(push_inst(compiler, SUB | SET_FLAGS | D(0) | S1(TMP_REG1) | S2(0), SET_FLAGS));
+ FAIL_IF(push_inst(compiler, SLL | D(TMP_REG1) | S1(TMP_REG1) | IMM(1), DR(TMP_REG1)));
+ FAIL_IF(push_inst(compiler, BICC | DA(0xe) | (-2 & DISP_MASK), UNMOVABLE_INS));
+ return push_inst(compiler, ADD | (flags & SET_FLAGS) | D(dst) | S1(dst) | IMM(1), UNMOVABLE_INS | (flags & SET_FLAGS));
+
+ case SLJIT_ADD:
+ return push_inst(compiler, ADD | (flags & SET_FLAGS) | D(dst) | S1(src1) | ARG2(flags, src2), DR(dst) | (flags & SET_FLAGS));
+
+ case SLJIT_ADDC:
+ return push_inst(compiler, ADDC | (flags & SET_FLAGS) | D(dst) | S1(src1) | ARG2(flags, src2), DR(dst) | (flags & SET_FLAGS));
+
+ case SLJIT_SUB:
+ return push_inst(compiler, SUB | (flags & SET_FLAGS) | D(dst) | S1(src1) | ARG2(flags, src2), DR(dst) | (flags & SET_FLAGS));
+
+ case SLJIT_SUBC:
+ return push_inst(compiler, SUBC | (flags & SET_FLAGS) | D(dst) | S1(src1) | ARG2(flags, src2), DR(dst) | (flags & SET_FLAGS));
+
+ case SLJIT_MUL:
+ FAIL_IF(push_inst(compiler, SMUL | D(dst) | S1(src1) | ARG2(flags, src2), DR(dst)));
+ if (!(flags & SET_FLAGS))
+ return SLJIT_SUCCESS;
+ FAIL_IF(push_inst(compiler, SRA | D(TMP_REG1) | S1(dst) | IMM(31), DR(TMP_REG1)));
+ FAIL_IF(push_inst(compiler, RDY | D(TMP_REG4), DR(TMP_REG4)));
+ return push_inst(compiler, SUB | SET_FLAGS | D(0) | S1(TMP_REG1) | S2(TMP_REG4), MOVABLE_INS | SET_FLAGS);
+
+ case SLJIT_AND:
+ return push_inst(compiler, AND | (flags & SET_FLAGS) | D(dst) | S1(src1) | ARG2(flags, src2), DR(dst) | (flags & SET_FLAGS));
+
+ case SLJIT_OR:
+ return push_inst(compiler, OR | (flags & SET_FLAGS) | D(dst) | S1(src1) | ARG2(flags, src2), DR(dst) | (flags & SET_FLAGS));
+
+ case SLJIT_XOR:
+ return push_inst(compiler, XOR | (flags & SET_FLAGS) | D(dst) | S1(src1) | ARG2(flags, src2), DR(dst) | (flags & SET_FLAGS));
+
+ case SLJIT_SHL:
+ FAIL_IF(push_inst(compiler, SLL | D(dst) | S1(src1) | ARG2(flags, src2), DR(dst)));
+ return !(flags & SET_FLAGS) ? SLJIT_SUCCESS : push_inst(compiler, SUB | SET_FLAGS | D(0) | S1(dst) | S2(0), SET_FLAGS);
+
+ case SLJIT_LSHR:
+ FAIL_IF(push_inst(compiler, SRL | D(dst) | S1(src1) | ARG2(flags, src2), DR(dst)));
+ return !(flags & SET_FLAGS) ? SLJIT_SUCCESS : push_inst(compiler, SUB | SET_FLAGS | D(0) | S1(dst) | S2(0), SET_FLAGS);
+
+ case SLJIT_ASHR:
+ FAIL_IF(push_inst(compiler, SRA | D(dst) | S1(src1) | ARG2(flags, src2), DR(dst)));
+ return !(flags & SET_FLAGS) ? SLJIT_SUCCESS : push_inst(compiler, SUB | SET_FLAGS | D(0) | S1(dst) | S2(0), SET_FLAGS);
+ }
+
+ SLJIT_ASSERT_STOP();
+ return SLJIT_SUCCESS;
+}
+
+static SLJIT_INLINE sljit_si emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw init_value)
+{
+ FAIL_IF(push_inst(compiler, SETHI | D(dst) | ((init_value >> 10) & 0x3fffff), DR(dst)));
+ return push_inst(compiler, OR | D(dst) | S1(dst) | IMM_ARG | (init_value & 0x3ff), DR(dst));
+}
+
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_jump_addr(sljit_uw addr, sljit_uw new_addr)
+{
+ sljit_ins *inst = (sljit_ins*)addr;
+
+ inst[0] = (inst[0] & 0xffc00000) | ((new_addr >> 10) & 0x3fffff);
+ inst[1] = (inst[1] & 0xfffffc00) | (new_addr & 0x3ff);
+ SLJIT_CACHE_FLUSH(inst, inst + 2);
+}
+
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_sw new_constant)
+{
+ sljit_ins *inst = (sljit_ins*)addr;
+
+ inst[0] = (inst[0] & 0xffc00000) | ((new_constant >> 10) & 0x3fffff);
+ inst[1] = (inst[1] & 0xfffffc00) | (new_constant & 0x3ff);
+ SLJIT_CACHE_FLUSH(inst, inst + 2);
+}
diff --git a/src/3rdparty/pcre/sljit/sljitNativeSPARC_common.c b/src/3rdparty/pcre/sljit/sljitNativeSPARC_common.c
new file mode 100644
index 0000000000..c6522be2a7
--- /dev/null
+++ b/src/3rdparty/pcre/sljit/sljitNativeSPARC_common.c
@@ -0,0 +1,1348 @@
+/*
+ * Stack-less Just-In-Time compiler
+ *
+ * Copyright 2009-2012 Zoltan Herczeg (hzmester@freemail.hu). 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 HOLDER(S) 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(S) 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.
+ */
+
+SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name(void)
+{
+ return "SPARC" SLJIT_CPUINFO;
+}
+
+/* Length of an instruction word
+ Both for sparc-32 and sparc-64 */
+typedef sljit_ui sljit_ins;
+
+static void sparc_cache_flush(sljit_ins *from, sljit_ins *to)
+{
+ if (SLJIT_UNLIKELY(from == to))
+ return;
+
+ do {
+ __asm__ volatile (
+ "flush %0\n"
+ : : "r"(from)
+ );
+ /* Operates at least on doubleword. */
+ from += 2;
+ } while (from < to);
+
+ if (from == to) {
+ /* Flush the last word. */
+ to --;
+ __asm__ volatile (
+ "flush %0\n"
+ : : "r"(to)
+ );
+ }
+}
+
+/* TMP_REG2 is not used by getput_arg */
+#define TMP_REG1 (SLJIT_NO_REGISTERS + 1)
+#define TMP_REG2 (SLJIT_NO_REGISTERS + 2)
+#define TMP_REG3 (SLJIT_NO_REGISTERS + 3)
+#define TMP_REG4 (SLJIT_NO_REGISTERS + 4)
+#define LINK_REG (SLJIT_NO_REGISTERS + 5)
+
+#define TMP_FREG1 (0)
+#define TMP_FREG2 ((SLJIT_FLOAT_REG6 + 1) << 1)
+
+static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 7] = {
+ 0, 8, 9, 10, 11, 12, 16, 17, 18, 19, 20, 14, 1, 24, 25, 26, 15
+};
+
+/* --------------------------------------------------------------------- */
+/* Instrucion forms */
+/* --------------------------------------------------------------------- */
+
+#define D(d) (reg_map[d] << 25)
+#define DA(d) ((d) << 25)
+#define S1(s1) (reg_map[s1] << 14)
+#define S2(s2) (reg_map[s2])
+#define S1A(s1) ((s1) << 14)
+#define S2A(s2) (s2)
+#define IMM_ARG 0x2000
+#define DOP(op) ((op) << 5)
+#define IMM(imm) (((imm) & 0x1fff) | IMM_ARG)
+
+#define DR(dr) (reg_map[dr])
+#define OPC1(opcode) ((opcode) << 30)
+#define OPC2(opcode) ((opcode) << 22)
+#define OPC3(opcode) ((opcode) << 19)
+#define SET_FLAGS OPC3(0x10)
+
+#define ADD (OPC1(0x2) | OPC3(0x00))
+#define ADDC (OPC1(0x2) | OPC3(0x08))
+#define AND (OPC1(0x2) | OPC3(0x01))
+#define ANDN (OPC1(0x2) | OPC3(0x05))
+#define CALL (OPC1(0x1))
+#define FABSS (OPC1(0x2) | OPC3(0x34) | DOP(0x09))
+#define FADDD (OPC1(0x2) | OPC3(0x34) | DOP(0x42))
+#define FADDS (OPC1(0x2) | OPC3(0x34) | DOP(0x41))
+#define FCMPD (OPC1(0x2) | OPC3(0x35) | DOP(0x52))
+#define FCMPS (OPC1(0x2) | OPC3(0x35) | DOP(0x51))
+#define FDIVD (OPC1(0x2) | OPC3(0x34) | DOP(0x4e))
+#define FDIVS (OPC1(0x2) | OPC3(0x34) | DOP(0x4d))
+#define FMOVS (OPC1(0x2) | OPC3(0x34) | DOP(0x01))
+#define FMULD (OPC1(0x2) | OPC3(0x34) | DOP(0x4a))
+#define FMULS (OPC1(0x2) | OPC3(0x34) | DOP(0x49))
+#define FNEGS (OPC1(0x2) | OPC3(0x34) | DOP(0x05))
+#define FSUBD (OPC1(0x2) | OPC3(0x34) | DOP(0x46))
+#define FSUBS (OPC1(0x2) | OPC3(0x34) | DOP(0x45))
+#define JMPL (OPC1(0x2) | OPC3(0x38))
+#define NOP (OPC1(0x0) | OPC2(0x04))
+#define OR (OPC1(0x2) | OPC3(0x02))
+#define ORN (OPC1(0x2) | OPC3(0x06))
+#define RDY (OPC1(0x2) | OPC3(0x28) | S1A(0))
+#define RESTORE (OPC1(0x2) | OPC3(0x3d))
+#define SAVE (OPC1(0x2) | OPC3(0x3c))
+#define SETHI (OPC1(0x0) | OPC2(0x04))
+#define SLL (OPC1(0x2) | OPC3(0x25))
+#define SLLX (OPC1(0x2) | OPC3(0x25) | (1 << 12))
+#define SRA (OPC1(0x2) | OPC3(0x27))
+#define SRAX (OPC1(0x2) | OPC3(0x27) | (1 << 12))
+#define SRL (OPC1(0x2) | OPC3(0x26))
+#define SRLX (OPC1(0x2) | OPC3(0x26) | (1 << 12))
+#define SUB (OPC1(0x2) | OPC3(0x04))
+#define SUBC (OPC1(0x2) | OPC3(0x0c))
+#define TA (OPC1(0x2) | OPC3(0x3a) | (8 << 25))
+#define WRY (OPC1(0x2) | OPC3(0x30) | DA(0))
+#define XOR (OPC1(0x2) | OPC3(0x03))
+#define XNOR (OPC1(0x2) | OPC3(0x07))
+
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+#define MAX_DISP (0x1fffff)
+#define MIN_DISP (-0x200000)
+#define DISP_MASK (0x3fffff)
+
+#define BICC (OPC1(0x0) | OPC2(0x2))
+#define FBFCC (OPC1(0x0) | OPC2(0x6))
+#define SLL_W SLL
+#define SDIV (OPC1(0x2) | OPC3(0x0f))
+#define SMUL (OPC1(0x2) | OPC3(0x0b))
+#define UDIV (OPC1(0x2) | OPC3(0x0e))
+#define UMUL (OPC1(0x2) | OPC3(0x0a))
+#else
+#define SLL_W SLLX
+#endif
+
+#define SIMM_MAX (0x0fff)
+#define SIMM_MIN (-0x1000)
+
+/* dest_reg is the absolute name of the register
+ Useful for reordering instructions in the delay slot. */
+static sljit_si push_inst(struct sljit_compiler *compiler, sljit_ins ins, sljit_si delay_slot)
+{
+ sljit_ins *ptr;
+ SLJIT_ASSERT((delay_slot & DST_INS_MASK) == UNMOVABLE_INS
+ || (delay_slot & DST_INS_MASK) == MOVABLE_INS
+ || (delay_slot & DST_INS_MASK) == ((ins >> 25) & 0x1f));
+ ptr = (sljit_ins*)ensure_buf(compiler, sizeof(sljit_ins));
+ FAIL_IF(!ptr);
+ *ptr = ins;
+ compiler->size++;
+ compiler->delay_slot = delay_slot;
+ return SLJIT_SUCCESS;
+}
+
+static SLJIT_INLINE sljit_ins* optimize_jump(struct sljit_jump *jump, sljit_ins *code_ptr, sljit_ins *code)
+{
+ sljit_sw diff;
+ sljit_uw target_addr;
+ sljit_ins *inst;
+ sljit_ins saved_inst;
+
+ if (jump->flags & SLJIT_REWRITABLE_JUMP)
+ return code_ptr;
+
+ if (jump->flags & JUMP_ADDR)
+ target_addr = jump->u.target;
+ else {
+ SLJIT_ASSERT(jump->flags & JUMP_LABEL);
+ target_addr = (sljit_uw)(code + jump->u.label->size);
+ }
+ inst = (sljit_ins*)jump->addr;
+
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+ if (jump->flags & IS_CALL) {
+ /* Call is always patchable on sparc 32. */
+ jump->flags |= PATCH_CALL;
+ if (jump->flags & IS_MOVABLE) {
+ inst[0] = inst[-1];
+ inst[-1] = CALL;
+ jump->addr -= sizeof(sljit_ins);
+ return inst;
+ }
+ inst[0] = CALL;
+ inst[1] = NOP;
+ return inst + 1;
+ }
+#else
+ /* Both calls and BPr instructions shall not pass this point. */
+#error "Implementation required"
+#endif
+
+ if (jump->flags & IS_COND)
+ inst--;
+
+ if (jump->flags & IS_MOVABLE) {
+ diff = ((sljit_sw)target_addr - (sljit_sw)(inst - 1)) >> 2;
+ if (diff <= MAX_DISP && diff >= MIN_DISP) {
+ jump->flags |= PATCH_B;
+ inst--;
+ if (jump->flags & IS_COND) {
+ saved_inst = inst[0];
+ inst[0] = inst[1] ^ (1 << 28);
+ inst[1] = saved_inst;
+ } else {
+ inst[1] = inst[0];
+ inst[0] = BICC | DA(0x8);
+ }
+ jump->addr = (sljit_uw)inst;
+ return inst + 1;
+ }
+ }
+
+ diff = ((sljit_sw)target_addr - (sljit_sw)(inst)) >> 2;
+ if (diff <= MAX_DISP && diff >= MIN_DISP) {
+ jump->flags |= PATCH_B;
+ if (jump->flags & IS_COND)
+ inst[0] ^= (1 << 28);
+ else
+ inst[0] = BICC | DA(0x8);
+ inst[1] = NOP;
+ jump->addr = (sljit_uw)inst;
+ return inst + 1;
+ }
+
+ return code_ptr;
+}
+
+SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compiler)
+{
+ struct sljit_memory_fragment *buf;
+ sljit_ins *code;
+ sljit_ins *code_ptr;
+ sljit_ins *buf_ptr;
+ sljit_ins *buf_end;
+ sljit_uw word_count;
+ sljit_uw addr;
+
+ struct sljit_label *label;
+ struct sljit_jump *jump;
+ struct sljit_const *const_;
+
+ CHECK_ERROR_PTR();
+ check_sljit_generate_code(compiler);
+ reverse_buf(compiler);
+
+ code = (sljit_ins*)SLJIT_MALLOC_EXEC(compiler->size * sizeof(sljit_ins));
+ PTR_FAIL_WITH_EXEC_IF(code);
+ buf = compiler->buf;
+
+ code_ptr = code;
+ word_count = 0;
+ label = compiler->labels;
+ jump = compiler->jumps;
+ const_ = compiler->consts;
+ do {
+ buf_ptr = (sljit_ins*)buf->memory;
+ buf_end = buf_ptr + (buf->used_size >> 2);
+ do {
+ *code_ptr = *buf_ptr++;
+ SLJIT_ASSERT(!label || label->size >= word_count);
+ SLJIT_ASSERT(!jump || jump->addr >= word_count);
+ SLJIT_ASSERT(!const_ || const_->addr >= word_count);
+ /* These structures are ordered by their address. */
+ if (label && label->size == word_count) {
+ /* Just recording the address. */
+ label->addr = (sljit_uw)code_ptr;
+ label->size = code_ptr - code;
+ label = label->next;
+ }
+ if (jump && jump->addr == word_count) {
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+ jump->addr = (sljit_uw)(code_ptr - 3);
+#else
+ jump->addr = (sljit_uw)(code_ptr - 6);
+#endif
+ code_ptr = optimize_jump(jump, code_ptr, code);
+ jump = jump->next;
+ }
+ if (const_ && const_->addr == word_count) {
+ /* Just recording the address. */
+ const_->addr = (sljit_uw)code_ptr;
+ const_ = const_->next;
+ }
+ code_ptr ++;
+ word_count ++;
+ } while (buf_ptr < buf_end);
+
+ buf = buf->next;
+ } while (buf);
+
+ if (label && label->size == word_count) {
+ label->addr = (sljit_uw)code_ptr;
+ label->size = code_ptr - code;
+ label = label->next;
+ }
+
+ SLJIT_ASSERT(!label);
+ SLJIT_ASSERT(!jump);
+ SLJIT_ASSERT(!const_);
+ SLJIT_ASSERT(code_ptr - code <= (sljit_si)compiler->size);
+
+ jump = compiler->jumps;
+ while (jump) {
+ do {
+ addr = (jump->flags & JUMP_LABEL) ? jump->u.label->addr : jump->u.target;
+ buf_ptr = (sljit_ins*)jump->addr;
+
+ if (jump->flags & PATCH_CALL) {
+ addr = (sljit_sw)(addr - jump->addr) >> 2;
+ SLJIT_ASSERT((sljit_sw)addr <= 0x1fffffff && (sljit_sw)addr >= -0x20000000);
+ buf_ptr[0] = CALL | (addr & 0x3fffffff);
+ break;
+ }
+ if (jump->flags & PATCH_B) {
+ addr = (sljit_sw)(addr - jump->addr) >> 2;
+ SLJIT_ASSERT((sljit_sw)addr <= MAX_DISP && (sljit_sw)addr >= MIN_DISP);
+ buf_ptr[0] = (buf_ptr[0] & ~DISP_MASK) | (addr & DISP_MASK);
+ break;
+ }
+
+ /* Set the fields of immediate loads. */
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+ buf_ptr[0] = (buf_ptr[0] & 0xffc00000) | ((addr >> 10) & 0x3fffff);
+ buf_ptr[1] = (buf_ptr[1] & 0xfffffc00) | (addr & 0x3ff);
+#else
+#error "Implementation required"
+#endif
+ } while (0);
+ jump = jump->next;
+ }
+
+
+ compiler->error = SLJIT_ERR_COMPILED;
+ compiler->executable_size = compiler->size * sizeof(sljit_ins);
+ SLJIT_CACHE_FLUSH(code, code_ptr);
+ return code;
+}
+
+/* --------------------------------------------------------------------- */
+/* Entry, exit */
+/* --------------------------------------------------------------------- */
+
+/* Creates an index in data_transfer_insts array. */
+#define LOAD_DATA 0x01
+#define WORD_DATA 0x00
+#define BYTE_DATA 0x02
+#define HALF_DATA 0x04
+#define INT_DATA 0x06
+#define SIGNED_DATA 0x08
+/* Separates integer and floating point registers */
+#define GPR_REG 0x0f
+#define DOUBLE_DATA 0x10
+
+#define MEM_MASK 0x1f
+
+#define WRITE_BACK 0x00020
+#define ARG_TEST 0x00040
+#define ALT_KEEP_CACHE 0x00080
+#define CUMULATIVE_OP 0x00100
+#define IMM_OP 0x00200
+#define SRC2_IMM 0x00400
+
+#define REG_DEST 0x00800
+#define REG2_SOURCE 0x01000
+#define SLOW_SRC1 0x02000
+#define SLOW_SRC2 0x04000
+#define SLOW_DEST 0x08000
+
+/* SET_FLAGS (0x10 << 19) also belong here! */
+
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+#include "sljitNativeSPARC_32.c"
+#else
+#include "sljitNativeSPARC_64.c"
+#endif
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_enter(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
+{
+ CHECK_ERROR();
+ check_sljit_emit_enter(compiler, args, scratches, saveds, local_size);
+
+ compiler->scratches = scratches;
+ compiler->saveds = saveds;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
+
+ local_size += 23 * sizeof(sljit_sw);
+ local_size = (local_size + 7) & ~0x7;
+ compiler->local_size = local_size;
+
+ if (local_size <= SIMM_MAX) {
+ FAIL_IF(push_inst(compiler, SAVE | D(SLJIT_LOCALS_REG) | S1(SLJIT_LOCALS_REG) | IMM(-local_size), UNMOVABLE_INS));
+ }
+ else {
+ FAIL_IF(load_immediate(compiler, TMP_REG1, -local_size));
+ FAIL_IF(push_inst(compiler, SAVE | D(SLJIT_LOCALS_REG) | S1(SLJIT_LOCALS_REG) | S2(TMP_REG1), UNMOVABLE_INS));
+ }
+
+ if (args >= 1)
+ FAIL_IF(push_inst(compiler, OR | D(SLJIT_SAVED_REG1) | S1(0) | S2A(24), DR(SLJIT_SAVED_REG1)));
+ if (args >= 2)
+ FAIL_IF(push_inst(compiler, OR | D(SLJIT_SAVED_REG2) | S1(0) | S2A(25), DR(SLJIT_SAVED_REG2)));
+ if (args >= 3)
+ FAIL_IF(push_inst(compiler, OR | D(SLJIT_SAVED_REG3) | S1(0) | S2A(26), DR(SLJIT_SAVED_REG3)));
+
+ return SLJIT_SUCCESS;
+}
+
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
+{
+ CHECK_ERROR_VOID();
+ check_sljit_set_context(compiler, args, scratches, saveds, local_size);
+
+ compiler->scratches = scratches;
+ compiler->saveds = saveds;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
+
+ local_size += 23 * sizeof(sljit_sw);
+ compiler->local_size = (local_size + 7) & ~0x7;
+}
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_return(struct sljit_compiler *compiler, sljit_si op, sljit_si src, sljit_sw srcw)
+{
+ CHECK_ERROR();
+ check_sljit_emit_return(compiler, op, src, srcw);
+
+ if (op != SLJIT_MOV || !(src <= TMP_REG3)) {
+ FAIL_IF(emit_mov_before_return(compiler, op, src, srcw));
+ src = SLJIT_SCRATCH_REG1;
+ }
+
+ FAIL_IF(push_inst(compiler, JMPL | D(0) | S1A(31) | IMM(8), UNMOVABLE_INS));
+ return push_inst(compiler, RESTORE | D(SLJIT_SCRATCH_REG1) | S1(src) | S2(0), UNMOVABLE_INS);
+}
+
+/* --------------------------------------------------------------------- */
+/* Operators */
+/* --------------------------------------------------------------------- */
+
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+#define ARCH_32_64(a, b) a
+#else
+#define ARCH_32_64(a, b) b
+#endif
+
+static SLJIT_CONST sljit_ins data_transfer_insts[16 + 4] = {
+/* u w s */ ARCH_32_64(OPC1(3) | OPC3(0x04) /* stw */, OPC1(3) | OPC3(0x0e) /* stx */),
+/* u w l */ ARCH_32_64(OPC1(3) | OPC3(0x00) /* lduw */, OPC1(3) | OPC3(0x0b) /* ldx */),
+/* u b s */ OPC1(3) | OPC3(0x05) /* stb */,
+/* u b l */ OPC1(3) | OPC3(0x01) /* ldub */,
+/* u h s */ OPC1(3) | OPC3(0x06) /* sth */,
+/* u h l */ OPC1(3) | OPC3(0x02) /* lduh */,
+/* u i s */ OPC1(3) | OPC3(0x04) /* stw */,
+/* u i l */ OPC1(3) | OPC3(0x00) /* lduw */,
+
+/* s w s */ ARCH_32_64(OPC1(3) | OPC3(0x04) /* stw */, OPC1(3) | OPC3(0x0e) /* stx */),
+/* s w l */ ARCH_32_64(OPC1(3) | OPC3(0x00) /* lduw */, OPC1(3) | OPC3(0x0b) /* ldx */),
+/* s b s */ OPC1(3) | OPC3(0x05) /* stb */,
+/* s b l */ OPC1(3) | OPC3(0x09) /* ldsb */,
+/* s h s */ OPC1(3) | OPC3(0x06) /* sth */,
+/* s h l */ OPC1(3) | OPC3(0x0a) /* ldsh */,
+/* s i s */ OPC1(3) | OPC3(0x04) /* stw */,
+/* s i l */ ARCH_32_64(OPC1(3) | OPC3(0x00) /* lduw */, OPC1(3) | OPC3(0x08) /* ldsw */),
+
+/* d s */ OPC1(3) | OPC3(0x27),
+/* d l */ OPC1(3) | OPC3(0x23),
+/* s s */ OPC1(3) | OPC3(0x24),
+/* s l */ OPC1(3) | OPC3(0x20),
+};
+
+#undef ARCH_32_64
+
+/* Can perform an operation using at most 1 instruction. */
+static sljit_si getput_arg_fast(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg, sljit_sw argw)
+{
+ SLJIT_ASSERT(arg & SLJIT_MEM);
+
+ if (!(flags & WRITE_BACK) || !(arg & 0xf)) {
+ if ((!(arg & 0xf0) && argw <= SIMM_MAX && argw >= SIMM_MIN)
+ || ((arg & 0xf0) && (argw & 0x3) == 0)) {
+ /* Works for both absoulte and relative addresses (immediate case). */
+ if (SLJIT_UNLIKELY(flags & ARG_TEST))
+ return 1;
+ FAIL_IF(push_inst(compiler, data_transfer_insts[flags & MEM_MASK]
+ | ((flags & MEM_MASK) <= GPR_REG ? D(reg) : DA(reg))
+ | S1(arg & 0xf) | ((arg & 0xf0) ? S2((arg >> 4) & 0xf) : IMM(argw)),
+ ((flags & MEM_MASK) <= GPR_REG && (flags & LOAD_DATA)) ? DR(reg) : MOVABLE_INS));
+ return -1;
+ }
+ }
+ return 0;
+}
+
+/* See getput_arg below.
+ Note: can_cache is called only for binary operators. Those
+ operators always uses word arguments without write back. */
+static sljit_si can_cache(sljit_si arg, sljit_sw argw, sljit_si next_arg, sljit_sw next_argw)
+{
+ SLJIT_ASSERT((arg & SLJIT_MEM) && (next_arg & SLJIT_MEM));
+
+ /* Simple operation except for updates. */
+ if (arg & 0xf0) {
+ argw &= 0x3;
+ SLJIT_ASSERT(argw);
+ next_argw &= 0x3;
+ if ((arg & 0xf0) == (next_arg & 0xf0) && argw == next_argw)
+ return 1;
+ return 0;
+ }
+
+ if (((next_argw - argw) <= SIMM_MAX && (next_argw - argw) >= SIMM_MIN))
+ return 1;
+ return 0;
+}
+
+/* Emit the necessary instructions. See can_cache above. */
+static sljit_si getput_arg(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg, sljit_sw argw, sljit_si next_arg, sljit_sw next_argw)
+{
+ sljit_si base, arg2, delay_slot;
+ sljit_ins dest;
+
+ SLJIT_ASSERT(arg & SLJIT_MEM);
+ if (!(next_arg & SLJIT_MEM)) {
+ next_arg = 0;
+ next_argw = 0;
+ }
+
+ base = arg & 0xf;
+ if (SLJIT_UNLIKELY(arg & 0xf0)) {
+ argw &= 0x3;
+ SLJIT_ASSERT(argw != 0);
+
+ /* Using the cache. */
+ if (((SLJIT_MEM | (arg & 0xf0)) == compiler->cache_arg) && (argw == compiler->cache_argw))
+ arg2 = TMP_REG3;
+ else {
+ if ((arg & 0xf0) == (next_arg & 0xf0) && argw == (next_argw & 0x3)) {
+ compiler->cache_arg = SLJIT_MEM | (arg & 0xf0);
+ compiler->cache_argw = argw;
+ arg2 = TMP_REG3;
+ }
+ else if ((flags & LOAD_DATA) && ((flags & MEM_MASK) <= GPR_REG) && reg != base && (reg << 4) != (arg & 0xf0))
+ arg2 = reg;
+ else /* It must be a mov operation, so tmp1 must be free to use. */
+ arg2 = TMP_REG1;
+ FAIL_IF(push_inst(compiler, SLL_W | D(arg2) | S1((arg >> 4) & 0xf) | IMM_ARG | argw, DR(arg2)));
+ }
+ }
+ else {
+ /* Using the cache. */
+ if ((compiler->cache_arg == SLJIT_MEM) && (argw - compiler->cache_argw) <= SIMM_MAX && (argw - compiler->cache_argw) >= SIMM_MIN) {
+ if (argw != compiler->cache_argw) {
+ FAIL_IF(push_inst(compiler, ADD | D(TMP_REG3) | S1(TMP_REG3) | IMM(argw - compiler->cache_argw), DR(TMP_REG3)));
+ compiler->cache_argw = argw;
+ }
+ arg2 = TMP_REG3;
+ } else {
+ if ((next_argw - argw) <= SIMM_MAX && (next_argw - argw) >= SIMM_MIN) {
+ compiler->cache_arg = SLJIT_MEM;
+ compiler->cache_argw = argw;
+ arg2 = TMP_REG3;
+ }
+ else if ((flags & LOAD_DATA) && ((flags & MEM_MASK) <= GPR_REG) && reg != base)
+ arg2 = reg;
+ else /* It must be a mov operation, so tmp1 must be free to use. */
+ arg2 = TMP_REG1;
+ FAIL_IF(load_immediate(compiler, arg2, argw));
+ }
+ }
+
+ dest = ((flags & MEM_MASK) <= GPR_REG ? D(reg) : DA(reg));
+ delay_slot = ((flags & MEM_MASK) <= GPR_REG && (flags & LOAD_DATA)) ? DR(reg) : MOVABLE_INS;
+ if (!base)
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | dest | S1(arg2) | IMM(0), delay_slot);
+ if (!(flags & WRITE_BACK))
+ return push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | dest | S1(base) | S2(arg2), delay_slot);
+ FAIL_IF(push_inst(compiler, data_transfer_insts[flags & MEM_MASK] | dest | S1(base) | S2(arg2), delay_slot));
+ return push_inst(compiler, ADD | D(base) | S1(base) | S2(arg2), DR(base));
+}
+
+static SLJIT_INLINE sljit_si emit_op_mem(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg, sljit_sw argw)
+{
+ if (getput_arg_fast(compiler, flags, reg, arg, argw))
+ return compiler->error;
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+ return getput_arg(compiler, flags, reg, arg, argw, 0, 0);
+}
+
+static SLJIT_INLINE sljit_si emit_op_mem2(struct sljit_compiler *compiler, sljit_si flags, sljit_si reg, sljit_si arg1, sljit_sw arg1w, sljit_si arg2, sljit_sw arg2w)
+{
+ if (getput_arg_fast(compiler, flags, reg, arg1, arg1w))
+ return compiler->error;
+ return getput_arg(compiler, flags, reg, arg1, arg1w, arg2, arg2w);
+}
+
+static sljit_si emit_op(struct sljit_compiler *compiler, sljit_si op, sljit_si flags,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
+{
+ /* arg1 goes to TMP_REG1 or src reg
+ arg2 goes to TMP_REG2, imm or src reg
+ TMP_REG3 can be used for caching
+ result goes to TMP_REG2, so put result can use TMP_REG1 and TMP_REG3. */
+ sljit_si dst_r = TMP_REG2;
+ sljit_si src1_r;
+ sljit_sw src2_r = 0;
+ sljit_si sugg_src2_r = TMP_REG2;
+
+ if (!(flags & ALT_KEEP_CACHE)) {
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+ }
+
+ if (SLJIT_UNLIKELY(dst == SLJIT_UNUSED)) {
+ if (op >= SLJIT_MOV && op <= SLJIT_MOVU_SI && !(src2 & SLJIT_MEM))
+ return SLJIT_SUCCESS;
+ }
+ else if (dst <= TMP_REG3) {
+ dst_r = dst;
+ flags |= REG_DEST;
+ if (op >= SLJIT_MOV && op <= SLJIT_MOVU_SI)
+ sugg_src2_r = dst_r;
+ }
+ else if ((dst & SLJIT_MEM) && !getput_arg_fast(compiler, flags | ARG_TEST, TMP_REG1, dst, dstw))
+ flags |= SLOW_DEST;
+
+ if (flags & IMM_OP) {
+ if ((src2 & SLJIT_IMM) && src2w) {
+ if (src2w <= SIMM_MAX && src2w >= SIMM_MIN) {
+ flags |= SRC2_IMM;
+ src2_r = src2w;
+ }
+ }
+ if (!(flags & SRC2_IMM) && (flags & CUMULATIVE_OP) && (src1 & SLJIT_IMM) && src1w) {
+ if (src1w <= SIMM_MAX && src1w >= SIMM_MIN) {
+ flags |= SRC2_IMM;
+ src2_r = src1w;
+
+ /* And swap arguments. */
+ src1 = src2;
+ src1w = src2w;
+ src2 = SLJIT_IMM;
+ /* src2w = src2_r unneeded. */
+ }
+ }
+ }
+
+ /* Source 1. */
+ if (src1 <= TMP_REG3)
+ src1_r = src1;
+ else if (src1 & SLJIT_IMM) {
+ if (src1w) {
+ FAIL_IF(load_immediate(compiler, TMP_REG1, src1w));
+ src1_r = TMP_REG1;
+ }
+ else
+ src1_r = 0;
+ }
+ else {
+ if (getput_arg_fast(compiler, flags | LOAD_DATA, TMP_REG1, src1, src1w))
+ FAIL_IF(compiler->error);
+ else
+ flags |= SLOW_SRC1;
+ src1_r = TMP_REG1;
+ }
+
+ /* Source 2. */
+ if (src2 <= TMP_REG3) {
+ src2_r = src2;
+ flags |= REG2_SOURCE;
+ if (!(flags & REG_DEST) && op >= SLJIT_MOV && op <= SLJIT_MOVU_SI)
+ dst_r = src2_r;
+ }
+ else if (src2 & SLJIT_IMM) {
+ if (!(flags & SRC2_IMM)) {
+ if (src2w) {
+ FAIL_IF(load_immediate(compiler, sugg_src2_r, src2w));
+ src2_r = sugg_src2_r;
+ }
+ else {
+ src2_r = 0;
+ if ((op >= SLJIT_MOV && op <= SLJIT_MOVU_SI) && (dst & SLJIT_MEM))
+ dst_r = 0;
+ }
+ }
+ }
+ else {
+ if (getput_arg_fast(compiler, flags | LOAD_DATA, sugg_src2_r, src2, src2w))
+ FAIL_IF(compiler->error);
+ else
+ flags |= SLOW_SRC2;
+ src2_r = sugg_src2_r;
+ }
+
+ if ((flags & (SLOW_SRC1 | SLOW_SRC2)) == (SLOW_SRC1 | SLOW_SRC2)) {
+ SLJIT_ASSERT(src2_r == TMP_REG2);
+ if (!can_cache(src1, src1w, src2, src2w) && can_cache(src1, src1w, dst, dstw)) {
+ FAIL_IF(getput_arg(compiler, flags | LOAD_DATA, TMP_REG2, src2, src2w, src1, src1w));
+ FAIL_IF(getput_arg(compiler, flags | LOAD_DATA, TMP_REG1, src1, src1w, dst, dstw));
+ }
+ else {
+ FAIL_IF(getput_arg(compiler, flags | LOAD_DATA, TMP_REG1, src1, src1w, src2, src2w));
+ FAIL_IF(getput_arg(compiler, flags | LOAD_DATA, TMP_REG2, src2, src2w, dst, dstw));
+ }
+ }
+ else if (flags & SLOW_SRC1)
+ FAIL_IF(getput_arg(compiler, flags | LOAD_DATA, TMP_REG1, src1, src1w, dst, dstw));
+ else if (flags & SLOW_SRC2)
+ FAIL_IF(getput_arg(compiler, flags | LOAD_DATA, sugg_src2_r, src2, src2w, dst, dstw));
+
+ FAIL_IF(emit_single_op(compiler, op, flags, dst_r, src1_r, src2_r));
+
+ if (dst & SLJIT_MEM) {
+ if (!(flags & SLOW_DEST)) {
+ getput_arg_fast(compiler, flags, dst_r, dst, dstw);
+ return compiler->error;
+ }
+ return getput_arg(compiler, flags, dst_r, dst, dstw, 0, 0);
+ }
+
+ return SLJIT_SUCCESS;
+}
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op)
+{
+ CHECK_ERROR();
+ check_sljit_emit_op0(compiler, op);
+
+ op = GET_OPCODE(op);
+ switch (op) {
+ case SLJIT_BREAKPOINT:
+ return push_inst(compiler, TA, UNMOVABLE_INS);
+ case SLJIT_NOP:
+ return push_inst(compiler, NOP, UNMOVABLE_INS);
+ case SLJIT_UMUL:
+ case SLJIT_SMUL:
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+ FAIL_IF(push_inst(compiler, (op == SLJIT_UMUL ? UMUL : SMUL) | D(SLJIT_SCRATCH_REG1) | S1(SLJIT_SCRATCH_REG1) | S2(SLJIT_SCRATCH_REG2), DR(SLJIT_SCRATCH_REG1)));
+ return push_inst(compiler, RDY | D(SLJIT_SCRATCH_REG2), DR(SLJIT_SCRATCH_REG2));
+#else
+#error "Implementation required"
+#endif
+ case SLJIT_UDIV:
+ case SLJIT_SDIV:
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+ if (op == SLJIT_UDIV)
+ FAIL_IF(push_inst(compiler, WRY | S1(0), MOVABLE_INS));
+ else {
+ FAIL_IF(push_inst(compiler, SRA | D(TMP_REG1) | S1(SLJIT_SCRATCH_REG1) | IMM(31), DR(TMP_REG1)));
+ FAIL_IF(push_inst(compiler, WRY | S1(TMP_REG1), MOVABLE_INS));
+ }
+ FAIL_IF(push_inst(compiler, OR | D(TMP_REG2) | S1(0) | S2(SLJIT_SCRATCH_REG1), DR(TMP_REG2)));
+ FAIL_IF(push_inst(compiler, (op == SLJIT_UDIV ? UDIV : SDIV) | D(SLJIT_SCRATCH_REG1) | S1(SLJIT_SCRATCH_REG1) | S2(SLJIT_SCRATCH_REG2), DR(SLJIT_SCRATCH_REG1)));
+ FAIL_IF(push_inst(compiler, SMUL | D(SLJIT_SCRATCH_REG2) | S1(SLJIT_SCRATCH_REG1) | S2(SLJIT_SCRATCH_REG2), DR(SLJIT_SCRATCH_REG2)));
+ FAIL_IF(push_inst(compiler, SUB | D(SLJIT_SCRATCH_REG2) | S1(TMP_REG2) | S2(SLJIT_SCRATCH_REG2), DR(SLJIT_SCRATCH_REG2)));
+ return SLJIT_SUCCESS;
+#else
+#error "Implementation required"
+#endif
+ }
+
+ return SLJIT_SUCCESS;
+}
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
+{
+ sljit_si flags = GET_FLAGS(op) ? SET_FLAGS : 0;
+
+ CHECK_ERROR();
+ check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
+
+ op = GET_OPCODE(op);
+ switch (op) {
+ case SLJIT_MOV:
+ case SLJIT_MOV_P:
+ return emit_op(compiler, SLJIT_MOV, flags | WORD_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
+
+ case SLJIT_MOV_UI:
+ return emit_op(compiler, SLJIT_MOV_UI, flags | INT_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
+
+ case SLJIT_MOV_SI:
+ return emit_op(compiler, SLJIT_MOV_SI, flags | INT_DATA | SIGNED_DATA, dst, dstw, TMP_REG1, 0, src, srcw);
+
+ case SLJIT_MOV_UB:
+ return emit_op(compiler, SLJIT_MOV_UB, flags | BYTE_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_ub)srcw : srcw);
+
+ case SLJIT_MOV_SB:
+ return emit_op(compiler, SLJIT_MOV_SB, flags | BYTE_DATA | SIGNED_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_sb)srcw : srcw);
+
+ case SLJIT_MOV_UH:
+ return emit_op(compiler, SLJIT_MOV_UH, flags | HALF_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_uh)srcw : srcw);
+
+ case SLJIT_MOV_SH:
+ return emit_op(compiler, SLJIT_MOV_SH, flags | HALF_DATA | SIGNED_DATA, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_sh)srcw : srcw);
+
+ case SLJIT_MOVU:
+ case SLJIT_MOVU_P:
+ return emit_op(compiler, SLJIT_MOV, flags | WORD_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
+
+ case SLJIT_MOVU_UI:
+ return emit_op(compiler, SLJIT_MOV_UI, flags | INT_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
+
+ case SLJIT_MOVU_SI:
+ return emit_op(compiler, SLJIT_MOV_SI, flags | INT_DATA | SIGNED_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, srcw);
+
+ case SLJIT_MOVU_UB:
+ return emit_op(compiler, SLJIT_MOV_UB, flags | BYTE_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_ub)srcw : srcw);
+
+ case SLJIT_MOVU_SB:
+ return emit_op(compiler, SLJIT_MOV_SB, flags | BYTE_DATA | SIGNED_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_sb)srcw : srcw);
+
+ case SLJIT_MOVU_UH:
+ return emit_op(compiler, SLJIT_MOV_UH, flags | HALF_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_uh)srcw : srcw);
+
+ case SLJIT_MOVU_SH:
+ return emit_op(compiler, SLJIT_MOV_SH, flags | HALF_DATA | SIGNED_DATA | WRITE_BACK, dst, dstw, TMP_REG1, 0, src, (src & SLJIT_IMM) ? (sljit_sh)srcw : srcw);
+
+ case SLJIT_NOT:
+ case SLJIT_CLZ:
+ return emit_op(compiler, op, flags, dst, dstw, TMP_REG1, 0, src, srcw);
+
+ case SLJIT_NEG:
+ return emit_op(compiler, SLJIT_SUB, flags | IMM_OP, dst, dstw, SLJIT_IMM, 0, src, srcw);
+ }
+
+ return SLJIT_SUCCESS;
+}
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
+{
+ sljit_si flags = GET_FLAGS(op) ? SET_FLAGS : 0;
+
+ CHECK_ERROR();
+ check_sljit_emit_op2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src1, src1w);
+ ADJUST_LOCAL_OFFSET(src2, src2w);
+
+ op = GET_OPCODE(op);
+ switch (op) {
+ case SLJIT_ADD:
+ case SLJIT_ADDC:
+ case SLJIT_MUL:
+ case SLJIT_AND:
+ case SLJIT_OR:
+ case SLJIT_XOR:
+ return emit_op(compiler, op, flags | CUMULATIVE_OP | IMM_OP, dst, dstw, src1, src1w, src2, src2w);
+
+ case SLJIT_SUB:
+ case SLJIT_SUBC:
+ return emit_op(compiler, op, flags | IMM_OP, dst, dstw, src1, src1w, src2, src2w);
+
+ case SLJIT_SHL:
+ case SLJIT_LSHR:
+ case SLJIT_ASHR:
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+ if (src2 & SLJIT_IMM)
+ src2w &= 0x1f;
+#else
+ SLJIT_ASSERT_STOP();
+#endif
+ return emit_op(compiler, op, flags | IMM_OP, dst, dstw, src1, src1w, src2, src2w);
+ }
+
+ return SLJIT_SUCCESS;
+}
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg)
+{
+ check_sljit_get_register_index(reg);
+ return reg_map[reg];
+}
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler,
+ void *instruction, sljit_si size)
+{
+ CHECK_ERROR();
+ check_sljit_emit_op_custom(compiler, instruction, size);
+ SLJIT_ASSERT(size == 4);
+
+ return push_inst(compiler, *(sljit_ins*)instruction, UNMOVABLE_INS);
+}
+
+/* --------------------------------------------------------------------- */
+/* Floating point operators */
+/* --------------------------------------------------------------------- */
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_is_fpu_available(void)
+{
+ return 1;
+}
+
+#define FLOAT_DATA(op) (DOUBLE_DATA | ((op & SLJIT_SINGLE_OP) >> 7))
+#define SELECT_FOP(op, single, double) ((op & SLJIT_SINGLE_OP) ? single : double)
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
+{
+ sljit_si dst_fr;
+
+ CHECK_ERROR();
+ check_sljit_emit_fop1(compiler, op, dst, dstw, src, srcw);
+ SLJIT_COMPILE_ASSERT((SLJIT_SINGLE_OP == 0x100) && !(DOUBLE_DATA & 0x2), float_transfer_bit_error);
+
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+
+ if (GET_OPCODE(op) == SLJIT_CMPD) {
+ if (dst > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, dst, dstw, src, srcw));
+ dst = TMP_FREG1;
+ }
+ else
+ dst <<= 1;
+
+ if (src > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src, srcw, 0, 0));
+ src = TMP_FREG2;
+ }
+ else
+ src <<= 1;
+
+ return push_inst(compiler, SELECT_FOP(op, FCMPS, FCMPD) | S1A(dst) | S2A(src), FCC_IS_SET | MOVABLE_INS);
+ }
+
+ dst_fr = (dst > SLJIT_FLOAT_REG6) ? TMP_FREG1 : (dst << 1);
+
+ if (src > SLJIT_FLOAT_REG6) {
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op) | LOAD_DATA, dst_fr, src, srcw, dst, dstw));
+ src = dst_fr;
+ }
+ else
+ src <<= 1;
+
+ switch (GET_OPCODE(op)) {
+ case SLJIT_MOVD:
+ if (src != dst_fr && dst_fr != TMP_FREG1) {
+ FAIL_IF(push_inst(compiler, FMOVS | DA(dst_fr) | S2A(src), MOVABLE_INS));
+ if (!(op & SLJIT_SINGLE_OP))
+ FAIL_IF(push_inst(compiler, FMOVS | DA(dst_fr | 1) | S2A(src | 1), MOVABLE_INS));
+ }
+ break;
+ case SLJIT_NEGD:
+ FAIL_IF(push_inst(compiler, FNEGS | DA(dst_fr) | S2A(src), MOVABLE_INS));
+ if (dst_fr != src && !(op & SLJIT_SINGLE_OP))
+ FAIL_IF(push_inst(compiler, FMOVS | DA(dst_fr | 1) | S2A(src | 1), MOVABLE_INS));
+ break;
+ case SLJIT_ABSD:
+ FAIL_IF(push_inst(compiler, FABSS | DA(dst_fr) | S2A(src), MOVABLE_INS));
+ if (dst_fr != src && !(op & SLJIT_SINGLE_OP))
+ FAIL_IF(push_inst(compiler, FMOVS | DA(dst_fr | 1) | S2A(src | 1), MOVABLE_INS));
+ break;
+ }
+
+ if (dst_fr == TMP_FREG1) {
+ if (GET_OPCODE(op) == SLJIT_MOVD)
+ dst_fr = src;
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op), dst_fr, dst, dstw, 0, 0));
+ }
+
+ return SLJIT_SUCCESS;
+}
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
+{
+ sljit_si dst_fr, flags = 0;
+
+ CHECK_ERROR();
+ check_sljit_emit_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
+
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+
+ dst_fr = (dst > SLJIT_FLOAT_REG6) ? TMP_FREG2 : (dst << 1);
+
+ if (src1 > SLJIT_FLOAT_REG6) {
+ if (getput_arg_fast(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, src1, src1w)) {
+ FAIL_IF(compiler->error);
+ src1 = TMP_FREG1;
+ } else
+ flags |= SLOW_SRC1;
+ }
+ else
+ src1 <<= 1;
+
+ if (src2 > SLJIT_FLOAT_REG6) {
+ if (getput_arg_fast(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src2, src2w)) {
+ FAIL_IF(compiler->error);
+ src2 = TMP_FREG2;
+ } else
+ flags |= SLOW_SRC2;
+ }
+ else
+ src2 <<= 1;
+
+ if ((flags & (SLOW_SRC1 | SLOW_SRC2)) == (SLOW_SRC1 | SLOW_SRC2)) {
+ if (!can_cache(src1, src1w, src2, src2w) && can_cache(src1, src1w, dst, dstw)) {
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src2, src2w, src1, src1w));
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, src1, src1w, dst, dstw));
+ }
+ else {
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, src1, src1w, src2, src2w));
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src2, src2w, dst, dstw));
+ }
+ }
+ else if (flags & SLOW_SRC1)
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG1, src1, src1w, dst, dstw));
+ else if (flags & SLOW_SRC2)
+ FAIL_IF(getput_arg(compiler, FLOAT_DATA(op) | LOAD_DATA, TMP_FREG2, src2, src2w, dst, dstw));
+
+ if (flags & SLOW_SRC1)
+ src1 = TMP_FREG1;
+ if (flags & SLOW_SRC2)
+ src2 = TMP_FREG2;
+
+ switch (GET_OPCODE(op)) {
+ case SLJIT_ADDD:
+ FAIL_IF(push_inst(compiler, SELECT_FOP(op, FADDS, FADDD) | DA(dst_fr) | S1A(src1) | S2A(src2), MOVABLE_INS));
+ break;
+
+ case SLJIT_SUBD:
+ FAIL_IF(push_inst(compiler, SELECT_FOP(op, FSUBS, FSUBD) | DA(dst_fr) | S1A(src1) | S2A(src2), MOVABLE_INS));
+ break;
+
+ case SLJIT_MULD:
+ FAIL_IF(push_inst(compiler, SELECT_FOP(op, FMULS, FMULD) | DA(dst_fr) | S1A(src1) | S2A(src2), MOVABLE_INS));
+ break;
+
+ case SLJIT_DIVD:
+ FAIL_IF(push_inst(compiler, SELECT_FOP(op, FDIVS, FDIVD) | DA(dst_fr) | S1A(src1) | S2A(src2), MOVABLE_INS));
+ break;
+ }
+
+ if (dst_fr == TMP_FREG2)
+ FAIL_IF(emit_op_mem2(compiler, FLOAT_DATA(op), TMP_FREG2, dst, dstw, 0, 0));
+
+ return SLJIT_SUCCESS;
+}
+
+#undef FLOAT_DATA
+#undef SELECT_FOP
+
+/* --------------------------------------------------------------------- */
+/* Other instructions */
+/* --------------------------------------------------------------------- */
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_enter(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw)
+{
+ CHECK_ERROR();
+ check_sljit_emit_fast_enter(compiler, dst, dstw);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+
+ /* For UNUSED dst. Uncommon, but possible. */
+ if (dst == SLJIT_UNUSED)
+ return SLJIT_SUCCESS;
+
+ if (dst <= TMP_REG3)
+ return push_inst(compiler, OR | D(dst) | S1(0) | S2(LINK_REG), DR(dst));
+
+ /* Memory. */
+ return emit_op_mem(compiler, WORD_DATA, LINK_REG, dst, dstw);
+}
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_return(struct sljit_compiler *compiler, sljit_si src, sljit_sw srcw)
+{
+ CHECK_ERROR();
+ check_sljit_emit_fast_return(compiler, src, srcw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
+
+ if (src <= TMP_REG3)
+ FAIL_IF(push_inst(compiler, OR | D(LINK_REG) | S1(0) | S2(src), DR(LINK_REG)));
+ else if (src & SLJIT_MEM)
+ FAIL_IF(emit_op_mem(compiler, WORD_DATA | LOAD_DATA, LINK_REG, src, srcw));
+ else if (src & SLJIT_IMM)
+ FAIL_IF(load_immediate(compiler, LINK_REG, srcw));
+
+ FAIL_IF(push_inst(compiler, JMPL | D(0) | S1(LINK_REG) | IMM(8), UNMOVABLE_INS));
+ return push_inst(compiler, NOP, UNMOVABLE_INS);
+}
+
+/* --------------------------------------------------------------------- */
+/* Conditional instructions */
+/* --------------------------------------------------------------------- */
+
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_label* sljit_emit_label(struct sljit_compiler *compiler)
+{
+ struct sljit_label *label;
+
+ CHECK_ERROR_PTR();
+ check_sljit_emit_label(compiler);
+
+ if (compiler->last_label && compiler->last_label->size == compiler->size)
+ return compiler->last_label;
+
+ label = (struct sljit_label*)ensure_abuf(compiler, sizeof(struct sljit_label));
+ PTR_FAIL_IF(!label);
+ set_label(label, compiler);
+ compiler->delay_slot = UNMOVABLE_INS;
+ return label;
+}
+
+static sljit_ins get_cc(sljit_si type)
+{
+ switch (type) {
+ case SLJIT_C_EQUAL:
+ case SLJIT_C_MUL_NOT_OVERFLOW:
+ return DA(0x1);
+
+ case SLJIT_C_NOT_EQUAL:
+ case SLJIT_C_MUL_OVERFLOW:
+ return DA(0x9);
+
+ case SLJIT_C_LESS:
+ return DA(0x5);
+
+ case SLJIT_C_GREATER_EQUAL:
+ return DA(0xd);
+
+ case SLJIT_C_GREATER:
+ return DA(0xc);
+
+ case SLJIT_C_LESS_EQUAL:
+ return DA(0x4);
+
+ case SLJIT_C_SIG_LESS:
+ return DA(0x3);
+
+ case SLJIT_C_SIG_GREATER_EQUAL:
+ return DA(0xb);
+
+ case SLJIT_C_SIG_GREATER:
+ return DA(0xa);
+
+ case SLJIT_C_SIG_LESS_EQUAL:
+ return DA(0x2);
+
+ case SLJIT_C_OVERFLOW:
+ return DA(0x7);
+
+ case SLJIT_C_NOT_OVERFLOW:
+ return DA(0xf);
+
+ case SLJIT_C_FLOAT_EQUAL:
+ return DA(0x9);
+
+ case SLJIT_C_FLOAT_NOT_EQUAL: /* Unordered. */
+ return DA(0x1);
+
+ case SLJIT_C_FLOAT_LESS:
+ return DA(0x4);
+
+ case SLJIT_C_FLOAT_GREATER_EQUAL: /* Unordered. */
+ return DA(0xc);
+
+ case SLJIT_C_FLOAT_LESS_EQUAL:
+ return DA(0xd);
+
+ case SLJIT_C_FLOAT_GREATER: /* Unordered. */
+ return DA(0x5);
+
+ case SLJIT_C_FLOAT_UNORDERED:
+ return DA(0x7);
+
+ case SLJIT_C_FLOAT_ORDERED:
+ return DA(0xf);
+
+ default:
+ SLJIT_ASSERT_STOP();
+ return DA(0x8);
+ }
+}
+
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, sljit_si type)
+{
+ struct sljit_jump *jump;
+
+ CHECK_ERROR_PTR();
+ check_sljit_emit_jump(compiler, type);
+
+ jump = (struct sljit_jump*)ensure_abuf(compiler, sizeof(struct sljit_jump));
+ PTR_FAIL_IF(!jump);
+ set_jump(jump, compiler, type & SLJIT_REWRITABLE_JUMP);
+ type &= 0xff;
+
+ if (type < SLJIT_C_FLOAT_EQUAL) {
+ jump->flags |= IS_COND;
+ if (((compiler->delay_slot & DST_INS_MASK) != UNMOVABLE_INS) && !(compiler->delay_slot & ICC_IS_SET))
+ jump->flags |= IS_MOVABLE;
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+ PTR_FAIL_IF(push_inst(compiler, BICC | get_cc(type ^ 1) | 5, UNMOVABLE_INS));
+#else
+#error "Implementation required"
+#endif
+ }
+ else if (type < SLJIT_JUMP) {
+ jump->flags |= IS_COND;
+ if (((compiler->delay_slot & DST_INS_MASK) != UNMOVABLE_INS) && !(compiler->delay_slot & FCC_IS_SET))
+ jump->flags |= IS_MOVABLE;
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+ PTR_FAIL_IF(push_inst(compiler, FBFCC | get_cc(type ^ 1) | 5, UNMOVABLE_INS));
+#else
+#error "Implementation required"
+#endif
+ } else {
+ if ((compiler->delay_slot & DST_INS_MASK) != UNMOVABLE_INS)
+ jump->flags |= IS_MOVABLE;
+ if (type >= SLJIT_FAST_CALL)
+ jump->flags |= IS_CALL;
+ }
+
+ PTR_FAIL_IF(emit_const(compiler, TMP_REG2, 0));
+ PTR_FAIL_IF(push_inst(compiler, JMPL | D(type >= SLJIT_FAST_CALL ? LINK_REG : 0) | S1(TMP_REG2) | IMM(0), UNMOVABLE_INS));
+ jump->addr = compiler->size;
+ PTR_FAIL_IF(push_inst(compiler, NOP, UNMOVABLE_INS));
+
+ return jump;
+}
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_ijump(struct sljit_compiler *compiler, sljit_si type, sljit_si src, sljit_sw srcw)
+{
+ struct sljit_jump *jump = NULL;
+ sljit_si src_r;
+
+ CHECK_ERROR();
+ check_sljit_emit_ijump(compiler, type, src, srcw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
+
+ if (src <= TMP_REG3)
+ src_r = src;
+ else if (src & SLJIT_IMM) {
+ jump = (struct sljit_jump*)ensure_abuf(compiler, sizeof(struct sljit_jump));
+ FAIL_IF(!jump);
+ set_jump(jump, compiler, JUMP_ADDR);
+ jump->u.target = srcw;
+ if ((compiler->delay_slot & DST_INS_MASK) != UNMOVABLE_INS)
+ jump->flags |= IS_MOVABLE;
+ if (type >= SLJIT_FAST_CALL)
+ jump->flags |= IS_CALL;
+
+ FAIL_IF(emit_const(compiler, TMP_REG2, 0));
+ src_r = TMP_REG2;
+ }
+ else {
+ FAIL_IF(emit_op_mem(compiler, WORD_DATA | LOAD_DATA, TMP_REG2, src, srcw));
+ src_r = TMP_REG2;
+ }
+
+ FAIL_IF(push_inst(compiler, JMPL | D(type >= SLJIT_FAST_CALL ? LINK_REG : 0) | S1(src_r) | IMM(0), UNMOVABLE_INS));
+ if (jump)
+ jump->addr = compiler->size;
+ return push_inst(compiler, NOP, UNMOVABLE_INS);
+}
+
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_flags(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw,
+ sljit_si type)
+{
+ sljit_si reg, flags = (GET_FLAGS(op) ? SET_FLAGS : 0);
+
+ CHECK_ERROR();
+ check_sljit_emit_op_flags(compiler, op, dst, dstw, src, srcw, type);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+
+ if (dst == SLJIT_UNUSED)
+ return SLJIT_SUCCESS;
+
+#if (defined SLJIT_CONFIG_SPARC_32 && SLJIT_CONFIG_SPARC_32)
+ op = GET_OPCODE(op);
+ reg = (op < SLJIT_ADD && dst <= TMP_REG3) ? dst : TMP_REG2;
+
+ compiler->cache_arg = 0;
+ compiler->cache_argw = 0;
+ if (op >= SLJIT_ADD && (src & SLJIT_MEM)) {
+ ADJUST_LOCAL_OFFSET(src, srcw);
+ FAIL_IF(emit_op_mem2(compiler, WORD_DATA | LOAD_DATA, TMP_REG1, src, srcw, dst, dstw));
+ src = TMP_REG1;
+ srcw = 0;
+ }
+
+ if (type < SLJIT_C_FLOAT_EQUAL)
+ FAIL_IF(push_inst(compiler, BICC | get_cc(type) | 3, UNMOVABLE_INS));
+ else
+ FAIL_IF(push_inst(compiler, FBFCC | get_cc(type) | 3, UNMOVABLE_INS));
+
+ FAIL_IF(push_inst(compiler, OR | D(reg) | S1(0) | IMM(1), UNMOVABLE_INS));
+ FAIL_IF(push_inst(compiler, OR | D(reg) | S1(0) | IMM(0), UNMOVABLE_INS));
+
+ if (op >= SLJIT_ADD)
+ return emit_op(compiler, op, flags | CUMULATIVE_OP | IMM_OP | ALT_KEEP_CACHE, dst, dstw, src, srcw, TMP_REG2, 0);
+
+ return (reg == TMP_REG2) ? emit_op_mem(compiler, WORD_DATA, TMP_REG2, dst, dstw) : SLJIT_SUCCESS;
+#else
+#error "Implementation required"
+#endif
+}
+
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw init_value)
+{
+ sljit_si reg;
+ struct sljit_const *const_;
+
+ CHECK_ERROR_PTR();
+ check_sljit_emit_const(compiler, dst, dstw, init_value);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+
+ const_ = (struct sljit_const*)ensure_abuf(compiler, sizeof(struct sljit_const));
+ PTR_FAIL_IF(!const_);
+ set_const(const_, compiler);
+
+ reg = (dst <= TMP_REG3) ? dst : TMP_REG2;
+
+ PTR_FAIL_IF(emit_const(compiler, reg, init_value));
+
+ if (dst & SLJIT_MEM)
+ PTR_FAIL_IF(emit_op_mem(compiler, WORD_DATA, TMP_REG2, dst, dstw));
+
+ return const_;
+}
diff --git a/src/3rdparty/pcre/sljit/sljitNativeX86_32.c b/src/3rdparty/pcre/sljit/sljitNativeX86_32.c
index 68bca8441a..03a595bd85 100644
--- a/src/3rdparty/pcre/sljit/sljitNativeX86_32.c
+++ b/src/3rdparty/pcre/sljit/sljitNativeX86_32.c
@@ -26,30 +26,30 @@
/* x86 32-bit arch dependent functions. */
-static int emit_do_imm(struct sljit_compiler *compiler, sljit_ub opcode, sljit_w imm)
+static sljit_si emit_do_imm(struct sljit_compiler *compiler, sljit_ub opcode, sljit_sw imm)
{
- sljit_ub *buf;
+ sljit_ub *inst;
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1 + sizeof(sljit_w));
- FAIL_IF(!buf);
- INC_SIZE(1 + sizeof(sljit_w));
- *buf++ = opcode;
- *(sljit_w*)buf = imm;
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1 + sizeof(sljit_sw));
+ FAIL_IF(!inst);
+ INC_SIZE(1 + sizeof(sljit_sw));
+ *inst++ = opcode;
+ *(sljit_sw*)inst = imm;
return SLJIT_SUCCESS;
}
-static sljit_ub* generate_far_jump_code(struct sljit_jump *jump, sljit_ub *code_ptr, int type)
+static sljit_ub* generate_far_jump_code(struct sljit_jump *jump, sljit_ub *code_ptr, sljit_si type)
{
if (type == SLJIT_JUMP) {
- *code_ptr++ = 0xe9;
+ *code_ptr++ = JMP_i32;
jump->addr++;
}
else if (type >= SLJIT_FAST_CALL) {
- *code_ptr++ = 0xe8;
+ *code_ptr++ = CALL_i32;
jump->addr++;
}
else {
- *code_ptr++ = 0x0f;
+ *code_ptr++ = GROUP_0F;
*code_ptr++ = get_jump_code(type);
jump->addr += 2;
}
@@ -57,39 +57,43 @@ static sljit_ub* generate_far_jump_code(struct sljit_jump *jump, sljit_ub *code_
if (jump->flags & JUMP_LABEL)
jump->flags |= PATCH_MW;
else
- *(sljit_w*)code_ptr = jump->u.target - (jump->addr + 4);
+ *(sljit_sw*)code_ptr = jump->u.target - (jump->addr + 4);
code_ptr += 4;
return code_ptr;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_enter(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
- int size;
- sljit_ub *buf;
+ sljit_si size;
+ sljit_si locals_offset;
+ sljit_ub *inst;
CHECK_ERROR();
- check_sljit_emit_enter(compiler, args, temporaries, saveds, local_size);
+ check_sljit_emit_enter(compiler, args, scratches, saveds, local_size);
- compiler->temporaries = temporaries;
+ compiler->scratches = scratches;
compiler->saveds = saveds;
compiler->args = args;
compiler->flags_saved = 0;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
#if (defined SLJIT_X86_32_FASTCALL && SLJIT_X86_32_FASTCALL)
size = 1 + (saveds <= 3 ? saveds : 3) + (args > 0 ? (args * 2) : 0) + (args > 2 ? 2 : 0);
#else
size = 1 + (saveds <= 3 ? saveds : 3) + (args > 0 ? (2 + args * 3) : 0);
#endif
- buf = (sljit_ub*)ensure_buf(compiler, 1 + size);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + size);
+ FAIL_IF(!inst);
INC_SIZE(size);
PUSH_REG(reg_map[TMP_REGISTER]);
#if !(defined SLJIT_X86_32_FASTCALL && SLJIT_X86_32_FASTCALL)
if (args > 0) {
- *buf++ = 0x8b;
- *buf++ = 0xc4 | (reg_map[TMP_REGISTER] << 3);
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (reg_map[TMP_REGISTER] << 3) | 0x4 /* esp */;
}
#endif
if (saveds > 2)
@@ -101,81 +105,105 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, i
#if (defined SLJIT_X86_32_FASTCALL && SLJIT_X86_32_FASTCALL)
if (args > 0) {
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (reg_map[SLJIT_SAVED_REG1] << 3) | reg_map[SLJIT_TEMPORARY_REG3];
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (reg_map[SLJIT_SAVED_REG1] << 3) | reg_map[SLJIT_SCRATCH_REG3];
}
if (args > 1) {
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (reg_map[SLJIT_SAVED_REG2] << 3) | reg_map[SLJIT_TEMPORARY_REG2];
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (reg_map[SLJIT_SAVED_REG2] << 3) | reg_map[SLJIT_SCRATCH_REG2];
}
if (args > 2) {
- *buf++ = 0x8b;
- *buf++ = 0x44 | (reg_map[SLJIT_SAVED_REG3] << 3);
- *buf++ = 0x24;
- *buf++ = sizeof(sljit_w) * (3 + 2); /* saveds >= 3 as well. */
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_DISP8 | (reg_map[SLJIT_SAVED_REG3] << 3) | 0x4 /* esp */;
+ *inst++ = 0x24;
+ *inst++ = sizeof(sljit_sw) * (3 + 2); /* saveds >= 3 as well. */
}
#else
if (args > 0) {
- *buf++ = 0x8b;
- *buf++ = 0x40 | (reg_map[SLJIT_SAVED_REG1] << 3) | reg_map[TMP_REGISTER];
- *buf++ = sizeof(sljit_w) * 2;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_DISP8 | (reg_map[SLJIT_SAVED_REG1] << 3) | reg_map[TMP_REGISTER];
+ *inst++ = sizeof(sljit_sw) * 2;
}
if (args > 1) {
- *buf++ = 0x8b;
- *buf++ = 0x40 | (reg_map[SLJIT_SAVED_REG2] << 3) | reg_map[TMP_REGISTER];
- *buf++ = sizeof(sljit_w) * 3;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_DISP8 | (reg_map[SLJIT_SAVED_REG2] << 3) | reg_map[TMP_REGISTER];
+ *inst++ = sizeof(sljit_sw) * 3;
}
if (args > 2) {
- *buf++ = 0x8b;
- *buf++ = 0x40 | (reg_map[SLJIT_SAVED_REG3] << 3) | reg_map[TMP_REGISTER];
- *buf++ = sizeof(sljit_w) * 4;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_DISP8 | (reg_map[SLJIT_SAVED_REG3] << 3) | reg_map[TMP_REGISTER];
+ *inst++ = sizeof(sljit_sw) * 4;
}
#endif
- local_size = (local_size + sizeof(sljit_uw) - 1) & ~(sizeof(sljit_uw) - 1);
- compiler->temporaries_start = local_size;
- if (temporaries > 3)
- local_size += (temporaries - 3) * sizeof(sljit_uw);
- compiler->saveds_start = local_size;
+#if (defined SLJIT_X86_32_FASTCALL && SLJIT_X86_32_FASTCALL)
+ locals_offset = 2 * sizeof(sljit_uw);
+#else
+ SLJIT_COMPILE_ASSERT(FIXED_LOCALS_OFFSET >= 2 * sizeof(sljit_uw), require_at_least_two_words);
+ locals_offset = FIXED_LOCALS_OFFSET;
+#endif
+ compiler->scratches_start = locals_offset;
+ if (scratches > 3)
+ locals_offset += (scratches - 3) * sizeof(sljit_uw);
+ compiler->saveds_start = locals_offset;
if (saveds > 3)
- local_size += (saveds - 3) * sizeof(sljit_uw);
+ locals_offset += (saveds - 3) * sizeof(sljit_uw);
+ compiler->locals_offset = locals_offset;
+ local_size = locals_offset + ((local_size + sizeof(sljit_uw) - 1) & ~(sizeof(sljit_uw) - 1));
+ compiler->local_size = local_size;
#ifdef _WIN32
if (local_size > 1024) {
- FAIL_IF(emit_do_imm(compiler, 0xb8 + reg_map[SLJIT_TEMPORARY_REG1], local_size));
- FAIL_IF(sljit_emit_ijump(compiler, SLJIT_CALL1, SLJIT_IMM, SLJIT_FUNC_OFFSET(sljit_touch_stack)));
+#if (defined SLJIT_X86_32_FASTCALL && SLJIT_X86_32_FASTCALL)
+ FAIL_IF(emit_do_imm(compiler, MOV_r_i32 + reg_map[SLJIT_SCRATCH_REG1], local_size));
+#else
+ local_size -= FIXED_LOCALS_OFFSET;
+ FAIL_IF(emit_do_imm(compiler, MOV_r_i32 + reg_map[SLJIT_SCRATCH_REG1], local_size));
+ FAIL_IF(emit_non_cum_binary(compiler, SUB_r_rm, SUB_rm_r, SUB, SUB_EAX_i32,
+ SLJIT_LOCALS_REG, 0, SLJIT_LOCALS_REG, 0, SLJIT_IMM, FIXED_LOCALS_OFFSET));
+#endif
+ FAIL_IF(sljit_emit_ijump(compiler, SLJIT_CALL1, SLJIT_IMM, SLJIT_FUNC_OFFSET(sljit_grow_stack)));
}
#endif
- compiler->local_size = local_size;
- if (local_size > 0)
- return emit_non_cum_binary(compiler, 0x2b, 0x29, 0x5 << 3, 0x2d,
- SLJIT_LOCALS_REG, 0, SLJIT_LOCALS_REG, 0, SLJIT_IMM, local_size);
-
- return SLJIT_SUCCESS;
+ SLJIT_ASSERT(local_size > 0);
+ return emit_non_cum_binary(compiler, SUB_r_rm, SUB_rm_r, SUB, SUB_EAX_i32,
+ SLJIT_LOCALS_REG, 0, SLJIT_LOCALS_REG, 0, SLJIT_IMM, local_size);
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
+ sljit_si locals_offset;
+
CHECK_ERROR_VOID();
- check_sljit_set_context(compiler, args, temporaries, saveds, local_size);
+ check_sljit_set_context(compiler, args, scratches, saveds, local_size);
- compiler->temporaries = temporaries;
+ compiler->scratches = scratches;
compiler->saveds = saveds;
compiler->args = args;
- compiler->local_size = (local_size + sizeof(sljit_uw) - 1) & ~(sizeof(sljit_uw) - 1);
- compiler->temporaries_start = compiler->local_size;
- if (temporaries > 3)
- compiler->local_size += (temporaries - 3) * sizeof(sljit_uw);
- compiler->saveds_start = compiler->local_size;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
+
+#if (defined SLJIT_X86_32_FASTCALL && SLJIT_X86_32_FASTCALL)
+ locals_offset = 2 * sizeof(sljit_uw);
+#else
+ locals_offset = FIXED_LOCALS_OFFSET;
+#endif
+ compiler->scratches_start = locals_offset;
+ if (scratches > 3)
+ locals_offset += (scratches - 3) * sizeof(sljit_uw);
+ compiler->saveds_start = locals_offset;
if (saveds > 3)
- compiler->local_size += (saveds - 3) * sizeof(sljit_uw);
+ locals_offset += (saveds - 3) * sizeof(sljit_uw);
+ compiler->locals_offset = locals_offset;
+ compiler->local_size = locals_offset + ((local_size + sizeof(sljit_uw) - 1) & ~(sizeof(sljit_uw) - 1));
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler, int op, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_return(struct sljit_compiler *compiler, sljit_si op, sljit_si src, sljit_sw srcw)
{
- int size;
- sljit_ub *buf;
+ sljit_si size;
+ sljit_ub *inst;
CHECK_ERROR();
check_sljit_emit_return(compiler, op, src, srcw);
@@ -184,9 +212,9 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
compiler->flags_saved = 0;
FAIL_IF(emit_mov_before_return(compiler, op, src, srcw));
- if (compiler->local_size > 0)
- FAIL_IF(emit_cum_binary(compiler, 0x03, 0x01, 0x0 << 3, 0x05,
- SLJIT_LOCALS_REG, 0, SLJIT_LOCALS_REG, 0, SLJIT_IMM, compiler->local_size));
+ SLJIT_ASSERT(compiler->local_size > 0);
+ FAIL_IF(emit_cum_binary(compiler, ADD_r_rm, ADD_rm_r, ADD, ADD_EAX_i32,
+ SLJIT_LOCALS_REG, 0, SLJIT_LOCALS_REG, 0, SLJIT_IMM, compiler->local_size));
size = 2 + (compiler->saveds <= 3 ? compiler->saveds : 3);
#if (defined SLJIT_X86_32_FASTCALL && SLJIT_X86_32_FASTCALL)
@@ -196,8 +224,8 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
if (compiler->args > 0)
size += 2;
#endif
- buf = (sljit_ub*)ensure_buf(compiler, 1 + size);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + size);
+ FAIL_IF(!inst);
INC_SIZE(size);
@@ -210,14 +238,11 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
POP_REG(reg_map[TMP_REGISTER]);
#if (defined SLJIT_X86_32_FASTCALL && SLJIT_X86_32_FASTCALL)
if (compiler->args > 2)
- RETN(sizeof(sljit_w));
+ RET_I16(sizeof(sljit_sw));
else
RET();
#else
- if (compiler->args > 0)
- RETN(compiler->args * sizeof(sljit_w));
- else
- RET();
+ RET();
#endif
return SLJIT_SUCCESS;
@@ -228,16 +253,16 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
/* --------------------------------------------------------------------- */
/* Size contains the flags as well. */
-static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
+static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, sljit_si size,
/* The register or immediate operand. */
- int a, sljit_w imma,
+ sljit_si a, sljit_sw imma,
/* The general operand (not immediate). */
- int b, sljit_w immb)
+ sljit_si b, sljit_sw immb)
{
- sljit_ub *buf;
+ sljit_ub *inst;
sljit_ub *buf_ptr;
- int flags = size & ~0xf;
- int inst_size;
+ sljit_si flags = size & ~0xf;
+ sljit_si inst_size;
/* Both cannot be switched on. */
SLJIT_ASSERT((flags & (EX86_BIN_INS | EX86_SHIFT_INS)) != (EX86_BIN_INS | EX86_SHIFT_INS));
@@ -248,13 +273,16 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
#if (defined SLJIT_SSE2 && SLJIT_SSE2)
/* SSE2 and immediate is not possible. */
SLJIT_ASSERT(!(a & SLJIT_IMM) || !(flags & EX86_SSE2));
+ SLJIT_ASSERT((flags & (EX86_PREF_F2 | EX86_PREF_F3)) != (EX86_PREF_F2 | EX86_PREF_F3)
+ && (flags & (EX86_PREF_F2 | EX86_PREF_66)) != (EX86_PREF_F2 | EX86_PREF_66)
+ && (flags & (EX86_PREF_F3 | EX86_PREF_66)) != (EX86_PREF_F3 | EX86_PREF_66));
#endif
size &= 0xf;
inst_size = size;
#if (defined SLJIT_SSE2 && SLJIT_SSE2)
- if (flags & EX86_PREF_F2)
+ if (flags & (EX86_PREF_F2 | EX86_PREF_F3))
inst_size++;
#endif
if (flags & EX86_PREF_66)
@@ -264,13 +292,13 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
inst_size += 1; /* mod r/m byte. */
if (b & SLJIT_MEM) {
if ((b & 0x0f) == SLJIT_UNUSED)
- inst_size += sizeof(sljit_w);
+ inst_size += sizeof(sljit_sw);
else if (immb != 0 && !(b & 0xf0)) {
/* Immediate operand. */
if (immb <= 127 && immb >= -128)
- inst_size += sizeof(sljit_b);
+ inst_size += sizeof(sljit_sb);
else
- inst_size += sizeof(sljit_w);
+ inst_size += sizeof(sljit_sw);
}
if ((b & 0xf) == SLJIT_LOCALS_REG && !(b & 0xf0))
@@ -300,29 +328,31 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
else if (flags & EX86_HALF_ARG)
inst_size += sizeof(short);
else
- inst_size += sizeof(sljit_w);
+ inst_size += sizeof(sljit_sw);
}
else
SLJIT_ASSERT(!(flags & EX86_SHIFT_INS) || a == SLJIT_PREF_SHIFT_REG);
- buf = (sljit_ub*)ensure_buf(compiler, 1 + inst_size);
- PTR_FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + inst_size);
+ PTR_FAIL_IF(!inst);
/* Encoding the byte. */
INC_SIZE(inst_size);
#if (defined SLJIT_SSE2 && SLJIT_SSE2)
if (flags & EX86_PREF_F2)
- *buf++ = 0xf2;
+ *inst++ = 0xf2;
+ if (flags & EX86_PREF_F3)
+ *inst++ = 0xf3;
#endif
if (flags & EX86_PREF_66)
- *buf++ = 0x66;
+ *inst++ = 0x66;
- buf_ptr = buf + size;
+ buf_ptr = inst + size;
/* Encode mod/rm byte. */
if (!(flags & EX86_SHIFT_INS)) {
if ((flags & EX86_BIN_INS) && (a & SLJIT_IMM))
- *buf = (flags & EX86_BYTE_ARG) ? 0x83 : 0x81;
+ *inst = (flags & EX86_BYTE_ARG) ? GROUP_BINARY_83 : GROUP_BINARY_81;
if ((a & SLJIT_IMM) || (a == 0))
*buf_ptr = 0;
@@ -339,19 +369,19 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
else {
if (a & SLJIT_IMM) {
if (imma == 1)
- *buf = 0xd1;
+ *inst = GROUP_SHIFT_1;
else
- *buf = 0xc1;
+ *inst = GROUP_SHIFT_N;
} else
- *buf = 0xd3;
+ *inst = GROUP_SHIFT_CL;
*buf_ptr = 0;
}
if (!(b & SLJIT_MEM))
#if (defined SLJIT_SSE2 && SLJIT_SSE2)
- *buf_ptr++ |= 0xc0 + ((!(flags & EX86_SSE2)) ? reg_map[b] : b);
+ *buf_ptr++ |= MOD_REG + ((!(flags & EX86_SSE2)) ? reg_map[b] : b);
#else
- *buf_ptr++ |= 0xc0 + reg_map[b];
+ *buf_ptr++ |= MOD_REG + reg_map[b];
#endif
else if ((b & 0x0f) != SLJIT_UNUSED) {
if ((b & 0xf0) == SLJIT_UNUSED || (b & 0xf0) == (SLJIT_LOCALS_REG << 4)) {
@@ -373,8 +403,8 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
if (immb <= 127 && immb >= -128)
*buf_ptr++ = immb; /* 8 bit displacement. */
else {
- *(sljit_w*)buf_ptr = immb; /* 32 bit displacement. */
- buf_ptr += sizeof(sljit_w);
+ *(sljit_sw*)buf_ptr = immb; /* 32 bit displacement. */
+ buf_ptr += sizeof(sljit_sw);
}
}
}
@@ -385,8 +415,8 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
}
else {
*buf_ptr++ |= 0x05;
- *(sljit_w*)buf_ptr = immb; /* 32 bit displacement. */
- buf_ptr += sizeof(sljit_w);
+ *(sljit_sw*)buf_ptr = immb; /* 32 bit displacement. */
+ buf_ptr += sizeof(sljit_sw);
}
if (a & SLJIT_IMM) {
@@ -395,121 +425,121 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
else if (flags & EX86_HALF_ARG)
*(short*)buf_ptr = imma;
else if (!(flags & EX86_SHIFT_INS))
- *(sljit_w*)buf_ptr = imma;
+ *(sljit_sw*)buf_ptr = imma;
}
- return !(flags & EX86_SHIFT_INS) ? buf : (buf + 1);
+ return !(flags & EX86_SHIFT_INS) ? inst : (inst + 1);
}
/* --------------------------------------------------------------------- */
/* Call / return instructions */
/* --------------------------------------------------------------------- */
-static SLJIT_INLINE int call_with_args(struct sljit_compiler *compiler, int type)
+static SLJIT_INLINE sljit_si call_with_args(struct sljit_compiler *compiler, sljit_si type)
{
- sljit_ub *buf;
+ sljit_ub *inst;
#if (defined SLJIT_X86_32_FASTCALL && SLJIT_X86_32_FASTCALL)
- buf = (sljit_ub*)ensure_buf(compiler, type >= SLJIT_CALL3 ? 1 + 2 + 1 : 1 + 2);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, type >= SLJIT_CALL3 ? 1 + 2 + 1 : 1 + 2);
+ FAIL_IF(!inst);
INC_SIZE(type >= SLJIT_CALL3 ? 2 + 1 : 2);
if (type >= SLJIT_CALL3)
- PUSH_REG(reg_map[SLJIT_TEMPORARY_REG3]);
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (reg_map[SLJIT_TEMPORARY_REG3] << 3) | reg_map[SLJIT_TEMPORARY_REG1];
+ PUSH_REG(reg_map[SLJIT_SCRATCH_REG3]);
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (reg_map[SLJIT_SCRATCH_REG3] << 3) | reg_map[SLJIT_SCRATCH_REG1];
#else
- buf = (sljit_ub*)ensure_buf(compiler, type - SLJIT_CALL0 + 1);
- FAIL_IF(!buf);
- INC_SIZE(type - SLJIT_CALL0);
- if (type >= SLJIT_CALL3)
- PUSH_REG(reg_map[SLJIT_TEMPORARY_REG3]);
- if (type >= SLJIT_CALL2)
- PUSH_REG(reg_map[SLJIT_TEMPORARY_REG2]);
- PUSH_REG(reg_map[SLJIT_TEMPORARY_REG1]);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 4 * (type - SLJIT_CALL0));
+ FAIL_IF(!inst);
+ INC_SIZE(4 * (type - SLJIT_CALL0));
+
+ *inst++ = MOV_rm_r;
+ *inst++ = MOD_DISP8 | (reg_map[SLJIT_SCRATCH_REG1] << 3) | 0x4 /* SIB */;
+ *inst++ = (0x4 /* none*/ << 3) | reg_map[SLJIT_LOCALS_REG];
+ *inst++ = 0;
+ if (type >= SLJIT_CALL2) {
+ *inst++ = MOV_rm_r;
+ *inst++ = MOD_DISP8 | (reg_map[SLJIT_SCRATCH_REG2] << 3) | 0x4 /* SIB */;
+ *inst++ = (0x4 /* none*/ << 3) | reg_map[SLJIT_LOCALS_REG];
+ *inst++ = sizeof(sljit_sw);
+ }
+ if (type >= SLJIT_CALL3) {
+ *inst++ = MOV_rm_r;
+ *inst++ = MOD_DISP8 | (reg_map[SLJIT_SCRATCH_REG3] << 3) | 0x4 /* SIB */;
+ *inst++ = (0x4 /* none*/ << 3) | reg_map[SLJIT_LOCALS_REG];
+ *inst++ = 2 * sizeof(sljit_sw);
+ }
#endif
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_enter(struct sljit_compiler *compiler, int dst, sljit_w dstw, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_enter(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw)
{
- sljit_ub *buf;
+ sljit_ub *inst;
CHECK_ERROR();
- check_sljit_emit_fast_enter(compiler, dst, dstw, args, temporaries, saveds, local_size);
-
- compiler->temporaries = temporaries;
- compiler->saveds = saveds;
- compiler->args = args;
- compiler->local_size = (local_size + sizeof(sljit_uw) - 1) & ~(sizeof(sljit_uw) - 1);
- compiler->temporaries_start = compiler->local_size;
- if (temporaries > 3)
- compiler->local_size += (temporaries - 3) * sizeof(sljit_uw);
- compiler->saveds_start = compiler->local_size;
- if (saveds > 3)
- compiler->local_size += (saveds - 3) * sizeof(sljit_uw);
+ check_sljit_emit_fast_enter(compiler, dst, dstw);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
CHECK_EXTRA_REGS(dst, dstw, (void)0);
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1);
- FAIL_IF(!buf);
+ /* For UNUSED dst. Uncommon, but possible. */
+ if (dst == SLJIT_UNUSED)
+ dst = TMP_REGISTER;
+
+ if (dst <= TMP_REGISTER) {
+ /* Unused dest is possible here. */
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1);
+ FAIL_IF(!inst);
INC_SIZE(1);
POP_REG(reg_map[dst]);
return SLJIT_SUCCESS;
}
- else if (dst & SLJIT_MEM) {
- buf = emit_x86_instruction(compiler, 1, 0, 0, dst, dstw);
- FAIL_IF(!buf);
- *buf++ = 0x8f;
- return SLJIT_SUCCESS;
- }
-
- /* For UNUSED dst. Uncommon, but possible. */
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1);
- FAIL_IF(!buf);
- INC_SIZE(1);
- POP_REG(reg_map[TMP_REGISTER]);
+ /* Memory. */
+ inst = emit_x86_instruction(compiler, 1, 0, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst++ = POP_rm;
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compiler, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_return(struct sljit_compiler *compiler, sljit_si src, sljit_sw srcw)
{
- sljit_ub *buf;
+ sljit_ub *inst;
CHECK_ERROR();
check_sljit_emit_fast_return(compiler, src, srcw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
CHECK_EXTRA_REGS(src, srcw, (void)0);
- if (src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_NO_REGISTERS) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1 + 1);
- FAIL_IF(!buf);
+ if (src <= TMP_REGISTER) {
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1 + 1);
+ FAIL_IF(!inst);
INC_SIZE(1 + 1);
PUSH_REG(reg_map[src]);
}
else if (src & SLJIT_MEM) {
- buf = emit_x86_instruction(compiler, 1, 0, 0, src, srcw);
- FAIL_IF(!buf);
- *buf++ = 0xff;
- *buf |= 6 << 3;
+ inst = emit_x86_instruction(compiler, 1, 0, 0, src, srcw);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_FF;
+ *inst |= PUSH_rm;
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1);
+ FAIL_IF(!inst);
INC_SIZE(1);
}
else {
/* SLJIT_IMM. */
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 5 + 1);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 5 + 1);
+ FAIL_IF(!inst);
INC_SIZE(5 + 1);
- *buf++ = 0x68;
- *(sljit_w*)buf = srcw;
- buf += sizeof(sljit_w);
+ *inst++ = PUSH_i32;
+ *(sljit_sw*)inst = srcw;
+ inst += sizeof(sljit_sw);
}
RET();
diff --git a/src/3rdparty/pcre/sljit/sljitNativeX86_64.c b/src/3rdparty/pcre/sljit/sljitNativeX86_64.c
index 40d875b841..28f04fddd8 100644
--- a/src/3rdparty/pcre/sljit/sljitNativeX86_64.c
+++ b/src/3rdparty/pcre/sljit/sljitNativeX86_64.c
@@ -26,118 +26,116 @@
/* x86 64-bit arch dependent functions. */
-static int emit_load_imm64(struct sljit_compiler *compiler, int reg, sljit_w imm)
+static sljit_si emit_load_imm64(struct sljit_compiler *compiler, sljit_si reg, sljit_sw imm)
{
- sljit_ub *buf;
-
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 2 + sizeof(sljit_w));
- FAIL_IF(!buf);
- INC_SIZE(2 + sizeof(sljit_w));
- *buf++ = REX_W | ((reg_map[reg] <= 7) ? 0 : REX_B);
- *buf++ = 0xb8 + (reg_map[reg] & 0x7);
- *(sljit_w*)buf = imm;
+ sljit_ub *inst;
+
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 2 + sizeof(sljit_sw));
+ FAIL_IF(!inst);
+ INC_SIZE(2 + sizeof(sljit_sw));
+ *inst++ = REX_W | ((reg_map[reg] <= 7) ? 0 : REX_B);
+ *inst++ = MOV_r_i32 + (reg_map[reg] & 0x7);
+ *(sljit_sw*)inst = imm;
return SLJIT_SUCCESS;
}
-static sljit_ub* generate_far_jump_code(struct sljit_jump *jump, sljit_ub *code_ptr, int type)
+static sljit_ub* generate_far_jump_code(struct sljit_jump *jump, sljit_ub *code_ptr, sljit_si type)
{
if (type < SLJIT_JUMP) {
+ /* Invert type. */
*code_ptr++ = get_jump_code(type ^ 0x1) - 0x10;
*code_ptr++ = 10 + 3;
}
SLJIT_COMPILE_ASSERT(reg_map[TMP_REG3] == 9, tmp3_is_9_first);
*code_ptr++ = REX_W | REX_B;
- *code_ptr++ = 0xb8 + 1;
+ *code_ptr++ = MOV_r_i32 + 1;
jump->addr = (sljit_uw)code_ptr;
if (jump->flags & JUMP_LABEL)
jump->flags |= PATCH_MD;
else
- *(sljit_w*)code_ptr = jump->u.target;
+ *(sljit_sw*)code_ptr = jump->u.target;
- code_ptr += sizeof(sljit_w);
+ code_ptr += sizeof(sljit_sw);
*code_ptr++ = REX_B;
- *code_ptr++ = 0xff;
- *code_ptr++ = (type >= SLJIT_FAST_CALL) ? 0xd1 /* call */ : 0xe1 /* jmp */;
+ *code_ptr++ = GROUP_FF;
+ *code_ptr++ = (type >= SLJIT_FAST_CALL) ? (MOD_REG | CALL_rm | 1) : (MOD_REG | JMP_rm | 1);
return code_ptr;
}
-static sljit_ub* generate_fixed_jump(sljit_ub *code_ptr, sljit_w addr, int type)
+static sljit_ub* generate_fixed_jump(sljit_ub *code_ptr, sljit_sw addr, sljit_si type)
{
- sljit_w delta = addr - ((sljit_w)code_ptr + 1 + sizeof(sljit_hw));
+ sljit_sw delta = addr - ((sljit_sw)code_ptr + 1 + sizeof(sljit_si));
if (delta <= SLJIT_W(0x7fffffff) && delta >= SLJIT_W(-0x80000000)) {
- *code_ptr++ = (type == 2) ? 0xe8 /* call */ : 0xe9 /* jmp */;
- *(sljit_w*)code_ptr = delta;
+ *code_ptr++ = (type == 2) ? CALL_i32 : JMP_i32;
+ *(sljit_sw*)code_ptr = delta;
}
else {
SLJIT_COMPILE_ASSERT(reg_map[TMP_REG3] == 9, tmp3_is_9_second);
*code_ptr++ = REX_W | REX_B;
- *code_ptr++ = 0xb8 + 1;
- *(sljit_w*)code_ptr = addr;
- code_ptr += sizeof(sljit_w);
+ *code_ptr++ = MOV_r_i32 + 1;
+ *(sljit_sw*)code_ptr = addr;
+ code_ptr += sizeof(sljit_sw);
*code_ptr++ = REX_B;
- *code_ptr++ = 0xff;
- *code_ptr++ = (type == 2) ? 0xd1 /* call */ : 0xe1 /* jmp */;
+ *code_ptr++ = GROUP_FF;
+ *code_ptr++ = (type == 2) ? (MOD_REG | CALL_rm | 1) : (MOD_REG | JMP_rm | 1);
}
return code_ptr;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_enter(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
- int size, pushed_size;
- sljit_ub *buf;
+ sljit_si size, pushed_size;
+ sljit_ub *inst;
CHECK_ERROR();
- check_sljit_emit_enter(compiler, args, temporaries, saveds, local_size);
+ check_sljit_emit_enter(compiler, args, scratches, saveds, local_size);
- compiler->temporaries = temporaries;
+ compiler->scratches = scratches;
compiler->saveds = saveds;
compiler->flags_saved = 0;
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
+#endif
size = saveds;
/* Including the return address saved by the call instruction. */
- pushed_size = (saveds + 1) * sizeof(sljit_w);
+ pushed_size = (saveds + 1) * sizeof(sljit_sw);
#ifndef _WIN64
if (saveds >= 2)
size += saveds - 1;
#else
- /* Saving the virtual stack pointer. */
- compiler->has_locals = local_size > 0;
- if (local_size > 0) {
- size += 2;
- pushed_size += sizeof(sljit_w);
- }
if (saveds >= 4)
size += saveds - 3;
- if (temporaries >= 5) {
+ if (scratches >= 5) {
size += (5 - 4) * 2;
- pushed_size += sizeof(sljit_w);
+ pushed_size += sizeof(sljit_sw);
}
#endif
size += args * 3;
if (size > 0) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + size);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + size);
+ FAIL_IF(!inst);
INC_SIZE(size);
if (saveds >= 5) {
SLJIT_COMPILE_ASSERT(reg_map[SLJIT_SAVED_EREG2] >= 8, saved_ereg2_is_hireg);
- *buf++ = REX_B;
+ *inst++ = REX_B;
PUSH_REG(reg_lmap[SLJIT_SAVED_EREG2]);
}
if (saveds >= 4) {
SLJIT_COMPILE_ASSERT(reg_map[SLJIT_SAVED_EREG1] >= 8, saved_ereg1_is_hireg);
- *buf++ = REX_B;
+ *inst++ = REX_B;
PUSH_REG(reg_lmap[SLJIT_SAVED_EREG1]);
}
if (saveds >= 3) {
#ifndef _WIN64
SLJIT_COMPILE_ASSERT(reg_map[SLJIT_SAVED_REG3] >= 8, saved_reg3_is_hireg);
- *buf++ = REX_B;
+ *inst++ = REX_B;
#else
SLJIT_COMPILE_ASSERT(reg_map[SLJIT_SAVED_REG3] < 8, saved_reg3_is_loreg);
#endif
@@ -146,7 +144,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, i
if (saveds >= 2) {
#ifndef _WIN64
SLJIT_COMPILE_ASSERT(reg_map[SLJIT_SAVED_REG2] >= 8, saved_reg2_is_hireg);
- *buf++ = REX_B;
+ *inst++ = REX_B;
#else
SLJIT_COMPILE_ASSERT(reg_map[SLJIT_SAVED_REG2] < 8, saved_reg2_is_loreg);
#endif
@@ -157,149 +155,138 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_enter(struct sljit_compiler *compiler, i
PUSH_REG(reg_lmap[SLJIT_SAVED_REG1]);
}
#ifdef _WIN64
- if (temporaries >= 5) {
+ if (scratches >= 5) {
SLJIT_COMPILE_ASSERT(reg_map[SLJIT_TEMPORARY_EREG2] >= 8, temporary_ereg2_is_hireg);
- *buf++ = REX_B;
+ *inst++ = REX_B;
PUSH_REG(reg_lmap[SLJIT_TEMPORARY_EREG2]);
}
- if (local_size > 0) {
- SLJIT_COMPILE_ASSERT(reg_map[SLJIT_LOCALS_REG] >= 8, locals_reg_is_hireg);
- *buf++ = REX_B;
- PUSH_REG(reg_lmap[SLJIT_LOCALS_REG]);
- }
#endif
#ifndef _WIN64
if (args > 0) {
- *buf++ = REX_W;
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (reg_map[SLJIT_SAVED_REG1] << 3) | 0x7;
+ *inst++ = REX_W;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (reg_map[SLJIT_SAVED_REG1] << 3) | 0x7 /* rdi */;
}
if (args > 1) {
- *buf++ = REX_W | REX_R;
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (reg_lmap[SLJIT_SAVED_REG2] << 3) | 0x6;
+ *inst++ = REX_W | REX_R;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (reg_lmap[SLJIT_SAVED_REG2] << 3) | 0x6 /* rsi */;
}
if (args > 2) {
- *buf++ = REX_W | REX_R;
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (reg_lmap[SLJIT_SAVED_REG3] << 3) | 0x2;
+ *inst++ = REX_W | REX_R;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (reg_lmap[SLJIT_SAVED_REG3] << 3) | 0x2 /* rdx */;
}
#else
if (args > 0) {
- *buf++ = REX_W;
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (reg_map[SLJIT_SAVED_REG1] << 3) | 0x1;
+ *inst++ = REX_W;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (reg_map[SLJIT_SAVED_REG1] << 3) | 0x1 /* rcx */;
}
if (args > 1) {
- *buf++ = REX_W;
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (reg_map[SLJIT_SAVED_REG2] << 3) | 0x2;
+ *inst++ = REX_W;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (reg_map[SLJIT_SAVED_REG2] << 3) | 0x2 /* rdx */;
}
if (args > 2) {
- *buf++ = REX_W | REX_B;
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (reg_map[SLJIT_SAVED_REG3] << 3) | 0x0;
+ *inst++ = REX_W | REX_B;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (reg_map[SLJIT_SAVED_REG3] << 3) | 0x0 /* r8 */;
}
#endif
}
- local_size = ((local_size + pushed_size + 16 - 1) & ~(16 - 1)) - pushed_size;
-#ifdef _WIN64
- local_size += 4 * sizeof(sljit_w);
+ local_size = ((local_size + FIXED_LOCALS_OFFSET + pushed_size + 16 - 1) & ~(16 - 1)) - pushed_size;
compiler->local_size = local_size;
+#ifdef _WIN64
if (local_size > 1024) {
- /* Allocate the stack for the function itself. */
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 4);
- FAIL_IF(!buf);
- INC_SIZE(4);
- *buf++ = REX_W;
- *buf++ = 0x83;
- *buf++ = 0xc0 | (5 << 3) | 4;
+ /* Allocate stack for the callback, which grows the stack. */
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 4 + (3 + sizeof(sljit_si)));
+ FAIL_IF(!inst);
+ INC_SIZE(4 + (3 + sizeof(sljit_si)));
+ *inst++ = REX_W;
+ *inst++ = GROUP_BINARY_83;
+ *inst++ = MOD_REG | SUB | 4;
/* Pushed size must be divisible by 8. */
SLJIT_ASSERT(!(pushed_size & 0x7));
if (pushed_size & 0x8) {
- *buf++ = 5 * sizeof(sljit_w);
- local_size -= 5 * sizeof(sljit_w);
+ *inst++ = 5 * sizeof(sljit_sw);
+ local_size -= 5 * sizeof(sljit_sw);
} else {
- *buf++ = 4 * sizeof(sljit_w);
- local_size -= 4 * sizeof(sljit_w);
+ *inst++ = 4 * sizeof(sljit_sw);
+ local_size -= 4 * sizeof(sljit_sw);
}
- FAIL_IF(emit_load_imm64(compiler, SLJIT_TEMPORARY_REG1, local_size));
- FAIL_IF(sljit_emit_ijump(compiler, SLJIT_CALL1, SLJIT_IMM, SLJIT_FUNC_OFFSET(sljit_touch_stack)));
- }
-#else
- compiler->local_size = local_size;
- if (local_size > 0) {
+ /* Second instruction */
+ SLJIT_COMPILE_ASSERT(reg_map[SLJIT_SCRATCH_REG1] < 8, temporary_reg1_is_loreg);
+ *inst++ = REX_W;
+ *inst++ = MOV_rm_i32;
+ *inst++ = MOD_REG | reg_lmap[SLJIT_SCRATCH_REG1];
+ *(sljit_si*)inst = local_size;
+#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->skip_checks = 1;
#endif
- /* In case of Win64, local_size is always > 4 * sizeof(sljit_w) */
- if (local_size <= 127) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 4);
- FAIL_IF(!buf);
- INC_SIZE(4);
- *buf++ = REX_W;
- *buf++ = 0x83;
- *buf++ = 0xc0 | (5 << 3) | 4;
- *buf++ = local_size;
- }
- else {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 7);
- FAIL_IF(!buf);
- INC_SIZE(7);
- *buf++ = REX_W;
- *buf++ = 0x81;
- *buf++ = 0xc0 | (5 << 3) | 4;
- *(sljit_hw*)buf = local_size;
- buf += sizeof(sljit_hw);
- }
-#ifndef _WIN64
+ FAIL_IF(sljit_emit_ijump(compiler, SLJIT_CALL1, SLJIT_IMM, SLJIT_FUNC_OFFSET(sljit_grow_stack)));
}
#endif
-
-#ifdef _WIN64
- if (compiler->has_locals) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 5);
- FAIL_IF(!buf);
- INC_SIZE(5);
- *buf++ = REX_W | REX_R;
- *buf++ = 0x8d;
- *buf++ = 0x40 | (reg_lmap[SLJIT_LOCALS_REG] << 3) | 0x4;
- *buf++ = 0x24;
- *buf = 4 * sizeof(sljit_w);
+ SLJIT_ASSERT(local_size > 0);
+ if (local_size <= 127) {
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 4);
+ FAIL_IF(!inst);
+ INC_SIZE(4);
+ *inst++ = REX_W;
+ *inst++ = GROUP_BINARY_83;
+ *inst++ = MOD_REG | SUB | 4;
+ *inst++ = local_size;
+ }
+ else {
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 7);
+ FAIL_IF(!inst);
+ INC_SIZE(7);
+ *inst++ = REX_W;
+ *inst++ = GROUP_BINARY_81;
+ *inst++ = MOD_REG | SUB | 4;
+ *(sljit_si*)inst = local_size;
+ inst += sizeof(sljit_si);
}
+#ifdef _WIN64
+ /* Save xmm6 with MOVAPS instruction. */
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 5);
+ FAIL_IF(!inst);
+ INC_SIZE(5);
+ *inst++ = GROUP_0F;
+ *(sljit_si*)inst = 0x20247429;
#endif
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_context(struct sljit_compiler *compiler, sljit_si args, sljit_si scratches, sljit_si saveds, sljit_si local_size)
{
- int pushed_size;
+ sljit_si pushed_size;
CHECK_ERROR_VOID();
- check_sljit_set_context(compiler, args, temporaries, saveds, local_size);
+ check_sljit_set_context(compiler, args, scratches, saveds, local_size);
- compiler->temporaries = temporaries;
+ compiler->scratches = scratches;
compiler->saveds = saveds;
- /* Including the return address saved by the call instruction. */
- pushed_size = (saveds + 1) * sizeof(sljit_w);
-#ifdef _WIN64
- compiler->has_locals = local_size > 0;
- if (local_size > 0)
- pushed_size += sizeof(sljit_w);
- if (temporaries >= 5)
- pushed_size += sizeof(sljit_w);
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->logical_local_size = local_size;
#endif
- compiler->local_size = ((local_size + pushed_size + 16 - 1) & ~(16 - 1)) - pushed_size;
+
+ /* Including the return address saved by the call instruction. */
+ pushed_size = (saveds + 1) * sizeof(sljit_sw);
#ifdef _WIN64
- compiler->local_size += 4 * sizeof(sljit_w);
+ if (scratches >= 5)
+ pushed_size += sizeof(sljit_sw);
#endif
+ compiler->local_size = ((local_size + FIXED_LOCALS_OFFSET + pushed_size + 16 - 1) & ~(16 - 1)) - pushed_size;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler, int op, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_return(struct sljit_compiler *compiler, sljit_si op, sljit_si src, sljit_sw srcw)
{
- int size;
- sljit_ub *buf;
+ sljit_si size;
+ sljit_ub *inst;
CHECK_ERROR();
check_sljit_emit_return(compiler, op, src, srcw);
@@ -307,25 +294,32 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
compiler->flags_saved = 0;
FAIL_IF(emit_mov_before_return(compiler, op, src, srcw));
- if (compiler->local_size > 0) {
- if (compiler->local_size <= 127) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 4);
- FAIL_IF(!buf);
- INC_SIZE(4);
- *buf++ = REX_W;
- *buf++ = 0x83;
- *buf++ = 0xc0 | (0 << 3) | 4;
- *buf = compiler->local_size;
- }
- else {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 7);
- FAIL_IF(!buf);
- INC_SIZE(7);
- *buf++ = REX_W;
- *buf++ = 0x81;
- *buf++ = 0xc0 | (0 << 3) | 4;
- *(sljit_hw*)buf = compiler->local_size;
- }
+#ifdef _WIN64
+ /* Restore xmm6 with MOVAPS instruction. */
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 5);
+ FAIL_IF(!inst);
+ INC_SIZE(5);
+ *inst++ = GROUP_0F;
+ *(sljit_si*)inst = 0x20247428;
+#endif
+ SLJIT_ASSERT(compiler->local_size > 0);
+ if (compiler->local_size <= 127) {
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 4);
+ FAIL_IF(!inst);
+ INC_SIZE(4);
+ *inst++ = REX_W;
+ *inst++ = GROUP_BINARY_83;
+ *inst++ = MOD_REG | ADD | 4;
+ *inst = compiler->local_size;
+ }
+ else {
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 7);
+ FAIL_IF(!inst);
+ INC_SIZE(7);
+ *inst++ = REX_W;
+ *inst++ = GROUP_BINARY_81;
+ *inst++ = MOD_REG | ADD | 4;
+ *(sljit_si*)inst = compiler->local_size;
}
size = 1 + compiler->saveds;
@@ -333,25 +327,19 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
if (compiler->saveds >= 2)
size += compiler->saveds - 1;
#else
- if (compiler->has_locals)
- size += 2;
if (compiler->saveds >= 4)
size += compiler->saveds - 3;
- if (compiler->temporaries >= 5)
+ if (compiler->scratches >= 5)
size += (5 - 4) * 2;
#endif
- buf = (sljit_ub*)ensure_buf(compiler, 1 + size);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + size);
+ FAIL_IF(!inst);
INC_SIZE(size);
#ifdef _WIN64
- if (compiler->has_locals) {
- *buf++ = REX_B;
- POP_REG(reg_lmap[SLJIT_LOCALS_REG]);
- }
- if (compiler->temporaries >= 5) {
- *buf++ = REX_B;
+ if (compiler->scratches >= 5) {
+ *inst++ = REX_B;
POP_REG(reg_lmap[SLJIT_TEMPORARY_EREG2]);
}
#endif
@@ -359,22 +347,22 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
POP_REG(reg_map[SLJIT_SAVED_REG1]);
if (compiler->saveds >= 2) {
#ifndef _WIN64
- *buf++ = REX_B;
+ *inst++ = REX_B;
#endif
POP_REG(reg_lmap[SLJIT_SAVED_REG2]);
}
if (compiler->saveds >= 3) {
#ifndef _WIN64
- *buf++ = REX_B;
+ *inst++ = REX_B;
#endif
POP_REG(reg_lmap[SLJIT_SAVED_REG3]);
}
if (compiler->saveds >= 4) {
- *buf++ = REX_B;
+ *inst++ = REX_B;
POP_REG(reg_lmap[SLJIT_SAVED_EREG1]);
}
if (compiler->saveds >= 5) {
- *buf++ = REX_B;
+ *inst++ = REX_B;
POP_REG(reg_lmap[SLJIT_SAVED_EREG2]);
}
@@ -386,39 +374,32 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_return(struct sljit_compiler *compiler,
/* Operators */
/* --------------------------------------------------------------------- */
-static int emit_do_imm32(struct sljit_compiler *compiler, sljit_ub rex, sljit_ub opcode, sljit_w imm)
+static sljit_si emit_do_imm32(struct sljit_compiler *compiler, sljit_ub rex, sljit_ub opcode, sljit_sw imm)
{
- sljit_ub *buf;
+ sljit_ub *inst;
+ sljit_si length = 1 + (rex ? 1 : 0) + sizeof(sljit_si);
- if (rex != 0) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 2 + sizeof(sljit_hw));
- FAIL_IF(!buf);
- INC_SIZE(2 + sizeof(sljit_hw));
- *buf++ = rex;
- *buf++ = opcode;
- *(sljit_hw*)buf = imm;
- }
- else {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1 + sizeof(sljit_hw));
- FAIL_IF(!buf);
- INC_SIZE(1 + sizeof(sljit_hw));
- *buf++ = opcode;
- *(sljit_hw*)buf = imm;
- }
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + length);
+ FAIL_IF(!inst);
+ INC_SIZE(length);
+ if (rex)
+ *inst++ = rex;
+ *inst++ = opcode;
+ *(sljit_si*)inst = imm;
return SLJIT_SUCCESS;
}
-static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
+static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, sljit_si size,
/* The register or immediate operand. */
- int a, sljit_w imma,
+ sljit_si a, sljit_sw imma,
/* The general operand (not immediate). */
- int b, sljit_w immb)
+ sljit_si b, sljit_sw immb)
{
- sljit_ub *buf;
+ sljit_ub *inst;
sljit_ub *buf_ptr;
sljit_ub rex = 0;
- int flags = size & ~0xf;
- int inst_size;
+ sljit_si flags = size & ~0xf;
+ sljit_si inst_size;
/* The immediate operand must be 32 bit. */
SLJIT_ASSERT(!(a & SLJIT_IMM) || compiler->mode32 || IS_HALFWORD(imma));
@@ -431,6 +412,9 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
#if (defined SLJIT_SSE2 && SLJIT_SSE2)
/* SSE2 and immediate is not possible. */
SLJIT_ASSERT(!(a & SLJIT_IMM) || !(flags & EX86_SSE2));
+ SLJIT_ASSERT((flags & (EX86_PREF_F2 | EX86_PREF_F3)) != (EX86_PREF_F2 | EX86_PREF_F3)
+ && (flags & (EX86_PREF_F2 | EX86_PREF_66)) != (EX86_PREF_F2 | EX86_PREF_66)
+ && (flags & (EX86_PREF_F3 | EX86_PREF_66)) != (EX86_PREF_F3 | EX86_PREF_66));
#endif
size &= 0xf;
@@ -452,7 +436,7 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
rex |= REX;
#if (defined SLJIT_SSE2 && SLJIT_SSE2)
- if (flags & EX86_PREF_F2)
+ if (flags & (EX86_PREF_F2 | EX86_PREF_F3))
inst_size++;
#endif
if (flags & EX86_PREF_66)
@@ -462,23 +446,21 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
inst_size += 1; /* mod r/m byte. */
if (b & SLJIT_MEM) {
if ((b & 0x0f) == SLJIT_UNUSED)
- inst_size += 1 + sizeof(sljit_hw); /* SIB byte required to avoid RIP based addressing. */
+ inst_size += 1 + sizeof(sljit_si); /* SIB byte required to avoid RIP based addressing. */
else {
if (reg_map[b & 0x0f] >= 8)
rex |= REX_B;
if (immb != 0 && !(b & 0xf0)) {
/* Immediate operand. */
if (immb <= 127 && immb >= -128)
- inst_size += sizeof(sljit_b);
+ inst_size += sizeof(sljit_sb);
else
- inst_size += sizeof(sljit_hw);
+ inst_size += sizeof(sljit_si);
}
}
-#ifndef _WIN64
- if ((b & 0xf) == SLJIT_LOCALS_REG && (b & 0xf0) == 0)
+ if ((b & 0xf) == SLJIT_LOCALS_REG && !(b & 0xf0))
b |= SLJIT_LOCALS_REG << 4;
-#endif
if ((b & 0xf0) != SLJIT_UNUSED) {
inst_size += 1; /* SIB byte. */
@@ -513,7 +495,7 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
else if (flags & EX86_HALF_ARG)
inst_size += sizeof(short);
else
- inst_size += sizeof(sljit_hw);
+ inst_size += sizeof(sljit_si);
}
else {
SLJIT_ASSERT(!(flags & EX86_SHIFT_INS) || a == SLJIT_PREF_SHIFT_REG);
@@ -530,25 +512,27 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
if (rex)
inst_size++;
- buf = (sljit_ub*)ensure_buf(compiler, 1 + inst_size);
- PTR_FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + inst_size);
+ PTR_FAIL_IF(!inst);
/* Encoding the byte. */
INC_SIZE(inst_size);
#if (defined SLJIT_SSE2 && SLJIT_SSE2)
if (flags & EX86_PREF_F2)
- *buf++ = 0xf2;
+ *inst++ = 0xf2;
+ if (flags & EX86_PREF_F3)
+ *inst++ = 0xf3;
#endif
if (flags & EX86_PREF_66)
- *buf++ = 0x66;
+ *inst++ = 0x66;
if (rex)
- *buf++ = rex;
- buf_ptr = buf + size;
+ *inst++ = rex;
+ buf_ptr = inst + size;
/* Encode mod/rm byte. */
if (!(flags & EX86_SHIFT_INS)) {
if ((flags & EX86_BIN_INS) && (a & SLJIT_IMM))
- *buf = (flags & EX86_BYTE_ARG) ? 0x83 : 0x81;
+ *inst = (flags & EX86_BYTE_ARG) ? GROUP_BINARY_83 : GROUP_BINARY_81;
if ((a & SLJIT_IMM) || (a == 0))
*buf_ptr = 0;
@@ -565,24 +549,21 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
else {
if (a & SLJIT_IMM) {
if (imma == 1)
- *buf = 0xd1;
+ *inst = GROUP_SHIFT_1;
else
- *buf = 0xc1;
+ *inst = GROUP_SHIFT_N;
} else
- *buf = 0xd3;
+ *inst = GROUP_SHIFT_CL;
*buf_ptr = 0;
}
if (!(b & SLJIT_MEM))
#if (defined SLJIT_SSE2 && SLJIT_SSE2)
- *buf_ptr++ |= 0xc0 + ((!(flags & EX86_SSE2)) ? reg_lmap[b] : b);
+ *buf_ptr++ |= MOD_REG + ((!(flags & EX86_SSE2)) ? reg_lmap[b] : b);
#else
- *buf_ptr++ |= 0xc0 + reg_lmap[b];
+ *buf_ptr++ |= MOD_REG + reg_lmap[b];
#endif
else if ((b & 0x0f) != SLJIT_UNUSED) {
-#ifdef _WIN64
- SLJIT_ASSERT((b & 0xf0) != (SLJIT_LOCALS_REG << 4));
-#endif
if ((b & 0xf0) == SLJIT_UNUSED || (b & 0xf0) == (SLJIT_LOCALS_REG << 4)) {
if (immb != 0) {
if (immb <= 127 && immb >= -128)
@@ -602,8 +583,8 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
if (immb <= 127 && immb >= -128)
*buf_ptr++ = immb; /* 8 bit displacement. */
else {
- *(sljit_hw*)buf_ptr = immb; /* 32 bit displacement. */
- buf_ptr += sizeof(sljit_hw);
+ *(sljit_si*)buf_ptr = immb; /* 32 bit displacement. */
+ buf_ptr += sizeof(sljit_si);
}
}
}
@@ -615,8 +596,8 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
else {
*buf_ptr++ |= 0x04;
*buf_ptr++ = 0x25;
- *(sljit_hw*)buf_ptr = immb; /* 32 bit displacement. */
- buf_ptr += sizeof(sljit_hw);
+ *(sljit_si*)buf_ptr = immb; /* 32 bit displacement. */
+ buf_ptr += sizeof(sljit_si);
}
if (a & SLJIT_IMM) {
@@ -625,154 +606,141 @@ static sljit_ub* emit_x86_instruction(struct sljit_compiler *compiler, int size,
else if (flags & EX86_HALF_ARG)
*(short*)buf_ptr = imma;
else if (!(flags & EX86_SHIFT_INS))
- *(sljit_hw*)buf_ptr = imma;
+ *(sljit_si*)buf_ptr = imma;
}
- return !(flags & EX86_SHIFT_INS) ? buf : (buf + 1);
+ return !(flags & EX86_SHIFT_INS) ? inst : (inst + 1);
}
/* --------------------------------------------------------------------- */
/* Call / return instructions */
/* --------------------------------------------------------------------- */
-static SLJIT_INLINE int call_with_args(struct sljit_compiler *compiler, int type)
+static SLJIT_INLINE sljit_si call_with_args(struct sljit_compiler *compiler, sljit_si type)
{
- sljit_ub *buf;
+ sljit_ub *inst;
#ifndef _WIN64
- SLJIT_COMPILE_ASSERT(reg_map[SLJIT_TEMPORARY_REG2] == 6 && reg_map[SLJIT_TEMPORARY_REG1] < 8 && reg_map[SLJIT_TEMPORARY_REG3] < 8, args_registers);
+ SLJIT_COMPILE_ASSERT(reg_map[SLJIT_SCRATCH_REG2] == 6 && reg_map[SLJIT_SCRATCH_REG1] < 8 && reg_map[SLJIT_SCRATCH_REG3] < 8, args_registers);
- buf = (sljit_ub*)ensure_buf(compiler, 1 + ((type < SLJIT_CALL3) ? 3 : 6));
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + ((type < SLJIT_CALL3) ? 3 : 6));
+ FAIL_IF(!inst);
INC_SIZE((type < SLJIT_CALL3) ? 3 : 6);
if (type >= SLJIT_CALL3) {
- *buf++ = REX_W;
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (0x2 << 3) | reg_lmap[SLJIT_TEMPORARY_REG3];
+ *inst++ = REX_W;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (0x2 /* rdx */ << 3) | reg_lmap[SLJIT_SCRATCH_REG3];
}
- *buf++ = REX_W;
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (0x7 << 3) | reg_lmap[SLJIT_TEMPORARY_REG1];
+ *inst++ = REX_W;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (0x7 /* rdi */ << 3) | reg_lmap[SLJIT_SCRATCH_REG1];
#else
- SLJIT_COMPILE_ASSERT(reg_map[SLJIT_TEMPORARY_REG2] == 2 && reg_map[SLJIT_TEMPORARY_REG1] < 8 && reg_map[SLJIT_TEMPORARY_REG3] < 8, args_registers);
+ SLJIT_COMPILE_ASSERT(reg_map[SLJIT_SCRATCH_REG2] == 2 && reg_map[SLJIT_SCRATCH_REG1] < 8 && reg_map[SLJIT_SCRATCH_REG3] < 8, args_registers);
- buf = (sljit_ub*)ensure_buf(compiler, 1 + ((type < SLJIT_CALL3) ? 3 : 6));
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + ((type < SLJIT_CALL3) ? 3 : 6));
+ FAIL_IF(!inst);
INC_SIZE((type < SLJIT_CALL3) ? 3 : 6);
if (type >= SLJIT_CALL3) {
- *buf++ = REX_W | REX_R;
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (0x0 << 3) | reg_lmap[SLJIT_TEMPORARY_REG3];
+ *inst++ = REX_W | REX_R;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (0x0 /* r8 */ << 3) | reg_lmap[SLJIT_SCRATCH_REG3];
}
- *buf++ = REX_W;
- *buf++ = 0x8b;
- *buf++ = 0xc0 | (0x1 << 3) | reg_lmap[SLJIT_TEMPORARY_REG1];
+ *inst++ = REX_W;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (0x1 /* rcx */ << 3) | reg_lmap[SLJIT_SCRATCH_REG1];
#endif
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_enter(struct sljit_compiler *compiler, int dst, sljit_w dstw, int args, int temporaries, int saveds, int local_size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_enter(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw)
{
- sljit_ub *buf;
+ sljit_ub *inst;
CHECK_ERROR();
- check_sljit_emit_fast_enter(compiler, dst, dstw, args, temporaries, saveds, local_size);
-
- compiler->temporaries = temporaries;
- compiler->saveds = saveds;
- compiler->local_size = (local_size + sizeof(sljit_uw) - 1) & ~(sizeof(sljit_uw) - 1);
-#ifdef _WIN64
- compiler->local_size += 4 * sizeof(sljit_w);
-#endif
+ check_sljit_emit_fast_enter(compiler, dst, dstw);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
/* For UNUSED dst. Uncommon, but possible. */
if (dst == SLJIT_UNUSED)
dst = TMP_REGISTER;
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= TMP_REGISTER) {
+ if (dst <= TMP_REGISTER) {
if (reg_map[dst] < 8) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1);
- FAIL_IF(!buf);
-
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1);
+ FAIL_IF(!inst);
INC_SIZE(1);
POP_REG(reg_lmap[dst]);
+ return SLJIT_SUCCESS;
}
- else {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 2);
- FAIL_IF(!buf);
- INC_SIZE(2);
- *buf++ = REX_B;
- POP_REG(reg_lmap[dst]);
- }
- }
- else if (dst & SLJIT_MEM) {
-#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- /* REX_W is not necessary (src is not immediate). */
- compiler->mode32 = 1;
-#endif
- buf = emit_x86_instruction(compiler, 1, 0, 0, dst, dstw);
- FAIL_IF(!buf);
- *buf++ = 0x8f;
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 2);
+ FAIL_IF(!inst);
+ INC_SIZE(2);
+ *inst++ = REX_B;
+ POP_REG(reg_lmap[dst]);
+ return SLJIT_SUCCESS;
}
+
+ /* REX_W is not necessary (src is not immediate). */
+ compiler->mode32 = 1;
+ inst = emit_x86_instruction(compiler, 1, 0, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst++ = POP_rm;
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compiler, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fast_return(struct sljit_compiler *compiler, sljit_si src, sljit_sw srcw)
{
- sljit_ub *buf;
+ sljit_ub *inst;
CHECK_ERROR();
check_sljit_emit_fast_return(compiler, src, srcw);
-
- CHECK_EXTRA_REGS(src, srcw, (void)0);
+ ADJUST_LOCAL_OFFSET(src, srcw);
if ((src & SLJIT_IMM) && NOT_HALFWORD(srcw)) {
FAIL_IF(emit_load_imm64(compiler, TMP_REGISTER, srcw));
src = TMP_REGISTER;
}
- if (src >= SLJIT_TEMPORARY_REG1 && src <= TMP_REGISTER) {
+ if (src <= TMP_REGISTER) {
if (reg_map[src] < 8) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1 + 1);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1 + 1);
+ FAIL_IF(!inst);
INC_SIZE(1 + 1);
PUSH_REG(reg_lmap[src]);
}
else {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 2 + 1);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 2 + 1);
+ FAIL_IF(!inst);
INC_SIZE(2 + 1);
- *buf++ = REX_B;
+ *inst++ = REX_B;
PUSH_REG(reg_lmap[src]);
}
}
else if (src & SLJIT_MEM) {
-#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
/* REX_W is not necessary (src is not immediate). */
compiler->mode32 = 1;
-#endif
- buf = emit_x86_instruction(compiler, 1, 0, 0, src, srcw);
- FAIL_IF(!buf);
- *buf++ = 0xff;
- *buf |= 6 << 3;
+ inst = emit_x86_instruction(compiler, 1, 0, 0, src, srcw);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_FF;
+ *inst |= PUSH_rm;
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1);
+ FAIL_IF(!inst);
INC_SIZE(1);
}
else {
SLJIT_ASSERT(IS_HALFWORD(srcw));
/* SLJIT_IMM. */
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 5 + 1);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 5 + 1);
+ FAIL_IF(!inst);
INC_SIZE(5 + 1);
- *buf++ = 0x68;
- *(sljit_hw*)buf = srcw;
- buf += sizeof(sljit_hw);
+ *inst++ = PUSH_i32;
+ *(sljit_si*)inst = srcw;
+ inst += sizeof(sljit_si);
}
RET();
@@ -784,12 +752,12 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fast_return(struct sljit_compiler *compi
/* Extend input */
/* --------------------------------------------------------------------- */
-static int emit_mov_int(struct sljit_compiler *compiler, int sign,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+static sljit_si emit_mov_int(struct sljit_compiler *compiler, sljit_si sign,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- sljit_ub* code;
- int dst_r;
+ sljit_ub* inst;
+ sljit_si dst_r;
compiler->mode32 = 0;
@@ -797,32 +765,32 @@ static int emit_mov_int(struct sljit_compiler *compiler, int sign,
return SLJIT_SUCCESS; /* Empty instruction. */
if (src & SLJIT_IMM) {
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) {
+ if (dst <= TMP_REGISTER) {
if (sign || ((sljit_uw)srcw <= 0x7fffffff)) {
- code = emit_x86_instruction(compiler, 1, SLJIT_IMM, (sljit_w)(sljit_i)srcw, dst, dstw);
- FAIL_IF(!code);
- *code = 0xc7;
+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, (sljit_sw)(sljit_si)srcw, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm_i32;
return SLJIT_SUCCESS;
}
return emit_load_imm64(compiler, dst, srcw);
}
compiler->mode32 = 1;
- code = emit_x86_instruction(compiler, 1, SLJIT_IMM, (sljit_w)(sljit_i)srcw, dst, dstw);
- FAIL_IF(!code);
- *code = 0xc7;
+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, (sljit_sw)(sljit_si)srcw, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm_i32;
compiler->mode32 = 0;
return SLJIT_SUCCESS;
}
- dst_r = (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_SAVED_REG3) ? dst : TMP_REGISTER;
+ dst_r = (dst <= TMP_REGISTER) ? dst : TMP_REGISTER;
- if ((dst & SLJIT_MEM) && (src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_SAVED_REG3))
+ if ((dst & SLJIT_MEM) && (src <= TMP_REGISTER))
dst_r = src;
else {
if (sign) {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, src, srcw);
- FAIL_IF(!code);
- *code++ = 0x63;
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, src, srcw);
+ FAIL_IF(!inst);
+ *inst++ = MOVSXD_r_rm;
} else {
compiler->mode32 = 1;
FAIL_IF(emit_mov(compiler, dst_r, 0, src, srcw));
@@ -832,9 +800,9 @@ static int emit_mov_int(struct sljit_compiler *compiler, int sign,
if (dst & SLJIT_MEM) {
compiler->mode32 = 1;
- code = emit_x86_instruction(compiler, 1, dst_r, 0, dst, dstw);
- FAIL_IF(!code);
- *code = 0x89;
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm_r;
compiler->mode32 = 0;
}
diff --git a/src/3rdparty/pcre/sljit/sljitNativeX86_common.c b/src/3rdparty/pcre/sljit/sljitNativeX86_common.c
index 0a44163802..ab98a03d2c 100644
--- a/src/3rdparty/pcre/sljit/sljitNativeX86_common.c
+++ b/src/3rdparty/pcre/sljit/sljitNativeX86_common.c
@@ -24,7 +24,7 @@
* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name()
+SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name(void)
{
return "x86" SLJIT_CPUINFO;
}
@@ -67,17 +67,17 @@ SLJIT_API_FUNC_ATTRIBUTE SLJIT_CONST char* sljit_get_platform_name()
#define TMP_REGISTER (SLJIT_NO_REGISTERS + 1)
static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 2] = {
- 0, 0, 2, 1, 0, 0, 3, 6, 7, 0, 0, 4, 5
+ 0, 0, 2, 1, 0, 0, 3, 6, 7, 0, 0, 4, 5
};
#define CHECK_EXTRA_REGS(p, w, do) \
if (p >= SLJIT_TEMPORARY_EREG1 && p <= SLJIT_TEMPORARY_EREG2) { \
- w = compiler->temporaries_start + (p - SLJIT_TEMPORARY_EREG1) * sizeof(sljit_w); \
+ w = compiler->scratches_start + (p - SLJIT_TEMPORARY_EREG1) * sizeof(sljit_sw); \
p = SLJIT_MEM1(SLJIT_LOCALS_REG); \
do; \
} \
else if (p >= SLJIT_SAVED_EREG1 && p <= SLJIT_SAVED_EREG2) { \
- w = compiler->saveds_start + (p - SLJIT_SAVED_EREG1) * sizeof(sljit_w); \
+ w = compiler->saveds_start + (p - SLJIT_SAVED_EREG1) * sizeof(sljit_sw); \
p = SLJIT_MEM1(SLJIT_LOCALS_REG); \
do; \
}
@@ -95,20 +95,20 @@ static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 2] = {
#ifndef _WIN64
/* 1st passed in rdi, 2nd argument passed in rsi, 3rd in rdx. */
static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 4] = {
- 0, 0, 6, 1, 8, 11, 3, 15, 14, 13, 12, 4, 2, 7, 9
+ 0, 0, 6, 1, 8, 11, 3, 15, 14, 13, 12, 4, 2, 7, 9
};
/* low-map. reg_map & 0x7. */
static SLJIT_CONST sljit_ub reg_lmap[SLJIT_NO_REGISTERS + 4] = {
- 0, 0, 6, 1, 0, 3, 3, 7, 6, 5, 4, 4, 2, 7, 1
+ 0, 0, 6, 1, 0, 3, 3, 7, 6, 5, 4, 4, 2, 7, 1
};
#else
/* 1st passed in rcx, 2nd argument passed in rdx, 3rd in r8. */
static SLJIT_CONST sljit_ub reg_map[SLJIT_NO_REGISTERS + 4] = {
- 0, 0, 2, 1, 11, 13, 3, 6, 7, 14, 12, 15, 10, 8, 9
+ 0, 0, 2, 1, 11, 13, 3, 6, 7, 14, 15, 4, 10, 8, 9
};
/* low-map. reg_map & 0x7. */
static SLJIT_CONST sljit_ub reg_lmap[SLJIT_NO_REGISTERS + 4] = {
- 0, 0, 2, 1, 3, 5, 3, 6, 7, 6, 4, 7, 2, 0, 1
+ 0, 0, 2, 1, 3, 5, 3, 6, 7, 6, 7, 4, 2, 0, 1
};
#endif
@@ -118,9 +118,6 @@ static SLJIT_CONST sljit_ub reg_lmap[SLJIT_NO_REGISTERS + 4] = {
#define REX_B 0x41
#define REX 0x40
-typedef unsigned int sljit_uhw;
-typedef int sljit_hw;
-
#define IS_HALFWORD(x) ((x) <= 0x7fffffffll && (x) >= -0x80000000ll)
#define NOT_HALFWORD(x) ((x) > 0x7fffffffll || (x) < -0x80000000ll)
@@ -129,7 +126,7 @@ typedef int sljit_hw;
#endif /* SLJIT_CONFIG_X86_32 */
#if (defined SLJIT_SSE2 && SLJIT_SSE2)
-#define TMP_FREG (SLJIT_FLOAT_REG4 + 1)
+#define TMP_FREG (0)
#endif
/* Size flags for emit_x86_instruction: */
@@ -142,108 +139,298 @@ typedef int sljit_hw;
#define EX86_PREF_66 0x0400
#if (defined SLJIT_SSE2 && SLJIT_SSE2)
-#define EX86_PREF_F2 0x0800
-#define EX86_SSE2 0x1000
+#define EX86_SSE2 0x0800
+#define EX86_PREF_F2 0x1000
+#define EX86_PREF_F3 0x2000
#endif
-#define INC_SIZE(s) (*buf++ = (s), compiler->size += (s))
-#define INC_CSIZE(s) (*code++ = (s), compiler->size += (s))
+/* --------------------------------------------------------------------- */
+/* Instrucion forms */
+/* --------------------------------------------------------------------- */
-#define PUSH_REG(r) (*buf++ = (0x50 + (r)))
-#define POP_REG(r) (*buf++ = (0x58 + (r)))
-#define RET() (*buf++ = (0xc3))
-#define RETN(n) (*buf++ = (0xc2), *buf++ = n, *buf++ = 0)
+#define ADD (/* BINARY */ 0 << 3)
+#define ADD_EAX_i32 0x05
+#define ADD_r_rm 0x03
+#define ADD_rm_r 0x01
+#define ADDSD_x_xm 0x58
+#define ADC (/* BINARY */ 2 << 3)
+#define ADC_EAX_i32 0x15
+#define ADC_r_rm 0x13
+#define ADC_rm_r 0x11
+#define AND (/* BINARY */ 4 << 3)
+#define AND_EAX_i32 0x25
+#define AND_r_rm 0x23
+#define AND_rm_r 0x21
+#define ANDPD_x_xm 0x54
+#define BSR_r_rm (/* GROUP_0F */ 0xbd)
+#define CALL_i32 0xe8
+#define CALL_rm (/* GROUP_FF */ 2 << 3)
+#define CDQ 0x99
+#define CMOVNE_r_rm (/* GROUP_0F */ 0x45)
+#define CMP (/* BINARY */ 7 << 3)
+#define CMP_EAX_i32 0x3d
+#define CMP_r_rm 0x3b
+#define CMP_rm_r 0x39
+#define DIV (/* GROUP_F7 */ 6 << 3)
+#define DIVSD_x_xm 0x5e
+#define INT3 0xcc
+#define IDIV (/* GROUP_F7 */ 7 << 3)
+#define IMUL (/* GROUP_F7 */ 5 << 3)
+#define IMUL_r_rm (/* GROUP_0F */ 0xaf)
+#define IMUL_r_rm_i8 0x6b
+#define IMUL_r_rm_i32 0x69
+#define JE_i8 0x74
+#define JMP_i8 0xeb
+#define JMP_i32 0xe9
+#define JMP_rm (/* GROUP_FF */ 4 << 3)
+#define LEA_r_m 0x8d
+#define MOV_r_rm 0x8b
+#define MOV_r_i32 0xb8
+#define MOV_rm_r 0x89
+#define MOV_rm_i32 0xc7
+#define MOV_rm8_i8 0xc6
+#define MOV_rm8_r8 0x88
+#define MOVSD_x_xm 0x10
+#define MOVSD_xm_x 0x11
+#define MOVSXD_r_rm 0x63
+#define MOVSX_r_rm8 (/* GROUP_0F */ 0xbe)
+#define MOVSX_r_rm16 (/* GROUP_0F */ 0xbf)
+#define MOVZX_r_rm8 (/* GROUP_0F */ 0xb6)
+#define MOVZX_r_rm16 (/* GROUP_0F */ 0xb7)
+#define MUL (/* GROUP_F7 */ 4 << 3)
+#define MULSD_x_xm 0x59
+#define NEG_rm (/* GROUP_F7 */ 3 << 3)
+#define NOP 0x90
+#define NOT_rm (/* GROUP_F7 */ 2 << 3)
+#define OR (/* BINARY */ 1 << 3)
+#define OR_r_rm 0x0b
+#define OR_EAX_i32 0x0d
+#define OR_rm_r 0x09
+#define POP_r 0x58
+#define POP_rm 0x8f
+#define POPF 0x9d
+#define PUSH_i32 0x68
+#define PUSH_r 0x50
+#define PUSH_rm (/* GROUP_FF */ 6 << 3)
+#define PUSHF 0x9c
+#define RET_near 0xc3
+#define RET_i16 0xc2
+#define SBB (/* BINARY */ 3 << 3)
+#define SBB_EAX_i32 0x1d
+#define SBB_r_rm 0x1b
+#define SBB_rm_r 0x19
+#define SAR (/* SHIFT */ 7 << 3)
+#define SHL (/* SHIFT */ 4 << 3)
+#define SHR (/* SHIFT */ 5 << 3)
+#define SUB (/* BINARY */ 5 << 3)
+#define SUB_EAX_i32 0x2d
+#define SUB_r_rm 0x2b
+#define SUB_rm_r 0x29
+#define SUBSD_x_xm 0x5c
+#define TEST_EAX_i32 0xa9
+#define TEST_rm_r 0x85
+#define UCOMISD_x_xm 0x2e
+#define XCHG_EAX_r 0x90
+#define XCHG_r_rm 0x87
+#define XOR (/* BINARY */ 6 << 3)
+#define XOR_EAX_i32 0x35
+#define XOR_r_rm 0x33
+#define XOR_rm_r 0x31
+#define XORPD_x_xm 0x57
+
+#define GROUP_0F 0x0f
+#define GROUP_F7 0xf7
+#define GROUP_FF 0xff
+#define GROUP_BINARY_81 0x81
+#define GROUP_BINARY_83 0x83
+#define GROUP_SHIFT_1 0xd1
+#define GROUP_SHIFT_N 0xc1
+#define GROUP_SHIFT_CL 0xd3
+
+#define MOD_REG 0xc0
+#define MOD_DISP8 0x40
+
+#define INC_SIZE(s) (*inst++ = (s), compiler->size += (s))
+
+#define PUSH_REG(r) (*inst++ = (PUSH_r + (r)))
+#define POP_REG(r) (*inst++ = (POP_r + (r)))
+#define RET() (*inst++ = (RET_near))
+#define RET_I16(n) (*inst++ = (RET_i16), *inst++ = n, *inst++ = 0)
/* r32, r/m32 */
-#define MOV_RM(mod, reg, rm) (*buf++ = (0x8b), *buf++ = (mod) << 6 | (reg) << 3 | (rm))
+#define MOV_RM(mod, reg, rm) (*inst++ = (MOV_r_rm), *inst++ = (mod) << 6 | (reg) << 3 | (rm))
+
+/* Multithreading does not affect these static variables, since they store
+ built-in CPU features. Therefore they can be overwritten by different threads
+ if they detect the CPU features in the same time. */
+#if (defined SLJIT_SSE2 && SLJIT_SSE2) && (defined SLJIT_DETECT_SSE2 && SLJIT_DETECT_SSE2)
+static sljit_si cpu_has_sse2 = -1;
+#endif
+static sljit_si cpu_has_cmov = -1;
+
+#if defined(_MSC_VER) && (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
+#if _MSC_VER >= 1400
+#include <intrin.h>
+#else
+#error "MSVC does not support inline assembly in 64 bit mode"
+#endif
+#endif /* _MSC_VER && SLJIT_CONFIG_X86_64 */
+
+static void get_cpu_features(void)
+{
+ sljit_ui features;
+
+#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
+
+#if defined(__GNUC__) || defined(__INTEL_COMPILER) || defined(__SUNPRO_C)
+ /* AT&T syntax. */
+ __asm__ (
+ "pushl %%ebx\n"
+ "movl $0x1, %%eax\n"
+ "cpuid\n"
+ "popl %%ebx\n"
+ "movl %%edx, %0\n"
+ : "=g" (features)
+ :
+ : "%eax", "%ecx", "%edx"
+ );
+#elif defined(_MSC_VER) || defined(__BORLANDC__)
+ /* Intel syntax. */
+ __asm {
+ mov eax, 1
+ push ebx
+ cpuid
+ pop ebx
+ mov features, edx
+ }
+#else
+# error "SLJIT_DETECT_SSE2 is not implemented for this C compiler"
+#endif
+
+#else /* SLJIT_CONFIG_X86_32 */
+
+#if defined(__GNUC__) || defined(__INTEL_COMPILER) || defined(__SUNPRO_C)
+ /* AT&T syntax. */
+ __asm__ (
+ "pushq %%rbx\n"
+ "movl $0x1, %%eax\n"
+ "cpuid\n"
+ "popq %%rbx\n"
+ "movl %%edx, %0\n"
+ : "=g" (features)
+ :
+ : "%rax", "%rcx", "%rdx"
+ );
+#elif defined(_MSC_VER) && _MSC_VER >= 1400
+ int CPUInfo[4];
+
+ __cpuid(CPUInfo, 1);
+ features = (sljit_ui)CPUInfo[3];
+#else
+ __asm {
+ mov eax, 1
+ push rbx
+ cpuid
+ pop rbx
+ mov features, edx
+ }
+#endif
-static sljit_ub get_jump_code(int type)
+#endif /* SLJIT_CONFIG_X86_32 */
+
+#if (defined SLJIT_SSE2 && SLJIT_SSE2) && (defined SLJIT_DETECT_SSE2 && SLJIT_DETECT_SSE2)
+ cpu_has_sse2 = (features >> 26) & 0x1;
+#endif
+ cpu_has_cmov = (features >> 15) & 0x1;
+}
+
+static sljit_ub get_jump_code(sljit_si type)
{
switch (type) {
case SLJIT_C_EQUAL:
case SLJIT_C_FLOAT_EQUAL:
- return 0x84;
+ return 0x84 /* je */;
case SLJIT_C_NOT_EQUAL:
case SLJIT_C_FLOAT_NOT_EQUAL:
- return 0x85;
+ return 0x85 /* jne */;
case SLJIT_C_LESS:
case SLJIT_C_FLOAT_LESS:
- return 0x82;
+ return 0x82 /* jc */;
case SLJIT_C_GREATER_EQUAL:
case SLJIT_C_FLOAT_GREATER_EQUAL:
- return 0x83;
+ return 0x83 /* jae */;
case SLJIT_C_GREATER:
case SLJIT_C_FLOAT_GREATER:
- return 0x87;
+ return 0x87 /* jnbe */;
case SLJIT_C_LESS_EQUAL:
case SLJIT_C_FLOAT_LESS_EQUAL:
- return 0x86;
+ return 0x86 /* jbe */;
case SLJIT_C_SIG_LESS:
- return 0x8c;
+ return 0x8c /* jl */;
case SLJIT_C_SIG_GREATER_EQUAL:
- return 0x8d;
+ return 0x8d /* jnl */;
case SLJIT_C_SIG_GREATER:
- return 0x8f;
+ return 0x8f /* jnle */;
case SLJIT_C_SIG_LESS_EQUAL:
- return 0x8e;
+ return 0x8e /* jle */;
case SLJIT_C_OVERFLOW:
case SLJIT_C_MUL_OVERFLOW:
- return 0x80;
+ return 0x80 /* jo */;
case SLJIT_C_NOT_OVERFLOW:
case SLJIT_C_MUL_NOT_OVERFLOW:
- return 0x81;
+ return 0x81 /* jno */;
- case SLJIT_C_FLOAT_NAN:
- return 0x8a;
+ case SLJIT_C_FLOAT_UNORDERED:
+ return 0x8a /* jp */;
- case SLJIT_C_FLOAT_NOT_NAN:
- return 0x8b;
+ case SLJIT_C_FLOAT_ORDERED:
+ return 0x8b /* jpo */;
}
return 0;
}
-static sljit_ub* generate_far_jump_code(struct sljit_jump *jump, sljit_ub *code_ptr, int type);
+static sljit_ub* generate_far_jump_code(struct sljit_jump *jump, sljit_ub *code_ptr, sljit_si type);
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
-static sljit_ub* generate_fixed_jump(sljit_ub *code_ptr, sljit_w addr, int type);
+static sljit_ub* generate_fixed_jump(sljit_ub *code_ptr, sljit_sw addr, sljit_si type);
#endif
-static sljit_ub* generate_near_jump_code(struct sljit_jump *jump, sljit_ub *code_ptr, sljit_ub *code, int type)
+static sljit_ub* generate_near_jump_code(struct sljit_jump *jump, sljit_ub *code_ptr, sljit_ub *code, sljit_si type)
{
- int short_jump;
+ sljit_si short_jump;
sljit_uw label_addr;
if (jump->flags & JUMP_LABEL)
label_addr = (sljit_uw)(code + jump->u.label->size);
else
label_addr = jump->u.target;
- short_jump = (sljit_w)(label_addr - (jump->addr + 2)) >= -128 && (sljit_w)(label_addr - (jump->addr + 2)) <= 127;
+ short_jump = (sljit_sw)(label_addr - (jump->addr + 2)) >= -128 && (sljit_sw)(label_addr - (jump->addr + 2)) <= 127;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- if ((sljit_w)(label_addr - (jump->addr + 1)) > 0x7fffffffll || (sljit_w)(label_addr - (jump->addr + 1)) < -0x80000000ll)
+ if ((sljit_sw)(label_addr - (jump->addr + 1)) > 0x7fffffffll || (sljit_sw)(label_addr - (jump->addr + 1)) < -0x80000000ll)
return generate_far_jump_code(jump, code_ptr, type);
#endif
if (type == SLJIT_JUMP) {
if (short_jump)
- *code_ptr++ = 0xeb;
+ *code_ptr++ = JMP_i8;
else
- *code_ptr++ = 0xe9;
+ *code_ptr++ = JMP_i32;
jump->addr++;
}
else if (type >= SLJIT_FAST_CALL) {
short_jump = 0;
- *code_ptr++ = 0xe8;
+ *code_ptr++ = CALL_i32;
jump->addr++;
}
else if (short_jump) {
@@ -251,20 +438,20 @@ static sljit_ub* generate_near_jump_code(struct sljit_jump *jump, sljit_ub *code
jump->addr++;
}
else {
- *code_ptr++ = 0x0f;
+ *code_ptr++ = GROUP_0F;
*code_ptr++ = get_jump_code(type);
jump->addr += 2;
}
if (short_jump) {
jump->flags |= PATCH_MB;
- code_ptr += sizeof(sljit_b);
+ code_ptr += sizeof(sljit_sb);
} else {
jump->flags |= PATCH_MW;
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- code_ptr += sizeof(sljit_w);
+ code_ptr += sizeof(sljit_sw);
#else
- code_ptr += sizeof(sljit_hw);
+ code_ptr += sizeof(sljit_si);
#endif
}
@@ -323,19 +510,19 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
label = label->next;
}
else if (*buf_ptr == 1) {
- const_->addr = ((sljit_uw)code_ptr) - sizeof(sljit_w);
+ const_->addr = ((sljit_uw)code_ptr) - sizeof(sljit_sw);
const_ = const_->next;
}
else {
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- *code_ptr++ = (*buf_ptr == 2) ? 0xe8 /* call */ : 0xe9 /* jmp */;
+ *code_ptr++ = (*buf_ptr == 2) ? CALL_i32 : JMP_i32;
buf_ptr++;
- *(sljit_w*)code_ptr = *(sljit_w*)buf_ptr - ((sljit_w)code_ptr + sizeof(sljit_w));
- code_ptr += sizeof(sljit_w);
- buf_ptr += sizeof(sljit_w) - 1;
+ *(sljit_sw*)code_ptr = *(sljit_sw*)buf_ptr - ((sljit_sw)code_ptr + sizeof(sljit_sw));
+ code_ptr += sizeof(sljit_sw);
+ buf_ptr += sizeof(sljit_sw) - 1;
#else
- code_ptr = generate_fixed_jump(code_ptr, *(sljit_w*)(buf_ptr + 1), *buf_ptr);
- buf_ptr += sizeof(sljit_w);
+ code_ptr = generate_fixed_jump(code_ptr, *(sljit_sw*)(buf_ptr + 1), *buf_ptr);
+ buf_ptr += sizeof(sljit_sw);
#endif
}
buf_ptr++;
@@ -352,29 +539,29 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
jump = compiler->jumps;
while (jump) {
if (jump->flags & PATCH_MB) {
- SLJIT_ASSERT((sljit_w)(jump->u.label->addr - (jump->addr + sizeof(sljit_b))) >= -128 && (sljit_w)(jump->u.label->addr - (jump->addr + sizeof(sljit_b))) <= 127);
- *(sljit_ub*)jump->addr = (sljit_ub)(jump->u.label->addr - (jump->addr + sizeof(sljit_b)));
+ SLJIT_ASSERT((sljit_sw)(jump->u.label->addr - (jump->addr + sizeof(sljit_sb))) >= -128 && (sljit_sw)(jump->u.label->addr - (jump->addr + sizeof(sljit_sb))) <= 127);
+ *(sljit_ub*)jump->addr = (sljit_ub)(jump->u.label->addr - (jump->addr + sizeof(sljit_sb)));
} else if (jump->flags & PATCH_MW) {
if (jump->flags & JUMP_LABEL) {
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- *(sljit_w*)jump->addr = (sljit_w)(jump->u.label->addr - (jump->addr + sizeof(sljit_w)));
+ *(sljit_sw*)jump->addr = (sljit_sw)(jump->u.label->addr - (jump->addr + sizeof(sljit_sw)));
#else
- SLJIT_ASSERT((sljit_w)(jump->u.label->addr - (jump->addr + sizeof(sljit_hw))) >= -0x80000000ll && (sljit_w)(jump->u.label->addr - (jump->addr + sizeof(sljit_hw))) <= 0x7fffffffll);
- *(sljit_hw*)jump->addr = (sljit_hw)(jump->u.label->addr - (jump->addr + sizeof(sljit_hw)));
+ SLJIT_ASSERT((sljit_sw)(jump->u.label->addr - (jump->addr + sizeof(sljit_si))) >= -0x80000000ll && (sljit_sw)(jump->u.label->addr - (jump->addr + sizeof(sljit_si))) <= 0x7fffffffll);
+ *(sljit_si*)jump->addr = (sljit_si)(jump->u.label->addr - (jump->addr + sizeof(sljit_si)));
#endif
}
else {
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- *(sljit_w*)jump->addr = (sljit_w)(jump->u.target - (jump->addr + sizeof(sljit_w)));
+ *(sljit_sw*)jump->addr = (sljit_sw)(jump->u.target - (jump->addr + sizeof(sljit_sw)));
#else
- SLJIT_ASSERT((sljit_w)(jump->u.target - (jump->addr + sizeof(sljit_hw))) >= -0x80000000ll && (sljit_w)(jump->u.target - (jump->addr + sizeof(sljit_hw))) <= 0x7fffffffll);
- *(sljit_hw*)jump->addr = (sljit_hw)(jump->u.target - (jump->addr + sizeof(sljit_hw)));
+ SLJIT_ASSERT((sljit_sw)(jump->u.target - (jump->addr + sizeof(sljit_si))) >= -0x80000000ll && (sljit_sw)(jump->u.target - (jump->addr + sizeof(sljit_si))) <= 0x7fffffffll);
+ *(sljit_si*)jump->addr = (sljit_si)(jump->u.target - (jump->addr + sizeof(sljit_si)));
#endif
}
}
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
else if (jump->flags & PATCH_MD)
- *(sljit_w*)jump->addr = jump->u.label->addr;
+ *(sljit_sw*)jump->addr = jump->u.label->addr;
#endif
jump = jump->next;
@@ -391,65 +578,65 @@ SLJIT_API_FUNC_ATTRIBUTE void* sljit_generate_code(struct sljit_compiler *compil
/* Operators */
/* --------------------------------------------------------------------- */
-static int emit_cum_binary(struct sljit_compiler *compiler,
+static sljit_si emit_cum_binary(struct sljit_compiler *compiler,
sljit_ub op_rm, sljit_ub op_mr, sljit_ub op_imm, sljit_ub op_eax_imm,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w);
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w);
-static int emit_non_cum_binary(struct sljit_compiler *compiler,
+static sljit_si emit_non_cum_binary(struct sljit_compiler *compiler,
sljit_ub op_rm, sljit_ub op_mr, sljit_ub op_imm, sljit_ub op_eax_imm,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w);
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w);
-static int emit_mov(struct sljit_compiler *compiler,
- int dst, sljit_w dstw,
- int src, sljit_w srcw);
+static sljit_si emit_mov(struct sljit_compiler *compiler,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw);
-static SLJIT_INLINE int emit_save_flags(struct sljit_compiler *compiler)
+static SLJIT_INLINE sljit_si emit_save_flags(struct sljit_compiler *compiler)
{
- sljit_ub *buf;
+ sljit_ub *inst;
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 5);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 5);
+ FAIL_IF(!inst);
INC_SIZE(5);
- *buf++ = 0x9c; /* pushfd */
#else
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 6);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 6);
+ FAIL_IF(!inst);
INC_SIZE(6);
- *buf++ = 0x9c; /* pushfq */
- *buf++ = 0x48;
+ *inst++ = REX_W;
#endif
- *buf++ = 0x8d; /* lea esp/rsp, [esp/rsp + sizeof(sljit_w)] */
- *buf++ = 0x64;
- *buf++ = 0x24;
- *buf++ = sizeof(sljit_w);
+ *inst++ = LEA_r_m; /* lea esp/rsp, [esp/rsp + sizeof(sljit_sw)] */
+ *inst++ = 0x64;
+ *inst++ = 0x24;
+ *inst++ = (sljit_ub)sizeof(sljit_sw);
+ *inst++ = PUSHF;
compiler->flags_saved = 1;
return SLJIT_SUCCESS;
}
-static SLJIT_INLINE int emit_restore_flags(struct sljit_compiler *compiler, int keep_flags)
+static SLJIT_INLINE sljit_si emit_restore_flags(struct sljit_compiler *compiler, sljit_si keep_flags)
{
- sljit_ub *buf;
+ sljit_ub *inst;
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 5);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 5);
+ FAIL_IF(!inst);
INC_SIZE(5);
+ *inst++ = POPF;
#else
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 6);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 6);
+ FAIL_IF(!inst);
INC_SIZE(6);
- *buf++ = 0x48;
+ *inst++ = POPF;
+ *inst++ = REX_W;
#endif
- *buf++ = 0x8d; /* lea esp/rsp, [esp/rsp - sizeof(sljit_w)] */
- *buf++ = 0x64;
- *buf++ = 0x24;
- *buf++ = (sljit_ub)-(int)sizeof(sljit_w);
- *buf++ = 0x9d; /* popfd / popfq */
+ *inst++ = LEA_r_m; /* lea esp/rsp, [esp/rsp - sizeof(sljit_sw)] */
+ *inst++ = 0x64;
+ *inst++ = 0x24;
+ *inst++ = (sljit_ub)-(sljit_sb)sizeof(sljit_sw);
compiler->flags_saved = keep_flags;
return SLJIT_SUCCESS;
}
@@ -457,11 +644,17 @@ static SLJIT_INLINE int emit_restore_flags(struct sljit_compiler *compiler, int
#ifdef _WIN32
#include <malloc.h>
-static void SLJIT_CALL sljit_touch_stack(sljit_w local_size)
+static void SLJIT_CALL sljit_grow_stack(sljit_sw local_size)
{
- /* Workaround for calling _chkstk. */
+ /* Workaround for calling the internal _chkstk() function on Windows.
+ This function touches all 4k pages belongs to the requested stack space,
+ which size is passed in local_size. This is necessary on Windows where
+ the stack can only grow in 4k steps. However, this function just burn
+ CPU cycles if the stack is large enough, but you don't know it in advance.
+ I think this is a bad design even if it has some reasons. */
alloca(local_size);
}
+
#endif
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
@@ -470,79 +663,79 @@ static void SLJIT_CALL sljit_touch_stack(sljit_w local_size)
#include "sljitNativeX86_64.c"
#endif
-static int emit_mov(struct sljit_compiler *compiler,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+static sljit_si emit_mov(struct sljit_compiler *compiler,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- sljit_ub* code;
+ sljit_ub* inst;
if (dst == SLJIT_UNUSED) {
/* No destination, doesn't need to setup flags. */
if (src & SLJIT_MEM) {
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src, srcw);
- FAIL_IF(!code);
- *code = 0x8b;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src, srcw);
+ FAIL_IF(!inst);
+ *inst = MOV_r_rm;
}
return SLJIT_SUCCESS;
}
- if (src >= SLJIT_TEMPORARY_REG1 && src <= TMP_REGISTER) {
- code = emit_x86_instruction(compiler, 1, src, 0, dst, dstw);
- FAIL_IF(!code);
- *code = 0x89;
+ if (src <= TMP_REGISTER) {
+ inst = emit_x86_instruction(compiler, 1, src, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm_r;
return SLJIT_SUCCESS;
}
if (src & SLJIT_IMM) {
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= TMP_REGISTER) {
+ if (dst <= TMP_REGISTER) {
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- return emit_do_imm(compiler, 0xb8 + reg_map[dst], srcw);
+ return emit_do_imm(compiler, MOV_r_i32 + reg_map[dst], srcw);
#else
if (!compiler->mode32) {
if (NOT_HALFWORD(srcw))
return emit_load_imm64(compiler, dst, srcw);
}
else
- return emit_do_imm32(compiler, (reg_map[dst] >= 8) ? REX_B : 0, 0xb8 + reg_lmap[dst], srcw);
+ return emit_do_imm32(compiler, (reg_map[dst] >= 8) ? REX_B : 0, MOV_r_i32 + reg_lmap[dst], srcw);
#endif
}
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
if (!compiler->mode32 && NOT_HALFWORD(srcw)) {
FAIL_IF(emit_load_imm64(compiler, TMP_REG2, srcw));
- code = emit_x86_instruction(compiler, 1, TMP_REG2, 0, dst, dstw);
- FAIL_IF(!code);
- *code = 0x89;
+ inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm_r;
return SLJIT_SUCCESS;
}
#endif
- code = emit_x86_instruction(compiler, 1, SLJIT_IMM, srcw, dst, dstw);
- FAIL_IF(!code);
- *code = 0xc7;
+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, srcw, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm_i32;
return SLJIT_SUCCESS;
}
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= TMP_REGISTER) {
- code = emit_x86_instruction(compiler, 1, dst, 0, src, srcw);
- FAIL_IF(!code);
- *code = 0x8b;
+ if (dst <= TMP_REGISTER) {
+ inst = emit_x86_instruction(compiler, 1, dst, 0, src, srcw);
+ FAIL_IF(!inst);
+ *inst = MOV_r_rm;
return SLJIT_SUCCESS;
}
/* Memory to memory move. Requires two instruction. */
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src, srcw);
- FAIL_IF(!code);
- *code = 0x8b;
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, dst, dstw);
- FAIL_IF(!code);
- *code = 0x89;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src, srcw);
+ FAIL_IF(!inst);
+ *inst = MOV_r_rm;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm_r;
return SLJIT_SUCCESS;
}
#define EMIT_MOV(compiler, dst, dstw, src, srcw) \
FAIL_IF(emit_mov(compiler, dst, dstw, src, srcw));
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int op)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op0(struct sljit_compiler *compiler, sljit_si op)
{
- sljit_ub *buf;
+ sljit_ub *inst;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- int size;
+ sljit_si size;
#endif
CHECK_ERROR();
@@ -550,16 +743,16 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
switch (GET_OPCODE(op)) {
case SLJIT_BREAKPOINT:
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1);
+ FAIL_IF(!inst);
INC_SIZE(1);
- *buf = 0xcc;
+ *inst = INT3;
break;
case SLJIT_NOP:
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1);
+ FAIL_IF(!inst);
INC_SIZE(1);
- *buf = 0x90;
+ *inst = NOP;
break;
case SLJIT_UMUL:
case SLJIT_SMUL:
@@ -569,14 +762,14 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
#ifdef _WIN64
SLJIT_COMPILE_ASSERT(
- reg_map[SLJIT_TEMPORARY_REG1] == 0
- && reg_map[SLJIT_TEMPORARY_REG2] == 2
+ reg_map[SLJIT_SCRATCH_REG1] == 0
+ && reg_map[SLJIT_SCRATCH_REG2] == 2
&& reg_map[TMP_REGISTER] > 7,
invalid_register_assignment_for_div_mul);
#else
SLJIT_COMPILE_ASSERT(
- reg_map[SLJIT_TEMPORARY_REG1] == 0
- && reg_map[SLJIT_TEMPORARY_REG2] < 7
+ reg_map[SLJIT_SCRATCH_REG1] == 0
+ && reg_map[SLJIT_SCRATCH_REG2] < 7
&& reg_map[TMP_REGISTER] == 2,
invalid_register_assignment_for_div_mul);
#endif
@@ -586,87 +779,86 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
op = GET_OPCODE(op);
if (op == SLJIT_UDIV) {
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || defined(_WIN64)
- EMIT_MOV(compiler, TMP_REGISTER, 0, SLJIT_TEMPORARY_REG2, 0);
- buf = emit_x86_instruction(compiler, 1, SLJIT_TEMPORARY_REG2, 0, SLJIT_TEMPORARY_REG2, 0);
+ EMIT_MOV(compiler, TMP_REGISTER, 0, SLJIT_SCRATCH_REG2, 0);
+ inst = emit_x86_instruction(compiler, 1, SLJIT_SCRATCH_REG2, 0, SLJIT_SCRATCH_REG2, 0);
#else
- buf = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, TMP_REGISTER, 0);
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, TMP_REGISTER, 0);
#endif
- FAIL_IF(!buf);
- *buf = 0x33;
+ FAIL_IF(!inst);
+ *inst = XOR_r_rm;
}
if (op == SLJIT_SDIV) {
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32) || defined(_WIN64)
- EMIT_MOV(compiler, TMP_REGISTER, 0, SLJIT_TEMPORARY_REG2, 0);
+ EMIT_MOV(compiler, TMP_REGISTER, 0, SLJIT_SCRATCH_REG2, 0);
#endif
- /* CDQ instruction */
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1);
+ FAIL_IF(!inst);
INC_SIZE(1);
- *buf = 0x99;
+ *inst = CDQ;
#else
if (compiler->mode32) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 1);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1);
+ FAIL_IF(!inst);
INC_SIZE(1);
- *buf = 0x99;
+ *inst = CDQ;
} else {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 2);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 2);
+ FAIL_IF(!inst);
INC_SIZE(2);
- *buf++ = REX_W;
- *buf = 0x99;
+ *inst++ = REX_W;
+ *inst = CDQ;
}
#endif
}
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 2);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 2);
+ FAIL_IF(!inst);
INC_SIZE(2);
- *buf++ = 0xf7;
- *buf = 0xc0 | ((op >= SLJIT_UDIV) ? reg_map[TMP_REGISTER] : reg_map[SLJIT_TEMPORARY_REG2]);
+ *inst++ = GROUP_F7;
+ *inst = MOD_REG | ((op >= SLJIT_UDIV) ? reg_map[TMP_REGISTER] : reg_map[SLJIT_SCRATCH_REG2]);
#else
#ifdef _WIN64
size = (!compiler->mode32 || op >= SLJIT_UDIV) ? 3 : 2;
#else
size = (!compiler->mode32) ? 3 : 2;
#endif
- buf = (sljit_ub*)ensure_buf(compiler, 1 + size);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + size);
+ FAIL_IF(!inst);
INC_SIZE(size);
#ifdef _WIN64
if (!compiler->mode32)
- *buf++ = REX_W | ((op >= SLJIT_UDIV) ? REX_B : 0);
+ *inst++ = REX_W | ((op >= SLJIT_UDIV) ? REX_B : 0);
else if (op >= SLJIT_UDIV)
- *buf++ = REX_B;
- *buf++ = 0xf7;
- *buf = 0xc0 | ((op >= SLJIT_UDIV) ? reg_lmap[TMP_REGISTER] : reg_lmap[SLJIT_TEMPORARY_REG2]);
+ *inst++ = REX_B;
+ *inst++ = GROUP_F7;
+ *inst = MOD_REG | ((op >= SLJIT_UDIV) ? reg_lmap[TMP_REGISTER] : reg_lmap[SLJIT_SCRATCH_REG2]);
#else
if (!compiler->mode32)
- *buf++ = REX_W;
- *buf++ = 0xf7;
- *buf = 0xc0 | reg_map[SLJIT_TEMPORARY_REG2];
+ *inst++ = REX_W;
+ *inst++ = GROUP_F7;
+ *inst = MOD_REG | reg_map[SLJIT_SCRATCH_REG2];
#endif
#endif
switch (op) {
case SLJIT_UMUL:
- *buf |= 4 << 3;
+ *inst |= MUL;
break;
case SLJIT_SMUL:
- *buf |= 5 << 3;
+ *inst |= IMUL;
break;
case SLJIT_UDIV:
- *buf |= 6 << 3;
+ *inst |= DIV;
break;
case SLJIT_SDIV:
- *buf |= 7 << 3;
+ *inst |= IDIV;
break;
}
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) && !defined(_WIN64)
- EMIT_MOV(compiler, SLJIT_TEMPORARY_REG2, 0, TMP_REGISTER, 0);
+ EMIT_MOV(compiler, SLJIT_SCRATCH_REG2, 0, TMP_REGISTER, 0);
#endif
break;
}
@@ -676,20 +868,20 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op0(struct sljit_compiler *compiler, int
#define ENCODE_PREFIX(prefix) \
do { \
- code = (sljit_ub*)ensure_buf(compiler, 1 + 1); \
- FAIL_IF(!code); \
- INC_CSIZE(1); \
- *code = (prefix); \
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1); \
+ FAIL_IF(!inst); \
+ INC_SIZE(1); \
+ *inst = (prefix); \
} while (0)
-static int emit_mov_byte(struct sljit_compiler *compiler, int sign,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+static sljit_si emit_mov_byte(struct sljit_compiler *compiler, sljit_si sign,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- sljit_ub* code;
- int dst_r;
+ sljit_ub* inst;
+ sljit_si dst_r;
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- int work_r;
+ sljit_si work_r;
#endif
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
@@ -700,22 +892,25 @@ static int emit_mov_byte(struct sljit_compiler *compiler, int sign,
return SLJIT_SUCCESS; /* Empty instruction. */
if (src & SLJIT_IMM) {
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= TMP_REGISTER) {
+ if (dst <= TMP_REGISTER) {
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- return emit_do_imm(compiler, 0xb8 + reg_map[dst], srcw);
+ return emit_do_imm(compiler, MOV_r_i32 + reg_map[dst], srcw);
#else
- return emit_load_imm64(compiler, dst, srcw);
+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, srcw, dst, 0);
+ FAIL_IF(!inst);
+ *inst = MOV_rm_i32;
+ return SLJIT_SUCCESS;
#endif
}
- code = emit_x86_instruction(compiler, 1 | EX86_BYTE_ARG | EX86_NO_REXW, SLJIT_IMM, srcw, dst, dstw);
- FAIL_IF(!code);
- *code = 0xc6;
+ inst = emit_x86_instruction(compiler, 1 | EX86_BYTE_ARG | EX86_NO_REXW, SLJIT_IMM, srcw, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm8_i8;
return SLJIT_SUCCESS;
}
- dst_r = (dst >= SLJIT_TEMPORARY_REG1 && dst <= TMP_REGISTER) ? dst : TMP_REGISTER;
+ dst_r = (dst <= TMP_REGISTER) ? dst : TMP_REGISTER;
- if ((dst & SLJIT_MEM) && src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_NO_REGISTERS) {
+ if ((dst & SLJIT_MEM) && src <= TMP_REGISTER) {
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
if (reg_map[src] >= 4) {
SLJIT_ASSERT(dst_r == TMP_REGISTER);
@@ -727,35 +922,34 @@ static int emit_mov_byte(struct sljit_compiler *compiler, int sign,
#endif
}
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- else if (src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_NO_REGISTERS && reg_map[src] >= 4) {
+ else if (src <= TMP_REGISTER && reg_map[src] >= 4) {
/* src, dst are registers. */
- SLJIT_ASSERT(dst >= SLJIT_TEMPORARY_REG1 && dst <= TMP_REGISTER);
+ SLJIT_ASSERT(dst >= SLJIT_SCRATCH_REG1 && dst <= TMP_REGISTER);
if (reg_map[dst] < 4) {
if (dst != src)
EMIT_MOV(compiler, dst, 0, src, 0);
- code = emit_x86_instruction(compiler, 2, dst, 0, dst, 0);
- FAIL_IF(!code);
- *code++ = 0x0f;
- *code = sign ? 0xbe : 0xb6;
+ inst = emit_x86_instruction(compiler, 2, dst, 0, dst, 0);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_0F;
+ *inst = sign ? MOVSX_r_rm8 : MOVZX_r_rm8;
}
else {
if (dst != src)
EMIT_MOV(compiler, dst, 0, src, 0);
if (sign) {
/* shl reg, 24 */
- code = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_IMM, 24, dst, 0);
- FAIL_IF(!code);
- *code |= 0x4 << 3;
- code = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_IMM, 24, dst, 0);
- FAIL_IF(!code);
- /* shr/sar reg, 24 */
- *code |= 0x7 << 3;
+ inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_IMM, 24, dst, 0);
+ FAIL_IF(!inst);
+ *inst |= SHL;
+ /* sar reg, 24 */
+ inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_IMM, 24, dst, 0);
+ FAIL_IF(!inst);
+ *inst |= SAR;
}
else {
- /* and dst, 0xff */
- code = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, 255, dst, 0);
- FAIL_IF(!code);
- *(code + 1) |= 0x4 << 3;
+ inst = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, 0xff, dst, 0);
+ FAIL_IF(!inst);
+ *(inst + 1) |= AND;
}
}
return SLJIT_SUCCESS;
@@ -763,74 +957,74 @@ static int emit_mov_byte(struct sljit_compiler *compiler, int sign,
#endif
else {
/* src can be memory addr or reg_map[src] < 4 on x86_32 architectures. */
- code = emit_x86_instruction(compiler, 2, dst_r, 0, src, srcw);
- FAIL_IF(!code);
- *code++ = 0x0f;
- *code = sign ? 0xbe : 0xb6;
+ inst = emit_x86_instruction(compiler, 2, dst_r, 0, src, srcw);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_0F;
+ *inst = sign ? MOVSX_r_rm8 : MOVZX_r_rm8;
}
if (dst & SLJIT_MEM) {
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
if (dst_r == TMP_REGISTER) {
/* Find a non-used register, whose reg_map[src] < 4. */
- if ((dst & 0xf) == SLJIT_TEMPORARY_REG1) {
- if ((dst & 0xf0) == (SLJIT_TEMPORARY_REG2 << 4))
- work_r = SLJIT_TEMPORARY_REG3;
+ if ((dst & 0xf) == SLJIT_SCRATCH_REG1) {
+ if ((dst & 0xf0) == (SLJIT_SCRATCH_REG2 << 4))
+ work_r = SLJIT_SCRATCH_REG3;
else
- work_r = SLJIT_TEMPORARY_REG2;
+ work_r = SLJIT_SCRATCH_REG2;
}
else {
- if ((dst & 0xf0) != (SLJIT_TEMPORARY_REG1 << 4))
- work_r = SLJIT_TEMPORARY_REG1;
- else if ((dst & 0xf) == SLJIT_TEMPORARY_REG2)
- work_r = SLJIT_TEMPORARY_REG3;
+ if ((dst & 0xf0) != (SLJIT_SCRATCH_REG1 << 4))
+ work_r = SLJIT_SCRATCH_REG1;
+ else if ((dst & 0xf) == SLJIT_SCRATCH_REG2)
+ work_r = SLJIT_SCRATCH_REG3;
else
- work_r = SLJIT_TEMPORARY_REG2;
+ work_r = SLJIT_SCRATCH_REG2;
}
- if (work_r == SLJIT_TEMPORARY_REG1) {
- ENCODE_PREFIX(0x90 + reg_map[TMP_REGISTER]);
+ if (work_r == SLJIT_SCRATCH_REG1) {
+ ENCODE_PREFIX(XCHG_EAX_r + reg_map[TMP_REGISTER]);
}
else {
- code = emit_x86_instruction(compiler, 1, work_r, 0, dst_r, 0);
- FAIL_IF(!code);
- *code = 0x87;
+ inst = emit_x86_instruction(compiler, 1, work_r, 0, dst_r, 0);
+ FAIL_IF(!inst);
+ *inst = XCHG_r_rm;
}
- code = emit_x86_instruction(compiler, 1, work_r, 0, dst, dstw);
- FAIL_IF(!code);
- *code = 0x88;
+ inst = emit_x86_instruction(compiler, 1, work_r, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm8_r8;
- if (work_r == SLJIT_TEMPORARY_REG1) {
- ENCODE_PREFIX(0x90 + reg_map[TMP_REGISTER]);
+ if (work_r == SLJIT_SCRATCH_REG1) {
+ ENCODE_PREFIX(XCHG_EAX_r + reg_map[TMP_REGISTER]);
}
else {
- code = emit_x86_instruction(compiler, 1, work_r, 0, dst_r, 0);
- FAIL_IF(!code);
- *code = 0x87;
+ inst = emit_x86_instruction(compiler, 1, work_r, 0, dst_r, 0);
+ FAIL_IF(!inst);
+ *inst = XCHG_r_rm;
}
}
else {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, dst, dstw);
- FAIL_IF(!code);
- *code = 0x88;
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm8_r8;
}
#else
- code = emit_x86_instruction(compiler, 1 | EX86_REX | EX86_NO_REXW, dst_r, 0, dst, dstw);
- FAIL_IF(!code);
- *code = 0x88;
+ inst = emit_x86_instruction(compiler, 1 | EX86_REX | EX86_NO_REXW, dst_r, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm8_r8;
#endif
}
return SLJIT_SUCCESS;
}
-static int emit_mov_half(struct sljit_compiler *compiler, int sign,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+static sljit_si emit_mov_half(struct sljit_compiler *compiler, sljit_si sign,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- sljit_ub* code;
- int dst_r;
+ sljit_ub* inst;
+ sljit_si dst_r;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
compiler->mode32 = 0;
@@ -840,193 +1034,222 @@ static int emit_mov_half(struct sljit_compiler *compiler, int sign,
return SLJIT_SUCCESS; /* Empty instruction. */
if (src & SLJIT_IMM) {
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= TMP_REGISTER) {
+ if (dst <= TMP_REGISTER) {
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- return emit_do_imm(compiler, 0xb8 + reg_map[dst], srcw);
+ return emit_do_imm(compiler, MOV_r_i32 + reg_map[dst], srcw);
#else
- return emit_load_imm64(compiler, dst, srcw);
+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, srcw, dst, 0);
+ FAIL_IF(!inst);
+ *inst = MOV_rm_i32;
+ return SLJIT_SUCCESS;
#endif
}
- code = emit_x86_instruction(compiler, 1 | EX86_HALF_ARG | EX86_NO_REXW | EX86_PREF_66, SLJIT_IMM, srcw, dst, dstw);
- FAIL_IF(!code);
- *code = 0xc7;
+ inst = emit_x86_instruction(compiler, 1 | EX86_HALF_ARG | EX86_NO_REXW | EX86_PREF_66, SLJIT_IMM, srcw, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm_i32;
return SLJIT_SUCCESS;
}
- dst_r = (dst >= SLJIT_TEMPORARY_REG1 && dst <= TMP_REGISTER) ? dst : TMP_REGISTER;
+ dst_r = (dst <= TMP_REGISTER) ? dst : TMP_REGISTER;
- if ((dst & SLJIT_MEM) && (src >= SLJIT_TEMPORARY_REG1 && src <= SLJIT_NO_REGISTERS))
+ if ((dst & SLJIT_MEM) && src <= TMP_REGISTER)
dst_r = src;
else {
- code = emit_x86_instruction(compiler, 2, dst_r, 0, src, srcw);
- FAIL_IF(!code);
- *code++ = 0x0f;
- *code = sign ? 0xbf : 0xb7;
+ inst = emit_x86_instruction(compiler, 2, dst_r, 0, src, srcw);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_0F;
+ *inst = sign ? MOVSX_r_rm16 : MOVZX_r_rm16;
}
if (dst & SLJIT_MEM) {
- code = emit_x86_instruction(compiler, 1 | EX86_NO_REXW | EX86_PREF_66, dst_r, 0, dst, dstw);
- FAIL_IF(!code);
- *code = 0x89;
+ inst = emit_x86_instruction(compiler, 1 | EX86_NO_REXW | EX86_PREF_66, dst_r, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = MOV_rm_r;
}
return SLJIT_SUCCESS;
}
-static int emit_unary(struct sljit_compiler *compiler, int un_index,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+static sljit_si emit_unary(struct sljit_compiler *compiler, sljit_ub opcode,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- sljit_ub* code;
+ sljit_ub* inst;
if (dst == SLJIT_UNUSED) {
EMIT_MOV(compiler, TMP_REGISTER, 0, src, srcw);
- code = emit_x86_instruction(compiler, 1, 0, 0, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code++ = 0xf7;
- *code |= (un_index) << 3;
+ inst = emit_x86_instruction(compiler, 1, 0, 0, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_F7;
+ *inst |= opcode;
return SLJIT_SUCCESS;
}
if (dst == src && dstw == srcw) {
/* Same input and output */
- code = emit_x86_instruction(compiler, 1, 0, 0, dst, dstw);
- FAIL_IF(!code);
- *code++ = 0xf7;
- *code |= (un_index) << 3;
+ inst = emit_x86_instruction(compiler, 1, 0, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_F7;
+ *inst |= opcode;
return SLJIT_SUCCESS;
}
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) {
+ if (dst <= TMP_REGISTER) {
EMIT_MOV(compiler, dst, 0, src, srcw);
- code = emit_x86_instruction(compiler, 1, 0, 0, dst, dstw);
- FAIL_IF(!code);
- *code++ = 0xf7;
- *code |= (un_index) << 3;
+ inst = emit_x86_instruction(compiler, 1, 0, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_F7;
+ *inst |= opcode;
return SLJIT_SUCCESS;
}
EMIT_MOV(compiler, TMP_REGISTER, 0, src, srcw);
- code = emit_x86_instruction(compiler, 1, 0, 0, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code++ = 0xf7;
- *code |= (un_index) << 3;
+ inst = emit_x86_instruction(compiler, 1, 0, 0, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_F7;
+ *inst |= opcode;
EMIT_MOV(compiler, dst, dstw, TMP_REGISTER, 0);
return SLJIT_SUCCESS;
}
-static int emit_not_with_flags(struct sljit_compiler *compiler,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+static sljit_si emit_not_with_flags(struct sljit_compiler *compiler,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- sljit_ub* code;
+ sljit_ub* inst;
if (dst == SLJIT_UNUSED) {
EMIT_MOV(compiler, TMP_REGISTER, 0, src, srcw);
- code = emit_x86_instruction(compiler, 1, 0, 0, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code++ = 0xf7;
- *code |= 0x2 << 3;
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code = 0x0b;
+ inst = emit_x86_instruction(compiler, 1, 0, 0, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_F7;
+ *inst |= NOT_rm;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst = OR_r_rm;
return SLJIT_SUCCESS;
}
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) {
+ if (dst <= TMP_REGISTER) {
EMIT_MOV(compiler, dst, 0, src, srcw);
- code = emit_x86_instruction(compiler, 1, 0, 0, dst, dstw);
- FAIL_IF(!code);
- *code++ = 0xf7;
- *code |= 0x2 << 3;
- code = emit_x86_instruction(compiler, 1, dst, 0, dst, 0);
- FAIL_IF(!code);
- *code = 0x0b;
+ inst = emit_x86_instruction(compiler, 1, 0, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_F7;
+ *inst |= NOT_rm;
+ inst = emit_x86_instruction(compiler, 1, dst, 0, dst, 0);
+ FAIL_IF(!inst);
+ *inst = OR_r_rm;
return SLJIT_SUCCESS;
}
EMIT_MOV(compiler, TMP_REGISTER, 0, src, srcw);
- code = emit_x86_instruction(compiler, 1, 0, 0, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code++ = 0xf7;
- *code |= 0x2 << 3;
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code = 0x0b;
+ inst = emit_x86_instruction(compiler, 1, 0, 0, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_F7;
+ *inst |= NOT_rm;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst = OR_r_rm;
EMIT_MOV(compiler, dst, dstw, TMP_REGISTER, 0);
return SLJIT_SUCCESS;
}
-static int emit_clz(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+static sljit_si emit_clz(struct sljit_compiler *compiler, sljit_si op_flags,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- sljit_ub* code;
- int dst_r;
+ sljit_ub* inst;
+ sljit_si dst_r;
- SLJIT_UNUSED_ARG(op);
+ SLJIT_UNUSED_ARG(op_flags);
if (SLJIT_UNLIKELY(dst == SLJIT_UNUSED)) {
/* Just set the zero flag. */
EMIT_MOV(compiler, TMP_REGISTER, 0, src, srcw);
- code = emit_x86_instruction(compiler, 1, 0, 0, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code++ = 0xf7;
- *code |= 0x2 << 3;
+ inst = emit_x86_instruction(compiler, 1, 0, 0, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_F7;
+ *inst |= NOT_rm;
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- code = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_IMM, 31, TMP_REGISTER, 0);
+ inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_IMM, 31, TMP_REGISTER, 0);
#else
- code = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_IMM, !(op & SLJIT_INT_OP) ? 63 : 31, TMP_REGISTER, 0);
+ inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_IMM, !(op_flags & SLJIT_INT_OP) ? 63 : 31, TMP_REGISTER, 0);
#endif
- FAIL_IF(!code);
- *code |= 0x5 << 3;
+ FAIL_IF(!inst);
+ *inst |= SHR;
return SLJIT_SUCCESS;
}
if (SLJIT_UNLIKELY(src & SLJIT_IMM)) {
- EMIT_MOV(compiler, TMP_REGISTER, 0, src, srcw);
+ EMIT_MOV(compiler, TMP_REGISTER, 0, SLJIT_IMM, srcw);
src = TMP_REGISTER;
srcw = 0;
}
- code = emit_x86_instruction(compiler, 2, TMP_REGISTER, 0, src, srcw);
- FAIL_IF(!code);
- *code++ = 0x0f;
- *code = 0xbd;
+ inst = emit_x86_instruction(compiler, 2, TMP_REGISTER, 0, src, srcw);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_0F;
+ *inst = BSR_r_rm;
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= TMP_REGISTER)
+ if (dst <= TMP_REGISTER)
dst_r = dst;
else {
/* Find an unused temporary register. */
- if ((dst & 0xf) != SLJIT_TEMPORARY_REG1 && (dst & 0xf0) != (SLJIT_TEMPORARY_REG1 << 4))
- dst_r = SLJIT_TEMPORARY_REG1;
- else if ((dst & 0xf) != SLJIT_TEMPORARY_REG2 && (dst & 0xf0) != (SLJIT_TEMPORARY_REG2 << 4))
- dst_r = SLJIT_TEMPORARY_REG2;
+ if ((dst & 0xf) != SLJIT_SCRATCH_REG1 && (dst & 0xf0) != (SLJIT_SCRATCH_REG1 << 4))
+ dst_r = SLJIT_SCRATCH_REG1;
+ else if ((dst & 0xf) != SLJIT_SCRATCH_REG2 && (dst & 0xf0) != (SLJIT_SCRATCH_REG2 << 4))
+ dst_r = SLJIT_SCRATCH_REG2;
else
- dst_r = SLJIT_TEMPORARY_REG3;
+ dst_r = SLJIT_SCRATCH_REG3;
EMIT_MOV(compiler, dst, dstw, dst_r, 0);
}
EMIT_MOV(compiler, dst_r, 0, SLJIT_IMM, 32 + 31);
#else
- dst_r = (dst >= SLJIT_TEMPORARY_REG1 && dst <= TMP_REGISTER) ? dst : TMP_REG2;
+ dst_r = (dst <= TMP_REGISTER) ? dst : TMP_REG2;
compiler->mode32 = 0;
- EMIT_MOV(compiler, dst_r, 0, SLJIT_IMM, !(op & SLJIT_INT_OP) ? 64 + 63 : 32 + 31);
- compiler->mode32 = op & SLJIT_INT_OP;
+ EMIT_MOV(compiler, dst_r, 0, SLJIT_IMM, !(op_flags & SLJIT_INT_OP) ? 64 + 63 : 32 + 31);
+ compiler->mode32 = op_flags & SLJIT_INT_OP;
#endif
- code = emit_x86_instruction(compiler, 2, dst_r, 0, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code++ = 0x0f;
- *code = 0x45;
+ if (cpu_has_cmov == -1)
+ get_cpu_features();
+
+ if (cpu_has_cmov) {
+ inst = emit_x86_instruction(compiler, 2, dst_r, 0, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_0F;
+ *inst = CMOVNE_r_rm;
+ } else {
+#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 4);
+ FAIL_IF(!inst);
+ INC_SIZE(4);
+
+ *inst++ = JE_i8;
+ *inst++ = 2;
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (reg_map[dst_r] << 3) | reg_map[TMP_REGISTER];
+#else
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 5);
+ FAIL_IF(!inst);
+ INC_SIZE(5);
+
+ *inst++ = JE_i8;
+ *inst++ = 3;
+ *inst++ = REX_W | (reg_map[dst_r] >= 8 ? REX_R : 0) | (reg_map[TMP_REGISTER] >= 8 ? REX_B : 0);
+ *inst++ = MOV_r_rm;
+ *inst++ = MOD_REG | (reg_lmap[dst_r] << 3) | reg_lmap[TMP_REGISTER];
+#endif
+ }
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- code = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, 31, dst_r, 0);
+ inst = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, 31, dst_r, 0);
#else
- code = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, !(op & SLJIT_INT_OP) ? 63 : 31, dst_r, 0);
+ inst = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, !(op_flags & SLJIT_INT_OP) ? 63 : 31, dst_r, 0);
#endif
- FAIL_IF(!code);
- *(code + 1) |= 0x6 << 3;
+ FAIL_IF(!inst);
+ *(inst + 1) |= XOR;
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
if (dst & SLJIT_MEM) {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, dst, dstw);
- FAIL_IF(!code);
- *code = 0x87;
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = XCHG_r_rm;
}
#else
if (dst & SLJIT_MEM)
@@ -1035,60 +1258,80 @@ static int emit_clz(struct sljit_compiler *compiler, int op,
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- sljit_ub* code;
- int update = 0;
+ sljit_ub* inst;
+ sljit_si update = 0;
+ sljit_si op_flags = GET_ALL_FLAGS(op);
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- int dst_is_ereg = 0;
- int src_is_ereg = 0;
+ sljit_si dst_is_ereg = 0;
+ sljit_si src_is_ereg = 0;
#else
- #define src_is_ereg 0
+# define src_is_ereg 0
#endif
CHECK_ERROR();
check_sljit_emit_op1(compiler, op, dst, dstw, src, srcw);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
-#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- compiler->mode32 = op & SLJIT_INT_OP;
-#endif
CHECK_EXTRA_REGS(dst, dstw, dst_is_ereg = 1);
CHECK_EXTRA_REGS(src, srcw, src_is_ereg = 1);
+#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
+ compiler->mode32 = op_flags & SLJIT_INT_OP;
+#endif
- if (GET_OPCODE(op) >= SLJIT_MOV && GET_OPCODE(op) <= SLJIT_MOVU_SI) {
- op = GET_OPCODE(op);
+ op = GET_OPCODE(op);
+ if (op >= SLJIT_MOV && op <= SLJIT_MOVU_P) {
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
compiler->mode32 = 0;
#endif
- SLJIT_COMPILE_ASSERT(SLJIT_MOV + 7 == SLJIT_MOVU, movu_offset);
+ if (op_flags & SLJIT_INT_OP) {
+ if (src <= TMP_REGISTER && src == dst) {
+ if (!TYPE_CAST_NEEDED(op))
+ return SLJIT_SUCCESS;
+ }
+#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
+ if (op == SLJIT_MOV_SI && (src & SLJIT_MEM))
+ op = SLJIT_MOV_UI;
+ if (op == SLJIT_MOVU_SI && (src & SLJIT_MEM))
+ op = SLJIT_MOVU_UI;
+ if (op == SLJIT_MOV_UI && (src & SLJIT_IMM))
+ op = SLJIT_MOV_SI;
+ if (op == SLJIT_MOVU_UI && (src & SLJIT_IMM))
+ op = SLJIT_MOVU_SI;
+#endif
+ }
+
+ SLJIT_COMPILE_ASSERT(SLJIT_MOV + 8 == SLJIT_MOVU, movu_offset);
if (op >= SLJIT_MOVU) {
update = 1;
- op -= 7;
+ op -= 8;
}
if (src & SLJIT_IMM) {
switch (op) {
case SLJIT_MOV_UB:
- srcw = (unsigned char)srcw;
+ srcw = (sljit_ub)srcw;
break;
case SLJIT_MOV_SB:
- srcw = (signed char)srcw;
+ srcw = (sljit_sb)srcw;
break;
case SLJIT_MOV_UH:
- srcw = (unsigned short)srcw;
+ srcw = (sljit_uh)srcw;
break;
case SLJIT_MOV_SH:
- srcw = (signed short)srcw;
+ srcw = (sljit_sh)srcw;
break;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
case SLJIT_MOV_UI:
- srcw = (unsigned int)srcw;
+ srcw = (sljit_ui)srcw;
break;
case SLJIT_MOV_SI:
- srcw = (signed int)srcw;
+ srcw = (sljit_si)srcw;
break;
#endif
}
@@ -1099,15 +1342,15 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int
}
if (SLJIT_UNLIKELY(update) && (src & SLJIT_MEM) && !src_is_ereg && (src & 0xf) && (srcw != 0 || (src & 0xf0) != 0)) {
- code = emit_x86_instruction(compiler, 1, src & 0xf, 0, src, srcw);
- FAIL_IF(!code);
- *code = 0x8d;
+ inst = emit_x86_instruction(compiler, 1, src & 0xf, 0, src, srcw);
+ FAIL_IF(!inst);
+ *inst = LEA_r_m;
src &= SLJIT_MEM | 0xf;
srcw = 0;
}
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- if (SLJIT_UNLIKELY(dst_is_ereg) && (!(op == SLJIT_MOV || op == SLJIT_MOV_UI || op == SLJIT_MOV_SI) || (src & SLJIT_MEM))) {
+ if (SLJIT_UNLIKELY(dst_is_ereg) && (!(op == SLJIT_MOV || op == SLJIT_MOV_UI || op == SLJIT_MOV_SI || op == SLJIT_MOV_P) || (src & SLJIT_MEM))) {
SLJIT_ASSERT(dst == SLJIT_MEM1(SLJIT_LOCALS_REG));
dst = TMP_REGISTER;
}
@@ -1115,6 +1358,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int
switch (op) {
case SLJIT_MOV:
+ case SLJIT_MOV_P:
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
case SLJIT_MOV_UI:
case SLJIT_MOV_SI:
@@ -1122,23 +1366,23 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int
FAIL_IF(emit_mov(compiler, dst, dstw, src, srcw));
break;
case SLJIT_MOV_UB:
- FAIL_IF(emit_mov_byte(compiler, 0, dst, dstw, src, (src & SLJIT_IMM) ? (unsigned char)srcw : srcw));
+ FAIL_IF(emit_mov_byte(compiler, 0, dst, dstw, src, srcw));
break;
case SLJIT_MOV_SB:
- FAIL_IF(emit_mov_byte(compiler, 1, dst, dstw, src, (src & SLJIT_IMM) ? (signed char)srcw : srcw));
+ FAIL_IF(emit_mov_byte(compiler, 1, dst, dstw, src, srcw));
break;
case SLJIT_MOV_UH:
- FAIL_IF(emit_mov_half(compiler, 0, dst, dstw, src, (src & SLJIT_IMM) ? (unsigned short)srcw : srcw));
+ FAIL_IF(emit_mov_half(compiler, 0, dst, dstw, src, srcw));
break;
case SLJIT_MOV_SH:
- FAIL_IF(emit_mov_half(compiler, 1, dst, dstw, src, (src & SLJIT_IMM) ? (signed short)srcw : srcw));
+ FAIL_IF(emit_mov_half(compiler, 1, dst, dstw, src, srcw));
break;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
case SLJIT_MOV_UI:
- FAIL_IF(emit_mov_int(compiler, 0, dst, dstw, src, (src & SLJIT_IMM) ? (unsigned int)srcw : srcw));
+ FAIL_IF(emit_mov_int(compiler, 0, dst, dstw, src, srcw));
break;
case SLJIT_MOV_SI:
- FAIL_IF(emit_mov_int(compiler, 1, dst, dstw, src, (src & SLJIT_IMM) ? (signed int)srcw : srcw));
+ FAIL_IF(emit_mov_int(compiler, 1, dst, dstw, src, srcw));
break;
#endif
}
@@ -1149,77 +1393,77 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op1(struct sljit_compiler *compiler, int
#endif
if (SLJIT_UNLIKELY(update) && (dst & SLJIT_MEM) && (dst & 0xf) && (dstw != 0 || (dst & 0xf0) != 0)) {
- code = emit_x86_instruction(compiler, 1, dst & 0xf, 0, dst, dstw);
- FAIL_IF(!code);
- *code = 0x8d;
+ inst = emit_x86_instruction(compiler, 1, dst & 0xf, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = LEA_r_m;
}
return SLJIT_SUCCESS;
}
- if (SLJIT_UNLIKELY(GET_FLAGS(op)))
+ if (SLJIT_UNLIKELY(GET_FLAGS(op_flags)))
compiler->flags_saved = 0;
- switch (GET_OPCODE(op)) {
+ switch (op) {
case SLJIT_NOT:
- if (SLJIT_UNLIKELY(op & SLJIT_SET_E))
+ if (SLJIT_UNLIKELY(op_flags & SLJIT_SET_E))
return emit_not_with_flags(compiler, dst, dstw, src, srcw);
- return emit_unary(compiler, 0x2, dst, dstw, src, srcw);
+ return emit_unary(compiler, NOT_rm, dst, dstw, src, srcw);
case SLJIT_NEG:
- if (SLJIT_UNLIKELY(op & SLJIT_KEEP_FLAGS) && !compiler->flags_saved)
+ if (SLJIT_UNLIKELY(op_flags & SLJIT_KEEP_FLAGS) && !compiler->flags_saved)
FAIL_IF(emit_save_flags(compiler));
- return emit_unary(compiler, 0x3, dst, dstw, src, srcw);
+ return emit_unary(compiler, NEG_rm, dst, dstw, src, srcw);
case SLJIT_CLZ:
- if (SLJIT_UNLIKELY(op & SLJIT_KEEP_FLAGS) && !compiler->flags_saved)
+ if (SLJIT_UNLIKELY(op_flags & SLJIT_KEEP_FLAGS) && !compiler->flags_saved)
FAIL_IF(emit_save_flags(compiler));
- return emit_clz(compiler, op, dst, dstw, src, srcw);
+ return emit_clz(compiler, op_flags, dst, dstw, src, srcw);
}
return SLJIT_SUCCESS;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- #undef src_is_ereg
+# undef src_is_ereg
#endif
}
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
-#define BINARY_IMM(_op_imm_, _op_mr_, immw, arg, argw) \
+#define BINARY_IMM(op_imm, op_mr, immw, arg, argw) \
if (IS_HALFWORD(immw) || compiler->mode32) { \
- code = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, immw, arg, argw); \
- FAIL_IF(!code); \
- *(code + 1) |= (_op_imm_); \
+ inst = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, immw, arg, argw); \
+ FAIL_IF(!inst); \
+ *(inst + 1) |= (op_imm); \
} \
else { \
FAIL_IF(emit_load_imm64(compiler, TMP_REG2, immw)); \
- code = emit_x86_instruction(compiler, 1, TMP_REG2, 0, arg, argw); \
- FAIL_IF(!code); \
- *code = (_op_mr_); \
+ inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, arg, argw); \
+ FAIL_IF(!inst); \
+ *inst = (op_mr); \
}
-#define BINARY_EAX_IMM(_op_eax_imm_, immw) \
- FAIL_IF(emit_do_imm32(compiler, (!compiler->mode32) ? REX_W : 0, (_op_eax_imm_), immw))
+#define BINARY_EAX_IMM(op_eax_imm, immw) \
+ FAIL_IF(emit_do_imm32(compiler, (!compiler->mode32) ? REX_W : 0, (op_eax_imm), immw))
#else
-#define BINARY_IMM(_op_imm_, _op_mr_, immw, arg, argw) \
- code = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, immw, arg, argw); \
- FAIL_IF(!code); \
- *(code + 1) |= (_op_imm_);
+#define BINARY_IMM(op_imm, op_mr, immw, arg, argw) \
+ inst = emit_x86_instruction(compiler, 1 | EX86_BIN_INS, SLJIT_IMM, immw, arg, argw); \
+ FAIL_IF(!inst); \
+ *(inst + 1) |= (op_imm);
-#define BINARY_EAX_IMM(_op_eax_imm_, immw) \
- FAIL_IF(emit_do_imm(compiler, (_op_eax_imm_), immw))
+#define BINARY_EAX_IMM(op_eax_imm, immw) \
+ FAIL_IF(emit_do_imm(compiler, (op_eax_imm), immw))
#endif
-static int emit_cum_binary(struct sljit_compiler *compiler,
+static sljit_si emit_cum_binary(struct sljit_compiler *compiler,
sljit_ub op_rm, sljit_ub op_mr, sljit_ub op_imm, sljit_ub op_eax_imm,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- sljit_ub* code;
+ sljit_ub* inst;
if (dst == SLJIT_UNUSED) {
EMIT_MOV(compiler, TMP_REGISTER, 0, src1, src1w);
@@ -1227,9 +1471,9 @@ static int emit_cum_binary(struct sljit_compiler *compiler,
BINARY_IMM(op_imm, op_mr, src2w, TMP_REGISTER, 0);
}
else {
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src2, src2w);
- FAIL_IF(!code);
- *code = op_rm;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = op_rm;
}
return SLJIT_SUCCESS;
}
@@ -1237,9 +1481,9 @@ static int emit_cum_binary(struct sljit_compiler *compiler,
if (dst == src1 && dstw == src1w) {
if (src2 & SLJIT_IMM) {
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- if ((dst == SLJIT_TEMPORARY_REG1) && (src2w > 127 || src2w < -128) && (compiler->mode32 || IS_HALFWORD(src2w))) {
+ if ((dst == SLJIT_SCRATCH_REG1) && (src2w > 127 || src2w < -128) && (compiler->mode32 || IS_HALFWORD(src2w))) {
#else
- if ((dst == SLJIT_TEMPORARY_REG1) && (src2w > 127 || src2w < -128)) {
+ if ((dst == SLJIT_SCRATCH_REG1) && (src2w > 127 || src2w < -128)) {
#endif
BINARY_EAX_IMM(op_eax_imm, src2w);
}
@@ -1247,22 +1491,22 @@ static int emit_cum_binary(struct sljit_compiler *compiler,
BINARY_IMM(op_imm, op_mr, src2w, dst, dstw);
}
}
- else if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) {
- code = emit_x86_instruction(compiler, 1, dst, dstw, src2, src2w);
- FAIL_IF(!code);
- *code = op_rm;
+ else if (dst <= TMP_REGISTER) {
+ inst = emit_x86_instruction(compiler, 1, dst, dstw, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = op_rm;
}
- else if (src2 >= SLJIT_TEMPORARY_REG1 && src2 <= TMP_REGISTER) {
- /* Special exception for sljit_emit_cond_value. */
- code = emit_x86_instruction(compiler, 1, src2, src2w, dst, dstw);
- FAIL_IF(!code);
- *code = op_mr;
+ else if (src2 <= TMP_REGISTER) {
+ /* Special exception for sljit_emit_op_flags. */
+ inst = emit_x86_instruction(compiler, 1, src2, src2w, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = op_mr;
}
else {
EMIT_MOV(compiler, TMP_REGISTER, 0, src2, src2w);
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, dst, dstw);
- FAIL_IF(!code);
- *code = op_mr;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = op_mr;
}
return SLJIT_SUCCESS;
}
@@ -1271,9 +1515,9 @@ static int emit_cum_binary(struct sljit_compiler *compiler,
if (dst == src2 && dstw == src2w) {
if (src1 & SLJIT_IMM) {
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- if ((dst == SLJIT_TEMPORARY_REG1) && (src1w > 127 || src1w < -128) && (compiler->mode32 || IS_HALFWORD(src1w))) {
+ if ((dst == SLJIT_SCRATCH_REG1) && (src1w > 127 || src1w < -128) && (compiler->mode32 || IS_HALFWORD(src1w))) {
#else
- if ((dst == SLJIT_TEMPORARY_REG1) && (src1w > 127 || src1w < -128)) {
+ if ((dst == SLJIT_SCRATCH_REG1) && (src1w > 127 || src1w < -128)) {
#endif
BINARY_EAX_IMM(op_eax_imm, src1w);
}
@@ -1281,35 +1525,35 @@ static int emit_cum_binary(struct sljit_compiler *compiler,
BINARY_IMM(op_imm, op_mr, src1w, dst, dstw);
}
}
- else if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) {
- code = emit_x86_instruction(compiler, 1, dst, dstw, src1, src1w);
- FAIL_IF(!code);
- *code = op_rm;
+ else if (dst <= TMP_REGISTER) {
+ inst = emit_x86_instruction(compiler, 1, dst, dstw, src1, src1w);
+ FAIL_IF(!inst);
+ *inst = op_rm;
}
- else if (src1 >= SLJIT_TEMPORARY_REG1 && src1 <= SLJIT_NO_REGISTERS) {
- code = emit_x86_instruction(compiler, 1, src1, src1w, dst, dstw);
- FAIL_IF(!code);
- *code = op_mr;
+ else if (src1 <= TMP_REGISTER) {
+ inst = emit_x86_instruction(compiler, 1, src1, src1w, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = op_mr;
}
else {
EMIT_MOV(compiler, TMP_REGISTER, 0, src1, src1w);
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, dst, dstw);
- FAIL_IF(!code);
- *code = op_mr;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = op_mr;
}
return SLJIT_SUCCESS;
}
/* General version. */
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) {
+ if (dst <= TMP_REGISTER) {
EMIT_MOV(compiler, dst, 0, src1, src1w);
if (src2 & SLJIT_IMM) {
BINARY_IMM(op_imm, op_mr, src2w, dst, 0);
}
else {
- code = emit_x86_instruction(compiler, 1, dst, 0, src2, src2w);
- FAIL_IF(!code);
- *code = op_rm;
+ inst = emit_x86_instruction(compiler, 1, dst, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = op_rm;
}
}
else {
@@ -1319,9 +1563,9 @@ static int emit_cum_binary(struct sljit_compiler *compiler,
BINARY_IMM(op_imm, op_mr, src2w, TMP_REGISTER, 0);
}
else {
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src2, src2w);
- FAIL_IF(!code);
- *code = op_rm;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = op_rm;
}
EMIT_MOV(compiler, dst, dstw, TMP_REGISTER, 0);
}
@@ -1329,13 +1573,13 @@ static int emit_cum_binary(struct sljit_compiler *compiler,
return SLJIT_SUCCESS;
}
-static int emit_non_cum_binary(struct sljit_compiler *compiler,
+static sljit_si emit_non_cum_binary(struct sljit_compiler *compiler,
sljit_ub op_rm, sljit_ub op_mr, sljit_ub op_imm, sljit_ub op_eax_imm,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- sljit_ub* code;
+ sljit_ub* inst;
if (dst == SLJIT_UNUSED) {
EMIT_MOV(compiler, TMP_REGISTER, 0, src1, src1w);
@@ -1343,9 +1587,9 @@ static int emit_non_cum_binary(struct sljit_compiler *compiler,
BINARY_IMM(op_imm, op_mr, src2w, TMP_REGISTER, 0);
}
else {
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src2, src2w);
- FAIL_IF(!code);
- *code = op_rm;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = op_rm;
}
return SLJIT_SUCCESS;
}
@@ -1353,9 +1597,9 @@ static int emit_non_cum_binary(struct sljit_compiler *compiler,
if (dst == src1 && dstw == src1w) {
if (src2 & SLJIT_IMM) {
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- if ((dst == SLJIT_TEMPORARY_REG1) && (src2w > 127 || src2w < -128) && (compiler->mode32 || IS_HALFWORD(src2w))) {
+ if ((dst == SLJIT_SCRATCH_REG1) && (src2w > 127 || src2w < -128) && (compiler->mode32 || IS_HALFWORD(src2w))) {
#else
- if ((dst == SLJIT_TEMPORARY_REG1) && (src2w > 127 || src2w < -128)) {
+ if ((dst == SLJIT_SCRATCH_REG1) && (src2w > 127 || src2w < -128)) {
#endif
BINARY_EAX_IMM(op_eax_imm, src2w);
}
@@ -1363,35 +1607,35 @@ static int emit_non_cum_binary(struct sljit_compiler *compiler,
BINARY_IMM(op_imm, op_mr, src2w, dst, dstw);
}
}
- else if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) {
- code = emit_x86_instruction(compiler, 1, dst, dstw, src2, src2w);
- FAIL_IF(!code);
- *code = op_rm;
+ else if (dst <= TMP_REGISTER) {
+ inst = emit_x86_instruction(compiler, 1, dst, dstw, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = op_rm;
}
- else if (src2 >= SLJIT_TEMPORARY_REG1 && src2 <= SLJIT_NO_REGISTERS) {
- code = emit_x86_instruction(compiler, 1, src2, src2w, dst, dstw);
- FAIL_IF(!code);
- *code = op_mr;
+ else if (src2 <= TMP_REGISTER) {
+ inst = emit_x86_instruction(compiler, 1, src2, src2w, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = op_mr;
}
else {
EMIT_MOV(compiler, TMP_REGISTER, 0, src2, src2w);
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, dst, dstw);
- FAIL_IF(!code);
- *code = op_mr;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, dst, dstw);
+ FAIL_IF(!inst);
+ *inst = op_mr;
}
return SLJIT_SUCCESS;
}
/* General version. */
- if ((dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) && dst != src2) {
+ if (dst <= TMP_REGISTER && dst != src2) {
EMIT_MOV(compiler, dst, 0, src1, src1w);
if (src2 & SLJIT_IMM) {
BINARY_IMM(op_imm, op_mr, src2w, dst, 0);
}
else {
- code = emit_x86_instruction(compiler, 1, dst, 0, src2, src2w);
- FAIL_IF(!code);
- *code = op_rm;
+ inst = emit_x86_instruction(compiler, 1, dst, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = op_rm;
}
}
else {
@@ -1401,9 +1645,9 @@ static int emit_non_cum_binary(struct sljit_compiler *compiler,
BINARY_IMM(op_imm, op_mr, src2w, TMP_REGISTER, 0);
}
else {
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src2, src2w);
- FAIL_IF(!code);
- *code = op_rm;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = op_rm;
}
EMIT_MOV(compiler, dst, dstw, TMP_REGISTER, 0);
}
@@ -1411,28 +1655,28 @@ static int emit_non_cum_binary(struct sljit_compiler *compiler,
return SLJIT_SUCCESS;
}
-static int emit_mul(struct sljit_compiler *compiler,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+static sljit_si emit_mul(struct sljit_compiler *compiler,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- sljit_ub* code;
- int dst_r;
+ sljit_ub* inst;
+ sljit_si dst_r;
- dst_r = (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REGISTER;
+ dst_r = (dst <= TMP_REGISTER) ? dst : TMP_REGISTER;
/* Register destination. */
if (dst_r == src1 && !(src2 & SLJIT_IMM)) {
- code = emit_x86_instruction(compiler, 2, dst_r, 0, src2, src2w);
- FAIL_IF(!code);
- *code++ = 0x0f;
- *code = 0xaf;
+ inst = emit_x86_instruction(compiler, 2, dst_r, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_0F;
+ *inst = IMUL_r_rm;
}
else if (dst_r == src2 && !(src1 & SLJIT_IMM)) {
- code = emit_x86_instruction(compiler, 2, dst_r, 0, src1, src1w);
- FAIL_IF(!code);
- *code++ = 0x0f;
- *code = 0xaf;
+ inst = emit_x86_instruction(compiler, 2, dst_r, 0, src1, src1w);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_0F;
+ *inst = IMUL_r_rm;
}
else if (src1 & SLJIT_IMM) {
if (src2 & SLJIT_IMM) {
@@ -1442,42 +1686,42 @@ static int emit_mul(struct sljit_compiler *compiler,
}
if (src1w <= 127 && src1w >= -128) {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, src2, src2w);
- FAIL_IF(!code);
- *code = 0x6b;
- code = (sljit_ub*)ensure_buf(compiler, 1 + 1);
- FAIL_IF(!code);
- INC_CSIZE(1);
- *code = (sljit_b)src1w;
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = IMUL_r_rm_i8;
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1);
+ FAIL_IF(!inst);
+ INC_SIZE(1);
+ *inst = (sljit_sb)src1w;
}
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
else {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, src2, src2w);
- FAIL_IF(!code);
- *code = 0x69;
- code = (sljit_ub*)ensure_buf(compiler, 1 + 4);
- FAIL_IF(!code);
- INC_CSIZE(4);
- *(sljit_w*)code = src1w;
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = IMUL_r_rm_i32;
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 4);
+ FAIL_IF(!inst);
+ INC_SIZE(4);
+ *(sljit_sw*)inst = src1w;
}
#else
else if (IS_HALFWORD(src1w)) {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, src2, src2w);
- FAIL_IF(!code);
- *code = 0x69;
- code = (sljit_ub*)ensure_buf(compiler, 1 + 4);
- FAIL_IF(!code);
- INC_CSIZE(4);
- *(sljit_hw*)code = (sljit_hw)src1w;
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = IMUL_r_rm_i32;
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 4);
+ FAIL_IF(!inst);
+ INC_SIZE(4);
+ *(sljit_si*)inst = (sljit_si)src1w;
}
else {
EMIT_MOV(compiler, TMP_REG2, 0, SLJIT_IMM, src1w);
if (dst_r != src2)
EMIT_MOV(compiler, dst_r, 0, src2, src2w);
- code = emit_x86_instruction(compiler, 2, dst_r, 0, TMP_REG2, 0);
- FAIL_IF(!code);
- *code++ = 0x0f;
- *code = 0xaf;
+ inst = emit_x86_instruction(compiler, 2, dst_r, 0, TMP_REG2, 0);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_0F;
+ *inst = IMUL_r_rm;
}
#endif
}
@@ -1485,42 +1729,42 @@ static int emit_mul(struct sljit_compiler *compiler,
/* Note: src1 is NOT immediate. */
if (src2w <= 127 && src2w >= -128) {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, src1, src1w);
- FAIL_IF(!code);
- *code = 0x6b;
- code = (sljit_ub*)ensure_buf(compiler, 1 + 1);
- FAIL_IF(!code);
- INC_CSIZE(1);
- *code = (sljit_b)src2w;
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, src1, src1w);
+ FAIL_IF(!inst);
+ *inst = IMUL_r_rm_i8;
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1);
+ FAIL_IF(!inst);
+ INC_SIZE(1);
+ *inst = (sljit_sb)src2w;
}
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
else {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, src1, src1w);
- FAIL_IF(!code);
- *code = 0x69;
- code = (sljit_ub*)ensure_buf(compiler, 1 + 4);
- FAIL_IF(!code);
- INC_CSIZE(4);
- *(sljit_w*)code = src2w;
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, src1, src1w);
+ FAIL_IF(!inst);
+ *inst = IMUL_r_rm_i32;
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 4);
+ FAIL_IF(!inst);
+ INC_SIZE(4);
+ *(sljit_sw*)inst = src2w;
}
#else
else if (IS_HALFWORD(src2w)) {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, src1, src1w);
- FAIL_IF(!code);
- *code = 0x69;
- code = (sljit_ub*)ensure_buf(compiler, 1 + 4);
- FAIL_IF(!code);
- INC_CSIZE(4);
- *(sljit_hw*)code = (sljit_hw)src2w;
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, src1, src1w);
+ FAIL_IF(!inst);
+ *inst = IMUL_r_rm_i32;
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 4);
+ FAIL_IF(!inst);
+ INC_SIZE(4);
+ *(sljit_si*)inst = (sljit_si)src2w;
}
else {
EMIT_MOV(compiler, TMP_REG2, 0, SLJIT_IMM, src1w);
if (dst_r != src1)
EMIT_MOV(compiler, dst_r, 0, src1, src1w);
- code = emit_x86_instruction(compiler, 2, dst_r, 0, TMP_REG2, 0);
- FAIL_IF(!code);
- *code++ = 0x0f;
- *code = 0xaf;
+ inst = emit_x86_instruction(compiler, 2, dst_r, 0, TMP_REG2, 0);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_0F;
+ *inst = IMUL_r_rm;
}
#endif
}
@@ -1529,10 +1773,10 @@ static int emit_mul(struct sljit_compiler *compiler,
if (ADDRESSING_DEPENDS_ON(src2, dst_r))
dst_r = TMP_REGISTER;
EMIT_MOV(compiler, dst_r, 0, src1, src1w);
- code = emit_x86_instruction(compiler, 2, dst_r, 0, src2, src2w);
- FAIL_IF(!code);
- *code++ = 0x0f;
- *code = 0xaf;
+ inst = emit_x86_instruction(compiler, 2, dst_r, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_0F;
+ *inst = IMUL_r_rm;
}
if (dst_r == TMP_REGISTER)
@@ -1541,13 +1785,13 @@ static int emit_mul(struct sljit_compiler *compiler,
return SLJIT_SUCCESS;
}
-static int emit_lea_binary(struct sljit_compiler *compiler,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+static sljit_si emit_lea_binary(struct sljit_compiler *compiler,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- sljit_ub* code;
- int dst_r, done = 0;
+ sljit_ub* inst;
+ sljit_si dst_r, done = 0;
/* These cases better be left to handled by normal way. */
if (dst == src1 && dstw == src1w)
@@ -1555,40 +1799,37 @@ static int emit_lea_binary(struct sljit_compiler *compiler,
if (dst == src2 && dstw == src2w)
return SLJIT_ERR_UNSUPPORTED;
- dst_r = (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REGISTER;
+ dst_r = (dst <= TMP_REGISTER) ? dst : TMP_REGISTER;
- if (src1 >= SLJIT_TEMPORARY_REG1 && src1 <= SLJIT_NO_REGISTERS) {
- if (src2 >= SLJIT_TEMPORARY_REG1 && src2 <= SLJIT_NO_REGISTERS) {
- /* It is not possible to be both SLJIT_LOCALS_REG. */
- if (src1 != SLJIT_LOCALS_REG || src2 != SLJIT_LOCALS_REG) {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM2(src1, src2), 0);
- FAIL_IF(!code);
- *code = 0x8d;
- done = 1;
- }
+ if (src1 <= TMP_REGISTER) {
+ if (src2 <= TMP_REGISTER || src2 == TMP_REGISTER) {
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM2(src1, src2), 0);
+ FAIL_IF(!inst);
+ *inst = LEA_r_m;
+ done = 1;
}
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
if ((src2 & SLJIT_IMM) && (compiler->mode32 || IS_HALFWORD(src2w))) {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM1(src1), (int)src2w);
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM1(src1), (sljit_si)src2w);
#else
if (src2 & SLJIT_IMM) {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM1(src1), src2w);
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM1(src1), src2w);
#endif
- FAIL_IF(!code);
- *code = 0x8d;
+ FAIL_IF(!inst);
+ *inst = LEA_r_m;
done = 1;
}
}
- else if (src2 >= SLJIT_TEMPORARY_REG1 && src2 <= SLJIT_NO_REGISTERS) {
+ else if (src2 <= TMP_REGISTER) {
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
if ((src1 & SLJIT_IMM) && (compiler->mode32 || IS_HALFWORD(src1w))) {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM1(src2), (int)src1w);
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM1(src2), (sljit_si)src1w);
#else
if (src1 & SLJIT_IMM) {
- code = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM1(src2), src1w);
+ inst = emit_x86_instruction(compiler, 1, dst_r, 0, SLJIT_MEM1(src2), src1w);
#endif
- FAIL_IF(!code);
- *code = 0x8d;
+ FAIL_IF(!inst);
+ *inst = LEA_r_m;
done = 1;
}
}
@@ -1601,37 +1842,37 @@ static int emit_lea_binary(struct sljit_compiler *compiler,
return SLJIT_ERR_UNSUPPORTED;
}
-static int emit_cmp_binary(struct sljit_compiler *compiler,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+static sljit_si emit_cmp_binary(struct sljit_compiler *compiler,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- sljit_ub* code;
+ sljit_ub* inst;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- if (src1 == SLJIT_TEMPORARY_REG1 && (src2 & SLJIT_IMM) && (src2w > 127 || src2w < -128) && (compiler->mode32 || IS_HALFWORD(src2w))) {
+ if (src1 == SLJIT_SCRATCH_REG1 && (src2 & SLJIT_IMM) && (src2w > 127 || src2w < -128) && (compiler->mode32 || IS_HALFWORD(src2w))) {
#else
- if (src1 == SLJIT_TEMPORARY_REG1 && (src2 & SLJIT_IMM) && (src2w > 127 || src2w < -128)) {
+ if (src1 == SLJIT_SCRATCH_REG1 && (src2 & SLJIT_IMM) && (src2w > 127 || src2w < -128)) {
#endif
- BINARY_EAX_IMM(0x3d, src2w);
+ BINARY_EAX_IMM(CMP_EAX_i32, src2w);
return SLJIT_SUCCESS;
}
- if (src1 >= SLJIT_TEMPORARY_REG1 && src1 <= SLJIT_NO_REGISTERS) {
+ if (src1 <= TMP_REGISTER) {
if (src2 & SLJIT_IMM) {
- BINARY_IMM(0x7 << 3, 0x39, src2w, src1, 0);
+ BINARY_IMM(CMP, CMP_rm_r, src2w, src1, 0);
}
else {
- code = emit_x86_instruction(compiler, 1, src1, 0, src2, src2w);
- FAIL_IF(!code);
- *code = 0x3b;
+ inst = emit_x86_instruction(compiler, 1, src1, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = CMP_r_rm;
}
return SLJIT_SUCCESS;
}
- if (src2 >= SLJIT_TEMPORARY_REG1 && src2 <= SLJIT_NO_REGISTERS && !(src1 & SLJIT_IMM)) {
- code = emit_x86_instruction(compiler, 1, src2, 0, src1, src1w);
- FAIL_IF(!code);
- *code = 0x39;
+ if (src2 <= TMP_REGISTER && !(src1 & SLJIT_IMM)) {
+ inst = emit_x86_instruction(compiler, 1, src2, 0, src1, src1w);
+ FAIL_IF(!inst);
+ *inst = CMP_rm_r;
return SLJIT_SUCCESS;
}
@@ -1641,93 +1882,93 @@ static int emit_cmp_binary(struct sljit_compiler *compiler,
src1 = TMP_REGISTER;
src1w = 0;
}
- BINARY_IMM(0x7 << 3, 0x39, src2w, src1, src1w);
+ BINARY_IMM(CMP, CMP_rm_r, src2w, src1, src1w);
}
else {
EMIT_MOV(compiler, TMP_REGISTER, 0, src1, src1w);
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src2, src2w);
- FAIL_IF(!code);
- *code = 0x3b;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = CMP_r_rm;
}
return SLJIT_SUCCESS;
}
-static int emit_test_binary(struct sljit_compiler *compiler,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+static sljit_si emit_test_binary(struct sljit_compiler *compiler,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- sljit_ub* code;
+ sljit_ub* inst;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- if (src1 == SLJIT_TEMPORARY_REG1 && (src2 & SLJIT_IMM) && (src2w > 127 || src2w < -128) && (compiler->mode32 || IS_HALFWORD(src2w))) {
+ if (src1 == SLJIT_SCRATCH_REG1 && (src2 & SLJIT_IMM) && (src2w > 127 || src2w < -128) && (compiler->mode32 || IS_HALFWORD(src2w))) {
#else
- if (src1 == SLJIT_TEMPORARY_REG1 && (src2 & SLJIT_IMM) && (src2w > 127 || src2w < -128)) {
+ if (src1 == SLJIT_SCRATCH_REG1 && (src2 & SLJIT_IMM) && (src2w > 127 || src2w < -128)) {
#endif
- BINARY_EAX_IMM(0xa9, src2w);
+ BINARY_EAX_IMM(TEST_EAX_i32, src2w);
return SLJIT_SUCCESS;
}
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- if (src2 == SLJIT_TEMPORARY_REG1 && (src2 & SLJIT_IMM) && (src1w > 127 || src1w < -128) && (compiler->mode32 || IS_HALFWORD(src1w))) {
+ if (src2 == SLJIT_SCRATCH_REG1 && (src2 & SLJIT_IMM) && (src1w > 127 || src1w < -128) && (compiler->mode32 || IS_HALFWORD(src1w))) {
#else
- if (src2 == SLJIT_TEMPORARY_REG1 && (src1 & SLJIT_IMM) && (src1w > 127 || src1w < -128)) {
+ if (src2 == SLJIT_SCRATCH_REG1 && (src1 & SLJIT_IMM) && (src1w > 127 || src1w < -128)) {
#endif
- BINARY_EAX_IMM(0xa9, src1w);
+ BINARY_EAX_IMM(TEST_EAX_i32, src1w);
return SLJIT_SUCCESS;
}
- if (src1 >= SLJIT_TEMPORARY_REG1 && src1 <= SLJIT_NO_REGISTERS) {
+ if (src1 <= TMP_REGISTER) {
if (src2 & SLJIT_IMM) {
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
if (IS_HALFWORD(src2w) || compiler->mode32) {
- code = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, 0);
- FAIL_IF(!code);
- *code = 0xf7;
+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, 0);
+ FAIL_IF(!inst);
+ *inst = GROUP_F7;
}
else {
FAIL_IF(emit_load_imm64(compiler, TMP_REG2, src2w));
- code = emit_x86_instruction(compiler, 1, TMP_REG2, 0, src1, 0);
- FAIL_IF(!code);
- *code = 0x85;
+ inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, src1, 0);
+ FAIL_IF(!inst);
+ *inst = TEST_rm_r;
}
#else
- code = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, 0);
- FAIL_IF(!code);
- *code = 0xf7;
+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, src1, 0);
+ FAIL_IF(!inst);
+ *inst = GROUP_F7;
#endif
}
else {
- code = emit_x86_instruction(compiler, 1, src1, 0, src2, src2w);
- FAIL_IF(!code);
- *code = 0x85;
+ inst = emit_x86_instruction(compiler, 1, src1, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = TEST_rm_r;
}
return SLJIT_SUCCESS;
}
- if (src2 >= SLJIT_TEMPORARY_REG1 && src2 <= SLJIT_NO_REGISTERS) {
+ if (src2 <= TMP_REGISTER) {
if (src1 & SLJIT_IMM) {
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
if (IS_HALFWORD(src1w) || compiler->mode32) {
- code = emit_x86_instruction(compiler, 1, SLJIT_IMM, src1w, src2, 0);
- FAIL_IF(!code);
- *code = 0xf7;
+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src1w, src2, 0);
+ FAIL_IF(!inst);
+ *inst = GROUP_F7;
}
else {
FAIL_IF(emit_load_imm64(compiler, TMP_REG2, src1w));
- code = emit_x86_instruction(compiler, 1, TMP_REG2, 0, src2, 0);
- FAIL_IF(!code);
- *code = 0x85;
+ inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, src2, 0);
+ FAIL_IF(!inst);
+ *inst = TEST_rm_r;
}
#else
- code = emit_x86_instruction(compiler, 1, src1, src1w, src2, 0);
- FAIL_IF(!code);
- *code = 0xf7;
+ inst = emit_x86_instruction(compiler, 1, src1, src1w, src2, 0);
+ FAIL_IF(!inst);
+ *inst = GROUP_F7;
#endif
}
else {
- code = emit_x86_instruction(compiler, 1, src2, 0, src1, src1w);
- FAIL_IF(!code);
- *code = 0x85;
+ inst = emit_x86_instruction(compiler, 1, src2, 0, src1, src1w);
+ FAIL_IF(!inst);
+ *inst = TEST_rm_r;
}
return SLJIT_SUCCESS;
}
@@ -1736,72 +1977,72 @@ static int emit_test_binary(struct sljit_compiler *compiler,
if (src2 & SLJIT_IMM) {
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
if (IS_HALFWORD(src2w) || compiler->mode32) {
- code = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code = 0xf7;
+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst = GROUP_F7;
}
else {
FAIL_IF(emit_load_imm64(compiler, TMP_REG2, src2w));
- code = emit_x86_instruction(compiler, 1, TMP_REG2, 0, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code = 0x85;
+ inst = emit_x86_instruction(compiler, 1, TMP_REG2, 0, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst = TEST_rm_r;
}
#else
- code = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code = 0xf7;
+ inst = emit_x86_instruction(compiler, 1, SLJIT_IMM, src2w, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst = GROUP_F7;
#endif
}
else {
- code = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src2, src2w);
- FAIL_IF(!code);
- *code = 0x85;
+ inst = emit_x86_instruction(compiler, 1, TMP_REGISTER, 0, src2, src2w);
+ FAIL_IF(!inst);
+ *inst = TEST_rm_r;
}
return SLJIT_SUCCESS;
}
-static int emit_shift(struct sljit_compiler *compiler,
+static sljit_si emit_shift(struct sljit_compiler *compiler,
sljit_ub mode,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- sljit_ub* code;
+ sljit_ub* inst;
if ((src2 & SLJIT_IMM) || (src2 == SLJIT_PREF_SHIFT_REG)) {
if (dst == src1 && dstw == src1w) {
- code = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, dst, dstw);
- FAIL_IF(!code);
- *code |= mode;
+ inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, dst, dstw);
+ FAIL_IF(!inst);
+ *inst |= mode;
return SLJIT_SUCCESS;
}
if (dst == SLJIT_UNUSED) {
EMIT_MOV(compiler, TMP_REGISTER, 0, src1, src1w);
- code = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code |= mode;
+ inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst |= mode;
return SLJIT_SUCCESS;
}
if (dst == SLJIT_PREF_SHIFT_REG && src2 == SLJIT_PREF_SHIFT_REG) {
EMIT_MOV(compiler, TMP_REGISTER, 0, src1, src1w);
- code = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code |= mode;
+ inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst |= mode;
EMIT_MOV(compiler, SLJIT_PREF_SHIFT_REG, 0, TMP_REGISTER, 0);
return SLJIT_SUCCESS;
}
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) {
+ if (dst <= TMP_REGISTER) {
EMIT_MOV(compiler, dst, 0, src1, src1w);
- code = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, dst, 0);
- FAIL_IF(!code);
- *code |= mode;
+ inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, dst, 0);
+ FAIL_IF(!inst);
+ *inst |= mode;
return SLJIT_SUCCESS;
}
EMIT_MOV(compiler, TMP_REGISTER, 0, src1, src1w);
- code = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code |= mode;
+ inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, src2, src2w, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst |= mode;
EMIT_MOV(compiler, dst, dstw, TMP_REGISTER, 0);
return SLJIT_SUCCESS;
}
@@ -1809,19 +2050,19 @@ static int emit_shift(struct sljit_compiler *compiler,
if (dst == SLJIT_PREF_SHIFT_REG) {
EMIT_MOV(compiler, TMP_REGISTER, 0, src1, src1w);
EMIT_MOV(compiler, SLJIT_PREF_SHIFT_REG, 0, src2, src2w);
- code = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code |= mode;
+ inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst |= mode;
EMIT_MOV(compiler, SLJIT_PREF_SHIFT_REG, 0, TMP_REGISTER, 0);
}
- else if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS && dst != src2 && !ADDRESSING_DEPENDS_ON(src2, dst)) {
+ else if (dst <= TMP_REGISTER && dst != src2 && !ADDRESSING_DEPENDS_ON(src2, dst)) {
if (src1 != dst)
EMIT_MOV(compiler, dst, 0, src1, src1w);
EMIT_MOV(compiler, TMP_REGISTER, 0, SLJIT_PREF_SHIFT_REG, 0);
EMIT_MOV(compiler, SLJIT_PREF_SHIFT_REG, 0, src2, src2w);
- code = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, dst, 0);
- FAIL_IF(!code);
- *code |= mode;
+ inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, dst, 0);
+ FAIL_IF(!inst);
+ *inst |= mode;
EMIT_MOV(compiler, SLJIT_PREF_SHIFT_REG, 0, TMP_REGISTER, 0);
}
else {
@@ -1831,18 +2072,17 @@ static int emit_shift(struct sljit_compiler *compiler,
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
EMIT_MOV(compiler, TMP_REG2, 0, SLJIT_PREF_SHIFT_REG, 0);
#else
- /* [esp - 4] is reserved for eflags. */
- EMIT_MOV(compiler, SLJIT_MEM1(SLJIT_LOCALS_REG), -(int)(2 * sizeof(sljit_w)), SLJIT_PREF_SHIFT_REG, 0);
+ /* [esp+0] contains the flags. */
+ EMIT_MOV(compiler, SLJIT_MEM1(SLJIT_LOCALS_REG), sizeof(sljit_sw), SLJIT_PREF_SHIFT_REG, 0);
#endif
EMIT_MOV(compiler, SLJIT_PREF_SHIFT_REG, 0, src2, src2w);
- code = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, TMP_REGISTER, 0);
- FAIL_IF(!code);
- *code |= mode;
+ inst = emit_x86_instruction(compiler, 1 | EX86_SHIFT_INS, SLJIT_PREF_SHIFT_REG, 0, TMP_REGISTER, 0);
+ FAIL_IF(!inst);
+ *inst |= mode;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
EMIT_MOV(compiler, SLJIT_PREF_SHIFT_REG, 0, TMP_REG2, 0);
#else
- /* [esp - 4] is reserved for eflags. */
- EMIT_MOV(compiler, SLJIT_PREF_SHIFT_REG, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), -(int)(2 * sizeof(sljit_w)));
+ EMIT_MOV(compiler, SLJIT_PREF_SHIFT_REG, 0, SLJIT_MEM1(SLJIT_LOCALS_REG), sizeof(sljit_sw));
#endif
EMIT_MOV(compiler, dst, dstw, TMP_REGISTER, 0);
}
@@ -1850,11 +2090,11 @@ static int emit_shift(struct sljit_compiler *compiler,
return SLJIT_SUCCESS;
}
-static int emit_shift_with_flags(struct sljit_compiler *compiler,
- sljit_ub mode, int set_flags,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+static sljit_si emit_shift_with_flags(struct sljit_compiler *compiler,
+ sljit_ub mode, sljit_si set_flags,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
/* The CPU does not set flags if the shift count is 0. */
if (src2 & SLJIT_IMM) {
@@ -1868,37 +2108,40 @@ static int emit_shift_with_flags(struct sljit_compiler *compiler,
if (!set_flags)
return emit_mov(compiler, dst, dstw, src1, src1w);
/* OR dst, src, 0 */
- return emit_cum_binary(compiler, 0x0b, 0x09, 0x1 << 3, 0x0d,
+ return emit_cum_binary(compiler, OR_r_rm, OR_rm_r, OR, OR_EAX_i32,
dst, dstw, src1, src1w, SLJIT_IMM, 0);
}
if (!set_flags)
return emit_shift(compiler, mode, dst, dstw, src1, src1w, src2, src2w);
- if (!(dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS))
+ if (!(dst <= TMP_REGISTER))
FAIL_IF(emit_cmp_binary(compiler, src1, src1w, SLJIT_IMM, 0));
FAIL_IF(emit_shift(compiler,mode, dst, dstw, src1, src1w, src2, src2w));
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS)
+ if (dst <= TMP_REGISTER)
return emit_cmp_binary(compiler, dst, dstw, SLJIT_IMM, 0);
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
CHECK_ERROR();
check_sljit_emit_op2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
+ ADJUST_LOCAL_OFFSET(src1, src1w);
+ ADJUST_LOCAL_OFFSET(src2, src2w);
-#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- compiler->mode32 = op & SLJIT_INT_OP;
-#endif
CHECK_EXTRA_REGS(dst, dstw, (void)0);
CHECK_EXTRA_REGS(src1, src1w, (void)0);
CHECK_EXTRA_REGS(src2, src2w, (void)0);
+#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
+ compiler->mode32 = op & SLJIT_INT_OP;
+#endif
if (GET_OPCODE(op) >= SLJIT_MUL) {
if (SLJIT_UNLIKELY(GET_FLAGS(op)))
@@ -1912,12 +2155,12 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int
if (!GET_FLAGS(op)) {
if (emit_lea_binary(compiler, dst, dstw, src1, src1w, src2, src2w) != SLJIT_ERR_UNSUPPORTED)
return compiler->error;
- }
+ }
else
compiler->flags_saved = 0;
if (SLJIT_UNLIKELY(op & SLJIT_KEEP_FLAGS) && !compiler->flags_saved)
FAIL_IF(emit_save_flags(compiler));
- return emit_cum_binary(compiler, 0x03, 0x01, 0x0 << 3, 0x05,
+ return emit_cum_binary(compiler, ADD_r_rm, ADD_rm_r, ADD, ADD_EAX_i32,
dst, dstw, src1, src1w, src2, src2w);
case SLJIT_ADDC:
if (SLJIT_UNLIKELY(compiler->flags_saved)) /* C flag must be restored. */
@@ -1926,7 +2169,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int
FAIL_IF(emit_save_flags(compiler));
if (SLJIT_UNLIKELY(GET_FLAGS(op)))
compiler->flags_saved = 0;
- return emit_cum_binary(compiler, 0x13, 0x11, 0x2 << 3, 0x15,
+ return emit_cum_binary(compiler, ADC_r_rm, ADC_rm_r, ADC, ADC_EAX_i32,
dst, dstw, src1, src1w, src2, src2w);
case SLJIT_SUB:
if (!GET_FLAGS(op)) {
@@ -1939,7 +2182,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int
FAIL_IF(emit_save_flags(compiler));
if (dst == SLJIT_UNUSED)
return emit_cmp_binary(compiler, src1, src1w, src2, src2w);
- return emit_non_cum_binary(compiler, 0x2b, 0x29, 0x5 << 3, 0x2d,
+ return emit_non_cum_binary(compiler, SUB_r_rm, SUB_rm_r, SUB, SUB_EAX_i32,
dst, dstw, src1, src1w, src2, src2w);
case SLJIT_SUBC:
if (SLJIT_UNLIKELY(compiler->flags_saved)) /* C flag must be restored. */
@@ -1948,36 +2191,36 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op2(struct sljit_compiler *compiler, int
FAIL_IF(emit_save_flags(compiler));
if (SLJIT_UNLIKELY(GET_FLAGS(op)))
compiler->flags_saved = 0;
- return emit_non_cum_binary(compiler, 0x1b, 0x19, 0x3 << 3, 0x1d,
+ return emit_non_cum_binary(compiler, SBB_r_rm, SBB_rm_r, SBB, SBB_EAX_i32,
dst, dstw, src1, src1w, src2, src2w);
case SLJIT_MUL:
return emit_mul(compiler, dst, dstw, src1, src1w, src2, src2w);
case SLJIT_AND:
if (dst == SLJIT_UNUSED)
return emit_test_binary(compiler, src1, src1w, src2, src2w);
- return emit_cum_binary(compiler, 0x23, 0x21, 0x4 << 3, 0x25,
+ return emit_cum_binary(compiler, AND_r_rm, AND_rm_r, AND, AND_EAX_i32,
dst, dstw, src1, src1w, src2, src2w);
case SLJIT_OR:
- return emit_cum_binary(compiler, 0x0b, 0x09, 0x1 << 3, 0x0d,
+ return emit_cum_binary(compiler, OR_r_rm, OR_rm_r, OR, OR_EAX_i32,
dst, dstw, src1, src1w, src2, src2w);
case SLJIT_XOR:
- return emit_cum_binary(compiler, 0x33, 0x31, 0x6 << 3, 0x35,
+ return emit_cum_binary(compiler, XOR_r_rm, XOR_rm_r, XOR, XOR_EAX_i32,
dst, dstw, src1, src1w, src2, src2w);
case SLJIT_SHL:
- return emit_shift_with_flags(compiler, 0x4 << 3, GET_FLAGS(op),
+ return emit_shift_with_flags(compiler, SHL, GET_FLAGS(op),
dst, dstw, src1, src1w, src2, src2w);
case SLJIT_LSHR:
- return emit_shift_with_flags(compiler, 0x5 << 3, GET_FLAGS(op),
+ return emit_shift_with_flags(compiler, SHR, GET_FLAGS(op),
dst, dstw, src1, src1w, src2, src2w);
case SLJIT_ASHR:
- return emit_shift_with_flags(compiler, 0x7 << 3, GET_FLAGS(op),
+ return emit_shift_with_flags(compiler, SAR, GET_FLAGS(op),
dst, dstw, src1, src1w, src2, src2w);
}
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_get_register_index(int reg)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_register_index(sljit_si reg)
{
check_sljit_get_register_index(reg);
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
@@ -1988,19 +2231,19 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_get_register_index(int reg)
return reg_map[reg];
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compiler,
- void *instruction, int size)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_custom(struct sljit_compiler *compiler,
+ void *instruction, sljit_si size)
{
- sljit_ub *buf;
+ sljit_ub *inst;
CHECK_ERROR();
check_sljit_emit_op_custom(compiler, instruction, size);
SLJIT_ASSERT(size > 0 && size < 16);
- buf = (sljit_ub*)ensure_buf(compiler, 1 + size);
- FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + size);
+ FAIL_IF(!inst);
INC_SIZE(size);
- SLJIT_MEMMOVE(buf, instruction, size);
+ SLJIT_MEMMOVE(inst, instruction, size);
return SLJIT_SUCCESS;
}
@@ -2008,112 +2251,85 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_op_custom(struct sljit_compiler *compile
/* Floating point operators */
/* --------------------------------------------------------------------- */
-#if (defined SLJIT_SSE2_AUTO && SLJIT_SSE2_AUTO)
-static int sse2_available = 0;
-#endif
-
#if (defined SLJIT_SSE2 && SLJIT_SSE2)
/* Alignment + 2 * 16 bytes. */
-static sljit_i sse2_data[3 + 4 + 4];
-static sljit_i *sse2_buffer;
+static sljit_si sse2_data[3 + (4 + 4) * 2];
+static sljit_si *sse2_buffer;
-static void init_compiler()
+static void init_compiler(void)
{
-#if (defined SLJIT_SSE2_AUTO && SLJIT_SSE2_AUTO)
- int features = 0;
-#endif
-
- sse2_buffer = (sljit_i*)(((sljit_uw)sse2_data + 15) & ~0xf);
- sse2_buffer[0] = 0;
- sse2_buffer[1] = 0x80000000;
- sse2_buffer[4] = 0xffffffff;
- sse2_buffer[5] = 0x7fffffff;
-
-#if (defined SLJIT_SSE2_AUTO && SLJIT_SSE2_AUTO)
-#ifdef __GNUC__
- /* AT&T syntax. */
- asm (
- "pushl %%ebx\n"
- "movl $0x1, %%eax\n"
- "cpuid\n"
- "popl %%ebx\n"
- "movl %%edx, %0\n"
- : "=g" (features)
- :
- : "%eax", "%ecx", "%edx"
- );
-#elif defined(_MSC_VER) || defined(__BORLANDC__)
- /* Intel syntax. */
- __asm {
- mov eax, 1
- push ebx
- cpuid
- pop ebx
- mov features, edx
- }
-#else
- #error "SLJIT_SSE2_AUTO is not implemented for this C compiler"
-#endif
- sse2_available = (features >> 26) & 0x1;
-#endif
+ sse2_buffer = (sljit_si*)(((sljit_uw)sse2_data + 15) & ~0xf);
+ /* Single precision constants. */
+ sse2_buffer[0] = 0x80000000;
+ sse2_buffer[4] = 0x7fffffff;
+ /* Double precision constants. */
+ sse2_buffer[8] = 0;
+ sse2_buffer[9] = 0x80000000;
+ sse2_buffer[12] = 0xffffffff;
+ sse2_buffer[13] = 0x7fffffff;
}
#endif
-SLJIT_API_FUNC_ATTRIBUTE int sljit_is_fpu_available(void)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_is_fpu_available(void)
{
- /* Always available. */
+#if (defined SLJIT_SSE2 && SLJIT_SSE2)
+#if (defined SLJIT_DETECT_SSE2 && SLJIT_DETECT_SSE2)
+ if (cpu_has_sse2 == -1)
+ get_cpu_features();
+ return cpu_has_sse2;
+#else /* SLJIT_DETECT_SSE2 */
return 1;
+#endif /* SLJIT_DETECT_SSE2 */
+#else /* SLJIT_SSE2 */
+ return 0;
+#endif
}
#if (defined SLJIT_SSE2 && SLJIT_SSE2)
-static int emit_sse2(struct sljit_compiler *compiler, sljit_ub opcode,
- int xmm1, int xmm2, sljit_w xmm2w)
+static sljit_si emit_sse2(struct sljit_compiler *compiler, sljit_ub opcode,
+ sljit_si single, sljit_si xmm1, sljit_si xmm2, sljit_sw xmm2w)
{
- sljit_ub *buf;
+ sljit_ub *inst;
- buf = emit_x86_instruction(compiler, 2 | EX86_PREF_F2 | EX86_SSE2, xmm1, 0, xmm2, xmm2w);
- FAIL_IF(!buf);
- *buf++ = 0x0f;
- *buf = opcode;
+ inst = emit_x86_instruction(compiler, 2 | (single ? EX86_PREF_F3 : EX86_PREF_F2) | EX86_SSE2, xmm1, 0, xmm2, xmm2w);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_0F;
+ *inst = opcode;
return SLJIT_SUCCESS;
}
-static int emit_sse2_logic(struct sljit_compiler *compiler, sljit_ub opcode,
- int xmm1, int xmm2, sljit_w xmm2w)
+static sljit_si emit_sse2_logic(struct sljit_compiler *compiler, sljit_ub opcode,
+ sljit_si pref66, sljit_si xmm1, sljit_si xmm2, sljit_sw xmm2w)
{
- sljit_ub *buf;
+ sljit_ub *inst;
- buf = emit_x86_instruction(compiler, 2 | EX86_PREF_66 | EX86_SSE2, xmm1, 0, xmm2, xmm2w);
- FAIL_IF(!buf);
- *buf++ = 0x0f;
- *buf = opcode;
+ inst = emit_x86_instruction(compiler, 2 | (pref66 ? EX86_PREF_66 : 0) | EX86_SSE2, xmm1, 0, xmm2, xmm2w);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_0F;
+ *inst = opcode;
return SLJIT_SUCCESS;
}
-static SLJIT_INLINE int emit_sse2_load(struct sljit_compiler *compiler,
- int dst, int src, sljit_w srcw)
+static SLJIT_INLINE sljit_si emit_sse2_load(struct sljit_compiler *compiler,
+ sljit_si single, sljit_si dst, sljit_si src, sljit_sw srcw)
{
- return emit_sse2(compiler, 0x10, dst, src, srcw);
+ return emit_sse2(compiler, MOVSD_x_xm, single, dst, src, srcw);
}
-static SLJIT_INLINE int emit_sse2_store(struct sljit_compiler *compiler,
- int dst, sljit_w dstw, int src)
+static SLJIT_INLINE sljit_si emit_sse2_store(struct sljit_compiler *compiler,
+ sljit_si single, sljit_si dst, sljit_sw dstw, sljit_si src)
{
- return emit_sse2(compiler, 0x11, src, dst, dstw);
+ return emit_sse2(compiler, MOVSD_xm_x, single, src, dst, dstw);
}
-#if !(defined SLJIT_SSE2_AUTO && SLJIT_SSE2_AUTO)
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop1(struct sljit_compiler *compiler, int op,
-#else
-static int sljit_emit_sse2_fop1(struct sljit_compiler *compiler, int op,
-#endif
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
{
- int dst_r;
+ sljit_si dst_r;
CHECK_ERROR();
check_sljit_emit_fop1(compiler, op, dst, dstw, src, srcw);
@@ -2122,61 +2338,57 @@ static int sljit_emit_sse2_fop1(struct sljit_compiler *compiler, int op,
compiler->mode32 = 1;
#endif
- if (GET_OPCODE(op) == SLJIT_FCMP) {
+ if (GET_OPCODE(op) == SLJIT_CMPD) {
compiler->flags_saved = 0;
- if (dst >= SLJIT_FLOAT_REG1 && dst <= SLJIT_FLOAT_REG4)
+ if (dst <= SLJIT_FLOAT_REG6)
dst_r = dst;
else {
dst_r = TMP_FREG;
- FAIL_IF(emit_sse2_load(compiler, dst_r, dst, dstw));
+ FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, dst_r, dst, dstw));
}
- return emit_sse2_logic(compiler, 0x2e, dst_r, src, srcw);
+ return emit_sse2_logic(compiler, UCOMISD_x_xm, !(op & SLJIT_SINGLE_OP), dst_r, src, srcw);
}
- if (op == SLJIT_FMOV) {
- if (dst >= SLJIT_FLOAT_REG1 && dst <= SLJIT_FLOAT_REG4)
- return emit_sse2_load(compiler, dst, src, srcw);
- if (src >= SLJIT_FLOAT_REG1 && src <= SLJIT_FLOAT_REG4)
- return emit_sse2_store(compiler, dst, dstw, src);
- FAIL_IF(emit_sse2_load(compiler, TMP_FREG, src, srcw));
- return emit_sse2_store(compiler, dst, dstw, TMP_FREG);
+ if (op == SLJIT_MOVD) {
+ if (dst <= SLJIT_FLOAT_REG6)
+ return emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, dst, src, srcw);
+ if (src <= SLJIT_FLOAT_REG6)
+ return emit_sse2_store(compiler, op & SLJIT_SINGLE_OP, dst, dstw, src);
+ FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, TMP_FREG, src, srcw));
+ return emit_sse2_store(compiler, op & SLJIT_SINGLE_OP, dst, dstw, TMP_FREG);
}
- if (dst >= SLJIT_FLOAT_REG1 && dst <= SLJIT_FLOAT_REG4) {
+ if (dst >= SLJIT_FLOAT_REG1 && dst <= SLJIT_FLOAT_REG6) {
dst_r = dst;
if (dst != src)
- FAIL_IF(emit_sse2_load(compiler, dst_r, src, srcw));
+ FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, dst_r, src, srcw));
}
else {
dst_r = TMP_FREG;
- FAIL_IF(emit_sse2_load(compiler, dst_r, src, srcw));
+ FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, dst_r, src, srcw));
}
- switch (op) {
- case SLJIT_FNEG:
- FAIL_IF(emit_sse2_logic(compiler, 0x57, dst_r, SLJIT_MEM0(), (sljit_w)sse2_buffer));
+ switch (GET_OPCODE(op)) {
+ case SLJIT_NEGD:
+ FAIL_IF(emit_sse2_logic(compiler, XORPD_x_xm, 1, dst_r, SLJIT_MEM0(), (sljit_sw)(op & SLJIT_SINGLE_OP ? sse2_buffer : sse2_buffer + 8)));
break;
- case SLJIT_FABS:
- FAIL_IF(emit_sse2_logic(compiler, 0x54, dst_r, SLJIT_MEM0(), (sljit_w)(sse2_buffer + 4)));
+ case SLJIT_ABSD:
+ FAIL_IF(emit_sse2_logic(compiler, ANDPD_x_xm, 1, dst_r, SLJIT_MEM0(), (sljit_sw)(op & SLJIT_SINGLE_OP ? sse2_buffer + 4 : sse2_buffer + 12)));
break;
}
if (dst_r == TMP_FREG)
- return emit_sse2_store(compiler, dst, dstw, TMP_FREG);
+ return emit_sse2_store(compiler, op & SLJIT_SINGLE_OP, dst, dstw, TMP_FREG);
return SLJIT_SUCCESS;
}
-#if !(defined SLJIT_SSE2_AUTO && SLJIT_SSE2_AUTO)
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, int op,
-#else
-static int sljit_emit_sse2_fop2(struct sljit_compiler *compiler, int op,
-#endif
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
- int dst_r;
+ sljit_si dst_r;
CHECK_ERROR();
check_sljit_emit_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
@@ -2185,274 +2397,73 @@ static int sljit_emit_sse2_fop2(struct sljit_compiler *compiler, int op,
compiler->mode32 = 1;
#endif
- if (dst >= SLJIT_FLOAT_REG1 && dst <= SLJIT_FLOAT_REG4) {
+ if (dst <= SLJIT_FLOAT_REG6) {
dst_r = dst;
if (dst == src1)
; /* Do nothing here. */
- else if (dst == src2 && (op == SLJIT_FADD || op == SLJIT_FMUL)) {
+ else if (dst == src2 && (op == SLJIT_ADDD || op == SLJIT_MULD)) {
/* Swap arguments. */
src2 = src1;
src2w = src1w;
}
else if (dst != src2)
- FAIL_IF(emit_sse2_load(compiler, dst_r, src1, src1w));
+ FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, dst_r, src1, src1w));
else {
dst_r = TMP_FREG;
- FAIL_IF(emit_sse2_load(compiler, TMP_FREG, src1, src1w));
+ FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, TMP_FREG, src1, src1w));
}
}
else {
dst_r = TMP_FREG;
- FAIL_IF(emit_sse2_load(compiler, TMP_FREG, src1, src1w));
+ FAIL_IF(emit_sse2_load(compiler, op & SLJIT_SINGLE_OP, TMP_FREG, src1, src1w));
}
- switch (op) {
- case SLJIT_FADD:
- FAIL_IF(emit_sse2(compiler, 0x58, dst_r, src2, src2w));
+ switch (GET_OPCODE(op)) {
+ case SLJIT_ADDD:
+ FAIL_IF(emit_sse2(compiler, ADDSD_x_xm, op & SLJIT_SINGLE_OP, dst_r, src2, src2w));
break;
- case SLJIT_FSUB:
- FAIL_IF(emit_sse2(compiler, 0x5c, dst_r, src2, src2w));
+ case SLJIT_SUBD:
+ FAIL_IF(emit_sse2(compiler, SUBSD_x_xm, op & SLJIT_SINGLE_OP, dst_r, src2, src2w));
break;
- case SLJIT_FMUL:
- FAIL_IF(emit_sse2(compiler, 0x59, dst_r, src2, src2w));
+ case SLJIT_MULD:
+ FAIL_IF(emit_sse2(compiler, MULSD_x_xm, op & SLJIT_SINGLE_OP, dst_r, src2, src2w));
break;
- case SLJIT_FDIV:
- FAIL_IF(emit_sse2(compiler, 0x5e, dst_r, src2, src2w));
+ case SLJIT_DIVD:
+ FAIL_IF(emit_sse2(compiler, DIVSD_x_xm, op & SLJIT_SINGLE_OP, dst_r, src2, src2w));
break;
}
if (dst_r == TMP_FREG)
- return emit_sse2_store(compiler, dst, dstw, TMP_FREG);
+ return emit_sse2_store(compiler, op & SLJIT_SINGLE_OP, dst, dstw, TMP_FREG);
return SLJIT_SUCCESS;
}
-#endif
-
-#if (defined SLJIT_SSE2_AUTO && SLJIT_SSE2_AUTO) || !(defined SLJIT_SSE2 && SLJIT_SSE2)
-
-static int emit_fld(struct sljit_compiler *compiler,
- int src, sljit_w srcw)
-{
- sljit_ub *buf;
-
- if (src >= SLJIT_FLOAT_REG1 && src <= SLJIT_FLOAT_REG4) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 2);
- FAIL_IF(!buf);
- INC_SIZE(2);
- *buf++ = 0xd9;
- *buf = 0xc0 + src - 1;
- return SLJIT_SUCCESS;
- }
-
- buf = emit_x86_instruction(compiler, 1, 0, 0, src, srcw);
- FAIL_IF(!buf);
- *buf = 0xdd;
- return SLJIT_SUCCESS;
-}
-
-static int emit_fop(struct sljit_compiler *compiler,
- sljit_ub st_arg, sljit_ub st_arg2,
- sljit_ub m64fp_arg, sljit_ub m64fp_arg2,
- int src, sljit_w srcw)
-{
- sljit_ub *buf;
-
- if (src >= SLJIT_FLOAT_REG1 && src <= SLJIT_FLOAT_REG4) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 2);
- FAIL_IF(!buf);
- INC_SIZE(2);
- *buf++ = st_arg;
- *buf = st_arg2 + src;
- return SLJIT_SUCCESS;
- }
-
- buf = emit_x86_instruction(compiler, 1, 0, 0, src, srcw);
- FAIL_IF(!buf);
- *buf++ = m64fp_arg;
- *buf |= m64fp_arg2;
- return SLJIT_SUCCESS;
-}
-
-static int emit_fop_regs(struct sljit_compiler *compiler,
- sljit_ub st_arg, sljit_ub st_arg2,
- int src)
-{
- sljit_ub *buf;
-
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 2);
- FAIL_IF(!buf);
- INC_SIZE(2);
- *buf++ = st_arg;
- *buf = st_arg2 + src;
- return SLJIT_SUCCESS;
-}
-
-#if !(defined SLJIT_SSE2_AUTO && SLJIT_SSE2_AUTO)
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop1(struct sljit_compiler *compiler, int op,
#else
-static int sljit_emit_fpu_fop1(struct sljit_compiler *compiler, int op,
-#endif
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
-{
-#if !(defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- sljit_ub *buf;
-#endif
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop1(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw)
+{
CHECK_ERROR();
+ /* Should cause an assertion fail. */
check_sljit_emit_fop1(compiler, op, dst, dstw, src, srcw);
-
-#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- compiler->mode32 = 1;
-#endif
-
- if (GET_OPCODE(op) == SLJIT_FCMP) {
- compiler->flags_saved = 0;
-#if !(defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- FAIL_IF(emit_fld(compiler, dst, dstw));
- FAIL_IF(emit_fop(compiler, 0xd8, 0xd8, 0xdc, 0x3 << 3, src, srcw));
-
- /* Copy flags. */
- EMIT_MOV(compiler, TMP_REGISTER, 0, SLJIT_TEMPORARY_REG1, 0);
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 3);
- FAIL_IF(!buf);
- INC_SIZE(3);
- *buf++ = 0xdf;
- *buf++ = 0xe0;
- /* Note: lahf is not supported on all x86-64 architectures. */
- *buf++ = 0x9e;
- EMIT_MOV(compiler, SLJIT_TEMPORARY_REG1, 0, TMP_REGISTER, 0);
-#else
- if (src >= SLJIT_FLOAT_REG1 && src <= SLJIT_FLOAT_REG4) {
- FAIL_IF(emit_fld(compiler, dst, dstw));
- FAIL_IF(emit_fop_regs(compiler, 0xdf, 0xe8, src));
- } else {
- FAIL_IF(emit_fld(compiler, src, srcw));
- FAIL_IF(emit_fld(compiler, dst + ((dst >= SLJIT_FLOAT_REG1 && dst <= SLJIT_FLOAT_REG4) ? 1 : 0), dstw));
- FAIL_IF(emit_fop_regs(compiler, 0xdf, 0xe8, src));
- FAIL_IF(emit_fop_regs(compiler, 0xdd, 0xd8, 0));
- }
-#endif
- return SLJIT_SUCCESS;
- }
-
- FAIL_IF(emit_fld(compiler, src, srcw));
-
- switch (op) {
- case SLJIT_FNEG:
- FAIL_IF(emit_fop_regs(compiler, 0xd9, 0xe0, 0));
- break;
- case SLJIT_FABS:
- FAIL_IF(emit_fop_regs(compiler, 0xd9, 0xe1, 0));
- break;
- }
-
- FAIL_IF(emit_fop(compiler, 0xdd, 0xd8, 0xdd, 0x3 << 3, dst, dstw));
-
- return SLJIT_SUCCESS;
+ compiler->error = SLJIT_ERR_UNSUPPORTED;
+ return SLJIT_ERR_UNSUPPORTED;
}
-#if !(defined SLJIT_SSE2_AUTO && SLJIT_SSE2_AUTO)
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, int op,
-#else
-static int sljit_emit_fpu_fop2(struct sljit_compiler *compiler, int op,
-#endif
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_fop2(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src1, sljit_sw src1w,
+ sljit_si src2, sljit_sw src2w)
{
CHECK_ERROR();
+ /* Should cause an assertion fail. */
check_sljit_emit_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
-
-#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- compiler->mode32 = 1;
-#endif
-
- if (src1 >= SLJIT_FLOAT_REG1 && src1 <= SLJIT_FLOAT_REG4 && dst == src1) {
- FAIL_IF(emit_fld(compiler, src2, src2w));
-
- switch (op) {
- case SLJIT_FADD:
- FAIL_IF(emit_fop_regs(compiler, 0xde, 0xc0, src1));
- break;
- case SLJIT_FSUB:
- FAIL_IF(emit_fop_regs(compiler, 0xde, 0xe8, src1));
- break;
- case SLJIT_FMUL:
- FAIL_IF(emit_fop_regs(compiler, 0xde, 0xc8, src1));
- break;
- case SLJIT_FDIV:
- FAIL_IF(emit_fop_regs(compiler, 0xde, 0xf8, src1));
- break;
- }
- return SLJIT_SUCCESS;
- }
-
- FAIL_IF(emit_fld(compiler, src1, src1w));
-
- if (src2 >= SLJIT_FLOAT_REG1 && src2 <= SLJIT_FLOAT_REG4 && dst == src2) {
- switch (op) {
- case SLJIT_FADD:
- FAIL_IF(emit_fop_regs(compiler, 0xde, 0xc0, src2));
- break;
- case SLJIT_FSUB:
- FAIL_IF(emit_fop_regs(compiler, 0xde, 0xe0, src2));
- break;
- case SLJIT_FMUL:
- FAIL_IF(emit_fop_regs(compiler, 0xde, 0xc8, src2));
- break;
- case SLJIT_FDIV:
- FAIL_IF(emit_fop_regs(compiler, 0xde, 0xf0, src2));
- break;
- }
- return SLJIT_SUCCESS;
- }
-
- switch (op) {
- case SLJIT_FADD:
- FAIL_IF(emit_fop(compiler, 0xd8, 0xc0, 0xdc, 0x0 << 3, src2, src2w));
- break;
- case SLJIT_FSUB:
- FAIL_IF(emit_fop(compiler, 0xd8, 0xe0, 0xdc, 0x4 << 3, src2, src2w));
- break;
- case SLJIT_FMUL:
- FAIL_IF(emit_fop(compiler, 0xd8, 0xc8, 0xdc, 0x1 << 3, src2, src2w));
- break;
- case SLJIT_FDIV:
- FAIL_IF(emit_fop(compiler, 0xd8, 0xf0, 0xdc, 0x6 << 3, src2, src2w));
- break;
- }
-
- FAIL_IF(emit_fop(compiler, 0xdd, 0xd8, 0xdd, 0x3 << 3, dst, dstw));
-
- return SLJIT_SUCCESS;
-}
-#endif
-
-#if (defined SLJIT_SSE2_AUTO && SLJIT_SSE2_AUTO)
-
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop1(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src, sljit_w srcw)
-{
- if (sse2_available)
- return sljit_emit_sse2_fop1(compiler, op, dst, dstw, src, srcw);
- else
- return sljit_emit_fpu_fop1(compiler, op, dst, dstw, src, srcw);
-}
-
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, int op,
- int dst, sljit_w dstw,
- int src1, sljit_w src1w,
- int src2, sljit_w src2w)
-{
- if (sse2_available)
- return sljit_emit_sse2_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
- else
- return sljit_emit_fpu_fop2(compiler, op, dst, dstw, src1, src1w, src2, src2w);
+ compiler->error = SLJIT_ERR_UNSUPPORTED;
+ return SLJIT_ERR_UNSUPPORTED;
}
#endif
@@ -2463,7 +2474,7 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_fop2(struct sljit_compiler *compiler, in
SLJIT_API_FUNC_ATTRIBUTE struct sljit_label* sljit_emit_label(struct sljit_compiler *compiler)
{
- sljit_ub *buf;
+ sljit_ub *inst;
struct sljit_label *label;
CHECK_ERROR_PTR();
@@ -2481,18 +2492,18 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_label* sljit_emit_label(struct sljit_compi
PTR_FAIL_IF(!label);
set_label(label, compiler);
- buf = (sljit_ub*)ensure_buf(compiler, 2);
- PTR_FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 2);
+ PTR_FAIL_IF(!inst);
- *buf++ = 0;
- *buf++ = 0;
+ *inst++ = 0;
+ *inst++ = 0;
return label;
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, int type)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compiler *compiler, sljit_si type)
{
- sljit_ub *buf;
+ sljit_ub *inst;
struct sljit_jump *jump;
CHECK_ERROR_PTR();
@@ -2519,23 +2530,25 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_jump* sljit_emit_jump(struct sljit_compile
compiler->size += (type >= SLJIT_JUMP) ? (10 + 3) : (2 + 10 + 3);
#endif
- buf = (sljit_ub*)ensure_buf(compiler, 2);
- PTR_FAIL_IF_NULL(buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 2);
+ PTR_FAIL_IF_NULL(inst);
- *buf++ = 0;
- *buf++ = type + 4;
+ *inst++ = 0;
+ *inst++ = type + 4;
return jump;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, int type, int src, sljit_w srcw)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_ijump(struct sljit_compiler *compiler, sljit_si type, sljit_si src, sljit_sw srcw)
{
- sljit_ub *code;
+ sljit_ub *inst;
struct sljit_jump *jump;
CHECK_ERROR();
check_sljit_emit_ijump(compiler, type, src, srcw);
+ ADJUST_LOCAL_OFFSET(src, srcw);
CHECK_EXTRA_REGS(src, srcw, (void)0);
+
if (SLJIT_UNLIKELY(compiler->flags_saved)) {
if (type <= SLJIT_JUMP)
FAIL_IF(emit_restore_flags(compiler, 0));
@@ -2545,31 +2558,16 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, i
if (type >= SLJIT_CALL1) {
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
#if (defined SLJIT_X86_32_FASTCALL && SLJIT_X86_32_FASTCALL)
- if (src == SLJIT_TEMPORARY_REG3) {
+ if (src == SLJIT_SCRATCH_REG3) {
EMIT_MOV(compiler, TMP_REGISTER, 0, src, 0);
src = TMP_REGISTER;
}
- if ((src & SLJIT_MEM) && (src & 0xf) == SLJIT_LOCALS_REG && type >= SLJIT_CALL3) {
- if (src & 0xf0) {
- EMIT_MOV(compiler, TMP_REGISTER, 0, src, srcw);
- src = TMP_REGISTER;
- }
- else
- srcw += sizeof(sljit_w);
- }
-#else
- if ((src & SLJIT_MEM) && (src & 0xf) == SLJIT_LOCALS_REG) {
- if (src & 0xf0) {
- EMIT_MOV(compiler, TMP_REGISTER, 0, src, srcw);
- src = TMP_REGISTER;
- }
- else
- srcw += sizeof(sljit_w) * (type - SLJIT_CALL0);
- }
+ if (src == SLJIT_MEM1(SLJIT_LOCALS_REG) && type >= SLJIT_CALL3)
+ srcw += sizeof(sljit_sw);
#endif
#endif
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64) && defined(_WIN64)
- if (src == SLJIT_TEMPORARY_REG3) {
+ if (src == SLJIT_SCRATCH_REG3) {
EMIT_MOV(compiler, TMP_REGISTER, 0, src, 0);
src = TMP_REGISTER;
}
@@ -2590,223 +2588,203 @@ SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_ijump(struct sljit_compiler *compiler, i
compiler->size += 10 + 3;
#endif
- code = (sljit_ub*)ensure_buf(compiler, 2);
- FAIL_IF_NULL(code);
+ inst = (sljit_ub*)ensure_buf(compiler, 2);
+ FAIL_IF_NULL(inst);
- *code++ = 0;
- *code++ = type + 4;
+ *inst++ = 0;
+ *inst++ = type + 4;
}
else {
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
/* REX_W is not necessary (src is not immediate). */
compiler->mode32 = 1;
#endif
- code = emit_x86_instruction(compiler, 1, 0, 0, src, srcw);
- FAIL_IF(!code);
- *code++ = 0xff;
- *code |= (type >= SLJIT_FAST_CALL) ? (2 << 3) : (4 << 3);
+ inst = emit_x86_instruction(compiler, 1, 0, 0, src, srcw);
+ FAIL_IF(!inst);
+ *inst++ = GROUP_FF;
+ *inst |= (type >= SLJIT_FAST_CALL) ? CALL_rm : JMP_rm;
}
return SLJIT_SUCCESS;
}
-SLJIT_API_FUNC_ATTRIBUTE int sljit_emit_cond_value(struct sljit_compiler *compiler, int op, int dst, sljit_w dstw, int type)
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_emit_op_flags(struct sljit_compiler *compiler, sljit_si op,
+ sljit_si dst, sljit_sw dstw,
+ sljit_si src, sljit_sw srcw,
+ sljit_si type)
{
- sljit_ub *buf;
+ sljit_ub *inst;
sljit_ub cond_set = 0;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- int reg;
+ sljit_si reg;
+#else
+ /* CHECK_EXTRA_REGS migh overwrite these values. */
+ sljit_si dst_save = dst;
+ sljit_sw dstw_save = dstw;
#endif
CHECK_ERROR();
- check_sljit_emit_cond_value(compiler, op, dst, dstw, type);
+ check_sljit_emit_op_flags(compiler, op, dst, dstw, src, srcw, type);
if (dst == SLJIT_UNUSED)
return SLJIT_SUCCESS;
+ ADJUST_LOCAL_OFFSET(dst, dstw);
CHECK_EXTRA_REGS(dst, dstw, (void)0);
if (SLJIT_UNLIKELY(compiler->flags_saved))
- FAIL_IF(emit_restore_flags(compiler, 0));
+ FAIL_IF(emit_restore_flags(compiler, op & SLJIT_KEEP_FLAGS));
- switch (type) {
- case SLJIT_C_EQUAL:
- case SLJIT_C_FLOAT_EQUAL:
- cond_set = 0x94;
- break;
+ /* setcc = jcc + 0x10. */
+ cond_set = get_jump_code(type) + 0x10;
- case SLJIT_C_NOT_EQUAL:
- case SLJIT_C_FLOAT_NOT_EQUAL:
- cond_set = 0x95;
- break;
+#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
+ reg = (op == SLJIT_MOV && dst <= TMP_REGISTER) ? dst : TMP_REGISTER;
- case SLJIT_C_LESS:
- case SLJIT_C_FLOAT_LESS:
- cond_set = 0x92;
- break;
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 4 + 4);
+ FAIL_IF(!inst);
+ INC_SIZE(4 + 4);
+ /* Set low register to conditional flag. */
+ *inst++ = (reg_map[reg] <= 7) ? REX : REX_B;
+ *inst++ = GROUP_0F;
+ *inst++ = cond_set;
+ *inst++ = MOD_REG | reg_lmap[reg];
+ *inst++ = REX_W | (reg_map[reg] <= 7 ? 0 : (REX_B | REX_R));
+ *inst++ = GROUP_0F;
+ *inst++ = MOVZX_r_rm8;
+ *inst = MOD_REG | (reg_lmap[reg] << 3) | reg_lmap[reg];
+
+ if (reg != TMP_REGISTER)
+ return SLJIT_SUCCESS;
- case SLJIT_C_GREATER_EQUAL:
- case SLJIT_C_FLOAT_GREATER_EQUAL:
- cond_set = 0x93;
- break;
+ if (GET_OPCODE(op) < SLJIT_ADD) {
+ compiler->mode32 = GET_OPCODE(op) != SLJIT_MOV;
+ return emit_mov(compiler, dst, dstw, TMP_REGISTER, 0);
+ }
+#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ compiler->skip_checks = 1;
+#endif
+ return sljit_emit_op2(compiler, op, dst, dstw, dst, dstw, TMP_REGISTER, 0);
+#else /* SLJIT_CONFIG_X86_64 */
+ if (GET_OPCODE(op) < SLJIT_ADD && dst <= TMP_REGISTER) {
+ if (reg_map[dst] <= 4) {
+ /* Low byte is accessible. */
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 3 + 3);
+ FAIL_IF(!inst);
+ INC_SIZE(3 + 3);
+ /* Set low byte to conditional flag. */
+ *inst++ = GROUP_0F;
+ *inst++ = cond_set;
+ *inst++ = MOD_REG | reg_map[dst];
- case SLJIT_C_GREATER:
- case SLJIT_C_FLOAT_GREATER:
- cond_set = 0x97;
- break;
+ *inst++ = GROUP_0F;
+ *inst++ = MOVZX_r_rm8;
+ *inst = MOD_REG | (reg_map[dst] << 3) | reg_map[dst];
+ return SLJIT_SUCCESS;
+ }
- case SLJIT_C_LESS_EQUAL:
- case SLJIT_C_FLOAT_LESS_EQUAL:
- cond_set = 0x96;
- break;
+ /* Low byte is not accessible. */
+ if (cpu_has_cmov == -1)
+ get_cpu_features();
- case SLJIT_C_SIG_LESS:
- cond_set = 0x9c;
- break;
+ if (cpu_has_cmov) {
+ EMIT_MOV(compiler, TMP_REGISTER, 0, SLJIT_IMM, 1);
+ /* a xor reg, reg operation would overwrite the flags. */
+ EMIT_MOV(compiler, dst, 0, SLJIT_IMM, 0);
- case SLJIT_C_SIG_GREATER_EQUAL:
- cond_set = 0x9d;
- break;
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 3);
+ FAIL_IF(!inst);
+ INC_SIZE(3);
- case SLJIT_C_SIG_GREATER:
- cond_set = 0x9f;
- break;
+ *inst++ = GROUP_0F;
+ /* cmovcc = setcc - 0x50. */
+ *inst++ = cond_set - 0x50;
+ *inst++ = MOD_REG | (reg_map[dst] << 3) | reg_map[TMP_REGISTER];
+ return SLJIT_SUCCESS;
+ }
- case SLJIT_C_SIG_LESS_EQUAL:
- cond_set = 0x9e;
- break;
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1 + 3 + 3 + 1);
+ FAIL_IF(!inst);
+ INC_SIZE(1 + 3 + 3 + 1);
+ *inst++ = XCHG_EAX_r + reg_map[TMP_REGISTER];
+ /* Set al to conditional flag. */
+ *inst++ = GROUP_0F;
+ *inst++ = cond_set;
+ *inst++ = MOD_REG | 0 /* eax */;
- case SLJIT_C_OVERFLOW:
- case SLJIT_C_MUL_OVERFLOW:
- cond_set = 0x90;
- break;
+ *inst++ = GROUP_0F;
+ *inst++ = MOVZX_r_rm8;
+ *inst++ = MOD_REG | (reg_map[dst] << 3) | 0 /* eax */;
+ *inst++ = XCHG_EAX_r + reg_map[TMP_REGISTER];
+ return SLJIT_SUCCESS;
+ }
- case SLJIT_C_NOT_OVERFLOW:
- case SLJIT_C_MUL_NOT_OVERFLOW:
- cond_set = 0x91;
- break;
+ /* Set TMP_REGISTER to the bit. */
+ inst = (sljit_ub*)ensure_buf(compiler, 1 + 1 + 3 + 3 + 1);
+ FAIL_IF(!inst);
+ INC_SIZE(1 + 3 + 3 + 1);
+ *inst++ = XCHG_EAX_r + reg_map[TMP_REGISTER];
+ /* Set al to conditional flag. */
+ *inst++ = GROUP_0F;
+ *inst++ = cond_set;
+ *inst++ = MOD_REG | 0 /* eax */;
- case SLJIT_C_FLOAT_NAN:
- cond_set = 0x9a;
- break;
+ *inst++ = GROUP_0F;
+ *inst++ = MOVZX_r_rm8;
+ *inst++ = MOD_REG | (0 << 3) /* eax */ | 0 /* eax */;
- case SLJIT_C_FLOAT_NOT_NAN:
- cond_set = 0x9b;
- break;
- }
+ *inst++ = XCHG_EAX_r + reg_map[TMP_REGISTER];
-#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- reg = (op == SLJIT_MOV && dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REGISTER;
+ if (GET_OPCODE(op) < SLJIT_ADD)
+ return emit_mov(compiler, dst, dstw, TMP_REGISTER, 0);
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 4 + 4);
- FAIL_IF(!buf);
- INC_SIZE(4 + 4);
- /* Set low register to conditional flag. */
- *buf++ = (reg_map[reg] <= 7) ? 0x40 : REX_B;
- *buf++ = 0x0f;
- *buf++ = cond_set;
- *buf++ = 0xC0 | reg_lmap[reg];
- *buf++ = REX_W | (reg_map[reg] <= 7 ? 0 : (REX_B | REX_R));
- *buf++ = 0x0f;
- *buf++ = 0xb6;
- *buf = 0xC0 | (reg_lmap[reg] << 3) | reg_lmap[reg];
-
- if (reg == TMP_REGISTER) {
- if (op == SLJIT_MOV) {
- compiler->mode32 = 0;
- EMIT_MOV(compiler, dst, dstw, TMP_REGISTER, 0);
- }
- else {
#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
- compiler->skip_checks = 1;
+ compiler->skip_checks = 1;
#endif
- return sljit_emit_op2(compiler, op, dst, dstw, dst, dstw, TMP_REGISTER, 0);
- }
- }
-#else
- if (op == SLJIT_MOV) {
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_TEMPORARY_REG3) {
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 3 + 3);
- FAIL_IF(!buf);
- INC_SIZE(3 + 3);
- /* Set low byte to conditional flag. */
- *buf++ = 0x0f;
- *buf++ = cond_set;
- *buf++ = 0xC0 | reg_map[dst];
-
- *buf++ = 0x0f;
- *buf++ = 0xb6;
- *buf = 0xC0 | (reg_map[dst] << 3) | reg_map[dst];
- }
- else {
- EMIT_MOV(compiler, TMP_REGISTER, 0, SLJIT_TEMPORARY_REG1, 0);
-
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 3 + 3);
- FAIL_IF(!buf);
- INC_SIZE(3 + 3);
- /* Set al to conditional flag. */
- *buf++ = 0x0f;
- *buf++ = cond_set;
- *buf++ = 0xC0;
-
- *buf++ = 0x0f;
- *buf++ = 0xb6;
- if (dst >= SLJIT_SAVED_REG1 && dst <= SLJIT_NO_REGISTERS)
- *buf = 0xC0 | (reg_map[dst] << 3);
- else {
- *buf = 0xC0;
- EMIT_MOV(compiler, dst, dstw, SLJIT_TEMPORARY_REG1, 0);
- }
+ return sljit_emit_op2(compiler, op, dst_save, dstw_save, dst_save, dstw_save, TMP_REGISTER, 0);
+#endif /* SLJIT_CONFIG_X86_64 */
+}
- EMIT_MOV(compiler, SLJIT_TEMPORARY_REG1, 0, TMP_REGISTER, 0);
- }
- }
- else {
- if (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_TEMPORARY_REG3) {
- EMIT_MOV(compiler, TMP_REGISTER, 0, dst, 0);
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 3);
- FAIL_IF(!buf);
- INC_SIZE(3);
+SLJIT_API_FUNC_ATTRIBUTE sljit_si sljit_get_local_base(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw offset)
+{
+ CHECK_ERROR();
+ check_sljit_get_local_base(compiler, dst, dstw, offset);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
- *buf++ = 0x0f;
- *buf++ = cond_set;
- *buf++ = 0xC0 | reg_map[dst];
- }
- else {
- EMIT_MOV(compiler, TMP_REGISTER, 0, SLJIT_TEMPORARY_REG1, 0);
+ CHECK_EXTRA_REGS(dst, dstw, (void)0);
- buf = (sljit_ub*)ensure_buf(compiler, 1 + 3 + 3 + 1);
- FAIL_IF(!buf);
- INC_SIZE(3 + 3 + 1);
- /* Set al to conditional flag. */
- *buf++ = 0x0f;
- *buf++ = cond_set;
- *buf++ = 0xC0;
+#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
+ compiler->mode32 = 0;
+#endif
- *buf++ = 0x0f;
- *buf++ = 0xb6;
- *buf++ = 0xC0;
+ ADJUST_LOCAL_OFFSET(SLJIT_MEM1(SLJIT_LOCALS_REG), offset);
- *buf++ = 0x90 + reg_map[TMP_REGISTER];
- }
-#if (defined SLJIT_VERBOSE && SLJIT_VERBOSE) || (defined SLJIT_DEBUG && SLJIT_DEBUG)
- compiler->skip_checks = 1;
+#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
+ if (NOT_HALFWORD(offset)) {
+ FAIL_IF(emit_load_imm64(compiler, TMP_REGISTER, offset));
+#if (defined SLJIT_DEBUG && SLJIT_DEBUG)
+ SLJIT_ASSERT(emit_lea_binary(compiler, dst, dstw, SLJIT_LOCALS_REG, 0, TMP_REGISTER, 0) != SLJIT_ERR_UNSUPPORTED);
+ return compiler->error;
+#else
+ return emit_lea_binary(compiler, dst, dstw, SLJIT_LOCALS_REG, 0, TMP_REGISTER, 0);
#endif
- return sljit_emit_op2(compiler, op, dst, dstw, dst, dstw, TMP_REGISTER, 0);
}
#endif
- return SLJIT_SUCCESS;
+ if (offset != 0)
+ return emit_lea_binary(compiler, dst, dstw, SLJIT_LOCALS_REG, 0, SLJIT_IMM, offset);
+ return emit_mov(compiler, dst, dstw, SLJIT_LOCALS_REG, 0);
}
-SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, int dst, sljit_w dstw, sljit_w init_value)
+SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, sljit_si dst, sljit_sw dstw, sljit_sw init_value)
{
- sljit_ub *buf;
+ sljit_ub *inst;
struct sljit_const *const_;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
- int reg;
+ sljit_si reg;
#endif
CHECK_ERROR_PTR();
check_sljit_emit_const(compiler, dst, dstw, init_value);
+ ADJUST_LOCAL_OFFSET(dst, dstw);
CHECK_EXTRA_REGS(dst, dstw, (void)0);
@@ -2816,7 +2794,7 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compi
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
compiler->mode32 = 0;
- reg = (dst >= SLJIT_TEMPORARY_REG1 && dst <= SLJIT_NO_REGISTERS) ? dst : TMP_REGISTER;
+ reg = (dst <= TMP_REGISTER) ? dst : TMP_REGISTER;
if (emit_load_imm64(compiler, reg, init_value))
return NULL;
@@ -2828,11 +2806,11 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compi
return NULL;
#endif
- buf = (sljit_ub*)ensure_buf(compiler, 2);
- PTR_FAIL_IF(!buf);
+ inst = (sljit_ub*)ensure_buf(compiler, 2);
+ PTR_FAIL_IF(!inst);
- *buf++ = 0;
- *buf++ = 1;
+ *inst++ = 0;
+ *inst++ = 1;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
if (reg == TMP_REGISTER && dst != SLJIT_UNUSED)
@@ -2846,13 +2824,13 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_const* sljit_emit_const(struct sljit_compi
SLJIT_API_FUNC_ATTRIBUTE void sljit_set_jump_addr(sljit_uw addr, sljit_uw new_addr)
{
#if (defined SLJIT_CONFIG_X86_32 && SLJIT_CONFIG_X86_32)
- *(sljit_w*)addr = new_addr - (addr + 4);
+ *(sljit_sw*)addr = new_addr - (addr + 4);
#else
*(sljit_uw*)addr = new_addr;
#endif
}
-SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_w new_constant)
+SLJIT_API_FUNC_ATTRIBUTE void sljit_set_const(sljit_uw addr, sljit_sw new_constant)
{
- *(sljit_w*)addr = new_constant;
+ *(sljit_sw*)addr = new_constant;
}
diff --git a/src/3rdparty/pcre/sljit/sljitUtils.c b/src/3rdparty/pcre/sljit/sljitUtils.c
index f3b52fece7..1f023fa644 100644
--- a/src/3rdparty/pcre/sljit/sljitUtils.c
+++ b/src/3rdparty/pcre/sljit/sljitUtils.c
@@ -30,7 +30,37 @@
#if (defined SLJIT_EXECUTABLE_ALLOCATOR && SLJIT_EXECUTABLE_ALLOCATOR) || (defined SLJIT_UTIL_GLOBAL_LOCK && SLJIT_UTIL_GLOBAL_LOCK)
-#ifdef _WIN32
+#if (defined SLJIT_SINGLE_THREADED && SLJIT_SINGLE_THREADED)
+
+#if (defined SLJIT_EXECUTABLE_ALLOCATOR && SLJIT_EXECUTABLE_ALLOCATOR)
+
+static SLJIT_INLINE void allocator_grab_lock(void)
+{
+ /* Always successful. */
+}
+
+static SLJIT_INLINE void allocator_release_lock(void)
+{
+ /* Always successful. */
+}
+
+#endif /* SLJIT_EXECUTABLE_ALLOCATOR */
+
+#if (defined SLJIT_UTIL_GLOBAL_LOCK && SLJIT_UTIL_GLOBAL_LOCK)
+
+SLJIT_API_FUNC_ATTRIBUTE void SLJIT_CALL sljit_grab_lock(void)
+{
+ /* Always successful. */
+}
+
+SLJIT_API_FUNC_ATTRIBUTE void SLJIT_CALL sljit_release_lock(void)
+{
+ /* Always successful. */
+}
+
+#endif /* SLJIT_UTIL_GLOBAL_LOCK */
+
+#elif defined(_WIN32) /* SLJIT_SINGLE_THREADED */
#include "windows.h"
@@ -76,10 +106,10 @@ SLJIT_API_FUNC_ATTRIBUTE void SLJIT_CALL sljit_release_lock(void)
#else /* _WIN32 */
-#include "pthread.h"
-
#if (defined SLJIT_EXECUTABLE_ALLOCATOR && SLJIT_EXECUTABLE_ALLOCATOR)
+#include <pthread.h>
+
static pthread_mutex_t allocator_mutex = PTHREAD_MUTEX_INITIALIZER;
static SLJIT_INLINE void allocator_grab_lock(void)
@@ -96,6 +126,8 @@ static SLJIT_INLINE void allocator_release_lock(void)
#if (defined SLJIT_UTIL_GLOBAL_LOCK && SLJIT_UTIL_GLOBAL_LOCK)
+#include <pthread.h>
+
static pthread_mutex_t global_mutex = PTHREAD_MUTEX_INITIALIZER;
SLJIT_API_FUNC_ATTRIBUTE void SLJIT_CALL sljit_grab_lock(void)
@@ -116,17 +148,57 @@ SLJIT_API_FUNC_ATTRIBUTE void SLJIT_CALL sljit_release_lock(void)
/* Stack */
/* ------------------------------------------------------------------------ */
-#if (defined SLJIT_UTIL_STACK && SLJIT_UTIL_STACK)
+#if (defined SLJIT_UTIL_STACK && SLJIT_UTIL_STACK) || (defined SLJIT_EXECUTABLE_ALLOCATOR && SLJIT_EXECUTABLE_ALLOCATOR)
#ifdef _WIN32
#include "windows.h"
#else
+/* Provides mmap function. */
#include <sys/mman.h>
+/* For detecting the page size. */
#include <unistd.h>
+
+#ifndef MAP_ANON
+
+#include <fcntl.h>
+
+/* Some old systems does not have MAP_ANON. */
+static sljit_si dev_zero = -1;
+
+#if (defined SLJIT_SINGLE_THREADED && SLJIT_SINGLE_THREADED)
+
+static SLJIT_INLINE sljit_si open_dev_zero(void)
+{
+ dev_zero = open("/dev/zero", O_RDWR);
+ return dev_zero < 0;
+}
+
+#else /* SLJIT_SINGLE_THREADED */
+
+#include <pthread.h>
+
+static pthread_mutex_t dev_zero_mutex = PTHREAD_MUTEX_INITIALIZER;
+
+static SLJIT_INLINE sljit_si open_dev_zero(void)
+{
+ pthread_mutex_lock(&dev_zero_mutex);
+ dev_zero = open("/dev/zero", O_RDWR);
+ pthread_mutex_unlock(&dev_zero_mutex);
+ return dev_zero < 0;
+}
+
+#endif /* SLJIT_SINGLE_THREADED */
+
#endif
+#endif
+
+#endif /* SLJIT_UTIL_STACK || SLJIT_EXECUTABLE_ALLOCATOR */
+
+#if (defined SLJIT_UTIL_STACK && SLJIT_UTIL_STACK)
+
/* Planning to make it even more clever in the future. */
-static sljit_w sljit_page_align = 0;
+static sljit_sw sljit_page_align = 0;
SLJIT_API_FUNC_ATTRIBUTE struct sljit_stack* SLJIT_CALL sljit_allocate_stack(sljit_uw limit, sljit_uw max_limit)
{
@@ -165,7 +237,7 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_stack* SLJIT_CALL sljit_allocate_stack(slj
return NULL;
#ifdef _WIN32
- base.ptr = VirtualAlloc(0, max_limit, MEM_RESERVE, PAGE_READWRITE);
+ base.ptr = VirtualAlloc(NULL, max_limit, MEM_RESERVE, PAGE_READWRITE);
if (!base.ptr) {
SLJIT_FREE(stack);
return NULL;
@@ -178,7 +250,17 @@ SLJIT_API_FUNC_ATTRIBUTE struct sljit_stack* SLJIT_CALL sljit_allocate_stack(slj
return NULL;
}
#else
- base.ptr = mmap(0, max_limit, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON, -1, 0);
+#ifdef MAP_ANON
+ base.ptr = mmap(NULL, max_limit, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANON, -1, 0);
+#else
+ if (dev_zero < 0) {
+ if (open_dev_zero()) {
+ SLJIT_FREE(stack);
+ return NULL;
+ }
+ }
+ base.ptr = mmap(NULL, max_limit, PROT_READ | PROT_WRITE, MAP_PRIVATE, dev_zero, 0);
+#endif
if (base.ptr == MAP_FAILED) {
SLJIT_FREE(stack);
return NULL;
@@ -203,7 +285,7 @@ SLJIT_API_FUNC_ATTRIBUTE void SLJIT_CALL sljit_free_stack(struct sljit_stack* st
SLJIT_FREE(stack);
}
-SLJIT_API_FUNC_ATTRIBUTE sljit_w SLJIT_CALL sljit_stack_resize(struct sljit_stack* stack, sljit_uw new_limit)
+SLJIT_API_FUNC_ATTRIBUTE sljit_sw SLJIT_CALL sljit_stack_resize(struct sljit_stack* stack, sljit_uw new_limit)
{
sljit_uw aligned_old_limit;
sljit_uw aligned_new_limit;
@@ -232,10 +314,12 @@ SLJIT_API_FUNC_ATTRIBUTE sljit_w SLJIT_CALL sljit_stack_resize(struct sljit_stac
}
aligned_new_limit = (new_limit + sljit_page_align) & ~sljit_page_align;
aligned_old_limit = (stack->limit + sljit_page_align) & ~sljit_page_align;
+ /* If madvise is available, we release the unnecessary space. */
+#if defined(POSIX_MADV_DONTNEED)
if (aligned_new_limit < aligned_old_limit)
-#if defined(__QNXNTO__) || defined(__LSB_VERSION__)
posix_madvise((void*)aligned_new_limit, aligned_old_limit - aligned_new_limit, POSIX_MADV_DONTNEED);
-#else
+#elif defined(MADV_DONTNEED)
+ if (aligned_new_limit < aligned_old_limit)
madvise((void*)aligned_new_limit, aligned_old_limit - aligned_new_limit, MADV_DONTNEED);
#endif
stack->limit = new_limit;
diff --git a/src/3rdparty/pcre/ucp.h b/src/3rdparty/pcre/ucp.h
index 34077fe07e..21039106e5 100644
--- a/src/3rdparty/pcre/ucp.h
+++ b/src/3rdparty/pcre/ucp.h
@@ -7,7 +7,11 @@
/* This file contains definitions of the property values that are returned by
the UCD access macros. New values that are added for new releases of Unicode
-should always be at the end of each enum, for backwards compatibility. */
+should always be at the end of each enum, for backwards compatibility.
+
+IMPORTANT: Note also that the specific numeric values of the enums have to be
+the same as the values that are generated by the maint/MultiStage2.py script,
+where the equivalent property descriptive names are listed in vectors. */
/* These are the general character categories. */
@@ -21,7 +25,7 @@ enum {
ucp_Z /* Separator */
};
-/* These are the particular character types. */
+/* These are the particular character categories. */
enum {
ucp_Cc, /* Control */
@@ -56,6 +60,26 @@ enum {
ucp_Zs /* Space separator */
};
+/* These are grapheme break properties. Note that the code for processing them
+assumes that the values are less than 16. If more values are added that take
+the number to 16 or more, the code will have to be rewritten. */
+
+enum {
+ ucp_gbCR, /* 0 */
+ ucp_gbLF, /* 1 */
+ ucp_gbControl, /* 2 */
+ ucp_gbExtend, /* 3 */
+ ucp_gbPrepend, /* 4 */
+ ucp_gbSpacingMark, /* 5 */
+ ucp_gbL, /* 6 Hangul syllable type L */
+ ucp_gbV, /* 7 Hangul syllable type V */
+ ucp_gbT, /* 8 Hangul syllable type T */
+ ucp_gbLV, /* 9 Hangul syllable type LV */
+ ucp_gbLVT, /* 10 Hangul syllable type LVT */
+ ucp_gbRegionalIndicator, /* 11 */
+ ucp_gbOther /* 12 */
+};
+
/* These are the script identifications. */
enum {
@@ -157,7 +181,15 @@ enum {
/* New for Unicode 6.0.0: */
ucp_Batak,
ucp_Brahmi,
- ucp_Mandaic
+ ucp_Mandaic,
+ /* New for Unicode 6.1.0: */
+ ucp_Chakma,
+ ucp_Meroitic_Cursive,
+ ucp_Meroitic_Hieroglyphs,
+ ucp_Miao,
+ ucp_Sharada,
+ ucp_Sora_Sompeng,
+ ucp_Takri
};
#endif
diff --git a/src/3rdparty/sha3/KeccakF-1600-32-rvk.macros b/src/3rdparty/sha3/KeccakF-1600-32-rvk.macros
new file mode 100755
index 0000000000..c0c9029873
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakF-1600-32-rvk.macros
@@ -0,0 +1,555 @@
+/*
+The Keccak sponge function, designed by Guido Bertoni, Joan Daemen,
+Michaël Peeters and Gilles Van Assche. For more information, feedback or
+questions, please refer to our website: http://keccak.noekeon.org/
+
+Implementation by Ronny Van Keer,
+hereby denoted as "the implementer".
+
+To the extent possible under law, the implementer has waived all copyright
+and related or neighboring rights to the source code in this file.
+http://creativecommons.org/publicdomain/zero/1.0/
+*/
+
+static const UINT32 KeccakF1600RoundConstants_int2[2*24] =
+{
+ 0x00000001UL, 0x00000000UL,
+ 0x00000000UL, 0x00000089UL,
+ 0x00000000UL, 0x8000008bUL,
+ 0x00000000UL, 0x80008080UL,
+ 0x00000001UL, 0x0000008bUL,
+ 0x00000001UL, 0x00008000UL,
+ 0x00000001UL, 0x80008088UL,
+ 0x00000001UL, 0x80000082UL,
+ 0x00000000UL, 0x0000000bUL,
+ 0x00000000UL, 0x0000000aUL,
+ 0x00000001UL, 0x00008082UL,
+ 0x00000000UL, 0x00008003UL,
+ 0x00000001UL, 0x0000808bUL,
+ 0x00000001UL, 0x8000000bUL,
+ 0x00000001UL, 0x8000008aUL,
+ 0x00000001UL, 0x80000081UL,
+ 0x00000000UL, 0x80000081UL,
+ 0x00000000UL, 0x80000008UL,
+ 0x00000000UL, 0x00000083UL,
+ 0x00000000UL, 0x80008003UL,
+ 0x00000001UL, 0x80008088UL,
+ 0x00000000UL, 0x80000088UL,
+ 0x00000001UL, 0x00008000UL,
+ 0x00000000UL, 0x80008082UL
+};
+
+#undef rounds
+
+#define rounds \
+{ \
+ UINT32 Da0, De0, Di0, Do0, Du0; \
+ UINT32 Da1, De1, Di1, Do1, Du1; \
+ UINT32 Ba, Be, Bi, Bo, Bu; \
+ UINT32 Aba0, Abe0, Abi0, Abo0, Abu0; \
+ UINT32 Aba1, Abe1, Abi1, Abo1, Abu1; \
+ UINT32 Aga0, Age0, Agi0, Ago0, Agu0; \
+ UINT32 Aga1, Age1, Agi1, Ago1, Agu1; \
+ UINT32 Aka0, Ake0, Aki0, Ako0, Aku0; \
+ UINT32 Aka1, Ake1, Aki1, Ako1, Aku1; \
+ UINT32 Ama0, Ame0, Ami0, Amo0, Amu0; \
+ UINT32 Ama1, Ame1, Ami1, Amo1, Amu1; \
+ UINT32 Asa0, Ase0, Asi0, Aso0, Asu0; \
+ UINT32 Asa1, Ase1, Asi1, Aso1, Asu1; \
+ UINT32 Cw, Cx, Cy, Cz; \
+ UINT32 Eba0, Ebe0, Ebi0, Ebo0, Ebu0; \
+ UINT32 Eba1, Ebe1, Ebi1, Ebo1, Ebu1; \
+ UINT32 Ega0, Ege0, Egi0, Ego0, Egu0; \
+ UINT32 Ega1, Ege1, Egi1, Ego1, Egu1; \
+ UINT32 Eka0, Eke0, Eki0, Eko0, Eku0; \
+ UINT32 Eka1, Eke1, Eki1, Eko1, Eku1; \
+ UINT32 Ema0, Eme0, Emi0, Emo0, Emu0; \
+ UINT32 Ema1, Eme1, Emi1, Emo1, Emu1; \
+ UINT32 Esa0, Ese0, Esi0, Eso0, Esu0; \
+ UINT32 Esa1, Ese1, Esi1, Eso1, Esu1; \
+ const UINT32 * pRoundConstants = KeccakF1600RoundConstants_int2; \
+ UINT32 i; \
+\
+ copyFromState(A, state) \
+\
+ for( i = 12; i != 0; --i ) { \
+ Cx = Abu0^Agu0^Aku0^Amu0^Asu0; \
+ Du1 = Abe1^Age1^Ake1^Ame1^Ase1; \
+ Da0 = Cx^ROL32(Du1, 1); \
+ Cz = Abu1^Agu1^Aku1^Amu1^Asu1; \
+ Du0 = Abe0^Age0^Ake0^Ame0^Ase0; \
+ Da1 = Cz^Du0; \
+\
+ Cw = Abi0^Agi0^Aki0^Ami0^Asi0; \
+ Do0 = Cw^ROL32(Cz, 1); \
+ Cy = Abi1^Agi1^Aki1^Ami1^Asi1; \
+ Do1 = Cy^Cx; \
+\
+ Cx = Aba0^Aga0^Aka0^Ama0^Asa0; \
+ De0 = Cx^ROL32(Cy, 1); \
+ Cz = Aba1^Aga1^Aka1^Ama1^Asa1; \
+ De1 = Cz^Cw; \
+\
+ Cy = Abo1^Ago1^Ako1^Amo1^Aso1; \
+ Di0 = Du0^ROL32(Cy, 1); \
+ Cw = Abo0^Ago0^Ako0^Amo0^Aso0; \
+ Di1 = Du1^Cw; \
+\
+ Du0 = Cw^ROL32(Cz, 1); \
+ Du1 = Cy^Cx; \
+\
+ Aba0 ^= Da0; \
+ Ba = Aba0; \
+ Age0 ^= De0; \
+ Be = ROL32(Age0, 22); \
+ Aki1 ^= Di1; \
+ Bi = ROL32(Aki1, 22); \
+ Amo1 ^= Do1; \
+ Bo = ROL32(Amo1, 11); \
+ Asu0 ^= Du0; \
+ Bu = ROL32(Asu0, 7); \
+ Eba0 = Ba ^((~Be)& Bi ) ^ *(pRoundConstants++); \
+ Ebe0 = Be ^((~Bi)& Bo ); \
+ Ebi0 = Bi ^((~Bo)& Bu ); \
+ Ebo0 = Bo ^((~Bu)& Ba ); \
+ Ebu0 = Bu ^((~Ba)& Be ); \
+\
+ Abo0 ^= Do0; \
+ Ba = ROL32(Abo0, 14); \
+ Agu0 ^= Du0; \
+ Be = ROL32(Agu0, 10); \
+ Aka1 ^= Da1; \
+ Bi = ROL32(Aka1, 2); \
+ Ame1 ^= De1; \
+ Bo = ROL32(Ame1, 23); \
+ Asi1 ^= Di1; \
+ Bu = ROL32(Asi1, 31); \
+ Ega0 = Ba ^((~Be)& Bi ); \
+ Ege0 = Be ^((~Bi)& Bo ); \
+ Egi0 = Bi ^((~Bo)& Bu ); \
+ Ego0 = Bo ^((~Bu)& Ba ); \
+ Egu0 = Bu ^((~Ba)& Be ); \
+\
+ Abe1 ^= De1; \
+ Ba = ROL32(Abe1, 1); \
+ Agi0 ^= Di0; \
+ Be = ROL32(Agi0, 3); \
+ Ako1 ^= Do1; \
+ Bi = ROL32(Ako1, 13); \
+ Amu0 ^= Du0; \
+ Bo = ROL32(Amu0, 4); \
+ Asa0 ^= Da0; \
+ Bu = ROL32(Asa0, 9); \
+ Eka0 = Ba ^((~Be)& Bi ); \
+ Eke0 = Be ^((~Bi)& Bo ); \
+ Eki0 = Bi ^((~Bo)& Bu ); \
+ Eko0 = Bo ^((~Bu)& Ba ); \
+ Eku0 = Bu ^((~Ba)& Be ); \
+\
+ Abu1 ^= Du1; \
+ Ba = ROL32(Abu1, 14); \
+ Aga0 ^= Da0; \
+ Be = ROL32(Aga0, 18); \
+ Ake0 ^= De0; \
+ Bi = ROL32(Ake0, 5); \
+ Ami1 ^= Di1; \
+ Bo = ROL32(Ami1, 8); \
+ Aso0 ^= Do0; \
+ Bu = ROL32(Aso0, 28); \
+ Ema0 = Ba ^((~Be)& Bi ); \
+ Eme0 = Be ^((~Bi)& Bo ); \
+ Emi0 = Bi ^((~Bo)& Bu ); \
+ Emo0 = Bo ^((~Bu)& Ba ); \
+ Emu0 = Bu ^((~Ba)& Be ); \
+\
+ Abi0 ^= Di0; \
+ Ba = ROL32(Abi0, 31); \
+ Ago1 ^= Do1; \
+ Be = ROL32(Ago1, 28); \
+ Aku1 ^= Du1; \
+ Bi = ROL32(Aku1, 20); \
+ Ama1 ^= Da1; \
+ Bo = ROL32(Ama1, 21); \
+ Ase0 ^= De0; \
+ Bu = ROL32(Ase0, 1); \
+ Esa0 = Ba ^((~Be)& Bi ); \
+ Ese0 = Be ^((~Bi)& Bo ); \
+ Esi0 = Bi ^((~Bo)& Bu ); \
+ Eso0 = Bo ^((~Bu)& Ba ); \
+ Esu0 = Bu ^((~Ba)& Be ); \
+\
+ Aba1 ^= Da1; \
+ Ba = Aba1; \
+ Age1 ^= De1; \
+ Be = ROL32(Age1, 22); \
+ Aki0 ^= Di0; \
+ Bi = ROL32(Aki0, 21); \
+ Amo0 ^= Do0; \
+ Bo = ROL32(Amo0, 10); \
+ Asu1 ^= Du1; \
+ Bu = ROL32(Asu1, 7); \
+ Eba1 = Ba ^((~Be)& Bi ); \
+ Eba1 ^= *(pRoundConstants++); \
+ Ebe1 = Be ^((~Bi)& Bo ); \
+ Ebi1 = Bi ^((~Bo)& Bu ); \
+ Ebo1 = Bo ^((~Bu)& Ba ); \
+ Ebu1 = Bu ^((~Ba)& Be ); \
+\
+ Abo1 ^= Do1; \
+ Ba = ROL32(Abo1, 14); \
+ Agu1 ^= Du1; \
+ Be = ROL32(Agu1, 10); \
+ Aka0 ^= Da0; \
+ Bi = ROL32(Aka0, 1); \
+ Ame0 ^= De0; \
+ Bo = ROL32(Ame0, 22); \
+ Asi0 ^= Di0; \
+ Bu = ROL32(Asi0, 30); \
+ Ega1 = Ba ^((~Be)& Bi ); \
+ Ege1 = Be ^((~Bi)& Bo ); \
+ Egi1 = Bi ^((~Bo)& Bu ); \
+ Ego1 = Bo ^((~Bu)& Ba ); \
+ Egu1 = Bu ^((~Ba)& Be ); \
+\
+ Abe0 ^= De0; \
+ Ba = Abe0; \
+ Agi1 ^= Di1; \
+ Be = ROL32(Agi1, 3); \
+ Ako0 ^= Do0; \
+ Bi = ROL32(Ako0, 12); \
+ Amu1 ^= Du1; \
+ Bo = ROL32(Amu1, 4); \
+ Asa1 ^= Da1; \
+ Bu = ROL32(Asa1, 9); \
+ Eka1 = Ba ^((~Be)& Bi ); \
+ Eke1 = Be ^((~Bi)& Bo ); \
+ Eki1 = Bi ^((~Bo)& Bu ); \
+ Eko1 = Bo ^((~Bu)& Ba ); \
+ Eku1 = Bu ^((~Ba)& Be ); \
+\
+ Abu0 ^= Du0; \
+ Ba = ROL32(Abu0, 13); \
+ Aga1 ^= Da1; \
+ Be = ROL32(Aga1, 18); \
+ Ake1 ^= De1; \
+ Bi = ROL32(Ake1, 5); \
+ Ami0 ^= Di0; \
+ Bo = ROL32(Ami0, 7); \
+ Aso1 ^= Do1; \
+ Bu = ROL32(Aso1, 28); \
+ Ema1 = Ba ^((~Be)& Bi ); \
+ Eme1 = Be ^((~Bi)& Bo ); \
+ Emi1 = Bi ^((~Bo)& Bu ); \
+ Emo1 = Bo ^((~Bu)& Ba ); \
+ Emu1 = Bu ^((~Ba)& Be ); \
+\
+ Abi1 ^= Di1; \
+ Ba = ROL32(Abi1, 31); \
+ Ago0 ^= Do0; \
+ Be = ROL32(Ago0, 27); \
+ Aku0 ^= Du0; \
+ Bi = ROL32(Aku0, 19); \
+ Ama0 ^= Da0; \
+ Bo = ROL32(Ama0, 20); \
+ Ase1 ^= De1; \
+ Bu = ROL32(Ase1, 1); \
+ Esa1 = Ba ^((~Be)& Bi ); \
+ Ese1 = Be ^((~Bi)& Bo ); \
+ Esi1 = Bi ^((~Bo)& Bu ); \
+ Eso1 = Bo ^((~Bu)& Ba ); \
+ Esu1 = Bu ^((~Ba)& Be ); \
+\
+ Cx = Ebu0^Egu0^Eku0^Emu0^Esu0; \
+ Du1 = Ebe1^Ege1^Eke1^Eme1^Ese1; \
+ Da0 = Cx^ROL32(Du1, 1); \
+ Cz = Ebu1^Egu1^Eku1^Emu1^Esu1; \
+ Du0 = Ebe0^Ege0^Eke0^Eme0^Ese0; \
+ Da1 = Cz^Du0; \
+\
+ Cw = Ebi0^Egi0^Eki0^Emi0^Esi0; \
+ Do0 = Cw^ROL32(Cz, 1); \
+ Cy = Ebi1^Egi1^Eki1^Emi1^Esi1; \
+ Do1 = Cy^Cx; \
+\
+ Cx = Eba0^Ega0^Eka0^Ema0^Esa0; \
+ De0 = Cx^ROL32(Cy, 1); \
+ Cz = Eba1^Ega1^Eka1^Ema1^Esa1; \
+ De1 = Cz^Cw; \
+\
+ Cy = Ebo1^Ego1^Eko1^Emo1^Eso1; \
+ Di0 = Du0^ROL32(Cy, 1); \
+ Cw = Ebo0^Ego0^Eko0^Emo0^Eso0; \
+ Di1 = Du1^Cw; \
+\
+ Du0 = Cw^ROL32(Cz, 1); \
+ Du1 = Cy^Cx; \
+\
+ Eba0 ^= Da0; \
+ Ba = Eba0; \
+ Ege0 ^= De0; \
+ Be = ROL32(Ege0, 22); \
+ Eki1 ^= Di1; \
+ Bi = ROL32(Eki1, 22); \
+ Emo1 ^= Do1; \
+ Bo = ROL32(Emo1, 11); \
+ Esu0 ^= Du0; \
+ Bu = ROL32(Esu0, 7); \
+ Aba0 = Ba ^((~Be)& Bi ); \
+ Aba0 ^= *(pRoundConstants++); \
+ Abe0 = Be ^((~Bi)& Bo ); \
+ Abi0 = Bi ^((~Bo)& Bu ); \
+ Abo0 = Bo ^((~Bu)& Ba ); \
+ Abu0 = Bu ^((~Ba)& Be ); \
+\
+ Ebo0 ^= Do0; \
+ Ba = ROL32(Ebo0, 14); \
+ Egu0 ^= Du0; \
+ Be = ROL32(Egu0, 10); \
+ Eka1 ^= Da1; \
+ Bi = ROL32(Eka1, 2); \
+ Eme1 ^= De1; \
+ Bo = ROL32(Eme1, 23); \
+ Esi1 ^= Di1; \
+ Bu = ROL32(Esi1, 31); \
+ Aga0 = Ba ^((~Be)& Bi ); \
+ Age0 = Be ^((~Bi)& Bo ); \
+ Agi0 = Bi ^((~Bo)& Bu ); \
+ Ago0 = Bo ^((~Bu)& Ba ); \
+ Agu0 = Bu ^((~Ba)& Be ); \
+\
+ Ebe1 ^= De1; \
+ Ba = ROL32(Ebe1, 1); \
+ Egi0 ^= Di0; \
+ Be = ROL32(Egi0, 3); \
+ Eko1 ^= Do1; \
+ Bi = ROL32(Eko1, 13); \
+ Emu0 ^= Du0; \
+ Bo = ROL32(Emu0, 4); \
+ Esa0 ^= Da0; \
+ Bu = ROL32(Esa0, 9); \
+ Aka0 = Ba ^((~Be)& Bi ); \
+ Ake0 = Be ^((~Bi)& Bo ); \
+ Aki0 = Bi ^((~Bo)& Bu ); \
+ Ako0 = Bo ^((~Bu)& Ba ); \
+ Aku0 = Bu ^((~Ba)& Be ); \
+\
+ Ebu1 ^= Du1; \
+ Ba = ROL32(Ebu1, 14); \
+ Ega0 ^= Da0; \
+ Be = ROL32(Ega0, 18); \
+ Eke0 ^= De0; \
+ Bi = ROL32(Eke0, 5); \
+ Emi1 ^= Di1; \
+ Bo = ROL32(Emi1, 8); \
+ Eso0 ^= Do0; \
+ Bu = ROL32(Eso0, 28); \
+ Ama0 = Ba ^((~Be)& Bi ); \
+ Ame0 = Be ^((~Bi)& Bo ); \
+ Ami0 = Bi ^((~Bo)& Bu ); \
+ Amo0 = Bo ^((~Bu)& Ba ); \
+ Amu0 = Bu ^((~Ba)& Be ); \
+\
+ Ebi0 ^= Di0; \
+ Ba = ROL32(Ebi0, 31); \
+ Ego1 ^= Do1; \
+ Be = ROL32(Ego1, 28); \
+ Eku1 ^= Du1; \
+ Bi = ROL32(Eku1, 20); \
+ Ema1 ^= Da1; \
+ Bo = ROL32(Ema1, 21); \
+ Ese0 ^= De0; \
+ Bu = ROL32(Ese0, 1); \
+ Asa0 = Ba ^((~Be)& Bi ); \
+ Ase0 = Be ^((~Bi)& Bo ); \
+ Asi0 = Bi ^((~Bo)& Bu ); \
+ Aso0 = Bo ^((~Bu)& Ba ); \
+ Asu0 = Bu ^((~Ba)& Be ); \
+\
+ Eba1 ^= Da1; \
+ Ba = Eba1; \
+ Ege1 ^= De1; \
+ Be = ROL32(Ege1, 22); \
+ Eki0 ^= Di0; \
+ Bi = ROL32(Eki0, 21); \
+ Emo0 ^= Do0; \
+ Bo = ROL32(Emo0, 10); \
+ Esu1 ^= Du1; \
+ Bu = ROL32(Esu1, 7); \
+ Aba1 = Ba ^((~Be)& Bi ); \
+ Aba1 ^= *(pRoundConstants++); \
+ Abe1 = Be ^((~Bi)& Bo ); \
+ Abi1 = Bi ^((~Bo)& Bu ); \
+ Abo1 = Bo ^((~Bu)& Ba ); \
+ Abu1 = Bu ^((~Ba)& Be ); \
+\
+ Ebo1 ^= Do1; \
+ Ba = ROL32(Ebo1, 14); \
+ Egu1 ^= Du1; \
+ Be = ROL32(Egu1, 10); \
+ Eka0 ^= Da0; \
+ Bi = ROL32(Eka0, 1); \
+ Eme0 ^= De0; \
+ Bo = ROL32(Eme0, 22); \
+ Esi0 ^= Di0; \
+ Bu = ROL32(Esi0, 30); \
+ Aga1 = Ba ^((~Be)& Bi ); \
+ Age1 = Be ^((~Bi)& Bo ); \
+ Agi1 = Bi ^((~Bo)& Bu ); \
+ Ago1 = Bo ^((~Bu)& Ba ); \
+ Agu1 = Bu ^((~Ba)& Be ); \
+\
+ Ebe0 ^= De0; \
+ Ba = Ebe0; \
+ Egi1 ^= Di1; \
+ Be = ROL32(Egi1, 3); \
+ Eko0 ^= Do0; \
+ Bi = ROL32(Eko0, 12); \
+ Emu1 ^= Du1; \
+ Bo = ROL32(Emu1, 4); \
+ Esa1 ^= Da1; \
+ Bu = ROL32(Esa1, 9); \
+ Aka1 = Ba ^((~Be)& Bi ); \
+ Ake1 = Be ^((~Bi)& Bo ); \
+ Aki1 = Bi ^((~Bo)& Bu ); \
+ Ako1 = Bo ^((~Bu)& Ba ); \
+ Aku1 = Bu ^((~Ba)& Be ); \
+\
+ Ebu0 ^= Du0; \
+ Ba = ROL32(Ebu0, 13); \
+ Ega1 ^= Da1; \
+ Be = ROL32(Ega1, 18); \
+ Eke1 ^= De1; \
+ Bi = ROL32(Eke1, 5); \
+ Emi0 ^= Di0; \
+ Bo = ROL32(Emi0, 7); \
+ Eso1 ^= Do1; \
+ Bu = ROL32(Eso1, 28); \
+ Ama1 = Ba ^((~Be)& Bi ); \
+ Ame1 = Be ^((~Bi)& Bo ); \
+ Ami1 = Bi ^((~Bo)& Bu ); \
+ Amo1 = Bo ^((~Bu)& Ba ); \
+ Amu1 = Bu ^((~Ba)& Be ); \
+\
+ Ebi1 ^= Di1; \
+ Ba = ROL32(Ebi1, 31); \
+ Ego0 ^= Do0; \
+ Be = ROL32(Ego0, 27); \
+ Eku0 ^= Du0; \
+ Bi = ROL32(Eku0, 19); \
+ Ema0 ^= Da0; \
+ Bo = ROL32(Ema0, 20); \
+ Ese1 ^= De1; \
+ Bu = ROL32(Ese1, 1); \
+ Asa1 = Ba ^((~Be)& Bi ); \
+ Ase1 = Be ^((~Bi)& Bo ); \
+ Asi1 = Bi ^((~Bo)& Bu ); \
+ Aso1 = Bo ^((~Bu)& Ba ); \
+ Asu1 = Bu ^((~Ba)& Be ); \
+ } \
+ copyToState(state, A) \
+}
+
+#define copyFromState(X, state) \
+ X##ba0 = state[ 0]; \
+ X##ba1 = state[ 1]; \
+ X##be0 = state[ 2]; \
+ X##be1 = state[ 3]; \
+ X##bi0 = state[ 4]; \
+ X##bi1 = state[ 5]; \
+ X##bo0 = state[ 6]; \
+ X##bo1 = state[ 7]; \
+ X##bu0 = state[ 8]; \
+ X##bu1 = state[ 9]; \
+ X##ga0 = state[10]; \
+ X##ga1 = state[11]; \
+ X##ge0 = state[12]; \
+ X##ge1 = state[13]; \
+ X##gi0 = state[14]; \
+ X##gi1 = state[15]; \
+ X##go0 = state[16]; \
+ X##go1 = state[17]; \
+ X##gu0 = state[18]; \
+ X##gu1 = state[19]; \
+ X##ka0 = state[20]; \
+ X##ka1 = state[21]; \
+ X##ke0 = state[22]; \
+ X##ke1 = state[23]; \
+ X##ki0 = state[24]; \
+ X##ki1 = state[25]; \
+ X##ko0 = state[26]; \
+ X##ko1 = state[27]; \
+ X##ku0 = state[28]; \
+ X##ku1 = state[29]; \
+ X##ma0 = state[30]; \
+ X##ma1 = state[31]; \
+ X##me0 = state[32]; \
+ X##me1 = state[33]; \
+ X##mi0 = state[34]; \
+ X##mi1 = state[35]; \
+ X##mo0 = state[36]; \
+ X##mo1 = state[37]; \
+ X##mu0 = state[38]; \
+ X##mu1 = state[39]; \
+ X##sa0 = state[40]; \
+ X##sa1 = state[41]; \
+ X##se0 = state[42]; \
+ X##se1 = state[43]; \
+ X##si0 = state[44]; \
+ X##si1 = state[45]; \
+ X##so0 = state[46]; \
+ X##so1 = state[47]; \
+ X##su0 = state[48]; \
+ X##su1 = state[49]; \
+
+#define copyToState(state, X) \
+ state[ 0] = X##ba0; \
+ state[ 1] = X##ba1; \
+ state[ 2] = X##be0; \
+ state[ 3] = X##be1; \
+ state[ 4] = X##bi0; \
+ state[ 5] = X##bi1; \
+ state[ 6] = X##bo0; \
+ state[ 7] = X##bo1; \
+ state[ 8] = X##bu0; \
+ state[ 9] = X##bu1; \
+ state[10] = X##ga0; \
+ state[11] = X##ga1; \
+ state[12] = X##ge0; \
+ state[13] = X##ge1; \
+ state[14] = X##gi0; \
+ state[15] = X##gi1; \
+ state[16] = X##go0; \
+ state[17] = X##go1; \
+ state[18] = X##gu0; \
+ state[19] = X##gu1; \
+ state[20] = X##ka0; \
+ state[21] = X##ka1; \
+ state[22] = X##ke0; \
+ state[23] = X##ke1; \
+ state[24] = X##ki0; \
+ state[25] = X##ki1; \
+ state[26] = X##ko0; \
+ state[27] = X##ko1; \
+ state[28] = X##ku0; \
+ state[29] = X##ku1; \
+ state[30] = X##ma0; \
+ state[31] = X##ma1; \
+ state[32] = X##me0; \
+ state[33] = X##me1; \
+ state[34] = X##mi0; \
+ state[35] = X##mi1; \
+ state[36] = X##mo0; \
+ state[37] = X##mo1; \
+ state[38] = X##mu0; \
+ state[39] = X##mu1; \
+ state[40] = X##sa0; \
+ state[41] = X##sa1; \
+ state[42] = X##se0; \
+ state[43] = X##se1; \
+ state[44] = X##si0; \
+ state[45] = X##si1; \
+ state[46] = X##so0; \
+ state[47] = X##so1; \
+ state[48] = X##su0; \
+ state[49] = X##su1; \
+
diff --git a/src/3rdparty/sha3/KeccakF-1600-32.macros b/src/3rdparty/sha3/KeccakF-1600-32.macros
new file mode 100755
index 0000000000..9ade600067
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakF-1600-32.macros
@@ -0,0 +1,26 @@
+/*
+The Keccak sponge function, designed by Guido Bertoni, Joan Daemen,
+Michaël Peeters and Gilles Van Assche. For more information, feedback or
+questions, please refer to our website: http://keccak.noekeon.org/
+
+Implementation by the designers,
+hereby denoted as "the implementer".
+
+To the extent possible under law, the implementer has waived all copyright
+and related or neighboring rights to the source code in this file.
+http://creativecommons.org/publicdomain/zero/1.0/
+*/
+
+#ifdef UseSchedule
+ #if (UseSchedule == 1)
+ #include "KeccakF-1600-32-s1.macros"
+ #elif (UseSchedule == 2)
+ #include "KeccakF-1600-32-s2.macros"
+ #elif (UseSchedule == 3)
+ #include "KeccakF-1600-32-rvk.macros"
+ #else
+ #error "This schedule is not supported."
+ #endif
+#else
+ #include "KeccakF-1600-32-s1.macros"
+#endif
diff --git a/src/3rdparty/sha3/KeccakF-1600-64.macros b/src/3rdparty/sha3/KeccakF-1600-64.macros
new file mode 100755
index 0000000000..0c20bca40f
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakF-1600-64.macros
@@ -0,0 +1,728 @@
+/*
+Code automatically generated by KeccakTools!
+
+The Keccak sponge function, designed by Guido Bertoni, Joan Daemen,
+Michaël Peeters and Gilles Van Assche. For more information, feedback or
+questions, please refer to our website: http://keccak.noekeon.org/
+
+Implementation by the designers,
+hereby denoted as "the implementer".
+
+To the extent possible under law, the implementer has waived all copyright
+and related or neighboring rights to the source code in this file.
+http://creativecommons.org/publicdomain/zero/1.0/
+*/
+
+#define declareABCDE \
+ UINT64 Aba, Abe, Abi, Abo, Abu; \
+ UINT64 Aga, Age, Agi, Ago, Agu; \
+ UINT64 Aka, Ake, Aki, Ako, Aku; \
+ UINT64 Ama, Ame, Ami, Amo, Amu; \
+ UINT64 Asa, Ase, Asi, Aso, Asu; \
+ UINT64 Bba, Bbe, Bbi, Bbo, Bbu; \
+ UINT64 Bga, Bge, Bgi, Bgo, Bgu; \
+ UINT64 Bka, Bke, Bki, Bko, Bku; \
+ UINT64 Bma, Bme, Bmi, Bmo, Bmu; \
+ UINT64 Bsa, Bse, Bsi, Bso, Bsu; \
+ UINT64 Ca, Ce, Ci, Co, Cu; \
+ UINT64 Da, De, Di, Do, Du; \
+ UINT64 Eba, Ebe, Ebi, Ebo, Ebu; \
+ UINT64 Ega, Ege, Egi, Ego, Egu; \
+ UINT64 Eka, Eke, Eki, Eko, Eku; \
+ UINT64 Ema, Eme, Emi, Emo, Emu; \
+ UINT64 Esa, Ese, Esi, Eso, Esu; \
+
+#define prepareTheta \
+ Ca = Aba^Aga^Aka^Ama^Asa; \
+ Ce = Abe^Age^Ake^Ame^Ase; \
+ Ci = Abi^Agi^Aki^Ami^Asi; \
+ Co = Abo^Ago^Ako^Amo^Aso; \
+ Cu = Abu^Agu^Aku^Amu^Asu; \
+
+#ifdef UseBebigokimisa
+// --- Code for round, with prepare-theta (lane complementing pattern 'bebigokimisa')
+// --- 64-bit lanes mapped to 64-bit words
+#define thetaRhoPiChiIotaPrepareTheta(i, A, E) \
+ Da = Cu^ROL64(Ce, 1); \
+ De = Ca^ROL64(Ci, 1); \
+ Di = Ce^ROL64(Co, 1); \
+ Do = Ci^ROL64(Cu, 1); \
+ Du = Co^ROL64(Ca, 1); \
+\
+ A##ba ^= Da; \
+ Bba = A##ba; \
+ A##ge ^= De; \
+ Bbe = ROL64(A##ge, 44); \
+ A##ki ^= Di; \
+ Bbi = ROL64(A##ki, 43); \
+ A##mo ^= Do; \
+ Bbo = ROL64(A##mo, 21); \
+ A##su ^= Du; \
+ Bbu = ROL64(A##su, 14); \
+ E##ba = Bba ^( Bbe | Bbi ); \
+ E##ba ^= KeccakF1600RoundConstants[i]; \
+ Ca = E##ba; \
+ E##be = Bbe ^((~Bbi)| Bbo ); \
+ Ce = E##be; \
+ E##bi = Bbi ^( Bbo & Bbu ); \
+ Ci = E##bi; \
+ E##bo = Bbo ^( Bbu | Bba ); \
+ Co = E##bo; \
+ E##bu = Bbu ^( Bba & Bbe ); \
+ Cu = E##bu; \
+\
+ A##bo ^= Do; \
+ Bga = ROL64(A##bo, 28); \
+ A##gu ^= Du; \
+ Bge = ROL64(A##gu, 20); \
+ A##ka ^= Da; \
+ Bgi = ROL64(A##ka, 3); \
+ A##me ^= De; \
+ Bgo = ROL64(A##me, 45); \
+ A##si ^= Di; \
+ Bgu = ROL64(A##si, 61); \
+ E##ga = Bga ^( Bge | Bgi ); \
+ Ca ^= E##ga; \
+ E##ge = Bge ^( Bgi & Bgo ); \
+ Ce ^= E##ge; \
+ E##gi = Bgi ^( Bgo |(~Bgu)); \
+ Ci ^= E##gi; \
+ E##go = Bgo ^( Bgu | Bga ); \
+ Co ^= E##go; \
+ E##gu = Bgu ^( Bga & Bge ); \
+ Cu ^= E##gu; \
+\
+ A##be ^= De; \
+ Bka = ROL64(A##be, 1); \
+ A##gi ^= Di; \
+ Bke = ROL64(A##gi, 6); \
+ A##ko ^= Do; \
+ Bki = ROL64(A##ko, 25); \
+ A##mu ^= Du; \
+ Bko = ROL64(A##mu, 8); \
+ A##sa ^= Da; \
+ Bku = ROL64(A##sa, 18); \
+ E##ka = Bka ^( Bke | Bki ); \
+ Ca ^= E##ka; \
+ E##ke = Bke ^( Bki & Bko ); \
+ Ce ^= E##ke; \
+ E##ki = Bki ^((~Bko)& Bku ); \
+ Ci ^= E##ki; \
+ E##ko = (~Bko)^( Bku | Bka ); \
+ Co ^= E##ko; \
+ E##ku = Bku ^( Bka & Bke ); \
+ Cu ^= E##ku; \
+\
+ A##bu ^= Du; \
+ Bma = ROL64(A##bu, 27); \
+ A##ga ^= Da; \
+ Bme = ROL64(A##ga, 36); \
+ A##ke ^= De; \
+ Bmi = ROL64(A##ke, 10); \
+ A##mi ^= Di; \
+ Bmo = ROL64(A##mi, 15); \
+ A##so ^= Do; \
+ Bmu = ROL64(A##so, 56); \
+ E##ma = Bma ^( Bme & Bmi ); \
+ Ca ^= E##ma; \
+ E##me = Bme ^( Bmi | Bmo ); \
+ Ce ^= E##me; \
+ E##mi = Bmi ^((~Bmo)| Bmu ); \
+ Ci ^= E##mi; \
+ E##mo = (~Bmo)^( Bmu & Bma ); \
+ Co ^= E##mo; \
+ E##mu = Bmu ^( Bma | Bme ); \
+ Cu ^= E##mu; \
+\
+ A##bi ^= Di; \
+ Bsa = ROL64(A##bi, 62); \
+ A##go ^= Do; \
+ Bse = ROL64(A##go, 55); \
+ A##ku ^= Du; \
+ Bsi = ROL64(A##ku, 39); \
+ A##ma ^= Da; \
+ Bso = ROL64(A##ma, 41); \
+ A##se ^= De; \
+ Bsu = ROL64(A##se, 2); \
+ E##sa = Bsa ^((~Bse)& Bsi ); \
+ Ca ^= E##sa; \
+ E##se = (~Bse)^( Bsi | Bso ); \
+ Ce ^= E##se; \
+ E##si = Bsi ^( Bso & Bsu ); \
+ Ci ^= E##si; \
+ E##so = Bso ^( Bsu | Bsa ); \
+ Co ^= E##so; \
+ E##su = Bsu ^( Bsa & Bse ); \
+ Cu ^= E##su; \
+\
+
+// --- Code for round (lane complementing pattern 'bebigokimisa')
+// --- 64-bit lanes mapped to 64-bit words
+#define thetaRhoPiChiIota(i, A, E) \
+ Da = Cu^ROL64(Ce, 1); \
+ De = Ca^ROL64(Ci, 1); \
+ Di = Ce^ROL64(Co, 1); \
+ Do = Ci^ROL64(Cu, 1); \
+ Du = Co^ROL64(Ca, 1); \
+\
+ A##ba ^= Da; \
+ Bba = A##ba; \
+ A##ge ^= De; \
+ Bbe = ROL64(A##ge, 44); \
+ A##ki ^= Di; \
+ Bbi = ROL64(A##ki, 43); \
+ A##mo ^= Do; \
+ Bbo = ROL64(A##mo, 21); \
+ A##su ^= Du; \
+ Bbu = ROL64(A##su, 14); \
+ E##ba = Bba ^( Bbe | Bbi ); \
+ E##ba ^= KeccakF1600RoundConstants[i]; \
+ E##be = Bbe ^((~Bbi)| Bbo ); \
+ E##bi = Bbi ^( Bbo & Bbu ); \
+ E##bo = Bbo ^( Bbu | Bba ); \
+ E##bu = Bbu ^( Bba & Bbe ); \
+\
+ A##bo ^= Do; \
+ Bga = ROL64(A##bo, 28); \
+ A##gu ^= Du; \
+ Bge = ROL64(A##gu, 20); \
+ A##ka ^= Da; \
+ Bgi = ROL64(A##ka, 3); \
+ A##me ^= De; \
+ Bgo = ROL64(A##me, 45); \
+ A##si ^= Di; \
+ Bgu = ROL64(A##si, 61); \
+ E##ga = Bga ^( Bge | Bgi ); \
+ E##ge = Bge ^( Bgi & Bgo ); \
+ E##gi = Bgi ^( Bgo |(~Bgu)); \
+ E##go = Bgo ^( Bgu | Bga ); \
+ E##gu = Bgu ^( Bga & Bge ); \
+\
+ A##be ^= De; \
+ Bka = ROL64(A##be, 1); \
+ A##gi ^= Di; \
+ Bke = ROL64(A##gi, 6); \
+ A##ko ^= Do; \
+ Bki = ROL64(A##ko, 25); \
+ A##mu ^= Du; \
+ Bko = ROL64(A##mu, 8); \
+ A##sa ^= Da; \
+ Bku = ROL64(A##sa, 18); \
+ E##ka = Bka ^( Bke | Bki ); \
+ E##ke = Bke ^( Bki & Bko ); \
+ E##ki = Bki ^((~Bko)& Bku ); \
+ E##ko = (~Bko)^( Bku | Bka ); \
+ E##ku = Bku ^( Bka & Bke ); \
+\
+ A##bu ^= Du; \
+ Bma = ROL64(A##bu, 27); \
+ A##ga ^= Da; \
+ Bme = ROL64(A##ga, 36); \
+ A##ke ^= De; \
+ Bmi = ROL64(A##ke, 10); \
+ A##mi ^= Di; \
+ Bmo = ROL64(A##mi, 15); \
+ A##so ^= Do; \
+ Bmu = ROL64(A##so, 56); \
+ E##ma = Bma ^( Bme & Bmi ); \
+ E##me = Bme ^( Bmi | Bmo ); \
+ E##mi = Bmi ^((~Bmo)| Bmu ); \
+ E##mo = (~Bmo)^( Bmu & Bma ); \
+ E##mu = Bmu ^( Bma | Bme ); \
+\
+ A##bi ^= Di; \
+ Bsa = ROL64(A##bi, 62); \
+ A##go ^= Do; \
+ Bse = ROL64(A##go, 55); \
+ A##ku ^= Du; \
+ Bsi = ROL64(A##ku, 39); \
+ A##ma ^= Da; \
+ Bso = ROL64(A##ma, 41); \
+ A##se ^= De; \
+ Bsu = ROL64(A##se, 2); \
+ E##sa = Bsa ^((~Bse)& Bsi ); \
+ E##se = (~Bse)^( Bsi | Bso ); \
+ E##si = Bsi ^( Bso & Bsu ); \
+ E##so = Bso ^( Bsu | Bsa ); \
+ E##su = Bsu ^( Bsa & Bse ); \
+\
+
+#else // UseBebigokimisa
+// --- Code for round, with prepare-theta
+// --- 64-bit lanes mapped to 64-bit words
+#define thetaRhoPiChiIotaPrepareTheta(i, A, E) \
+ Da = Cu^ROL64(Ce, 1); \
+ De = Ca^ROL64(Ci, 1); \
+ Di = Ce^ROL64(Co, 1); \
+ Do = Ci^ROL64(Cu, 1); \
+ Du = Co^ROL64(Ca, 1); \
+\
+ A##ba ^= Da; \
+ Bba = A##ba; \
+ A##ge ^= De; \
+ Bbe = ROL64(A##ge, 44); \
+ A##ki ^= Di; \
+ Bbi = ROL64(A##ki, 43); \
+ A##mo ^= Do; \
+ Bbo = ROL64(A##mo, 21); \
+ A##su ^= Du; \
+ Bbu = ROL64(A##su, 14); \
+ E##ba = Bba ^((~Bbe)& Bbi ); \
+ E##ba ^= KeccakF1600RoundConstants[i]; \
+ Ca = E##ba; \
+ E##be = Bbe ^((~Bbi)& Bbo ); \
+ Ce = E##be; \
+ E##bi = Bbi ^((~Bbo)& Bbu ); \
+ Ci = E##bi; \
+ E##bo = Bbo ^((~Bbu)& Bba ); \
+ Co = E##bo; \
+ E##bu = Bbu ^((~Bba)& Bbe ); \
+ Cu = E##bu; \
+\
+ A##bo ^= Do; \
+ Bga = ROL64(A##bo, 28); \
+ A##gu ^= Du; \
+ Bge = ROL64(A##gu, 20); \
+ A##ka ^= Da; \
+ Bgi = ROL64(A##ka, 3); \
+ A##me ^= De; \
+ Bgo = ROL64(A##me, 45); \
+ A##si ^= Di; \
+ Bgu = ROL64(A##si, 61); \
+ E##ga = Bga ^((~Bge)& Bgi ); \
+ Ca ^= E##ga; \
+ E##ge = Bge ^((~Bgi)& Bgo ); \
+ Ce ^= E##ge; \
+ E##gi = Bgi ^((~Bgo)& Bgu ); \
+ Ci ^= E##gi; \
+ E##go = Bgo ^((~Bgu)& Bga ); \
+ Co ^= E##go; \
+ E##gu = Bgu ^((~Bga)& Bge ); \
+ Cu ^= E##gu; \
+\
+ A##be ^= De; \
+ Bka = ROL64(A##be, 1); \
+ A##gi ^= Di; \
+ Bke = ROL64(A##gi, 6); \
+ A##ko ^= Do; \
+ Bki = ROL64(A##ko, 25); \
+ A##mu ^= Du; \
+ Bko = ROL64(A##mu, 8); \
+ A##sa ^= Da; \
+ Bku = ROL64(A##sa, 18); \
+ E##ka = Bka ^((~Bke)& Bki ); \
+ Ca ^= E##ka; \
+ E##ke = Bke ^((~Bki)& Bko ); \
+ Ce ^= E##ke; \
+ E##ki = Bki ^((~Bko)& Bku ); \
+ Ci ^= E##ki; \
+ E##ko = Bko ^((~Bku)& Bka ); \
+ Co ^= E##ko; \
+ E##ku = Bku ^((~Bka)& Bke ); \
+ Cu ^= E##ku; \
+\
+ A##bu ^= Du; \
+ Bma = ROL64(A##bu, 27); \
+ A##ga ^= Da; \
+ Bme = ROL64(A##ga, 36); \
+ A##ke ^= De; \
+ Bmi = ROL64(A##ke, 10); \
+ A##mi ^= Di; \
+ Bmo = ROL64(A##mi, 15); \
+ A##so ^= Do; \
+ Bmu = ROL64(A##so, 56); \
+ E##ma = Bma ^((~Bme)& Bmi ); \
+ Ca ^= E##ma; \
+ E##me = Bme ^((~Bmi)& Bmo ); \
+ Ce ^= E##me; \
+ E##mi = Bmi ^((~Bmo)& Bmu ); \
+ Ci ^= E##mi; \
+ E##mo = Bmo ^((~Bmu)& Bma ); \
+ Co ^= E##mo; \
+ E##mu = Bmu ^((~Bma)& Bme ); \
+ Cu ^= E##mu; \
+\
+ A##bi ^= Di; \
+ Bsa = ROL64(A##bi, 62); \
+ A##go ^= Do; \
+ Bse = ROL64(A##go, 55); \
+ A##ku ^= Du; \
+ Bsi = ROL64(A##ku, 39); \
+ A##ma ^= Da; \
+ Bso = ROL64(A##ma, 41); \
+ A##se ^= De; \
+ Bsu = ROL64(A##se, 2); \
+ E##sa = Bsa ^((~Bse)& Bsi ); \
+ Ca ^= E##sa; \
+ E##se = Bse ^((~Bsi)& Bso ); \
+ Ce ^= E##se; \
+ E##si = Bsi ^((~Bso)& Bsu ); \
+ Ci ^= E##si; \
+ E##so = Bso ^((~Bsu)& Bsa ); \
+ Co ^= E##so; \
+ E##su = Bsu ^((~Bsa)& Bse ); \
+ Cu ^= E##su; \
+\
+
+// --- Code for round
+// --- 64-bit lanes mapped to 64-bit words
+#define thetaRhoPiChiIota(i, A, E) \
+ Da = Cu^ROL64(Ce, 1); \
+ De = Ca^ROL64(Ci, 1); \
+ Di = Ce^ROL64(Co, 1); \
+ Do = Ci^ROL64(Cu, 1); \
+ Du = Co^ROL64(Ca, 1); \
+\
+ A##ba ^= Da; \
+ Bba = A##ba; \
+ A##ge ^= De; \
+ Bbe = ROL64(A##ge, 44); \
+ A##ki ^= Di; \
+ Bbi = ROL64(A##ki, 43); \
+ A##mo ^= Do; \
+ Bbo = ROL64(A##mo, 21); \
+ A##su ^= Du; \
+ Bbu = ROL64(A##su, 14); \
+ E##ba = Bba ^((~Bbe)& Bbi ); \
+ E##ba ^= KeccakF1600RoundConstants[i]; \
+ E##be = Bbe ^((~Bbi)& Bbo ); \
+ E##bi = Bbi ^((~Bbo)& Bbu ); \
+ E##bo = Bbo ^((~Bbu)& Bba ); \
+ E##bu = Bbu ^((~Bba)& Bbe ); \
+\
+ A##bo ^= Do; \
+ Bga = ROL64(A##bo, 28); \
+ A##gu ^= Du; \
+ Bge = ROL64(A##gu, 20); \
+ A##ka ^= Da; \
+ Bgi = ROL64(A##ka, 3); \
+ A##me ^= De; \
+ Bgo = ROL64(A##me, 45); \
+ A##si ^= Di; \
+ Bgu = ROL64(A##si, 61); \
+ E##ga = Bga ^((~Bge)& Bgi ); \
+ E##ge = Bge ^((~Bgi)& Bgo ); \
+ E##gi = Bgi ^((~Bgo)& Bgu ); \
+ E##go = Bgo ^((~Bgu)& Bga ); \
+ E##gu = Bgu ^((~Bga)& Bge ); \
+\
+ A##be ^= De; \
+ Bka = ROL64(A##be, 1); \
+ A##gi ^= Di; \
+ Bke = ROL64(A##gi, 6); \
+ A##ko ^= Do; \
+ Bki = ROL64(A##ko, 25); \
+ A##mu ^= Du; \
+ Bko = ROL64(A##mu, 8); \
+ A##sa ^= Da; \
+ Bku = ROL64(A##sa, 18); \
+ E##ka = Bka ^((~Bke)& Bki ); \
+ E##ke = Bke ^((~Bki)& Bko ); \
+ E##ki = Bki ^((~Bko)& Bku ); \
+ E##ko = Bko ^((~Bku)& Bka ); \
+ E##ku = Bku ^((~Bka)& Bke ); \
+\
+ A##bu ^= Du; \
+ Bma = ROL64(A##bu, 27); \
+ A##ga ^= Da; \
+ Bme = ROL64(A##ga, 36); \
+ A##ke ^= De; \
+ Bmi = ROL64(A##ke, 10); \
+ A##mi ^= Di; \
+ Bmo = ROL64(A##mi, 15); \
+ A##so ^= Do; \
+ Bmu = ROL64(A##so, 56); \
+ E##ma = Bma ^((~Bme)& Bmi ); \
+ E##me = Bme ^((~Bmi)& Bmo ); \
+ E##mi = Bmi ^((~Bmo)& Bmu ); \
+ E##mo = Bmo ^((~Bmu)& Bma ); \
+ E##mu = Bmu ^((~Bma)& Bme ); \
+\
+ A##bi ^= Di; \
+ Bsa = ROL64(A##bi, 62); \
+ A##go ^= Do; \
+ Bse = ROL64(A##go, 55); \
+ A##ku ^= Du; \
+ Bsi = ROL64(A##ku, 39); \
+ A##ma ^= Da; \
+ Bso = ROL64(A##ma, 41); \
+ A##se ^= De; \
+ Bsu = ROL64(A##se, 2); \
+ E##sa = Bsa ^((~Bse)& Bsi ); \
+ E##se = Bse ^((~Bsi)& Bso ); \
+ E##si = Bsi ^((~Bso)& Bsu ); \
+ E##so = Bso ^((~Bsu)& Bsa ); \
+ E##su = Bsu ^((~Bsa)& Bse ); \
+\
+
+#endif // UseBebigokimisa
+
+const UINT64 KeccakF1600RoundConstants[24] = {
+ 0x0000000000000001ULL,
+ 0x0000000000008082ULL,
+ 0x800000000000808aULL,
+ 0x8000000080008000ULL,
+ 0x000000000000808bULL,
+ 0x0000000080000001ULL,
+ 0x8000000080008081ULL,
+ 0x8000000000008009ULL,
+ 0x000000000000008aULL,
+ 0x0000000000000088ULL,
+ 0x0000000080008009ULL,
+ 0x000000008000000aULL,
+ 0x000000008000808bULL,
+ 0x800000000000008bULL,
+ 0x8000000000008089ULL,
+ 0x8000000000008003ULL,
+ 0x8000000000008002ULL,
+ 0x8000000000000080ULL,
+ 0x000000000000800aULL,
+ 0x800000008000000aULL,
+ 0x8000000080008081ULL,
+ 0x8000000000008080ULL,
+ 0x0000000080000001ULL,
+ 0x8000000080008008ULL };
+
+#define copyFromStateAndXor576bits(X, state, input) \
+ X##ba = state[ 0]^input[ 0]; \
+ X##be = state[ 1]^input[ 1]; \
+ X##bi = state[ 2]^input[ 2]; \
+ X##bo = state[ 3]^input[ 3]; \
+ X##bu = state[ 4]^input[ 4]; \
+ X##ga = state[ 5]^input[ 5]; \
+ X##ge = state[ 6]^input[ 6]; \
+ X##gi = state[ 7]^input[ 7]; \
+ X##go = state[ 8]^input[ 8]; \
+ X##gu = state[ 9]; \
+ X##ka = state[10]; \
+ X##ke = state[11]; \
+ X##ki = state[12]; \
+ X##ko = state[13]; \
+ X##ku = state[14]; \
+ X##ma = state[15]; \
+ X##me = state[16]; \
+ X##mi = state[17]; \
+ X##mo = state[18]; \
+ X##mu = state[19]; \
+ X##sa = state[20]; \
+ X##se = state[21]; \
+ X##si = state[22]; \
+ X##so = state[23]; \
+ X##su = state[24]; \
+
+#define copyFromStateAndXor832bits(X, state, input) \
+ X##ba = state[ 0]^input[ 0]; \
+ X##be = state[ 1]^input[ 1]; \
+ X##bi = state[ 2]^input[ 2]; \
+ X##bo = state[ 3]^input[ 3]; \
+ X##bu = state[ 4]^input[ 4]; \
+ X##ga = state[ 5]^input[ 5]; \
+ X##ge = state[ 6]^input[ 6]; \
+ X##gi = state[ 7]^input[ 7]; \
+ X##go = state[ 8]^input[ 8]; \
+ X##gu = state[ 9]^input[ 9]; \
+ X##ka = state[10]^input[10]; \
+ X##ke = state[11]^input[11]; \
+ X##ki = state[12]^input[12]; \
+ X##ko = state[13]; \
+ X##ku = state[14]; \
+ X##ma = state[15]; \
+ X##me = state[16]; \
+ X##mi = state[17]; \
+ X##mo = state[18]; \
+ X##mu = state[19]; \
+ X##sa = state[20]; \
+ X##se = state[21]; \
+ X##si = state[22]; \
+ X##so = state[23]; \
+ X##su = state[24]; \
+
+#define copyFromStateAndXor1024bits(X, state, input) \
+ X##ba = state[ 0]^input[ 0]; \
+ X##be = state[ 1]^input[ 1]; \
+ X##bi = state[ 2]^input[ 2]; \
+ X##bo = state[ 3]^input[ 3]; \
+ X##bu = state[ 4]^input[ 4]; \
+ X##ga = state[ 5]^input[ 5]; \
+ X##ge = state[ 6]^input[ 6]; \
+ X##gi = state[ 7]^input[ 7]; \
+ X##go = state[ 8]^input[ 8]; \
+ X##gu = state[ 9]^input[ 9]; \
+ X##ka = state[10]^input[10]; \
+ X##ke = state[11]^input[11]; \
+ X##ki = state[12]^input[12]; \
+ X##ko = state[13]^input[13]; \
+ X##ku = state[14]^input[14]; \
+ X##ma = state[15]^input[15]; \
+ X##me = state[16]; \
+ X##mi = state[17]; \
+ X##mo = state[18]; \
+ X##mu = state[19]; \
+ X##sa = state[20]; \
+ X##se = state[21]; \
+ X##si = state[22]; \
+ X##so = state[23]; \
+ X##su = state[24]; \
+
+#define copyFromStateAndXor1088bits(X, state, input) \
+ X##ba = state[ 0]^input[ 0]; \
+ X##be = state[ 1]^input[ 1]; \
+ X##bi = state[ 2]^input[ 2]; \
+ X##bo = state[ 3]^input[ 3]; \
+ X##bu = state[ 4]^input[ 4]; \
+ X##ga = state[ 5]^input[ 5]; \
+ X##ge = state[ 6]^input[ 6]; \
+ X##gi = state[ 7]^input[ 7]; \
+ X##go = state[ 8]^input[ 8]; \
+ X##gu = state[ 9]^input[ 9]; \
+ X##ka = state[10]^input[10]; \
+ X##ke = state[11]^input[11]; \
+ X##ki = state[12]^input[12]; \
+ X##ko = state[13]^input[13]; \
+ X##ku = state[14]^input[14]; \
+ X##ma = state[15]^input[15]; \
+ X##me = state[16]^input[16]; \
+ X##mi = state[17]; \
+ X##mo = state[18]; \
+ X##mu = state[19]; \
+ X##sa = state[20]; \
+ X##se = state[21]; \
+ X##si = state[22]; \
+ X##so = state[23]; \
+ X##su = state[24]; \
+
+#define copyFromStateAndXor1152bits(X, state, input) \
+ X##ba = state[ 0]^input[ 0]; \
+ X##be = state[ 1]^input[ 1]; \
+ X##bi = state[ 2]^input[ 2]; \
+ X##bo = state[ 3]^input[ 3]; \
+ X##bu = state[ 4]^input[ 4]; \
+ X##ga = state[ 5]^input[ 5]; \
+ X##ge = state[ 6]^input[ 6]; \
+ X##gi = state[ 7]^input[ 7]; \
+ X##go = state[ 8]^input[ 8]; \
+ X##gu = state[ 9]^input[ 9]; \
+ X##ka = state[10]^input[10]; \
+ X##ke = state[11]^input[11]; \
+ X##ki = state[12]^input[12]; \
+ X##ko = state[13]^input[13]; \
+ X##ku = state[14]^input[14]; \
+ X##ma = state[15]^input[15]; \
+ X##me = state[16]^input[16]; \
+ X##mi = state[17]^input[17]; \
+ X##mo = state[18]; \
+ X##mu = state[19]; \
+ X##sa = state[20]; \
+ X##se = state[21]; \
+ X##si = state[22]; \
+ X##so = state[23]; \
+ X##su = state[24]; \
+
+#define copyFromStateAndXor1344bits(X, state, input) \
+ X##ba = state[ 0]^input[ 0]; \
+ X##be = state[ 1]^input[ 1]; \
+ X##bi = state[ 2]^input[ 2]; \
+ X##bo = state[ 3]^input[ 3]; \
+ X##bu = state[ 4]^input[ 4]; \
+ X##ga = state[ 5]^input[ 5]; \
+ X##ge = state[ 6]^input[ 6]; \
+ X##gi = state[ 7]^input[ 7]; \
+ X##go = state[ 8]^input[ 8]; \
+ X##gu = state[ 9]^input[ 9]; \
+ X##ka = state[10]^input[10]; \
+ X##ke = state[11]^input[11]; \
+ X##ki = state[12]^input[12]; \
+ X##ko = state[13]^input[13]; \
+ X##ku = state[14]^input[14]; \
+ X##ma = state[15]^input[15]; \
+ X##me = state[16]^input[16]; \
+ X##mi = state[17]^input[17]; \
+ X##mo = state[18]^input[18]; \
+ X##mu = state[19]^input[19]; \
+ X##sa = state[20]^input[20]; \
+ X##se = state[21]; \
+ X##si = state[22]; \
+ X##so = state[23]; \
+ X##su = state[24]; \
+
+#define copyFromState(X, state) \
+ X##ba = state[ 0]; \
+ X##be = state[ 1]; \
+ X##bi = state[ 2]; \
+ X##bo = state[ 3]; \
+ X##bu = state[ 4]; \
+ X##ga = state[ 5]; \
+ X##ge = state[ 6]; \
+ X##gi = state[ 7]; \
+ X##go = state[ 8]; \
+ X##gu = state[ 9]; \
+ X##ka = state[10]; \
+ X##ke = state[11]; \
+ X##ki = state[12]; \
+ X##ko = state[13]; \
+ X##ku = state[14]; \
+ X##ma = state[15]; \
+ X##me = state[16]; \
+ X##mi = state[17]; \
+ X##mo = state[18]; \
+ X##mu = state[19]; \
+ X##sa = state[20]; \
+ X##se = state[21]; \
+ X##si = state[22]; \
+ X##so = state[23]; \
+ X##su = state[24]; \
+
+#define copyToState(state, X) \
+ state[ 0] = X##ba; \
+ state[ 1] = X##be; \
+ state[ 2] = X##bi; \
+ state[ 3] = X##bo; \
+ state[ 4] = X##bu; \
+ state[ 5] = X##ga; \
+ state[ 6] = X##ge; \
+ state[ 7] = X##gi; \
+ state[ 8] = X##go; \
+ state[ 9] = X##gu; \
+ state[10] = X##ka; \
+ state[11] = X##ke; \
+ state[12] = X##ki; \
+ state[13] = X##ko; \
+ state[14] = X##ku; \
+ state[15] = X##ma; \
+ state[16] = X##me; \
+ state[17] = X##mi; \
+ state[18] = X##mo; \
+ state[19] = X##mu; \
+ state[20] = X##sa; \
+ state[21] = X##se; \
+ state[22] = X##si; \
+ state[23] = X##so; \
+ state[24] = X##su; \
+
+#define copyStateVariables(X, Y) \
+ X##ba = Y##ba; \
+ X##be = Y##be; \
+ X##bi = Y##bi; \
+ X##bo = Y##bo; \
+ X##bu = Y##bu; \
+ X##ga = Y##ga; \
+ X##ge = Y##ge; \
+ X##gi = Y##gi; \
+ X##go = Y##go; \
+ X##gu = Y##gu; \
+ X##ka = Y##ka; \
+ X##ke = Y##ke; \
+ X##ki = Y##ki; \
+ X##ko = Y##ko; \
+ X##ku = Y##ku; \
+ X##ma = Y##ma; \
+ X##me = Y##me; \
+ X##mi = Y##mi; \
+ X##mo = Y##mo; \
+ X##mu = Y##mu; \
+ X##sa = Y##sa; \
+ X##se = Y##se; \
+ X##si = Y##si; \
+ X##so = Y##so; \
+ X##su = Y##su; \
+
diff --git a/src/3rdparty/sha3/KeccakF-1600-int-set.h b/src/3rdparty/sha3/KeccakF-1600-int-set.h
new file mode 100755
index 0000000000..0ed1d802e3
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakF-1600-int-set.h
@@ -0,0 +1,6 @@
+#define ProvideFast576
+#define ProvideFast832
+#define ProvideFast1024
+#define ProvideFast1088
+#define ProvideFast1152
+#define ProvideFast1344
diff --git a/src/3rdparty/sha3/KeccakF-1600-interface.h b/src/3rdparty/sha3/KeccakF-1600-interface.h
new file mode 100755
index 0000000000..ce2710eeb2
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakF-1600-interface.h
@@ -0,0 +1,46 @@
+/*
+The Keccak sponge function, designed by Guido Bertoni, Joan Daemen,
+Michaël Peeters and Gilles Van Assche. For more information, feedback or
+questions, please refer to our website: http://keccak.noekeon.org/
+
+Implementation by the designers,
+hereby denoted as "the implementer".
+
+To the extent possible under law, the implementer has waived all copyright
+and related or neighboring rights to the source code in this file.
+http://creativecommons.org/publicdomain/zero/1.0/
+*/
+
+#ifndef _KeccakPermutationInterface_h_
+#define _KeccakPermutationInterface_h_
+
+#include "KeccakF-1600-int-set.h"
+
+static void KeccakInitialize( void );
+static void KeccakInitializeState(unsigned char *state);
+static void KeccakPermutation(unsigned char *state);
+#ifdef ProvideFast576
+static void KeccakAbsorb576bits(unsigned char *state, const unsigned char *data);
+#endif
+#ifdef ProvideFast832
+static void KeccakAbsorb832bits(unsigned char *state, const unsigned char *data);
+#endif
+#ifdef ProvideFast1024
+static void KeccakAbsorb1024bits(unsigned char *state, const unsigned char *data);
+#endif
+#ifdef ProvideFast1088
+static void KeccakAbsorb1088bits(unsigned char *state, const unsigned char *data);
+#endif
+#ifdef ProvideFast1152
+static void KeccakAbsorb1152bits(unsigned char *state, const unsigned char *data);
+#endif
+#ifdef ProvideFast1344
+static void KeccakAbsorb1344bits(unsigned char *state, const unsigned char *data);
+#endif
+static void KeccakAbsorb(unsigned char *state, const unsigned char *data, unsigned int laneCount);
+#ifdef ProvideFast1024
+static void KeccakExtract1024bits(const unsigned char *state, unsigned char *data);
+#endif
+static void KeccakExtract(const unsigned char *state, unsigned char *data, unsigned int laneCount);
+
+#endif
diff --git a/src/3rdparty/sha3/KeccakF-1600-opt32-settings.h b/src/3rdparty/sha3/KeccakF-1600-opt32-settings.h
new file mode 100755
index 0000000000..b135918ca9
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakF-1600-opt32-settings.h
@@ -0,0 +1,4 @@
+#define Unrolling 2
+//#define UseBebigokimisa
+//#define UseInterleaveTables
+#define UseSchedule 3
diff --git a/src/3rdparty/sha3/KeccakF-1600-opt32.c b/src/3rdparty/sha3/KeccakF-1600-opt32.c
new file mode 100755
index 0000000000..b1b442c7e0
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakF-1600-opt32.c
@@ -0,0 +1,524 @@
+/*
+The Keccak sponge function, designed by Guido Bertoni, Joan Daemen,
+Michaël Peeters and Gilles Van Assche. For more information, feedback or
+questions, please refer to our website: http://keccak.noekeon.org/
+
+Implementation by the designers,
+hereby denoted as "the implementer".
+
+To the extent possible under law, the implementer has waived all copyright
+and related or neighboring rights to the source code in this file.
+http://creativecommons.org/publicdomain/zero/1.0/
+*/
+
+#include <string.h>
+#include "brg_endian.h"
+#include "KeccakF-1600-opt32-settings.h"
+#include "KeccakF-1600-interface.h"
+
+typedef unsigned char UINT8;
+typedef unsigned short UINT16;
+typedef unsigned int UINT32;
+typedef unsigned long long int UINT64;
+
+#ifdef UseInterleaveTables
+int interleaveTablesBuilt = 0;
+UINT16 interleaveTable[65536];
+UINT16 deinterleaveTable[65536];
+
+static void buildInterleaveTables()
+{
+ UINT32 i, j;
+ UINT16 x;
+
+ if (!interleaveTablesBuilt) {
+ for(i=0; i<65536; i++) {
+ x = 0;
+ for(j=0; j<16; j++) {
+ if (i & (1 << j))
+ x |= (1 << (j/2 + 8*(j%2)));
+ }
+ interleaveTable[i] = x;
+ deinterleaveTable[x] = (UINT16)i;
+ }
+ interleaveTablesBuilt = 1;
+ }
+}
+
+#if (PLATFORM_BYTE_ORDER == IS_LITTLE_ENDIAN)
+
+#define xor2bytesIntoInterleavedWords(even, odd, source, j) \
+ i##j = interleaveTable[((const UINT16*)source)[j]]; \
+ ((UINT8*)even)[j] ^= i##j & 0xFF; \
+ ((UINT8*)odd)[j] ^= i##j >> 8;
+
+#define setInterleavedWordsInto2bytes(dest, even, odd, j) \
+ d##j = deinterleaveTable[((even >> (j*8)) & 0xFF) ^ (((odd >> (j*8)) & 0xFF) << 8)]; \
+ ((UINT16*)dest)[j] = d##j;
+
+#else // (PLATFORM_BYTE_ORDER == IS_BIG_ENDIAN)
+
+#define xor2bytesIntoInterleavedWords(even, odd, source, j) \
+ i##j = interleaveTable[source[2*j] ^ ((UINT16)source[2*j+1] << 8)]; \
+ *even ^= (i##j & 0xFF) << (j*8); \
+ *odd ^= ((i##j >> 8) & 0xFF) << (j*8);
+
+#define setInterleavedWordsInto2bytes(dest, even, odd, j) \
+ d##j = deinterleaveTable[((even >> (j*8)) & 0xFF) ^ (((odd >> (j*8)) & 0xFF) << 8)]; \
+ dest[2*j] = d##j & 0xFF; \
+ dest[2*j+1] = d##j >> 8;
+
+#endif // Endianness
+
+static void xor8bytesIntoInterleavedWords(UINT32 *even, UINT32 *odd, const UINT8* source)
+{
+ UINT16 i0, i1, i2, i3;
+
+ xor2bytesIntoInterleavedWords(even, odd, source, 0)
+ xor2bytesIntoInterleavedWords(even, odd, source, 1)
+ xor2bytesIntoInterleavedWords(even, odd, source, 2)
+ xor2bytesIntoInterleavedWords(even, odd, source, 3)
+}
+
+#define xorLanesIntoState(laneCount, state, input) \
+ { \
+ int i; \
+ for(i=0; i<(laneCount); i++) \
+ xor8bytesIntoInterleavedWords(state+i*2, state+i*2+1, input+i*8); \
+ }
+
+static void setInterleavedWordsInto8bytes(UINT8* dest, UINT32 even, UINT32 odd)
+{
+ UINT16 d0, d1, d2, d3;
+
+ setInterleavedWordsInto2bytes(dest, even, odd, 0)
+ setInterleavedWordsInto2bytes(dest, even, odd, 1)
+ setInterleavedWordsInto2bytes(dest, even, odd, 2)
+ setInterleavedWordsInto2bytes(dest, even, odd, 3)
+}
+
+#define extractLanes(laneCount, state, data) \
+ { \
+ int i; \
+ for(i=0; i<(laneCount); i++) \
+ setInterleavedWordsInto8bytes(data+i*8, ((UINT32*)state)[i*2], ((UINT32*)state)[i*2+1]); \
+ }
+
+#else // No interleaving tables
+
+#if (PLATFORM_BYTE_ORDER == IS_LITTLE_ENDIAN)
+
+// Credit: Henry S. Warren, Hacker's Delight, Addison-Wesley, 2002
+#define xorInterleavedLE(rateInLanes, state, input) \
+ { \
+ const UINT32 * pI = (const UINT32 *)input; \
+ UINT32 * pS = state; \
+ UINT32 t, x0, x1; \
+ int i; \
+ for (i = (rateInLanes)-1; i >= 0; --i) \
+ { \
+ x0 = *(pI++); \
+ t = (x0 ^ (x0 >> 1)) & 0x22222222UL; x0 = x0 ^ t ^ (t << 1); \
+ t = (x0 ^ (x0 >> 2)) & 0x0C0C0C0CUL; x0 = x0 ^ t ^ (t << 2); \
+ t = (x0 ^ (x0 >> 4)) & 0x00F000F0UL; x0 = x0 ^ t ^ (t << 4); \
+ t = (x0 ^ (x0 >> 8)) & 0x0000FF00UL; x0 = x0 ^ t ^ (t << 8); \
+ x1 = *(pI++); \
+ t = (x1 ^ (x1 >> 1)) & 0x22222222UL; x1 = x1 ^ t ^ (t << 1); \
+ t = (x1 ^ (x1 >> 2)) & 0x0C0C0C0CUL; x1 = x1 ^ t ^ (t << 2); \
+ t = (x1 ^ (x1 >> 4)) & 0x00F000F0UL; x1 = x1 ^ t ^ (t << 4); \
+ t = (x1 ^ (x1 >> 8)) & 0x0000FF00UL; x1 = x1 ^ t ^ (t << 8); \
+ *(pS++) ^= (UINT16)x0 | (x1 << 16); \
+ *(pS++) ^= (x0 >> 16) | (x1 & 0xFFFF0000); \
+ } \
+ }
+
+#define xorLanesIntoState(laneCount, state, input) \
+ xorInterleavedLE(laneCount, state, input)
+
+#else // (PLATFORM_BYTE_ORDER == IS_BIG_ENDIAN)
+
+// Credit: Henry S. Warren, Hacker's Delight, Addison-Wesley, 2002
+static UINT64 toInterleaving(UINT64 x)
+{
+ UINT64 t;
+
+ t = (x ^ (x >> 1)) & 0x2222222222222222ULL; x = x ^ t ^ (t << 1);
+ t = (x ^ (x >> 2)) & 0x0C0C0C0C0C0C0C0CULL; x = x ^ t ^ (t << 2);
+ t = (x ^ (x >> 4)) & 0x00F000F000F000F0ULL; x = x ^ t ^ (t << 4);
+ t = (x ^ (x >> 8)) & 0x0000FF000000FF00ULL; x = x ^ t ^ (t << 8);
+ t = (x ^ (x >> 16)) & 0x00000000FFFF0000ULL; x = x ^ t ^ (t << 16);
+
+ return x;
+}
+
+static void xor8bytesIntoInterleavedWords(UINT32* evenAndOdd, const UINT8* source)
+{
+ // This can be optimized
+ UINT64 sourceWord =
+ (UINT64)source[0]
+ ^ (((UINT64)source[1]) << 8)
+ ^ (((UINT64)source[2]) << 16)
+ ^ (((UINT64)source[3]) << 24)
+ ^ (((UINT64)source[4]) << 32)
+ ^ (((UINT64)source[5]) << 40)
+ ^ (((UINT64)source[6]) << 48)
+ ^ (((UINT64)source[7]) << 56);
+ UINT64 evenAndOddWord = toInterleaving(sourceWord);
+ evenAndOdd[0] ^= (UINT32)evenAndOddWord;
+ evenAndOdd[1] ^= (UINT32)(evenAndOddWord >> 32);
+}
+
+#define xorLanesIntoState(laneCount, state, input) \
+ { \
+ int i; \
+ for(i=0; i<(laneCount); i++) \
+ xor8bytesIntoInterleavedWords(state+i*2, input+i*8); \
+ }
+
+#endif // Endianness
+
+// Credit: Henry S. Warren, Hacker's Delight, Addison-Wesley, 2002
+static UINT64 fromInterleaving(UINT64 x)
+{
+ UINT64 t;
+
+ t = (x ^ (x >> 16)) & 0x00000000FFFF0000ULL; x = x ^ t ^ (t << 16);
+ t = (x ^ (x >> 8)) & 0x0000FF000000FF00ULL; x = x ^ t ^ (t << 8);
+ t = (x ^ (x >> 4)) & 0x00F000F000F000F0ULL; x = x ^ t ^ (t << 4);
+ t = (x ^ (x >> 2)) & 0x0C0C0C0C0C0C0C0CULL; x = x ^ t ^ (t << 2);
+ t = (x ^ (x >> 1)) & 0x2222222222222222ULL; x = x ^ t ^ (t << 1);
+
+ return x;
+}
+
+static void setInterleavedWordsInto8bytes(UINT8* dest, UINT32* evenAndOdd)
+{
+#if (PLATFORM_BYTE_ORDER == IS_LITTLE_ENDIAN)
+ ((UINT64*)dest)[0] = fromInterleaving(*(UINT64*)evenAndOdd);
+#else // (PLATFORM_BYTE_ORDER == IS_BIG_ENDIAN)
+ // This can be optimized
+ UINT64 evenAndOddWord = (UINT64)evenAndOdd[0] ^ ((UINT64)evenAndOdd[1] << 32);
+ UINT64 destWord = fromInterleaving(evenAndOddWord);
+ dest[0] = destWord & 0xFF;
+ dest[1] = (destWord >> 8) & 0xFF;
+ dest[2] = (destWord >> 16) & 0xFF;
+ dest[3] = (destWord >> 24) & 0xFF;
+ dest[4] = (destWord >> 32) & 0xFF;
+ dest[5] = (destWord >> 40) & 0xFF;
+ dest[6] = (destWord >> 48) & 0xFF;
+ dest[7] = (destWord >> 56) & 0xFF;
+#endif // Endianness
+}
+
+#define extractLanes(laneCount, state, data) \
+ { \
+ int i; \
+ for(i=0; i<(laneCount); i++) \
+ setInterleavedWordsInto8bytes(data+i*8, (UINT32*)state+i*2); \
+ }
+
+#endif // With or without interleaving tables
+
+#if defined(_MSC_VER)
+#define ROL32(a, offset) _rotl(a, offset)
+#elif (defined (__arm__) && defined(__ARMCC_VERSION))
+#define ROL32(a, offset) __ror(a, 32-(offset))
+#else
+#define ROL32(a, offset) ((((UINT32)a) << (offset)) ^ (((UINT32)a) >> (32-(offset))))
+#endif
+
+#include "KeccakF-1600-unrolling.macros"
+#include "KeccakF-1600-32.macros"
+
+#if (UseSchedule == 3)
+
+#ifdef UseBebigokimisa
+#error "No lane complementing with schedule 3."
+#endif
+
+#if (Unrolling != 2)
+#error "Only unrolling 2 is supported by schedule 3."
+#endif
+
+static void KeccakPermutationOnWords(UINT32 *state)
+{
+ rounds
+}
+
+static void KeccakPermutationOnWordsAfterXoring(UINT32 *state, const UINT8 *input, unsigned int laneCount)
+{
+ xorLanesIntoState(laneCount, state, input)
+ rounds
+}
+
+#ifdef ProvideFast576
+static void KeccakPermutationOnWordsAfterXoring576bits(UINT32 *state, const UINT8 *input)
+{
+ xorLanesIntoState(9, state, input)
+ rounds
+}
+#endif
+
+#ifdef ProvideFast832
+static void KeccakPermutationOnWordsAfterXoring832bits(UINT32 *state, const UINT8 *input)
+{
+ xorLanesIntoState(13, state, input)
+ rounds
+}
+#endif
+
+#ifdef ProvideFast1024
+static void KeccakPermutationOnWordsAfterXoring1024bits(UINT32 *state, const UINT8 *input)
+{
+ xorLanesIntoState(16, state, input)
+ rounds
+}
+#endif
+
+#ifdef ProvideFast1088
+static void KeccakPermutationOnWordsAfterXoring1088bits(UINT32 *state, const UINT8 *input)
+{
+ xorLanesIntoState(17, state, input)
+ rounds
+}
+#endif
+
+#ifdef ProvideFast1152
+static void KeccakPermutationOnWordsAfterXoring1152bits(UINT32 *state, const UINT8 *input)
+{
+ xorLanesIntoState(18, state, input)
+ rounds
+}
+#endif
+
+#ifdef ProvideFast1344
+static void KeccakPermutationOnWordsAfterXoring1344bits(UINT32 *state, const UINT8 *input)
+{
+ xorLanesIntoState(21, state, input)
+ rounds
+}
+#endif
+
+#else // (Schedule != 3)
+
+static void KeccakPermutationOnWords(UINT32 *state)
+{
+ declareABCDE
+#if (Unrolling != 24)
+ unsigned int i;
+#endif
+
+ copyFromState(A, state)
+ rounds
+}
+
+static void KeccakPermutationOnWordsAfterXoring(UINT32 *state, const UINT8 *input, unsigned int laneCount)
+{
+ declareABCDE
+ unsigned int i;
+
+ xorLanesIntoState(laneCount, state, input)
+ copyFromState(A, state)
+ rounds
+}
+
+#ifdef ProvideFast576
+static void KeccakPermutationOnWordsAfterXoring576bits(UINT32 *state, const UINT8 *input)
+{
+ declareABCDE
+ unsigned int i;
+
+ xorLanesIntoState(9, state, input)
+ copyFromState(A, state)
+ rounds
+}
+#endif
+
+#ifdef ProvideFast832
+static void KeccakPermutationOnWordsAfterXoring832bits(UINT32 *state, const UINT8 *input)
+{
+ declareABCDE
+ unsigned int i;
+
+ xorLanesIntoState(13, state, input)
+ copyFromState(A, state)
+ rounds
+}
+#endif
+
+#ifdef ProvideFast1024
+static void KeccakPermutationOnWordsAfterXoring1024bits(UINT32 *state, const UINT8 *input)
+{
+ declareABCDE
+ unsigned int i;
+
+ xorLanesIntoState(16, state, input)
+ copyFromState(A, state)
+ rounds
+}
+#endif
+
+#ifdef ProvideFast1088
+static void KeccakPermutationOnWordsAfterXoring1088bits(UINT32 *state, const UINT8 *input)
+{
+ declareABCDE
+ unsigned int i;
+
+ xorLanesIntoState(17, state, input)
+ copyFromState(A, state)
+ rounds
+}
+#endif
+
+#ifdef ProvideFast1152
+static void KeccakPermutationOnWordsAfterXoring1152bits(UINT32 *state, const UINT8 *input)
+{
+ declareABCDE
+ unsigned int i;
+
+ xorLanesIntoState(18, state, input)
+ copyFromState(A, state)
+ rounds
+}
+#endif
+
+#ifdef ProvideFast1344
+static void KeccakPermutationOnWordsAfterXoring1344bits(UINT32 *state, const UINT8 *input)
+{
+ declareABCDE
+ unsigned int i;
+
+ xorLanesIntoState(21, state, input)
+ copyFromState(A, state)
+ rounds
+}
+#endif
+
+#endif
+
+static void KeccakInitialize()
+{
+#ifdef UseInterleaveTables
+ buildInterleaveTables();
+#endif
+}
+
+static void KeccakInitializeState(unsigned char *state)
+{
+ memset(state, 0, 200);
+#ifdef UseBebigokimisa
+ ((UINT32*)state)[ 2] = ~(UINT32)0;
+ ((UINT32*)state)[ 3] = ~(UINT32)0;
+ ((UINT32*)state)[ 4] = ~(UINT32)0;
+ ((UINT32*)state)[ 5] = ~(UINT32)0;
+ ((UINT32*)state)[16] = ~(UINT32)0;
+ ((UINT32*)state)[17] = ~(UINT32)0;
+ ((UINT32*)state)[24] = ~(UINT32)0;
+ ((UINT32*)state)[25] = ~(UINT32)0;
+ ((UINT32*)state)[34] = ~(UINT32)0;
+ ((UINT32*)state)[35] = ~(UINT32)0;
+ ((UINT32*)state)[40] = ~(UINT32)0;
+ ((UINT32*)state)[41] = ~(UINT32)0;
+#endif
+}
+
+static void KeccakPermutation(unsigned char *state)
+{
+ // We assume the state is always stored as interleaved 32-bit words
+ KeccakPermutationOnWords((UINT32*)state);
+}
+
+#ifdef ProvideFast576
+static void KeccakAbsorb576bits(unsigned char *state, const unsigned char *data)
+{
+ KeccakPermutationOnWordsAfterXoring576bits((UINT32*)state, data);
+}
+#endif
+
+#ifdef ProvideFast832
+static void KeccakAbsorb832bits(unsigned char *state, const unsigned char *data)
+{
+ KeccakPermutationOnWordsAfterXoring832bits((UINT32*)state, data);
+}
+#endif
+
+#ifdef ProvideFast1024
+static void KeccakAbsorb1024bits(unsigned char *state, const unsigned char *data)
+{
+ KeccakPermutationOnWordsAfterXoring1024bits((UINT32*)state, data);
+}
+#endif
+
+#ifdef ProvideFast1088
+static void KeccakAbsorb1088bits(unsigned char *state, const unsigned char *data)
+{
+ KeccakPermutationOnWordsAfterXoring1088bits((UINT32*)state, data);
+}
+#endif
+
+#ifdef ProvideFast1152
+static void KeccakAbsorb1152bits(unsigned char *state, const unsigned char *data)
+{
+ KeccakPermutationOnWordsAfterXoring1152bits((UINT32*)state, data);
+}
+#endif
+
+#ifdef ProvideFast1344
+static void KeccakAbsorb1344bits(unsigned char *state, const unsigned char *data)
+{
+ KeccakPermutationOnWordsAfterXoring1344bits((UINT32*)state, data);
+}
+#endif
+
+static void KeccakAbsorb(unsigned char *state, const unsigned char *data, unsigned int laneCount)
+{
+ KeccakPermutationOnWordsAfterXoring((UINT32*)state, data, laneCount);
+}
+
+#ifdef ProvideFast1024
+static void KeccakExtract1024bits(const unsigned char *state, unsigned char *data)
+{
+ extractLanes(16, state, data)
+#ifdef UseBebigokimisa
+ ((UINT32*)data)[ 2] = ~((UINT32*)data)[ 2];
+ ((UINT32*)data)[ 3] = ~((UINT32*)data)[ 3];
+ ((UINT32*)data)[ 4] = ~((UINT32*)data)[ 4];
+ ((UINT32*)data)[ 5] = ~((UINT32*)data)[ 5];
+ ((UINT32*)data)[16] = ~((UINT32*)data)[16];
+ ((UINT32*)data)[17] = ~((UINT32*)data)[17];
+ ((UINT32*)data)[24] = ~((UINT32*)data)[24];
+ ((UINT32*)data)[25] = ~((UINT32*)data)[25];
+#endif
+}
+#endif
+
+static void KeccakExtract(const unsigned char *state, unsigned char *data, unsigned int laneCount)
+{
+ extractLanes(laneCount, state, data)
+#ifdef UseBebigokimisa
+ if (laneCount > 1) {
+ ((UINT32*)data)[ 2] = ~((UINT32*)data)[ 2];
+ ((UINT32*)data)[ 3] = ~((UINT32*)data)[ 3];
+ if (laneCount > 2) {
+ ((UINT32*)data)[ 4] = ~((UINT32*)data)[ 4];
+ ((UINT32*)data)[ 5] = ~((UINT32*)data)[ 5];
+ if (laneCount > 8) {
+ ((UINT32*)data)[16] = ~((UINT32*)data)[16];
+ ((UINT32*)data)[17] = ~((UINT32*)data)[17];
+ if (laneCount > 12) {
+ ((UINT32*)data)[24] = ~((UINT32*)data)[24];
+ ((UINT32*)data)[25] = ~((UINT32*)data)[25];
+ if (laneCount > 17) {
+ ((UINT32*)data)[34] = ~((UINT32*)data)[34];
+ ((UINT32*)data)[35] = ~((UINT32*)data)[35];
+ if (laneCount > 20) {
+ ((UINT32*)data)[40] = ~((UINT32*)data)[40];
+ ((UINT32*)data)[41] = ~((UINT32*)data)[41];
+ }
+ }
+ }
+ }
+ }
+ }
+#endif
+}
diff --git a/src/3rdparty/sha3/KeccakF-1600-opt64-settings.h b/src/3rdparty/sha3/KeccakF-1600-opt64-settings.h
new file mode 100755
index 0000000000..8f16ada636
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakF-1600-opt64-settings.h
@@ -0,0 +1,7 @@
+#define Unrolling 24
+#define UseBebigokimisa
+//#define UseSSE
+//#define UseOnlySIMD64
+//#define UseMMX
+//#define UseSHLD
+//#define UseXOP
diff --git a/src/3rdparty/sha3/KeccakF-1600-opt64.c b/src/3rdparty/sha3/KeccakF-1600-opt64.c
new file mode 100755
index 0000000000..0432f1ab18
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakF-1600-opt64.c
@@ -0,0 +1,508 @@
+/*
+The Keccak sponge function, designed by Guido Bertoni, Joan Daemen,
+Michaël Peeters and Gilles Van Assche. For more information, feedback or
+questions, please refer to our website: http://keccak.noekeon.org/
+
+Implementation by the designers,
+hereby denoted as "the implementer".
+
+To the extent possible under law, the implementer has waived all copyright
+and related or neighboring rights to the source code in this file.
+http://creativecommons.org/publicdomain/zero/1.0/
+*/
+
+#include <string.h>
+#include "brg_endian.h"
+#include "KeccakF-1600-opt64-settings.h"
+#include "KeccakF-1600-interface.h"
+
+typedef unsigned char UINT8;
+typedef unsigned long long int UINT64;
+
+#if defined(__GNUC__)
+#define ALIGN __attribute__ ((aligned(32)))
+#elif defined(_MSC_VER)
+#define ALIGN __declspec(align(32))
+#else
+#define ALIGN
+#endif
+
+#if defined(UseSSE)
+ #include <x86intrin.h>
+ typedef __m128i V64;
+ typedef __m128i V128;
+ typedef union {
+ V128 v128;
+ UINT64 v64[2];
+ } V6464;
+
+ #define ANDnu64(a, b) _mm_andnot_si128(a, b)
+ #define LOAD64(a) _mm_loadl_epi64((const V64 *)&(a))
+ #define CONST64(a) _mm_loadl_epi64((const V64 *)&(a))
+ #define ROL64(a, o) _mm_or_si128(_mm_slli_epi64(a, o), _mm_srli_epi64(a, 64-(o)))
+ #define STORE64(a, b) _mm_storel_epi64((V64 *)&(a), b)
+ #define XOR64(a, b) _mm_xor_si128(a, b)
+ #define XOReq64(a, b) a = _mm_xor_si128(a, b)
+ #define SHUFFLEBYTES128(a, b) _mm_shuffle_epi8(a, b)
+
+ #define ANDnu128(a, b) _mm_andnot_si128(a, b)
+ #define LOAD6464(a, b) _mm_set_epi64((__m64)(a), (__m64)(b))
+ #define CONST128(a) _mm_load_si128((const V128 *)&(a))
+ #define LOAD128(a) _mm_load_si128((const V128 *)&(a))
+ #define LOAD128u(a) _mm_loadu_si128((const V128 *)&(a))
+ #define ROL64in128(a, o) _mm_or_si128(_mm_slli_epi64(a, o), _mm_srli_epi64(a, 64-(o)))
+ #define STORE128(a, b) _mm_store_si128((V128 *)&(a), b)
+ #define XOR128(a, b) _mm_xor_si128(a, b)
+ #define XOReq128(a, b) a = _mm_xor_si128(a, b)
+ #define GET64LOLO(a, b) _mm_unpacklo_epi64(a, b)
+ #define GET64HIHI(a, b) _mm_unpackhi_epi64(a, b)
+ #define COPY64HI2LO(a) _mm_shuffle_epi32(a, 0xEE)
+ #define COPY64LO2HI(a) _mm_shuffle_epi32(a, 0x44)
+ #define ZERO128() _mm_setzero_si128()
+
+ #ifdef UseOnlySIMD64
+ #include "KeccakF-1600-simd64.macros"
+ #else
+ALIGN const UINT64 rho8_56[2] = {0x0605040302010007, 0x080F0E0D0C0B0A09};
+ #include "KeccakF-1600-simd128.macros"
+ #endif
+
+ #ifdef UseBebigokimisa
+ #error "UseBebigokimisa cannot be used in combination with UseSSE"
+ #endif
+#elif defined(UseXOP)
+ #include <x86intrin.h>
+ typedef __m128i V64;
+ typedef __m128i V128;
+
+ #define LOAD64(a) _mm_loadl_epi64((const V64 *)&(a))
+ #define CONST64(a) _mm_loadl_epi64((const V64 *)&(a))
+ #define STORE64(a, b) _mm_storel_epi64((V64 *)&(a), b)
+ #define XOR64(a, b) _mm_xor_si128(a, b)
+ #define XOReq64(a, b) a = _mm_xor_si128(a, b)
+
+ #define ANDnu128(a, b) _mm_andnot_si128(a, b)
+ #define LOAD6464(a, b) _mm_set_epi64((__m64)(a), (__m64)(b))
+ #define CONST128(a) _mm_load_si128((const V128 *)&(a))
+ #define LOAD128(a) _mm_load_si128((const V128 *)&(a))
+ #define LOAD128u(a) _mm_loadu_si128((const V128 *)&(a))
+ #define STORE128(a, b) _mm_store_si128((V128 *)&(a), b)
+ #define XOR128(a, b) _mm_xor_si128(a, b)
+ #define XOReq128(a, b) a = _mm_xor_si128(a, b)
+ #define ZERO128() _mm_setzero_si128()
+
+ #define SWAP64(a) _mm_shuffle_epi32(a, 0x4E)
+ #define GET64LOLO(a, b) _mm_unpacklo_epi64(a, b)
+ #define GET64HIHI(a, b) _mm_unpackhi_epi64(a, b)
+ #define GET64LOHI(a, b) ((__m128i)_mm_blend_pd((__m128d)a, (__m128d)b, 2))
+ #define GET64HILO(a, b) SWAP64(GET64LOHI(b, a))
+ #define COPY64HI2LO(a) _mm_shuffle_epi32(a, 0xEE)
+ #define COPY64LO2HI(a) _mm_shuffle_epi32(a, 0x44)
+
+ #define ROL6464same(a, o) _mm_roti_epi64(a, o)
+ #define ROL6464(a, r1, r2) _mm_rot_epi64(a, CONST128( rot_##r1##_##r2 ))
+ALIGN const UINT64 rot_0_20[2] = { 0, 20};
+ALIGN const UINT64 rot_44_3[2] = {44, 3};
+ALIGN const UINT64 rot_43_45[2] = {43, 45};
+ALIGN const UINT64 rot_21_61[2] = {21, 61};
+ALIGN const UINT64 rot_14_28[2] = {14, 28};
+ALIGN const UINT64 rot_1_36[2] = { 1, 36};
+ALIGN const UINT64 rot_6_10[2] = { 6, 10};
+ALIGN const UINT64 rot_25_15[2] = {25, 15};
+ALIGN const UINT64 rot_8_56[2] = { 8, 56};
+ALIGN const UINT64 rot_18_27[2] = {18, 27};
+ALIGN const UINT64 rot_62_55[2] = {62, 55};
+ALIGN const UINT64 rot_39_41[2] = {39, 41};
+
+#if defined(UseSimulatedXOP)
+ // For debugging purposes, when XOP is not available
+ #undef ROL6464
+ #undef ROL6464same
+ #define ROL6464same(a, o) _mm_or_si128(_mm_slli_epi64(a, o), _mm_srli_epi64(a, 64-(o)))
+ V128 ROL6464(V128 a, int r0, int r1)
+ {
+ V128 a0 = ROL64(a, r0);
+ V128 a1 = COPY64HI2LO(ROL64(a, r1));
+ return GET64LOLO(a0, a1);
+ }
+#endif
+
+ #include "KeccakF-1600-xop.macros"
+
+ #ifdef UseBebigokimisa
+ #error "UseBebigokimisa cannot be used in combination with UseXOP"
+ #endif
+#elif defined(UseMMX)
+ #include <mmintrin.h>
+ typedef __m64 V64;
+ #define ANDnu64(a, b) _mm_andnot_si64(a, b)
+
+ #if (defined(_MSC_VER) || defined (__INTEL_COMPILER))
+ #define LOAD64(a) *(V64*)&(a)
+ #define CONST64(a) *(V64*)&(a)
+ #define STORE64(a, b) *(V64*)&(a) = b
+ #else
+ #define LOAD64(a) (V64)a
+ #define CONST64(a) (V64)a
+ #define STORE64(a, b) a = (UINT64)b
+ #endif
+ #define ROL64(a, o) _mm_or_si64(_mm_slli_si64(a, o), _mm_srli_si64(a, 64-(o)))
+ #define XOR64(a, b) _mm_xor_si64(a, b)
+ #define XOReq64(a, b) a = _mm_xor_si64(a, b)
+
+ #include "KeccakF-1600-simd64.macros"
+
+ #ifdef UseBebigokimisa
+ #error "UseBebigokimisa cannot be used in combination with UseMMX"
+ #endif
+#else
+ #if defined(_MSC_VER)
+ #define ROL64(a, offset) _rotl64(a, offset)
+ #elif defined(UseSHLD)
+ #define ROL64(x,N) ({ \
+ register UINT64 __out; \
+ register UINT64 __in = x; \
+ __asm__ ("shld %2,%0,%0" : "=r"(__out) : "0"(__in), "i"(N)); \
+ __out; \
+ })
+ #else
+ #define ROL64(a, offset) ((((UINT64)a) << offset) ^ (((UINT64)a) >> (64-offset)))
+ #endif
+
+ #include "KeccakF-1600-64.macros"
+#endif
+
+#include "KeccakF-1600-unrolling.macros"
+
+static void KeccakPermutationOnWords(UINT64 *state)
+{
+ declareABCDE
+#if (Unrolling != 24)
+ unsigned int i;
+#endif
+
+ copyFromState(A, state)
+ rounds
+#if defined(UseMMX)
+ _mm_empty();
+#endif
+}
+
+static void KeccakPermutationOnWordsAfterXoring(UINT64 *state, const UINT64 *input, unsigned int laneCount)
+{
+ declareABCDE
+#if (Unrolling != 24)
+ unsigned int i;
+#endif
+ unsigned int j;
+
+ for(j=0; j<laneCount; j++)
+ state[j] ^= input[j];
+ copyFromState(A, state)
+ rounds
+#if defined(UseMMX)
+ _mm_empty();
+#endif
+}
+
+#ifdef ProvideFast576
+static void KeccakPermutationOnWordsAfterXoring576bits(UINT64 *state, const UINT64 *input)
+{
+ declareABCDE
+#if (Unrolling != 24)
+ unsigned int i;
+#endif
+
+ copyFromStateAndXor576bits(A, state, input)
+ rounds
+#if defined(UseMMX)
+ _mm_empty();
+#endif
+}
+#endif
+
+#ifdef ProvideFast832
+static void KeccakPermutationOnWordsAfterXoring832bits(UINT64 *state, const UINT64 *input)
+{
+ declareABCDE
+#if (Unrolling != 24)
+ unsigned int i;
+#endif
+
+ copyFromStateAndXor832bits(A, state, input)
+ rounds
+#if defined(UseMMX)
+ _mm_empty();
+#endif
+}
+#endif
+
+#ifdef ProvideFast1024
+static void KeccakPermutationOnWordsAfterXoring1024bits(UINT64 *state, const UINT64 *input)
+{
+ declareABCDE
+#if (Unrolling != 24)
+ unsigned int i;
+#endif
+
+ copyFromStateAndXor1024bits(A, state, input)
+ rounds
+#if defined(UseMMX)
+ _mm_empty();
+#endif
+}
+#endif
+
+#ifdef ProvideFast1088
+static void KeccakPermutationOnWordsAfterXoring1088bits(UINT64 *state, const UINT64 *input)
+{
+ declareABCDE
+#if (Unrolling != 24)
+ unsigned int i;
+#endif
+
+ copyFromStateAndXor1088bits(A, state, input)
+ rounds
+#if defined(UseMMX)
+ _mm_empty();
+#endif
+}
+#endif
+
+#ifdef ProvideFast1152
+static void KeccakPermutationOnWordsAfterXoring1152bits(UINT64 *state, const UINT64 *input)
+{
+ declareABCDE
+#if (Unrolling != 24)
+ unsigned int i;
+#endif
+
+ copyFromStateAndXor1152bits(A, state, input)
+ rounds
+#if defined(UseMMX)
+ _mm_empty();
+#endif
+}
+#endif
+
+#ifdef ProvideFast1344
+static void KeccakPermutationOnWordsAfterXoring1344bits(UINT64 *state, const UINT64 *input)
+{
+ declareABCDE
+#if (Unrolling != 24)
+ unsigned int i;
+#endif
+
+ copyFromStateAndXor1344bits(A, state, input)
+ rounds
+#if defined(UseMMX)
+ _mm_empty();
+#endif
+}
+#endif
+
+static void KeccakInitialize()
+{
+}
+
+static void KeccakInitializeState(unsigned char *state)
+{
+ memset(state, 0, 200);
+#ifdef UseBebigokimisa
+ ((UINT64*)state)[ 1] = ~(UINT64)0;
+ ((UINT64*)state)[ 2] = ~(UINT64)0;
+ ((UINT64*)state)[ 8] = ~(UINT64)0;
+ ((UINT64*)state)[12] = ~(UINT64)0;
+ ((UINT64*)state)[17] = ~(UINT64)0;
+ ((UINT64*)state)[20] = ~(UINT64)0;
+#endif
+}
+
+static void KeccakPermutation(unsigned char *state)
+{
+ // We assume the state is always stored as words
+ KeccakPermutationOnWords((UINT64*)state);
+}
+
+#if 0 // Unused in the Qt configuration
+static void fromBytesToWord(UINT64 *word, const UINT8 *bytes)
+{
+ unsigned int i;
+
+ *word = 0;
+ for(i=0; i<(64/8); i++)
+ *word |= (UINT64)(bytes[i]) << (8*i);
+}
+#endif
+
+#ifdef ProvideFast576
+static void KeccakAbsorb576bits(unsigned char *state, const unsigned char *data)
+{
+#if (PLATFORM_BYTE_ORDER == IS_LITTLE_ENDIAN)
+ KeccakPermutationOnWordsAfterXoring576bits((UINT64*)state, (const UINT64*)data);
+#else
+ UINT64 dataAsWords[9];
+ unsigned int i;
+
+ for(i=0; i<9; i++)
+ fromBytesToWord(dataAsWords+i, data+(i*8));
+ KeccakPermutationOnWordsAfterXoring576bits((UINT64*)state, dataAsWords);
+#endif
+}
+#endif
+
+#ifdef ProvideFast832
+static void KeccakAbsorb832bits(unsigned char *state, const unsigned char *data)
+{
+#if (PLATFORM_BYTE_ORDER == IS_LITTLE_ENDIAN)
+ KeccakPermutationOnWordsAfterXoring832bits((UINT64*)state, (const UINT64*)data);
+#else
+ UINT64 dataAsWords[13];
+ unsigned int i;
+
+ for(i=0; i<13; i++)
+ fromBytesToWord(dataAsWords+i, data+(i*8));
+ KeccakPermutationOnWordsAfterXoring832bits((UINT64*)state, dataAsWords);
+#endif
+}
+#endif
+
+#ifdef ProvideFast1024
+static void KeccakAbsorb1024bits(unsigned char *state, const unsigned char *data)
+{
+#if (PLATFORM_BYTE_ORDER == IS_LITTLE_ENDIAN)
+ KeccakPermutationOnWordsAfterXoring1024bits((UINT64*)state, (const UINT64*)data);
+#else
+ UINT64 dataAsWords[16];
+ unsigned int i;
+
+ for(i=0; i<16; i++)
+ fromBytesToWord(dataAsWords+i, data+(i*8));
+ KeccakPermutationOnWordsAfterXoring1024bits((UINT64*)state, dataAsWords);
+#endif
+}
+#endif
+
+#ifdef ProvideFast1088
+static void KeccakAbsorb1088bits(unsigned char *state, const unsigned char *data)
+{
+#if (PLATFORM_BYTE_ORDER == IS_LITTLE_ENDIAN)
+ KeccakPermutationOnWordsAfterXoring1088bits((UINT64*)state, (const UINT64*)data);
+#else
+ UINT64 dataAsWords[17];
+ unsigned int i;
+
+ for(i=0; i<17; i++)
+ fromBytesToWord(dataAsWords+i, data+(i*8));
+ KeccakPermutationOnWordsAfterXoring1088bits((UINT64*)state, dataAsWords);
+#endif
+}
+#endif
+
+#ifdef ProvideFast1152
+static void KeccakAbsorb1152bits(unsigned char *state, const unsigned char *data)
+{
+#if (PLATFORM_BYTE_ORDER == IS_LITTLE_ENDIAN)
+ KeccakPermutationOnWordsAfterXoring1152bits((UINT64*)state, (const UINT64*)data);
+#else
+ UINT64 dataAsWords[18];
+ unsigned int i;
+
+ for(i=0; i<18; i++)
+ fromBytesToWord(dataAsWords+i, data+(i*8));
+ KeccakPermutationOnWordsAfterXoring1152bits((UINT64*)state, dataAsWords);
+#endif
+}
+#endif
+
+#ifdef ProvideFast1344
+static void KeccakAbsorb1344bits(unsigned char *state, const unsigned char *data)
+{
+#if (PLATFORM_BYTE_ORDER == IS_LITTLE_ENDIAN)
+ KeccakPermutationOnWordsAfterXoring1344bits((UINT64*)state, (const UINT64*)data);
+#else
+ UINT64 dataAsWords[21];
+ unsigned int i;
+
+ for(i=0; i<21; i++)
+ fromBytesToWord(dataAsWords+i, data+(i*8));
+ KeccakPermutationOnWordsAfterXoring1344bits((UINT64*)state, dataAsWords);
+#endif
+}
+#endif
+
+static void KeccakAbsorb(unsigned char *state, const unsigned char *data, unsigned int laneCount)
+{
+#if (PLATFORM_BYTE_ORDER == IS_LITTLE_ENDIAN)
+ KeccakPermutationOnWordsAfterXoring((UINT64*)state, (const UINT64*)data, laneCount);
+#else
+ UINT64 dataAsWords[25];
+ unsigned int i;
+
+ for(i=0; i<laneCount; i++)
+ fromBytesToWord(dataAsWords+i, data+(i*8));
+ KeccakPermutationOnWordsAfterXoring((UINT64*)state, dataAsWords, laneCount);
+#endif
+}
+
+#if 0 // Unused in the Qt configuration
+static void fromWordToBytes(UINT8 *bytes, const UINT64 word)
+{
+ unsigned int i;
+
+ for(i=0; i<(64/8); i++)
+ bytes[i] = (word >> (8*i)) & 0xFF;
+}
+#endif
+
+#ifdef ProvideFast1024
+static void KeccakExtract1024bits(const unsigned char *state, unsigned char *data)
+{
+#if (PLATFORM_BYTE_ORDER == IS_LITTLE_ENDIAN)
+ memcpy(data, state, 128);
+#else
+ unsigned int i;
+
+ for(i=0; i<16; i++)
+ fromWordToBytes(data+(i*8), ((const UINT64*)state)[i]);
+#endif
+#ifdef UseBebigokimisa
+ ((UINT64*)data)[ 1] = ~((UINT64*)data)[ 1];
+ ((UINT64*)data)[ 2] = ~((UINT64*)data)[ 2];
+ ((UINT64*)data)[ 8] = ~((UINT64*)data)[ 8];
+ ((UINT64*)data)[12] = ~((UINT64*)data)[12];
+#endif
+}
+#endif
+
+static void KeccakExtract(const unsigned char *state, unsigned char *data, unsigned int laneCount)
+{
+#if (PLATFORM_BYTE_ORDER == IS_LITTLE_ENDIAN)
+ memcpy(data, state, laneCount*8);
+#else
+ unsigned int i;
+
+ for(i=0; i<laneCount; i++)
+ fromWordToBytes(data+(i*8), ((const UINT64*)state)[i]);
+#endif
+#ifdef UseBebigokimisa
+ if (laneCount > 1) {
+ ((UINT64*)data)[ 1] = ~((UINT64*)data)[ 1];
+ if (laneCount > 2) {
+ ((UINT64*)data)[ 2] = ~((UINT64*)data)[ 2];
+ if (laneCount > 8) {
+ ((UINT64*)data)[ 8] = ~((UINT64*)data)[ 8];
+ if (laneCount > 12) {
+ ((UINT64*)data)[12] = ~((UINT64*)data)[12];
+ if (laneCount > 17) {
+ ((UINT64*)data)[17] = ~((UINT64*)data)[17];
+ if (laneCount > 20) {
+ ((UINT64*)data)[20] = ~((UINT64*)data)[20];
+ }
+ }
+ }
+ }
+ }
+ }
+#endif
+}
diff --git a/src/3rdparty/sha3/KeccakF-1600-unrolling.macros b/src/3rdparty/sha3/KeccakF-1600-unrolling.macros
new file mode 100755
index 0000000000..83c694ca48
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakF-1600-unrolling.macros
@@ -0,0 +1,124 @@
+/*
+The Keccak sponge function, designed by Guido Bertoni, Joan Daemen,
+Michaël Peeters and Gilles Van Assche. For more information, feedback or
+questions, please refer to our website: http://keccak.noekeon.org/
+
+Implementation by the designers,
+hereby denoted as "the implementer".
+
+To the extent possible under law, the implementer has waived all copyright
+and related or neighboring rights to the source code in this file.
+http://creativecommons.org/publicdomain/zero/1.0/
+*/
+
+#if (Unrolling == 24)
+#define rounds \
+ prepareTheta \
+ thetaRhoPiChiIotaPrepareTheta( 0, A, E) \
+ thetaRhoPiChiIotaPrepareTheta( 1, E, A) \
+ thetaRhoPiChiIotaPrepareTheta( 2, A, E) \
+ thetaRhoPiChiIotaPrepareTheta( 3, E, A) \
+ thetaRhoPiChiIotaPrepareTheta( 4, A, E) \
+ thetaRhoPiChiIotaPrepareTheta( 5, E, A) \
+ thetaRhoPiChiIotaPrepareTheta( 6, A, E) \
+ thetaRhoPiChiIotaPrepareTheta( 7, E, A) \
+ thetaRhoPiChiIotaPrepareTheta( 8, A, E) \
+ thetaRhoPiChiIotaPrepareTheta( 9, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(10, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(11, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(12, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(13, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(14, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(15, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(16, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(17, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(18, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(19, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(20, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(21, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(22, A, E) \
+ thetaRhoPiChiIota(23, E, A) \
+ copyToState(state, A)
+#elif (Unrolling == 12)
+#define rounds \
+ prepareTheta \
+ for(i=0; i<24; i+=12) { \
+ thetaRhoPiChiIotaPrepareTheta(i , A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+ 1, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(i+ 2, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+ 3, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(i+ 4, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+ 5, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(i+ 6, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+ 7, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(i+ 8, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+ 9, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(i+10, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+11, E, A) \
+ } \
+ copyToState(state, A)
+#elif (Unrolling == 8)
+#define rounds \
+ prepareTheta \
+ for(i=0; i<24; i+=8) { \
+ thetaRhoPiChiIotaPrepareTheta(i , A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+1, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(i+2, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+3, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(i+4, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+5, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(i+6, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+7, E, A) \
+ } \
+ copyToState(state, A)
+#elif (Unrolling == 6)
+#define rounds \
+ prepareTheta \
+ for(i=0; i<24; i+=6) { \
+ thetaRhoPiChiIotaPrepareTheta(i , A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+1, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(i+2, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+3, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(i+4, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+5, E, A) \
+ } \
+ copyToState(state, A)
+#elif (Unrolling == 4)
+#define rounds \
+ prepareTheta \
+ for(i=0; i<24; i+=4) { \
+ thetaRhoPiChiIotaPrepareTheta(i , A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+1, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(i+2, A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+3, E, A) \
+ } \
+ copyToState(state, A)
+#elif (Unrolling == 3)
+#define rounds \
+ prepareTheta \
+ for(i=0; i<24; i+=3) { \
+ thetaRhoPiChiIotaPrepareTheta(i , A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+1, E, A) \
+ thetaRhoPiChiIotaPrepareTheta(i+2, A, E) \
+ copyStateVariables(A, E) \
+ } \
+ copyToState(state, A)
+#elif (Unrolling == 2)
+#define rounds \
+ prepareTheta \
+ for(i=0; i<24; i+=2) { \
+ thetaRhoPiChiIotaPrepareTheta(i , A, E) \
+ thetaRhoPiChiIotaPrepareTheta(i+1, E, A) \
+ } \
+ copyToState(state, A)
+#elif (Unrolling == 1)
+#define rounds \
+ prepareTheta \
+ for(i=0; i<24; i++) { \
+ thetaRhoPiChiIotaPrepareTheta(i , A, E) \
+ copyStateVariables(A, E) \
+ } \
+ copyToState(state, A)
+#else
+#error "Unrolling is not correctly specified!"
+#endif
diff --git a/src/3rdparty/sha3/KeccakNISTInterface.c b/src/3rdparty/sha3/KeccakNISTInterface.c
new file mode 100755
index 0000000000..e530a11db5
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakNISTInterface.c
@@ -0,0 +1,82 @@
+/*
+The Keccak sponge function, designed by Guido Bertoni, Joan Daemen,
+Michaël Peeters and Gilles Van Assche. For more information, feedback or
+questions, please refer to our website: http://keccak.noekeon.org/
+
+Implementation by the designers,
+hereby denoted as "the implementer".
+
+To the extent possible under law, the implementer has waived all copyright
+and related or neighboring rights to the source code in this file.
+http://creativecommons.org/publicdomain/zero/1.0/
+*/
+
+#include <string.h>
+//#include "KeccakNISTInterface.h"
+#include "KeccakF-1600-interface.h"
+
+static HashReturn Init(hashState *state, int hashbitlen)
+{
+ switch(hashbitlen) {
+ case 0: // Default parameters, arbitrary length output
+ InitSponge((spongeState*)state, 1024, 576);
+ break;
+ case 224:
+ InitSponge((spongeState*)state, 1152, 448);
+ break;
+ case 256:
+ InitSponge((spongeState*)state, 1088, 512);
+ break;
+ case 384:
+ InitSponge((spongeState*)state, 832, 768);
+ break;
+ case 512:
+ InitSponge((spongeState*)state, 576, 1024);
+ break;
+ default:
+ return BAD_HASHLEN;
+ }
+ state->fixedOutputLength = hashbitlen;
+ return SUCCESS;
+}
+
+static HashReturn Update(hashState *state, const BitSequence *data, DataLength databitlen)
+{
+ if ((databitlen % 8) == 0)
+ return (HashReturn) Absorb((spongeState*)state, data, databitlen);
+ else {
+ HashReturn ret = (HashReturn) Absorb((spongeState*)state, data, databitlen - (databitlen % 8));
+ if (ret == SUCCESS) {
+ unsigned char lastByte;
+ // Align the last partial byte to the least significant bits
+ lastByte = data[databitlen/8] >> (8 - (databitlen % 8));
+ return (HashReturn) Absorb((spongeState*)state, &lastByte, databitlen % 8);
+ }
+ else
+ return ret;
+ }
+}
+
+static HashReturn Final(hashState *state, BitSequence *hashval)
+{
+ return (HashReturn) Squeeze(state, hashval, state->fixedOutputLength);
+}
+
+#ifndef QT_BUILDING_QT
+static HashReturn Hash(int hashbitlen, const BitSequence *data, DataLength databitlen, BitSequence *hashval)
+{
+ hashState state;
+ HashReturn result;
+
+ if ((hashbitlen != 224) && (hashbitlen != 256) && (hashbitlen != 384) && (hashbitlen != 512))
+ return BAD_HASHLEN; // Only the four fixed output lengths available through this API
+ result = Init(&state, hashbitlen);
+ if (result != SUCCESS)
+ return result;
+ result = Update(&state, data, databitlen);
+ if (result != SUCCESS)
+ return result;
+ result = Final(&state, hashval);
+ return result;
+}
+#endif
diff --git a/src/3rdparty/sha3/KeccakNISTInterface.h b/src/3rdparty/sha3/KeccakNISTInterface.h
new file mode 100755
index 0000000000..cd85f24aa7
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakNISTInterface.h
@@ -0,0 +1,70 @@
+/*
+The Keccak sponge function, designed by Guido Bertoni, Joan Daemen,
+Michaël Peeters and Gilles Van Assche. For more information, feedback or
+questions, please refer to our website: http://keccak.noekeon.org/
+
+Implementation by the designers,
+hereby denoted as "the implementer".
+
+To the extent possible under law, the implementer has waived all copyright
+and related or neighboring rights to the source code in this file.
+http://creativecommons.org/publicdomain/zero/1.0/
+*/
+
+#ifndef _KeccakNISTInterface_h_
+#define _KeccakNISTInterface_h_
+
+#include "KeccakSponge.h"
+
+typedef unsigned char BitSequence;
+typedef unsigned long long DataLength;
+typedef enum { SUCCESS = 0, FAIL = 1, BAD_HASHLEN = 2 } HashReturn;
+
+typedef spongeState hashState;
+
+/**
+ * Function to initialize the state of the Keccak[r, c] sponge function.
+ * The rate r and capacity c values are determined from @a hashbitlen.
+ * @param state Pointer to the state of the sponge function to be initialized.
+ * @param hashbitlen The desired number of output bits,
+ * or 0 for Keccak[] with default parameters
+ * and arbitrarily-long output.
+ * @pre The value of hashbitlen must be one of 0, 224, 256, 384 and 512.
+ * @return SUCCESS if successful, BAD_HASHLEN if the value of hashbitlen is incorrect.
+ */
+static HashReturn Init(hashState *state, int hashbitlen);
+/**
+ * Function to give input data for the sponge function to absorb.
+ * @param state Pointer to the state of the sponge function initialized by Init().
+ * @param data Pointer to the input data.
+ * When @a databitLen is not a multiple of 8, the last bits of data must be
+ * in the most significant bits of the last byte.
+ * @param databitLen The number of input bits provided in the input data.
+ * @pre In the previous call to Absorb(), databitLen was a multiple of 8.
+ * @return SUCCESS if successful, FAIL otherwise.
+ */
+static HashReturn Update(hashState *state, const BitSequence *data, DataLength databitlen);
+/**
+ * Function to squeeze output data from the sponge function.
+ * If @a hashbitlen was not 0 in the call to Init(), the number of output bits is equal to @a hashbitlen.
+ * If @a hashbitlen was 0 in the call to Init(), the output bits must be extracted using the Squeeze() function.
+ * @param state Pointer to the state of the sponge function initialized by Init().
+ * @param hashval Pointer to the buffer where to store the output data.
+ * @return SUCCESS if successful, FAIL otherwise.
+ */
+static HashReturn Final(hashState *state, BitSequence *hashval);
+/**
+ * Function to compute a hash using the Keccak[r, c] sponge function.
+ * The rate r and capacity c values are determined from @a hashbitlen.
+ * @param hashbitlen The desired number of output bits.
+ * @param data Pointer to the input data.
+ * When @a databitLen is not a multiple of 8, the last bits of data must be
+ * in the most significant bits of the last byte.
+ * @param databitLen The number of input bits provided in the input data.
+ * @param hashval Pointer to the buffer where to store the output data.
+ * @pre The value of hashbitlen must be one of 224, 256, 384 and 512.
+ * @return SUCCESS if successful, BAD_HASHLEN if the value of hashbitlen is incorrect.
+ */
+static HashReturn Hash(int hashbitlen, const BitSequence *data, DataLength databitlen, BitSequence *hashval);
+
+#endif
diff --git a/src/3rdparty/sha3/KeccakSponge.c b/src/3rdparty/sha3/KeccakSponge.c
new file mode 100755
index 0000000000..6f3da95dbb
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakSponge.c
@@ -0,0 +1,266 @@
+/*
+The Keccak sponge function, designed by Guido Bertoni, Joan Daemen,
+Michaël Peeters and Gilles Van Assche. For more information, feedback or
+questions, please refer to our website: http://keccak.noekeon.org/
+
+Implementation by the designers,
+hereby denoted as "the implementer".
+
+To the extent possible under law, the implementer has waived all copyright
+and related or neighboring rights to the source code in this file.
+http://creativecommons.org/publicdomain/zero/1.0/
+*/
+
+#include <string.h>
+#include "KeccakSponge.h"
+#include "KeccakF-1600-interface.h"
+#ifdef KeccakReference
+#include "displayIntermediateValues.h"
+#endif
+
+static int InitSponge(spongeState *state, unsigned int rate, unsigned int capacity)
+{
+ if (rate+capacity != 1600)
+ return 1;
+ if ((rate <= 0) || (rate >= 1600) || ((rate % 64) != 0))
+ return 1;
+ KeccakInitialize();
+ state->rate = rate;
+ state->capacity = capacity;
+ state->fixedOutputLength = 0;
+ KeccakInitializeState(state->state);
+ memset(state->dataQueue, 0, KeccakMaximumRateInBytes);
+ state->bitsInQueue = 0;
+ state->squeezing = 0;
+ state->bitsAvailableForSqueezing = 0;
+
+ return 0;
+}
+
+static void AbsorbQueue(spongeState *state)
+{
+ // state->bitsInQueue is assumed to be equal to state->rate
+ #ifdef KeccakReference
+ displayBytes(1, "Block to be absorbed", state->dataQueue, state->rate/8);
+ #endif
+#ifdef ProvideFast576
+ if (state->rate == 576)
+ KeccakAbsorb576bits(state->state, state->dataQueue);
+ else
+#endif
+#ifdef ProvideFast832
+ if (state->rate == 832)
+ KeccakAbsorb832bits(state->state, state->dataQueue);
+ else
+#endif
+#ifdef ProvideFast1024
+ if (state->rate == 1024)
+ KeccakAbsorb1024bits(state->state, state->dataQueue);
+ else
+#endif
+#ifdef ProvideFast1088
+ if (state->rate == 1088)
+ KeccakAbsorb1088bits(state->state, state->dataQueue);
+ else
+#endif
+#ifdef ProvideFast1152
+ if (state->rate == 1152)
+ KeccakAbsorb1152bits(state->state, state->dataQueue);
+ else
+#endif
+#ifdef ProvideFast1344
+ if (state->rate == 1344)
+ KeccakAbsorb1344bits(state->state, state->dataQueue);
+ else
+#endif
+ KeccakAbsorb(state->state, state->dataQueue, state->rate/64);
+ state->bitsInQueue = 0;
+}
+
+static int Absorb(spongeState *state, const unsigned char *data, unsigned long long databitlen)
+{
+ unsigned long long i, j, wholeBlocks;
+ unsigned int partialBlock, partialByte;
+ const unsigned char *curData;
+
+ if ((state->bitsInQueue % 8) != 0)
+ return 1; // Only the last call may contain a partial byte
+ if (state->squeezing)
+ return 1; // Too late for additional input
+
+ i = 0;
+ while(i < databitlen) {
+ if ((state->bitsInQueue == 0) && (databitlen >= state->rate) && (i <= (databitlen-state->rate))) {
+ wholeBlocks = (databitlen-i)/state->rate;
+ curData = data+i/8;
+#ifdef ProvideFast576
+ if (state->rate == 576) {
+ for(j=0; j<wholeBlocks; j++, curData+=576/8) {
+ #ifdef KeccakReference
+ displayBytes(1, "Block to be absorbed", curData, state->rate/8);
+ #endif
+ KeccakAbsorb576bits(state->state, curData);
+ }
+ }
+ else
+#endif
+#ifdef ProvideFast832
+ if (state->rate == 832) {
+ for(j=0; j<wholeBlocks; j++, curData+=832/8) {
+ #ifdef KeccakReference
+ displayBytes(1, "Block to be absorbed", curData, state->rate/8);
+ #endif
+ KeccakAbsorb832bits(state->state, curData);
+ }
+ }
+ else
+#endif
+#ifdef ProvideFast1024
+ if (state->rate == 1024) {
+ for(j=0; j<wholeBlocks; j++, curData+=1024/8) {
+ #ifdef KeccakReference
+ displayBytes(1, "Block to be absorbed", curData, state->rate/8);
+ #endif
+ KeccakAbsorb1024bits(state->state, curData);
+ }
+ }
+ else
+#endif
+#ifdef ProvideFast1088
+ if (state->rate == 1088) {
+ for(j=0; j<wholeBlocks; j++, curData+=1088/8) {
+ #ifdef KeccakReference
+ displayBytes(1, "Block to be absorbed", curData, state->rate/8);
+ #endif
+ KeccakAbsorb1088bits(state->state, curData);
+ }
+ }
+ else
+#endif
+#ifdef ProvideFast1152
+ if (state->rate == 1152) {
+ for(j=0; j<wholeBlocks; j++, curData+=1152/8) {
+ #ifdef KeccakReference
+ displayBytes(1, "Block to be absorbed", curData, state->rate/8);
+ #endif
+ KeccakAbsorb1152bits(state->state, curData);
+ }
+ }
+ else
+#endif
+#ifdef ProvideFast1344
+ if (state->rate == 1344) {
+ for(j=0; j<wholeBlocks; j++, curData+=1344/8) {
+ #ifdef KeccakReference
+ displayBytes(1, "Block to be absorbed", curData, state->rate/8);
+ #endif
+ KeccakAbsorb1344bits(state->state, curData);
+ }
+ }
+ else
+#endif
+ {
+ for(j=0; j<wholeBlocks; j++, curData+=state->rate/8) {
+ #ifdef KeccakReference
+ displayBytes(1, "Block to be absorbed", curData, state->rate/8);
+ #endif
+ KeccakAbsorb(state->state, curData, state->rate/64);
+ }
+ }
+ i += wholeBlocks*state->rate;
+ }
+ else {
+ partialBlock = (unsigned int)(databitlen - i);
+ if (partialBlock+state->bitsInQueue > state->rate)
+ partialBlock = state->rate-state->bitsInQueue;
+ partialByte = partialBlock % 8;
+ partialBlock -= partialByte;
+ memcpy(state->dataQueue+state->bitsInQueue/8, data+i/8, partialBlock/8);
+ state->bitsInQueue += partialBlock;
+ i += partialBlock;
+ if (state->bitsInQueue == state->rate)
+ AbsorbQueue(state);
+ if (partialByte > 0) {
+ unsigned char mask = (1 << partialByte)-1;
+ state->dataQueue[state->bitsInQueue/8] = data[i/8] & mask;
+ state->bitsInQueue += partialByte;
+ i += partialByte;
+ }
+ }
+ }
+ return 0;
+}
+
+static void PadAndSwitchToSqueezingPhase(spongeState *state)
+{
+ // Note: the bits are numbered from 0=LSB to 7=MSB
+ if (state->bitsInQueue + 1 == state->rate) {
+ state->dataQueue[state->bitsInQueue/8 ] |= 1 << (state->bitsInQueue % 8);
+ AbsorbQueue(state);
+ memset(state->dataQueue, 0, state->rate/8);
+ }
+ else {
+ memset(state->dataQueue + (state->bitsInQueue+7)/8, 0, state->rate/8 - (state->bitsInQueue+7)/8);
+ state->dataQueue[state->bitsInQueue/8 ] |= 1 << (state->bitsInQueue % 8);
+ }
+ state->dataQueue[(state->rate-1)/8] |= 1 << ((state->rate-1) % 8);
+ AbsorbQueue(state);
+
+ #ifdef KeccakReference
+ displayText(1, "--- Switching to squeezing phase ---");
+ #endif
+#ifdef ProvideFast1024
+ if (state->rate == 1024) {
+ KeccakExtract1024bits(state->state, state->dataQueue);
+ state->bitsAvailableForSqueezing = 1024;
+ }
+ else
+#endif
+ {
+ KeccakExtract(state->state, state->dataQueue, state->rate/64);
+ state->bitsAvailableForSqueezing = state->rate;
+ }
+ #ifdef KeccakReference
+ displayBytes(1, "Block available for squeezing", state->dataQueue, state->bitsAvailableForSqueezing/8);
+ #endif
+ state->squeezing = 1;
+}
+
+static int Squeeze(spongeState *state, unsigned char *output, unsigned long long outputLength)
+{
+ unsigned long long i;
+ unsigned int partialBlock;
+
+ if (!state->squeezing)
+ PadAndSwitchToSqueezingPhase(state);
+ if ((outputLength % 8) != 0)
+ return 1; // Only multiple of 8 bits are allowed, truncation can be done at user level
+
+ i = 0;
+ while(i < outputLength) {
+ if (state->bitsAvailableForSqueezing == 0) {
+ KeccakPermutation(state->state);
+#ifdef ProvideFast1024
+ if (state->rate == 1024) {
+ KeccakExtract1024bits(state->state, state->dataQueue);
+ state->bitsAvailableForSqueezing = 1024;
+ }
+ else
+#endif
+ {
+ KeccakExtract(state->state, state->dataQueue, state->rate/64);
+ state->bitsAvailableForSqueezing = state->rate;
+ }
+ #ifdef KeccakReference
+ displayBytes(1, "Block available for squeezing", state->dataQueue, state->bitsAvailableForSqueezing/8);
+ #endif
+ }
+ partialBlock = state->bitsAvailableForSqueezing;
+ if ((unsigned long long)partialBlock > outputLength - i)
+ partialBlock = (unsigned int)(outputLength - i);
+ memcpy(output+i/8, state->dataQueue+(state->rate-state->bitsAvailableForSqueezing)/8, partialBlock/8);
+ state->bitsAvailableForSqueezing -= partialBlock;
+ i += partialBlock;
+ }
+ return 0;
+}
diff --git a/src/3rdparty/sha3/KeccakSponge.h b/src/3rdparty/sha3/KeccakSponge.h
new file mode 100755
index 0000000000..a545cacb30
--- /dev/null
+++ b/src/3rdparty/sha3/KeccakSponge.h
@@ -0,0 +1,76 @@
+/*
+The Keccak sponge function, designed by Guido Bertoni, Joan Daemen,
+Michaël Peeters and Gilles Van Assche. For more information, feedback or
+questions, please refer to our website: http://keccak.noekeon.org/
+
+Implementation by the designers,
+hereby denoted as "the implementer".
+
+To the extent possible under law, the implementer has waived all copyright
+and related or neighboring rights to the source code in this file.
+http://creativecommons.org/publicdomain/zero/1.0/
+*/
+
+#ifndef _KeccakSponge_h_
+#define _KeccakSponge_h_
+
+#define KeccakPermutationSize 1600
+#define KeccakPermutationSizeInBytes (KeccakPermutationSize/8)
+#define KeccakMaximumRate 1536
+#define KeccakMaximumRateInBytes (KeccakMaximumRate/8)
+
+#if defined(__GNUC__)
+#define ALIGN __attribute__ ((aligned(32)))
+#elif defined(_MSC_VER)
+#define ALIGN __declspec(align(32))
+#else
+#define ALIGN
+#endif
+
+ALIGN typedef struct spongeStateStruct {
+ ALIGN unsigned char state[KeccakPermutationSizeInBytes];
+ ALIGN unsigned char dataQueue[KeccakMaximumRateInBytes];
+ unsigned int rate;
+ unsigned int capacity;
+ unsigned int bitsInQueue;
+ unsigned int fixedOutputLength;
+ int squeezing;
+ unsigned int bitsAvailableForSqueezing;
+} spongeState;
+
+/**
+ * Function to initialize the state of the Keccak[r, c] sponge function.
+ * The sponge function is set to the absorbing phase.
+ * @param state Pointer to the state of the sponge function to be initialized.
+ * @param rate The value of the rate r.
+ * @param capacity The value of the capacity c.
+ * @pre One must have r+c=1600 and the rate a multiple of 64 bits in this implementation.
+ * @return Zero if successful, 1 otherwise.
+ */
+static int InitSponge(spongeState *state, unsigned int rate, unsigned int capacity);
+/**
+ * Function to give input data for the sponge function to absorb.
+ * @param state Pointer to the state of the sponge function initialized by InitSponge().
+ * @param data Pointer to the input data.
+ * When @a databitLen is not a multiple of 8, the last bits of data must be
+ * in the least significant bits of the last byte.
+ * @param databitLen The number of input bits provided in the input data.
+ * @pre In the previous call to Absorb(), databitLen was a multiple of 8.
+ * @pre The sponge function must be in the absorbing phase,
+ * i.e., Squeeze() must not have been called before.
+ * @return Zero if successful, 1 otherwise.
+ */
+static int Absorb(spongeState *state, const unsigned char *data, unsigned long long databitlen);
+/**
+ * Function to squeeze output data from the sponge function.
+ * If the sponge function was in the absorbing phase, this function
+ * switches it to the squeezing phase.
+ * @param state Pointer to the state of the sponge function initialized by InitSponge().
+ * @param output Pointer to the buffer where to store the output data.
+ * @param outputLength The number of output bits desired.
+ * It must be a multiple of 8.
+ * @return Zero if successful, 1 otherwise.
+ */
+static int Squeeze(spongeState *state, unsigned char *output, unsigned long long outputLength);
+
+#endif
diff --git a/src/3rdparty/sha3/brg_endian.h b/src/3rdparty/sha3/brg_endian.h
new file mode 100755
index 0000000000..7226eb3bec
--- /dev/null
+++ b/src/3rdparty/sha3/brg_endian.h
@@ -0,0 +1,142 @@
+/*
+ ---------------------------------------------------------------------------
+ Copyright (c) 1998-2008, Brian Gladman, Worcester, UK. All rights reserved.
+
+ LICENSE TERMS
+
+ The redistribution and use of this software (with or without changes)
+ is allowed without the payment of fees or royalties provided that:
+
+ 1. source code distributions include the above copyright notice, this
+ list of conditions and the following disclaimer;
+
+ 2. binary distributions include the above copyright notice, this list
+ of conditions and the following disclaimer in their documentation;
+
+ 3. the name of the copyright holder is not used to endorse products
+ built using this software without specific written permission.
+
+ DISCLAIMER
+
+ This software is provided 'as is' with no explicit or implied warranties
+ in respect of its properties, including, but not limited to, correctness
+ and/or fitness for purpose.
+ ---------------------------------------------------------------------------
+ Issue Date: 20/12/2007
+ Changes for ARM 9/9/2010
+*/
+
+#ifndef _BRG_ENDIAN_H
+#define _BRG_ENDIAN_H
+
+#define IS_BIG_ENDIAN 4321 /* byte 0 is most significant (mc68k) */
+#define IS_LITTLE_ENDIAN 1234 /* byte 0 is least significant (i386) */
+
+#if 0
+/* Include files where endian defines and byteswap functions may reside */
+#if defined( __sun )
+# include <sys/isa_defs.h>
+#elif defined( __FreeBSD__ ) || defined( __OpenBSD__ ) || defined( __NetBSD__ )
+# include <sys/endian.h>
+#elif defined( BSD ) && ( BSD >= 199103 ) || defined( __APPLE__ ) || \
+ defined( __CYGWIN32__ ) || defined( __DJGPP__ ) || defined( __osf__ )
+# include <machine/endian.h>
+#elif defined( __linux__ ) || defined( __GNUC__ ) || defined( __GNU_LIBRARY__ )
+# if !defined( __MINGW32__ ) && !defined( _AIX )
+# include <endian.h>
+# if !defined( __BEOS__ )
+# include <byteswap.h>
+# endif
+# endif
+#endif
+#endif
+
+/* Now attempt to set the define for platform byte order using any */
+/* of the four forms SYMBOL, _SYMBOL, __SYMBOL & __SYMBOL__, which */
+/* seem to encompass most endian symbol definitions */
+
+#if defined( BIG_ENDIAN ) && defined( LITTLE_ENDIAN )
+# if defined( BYTE_ORDER ) && BYTE_ORDER == BIG_ENDIAN
+# define PLATFORM_BYTE_ORDER IS_BIG_ENDIAN
+# elif defined( BYTE_ORDER ) && BYTE_ORDER == LITTLE_ENDIAN
+# define PLATFORM_BYTE_ORDER IS_LITTLE_ENDIAN
+# endif
+#elif defined( BIG_ENDIAN )
+# define PLATFORM_BYTE_ORDER IS_BIG_ENDIAN
+#elif defined( LITTLE_ENDIAN )
+# define PLATFORM_BYTE_ORDER IS_LITTLE_ENDIAN
+#endif
+
+#if defined( _BIG_ENDIAN ) && defined( _LITTLE_ENDIAN )
+# if defined( _BYTE_ORDER ) && _BYTE_ORDER == _BIG_ENDIAN
+# define PLATFORM_BYTE_ORDER IS_BIG_ENDIAN
+# elif defined( _BYTE_ORDER ) && _BYTE_ORDER == _LITTLE_ENDIAN
+# define PLATFORM_BYTE_ORDER IS_LITTLE_ENDIAN
+# endif
+#elif defined( _BIG_ENDIAN )
+# define PLATFORM_BYTE_ORDER IS_BIG_ENDIAN
+#elif defined( _LITTLE_ENDIAN )
+# define PLATFORM_BYTE_ORDER IS_LITTLE_ENDIAN
+#endif
+
+#if defined( __BIG_ENDIAN ) && defined( __LITTLE_ENDIAN )
+# if defined( __BYTE_ORDER ) && __BYTE_ORDER == __BIG_ENDIAN
+# define PLATFORM_BYTE_ORDER IS_BIG_ENDIAN
+# elif defined( __BYTE_ORDER ) && __BYTE_ORDER == __LITTLE_ENDIAN
+# define PLATFORM_BYTE_ORDER IS_LITTLE_ENDIAN
+# endif
+#elif defined( __BIG_ENDIAN )
+# define PLATFORM_BYTE_ORDER IS_BIG_ENDIAN
+#elif defined( __LITTLE_ENDIAN )
+# define PLATFORM_BYTE_ORDER IS_LITTLE_ENDIAN
+#endif
+
+#if defined( __BIG_ENDIAN__ ) && defined( __LITTLE_ENDIAN__ )
+# if defined( __BYTE_ORDER__ ) && __BYTE_ORDER__ == __BIG_ENDIAN__
+# define PLATFORM_BYTE_ORDER IS_BIG_ENDIAN
+# elif defined( __BYTE_ORDER__ ) && __BYTE_ORDER__ == __LITTLE_ENDIAN__
+# define PLATFORM_BYTE_ORDER IS_LITTLE_ENDIAN
+# endif
+#elif defined( __BIG_ENDIAN__ )
+# define PLATFORM_BYTE_ORDER IS_BIG_ENDIAN
+#elif defined( __LITTLE_ENDIAN__ )
+# define PLATFORM_BYTE_ORDER IS_LITTLE_ENDIAN
+#endif
+
+/* if the platform byte order could not be determined, then try to */
+/* set this define using common machine defines */
+#if !defined(PLATFORM_BYTE_ORDER)
+
+#if defined( __alpha__ ) || defined( __alpha ) || defined( i386 ) || \
+ defined( __i386__ ) || defined( _M_I86 ) || defined( _M_IX86 ) || \
+ defined( __OS2__ ) || defined( sun386 ) || defined( __TURBOC__ ) || \
+ defined( vax ) || defined( vms ) || defined( VMS ) || \
+ defined( __VMS ) || defined( _M_X64 )
+# define PLATFORM_BYTE_ORDER IS_LITTLE_ENDIAN
+
+#elif defined( AMIGA ) || defined( applec ) || defined( __AS400__ ) || \
+ defined( _CRAY ) || defined( __hppa ) || defined( __hp9000 ) || \
+ defined( ibm370 ) || defined( mc68000 ) || defined( m68k ) || \
+ defined( __MRC__ ) || defined( __MVS__ ) || defined( __MWERKS__ ) || \
+ defined( sparc ) || defined( __sparc) || defined( SYMANTEC_C ) || \
+ defined( __VOS__ ) || defined( __TIGCC__ ) || defined( __TANDEM ) || \
+ defined( THINK_C ) || defined( __VMCMS__ ) || defined( _AIX )
+# define PLATFORM_BYTE_ORDER IS_BIG_ENDIAN
+
+#elif defined(__arm__)
+# ifdef __BIG_ENDIAN
+# define PLATFORM_BYTE_ORDER IS_BIG_ENDIAN
+# else
+# define PLATFORM_BYTE_ORDER IS_LITTLE_ENDIAN
+# endif
+#elif 1 /* **** EDIT HERE IF NECESSARY **** */
+# define PLATFORM_BYTE_ORDER IS_LITTLE_ENDIAN
+#elif 0 /* **** EDIT HERE IF NECESSARY **** */
+# define PLATFORM_BYTE_ORDER IS_BIG_ENDIAN
+#else
+# error Please edit lines 132 or 134 in brg_endian.h to set the platform byte order
+#endif
+
+#endif
+
+#endif
diff --git a/src/3rdparty/sqlite/shell.c b/src/3rdparty/sqlite/shell.c
index a54c922e87..c6d7fa3d53 100644
--- a/src/3rdparty/sqlite/shell.c
+++ b/src/3rdparty/sqlite/shell.c
@@ -12,11 +12,22 @@
** This file contains code to implement the "sqlite" command line
** utility for accessing SQLite databases.
*/
-#if defined(_WIN32) || defined(WIN32)
+#if (defined(_WIN32) || defined(WIN32)) && !defined(_CRT_SECURE_NO_WARNINGS)
/* This needs to come before any includes for MSVC compiler */
#define _CRT_SECURE_NO_WARNINGS
#endif
+/*
+** Enable large-file support for fopen() and friends on unix.
+*/
+#ifndef SQLITE_DISABLE_LFS
+# define _LARGE_FILE 1
+# ifndef _FILE_OFFSET_BITS
+# define _FILE_OFFSET_BITS 64
+# endif
+# define _LARGEFILE_SOURCE 1
+#endif
+
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
@@ -25,7 +36,7 @@
#include <ctype.h>
#include <stdarg.h>
-#if !defined(_WIN32) && !defined(WIN32) && !defined(__OS2__)
+#if !defined(_WIN32) && !defined(WIN32)
# include <signal.h>
# if !defined(__RTP__) && !defined(_WRS_KERNEL)
# include <pwd.h>
@@ -34,10 +45,6 @@
# include <sys/types.h>
#endif
-#ifdef __OS2__
-# include <unistd.h>
-#endif
-
#ifdef HAVE_EDITLINE
# include <editline/editline.h>
#endif
@@ -46,7 +53,7 @@
# include <readline/history.h>
#endif
#if !defined(HAVE_EDITLINE) && (!defined(HAVE_READLINE) || HAVE_READLINE!=1)
-# define readline(p) local_getline(p,stdin)
+# define readline(p) local_getline(p,stdin,0)
# define add_history(X)
# define read_history(X)
# define write_history(X)
@@ -57,10 +64,14 @@
# include <io.h>
#define isatty(h) _isatty(h)
#define access(f,m) _access((f),(m))
+#undef popen
+#define popen(a,b) _popen((a),(b))
+#undef pclose
+#define pclose(x) _pclose(x)
#else
/* Make sure isatty() has a prototype.
*/
-extern int isatty();
+extern int isatty(int);
#endif
#if defined(_WIN32_WCE)
@@ -74,7 +85,13 @@ extern int isatty();
/* True if the timer is enabled */
static int enableTimer = 0;
-#if !defined(_WIN32) && !defined(WIN32) && !defined(__OS2__) && !defined(__RTP__) && !defined(_WRS_KERNEL)
+/* ctype macros that work with signed characters */
+#define IsSpace(X) isspace((unsigned char)X)
+#define IsDigit(X) isdigit((unsigned char)X)
+#define ToLower(X) (char)tolower((unsigned char)X)
+
+#if !defined(_WIN32) && !defined(WIN32) && !defined(_WRS_KERNEL) \
+ && !defined(__minux)
#include <sys/time.h>
#include <sys/resource.h>
@@ -265,23 +282,23 @@ static void iotracePrintf(const char *zFormat, ...){
*/
static int isNumber(const char *z, int *realnum){
if( *z=='-' || *z=='+' ) z++;
- if( !isdigit(*z) ){
+ if( !IsDigit(*z) ){
return 0;
}
z++;
if( realnum ) *realnum = 0;
- while( isdigit(*z) ){ z++; }
+ while( IsDigit(*z) ){ z++; }
if( *z=='.' ){
z++;
- if( !isdigit(*z) ) return 0;
- while( isdigit(*z) ){ z++; }
+ if( !IsDigit(*z) ) return 0;
+ while( IsDigit(*z) ){ z++; }
if( realnum ) *realnum = 1;
}
if( *z=='e' || *z=='E' ){
z++;
if( *z=='+' || *z=='-' ) z++;
- if( !isdigit(*z) ) return 0;
- while( isdigit(*z) ){ z++; }
+ if( !IsDigit(*z) ) return 0;
+ while( IsDigit(*z) ){ z++; }
if( realnum ) *realnum = 1;
}
return *z==0;
@@ -318,11 +335,11 @@ static void shellstaticFunc(
** The interface is like "readline" but no command-line editing
** is done.
*/
-static char *local_getline(char *zPrompt, FILE *in){
+static char *local_getline(char *zPrompt, FILE *in, int csvFlag){
char *zLine;
int nLine;
int n;
- int eol;
+ int inQuote = 0;
if( zPrompt && *zPrompt ){
printf("%s",zPrompt);
@@ -332,8 +349,7 @@ static char *local_getline(char *zPrompt, FILE *in){
zLine = malloc( nLine );
if( zLine==0 ) return 0;
n = 0;
- eol = 0;
- while( !eol ){
+ while( 1 ){
if( n+100>nLine ){
nLine = nLine*2 + 100;
zLine = realloc(zLine, nLine);
@@ -345,15 +361,17 @@ static char *local_getline(char *zPrompt, FILE *in){
return 0;
}
zLine[n] = 0;
- eol = 1;
break;
}
- while( zLine[n] ){ n++; }
- if( n>0 && zLine[n-1]=='\n' ){
+ while( zLine[n] ){
+ if( zLine[n]=='"' ) inQuote = !inQuote;
+ n++;
+ }
+ if( n>0 && zLine[n-1]=='\n' && (!inQuote || !csvFlag) ){
n--;
if( n>0 && zLine[n-1]=='\r' ) n--;
zLine[n] = 0;
- eol = 1;
+ break;
}
}
zLine = realloc( zLine, n+1 );
@@ -370,7 +388,7 @@ static char *one_input_line(const char *zPrior, FILE *in){
char *zPrompt;
char *zResult;
if( in!=0 ){
- return local_getline(0, in);
+ return local_getline(0, in, 0);
}
if( zPrior && zPrior[0] ){
zPrompt = continuePrompt;
@@ -402,6 +420,8 @@ struct callback_data {
int statsOn; /* True to display memory stats before each finalize */
int cnt; /* Number of records displayed so far */
FILE *out; /* Write results here */
+ FILE *traceOut; /* Output for sqlite3_trace() */
+ int nErr; /* Number of errors seen */
int mode; /* An output mode setting */
int writableSchema; /* True if PRAGMA writable_schema=ON */
int showHeader; /* True to show column names in List or Column mode */
@@ -478,7 +498,7 @@ static void output_hex_blob(FILE *out, const void *pBlob, int nBlob){
int i;
char *zBlob = (char *)pBlob;
fprintf(out,"X'");
- for(i=0; i<nBlob; i++){ fprintf(out,"%02x",zBlob[i]); }
+ for(i=0; i<nBlob; i++){ fprintf(out,"%02x",zBlob[i]&0xff); }
fprintf(out,"'");
}
@@ -522,6 +542,9 @@ static void output_c_string(FILE *out, const char *z){
if( c=='\\' ){
fputc(c, out);
fputc(c, out);
+ }else if( c=='"' ){
+ fputc('\\', out);
+ fputc('"', out);
}else if( c=='\t' ){
fputc('\\', out);
fputc('t', out);
@@ -600,8 +623,7 @@ static const char needCsvQuote[] = {
/*
** Output a single term of CSV. Actually, p->separator is used for
** the separator, which may or may not be a comma. p->nullvalue is
-** the null value. Strings are quoted using ANSI-C rules. Numbers
-** appear outside of quotes.
+** the null value. Strings are quoted if necessary.
*/
static void output_csv(struct callback_data *p, const char *z, int bSep){
FILE *out = p->out;
@@ -678,7 +700,7 @@ static int shell_callback(void *pArg, int nArg, char **azArg, char **azCol, int
}else{
w = 0;
}
- if( w<=0 ){
+ if( w==0 ){
w = strlen30(azCol[i] ? azCol[i] : "");
if( w<10 ) w = 10;
n = strlen30(azArg && azArg[i] ? azArg[i] : p->nullvalue);
@@ -688,7 +710,11 @@ static int shell_callback(void *pArg, int nArg, char **azArg, char **azCol, int
p->actualWidth[i] = w;
}
if( p->showHeader ){
- fprintf(p->out,"%-*.*s%s",w,w,azCol[i], i==nArg-1 ? "\n": " ");
+ if( w<0 ){
+ fprintf(p->out,"%*.*s%s",-w,-w,azCol[i], i==nArg-1 ? "\n": " ");
+ }else{
+ fprintf(p->out,"%-*.*s%s",w,w,azCol[i], i==nArg-1 ? "\n": " ");
+ }
}
}
if( p->showHeader ){
@@ -696,6 +722,7 @@ static int shell_callback(void *pArg, int nArg, char **azArg, char **azCol, int
int w;
if( i<ArraySize(p->actualWidth) ){
w = p->actualWidth[i];
+ if( w<0 ) w = -w;
}else{
w = 10;
}
@@ -717,8 +744,13 @@ static int shell_callback(void *pArg, int nArg, char **azArg, char **azCol, int
strlen30(azArg[i])>w ){
w = strlen30(azArg[i]);
}
- fprintf(p->out,"%-*.*s%s",w,w,
- azArg[i] ? azArg[i] : p->nullvalue, i==nArg-1 ? "\n": " ");
+ if( w<0 ){
+ fprintf(p->out,"%*.*s%s",-w,-w,
+ azArg[i] ? azArg[i] : p->nullvalue, i==nArg-1 ? "\n": " ");
+ }else{
+ fprintf(p->out,"%-*.*s%s",w,w,
+ azArg[i] ? azArg[i] : p->nullvalue, i==nArg-1 ? "\n": " ");
+ }
}
break;
}
@@ -768,14 +800,14 @@ static int shell_callback(void *pArg, int nArg, char **azArg, char **azCol, int
if( p->cnt++==0 && p->showHeader ){
for(i=0; i<nArg; i++){
output_c_string(p->out,azCol[i] ? azCol[i] : "");
- fprintf(p->out, "%s", p->separator);
+ if(i<nArg-1) fprintf(p->out, "%s", p->separator);
}
fprintf(p->out,"\n");
}
if( azArg==0 ) break;
for(i=0; i<nArg; i++){
output_c_string(p->out, azArg[i] ? azArg[i] : p->nullvalue);
- fprintf(p->out, "%s", p->separator);
+ if(i<nArg-1) fprintf(p->out, "%s", p->separator);
}
fprintf(p->out,"\n");
break;
@@ -920,34 +952,58 @@ static char *appendText(char *zIn, char const *zAppend, char quote){
/*
-** Execute a query statement that has a single result column. Print
-** that result column on a line by itself with a semicolon terminator.
+** Execute a query statement that will generate SQL output. Print
+** the result columns, comma-separated, on a line and then add a
+** semicolon terminator to the end of that line.
**
-** This is used, for example, to show the schema of the database by
-** querying the SQLITE_MASTER table.
+** If the number of columns is 1 and that column contains text "--"
+** then write the semicolon on a separate line. That way, if a
+** "--" comment occurs at the end of the statement, the comment
+** won't consume the semicolon terminator.
*/
static int run_table_dump_query(
- FILE *out, /* Send output here */
- sqlite3 *db, /* Database to query */
- const char *zSelect, /* SELECT statement to extract content */
- const char *zFirstRow /* Print before first row, if not NULL */
+ struct callback_data *p, /* Query context */
+ const char *zSelect, /* SELECT statement to extract content */
+ const char *zFirstRow /* Print before first row, if not NULL */
){
sqlite3_stmt *pSelect;
int rc;
- rc = sqlite3_prepare(db, zSelect, -1, &pSelect, 0);
+ int nResult;
+ int i;
+ const char *z;
+ rc = sqlite3_prepare(p->db, zSelect, -1, &pSelect, 0);
if( rc!=SQLITE_OK || !pSelect ){
+ fprintf(p->out, "/**** ERROR: (%d) %s *****/\n", rc, sqlite3_errmsg(p->db));
+ p->nErr++;
return rc;
}
rc = sqlite3_step(pSelect);
+ nResult = sqlite3_column_count(pSelect);
while( rc==SQLITE_ROW ){
if( zFirstRow ){
- fprintf(out, "%s", zFirstRow);
+ fprintf(p->out, "%s", zFirstRow);
zFirstRow = 0;
}
- fprintf(out, "%s;\n", sqlite3_column_text(pSelect, 0));
+ z = (const char*)sqlite3_column_text(pSelect, 0);
+ fprintf(p->out, "%s", z);
+ for(i=1; i<nResult; i++){
+ fprintf(p->out, ",%s", sqlite3_column_text(pSelect, i));
+ }
+ if( z==0 ) z = "";
+ while( z[0] && (z[0]!='-' || z[1]!='-') ) z++;
+ if( z[0] ){
+ fprintf(p->out, "\n;\n");
+ }else{
+ fprintf(p->out, ";\n");
+ }
rc = sqlite3_step(pSelect);
}
- return sqlite3_finalize(pSelect);
+ rc = sqlite3_finalize(pSelect);
+ if( rc!=SQLITE_OK ){
+ fprintf(p->out, "/**** ERROR: (%d) %s *****/\n", rc, sqlite3_errmsg(p->db));
+ p->nErr++;
+ }
+ return rc;
}
/*
@@ -1029,7 +1085,15 @@ static int display_stats(
fprintf(pArg->out, "Lookaside failures due to OOM: %d\n", iHiwtr);
iHiwtr = iCur = -1;
sqlite3_db_status(db, SQLITE_DBSTATUS_CACHE_USED, &iCur, &iHiwtr, bReset);
- fprintf(pArg->out, "Pager Heap Usage: %d bytes\n", iCur);
+ fprintf(pArg->out, "Pager Heap Usage: %d bytes\n", iCur); iHiwtr = iCur = -1;
+ sqlite3_db_status(db, SQLITE_DBSTATUS_CACHE_HIT, &iCur, &iHiwtr, 1);
+ fprintf(pArg->out, "Page cache hits: %d\n", iCur);
+ iHiwtr = iCur = -1;
+ sqlite3_db_status(db, SQLITE_DBSTATUS_CACHE_MISS, &iCur, &iHiwtr, 1);
+ fprintf(pArg->out, "Page cache misses: %d\n", iCur);
+ iHiwtr = iCur = -1;
+ sqlite3_db_status(db, SQLITE_DBSTATUS_CACHE_WRITE, &iCur, &iHiwtr, 1);
+ fprintf(pArg->out, "Page cache writes: %d\n", iCur);
iHiwtr = iCur = -1;
sqlite3_db_status(db, SQLITE_DBSTATUS_SCHEMA_USED, &iCur, &iHiwtr, bReset);
fprintf(pArg->out, "Schema Heap Usage: %d bytes\n", iCur);
@@ -1069,6 +1133,7 @@ static int shell_exec(
){
sqlite3_stmt *pStmt = NULL; /* Statement to execute. */
int rc = SQLITE_OK; /* Return Code */
+ int rc2;
const char *zLeftover; /* Tail of unprocessed SQL */
if( pzErrMsg ){
@@ -1085,7 +1150,7 @@ static int shell_exec(
if( !pStmt ){
/* this happens for a comment or white-space */
zSql = zLeftover;
- while( isspace(zSql[0]) ) zSql++;
+ while( IsSpace(zSql[0]) ) zSql++;
continue;
}
@@ -1101,6 +1166,15 @@ static int shell_exec(
fprintf(pArg->out, "%s\n", zStmtSql ? zStmtSql : zSql);
}
+ /* Output TESTCTRL_EXPLAIN text of requested */
+ if( pArg && pArg->mode==MODE_Explain ){
+ const char *zExplain = 0;
+ sqlite3_test_control(SQLITE_TESTCTRL_EXPLAIN_STMT, pStmt, &zExplain);
+ if( zExplain && zExplain[0] ){
+ fprintf(pArg->out, "%s", zExplain);
+ }
+ }
+
/* perform the first step. this will tell us if we
** have a result set or not and how wide it is.
*/
@@ -1162,10 +1236,11 @@ static int shell_exec(
/* Finalize the statement just executed. If this fails, save a
** copy of the error message. Otherwise, set zSql to point to the
** next statement to execute. */
- rc = sqlite3_finalize(pStmt);
+ rc2 = sqlite3_finalize(pStmt);
+ if( rc!=SQLITE_NOMEM ) rc = rc2;
if( rc==SQLITE_OK ){
zSql = zLeftover;
- while( isspace(zSql[0]) ) zSql++;
+ while( IsSpace(zSql[0]) ) zSql++;
}else if( pzErrMsg ){
*pzErrMsg = save_err_msg(db);
}
@@ -1242,9 +1317,12 @@ static int dump_callback(void *pArg, int nArg, char **azArg, char **azCol){
}
zSelect = appendText(zSelect, "SELECT 'INSERT INTO ' || ", 0);
+ /* Always quote the table name, even if it appears to be pure ascii,
+ ** in case it is a keyword. Ex: INSERT INTO "table" ... */
zTmp = appendText(zTmp, zTable, '"');
if( zTmp ){
zSelect = appendText(zSelect, zTmp, '\'');
+ free(zTmp);
}
zSelect = appendText(zSelect, " || ' VALUES(' || ", 0);
rc = sqlite3_step(pTableInfo);
@@ -1254,7 +1332,7 @@ static int dump_callback(void *pArg, int nArg, char **azArg, char **azCol){
zSelect = appendText(zSelect, zText, '"');
rc = sqlite3_step(pTableInfo);
if( rc==SQLITE_ROW ){
- zSelect = appendText(zSelect, ") || ',' || ", 0);
+ zSelect = appendText(zSelect, "), ", 0);
}else{
zSelect = appendText(zSelect, ") ", 0);
}
@@ -1268,12 +1346,12 @@ static int dump_callback(void *pArg, int nArg, char **azArg, char **azCol){
zSelect = appendText(zSelect, "|| ')' FROM ", 0);
zSelect = appendText(zSelect, zTable, '"');
- rc = run_table_dump_query(p->out, p->db, zSelect, zPrepStmt);
+ rc = run_table_dump_query(p, zSelect, zPrepStmt);
if( rc==SQLITE_CORRUPT ){
zSelect = appendText(zSelect, " ORDER BY rowid DESC", 0);
- rc = run_table_dump_query(p->out, p->db, zSelect, 0);
+ run_table_dump_query(p, zSelect, 0);
}
- if( zSelect ) free(zSelect);
+ free(zSelect);
}
return 0;
}
@@ -1287,19 +1365,30 @@ static int dump_callback(void *pArg, int nArg, char **azArg, char **azCol){
*/
static int run_schema_dump_query(
struct callback_data *p,
- const char *zQuery,
- char **pzErrMsg
+ const char *zQuery
){
int rc;
- rc = sqlite3_exec(p->db, zQuery, dump_callback, p, pzErrMsg);
+ char *zErr = 0;
+ rc = sqlite3_exec(p->db, zQuery, dump_callback, p, &zErr);
if( rc==SQLITE_CORRUPT ){
char *zQ2;
int len = strlen30(zQuery);
- if( pzErrMsg ) sqlite3_free(*pzErrMsg);
+ fprintf(p->out, "/****** CORRUPTION ERROR *******/\n");
+ if( zErr ){
+ fprintf(p->out, "/****** %s ******/\n", zErr);
+ sqlite3_free(zErr);
+ zErr = 0;
+ }
zQ2 = malloc( len+100 );
if( zQ2==0 ) return rc;
- sqlite3_snprintf(sizeof(zQ2), zQ2, "%s ORDER BY rowid DESC", zQuery);
- rc = sqlite3_exec(p->db, zQ2, dump_callback, p, pzErrMsg);
+ sqlite3_snprintf(len+100, zQ2, "%s ORDER BY rowid DESC", zQuery);
+ rc = sqlite3_exec(p->db, zQ2, dump_callback, p, &zErr);
+ if( rc ){
+ fprintf(p->out, "/****** ERROR: %s ******/\n", zErr);
+ }else{
+ rc = SQLITE_CORRUPT;
+ }
+ sqlite3_free(zErr);
free(zQ2);
}
return rc;
@@ -1341,9 +1430,10 @@ static char zHelp[] =
" list Values delimited by .separator string\n"
" tabs Tab-separated values\n"
" tcl TCL list elements\n"
- ".nullvalue STRING Print STRING in place of NULL values\n"
+ ".nullvalue STRING Use STRING in place of NULL values\n"
".output FILENAME Send output to FILENAME\n"
".output stdout Send output to the screen\n"
+ ".print STRING... Print literal STRING\n"
".prompt MAIN CONTINUE Replace the standard prompts\n"
".quit Exit this program\n"
".read FILENAME Execute SQL in FILENAME\n"
@@ -1358,6 +1448,8 @@ static char zHelp[] =
" If TABLE specified, only list tables matching\n"
" LIKE pattern TABLE.\n"
".timeout MS Try opening locked tables for MS milliseconds\n"
+ ".trace FILE|off Output each SQL statement as it is run\n"
+ ".vfsname ?AUX? Print the name of the VFS stack\n"
".width NUM1 NUM2 ... Set column widths for \"column\" mode\n"
;
@@ -1374,6 +1466,7 @@ static int process_input(struct callback_data *p, FILE *in);
*/
static void open_db(struct callback_data *p){
if( p->db==0 ){
+ sqlite3_initialize();
sqlite3_open(p->zDbFilename, &p->db);
db = p->db;
if( db && sqlite3_errcode(db)==SQLITE_OK ){
@@ -1388,6 +1481,18 @@ static void open_db(struct callback_data *p){
#ifndef SQLITE_OMIT_LOAD_EXTENSION
sqlite3_enable_load_extension(p->db, 1);
#endif
+#ifdef SQLITE_ENABLE_REGEXP
+ {
+ extern int sqlite3_add_regexp_func(sqlite3*);
+ sqlite3_add_regexp_func(db);
+ }
+#endif
+#ifdef SQLITE_ENABLE_SPELLFIX
+ {
+ extern int sqlite3_spellfix1_register(sqlite3*);
+ sqlite3_spellfix1_register(db);
+ }
+#endif
}
}
@@ -1433,17 +1538,64 @@ static void resolve_backslashes(char *z){
** Interpret zArg as a boolean value. Return either 0 or 1.
*/
static int booleanValue(char *zArg){
- int val = atoi(zArg);
- int j;
- for(j=0; zArg[j]; j++){
- zArg[j] = (char)tolower(zArg[j]);
+ int i;
+ for(i=0; zArg[i]>='0' && zArg[i]<='9'; i++){}
+ if( i>0 && zArg[i]==0 ) return atoi(zArg);
+ if( sqlite3_stricmp(zArg, "on")==0 || sqlite3_stricmp(zArg,"yes")==0 ){
+ return 1;
}
- if( strcmp(zArg,"on")==0 ){
- val = 1;
- }else if( strcmp(zArg,"yes")==0 ){
- val = 1;
+ if( sqlite3_stricmp(zArg, "off")==0 || sqlite3_stricmp(zArg,"no")==0 ){
+ return 0;
}
- return val;
+ fprintf(stderr, "ERROR: Not a boolean value: \"%s\". Assuming \"no\".\n",
+ zArg);
+ return 0;
+}
+
+/*
+** Close an output file, assuming it is not stderr or stdout
+*/
+static void output_file_close(FILE *f){
+ if( f && f!=stdout && f!=stderr ) fclose(f);
+}
+
+/*
+** Try to open an output file. The names "stdout" and "stderr" are
+** recognized and do the right thing. NULL is returned if the output
+** filename is "off".
+*/
+static FILE *output_file_open(const char *zFile){
+ FILE *f;
+ if( strcmp(zFile,"stdout")==0 ){
+ f = stdout;
+ }else if( strcmp(zFile, "stderr")==0 ){
+ f = stderr;
+ }else if( strcmp(zFile, "off")==0 ){
+ f = 0;
+ }else{
+ f = fopen(zFile, "wb");
+ if( f==0 ){
+ fprintf(stderr, "Error: cannot open \"%s\"\n", zFile);
+ }
+ }
+ return f;
+}
+
+/*
+** A routine for handling output from sqlite3_trace().
+*/
+static void sql_trace_callback(void *pArg, const char *z){
+ FILE *f = (FILE*)pArg;
+ if( f ) fprintf(f, "%s\n", z);
+}
+
+/*
+** A no-op routine that runs with the ".breakpoint" doc-command. This is
+** a useful spot to set a debugger breakpoint.
+*/
+static void test_breakpoint(void){
+ static int nCall = 0;
+ nCall++;
}
/*
@@ -1462,7 +1614,7 @@ static int do_meta_command(char *zLine, struct callback_data *p){
/* Parse the input line into tokens.
*/
while( zLine[i] && nArg<ArraySize(azArg) ){
- while( isspace((unsigned char)zLine[i]) ){ i++; }
+ while( IsSpace(zLine[i]) ){ i++; }
if( zLine[i]==0 ) break;
if( zLine[i]=='\'' || zLine[i]=='"' ){
int delim = zLine[i++];
@@ -1474,7 +1626,7 @@ static int do_meta_command(char *zLine, struct callback_data *p){
if( delim=='"' ) resolve_backslashes(azArg[nArg-1]);
}else{
azArg[nArg++] = &zLine[i];
- while( zLine[i] && !isspace((unsigned char)zLine[i]) ){ i++; }
+ while( zLine[i] && !IsSpace(zLine[i]) ){ i++; }
if( zLine[i] ) zLine[i++] = 0;
resolve_backslashes(azArg[nArg-1]);
}
@@ -1485,24 +1637,50 @@ static int do_meta_command(char *zLine, struct callback_data *p){
if( nArg==0 ) return 0; /* no tokens, no error */
n = strlen30(azArg[0]);
c = azArg[0][0];
- if( c=='b' && n>=3 && strncmp(azArg[0], "backup", n)==0 && nArg>1 && nArg<4){
- const char *zDestFile;
- const char *zDb;
+ if( c=='b' && n>=3 && strncmp(azArg[0], "backup", n)==0 ){
+ const char *zDestFile = 0;
+ const char *zDb = 0;
+ const char *zKey = 0;
sqlite3 *pDest;
sqlite3_backup *pBackup;
- if( nArg==2 ){
- zDestFile = azArg[1];
- zDb = "main";
- }else{
- zDestFile = azArg[2];
- zDb = azArg[1];
+ int j;
+ for(j=1; j<nArg; j++){
+ const char *z = azArg[j];
+ if( z[0]=='-' ){
+ while( z[0]=='-' ) z++;
+ if( strcmp(z,"key")==0 && j<nArg-1 ){
+ zKey = azArg[++j];
+ }else
+ {
+ fprintf(stderr, "unknown option: %s\n", azArg[j]);
+ return 1;
+ }
+ }else if( zDestFile==0 ){
+ zDestFile = azArg[j];
+ }else if( zDb==0 ){
+ zDb = zDestFile;
+ zDestFile = azArg[j];
+ }else{
+ fprintf(stderr, "too many arguments to .backup\n");
+ return 1;
+ }
}
+ if( zDestFile==0 ){
+ fprintf(stderr, "missing FILENAME argument on .backup\n");
+ return 1;
+ }
+ if( zDb==0 ) zDb = "main";
rc = sqlite3_open(zDestFile, &pDest);
if( rc!=SQLITE_OK ){
fprintf(stderr, "Error: cannot open \"%s\"\n", zDestFile);
sqlite3_close(pDest);
return 1;
}
+#ifdef SQLITE_HAS_CODEC
+ sqlite3_key(pDest, zKey, (int)strlen(zKey));
+#else
+ (void)zKey;
+#endif
open_db(p);
pBackup = sqlite3_backup_init(pDest, "main", p->db, zDb);
if( pBackup==0 ){
@@ -1525,6 +1703,13 @@ static int do_meta_command(char *zLine, struct callback_data *p){
bail_on_error = booleanValue(azArg[1]);
}else
+ /* The undocumented ".breakpoint" command causes a call to the no-op
+ ** routine named test_breakpoint().
+ */
+ if( c=='b' && n>=3 && strncmp(azArg[0], "breakpoint", n)==0 ){
+ test_breakpoint();
+ }else
+
if( c=='d' && n>1 && strncmp(azArg[0], "databases", n)==0 && nArg==1 ){
struct callback_data data;
char *zErrMsg = 0;
@@ -1545,7 +1730,6 @@ static int do_meta_command(char *zLine, struct callback_data *p){
}else
if( c=='d' && strncmp(azArg[0], "dump", n)==0 && nArg<3 ){
- char *zErrMsg = 0;
open_db(p);
/* When playing back a "dump", the content might appear in an order
** which causes immediate foreign key constraints to be violated.
@@ -1553,17 +1737,18 @@ static int do_meta_command(char *zLine, struct callback_data *p){
fprintf(p->out, "PRAGMA foreign_keys=OFF;\n");
fprintf(p->out, "BEGIN TRANSACTION;\n");
p->writableSchema = 0;
- sqlite3_exec(p->db, "PRAGMA writable_schema=ON", 0, 0, 0);
+ sqlite3_exec(p->db, "SAVEPOINT dump; PRAGMA writable_schema=ON", 0, 0, 0);
+ p->nErr = 0;
if( nArg==1 ){
run_schema_dump_query(p,
"SELECT name, type, sql FROM sqlite_master "
- "WHERE sql NOT NULL AND type=='table' AND name!='sqlite_sequence'", 0
+ "WHERE sql NOT NULL AND type=='table' AND name!='sqlite_sequence'"
);
run_schema_dump_query(p,
"SELECT name, type, sql FROM sqlite_master "
- "WHERE name=='sqlite_sequence'", 0
+ "WHERE name=='sqlite_sequence'"
);
- run_table_dump_query(p->out, p->db,
+ run_table_dump_query(p,
"SELECT sql FROM sqlite_master "
"WHERE sql NOT NULL AND type IN ('index','trigger','view')", 0
);
@@ -1574,8 +1759,8 @@ static int do_meta_command(char *zLine, struct callback_data *p){
run_schema_dump_query(p,
"SELECT name, type, sql FROM sqlite_master "
"WHERE tbl_name LIKE shellstatic() AND type=='table'"
- " AND sql NOT NULL", 0);
- run_table_dump_query(p->out, p->db,
+ " AND sql NOT NULL");
+ run_table_dump_query(p,
"SELECT sql FROM sqlite_master "
"WHERE sql NOT NULL"
" AND type IN ('index','trigger','view')"
@@ -1588,20 +1773,17 @@ static int do_meta_command(char *zLine, struct callback_data *p){
fprintf(p->out, "PRAGMA writable_schema=OFF;\n");
p->writableSchema = 0;
}
- sqlite3_exec(p->db, "PRAGMA writable_schema=OFF", 0, 0, 0);
- if( zErrMsg ){
- fprintf(stderr,"Error: %s\n", zErrMsg);
- sqlite3_free(zErrMsg);
- }else{
- fprintf(p->out, "COMMIT;\n");
- }
+ sqlite3_exec(p->db, "PRAGMA writable_schema=OFF;", 0, 0, 0);
+ sqlite3_exec(p->db, "RELEASE dump;", 0, 0, 0);
+ fprintf(p->out, p->nErr ? "ROLLBACK; -- due to errors\n" : "COMMIT;\n");
}else
if( c=='e' && strncmp(azArg[0], "echo", n)==0 && nArg>1 && nArg<3 ){
p->echoOn = booleanValue(azArg[1]);
}else
- if( c=='e' && strncmp(azArg[0], "exit", n)==0 && nArg==1 ){
+ if( c=='e' && strncmp(azArg[0], "exit", n)==0 ){
+ if( nArg>1 && (rc = atoi(azArg[1]))!=0 ) exit(rc);
rc = 2;
}else
@@ -1673,7 +1855,7 @@ static int do_meta_command(char *zLine, struct callback_data *p){
fprintf(stderr, "Error: non-null separator required for import\n");
return 1;
}
- zSql = sqlite3_mprintf("SELECT * FROM '%q'", zTable);
+ zSql = sqlite3_mprintf("SELECT * FROM %s", zTable);
if( zSql==0 ){
fprintf(stderr, "Error: out of memory\n");
return 1;
@@ -1695,7 +1877,7 @@ static int do_meta_command(char *zLine, struct callback_data *p){
fprintf(stderr, "Error: out of memory\n");
return 1;
}
- sqlite3_snprintf(nByte+20, zSql, "INSERT INTO '%q' VALUES(?", zTable);
+ sqlite3_snprintf(nByte+20, zSql, "INSERT INTO %s VALUES(?", zTable);
j = strlen30(zSql);
for(i=1; i<nCol; i++){
zSql[j++] = ',';
@@ -1725,13 +1907,15 @@ static int do_meta_command(char *zLine, struct callback_data *p){
}
sqlite3_exec(p->db, "BEGIN", 0, 0, 0);
zCommit = "COMMIT";
- while( (zLine = local_getline(0, in))!=0 ){
- char *z;
- i = 0;
+ while( (zLine = local_getline(0, in, 1))!=0 ){
+ char *z, c;
+ int inQuote = 0;
lineno++;
azCol[0] = zLine;
- for(i=0, z=zLine; *z && *z!='\n' && *z!='\r'; z++){
- if( *z==p->separator[0] && strncmp(z, p->separator, nSep)==0 ){
+ for(i=0, z=zLine; (c = *z)!=0; z++){
+ if( c=='"' ) inQuote = !inQuote;
+ if( c=='\n' ) lineno++;
+ if( !inQuote && c==p->separator[0] && strncmp(z,p->separator,nSep)==0 ){
*z = 0;
i++;
if( i<nCol ){
@@ -1751,6 +1935,14 @@ static int do_meta_command(char *zLine, struct callback_data *p){
break; /* from while */
}
for(i=0; i<nCol; i++){
+ if( azCol[i][0]=='"' ){
+ int k;
+ for(z=azCol[i], j=1, k=0; z[j]; j++){
+ if( z[j]=='"' ){ j++; if( z[j]==0 ) break; }
+ z[k++] = z[j];
+ }
+ z[k] = 0;
+ }
sqlite3_bind_text(pStmt, i+1, azCol[i], -1, SQLITE_STATIC);
}
sqlite3_step(pStmt);
@@ -1850,22 +2042,8 @@ static int do_meta_command(char *zLine, struct callback_data *p){
if( c=='l' && strncmp(azArg[0], "log", n)==0 && nArg>=2 ){
const char *zFile = azArg[1];
- if( p->pLog && p->pLog!=stdout && p->pLog!=stderr ){
- fclose(p->pLog);
- p->pLog = 0;
- }
- if( strcmp(zFile,"stdout")==0 ){
- p->pLog = stdout;
- }else if( strcmp(zFile, "stderr")==0 ){
- p->pLog = stderr;
- }else if( strcmp(zFile, "off")==0 ){
- p->pLog = 0;
- }else{
- p->pLog = fopen(zFile, "w");
- if( p->pLog==0 ){
- fprintf(stderr, "Error: cannot open \"%s\"\n", zFile);
- }
- }
+ output_file_close(p->pLog);
+ p->pLog = output_file_open(zFile);
}else
if( c=='m' && strncmp(azArg[0], "mode", n)==0 && nArg==2 ){
@@ -1884,6 +2062,7 @@ static int do_meta_command(char *zLine, struct callback_data *p){
p->mode = MODE_Html;
}else if( n2==3 && strncmp(azArg[1],"tcl",n2)==0 ){
p->mode = MODE_Tcl;
+ sqlite3_snprintf(sizeof(p->separator), p->separator, " ");
}else if( n2==3 && strncmp(azArg[1],"csv",n2)==0 ){
p->mode = MODE_Csv;
sqlite3_snprintf(sizeof(p->separator), p->separator, ",");
@@ -1918,24 +2097,44 @@ static int do_meta_command(char *zLine, struct callback_data *p){
}else
if( c=='o' && strncmp(azArg[0], "output", n)==0 && nArg==2 ){
- if( p->out!=stdout ){
- fclose(p->out);
+ if( p->outfile[0]=='|' ){
+ pclose(p->out);
+ }else{
+ output_file_close(p->out);
}
- if( strcmp(azArg[1],"stdout")==0 ){
- p->out = stdout;
- sqlite3_snprintf(sizeof(p->outfile), p->outfile, "stdout");
+ p->outfile[0] = 0;
+ if( azArg[1][0]=='|' ){
+ p->out = popen(&azArg[1][1], "w");
+ if( p->out==0 ){
+ fprintf(stderr,"Error: cannot open pipe \"%s\"\n", &azArg[1][1]);
+ p->out = stdout;
+ rc = 1;
+ }else{
+ sqlite3_snprintf(sizeof(p->outfile), p->outfile, "%s", azArg[1]);
+ }
}else{
- p->out = fopen(azArg[1], "wb");
+ p->out = output_file_open(azArg[1]);
if( p->out==0 ){
- fprintf(stderr,"Error: cannot write to \"%s\"\n", azArg[1]);
+ if( strcmp(azArg[1],"off")!=0 ){
+ fprintf(stderr,"Error: cannot write to \"%s\"\n", azArg[1]);
+ }
p->out = stdout;
rc = 1;
} else {
- sqlite3_snprintf(sizeof(p->outfile), p->outfile, "%s", azArg[1]);
+ sqlite3_snprintf(sizeof(p->outfile), p->outfile, "%s", azArg[1]);
}
}
}else
+ if( c=='p' && n>=3 && strncmp(azArg[0], "print", n)==0 ){
+ int i;
+ for(i=1; i<nArg; i++){
+ if( i>1 ) fprintf(p->out, " ");
+ fprintf(p->out, "%s", azArg[i]);
+ }
+ fprintf(p->out, "\n");
+ }else
+
if( c=='p' && strncmp(azArg[0], "prompt", n)==0 && (nArg==2 || nArg==3)){
if( nArg >= 2) {
strncpy(mainPrompt,azArg[1],(int)ArraySize(mainPrompt)-1);
@@ -2016,7 +2215,7 @@ static int do_meta_command(char *zLine, struct callback_data *p){
data.mode = MODE_Semi;
if( nArg>1 ){
int i;
- for(i=0; azArg[1][i]; i++) azArg[1][i] = (char)tolower(azArg[1][i]);
+ for(i=0; azArg[1][i]; i++) azArg[1][i] = ToLower(azArg[1][i]);
if( strcmp(azArg[1],"sqlite_master")==0 ){
char *new_argv[2], *new_colv[2];
new_argv[0] = "CREATE TABLE sqlite_master (\n"
@@ -2049,22 +2248,25 @@ static int do_meta_command(char *zLine, struct callback_data *p){
zShellStatic = azArg[1];
rc = sqlite3_exec(p->db,
"SELECT sql FROM "
- " (SELECT sql sql, type type, tbl_name tbl_name, name name"
+ " (SELECT sql sql, type type, tbl_name tbl_name, name name, rowid x"
" FROM sqlite_master UNION ALL"
- " SELECT sql, type, tbl_name, name FROM sqlite_temp_master) "
- "WHERE tbl_name LIKE shellstatic() AND type!='meta' AND sql NOTNULL "
- "ORDER BY substr(type,2,1), name",
+ " SELECT sql, type, tbl_name, name, rowid FROM sqlite_temp_master) "
+ "WHERE lower(tbl_name) LIKE shellstatic()"
+ " AND type!='meta' AND sql NOTNULL "
+ "ORDER BY substr(type,2,1), "
+ " CASE type WHEN 'view' THEN rowid ELSE name END",
callback, &data, &zErrMsg);
zShellStatic = 0;
}
}else{
rc = sqlite3_exec(p->db,
"SELECT sql FROM "
- " (SELECT sql sql, type type, tbl_name tbl_name, name name"
+ " (SELECT sql sql, type type, tbl_name tbl_name, name name, rowid x"
" FROM sqlite_master UNION ALL"
- " SELECT sql, type, tbl_name, name FROM sqlite_temp_master) "
+ " SELECT sql, type, tbl_name, name, rowid FROM sqlite_temp_master) "
"WHERE type!='meta' AND sql NOTNULL AND name NOT LIKE 'sqlite_%'"
- "ORDER BY substr(type,2,1), name",
+ "ORDER BY substr(type,2,1),"
+ " CASE type WHEN 'view' THEN rowid ELSE name END",
callback, &data, &zErrMsg
);
}
@@ -2112,46 +2314,71 @@ static int do_meta_command(char *zLine, struct callback_data *p){
}else
if( c=='t' && n>1 && strncmp(azArg[0], "tables", n)==0 && nArg<3 ){
+ sqlite3_stmt *pStmt;
char **azResult;
- int nRow;
- char *zErrMsg;
+ int nRow, nAlloc;
+ char *zSql = 0;
+ int ii;
open_db(p);
- if( nArg==1 ){
- rc = sqlite3_get_table(p->db,
- "SELECT name FROM sqlite_master "
- "WHERE type IN ('table','view') AND name NOT LIKE 'sqlite_%' "
- "UNION ALL "
- "SELECT name FROM sqlite_temp_master "
- "WHERE type IN ('table','view') "
- "ORDER BY 1",
- &azResult, &nRow, 0, &zErrMsg
- );
- }else{
- zShellStatic = azArg[1];
- rc = sqlite3_get_table(p->db,
- "SELECT name FROM sqlite_master "
- "WHERE type IN ('table','view') AND name LIKE shellstatic() "
- "UNION ALL "
- "SELECT name FROM sqlite_temp_master "
- "WHERE type IN ('table','view') AND name LIKE shellstatic() "
- "ORDER BY 1",
- &azResult, &nRow, 0, &zErrMsg
- );
- zShellStatic = 0;
+ rc = sqlite3_prepare_v2(p->db, "PRAGMA database_list", -1, &pStmt, 0);
+ if( rc ) return rc;
+ zSql = sqlite3_mprintf(
+ "SELECT name FROM sqlite_master"
+ " WHERE type IN ('table','view')"
+ " AND name NOT LIKE 'sqlite_%%'"
+ " AND name LIKE ?1");
+ while( sqlite3_step(pStmt)==SQLITE_ROW ){
+ const char *zDbName = (const char*)sqlite3_column_text(pStmt, 1);
+ if( zDbName==0 || strcmp(zDbName,"main")==0 ) continue;
+ if( strcmp(zDbName,"temp")==0 ){
+ zSql = sqlite3_mprintf(
+ "%z UNION ALL "
+ "SELECT 'temp.' || name FROM sqlite_temp_master"
+ " WHERE type IN ('table','view')"
+ " AND name NOT LIKE 'sqlite_%%'"
+ " AND name LIKE ?1", zSql);
+ }else{
+ zSql = sqlite3_mprintf(
+ "%z UNION ALL "
+ "SELECT '%q.' || name FROM \"%w\".sqlite_master"
+ " WHERE type IN ('table','view')"
+ " AND name NOT LIKE 'sqlite_%%'"
+ " AND name LIKE ?1", zSql, zDbName, zDbName);
+ }
}
- if( zErrMsg ){
- fprintf(stderr,"Error: %s\n", zErrMsg);
- sqlite3_free(zErrMsg);
- rc = 1;
- }else if( rc != SQLITE_OK ){
- fprintf(stderr,"Error: querying sqlite_master and sqlite_temp_master\n");
- rc = 1;
+ sqlite3_finalize(pStmt);
+ zSql = sqlite3_mprintf("%z ORDER BY 1", zSql);
+ rc = sqlite3_prepare_v2(p->db, zSql, -1, &pStmt, 0);
+ sqlite3_free(zSql);
+ if( rc ) return rc;
+ nRow = nAlloc = 0;
+ azResult = 0;
+ if( nArg>1 ){
+ sqlite3_bind_text(pStmt, 1, azArg[1], -1, SQLITE_TRANSIENT);
}else{
+ sqlite3_bind_text(pStmt, 1, "%", -1, SQLITE_STATIC);
+ }
+ while( sqlite3_step(pStmt)==SQLITE_ROW ){
+ if( nRow>=nAlloc ){
+ char **azNew;
+ int n = nAlloc*2 + 10;
+ azNew = sqlite3_realloc(azResult, sizeof(azResult[0])*n);
+ if( azNew==0 ){
+ fprintf(stderr, "Error: out of memory\n");
+ break;
+ }
+ nAlloc = n;
+ azResult = azNew;
+ }
+ azResult[nRow] = sqlite3_mprintf("%s", sqlite3_column_text(pStmt, 0));
+ if( azResult[nRow] ) nRow++;
+ }
+ sqlite3_finalize(pStmt);
+ if( nRow>0 ){
int len, maxlen = 0;
int i, j;
int nPrintCol, nPrintRow;
- for(i=1; i<=nRow; i++){
- if( azResult[i]==0 ) continue;
+ for(i=0; i<nRow; i++){
len = strlen30(azResult[i]);
if( len>maxlen ) maxlen = len;
}
@@ -2159,14 +2386,15 @@ static int do_meta_command(char *zLine, struct callback_data *p){
if( nPrintCol<1 ) nPrintCol = 1;
nPrintRow = (nRow + nPrintCol - 1)/nPrintCol;
for(i=0; i<nPrintRow; i++){
- for(j=i+1; j<=nRow; j+=nPrintRow){
- char *zSp = j<=nPrintRow ? "" : " ";
+ for(j=i; j<nRow; j+=nPrintRow){
+ char *zSp = j<nPrintRow ? "" : " ";
printf("%s%-*s", zSp, maxlen, azResult[j] ? azResult[j] : "");
}
printf("\n");
}
}
- sqlite3_free_table(azResult);
+ for(ii=0; ii<nRow; ii++) sqlite3_free(azResult[ii]);
+ sqlite3_free(azResult);
}else
if( c=='t' && n>=8 && strncmp(azArg[0], "testctrl", n)==0 && nArg>=2 ){
@@ -2186,7 +2414,6 @@ static int do_meta_command(char *zLine, struct callback_data *p){
{ "reserve", SQLITE_TESTCTRL_RESERVE },
{ "optimizations", SQLITE_TESTCTRL_OPTIMIZATIONS },
{ "iskeyword", SQLITE_TESTCTRL_ISKEYWORD },
- { "pghdrsz", SQLITE_TESTCTRL_PGHDRSZ },
{ "scratchmalloc", SQLITE_TESTCTRL_SCRATCHMALLOC },
};
int testctrl = -1;
@@ -2202,7 +2429,7 @@ static int do_meta_command(char *zLine, struct callback_data *p){
if( testctrl<0 ){
testctrl = aCtrl[i].ctrlCode;
}else{
- fprintf(stderr, "ambiguous option name: \"%s\"\n", azArg[i]);
+ fprintf(stderr, "ambiguous option name: \"%s\"\n", azArg[1]);
testctrl = -1;
break;
}
@@ -2231,7 +2458,6 @@ static int do_meta_command(char *zLine, struct callback_data *p){
case SQLITE_TESTCTRL_PRNG_SAVE:
case SQLITE_TESTCTRL_PRNG_RESTORE:
case SQLITE_TESTCTRL_PRNG_RESET:
- case SQLITE_TESTCTRL_PGHDRSZ:
if( nArg==2 ){
rc = sqlite3_test_control(testctrl);
printf("%d (0x%08x)\n", rc, rc);
@@ -2302,11 +2528,43 @@ static int do_meta_command(char *zLine, struct callback_data *p){
enableTimer = booleanValue(azArg[1]);
}else
+ if( c=='t' && strncmp(azArg[0], "trace", n)==0 && nArg>1 ){
+ open_db(p);
+ output_file_close(p->traceOut);
+ p->traceOut = output_file_open(azArg[1]);
+#if !defined(SQLITE_OMIT_TRACE) && !defined(SQLITE_OMIT_FLOATING_POINT)
+ if( p->traceOut==0 ){
+ sqlite3_trace(p->db, 0, 0);
+ }else{
+ sqlite3_trace(p->db, sql_trace_callback, p->traceOut);
+ }
+#endif
+ }else
+
if( c=='v' && strncmp(azArg[0], "version", n)==0 ){
- printf("SQLite %s %s\n",
+ printf("SQLite %s %s\n" /*extra-version-info*/,
sqlite3_libversion(), sqlite3_sourceid());
}else
+ if( c=='v' && strncmp(azArg[0], "vfsname", n)==0 ){
+ const char *zDbName = nArg==2 ? azArg[1] : "main";
+ char *zVfsName = 0;
+ if( p->db ){
+ sqlite3_file_control(p->db, zDbName, SQLITE_FCNTL_VFSNAME, &zVfsName);
+ if( zVfsName ){
+ printf("%s\n", zVfsName);
+ sqlite3_free(zVfsName);
+ }
+ }
+ }else
+
+#if defined(SQLITE_DEBUG) && defined(SQLITE_ENABLE_WHERETRACE)
+ if( c=='w' && strncmp(azArg[0], "wheretrace", n)==0 ){
+ extern int sqlite3WhereTrace;
+ sqlite3WhereTrace = atoi(azArg[1]);
+ }else
+#endif
+
if( c=='w' && strncmp(azArg[0], "width", n)==0 && nArg>1 ){
int j;
assert( nArg<=ArraySize(azArg) );
@@ -2339,7 +2597,7 @@ static int _contains_semicolon(const char *z, int N){
*/
static int _all_whitespace(const char *z){
for(; *z; z++){
- if( isspace(*(unsigned char*)z) ) continue;
+ if( IsSpace(z[0]) ) continue;
if( *z=='/' && z[1]=='*' ){
z += 2;
while( *z && (*z!='*' || z[1]!='/') ){ z++; }
@@ -2364,11 +2622,11 @@ static int _all_whitespace(const char *z){
** as is the Oracle "/".
*/
static int _is_command_terminator(const char *zLine){
- while( isspace(*(unsigned char*)zLine) ){ zLine++; };
+ while( IsSpace(zLine[0]) ){ zLine++; };
if( zLine[0]=='/' && _all_whitespace(&zLine[1]) ){
return 1; /* Oracle */
}
- if( tolower(zLine[0])=='g' && tolower(zLine[1])=='o'
+ if( ToLower(zLine[0])=='g' && ToLower(zLine[1])=='o'
&& _all_whitespace(&zLine[2]) ){
return 1; /* SQL Server */
}
@@ -2414,7 +2672,9 @@ static int process_input(struct callback_data *p, FILE *in){
free(zLine);
zLine = one_input_line(zSql, in);
if( zLine==0 ){
- break; /* We have reached EOF */
+ /* End of input */
+ if( stdin_is_interactive ) printf("\n");
+ break;
}
if( seenInterrupt ){
if( in!=0 ) break;
@@ -2438,7 +2698,7 @@ static int process_input(struct callback_data *p, FILE *in){
nSqlPrior = nSql;
if( zSql==0 ){
int i;
- for(i=0; zLine[i] && isspace((unsigned char)zLine[i]); i++){}
+ for(i=0; zLine[i] && IsSpace(zLine[i]); i++){}
if( zLine[i]!=0 ){
nSql = strlen30(zLine);
zSql = malloc( nSql+3 );
@@ -2496,33 +2756,34 @@ static int process_input(struct callback_data *p, FILE *in){
free(zSql);
}
free(zLine);
- return errCnt;
+ return errCnt>0;
}
/*
** Return a pathname which is the user's home directory. A
-** 0 return indicates an error of some kind. Space to hold the
-** resulting string is obtained from malloc(). The calling
-** function should free the result.
+** 0 return indicates an error of some kind.
*/
static char *find_home_dir(void){
- char *home_dir = NULL;
+ static char *home_dir = NULL;
+ if( home_dir ) return home_dir;
-#if !defined(_WIN32) && !defined(WIN32) && !defined(__OS2__) && !defined(_WIN32_WCE) && !defined(__RTP__) && !defined(_WRS_KERNEL)
- struct passwd *pwent;
- uid_t uid = getuid();
- if( (pwent=getpwuid(uid)) != NULL) {
- home_dir = pwent->pw_dir;
+#if !defined(_WIN32) && !defined(WIN32) && !defined(_WIN32_WCE) && !defined(__RTP__) && !defined(_WRS_KERNEL)
+ {
+ struct passwd *pwent;
+ uid_t uid = getuid();
+ if( (pwent=getpwuid(uid)) != NULL) {
+ home_dir = pwent->pw_dir;
+ }
}
#endif
#if defined(_WIN32_WCE)
/* Windows CE (arm-wince-mingw32ce-gcc) does not provide getenv()
*/
- home_dir = strdup("/");
+ home_dir = "/";
#else
-#if defined(_WIN32) || defined(WIN32) || defined(__OS2__)
+#if defined(_WIN32) || defined(WIN32)
if (!home_dir) {
home_dir = getenv("USERPROFILE");
}
@@ -2532,7 +2793,7 @@ static char *find_home_dir(void){
home_dir = getenv("HOME");
}
-#if defined(_WIN32) || defined(WIN32) || defined(__OS2__)
+#if defined(_WIN32) || defined(WIN32)
if (!home_dir) {
char *zDrive, *zPath;
int n;
@@ -2575,7 +2836,6 @@ static int process_sqliterc(
const char *sqliterc = sqliterc_override;
char *zBuf = 0;
FILE *in = NULL;
- int nBuf;
int rc = 0;
if (sqliterc == NULL) {
@@ -2586,15 +2846,9 @@ static int process_sqliterc(
#endif
return 1;
}
- nBuf = strlen30(home_dir) + 16;
- zBuf = malloc( nBuf );
- if( zBuf==0 ){
- fprintf(stderr,"%s: Error: out of memory\n",Argv0);
- return 1;
- }
- sqlite3_snprintf(nBuf, zBuf,"%s/.sqliterc",home_dir);
- free(home_dir);
- sqliterc = (const char*)zBuf;
+ sqlite3_initialize();
+ zBuf = sqlite3_mprintf("%s/.sqliterc",home_dir);
+ sqliterc = zBuf;
}
in = fopen(sqliterc,"rb");
if( in ){
@@ -2604,7 +2858,7 @@ static int process_sqliterc(
rc = process_input(p,in);
fclose(in);
}
- free(zBuf);
+ sqlite3_free(zBuf);
return rc;
}
@@ -2612,21 +2866,28 @@ static int process_sqliterc(
** Show available command line options
*/
static const char zOptions[] =
- " -help show this message\n"
- " -init filename read/process named file\n"
- " -echo print commands before execution\n"
- " -[no]header turn headers on or off\n"
" -bail stop after hitting an error\n"
- " -interactive force interactive I/O\n"
" -batch force batch I/O\n"
" -column set output mode to 'column'\n"
+ " -cmd COMMAND run \"COMMAND\" before reading stdin\n"
" -csv set output mode to 'csv'\n"
+ " -echo print commands before execution\n"
+ " -init FILENAME read/process named file\n"
+ " -[no]header turn headers on or off\n"
+#if defined(SQLITE_ENABLE_MEMSYS3) || defined(SQLITE_ENABLE_MEMSYS5)
+ " -heap SIZE Size of heap for memsys3 or memsys5\n"
+#endif
+ " -help show this message\n"
" -html set output mode to HTML\n"
+ " -interactive force interactive I/O\n"
" -line set output mode to 'line'\n"
" -list set output mode to 'list'\n"
- " -separator 'x' set output field separator (|)\n"
+#ifdef SQLITE_ENABLE_MULTIPLEX
+ " -multiplex enable the multiplexor VFS\n"
+#endif
+ " -nullvalue TEXT set text string for NULL values. Default ''\n"
+ " -separator SEP set output field separator. Default: '|'\n"
" -stats print memory stats before each finalize\n"
- " -nullvalue 'text' set text string for NULL values\n"
" -version show SQLite version\n"
" -vfs NAME use NAME as the default VFS\n"
#ifdef SQLITE_ENABLE_VFSTRACE
@@ -2661,6 +2922,19 @@ static void main_init(struct callback_data *data) {
sqlite3_config(SQLITE_CONFIG_SINGLETHREAD);
}
+/*
+** Get the argument to an --option. Throw an error and die if no argument
+** is available.
+*/
+static char *cmdline_option_value(int argc, char **argv, int i){
+ if( i==argc ){
+ fprintf(stderr, "%s: Error: missing argument to %s\n",
+ argv[0], argv[argc-1]);
+ exit(1);
+ }
+ return argv[i];
+}
+
int main(int argc, char **argv){
char *zErrMsg = 0;
struct callback_data data;
@@ -2690,28 +2964,43 @@ int main(int argc, char **argv){
** the size of the alternative malloc heap,
** and the first command to execute.
*/
- for(i=1; i<argc-1; i++){
+ for(i=1; i<argc; i++){
char *z;
- if( argv[i][0]!='-' ) break;
z = argv[i];
- if( z[0]=='-' && z[1]=='-' ) z++;
- if( strcmp(argv[i],"-separator")==0 || strcmp(argv[i],"-nullvalue")==0 ){
- i++;
- }else if( strcmp(argv[i],"-init")==0 ){
- i++;
- zInitFile = argv[i];
- /* Need to check for batch mode here to so we can avoid printing
- ** informational messages (like from process_sqliterc) before
- ** we do the actual processing of arguments later in a second pass.
- */
- }else if( strcmp(argv[i],"-batch")==0 ){
+ if( z[0]!='-' ){
+ if( data.zDbFilename==0 ){
+ data.zDbFilename = z;
+ continue;
+ }
+ if( zFirstCmd==0 ){
+ zFirstCmd = z;
+ continue;
+ }
+ fprintf(stderr,"%s: Error: too many options: \"%s\"\n", Argv0, argv[i]);
+ fprintf(stderr,"Use -help for a list of options.\n");
+ return 1;
+ }
+ if( z[1]=='-' ) z++;
+ if( strcmp(z,"-separator")==0
+ || strcmp(z,"-nullvalue")==0
+ || strcmp(z,"-cmd")==0
+ ){
+ (void)cmdline_option_value(argc, argv, ++i);
+ }else if( strcmp(z,"-init")==0 ){
+ zInitFile = cmdline_option_value(argc, argv, ++i);
+ }else if( strcmp(z,"-batch")==0 ){
+ /* Need to check for batch mode here to so we can avoid printing
+ ** informational messages (like from process_sqliterc) before
+ ** we do the actual processing of arguments later in a second pass.
+ */
stdin_is_interactive = 0;
- }else if( strcmp(argv[i],"-heap")==0 ){
+ }else if( strcmp(z,"-heap")==0 ){
+#if defined(SQLITE_ENABLE_MEMSYS3) || defined(SQLITE_ENABLE_MEMSYS5)
int j, c;
const char *zSize;
sqlite3_int64 szHeap;
- zSize = argv[++i];
+ zSize = cmdline_option_value(argc, argv, ++i);
szHeap = atoi(zSize);
for(j=0; (c = zSize[j])!=0; j++){
if( c=='M' ){ szHeap *= 1000000; break; }
@@ -2719,11 +3008,10 @@ int main(int argc, char **argv){
if( c=='G' ){ szHeap *= 1000000000; break; }
}
if( szHeap>0x7fff0000 ) szHeap = 0x7fff0000;
-#if defined(SQLITE_ENABLE_MEMSYS3) || defined(SQLITE_ENABLE_MEMSYS5)
sqlite3_config(SQLITE_CONFIG_HEAP, malloc((int)szHeap), (int)szHeap, 64);
#endif
#ifdef SQLITE_ENABLE_VFSTRACE
- }else if( strcmp(argv[i],"-vfstrace")==0 ){
+ }else if( strcmp(z,"-vfstrace")==0 ){
extern int vfstrace_register(
const char *zTraceName,
const char *zOldVfsName,
@@ -2733,8 +3021,13 @@ int main(int argc, char **argv){
);
vfstrace_register("trace",0,(int(*)(const char*,void*))fputs,stderr,1);
#endif
- }else if( strcmp(argv[i],"-vfs")==0 ){
- sqlite3_vfs *pVfs = sqlite3_vfs_find(argv[++i]);
+#ifdef SQLITE_ENABLE_MULTIPLEX
+ }else if( strcmp(z,"-multiplex")==0 ){
+ extern int sqlite3_multiple_initialize(const char*,int);
+ sqlite3_multiplex_initialize(0, 1);
+#endif
+ }else if( strcmp(z,"-vfs")==0 ){
+ sqlite3_vfs *pVfs = sqlite3_vfs_find(cmdline_option_value(argc,argv,++i));
if( pVfs ){
sqlite3_vfs_register(pVfs, 1);
}else{
@@ -2743,35 +3036,15 @@ int main(int argc, char **argv){
}
}
}
- if( i<argc ){
-#if defined(SQLITE_OS_OS2) && SQLITE_OS_OS2
- data.zDbFilename = (const char *)convertCpPathToUtf8( argv[i++] );
-#else
- data.zDbFilename = argv[i++];
-#endif
- }else{
+ if( data.zDbFilename==0 ){
#ifndef SQLITE_OMIT_MEMORYDB
data.zDbFilename = ":memory:";
#else
- data.zDbFilename = 0;
-#endif
- }
- if( i<argc ){
- zFirstCmd = argv[i++];
- }
- if( i<argc ){
- fprintf(stderr,"%s: Error: too many options: \"%s\"\n", Argv0, argv[i]);
- fprintf(stderr,"Use -help for a list of options.\n");
- return 1;
- }
- data.out = stdout;
-
-#ifdef SQLITE_OMIT_MEMORYDB
- if( data.zDbFilename==0 ){
fprintf(stderr,"%s: Error: no database filename specified\n", Argv0);
return 1;
- }
#endif
+ }
+ data.out = stdout;
/* Go ahead and open the database file if it already exists. If the
** file does not exist, delay opening it. This prevents empty database
@@ -2796,8 +3069,9 @@ int main(int argc, char **argv){
** file is processed so that the command-line arguments will override
** settings in the initialization file.
*/
- for(i=1; i<argc && argv[i][0]=='-'; i++){
+ for(i=1; i<argc; i++){
char *z = argv[i];
+ if( z[0]!='-' ) continue;
if( z[1]=='-' ){ z++; }
if( strcmp(z,"-init")==0 ){
i++;
@@ -2813,23 +3087,11 @@ int main(int argc, char **argv){
data.mode = MODE_Csv;
memcpy(data.separator,",",2);
}else if( strcmp(z,"-separator")==0 ){
- i++;
- if(i>=argc){
- fprintf(stderr,"%s: Error: missing argument for option: %s\n", Argv0, z);
- fprintf(stderr,"Use -help for a list of options.\n");
- return 1;
- }
sqlite3_snprintf(sizeof(data.separator), data.separator,
- "%.*s",(int)sizeof(data.separator)-1,argv[i]);
+ "%s",cmdline_option_value(argc,argv,++i));
}else if( strcmp(z,"-nullvalue")==0 ){
- i++;
- if(i>=argc){
- fprintf(stderr,"%s: Error: missing argument for option: %s\n", Argv0, z);
- fprintf(stderr,"Use -help for a list of options.\n");
- return 1;
- }
sqlite3_snprintf(sizeof(data.nullvalue), data.nullvalue,
- "%.*s",(int)sizeof(data.nullvalue)-1,argv[i]);
+ "%s",cmdline_option_value(argc,argv,++i));
}else if( strcmp(z,"-header")==0 ){
data.showHeader = 1;
}else if( strcmp(z,"-noheader")==0 ){
@@ -2851,10 +3113,33 @@ int main(int argc, char **argv){
i++;
}else if( strcmp(z,"-vfs")==0 ){
i++;
+#ifdef SQLITE_ENABLE_VFSTRACE
}else if( strcmp(z,"-vfstrace")==0 ){
i++;
- }else if( strcmp(z,"-help")==0 || strcmp(z, "--help")==0 ){
+#endif
+#ifdef SQLITE_ENABLE_MULTIPLEX
+ }else if( strcmp(z,"-multiplex")==0 ){
+ i++;
+#endif
+ }else if( strcmp(z,"-help")==0 ){
usage(1);
+ }else if( strcmp(z,"-cmd")==0 ){
+ if( i==argc-1 ) break;
+ z = cmdline_option_value(argc,argv,++i);
+ if( z[0]=='.' ){
+ rc = do_meta_command(z, &data);
+ if( rc && bail_on_error ) return rc;
+ }else{
+ open_db(&data);
+ rc = shell_exec(data.db, z, shell_callback, &data, &zErrMsg);
+ if( zErrMsg!=0 ){
+ fprintf(stderr,"Error: %s\n", zErrMsg);
+ if( bail_on_error ) return rc!=0 ? rc : 1;
+ }else if( rc!=0 ){
+ fprintf(stderr,"Error: unable to process SQL \"%s\"\n", z);
+ if( bail_on_error ) return rc;
+ }
+ }
}else{
fprintf(stderr,"%s: Error: unknown option: %s\n", Argv0, z);
fprintf(stderr,"Use -help for a list of options.\n");
@@ -2886,7 +3171,7 @@ int main(int argc, char **argv){
char *zHistory = 0;
int nHistory;
printf(
- "SQLite version %s %.19s\n"
+ "SQLite version %s %.19s\n" /*extra-version-info*/
"Enter \".help\" for instructions\n"
"Enter SQL statements terminated with a \";\"\n",
sqlite3_libversion(), sqlite3_sourceid()
@@ -2907,7 +3192,6 @@ int main(int argc, char **argv){
write_history(zHistory);
free(zHistory);
}
- free(zHome);
}else{
rc = process_input(&data, stdin);
}
diff --git a/src/3rdparty/sqlite/sqlite3.c b/src/3rdparty/sqlite/sqlite3.c
index 024dad7c6e..37ee4ad380 100644
--- a/src/3rdparty/sqlite/sqlite3.c
+++ b/src/3rdparty/sqlite/sqlite3.c
@@ -1,6 +1,6 @@
/******************************************************************************
** This file is an amalgamation of many separate C source files from SQLite
-** version 3.7.7.1. By combining all the individual C code files into this
+** version 3.7.16.1. By combining all the individual C code files into this
** single large file, the entire code can be compiled as a single translation
** unit. This allows many compilers to do optimizations that would not be
** possible if the files were compiled separately. Performance improvements
@@ -306,6 +306,10 @@
# define _GNU_SOURCE
#endif
+#if defined(__OpenBSD__) && !defined(_BSD_SOURCE)
+# define _BSD_SOURCE
+#endif
+
/*
** Include standard header files as necessary
*/
@@ -317,13 +321,6 @@
#endif
/*
-** The number of samples of an index that SQLite takes in order to
-** construct a histogram of the table content when running ANALYZE
-** and with SQLITE_ENABLE_STAT2
-*/
-#define SQLITE_INDEX_SAMPLES 10
-
-/*
** The following macros are used to cast pointers to integers and
** integers to pointers. The way you do this varies from one compiler
** to the next, so we have developed the following set of #if statements
@@ -373,6 +370,14 @@
#endif
/*
+** Powersafe overwrite is on by default. But can be turned off using
+** the -DSQLITE_POWERSAFE_OVERWRITE=0 command-line option.
+*/
+#ifndef SQLITE_POWERSAFE_OVERWRITE
+# define SQLITE_POWERSAFE_OVERWRITE 1
+#endif
+
+/*
** The SQLITE_DEFAULT_MEMSTATUS macro must be defined as either 0 or 1.
** It determines whether or not the features related to
** SQLITE_CONFIG_MEMSTATUS are available by default or not. This value can
@@ -387,19 +392,34 @@
** specify which memory allocation subsystem to use.
**
** SQLITE_SYSTEM_MALLOC // Use normal system malloc()
+** SQLITE_WIN32_MALLOC // Use Win32 native heap API
+** SQLITE_ZERO_MALLOC // Use a stub allocator that always fails
** SQLITE_MEMDEBUG // Debugging version of system malloc()
**
+** On Windows, if the SQLITE_WIN32_MALLOC_VALIDATE macro is defined and the
+** assert() macro is enabled, each call into the Win32 native heap subsystem
+** will cause HeapValidate to be called. If heap validation should fail, an
+** assertion will be triggered.
+**
** (Historical note: There used to be several other options, but we've
-** pared it down to just these two.)
+** pared it down to just these three.)
**
** If none of the above are defined, then set SQLITE_SYSTEM_MALLOC as
** the default.
*/
-#if defined(SQLITE_SYSTEM_MALLOC)+defined(SQLITE_MEMDEBUG)>1
-# error "At most one of the following compile-time configuration options\
- is allows: SQLITE_SYSTEM_MALLOC, SQLITE_MEMDEBUG"
-#endif
-#if defined(SQLITE_SYSTEM_MALLOC)+defined(SQLITE_MEMDEBUG)==0
+#if defined(SQLITE_SYSTEM_MALLOC) \
+ + defined(SQLITE_WIN32_MALLOC) \
+ + defined(SQLITE_ZERO_MALLOC) \
+ + defined(SQLITE_MEMDEBUG)>1
+# error "Two or more of the following compile-time configuration options\
+ are defined but at most one is allowed:\
+ SQLITE_SYSTEM_MALLOC, SQLITE_WIN32_MALLOC, SQLITE_MEMDEBUG,\
+ SQLITE_ZERO_MALLOC"
+#endif
+#if defined(SQLITE_SYSTEM_MALLOC) \
+ + defined(SQLITE_WIN32_MALLOC) \
+ + defined(SQLITE_ZERO_MALLOC) \
+ + defined(SQLITE_MEMDEBUG)==0
# define SQLITE_SYSTEM_MALLOC 1
#endif
@@ -424,7 +444,8 @@
**
** See also ticket #2741.
*/
-#if !defined(_XOPEN_SOURCE) && !defined(__DARWIN__) && !defined(__APPLE__) && SQLITE_THREADSAFE && !defined(VXWORKS)
+#if !defined(_XOPEN_SOURCE) && !defined(__DARWIN__) \
+ && !defined(__APPLE__) && SQLITE_THREADSAFE
# define _XOPEN_SOURCE 500 /* Needed to enable pthread recursive mutexes */
#endif
@@ -436,15 +457,22 @@
#endif
/*
-** Many people are failing to set -DNDEBUG=1 when compiling SQLite.
-** Setting NDEBUG makes the code smaller and run faster. So the following
-** lines are added to automatically set NDEBUG unless the -DSQLITE_DEBUG=1
-** option is set. Thus NDEBUG becomes an opt-in rather than an opt-out
+** NDEBUG and SQLITE_DEBUG are opposites. It should always be true that
+** defined(NDEBUG)==!defined(SQLITE_DEBUG). If this is not currently true,
+** make it true by defining or undefining NDEBUG.
+**
+** Setting NDEBUG makes the code smaller and run faster by disabling the
+** number assert() statements in the code. So we want the default action
+** to be for NDEBUG to be set and NDEBUG to be undefined only if SQLITE_DEBUG
+** is set. Thus NDEBUG becomes an opt-in rather than an opt-out
** feature.
*/
#if !defined(NDEBUG) && !defined(SQLITE_DEBUG)
# define NDEBUG 1
#endif
+#if defined(NDEBUG) && defined(SQLITE_DEBUG)
+# undef NDEBUG
+#endif
/*
** The testcase() macro is used to aid in coverage testing. When
@@ -575,13 +603,6 @@ SQLITE_PRIVATE void sqlite3Coverage(int);
*/
#ifndef _SQLITE3_H_
#define _SQLITE3_H_
-
-#ifdef VXWORKS
-# define SQLITE_HOMEGROWN_RECURSIVE_MUTEX
-# define NO_GETTOD
-# include <ioLib.h>
-#endif
-
#include <stdarg.h> /* Needed for the definition of va_list */
/*
@@ -657,9 +678,9 @@ extern "C" {
** [sqlite3_libversion_number()], [sqlite3_sourceid()],
** [sqlite_version()] and [sqlite_source_id()].
*/
-#define SQLITE_VERSION "3.7.7.1"
-#define SQLITE_VERSION_NUMBER 3007007
-#define SQLITE_SOURCE_ID "2011-06-28 17:39:05 af0d91adf497f5f36ec3813f04235a6e195a605f"
+#define SQLITE_VERSION "3.7.16.1"
+#define SQLITE_VERSION_NUMBER 3007016
+#define SQLITE_SOURCE_ID "2013-03-29 13:44:34 527231bc67285f01fb18d4451b28f61da3c4e39d"
/*
** CAPI3REF: Run-Time Library Version Numbers
@@ -727,7 +748,7 @@ SQLITE_API const char *sqlite3_compileoption_get(int N);
** CAPI3REF: Test To See If The Library Is Threadsafe
**
** ^The sqlite3_threadsafe() function returns zero if and only if
-** SQLite was compiled mutexing code omitted due to the
+** SQLite was compiled with mutexing code omitted due to the
** [SQLITE_THREADSAFE] compile-time option being set to 0.
**
** SQLite can be compiled with or without mutexes. When
@@ -769,7 +790,8 @@ SQLITE_API int sqlite3_threadsafe(void);
** the opaque structure named "sqlite3". It is useful to think of an sqlite3
** pointer as an object. The [sqlite3_open()], [sqlite3_open16()], and
** [sqlite3_open_v2()] interfaces are its constructors, and [sqlite3_close()]
-** is its destructor. There are many other interfaces (such as
+** and [sqlite3_close_v2()] are its destructors. There are many other
+** interfaces (such as
** [sqlite3_prepare_v2()], [sqlite3_create_function()], and
** [sqlite3_busy_timeout()] to name but three) that are methods on an
** sqlite3 object.
@@ -816,28 +838,46 @@ typedef sqlite_uint64 sqlite3_uint64;
/*
** CAPI3REF: Closing A Database Connection
**
-** ^The sqlite3_close() routine is the destructor for the [sqlite3] object.
-** ^Calls to sqlite3_close() return SQLITE_OK if the [sqlite3] object is
-** successfully destroyed and all associated resources are deallocated.
-**
-** Applications must [sqlite3_finalize | finalize] all [prepared statements]
-** and [sqlite3_blob_close | close] all [BLOB handles] associated with
-** the [sqlite3] object prior to attempting to close the object. ^If
-** sqlite3_close() is called on a [database connection] that still has
-** outstanding [prepared statements] or [BLOB handles], then it returns
-** SQLITE_BUSY.
-**
-** ^If [sqlite3_close()] is invoked while a transaction is open,
+** ^The sqlite3_close() and sqlite3_close_v2() routines are destructors
+** for the [sqlite3] object.
+** ^Calls to sqlite3_close() and sqlite3_close_v2() return SQLITE_OK if
+** the [sqlite3] object is successfully destroyed and all associated
+** resources are deallocated.
+**
+** ^If the database connection is associated with unfinalized prepared
+** statements or unfinished sqlite3_backup objects then sqlite3_close()
+** will leave the database connection open and return [SQLITE_BUSY].
+** ^If sqlite3_close_v2() is called with unfinalized prepared statements
+** and unfinished sqlite3_backups, then the database connection becomes
+** an unusable "zombie" which will automatically be deallocated when the
+** last prepared statement is finalized or the last sqlite3_backup is
+** finished. The sqlite3_close_v2() interface is intended for use with
+** host languages that are garbage collected, and where the order in which
+** destructors are called is arbitrary.
+**
+** Applications should [sqlite3_finalize | finalize] all [prepared statements],
+** [sqlite3_blob_close | close] all [BLOB handles], and
+** [sqlite3_backup_finish | finish] all [sqlite3_backup] objects associated
+** with the [sqlite3] object prior to attempting to close the object. ^If
+** sqlite3_close_v2() is called on a [database connection] that still has
+** outstanding [prepared statements], [BLOB handles], and/or
+** [sqlite3_backup] objects then it returns SQLITE_OK but the deallocation
+** of resources is deferred until all [prepared statements], [BLOB handles],
+** and [sqlite3_backup] objects are also destroyed.
+**
+** ^If an [sqlite3] object is destroyed while a transaction is open,
** the transaction is automatically rolled back.
**
-** The C parameter to [sqlite3_close(C)] must be either a NULL
+** The C parameter to [sqlite3_close(C)] and [sqlite3_close_v2(C)]
+** must be either a NULL
** pointer or an [sqlite3] object pointer obtained
** from [sqlite3_open()], [sqlite3_open16()], or
** [sqlite3_open_v2()], and not previously closed.
-** ^Calling sqlite3_close() with a NULL pointer argument is a
-** harmless no-op.
+** ^Calling sqlite3_close() or sqlite3_close_v2() with a NULL pointer
+** argument is a harmless no-op.
*/
-SQLITE_API int sqlite3_close(sqlite3 *);
+SQLITE_API int sqlite3_close(sqlite3*);
+SQLITE_API int sqlite3_close_v2(sqlite3*);
/*
** The type for a callback function.
@@ -921,7 +961,7 @@ SQLITE_API int sqlite3_exec(
** KEYWORDS: {result code} {result codes}
**
** Many SQLite functions return an integer result code from the set shown
-** here in order to indicates success or failure.
+** here in order to indicate success or failure.
**
** New error codes may be added in future versions of SQLite.
**
@@ -1005,12 +1045,26 @@ SQLITE_API int sqlite3_exec(
#define SQLITE_IOERR_SHMLOCK (SQLITE_IOERR | (20<<8))
#define SQLITE_IOERR_SHMMAP (SQLITE_IOERR | (21<<8))
#define SQLITE_IOERR_SEEK (SQLITE_IOERR | (22<<8))
+#define SQLITE_IOERR_DELETE_NOENT (SQLITE_IOERR | (23<<8))
#define SQLITE_LOCKED_SHAREDCACHE (SQLITE_LOCKED | (1<<8))
#define SQLITE_BUSY_RECOVERY (SQLITE_BUSY | (1<<8))
#define SQLITE_CANTOPEN_NOTEMPDIR (SQLITE_CANTOPEN | (1<<8))
+#define SQLITE_CANTOPEN_ISDIR (SQLITE_CANTOPEN | (2<<8))
+#define SQLITE_CANTOPEN_FULLPATH (SQLITE_CANTOPEN | (3<<8))
#define SQLITE_CORRUPT_VTAB (SQLITE_CORRUPT | (1<<8))
#define SQLITE_READONLY_RECOVERY (SQLITE_READONLY | (1<<8))
#define SQLITE_READONLY_CANTLOCK (SQLITE_READONLY | (2<<8))
+#define SQLITE_READONLY_ROLLBACK (SQLITE_READONLY | (3<<8))
+#define SQLITE_ABORT_ROLLBACK (SQLITE_ABORT | (2<<8))
+#define SQLITE_CONSTRAINT_CHECK (SQLITE_CONSTRAINT | (1<<8))
+#define SQLITE_CONSTRAINT_COMMITHOOK (SQLITE_CONSTRAINT | (2<<8))
+#define SQLITE_CONSTRAINT_FOREIGNKEY (SQLITE_CONSTRAINT | (3<<8))
+#define SQLITE_CONSTRAINT_FUNCTION (SQLITE_CONSTRAINT | (4<<8))
+#define SQLITE_CONSTRAINT_NOTNULL (SQLITE_CONSTRAINT | (5<<8))
+#define SQLITE_CONSTRAINT_PRIMARYKEY (SQLITE_CONSTRAINT | (6<<8))
+#define SQLITE_CONSTRAINT_TRIGGER (SQLITE_CONSTRAINT | (7<<8))
+#define SQLITE_CONSTRAINT_UNIQUE (SQLITE_CONSTRAINT | (8<<8))
+#define SQLITE_CONSTRAINT_VTAB (SQLITE_CONSTRAINT | (9<<8))
/*
** CAPI3REF: Flags For File Open Operations
@@ -1026,6 +1080,7 @@ SQLITE_API int sqlite3_exec(
#define SQLITE_OPEN_EXCLUSIVE 0x00000010 /* VFS only */
#define SQLITE_OPEN_AUTOPROXY 0x00000020 /* VFS only */
#define SQLITE_OPEN_URI 0x00000040 /* Ok for sqlite3_open_v2() */
+#define SQLITE_OPEN_MEMORY 0x00000080 /* Ok for sqlite3_open_v2() */
#define SQLITE_OPEN_MAIN_DB 0x00000100 /* VFS only */
#define SQLITE_OPEN_TEMP_DB 0x00000200 /* VFS only */
#define SQLITE_OPEN_TRANSIENT_DB 0x00000400 /* VFS only */
@@ -1045,7 +1100,7 @@ SQLITE_API int sqlite3_exec(
** CAPI3REF: Device Characteristics
**
** The xDeviceCharacteristics method of the [sqlite3_io_methods]
-** object returns an integer which is a vector of the these
+** object returns an integer which is a vector of these
** bit values expressing I/O characteristics of the mass storage
** device that holds the file that the [sqlite3_io_methods]
** refers to.
@@ -1059,7 +1114,11 @@ SQLITE_API int sqlite3_exec(
** first then the size of the file is extended, never the other
** way around. The SQLITE_IOCAP_SEQUENTIAL property means that
** information is written to disk in the same order as calls
-** to xWrite().
+** to xWrite(). The SQLITE_IOCAP_POWERSAFE_OVERWRITE property means that
+** after reboot following a crash or power loss, the only bytes in a
+** file that were written at the application level might have changed
+** and that adjacent bytes, even bytes within the same sector are
+** guaranteed to be unchanged.
*/
#define SQLITE_IOCAP_ATOMIC 0x00000001
#define SQLITE_IOCAP_ATOMIC512 0x00000002
@@ -1073,6 +1132,7 @@ SQLITE_API int sqlite3_exec(
#define SQLITE_IOCAP_SAFE_APPEND 0x00000200
#define SQLITE_IOCAP_SEQUENTIAL 0x00000400
#define SQLITE_IOCAP_UNDELETABLE_WHEN_OPEN 0x00000800
+#define SQLITE_IOCAP_POWERSAFE_OVERWRITE 0x00001000
/*
** CAPI3REF: File Locking Levels
@@ -1261,7 +1321,8 @@ struct sqlite3_io_methods {
** into an integer that the pArg argument points to. This capability
** is used during testing and only needs to be supported when SQLITE_TEST
** is defined.
-**
+** <ul>
+** <li>[[SQLITE_FCNTL_SIZE_HINT]]
** The [SQLITE_FCNTL_SIZE_HINT] opcode is used by SQLite to give the VFS
** layer a hint of how large the database file will grow to be during the
** current transaction. This hint is not guaranteed to be accurate but it
@@ -1269,6 +1330,7 @@ struct sqlite3_io_methods {
** file space based on this hint in order to help writes to the database
** file run faster.
**
+** <li>[[SQLITE_FCNTL_CHUNK_SIZE]]
** The [SQLITE_FCNTL_CHUNK_SIZE] opcode is used to request that the VFS
** extends and truncates the database file in chunks of a size specified
** by the user. The fourth argument to [sqlite3_file_control()] should
@@ -1277,11 +1339,13 @@ struct sqlite3_io_methods {
** chunks (say 1MB at a time), may reduce file-system fragmentation and
** improve performance on some systems.
**
+** <li>[[SQLITE_FCNTL_FILE_POINTER]]
** The [SQLITE_FCNTL_FILE_POINTER] opcode is used to obtain a pointer
** to the [sqlite3_file] object associated with a particular database
** connection. See the [sqlite3_file_control()] documentation for
** additional information.
**
+** <li>[[SQLITE_FCNTL_SYNC_OMITTED]]
** ^(The [SQLITE_FCNTL_SYNC_OMITTED] opcode is generated internally by
** SQLite and sent to all VFSes in place of a call to the xSync method
** when the database connection has [PRAGMA synchronous] set to OFF.)^
@@ -1291,16 +1355,127 @@ struct sqlite3_io_methods {
** Applications should not call [sqlite3_file_control()] with this
** opcode as doing so may disrupt the operation of the specialized VFSes
** that do require it.
+**
+** <li>[[SQLITE_FCNTL_WIN32_AV_RETRY]]
+** ^The [SQLITE_FCNTL_WIN32_AV_RETRY] opcode is used to configure automatic
+** retry counts and intervals for certain disk I/O operations for the
+** windows [VFS] in order to provide robustness in the presence of
+** anti-virus programs. By default, the windows VFS will retry file read,
+** file write, and file delete operations up to 10 times, with a delay
+** of 25 milliseconds before the first retry and with the delay increasing
+** by an additional 25 milliseconds with each subsequent retry. This
+** opcode allows these two values (10 retries and 25 milliseconds of delay)
+** to be adjusted. The values are changed for all database connections
+** within the same process. The argument is a pointer to an array of two
+** integers where the first integer i the new retry count and the second
+** integer is the delay. If either integer is negative, then the setting
+** is not changed but instead the prior value of that setting is written
+** into the array entry, allowing the current retry settings to be
+** interrogated. The zDbName parameter is ignored.
+**
+** <li>[[SQLITE_FCNTL_PERSIST_WAL]]
+** ^The [SQLITE_FCNTL_PERSIST_WAL] opcode is used to set or query the
+** persistent [WAL | Write Ahead Log] setting. By default, the auxiliary
+** write ahead log and shared memory files used for transaction control
+** are automatically deleted when the latest connection to the database
+** closes. Setting persistent WAL mode causes those files to persist after
+** close. Persisting the files is useful when other processes that do not
+** have write permission on the directory containing the database file want
+** to read the database file, as the WAL and shared memory files must exist
+** in order for the database to be readable. The fourth parameter to
+** [sqlite3_file_control()] for this opcode should be a pointer to an integer.
+** That integer is 0 to disable persistent WAL mode or 1 to enable persistent
+** WAL mode. If the integer is -1, then it is overwritten with the current
+** WAL persistence setting.
+**
+** <li>[[SQLITE_FCNTL_POWERSAFE_OVERWRITE]]
+** ^The [SQLITE_FCNTL_POWERSAFE_OVERWRITE] opcode is used to set or query the
+** persistent "powersafe-overwrite" or "PSOW" setting. The PSOW setting
+** determines the [SQLITE_IOCAP_POWERSAFE_OVERWRITE] bit of the
+** xDeviceCharacteristics methods. The fourth parameter to
+** [sqlite3_file_control()] for this opcode should be a pointer to an integer.
+** That integer is 0 to disable zero-damage mode or 1 to enable zero-damage
+** mode. If the integer is -1, then it is overwritten with the current
+** zero-damage mode setting.
+**
+** <li>[[SQLITE_FCNTL_OVERWRITE]]
+** ^The [SQLITE_FCNTL_OVERWRITE] opcode is invoked by SQLite after opening
+** a write transaction to indicate that, unless it is rolled back for some
+** reason, the entire database file will be overwritten by the current
+** transaction. This is used by VACUUM operations.
+**
+** <li>[[SQLITE_FCNTL_VFSNAME]]
+** ^The [SQLITE_FCNTL_VFSNAME] opcode can be used to obtain the names of
+** all [VFSes] in the VFS stack. The names are of all VFS shims and the
+** final bottom-level VFS are written into memory obtained from
+** [sqlite3_malloc()] and the result is stored in the char* variable
+** that the fourth parameter of [sqlite3_file_control()] points to.
+** The caller is responsible for freeing the memory when done. As with
+** all file-control actions, there is no guarantee that this will actually
+** do anything. Callers should initialize the char* variable to a NULL
+** pointer in case this file-control is not implemented. This file-control
+** is intended for diagnostic use only.
+**
+** <li>[[SQLITE_FCNTL_PRAGMA]]
+** ^Whenever a [PRAGMA] statement is parsed, an [SQLITE_FCNTL_PRAGMA]
+** file control is sent to the open [sqlite3_file] object corresponding
+** to the database file to which the pragma statement refers. ^The argument
+** to the [SQLITE_FCNTL_PRAGMA] file control is an array of
+** pointers to strings (char**) in which the second element of the array
+** is the name of the pragma and the third element is the argument to the
+** pragma or NULL if the pragma has no argument. ^The handler for an
+** [SQLITE_FCNTL_PRAGMA] file control can optionally make the first element
+** of the char** argument point to a string obtained from [sqlite3_mprintf()]
+** or the equivalent and that string will become the result of the pragma or
+** the error message if the pragma fails. ^If the
+** [SQLITE_FCNTL_PRAGMA] file control returns [SQLITE_NOTFOUND], then normal
+** [PRAGMA] processing continues. ^If the [SQLITE_FCNTL_PRAGMA]
+** file control returns [SQLITE_OK], then the parser assumes that the
+** VFS has handled the PRAGMA itself and the parser generates a no-op
+** prepared statement. ^If the [SQLITE_FCNTL_PRAGMA] file control returns
+** any result code other than [SQLITE_OK] or [SQLITE_NOTFOUND], that means
+** that the VFS encountered an error while handling the [PRAGMA] and the
+** compilation of the PRAGMA fails with an error. ^The [SQLITE_FCNTL_PRAGMA]
+** file control occurs at the beginning of pragma statement analysis and so
+** it is able to override built-in [PRAGMA] statements.
+**
+** <li>[[SQLITE_FCNTL_BUSYHANDLER]]
+** ^This file-control may be invoked by SQLite on the database file handle
+** shortly after it is opened in order to provide a custom VFS with access
+** to the connections busy-handler callback. The argument is of type (void **)
+** - an array of two (void *) values. The first (void *) actually points
+** to a function of type (int (*)(void *)). In order to invoke the connections
+** busy-handler, this function should be invoked with the second (void *) in
+** the array as the only argument. If it returns non-zero, then the operation
+** should be retried. If it returns zero, the custom VFS should abandon the
+** current operation.
+**
+** <li>[[SQLITE_FCNTL_TEMPFILENAME]]
+** ^Application can invoke this file-control to have SQLite generate a
+** temporary filename using the same algorithm that is followed to generate
+** temporary filenames for TEMP tables and other internal uses. The
+** argument should be a char** which will be filled with the filename
+** written into memory obtained from [sqlite3_malloc()]. The caller should
+** invoke [sqlite3_free()] on the result to avoid a memory leak.
+**
+** </ul>
*/
-#define SQLITE_FCNTL_LOCKSTATE 1
-#define SQLITE_GET_LOCKPROXYFILE 2
-#define SQLITE_SET_LOCKPROXYFILE 3
-#define SQLITE_LAST_ERRNO 4
-#define SQLITE_FCNTL_SIZE_HINT 5
-#define SQLITE_FCNTL_CHUNK_SIZE 6
-#define SQLITE_FCNTL_FILE_POINTER 7
-#define SQLITE_FCNTL_SYNC_OMITTED 8
-
+#define SQLITE_FCNTL_LOCKSTATE 1
+#define SQLITE_GET_LOCKPROXYFILE 2
+#define SQLITE_SET_LOCKPROXYFILE 3
+#define SQLITE_LAST_ERRNO 4
+#define SQLITE_FCNTL_SIZE_HINT 5
+#define SQLITE_FCNTL_CHUNK_SIZE 6
+#define SQLITE_FCNTL_FILE_POINTER 7
+#define SQLITE_FCNTL_SYNC_OMITTED 8
+#define SQLITE_FCNTL_WIN32_AV_RETRY 9
+#define SQLITE_FCNTL_PERSIST_WAL 10
+#define SQLITE_FCNTL_OVERWRITE 11
+#define SQLITE_FCNTL_VFSNAME 12
+#define SQLITE_FCNTL_POWERSAFE_OVERWRITE 13
+#define SQLITE_FCNTL_PRAGMA 14
+#define SQLITE_FCNTL_BUSYHANDLER 15
+#define SQLITE_FCNTL_TEMPFILENAME 16
/*
** CAPI3REF: Mutex Handle
@@ -1355,7 +1530,7 @@ typedef struct sqlite3_mutex sqlite3_mutex;
** from xFullPathname() with an optional suffix added.
** ^If a suffix is added to the zFilename parameter, it will
** consist of a single "-" character followed by no more than
-** 10 alphanumeric and/or "-" characters.
+** 11 alphanumeric and/or "-" characters.
** ^SQLite further guarantees that
** the string will be valid and unchanged until xClose() is
** called. Because of the previous sentence,
@@ -1728,16 +1903,10 @@ SQLITE_API int sqlite3_db_config(sqlite3*, int op, ...);
** order to verify that SQLite recovers gracefully from such
** conditions.
**
-** The xMalloc and xFree methods must work like the
-** malloc() and free() functions from the standard C library.
-** The xRealloc method must work like realloc() from the standard C library
-** with the exception that if the second argument to xRealloc is zero,
-** xRealloc must be a no-op - it must not perform any allocation or
-** deallocation. ^SQLite guarantees that the second argument to
+** The xMalloc, xRealloc, and xFree methods must work like the
+** malloc(), realloc() and free() functions from the standard C library.
+** ^SQLite guarantees that the second argument to
** xRealloc is always a value returned by a prior call to xRoundup.
-** And so in cases where xRoundup always returns a positive number,
-** xRealloc can perform exactly as the standard library realloc() and
-** still be in compliance with this specification.
**
** xSize should return the allocated size of a memory allocation
** previously obtained from xMalloc or xRealloc. The allocated size
@@ -1892,7 +2061,7 @@ struct sqlite3_mem_methods {
** <dd> ^This option specifies a static memory buffer that SQLite can use for
** the database page cache with the default page cache implementation.
** This configuration should not be used if an application-define page
-** cache implementation is loaded using the SQLITE_CONFIG_PCACHE option.
+** cache implementation is loaded using the SQLITE_CONFIG_PCACHE2 option.
** There are three arguments to this option: A pointer to 8-byte aligned
** memory, the size of each page buffer (sz), and the number of pages (N).
** The sz argument should be the size of the largest database page
@@ -1923,8 +2092,8 @@ struct sqlite3_mem_methods {
** allocator is engaged to handle all of SQLites memory allocation needs.
** The first pointer (the memory pointer) must be aligned to an 8-byte
** boundary or subsequent behavior of SQLite will be undefined.
-** The minimum allocation size is capped at 2^12. Reasonable values
-** for the minimum allocation size are 2^5 through 2^8.</dd>
+** The minimum allocation size is capped at 2**12. Reasonable values
+** for the minimum allocation size are 2**5 through 2**8.</dd>
**
** [[SQLITE_CONFIG_MUTEX]] <dt>SQLITE_CONFIG_MUTEX</dt>
** <dd> ^(This option takes a single argument which is a pointer to an
@@ -1961,15 +2130,15 @@ struct sqlite3_mem_methods {
** verb to [sqlite3_db_config()] can be used to change the lookaside
** configuration on individual connections.)^ </dd>
**
-** [[SQLITE_CONFIG_PCACHE]] <dt>SQLITE_CONFIG_PCACHE</dt>
+** [[SQLITE_CONFIG_PCACHE2]] <dt>SQLITE_CONFIG_PCACHE2</dt>
** <dd> ^(This option takes a single argument which is a pointer to
-** an [sqlite3_pcache_methods] object. This object specifies the interface
+** an [sqlite3_pcache_methods2] object. This object specifies the interface
** to a custom page cache implementation.)^ ^SQLite makes a copy of the
** object and uses it for page cache memory allocations.</dd>
**
-** [[SQLITE_CONFIG_GETPCACHE]] <dt>SQLITE_CONFIG_GETPCACHE</dt>
+** [[SQLITE_CONFIG_GETPCACHE2]] <dt>SQLITE_CONFIG_GETPCACHE2</dt>
** <dd> ^(This option takes a single argument which is a pointer to an
-** [sqlite3_pcache_methods] object. SQLite copies of the current
+** [sqlite3_pcache_methods2] object. SQLite copies of the current
** page cache implementation into that object.)^ </dd>
**
** [[SQLITE_CONFIG_LOG]] <dt>SQLITE_CONFIG_LOG</dt>
@@ -2002,6 +2171,39 @@ struct sqlite3_mem_methods {
** database connection is opened. By default, URI handling is globally
** disabled. The default value may be changed by compiling with the
** [SQLITE_USE_URI] symbol defined.
+**
+** [[SQLITE_CONFIG_COVERING_INDEX_SCAN]] <dt>SQLITE_CONFIG_COVERING_INDEX_SCAN
+** <dd> This option takes a single integer argument which is interpreted as
+** a boolean in order to enable or disable the use of covering indices for
+** full table scans in the query optimizer. The default setting is determined
+** by the [SQLITE_ALLOW_COVERING_INDEX_SCAN] compile-time option, or is "on"
+** if that compile-time option is omitted.
+** The ability to disable the use of covering indices for full table scans
+** is because some incorrectly coded legacy applications might malfunction
+** malfunction when the optimization is enabled. Providing the ability to
+** disable the optimization allows the older, buggy application code to work
+** without change even with newer versions of SQLite.
+**
+** [[SQLITE_CONFIG_PCACHE]] [[SQLITE_CONFIG_GETPCACHE]]
+** <dt>SQLITE_CONFIG_PCACHE and SQLITE_CONFIG_GETPCACHE
+** <dd> These options are obsolete and should not be used by new code.
+** They are retained for backwards compatibility but are now no-ops.
+** </dl>
+**
+** [[SQLITE_CONFIG_SQLLOG]]
+** <dt>SQLITE_CONFIG_SQLLOG
+** <dd>This option is only available if sqlite is compiled with the
+** SQLITE_ENABLE_SQLLOG pre-processor macro defined. The first argument should
+** be a pointer to a function of type void(*)(void*,sqlite3*,const char*, int).
+** The second should be of type (void*). The callback is invoked by the library
+** in three separate circumstances, identified by the value passed as the
+** fourth parameter. If the fourth parameter is 0, then the database connection
+** passed as the second argument has just been opened. The third argument
+** points to a buffer containing the name of the main database file. If the
+** fourth parameter is 1, then the SQL statement that the third parameter
+** points to has just been executed. Or, if the fourth parameter is 2, then
+** the connection being passed as the second parameter is being closed. The
+** third parameter is passed NULL In this case.
** </dl>
*/
#define SQLITE_CONFIG_SINGLETHREAD 1 /* nil */
@@ -2017,10 +2219,14 @@ struct sqlite3_mem_methods {
#define SQLITE_CONFIG_GETMUTEX 11 /* sqlite3_mutex_methods* */
/* previously SQLITE_CONFIG_CHUNKALLOC 12 which is now unused. */
#define SQLITE_CONFIG_LOOKASIDE 13 /* int int */
-#define SQLITE_CONFIG_PCACHE 14 /* sqlite3_pcache_methods* */
-#define SQLITE_CONFIG_GETPCACHE 15 /* sqlite3_pcache_methods* */
+#define SQLITE_CONFIG_PCACHE 14 /* no-op */
+#define SQLITE_CONFIG_GETPCACHE 15 /* no-op */
#define SQLITE_CONFIG_LOG 16 /* xFunc, void* */
#define SQLITE_CONFIG_URI 17 /* int */
+#define SQLITE_CONFIG_PCACHE2 18 /* sqlite3_pcache_methods2* */
+#define SQLITE_CONFIG_GETPCACHE2 19 /* sqlite3_pcache_methods2* */
+#define SQLITE_CONFIG_COVERING_INDEX_SCAN 20 /* int */
+#define SQLITE_CONFIG_SQLLOG 21 /* xSqllog, void* */
/*
** CAPI3REF: Database Connection Configuration Options
@@ -2505,7 +2711,7 @@ SQLITE_API void sqlite3_free_table(char **result);
** All of the usual printf() formatting options apply. In addition, there
** is are "%q", "%Q", and "%z" options.
**
-** ^(The %q option works like %s in that it substitutes a null-terminated
+** ^(The %q option works like %s in that it substitutes a nul-terminated
** string from the argument list. But %q also doubles every '\'' character.
** %q is designed for use inside a string literal.)^ By doubling each '\''
** character it escapes that character and allows it to be inserted into
@@ -2618,12 +2824,12 @@ SQLITE_API char *sqlite3_vsnprintf(int,char*,const char*, va_list);
** implementation of these routines to be omitted. That capability
** is no longer provided. Only built-in memory allocators can be used.
**
-** The Windows OS interface layer calls
+** Prior to SQLite version 3.7.10, the Windows OS interface layer called
** the system malloc() and free() directly when converting
** filenames between the UTF-8 encoding used by SQLite
** and whatever filename encoding is used by the particular Windows
-** installation. Memory allocation errors are detected, but
-** they are reported back as [SQLITE_CANTOPEN] or
+** installation. Memory allocation errors were detected, but
+** they were reported back as [SQLITE_CANTOPEN] or
** [SQLITE_IOERR] rather than [SQLITE_NOMEM].
**
** The pointer arguments to [sqlite3_free()] and [sqlite3_realloc()]
@@ -3024,18 +3230,20 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*);
** present, then the VFS specified by the option takes precedence over
** the value passed as the fourth parameter to sqlite3_open_v2().
**
-** <li> <b>mode</b>: ^(The mode parameter may be set to either "ro", "rw" or
-** "rwc". Attempting to set it to any other value is an error)^.
+** <li> <b>mode</b>: ^(The mode parameter may be set to either "ro", "rw",
+** "rwc", or "memory". Attempting to set it to any other value is
+** an error)^.
** ^If "ro" is specified, then the database is opened for read-only
** access, just as if the [SQLITE_OPEN_READONLY] flag had been set in the
-** third argument to sqlite3_prepare_v2(). ^If the mode option is set to
+** third argument to sqlite3_open_v2(). ^If the mode option is set to
** "rw", then the database is opened for read-write (but not create)
** access, as if SQLITE_OPEN_READWRITE (but not SQLITE_OPEN_CREATE) had
** been set. ^Value "rwc" is equivalent to setting both
-** SQLITE_OPEN_READWRITE and SQLITE_OPEN_CREATE. ^If sqlite3_open_v2() is
-** used, it is an error to specify a value for the mode parameter that is
-** less restrictive than that specified by the flags passed as the third
-** parameter.
+** SQLITE_OPEN_READWRITE and SQLITE_OPEN_CREATE. ^If the mode option is
+** set to "memory" then a pure [in-memory database] that never reads
+** or writes from disk is used. ^It is an error to specify a value for
+** the mode parameter that is less restrictive than that specified by
+** the flags passed in the third parameter to sqlite3_open_v2().
**
** <li> <b>cache</b>: ^The cache parameter may be set to either "shared" or
** "private". ^Setting it to "shared" is equivalent to setting the
@@ -3043,7 +3251,7 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*);
** sqlite3_open_v2(). ^Setting the cache parameter to "private" is
** equivalent to setting the SQLITE_OPEN_PRIVATECACHE bit.
** ^If sqlite3_open_v2() is used and the "cache" parameter is present in
-** a URI filename, its value overrides any behaviour requested by setting
+** a URI filename, its value overrides any behavior requested by setting
** SQLITE_OPEN_PRIVATECACHE or SQLITE_OPEN_SHAREDCACHE flag.
** </ul>
**
@@ -3094,6 +3302,12 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*);
** codepage is currently defined. Filenames containing international
** characters must be converted to UTF-8 prior to passing them into
** sqlite3_open() or sqlite3_open_v2().
+**
+** <b>Note to Windows Runtime users:</b> The temporary directory must be set
+** prior to calling sqlite3_open() or sqlite3_open_v2(). Otherwise, various
+** features that require the use of temporary files may fail.
+**
+** See also: [sqlite3_temp_directory]
*/
SQLITE_API int sqlite3_open(
const char *filename, /* Database filename (UTF-8) */
@@ -3113,21 +3327,45 @@ SQLITE_API int sqlite3_open_v2(
/*
** CAPI3REF: Obtain Values For URI Parameters
**
-** This is a utility routine, useful to VFS implementations, that checks
+** These are utility routines, useful to VFS implementations, that check
** to see if a database file was a URI that contained a specific query
-** parameter, and if so obtains the value of the query parameter.
-**
-** The zFilename argument is the filename pointer passed into the xOpen()
-** method of a VFS implementation. The zParam argument is the name of the
-** query parameter we seek. This routine returns the value of the zParam
-** parameter if it exists. If the parameter does not exist, this routine
-** returns a NULL pointer.
-**
-** If the zFilename argument to this function is not a pointer that SQLite
-** passed into the xOpen VFS method, then the behavior of this routine
-** is undefined and probably undesirable.
+** parameter, and if so obtains the value of that query parameter.
+**
+** If F is the database filename pointer passed into the xOpen() method of
+** a VFS implementation when the flags parameter to xOpen() has one or
+** more of the [SQLITE_OPEN_URI] or [SQLITE_OPEN_MAIN_DB] bits set and
+** P is the name of the query parameter, then
+** sqlite3_uri_parameter(F,P) returns the value of the P
+** parameter if it exists or a NULL pointer if P does not appear as a
+** query parameter on F. If P is a query parameter of F
+** has no explicit value, then sqlite3_uri_parameter(F,P) returns
+** a pointer to an empty string.
+**
+** The sqlite3_uri_boolean(F,P,B) routine assumes that P is a boolean
+** parameter and returns true (1) or false (0) according to the value
+** of P. The sqlite3_uri_boolean(F,P,B) routine returns true (1) if the
+** value of query parameter P is one of "yes", "true", or "on" in any
+** case or if the value begins with a non-zero number. The
+** sqlite3_uri_boolean(F,P,B) routines returns false (0) if the value of
+** query parameter P is one of "no", "false", or "off" in any case or
+** if the value begins with a numeric zero. If P is not a query
+** parameter on F or if the value of P is does not match any of the
+** above, then sqlite3_uri_boolean(F,P,B) returns (B!=0).
+**
+** The sqlite3_uri_int64(F,P,D) routine converts the value of P into a
+** 64-bit signed integer and returns that integer, or D if P does not
+** exist. If the value of P is something other than an integer, then
+** zero is returned.
+**
+** If F is a NULL pointer, then sqlite3_uri_parameter(F,P) returns NULL and
+** sqlite3_uri_boolean(F,P,B) returns B. If F is not a NULL pointer and
+** is not a database file pathname pointer that SQLite passed into the xOpen
+** VFS method, then the behavior of this routine is undefined and probably
+** undesirable.
*/
SQLITE_API const char *sqlite3_uri_parameter(const char *zFilename, const char *zParam);
+SQLITE_API int sqlite3_uri_boolean(const char *zFile, const char *zParam, int bDefault);
+SQLITE_API sqlite3_int64 sqlite3_uri_int64(const char*, const char*, sqlite3_int64);
/*
@@ -3149,6 +3387,11 @@ SQLITE_API const char *sqlite3_uri_parameter(const char *zFilename, const char *
** However, the error string might be overwritten or deallocated by
** subsequent calls to other SQLite interface functions.)^
**
+** ^The sqlite3_errstr() interface returns the English-language text
+** that describes the [result code], as UTF-8.
+** ^(Memory to hold the error message string is managed internally
+** and must not be freed by the application)^.
+**
** When the serialized [threading mode] is in use, it might be the
** case that a second error occurs on a separate thread in between
** the time of the first error and the call to these interfaces.
@@ -3167,6 +3410,7 @@ SQLITE_API int sqlite3_errcode(sqlite3 *db);
SQLITE_API int sqlite3_extended_errcode(sqlite3 *db);
SQLITE_API const char *sqlite3_errmsg(sqlite3*);
SQLITE_API const void *sqlite3_errmsg16(sqlite3*);
+SQLITE_API const char *sqlite3_errstr(int);
/*
** CAPI3REF: SQL Statement Object
@@ -3323,7 +3567,8 @@ SQLITE_API int sqlite3_limit(sqlite3*, int id, int newVal);
** that the supplied string is nul-terminated, then there is a small
** performance advantage to be gained by passing an nByte parameter that
** is equal to the number of bytes in the input string <i>including</i>
-** the nul-terminator bytes.
+** the nul-terminator bytes as this saves SQLite from having to
+** make a copy of the input string.
**
** ^If pzTail is not NULL then *pzTail is made to point to the first byte
** past the end of the first SQL statement in zSql. These routines only
@@ -3374,7 +3619,7 @@ SQLITE_API int sqlite3_limit(sqlite3*, int id, int newVal);
** ^The specific value of WHERE-clause [parameter] might influence the
** choice of query plan if the parameter is the left-hand side of a [LIKE]
** or [GLOB] operator or if the parameter is compared to an indexed column
-** and the [SQLITE_ENABLE_STAT2] compile-time option is enabled.
+** and the [SQLITE_ENABLE_STAT3] compile-time option is enabled.
** the
** </li>
** </ol>
@@ -3449,6 +3694,25 @@ SQLITE_API const char *sqlite3_sql(sqlite3_stmt *pStmt);
SQLITE_API int sqlite3_stmt_readonly(sqlite3_stmt *pStmt);
/*
+** CAPI3REF: Determine If A Prepared Statement Has Been Reset
+**
+** ^The sqlite3_stmt_busy(S) interface returns true (non-zero) if the
+** [prepared statement] S has been stepped at least once using
+** [sqlite3_step(S)] but has not run to completion and/or has not
+** been reset using [sqlite3_reset(S)]. ^The sqlite3_stmt_busy(S)
+** interface returns false if S is a NULL pointer. If S is not a
+** NULL pointer and is not a pointer to a valid [prepared statement]
+** object, then the behavior is undefined and probably undesirable.
+**
+** This interface can be used in combination [sqlite3_next_stmt()]
+** to locate all prepared statements associated with a database
+** connection that are in need of being reset. This can be used,
+** for example, in diagnostic routines to search for prepared
+** statements that are holding a transaction open.
+*/
+SQLITE_API int sqlite3_stmt_busy(sqlite3_stmt*);
+
+/*
** CAPI3REF: Dynamically Typed Value Object
** KEYWORDS: {protected sqlite3_value} {unprotected sqlite3_value}
**
@@ -3542,8 +3806,18 @@ typedef struct sqlite3_context sqlite3_context;
** ^(In those routines that have a fourth argument, its value is the
** number of bytes in the parameter. To be clear: the value is the
** number of <u>bytes</u> in the value, not the number of characters.)^
-** ^If the fourth parameter is negative, the length of the string is
+** ^If the fourth parameter to sqlite3_bind_text() or sqlite3_bind_text16()
+** is negative, then the length of the string is
** the number of bytes up to the first zero terminator.
+** If the fourth parameter to sqlite3_bind_blob() is negative, then
+** the behavior is undefined.
+** If a non-negative fourth parameter is provided to sqlite3_bind_text()
+** or sqlite3_bind_text16() then that parameter must be the byte offset
+** where the NUL terminator would occur assuming the string were NUL
+** terminated. If any NUL characters occur at byte offsets less than
+** the value of the fourth parameter then the resulting string value will
+** contain embedded NULs. The result of expressions involving strings
+** with embedded NULs is undefined.
**
** ^The fifth argument to sqlite3_bind_blob(), sqlite3_bind_text(), and
** sqlite3_bind_text16() is a destructor used to dispose of the BLOB or
@@ -3877,6 +4151,12 @@ SQLITE_API int sqlite3_step(sqlite3_stmt*);
** (via calls to the [sqlite3_column_int | sqlite3_column_*()] of
** interfaces) then sqlite3_data_count(P) returns 0.
** ^The sqlite3_data_count(P) routine also returns 0 if P is a NULL pointer.
+** ^The sqlite3_data_count(P) routine returns 0 if the previous call to
+** [sqlite3_step](P) returned [SQLITE_DONE]. ^The sqlite3_data_count(P)
+** will return non-zero if previous call to [sqlite3_step](P) returned
+** [SQLITE_ROW], except in the case of the [PRAGMA incremental_vacuum]
+** where it always returns zero since each step of that multi-step
+** pragma returns 0 columns of data.
**
** See also: [sqlite3_column_count()]
*/
@@ -3976,7 +4256,7 @@ SQLITE_API int sqlite3_data_count(sqlite3_stmt *pStmt);
** bytes in the string, not the number of characters.
**
** ^Strings returned by sqlite3_column_text() and sqlite3_column_text16(),
-** even empty strings, are always zero terminated. ^The return
+** even empty strings, are always zero-terminated. ^The return
** value from sqlite3_column_blob() for a zero-length BLOB is a NULL pointer.
**
** ^The object returned by [sqlite3_column_value()] is an
@@ -4289,7 +4569,8 @@ SQLITE_API SQLITE_DEPRECATED int sqlite3_expired(sqlite3_stmt*);
SQLITE_API SQLITE_DEPRECATED int sqlite3_transfer_bindings(sqlite3_stmt*, sqlite3_stmt*);
SQLITE_API SQLITE_DEPRECATED int sqlite3_global_recover(void);
SQLITE_API SQLITE_DEPRECATED void sqlite3_thread_cleanup(void);
-SQLITE_API SQLITE_DEPRECATED int sqlite3_memory_alarm(void(*)(void*,sqlite3_int64,int),void*,sqlite3_int64);
+SQLITE_API SQLITE_DEPRECATED int sqlite3_memory_alarm(void(*)(void*,sqlite3_int64,int),
+ void*,sqlite3_int64);
#endif
/*
@@ -4369,14 +4650,17 @@ SQLITE_API int sqlite3_value_numeric_type(sqlite3_value*);
** In those cases, sqlite3_aggregate_context() might be called for the
** first time from within xFinal().)^
**
-** ^The sqlite3_aggregate_context(C,N) routine returns a NULL pointer if N is
-** less than or equal to zero or if a memory allocate error occurs.
+** ^The sqlite3_aggregate_context(C,N) routine returns a NULL pointer
+** when first called if N is less than or equal to zero or if a memory
+** allocate error occurs.
**
** ^(The amount of space allocated by sqlite3_aggregate_context(C,N) is
** determined by the N parameter on first successful call. Changing the
** value of N in subsequent call to sqlite3_aggregate_context() within
** the same aggregate function instance will not resize the memory
-** allocation.)^
+** allocation.)^ Within the xFinal callback, it is customary to set
+** N=0 in calls to sqlite3_aggregate_context(C,N) so that no
+** pointless memory allocations occur.
**
** ^SQLite automatically frees the memory allocated by
** sqlite3_aggregate_context() when the aggregate query concludes.
@@ -4527,11 +4811,11 @@ typedef void (*sqlite3_destructor_type)(void*);
** the error code is SQLITE_ERROR. ^A subsequent call to sqlite3_result_error()
** or sqlite3_result_error16() resets the error code to SQLITE_ERROR.
**
-** ^The sqlite3_result_toobig() interface causes SQLite to throw an error
-** indicating that a string or BLOB is too long to represent.
+** ^The sqlite3_result_error_toobig() interface causes SQLite to throw an
+** error indicating that a string or BLOB is too long to represent.
**
-** ^The sqlite3_result_nomem() interface causes SQLite to throw an error
-** indicating that a memory allocation failed.
+** ^The sqlite3_result_error_nomem() interface causes SQLite to throw an
+** error indicating that a memory allocation failed.
**
** ^The sqlite3_result_int() interface sets the return value
** of the application-defined function to be the 32-bit signed integer
@@ -4556,7 +4840,12 @@ typedef void (*sqlite3_destructor_type)(void*);
** ^If the 3rd parameter to the sqlite3_result_text* interfaces
** is non-negative, then as many bytes (not characters) of the text
** pointed to by the 2nd parameter are taken as the application-defined
-** function result.
+** function result. If the 3rd parameter is non-negative, then it
+** must be the byte offset into the string where the NUL terminator would
+** appear if the string where NUL terminated. If any NUL characters occur
+** in the string at a byte offset that is less than the value of the 3rd
+** parameter, then the resulting string will contain embedded NULs and the
+** result of expressions operating on strings with embedded NULs is undefined.
** ^If the 4th parameter to the sqlite3_result_text* interfaces
** or sqlite3_result_blob is a non-NULL pointer, then SQLite calls that
** function as the destructor on the text or BLOB result when it has
@@ -4833,10 +5122,62 @@ SQLITE_API int sqlite3_sleep(int);
** Hence, if this variable is modified directly, either it should be
** made NULL or made to point to memory obtained from [sqlite3_malloc]
** or else the use of the [temp_store_directory pragma] should be avoided.
+**
+** <b>Note to Windows Runtime users:</b> The temporary directory must be set
+** prior to calling [sqlite3_open] or [sqlite3_open_v2]. Otherwise, various
+** features that require the use of temporary files may fail. Here is an
+** example of how to do this using C++ with the Windows Runtime:
+**
+** <blockquote><pre>
+** LPCWSTR zPath = Windows::Storage::ApplicationData::Current->
+** &nbsp; TemporaryFolder->Path->Data();
+** char zPathBuf&#91;MAX_PATH + 1&#93;;
+** memset(zPathBuf, 0, sizeof(zPathBuf));
+** WideCharToMultiByte(CP_UTF8, 0, zPath, -1, zPathBuf, sizeof(zPathBuf),
+** &nbsp; NULL, NULL);
+** sqlite3_temp_directory = sqlite3_mprintf("%s", zPathBuf);
+** </pre></blockquote>
*/
SQLITE_API char *sqlite3_temp_directory;
/*
+** CAPI3REF: Name Of The Folder Holding Database Files
+**
+** ^(If this global variable is made to point to a string which is
+** the name of a folder (a.k.a. directory), then all database files
+** specified with a relative pathname and created or accessed by
+** SQLite when using a built-in windows [sqlite3_vfs | VFS] will be assumed
+** to be relative to that directory.)^ ^If this variable is a NULL
+** pointer, then SQLite assumes that all database files specified
+** with a relative pathname are relative to the current directory
+** for the process. Only the windows VFS makes use of this global
+** variable; it is ignored by the unix VFS.
+**
+** Changing the value of this variable while a database connection is
+** open can result in a corrupt database.
+**
+** It is not safe to read or modify this variable in more than one
+** thread at a time. It is not safe to read or modify this variable
+** if a [database connection] is being used at the same time in a separate
+** thread.
+** It is intended that this variable be set once
+** as part of process initialization and before any SQLite interface
+** routines have been called and that this variable remain unchanged
+** thereafter.
+**
+** ^The [data_store_directory pragma] may modify this variable and cause
+** it to point to memory obtained from [sqlite3_malloc]. ^Furthermore,
+** the [data_store_directory pragma] always assumes that any string
+** that this variable points to is held in memory obtained from
+** [sqlite3_malloc] and the pragma may attempt to free that memory
+** using [sqlite3_free].
+** Hence, if this variable is modified directly, either it should be
+** made NULL or made to point to memory obtained from [sqlite3_malloc]
+** or else the use of the [data_store_directory pragma] should be avoided.
+*/
+SQLITE_API char *sqlite3_data_directory;
+
+/*
** CAPI3REF: Test For Auto-Commit Mode
** KEYWORDS: {autocommit mode}
**
@@ -4872,6 +5213,31 @@ SQLITE_API int sqlite3_get_autocommit(sqlite3*);
SQLITE_API sqlite3 *sqlite3_db_handle(sqlite3_stmt*);
/*
+** CAPI3REF: Return The Filename For A Database Connection
+**
+** ^The sqlite3_db_filename(D,N) interface returns a pointer to a filename
+** associated with database N of connection D. ^The main database file
+** has the name "main". If there is no attached database N on the database
+** connection D, or if database N is a temporary or in-memory database, then
+** a NULL pointer is returned.
+**
+** ^The filename returned by this function is the output of the
+** xFullPathname method of the [VFS]. ^In other words, the filename
+** will be an absolute pathname, even if the filename used
+** to open the database originally was a URI or relative pathname.
+*/
+SQLITE_API const char *sqlite3_db_filename(sqlite3 *db, const char *zDbName);
+
+/*
+** CAPI3REF: Determine if a database is read-only
+**
+** ^The sqlite3_db_readonly(D,N) interface returns 1 if the database N
+** of connection D is read-only, 0 if it is read/write, or -1 if N is not
+** the name of a database on connection D.
+*/
+SQLITE_API int sqlite3_db_readonly(sqlite3 *db, const char *zDbName);
+
+/*
** CAPI3REF: Find the next prepared statement
**
** ^This interface returns a pointer to the next [prepared statement] after
@@ -4906,13 +5272,15 @@ SQLITE_API sqlite3_stmt *sqlite3_next_stmt(sqlite3 *pDb, sqlite3_stmt *pStmt);
** on the same [database connection] D, or NULL for
** the first call for each function on D.
**
+** The commit and rollback hook callbacks are not reentrant.
** The callback implementation must not do anything that will modify
** the database connection that invoked the callback. Any actions
** to modify the database connection must be deferred until after the
** completion of the [sqlite3_step()] call that triggered the commit
** or rollback hook in the first place.
-** Note that [sqlite3_prepare_v2()] and [sqlite3_step()] both modify their
-** database connections for the meaning of "modify" in this paragraph.
+** Note that running any other SQL statements, including SELECT statements,
+** or merely calling [sqlite3_prepare_v2()] and [sqlite3_step()] will modify
+** the database connections for the meaning of "modify" in this paragraph.
**
** ^Registering a NULL function disables the callback.
**
@@ -4987,7 +5355,6 @@ SQLITE_API void *sqlite3_update_hook(
/*
** CAPI3REF: Enable Or Disable Shared Pager Cache
-** KEYWORDS: {shared cache}
**
** ^(This routine enables or disables the sharing of the database cache
** and schema data structures between [database connection | connections]
@@ -5010,6 +5377,9 @@ SQLITE_API void *sqlite3_update_hook(
** future releases of SQLite. Applications that care about shared
** cache setting should set it explicitly.
**
+** This interface is threadsafe on processors where writing a
+** 32-bit integer is atomic.
+**
** See Also: [SQLite Shared-Cache Mode]
*/
SQLITE_API int sqlite3_enable_shared_cache(int);
@@ -5025,10 +5395,25 @@ SQLITE_API int sqlite3_enable_shared_cache(int);
** which might be more or less than the amount requested.
** ^The sqlite3_release_memory() routine is a no-op returning zero
** if SQLite is not compiled with [SQLITE_ENABLE_MEMORY_MANAGEMENT].
+**
+** See also: [sqlite3_db_release_memory()]
*/
SQLITE_API int sqlite3_release_memory(int);
/*
+** CAPI3REF: Free Memory Used By A Database Connection
+**
+** ^The sqlite3_db_release_memory(D) interface attempts to free as much heap
+** memory as possible from database connection D. Unlike the
+** [sqlite3_release_memory()] interface, this interface is effect even
+** when then [SQLITE_ENABLE_MEMORY_MANAGEMENT] compile-time option is
+** omitted.
+**
+** See also: [sqlite3_release_memory()]
+*/
+SQLITE_API int sqlite3_db_release_memory(sqlite3*);
+
+/*
** CAPI3REF: Impose A Limit On Heap Size
**
** ^The sqlite3_soft_heap_limit64() interface sets and/or queries the
@@ -5042,7 +5427,8 @@ SQLITE_API int sqlite3_release_memory(int);
** is advisory only.
**
** ^The return value from sqlite3_soft_heap_limit64() is the size of
-** the soft heap limit prior to the call. ^If the argument N is negative
+** the soft heap limit prior to the call, or negative in the case of an
+** error. ^If the argument N is negative
** then no change is made to the soft heap limit. Hence, the current
** size of the soft heap limit can be determined by invoking
** sqlite3_soft_heap_limit64() with a negative argument.
@@ -5058,7 +5444,7 @@ SQLITE_API int sqlite3_release_memory(int);
** [sqlite3_config]([SQLITE_CONFIG_MEMSTATUS],...) start-time option and
** the [SQLITE_DEFAULT_MEMSTATUS] compile-time option.
** <li> An alternative page cache implementation is specified using
-** [sqlite3_config]([SQLITE_CONFIG_PCACHE],...).
+** [sqlite3_config]([SQLITE_CONFIG_PCACHE2],...).
** <li> The page cache allocates from its own memory pool supplied
** by [sqlite3_config]([SQLITE_CONFIG_PAGECACHE],...) rather than
** from the heap.
@@ -5799,17 +6185,16 @@ SQLITE_API int sqlite3_vfs_unregister(sqlite3_vfs*);
** implementations are available in the SQLite core:
**
** <ul>
-** <li> SQLITE_MUTEX_OS2
-** <li> SQLITE_MUTEX_PTHREAD
+** <li> SQLITE_MUTEX_PTHREADS
** <li> SQLITE_MUTEX_W32
** <li> SQLITE_MUTEX_NOOP
** </ul>)^
**
** ^The SQLITE_MUTEX_NOOP implementation is a set of routines
** that does no real locking and is appropriate for use in
-** a single-threaded application. ^The SQLITE_MUTEX_OS2,
-** SQLITE_MUTEX_PTHREAD, and SQLITE_MUTEX_W32 implementations
-** are appropriate for use on OS/2, Unix, and Windows.
+** a single-threaded application. ^The SQLITE_MUTEX_PTHREADS and
+** SQLITE_MUTEX_W32 implementations are appropriate for use on Unix
+** and Windows.
**
** ^(If SQLite is compiled with the SQLITE_MUTEX_APPDEF preprocessor
** macro defined (with "-DSQLITE_MUTEX_APPDEF=1"), then no mutex
@@ -5998,7 +6383,7 @@ struct sqlite3_mutex_methods {
** ^These routines should return true if the mutex in their argument
** is held or not held, respectively, by the calling thread.
**
-** ^The implementation is not required to provided versions of these
+** ^The implementation is not required to provide versions of these
** routines that actually work. If the implementation does not provide working
** versions of these routines, it should at least provide stubs that always
** return true so that one does not get spurious assertion failures.
@@ -6126,9 +6511,9 @@ SQLITE_API int sqlite3_test_control(int op, ...);
#define SQLITE_TESTCTRL_RESERVE 14
#define SQLITE_TESTCTRL_OPTIMIZATIONS 15
#define SQLITE_TESTCTRL_ISKEYWORD 16
-#define SQLITE_TESTCTRL_PGHDRSZ 17
-#define SQLITE_TESTCTRL_SCRATCHMALLOC 18
-#define SQLITE_TESTCTRL_LOCALTIME_FAULT 19
+#define SQLITE_TESTCTRL_SCRATCHMALLOC 17
+#define SQLITE_TESTCTRL_LOCALTIME_FAULT 18
+#define SQLITE_TESTCTRL_EXPLAIN_STMT 19
#define SQLITE_TESTCTRL_LAST 19
/*
@@ -6339,6 +6724,29 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r
** the database connection.)^
** ^The highwater mark associated with SQLITE_DBSTATUS_STMT_USED is always 0.
** </dd>
+**
+** [[SQLITE_DBSTATUS_CACHE_HIT]] ^(<dt>SQLITE_DBSTATUS_CACHE_HIT</dt>
+** <dd>This parameter returns the number of pager cache hits that have
+** occurred.)^ ^The highwater mark associated with SQLITE_DBSTATUS_CACHE_HIT
+** is always 0.
+** </dd>
+**
+** [[SQLITE_DBSTATUS_CACHE_MISS]] ^(<dt>SQLITE_DBSTATUS_CACHE_MISS</dt>
+** <dd>This parameter returns the number of pager cache misses that have
+** occurred.)^ ^The highwater mark associated with SQLITE_DBSTATUS_CACHE_MISS
+** is always 0.
+** </dd>
+**
+** [[SQLITE_DBSTATUS_CACHE_WRITE]] ^(<dt>SQLITE_DBSTATUS_CACHE_WRITE</dt>
+** <dd>This parameter returns the number of dirty cache entries that have
+** been written to disk. Specifically, the number of pages written to the
+** wal file in wal mode databases, or the number of pages written to the
+** database file in rollback mode databases. Any pages written as part of
+** transaction rollback or database recovery operations are not included.
+** If an IO or other error occurs while writing a page to disk, the effect
+** on subsequent SQLITE_DBSTATUS_CACHE_WRITE requests is undefined.)^ ^The
+** highwater mark associated with SQLITE_DBSTATUS_CACHE_WRITE is always 0.
+** </dd>
** </dl>
*/
#define SQLITE_DBSTATUS_LOOKASIDE_USED 0
@@ -6348,7 +6756,10 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r
#define SQLITE_DBSTATUS_LOOKASIDE_HIT 4
#define SQLITE_DBSTATUS_LOOKASIDE_MISS_SIZE 5
#define SQLITE_DBSTATUS_LOOKASIDE_MISS_FULL 6
-#define SQLITE_DBSTATUS_MAX 6 /* Largest defined DBSTATUS */
+#define SQLITE_DBSTATUS_CACHE_HIT 7
+#define SQLITE_DBSTATUS_CACHE_MISS 8
+#define SQLITE_DBSTATUS_CACHE_WRITE 9
+#define SQLITE_DBSTATUS_MAX 9 /* Largest defined DBSTATUS */
/*
@@ -6402,7 +6813,6 @@ SQLITE_API int sqlite3_stmt_status(sqlite3_stmt*, int op,int resetFlg);
** A non-zero value in this counter may indicate an opportunity to
** improvement performance by adding permanent indices that do not
** need to be reinitialized each time the statement is run.</dd>
-**
** </dl>
*/
#define SQLITE_STMTSTATUS_FULLSCAN_STEP 1
@@ -6418,17 +6828,33 @@ SQLITE_API int sqlite3_stmt_status(sqlite3_stmt*, int op,int resetFlg);
** sqlite3_pcache object except by holding and passing pointers
** to the object.
**
-** See [sqlite3_pcache_methods] for additional information.
+** See [sqlite3_pcache_methods2] for additional information.
*/
typedef struct sqlite3_pcache sqlite3_pcache;
/*
+** CAPI3REF: Custom Page Cache Object
+**
+** The sqlite3_pcache_page object represents a single page in the
+** page cache. The page cache will allocate instances of this
+** object. Various methods of the page cache use pointers to instances
+** of this object as parameters or as their return value.
+**
+** See [sqlite3_pcache_methods2] for additional information.
+*/
+typedef struct sqlite3_pcache_page sqlite3_pcache_page;
+struct sqlite3_pcache_page {
+ void *pBuf; /* The content of the page */
+ void *pExtra; /* Extra information associated with the page */
+};
+
+/*
** CAPI3REF: Application Defined Page Cache.
** KEYWORDS: {page cache}
**
-** ^(The [sqlite3_config]([SQLITE_CONFIG_PCACHE], ...) interface can
+** ^(The [sqlite3_config]([SQLITE_CONFIG_PCACHE2], ...) interface can
** register an alternative page cache implementation by passing in an
-** instance of the sqlite3_pcache_methods structure.)^
+** instance of the sqlite3_pcache_methods2 structure.)^
** In many applications, most of the heap memory allocated by
** SQLite is used for the page cache.
** By implementing a
@@ -6442,7 +6868,7 @@ typedef struct sqlite3_pcache sqlite3_pcache;
** extreme measure that is only needed by the most demanding applications.
** The built-in page cache is recommended for most uses.
**
-** ^(The contents of the sqlite3_pcache_methods structure are copied to an
+** ^(The contents of the sqlite3_pcache_methods2 structure are copied to an
** internal buffer by SQLite within the call to [sqlite3_config]. Hence
** the application may discard the parameter after the call to
** [sqlite3_config()] returns.)^
@@ -6451,7 +6877,7 @@ typedef struct sqlite3_pcache sqlite3_pcache;
** ^(The xInit() method is called once for each effective
** call to [sqlite3_initialize()])^
** (usually only once during the lifetime of the process). ^(The xInit()
-** method is passed a copy of the sqlite3_pcache_methods.pArg value.)^
+** method is passed a copy of the sqlite3_pcache_methods2.pArg value.)^
** The intent of the xInit() method is to set up global data structures
** required by the custom page cache implementation.
** ^(If the xInit() method is NULL, then the
@@ -6478,17 +6904,15 @@ typedef struct sqlite3_pcache sqlite3_pcache;
** SQLite will typically create one cache instance for each open database file,
** though this is not guaranteed. ^The
** first parameter, szPage, is the size in bytes of the pages that must
-** be allocated by the cache. ^szPage will not be a power of two. ^szPage
-** will the page size of the database file that is to be cached plus an
-** increment (here called "R") of less than 250. SQLite will use the
-** extra R bytes on each page to store metadata about the underlying
-** database page on disk. The value of R depends
+** be allocated by the cache. ^szPage will always a power of two. ^The
+** second parameter szExtra is a number of bytes of extra storage
+** associated with each page cache entry. ^The szExtra parameter will
+** a number less than 250. SQLite will use the
+** extra szExtra bytes on each page to store metadata about the underlying
+** database page on disk. The value passed into szExtra depends
** on the SQLite version, the target platform, and how SQLite was compiled.
-** ^(R is constant for a particular build of SQLite. Except, there are two
-** distinct values of R when SQLite is compiled with the proprietary
-** ZIPVFS extension.)^ ^The second argument to
-** xCreate(), bPurgeable, is true if the cache being created will
-** be used to cache database pages of a file stored on disk, or
+** ^The third argument to xCreate(), bPurgeable, is true if the cache being
+** created will be used to cache database pages of a file stored on disk, or
** false if it is used for an in-memory database. The cache implementation
** does not have to do anything special based with the value of bPurgeable;
** it is purely advisory. ^On a cache where bPurgeable is false, SQLite will
@@ -6512,11 +6936,16 @@ typedef struct sqlite3_pcache sqlite3_pcache;
**
** [[the xFetch() page cache methods]]
** The xFetch() method locates a page in the cache and returns a pointer to
-** the page, or a NULL pointer.
-** A "page", in this context, means a buffer of szPage bytes aligned at an
-** 8-byte boundary. The page to be fetched is determined by the key. ^The
-** minimum key value is 1. After it has been retrieved using xFetch, the page
-** is considered to be "pinned".
+** an sqlite3_pcache_page object associated with that page, or a NULL pointer.
+** The pBuf element of the returned sqlite3_pcache_page object will be a
+** pointer to a buffer of szPage bytes used to store the content of a
+** single database page. The pExtra element of sqlite3_pcache_page will be
+** a pointer to the szExtra bytes of extra storage that SQLite has requested
+** for each entry in the page cache.
+**
+** The page to be fetched is determined by the key. ^The minimum key value
+** is 1. After it has been retrieved using xFetch, the page is considered
+** to be "pinned".
**
** If the requested page is already in the page cache, then the page cache
** implementation must return a pointer to the page buffer with its content
@@ -6525,7 +6954,7 @@ typedef struct sqlite3_pcache sqlite3_pcache;
** parameter to help it determined what action to take:
**
** <table border=1 width=85% align=center>
-** <tr><th> createFlag <th> Behaviour when page is not already in cache
+** <tr><th> createFlag <th> Behavior when page is not already in cache
** <tr><td> 0 <td> Do not allocate a new page. Return NULL.
** <tr><td> 1 <td> Allocate a new page if it easy and convenient to do so.
** Otherwise return NULL.
@@ -6569,8 +6998,37 @@ typedef struct sqlite3_pcache sqlite3_pcache;
** ^The xDestroy() method is used to delete a cache allocated by xCreate().
** All resources associated with the specified cache should be freed. ^After
** calling the xDestroy() method, SQLite considers the [sqlite3_pcache*]
-** handle invalid, and will not use it with any other sqlite3_pcache_methods
+** handle invalid, and will not use it with any other sqlite3_pcache_methods2
** functions.
+**
+** [[the xShrink() page cache method]]
+** ^SQLite invokes the xShrink() method when it wants the page cache to
+** free up as much of heap memory as possible. The page cache implementation
+** is not obligated to free any memory, but well-behaved implementations should
+** do their best.
+*/
+typedef struct sqlite3_pcache_methods2 sqlite3_pcache_methods2;
+struct sqlite3_pcache_methods2 {
+ int iVersion;
+ void *pArg;
+ int (*xInit)(void*);
+ void (*xShutdown)(void*);
+ sqlite3_pcache *(*xCreate)(int szPage, int szExtra, int bPurgeable);
+ void (*xCachesize)(sqlite3_pcache*, int nCachesize);
+ int (*xPagecount)(sqlite3_pcache*);
+ sqlite3_pcache_page *(*xFetch)(sqlite3_pcache*, unsigned key, int createFlag);
+ void (*xUnpin)(sqlite3_pcache*, sqlite3_pcache_page*, int discard);
+ void (*xRekey)(sqlite3_pcache*, sqlite3_pcache_page*,
+ unsigned oldKey, unsigned newKey);
+ void (*xTruncate)(sqlite3_pcache*, unsigned iLimit);
+ void (*xDestroy)(sqlite3_pcache*);
+ void (*xShrink)(sqlite3_pcache*);
+};
+
+/*
+** This is the obsolete pcache_methods object that has now been replaced
+** by sqlite3_pcache_methods2. This object is not used by SQLite. It is
+** retained in the header file for backwards compatibility only.
*/
typedef struct sqlite3_pcache_methods sqlite3_pcache_methods;
struct sqlite3_pcache_methods {
@@ -6587,6 +7045,7 @@ struct sqlite3_pcache_methods {
void (*xDestroy)(sqlite3_pcache*);
};
+
/*
** CAPI3REF: Online Backup Object
**
@@ -6916,11 +7375,12 @@ SQLITE_API int sqlite3_unlock_notify(
/*
** CAPI3REF: String Comparison
**
-** ^The [sqlite3_strnicmp()] API allows applications and extensions to
-** compare the contents of two buffers containing UTF-8 strings in a
-** case-independent fashion, using the same definition of case independence
-** that SQLite uses internally when comparing identifiers.
+** ^The [sqlite3_stricmp()] and [sqlite3_strnicmp()] APIs allow applications
+** and extensions to compare the contents of two buffers containing UTF-8
+** strings in a case-independent fashion, using the same definition of "case
+** independence" that SQLite uses internally when comparing identifiers.
*/
+SQLITE_API int sqlite3_stricmp(const char *, const char *);
SQLITE_API int sqlite3_strnicmp(const char *, const char *, int);
/*
@@ -7255,7 +7715,11 @@ typedef struct sqlite3_rtree_geometry sqlite3_rtree_geometry;
SQLITE_API int sqlite3_rtree_geometry_callback(
sqlite3 *db,
const char *zGeom,
- int (*xGeom)(sqlite3_rtree_geometry *, int nCoord, double *aCoord, int *pRes),
+#ifdef SQLITE_RTREE_INT_ONLY
+ int (*xGeom)(sqlite3_rtree_geometry*, int n, sqlite3_int64 *a, int *pRes),
+#else
+ int (*xGeom)(sqlite3_rtree_geometry*, int n, double *a, int *pRes),
+#endif
void *pContext
);
@@ -7295,7 +7759,7 @@ struct sqlite3_rtree_geometry {
** May you share freely, never taking more than you give.
**
*************************************************************************
-** This is the header file for the generic hash-table implemenation
+** This is the header file for the generic hash-table implementation
** used in SQLite.
*/
#ifndef _SQLITE_HASH_H_
@@ -7590,7 +8054,7 @@ SQLITE_PRIVATE void sqlite3HashClear(Hash*);
*/
#define SQLITE_MAX_FILE_FORMAT 4
#ifndef SQLITE_DEFAULT_FILE_FORMAT
-# define SQLITE_DEFAULT_FILE_FORMAT 1
+# define SQLITE_DEFAULT_FILE_FORMAT 4
#endif
/*
@@ -7689,6 +8153,18 @@ typedef INT8_TYPE i8; /* 1-byte signed integer */
#define SQLITE_MAX_U32 ((((u64)1)<<32)-1)
/*
+** The datatype used to store estimates of the number of rows in a
+** table or index. This is an unsigned integer type. For 99.9% of
+** the world, a 32-bit integer is sufficient. But a 64-bit integer
+** can be used at compile-time if desired.
+*/
+#ifdef SQLITE_64BIT_STATS
+ typedef u64 tRowcnt; /* 64-bit only if requested at compile-time */
+#else
+ typedef u32 tRowcnt; /* 32-bit is the default */
+#endif
+
+/*
** Macros to determine whether the machine is big or little endian,
** evaluated at runtime.
*/
@@ -7784,10 +8260,19 @@ struct BusyHandler {
#define ArraySize(X) ((int)(sizeof(X)/sizeof(X[0])))
/*
+** Determine if the argument is a power of two
+*/
+#define IsPowerOfTwo(X) (((X)&((X)-1))==0)
+
+/*
** The following value as a destructor means to use sqlite3DbFree().
-** This is an internal extension to SQLITE_STATIC and SQLITE_TRANSIENT.
+** The sqlite3DbFree() routine requires two parameters instead of the
+** one parameter that destructors normally want. So we have to introduce
+** this magic value that the code knows to handle differently. Any
+** pointer will work here as long as it is distinct from SQLITE_STATIC
+** and SQLITE_TRANSIENT.
*/
-#define SQLITE_DYNAMIC ((sqlite3_destructor_type)sqlite3DbFree)
+#define SQLITE_DYNAMIC ((sqlite3_destructor_type)sqlite3MallocSize)
/*
** When SQLITE_OMIT_WSD is defined, it means that the target platform does
@@ -7865,6 +8350,7 @@ typedef struct Parse Parse;
typedef struct RowSet RowSet;
typedef struct Savepoint Savepoint;
typedef struct Select Select;
+typedef struct SelectDest SelectDest;
typedef struct SrcList SrcList;
typedef struct StrAccum StrAccum;
typedef struct Table Table;
@@ -7947,10 +8433,9 @@ SQLITE_PRIVATE int sqlite3BtreeOpen(
** pager.h.
*/
#define BTREE_OMIT_JOURNAL 1 /* Do not create or use a rollback journal */
-#define BTREE_NO_READLOCK 2 /* Omit readlocks on readonly files */
-#define BTREE_MEMORY 4 /* This is an in-memory DB */
-#define BTREE_SINGLE 8 /* The file contains at most 1 b-tree */
-#define BTREE_UNORDERED 16 /* Use of a hash implementation is OK */
+#define BTREE_MEMORY 2 /* This is an in-memory DB */
+#define BTREE_SINGLE 4 /* The file contains at most 1 b-tree */
+#define BTREE_UNORDERED 8 /* Use of a hash implementation is OK */
SQLITE_PRIVATE int sqlite3BtreeClose(Btree*);
SQLITE_PRIVATE int sqlite3BtreeSetCacheSize(Btree*,int);
@@ -7962,13 +8447,16 @@ SQLITE_PRIVATE int sqlite3BtreeMaxPageCount(Btree*,int);
SQLITE_PRIVATE u32 sqlite3BtreeLastPage(Btree*);
SQLITE_PRIVATE int sqlite3BtreeSecureDelete(Btree*,int);
SQLITE_PRIVATE int sqlite3BtreeGetReserve(Btree*);
+#if defined(SQLITE_HAS_CODEC) || defined(SQLITE_DEBUG)
+SQLITE_PRIVATE int sqlite3BtreeGetReserveNoMutex(Btree *p);
+#endif
SQLITE_PRIVATE int sqlite3BtreeSetAutoVacuum(Btree *, int);
SQLITE_PRIVATE int sqlite3BtreeGetAutoVacuum(Btree *);
SQLITE_PRIVATE int sqlite3BtreeBeginTrans(Btree*,int);
SQLITE_PRIVATE int sqlite3BtreeCommitPhaseOne(Btree*, const char *zMaster);
SQLITE_PRIVATE int sqlite3BtreeCommitPhaseTwo(Btree*, int);
SQLITE_PRIVATE int sqlite3BtreeCommit(Btree*);
-SQLITE_PRIVATE int sqlite3BtreeRollback(Btree*);
+SQLITE_PRIVATE int sqlite3BtreeRollback(Btree*,int);
SQLITE_PRIVATE int sqlite3BtreeBeginStmt(Btree*,int);
SQLITE_PRIVATE int sqlite3BtreeCreateTable(Btree*, int*, int flags);
SQLITE_PRIVATE int sqlite3BtreeIsInTrans(Btree*);
@@ -8005,6 +8493,8 @@ SQLITE_PRIVATE void sqlite3BtreeTripAllCursors(Btree*, int);
SQLITE_PRIVATE void sqlite3BtreeGetMeta(Btree *pBtree, int idx, u32 *pValue);
SQLITE_PRIVATE int sqlite3BtreeUpdateMeta(Btree*, int idx, u32 value);
+SQLITE_PRIVATE int sqlite3BtreeNewDb(Btree *p);
+
/*
** The second parameter to sqlite3BtreeGetMeta or sqlite3BtreeUpdateMeta
** should be one of the following values. The integer values are assigned
@@ -8026,6 +8516,12 @@ SQLITE_PRIVATE int sqlite3BtreeUpdateMeta(Btree*, int idx, u32 value);
#define BTREE_USER_VERSION 6
#define BTREE_INCR_VACUUM 7
+/*
+** Values that may be OR'd together to form the second argument of an
+** sqlite3BtreeCursorHints() call.
+*/
+#define BTREE_BULKLOAD 0x00000001
+
SQLITE_PRIVATE int sqlite3BtreeCursor(
Btree*, /* BTree containing table to open */
int iTable, /* Index of root page */
@@ -8069,8 +8565,8 @@ SQLITE_PRIVATE struct Pager *sqlite3BtreePager(Btree*);
SQLITE_PRIVATE int sqlite3BtreePutData(BtCursor*, u32 offset, u32 amt, void*);
SQLITE_PRIVATE void sqlite3BtreeCacheOverflow(BtCursor *);
SQLITE_PRIVATE void sqlite3BtreeClearCursor(BtCursor *);
-
SQLITE_PRIVATE int sqlite3BtreeSetVersion(Btree *pBt, int iVersion);
+SQLITE_PRIVATE void sqlite3BtreeCursorHints(BtCursor *, unsigned int mask);
#ifndef NDEBUG
SQLITE_PRIVATE int sqlite3BtreeCursorIsValid(BtCursor*);
@@ -8153,6 +8649,7 @@ SQLITE_PRIVATE int sqlite3SchemaMutexHeld(sqlite3*,int,Schema*);
*/
#ifndef _SQLITE_VDBE_H_
#define _SQLITE_VDBE_H_
+/* #include <stdio.h> */
/*
** A single VDBE is an opaque structure named "Vdbe". Only routines
@@ -8196,6 +8693,7 @@ struct VdbeOp {
KeyInfo *pKeyInfo; /* Used when p4type is P4_KEYINFO */
int *ai; /* Used when p4type is P4_INTARRAY */
SubProgram *pProgram; /* Used when p4type is P4_SUBPROGRAM */
+ int (*xAdvance)(BtCursor *, int *);
} p4;
#ifdef SQLITE_DEBUG
char *zComment; /* Comment to improve readability */
@@ -8216,6 +8714,7 @@ struct SubProgram {
int nOp; /* Elements in aOp[] */
int nMem; /* Number of memory cells required */
int nCsr; /* Number of cursors required */
+ int nOnce; /* Number of OP_Once instructions */
void *token; /* id that may be used to recursive triggers */
SubProgram *pNext; /* Next sub-program already visited */
};
@@ -8251,6 +8750,7 @@ typedef struct VdbeOpList VdbeOpList;
#define P4_INT32 (-14) /* P4 is a 32-bit signed integer */
#define P4_INTARRAY (-15) /* P4 is a vector of 32-bit integers */
#define P4_SUBPROGRAM (-18) /* P4 is a pointer to a SubProgram structure */
+#define P4_ADVANCE (-19) /* P4 is a pointer to BtreeNext() or BtreePrev() */
/* When adding a P4 argument using P4_KEYINFO, a copy of the KeyInfo structure
** is made. That copy is freed when the Vdbe is finalized. But if the
@@ -8348,102 +8848,105 @@ typedef struct VdbeOpList VdbeOpList;
#define OP_Or 68 /* same as TK_OR */
#define OP_Not 19 /* same as TK_NOT */
#define OP_BitNot 93 /* same as TK_BITNOT */
-#define OP_If 26
-#define OP_IfNot 27
+#define OP_Once 26
+#define OP_If 27
+#define OP_IfNot 28
#define OP_IsNull 73 /* same as TK_ISNULL */
#define OP_NotNull 74 /* same as TK_NOTNULL */
-#define OP_Column 28
-#define OP_Affinity 29
-#define OP_MakeRecord 30
-#define OP_Count 31
-#define OP_Savepoint 32
-#define OP_AutoCommit 33
-#define OP_Transaction 34
-#define OP_ReadCookie 35
-#define OP_SetCookie 36
-#define OP_VerifyCookie 37
-#define OP_OpenRead 38
-#define OP_OpenWrite 39
-#define OP_OpenAutoindex 40
-#define OP_OpenEphemeral 41
-#define OP_OpenPseudo 42
-#define OP_Close 43
-#define OP_SeekLt 44
-#define OP_SeekLe 45
-#define OP_SeekGe 46
-#define OP_SeekGt 47
-#define OP_Seek 48
-#define OP_NotFound 49
-#define OP_Found 50
-#define OP_IsUnique 51
-#define OP_NotExists 52
-#define OP_Sequence 53
-#define OP_NewRowid 54
-#define OP_Insert 55
-#define OP_InsertInt 56
-#define OP_Delete 57
-#define OP_ResetCount 58
-#define OP_RowKey 59
-#define OP_RowData 60
-#define OP_Rowid 61
-#define OP_NullRow 62
-#define OP_Last 63
-#define OP_Sort 64
-#define OP_Rewind 65
-#define OP_Prev 66
-#define OP_Next 67
-#define OP_IdxInsert 70
-#define OP_IdxDelete 71
-#define OP_IdxRowid 72
-#define OP_IdxLT 81
-#define OP_IdxGE 92
-#define OP_Destroy 95
-#define OP_Clear 96
-#define OP_CreateIndex 97
-#define OP_CreateTable 98
-#define OP_ParseSchema 99
-#define OP_LoadAnalysis 100
-#define OP_DropTable 101
-#define OP_DropIndex 102
-#define OP_DropTrigger 103
-#define OP_IntegrityCk 104
-#define OP_RowSetAdd 105
-#define OP_RowSetRead 106
-#define OP_RowSetTest 107
-#define OP_Program 108
-#define OP_Param 109
-#define OP_FkCounter 110
-#define OP_FkIfZero 111
-#define OP_MemMax 112
-#define OP_IfPos 113
-#define OP_IfNeg 114
-#define OP_IfZero 115
-#define OP_AggStep 116
-#define OP_AggFinal 117
-#define OP_Checkpoint 118
-#define OP_JournalMode 119
-#define OP_Vacuum 120
-#define OP_IncrVacuum 121
-#define OP_Expire 122
-#define OP_TableLock 123
-#define OP_VBegin 124
-#define OP_VCreate 125
-#define OP_VDestroy 126
-#define OP_VOpen 127
-#define OP_VFilter 128
-#define OP_VColumn 129
-#define OP_VNext 131
-#define OP_VRename 132
-#define OP_VUpdate 133
-#define OP_Pagecount 134
-#define OP_MaxPgcnt 135
-#define OP_Trace 136
-#define OP_Noop 137
-#define OP_Explain 138
-
-/* The following opcode values are never used */
-#define OP_NotUsed_139 139
-#define OP_NotUsed_140 140
+#define OP_Column 29
+#define OP_Affinity 30
+#define OP_MakeRecord 31
+#define OP_Count 32
+#define OP_Savepoint 33
+#define OP_AutoCommit 34
+#define OP_Transaction 35
+#define OP_ReadCookie 36
+#define OP_SetCookie 37
+#define OP_VerifyCookie 38
+#define OP_OpenRead 39
+#define OP_OpenWrite 40
+#define OP_OpenAutoindex 41
+#define OP_OpenEphemeral 42
+#define OP_SorterOpen 43
+#define OP_OpenPseudo 44
+#define OP_Close 45
+#define OP_SeekLt 46
+#define OP_SeekLe 47
+#define OP_SeekGe 48
+#define OP_SeekGt 49
+#define OP_Seek 50
+#define OP_NotFound 51
+#define OP_Found 52
+#define OP_IsUnique 53
+#define OP_NotExists 54
+#define OP_Sequence 55
+#define OP_NewRowid 56
+#define OP_Insert 57
+#define OP_InsertInt 58
+#define OP_Delete 59
+#define OP_ResetCount 60
+#define OP_SorterCompare 61
+#define OP_SorterData 62
+#define OP_RowKey 63
+#define OP_RowData 64
+#define OP_Rowid 65
+#define OP_NullRow 66
+#define OP_Last 67
+#define OP_SorterSort 70
+#define OP_Sort 71
+#define OP_Rewind 72
+#define OP_SorterNext 81
+#define OP_Prev 92
+#define OP_Next 95
+#define OP_SorterInsert 96
+#define OP_IdxInsert 97
+#define OP_IdxDelete 98
+#define OP_IdxRowid 99
+#define OP_IdxLT 100
+#define OP_IdxGE 101
+#define OP_Destroy 102
+#define OP_Clear 103
+#define OP_CreateIndex 104
+#define OP_CreateTable 105
+#define OP_ParseSchema 106
+#define OP_LoadAnalysis 107
+#define OP_DropTable 108
+#define OP_DropIndex 109
+#define OP_DropTrigger 110
+#define OP_IntegrityCk 111
+#define OP_RowSetAdd 112
+#define OP_RowSetRead 113
+#define OP_RowSetTest 114
+#define OP_Program 115
+#define OP_Param 116
+#define OP_FkCounter 117
+#define OP_FkIfZero 118
+#define OP_MemMax 119
+#define OP_IfPos 120
+#define OP_IfNeg 121
+#define OP_IfZero 122
+#define OP_AggStep 123
+#define OP_AggFinal 124
+#define OP_Checkpoint 125
+#define OP_JournalMode 126
+#define OP_Vacuum 127
+#define OP_IncrVacuum 128
+#define OP_Expire 129
+#define OP_TableLock 131
+#define OP_VBegin 132
+#define OP_VCreate 133
+#define OP_VDestroy 134
+#define OP_VOpen 135
+#define OP_VFilter 136
+#define OP_VColumn 137
+#define OP_VNext 138
+#define OP_VRename 139
+#define OP_VUpdate 140
+#define OP_Pagecount 146
+#define OP_MaxPgcnt 147
+#define OP_Trace 148
+#define OP_Noop 149
+#define OP_Explain 150
/* Properties such as "out2" or "jump" that are specified in
@@ -8458,25 +8961,25 @@ typedef struct VdbeOpList VdbeOpList;
#define OPFLG_OUT2 0x0020 /* out2: P2 is an output */
#define OPFLG_OUT3 0x0040 /* out3: P3 is an output */
#define OPFLG_INITIALIZER {\
-/* 0 */ 0x00, 0x01, 0x05, 0x04, 0x04, 0x10, 0x00, 0x02,\
-/* 8 */ 0x02, 0x02, 0x02, 0x02, 0x02, 0x00, 0x24, 0x24,\
+/* 0 */ 0x00, 0x01, 0x01, 0x04, 0x04, 0x10, 0x00, 0x02,\
+/* 8 */ 0x02, 0x02, 0x02, 0x02, 0x02, 0x00, 0x00, 0x24,\
/* 16 */ 0x00, 0x00, 0x00, 0x24, 0x04, 0x05, 0x04, 0x00,\
-/* 24 */ 0x00, 0x01, 0x05, 0x05, 0x00, 0x00, 0x00, 0x02,\
-/* 32 */ 0x00, 0x00, 0x00, 0x02, 0x10, 0x00, 0x00, 0x00,\
-/* 40 */ 0x00, 0x00, 0x00, 0x00, 0x11, 0x11, 0x11, 0x11,\
-/* 48 */ 0x08, 0x11, 0x11, 0x11, 0x11, 0x02, 0x02, 0x00,\
-/* 56 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x01,\
-/* 64 */ 0x01, 0x01, 0x01, 0x01, 0x4c, 0x4c, 0x08, 0x00,\
-/* 72 */ 0x02, 0x05, 0x05, 0x15, 0x15, 0x15, 0x15, 0x15,\
+/* 24 */ 0x00, 0x01, 0x01, 0x05, 0x05, 0x00, 0x00, 0x00,\
+/* 32 */ 0x02, 0x00, 0x00, 0x00, 0x02, 0x10, 0x00, 0x00,\
+/* 40 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x11,\
+/* 48 */ 0x11, 0x11, 0x08, 0x11, 0x11, 0x11, 0x11, 0x02,\
+/* 56 */ 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,\
+/* 64 */ 0x00, 0x02, 0x00, 0x01, 0x4c, 0x4c, 0x01, 0x01,\
+/* 72 */ 0x01, 0x05, 0x05, 0x15, 0x15, 0x15, 0x15, 0x15,\
/* 80 */ 0x15, 0x01, 0x4c, 0x4c, 0x4c, 0x4c, 0x4c, 0x4c,\
-/* 88 */ 0x4c, 0x4c, 0x4c, 0x4c, 0x01, 0x24, 0x02, 0x02,\
-/* 96 */ 0x00, 0x02, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00,\
-/* 104 */ 0x00, 0x0c, 0x45, 0x15, 0x01, 0x02, 0x00, 0x01,\
-/* 112 */ 0x08, 0x05, 0x05, 0x05, 0x00, 0x00, 0x00, 0x02,\
-/* 120 */ 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,\
-/* 128 */ 0x01, 0x00, 0x02, 0x01, 0x00, 0x00, 0x02, 0x02,\
-/* 136 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x04, 0x04,\
-/* 144 */ 0x04, 0x04,}
+/* 88 */ 0x4c, 0x4c, 0x4c, 0x4c, 0x01, 0x24, 0x02, 0x01,\
+/* 96 */ 0x08, 0x08, 0x00, 0x02, 0x01, 0x01, 0x02, 0x00,\
+/* 104 */ 0x02, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,\
+/* 112 */ 0x0c, 0x45, 0x15, 0x01, 0x02, 0x00, 0x01, 0x08,\
+/* 120 */ 0x05, 0x05, 0x05, 0x00, 0x00, 0x00, 0x02, 0x00,\
+/* 128 */ 0x01, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00,\
+/* 136 */ 0x01, 0x00, 0x01, 0x00, 0x00, 0x04, 0x04, 0x04,\
+/* 144 */ 0x04, 0x04, 0x02, 0x02, 0x00, 0x00, 0x00,}
/************** End of opcodes.h *********************************************/
/************** Continuing where we left off in vdbe.h ***********************/
@@ -8494,19 +8997,19 @@ SQLITE_PRIVATE int sqlite3VdbeAddOp4(Vdbe*,int,int,int,int,const char *zP4,int);
SQLITE_PRIVATE int sqlite3VdbeAddOp4Int(Vdbe*,int,int,int,int,int);
SQLITE_PRIVATE int sqlite3VdbeAddOpList(Vdbe*, int nOp, VdbeOpList const *aOp);
SQLITE_PRIVATE void sqlite3VdbeAddParseSchemaOp(Vdbe*,int,char*);
-SQLITE_PRIVATE void sqlite3VdbeChangeP1(Vdbe*, int addr, int P1);
-SQLITE_PRIVATE void sqlite3VdbeChangeP2(Vdbe*, int addr, int P2);
-SQLITE_PRIVATE void sqlite3VdbeChangeP3(Vdbe*, int addr, int P3);
+SQLITE_PRIVATE void sqlite3VdbeChangeP1(Vdbe*, u32 addr, int P1);
+SQLITE_PRIVATE void sqlite3VdbeChangeP2(Vdbe*, u32 addr, int P2);
+SQLITE_PRIVATE void sqlite3VdbeChangeP3(Vdbe*, u32 addr, int P3);
SQLITE_PRIVATE void sqlite3VdbeChangeP5(Vdbe*, u8 P5);
SQLITE_PRIVATE void sqlite3VdbeJumpHere(Vdbe*, int addr);
-SQLITE_PRIVATE void sqlite3VdbeChangeToNoop(Vdbe*, int addr, int N);
+SQLITE_PRIVATE void sqlite3VdbeChangeToNoop(Vdbe*, int addr);
SQLITE_PRIVATE void sqlite3VdbeChangeP4(Vdbe*, int addr, const char *zP4, int N);
SQLITE_PRIVATE void sqlite3VdbeUsesBtree(Vdbe*, int);
SQLITE_PRIVATE VdbeOp *sqlite3VdbeGetOp(Vdbe*, int);
SQLITE_PRIVATE int sqlite3VdbeMakeLabel(Vdbe*);
SQLITE_PRIVATE void sqlite3VdbeRunOnlyOnce(Vdbe*);
SQLITE_PRIVATE void sqlite3VdbeDelete(Vdbe*);
-SQLITE_PRIVATE void sqlite3VdbeDeleteObject(sqlite3*,Vdbe*);
+SQLITE_PRIVATE void sqlite3VdbeClearObject(sqlite3*,Vdbe*);
SQLITE_PRIVATE void sqlite3VdbeMakeReady(Vdbe*,Parse*);
SQLITE_PRIVATE int sqlite3VdbeFinalize(Vdbe*);
SQLITE_PRIVATE void sqlite3VdbeResolveLabel(Vdbe*, int);
@@ -8531,9 +9034,9 @@ SQLITE_PRIVATE void sqlite3VdbeSetVarmask(Vdbe*, int);
SQLITE_PRIVATE char *sqlite3VdbeExpandSql(Vdbe*, const char*);
#endif
-SQLITE_PRIVATE UnpackedRecord *sqlite3VdbeRecordUnpack(KeyInfo*,int,const void*,char*,int);
-SQLITE_PRIVATE void sqlite3VdbeDeleteUnpackedRecord(UnpackedRecord*);
+SQLITE_PRIVATE void sqlite3VdbeRecordUnpack(KeyInfo*,int,const void*,UnpackedRecord*);
SQLITE_PRIVATE int sqlite3VdbeRecordCompare(int,const void*,UnpackedRecord*);
+SQLITE_PRIVATE UnpackedRecord *sqlite3VdbeAllocUnpackedRecord(KeyInfo *, char *, int, char **);
#ifndef SQLITE_OMIT_TRIGGER
SQLITE_PRIVATE void sqlite3VdbeLinkSubProgram(Vdbe *, SubProgram *);
@@ -8616,8 +9119,7 @@ typedef struct PgHdr DbPage;
** NOTE: These values must match the corresponding BTREE_ values in btree.h.
*/
#define PAGER_OMIT_JOURNAL 0x0001 /* Do not use a rollback journal */
-#define PAGER_NO_READLOCK 0x0002 /* Omit readlocks on readonly files */
-#define PAGER_MEMORY 0x0004 /* In-memory database */
+#define PAGER_MEMORY 0x0002 /* In-memory database */
/*
** Valid values for the second argument to sqlite3PagerLockingMode().
@@ -8661,6 +9163,7 @@ SQLITE_PRIVATE void sqlite3PagerSetBusyhandler(Pager*, int(*)(void *), void *);
SQLITE_PRIVATE int sqlite3PagerSetPagesize(Pager*, u32*, int);
SQLITE_PRIVATE int sqlite3PagerMaxPageCount(Pager*, int);
SQLITE_PRIVATE void sqlite3PagerSetCachesize(Pager*, int);
+SQLITE_PRIVATE void sqlite3PagerShrink(Pager*);
SQLITE_PRIVATE void sqlite3PagerSetSafetyLevel(Pager*,int,int,int);
SQLITE_PRIVATE int sqlite3PagerLockingMode(Pager *, int);
SQLITE_PRIVATE int sqlite3PagerSetJournalMode(Pager *, int);
@@ -8696,23 +9199,32 @@ SQLITE_PRIVATE int sqlite3PagerOpenSavepoint(Pager *pPager, int n);
SQLITE_PRIVATE int sqlite3PagerSavepoint(Pager *pPager, int op, int iSavepoint);
SQLITE_PRIVATE int sqlite3PagerSharedLock(Pager *pPager);
-SQLITE_PRIVATE int sqlite3PagerCheckpoint(Pager *pPager, int, int*, int*);
-SQLITE_PRIVATE int sqlite3PagerWalSupported(Pager *pPager);
-SQLITE_PRIVATE int sqlite3PagerWalCallback(Pager *pPager);
-SQLITE_PRIVATE int sqlite3PagerOpenWal(Pager *pPager, int *pisOpen);
-SQLITE_PRIVATE int sqlite3PagerCloseWal(Pager *pPager);
+#ifndef SQLITE_OMIT_WAL
+SQLITE_PRIVATE int sqlite3PagerCheckpoint(Pager *pPager, int, int*, int*);
+SQLITE_PRIVATE int sqlite3PagerWalSupported(Pager *pPager);
+SQLITE_PRIVATE int sqlite3PagerWalCallback(Pager *pPager);
+SQLITE_PRIVATE int sqlite3PagerOpenWal(Pager *pPager, int *pisOpen);
+SQLITE_PRIVATE int sqlite3PagerCloseWal(Pager *pPager);
+#endif
+
+#ifdef SQLITE_ENABLE_ZIPVFS
+SQLITE_PRIVATE int sqlite3PagerWalFramesize(Pager *pPager);
+#endif
/* Functions used to query pager state and configuration. */
SQLITE_PRIVATE u8 sqlite3PagerIsreadonly(Pager*);
SQLITE_PRIVATE int sqlite3PagerRefcount(Pager*);
SQLITE_PRIVATE int sqlite3PagerMemUsed(Pager*);
-SQLITE_PRIVATE const char *sqlite3PagerFilename(Pager*);
+SQLITE_PRIVATE const char *sqlite3PagerFilename(Pager*, int);
SQLITE_PRIVATE const sqlite3_vfs *sqlite3PagerVfs(Pager*);
SQLITE_PRIVATE sqlite3_file *sqlite3PagerFile(Pager*);
SQLITE_PRIVATE const char *sqlite3PagerJournalname(Pager*);
SQLITE_PRIVATE int sqlite3PagerNosync(Pager*);
SQLITE_PRIVATE void *sqlite3PagerTempSpace(Pager*);
SQLITE_PRIVATE int sqlite3PagerIsMemdb(Pager*);
+SQLITE_PRIVATE void sqlite3PagerCacheStat(Pager *, int, int, int *);
+SQLITE_PRIVATE void sqlite3PagerClearCache(Pager *);
+SQLITE_PRIVATE int sqlite3SectorSize(sqlite3_file *);
/* Functions used to truncate the database file. */
SQLITE_PRIVATE void sqlite3PagerTruncateImage(Pager*,Pgno);
@@ -8767,11 +9279,12 @@ typedef struct PCache PCache;
** structure.
*/
struct PgHdr {
- void *pData; /* Content of this page */
+ sqlite3_pcache_page *pPage; /* Pcache object page handle */
+ void *pData; /* Page data */
void *pExtra; /* Extra content */
PgHdr *pDirty; /* Transient list of dirty pages */
- Pgno pgno; /* Page number for this page */
Pager *pPager; /* The pager this page is part of */
+ Pgno pgno; /* Page number for this page */
#ifdef SQLITE_CHECK_PAGES
u32 pageHash; /* Hash of page content */
#endif
@@ -8885,6 +9398,9 @@ SQLITE_PRIVATE void sqlite3PcacheSetCachesize(PCache *, int);
SQLITE_PRIVATE int sqlite3PcacheGetCachesize(PCache *);
#endif
+/* Free up as much memory as possible from the page cache */
+SQLITE_PRIVATE void sqlite3PcacheShrink(PCache*);
+
#ifdef SQLITE_ENABLE_MEMORY_MANAGEMENT
/* Try to return memory used by the pcache module to the main memory heap */
SQLITE_PRIVATE int sqlite3PcacheReleaseMemory(int);
@@ -8928,7 +9444,7 @@ SQLITE_PRIVATE void sqlite3PCacheSetDefault(void);
/*
** Figure out if we are dealing with Unix, Windows, or some other
** operating system. After the following block of preprocess macros,
-** all of SQLITE_OS_UNIX, SQLITE_OS_WIN, SQLITE_OS_OS2, and SQLITE_OS_OTHER
+** all of SQLITE_OS_UNIX, SQLITE_OS_WIN, and SQLITE_OS_OTHER
** will defined to either 1 or 0. One of the four will be 1. The other
** three will be 0.
*/
@@ -8938,8 +9454,6 @@ SQLITE_PRIVATE void sqlite3PCacheSetDefault(void);
# define SQLITE_OS_UNIX 0
# undef SQLITE_OS_WIN
# define SQLITE_OS_WIN 0
-# undef SQLITE_OS_OS2
-# define SQLITE_OS_OS2 0
# else
# undef SQLITE_OS_OTHER
# endif
@@ -8950,19 +9464,12 @@ SQLITE_PRIVATE void sqlite3PCacheSetDefault(void);
# if defined(_WIN32) || defined(WIN32) || defined(__CYGWIN__) || defined(__MINGW32__) || defined(__BORLANDC__)
# define SQLITE_OS_WIN 1
# define SQLITE_OS_UNIX 0
-# define SQLITE_OS_OS2 0
-# elif defined(__EMX__) || defined(_OS2) || defined(OS2) || defined(_OS2_) || defined(__OS2__)
-# define SQLITE_OS_WIN 0
-# define SQLITE_OS_UNIX 0
-# define SQLITE_OS_OS2 1
# else
# define SQLITE_OS_WIN 0
# define SQLITE_OS_UNIX 1
-# define SQLITE_OS_OS2 0
# endif
# else
# define SQLITE_OS_UNIX 0
-# define SQLITE_OS_OS2 0
# endif
#else
# ifndef SQLITE_OS_WIN
@@ -8970,6 +9477,31 @@ SQLITE_PRIVATE void sqlite3PCacheSetDefault(void);
# endif
#endif
+#if SQLITE_OS_WIN
+# include <windows.h>
+#endif
+
+/*
+** Determine if we are dealing with Windows NT.
+**
+** We ought to be able to determine if we are compiling for win98 or winNT
+** using the _WIN32_WINNT macro as follows:
+**
+** #if defined(_WIN32_WINNT)
+** # define SQLITE_OS_WINNT 1
+** #else
+** # define SQLITE_OS_WINNT 0
+** #endif
+**
+** However, vs2005 does not set _WIN32_WINNT by default, as it ought to,
+** so the above test does not work. We'll just assume that everything is
+** winNT unless the programmer explicitly says otherwise by setting
+** SQLITE_OS_WINNT to 0.
+*/
+#if SQLITE_OS_WIN && !defined(SQLITE_OS_WINNT)
+# define SQLITE_OS_WINNT 1
+#endif
+
/*
** Determine if we are dealing with WindowsCE - which has a much
** reduced API.
@@ -8980,29 +9512,20 @@ SQLITE_PRIVATE void sqlite3PCacheSetDefault(void);
# define SQLITE_OS_WINCE 0
#endif
-
/*
-** Define the maximum size of a temporary filename
+** Determine if we are dealing with WinRT, which provides only a subset of
+** the full Win32 API.
*/
-#if SQLITE_OS_WIN
-# include <windows.h>
-# define SQLITE_TEMPNAME_SIZE (MAX_PATH+50)
-#elif SQLITE_OS_OS2
-# if (__GNUC__ > 3 || __GNUC__ == 3 && __GNUC_MINOR__ >= 3) && defined(OS2_HIGH_MEMORY)
-# include <os2safe.h> /* has to be included before os2.h for linking to work */
-# endif
-# define INCL_DOSDATETIME
-# define INCL_DOSFILEMGR
-# define INCL_DOSERRORS
-# define INCL_DOSMISC
-# define INCL_DOSPROCESS
-# define INCL_DOSMODULEMGR
-# define INCL_DOSSEMAPHORES
-# include <os2.h>
-# include <uconv.h>
-# define SQLITE_TEMPNAME_SIZE (CCHMAXPATHCOMP)
-#else
-# define SQLITE_TEMPNAME_SIZE 200
+#if !defined(SQLITE_OS_WINRT)
+# define SQLITE_OS_WINRT 0
+#endif
+
+/*
+** When compiled for WinCE or WinRT, there is no concept of the current
+** directory.
+ */
+#if !SQLITE_OS_WINCE && !SQLITE_OS_WINRT
+# define SQLITE_CURDIR 1
#endif
/* If the SET_FULLSYNC macro is not defined above, then make it
@@ -9016,7 +9539,7 @@ SQLITE_PRIVATE void sqlite3PCacheSetDefault(void);
** The default size of a disk sector
*/
#ifndef SQLITE_DEFAULT_SECTOR_SIZE
-# define SQLITE_DEFAULT_SECTOR_SIZE 512
+# define SQLITE_DEFAULT_SECTOR_SIZE 4096
#endif
/*
@@ -9149,6 +9672,7 @@ SQLITE_PRIVATE int sqlite3OsLock(sqlite3_file*, int);
SQLITE_PRIVATE int sqlite3OsUnlock(sqlite3_file*, int);
SQLITE_PRIVATE int sqlite3OsCheckReservedLock(sqlite3_file *id, int *pResOut);
SQLITE_PRIVATE int sqlite3OsFileControl(sqlite3_file*,int,void*);
+SQLITE_PRIVATE void sqlite3OsFileControlHint(sqlite3_file*,int,void*);
#define SQLITE_FCNTL_DB_UNCHANGED 0xca093fa0
SQLITE_PRIVATE int sqlite3OsSectorSize(sqlite3_file *id);
SQLITE_PRIVATE int sqlite3OsDeviceCharacteristics(sqlite3_file *id);
@@ -9157,6 +9681,7 @@ SQLITE_PRIVATE int sqlite3OsShmLock(sqlite3_file *id, int, int, int);
SQLITE_PRIVATE void sqlite3OsShmBarrier(sqlite3_file *id);
SQLITE_PRIVATE int sqlite3OsShmUnmap(sqlite3_file *id, int);
+
/*
** Functions for accessing sqlite3_vfs methods
*/
@@ -9225,8 +9750,6 @@ SQLITE_PRIVATE int sqlite3OsCloseFree(sqlite3_file *);
** SQLITE_MUTEX_PTHREADS For multi-threaded applications on Unix.
**
** SQLITE_MUTEX_W32 For multi-threaded applications on Win32.
-**
-** SQLITE_MUTEX_OS2 For multi-threaded applications on OS/2.
*/
#if !SQLITE_THREADSAFE
# define SQLITE_MUTEX_OMIT
@@ -9236,8 +9759,6 @@ SQLITE_PRIVATE int sqlite3OsCloseFree(sqlite3_file *);
# define SQLITE_MUTEX_PTHREADS
# elif SQLITE_OS_WIN
# define SQLITE_MUTEX_W32
-# elif SQLITE_OS_OS2
-# define SQLITE_MUTEX_OS2
# else
# define SQLITE_MUTEX_NOOP
# endif
@@ -9249,14 +9770,17 @@ SQLITE_PRIVATE int sqlite3OsCloseFree(sqlite3_file *);
*/
#define sqlite3_mutex_alloc(X) ((sqlite3_mutex*)8)
#define sqlite3_mutex_free(X)
-#define sqlite3_mutex_enter(X)
+#define sqlite3_mutex_enter(X)
#define sqlite3_mutex_try(X) SQLITE_OK
-#define sqlite3_mutex_leave(X)
+#define sqlite3_mutex_leave(X)
#define sqlite3_mutex_held(X) ((void)(X),1)
#define sqlite3_mutex_notheld(X) ((void)(X),1)
#define sqlite3MutexAlloc(X) ((sqlite3_mutex*)8)
#define sqlite3MutexInit() SQLITE_OK
#define sqlite3MutexEnd()
+#define MUTEX_LOGIC(X)
+#else
+#define MUTEX_LOGIC(X) X
#endif /* defined(SQLITE_MUTEX_OMIT) */
/************** End of mutex.h ***********************************************/
@@ -9385,38 +9909,20 @@ struct FuncDefHash {
/*
** Each database connection is an instance of the following structure.
-**
-** The sqlite.lastRowid records the last insert rowid generated by an
-** insert statement. Inserts on views do not affect its value. Each
-** trigger has its own context, so that lastRowid can be updated inside
-** triggers as usual. The previous value will be restored once the trigger
-** exits. Upon entering a before or instead of trigger, lastRowid is no
-** longer (since after version 2.8.12) reset to -1.
-**
-** The sqlite.nChange does not count changes within triggers and keeps no
-** context. It is reset at start of sqlite3_exec.
-** The sqlite.lsChange represents the number of changes made by the last
-** insert, update, or delete statement. It remains constant throughout the
-** length of a statement and is then updated by OP_SetCounts. It keeps a
-** context stack just like lastRowid so that the count of changes
-** within a trigger is not seen outside the trigger. Changes to views do not
-** affect the value of lsChange.
-** The sqlite.csChange keeps track of the number of current changes (since
-** the last statement) and is used to update sqlite_lsChange.
-**
-** The member variables sqlite.errCode, sqlite.zErrMsg and sqlite.zErrMsg16
-** store the most recent error code and, if applicable, string. The
-** internal function sqlite3Error() is used to set these variables
-** consistently.
*/
struct sqlite3 {
sqlite3_vfs *pVfs; /* OS Interface */
- int nDb; /* Number of backends currently in use */
+ struct Vdbe *pVdbe; /* List of active virtual machines */
+ CollSeq *pDfltColl; /* The default collating sequence (BINARY) */
+ sqlite3_mutex *mutex; /* Connection mutex */
Db *aDb; /* All backends */
+ int nDb; /* Number of backends currently in use */
int flags; /* Miscellaneous flags. See below */
+ i64 lastRowid; /* ROWID of most recent insert (see above) */
unsigned int openFlags; /* Flags passed to sqlite3_vfs.xOpen() */
int errCode; /* Most recent error code (SQLITE_*) */
int errMask; /* & result codes with this before returning */
+ u16 dbOptFlags; /* Flags to enable/disable optimizations */
u8 autoCommit; /* The auto-commit flag. */
u8 temp_store; /* 1: file 2: memory 0: default */
u8 mallocFailed; /* True if we have seen a malloc failure */
@@ -9424,27 +9930,23 @@ struct sqlite3 {
signed char nextAutovac; /* Autovac setting after VACUUM if >=0 */
u8 suppressErr; /* Do not issue error messages if true */
u8 vtabOnConflict; /* Value to return for s3_vtab_on_conflict() */
+ u8 isTransactionSavepoint; /* True if the outermost savepoint is a TS */
int nextPagesize; /* Pagesize after VACUUM if >0 */
- int nTable; /* Number of tables in the database */
- CollSeq *pDfltColl; /* The default collating sequence (BINARY) */
- i64 lastRowid; /* ROWID of most recent insert (see above) */
u32 magic; /* Magic number for detect library misuse */
int nChange; /* Value returned by sqlite3_changes() */
int nTotalChange; /* Value returned by sqlite3_total_changes() */
- sqlite3_mutex *mutex; /* Connection mutex */
int aLimit[SQLITE_N_LIMIT]; /* Limits */
struct sqlite3InitInfo { /* Information used during initialization */
- int iDb; /* When back is being initialized */
int newTnum; /* Rootpage of table being initialized */
+ u8 iDb; /* Which db file is being initialized */
u8 busy; /* TRUE if currently initializing */
u8 orphanTrigger; /* Last statement is orphaned TEMP trigger */
} init;
- int nExtension; /* Number of loaded extensions */
- void **aExtension; /* Array of shared library handles */
- struct Vdbe *pVdbe; /* List of active virtual machines */
int activeVdbeCnt; /* Number of VDBEs currently executing */
int writeVdbeCnt; /* Number of active VDBEs that are writing */
int vdbeExecCnt; /* Number of nested calls to VdbeExec() */
+ int nExtension; /* Number of loaded extensions */
+ void **aExtension; /* Array of shared library handles */
void (*xTrace)(void*,const char*); /* Trace function */
void *pTraceArg; /* Argument to the trace function */
void (*xProfile)(void*,const char*,u64); /* Profiling function */
@@ -9481,21 +9983,20 @@ struct sqlite3 {
int nProgressOps; /* Number of opcodes for progress callback */
#endif
#ifndef SQLITE_OMIT_VIRTUALTABLE
+ int nVTrans; /* Allocated size of aVTrans */
Hash aModule; /* populated by sqlite3_create_module() */
VtabCtx *pVtabCtx; /* Context for active vtab connect/create */
VTable **aVTrans; /* Virtual tables with open transactions */
- int nVTrans; /* Allocated size of aVTrans */
VTable *pDisconnect; /* Disconnect these in next sqlite3_prepare() */
#endif
FuncDefHash aFunc; /* Hash table of connection functions */
Hash aCollSeq; /* All collating sequences */
BusyHandler busyHandler; /* Busy callback */
- int busyTimeout; /* Busy handler timeout, in msec */
Db aDbStatic[2]; /* Static space for the 2 default backends */
Savepoint *pSavepoint; /* List of active savepoints */
+ int busyTimeout; /* Busy handler timeout, in msec */
int nSavepoint; /* Number of non-transaction savepoints */
int nStatement; /* Number of nested statement-transactions */
- u8 isTransactionSavepoint; /* True if the outermost savepoint is a TS */
i64 nDeferredCons; /* Net deferred constraints this transaction. */
int *pnBytesFreed; /* If not NULL, increment this in DbFree() */
@@ -9526,48 +10027,60 @@ struct sqlite3 {
/*
** Possible values for the sqlite3.flags.
*/
-#define SQLITE_VdbeTrace 0x00000100 /* True to trace VDBE execution */
-#define SQLITE_InternChanges 0x00000200 /* Uncommitted Hash table changes */
-#define SQLITE_FullColNames 0x00000400 /* Show full column names on SELECT */
-#define SQLITE_ShortColNames 0x00000800 /* Show short columns names */
-#define SQLITE_CountRows 0x00001000 /* Count rows changed by INSERT, */
+#define SQLITE_VdbeTrace 0x00000001 /* True to trace VDBE execution */
+#define SQLITE_InternChanges 0x00000002 /* Uncommitted Hash table changes */
+#define SQLITE_FullColNames 0x00000004 /* Show full column names on SELECT */
+#define SQLITE_ShortColNames 0x00000008 /* Show short columns names */
+#define SQLITE_CountRows 0x00000010 /* Count rows changed by INSERT, */
/* DELETE, or UPDATE and return */
/* the count using a callback. */
-#define SQLITE_NullCallback 0x00002000 /* Invoke the callback once if the */
+#define SQLITE_NullCallback 0x00000020 /* Invoke the callback once if the */
/* result set is empty */
-#define SQLITE_SqlTrace 0x00004000 /* Debug print SQL as it executes */
-#define SQLITE_VdbeListing 0x00008000 /* Debug listings of VDBE programs */
-#define SQLITE_WriteSchema 0x00010000 /* OK to update SQLITE_MASTER */
-#define SQLITE_NoReadlock 0x00020000 /* Readlocks are omitted when
- ** accessing read-only databases */
-#define SQLITE_IgnoreChecks 0x00040000 /* Do not enforce check constraints */
-#define SQLITE_ReadUncommitted 0x0080000 /* For shared-cache mode */
-#define SQLITE_LegacyFileFmt 0x00100000 /* Create new databases in format 1 */
-#define SQLITE_FullFSync 0x00200000 /* Use full fsync on the backend */
-#define SQLITE_CkptFullFSync 0x00400000 /* Use full fsync for checkpoint */
-#define SQLITE_RecoveryMode 0x00800000 /* Ignore schema errors */
-#define SQLITE_ReverseOrder 0x01000000 /* Reverse unordered SELECTs */
-#define SQLITE_RecTriggers 0x02000000 /* Enable recursive triggers */
-#define SQLITE_ForeignKeys 0x04000000 /* Enforce foreign key constraints */
-#define SQLITE_AutoIndex 0x08000000 /* Enable automatic indexes */
-#define SQLITE_PreferBuiltin 0x10000000 /* Preference to built-in funcs */
-#define SQLITE_LoadExtension 0x20000000 /* Enable load_extension */
-#define SQLITE_EnableTrigger 0x40000000 /* True to enable triggers */
-
-/*
-** Bits of the sqlite3.flags field that are used by the
-** sqlite3_test_control(SQLITE_TESTCTRL_OPTIMIZATIONS,...) interface.
-** These must be the low-order bits of the flags field.
-*/
-#define SQLITE_QueryFlattener 0x01 /* Disable query flattening */
-#define SQLITE_ColumnCache 0x02 /* Disable the column cache */
-#define SQLITE_IndexSort 0x04 /* Disable indexes for sorting */
-#define SQLITE_IndexSearch 0x08 /* Disable indexes for searching */
-#define SQLITE_IndexCover 0x10 /* Disable index covering table */
-#define SQLITE_GroupByOrder 0x20 /* Disable GROUPBY cover of ORDERBY */
-#define SQLITE_FactorOutConst 0x40 /* Disable factoring out constants */
-#define SQLITE_IdxRealAsInt 0x80 /* Store REAL as INT in indices */
-#define SQLITE_OptMask 0xff /* Mask of all disablable opts */
+#define SQLITE_SqlTrace 0x00000040 /* Debug print SQL as it executes */
+#define SQLITE_VdbeListing 0x00000080 /* Debug listings of VDBE programs */
+#define SQLITE_WriteSchema 0x00000100 /* OK to update SQLITE_MASTER */
+#define SQLITE_VdbeAddopTrace 0x00000200 /* Trace sqlite3VdbeAddOp() calls */
+#define SQLITE_IgnoreChecks 0x00000400 /* Do not enforce check constraints */
+#define SQLITE_ReadUncommitted 0x0000800 /* For shared-cache mode */
+#define SQLITE_LegacyFileFmt 0x00001000 /* Create new databases in format 1 */
+#define SQLITE_FullFSync 0x00002000 /* Use full fsync on the backend */
+#define SQLITE_CkptFullFSync 0x00004000 /* Use full fsync for checkpoint */
+#define SQLITE_RecoveryMode 0x00008000 /* Ignore schema errors */
+#define SQLITE_ReverseOrder 0x00010000 /* Reverse unordered SELECTs */
+#define SQLITE_RecTriggers 0x00020000 /* Enable recursive triggers */
+#define SQLITE_ForeignKeys 0x00040000 /* Enforce foreign key constraints */
+#define SQLITE_AutoIndex 0x00080000 /* Enable automatic indexes */
+#define SQLITE_PreferBuiltin 0x00100000 /* Preference to built-in funcs */
+#define SQLITE_LoadExtension 0x00200000 /* Enable load_extension */
+#define SQLITE_EnableTrigger 0x00400000 /* True to enable triggers */
+
+/*
+** Bits of the sqlite3.dbOptFlags field that are used by the
+** sqlite3_test_control(SQLITE_TESTCTRL_OPTIMIZATIONS,...) interface to
+** selectively disable various optimizations.
+*/
+#define SQLITE_QueryFlattener 0x0001 /* Query flattening */
+#define SQLITE_ColumnCache 0x0002 /* Column cache */
+#define SQLITE_GroupByOrder 0x0004 /* GROUPBY cover of ORDERBY */
+#define SQLITE_FactorOutConst 0x0008 /* Constant factoring */
+#define SQLITE_IdxRealAsInt 0x0010 /* Store REAL as INT in indices */
+#define SQLITE_DistinctOpt 0x0020 /* DISTINCT using indexes */
+#define SQLITE_CoverIdxScan 0x0040 /* Covering index scans */
+#define SQLITE_OrderByIdxJoin 0x0080 /* ORDER BY of joins via index */
+#define SQLITE_SubqCoroutine 0x0100 /* Evaluate subqueries as coroutines */
+#define SQLITE_Transitive 0x0200 /* Transitive constraints */
+#define SQLITE_AllOpts 0xffff /* All optimizations */
+
+/*
+** Macros for testing whether or not optimizations are enabled or disabled.
+*/
+#ifndef SQLITE_OMIT_BUILTIN_TEST
+#define OptimizationDisabled(db, mask) (((db)->dbOptFlags&(mask))!=0)
+#define OptimizationEnabled(db, mask) (((db)->dbOptFlags&(mask))==0)
+#else
+#define OptimizationDisabled(db, mask) 0
+#define OptimizationEnabled(db, mask) 1
+#endif
/*
** Possible values for the sqlite.magic field.
@@ -9579,6 +10092,7 @@ struct sqlite3 {
#define SQLITE_MAGIC_SICK 0x4b771290 /* Error and awaiting close */
#define SQLITE_MAGIC_BUSY 0xf03b7906 /* Database currently in use */
#define SQLITE_MAGIC_ERROR 0xb5357930 /* An SQLITE_MISUSE error occurred */
+#define SQLITE_MAGIC_ZOMBIE 0x64cffc7f /* Close with last statement close */
/*
** Each SQL function is defined by an instance of the following
@@ -9621,15 +10135,18 @@ struct FuncDestructor {
};
/*
-** Possible values for FuncDef.flags
+** Possible values for FuncDef.flags. Note that the _LENGTH and _TYPEOF
+** values must correspond to OPFLAG_LENGTHARG and OPFLAG_TYPEOFARG. There
+** are assert() statements in the code to verify this.
*/
#define SQLITE_FUNC_LIKE 0x01 /* Candidate for the LIKE optimization */
#define SQLITE_FUNC_CASE 0x02 /* Case-sensitive LIKE-type function */
#define SQLITE_FUNC_EPHEM 0x04 /* Ephemeral. Delete with VDBE */
#define SQLITE_FUNC_NEEDCOLL 0x08 /* sqlite3GetFuncCollSeq() might be called */
-#define SQLITE_FUNC_PRIVATE 0x10 /* Allowed for internal use only */
-#define SQLITE_FUNC_COUNT 0x20 /* Built-in count(*) aggregate */
-#define SQLITE_FUNC_COALESCE 0x40 /* Built-in coalesce() or ifnull() function */
+#define SQLITE_FUNC_COUNT 0x10 /* Built-in count(*) aggregate */
+#define SQLITE_FUNC_COALESCE 0x20 /* Built-in coalesce() or ifnull() function */
+#define SQLITE_FUNC_LENGTH 0x40 /* Built-in length() function */
+#define SQLITE_FUNC_TYPEOF 0x80 /* Built-in typeof() function */
/*
** The following three macros, FUNCTION(), LIKEFUNC() and AGGREGATE() are
@@ -9657,7 +10174,10 @@ struct FuncDestructor {
** parameter.
*/
#define FUNCTION(zName, nArg, iArg, bNC, xFunc) \
- {nArg, SQLITE_UTF8, bNC*SQLITE_FUNC_NEEDCOLL, \
+ {nArg, SQLITE_UTF8, (bNC*SQLITE_FUNC_NEEDCOLL), \
+ SQLITE_INT_TO_PTR(iArg), 0, xFunc, 0, 0, #zName, 0, 0}
+#define FUNCTION2(zName, nArg, iArg, bNC, xFunc, extraFlags) \
+ {nArg, SQLITE_UTF8, (bNC*SQLITE_FUNC_NEEDCOLL)|extraFlags, \
SQLITE_INT_TO_PTR(iArg), 0, xFunc, 0, 0, #zName, 0, 0}
#define STR_FUNCTION(zName, nArg, pArg, bNC, xFunc) \
{nArg, SQLITE_UTF8, bNC*SQLITE_FUNC_NEEDCOLL, \
@@ -9711,53 +10231,34 @@ struct Column {
char *zDflt; /* Original text of the default value */
char *zType; /* Data type for this column */
char *zColl; /* Collating sequence. If NULL, use the default */
- u8 notNull; /* True if there is a NOT NULL constraint */
- u8 isPrimKey; /* True if this column is part of the PRIMARY KEY */
+ u8 notNull; /* An OE_ code for handling a NOT NULL constraint */
char affinity; /* One of the SQLITE_AFF_... values */
-#ifndef SQLITE_OMIT_VIRTUALTABLE
- u8 isHidden; /* True if this column is 'hidden' */
-#endif
+ u16 colFlags; /* Boolean properties. See COLFLAG_ defines below */
};
+/* Allowed values for Column.colFlags:
+*/
+#define COLFLAG_PRIMKEY 0x0001 /* Column is part of the primary key */
+#define COLFLAG_HIDDEN 0x0002 /* A hidden column in a virtual table */
+
/*
** A "Collating Sequence" is defined by an instance of the following
** structure. Conceptually, a collating sequence consists of a name and
** a comparison routine that defines the order of that sequence.
**
-** There may two separate implementations of the collation function, one
-** that processes text in UTF-8 encoding (CollSeq.xCmp) and another that
-** processes text encoded in UTF-16 (CollSeq.xCmp16), using the machine
-** native byte order. When a collation sequence is invoked, SQLite selects
-** the version that will require the least expensive encoding
-** translations, if any.
-**
-** The CollSeq.pUser member variable is an extra parameter that passed in
-** as the first argument to the UTF-8 comparison function, xCmp.
-** CollSeq.pUser16 is the equivalent for the UTF-16 comparison function,
-** xCmp16.
-**
-** If both CollSeq.xCmp and CollSeq.xCmp16 are NULL, it means that the
+** If CollSeq.xCmp is NULL, it means that the
** collating sequence is undefined. Indices built on an undefined
** collating sequence may not be read or written.
*/
struct CollSeq {
char *zName; /* Name of the collating sequence, UTF-8 encoded */
u8 enc; /* Text encoding handled by xCmp() */
- u8 type; /* One of the SQLITE_COLL_... values below */
void *pUser; /* First argument to xCmp() */
int (*xCmp)(void*,int, const void*, int, const void*);
void (*xDel)(void*); /* Destructor for pUser */
};
/*
-** Allowed values of CollSeq.type:
-*/
-#define SQLITE_COLL_BINARY 1 /* The default memcmp() collating sequence */
-#define SQLITE_COLL_NOCASE 2 /* The built-in NOCASE collating sequence */
-#define SQLITE_COLL_REVERSE 3 /* The built-in REVERSE collating sequence */
-#define SQLITE_COLL_USER 0 /* Any other user-defined collating sequence */
-
-/*
** A sort order can be either ASC or DESC.
*/
#define SQLITE_SO_ASC 0 /* Sort in ascending order */
@@ -9883,28 +10384,28 @@ struct VTable {
*/
struct Table {
char *zName; /* Name of the table or view */
- int iPKey; /* If not negative, use aCol[iPKey] as the primary key */
- int nCol; /* Number of columns in this table */
Column *aCol; /* Information about each column */
Index *pIndex; /* List of SQL indexes on this table. */
- int tnum; /* Root BTree node for this table (see note above) */
- unsigned nRowEst; /* Estimated rows in table - from sqlite_stat1 table */
Select *pSelect; /* NULL for tables. Points to definition if a view. */
- u16 nRef; /* Number of pointers to this Table */
- u8 tabFlags; /* Mask of TF_* values */
- u8 keyConf; /* What to do in case of uniqueness conflict on iPKey */
FKey *pFKey; /* Linked list of all foreign keys in this table */
char *zColAff; /* String defining the affinity of each column */
#ifndef SQLITE_OMIT_CHECK
- Expr *pCheck; /* The AND of all CHECK constraints */
+ ExprList *pCheck; /* All CHECK constraints */
#endif
+ tRowcnt nRowEst; /* Estimated rows in table - from sqlite_stat1 table */
+ int tnum; /* Root BTree node for this table (see note above) */
+ i16 iPKey; /* If not negative, use aCol[iPKey] as the primary key */
+ i16 nCol; /* Number of columns in this table */
+ u16 nRef; /* Number of pointers to this Table */
+ u8 tabFlags; /* Mask of TF_* values */
+ u8 keyConf; /* What to do in case of uniqueness conflict on iPKey */
#ifndef SQLITE_OMIT_ALTERTABLE
int addColOffset; /* Offset in CREATE TABLE stmt to add a new column */
#endif
#ifndef SQLITE_OMIT_VIRTUALTABLE
- VTable *pVTable; /* List of VTable objects. */
int nModuleArg; /* Number of arguments to the module */
char **azModuleArg; /* Text of all module args. [0] is module name */
+ VTable *pVTable; /* List of VTable objects. */
#endif
Trigger *pTrigger; /* List of triggers stored in pSchema */
Schema *pSchema; /* Schema that contains this table */
@@ -9919,8 +10420,6 @@ struct Table {
#define TF_HasPrimaryKey 0x04 /* Table has a primary key */
#define TF_Autoincrement 0x08 /* Integer primary key is autoincrement */
#define TF_Virtual 0x10 /* Is a virtual table */
-#define TF_NeedMetadata 0x20 /* aCol[].zType and aCol[].pColl missing */
-
/*
@@ -9930,7 +10429,7 @@ struct Table {
*/
#ifndef SQLITE_OMIT_VIRTUALTABLE
# define IsVirtual(X) (((X)->tabFlags & TF_Virtual)!=0)
-# define IsHiddenColumn(X) ((X)->isHidden)
+# define IsHiddenColumn(X) (((X)->colFlags & COLFLAG_HIDDEN)!=0)
#else
# define IsVirtual(X) 0
# define IsHiddenColumn(X) 0
@@ -10042,7 +10541,7 @@ struct KeyInfo {
struct UnpackedRecord {
KeyInfo *pKeyInfo; /* Collation and sort-order information */
u16 nField; /* Number of entries in apMem[] */
- u16 flags; /* Boolean settings. UNPACKED_... below */
+ u8 flags; /* Boolean settings. UNPACKED_... below */
i64 rowid; /* Used by UNPACKED_PREFIX_SEARCH */
Mem *aMem; /* Values */
};
@@ -10050,12 +10549,9 @@ struct UnpackedRecord {
/*
** Allowed values of UnpackedRecord.flags
*/
-#define UNPACKED_NEED_FREE 0x0001 /* Memory is from sqlite3Malloc() */
-#define UNPACKED_NEED_DESTROY 0x0002 /* apMem[]s should all be destroyed */
-#define UNPACKED_IGNORE_ROWID 0x0004 /* Ignore trailing rowid on key1 */
-#define UNPACKED_INCRKEY 0x0008 /* Make this key an epsilon larger */
-#define UNPACKED_PREFIX_MATCH 0x0010 /* A prefix match is considered OK */
-#define UNPACKED_PREFIX_SEARCH 0x0020 /* A prefix match is considered OK */
+#define UNPACKED_INCRKEY 0x01 /* Make this key an epsilon larger */
+#define UNPACKED_PREFIX_MATCH 0x02 /* A prefix match is considered OK */
+#define UNPACKED_PREFIX_SEARCH 0x04 /* Ignore final (rowid) field */
/*
** Each SQL index is represented in memory by an
@@ -10084,34 +10580,43 @@ struct UnpackedRecord {
** element.
*/
struct Index {
- char *zName; /* Name of this index */
- int nColumn; /* Number of columns in the table used by this index */
- int *aiColumn; /* Which columns are used by this index. 1st is 0 */
- unsigned *aiRowEst; /* Result of ANALYZE: Est. rows selected by each column */
- Table *pTable; /* The SQL table being indexed */
- int tnum; /* Page containing root of this index in database file */
- u8 onError; /* OE_Abort, OE_Ignore, OE_Replace, or OE_None */
- u8 autoIndex; /* True if is automatically created (ex: by UNIQUE) */
- u8 bUnordered; /* Use this index for == or IN queries only */
- char *zColAff; /* String defining the affinity of each column */
- Index *pNext; /* The next index associated with the same table */
- Schema *pSchema; /* Schema containing this index */
- u8 *aSortOrder; /* Array of size Index.nColumn. True==DESC, False==ASC */
- char **azColl; /* Array of collation sequence names for index */
- IndexSample *aSample; /* Array of SQLITE_INDEX_SAMPLES samples */
+ char *zName; /* Name of this index */
+ int *aiColumn; /* Which columns are used by this index. 1st is 0 */
+ tRowcnt *aiRowEst; /* From ANALYZE: Est. rows selected by each column */
+ Table *pTable; /* The SQL table being indexed */
+ char *zColAff; /* String defining the affinity of each column */
+ Index *pNext; /* The next index associated with the same table */
+ Schema *pSchema; /* Schema containing this index */
+ u8 *aSortOrder; /* for each column: True==DESC, False==ASC */
+ char **azColl; /* Array of collation sequence names for index */
+ int tnum; /* DB Page containing root of this index */
+ u16 nColumn; /* Number of columns in table used by this index */
+ u8 onError; /* OE_Abort, OE_Ignore, OE_Replace, or OE_None */
+ unsigned autoIndex:2; /* 1==UNIQUE, 2==PRIMARY KEY, 0==CREATE INDEX */
+ unsigned bUnordered:1; /* Use this index for == or IN queries only */
+#ifdef SQLITE_ENABLE_STAT3
+ int nSample; /* Number of elements in aSample[] */
+ tRowcnt avgEq; /* Average nEq value for key values not in aSample */
+ IndexSample *aSample; /* Samples of the left-most key */
+#endif
};
/*
-** Each sample stored in the sqlite_stat2 table is represented in memory
-** using a structure of this type.
+** Each sample stored in the sqlite_stat3 table is represented in memory
+** using a structure of this type. See documentation at the top of the
+** analyze.c source file for additional information.
*/
struct IndexSample {
union {
char *z; /* Value if eType is SQLITE_TEXT or SQLITE_BLOB */
- double r; /* Value if eType is SQLITE_FLOAT or SQLITE_INTEGER */
+ double r; /* Value if eType is SQLITE_FLOAT */
+ i64 i; /* Value if eType is SQLITE_INTEGER */
} u;
u8 eType; /* SQLITE_NULL, SQLITE_INTEGER ... etc. */
- u8 nByte; /* Size in byte of text or blob. */
+ int nByte; /* Size in byte of text or blob. */
+ tRowcnt nEq; /* Est. number of rows where the key equals this sample */
+ tRowcnt nLt; /* Est. number of rows where key is less than this sample */
+ tRowcnt nDLt; /* Est. number of distinct keys less than this sample */
};
/*
@@ -10146,8 +10651,9 @@ struct AggInfo {
u8 useSortingIdx; /* In direct mode, reference the sorting index rather
** than the source table */
int sortingIdx; /* Cursor number of the sorting index */
- ExprList *pGroupBy; /* The group by clause */
+ int sortingIdxPTab; /* Cursor number of pseudo-table */
int nSortingColumn; /* Number of columns in the sorting index */
+ ExprList *pGroupBy; /* The group by clause */
struct AggInfo_col { /* For each column used in source tables */
Table *pTab; /* Source table */
int iTable; /* Cursor number of the source table */
@@ -10157,7 +10663,6 @@ struct AggInfo {
Expr *pExpr; /* The original expression */
} *aCol;
int nColumn; /* Number of used entries in aCol[] */
- int nColumnAlloc; /* Number of slots allocated for aCol[] */
int nAccumulator; /* Number of columns that show through to the output.
** Additional columns are used only as parameters to
** aggregate functions */
@@ -10168,7 +10673,6 @@ struct AggInfo {
int iDistinct; /* Ephemeral table used to enforce DISTINCT */
} *aFunc;
int nFunc; /* Number of entries in aFunc[] */
- int nFuncAlloc; /* Number of slots allocated for aFunc[] */
};
/*
@@ -10270,13 +10774,15 @@ struct Expr {
ExprList *pList; /* Function arguments or in "<expr> IN (<expr-list)" */
Select *pSelect; /* Used for sub-selects and "<expr> IN (<select>)" */
} x;
- CollSeq *pColl; /* The collation type of the column or 0 */
/* If the EP_Reduced flag is set in the Expr.flags mask, then no
** space is allocated for the fields below this point. An attempt to
** access them will result in a segfault or malfunction.
*********************************************************************/
+#if SQLITE_MAX_EXPR_DEPTH>0
+ int nHeight; /* Height of the tree headed by this node */
+#endif
int iTable; /* TK_COLUMN: cursor number of table holding column
** TK_REGISTER: register number
** TK_TRIGGER: 1 -> new, 0 -> old */
@@ -10285,12 +10791,11 @@ struct Expr {
i16 iAgg; /* Which entry in pAggInfo->aCol[] or ->aFunc[] */
i16 iRightJoinTable; /* If EP_FromJoin, the right table of the join */
u8 flags2; /* Second set of flags. EP2_... */
- u8 op2; /* If a TK_REGISTER, the original value of Expr.op */
+ u8 op2; /* TK_REGISTER: original value of Expr.op
+ ** TK_COLUMN: the value of p5 for OP_Column
+ ** TK_AGG_FUNCTION: nesting depth */
AggInfo *pAggInfo; /* Used by TK_AGG_COLUMN and TK_AGG_FUNCTION */
Table *pTab; /* Table for TK_COLUMN expressions. */
-#if SQLITE_MAX_EXPR_DEPTH>0
- int nHeight; /* Height of the tree headed by this node */
-#endif
};
/*
@@ -10304,14 +10809,14 @@ struct Expr {
#define EP_VarSelect 0x0020 /* pSelect is correlated, not constant */
#define EP_DblQuoted 0x0040 /* token.z was originally in "..." */
#define EP_InfixFunc 0x0080 /* True for an infix function: LIKE, GLOB, etc */
-#define EP_ExpCollate 0x0100 /* Collating sequence specified explicitly */
+#define EP_Collate 0x0100 /* Tree contains a TK_COLLATE opeartor */
#define EP_FixedDest 0x0200 /* Result needed in a specific register */
#define EP_IntValue 0x0400 /* Integer value contained in u.iValue */
#define EP_xIsSelect 0x0800 /* x.pSelect is valid (otherwise x.pList is) */
-
-#define EP_Reduced 0x1000 /* Expr struct is EXPR_REDUCEDSIZE bytes only */
-#define EP_TokenOnly 0x2000 /* Expr struct is EXPR_TOKENONLYSIZE bytes only */
-#define EP_Static 0x4000 /* Held in memory not obtained from malloc() */
+#define EP_Hint 0x1000 /* Not used */
+#define EP_Reduced 0x2000 /* Expr struct is EXPR_REDUCEDSIZE bytes only */
+#define EP_TokenOnly 0x4000 /* Expr struct is EXPR_TOKENONLYSIZE bytes only */
+#define EP_Static 0x8000 /* Held in memory not obtained from malloc() */
/*
** The following are the meanings of bits in the Expr.flags2 field.
@@ -10362,20 +10867,28 @@ struct Expr {
** list of "ID = expr" items in an UPDATE. A list of expressions can
** also be used as the argument to a function, in which case the a.zName
** field is not used.
+**
+** By default the Expr.zSpan field holds a human-readable description of
+** the expression that is used in the generation of error messages and
+** column labels. In this case, Expr.zSpan is typically the text of a
+** column expression as it exists in a SELECT statement. However, if
+** the bSpanIsTab flag is set, then zSpan is overloaded to mean the name
+** of the result column in the form: DATABASE.TABLE.COLUMN. This later
+** form is used for name resolution with nested FROM clauses.
*/
struct ExprList {
int nExpr; /* Number of expressions on the list */
- int nAlloc; /* Number of entries allocated below */
int iECursor; /* VDBE Cursor associated with this ExprList */
- struct ExprList_item {
- Expr *pExpr; /* The list of expressions */
- char *zName; /* Token associated with this expression */
- char *zSpan; /* Original text of the expression */
- u8 sortOrder; /* 1 for DESC or 0 for ASC */
- u8 done; /* A flag to indicate when processing is finished */
- u16 iCol; /* For ORDER BY, column number in result set */
- u16 iAlias; /* Index into Parse.aAlias[] for zName */
- } *a; /* One entry for each expression */
+ struct ExprList_item { /* For each expression in the list */
+ Expr *pExpr; /* The list of expressions */
+ char *zName; /* Token associated with this expression */
+ char *zSpan; /* Original text of the expression */
+ u8 sortOrder; /* 1 for DESC or 0 for ASC */
+ unsigned done :1; /* A flag to indicate when processing is finished */
+ unsigned bSpanIsTab :1; /* zSpan holds DB.TABLE.COLUMN */
+ u16 iOrderByCol; /* For ORDER BY, column number in result set */
+ u16 iAlias; /* Index into Parse.aAlias[] for zName */
+ } *a; /* Alloc a power of two greater or equal to nExpr */
};
/*
@@ -10410,7 +10923,6 @@ struct IdList {
int idx; /* Index in some Table.aCol[] of a column named zName */
} *a;
int nId; /* Number of identifiers on the list */
- int nAlloc; /* Number of entries allocated for a[] below */
};
/*
@@ -10450,14 +10962,18 @@ struct SrcList {
i16 nSrc; /* Number of tables or subqueries in the FROM clause */
i16 nAlloc; /* Number of entries allocated in a[] below */
struct SrcList_item {
+ Schema *pSchema; /* Schema to which this item is fixed */
char *zDatabase; /* Name of database holding this table */
char *zName; /* Name of the table */
char *zAlias; /* The "B" part of a "A AS B" phrase. zName is the "A" */
Table *pTab; /* An SQL table corresponding to zName */
Select *pSelect; /* A SELECT statement used in place of a table name */
- u8 isPopulated; /* Temporary table associated with SELECT is populated */
+ int addrFillSub; /* Address of subroutine to manifest a subquery */
+ int regReturn; /* Register holding return address of addrFillSub */
u8 jointype; /* Type of join between this able and the previous */
- u8 notIndexed; /* True if there is a NOT INDEXED clause */
+ unsigned notIndexed :1; /* True if there is a NOT INDEXED clause */
+ unsigned isCorrelated :1; /* True if sub-query is correlated */
+ unsigned viaCoroutine :1; /* Implemented as a co-routine */
#ifndef SQLITE_OMIT_EXPLAIN
u8 iSelectId; /* If pSelect!=0, the id of the sub-select in EQP */
#endif
@@ -10498,7 +11014,8 @@ struct SrcList {
*/
struct WherePlan {
u32 wsFlags; /* WHERE_* flags that describe the strategy */
- u32 nEq; /* Number of == constraints */
+ u16 nEq; /* Number of == constraints */
+ u16 nOBSat; /* Number of ORDER BY terms satisfied */
double nRow; /* Estimated number of rows (for EQP) */
union {
Index *pIdx; /* Index when WHERE_INDEXED is true */
@@ -10510,7 +11027,7 @@ struct WherePlan {
/*
** For each nested loop in a WHERE clause implementation, the WhereInfo
** structure contains a single instance of this structure. This structure
-** is intended to be private the the where.c module and should not be
+** is intended to be private to the where.c module and should not be
** access or modified by other modules.
**
** The pIdxInfo field is used to help pick the best index on a
@@ -10538,9 +11055,12 @@ struct WhereLevel {
struct InLoop {
int iCur; /* The VDBE cursor used by this IN operator */
int addrInTop; /* Top of the IN loop */
+ u8 eEndLoopOp; /* IN Loop terminator. OP_Next or OP_Prev */
} *aInLoop; /* Information about each nested IN operator */
} in; /* Used when plan.wsFlags&WHERE_IN_ABLE */
+ Index *pCovidx; /* Possible covering index for WHERE_MULTI_OR */
} u;
+ double rOptCost; /* "Optimal" cost for this level */
/* The following field is really not part of the current level. But
** we need a place to cache virtual table index information for each
@@ -10560,10 +11080,10 @@ struct WhereLevel {
#define WHERE_ORDERBY_MAX 0x0002 /* ORDER BY processing for max() func */
#define WHERE_ONEPASS_DESIRED 0x0004 /* Want to do one-pass UPDATE/DELETE */
#define WHERE_DUPLICATES_OK 0x0008 /* Ok to return a row more than once */
-#define WHERE_OMIT_OPEN 0x0010 /* Table cursors are already open */
-#define WHERE_OMIT_CLOSE 0x0020 /* Omit close of table & index cursors */
-#define WHERE_FORCE_TABLE 0x0040 /* Do not use an index-only search */
-#define WHERE_ONETABLE_ONLY 0x0080 /* Only code the 1st table in pTabList */
+#define WHERE_OMIT_OPEN_CLOSE 0x0010 /* Table cursors are already open */
+#define WHERE_FORCE_TABLE 0x0020 /* Do not use an index-only search */
+#define WHERE_ONETABLE_ONLY 0x0040 /* Only code the 1st table in pTabList */
+#define WHERE_AND_ONLY 0x0080 /* Don't use indices for OR terms */
/*
** The WHERE clause processing routine has two halves. The
@@ -10573,21 +11093,29 @@ struct WhereLevel {
** into the second half to give some continuity.
*/
struct WhereInfo {
- Parse *pParse; /* Parsing and code generating context */
- u16 wctrlFlags; /* Flags originally passed to sqlite3WhereBegin() */
- u8 okOnePass; /* Ok to use one-pass algorithm for UPDATE or DELETE */
- u8 untestedTerms; /* Not all WHERE terms resolved by outer loop */
- SrcList *pTabList; /* List of tables in the join */
- int iTop; /* The very beginning of the WHERE loop */
- int iContinue; /* Jump here to continue with next record */
- int iBreak; /* Jump here to break out of the loop */
- int nLevel; /* Number of nested loop */
- struct WhereClause *pWC; /* Decomposition of the WHERE clause */
- double savedNQueryLoop; /* pParse->nQueryLoop outside the WHERE loop */
- double nRowOut; /* Estimated number of output rows */
- WhereLevel a[1]; /* Information about each nest loop in WHERE */
+ Parse *pParse; /* Parsing and code generating context */
+ SrcList *pTabList; /* List of tables in the join */
+ u16 nOBSat; /* Number of ORDER BY terms satisfied by indices */
+ u16 wctrlFlags; /* Flags originally passed to sqlite3WhereBegin() */
+ u8 okOnePass; /* Ok to use one-pass algorithm for UPDATE/DELETE */
+ u8 untestedTerms; /* Not all WHERE terms resolved by outer loop */
+ u8 eDistinct; /* One of the WHERE_DISTINCT_* values below */
+ int iTop; /* The very beginning of the WHERE loop */
+ int iContinue; /* Jump here to continue with next record */
+ int iBreak; /* Jump here to break out of the loop */
+ int nLevel; /* Number of nested loop */
+ struct WhereClause *pWC; /* Decomposition of the WHERE clause */
+ double savedNQueryLoop; /* pParse->nQueryLoop outside the WHERE loop */
+ double nRowOut; /* Estimated number of output rows */
+ WhereLevel a[1]; /* Information about each nest loop in WHERE */
};
+/* Allowed values for WhereInfo.eDistinct and DistinctCtx.eTnctType */
+#define WHERE_DISTINCT_NOOP 0 /* DISTINCT keyword not used */
+#define WHERE_DISTINCT_UNIQUE 1 /* No duplicates */
+#define WHERE_DISTINCT_ORDERED 2 /* All duplicates are adjacent */
+#define WHERE_DISTINCT_UNORDERED 3 /* Duplicates are scattered */
+
/*
** A NameContext defines a context in which to resolve table and column
** names. The context consists of a list of tables (the pSrcList) field and
@@ -10613,17 +11141,22 @@ struct NameContext {
Parse *pParse; /* The parser */
SrcList *pSrcList; /* One or more tables used to resolve names */
ExprList *pEList; /* Optional list of named expressions */
- int nRef; /* Number of names resolved by this context */
- int nErr; /* Number of errors encountered while resolving names */
- u8 allowAgg; /* Aggregate functions allowed here */
- u8 hasAgg; /* True if aggregates are seen */
- u8 isCheck; /* True if resolving names in a CHECK constraint */
- int nDepth; /* Depth of subquery recursion. 1 for no recursion */
AggInfo *pAggInfo; /* Information about aggregates at this level */
NameContext *pNext; /* Next outer name context. NULL for outermost */
+ int nRef; /* Number of names resolved by this context */
+ int nErr; /* Number of errors encountered while resolving names */
+ u8 ncFlags; /* Zero or more NC_* flags defined below */
};
/*
+** Allowed values for the NameContext, ncFlags field.
+*/
+#define NC_AllowAgg 0x01 /* Aggregate functions are allowed here */
+#define NC_HasAgg 0x02 /* One or more aggregate functions seen */
+#define NC_IsCheck 0x04 /* True if resolving names in a CHECK constraint */
+#define NC_InAggFunc 0x08 /* True if analyzing arguments to an agg func */
+
+/*
** An instance of the following structure contains all information
** needed to generate code for a single SELECT statement.
**
@@ -10640,14 +11173,16 @@ struct NameContext {
** as the OP_OpenEphm instruction is coded because not
** enough information about the compound query is known at that point.
** The KeyInfo for addrOpenTran[0] and [1] contains collating sequences
-** for the result set. The KeyInfo for addrOpenTran[2] contains collating
+** for the result set. The KeyInfo for addrOpenEphm[2] contains collating
** sequences for the ORDER BY clause.
*/
struct Select {
ExprList *pEList; /* The fields of the result */
u8 op; /* One of: TK_UNION TK_ALL TK_INTERSECT TK_EXCEPT */
- char affinity; /* MakeRecord with this affinity for SRT_Set */
u16 selFlags; /* Various SF_* values */
+ int iLimit, iOffset; /* Memory registers holding LIMIT & OFFSET counters */
+ int addrOpenEphm[3]; /* OP_OpenEphem opcodes related to this select */
+ double nSelectRow; /* Estimated number of result rows */
SrcList *pSrc; /* The FROM clause */
Expr *pWhere; /* The WHERE clause */
ExprList *pGroupBy; /* The GROUP BY clause */
@@ -10658,9 +11193,6 @@ struct Select {
Select *pRightmost; /* Right-most select in a compound select statement */
Expr *pLimit; /* LIMIT expression. NULL means not used. */
Expr *pOffset; /* OFFSET expression. NULL means not used. */
- int iLimit, iOffset; /* Memory registers holding LIMIT & OFFSET counters */
- int addrOpenEphm[3]; /* OP_OpenEphem opcodes related to this select */
- double nSelectRow; /* Estimated number of result rows */
};
/*
@@ -10673,6 +11205,10 @@ struct Select {
#define SF_UsesEphemeral 0x0008 /* Uses the OpenEphemeral opcode */
#define SF_Expanded 0x0010 /* sqlite3SelectExpand() called on this */
#define SF_HasTypeInfo 0x0020 /* FROM subqueries have Table metadata */
+#define SF_UseSorter 0x0040 /* Sort using a sorter */
+#define SF_Values 0x0080 /* Synthesized from VALUES clause */
+#define SF_Materialize 0x0100 /* Force materialization of views */
+#define SF_NestedFrom 0x0200 /* Part of a parenthesized FROM clause */
/*
@@ -10695,16 +11231,15 @@ struct Select {
#define SRT_Coroutine 10 /* Generate a single row of result */
/*
-** A structure used to customize the behavior of sqlite3Select(). See
-** comments above sqlite3Select() for details.
+** An instance of this object describes where to put of the results of
+** a SELECT statement.
*/
-typedef struct SelectDest SelectDest;
struct SelectDest {
- u8 eDest; /* How to dispose of the results */
- u8 affinity; /* Affinity used when eDest==SRT_Set */
- int iParm; /* A parameter used by the eDest disposal method */
- int iMem; /* Base register where results are written */
- int nMem; /* Number of registers allocated */
+ u8 eDest; /* How to dispose of the results. On of SRT_* above. */
+ char affSdst; /* Affinity used when eDest==SRT_Set */
+ int iSDParm; /* A parameter used by the eDest disposal method */
+ int iSdst; /* Base register where results are written */
+ int nSdst; /* Number of registers allocated */
};
/*
@@ -10750,10 +11285,10 @@ struct AutoincInfo {
*/
struct TriggerPrg {
Trigger *pTrigger; /* Trigger this program was coded from */
- int orconf; /* Default ON CONFLICT policy */
+ TriggerPrg *pNext; /* Next entry in Parse.pTriggerPrg list */
SubProgram *pProgram; /* Program implementing pTrigger/orconf */
+ int orconf; /* Default ON CONFLICT policy */
u32 aColmask[2]; /* Masks of old.*, new.* columns accessed */
- TriggerPrg *pNext; /* Next entry in Parse.pTriggerPrg list */
};
/*
@@ -10783,16 +11318,18 @@ struct TriggerPrg {
*/
struct Parse {
sqlite3 *db; /* The main database structure */
- int rc; /* Return code from execution */
char *zErrMsg; /* An error message */
Vdbe *pVdbe; /* An engine for executing database bytecode */
+ int rc; /* Return code from execution */
u8 colNamesSet; /* TRUE after OP_ColumnName has been issued to pVdbe */
- u8 nameClash; /* A permanent table name clashes with temp table name */
u8 checkSchema; /* Causes schema cookie check after an error */
u8 nested; /* Number of nested calls to the parser/code generator */
- u8 parseError; /* True after a parsing error. Ticket #1794 */
u8 nTempReg; /* Number of temporary registers in aTempReg[] */
u8 nTempInUse; /* Number of aTempReg[] currently checked out */
+ u8 nColCache; /* Number of entries in aColCache[] */
+ u8 iColCache; /* Next entry in aColCache[] to replace */
+ u8 isMultiWrite; /* True if statement may modify/insert multiple rows */
+ u8 mayAbort; /* True if statement may throw an ABORT exception */
int aTempReg[8]; /* Holding area for temporary registers */
int nRangeReg; /* Size of the temporary register block */
int iRangeReg; /* First register in temporary register block */
@@ -10800,11 +11337,10 @@ struct Parse {
int nTab; /* Number of previously allocated VDBE cursors */
int nMem; /* Number of memory cells used so far */
int nSet; /* Number of sets used so far */
+ int nOnce; /* Number of OP_Once instructions so far */
int ckBase; /* Base register of data during check constraints */
int iCacheLevel; /* ColCache valid when aColCache[].iLevel<=iCacheLevel */
int iCacheCnt; /* Counter used to generate aColCache[].lru values */
- u8 nColCache; /* Number of entries in the column cache */
- u8 iColCache; /* Next entry of the cache to replace */
struct yColCache {
int iTable; /* Table cursor number */
int iColumn; /* Table column number */
@@ -10815,62 +11351,64 @@ struct Parse {
} aColCache[SQLITE_N_COLCACHE]; /* One for each column cache entry */
yDbMask writeMask; /* Start a write transaction on these databases */
yDbMask cookieMask; /* Bitmask of schema verified databases */
- u8 isMultiWrite; /* True if statement may affect/insert multiple rows */
- u8 mayAbort; /* True if statement may throw an ABORT exception */
int cookieGoto; /* Address of OP_Goto to cookie verifier subroutine */
int cookieValue[SQLITE_MAX_ATTACHED+2]; /* Values of cookies to verify */
+ int regRowid; /* Register holding rowid of CREATE TABLE entry */
+ int regRoot; /* Register holding root page number for new objects */
+ int nMaxArg; /* Max args passed to user function by sub-program */
+ Token constraintName;/* Name of the constraint currently being parsed */
#ifndef SQLITE_OMIT_SHARED_CACHE
int nTableLock; /* Number of locks in aTableLock */
TableLock *aTableLock; /* Required table locks for shared-cache mode */
#endif
- int regRowid; /* Register holding rowid of CREATE TABLE entry */
- int regRoot; /* Register holding root page number for new objects */
AutoincInfo *pAinc; /* Information about AUTOINCREMENT counters */
- int nMaxArg; /* Max args passed to user function by sub-program */
/* Information used while coding trigger programs. */
Parse *pToplevel; /* Parse structure for main program (or NULL) */
Table *pTriggerTab; /* Table triggers are being coded for */
+ double nQueryLoop; /* Estimated number of iterations of a query */
u32 oldmask; /* Mask of old.* columns referenced */
u32 newmask; /* Mask of new.* columns referenced */
u8 eTriggerOp; /* TK_UPDATE, TK_INSERT or TK_DELETE */
u8 eOrconf; /* Default ON CONFLICT policy for trigger steps */
u8 disableTriggers; /* True to disable triggers */
- double nQueryLoop; /* Estimated number of iterations of a query */
/* Above is constant between recursions. Below is reset before and after
** each recursion */
- int nVar; /* Number of '?' variables seen in the SQL so far */
- int nzVar; /* Number of available slots in azVar[] */
- char **azVar; /* Pointers to names of parameters */
- Vdbe *pReprepare; /* VM being reprepared (sqlite3Reprepare()) */
- int nAlias; /* Number of aliased result set columns */
- int nAliasAlloc; /* Number of allocated slots for aAlias[] */
- int *aAlias; /* Register used to hold aliased result */
- u8 explain; /* True if the EXPLAIN flag is found on the query */
- Token sNameToken; /* Token with unqualified schema object name */
- Token sLastToken; /* The last token parsed */
- const char *zTail; /* All SQL text past the last semicolon parsed */
- Table *pNewTable; /* A table being constructed by CREATE TABLE */
- Trigger *pNewTrigger; /* Trigger under construct by a CREATE TRIGGER */
- const char *zAuthContext; /* The 6th parameter to db->xAuth callbacks */
+ int nVar; /* Number of '?' variables seen in the SQL so far */
+ int nzVar; /* Number of available slots in azVar[] */
+ u8 explain; /* True if the EXPLAIN flag is found on the query */
#ifndef SQLITE_OMIT_VIRTUALTABLE
- Token sArg; /* Complete text of a module argument */
- u8 declareVtab; /* True if inside sqlite3_declare_vtab() */
- int nVtabLock; /* Number of virtual tables to lock */
- Table **apVtabLock; /* Pointer to virtual tables needing locking */
+ u8 declareVtab; /* True if inside sqlite3_declare_vtab() */
+ int nVtabLock; /* Number of virtual tables to lock */
#endif
- int nHeight; /* Expression tree height of current sub-select */
- Table *pZombieTab; /* List of Table objects to delete after code gen */
- TriggerPrg *pTriggerPrg; /* Linked list of coded triggers */
-
+ int nAlias; /* Number of aliased result set columns */
+ int nHeight; /* Expression tree height of current sub-select */
#ifndef SQLITE_OMIT_EXPLAIN
- int iSelectId;
- int iNextSelectId;
+ int iSelectId; /* ID of current select for EXPLAIN output */
+ int iNextSelectId; /* Next available select ID for EXPLAIN output */
+#endif
+ char **azVar; /* Pointers to names of parameters */
+ Vdbe *pReprepare; /* VM being reprepared (sqlite3Reprepare()) */
+ int *aAlias; /* Register used to hold aliased result */
+ const char *zTail; /* All SQL text past the last semicolon parsed */
+ Table *pNewTable; /* A table being constructed by CREATE TABLE */
+ Trigger *pNewTrigger; /* Trigger under construct by a CREATE TRIGGER */
+ const char *zAuthContext; /* The 6th parameter to db->xAuth callbacks */
+ Token sNameToken; /* Token with unqualified schema object name */
+ Token sLastToken; /* The last token parsed */
+#ifndef SQLITE_OMIT_VIRTUALTABLE
+ Token sArg; /* Complete text of a module argument */
+ Table **apVtabLock; /* Pointer to virtual tables needing locking */
#endif
+ Table *pZombieTab; /* List of Table objects to delete after code gen */
+ TriggerPrg *pTriggerPrg; /* Linked list of coded triggers */
};
+/*
+** Return true if currently inside an sqlite3_declare_vtab() call.
+*/
#ifdef SQLITE_OMIT_VIRTUALTABLE
#define IN_DECLARE_VTAB 0
#else
@@ -10887,7 +11425,7 @@ struct AuthContext {
};
/*
-** Bitfield flags for P5 value in OP_Insert and OP_Delete
+** Bitfield flags for P5 value in various opcodes.
*/
#define OPFLAG_NCHANGE 0x01 /* Set to update db->nChange */
#define OPFLAG_LASTROWID 0x02 /* Set to update db->lastRowid */
@@ -10895,6 +11433,11 @@ struct AuthContext {
#define OPFLAG_APPEND 0x08 /* This is likely to be an append */
#define OPFLAG_USESEEKRESULT 0x10 /* Try to avoid a seek in BtreeInsert() */
#define OPFLAG_CLEARCACHE 0x20 /* Clear pseudo-table cache in OP_Column */
+#define OPFLAG_LENGTHARG 0x40 /* OP_Column only used for length() */
+#define OPFLAG_TYPEOFARG 0x80 /* OP_Column only used for typeof() */
+#define OPFLAG_BULKCSR 0x01 /* OP_Open** used to open bulk cursor */
+#define OPFLAG_P2ISREG 0x02 /* P2 to OP_Open** is a register number */
+#define OPFLAG_PERMUTE 0x01 /* OP_Compare: use the permutation */
/*
* Each trigger present in the database schema is stored as an instance of
@@ -10994,6 +11537,7 @@ struct TriggerStep {
typedef struct DbFixer DbFixer;
struct DbFixer {
Parse *pParse; /* The parsing context. Error messages written here */
+ Schema *pSchema; /* Fix items to this schema */
const char *zDb; /* Make sure all objects are contained in this database */
const char *zType; /* Type of the container - used for error messages */
const Token *pName; /* Name of the container - used for error messages */
@@ -11021,8 +11565,8 @@ struct StrAccum {
*/
typedef struct {
sqlite3 *db; /* The database being initialized */
- int iDb; /* 0 for main database. 1 for TEMP, 2.. for ATTACHed */
char **pzErrMsg; /* Error message stored here */
+ int iDb; /* 0 for main database. 1 for TEMP, 2.. for ATTACHed */
int rc; /* Result code stored here */
} InitData;
@@ -11036,12 +11580,13 @@ struct Sqlite3Config {
int bCoreMutex; /* True to enable core mutexing */
int bFullMutex; /* True to enable full mutexing */
int bOpenUri; /* True to interpret filenames as URIs */
+ int bUseCis; /* Use covering indices for full-scans */
int mxStrlen; /* Maximum string length */
int szLookaside; /* Default lookaside buffer size */
int nLookaside; /* Default lookaside buffer count */
sqlite3_mem_methods m; /* Low-level memory allocation interface */
sqlite3_mutex_methods mutex; /* Low-level mutex interface */
- sqlite3_pcache_methods pcache; /* Low-level page-cache interface */
+ sqlite3_pcache_methods2 pcache2; /* Low-level page-cache interface */
void *pHeap; /* Heap storage space */
int nHeap; /* Size of pHeap[] */
int mnReq, mxReq; /* Min and max heap requests sizes */
@@ -11065,6 +11610,10 @@ struct Sqlite3Config {
void (*xLog)(void*,int,const char*); /* Function for logging */
void *pLogArg; /* First argument to xLog() */
int bLocaltimeFault; /* True to fail localtime() calls */
+#ifdef SQLITE_ENABLE_SQLLOG
+ void(*xSqllog)(void*,sqlite3*,const char*, int);
+ void *pSqllogArg;
+#endif
};
/*
@@ -11074,9 +11623,12 @@ struct Walker {
int (*xExprCallback)(Walker*, Expr*); /* Callback for expressions */
int (*xSelectCallback)(Walker*,Select*); /* Callback for SELECTs */
Parse *pParse; /* Parser context. */
+ int walkerDepth; /* Number of subqueries */
union { /* Extra data for callback */
NameContext *pNC; /* Naming context */
int i; /* Integer value */
+ SrcList *pSrcList; /* FROM clause */
+ struct SrcCount *pSrcCount; /* Counting column references */
} u;
};
@@ -11164,7 +11716,7 @@ SQLITE_PRIVATE int sqlite3CantopenError(int);
/*
** Internal function prototypes
*/
-SQLITE_PRIVATE int sqlite3StrICmp(const char *, const char *);
+#define sqlite3StrICmp sqlite3_stricmp
SQLITE_PRIVATE int sqlite3Strlen30(const char*);
#define sqlite3StrNICmp sqlite3_strnicmp
@@ -11247,6 +11799,29 @@ SQLITE_PRIVATE void sqlite3DebugPrintf(const char*, ...);
#if defined(SQLITE_TEST)
SQLITE_PRIVATE void *sqlite3TestTextToPtr(const char*);
#endif
+
+/* Output formatting for SQLITE_TESTCTRL_EXPLAIN */
+#if defined(SQLITE_ENABLE_TREE_EXPLAIN)
+SQLITE_PRIVATE void sqlite3ExplainBegin(Vdbe*);
+SQLITE_PRIVATE void sqlite3ExplainPrintf(Vdbe*, const char*, ...);
+SQLITE_PRIVATE void sqlite3ExplainNL(Vdbe*);
+SQLITE_PRIVATE void sqlite3ExplainPush(Vdbe*);
+SQLITE_PRIVATE void sqlite3ExplainPop(Vdbe*);
+SQLITE_PRIVATE void sqlite3ExplainFinish(Vdbe*);
+SQLITE_PRIVATE void sqlite3ExplainSelect(Vdbe*, Select*);
+SQLITE_PRIVATE void sqlite3ExplainExpr(Vdbe*, Expr*);
+SQLITE_PRIVATE void sqlite3ExplainExprList(Vdbe*, ExprList*);
+SQLITE_PRIVATE const char *sqlite3VdbeExplanation(Vdbe*);
+#else
+# define sqlite3ExplainBegin(X)
+# define sqlite3ExplainSelect(A,B)
+# define sqlite3ExplainExpr(A,B)
+# define sqlite3ExplainExprList(A,B)
+# define sqlite3ExplainFinish(X)
+# define sqlite3VdbeExplanation(X) 0
+#endif
+
+
SQLITE_PRIVATE void sqlite3SetString(char **, sqlite3*, const char*, ...);
SQLITE_PRIVATE void sqlite3ErrorMsg(Parse*, const char*, ...);
SQLITE_PRIVATE int sqlite3Dequote(char*);
@@ -11257,6 +11832,7 @@ SQLITE_PRIVATE int sqlite3GetTempReg(Parse*);
SQLITE_PRIVATE void sqlite3ReleaseTempReg(Parse*,int);
SQLITE_PRIVATE int sqlite3GetTempRange(Parse*,int);
SQLITE_PRIVATE void sqlite3ReleaseTempRange(Parse*,int,int);
+SQLITE_PRIVATE void sqlite3ClearTempRegCache(Parse*);
SQLITE_PRIVATE Expr *sqlite3ExprAlloc(sqlite3*,int,const Token*,int);
SQLITE_PRIVATE Expr *sqlite3Expr(sqlite3*,int,const char*);
SQLITE_PRIVATE void sqlite3ExprAttachSubtrees(sqlite3*,Expr*,Expr*,Expr*);
@@ -11272,7 +11848,9 @@ SQLITE_PRIVATE void sqlite3ExprListDelete(sqlite3*, ExprList*);
SQLITE_PRIVATE int sqlite3Init(sqlite3*, char**);
SQLITE_PRIVATE int sqlite3InitCallback(void*, int, char**, char**);
SQLITE_PRIVATE void sqlite3Pragma(Parse*,Token*,Token*,Token*,int);
-SQLITE_PRIVATE void sqlite3ResetInternalSchema(sqlite3*, int);
+SQLITE_PRIVATE void sqlite3ResetAllSchemasOfConnection(sqlite3*);
+SQLITE_PRIVATE void sqlite3ResetOneSchema(sqlite3*,int);
+SQLITE_PRIVATE void sqlite3CollapseDatabaseArray(sqlite3*);
SQLITE_PRIVATE void sqlite3BeginParse(Parse*,int);
SQLITE_PRIVATE void sqlite3CommitInternalChanges(sqlite3*);
SQLITE_PRIVATE Table *sqlite3ResultSetOfSelect(Parse*,Select*);
@@ -11288,6 +11866,8 @@ SQLITE_PRIVATE void sqlite3AddCollateType(Parse*, Token*);
SQLITE_PRIVATE void sqlite3EndTable(Parse*,Token*,Token*,Select*);
SQLITE_PRIVATE int sqlite3ParseUri(const char*,const char*,unsigned int*,
sqlite3_vfs**,char**,char **);
+SQLITE_PRIVATE Btree *sqlite3DbNameToBtree(sqlite3*,const char*);
+SQLITE_PRIVATE int sqlite3CodeOnce(Parse *);
SQLITE_PRIVATE Bitvec *sqlite3BitvecCreate(u32);
SQLITE_PRIVATE int sqlite3BitvecTest(Bitvec*, u32);
@@ -11312,6 +11892,7 @@ SQLITE_PRIVATE int sqlite3ViewGetColumnNames(Parse*,Table*);
#endif
SQLITE_PRIVATE void sqlite3DropTable(Parse*, SrcList*, int, int);
+SQLITE_PRIVATE void sqlite3CodeDropTable(Parse*, Table*, int, int);
SQLITE_PRIVATE void sqlite3DeleteTable(sqlite3*, Table*);
#ifndef SQLITE_OMIT_AUTOINCREMENT
SQLITE_PRIVATE void sqlite3AutoincrementBegin(Parse *pParse);
@@ -11320,8 +11901,9 @@ SQLITE_PRIVATE void sqlite3AutoincrementEnd(Parse *pParse);
# define sqlite3AutoincrementBegin(X)
# define sqlite3AutoincrementEnd(X)
#endif
+SQLITE_PRIVATE int sqlite3CodeCoroutine(Parse*, Select*, SelectDest*);
SQLITE_PRIVATE void sqlite3Insert(Parse*, SrcList*, ExprList*, Select*, IdList*, int);
-SQLITE_PRIVATE void *sqlite3ArrayAllocate(sqlite3*,void*,int,int,int*,int*,int*);
+SQLITE_PRIVATE void *sqlite3ArrayAllocate(sqlite3*,void*,int,int*,int*);
SQLITE_PRIVATE IdList *sqlite3IdListAppend(sqlite3*, IdList*, Token*);
SQLITE_PRIVATE int sqlite3IdListIndex(IdList*,const char*);
SQLITE_PRIVATE SrcList *sqlite3SrcListEnlarge(sqlite3*, SrcList*, int, int);
@@ -11339,22 +11921,21 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex(Parse*,Token*,Token*,SrcList*,ExprList*
SQLITE_PRIVATE void sqlite3DropIndex(Parse*, SrcList*, int);
SQLITE_PRIVATE int sqlite3Select(Parse*, Select*, SelectDest*);
SQLITE_PRIVATE Select *sqlite3SelectNew(Parse*,ExprList*,SrcList*,Expr*,ExprList*,
- Expr*,ExprList*,int,Expr*,Expr*);
+ Expr*,ExprList*,u16,Expr*,Expr*);
SQLITE_PRIVATE void sqlite3SelectDelete(sqlite3*, Select*);
SQLITE_PRIVATE Table *sqlite3SrcListLookup(Parse*, SrcList*);
SQLITE_PRIVATE int sqlite3IsReadOnly(Parse*, Table*, int);
SQLITE_PRIVATE void sqlite3OpenTable(Parse*, int iCur, int iDb, Table*, int);
#if defined(SQLITE_ENABLE_UPDATE_DELETE_LIMIT) && !defined(SQLITE_OMIT_SUBQUERY)
-SQLITE_PRIVATE Expr *sqlite3LimitWhere(Parse *, SrcList *, Expr *, ExprList *, Expr *, Expr *, char *);
+SQLITE_PRIVATE Expr *sqlite3LimitWhere(Parse*,SrcList*,Expr*,ExprList*,Expr*,Expr*,char*);
#endif
SQLITE_PRIVATE void sqlite3DeleteFrom(Parse*, SrcList*, Expr*);
SQLITE_PRIVATE void sqlite3Update(Parse*, SrcList*, ExprList*, Expr*, int);
-SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(Parse*, SrcList*, Expr*, ExprList**, u16);
+SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(Parse*,SrcList*,Expr*,ExprList*,ExprList*,u16,int);
SQLITE_PRIVATE void sqlite3WhereEnd(WhereInfo*);
-SQLITE_PRIVATE int sqlite3ExprCodeGetColumn(Parse*, Table*, int, int, int);
+SQLITE_PRIVATE int sqlite3ExprCodeGetColumn(Parse*, Table*, int, int, int, u8);
SQLITE_PRIVATE void sqlite3ExprCodeGetColumnOfTable(Vdbe*, Table*, int, int, int);
SQLITE_PRIVATE void sqlite3ExprCodeMove(Parse*, int, int, int);
-SQLITE_PRIVATE void sqlite3ExprCodeCopy(Parse*, int, int, int);
SQLITE_PRIVATE void sqlite3ExprCacheStore(Parse*, int, int, int);
SQLITE_PRIVATE void sqlite3ExprCachePush(Parse*);
SQLITE_PRIVATE void sqlite3ExprCachePop(Parse*, int);
@@ -11371,6 +11952,7 @@ SQLITE_PRIVATE void sqlite3ExprIfTrue(Parse*, Expr*, int, int);
SQLITE_PRIVATE void sqlite3ExprIfFalse(Parse*, Expr*, int, int);
SQLITE_PRIVATE Table *sqlite3FindTable(sqlite3*,const char*, const char*);
SQLITE_PRIVATE Table *sqlite3LocateTable(Parse*,int isView,const char*, const char*);
+SQLITE_PRIVATE Table *sqlite3LocateTableItem(Parse*,int isView,struct SrcList_item *);
SQLITE_PRIVATE Index *sqlite3FindIndex(sqlite3*,const char*, const char*);
SQLITE_PRIVATE void sqlite3UnlinkAndDeleteTable(sqlite3*,int,const char*);
SQLITE_PRIVATE void sqlite3UnlinkAndDeleteIndex(sqlite3*,int,const char*);
@@ -11381,11 +11963,12 @@ SQLITE_PRIVATE int sqlite3ExprCompare(Expr*, Expr*);
SQLITE_PRIVATE int sqlite3ExprListCompare(ExprList*, ExprList*);
SQLITE_PRIVATE void sqlite3ExprAnalyzeAggregates(NameContext*, Expr*);
SQLITE_PRIVATE void sqlite3ExprAnalyzeAggList(NameContext*,ExprList*);
+SQLITE_PRIVATE int sqlite3FunctionUsesThisSrc(Expr*, SrcList*);
SQLITE_PRIVATE Vdbe *sqlite3GetVdbe(Parse*);
SQLITE_PRIVATE void sqlite3PrngSaveState(void);
SQLITE_PRIVATE void sqlite3PrngRestoreState(void);
SQLITE_PRIVATE void sqlite3PrngResetState(void);
-SQLITE_PRIVATE void sqlite3RollbackAll(sqlite3*);
+SQLITE_PRIVATE void sqlite3RollbackAll(sqlite3*,int);
SQLITE_PRIVATE void sqlite3CodeVerifySchema(Parse*, int);
SQLITE_PRIVATE void sqlite3CodeVerifyNamedSchema(Parse*, const char *zDb);
SQLITE_PRIVATE void sqlite3BeginTransaction(Parse*, int);
@@ -11393,6 +11976,7 @@ SQLITE_PRIVATE void sqlite3CommitTransaction(Parse*);
SQLITE_PRIVATE void sqlite3RollbackTransaction(Parse*);
SQLITE_PRIVATE void sqlite3Savepoint(Parse*, int, Token*);
SQLITE_PRIVATE void sqlite3CloseSavepoints(sqlite3 *);
+SQLITE_PRIVATE void sqlite3LeaveMutexAndCloseZombie(sqlite3*);
SQLITE_PRIVATE int sqlite3ExprIsConstant(Expr*);
SQLITE_PRIVATE int sqlite3ExprIsConstantNotJoin(Expr*);
SQLITE_PRIVATE int sqlite3ExprIsConstantOrFunction(Expr*);
@@ -11411,14 +11995,14 @@ SQLITE_PRIVATE int sqlite3OpenTableAndIndices(Parse*, Table*, int, int);
SQLITE_PRIVATE void sqlite3BeginWriteOperation(Parse*, int, int);
SQLITE_PRIVATE void sqlite3MultiWrite(Parse*);
SQLITE_PRIVATE void sqlite3MayAbort(Parse*);
-SQLITE_PRIVATE void sqlite3HaltConstraint(Parse*, int, char*, int);
+SQLITE_PRIVATE void sqlite3HaltConstraint(Parse*, int, int, char*, int);
SQLITE_PRIVATE Expr *sqlite3ExprDup(sqlite3*,Expr*,int);
SQLITE_PRIVATE ExprList *sqlite3ExprListDup(sqlite3*,ExprList*,int);
SQLITE_PRIVATE SrcList *sqlite3SrcListDup(sqlite3*,SrcList*,int);
SQLITE_PRIVATE IdList *sqlite3IdListDup(sqlite3*,IdList*);
SQLITE_PRIVATE Select *sqlite3SelectDup(sqlite3*,Select*,int);
SQLITE_PRIVATE void sqlite3FuncDefInsert(FuncDefHash*, FuncDef*);
-SQLITE_PRIVATE FuncDef *sqlite3FindFunction(sqlite3*,const char*,int,int,u8,int);
+SQLITE_PRIVATE FuncDef *sqlite3FindFunction(sqlite3*,const char*,int,int,u8,u8);
SQLITE_PRIVATE void sqlite3RegisterBuiltinFunctions(sqlite3*);
SQLITE_PRIVATE void sqlite3RegisterDateTimeFunctions(void);
SQLITE_PRIVATE void sqlite3RegisterGlobalFunctions(void);
@@ -11492,7 +12076,7 @@ SQLITE_PRIVATE int sqlite3GetInt32(const char *, int*);
SQLITE_PRIVATE int sqlite3Atoi(const char*);
SQLITE_PRIVATE int sqlite3Utf16ByteLen(const void *pData, int nChar);
SQLITE_PRIVATE int sqlite3Utf8CharLen(const char *pData, int nByte);
-SQLITE_PRIVATE u32 sqlite3Utf8Read(const u8*, const u8**);
+SQLITE_PRIVATE u32 sqlite3Utf8Read(const u8**);
/*
** Routines to read and write variable-length integers. These used to
@@ -11524,8 +12108,11 @@ SQLITE_PRIVATE int sqlite3VarintLen(u64 v);
** x = putVarint32( A, B );
**
*/
-#define getVarint32(A,B) (u8)((*(A)<(u8)0x80) ? ((B) = (u32)*(A)),1 : sqlite3GetVarint32((A), (u32 *)&(B)))
-#define putVarint32(A,B) (u8)(((u32)(B)<(u32)0x80) ? (*(A) = (unsigned char)(B)),1 : sqlite3PutVarint32((A), (B)))
+#define getVarint32(A,B) \
+ (u8)((*(A)<(u8)0x80)?((B)=(u32)*(A)),1:sqlite3GetVarint32((A),(u32 *)&(B)))
+#define putVarint32(A,B) \
+ (u8)(((u32)(B)<(u32)0x80)?(*(A)=(unsigned char)(B)),1:\
+ sqlite3PutVarint32((A),(B)))
#define getVarint sqlite3GetVarint
#define putVarint sqlite3PutVarint
@@ -11545,8 +12132,9 @@ SQLITE_PRIVATE int sqlite3ReadSchema(Parse *pParse);
SQLITE_PRIVATE CollSeq *sqlite3FindCollSeq(sqlite3*,u8 enc, const char*,int);
SQLITE_PRIVATE CollSeq *sqlite3LocateCollSeq(Parse *pParse, const char*zName);
SQLITE_PRIVATE CollSeq *sqlite3ExprCollSeq(Parse *pParse, Expr *pExpr);
-SQLITE_PRIVATE Expr *sqlite3ExprSetColl(Expr*, CollSeq*);
-SQLITE_PRIVATE Expr *sqlite3ExprSetCollByToken(Parse *pParse, Expr*, Token*);
+SQLITE_PRIVATE Expr *sqlite3ExprAddCollateToken(Parse *pParse, Expr*, Token*);
+SQLITE_PRIVATE Expr *sqlite3ExprAddCollateString(Parse*,Expr*,const char*);
+SQLITE_PRIVATE Expr *sqlite3ExprSkipCollate(Expr*);
SQLITE_PRIVATE int sqlite3CheckCollSeq(Parse *, CollSeq *);
SQLITE_PRIVATE int sqlite3CheckObjectName(Parse *, const char *);
SQLITE_PRIVATE void sqlite3VdbeSetChanges(sqlite3 *, int);
@@ -11559,7 +12147,7 @@ SQLITE_PRIVATE void sqlite3FileSuffix3(const char*, char*);
#else
# define sqlite3FileSuffix3(X,Y)
#endif
-SQLITE_PRIVATE u8 sqlite3GetBoolean(const char *z);
+SQLITE_PRIVATE u8 sqlite3GetBoolean(const char *z,int);
SQLITE_PRIVATE const void *sqlite3ValueText(sqlite3_value*, u8);
SQLITE_PRIVATE int sqlite3ValueBytes(sqlite3_value*, u8);
@@ -11568,7 +12156,7 @@ SQLITE_PRIVATE void sqlite3ValueSetStr(sqlite3_value*, int, const void *,u8,
SQLITE_PRIVATE void sqlite3ValueFree(sqlite3_value*);
SQLITE_PRIVATE sqlite3_value *sqlite3ValueNew(sqlite3 *);
SQLITE_PRIVATE char *sqlite3Utf16to8(sqlite3 *, const void*, int, u8);
-#ifdef SQLITE_ENABLE_STAT2
+#ifdef SQLITE_ENABLE_STAT3
SQLITE_PRIVATE char *sqlite3Utf8to16(sqlite3 *, u8, char *, int, int *);
#endif
SQLITE_PRIVATE int sqlite3ValueFromExpr(sqlite3 *, Expr *, u8, u8, sqlite3_value **);
@@ -11593,13 +12181,14 @@ SQLITE_PRIVATE void sqlite3NestedParse(Parse*, const char*, ...);
SQLITE_PRIVATE void sqlite3ExpirePreparedStatements(sqlite3*);
SQLITE_PRIVATE int sqlite3CodeSubselect(Parse *, Expr *, int, int);
SQLITE_PRIVATE void sqlite3SelectPrep(Parse*, Select*, NameContext*);
+SQLITE_PRIVATE int sqlite3MatchSpanName(const char*, const char*, const char*, const char*);
SQLITE_PRIVATE int sqlite3ResolveExprNames(NameContext*, Expr*);
SQLITE_PRIVATE void sqlite3ResolveSelectNames(Parse*, Select*, NameContext*);
SQLITE_PRIVATE int sqlite3ResolveOrderGroupBy(Parse*, Select*, ExprList*, const char*);
SQLITE_PRIVATE void sqlite3ColumnDefault(Vdbe *, Table *, int, int);
SQLITE_PRIVATE void sqlite3AlterFinishAddColumn(Parse *, Token *);
SQLITE_PRIVATE void sqlite3AlterBeginAddColumn(Parse *, SrcList *);
-SQLITE_PRIVATE CollSeq *sqlite3GetCollSeq(sqlite3*, u8, CollSeq *, const char*);
+SQLITE_PRIVATE CollSeq *sqlite3GetCollSeq(Parse*, u8, CollSeq *, const char*);
SQLITE_PRIVATE char sqlite3AffinityType(const char*);
SQLITE_PRIVATE void sqlite3Analyze(Parse*, Token*, Token*);
SQLITE_PRIVATE int sqlite3InvokeBusyHandler(BusyHandler*);
@@ -11625,6 +12214,7 @@ SQLITE_PRIVATE int sqlite3OpenTempDatabase(Parse *);
SQLITE_PRIVATE void sqlite3StrAccumInit(StrAccum*, char*, int, int);
SQLITE_PRIVATE void sqlite3StrAccumAppend(StrAccum*,const char*,int);
+SQLITE_PRIVATE void sqlite3AppendSpace(StrAccum*,int);
SQLITE_PRIVATE char *sqlite3StrAccumFinish(StrAccum*);
SQLITE_PRIVATE void sqlite3StrAccumReset(StrAccum*);
SQLITE_PRIVATE void sqlite3SelectDestInit(SelectDest*,int,int);
@@ -11670,8 +12260,10 @@ SQLITE_PRIVATE int sqlite3Utf8To8(unsigned char*);
# define sqlite3VtabUnlock(X)
# define sqlite3VtabUnlockList(X)
# define sqlite3VtabSavepoint(X, Y, Z) SQLITE_OK
+# define sqlite3GetVTable(X,Y) ((VTable*)0)
#else
SQLITE_PRIVATE void sqlite3VtabClear(sqlite3 *db, Table*);
+SQLITE_PRIVATE void sqlite3VtabDisconnect(sqlite3 *db, Table *p);
SQLITE_PRIVATE int sqlite3VtabSync(sqlite3 *db, char **);
SQLITE_PRIVATE int sqlite3VtabRollback(sqlite3 *db);
SQLITE_PRIVATE int sqlite3VtabCommit(sqlite3 *db);
@@ -11679,10 +12271,11 @@ SQLITE_PRIVATE void sqlite3VtabLock(VTable *);
SQLITE_PRIVATE void sqlite3VtabUnlock(VTable *);
SQLITE_PRIVATE void sqlite3VtabUnlockList(sqlite3*);
SQLITE_PRIVATE int sqlite3VtabSavepoint(sqlite3 *, int, int);
+SQLITE_PRIVATE VTable *sqlite3GetVTable(sqlite3*, Table*);
# define sqlite3VtabInSync(db) ((db)->nVTrans>0 && (db)->aVTrans==0)
#endif
SQLITE_PRIVATE void sqlite3VtabMakeWritable(Parse*,Table*);
-SQLITE_PRIVATE void sqlite3VtabBeginParse(Parse*, Token*, Token*, Token*);
+SQLITE_PRIVATE void sqlite3VtabBeginParse(Parse*, Token*, Token*, Token*, int);
SQLITE_PRIVATE void sqlite3VtabFinishParse(Parse*, Token*);
SQLITE_PRIVATE void sqlite3VtabArgInit(Parse*);
SQLITE_PRIVATE void sqlite3VtabArgExtend(Parse*, Token*);
@@ -11698,10 +12291,11 @@ SQLITE_PRIVATE int sqlite3Reprepare(Vdbe*);
SQLITE_PRIVATE void sqlite3ExprListCheckLength(Parse*, ExprList*, const char*);
SQLITE_PRIVATE CollSeq *sqlite3BinaryCompareCollSeq(Parse *, Expr *, Expr *);
SQLITE_PRIVATE int sqlite3TempInMemory(const sqlite3*);
-SQLITE_PRIVATE VTable *sqlite3GetVTable(sqlite3*, Table*);
SQLITE_PRIVATE const char *sqlite3JournalModename(int);
-SQLITE_PRIVATE int sqlite3Checkpoint(sqlite3*, int, int, int*, int*);
-SQLITE_PRIVATE int sqlite3WalDefaultHook(void*,sqlite3*,const char*,int);
+#ifndef SQLITE_OMIT_WAL
+SQLITE_PRIVATE int sqlite3Checkpoint(sqlite3*, int, int, int*, int*);
+SQLITE_PRIVATE int sqlite3WalDefaultHook(void*,sqlite3*,const char*,int);
+#endif
/* Declarations for functions in fkey.c. All of these are replaced by
** no-op macros if OMIT_FOREIGN_KEY is defined. In this case no foreign
@@ -11726,8 +12320,10 @@ SQLITE_PRIVATE FKey *sqlite3FkReferences(Table *);
#endif
#ifndef SQLITE_OMIT_FOREIGN_KEY
SQLITE_PRIVATE void sqlite3FkDelete(sqlite3 *, Table*);
+SQLITE_PRIVATE int sqlite3FkLocateIndex(Parse*,Table*,FKey*,Index**,int**);
#else
#define sqlite3FkDelete(a,b)
+ #define sqlite3FkLocateIndex(a,b,c,d,e)
#endif
@@ -11752,15 +12348,18 @@ SQLITE_PRIVATE void sqlite3EndBenignMalloc(void);
#define IN_INDEX_ROWID 1
#define IN_INDEX_EPH 2
-#define IN_INDEX_INDEX 3
+#define IN_INDEX_INDEX_ASC 3
+#define IN_INDEX_INDEX_DESC 4
SQLITE_PRIVATE int sqlite3FindInIndex(Parse *, Expr *, int*);
#ifdef SQLITE_ENABLE_ATOMIC_WRITE
SQLITE_PRIVATE int sqlite3JournalOpen(sqlite3_vfs *, const char *, sqlite3_file *, int, int);
SQLITE_PRIVATE int sqlite3JournalSize(sqlite3_vfs *);
SQLITE_PRIVATE int sqlite3JournalCreate(sqlite3_file *);
+SQLITE_PRIVATE int sqlite3JournalExists(sqlite3_file *p);
#else
#define sqlite3JournalSize(pVfs) ((pVfs)->szOsFile)
+ #define sqlite3JournalExists(p) 1
#endif
SQLITE_PRIVATE void sqlite3MemJournalOpen(sqlite3_file *);
@@ -11989,6 +12588,10 @@ SQLITE_PRIVATE const unsigned char sqlite3CtypeMap[256] = {
# define SQLITE_USE_URI 0
#endif
+#ifndef SQLITE_ALLOW_COVERING_INDEX_SCAN
+# define SQLITE_ALLOW_COVERING_INDEX_SCAN 1
+#endif
+
/*
** The following singleton contains the global configuration for
** the SQLite library.
@@ -11998,12 +12601,13 @@ SQLITE_PRIVATE SQLITE_WSD struct Sqlite3Config sqlite3Config = {
1, /* bCoreMutex */
SQLITE_THREADSAFE==1, /* bFullMutex */
SQLITE_USE_URI, /* bOpenUri */
+ SQLITE_ALLOW_COVERING_INDEX_SCAN, /* bUseCis */
0x7ffffffe, /* mxStrlen */
- 100, /* szLookaside */
+ 128, /* szLookaside */
500, /* nLookaside */
{0,0,0,0,0,0,0,0}, /* m */
{0,0,0,0,0,0,0,0,0}, /* mutex */
- {0,0,0,0,0,0,0,0,0,0,0}, /* pcache */
+ {0,0,0,0,0,0,0,0,0,0,0,0,0},/* pcache2 */
(void*)0, /* pHeap */
0, /* nHeap */
0, 0, /* mnHeap, mxHeap */
@@ -12026,6 +12630,10 @@ SQLITE_PRIVATE SQLITE_WSD struct Sqlite3Config sqlite3Config = {
0, /* xLog */
0, /* pLogArg */
0, /* bLocaltimeFault */
+#ifdef SQLITE_ENABLE_SQLLOG
+ 0, /* xSqllog */
+ 0 /* pSqllogArg */
+#endif
};
@@ -12126,6 +12734,9 @@ static const char * const azCompileOpt[] = {
#ifdef SQLITE_COVERAGE_TEST
"COVERAGE_TEST",
#endif
+#ifdef SQLITE_CURDIR
+ "CURDIR",
+#endif
#ifdef SQLITE_DEBUG
"DEBUG",
#endif
@@ -12192,8 +12803,8 @@ static const char * const azCompileOpt[] = {
#ifdef SQLITE_ENABLE_RTREE
"ENABLE_RTREE",
#endif
-#ifdef SQLITE_ENABLE_STAT2
- "ENABLE_STAT2",
+#ifdef SQLITE_ENABLE_STAT3
+ "ENABLE_STAT3",
#endif
#ifdef SQLITE_ENABLE_UNLOCK_NOTIFY
"ENABLE_UNLOCK_NOTIFY",
@@ -12222,6 +12833,9 @@ static const char * const azCompileOpt[] = {
#ifdef SQLITE_LOCK_TRACE
"LOCK_TRACE",
#endif
+#ifdef SQLITE_MAX_SCHEMA_RETRY
+ "MAX_SCHEMA_RETRY=" CTIMEOPT_VAL(SQLITE_MAX_SCHEMA_RETRY),
+#endif
#ifdef SQLITE_MEMDEBUG
"MEMDEBUG",
#endif
@@ -12407,6 +13021,9 @@ static const char * const azCompileOpt[] = {
#ifdef SQLITE_PROXY_DEBUG
"PROXY_DEBUG",
#endif
+#ifdef SQLITE_RTREE_INT_ONLY
+ "RTREE_INT_ONLY",
+#endif
#ifdef SQLITE_SECURE_DELETE
"SECURE_DELETE",
#endif
@@ -12521,6 +13138,12 @@ typedef struct VdbeOp Op;
*/
typedef unsigned char Bool;
+/* Opaque type used by code in vdbesort.c */
+typedef struct VdbeSorter VdbeSorter;
+
+/* Opaque type used by the explainer */
+typedef struct Explain Explain;
+
/*
** A cursor is a pointer into a single BTree within a database file.
** The cursor can seek to a BTree entry with a particular key, or
@@ -12547,11 +13170,14 @@ struct VdbeCursor {
Bool isTable; /* True if a table requiring integer keys */
Bool isIndex; /* True if an index containing keys only - no data */
Bool isOrdered; /* True if the underlying table is BTREE_UNORDERED */
+ Bool isSorter; /* True if a new-style sorter */
+ Bool multiPseudo; /* Multi-register pseudo-cursor */
sqlite3_vtab_cursor *pVtabCursor; /* The cursor for a virtual table */
const sqlite3_module *pModule; /* Module for cursor pVtabCursor */
i64 seqCount; /* Sequence counter */
i64 movetoTarget; /* Argument to the deferred sqlite3BtreeMoveto() */
i64 lastRowid; /* Last rowid from a Next or NextIdx operation */
+ VdbeSorter *pSorter; /* Sorter object for OP_SorterOpen cursors */
/* Result of last sqlite3BtreeMoveto() done by an OP_NotExists or
** OP_IsUnique opcode on this cursor. */
@@ -12598,19 +13224,21 @@ typedef struct VdbeCursor VdbeCursor;
typedef struct VdbeFrame VdbeFrame;
struct VdbeFrame {
Vdbe *v; /* VM this frame belongs to */
- int pc; /* Program Counter in parent (calling) frame */
+ VdbeFrame *pParent; /* Parent of this frame, or NULL if parent is main */
Op *aOp; /* Program instructions for parent frame */
- int nOp; /* Size of aOp array */
Mem *aMem; /* Array of memory cells for parent frame */
- int nMem; /* Number of entries in aMem */
+ u8 *aOnceFlag; /* Array of OP_Once flags for parent frame */
VdbeCursor **apCsr; /* Array of Vdbe cursors for parent frame */
- u16 nCursor; /* Number of entries in apCsr */
void *token; /* Copy of SubProgram.token */
+ i64 lastRowid; /* Last insert rowid (sqlite3.lastRowid) */
+ int nCursor; /* Number of entries in apCsr */
+ int pc; /* Program Counter in parent (calling) frame */
+ int nOp; /* Size of aOp array */
+ int nMem; /* Number of entries in aMem */
+ int nOnceFlag; /* Number of entries in aOnceFlag */
int nChildMem; /* Number of memory cells for child frame */
int nChildCsr; /* Number of cursors for child frame */
- i64 lastRowid; /* Last insert rowid (sqlite3.lastRowid) */
int nChange; /* Statement changes (Vdbe.nChanges) */
- VdbeFrame *pParent; /* Parent of this frame, or NULL if parent is main */
};
#define VdbeFrameMem(p) ((Mem *)&((u8 *)p)[ROUND8(sizeof(VdbeFrame))])
@@ -12668,7 +13296,9 @@ struct Mem {
#define MEM_RowSet 0x0020 /* Value is a RowSet object */
#define MEM_Frame 0x0040 /* Value is a VdbeFrame object */
#define MEM_Invalid 0x0080 /* Value is undefined */
-#define MEM_TypeMask 0x00ff /* Mask of type bits */
+#define MEM_Cleared 0x0100 /* NULL set by OP_Null, not from data */
+#define MEM_TypeMask 0x01ff /* Mask of type bits */
+
/* Whenever Mem contains a valid string or blob representation, one of
** the following flags must be set to determine the memory management
@@ -12737,11 +13367,29 @@ struct sqlite3_context {
VdbeFunc *pVdbeFunc; /* Auxilary data, if created. */
Mem s; /* The return value is stored here */
Mem *pMem; /* Memory cell used to store aggregate context */
- int isError; /* Error code returned by the function. */
CollSeq *pColl; /* Collating sequence */
+ int isError; /* Error code returned by the function. */
+ int skipFlag; /* Skip skip accumulator loading if true */
};
/*
+** An Explain object accumulates indented output which is helpful
+** in describing recursive data structures.
+*/
+struct Explain {
+ Vdbe *pVdbe; /* Attach the explanation to this Vdbe */
+ StrAccum str; /* The string being accumulated */
+ int nIndent; /* Number of elements in aIndent */
+ u16 aIndent[100]; /* Levels of indentation */
+ char zBase[100]; /* Initial space */
+};
+
+/* A bitfield type for use inside of structures. Always follow with :N where
+** N is the number of bits.
+*/
+typedef unsigned bft; /* Bit Field Type */
+
+/*
** An instance of the virtual machine. This structure contains the complete
** state of the virtual machine.
**
@@ -12767,10 +13415,9 @@ struct Vdbe {
int nOp; /* Number of instructions in the program */
int nOpAlloc; /* Number of slots allocated for aOp[] */
int nLabel; /* Number of labels used */
- int nLabelAlloc; /* Number of slots allocated in aLabel[] */
int *aLabel; /* Space to hold the labels */
u16 nResColumn; /* Number of columns in one row of the result set */
- u16 nCursor; /* Number of slots in apCsr[] */
+ int nCursor; /* Number of slots in apCsr[] */
u32 magic; /* Magic number for sanity checking */
char *zErrMsg; /* Error message written here */
Vdbe *pPrev,*pNext; /* Linked list of VDBEs with the same Vdbe.db */
@@ -12783,15 +13430,16 @@ struct Vdbe {
int pc; /* The program counter */
int rc; /* Value to return */
u8 errorAction; /* Recovery action to do in case of an error */
- u8 explain; /* True if EXPLAIN present on SQL command */
- u8 changeCntOn; /* True to update the change-counter */
- u8 expired; /* True if the VM needs to be recompiled */
- u8 runOnlyOnce; /* Automatically expire on reset */
u8 minWriteFileFormat; /* Minimum file format for writable database files */
- u8 inVtabMethod; /* See comments above */
- u8 usesStmtJournal; /* True if uses a statement journal */
- u8 readOnly; /* True for read-only statements */
- u8 isPrepareV2; /* True if prepared with prepare_v2() */
+ bft explain:2; /* True if EXPLAIN present on SQL command */
+ bft inVtabMethod:2; /* See comments above */
+ bft changeCntOn:1; /* True to update the change-counter */
+ bft expired:1; /* True if the VM needs to be recompiled */
+ bft runOnlyOnce:1; /* Automatically expire on reset */
+ bft usesStmtJournal:1; /* True if uses a statement journal */
+ bft readOnly:1; /* True for read-only statements */
+ bft isPrepareV2:1; /* True if prepared with prepare_v2() */
+ bft doingRerun:1; /* True if rerunning after an auto-reprepare */
int nChange; /* Number of db changes made since last reset */
yDbMask btreeMask; /* Bitmask of db->aDb[] entries referenced */
yDbMask lockMask; /* Subset of btreeMask that requires a lock */
@@ -12807,11 +13455,17 @@ struct Vdbe {
#ifdef SQLITE_DEBUG
FILE *trace; /* Write an execution trace here, if not NULL */
#endif
+#ifdef SQLITE_ENABLE_TREE_EXPLAIN
+ Explain *pExplain; /* The explainer */
+ char *zExplain; /* Explanation of data structures */
+#endif
VdbeFrame *pFrame; /* Parent frame */
VdbeFrame *pDelFrame; /* List of frame objects to free on VM reset */
int nFrame; /* Number of frames in pFrame list */
u32 expmask; /* Binding to these vars invalidates VM */
SubProgram *pProgram; /* Linked list of all sub-programs used by VM */
+ int nOnceFlag; /* Size of array aOnceFlag[] */
+ u8 *aOnceFlag; /* Flags for OP_Once */
};
/*
@@ -12871,6 +13525,9 @@ SQLITE_PRIVATE int sqlite3VdbeMemNumerify(Mem*);
SQLITE_PRIVATE int sqlite3VdbeMemFromBtree(BtCursor*,int,int,int,Mem*);
SQLITE_PRIVATE void sqlite3VdbeMemRelease(Mem *p);
SQLITE_PRIVATE void sqlite3VdbeMemReleaseExternal(Mem *p);
+#define VdbeMemRelease(X) \
+ if((X)->flags&(MEM_Agg|MEM_Dyn|MEM_RowSet|MEM_Frame)) \
+ sqlite3VdbeMemReleaseExternal(X);
SQLITE_PRIVATE int sqlite3VdbeMemFinalize(Mem*, FuncDef*);
SQLITE_PRIVATE const char *sqlite3OpcodeName(int);
SQLITE_PRIVATE int sqlite3VdbeMemGrow(Mem *pMem, int n, int preserve);
@@ -12878,6 +13535,15 @@ SQLITE_PRIVATE int sqlite3VdbeCloseStatement(Vdbe *, int);
SQLITE_PRIVATE void sqlite3VdbeFrameDelete(VdbeFrame*);
SQLITE_PRIVATE int sqlite3VdbeFrameRestore(VdbeFrame *);
SQLITE_PRIVATE void sqlite3VdbeMemStoreType(Mem *pMem);
+SQLITE_PRIVATE int sqlite3VdbeTransferError(Vdbe *p);
+
+SQLITE_PRIVATE int sqlite3VdbeSorterInit(sqlite3 *, VdbeCursor *);
+SQLITE_PRIVATE void sqlite3VdbeSorterClose(sqlite3 *, VdbeCursor *);
+SQLITE_PRIVATE int sqlite3VdbeSorterRowkey(const VdbeCursor *, Mem *);
+SQLITE_PRIVATE int sqlite3VdbeSorterNext(sqlite3 *, const VdbeCursor *, int *);
+SQLITE_PRIVATE int sqlite3VdbeSorterRewind(sqlite3 *, const VdbeCursor *, int *);
+SQLITE_PRIVATE int sqlite3VdbeSorterWrite(sqlite3 *, const VdbeCursor *, Mem *);
+SQLITE_PRIVATE int sqlite3VdbeSorterCompare(const VdbeCursor *, Mem *, int *);
#if !defined(SQLITE_OMIT_SHARED_CACHE) && SQLITE_THREADSAFE>0
SQLITE_PRIVATE void sqlite3VdbeEnter(Vdbe*);
@@ -12888,7 +13554,7 @@ SQLITE_PRIVATE void sqlite3VdbeLeave(Vdbe*);
#endif
#ifdef SQLITE_DEBUG
-SQLITE_PRIVATE void sqlite3VdbeMemPrepareToChange(Vdbe*,Mem*);
+SQLITE_PRIVATE void sqlite3VdbeMemAboutToChange(Vdbe*,Mem*);
#endif
#ifndef SQLITE_OMIT_FOREIGN_KEY
@@ -12906,8 +13572,10 @@ SQLITE_PRIVATE int sqlite3VdbeMemHandleBom(Mem *pMem);
#ifndef SQLITE_OMIT_INCRBLOB
SQLITE_PRIVATE int sqlite3VdbeMemExpandBlob(Mem *);
+ #define ExpandBlob(P) (((P)->flags&MEM_Zero)?sqlite3VdbeMemExpandBlob(P):0)
#else
#define sqlite3VdbeMemExpandBlob(x) SQLITE_OK
+ #define ExpandBlob(P) SQLITE_OK
#endif
#endif /* !defined(_VDBEINT_H_) */
@@ -13107,7 +13775,8 @@ SQLITE_API int sqlite3_db_status(
db->pnBytesFreed = &nByte;
for(pVdbe=db->pVdbe; pVdbe; pVdbe=pVdbe->pNext){
- sqlite3VdbeDeleteObject(db, pVdbe);
+ sqlite3VdbeClearObject(db, pVdbe);
+ sqlite3DbFree(db, pVdbe);
}
db->pnBytesFreed = 0;
@@ -13117,6 +13786,30 @@ SQLITE_API int sqlite3_db_status(
break;
}
+ /*
+ ** Set *pCurrent to the total cache hits or misses encountered by all
+ ** pagers the database handle is connected to. *pHighwater is always set
+ ** to zero.
+ */
+ case SQLITE_DBSTATUS_CACHE_HIT:
+ case SQLITE_DBSTATUS_CACHE_MISS:
+ case SQLITE_DBSTATUS_CACHE_WRITE:{
+ int i;
+ int nRet = 0;
+ assert( SQLITE_DBSTATUS_CACHE_MISS==SQLITE_DBSTATUS_CACHE_HIT+1 );
+ assert( SQLITE_DBSTATUS_CACHE_WRITE==SQLITE_DBSTATUS_CACHE_HIT+2 );
+
+ for(i=0; i<db->nDb; i++){
+ if( db->aDb[i].pBt ){
+ Pager *pPager = sqlite3BtreePager(db->aDb[i].pBt);
+ sqlite3PagerCacheStat(pPager, op, resetFlag, &nRet);
+ }
+ }
+ *pHighwater = 0;
+ *pCurrent = nRet;
+ break;
+ }
+
default: {
rc = SQLITE_ERROR;
}
@@ -13172,6 +13865,8 @@ SQLITE_API int sqlite3_db_status(
** Willmann-Bell, Inc
** Richmond, Virginia (USA)
*/
+/* #include <stdlib.h> */
+/* #include <assert.h> */
#include <time.h>
#ifndef SQLITE_OMIT_DATETIME_FUNCS
@@ -13415,12 +14110,18 @@ static int parseYyyyMmDd(const char *zDate, DateTime *p){
}
/*
-** Set the time to the current time reported by the VFS
+** Set the time to the current time reported by the VFS.
+**
+** Return the number of errors.
*/
-static void setDateTimeToCurrent(sqlite3_context *context, DateTime *p){
+static int setDateTimeToCurrent(sqlite3_context *context, DateTime *p){
sqlite3 *db = sqlite3_context_db_handle(context);
- sqlite3OsCurrentTimeInt64(db->pVfs, &p->iJD);
- p->validJD = 1;
+ if( sqlite3OsCurrentTimeInt64(db->pVfs, &p->iJD)==SQLITE_OK ){
+ p->validJD = 1;
+ return 0;
+ }else{
+ return 1;
+ }
}
/*
@@ -13450,8 +14151,7 @@ static int parseDateOrTime(
}else if( parseHhMmSs(zDate, p)==0 ){
return 0;
}else if( sqlite3StrICmp(zDate,"now")==0){
- setDateTimeToCurrent(context, p);
- return 0;
+ return setDateTimeToCurrent(context, p);
}else if( sqlite3AtoF(zDate, &r, sqlite3Strlen30(zDate), SQLITE_UTF8) ){
p->iJD = (sqlite3_int64)(r*86400000.0 + 0.5);
p->validJD = 1;
@@ -13540,16 +14240,6 @@ static void clearYMD_HMS_TZ(DateTime *p){
#ifndef SQLITE_OMIT_LOCALTIME
/*
-** Windows CE does not declare the localtime
-** function as it is not defined anywhere.
-** Anyway we need the forward-declaration to be
-** able to define it later on.
-*/
-#if defined(_WIN32_WCE) && (_WIN32_WCE >= 0x600)
-static struct tm *__cdecl localtime(const time_t *t);
-#endif
-
-/*
** The following routine implements the rough equivalent of localtime_r()
** using whatever operating-system specific localtime facility that
** is available. This routine returns 0 on success and
@@ -13563,7 +14253,9 @@ static int osLocaltime(time_t *t, struct tm *pTm){
#if (!defined(HAVE_LOCALTIME_R) || !HAVE_LOCALTIME_R) \
&& (!defined(HAVE_LOCALTIME_S) || !HAVE_LOCALTIME_S)
struct tm *pX;
+#if SQLITE_THREADSAFE>0
sqlite3_mutex *mutex = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER);
+#endif
sqlite3_mutex_enter(mutex);
pX = localtime(t);
#ifndef SQLITE_OMIT_BUILTIN_TEST
@@ -13584,7 +14276,10 @@ static int osLocaltime(time_t *t, struct tm *pTm){
#endif /* HAVE_LOCALTIME_R || HAVE_LOCALTIME_S */
return rc;
}
+#endif /* SQLITE_OMIT_LOCALTIME */
+
+#ifndef SQLITE_OMIT_LOCALTIME
/*
** Compute the difference (in milliseconds) between localtime and UTC
** (a.k.a. GMT) for the time value p where p is in UTC. If no error occurs,
@@ -13883,8 +14578,9 @@ static int isDate(
int eType;
memset(p, 0, sizeof(*p));
if( argc==0 ){
- setDateTimeToCurrent(context, p);
- }else if( (eType = sqlite3_value_type(argv[0]))==SQLITE_FLOAT
+ return setDateTimeToCurrent(context, p);
+ }
+ if( (eType = sqlite3_value_type(argv[0]))==SQLITE_FLOAT
|| eType==SQLITE_INTEGER ){
p->iJD = (sqlite3_int64)(sqlite3_value_double(argv[0])*86400000.0 + 0.5);
p->validJD = 1;
@@ -14196,31 +14892,28 @@ static void currentTimeFunc(
char *zFormat = (char *)sqlite3_user_data(context);
sqlite3 *db;
sqlite3_int64 iT;
+ struct tm *pTm;
+ struct tm sNow;
char zBuf[20];
UNUSED_PARAMETER(argc);
UNUSED_PARAMETER(argv);
db = sqlite3_context_db_handle(context);
- sqlite3OsCurrentTimeInt64(db->pVfs, &iT);
+ if( sqlite3OsCurrentTimeInt64(db->pVfs, &iT) ) return;
t = iT/1000 - 10000*(sqlite3_int64)21086676;
#ifdef HAVE_GMTIME_R
- {
- struct tm sNow;
- gmtime_r(&t, &sNow);
- strftime(zBuf, 20, zFormat, &sNow);
- }
+ pTm = gmtime_r(&t, &sNow);
#else
- {
- struct tm *pTm;
- sqlite3_mutex_enter(sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER));
- pTm = gmtime(&t);
- strftime(zBuf, 20, zFormat, pTm);
- sqlite3_mutex_leave(sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER));
- }
+ sqlite3_mutex_enter(sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER));
+ pTm = gmtime(&t);
+ if( pTm ) memcpy(&sNow, pTm, sizeof(sNow));
+ sqlite3_mutex_leave(sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER));
#endif
-
- sqlite3_result_text(context, zBuf, -1, SQLITE_TRANSIENT);
+ if( pTm ){
+ strftime(zBuf, 20, zFormat, &sNow);
+ sqlite3_result_text(context, zBuf, -1, SQLITE_TRANSIENT);
+ }
}
#endif
@@ -14285,11 +14978,18 @@ SQLITE_PRIVATE void sqlite3RegisterDateTimeFunctions(void){
** The following functions are instrumented for malloc() failure
** testing:
**
-** sqlite3OsOpen()
** sqlite3OsRead()
** sqlite3OsWrite()
** sqlite3OsSync()
+** sqlite3OsFileSize()
** sqlite3OsLock()
+** sqlite3OsCheckReservedLock()
+** sqlite3OsFileControl()
+** sqlite3OsShmMap()
+** sqlite3OsOpen()
+** sqlite3OsDelete()
+** sqlite3OsAccess()
+** sqlite3OsFullPathname()
**
*/
#if defined(SQLITE_TEST)
@@ -14348,9 +15048,23 @@ SQLITE_PRIVATE int sqlite3OsCheckReservedLock(sqlite3_file *id, int *pResOut){
DO_OS_MALLOC_TEST(id);
return id->pMethods->xCheckReservedLock(id, pResOut);
}
+
+/*
+** Use sqlite3OsFileControl() when we are doing something that might fail
+** and we need to know about the failures. Use sqlite3OsFileControlHint()
+** when simply tossing information over the wall to the VFS and we do not
+** really care if the VFS receives and understands the information since it
+** is only a hint and can be safely ignored. The sqlite3OsFileControlHint()
+** routine has no return value since the return value would be meaningless.
+*/
SQLITE_PRIVATE int sqlite3OsFileControl(sqlite3_file *id, int op, void *pArg){
+ DO_OS_MALLOC_TEST(id);
return id->pMethods->xFileControl(id, op, pArg);
}
+SQLITE_PRIVATE void sqlite3OsFileControlHint(sqlite3_file *id, int op, void *pArg){
+ (void)id->pMethods->xFileControl(id, op, pArg);
+}
+
SQLITE_PRIVATE int sqlite3OsSectorSize(sqlite3_file *id){
int (*xSectorSize)(sqlite3_file*) = id->pMethods->xSectorSize;
return (xSectorSize ? xSectorSize(id) : SQLITE_DEFAULT_SECTOR_SIZE);
@@ -14374,6 +15088,7 @@ SQLITE_PRIVATE int sqlite3OsShmMap(
int bExtend, /* True to extend file if necessary */
void volatile **pp /* OUT: Pointer to mapping */
){
+ DO_OS_MALLOC_TEST(id);
return id->pMethods->xShmMap(id, iPage, pgsz, bExtend, pp);
}
@@ -14390,15 +15105,17 @@ SQLITE_PRIVATE int sqlite3OsOpen(
){
int rc;
DO_OS_MALLOC_TEST(0);
- /* 0x87f3f is a mask of SQLITE_OPEN_ flags that are valid to be passed
+ /* 0x87f7f is a mask of SQLITE_OPEN_ flags that are valid to be passed
** down into the VFS layer. Some SQLITE_OPEN_ flags (for example,
** SQLITE_OPEN_FULLMUTEX or SQLITE_OPEN_SHAREDCACHE) are blocked before
** reaching the VFS. */
- rc = pVfs->xOpen(pVfs, zPath, pFile, flags & 0x87f3f, pFlagsOut);
+ rc = pVfs->xOpen(pVfs, zPath, pFile, flags & 0x87f7f, pFlagsOut);
assert( rc==SQLITE_OK || pFile->pMethods==0 );
return rc;
}
SQLITE_PRIVATE int sqlite3OsDelete(sqlite3_vfs *pVfs, const char *zPath, int dirSync){
+ DO_OS_MALLOC_TEST(0);
+ assert( dirSync==0 || dirSync==1 );
return pVfs->xDelete(pVfs, zPath, dirSync);
}
SQLITE_PRIVATE int sqlite3OsAccess(
@@ -14416,6 +15133,7 @@ SQLITE_PRIVATE int sqlite3OsFullPathname(
int nPathOut,
char *zPathOut
){
+ DO_OS_MALLOC_TEST(0);
zPathOut[0] = 0;
return pVfs->xFullPathname(pVfs, zPath, nPathOut, zPathOut);
}
@@ -14466,7 +15184,7 @@ SQLITE_PRIVATE int sqlite3OsOpenMalloc(
){
int rc = SQLITE_NOMEM;
sqlite3_file *pFile;
- pFile = (sqlite3_file *)sqlite3Malloc(pVfs->szOsFile);
+ pFile = (sqlite3_file *)sqlite3MallocZero(pVfs->szOsFile);
if( pFile ){
rc = sqlite3OsOpen(pVfs, zFile, pFile, flags, pOutFlags);
if( rc!=SQLITE_OK ){
@@ -14555,12 +15273,12 @@ static void vfsUnlink(sqlite3_vfs *pVfs){
** true.
*/
SQLITE_API int sqlite3_vfs_register(sqlite3_vfs *pVfs, int makeDflt){
- sqlite3_mutex *mutex = 0;
+ MUTEX_LOGIC(sqlite3_mutex *mutex;)
#ifndef SQLITE_OMIT_AUTOINIT
int rc = sqlite3_initialize();
if( rc ) return rc;
#endif
- mutex = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER);
+ MUTEX_LOGIC( mutex = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER); )
sqlite3_mutex_enter(mutex);
vfsUnlink(pVfs);
if( makeDflt || vfsList==0 ){
@@ -14757,7 +15475,31 @@ SQLITE_PRIVATE void sqlite3MemSetDefault(void){
** to obtain the memory it needs.
**
** This file contains implementations of the low-level memory allocation
-** routines specified in the sqlite3_mem_methods object.
+** routines specified in the sqlite3_mem_methods object. The content of
+** this file is only used if SQLITE_SYSTEM_MALLOC is defined. The
+** SQLITE_SYSTEM_MALLOC macro is defined automatically if neither the
+** SQLITE_MEMDEBUG nor the SQLITE_WIN32_MALLOC macros are defined. The
+** default configuration is to use memory allocation routines in this
+** file.
+**
+** C-preprocessor macro summary:
+**
+** HAVE_MALLOC_USABLE_SIZE The configure script sets this symbol if
+** the malloc_usable_size() interface exists
+** on the target platform. Or, this symbol
+** can be set manually, if desired.
+** If an equivalent interface exists by
+** a different name, using a separate -D
+** option to rename it.
+**
+** SQLITE_WITHOUT_ZONEMALLOC Some older macs lack support for the zone
+** memory allocator. Set this symbol to enable
+** building on older macs.
+**
+** SQLITE_WITHOUT_MSIZE Set this symbol to disable the use of
+** _msize() on windows systems. This might
+** be necessary when compiling for Delphi,
+** for example.
*/
/*
@@ -14768,6 +15510,55 @@ SQLITE_PRIVATE void sqlite3MemSetDefault(void){
#ifdef SQLITE_SYSTEM_MALLOC
/*
+** The MSVCRT has malloc_usable_size() but it is called _msize().
+** The use of _msize() is automatic, but can be disabled by compiling
+** with -DSQLITE_WITHOUT_MSIZE
+*/
+#if defined(_MSC_VER) && !defined(SQLITE_WITHOUT_MSIZE)
+# define SQLITE_MALLOCSIZE _msize
+#endif
+
+#if defined(__APPLE__) && !defined(SQLITE_WITHOUT_ZONEMALLOC)
+
+/*
+** Use the zone allocator available on apple products unless the
+** SQLITE_WITHOUT_ZONEMALLOC symbol is defined.
+*/
+#include <sys/sysctl.h>
+#include <malloc/malloc.h>
+#include <libkern/OSAtomic.h>
+static malloc_zone_t* _sqliteZone_;
+#define SQLITE_MALLOC(x) malloc_zone_malloc(_sqliteZone_, (x))
+#define SQLITE_FREE(x) malloc_zone_free(_sqliteZone_, (x));
+#define SQLITE_REALLOC(x,y) malloc_zone_realloc(_sqliteZone_, (x), (y))
+#define SQLITE_MALLOCSIZE(x) \
+ (_sqliteZone_ ? _sqliteZone_->size(_sqliteZone_,x) : malloc_size(x))
+
+#else /* if not __APPLE__ */
+
+/*
+** Use standard C library malloc and free on non-Apple systems.
+** Also used by Apple systems if SQLITE_WITHOUT_ZONEMALLOC is defined.
+*/
+#define SQLITE_MALLOC(x) malloc(x)
+#define SQLITE_FREE(x) free(x)
+#define SQLITE_REALLOC(x,y) realloc((x),(y))
+
+#if (defined(_MSC_VER) && !defined(SQLITE_WITHOUT_MSIZE)) \
+ || (defined(HAVE_MALLOC_H) && defined(HAVE_MALLOC_USABLE_SIZE))
+# include <malloc.h> /* Needed for malloc_usable_size on linux */
+#endif
+#ifdef HAVE_MALLOC_USABLE_SIZE
+# ifndef SQLITE_MALLOCSIZE
+# define SQLITE_MALLOCSIZE(x) malloc_usable_size(x)
+# endif
+#else
+# undef SQLITE_MALLOCSIZE
+#endif
+
+#endif /* __APPLE__ or not __APPLE__ */
+
+/*
** Like malloc(), but remember the size of the allocation
** so that we can find it later using sqlite3MemSize().
**
@@ -14776,10 +15567,18 @@ SQLITE_PRIVATE void sqlite3MemSetDefault(void){
** routines.
*/
static void *sqlite3MemMalloc(int nByte){
+#ifdef SQLITE_MALLOCSIZE
+ void *p = SQLITE_MALLOC( nByte );
+ if( p==0 ){
+ testcase( sqlite3GlobalConfig.xLog!=0 );
+ sqlite3_log(SQLITE_NOMEM, "failed to allocate %u bytes of memory", nByte);
+ }
+ return p;
+#else
sqlite3_int64 *p;
assert( nByte>0 );
nByte = ROUND8(nByte);
- p = malloc( nByte+8 );
+ p = SQLITE_MALLOC( nByte+8 );
if( p ){
p[0] = nByte;
p++;
@@ -14788,6 +15587,7 @@ static void *sqlite3MemMalloc(int nByte){
sqlite3_log(SQLITE_NOMEM, "failed to allocate %u bytes of memory", nByte);
}
return (void *)p;
+#endif
}
/*
@@ -14799,10 +15599,14 @@ static void *sqlite3MemMalloc(int nByte){
** by higher-level routines.
*/
static void sqlite3MemFree(void *pPrior){
+#ifdef SQLITE_MALLOCSIZE
+ SQLITE_FREE(pPrior);
+#else
sqlite3_int64 *p = (sqlite3_int64*)pPrior;
assert( pPrior!=0 );
p--;
- free(p);
+ SQLITE_FREE(p);
+#endif
}
/*
@@ -14810,11 +15614,15 @@ static void sqlite3MemFree(void *pPrior){
** or xRealloc().
*/
static int sqlite3MemSize(void *pPrior){
+#ifdef SQLITE_MALLOCSIZE
+ return pPrior ? (int)SQLITE_MALLOCSIZE(pPrior) : 0;
+#else
sqlite3_int64 *p;
if( pPrior==0 ) return 0;
p = (sqlite3_int64*)pPrior;
p--;
return (int)p[0];
+#endif
}
/*
@@ -14828,11 +15636,21 @@ static int sqlite3MemSize(void *pPrior){
** routines and redirected to xFree.
*/
static void *sqlite3MemRealloc(void *pPrior, int nByte){
+#ifdef SQLITE_MALLOCSIZE
+ void *p = SQLITE_REALLOC(pPrior, nByte);
+ if( p==0 ){
+ testcase( sqlite3GlobalConfig.xLog!=0 );
+ sqlite3_log(SQLITE_NOMEM,
+ "failed memory resize %u to %u bytes",
+ SQLITE_MALLOCSIZE(pPrior), nByte);
+ }
+ return p;
+#else
sqlite3_int64 *p = (sqlite3_int64*)pPrior;
assert( pPrior!=0 && nByte>0 );
assert( nByte==ROUND8(nByte) ); /* EV: R-46199-30249 */
p--;
- p = realloc(p, nByte+8 );
+ p = SQLITE_REALLOC(p, nByte+8 );
if( p ){
p[0] = nByte;
p++;
@@ -14843,6 +15661,7 @@ static void *sqlite3MemRealloc(void *pPrior, int nByte){
sqlite3MemSize(pPrior), nByte);
}
return (void*)p;
+#endif
}
/*
@@ -14856,6 +15675,34 @@ static int sqlite3MemRoundup(int n){
** Initialize this module.
*/
static int sqlite3MemInit(void *NotUsed){
+#if defined(__APPLE__) && !defined(SQLITE_WITHOUT_ZONEMALLOC)
+ int cpuCount;
+ size_t len;
+ if( _sqliteZone_ ){
+ return SQLITE_OK;
+ }
+ len = sizeof(cpuCount);
+ /* One usually wants to use hw.acctivecpu for MT decisions, but not here */
+ sysctlbyname("hw.ncpu", &cpuCount, &len, NULL, 0);
+ if( cpuCount>1 ){
+ /* defer MT decisions to system malloc */
+ _sqliteZone_ = malloc_default_zone();
+ }else{
+ /* only 1 core, use our own zone to contention over global locks,
+ ** e.g. we have our own dedicated locks */
+ bool success;
+ malloc_zone_t* newzone = malloc_create_zone(4096, 0);
+ malloc_set_zone_name(newzone, "Sqlite_Heap");
+ do{
+ success = OSAtomicCompareAndSwapPtrBarrier(NULL, newzone,
+ (void * volatile *)&_sqliteZone_);
+ }while(!_sqliteZone_);
+ if( !success ){
+ /* somebody registered a zone first */
+ malloc_destroy_zone(newzone);
+ }
+ }
+#endif
UNUSED_PARAMETER(NotUsed);
return SQLITE_OK;
}
@@ -14930,6 +15777,7 @@ SQLITE_PRIVATE void sqlite3MemSetDefault(void){
# define backtrace(A,B) 1
# define backtrace_symbols_fd(A,B,C)
#endif
+/* #include <stdio.h> */
/*
** Each memory allocation looks like this:
@@ -15855,7 +16703,7 @@ static void *memsys3MallocUnsafe(int nByte){
** This function assumes that the necessary mutexes, if any, are
** already held by the caller. Hence "Unsafe".
*/
-void memsys3FreeUnsafe(void *pOld){
+static void memsys3FreeUnsafe(void *pOld){
Mem3Block *p = (Mem3Block*)pOld;
int i;
u32 size, x;
@@ -15930,7 +16778,7 @@ static void *memsys3Malloc(int nBytes){
/*
** Free memory.
*/
-void memsys3Free(void *pPrior){
+static void memsys3Free(void *pPrior){
assert( pPrior );
memsys3Enter();
memsys3FreeUnsafe(pPrior);
@@ -15940,7 +16788,7 @@ void memsys3Free(void *pPrior){
/*
** Change the size of an existing memory allocation
*/
-void *memsys3Realloc(void *pPrior, int nBytes){
+static void *memsys3Realloc(void *pPrior, int nBytes){
int nOld;
void *p;
if( pPrior==0 ){
@@ -16844,7 +17692,7 @@ SQLITE_API int sqlite3_mutex_notheld(sqlite3_mutex *p){
}
#endif
-#endif /* SQLITE_MUTEX_OMIT */
+#endif /* !defined(SQLITE_MUTEX_OMIT) */
/************** End of mutex.c ***********************************************/
/************** Begin file mutex_noop.c **************************************/
@@ -17051,286 +17899,10 @@ SQLITE_PRIVATE sqlite3_mutex_methods const *sqlite3NoopMutex(void){
SQLITE_PRIVATE sqlite3_mutex_methods const *sqlite3DefaultMutex(void){
return sqlite3NoopMutex();
}
-#endif /* SQLITE_MUTEX_NOOP */
-#endif /* SQLITE_MUTEX_OMIT */
+#endif /* defined(SQLITE_MUTEX_NOOP) */
+#endif /* !defined(SQLITE_MUTEX_OMIT) */
/************** End of mutex_noop.c ******************************************/
-/************** Begin file mutex_os2.c ***************************************/
-/*
-** 2007 August 28
-**
-** The author disclaims copyright to this source code. In place of
-** a legal notice, here is a blessing:
-**
-** May you do good and not evil.
-** May you find forgiveness for yourself and forgive others.
-** May you share freely, never taking more than you give.
-**
-*************************************************************************
-** This file contains the C functions that implement mutexes for OS/2
-*/
-
-/*
-** The code in this file is only used if SQLITE_MUTEX_OS2 is defined.
-** See the mutex.h file for details.
-*/
-#ifdef SQLITE_MUTEX_OS2
-
-/********************** OS/2 Mutex Implementation **********************
-**
-** This implementation of mutexes is built using the OS/2 API.
-*/
-
-/*
-** The mutex object
-** Each recursive mutex is an instance of the following structure.
-*/
-struct sqlite3_mutex {
- HMTX mutex; /* Mutex controlling the lock */
- int id; /* Mutex type */
-#ifdef SQLITE_DEBUG
- int trace; /* True to trace changes */
-#endif
-};
-
-#ifdef SQLITE_DEBUG
-#define SQLITE3_MUTEX_INITIALIZER { 0, 0, 0 }
-#else
-#define SQLITE3_MUTEX_INITIALIZER { 0, 0 }
-#endif
-
-/*
-** Initialize and deinitialize the mutex subsystem.
-*/
-static int os2MutexInit(void){ return SQLITE_OK; }
-static int os2MutexEnd(void){ return SQLITE_OK; }
-
-/*
-** The sqlite3_mutex_alloc() routine allocates a new
-** mutex and returns a pointer to it. If it returns NULL
-** that means that a mutex could not be allocated.
-** SQLite will unwind its stack and return an error. The argument
-** to sqlite3_mutex_alloc() is one of these integer constants:
-**
-** <ul>
-** <li> SQLITE_MUTEX_FAST
-** <li> SQLITE_MUTEX_RECURSIVE
-** <li> SQLITE_MUTEX_STATIC_MASTER
-** <li> SQLITE_MUTEX_STATIC_MEM
-** <li> SQLITE_MUTEX_STATIC_MEM2
-** <li> SQLITE_MUTEX_STATIC_PRNG
-** <li> SQLITE_MUTEX_STATIC_LRU
-** <li> SQLITE_MUTEX_STATIC_LRU2
-** </ul>
-**
-** The first two constants cause sqlite3_mutex_alloc() to create
-** a new mutex. The new mutex is recursive when SQLITE_MUTEX_RECURSIVE
-** is used but not necessarily so when SQLITE_MUTEX_FAST is used.
-** The mutex implementation does not need to make a distinction
-** between SQLITE_MUTEX_RECURSIVE and SQLITE_MUTEX_FAST if it does
-** not want to. But SQLite will only request a recursive mutex in
-** cases where it really needs one. If a faster non-recursive mutex
-** implementation is available on the host platform, the mutex subsystem
-** might return such a mutex in response to SQLITE_MUTEX_FAST.
-**
-** The other allowed parameters to sqlite3_mutex_alloc() each return
-** a pointer to a static preexisting mutex. Six static mutexes are
-** used by the current version of SQLite. Future versions of SQLite
-** may add additional static mutexes. Static mutexes are for internal
-** use by SQLite only. Applications that use SQLite mutexes should
-** use only the dynamic mutexes returned by SQLITE_MUTEX_FAST or
-** SQLITE_MUTEX_RECURSIVE.
-**
-** Note that if one of the dynamic mutex parameters (SQLITE_MUTEX_FAST
-** or SQLITE_MUTEX_RECURSIVE) is used then sqlite3_mutex_alloc()
-** returns a different mutex on every call. But for the static
-** mutex types, the same mutex is returned on every call that has
-** the same type number.
-*/
-static sqlite3_mutex *os2MutexAlloc(int iType){
- sqlite3_mutex *p = NULL;
- switch( iType ){
- case SQLITE_MUTEX_FAST:
- case SQLITE_MUTEX_RECURSIVE: {
- p = sqlite3MallocZero( sizeof(*p) );
- if( p ){
- p->id = iType;
- if( DosCreateMutexSem( 0, &p->mutex, 0, FALSE ) != NO_ERROR ){
- sqlite3_free( p );
- p = NULL;
- }
- }
- break;
- }
- default: {
- static volatile int isInit = 0;
- static sqlite3_mutex staticMutexes[6] = {
- SQLITE3_MUTEX_INITIALIZER,
- SQLITE3_MUTEX_INITIALIZER,
- SQLITE3_MUTEX_INITIALIZER,
- SQLITE3_MUTEX_INITIALIZER,
- SQLITE3_MUTEX_INITIALIZER,
- SQLITE3_MUTEX_INITIALIZER,
- };
- if ( !isInit ){
- APIRET rc;
- PTIB ptib;
- PPIB ppib;
- HMTX mutex;
- char name[32];
- DosGetInfoBlocks( &ptib, &ppib );
- sqlite3_snprintf( sizeof(name), name, "\\SEM32\\SQLITE%04x",
- ppib->pib_ulpid );
- while( !isInit ){
- mutex = 0;
- rc = DosCreateMutexSem( name, &mutex, 0, FALSE);
- if( rc == NO_ERROR ){
- unsigned int i;
- if( !isInit ){
- for( i = 0; i < sizeof(staticMutexes)/sizeof(staticMutexes[0]); i++ ){
- DosCreateMutexSem( 0, &staticMutexes[i].mutex, 0, FALSE );
- }
- isInit = 1;
- }
- DosCloseMutexSem( mutex );
- }else if( rc == ERROR_DUPLICATE_NAME ){
- DosSleep( 1 );
- }else{
- return p;
- }
- }
- }
- assert( iType-2 >= 0 );
- assert( iType-2 < sizeof(staticMutexes)/sizeof(staticMutexes[0]) );
- p = &staticMutexes[iType-2];
- p->id = iType;
- break;
- }
- }
- return p;
-}
-
-
-/*
-** This routine deallocates a previously allocated mutex.
-** SQLite is careful to deallocate every mutex that it allocates.
-*/
-static void os2MutexFree(sqlite3_mutex *p){
-#ifdef SQLITE_DEBUG
- TID tid;
- PID pid;
- ULONG ulCount;
- DosQueryMutexSem(p->mutex, &pid, &tid, &ulCount);
- assert( ulCount==0 );
- assert( p->id==SQLITE_MUTEX_FAST || p->id==SQLITE_MUTEX_RECURSIVE );
-#endif
- DosCloseMutexSem( p->mutex );
- sqlite3_free( p );
-}
-
-#ifdef SQLITE_DEBUG
-/*
-** The sqlite3_mutex_held() and sqlite3_mutex_notheld() routine are
-** intended for use inside assert() statements.
-*/
-static int os2MutexHeld(sqlite3_mutex *p){
- TID tid;
- PID pid;
- ULONG ulCount;
- PTIB ptib;
- DosQueryMutexSem(p->mutex, &pid, &tid, &ulCount);
- if( ulCount==0 || ( ulCount>1 && p->id!=SQLITE_MUTEX_RECURSIVE ) )
- return 0;
- DosGetInfoBlocks(&ptib, NULL);
- return tid==ptib->tib_ptib2->tib2_ultid;
-}
-static int os2MutexNotheld(sqlite3_mutex *p){
- TID tid;
- PID pid;
- ULONG ulCount;
- PTIB ptib;
- DosQueryMutexSem(p->mutex, &pid, &tid, &ulCount);
- if( ulCount==0 )
- return 1;
- DosGetInfoBlocks(&ptib, NULL);
- return tid!=ptib->tib_ptib2->tib2_ultid;
-}
-static void os2MutexTrace(sqlite3_mutex *p, char *pAction){
- TID tid;
- PID pid;
- ULONG ulCount;
- DosQueryMutexSem(p->mutex, &pid, &tid, &ulCount);
- printf("%s mutex %p (%d) with nRef=%ld\n", pAction, (void*)p, p->trace, ulCount);
-}
-#endif
-
-/*
-** The sqlite3_mutex_enter() and sqlite3_mutex_try() routines attempt
-** to enter a mutex. If another thread is already within the mutex,
-** sqlite3_mutex_enter() will block and sqlite3_mutex_try() will return
-** SQLITE_BUSY. The sqlite3_mutex_try() interface returns SQLITE_OK
-** upon successful entry. Mutexes created using SQLITE_MUTEX_RECURSIVE can
-** be entered multiple times by the same thread. In such cases the,
-** mutex must be exited an equal number of times before another thread
-** can enter. If the same thread tries to enter any other kind of mutex
-** more than once, the behavior is undefined.
-*/
-static void os2MutexEnter(sqlite3_mutex *p){
- assert( p->id==SQLITE_MUTEX_RECURSIVE || os2MutexNotheld(p) );
- DosRequestMutexSem(p->mutex, SEM_INDEFINITE_WAIT);
-#ifdef SQLITE_DEBUG
- if( p->trace ) os2MutexTrace(p, "enter");
-#endif
-}
-static int os2MutexTry(sqlite3_mutex *p){
- int rc = SQLITE_BUSY;
- assert( p->id==SQLITE_MUTEX_RECURSIVE || os2MutexNotheld(p) );
- if( DosRequestMutexSem(p->mutex, SEM_IMMEDIATE_RETURN) == NO_ERROR ) {
- rc = SQLITE_OK;
-#ifdef SQLITE_DEBUG
- if( p->trace ) os2MutexTrace(p, "try");
-#endif
- }
- return rc;
-}
-
-/*
-** The sqlite3_mutex_leave() routine exits a mutex that was
-** previously entered by the same thread. The behavior
-** is undefined if the mutex is not currently entered or
-** is not currently allocated. SQLite will never do either.
-*/
-static void os2MutexLeave(sqlite3_mutex *p){
- assert( os2MutexHeld(p) );
- DosReleaseMutexSem(p->mutex);
-#ifdef SQLITE_DEBUG
- if( p->trace ) os2MutexTrace(p, "leave");
-#endif
-}
-
-SQLITE_PRIVATE sqlite3_mutex_methods const *sqlite3DefaultMutex(void){
- static const sqlite3_mutex_methods sMutex = {
- os2MutexInit,
- os2MutexEnd,
- os2MutexAlloc,
- os2MutexFree,
- os2MutexEnter,
- os2MutexTry,
- os2MutexLeave,
-#ifdef SQLITE_DEBUG
- os2MutexHeld,
- os2MutexNotheld
-#else
- 0,
- 0
-#endif
- };
-
- return &sMutex;
-}
-#endif /* SQLITE_MUTEX_OS2 */
-
-/************** End of mutex_os2.c *******************************************/
/************** Begin file mutex_unix.c **************************************/
/*
** 2007 August 28
@@ -17681,7 +18253,7 @@ SQLITE_PRIVATE sqlite3_mutex_methods const *sqlite3DefaultMutex(void){
return &sMutex;
}
-#endif /* SQLITE_MUTEX_PTHREAD */
+#endif /* SQLITE_MUTEX_PTHREADS */
/************** End of mutex_unix.c ******************************************/
/************** Begin file mutex_w32.c ***************************************/
@@ -17742,7 +18314,7 @@ struct sqlite3_mutex {
** this out as well.
*/
#if 0
-#if SQLITE_OS_WINCE
+#if SQLITE_OS_WINCE || SQLITE_OS_WINRT
# define mutexIsNT() (1)
#else
static int mutexIsNT(void){
@@ -17795,18 +18367,24 @@ static int winMutex_isInit = 0;
*/
static long winMutex_lock = 0;
+SQLITE_API void sqlite3_win32_sleep(DWORD milliseconds); /* os_win.c */
+
static int winMutexInit(void){
/* The first to increment to 1 does actual initialization */
if( InterlockedCompareExchange(&winMutex_lock, 1, 0)==0 ){
int i;
for(i=0; i<ArraySize(winMutex_staticMutexes); i++){
+#if SQLITE_OS_WINRT
+ InitializeCriticalSectionEx(&winMutex_staticMutexes[i].mutex, 0, 0);
+#else
InitializeCriticalSection(&winMutex_staticMutexes[i].mutex);
+#endif
}
winMutex_isInit = 1;
}else{
/* Someone else is in the process of initing the static mutexes */
while( !winMutex_isInit ){
- Sleep(1);
+ sqlite3_win32_sleep(1);
}
}
return SQLITE_OK;
@@ -17880,7 +18458,11 @@ static sqlite3_mutex *winMutexAlloc(int iType){
#ifdef SQLITE_DEBUG
p->id = iType;
#endif
+#if SQLITE_OS_WINRT
+ InitializeCriticalSectionEx(&p->mutex, 0, 0);
+#else
InitializeCriticalSection(&p->mutex);
+#endif
}
break;
}
@@ -18033,6 +18615,7 @@ SQLITE_PRIVATE sqlite3_mutex_methods const *sqlite3DefaultMutex(void){
**
** Memory allocation functions used throughout sqlite.
*/
+/* #include <stdarg.h> */
/*
** Attempt to release up to n bytes of non-essential memory currently
@@ -18149,7 +18732,8 @@ SQLITE_API sqlite3_int64 sqlite3_soft_heap_limit64(sqlite3_int64 n){
sqlite3_int64 priorLimit;
sqlite3_int64 excess;
#ifndef SQLITE_OMIT_AUTOINIT
- sqlite3_initialize();
+ int rc = sqlite3_initialize();
+ if( rc ) return -1;
#endif
sqlite3_mutex_enter(mem0.mutex);
priorLimit = mem0.alarmThreshold;
@@ -18509,6 +19093,10 @@ SQLITE_PRIVATE void sqlite3DbFree(sqlite3 *db, void *p){
}
if( isLookaside(db, p) ){
LookasideSlot *pBuf = (LookasideSlot*)p;
+#if SQLITE_DEBUG
+ /* Trash all content in the buffer being freed */
+ memset(p, 0xaa, db->lookaside.sz);
+#endif
pBuf->pNext = db->lookaside.pFree;
db->lookaside.pFree = pBuf;
db->lookaside.nOut--;
@@ -18806,48 +19394,10 @@ SQLITE_PRIVATE int sqlite3ApiExit(sqlite3* db, int rc){
**
**************************************************************************
**
-** The following modules is an enhanced replacement for the "printf" subroutines
-** found in the standard C library. The following enhancements are
-** supported:
-**
-** + Additional functions. The standard set of "printf" functions
-** includes printf, fprintf, sprintf, vprintf, vfprintf, and
-** vsprintf. This module adds the following:
-**
-** * snprintf -- Works like sprintf, but has an extra argument
-** which is the size of the buffer written to.
-**
-** * mprintf -- Similar to sprintf. Writes output to memory
-** obtained from malloc.
-**
-** * xprintf -- Calls a function to dispose of output.
-**
-** * nprintf -- No output, but returns the number of characters
-** that would have been output by printf.
-**
-** * A v- version (ex: vsnprintf) of every function is also
-** supplied.
-**
-** + A few extensions to the formatting notation are supported:
-**
-** * The "=" flag (similar to "-") causes the output to be
-** be centered in the appropriately sized field.
-**
-** * The %b field outputs an integer in binary notation.
-**
-** * The %c field now accepts a precision. The character output
-** is repeated by the number of times the precision specifies.
-**
-** * The %' field works like %c, but takes as its character the
-** next character of the format string, instead of the next
-** argument. For example, printf("%.78'-") prints 78 minus
-** signs, the same as printf("%.78c",'-').
-**
-** + When compiled using GCC on a SPARC, this version of printf is
-** faster than the library printf for SUN OS 4.1.
-**
-** + All functions are fully reentrant.
-**
+** This file contains code for a set of "printf"-like routines. These
+** routines format strings much like the printf() from the standard C
+** library, though the implementation here has enhancements to support
+** SQLlite.
*/
/*
@@ -18960,7 +19510,8 @@ static const et_info fmtinfo[] = {
static char et_getdigit(LONGDOUBLE_TYPE *val, int *cnt){
int digit;
LONGDOUBLE_TYPE d;
- if( (*cnt)++ >= 16 ) return '0';
+ if( (*cnt)<=0 ) return '0';
+ (*cnt)--;
digit = (int)*val;
d = digit;
digit += '0';
@@ -18972,7 +19523,7 @@ static char et_getdigit(LONGDOUBLE_TYPE *val, int *cnt){
/*
** Append N space characters to the given string buffer.
*/
-static void appendSpace(StrAccum *pAccum, int N){
+SQLITE_PRIVATE void sqlite3AppendSpace(StrAccum *pAccum, int N){
static const char zSpaces[] = " ";
while( N>=(int)sizeof(zSpaces)-1 ){
sqlite3StrAccumAppend(pAccum, zSpaces, sizeof(zSpaces)-1);
@@ -18985,43 +19536,15 @@ static void appendSpace(StrAccum *pAccum, int N){
/*
** On machines with a small stack size, you can redefine the
-** SQLITE_PRINT_BUF_SIZE to be less than 350.
+** SQLITE_PRINT_BUF_SIZE to be something smaller, if desired.
*/
#ifndef SQLITE_PRINT_BUF_SIZE
-# if defined(SQLITE_SMALL_STACK)
-# define SQLITE_PRINT_BUF_SIZE 50
-# else
-# define SQLITE_PRINT_BUF_SIZE 350
-# endif
+# define SQLITE_PRINT_BUF_SIZE 70
#endif
#define etBUFSIZE SQLITE_PRINT_BUF_SIZE /* Size of the output buffer */
/*
-** The root program. All variations call this core.
-**
-** INPUTS:
-** func This is a pointer to a function taking three arguments
-** 1. A pointer to anything. Same as the "arg" parameter.
-** 2. A pointer to the list of characters to be output
-** (Note, this list is NOT null terminated.)
-** 3. An integer number of characters to be output.
-** (Note: This number might be zero.)
-**
-** arg This is the pointer to anything which will be passed as the
-** first argument to "func". Use it for whatever you like.
-**
-** fmt This is the format string, as in the usual print.
-**
-** ap This is a pointer to a list of arguments. Same as in
-** vfprint.
-**
-** OUTPUTS:
-** The return value is the total number of characters sent to
-** the function "func". Returns -1 on a error.
-**
-** Note that the order in which automatic variables are declared below
-** seems to make a big difference in determining how fast this beast
-** will run.
+** Render a string given by "fmt" into the StrAccum object.
*/
SQLITE_PRIVATE void sqlite3VXPrintf(
StrAccum *pAccum, /* Accumulate results here */
@@ -19044,23 +19567,23 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
etByte flag_long; /* True if "l" flag is present */
etByte flag_longlong; /* True if the "ll" flag is present */
etByte done; /* Loop termination flag */
+ etByte xtype = 0; /* Conversion paradigm */
+ char prefix; /* Prefix character. "+" or "-" or " " or '\0'. */
sqlite_uint64 longvalue; /* Value for integer types */
LONGDOUBLE_TYPE realvalue; /* Value for real types */
const et_info *infop; /* Pointer to the appropriate info structure */
- char buf[etBUFSIZE]; /* Conversion buffer */
- char prefix; /* Prefix character. "+" or "-" or " " or '\0'. */
- etByte xtype = 0; /* Conversion paradigm */
- char *zExtra; /* Extra memory used for etTCLESCAPE conversions */
+ char *zOut; /* Rendering buffer */
+ int nOut; /* Size of the rendering buffer */
+ char *zExtra; /* Malloced memory used by some conversion */
#ifndef SQLITE_OMIT_FLOATING_POINT
int exp, e2; /* exponent of real numbers */
+ int nsd; /* Number of significant digits returned */
double rounder; /* Used for rounding floating point values */
etByte flag_dp; /* True if decimal point should be shown */
etByte flag_rtz; /* True if trailing zeros should be removed */
- etByte flag_exp; /* True to force display of the exponent */
- int nsd; /* Number of significant digits returned */
#endif
+ char buf[etBUFSIZE]; /* Conversion buffer */
- length = 0;
bufpt = 0;
for(; (c=(*fmt))!=0; ++fmt){
if( c!='%' ){
@@ -19105,9 +19628,6 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
c = *++fmt;
}
}
- if( width > etBUFSIZE-10 ){
- width = etBUFSIZE-10;
- }
/* Get the precision */
if( c=='.' ){
precision = 0;
@@ -19154,12 +19674,6 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
}
zExtra = 0;
-
- /* Limit the precision to prevent overflowing buf[] during conversion */
- if( precision>etBUFSIZE-40 && (infop->flags & FLAG_STRING)==0 ){
- precision = etBUFSIZE-40;
- }
-
/*
** At this point, variables are initialized as follows:
**
@@ -19224,16 +19738,26 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
if( flag_zeropad && precision<width-(prefix!=0) ){
precision = width-(prefix!=0);
}
- bufpt = &buf[etBUFSIZE-1];
+ if( precision<etBUFSIZE-10 ){
+ nOut = etBUFSIZE;
+ zOut = buf;
+ }else{
+ nOut = precision + 10;
+ zOut = zExtra = sqlite3Malloc( nOut );
+ if( zOut==0 ){
+ pAccum->mallocFailed = 1;
+ return;
+ }
+ }
+ bufpt = &zOut[nOut-1];
if( xtype==etORDINAL ){
static const char zOrd[] = "thstndrd";
int x = (int)(longvalue % 10);
if( x>=4 || (longvalue/10)%10==1 ){
x = 0;
}
- buf[etBUFSIZE-3] = zOrd[x*2];
- buf[etBUFSIZE-2] = zOrd[x*2+1];
- bufpt -= 2;
+ *(--bufpt) = zOrd[x*2+1];
+ *(--bufpt) = zOrd[x*2];
}
{
register const char *cset; /* Use registers for speed */
@@ -19245,7 +19769,7 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
longvalue = longvalue/base;
}while( longvalue>0 );
}
- length = (int)(&buf[etBUFSIZE-1]-bufpt);
+ length = (int)(&zOut[nOut-1]-bufpt);
for(idx=precision-length; idx>0; idx--){
*(--bufpt) = '0'; /* Zero pad */
}
@@ -19256,7 +19780,7 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
pre = &aPrefix[infop->prefix];
for(; (x=(*pre))!=0; pre++) *(--bufpt) = x;
}
- length = (int)(&buf[etBUFSIZE-1]-bufpt);
+ length = (int)(&zOut[nOut-1]-bufpt);
break;
case etFLOAT:
case etEXP:
@@ -19266,7 +19790,6 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
length = 0;
#else
if( precision<0 ) precision = 6; /* Set default precision */
- if( precision>etBUFSIZE/2-10 ) precision = etBUFSIZE/2-10;
if( realvalue<0.0 ){
realvalue = -realvalue;
prefix = '-';
@@ -19292,9 +19815,12 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
break;
}
if( realvalue>0.0 ){
- while( realvalue>=1e32 && exp<=350 ){ realvalue *= 1e-32; exp+=32; }
- while( realvalue>=1e8 && exp<=350 ){ realvalue *= 1e-8; exp+=8; }
- while( realvalue>=10.0 && exp<=350 ){ realvalue *= 0.1; exp++; }
+ LONGDOUBLE_TYPE scale = 1.0;
+ while( realvalue>=1e100*scale && exp<=350 ){ scale *= 1e100;exp+=100;}
+ while( realvalue>=1e64*scale && exp<=350 ){ scale *= 1e64; exp+=64; }
+ while( realvalue>=1e8*scale && exp<=350 ){ scale *= 1e8; exp+=8; }
+ while( realvalue>=10.0*scale && exp<=350 ){ scale *= 10.0; exp++; }
+ realvalue /= scale;
while( realvalue<1e-8 ){ realvalue *= 1e8; exp-=8; }
while( realvalue<1.0 ){ realvalue *= 10.0; exp--; }
if( exp>350 ){
@@ -19314,7 +19840,6 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
** If the field type is etGENERIC, then convert to either etEXP
** or etFLOAT, as appropriate.
*/
- flag_exp = xtype==etEXP;
if( xtype!=etFLOAT ){
realvalue += rounder;
if( realvalue>=10.0 ){ realvalue *= 0.1; exp++; }
@@ -19328,14 +19853,22 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
xtype = etFLOAT;
}
}else{
- flag_rtz = 0;
+ flag_rtz = flag_altform2;
}
if( xtype==etEXP ){
e2 = 0;
}else{
e2 = exp;
}
- nsd = 0;
+ if( e2+precision+width > etBUFSIZE - 15 ){
+ bufpt = zExtra = sqlite3Malloc( e2+precision+width+15 );
+ if( bufpt==0 ){
+ pAccum->mallocFailed = 1;
+ return;
+ }
+ }
+ zOut = bufpt;
+ nsd = 16 + flag_altform2*10;
flag_dp = (precision>0 ?1:0) | flag_alternateform | flag_altform2;
/* The sign in front of the number */
if( prefix ){
@@ -19366,7 +19899,7 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
/* Remove trailing zeros and the "." if no digits follow the "." */
if( flag_rtz && flag_dp ){
while( bufpt[-1]=='0' ) *(--bufpt) = 0;
- assert( bufpt>buf );
+ assert( bufpt>zOut );
if( bufpt[-1]=='.' ){
if( flag_altform2 ){
*(bufpt++) = '0';
@@ -19376,7 +19909,7 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
}
}
/* Add the "eNNN" suffix */
- if( flag_exp || xtype==etEXP ){
+ if( xtype==etEXP ){
*(bufpt++) = aDigits[infop->charset];
if( exp<0 ){
*(bufpt++) = '-'; exp = -exp;
@@ -19395,8 +19928,8 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
/* The converted number is in buf[] and zero terminated. Output it.
** Note that the number is in the usual order, not reversed as with
** integer conversions. */
- length = (int)(bufpt-buf);
- bufpt = buf;
+ length = (int)(bufpt-zOut);
+ bufpt = zOut;
/* Special case: Add leading zeros if the flag_zeropad flag is
** set and we are not left justified */
@@ -19521,7 +20054,7 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
register int nspace;
nspace = width-length;
if( nspace>0 ){
- appendSpace(pAccum, nspace);
+ sqlite3AppendSpace(pAccum, nspace);
}
}
if( length>0 ){
@@ -19531,12 +20064,10 @@ SQLITE_PRIVATE void sqlite3VXPrintf(
register int nspace;
nspace = width-length;
if( nspace>0 ){
- appendSpace(pAccum, nspace);
+ sqlite3AppendSpace(pAccum, nspace);
}
}
- if( zExtra ){
- sqlite3_free(zExtra);
- }
+ sqlite3_free(zExtra);
}/* End for loop over the format string */
} /* End of function */
@@ -19550,6 +20081,7 @@ SQLITE_PRIVATE void sqlite3StrAccumAppend(StrAccum *p, const char *z, int N){
testcase(p->mallocFailed);
return;
}
+ assert( p->zText!=0 || p->nChar==0 );
if( N<0 ){
N = sqlite3Strlen30(z);
}
@@ -19581,7 +20113,7 @@ SQLITE_PRIVATE void sqlite3StrAccumAppend(StrAccum *p, const char *z, int N){
zNew = sqlite3_realloc(zOld, p->nAlloc);
}
if( zNew ){
- if( zOld==0 ) memcpy(zNew, p->zText, p->nChar);
+ if( zOld==0 && p->nChar>0 ) memcpy(zNew, p->zText, p->nChar);
p->zText = zNew;
}else{
p->mallocFailed = 1;
@@ -19590,6 +20122,7 @@ SQLITE_PRIVATE void sqlite3StrAccumAppend(StrAccum *p, const char *z, int N){
}
}
}
+ assert( p->zText );
memcpy(&p->zText[p->nChar], z, N);
p->nChar += N;
}
@@ -20010,6 +20543,7 @@ SQLITE_PRIVATE void sqlite3PrngResetState(void){
** 0xfe 0xff big-endian utf-16 follows
**
*/
+/* #include <assert.h> */
#ifndef SQLITE_AMALGAMATION
/*
@@ -20138,25 +20672,23 @@ static const unsigned char sqlite3Utf8Trans1[] = {
|| (c&0xFFFFFFFE)==0xFFFE ){ c = 0xFFFD; } \
}
SQLITE_PRIVATE u32 sqlite3Utf8Read(
- const unsigned char *zIn, /* First byte of UTF-8 character */
- const unsigned char **pzNext /* Write first byte past UTF-8 char here */
+ const unsigned char **pz /* Pointer to string from which to read char */
){
unsigned int c;
/* Same as READ_UTF8() above but without the zTerm parameter.
** For this routine, we assume the UTF8 string is always zero-terminated.
*/
- c = *(zIn++);
+ c = *((*pz)++);
if( c>=0xc0 ){
c = sqlite3Utf8Trans1[c-0xc0];
- while( (*zIn & 0xc0)==0x80 ){
- c = (c<<6) + (0x3f & *(zIn++));
+ while( (*(*pz) & 0xc0)==0x80 ){
+ c = (c<<6) + (0x3f & *((*pz)++));
}
if( c<0x80
|| (c&0xFFFFF800)==0xD800
|| (c&0xFFFFFFFE)==0xFFFE ){ c = 0xFFFD; }
}
- *pzNext = zIn;
return c;
}
@@ -20257,7 +20789,6 @@ SQLITE_PRIVATE int sqlite3VdbeMemTranslate(Mem *pMem, u8 desiredEnc){
if( desiredEnc==SQLITE_UTF16LE ){
/* UTF-8 -> UTF-16 Little-endian */
while( zIn<zTerm ){
- /* c = sqlite3Utf8Read(zIn, zTerm, (const u8**)&zIn); */
READ_UTF8(zIn, zTerm, c);
WRITE_UTF16LE(z, c);
}
@@ -20265,7 +20796,6 @@ SQLITE_PRIVATE int sqlite3VdbeMemTranslate(Mem *pMem, u8 desiredEnc){
assert( desiredEnc==SQLITE_UTF16BE );
/* UTF-8 -> UTF-16 Big-endian */
while( zIn<zTerm ){
- /* c = sqlite3Utf8Read(zIn, zTerm, (const u8**)&zIn); */
READ_UTF8(zIn, zTerm, c);
WRITE_UTF16BE(z, c);
}
@@ -20393,7 +20923,7 @@ SQLITE_PRIVATE int sqlite3Utf8To8(unsigned char *zIn){
u32 c;
while( zIn[0] && zOut<=zIn ){
- c = sqlite3Utf8Read(zIn, (const u8**)&zIn);
+ c = sqlite3Utf8Read((const u8**)&zIn);
if( c!=0xfffd ){
WRITE_UTF8(zOut, c);
}
@@ -20438,7 +20968,7 @@ SQLITE_PRIVATE char *sqlite3Utf16to8(sqlite3 *db, const void *z, int nByte, u8 e
** If a malloc failure occurs, NULL is returned and the db.mallocFailed
** flag set.
*/
-#ifdef SQLITE_ENABLE_STAT2
+#ifdef SQLITE_ENABLE_STAT3
SQLITE_PRIVATE char *sqlite3Utf8to16(sqlite3 *db, u8 enc, char *z, int n, int *pnOut){
Mem m;
memset(&m, 0, sizeof(m));
@@ -20498,7 +21028,7 @@ SQLITE_PRIVATE void sqlite3UtfSelfTest(void){
assert( n>0 && n<=4 );
z[0] = 0;
z = zBuf;
- c = sqlite3Utf8Read(z, (const u8**)&z);
+ c = sqlite3Utf8Read((const u8**)&z);
t = i;
if( i>=0xD800 && i<=0xDFFF ) t = 0xFFFD;
if( (i&0xFFFFFFFE)==0xFFFE ) t = 0xFFFD;
@@ -20552,6 +21082,7 @@ SQLITE_PRIVATE void sqlite3UtfSelfTest(void){
** strings, and stuff like that.
**
*/
+/* #include <stdarg.h> */
#ifdef SQLITE_HAVE_ISNAN
# include <math.h>
#endif
@@ -20751,13 +21282,13 @@ SQLITE_PRIVATE int sqlite3Dequote(char *z){
** Some systems have stricmp(). Others have strcasecmp(). Because
** there is no consistency, we will define our own.
**
-** IMPLEMENTATION-OF: R-20522-24639 The sqlite3_strnicmp() API allows
-** applications and extensions to compare the contents of two buffers
-** containing UTF-8 strings in a case-independent fashion, using the same
-** definition of case independence that SQLite uses internally when
-** comparing identifiers.
+** IMPLEMENTATION-OF: R-30243-02494 The sqlite3_stricmp() and
+** sqlite3_strnicmp() APIs allow applications and extensions to compare
+** the contents of two buffers containing UTF-8 strings in a
+** case-independent fashion, using the same definition of "case
+** independence" that SQLite uses internally when comparing identifiers.
*/
-SQLITE_PRIVATE int sqlite3StrICmp(const char *zLeft, const char *zRight){
+SQLITE_API int sqlite3_stricmp(const char *zLeft, const char *zRight){
register unsigned char *a, *b;
a = (unsigned char *)zLeft;
b = (unsigned char *)zRight;
@@ -20796,7 +21327,7 @@ SQLITE_API int sqlite3_strnicmp(const char *zLeft, const char *zRight, int N){
*/
SQLITE_PRIVATE int sqlite3AtoF(const char *z, double *pResult, int length, u8 enc){
#ifndef SQLITE_OMIT_FLOATING_POINT
- int incr = (enc==SQLITE_UTF8?1:2);
+ int incr;
const char *zEnd = z + length;
/* sign * significand * (10 ^ (esign * exponent)) */
int sign = 1; /* sign of significand */
@@ -20807,10 +21338,22 @@ SQLITE_PRIVATE int sqlite3AtoF(const char *z, double *pResult, int length, u8 en
int eValid = 1; /* True exponent is either not used or is well-formed */
double result;
int nDigits = 0;
+ int nonNum = 0;
+ assert( enc==SQLITE_UTF8 || enc==SQLITE_UTF16LE || enc==SQLITE_UTF16BE );
*pResult = 0.0; /* Default return value, in case of an error */
- if( enc==SQLITE_UTF16BE ) z++;
+ if( enc==SQLITE_UTF8 ){
+ incr = 1;
+ }else{
+ int i;
+ incr = 2;
+ assert( SQLITE_UTF16LE==2 && SQLITE_UTF16BE==3 );
+ for(i=3-enc; i<length && z[i]==0; i+=2){}
+ nonNum = i<length;
+ zEnd = z+i+enc-3;
+ z += (enc&1);
+ }
/* skip leading spaces */
while( z<zEnd && sqlite3Isspace(*z) ) z+=incr;
@@ -20866,7 +21409,7 @@ SQLITE_PRIVATE int sqlite3AtoF(const char *z, double *pResult, int length, u8 en
}
/* copy digits to exponent */
while( z<zEnd && sqlite3Isdigit(*z) ){
- e = e*10 + (*z - '0');
+ e = e<10000 ? (e*10 + (*z - '0')) : 10000;
z+=incr;
eValid = 1;
}
@@ -20906,7 +21449,7 @@ do_atof_calc:
/* if exponent, scale significand as appropriate
** and store in result. */
if( e ){
- double scale = 1.0;
+ LONGDOUBLE_TYPE scale = 1.0;
/* attempt to handle extremely small/large numbers better */
if( e>307 && e<342 ){
while( e%308 ) { scale *= 1.0e+1; e -= 1; }
@@ -20917,6 +21460,12 @@ do_atof_calc:
result = s * scale;
result *= 1.0e+308;
}
+ }else if( e>=342 ){
+ if( esign<0 ){
+ result = 0.0*s;
+ }else{
+ result = 1e308*1e308*s; /* Infinity */
+ }
}else{
/* 1.0e+22 is the largest power of 10 than can be
** represented exactly. */
@@ -20937,7 +21486,7 @@ do_atof_calc:
*pResult = result;
/* return true if number and no extra non-whitespace chracters after */
- return z>=zEnd && nDigits>0 && eValid;
+ return z>=zEnd && nDigits>0 && eValid && nonNum==0;
#else
return !sqlite3Atoi64(z, pResult, length, enc);
#endif /* SQLITE_OMIT_FLOATING_POINT */
@@ -20986,21 +21535,33 @@ static int compare2pow63(const char *zNum, int incr){
** signed 64-bit integer, its negative -9223372036854665808 can be.
**
** If zNum is too big for a 64-bit integer and is not
-** 9223372036854665808 then return 1.
+** 9223372036854665808 or if zNum contains any non-numeric text,
+** then return 1.
**
** length is the number of bytes in the string (bytes, not characters).
** The string is not necessarily zero-terminated. The encoding is
** given by enc.
*/
SQLITE_PRIVATE int sqlite3Atoi64(const char *zNum, i64 *pNum, int length, u8 enc){
- int incr = (enc==SQLITE_UTF8?1:2);
+ int incr;
u64 u = 0;
int neg = 0; /* assume positive */
int i;
int c = 0;
+ int nonNum = 0;
const char *zStart;
const char *zEnd = zNum + length;
- if( enc==SQLITE_UTF16BE ) zNum++;
+ assert( enc==SQLITE_UTF8 || enc==SQLITE_UTF16LE || enc==SQLITE_UTF16BE );
+ if( enc==SQLITE_UTF8 ){
+ incr = 1;
+ }else{
+ incr = 2;
+ assert( SQLITE_UTF16LE==2 && SQLITE_UTF16BE==3 );
+ for(i=3-enc; i<length && zNum[i]==0; i+=2){}
+ nonNum = i<length;
+ zEnd = zNum+i+enc-3;
+ zNum += (enc&1);
+ }
while( zNum<zEnd && sqlite3Isspace(*zNum) ) zNum+=incr;
if( zNum<zEnd ){
if( *zNum=='-' ){
@@ -21025,7 +21586,7 @@ SQLITE_PRIVATE int sqlite3Atoi64(const char *zNum, i64 *pNum, int length, u8 enc
testcase( i==18 );
testcase( i==19 );
testcase( i==20 );
- if( (c!=0 && &zNum[i]<zEnd) || (i==0 && zStart==zNum) || i>19*incr ){
+ if( (c!=0 && &zNum[i]<zEnd) || (i==0 && zStart==zNum) || i>19*incr || nonNum ){
/* zNum is empty or contains non-numeric text or is longer
** than 19 digits (thus guaranteeing that it is too large) */
return 1;
@@ -21684,26 +22245,31 @@ SQLITE_PRIVATE int sqlite3AbsInt32(int x){
#ifdef SQLITE_ENABLE_8_3_NAMES
/*
-** If SQLITE_ENABLE_8_3_NAME is set at compile-time and if the database
+** If SQLITE_ENABLE_8_3_NAMES is set at compile-time and if the database
** filename in zBaseFilename is a URI with the "8_3_names=1" parameter and
** if filename in z[] has a suffix (a.k.a. "extension") that is longer than
** three characters, then shorten the suffix on z[] to be the last three
** characters of the original suffix.
**
+** If SQLITE_ENABLE_8_3_NAMES is set to 2 at compile-time, then always
+** do the suffix shortening regardless of URI parameter.
+**
** Examples:
**
** test.db-journal => test.nal
** test.db-wal => test.wal
** test.db-shm => test.shm
+** test.db-mj7f3319fa => test.9fa
*/
SQLITE_PRIVATE void sqlite3FileSuffix3(const char *zBaseFilename, char *z){
- const char *zOk;
- zOk = sqlite3_uri_parameter(zBaseFilename, "8_3_names");
- if( zOk && sqlite3GetBoolean(zOk) ){
+#if SQLITE_ENABLE_8_3_NAMES<2
+ if( sqlite3_uri_boolean(zBaseFilename, "8_3_names", 0) )
+#endif
+ {
int i, sz;
sz = sqlite3Strlen30(z);
for(i=sz-1; i>0 && z[i]!='/' && z[i]!='.'; i--){}
- if( z[i]=='.' && ALWAYS(sz>i+4) ) memcpy(&z[i+1], &z[sz-3], 4);
+ if( z[i]=='.' && ALWAYS(sz>i+4) ) memmove(&z[i+1], &z[sz-3], 4);
}
}
#endif
@@ -21724,6 +22290,7 @@ SQLITE_PRIVATE void sqlite3FileSuffix3(const char *zBaseFilename, char *z){
** This is the implementation of generic hash-tables
** used in SQLite.
*/
+/* #include <assert.h> */
/* Turn bulk memory into a hash table object by initializing the
** fields of the Hash structure.
@@ -21823,7 +22390,11 @@ static int rehash(Hash *pH, unsigned int new_size){
/* The inability to allocates space for a larger hash table is
** a performance hit but it is not a fatal error. So mark the
- ** allocation as a benign.
+ ** allocation as a benign. Use sqlite3Malloc()/memset(0) instead of
+ ** sqlite3MallocZero() to make the allocation, as sqlite3MallocZero()
+ ** only zeroes the requested number of bytes whereas this module will
+ ** use the actual amount of space allocated for the hash table (which
+ ** may be larger than the requested amount).
*/
sqlite3BeginBenignMalloc();
new_ht = (struct _ht *)sqlite3Malloc( new_size*sizeof(struct _ht) );
@@ -21899,7 +22470,7 @@ static void removeElementGivenHash(
}
sqlite3_free( elem );
pH->count--;
- if( pH->count<=0 ){
+ if( pH->count==0 ){
assert( pH->first==0 );
assert( pH->count==0 );
sqlite3HashClear(pH);
@@ -22018,53 +22589,53 @@ SQLITE_PRIVATE const char *sqlite3OpcodeName(int i){
/* 23 */ "Permutation",
/* 24 */ "Compare",
/* 25 */ "Jump",
- /* 26 */ "If",
- /* 27 */ "IfNot",
- /* 28 */ "Column",
- /* 29 */ "Affinity",
- /* 30 */ "MakeRecord",
- /* 31 */ "Count",
- /* 32 */ "Savepoint",
- /* 33 */ "AutoCommit",
- /* 34 */ "Transaction",
- /* 35 */ "ReadCookie",
- /* 36 */ "SetCookie",
- /* 37 */ "VerifyCookie",
- /* 38 */ "OpenRead",
- /* 39 */ "OpenWrite",
- /* 40 */ "OpenAutoindex",
- /* 41 */ "OpenEphemeral",
- /* 42 */ "OpenPseudo",
- /* 43 */ "Close",
- /* 44 */ "SeekLt",
- /* 45 */ "SeekLe",
- /* 46 */ "SeekGe",
- /* 47 */ "SeekGt",
- /* 48 */ "Seek",
- /* 49 */ "NotFound",
- /* 50 */ "Found",
- /* 51 */ "IsUnique",
- /* 52 */ "NotExists",
- /* 53 */ "Sequence",
- /* 54 */ "NewRowid",
- /* 55 */ "Insert",
- /* 56 */ "InsertInt",
- /* 57 */ "Delete",
- /* 58 */ "ResetCount",
- /* 59 */ "RowKey",
- /* 60 */ "RowData",
- /* 61 */ "Rowid",
- /* 62 */ "NullRow",
- /* 63 */ "Last",
- /* 64 */ "Sort",
- /* 65 */ "Rewind",
- /* 66 */ "Prev",
- /* 67 */ "Next",
+ /* 26 */ "Once",
+ /* 27 */ "If",
+ /* 28 */ "IfNot",
+ /* 29 */ "Column",
+ /* 30 */ "Affinity",
+ /* 31 */ "MakeRecord",
+ /* 32 */ "Count",
+ /* 33 */ "Savepoint",
+ /* 34 */ "AutoCommit",
+ /* 35 */ "Transaction",
+ /* 36 */ "ReadCookie",
+ /* 37 */ "SetCookie",
+ /* 38 */ "VerifyCookie",
+ /* 39 */ "OpenRead",
+ /* 40 */ "OpenWrite",
+ /* 41 */ "OpenAutoindex",
+ /* 42 */ "OpenEphemeral",
+ /* 43 */ "SorterOpen",
+ /* 44 */ "OpenPseudo",
+ /* 45 */ "Close",
+ /* 46 */ "SeekLt",
+ /* 47 */ "SeekLe",
+ /* 48 */ "SeekGe",
+ /* 49 */ "SeekGt",
+ /* 50 */ "Seek",
+ /* 51 */ "NotFound",
+ /* 52 */ "Found",
+ /* 53 */ "IsUnique",
+ /* 54 */ "NotExists",
+ /* 55 */ "Sequence",
+ /* 56 */ "NewRowid",
+ /* 57 */ "Insert",
+ /* 58 */ "InsertInt",
+ /* 59 */ "Delete",
+ /* 60 */ "ResetCount",
+ /* 61 */ "SorterCompare",
+ /* 62 */ "SorterData",
+ /* 63 */ "RowKey",
+ /* 64 */ "RowData",
+ /* 65 */ "Rowid",
+ /* 66 */ "NullRow",
+ /* 67 */ "Last",
/* 68 */ "Or",
/* 69 */ "And",
- /* 70 */ "IdxInsert",
- /* 71 */ "IdxDelete",
- /* 72 */ "IdxRowid",
+ /* 70 */ "SorterSort",
+ /* 71 */ "Sort",
+ /* 72 */ "Rewind",
/* 73 */ "IsNull",
/* 74 */ "NotNull",
/* 75 */ "Ne",
@@ -22073,7 +22644,7 @@ SQLITE_PRIVATE const char *sqlite3OpcodeName(int i){
/* 78 */ "Le",
/* 79 */ "Lt",
/* 80 */ "Ge",
- /* 81 */ "IdxLT",
+ /* 81 */ "SorterNext",
/* 82 */ "BitAnd",
/* 83 */ "BitOr",
/* 84 */ "ShiftLeft",
@@ -22084,2197 +22655,71 @@ SQLITE_PRIVATE const char *sqlite3OpcodeName(int i){
/* 89 */ "Divide",
/* 90 */ "Remainder",
/* 91 */ "Concat",
- /* 92 */ "IdxGE",
+ /* 92 */ "Prev",
/* 93 */ "BitNot",
/* 94 */ "String8",
- /* 95 */ "Destroy",
- /* 96 */ "Clear",
- /* 97 */ "CreateIndex",
- /* 98 */ "CreateTable",
- /* 99 */ "ParseSchema",
- /* 100 */ "LoadAnalysis",
- /* 101 */ "DropTable",
- /* 102 */ "DropIndex",
- /* 103 */ "DropTrigger",
- /* 104 */ "IntegrityCk",
- /* 105 */ "RowSetAdd",
- /* 106 */ "RowSetRead",
- /* 107 */ "RowSetTest",
- /* 108 */ "Program",
- /* 109 */ "Param",
- /* 110 */ "FkCounter",
- /* 111 */ "FkIfZero",
- /* 112 */ "MemMax",
- /* 113 */ "IfPos",
- /* 114 */ "IfNeg",
- /* 115 */ "IfZero",
- /* 116 */ "AggStep",
- /* 117 */ "AggFinal",
- /* 118 */ "Checkpoint",
- /* 119 */ "JournalMode",
- /* 120 */ "Vacuum",
- /* 121 */ "IncrVacuum",
- /* 122 */ "Expire",
- /* 123 */ "TableLock",
- /* 124 */ "VBegin",
- /* 125 */ "VCreate",
- /* 126 */ "VDestroy",
- /* 127 */ "VOpen",
- /* 128 */ "VFilter",
- /* 129 */ "VColumn",
+ /* 95 */ "Next",
+ /* 96 */ "SorterInsert",
+ /* 97 */ "IdxInsert",
+ /* 98 */ "IdxDelete",
+ /* 99 */ "IdxRowid",
+ /* 100 */ "IdxLT",
+ /* 101 */ "IdxGE",
+ /* 102 */ "Destroy",
+ /* 103 */ "Clear",
+ /* 104 */ "CreateIndex",
+ /* 105 */ "CreateTable",
+ /* 106 */ "ParseSchema",
+ /* 107 */ "LoadAnalysis",
+ /* 108 */ "DropTable",
+ /* 109 */ "DropIndex",
+ /* 110 */ "DropTrigger",
+ /* 111 */ "IntegrityCk",
+ /* 112 */ "RowSetAdd",
+ /* 113 */ "RowSetRead",
+ /* 114 */ "RowSetTest",
+ /* 115 */ "Program",
+ /* 116 */ "Param",
+ /* 117 */ "FkCounter",
+ /* 118 */ "FkIfZero",
+ /* 119 */ "MemMax",
+ /* 120 */ "IfPos",
+ /* 121 */ "IfNeg",
+ /* 122 */ "IfZero",
+ /* 123 */ "AggStep",
+ /* 124 */ "AggFinal",
+ /* 125 */ "Checkpoint",
+ /* 126 */ "JournalMode",
+ /* 127 */ "Vacuum",
+ /* 128 */ "IncrVacuum",
+ /* 129 */ "Expire",
/* 130 */ "Real",
- /* 131 */ "VNext",
- /* 132 */ "VRename",
- /* 133 */ "VUpdate",
- /* 134 */ "Pagecount",
- /* 135 */ "MaxPgcnt",
- /* 136 */ "Trace",
- /* 137 */ "Noop",
- /* 138 */ "Explain",
- /* 139 */ "NotUsed_139",
- /* 140 */ "NotUsed_140",
+ /* 131 */ "TableLock",
+ /* 132 */ "VBegin",
+ /* 133 */ "VCreate",
+ /* 134 */ "VDestroy",
+ /* 135 */ "VOpen",
+ /* 136 */ "VFilter",
+ /* 137 */ "VColumn",
+ /* 138 */ "VNext",
+ /* 139 */ "VRename",
+ /* 140 */ "VUpdate",
/* 141 */ "ToText",
/* 142 */ "ToBlob",
/* 143 */ "ToNumeric",
/* 144 */ "ToInt",
/* 145 */ "ToReal",
+ /* 146 */ "Pagecount",
+ /* 147 */ "MaxPgcnt",
+ /* 148 */ "Trace",
+ /* 149 */ "Noop",
+ /* 150 */ "Explain",
};
return azName[i];
}
#endif
/************** End of opcodes.c *********************************************/
-/************** Begin file os_os2.c ******************************************/
-/*
-** 2006 Feb 14
-**
-** The author disclaims copyright to this source code. In place of
-** a legal notice, here is a blessing:
-**
-** May you do good and not evil.
-** May you find forgiveness for yourself and forgive others.
-** May you share freely, never taking more than you give.
-**
-******************************************************************************
-**
-** This file contains code that is specific to OS/2.
-*/
-
-
-#if SQLITE_OS_OS2
-
-/*
-** A Note About Memory Allocation:
-**
-** This driver uses malloc()/free() directly rather than going through
-** the SQLite-wrappers sqlite3_malloc()/sqlite3_free(). Those wrappers
-** are designed for use on embedded systems where memory is scarce and
-** malloc failures happen frequently. OS/2 does not typically run on
-** embedded systems, and when it does the developers normally have bigger
-** problems to worry about than running out of memory. So there is not
-** a compelling need to use the wrappers.
-**
-** But there is a good reason to not use the wrappers. If we use the
-** wrappers then we will get simulated malloc() failures within this
-** driver. And that causes all kinds of problems for our tests. We
-** could enhance SQLite to deal with simulated malloc failures within
-** the OS driver, but the code to deal with those failure would not
-** be exercised on Linux (which does not need to malloc() in the driver)
-** and so we would have difficulty writing coverage tests for that
-** code. Better to leave the code out, we think.
-**
-** The point of this discussion is as follows: When creating a new
-** OS layer for an embedded system, if you use this file as an example,
-** avoid the use of malloc()/free(). Those routines work ok on OS/2
-** desktops but not so well in embedded systems.
-*/
-
-/*
-** Macros used to determine whether or not to use threads.
-*/
-#if defined(SQLITE_THREADSAFE) && SQLITE_THREADSAFE
-# define SQLITE_OS2_THREADS 1
-#endif
-
-/*
-** Include code that is common to all os_*.c files
-*/
-/************** Include os_common.h in the middle of os_os2.c ****************/
-/************** Begin file os_common.h ***************************************/
-/*
-** 2004 May 22
-**
-** The author disclaims copyright to this source code. In place of
-** a legal notice, here is a blessing:
-**
-** May you do good and not evil.
-** May you find forgiveness for yourself and forgive others.
-** May you share freely, never taking more than you give.
-**
-******************************************************************************
-**
-** This file contains macros and a little bit of code that is common to
-** all of the platform-specific files (os_*.c) and is #included into those
-** files.
-**
-** This file should be #included by the os_*.c files only. It is not a
-** general purpose header file.
-*/
-#ifndef _OS_COMMON_H_
-#define _OS_COMMON_H_
-
-/*
-** At least two bugs have slipped in because we changed the MEMORY_DEBUG
-** macro to SQLITE_DEBUG and some older makefiles have not yet made the
-** switch. The following code should catch this problem at compile-time.
-*/
-#ifdef MEMORY_DEBUG
-# error "The MEMORY_DEBUG macro is obsolete. Use SQLITE_DEBUG instead."
-#endif
-
-#ifdef SQLITE_DEBUG
-SQLITE_PRIVATE int sqlite3OSTrace = 0;
-#define OSTRACE(X) if( sqlite3OSTrace ) sqlite3DebugPrintf X
-#else
-#define OSTRACE(X)
-#endif
-
-/*
-** Macros for performance tracing. Normally turned off. Only works
-** on i486 hardware.
-*/
-#ifdef SQLITE_PERFORMANCE_TRACE
-
-/*
-** hwtime.h contains inline assembler code for implementing
-** high-performance timing routines.
-*/
-/************** Include hwtime.h in the middle of os_common.h ****************/
-/************** Begin file hwtime.h ******************************************/
-/*
-** 2008 May 27
-**
-** The author disclaims copyright to this source code. In place of
-** a legal notice, here is a blessing:
-**
-** May you do good and not evil.
-** May you find forgiveness for yourself and forgive others.
-** May you share freely, never taking more than you give.
-**
-******************************************************************************
-**
-** This file contains inline asm code for retrieving "high-performance"
-** counters for x86 class CPUs.
-*/
-#ifndef _HWTIME_H_
-#define _HWTIME_H_
-
-/*
-** The following routine only works on pentium-class (or newer) processors.
-** It uses the RDTSC opcode to read the cycle count value out of the
-** processor and returns that value. This can be used for high-res
-** profiling.
-*/
-#if (defined(__GNUC__) || defined(_MSC_VER)) && \
- (defined(i386) || defined(__i386__) || defined(_M_IX86))
-
- #if defined(__GNUC__)
-
- __inline__ sqlite_uint64 sqlite3Hwtime(void){
- unsigned int lo, hi;
- __asm__ __volatile__ ("rdtsc" : "=a" (lo), "=d" (hi));
- return (sqlite_uint64)hi << 32 | lo;
- }
-
- #elif defined(_MSC_VER)
-
- __declspec(naked) __inline sqlite_uint64 __cdecl sqlite3Hwtime(void){
- __asm {
- rdtsc
- ret ; return value at EDX:EAX
- }
- }
-
- #endif
-
-#elif (defined(__GNUC__) && defined(__x86_64__))
-
- __inline__ sqlite_uint64 sqlite3Hwtime(void){
- unsigned long val;
- __asm__ __volatile__ ("rdtsc" : "=A" (val));
- return val;
- }
-
-#elif (defined(__GNUC__) && defined(__ppc__))
-
- __inline__ sqlite_uint64 sqlite3Hwtime(void){
- unsigned long long retval;
- unsigned long junk;
- __asm__ __volatile__ ("\n\
- 1: mftbu %1\n\
- mftb %L0\n\
- mftbu %0\n\
- cmpw %0,%1\n\
- bne 1b"
- : "=r" (retval), "=r" (junk));
- return retval;
- }
-
-#else
-
- #error Need implementation of sqlite3Hwtime() for your platform.
-
- /*
- ** To compile without implementing sqlite3Hwtime() for your platform,
- ** you can remove the above #error and use the following
- ** stub function. You will lose timing support for many
- ** of the debugging and testing utilities, but it should at
- ** least compile and run.
- */
-SQLITE_PRIVATE sqlite_uint64 sqlite3Hwtime(void){ return ((sqlite_uint64)0); }
-
-#endif
-
-#endif /* !defined(_HWTIME_H_) */
-
-/************** End of hwtime.h **********************************************/
-/************** Continuing where we left off in os_common.h ******************/
-
-static sqlite_uint64 g_start;
-static sqlite_uint64 g_elapsed;
-#define TIMER_START g_start=sqlite3Hwtime()
-#define TIMER_END g_elapsed=sqlite3Hwtime()-g_start
-#define TIMER_ELAPSED g_elapsed
-#else
-#define TIMER_START
-#define TIMER_END
-#define TIMER_ELAPSED ((sqlite_uint64)0)
-#endif
-
-/*
-** If we compile with the SQLITE_TEST macro set, then the following block
-** of code will give us the ability to simulate a disk I/O error. This
-** is used for testing the I/O recovery logic.
-*/
-#ifdef SQLITE_TEST
-SQLITE_API int sqlite3_io_error_hit = 0; /* Total number of I/O Errors */
-SQLITE_API int sqlite3_io_error_hardhit = 0; /* Number of non-benign errors */
-SQLITE_API int sqlite3_io_error_pending = 0; /* Count down to first I/O error */
-SQLITE_API int sqlite3_io_error_persist = 0; /* True if I/O errors persist */
-SQLITE_API int sqlite3_io_error_benign = 0; /* True if errors are benign */
-SQLITE_API int sqlite3_diskfull_pending = 0;
-SQLITE_API int sqlite3_diskfull = 0;
-#define SimulateIOErrorBenign(X) sqlite3_io_error_benign=(X)
-#define SimulateIOError(CODE) \
- if( (sqlite3_io_error_persist && sqlite3_io_error_hit) \
- || sqlite3_io_error_pending-- == 1 ) \
- { local_ioerr(); CODE; }
-static void local_ioerr(){
- IOTRACE(("IOERR\n"));
- sqlite3_io_error_hit++;
- if( !sqlite3_io_error_benign ) sqlite3_io_error_hardhit++;
-}
-#define SimulateDiskfullError(CODE) \
- if( sqlite3_diskfull_pending ){ \
- if( sqlite3_diskfull_pending == 1 ){ \
- local_ioerr(); \
- sqlite3_diskfull = 1; \
- sqlite3_io_error_hit = 1; \
- CODE; \
- }else{ \
- sqlite3_diskfull_pending--; \
- } \
- }
-#else
-#define SimulateIOErrorBenign(X)
-#define SimulateIOError(A)
-#define SimulateDiskfullError(A)
-#endif
-
-/*
-** When testing, keep a count of the number of open files.
-*/
-#ifdef SQLITE_TEST
-SQLITE_API int sqlite3_open_file_count = 0;
-#define OpenCounter(X) sqlite3_open_file_count+=(X)
-#else
-#define OpenCounter(X)
-#endif
-
-#endif /* !defined(_OS_COMMON_H_) */
-
-/************** End of os_common.h *******************************************/
-/************** Continuing where we left off in os_os2.c *********************/
-
-/* Forward references */
-typedef struct os2File os2File; /* The file structure */
-typedef struct os2ShmNode os2ShmNode; /* A shared descritive memory node */
-typedef struct os2ShmLink os2ShmLink; /* A connection to shared-memory */
-
-/*
-** The os2File structure is subclass of sqlite3_file specific for the OS/2
-** protability layer.
-*/
-struct os2File {
- const sqlite3_io_methods *pMethod; /* Always the first entry */
- HFILE h; /* Handle for accessing the file */
- int flags; /* Flags provided to os2Open() */
- int locktype; /* Type of lock currently held on this file */
- int szChunk; /* Chunk size configured by FCNTL_CHUNK_SIZE */
- char *zFullPathCp; /* Full path name of this file */
- os2ShmLink *pShmLink; /* Instance of shared memory on this file */
-};
-
-#define LOCK_TIMEOUT 10L /* the default locking timeout */
-
-/*
-** Missing from some versions of the OS/2 toolkit -
-** used to allocate from high memory if possible
-*/
-#ifndef OBJ_ANY
-# define OBJ_ANY 0x00000400
-#endif
-
-/*****************************************************************************
-** The next group of routines implement the I/O methods specified
-** by the sqlite3_io_methods object.
-******************************************************************************/
-
-/*
-** Close a file.
-*/
-static int os2Close( sqlite3_file *id ){
- APIRET rc;
- os2File *pFile = (os2File*)id;
-
- assert( id!=0 );
- OSTRACE(( "CLOSE %d (%s)\n", pFile->h, pFile->zFullPathCp ));
-
- rc = DosClose( pFile->h );
-
- if( pFile->flags & SQLITE_OPEN_DELETEONCLOSE )
- DosForceDelete( (PSZ)pFile->zFullPathCp );
-
- free( pFile->zFullPathCp );
- pFile->zFullPathCp = NULL;
- pFile->locktype = NO_LOCK;
- pFile->h = (HFILE)-1;
- pFile->flags = 0;
-
- OpenCounter( -1 );
- return rc == NO_ERROR ? SQLITE_OK : SQLITE_IOERR;
-}
-
-/*
-** Read data from a file into a buffer. Return SQLITE_OK if all
-** bytes were read successfully and SQLITE_IOERR if anything goes
-** wrong.
-*/
-static int os2Read(
- sqlite3_file *id, /* File to read from */
- void *pBuf, /* Write content into this buffer */
- int amt, /* Number of bytes to read */
- sqlite3_int64 offset /* Begin reading at this offset */
-){
- ULONG fileLocation = 0L;
- ULONG got;
- os2File *pFile = (os2File*)id;
- assert( id!=0 );
- SimulateIOError( return SQLITE_IOERR_READ );
- OSTRACE(( "READ %d lock=%d\n", pFile->h, pFile->locktype ));
- if( DosSetFilePtr(pFile->h, offset, FILE_BEGIN, &fileLocation) != NO_ERROR ){
- return SQLITE_IOERR;
- }
- if( DosRead( pFile->h, pBuf, amt, &got ) != NO_ERROR ){
- return SQLITE_IOERR_READ;
- }
- if( got == (ULONG)amt )
- return SQLITE_OK;
- else {
- /* Unread portions of the input buffer must be zero-filled */
- memset(&((char*)pBuf)[got], 0, amt-got);
- return SQLITE_IOERR_SHORT_READ;
- }
-}
-
-/*
-** Write data from a buffer into a file. Return SQLITE_OK on success
-** or some other error code on failure.
-*/
-static int os2Write(
- sqlite3_file *id, /* File to write into */
- const void *pBuf, /* The bytes to be written */
- int amt, /* Number of bytes to write */
- sqlite3_int64 offset /* Offset into the file to begin writing at */
-){
- ULONG fileLocation = 0L;
- APIRET rc = NO_ERROR;
- ULONG wrote;
- os2File *pFile = (os2File*)id;
- assert( id!=0 );
- SimulateIOError( return SQLITE_IOERR_WRITE );
- SimulateDiskfullError( return SQLITE_FULL );
- OSTRACE(( "WRITE %d lock=%d\n", pFile->h, pFile->locktype ));
- if( DosSetFilePtr(pFile->h, offset, FILE_BEGIN, &fileLocation) != NO_ERROR ){
- return SQLITE_IOERR;
- }
- assert( amt>0 );
- while( amt > 0 &&
- ( rc = DosWrite( pFile->h, (PVOID)pBuf, amt, &wrote ) ) == NO_ERROR &&
- wrote > 0
- ){
- amt -= wrote;
- pBuf = &((char*)pBuf)[wrote];
- }
-
- return ( rc != NO_ERROR || amt > (int)wrote ) ? SQLITE_FULL : SQLITE_OK;
-}
-
-/*
-** Truncate an open file to a specified size
-*/
-static int os2Truncate( sqlite3_file *id, i64 nByte ){
- APIRET rc;
- os2File *pFile = (os2File*)id;
- assert( id!=0 );
- OSTRACE(( "TRUNCATE %d %lld\n", pFile->h, nByte ));
- SimulateIOError( return SQLITE_IOERR_TRUNCATE );
-
- /* If the user has configured a chunk-size for this file, truncate the
- ** file so that it consists of an integer number of chunks (i.e. the
- ** actual file size after the operation may be larger than the requested
- ** size).
- */
- if( pFile->szChunk ){
- nByte = ((nByte + pFile->szChunk - 1)/pFile->szChunk) * pFile->szChunk;
- }
-
- rc = DosSetFileSize( pFile->h, nByte );
- return rc == NO_ERROR ? SQLITE_OK : SQLITE_IOERR_TRUNCATE;
-}
-
-#ifdef SQLITE_TEST
-/*
-** Count the number of fullsyncs and normal syncs. This is used to test
-** that syncs and fullsyncs are occuring at the right times.
-*/
-SQLITE_API int sqlite3_sync_count = 0;
-SQLITE_API int sqlite3_fullsync_count = 0;
-#endif
-
-/*
-** Make sure all writes to a particular file are committed to disk.
-*/
-static int os2Sync( sqlite3_file *id, int flags ){
- os2File *pFile = (os2File*)id;
- OSTRACE(( "SYNC %d lock=%d\n", pFile->h, pFile->locktype ));
-#ifdef SQLITE_TEST
- if( flags & SQLITE_SYNC_FULL){
- sqlite3_fullsync_count++;
- }
- sqlite3_sync_count++;
-#endif
- /* If we compiled with the SQLITE_NO_SYNC flag, then syncing is a
- ** no-op
- */
-#ifdef SQLITE_NO_SYNC
- UNUSED_PARAMETER(pFile);
- return SQLITE_OK;
-#else
- return DosResetBuffer( pFile->h ) == NO_ERROR ? SQLITE_OK : SQLITE_IOERR;
-#endif
-}
-
-/*
-** Determine the current size of a file in bytes
-*/
-static int os2FileSize( sqlite3_file *id, sqlite3_int64 *pSize ){
- APIRET rc = NO_ERROR;
- FILESTATUS3 fsts3FileInfo;
- memset(&fsts3FileInfo, 0, sizeof(fsts3FileInfo));
- assert( id!=0 );
- SimulateIOError( return SQLITE_IOERR_FSTAT );
- rc = DosQueryFileInfo( ((os2File*)id)->h, FIL_STANDARD, &fsts3FileInfo, sizeof(FILESTATUS3) );
- if( rc == NO_ERROR ){
- *pSize = fsts3FileInfo.cbFile;
- return SQLITE_OK;
- }else{
- return SQLITE_IOERR_FSTAT;
- }
-}
-
-/*
-** Acquire a reader lock.
-*/
-static int getReadLock( os2File *pFile ){
- FILELOCK LockArea,
- UnlockArea;
- APIRET res;
- memset(&LockArea, 0, sizeof(LockArea));
- memset(&UnlockArea, 0, sizeof(UnlockArea));
- LockArea.lOffset = SHARED_FIRST;
- LockArea.lRange = SHARED_SIZE;
- UnlockArea.lOffset = 0L;
- UnlockArea.lRange = 0L;
- res = DosSetFileLocks( pFile->h, &UnlockArea, &LockArea, LOCK_TIMEOUT, 1L );
- OSTRACE(( "GETREADLOCK %d res=%d\n", pFile->h, res ));
- return res;
-}
-
-/*
-** Undo a readlock
-*/
-static int unlockReadLock( os2File *id ){
- FILELOCK LockArea,
- UnlockArea;
- APIRET res;
- memset(&LockArea, 0, sizeof(LockArea));
- memset(&UnlockArea, 0, sizeof(UnlockArea));
- LockArea.lOffset = 0L;
- LockArea.lRange = 0L;
- UnlockArea.lOffset = SHARED_FIRST;
- UnlockArea.lRange = SHARED_SIZE;
- res = DosSetFileLocks( id->h, &UnlockArea, &LockArea, LOCK_TIMEOUT, 1L );
- OSTRACE(( "UNLOCK-READLOCK file handle=%d res=%d?\n", id->h, res ));
- return res;
-}
-
-/*
-** Lock the file with the lock specified by parameter locktype - one
-** of the following:
-**
-** (1) SHARED_LOCK
-** (2) RESERVED_LOCK
-** (3) PENDING_LOCK
-** (4) EXCLUSIVE_LOCK
-**
-** Sometimes when requesting one lock state, additional lock states
-** are inserted in between. The locking might fail on one of the later
-** transitions leaving the lock state different from what it started but
-** still short of its goal. The following chart shows the allowed
-** transitions and the inserted intermediate states:
-**
-** UNLOCKED -> SHARED
-** SHARED -> RESERVED
-** SHARED -> (PENDING) -> EXCLUSIVE
-** RESERVED -> (PENDING) -> EXCLUSIVE
-** PENDING -> EXCLUSIVE
-**
-** This routine will only increase a lock. The os2Unlock() routine
-** erases all locks at once and returns us immediately to locking level 0.
-** It is not possible to lower the locking level one step at a time. You
-** must go straight to locking level 0.
-*/
-static int os2Lock( sqlite3_file *id, int locktype ){
- int rc = SQLITE_OK; /* Return code from subroutines */
- APIRET res = NO_ERROR; /* Result of an OS/2 lock call */
- int newLocktype; /* Set pFile->locktype to this value before exiting */
- int gotPendingLock = 0;/* True if we acquired a PENDING lock this time */
- FILELOCK LockArea,
- UnlockArea;
- os2File *pFile = (os2File*)id;
- memset(&LockArea, 0, sizeof(LockArea));
- memset(&UnlockArea, 0, sizeof(UnlockArea));
- assert( pFile!=0 );
- OSTRACE(( "LOCK %d %d was %d\n", pFile->h, locktype, pFile->locktype ));
-
- /* If there is already a lock of this type or more restrictive on the
- ** os2File, do nothing. Don't use the end_lock: exit path, as
- ** sqlite3_mutex_enter() hasn't been called yet.
- */
- if( pFile->locktype>=locktype ){
- OSTRACE(( "LOCK %d %d ok (already held)\n", pFile->h, locktype ));
- return SQLITE_OK;
- }
-
- /* Make sure the locking sequence is correct
- */
- assert( pFile->locktype!=NO_LOCK || locktype==SHARED_LOCK );
- assert( locktype!=PENDING_LOCK );
- assert( locktype!=RESERVED_LOCK || pFile->locktype==SHARED_LOCK );
-
- /* Lock the PENDING_LOCK byte if we need to acquire a PENDING lock or
- ** a SHARED lock. If we are acquiring a SHARED lock, the acquisition of
- ** the PENDING_LOCK byte is temporary.
- */
- newLocktype = pFile->locktype;
- if( pFile->locktype==NO_LOCK
- || (locktype==EXCLUSIVE_LOCK && pFile->locktype==RESERVED_LOCK)
- ){
- LockArea.lOffset = PENDING_BYTE;
- LockArea.lRange = 1L;
- UnlockArea.lOffset = 0L;
- UnlockArea.lRange = 0L;
-
- /* wait longer than LOCK_TIMEOUT here not to have to try multiple times */
- res = DosSetFileLocks( pFile->h, &UnlockArea, &LockArea, 100L, 0L );
- if( res == NO_ERROR ){
- gotPendingLock = 1;
- OSTRACE(( "LOCK %d pending lock boolean set. res=%d\n", pFile->h, res ));
- }
- }
-
- /* Acquire a shared lock
- */
- if( locktype==SHARED_LOCK && res == NO_ERROR ){
- assert( pFile->locktype==NO_LOCK );
- res = getReadLock(pFile);
- if( res == NO_ERROR ){
- newLocktype = SHARED_LOCK;
- }
- OSTRACE(( "LOCK %d acquire shared lock. res=%d\n", pFile->h, res ));
- }
-
- /* Acquire a RESERVED lock
- */
- if( locktype==RESERVED_LOCK && res == NO_ERROR ){
- assert( pFile->locktype==SHARED_LOCK );
- LockArea.lOffset = RESERVED_BYTE;
- LockArea.lRange = 1L;
- UnlockArea.lOffset = 0L;
- UnlockArea.lRange = 0L;
- res = DosSetFileLocks( pFile->h, &UnlockArea, &LockArea, LOCK_TIMEOUT, 0L );
- if( res == NO_ERROR ){
- newLocktype = RESERVED_LOCK;
- }
- OSTRACE(( "LOCK %d acquire reserved lock. res=%d\n", pFile->h, res ));
- }
-
- /* Acquire a PENDING lock
- */
- if( locktype==EXCLUSIVE_LOCK && res == NO_ERROR ){
- newLocktype = PENDING_LOCK;
- gotPendingLock = 0;
- OSTRACE(( "LOCK %d acquire pending lock. pending lock boolean unset.\n",
- pFile->h ));
- }
-
- /* Acquire an EXCLUSIVE lock
- */
- if( locktype==EXCLUSIVE_LOCK && res == NO_ERROR ){
- assert( pFile->locktype>=SHARED_LOCK );
- res = unlockReadLock(pFile);
- OSTRACE(( "unreadlock = %d\n", res ));
- LockArea.lOffset = SHARED_FIRST;
- LockArea.lRange = SHARED_SIZE;
- UnlockArea.lOffset = 0L;
- UnlockArea.lRange = 0L;
- res = DosSetFileLocks( pFile->h, &UnlockArea, &LockArea, LOCK_TIMEOUT, 0L );
- if( res == NO_ERROR ){
- newLocktype = EXCLUSIVE_LOCK;
- }else{
- OSTRACE(( "OS/2 error-code = %d\n", res ));
- getReadLock(pFile);
- }
- OSTRACE(( "LOCK %d acquire exclusive lock. res=%d\n", pFile->h, res ));
- }
-
- /* If we are holding a PENDING lock that ought to be released, then
- ** release it now.
- */
- if( gotPendingLock && locktype==SHARED_LOCK ){
- int r;
- LockArea.lOffset = 0L;
- LockArea.lRange = 0L;
- UnlockArea.lOffset = PENDING_BYTE;
- UnlockArea.lRange = 1L;
- r = DosSetFileLocks( pFile->h, &UnlockArea, &LockArea, LOCK_TIMEOUT, 0L );
- OSTRACE(( "LOCK %d unlocking pending/is shared. r=%d\n", pFile->h, r ));
- }
-
- /* Update the state of the lock has held in the file descriptor then
- ** return the appropriate result code.
- */
- if( res == NO_ERROR ){
- rc = SQLITE_OK;
- }else{
- OSTRACE(( "LOCK FAILED %d trying for %d but got %d\n", pFile->h,
- locktype, newLocktype ));
- rc = SQLITE_BUSY;
- }
- pFile->locktype = newLocktype;
- OSTRACE(( "LOCK %d now %d\n", pFile->h, pFile->locktype ));
- return rc;
-}
-
-/*
-** This routine checks if there is a RESERVED lock held on the specified
-** file by this or any other process. If such a lock is held, return
-** non-zero, otherwise zero.
-*/
-static int os2CheckReservedLock( sqlite3_file *id, int *pOut ){
- int r = 0;
- os2File *pFile = (os2File*)id;
- assert( pFile!=0 );
- if( pFile->locktype>=RESERVED_LOCK ){
- r = 1;
- OSTRACE(( "TEST WR-LOCK %d %d (local)\n", pFile->h, r ));
- }else{
- FILELOCK LockArea,
- UnlockArea;
- APIRET rc = NO_ERROR;
- memset(&LockArea, 0, sizeof(LockArea));
- memset(&UnlockArea, 0, sizeof(UnlockArea));
- LockArea.lOffset = RESERVED_BYTE;
- LockArea.lRange = 1L;
- UnlockArea.lOffset = 0L;
- UnlockArea.lRange = 0L;
- rc = DosSetFileLocks( pFile->h, &UnlockArea, &LockArea, LOCK_TIMEOUT, 0L );
- OSTRACE(( "TEST WR-LOCK %d lock reserved byte rc=%d\n", pFile->h, rc ));
- if( rc == NO_ERROR ){
- APIRET rcu = NO_ERROR; /* return code for unlocking */
- LockArea.lOffset = 0L;
- LockArea.lRange = 0L;
- UnlockArea.lOffset = RESERVED_BYTE;
- UnlockArea.lRange = 1L;
- rcu = DosSetFileLocks( pFile->h, &UnlockArea, &LockArea, LOCK_TIMEOUT, 0L );
- OSTRACE(( "TEST WR-LOCK %d unlock reserved byte r=%d\n", pFile->h, rcu ));
- }
- r = !(rc == NO_ERROR);
- OSTRACE(( "TEST WR-LOCK %d %d (remote)\n", pFile->h, r ));
- }
- *pOut = r;
- return SQLITE_OK;
-}
-
-/*
-** Lower the locking level on file descriptor id to locktype. locktype
-** must be either NO_LOCK or SHARED_LOCK.
-**
-** If the locking level of the file descriptor is already at or below
-** the requested locking level, this routine is a no-op.
-**
-** It is not possible for this routine to fail if the second argument
-** is NO_LOCK. If the second argument is SHARED_LOCK then this routine
-** might return SQLITE_IOERR;
-*/
-static int os2Unlock( sqlite3_file *id, int locktype ){
- int type;
- os2File *pFile = (os2File*)id;
- APIRET rc = SQLITE_OK;
- APIRET res = NO_ERROR;
- FILELOCK LockArea,
- UnlockArea;
- memset(&LockArea, 0, sizeof(LockArea));
- memset(&UnlockArea, 0, sizeof(UnlockArea));
- assert( pFile!=0 );
- assert( locktype<=SHARED_LOCK );
- OSTRACE(( "UNLOCK %d to %d was %d\n", pFile->h, locktype, pFile->locktype ));
- type = pFile->locktype;
- if( type>=EXCLUSIVE_LOCK ){
- LockArea.lOffset = 0L;
- LockArea.lRange = 0L;
- UnlockArea.lOffset = SHARED_FIRST;
- UnlockArea.lRange = SHARED_SIZE;
- res = DosSetFileLocks( pFile->h, &UnlockArea, &LockArea, LOCK_TIMEOUT, 0L );
- OSTRACE(( "UNLOCK %d exclusive lock res=%d\n", pFile->h, res ));
- if( locktype==SHARED_LOCK && getReadLock(pFile) != NO_ERROR ){
- /* This should never happen. We should always be able to
- ** reacquire the read lock */
- OSTRACE(( "UNLOCK %d to %d getReadLock() failed\n", pFile->h, locktype ));
- rc = SQLITE_IOERR_UNLOCK;
- }
- }
- if( type>=RESERVED_LOCK ){
- LockArea.lOffset = 0L;
- LockArea.lRange = 0L;
- UnlockArea.lOffset = RESERVED_BYTE;
- UnlockArea.lRange = 1L;
- res = DosSetFileLocks( pFile->h, &UnlockArea, &LockArea, LOCK_TIMEOUT, 0L );
- OSTRACE(( "UNLOCK %d reserved res=%d\n", pFile->h, res ));
- }
- if( locktype==NO_LOCK && type>=SHARED_LOCK ){
- res = unlockReadLock(pFile);
- OSTRACE(( "UNLOCK %d is %d want %d res=%d\n",
- pFile->h, type, locktype, res ));
- }
- if( type>=PENDING_LOCK ){
- LockArea.lOffset = 0L;
- LockArea.lRange = 0L;
- UnlockArea.lOffset = PENDING_BYTE;
- UnlockArea.lRange = 1L;
- res = DosSetFileLocks( pFile->h, &UnlockArea, &LockArea, LOCK_TIMEOUT, 0L );
- OSTRACE(( "UNLOCK %d pending res=%d\n", pFile->h, res ));
- }
- pFile->locktype = locktype;
- OSTRACE(( "UNLOCK %d now %d\n", pFile->h, pFile->locktype ));
- return rc;
-}
-
-/*
-** Control and query of the open file handle.
-*/
-static int os2FileControl(sqlite3_file *id, int op, void *pArg){
- switch( op ){
- case SQLITE_FCNTL_LOCKSTATE: {
- *(int*)pArg = ((os2File*)id)->locktype;
- OSTRACE(( "FCNTL_LOCKSTATE %d lock=%d\n",
- ((os2File*)id)->h, ((os2File*)id)->locktype ));
- return SQLITE_OK;
- }
- case SQLITE_FCNTL_CHUNK_SIZE: {
- ((os2File*)id)->szChunk = *(int*)pArg;
- return SQLITE_OK;
- }
- case SQLITE_FCNTL_SIZE_HINT: {
- sqlite3_int64 sz = *(sqlite3_int64*)pArg;
- SimulateIOErrorBenign(1);
- os2Truncate(id, sz);
- SimulateIOErrorBenign(0);
- return SQLITE_OK;
- }
- case SQLITE_FCNTL_SYNC_OMITTED: {
- return SQLITE_OK;
- }
- }
- return SQLITE_NOTFOUND;
-}
-
-/*
-** Return the sector size in bytes of the underlying block device for
-** the specified file. This is almost always 512 bytes, but may be
-** larger for some devices.
-**
-** SQLite code assumes this function cannot fail. It also assumes that
-** if two files are created in the same file-system directory (i.e.
-** a database and its journal file) that the sector size will be the
-** same for both.
-*/
-static int os2SectorSize(sqlite3_file *id){
- UNUSED_PARAMETER(id);
- return SQLITE_DEFAULT_SECTOR_SIZE;
-}
-
-/*
-** Return a vector of device characteristics.
-*/
-static int os2DeviceCharacteristics(sqlite3_file *id){
- UNUSED_PARAMETER(id);
- return SQLITE_IOCAP_UNDELETABLE_WHEN_OPEN;
-}
-
-
-/*
-** Character set conversion objects used by conversion routines.
-*/
-static UconvObject ucUtf8 = NULL; /* convert between UTF-8 and UCS-2 */
-static UconvObject uclCp = NULL; /* convert between local codepage and UCS-2 */
-
-/*
-** Helper function to initialize the conversion objects from and to UTF-8.
-*/
-static void initUconvObjects( void ){
- if( UniCreateUconvObject( UTF_8, &ucUtf8 ) != ULS_SUCCESS )
- ucUtf8 = NULL;
- if ( UniCreateUconvObject( (UniChar *)L"@path=yes", &uclCp ) != ULS_SUCCESS )
- uclCp = NULL;
-}
-
-/*
-** Helper function to free the conversion objects from and to UTF-8.
-*/
-static void freeUconvObjects( void ){
- if ( ucUtf8 )
- UniFreeUconvObject( ucUtf8 );
- if ( uclCp )
- UniFreeUconvObject( uclCp );
- ucUtf8 = NULL;
- uclCp = NULL;
-}
-
-/*
-** Helper function to convert UTF-8 filenames to local OS/2 codepage.
-** The two-step process: first convert the incoming UTF-8 string
-** into UCS-2 and then from UCS-2 to the current codepage.
-** The returned char pointer has to be freed.
-*/
-static char *convertUtf8PathToCp( const char *in ){
- UniChar tempPath[CCHMAXPATH];
- char *out = (char *)calloc( CCHMAXPATH, 1 );
-
- if( !out )
- return NULL;
-
- if( !ucUtf8 || !uclCp )
- initUconvObjects();
-
- /* determine string for the conversion of UTF-8 which is CP1208 */
- if( UniStrToUcs( ucUtf8, tempPath, (char *)in, CCHMAXPATH ) != ULS_SUCCESS )
- return out; /* if conversion fails, return the empty string */
-
- /* conversion for current codepage which can be used for paths */
- UniStrFromUcs( uclCp, out, tempPath, CCHMAXPATH );
-
- return out;
-}
-
-/*
-** Helper function to convert filenames from local codepage to UTF-8.
-** The two-step process: first convert the incoming codepage-specific
-** string into UCS-2 and then from UCS-2 to the codepage of UTF-8.
-** The returned char pointer has to be freed.
-**
-** This function is non-static to be able to use this in shell.c and
-** similar applications that take command line arguments.
-*/
-char *convertCpPathToUtf8( const char *in ){
- UniChar tempPath[CCHMAXPATH];
- char *out = (char *)calloc( CCHMAXPATH, 1 );
-
- if( !out )
- return NULL;
-
- if( !ucUtf8 || !uclCp )
- initUconvObjects();
-
- /* conversion for current codepage which can be used for paths */
- if( UniStrToUcs( uclCp, tempPath, (char *)in, CCHMAXPATH ) != ULS_SUCCESS )
- return out; /* if conversion fails, return the empty string */
-
- /* determine string for the conversion of UTF-8 which is CP1208 */
- UniStrFromUcs( ucUtf8, out, tempPath, CCHMAXPATH );
-
- return out;
-}
-
-
-#ifndef SQLITE_OMIT_WAL
-
-/*
-** Use main database file for interprocess locking. If un-defined
-** a separate file is created for this purpose. The file will be
-** used only to set file locks. There will be no data written to it.
-*/
-#define SQLITE_OS2_NO_WAL_LOCK_FILE
-
-#if 0
-static void _ERR_TRACE( const char *fmt, ... ) {
- va_list ap;
- va_start(ap, fmt);
- vfprintf(stderr, fmt, ap);
- fflush(stderr);
-}
-#define ERR_TRACE(rc, msg) \
- if( (rc) != SQLITE_OK ) _ERR_TRACE msg;
-#else
-#define ERR_TRACE(rc, msg)
-#endif
-
-/*
-** Helper functions to obtain and relinquish the global mutex. The
-** global mutex is used to protect os2ShmNodeList.
-**
-** Function os2ShmMutexHeld() is used to assert() that the global mutex
-** is held when required. This function is only used as part of assert()
-** statements. e.g.
-**
-** os2ShmEnterMutex()
-** assert( os2ShmMutexHeld() );
-** os2ShmLeaveMutex()
-*/
-static void os2ShmEnterMutex(void){
- sqlite3_mutex_enter(sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER));
-}
-static void os2ShmLeaveMutex(void){
- sqlite3_mutex_leave(sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER));
-}
-#ifdef SQLITE_DEBUG
-static int os2ShmMutexHeld(void) {
- return sqlite3_mutex_held(sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER));
-}
-int GetCurrentProcessId(void) {
- PPIB pib;
- DosGetInfoBlocks(NULL, &pib);
- return (int)pib->pib_ulpid;
-}
-#endif
-
-/*
-** Object used to represent a the shared memory area for a single log file.
-** When multiple threads all reference the same log-summary, each thread has
-** its own os2File object, but they all point to a single instance of this
-** object. In other words, each log-summary is opened only once per process.
-**
-** os2ShmMutexHeld() must be true when creating or destroying
-** this object or while reading or writing the following fields:
-**
-** nRef
-** pNext
-**
-** The following fields are read-only after the object is created:
-**
-** szRegion
-** hLockFile
-** shmBaseName
-**
-** Either os2ShmNode.mutex must be held or os2ShmNode.nRef==0 and
-** os2ShmMutexHeld() is true when reading or writing any other field
-** in this structure.
-**
-*/
-struct os2ShmNode {
- sqlite3_mutex *mutex; /* Mutex to access this object */
- os2ShmNode *pNext; /* Next in list of all os2ShmNode objects */
-
- int szRegion; /* Size of shared-memory regions */
-
- int nRegion; /* Size of array apRegion */
- void **apRegion; /* Array of pointers to shared-memory regions */
-
- int nRef; /* Number of os2ShmLink objects pointing to this */
- os2ShmLink *pFirst; /* First os2ShmLink object pointing to this */
-
- HFILE hLockFile; /* File used for inter-process memory locking */
- char shmBaseName[1]; /* Name of the memory object !!! must last !!! */
-};
-
-
-/*
-** Structure used internally by this VFS to record the state of an
-** open shared memory connection.
-**
-** The following fields are initialized when this object is created and
-** are read-only thereafter:
-**
-** os2Shm.pShmNode
-** os2Shm.id
-**
-** All other fields are read/write. The os2Shm.pShmNode->mutex must be held
-** while accessing any read/write fields.
-*/
-struct os2ShmLink {
- os2ShmNode *pShmNode; /* The underlying os2ShmNode object */
- os2ShmLink *pNext; /* Next os2Shm with the same os2ShmNode */
- u32 sharedMask; /* Mask of shared locks held */
- u32 exclMask; /* Mask of exclusive locks held */
-#ifdef SQLITE_DEBUG
- u8 id; /* Id of this connection with its os2ShmNode */
-#endif
-};
-
-
-/*
-** A global list of all os2ShmNode objects.
-**
-** The os2ShmMutexHeld() must be true while reading or writing this list.
-*/
-static os2ShmNode *os2ShmNodeList = NULL;
-
-/*
-** Constants used for locking
-*/
-#ifdef SQLITE_OS2_NO_WAL_LOCK_FILE
-#define OS2_SHM_BASE (PENDING_BYTE + 0x10000) /* first lock byte */
-#else
-#define OS2_SHM_BASE ((22+SQLITE_SHM_NLOCK)*4) /* first lock byte */
-#endif
-
-#define OS2_SHM_DMS (OS2_SHM_BASE+SQLITE_SHM_NLOCK) /* deadman switch */
-
-/*
-** Apply advisory locks for all n bytes beginning at ofst.
-*/
-#define _SHM_UNLCK 1 /* no lock */
-#define _SHM_RDLCK 2 /* shared lock, no wait */
-#define _SHM_WRLCK 3 /* exlusive lock, no wait */
-#define _SHM_WRLCK_WAIT 4 /* exclusive lock, wait */
-static int os2ShmSystemLock(
- os2ShmNode *pNode, /* Apply locks to this open shared-memory segment */
- int lockType, /* _SHM_UNLCK, _SHM_RDLCK, _SHM_WRLCK or _SHM_WRLCK_WAIT */
- int ofst, /* Offset to first byte to be locked/unlocked */
- int nByte /* Number of bytes to lock or unlock */
-){
- APIRET rc;
- FILELOCK area;
- ULONG mode, timeout;
-
- /* Access to the os2ShmNode object is serialized by the caller */
- assert( sqlite3_mutex_held(pNode->mutex) || pNode->nRef==0 );
-
- mode = 1; /* shared lock */
- timeout = 0; /* no wait */
- area.lOffset = ofst;
- area.lRange = nByte;
-
- switch( lockType ) {
- case _SHM_WRLCK_WAIT:
- timeout = (ULONG)-1; /* wait forever */
- case _SHM_WRLCK:
- mode = 0; /* exclusive lock */
- case _SHM_RDLCK:
- rc = DosSetFileLocks(pNode->hLockFile,
- NULL, &area, timeout, mode);
- break;
- /* case _SHM_UNLCK: */
- default:
- rc = DosSetFileLocks(pNode->hLockFile,
- &area, NULL, 0, 0);
- break;
- }
-
- OSTRACE(("SHM-LOCK %d %s %s 0x%08lx\n",
- pNode->hLockFile,
- rc==SQLITE_OK ? "ok" : "failed",
- lockType==_SHM_UNLCK ? "Unlock" : "Lock",
- rc));
-
- ERR_TRACE(rc, ("os2ShmSystemLock: %d %s\n", rc, pNode->shmBaseName))
-
- return ( rc == 0 ) ? SQLITE_OK : SQLITE_BUSY;
-}
-
-/*
-** Find an os2ShmNode in global list or allocate a new one, if not found.
-**
-** This is not a VFS shared-memory method; it is a utility function called
-** by VFS shared-memory methods.
-*/
-static int os2OpenSharedMemory( os2File *fd, int szRegion ) {
- os2ShmLink *pLink;
- os2ShmNode *pNode;
- int cbShmName, rc = SQLITE_OK;
- char shmName[CCHMAXPATH + 30];
-#ifndef SQLITE_OS2_NO_WAL_LOCK_FILE
- ULONG action;
-#endif
-
- /* We need some additional space at the end to append the region number */
- cbShmName = sprintf(shmName, "\\SHAREMEM\\%s", fd->zFullPathCp );
- if( cbShmName >= CCHMAXPATH-8 )
- return SQLITE_IOERR_SHMOPEN;
-
- /* Replace colon in file name to form a valid shared memory name */
- shmName[10+1] = '!';
-
- /* Allocate link object (we free it later in case of failure) */
- pLink = sqlite3_malloc( sizeof(*pLink) );
- if( !pLink )
- return SQLITE_NOMEM;
-
- /* Access node list */
- os2ShmEnterMutex();
-
- /* Find node by it's shared memory base name */
- for( pNode = os2ShmNodeList;
- pNode && stricmp(shmName, pNode->shmBaseName) != 0;
- pNode = pNode->pNext ) ;
-
- /* Not found: allocate a new node */
- if( !pNode ) {
- pNode = sqlite3_malloc( sizeof(*pNode) + cbShmName );
- if( pNode ) {
- memset(pNode, 0, sizeof(*pNode) );
- pNode->szRegion = szRegion;
- pNode->hLockFile = (HFILE)-1;
- strcpy(pNode->shmBaseName, shmName);
-
-#ifdef SQLITE_OS2_NO_WAL_LOCK_FILE
- if( DosDupHandle(fd->h, &pNode->hLockFile) != 0 ) {
-#else
- sprintf(shmName, "%s-lck", fd->zFullPathCp);
- if( DosOpen((PSZ)shmName, &pNode->hLockFile, &action, 0, FILE_NORMAL,
- OPEN_ACTION_OPEN_IF_EXISTS | OPEN_ACTION_CREATE_IF_NEW,
- OPEN_ACCESS_READWRITE | OPEN_SHARE_DENYNONE |
- OPEN_FLAGS_NOINHERIT | OPEN_FLAGS_FAIL_ON_ERROR,
- NULL) != 0 ) {
-#endif
- sqlite3_free(pNode);
- rc = SQLITE_IOERR;
- } else {
- pNode->mutex = sqlite3_mutex_alloc(SQLITE_MUTEX_FAST);
- if( !pNode->mutex ) {
- sqlite3_free(pNode);
- rc = SQLITE_NOMEM;
- }
- }
- } else {
- rc = SQLITE_NOMEM;
- }
-
- if( rc == SQLITE_OK ) {
- pNode->pNext = os2ShmNodeList;
- os2ShmNodeList = pNode;
- } else {
- pNode = NULL;
- }
- } else if( pNode->szRegion != szRegion ) {
- rc = SQLITE_IOERR_SHMSIZE;
- pNode = NULL;
- }
-
- if( pNode ) {
- sqlite3_mutex_enter(pNode->mutex);
-
- memset(pLink, 0, sizeof(*pLink));
-
- pLink->pShmNode = pNode;
- pLink->pNext = pNode->pFirst;
- pNode->pFirst = pLink;
- pNode->nRef++;
-
- fd->pShmLink = pLink;
-
- sqlite3_mutex_leave(pNode->mutex);
-
- } else {
- /* Error occured. Free our link object. */
- sqlite3_free(pLink);
- }
-
- os2ShmLeaveMutex();
-
- ERR_TRACE(rc, ("os2OpenSharedMemory: %d %s\n", rc, fd->zFullPathCp))
-
- return rc;
-}
-
-/*
-** Purge the os2ShmNodeList list of all entries with nRef==0.
-**
-** This is not a VFS shared-memory method; it is a utility function called
-** by VFS shared-memory methods.
-*/
-static void os2PurgeShmNodes( int deleteFlag ) {
- os2ShmNode *pNode;
- os2ShmNode **ppNode;
-
- os2ShmEnterMutex();
-
- ppNode = &os2ShmNodeList;
-
- while( *ppNode ) {
- pNode = *ppNode;
-
- if( pNode->nRef == 0 ) {
- *ppNode = pNode->pNext;
-
- if( pNode->apRegion ) {
- /* Prevent other processes from resizing the shared memory */
- os2ShmSystemLock(pNode, _SHM_WRLCK_WAIT, OS2_SHM_DMS, 1);
-
- while( pNode->nRegion-- ) {
-#ifdef SQLITE_DEBUG
- int rc =
-#endif
- DosFreeMem(pNode->apRegion[pNode->nRegion]);
-
- OSTRACE(("SHM-PURGE pid-%d unmap region=%d %s\n",
- (int)GetCurrentProcessId(), pNode->nRegion,
- rc == 0 ? "ok" : "failed"));
- }
-
- /* Allow other processes to resize the shared memory */
- os2ShmSystemLock(pNode, _SHM_UNLCK, OS2_SHM_DMS, 1);
-
- sqlite3_free(pNode->apRegion);
- }
-
- DosClose(pNode->hLockFile);
-
-#ifndef SQLITE_OS2_NO_WAL_LOCK_FILE
- if( deleteFlag ) {
- char fileName[CCHMAXPATH];
- /* Skip "\\SHAREMEM\\" */
- sprintf(fileName, "%s-lck", pNode->shmBaseName + 10);
- /* restore colon */
- fileName[1] = ':';
-
- DosForceDelete(fileName);
- }
-#endif
-
- sqlite3_mutex_free(pNode->mutex);
-
- sqlite3_free(pNode);
-
- } else {
- ppNode = &pNode->pNext;
- }
- }
-
- os2ShmLeaveMutex();
-}
-
-/*
-** This function is called to obtain a pointer to region iRegion of the
-** shared-memory associated with the database file id. Shared-memory regions
-** are numbered starting from zero. Each shared-memory region is szRegion
-** bytes in size.
-**
-** If an error occurs, an error code is returned and *pp is set to NULL.
-**
-** Otherwise, if the bExtend parameter is 0 and the requested shared-memory
-** region has not been allocated (by any client, including one running in a
-** separate process), then *pp is set to NULL and SQLITE_OK returned. If
-** bExtend is non-zero and the requested shared-memory region has not yet
-** been allocated, it is allocated by this function.
-**
-** If the shared-memory region has already been allocated or is allocated by
-** this call as described above, then it is mapped into this processes
-** address space (if it is not already), *pp is set to point to the mapped
-** memory and SQLITE_OK returned.
-*/
-static int os2ShmMap(
- sqlite3_file *id, /* Handle open on database file */
- int iRegion, /* Region to retrieve */
- int szRegion, /* Size of regions */
- int bExtend, /* True to extend block if necessary */
- void volatile **pp /* OUT: Mapped memory */
-){
- PVOID pvTemp;
- void **apRegion;
- os2ShmNode *pNode;
- int n, rc = SQLITE_OK;
- char shmName[CCHMAXPATH];
- os2File *pFile = (os2File*)id;
-
- *pp = NULL;
-
- if( !pFile->pShmLink )
- rc = os2OpenSharedMemory( pFile, szRegion );
-
- if( rc == SQLITE_OK ) {
- pNode = pFile->pShmLink->pShmNode ;
-
- sqlite3_mutex_enter(pNode->mutex);
-
- assert( szRegion==pNode->szRegion );
-
- /* Unmapped region ? */
- if( iRegion >= pNode->nRegion ) {
- /* Prevent other processes from resizing the shared memory */
- os2ShmSystemLock(pNode, _SHM_WRLCK_WAIT, OS2_SHM_DMS, 1);
-
- apRegion = sqlite3_realloc(
- pNode->apRegion, (iRegion + 1) * sizeof(apRegion[0]));
-
- if( apRegion ) {
- pNode->apRegion = apRegion;
-
- while( pNode->nRegion <= iRegion ) {
- sprintf(shmName, "%s-%u",
- pNode->shmBaseName, pNode->nRegion);
-
- if( DosGetNamedSharedMem(&pvTemp, (PSZ)shmName,
- PAG_READ | PAG_WRITE) != NO_ERROR ) {
- if( !bExtend )
- break;
-
- if( DosAllocSharedMem(&pvTemp, (PSZ)shmName, szRegion,
- PAG_READ | PAG_WRITE | PAG_COMMIT | OBJ_ANY) != NO_ERROR &&
- DosAllocSharedMem(&pvTemp, (PSZ)shmName, szRegion,
- PAG_READ | PAG_WRITE | PAG_COMMIT) != NO_ERROR ) {
- rc = SQLITE_NOMEM;
- break;
- }
- }
-
- apRegion[pNode->nRegion++] = pvTemp;
- }
-
- /* zero out remaining entries */
- for( n = pNode->nRegion; n <= iRegion; n++ )
- pNode->apRegion[n] = NULL;
-
- /* Return this region (maybe zero) */
- *pp = pNode->apRegion[iRegion];
- } else {
- rc = SQLITE_NOMEM;
- }
-
- /* Allow other processes to resize the shared memory */
- os2ShmSystemLock(pNode, _SHM_UNLCK, OS2_SHM_DMS, 1);
-
- } else {
- /* Region has been mapped previously */
- *pp = pNode->apRegion[iRegion];
- }
-
- sqlite3_mutex_leave(pNode->mutex);
- }
-
- ERR_TRACE(rc, ("os2ShmMap: %s iRgn = %d, szRgn = %d, bExt = %d : %d\n",
- pFile->zFullPathCp, iRegion, szRegion, bExtend, rc))
-
- return rc;
-}
-
-/*
-** Close a connection to shared-memory. Delete the underlying
-** storage if deleteFlag is true.
-**
-** If there is no shared memory associated with the connection then this
-** routine is a harmless no-op.
-*/
-static int os2ShmUnmap(
- sqlite3_file *id, /* The underlying database file */
- int deleteFlag /* Delete shared-memory if true */
-){
- os2File *pFile = (os2File*)id;
- os2ShmLink *pLink = pFile->pShmLink;
-
- if( pLink ) {
- int nRef = -1;
- os2ShmLink **ppLink;
- os2ShmNode *pNode = pLink->pShmNode;
-
- sqlite3_mutex_enter(pNode->mutex);
-
- for( ppLink = &pNode->pFirst;
- *ppLink && *ppLink != pLink;
- ppLink = &(*ppLink)->pNext ) ;
-
- assert(*ppLink);
-
- if( *ppLink ) {
- *ppLink = pLink->pNext;
- nRef = --pNode->nRef;
- } else {
- ERR_TRACE(1, ("os2ShmUnmap: link not found ! %s\n",
- pNode->shmBaseName))
- }
-
- pFile->pShmLink = NULL;
- sqlite3_free(pLink);
-
- sqlite3_mutex_leave(pNode->mutex);
-
- if( nRef == 0 )
- os2PurgeShmNodes( deleteFlag );
- }
-
- return SQLITE_OK;
-}
-
-/*
-** Change the lock state for a shared-memory segment.
-**
-** Note that the relationship between SHAREd and EXCLUSIVE locks is a little
-** different here than in posix. In xShmLock(), one can go from unlocked
-** to shared and back or from unlocked to exclusive and back. But one may
-** not go from shared to exclusive or from exclusive to shared.
-*/
-static int os2ShmLock(
- sqlite3_file *id, /* Database file holding the shared memory */
- int ofst, /* First lock to acquire or release */
- int n, /* Number of locks to acquire or release */
- int flags /* What to do with the lock */
-){
- u32 mask; /* Mask of locks to take or release */
- int rc = SQLITE_OK; /* Result code */
- os2File *pFile = (os2File*)id;
- os2ShmLink *p = pFile->pShmLink; /* The shared memory being locked */
- os2ShmLink *pX; /* For looping over all siblings */
- os2ShmNode *pShmNode = p->pShmNode; /* Our node */
-
- assert( ofst>=0 && ofst+n<=SQLITE_SHM_NLOCK );
- assert( n>=1 );
- assert( flags==(SQLITE_SHM_LOCK | SQLITE_SHM_SHARED)
- || flags==(SQLITE_SHM_LOCK | SQLITE_SHM_EXCLUSIVE)
- || flags==(SQLITE_SHM_UNLOCK | SQLITE_SHM_SHARED)
- || flags==(SQLITE_SHM_UNLOCK | SQLITE_SHM_EXCLUSIVE) );
- assert( n==1 || (flags & SQLITE_SHM_EXCLUSIVE)!=0 );
-
- mask = (u32)((1U<<(ofst+n)) - (1U<<ofst));
- assert( n>1 || mask==(1<<ofst) );
-
-
- sqlite3_mutex_enter(pShmNode->mutex);
-
- if( flags & SQLITE_SHM_UNLOCK ){
- u32 allMask = 0; /* Mask of locks held by siblings */
-
- /* See if any siblings hold this same lock */
- for(pX=pShmNode->pFirst; pX; pX=pX->pNext){
- if( pX==p ) continue;
- assert( (pX->exclMask & (p->exclMask|p->sharedMask))==0 );
- allMask |= pX->sharedMask;
- }
-
- /* Unlock the system-level locks */
- if( (mask & allMask)==0 ){
- rc = os2ShmSystemLock(pShmNode, _SHM_UNLCK, ofst+OS2_SHM_BASE, n);
- }else{
- rc = SQLITE_OK;
- }
-
- /* Undo the local locks */
- if( rc==SQLITE_OK ){
- p->exclMask &= ~mask;
- p->sharedMask &= ~mask;
- }
- }else if( flags & SQLITE_SHM_SHARED ){
- u32 allShared = 0; /* Union of locks held by connections other than "p" */
-
- /* Find out which shared locks are already held by sibling connections.
- ** If any sibling already holds an exclusive lock, go ahead and return
- ** SQLITE_BUSY.
- */
- for(pX=pShmNode->pFirst; pX; pX=pX->pNext){
- if( (pX->exclMask & mask)!=0 ){
- rc = SQLITE_BUSY;
- break;
- }
- allShared |= pX->sharedMask;
- }
-
- /* Get shared locks at the system level, if necessary */
- if( rc==SQLITE_OK ){
- if( (allShared & mask)==0 ){
- rc = os2ShmSystemLock(pShmNode, _SHM_RDLCK, ofst+OS2_SHM_BASE, n);
- }else{
- rc = SQLITE_OK;
- }
- }
-
- /* Get the local shared locks */
- if( rc==SQLITE_OK ){
- p->sharedMask |= mask;
- }
- }else{
- /* Make sure no sibling connections hold locks that will block this
- ** lock. If any do, return SQLITE_BUSY right away.
- */
- for(pX=pShmNode->pFirst; pX; pX=pX->pNext){
- if( (pX->exclMask & mask)!=0 || (pX->sharedMask & mask)!=0 ){
- rc = SQLITE_BUSY;
- break;
- }
- }
-
- /* Get the exclusive locks at the system level. Then if successful
- ** also mark the local connection as being locked.
- */
- if( rc==SQLITE_OK ){
- rc = os2ShmSystemLock(pShmNode, _SHM_WRLCK, ofst+OS2_SHM_BASE, n);
- if( rc==SQLITE_OK ){
- assert( (p->sharedMask & mask)==0 );
- p->exclMask |= mask;
- }
- }
- }
-
- sqlite3_mutex_leave(pShmNode->mutex);
-
- OSTRACE(("SHM-LOCK shmid-%d, pid-%d got %03x,%03x %s\n",
- p->id, (int)GetCurrentProcessId(), p->sharedMask, p->exclMask,
- rc ? "failed" : "ok"));
-
- ERR_TRACE(rc, ("os2ShmLock: ofst = %d, n = %d, flags = 0x%x -> %d \n",
- ofst, n, flags, rc))
-
- return rc;
-}
-
-/*
-** Implement a memory barrier or memory fence on shared memory.
-**
-** All loads and stores begun before the barrier must complete before
-** any load or store begun after the barrier.
-*/
-static void os2ShmBarrier(
- sqlite3_file *id /* Database file holding the shared memory */
-){
- UNUSED_PARAMETER(id);
- os2ShmEnterMutex();
- os2ShmLeaveMutex();
-}
-
-#else
-# define os2ShmMap 0
-# define os2ShmLock 0
-# define os2ShmBarrier 0
-# define os2ShmUnmap 0
-#endif /* #ifndef SQLITE_OMIT_WAL */
-
-
-/*
-** This vector defines all the methods that can operate on an
-** sqlite3_file for os2.
-*/
-static const sqlite3_io_methods os2IoMethod = {
- 2, /* iVersion */
- os2Close, /* xClose */
- os2Read, /* xRead */
- os2Write, /* xWrite */
- os2Truncate, /* xTruncate */
- os2Sync, /* xSync */
- os2FileSize, /* xFileSize */
- os2Lock, /* xLock */
- os2Unlock, /* xUnlock */
- os2CheckReservedLock, /* xCheckReservedLock */
- os2FileControl, /* xFileControl */
- os2SectorSize, /* xSectorSize */
- os2DeviceCharacteristics, /* xDeviceCharacteristics */
- os2ShmMap, /* xShmMap */
- os2ShmLock, /* xShmLock */
- os2ShmBarrier, /* xShmBarrier */
- os2ShmUnmap /* xShmUnmap */
-};
-
-
-/***************************************************************************
-** Here ends the I/O methods that form the sqlite3_io_methods object.
-**
-** The next block of code implements the VFS methods.
-****************************************************************************/
-
-/*
-** Create a temporary file name in zBuf. zBuf must be big enough to
-** hold at pVfs->mxPathname characters.
-*/
-static int getTempname(int nBuf, char *zBuf ){
- static const char zChars[] =
- "abcdefghijklmnopqrstuvwxyz"
- "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
- "0123456789";
- int i, j;
- PSZ zTempPathCp;
- char zTempPath[CCHMAXPATH];
- ULONG ulDriveNum, ulDriveMap;
-
- /* It's odd to simulate an io-error here, but really this is just
- ** using the io-error infrastructure to test that SQLite handles this
- ** function failing.
- */
- SimulateIOError( return SQLITE_IOERR );
-
- if( sqlite3_temp_directory ) {
- sqlite3_snprintf(CCHMAXPATH-30, zTempPath, "%s", sqlite3_temp_directory);
- } else if( DosScanEnv( (PSZ)"TEMP", &zTempPathCp ) == NO_ERROR ||
- DosScanEnv( (PSZ)"TMP", &zTempPathCp ) == NO_ERROR ||
- DosScanEnv( (PSZ)"TMPDIR", &zTempPathCp ) == NO_ERROR ) {
- char *zTempPathUTF = convertCpPathToUtf8( (char *)zTempPathCp );
- sqlite3_snprintf(CCHMAXPATH-30, zTempPath, "%s", zTempPathUTF);
- free( zTempPathUTF );
- } else if( DosQueryCurrentDisk( &ulDriveNum, &ulDriveMap ) == NO_ERROR ) {
- zTempPath[0] = (char)('A' + ulDriveNum - 1);
- zTempPath[1] = ':';
- zTempPath[2] = '\0';
- } else {
- zTempPath[0] = '\0';
- }
-
- /* Strip off a trailing slashes or backslashes, otherwise we would get *
- * multiple (back)slashes which causes DosOpen() to fail. *
- * Trailing spaces are not allowed, either. */
- j = sqlite3Strlen30(zTempPath);
- while( j > 0 && ( zTempPath[j-1] == '\\' || zTempPath[j-1] == '/' ||
- zTempPath[j-1] == ' ' ) ){
- j--;
- }
- zTempPath[j] = '\0';
-
- /* We use 20 bytes to randomize the name */
- sqlite3_snprintf(nBuf-22, zBuf,
- "%s\\"SQLITE_TEMP_FILE_PREFIX, zTempPath);
- j = sqlite3Strlen30(zBuf);
- sqlite3_randomness( 20, &zBuf[j] );
- for( i = 0; i < 20; i++, j++ ){
- zBuf[j] = zChars[ ((unsigned char)zBuf[j])%(sizeof(zChars)-1) ];
- }
- zBuf[j] = 0;
-
- OSTRACE(( "TEMP FILENAME: %s\n", zBuf ));
- return SQLITE_OK;
-}
-
-
-/*
-** Turn a relative pathname into a full pathname. Write the full
-** pathname into zFull[]. zFull[] will be at least pVfs->mxPathname
-** bytes in size.
-*/
-static int os2FullPathname(
- sqlite3_vfs *pVfs, /* Pointer to vfs object */
- const char *zRelative, /* Possibly relative input path */
- int nFull, /* Size of output buffer in bytes */
- char *zFull /* Output buffer */
-){
- char *zRelativeCp = convertUtf8PathToCp( zRelative );
- char zFullCp[CCHMAXPATH] = "\0";
- char *zFullUTF;
- APIRET rc = DosQueryPathInfo( (PSZ)zRelativeCp, FIL_QUERYFULLNAME,
- zFullCp, CCHMAXPATH );
- free( zRelativeCp );
- zFullUTF = convertCpPathToUtf8( zFullCp );
- sqlite3_snprintf( nFull, zFull, zFullUTF );
- free( zFullUTF );
- return rc == NO_ERROR ? SQLITE_OK : SQLITE_IOERR;
-}
-
-
-/*
-** Open a file.
-*/
-static int os2Open(
- sqlite3_vfs *pVfs, /* Not used */
- const char *zName, /* Name of the file (UTF-8) */
- sqlite3_file *id, /* Write the SQLite file handle here */
- int flags, /* Open mode flags */
- int *pOutFlags /* Status return flags */
-){
- HFILE h;
- ULONG ulOpenFlags = 0;
- ULONG ulOpenMode = 0;
- ULONG ulAction = 0;
- ULONG rc;
- os2File *pFile = (os2File*)id;
- const char *zUtf8Name = zName;
- char *zNameCp;
- char zTmpname[CCHMAXPATH];
-
- int isExclusive = (flags & SQLITE_OPEN_EXCLUSIVE);
- int isCreate = (flags & SQLITE_OPEN_CREATE);
- int isReadWrite = (flags & SQLITE_OPEN_READWRITE);
-#ifndef NDEBUG
- int isDelete = (flags & SQLITE_OPEN_DELETEONCLOSE);
- int isReadonly = (flags & SQLITE_OPEN_READONLY);
- int eType = (flags & 0xFFFFFF00);
- int isOpenJournal = (isCreate && (
- eType==SQLITE_OPEN_MASTER_JOURNAL
- || eType==SQLITE_OPEN_MAIN_JOURNAL
- || eType==SQLITE_OPEN_WAL
- ));
-#endif
-
- UNUSED_PARAMETER(pVfs);
- assert( id!=0 );
-
- /* Check the following statements are true:
- **
- ** (a) Exactly one of the READWRITE and READONLY flags must be set, and
- ** (b) if CREATE is set, then READWRITE must also be set, and
- ** (c) if EXCLUSIVE is set, then CREATE must also be set.
- ** (d) if DELETEONCLOSE is set, then CREATE must also be set.
- */
- assert((isReadonly==0 || isReadWrite==0) && (isReadWrite || isReadonly));
- assert(isCreate==0 || isReadWrite);
- assert(isExclusive==0 || isCreate);
- assert(isDelete==0 || isCreate);
-
- /* The main DB, main journal, WAL file and master journal are never
- ** automatically deleted. Nor are they ever temporary files. */
- assert( (!isDelete && zName) || eType!=SQLITE_OPEN_MAIN_DB );
- assert( (!isDelete && zName) || eType!=SQLITE_OPEN_MAIN_JOURNAL );
- assert( (!isDelete && zName) || eType!=SQLITE_OPEN_MASTER_JOURNAL );
- assert( (!isDelete && zName) || eType!=SQLITE_OPEN_WAL );
-
- /* Assert that the upper layer has set one of the "file-type" flags. */
- assert( eType==SQLITE_OPEN_MAIN_DB || eType==SQLITE_OPEN_TEMP_DB
- || eType==SQLITE_OPEN_MAIN_JOURNAL || eType==SQLITE_OPEN_TEMP_JOURNAL
- || eType==SQLITE_OPEN_SUBJOURNAL || eType==SQLITE_OPEN_MASTER_JOURNAL
- || eType==SQLITE_OPEN_TRANSIENT_DB || eType==SQLITE_OPEN_WAL
- );
-
- memset( pFile, 0, sizeof(*pFile) );
- pFile->h = (HFILE)-1;
-
- /* If the second argument to this function is NULL, generate a
- ** temporary file name to use
- */
- if( !zUtf8Name ){
- assert(isDelete && !isOpenJournal);
- rc = getTempname(CCHMAXPATH, zTmpname);
- if( rc!=SQLITE_OK ){
- return rc;
- }
- zUtf8Name = zTmpname;
- }
-
- if( isReadWrite ){
- ulOpenMode |= OPEN_ACCESS_READWRITE;
- }else{
- ulOpenMode |= OPEN_ACCESS_READONLY;
- }
-
- /* Open in random access mode for possibly better speed. Allow full
- ** sharing because file locks will provide exclusive access when needed.
- ** The handle should not be inherited by child processes and we don't
- ** want popups from the critical error handler.
- */
- ulOpenMode |= OPEN_FLAGS_RANDOM | OPEN_SHARE_DENYNONE |
- OPEN_FLAGS_NOINHERIT | OPEN_FLAGS_FAIL_ON_ERROR;
-
- /* SQLITE_OPEN_EXCLUSIVE is used to make sure that a new file is
- ** created. SQLite doesn't use it to indicate "exclusive access"
- ** as it is usually understood.
- */
- if( isExclusive ){
- /* Creates a new file, only if it does not already exist. */
- /* If the file exists, it fails. */
- ulOpenFlags |= OPEN_ACTION_CREATE_IF_NEW | OPEN_ACTION_FAIL_IF_EXISTS;
- }else if( isCreate ){
- /* Open existing file, or create if it doesn't exist */
- ulOpenFlags |= OPEN_ACTION_CREATE_IF_NEW | OPEN_ACTION_OPEN_IF_EXISTS;
- }else{
- /* Opens a file, only if it exists. */
- ulOpenFlags |= OPEN_ACTION_FAIL_IF_NEW | OPEN_ACTION_OPEN_IF_EXISTS;
- }
-
- zNameCp = convertUtf8PathToCp( zUtf8Name );
- rc = DosOpen( (PSZ)zNameCp,
- &h,
- &ulAction,
- 0L,
- FILE_NORMAL,
- ulOpenFlags,
- ulOpenMode,
- (PEAOP2)NULL );
- free( zNameCp );
-
- if( rc != NO_ERROR ){
- OSTRACE(( "OPEN Invalid handle rc=%d: zName=%s, ulAction=%#lx, ulFlags=%#lx, ulMode=%#lx\n",
- rc, zUtf8Name, ulAction, ulOpenFlags, ulOpenMode ));
-
- if( isReadWrite ){
- return os2Open( pVfs, zName, id,
- ((flags|SQLITE_OPEN_READONLY)&~(SQLITE_OPEN_CREATE|SQLITE_OPEN_READWRITE)),
- pOutFlags );
- }else{
- return SQLITE_CANTOPEN;
- }
- }
-
- if( pOutFlags ){
- *pOutFlags = isReadWrite ? SQLITE_OPEN_READWRITE : SQLITE_OPEN_READONLY;
- }
-
- os2FullPathname( pVfs, zUtf8Name, sizeof( zTmpname ), zTmpname );
- pFile->zFullPathCp = convertUtf8PathToCp( zTmpname );
- pFile->pMethod = &os2IoMethod;
- pFile->flags = flags;
- pFile->h = h;
-
- OpenCounter(+1);
- OSTRACE(( "OPEN %d pOutFlags=%d\n", pFile->h, pOutFlags ));
- return SQLITE_OK;
-}
-
-/*
-** Delete the named file.
-*/
-static int os2Delete(
- sqlite3_vfs *pVfs, /* Not used on os2 */
- const char *zFilename, /* Name of file to delete */
- int syncDir /* Not used on os2 */
-){
- APIRET rc;
- char *zFilenameCp;
- SimulateIOError( return SQLITE_IOERR_DELETE );
- zFilenameCp = convertUtf8PathToCp( zFilename );
- rc = DosDelete( (PSZ)zFilenameCp );
- free( zFilenameCp );
- OSTRACE(( "DELETE \"%s\"\n", zFilename ));
- return (rc == NO_ERROR ||
- rc == ERROR_FILE_NOT_FOUND ||
- rc == ERROR_PATH_NOT_FOUND ) ? SQLITE_OK : SQLITE_IOERR_DELETE;
-}
-
-/*
-** Check the existance and status of a file.
-*/
-static int os2Access(
- sqlite3_vfs *pVfs, /* Not used on os2 */
- const char *zFilename, /* Name of file to check */
- int flags, /* Type of test to make on this file */
- int *pOut /* Write results here */
-){
- APIRET rc;
- FILESTATUS3 fsts3ConfigInfo;
- char *zFilenameCp;
-
- UNUSED_PARAMETER(pVfs);
- SimulateIOError( return SQLITE_IOERR_ACCESS; );
-
- zFilenameCp = convertUtf8PathToCp( zFilename );
- rc = DosQueryPathInfo( (PSZ)zFilenameCp, FIL_STANDARD,
- &fsts3ConfigInfo, sizeof(FILESTATUS3) );
- free( zFilenameCp );
- OSTRACE(( "ACCESS fsts3ConfigInfo.attrFile=%d flags=%d rc=%d\n",
- fsts3ConfigInfo.attrFile, flags, rc ));
-
- switch( flags ){
- case SQLITE_ACCESS_EXISTS:
- /* For an SQLITE_ACCESS_EXISTS query, treat a zero-length file
- ** as if it does not exist.
- */
- if( fsts3ConfigInfo.cbFile == 0 )
- rc = ERROR_FILE_NOT_FOUND;
- break;
- case SQLITE_ACCESS_READ:
- break;
- case SQLITE_ACCESS_READWRITE:
- if( fsts3ConfigInfo.attrFile & FILE_READONLY )
- rc = ERROR_ACCESS_DENIED;
- break;
- default:
- rc = ERROR_FILE_NOT_FOUND;
- assert( !"Invalid flags argument" );
- }
-
- *pOut = (rc == NO_ERROR);
- OSTRACE(( "ACCESS %s flags %d: rc=%d\n", zFilename, flags, *pOut ));
-
- return SQLITE_OK;
-}
-
-
-#ifndef SQLITE_OMIT_LOAD_EXTENSION
-/*
-** Interfaces for opening a shared library, finding entry points
-** within the shared library, and closing the shared library.
-*/
-/*
-** Interfaces for opening a shared library, finding entry points
-** within the shared library, and closing the shared library.
-*/
-static void *os2DlOpen(sqlite3_vfs *pVfs, const char *zFilename){
- HMODULE hmod;
- APIRET rc;
- char *zFilenameCp = convertUtf8PathToCp(zFilename);
- rc = DosLoadModule(NULL, 0, (PSZ)zFilenameCp, &hmod);
- free(zFilenameCp);
- return rc != NO_ERROR ? 0 : (void*)hmod;
-}
-/*
-** A no-op since the error code is returned on the DosLoadModule call.
-** os2Dlopen returns zero if DosLoadModule is not successful.
-*/
-static void os2DlError(sqlite3_vfs *pVfs, int nBuf, char *zBufOut){
-/* no-op */
-}
-static void (*os2DlSym(sqlite3_vfs *pVfs, void *pHandle, const char *zSymbol))(void){
- PFN pfn;
- APIRET rc;
- rc = DosQueryProcAddr((HMODULE)pHandle, 0L, (PSZ)zSymbol, &pfn);
- if( rc != NO_ERROR ){
- /* if the symbol itself was not found, search again for the same
- * symbol with an extra underscore, that might be needed depending
- * on the calling convention */
- char _zSymbol[256] = "_";
- strncat(_zSymbol, zSymbol, 254);
- rc = DosQueryProcAddr((HMODULE)pHandle, 0L, (PSZ)_zSymbol, &pfn);
- }
- return rc != NO_ERROR ? 0 : (void(*)(void))pfn;
-}
-static void os2DlClose(sqlite3_vfs *pVfs, void *pHandle){
- DosFreeModule((HMODULE)pHandle);
-}
-#else /* if SQLITE_OMIT_LOAD_EXTENSION is defined: */
- #define os2DlOpen 0
- #define os2DlError 0
- #define os2DlSym 0
- #define os2DlClose 0
-#endif
-
-
-/*
-** Write up to nBuf bytes of randomness into zBuf.
-*/
-static int os2Randomness(sqlite3_vfs *pVfs, int nBuf, char *zBuf ){
- int n = 0;
-#if defined(SQLITE_TEST)
- n = nBuf;
- memset(zBuf, 0, nBuf);
-#else
- int i;
- PPIB ppib;
- PTIB ptib;
- DATETIME dt;
- static unsigned c = 0;
- /* Ordered by variation probability */
- static ULONG svIdx[6] = { QSV_MS_COUNT, QSV_TIME_LOW,
- QSV_MAXPRMEM, QSV_MAXSHMEM,
- QSV_TOTAVAILMEM, QSV_TOTRESMEM };
-
- /* 8 bytes; timezone and weekday don't increase the randomness much */
- if( (int)sizeof(dt)-3 <= nBuf - n ){
- c += 0x0100;
- DosGetDateTime(&dt);
- dt.year = (USHORT)((dt.year - 1900) | c);
- memcpy(&zBuf[n], &dt, sizeof(dt)-3);
- n += sizeof(dt)-3;
- }
-
- /* 4 bytes; PIDs and TIDs are 16 bit internally, so combine them */
- if( (int)sizeof(ULONG) <= nBuf - n ){
- DosGetInfoBlocks(&ptib, &ppib);
- *(PULONG)&zBuf[n] = MAKELONG(ppib->pib_ulpid,
- ptib->tib_ptib2->tib2_ultid);
- n += sizeof(ULONG);
- }
-
- /* Up to 6 * 4 bytes; variables depend on the system state */
- for( i = 0; i < 6 && (int)sizeof(ULONG) <= nBuf - n; i++ ){
- DosQuerySysInfo(svIdx[i], svIdx[i],
- (PULONG)&zBuf[n], sizeof(ULONG));
- n += sizeof(ULONG);
- }
-#endif
-
- return n;
-}
-
-/*
-** Sleep for a little while. Return the amount of time slept.
-** The argument is the number of microseconds we want to sleep.
-** The return value is the number of microseconds of sleep actually
-** requested from the underlying operating system, a number which
-** might be greater than or equal to the argument, but not less
-** than the argument.
-*/
-static int os2Sleep( sqlite3_vfs *pVfs, int microsec ){
- DosSleep( (microsec/1000) );
- return microsec;
-}
-
-/*
-** The following variable, if set to a non-zero value, becomes the result
-** returned from sqlite3OsCurrentTime(). This is used for testing.
-*/
-#ifdef SQLITE_TEST
-SQLITE_API int sqlite3_current_time = 0;
-#endif
-
-/*
-** Find the current time (in Universal Coordinated Time). Write into *piNow
-** the current time and date as a Julian Day number times 86_400_000. In
-** other words, write into *piNow the number of milliseconds since the Julian
-** epoch of noon in Greenwich on November 24, 4714 B.C according to the
-** proleptic Gregorian calendar.
-**
-** On success, return 0. Return 1 if the time and date cannot be found.
-*/
-static int os2CurrentTimeInt64(sqlite3_vfs *pVfs, sqlite3_int64 *piNow){
-#ifdef SQLITE_TEST
- static const sqlite3_int64 unixEpoch = 24405875*(sqlite3_int64)8640000;
-#endif
- int year, month, datepart, timepart;
-
- DATETIME dt;
- DosGetDateTime( &dt );
-
- year = dt.year;
- month = dt.month;
-
- /* Calculations from http://www.astro.keele.ac.uk/~rno/Astronomy/hjd.html
- ** http://www.astro.keele.ac.uk/~rno/Astronomy/hjd-0.1.c
- ** Calculate the Julian days
- */
- datepart = (int)dt.day - 32076 +
- 1461*(year + 4800 + (month - 14)/12)/4 +
- 367*(month - 2 - (month - 14)/12*12)/12 -
- 3*((year + 4900 + (month - 14)/12)/100)/4;
-
- /* Time in milliseconds, hours to noon added */
- timepart = 12*3600*1000 + dt.hundredths*10 + dt.seconds*1000 +
- ((int)dt.minutes + dt.timezone)*60*1000 + dt.hours*3600*1000;
-
- *piNow = (sqlite3_int64)datepart*86400*1000 + timepart;
-
-#ifdef SQLITE_TEST
- if( sqlite3_current_time ){
- *piNow = 1000*(sqlite3_int64)sqlite3_current_time + unixEpoch;
- }
-#endif
-
- UNUSED_PARAMETER(pVfs);
- return 0;
-}
-
-/*
-** Find the current time (in Universal Coordinated Time). Write the
-** current time and date as a Julian Day number into *prNow and
-** return 0. Return 1 if the time and date cannot be found.
-*/
-static int os2CurrentTime( sqlite3_vfs *pVfs, double *prNow ){
- int rc;
- sqlite3_int64 i;
- rc = os2CurrentTimeInt64(pVfs, &i);
- if( !rc ){
- *prNow = i/86400000.0;
- }
- return rc;
-}
-
-/*
-** The idea is that this function works like a combination of
-** GetLastError() and FormatMessage() on windows (or errno and
-** strerror_r() on unix). After an error is returned by an OS
-** function, SQLite calls this function with zBuf pointing to
-** a buffer of nBuf bytes. The OS layer should populate the
-** buffer with a nul-terminated UTF-8 encoded error message
-** describing the last IO error to have occurred within the calling
-** thread.
-**
-** If the error message is too large for the supplied buffer,
-** it should be truncated. The return value of xGetLastError
-** is zero if the error message fits in the buffer, or non-zero
-** otherwise (if the message was truncated). If non-zero is returned,
-** then it is not necessary to include the nul-terminator character
-** in the output buffer.
-**
-** Not supplying an error message will have no adverse effect
-** on SQLite. It is fine to have an implementation that never
-** returns an error message:
-**
-** int xGetLastError(sqlite3_vfs *pVfs, int nBuf, char *zBuf){
-** assert(zBuf[0]=='\0');
-** return 0;
-** }
-**
-** However if an error message is supplied, it will be incorporated
-** by sqlite into the error message available to the user using
-** sqlite3_errmsg(), possibly making IO errors easier to debug.
-*/
-static int os2GetLastError(sqlite3_vfs *pVfs, int nBuf, char *zBuf){
- assert(zBuf[0]=='\0');
- return 0;
-}
-
-/*
-** Initialize and deinitialize the operating system interface.
-*/
-SQLITE_API int sqlite3_os_init(void){
- static sqlite3_vfs os2Vfs = {
- 3, /* iVersion */
- sizeof(os2File), /* szOsFile */
- CCHMAXPATH, /* mxPathname */
- 0, /* pNext */
- "os2", /* zName */
- 0, /* pAppData */
-
- os2Open, /* xOpen */
- os2Delete, /* xDelete */
- os2Access, /* xAccess */
- os2FullPathname, /* xFullPathname */
- os2DlOpen, /* xDlOpen */
- os2DlError, /* xDlError */
- os2DlSym, /* xDlSym */
- os2DlClose, /* xDlClose */
- os2Randomness, /* xRandomness */
- os2Sleep, /* xSleep */
- os2CurrentTime, /* xCurrentTime */
- os2GetLastError, /* xGetLastError */
- os2CurrentTimeInt64, /* xCurrentTimeInt64 */
- 0, /* xSetSystemCall */
- 0, /* xGetSystemCall */
- 0 /* xNextSystemCall */
- };
- sqlite3_vfs_register(&os2Vfs, 1);
- initUconvObjects();
-/* sqlite3OSTrace = 1; */
- return SQLITE_OK;
-}
-SQLITE_API int sqlite3_os_end(void){
- freeUconvObjects();
- return SQLITE_OK;
-}
-
-#endif /* SQLITE_OS_OS2 */
-
-/************** End of os_os2.c **********************************************/
/************** Begin file os_unix.c *****************************************/
/*
** 2004 May 22
@@ -24323,7 +22768,12 @@ SQLITE_API int sqlite3_os_end(void){
*/
#if SQLITE_OS_UNIX /* This file is used on unix only */
-#include <qconfig.h>
+/* Use posix_fallocate() if it is available
+*/
+#if !defined(HAVE_POSIX_FALLOCATE) \
+ && (_XOPEN_SOURCE >= 600 || _POSIX_C_SOURCE >= 200112L)
+# define HAVE_POSIX_FALLOCATE 1
+#endif
/*
** There are various methods for file locking used for concurrency
@@ -24395,16 +22845,14 @@ SQLITE_API int sqlite3_os_end(void){
#include <sys/stat.h>
#include <fcntl.h>
#include <unistd.h>
-#ifdef VXWORKS
-# include <sys/times.h>
-#else
-# include <sys/time.h>
-#endif
+/* #include <time.h> */
+#include <sys/time.h>
#include <errno.h>
#ifndef SQLITE_OMIT_WAL
#include <sys/mman.h>
#endif
+
#if SQLITE_ENABLE_LOCKING_STYLE
# include <sys/ioctl.h>
# if OS_VXWORKS
@@ -24433,7 +22881,8 @@ SQLITE_API int sqlite3_os_end(void){
** If we are to be thread-safe, include the pthreads header and define
** the SQLITE_UNIX_THREADS macro.
*/
-#ifndef QT_NO_THREAD
+#if SQLITE_THREADSAFE
+/* # include <pthread.h> */
# define SQLITE_UNIX_THREADS 1
#endif
@@ -24445,8 +22894,8 @@ SQLITE_API int sqlite3_os_end(void){
#endif
/*
- ** Default permissions when creating auto proxy dir
- */
+** Default permissions when creating auto proxy dir
+*/
#ifndef SQLITE_DEFAULT_PROXYDIR_PERMISSIONS
# define SQLITE_DEFAULT_PROXYDIR_PERMISSIONS 0755
#endif
@@ -24487,17 +22936,21 @@ struct UnixUnusedFd {
typedef struct unixFile unixFile;
struct unixFile {
sqlite3_io_methods const *pMethod; /* Always the first entry */
+ sqlite3_vfs *pVfs; /* The VFS that created this unixFile */
unixInodeInfo *pInode; /* Info about locks on this inode */
int h; /* The file descriptor */
- int dirfd; /* File descriptor for the directory */
unsigned char eFileLock; /* The type of lock held on this fd */
- unsigned char ctrlFlags; /* Behavioral bits. UNIXFILE_* flags */
+ unsigned short int ctrlFlags; /* Behavioral bits. UNIXFILE_* flags */
int lastErrno; /* The unix errno from last I/O error */
void *lockingContext; /* Locking style specific state */
UnixUnusedFd *pUnused; /* Pre-allocated UnixUnusedFd */
const char *zPath; /* Name of the file */
unixShm *pShm; /* Shared memory segment information */
int szChunk; /* Configured by FCNTL_CHUNK_SIZE */
+#ifdef __QNXNTO__
+ int sectorSize; /* Device sector size */
+ int deviceCharacteristics; /* Precomputed device characteristics */
+#endif
#if SQLITE_ENABLE_LOCKING_STYLE
int openFlags; /* The flags specified at open() */
#endif
@@ -24505,10 +22958,9 @@ struct unixFile {
unsigned fsFlags; /* cached details from statfs() */
#endif
#if OS_VXWORKS
- int isDelete; /* Delete on close if true */
struct vxworksFileId *pId; /* Unique file ID */
#endif
-#ifndef NDEBUG
+#ifdef SQLITE_DEBUG
/* The next group of variables are used to track whether or not the
** transaction counter in bytes 24-27 of database files are updated
** whenever any part of the database changes. An assertion fault will
@@ -24531,8 +22983,18 @@ struct unixFile {
/*
** Allowed values for the unixFile.ctrlFlags bitmask:
*/
-#define UNIXFILE_EXCL 0x01 /* Connections from one process only */
-#define UNIXFILE_RDONLY 0x02 /* Connection is read only */
+#define UNIXFILE_EXCL 0x01 /* Connections from one process only */
+#define UNIXFILE_RDONLY 0x02 /* Connection is read only */
+#define UNIXFILE_PERSIST_WAL 0x04 /* Persistent WAL mode */
+#ifndef SQLITE_DISABLE_DIRSYNC
+# define UNIXFILE_DIRSYNC 0x08 /* Directory sync needed */
+#else
+# define UNIXFILE_DIRSYNC 0x00
+#endif
+#define UNIXFILE_PSOW 0x10 /* SQLITE_IOCAP_POWERSAFE_OVERWRITE */
+#define UNIXFILE_DELETE 0x20 /* Delete on close */
+#define UNIXFILE_URI 0x40 /* Filename might have query parameters */
+#define UNIXFILE_NOLOCK 0x80 /* Do no file locking */
/*
** Include code that is common to all os_*.c files
@@ -24570,11 +23032,14 @@ struct unixFile {
# error "The MEMORY_DEBUG macro is obsolete. Use SQLITE_DEBUG instead."
#endif
-#ifdef SQLITE_DEBUG
-SQLITE_PRIVATE int sqlite3OSTrace = 0;
-#define OSTRACE(X) if( sqlite3OSTrace ) sqlite3DebugPrintf X
+#if defined(SQLITE_TEST) && defined(SQLITE_DEBUG)
+# ifndef SQLITE_DEBUG_OS_TRACE
+# define SQLITE_DEBUG_OS_TRACE 0
+# endif
+ int sqlite3OSTrace = SQLITE_DEBUG_OS_TRACE;
+# define OSTRACE(X) if( sqlite3OSTrace ) sqlite3DebugPrintf X
#else
-#define OSTRACE(X)
+# define OSTRACE(X)
#endif
/*
@@ -24784,13 +23249,25 @@ static int posixOpen(const char *zFile, int flags, int mode){
}
/*
+** On some systems, calls to fchown() will trigger a message in a security
+** log if they come from non-root processes. So avoid calling fchown() if
+** we are not running as root.
+*/
+static int posixFchown(int fd, uid_t uid, gid_t gid){
+ return geteuid() ? 0 : fchown(fd,uid,gid);
+}
+
+/* Forward reference */
+static int openDirectory(const char*, int*);
+
+/*
** Many system calls are accessed through pointer-to-functions so that
** they may be overridden at runtime to facilitate fault injection during
** testing and sandboxing. The following array holds the names and pointers
** to all overrideable system calls.
*/
static struct unix_syscall {
- const char *zName; /* Name of the sytem call */
+ const char *zName; /* Name of the system call */
sqlite3_syscall_ptr pCurrent; /* Current value of the system call */
sqlite3_syscall_ptr pDefault; /* Default value */
} aSyscall[] = {
@@ -24847,12 +23324,7 @@ static struct unix_syscall {
#define osPread64 ((ssize_t(*)(int,void*,size_t,off_t))aSyscall[10].pCurrent)
{ "write", (sqlite3_syscall_ptr)write, 0 },
-
-#ifndef VXWORKS
- #define osWrite ((ssize_t(*)(int,const void*,size_t))aSyscall[11].pCurrent)
-#else
- #define osWrite ((ssize_t(*)(int,char*,size_t))aSyscall[11].pCurrent)
-#endif
+#define osWrite ((ssize_t(*)(int,const void*,size_t))aSyscall[11].pCurrent)
#if defined(USE_PREAD) || SQLITE_ENABLE_LOCKING_STYLE
{ "pwrite", (sqlite3_syscall_ptr)pwrite, 0 },
@@ -24870,11 +23342,7 @@ static struct unix_syscall {
#define osPwrite64 ((ssize_t(*)(int,const void*,size_t,off_t))\
aSyscall[13].pCurrent)
-#if SQLITE_ENABLE_LOCKING_STYLE
{ "fchmod", (sqlite3_syscall_ptr)fchmod, 0 },
-#else
- { "fchmod", (sqlite3_syscall_ptr)0, 0 },
-#endif
#define osFchmod ((int(*)(int,mode_t))aSyscall[14].pCurrent)
#if defined(HAVE_POSIX_FALLOCATE) && HAVE_POSIX_FALLOCATE
@@ -24884,6 +23352,21 @@ static struct unix_syscall {
#endif
#define osFallocate ((int(*)(int,off_t,off_t))aSyscall[15].pCurrent)
+ { "unlink", (sqlite3_syscall_ptr)unlink, 0 },
+#define osUnlink ((int(*)(const char*))aSyscall[16].pCurrent)
+
+ { "openDirectory", (sqlite3_syscall_ptr)openDirectory, 0 },
+#define osOpenDirectory ((int(*)(const char*,int*))aSyscall[17].pCurrent)
+
+ { "mkdir", (sqlite3_syscall_ptr)mkdir, 0 },
+#define osMkdir ((int(*)(const char*,mode_t))aSyscall[18].pCurrent)
+
+ { "rmdir", (sqlite3_syscall_ptr)rmdir, 0 },
+#define osRmdir ((int(*)(const char*))aSyscall[19].pCurrent)
+
+ { "fchown", (sqlite3_syscall_ptr)posixFchown, 0 },
+#define osFchown ((int(*)(int,uid_t,gid_t))aSyscall[20].pCurrent)
+
}; /* End of the overrideable system calls */
/*
@@ -24970,12 +23453,47 @@ static const char *unixNextSystemCall(sqlite3_vfs *p, const char *zName){
}
/*
-** Retry open() calls that fail due to EINTR
+** Invoke open(). Do so multiple times, until it either succeeds or
+** fails for some reason other than EINTR.
+**
+** If the file creation mode "m" is 0 then set it to the default for
+** SQLite. The default is SQLITE_DEFAULT_FILE_PERMISSIONS (normally
+** 0644) as modified by the system umask. If m is not 0, then
+** make the file creation mode be exactly m ignoring the umask.
+**
+** The m parameter will be non-zero only when creating -wal, -journal,
+** and -shm files. We want those files to have *exactly* the same
+** permissions as their original database, unadulterated by the umask.
+** In that way, if a database file is -rw-rw-rw or -rw-rw-r-, and a
+** transaction crashes and leaves behind hot journals, then any
+** process that is able to write to the database will also be able to
+** recover the hot journals.
*/
-static int robust_open(const char *z, int f, int m){
- int rc;
- do{ rc = osOpen(z,f,m); }while( rc<0 && errno==EINTR );
- return rc;
+static int robust_open(const char *z, int f, mode_t m){
+ int fd;
+ mode_t m2 = m ? m : SQLITE_DEFAULT_FILE_PERMISSIONS;
+ do{
+#if defined(O_CLOEXEC)
+ fd = osOpen(z,f|O_CLOEXEC,m2);
+#else
+ fd = osOpen(z,f,m2);
+#endif
+ }while( fd<0 && errno==EINTR );
+ if( fd>=0 ){
+ if( m!=0 ){
+ struct stat statbuf;
+ if( osFstat(fd, &statbuf)==0
+ && statbuf.st_size==0
+ && (statbuf.st_mode&0777)!=m
+ ){
+ osFchmod(fd, m);
+ }
+ }
+#if defined(FD_CLOEXEC) && (!defined(O_CLOEXEC) || O_CLOEXEC==0)
+ osFcntl(fd, F_SETFD, osFcntl(fd, F_GETFD, 0) | FD_CLOEXEC);
+#endif
+ }
+ return fd;
}
/*
@@ -25005,7 +23523,7 @@ static int unixMutexHeld(void) {
#endif
-#ifdef SQLITE_DEBUG
+#if defined(SQLITE_TEST) && defined(SQLITE_DEBUG)
/*
** Helper function for printing out trace information from debugging
** binaries. This returns the string represetation of the supplied
@@ -25132,9 +23650,9 @@ static int sqliteErrorFromPosixError(int posixError, int sqliteIOErr) {
case EACCES:
/* EACCES is like EAGAIN during locking operations, but not any other time*/
if( (sqliteIOErr == SQLITE_IOERR_LOCK) ||
- (sqliteIOErr == SQLITE_IOERR_UNLOCK) ||
- (sqliteIOErr == SQLITE_IOERR_RDLOCK) ||
- (sqliteIOErr == SQLITE_IOERR_CHECKRESERVEDLOCK) ){
+ (sqliteIOErr == SQLITE_IOERR_UNLOCK) ||
+ (sqliteIOErr == SQLITE_IOERR_RDLOCK) ||
+ (sqliteIOErr == SQLITE_IOERR_CHECKRESERVEDLOCK) ){
return SQLITE_BUSY;
}
/* else fall through */
@@ -25168,7 +23686,9 @@ static int sqliteErrorFromPosixError(int posixError, int sqliteIOErr) {
case ENODEV:
case ENXIO:
case ENOENT:
+#ifdef ESTALE /* ESTALE is not defined on Interix systems */
case ESTALE:
+#endif
case ENOSYS:
/* these should force the client to close the file and reconnect */
@@ -25467,7 +23987,7 @@ static unixInodeInfo *inodeList = 0;
** The first argument passed to the macro should be the error code that
** will be returned to SQLite (e.g. SQLITE_IOERR_DELETE, SQLITE_CANTOPEN).
** The two subsequent arguments should be the name of the OS function that
-** failed (e.g. "unlink", "open") and the the associated file-system path,
+** failed (e.g. "unlink", "open") and the associated file-system path,
** if any.
*/
#define unixLogError(a,b,c) unixLogErrorAtLine(a,b,c,__LINE__)
@@ -25490,7 +24010,7 @@ static int unixLogErrorAtLine(
zErr = aErr;
/* If STRERROR_R_CHAR_P (set by autoconf scripts) or __USE_GNU is defined,
- ** assume that the system provides the the GNU version of strerror_r() that
+ ** assume that the system provides the GNU version of strerror_r() that
** returns a pointer to a buffer containing the error message. That pointer
** may point to aErr[], or it may point to some static storage somewhere.
** Otherwise, assume that the system provides the POSIX version of
@@ -25726,11 +24246,6 @@ static int unixCheckReservedLock(sqlite3_file *id, int *pResOut){
return rc;
}
-#ifdef VXWORKS
-static int getpid(){
- return (int)taskIdCurrent();
-}
-#endif
/*
** Attempt to set a system-lock on the file pFile. The lock is
** described by pLock.
@@ -25843,14 +24358,14 @@ static int unixLock(sqlite3_file *id, int eFileLock){
*/
int rc = SQLITE_OK;
unixFile *pFile = (unixFile*)id;
- unixInodeInfo *pInode = pFile->pInode;
+ unixInodeInfo *pInode;
struct flock lock;
int tErrno = 0;
assert( pFile );
OSTRACE(("LOCK %d %s was %s(%s,%d) pid=%d (unix)\n", pFile->h,
azFileLock(eFileLock), azFileLock(pFile->eFileLock),
- azFileLock(pInode->eFileLock), pInode->nShared , getpid()));
+ azFileLock(pFile->pInode->eFileLock), pFile->pInode->nShared , getpid()));
/* If there is already a lock of this type or more restrictive on the
** unixFile, do nothing. Don't use the end_lock: exit path, as
@@ -25991,7 +24506,7 @@ static int unixLock(sqlite3_file *id, int eFileLock){
}
-#ifndef NDEBUG
+#ifdef SQLITE_DEBUG
/* Set up the transaction-counter change checking flags when
** transitioning from a SHARED to a RESERVED lock. The change
** from SHARED to RESERVED marks the beginning of a normal
@@ -26054,7 +24569,6 @@ static int posixUnlock(sqlite3_file *id, int eFileLock, int handleNFSUnlock){
unixInodeInfo *pInode;
struct flock lock;
int rc = SQLITE_OK;
- int h;
assert( pFile );
OSTRACE(("UNLOCK %d %d was %d(%d,%d) pid=%d (unix)\n", pFile->h, eFileLock,
@@ -26066,16 +24580,12 @@ static int posixUnlock(sqlite3_file *id, int eFileLock, int handleNFSUnlock){
return SQLITE_OK;
}
unixEnterMutex();
- h = pFile->h;
pInode = pFile->pInode;
assert( pInode->nShared!=0 );
if( pFile->eFileLock>SHARED_LOCK ){
assert( pInode->eFileLock==pFile->eFileLock );
- SimulateIOErrorBenign(1);
- SimulateIOError( h=(-1) )
- SimulateIOErrorBenign(0);
-#ifndef NDEBUG
+#ifdef SQLITE_DEBUG
/* When reducing a lock such that other processes can start
** reading the database file again, make sure that the
** transaction counter was updated if any part of the database
@@ -26084,11 +24594,6 @@ static int posixUnlock(sqlite3_file *id, int eFileLock, int handleNFSUnlock){
** the file has changed and hence might not know to flush their
** cache. The use of a stale cache can lead to database corruption.
*/
-#if 0
- assert( pFile->inNormalWrite==0
- || pFile->dbUpdate==0
- || pFile->transCntrChng==1 );
-#endif
pFile->inNormalWrite = 0;
#endif
@@ -26190,14 +24695,11 @@ static int posixUnlock(sqlite3_file *id, int eFileLock, int handleNFSUnlock){
lock.l_type = F_UNLCK;
lock.l_whence = SEEK_SET;
lock.l_start = lock.l_len = 0L;
- SimulateIOErrorBenign(1);
- SimulateIOError( h=(-1) )
- SimulateIOErrorBenign(0);
if( unixFileLock(pFile, &lock)==0 ){
pInode->eFileLock = NO_LOCK;
}else{
rc = SQLITE_IOERR_UNLOCK;
- pFile->lastErrno = errno;
+ pFile->lastErrno = errno;
pInode->eFileLock = NO_LOCK;
pFile->eFileLock = NO_LOCK;
}
@@ -26213,7 +24715,7 @@ static int posixUnlock(sqlite3_file *id, int eFileLock, int handleNFSUnlock){
closePendingFds(pFile);
}
}
-
+
end_unlock:
unixLeaveMutex();
if( rc==SQLITE_OK ) pFile->eFileLock = eFileLock;
@@ -26243,18 +24745,14 @@ static int unixUnlock(sqlite3_file *id, int eFileLock){
*/
static int closeUnixFile(sqlite3_file *id){
unixFile *pFile = (unixFile*)id;
- if( pFile->dirfd>=0 ){
- robust_close(pFile, pFile->dirfd, __LINE__);
- pFile->dirfd=-1;
- }
if( pFile->h>=0 ){
robust_close(pFile, pFile->h, __LINE__);
pFile->h = -1;
}
#if OS_VXWORKS
if( pFile->pId ){
- if( pFile->isDelete ){
- unlink(pFile->pId->zCanonicalName);
+ if( pFile->ctrlFlags & UNIXFILE_DELETE ){
+ osUnlink(pFile->pId->zCanonicalName);
}
vxworksReleaseFileId(pFile->pId);
pFile->pId = 0;
@@ -26341,9 +24839,9 @@ static int nolockClose(sqlite3_file *id) {
/******************************************************************************
************************* Begin dot-file Locking ******************************
**
-** The dotfile locking implementation uses the existance of separate lock
-** files in order to control access to the database. This works on just
-** about every filesystem imaginable. But there are serious downsides:
+** The dotfile locking implementation uses the existence of separate lock
+** files (really a directory) to control access to the database. This works
+** on just about every filesystem imaginable. But there are serious downsides:
**
** (1) There is zero concurrency. A single reader blocks all other
** connections from reading or writing the database.
@@ -26354,15 +24852,15 @@ static int nolockClose(sqlite3_file *id) {
** Nevertheless, a dotlock is an appropriate locking mode for use if no
** other locking strategy is available.
**
-** Dotfile locking works by creating a file in the same directory as the
-** database and with the same name but with a ".lock" extension added.
-** The existance of a lock file implies an EXCLUSIVE lock. All other lock
-** types (SHARED, RESERVED, PENDING) are mapped into EXCLUSIVE.
+** Dotfile locking works by creating a subdirectory in the same directory as
+** the database and with the same name but with a ".lock" extension added.
+** The existence of a lock directory implies an EXCLUSIVE lock. All other
+** lock types (SHARED, RESERVED, PENDING) are mapped into EXCLUSIVE.
*/
/*
** The file suffix added to the data base filename in order to create the
-** lock file.
+** lock directory.
*/
#define DOTLOCK_SUFFIX ".lock"
@@ -26429,7 +24927,6 @@ static int dotlockCheckReservedLock(sqlite3_file *id, int *pResOut) {
*/
static int dotlockLock(sqlite3_file *id, int eFileLock) {
unixFile *pFile = (unixFile*)id;
- int fd;
char *zLockFile = (char *)pFile->lockingContext;
int rc = SQLITE_OK;
@@ -26449,9 +24946,9 @@ static int dotlockLock(sqlite3_file *id, int eFileLock) {
}
/* grab an exclusive lock */
- fd = robust_open(zLockFile,O_RDONLY|O_CREAT|O_EXCL,0600);
- if( fd<0 ){
- /* failed to open/create the file, someone else may have stolen the lock */
+ rc = osMkdir(zLockFile, 0777);
+ if( rc<0 ){
+ /* failed to open/create the lock directory */
int tErrno = errno;
if( EEXIST == tErrno ){
rc = SQLITE_BUSY;
@@ -26463,7 +24960,6 @@ static int dotlockLock(sqlite3_file *id, int eFileLock) {
}
return rc;
}
- robust_close(pFile, fd, __LINE__);
/* got it, set the type and return ok */
pFile->eFileLock = eFileLock;
@@ -26482,10 +24978,11 @@ static int dotlockLock(sqlite3_file *id, int eFileLock) {
static int dotlockUnlock(sqlite3_file *id, int eFileLock) {
unixFile *pFile = (unixFile*)id;
char *zLockFile = (char *)pFile->lockingContext;
+ int rc;
assert( pFile );
OSTRACE(("UNLOCK %d %d was %d pid=%d (dotlock)\n", pFile->h, eFileLock,
- pFile->eFileLock, getpid()));
+ pFile->eFileLock, getpid()));
assert( eFileLock<=SHARED_LOCK );
/* no-op if possible */
@@ -26503,9 +25000,11 @@ static int dotlockUnlock(sqlite3_file *id, int eFileLock) {
/* To fully unlock the database, delete the lock file */
assert( eFileLock==NO_LOCK );
- if( unlink(zLockFile) ){
- int rc = 0;
+ rc = osRmdir(zLockFile);
+ if( rc<0 && errno==ENOTDIR ) rc = osUnlink(zLockFile);
+ if( rc<0 ){
int tErrno = errno;
+ rc = 0;
if( ENOENT != tErrno ){
rc = SQLITE_IOERR_UNLOCK;
}
@@ -26522,13 +25021,13 @@ static int dotlockUnlock(sqlite3_file *id, int eFileLock) {
** Close a file. Make sure the lock has been released before closing.
*/
static int dotlockClose(sqlite3_file *id) {
- int rc;
+ int rc = SQLITE_OK;
if( id ){
unixFile *pFile = (unixFile*)id;
dotlockUnlock(id, NO_LOCK);
sqlite3_free(pFile->lockingContext);
+ rc = closeUnixFile(id);
}
- rc = closeUnixFile(id);
return rc;
}
/****************** End of the dot-file lock implementation *******************
@@ -26732,10 +25231,12 @@ static int flockUnlock(sqlite3_file *id, int eFileLock) {
** Close a file.
*/
static int flockClose(sqlite3_file *id) {
+ int rc = SQLITE_OK;
if( id ){
flockUnlock(id, NO_LOCK);
+ rc = closeUnixFile(id);
}
- return closeUnixFile(id);
+ return rc;
}
#endif /* SQLITE_ENABLE_LOCKING_STYLE && !OS_VXWORK */
@@ -26870,7 +25371,7 @@ static int semUnlock(sqlite3_file *id, int eFileLock) {
assert( pFile );
assert( pSem );
OSTRACE(("UNLOCK %d %d was %d pid=%d (sem)\n", pFile->h, eFileLock,
- pFile->eFileLock, getpid()));
+ pFile->eFileLock, getpid()));
assert( eFileLock<=SHARED_LOCK );
/* no-op if possible */
@@ -27009,11 +25510,12 @@ static int afpCheckReservedLock(sqlite3_file *id, int *pResOut){
int rc = SQLITE_OK;
int reserved = 0;
unixFile *pFile = (unixFile*)id;
+ afpLockingContext *context;
SimulateIOError( return SQLITE_IOERR_CHECKRESERVEDLOCK; );
assert( pFile );
- afpLockingContext *context = (afpLockingContext *) pFile->lockingContext;
+ context = (afpLockingContext *) pFile->lockingContext;
if( context->reserved ){
*pResOut = 1;
return SQLITE_OK;
@@ -27153,7 +25655,7 @@ static int afpLock(sqlite3_file *id, int eFileLock){
** operating system calls for the specified lock.
*/
if( eFileLock==SHARED_LOCK ){
- int lrc1, lrc2, lrc1Errno;
+ int lrc1, lrc2, lrc1Errno = 0;
long lk, mask;
assert( pInode->nShared==0 );
@@ -27284,7 +25786,7 @@ static int afpUnlock(sqlite3_file *id, int eFileLock) {
SimulateIOError( h=(-1) )
SimulateIOErrorBenign(0);
-#ifndef NDEBUG
+#ifdef SQLITE_DEBUG
/* When reducing a lock such that other processes can start
** reading the database file again, make sure that the
** transaction counter was updated if any part of the database
@@ -27440,35 +25942,50 @@ static int nfsUnlock(sqlite3_file *id, int eFileLock){
*/
static int seekAndRead(unixFile *id, sqlite3_int64 offset, void *pBuf, int cnt){
int got;
+ int prior = 0;
#if (!defined(USE_PREAD) && !defined(USE_PREAD64))
i64 newOffset;
#endif
TIMER_START;
+ assert( cnt==(cnt&0x1ffff) );
+ cnt &= 0x1ffff;
+ do{
#if defined(USE_PREAD)
- do{ got = osPread(id->h, pBuf, cnt, offset); }while( got<0 && errno==EINTR );
- SimulateIOError( got = -1 );
+ got = osPread(id->h, pBuf, cnt, offset);
+ SimulateIOError( got = -1 );
#elif defined(USE_PREAD64)
- do{ got = osPread64(id->h, pBuf, cnt, offset); }while( got<0 && errno==EINTR);
- SimulateIOError( got = -1 );
+ got = osPread64(id->h, pBuf, cnt, offset);
+ SimulateIOError( got = -1 );
#else
- newOffset = lseek(id->h, offset, SEEK_SET);
- SimulateIOError( newOffset-- );
- if( newOffset!=offset ){
- if( newOffset == -1 ){
- ((unixFile*)id)->lastErrno = errno;
- }else{
- ((unixFile*)id)->lastErrno = 0;
+ newOffset = lseek(id->h, offset, SEEK_SET);
+ SimulateIOError( newOffset-- );
+ if( newOffset!=offset ){
+ if( newOffset == -1 ){
+ ((unixFile*)id)->lastErrno = errno;
+ }else{
+ ((unixFile*)id)->lastErrno = 0;
+ }
+ return -1;
}
- return -1;
- }
- do{ got = osRead(id->h, pBuf, cnt); }while( got<0 && errno==EINTR );
+ got = osRead(id->h, pBuf, cnt);
#endif
+ if( got==cnt ) break;
+ if( got<0 ){
+ if( errno==EINTR ){ got = 1; continue; }
+ prior = 0;
+ ((unixFile*)id)->lastErrno = errno;
+ break;
+ }else if( got>0 ){
+ cnt -= got;
+ offset += got;
+ prior += got;
+ pBuf = (void*)(got + (char*)pBuf);
+ }
+ }while( got>0 );
TIMER_END;
- if( got<0 ){
- ((unixFile*)id)->lastErrno = errno;
- }
- OSTRACE(("READ %-3d %5d %7lld %llu\n", id->h, got, offset, TIMER_ELAPSED));
- return got;
+ OSTRACE(("READ %-3d %5d %7lld %llu\n",
+ id->h, got+prior, offset-prior, TIMER_ELAPSED));
+ return got+prior;
}
/*
@@ -27521,27 +26038,27 @@ static int seekAndWrite(unixFile *id, i64 offset, const void *pBuf, int cnt){
#if (!defined(USE_PREAD) && !defined(USE_PREAD64))
i64 newOffset;
#endif
+ assert( cnt==(cnt&0x1ffff) );
+ cnt &= 0x1ffff;
TIMER_START;
#if defined(USE_PREAD)
do{ got = osPwrite(id->h, pBuf, cnt, offset); }while( got<0 && errno==EINTR );
#elif defined(USE_PREAD64)
do{ got = osPwrite64(id->h, pBuf, cnt, offset);}while( got<0 && errno==EINTR);
#else
- newOffset = lseek(id->h, offset, SEEK_SET);
- SimulateIOError( newOffset-- );
- if( newOffset!=offset ){
- if( newOffset == -1 ){
- ((unixFile*)id)->lastErrno = errno;
- }else{
- ((unixFile*)id)->lastErrno = 0;
+ do{
+ newOffset = lseek(id->h, offset, SEEK_SET);
+ SimulateIOError( newOffset-- );
+ if( newOffset!=offset ){
+ if( newOffset == -1 ){
+ ((unixFile*)id)->lastErrno = errno;
+ }else{
+ ((unixFile*)id)->lastErrno = 0;
+ }
+ return -1;
}
- return -1;
- }
-#ifndef VXWORKS
- do{ got = osWrite(id->h, pBuf, cnt); }while( got<0 && errno==EINTR );
-#else
- do{ got = osWrite(id->h, (char *)pBuf, cnt); }while( got<0 && errno==EINTR );
-#endif
+ got = osWrite(id->h, pBuf, cnt);
+ }while( got<0 && errno==EINTR );
#endif
TIMER_END;
if( got<0 ){
@@ -27577,7 +26094,7 @@ static int unixWrite(
);
#endif
-#ifndef NDEBUG
+#ifdef SQLITE_DEBUG
/* If we are doing a normal write to a database file (as opposed to
** doing a hot-journal rollback or a write to some file other than a
** normal database file) then record the fact that the database
@@ -27631,8 +26148,8 @@ SQLITE_API int sqlite3_fullsync_count = 0;
/*
** We do not trust systems to provide a working fdatasync(). Some do.
-** Others do no. To be safe, we will stick with the (slower) fsync().
-** If you know that your system does support fdatasync() correctly,
+** Others do no. To be safe, we will stick with the (slightly slower)
+** fsync(). If you know that your system does support fdatasync() correctly,
** then simply compile with -Dfdatasync=fdatasync
*/
#if !defined(fdatasync)
@@ -27744,6 +26261,47 @@ static int full_fsync(int fd, int fullSync, int dataOnly){
}
/*
+** Open a file descriptor to the directory containing file zFilename.
+** If successful, *pFd is set to the opened file descriptor and
+** SQLITE_OK is returned. If an error occurs, either SQLITE_NOMEM
+** or SQLITE_CANTOPEN is returned and *pFd is set to an undefined
+** value.
+**
+** The directory file descriptor is used for only one thing - to
+** fsync() a directory to make sure file creation and deletion events
+** are flushed to disk. Such fsyncs are not needed on newer
+** journaling filesystems, but are required on older filesystems.
+**
+** This routine can be overridden using the xSetSysCall interface.
+** The ability to override this routine was added in support of the
+** chromium sandbox. Opening a directory is a security risk (we are
+** told) so making it overrideable allows the chromium sandbox to
+** replace this routine with a harmless no-op. To make this routine
+** a no-op, replace it with a stub that returns SQLITE_OK but leaves
+** *pFd set to a negative number.
+**
+** If SQLITE_OK is returned, the caller is responsible for closing
+** the file descriptor *pFd using close().
+*/
+static int openDirectory(const char *zFilename, int *pFd){
+ int ii;
+ int fd = -1;
+ char zDirname[MAX_PATHNAME+1];
+
+ sqlite3_snprintf(MAX_PATHNAME, zDirname, "%s", zFilename);
+ for(ii=(int)strlen(zDirname); ii>1 && zDirname[ii]!='/'; ii--);
+ if( ii>0 ){
+ zDirname[ii] = '\0';
+ fd = robust_open(zDirname, O_RDONLY|O_BINARY, 0);
+ if( fd>=0 ){
+ OSTRACE(("OPENDIR %-3d %s\n", fd, zDirname));
+ }
+ }
+ *pFd = fd;
+ return (fd>=0?SQLITE_OK:unixLogError(SQLITE_CANTOPEN_BKPT, "open", zDirname));
+}
+
+/*
** Make sure all writes to a particular file are committed to disk.
**
** If dataOnly==0 then both the file itself and its metadata (file
@@ -27783,28 +26341,23 @@ static int unixSync(sqlite3_file *id, int flags){
pFile->lastErrno = errno;
return unixLogError(SQLITE_IOERR_FSYNC, "full_fsync", pFile->zPath);
}
- if( pFile->dirfd>=0 ){
- OSTRACE(("DIRSYNC %-3d (have_fullfsync=%d fullsync=%d)\n", pFile->dirfd,
+
+ /* Also fsync the directory containing the file if the DIRSYNC flag
+ ** is set. This is a one-time occurrence. Many systems (examples: AIX)
+ ** are unable to fsync a directory, so ignore errors on the fsync.
+ */
+ if( pFile->ctrlFlags & UNIXFILE_DIRSYNC ){
+ int dirfd;
+ OSTRACE(("DIRSYNC %s (have_fullfsync=%d fullsync=%d)\n", pFile->zPath,
HAVE_FULLFSYNC, isFullsync));
-#ifndef SQLITE_DISABLE_DIRSYNC
- /* The directory sync is only attempted if full_fsync is
- ** turned off or unavailable. If a full_fsync occurred above,
- ** then the directory sync is superfluous.
- */
- if( (!HAVE_FULLFSYNC || !isFullsync) && full_fsync(pFile->dirfd,0,0) ){
- /*
- ** We have received multiple reports of fsync() returning
- ** errors when applied to directories on certain file systems.
- ** A failed directory sync is not a big deal. So it seems
- ** better to ignore the error. Ticket #1657
- */
- /* pFile->lastErrno = errno; */
- /* return SQLITE_IOERR; */
+ rc = osOpenDirectory(pFile->zPath, &dirfd);
+ if( rc==SQLITE_OK && dirfd>=0 ){
+ full_fsync(dirfd, 0, 0);
+ robust_close(pFile, dirfd, __LINE__);
+ }else if( rc==SQLITE_CANTOPEN ){
+ rc = SQLITE_OK;
}
-#endif
- /* Only need to sync once, so close the directory when we are done */
- robust_close(pFile, pFile->dirfd, __LINE__);
- pFile->dirfd = -1;
+ pFile->ctrlFlags &= ~UNIXFILE_DIRSYNC;
}
return rc;
}
@@ -27823,7 +26376,7 @@ static int unixTruncate(sqlite3_file *id, i64 nByte){
** actual file size after the operation may be larger than the requested
** size).
*/
- if( pFile->szChunk ){
+ if( pFile->szChunk>0 ){
nByte = ((nByte + pFile->szChunk - 1)/pFile->szChunk) * pFile->szChunk;
}
@@ -27832,7 +26385,7 @@ static int unixTruncate(sqlite3_file *id, i64 nByte){
pFile->lastErrno = errno;
return unixLogError(SQLITE_IOERR_TRUNCATE, "ftruncate", pFile->zPath);
}else{
-#ifndef NDEBUG
+#ifdef SQLITE_DEBUG
/* If we are doing a normal write to a database file (as opposed to
** doing a hot-journal rollback or a write to some file other than a
** normal database file) and we truncate the file to zero length,
@@ -27886,14 +26439,12 @@ static int proxyFileControl(sqlite3_file*,int,void*);
/*
** This function is called to handle the SQLITE_FCNTL_SIZE_HINT
-** file-control operation.
-**
-** If the user has configured a chunk-size for this file, it could be
-** that the file needs to be extended at this point. Otherwise, the
-** SQLITE_FCNTL_SIZE_HINT operation is a no-op for Unix.
+** file-control operation. Enlarge the database to nBytes in size
+** (rounded up to the next chunk-size). If the database is already
+** nBytes or larger, this routine is a no-op.
*/
static int fcntlSizeHint(unixFile *pFile, i64 nByte){
- if( pFile->szChunk ){
+ if( pFile->szChunk>0 ){
i64 nSize; /* Required file size */
struct stat buf; /* Used to hold return values of fstat() */
@@ -27939,26 +26490,70 @@ static int fcntlSizeHint(unixFile *pFile, i64 nByte){
}
/*
+** If *pArg is inititially negative then this is a query. Set *pArg to
+** 1 or 0 depending on whether or not bit mask of pFile->ctrlFlags is set.
+**
+** If *pArg is 0 or 1, then clear or set the mask bit of pFile->ctrlFlags.
+*/
+static void unixModeBit(unixFile *pFile, unsigned char mask, int *pArg){
+ if( *pArg<0 ){
+ *pArg = (pFile->ctrlFlags & mask)!=0;
+ }else if( (*pArg)==0 ){
+ pFile->ctrlFlags &= ~mask;
+ }else{
+ pFile->ctrlFlags |= mask;
+ }
+}
+
+/* Forward declaration */
+static int unixGetTempname(int nBuf, char *zBuf);
+
+/*
** Information and control of an open file handle.
*/
static int unixFileControl(sqlite3_file *id, int op, void *pArg){
+ unixFile *pFile = (unixFile*)id;
switch( op ){
case SQLITE_FCNTL_LOCKSTATE: {
- *(int*)pArg = ((unixFile*)id)->eFileLock;
+ *(int*)pArg = pFile->eFileLock;
return SQLITE_OK;
}
case SQLITE_LAST_ERRNO: {
- *(int*)pArg = ((unixFile*)id)->lastErrno;
+ *(int*)pArg = pFile->lastErrno;
return SQLITE_OK;
}
case SQLITE_FCNTL_CHUNK_SIZE: {
- ((unixFile*)id)->szChunk = *(int *)pArg;
+ pFile->szChunk = *(int *)pArg;
return SQLITE_OK;
}
case SQLITE_FCNTL_SIZE_HINT: {
- return fcntlSizeHint((unixFile *)id, *(i64 *)pArg);
+ int rc;
+ SimulateIOErrorBenign(1);
+ rc = fcntlSizeHint(pFile, *(i64 *)pArg);
+ SimulateIOErrorBenign(0);
+ return rc;
}
-#ifndef NDEBUG
+ case SQLITE_FCNTL_PERSIST_WAL: {
+ unixModeBit(pFile, UNIXFILE_PERSIST_WAL, (int*)pArg);
+ return SQLITE_OK;
+ }
+ case SQLITE_FCNTL_POWERSAFE_OVERWRITE: {
+ unixModeBit(pFile, UNIXFILE_PSOW, (int*)pArg);
+ return SQLITE_OK;
+ }
+ case SQLITE_FCNTL_VFSNAME: {
+ *(char**)pArg = sqlite3_mprintf("%s", pFile->pVfs->zName);
+ return SQLITE_OK;
+ }
+ case SQLITE_FCNTL_TEMPFILENAME: {
+ char *zTFile = sqlite3_malloc( pFile->pVfs->mxPathname );
+ if( zTFile ){
+ unixGetTempname(pFile->pVfs->mxPathname, zTFile);
+ *(char**)pArg = zTFile;
+ }
+ return SQLITE_OK;
+ }
+#ifdef SQLITE_DEBUG
/* The pager calls this method to signal that it has done
** a rollback and that the database is therefore unchanged and
** it hence it is OK for the transaction change counter to be
@@ -27975,9 +26570,6 @@ static int unixFileControl(sqlite3_file *id, int op, void *pArg){
return proxyFileControl(id,op,pArg);
}
#endif /* SQLITE_ENABLE_LOCKING_STYLE && defined(__APPLE__) */
- case SQLITE_FCNTL_SYNC_OMITTED: {
- return SQLITE_OK; /* A no-op */
- }
}
return SQLITE_NOTFOUND;
}
@@ -27992,17 +26584,117 @@ static int unixFileControl(sqlite3_file *id, int op, void *pArg){
** a database and its journal file) that the sector size will be the
** same for both.
*/
+#ifndef __QNXNTO__
static int unixSectorSize(sqlite3_file *NotUsed){
UNUSED_PARAMETER(NotUsed);
return SQLITE_DEFAULT_SECTOR_SIZE;
}
+#endif
/*
-** Return the device characteristics for the file. This is always 0 for unix.
+** The following version of unixSectorSize() is optimized for QNX.
*/
-static int unixDeviceCharacteristics(sqlite3_file *NotUsed){
- UNUSED_PARAMETER(NotUsed);
- return 0;
+#ifdef __QNXNTO__
+#include <sys/dcmd_blk.h>
+#include <sys/statvfs.h>
+static int unixSectorSize(sqlite3_file *id){
+ unixFile *pFile = (unixFile*)id;
+ if( pFile->sectorSize == 0 ){
+ struct statvfs fsInfo;
+
+ /* Set defaults for non-supported filesystems */
+ pFile->sectorSize = SQLITE_DEFAULT_SECTOR_SIZE;
+ pFile->deviceCharacteristics = 0;
+ if( fstatvfs(pFile->h, &fsInfo) == -1 ) {
+ return pFile->sectorSize;
+ }
+
+ if( !strcmp(fsInfo.f_basetype, "tmp") ) {
+ pFile->sectorSize = fsInfo.f_bsize;
+ pFile->deviceCharacteristics =
+ SQLITE_IOCAP_ATOMIC4K | /* All ram filesystem writes are atomic */
+ SQLITE_IOCAP_SAFE_APPEND | /* growing the file does not occur until
+ ** the write succeeds */
+ SQLITE_IOCAP_SEQUENTIAL | /* The ram filesystem has no write behind
+ ** so it is ordered */
+ 0;
+ }else if( strstr(fsInfo.f_basetype, "etfs") ){
+ pFile->sectorSize = fsInfo.f_bsize;
+ pFile->deviceCharacteristics =
+ /* etfs cluster size writes are atomic */
+ (pFile->sectorSize / 512 * SQLITE_IOCAP_ATOMIC512) |
+ SQLITE_IOCAP_SAFE_APPEND | /* growing the file does not occur until
+ ** the write succeeds */
+ SQLITE_IOCAP_SEQUENTIAL | /* The ram filesystem has no write behind
+ ** so it is ordered */
+ 0;
+ }else if( !strcmp(fsInfo.f_basetype, "qnx6") ){
+ pFile->sectorSize = fsInfo.f_bsize;
+ pFile->deviceCharacteristics =
+ SQLITE_IOCAP_ATOMIC | /* All filesystem writes are atomic */
+ SQLITE_IOCAP_SAFE_APPEND | /* growing the file does not occur until
+ ** the write succeeds */
+ SQLITE_IOCAP_SEQUENTIAL | /* The ram filesystem has no write behind
+ ** so it is ordered */
+ 0;
+ }else if( !strcmp(fsInfo.f_basetype, "qnx4") ){
+ pFile->sectorSize = fsInfo.f_bsize;
+ pFile->deviceCharacteristics =
+ /* full bitset of atomics from max sector size and smaller */
+ ((pFile->sectorSize / 512 * SQLITE_IOCAP_ATOMIC512) << 1) - 2 |
+ SQLITE_IOCAP_SEQUENTIAL | /* The ram filesystem has no write behind
+ ** so it is ordered */
+ 0;
+ }else if( strstr(fsInfo.f_basetype, "dos") ){
+ pFile->sectorSize = fsInfo.f_bsize;
+ pFile->deviceCharacteristics =
+ /* full bitset of atomics from max sector size and smaller */
+ ((pFile->sectorSize / 512 * SQLITE_IOCAP_ATOMIC512) << 1) - 2 |
+ SQLITE_IOCAP_SEQUENTIAL | /* The ram filesystem has no write behind
+ ** so it is ordered */
+ 0;
+ }else{
+ pFile->deviceCharacteristics =
+ SQLITE_IOCAP_ATOMIC512 | /* blocks are atomic */
+ SQLITE_IOCAP_SAFE_APPEND | /* growing the file does not occur until
+ ** the write succeeds */
+ 0;
+ }
+ }
+ /* Last chance verification. If the sector size isn't a multiple of 512
+ ** then it isn't valid.*/
+ if( pFile->sectorSize % 512 != 0 ){
+ pFile->deviceCharacteristics = 0;
+ pFile->sectorSize = SQLITE_DEFAULT_SECTOR_SIZE;
+ }
+ return pFile->sectorSize;
+}
+#endif /* __QNXNTO__ */
+
+/*
+** Return the device characteristics for the file.
+**
+** This VFS is set up to return SQLITE_IOCAP_POWERSAFE_OVERWRITE by default.
+** However, that choice is contraversial since technically the underlying
+** file system does not always provide powersafe overwrites. (In other
+** words, after a power-loss event, parts of the file that were never
+** written might end up being altered.) However, non-PSOW behavior is very,
+** very rare. And asserting PSOW makes a large reduction in the amount
+** of required I/O for journaling, since a lot of padding is eliminated.
+** Hence, while POWERSAFE_OVERWRITE is on by default, there is a file-control
+** available to turn it off and URI query parameter available to turn it off.
+*/
+static int unixDeviceCharacteristics(sqlite3_file *id){
+ unixFile *p = (unixFile*)id;
+ int rc = 0;
+#ifdef __QNXNTO__
+ if( p->sectorSize==0 ) unixSectorSize(id);
+ rc = p->deviceCharacteristics;
+#endif
+ if( p->ctrlFlags & UNIXFILE_PSOW ){
+ rc |= SQLITE_IOCAP_POWERSAFE_OVERWRITE;
+ }
+ return rc;
}
#ifndef SQLITE_OMIT_WAL
@@ -28072,11 +26764,9 @@ struct unixShm {
unixShmNode *pShmNode; /* The underlying unixShmNode object */
unixShm *pNext; /* Next unixShm with the same unixShmNode */
u8 hasMutex; /* True if holding the unixShmNode mutex */
+ u8 id; /* Id of this connection within its unixShmNode */
u16 sharedMask; /* Mask of shared locks held */
u16 exclMask; /* Mask of exclusive locks held */
-#ifdef SQLITE_DEBUG
- u8 id; /* Id of this connection within its unixShmNode */
-#endif
};
/*
@@ -28172,7 +26862,7 @@ static void unixShmPurge(unixFile *pFd){
if( p && p->nRef==0 ){
int i;
assert( p->pInode==pFd->pInode );
- if( p->mutex ) sqlite3_mutex_free(p->mutex);
+ sqlite3_mutex_free(p->mutex);
for(i=0; i<p->nRegion; i++){
if( p->h>=0 ){
munmap(p->apRegion[i], p->szRegion);
@@ -28250,8 +26940,7 @@ static int unixOpenSharedMemory(unixFile *pDbFd){
/* Call fstat() to figure out the permissions on the database file. If
** a new *-shm file is created, an attempt will be made to create it
- ** with the same permissions. The actual permissions the file is created
- ** with are subject to the current umask setting.
+ ** with the same permissions.
*/
if( osFstat(pDbFd->h, &sStat) && pInode->bProcessLock==0 ){
rc = SQLITE_IOERR_FSTAT;
@@ -28259,16 +26948,16 @@ static int unixOpenSharedMemory(unixFile *pDbFd){
}
#ifdef SQLITE_SHM_DIRECTORY
- nShmFilename = sizeof(SQLITE_SHM_DIRECTORY) + 30;
+ nShmFilename = sizeof(SQLITE_SHM_DIRECTORY) + 31;
#else
- nShmFilename = 5 + (int)strlen(pDbFd->zPath);
+ nShmFilename = 6 + (int)strlen(pDbFd->zPath);
#endif
pShmNode = sqlite3_malloc( sizeof(*pShmNode) + nShmFilename );
if( pShmNode==0 ){
rc = SQLITE_NOMEM;
goto shm_open_err;
}
- memset(pShmNode, 0, sizeof(*pShmNode));
+ memset(pShmNode, 0, sizeof(*pShmNode)+nShmFilename);
zShmFilename = pShmNode->zFilename = (char*)&pShmNode[1];
#ifdef SQLITE_SHM_DIRECTORY
sqlite3_snprintf(nShmFilename, zShmFilename,
@@ -28288,21 +26977,22 @@ static int unixOpenSharedMemory(unixFile *pDbFd){
}
if( pInode->bProcessLock==0 ){
- pShmNode->h = robust_open(zShmFilename, O_RDWR|O_CREAT,
- (sStat.st_mode & 0777));
+ int openFlags = O_RDWR | O_CREAT;
+ if( sqlite3_uri_boolean(pDbFd->zPath, "readonly_shm", 0) ){
+ openFlags = O_RDONLY;
+ pShmNode->isReadonly = 1;
+ }
+ pShmNode->h = robust_open(zShmFilename, openFlags, (sStat.st_mode&0777));
if( pShmNode->h<0 ){
- const char *zRO;
- zRO = sqlite3_uri_parameter(pDbFd->zPath, "readonly_shm");
- if( zRO && sqlite3GetBoolean(zRO) ){
- pShmNode->h = robust_open(zShmFilename, O_RDONLY,
- (sStat.st_mode & 0777));
- pShmNode->isReadonly = 1;
- }
- if( pShmNode->h<0 ){
- rc = unixLogError(SQLITE_CANTOPEN_BKPT, "open", zShmFilename);
- goto shm_open_err;
- }
+ rc = unixLogError(SQLITE_CANTOPEN_BKPT, "open", zShmFilename);
+ goto shm_open_err;
}
+
+ /* If this process is running as root, make sure that the SHM file
+ ** is owned by the same user that owns the original database. Otherwise,
+ ** the original owner will not be able to connect.
+ */
+ osFchown(pShmNode->h, sStat.st_uid, sStat.st_gid);
/* Check to see if another process is holding the dead-man switch.
** If not, truncate the file to zero length.
@@ -28420,11 +27110,19 @@ static int unixShmMap(
** the requested memory region.
*/
if( !bExtend ) goto shmpage_out;
+#if defined(HAVE_POSIX_FALLOCATE) && HAVE_POSIX_FALLOCATE
+ if( osFallocate(pShmNode->h, sStat.st_size, nByte)!=0 ){
+ rc = unixLogError(SQLITE_IOERR_SHMSIZE, "fallocate",
+ pShmNode->zFilename);
+ goto shmpage_out;
+ }
+#else
if( robust_ftruncate(pShmNode->h, nByte) ){
rc = unixLogError(SQLITE_IOERR_SHMSIZE, "ftruncate",
pShmNode->zFilename);
goto shmpage_out;
}
+#endif
}
}
@@ -28442,7 +27140,7 @@ static int unixShmMap(
if( pShmNode->h>=0 ){
pMem = mmap(0, szRegion,
pShmNode->isReadonly ? PROT_READ : PROT_READ|PROT_WRITE,
- MAP_SHARED, pShmNode->h, pShmNode->nRegion*szRegion
+ MAP_SHARED, pShmNode->h, szRegion*(i64)pShmNode->nRegion
);
if( pMem==MAP_FAILED ){
rc = unixLogError(SQLITE_IOERR_SHMMAP, "mmap", pShmNode->zFilename);
@@ -28641,7 +27339,7 @@ static int unixShmUnmap(
assert( pShmNode->nRef>0 );
pShmNode->nRef--;
if( pShmNode->nRef==0 ){
- if( deleteFlag && pShmNode->h>=0 ) unlink(pShmNode->zFilename);
+ if( deleteFlag && pShmNode->h>=0 ) osUnlink(pShmNode->zFilename);
unixShmPurge(pDbFd);
}
unixLeaveMutex();
@@ -28954,12 +27652,9 @@ typedef const sqlite3_io_methods *(*finder_type)(const char*,unixFile*);
static int fillInUnixFile(
sqlite3_vfs *pVfs, /* Pointer to vfs object */
int h, /* Open file descriptor of file being opened */
- int dirfd, /* Directory file descriptor */
sqlite3_file *pId, /* Write to the unixFile structure here */
const char *zFilename, /* Name of the file being opened */
- int noLock, /* Omit locking if true */
- int isDelete, /* Delete on close if true */
- int isReadOnly /* True if the file is opened read-only */
+ int ctrlFlags /* Zero or more UNIXFILE_* values */
){
const sqlite3_io_methods *pLockingStyle;
unixFile *pNew = (unixFile *)pId;
@@ -28967,11 +27662,6 @@ static int fillInUnixFile(
assert( pNew->pInode==NULL );
- /* Parameter isDelete is only used on vxworks. Express this explicitly
- ** here to prevent compiler warnings about unused parameters.
- */
- UNUSED_PARAMETER(isDelete);
-
/* Usually the path zFilename should not be a relative pathname. The
** exception is when opening the proxy "conch" file in builds that
** include the special Apple locking styles.
@@ -28983,28 +27673,31 @@ static int fillInUnixFile(
assert( zFilename==0 || zFilename[0]=='/' );
#endif
+ /* No locking occurs in temporary files */
+ assert( zFilename!=0 || (ctrlFlags & UNIXFILE_NOLOCK)!=0 );
+
OSTRACE(("OPEN %-3d %s\n", h, zFilename));
pNew->h = h;
- pNew->dirfd = dirfd;
+ pNew->pVfs = pVfs;
pNew->zPath = zFilename;
- if( memcmp(pVfs->zName,"unix-excl",10)==0 ){
- pNew->ctrlFlags = UNIXFILE_EXCL;
- }else{
- pNew->ctrlFlags = 0;
+ pNew->ctrlFlags = (u8)ctrlFlags;
+ if( sqlite3_uri_boolean(((ctrlFlags & UNIXFILE_URI) ? zFilename : 0),
+ "psow", SQLITE_POWERSAFE_OVERWRITE) ){
+ pNew->ctrlFlags |= UNIXFILE_PSOW;
}
- if( isReadOnly ){
- pNew->ctrlFlags |= UNIXFILE_RDONLY;
+ if( strcmp(pVfs->zName,"unix-excl")==0 ){
+ pNew->ctrlFlags |= UNIXFILE_EXCL;
}
#if OS_VXWORKS
pNew->pId = vxworksFindFileId(zFilename);
if( pNew->pId==0 ){
- noLock = 1;
+ ctrlFlags |= UNIXFILE_NOLOCK;
rc = SQLITE_NOMEM;
}
#endif
- if( noLock ){
+ if( ctrlFlags & UNIXFILE_NOLOCK ){
pLockingStyle = &nolockIoMethods;
}else{
pLockingStyle = (**(finder_type*)pVfs->pAppData)(zFilename, pNew);
@@ -29024,7 +27717,7 @@ static int fillInUnixFile(
unixEnterMutex();
rc = findInodeInfo(pNew, &pNew->pInode);
if( rc!=SQLITE_OK ){
- /* If an error occured in findInodeInfo(), close the file descriptor
+ /* If an error occurred in findInodeInfo(), close the file descriptor
** immediately, before releasing the mutex. findInodeInfo() may fail
** in two scenarios:
**
@@ -29082,6 +27775,7 @@ static int fillInUnixFile(
*/
char *zLockFile;
int nFilename;
+ assert( zFilename!=0 );
nFilename = (int)strlen(zFilename) + 6;
zLockFile = (char *)sqlite3_malloc(nFilename);
if( zLockFile==0 ){
@@ -29121,13 +27815,12 @@ static int fillInUnixFile(
if( rc!=SQLITE_OK ){
if( h>=0 ) robust_close(pNew, h, __LINE__);
h = -1;
- unlink(zFilename);
+ osUnlink(zFilename);
isDelete = 0;
}
- pNew->isDelete = isDelete;
+ if( isDelete ) pNew->ctrlFlags |= UNIXFILE_DELETE;
#endif
if( rc!=SQLITE_OK ){
- if( dirfd>=0 ) robust_close(pNew, dirfd, __LINE__);
if( h>=0 ) robust_close(pNew, h, __LINE__);
}else{
pNew->pMethod = pLockingStyle;
@@ -29137,37 +27830,6 @@ static int fillInUnixFile(
}
/*
-** Open a file descriptor to the directory containing file zFilename.
-** If successful, *pFd is set to the opened file descriptor and
-** SQLITE_OK is returned. If an error occurs, either SQLITE_NOMEM
-** or SQLITE_CANTOPEN is returned and *pFd is set to an undefined
-** value.
-**
-** If SQLITE_OK is returned, the caller is responsible for closing
-** the file descriptor *pFd using close().
-*/
-static int openDirectory(const char *zFilename, int *pFd){
- int ii;
- int fd = -1;
- char zDirname[MAX_PATHNAME+1];
-
- sqlite3_snprintf(MAX_PATHNAME, zDirname, "%s", zFilename);
- for(ii=(int)strlen(zDirname); ii>1 && zDirname[ii]!='/'; ii--);
- if( ii>0 ){
- zDirname[ii] = '\0';
- fd = robust_open(zDirname, O_RDONLY|O_BINARY, 0);
- if( fd>=0 ){
-#ifdef FD_CLOEXEC
- osFcntl(fd, F_SETFD, osFcntl(fd, F_GETFD, 0) | FD_CLOEXEC);
-#endif
- OSTRACE(("OPENDIR %-3d %s\n", fd, zDirname));
- }
- }
- *pFd = fd;
- return (fd>=0?SQLITE_OK:unixLogError(SQLITE_CANTOPEN_BKPT, "open", zDirname));
-}
-
-/*
** Return the name of a directory in which to put temporary files.
** If no suitable temporary file directory can be found, return NULL.
*/
@@ -29221,18 +27883,19 @@ static int unixGetTempname(int nBuf, char *zBuf){
/* Check that the output buffer is large enough for the temporary file
** name. If it is not, return SQLITE_ERROR.
*/
- if( (strlen(zDir) + strlen(SQLITE_TEMP_FILE_PREFIX) + 17) >= (size_t)nBuf ){
+ if( (strlen(zDir) + strlen(SQLITE_TEMP_FILE_PREFIX) + 18) >= (size_t)nBuf ){
return SQLITE_ERROR;
}
do{
- sqlite3_snprintf(nBuf-17, zBuf, "%s/"SQLITE_TEMP_FILE_PREFIX, zDir);
+ sqlite3_snprintf(nBuf-18, zBuf, "%s/"SQLITE_TEMP_FILE_PREFIX, zDir);
j = (int)strlen(zBuf);
sqlite3_randomness(15, &zBuf[j]);
for(i=0; i<15; i++, j++){
zBuf[j] = (char)zChars[ ((unsigned char)zBuf[j])%(sizeof(zChars)-1) ];
}
zBuf[j] = 0;
+ zBuf[j+1] = 0;
}while( osAccess(zBuf,0)==0 );
return SQLITE_OK;
}
@@ -29281,7 +27944,7 @@ static UnixUnusedFd *findReusableFd(const char *zPath, int flags){
**
** Even if a subsequent open() call does succeed, the consequences of
** not searching for a resusable file descriptor are not dire. */
- if( 0==stat(zPath, &sStat) ){
+ if( 0==osStat(zPath, &sStat) ){
unixInodeInfo *pInode;
unixEnterMutex();
@@ -29311,12 +27974,10 @@ static UnixUnusedFd *findReusableFd(const char *zPath, int flags){
** written to *pMode. If an IO error occurs, an SQLite error code is
** returned and the value of *pMode is not modified.
**
-** If the file being opened is a temporary file, it is always created with
-** the octal permissions 0600 (read/writable by owner only). If the file
-** is a database or master journal file, it is created with the permissions
-** mask SQLITE_DEFAULT_FILE_PERMISSIONS.
-**
-** Finally, if the file being opened is a WAL or regular journal file, then
+** In most cases cases, this routine sets *pMode to 0, which will become
+** an indication to robust_open() to create the file using
+** SQLITE_DEFAULT_FILE_PERMISSIONS adjusted by the umask.
+** But if the file being opened is a WAL or regular journal file, then
** this function queries the file-system for the permissions on the
** corresponding database file and sets *pMode to this value. Whenever
** possible, WAL and journal files are created using the same permissions
@@ -29330,10 +27991,14 @@ static UnixUnusedFd *findReusableFd(const char *zPath, int flags){
static int findCreateFileMode(
const char *zPath, /* Path of file (possibly) being created */
int flags, /* Flags passed as 4th argument to xOpen() */
- mode_t *pMode /* OUT: Permissions to open file with */
+ mode_t *pMode, /* OUT: Permissions to open file with */
+ uid_t *pUid, /* OUT: uid to set on the file */
+ gid_t *pGid /* OUT: gid to set on the file */
){
int rc = SQLITE_OK; /* Return Code */
- *pMode = SQLITE_DEFAULT_FILE_PERMISSIONS;
+ *pMode = 0;
+ *pUid = 0;
+ *pGid = 0;
if( flags & (SQLITE_OPEN_WAL|SQLITE_OPEN_MAIN_JOURNAL) ){
char zDb[MAX_PATHNAME+1]; /* Database file path */
int nDb; /* Number of valid bytes in zDb */
@@ -29348,17 +28013,27 @@ static int findCreateFileMode(
** "<path to db>-journalNN"
** "<path to db>-walNN"
**
- ** where NN is a 4 digit decimal number. The NN naming schemes are
+ ** where NN is a decimal number. The NN naming schemes are
** used by the test_multiplex.c module.
*/
nDb = sqlite3Strlen30(zPath) - 1;
- while( nDb>0 && zPath[nDb]!='-' ) nDb--;
- if( nDb==0 ) return SQLITE_OK;
+#ifdef SQLITE_ENABLE_8_3_NAMES
+ while( nDb>0 && sqlite3Isalnum(zPath[nDb]) ) nDb--;
+ if( nDb==0 || zPath[nDb]!='-' ) return SQLITE_OK;
+#else
+ while( zPath[nDb]!='-' ){
+ assert( nDb>0 );
+ assert( zPath[nDb]!='\n' );
+ nDb--;
+ }
+#endif
memcpy(zDb, zPath, nDb);
zDb[nDb] = '\0';
- if( 0==stat(zDb, &sStat) ){
+ if( 0==osStat(zDb, &sStat) ){
*pMode = sStat.st_mode & 0777;
+ *pUid = sStat.st_uid;
+ *pGid = sStat.st_gid;
}else{
rc = SQLITE_IOERR_FSTAT;
}
@@ -29399,11 +28074,11 @@ static int unixOpen(
){
unixFile *p = (unixFile *)pFile;
int fd = -1; /* File descriptor returned by open() */
- int dirfd = -1; /* Directory file descriptor */
int openFlags = 0; /* Flags to pass to open() */
int eType = flags&0xFFFFFF00; /* Type of file to open */
int noLock; /* True to omit locking primitives */
int rc = SQLITE_OK; /* Function Return Code */
+ int ctrlFlags = 0; /* UNIXFILE_* flags */
int isExclusive = (flags & SQLITE_OPEN_EXCLUSIVE);
int isDelete = (flags & SQLITE_OPEN_DELETEONCLOSE);
@@ -29413,12 +28088,15 @@ static int unixOpen(
#if SQLITE_ENABLE_LOCKING_STYLE
int isAutoProxy = (flags & SQLITE_OPEN_AUTOPROXY);
#endif
+#if defined(__APPLE__) || SQLITE_ENABLE_LOCKING_STYLE
+ struct statfs fsInfo;
+#endif
/* If creating a master or main-file journal, this function will open
** a file-descriptor on the directory too. The first time unixSync()
** is called the directory file descriptor will be fsync()ed and close()d.
*/
- int isOpenDirectory = (isCreate && (
+ int syncDir = (isCreate && (
eType==SQLITE_OPEN_MASTER_JOURNAL
|| eType==SQLITE_OPEN_MAIN_JOURNAL
|| eType==SQLITE_OPEN_WAL
@@ -29427,7 +28105,7 @@ static int unixOpen(
/* If argument zPath is a NULL pointer, this function is required to open
** a temporary file. Use this buffer to store the file name in.
*/
- char zTmpname[MAX_PATHNAME+1];
+ char zTmpname[MAX_PATHNAME+2];
const char *zName = zPath;
/* Check the following statements are true:
@@ -29470,14 +28148,24 @@ static int unixOpen(
}
}
p->pUnused = pUnused;
+
+ /* Database filenames are double-zero terminated if they are not
+ ** URIs with parameters. Hence, they can always be passed into
+ ** sqlite3_uri_parameter(). */
+ assert( (flags & SQLITE_OPEN_URI) || zName[strlen(zName)+1]==0 );
+
}else if( !zName ){
/* If zName is NULL, the upper layer is requesting a temp file. */
- assert(isDelete && !isOpenDirectory);
- rc = unixGetTempname(MAX_PATHNAME+1, zTmpname);
+ assert(isDelete && !syncDir);
+ rc = unixGetTempname(MAX_PATHNAME+2, zTmpname);
if( rc!=SQLITE_OK ){
return rc;
}
zName = zTmpname;
+
+ /* Generated temporary filenames are always double-zero terminated
+ ** for use by sqlite3_uri_parameter(). */
+ assert( zName[strlen(zName)+1]==0 );
}
/* Determine the value of the flags parameter passed to POSIX function
@@ -29492,7 +28180,9 @@ static int unixOpen(
if( fd<0 ){
mode_t openMode; /* Permissions to create file with */
- rc = findCreateFileMode(zName, flags, &openMode);
+ uid_t uid; /* Userid for the file */
+ gid_t gid; /* Groupid for the file */
+ rc = findCreateFileMode(zName, flags, &openMode, &uid, &gid);
if( rc!=SQLITE_OK ){
assert( !p->pUnused );
assert( eType==SQLITE_OPEN_WAL || eType==SQLITE_OPEN_MAIN_JOURNAL );
@@ -29513,6 +28203,14 @@ static int unixOpen(
rc = unixLogError(SQLITE_CANTOPEN_BKPT, "open", zName);
goto open_finished;
}
+
+ /* If this process is running as root and if creating a new rollback
+ ** journal or WAL file, set the ownership of the journal or WAL to be
+ ** the same as the original database.
+ */
+ if( flags & (SQLITE_OPEN_WAL|SQLITE_OPEN_MAIN_JOURNAL) ){
+ osFchown(fd, uid, gid);
+ }
}
assert( fd>=0 );
if( pOutFlags ){
@@ -29528,7 +28226,7 @@ static int unixOpen(
#if OS_VXWORKS
zPath = zName;
#else
- unlink(zName);
+ osUnlink(zName);
#endif
}
#if SQLITE_ENABLE_LOCKING_STYLE
@@ -29537,31 +28235,12 @@ static int unixOpen(
}
#endif
- if( isOpenDirectory ){
- rc = openDirectory(zPath, &dirfd);
- if( rc!=SQLITE_OK ){
- /* It is safe to close fd at this point, because it is guaranteed not
- ** to be open on a database file. If it were open on a database file,
- ** it would not be safe to close as this would release any locks held
- ** on the file by this process. */
- assert( eType!=SQLITE_OPEN_MAIN_DB );
- robust_close(p, fd, __LINE__);
- goto open_finished;
- }
- }
-
-#ifdef FD_CLOEXEC
- osFcntl(fd, F_SETFD, osFcntl(fd, F_GETFD, 0) | FD_CLOEXEC);
-#endif
-
noLock = eType!=SQLITE_OPEN_MAIN_DB;
#if defined(__APPLE__) || SQLITE_ENABLE_LOCKING_STYLE
- struct statfs fsInfo;
if( fstatfs(fd, &fsInfo) == -1 ){
((unixFile*)pFile)->lastErrno = errno;
- if( dirfd>=0 ) robust_close(p, dirfd, __LINE__);
robust_close(p, fd, __LINE__);
return SQLITE_IOERR_ACCESS;
}
@@ -29569,7 +28248,14 @@ static int unixOpen(
((unixFile*)pFile)->fsFlags |= SQLITE_FSFLAGS_IS_MSDOS;
}
#endif
-
+
+ /* Set up appropriate ctrlFlags */
+ if( isDelete ) ctrlFlags |= UNIXFILE_DELETE;
+ if( isReadonly ) ctrlFlags |= UNIXFILE_RDONLY;
+ if( noLock ) ctrlFlags |= UNIXFILE_NOLOCK;
+ if( syncDir ) ctrlFlags |= UNIXFILE_DIRSYNC;
+ if( flags & SQLITE_OPEN_URI ) ctrlFlags |= UNIXFILE_URI;
+
#if SQLITE_ENABLE_LOCKING_STYLE
#if SQLITE_PREFER_PROXY_LOCKING
isAutoProxy = 1;
@@ -29583,7 +28269,6 @@ static int unixOpen(
if( envforce!=NULL ){
useProxy = atoi(envforce)>0;
}else{
- struct statfs fsInfo;
if( statfs(zPath, &fsInfo) == -1 ){
/* In theory, the close(fd) call is sub-optimal. If the file opened
** with fd is a database file, and there are other connections open
@@ -29593,9 +28278,6 @@ static int unixOpen(
** not while other file descriptors opened by the same process on
** the same file are working. */
p->lastErrno = errno;
- if( dirfd>=0 ){
- robust_close(p, dirfd, __LINE__);
- }
robust_close(p, fd, __LINE__);
rc = SQLITE_IOERR_ACCESS;
goto open_finished;
@@ -29603,8 +28285,7 @@ static int unixOpen(
useProxy = !(fsInfo.f_flags&MNT_LOCAL);
}
if( useProxy ){
- rc = fillInUnixFile(pVfs, fd, dirfd, pFile, zPath, noLock,
- isDelete, isReadonly);
+ rc = fillInUnixFile(pVfs, fd, pFile, zPath, ctrlFlags);
if( rc==SQLITE_OK ){
rc = proxyTransformUnixFile((unixFile*)pFile, ":auto:");
if( rc!=SQLITE_OK ){
@@ -29621,8 +28302,8 @@ static int unixOpen(
}
#endif
- rc = fillInUnixFile(pVfs, fd, dirfd, pFile, zPath, noLock,
- isDelete, isReadonly);
+ rc = fillInUnixFile(pVfs, fd, pFile, zPath, ctrlFlags);
+
open_finished:
if( rc!=SQLITE_OK ){
sqlite3_free(p->pUnused);
@@ -29643,13 +28324,18 @@ static int unixDelete(
int rc = SQLITE_OK;
UNUSED_PARAMETER(NotUsed);
SimulateIOError(return SQLITE_IOERR_DELETE);
- if( unlink(zPath)==(-1) && errno!=ENOENT ){
- return unixLogError(SQLITE_IOERR_DELETE, "unlink", zPath);
+ if( osUnlink(zPath)==(-1) ){
+ if( errno==ENOENT ){
+ rc = SQLITE_IOERR_DELETE_NOENT;
+ }else{
+ rc = unixLogError(SQLITE_IOERR_DELETE, "unlink", zPath);
+ }
+ return rc;
}
#ifndef SQLITE_DISABLE_DIRSYNC
- if( dirSync ){
+ if( (dirSync & 1)!=0 ){
int fd;
- rc = openDirectory(zPath, &fd);
+ rc = osOpenDirectory(zPath, &fd);
if( rc==SQLITE_OK ){
#if OS_VXWORKS
if( fsync(fd)==-1 )
@@ -29660,6 +28346,8 @@ static int unixDelete(
rc = unixLogError(SQLITE_IOERR_DIR_FSYNC, "fsync", zPath);
}
robust_close(0, fd, __LINE__);
+ }else if( rc==SQLITE_CANTOPEN ){
+ rc = SQLITE_OK;
}
}
#endif
@@ -29667,7 +28355,7 @@ static int unixDelete(
}
/*
-** Test the existance of or access permissions of file zPath. The
+** Test the existence of or access permissions of file zPath. The
** test performed depends on the value of flags:
**
** SQLITE_ACCESS_EXISTS: Return 1 if the file exists
@@ -29702,7 +28390,7 @@ static int unixAccess(
*pResOut = (osAccess(zPath, amode)==0);
if( flags==SQLITE_ACCESS_EXISTS && *pResOut ){
struct stat buf;
- if( 0==stat(zPath, &buf) && buf.st_size==0 ){
+ if( 0==osStat(zPath, &buf) && buf.st_size==0 ){
*pResOut = 0;
}
}
@@ -29835,7 +28523,7 @@ static int unixRandomness(sqlite3_vfs *NotUsed, int nBuf, char *zBuf){
memset(zBuf, 0, nBuf);
#if !defined(SQLITE_TEST)
{
- int pid, fd;
+ int pid, fd, got;
fd = robust_open("/dev/urandom", O_RDONLY, 0);
if( fd<0 ){
time_t t;
@@ -29846,7 +28534,7 @@ static int unixRandomness(sqlite3_vfs *NotUsed, int nBuf, char *zBuf){
assert( sizeof(t)+sizeof(pid)<=(size_t)nBuf );
nBuf = sizeof(t) + sizeof(pid);
}else{
- do{ nBuf = osRead(fd, zBuf, nBuf); }while( nBuf<0 && errno==EINTR );
+ do{ got = osRead(fd, zBuf, nBuf); }while( got<0 && errno==EINTR );
robust_close(0, fd, __LINE__);
}
}
@@ -29900,10 +28588,12 @@ SQLITE_API int sqlite3_current_time = 0; /* Fake system time in seconds since 1
** epoch of noon in Greenwich on November 24, 4714 B.C according to the
** proleptic Gregorian calendar.
**
-** On success, return 0. Return 1 if the time and date cannot be found.
+** On success, return SQLITE_OK. Return SQLITE_ERROR if the time and date
+** cannot be found.
*/
static int unixCurrentTimeInt64(sqlite3_vfs *NotUsed, sqlite3_int64 *piNow){
static const sqlite3_int64 unixEpoch = 24405875*(sqlite3_int64)8640000;
+ int rc = SQLITE_OK;
#if defined(NO_GETTOD)
time_t t;
time(&t);
@@ -29914,8 +28604,11 @@ static int unixCurrentTimeInt64(sqlite3_vfs *NotUsed, sqlite3_int64 *piNow){
*piNow = unixEpoch + 1000*(sqlite3_int64)sNow.tv_sec + sNow.tv_nsec/1000000;
#else
struct timeval sNow;
- gettimeofday(&sNow, 0);
- *piNow = unixEpoch + 1000*(sqlite3_int64)sNow.tv_sec + sNow.tv_usec/1000;
+ if( gettimeofday(&sNow, 0)==0 ){
+ *piNow = unixEpoch + 1000*(sqlite3_int64)sNow.tv_sec + sNow.tv_usec/1000;
+ }else{
+ rc = SQLITE_ERROR;
+ }
#endif
#ifdef SQLITE_TEST
@@ -29924,7 +28617,7 @@ static int unixCurrentTimeInt64(sqlite3_vfs *NotUsed, sqlite3_int64 *piNow){
}
#endif
UNUSED_PARAMETER(NotUsed);
- return 0;
+ return rc;
}
/*
@@ -29933,11 +28626,12 @@ static int unixCurrentTimeInt64(sqlite3_vfs *NotUsed, sqlite3_int64 *piNow){
** return 0. Return 1 if the time and date cannot be found.
*/
static int unixCurrentTime(sqlite3_vfs *NotUsed, double *prNow){
- sqlite3_int64 i;
+ sqlite3_int64 i = 0;
+ int rc;
UNUSED_PARAMETER(NotUsed);
- unixCurrentTimeInt64(0, &i);
+ rc = unixCurrentTimeInt64(0, &i);
*prNow = i/86400000.0;
- return 0;
+ return rc;
}
/*
@@ -29983,7 +28677,7 @@ static int unixGetLastError(sqlite3_vfs *NotUsed, int NotUsed2, char *NotUsed3){
** address in the shared range is taken for a SHARED lock, the entire
** shared range is taken for an EXCLUSIVE lock):
**
-** PENDING_BYTE 0x40000000
+** PENDING_BYTE 0x40000000
** RESERVED_BYTE 0x40000001
** SHARED_RANGE 0x40000002 -> 0x40000200
**
@@ -30190,7 +28884,7 @@ static int proxyCreateLockPath(const char *lockPath){
if( i-start>2 || (i-start==1 && buf[start] != '.' && buf[start] != '/')
|| (i-start==2 && buf[start] != '.' && buf[start+1] != '.') ){
buf[i]='\0';
- if( mkdir(buf, SQLITE_DEFAULT_PROXYDIR_PERMISSIONS) ){
+ if( osMkdir(buf, SQLITE_DEFAULT_PROXYDIR_PERMISSIONS) ){
int err=errno;
if( err!=EEXIST ) {
OSTRACE(("CREATELOCKPATH FAILED creating %s, "
@@ -30221,7 +28915,6 @@ static int proxyCreateUnixFile(
int islockfile /* if non zero missing dirs will be created */
) {
int fd = -1;
- int dirfd = -1;
unixFile *pNew;
int rc = SQLITE_OK;
int openFlags = O_RDWR | O_CREAT;
@@ -30245,17 +28938,17 @@ static int proxyCreateUnixFile(
}
}
if( fd<0 ){
- fd = robust_open(path, openFlags, SQLITE_DEFAULT_FILE_PERMISSIONS);
+ fd = robust_open(path, openFlags, 0);
terrno = errno;
if( fd<0 && errno==ENOENT && islockfile ){
if( proxyCreateLockPath(path) == SQLITE_OK ){
- fd = robust_open(path, openFlags, SQLITE_DEFAULT_FILE_PERMISSIONS);
+ fd = robust_open(path, openFlags, 0);
}
}
}
if( fd<0 ){
openFlags = O_RDONLY;
- fd = robust_open(path, openFlags, SQLITE_DEFAULT_FILE_PERMISSIONS);
+ fd = robust_open(path, openFlags, 0);
terrno = errno;
}
if( fd<0 ){
@@ -30286,7 +28979,7 @@ static int proxyCreateUnixFile(
pUnused->flags = openFlags;
pNew->pUnused = pUnused;
- rc = fillInUnixFile(&dummyVfs, fd, dirfd, (sqlite3_file*)pNew, path, 0, 0, 0);
+ rc = fillInUnixFile(&dummyVfs, fd, (sqlite3_file*)pNew, path, 0);
if( rc==SQLITE_OK ){
*ppFile = pNew;
return SQLITE_OK;
@@ -30326,6 +29019,8 @@ static int proxyGetHostID(unsigned char *pHostID, int *pError){
return SQLITE_IOERR;
}
}
+#else
+ UNUSED_PARAMETER(pError);
#endif
#ifdef SQLITE_TEST
/* simulate multiple hosts by creating unique hostid file paths */
@@ -30377,8 +29072,7 @@ static int proxyBreakConchLock(unixFile *pFile, uuid_t myHostID){
goto end_breaklock;
}
/* write it out to the temporary break file */
- fd = robust_open(tPath, (O_RDWR|O_CREAT|O_EXCL),
- SQLITE_DEFAULT_FILE_PERMISSIONS);
+ fd = robust_open(tPath, (O_RDWR|O_CREAT|O_EXCL), 0);
if( fd<0 ){
sqlite3_snprintf(sizeof(errmsg), errmsg, "create failed (%d)", errno);
goto end_breaklock;
@@ -30400,7 +29094,7 @@ static int proxyBreakConchLock(unixFile *pFile, uuid_t myHostID){
end_breaklock:
if( rc ){
if( fd>=0 ){
- unlink(tPath);
+ osUnlink(tPath);
robust_close(pFile, fd, __LINE__);
}
fprintf(stderr, "failed to break stale lock on %s, %s\n", cPath, errmsg);
@@ -30418,6 +29112,7 @@ static int proxyConchLock(unixFile *pFile, uuid_t myHostID, int lockType){
int nTries = 0;
struct timespec conchModTime;
+ memset(&conchModTime, 0, sizeof(conchModTime));
do {
rc = conchFile->pMethod->xLock((sqlite3_file*)conchFile, lockType);
nTries ++;
@@ -30649,12 +29344,12 @@ static int proxyTakeConch(unixFile *pFile){
end_takeconch:
OSTRACE(("TRANSPROXY: CLOSE %d\n", pFile->h));
if( rc==SQLITE_OK && pFile->openFlags ){
+ int fd;
if( pFile->h>=0 ){
robust_close(pFile, pFile->h, __LINE__);
}
pFile->h = -1;
- int fd = robust_open(pCtx->dbPath, pFile->openFlags,
- SQLITE_DEFAULT_FILE_PERMISSIONS);
+ fd = robust_open(pCtx->dbPath, pFile->openFlags, 0);
OSTRACE(("TRANSPROXY: OPEN %d\n", fd));
if( fd>=0 ){
pFile->h = fd;
@@ -31223,7 +29918,7 @@ SQLITE_API int sqlite3_os_init(void){
/* Double-check that the aSyscall[] array has been constructed
** correctly. See ticket [bb3a86e890c8e96ab] */
- assert( ArraySize(aSyscall)==16 );
+ assert( ArraySize(aSyscall)==21 );
/* Register all VFSes defined in the aVfs[] array */
for(i=0; i<(sizeof(aVfs)/sizeof(sqlite3_vfs)); i++){
@@ -31259,53 +29954,15 @@ SQLITE_API int sqlite3_os_end(void){
**
******************************************************************************
**
-** This file contains code that is specific to windows.
-*/
-#if SQLITE_OS_WIN /* This file is used for windows only */
-
-
-/*
-** A Note About Memory Allocation:
-**
-** This driver uses malloc()/free() directly rather than going through
-** the SQLite-wrappers sqlite3_malloc()/sqlite3_free(). Those wrappers
-** are designed for use on embedded systems where memory is scarce and
-** malloc failures happen frequently. Win32 does not typically run on
-** embedded systems, and when it does the developers normally have bigger
-** problems to worry about than running out of memory. So there is not
-** a compelling need to use the wrappers.
-**
-** But there is a good reason to not use the wrappers. If we use the
-** wrappers then we will get simulated malloc() failures within this
-** driver. And that causes all kinds of problems for our tests. We
-** could enhance SQLite to deal with simulated malloc failures within
-** the OS driver, but the code to deal with those failure would not
-** be exercised on Linux (which does not need to malloc() in the driver)
-** and so we would have difficulty writing coverage tests for that
-** code. Better to leave the code out, we think.
-**
-** The point of this discussion is as follows: When creating a new
-** OS layer for an embedded system, if you use this file as an example,
-** avoid the use of malloc()/free(). Those routines work ok on windows
-** desktops but not so well in embedded systems.
+** This file contains code that is specific to Windows.
*/
-
-#include <qconfig.h>
-
-#include <winbase.h>
+#if SQLITE_OS_WIN /* This file is used for Windows only */
#ifdef __CYGWIN__
# include <sys/cygwin.h>
#endif
/*
-** Macros used to determine whether or not to use threads.
-*/
-#ifndef QT_NO_THREAD
-# define SQLITE_W32_THREADS 1
-#endif
-
-/*
** Include code that is common to all os_*.c files
*/
/************** Include os_common.h in the middle of os_win.c ****************/
@@ -31341,11 +29998,14 @@ SQLITE_API int sqlite3_os_end(void){
# error "The MEMORY_DEBUG macro is obsolete. Use SQLITE_DEBUG instead."
#endif
-#ifdef SQLITE_DEBUG
-SQLITE_PRIVATE int sqlite3OSTrace = 0;
-#define OSTRACE(X) if( sqlite3OSTrace ) sqlite3DebugPrintf X
+#if defined(SQLITE_TEST) && defined(SQLITE_DEBUG)
+# ifndef SQLITE_DEBUG_OS_TRACE
+# define SQLITE_DEBUG_OS_TRACE 0
+# endif
+ int sqlite3OSTrace = SQLITE_DEBUG_OS_TRACE;
+# define OSTRACE(X) if( sqlite3OSTrace ) sqlite3DebugPrintf X
#else
-#define OSTRACE(X)
+# define OSTRACE(X)
#endif
/*
@@ -31516,24 +30176,92 @@ SQLITE_API int sqlite3_open_file_count = 0;
/************** Continuing where we left off in os_win.c *********************/
/*
-** Some microsoft compilers lack this definition.
+** Compiling and using WAL mode requires several APIs that are only
+** available in Windows platforms based on the NT kernel.
*/
-#ifndef INVALID_FILE_ATTRIBUTES
-# define INVALID_FILE_ATTRIBUTES ((DWORD)-1)
+#if !SQLITE_OS_WINNT && !defined(SQLITE_OMIT_WAL)
+# error "WAL mode requires support from the Windows NT kernel, compile\
+ with SQLITE_OMIT_WAL."
#endif
/*
-** Determine if we are dealing with WindowsCE - which has a much
-** reduced API.
+** Are most of the Win32 ANSI APIs available (i.e. with certain exceptions
+** based on the sub-platform)?
*/
-#if SQLITE_OS_WINCE
-# define AreFileApisANSI() 1
-# define FormatMessageW(a,b,c,d,e,f,g) 0
+#if !SQLITE_OS_WINCE && !SQLITE_OS_WINRT
+# define SQLITE_WIN32_HAS_ANSI
#endif
+/*
+** Are most of the Win32 Unicode APIs available (i.e. with certain exceptions
+** based on the sub-platform)?
+*/
+#if SQLITE_OS_WINCE || SQLITE_OS_WINNT || SQLITE_OS_WINRT
+# define SQLITE_WIN32_HAS_WIDE
+#endif
+
+/*
+** Do we need to manually define the Win32 file mapping APIs for use with WAL
+** mode (e.g. these APIs are available in the Windows CE SDK; however, they
+** are not present in the header file)?
+*/
+#if SQLITE_WIN32_FILEMAPPING_API && !defined(SQLITE_OMIT_WAL)
+/*
+** Two of the file mapping APIs are different under WinRT. Figure out which
+** set we need.
+*/
+#if SQLITE_OS_WINRT
+WINBASEAPI HANDLE WINAPI CreateFileMappingFromApp(HANDLE, \
+ LPSECURITY_ATTRIBUTES, ULONG, ULONG64, LPCWSTR);
+
+WINBASEAPI LPVOID WINAPI MapViewOfFileFromApp(HANDLE, ULONG, ULONG64, SIZE_T);
+#else
+#if defined(SQLITE_WIN32_HAS_ANSI)
+WINBASEAPI HANDLE WINAPI CreateFileMappingA(HANDLE, LPSECURITY_ATTRIBUTES, \
+ DWORD, DWORD, DWORD, LPCSTR);
+#endif /* defined(SQLITE_WIN32_HAS_ANSI) */
+
+#if defined(SQLITE_WIN32_HAS_WIDE)
+WINBASEAPI HANDLE WINAPI CreateFileMappingW(HANDLE, LPSECURITY_ATTRIBUTES, \
+ DWORD, DWORD, DWORD, LPCWSTR);
+#endif /* defined(SQLITE_WIN32_HAS_WIDE) */
+
+WINBASEAPI LPVOID WINAPI MapViewOfFile(HANDLE, DWORD, DWORD, DWORD, SIZE_T);
+#endif /* SQLITE_OS_WINRT */
+
+/*
+** This file mapping API is common to both Win32 and WinRT.
+*/
+WINBASEAPI BOOL WINAPI UnmapViewOfFile(LPCVOID);
+#endif /* SQLITE_WIN32_FILEMAPPING_API && !defined(SQLITE_OMIT_WAL) */
+
+/*
+** Macro to find the minimum of two numeric values.
+*/
+#ifndef MIN
+# define MIN(x,y) ((x)<(y)?(x):(y))
+#endif
+
+/*
+** Some Microsoft compilers lack this definition.
+*/
+#ifndef INVALID_FILE_ATTRIBUTES
+# define INVALID_FILE_ATTRIBUTES ((DWORD)-1)
+#endif
+
+#ifndef FILE_FLAG_MASK
+# define FILE_FLAG_MASK (0xFF3C0000)
+#endif
+
+#ifndef FILE_ATTRIBUTE_MASK
+# define FILE_ATTRIBUTE_MASK (0x0003FFF7)
+#endif
+
+#ifndef SQLITE_OMIT_WAL
/* Forward references */
typedef struct winShm winShm; /* A connection to shared-memory */
typedef struct winShmNode winShmNode; /* A region of shared-memory */
+#endif
/*
** WinCE lacks native support for file locking so we have to fake it
@@ -31557,15 +30285,17 @@ struct winFile {
const sqlite3_io_methods *pMethod; /*** Must be first ***/
sqlite3_vfs *pVfs; /* The VFS used to open this file */
HANDLE h; /* Handle for accessing the file */
- unsigned char locktype; /* Type of lock currently held on this file */
+ u8 locktype; /* Type of lock currently held on this file */
short sharedLockByte; /* Randomly chosen byte used as a shared lock */
+ u8 ctrlFlags; /* Flags. See WINFILE_* below */
DWORD lastErrno; /* The Windows errno from the last I/O error */
- DWORD sectorSize; /* Sector size of the device file is on */
+#ifndef SQLITE_OMIT_WAL
winShm *pShm; /* Instance of shared memory on this file */
+#endif
const char *zPath; /* Full pathname of this file */
int szChunk; /* Chunk size configured by FCNTL_CHUNK_SIZE */
#if SQLITE_OS_WINCE
- WCHAR *zDeleteOnClose; /* Name of file to delete when closing */
+ LPWSTR zDeleteOnClose; /* Name of file to delete when closing */
HANDLE hMutex; /* Mutex used to control access to shared lock */
HANDLE hShared; /* Shared memory segment used for locking */
winceLock local; /* Locks obtained by this instance of winFile */
@@ -31573,22 +30303,132 @@ struct winFile {
#endif
};
+/*
+** Allowed values for winFile.ctrlFlags
+*/
+#define WINFILE_PERSIST_WAL 0x04 /* Persistent WAL mode */
+#define WINFILE_PSOW 0x10 /* SQLITE_IOCAP_POWERSAFE_OVERWRITE */
+
+/*
+ * The size of the buffer used by sqlite3_win32_write_debug().
+ */
+#ifndef SQLITE_WIN32_DBG_BUF_SIZE
+# define SQLITE_WIN32_DBG_BUF_SIZE ((int)(4096-sizeof(DWORD)))
+#endif
+
+/*
+ * The value used with sqlite3_win32_set_directory() to specify that
+ * the data directory should be changed.
+ */
+#ifndef SQLITE_WIN32_DATA_DIRECTORY_TYPE
+# define SQLITE_WIN32_DATA_DIRECTORY_TYPE (1)
+#endif
+
+/*
+ * The value used with sqlite3_win32_set_directory() to specify that
+ * the temporary directory should be changed.
+ */
+#ifndef SQLITE_WIN32_TEMP_DIRECTORY_TYPE
+# define SQLITE_WIN32_TEMP_DIRECTORY_TYPE (2)
+#endif
+
+/*
+ * If compiled with SQLITE_WIN32_MALLOC on Windows, we will use the
+ * various Win32 API heap functions instead of our own.
+ */
+#ifdef SQLITE_WIN32_MALLOC
+
+/*
+ * If this is non-zero, an isolated heap will be created by the native Win32
+ * allocator subsystem; otherwise, the default process heap will be used. This
+ * setting has no effect when compiling for WinRT. By default, this is enabled
+ * and an isolated heap will be created to store all allocated data.
+ *
+ ******************************************************************************
+ * WARNING: It is important to note that when this setting is non-zero and the
+ * winMemShutdown function is called (e.g. by the sqlite3_shutdown
+ * function), all data that was allocated using the isolated heap will
+ * be freed immediately and any attempt to access any of that freed
+ * data will almost certainly result in an immediate access violation.
+ ******************************************************************************
+ */
+#ifndef SQLITE_WIN32_HEAP_CREATE
+# define SQLITE_WIN32_HEAP_CREATE (TRUE)
+#endif
/*
-** Forward prototypes.
+ * The initial size of the Win32-specific heap. This value may be zero.
+ */
+#ifndef SQLITE_WIN32_HEAP_INIT_SIZE
+# define SQLITE_WIN32_HEAP_INIT_SIZE ((SQLITE_DEFAULT_CACHE_SIZE) * \
+ (SQLITE_DEFAULT_PAGE_SIZE) + 4194304)
+#endif
+
+/*
+ * The maximum size of the Win32-specific heap. This value may be zero.
+ */
+#ifndef SQLITE_WIN32_HEAP_MAX_SIZE
+# define SQLITE_WIN32_HEAP_MAX_SIZE (0)
+#endif
+
+/*
+ * The extra flags to use in calls to the Win32 heap APIs. This value may be
+ * zero for the default behavior.
+ */
+#ifndef SQLITE_WIN32_HEAP_FLAGS
+# define SQLITE_WIN32_HEAP_FLAGS (0)
+#endif
+
+/*
+** The winMemData structure stores information required by the Win32-specific
+** sqlite3_mem_methods implementation.
*/
-static int getSectorSize(
- sqlite3_vfs *pVfs,
- const char *zRelative /* UTF-8 file name */
-);
+typedef struct winMemData winMemData;
+struct winMemData {
+#ifndef NDEBUG
+ u32 magic; /* Magic number to detect structure corruption. */
+#endif
+ HANDLE hHeap; /* The handle to our heap. */
+ BOOL bOwned; /* Do we own the heap (i.e. destroy it on shutdown)? */
+};
+
+#ifndef NDEBUG
+#define WINMEM_MAGIC 0x42b2830b
+#endif
+
+static struct winMemData win_mem_data = {
+#ifndef NDEBUG
+ WINMEM_MAGIC,
+#endif
+ NULL, FALSE
+};
+
+#ifndef NDEBUG
+#define winMemAssertMagic() assert( win_mem_data.magic==WINMEM_MAGIC )
+#else
+#define winMemAssertMagic()
+#endif
+
+#define winMemGetHeap() win_mem_data.hHeap
+
+static void *winMemMalloc(int nBytes);
+static void winMemFree(void *pPrior);
+static void *winMemRealloc(void *pPrior, int nBytes);
+static int winMemSize(void *p);
+static int winMemRoundup(int n);
+static int winMemInit(void *pAppData);
+static void winMemShutdown(void *pAppData);
+
+SQLITE_PRIVATE const sqlite3_mem_methods *sqlite3MemGetWin32(void);
+#endif /* SQLITE_WIN32_MALLOC */
/*
** The following variable is (normally) set once and never changes
-** thereafter. It records whether the operating system is Win95
+** thereafter. It records whether the operating system is Win9x
** or WinNT.
**
** 0: Operating system unknown.
-** 1: Operating system is Win95.
+** 1: Operating system is Win9x.
** 2: Operating system is WinNT.
**
** In order to facilitate testing on a WinNT system, the test fixture
@@ -31600,6 +30440,758 @@ SQLITE_API int sqlite3_os_type = 0;
static int sqlite3_os_type = 0;
#endif
+#ifndef SYSCALL
+# define SYSCALL sqlite3_syscall_ptr
+#endif
+
+/*
+** This function is not available on Windows CE or WinRT.
+ */
+
+#if SQLITE_OS_WINCE || SQLITE_OS_WINRT
+# define osAreFileApisANSI() 1
+#endif
+
+/*
+** Many system calls are accessed through pointer-to-functions so that
+** they may be overridden at runtime to facilitate fault injection during
+** testing and sandboxing. The following array holds the names and pointers
+** to all overrideable system calls.
+*/
+static struct win_syscall {
+ const char *zName; /* Name of the system call */
+ sqlite3_syscall_ptr pCurrent; /* Current value of the system call */
+ sqlite3_syscall_ptr pDefault; /* Default value */
+} aSyscall[] = {
+#if !SQLITE_OS_WINCE && !SQLITE_OS_WINRT
+ { "AreFileApisANSI", (SYSCALL)AreFileApisANSI, 0 },
+#else
+ { "AreFileApisANSI", (SYSCALL)0, 0 },
+#endif
+
+#ifndef osAreFileApisANSI
+#define osAreFileApisANSI ((BOOL(WINAPI*)(VOID))aSyscall[0].pCurrent)
+#endif
+
+#if SQLITE_OS_WINCE && defined(SQLITE_WIN32_HAS_WIDE)
+ { "CharLowerW", (SYSCALL)CharLowerW, 0 },
+#else
+ { "CharLowerW", (SYSCALL)0, 0 },
+#endif
+
+#define osCharLowerW ((LPWSTR(WINAPI*)(LPWSTR))aSyscall[1].pCurrent)
+
+#if SQLITE_OS_WINCE && defined(SQLITE_WIN32_HAS_WIDE)
+ { "CharUpperW", (SYSCALL)CharUpperW, 0 },
+#else
+ { "CharUpperW", (SYSCALL)0, 0 },
+#endif
+
+#define osCharUpperW ((LPWSTR(WINAPI*)(LPWSTR))aSyscall[2].pCurrent)
+
+ { "CloseHandle", (SYSCALL)CloseHandle, 0 },
+
+#define osCloseHandle ((BOOL(WINAPI*)(HANDLE))aSyscall[3].pCurrent)
+
+#if defined(SQLITE_WIN32_HAS_ANSI)
+ { "CreateFileA", (SYSCALL)CreateFileA, 0 },
+#else
+ { "CreateFileA", (SYSCALL)0, 0 },
+#endif
+
+#define osCreateFileA ((HANDLE(WINAPI*)(LPCSTR,DWORD,DWORD, \
+ LPSECURITY_ATTRIBUTES,DWORD,DWORD,HANDLE))aSyscall[4].pCurrent)
+
+#if !SQLITE_OS_WINRT && defined(SQLITE_WIN32_HAS_WIDE)
+ { "CreateFileW", (SYSCALL)CreateFileW, 0 },
+#else
+ { "CreateFileW", (SYSCALL)0, 0 },
+#endif
+
+#define osCreateFileW ((HANDLE(WINAPI*)(LPCWSTR,DWORD,DWORD, \
+ LPSECURITY_ATTRIBUTES,DWORD,DWORD,HANDLE))aSyscall[5].pCurrent)
+
+#if (!SQLITE_OS_WINRT && defined(SQLITE_WIN32_HAS_ANSI) && \
+ !defined(SQLITE_OMIT_WAL))
+ { "CreateFileMappingA", (SYSCALL)CreateFileMappingA, 0 },
+#else
+ { "CreateFileMappingA", (SYSCALL)0, 0 },
+#endif
+
+#define osCreateFileMappingA ((HANDLE(WINAPI*)(HANDLE,LPSECURITY_ATTRIBUTES, \
+ DWORD,DWORD,DWORD,LPCSTR))aSyscall[6].pCurrent)
+
+#if SQLITE_OS_WINCE || (!SQLITE_OS_WINRT && defined(SQLITE_WIN32_HAS_WIDE) && \
+ !defined(SQLITE_OMIT_WAL))
+ { "CreateFileMappingW", (SYSCALL)CreateFileMappingW, 0 },
+#else
+ { "CreateFileMappingW", (SYSCALL)0, 0 },
+#endif
+
+#define osCreateFileMappingW ((HANDLE(WINAPI*)(HANDLE,LPSECURITY_ATTRIBUTES, \
+ DWORD,DWORD,DWORD,LPCWSTR))aSyscall[7].pCurrent)
+
+#if !SQLITE_OS_WINRT && defined(SQLITE_WIN32_HAS_WIDE)
+ { "CreateMutexW", (SYSCALL)CreateMutexW, 0 },
+#else
+ { "CreateMutexW", (SYSCALL)0, 0 },
+#endif
+
+#define osCreateMutexW ((HANDLE(WINAPI*)(LPSECURITY_ATTRIBUTES,BOOL, \
+ LPCWSTR))aSyscall[8].pCurrent)
+
+#if defined(SQLITE_WIN32_HAS_ANSI)
+ { "DeleteFileA", (SYSCALL)DeleteFileA, 0 },
+#else
+ { "DeleteFileA", (SYSCALL)0, 0 },
+#endif
+
+#define osDeleteFileA ((BOOL(WINAPI*)(LPCSTR))aSyscall[9].pCurrent)
+
+#if defined(SQLITE_WIN32_HAS_WIDE)
+ { "DeleteFileW", (SYSCALL)DeleteFileW, 0 },
+#else
+ { "DeleteFileW", (SYSCALL)0, 0 },
+#endif
+
+#define osDeleteFileW ((BOOL(WINAPI*)(LPCWSTR))aSyscall[10].pCurrent)
+
+#if SQLITE_OS_WINCE
+ { "FileTimeToLocalFileTime", (SYSCALL)FileTimeToLocalFileTime, 0 },
+#else
+ { "FileTimeToLocalFileTime", (SYSCALL)0, 0 },
+#endif
+
+#define osFileTimeToLocalFileTime ((BOOL(WINAPI*)(CONST FILETIME*, \
+ LPFILETIME))aSyscall[11].pCurrent)
+
+#if SQLITE_OS_WINCE
+ { "FileTimeToSystemTime", (SYSCALL)FileTimeToSystemTime, 0 },
+#else
+ { "FileTimeToSystemTime", (SYSCALL)0, 0 },
+#endif
+
+#define osFileTimeToSystemTime ((BOOL(WINAPI*)(CONST FILETIME*, \
+ LPSYSTEMTIME))aSyscall[12].pCurrent)
+
+ { "FlushFileBuffers", (SYSCALL)FlushFileBuffers, 0 },
+
+#define osFlushFileBuffers ((BOOL(WINAPI*)(HANDLE))aSyscall[13].pCurrent)
+
+#if defined(SQLITE_WIN32_HAS_ANSI)
+ { "FormatMessageA", (SYSCALL)FormatMessageA, 0 },
+#else
+ { "FormatMessageA", (SYSCALL)0, 0 },
+#endif
+
+#define osFormatMessageA ((DWORD(WINAPI*)(DWORD,LPCVOID,DWORD,DWORD,LPSTR, \
+ DWORD,va_list*))aSyscall[14].pCurrent)
+
+#if defined(SQLITE_WIN32_HAS_WIDE)
+ { "FormatMessageW", (SYSCALL)FormatMessageW, 0 },
+#else
+ { "FormatMessageW", (SYSCALL)0, 0 },
+#endif
+
+#define osFormatMessageW ((DWORD(WINAPI*)(DWORD,LPCVOID,DWORD,DWORD,LPWSTR, \
+ DWORD,va_list*))aSyscall[15].pCurrent)
+
+#if !defined(SQLITE_OMIT_LOAD_EXTENSION)
+ { "FreeLibrary", (SYSCALL)FreeLibrary, 0 },
+#else
+ { "FreeLibrary", (SYSCALL)0, 0 },
+#endif
+
+#define osFreeLibrary ((BOOL(WINAPI*)(HMODULE))aSyscall[16].pCurrent)
+
+ { "GetCurrentProcessId", (SYSCALL)GetCurrentProcessId, 0 },
+
+#define osGetCurrentProcessId ((DWORD(WINAPI*)(VOID))aSyscall[17].pCurrent)
+
+#if !SQLITE_OS_WINCE && defined(SQLITE_WIN32_HAS_ANSI)
+ { "GetDiskFreeSpaceA", (SYSCALL)GetDiskFreeSpaceA, 0 },
+#else
+ { "GetDiskFreeSpaceA", (SYSCALL)0, 0 },
+#endif
+
+#define osGetDiskFreeSpaceA ((BOOL(WINAPI*)(LPCSTR,LPDWORD,LPDWORD,LPDWORD, \
+ LPDWORD))aSyscall[18].pCurrent)
+
+#if !SQLITE_OS_WINCE && !SQLITE_OS_WINRT && defined(SQLITE_WIN32_HAS_WIDE)
+ { "GetDiskFreeSpaceW", (SYSCALL)GetDiskFreeSpaceW, 0 },
+#else
+ { "GetDiskFreeSpaceW", (SYSCALL)0, 0 },
+#endif
+
+#define osGetDiskFreeSpaceW ((BOOL(WINAPI*)(LPCWSTR,LPDWORD,LPDWORD,LPDWORD, \
+ LPDWORD))aSyscall[19].pCurrent)
+
+#if defined(SQLITE_WIN32_HAS_ANSI)
+ { "GetFileAttributesA", (SYSCALL)GetFileAttributesA, 0 },
+#else
+ { "GetFileAttributesA", (SYSCALL)0, 0 },
+#endif
+
+#define osGetFileAttributesA ((DWORD(WINAPI*)(LPCSTR))aSyscall[20].pCurrent)
+
+#if !SQLITE_OS_WINRT && defined(SQLITE_WIN32_HAS_WIDE)
+ { "GetFileAttributesW", (SYSCALL)GetFileAttributesW, 0 },
+#else
+ { "GetFileAttributesW", (SYSCALL)0, 0 },
+#endif
+
+#define osGetFileAttributesW ((DWORD(WINAPI*)(LPCWSTR))aSyscall[21].pCurrent)
+
+#if defined(SQLITE_WIN32_HAS_WIDE)
+ { "GetFileAttributesExW", (SYSCALL)GetFileAttributesExW, 0 },
+#else
+ { "GetFileAttributesExW", (SYSCALL)0, 0 },
+#endif
+
+#define osGetFileAttributesExW ((BOOL(WINAPI*)(LPCWSTR,GET_FILEEX_INFO_LEVELS, \
+ LPVOID))aSyscall[22].pCurrent)
+
+#if !SQLITE_OS_WINRT
+ { "GetFileSize", (SYSCALL)GetFileSize, 0 },
+#else
+ { "GetFileSize", (SYSCALL)0, 0 },
+#endif
+
+#define osGetFileSize ((DWORD(WINAPI*)(HANDLE,LPDWORD))aSyscall[23].pCurrent)
+
+#if !SQLITE_OS_WINCE && defined(SQLITE_WIN32_HAS_ANSI)
+ { "GetFullPathNameA", (SYSCALL)GetFullPathNameA, 0 },
+#else
+ { "GetFullPathNameA", (SYSCALL)0, 0 },
+#endif
+
+#define osGetFullPathNameA ((DWORD(WINAPI*)(LPCSTR,DWORD,LPSTR, \
+ LPSTR*))aSyscall[24].pCurrent)
+
+#if !SQLITE_OS_WINCE && !SQLITE_OS_WINRT && defined(SQLITE_WIN32_HAS_WIDE)
+ { "GetFullPathNameW", (SYSCALL)GetFullPathNameW, 0 },
+#else
+ { "GetFullPathNameW", (SYSCALL)0, 0 },
+#endif
+
+#define osGetFullPathNameW ((DWORD(WINAPI*)(LPCWSTR,DWORD,LPWSTR, \
+ LPWSTR*))aSyscall[25].pCurrent)
+
+ { "GetLastError", (SYSCALL)GetLastError, 0 },
+
+#define osGetLastError ((DWORD(WINAPI*)(VOID))aSyscall[26].pCurrent)
+
+#if !defined(SQLITE_OMIT_LOAD_EXTENSION)
+#if SQLITE_OS_WINCE
+ /* The GetProcAddressA() routine is only available on Windows CE. */
+ { "GetProcAddressA", (SYSCALL)GetProcAddressA, 0 },
+#else
+ /* All other Windows platforms expect GetProcAddress() to take
+ ** an ANSI string regardless of the _UNICODE setting */
+ { "GetProcAddressA", (SYSCALL)GetProcAddress, 0 },
+#endif
+#else
+ { "GetProcAddressA", (SYSCALL)0, 0 },
+#endif
+
+#define osGetProcAddressA ((FARPROC(WINAPI*)(HMODULE, \
+ LPCSTR))aSyscall[27].pCurrent)
+
+#if !SQLITE_OS_WINRT
+ { "GetSystemInfo", (SYSCALL)GetSystemInfo, 0 },
+#else
+ { "GetSystemInfo", (SYSCALL)0, 0 },
+#endif
+
+#define osGetSystemInfo ((VOID(WINAPI*)(LPSYSTEM_INFO))aSyscall[28].pCurrent)
+
+ { "GetSystemTime", (SYSCALL)GetSystemTime, 0 },
+
+#define osGetSystemTime ((VOID(WINAPI*)(LPSYSTEMTIME))aSyscall[29].pCurrent)
+
+#if !SQLITE_OS_WINCE
+ { "GetSystemTimeAsFileTime", (SYSCALL)GetSystemTimeAsFileTime, 0 },
+#else
+ { "GetSystemTimeAsFileTime", (SYSCALL)0, 0 },
+#endif
+
+#define osGetSystemTimeAsFileTime ((VOID(WINAPI*)( \
+ LPFILETIME))aSyscall[30].pCurrent)
+
+#if defined(SQLITE_WIN32_HAS_ANSI)
+ { "GetTempPathA", (SYSCALL)GetTempPathA, 0 },
+#else
+ { "GetTempPathA", (SYSCALL)0, 0 },
+#endif
+
+#define osGetTempPathA ((DWORD(WINAPI*)(DWORD,LPSTR))aSyscall[31].pCurrent)
+
+#if !SQLITE_OS_WINRT && defined(SQLITE_WIN32_HAS_WIDE)
+ { "GetTempPathW", (SYSCALL)GetTempPathW, 0 },
+#else
+ { "GetTempPathW", (SYSCALL)0, 0 },
+#endif
+
+#define osGetTempPathW ((DWORD(WINAPI*)(DWORD,LPWSTR))aSyscall[32].pCurrent)
+
+#if !SQLITE_OS_WINRT
+ { "GetTickCount", (SYSCALL)GetTickCount, 0 },
+#else
+ { "GetTickCount", (SYSCALL)0, 0 },
+#endif
+
+#define osGetTickCount ((DWORD(WINAPI*)(VOID))aSyscall[33].pCurrent)
+
+#if defined(SQLITE_WIN32_HAS_ANSI)
+ { "GetVersionExA", (SYSCALL)GetVersionExA, 0 },
+#else
+ { "GetVersionExA", (SYSCALL)0, 0 },
+#endif
+
+#define osGetVersionExA ((BOOL(WINAPI*)( \
+ LPOSVERSIONINFOA))aSyscall[34].pCurrent)
+
+ { "HeapAlloc", (SYSCALL)HeapAlloc, 0 },
+
+#define osHeapAlloc ((LPVOID(WINAPI*)(HANDLE,DWORD, \
+ SIZE_T))aSyscall[35].pCurrent)
+
+#if !SQLITE_OS_WINRT
+ { "HeapCreate", (SYSCALL)HeapCreate, 0 },
+#else
+ { "HeapCreate", (SYSCALL)0, 0 },
+#endif
+
+#define osHeapCreate ((HANDLE(WINAPI*)(DWORD,SIZE_T, \
+ SIZE_T))aSyscall[36].pCurrent)
+
+#if !SQLITE_OS_WINRT
+ { "HeapDestroy", (SYSCALL)HeapDestroy, 0 },
+#else
+ { "HeapDestroy", (SYSCALL)0, 0 },
+#endif
+
+#define osHeapDestroy ((BOOL(WINAPI*)(HANDLE))aSyscall[37].pCurrent)
+
+ { "HeapFree", (SYSCALL)HeapFree, 0 },
+
+#define osHeapFree ((BOOL(WINAPI*)(HANDLE,DWORD,LPVOID))aSyscall[38].pCurrent)
+
+ { "HeapReAlloc", (SYSCALL)HeapReAlloc, 0 },
+
+#define osHeapReAlloc ((LPVOID(WINAPI*)(HANDLE,DWORD,LPVOID, \
+ SIZE_T))aSyscall[39].pCurrent)
+
+ { "HeapSize", (SYSCALL)HeapSize, 0 },
+
+#define osHeapSize ((SIZE_T(WINAPI*)(HANDLE,DWORD, \
+ LPCVOID))aSyscall[40].pCurrent)
+
+#if !SQLITE_OS_WINRT
+ { "HeapValidate", (SYSCALL)HeapValidate, 0 },
+#else
+ { "HeapValidate", (SYSCALL)0, 0 },
+#endif
+
+#define osHeapValidate ((BOOL(WINAPI*)(HANDLE,DWORD, \
+ LPCVOID))aSyscall[41].pCurrent)
+
+#if defined(SQLITE_WIN32_HAS_ANSI) && !defined(SQLITE_OMIT_LOAD_EXTENSION)
+ { "LoadLibraryA", (SYSCALL)LoadLibraryA, 0 },
+#else
+ { "LoadLibraryA", (SYSCALL)0, 0 },
+#endif
+
+#define osLoadLibraryA ((HMODULE(WINAPI*)(LPCSTR))aSyscall[42].pCurrent)
+
+#if !SQLITE_OS_WINRT && defined(SQLITE_WIN32_HAS_WIDE) && \
+ !defined(SQLITE_OMIT_LOAD_EXTENSION)
+ { "LoadLibraryW", (SYSCALL)LoadLibraryW, 0 },
+#else
+ { "LoadLibraryW", (SYSCALL)0, 0 },
+#endif
+
+#define osLoadLibraryW ((HMODULE(WINAPI*)(LPCWSTR))aSyscall[43].pCurrent)
+
+#if !SQLITE_OS_WINRT
+ { "LocalFree", (SYSCALL)LocalFree, 0 },
+#else
+ { "LocalFree", (SYSCALL)0, 0 },
+#endif
+
+#define osLocalFree ((HLOCAL(WINAPI*)(HLOCAL))aSyscall[44].pCurrent)
+
+#if !SQLITE_OS_WINCE && !SQLITE_OS_WINRT
+ { "LockFile", (SYSCALL)LockFile, 0 },
+#else
+ { "LockFile", (SYSCALL)0, 0 },
+#endif
+
+#ifndef osLockFile
+#define osLockFile ((BOOL(WINAPI*)(HANDLE,DWORD,DWORD,DWORD, \
+ DWORD))aSyscall[45].pCurrent)
+#endif
+
+#if !SQLITE_OS_WINCE
+ { "LockFileEx", (SYSCALL)LockFileEx, 0 },
+#else
+ { "LockFileEx", (SYSCALL)0, 0 },
+#endif
+
+#ifndef osLockFileEx
+#define osLockFileEx ((BOOL(WINAPI*)(HANDLE,DWORD,DWORD,DWORD,DWORD, \
+ LPOVERLAPPED))aSyscall[46].pCurrent)
+#endif
+
+#if SQLITE_OS_WINCE || (!SQLITE_OS_WINRT && !defined(SQLITE_OMIT_WAL))
+ { "MapViewOfFile", (SYSCALL)MapViewOfFile, 0 },
+#else
+ { "MapViewOfFile", (SYSCALL)0, 0 },
+#endif
+
+#define osMapViewOfFile ((LPVOID(WINAPI*)(HANDLE,DWORD,DWORD,DWORD, \
+ SIZE_T))aSyscall[47].pCurrent)
+
+ { "MultiByteToWideChar", (SYSCALL)MultiByteToWideChar, 0 },
+
+#define osMultiByteToWideChar ((int(WINAPI*)(UINT,DWORD,LPCSTR,int,LPWSTR, \
+ int))aSyscall[48].pCurrent)
+
+ { "QueryPerformanceCounter", (SYSCALL)QueryPerformanceCounter, 0 },
+
+#define osQueryPerformanceCounter ((BOOL(WINAPI*)( \
+ LARGE_INTEGER*))aSyscall[49].pCurrent)
+
+ { "ReadFile", (SYSCALL)ReadFile, 0 },
+
+#define osReadFile ((BOOL(WINAPI*)(HANDLE,LPVOID,DWORD,LPDWORD, \
+ LPOVERLAPPED))aSyscall[50].pCurrent)
+
+ { "SetEndOfFile", (SYSCALL)SetEndOfFile, 0 },
+
+#define osSetEndOfFile ((BOOL(WINAPI*)(HANDLE))aSyscall[51].pCurrent)
+
+#if !SQLITE_OS_WINRT
+ { "SetFilePointer", (SYSCALL)SetFilePointer, 0 },
+#else
+ { "SetFilePointer", (SYSCALL)0, 0 },
+#endif
+
+#define osSetFilePointer ((DWORD(WINAPI*)(HANDLE,LONG,PLONG, \
+ DWORD))aSyscall[52].pCurrent)
+
+#if !SQLITE_OS_WINRT
+ { "Sleep", (SYSCALL)Sleep, 0 },
+#else
+ { "Sleep", (SYSCALL)0, 0 },
+#endif
+
+#define osSleep ((VOID(WINAPI*)(DWORD))aSyscall[53].pCurrent)
+
+ { "SystemTimeToFileTime", (SYSCALL)SystemTimeToFileTime, 0 },
+
+#define osSystemTimeToFileTime ((BOOL(WINAPI*)(CONST SYSTEMTIME*, \
+ LPFILETIME))aSyscall[54].pCurrent)
+
+#if !SQLITE_OS_WINCE && !SQLITE_OS_WINRT
+ { "UnlockFile", (SYSCALL)UnlockFile, 0 },
+#else
+ { "UnlockFile", (SYSCALL)0, 0 },
+#endif
+
+#ifndef osUnlockFile
+#define osUnlockFile ((BOOL(WINAPI*)(HANDLE,DWORD,DWORD,DWORD, \
+ DWORD))aSyscall[55].pCurrent)
+#endif
+
+#if !SQLITE_OS_WINCE
+ { "UnlockFileEx", (SYSCALL)UnlockFileEx, 0 },
+#else
+ { "UnlockFileEx", (SYSCALL)0, 0 },
+#endif
+
+#define osUnlockFileEx ((BOOL(WINAPI*)(HANDLE,DWORD,DWORD,DWORD, \
+ LPOVERLAPPED))aSyscall[56].pCurrent)
+
+#if SQLITE_OS_WINCE || !defined(SQLITE_OMIT_WAL)
+ { "UnmapViewOfFile", (SYSCALL)UnmapViewOfFile, 0 },
+#else
+ { "UnmapViewOfFile", (SYSCALL)0, 0 },
+#endif
+
+#define osUnmapViewOfFile ((BOOL(WINAPI*)(LPCVOID))aSyscall[57].pCurrent)
+
+ { "WideCharToMultiByte", (SYSCALL)WideCharToMultiByte, 0 },
+
+#define osWideCharToMultiByte ((int(WINAPI*)(UINT,DWORD,LPCWSTR,int,LPSTR,int, \
+ LPCSTR,LPBOOL))aSyscall[58].pCurrent)
+
+ { "WriteFile", (SYSCALL)WriteFile, 0 },
+
+#define osWriteFile ((BOOL(WINAPI*)(HANDLE,LPCVOID,DWORD,LPDWORD, \
+ LPOVERLAPPED))aSyscall[59].pCurrent)
+
+#if SQLITE_OS_WINRT
+ { "CreateEventExW", (SYSCALL)CreateEventExW, 0 },
+#else
+ { "CreateEventExW", (SYSCALL)0, 0 },
+#endif
+
+#define osCreateEventExW ((HANDLE(WINAPI*)(LPSECURITY_ATTRIBUTES,LPCWSTR, \
+ DWORD,DWORD))aSyscall[60].pCurrent)
+
+#if !SQLITE_OS_WINRT
+ { "WaitForSingleObject", (SYSCALL)WaitForSingleObject, 0 },
+#else
+ { "WaitForSingleObject", (SYSCALL)0, 0 },
+#endif
+
+#define osWaitForSingleObject ((DWORD(WINAPI*)(HANDLE, \
+ DWORD))aSyscall[61].pCurrent)
+
+#if SQLITE_OS_WINRT
+ { "WaitForSingleObjectEx", (SYSCALL)WaitForSingleObjectEx, 0 },
+#else
+ { "WaitForSingleObjectEx", (SYSCALL)0, 0 },
+#endif
+
+#define osWaitForSingleObjectEx ((DWORD(WINAPI*)(HANDLE,DWORD, \
+ BOOL))aSyscall[62].pCurrent)
+
+#if SQLITE_OS_WINRT
+ { "SetFilePointerEx", (SYSCALL)SetFilePointerEx, 0 },
+#else
+ { "SetFilePointerEx", (SYSCALL)0, 0 },
+#endif
+
+#define osSetFilePointerEx ((BOOL(WINAPI*)(HANDLE,LARGE_INTEGER, \
+ PLARGE_INTEGER,DWORD))aSyscall[63].pCurrent)
+
+#if SQLITE_OS_WINRT
+ { "GetFileInformationByHandleEx", (SYSCALL)GetFileInformationByHandleEx, 0 },
+#else
+ { "GetFileInformationByHandleEx", (SYSCALL)0, 0 },
+#endif
+
+#define osGetFileInformationByHandleEx ((BOOL(WINAPI*)(HANDLE, \
+ FILE_INFO_BY_HANDLE_CLASS,LPVOID,DWORD))aSyscall[64].pCurrent)
+
+#if SQLITE_OS_WINRT && !defined(SQLITE_OMIT_WAL)
+ { "MapViewOfFileFromApp", (SYSCALL)MapViewOfFileFromApp, 0 },
+#else
+ { "MapViewOfFileFromApp", (SYSCALL)0, 0 },
+#endif
+
+#define osMapViewOfFileFromApp ((LPVOID(WINAPI*)(HANDLE,ULONG,ULONG64, \
+ SIZE_T))aSyscall[65].pCurrent)
+
+#if SQLITE_OS_WINRT
+ { "CreateFile2", (SYSCALL)CreateFile2, 0 },
+#else
+ { "CreateFile2", (SYSCALL)0, 0 },
+#endif
+
+#define osCreateFile2 ((HANDLE(WINAPI*)(LPCWSTR,DWORD,DWORD,DWORD, \
+ LPCREATEFILE2_EXTENDED_PARAMETERS))aSyscall[66].pCurrent)
+
+#if SQLITE_OS_WINRT && !defined(SQLITE_OMIT_LOAD_EXTENSION)
+ { "LoadPackagedLibrary", (SYSCALL)LoadPackagedLibrary, 0 },
+#else
+ { "LoadPackagedLibrary", (SYSCALL)0, 0 },
+#endif
+
+#define osLoadPackagedLibrary ((HMODULE(WINAPI*)(LPCWSTR, \
+ DWORD))aSyscall[67].pCurrent)
+
+#if SQLITE_OS_WINRT
+ { "GetTickCount64", (SYSCALL)GetTickCount64, 0 },
+#else
+ { "GetTickCount64", (SYSCALL)0, 0 },
+#endif
+
+#define osGetTickCount64 ((ULONGLONG(WINAPI*)(VOID))aSyscall[68].pCurrent)
+
+#if SQLITE_OS_WINRT
+ { "GetNativeSystemInfo", (SYSCALL)GetNativeSystemInfo, 0 },
+#else
+ { "GetNativeSystemInfo", (SYSCALL)0, 0 },
+#endif
+
+#define osGetNativeSystemInfo ((VOID(WINAPI*)( \
+ LPSYSTEM_INFO))aSyscall[69].pCurrent)
+
+#if defined(SQLITE_WIN32_HAS_ANSI)
+ { "OutputDebugStringA", (SYSCALL)OutputDebugStringA, 0 },
+#else
+ { "OutputDebugStringA", (SYSCALL)0, 0 },
+#endif
+
+#define osOutputDebugStringA ((VOID(WINAPI*)(LPCSTR))aSyscall[70].pCurrent)
+
+#if defined(SQLITE_WIN32_HAS_WIDE)
+ { "OutputDebugStringW", (SYSCALL)OutputDebugStringW, 0 },
+#else
+ { "OutputDebugStringW", (SYSCALL)0, 0 },
+#endif
+
+#define osOutputDebugStringW ((VOID(WINAPI*)(LPCWSTR))aSyscall[71].pCurrent)
+
+ { "GetProcessHeap", (SYSCALL)GetProcessHeap, 0 },
+
+#define osGetProcessHeap ((HANDLE(WINAPI*)(VOID))aSyscall[72].pCurrent)
+
+#if SQLITE_OS_WINRT && !defined(SQLITE_OMIT_WAL)
+ { "CreateFileMappingFromApp", (SYSCALL)CreateFileMappingFromApp, 0 },
+#else
+ { "CreateFileMappingFromApp", (SYSCALL)0, 0 },
+#endif
+
+#define osCreateFileMappingFromApp ((HANDLE(WINAPI*)(HANDLE, \
+ LPSECURITY_ATTRIBUTES,ULONG,ULONG64,LPCWSTR))aSyscall[73].pCurrent)
+
+}; /* End of the overrideable system calls */
+
+/*
+** This is the xSetSystemCall() method of sqlite3_vfs for all of the
+** "win32" VFSes. Return SQLITE_OK opon successfully updating the
+** system call pointer, or SQLITE_NOTFOUND if there is no configurable
+** system call named zName.
+*/
+static int winSetSystemCall(
+ sqlite3_vfs *pNotUsed, /* The VFS pointer. Not used */
+ const char *zName, /* Name of system call to override */
+ sqlite3_syscall_ptr pNewFunc /* Pointer to new system call value */
+){
+ unsigned int i;
+ int rc = SQLITE_NOTFOUND;
+
+ UNUSED_PARAMETER(pNotUsed);
+ if( zName==0 ){
+ /* If no zName is given, restore all system calls to their default
+ ** settings and return NULL
+ */
+ rc = SQLITE_OK;
+ for(i=0; i<sizeof(aSyscall)/sizeof(aSyscall[0]); i++){
+ if( aSyscall[i].pDefault ){
+ aSyscall[i].pCurrent = aSyscall[i].pDefault;
+ }
+ }
+ }else{
+ /* If zName is specified, operate on only the one system call
+ ** specified.
+ */
+ for(i=0; i<sizeof(aSyscall)/sizeof(aSyscall[0]); i++){
+ if( strcmp(zName, aSyscall[i].zName)==0 ){
+ if( aSyscall[i].pDefault==0 ){
+ aSyscall[i].pDefault = aSyscall[i].pCurrent;
+ }
+ rc = SQLITE_OK;
+ if( pNewFunc==0 ) pNewFunc = aSyscall[i].pDefault;
+ aSyscall[i].pCurrent = pNewFunc;
+ break;
+ }
+ }
+ }
+ return rc;
+}
+
+/*
+** Return the value of a system call. Return NULL if zName is not a
+** recognized system call name. NULL is also returned if the system call
+** is currently undefined.
+*/
+static sqlite3_syscall_ptr winGetSystemCall(
+ sqlite3_vfs *pNotUsed,
+ const char *zName
+){
+ unsigned int i;
+
+ UNUSED_PARAMETER(pNotUsed);
+ for(i=0; i<sizeof(aSyscall)/sizeof(aSyscall[0]); i++){
+ if( strcmp(zName, aSyscall[i].zName)==0 ) return aSyscall[i].pCurrent;
+ }
+ return 0;
+}
+
+/*
+** Return the name of the first system call after zName. If zName==NULL
+** then return the name of the first system call. Return NULL if zName
+** is the last system call or if zName is not the name of a valid
+** system call.
+*/
+static const char *winNextSystemCall(sqlite3_vfs *p, const char *zName){
+ int i = -1;
+
+ UNUSED_PARAMETER(p);
+ if( zName ){
+ for(i=0; i<ArraySize(aSyscall)-1; i++){
+ if( strcmp(zName, aSyscall[i].zName)==0 ) break;
+ }
+ }
+ for(i++; i<ArraySize(aSyscall); i++){
+ if( aSyscall[i].pCurrent!=0 ) return aSyscall[i].zName;
+ }
+ return 0;
+}
+
+/*
+** This function outputs the specified (ANSI) string to the Win32 debugger
+** (if available).
+*/
+
+SQLITE_API void sqlite3_win32_write_debug(const char *zBuf, int nBuf){
+ char zDbgBuf[SQLITE_WIN32_DBG_BUF_SIZE];
+ int nMin = MIN(nBuf, (SQLITE_WIN32_DBG_BUF_SIZE - 1)); /* may be negative. */
+ if( nMin<-1 ) nMin = -1; /* all negative values become -1. */
+ assert( nMin==-1 || nMin==0 || nMin<SQLITE_WIN32_DBG_BUF_SIZE );
+#if defined(SQLITE_WIN32_HAS_ANSI)
+ if( nMin>0 ){
+ memset(zDbgBuf, 0, SQLITE_WIN32_DBG_BUF_SIZE);
+ memcpy(zDbgBuf, zBuf, nMin);
+ osOutputDebugStringA(zDbgBuf);
+ }else{
+ osOutputDebugStringA(zBuf);
+ }
+#elif defined(SQLITE_WIN32_HAS_WIDE)
+ memset(zDbgBuf, 0, SQLITE_WIN32_DBG_BUF_SIZE);
+ if ( osMultiByteToWideChar(
+ osAreFileApisANSI() ? CP_ACP : CP_OEMCP, 0, zBuf,
+ nMin, (LPWSTR)zDbgBuf, SQLITE_WIN32_DBG_BUF_SIZE/sizeof(WCHAR))<=0 ){
+ return;
+ }
+ osOutputDebugStringW((LPCWSTR)zDbgBuf);
+#else
+ if( nMin>0 ){
+ memset(zDbgBuf, 0, SQLITE_WIN32_DBG_BUF_SIZE);
+ memcpy(zDbgBuf, zBuf, nMin);
+ fprintf(stderr, "%s", zDbgBuf);
+ }else{
+ fprintf(stderr, "%s", zBuf);
+ }
+#endif
+}
+
+/*
+** The following routine suspends the current thread for at least ms
+** milliseconds. This is equivalent to the Win32 Sleep() interface.
+*/
+#if SQLITE_OS_WINRT
+static HANDLE sleepObj = NULL;
+#endif
+
+SQLITE_API void sqlite3_win32_sleep(DWORD milliseconds){
+#if SQLITE_OS_WINRT
+ if ( sleepObj==NULL ){
+ sleepObj = osCreateEventExW(NULL, NULL, CREATE_EVENT_MANUAL_RESET,
+ SYNCHRONIZE);
+ }
+ assert( sleepObj!=NULL );
+ osWaitForSingleObjectEx(sleepObj, milliseconds, FALSE);
+#else
+ osSleep(milliseconds);
+#endif
+}
+
/*
** Return true (non-zero) if we are running under WinNT, Win2K, WinXP,
** or WinCE. Return false (zero) for Win95, Win98, or WinME.
@@ -31611,110 +31203,322 @@ static int sqlite3_os_type = 0;
** WinNT/2K/XP so that we will know whether or not we can safely call
** the LockFileEx() API.
*/
-#if SQLITE_OS_WINCE
+#if SQLITE_OS_WINCE || SQLITE_OS_WINRT
# define isNT() (1)
+#elif !defined(SQLITE_WIN32_HAS_WIDE)
+# define isNT() (0)
#else
static int isNT(void){
if( sqlite3_os_type==0 ){
- OSVERSIONINFO sInfo;
+ OSVERSIONINFOA sInfo;
sInfo.dwOSVersionInfoSize = sizeof(sInfo);
- GetVersionEx(&sInfo);
+ osGetVersionExA(&sInfo);
sqlite3_os_type = sInfo.dwPlatformId==VER_PLATFORM_WIN32_NT ? 2 : 1;
}
return sqlite3_os_type==2;
}
-#endif /* SQLITE_OS_WINCE */
+#endif
+
+#ifdef SQLITE_WIN32_MALLOC
+/*
+** Allocate nBytes of memory.
+*/
+static void *winMemMalloc(int nBytes){
+ HANDLE hHeap;
+ void *p;
+
+ winMemAssertMagic();
+ hHeap = winMemGetHeap();
+ assert( hHeap!=0 );
+ assert( hHeap!=INVALID_HANDLE_VALUE );
+#if !SQLITE_OS_WINRT && defined(SQLITE_WIN32_MALLOC_VALIDATE)
+ assert ( osHeapValidate(hHeap, SQLITE_WIN32_HEAP_FLAGS, NULL) );
+#endif
+ assert( nBytes>=0 );
+ p = osHeapAlloc(hHeap, SQLITE_WIN32_HEAP_FLAGS, (SIZE_T)nBytes);
+ if( !p ){
+ sqlite3_log(SQLITE_NOMEM, "failed to HeapAlloc %u bytes (%d), heap=%p",
+ nBytes, osGetLastError(), (void*)hHeap);
+ }
+ return p;
+}
+
+/*
+** Free memory.
+*/
+static void winMemFree(void *pPrior){
+ HANDLE hHeap;
+
+ winMemAssertMagic();
+ hHeap = winMemGetHeap();
+ assert( hHeap!=0 );
+ assert( hHeap!=INVALID_HANDLE_VALUE );
+#if !SQLITE_OS_WINRT && defined(SQLITE_WIN32_MALLOC_VALIDATE)
+ assert ( osHeapValidate(hHeap, SQLITE_WIN32_HEAP_FLAGS, pPrior) );
+#endif
+ if( !pPrior ) return; /* Passing NULL to HeapFree is undefined. */
+ if( !osHeapFree(hHeap, SQLITE_WIN32_HEAP_FLAGS, pPrior) ){
+ sqlite3_log(SQLITE_NOMEM, "failed to HeapFree block %p (%d), heap=%p",
+ pPrior, osGetLastError(), (void*)hHeap);
+ }
+}
+
+/*
+** Change the size of an existing memory allocation
+*/
+static void *winMemRealloc(void *pPrior, int nBytes){
+ HANDLE hHeap;
+ void *p;
+
+ winMemAssertMagic();
+ hHeap = winMemGetHeap();
+ assert( hHeap!=0 );
+ assert( hHeap!=INVALID_HANDLE_VALUE );
+#if !SQLITE_OS_WINRT && defined(SQLITE_WIN32_MALLOC_VALIDATE)
+ assert ( osHeapValidate(hHeap, SQLITE_WIN32_HEAP_FLAGS, pPrior) );
+#endif
+ assert( nBytes>=0 );
+ if( !pPrior ){
+ p = osHeapAlloc(hHeap, SQLITE_WIN32_HEAP_FLAGS, (SIZE_T)nBytes);
+ }else{
+ p = osHeapReAlloc(hHeap, SQLITE_WIN32_HEAP_FLAGS, pPrior, (SIZE_T)nBytes);
+ }
+ if( !p ){
+ sqlite3_log(SQLITE_NOMEM, "failed to %s %u bytes (%d), heap=%p",
+ pPrior ? "HeapReAlloc" : "HeapAlloc", nBytes, osGetLastError(),
+ (void*)hHeap);
+ }
+ return p;
+}
+
+/*
+** Return the size of an outstanding allocation, in bytes.
+*/
+static int winMemSize(void *p){
+ HANDLE hHeap;
+ SIZE_T n;
+
+ winMemAssertMagic();
+ hHeap = winMemGetHeap();
+ assert( hHeap!=0 );
+ assert( hHeap!=INVALID_HANDLE_VALUE );
+#if !SQLITE_OS_WINRT && defined(SQLITE_WIN32_MALLOC_VALIDATE)
+ assert ( osHeapValidate(hHeap, SQLITE_WIN32_HEAP_FLAGS, NULL) );
+#endif
+ if( !p ) return 0;
+ n = osHeapSize(hHeap, SQLITE_WIN32_HEAP_FLAGS, p);
+ if( n==(SIZE_T)-1 ){
+ sqlite3_log(SQLITE_NOMEM, "failed to HeapSize block %p (%d), heap=%p",
+ p, osGetLastError(), (void*)hHeap);
+ return 0;
+ }
+ return (int)n;
+}
+
+/*
+** Round up a request size to the next valid allocation size.
+*/
+static int winMemRoundup(int n){
+ return n;
+}
/*
-** Convert a UTF-8 string to microsoft unicode (UTF-16?).
+** Initialize this module.
+*/
+static int winMemInit(void *pAppData){
+ winMemData *pWinMemData = (winMemData *)pAppData;
+
+ if( !pWinMemData ) return SQLITE_ERROR;
+ assert( pWinMemData->magic==WINMEM_MAGIC );
+
+#if !SQLITE_OS_WINRT && SQLITE_WIN32_HEAP_CREATE
+ if( !pWinMemData->hHeap ){
+ pWinMemData->hHeap = osHeapCreate(SQLITE_WIN32_HEAP_FLAGS,
+ SQLITE_WIN32_HEAP_INIT_SIZE,
+ SQLITE_WIN32_HEAP_MAX_SIZE);
+ if( !pWinMemData->hHeap ){
+ sqlite3_log(SQLITE_NOMEM,
+ "failed to HeapCreate (%d), flags=%u, initSize=%u, maxSize=%u",
+ osGetLastError(), SQLITE_WIN32_HEAP_FLAGS,
+ SQLITE_WIN32_HEAP_INIT_SIZE, SQLITE_WIN32_HEAP_MAX_SIZE);
+ return SQLITE_NOMEM;
+ }
+ pWinMemData->bOwned = TRUE;
+ assert( pWinMemData->bOwned );
+ }
+#else
+ pWinMemData->hHeap = osGetProcessHeap();
+ if( !pWinMemData->hHeap ){
+ sqlite3_log(SQLITE_NOMEM,
+ "failed to GetProcessHeap (%d)", osGetLastError());
+ return SQLITE_NOMEM;
+ }
+ pWinMemData->bOwned = FALSE;
+ assert( !pWinMemData->bOwned );
+#endif
+ assert( pWinMemData->hHeap!=0 );
+ assert( pWinMemData->hHeap!=INVALID_HANDLE_VALUE );
+#if !SQLITE_OS_WINRT && defined(SQLITE_WIN32_MALLOC_VALIDATE)
+ assert( osHeapValidate(pWinMemData->hHeap, SQLITE_WIN32_HEAP_FLAGS, NULL) );
+#endif
+ return SQLITE_OK;
+}
+
+/*
+** Deinitialize this module.
+*/
+static void winMemShutdown(void *pAppData){
+ winMemData *pWinMemData = (winMemData *)pAppData;
+
+ if( !pWinMemData ) return;
+ if( pWinMemData->hHeap ){
+ assert( pWinMemData->hHeap!=INVALID_HANDLE_VALUE );
+#if !SQLITE_OS_WINRT && defined(SQLITE_WIN32_MALLOC_VALIDATE)
+ assert( osHeapValidate(pWinMemData->hHeap, SQLITE_WIN32_HEAP_FLAGS, NULL) );
+#endif
+ if( pWinMemData->bOwned ){
+ if( !osHeapDestroy(pWinMemData->hHeap) ){
+ sqlite3_log(SQLITE_NOMEM, "failed to HeapDestroy (%d), heap=%p",
+ osGetLastError(), (void*)pWinMemData->hHeap);
+ }
+ pWinMemData->bOwned = FALSE;
+ }
+ pWinMemData->hHeap = NULL;
+ }
+}
+
+/*
+** Populate the low-level memory allocation function pointers in
+** sqlite3GlobalConfig.m with pointers to the routines in this file. The
+** arguments specify the block of memory to manage.
+**
+** This routine is only called by sqlite3_config(), and therefore
+** is not required to be threadsafe (it is not).
+*/
+SQLITE_PRIVATE const sqlite3_mem_methods *sqlite3MemGetWin32(void){
+ static const sqlite3_mem_methods winMemMethods = {
+ winMemMalloc,
+ winMemFree,
+ winMemRealloc,
+ winMemSize,
+ winMemRoundup,
+ winMemInit,
+ winMemShutdown,
+ &win_mem_data
+ };
+ return &winMemMethods;
+}
+
+SQLITE_PRIVATE void sqlite3MemSetDefault(void){
+ sqlite3_config(SQLITE_CONFIG_MALLOC, sqlite3MemGetWin32());
+}
+#endif /* SQLITE_WIN32_MALLOC */
+
+/*
+** Convert a UTF-8 string to Microsoft Unicode (UTF-16?).
**
** Space to hold the returned string is obtained from malloc.
*/
-static WCHAR *utf8ToUnicode(const char *zFilename){
+static LPWSTR utf8ToUnicode(const char *zFilename){
int nChar;
- WCHAR *zWideFilename;
+ LPWSTR zWideFilename;
- nChar = MultiByteToWideChar(CP_UTF8, 0, zFilename, -1, NULL, 0);
- zWideFilename = malloc( nChar*sizeof(zWideFilename[0]) );
+ nChar = osMultiByteToWideChar(CP_UTF8, 0, zFilename, -1, NULL, 0);
+ if( nChar==0 ){
+ return 0;
+ }
+ zWideFilename = sqlite3MallocZero( nChar*sizeof(zWideFilename[0]) );
if( zWideFilename==0 ){
return 0;
}
- nChar = MultiByteToWideChar(CP_UTF8, 0, zFilename, -1, zWideFilename, nChar);
+ nChar = osMultiByteToWideChar(CP_UTF8, 0, zFilename, -1, zWideFilename,
+ nChar);
if( nChar==0 ){
- free(zWideFilename);
+ sqlite3_free(zWideFilename);
zWideFilename = 0;
}
return zWideFilename;
}
/*
-** Convert microsoft unicode to UTF-8. Space to hold the returned string is
-** obtained from malloc().
+** Convert Microsoft Unicode to UTF-8. Space to hold the returned string is
+** obtained from sqlite3_malloc().
*/
-static char *unicodeToUtf8(const WCHAR *zWideFilename){
+static char *unicodeToUtf8(LPCWSTR zWideFilename){
int nByte;
char *zFilename;
- nByte = WideCharToMultiByte(CP_UTF8, 0, zWideFilename, -1, 0, 0, 0, 0);
- zFilename = malloc( nByte );
+ nByte = osWideCharToMultiByte(CP_UTF8, 0, zWideFilename, -1, 0, 0, 0, 0);
+ if( nByte == 0 ){
+ return 0;
+ }
+ zFilename = sqlite3MallocZero( nByte );
if( zFilename==0 ){
return 0;
}
- nByte = WideCharToMultiByte(CP_UTF8, 0, zWideFilename, -1, zFilename, nByte,
- 0, 0);
+ nByte = osWideCharToMultiByte(CP_UTF8, 0, zWideFilename, -1, zFilename, nByte,
+ 0, 0);
if( nByte == 0 ){
- free(zFilename);
+ sqlite3_free(zFilename);
zFilename = 0;
}
return zFilename;
}
/*
-** Convert an ansi string to microsoft unicode, based on the
+** Convert an ANSI string to Microsoft Unicode, based on the
** current codepage settings for file apis.
**
** Space to hold the returned string is obtained
-** from malloc.
+** from sqlite3_malloc.
*/
-static WCHAR *mbcsToUnicode(const char *zFilename){
+static LPWSTR mbcsToUnicode(const char *zFilename){
int nByte;
- WCHAR *zMbcsFilename;
- int codepage = AreFileApisANSI() ? CP_ACP : CP_OEMCP;
+ LPWSTR zMbcsFilename;
+ int codepage = osAreFileApisANSI() ? CP_ACP : CP_OEMCP;
- nByte = MultiByteToWideChar(codepage, 0, zFilename, -1, NULL,0)*sizeof(WCHAR);
- zMbcsFilename = malloc( nByte*sizeof(zMbcsFilename[0]) );
+ nByte = osMultiByteToWideChar(codepage, 0, zFilename, -1, NULL,
+ 0)*sizeof(WCHAR);
+ if( nByte==0 ){
+ return 0;
+ }
+ zMbcsFilename = sqlite3MallocZero( nByte*sizeof(zMbcsFilename[0]) );
if( zMbcsFilename==0 ){
return 0;
}
- nByte = MultiByteToWideChar(codepage, 0, zFilename, -1, zMbcsFilename, nByte);
+ nByte = osMultiByteToWideChar(codepage, 0, zFilename, -1, zMbcsFilename,
+ nByte);
if( nByte==0 ){
- free(zMbcsFilename);
+ sqlite3_free(zMbcsFilename);
zMbcsFilename = 0;
}
return zMbcsFilename;
}
/*
-** Convert microsoft unicode to multibyte character string, based on the
-** user's Ansi codepage.
+** Convert Microsoft Unicode to multi-byte character string, based on the
+** user's ANSI codepage.
**
** Space to hold the returned string is obtained from
-** malloc().
+** sqlite3_malloc().
*/
-static char *unicodeToMbcs(const WCHAR *zWideFilename){
+static char *unicodeToMbcs(LPCWSTR zWideFilename){
int nByte;
char *zFilename;
- int codepage = AreFileApisANSI() ? CP_ACP : CP_OEMCP;
+ int codepage = osAreFileApisANSI() ? CP_ACP : CP_OEMCP;
- nByte = WideCharToMultiByte(codepage, 0, zWideFilename, -1, 0, 0, 0, 0);
- zFilename = malloc( nByte );
+ nByte = osWideCharToMultiByte(codepage, 0, zWideFilename, -1, 0, 0, 0, 0);
+ if( nByte == 0 ){
+ return 0;
+ }
+ zFilename = sqlite3MallocZero( nByte );
if( zFilename==0 ){
return 0;
}
- nByte = WideCharToMultiByte(codepage, 0, zWideFilename, -1, zFilename, nByte,
- 0, 0);
+ nByte = osWideCharToMultiByte(codepage, 0, zWideFilename, -1, zFilename,
+ nByte, 0, 0);
if( nByte == 0 ){
- free(zFilename);
+ sqlite3_free(zFilename);
zFilename = 0;
}
return zFilename;
@@ -31722,97 +31526,151 @@ static char *unicodeToMbcs(const WCHAR *zWideFilename){
/*
** Convert multibyte character string to UTF-8. Space to hold the
-** returned string is obtained from malloc().
+** returned string is obtained from sqlite3_malloc().
*/
SQLITE_API char *sqlite3_win32_mbcs_to_utf8(const char *zFilename){
char *zFilenameUtf8;
- WCHAR *zTmpWide;
+ LPWSTR zTmpWide;
zTmpWide = mbcsToUnicode(zFilename);
if( zTmpWide==0 ){
return 0;
}
zFilenameUtf8 = unicodeToUtf8(zTmpWide);
- free(zTmpWide);
+ sqlite3_free(zTmpWide);
return zFilenameUtf8;
}
/*
** Convert UTF-8 to multibyte character string. Space to hold the
-** returned string is obtained from malloc().
+** returned string is obtained from sqlite3_malloc().
*/
SQLITE_API char *sqlite3_win32_utf8_to_mbcs(const char *zFilename){
char *zFilenameMbcs;
- WCHAR *zTmpWide;
+ LPWSTR zTmpWide;
zTmpWide = utf8ToUnicode(zFilename);
if( zTmpWide==0 ){
return 0;
}
zFilenameMbcs = unicodeToMbcs(zTmpWide);
- free(zTmpWide);
+ sqlite3_free(zTmpWide);
return zFilenameMbcs;
}
+/*
+** This function sets the data directory or the temporary directory based on
+** the provided arguments. The type argument must be 1 in order to set the
+** data directory or 2 in order to set the temporary directory. The zValue
+** argument is the name of the directory to use. The return value will be
+** SQLITE_OK if successful.
+*/
+SQLITE_API int sqlite3_win32_set_directory(DWORD type, LPCWSTR zValue){
+ char **ppDirectory = 0;
+#ifndef SQLITE_OMIT_AUTOINIT
+ int rc = sqlite3_initialize();
+ if( rc ) return rc;
+#endif
+ if( type==SQLITE_WIN32_DATA_DIRECTORY_TYPE ){
+ ppDirectory = &sqlite3_data_directory;
+ }else if( type==SQLITE_WIN32_TEMP_DIRECTORY_TYPE ){
+ ppDirectory = &sqlite3_temp_directory;
+ }
+ assert( !ppDirectory || type==SQLITE_WIN32_DATA_DIRECTORY_TYPE
+ || type==SQLITE_WIN32_TEMP_DIRECTORY_TYPE
+ );
+ assert( !ppDirectory || sqlite3MemdebugHasType(*ppDirectory, MEMTYPE_HEAP) );
+ if( ppDirectory ){
+ char *zValueUtf8 = 0;
+ if( zValue && zValue[0] ){
+ zValueUtf8 = unicodeToUtf8(zValue);
+ if ( zValueUtf8==0 ){
+ return SQLITE_NOMEM;
+ }
+ }
+ sqlite3_free(*ppDirectory);
+ *ppDirectory = zValueUtf8;
+ return SQLITE_OK;
+ }
+ return SQLITE_ERROR;
+}
/*
** The return value of getLastErrorMsg
** is zero if the error message fits in the buffer, or non-zero
** otherwise (if the message was truncated).
*/
-static int getLastErrorMsg(int nBuf, char *zBuf){
+static int getLastErrorMsg(DWORD lastErrno, int nBuf, char *zBuf){
/* FormatMessage returns 0 on failure. Otherwise it
** returns the number of TCHARs written to the output
** buffer, excluding the terminating null char.
*/
- DWORD error = GetLastError();
DWORD dwLen = 0;
char *zOut = 0;
if( isNT() ){
- WCHAR *zTempWide = NULL;
- dwLen = FormatMessageW(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
- NULL,
- error,
- 0,
- (LPWSTR) &zTempWide,
- 0,
- 0);
+#if SQLITE_OS_WINRT
+ WCHAR zTempWide[MAX_PATH+1]; /* NOTE: Somewhat arbitrary. */
+ dwLen = osFormatMessageW(FORMAT_MESSAGE_FROM_SYSTEM |
+ FORMAT_MESSAGE_IGNORE_INSERTS,
+ NULL,
+ lastErrno,
+ 0,
+ zTempWide,
+ MAX_PATH,
+ 0);
+#else
+ LPWSTR zTempWide = NULL;
+ dwLen = osFormatMessageW(FORMAT_MESSAGE_ALLOCATE_BUFFER |
+ FORMAT_MESSAGE_FROM_SYSTEM |
+ FORMAT_MESSAGE_IGNORE_INSERTS,
+ NULL,
+ lastErrno,
+ 0,
+ (LPWSTR) &zTempWide,
+ 0,
+ 0);
+#endif
if( dwLen > 0 ){
/* allocate a buffer and convert to UTF8 */
+ sqlite3BeginBenignMalloc();
zOut = unicodeToUtf8(zTempWide);
+ sqlite3EndBenignMalloc();
+#if !SQLITE_OS_WINRT
/* free the system buffer allocated by FormatMessage */
- LocalFree(zTempWide);
+ osLocalFree(zTempWide);
+#endif
}
-/* isNT() is 1 if SQLITE_OS_WINCE==1, so this else is never executed.
-** Since the ASCII version of these Windows API do not exist for WINCE,
-** it's important to not reference them for WINCE builds.
-*/
-#if SQLITE_OS_WINCE==0
- }else{
+ }
+#ifdef SQLITE_WIN32_HAS_ANSI
+ else{
char *zTemp = NULL;
- dwLen = FormatMessageA(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
- NULL,
- error,
- 0,
- (LPSTR) &zTemp,
- 0,
- 0);
+ dwLen = osFormatMessageA(FORMAT_MESSAGE_ALLOCATE_BUFFER |
+ FORMAT_MESSAGE_FROM_SYSTEM |
+ FORMAT_MESSAGE_IGNORE_INSERTS,
+ NULL,
+ lastErrno,
+ 0,
+ (LPSTR) &zTemp,
+ 0,
+ 0);
if( dwLen > 0 ){
/* allocate a buffer and convert to UTF8 */
+ sqlite3BeginBenignMalloc();
zOut = sqlite3_win32_mbcs_to_utf8(zTemp);
+ sqlite3EndBenignMalloc();
/* free the system buffer allocated by FormatMessage */
- LocalFree(zTemp);
+ osLocalFree(zTemp);
}
-#endif
}
+#endif
if( 0 == dwLen ){
- sqlite3_snprintf(nBuf, zBuf, "OsError 0x%x (%u)", error, error);
+ sqlite3_snprintf(nBuf, zBuf, "OsError 0x%x (%u)", lastErrno, lastErrno);
}else{
/* copy a maximum of nBuf chars to output buffer */
sqlite3_snprintf(nBuf, zBuf, "%s", zOut);
/* free the UTF8 buffer */
- free(zOut);
+ sqlite3_free(zOut);
}
return 0;
}
@@ -31830,41 +31688,96 @@ static int getLastErrorMsg(int nBuf, char *zBuf){
** The first argument passed to the macro should be the error code that
** will be returned to SQLite (e.g. SQLITE_IOERR_DELETE, SQLITE_CANTOPEN).
** The two subsequent arguments should be the name of the OS function that
-** failed and the the associated file-system path, if any.
+** failed and the associated file-system path, if any.
*/
-#define winLogError(a,b,c) winLogErrorAtLine(a,b,c,__LINE__)
+#define winLogError(a,b,c,d) winLogErrorAtLine(a,b,c,d,__LINE__)
static int winLogErrorAtLine(
int errcode, /* SQLite error code */
+ DWORD lastErrno, /* Win32 last error */
const char *zFunc, /* Name of OS function that failed */
const char *zPath, /* File path associated with error */
int iLine /* Source line number where error occurred */
){
char zMsg[500]; /* Human readable error text */
int i; /* Loop counter */
- DWORD iErrno = GetLastError(); /* Error code */
zMsg[0] = 0;
- getLastErrorMsg(sizeof(zMsg), zMsg);
+ getLastErrorMsg(lastErrno, sizeof(zMsg), zMsg);
assert( errcode!=SQLITE_OK );
if( zPath==0 ) zPath = "";
for(i=0; zMsg[i] && zMsg[i]!='\r' && zMsg[i]!='\n'; i++){}
zMsg[i] = 0;
sqlite3_log(errcode,
"os_win.c:%d: (%d) %s(%s) - %s",
- iLine, iErrno, zFunc, zPath, zMsg
+ iLine, lastErrno, zFunc, zPath, zMsg
);
return errcode;
}
+/*
+** The number of times that a ReadFile(), WriteFile(), and DeleteFile()
+** will be retried following a locking error - probably caused by
+** antivirus software. Also the initial delay before the first retry.
+** The delay increases linearly with each retry.
+*/
+#ifndef SQLITE_WIN32_IOERR_RETRY
+# define SQLITE_WIN32_IOERR_RETRY 10
+#endif
+#ifndef SQLITE_WIN32_IOERR_RETRY_DELAY
+# define SQLITE_WIN32_IOERR_RETRY_DELAY 25
+#endif
+static int win32IoerrRetry = SQLITE_WIN32_IOERR_RETRY;
+static int win32IoerrRetryDelay = SQLITE_WIN32_IOERR_RETRY_DELAY;
+
+/*
+** If a ReadFile() or WriteFile() error occurs, invoke this routine
+** to see if it should be retried. Return TRUE to retry. Return FALSE
+** to give up with an error.
+*/
+static int retryIoerr(int *pnRetry, DWORD *pError){
+ DWORD e = osGetLastError();
+ if( *pnRetry>=win32IoerrRetry ){
+ if( pError ){
+ *pError = e;
+ }
+ return 0;
+ }
+ if( e==ERROR_ACCESS_DENIED ||
+ e==ERROR_LOCK_VIOLATION ||
+ e==ERROR_SHARING_VIOLATION ){
+ sqlite3_win32_sleep(win32IoerrRetryDelay*(1+*pnRetry));
+ ++*pnRetry;
+ return 1;
+ }
+ if( pError ){
+ *pError = e;
+ }
+ return 0;
+}
+
+/*
+** Log a I/O error retry episode.
+*/
+static void logIoerr(int nRetry){
+ if( nRetry ){
+ sqlite3_log(SQLITE_IOERR,
+ "delayed %dms for lock/sharing conflict",
+ win32IoerrRetryDelay*nRetry*(nRetry+1)/2
+ );
+ }
+}
+
#if SQLITE_OS_WINCE
/*************************************************************************
** This section contains code for WinCE only.
*/
+#if !defined(SQLITE_MSVC_LOCALTIME_API) || !SQLITE_MSVC_LOCALTIME_API
/*
-** WindowsCE does not have a localtime() function. So create a
-** substitute.
+** The MSVC CRT on Windows CE may not have a localtime() function. So
+** create a substitute.
*/
+/* #include <time.h> */
struct tm *__cdecl localtime(const time_t *t)
{
static struct tm y;
@@ -31875,8 +31788,8 @@ struct tm *__cdecl localtime(const time_t *t)
t64 = (t64 + 11644473600)*10000000;
uTm.dwLowDateTime = (DWORD)(t64 & 0xFFFFFFFF);
uTm.dwHighDateTime= (DWORD)(t64 >> 32);
- FileTimeToLocalFileTime(&uTm,&lTm);
- FileTimeToSystemTime(&lTm,&pTm);
+ osFileTimeToLocalFileTime(&uTm,&lTm);
+ osFileTimeToSystemTime(&lTm,&pTm);
y.tm_year = pTm.wYear - 1900;
y.tm_mon = pTm.wMonth - 1;
y.tm_wday = pTm.wDayOfWeek;
@@ -31886,13 +31799,7 @@ struct tm *__cdecl localtime(const time_t *t)
y.tm_sec = pTm.wSecond;
return &y;
}
-
-/* This will never be called, but defined to make the code compile */
-#define GetTempPathA(a,b)
-
-#define LockFile(a,b,c,d,e) winceLockFile(&a, b, c, d, e)
-#define UnlockFile(a,b,c,d,e) winceUnlockFile(&a, b, c, d, e)
-#define LockFileEx(a,b,c,d,e,f) winceLockFileEx(&a, b, c, d, e, f)
+#endif
#define HANDLE_TO_WINFILE(a) (winFile*)&((char*)a)[-(int)offsetof(winFile,h)]
@@ -31902,7 +31809,7 @@ struct tm *__cdecl localtime(const time_t *t)
static void winceMutexAcquire(HANDLE h){
DWORD dwErr;
do {
- dwErr = WaitForSingleObject(h, INFINITE);
+ dwErr = osWaitForSingleObject(h, INFINITE);
} while (dwErr != WAIT_OBJECT_0 && dwErr != WAIT_ABANDONED);
}
/*
@@ -31914,28 +31821,37 @@ static void winceMutexAcquire(HANDLE h){
** Create the mutex and shared memory used for locking in the file
** descriptor pFile
*/
-static BOOL winceCreateLock(const char *zFilename, winFile *pFile){
- WCHAR *zTok;
- WCHAR *zName = utf8ToUnicode(zFilename);
+static int winceCreateLock(const char *zFilename, winFile *pFile){
+ LPWSTR zTok;
+ LPWSTR zName;
+ DWORD lastErrno;
+ BOOL bLogged = FALSE;
BOOL bInit = TRUE;
+ zName = utf8ToUnicode(zFilename);
+ if( zName==0 ){
+ /* out of memory */
+ return SQLITE_IOERR_NOMEM;
+ }
+
/* Initialize the local lockdata */
- ZeroMemory(&pFile->local, sizeof(pFile->local));
+ memset(&pFile->local, 0, sizeof(pFile->local));
/* Replace the backslashes from the filename and lowercase it
** to derive a mutex name. */
- zTok = CharLowerW(zName);
+ zTok = osCharLowerW(zName);
for (;*zTok;zTok++){
if (*zTok == '\\') *zTok = '_';
}
/* Create/open the named mutex */
- pFile->hMutex = CreateMutexW(NULL, FALSE, zName);
+ pFile->hMutex = osCreateMutexW(NULL, FALSE, zName);
if (!pFile->hMutex){
- pFile->lastErrno = GetLastError();
- winLogError(SQLITE_ERROR, "winceCreateLock1", zFilename);
- free(zName);
- return FALSE;
+ pFile->lastErrno = osGetLastError();
+ winLogError(SQLITE_IOERR, pFile->lastErrno,
+ "winceCreateLock1", zFilename);
+ sqlite3_free(zName);
+ return SQLITE_IOERR;
}
/* Acquire the mutex before continuing */
@@ -31945,47 +31861,56 @@ static BOOL winceCreateLock(const char *zFilename, winFile *pFile){
** case-sensitive, take advantage of that by uppercasing the mutex name
** and using that as the shared filemapping name.
*/
- CharUpperW(zName);
- pFile->hShared = CreateFileMappingW(INVALID_HANDLE_VALUE, NULL,
- PAGE_READWRITE, 0, sizeof(winceLock),
- zName);
+ osCharUpperW(zName);
+ pFile->hShared = osCreateFileMappingW(INVALID_HANDLE_VALUE, NULL,
+ PAGE_READWRITE, 0, sizeof(winceLock),
+ zName);
/* Set a flag that indicates we're the first to create the memory so it
** must be zero-initialized */
- if (GetLastError() == ERROR_ALREADY_EXISTS){
+ lastErrno = osGetLastError();
+ if (lastErrno == ERROR_ALREADY_EXISTS){
bInit = FALSE;
}
- free(zName);
+ sqlite3_free(zName);
/* If we succeeded in making the shared memory handle, map it. */
- if (pFile->hShared){
- pFile->shared = (winceLock*)MapViewOfFile(pFile->hShared,
+ if( pFile->hShared ){
+ pFile->shared = (winceLock*)osMapViewOfFile(pFile->hShared,
FILE_MAP_READ|FILE_MAP_WRITE, 0, 0, sizeof(winceLock));
/* If mapping failed, close the shared memory handle and erase it */
- if (!pFile->shared){
- pFile->lastErrno = GetLastError();
- winLogError(SQLITE_ERROR, "winceCreateLock2", zFilename);
- CloseHandle(pFile->hShared);
+ if( !pFile->shared ){
+ pFile->lastErrno = osGetLastError();
+ winLogError(SQLITE_IOERR, pFile->lastErrno,
+ "winceCreateLock2", zFilename);
+ bLogged = TRUE;
+ osCloseHandle(pFile->hShared);
pFile->hShared = NULL;
}
}
/* If shared memory could not be created, then close the mutex and fail */
- if (pFile->hShared == NULL){
+ if( pFile->hShared==NULL ){
+ if( !bLogged ){
+ pFile->lastErrno = lastErrno;
+ winLogError(SQLITE_IOERR, pFile->lastErrno,
+ "winceCreateLock3", zFilename);
+ bLogged = TRUE;
+ }
winceMutexRelease(pFile->hMutex);
- CloseHandle(pFile->hMutex);
+ osCloseHandle(pFile->hMutex);
pFile->hMutex = NULL;
- return FALSE;
+ return SQLITE_IOERR;
}
/* Initialize the shared memory if we're supposed to */
- if (bInit) {
- ZeroMemory(pFile->shared, sizeof(winceLock));
+ if( bInit ){
+ memset(pFile->shared, 0, sizeof(winceLock));
}
winceMutexRelease(pFile->hMutex);
- return TRUE;
+ return SQLITE_OK;
}
/*
@@ -32012,21 +31937,21 @@ static void winceDestroyLock(winFile *pFile){
}
/* De-reference and close our copy of the shared memory handle */
- UnmapViewOfFile(pFile->shared);
- CloseHandle(pFile->hShared);
+ osUnmapViewOfFile(pFile->shared);
+ osCloseHandle(pFile->hShared);
/* Done with the mutex */
winceMutexRelease(pFile->hMutex);
- CloseHandle(pFile->hMutex);
+ osCloseHandle(pFile->hMutex);
pFile->hMutex = NULL;
}
}
/*
-** An implementation of the LockFile() API of windows for wince
+** An implementation of the LockFile() API of Windows for CE
*/
static BOOL winceLockFile(
- HANDLE *phFile,
+ LPHANDLE phFile,
DWORD dwFileOffsetLow,
DWORD dwFileOffsetHigh,
DWORD nNumberOfBytesToLockLow,
@@ -32064,7 +31989,8 @@ static BOOL winceLockFile(
}
/* Want a pending lock? */
- else if (dwFileOffsetLow == (DWORD)PENDING_BYTE && nNumberOfBytesToLockLow == 1){
+ else if (dwFileOffsetLow == (DWORD)PENDING_BYTE
+ && nNumberOfBytesToLockLow == 1){
/* If no pending lock has been acquired, then acquire it */
if (pFile->shared->bPending == 0) {
pFile->shared->bPending = TRUE;
@@ -32074,7 +32000,8 @@ static BOOL winceLockFile(
}
/* Want a reserved lock? */
- else if (dwFileOffsetLow == (DWORD)RESERVED_BYTE && nNumberOfBytesToLockLow == 1){
+ else if (dwFileOffsetLow == (DWORD)RESERVED_BYTE
+ && nNumberOfBytesToLockLow == 1){
if (pFile->shared->bReserved == 0) {
pFile->shared->bReserved = TRUE;
pFile->local.bReserved = TRUE;
@@ -32087,10 +32014,10 @@ static BOOL winceLockFile(
}
/*
-** An implementation of the UnlockFile API of windows for wince
+** An implementation of the UnlockFile API of Windows for CE
*/
static BOOL winceUnlockFile(
- HANDLE *phFile,
+ LPHANDLE phFile,
DWORD dwFileOffsetLow,
DWORD dwFileOffsetHigh,
DWORD nNumberOfBytesToUnlockLow,
@@ -32117,7 +32044,8 @@ static BOOL winceUnlockFile(
/* Did we just have a reader lock? */
else if (pFile->local.nReaders){
- assert(nNumberOfBytesToUnlockLow == (DWORD)SHARED_SIZE || nNumberOfBytesToUnlockLow == 1);
+ assert(nNumberOfBytesToUnlockLow == (DWORD)SHARED_SIZE
+ || nNumberOfBytesToUnlockLow == 1);
pFile->local.nReaders --;
if (pFile->local.nReaders == 0)
{
@@ -32128,7 +32056,8 @@ static BOOL winceUnlockFile(
}
/* Releasing a pending lock */
- else if (dwFileOffsetLow == (DWORD)PENDING_BYTE && nNumberOfBytesToUnlockLow == 1){
+ else if (dwFileOffsetLow == (DWORD)PENDING_BYTE
+ && nNumberOfBytesToUnlockLow == 1){
if (pFile->local.bPending){
pFile->local.bPending = FALSE;
pFile->shared->bPending = FALSE;
@@ -32136,7 +32065,8 @@ static BOOL winceUnlockFile(
}
}
/* Releasing a reserved lock */
- else if (dwFileOffsetLow == (DWORD)RESERVED_BYTE && nNumberOfBytesToUnlockLow == 1){
+ else if (dwFileOffsetLow == (DWORD)RESERVED_BYTE
+ && nNumberOfBytesToUnlockLow == 1){
if (pFile->local.bReserved) {
pFile->local.bReserved = FALSE;
pFile->shared->bReserved = FALSE;
@@ -32147,34 +32077,73 @@ static BOOL winceUnlockFile(
winceMutexRelease(pFile->hMutex);
return bReturn;
}
+/*
+** End of the special code for wince
+*****************************************************************************/
+#endif /* SQLITE_OS_WINCE */
/*
-** An implementation of the LockFileEx() API of windows for wince
+** Lock a file region.
*/
-static BOOL winceLockFileEx(
- HANDLE *phFile,
- DWORD dwFlags,
- DWORD dwReserved,
- DWORD nNumberOfBytesToLockLow,
- DWORD nNumberOfBytesToLockHigh,
- LPOVERLAPPED lpOverlapped
+static BOOL winLockFile(
+ LPHANDLE phFile,
+ DWORD flags,
+ DWORD offsetLow,
+ DWORD offsetHigh,
+ DWORD numBytesLow,
+ DWORD numBytesHigh
){
- UNUSED_PARAMETER(dwReserved);
- UNUSED_PARAMETER(nNumberOfBytesToLockHigh);
-
- /* If the caller wants a shared read lock, forward this call
- ** to winceLockFile */
- if (lpOverlapped->Offset == (DWORD)SHARED_FIRST &&
- dwFlags == 1 &&
- nNumberOfBytesToLockLow == (DWORD)SHARED_SIZE){
- return winceLockFile(phFile, SHARED_FIRST, 0, 1, 0);
+#if SQLITE_OS_WINCE
+ /*
+ ** NOTE: Windows CE is handled differently here due its lack of the Win32
+ ** API LockFile.
+ */
+ return winceLockFile(phFile, offsetLow, offsetHigh,
+ numBytesLow, numBytesHigh);
+#else
+ if( isNT() ){
+ OVERLAPPED ovlp;
+ memset(&ovlp, 0, sizeof(OVERLAPPED));
+ ovlp.Offset = offsetLow;
+ ovlp.OffsetHigh = offsetHigh;
+ return osLockFileEx(*phFile, flags, 0, numBytesLow, numBytesHigh, &ovlp);
+ }else{
+ return osLockFile(*phFile, offsetLow, offsetHigh, numBytesLow,
+ numBytesHigh);
}
- return FALSE;
+#endif
}
+
/*
-** End of the special code for wince
-*****************************************************************************/
-#endif /* SQLITE_OS_WINCE */
+** Unlock a file region.
+ */
+static BOOL winUnlockFile(
+ LPHANDLE phFile,
+ DWORD offsetLow,
+ DWORD offsetHigh,
+ DWORD numBytesLow,
+ DWORD numBytesHigh
+){
+#if SQLITE_OS_WINCE
+ /*
+ ** NOTE: Windows CE is handled differently here due its lack of the Win32
+ ** API UnlockFile.
+ */
+ return winceUnlockFile(phFile, offsetLow, offsetHigh,
+ numBytesLow, numBytesHigh);
+#else
+ if( isNT() ){
+ OVERLAPPED ovlp;
+ memset(&ovlp, 0, sizeof(OVERLAPPED));
+ ovlp.Offset = offsetLow;
+ ovlp.OffsetHigh = offsetHigh;
+ return osUnlockFileEx(*phFile, 0, numBytesLow, numBytesHigh, &ovlp);
+ }else{
+ return osUnlockFile(*phFile, offsetLow, offsetHigh, numBytesLow,
+ numBytesHigh);
+ }
+#endif
+}
/*****************************************************************************
** The next group of routines implement the I/O methods specified
@@ -32182,7 +32151,7 @@ static BOOL winceLockFileEx(
******************************************************************************/
/*
-** Some microsoft compilers lack this definition.
+** Some Microsoft compilers lack this definition.
*/
#ifndef INVALID_SET_FILE_POINTER
# define INVALID_SET_FILE_POINTER ((DWORD)-1)
@@ -32194,9 +32163,11 @@ static BOOL winceLockFileEx(
** Otherwise, set pFile->lastErrno and return non-zero.
*/
static int seekWinFile(winFile *pFile, sqlite3_int64 iOffset){
+#if !SQLITE_OS_WINRT
LONG upperBits; /* Most sig. 32 bits of new offset */
LONG lowerBits; /* Least sig. 32 bits of new offset */
DWORD dwRet; /* Value returned by SetFilePointer() */
+ DWORD lastErrno; /* Value returned by GetLastError() */
upperBits = (LONG)((iOffset>>32) & 0x7fffffff);
lowerBits = (LONG)(iOffset & 0xffffffff);
@@ -32205,24 +32176,47 @@ static int seekWinFile(winFile *pFile, sqlite3_int64 iOffset){
** containing the lower 32-bits of the new file-offset. Or, if it fails,
** it returns INVALID_SET_FILE_POINTER. However according to MSDN,
** INVALID_SET_FILE_POINTER may also be a valid new offset. So to determine
- ** whether an error has actually occured, it is also necessary to call
+ ** whether an error has actually occurred, it is also necessary to call
** GetLastError().
*/
- dwRet = SetFilePointer(pFile->h, lowerBits, &upperBits, FILE_BEGIN);
- if( (dwRet==INVALID_SET_FILE_POINTER && GetLastError()!=NO_ERROR) ){
- pFile->lastErrno = GetLastError();
- winLogError(SQLITE_IOERR_SEEK, "seekWinFile", pFile->zPath);
+ dwRet = osSetFilePointer(pFile->h, lowerBits, &upperBits, FILE_BEGIN);
+
+ if( (dwRet==INVALID_SET_FILE_POINTER
+ && ((lastErrno = osGetLastError())!=NO_ERROR)) ){
+ pFile->lastErrno = lastErrno;
+ winLogError(SQLITE_IOERR_SEEK, pFile->lastErrno,
+ "seekWinFile", pFile->zPath);
+ return 1;
+ }
+
+ return 0;
+#else
+ /*
+ ** Same as above, except that this implementation works for WinRT.
+ */
+
+ LARGE_INTEGER x; /* The new offset */
+ BOOL bRet; /* Value returned by SetFilePointerEx() */
+
+ x.QuadPart = iOffset;
+ bRet = osSetFilePointerEx(pFile->h, x, 0, FILE_BEGIN);
+
+ if(!bRet){
+ pFile->lastErrno = osGetLastError();
+ winLogError(SQLITE_IOERR_SEEK, pFile->lastErrno,
+ "seekWinFile", pFile->zPath);
return 1;
}
return 0;
+#endif
}
/*
** Close a file.
**
** It is reported that an attempt to close a handle might sometimes
-** fail. This is a very unreasonable result, but windows is notorious
+** fail. This is a very unreasonable result, but Windows is notorious
** for being unreasonable so I do not doubt that it might happen. If
** the close fails, we pause for 100 milliseconds and try again. As
** many as MX_CLOSE_ATTEMPT attempts to close the handle are made before
@@ -32234,31 +32228,38 @@ static int winClose(sqlite3_file *id){
winFile *pFile = (winFile*)id;
assert( id!=0 );
+#ifndef SQLITE_OMIT_WAL
assert( pFile->pShm==0 );
+#endif
OSTRACE(("CLOSE %d\n", pFile->h));
+ assert( pFile->h!=NULL && pFile->h!=INVALID_HANDLE_VALUE );
do{
- rc = CloseHandle(pFile->h);
+ rc = osCloseHandle(pFile->h);
/* SimulateIOError( rc=0; cnt=MX_CLOSE_ATTEMPT; ); */
- }while( rc==0 && ++cnt < MX_CLOSE_ATTEMPT && (Sleep(100), 1) );
+ }while( rc==0 && ++cnt < MX_CLOSE_ATTEMPT && (sqlite3_win32_sleep(100), 1) );
#if SQLITE_OS_WINCE
#define WINCE_DELETION_ATTEMPTS 3
winceDestroyLock(pFile);
if( pFile->zDeleteOnClose ){
int cnt = 0;
while(
- DeleteFileW(pFile->zDeleteOnClose)==0
- && GetFileAttributesW(pFile->zDeleteOnClose)!=0xffffffff
+ osDeleteFileW(pFile->zDeleteOnClose)==0
+ && osGetFileAttributesW(pFile->zDeleteOnClose)!=0xffffffff
&& cnt++ < WINCE_DELETION_ATTEMPTS
){
- Sleep(100); /* Wait a little before trying again */
+ sqlite3_win32_sleep(100); /* Wait a little before trying again */
}
- free(pFile->zDeleteOnClose);
+ sqlite3_free(pFile->zDeleteOnClose);
}
#endif
OSTRACE(("CLOSE %d %s\n", pFile->h, rc ? "ok" : "failed"));
+ if( rc ){
+ pFile->h = NULL;
+ }
OpenCounter(-1);
return rc ? SQLITE_OK
- : winLogError(SQLITE_IOERR_CLOSE, "winClose", pFile->zPath);
+ : winLogError(SQLITE_IOERR_CLOSE, osGetLastError(),
+ "winClose", pFile->zPath);
}
/*
@@ -32272,20 +32273,36 @@ static int winRead(
int amt, /* Number of bytes to read */
sqlite3_int64 offset /* Begin reading at this offset */
){
+#if !SQLITE_OS_WINCE
+ OVERLAPPED overlapped; /* The offset for ReadFile. */
+#endif
winFile *pFile = (winFile*)id; /* file handle */
DWORD nRead; /* Number of bytes actually read from file */
+ int nRetry = 0; /* Number of retrys */
assert( id!=0 );
SimulateIOError(return SQLITE_IOERR_READ);
OSTRACE(("READ %d lock=%d\n", pFile->h, pFile->locktype));
+#if SQLITE_OS_WINCE
if( seekWinFile(pFile, offset) ){
return SQLITE_FULL;
}
- if( !ReadFile(pFile->h, pBuf, amt, &nRead, 0) ){
- pFile->lastErrno = GetLastError();
- return winLogError(SQLITE_IOERR_READ, "winRead", pFile->zPath);
- }
+ while( !osReadFile(pFile->h, pBuf, amt, &nRead, 0) ){
+#else
+ memset(&overlapped, 0, sizeof(OVERLAPPED));
+ overlapped.Offset = (LONG)(offset & 0xffffffff);
+ overlapped.OffsetHigh = (LONG)((offset>>32) & 0x7fffffff);
+ while( !osReadFile(pFile->h, pBuf, amt, &nRead, &overlapped) &&
+ osGetLastError()!=ERROR_HANDLE_EOF ){
+#endif
+ DWORD lastErrno;
+ if( retryIoerr(&nRetry, &lastErrno) ) continue;
+ pFile->lastErrno = lastErrno;
+ return winLogError(SQLITE_IOERR_READ, pFile->lastErrno,
+ "winRead", pFile->zPath);
+ }
+ logIoerr(nRetry);
if( nRead<(DWORD)amt ){
/* Unread parts of the buffer must be zero-filled */
memset(&((char*)pBuf)[nRead], 0, amt-nRead);
@@ -32305,8 +32322,9 @@ static int winWrite(
int amt, /* Number of bytes to write */
sqlite3_int64 offset /* Offset into the file to begin writing at */
){
- int rc; /* True if error has occured, else false */
+ int rc = 0; /* True if error has occurred, else false */
winFile *pFile = (winFile*)id; /* File handle */
+ int nRetry = 0; /* Number of retries */
assert( amt>0 );
assert( pFile );
@@ -32315,18 +32333,50 @@ static int winWrite(
OSTRACE(("WRITE %d lock=%d\n", pFile->h, pFile->locktype));
+#if SQLITE_OS_WINCE
rc = seekWinFile(pFile, offset);
if( rc==0 ){
+#else
+ {
+#endif
+#if !SQLITE_OS_WINCE
+ OVERLAPPED overlapped; /* The offset for WriteFile. */
+#endif
u8 *aRem = (u8 *)pBuf; /* Data yet to be written */
int nRem = amt; /* Number of bytes yet to be written */
DWORD nWrite; /* Bytes written by each WriteFile() call */
+ DWORD lastErrno = NO_ERROR; /* Value returned by GetLastError() */
+
+#if !SQLITE_OS_WINCE
+ memset(&overlapped, 0, sizeof(OVERLAPPED));
+ overlapped.Offset = (LONG)(offset & 0xffffffff);
+ overlapped.OffsetHigh = (LONG)((offset>>32) & 0x7fffffff);
+#endif
- while( nRem>0 && WriteFile(pFile->h, aRem, nRem, &nWrite, 0) && nWrite>0 ){
+ while( nRem>0 ){
+#if SQLITE_OS_WINCE
+ if( !osWriteFile(pFile->h, aRem, nRem, &nWrite, 0) ){
+#else
+ if( !osWriteFile(pFile->h, aRem, nRem, &nWrite, &overlapped) ){
+#endif
+ if( retryIoerr(&nRetry, &lastErrno) ) continue;
+ break;
+ }
+ assert( nWrite==0 || nWrite<=(DWORD)nRem );
+ if( nWrite==0 || nWrite>(DWORD)nRem ){
+ lastErrno = osGetLastError();
+ break;
+ }
+#if !SQLITE_OS_WINCE
+ offset += nWrite;
+ overlapped.Offset = (LONG)(offset & 0xffffffff);
+ overlapped.OffsetHigh = (LONG)((offset>>32) & 0x7fffffff);
+#endif
aRem += nWrite;
nRem -= nWrite;
}
if( nRem>0 ){
- pFile->lastErrno = GetLastError();
+ pFile->lastErrno = lastErrno;
rc = 1;
}
}
@@ -32336,7 +32386,10 @@ static int winWrite(
|| ( pFile->lastErrno==ERROR_DISK_FULL )){
return SQLITE_FULL;
}
- return winLogError(SQLITE_IOERR_WRITE, "winWrite", pFile->zPath);
+ return winLogError(SQLITE_IOERR_WRITE, pFile->lastErrno,
+ "winWrite", pFile->zPath);
+ }else{
+ logIoerr(nRetry);
}
return SQLITE_OK;
}
@@ -32358,16 +32411,18 @@ static int winTruncate(sqlite3_file *id, sqlite3_int64 nByte){
** actual file size after the operation may be larger than the requested
** size).
*/
- if( pFile->szChunk ){
+ if( pFile->szChunk>0 ){
nByte = ((nByte + pFile->szChunk - 1)/pFile->szChunk) * pFile->szChunk;
}
/* SetEndOfFile() returns non-zero when successful, or zero when it fails. */
if( seekWinFile(pFile, nByte) ){
- rc = winLogError(SQLITE_IOERR_TRUNCATE, "winTruncate1", pFile->zPath);
- }else if( 0==SetEndOfFile(pFile->h) ){
- pFile->lastErrno = GetLastError();
- rc = winLogError(SQLITE_IOERR_TRUNCATE, "winTruncate2", pFile->zPath);
+ rc = winLogError(SQLITE_IOERR_TRUNCATE, pFile->lastErrno,
+ "winTruncate1", pFile->zPath);
+ }else if( 0==osSetEndOfFile(pFile->h) ){
+ pFile->lastErrno = osGetLastError();
+ rc = winLogError(SQLITE_IOERR_TRUNCATE, pFile->lastErrno,
+ "winTruncate2", pFile->zPath);
}
OSTRACE(("TRUNCATE %d %lld %s\n", pFile->h, nByte, rc ? "failed" : "ok"));
@@ -32387,9 +32442,19 @@ SQLITE_API int sqlite3_fullsync_count = 0;
** Make sure all writes to a particular file are committed to disk.
*/
static int winSync(sqlite3_file *id, int flags){
-#if !defined(NDEBUG) || !defined(SQLITE_NO_SYNC) || defined(SQLITE_DEBUG)
- winFile *pFile = (winFile*)id;
+#ifndef SQLITE_NO_SYNC
+ /*
+ ** Used only when SQLITE_NO_SYNC is not defined.
+ */
BOOL rc;
+#endif
+#if !defined(NDEBUG) || !defined(SQLITE_NO_SYNC) || \
+ (defined(SQLITE_TEST) && defined(SQLITE_DEBUG))
+ /*
+ ** Used when SQLITE_NO_SYNC is not defined and by the assert() and/or
+ ** OSTRACE() macros.
+ */
+ winFile *pFile = (winFile*)id;
#else
UNUSED_PARAMETER(id);
#endif
@@ -32422,13 +32487,14 @@ static int winSync(sqlite3_file *id, int flags){
#ifdef SQLITE_NO_SYNC
return SQLITE_OK;
#else
- rc = FlushFileBuffers(pFile->h);
+ rc = osFlushFileBuffers(pFile->h);
SimulateIOError( rc=FALSE );
if( rc ){
return SQLITE_OK;
}else{
- pFile->lastErrno = GetLastError();
- return winLogError(SQLITE_IOERR_FSYNC, "winSync", pFile->zPath);
+ pFile->lastErrno = osGetLastError();
+ return winLogError(SQLITE_IOERR_FSYNC, pFile->lastErrno,
+ "winSync", pFile->zPath);
}
#endif
}
@@ -32437,22 +32503,40 @@ static int winSync(sqlite3_file *id, int flags){
** Determine the current size of a file in bytes
*/
static int winFileSize(sqlite3_file *id, sqlite3_int64 *pSize){
- DWORD upperBits;
- DWORD lowerBits;
winFile *pFile = (winFile*)id;
- DWORD error;
+ int rc = SQLITE_OK;
assert( id!=0 );
SimulateIOError(return SQLITE_IOERR_FSTAT);
- lowerBits = GetFileSize(pFile->h, &upperBits);
- if( (lowerBits == INVALID_FILE_SIZE)
- && ((error = GetLastError()) != NO_ERROR) )
+#if SQLITE_OS_WINRT
{
- pFile->lastErrno = error;
- return winLogError(SQLITE_IOERR_FSTAT, "winFileSize", pFile->zPath);
+ FILE_STANDARD_INFO info;
+ if( osGetFileInformationByHandleEx(pFile->h, FileStandardInfo,
+ &info, sizeof(info)) ){
+ *pSize = info.EndOfFile.QuadPart;
+ }else{
+ pFile->lastErrno = osGetLastError();
+ rc = winLogError(SQLITE_IOERR_FSTAT, pFile->lastErrno,
+ "winFileSize", pFile->zPath);
+ }
}
- *pSize = (((sqlite3_int64)upperBits)<<32) + lowerBits;
- return SQLITE_OK;
+#else
+ {
+ DWORD upperBits;
+ DWORD lowerBits;
+ DWORD lastErrno;
+
+ lowerBits = osGetFileSize(pFile->h, &upperBits);
+ *pSize = (((sqlite3_int64)upperBits)<<32) + lowerBits;
+ if( (lowerBits == INVALID_FILE_SIZE)
+ && ((lastErrno = osGetLastError())!=NO_ERROR) ){
+ pFile->lastErrno = lastErrno;
+ rc = winLogError(SQLITE_IOERR_FSTAT, pFile->lastErrno,
+ "winFileSize", pFile->zPath);
+ }
+ }
+#endif
+ return rc;
}
/*
@@ -32462,32 +32546,60 @@ static int winFileSize(sqlite3_file *id, sqlite3_int64 *pSize){
# define LOCKFILE_FAIL_IMMEDIATELY 1
#endif
+#ifndef LOCKFILE_EXCLUSIVE_LOCK
+# define LOCKFILE_EXCLUSIVE_LOCK 2
+#endif
+
+/*
+** Historically, SQLite has used both the LockFile and LockFileEx functions.
+** When the LockFile function was used, it was always expected to fail
+** immediately if the lock could not be obtained. Also, it always expected to
+** obtain an exclusive lock. These flags are used with the LockFileEx function
+** and reflect those expectations; therefore, they should not be changed.
+*/
+#ifndef SQLITE_LOCKFILE_FLAGS
+# define SQLITE_LOCKFILE_FLAGS (LOCKFILE_FAIL_IMMEDIATELY | \
+ LOCKFILE_EXCLUSIVE_LOCK)
+#endif
+
+/*
+** Currently, SQLite never calls the LockFileEx function without wanting the
+** call to fail immediately if the lock cannot be obtained.
+*/
+#ifndef SQLITE_LOCKFILEEX_FLAGS
+# define SQLITE_LOCKFILEEX_FLAGS (LOCKFILE_FAIL_IMMEDIATELY)
+#endif
+
/*
** Acquire a reader lock.
** Different API routines are called depending on whether or not this
-** is Win95 or WinNT.
+** is Win9x or WinNT.
*/
static int getReadLock(winFile *pFile){
int res;
if( isNT() ){
- OVERLAPPED ovlp;
- ovlp.Offset = SHARED_FIRST;
- ovlp.OffsetHigh = 0;
- ovlp.hEvent = 0;
- res = LockFileEx(pFile->h, LOCKFILE_FAIL_IMMEDIATELY,
- 0, SHARED_SIZE, 0, &ovlp);
-/* isNT() is 1 if SQLITE_OS_WINCE==1, so this else is never executed.
-*/
-#if SQLITE_OS_WINCE==0
- }else{
+#if SQLITE_OS_WINCE
+ /*
+ ** NOTE: Windows CE is handled differently here due its lack of the Win32
+ ** API LockFileEx.
+ */
+ res = winceLockFile(&pFile->h, SHARED_FIRST, 0, 1, 0);
+#else
+ res = winLockFile(&pFile->h, SQLITE_LOCKFILEEX_FLAGS, SHARED_FIRST, 0,
+ SHARED_SIZE, 0);
+#endif
+ }
+#ifdef SQLITE_WIN32_HAS_ANSI
+ else{
int lk;
sqlite3_randomness(sizeof(lk), &lk);
pFile->sharedLockByte = (short)((lk & 0x7fffffff)%(SHARED_SIZE - 1));
- res = LockFile(pFile->h, SHARED_FIRST+pFile->sharedLockByte, 0, 1, 0);
-#endif
+ res = winLockFile(&pFile->h, SQLITE_LOCKFILE_FLAGS,
+ SHARED_FIRST+pFile->sharedLockByte, 0, 1, 0);
}
+#endif
if( res == 0 ){
- pFile->lastErrno = GetLastError();
+ pFile->lastErrno = osGetLastError();
/* No need to log a failure to lock */
}
return res;
@@ -32498,18 +32610,19 @@ static int getReadLock(winFile *pFile){
*/
static int unlockReadLock(winFile *pFile){
int res;
+ DWORD lastErrno;
if( isNT() ){
- res = UnlockFile(pFile->h, SHARED_FIRST, 0, SHARED_SIZE, 0);
-/* isNT() is 1 if SQLITE_OS_WINCE==1, so this else is never executed.
-*/
-#if SQLITE_OS_WINCE==0
- }else{
- res = UnlockFile(pFile->h, SHARED_FIRST + pFile->sharedLockByte, 0, 1, 0);
-#endif
+ res = winUnlockFile(&pFile->h, SHARED_FIRST, 0, SHARED_SIZE, 0);
}
- if( res==0 && GetLastError()!=ERROR_NOT_LOCKED ){
- pFile->lastErrno = GetLastError();
- winLogError(SQLITE_IOERR_UNLOCK, "unlockReadLock", pFile->zPath);
+#ifdef SQLITE_WIN32_HAS_ANSI
+ else{
+ res = winUnlockFile(&pFile->h, SHARED_FIRST+pFile->sharedLockByte, 0, 1, 0);
+ }
+#endif
+ if( res==0 && ((lastErrno = osGetLastError())!=ERROR_NOT_LOCKED) ){
+ pFile->lastErrno = lastErrno;
+ winLogError(SQLITE_IOERR_UNLOCK, pFile->lastErrno,
+ "unlockReadLock", pFile->zPath);
}
return res;
}
@@ -32542,11 +32655,11 @@ static int unlockReadLock(winFile *pFile){
*/
static int winLock(sqlite3_file *id, int locktype){
int rc = SQLITE_OK; /* Return code from subroutines */
- int res = 1; /* Result of a windows lock call */
+ int res = 1; /* Result of a Windows lock call */
int newLocktype; /* Set pFile->locktype to this value before exiting */
int gotPendingLock = 0;/* True if we acquired a PENDING lock this time */
winFile *pFile = (winFile*)id;
- DWORD error = NO_ERROR;
+ DWORD lastErrno = NO_ERROR;
assert( id!=0 );
OSTRACE(("LOCK %d %d was %d(%d)\n",
@@ -32576,16 +32689,20 @@ static int winLock(sqlite3_file *id, int locktype){
&& (pFile->locktype==RESERVED_LOCK))
){
int cnt = 3;
- while( cnt-->0 && (res = LockFile(pFile->h, PENDING_BYTE, 0, 1, 0))==0 ){
- /* Try 3 times to get the pending lock. The pending lock might be
- ** held by another reader process who will release it momentarily.
+ while( cnt-->0 && (res = winLockFile(&pFile->h, SQLITE_LOCKFILE_FLAGS,
+ PENDING_BYTE, 0, 1, 0))==0 ){
+ /* Try 3 times to get the pending lock. This is needed to work
+ ** around problems caused by indexing and/or anti-virus software on
+ ** Windows systems.
+ ** If you are using this code as a model for alternative VFSes, do not
+ ** copy this retry logic. It is a hack intended for Windows only.
*/
OSTRACE(("could not get a PENDING lock. cnt=%d\n", cnt));
- Sleep(1);
+ if( cnt ) sqlite3_win32_sleep(1);
}
gotPendingLock = res;
if( !res ){
- error = GetLastError();
+ lastErrno = osGetLastError();
}
}
@@ -32597,7 +32714,7 @@ static int winLock(sqlite3_file *id, int locktype){
if( res ){
newLocktype = SHARED_LOCK;
}else{
- error = GetLastError();
+ lastErrno = osGetLastError();
}
}
@@ -32605,11 +32722,11 @@ static int winLock(sqlite3_file *id, int locktype){
*/
if( locktype==RESERVED_LOCK && res ){
assert( pFile->locktype==SHARED_LOCK );
- res = LockFile(pFile->h, RESERVED_BYTE, 0, 1, 0);
+ res = winLockFile(&pFile->h, SQLITE_LOCKFILE_FLAGS, RESERVED_BYTE, 0, 1, 0);
if( res ){
newLocktype = RESERVED_LOCK;
}else{
- error = GetLastError();
+ lastErrno = osGetLastError();
}
}
@@ -32626,12 +32743,13 @@ static int winLock(sqlite3_file *id, int locktype){
assert( pFile->locktype>=SHARED_LOCK );
res = unlockReadLock(pFile);
OSTRACE(("unreadlock = %d\n", res));
- res = LockFile(pFile->h, SHARED_FIRST, 0, SHARED_SIZE, 0);
+ res = winLockFile(&pFile->h, SQLITE_LOCKFILE_FLAGS, SHARED_FIRST, 0,
+ SHARED_SIZE, 0);
if( res ){
newLocktype = EXCLUSIVE_LOCK;
}else{
- error = GetLastError();
- OSTRACE(("error-code = %d\n", error));
+ lastErrno = osGetLastError();
+ OSTRACE(("error-code = %d\n", lastErrno));
getReadLock(pFile);
}
}
@@ -32640,7 +32758,7 @@ static int winLock(sqlite3_file *id, int locktype){
** release it now.
*/
if( gotPendingLock && locktype==SHARED_LOCK ){
- UnlockFile(pFile->h, PENDING_BYTE, 0, 1, 0);
+ winUnlockFile(&pFile->h, PENDING_BYTE, 0, 1, 0);
}
/* Update the state of the lock has held in the file descriptor then
@@ -32651,7 +32769,7 @@ static int winLock(sqlite3_file *id, int locktype){
}else{
OSTRACE(("LOCK FAILED %d trying for %d but got %d\n", pFile->h,
locktype, newLocktype));
- pFile->lastErrno = error;
+ pFile->lastErrno = lastErrno;
rc = SQLITE_BUSY;
}
pFile->locktype = (u8)newLocktype;
@@ -32674,9 +32792,9 @@ static int winCheckReservedLock(sqlite3_file *id, int *pResOut){
rc = 1;
OSTRACE(("TEST WR-LOCK %d %d (local)\n", pFile->h, rc));
}else{
- rc = LockFile(pFile->h, RESERVED_BYTE, 0, 1, 0);
+ rc = winLockFile(&pFile->h, SQLITE_LOCKFILE_FLAGS, RESERVED_BYTE, 0, 1, 0);
if( rc ){
- UnlockFile(pFile->h, RESERVED_BYTE, 0, 1, 0);
+ winUnlockFile(&pFile->h, RESERVED_BYTE, 0, 1, 0);
}
rc = !rc;
OSTRACE(("TEST WR-LOCK %d %d (remote)\n", pFile->h, rc));
@@ -32706,51 +32824,112 @@ static int winUnlock(sqlite3_file *id, int locktype){
pFile->locktype, pFile->sharedLockByte));
type = pFile->locktype;
if( type>=EXCLUSIVE_LOCK ){
- UnlockFile(pFile->h, SHARED_FIRST, 0, SHARED_SIZE, 0);
+ winUnlockFile(&pFile->h, SHARED_FIRST, 0, SHARED_SIZE, 0);
if( locktype==SHARED_LOCK && !getReadLock(pFile) ){
/* This should never happen. We should always be able to
** reacquire the read lock */
- rc = winLogError(SQLITE_IOERR_UNLOCK, "winUnlock", pFile->zPath);
+ rc = winLogError(SQLITE_IOERR_UNLOCK, osGetLastError(),
+ "winUnlock", pFile->zPath);
}
}
if( type>=RESERVED_LOCK ){
- UnlockFile(pFile->h, RESERVED_BYTE, 0, 1, 0);
+ winUnlockFile(&pFile->h, RESERVED_BYTE, 0, 1, 0);
}
if( locktype==NO_LOCK && type>=SHARED_LOCK ){
unlockReadLock(pFile);
}
if( type>=PENDING_LOCK ){
- UnlockFile(pFile->h, PENDING_BYTE, 0, 1, 0);
+ winUnlockFile(&pFile->h, PENDING_BYTE, 0, 1, 0);
}
pFile->locktype = (u8)locktype;
return rc;
}
/*
+** If *pArg is inititially negative then this is a query. Set *pArg to
+** 1 or 0 depending on whether or not bit mask of pFile->ctrlFlags is set.
+**
+** If *pArg is 0 or 1, then clear or set the mask bit of pFile->ctrlFlags.
+*/
+static void winModeBit(winFile *pFile, unsigned char mask, int *pArg){
+ if( *pArg<0 ){
+ *pArg = (pFile->ctrlFlags & mask)!=0;
+ }else if( (*pArg)==0 ){
+ pFile->ctrlFlags &= ~mask;
+ }else{
+ pFile->ctrlFlags |= mask;
+ }
+}
+
+/* Forward declaration */
+static int getTempname(int nBuf, char *zBuf);
+
+/*
** Control and query of the open file handle.
*/
static int winFileControl(sqlite3_file *id, int op, void *pArg){
+ winFile *pFile = (winFile*)id;
switch( op ){
case SQLITE_FCNTL_LOCKSTATE: {
- *(int*)pArg = ((winFile*)id)->locktype;
+ *(int*)pArg = pFile->locktype;
return SQLITE_OK;
}
case SQLITE_LAST_ERRNO: {
- *(int*)pArg = (int)((winFile*)id)->lastErrno;
+ *(int*)pArg = (int)pFile->lastErrno;
return SQLITE_OK;
}
case SQLITE_FCNTL_CHUNK_SIZE: {
- ((winFile*)id)->szChunk = *(int *)pArg;
+ pFile->szChunk = *(int *)pArg;
return SQLITE_OK;
}
case SQLITE_FCNTL_SIZE_HINT: {
- sqlite3_int64 sz = *(sqlite3_int64*)pArg;
- SimulateIOErrorBenign(1);
- winTruncate(id, sz);
- SimulateIOErrorBenign(0);
+ if( pFile->szChunk>0 ){
+ sqlite3_int64 oldSz;
+ int rc = winFileSize(id, &oldSz);
+ if( rc==SQLITE_OK ){
+ sqlite3_int64 newSz = *(sqlite3_int64*)pArg;
+ if( newSz>oldSz ){
+ SimulateIOErrorBenign(1);
+ rc = winTruncate(id, newSz);
+ SimulateIOErrorBenign(0);
+ }
+ }
+ return rc;
+ }
return SQLITE_OK;
}
- case SQLITE_FCNTL_SYNC_OMITTED: {
+ case SQLITE_FCNTL_PERSIST_WAL: {
+ winModeBit(pFile, WINFILE_PERSIST_WAL, (int*)pArg);
+ return SQLITE_OK;
+ }
+ case SQLITE_FCNTL_POWERSAFE_OVERWRITE: {
+ winModeBit(pFile, WINFILE_PSOW, (int*)pArg);
+ return SQLITE_OK;
+ }
+ case SQLITE_FCNTL_VFSNAME: {
+ *(char**)pArg = sqlite3_mprintf("win32");
+ return SQLITE_OK;
+ }
+ case SQLITE_FCNTL_WIN32_AV_RETRY: {
+ int *a = (int*)pArg;
+ if( a[0]>0 ){
+ win32IoerrRetry = a[0];
+ }else{
+ a[0] = win32IoerrRetry;
+ }
+ if( a[1]>0 ){
+ win32IoerrRetryDelay = a[1];
+ }else{
+ a[1] = win32IoerrRetryDelay;
+ }
+ return SQLITE_OK;
+ }
+ case SQLITE_FCNTL_TEMPFILENAME: {
+ char *zTFile = sqlite3MallocZero( pFile->pVfs->mxPathname );
+ if( zTFile ){
+ getTempname(pFile->pVfs->mxPathname, zTFile);
+ *(char**)pArg = zTFile;
+ }
return SQLITE_OK;
}
}
@@ -32768,16 +32947,17 @@ static int winFileControl(sqlite3_file *id, int op, void *pArg){
** same for both.
*/
static int winSectorSize(sqlite3_file *id){
- assert( id!=0 );
- return (int)(((winFile*)id)->sectorSize);
+ (void)id;
+ return SQLITE_DEFAULT_SECTOR_SIZE;
}
/*
** Return a vector of device characteristics.
*/
static int winDeviceCharacteristics(sqlite3_file *id){
- UNUSED_PARAMETER(id);
- return SQLITE_IOCAP_UNDELETABLE_WHEN_OPEN;
+ winFile *p = (winFile*)id;
+ return SQLITE_IOCAP_UNDELETABLE_WHEN_OPEN |
+ ((p->ctrlFlags & WINFILE_PSOW)?SQLITE_IOCAP_POWERSAFE_OVERWRITE:0);
}
#ifndef SQLITE_OMIT_WAL
@@ -32908,31 +33088,25 @@ static int winShmSystemLock(
int ofst, /* Offset to first byte to be locked/unlocked */
int nByte /* Number of bytes to lock or unlock */
){
- OVERLAPPED ovlp;
- DWORD dwFlags;
int rc = 0; /* Result code form Lock/UnlockFileEx() */
/* Access to the winShmNode object is serialized by the caller */
assert( sqlite3_mutex_held(pFile->mutex) || pFile->nRef==0 );
- /* Initialize the locking parameters */
- dwFlags = LOCKFILE_FAIL_IMMEDIATELY;
- if( lockType == _SHM_WRLCK ) dwFlags |= LOCKFILE_EXCLUSIVE_LOCK;
-
- memset(&ovlp, 0, sizeof(OVERLAPPED));
- ovlp.Offset = ofst;
-
/* Release/Acquire the system-level lock */
if( lockType==_SHM_UNLCK ){
- rc = UnlockFileEx(pFile->hFile.h, 0, nByte, 0, &ovlp);
+ rc = winUnlockFile(&pFile->hFile.h, ofst, 0, nByte, 0);
}else{
- rc = LockFileEx(pFile->hFile.h, dwFlags, 0, nByte, 0, &ovlp);
+ /* Initialize the locking parameters */
+ DWORD dwFlags = LOCKFILE_FAIL_IMMEDIATELY;
+ if( lockType == _SHM_WRLCK ) dwFlags |= LOCKFILE_EXCLUSIVE_LOCK;
+ rc = winLockFile(&pFile->hFile.h, dwFlags, ofst, 0, nByte, 0);
}
if( rc!= 0 ){
rc = SQLITE_OK;
}else{
- pFile->lastErrno = GetLastError();
+ pFile->lastErrno = osGetLastError();
rc = SQLITE_BUSY;
}
@@ -32966,23 +33140,25 @@ static void winShmPurge(sqlite3_vfs *pVfs, int deleteFlag){
int i;
if( p->mutex ) sqlite3_mutex_free(p->mutex);
for(i=0; i<p->nRegion; i++){
- bRc = UnmapViewOfFile(p->aRegion[i].pMap);
+ bRc = osUnmapViewOfFile(p->aRegion[i].pMap);
OSTRACE(("SHM-PURGE pid-%d unmap region=%d %s\n",
- (int)GetCurrentProcessId(), i,
+ (int)osGetCurrentProcessId(), i,
bRc ? "ok" : "failed"));
- bRc = CloseHandle(p->aRegion[i].hMap);
+ bRc = osCloseHandle(p->aRegion[i].hMap);
OSTRACE(("SHM-PURGE pid-%d close region=%d %s\n",
- (int)GetCurrentProcessId(), i,
+ (int)osGetCurrentProcessId(), i,
bRc ? "ok" : "failed"));
}
- if( p->hFile.h != INVALID_HANDLE_VALUE ){
+ if( p->hFile.h!=NULL && p->hFile.h!=INVALID_HANDLE_VALUE ){
SimulateIOErrorBenign(1);
winClose((sqlite3_file *)&p->hFile);
SimulateIOErrorBenign(0);
}
if( deleteFlag ){
SimulateIOErrorBenign(1);
+ sqlite3BeginBenignMalloc();
winDelete(pVfs, p->zFilename, 0);
+ sqlite3EndBenignMalloc();
SimulateIOErrorBenign(0);
}
*pp = p->pNext;
@@ -33013,16 +33189,14 @@ static int winOpenSharedMemory(winFile *pDbFd){
/* Allocate space for the new sqlite3_shm object. Also speculatively
** allocate space for a new winShmNode and filename.
*/
- p = sqlite3_malloc( sizeof(*p) );
- if( p==0 ) return SQLITE_NOMEM;
- memset(p, 0, sizeof(*p));
+ p = sqlite3MallocZero( sizeof(*p) );
+ if( p==0 ) return SQLITE_IOERR_NOMEM;
nName = sqlite3Strlen30(pDbFd->zPath);
- pNew = sqlite3_malloc( sizeof(*pShmNode) + nName + 15 );
+ pNew = sqlite3MallocZero( sizeof(*pShmNode) + nName + 17 );
if( pNew==0 ){
sqlite3_free(p);
- return SQLITE_NOMEM;
+ return SQLITE_IOERR_NOMEM;
}
- memset(pNew, 0, sizeof(*pNew));
pNew->zFilename = (char*)&pNew[1];
sqlite3_snprintf(nName+15, pNew->zFilename, "%s-shm", pDbFd->zPath);
sqlite3FileSuffix3(pDbFd->zPath, pNew->zFilename);
@@ -33048,17 +33222,16 @@ static int winOpenSharedMemory(winFile *pDbFd){
pShmNode->mutex = sqlite3_mutex_alloc(SQLITE_MUTEX_FAST);
if( pShmNode->mutex==0 ){
- rc = SQLITE_NOMEM;
+ rc = SQLITE_IOERR_NOMEM;
goto shm_open_err;
}
rc = winOpen(pDbFd->pVfs,
pShmNode->zFilename, /* Name of the file (UTF-8) */
(sqlite3_file*)&pShmNode->hFile, /* File handle here */
- SQLITE_OPEN_WAL | SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE, /* Mode flags */
+ SQLITE_OPEN_WAL | SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE,
0);
if( SQLITE_OK!=rc ){
- rc = SQLITE_CANTOPEN_BKPT;
goto shm_open_err;
}
@@ -33068,7 +33241,8 @@ static int winOpenSharedMemory(winFile *pDbFd){
if( winShmSystemLock(pShmNode, _SHM_WRLCK, WIN_SHM_DMS, 1)==SQLITE_OK ){
rc = winTruncate((sqlite3_file *)&pShmNode->hFile, 0);
if( rc!=SQLITE_OK ){
- rc = winLogError(SQLITE_IOERR_SHMOPEN, "winOpenShm", pDbFd->zPath);
+ rc = winLogError(SQLITE_IOERR_SHMOPEN, osGetLastError(),
+ "winOpenShm", pDbFd->zPath);
}
}
if( rc==SQLITE_OK ){
@@ -33253,7 +33427,7 @@ static int winShmLock(
}
sqlite3_mutex_leave(pShmNode->mutex);
OSTRACE(("SHM-LOCK shmid-%d, pid-%d got %03x,%03x %s\n",
- p->id, (int)GetCurrentProcessId(), p->sharedMask, p->exclMask,
+ p->id, (int)osGetCurrentProcessId(), p->sharedMask, p->exclMask,
rc ? "failed" : "ok"));
return rc;
}
@@ -33327,7 +33501,8 @@ static int winShmMap(
*/
rc = winFileSize((sqlite3_file *)&pShmNode->hFile, &sz);
if( rc!=SQLITE_OK ){
- rc = winLogError(SQLITE_IOERR_SHMSIZE, "winShmMap1", pDbFd->zPath);
+ rc = winLogError(SQLITE_IOERR_SHMSIZE, osGetLastError(),
+ "winShmMap1", pDbFd->zPath);
goto shmpage_out;
}
@@ -33341,7 +33516,8 @@ static int winShmMap(
if( !isWrite ) goto shmpage_out;
rc = winTruncate((sqlite3_file *)&pShmNode->hFile, nByte);
if( rc!=SQLITE_OK ){
- rc = winLogError(SQLITE_IOERR_SHMSIZE, "winShmMap2", pDbFd->zPath);
+ rc = winLogError(SQLITE_IOERR_SHMSIZE, osGetLastError(),
+ "winShmMap2", pDbFd->zPath);
goto shmpage_out;
}
}
@@ -33357,29 +33533,46 @@ static int winShmMap(
pShmNode->aRegion = apNew;
while( pShmNode->nRegion<=iRegion ){
- HANDLE hMap; /* file-mapping handle */
+ HANDLE hMap = NULL; /* file-mapping handle */
void *pMap = 0; /* Mapped memory region */
- hMap = CreateFileMapping(pShmNode->hFile.h,
+#if SQLITE_OS_WINRT
+ hMap = osCreateFileMappingFromApp(pShmNode->hFile.h,
+ NULL, PAGE_READWRITE, nByte, NULL
+ );
+#elif defined(SQLITE_WIN32_HAS_WIDE)
+ hMap = osCreateFileMappingW(pShmNode->hFile.h,
+ NULL, PAGE_READWRITE, 0, nByte, NULL
+ );
+#elif defined(SQLITE_WIN32_HAS_ANSI)
+ hMap = osCreateFileMappingA(pShmNode->hFile.h,
NULL, PAGE_READWRITE, 0, nByte, NULL
);
+#endif
OSTRACE(("SHM-MAP pid-%d create region=%d nbyte=%d %s\n",
- (int)GetCurrentProcessId(), pShmNode->nRegion, nByte,
+ (int)osGetCurrentProcessId(), pShmNode->nRegion, nByte,
hMap ? "ok" : "failed"));
if( hMap ){
int iOffset = pShmNode->nRegion*szRegion;
int iOffsetShift = iOffset % winSysInfo.dwAllocationGranularity;
- pMap = MapViewOfFile(hMap, FILE_MAP_WRITE | FILE_MAP_READ,
+#if SQLITE_OS_WINRT
+ pMap = osMapViewOfFileFromApp(hMap, FILE_MAP_WRITE | FILE_MAP_READ,
+ iOffset - iOffsetShift, szRegion + iOffsetShift
+ );
+#else
+ pMap = osMapViewOfFile(hMap, FILE_MAP_WRITE | FILE_MAP_READ,
0, iOffset - iOffsetShift, szRegion + iOffsetShift
);
+#endif
OSTRACE(("SHM-MAP pid-%d map region=%d offset=%d size=%d %s\n",
- (int)GetCurrentProcessId(), pShmNode->nRegion, iOffset, szRegion,
- pMap ? "ok" : "failed"));
+ (int)osGetCurrentProcessId(), pShmNode->nRegion, iOffset,
+ szRegion, pMap ? "ok" : "failed"));
}
if( !pMap ){
- pShmNode->lastErrno = GetLastError();
- rc = winLogError(SQLITE_IOERR_SHMMAP, "winShmMap3", pDbFd->zPath);
- if( hMap ) CloseHandle(hMap);
+ pShmNode->lastErrno = osGetLastError();
+ rc = winLogError(SQLITE_IOERR_SHMMAP, pShmNode->lastErrno,
+ "winShmMap3", pDbFd->zPath);
+ if( hMap ) osCloseHandle(hMap);
goto shmpage_out;
}
@@ -33456,13 +33649,12 @@ static void *convertUtf8Filename(const char *zFilename){
void *zConverted = 0;
if( isNT() ){
zConverted = utf8ToUnicode(zFilename);
-/* isNT() is 1 if SQLITE_OS_WINCE==1, so this else is never executed.
-*/
-#if SQLITE_OS_WINCE==0
- }else{
+ }
+#ifdef SQLITE_WIN32_HAS_ANSI
+ else{
zConverted = sqlite3_win32_utf8_to_mbcs(zFilename);
-#endif
}
+#endif
/* caller will handle out of memory */
return zConverted;
}
@@ -33477,7 +33669,8 @@ static int getTempname(int nBuf, char *zBuf){
"ABCDEFGHIJKLMNOPQRSTUVWXYZ"
"0123456789";
size_t i, j;
- char zTempPath[MAX_PATH+1];
+ int nTempPath;
+ char zTempPath[MAX_PATH+2];
/* It's odd to simulate an io-error here, but really this is just
** using the io-error infrastructure to test that SQLite handles this
@@ -33485,62 +33678,97 @@ static int getTempname(int nBuf, char *zBuf){
*/
SimulateIOError( return SQLITE_IOERR );
+ memset(zTempPath, 0, MAX_PATH+2);
+
if( sqlite3_temp_directory ){
sqlite3_snprintf(MAX_PATH-30, zTempPath, "%s", sqlite3_temp_directory);
- }else if( isNT() ){
+ }
+#if !SQLITE_OS_WINRT
+ else if( isNT() ){
char *zMulti;
WCHAR zWidePath[MAX_PATH];
- GetTempPathW(MAX_PATH-30, zWidePath);
+ osGetTempPathW(MAX_PATH-30, zWidePath);
zMulti = unicodeToUtf8(zWidePath);
if( zMulti ){
sqlite3_snprintf(MAX_PATH-30, zTempPath, "%s", zMulti);
- free(zMulti);
+ sqlite3_free(zMulti);
}else{
- return SQLITE_NOMEM;
+ return SQLITE_IOERR_NOMEM;
}
-/* isNT() is 1 if SQLITE_OS_WINCE==1, so this else is never executed.
-** Since the ASCII version of these Windows API do not exist for WINCE,
-** it's important to not reference them for WINCE builds.
-*/
-#if SQLITE_OS_WINCE==0
- }else{
+ }
+#ifdef SQLITE_WIN32_HAS_ANSI
+ else{
char *zUtf8;
char zMbcsPath[MAX_PATH];
- GetTempPathA(MAX_PATH-30, zMbcsPath);
+ osGetTempPathA(MAX_PATH-30, zMbcsPath);
zUtf8 = sqlite3_win32_mbcs_to_utf8(zMbcsPath);
if( zUtf8 ){
sqlite3_snprintf(MAX_PATH-30, zTempPath, "%s", zUtf8);
- free(zUtf8);
+ sqlite3_free(zUtf8);
}else{
- return SQLITE_NOMEM;
+ return SQLITE_IOERR_NOMEM;
}
-#endif
}
+#endif
+#endif
/* Check that the output buffer is large enough for the temporary file
** name. If it is not, return SQLITE_ERROR.
*/
- if( (sqlite3Strlen30(zTempPath) + sqlite3Strlen30(SQLITE_TEMP_FILE_PREFIX) + 17) >= nBuf ){
+ nTempPath = sqlite3Strlen30(zTempPath);
+
+ if( (nTempPath + sqlite3Strlen30(SQLITE_TEMP_FILE_PREFIX) + 18) >= nBuf ){
return SQLITE_ERROR;
}
- for(i=sqlite3Strlen30(zTempPath); i>0 && zTempPath[i-1]=='\\'; i--){}
+ for(i=nTempPath; i>0 && zTempPath[i-1]=='\\'; i--){}
zTempPath[i] = 0;
- sqlite3_snprintf(nBuf-17, zBuf,
- "%s\\"SQLITE_TEMP_FILE_PREFIX, zTempPath);
+ sqlite3_snprintf(nBuf-18, zBuf, (nTempPath > 0) ?
+ "%s\\"SQLITE_TEMP_FILE_PREFIX : SQLITE_TEMP_FILE_PREFIX,
+ zTempPath);
j = sqlite3Strlen30(zBuf);
sqlite3_randomness(15, &zBuf[j]);
for(i=0; i<15; i++, j++){
zBuf[j] = (char)zChars[ ((unsigned char)zBuf[j])%(sizeof(zChars)-1) ];
}
zBuf[j] = 0;
+ zBuf[j+1] = 0;
OSTRACE(("TEMP FILENAME: %s\n", zBuf));
return SQLITE_OK;
}
/*
+** Return TRUE if the named file is really a directory. Return false if
+** it is something other than a directory, or if there is any kind of memory
+** allocation failure.
+*/
+static int winIsDir(const void *zConverted){
+ DWORD attr;
+ int rc = 0;
+ DWORD lastErrno;
+
+ if( isNT() ){
+ int cnt = 0;
+ WIN32_FILE_ATTRIBUTE_DATA sAttrData;
+ memset(&sAttrData, 0, sizeof(sAttrData));
+ while( !(rc = osGetFileAttributesExW((LPCWSTR)zConverted,
+ GetFileExInfoStandard,
+ &sAttrData)) && retryIoerr(&cnt, &lastErrno) ){}
+ if( !rc ){
+ return 0; /* Invalid name? */
+ }
+ attr = sAttrData.dwFileAttributes;
+#if SQLITE_OS_WINCE==0
+ }else{
+ attr = osGetFileAttributesA((char*)zConverted);
+#endif
+ }
+ return (attr!=INVALID_FILE_ATTRIBUTES) && (attr&FILE_ATTRIBUTE_DIRECTORY);
+}
+
+/*
** Open a file.
*/
static int winOpen(
@@ -33551,6 +33779,7 @@ static int winOpen(
int *pOutFlags /* Status return flags */
){
HANDLE h;
+ DWORD lastErrno;
DWORD dwDesiredAccess;
DWORD dwShareMode;
DWORD dwCreationDisposition;
@@ -33561,11 +33790,12 @@ static int winOpen(
winFile *pFile = (winFile*)id;
void *zConverted; /* Filename in OS encoding */
const char *zUtf8Name = zName; /* Filename in UTF-8 encoding */
+ int cnt = 0;
/* If argument zPath is a NULL pointer, this function is required to open
** a temporary file. Use this buffer to store the file name in.
*/
- char zTmpname[MAX_PATH+1]; /* Buffer used to create temp filename */
+ char zTmpname[MAX_PATH+2]; /* Buffer used to create temp filename */
int rc = SQLITE_OK; /* Function Return Code */
#if !defined(NDEBUG) || SQLITE_OS_WINCE
@@ -33614,27 +33844,46 @@ static int winOpen(
|| eType==SQLITE_OPEN_TRANSIENT_DB || eType==SQLITE_OPEN_WAL
);
- assert( id!=0 );
- UNUSED_PARAMETER(pVfs);
-
+ assert( pFile!=0 );
+ memset(pFile, 0, sizeof(winFile));
pFile->h = INVALID_HANDLE_VALUE;
+#if SQLITE_OS_WINRT
+ if( !sqlite3_temp_directory ){
+ sqlite3_log(SQLITE_ERROR,
+ "sqlite3_temp_directory variable should be set for WinRT");
+ }
+#endif
+
/* If the second argument to this function is NULL, generate a
** temporary file name to use
*/
if( !zUtf8Name ){
assert(isDelete && !isOpenJournal);
- rc = getTempname(MAX_PATH+1, zTmpname);
+ memset(zTmpname, 0, MAX_PATH+2);
+ rc = getTempname(MAX_PATH+2, zTmpname);
if( rc!=SQLITE_OK ){
return rc;
}
zUtf8Name = zTmpname;
}
+ /* Database filenames are double-zero terminated if they are not
+ ** URIs with parameters. Hence, they can always be passed into
+ ** sqlite3_uri_parameter().
+ */
+ assert( (eType!=SQLITE_OPEN_MAIN_DB) || (flags & SQLITE_OPEN_URI) ||
+ zUtf8Name[strlen(zUtf8Name)+1]==0 );
+
/* Convert the filename to the system encoding. */
zConverted = convertUtf8Filename(zUtf8Name);
if( zConverted==0 ){
- return SQLITE_NOMEM;
+ return SQLITE_IOERR_NOMEM;
+ }
+
+ if( winIsDir(zConverted) ){
+ sqlite3_free(zConverted);
+ return SQLITE_CANTOPEN_ISDIR;
}
if( isReadWrite ){
@@ -33680,42 +33929,63 @@ static int winOpen(
#endif
if( isNT() ){
- h = CreateFileW((WCHAR*)zConverted,
- dwDesiredAccess,
- dwShareMode,
- NULL,
- dwCreationDisposition,
- dwFlagsAndAttributes,
- NULL
- );
-/* isNT() is 1 if SQLITE_OS_WINCE==1, so this else is never executed.
-** Since the ASCII version of these Windows API do not exist for WINCE,
-** it's important to not reference them for WINCE builds.
-*/
-#if SQLITE_OS_WINCE==0
- }else{
- h = CreateFileA((char*)zConverted,
- dwDesiredAccess,
- dwShareMode,
- NULL,
- dwCreationDisposition,
- dwFlagsAndAttributes,
- NULL
- );
+#if SQLITE_OS_WINRT
+ CREATEFILE2_EXTENDED_PARAMETERS extendedParameters;
+ extendedParameters.dwSize = sizeof(CREATEFILE2_EXTENDED_PARAMETERS);
+ extendedParameters.dwFileAttributes =
+ dwFlagsAndAttributes & FILE_ATTRIBUTE_MASK;
+ extendedParameters.dwFileFlags = dwFlagsAndAttributes & FILE_FLAG_MASK;
+ extendedParameters.dwSecurityQosFlags = SECURITY_ANONYMOUS;
+ extendedParameters.lpSecurityAttributes = NULL;
+ extendedParameters.hTemplateFile = NULL;
+ while( (h = osCreateFile2((LPCWSTR)zConverted,
+ dwDesiredAccess,
+ dwShareMode,
+ dwCreationDisposition,
+ &extendedParameters))==INVALID_HANDLE_VALUE &&
+ retryIoerr(&cnt, &lastErrno) ){
+ /* Noop */
+ }
+#else
+ while( (h = osCreateFileW((LPCWSTR)zConverted,
+ dwDesiredAccess,
+ dwShareMode, NULL,
+ dwCreationDisposition,
+ dwFlagsAndAttributes,
+ NULL))==INVALID_HANDLE_VALUE &&
+ retryIoerr(&cnt, &lastErrno) ){
+ /* Noop */
+ }
#endif
}
+#ifdef SQLITE_WIN32_HAS_ANSI
+ else{
+ while( (h = osCreateFileA((LPCSTR)zConverted,
+ dwDesiredAccess,
+ dwShareMode, NULL,
+ dwCreationDisposition,
+ dwFlagsAndAttributes,
+ NULL))==INVALID_HANDLE_VALUE &&
+ retryIoerr(&cnt, &lastErrno) ){
+ /* Noop */
+ }
+ }
+#endif
+ logIoerr(cnt);
OSTRACE(("OPEN %d %s 0x%lx %s\n",
h, zName, dwDesiredAccess,
h==INVALID_HANDLE_VALUE ? "failed" : "ok"));
if( h==INVALID_HANDLE_VALUE ){
- pFile->lastErrno = GetLastError();
- winLogError(SQLITE_CANTOPEN, "winOpen", zUtf8Name);
- free(zConverted);
- if( isReadWrite ){
+ pFile->lastErrno = lastErrno;
+ winLogError(SQLITE_CANTOPEN, pFile->lastErrno, "winOpen", zUtf8Name);
+ sqlite3_free(zConverted);
+ if( isReadWrite && !isExclusive ){
return winOpen(pVfs, zName, id,
- ((flags|SQLITE_OPEN_READONLY)&~(SQLITE_OPEN_CREATE|SQLITE_OPEN_READWRITE)), pOutFlags);
+ ((flags|SQLITE_OPEN_READONLY) &
+ ~(SQLITE_OPEN_CREATE|SQLITE_OPEN_READWRITE)),
+ pOutFlags);
}else{
return SQLITE_CANTOPEN_BKPT;
}
@@ -33729,30 +33999,30 @@ static int winOpen(
}
}
- memset(pFile, 0, sizeof(*pFile));
- pFile->pMethod = &winIoMethod;
- pFile->h = h;
- pFile->lastErrno = NO_ERROR;
- pFile->pVfs = pVfs;
- pFile->pShm = 0;
- pFile->zPath = zName;
- pFile->sectorSize = getSectorSize(pVfs, zUtf8Name);
-
#if SQLITE_OS_WINCE
if( isReadWrite && eType==SQLITE_OPEN_MAIN_DB
- && !winceCreateLock(zName, pFile)
+ && (rc = winceCreateLock(zName, pFile))!=SQLITE_OK
){
- CloseHandle(h);
- free(zConverted);
- return SQLITE_CANTOPEN_BKPT;
+ osCloseHandle(h);
+ sqlite3_free(zConverted);
+ return rc;
}
if( isTemp ){
pFile->zDeleteOnClose = zConverted;
}else
#endif
{
- free(zConverted);
+ sqlite3_free(zConverted);
+ }
+
+ pFile->pMethod = &winIoMethod;
+ pFile->pVfs = pVfs;
+ pFile->h = h;
+ if( sqlite3_uri_boolean(zName, "psow", SQLITE_POWERSAFE_OVERWRITE) ){
+ pFile->ctrlFlags |= WINFILE_PSOW;
}
+ pFile->lastErrno = NO_ERROR;
+ pFile->zPath = zName;
OpenCounter(+1);
return rc;
@@ -33761,7 +34031,7 @@ static int winOpen(
/*
** Delete the named file.
**
-** Note that windows does not allow a file to be deleted if some other
+** Note that Windows does not allow a file to be deleted if some other
** process has it open. Sometimes a virus scanner or indexing program
** will open a journal file shortly after it is created in order to do
** whatever it does. While this other process is holding the
@@ -33770,15 +34040,15 @@ static int winOpen(
** to MX_DELETION_ATTEMPTs deletion attempts are run before giving
** up and returning an error.
*/
-#define MX_DELETION_ATTEMPTS 5
static int winDelete(
sqlite3_vfs *pVfs, /* Not used on win32 */
const char *zFilename, /* Name of file to delete */
int syncDir /* Not used on win32 */
){
int cnt = 0;
- DWORD rc;
- DWORD error = 0;
+ int rc;
+ DWORD attr;
+ DWORD lastErrno;
void *zConverted;
UNUSED_PARAMETER(pVfs);
UNUSED_PARAMETER(syncDir);
@@ -33786,41 +34056,95 @@ static int winDelete(
SimulateIOError(return SQLITE_IOERR_DELETE);
zConverted = convertUtf8Filename(zFilename);
if( zConverted==0 ){
- return SQLITE_NOMEM;
+ return SQLITE_IOERR_NOMEM;
}
if( isNT() ){
- do{
- DeleteFileW(zConverted);
- }while( ( ((rc = GetFileAttributesW(zConverted)) != INVALID_FILE_ATTRIBUTES)
- || ((error = GetLastError()) == ERROR_ACCESS_DENIED))
- && (++cnt < MX_DELETION_ATTEMPTS)
- && (Sleep(100), 1) );
-/* isNT() is 1 if SQLITE_OS_WINCE==1, so this else is never executed.
-** Since the ASCII version of these Windows API do not exist for WINCE,
-** it's important to not reference them for WINCE builds.
-*/
-#if SQLITE_OS_WINCE==0
- }else{
- do{
- DeleteFileA(zConverted);
- }while( ( ((rc = GetFileAttributesA(zConverted)) != INVALID_FILE_ATTRIBUTES)
- || ((error = GetLastError()) == ERROR_ACCESS_DENIED))
- && (++cnt < MX_DELETION_ATTEMPTS)
- && (Sleep(100), 1) );
+ do {
+#if SQLITE_OS_WINRT
+ WIN32_FILE_ATTRIBUTE_DATA sAttrData;
+ memset(&sAttrData, 0, sizeof(sAttrData));
+ if ( osGetFileAttributesExW(zConverted, GetFileExInfoStandard,
+ &sAttrData) ){
+ attr = sAttrData.dwFileAttributes;
+ }else{
+ lastErrno = osGetLastError();
+ if( lastErrno==ERROR_FILE_NOT_FOUND
+ || lastErrno==ERROR_PATH_NOT_FOUND ){
+ rc = SQLITE_IOERR_DELETE_NOENT; /* Already gone? */
+ }else{
+ rc = SQLITE_ERROR;
+ }
+ break;
+ }
+#else
+ attr = osGetFileAttributesW(zConverted);
+#endif
+ if ( attr==INVALID_FILE_ATTRIBUTES ){
+ lastErrno = osGetLastError();
+ if( lastErrno==ERROR_FILE_NOT_FOUND
+ || lastErrno==ERROR_PATH_NOT_FOUND ){
+ rc = SQLITE_IOERR_DELETE_NOENT; /* Already gone? */
+ }else{
+ rc = SQLITE_ERROR;
+ }
+ break;
+ }
+ if ( attr&FILE_ATTRIBUTE_DIRECTORY ){
+ rc = SQLITE_ERROR; /* Files only. */
+ break;
+ }
+ if ( osDeleteFileW(zConverted) ){
+ rc = SQLITE_OK; /* Deleted OK. */
+ break;
+ }
+ if ( !retryIoerr(&cnt, &lastErrno) ){
+ rc = SQLITE_ERROR; /* No more retries. */
+ break;
+ }
+ } while(1);
+ }
+#ifdef SQLITE_WIN32_HAS_ANSI
+ else{
+ do {
+ attr = osGetFileAttributesA(zConverted);
+ if ( attr==INVALID_FILE_ATTRIBUTES ){
+ lastErrno = osGetLastError();
+ if( lastErrno==ERROR_FILE_NOT_FOUND
+ || lastErrno==ERROR_PATH_NOT_FOUND ){
+ rc = SQLITE_IOERR_DELETE_NOENT; /* Already gone? */
+ }else{
+ rc = SQLITE_ERROR;
+ }
+ break;
+ }
+ if ( attr&FILE_ATTRIBUTE_DIRECTORY ){
+ rc = SQLITE_ERROR; /* Files only. */
+ break;
+ }
+ if ( osDeleteFileA(zConverted) ){
+ rc = SQLITE_OK; /* Deleted OK. */
+ break;
+ }
+ if ( !retryIoerr(&cnt, &lastErrno) ){
+ rc = SQLITE_ERROR; /* No more retries. */
+ break;
+ }
+ } while(1);
+ }
#endif
+ if( rc && rc!=SQLITE_IOERR_DELETE_NOENT ){
+ rc = winLogError(SQLITE_IOERR_DELETE, lastErrno,
+ "winDelete", zFilename);
+ }else{
+ logIoerr(cnt);
}
- free(zConverted);
- OSTRACE(("DELETE \"%s\" %s\n", zFilename,
- ( (rc==INVALID_FILE_ATTRIBUTES) && (error==ERROR_FILE_NOT_FOUND)) ?
- "ok" : "failed" ));
-
- return ( (rc == INVALID_FILE_ATTRIBUTES)
- && (error == ERROR_FILE_NOT_FOUND)) ? SQLITE_OK :
- winLogError(SQLITE_IOERR_DELETE, "winDelete", zFilename);
+ sqlite3_free(zConverted);
+ OSTRACE(("DELETE \"%s\" %s\n", zFilename, (rc ? "failed" : "ok" )));
+ return rc;
}
/*
-** Check the existance and status of a file.
+** Check the existence and status of a file.
*/
static int winAccess(
sqlite3_vfs *pVfs, /* Not used on win32 */
@@ -33830,20 +34154,23 @@ static int winAccess(
){
DWORD attr;
int rc = 0;
+ DWORD lastErrno;
void *zConverted;
UNUSED_PARAMETER(pVfs);
SimulateIOError( return SQLITE_IOERR_ACCESS; );
zConverted = convertUtf8Filename(zFilename);
if( zConverted==0 ){
- return SQLITE_NOMEM;
+ return SQLITE_IOERR_NOMEM;
}
if( isNT() ){
+ int cnt = 0;
WIN32_FILE_ATTRIBUTE_DATA sAttrData;
memset(&sAttrData, 0, sizeof(sAttrData));
- if( GetFileAttributesExW((WCHAR*)zConverted,
+ while( !(rc = osGetFileAttributesExW((LPCWSTR)zConverted,
GetFileExInfoStandard,
- &sAttrData) ){
+ &sAttrData)) && retryIoerr(&cnt, &lastErrno) ){}
+ if( rc ){
/* For an SQLITE_ACCESS_EXISTS query, treat a zero-length file
** as if it does not exist.
*/
@@ -33855,31 +34182,30 @@ static int winAccess(
attr = sAttrData.dwFileAttributes;
}
}else{
- if( GetLastError()!=ERROR_FILE_NOT_FOUND ){
- winLogError(SQLITE_IOERR_ACCESS, "winAccess", zFilename);
- free(zConverted);
+ logIoerr(cnt);
+ if( lastErrno!=ERROR_FILE_NOT_FOUND && lastErrno!=ERROR_PATH_NOT_FOUND ){
+ winLogError(SQLITE_IOERR_ACCESS, lastErrno, "winAccess", zFilename);
+ sqlite3_free(zConverted);
return SQLITE_IOERR_ACCESS;
}else{
attr = INVALID_FILE_ATTRIBUTES;
}
}
-/* isNT() is 1 if SQLITE_OS_WINCE==1, so this else is never executed.
-** Since the ASCII version of these Windows API do not exist for WINCE,
-** it's important to not reference them for WINCE builds.
-*/
-#if SQLITE_OS_WINCE==0
- }else{
- attr = GetFileAttributesA((char*)zConverted);
-#endif
}
- free(zConverted);
+#ifdef SQLITE_WIN32_HAS_ANSI
+ else{
+ attr = osGetFileAttributesA((char*)zConverted);
+ }
+#endif
+ sqlite3_free(zConverted);
switch( flags ){
case SQLITE_ACCESS_READ:
case SQLITE_ACCESS_EXISTS:
rc = attr!=INVALID_FILE_ATTRIBUTES;
break;
case SQLITE_ACCESS_READWRITE:
- rc = (attr & FILE_ATTRIBUTE_READONLY)==0;
+ rc = attr!=INVALID_FILE_ATTRIBUTES &&
+ (attr & FILE_ATTRIBUTE_READONLY)==0;
break;
default:
assert(!"Invalid flags argument");
@@ -33890,6 +34216,43 @@ static int winAccess(
/*
+** Returns non-zero if the specified path name should be used verbatim. If
+** non-zero is returned from this function, the calling function must simply
+** use the provided path name verbatim -OR- resolve it into a full path name
+** using the GetFullPathName Win32 API function (if available).
+*/
+static BOOL winIsVerbatimPathname(
+ const char *zPathname
+){
+ /*
+ ** If the path name starts with a forward slash or a backslash, it is either
+ ** a legal UNC name, a volume relative path, or an absolute path name in the
+ ** "Unix" format on Windows. There is no easy way to differentiate between
+ ** the final two cases; therefore, we return the safer return value of TRUE
+ ** so that callers of this function will simply use it verbatim.
+ */
+ if ( zPathname[0]=='/' || zPathname[0]=='\\' ){
+ return TRUE;
+ }
+
+ /*
+ ** If the path name starts with a letter and a colon it is either a volume
+ ** relative path or an absolute path. Callers of this function must not
+ ** attempt to treat it as a relative path name (i.e. they should simply use
+ ** it verbatim).
+ */
+ if ( sqlite3Isalpha(zPathname[0]) && zPathname[1]==':' ){
+ return TRUE;
+ }
+
+ /*
+ ** If we get to this point, the path name should almost certainly be a purely
+ ** relative one (i.e. not a UNC name, not absolute, and not volume relative).
+ */
+ return FALSE;
+}
+
+/*
** Turn a relative pathname into a full pathname. Write the full
** pathname into zOut[]. zOut[] will be at least pVfs->mxPathname
** bytes in size.
@@ -33904,20 +34267,48 @@ static int winFullPathname(
#if defined(__CYGWIN__)
SimulateIOError( return SQLITE_ERROR );
UNUSED_PARAMETER(nFull);
- cygwin_conv_to_full_win32_path(zRelative, zFull);
+ assert( pVfs->mxPathname>=MAX_PATH );
+ assert( nFull>=pVfs->mxPathname );
+ if ( sqlite3_data_directory && !winIsVerbatimPathname(zRelative) ){
+ /*
+ ** NOTE: We are dealing with a relative path name and the data
+ ** directory has been set. Therefore, use it as the basis
+ ** for converting the relative path name to an absolute
+ ** one by prepending the data directory and a slash.
+ */
+ char zOut[MAX_PATH+1];
+ memset(zOut, 0, MAX_PATH+1);
+ cygwin_conv_path(CCP_POSIX_TO_WIN_A|CCP_RELATIVE, zRelative, zOut,
+ MAX_PATH+1);
+ sqlite3_snprintf(MIN(nFull, pVfs->mxPathname), zFull, "%s\\%s",
+ sqlite3_data_directory, zOut);
+ }else{
+ cygwin_conv_path(CCP_POSIX_TO_WIN_A, zRelative, zFull, nFull);
+ }
return SQLITE_OK;
#endif
-#if SQLITE_OS_WINCE
+#if (SQLITE_OS_WINCE || SQLITE_OS_WINRT) && !defined(__CYGWIN__)
SimulateIOError( return SQLITE_ERROR );
- UNUSED_PARAMETER(nFull);
/* WinCE has no concept of a relative pathname, or so I am told. */
- sqlite3_snprintf(pVfs->mxPathname, zFull, "%s", zRelative);
+ /* WinRT has no way to convert a relative path to an absolute one. */
+ if ( sqlite3_data_directory && !winIsVerbatimPathname(zRelative) ){
+ /*
+ ** NOTE: We are dealing with a relative path name and the data
+ ** directory has been set. Therefore, use it as the basis
+ ** for converting the relative path name to an absolute
+ ** one by prepending the data directory and a backslash.
+ */
+ sqlite3_snprintf(MIN(nFull, pVfs->mxPathname), zFull, "%s\\%s",
+ sqlite3_data_directory, zRelative);
+ }else{
+ sqlite3_snprintf(MIN(nFull, pVfs->mxPathname), zFull, "%s", zRelative);
+ }
return SQLITE_OK;
#endif
-#if !SQLITE_OS_WINCE && !defined(__CYGWIN__)
- int nByte;
+#if !SQLITE_OS_WINCE && !SQLITE_OS_WINRT && !defined(__CYGWIN__)
+ DWORD nByte;
void *zConverted;
char *zOut;
@@ -33934,119 +34325,87 @@ static int winFullPathname(
** current working directory has been unlinked.
*/
SimulateIOError( return SQLITE_ERROR );
- UNUSED_PARAMETER(nFull);
+ if ( sqlite3_data_directory && !winIsVerbatimPathname(zRelative) ){
+ /*
+ ** NOTE: We are dealing with a relative path name and the data
+ ** directory has been set. Therefore, use it as the basis
+ ** for converting the relative path name to an absolute
+ ** one by prepending the data directory and a backslash.
+ */
+ sqlite3_snprintf(MIN(nFull, pVfs->mxPathname), zFull, "%s\\%s",
+ sqlite3_data_directory, zRelative);
+ return SQLITE_OK;
+ }
zConverted = convertUtf8Filename(zRelative);
+ if( zConverted==0 ){
+ return SQLITE_IOERR_NOMEM;
+ }
if( isNT() ){
- WCHAR *zTemp;
- nByte = GetFullPathNameW((WCHAR*)zConverted, 0, 0, 0) + 3;
- zTemp = malloc( nByte*sizeof(zTemp[0]) );
+ LPWSTR zTemp;
+ nByte = osGetFullPathNameW((LPCWSTR)zConverted, 0, 0, 0);
+ if( nByte==0 ){
+ winLogError(SQLITE_ERROR, osGetLastError(),
+ "GetFullPathNameW1", zConverted);
+ sqlite3_free(zConverted);
+ return SQLITE_CANTOPEN_FULLPATH;
+ }
+ nByte += 3;
+ zTemp = sqlite3MallocZero( nByte*sizeof(zTemp[0]) );
if( zTemp==0 ){
- free(zConverted);
- return SQLITE_NOMEM;
- }
- GetFullPathNameW((WCHAR*)zConverted, nByte, zTemp, 0);
- free(zConverted);
+ sqlite3_free(zConverted);
+ return SQLITE_IOERR_NOMEM;
+ }
+ nByte = osGetFullPathNameW((LPCWSTR)zConverted, nByte, zTemp, 0);
+ if( nByte==0 ){
+ winLogError(SQLITE_ERROR, osGetLastError(),
+ "GetFullPathNameW2", zConverted);
+ sqlite3_free(zConverted);
+ sqlite3_free(zTemp);
+ return SQLITE_CANTOPEN_FULLPATH;
+ }
+ sqlite3_free(zConverted);
zOut = unicodeToUtf8(zTemp);
- free(zTemp);
-/* isNT() is 1 if SQLITE_OS_WINCE==1, so this else is never executed.
-** Since the ASCII version of these Windows API do not exist for WINCE,
-** it's important to not reference them for WINCE builds.
-*/
-#if SQLITE_OS_WINCE==0
- }else{
+ sqlite3_free(zTemp);
+ }
+#ifdef SQLITE_WIN32_HAS_ANSI
+ else{
char *zTemp;
- nByte = GetFullPathNameA((char*)zConverted, 0, 0, 0) + 3;
- zTemp = malloc( nByte*sizeof(zTemp[0]) );
+ nByte = osGetFullPathNameA((char*)zConverted, 0, 0, 0);
+ if( nByte==0 ){
+ winLogError(SQLITE_ERROR, osGetLastError(),
+ "GetFullPathNameA1", zConverted);
+ sqlite3_free(zConverted);
+ return SQLITE_CANTOPEN_FULLPATH;
+ }
+ nByte += 3;
+ zTemp = sqlite3MallocZero( nByte*sizeof(zTemp[0]) );
if( zTemp==0 ){
- free(zConverted);
- return SQLITE_NOMEM;
- }
- GetFullPathNameA((char*)zConverted, nByte, zTemp, 0);
- free(zConverted);
+ sqlite3_free(zConverted);
+ return SQLITE_IOERR_NOMEM;
+ }
+ nByte = osGetFullPathNameA((char*)zConverted, nByte, zTemp, 0);
+ if( nByte==0 ){
+ winLogError(SQLITE_ERROR, osGetLastError(),
+ "GetFullPathNameA2", zConverted);
+ sqlite3_free(zConverted);
+ sqlite3_free(zTemp);
+ return SQLITE_CANTOPEN_FULLPATH;
+ }
+ sqlite3_free(zConverted);
zOut = sqlite3_win32_mbcs_to_utf8(zTemp);
- free(zTemp);
-#endif
+ sqlite3_free(zTemp);
}
+#endif
if( zOut ){
- sqlite3_snprintf(pVfs->mxPathname, zFull, "%s", zOut);
- free(zOut);
+ sqlite3_snprintf(MIN(nFull, pVfs->mxPathname), zFull, "%s", zOut);
+ sqlite3_free(zOut);
return SQLITE_OK;
}else{
- return SQLITE_NOMEM;
+ return SQLITE_IOERR_NOMEM;
}
#endif
}
-/*
-** Get the sector size of the device used to store
-** file.
-*/
-static int getSectorSize(
- sqlite3_vfs *pVfs,
- const char *zRelative /* UTF-8 file name */
-){
- DWORD bytesPerSector = SQLITE_DEFAULT_SECTOR_SIZE;
- /* GetDiskFreeSpace is not supported under WINCE */
-#if SQLITE_OS_WINCE
- UNUSED_PARAMETER(pVfs);
- UNUSED_PARAMETER(zRelative);
-#else
- char zFullpath[MAX_PATH+1];
- int rc;
- DWORD dwRet = 0;
- DWORD dwDummy;
-
- /*
- ** We need to get the full path name of the file
- ** to get the drive letter to look up the sector
- ** size.
- */
- SimulateIOErrorBenign(1);
- rc = winFullPathname(pVfs, zRelative, MAX_PATH, zFullpath);
- SimulateIOErrorBenign(0);
- if( rc == SQLITE_OK )
- {
- void *zConverted = convertUtf8Filename(zFullpath);
- if( zConverted ){
- if( isNT() ){
- /* trim path to just drive reference */
- WCHAR *p = zConverted;
- for(;*p;p++){
- if( *p == '\\' ){
- *p = '\0';
- break;
- }
- }
- dwRet = GetDiskFreeSpaceW((WCHAR*)zConverted,
- &dwDummy,
- &bytesPerSector,
- &dwDummy,
- &dwDummy);
- }else{
- /* trim path to just drive reference */
- char *p = (char *)zConverted;
- for(;*p;p++){
- if( *p == '\\' ){
- *p = '\0';
- break;
- }
- }
- dwRet = GetDiskFreeSpaceA((char*)zConverted,
- &dwDummy,
- &bytesPerSector,
- &dwDummy,
- &dwDummy);
- }
- free(zConverted);
- }
- if( !dwRet ){
- bytesPerSector = SQLITE_DEFAULT_SECTOR_SIZE;
- }
- }
-#endif
- return (int) bytesPerSector;
-}
-
#ifndef SQLITE_OMIT_LOAD_EXTENSION
/*
** Interfaces for opening a shared library, finding entry points
@@ -34064,37 +34423,31 @@ static void *winDlOpen(sqlite3_vfs *pVfs, const char *zFilename){
return 0;
}
if( isNT() ){
- h = LoadLibraryW((WCHAR*)zConverted);
-/* isNT() is 1 if SQLITE_OS_WINCE==1, so this else is never executed.
-** Since the ASCII version of these Windows API do not exist for WINCE,
-** it's important to not reference them for WINCE builds.
-*/
-#if SQLITE_OS_WINCE==0
- }else{
- h = LoadLibraryA((char*)zConverted);
+#if SQLITE_OS_WINRT
+ h = osLoadPackagedLibrary((LPCWSTR)zConverted, 0);
+#else
+ h = osLoadLibraryW((LPCWSTR)zConverted);
#endif
}
- free(zConverted);
+#ifdef SQLITE_WIN32_HAS_ANSI
+ else{
+ h = osLoadLibraryA((char*)zConverted);
+ }
+#endif
+ sqlite3_free(zConverted);
return (void*)h;
}
static void winDlError(sqlite3_vfs *pVfs, int nBuf, char *zBufOut){
UNUSED_PARAMETER(pVfs);
- getLastErrorMsg(nBuf, zBufOut);
+ getLastErrorMsg(osGetLastError(), nBuf, zBufOut);
}
-void (*winDlSym(sqlite3_vfs *pVfs, void *pHandle, const char *zSymbol))(void){
+static void (*winDlSym(sqlite3_vfs *pVfs,void *pH,const char *zSym))(void){
UNUSED_PARAMETER(pVfs);
-#if SQLITE_OS_WINCE
- /* The GetProcAddressA() routine is only available on wince. */
- return (void(*)(void))GetProcAddressA((HANDLE)pHandle, zSymbol);
-#else
- /* All other windows platforms expect GetProcAddress() to take
- ** an Ansi string regardless of the _UNICODE setting */
- return (void(*)(void))GetProcAddress((HANDLE)pHandle, zSymbol);
-#endif
+ return (void(*)(void))osGetProcAddressA((HANDLE)pH, zSym);
}
-void winDlClose(sqlite3_vfs *pVfs, void *pHandle){
+static void winDlClose(sqlite3_vfs *pVfs, void *pHandle){
UNUSED_PARAMETER(pVfs);
- FreeLibrary((HANDLE)pHandle);
+ osFreeLibrary((HANDLE)pHandle);
}
#else /* if SQLITE_OMIT_LOAD_EXTENSION is defined: */
#define winDlOpen 0
@@ -34116,23 +34469,31 @@ static int winRandomness(sqlite3_vfs *pVfs, int nBuf, char *zBuf){
#else
if( sizeof(SYSTEMTIME)<=nBuf-n ){
SYSTEMTIME x;
- GetSystemTime(&x);
+ osGetSystemTime(&x);
memcpy(&zBuf[n], &x, sizeof(x));
n += sizeof(x);
}
if( sizeof(DWORD)<=nBuf-n ){
- DWORD pid = GetCurrentProcessId();
+ DWORD pid = osGetCurrentProcessId();
memcpy(&zBuf[n], &pid, sizeof(pid));
n += sizeof(pid);
}
+#if SQLITE_OS_WINRT
+ if( sizeof(ULONGLONG)<=nBuf-n ){
+ ULONGLONG cnt = osGetTickCount64();
+ memcpy(&zBuf[n], &cnt, sizeof(cnt));
+ n += sizeof(cnt);
+ }
+#else
if( sizeof(DWORD)<=nBuf-n ){
- DWORD cnt = GetTickCount();
+ DWORD cnt = osGetTickCount();
memcpy(&zBuf[n], &cnt, sizeof(cnt));
n += sizeof(cnt);
}
+#endif
if( sizeof(LARGE_INTEGER)<=nBuf-n ){
LARGE_INTEGER i;
- QueryPerformanceCounter(&i);
+ osQueryPerformanceCounter(&i);
memcpy(&zBuf[n], &i, sizeof(i));
n += sizeof(i);
}
@@ -34145,7 +34506,7 @@ static int winRandomness(sqlite3_vfs *pVfs, int nBuf, char *zBuf){
** Sleep for a little while. Return the amount of time slept.
*/
static int winSleep(sqlite3_vfs *pVfs, int microsec){
- Sleep((microsec+999)/1000);
+ sqlite3_win32_sleep((microsec+999)/1000);
UNUSED_PARAMETER(pVfs);
return ((microsec+999)/1000)*1000;
}
@@ -34166,7 +34527,8 @@ SQLITE_API int sqlite3_current_time = 0; /* Fake system time in seconds since 1
** epoch of noon in Greenwich on November 24, 4714 B.C according to the
** proleptic Gregorian calendar.
**
-** On success, return 0. Return 1 if the time and date cannot be found.
+** On success, return SQLITE_OK. Return SQLITE_ERROR if the time and date
+** cannot be found.
*/
static int winCurrentTimeInt64(sqlite3_vfs *pVfs, sqlite3_int64 *piNow){
/* FILETIME structure is a 64-bit value representing the number of
@@ -34179,17 +34541,18 @@ static int winCurrentTimeInt64(sqlite3_vfs *pVfs, sqlite3_int64 *piNow){
#endif
/* 2^32 - to avoid use of LL and warnings in gcc */
static const sqlite3_int64 max32BitValue =
- (sqlite3_int64)2000000000 + (sqlite3_int64)2000000000 + (sqlite3_int64)294967296;
+ (sqlite3_int64)2000000000 + (sqlite3_int64)2000000000 +
+ (sqlite3_int64)294967296;
#if SQLITE_OS_WINCE
SYSTEMTIME time;
- GetSystemTime(&time);
+ osGetSystemTime(&time);
/* if SystemTimeToFileTime() fails, it returns zero. */
- if (!SystemTimeToFileTime(&time,&ft)){
- return 1;
+ if (!osSystemTimeToFileTime(&time,&ft)){
+ return SQLITE_ERROR;
}
#else
- GetSystemTimeAsFileTime( &ft );
+ osGetSystemTimeAsFileTime( &ft );
#endif
*piNow = winFiletimeEpoch +
@@ -34202,7 +34565,7 @@ static int winCurrentTimeInt64(sqlite3_vfs *pVfs, sqlite3_int64 *piNow){
}
#endif
UNUSED_PARAMETER(pVfs);
- return 0;
+ return SQLITE_OK;
}
/*
@@ -34210,7 +34573,7 @@ static int winCurrentTimeInt64(sqlite3_vfs *pVfs, sqlite3_int64 *piNow){
** current time and date as a Julian Day number into *prNow and
** return 0. Return 1 if the time and date cannot be found.
*/
-int winCurrentTime(sqlite3_vfs *pVfs, double *prNow){
+static int winCurrentTime(sqlite3_vfs *pVfs, double *prNow){
int rc;
sqlite3_int64 i;
rc = winCurrentTimeInt64(pVfs, &i);
@@ -34222,8 +34585,8 @@ int winCurrentTime(sqlite3_vfs *pVfs, double *prNow){
/*
** The idea is that this function works like a combination of
-** GetLastError() and FormatMessage() on windows (or errno and
-** strerror_r() on unix). After an error is returned by an OS
+** GetLastError() and FormatMessage() on Windows (or errno and
+** strerror_r() on Unix). After an error is returned by an OS
** function, SQLite calls this function with zBuf pointing to
** a buffer of nBuf bytes. The OS layer should populate the
** buffer with a nul-terminated UTF-8 encoded error message
@@ -34252,11 +34615,9 @@ int winCurrentTime(sqlite3_vfs *pVfs, double *prNow){
*/
static int winGetLastError(sqlite3_vfs *pVfs, int nBuf, char *zBuf){
UNUSED_PARAMETER(pVfs);
- return getLastErrorMsg(nBuf, zBuf);
+ return getLastErrorMsg(osGetLastError(), nBuf, zBuf);
}
-
-
/*
** Initialize and deinitialize the operating system interface.
*/
@@ -34281,22 +34642,37 @@ SQLITE_API int sqlite3_os_init(void){
winCurrentTime, /* xCurrentTime */
winGetLastError, /* xGetLastError */
winCurrentTimeInt64, /* xCurrentTimeInt64 */
- 0, /* xSetSystemCall */
- 0, /* xGetSystemCall */
- 0, /* xNextSystemCall */
+ winSetSystemCall, /* xSetSystemCall */
+ winGetSystemCall, /* xGetSystemCall */
+ winNextSystemCall, /* xNextSystemCall */
};
+ /* Double-check that the aSyscall[] array has been constructed
+ ** correctly. See ticket [bb3a86e890c8e96ab] */
+ assert( ArraySize(aSyscall)==74 );
+
#ifndef SQLITE_OMIT_WAL
/* get memory map allocation granularity */
memset(&winSysInfo, 0, sizeof(SYSTEM_INFO));
- GetSystemInfo(&winSysInfo);
+#if SQLITE_OS_WINRT
+ osGetNativeSystemInfo(&winSysInfo);
+#else
+ osGetSystemInfo(&winSysInfo);
+#endif
assert(winSysInfo.dwAllocationGranularity > 0);
#endif
sqlite3_vfs_register(&winVfs, 1);
return SQLITE_OK;
}
+
SQLITE_API int sqlite3_os_end(void){
+#if SQLITE_OS_WINRT
+ if( sleepObj!=NULL ){
+ osCloseHandle(sleepObj);
+ sleepObj = NULL;
+ }
+#endif
return SQLITE_OK;
}
@@ -34377,7 +34753,7 @@ SQLITE_API int sqlite3_os_end(void){
/*
** A bitmap is an instance of the following structure.
**
-** This bitmap records the existance of zero or more bits
+** This bitmap records the existence of zero or more bits
** with values between 1 and iSize, inclusive.
**
** There are three possible representations of the bitmap.
@@ -34645,10 +35021,9 @@ SQLITE_PRIVATE int sqlite3BitvecBuiltinTest(int sz, int *aOp){
/* Allocate the Bitvec to be tested and a linear array of
** bits to act as the reference */
pBitvec = sqlite3BitvecCreate( sz );
- pV = sqlite3_malloc( (sz+7)/8 + 1 );
+ pV = sqlite3MallocZero( (sz+7)/8 + 1 );
pTmpSpace = sqlite3_malloc(BITVEC_SZ);
if( pBitvec==0 || pV==0 || pTmpSpace==0 ) goto bitvec_end;
- memset(pV, 0, (sz+7)/8 + 1);
/* NULL pBitvec tests */
sqlite3BitvecSet(0, 1);
@@ -34735,7 +35110,7 @@ struct PCache {
PgHdr *pDirty, *pDirtyTail; /* List of dirty pages in LRU order */
PgHdr *pSynced; /* Last synced page in dirty page list */
int nRef; /* Number of referenced pages */
- int nMax; /* Configured cache size */
+ int szCache; /* Configured cache size */
int szPage; /* Size of every page in this cache */
int szExtra; /* Size of extra space for each page */
int bPurgeable; /* True if pages are on backing store */
@@ -34846,7 +35221,7 @@ static void pcacheUnpin(PgHdr *p){
if( p->pgno==1 ){
pCache->pPage1 = 0;
}
- sqlite3GlobalConfig.pcache.xUnpin(pCache->pCache, p, 0);
+ sqlite3GlobalConfig.pcache2.xUnpin(pCache->pCache, p->pPage, 0);
}
}
@@ -34856,18 +35231,18 @@ static void pcacheUnpin(PgHdr *p){
** functions are threadsafe.
*/
SQLITE_PRIVATE int sqlite3PcacheInitialize(void){
- if( sqlite3GlobalConfig.pcache.xInit==0 ){
+ if( sqlite3GlobalConfig.pcache2.xInit==0 ){
/* IMPLEMENTATION-OF: R-26801-64137 If the xInit() method is NULL, then the
** built-in default page cache is used instead of the application defined
** page cache. */
sqlite3PCacheSetDefault();
}
- return sqlite3GlobalConfig.pcache.xInit(sqlite3GlobalConfig.pcache.pArg);
+ return sqlite3GlobalConfig.pcache2.xInit(sqlite3GlobalConfig.pcache2.pArg);
}
SQLITE_PRIVATE void sqlite3PcacheShutdown(void){
- if( sqlite3GlobalConfig.pcache.xShutdown ){
+ if( sqlite3GlobalConfig.pcache2.xShutdown ){
/* IMPLEMENTATION-OF: R-26000-56589 The xShutdown() method may be NULL. */
- sqlite3GlobalConfig.pcache.xShutdown(sqlite3GlobalConfig.pcache.pArg);
+ sqlite3GlobalConfig.pcache2.xShutdown(sqlite3GlobalConfig.pcache2.pArg);
}
}
@@ -34896,7 +35271,7 @@ SQLITE_PRIVATE void sqlite3PcacheOpen(
p->bPurgeable = bPurgeable;
p->xStress = xStress;
p->pStress = pStress;
- p->nMax = 100;
+ p->szCache = 100;
}
/*
@@ -34906,7 +35281,7 @@ SQLITE_PRIVATE void sqlite3PcacheOpen(
SQLITE_PRIVATE void sqlite3PcacheSetPageSize(PCache *pCache, int szPage){
assert( pCache->nRef==0 && pCache->pDirty==0 );
if( pCache->pCache ){
- sqlite3GlobalConfig.pcache.xDestroy(pCache->pCache);
+ sqlite3GlobalConfig.pcache2.xDestroy(pCache->pCache);
pCache->pCache = 0;
pCache->pPage1 = 0;
}
@@ -34914,6 +35289,17 @@ SQLITE_PRIVATE void sqlite3PcacheSetPageSize(PCache *pCache, int szPage){
}
/*
+** Compute the number of pages of cache requested.
+*/
+static int numberOfCachePages(PCache *p){
+ if( p->szCache>=0 ){
+ return p->szCache;
+ }else{
+ return (int)((-1024*(i64)p->szCache)/(p->szPage+p->szExtra));
+ }
+}
+
+/*
** Try to obtain a page from the cache.
*/
SQLITE_PRIVATE int sqlite3PcacheFetch(
@@ -34922,7 +35308,8 @@ SQLITE_PRIVATE int sqlite3PcacheFetch(
int createFlag, /* If true, create page if it does not exist already */
PgHdr **ppPage /* Write the page here */
){
- PgHdr *pPage = 0;
+ sqlite3_pcache_page *pPage = 0;
+ PgHdr *pPgHdr = 0;
int eCreate;
assert( pCache!=0 );
@@ -34934,19 +35321,19 @@ SQLITE_PRIVATE int sqlite3PcacheFetch(
*/
if( !pCache->pCache && createFlag ){
sqlite3_pcache *p;
- int nByte;
- nByte = pCache->szPage + pCache->szExtra + sizeof(PgHdr);
- p = sqlite3GlobalConfig.pcache.xCreate(nByte, pCache->bPurgeable);
+ p = sqlite3GlobalConfig.pcache2.xCreate(
+ pCache->szPage, pCache->szExtra + sizeof(PgHdr), pCache->bPurgeable
+ );
if( !p ){
return SQLITE_NOMEM;
}
- sqlite3GlobalConfig.pcache.xCachesize(p, pCache->nMax);
+ sqlite3GlobalConfig.pcache2.xCachesize(p, numberOfCachePages(pCache));
pCache->pCache = p;
}
eCreate = createFlag * (1 + (!pCache->bPurgeable || !pCache->pDirty));
if( pCache->pCache ){
- pPage = sqlite3GlobalConfig.pcache.xFetch(pCache->pCache, pgno, eCreate);
+ pPage = sqlite3GlobalConfig.pcache2.xFetch(pCache->pCache, pgno, eCreate);
}
if( !pPage && eCreate==1 ){
@@ -34973,7 +35360,7 @@ SQLITE_PRIVATE int sqlite3PcacheFetch(
"spill page %d making room for %d - cache used: %d/%d",
pPg->pgno, pgno,
sqlite3GlobalConfig.pcache.xPagecount(pCache->pCache),
- pCache->nMax);
+ numberOfCachePages(pCache));
#endif
rc = pCache->xStress(pCache->pStress, pPg);
if( rc!=SQLITE_OK && rc!=SQLITE_BUSY ){
@@ -34981,33 +35368,36 @@ SQLITE_PRIVATE int sqlite3PcacheFetch(
}
}
- pPage = sqlite3GlobalConfig.pcache.xFetch(pCache->pCache, pgno, 2);
+ pPage = sqlite3GlobalConfig.pcache2.xFetch(pCache->pCache, pgno, 2);
}
if( pPage ){
- if( !pPage->pData ){
- memset(pPage, 0, sizeof(PgHdr));
- pPage->pData = (void *)&pPage[1];
- pPage->pExtra = (void*)&((char *)pPage->pData)[pCache->szPage];
- memset(pPage->pExtra, 0, pCache->szExtra);
- pPage->pCache = pCache;
- pPage->pgno = pgno;
- }
- assert( pPage->pCache==pCache );
- assert( pPage->pgno==pgno );
- assert( pPage->pData==(void *)&pPage[1] );
- assert( pPage->pExtra==(void *)&((char *)&pPage[1])[pCache->szPage] );
-
- if( 0==pPage->nRef ){
+ pPgHdr = (PgHdr *)pPage->pExtra;
+
+ if( !pPgHdr->pPage ){
+ memset(pPgHdr, 0, sizeof(PgHdr));
+ pPgHdr->pPage = pPage;
+ pPgHdr->pData = pPage->pBuf;
+ pPgHdr->pExtra = (void *)&pPgHdr[1];
+ memset(pPgHdr->pExtra, 0, pCache->szExtra);
+ pPgHdr->pCache = pCache;
+ pPgHdr->pgno = pgno;
+ }
+ assert( pPgHdr->pCache==pCache );
+ assert( pPgHdr->pgno==pgno );
+ assert( pPgHdr->pData==pPage->pBuf );
+ assert( pPgHdr->pExtra==(void *)&pPgHdr[1] );
+
+ if( 0==pPgHdr->nRef ){
pCache->nRef++;
}
- pPage->nRef++;
+ pPgHdr->nRef++;
if( pgno==1 ){
- pCache->pPage1 = pPage;
+ pCache->pPage1 = pPgHdr;
}
}
- *ppPage = pPage;
- return (pPage==0 && eCreate) ? SQLITE_NOMEM : SQLITE_OK;
+ *ppPage = pPgHdr;
+ return (pPgHdr==0 && eCreate) ? SQLITE_NOMEM : SQLITE_OK;
}
/*
@@ -35054,7 +35444,7 @@ SQLITE_PRIVATE void sqlite3PcacheDrop(PgHdr *p){
if( p->pgno==1 ){
pCache->pPage1 = 0;
}
- sqlite3GlobalConfig.pcache.xUnpin(pCache->pCache, p, 1);
+ sqlite3GlobalConfig.pcache2.xUnpin(pCache->pCache, p->pPage, 1);
}
/*
@@ -35112,7 +35502,7 @@ SQLITE_PRIVATE void sqlite3PcacheMove(PgHdr *p, Pgno newPgno){
PCache *pCache = p->pCache;
assert( p->nRef>0 );
assert( newPgno>0 );
- sqlite3GlobalConfig.pcache.xRekey(pCache->pCache, p, p->pgno, newPgno);
+ sqlite3GlobalConfig.pcache2.xRekey(pCache->pCache, p->pPage, p->pgno,newPgno);
p->pgno = newPgno;
if( (p->flags&PGHDR_DIRTY) && (p->flags&PGHDR_NEED_SYNC) ){
pcacheRemoveFromDirtyList(p);
@@ -35149,7 +35539,7 @@ SQLITE_PRIVATE void sqlite3PcacheTruncate(PCache *pCache, Pgno pgno){
memset(pCache->pPage1->pData, 0, pCache->szPage);
pgno = 1;
}
- sqlite3GlobalConfig.pcache.xTruncate(pCache->pCache, pgno+1);
+ sqlite3GlobalConfig.pcache2.xTruncate(pCache->pCache, pgno+1);
}
}
@@ -35158,7 +35548,7 @@ SQLITE_PRIVATE void sqlite3PcacheTruncate(PCache *pCache, Pgno pgno){
*/
SQLITE_PRIVATE void sqlite3PcacheClose(PCache *pCache){
if( pCache->pCache ){
- sqlite3GlobalConfig.pcache.xDestroy(pCache->pCache);
+ sqlite3GlobalConfig.pcache2.xDestroy(pCache->pCache);
}
}
@@ -35270,7 +35660,7 @@ SQLITE_PRIVATE int sqlite3PcachePageRefcount(PgHdr *p){
SQLITE_PRIVATE int sqlite3PcachePagecount(PCache *pCache){
int nPage = 0;
if( pCache->pCache ){
- nPage = sqlite3GlobalConfig.pcache.xPagecount(pCache->pCache);
+ nPage = sqlite3GlobalConfig.pcache2.xPagecount(pCache->pCache);
}
return nPage;
}
@@ -35280,7 +35670,7 @@ SQLITE_PRIVATE int sqlite3PcachePagecount(PCache *pCache){
** Get the suggested cache-size value.
*/
SQLITE_PRIVATE int sqlite3PcacheGetCachesize(PCache *pCache){
- return pCache->nMax;
+ return numberOfCachePages(pCache);
}
#endif
@@ -35288,9 +35678,19 @@ SQLITE_PRIVATE int sqlite3PcacheGetCachesize(PCache *pCache){
** Set the suggested cache-size value.
*/
SQLITE_PRIVATE void sqlite3PcacheSetCachesize(PCache *pCache, int mxPage){
- pCache->nMax = mxPage;
+ pCache->szCache = mxPage;
if( pCache->pCache ){
- sqlite3GlobalConfig.pcache.xCachesize(pCache->pCache, mxPage);
+ sqlite3GlobalConfig.pcache2.xCachesize(pCache->pCache,
+ numberOfCachePages(pCache));
+ }
+}
+
+/*
+** Free up as much memory as possible from the page cache.
+*/
+SQLITE_PRIVATE void sqlite3PcacheShrink(PCache *pCache){
+ if( pCache->pCache ){
+ sqlite3GlobalConfig.pcache2.xShrink(pCache->pCache);
}
}
@@ -35351,7 +35751,7 @@ typedef struct PGroup PGroup;
** Mode 1 uses more memory (since PCache instances are not able to rob
** unused pages from other PCaches) but it also operates without a mutex,
** and is therefore often faster. Mode 2 requires a mutex in order to be
-** threadsafe, but is able recycle pages more efficient.
+** threadsafe, but recycles pages more efficiently.
**
** For mode (1), PGroup.mutex is NULL. For mode (2) there is only a single
** PGroup which is the pcache1.grp global variable and its mutex is
@@ -35359,10 +35759,10 @@ typedef struct PGroup PGroup;
*/
struct PGroup {
sqlite3_mutex *mutex; /* MUTEX_STATIC_LRU or NULL */
- int nMaxPage; /* Sum of nMax for purgeable caches */
- int nMinPage; /* Sum of nMin for purgeable caches */
- int mxPinned; /* nMaxpage + 10 - nMinPage */
- int nCurrentPage; /* Number of purgeable pages allocated */
+ unsigned int nMaxPage; /* Sum of nMax for purgeable caches */
+ unsigned int nMinPage; /* Sum of nMin for purgeable caches */
+ unsigned int mxPinned; /* nMaxpage + 10 - nMinPage */
+ unsigned int nCurrentPage; /* Number of purgeable pages allocated */
PgHdr1 *pLruHead, *pLruTail; /* LRU list of unpinned pages */
};
@@ -35377,15 +35777,17 @@ struct PGroup {
struct PCache1 {
/* Cache configuration parameters. Page size (szPage) and the purgeable
** flag (bPurgeable) are set when the cache is created. nMax may be
- ** modified at any time by a call to the pcache1CacheSize() method.
+ ** modified at any time by a call to the pcache1Cachesize() method.
** The PGroup mutex must be held when accessing nMax.
*/
PGroup *pGroup; /* PGroup this cache belongs to */
int szPage; /* Size of allocated pages in bytes */
+ int szExtra; /* Size of extra space in bytes */
int bPurgeable; /* True if cache is purgeable */
unsigned int nMin; /* Minimum number of pages reserved */
unsigned int nMax; /* Configured "cache_size" value */
unsigned int n90pct; /* nMax*9/10 */
+ unsigned int iMaxKey; /* Largest key seen since xTruncate() */
/* Hash table of all pages. The following variables may only be accessed
** when the accessor is holding the PGroup mutex.
@@ -35394,17 +35796,16 @@ struct PCache1 {
unsigned int nPage; /* Total number of pages in apHash */
unsigned int nHash; /* Number of slots in apHash[] */
PgHdr1 **apHash; /* Hash table for fast lookup by key */
-
- unsigned int iMaxKey; /* Largest key seen since xTruncate() */
};
/*
** Each cache entry is represented by an instance of the following
-** structure. A buffer of PgHdr1.pCache->szPage bytes is allocated
-** directly before this structure in memory (see the PGHDR1_TO_PAGE()
-** macro below).
+** structure. Unless SQLITE_PCACHE_SEPARATE_HEADER is defined, a buffer of
+** PgHdr1.pCache->szPage bytes is allocated directly before this structure
+** in memory.
*/
struct PgHdr1 {
+ sqlite3_pcache_page page;
unsigned int iKey; /* Key value (page number) */
PgHdr1 *pNext; /* Next in hash table chain */
PCache1 *pCache; /* Cache that currently owns this page */
@@ -35438,8 +35839,8 @@ static SQLITE_WSD struct PCacheGlobal {
void *pStart, *pEnd; /* Bounds of pagecache malloc range */
/* Above requires no mutex. Use mutex below for variable that follow. */
sqlite3_mutex *mutex; /* Mutex for accessing the following: */
- int nFreeSlot; /* Number of unused pcache slots */
PgFreeslot *pFree; /* Free page blocks */
+ int nFreeSlot; /* Number of unused pcache slots */
/* The following value requires a mutex to change. We skip the mutex on
** reading because (1) most platforms read a 32-bit integer atomically and
** (2) even if an incorrect value is read, no great harm is done since this
@@ -35455,21 +35856,6 @@ static SQLITE_WSD struct PCacheGlobal {
#define pcache1 (GLOBAL(struct PCacheGlobal, pcache1_g))
/*
-** When a PgHdr1 structure is allocated, the associated PCache1.szPage
-** bytes of data are located directly before it in memory (i.e. the total
-** size of the allocation is sizeof(PgHdr1)+PCache1.szPage byte). The
-** PGHDR1_TO_PAGE() macro takes a pointer to a PgHdr1 structure as
-** an argument and returns a pointer to the associated block of szPage
-** bytes. The PAGE_TO_PGHDR1() macro does the opposite: its argument is
-** a pointer to a block of szPage bytes of data and the return value is
-** a pointer to the associated PgHdr1 structure.
-**
-** assert( PGHDR1_TO_PAGE(PAGE_TO_PGHDR1(pCache, X))==X );
-*/
-#define PGHDR1_TO_PAGE(p) (void*)(((char*)p) - p->pCache->szPage)
-#define PAGE_TO_PGHDR1(c, p) (PgHdr1*)(((char*)p) + c->szPage)
-
-/*
** Macros to enter and leave the PCache LRU mutex.
*/
#define pcache1EnterMutex(X) sqlite3_mutex_enter((X)->mutex)
@@ -35537,12 +35923,14 @@ static void *pcache1Alloc(int nByte){
** it from sqlite3Malloc instead.
*/
p = sqlite3Malloc(nByte);
+#ifndef SQLITE_DISABLE_PAGECACHE_OVERFLOW_STATS
if( p ){
int sz = sqlite3MallocSize(p);
sqlite3_mutex_enter(pcache1.mutex);
sqlite3StatusAdd(SQLITE_STATUS_PAGECACHE_OVERFLOW, sz);
sqlite3_mutex_leave(pcache1.mutex);
}
+#endif
sqlite3MemdebugSetType(p, MEMTYPE_PCACHE);
}
return p;
@@ -35551,8 +35939,9 @@ static void *pcache1Alloc(int nByte){
/*
** Free an allocated buffer obtained from pcache1Alloc().
*/
-static void pcache1Free(void *p){
- if( p==0 ) return;
+static int pcache1Free(void *p){
+ int nFreed = 0;
+ if( p==0 ) return 0;
if( p>=pcache1.pStart && p<pcache1.pEnd ){
PgFreeslot *pSlot;
sqlite3_mutex_enter(pcache1.mutex);
@@ -35565,15 +35954,17 @@ static void pcache1Free(void *p){
assert( pcache1.nFreeSlot<=pcache1.nSlot );
sqlite3_mutex_leave(pcache1.mutex);
}else{
- int iSize;
assert( sqlite3MemdebugHasType(p, MEMTYPE_PCACHE) );
sqlite3MemdebugSetType(p, MEMTYPE_HEAP);
- iSize = sqlite3MallocSize(p);
+ nFreed = sqlite3MallocSize(p);
+#ifndef SQLITE_DISABLE_PAGECACHE_OVERFLOW_STATS
sqlite3_mutex_enter(pcache1.mutex);
- sqlite3StatusAdd(SQLITE_STATUS_PAGECACHE_OVERFLOW, -iSize);
+ sqlite3StatusAdd(SQLITE_STATUS_PAGECACHE_OVERFLOW, -nFreed);
sqlite3_mutex_leave(pcache1.mutex);
+#endif
sqlite3_free(p);
}
+ return nFreed;
}
#ifdef SQLITE_ENABLE_MEMORY_MANAGEMENT
@@ -35598,18 +35989,37 @@ static int pcache1MemSize(void *p){
** Allocate a new page object initially associated with cache pCache.
*/
static PgHdr1 *pcache1AllocPage(PCache1 *pCache){
- int nByte = sizeof(PgHdr1) + pCache->szPage;
- void *pPg = pcache1Alloc(nByte);
- PgHdr1 *p;
+ PgHdr1 *p = 0;
+ void *pPg;
+
+ /* The group mutex must be released before pcache1Alloc() is called. This
+ ** is because it may call sqlite3_release_memory(), which assumes that
+ ** this mutex is not held. */
+ assert( sqlite3_mutex_held(pCache->pGroup->mutex) );
+ pcache1LeaveMutex(pCache->pGroup);
+#ifdef SQLITE_PCACHE_SEPARATE_HEADER
+ pPg = pcache1Alloc(pCache->szPage);
+ p = sqlite3Malloc(sizeof(PgHdr1) + pCache->szExtra);
+ if( !pPg || !p ){
+ pcache1Free(pPg);
+ sqlite3_free(p);
+ pPg = 0;
+ }
+#else
+ pPg = pcache1Alloc(sizeof(PgHdr1) + pCache->szPage + pCache->szExtra);
+ p = (PgHdr1 *)&((u8 *)pPg)[pCache->szPage];
+#endif
+ pcache1EnterMutex(pCache->pGroup);
+
if( pPg ){
- p = PAGE_TO_PGHDR1(pCache, pPg);
+ p->page.pBuf = pPg;
+ p->page.pExtra = &p[1];
if( pCache->bPurgeable ){
pCache->pGroup->nCurrentPage++;
}
- }else{
- p = 0;
+ return p;
}
- return p;
+ return 0;
}
/*
@@ -35622,10 +36032,14 @@ static PgHdr1 *pcache1AllocPage(PCache1 *pCache){
static void pcache1FreePage(PgHdr1 *p){
if( ALWAYS(p) ){
PCache1 *pCache = p->pCache;
+ assert( sqlite3_mutex_held(p->pCache->pGroup->mutex) );
+ pcache1Free(p->page.pBuf);
+#ifdef SQLITE_PCACHE_SEPARATE_HEADER
+ sqlite3_free(p);
+#endif
if( pCache->bPurgeable ){
pCache->pGroup->nCurrentPage--;
}
- pcache1Free(PGHDR1_TO_PAGE(p));
}
}
@@ -35657,13 +36071,13 @@ SQLITE_PRIVATE void sqlite3PageFree(void *p){
** for all page cache needs and we should not need to spill the
** allocation onto the heap.
**
-** Or, the heap is used for all page cache memory put the heap is
+** Or, the heap is used for all page cache memory but the heap is
** under memory pressure, then again it is desirable to avoid
** allocating a new page cache entry in order to avoid stressing
** the heap even further.
*/
static int pcache1UnderMemoryPressure(PCache1 *pCache){
- if( pcache1.nSlot && pCache->szPage<=pcache1.szSlot ){
+ if( pcache1.nSlot && (pCache->szPage+pCache->szExtra)<=pcache1.szSlot ){
return pcache1.bUnderPressure;
}else{
return sqlite3HeapNearlyFull();
@@ -35693,11 +36107,10 @@ static int pcache1ResizeHash(PCache1 *p){
pcache1LeaveMutex(p->pGroup);
if( p->nHash ){ sqlite3BeginBenignMalloc(); }
- apNew = (PgHdr1 **)sqlite3_malloc(sizeof(PgHdr1 *)*nNew);
+ apNew = (PgHdr1 **)sqlite3MallocZero(sizeof(PgHdr1 *)*nNew);
if( p->nHash ){ sqlite3EndBenignMalloc(); }
pcache1EnterMutex(p->pGroup);
if( apNew ){
- memset(apNew, 0, sizeof(PgHdr1 *)*nNew);
for(i=0; i<p->nHash; i++){
PgHdr1 *pPage;
PgHdr1 *pNext = p->apHash[i];
@@ -35854,7 +36267,7 @@ static void pcache1Shutdown(void *NotUsed){
**
** Allocate a new cache.
*/
-static sqlite3_pcache *pcache1Create(int szPage, int bPurgeable){
+static sqlite3_pcache *pcache1Create(int szPage, int szExtra, int bPurgeable){
PCache1 *pCache; /* The newly created page cache */
PGroup *pGroup; /* The group the new page cache will belong to */
int sz; /* Bytes of memory required to allocate the new cache */
@@ -35877,10 +36290,12 @@ static sqlite3_pcache *pcache1Create(int szPage, int bPurgeable){
int separateCache = sqlite3GlobalConfig.bCoreMutex>0;
#endif
+ assert( (szPage & (szPage-1))==0 && szPage>=512 && szPage<=65536 );
+ assert( szExtra < 300 );
+
sz = sizeof(PCache1) + sizeof(PGroup)*separateCache;
- pCache = (PCache1 *)sqlite3_malloc(sz);
+ pCache = (PCache1 *)sqlite3MallocZero(sz);
if( pCache ){
- memset(pCache, 0, sz);
if( separateCache ){
pGroup = (PGroup*)&pCache[1];
pGroup->mxPinned = 10;
@@ -35889,6 +36304,7 @@ static sqlite3_pcache *pcache1Create(int szPage, int bPurgeable){
}
pCache->pGroup = pGroup;
pCache->szPage = szPage;
+ pCache->szExtra = szExtra;
pCache->bPurgeable = (bPurgeable ? 1 : 0);
if( bPurgeable ){
pCache->nMin = 10;
@@ -35921,6 +36337,25 @@ static void pcache1Cachesize(sqlite3_pcache *p, int nMax){
}
/*
+** Implementation of the sqlite3_pcache.xShrink method.
+**
+** Free up as much memory as possible.
+*/
+static void pcache1Shrink(sqlite3_pcache *p){
+ PCache1 *pCache = (PCache1*)p;
+ if( pCache->bPurgeable ){
+ PGroup *pGroup = pCache->pGroup;
+ int savedMaxPage;
+ pcache1EnterMutex(pGroup);
+ savedMaxPage = pGroup->nMaxPage;
+ pGroup->nMaxPage = 0;
+ pcache1EnforceMaxPage(pGroup);
+ pGroup->nMaxPage = savedMaxPage;
+ pcache1LeaveMutex(pGroup);
+ }
+}
+
+/*
** Implementation of the sqlite3_pcache.xPagecount method.
*/
static int pcache1Pagecount(sqlite3_pcache *p){
@@ -35945,7 +36380,7 @@ static int pcache1Pagecount(sqlite3_pcache *p){
** For a non-purgeable cache (a cache used as the storage for an in-memory
** database) there is really no difference between createFlag 1 and 2. So
** the calling function (pcache.c) will never have a createFlag of 1 on
-** a non-purgable cache.
+** a non-purgeable cache.
**
** There are three different approaches to obtaining space for a page,
** depending on the value of parameter createFlag (which may be 0, 1 or 2).
@@ -35986,8 +36421,12 @@ static int pcache1Pagecount(sqlite3_pcache *p){
**
** 5. Otherwise, allocate and return a new page buffer.
*/
-static void *pcache1Fetch(sqlite3_pcache *p, unsigned int iKey, int createFlag){
- int nPinned;
+static sqlite3_pcache_page *pcache1Fetch(
+ sqlite3_pcache *p,
+ unsigned int iKey,
+ int createFlag
+){
+ unsigned int nPinned;
PCache1 *pCache = (PCache1 *)p;
PGroup *pGroup;
PgHdr1 *pPage = 0;
@@ -36021,15 +36460,14 @@ static void *pcache1Fetch(sqlite3_pcache *p, unsigned int iKey, int createFlag){
pGroup = pCache->pGroup;
#endif
-
/* Step 3: Abort if createFlag is 1 but the cache is nearly full */
+ assert( pCache->nPage >= pCache->nRecyclable );
nPinned = pCache->nPage - pCache->nRecyclable;
- assert( nPinned>=0 );
assert( pGroup->mxPinned == pGroup->nMaxPage + 10 - pGroup->nMinPage );
assert( pCache->n90pct == pCache->nMax*9/10 );
if( createFlag==1 && (
nPinned>=pGroup->mxPinned
- || nPinned>=(int)pCache->n90pct
+ || nPinned>=pCache->n90pct
|| pcache1UnderMemoryPressure(pCache)
)){
goto fetch_out;
@@ -36045,16 +36483,24 @@ static void *pcache1Fetch(sqlite3_pcache *p, unsigned int iKey, int createFlag){
|| pGroup->nCurrentPage>=pGroup->nMaxPage
|| pcache1UnderMemoryPressure(pCache)
)){
- PCache1 *pOtherCache;
+ PCache1 *pOther;
pPage = pGroup->pLruTail;
pcache1RemoveFromHash(pPage);
pcache1PinPage(pPage);
- if( (pOtherCache = pPage->pCache)->szPage!=pCache->szPage ){
+ pOther = pPage->pCache;
+
+ /* We want to verify that szPage and szExtra are the same for pOther
+ ** and pCache. Assert that we can verify this by comparing sums. */
+ assert( (pCache->szPage & (pCache->szPage-1))==0 && pCache->szPage>=512 );
+ assert( pCache->szExtra<512 );
+ assert( (pOther->szPage & (pOther->szPage-1))==0 && pOther->szPage>=512 );
+ assert( pOther->szExtra<512 );
+
+ if( pOther->szPage+pOther->szExtra != pCache->szPage+pCache->szExtra ){
pcache1FreePage(pPage);
pPage = 0;
}else{
- pGroup->nCurrentPage -=
- (pOtherCache->bPurgeable - pCache->bPurgeable);
+ pGroup->nCurrentPage -= (pOther->bPurgeable - pCache->bPurgeable);
}
}
@@ -36063,9 +36509,7 @@ static void *pcache1Fetch(sqlite3_pcache *p, unsigned int iKey, int createFlag){
*/
if( !pPage ){
if( createFlag==1 ) sqlite3BeginBenignMalloc();
- pcache1LeaveMutex(pGroup);
pPage = pcache1AllocPage(pCache);
- pcache1EnterMutex(pGroup);
if( createFlag==1 ) sqlite3EndBenignMalloc();
}
@@ -36077,7 +36521,7 @@ static void *pcache1Fetch(sqlite3_pcache *p, unsigned int iKey, int createFlag){
pPage->pCache = pCache;
pPage->pLruPrev = 0;
pPage->pLruNext = 0;
- *(void **)(PGHDR1_TO_PAGE(pPage)) = 0;
+ *(void **)pPage->page.pExtra = 0;
pCache->apHash[h] = pPage;
}
@@ -36086,7 +36530,7 @@ fetch_out:
pCache->iMaxKey = iKey;
}
pcache1LeaveMutex(pGroup);
- return (pPage ? PGHDR1_TO_PAGE(pPage) : 0);
+ return &pPage->page;
}
@@ -36095,9 +36539,13 @@ fetch_out:
**
** Mark a page as unpinned (eligible for asynchronous recycling).
*/
-static void pcache1Unpin(sqlite3_pcache *p, void *pPg, int reuseUnlikely){
+static void pcache1Unpin(
+ sqlite3_pcache *p,
+ sqlite3_pcache_page *pPg,
+ int reuseUnlikely
+){
PCache1 *pCache = (PCache1 *)p;
- PgHdr1 *pPage = PAGE_TO_PGHDR1(pCache, pPg);
+ PgHdr1 *pPage = (PgHdr1 *)pPg;
PGroup *pGroup = pCache->pGroup;
assert( pPage->pCache==pCache );
@@ -36133,12 +36581,12 @@ static void pcache1Unpin(sqlite3_pcache *p, void *pPg, int reuseUnlikely){
*/
static void pcache1Rekey(
sqlite3_pcache *p,
- void *pPg,
+ sqlite3_pcache_page *pPg,
unsigned int iOld,
unsigned int iNew
){
PCache1 *pCache = (PCache1 *)p;
- PgHdr1 *pPage = PAGE_TO_PGHDR1(pCache, pPg);
+ PgHdr1 *pPage = (PgHdr1 *)pPg;
PgHdr1 **pp;
unsigned int h;
assert( pPage->iKey==iOld );
@@ -36192,7 +36640,9 @@ static void pcache1Destroy(sqlite3_pcache *p){
assert( pCache->bPurgeable || (pCache->nMax==0 && pCache->nMin==0) );
pcache1EnterMutex(pGroup);
pcache1TruncateUnsafe(pCache, 0);
+ assert( pGroup->nMaxPage >= pCache->nMax );
pGroup->nMaxPage -= pCache->nMax;
+ assert( pGroup->nMinPage >= pCache->nMin );
pGroup->nMinPage -= pCache->nMin;
pGroup->mxPinned = pGroup->nMaxPage + 10 - pGroup->nMinPage;
pcache1EnforceMaxPage(pGroup);
@@ -36207,7 +36657,8 @@ static void pcache1Destroy(sqlite3_pcache *p){
** already provided an alternative.
*/
SQLITE_PRIVATE void sqlite3PCacheSetDefault(void){
- static const sqlite3_pcache_methods defaultMethods = {
+ static const sqlite3_pcache_methods2 defaultMethods = {
+ 1, /* iVersion */
0, /* pArg */
pcache1Init, /* xInit */
pcache1Shutdown, /* xShutdown */
@@ -36218,9 +36669,10 @@ SQLITE_PRIVATE void sqlite3PCacheSetDefault(void){
pcache1Unpin, /* xUnpin */
pcache1Rekey, /* xRekey */
pcache1Truncate, /* xTruncate */
- pcache1Destroy /* xDestroy */
+ pcache1Destroy, /* xDestroy */
+ pcache1Shrink /* xShrink */
};
- sqlite3_config(SQLITE_CONFIG_PCACHE, &defaultMethods);
+ sqlite3_config(SQLITE_CONFIG_PCACHE2, &defaultMethods);
}
#ifdef SQLITE_ENABLE_MEMORY_MANAGEMENT
@@ -36241,7 +36693,10 @@ SQLITE_PRIVATE int sqlite3PcacheReleaseMemory(int nReq){
PgHdr1 *p;
pcache1EnterMutex(&pcache1.grp);
while( (nReq<0 || nFree<nReq) && ((p=pcache1.grp.pLruTail)!=0) ){
- nFree += pcache1MemSize(PGHDR1_TO_PAGE(p));
+ nFree += pcache1MemSize(p->page.pBuf);
+#ifdef SQLITE_PCACHE_SEPARATE_HEADER
+ nFree += sqlite3MemSize(p);
+#endif
pcache1PinPage(p);
pcache1RemoveFromHash(p);
pcache1FreePage(p);
@@ -36269,8 +36724,8 @@ SQLITE_PRIVATE void sqlite3PcacheStats(
nRecyclable++;
}
*pnCurrent = pcache1.grp.nCurrentPage;
- *pnMax = pcache1.grp.nMaxPage;
- *pnMin = pcache1.grp.nMinPage;
+ *pnMax = (int)pcache1.grp.nMaxPage;
+ *pnMin = (int)pcache1.grp.nMinPage;
*pnRecyclable = nRecyclable;
}
#endif
@@ -36354,6 +36809,11 @@ SQLITE_PRIVATE void sqlite3PcacheStats(
/*
** Each entry in a RowSet is an instance of the following object.
+**
+** This same object is reused to store a linked list of trees of RowSetEntry
+** objects. In that alternative use, pRight points to the next entry
+** in the list, pLeft points to the tree, and v is unused. The
+** RowSet.pForest value points to the head of this forest list.
*/
struct RowSetEntry {
i64 v; /* ROWID value for this entry */
@@ -36383,13 +36843,19 @@ struct RowSet {
struct RowSetEntry *pEntry; /* List of entries using pRight */
struct RowSetEntry *pLast; /* Last entry on the pEntry list */
struct RowSetEntry *pFresh; /* Source of new entry objects */
- struct RowSetEntry *pTree; /* Binary tree of entries */
+ struct RowSetEntry *pForest; /* List of binary trees of entries */
u16 nFresh; /* Number of objects on pFresh */
- u8 isSorted; /* True if pEntry is sorted */
+ u8 rsFlags; /* Various flags */
u8 iBatch; /* Current insert batch */
};
/*
+** Allowed values for RowSet.rsFlags
+*/
+#define ROWSET_SORTED 0x01 /* True if RowSet.pEntry is sorted */
+#define ROWSET_NEXT 0x02 /* True if sqlite3RowSetNext() has been called */
+
+/*
** Turn bulk memory into a RowSet object. N bytes of memory
** are available at pSpace. The db pointer is used as a memory context
** for any subsequent allocations that need to occur.
@@ -36409,10 +36875,10 @@ SQLITE_PRIVATE RowSet *sqlite3RowSetInit(sqlite3 *db, void *pSpace, unsigned int
p->db = db;
p->pEntry = 0;
p->pLast = 0;
- p->pTree = 0;
+ p->pForest = 0;
p->pFresh = (struct RowSetEntry*)(ROUND8(sizeof(*p)) + (char*)p);
p->nFresh = (u16)((N - ROUND8(sizeof(*p)))/sizeof(struct RowSetEntry));
- p->isSorted = 1;
+ p->rsFlags = ROWSET_SORTED;
p->iBatch = 0;
return p;
}
@@ -36432,43 +36898,59 @@ SQLITE_PRIVATE void sqlite3RowSetClear(RowSet *p){
p->nFresh = 0;
p->pEntry = 0;
p->pLast = 0;
- p->pTree = 0;
- p->isSorted = 1;
+ p->pForest = 0;
+ p->rsFlags = ROWSET_SORTED;
}
/*
-** Insert a new value into a RowSet.
+** Allocate a new RowSetEntry object that is associated with the
+** given RowSet. Return a pointer to the new and completely uninitialized
+** objected.
**
-** The mallocFailed flag of the database connection is set if a
-** memory allocation fails.
+** In an OOM situation, the RowSet.db->mallocFailed flag is set and this
+** routine returns NULL.
*/
-SQLITE_PRIVATE void sqlite3RowSetInsert(RowSet *p, i64 rowid){
- struct RowSetEntry *pEntry; /* The new entry */
- struct RowSetEntry *pLast; /* The last prior entry */
+static struct RowSetEntry *rowSetEntryAlloc(RowSet *p){
assert( p!=0 );
if( p->nFresh==0 ){
struct RowSetChunk *pNew;
pNew = sqlite3DbMallocRaw(p->db, sizeof(*pNew));
if( pNew==0 ){
- return;
+ return 0;
}
pNew->pNextChunk = p->pChunk;
p->pChunk = pNew;
p->pFresh = pNew->aEntry;
p->nFresh = ROWSET_ENTRY_PER_CHUNK;
}
- pEntry = p->pFresh++;
p->nFresh--;
+ return p->pFresh++;
+}
+
+/*
+** Insert a new value into a RowSet.
+**
+** The mallocFailed flag of the database connection is set if a
+** memory allocation fails.
+*/
+SQLITE_PRIVATE void sqlite3RowSetInsert(RowSet *p, i64 rowid){
+ struct RowSetEntry *pEntry; /* The new entry */
+ struct RowSetEntry *pLast; /* The last prior entry */
+
+ /* This routine is never called after sqlite3RowSetNext() */
+ assert( p!=0 && (p->rsFlags & ROWSET_NEXT)==0 );
+
+ pEntry = rowSetEntryAlloc(p);
+ if( pEntry==0 ) return;
pEntry->v = rowid;
pEntry->pRight = 0;
pLast = p->pLast;
if( pLast ){
- if( p->isSorted && rowid<=pLast->v ){
- p->isSorted = 0;
+ if( (p->rsFlags & ROWSET_SORTED)!=0 && rowid<=pLast->v ){
+ p->rsFlags &= ~ROWSET_SORTED;
}
pLast->pRight = pEntry;
}else{
- assert( p->pEntry==0 ); /* Fires if INSERT after SMALLEST */
p->pEntry = pEntry;
}
p->pLast = pEntry;
@@ -36480,7 +36962,7 @@ SQLITE_PRIVATE void sqlite3RowSetInsert(RowSet *p, i64 rowid){
** The input lists are connected via pRight pointers and are
** assumed to each already be in sorted order.
*/
-static struct RowSetEntry *rowSetMerge(
+static struct RowSetEntry *rowSetEntryMerge(
struct RowSetEntry *pA, /* First sorted list to be merged */
struct RowSetEntry *pB /* Second sorted list to be merged */
){
@@ -36514,32 +36996,29 @@ static struct RowSetEntry *rowSetMerge(
}
/*
-** Sort all elements on the pEntry list of the RowSet into ascending order.
+** Sort all elements on the list of RowSetEntry objects into order of
+** increasing v.
*/
-static void rowSetSort(RowSet *p){
+static struct RowSetEntry *rowSetEntrySort(struct RowSetEntry *pIn){
unsigned int i;
- struct RowSetEntry *pEntry;
- struct RowSetEntry *aBucket[40];
+ struct RowSetEntry *pNext, *aBucket[40];
- assert( p->isSorted==0 );
memset(aBucket, 0, sizeof(aBucket));
- while( p->pEntry ){
- pEntry = p->pEntry;
- p->pEntry = pEntry->pRight;
- pEntry->pRight = 0;
+ while( pIn ){
+ pNext = pIn->pRight;
+ pIn->pRight = 0;
for(i=0; aBucket[i]; i++){
- pEntry = rowSetMerge(aBucket[i], pEntry);
+ pIn = rowSetEntryMerge(aBucket[i], pIn);
aBucket[i] = 0;
}
- aBucket[i] = pEntry;
+ aBucket[i] = pIn;
+ pIn = pNext;
}
- pEntry = 0;
+ pIn = 0;
for(i=0; i<sizeof(aBucket)/sizeof(aBucket[0]); i++){
- pEntry = rowSetMerge(pEntry, aBucket[i]);
+ pIn = rowSetEntryMerge(pIn, aBucket[i]);
}
- p->pEntry = pEntry;
- p->pLast = 0;
- p->isSorted = 1;
+ return pIn;
}
@@ -36633,20 +37112,37 @@ static struct RowSetEntry *rowSetListToTree(struct RowSetEntry *pList){
}
/*
-** Convert the list in p->pEntry into a sorted list if it is not
-** sorted already. If there is a binary tree on p->pTree, then
-** convert it into a list too and merge it into the p->pEntry list.
+** Take all the entries on p->pEntry and on the trees in p->pForest and
+** sort them all together into one big ordered list on p->pEntry.
+**
+** This routine should only be called once in the life of a RowSet.
*/
static void rowSetToList(RowSet *p){
- if( !p->isSorted ){
- rowSetSort(p);
+
+ /* This routine is called only once */
+ assert( p!=0 && (p->rsFlags & ROWSET_NEXT)==0 );
+
+ if( (p->rsFlags & ROWSET_SORTED)==0 ){
+ p->pEntry = rowSetEntrySort(p->pEntry);
}
- if( p->pTree ){
- struct RowSetEntry *pHead, *pTail;
- rowSetTreeToList(p->pTree, &pHead, &pTail);
- p->pTree = 0;
- p->pEntry = rowSetMerge(p->pEntry, pHead);
+
+ /* While this module could theoretically support it, sqlite3RowSetNext()
+ ** is never called after sqlite3RowSetText() for the same RowSet. So
+ ** there is never a forest to deal with. Should this change, simply
+ ** remove the assert() and the #if 0. */
+ assert( p->pForest==0 );
+#if 0
+ while( p->pForest ){
+ struct RowSetEntry *pTree = p->pForest->pLeft;
+ if( pTree ){
+ struct RowSetEntry *pHead, *pTail;
+ rowSetTreeToList(pTree, &pHead, &pTail);
+ p->pEntry = rowSetEntryMerge(p->pEntry, pHead);
+ }
+ p->pForest = p->pForest->pRight;
}
+#endif
+ p->rsFlags |= ROWSET_NEXT; /* Verify this routine is never called again */
}
/*
@@ -36658,7 +37154,12 @@ static void rowSetToList(RowSet *p){
** routine may not be called again.
*/
SQLITE_PRIVATE int sqlite3RowSetNext(RowSet *p, i64 *pRowid){
- rowSetToList(p);
+ assert( p!=0 );
+
+ /* Merge the forest into a single sorted list on first call */
+ if( (p->rsFlags & ROWSET_NEXT)==0 ) rowSetToList(p);
+
+ /* Return the next entry on the list */
if( p->pEntry ){
*pRowid = p->pEntry->v;
p->pEntry = p->pEntry->pRight;
@@ -36672,28 +37173,68 @@ SQLITE_PRIVATE int sqlite3RowSetNext(RowSet *p, i64 *pRowid){
}
/*
-** Check to see if element iRowid was inserted into the the rowset as
+** Check to see if element iRowid was inserted into the rowset as
** part of any insert batch prior to iBatch. Return 1 or 0.
+**
+** If this is the first test of a new batch and if there exist entires
+** on pRowSet->pEntry, then sort those entires into the forest at
+** pRowSet->pForest so that they can be tested.
*/
SQLITE_PRIVATE int sqlite3RowSetTest(RowSet *pRowSet, u8 iBatch, sqlite3_int64 iRowid){
- struct RowSetEntry *p;
+ struct RowSetEntry *p, *pTree;
+
+ /* This routine is never called after sqlite3RowSetNext() */
+ assert( pRowSet!=0 && (pRowSet->rsFlags & ROWSET_NEXT)==0 );
+
+ /* Sort entries into the forest on the first test of a new batch
+ */
if( iBatch!=pRowSet->iBatch ){
- if( pRowSet->pEntry ){
- rowSetToList(pRowSet);
- pRowSet->pTree = rowSetListToTree(pRowSet->pEntry);
+ p = pRowSet->pEntry;
+ if( p ){
+ struct RowSetEntry **ppPrevTree = &pRowSet->pForest;
+ if( (pRowSet->rsFlags & ROWSET_SORTED)==0 ){
+ p = rowSetEntrySort(p);
+ }
+ for(pTree = pRowSet->pForest; pTree; pTree=pTree->pRight){
+ ppPrevTree = &pTree->pRight;
+ if( pTree->pLeft==0 ){
+ pTree->pLeft = rowSetListToTree(p);
+ break;
+ }else{
+ struct RowSetEntry *pAux, *pTail;
+ rowSetTreeToList(pTree->pLeft, &pAux, &pTail);
+ pTree->pLeft = 0;
+ p = rowSetEntryMerge(pAux, p);
+ }
+ }
+ if( pTree==0 ){
+ *ppPrevTree = pTree = rowSetEntryAlloc(pRowSet);
+ if( pTree ){
+ pTree->v = 0;
+ pTree->pRight = 0;
+ pTree->pLeft = rowSetListToTree(p);
+ }
+ }
pRowSet->pEntry = 0;
pRowSet->pLast = 0;
+ pRowSet->rsFlags |= ROWSET_SORTED;
}
pRowSet->iBatch = iBatch;
}
- p = pRowSet->pTree;
- while( p ){
- if( p->v<iRowid ){
- p = p->pRight;
- }else if( p->v>iRowid ){
- p = p->pLeft;
- }else{
- return 1;
+
+ /* Test to see if the iRowid value appears anywhere in the forest.
+ ** Return 1 if it does and 0 if not.
+ */
+ for(pTree = pRowSet->pForest; pTree; pTree=pTree->pRight){
+ p = pTree->pLeft;
+ while( p ){
+ if( p->v<iRowid ){
+ p = p->pRight;
+ }else if( p->v>iRowid ){
+ p = p->pLeft;
+ }else{
+ return 1;
+ }
}
}
return 0;
@@ -36744,6 +37285,12 @@ SQLITE_PRIVATE int sqlite3RowSetTest(RowSet *pRowSet, u8 iBatch, sqlite3_int64 i
#define _WAL_H_
+/* Additional values that can be added to the sync_flags argument of
+** sqlite3WalFrames():
+*/
+#define WAL_SYNC_TRANSACTIONS 0x20 /* Sync at the end of each transaction */
+#define SQLITE_SYNC_MASK 0x13 /* Mask off the SQLITE_SYNC_* values */
+
#ifdef SQLITE_OMIT_WAL
# define sqlite3WalOpen(x,y,z) 0
# define sqlite3WalLimit(x,y)
@@ -36762,6 +37309,7 @@ SQLITE_PRIVATE int sqlite3RowSetTest(RowSet *pRowSet, u8 iBatch, sqlite3_int64 i
# define sqlite3WalCallback(z) 0
# define sqlite3WalExclusiveMode(y,z) 0
# define sqlite3WalHeapMemory(z) 0
+# define sqlite3WalFramesize(z) 0
#else
#define WAL_SAVEPOINT_NDATA 4
@@ -36843,6 +37391,13 @@ SQLITE_PRIVATE int sqlite3WalExclusiveMode(Wal *pWal, int op);
*/
SQLITE_PRIVATE int sqlite3WalHeapMemory(Wal *pWal);
+#ifdef SQLITE_ENABLE_ZIPVFS
+/* If the WAL file is not empty, return the number of bytes of content
+** stored in each frame (i.e. the db page-size when the WAL was created).
+*/
+SQLITE_PRIVATE int sqlite3WalFramesize(Wal *pWal);
+#endif
+
#endif /* ifndef SQLITE_OMIT_WAL */
#endif /* _WAL_H_ */
@@ -36902,7 +37457,7 @@ SQLITE_PRIVATE int sqlite3WalHeapMemory(Wal *pWal);
**
** Definition: Two databases (or the same database at two points it time)
** are said to be "logically equivalent" if they give the same answer to
-** all queries. Note in particular the the content of freelist leaf
+** all queries. Note in particular the content of freelist leaf
** pages can be changed arbitarily without effecting the logical equivalence
** of the database.
**
@@ -37100,7 +37655,7 @@ int sqlite3PagerTrace=1; /* True to enable tracing */
** * A write transaction is active.
** * An EXCLUSIVE or greater lock is held on the database file.
** * All writing and syncing of journal and database data has finished.
-** If no error occured, all that remains is to finalize the journal to
+** If no error occurred, all that remains is to finalize the journal to
** commit the transaction. If an error did occur, the caller will need
** to rollback the transaction.
**
@@ -37348,7 +37903,7 @@ struct PagerSavepoint {
**
** doNotSpill, doNotSyncSpill
**
-** These two boolean variables control the behaviour of cache-spills
+** These two boolean variables control the behavior of cache-spills
** (calls made by the pcache module to the pagerStress() routine to
** write cached data to the file-system in order to free up memory).
**
@@ -37439,10 +37994,10 @@ struct Pager {
u8 exclusiveMode; /* Boolean. True if locking_mode==EXCLUSIVE */
u8 journalMode; /* One of the PAGER_JOURNALMODE_* values */
u8 useJournal; /* Use a rollback journal on this file */
- u8 noReadlock; /* Do not bother to obtain readlocks */
u8 noSync; /* Do not sync the journal if true */
u8 fullSync; /* Do extra syncs of the journal for robustness */
u8 ckptSyncFlags; /* SYNC_NORMAL or SYNC_FULL for checkpoint */
+ u8 walSyncFlags; /* SYNC_NORMAL or SYNC_FULL for wal writes */
u8 syncFlags; /* SYNC_NORMAL or SYNC_FULL otherwise */
u8 tempFile; /* zFilename is a temporary file */
u8 readOnly; /* True for a read-only database */
@@ -37497,9 +38052,9 @@ struct Pager {
char *zJournal; /* Name of the journal file */
int (*xBusyHandler)(void*); /* Function to call when busy */
void *pBusyHandlerArg; /* Context argument for xBusyHandler */
+ int aStat[3]; /* Total cache hits, misses and writes */
#ifdef SQLITE_TEST
- int nHit, nMiss; /* Cache hits and missing */
- int nRead, nWrite; /* Database pages read/written */
+ int nRead; /* Database pages read */
#endif
void (*xReiniter)(DbPage*); /* Call this routine when reloading pages */
#ifdef SQLITE_HAS_CODEC
@@ -37517,6 +38072,15 @@ struct Pager {
};
/*
+** Indexes for use with Pager.aStat[]. The Pager.aStat[] array contains
+** the values accessed by passing SQLITE_DBSTATUS_CACHE_HIT, CACHE_MISS
+** or CACHE_WRITE to sqlite3_db_status().
+*/
+#define PAGER_STAT_HIT 0
+#define PAGER_STAT_MISS 1
+#define PAGER_STAT_WRITE 2
+
+/*
** The following global variables hold counters used for
** testing purposes only. These variables do not exist in
** a non-testing build. These variables are not thread-safe.
@@ -37613,7 +38177,7 @@ static int pagerUseWal(Pager *pPager){
#else
# define pagerUseWal(x) 0
# define pagerRollbackWal(x) 0
-# define pagerWalFrames(v,w,x,y,z) 0
+# define pagerWalFrames(v,w,x,y) 0
# define pagerOpenWalIfPresent(z) SQLITE_OK
# define pagerBeginReadTransaction(z) SQLITE_OK
#endif
@@ -37686,7 +38250,7 @@ static int assert_pager_state(Pager *p){
case PAGER_READER:
assert( pPager->errCode==SQLITE_OK );
assert( p->eLock!=UNKNOWN_LOCK );
- assert( p->eLock>=SHARED_LOCK || p->noReadlock );
+ assert( p->eLock>=SHARED_LOCK );
break;
case PAGER_WRITER_LOCKED:
@@ -38217,7 +38781,7 @@ static int writeJournalHdr(Pager *pPager){
memset(zHeader, 0, sizeof(aJournalMagic)+4);
}
- /* The random check-hash initialiser */
+ /* The random check-hash initializer */
sqlite3_randomness(sizeof(pPager->cksumInit), &pPager->cksumInit);
put32bits(&zHeader[sizeof(aJournalMagic)+4], pPager->cksumInit);
/* The initial database size */
@@ -38656,6 +39220,8 @@ static int pager_error(Pager *pPager, int rc){
return rc;
}
+static int pager_truncate(Pager *pPager, Pgno nPage);
+
/*
** This routine ends a transaction. A transaction is usually ended by
** either a COMMIT or a ROLLBACK operation. This routine may be called
@@ -38709,7 +39275,7 @@ static int pager_error(Pager *pPager, int rc){
** to the first error encountered (the journal finalization one) is
** returned.
*/
-static int pager_end_transaction(Pager *pPager, int hasMaster){
+static int pager_end_transaction(Pager *pPager, int hasMaster, int bCommit){
int rc = SQLITE_OK; /* Error code from journal finalization operation */
int rc2 = SQLITE_OK; /* Error code from db file unlock operation */
@@ -38759,12 +39325,13 @@ static int pager_end_transaction(Pager *pPager, int hasMaster){
** file should be closed and deleted. If this connection writes to
** the database file, it will do so using an in-memory journal.
*/
+ int bDelete = (!pPager->tempFile && sqlite3JournalExists(pPager->jfd));
assert( pPager->journalMode==PAGER_JOURNALMODE_DELETE
|| pPager->journalMode==PAGER_JOURNALMODE_MEMORY
|| pPager->journalMode==PAGER_JOURNALMODE_WAL
);
sqlite3OsClose(pPager->jfd);
- if( !pPager->tempFile ){
+ if( bDelete ){
rc = sqlite3OsDelete(pPager->pVfs, pPager->zJournal, 0);
}
}
@@ -38794,7 +39361,17 @@ static int pager_end_transaction(Pager *pPager, int hasMaster){
*/
rc2 = sqlite3WalEndWriteTransaction(pPager->pWal);
assert( rc2==SQLITE_OK );
+ }else if( rc==SQLITE_OK && bCommit && pPager->dbFileSize>pPager->dbSize ){
+ /* This branch is taken when committing a transaction in rollback-journal
+ ** mode if the database file on disk is larger than the database image.
+ ** At this point the journal has been finalized and the transaction
+ ** successfully committed, but the EXCLUSIVE lock is still held on the
+ ** file. So it is safe to truncate the database file to its minimum
+ ** required size. */
+ assert( pPager->eLock==EXCLUSIVE_LOCK );
+ rc = pager_truncate(pPager, pPager->dbSize);
}
+
if( !pPager->exclusiveMode
&& (!pagerUseWal(pPager) || sqlite3WalExclusiveMode(pPager->pWal, 0))
){
@@ -38833,7 +39410,7 @@ static void pagerUnlockAndRollback(Pager *pPager){
sqlite3EndBenignMalloc();
}else if( !pPager->exclusiveMode ){
assert( pPager->eState==PAGER_READER );
- pager_end_transaction(pPager, 0);
+ pager_end_transaction(pPager, 0, 0);
}
}
pager_unlock(pPager);
@@ -39312,10 +39889,9 @@ static int pager_truncate(Pager *pPager, Pgno nPage){
if( rc==SQLITE_OK && currentSize!=newSize ){
if( currentSize>newSize ){
rc = sqlite3OsTruncate(pPager->fd, newSize);
- }else{
+ }else if( (currentSize+szPage)<=newSize ){
char *pTmp = pPager->pTmpSpace;
memset(pTmp, 0, szPage);
- testcase( (newSize-szPage) < currentSize );
testcase( (newSize-szPage) == currentSize );
testcase( (newSize-szPage) > currentSize );
rc = sqlite3OsWrite(pPager->fd, pTmp, szPage, newSize-szPage);
@@ -39329,6 +39905,21 @@ static int pager_truncate(Pager *pPager, Pgno nPage){
}
/*
+** Return a sanitized version of the sector-size of OS file pFile. The
+** return value is guaranteed to lie between 32 and MAX_SECTOR_SIZE.
+*/
+SQLITE_PRIVATE int sqlite3SectorSize(sqlite3_file *pFile){
+ int iRet = sqlite3OsSectorSize(pFile);
+ if( iRet<32 ){
+ iRet = 512;
+ }else if( iRet>MAX_SECTOR_SIZE ){
+ assert( MAX_SECTOR_SIZE>=512 );
+ iRet = MAX_SECTOR_SIZE;
+ }
+ return iRet;
+}
+
+/*
** Set the value of the Pager.sectorSize variable for the given
** pager based on the value returned by the xSectorSize method
** of the open database file. The sector size will be used used
@@ -39341,23 +39932,29 @@ static int pager_truncate(Pager *pPager, Pgno nPage){
** the value returned by the xSectorSize() method rounded up to 32 if
** it is less than 32, or rounded down to MAX_SECTOR_SIZE if it
** is greater than MAX_SECTOR_SIZE.
+**
+** If the file has the SQLITE_IOCAP_POWERSAFE_OVERWRITE property, then set
+** the effective sector size to its minimum value (512). The purpose of
+** pPager->sectorSize is to define the "blast radius" of bytes that
+** might change if a crash occurs while writing to a single byte in
+** that range. But with POWERSAFE_OVERWRITE, the blast radius is zero
+** (that is what POWERSAFE_OVERWRITE means), so we minimize the sector
+** size. For backwards compatibility of the rollback journal file format,
+** we cannot reduce the effective sector size below 512.
*/
static void setSectorSize(Pager *pPager){
assert( isOpen(pPager->fd) || pPager->tempFile );
- if( !pPager->tempFile ){
+ if( pPager->tempFile
+ || (sqlite3OsDeviceCharacteristics(pPager->fd) &
+ SQLITE_IOCAP_POWERSAFE_OVERWRITE)!=0
+ ){
/* Sector size doesn't matter for temporary files. Also, the file
** may not have been opened yet, in which case the OsSectorSize()
- ** call will segfault.
- */
- pPager->sectorSize = sqlite3OsSectorSize(pPager->fd);
- }
- if( pPager->sectorSize<32 ){
+ ** call will segfault. */
pPager->sectorSize = 512;
- }
- if( pPager->sectorSize>MAX_SECTOR_SIZE ){
- assert( MAX_SECTOR_SIZE>=512 );
- pPager->sectorSize = MAX_SECTOR_SIZE;
+ }else{
+ pPager->sectorSize = sqlite3SectorSize(pPager->fd);
}
}
@@ -39530,7 +40127,6 @@ static int pager_playback(Pager *pPager, int isHot){
rc = pager_playback_one_page(pPager,&pPager->journalOff,0,1,0);
if( rc!=SQLITE_OK ){
if( rc==SQLITE_DONE ){
- rc = SQLITE_OK;
pPager->journalOff = szJ;
break;
}else if( rc==SQLITE_IOERR_SHORT_READ ){
@@ -39561,10 +40157,11 @@ end_playback:
** SQLITE_FCNTL_DB_UNCHANGED file-control method to disable the
** assertion that the transaction counter was modified.
*/
- assert(
- pPager->fd->pMethods==0 ||
- sqlite3OsFileControl(pPager->fd,SQLITE_FCNTL_DB_UNCHANGED,0)>=SQLITE_OK
- );
+#ifdef SQLITE_DEBUG
+ if( pPager->fd->pMethods ){
+ sqlite3OsFileControlHint(pPager->fd,SQLITE_FCNTL_DB_UNCHANGED,0);
+ }
+#endif
/* If this playback is happening automatically as a result of an IO or
** malloc error that occurred after the change-counter was updated but
@@ -39588,7 +40185,7 @@ end_playback:
rc = sqlite3PagerSync(pPager);
}
if( rc==SQLITE_OK ){
- rc = pager_end_transaction(pPager, zMaster[0]!='\0');
+ rc = pager_end_transaction(pPager, zMaster[0]!='\0', 0);
testcase( rc!=SQLITE_OK );
}
if( rc==SQLITE_OK && zMaster[0] && res ){
@@ -39783,15 +40380,16 @@ static int pagerWalFrames(
Pager *pPager, /* Pager object */
PgHdr *pList, /* List of frames to log */
Pgno nTruncate, /* Database size after this commit */
- int isCommit, /* True if this is a commit */
- int syncFlags /* Flags to pass to OsSync() (or 0) */
+ int isCommit /* True if this is a commit */
){
int rc; /* Return code */
+ int nList; /* Number of pages in pList */
#if defined(SQLITE_DEBUG) || defined(SQLITE_CHECK_PAGES)
PgHdr *p; /* For looping over pages */
#endif
assert( pPager->pWal );
+ assert( pList );
#ifdef SQLITE_DEBUG
/* Verify that the page list is in accending order */
for(p=pList; p && p->pDirty; p=p->pDirty){
@@ -39799,6 +40397,7 @@ static int pagerWalFrames(
}
#endif
+ assert( pList->pDirty==0 || isCommit );
if( isCommit ){
/* If a WAL transaction is being committed, there is no point in writing
** any pages with page numbers greater than nTruncate into the WAL file.
@@ -39806,15 +40405,22 @@ static int pagerWalFrames(
** list here. */
PgHdr *p;
PgHdr **ppNext = &pList;
- for(p=pList; (*ppNext = p); p=p->pDirty){
- if( p->pgno<=nTruncate ) ppNext = &p->pDirty;
+ nList = 0;
+ for(p=pList; (*ppNext = p)!=0; p=p->pDirty){
+ if( p->pgno<=nTruncate ){
+ ppNext = &p->pDirty;
+ nList++;
+ }
}
assert( pList );
+ }else{
+ nList = 1;
}
+ pPager->aStat[PAGER_STAT_WRITE] += nList;
if( pList->pgno==1 ) pager_write_changecounter(pList);
rc = sqlite3WalFrames(pPager->pWal,
- pPager->pageSize, pList, nTruncate, isCommit, syncFlags
+ pPager->pageSize, pList, nTruncate, isCommit, pPager->walSyncFlags
);
if( rc==SQLITE_OK && pPager->pBackup ){
PgHdr *p;
@@ -39883,7 +40489,7 @@ static int pagerPagecount(Pager *pPager, Pgno *pnPage){
** contains no valid committed transactions.
*/
assert( pPager->eState==PAGER_OPEN );
- assert( pPager->eLock>=SHARED_LOCK || pPager->noReadlock );
+ assert( pPager->eLock>=SHARED_LOCK );
nPage = sqlite3WalDbsize(pPager->pWal);
/* If the database size was not available from the WAL sub-system,
@@ -39901,10 +40507,7 @@ static int pagerPagecount(Pager *pPager, Pgno *pnPage){
return rc;
}
}
- nPage = (Pgno)(n / pPager->pageSize);
- if( nPage==0 && n>0 ){
- nPage = 1;
- }
+ nPage = (Pgno)((n+pPager->pageSize-1) / pPager->pageSize);
}
/* If the current number of pages in the file is greater than the
@@ -39941,7 +40544,7 @@ static int pagerPagecount(Pager *pPager, Pgno *pnPage){
static int pagerOpenWalIfPresent(Pager *pPager){
int rc = SQLITE_OK;
assert( pPager->eState==PAGER_OPEN );
- assert( pPager->eLock>=SHARED_LOCK || pPager->noReadlock );
+ assert( pPager->eLock>=SHARED_LOCK );
if( !pPager->tempFile ){
int isWal; /* True if WAL file exists */
@@ -39951,6 +40554,7 @@ static int pagerOpenWalIfPresent(Pager *pPager){
if( rc ) return rc;
if( nPage==0 ){
rc = sqlite3OsDelete(pPager->pVfs, pPager->zWal, 0);
+ if( rc==SQLITE_IOERR_DELETE_NOENT ) rc = SQLITE_OK;
isWal = 0;
}else{
rc = sqlite3OsAccess(
@@ -40094,13 +40698,13 @@ static int pagerPlaybackSavepoint(Pager *pPager, PagerSavepoint *pSavepoint){
*/
if( pSavepoint ){
u32 ii; /* Loop counter */
- i64 offset = pSavepoint->iSubRec*(4+pPager->pageSize);
+ i64 offset = (i64)pSavepoint->iSubRec*(4+pPager->pageSize);
if( pagerUseWal(pPager) ){
rc = sqlite3WalSavepointUndo(pPager->pWal, pSavepoint->aWalData);
}
for(ii=pSavepoint->iSubRec; rc==SQLITE_OK && ii<pPager->nSubRec; ii++){
- assert( offset==ii*(4+pPager->pageSize) );
+ assert( offset==(i64)ii*(4+pPager->pageSize) );
rc = pager_playback_one_page(pPager, &offset, pDone, 0, 1);
}
assert( rc!=SQLITE_DONE );
@@ -40122,6 +40726,13 @@ SQLITE_PRIVATE void sqlite3PagerSetCachesize(Pager *pPager, int mxPage){
}
/*
+** Free as much memory as possible from the pager.
+*/
+SQLITE_PRIVATE void sqlite3PagerShrink(Pager *pPager){
+ sqlite3PcacheShrink(pPager->pPCache);
+}
+
+/*
** Adjust the robustness of the database to damage due to OS crashes
** or power failures by changing the number of syncs()s when writing
** the rollback journal. There are three levels:
@@ -40187,6 +40798,10 @@ SQLITE_PRIVATE void sqlite3PagerSetSafetyLevel(
pPager->syncFlags = SQLITE_SYNC_NORMAL;
pPager->ckptSyncFlags = SQLITE_SYNC_NORMAL;
}
+ pPager->walSyncFlags = pPager->syncFlags;
+ if( pPager->fullSync ){
+ pPager->walSyncFlags |= WAL_SYNC_TRANSACTIONS;
+ }
}
#endif
@@ -40257,9 +40872,16 @@ SQLITE_PRIVATE void sqlite3PagerSetBusyhandler(
Pager *pPager, /* Pager object */
int (*xBusyHandler)(void *), /* Pointer to busy-handler function */
void *pBusyHandlerArg /* Argument to pass to xBusyHandler */
-){
+){
pPager->xBusyHandler = xBusyHandler;
pPager->pBusyHandlerArg = pBusyHandlerArg;
+
+ if( isOpen(pPager->fd) ){
+ void **ap = (void **)&pPager->xBusyHandler;
+ assert( ((int(*)(void *))(ap[0]))==xBusyHandler );
+ assert( ap[1]==pBusyHandlerArg );
+ sqlite3OsFileControlHint(pPager->fd, SQLITE_FCNTL_BUSYHANDLER, (void *)ap);
+ }
}
/*
@@ -40324,7 +40946,7 @@ SQLITE_PRIVATE int sqlite3PagerSetPagesize(Pager *pPager, u32 *pPageSize, int nR
if( rc==SQLITE_OK ){
pager_reset(pPager);
- pPager->dbSize = (Pgno)(nByte/pageSize);
+ pPager->dbSize = (Pgno)((nByte+pageSize-1)/pageSize);
pPager->pageSize = pageSize;
sqlite3PageFree(pPager->pTmpSpace);
pPager->pTmpSpace = pNew;
@@ -40491,7 +41113,7 @@ static int pager_wait_on_lock(Pager *pPager, int locktype){
** dirty page were to be discarded from the cache via the pagerStress()
** routine, pagerStress() would not write the current page content to
** the database file. If a savepoint transaction were rolled back after
-** this happened, the correct behaviour would be to restore the current
+** this happened, the correct behavior would be to restore the current
** content of the page. However, since this content is not present in either
** the database file or the portion of the rollback journal and
** sub-journal rolled back the content could not be restored and the
@@ -40515,12 +41137,26 @@ static void assertTruncateConstraint(Pager *pPager){
** function does not actually modify the database file on disk. It
** just sets the internal state of the pager object so that the
** truncation will be done when the current transaction is committed.
+**
+** This function is only called right before committing a transaction.
+** Once this function has been called, the transaction must either be
+** rolled back or committed. It is not safe to call this function and
+** then continue writing to the database.
*/
SQLITE_PRIVATE void sqlite3PagerTruncateImage(Pager *pPager, Pgno nPage){
assert( pPager->dbSize>=nPage );
assert( pPager->eState>=PAGER_WRITER_CACHEMOD );
pPager->dbSize = nPage;
- assertTruncateConstraint(pPager);
+
+ /* At one point the code here called assertTruncateConstraint() to
+ ** ensure that all pages being truncated away by this operation are,
+ ** if one or more savepoints are open, present in the savepoint
+ ** journal so that they can be restored if the savepoint is rolled
+ ** back. This is no longer necessary as this function is now only
+ ** called right before committing a transaction. So although the
+ ** Pager object may still have open savepoints (Pager.nSavepoint!=0),
+ ** they cannot be rolled back. So the assertTruncateConstraint() call
+ ** is no longer correct. */
}
@@ -40566,6 +41202,7 @@ static int pagerSyncHotJournal(Pager *pPager){
SQLITE_PRIVATE int sqlite3PagerClose(Pager *pPager){
u8 *pTmp = (u8 *)pPager->pTmpSpace;
+ assert( assert_pager_state(pPager) );
disable_simulated_io_errors();
sqlite3BeginBenignMalloc();
/* pPager->errCode = 0; */
@@ -40637,7 +41274,7 @@ SQLITE_PRIVATE void sqlite3PagerRef(DbPage *pPg){
**
** If the Pager.noSync flag is set, then this function is a no-op.
** Otherwise, the actions required depend on the journal-mode and the
-** device characteristics of the the file-system, as follows:
+** device characteristics of the file-system, as follows:
**
** * If the journal file is an in-memory journal file, no action need
** be taken.
@@ -40831,7 +41468,7 @@ static int pager_write_pagelist(Pager *pPager, PgHdr *pList){
assert( rc!=SQLITE_OK || isOpen(pPager->fd) );
if( rc==SQLITE_OK && pPager->dbSize>pPager->dbHintSize ){
sqlite3_int64 szFile = pPager->pageSize * (sqlite3_int64)pPager->dbSize;
- sqlite3OsFileControl(pPager->fd, SQLITE_FCNTL_SIZE_HINT, &szFile);
+ sqlite3OsFileControlHint(pPager->fd, SQLITE_FCNTL_SIZE_HINT, &szFile);
pPager->dbHintSize = pPager->dbSize;
}
@@ -40869,6 +41506,7 @@ static int pager_write_pagelist(Pager *pPager, PgHdr *pList){
if( pgno>pPager->dbFileSize ){
pPager->dbFileSize = pgno;
}
+ pPager->aStat[PAGER_STAT_WRITE]++;
/* Update any backup objects copying the contents of this pager. */
sqlite3BackupUpdate(pPager->pBackup, pgno, (u8*)pList->pData);
@@ -40877,7 +41515,6 @@ static int pager_write_pagelist(Pager *pPager, PgHdr *pList){
PAGERID(pPager), pgno, pager_pagehash(pList)));
IOTRACE(("PGOUT %p %d\n", pPager, pgno));
PAGER_INCR(sqlite3_pager_writedb_count);
- PAGER_INCR(pPager->nWrite);
}else{
PAGERTRACE(("NOSTORE %d page %d\n", PAGERID(pPager), pgno));
}
@@ -40940,7 +41577,7 @@ static int subjournalPage(PgHdr *pPg){
** write the journal record into the file. */
if( rc==SQLITE_OK ){
void *pData = pPg->pData;
- i64 offset = pPager->nSubRec*(4+pPager->pageSize);
+ i64 offset = (i64)pPager->nSubRec*(4+pPager->pageSize);
char *pData2;
CODEC2(pPager, pData, pPg->pgno, 7, return SQLITE_NOMEM, pData2);
@@ -40995,7 +41632,7 @@ static int pagerStress(void *p, PgHdr *pPg){
**
** Spilling is also prohibited when in an error state since that could
** lead to database corruption. In the current implementaton it
- ** is impossible for sqlite3PCacheFetch() to be called with createFlag==1
+ ** is impossible for sqlite3PcacheFetch() to be called with createFlag==1
** while in the error state, hence it is impossible for this routine to
** be called in the error state. Nevertheless, we include a NEVER()
** test for the error state as a safeguard against future changes.
@@ -41013,7 +41650,7 @@ static int pagerStress(void *p, PgHdr *pPg){
rc = subjournalPage(pPg);
}
if( rc==SQLITE_OK ){
- rc = pagerWalFrames(pPager, pPg, 0, 0, 0);
+ rc = pagerWalFrames(pPager, pPg, 0, 0);
}
}else{
@@ -41092,7 +41729,7 @@ static int pagerStress(void *p, PgHdr *pPg){
**
** The flags argument is used to specify properties that affect the
** operation of the pager. It should be passed some bitwise combination
-** of the PAGER_OMIT_JOURNAL and PAGER_NO_READLOCK flags.
+** of the PAGER_* flags.
**
** The vfsFlags parameter is a bitmask to pass to the flags parameter
** of the xOpen() method of the supplied VFS when opening files.
@@ -41123,7 +41760,6 @@ SQLITE_PRIVATE int sqlite3PagerOpen(
char *zPathname = 0; /* Full path to database file */
int nPathname = 0; /* Number of bytes in zPathname */
int useJournal = (flags & PAGER_OMIT_JOURNAL)==0; /* False to omit journal */
- int noReadlock = (flags & PAGER_NO_READLOCK)!=0; /* True to omit read-lock */
int pcacheSize = sqlite3PcacheSize(); /* Bytes to allocate for PCache */
u32 szPageDflt = SQLITE_DEFAULT_PAGE_SIZE; /* Default page size */
const char *zUri = 0; /* URI args to copy */
@@ -41149,7 +41785,12 @@ SQLITE_PRIVATE int sqlite3PagerOpen(
#ifndef SQLITE_OMIT_MEMORYDB
if( flags & PAGER_MEMORY ){
memDb = 1;
- zFilename = 0;
+ if( zFilename && zFilename[0] ){
+ zPathname = sqlite3DbStrDup(0, zFilename);
+ if( zPathname==0 ) return SQLITE_NOMEM;
+ nPathname = sqlite3Strlen30(zPathname);
+ zFilename = 0;
+ }
}
#endif
@@ -41160,7 +41801,7 @@ SQLITE_PRIVATE int sqlite3PagerOpen(
if( zFilename && zFilename[0] ){
const char *z;
nPathname = pVfs->mxPathname+1;
- zPathname = sqlite3Malloc(nPathname*2);
+ zPathname = sqlite3DbMallocRaw(0, nPathname*2);
if( zPathname==0 ){
return SQLITE_NOMEM;
}
@@ -41172,7 +41813,8 @@ SQLITE_PRIVATE int sqlite3PagerOpen(
z += sqlite3Strlen30(z)+1;
z += sqlite3Strlen30(z)+1;
}
- nUri = &z[1] - zUri;
+ nUri = (int)(&z[1] - zUri);
+ assert( nUri>=0 );
if( rc==SQLITE_OK && nPathname+8>pVfs->mxPathname ){
/* This branch is taken when the journal path required by
** the database being opened will be more than pVfs->mxPathname
@@ -41183,7 +41825,7 @@ SQLITE_PRIVATE int sqlite3PagerOpen(
rc = SQLITE_CANTOPEN_BKPT;
}
if( rc!=SQLITE_OK ){
- sqlite3_free(zPathname);
+ sqlite3DbFree(0, zPathname);
return rc;
}
}
@@ -41206,14 +41848,14 @@ SQLITE_PRIVATE int sqlite3PagerOpen(
ROUND8(pVfs->szOsFile) + /* The main db file */
journalFileSize * 2 + /* The two journal files */
nPathname + 1 + nUri + /* zFilename */
- nPathname + 8 + 1 /* zJournal */
+ nPathname + 8 + 2 /* zJournal */
#ifndef SQLITE_OMIT_WAL
- + nPathname + 4 + 1 /* zWal */
+ + nPathname + 4 + 2 /* zWal */
#endif
);
assert( EIGHT_BYTE_ALIGNMENT(SQLITE_INT_TO_PTR(journalFileSize)) );
if( !pPtr ){
- sqlite3_free(zPathname);
+ sqlite3DbFree(0, zPathname);
return SQLITE_NOMEM;
}
pPager = (Pager*)(pPtr);
@@ -41229,17 +41871,17 @@ SQLITE_PRIVATE int sqlite3PagerOpen(
assert( nPathname>0 );
pPager->zJournal = (char*)(pPtr += nPathname + 1 + nUri);
memcpy(pPager->zFilename, zPathname, nPathname);
- memcpy(&pPager->zFilename[nPathname+1], zUri, nUri);
+ if( nUri ) memcpy(&pPager->zFilename[nPathname+1], zUri, nUri);
memcpy(pPager->zJournal, zPathname, nPathname);
- memcpy(&pPager->zJournal[nPathname], "-journal", 8);
+ memcpy(&pPager->zJournal[nPathname], "-journal\000", 8+2);
sqlite3FileSuffix3(pPager->zFilename, pPager->zJournal);
#ifndef SQLITE_OMIT_WAL
pPager->zWal = &pPager->zJournal[nPathname+8+1];
memcpy(pPager->zWal, zPathname, nPathname);
- memcpy(&pPager->zWal[nPathname], "-wal", 4);
+ memcpy(&pPager->zWal[nPathname], "-wal\000", 4+1);
sqlite3FileSuffix3(pPager->zFilename, pPager->zWal);
#endif
- sqlite3_free(zPathname);
+ sqlite3DbFree(0, zPathname);
}
pPager->pVfs = pVfs;
pPager->vfsFlags = vfsFlags;
@@ -41329,7 +41971,6 @@ SQLITE_PRIVATE int sqlite3PagerOpen(
IOTRACE(("OPEN %p %s\n", pPager, pPager->zFilename))
pPager->useJournal = (u8)useJournal;
- pPager->noReadlock = (noReadlock && readOnly) ?1:0;
/* pPager->stmtOpen = 0; */
/* pPager->stmtInUse = 0; */
/* pPager->nRef = 0; */
@@ -41352,9 +41993,17 @@ SQLITE_PRIVATE int sqlite3PagerOpen(
pPager->readOnly = (u8)readOnly;
assert( useJournal || pPager->tempFile );
pPager->noSync = pPager->tempFile;
- pPager->fullSync = pPager->noSync ?0:1;
- pPager->syncFlags = pPager->noSync ? 0 : SQLITE_SYNC_NORMAL;
- pPager->ckptSyncFlags = pPager->syncFlags;
+ if( pPager->noSync ){
+ assert( pPager->fullSync==0 );
+ assert( pPager->syncFlags==0 );
+ assert( pPager->walSyncFlags==0 );
+ assert( pPager->ckptSyncFlags==0 );
+ }else{
+ pPager->fullSync = 1;
+ pPager->syncFlags = SQLITE_SYNC_NORMAL;
+ pPager->walSyncFlags = SQLITE_SYNC_NORMAL | WAL_SYNC_TRANSACTIONS;
+ pPager->ckptSyncFlags = SQLITE_SYNC_NORMAL;
+ }
/* pPager->pFirst = 0; */
/* pPager->pFirstSynced = 0; */
/* pPager->pLast = 0; */
@@ -41543,14 +42192,11 @@ SQLITE_PRIVATE int sqlite3PagerSharedLock(Pager *pPager){
int bHotJournal = 1; /* True if there exists a hot journal-file */
assert( !MEMDB );
- assert( pPager->noReadlock==0 || pPager->readOnly );
- if( pPager->noReadlock==0 ){
- rc = pager_wait_on_lock(pPager, SHARED_LOCK);
- if( rc!=SQLITE_OK ){
- assert( pPager->eLock==NO_LOCK || pPager->eLock==UNKNOWN_LOCK );
- goto failed;
- }
+ rc = pager_wait_on_lock(pPager, SHARED_LOCK);
+ if( rc!=SQLITE_OK ){
+ assert( pPager->eLock==NO_LOCK || pPager->eLock==UNKNOWN_LOCK );
+ goto failed;
}
/* If a journal file exists, and there is no RESERVED lock on the
@@ -41563,6 +42209,11 @@ SQLITE_PRIVATE int sqlite3PagerSharedLock(Pager *pPager){
goto failed;
}
if( bHotJournal ){
+ if( pPager->readOnly ){
+ rc = SQLITE_READONLY_ROLLBACK;
+ goto failed;
+ }
+
/* Get an EXCLUSIVE lock on the database file. At this point it is
** important that a RESERVED lock is not obtained on the way to the
** EXCLUSIVE lock. If it were, another process might open the
@@ -41831,14 +42482,13 @@ SQLITE_PRIVATE int sqlite3PagerAcquire(
/* In this case the pcache already contains an initialized copy of
** the page. Return without further ado. */
assert( pgno<=PAGER_MAX_PGNO && pgno!=PAGER_MJ_PGNO(pPager) );
- PAGER_INCR(pPager->nHit);
+ pPager->aStat[PAGER_STAT_HIT]++;
return SQLITE_OK;
}else{
/* The pager cache has created a new page. Its content needs to
** be initialized. */
- PAGER_INCR(pPager->nMiss);
pPg = *ppPage;
pPg->pPager = pPager;
@@ -41874,6 +42524,7 @@ SQLITE_PRIVATE int sqlite3PagerAcquire(
IOTRACE(("ZERO %p %d\n", pPager, pgno));
}else{
assert( pPg->pPager==pPager );
+ pPager->aStat[PAGER_STAT_MISS]++;
rc = readDbPage(pPg);
if( rc!=SQLITE_OK ){
goto pager_acquire_err;
@@ -42429,7 +43080,7 @@ static int pager_incr_changecounter(Pager *pPager, int isDirectMode){
# define DIRECT_MODE isDirectMode
#endif
- if( !pPager->changeCountDone && pPager->dbSize>0 ){
+ if( !pPager->changeCountDone && ALWAYS(pPager->dbSize>0) ){
PgHdr *pPgHdr; /* Reference to page 1 */
assert( !pPager->tempFile && isOpen(pPager->fd) );
@@ -42458,6 +43109,7 @@ static int pager_incr_changecounter(Pager *pPager, int isDirectMode){
CODEC2(pPager, pPgHdr->pData, 1, 6, rc=SQLITE_NOMEM, zBuf);
if( rc==SQLITE_OK ){
rc = sqlite3OsWrite(pPager->fd, zBuf, pPager->pageSize, 0);
+ pPager->aStat[PAGER_STAT_WRITE]++;
}
if( rc==SQLITE_OK ){
pPager->changeCountDone = 1;
@@ -42487,7 +43139,10 @@ SQLITE_PRIVATE int sqlite3PagerSync(Pager *pPager){
rc = sqlite3OsSync(pPager->fd, pPager->syncFlags);
}else if( isOpen(pPager->fd) ){
assert( !MEMDB );
- sqlite3OsFileControl(pPager->fd, SQLITE_FCNTL_SYNC_OMITTED, (void *)&rc);
+ rc = sqlite3OsFileControl(pPager->fd, SQLITE_FCNTL_SYNC_OMITTED, 0);
+ if( rc==SQLITE_NOTFOUND ){
+ rc = SQLITE_OK;
+ }
}
return rc;
}
@@ -42584,9 +43239,7 @@ SQLITE_PRIVATE int sqlite3PagerCommitPhaseOne(
}
assert( rc==SQLITE_OK );
if( ALWAYS(pList) ){
- rc = pagerWalFrames(pPager, pList, pPager->dbSize, 1,
- (pPager->fullSync ? pPager->syncFlags : 0)
- );
+ rc = pagerWalFrames(pPager, pList, pPager->dbSize, 1);
}
sqlite3PagerUnref(pPageOne);
if( rc==SQLITE_OK ){
@@ -42645,38 +43298,6 @@ SQLITE_PRIVATE int sqlite3PagerCommitPhaseOne(
#endif
if( rc!=SQLITE_OK ) goto commit_phase_one_exit;
- /* If this transaction has made the database smaller, then all pages
- ** being discarded by the truncation must be written to the journal
- ** file. This can only happen in auto-vacuum mode.
- **
- ** Before reading the pages with page numbers larger than the
- ** current value of Pager.dbSize, set dbSize back to the value
- ** that it took at the start of the transaction. Otherwise, the
- ** calls to sqlite3PagerGet() return zeroed pages instead of
- ** reading data from the database file.
- */
- #ifndef SQLITE_OMIT_AUTOVACUUM
- if( pPager->dbSize<pPager->dbOrigSize
- && pPager->journalMode!=PAGER_JOURNALMODE_OFF
- ){
- Pgno i; /* Iterator variable */
- const Pgno iSkip = PAGER_MJ_PGNO(pPager); /* Pending lock page */
- const Pgno dbSize = pPager->dbSize; /* Database image size */
- pPager->dbSize = pPager->dbOrigSize;
- for( i=dbSize+1; i<=pPager->dbOrigSize; i++ ){
- if( !sqlite3BitvecTest(pPager->pInJournal, i) && i!=iSkip ){
- PgHdr *pPage; /* Page to journal */
- rc = sqlite3PagerGet(pPager, i, &pPage);
- if( rc!=SQLITE_OK ) goto commit_phase_one_exit;
- rc = sqlite3PagerWrite(pPage);
- sqlite3PagerUnref(pPage);
- if( rc!=SQLITE_OK ) goto commit_phase_one_exit;
- }
- }
- pPager->dbSize = dbSize;
- }
- #endif
-
/* Write the master journal name into the journal file. If a master
** journal file name has already been written to the journal file,
** or if zMaster is NULL (no master journal), then this call is a no-op.
@@ -42704,11 +43325,14 @@ SQLITE_PRIVATE int sqlite3PagerCommitPhaseOne(
goto commit_phase_one_exit;
}
sqlite3PcacheCleanAll(pPager->pPCache);
-
- /* If the file on disk is not the same size as the database image,
- ** then use pager_truncate to grow or shrink the file here.
- */
- if( pPager->dbSize!=pPager->dbFileSize ){
+
+ /* If the file on disk is smaller than the database image, use
+ ** pager_truncate to grow the file here. This can happen if the database
+ ** image was extended as part of the current transaction and then the
+ ** last page in the db image moved to the free-list. In this case the
+ ** last page is never written out to disk, leaving the database file
+ ** undersized. Fix this now if it is the case. */
+ if( pPager->dbSize>pPager->dbFileSize ){
Pgno nNew = pPager->dbSize - (pPager->dbSize==PAGER_MJ_PGNO(pPager));
assert( pPager->eState==PAGER_WRITER_DBMOD );
rc = pager_truncate(pPager, nNew);
@@ -42781,7 +43405,7 @@ SQLITE_PRIVATE int sqlite3PagerCommitPhaseTwo(Pager *pPager){
}
PAGERTRACE(("COMMIT %d\n", PAGERID(pPager)));
- rc = pager_end_transaction(pPager, pPager->setMaster);
+ rc = pager_end_transaction(pPager, pPager->setMaster, 1);
return pager_error(pPager, rc);
}
@@ -42826,11 +43450,11 @@ SQLITE_PRIVATE int sqlite3PagerRollback(Pager *pPager){
if( pagerUseWal(pPager) ){
int rc2;
rc = sqlite3PagerSavepoint(pPager, SAVEPOINT_ROLLBACK, -1);
- rc2 = pager_end_transaction(pPager, pPager->setMaster);
+ rc2 = pager_end_transaction(pPager, pPager->setMaster, 0);
if( rc==SQLITE_OK ) rc = rc2;
}else if( !isOpen(pPager->jfd) || pPager->eState==PAGER_WRITER_LOCKED ){
int eState = pPager->eState;
- rc = pager_end_transaction(pPager, 0);
+ rc = pager_end_transaction(pPager, 0, 0);
if( !MEMDB && eState>PAGER_WRITER_LOCKED ){
/* This can happen using journal_mode=off. Move the pager to the error
** state to indicate that the contents of the cache may not be trusted.
@@ -42845,7 +43469,8 @@ SQLITE_PRIVATE int sqlite3PagerRollback(Pager *pPager){
}
assert( pPager->eState==PAGER_READER || rc!=SQLITE_OK );
- assert( rc==SQLITE_OK || rc==SQLITE_FULL || (rc&0xFF)==SQLITE_IOERR );
+ assert( rc==SQLITE_OK || rc==SQLITE_FULL
+ || rc==SQLITE_NOMEM || (rc&0xFF)==SQLITE_IOERR );
/* If an error occurs during a ROLLBACK, we can no longer trust the pager
** cache. So call pager_error() on the way out to make any error persistent.
@@ -42899,16 +43524,40 @@ SQLITE_PRIVATE int *sqlite3PagerStats(Pager *pPager){
a[3] = pPager->eState==PAGER_OPEN ? -1 : (int) pPager->dbSize;
a[4] = pPager->eState;
a[5] = pPager->errCode;
- a[6] = pPager->nHit;
- a[7] = pPager->nMiss;
+ a[6] = pPager->aStat[PAGER_STAT_HIT];
+ a[7] = pPager->aStat[PAGER_STAT_MISS];
a[8] = 0; /* Used to be pPager->nOvfl */
a[9] = pPager->nRead;
- a[10] = pPager->nWrite;
+ a[10] = pPager->aStat[PAGER_STAT_WRITE];
return a;
}
#endif
/*
+** Parameter eStat must be either SQLITE_DBSTATUS_CACHE_HIT or
+** SQLITE_DBSTATUS_CACHE_MISS. Before returning, *pnVal is incremented by the
+** current cache hit or miss count, according to the value of eStat. If the
+** reset parameter is non-zero, the cache hit or miss count is zeroed before
+** returning.
+*/
+SQLITE_PRIVATE void sqlite3PagerCacheStat(Pager *pPager, int eStat, int reset, int *pnVal){
+
+ assert( eStat==SQLITE_DBSTATUS_CACHE_HIT
+ || eStat==SQLITE_DBSTATUS_CACHE_MISS
+ || eStat==SQLITE_DBSTATUS_CACHE_WRITE
+ );
+
+ assert( SQLITE_DBSTATUS_CACHE_HIT+1==SQLITE_DBSTATUS_CACHE_MISS );
+ assert( SQLITE_DBSTATUS_CACHE_HIT+2==SQLITE_DBSTATUS_CACHE_WRITE );
+ assert( PAGER_STAT_HIT==0 && PAGER_STAT_MISS==1 && PAGER_STAT_WRITE==2 );
+
+ *pnVal += pPager->aStat[eStat - SQLITE_DBSTATUS_CACHE_HIT];
+ if( reset ){
+ pPager->aStat[eStat - SQLITE_DBSTATUS_CACHE_HIT] = 0;
+ }
+}
+
+/*
** Return true if this is an in-memory pager.
*/
SQLITE_PRIVATE int sqlite3PagerIsMemdb(Pager *pPager){
@@ -43053,9 +43702,16 @@ SQLITE_PRIVATE int sqlite3PagerSavepoint(Pager *pPager, int op, int iSavepoint){
/*
** Return the full pathname of the database file.
+**
+** Except, if the pager is in-memory only, then return an empty string if
+** nullIfMemDb is true. This routine is called with nullIfMemDb==1 when
+** used to report the filename to the user, for compatibility with legacy
+** behavior. But when the Btree needs to know the filename for matching to
+** shared cache, it uses nullIfMemDb==0 so that in-memory databases can
+** participate in shared-cache.
*/
-SQLITE_PRIVATE const char *sqlite3PagerFilename(Pager *pPager){
- return pPager->zFilename;
+SQLITE_PRIVATE const char *sqlite3PagerFilename(Pager *pPager, int nullIfMemDb){
+ return (nullIfMemDb && pPager->memDb) ? "" : pPager->zFilename;
}
/*
@@ -43196,7 +43852,8 @@ SQLITE_PRIVATE int sqlite3PagerMovepage(Pager *pPager, DbPage *pPg, Pgno pgno, i
*/
if( (pPg->flags&PGHDR_NEED_SYNC) && !isCommit ){
needSyncPgno = pPg->pgno;
- assert( pageInJournal(pPg) || pPg->pgno>pPager->dbOrigSize );
+ assert( pPager->journalMode==PAGER_JOURNALMODE_OFF ||
+ pageInJournal(pPg) || pPg->pgno>pPager->dbOrigSize );
assert( pPg->flags&PGHDR_DIRTY );
}
@@ -43461,6 +44118,15 @@ SQLITE_PRIVATE sqlite3_backup **sqlite3PagerBackupPtr(Pager *pPager){
return &pPager->pBackup;
}
+#ifndef SQLITE_OMIT_VACUUM
+/*
+** Unless this is an in-memory or temporary database, clear the pager cache.
+*/
+SQLITE_PRIVATE void sqlite3PagerClearCache(Pager *pPager){
+ if( !MEMDB && pPager->tempFile==0 ) pager_reset(pPager);
+}
+#endif
+
#ifndef SQLITE_OMIT_WAL
/*
** This function is called when the user invokes "PRAGMA wal_checkpoint",
@@ -43522,7 +44188,7 @@ static int pagerOpenWal(Pager *pPager){
int rc = SQLITE_OK;
assert( pPager->pWal==0 && pPager->tempFile==0 );
- assert( pPager->eLock==SHARED_LOCK || pPager->eLock==EXCLUSIVE_LOCK || pPager->noReadlock);
+ assert( pPager->eLock==SHARED_LOCK || pPager->eLock==EXCLUSIVE_LOCK );
/* If the pager is already in exclusive-mode, the WAL module will use
** heap-memory for the wal-index instead of the VFS shared-memory
@@ -43637,6 +44303,22 @@ SQLITE_PRIVATE int sqlite3PagerCloseWal(Pager *pPager){
return rc;
}
+#endif /* !SQLITE_OMIT_WAL */
+
+#ifdef SQLITE_ENABLE_ZIPVFS
+/*
+** A read-lock must be held on the pager when this function is called. If
+** the pager is in WAL mode and the WAL file currently contains one or more
+** frames, return the size in bytes of the page images stored within the
+** WAL frames. Otherwise, if this is not a WAL database or the WAL file
+** is empty, return 0.
+*/
+SQLITE_PRIVATE int sqlite3PagerWalFramesize(Pager *pPager){
+ assert( pPager->eState==PAGER_READER );
+ return sqlite3WalFramesize(pPager->pWal);
+}
+#endif
+
#ifdef SQLITE_HAS_CODEC
/*
** This function is called by the wal module when writing page content
@@ -43652,8 +44334,6 @@ SQLITE_PRIVATE void *sqlite3PagerCodec(PgHdr *pPg){
}
#endif /* SQLITE_HAS_CODEC */
-#endif /* !SQLITE_OMIT_WAL */
-
#endif /* SQLITE_OMIT_DISKIO */
/************** End of pager.c ***********************************************/
@@ -43802,14 +44482,15 @@ SQLITE_PRIVATE void *sqlite3PagerCodec(PgHdr *pPg){
** byte order of the host computer.
**
** The purpose of the wal-index is to answer this question quickly: Given
-** a page number P, return the index of the last frame for page P in the WAL,
-** or return NULL if there are no frames for page P in the WAL.
+** a page number P and a maximum frame index M, return the index of the
+** last frame in the wal before frame M for page P in the WAL, or return
+** NULL if there are no frames for page P in the WAL prior to M.
**
** The wal-index consists of a header region, followed by an one or
** more index blocks.
**
** The wal-index header contains the total number of frames within the WAL
-** in the the mxFrame field.
+** in the mxFrame field.
**
** Each index block except for the first contains information on
** HASHTABLE_NPAGE frames. The first index block contains information on
@@ -44073,13 +44754,18 @@ struct Wal {
u32 iCallback; /* Value to pass to log callback (or 0) */
i64 mxWalSize; /* Truncate WAL to this size upon reset */
int nWiData; /* Size of array apWiData */
+ int szFirstBlock; /* Size of first block written to WAL file */
volatile u32 **apWiData; /* Pointer to wal-index content in memory */
u32 szPage; /* Database page size */
i16 readLock; /* Which read lock is being held. -1 for none */
+ u8 syncFlags; /* Flags to use to sync header writes */
u8 exclusiveMode; /* Non-zero if connection is in exclusive mode */
u8 writeLock; /* True if in a write transaction */
u8 ckptLock; /* True if holding a checkpoint lock */
u8 readOnly; /* WAL_RDWR, WAL_RDONLY, or WAL_SHM_RDONLY */
+ u8 truncateOnCommit; /* True to truncate WAL file on commit */
+ u8 syncHeader; /* Fsync the WAL header if true */
+ u8 padToSectorBoundary; /* Pad transactions out to the next sector */
WalIndexHdr hdr; /* Wal-index header for current transaction */
const char *zWalName; /* Name of WAL file */
u32 nCkpt; /* Checkpoint sequence counter in the wal-header */
@@ -44752,6 +45438,7 @@ static int walIndexRecover(Wal *pWal){
int szPage; /* Page size according to the log */
u32 magic; /* Magic value read from WAL header */
u32 version; /* Magic value read from WAL header */
+ int isValid; /* True if this frame is valid */
/* Read in the WAL header. */
rc = sqlite3OsRead(pWal->pWalFd, aBuf, WAL_HDRSIZE, 0);
@@ -44810,14 +45497,14 @@ static int walIndexRecover(Wal *pWal){
for(iOffset=WAL_HDRSIZE; (iOffset+szFrame)<=nSize; iOffset+=szFrame){
u32 pgno; /* Database page number for frame */
u32 nTruncate; /* dbsize field from frame header */
- int isValid; /* True if this frame is valid */
/* Read and decode the next log frame. */
+ iFrame++;
rc = sqlite3OsRead(pWal->pWalFd, aFrame, szFrame, iOffset);
if( rc!=SQLITE_OK ) break;
isValid = walDecodeFrame(pWal, &pgno, &nTruncate, aData, aFrame);
if( !isValid ) break;
- rc = walIndexAppend(pWal, ++iFrame, pgno);
+ rc = walIndexAppend(pWal, iFrame, pgno);
if( rc!=SQLITE_OK ) break;
/* If nTruncate is non-zero, this is a commit record. */
@@ -44851,6 +45538,7 @@ finished:
pInfo->nBackfill = 0;
pInfo->aReadMark[0] = 0;
for(i=1; i<WAL_NREADER; i++) pInfo->aReadMark[i] = READMARK_NOT_USED;
+ if( pWal->hdr.mxFrame ) pInfo->aReadMark[1] = pWal->hdr.mxFrame;
/* If more than one frame was recovered from the log file, report an
** event via sqlite3_log(). This is to help with identifying performance
@@ -44940,6 +45628,8 @@ SQLITE_PRIVATE int sqlite3WalOpen(
pRet->readLock = -1;
pRet->mxWalSize = mxWalSize;
pRet->zWalName = zWalName;
+ pRet->syncHeader = 1;
+ pRet->padToSectorBoundary = 1;
pRet->exclusiveMode = (bNoShm ? WAL_HEAPMEMORY_MODE: WAL_NORMAL_MODE);
/* Open file handle on the write-ahead log file. */
@@ -44954,6 +45644,11 @@ SQLITE_PRIVATE int sqlite3WalOpen(
sqlite3OsClose(pRet->pWalFd);
sqlite3_free(pRet);
}else{
+ int iDC = sqlite3OsDeviceCharacteristics(pRet->pWalFd);
+ if( iDC & SQLITE_IOCAP_SEQUENTIAL ){ pRet->syncHeader = 0; }
+ if( iDC & SQLITE_IOCAP_POWERSAFE_OVERWRITE ){
+ pRet->padToSectorBoundary = 0;
+ }
*ppWal = pRet;
WALTRACE(("WAL%d: opened\n", pRet));
}
@@ -45344,7 +46039,7 @@ static int walCheckpoint(
assert( y<=pWal->hdr.mxFrame );
rc = walBusyLock(pWal, xBusy, pBusyArg, WAL_READ_LOCK(i), 1);
if( rc==SQLITE_OK ){
- pInfo->aReadMark[i] = READMARK_NOT_USED;
+ pInfo->aReadMark[i] = (i==1 ? mxSafeFrame : READMARK_NOT_USED);
walUnlockExclusive(pWal, WAL_READ_LOCK(i), 1);
}else if( rc==SQLITE_BUSY ){
mxSafeFrame = y;
@@ -45373,7 +46068,7 @@ static int walCheckpoint(
i64 nReq = ((i64)mxPage * szPage);
rc = sqlite3OsFileSize(pWal->pDbFd, &nSize);
if( rc==SQLITE_OK && nSize<nReq ){
- sqlite3OsFileControl(pWal->pDbFd, SQLITE_FCNTL_SIZE_HINT, &nReq);
+ sqlite3OsFileControlHint(pWal->pDbFd, SQLITE_FCNTL_SIZE_HINT, &nReq);
}
}
@@ -45441,6 +46136,24 @@ static int walCheckpoint(
}
/*
+** If the WAL file is currently larger than nMax bytes in size, truncate
+** it to exactly nMax bytes. If an error occurs while doing so, ignore it.
+*/
+static void walLimitSize(Wal *pWal, i64 nMax){
+ i64 sz;
+ int rx;
+ sqlite3BeginBenignMalloc();
+ rx = sqlite3OsFileSize(pWal->pWalFd, &sz);
+ if( rx==SQLITE_OK && (sz > nMax ) ){
+ rx = sqlite3OsTruncate(pWal->pWalFd, nMax);
+ }
+ sqlite3EndBenignMalloc();
+ if( rx ){
+ sqlite3_log(rx, "cannot limit WAL size: %s", pWal->zWalName);
+ }
+}
+
+/*
** Close a connection to a log file.
*/
SQLITE_PRIVATE int sqlite3WalClose(
@@ -45470,14 +46183,33 @@ SQLITE_PRIVATE int sqlite3WalClose(
pWal, SQLITE_CHECKPOINT_PASSIVE, 0, 0, sync_flags, nBuf, zBuf, 0, 0
);
if( rc==SQLITE_OK ){
- isDelete = 1;
+ int bPersist = -1;
+ sqlite3OsFileControlHint(
+ pWal->pDbFd, SQLITE_FCNTL_PERSIST_WAL, &bPersist
+ );
+ if( bPersist!=1 ){
+ /* Try to delete the WAL file if the checkpoint completed and
+ ** fsyned (rc==SQLITE_OK) and if we are not in persistent-wal
+ ** mode (!bPersist) */
+ isDelete = 1;
+ }else if( pWal->mxWalSize>=0 ){
+ /* Try to truncate the WAL file to zero bytes if the checkpoint
+ ** completed and fsynced (rc==SQLITE_OK) and we are in persistent
+ ** WAL mode (bPersist) and if the PRAGMA journal_size_limit is a
+ ** non-negative value (pWal->mxWalSize>=0). Note that we truncate
+ ** to zero bytes as truncating to the journal_size_limit might
+ ** leave a corrupt WAL file on disk. */
+ walLimitSize(pWal, 0);
+ }
}
}
walIndexClose(pWal, isDelete);
sqlite3OsClose(pWal->pWalFd);
if( isDelete ){
+ sqlite3BeginBenignMalloc();
sqlite3OsDelete(pWal->pVfs, pWal->zWalName, 0);
+ sqlite3EndBenignMalloc();
}
WALTRACE(("WAL%p: closed\n", pWal));
sqlite3_free((void *)pWal->apWiData);
@@ -45967,7 +46699,7 @@ SQLITE_PRIVATE int sqlite3WalRead(
for(iKey=walHash(pgno); aHash[iKey]; iKey=walNextHash(iKey)){
u32 iFrame = aHash[iKey] + iZero;
if( iFrame<=iLast && aPgno[aHash[iKey]]==pgno ){
- assert( iFrame>iRead );
+ /* assert( iFrame>iRead ); -- not true if there is corruption */
iRead = iFrame;
}
if( (nCollide--)==0 ){
@@ -46000,13 +46732,13 @@ SQLITE_PRIVATE int sqlite3WalRead(
int sz;
i64 iOffset;
sz = pWal->hdr.szPage;
- sz = (pWal->hdr.szPage&0xfe00) + ((pWal->hdr.szPage&0x0001)<<16);
+ sz = (sz&0xfe00) + ((sz&0x0001)<<16);
testcase( sz<=32768 );
testcase( sz>=65536 );
iOffset = walFrameOffset(iRead, sz) + WAL_FRAME_HDRSIZE;
*pInWal = 1;
/* testcase( IS_BIG_INT(iOffset) ); // requires a 4GiB WAL */
- return sqlite3OsRead(pWal->pWalFd, pOut, nOut, iOffset);
+ return sqlite3OsRead(pWal->pWalFd, pOut, (nOut>sz ? sz : nOut), iOffset);
}
*pInWal = 0;
@@ -46079,6 +46811,7 @@ SQLITE_PRIVATE int sqlite3WalEndWriteTransaction(Wal *pWal){
if( pWal->writeLock ){
walUnlockExclusive(pWal, WAL_WRITE_LOCK, 1);
pWal->writeLock = 0;
+ pWal->truncateOnCommit = 0;
}
return SQLITE_OK;
}
@@ -46124,7 +46857,7 @@ SQLITE_PRIVATE int sqlite3WalUndo(Wal *pWal, int (*xUndo)(void *, Pgno), void *p
assert( walFramePgno(pWal, iFrame)!=1 );
rc = xUndo(pUndoCtx, walFramePgno(pWal, iFrame));
}
- walCleanupHash(pWal);
+ if( iMax!=pWal->hdr.mxFrame ) walCleanupHash(pWal);
}
assert( rc==SQLITE_OK );
return rc;
@@ -46175,6 +46908,7 @@ SQLITE_PRIVATE int sqlite3WalSavepointUndo(Wal *pWal, u32 *aWalData){
return rc;
}
+
/*
** This function is called just before writing a set of frames to the log
** file (see sqlite3WalFrames()). It checks to see if, instead of appending
@@ -46212,30 +46946,14 @@ static int walRestartLog(Wal *pWal){
int i; /* Loop counter */
u32 *aSalt = pWal->hdr.aSalt; /* Big-endian salt values */
- /* Limit the size of WAL file if the journal_size_limit PRAGMA is
- ** set to a non-negative value. Log errors encountered
- ** during the truncation attempt. */
- if( pWal->mxWalSize>=0 ){
- i64 sz;
- int rx;
- sqlite3BeginBenignMalloc();
- rx = sqlite3OsFileSize(pWal->pWalFd, &sz);
- if( rx==SQLITE_OK && (sz > pWal->mxWalSize) ){
- rx = sqlite3OsTruncate(pWal->pWalFd, pWal->mxWalSize);
- }
- sqlite3EndBenignMalloc();
- if( rx ){
- sqlite3_log(rx, "cannot limit WAL size: %s", pWal->zWalName);
- }
- }
-
pWal->nCkpt++;
pWal->hdr.mxFrame = 0;
sqlite3Put4byte((u8*)&aSalt[0], 1 + sqlite3Get4byte((u8*)&aSalt[0]));
aSalt[1] = salt1;
walIndexWriteHdr(pWal);
pInfo->nBackfill = 0;
- for(i=1; i<WAL_NREADER; i++) pInfo->aReadMark[i] = READMARK_NOT_USED;
+ pInfo->aReadMark[1] = 0;
+ for(i=2; i<WAL_NREADER; i++) pInfo->aReadMark[i] = READMARK_NOT_USED;
assert( pInfo->aReadMark[0]==0 );
walUnlockExclusive(pWal, WAL_READ_LOCK(1), WAL_NREADER-1);
}else if( rc!=SQLITE_BUSY ){
@@ -46257,6 +46975,74 @@ static int walRestartLog(Wal *pWal){
return rc;
}
+/*
+** Information about the current state of the WAL file and where
+** the next fsync should occur - passed from sqlite3WalFrames() into
+** walWriteToLog().
+*/
+typedef struct WalWriter {
+ Wal *pWal; /* The complete WAL information */
+ sqlite3_file *pFd; /* The WAL file to which we write */
+ sqlite3_int64 iSyncPoint; /* Fsync at this offset */
+ int syncFlags; /* Flags for the fsync */
+ int szPage; /* Size of one page */
+} WalWriter;
+
+/*
+** Write iAmt bytes of content into the WAL file beginning at iOffset.
+** Do a sync when crossing the p->iSyncPoint boundary.
+**
+** In other words, if iSyncPoint is in between iOffset and iOffset+iAmt,
+** first write the part before iSyncPoint, then sync, then write the
+** rest.
+*/
+static int walWriteToLog(
+ WalWriter *p, /* WAL to write to */
+ void *pContent, /* Content to be written */
+ int iAmt, /* Number of bytes to write */
+ sqlite3_int64 iOffset /* Start writing at this offset */
+){
+ int rc;
+ if( iOffset<p->iSyncPoint && iOffset+iAmt>=p->iSyncPoint ){
+ int iFirstAmt = (int)(p->iSyncPoint - iOffset);
+ rc = sqlite3OsWrite(p->pFd, pContent, iFirstAmt, iOffset);
+ if( rc ) return rc;
+ iOffset += iFirstAmt;
+ iAmt -= iFirstAmt;
+ pContent = (void*)(iFirstAmt + (char*)pContent);
+ assert( p->syncFlags & (SQLITE_SYNC_NORMAL|SQLITE_SYNC_FULL) );
+ rc = sqlite3OsSync(p->pFd, p->syncFlags);
+ if( iAmt==0 || rc ) return rc;
+ }
+ rc = sqlite3OsWrite(p->pFd, pContent, iAmt, iOffset);
+ return rc;
+}
+
+/*
+** Write out a single frame of the WAL
+*/
+static int walWriteOneFrame(
+ WalWriter *p, /* Where to write the frame */
+ PgHdr *pPage, /* The page of the frame to be written */
+ int nTruncate, /* The commit flag. Usually 0. >0 for commit */
+ sqlite3_int64 iOffset /* Byte offset at which to write */
+){
+ int rc; /* Result code from subfunctions */
+ void *pData; /* Data actually written */
+ u8 aFrame[WAL_FRAME_HDRSIZE]; /* Buffer to assemble frame-header in */
+#if defined(SQLITE_HAS_CODEC)
+ if( (pData = sqlite3PagerCodec(pPage))==0 ) return SQLITE_NOMEM;
+#else
+ pData = pPage->pData;
+#endif
+ walEncodeFrame(p->pWal, pPage->pgno, nTruncate, pData, aFrame);
+ rc = walWriteToLog(p, aFrame, sizeof(aFrame), iOffset);
+ if( rc ) return rc;
+ /* Write the page data */
+ rc = walWriteToLog(p, pData, p->szPage, iOffset+sizeof(aFrame));
+ return rc;
+}
+
/*
** Write a set of frames to the log. The caller must hold the write-lock
** on the log file (obtained using sqlite3WalBeginWriteTransaction()).
@@ -46271,14 +47057,20 @@ SQLITE_PRIVATE int sqlite3WalFrames(
){
int rc; /* Used to catch return codes */
u32 iFrame; /* Next frame address */
- u8 aFrame[WAL_FRAME_HDRSIZE]; /* Buffer to assemble frame-header in */
PgHdr *p; /* Iterator to run through pList with. */
PgHdr *pLast = 0; /* Last frame in list */
- int nLast = 0; /* Number of extra copies of last page */
+ int nExtra = 0; /* Number of extra copies of last page */
+ int szFrame; /* The size of a single frame */
+ i64 iOffset; /* Next byte to write in WAL file */
+ WalWriter w; /* The writer */
assert( pList );
assert( pWal->writeLock );
+ /* If this frame set completes a transaction, then nTruncate>0. If
+ ** nTruncate==0 then this frame set does not complete the transaction. */
+ assert( (isCommit!=0)==(nTruncate!=0) );
+
#if defined(SQLITE_TEST) && defined(SQLITE_DEBUG)
{ int cnt; for(cnt=0, p=pList; p; p=p->pDirty, cnt++){}
WALTRACE(("WAL%p: frame write begin. %d frames. mxFrame=%d. %s\n",
@@ -46306,7 +47098,7 @@ SQLITE_PRIVATE int sqlite3WalFrames(
sqlite3Put4byte(&aWalHdr[4], WAL_MAX_VERSION);
sqlite3Put4byte(&aWalHdr[8], szPage);
sqlite3Put4byte(&aWalHdr[12], pWal->nCkpt);
- sqlite3_randomness(8, pWal->hdr.aSalt);
+ if( pWal->nCkpt==0 ) sqlite3_randomness(8, pWal->hdr.aSalt);
memcpy(&aWalHdr[16], pWal->hdr.aSalt, 8);
walChecksumBytes(1, aWalHdr, WAL_HDRSIZE-2*4, 0, aCksum);
sqlite3Put4byte(&aWalHdr[24], aCksum[0]);
@@ -46316,77 +47108,89 @@ SQLITE_PRIVATE int sqlite3WalFrames(
pWal->hdr.bigEndCksum = SQLITE_BIGENDIAN;
pWal->hdr.aFrameCksum[0] = aCksum[0];
pWal->hdr.aFrameCksum[1] = aCksum[1];
+ pWal->truncateOnCommit = 1;
rc = sqlite3OsWrite(pWal->pWalFd, aWalHdr, sizeof(aWalHdr), 0);
WALTRACE(("WAL%p: wal-header write %s\n", pWal, rc ? "failed" : "ok"));
if( rc!=SQLITE_OK ){
return rc;
}
+
+ /* Sync the header (unless SQLITE_IOCAP_SEQUENTIAL is true or unless
+ ** all syncing is turned off by PRAGMA synchronous=OFF). Otherwise
+ ** an out-of-order write following a WAL restart could result in
+ ** database corruption. See the ticket:
+ **
+ ** http://localhost:591/sqlite/info/ff5be73dee
+ */
+ if( pWal->syncHeader && sync_flags ){
+ rc = sqlite3OsSync(pWal->pWalFd, sync_flags & SQLITE_SYNC_MASK);
+ if( rc ) return rc;
+ }
}
assert( (int)pWal->szPage==szPage );
- /* Write the log file. */
- for(p=pList; p; p=p->pDirty){
- u32 nDbsize; /* Db-size field for frame header */
- i64 iOffset; /* Write offset in log file */
- void *pData;
-
- iOffset = walFrameOffset(++iFrame, szPage);
- /* testcase( IS_BIG_INT(iOffset) ); // requires a 4GiB WAL */
-
- /* Populate and write the frame header */
- nDbsize = (isCommit && p->pDirty==0) ? nTruncate : 0;
-#if defined(SQLITE_HAS_CODEC)
- if( (pData = sqlite3PagerCodec(p))==0 ) return SQLITE_NOMEM;
-#else
- pData = p->pData;
-#endif
- walEncodeFrame(pWal, p->pgno, nDbsize, pData, aFrame);
- rc = sqlite3OsWrite(pWal->pWalFd, aFrame, sizeof(aFrame), iOffset);
- if( rc!=SQLITE_OK ){
- return rc;
- }
+ /* Setup information needed to write frames into the WAL */
+ w.pWal = pWal;
+ w.pFd = pWal->pWalFd;
+ w.iSyncPoint = 0;
+ w.syncFlags = sync_flags;
+ w.szPage = szPage;
+ iOffset = walFrameOffset(iFrame+1, szPage);
+ szFrame = szPage + WAL_FRAME_HDRSIZE;
- /* Write the page data */
- rc = sqlite3OsWrite(pWal->pWalFd, pData, szPage, iOffset+sizeof(aFrame));
- if( rc!=SQLITE_OK ){
- return rc;
- }
+ /* Write all frames into the log file exactly once */
+ for(p=pList; p; p=p->pDirty){
+ int nDbSize; /* 0 normally. Positive == commit flag */
+ iFrame++;
+ assert( iOffset==walFrameOffset(iFrame, szPage) );
+ nDbSize = (isCommit && p->pDirty==0) ? nTruncate : 0;
+ rc = walWriteOneFrame(&w, p, nDbSize, iOffset);
+ if( rc ) return rc;
pLast = p;
+ iOffset += szFrame;
}
- /* Sync the log file if the 'isSync' flag was specified. */
- if( sync_flags ){
- i64 iSegment = sqlite3OsSectorSize(pWal->pWalFd);
- i64 iOffset = walFrameOffset(iFrame+1, szPage);
-
- assert( isCommit );
- assert( iSegment>0 );
-
- iSegment = (((iOffset+iSegment-1)/iSegment) * iSegment);
- while( iOffset<iSegment ){
- void *pData;
-#if defined(SQLITE_HAS_CODEC)
- if( (pData = sqlite3PagerCodec(pLast))==0 ) return SQLITE_NOMEM;
-#else
- pData = pLast->pData;
-#endif
- walEncodeFrame(pWal, pLast->pgno, nTruncate, pData, aFrame);
- /* testcase( IS_BIG_INT(iOffset) ); // requires a 4GiB WAL */
- rc = sqlite3OsWrite(pWal->pWalFd, aFrame, sizeof(aFrame), iOffset);
- if( rc!=SQLITE_OK ){
- return rc;
- }
- iOffset += WAL_FRAME_HDRSIZE;
- rc = sqlite3OsWrite(pWal->pWalFd, pData, szPage, iOffset);
- if( rc!=SQLITE_OK ){
- return rc;
+ /* If this is the end of a transaction, then we might need to pad
+ ** the transaction and/or sync the WAL file.
+ **
+ ** Padding and syncing only occur if this set of frames complete a
+ ** transaction and if PRAGMA synchronous=FULL. If synchronous==NORMAL
+ ** or synchonous==OFF, then no padding or syncing are needed.
+ **
+ ** If SQLITE_IOCAP_POWERSAFE_OVERWRITE is defined, then padding is not
+ ** needed and only the sync is done. If padding is needed, then the
+ ** final frame is repeated (with its commit mark) until the next sector
+ ** boundary is crossed. Only the part of the WAL prior to the last
+ ** sector boundary is synced; the part of the last frame that extends
+ ** past the sector boundary is written after the sync.
+ */
+ if( isCommit && (sync_flags & WAL_SYNC_TRANSACTIONS)!=0 ){
+ if( pWal->padToSectorBoundary ){
+ int sectorSize = sqlite3SectorSize(pWal->pWalFd);
+ w.iSyncPoint = ((iOffset+sectorSize-1)/sectorSize)*sectorSize;
+ while( iOffset<w.iSyncPoint ){
+ rc = walWriteOneFrame(&w, pLast, nTruncate, iOffset);
+ if( rc ) return rc;
+ iOffset += szFrame;
+ nExtra++;
}
- nLast++;
- iOffset += szPage;
+ }else{
+ rc = sqlite3OsSync(w.pFd, sync_flags & SQLITE_SYNC_MASK);
}
+ }
- rc = sqlite3OsSync(pWal->pWalFd, sync_flags);
+ /* If this frame set completes the first transaction in the WAL and
+ ** if PRAGMA journal_size_limit is set, then truncate the WAL to the
+ ** journal size limit, if possible.
+ */
+ if( isCommit && pWal->truncateOnCommit && pWal->mxWalSize>=0 ){
+ i64 sz = pWal->mxWalSize;
+ if( walFrameOffset(iFrame+nExtra+1, szPage)>pWal->mxWalSize ){
+ sz = walFrameOffset(iFrame+nExtra+1, szPage);
+ }
+ walLimitSize(pWal, sz);
+ pWal->truncateOnCommit = 0;
}
/* Append data to the wal-index. It is not necessary to lock the
@@ -46399,9 +47203,9 @@ SQLITE_PRIVATE int sqlite3WalFrames(
iFrame++;
rc = walIndexAppend(pWal, iFrame, p->pgno);
}
- while( nLast>0 && rc==SQLITE_OK ){
+ while( rc==SQLITE_OK && nExtra>0 ){
iFrame++;
- nLast--;
+ nExtra--;
rc = walIndexAppend(pWal, iFrame, pLast->pgno);
}
@@ -46606,6 +47410,18 @@ SQLITE_PRIVATE int sqlite3WalHeapMemory(Wal *pWal){
return (pWal && pWal->exclusiveMode==WAL_HEAPMEMORY_MODE );
}
+#ifdef SQLITE_ENABLE_ZIPVFS
+/*
+** If the argument is not NULL, it points to a Wal object that holds a
+** read-lock. This function returns the database page-size if it is known,
+** or zero if it is not (or if pWal is NULL).
+*/
+SQLITE_PRIVATE int sqlite3WalFramesize(Wal *pWal){
+ assert( pWal==0 || pWal->readLock>=0 );
+ return (pWal ? pWal->szPage : 0);
+}
+#endif
+
#endif /* #ifndef SQLITE_OMIT_WAL */
/************** End of wal.c *************************************************/
@@ -46907,18 +47723,20 @@ struct MemPage {
u8 hasData; /* True if this page stores data */
u8 hdrOffset; /* 100 for page 1. 0 otherwise */
u8 childPtrSize; /* 0 if leaf==1. 4 if leaf==0 */
+ u8 max1bytePayload; /* min(maxLocal,127) */
u16 maxLocal; /* Copy of BtShared.maxLocal or BtShared.maxLeaf */
u16 minLocal; /* Copy of BtShared.minLocal or BtShared.minLeaf */
u16 cellOffset; /* Index in aData of first cell pointer */
u16 nFree; /* Number of free bytes on the page */
u16 nCell; /* Number of cells on this page, local and ovfl */
u16 maskPage; /* Mask for page offset */
- struct _OvflCell { /* Cells that will not fit on aData[] */
- u8 *pCell; /* Pointers to the body of the overflow cell */
- u16 idx; /* Insert this cell before idx-th non-overflow cell */
- } aOvfl[5];
+ u16 aiOvfl[5]; /* Insert the i-th overflow cell before the aiOvfl-th
+ ** non-overflow cell */
+ u8 *apOvfl[5]; /* Pointers to the body of overflow cells */
BtShared *pBt; /* Pointer to BtShared that this page is part of */
u8 *aData; /* Pointer to disk image of the page data */
+ u8 *aDataEnd; /* One byte past the end of usable data */
+ u8 *aCellIdx; /* The cell index area */
DbPage *pDbPage; /* Pager page handle */
Pgno pgno; /* Page number for this page */
};
@@ -46998,7 +47816,7 @@ struct Btree {
/*
** An instance of this object represents a single database file.
**
-** A single database file can be in use as the same time by two
+** A single database file can be in use at the same time by two
** or more database connections. When two or more connections are
** sharing the same database file, each connection has it own
** private Btree object for the file and each of those Btrees points
@@ -47035,17 +47853,15 @@ struct BtShared {
sqlite3 *db; /* Database connection currently using this Btree */
BtCursor *pCursor; /* A list of all open cursors */
MemPage *pPage1; /* First page of the database */
- u8 readOnly; /* True if the underlying file is readonly */
- u8 pageSizeFixed; /* True if the page size can no longer be changed */
- u8 secureDelete; /* True if secure_delete is enabled */
- u8 initiallyEmpty; /* Database is empty at start of transaction */
u8 openFlags; /* Flags to sqlite3BtreeOpen() */
#ifndef SQLITE_OMIT_AUTOVACUUM
u8 autoVacuum; /* True if auto-vacuum is enabled */
u8 incrVacuum; /* True if incr-vacuum is enabled */
+ u8 bDoTruncate; /* True to truncate db on commit */
#endif
u8 inTransaction; /* Transaction state */
- u8 doNotUseWAL; /* If true, do not open write-ahead-log file */
+ u8 max1bytePayload; /* Maximum first byte of cell for a 1-byte payload */
+ u16 btsFlags; /* Boolean parameters. See BTS_* macros below */
u16 maxLocal; /* Maximum local payload in non-LEAFDATA tables */
u16 minLocal; /* Minimum local payload in non-LEAFDATA tables */
u16 maxLeaf; /* Maximum local payload in a LEAFDATA table */
@@ -47063,13 +47879,22 @@ struct BtShared {
BtShared *pNext; /* Next on a list of sharable BtShared structs */
BtLock *pLock; /* List of locks held on this shared-btree struct */
Btree *pWriter; /* Btree with currently open write transaction */
- u8 isExclusive; /* True if pWriter has an EXCLUSIVE lock on the db */
- u8 isPending; /* If waiting for read-locks to clear */
#endif
u8 *pTmpSpace; /* BtShared.pageSize bytes of space for tmp use */
};
/*
+** Allowed values for BtShared.btsFlags
+*/
+#define BTS_READ_ONLY 0x0001 /* Underlying file is readonly */
+#define BTS_PAGESIZE_FIXED 0x0002 /* Page size can no longer be changed */
+#define BTS_SECURE_DELETE 0x0004 /* PRAGMA secure_delete is enabled */
+#define BTS_INITIALLY_EMPTY 0x0008 /* Database was empty at trans start */
+#define BTS_NO_WAL 0x0010 /* Do not open write-ahead-log files */
+#define BTS_EXCLUSIVE 0x0020 /* pWriter has an exclusive lock */
+#define BTS_PENDING 0x0040 /* Waiting for read-locks to clear */
+
+/*
** An instance of the following structure is used to hold information
** about a cell. The parseCellPtr() function fills in this structure
** based on information extract from the raw disk page.
@@ -47104,7 +47929,7 @@ struct CellInfo {
** The entry is identified by its MemPage and the index in
** MemPage.aCell[] of the entry.
**
-** A single database file can shared by two more database connections,
+** A single database file can be shared by two more database connections,
** but cursors cannot be shared. Each cursor is associated with a
** particular database connection identified BtCursor.pBtree.db.
**
@@ -47116,6 +47941,9 @@ struct BtCursor {
BtShared *pBt; /* The BtShared this cursor points to */
BtCursor *pNext, *pPrev; /* Forms a linked list of all cursors */
struct KeyInfo *pKeyInfo; /* Argument passed to comparison function */
+#ifndef SQLITE_OMIT_INCRBLOB
+ Pgno *aOverflow; /* Cache of overflow page locations */
+#endif
Pgno pgnoRoot; /* The root page of this tree */
sqlite3_int64 cachedRowid; /* Next rowid cache. 0 means not valid */
CellInfo info; /* A parse of the cell we are pointing at */
@@ -47127,9 +47955,9 @@ struct BtCursor {
u8 validNKey; /* True if info.nKey is valid */
u8 eState; /* One of the CURSOR_XXX constants (see below) */
#ifndef SQLITE_OMIT_INCRBLOB
- Pgno *aOverflow; /* Cache of overflow page locations */
u8 isIncrblobHandle; /* True if this cursor is an incr. io handle */
#endif
+ u8 hints; /* As configured by CursorSetHints() */
i16 iPage; /* Index of current page in apPage */
u16 aiIdx[BTCURSOR_MAX_DEPTH]; /* Current index in apPage[i] */
MemPage *apPage[BTCURSOR_MAX_DEPTH]; /* Pages from root to current page */
@@ -47251,13 +48079,19 @@ struct BtCursor {
/*
** This structure is passed around through all the sanity checking routines
** in order to keep track of some global state information.
+**
+** The aRef[] array is allocated so that there is 1 bit for each page in
+** the database. As the integrity-check proceeds, for each page used in
+** the database the corresponding bit is set. This allows integrity-check to
+** detect pages that are used twice and orphaned pages (both of which
+** indicate corruption).
*/
typedef struct IntegrityCk IntegrityCk;
struct IntegrityCk {
BtShared *pBt; /* The tree being checked out */
Pager *pPager; /* The associated pager. Also accessible by pBt->pPager */
+ u8 *aPgRef; /* 1 bit per page in the db (see above) */
Pgno nPage; /* Number of pages in the database */
- int *anRef; /* Number of times each page is referenced */
int mxErr; /* Stop accumulating errors when this reaches zero */
int nErr; /* Number of messages written to zErrMsg so far */
int mallocFailed; /* A memory allocation error has occurred */
@@ -47265,7 +48099,7 @@ struct IntegrityCk {
};
/*
-** Read or write a two- and four-byte big-endian integer values.
+** Routines to read or write a two- and four-byte big-endian integer values.
*/
#define get2byte(x) ((x)[0]<<8 | (x)[1])
#define put2byte(p,v) ((p)[0] = (u8)((v)>>8), (p)[1] = (u8)(v))
@@ -47590,6 +48424,25 @@ int sqlite3BtreeTrace=1; /* True to enable tracing */
*/
#define get2byteNotZero(X) (((((int)get2byte(X))-1)&0xffff)+1)
+/*
+** Values passed as the 5th argument to allocateBtreePage()
+*/
+#define BTALLOC_ANY 0 /* Allocate any page */
+#define BTALLOC_EXACT 1 /* Allocate exact page if possible */
+#define BTALLOC_LE 2 /* Allocate any page <= the parameter */
+
+/*
+** Macro IfNotOmitAV(x) returns (x) if SQLITE_OMIT_AUTOVACUUM is not
+** defined, or 0 if it is. For example:
+**
+** bIncrVacuum = IfNotOmitAV(pBtShared->incrVacuum);
+*/
+#ifndef SQLITE_OMIT_AUTOVACUUM
+#define IfNotOmitAV(expr) (expr)
+#else
+#define IfNotOmitAV(expr) 0
+#endif
+
#ifndef SQLITE_OMIT_SHARED_CACHE
/*
** A list of BtShared objects that are eligible for participation
@@ -47790,7 +48643,7 @@ static int querySharedCacheTableLock(Btree *p, Pgno iTab, u8 eLock){
/* If some other connection is holding an exclusive lock, the
** requested lock may not be obtained.
*/
- if( pBt->pWriter!=p && pBt->isExclusive ){
+ if( pBt->pWriter!=p && (pBt->btsFlags & BTS_EXCLUSIVE)!=0 ){
sqlite3ConnectionBlocked(p->db, pBt->pWriter->db);
return SQLITE_LOCKED_SHAREDCACHE;
}
@@ -47811,7 +48664,7 @@ static int querySharedCacheTableLock(Btree *p, Pgno iTab, u8 eLock){
sqlite3ConnectionBlocked(p->db, pIter->pBtree->db);
if( eLock==WRITE_LOCK ){
assert( p==pBt->pWriter );
- pBt->isPending = 1;
+ pBt->btsFlags |= BTS_PENDING;
}
return SQLITE_LOCKED_SHAREDCACHE;
}
@@ -47899,7 +48752,7 @@ static int setSharedCacheTableLock(Btree *p, Pgno iTable, u8 eLock){
** the setSharedCacheTableLock() procedure) held by Btree object p.
**
** This function assumes that Btree p has an open read or write
-** transaction. If it does not, then the BtShared.isPending variable
+** transaction. If it does not, then the BTS_PENDING flag
** may be incorrectly cleared.
*/
static void clearAllSharedCacheTableLocks(Btree *p){
@@ -47912,7 +48765,7 @@ static void clearAllSharedCacheTableLocks(Btree *p){
while( *ppIter ){
BtLock *pLock = *ppIter;
- assert( pBt->isExclusive==0 || pBt->pWriter==pLock->pBtree );
+ assert( (pBt->btsFlags & BTS_EXCLUSIVE)==0 || pBt->pWriter==pLock->pBtree );
assert( pLock->pBtree->inTrans>=pLock->eLock );
if( pLock->pBtree==p ){
*ppIter = pLock->pNext;
@@ -47925,22 +48778,21 @@ static void clearAllSharedCacheTableLocks(Btree *p){
}
}
- assert( pBt->isPending==0 || pBt->pWriter );
+ assert( (pBt->btsFlags & BTS_PENDING)==0 || pBt->pWriter );
if( pBt->pWriter==p ){
pBt->pWriter = 0;
- pBt->isExclusive = 0;
- pBt->isPending = 0;
+ pBt->btsFlags &= ~(BTS_EXCLUSIVE|BTS_PENDING);
}else if( pBt->nTransaction==2 ){
/* This function is called when Btree p is concluding its
** transaction. If there currently exists a writer, and p is not
** that writer, then the number of locks held by connections other
** than the writer must be about to drop to zero. In this case
- ** set the isPending flag to 0.
+ ** set the BTS_PENDING flag to 0.
**
- ** If there is not currently a writer, then BtShared.isPending must
+ ** If there is not currently a writer, then BTS_PENDING must
** be zero already. So this next line is harmless in that case.
*/
- pBt->isPending = 0;
+ pBt->btsFlags &= ~BTS_PENDING;
}
}
@@ -47952,8 +48804,7 @@ static void downgradeAllSharedCacheTableLocks(Btree *p){
if( pBt->pWriter==p ){
BtLock *pLock;
pBt->pWriter = 0;
- pBt->isExclusive = 0;
- pBt->isPending = 0;
+ pBt->btsFlags &= ~(BTS_EXCLUSIVE|BTS_PENDING);
for(pLock=pBt->pLock; pLock; pLock=pLock->pNext){
assert( pLock->eLock==READ_LOCK || pLock->pBtree==p );
pLock->eLock = READ_LOCK;
@@ -48106,6 +48957,19 @@ static void btreeClearHasContent(BtShared *pBt){
}
/*
+** Release all of the apPage[] pages for a cursor.
+*/
+static void btreeReleaseAllCursorPages(BtCursor *pCur){
+ int i;
+ for(i=0; i<=pCur->iPage; i++){
+ releasePage(pCur->apPage[i]);
+ pCur->apPage[i] = 0;
+ }
+ pCur->iPage = -1;
+}
+
+
+/*
** Save the current cursor position in the variables BtCursor.nKey
** and BtCursor.pKey. The cursor's state is set to CURSOR_REQUIRESEEK.
**
@@ -48144,12 +49008,7 @@ static int saveCursorPosition(BtCursor *pCur){
assert( !pCur->apPage[0]->intKey || !pCur->pKey );
if( rc==SQLITE_OK ){
- int i;
- for(i=0; i<=pCur->iPage; i++){
- releasePage(pCur->apPage[i]);
- pCur->apPage[i] = 0;
- }
- pCur->iPage = -1;
+ btreeReleaseAllCursorPages(pCur);
pCur->eState = CURSOR_REQUIRESEEK;
}
@@ -48167,11 +49026,15 @@ static int saveAllCursors(BtShared *pBt, Pgno iRoot, BtCursor *pExcept){
assert( sqlite3_mutex_held(pBt->mutex) );
assert( pExcept==0 || pExcept->pBt==pBt );
for(p=pBt->pCursor; p; p=p->pNext){
- if( p!=pExcept && (0==iRoot || p->pgnoRoot==iRoot) &&
- p->eState==CURSOR_VALID ){
- int rc = saveCursorPosition(p);
- if( SQLITE_OK!=rc ){
- return rc;
+ if( p!=pExcept && (0==iRoot || p->pgnoRoot==iRoot) ){
+ if( p->eState==CURSOR_VALID ){
+ int rc = saveCursorPosition(p);
+ if( SQLITE_OK!=rc ){
+ return rc;
+ }
+ }else{
+ testcase( p->iPage>0 );
+ btreeReleaseAllCursorPages(p);
}
}
}
@@ -48203,18 +49066,21 @@ static int btreeMoveto(
int rc; /* Status code */
UnpackedRecord *pIdxKey; /* Unpacked index key */
char aSpace[150]; /* Temp space for pIdxKey - to avoid a malloc */
+ char *pFree = 0;
if( pKey ){
assert( nKey==(i64)(int)nKey );
- pIdxKey = sqlite3VdbeRecordUnpack(pCur->pKeyInfo, (int)nKey, pKey,
- aSpace, sizeof(aSpace));
+ pIdxKey = sqlite3VdbeAllocUnpackedRecord(
+ pCur->pKeyInfo, aSpace, sizeof(aSpace), &pFree
+ );
if( pIdxKey==0 ) return SQLITE_NOMEM;
+ sqlite3VdbeRecordUnpack(pCur->pKeyInfo, (int)nKey, pKey, pIdxKey);
}else{
pIdxKey = 0;
}
rc = sqlite3BtreeMovetoUnpacked(pCur, pIdxKey, nKey, bias, pRes);
- if( pKey ){
- sqlite3VdbeDeleteUnpackedRecord(pIdxKey);
+ if( pFree ){
+ sqlite3DbFree(pCur->pKeyInfo->db, pFree);
}
return rc;
}
@@ -48403,7 +49269,7 @@ static int ptrmapGet(BtShared *pBt, Pgno key, u8 *pEType, Pgno *pPgno){
** This routine works only for pages that do not contain overflow cells.
*/
#define findCell(P,I) \
- ((P)->aData + ((P)->maskPage & get2byte(&(P)->aData[(P)->cellOffset+2*(I)])))
+ ((P)->aData + ((P)->maskPage & get2byte(&(P)->aCellIdx[2*(I)])))
#define findCellv2(D,M,O,I) (D+(M&get2byte(D+(O+2*(I)))))
@@ -48416,12 +49282,10 @@ static u8 *findOverflowCell(MemPage *pPage, int iCell){
assert( sqlite3_mutex_held(pPage->pBt->mutex) );
for(i=pPage->nOverflow-1; i>=0; i--){
int k;
- struct _OvflCell *pOvfl;
- pOvfl = &pPage->aOvfl[i];
- k = pOvfl->idx;
+ k = pPage->aiOvfl[i];
if( k<=iCell ){
if( k==iCell ){
- return pOvfl->pCell;
+ return pPage->apOvfl[i];
}
iCell--;
}
@@ -48808,7 +49672,7 @@ static int freeSpace(MemPage *pPage, int start, int size){
assert( sqlite3_mutex_held(pPage->pBt->mutex) );
assert( size>=0 ); /* Minimum cell size is 4 */
- if( pPage->pBt->secureDelete ){
+ if( pPage->pBt->btsFlags & BTS_SECURE_DELETE ){
/* Overwrite deleted information with zeros when the secure_delete
** option is enabled */
memset(&data[start], 0, size);
@@ -48911,6 +49775,7 @@ static int decodeFlags(MemPage *pPage, int flagByte){
}else{
return SQLITE_CORRUPT_BKPT;
}
+ pPage->max1bytePayload = pBt->max1bytePayload;
return SQLITE_OK;
}
@@ -48953,6 +49818,8 @@ static int btreeInitPage(MemPage *pPage){
pPage->nOverflow = 0;
usableSize = pBt->usableSize;
pPage->cellOffset = cellOffset = hdr + 12 - 4*pPage->leaf;
+ pPage->aDataEnd = &data[usableSize];
+ pPage->aCellIdx = &data[cellOffset];
top = get2byteNotZero(&data[hdr+5]);
pPage->nCell = get2byte(&data[hdr+3]);
if( pPage->nCell>MX_CELL(pBt) ){
@@ -49006,7 +49873,7 @@ static int btreeInitPage(MemPage *pPage){
size = get2byte(&data[pc+2]);
if( (next>0 && next<=pc+size+3) || pc+size>usableSize ){
/* Free blocks must be in ascending order. And the last byte of
- ** the free-block must lie on the database page. */
+ ** the free-block must lie on the database page. */
return SQLITE_CORRUPT_BKPT;
}
nFree = nFree + size;
@@ -49044,7 +49911,7 @@ static void zeroPage(MemPage *pPage, int flags){
assert( sqlite3PagerGetData(pPage->pDbPage) == data );
assert( sqlite3PagerIswriteable(pPage->pDbPage) );
assert( sqlite3_mutex_held(pBt->mutex) );
- if( pBt->secureDelete ){
+ if( pBt->btsFlags & BTS_SECURE_DELETE ){
memset(&data[hdr], 0, pBt->usableSize - hdr);
}
data[hdr] = (char)flags;
@@ -49056,6 +49923,8 @@ static void zeroPage(MemPage *pPage, int flags){
decodeFlags(pPage, flags);
pPage->hdrOffset = hdr;
pPage->cellOffset = first;
+ pPage->aDataEnd = &data[pBt->usableSize];
+ pPage->aCellIdx = &data[first];
pPage->nOverflow = 0;
assert( pBt->pageSize>=512 && pBt->pageSize<=65536 );
pPage->maskPage = (u16)(pBt->pageSize - 1);
@@ -49230,11 +50099,8 @@ static int btreeInvokeBusyHandler(void *pArg){
** If zFilename is ":memory:" then an in-memory database is created
** that is automatically destroyed when it is closed.
**
-** The "flags" parameter is a bitmask that might contain bits
-** BTREE_OMIT_JOURNAL and/or BTREE_NO_READLOCK. The BTREE_NO_READLOCK
-** bit is also set if the SQLITE_NoReadlock flags is set in db->flags.
-** These flags are passed through into sqlite3PagerOpen() and must
-** be the same values as PAGER_OMIT_JOURNAL and PAGER_NO_READLOCK.
+** The "flags" parameter is a bitmask that might contain bits like
+** BTREE_OMIT_JOURNAL and/or BTREE_MEMORY.
**
** If the database is already opened in the same database connection
** and we are in shared cache mode, then the open will fail with an
@@ -49267,7 +50133,8 @@ SQLITE_PRIVATE int sqlite3BtreeOpen(
const int isMemdb = 0;
#else
const int isMemdb = (zFilename && strcmp(zFilename, ":memory:")==0)
- || (isTempDb && sqlite3TempInMemory(db));
+ || (isTempDb && sqlite3TempInMemory(db))
+ || (vfsFlags & SQLITE_OPEN_MEMORY)!=0;
#endif
assert( db!=0 );
@@ -49281,9 +50148,6 @@ SQLITE_PRIVATE int sqlite3BtreeOpen(
/* A BTREE_SINGLE database is always a temporary and/or ephemeral */
assert( (flags & BTREE_SINGLE)==0 || isTempDb );
- if( db->flags & SQLITE_NoReadlock ){
- flags |= BTREE_NO_READLOCK;
- }
if( isMemdb ){
flags |= BTREE_MEMORY;
}
@@ -49306,24 +50170,36 @@ SQLITE_PRIVATE int sqlite3BtreeOpen(
** If this Btree is a candidate for shared cache, try to find an
** existing BtShared object that we can share with
*/
- if( isMemdb==0 && isTempDb==0 ){
+ if( isTempDb==0 && (isMemdb==0 || (vfsFlags&SQLITE_OPEN_URI)!=0) ){
if( vfsFlags & SQLITE_OPEN_SHAREDCACHE ){
int nFullPathname = pVfs->mxPathname+1;
char *zFullPathname = sqlite3Malloc(nFullPathname);
- sqlite3_mutex *mutexShared;
+ MUTEX_LOGIC( sqlite3_mutex *mutexShared; )
p->sharable = 1;
if( !zFullPathname ){
sqlite3_free(p);
return SQLITE_NOMEM;
}
- sqlite3OsFullPathname(pVfs, zFilename, nFullPathname, zFullPathname);
+ if( isMemdb ){
+ memcpy(zFullPathname, zFilename, sqlite3Strlen30(zFilename)+1);
+ }else{
+ rc = sqlite3OsFullPathname(pVfs, zFilename,
+ nFullPathname, zFullPathname);
+ if( rc ){
+ sqlite3_free(zFullPathname);
+ sqlite3_free(p);
+ return rc;
+ }
+ }
+#if SQLITE_THREADSAFE
mutexOpen = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_OPEN);
sqlite3_mutex_enter(mutexOpen);
mutexShared = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER);
sqlite3_mutex_enter(mutexShared);
+#endif
for(pBt=GLOBAL(BtShared*,sqlite3SharedCacheList); pBt; pBt=pBt->pNext){
assert( pBt->nRef>0 );
- if( 0==strcmp(zFullPathname, sqlite3PagerFilename(pBt->pPager))
+ if( 0==strcmp(zFullPathname, sqlite3PagerFilename(pBt->pPager, 0))
&& sqlite3PagerVfs(pBt->pPager)==pVfs ){
int iDb;
for(iDb=db->nDb-1; iDb>=0; iDb--){
@@ -49388,9 +50264,9 @@ SQLITE_PRIVATE int sqlite3BtreeOpen(
pBt->pCursor = 0;
pBt->pPage1 = 0;
- pBt->readOnly = sqlite3PagerIsreadonly(pBt->pPager);
+ if( sqlite3PagerIsreadonly(pBt->pPager) ) pBt->btsFlags |= BTS_READ_ONLY;
#ifdef SQLITE_SECURE_DELETE
- pBt->secureDelete = 1;
+ pBt->btsFlags |= BTS_SECURE_DELETE;
#endif
pBt->pageSize = (zDbHeader[16]<<8) | (zDbHeader[17]<<16);
if( pBt->pageSize<512 || pBt->pageSize>SQLITE_MAX_PAGE_SIZE
@@ -49411,7 +50287,7 @@ SQLITE_PRIVATE int sqlite3BtreeOpen(
nReserve = 0;
}else{
nReserve = zDbHeader[20];
- pBt->pageSizeFixed = 1;
+ pBt->btsFlags |= BTS_PAGESIZE_FIXED;
#ifndef SQLITE_OMIT_AUTOVACUUM
pBt->autoVacuum = (get4byte(&zDbHeader[36 + 4*4])?1:0);
pBt->incrVacuum = (get4byte(&zDbHeader[36 + 7*4])?1:0);
@@ -49426,9 +50302,9 @@ SQLITE_PRIVATE int sqlite3BtreeOpen(
/* Add the new BtShared object to the linked list sharable BtShareds.
*/
if( p->sharable ){
- sqlite3_mutex *mutexShared;
+ MUTEX_LOGIC( sqlite3_mutex *mutexShared; )
pBt->nRef = 1;
- mutexShared = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER);
+ MUTEX_LOGIC( mutexShared = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER);)
if( SQLITE_THREADSAFE && sqlite3GlobalConfig.bCoreMutex ){
pBt->mutex = sqlite3MutexAlloc(SQLITE_MUTEX_FAST);
if( pBt->mutex==0 ){
@@ -49510,12 +50386,12 @@ btree_open_out:
*/
static int removeFromSharingList(BtShared *pBt){
#ifndef SQLITE_OMIT_SHARED_CACHE
- sqlite3_mutex *pMaster;
+ MUTEX_LOGIC( sqlite3_mutex *pMaster; )
BtShared *pList;
int removed = 0;
assert( sqlite3_mutex_notheld(pBt->mutex) );
- pMaster = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER);
+ MUTEX_LOGIC( pMaster = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER); )
sqlite3_mutex_enter(pMaster);
pBt->nRef--;
if( pBt->nRef<=0 ){
@@ -49583,7 +50459,7 @@ SQLITE_PRIVATE int sqlite3BtreeClose(Btree *p){
** The call to sqlite3BtreeRollback() drops any table-locks held by
** this handle.
*/
- sqlite3BtreeRollback(p);
+ sqlite3BtreeRollback(p, SQLITE_OK);
sqlite3BtreeLeave(p);
/* If there are still other outstanding references to the shared-btree
@@ -49699,7 +50575,7 @@ SQLITE_PRIVATE int sqlite3BtreeSyncDisabled(Btree *p){
** If parameter nReserve is less than zero, then the number of reserved
** bytes per page is left unchanged.
**
-** If the iFix!=0 then the pageSizeFixed flag is set so that the page size
+** If the iFix!=0 then the BTS_PAGESIZE_FIXED flag is set so that the page size
** and autovacuum mode can no longer be changed.
*/
SQLITE_PRIVATE int sqlite3BtreeSetPageSize(Btree *p, int pageSize, int nReserve, int iFix){
@@ -49707,7 +50583,7 @@ SQLITE_PRIVATE int sqlite3BtreeSetPageSize(Btree *p, int pageSize, int nReserve,
BtShared *pBt = p->pBt;
assert( nReserve>=-1 && nReserve<=255 );
sqlite3BtreeEnter(p);
- if( pBt->pageSizeFixed ){
+ if( pBt->btsFlags & BTS_PAGESIZE_FIXED ){
sqlite3BtreeLeave(p);
return SQLITE_READONLY;
}
@@ -49724,7 +50600,7 @@ SQLITE_PRIVATE int sqlite3BtreeSetPageSize(Btree *p, int pageSize, int nReserve,
}
rc = sqlite3PagerSetPagesize(pBt->pPager, &pBt->pageSize, nReserve);
pBt->usableSize = pBt->pageSize - (u16)nReserve;
- if( iFix ) pBt->pageSizeFixed = 1;
+ if( iFix ) pBt->btsFlags |= BTS_PAGESIZE_FIXED;
sqlite3BtreeLeave(p);
return rc;
}
@@ -49736,6 +50612,24 @@ SQLITE_PRIVATE int sqlite3BtreeGetPageSize(Btree *p){
return p->pBt->pageSize;
}
+#if defined(SQLITE_HAS_CODEC) || defined(SQLITE_DEBUG)
+/*
+** This function is similar to sqlite3BtreeGetReserve(), except that it
+** may only be called if it is guaranteed that the b-tree mutex is already
+** held.
+**
+** This is useful in one special case in the backup API code where it is
+** known that the shared b-tree mutex is held, but the mutex on the
+** database handle that owns *p is not. In this case if sqlite3BtreeEnter()
+** were to be called, it might collide with some other operation on the
+** database handle that owns *p, causing undefined behavior.
+*/
+SQLITE_PRIVATE int sqlite3BtreeGetReserveNoMutex(Btree *p){
+ assert( sqlite3_mutex_held(p->pBt->mutex) );
+ return p->pBt->pageSize - p->pBt->usableSize;
+}
+#endif /* SQLITE_HAS_CODEC || SQLITE_DEBUG */
+
#if !defined(SQLITE_OMIT_PAGER_PRAGMAS) || !defined(SQLITE_OMIT_VACUUM)
/*
** Return the number of bytes of space at the end of every page that
@@ -49764,8 +50658,8 @@ SQLITE_PRIVATE int sqlite3BtreeMaxPageCount(Btree *p, int mxPage){
}
/*
-** Set the secureDelete flag if newFlag is 0 or 1. If newFlag is -1,
-** then make no changes. Always return the value of the secureDelete
+** Set the BTS_SECURE_DELETE flag if newFlag is 0 or 1. If newFlag is -1,
+** then make no changes. Always return the value of the BTS_SECURE_DELETE
** setting after the change.
*/
SQLITE_PRIVATE int sqlite3BtreeSecureDelete(Btree *p, int newFlag){
@@ -49773,9 +50667,10 @@ SQLITE_PRIVATE int sqlite3BtreeSecureDelete(Btree *p, int newFlag){
if( p==0 ) return 0;
sqlite3BtreeEnter(p);
if( newFlag>=0 ){
- p->pBt->secureDelete = (newFlag!=0) ? 1 : 0;
+ p->pBt->btsFlags &= ~BTS_SECURE_DELETE;
+ if( newFlag ) p->pBt->btsFlags |= BTS_SECURE_DELETE;
}
- b = p->pBt->secureDelete;
+ b = (p->pBt->btsFlags & BTS_SECURE_DELETE)!=0;
sqlite3BtreeLeave(p);
return b;
}
@@ -49796,7 +50691,7 @@ SQLITE_PRIVATE int sqlite3BtreeSetAutoVacuum(Btree *p, int autoVacuum){
u8 av = (u8)autoVacuum;
sqlite3BtreeEnter(p);
- if( pBt->pageSizeFixed && (av ?1:0)!=pBt->autoVacuum ){
+ if( (pBt->btsFlags & BTS_PAGESIZE_FIXED)!=0 && (av ?1:0)!=pBt->autoVacuum ){
rc = SQLITE_READONLY;
}else{
pBt->autoVacuum = av ?1:0;
@@ -49870,14 +50765,14 @@ static int lockBtree(BtShared *pBt){
#ifdef SQLITE_OMIT_WAL
if( page1[18]>1 ){
- pBt->readOnly = 1;
+ pBt->btsFlags |= BTS_READ_ONLY;
}
if( page1[19]>1 ){
goto page1_init_failed;
}
#else
if( page1[18]>2 ){
- pBt->readOnly = 1;
+ pBt->btsFlags |= BTS_READ_ONLY;
}
if( page1[19]>2 ){
goto page1_init_failed;
@@ -49891,7 +50786,7 @@ static int lockBtree(BtShared *pBt){
** may not be the latest version - there may be a newer one in the log
** file.
*/
- if( page1[19]==2 && pBt->doNotUseWAL==0 ){
+ if( page1[19]==2 && (pBt->btsFlags & BTS_NO_WAL)==0 ){
int isOpen = 0;
rc = sqlite3PagerOpenWal(pBt->pPager, &isOpen);
if( rc!=SQLITE_OK ){
@@ -49968,6 +50863,11 @@ static int lockBtree(BtShared *pBt){
pBt->minLocal = (u16)((pBt->usableSize-12)*32/255 - 23);
pBt->maxLeaf = (u16)(pBt->usableSize - 35);
pBt->minLeaf = (u16)((pBt->usableSize-12)*32/255 - 23);
+ if( pBt->maxLocal>127 ){
+ pBt->max1bytePayload = 127;
+ }else{
+ pBt->max1bytePayload = (u8)pBt->maxLocal;
+ }
assert( pBt->maxLeaf + 23 <= MX_CELL_SIZE(pBt) );
pBt->pPage1 = pPage1;
pBt->nPage = nPage;
@@ -50031,7 +50931,7 @@ static int newDatabase(BtShared *pBt){
data[23] = 32;
memset(&data[24], 0, 100-24);
zeroPage(pP1, PTF_INTKEY|PTF_LEAF|PTF_LEAFDATA );
- pBt->pageSizeFixed = 1;
+ pBt->btsFlags |= BTS_PAGESIZE_FIXED;
#ifndef SQLITE_OMIT_AUTOVACUUM
assert( pBt->autoVacuum==1 || pBt->autoVacuum==0 );
assert( pBt->incrVacuum==1 || pBt->incrVacuum==0 );
@@ -50044,6 +50944,20 @@ static int newDatabase(BtShared *pBt){
}
/*
+** Initialize the first page of the database file (creating a database
+** consisting of a single page and no schema objects). Return SQLITE_OK
+** if successful, or an SQLite error code otherwise.
+*/
+SQLITE_PRIVATE int sqlite3BtreeNewDb(Btree *p){
+ int rc;
+ sqlite3BtreeEnter(p);
+ p->pBt->nPage = 0;
+ rc = newDatabase(p->pBt);
+ sqlite3BtreeLeave(p);
+ return rc;
+}
+
+/*
** Attempt to start a new transaction. A write-transaction
** is started if the second argument is nonzero, otherwise a read-
** transaction. If the second argument is 2 or more and exclusive
@@ -50093,9 +51007,10 @@ SQLITE_PRIVATE int sqlite3BtreeBeginTrans(Btree *p, int wrflag){
if( p->inTrans==TRANS_WRITE || (p->inTrans==TRANS_READ && !wrflag) ){
goto trans_begun;
}
+ assert( IfNotOmitAV(pBt->bDoTruncate)==0 );
/* Write transactions are not possible on a read-only database */
- if( pBt->readOnly && wrflag ){
+ if( (pBt->btsFlags & BTS_READ_ONLY)!=0 && wrflag ){
rc = SQLITE_READONLY;
goto trans_begun;
}
@@ -50105,7 +51020,9 @@ SQLITE_PRIVATE int sqlite3BtreeBeginTrans(Btree *p, int wrflag){
** on this shared-btree structure and a second write transaction is
** requested, return SQLITE_LOCKED.
*/
- if( (wrflag && pBt->inTransaction==TRANS_WRITE) || pBt->isPending ){
+ if( (wrflag && pBt->inTransaction==TRANS_WRITE)
+ || (pBt->btsFlags & BTS_PENDING)!=0
+ ){
pBlock = pBt->pWriter->db;
}else if( wrflag>1 ){
BtLock *pIter;
@@ -50129,7 +51046,8 @@ SQLITE_PRIVATE int sqlite3BtreeBeginTrans(Btree *p, int wrflag){
rc = querySharedCacheTableLock(p, MASTER_ROOT, READ_LOCK);
if( SQLITE_OK!=rc ) goto trans_begun;
- pBt->initiallyEmpty = (u8)(pBt->nPage==0);
+ pBt->btsFlags &= ~BTS_INITIALLY_EMPTY;
+ if( pBt->nPage==0 ) pBt->btsFlags |= BTS_INITIALLY_EMPTY;
do {
/* Call lockBtree() until either pBt->pPage1 is populated or
** lockBtree() returns something other than SQLITE_OK. lockBtree()
@@ -50141,7 +51059,7 @@ SQLITE_PRIVATE int sqlite3BtreeBeginTrans(Btree *p, int wrflag){
while( pBt->pPage1==0 && SQLITE_OK==(rc = lockBtree(pBt)) );
if( rc==SQLITE_OK && wrflag ){
- if( pBt->readOnly ){
+ if( (pBt->btsFlags & BTS_READ_ONLY)!=0 ){
rc = SQLITE_READONLY;
}else{
rc = sqlite3PagerBegin(pBt->pPager,wrflag>1,sqlite3TempInMemory(p->db));
@@ -50162,7 +51080,7 @@ SQLITE_PRIVATE int sqlite3BtreeBeginTrans(Btree *p, int wrflag){
pBt->nTransaction++;
#ifndef SQLITE_OMIT_SHARED_CACHE
if( p->sharable ){
- assert( p->lock.pBtree==p && p->lock.iTable==1 );
+ assert( p->lock.pBtree==p && p->lock.iTable==1 );
p->lock.eLock = READ_LOCK;
p->lock.pNext = pBt->pLock;
pBt->pLock = &p->lock;
@@ -50178,7 +51096,8 @@ SQLITE_PRIVATE int sqlite3BtreeBeginTrans(Btree *p, int wrflag){
#ifndef SQLITE_OMIT_SHARED_CACHE
assert( !pBt->pWriter );
pBt->pWriter = p;
- pBt->isExclusive = (u8)(wrflag>1);
+ pBt->btsFlags &= ~BTS_EXCLUSIVE;
+ if( wrflag>1 ) pBt->btsFlags |= BTS_EXCLUSIVE;
#endif
/* If the db-size header field is incorrect (as it may be if an old
@@ -50290,11 +51209,12 @@ static int modifyPagePointer(MemPage *pPage, Pgno iFrom, Pgno iTo, u8 eType){
if( eType==PTRMAP_OVERFLOW1 ){
CellInfo info;
btreeParseCellPtr(pPage, pCell, &info);
- if( info.iOverflow ){
- if( iFrom==get4byte(&pCell[info.iOverflow]) ){
- put4byte(&pCell[info.iOverflow], iTo);
- break;
- }
+ if( info.iOverflow
+ && pCell+info.iOverflow+3<=pPage->aData+pPage->maskPage
+ && iFrom==get4byte(&pCell[info.iOverflow])
+ ){
+ put4byte(&pCell[info.iOverflow], iTo);
+ break;
}
}else{
if( get4byte(pCell)==iFrom ){
@@ -50404,24 +51324,23 @@ static int relocatePage(
static int allocateBtreePage(BtShared *, MemPage **, Pgno *, Pgno, u8);
/*
-** Perform a single step of an incremental-vacuum. If successful,
-** return SQLITE_OK. If there is no work to do (and therefore no
-** point in calling this function again), return SQLITE_DONE.
+** Perform a single step of an incremental-vacuum. If successful, return
+** SQLITE_OK. If there is no work to do (and therefore no point in
+** calling this function again), return SQLITE_DONE. Or, if an error
+** occurs, return some other error code.
+**
+** More specificly, this function attempts to re-organize the database so
+** that the last page of the file currently in use is no longer in use.
**
-** More specificly, this function attempts to re-organize the
-** database so that the last page of the file currently in use
-** is no longer in use.
+** Parameter nFin is the number of pages that this database would contain
+** were this function called until it returns SQLITE_DONE.
**
-** If the nFin parameter is non-zero, this function assumes
-** that the caller will keep calling incrVacuumStep() until
-** it returns SQLITE_DONE or an error, and that nFin is the
-** number of pages the database file will contain after this
-** process is complete. If nFin is zero, it is assumed that
-** incrVacuumStep() will be called a finite amount of times
-** which may or may not empty the freelist. A full autovacuum
-** has nFin>0. A "PRAGMA incremental_vacuum" has nFin==0.
+** If the bCommit parameter is non-zero, this function assumes that the
+** caller will keep calling incrVacuumStep() until it returns SQLITE_DONE
+** or an error. bCommit is passed true for an auto-vacuum-on-commmit
+** operation, or false for an incremental vacuum.
*/
-static int incrVacuumStep(BtShared *pBt, Pgno nFin, Pgno iLastPg){
+static int incrVacuumStep(BtShared *pBt, Pgno nFin, Pgno iLastPg, int bCommit){
Pgno nFreeList; /* Number of pages still on the free-list */
int rc;
@@ -50446,15 +51365,15 @@ static int incrVacuumStep(BtShared *pBt, Pgno nFin, Pgno iLastPg){
}
if( eType==PTRMAP_FREEPAGE ){
- if( nFin==0 ){
+ if( bCommit==0 ){
/* Remove the page from the files free-list. This is not required
- ** if nFin is non-zero. In that case, the free-list will be
+ ** if bCommit is non-zero. In that case, the free-list will be
** truncated to zero after this function returns, so it doesn't
** matter if it still contains some garbage entries.
*/
Pgno iFreePg;
MemPage *pFreePg;
- rc = allocateBtreePage(pBt, &pFreePg, &iFreePg, iLastPg, 1);
+ rc = allocateBtreePage(pBt, &pFreePg, &iFreePg, iLastPg, BTALLOC_EXACT);
if( rc!=SQLITE_OK ){
return rc;
}
@@ -50464,34 +51383,37 @@ static int incrVacuumStep(BtShared *pBt, Pgno nFin, Pgno iLastPg){
} else {
Pgno iFreePg; /* Index of free page to move pLastPg to */
MemPage *pLastPg;
+ u8 eMode = BTALLOC_ANY; /* Mode parameter for allocateBtreePage() */
+ Pgno iNear = 0; /* nearby parameter for allocateBtreePage() */
rc = btreeGetPage(pBt, iLastPg, &pLastPg, 0);
if( rc!=SQLITE_OK ){
return rc;
}
- /* If nFin is zero, this loop runs exactly once and page pLastPg
+ /* If bCommit is zero, this loop runs exactly once and page pLastPg
** is swapped with the first free page pulled off the free list.
**
- ** On the other hand, if nFin is greater than zero, then keep
+ ** On the other hand, if bCommit is greater than zero, then keep
** looping until a free-page located within the first nFin pages
** of the file is found.
*/
+ if( bCommit==0 ){
+ eMode = BTALLOC_LE;
+ iNear = nFin;
+ }
do {
MemPage *pFreePg;
- rc = allocateBtreePage(pBt, &pFreePg, &iFreePg, 0, 0);
+ rc = allocateBtreePage(pBt, &pFreePg, &iFreePg, iNear, eMode);
if( rc!=SQLITE_OK ){
releasePage(pLastPg);
return rc;
}
releasePage(pFreePg);
- }while( nFin!=0 && iFreePg>nFin );
+ }while( bCommit && iFreePg>nFin );
assert( iFreePg<iLastPg );
- rc = sqlite3PagerWrite(pLastPg->pDbPage);
- if( rc==SQLITE_OK ){
- rc = relocatePage(pBt, pLastPg, eType, iPtrPage, iFreePg, nFin!=0);
- }
+ rc = relocatePage(pBt, pLastPg, eType, iPtrPage, iFreePg, bCommit);
releasePage(pLastPg);
if( rc!=SQLITE_OK ){
return rc;
@@ -50499,30 +51421,40 @@ static int incrVacuumStep(BtShared *pBt, Pgno nFin, Pgno iLastPg){
}
}
- if( nFin==0 ){
- iLastPg--;
- while( iLastPg==PENDING_BYTE_PAGE(pBt)||PTRMAP_ISPAGE(pBt, iLastPg) ){
- if( PTRMAP_ISPAGE(pBt, iLastPg) ){
- MemPage *pPg;
- rc = btreeGetPage(pBt, iLastPg, &pPg, 0);
- if( rc!=SQLITE_OK ){
- return rc;
- }
- rc = sqlite3PagerWrite(pPg->pDbPage);
- releasePage(pPg);
- if( rc!=SQLITE_OK ){
- return rc;
- }
- }
+ if( bCommit==0 ){
+ do {
iLastPg--;
- }
- sqlite3PagerTruncateImage(pBt->pPager, iLastPg);
+ }while( iLastPg==PENDING_BYTE_PAGE(pBt) || PTRMAP_ISPAGE(pBt, iLastPg) );
+ pBt->bDoTruncate = 1;
pBt->nPage = iLastPg;
}
return SQLITE_OK;
}
/*
+** The database opened by the first argument is an auto-vacuum database
+** nOrig pages in size containing nFree free pages. Return the expected
+** size of the database in pages following an auto-vacuum operation.
+*/
+static Pgno finalDbSize(BtShared *pBt, Pgno nOrig, Pgno nFree){
+ int nEntry; /* Number of entries on one ptrmap page */
+ Pgno nPtrmap; /* Number of PtrMap pages to be freed */
+ Pgno nFin; /* Return value */
+
+ nEntry = pBt->usableSize/5;
+ nPtrmap = (nFree-nOrig+PTRMAP_PAGENO(pBt, nOrig)+nEntry)/nEntry;
+ nFin = nOrig - nFree - nPtrmap;
+ if( nOrig>PENDING_BYTE_PAGE(pBt) && nFin<PENDING_BYTE_PAGE(pBt) ){
+ nFin--;
+ }
+ while( PTRMAP_ISPAGE(pBt, nFin) || nFin==PENDING_BYTE_PAGE(pBt) ){
+ nFin--;
+ }
+
+ return nFin;
+}
+
+/*
** A write-transaction must be opened before calling this function.
** It performs a single unit of work towards an incremental vacuum.
**
@@ -50539,11 +51471,21 @@ SQLITE_PRIVATE int sqlite3BtreeIncrVacuum(Btree *p){
if( !pBt->autoVacuum ){
rc = SQLITE_DONE;
}else{
- invalidateAllOverflowCache(pBt);
- rc = incrVacuumStep(pBt, 0, btreePagecount(pBt));
- if( rc==SQLITE_OK ){
- rc = sqlite3PagerWrite(pBt->pPage1->pDbPage);
- put4byte(&pBt->pPage1->aData[28], pBt->nPage);
+ Pgno nOrig = btreePagecount(pBt);
+ Pgno nFree = get4byte(&pBt->pPage1->aData[36]);
+ Pgno nFin = finalDbSize(pBt, nOrig, nFree);
+
+ if( nOrig<nFin ){
+ rc = SQLITE_CORRUPT_BKPT;
+ }else if( nFree>0 ){
+ invalidateAllOverflowCache(pBt);
+ rc = incrVacuumStep(pBt, nFin, nOrig, 0);
+ if( rc==SQLITE_OK ){
+ rc = sqlite3PagerWrite(pBt->pPage1->pDbPage);
+ put4byte(&pBt->pPage1->aData[28], pBt->nPage);
+ }
+ }else{
+ rc = SQLITE_DONE;
}
}
sqlite3BtreeLeave(p);
@@ -50570,9 +51512,7 @@ static int autoVacuumCommit(BtShared *pBt){
if( !pBt->incrVacuum ){
Pgno nFin; /* Number of pages in database after autovacuuming */
Pgno nFree; /* Number of pages on the freelist initially */
- Pgno nPtrmap; /* Number of PtrMap pages to be freed */
Pgno iFree; /* The next page to be freed */
- int nEntry; /* Number of entries on one ptrmap page */
Pgno nOrig; /* Database size before freeing */
nOrig = btreePagecount(pBt);
@@ -50585,26 +51525,18 @@ static int autoVacuumCommit(BtShared *pBt){
}
nFree = get4byte(&pBt->pPage1->aData[36]);
- nEntry = pBt->usableSize/5;
- nPtrmap = (nFree-nOrig+PTRMAP_PAGENO(pBt, nOrig)+nEntry)/nEntry;
- nFin = nOrig - nFree - nPtrmap;
- if( nOrig>PENDING_BYTE_PAGE(pBt) && nFin<PENDING_BYTE_PAGE(pBt) ){
- nFin--;
- }
- while( PTRMAP_ISPAGE(pBt, nFin) || nFin==PENDING_BYTE_PAGE(pBt) ){
- nFin--;
- }
+ nFin = finalDbSize(pBt, nOrig, nFree);
if( nFin>nOrig ) return SQLITE_CORRUPT_BKPT;
for(iFree=nOrig; iFree>nFin && rc==SQLITE_OK; iFree--){
- rc = incrVacuumStep(pBt, nFin, iFree);
+ rc = incrVacuumStep(pBt, nFin, iFree, 1);
}
if( (rc==SQLITE_DONE || rc==SQLITE_OK) && nFree>0 ){
rc = sqlite3PagerWrite(pBt->pPage1->pDbPage);
put4byte(&pBt->pPage1->aData[32], 0);
put4byte(&pBt->pPage1->aData[36], 0);
put4byte(&pBt->pPage1->aData[28], nFin);
- sqlite3PagerTruncateImage(pBt->pPager, nFin);
+ pBt->bDoTruncate = 1;
pBt->nPage = nFin;
}
if( rc!=SQLITE_OK ){
@@ -50659,6 +51591,9 @@ SQLITE_PRIVATE int sqlite3BtreeCommitPhaseOne(Btree *p, const char *zMaster){
return rc;
}
}
+ if( pBt->bDoTruncate ){
+ sqlite3PagerTruncateImage(pBt->pPager, pBt->nPage);
+ }
#endif
rc = sqlite3PagerCommitPhaseOne(pBt->pPager, zMaster, 0);
sqlite3BtreeLeave(p);
@@ -50674,6 +51609,9 @@ static void btreeEndTransaction(Btree *p){
BtShared *pBt = p->pBt;
assert( sqlite3BtreeHoldsMutex(p) );
+#ifndef SQLITE_OMIT_AUTOVACUUM
+ pBt->bDoTruncate = 0;
+#endif
btreeClearHasContent(pBt);
if( p->inTrans>TRANS_NONE && p->db->activeVdbeCnt>1 ){
/* If there are other active statements that belong to this database
@@ -50810,6 +51748,7 @@ static int countWriteCursors(BtShared *pBt){
*/
SQLITE_PRIVATE void sqlite3BtreeTripAllCursors(Btree *pBtree, int errCode){
BtCursor *p;
+ if( pBtree==0 ) return;
sqlite3BtreeEnter(pBtree);
for(p=pBtree->pBt->pCursor; p; p=p->pNext){
int i;
@@ -50833,25 +51772,20 @@ SQLITE_PRIVATE void sqlite3BtreeTripAllCursors(Btree *pBtree, int errCode){
** This will release the write lock on the database file. If there
** are no active cursors, it also releases the read lock.
*/
-SQLITE_PRIVATE int sqlite3BtreeRollback(Btree *p){
+SQLITE_PRIVATE int sqlite3BtreeRollback(Btree *p, int tripCode){
int rc;
BtShared *pBt = p->pBt;
MemPage *pPage1;
sqlite3BtreeEnter(p);
- rc = saveAllCursors(pBt, 0, 0);
-#ifndef SQLITE_OMIT_SHARED_CACHE
- if( rc!=SQLITE_OK ){
- /* This is a horrible situation. An IO or malloc() error occurred whilst
- ** trying to save cursor positions. If this is an automatic rollback (as
- ** the result of a constraint, malloc() failure or IO error) then
- ** the cache may be internally inconsistent (not contain valid trees) so
- ** we cannot simply return the error to the caller. Instead, abort
- ** all queries that may be using any of the cursors that failed to save.
- */
- sqlite3BtreeTripAllCursors(p, rc);
+ if( tripCode==SQLITE_OK ){
+ rc = tripCode = saveAllCursors(pBt, 0, 0);
+ }else{
+ rc = SQLITE_OK;
+ }
+ if( tripCode ){
+ sqlite3BtreeTripAllCursors(p, tripCode);
}
-#endif
btreeIntegrity(p);
if( p->inTrans==TRANS_WRITE ){
@@ -50906,7 +51840,7 @@ SQLITE_PRIVATE int sqlite3BtreeBeginStmt(Btree *p, int iStatement){
BtShared *pBt = p->pBt;
sqlite3BtreeEnter(p);
assert( p->inTrans==TRANS_WRITE );
- assert( pBt->readOnly==0 );
+ assert( (pBt->btsFlags & BTS_READ_ONLY)==0 );
assert( iStatement>0 );
assert( iStatement>p->db->nSavepoint );
assert( pBt->inTransaction==TRANS_WRITE );
@@ -50941,7 +51875,9 @@ SQLITE_PRIVATE int sqlite3BtreeSavepoint(Btree *p, int op, int iSavepoint){
sqlite3BtreeEnter(p);
rc = sqlite3PagerSavepoint(pBt->pPager, op, iSavepoint);
if( rc==SQLITE_OK ){
- if( iSavepoint<0 && pBt->initiallyEmpty ) pBt->nPage = 0;
+ if( iSavepoint<0 && (pBt->btsFlags & BTS_INITIALLY_EMPTY)!=0 ){
+ pBt->nPage = 0;
+ }
rc = newDatabase(pBt);
pBt->nPage = get4byte(28 + pBt->pPage1->aData);
@@ -51011,11 +51947,12 @@ static int btreeCursor(
assert( wrFlag==0 || p->inTrans==TRANS_WRITE );
assert( pBt->pPage1 && pBt->pPage1->aData );
- if( NEVER(wrFlag && pBt->readOnly) ){
+ if( NEVER(wrFlag && (pBt->btsFlags & BTS_READ_ONLY)!=0) ){
return SQLITE_READONLY;
}
if( iTable==1 && btreePagecount(pBt)==0 ){
- return SQLITE_EMPTY;
+ assert( wrFlag==0 );
+ iTable = 0;
}
/* Now that no other errors can occur, finish filling in the BtCursor
@@ -51480,21 +52417,55 @@ static int accessPayload(
/* Need to read this page properly. It contains some of the
** range of data that is being read (eOp==0) or written (eOp!=0).
*/
- DbPage *pDbPage;
+#ifdef SQLITE_DIRECT_OVERFLOW_READ
+ sqlite3_file *fd;
+#endif
int a = amt;
- rc = sqlite3PagerGet(pBt->pPager, nextPage, &pDbPage);
- if( rc==SQLITE_OK ){
- aPayload = sqlite3PagerGetData(pDbPage);
- nextPage = get4byte(aPayload);
- if( a + offset > ovflSize ){
- a = ovflSize - offset;
+ if( a + offset > ovflSize ){
+ a = ovflSize - offset;
+ }
+
+#ifdef SQLITE_DIRECT_OVERFLOW_READ
+ /* If all the following are true:
+ **
+ ** 1) this is a read operation, and
+ ** 2) data is required from the start of this overflow page, and
+ ** 3) the database is file-backed, and
+ ** 4) there is no open write-transaction, and
+ ** 5) the database is not a WAL database,
+ **
+ ** then data can be read directly from the database file into the
+ ** output buffer, bypassing the page-cache altogether. This speeds
+ ** up loading large records that span many overflow pages.
+ */
+ if( eOp==0 /* (1) */
+ && offset==0 /* (2) */
+ && pBt->inTransaction==TRANS_READ /* (4) */
+ && (fd = sqlite3PagerFile(pBt->pPager))->pMethods /* (3) */
+ && pBt->pPage1->aData[19]==0x01 /* (5) */
+ ){
+ u8 aSave[4];
+ u8 *aWrite = &pBuf[-4];
+ memcpy(aSave, aWrite, 4);
+ rc = sqlite3OsRead(fd, aWrite, a+4, (i64)pBt->pageSize*(nextPage-1));
+ nextPage = get4byte(aWrite);
+ memcpy(aWrite, aSave, 4);
+ }else
+#endif
+
+ {
+ DbPage *pDbPage;
+ rc = sqlite3PagerGet(pBt->pPager, nextPage, &pDbPage);
+ if( rc==SQLITE_OK ){
+ aPayload = sqlite3PagerGetData(pDbPage);
+ nextPage = get4byte(aPayload);
+ rc = copyPayload(&aPayload[offset+4], pBuf, a, eOp, pDbPage);
+ sqlite3PagerUnref(pDbPage);
+ offset = 0;
}
- rc = copyPayload(&aPayload[offset+4], pBuf, a, eOp, pDbPage);
- sqlite3PagerUnref(pDbPage);
- offset = 0;
- amt -= a;
- pBuf += a;
}
+ amt -= a;
+ pBuf += a;
}
}
}
@@ -51680,7 +52651,7 @@ static int moveToChild(BtCursor *pCur, u32 newPgno){
return SQLITE_OK;
}
-#ifndef NDEBUG
+#if 0
/*
** Page pParent is an internal (non-leaf) tree page. This function
** asserts that page number iChild is the left-child if the iIdx'th
@@ -51713,11 +52684,21 @@ static void moveToParent(BtCursor *pCur){
assert( pCur->eState==CURSOR_VALID );
assert( pCur->iPage>0 );
assert( pCur->apPage[pCur->iPage] );
+
+ /* UPDATE: It is actually possible for the condition tested by the assert
+ ** below to be untrue if the database file is corrupt. This can occur if
+ ** one cursor has modified page pParent while a reference to it is held
+ ** by a second cursor. Which can only happen if a single page is linked
+ ** into more than one b-tree structure in a corrupt database. */
+#if 0
assertParentIndex(
pCur->apPage[pCur->iPage-1],
pCur->aiIdx[pCur->iPage-1],
pCur->apPage[pCur->iPage]->pgno
);
+#endif
+ testcase( pCur->aiIdx[pCur->iPage-1] > pCur->apPage[pCur->iPage-1]->nCell );
+
releasePage(pCur->apPage[pCur->iPage]);
pCur->iPage--;
pCur->info.nSize = 0;
@@ -51769,6 +52750,9 @@ static int moveToRoot(BtCursor *pCur){
releasePage(pCur->apPage[i]);
}
pCur->iPage = 0;
+ }else if( pCur->pgnoRoot==0 ){
+ pCur->eState = CURSOR_INVALID;
+ return SQLITE_OK;
}else{
rc = getAndInitPage(pBt, pCur->pgnoRoot, &pCur->apPage[0]);
if( rc!=SQLITE_OK ){
@@ -51878,7 +52862,7 @@ SQLITE_PRIVATE int sqlite3BtreeFirst(BtCursor *pCur, int *pRes){
rc = moveToRoot(pCur);
if( rc==SQLITE_OK ){
if( pCur->eState==CURSOR_INVALID ){
- assert( pCur->apPage[pCur->iPage]->nCell==0 );
+ assert( pCur->pgnoRoot==0 || pCur->apPage[pCur->iPage]->nCell==0 );
*pRes = 1;
}else{
assert( pCur->apPage[pCur->iPage]->nCell>0 );
@@ -51917,7 +52901,7 @@ SQLITE_PRIVATE int sqlite3BtreeLast(BtCursor *pCur, int *pRes){
rc = moveToRoot(pCur);
if( rc==SQLITE_OK ){
if( CURSOR_INVALID==pCur->eState ){
- assert( pCur->apPage[pCur->iPage]->nCell==0 );
+ assert( pCur->pgnoRoot==0 || pCur->apPage[pCur->iPage]->nCell==0 );
*pRes = 1;
}else{
assert( pCur->eState==CURSOR_VALID );
@@ -51990,12 +52974,12 @@ SQLITE_PRIVATE int sqlite3BtreeMovetoUnpacked(
if( rc ){
return rc;
}
- assert( pCur->apPage[pCur->iPage] );
- assert( pCur->apPage[pCur->iPage]->isInit );
- assert( pCur->apPage[pCur->iPage]->nCell>0 || pCur->eState==CURSOR_INVALID );
+ assert( pCur->pgnoRoot==0 || pCur->apPage[pCur->iPage] );
+ assert( pCur->pgnoRoot==0 || pCur->apPage[pCur->iPage]->isInit );
+ assert( pCur->eState==CURSOR_INVALID || pCur->apPage[pCur->iPage]->nCell>0 );
if( pCur->eState==CURSOR_INVALID ){
*pRes = -1;
- assert( pCur->apPage[pCur->iPage]->nCell==0 );
+ assert( pCur->pgnoRoot==0 || pCur->apPage[pCur->iPage]->nCell==0 );
return SQLITE_OK;
}
assert( pCur->apPage[0]->intKey || pIdxKey );
@@ -52053,16 +53037,21 @@ SQLITE_PRIVATE int sqlite3BtreeMovetoUnpacked(
** 2 bytes of the cell.
*/
int nCell = pCell[0];
- if( !(nCell & 0x80) && nCell<=pPage->maxLocal ){
+ if( nCell<=pPage->max1bytePayload
+ /* && (pCell+nCell)<pPage->aDataEnd */
+ ){
/* This branch runs if the record-size field of the cell is a
** single byte varint and the record fits entirely on the main
** b-tree page. */
+ testcase( pCell+nCell+1==pPage->aDataEnd );
c = sqlite3VdbeRecordCompare(nCell, (void*)&pCell[1], pIdxKey);
}else if( !(pCell[1] & 0x80)
&& (nCell = ((nCell&0x7f)<<7) + pCell[1])<=pPage->maxLocal
+ /* && (pCell+nCell+2)<=pPage->aDataEnd */
){
/* The record-size field is a 2 byte varint and the record
** fits entirely on the main b-tree page. */
+ testcase( pCell+nCell+2==pPage->aDataEnd );
c = sqlite3VdbeRecordCompare(nCell, (void*)&pCell[2], pIdxKey);
}else{
/* The record flows over onto one or more overflow pages. In
@@ -52090,7 +53079,6 @@ SQLITE_PRIVATE int sqlite3BtreeMovetoUnpacked(
if( c==0 ){
if( pPage->intKey && !pPage->leaf ){
lwr = idx;
- upr = lwr - 1;
break;
}else{
*pRes = 0;
@@ -52108,7 +53096,7 @@ SQLITE_PRIVATE int sqlite3BtreeMovetoUnpacked(
}
pCur->aiIdx[pCur->iPage] = (u16)(idx = (lwr+upr)/2);
}
- assert( lwr==upr+1 );
+ assert( lwr==upr+1 || (pPage->intKey && !pPage->leaf) );
assert( pPage->isInit );
if( pPage->leaf ){
chldPg = 0;
@@ -52180,7 +53168,13 @@ SQLITE_PRIVATE int sqlite3BtreeNext(BtCursor *pCur, int *pRes){
pPage = pCur->apPage[pCur->iPage];
idx = ++pCur->aiIdx[pCur->iPage];
assert( pPage->isInit );
- assert( idx<=pPage->nCell );
+
+ /* If the database file is corrupt, it is possible for the value of idx
+ ** to be invalid here. This can only occur if a second cursor modifies
+ ** the page while cursor pCur is holding a reference to it. Which can
+ ** only happen if the database is corrupt in such a way as to link the
+ ** page into more than one b-tree structure. */
+ testcase( idx>pPage->nCell );
pCur->info.nSize = 0;
pCur->validNKey = 0;
@@ -52290,21 +53284,23 @@ SQLITE_PRIVATE int sqlite3BtreePrevious(BtCursor *pCur, int *pRes){
** an error. *ppPage and *pPgno are undefined in the event of an error.
** Do not invoke sqlite3PagerUnref() on *ppPage if an error is returned.
**
-** If the "nearby" parameter is not 0, then a (feeble) effort is made to
+** If the "nearby" parameter is not 0, then an effort is made to
** locate a page close to the page number "nearby". This can be used in an
** attempt to keep related pages close to each other in the database file,
** which in turn can make database access faster.
**
-** If the "exact" parameter is not 0, and the page-number nearby exists
-** anywhere on the free-list, then it is guarenteed to be returned. This
-** is only used by auto-vacuum databases when allocating a new table.
+** If the eMode parameter is BTALLOC_EXACT and the nearby page exists
+** anywhere on the free-list, then it is guaranteed to be returned. If
+** eMode is BTALLOC_LT then the page returned will be less than or equal
+** to nearby if any such page exists. If eMode is BTALLOC_ANY then there
+** are no restrictions on which page is returned.
*/
static int allocateBtreePage(
- BtShared *pBt,
- MemPage **ppPage,
- Pgno *pPgno,
- Pgno nearby,
- u8 exact
+ BtShared *pBt, /* The btree */
+ MemPage **ppPage, /* Store pointer to the allocated page here */
+ Pgno *pPgno, /* Store the page number here */
+ Pgno nearby, /* Search for a page near this one */
+ u8 eMode /* BTALLOC_EXACT, BTALLOC_LT, or BTALLOC_ANY */
){
MemPage *pPage1;
int rc;
@@ -52315,6 +53311,7 @@ static int allocateBtreePage(
Pgno mxPage; /* Total size of the database file */
assert( sqlite3_mutex_held(pBt->mutex) );
+ assert( eMode==BTALLOC_ANY || (nearby>0 && IfNotOmitAV(pBt->autoVacuum)) );
pPage1 = pBt->pPage1;
mxPage = btreePagecount(pBt);
n = get4byte(&pPage1->aData[36]);
@@ -52327,21 +53324,24 @@ static int allocateBtreePage(
Pgno iTrunk;
u8 searchList = 0; /* If the free-list must be searched for 'nearby' */
- /* If the 'exact' parameter was true and a query of the pointer-map
+ /* If eMode==BTALLOC_EXACT and a query of the pointer-map
** shows that the page 'nearby' is somewhere on the free-list, then
** the entire-list will be searched for that page.
*/
#ifndef SQLITE_OMIT_AUTOVACUUM
- if( exact && nearby<=mxPage ){
- u8 eType;
- assert( nearby>0 );
- assert( pBt->autoVacuum );
- rc = ptrmapGet(pBt, nearby, &eType, 0);
- if( rc ) return rc;
- if( eType==PTRMAP_FREEPAGE ){
- searchList = 1;
+ if( eMode==BTALLOC_EXACT ){
+ if( nearby<=mxPage ){
+ u8 eType;
+ assert( nearby>0 );
+ assert( pBt->autoVacuum );
+ rc = ptrmapGet(pBt, nearby, &eType, 0);
+ if( rc ) return rc;
+ if( eType==PTRMAP_FREEPAGE ){
+ searchList = 1;
+ }
}
- *pPgno = nearby;
+ }else if( eMode==BTALLOC_LE ){
+ searchList = 1;
}
#endif
@@ -52354,7 +53354,8 @@ static int allocateBtreePage(
/* The code within this loop is run only once if the 'searchList' variable
** is not true. Otherwise, it runs once for each trunk-page on the
- ** free-list until the page 'nearby' is located.
+ ** free-list until the page 'nearby' is located (eMode==BTALLOC_EXACT)
+ ** or until a page less than 'nearby' is located (eMode==BTALLOC_LT)
*/
do {
pPrevTrunk = pTrunk;
@@ -52373,6 +53374,8 @@ static int allocateBtreePage(
pTrunk = 0;
goto end_allocate_page;
}
+ assert( pTrunk!=0 );
+ assert( pTrunk->aData!=0 );
k = get4byte(&pTrunk->aData[4]); /* # of leaves on this trunk page */
if( k==0 && !searchList ){
@@ -52394,11 +53397,13 @@ static int allocateBtreePage(
rc = SQLITE_CORRUPT_BKPT;
goto end_allocate_page;
#ifndef SQLITE_OMIT_AUTOVACUUM
- }else if( searchList && nearby==iTrunk ){
+ }else if( searchList
+ && (nearby==iTrunk || (iTrunk<nearby && eMode==BTALLOC_LE))
+ ){
/* The list is being searched and this trunk page is the page
** to allocate, regardless of whether it has leaves.
*/
- assert( *pPgno==iTrunk );
+ *pPgno = iTrunk;
*ppPage = pTrunk;
searchList = 0;
rc = sqlite3PagerWrite(pTrunk->pDbPage);
@@ -52461,14 +53466,24 @@ static int allocateBtreePage(
unsigned char *aData = pTrunk->aData;
if( nearby>0 ){
u32 i;
- int dist;
closest = 0;
- dist = sqlite3AbsInt32(get4byte(&aData[8]) - nearby);
- for(i=1; i<k; i++){
- int d2 = sqlite3AbsInt32(get4byte(&aData[8+i*4]) - nearby);
- if( d2<dist ){
- closest = i;
- dist = d2;
+ if( eMode==BTALLOC_LE ){
+ for(i=0; i<k; i++){
+ iPage = get4byte(&aData[8+i*4]);
+ if( iPage<=nearby ){
+ closest = i;
+ break;
+ }
+ }
+ }else{
+ int dist;
+ dist = sqlite3AbsInt32(get4byte(&aData[8]) - nearby);
+ for(i=1; i<k; i++){
+ int d2 = sqlite3AbsInt32(get4byte(&aData[8+i*4]) - nearby);
+ if( d2<dist ){
+ closest = i;
+ dist = d2;
+ }
}
}
}else{
@@ -52482,7 +53497,9 @@ static int allocateBtreePage(
goto end_allocate_page;
}
testcase( iPage==mxPage );
- if( !searchList || iPage==nearby ){
+ if( !searchList
+ || (iPage==nearby || (iPage<nearby && eMode==BTALLOC_LE))
+ ){
int noContent;
*pPgno = iPage;
TRACE(("ALLOCATE: %d was leaf %d of %d on trunk %d"
@@ -52509,8 +53526,26 @@ static int allocateBtreePage(
pPrevTrunk = 0;
}while( searchList );
}else{
- /* There are no pages on the freelist, so create a new page at the
- ** end of the file */
+ /* There are no pages on the freelist, so append a new page to the
+ ** database image.
+ **
+ ** Normally, new pages allocated by this block can be requested from the
+ ** pager layer with the 'no-content' flag set. This prevents the pager
+ ** from trying to read the pages content from disk. However, if the
+ ** current transaction has already run one or more incremental-vacuum
+ ** steps, then the page we are about to allocate may contain content
+ ** that is required in the event of a rollback. In this case, do
+ ** not set the no-content flag. This causes the pager to load and journal
+ ** the current page content before overwriting it.
+ **
+ ** Note that the pager will not actually attempt to load or journal
+ ** content for any page that really does lie past the end of the database
+ ** file on disk. So the effects of disabling the no-content optimization
+ ** here are confined to those pages that lie between the end of the
+ ** database image and the end of the database file.
+ */
+ int bNoContent = (0==IfNotOmitAV(pBt->bDoTruncate));
+
rc = sqlite3PagerWrite(pBt->pPage1->pDbPage);
if( rc ) return rc;
pBt->nPage++;
@@ -52525,7 +53560,7 @@ static int allocateBtreePage(
MemPage *pPg = 0;
TRACE(("ALLOCATE: %d from end of file (pointer-map page)\n", pBt->nPage));
assert( pBt->nPage!=PENDING_BYTE_PAGE(pBt) );
- rc = btreeGetPage(pBt, pBt->nPage, &pPg, 1);
+ rc = btreeGetPage(pBt, pBt->nPage, &pPg, bNoContent);
if( rc==SQLITE_OK ){
rc = sqlite3PagerWrite(pPg->pDbPage);
releasePage(pPg);
@@ -52539,7 +53574,7 @@ static int allocateBtreePage(
*pPgno = pBt->nPage;
assert( *pPgno!=PENDING_BYTE_PAGE(pBt) );
- rc = btreeGetPage(pBt, *pPgno, ppPage, 1);
+ rc = btreeGetPage(pBt, *pPgno, ppPage, bNoContent);
if( rc ) return rc;
rc = sqlite3PagerWrite((*ppPage)->pDbPage);
if( rc!=SQLITE_OK ){
@@ -52603,7 +53638,7 @@ static int freePage2(BtShared *pBt, MemPage *pMemPage, Pgno iPage){
nFree = get4byte(&pPage1->aData[36]);
put4byte(&pPage1->aData[36], nFree+1);
- if( pBt->secureDelete ){
+ if( pBt->btsFlags & BTS_SECURE_DELETE ){
/* If the secure_delete option is enabled, then
** always fully overwrite deleted information with zeros.
*/
@@ -52664,7 +53699,7 @@ static int freePage2(BtShared *pBt, MemPage *pMemPage, Pgno iPage){
if( rc==SQLITE_OK ){
put4byte(&pTrunk->aData[4], nLeaf+1);
put4byte(&pTrunk->aData[8+nLeaf*4], iPage);
- if( pPage && !pBt->secureDelete ){
+ if( pPage && (pBt->btsFlags & BTS_SECURE_DELETE)==0 ){
sqlite3PagerDontWrite(pPage->pDbPage);
}
rc = btreeSetHasContent(pBt, iPage);
@@ -52722,6 +53757,9 @@ static int clearCell(MemPage *pPage, unsigned char *pCell){
if( info.iOverflow==0 ){
return SQLITE_OK; /* No overflow pages. Return without doing anything */
}
+ if( pCell+info.iOverflow+3 > pPage->aData+pPage->maskPage ){
+ return SQLITE_CORRUPT_BKPT; /* Cell extends past end of page */
+ }
ovflPgno = get4byte(&pCell[info.iOverflow]);
assert( pBt->usableSize > 4 );
ovflPageSize = pBt->usableSize - 4;
@@ -52864,7 +53902,7 @@ static int fillInCell(
** If this is the first overflow page, then write a partial entry
** to the pointer-map. If we write nothing to this pointer-map slot,
** then the optimistic overflow chain processing in clearCell()
- ** may misinterpret the uninitialised values and delete the
+ ** may misinterpret the uninitialized values and delete the
** wrong pages from the database.
*/
if( pBt->autoVacuum && rc==SQLITE_OK ){
@@ -52953,7 +53991,7 @@ static void dropCell(MemPage *pPage, int idx, int sz, int *pRC){
assert( sqlite3PagerIswriteable(pPage->pDbPage) );
assert( sqlite3_mutex_held(pPage->pBt->mutex) );
data = pPage->aData;
- ptr = &data[pPage->cellOffset + 2*idx];
+ ptr = &pPage->aCellIdx[2*idx];
pc = get2byte(ptr);
hdr = pPage->hdrOffset;
testcase( pc==get2byte(&data[hdr+5]) );
@@ -52967,7 +54005,7 @@ static void dropCell(MemPage *pPage, int idx, int sz, int *pRC){
*pRC = rc;
return;
}
- endPtr = &data[pPage->cellOffset + 2*pPage->nCell - 2];
+ endPtr = &pPage->aCellIdx[2*pPage->nCell - 2];
assert( (SQLITE_PTR_TO_INT(ptr)&1)==0 ); /* ptr is always 2-byte aligned */
while( ptr<endPtr ){
*(u16*)ptr = *(u16*)&ptr[2];
@@ -52985,7 +54023,7 @@ static void dropCell(MemPage *pPage, int idx, int sz, int *pRC){
** If the cell content will fit on the page, then put it there. If it
** will not fit, then make a copy of the cell content into pTemp if
** pTemp is not null. Regardless of pTemp, allocate a new entry
-** in pPage->aOvfl[] and make it point to the cell content (either
+** in pPage->apOvfl[] and make it point to the cell content (either
** in pTemp or the original pCell) and also record its index.
** Allocating a new entry in pPage->aCell[] implies that
** pPage->nOverflow is incremented.
@@ -53019,7 +54057,8 @@ static void insertCell(
assert( i>=0 && i<=pPage->nCell+pPage->nOverflow );
assert( pPage->nCell<=MX_CELL(pPage->pBt) && MX_CELL(pPage->pBt)<=10921 );
- assert( pPage->nOverflow<=ArraySize(pPage->aOvfl) );
+ assert( pPage->nOverflow<=ArraySize(pPage->apOvfl) );
+ assert( ArraySize(pPage->apOvfl)==ArraySize(pPage->aiOvfl) );
assert( sqlite3_mutex_held(pPage->pBt->mutex) );
/* The cell should normally be sized correctly. However, when moving a
** malformed cell from a leaf page to an interior page, if the cell size
@@ -53036,9 +54075,9 @@ static void insertCell(
put4byte(pCell, iChild);
}
j = pPage->nOverflow++;
- assert( j<(int)(sizeof(pPage->aOvfl)/sizeof(pPage->aOvfl[0])) );
- pPage->aOvfl[j].pCell = pCell;
- pPage->aOvfl[j].idx = (u16)i;
+ assert( j<(int)(sizeof(pPage->apOvfl)/sizeof(pPage->apOvfl[0])) );
+ pPage->apOvfl[j] = pCell;
+ pPage->aiOvfl[j] = (u16)i;
}else{
int rc = sqlite3PagerWrite(pPage->pDbPage);
if( rc!=SQLITE_OK ){
@@ -53109,7 +54148,7 @@ static void assemblePage(
assert( pPage->nCell==0 );
assert( get2byteNotZero(&data[hdr+5])==nUsable );
- pCellptr = &data[pPage->cellOffset + nCell*2];
+ pCellptr = &pPage->aCellIdx[nCell*2];
cellbody = nUsable;
for(i=nCell-1; i>=0; i--){
u16 sz = aSize[i];
@@ -53175,7 +54214,7 @@ static int balance_quick(MemPage *pParent, MemPage *pPage, u8 *pSpace){
assert( pPage->nOverflow==1 );
/* This error condition is now caught prior to reaching this function */
- if( pPage->nCell<=0 ) return SQLITE_CORRUPT_BKPT;
+ if( pPage->nCell==0 ) return SQLITE_CORRUPT_BKPT;
/* Allocate a new page. This page will become the right-sibling of
** pPage. Make the parent page writable, so that the new divider cell
@@ -53186,7 +54225,7 @@ static int balance_quick(MemPage *pParent, MemPage *pPage, u8 *pSpace){
if( rc==SQLITE_OK ){
u8 *pOut = &pSpace[4];
- u8 *pCell = pPage->aOvfl[0].pCell;
+ u8 *pCell = pPage->apOvfl[0];
u16 szCell = cellSizePtr(pPage, pCell);
u8 *pStop;
@@ -53296,7 +54335,7 @@ static int ptrmapCheckPages(MemPage **apPage, int nPage){
** map entries are also updated so that the parent page is page pTo.
**
** If pFrom is currently carrying any overflow cells (entries in the
-** MemPage.aOvfl[] array), they are not copied to pTo.
+** MemPage.apOvfl[] array), they are not copied to pTo.
**
** Before returning, page pTo is reinitialized using btreeInitPage().
**
@@ -53385,11 +54424,15 @@ static void copyNodeContent(MemPage *pFrom, MemPage *pTo, int *pRC){
** If aOvflSpace is set to a null pointer, this function returns
** SQLITE_NOMEM.
*/
+#if defined(_MSC_VER) && _MSC_VER >= 1700 && defined(_M_ARM)
+#pragma optimize("", off)
+#endif
static int balance_nonroot(
MemPage *pParent, /* Parent page of siblings being balanced */
int iParentIdx, /* Index of "the page" in pParent */
u8 *aOvflSpace, /* page-size bytes of space for parent ovfl */
- int isRoot /* True if pParent is a root-page */
+ int isRoot, /* True if pParent is a root-page */
+ int bBulk /* True if this call is part of a bulk load */
){
BtShared *pBt; /* The whole database */
int nCell = 0; /* Number of cells in apCell[] */
@@ -53433,7 +54476,7 @@ static int balance_nonroot(
** is called (indirectly) from sqlite3BtreeDelete().
*/
assert( pParent->nOverflow==0 || pParent->nOverflow==1 );
- assert( pParent->nOverflow==0 || pParent->aOvfl[0].idx==iParentIdx );
+ assert( pParent->nOverflow==0 || pParent->aiOvfl[0]==iParentIdx );
if( !aOvflSpace ){
return SQLITE_NOMEM;
@@ -53453,18 +54496,19 @@ static int balance_nonroot(
i = pParent->nOverflow + pParent->nCell;
if( i<2 ){
nxDiv = 0;
- nOld = i+1;
}else{
- nOld = 3;
+ assert( bBulk==0 || bBulk==1 );
if( iParentIdx==0 ){
nxDiv = 0;
}else if( iParentIdx==i ){
- nxDiv = i-2;
+ nxDiv = i-2+bBulk;
}else{
+ assert( bBulk==0 );
nxDiv = iParentIdx-1;
}
- i = 2;
+ i = 2-bBulk;
}
+ nOld = i+1;
if( (i+nxDiv-pParent->nOverflow)==pParent->nCell ){
pRight = &pParent->aData[pParent->hdrOffset+8];
}else{
@@ -53480,8 +54524,8 @@ static int balance_nonroot(
nMaxCells += 1+apOld[i]->nCell+apOld[i]->nOverflow;
if( (i--)==0 ) break;
- if( i+nxDiv==pParent->aOvfl[0].idx && pParent->nOverflow ){
- apDiv[i] = pParent->aOvfl[0].pCell;
+ if( i+nxDiv==pParent->aiOvfl[0] && pParent->nOverflow ){
+ apDiv[i] = pParent->apOvfl[0];
pgno = get4byte(apDiv[i]);
szNew[i] = cellSizePtr(pParent, apDiv[i]);
pParent->nOverflow = 0;
@@ -53497,13 +54541,15 @@ static int balance_nonroot(
** four bytes of the divider cell. So the pointer is safe to use
** later on.
**
- ** Unless SQLite is compiled in secure-delete mode. In this case,
+ ** But not if we are in secure-delete mode. In secure-delete mode,
** the dropCell() routine will overwrite the entire cell with zeroes.
** In this case, temporarily copy the cell into the aOvflSpace[]
** buffer. It will be copied out again as soon as the aSpace[] buffer
** is allocated. */
- if( pBt->secureDelete ){
- int iOff = SQLITE_PTR_TO_INT(apDiv[i]) - SQLITE_PTR_TO_INT(pParent->aData);
+ if( pBt->btsFlags & BTS_SECURE_DELETE ){
+ int iOff;
+
+ iOff = SQLITE_PTR_TO_INT(apDiv[i]) - SQLITE_PTR_TO_INT(pParent->aData);
if( (iOff+szNew[i])>(int)pBt->usableSize ){
rc = SQLITE_CORRUPT_BKPT;
memset(apOld, 0, (i+1)*sizeof(MemPage*));
@@ -53542,7 +54588,7 @@ static int balance_nonroot(
/*
** Load pointers to all cells on sibling pages and the divider cells
** into the local apCell[] array. Make copies of the divider cells
- ** into space obtained from aSpace1[] and remove the the divider Cells
+ ** into space obtained from aSpace1[] and remove the divider cells
** from pParent.
**
** If the siblings are on leaf pages, then the child pointers of the
@@ -53671,7 +54717,9 @@ static int balance_nonroot(
d = r + 1 - leafData;
assert( d<nMaxCells );
assert( r<nMaxCells );
- while( szRight==0 || szRight+szCell[d]+2<=szLeft-(szCell[r]+2) ){
+ while( szRight==0
+ || (!bBulk && szRight+szCell[d]+2<=szLeft-(szCell[r]+2))
+ ){
szRight += szCell[d] + 2;
szLeft -= szCell[r] + 2;
cntNew[i-1]--;
@@ -53685,8 +54733,14 @@ static int balance_nonroot(
/* Either we found one or more cells (cntnew[0])>0) or pPage is
** a virtual root page. A virtual root page is when the real root
** page is page 1 and we are the only child of that page.
+ **
+ ** UPDATE: The assert() below is not necessarily true if the database
+ ** file is corrupt. The corruption will be detected and reported later
+ ** in this procedure so there is no need to act upon it now.
*/
+#if 0
assert( cntNew[0]>0 || (pParent->pgno==1 && pParent->nCell==0) );
+#endif
TRACE(("BALANCE: old: %d %d %d ",
apOld[0]->pgno,
@@ -53712,7 +54766,7 @@ static int balance_nonroot(
if( rc ) goto balance_cleanup;
}else{
assert( i>0 );
- rc = allocateBtreePage(pBt, &pNew, &pgno, pgno, 0);
+ rc = allocateBtreePage(pBt, &pNew, &pgno, (bBulk ? 1 : pgno), 0);
if( rc ) goto balance_cleanup;
apNew[i] = pNew;
nNew++;
@@ -53914,7 +54968,7 @@ static int balance_nonroot(
MemPage *pOld = apCopy[0];
int nOverflow = pOld->nOverflow;
int iNextOld = pOld->nCell + nOverflow;
- int iOverflow = (nOverflow ? pOld->aOvfl[0].idx : -1);
+ int iOverflow = (nOverflow ? pOld->aiOvfl[0] : -1);
j = 0; /* Current 'old' sibling page */
k = 0; /* Current 'new' sibling page */
for(i=0; i<nCell; i++){
@@ -53923,18 +54977,20 @@ static int balance_nonroot(
/* Cell i is the cell immediately following the last cell on old
** sibling page j. If the siblings are not leaf pages of an
** intkey b-tree, then cell i was a divider cell. */
+ assert( j+1 < ArraySize(apCopy) );
+ assert( j+1 < nOld );
pOld = apCopy[++j];
iNextOld = i + !leafData + pOld->nCell + pOld->nOverflow;
if( pOld->nOverflow ){
nOverflow = pOld->nOverflow;
- iOverflow = i + !leafData + pOld->aOvfl[0].idx;
+ iOverflow = i + !leafData + pOld->aiOvfl[0];
}
isDivider = !leafData;
}
assert(nOverflow>0 || iOverflow<i );
- assert(nOverflow<2 || pOld->aOvfl[0].idx==pOld->aOvfl[1].idx-1);
- assert(nOverflow<3 || pOld->aOvfl[1].idx==pOld->aOvfl[2].idx-1);
+ assert(nOverflow<2 || pOld->aiOvfl[0]==pOld->aiOvfl[1]-1);
+ assert(nOverflow<3 || pOld->aiOvfl[1]==pOld->aiOvfl[2]-1);
if( i==iOverflow ){
isDivider = 1;
if( (--nOverflow)>0 ){
@@ -54001,6 +55057,9 @@ balance_cleanup:
return rc;
}
+#if defined(_MSC_VER) && _MSC_VER >= 1700 && defined(_M_ARM)
+#pragma optimize("", on)
+#endif
/*
@@ -54055,7 +55114,10 @@ static int balance_deeper(MemPage *pRoot, MemPage **ppChild){
TRACE(("BALANCE: copy root %d into %d\n", pRoot->pgno, pChild->pgno));
/* Copy the overflow cells from pRoot to pChild */
- memcpy(pChild->aOvfl, pRoot->aOvfl, pRoot->nOverflow*sizeof(pRoot->aOvfl[0]));
+ memcpy(pChild->aiOvfl, pRoot->aiOvfl,
+ pRoot->nOverflow*sizeof(pRoot->aiOvfl[0]));
+ memcpy(pChild->apOvfl, pRoot->apOvfl,
+ pRoot->nOverflow*sizeof(pRoot->apOvfl[0]));
pChild->nOverflow = pRoot->nOverflow;
/* Zero the contents of pRoot. Then install pChild as the right-child. */
@@ -54118,7 +55180,7 @@ static int balance(BtCursor *pCur){
#ifndef SQLITE_OMIT_QUICKBALANCE
if( pPage->hasData
&& pPage->nOverflow==1
- && pPage->aOvfl[0].idx==pPage->nCell
+ && pPage->aiOvfl[0]==pPage->nCell
&& pParent->pgno!=1
&& pParent->nCell==iIdx
){
@@ -54158,7 +55220,7 @@ static int balance(BtCursor *pCur){
** pSpace buffer passed to the latter call to balance_nonroot().
*/
u8 *pSpace = sqlite3PageMalloc(pCur->pBt->pageSize);
- rc = balance_nonroot(pParent, iIdx, pSpace, iPage==1);
+ rc = balance_nonroot(pParent, iIdx, pSpace, iPage==1, pCur->hints);
if( pFree ){
/* If pFree is not NULL, it points to the pSpace buffer used
** by a previous call to balance_nonroot(). Its contents are
@@ -54235,7 +55297,8 @@ SQLITE_PRIVATE int sqlite3BtreeInsert(
}
assert( cursorHoldsMutex(pCur) );
- assert( pCur->wrFlag && pBt->inTransaction==TRANS_WRITE && !pBt->readOnly );
+ assert( pCur->wrFlag && pBt->inTransaction==TRANS_WRITE
+ && (pBt->btsFlags & BTS_READ_ONLY)==0 );
assert( hasSharedCacheTableLock(p, pCur->pgnoRoot, pCur->pKeyInfo!=0, 2) );
/* Assert that the caller has been consistent. If this cursor was opened
@@ -54245,13 +55308,6 @@ SQLITE_PRIVATE int sqlite3BtreeInsert(
** blob of associated data. */
assert( (pKey==0)==(pCur->pKeyInfo==0) );
- /* If this is an insert into a table b-tree, invalidate any incrblob
- ** cursors open on the row being replaced (assuming this is a replace
- ** operation - if it is not, the following is a no-op). */
- if( pCur->pKeyInfo==0 ){
- invalidateIncrblobCursors(p, nKey, 0);
- }
-
/* Save the positions of any other cursors open on this table.
**
** In some cases, the call to btreeMoveto() below is a no-op. For
@@ -54265,6 +55321,14 @@ SQLITE_PRIVATE int sqlite3BtreeInsert(
*/
rc = saveAllCursors(pBt, pCur->pgnoRoot, pCur);
if( rc ) return rc;
+
+ /* If this is an insert into a table b-tree, invalidate any incrblob
+ ** cursors open on the row being replaced (assuming this is a replace
+ ** operation - if it is not, the following is a no-op). */
+ if( pCur->pKeyInfo==0 ){
+ invalidateIncrblobCursors(p, nKey, 0);
+ }
+
if( !loc ){
rc = btreeMoveto(pCur, pKey, nKey, appendBias, &loc);
if( rc ) return rc;
@@ -54311,7 +55375,7 @@ SQLITE_PRIVATE int sqlite3BtreeInsert(
insertCell(pPage, idx, newCell, szNew, 0, 0, &rc);
assert( rc!=SQLITE_OK || pPage->nCell>0 || pPage->nOverflow>0 );
- /* If no error has occured and pPage has an overflow cell, call balance()
+ /* If no error has occurred and pPage has an overflow cell, call balance()
** to redistribute the cells within the tree. Since balance() may move
** the cursor, zero the BtCursor.info.nSize and BtCursor.validNKey
** variables.
@@ -54364,7 +55428,7 @@ SQLITE_PRIVATE int sqlite3BtreeDelete(BtCursor *pCur){
assert( cursorHoldsMutex(pCur) );
assert( pBt->inTransaction==TRANS_WRITE );
- assert( !pBt->readOnly );
+ assert( (pBt->btsFlags & BTS_READ_ONLY)==0 );
assert( pCur->wrFlag );
assert( hasSharedCacheTableLock(p, pCur->pgnoRoot, pCur->pKeyInfo!=0, 2) );
assert( !hasReadConflicts(p, pCur->pgnoRoot) );
@@ -54375,12 +55439,6 @@ SQLITE_PRIVATE int sqlite3BtreeDelete(BtCursor *pCur){
return SQLITE_ERROR; /* Something has gone awry. */
}
- /* If this is a delete operation to remove a row from a table b-tree,
- ** invalidate any incrblob cursors open on the row being deleted. */
- if( pCur->pKeyInfo==0 ){
- invalidateIncrblobCursors(p, pCur->info.nKey, 0);
- }
-
iCellDepth = pCur->iPage;
iCellIdx = pCur->aiIdx[iCellDepth];
pPage = pCur->apPage[iCellDepth];
@@ -54406,6 +55464,13 @@ SQLITE_PRIVATE int sqlite3BtreeDelete(BtCursor *pCur){
*/
rc = saveAllCursors(pBt, pCur->pgnoRoot, pCur);
if( rc ) return rc;
+
+ /* If this is a delete operation to remove a row from a table b-tree,
+ ** invalidate any incrblob cursors open on the row being deleted. */
+ if( pCur->pKeyInfo==0 ){
+ invalidateIncrblobCursors(p, pCur->info.nKey, 0);
+ }
+
rc = sqlite3PagerWrite(pPage->pDbPage);
if( rc ) return rc;
rc = clearCell(pPage, pCell);
@@ -54485,7 +55550,7 @@ static int btreeCreateTable(Btree *p, int *piTable, int createTabFlags){
assert( sqlite3BtreeHoldsMutex(p) );
assert( pBt->inTransaction==TRANS_WRITE );
- assert( !pBt->readOnly );
+ assert( (pBt->btsFlags & BTS_READ_ONLY)==0 );
#ifdef SQLITE_OMIT_AUTOVACUUM
rc = allocateBtreePage(pBt, &pRoot, &pgnoRoot, 1, 0);
@@ -54524,7 +55589,7 @@ static int btreeCreateTable(Btree *p, int *piTable, int createTabFlags){
** be moved to the allocated page (unless the allocated page happens
** to reside at pgnoRoot).
*/
- rc = allocateBtreePage(pBt, &pPageMove, &pgnoMove, pgnoRoot, 1);
+ rc = allocateBtreePage(pBt, &pPageMove, &pgnoMove, pgnoRoot, BTALLOC_EXACT);
if( rc!=SQLITE_OK ){
return rc;
}
@@ -54687,13 +55752,13 @@ SQLITE_PRIVATE int sqlite3BtreeClearTable(Btree *p, int iTable, int *pnChange){
sqlite3BtreeEnter(p);
assert( p->inTrans==TRANS_WRITE );
- /* Invalidate all incrblob cursors open on table iTable (assuming iTable
- ** is the root of a table b-tree - if it is not, the following call is
- ** a no-op). */
- invalidateIncrblobCursors(p, 0, 1);
-
rc = saveAllCursors(pBt, (Pgno)iTable, 0);
+
if( SQLITE_OK==rc ){
+ /* Invalidate all incrblob cursors open on table iTable (assuming iTable
+ ** is the root of a table b-tree - if it is not, the following call is
+ ** a no-op). */
+ invalidateIncrblobCursors(p, 0, 1);
rc = clearDatabasePage(pBt, (Pgno)iTable, 0, pnChange);
}
sqlite3BtreeLeave(p);
@@ -54859,7 +55924,9 @@ SQLITE_PRIVATE void sqlite3BtreeGetMeta(Btree *p, int idx, u32 *pMeta){
/* If auto-vacuum is disabled in this build and this is an auto-vacuum
** database, mark the database as read-only. */
#ifdef SQLITE_OMIT_AUTOVACUUM
- if( idx==BTREE_LARGEST_ROOT_PAGE && *pMeta>0 ) pBt->readOnly = 1;
+ if( idx==BTREE_LARGEST_ROOT_PAGE && *pMeta>0 ){
+ pBt->btsFlags |= BTS_READ_ONLY;
+ }
#endif
sqlite3BtreeLeave(p);
@@ -54905,6 +55972,11 @@ SQLITE_PRIVATE int sqlite3BtreeUpdateMeta(Btree *p, int idx, u32 iMeta){
SQLITE_PRIVATE int sqlite3BtreeCount(BtCursor *pCur, i64 *pnEntry){
i64 nEntry = 0; /* Value to return in *pnEntry */
int rc; /* Return code */
+
+ if( pCur->pgnoRoot==0 ){
+ *pnEntry = 0;
+ return SQLITE_OK;
+ }
rc = moveToRoot(pCur);
/* Unless an error occurs, the following loop runs one iteration for each
@@ -55001,6 +56073,25 @@ static void checkAppendMsg(
#endif /* SQLITE_OMIT_INTEGRITY_CHECK */
#ifndef SQLITE_OMIT_INTEGRITY_CHECK
+
+/*
+** Return non-zero if the bit in the IntegrityCk.aPgRef[] array that
+** corresponds to page iPg is already set.
+*/
+static int getPageReferenced(IntegrityCk *pCheck, Pgno iPg){
+ assert( iPg<=pCheck->nPage && sizeof(pCheck->aPgRef[0])==1 );
+ return (pCheck->aPgRef[iPg/8] & (1 << (iPg & 0x07)));
+}
+
+/*
+** Set the bit in the IntegrityCk.aPgRef[] array that corresponds to page iPg.
+*/
+static void setPageReferenced(IntegrityCk *pCheck, Pgno iPg){
+ assert( iPg<=pCheck->nPage && sizeof(pCheck->aPgRef[0])==1 );
+ pCheck->aPgRef[iPg/8] |= (1 << (iPg & 0x07));
+}
+
+
/*
** Add 1 to the reference count for page iPage. If this is the second
** reference to the page, add an error message to pCheck->zErrMsg.
@@ -55015,11 +56106,12 @@ static int checkRef(IntegrityCk *pCheck, Pgno iPage, char *zContext){
checkAppendMsg(pCheck, zContext, "invalid page number %d", iPage);
return 1;
}
- if( pCheck->anRef[iPage]==1 ){
+ if( getPageReferenced(pCheck, iPage) ){
checkAppendMsg(pCheck, zContext, "2nd reference to page %d", iPage);
return 1;
}
- return (pCheck->anRef[iPage]++)>1;
+ setPageReferenced(pCheck, iPage);
+ return 0;
}
#ifndef SQLITE_OMIT_AUTOVACUUM
@@ -55395,18 +56487,16 @@ SQLITE_PRIVATE char *sqlite3BtreeIntegrityCheck(
sqlite3BtreeLeave(p);
return 0;
}
- sCheck.anRef = sqlite3Malloc( (sCheck.nPage+1)*sizeof(sCheck.anRef[0]) );
- if( !sCheck.anRef ){
+
+ sCheck.aPgRef = sqlite3MallocZero((sCheck.nPage / 8)+ 1);
+ if( !sCheck.aPgRef ){
*pnErr = 1;
sqlite3BtreeLeave(p);
return 0;
}
- for(i=0; i<=sCheck.nPage; i++){ sCheck.anRef[i] = 0; }
i = PENDING_BYTE_PAGE(pBt);
- if( i<=sCheck.nPage ){
- sCheck.anRef[i] = 1;
- }
- sqlite3StrAccumInit(&sCheck.errMsg, zErr, sizeof(zErr), 20000);
+ if( i<=sCheck.nPage ) setPageReferenced(&sCheck, i);
+ sqlite3StrAccumInit(&sCheck.errMsg, zErr, sizeof(zErr), SQLITE_MAX_LENGTH);
sCheck.errMsg.useMalloc = 2;
/* Check the integrity of the freelist
@@ -55430,18 +56520,18 @@ SQLITE_PRIVATE char *sqlite3BtreeIntegrityCheck(
*/
for(i=1; i<=sCheck.nPage && sCheck.mxErr; i++){
#ifdef SQLITE_OMIT_AUTOVACUUM
- if( sCheck.anRef[i]==0 ){
+ if( getPageReferenced(&sCheck, i)==0 ){
checkAppendMsg(&sCheck, 0, "Page %d is never used", i);
}
#else
/* If the database supports auto-vacuum, make sure no tables contain
** references to pointer-map pages.
*/
- if( sCheck.anRef[i]==0 &&
+ if( getPageReferenced(&sCheck, i)==0 &&
(PTRMAP_PAGENO(pBt, i)!=i || !pBt->autoVacuum) ){
checkAppendMsg(&sCheck, 0, "Page %d is never used", i);
}
- if( sCheck.anRef[i]!=0 &&
+ if( getPageReferenced(&sCheck, i)!=0 &&
(PTRMAP_PAGENO(pBt, i)==i && pBt->autoVacuum) ){
checkAppendMsg(&sCheck, 0, "Pointer map page %d is referenced", i);
}
@@ -55462,7 +56552,7 @@ SQLITE_PRIVATE char *sqlite3BtreeIntegrityCheck(
/* Clean up and report errors.
*/
sqlite3BtreeLeave(p);
- sqlite3_free(sCheck.anRef);
+ sqlite3_free(sCheck.aPgRef);
if( sCheck.mallocFailed ){
sqlite3StrAccumReset(&sCheck.errMsg);
*pnErr = sCheck.nErr+1;
@@ -55475,14 +56565,15 @@ SQLITE_PRIVATE char *sqlite3BtreeIntegrityCheck(
#endif /* SQLITE_OMIT_INTEGRITY_CHECK */
/*
-** Return the full pathname of the underlying database file.
+** Return the full pathname of the underlying database file. Return
+** an empty string if the database is in-memory or a TEMP database.
**
** The pager filename is invariant as long as the pager is
** open so it is safe to access without the BtShared mutex.
*/
SQLITE_PRIVATE const char *sqlite3BtreeGetFilename(Btree *p){
assert( p->pBt->pPager!=0 );
- return sqlite3PagerFilename(p->pBt->pPager);
+ return sqlite3PagerFilename(p->pBt->pPager, 1);
}
/*
@@ -55654,7 +56745,8 @@ SQLITE_PRIVATE int sqlite3BtreePutData(BtCursor *pCsr, u32 offset, u32 amt, void
if( !pCsr->wrFlag ){
return SQLITE_READONLY;
}
- assert( !pCsr->pBt->readOnly && pCsr->pBt->inTransaction==TRANS_WRITE );
+ assert( (pCsr->pBt->btsFlags & BTS_READ_ONLY)==0
+ && pCsr->pBt->inTransaction==TRANS_WRITE );
assert( hasSharedCacheTableLock(pCsr->pBtree, pCsr->pgnoRoot, 0, 2) );
assert( !hasReadConflicts(pCsr->pBtree, pCsr->pgnoRoot) );
assert( pCsr->apPage[pCsr->iPage]->intKey );
@@ -55689,13 +56781,13 @@ SQLITE_PRIVATE int sqlite3BtreeSetVersion(Btree *pBtree, int iVersion){
BtShared *pBt = pBtree->pBt;
int rc; /* Return code */
- assert( pBtree->inTrans==TRANS_NONE );
assert( iVersion==1 || iVersion==2 );
/* If setting the version fields to 1, do not automatically open the
** WAL connection, even if the version fields are currently set to 2.
*/
- pBt->doNotUseWAL = (u8)(iVersion==1);
+ pBt->btsFlags &= ~BTS_NO_WAL;
+ if( iVersion==1 ) pBt->btsFlags |= BTS_NO_WAL;
rc = sqlite3BtreeBeginTrans(pBtree, 0);
if( rc==SQLITE_OK ){
@@ -55712,10 +56804,19 @@ SQLITE_PRIVATE int sqlite3BtreeSetVersion(Btree *pBtree, int iVersion){
}
}
- pBt->doNotUseWAL = 0;
+ pBt->btsFlags &= ~BTS_NO_WAL;
return rc;
}
+/*
+** set the mask of hint flags for cursor pCsr. Currently the only valid
+** values are 0 and BTREE_BULKLOAD.
+*/
+SQLITE_PRIVATE void sqlite3BtreeCursorHints(BtCursor *pCsr, unsigned int mask){
+ assert( mask==BTREE_BULKLOAD || mask==0 );
+ pCsr->hints = mask;
+}
+
/************** End of btree.c ***********************************************/
/************** Begin file backup.c ******************************************/
/*
@@ -55882,7 +56983,7 @@ SQLITE_API sqlite3_backup *sqlite3_backup_init(
** EVIDENCE-OF: R-64852-21591 The sqlite3_backup object is created by a
** call to sqlite3_backup_init() and is destroyed by a call to
** sqlite3_backup_finish(). */
- p = (sqlite3_backup *)sqlite3_malloc(sizeof(sqlite3_backup));
+ p = (sqlite3_backup *)sqlite3MallocZero(sizeof(sqlite3_backup));
if( !p ){
sqlite3Error(pDestDb, SQLITE_NOMEM, 0);
}
@@ -55890,7 +56991,6 @@ SQLITE_API sqlite3_backup *sqlite3_backup_init(
/* If the allocation succeeded, populate the new object. */
if( p ){
- memset(p, 0, sizeof(sqlite3_backup));
p->pSrc = findBtree(pDestDb, pSrcDb, zSrcDb);
p->pDest = findBtree(pDestDb, pDestDb, zDestDb);
p->pDestDb = pDestDb;
@@ -55931,20 +57031,28 @@ static int isFatalError(int rc){
** page iSrcPg from the source database. Copy this data into the
** destination database.
*/
-static int backupOnePage(sqlite3_backup *p, Pgno iSrcPg, const u8 *zSrcData){
+static int backupOnePage(
+ sqlite3_backup *p, /* Backup handle */
+ Pgno iSrcPg, /* Source database page to backup */
+ const u8 *zSrcData, /* Source database page data */
+ int bUpdate /* True for an update, false otherwise */
+){
Pager * const pDestPager = sqlite3BtreePager(p->pDest);
const int nSrcPgsz = sqlite3BtreeGetPageSize(p->pSrc);
int nDestPgsz = sqlite3BtreeGetPageSize(p->pDest);
const int nCopy = MIN(nSrcPgsz, nDestPgsz);
const i64 iEnd = (i64)iSrcPg*(i64)nSrcPgsz;
#ifdef SQLITE_HAS_CODEC
- int nSrcReserve = sqlite3BtreeGetReserve(p->pSrc);
+ /* Use BtreeGetReserveNoMutex() for the source b-tree, as although it is
+ ** guaranteed that the shared-mutex is held by this thread, handle
+ ** p->pSrc may not actually be the owner. */
+ int nSrcReserve = sqlite3BtreeGetReserveNoMutex(p->pSrc);
int nDestReserve = sqlite3BtreeGetReserve(p->pDest);
#endif
-
int rc = SQLITE_OK;
i64 iOff;
+ assert( sqlite3BtreeGetReserveNoMutex(p->pSrc)>=0 );
assert( p->bDestLocked );
assert( !isFatalError(p->rc) );
assert( iSrcPg!=PENDING_BYTE_PAGE(p->pSrc->pBt) );
@@ -56001,6 +57109,9 @@ static int backupOnePage(sqlite3_backup *p, Pgno iSrcPg, const u8 *zSrcData){
*/
memcpy(zOut, zIn, nCopy);
((u8 *)sqlite3PagerGetExtra(pDestPg))[0] = 0;
+ if( iOff==0 && bUpdate==0 ){
+ sqlite3Put4byte(&zOut[28], sqlite3BtreeLastPage(p->pSrc));
+ }
}
sqlite3PagerUnref(pDestPg);
}
@@ -56107,7 +57218,7 @@ SQLITE_API int sqlite3_backup_step(sqlite3_backup *p, int nPage){
DbPage *pSrcPg; /* Source page object */
rc = sqlite3PagerGet(pSrcPager, iSrcPg, &pSrcPg);
if( rc==SQLITE_OK ){
- rc = backupOnePage(p, iSrcPg, sqlite3PagerGetData(pSrcPg));
+ rc = backupOnePage(p, iSrcPg, sqlite3PagerGetData(pSrcPg), 0);
sqlite3PagerUnref(pSrcPg);
}
}
@@ -56128,102 +57239,129 @@ SQLITE_API int sqlite3_backup_step(sqlite3_backup *p, int nPage){
** the case where the source and destination databases have the
** same schema version.
*/
- if( rc==SQLITE_DONE
- && (rc = sqlite3BtreeUpdateMeta(p->pDest,1,p->iDestSchema+1))==SQLITE_OK
- ){
- int nDestTruncate;
-
- if( p->pDestDb ){
- sqlite3ResetInternalSchema(p->pDestDb, -1);
+ if( rc==SQLITE_DONE ){
+ if( nSrcPage==0 ){
+ rc = sqlite3BtreeNewDb(p->pDest);
+ nSrcPage = 1;
}
-
- /* Set nDestTruncate to the final number of pages in the destination
- ** database. The complication here is that the destination page
- ** size may be different to the source page size.
- **
- ** If the source page size is smaller than the destination page size,
- ** round up. In this case the call to sqlite3OsTruncate() below will
- ** fix the size of the file. However it is important to call
- ** sqlite3PagerTruncateImage() here so that any pages in the
- ** destination file that lie beyond the nDestTruncate page mark are
- ** journalled by PagerCommitPhaseOne() before they are destroyed
- ** by the file truncation.
- */
- assert( pgszSrc==sqlite3BtreeGetPageSize(p->pSrc) );
- assert( pgszDest==sqlite3BtreeGetPageSize(p->pDest) );
- if( pgszSrc<pgszDest ){
- int ratio = pgszDest/pgszSrc;
- nDestTruncate = (nSrcPage+ratio-1)/ratio;
- if( nDestTruncate==(int)PENDING_BYTE_PAGE(p->pDest->pBt) ){
- nDestTruncate--;
+ if( rc==SQLITE_OK || rc==SQLITE_DONE ){
+ rc = sqlite3BtreeUpdateMeta(p->pDest,1,p->iDestSchema+1);
+ }
+ if( rc==SQLITE_OK ){
+ if( p->pDestDb ){
+ sqlite3ResetAllSchemasOfConnection(p->pDestDb);
+ }
+ if( destMode==PAGER_JOURNALMODE_WAL ){
+ rc = sqlite3BtreeSetVersion(p->pDest, 2);
}
- }else{
- nDestTruncate = nSrcPage * (pgszSrc/pgszDest);
}
- sqlite3PagerTruncateImage(pDestPager, nDestTruncate);
-
- if( pgszSrc<pgszDest ){
- /* If the source page-size is smaller than the destination page-size,
- ** two extra things may need to happen:
- **
- ** * The destination may need to be truncated, and
+ if( rc==SQLITE_OK ){
+ int nDestTruncate;
+ /* Set nDestTruncate to the final number of pages in the destination
+ ** database. The complication here is that the destination page
+ ** size may be different to the source page size.
**
- ** * Data stored on the pages immediately following the
- ** pending-byte page in the source database may need to be
- ** copied into the destination database.
+ ** If the source page size is smaller than the destination page size,
+ ** round up. In this case the call to sqlite3OsTruncate() below will
+ ** fix the size of the file. However it is important to call
+ ** sqlite3PagerTruncateImage() here so that any pages in the
+ ** destination file that lie beyond the nDestTruncate page mark are
+ ** journalled by PagerCommitPhaseOne() before they are destroyed
+ ** by the file truncation.
*/
- const i64 iSize = (i64)pgszSrc * (i64)nSrcPage;
- sqlite3_file * const pFile = sqlite3PagerFile(pDestPager);
- i64 iOff;
- i64 iEnd;
-
- assert( pFile );
- assert( (i64)nDestTruncate*(i64)pgszDest >= iSize || (
- nDestTruncate==(int)(PENDING_BYTE_PAGE(p->pDest->pBt)-1)
- && iSize>=PENDING_BYTE && iSize<=PENDING_BYTE+pgszDest
- ));
+ assert( pgszSrc==sqlite3BtreeGetPageSize(p->pSrc) );
+ assert( pgszDest==sqlite3BtreeGetPageSize(p->pDest) );
+ if( pgszSrc<pgszDest ){
+ int ratio = pgszDest/pgszSrc;
+ nDestTruncate = (nSrcPage+ratio-1)/ratio;
+ if( nDestTruncate==(int)PENDING_BYTE_PAGE(p->pDest->pBt) ){
+ nDestTruncate--;
+ }
+ }else{
+ nDestTruncate = nSrcPage * (pgszSrc/pgszDest);
+ }
+ assert( nDestTruncate>0 );
- /* This call ensures that all data required to recreate the original
- ** database has been stored in the journal for pDestPager and the
- ** journal synced to disk. So at this point we may safely modify
- ** the database file in any way, knowing that if a power failure
- ** occurs, the original database will be reconstructed from the
- ** journal file. */
- rc = sqlite3PagerCommitPhaseOne(pDestPager, 0, 1);
-
- /* Write the extra pages and truncate the database file as required. */
- iEnd = MIN(PENDING_BYTE + pgszDest, iSize);
- for(
- iOff=PENDING_BYTE+pgszSrc;
- rc==SQLITE_OK && iOff<iEnd;
- iOff+=pgszSrc
- ){
- PgHdr *pSrcPg = 0;
- const Pgno iSrcPg = (Pgno)((iOff/pgszSrc)+1);
- rc = sqlite3PagerGet(pSrcPager, iSrcPg, &pSrcPg);
+ if( pgszSrc<pgszDest ){
+ /* If the source page-size is smaller than the destination page-size,
+ ** two extra things may need to happen:
+ **
+ ** * The destination may need to be truncated, and
+ **
+ ** * Data stored on the pages immediately following the
+ ** pending-byte page in the source database may need to be
+ ** copied into the destination database.
+ */
+ const i64 iSize = (i64)pgszSrc * (i64)nSrcPage;
+ sqlite3_file * const pFile = sqlite3PagerFile(pDestPager);
+ Pgno iPg;
+ int nDstPage;
+ i64 iOff;
+ i64 iEnd;
+
+ assert( pFile );
+ assert( nDestTruncate==0
+ || (i64)nDestTruncate*(i64)pgszDest >= iSize || (
+ nDestTruncate==(int)(PENDING_BYTE_PAGE(p->pDest->pBt)-1)
+ && iSize>=PENDING_BYTE && iSize<=PENDING_BYTE+pgszDest
+ ));
+
+ /* This block ensures that all data required to recreate the original
+ ** database has been stored in the journal for pDestPager and the
+ ** journal synced to disk. So at this point we may safely modify
+ ** the database file in any way, knowing that if a power failure
+ ** occurs, the original database will be reconstructed from the
+ ** journal file. */
+ sqlite3PagerPagecount(pDestPager, &nDstPage);
+ for(iPg=nDestTruncate; rc==SQLITE_OK && iPg<=(Pgno)nDstPage; iPg++){
+ if( iPg!=PENDING_BYTE_PAGE(p->pDest->pBt) ){
+ DbPage *pPg;
+ rc = sqlite3PagerGet(pDestPager, iPg, &pPg);
+ if( rc==SQLITE_OK ){
+ rc = sqlite3PagerWrite(pPg);
+ sqlite3PagerUnref(pPg);
+ }
+ }
+ }
if( rc==SQLITE_OK ){
- u8 *zData = sqlite3PagerGetData(pSrcPg);
- rc = sqlite3OsWrite(pFile, zData, pgszSrc, iOff);
+ rc = sqlite3PagerCommitPhaseOne(pDestPager, 0, 1);
}
- sqlite3PagerUnref(pSrcPg);
- }
- if( rc==SQLITE_OK ){
- rc = backupTruncateFile(pFile, iSize);
- }
- /* Sync the database file to disk. */
- if( rc==SQLITE_OK ){
- rc = sqlite3PagerSync(pDestPager);
+ /* Write the extra pages and truncate the database file as required */
+ iEnd = MIN(PENDING_BYTE + pgszDest, iSize);
+ for(
+ iOff=PENDING_BYTE+pgszSrc;
+ rc==SQLITE_OK && iOff<iEnd;
+ iOff+=pgszSrc
+ ){
+ PgHdr *pSrcPg = 0;
+ const Pgno iSrcPg = (Pgno)((iOff/pgszSrc)+1);
+ rc = sqlite3PagerGet(pSrcPager, iSrcPg, &pSrcPg);
+ if( rc==SQLITE_OK ){
+ u8 *zData = sqlite3PagerGetData(pSrcPg);
+ rc = sqlite3OsWrite(pFile, zData, pgszSrc, iOff);
+ }
+ sqlite3PagerUnref(pSrcPg);
+ }
+ if( rc==SQLITE_OK ){
+ rc = backupTruncateFile(pFile, iSize);
+ }
+
+ /* Sync the database file to disk. */
+ if( rc==SQLITE_OK ){
+ rc = sqlite3PagerSync(pDestPager);
+ }
+ }else{
+ sqlite3PagerTruncateImage(pDestPager, nDestTruncate);
+ rc = sqlite3PagerCommitPhaseOne(pDestPager, 0, 0);
+ }
+
+ /* Finish committing the transaction to the destination database. */
+ if( SQLITE_OK==rc
+ && SQLITE_OK==(rc = sqlite3BtreeCommitPhaseTwo(p->pDest, 0))
+ ){
+ rc = SQLITE_DONE;
}
- }else{
- rc = sqlite3PagerCommitPhaseOne(pDestPager, 0, 0);
- }
-
- /* Finish committing the transaction to the destination database. */
- if( SQLITE_OK==rc
- && SQLITE_OK==(rc = sqlite3BtreeCommitPhaseTwo(p->pDest, 0))
- ){
- rc = SQLITE_DONE;
}
}
@@ -56257,14 +57395,14 @@ SQLITE_API int sqlite3_backup_step(sqlite3_backup *p, int nPage){
*/
SQLITE_API int sqlite3_backup_finish(sqlite3_backup *p){
sqlite3_backup **pp; /* Ptr to head of pagers backup list */
- sqlite3_mutex *mutex; /* Mutex to protect source database */
+ sqlite3 *pSrcDb; /* Source database connection */
int rc; /* Value to return */
/* Enter the mutexes */
if( p==0 ) return SQLITE_OK;
- sqlite3_mutex_enter(p->pSrcDb->mutex);
+ pSrcDb = p->pSrcDb;
+ sqlite3_mutex_enter(pSrcDb->mutex);
sqlite3BtreeEnter(p->pSrc);
- mutex = p->pSrcDb->mutex;
if( p->pDestDb ){
sqlite3_mutex_enter(p->pDestDb->mutex);
}
@@ -56282,7 +57420,7 @@ SQLITE_API int sqlite3_backup_finish(sqlite3_backup *p){
}
/* If a transaction is still open on the Btree, roll it back. */
- sqlite3BtreeRollback(p->pDest);
+ sqlite3BtreeRollback(p->pDest, SQLITE_OK);
/* Set the error code of the destination database handle. */
rc = (p->rc==SQLITE_DONE) ? SQLITE_OK : p->rc;
@@ -56290,7 +57428,7 @@ SQLITE_API int sqlite3_backup_finish(sqlite3_backup *p){
/* Exit the mutexes and free the backup context structure. */
if( p->pDestDb ){
- sqlite3_mutex_leave(p->pDestDb->mutex);
+ sqlite3LeaveMutexAndCloseZombie(p->pDestDb);
}
sqlite3BtreeLeave(p->pSrc);
if( p->pDestDb ){
@@ -56299,7 +57437,7 @@ SQLITE_API int sqlite3_backup_finish(sqlite3_backup *p){
** sqlite3_backup_finish(). */
sqlite3_free(p);
}
- sqlite3_mutex_leave(mutex);
+ sqlite3LeaveMutexAndCloseZombie(pSrcDb);
return rc;
}
@@ -56343,7 +57481,7 @@ SQLITE_PRIVATE void sqlite3BackupUpdate(sqlite3_backup *pBackup, Pgno iPage, con
int rc;
assert( p->pDestDb );
sqlite3_mutex_enter(p->pDestDb->mutex);
- rc = backupOnePage(p, iPage, aData);
+ rc = backupOnePage(p, iPage, aData, 1);
sqlite3_mutex_leave(p->pDestDb->mutex);
assert( rc!=SQLITE_BUSY && rc!=SQLITE_LOCKED );
if( rc!=SQLITE_OK ){
@@ -56383,10 +57521,20 @@ SQLITE_PRIVATE void sqlite3BackupRestart(sqlite3_backup *pBackup){
*/
SQLITE_PRIVATE int sqlite3BtreeCopyFile(Btree *pTo, Btree *pFrom){
int rc;
+ sqlite3_file *pFd; /* File descriptor for database pTo */
sqlite3_backup b;
sqlite3BtreeEnter(pTo);
sqlite3BtreeEnter(pFrom);
+ assert( sqlite3BtreeIsInTrans(pTo) );
+ pFd = sqlite3PagerFile(sqlite3BtreePager(pTo));
+ if( pFd->pMethods ){
+ i64 nByte = sqlite3BtreeGetPageSize(pFrom)*(i64)sqlite3BtreeLastPage(pFrom);
+ rc = sqlite3OsFileControl(pFd, SQLITE_FCNTL_OVERWRITE, &nByte);
+ if( rc==SQLITE_NOTFOUND ) rc = SQLITE_OK;
+ if( rc ) goto copy_finished;
+ }
+
/* Set up an sqlite3_backup object. sqlite3_backup.pDestDb must be set
** to 0. This is used by the implementations of sqlite3_backup_step()
** and sqlite3_backup_finish() to detect that they are being called
@@ -56409,9 +57557,13 @@ SQLITE_PRIVATE int sqlite3BtreeCopyFile(Btree *pTo, Btree *pFrom){
assert( b.rc!=SQLITE_OK );
rc = sqlite3_backup_finish(&b);
if( rc==SQLITE_OK ){
- pTo->pBt->pageSizeFixed = 0;
+ pTo->pBt->btsFlags &= ~BTS_PAGESIZE_FIXED;
+ }else{
+ sqlite3PagerClearCache(sqlite3BtreePager(b.pDest));
}
+ assert( sqlite3BtreeIsInTrans(pTo)==0 );
+copy_finished:
sqlite3BtreeLeave(pFrom);
sqlite3BtreeLeave(pTo);
return rc;
@@ -56439,12 +57591,6 @@ SQLITE_PRIVATE int sqlite3BtreeCopyFile(Btree *pTo, Btree *pFrom){
*/
/*
-** Call sqlite3VdbeMemExpandBlob() on the supplied value (type Mem*)
-** P if required.
-*/
-#define expandBlob(P) (((P)->flags&MEM_Zero)?sqlite3VdbeMemExpandBlob(P):0)
-
-/*
** If pMem is an object with a valid string representation, this routine
** ensures the internal encoding for the string representation is
** 'desiredEnc', one of SQLITE_UTF8, SQLITE_UTF16LE or SQLITE_UTF16BE.
@@ -56458,7 +57604,9 @@ SQLITE_PRIVATE int sqlite3BtreeCopyFile(Btree *pTo, Btree *pFrom){
** between formats.
*/
SQLITE_PRIVATE int sqlite3VdbeChangeEncoding(Mem *pMem, int desiredEnc){
+#ifndef SQLITE_OMIT_UTF16
int rc;
+#endif
assert( (pMem->flags&MEM_RowSet)==0 );
assert( desiredEnc==SQLITE_UTF8 || desiredEnc==SQLITE_UTF16LE
|| desiredEnc==SQLITE_UTF16BE );
@@ -56485,10 +57633,10 @@ SQLITE_PRIVATE int sqlite3VdbeChangeEncoding(Mem *pMem, int desiredEnc){
** Make sure pMem->z points to a writable allocation of at least
** n bytes.
**
-** If the memory cell currently contains string or blob data
-** and the third argument passed to this function is true, the
-** current content of the cell is preserved. Otherwise, it may
-** be discarded.
+** If the third argument passed to this function is true, then memory
+** cell pMem must contain a string or blob. In this case the content is
+** preserved. Otherwise, if the third parameter to this function is false,
+** any current string or blob value may be discarded.
**
** This function sets the MEM_Dyn flag and clears any xDel callback.
** It also clears MEM_Ephem and MEM_Static. If the preserve flag is
@@ -56503,6 +57651,10 @@ SQLITE_PRIVATE int sqlite3VdbeMemGrow(Mem *pMem, int n, int preserve){
);
assert( (pMem->flags&MEM_RowSet)==0 );
+ /* If the preserve flag is set to true, then the memory cell must already
+ ** contain a valid string or blob value. */
+ assert( preserve==0 || pMem->flags&(MEM_Blob|MEM_Str) );
+
if( n<32 ) n = 32;
if( sqlite3DbMallocSize(pMem->db, pMem->zMalloc)<n ){
if( preserve && pMem->z==pMem->zMalloc ){
@@ -56518,6 +57670,7 @@ SQLITE_PRIVATE int sqlite3VdbeMemGrow(Mem *pMem, int n, int preserve){
memcpy(pMem->zMalloc, pMem->z, pMem->n);
}
if( pMem->flags&MEM_Dyn && pMem->xDel ){
+ assert( pMem->xDel!=SQLITE_DYNAMIC );
pMem->xDel((void *)(pMem->z));
}
@@ -56543,7 +57696,7 @@ SQLITE_PRIVATE int sqlite3VdbeMemMakeWriteable(Mem *pMem){
int f;
assert( pMem->db==0 || sqlite3_mutex_held(pMem->db->mutex) );
assert( (pMem->flags&MEM_RowSet)==0 );
- expandBlob(pMem);
+ ExpandBlob(pMem);
f = pMem->flags;
if( (f&(MEM_Str|MEM_Blob)) && pMem->z!=pMem->zMalloc ){
if( sqlite3VdbeMemGrow(pMem, pMem->n + 2, 1) ){
@@ -56691,24 +57844,19 @@ SQLITE_PRIVATE int sqlite3VdbeMemFinalize(Mem *pMem, FuncDef *pFunc){
*/
SQLITE_PRIVATE void sqlite3VdbeMemReleaseExternal(Mem *p){
assert( p->db==0 || sqlite3_mutex_held(p->db->mutex) );
- testcase( p->flags & MEM_Agg );
- testcase( p->flags & MEM_Dyn );
- testcase( p->flags & MEM_RowSet );
- testcase( p->flags & MEM_Frame );
- if( p->flags&(MEM_Agg|MEM_Dyn|MEM_RowSet|MEM_Frame) ){
- if( p->flags&MEM_Agg ){
- sqlite3VdbeMemFinalize(p, p->u.pDef);
- assert( (p->flags & MEM_Agg)==0 );
- sqlite3VdbeMemRelease(p);
- }else if( p->flags&MEM_Dyn && p->xDel ){
- assert( (p->flags&MEM_RowSet)==0 );
- p->xDel((void *)p->z);
- p->xDel = 0;
- }else if( p->flags&MEM_RowSet ){
- sqlite3RowSetClear(p->u.pRowSet);
- }else if( p->flags&MEM_Frame ){
- sqlite3VdbeMemSetNull(p);
- }
+ if( p->flags&MEM_Agg ){
+ sqlite3VdbeMemFinalize(p, p->u.pDef);
+ assert( (p->flags & MEM_Agg)==0 );
+ sqlite3VdbeMemRelease(p);
+ }else if( p->flags&MEM_Dyn && p->xDel ){
+ assert( (p->flags&MEM_RowSet)==0 );
+ assert( p->xDel!=SQLITE_DYNAMIC );
+ p->xDel((void *)p->z);
+ p->xDel = 0;
+ }else if( p->flags&MEM_RowSet ){
+ sqlite3RowSetClear(p->u.pRowSet);
+ }else if( p->flags&MEM_Frame ){
+ sqlite3VdbeMemSetNull(p);
}
}
@@ -56718,7 +57866,7 @@ SQLITE_PRIVATE void sqlite3VdbeMemReleaseExternal(Mem *p){
** (Mem.type==SQLITE_TEXT).
*/
SQLITE_PRIVATE void sqlite3VdbeMemRelease(Mem *p){
- sqlite3VdbeMemReleaseExternal(p);
+ VdbeMemRelease(p);
sqlite3DbFree(p->db, p->zMalloc);
p->z = 0;
p->zMalloc = 0;
@@ -56845,8 +57993,14 @@ SQLITE_PRIVATE void sqlite3VdbeIntegerAffinity(Mem *pMem){
** true and could be omitted. But we leave it in because other
** architectures might behave differently.
*/
- if( pMem->r==(double)pMem->u.i && pMem->u.i>SMALLEST_INT64
- && ALWAYS(pMem->u.i<LARGEST_INT64) ){
+ if( pMem->r==(double)pMem->u.i
+ && pMem->u.i>SMALLEST_INT64
+#if defined(__i486__) || defined(__x86_64__)
+ && ALWAYS(pMem->u.i<LARGEST_INT64)
+#else
+ && pMem->u.i<LARGEST_INT64
+#endif
+ ){
pMem->flags |= MEM_Int;
}
}
@@ -57014,7 +58168,7 @@ SQLITE_PRIVATE int sqlite3VdbeMemTooBig(Mem *p){
** This is used for testing and debugging only - to make sure shallow
** copies are not misused.
*/
-SQLITE_PRIVATE void sqlite3VdbeMemPrepareToChange(Vdbe *pVdbe, Mem *pMem){
+SQLITE_PRIVATE void sqlite3VdbeMemAboutToChange(Vdbe *pVdbe, Mem *pMem){
int i;
Mem *pX;
for(i=1, pX=&pVdbe->aMem[1]; i<=pVdbe->nMem; i++, pX++){
@@ -57040,7 +58194,7 @@ SQLITE_PRIVATE void sqlite3VdbeMemPrepareToChange(Vdbe *pVdbe, Mem *pMem){
*/
SQLITE_PRIVATE void sqlite3VdbeMemShallowCopy(Mem *pTo, const Mem *pFrom, int srcType){
assert( (pFrom->flags & MEM_RowSet)==0 );
- sqlite3VdbeMemReleaseExternal(pTo);
+ VdbeMemRelease(pTo);
memcpy(pTo, pFrom, MEMCELLSIZE);
pTo->xDel = 0;
if( (pFrom->flags&MEM_Static)==0 ){
@@ -57058,7 +58212,7 @@ SQLITE_PRIVATE int sqlite3VdbeMemCopy(Mem *pTo, const Mem *pFrom){
int rc = SQLITE_OK;
assert( (pFrom->flags & MEM_RowSet)==0 );
- sqlite3VdbeMemReleaseExternal(pTo);
+ VdbeMemRelease(pTo);
memcpy(pTo, pFrom, MEMCELLSIZE);
pTo->flags &= ~MEM_Dyn;
@@ -57386,7 +58540,7 @@ SQLITE_PRIVATE const void *sqlite3ValueText(sqlite3_value* pVal, u8 enc){
}
assert( (MEM_Blob>>3) == MEM_Str );
pVal->flags |= (pVal->flags & MEM_Blob)>>3;
- expandBlob(pVal);
+ ExpandBlob(pVal);
if( pVal->flags&MEM_Str ){
sqlite3VdbeChangeEncoding(pVal, enc & ~SQLITE_UTF16_ALIGNED);
if( (enc & SQLITE_UTF16_ALIGNED)!=0 && 1==(1&SQLITE_PTR_TO_INT(pVal->z)) ){
@@ -57395,7 +58549,7 @@ SQLITE_PRIVATE const void *sqlite3ValueText(sqlite3_value* pVal, u8 enc){
return 0;
}
}
- sqlite3VdbeMemNulTerminate(pVal); /* IMP: R-59893-45467 */
+ sqlite3VdbeMemNulTerminate(pVal); /* IMP: R-31275-44060 */
}else{
assert( (pVal->flags&MEM_Blob)==0 );
sqlite3VdbeMemStringify(pVal, enc);
@@ -57452,11 +58606,11 @@ SQLITE_PRIVATE int sqlite3ValueFromExpr(
}
op = pExpr->op;
- /* op can only be TK_REGISTER if we have compiled with SQLITE_ENABLE_STAT2.
+ /* op can only be TK_REGISTER if we have compiled with SQLITE_ENABLE_STAT3.
** The ifdef here is to enable us to achieve 100% branch test coverage even
- ** when SQLITE_ENABLE_STAT2 is omitted.
+ ** when SQLITE_ENABLE_STAT3 is omitted.
*/
-#ifdef SQLITE_ENABLE_STAT2
+#ifdef SQLITE_ENABLE_STAT3
if( op==TK_REGISTER ) op = pExpr->op2;
#else
if( NEVER(op==TK_REGISTER) ) op = pExpr->op2;
@@ -57597,18 +58751,6 @@ SQLITE_PRIVATE int sqlite3ValueBytes(sqlite3_value *pVal, u8 enc){
** But that file was getting too big so this subroutines were split out.
*/
-
-
-/*
-** When debugging the code generator in a symbolic debugger, one can
-** set the sqlite3VdbeAddopTrace to 1 and all opcodes will be printed
-** as they are added to the instruction stream.
-*/
-#ifdef SQLITE_DEBUG
-SQLITE_PRIVATE int sqlite3VdbeAddopTrace = 0;
-#endif
-
-
/*
** Create a new virtual database engine.
*/
@@ -57633,7 +58775,7 @@ SQLITE_PRIVATE Vdbe *sqlite3VdbeCreate(sqlite3 *db){
SQLITE_PRIVATE void sqlite3VdbeSetSql(Vdbe *p, const char *z, int n, int isPrepareV2){
assert( isPrepareV2==1 || isPrepareV2==0 );
if( p==0 ) return;
-#ifdef SQLITE_OMIT_TRACE
+#if defined(SQLITE_OMIT_TRACE) && !defined(SQLITE_ENABLE_SQLLOG)
if( !isPrepareV2 ) return;
#endif
assert( p->zSql==0 );
@@ -57738,7 +58880,9 @@ SQLITE_PRIVATE int sqlite3VdbeAddOp3(Vdbe *p, int op, int p1, int p2, int p3){
pOp->p4type = P4_NOTUSED;
#ifdef SQLITE_DEBUG
pOp->zComment = 0;
- if( sqlite3VdbeAddopTrace ) sqlite3VdbePrintOp(0, i, &p->aOp[i]);
+ if( p->db->flags & SQLITE_VdbeAddopTrace ){
+ sqlite3VdbePrintOp(0, i, &p->aOp[i]);
+ }
#endif
#ifdef VDBE_PROFILE
pOp->cycles = 0;
@@ -57776,7 +58920,8 @@ SQLITE_PRIVATE int sqlite3VdbeAddOp4(
/*
** Add an OP_ParseSchema opcode. This routine is broken out from
-** sqlite3VdbeAddOp4() since it needs to also local all btrees.
+** sqlite3VdbeAddOp4() since it needs to also needs to mark all btrees
+** as having been used.
**
** The zWhere string must have been obtained from sqlite3_malloc().
** This routine will take ownership of the allocated memory.
@@ -57819,14 +58964,11 @@ SQLITE_PRIVATE int sqlite3VdbeAddOp4Int(
** Zero is returned if a malloc() fails.
*/
SQLITE_PRIVATE int sqlite3VdbeMakeLabel(Vdbe *p){
- int i;
- i = p->nLabel++;
+ int i = p->nLabel++;
assert( p->magic==VDBE_MAGIC_INIT );
- if( i>=p->nLabelAlloc ){
- int n = p->nLabelAlloc*2 + 5;
- p->aLabel = sqlite3DbReallocOrFree(p->db, p->aLabel,
- n*sizeof(p->aLabel[0]));
- p->nLabelAlloc = sqlite3DbMallocSize(p->db, p->aLabel)/sizeof(p->aLabel[0]);
+ if( (i & (i-1))==0 ){
+ p->aLabel = sqlite3DbReallocOrFree(p->db, p->aLabel,
+ (i*2+1)*sizeof(p->aLabel[0]));
}
if( p->aLabel ){
p->aLabel[i] = -1;
@@ -57959,7 +59101,7 @@ SQLITE_PRIVATE int sqlite3VdbeAssertMayAbort(Vdbe *v, int mayAbort){
|| (opcode==OP_FkCounter && pOp->p1==0 && pOp->p2==1)
#endif
|| ((opcode==OP_Halt || opcode==OP_HaltIfNull)
- && (pOp->p1==SQLITE_CONSTRAINT && pOp->p2==OE_Abort))
+ && ((pOp->p1&0xff)==SQLITE_CONSTRAINT && pOp->p2==OE_Abort))
){
hasAbort = 1;
break;
@@ -57967,7 +59109,7 @@ SQLITE_PRIVATE int sqlite3VdbeAssertMayAbort(Vdbe *v, int mayAbort){
}
sqlite3DbFree(v->db, sIter.apSub);
- /* Return true if hasAbort==mayAbort. Or if a malloc failure occured.
+ /* Return true if hasAbort==mayAbort. Or if a malloc failure occurred.
** If malloc failed, then the while() loop above may not have iterated
** through all opcodes and hasAbort may be set incorrectly. Return
** true for this case to prevent the assert() in the callers frame
@@ -58013,6 +59155,12 @@ static void resolveP2Values(Vdbe *p, int *pMaxFuncArgs){
n = pOp[-1].p1;
if( n>nMaxArgs ) nMaxArgs = n;
#endif
+ }else if( opcode==OP_Next || opcode==OP_SorterNext ){
+ pOp->p4.xAdvance = sqlite3BtreeNext;
+ pOp->p4type = P4_ADVANCE;
+ }else if( opcode==OP_Prev ){
+ pOp->p4.xAdvance = sqlite3BtreePrevious;
+ pOp->p4type = P4_ADVANCE;
}
if( (pOp->opflags & OPFLG_JUMP)!=0 && pOp->p2<0 ){
@@ -58088,7 +59236,7 @@ SQLITE_PRIVATE int sqlite3VdbeAddOpList(Vdbe *p, int nOp, VdbeOpList const *aOp)
pOut->p5 = 0;
#ifdef SQLITE_DEBUG
pOut->zComment = 0;
- if( sqlite3VdbeAddopTrace ){
+ if( p->db->flags & SQLITE_VdbeAddopTrace ){
sqlite3VdbePrintOp(0, i+addr, &p->aOp[i+addr]);
}
#endif
@@ -58104,10 +59252,9 @@ SQLITE_PRIVATE int sqlite3VdbeAddOpList(Vdbe *p, int nOp, VdbeOpList const *aOp)
** static array using sqlite3VdbeAddOpList but we want to make a
** few minor changes to the program.
*/
-SQLITE_PRIVATE void sqlite3VdbeChangeP1(Vdbe *p, int addr, int val){
+SQLITE_PRIVATE void sqlite3VdbeChangeP1(Vdbe *p, u32 addr, int val){
assert( p!=0 );
- assert( addr>=0 );
- if( p->nOp>addr ){
+ if( ((u32)p->nOp)>addr ){
p->aOp[addr].p1 = val;
}
}
@@ -58116,10 +59263,9 @@ SQLITE_PRIVATE void sqlite3VdbeChangeP1(Vdbe *p, int addr, int val){
** Change the value of the P2 operand for a specific instruction.
** This routine is useful for setting a jump destination.
*/
-SQLITE_PRIVATE void sqlite3VdbeChangeP2(Vdbe *p, int addr, int val){
+SQLITE_PRIVATE void sqlite3VdbeChangeP2(Vdbe *p, u32 addr, int val){
assert( p!=0 );
- assert( addr>=0 );
- if( p->nOp>addr ){
+ if( ((u32)p->nOp)>addr ){
p->aOp[addr].p2 = val;
}
}
@@ -58127,10 +59273,9 @@ SQLITE_PRIVATE void sqlite3VdbeChangeP2(Vdbe *p, int addr, int val){
/*
** Change the value of the P3 operand for a specific instruction.
*/
-SQLITE_PRIVATE void sqlite3VdbeChangeP3(Vdbe *p, int addr, int val){
+SQLITE_PRIVATE void sqlite3VdbeChangeP3(Vdbe *p, u32 addr, int val){
assert( p!=0 );
- assert( addr>=0 );
- if( p->nOp>addr ){
+ if( ((u32)p->nOp)>addr ){
p->aOp[addr].p3 = val;
}
}
@@ -58152,8 +59297,8 @@ SQLITE_PRIVATE void sqlite3VdbeChangeP5(Vdbe *p, u8 val){
** the address of the next instruction to be coded.
*/
SQLITE_PRIVATE void sqlite3VdbeJumpHere(Vdbe *p, int addr){
- assert( addr>=0 );
- sqlite3VdbeChangeP2(p, addr, p->nOp);
+ assert( addr>=0 || p->db->mallocFailed );
+ if( addr>=0 ) sqlite3VdbeChangeP2(p, addr, p->nOp);
}
@@ -58247,18 +59392,15 @@ SQLITE_PRIVATE void sqlite3VdbeLinkSubProgram(Vdbe *pVdbe, SubProgram *p){
}
/*
-** Change N opcodes starting at addr to No-ops.
+** Change the opcode at addr into OP_Noop
*/
-SQLITE_PRIVATE void sqlite3VdbeChangeToNoop(Vdbe *p, int addr, int N){
+SQLITE_PRIVATE void sqlite3VdbeChangeToNoop(Vdbe *p, int addr){
if( p->aOp ){
VdbeOp *pOp = &p->aOp[addr];
sqlite3 *db = p->db;
- while( N-- ){
- freeP4(db, pOp->p4type, pOp->p4.p);
- memset(pOp, 0, sizeof(pOp[0]));
- pOp->opcode = OP_Noop;
- pOp++;
- }
+ freeP4(db, pOp->p4type, pOp->p4.p);
+ memset(pOp, 0, sizeof(pOp[0]));
+ pOp->opcode = OP_Noop;
}
}
@@ -58305,6 +59447,7 @@ SQLITE_PRIVATE void sqlite3VdbeChangeP4(Vdbe *p, int addr, const char *zP4, int
addr = p->nOp - 1;
}
pOp = &p->aOp[addr];
+ assert( pOp->p4type==P4_NOTUSED || pOp->p4type==P4_INT32 );
freeP4(db, pOp->p4type, pOp->p4.p);
pOp->p4.p = 0;
if( n==P4_INT32 ){
@@ -58327,10 +59470,9 @@ SQLITE_PRIVATE void sqlite3VdbeChangeP4(Vdbe *p, int addr, const char *zP4, int
u8 *aSortOrder;
memcpy((char*)pKeyInfo, zP4, nByte - nField);
aSortOrder = pKeyInfo->aSortOrder;
- if( aSortOrder ){
- pKeyInfo->aSortOrder = (unsigned char*)&pKeyInfo->aColl[nField];
- memcpy(pKeyInfo->aSortOrder, aSortOrder, nField);
- }
+ assert( aSortOrder!=0 );
+ pKeyInfo->aSortOrder = (unsigned char*)&pKeyInfo->aColl[nField];
+ memcpy(pKeyInfo->aSortOrder, aSortOrder, nField);
pOp->p4type = P4_KEYINFO;
}else{
p->db->mallocFailed = 1;
@@ -58356,35 +59498,34 @@ SQLITE_PRIVATE void sqlite3VdbeChangeP4(Vdbe *p, int addr, const char *zP4, int
#ifndef NDEBUG
/*
-** Change the comment on the the most recently coded instruction. Or
+** Change the comment on the most recently coded instruction. Or
** insert a No-op and add the comment to that new instruction. This
** makes the code easier to read during debugging. None of this happens
** in a production build.
*/
-SQLITE_PRIVATE void sqlite3VdbeComment(Vdbe *p, const char *zFormat, ...){
- va_list ap;
- if( !p ) return;
+static void vdbeVComment(Vdbe *p, const char *zFormat, va_list ap){
assert( p->nOp>0 || p->aOp==0 );
assert( p->aOp==0 || p->aOp[p->nOp-1].zComment==0 || p->db->mallocFailed );
if( p->nOp ){
- char **pz = &p->aOp[p->nOp-1].zComment;
+ assert( p->aOp );
+ sqlite3DbFree(p->db, p->aOp[p->nOp-1].zComment);
+ p->aOp[p->nOp-1].zComment = sqlite3VMPrintf(p->db, zFormat, ap);
+ }
+}
+SQLITE_PRIVATE void sqlite3VdbeComment(Vdbe *p, const char *zFormat, ...){
+ va_list ap;
+ if( p ){
va_start(ap, zFormat);
- sqlite3DbFree(p->db, *pz);
- *pz = sqlite3VMPrintf(p->db, zFormat, ap);
+ vdbeVComment(p, zFormat, ap);
va_end(ap);
}
}
SQLITE_PRIVATE void sqlite3VdbeNoopComment(Vdbe *p, const char *zFormat, ...){
va_list ap;
- if( !p ) return;
- sqlite3VdbeAddOp0(p, OP_Noop);
- assert( p->nOp>0 || p->aOp==0 );
- assert( p->aOp==0 || p->aOp[p->nOp-1].zComment==0 || p->db->mallocFailed );
- if( p->nOp ){
- char **pz = &p->aOp[p->nOp-1].zComment;
+ if( p ){
+ sqlite3VdbeAddOp0(p, OP_Noop);
va_start(ap, zFormat);
- sqlite3DbFree(p->db, *pz);
- *pz = sqlite3VMPrintf(p->db, zFormat, ap);
+ vdbeVComment(p, zFormat, ap);
va_end(ap);
}
}
@@ -58414,7 +59555,7 @@ SQLITE_PRIVATE void sqlite3VdbeNoopComment(Vdbe *p, const char *zFormat, ...){
SQLITE_PRIVATE VdbeOp *sqlite3VdbeGetOp(Vdbe *p, int addr){
/* C89 specifies that the constant "dummy" will be initialized to all
** zeros, which is correct. MSVC generates a warning, nevertheless. */
- static const VdbeOp dummy; /* Ignore the MSVC warning about no initializer */
+ static VdbeOp dummy; /* Ignore the MSVC warning about no initializer */
assert( p->magic==VDBE_MAGIC_INIT );
if( addr<0 ){
#ifdef SQLITE_OMIT_TRACE
@@ -58444,26 +59585,23 @@ static char *displayP4(Op *pOp, char *zTemp, int nTemp){
case P4_KEYINFO: {
int i, j;
KeyInfo *pKeyInfo = pOp->p4.pKeyInfo;
+ assert( pKeyInfo->aSortOrder!=0 );
sqlite3_snprintf(nTemp, zTemp, "keyinfo(%d", pKeyInfo->nField);
i = sqlite3Strlen30(zTemp);
for(j=0; j<pKeyInfo->nField; j++){
CollSeq *pColl = pKeyInfo->aColl[j];
- if( pColl ){
- int n = sqlite3Strlen30(pColl->zName);
- if( i+n>nTemp-6 ){
- memcpy(&zTemp[i],",...",4);
- break;
- }
- zTemp[i++] = ',';
- if( pKeyInfo->aSortOrder && pKeyInfo->aSortOrder[j] ){
- zTemp[i++] = '-';
- }
- memcpy(&zTemp[i], pColl->zName,n+1);
- i += n;
- }else if( i+4<nTemp-6 ){
- memcpy(&zTemp[i],",nil",4);
- i += 4;
+ const char *zColl = pColl ? pColl->zName : "nil";
+ int n = sqlite3Strlen30(zColl);
+ if( i+n>nTemp-6 ){
+ memcpy(&zTemp[i],",...",4);
+ break;
}
+ zTemp[i++] = ',';
+ if( pKeyInfo->aSortOrder[j] ){
+ zTemp[i++] = '-';
+ }
+ memcpy(&zTemp[i], zColl, n+1);
+ i += n;
}
zTemp[i++] = ')';
zTemp[i] = 0;
@@ -58494,13 +59632,14 @@ static char *displayP4(Op *pOp, char *zTemp, int nTemp){
}
case P4_MEM: {
Mem *pMem = pOp->p4.pMem;
- assert( (pMem->flags & MEM_Null)==0 );
if( pMem->flags & MEM_Str ){
zP4 = pMem->z;
}else if( pMem->flags & MEM_Int ){
sqlite3_snprintf(nTemp, zTemp, "%lld", pMem->u.i);
}else if( pMem->flags & MEM_Real ){
sqlite3_snprintf(nTemp, zTemp, "%.16g", pMem->r);
+ }else if( pMem->flags & MEM_Null ){
+ sqlite3_snprintf(nTemp, zTemp, "NULL");
}else{
assert( pMem->flags & MEM_Blob );
zP4 = "(blob)";
@@ -58522,6 +59661,10 @@ static char *displayP4(Op *pOp, char *zTemp, int nTemp){
sqlite3_snprintf(nTemp, zTemp, "program");
break;
}
+ case P4_ADVANCE: {
+ zTemp[0] = 0;
+ break;
+ }
default: {
zP4 = pOp->p4.z;
if( zP4==0 ){
@@ -58539,8 +59682,9 @@ static char *displayP4(Op *pOp, char *zTemp, int nTemp){
** Declare to the Vdbe that the BTree object at db->aDb[i] is used.
**
** The prepared statements need to know in advance the complete set of
-** attached databases that they will be using. A mask of these databases
-** is maintained in p->btreeMask and is used for locking and other purposes.
+** attached databases that will be use. A mask of these databases
+** is maintained in p->btreeMask. The p->lockMask value is the subset of
+** p->btreeMask of databases that will require a lock.
*/
SQLITE_PRIVATE void sqlite3VdbeUsesBtree(Vdbe *p, int i){
assert( i>=0 && i<p->db->nDb && i<(int)sizeof(yDbMask)*8 );
@@ -58671,7 +59815,7 @@ static void releaseMemArray(Mem *p, int N){
p->zMalloc = 0;
}
- p->flags = MEM_Null;
+ p->flags = MEM_Invalid;
}
db->mallocFailed = malloc_failed;
}
@@ -58718,7 +59862,7 @@ SQLITE_PRIVATE int sqlite3VdbeList(
sqlite3 *db = p->db; /* The database connection */
int i; /* Loop counter */
int rc = SQLITE_OK; /* Return code */
- Mem *pMem = p->pResultSet = &p->aMem[1]; /* First Mem of result set */
+ Mem *pMem = &p->aMem[1]; /* First Mem of result set */
assert( p->explain );
assert( p->magic==VDBE_MAGIC_RUN );
@@ -58729,6 +59873,7 @@ SQLITE_PRIVATE int sqlite3VdbeList(
** sqlite3_column_text16(), causing a translation to UTF-16 encoding.
*/
releaseMemArray(pMem, 8);
+ p->pResultSet = 0;
if( p->rc==SQLITE_NOMEM ){
/* This happens if a malloc() inside a call to sqlite3_column_text() or
@@ -58815,7 +59960,7 @@ SQLITE_PRIVATE int sqlite3VdbeList(
for(j=0; j<nSub; j++){
if( apSub[j]==pOp->p4.pProgram ) break;
}
- if( j==nSub && SQLITE_OK==sqlite3VdbeMemGrow(pSub, nByte, 1) ){
+ if( j==nSub && SQLITE_OK==sqlite3VdbeMemGrow(pSub, nByte, nSub!=0) ){
apSub = (SubProgram **)pSub->z;
apSub[nSub++] = pOp->p4.pProgram;
pSub->flags |= MEM_Blob;
@@ -58883,6 +60028,7 @@ SQLITE_PRIVATE int sqlite3VdbeList(
}
p->nResColumn = 8 - 4*(p->explain-1);
+ p->pResultSet = &p->aMem[1];
p->rc = SQLITE_OK;
rc = SQLITE_ROW;
}
@@ -59044,6 +60190,7 @@ SQLITE_PRIVATE void sqlite3VdbeMakeReady(
int nMem; /* Number of VM memory registers */
int nCursor; /* Number of cursors required */
int nArg; /* Number of arguments in subprograms */
+ int nOnce; /* Number of OP_Once instructions */
int n; /* Loop counter */
u8 *zCsr; /* Memory available for allocation */
u8 *zEnd; /* First byte past allocated memory */
@@ -59059,6 +60206,8 @@ SQLITE_PRIVATE void sqlite3VdbeMakeReady(
nMem = pParse->nMem;
nCursor = pParse->nTab;
nArg = pParse->nMaxArg;
+ nOnce = pParse->nOnce;
+ if( nOnce==0 ) nOnce = 1; /* Ensure at least one byte in p->aOnceFlag[] */
/* For each cursor required, also allocate a memory cell. Memory
** cells (nMem+1-nCursor)..nMem, inclusive, will never be used by
@@ -59105,6 +60254,7 @@ SQLITE_PRIVATE void sqlite3VdbeMakeReady(
p->azVar = allocSpace(p->azVar, nVar*sizeof(char*), &zCsr, zEnd, &nByte);
p->apCsr = allocSpace(p->apCsr, nCursor*sizeof(VdbeCursor*),
&zCsr, zEnd, &nByte);
+ p->aOnceFlag = allocSpace(p->aOnceFlag, nOnce, &zCsr, zEnd, &nByte);
if( nByte ){
p->pFree = sqlite3DbMallocZero(db, nByte);
}
@@ -59112,7 +60262,8 @@ SQLITE_PRIVATE void sqlite3VdbeMakeReady(
zEnd = &zCsr[nByte];
}while( nByte && !db->mallocFailed );
- p->nCursor = (u16)nCursor;
+ p->nCursor = nCursor;
+ p->nOnceFlag = nOnce;
if( p->aVar ){
p->nVar = (ynVar)nVar;
for(n=0; n<nVar; n++){
@@ -59129,7 +60280,7 @@ SQLITE_PRIVATE void sqlite3VdbeMakeReady(
p->aMem--; /* aMem[] goes from 1..nMem */
p->nMem = nMem; /* not from 0..nMem-1 */
for(n=1; n<=nMem; n++){
- p->aMem[n].flags = MEM_Null;
+ p->aMem[n].flags = MEM_Invalid;
p->aMem[n].db = db;
}
}
@@ -59145,6 +60296,7 @@ SQLITE_PRIVATE void sqlite3VdbeFreeCursor(Vdbe *p, VdbeCursor *pCx){
if( pCx==0 ){
return;
}
+ sqlite3VdbeSorterClose(p->db, pCx);
if( pCx->pBt ){
sqlite3BtreeClose(pCx->pBt);
/* The pCx->pCursor will be close automatically, if it exists, by
@@ -59170,6 +60322,8 @@ SQLITE_PRIVATE void sqlite3VdbeFreeCursor(Vdbe *p, VdbeCursor *pCx){
*/
SQLITE_PRIVATE int sqlite3VdbeFrameRestore(VdbeFrame *pFrame){
Vdbe *v = pFrame->v;
+ v->aOnceFlag = pFrame->aOnceFlag;
+ v->nOnceFlag = pFrame->nOnceFlag;
v->aOp = pFrame->aOp;
v->nOp = pFrame->nOp;
v->aMem = pFrame->aMem;
@@ -59232,8 +60386,10 @@ static void Cleanup(Vdbe *p){
/* Execute assert() statements to ensure that the Vdbe.apCsr[] and
** Vdbe.aMem[] arrays have already been cleaned up. */
int i;
- for(i=0; i<p->nCursor; i++) assert( p->apCsr==0 || p->apCsr[i]==0 );
- for(i=1; i<=p->nMem; i++) assert( p->aMem==0 || p->aMem[i].flags==MEM_Null );
+ if( p->apCsr ) for(i=0; i<p->nCursor; i++) assert( p->apCsr[i]==0 );
+ if( p->aMem ){
+ for(i=1; i<=p->nMem; i++) assert( p->aMem[i].flags==MEM_Invalid );
+ }
#endif
sqlite3DbFree(db, p->zErrMsg);
@@ -59335,7 +60491,9 @@ static int vdbeCommit(sqlite3 *db, Vdbe *p){
if( sqlite3BtreeIsInTrans(pBt) ){
needXcommit = 1;
if( i!=1 ) nTrans++;
+ sqlite3BtreeEnter(pBt);
rc = sqlite3PagerExclusiveLock(sqlite3BtreePager(pBt));
+ sqlite3BtreeLeave(pBt);
}
}
if( rc!=SQLITE_OK ){
@@ -59346,7 +60504,7 @@ static int vdbeCommit(sqlite3 *db, Vdbe *p){
if( needXcommit && db->xCommitCallback ){
rc = db->xCommitCallback(db->pCommitArg);
if( rc ){
- return SQLITE_CONSTRAINT;
+ return SQLITE_CONSTRAINT_COMMITHOOK;
}
}
@@ -59398,16 +60556,31 @@ static int vdbeCommit(sqlite3 *db, Vdbe *p){
sqlite3_file *pMaster = 0;
i64 offset = 0;
int res;
+ int retryCount = 0;
+ int nMainFile;
/* Select a master journal file name */
+ nMainFile = sqlite3Strlen30(zMainFile);
+ zMaster = sqlite3MPrintf(db, "%s-mjXXXXXX9XXz", zMainFile);
+ if( zMaster==0 ) return SQLITE_NOMEM;
do {
u32 iRandom;
- sqlite3DbFree(db, zMaster);
- sqlite3_randomness(sizeof(iRandom), &iRandom);
- zMaster = sqlite3MPrintf(db, "%s-mj%08X", zMainFile, iRandom&0x7fffffff);
- if( !zMaster ){
- return SQLITE_NOMEM;
+ if( retryCount ){
+ if( retryCount>100 ){
+ sqlite3_log(SQLITE_FULL, "MJ delete: %s", zMaster);
+ sqlite3OsDelete(pVfs, zMaster, 0);
+ break;
+ }else if( retryCount==1 ){
+ sqlite3_log(SQLITE_FULL, "MJ collide: %s", zMaster);
+ }
}
+ retryCount++;
+ sqlite3_randomness(sizeof(iRandom), &iRandom);
+ sqlite3_snprintf(13, &zMaster[nMainFile], "-mj%06X9%02X",
+ (iRandom>>8)&0xffffff, iRandom&0xff);
+ /* The antipenultimate character of the master journal name must
+ ** be "9" to avoid name collisions when using 8+3 filenames. */
+ assert( zMaster[sqlite3Strlen30(zMaster)-3]=='9' );
sqlite3FileSuffix3(zMainFile, zMaster);
rc = sqlite3OsAccess(pVfs, zMaster, SQLITE_ACCESS_EXISTS, &res);
}while( rc==SQLITE_OK && res );
@@ -59553,32 +60726,6 @@ static void checkActiveVdbeCnt(sqlite3 *db){
#endif
/*
-** For every Btree that in database connection db which
-** has been modified, "trip" or invalidate each cursor in
-** that Btree might have been modified so that the cursor
-** can never be used again. This happens when a rollback
-*** occurs. We have to trip all the other cursors, even
-** cursor from other VMs in different database connections,
-** so that none of them try to use the data at which they
-** were pointing and which now may have been changed due
-** to the rollback.
-**
-** Remember that a rollback can delete tables complete and
-** reorder rootpages. So it is not sufficient just to save
-** the state of the cursor. We have to invalidate the cursor
-** so that it is never used again.
-*/
-static void invalidateCursorsOnModifiedBtrees(sqlite3 *db){
- int i;
- for(i=0; i<db->nDb; i++){
- Btree *p = db->aDb[i].pBt;
- if( p && sqlite3BtreeIsInTrans(p) ){
- sqlite3BtreeTripAllCursors(p, SQLITE_ABORT);
- }
- }
-}
-
-/*
** If the Vdbe passed as the first argument opened a statement-transaction,
** close it now. Argument eOp must be either SAVEPOINT_ROLLBACK or
** SAVEPOINT_RELEASE. If it is SAVEPOINT_ROLLBACK, then the statement
@@ -59594,7 +60741,7 @@ SQLITE_PRIVATE int sqlite3VdbeCloseStatement(Vdbe *p, int eOp){
/* If p->iStatement is greater than zero, then this Vdbe opened a
** statement transaction that should be closed here. The only exception
- ** is that an IO error may have occured, causing an emergency rollback.
+ ** is that an IO error may have occurred, causing an emergency rollback.
** In this case (db->nStatement==0), and there is nothing to do.
*/
if( db->nStatement && p->iStatement ){
@@ -59649,14 +60796,14 @@ SQLITE_PRIVATE int sqlite3VdbeCloseStatement(Vdbe *p, int eOp){
** violations, return SQLITE_ERROR. Otherwise, SQLITE_OK.
**
** If there are outstanding FK violations and this function returns
-** SQLITE_ERROR, set the result of the VM to SQLITE_CONSTRAINT and write
-** an error message to it. Then return SQLITE_ERROR.
+** SQLITE_ERROR, set the result of the VM to SQLITE_CONSTRAINT_FOREIGNKEY
+** and write an error message to it. Then return SQLITE_ERROR.
*/
#ifndef SQLITE_OMIT_FOREIGN_KEY
SQLITE_PRIVATE int sqlite3VdbeCheckFk(Vdbe *p, int deferred){
sqlite3 *db = p->db;
if( (deferred && db->nDeferredCons>0) || (!deferred && p->nFkConstraint>0) ){
- p->rc = SQLITE_CONSTRAINT;
+ p->rc = SQLITE_CONSTRAINT_FOREIGNKEY;
p->errorAction = OE_Abort;
sqlite3SetString(&p->zErrMsg, db, "foreign key constraint failed");
return SQLITE_ERROR;
@@ -59701,6 +60848,7 @@ SQLITE_PRIVATE int sqlite3VdbeHalt(Vdbe *p){
if( p->db->mallocFailed ){
p->rc = SQLITE_NOMEM;
}
+ if( p->aOnceFlag ) memset(p->aOnceFlag, 0, p->nOnceFlag);
closeAllCursors(p);
if( p->magic!=VDBE_MAGIC_RUN ){
return SQLITE_OK;
@@ -59729,7 +60877,7 @@ SQLITE_PRIVATE int sqlite3VdbeHalt(Vdbe *p){
**
** Even if the statement is read-only, it is important to perform
** a statement or transaction rollback operation. If the error
- ** occured while writing to the journal, sub-journal or database
+ ** occurred while writing to the journal, sub-journal or database
** file as part of an effort to free up cache space (see function
** pagerStress() in pager.c), the rollback is required to restore
** the pager to a consistent state.
@@ -59741,8 +60889,7 @@ SQLITE_PRIVATE int sqlite3VdbeHalt(Vdbe *p){
/* We are forced to roll back the active transaction. Before doing
** so, abort any other statements this handle currently has active.
*/
- invalidateCursorsOnModifiedBtrees(db);
- sqlite3RollbackAll(db);
+ sqlite3RollbackAll(db, SQLITE_ABORT_ROLLBACK);
sqlite3CloseSavepoints(db);
db->autoCommit = 1;
}
@@ -59771,7 +60918,7 @@ SQLITE_PRIVATE int sqlite3VdbeHalt(Vdbe *p){
sqlite3VdbeLeave(p);
return SQLITE_ERROR;
}
- rc = SQLITE_CONSTRAINT;
+ rc = SQLITE_CONSTRAINT_FOREIGNKEY;
}else{
/* The auto-commit flag is true, the vdbe program was successful
** or hit an 'OR FAIL' constraint and there are no deferred foreign
@@ -59784,13 +60931,13 @@ SQLITE_PRIVATE int sqlite3VdbeHalt(Vdbe *p){
return SQLITE_BUSY;
}else if( rc!=SQLITE_OK ){
p->rc = rc;
- sqlite3RollbackAll(db);
+ sqlite3RollbackAll(db, SQLITE_OK);
}else{
db->nDeferredCons = 0;
sqlite3CommitInternalChanges(db);
}
}else{
- sqlite3RollbackAll(db);
+ sqlite3RollbackAll(db, SQLITE_OK);
}
db->nStatement = 0;
}else if( eStatementOp==0 ){
@@ -59799,8 +60946,7 @@ SQLITE_PRIVATE int sqlite3VdbeHalt(Vdbe *p){
}else if( p->errorAction==OE_Abort ){
eStatementOp = SAVEPOINT_ROLLBACK;
}else{
- invalidateCursorsOnModifiedBtrees(db);
- sqlite3RollbackAll(db);
+ sqlite3RollbackAll(db, SQLITE_ABORT_ROLLBACK);
sqlite3CloseSavepoints(db);
db->autoCommit = 1;
}
@@ -59815,13 +60961,12 @@ SQLITE_PRIVATE int sqlite3VdbeHalt(Vdbe *p){
if( eStatementOp ){
rc = sqlite3VdbeCloseStatement(p, eStatementOp);
if( rc ){
- if( p->rc==SQLITE_OK || p->rc==SQLITE_CONSTRAINT ){
+ if( p->rc==SQLITE_OK || (p->rc&0xff)==SQLITE_CONSTRAINT ){
p->rc = rc;
sqlite3DbFree(db, p->zErrMsg);
p->zErrMsg = 0;
}
- invalidateCursorsOnModifiedBtrees(db);
- sqlite3RollbackAll(db);
+ sqlite3RollbackAll(db, SQLITE_ABORT_ROLLBACK);
sqlite3CloseSavepoints(db);
db->autoCommit = 1;
}
@@ -59838,12 +60983,6 @@ SQLITE_PRIVATE int sqlite3VdbeHalt(Vdbe *p){
}
p->nChange = 0;
}
-
- /* Rollback or commit any schema changes that occurred. */
- if( p->rc!=SQLITE_OK && db->flags&SQLITE_InternChanges ){
- sqlite3ResetInternalSchema(db, -1);
- db->flags = (db->flags | SQLITE_InternChanges);
- }
/* Release the locks */
sqlite3VdbeLeave(p);
@@ -59885,6 +61024,51 @@ SQLITE_PRIVATE void sqlite3VdbeResetStepResult(Vdbe *p){
}
/*
+** Copy the error code and error message belonging to the VDBE passed
+** as the first argument to its database handle (so that they will be
+** returned by calls to sqlite3_errcode() and sqlite3_errmsg()).
+**
+** This function does not clear the VDBE error code or message, just
+** copies them to the database handle.
+*/
+SQLITE_PRIVATE int sqlite3VdbeTransferError(Vdbe *p){
+ sqlite3 *db = p->db;
+ int rc = p->rc;
+ if( p->zErrMsg ){
+ u8 mallocFailed = db->mallocFailed;
+ sqlite3BeginBenignMalloc();
+ sqlite3ValueSetStr(db->pErr, -1, p->zErrMsg, SQLITE_UTF8, SQLITE_TRANSIENT);
+ sqlite3EndBenignMalloc();
+ db->mallocFailed = mallocFailed;
+ db->errCode = rc;
+ }else{
+ sqlite3Error(db, rc, 0);
+ }
+ return rc;
+}
+
+#ifdef SQLITE_ENABLE_SQLLOG
+/*
+** If an SQLITE_CONFIG_SQLLOG hook is registered and the VM has been run,
+** invoke it.
+*/
+static void vdbeInvokeSqllog(Vdbe *v){
+ if( sqlite3GlobalConfig.xSqllog && v->rc==SQLITE_OK && v->zSql && v->pc>=0 ){
+ char *zExpanded = sqlite3VdbeExpandSql(v, v->zSql);
+ assert( v->db->init.busy==0 );
+ if( zExpanded ){
+ sqlite3GlobalConfig.xSqllog(
+ sqlite3GlobalConfig.pSqllogArg, v->db, zExpanded, 1
+ );
+ sqlite3DbFree(v->db, zExpanded);
+ }
+ }
+}
+#else
+# define vdbeInvokeSqllog(x)
+#endif
+
+/*
** Clean up a VDBE after execution but do not delete the VDBE just yet.
** Write any error messages into *pzErrMsg. Return the result code.
**
@@ -59911,18 +61095,10 @@ SQLITE_PRIVATE int sqlite3VdbeReset(Vdbe *p){
** instructions yet, leave the main database error information unchanged.
*/
if( p->pc>=0 ){
- if( p->zErrMsg ){
- sqlite3BeginBenignMalloc();
- sqlite3ValueSetStr(db->pErr,-1,p->zErrMsg,SQLITE_UTF8,SQLITE_TRANSIENT);
- sqlite3EndBenignMalloc();
- db->errCode = p->rc;
- sqlite3DbFree(db, p->zErrMsg);
- p->zErrMsg = 0;
- }else if( p->rc ){
- sqlite3Error(db, p->rc, 0);
- }else{
- sqlite3Error(db, SQLITE_OK, 0);
- }
+ vdbeInvokeSqllog(p);
+ sqlite3VdbeTransferError(p);
+ sqlite3DbFree(db, p->zErrMsg);
+ p->zErrMsg = 0;
if( p->runOnlyOnce ) p->expired = 1;
}else if( p->rc && p->expired ){
/* The expired flag was set on the VDBE before the first call
@@ -60001,12 +61177,14 @@ SQLITE_PRIVATE void sqlite3VdbeDeleteAuxData(VdbeFunc *pVdbeFunc, int mask){
}
/*
-** Free all memory associated with the Vdbe passed as the second argument.
+** Free all memory associated with the Vdbe passed as the second argument,
+** except for object itself, which is preserved.
+**
** The difference between this function and sqlite3VdbeDelete() is that
** VdbeDelete() also unlinks the Vdbe from the list of VMs associated with
-** the database connection.
+** the database connection and frees the object itself.
*/
-SQLITE_PRIVATE void sqlite3VdbeDeleteObject(sqlite3 *db, Vdbe *p){
+SQLITE_PRIVATE void sqlite3VdbeClearObject(sqlite3 *db, Vdbe *p){
SubProgram *pSub, *pNext;
int i;
assert( p->db==0 || p->db==db );
@@ -60023,7 +61201,10 @@ SQLITE_PRIVATE void sqlite3VdbeDeleteObject(sqlite3 *db, Vdbe *p){
sqlite3DbFree(db, p->aColName);
sqlite3DbFree(db, p->zSql);
sqlite3DbFree(db, p->pFree);
- sqlite3DbFree(db, p);
+#if defined(SQLITE_ENABLE_TREE_EXPLAIN)
+ sqlite3DbFree(db, p->zExplain);
+ sqlite3DbFree(db, p->pExplain);
+#endif
}
/*
@@ -60034,6 +61215,8 @@ SQLITE_PRIVATE void sqlite3VdbeDelete(Vdbe *p){
if( NEVER(p==0) ) return;
db = p->db;
+ assert( sqlite3_mutex_held(db->mutex) );
+ sqlite3VdbeClearObject(db, p);
if( p->pPrev ){
p->pPrev->pNext = p->pNext;
}else{
@@ -60045,7 +61228,7 @@ SQLITE_PRIVATE void sqlite3VdbeDelete(Vdbe *p){
}
p->magic = VDBE_MAGIC_DEAD;
p->db = 0;
- sqlite3VdbeDeleteObject(db, p);
+ sqlite3DbFree(db, p);
}
/*
@@ -60108,7 +61291,7 @@ SQLITE_PRIVATE int sqlite3VdbeCursorMoveto(VdbeCursor *p){
** the blob of data that it corresponds to. In a table record, all serial
** types are stored at the start of the record, and the blobs of data at
** the end. Hence these functions allow the caller to handle the
-** serial-type and data blob seperately.
+** serial-type and data blob separately.
**
** The following table describes the various storage classes for data:
**
@@ -60147,9 +61330,6 @@ SQLITE_PRIVATE u32 sqlite3VdbeSerialType(Mem *pMem, int file_format){
# define MAX_6BYTE ((((i64)0x00008000)<<32)-1)
i64 i = pMem->u.i;
u64 u;
- if( file_format>=4 && (i&1)==i ){
- return 8+(u32)i;
- }
if( i<0 ){
if( i<(-MAX_6BYTE) ) return 6;
/* Previous test prevents: u = -(-9223372036854775808) */
@@ -60157,7 +61337,9 @@ SQLITE_PRIVATE u32 sqlite3VdbeSerialType(Mem *pMem, int file_format){
}else{
u = i;
}
- if( u<=127 ) return 1;
+ if( u<=127 ){
+ return ((i&1)==i && file_format>=4) ? 8+(u32)u : 1;
+ }
if( u<=32767 ) return 2;
if( u<=8388607 ) return 3;
if( u<=2147483647 ) return 4;
@@ -60402,57 +61584,71 @@ SQLITE_PRIVATE u32 sqlite3VdbeSerialGet(
return 0;
}
-
/*
-** Given the nKey-byte encoding of a record in pKey[], parse the
-** record into a UnpackedRecord structure. Return a pointer to
-** that structure.
+** This routine is used to allocate sufficient space for an UnpackedRecord
+** structure large enough to be used with sqlite3VdbeRecordUnpack() if
+** the first argument is a pointer to KeyInfo structure pKeyInfo.
**
-** The calling function might provide szSpace bytes of memory
-** space at pSpace. This space can be used to hold the returned
-** VDbeParsedRecord structure if it is large enough. If it is
-** not big enough, space is obtained from sqlite3_malloc().
+** The space is either allocated using sqlite3DbMallocRaw() or from within
+** the unaligned buffer passed via the second and third arguments (presumably
+** stack space). If the former, then *ppFree is set to a pointer that should
+** be eventually freed by the caller using sqlite3DbFree(). Or, if the
+** allocation comes from the pSpace/szSpace buffer, *ppFree is set to NULL
+** before returning.
**
-** The returned structure should be closed by a call to
-** sqlite3VdbeDeleteUnpackedRecord().
-*/
-SQLITE_PRIVATE UnpackedRecord *sqlite3VdbeRecordUnpack(
- KeyInfo *pKeyInfo, /* Information about the record format */
- int nKey, /* Size of the binary record */
- const void *pKey, /* The binary record */
- char *pSpace, /* Unaligned space available to hold the object */
- int szSpace /* Size of pSpace[] in bytes */
+** If an OOM error occurs, NULL is returned.
+*/
+SQLITE_PRIVATE UnpackedRecord *sqlite3VdbeAllocUnpackedRecord(
+ KeyInfo *pKeyInfo, /* Description of the record */
+ char *pSpace, /* Unaligned space available */
+ int szSpace, /* Size of pSpace[] in bytes */
+ char **ppFree /* OUT: Caller should free this pointer */
){
- const unsigned char *aKey = (const unsigned char *)pKey;
- UnpackedRecord *p; /* The unpacked record that we will return */
- int nByte; /* Memory space needed to hold p, in bytes */
- int d;
- u32 idx;
- u16 u; /* Unsigned loop counter */
- u32 szHdr;
- Mem *pMem;
- int nOff; /* Increase pSpace by this much to 8-byte align it */
-
- /*
- ** We want to shift the pointer pSpace up such that it is 8-byte aligned.
+ UnpackedRecord *p; /* Unpacked record to return */
+ int nOff; /* Increment pSpace by nOff to align it */
+ int nByte; /* Number of bytes required for *p */
+
+ /* We want to shift the pointer pSpace up such that it is 8-byte aligned.
** Thus, we need to calculate a value, nOff, between 0 and 7, to shift
** it by. If pSpace is already 8-byte aligned, nOff should be zero.
*/
nOff = (8 - (SQLITE_PTR_TO_INT(pSpace) & 7)) & 7;
- pSpace += nOff;
- szSpace -= nOff;
nByte = ROUND8(sizeof(UnpackedRecord)) + sizeof(Mem)*(pKeyInfo->nField+1);
- if( nByte>szSpace ){
- p = sqlite3DbMallocRaw(pKeyInfo->db, nByte);
- if( p==0 ) return 0;
- p->flags = UNPACKED_NEED_FREE | UNPACKED_NEED_DESTROY;
+ if( nByte>szSpace+nOff ){
+ p = (UnpackedRecord *)sqlite3DbMallocRaw(pKeyInfo->db, nByte);
+ *ppFree = (char *)p;
+ if( !p ) return 0;
}else{
- p = (UnpackedRecord*)pSpace;
- p->flags = UNPACKED_NEED_DESTROY;
+ p = (UnpackedRecord*)&pSpace[nOff];
+ *ppFree = 0;
}
+
+ p->aMem = (Mem*)&((char*)p)[ROUND8(sizeof(UnpackedRecord))];
+ assert( pKeyInfo->aSortOrder!=0 );
p->pKeyInfo = pKeyInfo;
p->nField = pKeyInfo->nField + 1;
- p->aMem = pMem = (Mem*)&((char*)p)[ROUND8(sizeof(UnpackedRecord))];
+ return p;
+}
+
+/*
+** Given the nKey-byte encoding of a record in pKey[], populate the
+** UnpackedRecord structure indicated by the fourth argument with the
+** contents of the decoded record.
+*/
+SQLITE_PRIVATE void sqlite3VdbeRecordUnpack(
+ KeyInfo *pKeyInfo, /* Information about the record format */
+ int nKey, /* Size of the binary record */
+ const void *pKey, /* The binary record */
+ UnpackedRecord *p /* Populate this structure before returning. */
+){
+ const unsigned char *aKey = (const unsigned char *)pKey;
+ int d;
+ u32 idx; /* Offset in aKey[] to read from */
+ u16 u; /* Unsigned loop counter */
+ u32 szHdr;
+ Mem *pMem = p->aMem;
+
+ p->flags = 0;
assert( EIGHT_BYTE_ALIGNMENT(pMem) );
idx = getVarint32(aKey, szHdr);
d = szHdr;
@@ -60471,31 +61667,6 @@ SQLITE_PRIVATE UnpackedRecord *sqlite3VdbeRecordUnpack(
}
assert( u<=pKeyInfo->nField + 1 );
p->nField = u;
- return (void*)p;
-}
-
-/*
-** This routine destroys a UnpackedRecord object.
-*/
-SQLITE_PRIVATE void sqlite3VdbeDeleteUnpackedRecord(UnpackedRecord *p){
-#ifdef SQLITE_DEBUG
- int i;
- Mem *pMem;
-
- assert( p!=0 );
- assert( p->flags & UNPACKED_NEED_DESTROY );
- for(i=0, pMem=p->aMem; i<p->nField; i++, pMem++){
- /* The unpacked record is always constructed by the
- ** sqlite3VdbeUnpackRecord() function above, which makes all
- ** strings and blobs static. And none of the elements are
- ** ever transformed, so there is never anything to delete.
- */
- if( NEVER(pMem->zMalloc) ) sqlite3VdbeMemRelease(pMem);
- }
-#endif
- if( p->flags & UNPACKED_NEED_FREE ){
- sqlite3DbFree(p->pKeyInfo->db, p);
- }
}
/*
@@ -60514,15 +61685,6 @@ SQLITE_PRIVATE void sqlite3VdbeDeleteUnpackedRecord(UnpackedRecord *p){
** Or if the UNPACKED_MATCH_PREFIX flag is set and the prefixes are
** equal, then the keys are considered to be equal and
** the parts beyond the common prefix are ignored.
-**
-** If the UNPACKED_IGNORE_ROWID flag is set, then the last byte of
-** the header of pKey1 is ignored. It is assumed that pKey1 is
-** an index key, and thus ends with a rowid value. The last byte
-** of the header will therefore be the serial type of the rowid:
-** one of 1, 2, 3, 4, 5, 6, 8, or 9 - the integer serial types.
-** The serial type of the final rowid will always be a single byte.
-** By ignoring this last byte of the header, we force the comparison
-** to ignore the rowid at the end of key1.
*/
SQLITE_PRIVATE int sqlite3VdbeRecordCompare(
int nKey1, const void *pKey1, /* Left key */
@@ -60555,10 +61717,8 @@ SQLITE_PRIVATE int sqlite3VdbeRecordCompare(
idx1 = getVarint32(aKey1, szHdr1);
d1 = szHdr1;
- if( pPKey2->flags & UNPACKED_IGNORE_ROWID ){
- szHdr1--;
- }
nField = pKeyInfo->nField;
+ assert( pKeyInfo->aSortOrder!=0 );
while( idx1<szHdr1 && i<pPKey2->nField ){
u32 serial_type1;
@@ -60578,7 +61738,7 @@ SQLITE_PRIVATE int sqlite3VdbeRecordCompare(
assert( mem1.zMalloc==0 ); /* See comment below */
/* Invert the result if we are using DESC sort order. */
- if( pKeyInfo->aSortOrder && i<nField && pKeyInfo->aSortOrder[i] ){
+ if( i<nField && pKeyInfo->aSortOrder[i] ){
rc = -rc;
}
@@ -60649,7 +61809,7 @@ SQLITE_PRIVATE int sqlite3VdbeIdxRowid(sqlite3 *db, BtCursor *pCur, i64 *rowid){
** this code can safely assume that nCellKey is 32-bits
*/
assert( sqlite3BtreeCursorIsValid(pCur) );
- rc = sqlite3BtreeKeySize(pCur, &nCellKey);
+ VVA_ONLY(rc =) sqlite3BtreeKeySize(pCur, &nCellKey);
assert( rc==SQLITE_OK ); /* pCur is always valid so KeySize cannot fail */
assert( (nCellKey & SQLITE_MAX_U32)==(u64)nCellKey );
@@ -60724,7 +61884,7 @@ SQLITE_PRIVATE int sqlite3VdbeIdxKeyCompare(
Mem m;
assert( sqlite3BtreeCursorIsValid(pCur) );
- rc = sqlite3BtreeKeySize(pCur, &nCellKey);
+ VVA_ONLY(rc =) sqlite3BtreeKeySize(pCur, &nCellKey);
assert( rc==SQLITE_OK ); /* pCur is always valid so KeySize cannot fail */
/* nCellKey will always be between 0 and 0xffffffff because of the say
** that btreeParseCellPtr() and sqlite3GetVarint32() are implemented */
@@ -60737,7 +61897,7 @@ SQLITE_PRIVATE int sqlite3VdbeIdxKeyCompare(
if( rc ){
return rc;
}
- assert( pUnpacked->flags & UNPACKED_IGNORE_ROWID );
+ assert( pUnpacked->flags & UNPACKED_PREFIX_MATCH );
*res = sqlite3VdbeRecordCompare(m.n, m.z, pUnpacked);
sqlite3VdbeMemRelease(&m);
return SQLITE_OK;
@@ -60897,17 +62057,11 @@ SQLITE_API int sqlite3_finalize(sqlite3_stmt *pStmt){
}else{
Vdbe *v = (Vdbe*)pStmt;
sqlite3 *db = v->db;
-#if SQLITE_THREADSAFE
- sqlite3_mutex *mutex;
-#endif
if( vdbeSafety(v) ) return SQLITE_MISUSE_BKPT;
-#if SQLITE_THREADSAFE
- mutex = v->db->mutex;
-#endif
- sqlite3_mutex_enter(mutex);
+ sqlite3_mutex_enter(db->mutex);
rc = sqlite3VdbeFinalize(v);
rc = sqlite3ApiExit(db, rc);
- sqlite3_mutex_leave(mutex);
+ sqlite3LeaveMutexAndCloseZombie(db);
}
return rc;
}
@@ -61180,7 +62334,7 @@ static int sqlite3Step(Vdbe *p){
**
** Nevertheless, some published applications that were originally written
** for version 3.6.23 or earlier do in fact depend on SQLITE_MISUSE
- ** returns, and the so were broken by the automatic-reset change. As a
+ ** returns, and those were broken by the automatic-reset change. As a
** a work-around, the SQLITE_OMIT_AUTORESET compile-time restores the
** legacy behavior of returning SQLITE_MISUSE for cases where the
** previous sqlite3_step() returned something other than a SQLITE_LOCKED
@@ -61277,10 +62431,10 @@ end_of_step:
assert( p->rc!=SQLITE_ROW && p->rc!=SQLITE_DONE );
if( p->isPrepareV2 && rc!=SQLITE_ROW && rc!=SQLITE_DONE ){
/* If this statement was prepared using sqlite3_prepare_v2(), and an
- ** error has occured, then return the error code in p->rc to the
+ ** error has occurred, then return the error code in p->rc to the
** caller. Set the error code in the database handle to the same value.
*/
- rc = db->errCode = p->rc;
+ rc = sqlite3VdbeTransferError(p);
}
return (rc&db->errMask);
}
@@ -61310,11 +62464,13 @@ SQLITE_API int sqlite3_step(sqlite3_stmt *pStmt){
}
db = v->db;
sqlite3_mutex_enter(db->mutex);
+ v->doingRerun = 0;
while( (rc = sqlite3Step(v))==SQLITE_SCHEMA
&& cnt++ < SQLITE_MAX_SCHEMA_RETRY
&& (rc2 = rc = sqlite3Reprepare(v))==SQLITE_OK ){
sqlite3_reset(pStmt);
- v->expired = 0;
+ v->doingRerun = 1;
+ assert( v->expired==0 );
}
if( rc2!=SQLITE_OK && ALWAYS(v->isPrepareV2) && ALWAYS(db->pErr) ){
/* This case occurs after failing to recompile an sql statement.
@@ -61526,13 +62682,13 @@ static Mem *columnMem(sqlite3_stmt *pStmt, int i){
/* If the value passed as the second argument is out of range, return
** a pointer to the following static Mem object which contains the
** value SQL NULL. Even though the Mem structure contains an element
- ** of type i64, on certain architecture (x86) with certain compiler
+ ** of type i64, on certain architectures (x86) with certain compiler
** switches (-Os), gcc may align this Mem object on a 4-byte boundary
** instead of an 8-byte one. This all works fine, except that when
** running with SQLITE_DEBUG defined the SQLite code sometimes assert()s
** that a Mem structure is located on an 8-byte boundary. To prevent
- ** this assert() from failing, when building with SQLITE_DEBUG defined
- ** using gcc, force nullMem to be 8-byte aligned using the magical
+ ** these assert()s from failing, when building with SQLITE_DEBUG defined
+ ** using gcc, we force nullMem to be 8-byte aligned using the magical
** __attribute__((aligned(8))) macro. */
static const Mem nullMem
#if defined(SQLITE_DEBUG) && defined(__GNUC__)
@@ -62028,7 +63184,7 @@ SQLITE_PRIVATE int sqlite3VdbeParameterIndex(Vdbe *p, const char *zName, int nNa
if( zName ){
for(i=0; i<p->nzVar; i++){
const char *z = p->azVar[i];
- if( z && memcmp(z,zName,nName)==0 && z[nName]==0 ){
+ if( z && strncmp(z,zName,nName)==0 && z[nName]==0 ){
return i+1;
}
}
@@ -62104,6 +63260,14 @@ SQLITE_API int sqlite3_stmt_readonly(sqlite3_stmt *pStmt){
}
/*
+** Return true if the prepared statement is in need of being reset.
+*/
+SQLITE_API int sqlite3_stmt_busy(sqlite3_stmt *pStmt){
+ Vdbe *v = (Vdbe*)pStmt;
+ return v!=0 && v->pc>0 && v->magic==VDBE_MAGIC_RUN;
+}
+
+/*
** Return a pointer to the next prepared statement after pStmt associated
** with database connection pDb. If pStmt is NULL, return the first
** prepared statement for the database connection. Return NULL if there
@@ -62147,6 +63311,8 @@ SQLITE_API int sqlite3_stmt_status(sqlite3_stmt *pStmt, int op, int resetFlag){
**
** This file contains code used to insert the values of host parameters
** (aka "wildcards") into the SQL text output by sqlite3_trace().
+**
+** The Vdbe parse-tree explainer is also found here.
*/
#ifndef SQLITE_OMIT_TRACE
@@ -62286,6 +63452,121 @@ SQLITE_PRIVATE char *sqlite3VdbeExpandSql(
#endif /* #ifndef SQLITE_OMIT_TRACE */
+/*****************************************************************************
+** The following code implements the data-structure explaining logic
+** for the Vdbe.
+*/
+
+#if defined(SQLITE_ENABLE_TREE_EXPLAIN)
+
+/*
+** Allocate a new Explain object
+*/
+SQLITE_PRIVATE void sqlite3ExplainBegin(Vdbe *pVdbe){
+ if( pVdbe ){
+ Explain *p;
+ sqlite3BeginBenignMalloc();
+ p = (Explain *)sqlite3MallocZero( sizeof(Explain) );
+ if( p ){
+ p->pVdbe = pVdbe;
+ sqlite3_free(pVdbe->pExplain);
+ pVdbe->pExplain = p;
+ sqlite3StrAccumInit(&p->str, p->zBase, sizeof(p->zBase),
+ SQLITE_MAX_LENGTH);
+ p->str.useMalloc = 2;
+ }else{
+ sqlite3EndBenignMalloc();
+ }
+ }
+}
+
+/*
+** Return true if the Explain ends with a new-line.
+*/
+static int endsWithNL(Explain *p){
+ return p && p->str.zText && p->str.nChar
+ && p->str.zText[p->str.nChar-1]=='\n';
+}
+
+/*
+** Append text to the indentation
+*/
+SQLITE_PRIVATE void sqlite3ExplainPrintf(Vdbe *pVdbe, const char *zFormat, ...){
+ Explain *p;
+ if( pVdbe && (p = pVdbe->pExplain)!=0 ){
+ va_list ap;
+ if( p->nIndent && endsWithNL(p) ){
+ int n = p->nIndent;
+ if( n>ArraySize(p->aIndent) ) n = ArraySize(p->aIndent);
+ sqlite3AppendSpace(&p->str, p->aIndent[n-1]);
+ }
+ va_start(ap, zFormat);
+ sqlite3VXPrintf(&p->str, 1, zFormat, ap);
+ va_end(ap);
+ }
+}
+
+/*
+** Append a '\n' if there is not already one.
+*/
+SQLITE_PRIVATE void sqlite3ExplainNL(Vdbe *pVdbe){
+ Explain *p;
+ if( pVdbe && (p = pVdbe->pExplain)!=0 && !endsWithNL(p) ){
+ sqlite3StrAccumAppend(&p->str, "\n", 1);
+ }
+}
+
+/*
+** Push a new indentation level. Subsequent lines will be indented
+** so that they begin at the current cursor position.
+*/
+SQLITE_PRIVATE void sqlite3ExplainPush(Vdbe *pVdbe){
+ Explain *p;
+ if( pVdbe && (p = pVdbe->pExplain)!=0 ){
+ if( p->str.zText && p->nIndent<ArraySize(p->aIndent) ){
+ const char *z = p->str.zText;
+ int i = p->str.nChar-1;
+ int x;
+ while( i>=0 && z[i]!='\n' ){ i--; }
+ x = (p->str.nChar - 1) - i;
+ if( p->nIndent && x<p->aIndent[p->nIndent-1] ){
+ x = p->aIndent[p->nIndent-1];
+ }
+ p->aIndent[p->nIndent] = x;
+ }
+ p->nIndent++;
+ }
+}
+
+/*
+** Pop the indentation stack by one level.
+*/
+SQLITE_PRIVATE void sqlite3ExplainPop(Vdbe *p){
+ if( p && p->pExplain ) p->pExplain->nIndent--;
+}
+
+/*
+** Free the indentation structure
+*/
+SQLITE_PRIVATE void sqlite3ExplainFinish(Vdbe *pVdbe){
+ if( pVdbe && pVdbe->pExplain ){
+ sqlite3_free(pVdbe->zExplain);
+ sqlite3ExplainNL(pVdbe);
+ pVdbe->zExplain = sqlite3StrAccumFinish(&pVdbe->pExplain->str);
+ sqlite3_free(pVdbe->pExplain);
+ pVdbe->pExplain = 0;
+ sqlite3EndBenignMalloc();
+ }
+}
+
+/*
+** Return the explanation of a virtual machine.
+*/
+SQLITE_PRIVATE const char *sqlite3VdbeExplanation(Vdbe *pVdbe){
+ return (pVdbe && pVdbe->zExplain) ? pVdbe->zExplain : 0;
+}
+#endif /* defined(SQLITE_DEBUG) */
+
/************** End of vdbetrace.c *******************************************/
/************** Begin file vdbe.c ********************************************/
/*
@@ -62340,7 +63621,7 @@ SQLITE_PRIVATE char *sqlite3VdbeExpandSql(
** not misused.
*/
#ifdef SQLITE_DEBUG
-# define memAboutToChange(P,M) sqlite3VdbeMemPrepareToChange(P,M)
+# define memAboutToChange(P,M) sqlite3VdbeMemAboutToChange(P,M)
#else
# define memAboutToChange(P,M)
#endif
@@ -62358,8 +63639,8 @@ SQLITE_API int sqlite3_search_count = 0;
/*
** When this global variable is positive, it gets decremented once before
-** each instruction in the VDBE. When reaches zero, the u1.isInterrupted
-** field of the sqlite3 structure is set in order to simulate and interrupt.
+** each instruction in the VDBE. When it reaches zero, the u1.isInterrupted
+** field of the sqlite3 structure is set in order to simulate an interrupt.
**
** This facility is used for testing purposes only. It does not function
** in an ordinary build.
@@ -62439,11 +63720,8 @@ SQLITE_API int sqlite3_found_count = 0;
if( ((P)->flags&MEM_Ephem)!=0 \
&& sqlite3VdbeMemMakeWriteable(P) ){ goto no_mem;}
-/*
-** Call sqlite3VdbeMemExpandBlob() on the supplied value (type Mem*)
-** P if required.
-*/
-#define ExpandBlob(P) (((P)->flags&MEM_Zero)?sqlite3VdbeMemExpandBlob(P):0)
+/* Return true if the cursor was opened using the OP_OpenSorter opcode. */
+# define isSorter(x) ((x)->pSorter!=0)
/*
** Argument pMem points at a register that will be passed to a
@@ -62477,7 +63755,7 @@ static VdbeCursor *allocateCursor(
Vdbe *p, /* The virtual machine */
int iCur, /* Index of the new VdbeCursor */
int nField, /* Number of fields in the table or index */
- int iDb, /* When database the cursor belongs to, or -1 */
+ int iDb, /* Database the cursor belongs to, or -1 */
int isBtreeCursor /* True for B-Tree. False for pseudo-table or vtab */
){
/* Find the memory cell that will be used to store the blob of memory
@@ -62709,7 +63987,9 @@ SQLITE_PRIVATE void sqlite3VdbeMemPrettyPrint(Mem *pMem, char *zBuf){
** Print the value of a register for tracing purposes:
*/
static void memTracePrint(FILE *out, Mem *p){
- if( p->flags & MEM_Null ){
+ if( p->flags & MEM_Invalid ){
+ fprintf(out, " undefined");
+ }else if( p->flags & MEM_Null ){
fprintf(out, " NULL");
}else if( (p->flags & (MEM_Int|MEM_Str))==(MEM_Int|MEM_Str) ){
fprintf(out, " si:%lld", p->u.i);
@@ -62848,7 +64128,7 @@ SQLITE_PRIVATE sqlite_uint64 sqlite3Hwtime(void){ return ((sqlite_uint64)0); }
**
** This macro added to every instruction that does a jump in order to
** implement a loop. This test used to be on every single instruction,
-** but that meant we more testing that we needed. By only testing the
+** but that meant we more testing than we needed. By only testing the
** flag on jump instructions, we get a (small) speed improvement.
*/
#define CHECK_FOR_INTERRUPT \
@@ -62958,48 +64238,56 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
struct OP_Yield_stack_vars {
int pcDest;
} aa;
+ struct OP_Null_stack_vars {
+ int cnt;
+ u16 nullFlag;
+ } ab;
struct OP_Variable_stack_vars {
Mem *pVar; /* Value being transferred */
- } ab;
+ } ac;
struct OP_Move_stack_vars {
char *zMalloc; /* Holding variable for allocated memory */
int n; /* Number of registers left to copy */
int p1; /* Register to copy from */
int p2; /* Register to copy to */
- } ac;
+ } ad;
+ struct OP_Copy_stack_vars {
+ int n;
+ } ae;
struct OP_ResultRow_stack_vars {
Mem *pMem;
int i;
- } ad;
+ } af;
struct OP_Concat_stack_vars {
i64 nByte;
- } ae;
+ } ag;
struct OP_Remainder_stack_vars {
+ char bIntint; /* Started out as two integer operands */
int flags; /* Combined MEM_* flags from both inputs */
i64 iA; /* Integer value of left operand */
i64 iB; /* Integer value of right operand */
double rA; /* Real value of left operand */
double rB; /* Real value of right operand */
- } af;
+ } ah;
struct OP_Function_stack_vars {
int i;
Mem *pArg;
sqlite3_context ctx;
sqlite3_value **apVal;
int n;
- } ag;
+ } ai;
struct OP_ShiftRight_stack_vars {
i64 iA;
u64 uA;
i64 iB;
u8 op;
- } ah;
+ } aj;
struct OP_Ge_stack_vars {
int res; /* Result of the comparison of pIn1 against pIn3 */
char affinity; /* Affinity to use for comparison */
u16 flags1; /* Copy of initial value of pIn1->flags */
u16 flags3; /* Copy of initial value of pIn3->flags */
- } ai;
+ } ak;
struct OP_Compare_stack_vars {
int n;
int i;
@@ -63009,14 +64297,14 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
int idx;
CollSeq *pColl; /* Collating sequence to use on this term */
int bRev; /* True for DESCENDING sort order */
- } aj;
+ } al;
struct OP_Or_stack_vars {
int v1; /* Left operand: 0==FALSE, 1==TRUE, 2==UNKNOWN or NULL */
int v2; /* Right operand: 0==FALSE, 1==TRUE, 2==UNKNOWN or NULL */
- } ak;
+ } am;
struct OP_IfNot_stack_vars {
int c;
- } al;
+ } an;
struct OP_Column_stack_vars {
u32 payloadSize; /* Number of bytes in the record */
i64 payloadSize64; /* Number of bytes in the record */
@@ -63039,12 +64327,13 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
u32 szField; /* Number of bytes in the content of a field */
int szHdr; /* Size of the header size field at start of record */
int avail; /* Number of bytes of available data */
+ u32 t; /* A type code from the record header */
Mem *pReg; /* PseudoTable input register */
- } am;
+ } ao;
struct OP_Affinity_stack_vars {
const char *zAffinity; /* The affinity to be applied */
char cAff; /* A single character of affinity */
- } an;
+ } ap;
struct OP_MakeRecord_stack_vars {
u8 *zNewRecord; /* A buffer to hold the data for the new record */
Mem *pRec; /* The new record */
@@ -63061,11 +64350,11 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
int file_format; /* File format to use for encoding */
int i; /* Space used in zNewRecord[] */
int len; /* Length of a field */
- } ao;
+ } aq;
struct OP_Count_stack_vars {
i64 nEntry;
BtCursor *pCrsr;
- } ap;
+ } ar;
struct OP_Savepoint_stack_vars {
int p1; /* Value of P1 operand */
char *zName; /* Name of savepoint */
@@ -63075,28 +64364,28 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
Savepoint *pTmp;
int iSavepoint;
int ii;
- } aq;
+ } as;
struct OP_AutoCommit_stack_vars {
int desiredAutoCommit;
int iRollback;
int turnOnAC;
- } ar;
+ } at;
struct OP_Transaction_stack_vars {
Btree *pBt;
- } as;
+ } au;
struct OP_ReadCookie_stack_vars {
int iMeta;
int iDb;
int iCookie;
- } at;
+ } av;
struct OP_SetCookie_stack_vars {
Db *pDb;
- } au;
+ } aw;
struct OP_VerifyCookie_stack_vars {
int iMeta;
int iGen;
Btree *pBt;
- } av;
+ } ax;
struct OP_OpenWrite_stack_vars {
int nField;
KeyInfo *pKeyInfo;
@@ -63106,13 +64395,16 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
Btree *pX;
VdbeCursor *pCur;
Db *pDb;
- } aw;
+ } ay;
struct OP_OpenEphemeral_stack_vars {
VdbeCursor *pCx;
- } ax;
+ } az;
+ struct OP_SorterOpen_stack_vars {
+ VdbeCursor *pCx;
+ } ba;
struct OP_OpenPseudo_stack_vars {
VdbeCursor *pCx;
- } ay;
+ } bb;
struct OP_SeekGt_stack_vars {
int res;
int oc;
@@ -63120,18 +64412,19 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
UnpackedRecord r;
int nField;
i64 iKey; /* The rowid we are to seek to */
- } az;
+ } bc;
struct OP_Seek_stack_vars {
VdbeCursor *pC;
- } ba;
+ } bd;
struct OP_Found_stack_vars {
int alreadyExists;
VdbeCursor *pC;
int res;
+ char *pFree;
UnpackedRecord *pIdxKey;
UnpackedRecord r;
char aTempRec[ROUND8(sizeof(UnpackedRecord)) + sizeof(Mem)*3 + 7];
- } bb;
+ } be;
struct OP_IsUnique_stack_vars {
u16 ii;
VdbeCursor *pCx;
@@ -63140,13 +64433,13 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
Mem *aMx;
UnpackedRecord r; /* B-Tree index search key */
i64 R; /* Rowid stored in register P3 */
- } bc;
+ } bf;
struct OP_NotExists_stack_vars {
VdbeCursor *pC;
BtCursor *pCrsr;
int res;
u64 iKey;
- } bd;
+ } bg;
struct OP_NewRowid_stack_vars {
i64 v; /* The new rowid */
VdbeCursor *pC; /* Cursor of table to get the new rowid */
@@ -63154,7 +64447,7 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
int cnt; /* Counter to limit the number of searches */
Mem *pMem; /* Register holding largest rowid for AUTOINCREMENT */
VdbeFrame *pFrame; /* Root frame of VDBE */
- } be;
+ } bh;
struct OP_InsertInt_stack_vars {
Mem *pData; /* MEM cell holding data for the record to be inserted */
Mem *pKey; /* MEM cell holding key for the record */
@@ -63165,83 +64458,89 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
const char *zDb; /* database name - used by the update hook */
const char *zTbl; /* Table name - used by the opdate hook */
int op; /* Opcode for update hook: SQLITE_UPDATE or SQLITE_INSERT */
- } bf;
+ } bi;
struct OP_Delete_stack_vars {
i64 iKey;
VdbeCursor *pC;
- } bg;
+ } bj;
+ struct OP_SorterCompare_stack_vars {
+ VdbeCursor *pC;
+ int res;
+ } bk;
+ struct OP_SorterData_stack_vars {
+ VdbeCursor *pC;
+ } bl;
struct OP_RowData_stack_vars {
VdbeCursor *pC;
BtCursor *pCrsr;
u32 n;
i64 n64;
- } bh;
+ } bm;
struct OP_Rowid_stack_vars {
VdbeCursor *pC;
i64 v;
sqlite3_vtab *pVtab;
const sqlite3_module *pModule;
- } bi;
+ } bn;
struct OP_NullRow_stack_vars {
VdbeCursor *pC;
- } bj;
+ } bo;
struct OP_Last_stack_vars {
VdbeCursor *pC;
BtCursor *pCrsr;
int res;
- } bk;
+ } bp;
struct OP_Rewind_stack_vars {
VdbeCursor *pC;
BtCursor *pCrsr;
int res;
- } bl;
+ } bq;
struct OP_Next_stack_vars {
VdbeCursor *pC;
- BtCursor *pCrsr;
int res;
- } bm;
+ } br;
struct OP_IdxInsert_stack_vars {
VdbeCursor *pC;
BtCursor *pCrsr;
int nKey;
const char *zKey;
- } bn;
+ } bs;
struct OP_IdxDelete_stack_vars {
VdbeCursor *pC;
BtCursor *pCrsr;
int res;
UnpackedRecord r;
- } bo;
+ } bt;
struct OP_IdxRowid_stack_vars {
BtCursor *pCrsr;
VdbeCursor *pC;
i64 rowid;
- } bp;
+ } bu;
struct OP_IdxGE_stack_vars {
VdbeCursor *pC;
int res;
UnpackedRecord r;
- } bq;
+ } bv;
struct OP_Destroy_stack_vars {
int iMoved;
int iCnt;
Vdbe *pVdbe;
int iDb;
- } br;
+ } bw;
struct OP_Clear_stack_vars {
int nChange;
- } bs;
+ } bx;
struct OP_CreateTable_stack_vars {
int pgno;
int flags;
Db *pDb;
- } bt;
+ } by;
struct OP_ParseSchema_stack_vars {
int iDb;
const char *zMaster;
char *zSql;
InitData initData;
- } bu;
+ } bz;
struct OP_IntegrityCk_stack_vars {
int nRoot; /* Number of tables to check. (Number of root pages.) */
int *aRoot; /* Array of rootpage numbers for tables to be checked */
@@ -63249,14 +64548,14 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
int nErr; /* Number of errors reported */
char *z; /* Text of the error report */
Mem *pnErr; /* Register keeping track of errors remaining */
- } bv;
+ } ca;
struct OP_RowSetRead_stack_vars {
i64 val;
- } bw;
+ } cb;
struct OP_RowSetTest_stack_vars {
int iSet;
int exists;
- } bx;
+ } cc;
struct OP_Program_stack_vars {
int nMem; /* Number of memory registers for sub-program */
int nByte; /* Bytes of runtime space required for sub-program */
@@ -63266,15 +64565,15 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
VdbeFrame *pFrame; /* New vdbe frame to execute in */
SubProgram *pProgram; /* Sub-program to execute */
void *t; /* Token identifying trigger */
- } by;
+ } cd;
struct OP_Param_stack_vars {
VdbeFrame *pFrame;
Mem *pIn;
- } bz;
+ } ce;
struct OP_MemMax_stack_vars {
Mem *pIn1;
VdbeFrame *pFrame;
- } ca;
+ } cf;
struct OP_AggStep_stack_vars {
int n;
int i;
@@ -63282,34 +64581,36 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
Mem *pRec;
sqlite3_context ctx;
sqlite3_value **apVal;
- } cb;
+ } cg;
struct OP_AggFinal_stack_vars {
Mem *pMem;
- } cc;
+ } ch;
struct OP_Checkpoint_stack_vars {
int i; /* Loop counter */
int aRes[3]; /* Results */
Mem *pMem; /* Write results here */
- } cd;
+ } ci;
struct OP_JournalMode_stack_vars {
Btree *pBt; /* Btree to change journal mode of */
Pager *pPager; /* Pager associated with pBt */
int eNew; /* New journal mode */
int eOld; /* The old journal mode */
+#ifndef SQLITE_OMIT_WAL
const char *zFilename; /* Name of database file for pPager */
- } ce;
+#endif
+ } cj;
struct OP_IncrVacuum_stack_vars {
Btree *pBt;
- } cf;
+ } ck;
struct OP_VBegin_stack_vars {
VTable *pVTab;
- } cg;
+ } cl;
struct OP_VOpen_stack_vars {
VdbeCursor *pCur;
sqlite3_vtab_cursor *pVtabCursor;
sqlite3_vtab *pVtab;
sqlite3_module *pModule;
- } ch;
+ } cm;
struct OP_VFilter_stack_vars {
int nArg;
int iQuery;
@@ -63322,23 +64623,23 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
int res;
int i;
Mem **apArg;
- } ci;
+ } cn;
struct OP_VColumn_stack_vars {
sqlite3_vtab *pVtab;
const sqlite3_module *pModule;
Mem *pDest;
sqlite3_context sContext;
- } cj;
+ } co;
struct OP_VNext_stack_vars {
sqlite3_vtab *pVtab;
const sqlite3_module *pModule;
int res;
VdbeCursor *pCur;
- } ck;
+ } cp;
struct OP_VRename_stack_vars {
sqlite3_vtab *pVtab;
Mem *pName;
- } cl;
+ } cq;
struct OP_VUpdate_stack_vars {
sqlite3_vtab *pVtab;
sqlite3_module *pModule;
@@ -63347,11 +64648,11 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
sqlite_int64 rowid;
Mem **apArg;
Mem *pX;
- } cm;
+ } cr;
struct OP_Trace_stack_vars {
char *zTrace;
char *z;
- } cn;
+ } cs;
} u;
/* End automatically generated code
********************************************************************/
@@ -63440,7 +64741,7 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
}
#endif
- /* On any opcode with the "out2-prerelase" tag, free any
+ /* On any opcode with the "out2-prerelease" tag, free any
** external allocations out of mem[p2] and set mem[p2] to be
** an undefined integer. Opcodes will either fill in the integer
** value or convert mem[p2] to a different type.
@@ -63451,7 +64752,7 @@ SQLITE_PRIVATE int sqlite3VdbeExec(
assert( pOp->p2<=p->nMem );
pOut = &aMem[pOp->p2];
memAboutToChange(p, pOut);
- sqlite3VdbeMemReleaseExternal(pOut);
+ VdbeMemRelease(pOut);
pOut->flags = MEM_Int;
}
@@ -63542,7 +64843,8 @@ case OP_Goto: { /* jump */
** Write the current address onto register P1
** and then jump to address P2.
*/
-case OP_Gosub: { /* jump, in1 */
+case OP_Gosub: { /* jump */
+ assert( pOp->p1>0 && pOp->p1<=p->nMem );
pIn1 = &aMem[pOp->p1];
assert( (pIn1->flags & MEM_Dyn)==0 );
memAboutToChange(p, pIn1);
@@ -63652,7 +64954,7 @@ case OP_Halt: {
if( rc==SQLITE_BUSY ){
p->rc = rc = SQLITE_BUSY;
}else{
- assert( rc==SQLITE_OK || p->rc==SQLITE_CONSTRAINT );
+ assert( rc==SQLITE_OK || (p->rc&0xff)==SQLITE_CONSTRAINT );
assert( rc==SQLITE_OK || db->nDeferredCons>0 );
rc = p->rc ? SQLITE_ERROR : SQLITE_DONE;
}
@@ -63741,12 +65043,32 @@ case OP_String: { /* out2-prerelease */
break;
}
-/* Opcode: Null * P2 * * *
+/* Opcode: Null P1 P2 P3 * *
**
-** Write a NULL into register P2.
+** Write a NULL into registers P2. If P3 greater than P2, then also write
+** NULL into register P3 and every register in between P2 and P3. If P3
+** is less than P2 (typically P3 is zero) then only register P2 is
+** set to NULL.
+**
+** If the P1 value is non-zero, then also set the MEM_Cleared flag so that
+** NULL values will not compare equal even if SQLITE_NULLEQ is set on
+** OP_Ne or OP_Eq.
*/
case OP_Null: { /* out2-prerelease */
- pOut->flags = MEM_Null;
+#if 0 /* local variables moved into u.ab */
+ int cnt;
+ u16 nullFlag;
+#endif /* local variables moved into u.ab */
+ u.ab.cnt = pOp->p3-pOp->p2;
+ assert( pOp->p3<=p->nMem );
+ pOut->flags = u.ab.nullFlag = pOp->p1 ? (MEM_Null|MEM_Cleared) : MEM_Null;
+ while( u.ab.cnt>0 ){
+ pOut++;
+ memAboutToChange(p, pOut);
+ VdbeMemRelease(pOut);
+ pOut->flags = u.ab.nullFlag;
+ u.ab.cnt--;
+ }
break;
}
@@ -63772,74 +65094,92 @@ case OP_Blob: { /* out2-prerelease */
** The P4 value is used by sqlite3_bind_parameter_name().
*/
case OP_Variable: { /* out2-prerelease */
-#if 0 /* local variables moved into u.ab */
+#if 0 /* local variables moved into u.ac */
Mem *pVar; /* Value being transferred */
-#endif /* local variables moved into u.ab */
+#endif /* local variables moved into u.ac */
assert( pOp->p1>0 && pOp->p1<=p->nVar );
assert( pOp->p4.z==0 || pOp->p4.z==p->azVar[pOp->p1-1] );
- u.ab.pVar = &p->aVar[pOp->p1 - 1];
- if( sqlite3VdbeMemTooBig(u.ab.pVar) ){
+ u.ac.pVar = &p->aVar[pOp->p1 - 1];
+ if( sqlite3VdbeMemTooBig(u.ac.pVar) ){
goto too_big;
}
- sqlite3VdbeMemShallowCopy(pOut, u.ab.pVar, MEM_Static);
+ sqlite3VdbeMemShallowCopy(pOut, u.ac.pVar, MEM_Static);
UPDATE_MAX_BLOBSIZE(pOut);
break;
}
/* Opcode: Move P1 P2 P3 * *
**
-** Move the values in register P1..P1+P3-1 over into
-** registers P2..P2+P3-1. Registers P1..P1+P1-1 are
+** Move the values in register P1..P1+P3 over into
+** registers P2..P2+P3. Registers P1..P1+P3 are
** left holding a NULL. It is an error for register ranges
-** P1..P1+P3-1 and P2..P2+P3-1 to overlap.
+** P1..P1+P3 and P2..P2+P3 to overlap.
*/
case OP_Move: {
-#if 0 /* local variables moved into u.ac */
+#if 0 /* local variables moved into u.ad */
char *zMalloc; /* Holding variable for allocated memory */
int n; /* Number of registers left to copy */
int p1; /* Register to copy from */
int p2; /* Register to copy to */
-#endif /* local variables moved into u.ac */
+#endif /* local variables moved into u.ad */
- u.ac.n = pOp->p3;
- u.ac.p1 = pOp->p1;
- u.ac.p2 = pOp->p2;
- assert( u.ac.n>0 && u.ac.p1>0 && u.ac.p2>0 );
- assert( u.ac.p1+u.ac.n<=u.ac.p2 || u.ac.p2+u.ac.n<=u.ac.p1 );
+ u.ad.n = pOp->p3 + 1;
+ u.ad.p1 = pOp->p1;
+ u.ad.p2 = pOp->p2;
+ assert( u.ad.n>0 && u.ad.p1>0 && u.ad.p2>0 );
+ assert( u.ad.p1+u.ad.n<=u.ad.p2 || u.ad.p2+u.ad.n<=u.ad.p1 );
- pIn1 = &aMem[u.ac.p1];
- pOut = &aMem[u.ac.p2];
- while( u.ac.n-- ){
+ pIn1 = &aMem[u.ad.p1];
+ pOut = &aMem[u.ad.p2];
+ while( u.ad.n-- ){
assert( pOut<=&aMem[p->nMem] );
assert( pIn1<=&aMem[p->nMem] );
assert( memIsValid(pIn1) );
memAboutToChange(p, pOut);
- u.ac.zMalloc = pOut->zMalloc;
+ u.ad.zMalloc = pOut->zMalloc;
pOut->zMalloc = 0;
sqlite3VdbeMemMove(pOut, pIn1);
- pIn1->zMalloc = u.ac.zMalloc;
- REGISTER_TRACE(u.ac.p2++, pOut);
+#ifdef SQLITE_DEBUG
+ if( pOut->pScopyFrom>=&aMem[u.ad.p1] && pOut->pScopyFrom<&aMem[u.ad.p1+pOp->p3] ){
+ pOut->pScopyFrom += u.ad.p1 - pOp->p2;
+ }
+#endif
+ pIn1->zMalloc = u.ad.zMalloc;
+ REGISTER_TRACE(u.ad.p2++, pOut);
pIn1++;
pOut++;
}
break;
}
-/* Opcode: Copy P1 P2 * * *
+/* Opcode: Copy P1 P2 P3 * *
**
-** Make a copy of register P1 into register P2.
+** Make a copy of registers P1..P1+P3 into registers P2..P2+P3.
**
** This instruction makes a deep copy of the value. A duplicate
** is made of any string or blob constant. See also OP_SCopy.
*/
-case OP_Copy: { /* in1, out2 */
+case OP_Copy: {
+#if 0 /* local variables moved into u.ae */
+ int n;
+#endif /* local variables moved into u.ae */
+
+ u.ae.n = pOp->p3;
pIn1 = &aMem[pOp->p1];
pOut = &aMem[pOp->p2];
assert( pOut!=pIn1 );
- sqlite3VdbeMemShallowCopy(pOut, pIn1, MEM_Ephem);
- Deephemeralize(pOut);
- REGISTER_TRACE(pOp->p2, pOut);
+ while( 1 ){
+ sqlite3VdbeMemShallowCopy(pOut, pIn1, MEM_Ephem);
+ Deephemeralize(pOut);
+#ifdef SQLITE_DEBUG
+ pOut->pScopyFrom = 0;
+#endif
+ REGISTER_TRACE(pOp->p2+pOp->p3-u.ae.n, pOut);
+ if( (u.ae.n--)==0 ) break;
+ pOut++;
+ pIn1++;
+ }
break;
}
@@ -63876,10 +65216,10 @@ case OP_SCopy: { /* in1, out2 */
** row.
*/
case OP_ResultRow: {
-#if 0 /* local variables moved into u.ad */
+#if 0 /* local variables moved into u.af */
Mem *pMem;
int i;
-#endif /* local variables moved into u.ad */
+#endif /* local variables moved into u.af */
assert( p->nResColumn==pOp->p2 );
assert( pOp->p1>0 );
assert( pOp->p1+pOp->p2<=p->nMem+1 );
@@ -63919,17 +65259,17 @@ case OP_ResultRow: {
/* Make sure the results of the current row are \000 terminated
** and have an assigned type. The results are de-ephemeralized as
- ** as side effect.
- */
- u.ad.pMem = p->pResultSet = &aMem[pOp->p1];
- for(u.ad.i=0; u.ad.i<pOp->p2; u.ad.i++){
- assert( memIsValid(&u.ad.pMem[u.ad.i]) );
- Deephemeralize(&u.ad.pMem[u.ad.i]);
- assert( (u.ad.pMem[u.ad.i].flags & MEM_Ephem)==0
- || (u.ad.pMem[u.ad.i].flags & (MEM_Str|MEM_Blob))==0 );
- sqlite3VdbeMemNulTerminate(&u.ad.pMem[u.ad.i]);
- sqlite3VdbeMemStoreType(&u.ad.pMem[u.ad.i]);
- REGISTER_TRACE(pOp->p1+u.ad.i, &u.ad.pMem[u.ad.i]);
+ ** a side effect.
+ */
+ u.af.pMem = p->pResultSet = &aMem[pOp->p1];
+ for(u.af.i=0; u.af.i<pOp->p2; u.af.i++){
+ assert( memIsValid(&u.af.pMem[u.af.i]) );
+ Deephemeralize(&u.af.pMem[u.af.i]);
+ assert( (u.af.pMem[u.af.i].flags & MEM_Ephem)==0
+ || (u.af.pMem[u.af.i].flags & (MEM_Str|MEM_Blob))==0 );
+ sqlite3VdbeMemNulTerminate(&u.af.pMem[u.af.i]);
+ sqlite3VdbeMemStoreType(&u.af.pMem[u.af.i]);
+ REGISTER_TRACE(pOp->p1+u.af.i, &u.af.pMem[u.af.i]);
}
if( db->mallocFailed ) goto no_mem;
@@ -63953,9 +65293,9 @@ case OP_ResultRow: {
** to avoid a memcpy().
*/
case OP_Concat: { /* same as TK_CONCAT, in1, in2, out3 */
-#if 0 /* local variables moved into u.ae */
+#if 0 /* local variables moved into u.ag */
i64 nByte;
-#endif /* local variables moved into u.ae */
+#endif /* local variables moved into u.ag */
pIn1 = &aMem[pOp->p1];
pIn2 = &aMem[pOp->p2];
@@ -63968,22 +65308,22 @@ case OP_Concat: { /* same as TK_CONCAT, in1, in2, out3 */
if( ExpandBlob(pIn1) || ExpandBlob(pIn2) ) goto no_mem;
Stringify(pIn1, encoding);
Stringify(pIn2, encoding);
- u.ae.nByte = pIn1->n + pIn2->n;
- if( u.ae.nByte>db->aLimit[SQLITE_LIMIT_LENGTH] ){
+ u.ag.nByte = pIn1->n + pIn2->n;
+ if( u.ag.nByte>db->aLimit[SQLITE_LIMIT_LENGTH] ){
goto too_big;
}
MemSetTypeFlag(pOut, MEM_Str);
- if( sqlite3VdbeMemGrow(pOut, (int)u.ae.nByte+2, pOut==pIn2) ){
+ if( sqlite3VdbeMemGrow(pOut, (int)u.ag.nByte+2, pOut==pIn2) ){
goto no_mem;
}
if( pOut!=pIn2 ){
memcpy(pOut->z, pIn2->z, pIn2->n);
}
memcpy(&pOut->z[pIn2->n], pIn1->z, pIn1->n);
- pOut->z[u.ae.nByte] = 0;
- pOut->z[u.ae.nByte+1] = 0;
+ pOut->z[u.ag.nByte] = 0;
+ pOut->z[u.ag.nByte+1] = 0;
pOut->flags |= MEM_Term;
- pOut->n = (int)u.ae.nByte;
+ pOut->n = (int)u.ag.nByte;
pOut->enc = encoding;
UPDATE_MAX_BLOBSIZE(pOut);
break;
@@ -64027,76 +65367,79 @@ case OP_Subtract: /* same as TK_MINUS, in1, in2, out3 */
case OP_Multiply: /* same as TK_STAR, in1, in2, out3 */
case OP_Divide: /* same as TK_SLASH, in1, in2, out3 */
case OP_Remainder: { /* same as TK_REM, in1, in2, out3 */
-#if 0 /* local variables moved into u.af */
+#if 0 /* local variables moved into u.ah */
+ char bIntint; /* Started out as two integer operands */
int flags; /* Combined MEM_* flags from both inputs */
i64 iA; /* Integer value of left operand */
i64 iB; /* Integer value of right operand */
double rA; /* Real value of left operand */
double rB; /* Real value of right operand */
-#endif /* local variables moved into u.af */
+#endif /* local variables moved into u.ah */
pIn1 = &aMem[pOp->p1];
applyNumericAffinity(pIn1);
pIn2 = &aMem[pOp->p2];
applyNumericAffinity(pIn2);
pOut = &aMem[pOp->p3];
- u.af.flags = pIn1->flags | pIn2->flags;
- if( (u.af.flags & MEM_Null)!=0 ) goto arithmetic_result_is_null;
+ u.ah.flags = pIn1->flags | pIn2->flags;
+ if( (u.ah.flags & MEM_Null)!=0 ) goto arithmetic_result_is_null;
if( (pIn1->flags & pIn2->flags & MEM_Int)==MEM_Int ){
- u.af.iA = pIn1->u.i;
- u.af.iB = pIn2->u.i;
+ u.ah.iA = pIn1->u.i;
+ u.ah.iB = pIn2->u.i;
+ u.ah.bIntint = 1;
switch( pOp->opcode ){
- case OP_Add: if( sqlite3AddInt64(&u.af.iB,u.af.iA) ) goto fp_math; break;
- case OP_Subtract: if( sqlite3SubInt64(&u.af.iB,u.af.iA) ) goto fp_math; break;
- case OP_Multiply: if( sqlite3MulInt64(&u.af.iB,u.af.iA) ) goto fp_math; break;
+ case OP_Add: if( sqlite3AddInt64(&u.ah.iB,u.ah.iA) ) goto fp_math; break;
+ case OP_Subtract: if( sqlite3SubInt64(&u.ah.iB,u.ah.iA) ) goto fp_math; break;
+ case OP_Multiply: if( sqlite3MulInt64(&u.ah.iB,u.ah.iA) ) goto fp_math; break;
case OP_Divide: {
- if( u.af.iA==0 ) goto arithmetic_result_is_null;
- if( u.af.iA==-1 && u.af.iB==SMALLEST_INT64 ) goto fp_math;
- u.af.iB /= u.af.iA;
+ if( u.ah.iA==0 ) goto arithmetic_result_is_null;
+ if( u.ah.iA==-1 && u.ah.iB==SMALLEST_INT64 ) goto fp_math;
+ u.ah.iB /= u.ah.iA;
break;
}
default: {
- if( u.af.iA==0 ) goto arithmetic_result_is_null;
- if( u.af.iA==-1 ) u.af.iA = 1;
- u.af.iB %= u.af.iA;
+ if( u.ah.iA==0 ) goto arithmetic_result_is_null;
+ if( u.ah.iA==-1 ) u.ah.iA = 1;
+ u.ah.iB %= u.ah.iA;
break;
}
}
- pOut->u.i = u.af.iB;
+ pOut->u.i = u.ah.iB;
MemSetTypeFlag(pOut, MEM_Int);
}else{
+ u.ah.bIntint = 0;
fp_math:
- u.af.rA = sqlite3VdbeRealValue(pIn1);
- u.af.rB = sqlite3VdbeRealValue(pIn2);
+ u.ah.rA = sqlite3VdbeRealValue(pIn1);
+ u.ah.rB = sqlite3VdbeRealValue(pIn2);
switch( pOp->opcode ){
- case OP_Add: u.af.rB += u.af.rA; break;
- case OP_Subtract: u.af.rB -= u.af.rA; break;
- case OP_Multiply: u.af.rB *= u.af.rA; break;
+ case OP_Add: u.ah.rB += u.ah.rA; break;
+ case OP_Subtract: u.ah.rB -= u.ah.rA; break;
+ case OP_Multiply: u.ah.rB *= u.ah.rA; break;
case OP_Divide: {
/* (double)0 In case of SQLITE_OMIT_FLOATING_POINT... */
- if( u.af.rA==(double)0 ) goto arithmetic_result_is_null;
- u.af.rB /= u.af.rA;
+ if( u.ah.rA==(double)0 ) goto arithmetic_result_is_null;
+ u.ah.rB /= u.ah.rA;
break;
}
default: {
- u.af.iA = (i64)u.af.rA;
- u.af.iB = (i64)u.af.rB;
- if( u.af.iA==0 ) goto arithmetic_result_is_null;
- if( u.af.iA==-1 ) u.af.iA = 1;
- u.af.rB = (double)(u.af.iB % u.af.iA);
+ u.ah.iA = (i64)u.ah.rA;
+ u.ah.iB = (i64)u.ah.rB;
+ if( u.ah.iA==0 ) goto arithmetic_result_is_null;
+ if( u.ah.iA==-1 ) u.ah.iA = 1;
+ u.ah.rB = (double)(u.ah.iB % u.ah.iA);
break;
}
}
#ifdef SQLITE_OMIT_FLOATING_POINT
- pOut->u.i = u.af.rB;
+ pOut->u.i = u.ah.rB;
MemSetTypeFlag(pOut, MEM_Int);
#else
- if( sqlite3IsNaN(u.af.rB) ){
+ if( sqlite3IsNaN(u.ah.rB) ){
goto arithmetic_result_is_null;
}
- pOut->r = u.af.rB;
+ pOut->r = u.ah.rB;
MemSetTypeFlag(pOut, MEM_Real);
- if( (u.af.flags & MEM_Real)==0 ){
+ if( (u.ah.flags & MEM_Real)==0 && !u.ah.bIntint ){
sqlite3VdbeIntegerAffinity(pOut);
}
#endif
@@ -64108,19 +65451,26 @@ arithmetic_result_is_null:
break;
}
-/* Opcode: CollSeq * * P4
+/* Opcode: CollSeq P1 * * P4
**
** P4 is a pointer to a CollSeq struct. If the next call to a user function
** or aggregate calls sqlite3GetFuncCollSeq(), this collation sequence will
** be returned. This is used by the built-in min(), max() and nullif()
** functions.
**
+** If P1 is not zero, then it is a register that a subsequent min() or
+** max() aggregate will set to 1 if the current row is not the minimum or
+** maximum. The P1 register is initialized to 0 by this instruction.
+**
** The interface used by the implementation of the aforementioned functions
** to retrieve the collation sequence set by this opcode is not available
** publicly, only to user functions defined in func.c.
*/
case OP_CollSeq: {
assert( pOp->p4type==P4_COLLSEQ );
+ if( pOp->p1 ){
+ sqlite3VdbeMemSetInt64(&aMem[pOp->p1], 0);
+ }
break;
}
@@ -64141,70 +65491,70 @@ case OP_CollSeq: {
** See also: AggStep and AggFinal
*/
case OP_Function: {
-#if 0 /* local variables moved into u.ag */
+#if 0 /* local variables moved into u.ai */
int i;
Mem *pArg;
sqlite3_context ctx;
sqlite3_value **apVal;
int n;
-#endif /* local variables moved into u.ag */
+#endif /* local variables moved into u.ai */
- u.ag.n = pOp->p5;
- u.ag.apVal = p->apArg;
- assert( u.ag.apVal || u.ag.n==0 );
+ u.ai.n = pOp->p5;
+ u.ai.apVal = p->apArg;
+ assert( u.ai.apVal || u.ai.n==0 );
assert( pOp->p3>0 && pOp->p3<=p->nMem );
pOut = &aMem[pOp->p3];
memAboutToChange(p, pOut);
- assert( u.ag.n==0 || (pOp->p2>0 && pOp->p2+u.ag.n<=p->nMem+1) );
- assert( pOp->p3<pOp->p2 || pOp->p3>=pOp->p2+u.ag.n );
- u.ag.pArg = &aMem[pOp->p2];
- for(u.ag.i=0; u.ag.i<u.ag.n; u.ag.i++, u.ag.pArg++){
- assert( memIsValid(u.ag.pArg) );
- u.ag.apVal[u.ag.i] = u.ag.pArg;
- Deephemeralize(u.ag.pArg);
- sqlite3VdbeMemStoreType(u.ag.pArg);
- REGISTER_TRACE(pOp->p2+u.ag.i, u.ag.pArg);
+ assert( u.ai.n==0 || (pOp->p2>0 && pOp->p2+u.ai.n<=p->nMem+1) );
+ assert( pOp->p3<pOp->p2 || pOp->p3>=pOp->p2+u.ai.n );
+ u.ai.pArg = &aMem[pOp->p2];
+ for(u.ai.i=0; u.ai.i<u.ai.n; u.ai.i++, u.ai.pArg++){
+ assert( memIsValid(u.ai.pArg) );
+ u.ai.apVal[u.ai.i] = u.ai.pArg;
+ Deephemeralize(u.ai.pArg);
+ sqlite3VdbeMemStoreType(u.ai.pArg);
+ REGISTER_TRACE(pOp->p2+u.ai.i, u.ai.pArg);
}
assert( pOp->p4type==P4_FUNCDEF || pOp->p4type==P4_VDBEFUNC );
if( pOp->p4type==P4_FUNCDEF ){
- u.ag.ctx.pFunc = pOp->p4.pFunc;
- u.ag.ctx.pVdbeFunc = 0;
+ u.ai.ctx.pFunc = pOp->p4.pFunc;
+ u.ai.ctx.pVdbeFunc = 0;
}else{
- u.ag.ctx.pVdbeFunc = (VdbeFunc*)pOp->p4.pVdbeFunc;
- u.ag.ctx.pFunc = u.ag.ctx.pVdbeFunc->pFunc;
+ u.ai.ctx.pVdbeFunc = (VdbeFunc*)pOp->p4.pVdbeFunc;
+ u.ai.ctx.pFunc = u.ai.ctx.pVdbeFunc->pFunc;
}
- u.ag.ctx.s.flags = MEM_Null;
- u.ag.ctx.s.db = db;
- u.ag.ctx.s.xDel = 0;
- u.ag.ctx.s.zMalloc = 0;
+ u.ai.ctx.s.flags = MEM_Null;
+ u.ai.ctx.s.db = db;
+ u.ai.ctx.s.xDel = 0;
+ u.ai.ctx.s.zMalloc = 0;
/* The output cell may already have a buffer allocated. Move
- ** the pointer to u.ag.ctx.s so in case the user-function can use
+ ** the pointer to u.ai.ctx.s so in case the user-function can use
** the already allocated buffer instead of allocating a new one.
*/
- sqlite3VdbeMemMove(&u.ag.ctx.s, pOut);
- MemSetTypeFlag(&u.ag.ctx.s, MEM_Null);
+ sqlite3VdbeMemMove(&u.ai.ctx.s, pOut);
+ MemSetTypeFlag(&u.ai.ctx.s, MEM_Null);
- u.ag.ctx.isError = 0;
- if( u.ag.ctx.pFunc->flags & SQLITE_FUNC_NEEDCOLL ){
+ u.ai.ctx.isError = 0;
+ if( u.ai.ctx.pFunc->flags & SQLITE_FUNC_NEEDCOLL ){
assert( pOp>aOp );
assert( pOp[-1].p4type==P4_COLLSEQ );
assert( pOp[-1].opcode==OP_CollSeq );
- u.ag.ctx.pColl = pOp[-1].p4.pColl;
+ u.ai.ctx.pColl = pOp[-1].p4.pColl;
}
db->lastRowid = lastRowid;
- (*u.ag.ctx.pFunc->xFunc)(&u.ag.ctx, u.ag.n, u.ag.apVal); /* IMP: R-24505-23230 */
+ (*u.ai.ctx.pFunc->xFunc)(&u.ai.ctx, u.ai.n, u.ai.apVal); /* IMP: R-24505-23230 */
lastRowid = db->lastRowid;
/* If any auxiliary data functions have been called by this user function,
** immediately call the destructor for any non-static values.
*/
- if( u.ag.ctx.pVdbeFunc ){
- sqlite3VdbeDeleteAuxData(u.ag.ctx.pVdbeFunc, pOp->p1);
- pOp->p4.pVdbeFunc = u.ag.ctx.pVdbeFunc;
+ if( u.ai.ctx.pVdbeFunc ){
+ sqlite3VdbeDeleteAuxData(u.ai.ctx.pVdbeFunc, pOp->p1);
+ pOp->p4.pVdbeFunc = u.ai.ctx.pVdbeFunc;
pOp->p4type = P4_VDBEFUNC;
}
@@ -64214,19 +65564,19 @@ case OP_Function: {
** to return a value. The following call releases any resources
** associated with such a value.
*/
- sqlite3VdbeMemRelease(&u.ag.ctx.s);
+ sqlite3VdbeMemRelease(&u.ai.ctx.s);
goto no_mem;
}
/* If the function returned an error, throw an exception */
- if( u.ag.ctx.isError ){
- sqlite3SetString(&p->zErrMsg, db, "%s", sqlite3_value_text(&u.ag.ctx.s));
- rc = u.ag.ctx.isError;
+ if( u.ai.ctx.isError ){
+ sqlite3SetString(&p->zErrMsg, db, "%s", sqlite3_value_text(&u.ai.ctx.s));
+ rc = u.ai.ctx.isError;
}
/* Copy the result of the function into register P3 */
- sqlite3VdbeChangeEncoding(&u.ag.ctx.s, encoding);
- sqlite3VdbeMemMove(pOut, &u.ag.ctx.s);
+ sqlite3VdbeChangeEncoding(&u.ai.ctx.s, encoding);
+ sqlite3VdbeMemMove(pOut, &u.ai.ctx.s);
if( sqlite3VdbeMemTooBig(pOut) ){
goto too_big;
}
@@ -64274,12 +65624,12 @@ case OP_BitAnd: /* same as TK_BITAND, in1, in2, out3 */
case OP_BitOr: /* same as TK_BITOR, in1, in2, out3 */
case OP_ShiftLeft: /* same as TK_LSHIFT, in1, in2, out3 */
case OP_ShiftRight: { /* same as TK_RSHIFT, in1, in2, out3 */
-#if 0 /* local variables moved into u.ah */
+#if 0 /* local variables moved into u.aj */
i64 iA;
u64 uA;
i64 iB;
u8 op;
-#endif /* local variables moved into u.ah */
+#endif /* local variables moved into u.aj */
pIn1 = &aMem[pOp->p1];
pIn2 = &aMem[pOp->p2];
@@ -64288,38 +65638,38 @@ case OP_ShiftRight: { /* same as TK_RSHIFT, in1, in2, out3 */
sqlite3VdbeMemSetNull(pOut);
break;
}
- u.ah.iA = sqlite3VdbeIntValue(pIn2);
- u.ah.iB = sqlite3VdbeIntValue(pIn1);
- u.ah.op = pOp->opcode;
- if( u.ah.op==OP_BitAnd ){
- u.ah.iA &= u.ah.iB;
- }else if( u.ah.op==OP_BitOr ){
- u.ah.iA |= u.ah.iB;
- }else if( u.ah.iB!=0 ){
- assert( u.ah.op==OP_ShiftRight || u.ah.op==OP_ShiftLeft );
+ u.aj.iA = sqlite3VdbeIntValue(pIn2);
+ u.aj.iB = sqlite3VdbeIntValue(pIn1);
+ u.aj.op = pOp->opcode;
+ if( u.aj.op==OP_BitAnd ){
+ u.aj.iA &= u.aj.iB;
+ }else if( u.aj.op==OP_BitOr ){
+ u.aj.iA |= u.aj.iB;
+ }else if( u.aj.iB!=0 ){
+ assert( u.aj.op==OP_ShiftRight || u.aj.op==OP_ShiftLeft );
/* If shifting by a negative amount, shift in the other direction */
- if( u.ah.iB<0 ){
+ if( u.aj.iB<0 ){
assert( OP_ShiftRight==OP_ShiftLeft+1 );
- u.ah.op = 2*OP_ShiftLeft + 1 - u.ah.op;
- u.ah.iB = u.ah.iB>(-64) ? -u.ah.iB : 64;
+ u.aj.op = 2*OP_ShiftLeft + 1 - u.aj.op;
+ u.aj.iB = u.aj.iB>(-64) ? -u.aj.iB : 64;
}
- if( u.ah.iB>=64 ){
- u.ah.iA = (u.ah.iA>=0 || u.ah.op==OP_ShiftLeft) ? 0 : -1;
+ if( u.aj.iB>=64 ){
+ u.aj.iA = (u.aj.iA>=0 || u.aj.op==OP_ShiftLeft) ? 0 : -1;
}else{
- memcpy(&u.ah.uA, &u.ah.iA, sizeof(u.ah.uA));
- if( u.ah.op==OP_ShiftLeft ){
- u.ah.uA <<= u.ah.iB;
+ memcpy(&u.aj.uA, &u.aj.iA, sizeof(u.aj.uA));
+ if( u.aj.op==OP_ShiftLeft ){
+ u.aj.uA <<= u.aj.iB;
}else{
- u.ah.uA >>= u.ah.iB;
+ u.aj.uA >>= u.aj.iB;
/* Sign-extend on a right shift of a negative number */
- if( u.ah.iA<0 ) u.ah.uA |= ((((u64)0xffffffff)<<32)|0xffffffff) << (64-u.ah.iB);
+ if( u.aj.iA<0 ) u.aj.uA |= ((((u64)0xffffffff)<<32)|0xffffffff) << (64-u.aj.iB);
}
- memcpy(&u.ah.iA, &u.ah.uA, sizeof(u.ah.iA));
+ memcpy(&u.aj.iA, &u.aj.uA, sizeof(u.aj.iA));
}
}
- pOut->u.i = u.ah.iA;
+ pOut->u.i = u.aj.iA;
MemSetTypeFlag(pOut, MEM_Int);
break;
}
@@ -64511,6 +65861,10 @@ case OP_ToReal: { /* same as TK_TO_REAL, in1 */
**
** If the SQLITE_STOREP2 bit of P5 is set, then do not jump. Instead,
** store a boolean result (either 0, or 1, or NULL) in register P2.
+**
+** If the SQLITE_NULLEQ bit is set in P5, then NULL values are considered
+** equal to one another, provided that they do not have their MEM_Cleared
+** bit set.
*/
/* Opcode: Ne P1 P2 P3 P4 P5
**
@@ -64560,18 +65914,18 @@ case OP_Lt: /* same as TK_LT, jump, in1, in3 */
case OP_Le: /* same as TK_LE, jump, in1, in3 */
case OP_Gt: /* same as TK_GT, jump, in1, in3 */
case OP_Ge: { /* same as TK_GE, jump, in1, in3 */
-#if 0 /* local variables moved into u.ai */
+#if 0 /* local variables moved into u.ak */
int res; /* Result of the comparison of pIn1 against pIn3 */
char affinity; /* Affinity to use for comparison */
u16 flags1; /* Copy of initial value of pIn1->flags */
u16 flags3; /* Copy of initial value of pIn3->flags */
-#endif /* local variables moved into u.ai */
+#endif /* local variables moved into u.ak */
pIn1 = &aMem[pOp->p1];
pIn3 = &aMem[pOp->p3];
- u.ai.flags1 = pIn1->flags;
- u.ai.flags3 = pIn3->flags;
- if( (u.ai.flags1 | u.ai.flags3)&MEM_Null ){
+ u.ak.flags1 = pIn1->flags;
+ u.ak.flags3 = pIn3->flags;
+ if( (u.ak.flags1 | u.ak.flags3)&MEM_Null ){
/* One or both operands are NULL */
if( pOp->p5 & SQLITE_NULLEQ ){
/* If SQLITE_NULLEQ is set (which will only happen if the operator is
@@ -64579,7 +65933,15 @@ case OP_Ge: { /* same as TK_GE, jump, in1, in3 */
** or not both operands are null.
*/
assert( pOp->opcode==OP_Eq || pOp->opcode==OP_Ne );
- u.ai.res = (u.ai.flags1 & u.ai.flags3 & MEM_Null)==0;
+ assert( (u.ak.flags1 & MEM_Cleared)==0 );
+ if( (u.ak.flags1&MEM_Null)!=0
+ && (u.ak.flags3&MEM_Null)!=0
+ && (u.ak.flags3&MEM_Cleared)==0
+ ){
+ u.ak.res = 0; /* Results are equal */
+ }else{
+ u.ak.res = 1; /* Results are not equal */
+ }
}else{
/* SQLITE_NULLEQ is clear and at least one operand is NULL,
** then the result is always NULL.
@@ -64596,40 +65958,40 @@ case OP_Ge: { /* same as TK_GE, jump, in1, in3 */
}
}else{
/* Neither operand is NULL. Do a comparison. */
- u.ai.affinity = pOp->p5 & SQLITE_AFF_MASK;
- if( u.ai.affinity ){
- applyAffinity(pIn1, u.ai.affinity, encoding);
- applyAffinity(pIn3, u.ai.affinity, encoding);
+ u.ak.affinity = pOp->p5 & SQLITE_AFF_MASK;
+ if( u.ak.affinity ){
+ applyAffinity(pIn1, u.ak.affinity, encoding);
+ applyAffinity(pIn3, u.ak.affinity, encoding);
if( db->mallocFailed ) goto no_mem;
}
assert( pOp->p4type==P4_COLLSEQ || pOp->p4.pColl==0 );
ExpandBlob(pIn1);
ExpandBlob(pIn3);
- u.ai.res = sqlite3MemCompare(pIn3, pIn1, pOp->p4.pColl);
+ u.ak.res = sqlite3MemCompare(pIn3, pIn1, pOp->p4.pColl);
}
switch( pOp->opcode ){
- case OP_Eq: u.ai.res = u.ai.res==0; break;
- case OP_Ne: u.ai.res = u.ai.res!=0; break;
- case OP_Lt: u.ai.res = u.ai.res<0; break;
- case OP_Le: u.ai.res = u.ai.res<=0; break;
- case OP_Gt: u.ai.res = u.ai.res>0; break;
- default: u.ai.res = u.ai.res>=0; break;
+ case OP_Eq: u.ak.res = u.ak.res==0; break;
+ case OP_Ne: u.ak.res = u.ak.res!=0; break;
+ case OP_Lt: u.ak.res = u.ak.res<0; break;
+ case OP_Le: u.ak.res = u.ak.res<=0; break;
+ case OP_Gt: u.ak.res = u.ak.res>0; break;
+ default: u.ak.res = u.ak.res>=0; break;
}
if( pOp->p5 & SQLITE_STOREP2 ){
pOut = &aMem[pOp->p2];
memAboutToChange(p, pOut);
MemSetTypeFlag(pOut, MEM_Int);
- pOut->u.i = u.ai.res;
+ pOut->u.i = u.ak.res;
REGISTER_TRACE(pOp->p2, pOut);
- }else if( u.ai.res ){
+ }else if( u.ak.res ){
pc = pOp->p2-1;
}
/* Undo any changes made by applyAffinity() to the input registers. */
- pIn1->flags = (pIn1->flags&~MEM_TypeMask) | (u.ai.flags1&MEM_TypeMask);
- pIn3->flags = (pIn3->flags&~MEM_TypeMask) | (u.ai.flags3&MEM_TypeMask);
+ pIn1->flags = (pIn1->flags&~MEM_TypeMask) | (u.ak.flags1&MEM_TypeMask);
+ pIn3->flags = (pIn3->flags&~MEM_TypeMask) | (u.ak.flags3&MEM_TypeMask);
break;
}
@@ -64638,9 +66000,9 @@ case OP_Ge: { /* same as TK_GE, jump, in1, in3 */
** Set the permutation used by the OP_Compare operator to be the array
** of integers in P4.
**
-** The permutation is only valid until the next OP_Permutation, OP_Compare,
-** OP_Halt, or OP_ResultRow. Typically the OP_Permutation should occur
-** immediately prior to the OP_Compare.
+** The permutation is only valid until the next OP_Compare that has
+** the OPFLAG_PERMUTE bit set in P5. Typically the OP_Permutation should
+** occur immediately prior to the OP_Compare.
*/
case OP_Permutation: {
assert( pOp->p4type==P4_INTARRAY );
@@ -64649,12 +66011,17 @@ case OP_Permutation: {
break;
}
-/* Opcode: Compare P1 P2 P3 P4 *
+/* Opcode: Compare P1 P2 P3 P4 P5
**
** Compare two vectors of registers in reg(P1)..reg(P1+P3-1) (call this
** vector "A") and in reg(P2)..reg(P2+P3-1) ("B"). Save the result of
** the comparison for use by the next OP_Jump instruct.
**
+** If P5 has the OPFLAG_PERMUTE bit set, then the order of comparison is
+** determined by the most recent OP_Permutation operator. If the
+** OPFLAG_PERMUTE bit is clear, then register are compared in sequential
+** order.
+**
** P4 is a KeyInfo structure that defines collating sequences and sort
** orders for the comparison. The permutation applies to registers
** only. The KeyInfo elements are used sequentially.
@@ -64664,7 +66031,7 @@ case OP_Permutation: {
** and strings are less than blobs.
*/
case OP_Compare: {
-#if 0 /* local variables moved into u.aj */
+#if 0 /* local variables moved into u.al */
int n;
int i;
int p1;
@@ -64673,37 +66040,38 @@ case OP_Compare: {
int idx;
CollSeq *pColl; /* Collating sequence to use on this term */
int bRev; /* True for DESCENDING sort order */
-#endif /* local variables moved into u.aj */
+#endif /* local variables moved into u.al */
- u.aj.n = pOp->p3;
- u.aj.pKeyInfo = pOp->p4.pKeyInfo;
- assert( u.aj.n>0 );
- assert( u.aj.pKeyInfo!=0 );
- u.aj.p1 = pOp->p1;
- u.aj.p2 = pOp->p2;
+ if( (pOp->p5 & OPFLAG_PERMUTE)==0 ) aPermute = 0;
+ u.al.n = pOp->p3;
+ u.al.pKeyInfo = pOp->p4.pKeyInfo;
+ assert( u.al.n>0 );
+ assert( u.al.pKeyInfo!=0 );
+ u.al.p1 = pOp->p1;
+ u.al.p2 = pOp->p2;
#if SQLITE_DEBUG
if( aPermute ){
int k, mx = 0;
- for(k=0; k<u.aj.n; k++) if( aPermute[k]>mx ) mx = aPermute[k];
- assert( u.aj.p1>0 && u.aj.p1+mx<=p->nMem+1 );
- assert( u.aj.p2>0 && u.aj.p2+mx<=p->nMem+1 );
+ for(k=0; k<u.al.n; k++) if( aPermute[k]>mx ) mx = aPermute[k];
+ assert( u.al.p1>0 && u.al.p1+mx<=p->nMem+1 );
+ assert( u.al.p2>0 && u.al.p2+mx<=p->nMem+1 );
}else{
- assert( u.aj.p1>0 && u.aj.p1+u.aj.n<=p->nMem+1 );
- assert( u.aj.p2>0 && u.aj.p2+u.aj.n<=p->nMem+1 );
+ assert( u.al.p1>0 && u.al.p1+u.al.n<=p->nMem+1 );
+ assert( u.al.p2>0 && u.al.p2+u.al.n<=p->nMem+1 );
}
#endif /* SQLITE_DEBUG */
- for(u.aj.i=0; u.aj.i<u.aj.n; u.aj.i++){
- u.aj.idx = aPermute ? aPermute[u.aj.i] : u.aj.i;
- assert( memIsValid(&aMem[u.aj.p1+u.aj.idx]) );
- assert( memIsValid(&aMem[u.aj.p2+u.aj.idx]) );
- REGISTER_TRACE(u.aj.p1+u.aj.idx, &aMem[u.aj.p1+u.aj.idx]);
- REGISTER_TRACE(u.aj.p2+u.aj.idx, &aMem[u.aj.p2+u.aj.idx]);
- assert( u.aj.i<u.aj.pKeyInfo->nField );
- u.aj.pColl = u.aj.pKeyInfo->aColl[u.aj.i];
- u.aj.bRev = u.aj.pKeyInfo->aSortOrder[u.aj.i];
- iCompare = sqlite3MemCompare(&aMem[u.aj.p1+u.aj.idx], &aMem[u.aj.p2+u.aj.idx], u.aj.pColl);
+ for(u.al.i=0; u.al.i<u.al.n; u.al.i++){
+ u.al.idx = aPermute ? aPermute[u.al.i] : u.al.i;
+ assert( memIsValid(&aMem[u.al.p1+u.al.idx]) );
+ assert( memIsValid(&aMem[u.al.p2+u.al.idx]) );
+ REGISTER_TRACE(u.al.p1+u.al.idx, &aMem[u.al.p1+u.al.idx]);
+ REGISTER_TRACE(u.al.p2+u.al.idx, &aMem[u.al.p2+u.al.idx]);
+ assert( u.al.i<u.al.pKeyInfo->nField );
+ u.al.pColl = u.al.pKeyInfo->aColl[u.al.i];
+ u.al.bRev = u.al.pKeyInfo->aSortOrder[u.al.i];
+ iCompare = sqlite3MemCompare(&aMem[u.al.p1+u.al.idx], &aMem[u.al.p2+u.al.idx], u.al.pColl);
if( iCompare ){
- if( u.aj.bRev ) iCompare = -iCompare;
+ if( u.al.bRev ) iCompare = -iCompare;
break;
}
}
@@ -64748,35 +66116,35 @@ case OP_Jump: { /* jump */
*/
case OP_And: /* same as TK_AND, in1, in2, out3 */
case OP_Or: { /* same as TK_OR, in1, in2, out3 */
-#if 0 /* local variables moved into u.ak */
+#if 0 /* local variables moved into u.am */
int v1; /* Left operand: 0==FALSE, 1==TRUE, 2==UNKNOWN or NULL */
int v2; /* Right operand: 0==FALSE, 1==TRUE, 2==UNKNOWN or NULL */
-#endif /* local variables moved into u.ak */
+#endif /* local variables moved into u.am */
pIn1 = &aMem[pOp->p1];
if( pIn1->flags & MEM_Null ){
- u.ak.v1 = 2;
+ u.am.v1 = 2;
}else{
- u.ak.v1 = sqlite3VdbeIntValue(pIn1)!=0;
+ u.am.v1 = sqlite3VdbeIntValue(pIn1)!=0;
}
pIn2 = &aMem[pOp->p2];
if( pIn2->flags & MEM_Null ){
- u.ak.v2 = 2;
+ u.am.v2 = 2;
}else{
- u.ak.v2 = sqlite3VdbeIntValue(pIn2)!=0;
+ u.am.v2 = sqlite3VdbeIntValue(pIn2)!=0;
}
if( pOp->opcode==OP_And ){
static const unsigned char and_logic[] = { 0, 0, 0, 0, 1, 2, 0, 2, 2 };
- u.ak.v1 = and_logic[u.ak.v1*3+u.ak.v2];
+ u.am.v1 = and_logic[u.am.v1*3+u.am.v2];
}else{
static const unsigned char or_logic[] = { 0, 1, 2, 1, 1, 1, 2, 1, 2 };
- u.ak.v1 = or_logic[u.ak.v1*3+u.ak.v2];
+ u.am.v1 = or_logic[u.am.v1*3+u.am.v2];
}
pOut = &aMem[pOp->p3];
- if( u.ak.v1==2 ){
+ if( u.am.v1==2 ){
MemSetTypeFlag(pOut, MEM_Null);
}else{
- pOut->u.i = u.ak.v1;
+ pOut->u.i = u.am.v1;
MemSetTypeFlag(pOut, MEM_Int);
}
break;
@@ -64816,35 +66184,50 @@ case OP_BitNot: { /* same as TK_BITNOT, in1, out2 */
break;
}
+/* Opcode: Once P1 P2 * * *
+**
+** Check if OP_Once flag P1 is set. If so, jump to instruction P2. Otherwise,
+** set the flag and fall through to the next instruction.
+*/
+case OP_Once: { /* jump */
+ assert( pOp->p1<p->nOnceFlag );
+ if( p->aOnceFlag[pOp->p1] ){
+ pc = pOp->p2-1;
+ }else{
+ p->aOnceFlag[pOp->p1] = 1;
+ }
+ break;
+}
+
/* Opcode: If P1 P2 P3 * *
**
** Jump to P2 if the value in register P1 is true. The value
** is considered true if it is numeric and non-zero. If the value
-** in P1 is NULL then take the jump if P3 is true.
+** in P1 is NULL then take the jump if P3 is non-zero.
*/
/* Opcode: IfNot P1 P2 P3 * *
**
** Jump to P2 if the value in register P1 is False. The value
-** is considered true if it has a numeric value of zero. If the value
-** in P1 is NULL then take the jump if P3 is true.
+** is considered false if it has a numeric value of zero. If the value
+** in P1 is NULL then take the jump if P3 is zero.
*/
case OP_If: /* jump, in1 */
case OP_IfNot: { /* jump, in1 */
-#if 0 /* local variables moved into u.al */
+#if 0 /* local variables moved into u.an */
int c;
-#endif /* local variables moved into u.al */
+#endif /* local variables moved into u.an */
pIn1 = &aMem[pOp->p1];
if( pIn1->flags & MEM_Null ){
- u.al.c = pOp->p3;
+ u.an.c = pOp->p3;
}else{
#ifdef SQLITE_OMIT_FLOATING_POINT
- u.al.c = sqlite3VdbeIntValue(pIn1)!=0;
+ u.an.c = sqlite3VdbeIntValue(pIn1)!=0;
#else
- u.al.c = sqlite3VdbeRealValue(pIn1)!=0.0;
+ u.an.c = sqlite3VdbeRealValue(pIn1)!=0.0;
#endif
- if( pOp->opcode==OP_IfNot ) u.al.c = !u.al.c;
+ if( pOp->opcode==OP_IfNot ) u.an.c = !u.an.c;
}
- if( u.al.c ){
+ if( u.an.c ){
pc = pOp->p2-1;
}
break;
@@ -64892,9 +66275,14 @@ case OP_NotNull: { /* same as TK_NOTNULL, jump, in1 */
** then the cache of the cursor is reset prior to extracting the column.
** The first OP_Column against a pseudo-table after the value of the content
** register has changed should have this bit set.
+**
+** If the OPFLAG_LENGTHARG and OPFLAG_TYPEOFARG bits are set on P5 when
+** the result is guaranteed to only be used as the argument of a length()
+** or typeof() function, respectively. The loading of large blobs can be
+** skipped for length() and all content loading can be skipped for typeof().
*/
case OP_Column: {
-#if 0 /* local variables moved into u.am */
+#if 0 /* local variables moved into u.ao */
u32 payloadSize; /* Number of bytes in the record */
i64 payloadSize64; /* Number of bytes in the record */
int p1; /* P1 value of the opcode */
@@ -64916,127 +66304,133 @@ case OP_Column: {
u32 szField; /* Number of bytes in the content of a field */
int szHdr; /* Size of the header size field at start of record */
int avail; /* Number of bytes of available data */
+ u32 t; /* A type code from the record header */
Mem *pReg; /* PseudoTable input register */
-#endif /* local variables moved into u.am */
+#endif /* local variables moved into u.ao */
- u.am.p1 = pOp->p1;
- u.am.p2 = pOp->p2;
- u.am.pC = 0;
- memset(&u.am.sMem, 0, sizeof(u.am.sMem));
- assert( u.am.p1<p->nCursor );
+ u.ao.p1 = pOp->p1;
+ u.ao.p2 = pOp->p2;
+ u.ao.pC = 0;
+ memset(&u.ao.sMem, 0, sizeof(u.ao.sMem));
+ assert( u.ao.p1<p->nCursor );
assert( pOp->p3>0 && pOp->p3<=p->nMem );
- u.am.pDest = &aMem[pOp->p3];
- memAboutToChange(p, u.am.pDest);
- MemSetTypeFlag(u.am.pDest, MEM_Null);
- u.am.zRec = 0;
+ u.ao.pDest = &aMem[pOp->p3];
+ memAboutToChange(p, u.ao.pDest);
+ u.ao.zRec = 0;
- /* This block sets the variable u.am.payloadSize to be the total number of
+ /* This block sets the variable u.ao.payloadSize to be the total number of
** bytes in the record.
**
- ** u.am.zRec is set to be the complete text of the record if it is available.
+ ** u.ao.zRec is set to be the complete text of the record if it is available.
** The complete record text is always available for pseudo-tables
** If the record is stored in a cursor, the complete record text
- ** might be available in the u.am.pC->aRow cache. Or it might not be.
- ** If the data is unavailable, u.am.zRec is set to NULL.
+ ** might be available in the u.ao.pC->aRow cache. Or it might not be.
+ ** If the data is unavailable, u.ao.zRec is set to NULL.
**
** We also compute the number of columns in the record. For cursors,
** the number of columns is stored in the VdbeCursor.nField element.
*/
- u.am.pC = p->apCsr[u.am.p1];
- assert( u.am.pC!=0 );
+ u.ao.pC = p->apCsr[u.ao.p1];
+ assert( u.ao.pC!=0 );
#ifndef SQLITE_OMIT_VIRTUALTABLE
- assert( u.am.pC->pVtabCursor==0 );
+ assert( u.ao.pC->pVtabCursor==0 );
#endif
- u.am.pCrsr = u.am.pC->pCursor;
- if( u.am.pCrsr!=0 ){
+ u.ao.pCrsr = u.ao.pC->pCursor;
+ if( u.ao.pCrsr!=0 ){
/* The record is stored in a B-Tree */
- rc = sqlite3VdbeCursorMoveto(u.am.pC);
+ rc = sqlite3VdbeCursorMoveto(u.ao.pC);
if( rc ) goto abort_due_to_error;
- if( u.am.pC->nullRow ){
- u.am.payloadSize = 0;
- }else if( u.am.pC->cacheStatus==p->cacheCtr ){
- u.am.payloadSize = u.am.pC->payloadSize;
- u.am.zRec = (char*)u.am.pC->aRow;
- }else if( u.am.pC->isIndex ){
- assert( sqlite3BtreeCursorIsValid(u.am.pCrsr) );
- rc = sqlite3BtreeKeySize(u.am.pCrsr, &u.am.payloadSize64);
+ if( u.ao.pC->nullRow ){
+ u.ao.payloadSize = 0;
+ }else if( u.ao.pC->cacheStatus==p->cacheCtr ){
+ u.ao.payloadSize = u.ao.pC->payloadSize;
+ u.ao.zRec = (char*)u.ao.pC->aRow;
+ }else if( u.ao.pC->isIndex ){
+ assert( sqlite3BtreeCursorIsValid(u.ao.pCrsr) );
+ VVA_ONLY(rc =) sqlite3BtreeKeySize(u.ao.pCrsr, &u.ao.payloadSize64);
assert( rc==SQLITE_OK ); /* True because of CursorMoveto() call above */
/* sqlite3BtreeParseCellPtr() uses getVarint32() to extract the
- ** payload size, so it is impossible for u.am.payloadSize64 to be
+ ** payload size, so it is impossible for u.ao.payloadSize64 to be
** larger than 32 bits. */
- assert( (u.am.payloadSize64 & SQLITE_MAX_U32)==(u64)u.am.payloadSize64 );
- u.am.payloadSize = (u32)u.am.payloadSize64;
+ assert( (u.ao.payloadSize64 & SQLITE_MAX_U32)==(u64)u.ao.payloadSize64 );
+ u.ao.payloadSize = (u32)u.ao.payloadSize64;
}else{
- assert( sqlite3BtreeCursorIsValid(u.am.pCrsr) );
- rc = sqlite3BtreeDataSize(u.am.pCrsr, &u.am.payloadSize);
+ assert( sqlite3BtreeCursorIsValid(u.ao.pCrsr) );
+ VVA_ONLY(rc =) sqlite3BtreeDataSize(u.ao.pCrsr, &u.ao.payloadSize);
assert( rc==SQLITE_OK ); /* DataSize() cannot fail */
}
- }else if( u.am.pC->pseudoTableReg>0 ){
- u.am.pReg = &aMem[u.am.pC->pseudoTableReg];
- assert( u.am.pReg->flags & MEM_Blob );
- assert( memIsValid(u.am.pReg) );
- u.am.payloadSize = u.am.pReg->n;
- u.am.zRec = u.am.pReg->z;
- u.am.pC->cacheStatus = (pOp->p5&OPFLAG_CLEARCACHE) ? CACHE_STALE : p->cacheCtr;
- assert( u.am.payloadSize==0 || u.am.zRec!=0 );
+ }else if( ALWAYS(u.ao.pC->pseudoTableReg>0) ){
+ u.ao.pReg = &aMem[u.ao.pC->pseudoTableReg];
+ if( u.ao.pC->multiPseudo ){
+ sqlite3VdbeMemShallowCopy(u.ao.pDest, u.ao.pReg+u.ao.p2, MEM_Ephem);
+ Deephemeralize(u.ao.pDest);
+ goto op_column_out;
+ }
+ assert( u.ao.pReg->flags & MEM_Blob );
+ assert( memIsValid(u.ao.pReg) );
+ u.ao.payloadSize = u.ao.pReg->n;
+ u.ao.zRec = u.ao.pReg->z;
+ u.ao.pC->cacheStatus = (pOp->p5&OPFLAG_CLEARCACHE) ? CACHE_STALE : p->cacheCtr;
+ assert( u.ao.payloadSize==0 || u.ao.zRec!=0 );
}else{
/* Consider the row to be NULL */
- u.am.payloadSize = 0;
+ u.ao.payloadSize = 0;
}
- /* If u.am.payloadSize is 0, then just store a NULL */
- if( u.am.payloadSize==0 ){
- assert( u.am.pDest->flags&MEM_Null );
+ /* If u.ao.payloadSize is 0, then just store a NULL. This can happen because of
+ ** nullRow or because of a corrupt database. */
+ if( u.ao.payloadSize==0 ){
+ MemSetTypeFlag(u.ao.pDest, MEM_Null);
goto op_column_out;
}
assert( db->aLimit[SQLITE_LIMIT_LENGTH]>=0 );
- if( u.am.payloadSize > (u32)db->aLimit[SQLITE_LIMIT_LENGTH] ){
+ if( u.ao.payloadSize > (u32)db->aLimit[SQLITE_LIMIT_LENGTH] ){
goto too_big;
}
- u.am.nField = u.am.pC->nField;
- assert( u.am.p2<u.am.nField );
+ u.ao.nField = u.ao.pC->nField;
+ assert( u.ao.p2<u.ao.nField );
/* Read and parse the table header. Store the results of the parse
** into the record header cache fields of the cursor.
*/
- u.am.aType = u.am.pC->aType;
- if( u.am.pC->cacheStatus==p->cacheCtr ){
- u.am.aOffset = u.am.pC->aOffset;
+ u.ao.aType = u.ao.pC->aType;
+ if( u.ao.pC->cacheStatus==p->cacheCtr ){
+ u.ao.aOffset = u.ao.pC->aOffset;
}else{
- assert(u.am.aType);
- u.am.avail = 0;
- u.am.pC->aOffset = u.am.aOffset = &u.am.aType[u.am.nField];
- u.am.pC->payloadSize = u.am.payloadSize;
- u.am.pC->cacheStatus = p->cacheCtr;
+ assert(u.ao.aType);
+ u.ao.avail = 0;
+ u.ao.pC->aOffset = u.ao.aOffset = &u.ao.aType[u.ao.nField];
+ u.ao.pC->payloadSize = u.ao.payloadSize;
+ u.ao.pC->cacheStatus = p->cacheCtr;
/* Figure out how many bytes are in the header */
- if( u.am.zRec ){
- u.am.zData = u.am.zRec;
+ if( u.ao.zRec ){
+ u.ao.zData = u.ao.zRec;
}else{
- if( u.am.pC->isIndex ){
- u.am.zData = (char*)sqlite3BtreeKeyFetch(u.am.pCrsr, &u.am.avail);
+ if( u.ao.pC->isIndex ){
+ u.ao.zData = (char*)sqlite3BtreeKeyFetch(u.ao.pCrsr, &u.ao.avail);
}else{
- u.am.zData = (char*)sqlite3BtreeDataFetch(u.am.pCrsr, &u.am.avail);
+ u.ao.zData = (char*)sqlite3BtreeDataFetch(u.ao.pCrsr, &u.ao.avail);
}
/* If KeyFetch()/DataFetch() managed to get the entire payload,
- ** save the payload in the u.am.pC->aRow cache. That will save us from
+ ** save the payload in the u.ao.pC->aRow cache. That will save us from
** having to make additional calls to fetch the content portion of
** the record.
*/
- assert( u.am.avail>=0 );
- if( u.am.payloadSize <= (u32)u.am.avail ){
- u.am.zRec = u.am.zData;
- u.am.pC->aRow = (u8*)u.am.zData;
+ assert( u.ao.avail>=0 );
+ if( u.ao.payloadSize <= (u32)u.ao.avail ){
+ u.ao.zRec = u.ao.zData;
+ u.ao.pC->aRow = (u8*)u.ao.zData;
}else{
- u.am.pC->aRow = 0;
+ u.ao.pC->aRow = 0;
}
}
- /* The following assert is true in all cases accept when
+ /* The following assert is true in all cases except when
** the database file has been corrupted externally.
- ** assert( u.am.zRec!=0 || u.am.avail>=u.am.payloadSize || u.am.avail>=9 ); */
- u.am.szHdr = getVarint32((u8*)u.am.zData, u.am.offset);
+ ** assert( u.ao.zRec!=0 || u.ao.avail>=u.ao.payloadSize || u.ao.avail>=9 ); */
+ u.ao.szHdr = getVarint32((u8*)u.ao.zData, u.ao.offset);
/* Make sure a corrupt database has not given us an oversize header.
** Do this now to avoid an oversize memory allocation.
@@ -65047,26 +66441,26 @@ case OP_Column: {
** 3-byte type for each of the maximum of 32768 columns plus three
** extra bytes for the header length itself. 32768*3 + 3 = 98307.
*/
- if( u.am.offset > 98307 ){
+ if( u.ao.offset > 98307 ){
rc = SQLITE_CORRUPT_BKPT;
goto op_column_out;
}
- /* Compute in u.am.len the number of bytes of data we need to read in order
- ** to get u.am.nField type values. u.am.offset is an upper bound on this. But
- ** u.am.nField might be significantly less than the true number of columns
- ** in the table, and in that case, 5*u.am.nField+3 might be smaller than u.am.offset.
- ** We want to minimize u.am.len in order to limit the size of the memory
- ** allocation, especially if a corrupt database file has caused u.am.offset
+ /* Compute in u.ao.len the number of bytes of data we need to read in order
+ ** to get u.ao.nField type values. u.ao.offset is an upper bound on this. But
+ ** u.ao.nField might be significantly less than the true number of columns
+ ** in the table, and in that case, 5*u.ao.nField+3 might be smaller than u.ao.offset.
+ ** We want to minimize u.ao.len in order to limit the size of the memory
+ ** allocation, especially if a corrupt database file has caused u.ao.offset
** to be oversized. Offset is limited to 98307 above. But 98307 might
** still exceed Robson memory allocation limits on some configurations.
- ** On systems that cannot tolerate large memory allocations, u.am.nField*5+3
- ** will likely be much smaller since u.am.nField will likely be less than
+ ** On systems that cannot tolerate large memory allocations, u.ao.nField*5+3
+ ** will likely be much smaller since u.ao.nField will likely be less than
** 20 or so. This insures that Robson memory allocation limits are
** not exceeded even for corrupt database files.
*/
- u.am.len = u.am.nField*5 + 3;
- if( u.am.len > (int)u.am.offset ) u.am.len = (int)u.am.offset;
+ u.ao.len = u.ao.nField*5 + 3;
+ if( u.ao.len > (int)u.ao.offset ) u.ao.len = (int)u.ao.offset;
/* The KeyFetch() or DataFetch() above are fast and will get the entire
** record header in most cases. But they will fail to get the complete
@@ -65074,45 +66468,51 @@ case OP_Column: {
** in the B-Tree. When that happens, use sqlite3VdbeMemFromBtree() to
** acquire the complete header text.
*/
- if( !u.am.zRec && u.am.avail<u.am.len ){
- u.am.sMem.flags = 0;
- u.am.sMem.db = 0;
- rc = sqlite3VdbeMemFromBtree(u.am.pCrsr, 0, u.am.len, u.am.pC->isIndex, &u.am.sMem);
+ if( !u.ao.zRec && u.ao.avail<u.ao.len ){
+ u.ao.sMem.flags = 0;
+ u.ao.sMem.db = 0;
+ rc = sqlite3VdbeMemFromBtree(u.ao.pCrsr, 0, u.ao.len, u.ao.pC->isIndex, &u.ao.sMem);
if( rc!=SQLITE_OK ){
goto op_column_out;
}
- u.am.zData = u.am.sMem.z;
+ u.ao.zData = u.ao.sMem.z;
}
- u.am.zEndHdr = (u8 *)&u.am.zData[u.am.len];
- u.am.zIdx = (u8 *)&u.am.zData[u.am.szHdr];
+ u.ao.zEndHdr = (u8 *)&u.ao.zData[u.ao.len];
+ u.ao.zIdx = (u8 *)&u.ao.zData[u.ao.szHdr];
- /* Scan the header and use it to fill in the u.am.aType[] and u.am.aOffset[]
- ** arrays. u.am.aType[u.am.i] will contain the type integer for the u.am.i-th
- ** column and u.am.aOffset[u.am.i] will contain the u.am.offset from the beginning
- ** of the record to the start of the data for the u.am.i-th column
+ /* Scan the header and use it to fill in the u.ao.aType[] and u.ao.aOffset[]
+ ** arrays. u.ao.aType[u.ao.i] will contain the type integer for the u.ao.i-th
+ ** column and u.ao.aOffset[u.ao.i] will contain the u.ao.offset from the beginning
+ ** of the record to the start of the data for the u.ao.i-th column
*/
- for(u.am.i=0; u.am.i<u.am.nField; u.am.i++){
- if( u.am.zIdx<u.am.zEndHdr ){
- u.am.aOffset[u.am.i] = u.am.offset;
- u.am.zIdx += getVarint32(u.am.zIdx, u.am.aType[u.am.i]);
- u.am.szField = sqlite3VdbeSerialTypeLen(u.am.aType[u.am.i]);
- u.am.offset += u.am.szField;
- if( u.am.offset<u.am.szField ){ /* True if u.am.offset overflows */
- u.am.zIdx = &u.am.zEndHdr[1]; /* Forces SQLITE_CORRUPT return below */
+ for(u.ao.i=0; u.ao.i<u.ao.nField; u.ao.i++){
+ if( u.ao.zIdx<u.ao.zEndHdr ){
+ u.ao.aOffset[u.ao.i] = u.ao.offset;
+ if( u.ao.zIdx[0]<0x80 ){
+ u.ao.t = u.ao.zIdx[0];
+ u.ao.zIdx++;
+ }else{
+ u.ao.zIdx += sqlite3GetVarint32(u.ao.zIdx, &u.ao.t);
+ }
+ u.ao.aType[u.ao.i] = u.ao.t;
+ u.ao.szField = sqlite3VdbeSerialTypeLen(u.ao.t);
+ u.ao.offset += u.ao.szField;
+ if( u.ao.offset<u.ao.szField ){ /* True if u.ao.offset overflows */
+ u.ao.zIdx = &u.ao.zEndHdr[1]; /* Forces SQLITE_CORRUPT return below */
break;
}
}else{
- /* If u.am.i is less that u.am.nField, then there are less fields in this
+ /* If u.ao.i is less that u.ao.nField, then there are fewer fields in this
** record than SetNumColumns indicated there are columns in the
- ** table. Set the u.am.offset for any extra columns not present in
- ** the record to 0. This tells code below to store a NULL
- ** instead of deserializing a value from the record.
+ ** table. Set the u.ao.offset for any extra columns not present in
+ ** the record to 0. This tells code below to store the default value
+ ** for the column instead of deserializing a value from the record.
*/
- u.am.aOffset[u.am.i] = 0;
+ u.ao.aOffset[u.ao.i] = 0;
}
}
- sqlite3VdbeMemRelease(&u.am.sMem);
- u.am.sMem.flags = MEM_Null;
+ sqlite3VdbeMemRelease(&u.ao.sMem);
+ u.ao.sMem.flags = MEM_Null;
/* If we have read more header data than was contained in the header,
** or if the end of the last field appears to be past the end of the
@@ -65120,63 +66520,78 @@ case OP_Column: {
** of the record (when all fields present), then we must be dealing
** with a corrupt database.
*/
- if( (u.am.zIdx > u.am.zEndHdr) || (u.am.offset > u.am.payloadSize)
- || (u.am.zIdx==u.am.zEndHdr && u.am.offset!=u.am.payloadSize) ){
+ if( (u.ao.zIdx > u.ao.zEndHdr) || (u.ao.offset > u.ao.payloadSize)
+ || (u.ao.zIdx==u.ao.zEndHdr && u.ao.offset!=u.ao.payloadSize) ){
rc = SQLITE_CORRUPT_BKPT;
goto op_column_out;
}
}
- /* Get the column information. If u.am.aOffset[u.am.p2] is non-zero, then
- ** deserialize the value from the record. If u.am.aOffset[u.am.p2] is zero,
+ /* Get the column information. If u.ao.aOffset[u.ao.p2] is non-zero, then
+ ** deserialize the value from the record. If u.ao.aOffset[u.ao.p2] is zero,
** then there are not enough fields in the record to satisfy the
** request. In this case, set the value NULL or to P4 if P4 is
** a pointer to a Mem object.
*/
- if( u.am.aOffset[u.am.p2] ){
+ if( u.ao.aOffset[u.ao.p2] ){
assert( rc==SQLITE_OK );
- if( u.am.zRec ){
- sqlite3VdbeMemReleaseExternal(u.am.pDest);
- sqlite3VdbeSerialGet((u8 *)&u.am.zRec[u.am.aOffset[u.am.p2]], u.am.aType[u.am.p2], u.am.pDest);
+ if( u.ao.zRec ){
+ /* This is the common case where the whole row fits on a single page */
+ VdbeMemRelease(u.ao.pDest);
+ sqlite3VdbeSerialGet((u8 *)&u.ao.zRec[u.ao.aOffset[u.ao.p2]], u.ao.aType[u.ao.p2], u.ao.pDest);
}else{
- u.am.len = sqlite3VdbeSerialTypeLen(u.am.aType[u.am.p2]);
- sqlite3VdbeMemMove(&u.am.sMem, u.am.pDest);
- rc = sqlite3VdbeMemFromBtree(u.am.pCrsr, u.am.aOffset[u.am.p2], u.am.len, u.am.pC->isIndex, &u.am.sMem);
- if( rc!=SQLITE_OK ){
- goto op_column_out;
+ /* This branch happens only when the row overflows onto multiple pages */
+ u.ao.t = u.ao.aType[u.ao.p2];
+ if( (pOp->p5 & (OPFLAG_LENGTHARG|OPFLAG_TYPEOFARG))!=0
+ && ((u.ao.t>=12 && (u.ao.t&1)==0) || (pOp->p5 & OPFLAG_TYPEOFARG)!=0)
+ ){
+ /* Content is irrelevant for the typeof() function and for
+ ** the length(X) function if X is a blob. So we might as well use
+ ** bogus content rather than reading content from disk. NULL works
+ ** for text and blob and whatever is in the u.ao.payloadSize64 variable
+ ** will work for everything else. */
+ u.ao.zData = u.ao.t<12 ? (char*)&u.ao.payloadSize64 : 0;
+ }else{
+ u.ao.len = sqlite3VdbeSerialTypeLen(u.ao.t);
+ sqlite3VdbeMemMove(&u.ao.sMem, u.ao.pDest);
+ rc = sqlite3VdbeMemFromBtree(u.ao.pCrsr, u.ao.aOffset[u.ao.p2], u.ao.len, u.ao.pC->isIndex,
+ &u.ao.sMem);
+ if( rc!=SQLITE_OK ){
+ goto op_column_out;
+ }
+ u.ao.zData = u.ao.sMem.z;
}
- u.am.zData = u.am.sMem.z;
- sqlite3VdbeSerialGet((u8*)u.am.zData, u.am.aType[u.am.p2], u.am.pDest);
+ sqlite3VdbeSerialGet((u8*)u.ao.zData, u.ao.t, u.ao.pDest);
}
- u.am.pDest->enc = encoding;
+ u.ao.pDest->enc = encoding;
}else{
if( pOp->p4type==P4_MEM ){
- sqlite3VdbeMemShallowCopy(u.am.pDest, pOp->p4.pMem, MEM_Static);
+ sqlite3VdbeMemShallowCopy(u.ao.pDest, pOp->p4.pMem, MEM_Static);
}else{
- assert( u.am.pDest->flags&MEM_Null );
+ MemSetTypeFlag(u.ao.pDest, MEM_Null);
}
}
/* If we dynamically allocated space to hold the data (in the
** sqlite3VdbeMemFromBtree() call above) then transfer control of that
- ** dynamically allocated space over to the u.am.pDest structure.
+ ** dynamically allocated space over to the u.ao.pDest structure.
** This prevents a memory copy.
*/
- if( u.am.sMem.zMalloc ){
- assert( u.am.sMem.z==u.am.sMem.zMalloc );
- assert( !(u.am.pDest->flags & MEM_Dyn) );
- assert( !(u.am.pDest->flags & (MEM_Blob|MEM_Str)) || u.am.pDest->z==u.am.sMem.z );
- u.am.pDest->flags &= ~(MEM_Ephem|MEM_Static);
- u.am.pDest->flags |= MEM_Term;
- u.am.pDest->z = u.am.sMem.z;
- u.am.pDest->zMalloc = u.am.sMem.zMalloc;
+ if( u.ao.sMem.zMalloc ){
+ assert( u.ao.sMem.z==u.ao.sMem.zMalloc );
+ assert( !(u.ao.pDest->flags & MEM_Dyn) );
+ assert( !(u.ao.pDest->flags & (MEM_Blob|MEM_Str)) || u.ao.pDest->z==u.ao.sMem.z );
+ u.ao.pDest->flags &= ~(MEM_Ephem|MEM_Static);
+ u.ao.pDest->flags |= MEM_Term;
+ u.ao.pDest->z = u.ao.sMem.z;
+ u.ao.pDest->zMalloc = u.ao.sMem.zMalloc;
}
- rc = sqlite3VdbeMemMakeWriteable(u.am.pDest);
+ rc = sqlite3VdbeMemMakeWriteable(u.ao.pDest);
op_column_out:
- UPDATE_MAX_BLOBSIZE(u.am.pDest);
- REGISTER_TRACE(pOp->p3, u.am.pDest);
+ UPDATE_MAX_BLOBSIZE(u.ao.pDest);
+ REGISTER_TRACE(pOp->p3, u.ao.pDest);
break;
}
@@ -65189,20 +66604,20 @@ op_column_out:
** memory cell in the range.
*/
case OP_Affinity: {
-#if 0 /* local variables moved into u.an */
+#if 0 /* local variables moved into u.ap */
const char *zAffinity; /* The affinity to be applied */
char cAff; /* A single character of affinity */
-#endif /* local variables moved into u.an */
+#endif /* local variables moved into u.ap */
- u.an.zAffinity = pOp->p4.z;
- assert( u.an.zAffinity!=0 );
- assert( u.an.zAffinity[pOp->p2]==0 );
+ u.ap.zAffinity = pOp->p4.z;
+ assert( u.ap.zAffinity!=0 );
+ assert( u.ap.zAffinity[pOp->p2]==0 );
pIn1 = &aMem[pOp->p1];
- while( (u.an.cAff = *(u.an.zAffinity++))!=0 ){
+ while( (u.ap.cAff = *(u.ap.zAffinity++))!=0 ){
assert( pIn1 <= &p->aMem[p->nMem] );
assert( memIsValid(pIn1) );
ExpandBlob(pIn1);
- applyAffinity(pIn1, u.an.cAff, encoding);
+ applyAffinity(pIn1, u.ap.cAff, encoding);
pIn1++;
}
break;
@@ -65224,7 +66639,7 @@ case OP_Affinity: {
** If P4 is NULL then all index fields have the affinity NONE.
*/
case OP_MakeRecord: {
-#if 0 /* local variables moved into u.ao */
+#if 0 /* local variables moved into u.aq */
u8 *zNewRecord; /* A buffer to hold the data for the new record */
Mem *pRec; /* The new record */
u64 nData; /* Number of bytes of data space */
@@ -65240,7 +66655,7 @@ case OP_MakeRecord: {
int file_format; /* File format to use for encoding */
int i; /* Space used in zNewRecord[] */
int len; /* Length of a field */
-#endif /* local variables moved into u.ao */
+#endif /* local variables moved into u.aq */
/* Assuming the record contains N fields, the record format looks
** like this:
@@ -65257,16 +66672,16 @@ case OP_MakeRecord: {
** hdr-size field is also a varint which is the offset from the beginning
** of the record to data0.
*/
- u.ao.nData = 0; /* Number of bytes of data space */
- u.ao.nHdr = 0; /* Number of bytes of header space */
- u.ao.nZero = 0; /* Number of zero bytes at the end of the record */
- u.ao.nField = pOp->p1;
- u.ao.zAffinity = pOp->p4.z;
- assert( u.ao.nField>0 && pOp->p2>0 && pOp->p2+u.ao.nField<=p->nMem+1 );
- u.ao.pData0 = &aMem[u.ao.nField];
- u.ao.nField = pOp->p2;
- u.ao.pLast = &u.ao.pData0[u.ao.nField-1];
- u.ao.file_format = p->minWriteFileFormat;
+ u.aq.nData = 0; /* Number of bytes of data space */
+ u.aq.nHdr = 0; /* Number of bytes of header space */
+ u.aq.nZero = 0; /* Number of zero bytes at the end of the record */
+ u.aq.nField = pOp->p1;
+ u.aq.zAffinity = pOp->p4.z;
+ assert( u.aq.nField>0 && pOp->p2>0 && pOp->p2+u.aq.nField<=p->nMem+1 );
+ u.aq.pData0 = &aMem[u.aq.nField];
+ u.aq.nField = pOp->p2;
+ u.aq.pLast = &u.aq.pData0[u.aq.nField-1];
+ u.aq.file_format = p->minWriteFileFormat;
/* Identify the output register */
assert( pOp->p3<pOp->p1 || pOp->p3>=pOp->p1+pOp->p2 );
@@ -65276,34 +66691,34 @@ case OP_MakeRecord: {
/* Loop through the elements that will make up the record to figure
** out how much space is required for the new record.
*/
- for(u.ao.pRec=u.ao.pData0; u.ao.pRec<=u.ao.pLast; u.ao.pRec++){
- assert( memIsValid(u.ao.pRec) );
- if( u.ao.zAffinity ){
- applyAffinity(u.ao.pRec, u.ao.zAffinity[u.ao.pRec-u.ao.pData0], encoding);
+ for(u.aq.pRec=u.aq.pData0; u.aq.pRec<=u.aq.pLast; u.aq.pRec++){
+ assert( memIsValid(u.aq.pRec) );
+ if( u.aq.zAffinity ){
+ applyAffinity(u.aq.pRec, u.aq.zAffinity[u.aq.pRec-u.aq.pData0], encoding);
}
- if( u.ao.pRec->flags&MEM_Zero && u.ao.pRec->n>0 ){
- sqlite3VdbeMemExpandBlob(u.ao.pRec);
+ if( u.aq.pRec->flags&MEM_Zero && u.aq.pRec->n>0 ){
+ sqlite3VdbeMemExpandBlob(u.aq.pRec);
}
- u.ao.serial_type = sqlite3VdbeSerialType(u.ao.pRec, u.ao.file_format);
- u.ao.len = sqlite3VdbeSerialTypeLen(u.ao.serial_type);
- u.ao.nData += u.ao.len;
- u.ao.nHdr += sqlite3VarintLen(u.ao.serial_type);
- if( u.ao.pRec->flags & MEM_Zero ){
+ u.aq.serial_type = sqlite3VdbeSerialType(u.aq.pRec, u.aq.file_format);
+ u.aq.len = sqlite3VdbeSerialTypeLen(u.aq.serial_type);
+ u.aq.nData += u.aq.len;
+ u.aq.nHdr += sqlite3VarintLen(u.aq.serial_type);
+ if( u.aq.pRec->flags & MEM_Zero ){
/* Only pure zero-filled BLOBs can be input to this Opcode.
** We do not allow blobs with a prefix and a zero-filled tail. */
- u.ao.nZero += u.ao.pRec->u.nZero;
- }else if( u.ao.len ){
- u.ao.nZero = 0;
+ u.aq.nZero += u.aq.pRec->u.nZero;
+ }else if( u.aq.len ){
+ u.aq.nZero = 0;
}
}
/* Add the initial header varint and total the size */
- u.ao.nHdr += u.ao.nVarint = sqlite3VarintLen(u.ao.nHdr);
- if( u.ao.nVarint<sqlite3VarintLen(u.ao.nHdr) ){
- u.ao.nHdr++;
+ u.aq.nHdr += u.aq.nVarint = sqlite3VarintLen(u.aq.nHdr);
+ if( u.aq.nVarint<sqlite3VarintLen(u.aq.nHdr) ){
+ u.aq.nHdr++;
}
- u.ao.nByte = u.ao.nHdr+u.ao.nData-u.ao.nZero;
- if( u.ao.nByte>db->aLimit[SQLITE_LIMIT_LENGTH] ){
+ u.aq.nByte = u.aq.nHdr+u.aq.nData-u.aq.nZero;
+ if( u.aq.nByte>db->aLimit[SQLITE_LIMIT_LENGTH] ){
goto too_big;
}
@@ -65312,28 +66727,28 @@ case OP_MakeRecord: {
** be one of the input registers (because the following call to
** sqlite3VdbeMemGrow() could clobber the value before it is used).
*/
- if( sqlite3VdbeMemGrow(pOut, (int)u.ao.nByte, 0) ){
+ if( sqlite3VdbeMemGrow(pOut, (int)u.aq.nByte, 0) ){
goto no_mem;
}
- u.ao.zNewRecord = (u8 *)pOut->z;
+ u.aq.zNewRecord = (u8 *)pOut->z;
/* Write the record */
- u.ao.i = putVarint32(u.ao.zNewRecord, u.ao.nHdr);
- for(u.ao.pRec=u.ao.pData0; u.ao.pRec<=u.ao.pLast; u.ao.pRec++){
- u.ao.serial_type = sqlite3VdbeSerialType(u.ao.pRec, u.ao.file_format);
- u.ao.i += putVarint32(&u.ao.zNewRecord[u.ao.i], u.ao.serial_type); /* serial type */
+ u.aq.i = putVarint32(u.aq.zNewRecord, u.aq.nHdr);
+ for(u.aq.pRec=u.aq.pData0; u.aq.pRec<=u.aq.pLast; u.aq.pRec++){
+ u.aq.serial_type = sqlite3VdbeSerialType(u.aq.pRec, u.aq.file_format);
+ u.aq.i += putVarint32(&u.aq.zNewRecord[u.aq.i], u.aq.serial_type); /* serial type */
}
- for(u.ao.pRec=u.ao.pData0; u.ao.pRec<=u.ao.pLast; u.ao.pRec++){ /* serial data */
- u.ao.i += sqlite3VdbeSerialPut(&u.ao.zNewRecord[u.ao.i], (int)(u.ao.nByte-u.ao.i), u.ao.pRec,u.ao.file_format);
+ for(u.aq.pRec=u.aq.pData0; u.aq.pRec<=u.aq.pLast; u.aq.pRec++){ /* serial data */
+ u.aq.i += sqlite3VdbeSerialPut(&u.aq.zNewRecord[u.aq.i], (int)(u.aq.nByte-u.aq.i), u.aq.pRec,u.aq.file_format);
}
- assert( u.ao.i==u.ao.nByte );
+ assert( u.aq.i==u.aq.nByte );
assert( pOp->p3>0 && pOp->p3<=p->nMem );
- pOut->n = (int)u.ao.nByte;
+ pOut->n = (int)u.aq.nByte;
pOut->flags = MEM_Blob | MEM_Dyn;
pOut->xDel = 0;
- if( u.ao.nZero ){
- pOut->u.nZero = u.ao.nZero;
+ if( u.aq.nZero ){
+ pOut->u.nZero = u.aq.nZero;
pOut->flags |= MEM_Zero;
}
pOut->enc = SQLITE_UTF8; /* In case the blob is ever converted to text */
@@ -65349,18 +66764,18 @@ case OP_MakeRecord: {
*/
#ifndef SQLITE_OMIT_BTREECOUNT
case OP_Count: { /* out2-prerelease */
-#if 0 /* local variables moved into u.ap */
+#if 0 /* local variables moved into u.ar */
i64 nEntry;
BtCursor *pCrsr;
-#endif /* local variables moved into u.ap */
+#endif /* local variables moved into u.ar */
- u.ap.pCrsr = p->apCsr[pOp->p1]->pCursor;
- if( u.ap.pCrsr ){
- rc = sqlite3BtreeCount(u.ap.pCrsr, &u.ap.nEntry);
+ u.ar.pCrsr = p->apCsr[pOp->p1]->pCursor;
+ if( ALWAYS(u.ar.pCrsr) ){
+ rc = sqlite3BtreeCount(u.ar.pCrsr, &u.ar.nEntry);
}else{
- u.ap.nEntry = 0;
+ u.ar.nEntry = 0;
}
- pOut->u.i = u.ap.nEntry;
+ pOut->u.i = u.ar.nEntry;
break;
}
#endif
@@ -65372,7 +66787,7 @@ case OP_Count: { /* out2-prerelease */
** existing savepoint, P1==1, or to rollback an existing savepoint P1==2.
*/
case OP_Savepoint: {
-#if 0 /* local variables moved into u.aq */
+#if 0 /* local variables moved into u.as */
int p1; /* Value of P1 operand */
char *zName; /* Name of savepoint */
int nName;
@@ -65381,20 +66796,20 @@ case OP_Savepoint: {
Savepoint *pTmp;
int iSavepoint;
int ii;
-#endif /* local variables moved into u.aq */
+#endif /* local variables moved into u.as */
- u.aq.p1 = pOp->p1;
- u.aq.zName = pOp->p4.z;
+ u.as.p1 = pOp->p1;
+ u.as.zName = pOp->p4.z;
- /* Assert that the u.aq.p1 parameter is valid. Also that if there is no open
+ /* Assert that the u.as.p1 parameter is valid. Also that if there is no open
** transaction, then there cannot be any savepoints.
*/
assert( db->pSavepoint==0 || db->autoCommit==0 );
- assert( u.aq.p1==SAVEPOINT_BEGIN||u.aq.p1==SAVEPOINT_RELEASE||u.aq.p1==SAVEPOINT_ROLLBACK );
+ assert( u.as.p1==SAVEPOINT_BEGIN||u.as.p1==SAVEPOINT_RELEASE||u.as.p1==SAVEPOINT_ROLLBACK );
assert( db->pSavepoint || db->isTransactionSavepoint==0 );
assert( checkSavepointCount(db) );
- if( u.aq.p1==SAVEPOINT_BEGIN ){
+ if( u.as.p1==SAVEPOINT_BEGIN ){
if( db->writeVdbeCnt>0 ){
/* A new savepoint cannot be created if there are active write
** statements (i.e. open read/write incremental blob handles).
@@ -65403,7 +66818,7 @@ case OP_Savepoint: {
"SQL statements in progress");
rc = SQLITE_BUSY;
}else{
- u.aq.nName = sqlite3Strlen30(u.aq.zName);
+ u.as.nName = sqlite3Strlen30(u.as.zName);
#ifndef SQLITE_OMIT_VIRTUALTABLE
/* This call is Ok even if this savepoint is actually a transaction
@@ -65417,10 +66832,10 @@ case OP_Savepoint: {
#endif
/* Create a new savepoint structure. */
- u.aq.pNew = sqlite3DbMallocRaw(db, sizeof(Savepoint)+u.aq.nName+1);
- if( u.aq.pNew ){
- u.aq.pNew->zName = (char *)&u.aq.pNew[1];
- memcpy(u.aq.pNew->zName, u.aq.zName, u.aq.nName+1);
+ u.as.pNew = sqlite3DbMallocRaw(db, sizeof(Savepoint)+u.as.nName+1);
+ if( u.as.pNew ){
+ u.as.pNew->zName = (char *)&u.as.pNew[1];
+ memcpy(u.as.pNew->zName, u.as.zName, u.as.nName+1);
/* If there is no open transaction, then mark this as a special
** "transaction savepoint". */
@@ -65432,36 +66847,32 @@ case OP_Savepoint: {
}
/* Link the new savepoint into the database handle's list. */
- u.aq.pNew->pNext = db->pSavepoint;
- db->pSavepoint = u.aq.pNew;
- u.aq.pNew->nDeferredCons = db->nDeferredCons;
+ u.as.pNew->pNext = db->pSavepoint;
+ db->pSavepoint = u.as.pNew;
+ u.as.pNew->nDeferredCons = db->nDeferredCons;
}
}
}else{
- u.aq.iSavepoint = 0;
+ u.as.iSavepoint = 0;
/* Find the named savepoint. If there is no such savepoint, then an
** an error is returned to the user. */
for(
- u.aq.pSavepoint = db->pSavepoint;
- u.aq.pSavepoint && sqlite3StrICmp(u.aq.pSavepoint->zName, u.aq.zName);
- u.aq.pSavepoint = u.aq.pSavepoint->pNext
+ u.as.pSavepoint = db->pSavepoint;
+ u.as.pSavepoint && sqlite3StrICmp(u.as.pSavepoint->zName, u.as.zName);
+ u.as.pSavepoint = u.as.pSavepoint->pNext
){
- u.aq.iSavepoint++;
+ u.as.iSavepoint++;
}
- if( !u.aq.pSavepoint ){
- sqlite3SetString(&p->zErrMsg, db, "no such savepoint: %s", u.aq.zName);
+ if( !u.as.pSavepoint ){
+ sqlite3SetString(&p->zErrMsg, db, "no such savepoint: %s", u.as.zName);
rc = SQLITE_ERROR;
- }else if(
- db->writeVdbeCnt>0 || (u.aq.p1==SAVEPOINT_ROLLBACK && db->activeVdbeCnt>1)
- ){
+ }else if( db->writeVdbeCnt>0 && u.as.p1==SAVEPOINT_RELEASE ){
/* It is not possible to release (commit) a savepoint if there are
- ** active write statements. It is not possible to rollback a savepoint
- ** if there are any active statements at all.
+ ** active write statements.
*/
sqlite3SetString(&p->zErrMsg, db,
- "cannot %s savepoint - SQL statements in progress",
- (u.aq.p1==SAVEPOINT_ROLLBACK ? "rollback": "release")
+ "cannot release savepoint - SQL statements in progress"
);
rc = SQLITE_BUSY;
}else{
@@ -65470,8 +66881,8 @@ case OP_Savepoint: {
** and this is a RELEASE command, then the current transaction
** is committed.
*/
- int isTransaction = u.aq.pSavepoint->pNext==0 && db->isTransactionSavepoint;
- if( isTransaction && u.aq.p1==SAVEPOINT_RELEASE ){
+ int isTransaction = u.as.pSavepoint->pNext==0 && db->isTransactionSavepoint;
+ if( isTransaction && u.as.p1==SAVEPOINT_RELEASE ){
if( (rc = sqlite3VdbeCheckFk(p, 1))!=SQLITE_OK ){
goto vdbe_return;
}
@@ -65485,26 +66896,31 @@ case OP_Savepoint: {
db->isTransactionSavepoint = 0;
rc = p->rc;
}else{
- u.aq.iSavepoint = db->nSavepoint - u.aq.iSavepoint - 1;
- for(u.aq.ii=0; u.aq.ii<db->nDb; u.aq.ii++){
- rc = sqlite3BtreeSavepoint(db->aDb[u.aq.ii].pBt, u.aq.p1, u.aq.iSavepoint);
+ u.as.iSavepoint = db->nSavepoint - u.as.iSavepoint - 1;
+ if( u.as.p1==SAVEPOINT_ROLLBACK ){
+ for(u.as.ii=0; u.as.ii<db->nDb; u.as.ii++){
+ sqlite3BtreeTripAllCursors(db->aDb[u.as.ii].pBt, SQLITE_ABORT);
+ }
+ }
+ for(u.as.ii=0; u.as.ii<db->nDb; u.as.ii++){
+ rc = sqlite3BtreeSavepoint(db->aDb[u.as.ii].pBt, u.as.p1, u.as.iSavepoint);
if( rc!=SQLITE_OK ){
goto abort_due_to_error;
}
}
- if( u.aq.p1==SAVEPOINT_ROLLBACK && (db->flags&SQLITE_InternChanges)!=0 ){
+ if( u.as.p1==SAVEPOINT_ROLLBACK && (db->flags&SQLITE_InternChanges)!=0 ){
sqlite3ExpirePreparedStatements(db);
- sqlite3ResetInternalSchema(db, -1);
+ sqlite3ResetAllSchemasOfConnection(db);
db->flags = (db->flags | SQLITE_InternChanges);
}
}
/* Regardless of whether this is a RELEASE or ROLLBACK, destroy all
** savepoints nested inside of the savepoint being operated on. */
- while( db->pSavepoint!=u.aq.pSavepoint ){
- u.aq.pTmp = db->pSavepoint;
- db->pSavepoint = u.aq.pTmp->pNext;
- sqlite3DbFree(db, u.aq.pTmp);
+ while( db->pSavepoint!=u.as.pSavepoint ){
+ u.as.pTmp = db->pSavepoint;
+ db->pSavepoint = u.as.pTmp->pNext;
+ sqlite3DbFree(db, u.as.pTmp);
db->nSavepoint--;
}
@@ -65512,19 +66928,19 @@ case OP_Savepoint: {
** too. If it is a ROLLBACK TO, then set the number of deferred
** constraint violations present in the database to the value stored
** when the savepoint was created. */
- if( u.aq.p1==SAVEPOINT_RELEASE ){
- assert( u.aq.pSavepoint==db->pSavepoint );
- db->pSavepoint = u.aq.pSavepoint->pNext;
- sqlite3DbFree(db, u.aq.pSavepoint);
+ if( u.as.p1==SAVEPOINT_RELEASE ){
+ assert( u.as.pSavepoint==db->pSavepoint );
+ db->pSavepoint = u.as.pSavepoint->pNext;
+ sqlite3DbFree(db, u.as.pSavepoint);
if( !isTransaction ){
db->nSavepoint--;
}
}else{
- db->nDeferredCons = u.aq.pSavepoint->nDeferredCons;
+ db->nDeferredCons = u.as.pSavepoint->nDeferredCons;
}
if( !isTransaction ){
- rc = sqlite3VtabSavepoint(db, u.aq.p1, u.aq.iSavepoint);
+ rc = sqlite3VtabSavepoint(db, u.as.p1, u.as.iSavepoint);
if( rc!=SQLITE_OK ) goto abort_due_to_error;
}
}
@@ -65543,20 +66959,21 @@ case OP_Savepoint: {
** This instruction causes the VM to halt.
*/
case OP_AutoCommit: {
-#if 0 /* local variables moved into u.ar */
+#if 0 /* local variables moved into u.at */
int desiredAutoCommit;
int iRollback;
int turnOnAC;
-#endif /* local variables moved into u.ar */
+#endif /* local variables moved into u.at */
- u.ar.desiredAutoCommit = pOp->p1;
- u.ar.iRollback = pOp->p2;
- u.ar.turnOnAC = u.ar.desiredAutoCommit && !db->autoCommit;
- assert( u.ar.desiredAutoCommit==1 || u.ar.desiredAutoCommit==0 );
- assert( u.ar.desiredAutoCommit==1 || u.ar.iRollback==0 );
+ u.at.desiredAutoCommit = pOp->p1;
+ u.at.iRollback = pOp->p2;
+ u.at.turnOnAC = u.at.desiredAutoCommit && !db->autoCommit;
+ assert( u.at.desiredAutoCommit==1 || u.at.desiredAutoCommit==0 );
+ assert( u.at.desiredAutoCommit==1 || u.at.iRollback==0 );
assert( db->activeVdbeCnt>0 ); /* At least this one VM is active */
- if( u.ar.turnOnAC && u.ar.iRollback && db->activeVdbeCnt>1 ){
+#if 0
+ if( u.at.turnOnAC && u.at.iRollback && db->activeVdbeCnt>1 ){
/* If this instruction implements a ROLLBACK and other VMs are
** still running, and a transaction is active, return an error indicating
** that the other VMs must complete first.
@@ -65564,25 +66981,27 @@ case OP_AutoCommit: {
sqlite3SetString(&p->zErrMsg, db, "cannot rollback transaction - "
"SQL statements in progress");
rc = SQLITE_BUSY;
- }else if( u.ar.turnOnAC && !u.ar.iRollback && db->writeVdbeCnt>0 ){
+ }else
+#endif
+ if( u.at.turnOnAC && !u.at.iRollback && db->writeVdbeCnt>0 ){
/* If this instruction implements a COMMIT and other VMs are writing
** return an error indicating that the other VMs must complete first.
*/
sqlite3SetString(&p->zErrMsg, db, "cannot commit transaction - "
"SQL statements in progress");
rc = SQLITE_BUSY;
- }else if( u.ar.desiredAutoCommit!=db->autoCommit ){
- if( u.ar.iRollback ){
- assert( u.ar.desiredAutoCommit==1 );
- sqlite3RollbackAll(db);
+ }else if( u.at.desiredAutoCommit!=db->autoCommit ){
+ if( u.at.iRollback ){
+ assert( u.at.desiredAutoCommit==1 );
+ sqlite3RollbackAll(db, SQLITE_ABORT_ROLLBACK);
db->autoCommit = 1;
}else if( (rc = sqlite3VdbeCheckFk(p, 1))!=SQLITE_OK ){
goto vdbe_return;
}else{
- db->autoCommit = (u8)u.ar.desiredAutoCommit;
+ db->autoCommit = (u8)u.at.desiredAutoCommit;
if( sqlite3VdbeHalt(p)==SQLITE_BUSY ){
p->pc = pc;
- db->autoCommit = (u8)(1-u.ar.desiredAutoCommit);
+ db->autoCommit = (u8)(1-u.at.desiredAutoCommit);
p->rc = rc = SQLITE_BUSY;
goto vdbe_return;
}
@@ -65597,8 +67016,8 @@ case OP_AutoCommit: {
goto vdbe_return;
}else{
sqlite3SetString(&p->zErrMsg, db,
- (!u.ar.desiredAutoCommit)?"cannot start a transaction within a transaction":(
- (u.ar.iRollback)?"cannot rollback - no transaction is active":
+ (!u.at.desiredAutoCommit)?"cannot start a transaction within a transaction":(
+ (u.at.iRollback)?"cannot rollback - no transaction is active":
"cannot commit - no transaction is active"));
rc = SQLITE_ERROR;
@@ -65630,7 +67049,7 @@ case OP_AutoCommit: {
** throw an ABORT exception), a statement transaction may also be opened.
** More specifically, a statement transaction is opened iff the database
** connection is currently not in autocommit mode, or if there are other
-** active statements. A statement transaction allows the affects of this
+** active statements. A statement transaction allows the changes made by this
** VDBE to be rolled back after an error without having to roll back the
** entire transaction. If no error is encountered, the statement transaction
** will automatically commit when the VDBE halts.
@@ -65638,16 +67057,16 @@ case OP_AutoCommit: {
** If P2 is zero, then a read-lock is obtained on the database file.
*/
case OP_Transaction: {
-#if 0 /* local variables moved into u.as */
+#if 0 /* local variables moved into u.au */
Btree *pBt;
-#endif /* local variables moved into u.as */
+#endif /* local variables moved into u.au */
assert( pOp->p1>=0 && pOp->p1<db->nDb );
assert( (p->btreeMask & (((yDbMask)1)<<pOp->p1))!=0 );
- u.as.pBt = db->aDb[pOp->p1].pBt;
+ u.au.pBt = db->aDb[pOp->p1].pBt;
- if( u.as.pBt ){
- rc = sqlite3BtreeBeginTrans(u.as.pBt, pOp->p2);
+ if( u.au.pBt ){
+ rc = sqlite3BtreeBeginTrans(u.au.pBt, pOp->p2);
if( rc==SQLITE_BUSY ){
p->pc = pc;
p->rc = rc = SQLITE_BUSY;
@@ -65660,7 +67079,7 @@ case OP_Transaction: {
if( pOp->p2 && p->usesStmtJournal
&& (db->autoCommit==0 || db->activeVdbeCnt>1)
){
- assert( sqlite3BtreeIsInTrans(u.as.pBt) );
+ assert( sqlite3BtreeIsInTrans(u.au.pBt) );
if( p->iStatement==0 ){
assert( db->nStatement>=0 && db->nSavepoint>=0 );
db->nStatement++;
@@ -65669,7 +67088,7 @@ case OP_Transaction: {
rc = sqlite3VtabSavepoint(db, SAVEPOINT_BEGIN, p->iStatement-1);
if( rc==SQLITE_OK ){
- rc = sqlite3BtreeBeginStmt(u.as.pBt, p->iStatement);
+ rc = sqlite3BtreeBeginStmt(u.au.pBt, p->iStatement);
}
/* Store the current value of the database handles deferred constraint
@@ -65694,21 +67113,21 @@ case OP_Transaction: {
** executing this instruction.
*/
case OP_ReadCookie: { /* out2-prerelease */
-#if 0 /* local variables moved into u.at */
+#if 0 /* local variables moved into u.av */
int iMeta;
int iDb;
int iCookie;
-#endif /* local variables moved into u.at */
+#endif /* local variables moved into u.av */
- u.at.iDb = pOp->p1;
- u.at.iCookie = pOp->p3;
+ u.av.iDb = pOp->p1;
+ u.av.iCookie = pOp->p3;
assert( pOp->p3<SQLITE_N_BTREE_META );
- assert( u.at.iDb>=0 && u.at.iDb<db->nDb );
- assert( db->aDb[u.at.iDb].pBt!=0 );
- assert( (p->btreeMask & (((yDbMask)1)<<u.at.iDb))!=0 );
+ assert( u.av.iDb>=0 && u.av.iDb<db->nDb );
+ assert( db->aDb[u.av.iDb].pBt!=0 );
+ assert( (p->btreeMask & (((yDbMask)1)<<u.av.iDb))!=0 );
- sqlite3BtreeGetMeta(db->aDb[u.at.iDb].pBt, u.at.iCookie, (u32 *)&u.at.iMeta);
- pOut->u.i = u.at.iMeta;
+ sqlite3BtreeGetMeta(db->aDb[u.av.iDb].pBt, u.av.iCookie, (u32 *)&u.av.iMeta);
+ pOut->u.i = u.av.iMeta;
break;
}
@@ -65723,26 +67142,26 @@ case OP_ReadCookie: { /* out2-prerelease */
** A transaction must be started before executing this opcode.
*/
case OP_SetCookie: { /* in3 */
-#if 0 /* local variables moved into u.au */
+#if 0 /* local variables moved into u.aw */
Db *pDb;
-#endif /* local variables moved into u.au */
+#endif /* local variables moved into u.aw */
assert( pOp->p2<SQLITE_N_BTREE_META );
assert( pOp->p1>=0 && pOp->p1<db->nDb );
assert( (p->btreeMask & (((yDbMask)1)<<pOp->p1))!=0 );
- u.au.pDb = &db->aDb[pOp->p1];
- assert( u.au.pDb->pBt!=0 );
+ u.aw.pDb = &db->aDb[pOp->p1];
+ assert( u.aw.pDb->pBt!=0 );
assert( sqlite3SchemaMutexHeld(db, pOp->p1, 0) );
pIn3 = &aMem[pOp->p3];
sqlite3VdbeMemIntegerify(pIn3);
/* See note about index shifting on OP_ReadCookie */
- rc = sqlite3BtreeUpdateMeta(u.au.pDb->pBt, pOp->p2, (int)pIn3->u.i);
+ rc = sqlite3BtreeUpdateMeta(u.aw.pDb->pBt, pOp->p2, (int)pIn3->u.i);
if( pOp->p2==BTREE_SCHEMA_VERSION ){
/* When the schema cookie changes, record the new cookie internally */
- u.au.pDb->pSchema->schema_cookie = (int)pIn3->u.i;
+ u.aw.pDb->pSchema->schema_cookie = (int)pIn3->u.i;
db->flags |= SQLITE_InternChanges;
}else if( pOp->p2==BTREE_FILE_FORMAT ){
/* Record changes in the file format */
- u.au.pDb->pSchema->file_format = (u8)pIn3->u.i;
+ u.aw.pDb->pSchema->file_format = (u8)pIn3->u.i;
}
if( pOp->p1==1 ){
/* Invalidate all prepared statements whenever the TEMP database
@@ -65772,23 +67191,23 @@ case OP_SetCookie: { /* in3 */
** invoked.
*/
case OP_VerifyCookie: {
-#if 0 /* local variables moved into u.av */
+#if 0 /* local variables moved into u.ax */
int iMeta;
int iGen;
Btree *pBt;
-#endif /* local variables moved into u.av */
+#endif /* local variables moved into u.ax */
assert( pOp->p1>=0 && pOp->p1<db->nDb );
assert( (p->btreeMask & (((yDbMask)1)<<pOp->p1))!=0 );
assert( sqlite3SchemaMutexHeld(db, pOp->p1, 0) );
- u.av.pBt = db->aDb[pOp->p1].pBt;
- if( u.av.pBt ){
- sqlite3BtreeGetMeta(u.av.pBt, BTREE_SCHEMA_VERSION, (u32 *)&u.av.iMeta);
- u.av.iGen = db->aDb[pOp->p1].pSchema->iGeneration;
+ u.ax.pBt = db->aDb[pOp->p1].pBt;
+ if( u.ax.pBt ){
+ sqlite3BtreeGetMeta(u.ax.pBt, BTREE_SCHEMA_VERSION, (u32 *)&u.ax.iMeta);
+ u.ax.iGen = db->aDb[pOp->p1].pSchema->iGeneration;
}else{
- u.av.iGen = u.av.iMeta = 0;
+ u.ax.iGen = u.ax.iMeta = 0;
}
- if( u.av.iMeta!=pOp->p2 || u.av.iGen!=pOp->p3 ){
+ if( u.ax.iMeta!=pOp->p2 || u.ax.iGen!=pOp->p3 ){
sqlite3DbFree(db, p->zErrMsg);
p->zErrMsg = sqlite3DbStrDup(db, "database schema has changed");
/* If the schema-cookie from the database file matches the cookie
@@ -65804,8 +67223,8 @@ case OP_VerifyCookie: {
** to be invalidated whenever sqlite3_step() is called from within
** a v-table method.
*/
- if( db->aDb[pOp->p1].pSchema->schema_cookie!=u.av.iMeta ){
- sqlite3ResetInternalSchema(db, pOp->p1);
+ if( db->aDb[pOp->p1].pSchema->schema_cookie!=u.ax.iMeta ){
+ sqlite3ResetOneSchema(db, pOp->p1);
}
p->expired = 1;
@@ -65865,7 +67284,7 @@ case OP_VerifyCookie: {
*/
case OP_OpenRead:
case OP_OpenWrite: {
-#if 0 /* local variables moved into u.aw */
+#if 0 /* local variables moved into u.ay */
int nField;
KeyInfo *pKeyInfo;
int p2;
@@ -65874,83 +67293,82 @@ case OP_OpenWrite: {
Btree *pX;
VdbeCursor *pCur;
Db *pDb;
-#endif /* local variables moved into u.aw */
+#endif /* local variables moved into u.ay */
+
+ assert( (pOp->p5&(OPFLAG_P2ISREG|OPFLAG_BULKCSR))==pOp->p5 );
+ assert( pOp->opcode==OP_OpenWrite || pOp->p5==0 );
if( p->expired ){
rc = SQLITE_ABORT;
break;
}
- u.aw.nField = 0;
- u.aw.pKeyInfo = 0;
- u.aw.p2 = pOp->p2;
- u.aw.iDb = pOp->p3;
- assert( u.aw.iDb>=0 && u.aw.iDb<db->nDb );
- assert( (p->btreeMask & (((yDbMask)1)<<u.aw.iDb))!=0 );
- u.aw.pDb = &db->aDb[u.aw.iDb];
- u.aw.pX = u.aw.pDb->pBt;
- assert( u.aw.pX!=0 );
+ u.ay.nField = 0;
+ u.ay.pKeyInfo = 0;
+ u.ay.p2 = pOp->p2;
+ u.ay.iDb = pOp->p3;
+ assert( u.ay.iDb>=0 && u.ay.iDb<db->nDb );
+ assert( (p->btreeMask & (((yDbMask)1)<<u.ay.iDb))!=0 );
+ u.ay.pDb = &db->aDb[u.ay.iDb];
+ u.ay.pX = u.ay.pDb->pBt;
+ assert( u.ay.pX!=0 );
if( pOp->opcode==OP_OpenWrite ){
- u.aw.wrFlag = 1;
- assert( sqlite3SchemaMutexHeld(db, u.aw.iDb, 0) );
- if( u.aw.pDb->pSchema->file_format < p->minWriteFileFormat ){
- p->minWriteFileFormat = u.aw.pDb->pSchema->file_format;
+ u.ay.wrFlag = 1;
+ assert( sqlite3SchemaMutexHeld(db, u.ay.iDb, 0) );
+ if( u.ay.pDb->pSchema->file_format < p->minWriteFileFormat ){
+ p->minWriteFileFormat = u.ay.pDb->pSchema->file_format;
}
}else{
- u.aw.wrFlag = 0;
+ u.ay.wrFlag = 0;
}
- if( pOp->p5 ){
- assert( u.aw.p2>0 );
- assert( u.aw.p2<=p->nMem );
- pIn2 = &aMem[u.aw.p2];
+ if( pOp->p5 & OPFLAG_P2ISREG ){
+ assert( u.ay.p2>0 );
+ assert( u.ay.p2<=p->nMem );
+ pIn2 = &aMem[u.ay.p2];
assert( memIsValid(pIn2) );
assert( (pIn2->flags & MEM_Int)!=0 );
sqlite3VdbeMemIntegerify(pIn2);
- u.aw.p2 = (int)pIn2->u.i;
- /* The u.aw.p2 value always comes from a prior OP_CreateTable opcode and
- ** that opcode will always set the u.aw.p2 value to 2 or more or else fail.
+ u.ay.p2 = (int)pIn2->u.i;
+ /* The u.ay.p2 value always comes from a prior OP_CreateTable opcode and
+ ** that opcode will always set the u.ay.p2 value to 2 or more or else fail.
** If there were a failure, the prepared statement would have halted
** before reaching this instruction. */
- if( NEVER(u.aw.p2<2) ) {
+ if( NEVER(u.ay.p2<2) ) {
rc = SQLITE_CORRUPT_BKPT;
goto abort_due_to_error;
}
}
if( pOp->p4type==P4_KEYINFO ){
- u.aw.pKeyInfo = pOp->p4.pKeyInfo;
- u.aw.pKeyInfo->enc = ENC(p->db);
- u.aw.nField = u.aw.pKeyInfo->nField+1;
+ u.ay.pKeyInfo = pOp->p4.pKeyInfo;
+ u.ay.pKeyInfo->enc = ENC(p->db);
+ u.ay.nField = u.ay.pKeyInfo->nField+1;
}else if( pOp->p4type==P4_INT32 ){
- u.aw.nField = pOp->p4.i;
+ u.ay.nField = pOp->p4.i;
}
assert( pOp->p1>=0 );
- u.aw.pCur = allocateCursor(p, pOp->p1, u.aw.nField, u.aw.iDb, 1);
- if( u.aw.pCur==0 ) goto no_mem;
- u.aw.pCur->nullRow = 1;
- u.aw.pCur->isOrdered = 1;
- rc = sqlite3BtreeCursor(u.aw.pX, u.aw.p2, u.aw.wrFlag, u.aw.pKeyInfo, u.aw.pCur->pCursor);
- u.aw.pCur->pKeyInfo = u.aw.pKeyInfo;
-
- /* Since it performs no memory allocation or IO, the only values that
- ** sqlite3BtreeCursor() may return are SQLITE_EMPTY and SQLITE_OK.
- ** SQLITE_EMPTY is only returned when attempting to open the table
- ** rooted at page 1 of a zero-byte database. */
- assert( rc==SQLITE_EMPTY || rc==SQLITE_OK );
- if( rc==SQLITE_EMPTY ){
- u.aw.pCur->pCursor = 0;
- rc = SQLITE_OK;
- }
+ u.ay.pCur = allocateCursor(p, pOp->p1, u.ay.nField, u.ay.iDb, 1);
+ if( u.ay.pCur==0 ) goto no_mem;
+ u.ay.pCur->nullRow = 1;
+ u.ay.pCur->isOrdered = 1;
+ rc = sqlite3BtreeCursor(u.ay.pX, u.ay.p2, u.ay.wrFlag, u.ay.pKeyInfo, u.ay.pCur->pCursor);
+ u.ay.pCur->pKeyInfo = u.ay.pKeyInfo;
+ assert( OPFLAG_BULKCSR==BTREE_BULKLOAD );
+ sqlite3BtreeCursorHints(u.ay.pCur->pCursor, (pOp->p5 & OPFLAG_BULKCSR));
+
+ /* Since it performs no memory allocation or IO, the only value that
+ ** sqlite3BtreeCursor() may return is SQLITE_OK. */
+ assert( rc==SQLITE_OK );
/* Set the VdbeCursor.isTable and isIndex variables. Previous versions of
** SQLite used to check if the root-page flags were sane at this point
** and report database corruption if they were not, but this check has
** since moved into the btree layer. */
- u.aw.pCur->isTable = pOp->p4type!=P4_KEYINFO;
- u.aw.pCur->isIndex = !u.aw.pCur->isTable;
+ u.ay.pCur->isTable = pOp->p4type!=P4_KEYINFO;
+ u.ay.pCur->isIndex = !u.ay.pCur->isTable;
break;
}
-/* Opcode: OpenEphemeral P1 P2 * P4 *
+/* Opcode: OpenEphemeral P1 P2 * P4 P5
**
** Open a new cursor P1 to a transient table.
** The cursor is always opened read/write even if
@@ -65967,6 +67385,11 @@ case OP_OpenWrite: {
** to a TEMP table at the SQL level, or to a table opened by
** this opcode. Then this opcode was call OpenVirtual. But
** that created confusion with the whole virtual-table idea.
+**
+** The P5 parameter can be a mask of the BTREE_* flags defined
+** in btree.h. These flags control aspects of the operation of
+** the btree. The BTREE_OMIT_JOURNAL and BTREE_SINGLE flags are
+** added automatically.
*/
/* Opcode: OpenAutoindex P1 P2 * P4 *
**
@@ -65977,9 +67400,9 @@ case OP_OpenWrite: {
*/
case OP_OpenAutoindex:
case OP_OpenEphemeral: {
-#if 0 /* local variables moved into u.ax */
+#if 0 /* local variables moved into u.az */
VdbeCursor *pCx;
-#endif /* local variables moved into u.ax */
+#endif /* local variables moved into u.az */
static const int vfsFlags =
SQLITE_OPEN_READWRITE |
SQLITE_OPEN_CREATE |
@@ -65988,13 +67411,13 @@ case OP_OpenEphemeral: {
SQLITE_OPEN_TRANSIENT_DB;
assert( pOp->p1>=0 );
- u.ax.pCx = allocateCursor(p, pOp->p1, pOp->p2, -1, 1);
- if( u.ax.pCx==0 ) goto no_mem;
- u.ax.pCx->nullRow = 1;
- rc = sqlite3BtreeOpen(db->pVfs, 0, db, &u.ax.pCx->pBt,
+ u.az.pCx = allocateCursor(p, pOp->p1, pOp->p2, -1, 1);
+ if( u.az.pCx==0 ) goto no_mem;
+ u.az.pCx->nullRow = 1;
+ rc = sqlite3BtreeOpen(db->pVfs, 0, db, &u.az.pCx->pBt,
BTREE_OMIT_JOURNAL | BTREE_SINGLE | pOp->p5, vfsFlags);
if( rc==SQLITE_OK ){
- rc = sqlite3BtreeBeginTrans(u.ax.pCx->pBt, 1);
+ rc = sqlite3BtreeBeginTrans(u.az.pCx->pBt, 1);
}
if( rc==SQLITE_OK ){
/* If a transient index is required, create it by calling
@@ -66005,31 +67428,52 @@ case OP_OpenEphemeral: {
if( pOp->p4.pKeyInfo ){
int pgno;
assert( pOp->p4type==P4_KEYINFO );
- rc = sqlite3BtreeCreateTable(u.ax.pCx->pBt, &pgno, BTREE_BLOBKEY);
+ rc = sqlite3BtreeCreateTable(u.az.pCx->pBt, &pgno, BTREE_BLOBKEY | pOp->p5);
if( rc==SQLITE_OK ){
assert( pgno==MASTER_ROOT+1 );
- rc = sqlite3BtreeCursor(u.ax.pCx->pBt, pgno, 1,
- (KeyInfo*)pOp->p4.z, u.ax.pCx->pCursor);
- u.ax.pCx->pKeyInfo = pOp->p4.pKeyInfo;
- u.ax.pCx->pKeyInfo->enc = ENC(p->db);
+ rc = sqlite3BtreeCursor(u.az.pCx->pBt, pgno, 1,
+ (KeyInfo*)pOp->p4.z, u.az.pCx->pCursor);
+ u.az.pCx->pKeyInfo = pOp->p4.pKeyInfo;
+ u.az.pCx->pKeyInfo->enc = ENC(p->db);
}
- u.ax.pCx->isTable = 0;
+ u.az.pCx->isTable = 0;
}else{
- rc = sqlite3BtreeCursor(u.ax.pCx->pBt, MASTER_ROOT, 1, 0, u.ax.pCx->pCursor);
- u.ax.pCx->isTable = 1;
+ rc = sqlite3BtreeCursor(u.az.pCx->pBt, MASTER_ROOT, 1, 0, u.az.pCx->pCursor);
+ u.az.pCx->isTable = 1;
}
}
- u.ax.pCx->isOrdered = (pOp->p5!=BTREE_UNORDERED);
- u.ax.pCx->isIndex = !u.ax.pCx->isTable;
+ u.az.pCx->isOrdered = (pOp->p5!=BTREE_UNORDERED);
+ u.az.pCx->isIndex = !u.az.pCx->isTable;
break;
}
-/* Opcode: OpenPseudo P1 P2 P3 * *
+/* Opcode: SorterOpen P1 P2 * P4 *
+**
+** This opcode works like OP_OpenEphemeral except that it opens
+** a transient index that is specifically designed to sort large
+** tables using an external merge-sort algorithm.
+*/
+case OP_SorterOpen: {
+#if 0 /* local variables moved into u.ba */
+ VdbeCursor *pCx;
+#endif /* local variables moved into u.ba */
+
+ u.ba.pCx = allocateCursor(p, pOp->p1, pOp->p2, -1, 1);
+ if( u.ba.pCx==0 ) goto no_mem;
+ u.ba.pCx->pKeyInfo = pOp->p4.pKeyInfo;
+ u.ba.pCx->pKeyInfo->enc = ENC(p->db);
+ u.ba.pCx->isSorter = 1;
+ rc = sqlite3VdbeSorterInit(db, u.ba.pCx);
+ break;
+}
+
+/* Opcode: OpenPseudo P1 P2 P3 * P5
**
** Open a new cursor that points to a fake table that contains a single
** row of data. The content of that one row in the content of memory
-** register P2. In other words, cursor P1 becomes an alias for the
-** MEM_Blob content contained in register P2.
+** register P2 when P5==0. In other words, cursor P1 becomes an alias for the
+** MEM_Blob content contained in register P2. When P5==1, then the
+** row is represented by P3 consecutive registers beginning with P2.
**
** A pseudo-table created by this opcode is used to hold a single
** row output from the sorter so that the row can be decomposed into
@@ -66040,17 +67484,18 @@ case OP_OpenEphemeral: {
** the pseudo-table.
*/
case OP_OpenPseudo: {
-#if 0 /* local variables moved into u.ay */
+#if 0 /* local variables moved into u.bb */
VdbeCursor *pCx;
-#endif /* local variables moved into u.ay */
+#endif /* local variables moved into u.bb */
assert( pOp->p1>=0 );
- u.ay.pCx = allocateCursor(p, pOp->p1, pOp->p3, -1, 0);
- if( u.ay.pCx==0 ) goto no_mem;
- u.ay.pCx->nullRow = 1;
- u.ay.pCx->pseudoTableReg = pOp->p2;
- u.ay.pCx->isTable = 1;
- u.ay.pCx->isIndex = 0;
+ u.bb.pCx = allocateCursor(p, pOp->p1, pOp->p3, -1, 0);
+ if( u.bb.pCx==0 ) goto no_mem;
+ u.bb.pCx->nullRow = 1;
+ u.bb.pCx->pseudoTableReg = pOp->p2;
+ u.bb.pCx->isTable = 1;
+ u.bb.pCx->isIndex = 0;
+ u.bb.pCx->multiPseudo = pOp->p5;
break;
}
@@ -66122,35 +67567,35 @@ case OP_SeekLt: /* jump, in3 */
case OP_SeekLe: /* jump, in3 */
case OP_SeekGe: /* jump, in3 */
case OP_SeekGt: { /* jump, in3 */
-#if 0 /* local variables moved into u.az */
+#if 0 /* local variables moved into u.bc */
int res;
int oc;
VdbeCursor *pC;
UnpackedRecord r;
int nField;
i64 iKey; /* The rowid we are to seek to */
-#endif /* local variables moved into u.az */
+#endif /* local variables moved into u.bc */
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
assert( pOp->p2!=0 );
- u.az.pC = p->apCsr[pOp->p1];
- assert( u.az.pC!=0 );
- assert( u.az.pC->pseudoTableReg==0 );
+ u.bc.pC = p->apCsr[pOp->p1];
+ assert( u.bc.pC!=0 );
+ assert( u.bc.pC->pseudoTableReg==0 );
assert( OP_SeekLe == OP_SeekLt+1 );
assert( OP_SeekGe == OP_SeekLt+2 );
assert( OP_SeekGt == OP_SeekLt+3 );
- assert( u.az.pC->isOrdered );
- if( u.az.pC->pCursor!=0 ){
- u.az.oc = pOp->opcode;
- u.az.pC->nullRow = 0;
- if( u.az.pC->isTable ){
+ assert( u.bc.pC->isOrdered );
+ if( ALWAYS(u.bc.pC->pCursor!=0) ){
+ u.bc.oc = pOp->opcode;
+ u.bc.pC->nullRow = 0;
+ if( u.bc.pC->isTable ){
/* The input value in P3 might be of any type: integer, real, string,
** blob, or NULL. But it needs to be an integer before we can do
** the seek, so covert it. */
pIn3 = &aMem[pOp->p3];
applyNumericAffinity(pIn3);
- u.az.iKey = sqlite3VdbeIntValue(pIn3);
- u.az.pC->rowidIsValid = 0;
+ u.bc.iKey = sqlite3VdbeIntValue(pIn3);
+ u.bc.pC->rowidIsValid = 0;
/* If the P3 value could not be converted into an integer without
** loss of information, then special processing is required... */
@@ -66165,101 +67610,101 @@ case OP_SeekGt: { /* jump, in3 */
** point number. */
assert( (pIn3->flags & MEM_Real)!=0 );
- if( u.az.iKey==SMALLEST_INT64 && (pIn3->r<(double)u.az.iKey || pIn3->r>0) ){
+ if( u.bc.iKey==SMALLEST_INT64 && (pIn3->r<(double)u.bc.iKey || pIn3->r>0) ){
/* The P3 value is too large in magnitude to be expressed as an
** integer. */
- u.az.res = 1;
+ u.bc.res = 1;
if( pIn3->r<0 ){
- if( u.az.oc>=OP_SeekGe ){ assert( u.az.oc==OP_SeekGe || u.az.oc==OP_SeekGt );
- rc = sqlite3BtreeFirst(u.az.pC->pCursor, &u.az.res);
+ if( u.bc.oc>=OP_SeekGe ){ assert( u.bc.oc==OP_SeekGe || u.bc.oc==OP_SeekGt );
+ rc = sqlite3BtreeFirst(u.bc.pC->pCursor, &u.bc.res);
if( rc!=SQLITE_OK ) goto abort_due_to_error;
}
}else{
- if( u.az.oc<=OP_SeekLe ){ assert( u.az.oc==OP_SeekLt || u.az.oc==OP_SeekLe );
- rc = sqlite3BtreeLast(u.az.pC->pCursor, &u.az.res);
+ if( u.bc.oc<=OP_SeekLe ){ assert( u.bc.oc==OP_SeekLt || u.bc.oc==OP_SeekLe );
+ rc = sqlite3BtreeLast(u.bc.pC->pCursor, &u.bc.res);
if( rc!=SQLITE_OK ) goto abort_due_to_error;
}
}
- if( u.az.res ){
+ if( u.bc.res ){
pc = pOp->p2 - 1;
}
break;
- }else if( u.az.oc==OP_SeekLt || u.az.oc==OP_SeekGe ){
+ }else if( u.bc.oc==OP_SeekLt || u.bc.oc==OP_SeekGe ){
/* Use the ceiling() function to convert real->int */
- if( pIn3->r > (double)u.az.iKey ) u.az.iKey++;
+ if( pIn3->r > (double)u.bc.iKey ) u.bc.iKey++;
}else{
/* Use the floor() function to convert real->int */
- assert( u.az.oc==OP_SeekLe || u.az.oc==OP_SeekGt );
- if( pIn3->r < (double)u.az.iKey ) u.az.iKey--;
+ assert( u.bc.oc==OP_SeekLe || u.bc.oc==OP_SeekGt );
+ if( pIn3->r < (double)u.bc.iKey ) u.bc.iKey--;
}
}
- rc = sqlite3BtreeMovetoUnpacked(u.az.pC->pCursor, 0, (u64)u.az.iKey, 0, &u.az.res);
+ rc = sqlite3BtreeMovetoUnpacked(u.bc.pC->pCursor, 0, (u64)u.bc.iKey, 0, &u.bc.res);
if( rc!=SQLITE_OK ){
goto abort_due_to_error;
}
- if( u.az.res==0 ){
- u.az.pC->rowidIsValid = 1;
- u.az.pC->lastRowid = u.az.iKey;
+ if( u.bc.res==0 ){
+ u.bc.pC->rowidIsValid = 1;
+ u.bc.pC->lastRowid = u.bc.iKey;
}
}else{
- u.az.nField = pOp->p4.i;
+ u.bc.nField = pOp->p4.i;
assert( pOp->p4type==P4_INT32 );
- assert( u.az.nField>0 );
- u.az.r.pKeyInfo = u.az.pC->pKeyInfo;
- u.az.r.nField = (u16)u.az.nField;
+ assert( u.bc.nField>0 );
+ u.bc.r.pKeyInfo = u.bc.pC->pKeyInfo;
+ u.bc.r.nField = (u16)u.bc.nField;
/* The next line of code computes as follows, only faster:
- ** if( u.az.oc==OP_SeekGt || u.az.oc==OP_SeekLe ){
- ** u.az.r.flags = UNPACKED_INCRKEY;
+ ** if( u.bc.oc==OP_SeekGt || u.bc.oc==OP_SeekLe ){
+ ** u.bc.r.flags = UNPACKED_INCRKEY;
** }else{
- ** u.az.r.flags = 0;
+ ** u.bc.r.flags = 0;
** }
*/
- u.az.r.flags = (u16)(UNPACKED_INCRKEY * (1 & (u.az.oc - OP_SeekLt)));
- assert( u.az.oc!=OP_SeekGt || u.az.r.flags==UNPACKED_INCRKEY );
- assert( u.az.oc!=OP_SeekLe || u.az.r.flags==UNPACKED_INCRKEY );
- assert( u.az.oc!=OP_SeekGe || u.az.r.flags==0 );
- assert( u.az.oc!=OP_SeekLt || u.az.r.flags==0 );
+ u.bc.r.flags = (u16)(UNPACKED_INCRKEY * (1 & (u.bc.oc - OP_SeekLt)));
+ assert( u.bc.oc!=OP_SeekGt || u.bc.r.flags==UNPACKED_INCRKEY );
+ assert( u.bc.oc!=OP_SeekLe || u.bc.r.flags==UNPACKED_INCRKEY );
+ assert( u.bc.oc!=OP_SeekGe || u.bc.r.flags==0 );
+ assert( u.bc.oc!=OP_SeekLt || u.bc.r.flags==0 );
- u.az.r.aMem = &aMem[pOp->p3];
+ u.bc.r.aMem = &aMem[pOp->p3];
#ifdef SQLITE_DEBUG
- { int i; for(i=0; i<u.az.r.nField; i++) assert( memIsValid(&u.az.r.aMem[i]) ); }
+ { int i; for(i=0; i<u.bc.r.nField; i++) assert( memIsValid(&u.bc.r.aMem[i]) ); }
#endif
- ExpandBlob(u.az.r.aMem);
- rc = sqlite3BtreeMovetoUnpacked(u.az.pC->pCursor, &u.az.r, 0, 0, &u.az.res);
+ ExpandBlob(u.bc.r.aMem);
+ rc = sqlite3BtreeMovetoUnpacked(u.bc.pC->pCursor, &u.bc.r, 0, 0, &u.bc.res);
if( rc!=SQLITE_OK ){
goto abort_due_to_error;
}
- u.az.pC->rowidIsValid = 0;
+ u.bc.pC->rowidIsValid = 0;
}
- u.az.pC->deferredMoveto = 0;
- u.az.pC->cacheStatus = CACHE_STALE;
+ u.bc.pC->deferredMoveto = 0;
+ u.bc.pC->cacheStatus = CACHE_STALE;
#ifdef SQLITE_TEST
sqlite3_search_count++;
#endif
- if( u.az.oc>=OP_SeekGe ){ assert( u.az.oc==OP_SeekGe || u.az.oc==OP_SeekGt );
- if( u.az.res<0 || (u.az.res==0 && u.az.oc==OP_SeekGt) ){
- rc = sqlite3BtreeNext(u.az.pC->pCursor, &u.az.res);
+ if( u.bc.oc>=OP_SeekGe ){ assert( u.bc.oc==OP_SeekGe || u.bc.oc==OP_SeekGt );
+ if( u.bc.res<0 || (u.bc.res==0 && u.bc.oc==OP_SeekGt) ){
+ rc = sqlite3BtreeNext(u.bc.pC->pCursor, &u.bc.res);
if( rc!=SQLITE_OK ) goto abort_due_to_error;
- u.az.pC->rowidIsValid = 0;
+ u.bc.pC->rowidIsValid = 0;
}else{
- u.az.res = 0;
+ u.bc.res = 0;
}
}else{
- assert( u.az.oc==OP_SeekLt || u.az.oc==OP_SeekLe );
- if( u.az.res>0 || (u.az.res==0 && u.az.oc==OP_SeekLt) ){
- rc = sqlite3BtreePrevious(u.az.pC->pCursor, &u.az.res);
+ assert( u.bc.oc==OP_SeekLt || u.bc.oc==OP_SeekLe );
+ if( u.bc.res>0 || (u.bc.res==0 && u.bc.oc==OP_SeekLt) ){
+ rc = sqlite3BtreePrevious(u.bc.pC->pCursor, &u.bc.res);
if( rc!=SQLITE_OK ) goto abort_due_to_error;
- u.az.pC->rowidIsValid = 0;
+ u.bc.pC->rowidIsValid = 0;
}else{
- /* u.az.res might be negative because the table is empty. Check to
+ /* u.bc.res might be negative because the table is empty. Check to
** see if this is the case.
*/
- u.az.res = sqlite3BtreeEof(u.az.pC->pCursor);
+ u.bc.res = sqlite3BtreeEof(u.bc.pC->pCursor);
}
}
assert( pOp->p2>0 );
- if( u.az.res ){
+ if( u.bc.res ){
pc = pOp->p2 - 1;
}
}else{
@@ -66282,20 +67727,20 @@ case OP_SeekGt: { /* jump, in3 */
** occur, no unnecessary I/O happens.
*/
case OP_Seek: { /* in2 */
-#if 0 /* local variables moved into u.ba */
+#if 0 /* local variables moved into u.bd */
VdbeCursor *pC;
-#endif /* local variables moved into u.ba */
+#endif /* local variables moved into u.bd */
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.ba.pC = p->apCsr[pOp->p1];
- assert( u.ba.pC!=0 );
- if( ALWAYS(u.ba.pC->pCursor!=0) ){
- assert( u.ba.pC->isTable );
- u.ba.pC->nullRow = 0;
+ u.bd.pC = p->apCsr[pOp->p1];
+ assert( u.bd.pC!=0 );
+ if( ALWAYS(u.bd.pC->pCursor!=0) ){
+ assert( u.bd.pC->isTable );
+ u.bd.pC->nullRow = 0;
pIn2 = &aMem[pOp->p2];
- u.ba.pC->movetoTarget = sqlite3VdbeIntValue(pIn2);
- u.ba.pC->rowidIsValid = 0;
- u.ba.pC->deferredMoveto = 1;
+ u.bd.pC->movetoTarget = sqlite3VdbeIntValue(pIn2);
+ u.bd.pC->rowidIsValid = 0;
+ u.bd.pC->deferredMoveto = 1;
}
break;
}
@@ -66327,62 +67772,63 @@ case OP_Seek: { /* in2 */
*/
case OP_NotFound: /* jump, in3 */
case OP_Found: { /* jump, in3 */
-#if 0 /* local variables moved into u.bb */
+#if 0 /* local variables moved into u.be */
int alreadyExists;
VdbeCursor *pC;
int res;
+ char *pFree;
UnpackedRecord *pIdxKey;
UnpackedRecord r;
char aTempRec[ROUND8(sizeof(UnpackedRecord)) + sizeof(Mem)*3 + 7];
-#endif /* local variables moved into u.bb */
+#endif /* local variables moved into u.be */
#ifdef SQLITE_TEST
sqlite3_found_count++;
#endif
- u.bb.alreadyExists = 0;
+ u.be.alreadyExists = 0;
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
assert( pOp->p4type==P4_INT32 );
- u.bb.pC = p->apCsr[pOp->p1];
- assert( u.bb.pC!=0 );
+ u.be.pC = p->apCsr[pOp->p1];
+ assert( u.be.pC!=0 );
pIn3 = &aMem[pOp->p3];
- if( ALWAYS(u.bb.pC->pCursor!=0) ){
+ if( ALWAYS(u.be.pC->pCursor!=0) ){
- assert( u.bb.pC->isTable==0 );
+ assert( u.be.pC->isTable==0 );
if( pOp->p4.i>0 ){
- u.bb.r.pKeyInfo = u.bb.pC->pKeyInfo;
- u.bb.r.nField = (u16)pOp->p4.i;
- u.bb.r.aMem = pIn3;
+ u.be.r.pKeyInfo = u.be.pC->pKeyInfo;
+ u.be.r.nField = (u16)pOp->p4.i;
+ u.be.r.aMem = pIn3;
#ifdef SQLITE_DEBUG
- { int i; for(i=0; i<u.bb.r.nField; i++) assert( memIsValid(&u.bb.r.aMem[i]) ); }
+ { int i; for(i=0; i<u.be.r.nField; i++) assert( memIsValid(&u.be.r.aMem[i]) ); }
#endif
- u.bb.r.flags = UNPACKED_PREFIX_MATCH;
- u.bb.pIdxKey = &u.bb.r;
+ u.be.r.flags = UNPACKED_PREFIX_MATCH;
+ u.be.pIdxKey = &u.be.r;
}else{
+ u.be.pIdxKey = sqlite3VdbeAllocUnpackedRecord(
+ u.be.pC->pKeyInfo, u.be.aTempRec, sizeof(u.be.aTempRec), &u.be.pFree
+ );
+ if( u.be.pIdxKey==0 ) goto no_mem;
assert( pIn3->flags & MEM_Blob );
assert( (pIn3->flags & MEM_Zero)==0 ); /* zeroblobs already expanded */
- u.bb.pIdxKey = sqlite3VdbeRecordUnpack(u.bb.pC->pKeyInfo, pIn3->n, pIn3->z,
- u.bb.aTempRec, sizeof(u.bb.aTempRec));
- if( u.bb.pIdxKey==0 ){
- goto no_mem;
- }
- u.bb.pIdxKey->flags |= UNPACKED_PREFIX_MATCH;
+ sqlite3VdbeRecordUnpack(u.be.pC->pKeyInfo, pIn3->n, pIn3->z, u.be.pIdxKey);
+ u.be.pIdxKey->flags |= UNPACKED_PREFIX_MATCH;
}
- rc = sqlite3BtreeMovetoUnpacked(u.bb.pC->pCursor, u.bb.pIdxKey, 0, 0, &u.bb.res);
+ rc = sqlite3BtreeMovetoUnpacked(u.be.pC->pCursor, u.be.pIdxKey, 0, 0, &u.be.res);
if( pOp->p4.i==0 ){
- sqlite3VdbeDeleteUnpackedRecord(u.bb.pIdxKey);
+ sqlite3DbFree(db, u.be.pFree);
}
if( rc!=SQLITE_OK ){
break;
}
- u.bb.alreadyExists = (u.bb.res==0);
- u.bb.pC->deferredMoveto = 0;
- u.bb.pC->cacheStatus = CACHE_STALE;
+ u.be.alreadyExists = (u.be.res==0);
+ u.be.pC->deferredMoveto = 0;
+ u.be.pC->cacheStatus = CACHE_STALE;
}
if( pOp->opcode==OP_Found ){
- if( u.bb.alreadyExists ) pc = pOp->p2 - 1;
+ if( u.be.alreadyExists ) pc = pOp->p2 - 1;
}else{
- if( !u.bb.alreadyExists ) pc = pOp->p2 - 1;
+ if( !u.be.alreadyExists ) pc = pOp->p2 - 1;
}
break;
}
@@ -66414,7 +67860,7 @@ case OP_Found: { /* jump, in3 */
** See also: NotFound, NotExists, Found
*/
case OP_IsUnique: { /* jump, in3 */
-#if 0 /* local variables moved into u.bc */
+#if 0 /* local variables moved into u.bf */
u16 ii;
VdbeCursor *pCx;
BtCursor *pCrsr;
@@ -66422,55 +67868,55 @@ case OP_IsUnique: { /* jump, in3 */
Mem *aMx;
UnpackedRecord r; /* B-Tree index search key */
i64 R; /* Rowid stored in register P3 */
-#endif /* local variables moved into u.bc */
+#endif /* local variables moved into u.bf */
pIn3 = &aMem[pOp->p3];
- u.bc.aMx = &aMem[pOp->p4.i];
+ u.bf.aMx = &aMem[pOp->p4.i];
/* Assert that the values of parameters P1 and P4 are in range. */
assert( pOp->p4type==P4_INT32 );
assert( pOp->p4.i>0 && pOp->p4.i<=p->nMem );
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
/* Find the index cursor. */
- u.bc.pCx = p->apCsr[pOp->p1];
- assert( u.bc.pCx->deferredMoveto==0 );
- u.bc.pCx->seekResult = 0;
- u.bc.pCx->cacheStatus = CACHE_STALE;
- u.bc.pCrsr = u.bc.pCx->pCursor;
+ u.bf.pCx = p->apCsr[pOp->p1];
+ assert( u.bf.pCx->deferredMoveto==0 );
+ u.bf.pCx->seekResult = 0;
+ u.bf.pCx->cacheStatus = CACHE_STALE;
+ u.bf.pCrsr = u.bf.pCx->pCursor;
/* If any of the values are NULL, take the jump. */
- u.bc.nField = u.bc.pCx->pKeyInfo->nField;
- for(u.bc.ii=0; u.bc.ii<u.bc.nField; u.bc.ii++){
- if( u.bc.aMx[u.bc.ii].flags & MEM_Null ){
+ u.bf.nField = u.bf.pCx->pKeyInfo->nField;
+ for(u.bf.ii=0; u.bf.ii<u.bf.nField; u.bf.ii++){
+ if( u.bf.aMx[u.bf.ii].flags & MEM_Null ){
pc = pOp->p2 - 1;
- u.bc.pCrsr = 0;
+ u.bf.pCrsr = 0;
break;
}
}
- assert( (u.bc.aMx[u.bc.nField].flags & MEM_Null)==0 );
+ assert( (u.bf.aMx[u.bf.nField].flags & MEM_Null)==0 );
- if( u.bc.pCrsr!=0 ){
+ if( u.bf.pCrsr!=0 ){
/* Populate the index search key. */
- u.bc.r.pKeyInfo = u.bc.pCx->pKeyInfo;
- u.bc.r.nField = u.bc.nField + 1;
- u.bc.r.flags = UNPACKED_PREFIX_SEARCH;
- u.bc.r.aMem = u.bc.aMx;
+ u.bf.r.pKeyInfo = u.bf.pCx->pKeyInfo;
+ u.bf.r.nField = u.bf.nField + 1;
+ u.bf.r.flags = UNPACKED_PREFIX_SEARCH;
+ u.bf.r.aMem = u.bf.aMx;
#ifdef SQLITE_DEBUG
- { int i; for(i=0; i<u.bc.r.nField; i++) assert( memIsValid(&u.bc.r.aMem[i]) ); }
+ { int i; for(i=0; i<u.bf.r.nField; i++) assert( memIsValid(&u.bf.r.aMem[i]) ); }
#endif
- /* Extract the value of u.bc.R from register P3. */
+ /* Extract the value of u.bf.R from register P3. */
sqlite3VdbeMemIntegerify(pIn3);
- u.bc.R = pIn3->u.i;
+ u.bf.R = pIn3->u.i;
/* Search the B-Tree index. If no conflicting record is found, jump
** to P2. Otherwise, copy the rowid of the conflicting record to
** register P3 and fall through to the next instruction. */
- rc = sqlite3BtreeMovetoUnpacked(u.bc.pCrsr, &u.bc.r, 0, 0, &u.bc.pCx->seekResult);
- if( (u.bc.r.flags & UNPACKED_PREFIX_SEARCH) || u.bc.r.rowid==u.bc.R ){
+ rc = sqlite3BtreeMovetoUnpacked(u.bf.pCrsr, &u.bf.r, 0, 0, &u.bf.pCx->seekResult);
+ if( (u.bf.r.flags & UNPACKED_PREFIX_SEARCH) || u.bf.r.rowid==u.bf.R ){
pc = pOp->p2 - 1;
}else{
- pIn3->u.i = u.bc.r.rowid;
+ pIn3->u.i = u.bf.r.rowid;
}
}
break;
@@ -66491,42 +67937,42 @@ case OP_IsUnique: { /* jump, in3 */
** See also: Found, NotFound, IsUnique
*/
case OP_NotExists: { /* jump, in3 */
-#if 0 /* local variables moved into u.bd */
+#if 0 /* local variables moved into u.bg */
VdbeCursor *pC;
BtCursor *pCrsr;
int res;
u64 iKey;
-#endif /* local variables moved into u.bd */
+#endif /* local variables moved into u.bg */
pIn3 = &aMem[pOp->p3];
assert( pIn3->flags & MEM_Int );
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.bd.pC = p->apCsr[pOp->p1];
- assert( u.bd.pC!=0 );
- assert( u.bd.pC->isTable );
- assert( u.bd.pC->pseudoTableReg==0 );
- u.bd.pCrsr = u.bd.pC->pCursor;
- if( u.bd.pCrsr!=0 ){
- u.bd.res = 0;
- u.bd.iKey = pIn3->u.i;
- rc = sqlite3BtreeMovetoUnpacked(u.bd.pCrsr, 0, u.bd.iKey, 0, &u.bd.res);
- u.bd.pC->lastRowid = pIn3->u.i;
- u.bd.pC->rowidIsValid = u.bd.res==0 ?1:0;
- u.bd.pC->nullRow = 0;
- u.bd.pC->cacheStatus = CACHE_STALE;
- u.bd.pC->deferredMoveto = 0;
- if( u.bd.res!=0 ){
+ u.bg.pC = p->apCsr[pOp->p1];
+ assert( u.bg.pC!=0 );
+ assert( u.bg.pC->isTable );
+ assert( u.bg.pC->pseudoTableReg==0 );
+ u.bg.pCrsr = u.bg.pC->pCursor;
+ if( ALWAYS(u.bg.pCrsr!=0) ){
+ u.bg.res = 0;
+ u.bg.iKey = pIn3->u.i;
+ rc = sqlite3BtreeMovetoUnpacked(u.bg.pCrsr, 0, u.bg.iKey, 0, &u.bg.res);
+ u.bg.pC->lastRowid = pIn3->u.i;
+ u.bg.pC->rowidIsValid = u.bg.res==0 ?1:0;
+ u.bg.pC->nullRow = 0;
+ u.bg.pC->cacheStatus = CACHE_STALE;
+ u.bg.pC->deferredMoveto = 0;
+ if( u.bg.res!=0 ){
pc = pOp->p2 - 1;
- assert( u.bd.pC->rowidIsValid==0 );
+ assert( u.bg.pC->rowidIsValid==0 );
}
- u.bd.pC->seekResult = u.bd.res;
+ u.bg.pC->seekResult = u.bg.res;
}else{
/* This happens when an attempt to open a read cursor on the
** sqlite_master table returns SQLITE_EMPTY.
*/
pc = pOp->p2 - 1;
- assert( u.bd.pC->rowidIsValid==0 );
- u.bd.pC->seekResult = 0;
+ assert( u.bg.pC->rowidIsValid==0 );
+ u.bg.pC->seekResult = 0;
}
break;
}
@@ -66561,21 +68007,21 @@ case OP_Sequence: { /* out2-prerelease */
** AUTOINCREMENT feature.
*/
case OP_NewRowid: { /* out2-prerelease */
-#if 0 /* local variables moved into u.be */
+#if 0 /* local variables moved into u.bh */
i64 v; /* The new rowid */
VdbeCursor *pC; /* Cursor of table to get the new rowid */
int res; /* Result of an sqlite3BtreeLast() */
int cnt; /* Counter to limit the number of searches */
Mem *pMem; /* Register holding largest rowid for AUTOINCREMENT */
VdbeFrame *pFrame; /* Root frame of VDBE */
-#endif /* local variables moved into u.be */
+#endif /* local variables moved into u.bh */
- u.be.v = 0;
- u.be.res = 0;
+ u.bh.v = 0;
+ u.bh.res = 0;
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.be.pC = p->apCsr[pOp->p1];
- assert( u.be.pC!=0 );
- if( NEVER(u.be.pC->pCursor==0) ){
+ u.bh.pC = p->apCsr[pOp->p1];
+ assert( u.bh.pC!=0 );
+ if( NEVER(u.bh.pC->pCursor==0) ){
/* The zero initialization above is all that is needed */
}else{
/* The next rowid or record number (different terms for the same
@@ -66591,7 +68037,7 @@ case OP_NewRowid: { /* out2-prerelease */
** succeeded. If the random rowid does exist, we select a new one
** and try again, up to 100 times.
*/
- assert( u.be.pC->isTable );
+ assert( u.bh.pC->isTable );
#ifdef SQLITE_32BIT_ROWID
# define MAX_ROWID 0x7fffffff
@@ -66603,23 +68049,23 @@ case OP_NewRowid: { /* out2-prerelease */
# define MAX_ROWID (i64)( (((u64)0x7fffffff)<<32) | (u64)0xffffffff )
#endif
- if( !u.be.pC->useRandomRowid ){
- u.be.v = sqlite3BtreeGetCachedRowid(u.be.pC->pCursor);
- if( u.be.v==0 ){
- rc = sqlite3BtreeLast(u.be.pC->pCursor, &u.be.res);
+ if( !u.bh.pC->useRandomRowid ){
+ u.bh.v = sqlite3BtreeGetCachedRowid(u.bh.pC->pCursor);
+ if( u.bh.v==0 ){
+ rc = sqlite3BtreeLast(u.bh.pC->pCursor, &u.bh.res);
if( rc!=SQLITE_OK ){
goto abort_due_to_error;
}
- if( u.be.res ){
- u.be.v = 1; /* IMP: R-61914-48074 */
+ if( u.bh.res ){
+ u.bh.v = 1; /* IMP: R-61914-48074 */
}else{
- assert( sqlite3BtreeCursorIsValid(u.be.pC->pCursor) );
- rc = sqlite3BtreeKeySize(u.be.pC->pCursor, &u.be.v);
+ assert( sqlite3BtreeCursorIsValid(u.bh.pC->pCursor) );
+ rc = sqlite3BtreeKeySize(u.bh.pC->pCursor, &u.bh.v);
assert( rc==SQLITE_OK ); /* Cannot fail following BtreeLast() */
- if( u.be.v==MAX_ROWID ){
- u.be.pC->useRandomRowid = 1;
+ if( u.bh.v>=MAX_ROWID ){
+ u.bh.pC->useRandomRowid = 1;
}else{
- u.be.v++; /* IMP: R-29538-34987 */
+ u.bh.v++; /* IMP: R-29538-34987 */
}
}
}
@@ -66629,35 +68075,35 @@ case OP_NewRowid: { /* out2-prerelease */
/* Assert that P3 is a valid memory cell. */
assert( pOp->p3>0 );
if( p->pFrame ){
- for(u.be.pFrame=p->pFrame; u.be.pFrame->pParent; u.be.pFrame=u.be.pFrame->pParent);
+ for(u.bh.pFrame=p->pFrame; u.bh.pFrame->pParent; u.bh.pFrame=u.bh.pFrame->pParent);
/* Assert that P3 is a valid memory cell. */
- assert( pOp->p3<=u.be.pFrame->nMem );
- u.be.pMem = &u.be.pFrame->aMem[pOp->p3];
+ assert( pOp->p3<=u.bh.pFrame->nMem );
+ u.bh.pMem = &u.bh.pFrame->aMem[pOp->p3];
}else{
/* Assert that P3 is a valid memory cell. */
assert( pOp->p3<=p->nMem );
- u.be.pMem = &aMem[pOp->p3];
- memAboutToChange(p, u.be.pMem);
+ u.bh.pMem = &aMem[pOp->p3];
+ memAboutToChange(p, u.bh.pMem);
}
- assert( memIsValid(u.be.pMem) );
+ assert( memIsValid(u.bh.pMem) );
- REGISTER_TRACE(pOp->p3, u.be.pMem);
- sqlite3VdbeMemIntegerify(u.be.pMem);
- assert( (u.be.pMem->flags & MEM_Int)!=0 ); /* mem(P3) holds an integer */
- if( u.be.pMem->u.i==MAX_ROWID || u.be.pC->useRandomRowid ){
+ REGISTER_TRACE(pOp->p3, u.bh.pMem);
+ sqlite3VdbeMemIntegerify(u.bh.pMem);
+ assert( (u.bh.pMem->flags & MEM_Int)!=0 ); /* mem(P3) holds an integer */
+ if( u.bh.pMem->u.i==MAX_ROWID || u.bh.pC->useRandomRowid ){
rc = SQLITE_FULL; /* IMP: R-12275-61338 */
goto abort_due_to_error;
}
- if( u.be.v<u.be.pMem->u.i+1 ){
- u.be.v = u.be.pMem->u.i + 1;
+ if( u.bh.v<u.bh.pMem->u.i+1 ){
+ u.bh.v = u.bh.pMem->u.i + 1;
}
- u.be.pMem->u.i = u.be.v;
+ u.bh.pMem->u.i = u.bh.v;
}
#endif
- sqlite3BtreeSetCachedRowid(u.be.pC->pCursor, u.be.v<MAX_ROWID ? u.be.v+1 : 0);
+ sqlite3BtreeSetCachedRowid(u.bh.pC->pCursor, u.bh.v<MAX_ROWID ? u.bh.v+1 : 0);
}
- if( u.be.pC->useRandomRowid ){
+ if( u.bh.pC->useRandomRowid ){
/* IMPLEMENTATION-OF: R-07677-41881 If the largest ROWID is equal to the
** largest possible integer (9223372036854775807) then the database
** engine starts picking positive candidate ROWIDs at random until
@@ -66665,35 +68111,35 @@ case OP_NewRowid: { /* out2-prerelease */
assert( pOp->p3==0 ); /* We cannot be in random rowid mode if this is
** an AUTOINCREMENT table. */
/* on the first attempt, simply do one more than previous */
- u.be.v = lastRowid;
- u.be.v &= (MAX_ROWID>>1); /* ensure doesn't go negative */
- u.be.v++; /* ensure non-zero */
- u.be.cnt = 0;
- while( ((rc = sqlite3BtreeMovetoUnpacked(u.be.pC->pCursor, 0, (u64)u.be.v,
- 0, &u.be.res))==SQLITE_OK)
- && (u.be.res==0)
- && (++u.be.cnt<100)){
+ u.bh.v = lastRowid;
+ u.bh.v &= (MAX_ROWID>>1); /* ensure doesn't go negative */
+ u.bh.v++; /* ensure non-zero */
+ u.bh.cnt = 0;
+ while( ((rc = sqlite3BtreeMovetoUnpacked(u.bh.pC->pCursor, 0, (u64)u.bh.v,
+ 0, &u.bh.res))==SQLITE_OK)
+ && (u.bh.res==0)
+ && (++u.bh.cnt<100)){
/* collision - try another random rowid */
- sqlite3_randomness(sizeof(u.be.v), &u.be.v);
- if( u.be.cnt<5 ){
+ sqlite3_randomness(sizeof(u.bh.v), &u.bh.v);
+ if( u.bh.cnt<5 ){
/* try "small" random rowids for the initial attempts */
- u.be.v &= 0xffffff;
+ u.bh.v &= 0xffffff;
}else{
- u.be.v &= (MAX_ROWID>>1); /* ensure doesn't go negative */
+ u.bh.v &= (MAX_ROWID>>1); /* ensure doesn't go negative */
}
- u.be.v++; /* ensure non-zero */
+ u.bh.v++; /* ensure non-zero */
}
- if( rc==SQLITE_OK && u.be.res==0 ){
+ if( rc==SQLITE_OK && u.bh.res==0 ){
rc = SQLITE_FULL; /* IMP: R-38219-53002 */
goto abort_due_to_error;
}
- assert( u.be.v>0 ); /* EV: R-40812-03570 */
+ assert( u.bh.v>0 ); /* EV: R-40812-03570 */
}
- u.be.pC->rowidIsValid = 0;
- u.be.pC->deferredMoveto = 0;
- u.be.pC->cacheStatus = CACHE_STALE;
+ u.bh.pC->rowidIsValid = 0;
+ u.bh.pC->deferredMoveto = 0;
+ u.bh.pC->cacheStatus = CACHE_STALE;
}
- pOut->u.i = u.be.v;
+ pOut->u.i = u.bh.v;
break;
}
@@ -66743,7 +68189,7 @@ case OP_NewRowid: { /* out2-prerelease */
*/
case OP_Insert:
case OP_InsertInt: {
-#if 0 /* local variables moved into u.bf */
+#if 0 /* local variables moved into u.bi */
Mem *pData; /* MEM cell holding data for the record to be inserted */
Mem *pKey; /* MEM cell holding key for the record */
i64 iKey; /* The integer ROWID or key for the record to be inserted */
@@ -66753,60 +68199,60 @@ case OP_InsertInt: {
const char *zDb; /* database name - used by the update hook */
const char *zTbl; /* Table name - used by the opdate hook */
int op; /* Opcode for update hook: SQLITE_UPDATE or SQLITE_INSERT */
-#endif /* local variables moved into u.bf */
+#endif /* local variables moved into u.bi */
- u.bf.pData = &aMem[pOp->p2];
+ u.bi.pData = &aMem[pOp->p2];
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- assert( memIsValid(u.bf.pData) );
- u.bf.pC = p->apCsr[pOp->p1];
- assert( u.bf.pC!=0 );
- assert( u.bf.pC->pCursor!=0 );
- assert( u.bf.pC->pseudoTableReg==0 );
- assert( u.bf.pC->isTable );
- REGISTER_TRACE(pOp->p2, u.bf.pData);
+ assert( memIsValid(u.bi.pData) );
+ u.bi.pC = p->apCsr[pOp->p1];
+ assert( u.bi.pC!=0 );
+ assert( u.bi.pC->pCursor!=0 );
+ assert( u.bi.pC->pseudoTableReg==0 );
+ assert( u.bi.pC->isTable );
+ REGISTER_TRACE(pOp->p2, u.bi.pData);
if( pOp->opcode==OP_Insert ){
- u.bf.pKey = &aMem[pOp->p3];
- assert( u.bf.pKey->flags & MEM_Int );
- assert( memIsValid(u.bf.pKey) );
- REGISTER_TRACE(pOp->p3, u.bf.pKey);
- u.bf.iKey = u.bf.pKey->u.i;
+ u.bi.pKey = &aMem[pOp->p3];
+ assert( u.bi.pKey->flags & MEM_Int );
+ assert( memIsValid(u.bi.pKey) );
+ REGISTER_TRACE(pOp->p3, u.bi.pKey);
+ u.bi.iKey = u.bi.pKey->u.i;
}else{
assert( pOp->opcode==OP_InsertInt );
- u.bf.iKey = pOp->p3;
+ u.bi.iKey = pOp->p3;
}
if( pOp->p5 & OPFLAG_NCHANGE ) p->nChange++;
- if( pOp->p5 & OPFLAG_LASTROWID ) db->lastRowid = lastRowid = u.bf.iKey;
- if( u.bf.pData->flags & MEM_Null ){
- u.bf.pData->z = 0;
- u.bf.pData->n = 0;
+ if( pOp->p5 & OPFLAG_LASTROWID ) db->lastRowid = lastRowid = u.bi.iKey;
+ if( u.bi.pData->flags & MEM_Null ){
+ u.bi.pData->z = 0;
+ u.bi.pData->n = 0;
}else{
- assert( u.bf.pData->flags & (MEM_Blob|MEM_Str) );
+ assert( u.bi.pData->flags & (MEM_Blob|MEM_Str) );
}
- u.bf.seekResult = ((pOp->p5 & OPFLAG_USESEEKRESULT) ? u.bf.pC->seekResult : 0);
- if( u.bf.pData->flags & MEM_Zero ){
- u.bf.nZero = u.bf.pData->u.nZero;
+ u.bi.seekResult = ((pOp->p5 & OPFLAG_USESEEKRESULT) ? u.bi.pC->seekResult : 0);
+ if( u.bi.pData->flags & MEM_Zero ){
+ u.bi.nZero = u.bi.pData->u.nZero;
}else{
- u.bf.nZero = 0;
+ u.bi.nZero = 0;
}
- sqlite3BtreeSetCachedRowid(u.bf.pC->pCursor, 0);
- rc = sqlite3BtreeInsert(u.bf.pC->pCursor, 0, u.bf.iKey,
- u.bf.pData->z, u.bf.pData->n, u.bf.nZero,
- pOp->p5 & OPFLAG_APPEND, u.bf.seekResult
+ sqlite3BtreeSetCachedRowid(u.bi.pC->pCursor, 0);
+ rc = sqlite3BtreeInsert(u.bi.pC->pCursor, 0, u.bi.iKey,
+ u.bi.pData->z, u.bi.pData->n, u.bi.nZero,
+ pOp->p5 & OPFLAG_APPEND, u.bi.seekResult
);
- u.bf.pC->rowidIsValid = 0;
- u.bf.pC->deferredMoveto = 0;
- u.bf.pC->cacheStatus = CACHE_STALE;
+ u.bi.pC->rowidIsValid = 0;
+ u.bi.pC->deferredMoveto = 0;
+ u.bi.pC->cacheStatus = CACHE_STALE;
/* Invoke the update-hook if required. */
if( rc==SQLITE_OK && db->xUpdateCallback && pOp->p4.z ){
- u.bf.zDb = db->aDb[u.bf.pC->iDb].zName;
- u.bf.zTbl = pOp->p4.z;
- u.bf.op = ((pOp->p5 & OPFLAG_ISUPDATE) ? SQLITE_UPDATE : SQLITE_INSERT);
- assert( u.bf.pC->isTable );
- db->xUpdateCallback(db->pUpdateArg, u.bf.op, u.bf.zDb, u.bf.zTbl, u.bf.iKey);
- assert( u.bf.pC->iDb>=0 );
+ u.bi.zDb = db->aDb[u.bi.pC->iDb].zName;
+ u.bi.zTbl = pOp->p4.z;
+ u.bi.op = ((pOp->p5 & OPFLAG_ISUPDATE) ? SQLITE_UPDATE : SQLITE_INSERT);
+ assert( u.bi.pC->isTable );
+ db->xUpdateCallback(db->pUpdateArg, u.bi.op, u.bi.zDb, u.bi.zTbl, u.bi.iKey);
+ assert( u.bi.pC->iDb>=0 );
}
break;
}
@@ -66832,47 +68278,47 @@ case OP_InsertInt: {
** using OP_NotFound prior to invoking this opcode.
*/
case OP_Delete: {
-#if 0 /* local variables moved into u.bg */
+#if 0 /* local variables moved into u.bj */
i64 iKey;
VdbeCursor *pC;
-#endif /* local variables moved into u.bg */
+#endif /* local variables moved into u.bj */
- u.bg.iKey = 0;
+ u.bj.iKey = 0;
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.bg.pC = p->apCsr[pOp->p1];
- assert( u.bg.pC!=0 );
- assert( u.bg.pC->pCursor!=0 ); /* Only valid for real tables, no pseudotables */
+ u.bj.pC = p->apCsr[pOp->p1];
+ assert( u.bj.pC!=0 );
+ assert( u.bj.pC->pCursor!=0 ); /* Only valid for real tables, no pseudotables */
- /* If the update-hook will be invoked, set u.bg.iKey to the rowid of the
+ /* If the update-hook will be invoked, set u.bj.iKey to the rowid of the
** row being deleted.
*/
if( db->xUpdateCallback && pOp->p4.z ){
- assert( u.bg.pC->isTable );
- assert( u.bg.pC->rowidIsValid ); /* lastRowid set by previous OP_NotFound */
- u.bg.iKey = u.bg.pC->lastRowid;
+ assert( u.bj.pC->isTable );
+ assert( u.bj.pC->rowidIsValid ); /* lastRowid set by previous OP_NotFound */
+ u.bj.iKey = u.bj.pC->lastRowid;
}
/* The OP_Delete opcode always follows an OP_NotExists or OP_Last or
** OP_Column on the same table without any intervening operations that
- ** might move or invalidate the cursor. Hence cursor u.bg.pC is always pointing
+ ** might move or invalidate the cursor. Hence cursor u.bj.pC is always pointing
** to the row to be deleted and the sqlite3VdbeCursorMoveto() operation
** below is always a no-op and cannot fail. We will run it anyhow, though,
** to guard against future changes to the code generator.
**/
- assert( u.bg.pC->deferredMoveto==0 );
- rc = sqlite3VdbeCursorMoveto(u.bg.pC);
+ assert( u.bj.pC->deferredMoveto==0 );
+ rc = sqlite3VdbeCursorMoveto(u.bj.pC);
if( NEVER(rc!=SQLITE_OK) ) goto abort_due_to_error;
- sqlite3BtreeSetCachedRowid(u.bg.pC->pCursor, 0);
- rc = sqlite3BtreeDelete(u.bg.pC->pCursor);
- u.bg.pC->cacheStatus = CACHE_STALE;
+ sqlite3BtreeSetCachedRowid(u.bj.pC->pCursor, 0);
+ rc = sqlite3BtreeDelete(u.bj.pC->pCursor);
+ u.bj.pC->cacheStatus = CACHE_STALE;
/* Invoke the update-hook if required. */
if( rc==SQLITE_OK && db->xUpdateCallback && pOp->p4.z ){
- const char *zDb = db->aDb[u.bg.pC->iDb].zName;
+ const char *zDb = db->aDb[u.bj.pC->iDb].zName;
const char *zTbl = pOp->p4.z;
- db->xUpdateCallback(db->pUpdateArg, SQLITE_DELETE, zDb, zTbl, u.bg.iKey);
- assert( u.bg.pC->iDb>=0 );
+ db->xUpdateCallback(db->pUpdateArg, SQLITE_DELETE, zDb, zTbl, u.bj.iKey);
+ assert( u.bj.pC->iDb>=0 );
}
if( pOp->p2 & OPFLAG_NCHANGE ) p->nChange++;
break;
@@ -66890,6 +68336,45 @@ case OP_ResetCount: {
break;
}
+/* Opcode: SorterCompare P1 P2 P3
+**
+** P1 is a sorter cursor. This instruction compares the record blob in
+** register P3 with the entry that the sorter cursor currently points to.
+** If, excluding the rowid fields at the end, the two records are a match,
+** fall through to the next instruction. Otherwise, jump to instruction P2.
+*/
+case OP_SorterCompare: {
+#if 0 /* local variables moved into u.bk */
+ VdbeCursor *pC;
+ int res;
+#endif /* local variables moved into u.bk */
+
+ u.bk.pC = p->apCsr[pOp->p1];
+ assert( isSorter(u.bk.pC) );
+ pIn3 = &aMem[pOp->p3];
+ rc = sqlite3VdbeSorterCompare(u.bk.pC, pIn3, &u.bk.res);
+ if( u.bk.res ){
+ pc = pOp->p2-1;
+ }
+ break;
+};
+
+/* Opcode: SorterData P1 P2 * * *
+**
+** Write into register P2 the current sorter data for sorter cursor P1.
+*/
+case OP_SorterData: {
+#if 0 /* local variables moved into u.bl */
+ VdbeCursor *pC;
+#endif /* local variables moved into u.bl */
+
+ pOut = &aMem[pOp->p2];
+ u.bl.pC = p->apCsr[pOp->p1];
+ assert( u.bl.pC->isSorter );
+ rc = sqlite3VdbeSorterRowkey(u.bl.pC, pOut);
+ break;
+}
+
/* Opcode: RowData P1 P2 * * *
**
** Write into register P2 the complete row data for cursor P1.
@@ -66912,61 +68397,62 @@ case OP_ResetCount: {
*/
case OP_RowKey:
case OP_RowData: {
-#if 0 /* local variables moved into u.bh */
+#if 0 /* local variables moved into u.bm */
VdbeCursor *pC;
BtCursor *pCrsr;
u32 n;
i64 n64;
-#endif /* local variables moved into u.bh */
+#endif /* local variables moved into u.bm */
pOut = &aMem[pOp->p2];
memAboutToChange(p, pOut);
/* Note that RowKey and RowData are really exactly the same instruction */
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.bh.pC = p->apCsr[pOp->p1];
- assert( u.bh.pC->isTable || pOp->opcode==OP_RowKey );
- assert( u.bh.pC->isIndex || pOp->opcode==OP_RowData );
- assert( u.bh.pC!=0 );
- assert( u.bh.pC->nullRow==0 );
- assert( u.bh.pC->pseudoTableReg==0 );
- assert( u.bh.pC->pCursor!=0 );
- u.bh.pCrsr = u.bh.pC->pCursor;
- assert( sqlite3BtreeCursorIsValid(u.bh.pCrsr) );
+ u.bm.pC = p->apCsr[pOp->p1];
+ assert( u.bm.pC->isSorter==0 );
+ assert( u.bm.pC->isTable || pOp->opcode!=OP_RowData );
+ assert( u.bm.pC->isIndex || pOp->opcode==OP_RowData );
+ assert( u.bm.pC!=0 );
+ assert( u.bm.pC->nullRow==0 );
+ assert( u.bm.pC->pseudoTableReg==0 );
+ assert( u.bm.pC->pCursor!=0 );
+ u.bm.pCrsr = u.bm.pC->pCursor;
+ assert( sqlite3BtreeCursorIsValid(u.bm.pCrsr) );
/* The OP_RowKey and OP_RowData opcodes always follow OP_NotExists or
** OP_Rewind/Op_Next with no intervening instructions that might invalidate
** the cursor. Hence the following sqlite3VdbeCursorMoveto() call is always
** a no-op and can never fail. But we leave it in place as a safety.
*/
- assert( u.bh.pC->deferredMoveto==0 );
- rc = sqlite3VdbeCursorMoveto(u.bh.pC);
+ assert( u.bm.pC->deferredMoveto==0 );
+ rc = sqlite3VdbeCursorMoveto(u.bm.pC);
if( NEVER(rc!=SQLITE_OK) ) goto abort_due_to_error;
- if( u.bh.pC->isIndex ){
- assert( !u.bh.pC->isTable );
- rc = sqlite3BtreeKeySize(u.bh.pCrsr, &u.bh.n64);
+ if( u.bm.pC->isIndex ){
+ assert( !u.bm.pC->isTable );
+ VVA_ONLY(rc =) sqlite3BtreeKeySize(u.bm.pCrsr, &u.bm.n64);
assert( rc==SQLITE_OK ); /* True because of CursorMoveto() call above */
- if( u.bh.n64>db->aLimit[SQLITE_LIMIT_LENGTH] ){
+ if( u.bm.n64>db->aLimit[SQLITE_LIMIT_LENGTH] ){
goto too_big;
}
- u.bh.n = (u32)u.bh.n64;
+ u.bm.n = (u32)u.bm.n64;
}else{
- rc = sqlite3BtreeDataSize(u.bh.pCrsr, &u.bh.n);
+ VVA_ONLY(rc =) sqlite3BtreeDataSize(u.bm.pCrsr, &u.bm.n);
assert( rc==SQLITE_OK ); /* DataSize() cannot fail */
- if( u.bh.n>(u32)db->aLimit[SQLITE_LIMIT_LENGTH] ){
+ if( u.bm.n>(u32)db->aLimit[SQLITE_LIMIT_LENGTH] ){
goto too_big;
}
}
- if( sqlite3VdbeMemGrow(pOut, u.bh.n, 0) ){
+ if( sqlite3VdbeMemGrow(pOut, u.bm.n, 0) ){
goto no_mem;
}
- pOut->n = u.bh.n;
+ pOut->n = u.bm.n;
MemSetTypeFlag(pOut, MEM_Blob);
- if( u.bh.pC->isIndex ){
- rc = sqlite3BtreeKey(u.bh.pCrsr, 0, u.bh.n, pOut->z);
+ if( u.bm.pC->isIndex ){
+ rc = sqlite3BtreeKey(u.bm.pCrsr, 0, u.bm.n, pOut->z);
}else{
- rc = sqlite3BtreeData(u.bh.pCrsr, 0, u.bh.n, pOut->z);
+ rc = sqlite3BtreeData(u.bm.pCrsr, 0, u.bm.n, pOut->z);
}
pOut->enc = SQLITE_UTF8; /* In case the blob is ever cast to text */
UPDATE_MAX_BLOBSIZE(pOut);
@@ -66983,42 +68469,42 @@ case OP_RowData: {
** one opcode now works for both table types.
*/
case OP_Rowid: { /* out2-prerelease */
-#if 0 /* local variables moved into u.bi */
+#if 0 /* local variables moved into u.bn */
VdbeCursor *pC;
i64 v;
sqlite3_vtab *pVtab;
const sqlite3_module *pModule;
-#endif /* local variables moved into u.bi */
+#endif /* local variables moved into u.bn */
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.bi.pC = p->apCsr[pOp->p1];
- assert( u.bi.pC!=0 );
- assert( u.bi.pC->pseudoTableReg==0 );
- if( u.bi.pC->nullRow ){
+ u.bn.pC = p->apCsr[pOp->p1];
+ assert( u.bn.pC!=0 );
+ assert( u.bn.pC->pseudoTableReg==0 || u.bn.pC->nullRow );
+ if( u.bn.pC->nullRow ){
pOut->flags = MEM_Null;
break;
- }else if( u.bi.pC->deferredMoveto ){
- u.bi.v = u.bi.pC->movetoTarget;
+ }else if( u.bn.pC->deferredMoveto ){
+ u.bn.v = u.bn.pC->movetoTarget;
#ifndef SQLITE_OMIT_VIRTUALTABLE
- }else if( u.bi.pC->pVtabCursor ){
- u.bi.pVtab = u.bi.pC->pVtabCursor->pVtab;
- u.bi.pModule = u.bi.pVtab->pModule;
- assert( u.bi.pModule->xRowid );
- rc = u.bi.pModule->xRowid(u.bi.pC->pVtabCursor, &u.bi.v);
- importVtabErrMsg(p, u.bi.pVtab);
+ }else if( u.bn.pC->pVtabCursor ){
+ u.bn.pVtab = u.bn.pC->pVtabCursor->pVtab;
+ u.bn.pModule = u.bn.pVtab->pModule;
+ assert( u.bn.pModule->xRowid );
+ rc = u.bn.pModule->xRowid(u.bn.pC->pVtabCursor, &u.bn.v);
+ importVtabErrMsg(p, u.bn.pVtab);
#endif /* SQLITE_OMIT_VIRTUALTABLE */
}else{
- assert( u.bi.pC->pCursor!=0 );
- rc = sqlite3VdbeCursorMoveto(u.bi.pC);
+ assert( u.bn.pC->pCursor!=0 );
+ rc = sqlite3VdbeCursorMoveto(u.bn.pC);
if( rc ) goto abort_due_to_error;
- if( u.bi.pC->rowidIsValid ){
- u.bi.v = u.bi.pC->lastRowid;
+ if( u.bn.pC->rowidIsValid ){
+ u.bn.v = u.bn.pC->lastRowid;
}else{
- rc = sqlite3BtreeKeySize(u.bi.pC->pCursor, &u.bi.v);
+ rc = sqlite3BtreeKeySize(u.bn.pC->pCursor, &u.bn.v);
assert( rc==SQLITE_OK ); /* Always so because of CursorMoveto() above */
}
}
- pOut->u.i = u.bi.v;
+ pOut->u.i = u.bn.v;
break;
}
@@ -67029,17 +68515,18 @@ case OP_Rowid: { /* out2-prerelease */
** write a NULL.
*/
case OP_NullRow: {
-#if 0 /* local variables moved into u.bj */
+#if 0 /* local variables moved into u.bo */
VdbeCursor *pC;
-#endif /* local variables moved into u.bj */
+#endif /* local variables moved into u.bo */
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.bj.pC = p->apCsr[pOp->p1];
- assert( u.bj.pC!=0 );
- u.bj.pC->nullRow = 1;
- u.bj.pC->rowidIsValid = 0;
- if( u.bj.pC->pCursor ){
- sqlite3BtreeClearCursor(u.bj.pC->pCursor);
+ u.bo.pC = p->apCsr[pOp->p1];
+ assert( u.bo.pC!=0 );
+ u.bo.pC->nullRow = 1;
+ u.bo.pC->rowidIsValid = 0;
+ assert( u.bo.pC->pCursor || u.bo.pC->pVtabCursor );
+ if( u.bo.pC->pCursor ){
+ sqlite3BtreeClearCursor(u.bo.pC->pCursor);
}
break;
}
@@ -67053,26 +68540,25 @@ case OP_NullRow: {
** to the following instruction.
*/
case OP_Last: { /* jump */
-#if 0 /* local variables moved into u.bk */
+#if 0 /* local variables moved into u.bp */
VdbeCursor *pC;
BtCursor *pCrsr;
int res;
-#endif /* local variables moved into u.bk */
+#endif /* local variables moved into u.bp */
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.bk.pC = p->apCsr[pOp->p1];
- assert( u.bk.pC!=0 );
- u.bk.pCrsr = u.bk.pC->pCursor;
- if( u.bk.pCrsr==0 ){
- u.bk.res = 1;
- }else{
- rc = sqlite3BtreeLast(u.bk.pCrsr, &u.bk.res);
- }
- u.bk.pC->nullRow = (u8)u.bk.res;
- u.bk.pC->deferredMoveto = 0;
- u.bk.pC->rowidIsValid = 0;
- u.bk.pC->cacheStatus = CACHE_STALE;
- if( pOp->p2>0 && u.bk.res ){
+ u.bp.pC = p->apCsr[pOp->p1];
+ assert( u.bp.pC!=0 );
+ u.bp.pCrsr = u.bp.pC->pCursor;
+ u.bp.res = 0;
+ if( ALWAYS(u.bp.pCrsr!=0) ){
+ rc = sqlite3BtreeLast(u.bp.pCrsr, &u.bp.res);
+ }
+ u.bp.pC->nullRow = (u8)u.bp.res;
+ u.bp.pC->deferredMoveto = 0;
+ u.bp.pC->rowidIsValid = 0;
+ u.bp.pC->cacheStatus = CACHE_STALE;
+ if( pOp->p2>0 && u.bp.res ){
pc = pOp->p2 - 1;
}
break;
@@ -67091,6 +68577,7 @@ case OP_Last: { /* jump */
** regression tests can determine whether or not the optimizer is
** correctly optimizing out sorts.
*/
+case OP_SorterSort: /* jump */
case OP_Sort: { /* jump */
#ifdef SQLITE_TEST
sqlite3_sort_count++;
@@ -67108,32 +68595,37 @@ case OP_Sort: { /* jump */
** to the following instruction.
*/
case OP_Rewind: { /* jump */
-#if 0 /* local variables moved into u.bl */
+#if 0 /* local variables moved into u.bq */
VdbeCursor *pC;
BtCursor *pCrsr;
int res;
-#endif /* local variables moved into u.bl */
+#endif /* local variables moved into u.bq */
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.bl.pC = p->apCsr[pOp->p1];
- assert( u.bl.pC!=0 );
- u.bl.res = 1;
- if( (u.bl.pCrsr = u.bl.pC->pCursor)!=0 ){
- rc = sqlite3BtreeFirst(u.bl.pCrsr, &u.bl.res);
- u.bl.pC->atFirst = u.bl.res==0 ?1:0;
- u.bl.pC->deferredMoveto = 0;
- u.bl.pC->cacheStatus = CACHE_STALE;
- u.bl.pC->rowidIsValid = 0;
- }
- u.bl.pC->nullRow = (u8)u.bl.res;
+ u.bq.pC = p->apCsr[pOp->p1];
+ assert( u.bq.pC!=0 );
+ assert( u.bq.pC->isSorter==(pOp->opcode==OP_SorterSort) );
+ u.bq.res = 1;
+ if( isSorter(u.bq.pC) ){
+ rc = sqlite3VdbeSorterRewind(db, u.bq.pC, &u.bq.res);
+ }else{
+ u.bq.pCrsr = u.bq.pC->pCursor;
+ assert( u.bq.pCrsr );
+ rc = sqlite3BtreeFirst(u.bq.pCrsr, &u.bq.res);
+ u.bq.pC->atFirst = u.bq.res==0 ?1:0;
+ u.bq.pC->deferredMoveto = 0;
+ u.bq.pC->cacheStatus = CACHE_STALE;
+ u.bq.pC->rowidIsValid = 0;
+ }
+ u.bq.pC->nullRow = (u8)u.bq.res;
assert( pOp->p2>0 && pOp->p2<p->nOp );
- if( u.bl.res ){
+ if( u.bq.res ){
pc = pOp->p2 - 1;
}
break;
}
-/* Opcode: Next P1 P2 * * P5
+/* Opcode: Next P1 P2 * P4 P5
**
** Advance cursor P1 so that it points to the next key/data pair in its
** table or index. If there are no more key/value pairs then fall through
@@ -67142,6 +68634,9 @@ case OP_Rewind: { /* jump */
**
** The P1 cursor must be for a real table, not a pseudo-table.
**
+** P4 is always of type P4_ADVANCE. The function pointer points to
+** sqlite3BtreeNext().
+**
** If P5 is positive and the jump is taken, then event counter
** number P5-1 in the prepared statement is incremented.
**
@@ -67156,43 +68651,49 @@ case OP_Rewind: { /* jump */
**
** The P1 cursor must be for a real table, not a pseudo-table.
**
+** P4 is always of type P4_ADVANCE. The function pointer points to
+** sqlite3BtreePrevious().
+**
** If P5 is positive and the jump is taken, then event counter
** number P5-1 in the prepared statement is incremented.
*/
+case OP_SorterNext: /* jump */
case OP_Prev: /* jump */
case OP_Next: { /* jump */
-#if 0 /* local variables moved into u.bm */
+#if 0 /* local variables moved into u.br */
VdbeCursor *pC;
- BtCursor *pCrsr;
int res;
-#endif /* local variables moved into u.bm */
+#endif /* local variables moved into u.br */
CHECK_FOR_INTERRUPT;
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
assert( pOp->p5<=ArraySize(p->aCounter) );
- u.bm.pC = p->apCsr[pOp->p1];
- if( u.bm.pC==0 ){
+ u.br.pC = p->apCsr[pOp->p1];
+ if( u.br.pC==0 ){
break; /* See ticket #2273 */
}
- u.bm.pCrsr = u.bm.pC->pCursor;
- if( u.bm.pCrsr==0 ){
- u.bm.pC->nullRow = 1;
- break;
- }
- u.bm.res = 1;
- assert( u.bm.pC->deferredMoveto==0 );
- rc = pOp->opcode==OP_Next ? sqlite3BtreeNext(u.bm.pCrsr, &u.bm.res) :
- sqlite3BtreePrevious(u.bm.pCrsr, &u.bm.res);
- u.bm.pC->nullRow = (u8)u.bm.res;
- u.bm.pC->cacheStatus = CACHE_STALE;
- if( u.bm.res==0 ){
+ assert( u.br.pC->isSorter==(pOp->opcode==OP_SorterNext) );
+ if( isSorter(u.br.pC) ){
+ assert( pOp->opcode==OP_SorterNext );
+ rc = sqlite3VdbeSorterNext(db, u.br.pC, &u.br.res);
+ }else{
+ u.br.res = 1;
+ assert( u.br.pC->deferredMoveto==0 );
+ assert( u.br.pC->pCursor );
+ assert( pOp->opcode!=OP_Next || pOp->p4.xAdvance==sqlite3BtreeNext );
+ assert( pOp->opcode!=OP_Prev || pOp->p4.xAdvance==sqlite3BtreePrevious );
+ rc = pOp->p4.xAdvance(u.br.pC->pCursor, &u.br.res);
+ }
+ u.br.pC->nullRow = (u8)u.br.res;
+ u.br.pC->cacheStatus = CACHE_STALE;
+ if( u.br.res==0 ){
pc = pOp->p2 - 1;
if( pOp->p5 ) p->aCounter[pOp->p5-1]++;
#ifdef SQLITE_TEST
sqlite3_search_count++;
#endif
}
- u.bm.pC->rowidIsValid = 0;
+ u.br.pC->rowidIsValid = 0;
break;
}
@@ -67208,31 +68709,37 @@ case OP_Next: { /* jump */
** This instruction only works for indices. The equivalent instruction
** for tables is OP_Insert.
*/
+case OP_SorterInsert: /* in2 */
case OP_IdxInsert: { /* in2 */
-#if 0 /* local variables moved into u.bn */
+#if 0 /* local variables moved into u.bs */
VdbeCursor *pC;
BtCursor *pCrsr;
int nKey;
const char *zKey;
-#endif /* local variables moved into u.bn */
+#endif /* local variables moved into u.bs */
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.bn.pC = p->apCsr[pOp->p1];
- assert( u.bn.pC!=0 );
+ u.bs.pC = p->apCsr[pOp->p1];
+ assert( u.bs.pC!=0 );
+ assert( u.bs.pC->isSorter==(pOp->opcode==OP_SorterInsert) );
pIn2 = &aMem[pOp->p2];
assert( pIn2->flags & MEM_Blob );
- u.bn.pCrsr = u.bn.pC->pCursor;
- if( ALWAYS(u.bn.pCrsr!=0) ){
- assert( u.bn.pC->isTable==0 );
+ u.bs.pCrsr = u.bs.pC->pCursor;
+ if( ALWAYS(u.bs.pCrsr!=0) ){
+ assert( u.bs.pC->isTable==0 );
rc = ExpandBlob(pIn2);
if( rc==SQLITE_OK ){
- u.bn.nKey = pIn2->n;
- u.bn.zKey = pIn2->z;
- rc = sqlite3BtreeInsert(u.bn.pCrsr, u.bn.zKey, u.bn.nKey, "", 0, 0, pOp->p3,
- ((pOp->p5 & OPFLAG_USESEEKRESULT) ? u.bn.pC->seekResult : 0)
- );
- assert( u.bn.pC->deferredMoveto==0 );
- u.bn.pC->cacheStatus = CACHE_STALE;
+ if( isSorter(u.bs.pC) ){
+ rc = sqlite3VdbeSorterWrite(db, u.bs.pC, pIn2);
+ }else{
+ u.bs.nKey = pIn2->n;
+ u.bs.zKey = pIn2->z;
+ rc = sqlite3BtreeInsert(u.bs.pCrsr, u.bs.zKey, u.bs.nKey, "", 0, 0, pOp->p3,
+ ((pOp->p5 & OPFLAG_USESEEKRESULT) ? u.bs.pC->seekResult : 0)
+ );
+ assert( u.bs.pC->deferredMoveto==0 );
+ u.bs.pC->cacheStatus = CACHE_STALE;
+ }
}
}
break;
@@ -67245,33 +68752,33 @@ case OP_IdxInsert: { /* in2 */
** index opened by cursor P1.
*/
case OP_IdxDelete: {
-#if 0 /* local variables moved into u.bo */
+#if 0 /* local variables moved into u.bt */
VdbeCursor *pC;
BtCursor *pCrsr;
int res;
UnpackedRecord r;
-#endif /* local variables moved into u.bo */
+#endif /* local variables moved into u.bt */
assert( pOp->p3>0 );
assert( pOp->p2>0 && pOp->p2+pOp->p3<=p->nMem+1 );
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.bo.pC = p->apCsr[pOp->p1];
- assert( u.bo.pC!=0 );
- u.bo.pCrsr = u.bo.pC->pCursor;
- if( ALWAYS(u.bo.pCrsr!=0) ){
- u.bo.r.pKeyInfo = u.bo.pC->pKeyInfo;
- u.bo.r.nField = (u16)pOp->p3;
- u.bo.r.flags = 0;
- u.bo.r.aMem = &aMem[pOp->p2];
+ u.bt.pC = p->apCsr[pOp->p1];
+ assert( u.bt.pC!=0 );
+ u.bt.pCrsr = u.bt.pC->pCursor;
+ if( ALWAYS(u.bt.pCrsr!=0) ){
+ u.bt.r.pKeyInfo = u.bt.pC->pKeyInfo;
+ u.bt.r.nField = (u16)pOp->p3;
+ u.bt.r.flags = 0;
+ u.bt.r.aMem = &aMem[pOp->p2];
#ifdef SQLITE_DEBUG
- { int i; for(i=0; i<u.bo.r.nField; i++) assert( memIsValid(&u.bo.r.aMem[i]) ); }
+ { int i; for(i=0; i<u.bt.r.nField; i++) assert( memIsValid(&u.bt.r.aMem[i]) ); }
#endif
- rc = sqlite3BtreeMovetoUnpacked(u.bo.pCrsr, &u.bo.r, 0, 0, &u.bo.res);
- if( rc==SQLITE_OK && u.bo.res==0 ){
- rc = sqlite3BtreeDelete(u.bo.pCrsr);
+ rc = sqlite3BtreeMovetoUnpacked(u.bt.pCrsr, &u.bt.r, 0, 0, &u.bt.res);
+ if( rc==SQLITE_OK && u.bt.res==0 ){
+ rc = sqlite3BtreeDelete(u.bt.pCrsr);
}
- assert( u.bo.pC->deferredMoveto==0 );
- u.bo.pC->cacheStatus = CACHE_STALE;
+ assert( u.bt.pC->deferredMoveto==0 );
+ u.bt.pC->cacheStatus = CACHE_STALE;
}
break;
}
@@ -67285,28 +68792,28 @@ case OP_IdxDelete: {
** See also: Rowid, MakeRecord.
*/
case OP_IdxRowid: { /* out2-prerelease */
-#if 0 /* local variables moved into u.bp */
+#if 0 /* local variables moved into u.bu */
BtCursor *pCrsr;
VdbeCursor *pC;
i64 rowid;
-#endif /* local variables moved into u.bp */
+#endif /* local variables moved into u.bu */
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.bp.pC = p->apCsr[pOp->p1];
- assert( u.bp.pC!=0 );
- u.bp.pCrsr = u.bp.pC->pCursor;
+ u.bu.pC = p->apCsr[pOp->p1];
+ assert( u.bu.pC!=0 );
+ u.bu.pCrsr = u.bu.pC->pCursor;
pOut->flags = MEM_Null;
- if( ALWAYS(u.bp.pCrsr!=0) ){
- rc = sqlite3VdbeCursorMoveto(u.bp.pC);
+ if( ALWAYS(u.bu.pCrsr!=0) ){
+ rc = sqlite3VdbeCursorMoveto(u.bu.pC);
if( NEVER(rc) ) goto abort_due_to_error;
- assert( u.bp.pC->deferredMoveto==0 );
- assert( u.bp.pC->isTable==0 );
- if( !u.bp.pC->nullRow ){
- rc = sqlite3VdbeIdxRowid(db, u.bp.pCrsr, &u.bp.rowid);
+ assert( u.bu.pC->deferredMoveto==0 );
+ assert( u.bu.pC->isTable==0 );
+ if( !u.bu.pC->nullRow ){
+ rc = sqlite3VdbeIdxRowid(db, u.bu.pCrsr, &u.bu.rowid);
if( rc!=SQLITE_OK ){
goto abort_due_to_error;
}
- pOut->u.i = u.bp.rowid;
+ pOut->u.i = u.bu.rowid;
pOut->flags = MEM_Int;
}
}
@@ -67341,39 +68848,39 @@ case OP_IdxRowid: { /* out2-prerelease */
*/
case OP_IdxLT: /* jump */
case OP_IdxGE: { /* jump */
-#if 0 /* local variables moved into u.bq */
+#if 0 /* local variables moved into u.bv */
VdbeCursor *pC;
int res;
UnpackedRecord r;
-#endif /* local variables moved into u.bq */
+#endif /* local variables moved into u.bv */
assert( pOp->p1>=0 && pOp->p1<p->nCursor );
- u.bq.pC = p->apCsr[pOp->p1];
- assert( u.bq.pC!=0 );
- assert( u.bq.pC->isOrdered );
- if( ALWAYS(u.bq.pC->pCursor!=0) ){
- assert( u.bq.pC->deferredMoveto==0 );
+ u.bv.pC = p->apCsr[pOp->p1];
+ assert( u.bv.pC!=0 );
+ assert( u.bv.pC->isOrdered );
+ if( ALWAYS(u.bv.pC->pCursor!=0) ){
+ assert( u.bv.pC->deferredMoveto==0 );
assert( pOp->p5==0 || pOp->p5==1 );
assert( pOp->p4type==P4_INT32 );
- u.bq.r.pKeyInfo = u.bq.pC->pKeyInfo;
- u.bq.r.nField = (u16)pOp->p4.i;
+ u.bv.r.pKeyInfo = u.bv.pC->pKeyInfo;
+ u.bv.r.nField = (u16)pOp->p4.i;
if( pOp->p5 ){
- u.bq.r.flags = UNPACKED_INCRKEY | UNPACKED_IGNORE_ROWID;
+ u.bv.r.flags = UNPACKED_INCRKEY | UNPACKED_PREFIX_MATCH;
}else{
- u.bq.r.flags = UNPACKED_IGNORE_ROWID;
+ u.bv.r.flags = UNPACKED_PREFIX_MATCH;
}
- u.bq.r.aMem = &aMem[pOp->p3];
+ u.bv.r.aMem = &aMem[pOp->p3];
#ifdef SQLITE_DEBUG
- { int i; for(i=0; i<u.bq.r.nField; i++) assert( memIsValid(&u.bq.r.aMem[i]) ); }
+ { int i; for(i=0; i<u.bv.r.nField; i++) assert( memIsValid(&u.bv.r.aMem[i]) ); }
#endif
- rc = sqlite3VdbeIdxKeyCompare(u.bq.pC, &u.bq.r, &u.bq.res);
+ rc = sqlite3VdbeIdxKeyCompare(u.bv.pC, &u.bv.r, &u.bv.res);
if( pOp->opcode==OP_IdxLT ){
- u.bq.res = -u.bq.res;
+ u.bv.res = -u.bv.res;
}else{
assert( pOp->opcode==OP_IdxGE );
- u.bq.res++;
+ u.bv.res++;
}
- if( u.bq.res>0 ){
+ if( u.bv.res>0 ){
pc = pOp->p2 - 1 ;
}
}
@@ -67401,39 +68908,40 @@ case OP_IdxGE: { /* jump */
** See also: Clear
*/
case OP_Destroy: { /* out2-prerelease */
-#if 0 /* local variables moved into u.br */
+#if 0 /* local variables moved into u.bw */
int iMoved;
int iCnt;
Vdbe *pVdbe;
int iDb;
-#endif /* local variables moved into u.br */
+#endif /* local variables moved into u.bw */
+
#ifndef SQLITE_OMIT_VIRTUALTABLE
- u.br.iCnt = 0;
- for(u.br.pVdbe=db->pVdbe; u.br.pVdbe; u.br.pVdbe = u.br.pVdbe->pNext){
- if( u.br.pVdbe->magic==VDBE_MAGIC_RUN && u.br.pVdbe->inVtabMethod<2 && u.br.pVdbe->pc>=0 ){
- u.br.iCnt++;
+ u.bw.iCnt = 0;
+ for(u.bw.pVdbe=db->pVdbe; u.bw.pVdbe; u.bw.pVdbe = u.bw.pVdbe->pNext){
+ if( u.bw.pVdbe->magic==VDBE_MAGIC_RUN && u.bw.pVdbe->inVtabMethod<2 && u.bw.pVdbe->pc>=0 ){
+ u.bw.iCnt++;
}
}
#else
- u.br.iCnt = db->activeVdbeCnt;
+ u.bw.iCnt = db->activeVdbeCnt;
#endif
pOut->flags = MEM_Null;
- if( u.br.iCnt>1 ){
+ if( u.bw.iCnt>1 ){
rc = SQLITE_LOCKED;
p->errorAction = OE_Abort;
}else{
- u.br.iDb = pOp->p3;
- assert( u.br.iCnt==1 );
- assert( (p->btreeMask & (((yDbMask)1)<<u.br.iDb))!=0 );
- rc = sqlite3BtreeDropTable(db->aDb[u.br.iDb].pBt, pOp->p1, &u.br.iMoved);
+ u.bw.iDb = pOp->p3;
+ assert( u.bw.iCnt==1 );
+ assert( (p->btreeMask & (((yDbMask)1)<<u.bw.iDb))!=0 );
+ rc = sqlite3BtreeDropTable(db->aDb[u.bw.iDb].pBt, pOp->p1, &u.bw.iMoved);
pOut->flags = MEM_Int;
- pOut->u.i = u.br.iMoved;
+ pOut->u.i = u.bw.iMoved;
#ifndef SQLITE_OMIT_AUTOVACUUM
- if( rc==SQLITE_OK && u.br.iMoved!=0 ){
- sqlite3RootPageMoved(db, u.br.iDb, u.br.iMoved, pOp->p1);
+ if( rc==SQLITE_OK && u.bw.iMoved!=0 ){
+ sqlite3RootPageMoved(db, u.bw.iDb, u.bw.iMoved, pOp->p1);
/* All OP_Destroy operations occur on the same btree */
- assert( resetSchemaOnFault==0 || resetSchemaOnFault==u.br.iDb+1 );
- resetSchemaOnFault = u.br.iDb+1;
+ assert( resetSchemaOnFault==0 || resetSchemaOnFault==u.bw.iDb+1 );
+ resetSchemaOnFault = u.bw.iDb+1;
}
#endif
}
@@ -67459,21 +68967,21 @@ case OP_Destroy: { /* out2-prerelease */
** See also: Destroy
*/
case OP_Clear: {
-#if 0 /* local variables moved into u.bs */
+#if 0 /* local variables moved into u.bx */
int nChange;
-#endif /* local variables moved into u.bs */
+#endif /* local variables moved into u.bx */
- u.bs.nChange = 0;
+ u.bx.nChange = 0;
assert( (p->btreeMask & (((yDbMask)1)<<pOp->p2))!=0 );
rc = sqlite3BtreeClearTable(
- db->aDb[pOp->p2].pBt, pOp->p1, (pOp->p3 ? &u.bs.nChange : 0)
+ db->aDb[pOp->p2].pBt, pOp->p1, (pOp->p3 ? &u.bx.nChange : 0)
);
if( pOp->p3 ){
- p->nChange += u.bs.nChange;
+ p->nChange += u.bx.nChange;
if( pOp->p3>0 ){
assert( memIsValid(&aMem[pOp->p3]) );
memAboutToChange(p, &aMem[pOp->p3]);
- aMem[pOp->p3].u.i += u.bs.nChange;
+ aMem[pOp->p3].u.i += u.bx.nChange;
}
}
break;
@@ -67503,25 +69011,25 @@ case OP_Clear: {
*/
case OP_CreateIndex: /* out2-prerelease */
case OP_CreateTable: { /* out2-prerelease */
-#if 0 /* local variables moved into u.bt */
+#if 0 /* local variables moved into u.by */
int pgno;
int flags;
Db *pDb;
-#endif /* local variables moved into u.bt */
+#endif /* local variables moved into u.by */
- u.bt.pgno = 0;
+ u.by.pgno = 0;
assert( pOp->p1>=0 && pOp->p1<db->nDb );
assert( (p->btreeMask & (((yDbMask)1)<<pOp->p1))!=0 );
- u.bt.pDb = &db->aDb[pOp->p1];
- assert( u.bt.pDb->pBt!=0 );
+ u.by.pDb = &db->aDb[pOp->p1];
+ assert( u.by.pDb->pBt!=0 );
if( pOp->opcode==OP_CreateTable ){
- /* u.bt.flags = BTREE_INTKEY; */
- u.bt.flags = BTREE_INTKEY;
+ /* u.by.flags = BTREE_INTKEY; */
+ u.by.flags = BTREE_INTKEY;
}else{
- u.bt.flags = BTREE_BLOBKEY;
+ u.by.flags = BTREE_BLOBKEY;
}
- rc = sqlite3BtreeCreateTable(u.bt.pDb->pBt, &u.bt.pgno, u.bt.flags);
- pOut->u.i = u.bt.pgno;
+ rc = sqlite3BtreeCreateTable(u.by.pDb->pBt, &u.by.pgno, u.by.flags);
+ pOut->u.i = u.by.pgno;
break;
}
@@ -67534,47 +69042,48 @@ case OP_CreateTable: { /* out2-prerelease */
** then runs the new virtual machine. It is thus a re-entrant opcode.
*/
case OP_ParseSchema: {
-#if 0 /* local variables moved into u.bu */
+#if 0 /* local variables moved into u.bz */
int iDb;
const char *zMaster;
char *zSql;
InitData initData;
-#endif /* local variables moved into u.bu */
+#endif /* local variables moved into u.bz */
/* Any prepared statement that invokes this opcode will hold mutexes
** on every btree. This is a prerequisite for invoking
** sqlite3InitCallback().
*/
#ifdef SQLITE_DEBUG
- for(u.bu.iDb=0; u.bu.iDb<db->nDb; u.bu.iDb++){
- assert( u.bu.iDb==1 || sqlite3BtreeHoldsMutex(db->aDb[u.bu.iDb].pBt) );
+ for(u.bz.iDb=0; u.bz.iDb<db->nDb; u.bz.iDb++){
+ assert( u.bz.iDb==1 || sqlite3BtreeHoldsMutex(db->aDb[u.bz.iDb].pBt) );
}
#endif
- u.bu.iDb = pOp->p1;
- assert( u.bu.iDb>=0 && u.bu.iDb<db->nDb );
- assert( DbHasProperty(db, u.bu.iDb, DB_SchemaLoaded) );
+ u.bz.iDb = pOp->p1;
+ assert( u.bz.iDb>=0 && u.bz.iDb<db->nDb );
+ assert( DbHasProperty(db, u.bz.iDb, DB_SchemaLoaded) );
/* Used to be a conditional */ {
- u.bu.zMaster = SCHEMA_TABLE(u.bu.iDb);
- u.bu.initData.db = db;
- u.bu.initData.iDb = pOp->p1;
- u.bu.initData.pzErrMsg = &p->zErrMsg;
- u.bu.zSql = sqlite3MPrintf(db,
+ u.bz.zMaster = SCHEMA_TABLE(u.bz.iDb);
+ u.bz.initData.db = db;
+ u.bz.initData.iDb = pOp->p1;
+ u.bz.initData.pzErrMsg = &p->zErrMsg;
+ u.bz.zSql = sqlite3MPrintf(db,
"SELECT name, rootpage, sql FROM '%q'.%s WHERE %s ORDER BY rowid",
- db->aDb[u.bu.iDb].zName, u.bu.zMaster, pOp->p4.z);
- if( u.bu.zSql==0 ){
+ db->aDb[u.bz.iDb].zName, u.bz.zMaster, pOp->p4.z);
+ if( u.bz.zSql==0 ){
rc = SQLITE_NOMEM;
}else{
assert( db->init.busy==0 );
db->init.busy = 1;
- u.bu.initData.rc = SQLITE_OK;
+ u.bz.initData.rc = SQLITE_OK;
assert( !db->mallocFailed );
- rc = sqlite3_exec(db, u.bu.zSql, sqlite3InitCallback, &u.bu.initData, 0);
- if( rc==SQLITE_OK ) rc = u.bu.initData.rc;
- sqlite3DbFree(db, u.bu.zSql);
+ rc = sqlite3_exec(db, u.bz.zSql, sqlite3InitCallback, &u.bz.initData, 0);
+ if( rc==SQLITE_OK ) rc = u.bz.initData.rc;
+ sqlite3DbFree(db, u.bz.zSql);
db->init.busy = 0;
}
}
+ if( rc ) sqlite3ResetAllSchemasOfConnection(db);
if( rc==SQLITE_NOMEM ){
goto no_mem;
}
@@ -67654,41 +69163,41 @@ case OP_DropTrigger: {
** This opcode is used to implement the integrity_check pragma.
*/
case OP_IntegrityCk: {
-#if 0 /* local variables moved into u.bv */
+#if 0 /* local variables moved into u.ca */
int nRoot; /* Number of tables to check. (Number of root pages.) */
int *aRoot; /* Array of rootpage numbers for tables to be checked */
int j; /* Loop counter */
int nErr; /* Number of errors reported */
char *z; /* Text of the error report */
Mem *pnErr; /* Register keeping track of errors remaining */
-#endif /* local variables moved into u.bv */
+#endif /* local variables moved into u.ca */
- u.bv.nRoot = pOp->p2;
- assert( u.bv.nRoot>0 );
- u.bv.aRoot = sqlite3DbMallocRaw(db, sizeof(int)*(u.bv.nRoot+1) );
- if( u.bv.aRoot==0 ) goto no_mem;
+ u.ca.nRoot = pOp->p2;
+ assert( u.ca.nRoot>0 );
+ u.ca.aRoot = sqlite3DbMallocRaw(db, sizeof(int)*(u.ca.nRoot+1) );
+ if( u.ca.aRoot==0 ) goto no_mem;
assert( pOp->p3>0 && pOp->p3<=p->nMem );
- u.bv.pnErr = &aMem[pOp->p3];
- assert( (u.bv.pnErr->flags & MEM_Int)!=0 );
- assert( (u.bv.pnErr->flags & (MEM_Str|MEM_Blob))==0 );
+ u.ca.pnErr = &aMem[pOp->p3];
+ assert( (u.ca.pnErr->flags & MEM_Int)!=0 );
+ assert( (u.ca.pnErr->flags & (MEM_Str|MEM_Blob))==0 );
pIn1 = &aMem[pOp->p1];
- for(u.bv.j=0; u.bv.j<u.bv.nRoot; u.bv.j++){
- u.bv.aRoot[u.bv.j] = (int)sqlite3VdbeIntValue(&pIn1[u.bv.j]);
+ for(u.ca.j=0; u.ca.j<u.ca.nRoot; u.ca.j++){
+ u.ca.aRoot[u.ca.j] = (int)sqlite3VdbeIntValue(&pIn1[u.ca.j]);
}
- u.bv.aRoot[u.bv.j] = 0;
+ u.ca.aRoot[u.ca.j] = 0;
assert( pOp->p5<db->nDb );
assert( (p->btreeMask & (((yDbMask)1)<<pOp->p5))!=0 );
- u.bv.z = sqlite3BtreeIntegrityCheck(db->aDb[pOp->p5].pBt, u.bv.aRoot, u.bv.nRoot,
- (int)u.bv.pnErr->u.i, &u.bv.nErr);
- sqlite3DbFree(db, u.bv.aRoot);
- u.bv.pnErr->u.i -= u.bv.nErr;
+ u.ca.z = sqlite3BtreeIntegrityCheck(db->aDb[pOp->p5].pBt, u.ca.aRoot, u.ca.nRoot,
+ (int)u.ca.pnErr->u.i, &u.ca.nErr);
+ sqlite3DbFree(db, u.ca.aRoot);
+ u.ca.pnErr->u.i -= u.ca.nErr;
sqlite3VdbeMemSetNull(pIn1);
- if( u.bv.nErr==0 ){
- assert( u.bv.z==0 );
- }else if( u.bv.z==0 ){
+ if( u.ca.nErr==0 ){
+ assert( u.ca.z==0 );
+ }else if( u.ca.z==0 ){
goto no_mem;
}else{
- sqlite3VdbeMemSetStr(pIn1, u.bv.z, -1, SQLITE_UTF8, sqlite3_free);
+ sqlite3VdbeMemSetStr(pIn1, u.ca.z, -1, SQLITE_UTF8, sqlite3_free);
}
UPDATE_MAX_BLOBSIZE(pIn1);
sqlite3VdbeChangeEncoding(pIn1, encoding);
@@ -67722,20 +69231,20 @@ case OP_RowSetAdd: { /* in1, in2 */
** unchanged and jump to instruction P2.
*/
case OP_RowSetRead: { /* jump, in1, out3 */
-#if 0 /* local variables moved into u.bw */
+#if 0 /* local variables moved into u.cb */
i64 val;
-#endif /* local variables moved into u.bw */
+#endif /* local variables moved into u.cb */
CHECK_FOR_INTERRUPT;
pIn1 = &aMem[pOp->p1];
if( (pIn1->flags & MEM_RowSet)==0
- || sqlite3RowSetNext(pIn1->u.pRowSet, &u.bw.val)==0
+ || sqlite3RowSetNext(pIn1->u.pRowSet, &u.cb.val)==0
){
/* The boolean index is empty */
sqlite3VdbeMemSetNull(pIn1);
pc = pOp->p2 - 1;
}else{
/* A value was pulled from the index */
- sqlite3VdbeMemSetInt64(&aMem[pOp->p3], u.bw.val);
+ sqlite3VdbeMemSetInt64(&aMem[pOp->p3], u.cb.val);
}
break;
}
@@ -67764,14 +69273,14 @@ case OP_RowSetRead: { /* jump, in1, out3 */
** inserted as part of some other set).
*/
case OP_RowSetTest: { /* jump, in1, in3 */
-#if 0 /* local variables moved into u.bx */
+#if 0 /* local variables moved into u.cc */
int iSet;
int exists;
-#endif /* local variables moved into u.bx */
+#endif /* local variables moved into u.cc */
pIn1 = &aMem[pOp->p1];
pIn3 = &aMem[pOp->p3];
- u.bx.iSet = pOp->p4.i;
+ u.cc.iSet = pOp->p4.i;
assert( pIn3->flags&MEM_Int );
/* If there is anything other than a rowset object in memory cell P1,
@@ -67783,17 +69292,17 @@ case OP_RowSetTest: { /* jump, in1, in3 */
}
assert( pOp->p4type==P4_INT32 );
- assert( u.bx.iSet==-1 || u.bx.iSet>=0 );
- if( u.bx.iSet ){
- u.bx.exists = sqlite3RowSetTest(pIn1->u.pRowSet,
- (u8)(u.bx.iSet>=0 ? u.bx.iSet & 0xf : 0xff),
+ assert( u.cc.iSet==-1 || u.cc.iSet>=0 );
+ if( u.cc.iSet ){
+ u.cc.exists = sqlite3RowSetTest(pIn1->u.pRowSet,
+ (u8)(u.cc.iSet>=0 ? u.cc.iSet & 0xf : 0xff),
pIn3->u.i);
- if( u.bx.exists ){
+ if( u.cc.exists ){
pc = pOp->p2 - 1;
break;
}
}
- if( u.bx.iSet>=0 ){
+ if( u.cc.iSet>=0 ){
sqlite3RowSetInsert(pIn1->u.pRowSet, pIn3->u.i);
}
break;
@@ -67816,7 +69325,7 @@ case OP_RowSetTest: { /* jump, in1, in3 */
** P4 is a pointer to the VM containing the trigger program.
*/
case OP_Program: { /* jump */
-#if 0 /* local variables moved into u.by */
+#if 0 /* local variables moved into u.cd */
int nMem; /* Number of memory registers for sub-program */
int nByte; /* Bytes of runtime space required for sub-program */
Mem *pRt; /* Register to allocate runtime space */
@@ -67825,12 +69334,11 @@ case OP_Program: { /* jump */
VdbeFrame *pFrame; /* New vdbe frame to execute in */
SubProgram *pProgram; /* Sub-program to execute */
void *t; /* Token identifying trigger */
-#endif /* local variables moved into u.by */
+#endif /* local variables moved into u.cd */
- u.by.pProgram = pOp->p4.pProgram;
- u.by.pRt = &aMem[pOp->p3];
- assert( memIsValid(u.by.pRt) );
- assert( u.by.pProgram->nOp>0 );
+ u.cd.pProgram = pOp->p4.pProgram;
+ u.cd.pRt = &aMem[pOp->p3];
+ assert( u.cd.pProgram->nOp>0 );
/* If the p5 flag is clear, then recursive invocation of triggers is
** disabled for backwards compatibility (p5 is set if this sub-program
@@ -67844,9 +69352,9 @@ case OP_Program: { /* jump */
** single trigger all have the same value for the SubProgram.token
** variable. */
if( pOp->p5 ){
- u.by.t = u.by.pProgram->token;
- for(u.by.pFrame=p->pFrame; u.by.pFrame && u.by.pFrame->token!=u.by.t; u.by.pFrame=u.by.pFrame->pParent);
- if( u.by.pFrame ) break;
+ u.cd.t = u.cd.pProgram->token;
+ for(u.cd.pFrame=p->pFrame; u.cd.pFrame && u.cd.pFrame->token!=u.cd.t; u.cd.pFrame=u.cd.pFrame->pParent);
+ if( u.cd.pFrame ) break;
}
if( p->nFrame>=db->aLimit[SQLITE_LIMIT_TRIGGER_DEPTH] ){
@@ -67855,65 +69363,71 @@ case OP_Program: { /* jump */
break;
}
- /* Register u.by.pRt is used to store the memory required to save the state
+ /* Register u.cd.pRt is used to store the memory required to save the state
** of the current program, and the memory required at runtime to execute
- ** the trigger program. If this trigger has been fired before, then u.by.pRt
+ ** the trigger program. If this trigger has been fired before, then u.cd.pRt
** is already allocated. Otherwise, it must be initialized. */
- if( (u.by.pRt->flags&MEM_Frame)==0 ){
+ if( (u.cd.pRt->flags&MEM_Frame)==0 ){
/* SubProgram.nMem is set to the number of memory cells used by the
** program stored in SubProgram.aOp. As well as these, one memory
** cell is required for each cursor used by the program. Set local
- ** variable u.by.nMem (and later, VdbeFrame.nChildMem) to this value.
+ ** variable u.cd.nMem (and later, VdbeFrame.nChildMem) to this value.
*/
- u.by.nMem = u.by.pProgram->nMem + u.by.pProgram->nCsr;
- u.by.nByte = ROUND8(sizeof(VdbeFrame))
- + u.by.nMem * sizeof(Mem)
- + u.by.pProgram->nCsr * sizeof(VdbeCursor *);
- u.by.pFrame = sqlite3DbMallocZero(db, u.by.nByte);
- if( !u.by.pFrame ){
+ u.cd.nMem = u.cd.pProgram->nMem + u.cd.pProgram->nCsr;
+ u.cd.nByte = ROUND8(sizeof(VdbeFrame))
+ + u.cd.nMem * sizeof(Mem)
+ + u.cd.pProgram->nCsr * sizeof(VdbeCursor *)
+ + u.cd.pProgram->nOnce * sizeof(u8);
+ u.cd.pFrame = sqlite3DbMallocZero(db, u.cd.nByte);
+ if( !u.cd.pFrame ){
goto no_mem;
}
- sqlite3VdbeMemRelease(u.by.pRt);
- u.by.pRt->flags = MEM_Frame;
- u.by.pRt->u.pFrame = u.by.pFrame;
-
- u.by.pFrame->v = p;
- u.by.pFrame->nChildMem = u.by.nMem;
- u.by.pFrame->nChildCsr = u.by.pProgram->nCsr;
- u.by.pFrame->pc = pc;
- u.by.pFrame->aMem = p->aMem;
- u.by.pFrame->nMem = p->nMem;
- u.by.pFrame->apCsr = p->apCsr;
- u.by.pFrame->nCursor = p->nCursor;
- u.by.pFrame->aOp = p->aOp;
- u.by.pFrame->nOp = p->nOp;
- u.by.pFrame->token = u.by.pProgram->token;
-
- u.by.pEnd = &VdbeFrameMem(u.by.pFrame)[u.by.pFrame->nChildMem];
- for(u.by.pMem=VdbeFrameMem(u.by.pFrame); u.by.pMem!=u.by.pEnd; u.by.pMem++){
- u.by.pMem->flags = MEM_Null;
- u.by.pMem->db = db;
+ sqlite3VdbeMemRelease(u.cd.pRt);
+ u.cd.pRt->flags = MEM_Frame;
+ u.cd.pRt->u.pFrame = u.cd.pFrame;
+
+ u.cd.pFrame->v = p;
+ u.cd.pFrame->nChildMem = u.cd.nMem;
+ u.cd.pFrame->nChildCsr = u.cd.pProgram->nCsr;
+ u.cd.pFrame->pc = pc;
+ u.cd.pFrame->aMem = p->aMem;
+ u.cd.pFrame->nMem = p->nMem;
+ u.cd.pFrame->apCsr = p->apCsr;
+ u.cd.pFrame->nCursor = p->nCursor;
+ u.cd.pFrame->aOp = p->aOp;
+ u.cd.pFrame->nOp = p->nOp;
+ u.cd.pFrame->token = u.cd.pProgram->token;
+ u.cd.pFrame->aOnceFlag = p->aOnceFlag;
+ u.cd.pFrame->nOnceFlag = p->nOnceFlag;
+
+ u.cd.pEnd = &VdbeFrameMem(u.cd.pFrame)[u.cd.pFrame->nChildMem];
+ for(u.cd.pMem=VdbeFrameMem(u.cd.pFrame); u.cd.pMem!=u.cd.pEnd; u.cd.pMem++){
+ u.cd.pMem->flags = MEM_Invalid;
+ u.cd.pMem->db = db;
}
}else{
- u.by.pFrame = u.by.pRt->u.pFrame;
- assert( u.by.pProgram->nMem+u.by.pProgram->nCsr==u.by.pFrame->nChildMem );
- assert( u.by.pProgram->nCsr==u.by.pFrame->nChildCsr );
- assert( pc==u.by.pFrame->pc );
+ u.cd.pFrame = u.cd.pRt->u.pFrame;
+ assert( u.cd.pProgram->nMem+u.cd.pProgram->nCsr==u.cd.pFrame->nChildMem );
+ assert( u.cd.pProgram->nCsr==u.cd.pFrame->nChildCsr );
+ assert( pc==u.cd.pFrame->pc );
}
p->nFrame++;
- u.by.pFrame->pParent = p->pFrame;
- u.by.pFrame->lastRowid = lastRowid;
- u.by.pFrame->nChange = p->nChange;
+ u.cd.pFrame->pParent = p->pFrame;
+ u.cd.pFrame->lastRowid = lastRowid;
+ u.cd.pFrame->nChange = p->nChange;
p->nChange = 0;
- p->pFrame = u.by.pFrame;
- p->aMem = aMem = &VdbeFrameMem(u.by.pFrame)[-1];
- p->nMem = u.by.pFrame->nChildMem;
- p->nCursor = (u16)u.by.pFrame->nChildCsr;
+ p->pFrame = u.cd.pFrame;
+ p->aMem = aMem = &VdbeFrameMem(u.cd.pFrame)[-1];
+ p->nMem = u.cd.pFrame->nChildMem;
+ p->nCursor = (u16)u.cd.pFrame->nChildCsr;
p->apCsr = (VdbeCursor **)&aMem[p->nMem+1];
- p->aOp = aOp = u.by.pProgram->aOp;
- p->nOp = u.by.pProgram->nOp;
+ p->aOp = aOp = u.cd.pProgram->aOp;
+ p->nOp = u.cd.pProgram->nOp;
+ p->aOnceFlag = (u8 *)&p->apCsr[p->nCursor];
+ p->nOnceFlag = u.cd.pProgram->nOnce;
pc = -1;
+ memset(p->aOnceFlag, 0, p->nOnceFlag);
break;
}
@@ -67931,13 +69445,13 @@ case OP_Program: { /* jump */
** calling OP_Program instruction.
*/
case OP_Param: { /* out2-prerelease */
-#if 0 /* local variables moved into u.bz */
+#if 0 /* local variables moved into u.ce */
VdbeFrame *pFrame;
Mem *pIn;
-#endif /* local variables moved into u.bz */
- u.bz.pFrame = p->pFrame;
- u.bz.pIn = &u.bz.pFrame->aMem[pOp->p1 + u.bz.pFrame->aOp[u.bz.pFrame->pc].p1];
- sqlite3VdbeMemShallowCopy(pOut, u.bz.pIn, MEM_Ephem);
+#endif /* local variables moved into u.ce */
+ u.ce.pFrame = p->pFrame;
+ u.ce.pIn = &u.ce.pFrame->aMem[pOp->p1 + u.ce.pFrame->aOp[u.ce.pFrame->pc].p1];
+ sqlite3VdbeMemShallowCopy(pOut, u.ce.pIn, MEM_Ephem);
break;
}
@@ -67993,22 +69507,22 @@ case OP_FkIfZero: { /* jump */
** an integer.
*/
case OP_MemMax: { /* in2 */
-#if 0 /* local variables moved into u.ca */
+#if 0 /* local variables moved into u.cf */
Mem *pIn1;
VdbeFrame *pFrame;
-#endif /* local variables moved into u.ca */
+#endif /* local variables moved into u.cf */
if( p->pFrame ){
- for(u.ca.pFrame=p->pFrame; u.ca.pFrame->pParent; u.ca.pFrame=u.ca.pFrame->pParent);
- u.ca.pIn1 = &u.ca.pFrame->aMem[pOp->p1];
+ for(u.cf.pFrame=p->pFrame; u.cf.pFrame->pParent; u.cf.pFrame=u.cf.pFrame->pParent);
+ u.cf.pIn1 = &u.cf.pFrame->aMem[pOp->p1];
}else{
- u.ca.pIn1 = &aMem[pOp->p1];
+ u.cf.pIn1 = &aMem[pOp->p1];
}
- assert( memIsValid(u.ca.pIn1) );
- sqlite3VdbeMemIntegerify(u.ca.pIn1);
+ assert( memIsValid(u.cf.pIn1) );
+ sqlite3VdbeMemIntegerify(u.cf.pIn1);
pIn2 = &aMem[pOp->p2];
sqlite3VdbeMemIntegerify(pIn2);
- if( u.ca.pIn1->u.i<pIn2->u.i){
- u.ca.pIn1->u.i = pIn2->u.i;
+ if( u.cf.pIn1->u.i<pIn2->u.i){
+ u.cf.pIn1->u.i = pIn2->u.i;
}
break;
}
@@ -68075,50 +69589,56 @@ case OP_IfZero: { /* jump, in1 */
** successors.
*/
case OP_AggStep: {
-#if 0 /* local variables moved into u.cb */
+#if 0 /* local variables moved into u.cg */
int n;
int i;
Mem *pMem;
Mem *pRec;
sqlite3_context ctx;
sqlite3_value **apVal;
-#endif /* local variables moved into u.cb */
+#endif /* local variables moved into u.cg */
- u.cb.n = pOp->p5;
- assert( u.cb.n>=0 );
- u.cb.pRec = &aMem[pOp->p2];
- u.cb.apVal = p->apArg;
- assert( u.cb.apVal || u.cb.n==0 );
- for(u.cb.i=0; u.cb.i<u.cb.n; u.cb.i++, u.cb.pRec++){
- assert( memIsValid(u.cb.pRec) );
- u.cb.apVal[u.cb.i] = u.cb.pRec;
- memAboutToChange(p, u.cb.pRec);
- sqlite3VdbeMemStoreType(u.cb.pRec);
- }
- u.cb.ctx.pFunc = pOp->p4.pFunc;
+ u.cg.n = pOp->p5;
+ assert( u.cg.n>=0 );
+ u.cg.pRec = &aMem[pOp->p2];
+ u.cg.apVal = p->apArg;
+ assert( u.cg.apVal || u.cg.n==0 );
+ for(u.cg.i=0; u.cg.i<u.cg.n; u.cg.i++, u.cg.pRec++){
+ assert( memIsValid(u.cg.pRec) );
+ u.cg.apVal[u.cg.i] = u.cg.pRec;
+ memAboutToChange(p, u.cg.pRec);
+ sqlite3VdbeMemStoreType(u.cg.pRec);
+ }
+ u.cg.ctx.pFunc = pOp->p4.pFunc;
assert( pOp->p3>0 && pOp->p3<=p->nMem );
- u.cb.ctx.pMem = u.cb.pMem = &aMem[pOp->p3];
- u.cb.pMem->n++;
- u.cb.ctx.s.flags = MEM_Null;
- u.cb.ctx.s.z = 0;
- u.cb.ctx.s.zMalloc = 0;
- u.cb.ctx.s.xDel = 0;
- u.cb.ctx.s.db = db;
- u.cb.ctx.isError = 0;
- u.cb.ctx.pColl = 0;
- if( u.cb.ctx.pFunc->flags & SQLITE_FUNC_NEEDCOLL ){
+ u.cg.ctx.pMem = u.cg.pMem = &aMem[pOp->p3];
+ u.cg.pMem->n++;
+ u.cg.ctx.s.flags = MEM_Null;
+ u.cg.ctx.s.z = 0;
+ u.cg.ctx.s.zMalloc = 0;
+ u.cg.ctx.s.xDel = 0;
+ u.cg.ctx.s.db = db;
+ u.cg.ctx.isError = 0;
+ u.cg.ctx.pColl = 0;
+ u.cg.ctx.skipFlag = 0;
+ if( u.cg.ctx.pFunc->flags & SQLITE_FUNC_NEEDCOLL ){
assert( pOp>p->aOp );
assert( pOp[-1].p4type==P4_COLLSEQ );
assert( pOp[-1].opcode==OP_CollSeq );
- u.cb.ctx.pColl = pOp[-1].p4.pColl;
+ u.cg.ctx.pColl = pOp[-1].p4.pColl;
}
- (u.cb.ctx.pFunc->xStep)(&u.cb.ctx, u.cb.n, u.cb.apVal); /* IMP: R-24505-23230 */
- if( u.cb.ctx.isError ){
- sqlite3SetString(&p->zErrMsg, db, "%s", sqlite3_value_text(&u.cb.ctx.s));
- rc = u.cb.ctx.isError;
+ (u.cg.ctx.pFunc->xStep)(&u.cg.ctx, u.cg.n, u.cg.apVal); /* IMP: R-24505-23230 */
+ if( u.cg.ctx.isError ){
+ sqlite3SetString(&p->zErrMsg, db, "%s", sqlite3_value_text(&u.cg.ctx.s));
+ rc = u.cg.ctx.isError;
+ }
+ if( u.cg.ctx.skipFlag ){
+ assert( pOp[-1].opcode==OP_CollSeq );
+ u.cg.i = pOp[-1].p1;
+ if( u.cg.i ) sqlite3VdbeMemSetInt64(&aMem[u.cg.i], 1);
}
- sqlite3VdbeMemRelease(&u.cb.ctx.s);
+ sqlite3VdbeMemRelease(&u.cg.ctx.s);
break;
}
@@ -68136,19 +69656,19 @@ case OP_AggStep: {
** the step function was not previously called.
*/
case OP_AggFinal: {
-#if 0 /* local variables moved into u.cc */
+#if 0 /* local variables moved into u.ch */
Mem *pMem;
-#endif /* local variables moved into u.cc */
+#endif /* local variables moved into u.ch */
assert( pOp->p1>0 && pOp->p1<=p->nMem );
- u.cc.pMem = &aMem[pOp->p1];
- assert( (u.cc.pMem->flags & ~(MEM_Null|MEM_Agg))==0 );
- rc = sqlite3VdbeMemFinalize(u.cc.pMem, pOp->p4.pFunc);
+ u.ch.pMem = &aMem[pOp->p1];
+ assert( (u.ch.pMem->flags & ~(MEM_Null|MEM_Agg))==0 );
+ rc = sqlite3VdbeMemFinalize(u.ch.pMem, pOp->p4.pFunc);
if( rc ){
- sqlite3SetString(&p->zErrMsg, db, "%s", sqlite3_value_text(u.cc.pMem));
+ sqlite3SetString(&p->zErrMsg, db, "%s", sqlite3_value_text(u.ch.pMem));
}
- sqlite3VdbeChangeEncoding(u.cc.pMem, encoding);
- UPDATE_MAX_BLOBSIZE(u.cc.pMem);
- if( sqlite3VdbeMemTooBig(u.cc.pMem) ){
+ sqlite3VdbeChangeEncoding(u.ch.pMem, encoding);
+ UPDATE_MAX_BLOBSIZE(u.ch.pMem);
+ if( sqlite3VdbeMemTooBig(u.ch.pMem) ){
goto too_big;
}
break;
@@ -68167,25 +69687,25 @@ case OP_AggFinal: {
** mem[P3+2] are initialized to -1.
*/
case OP_Checkpoint: {
-#if 0 /* local variables moved into u.cd */
+#if 0 /* local variables moved into u.ci */
int i; /* Loop counter */
int aRes[3]; /* Results */
Mem *pMem; /* Write results here */
-#endif /* local variables moved into u.cd */
+#endif /* local variables moved into u.ci */
- u.cd.aRes[0] = 0;
- u.cd.aRes[1] = u.cd.aRes[2] = -1;
+ u.ci.aRes[0] = 0;
+ u.ci.aRes[1] = u.ci.aRes[2] = -1;
assert( pOp->p2==SQLITE_CHECKPOINT_PASSIVE
|| pOp->p2==SQLITE_CHECKPOINT_FULL
|| pOp->p2==SQLITE_CHECKPOINT_RESTART
);
- rc = sqlite3Checkpoint(db, pOp->p1, pOp->p2, &u.cd.aRes[1], &u.cd.aRes[2]);
+ rc = sqlite3Checkpoint(db, pOp->p1, pOp->p2, &u.ci.aRes[1], &u.ci.aRes[2]);
if( rc==SQLITE_BUSY ){
rc = SQLITE_OK;
- u.cd.aRes[0] = 1;
+ u.ci.aRes[0] = 1;
}
- for(u.cd.i=0, u.cd.pMem = &aMem[pOp->p3]; u.cd.i<3; u.cd.i++, u.cd.pMem++){
- sqlite3VdbeMemSetInt64(u.cd.pMem, (i64)u.cd.aRes[u.cd.i]);
+ for(u.ci.i=0, u.ci.pMem = &aMem[pOp->p3]; u.ci.i<3; u.ci.i++, u.ci.pMem++){
+ sqlite3VdbeMemSetInt64(u.ci.pMem, (i64)u.ci.aRes[u.ci.i]);
}
break;
};
@@ -68204,91 +69724,93 @@ case OP_Checkpoint: {
** Write a string containing the final journal-mode to register P2.
*/
case OP_JournalMode: { /* out2-prerelease */
-#if 0 /* local variables moved into u.ce */
+#if 0 /* local variables moved into u.cj */
Btree *pBt; /* Btree to change journal mode of */
Pager *pPager; /* Pager associated with pBt */
int eNew; /* New journal mode */
int eOld; /* The old journal mode */
+#ifndef SQLITE_OMIT_WAL
const char *zFilename; /* Name of database file for pPager */
-#endif /* local variables moved into u.ce */
+#endif
+#endif /* local variables moved into u.cj */
- u.ce.eNew = pOp->p3;
- assert( u.ce.eNew==PAGER_JOURNALMODE_DELETE
- || u.ce.eNew==PAGER_JOURNALMODE_TRUNCATE
- || u.ce.eNew==PAGER_JOURNALMODE_PERSIST
- || u.ce.eNew==PAGER_JOURNALMODE_OFF
- || u.ce.eNew==PAGER_JOURNALMODE_MEMORY
- || u.ce.eNew==PAGER_JOURNALMODE_WAL
- || u.ce.eNew==PAGER_JOURNALMODE_QUERY
+ u.cj.eNew = pOp->p3;
+ assert( u.cj.eNew==PAGER_JOURNALMODE_DELETE
+ || u.cj.eNew==PAGER_JOURNALMODE_TRUNCATE
+ || u.cj.eNew==PAGER_JOURNALMODE_PERSIST
+ || u.cj.eNew==PAGER_JOURNALMODE_OFF
+ || u.cj.eNew==PAGER_JOURNALMODE_MEMORY
+ || u.cj.eNew==PAGER_JOURNALMODE_WAL
+ || u.cj.eNew==PAGER_JOURNALMODE_QUERY
);
assert( pOp->p1>=0 && pOp->p1<db->nDb );
- u.ce.pBt = db->aDb[pOp->p1].pBt;
- u.ce.pPager = sqlite3BtreePager(u.ce.pBt);
- u.ce.eOld = sqlite3PagerGetJournalMode(u.ce.pPager);
- if( u.ce.eNew==PAGER_JOURNALMODE_QUERY ) u.ce.eNew = u.ce.eOld;
- if( !sqlite3PagerOkToChangeJournalMode(u.ce.pPager) ) u.ce.eNew = u.ce.eOld;
+ u.cj.pBt = db->aDb[pOp->p1].pBt;
+ u.cj.pPager = sqlite3BtreePager(u.cj.pBt);
+ u.cj.eOld = sqlite3PagerGetJournalMode(u.cj.pPager);
+ if( u.cj.eNew==PAGER_JOURNALMODE_QUERY ) u.cj.eNew = u.cj.eOld;
+ if( !sqlite3PagerOkToChangeJournalMode(u.cj.pPager) ) u.cj.eNew = u.cj.eOld;
#ifndef SQLITE_OMIT_WAL
- u.ce.zFilename = sqlite3PagerFilename(u.ce.pPager);
+ u.cj.zFilename = sqlite3PagerFilename(u.cj.pPager, 1);
/* Do not allow a transition to journal_mode=WAL for a database
** in temporary storage or if the VFS does not support shared memory
*/
- if( u.ce.eNew==PAGER_JOURNALMODE_WAL
- && (u.ce.zFilename[0]==0 /* Temp file */
- || !sqlite3PagerWalSupported(u.ce.pPager)) /* No shared-memory support */
+ if( u.cj.eNew==PAGER_JOURNALMODE_WAL
+ && (sqlite3Strlen30(u.cj.zFilename)==0 /* Temp file */
+ || !sqlite3PagerWalSupported(u.cj.pPager)) /* No shared-memory support */
){
- u.ce.eNew = u.ce.eOld;
+ u.cj.eNew = u.cj.eOld;
}
- if( (u.ce.eNew!=u.ce.eOld)
- && (u.ce.eOld==PAGER_JOURNALMODE_WAL || u.ce.eNew==PAGER_JOURNALMODE_WAL)
+ if( (u.cj.eNew!=u.cj.eOld)
+ && (u.cj.eOld==PAGER_JOURNALMODE_WAL || u.cj.eNew==PAGER_JOURNALMODE_WAL)
){
if( !db->autoCommit || db->activeVdbeCnt>1 ){
rc = SQLITE_ERROR;
sqlite3SetString(&p->zErrMsg, db,
"cannot change %s wal mode from within a transaction",
- (u.ce.eNew==PAGER_JOURNALMODE_WAL ? "into" : "out of")
+ (u.cj.eNew==PAGER_JOURNALMODE_WAL ? "into" : "out of")
);
break;
}else{
- if( u.ce.eOld==PAGER_JOURNALMODE_WAL ){
+ if( u.cj.eOld==PAGER_JOURNALMODE_WAL ){
/* If leaving WAL mode, close the log file. If successful, the call
** to PagerCloseWal() checkpoints and deletes the write-ahead-log
** file. An EXCLUSIVE lock may still be held on the database file
** after a successful return.
*/
- rc = sqlite3PagerCloseWal(u.ce.pPager);
+ rc = sqlite3PagerCloseWal(u.cj.pPager);
if( rc==SQLITE_OK ){
- sqlite3PagerSetJournalMode(u.ce.pPager, u.ce.eNew);
+ sqlite3PagerSetJournalMode(u.cj.pPager, u.cj.eNew);
}
- }else if( u.ce.eOld==PAGER_JOURNALMODE_MEMORY ){
+ }else if( u.cj.eOld==PAGER_JOURNALMODE_MEMORY ){
/* Cannot transition directly from MEMORY to WAL. Use mode OFF
** as an intermediate */
- sqlite3PagerSetJournalMode(u.ce.pPager, PAGER_JOURNALMODE_OFF);
+ sqlite3PagerSetJournalMode(u.cj.pPager, PAGER_JOURNALMODE_OFF);
}
/* Open a transaction on the database file. Regardless of the journal
** mode, this transaction always uses a rollback journal.
*/
- assert( sqlite3BtreeIsInTrans(u.ce.pBt)==0 );
+ assert( sqlite3BtreeIsInTrans(u.cj.pBt)==0 );
if( rc==SQLITE_OK ){
- rc = sqlite3BtreeSetVersion(u.ce.pBt, (u.ce.eNew==PAGER_JOURNALMODE_WAL ? 2 : 1));
+ rc = sqlite3BtreeSetVersion(u.cj.pBt, (u.cj.eNew==PAGER_JOURNALMODE_WAL ? 2 : 1));
}
}
}
#endif /* ifndef SQLITE_OMIT_WAL */
if( rc ){
- u.ce.eNew = u.ce.eOld;
+ u.cj.eNew = u.cj.eOld;
}
- u.ce.eNew = sqlite3PagerSetJournalMode(u.ce.pPager, u.ce.eNew);
+ u.cj.eNew = sqlite3PagerSetJournalMode(u.cj.pPager, u.cj.eNew);
pOut = &aMem[pOp->p2];
pOut->flags = MEM_Str|MEM_Static|MEM_Term;
- pOut->z = (char *)sqlite3JournalModename(u.ce.eNew);
+ pOut->z = (char *)sqlite3JournalModename(u.cj.eNew);
pOut->n = sqlite3Strlen30(pOut->z);
pOut->enc = SQLITE_UTF8;
sqlite3VdbeChangeEncoding(pOut, encoding);
@@ -68317,14 +69839,14 @@ case OP_Vacuum: {
** P2. Otherwise, fall through to the next instruction.
*/
case OP_IncrVacuum: { /* jump */
-#if 0 /* local variables moved into u.cf */
+#if 0 /* local variables moved into u.ck */
Btree *pBt;
-#endif /* local variables moved into u.cf */
+#endif /* local variables moved into u.ck */
assert( pOp->p1>=0 && pOp->p1<db->nDb );
assert( (p->btreeMask & (((yDbMask)1)<<pOp->p1))!=0 );
- u.cf.pBt = db->aDb[pOp->p1].pBt;
- rc = sqlite3BtreeIncrVacuum(u.cf.pBt);
+ u.ck.pBt = db->aDb[pOp->p1].pBt;
+ rc = sqlite3BtreeIncrVacuum(u.ck.pBt);
if( rc==SQLITE_DONE ){
pc = pOp->p2 - 1;
rc = SQLITE_OK;
@@ -68394,12 +69916,12 @@ case OP_TableLock: {
** code will be set to SQLITE_LOCKED.
*/
case OP_VBegin: {
-#if 0 /* local variables moved into u.cg */
+#if 0 /* local variables moved into u.cl */
VTable *pVTab;
-#endif /* local variables moved into u.cg */
- u.cg.pVTab = pOp->p4.pVtab;
- rc = sqlite3VtabBegin(db, u.cg.pVTab);
- if( u.cg.pVTab ) importVtabErrMsg(p, u.cg.pVTab->pVtab);
+#endif /* local variables moved into u.cl */
+ u.cl.pVTab = pOp->p4.pVtab;
+ rc = sqlite3VtabBegin(db, u.cl.pVTab);
+ if( u.cl.pVTab ) importVtabErrMsg(p, u.cl.pVTab->pVtab);
break;
}
#endif /* SQLITE_OMIT_VIRTUALTABLE */
@@ -68438,32 +69960,32 @@ case OP_VDestroy: {
** table and stores that cursor in P1.
*/
case OP_VOpen: {
-#if 0 /* local variables moved into u.ch */
+#if 0 /* local variables moved into u.cm */
VdbeCursor *pCur;
sqlite3_vtab_cursor *pVtabCursor;
sqlite3_vtab *pVtab;
sqlite3_module *pModule;
-#endif /* local variables moved into u.ch */
+#endif /* local variables moved into u.cm */
- u.ch.pCur = 0;
- u.ch.pVtabCursor = 0;
- u.ch.pVtab = pOp->p4.pVtab->pVtab;
- u.ch.pModule = (sqlite3_module *)u.ch.pVtab->pModule;
- assert(u.ch.pVtab && u.ch.pModule);
- rc = u.ch.pModule->xOpen(u.ch.pVtab, &u.ch.pVtabCursor);
- importVtabErrMsg(p, u.ch.pVtab);
+ u.cm.pCur = 0;
+ u.cm.pVtabCursor = 0;
+ u.cm.pVtab = pOp->p4.pVtab->pVtab;
+ u.cm.pModule = (sqlite3_module *)u.cm.pVtab->pModule;
+ assert(u.cm.pVtab && u.cm.pModule);
+ rc = u.cm.pModule->xOpen(u.cm.pVtab, &u.cm.pVtabCursor);
+ importVtabErrMsg(p, u.cm.pVtab);
if( SQLITE_OK==rc ){
/* Initialize sqlite3_vtab_cursor base class */
- u.ch.pVtabCursor->pVtab = u.ch.pVtab;
+ u.cm.pVtabCursor->pVtab = u.cm.pVtab;
- /* Initialise vdbe cursor object */
- u.ch.pCur = allocateCursor(p, pOp->p1, 0, -1, 0);
- if( u.ch.pCur ){
- u.ch.pCur->pVtabCursor = u.ch.pVtabCursor;
- u.ch.pCur->pModule = u.ch.pVtabCursor->pVtab->pModule;
+ /* Initialize vdbe cursor object */
+ u.cm.pCur = allocateCursor(p, pOp->p1, 0, -1, 0);
+ if( u.cm.pCur ){
+ u.cm.pCur->pVtabCursor = u.cm.pVtabCursor;
+ u.cm.pCur->pModule = u.cm.pVtabCursor->pVtab->pModule;
}else{
db->mallocFailed = 1;
- u.ch.pModule->xClose(u.ch.pVtabCursor);
+ u.cm.pModule->xClose(u.cm.pVtabCursor);
}
}
break;
@@ -68490,7 +70012,7 @@ case OP_VOpen: {
** A jump is made to P2 if the result set after filtering would be empty.
*/
case OP_VFilter: { /* jump */
-#if 0 /* local variables moved into u.ci */
+#if 0 /* local variables moved into u.cn */
int nArg;
int iQuery;
const sqlite3_module *pModule;
@@ -68502,45 +70024,45 @@ case OP_VFilter: { /* jump */
int res;
int i;
Mem **apArg;
-#endif /* local variables moved into u.ci */
+#endif /* local variables moved into u.cn */
- u.ci.pQuery = &aMem[pOp->p3];
- u.ci.pArgc = &u.ci.pQuery[1];
- u.ci.pCur = p->apCsr[pOp->p1];
- assert( memIsValid(u.ci.pQuery) );
- REGISTER_TRACE(pOp->p3, u.ci.pQuery);
- assert( u.ci.pCur->pVtabCursor );
- u.ci.pVtabCursor = u.ci.pCur->pVtabCursor;
- u.ci.pVtab = u.ci.pVtabCursor->pVtab;
- u.ci.pModule = u.ci.pVtab->pModule;
+ u.cn.pQuery = &aMem[pOp->p3];
+ u.cn.pArgc = &u.cn.pQuery[1];
+ u.cn.pCur = p->apCsr[pOp->p1];
+ assert( memIsValid(u.cn.pQuery) );
+ REGISTER_TRACE(pOp->p3, u.cn.pQuery);
+ assert( u.cn.pCur->pVtabCursor );
+ u.cn.pVtabCursor = u.cn.pCur->pVtabCursor;
+ u.cn.pVtab = u.cn.pVtabCursor->pVtab;
+ u.cn.pModule = u.cn.pVtab->pModule;
/* Grab the index number and argc parameters */
- assert( (u.ci.pQuery->flags&MEM_Int)!=0 && u.ci.pArgc->flags==MEM_Int );
- u.ci.nArg = (int)u.ci.pArgc->u.i;
- u.ci.iQuery = (int)u.ci.pQuery->u.i;
+ assert( (u.cn.pQuery->flags&MEM_Int)!=0 && u.cn.pArgc->flags==MEM_Int );
+ u.cn.nArg = (int)u.cn.pArgc->u.i;
+ u.cn.iQuery = (int)u.cn.pQuery->u.i;
/* Invoke the xFilter method */
{
- u.ci.res = 0;
- u.ci.apArg = p->apArg;
- for(u.ci.i = 0; u.ci.i<u.ci.nArg; u.ci.i++){
- u.ci.apArg[u.ci.i] = &u.ci.pArgc[u.ci.i+1];
- sqlite3VdbeMemStoreType(u.ci.apArg[u.ci.i]);
+ u.cn.res = 0;
+ u.cn.apArg = p->apArg;
+ for(u.cn.i = 0; u.cn.i<u.cn.nArg; u.cn.i++){
+ u.cn.apArg[u.cn.i] = &u.cn.pArgc[u.cn.i+1];
+ sqlite3VdbeMemStoreType(u.cn.apArg[u.cn.i]);
}
p->inVtabMethod = 1;
- rc = u.ci.pModule->xFilter(u.ci.pVtabCursor, u.ci.iQuery, pOp->p4.z, u.ci.nArg, u.ci.apArg);
+ rc = u.cn.pModule->xFilter(u.cn.pVtabCursor, u.cn.iQuery, pOp->p4.z, u.cn.nArg, u.cn.apArg);
p->inVtabMethod = 0;
- importVtabErrMsg(p, u.ci.pVtab);
+ importVtabErrMsg(p, u.cn.pVtab);
if( rc==SQLITE_OK ){
- u.ci.res = u.ci.pModule->xEof(u.ci.pVtabCursor);
+ u.cn.res = u.cn.pModule->xEof(u.cn.pVtabCursor);
}
- if( u.ci.res ){
+ if( u.cn.res ){
pc = pOp->p2 - 1;
}
}
- u.ci.pCur->nullRow = 0;
+ u.cn.pCur->nullRow = 0;
break;
}
@@ -68554,51 +70076,51 @@ case OP_VFilter: { /* jump */
** P1 cursor is pointing to into register P3.
*/
case OP_VColumn: {
-#if 0 /* local variables moved into u.cj */
+#if 0 /* local variables moved into u.co */
sqlite3_vtab *pVtab;
const sqlite3_module *pModule;
Mem *pDest;
sqlite3_context sContext;
-#endif /* local variables moved into u.cj */
+#endif /* local variables moved into u.co */
VdbeCursor *pCur = p->apCsr[pOp->p1];
assert( pCur->pVtabCursor );
assert( pOp->p3>0 && pOp->p3<=p->nMem );
- u.cj.pDest = &aMem[pOp->p3];
- memAboutToChange(p, u.cj.pDest);
+ u.co.pDest = &aMem[pOp->p3];
+ memAboutToChange(p, u.co.pDest);
if( pCur->nullRow ){
- sqlite3VdbeMemSetNull(u.cj.pDest);
+ sqlite3VdbeMemSetNull(u.co.pDest);
break;
}
- u.cj.pVtab = pCur->pVtabCursor->pVtab;
- u.cj.pModule = u.cj.pVtab->pModule;
- assert( u.cj.pModule->xColumn );
- memset(&u.cj.sContext, 0, sizeof(u.cj.sContext));
+ u.co.pVtab = pCur->pVtabCursor->pVtab;
+ u.co.pModule = u.co.pVtab->pModule;
+ assert( u.co.pModule->xColumn );
+ memset(&u.co.sContext, 0, sizeof(u.co.sContext));
/* The output cell may already have a buffer allocated. Move
- ** the current contents to u.cj.sContext.s so in case the user-function
+ ** the current contents to u.co.sContext.s so in case the user-function
** can use the already allocated buffer instead of allocating a
** new one.
*/
- sqlite3VdbeMemMove(&u.cj.sContext.s, u.cj.pDest);
- MemSetTypeFlag(&u.cj.sContext.s, MEM_Null);
+ sqlite3VdbeMemMove(&u.co.sContext.s, u.co.pDest);
+ MemSetTypeFlag(&u.co.sContext.s, MEM_Null);
- rc = u.cj.pModule->xColumn(pCur->pVtabCursor, &u.cj.sContext, pOp->p2);
- importVtabErrMsg(p, u.cj.pVtab);
- if( u.cj.sContext.isError ){
- rc = u.cj.sContext.isError;
+ rc = u.co.pModule->xColumn(pCur->pVtabCursor, &u.co.sContext, pOp->p2);
+ importVtabErrMsg(p, u.co.pVtab);
+ if( u.co.sContext.isError ){
+ rc = u.co.sContext.isError;
}
/* Copy the result of the function to the P3 register. We
** do this regardless of whether or not an error occurred to ensure any
- ** dynamic allocation in u.cj.sContext.s (a Mem struct) is released.
+ ** dynamic allocation in u.co.sContext.s (a Mem struct) is released.
*/
- sqlite3VdbeChangeEncoding(&u.cj.sContext.s, encoding);
- sqlite3VdbeMemMove(u.cj.pDest, &u.cj.sContext.s);
- REGISTER_TRACE(pOp->p3, u.cj.pDest);
- UPDATE_MAX_BLOBSIZE(u.cj.pDest);
+ sqlite3VdbeChangeEncoding(&u.co.sContext.s, encoding);
+ sqlite3VdbeMemMove(u.co.pDest, &u.co.sContext.s);
+ REGISTER_TRACE(pOp->p3, u.co.pDest);
+ UPDATE_MAX_BLOBSIZE(u.co.pDest);
- if( sqlite3VdbeMemTooBig(u.cj.pDest) ){
+ if( sqlite3VdbeMemTooBig(u.co.pDest) ){
goto too_big;
}
break;
@@ -68613,22 +70135,22 @@ case OP_VColumn: {
** the end of its result set, then fall through to the next instruction.
*/
case OP_VNext: { /* jump */
-#if 0 /* local variables moved into u.ck */
+#if 0 /* local variables moved into u.cp */
sqlite3_vtab *pVtab;
const sqlite3_module *pModule;
int res;
VdbeCursor *pCur;
-#endif /* local variables moved into u.ck */
+#endif /* local variables moved into u.cp */
- u.ck.res = 0;
- u.ck.pCur = p->apCsr[pOp->p1];
- assert( u.ck.pCur->pVtabCursor );
- if( u.ck.pCur->nullRow ){
+ u.cp.res = 0;
+ u.cp.pCur = p->apCsr[pOp->p1];
+ assert( u.cp.pCur->pVtabCursor );
+ if( u.cp.pCur->nullRow ){
break;
}
- u.ck.pVtab = u.ck.pCur->pVtabCursor->pVtab;
- u.ck.pModule = u.ck.pVtab->pModule;
- assert( u.ck.pModule->xNext );
+ u.cp.pVtab = u.cp.pCur->pVtabCursor->pVtab;
+ u.cp.pModule = u.cp.pVtab->pModule;
+ assert( u.cp.pModule->xNext );
/* Invoke the xNext() method of the module. There is no way for the
** underlying implementation to return an error if one occurs during
@@ -68637,14 +70159,14 @@ case OP_VNext: { /* jump */
** some other method is next invoked on the save virtual table cursor.
*/
p->inVtabMethod = 1;
- rc = u.ck.pModule->xNext(u.ck.pCur->pVtabCursor);
+ rc = u.cp.pModule->xNext(u.cp.pCur->pVtabCursor);
p->inVtabMethod = 0;
- importVtabErrMsg(p, u.ck.pVtab);
+ importVtabErrMsg(p, u.cp.pVtab);
if( rc==SQLITE_OK ){
- u.ck.res = u.ck.pModule->xEof(u.ck.pCur->pVtabCursor);
+ u.cp.res = u.cp.pModule->xEof(u.cp.pCur->pVtabCursor);
}
- if( !u.ck.res ){
+ if( !u.cp.res ){
/* If there is data, jump to P2 */
pc = pOp->p2 - 1;
}
@@ -68660,21 +70182,26 @@ case OP_VNext: { /* jump */
** in register P1 is passed as the zName argument to the xRename method.
*/
case OP_VRename: {
-#if 0 /* local variables moved into u.cl */
+#if 0 /* local variables moved into u.cq */
sqlite3_vtab *pVtab;
Mem *pName;
-#endif /* local variables moved into u.cl */
-
- u.cl.pVtab = pOp->p4.pVtab->pVtab;
- u.cl.pName = &aMem[pOp->p1];
- assert( u.cl.pVtab->pModule->xRename );
- assert( memIsValid(u.cl.pName) );
- REGISTER_TRACE(pOp->p1, u.cl.pName);
- assert( u.cl.pName->flags & MEM_Str );
- rc = u.cl.pVtab->pModule->xRename(u.cl.pVtab, u.cl.pName->z);
- importVtabErrMsg(p, u.cl.pVtab);
- p->expired = 0;
-
+#endif /* local variables moved into u.cq */
+
+ u.cq.pVtab = pOp->p4.pVtab->pVtab;
+ u.cq.pName = &aMem[pOp->p1];
+ assert( u.cq.pVtab->pModule->xRename );
+ assert( memIsValid(u.cq.pName) );
+ REGISTER_TRACE(pOp->p1, u.cq.pName);
+ assert( u.cq.pName->flags & MEM_Str );
+ testcase( u.cq.pName->enc==SQLITE_UTF8 );
+ testcase( u.cq.pName->enc==SQLITE_UTF16BE );
+ testcase( u.cq.pName->enc==SQLITE_UTF16LE );
+ rc = sqlite3VdbeChangeEncoding(u.cq.pName, SQLITE_UTF8);
+ if( rc==SQLITE_OK ){
+ rc = u.cq.pVtab->pModule->xRename(u.cq.pVtab, u.cq.pName->z);
+ importVtabErrMsg(p, u.cq.pVtab);
+ p->expired = 0;
+ }
break;
}
#endif
@@ -68704,7 +70231,7 @@ case OP_VRename: {
** is set to the value of the rowid for the row just inserted.
*/
case OP_VUpdate: {
-#if 0 /* local variables moved into u.cm */
+#if 0 /* local variables moved into u.cr */
sqlite3_vtab *pVtab;
sqlite3_module *pModule;
int nArg;
@@ -68712,35 +70239,35 @@ case OP_VUpdate: {
sqlite_int64 rowid;
Mem **apArg;
Mem *pX;
-#endif /* local variables moved into u.cm */
+#endif /* local variables moved into u.cr */
assert( pOp->p2==1 || pOp->p5==OE_Fail || pOp->p5==OE_Rollback
|| pOp->p5==OE_Abort || pOp->p5==OE_Ignore || pOp->p5==OE_Replace
);
- u.cm.pVtab = pOp->p4.pVtab->pVtab;
- u.cm.pModule = (sqlite3_module *)u.cm.pVtab->pModule;
- u.cm.nArg = pOp->p2;
+ u.cr.pVtab = pOp->p4.pVtab->pVtab;
+ u.cr.pModule = (sqlite3_module *)u.cr.pVtab->pModule;
+ u.cr.nArg = pOp->p2;
assert( pOp->p4type==P4_VTAB );
- if( ALWAYS(u.cm.pModule->xUpdate) ){
+ if( ALWAYS(u.cr.pModule->xUpdate) ){
u8 vtabOnConflict = db->vtabOnConflict;
- u.cm.apArg = p->apArg;
- u.cm.pX = &aMem[pOp->p3];
- for(u.cm.i=0; u.cm.i<u.cm.nArg; u.cm.i++){
- assert( memIsValid(u.cm.pX) );
- memAboutToChange(p, u.cm.pX);
- sqlite3VdbeMemStoreType(u.cm.pX);
- u.cm.apArg[u.cm.i] = u.cm.pX;
- u.cm.pX++;
+ u.cr.apArg = p->apArg;
+ u.cr.pX = &aMem[pOp->p3];
+ for(u.cr.i=0; u.cr.i<u.cr.nArg; u.cr.i++){
+ assert( memIsValid(u.cr.pX) );
+ memAboutToChange(p, u.cr.pX);
+ sqlite3VdbeMemStoreType(u.cr.pX);
+ u.cr.apArg[u.cr.i] = u.cr.pX;
+ u.cr.pX++;
}
db->vtabOnConflict = pOp->p5;
- rc = u.cm.pModule->xUpdate(u.cm.pVtab, u.cm.nArg, u.cm.apArg, &u.cm.rowid);
+ rc = u.cr.pModule->xUpdate(u.cr.pVtab, u.cr.nArg, u.cr.apArg, &u.cr.rowid);
db->vtabOnConflict = vtabOnConflict;
- importVtabErrMsg(p, u.cm.pVtab);
+ importVtabErrMsg(p, u.cr.pVtab);
if( rc==SQLITE_OK && pOp->p1 ){
- assert( u.cm.nArg>1 && u.cm.apArg[0] && (u.cm.apArg[0]->flags&MEM_Null) );
- db->lastRowid = lastRowid = u.cm.rowid;
+ assert( u.cr.nArg>1 && u.cr.apArg[0] && (u.cr.apArg[0]->flags&MEM_Null) );
+ db->lastRowid = lastRowid = u.cr.rowid;
}
- if( rc==SQLITE_CONSTRAINT && pOp->p4.pVtab->bConstraint ){
+ if( (rc&0xff)==SQLITE_CONSTRAINT && pOp->p4.pVtab->bConstraint ){
if( pOp->p5==OE_Ignore ){
rc = SQLITE_OK;
}else{
@@ -68798,21 +70325,24 @@ case OP_MaxPgcnt: { /* out2-prerelease */
** the UTF-8 string contained in P4 is emitted on the trace callback.
*/
case OP_Trace: {
-#if 0 /* local variables moved into u.cn */
+#if 0 /* local variables moved into u.cs */
char *zTrace;
char *z;
-#endif /* local variables moved into u.cn */
+#endif /* local variables moved into u.cs */
- if( db->xTrace && (u.cn.zTrace = (pOp->p4.z ? pOp->p4.z : p->zSql))!=0 ){
- u.cn.z = sqlite3VdbeExpandSql(p, u.cn.zTrace);
- db->xTrace(db->pTraceArg, u.cn.z);
- sqlite3DbFree(db, u.cn.z);
+ if( db->xTrace
+ && !p->doingRerun
+ && (u.cs.zTrace = (pOp->p4.z ? pOp->p4.z : p->zSql))!=0
+ ){
+ u.cs.z = sqlite3VdbeExpandSql(p, u.cs.zTrace);
+ db->xTrace(db->pTraceArg, u.cs.z);
+ sqlite3DbFree(db, u.cs.z);
}
#ifdef SQLITE_DEBUG
if( (db->flags & SQLITE_SqlTrace)!=0
- && (u.cn.zTrace = (pOp->p4.z ? pOp->p4.z : p->zSql))!=0
+ && (u.cs.zTrace = (pOp->p4.z ? pOp->p4.z : p->zSql))!=0
){
- sqlite3DebugPrintf("SQL-trace: %s\n", u.cn.zTrace);
+ sqlite3DebugPrintf("SQL-trace: %s\n", u.cs.zTrace);
}
#endif /* SQLITE_DEBUG */
break;
@@ -68891,7 +70421,7 @@ vdbe_error_halt:
if( rc==SQLITE_IOERR_NOMEM ) db->mallocFailed = 1;
rc = SQLITE_ERROR;
if( resetSchemaOnFault>0 ){
- sqlite3ResetInternalSchema(db, resetSchemaOnFault-1);
+ sqlite3ResetOneSchema(db, resetSchemaOnFault-1);
}
/* This is the only way out of this procedure. We have to
@@ -69215,7 +70745,7 @@ SQLITE_API int sqlite3_blob_open(
/* Configure the OP_TableLock instruction */
#ifdef SQLITE_OMIT_SHARED_CACHE
- sqlite3VdbeChangeToNoop(v, 2, 1);
+ sqlite3VdbeChangeToNoop(v, 2);
#else
sqlite3VdbeChangeP1(v, 2, iDb);
sqlite3VdbeChangeP2(v, 2, pTab->tnum);
@@ -69225,7 +70755,7 @@ SQLITE_API int sqlite3_blob_open(
/* Remove either the OP_OpenWrite or OpenRead. Set the P2
** parameter of the other to pTab->tnum. */
- sqlite3VdbeChangeToNoop(v, 4 - flags, 1);
+ sqlite3VdbeChangeToNoop(v, 4 - flags);
sqlite3VdbeChangeP2(v, 3 + flags, pTab->tnum);
sqlite3VdbeChangeP3(v, 3 + flags, iDb);
@@ -69411,6 +70941,1045 @@ SQLITE_API int sqlite3_blob_reopen(sqlite3_blob *pBlob, sqlite3_int64 iRow){
#endif /* #ifndef SQLITE_OMIT_INCRBLOB */
/************** End of vdbeblob.c ********************************************/
+/************** Begin file vdbesort.c ****************************************/
+/*
+** 2011 July 9
+**
+** The author disclaims copyright to this source code. In place of
+** a legal notice, here is a blessing:
+**
+** May you do good and not evil.
+** May you find forgiveness for yourself and forgive others.
+** May you share freely, never taking more than you give.
+**
+*************************************************************************
+** This file contains code for the VdbeSorter object, used in concert with
+** a VdbeCursor to sort large numbers of keys (as may be required, for
+** example, by CREATE INDEX statements on tables too large to fit in main
+** memory).
+*/
+
+
+
+typedef struct VdbeSorterIter VdbeSorterIter;
+typedef struct SorterRecord SorterRecord;
+typedef struct FileWriter FileWriter;
+
+/*
+** NOTES ON DATA STRUCTURE USED FOR N-WAY MERGES:
+**
+** As keys are added to the sorter, they are written to disk in a series
+** of sorted packed-memory-arrays (PMAs). The size of each PMA is roughly
+** the same as the cache-size allowed for temporary databases. In order
+** to allow the caller to extract keys from the sorter in sorted order,
+** all PMAs currently stored on disk must be merged together. This comment
+** describes the data structure used to do so. The structure supports
+** merging any number of arrays in a single pass with no redundant comparison
+** operations.
+**
+** The aIter[] array contains an iterator for each of the PMAs being merged.
+** An aIter[] iterator either points to a valid key or else is at EOF. For
+** the purposes of the paragraphs below, we assume that the array is actually
+** N elements in size, where N is the smallest power of 2 greater to or equal
+** to the number of iterators being merged. The extra aIter[] elements are
+** treated as if they are empty (always at EOF).
+**
+** The aTree[] array is also N elements in size. The value of N is stored in
+** the VdbeSorter.nTree variable.
+**
+** The final (N/2) elements of aTree[] contain the results of comparing
+** pairs of iterator keys together. Element i contains the result of
+** comparing aIter[2*i-N] and aIter[2*i-N+1]. Whichever key is smaller, the
+** aTree element is set to the index of it.
+**
+** For the purposes of this comparison, EOF is considered greater than any
+** other key value. If the keys are equal (only possible with two EOF
+** values), it doesn't matter which index is stored.
+**
+** The (N/4) elements of aTree[] that preceed the final (N/2) described
+** above contains the index of the smallest of each block of 4 iterators.
+** And so on. So that aTree[1] contains the index of the iterator that
+** currently points to the smallest key value. aTree[0] is unused.
+**
+** Example:
+**
+** aIter[0] -> Banana
+** aIter[1] -> Feijoa
+** aIter[2] -> Elderberry
+** aIter[3] -> Currant
+** aIter[4] -> Grapefruit
+** aIter[5] -> Apple
+** aIter[6] -> Durian
+** aIter[7] -> EOF
+**
+** aTree[] = { X, 5 0, 5 0, 3, 5, 6 }
+**
+** The current element is "Apple" (the value of the key indicated by
+** iterator 5). When the Next() operation is invoked, iterator 5 will
+** be advanced to the next key in its segment. Say the next key is
+** "Eggplant":
+**
+** aIter[5] -> Eggplant
+**
+** The contents of aTree[] are updated first by comparing the new iterator
+** 5 key to the current key of iterator 4 (still "Grapefruit"). The iterator
+** 5 value is still smaller, so aTree[6] is set to 5. And so on up the tree.
+** The value of iterator 6 - "Durian" - is now smaller than that of iterator
+** 5, so aTree[3] is set to 6. Key 0 is smaller than key 6 (Banana<Durian),
+** so the value written into element 1 of the array is 0. As follows:
+**
+** aTree[] = { X, 0 0, 6 0, 3, 5, 6 }
+**
+** In other words, each time we advance to the next sorter element, log2(N)
+** key comparison operations are required, where N is the number of segments
+** being merged (rounded up to the next power of 2).
+*/
+struct VdbeSorter {
+ i64 iWriteOff; /* Current write offset within file pTemp1 */
+ i64 iReadOff; /* Current read offset within file pTemp1 */
+ int nInMemory; /* Current size of pRecord list as PMA */
+ int nTree; /* Used size of aTree/aIter (power of 2) */
+ int nPMA; /* Number of PMAs stored in pTemp1 */
+ int mnPmaSize; /* Minimum PMA size, in bytes */
+ int mxPmaSize; /* Maximum PMA size, in bytes. 0==no limit */
+ VdbeSorterIter *aIter; /* Array of iterators to merge */
+ int *aTree; /* Current state of incremental merge */
+ sqlite3_file *pTemp1; /* PMA file 1 */
+ SorterRecord *pRecord; /* Head of in-memory record list */
+ UnpackedRecord *pUnpacked; /* Used to unpack keys */
+};
+
+/*
+** The following type is an iterator for a PMA. It caches the current key in
+** variables nKey/aKey. If the iterator is at EOF, pFile==0.
+*/
+struct VdbeSorterIter {
+ i64 iReadOff; /* Current read offset */
+ i64 iEof; /* 1 byte past EOF for this iterator */
+ int nAlloc; /* Bytes of space at aAlloc */
+ int nKey; /* Number of bytes in key */
+ sqlite3_file *pFile; /* File iterator is reading from */
+ u8 *aAlloc; /* Allocated space */
+ u8 *aKey; /* Pointer to current key */
+ u8 *aBuffer; /* Current read buffer */
+ int nBuffer; /* Size of read buffer in bytes */
+};
+
+/*
+** An instance of this structure is used to organize the stream of records
+** being written to files by the merge-sort code into aligned, page-sized
+** blocks. Doing all I/O in aligned page-sized blocks helps I/O to go
+** faster on many operating systems.
+*/
+struct FileWriter {
+ int eFWErr; /* Non-zero if in an error state */
+ u8 *aBuffer; /* Pointer to write buffer */
+ int nBuffer; /* Size of write buffer in bytes */
+ int iBufStart; /* First byte of buffer to write */
+ int iBufEnd; /* Last byte of buffer to write */
+ i64 iWriteOff; /* Offset of start of buffer in file */
+ sqlite3_file *pFile; /* File to write to */
+};
+
+/*
+** A structure to store a single record. All in-memory records are connected
+** together into a linked list headed at VdbeSorter.pRecord using the
+** SorterRecord.pNext pointer.
+*/
+struct SorterRecord {
+ void *pVal;
+ int nVal;
+ SorterRecord *pNext;
+};
+
+/* Minimum allowable value for the VdbeSorter.nWorking variable */
+#define SORTER_MIN_WORKING 10
+
+/* Maximum number of segments to merge in a single pass. */
+#define SORTER_MAX_MERGE_COUNT 16
+
+/*
+** Free all memory belonging to the VdbeSorterIter object passed as the second
+** argument. All structure fields are set to zero before returning.
+*/
+static void vdbeSorterIterZero(sqlite3 *db, VdbeSorterIter *pIter){
+ sqlite3DbFree(db, pIter->aAlloc);
+ sqlite3DbFree(db, pIter->aBuffer);
+ memset(pIter, 0, sizeof(VdbeSorterIter));
+}
+
+/*
+** Read nByte bytes of data from the stream of data iterated by object p.
+** If successful, set *ppOut to point to a buffer containing the data
+** and return SQLITE_OK. Otherwise, if an error occurs, return an SQLite
+** error code.
+**
+** The buffer indicated by *ppOut may only be considered valid until the
+** next call to this function.
+*/
+static int vdbeSorterIterRead(
+ sqlite3 *db, /* Database handle (for malloc) */
+ VdbeSorterIter *p, /* Iterator */
+ int nByte, /* Bytes of data to read */
+ u8 **ppOut /* OUT: Pointer to buffer containing data */
+){
+ int iBuf; /* Offset within buffer to read from */
+ int nAvail; /* Bytes of data available in buffer */
+ assert( p->aBuffer );
+
+ /* If there is no more data to be read from the buffer, read the next
+ ** p->nBuffer bytes of data from the file into it. Or, if there are less
+ ** than p->nBuffer bytes remaining in the PMA, read all remaining data. */
+ iBuf = p->iReadOff % p->nBuffer;
+ if( iBuf==0 ){
+ int nRead; /* Bytes to read from disk */
+ int rc; /* sqlite3OsRead() return code */
+
+ /* Determine how many bytes of data to read. */
+ if( (p->iEof - p->iReadOff) > (i64)p->nBuffer ){
+ nRead = p->nBuffer;
+ }else{
+ nRead = (int)(p->iEof - p->iReadOff);
+ }
+ assert( nRead>0 );
+
+ /* Read data from the file. Return early if an error occurs. */
+ rc = sqlite3OsRead(p->pFile, p->aBuffer, nRead, p->iReadOff);
+ assert( rc!=SQLITE_IOERR_SHORT_READ );
+ if( rc!=SQLITE_OK ) return rc;
+ }
+ nAvail = p->nBuffer - iBuf;
+
+ if( nByte<=nAvail ){
+ /* The requested data is available in the in-memory buffer. In this
+ ** case there is no need to make a copy of the data, just return a
+ ** pointer into the buffer to the caller. */
+ *ppOut = &p->aBuffer[iBuf];
+ p->iReadOff += nByte;
+ }else{
+ /* The requested data is not all available in the in-memory buffer.
+ ** In this case, allocate space at p->aAlloc[] to copy the requested
+ ** range into. Then return a copy of pointer p->aAlloc to the caller. */
+ int nRem; /* Bytes remaining to copy */
+
+ /* Extend the p->aAlloc[] allocation if required. */
+ if( p->nAlloc<nByte ){
+ int nNew = p->nAlloc*2;
+ while( nByte>nNew ) nNew = nNew*2;
+ p->aAlloc = sqlite3DbReallocOrFree(db, p->aAlloc, nNew);
+ if( !p->aAlloc ) return SQLITE_NOMEM;
+ p->nAlloc = nNew;
+ }
+
+ /* Copy as much data as is available in the buffer into the start of
+ ** p->aAlloc[]. */
+ memcpy(p->aAlloc, &p->aBuffer[iBuf], nAvail);
+ p->iReadOff += nAvail;
+ nRem = nByte - nAvail;
+
+ /* The following loop copies up to p->nBuffer bytes per iteration into
+ ** the p->aAlloc[] buffer. */
+ while( nRem>0 ){
+ int rc; /* vdbeSorterIterRead() return code */
+ int nCopy; /* Number of bytes to copy */
+ u8 *aNext; /* Pointer to buffer to copy data from */
+
+ nCopy = nRem;
+ if( nRem>p->nBuffer ) nCopy = p->nBuffer;
+ rc = vdbeSorterIterRead(db, p, nCopy, &aNext);
+ if( rc!=SQLITE_OK ) return rc;
+ assert( aNext!=p->aAlloc );
+ memcpy(&p->aAlloc[nByte - nRem], aNext, nCopy);
+ nRem -= nCopy;
+ }
+
+ *ppOut = p->aAlloc;
+ }
+
+ return SQLITE_OK;
+}
+
+/*
+** Read a varint from the stream of data accessed by p. Set *pnOut to
+** the value read.
+*/
+static int vdbeSorterIterVarint(sqlite3 *db, VdbeSorterIter *p, u64 *pnOut){
+ int iBuf;
+
+ iBuf = p->iReadOff % p->nBuffer;
+ if( iBuf && (p->nBuffer-iBuf)>=9 ){
+ p->iReadOff += sqlite3GetVarint(&p->aBuffer[iBuf], pnOut);
+ }else{
+ u8 aVarint[16], *a;
+ int i = 0, rc;
+ do{
+ rc = vdbeSorterIterRead(db, p, 1, &a);
+ if( rc ) return rc;
+ aVarint[(i++)&0xf] = a[0];
+ }while( (a[0]&0x80)!=0 );
+ sqlite3GetVarint(aVarint, pnOut);
+ }
+
+ return SQLITE_OK;
+}
+
+
+/*
+** Advance iterator pIter to the next key in its PMA. Return SQLITE_OK if
+** no error occurs, or an SQLite error code if one does.
+*/
+static int vdbeSorterIterNext(
+ sqlite3 *db, /* Database handle (for sqlite3DbMalloc() ) */
+ VdbeSorterIter *pIter /* Iterator to advance */
+){
+ int rc; /* Return Code */
+ u64 nRec = 0; /* Size of record in bytes */
+
+ if( pIter->iReadOff>=pIter->iEof ){
+ /* This is an EOF condition */
+ vdbeSorterIterZero(db, pIter);
+ return SQLITE_OK;
+ }
+
+ rc = vdbeSorterIterVarint(db, pIter, &nRec);
+ if( rc==SQLITE_OK ){
+ pIter->nKey = (int)nRec;
+ rc = vdbeSorterIterRead(db, pIter, (int)nRec, &pIter->aKey);
+ }
+
+ return rc;
+}
+
+/*
+** Initialize iterator pIter to scan through the PMA stored in file pFile
+** starting at offset iStart and ending at offset iEof-1. This function
+** leaves the iterator pointing to the first key in the PMA (or EOF if the
+** PMA is empty).
+*/
+static int vdbeSorterIterInit(
+ sqlite3 *db, /* Database handle */
+ const VdbeSorter *pSorter, /* Sorter object */
+ i64 iStart, /* Start offset in pFile */
+ VdbeSorterIter *pIter, /* Iterator to populate */
+ i64 *pnByte /* IN/OUT: Increment this value by PMA size */
+){
+ int rc = SQLITE_OK;
+ int nBuf;
+
+ nBuf = sqlite3BtreeGetPageSize(db->aDb[0].pBt);
+
+ assert( pSorter->iWriteOff>iStart );
+ assert( pIter->aAlloc==0 );
+ assert( pIter->aBuffer==0 );
+ pIter->pFile = pSorter->pTemp1;
+ pIter->iReadOff = iStart;
+ pIter->nAlloc = 128;
+ pIter->aAlloc = (u8 *)sqlite3DbMallocRaw(db, pIter->nAlloc);
+ pIter->nBuffer = nBuf;
+ pIter->aBuffer = (u8 *)sqlite3DbMallocRaw(db, nBuf);
+
+ if( !pIter->aBuffer ){
+ rc = SQLITE_NOMEM;
+ }else{
+ int iBuf;
+
+ iBuf = iStart % nBuf;
+ if( iBuf ){
+ int nRead = nBuf - iBuf;
+ if( (iStart + nRead) > pSorter->iWriteOff ){
+ nRead = (int)(pSorter->iWriteOff - iStart);
+ }
+ rc = sqlite3OsRead(
+ pSorter->pTemp1, &pIter->aBuffer[iBuf], nRead, iStart
+ );
+ assert( rc!=SQLITE_IOERR_SHORT_READ );
+ }
+
+ if( rc==SQLITE_OK ){
+ u64 nByte; /* Size of PMA in bytes */
+ pIter->iEof = pSorter->iWriteOff;
+ rc = vdbeSorterIterVarint(db, pIter, &nByte);
+ pIter->iEof = pIter->iReadOff + nByte;
+ *pnByte += nByte;
+ }
+ }
+
+ if( rc==SQLITE_OK ){
+ rc = vdbeSorterIterNext(db, pIter);
+ }
+ return rc;
+}
+
+
+/*
+** Compare key1 (buffer pKey1, size nKey1 bytes) with key2 (buffer pKey2,
+** size nKey2 bytes). Argument pKeyInfo supplies the collation functions
+** used by the comparison. If an error occurs, return an SQLite error code.
+** Otherwise, return SQLITE_OK and set *pRes to a negative, zero or positive
+** value, depending on whether key1 is smaller, equal to or larger than key2.
+**
+** If the bOmitRowid argument is non-zero, assume both keys end in a rowid
+** field. For the purposes of the comparison, ignore it. Also, if bOmitRowid
+** is true and key1 contains even a single NULL value, it is considered to
+** be less than key2. Even if key2 also contains NULL values.
+**
+** If pKey2 is passed a NULL pointer, then it is assumed that the pCsr->aSpace
+** has been allocated and contains an unpacked record that is used as key2.
+*/
+static void vdbeSorterCompare(
+ const VdbeCursor *pCsr, /* Cursor object (for pKeyInfo) */
+ int bOmitRowid, /* Ignore rowid field at end of keys */
+ const void *pKey1, int nKey1, /* Left side of comparison */
+ const void *pKey2, int nKey2, /* Right side of comparison */
+ int *pRes /* OUT: Result of comparison */
+){
+ KeyInfo *pKeyInfo = pCsr->pKeyInfo;
+ VdbeSorter *pSorter = pCsr->pSorter;
+ UnpackedRecord *r2 = pSorter->pUnpacked;
+ int i;
+
+ if( pKey2 ){
+ sqlite3VdbeRecordUnpack(pKeyInfo, nKey2, pKey2, r2);
+ }
+
+ if( bOmitRowid ){
+ r2->nField = pKeyInfo->nField;
+ assert( r2->nField>0 );
+ for(i=0; i<r2->nField; i++){
+ if( r2->aMem[i].flags & MEM_Null ){
+ *pRes = -1;
+ return;
+ }
+ }
+ r2->flags |= UNPACKED_PREFIX_MATCH;
+ }
+
+ *pRes = sqlite3VdbeRecordCompare(nKey1, pKey1, r2);
+}
+
+/*
+** This function is called to compare two iterator keys when merging
+** multiple b-tree segments. Parameter iOut is the index of the aTree[]
+** value to recalculate.
+*/
+static int vdbeSorterDoCompare(const VdbeCursor *pCsr, int iOut){
+ VdbeSorter *pSorter = pCsr->pSorter;
+ int i1;
+ int i2;
+ int iRes;
+ VdbeSorterIter *p1;
+ VdbeSorterIter *p2;
+
+ assert( iOut<pSorter->nTree && iOut>0 );
+
+ if( iOut>=(pSorter->nTree/2) ){
+ i1 = (iOut - pSorter->nTree/2) * 2;
+ i2 = i1 + 1;
+ }else{
+ i1 = pSorter->aTree[iOut*2];
+ i2 = pSorter->aTree[iOut*2+1];
+ }
+
+ p1 = &pSorter->aIter[i1];
+ p2 = &pSorter->aIter[i2];
+
+ if( p1->pFile==0 ){
+ iRes = i2;
+ }else if( p2->pFile==0 ){
+ iRes = i1;
+ }else{
+ int res;
+ assert( pCsr->pSorter->pUnpacked!=0 ); /* allocated in vdbeSorterMerge() */
+ vdbeSorterCompare(
+ pCsr, 0, p1->aKey, p1->nKey, p2->aKey, p2->nKey, &res
+ );
+ if( res<=0 ){
+ iRes = i1;
+ }else{
+ iRes = i2;
+ }
+ }
+
+ pSorter->aTree[iOut] = iRes;
+ return SQLITE_OK;
+}
+
+/*
+** Initialize the temporary index cursor just opened as a sorter cursor.
+*/
+SQLITE_PRIVATE int sqlite3VdbeSorterInit(sqlite3 *db, VdbeCursor *pCsr){
+ int pgsz; /* Page size of main database */
+ int mxCache; /* Cache size */
+ VdbeSorter *pSorter; /* The new sorter */
+ char *d; /* Dummy */
+
+ assert( pCsr->pKeyInfo && pCsr->pBt==0 );
+ pCsr->pSorter = pSorter = sqlite3DbMallocZero(db, sizeof(VdbeSorter));
+ if( pSorter==0 ){
+ return SQLITE_NOMEM;
+ }
+
+ pSorter->pUnpacked = sqlite3VdbeAllocUnpackedRecord(pCsr->pKeyInfo, 0, 0, &d);
+ if( pSorter->pUnpacked==0 ) return SQLITE_NOMEM;
+ assert( pSorter->pUnpacked==(UnpackedRecord *)d );
+
+ if( !sqlite3TempInMemory(db) ){
+ pgsz = sqlite3BtreeGetPageSize(db->aDb[0].pBt);
+ pSorter->mnPmaSize = SORTER_MIN_WORKING * pgsz;
+ mxCache = db->aDb[0].pSchema->cache_size;
+ if( mxCache<SORTER_MIN_WORKING ) mxCache = SORTER_MIN_WORKING;
+ pSorter->mxPmaSize = mxCache * pgsz;
+ }
+
+ return SQLITE_OK;
+}
+
+/*
+** Free the list of sorted records starting at pRecord.
+*/
+static void vdbeSorterRecordFree(sqlite3 *db, SorterRecord *pRecord){
+ SorterRecord *p;
+ SorterRecord *pNext;
+ for(p=pRecord; p; p=pNext){
+ pNext = p->pNext;
+ sqlite3DbFree(db, p);
+ }
+}
+
+/*
+** Free any cursor components allocated by sqlite3VdbeSorterXXX routines.
+*/
+SQLITE_PRIVATE void sqlite3VdbeSorterClose(sqlite3 *db, VdbeCursor *pCsr){
+ VdbeSorter *pSorter = pCsr->pSorter;
+ if( pSorter ){
+ if( pSorter->aIter ){
+ int i;
+ for(i=0; i<pSorter->nTree; i++){
+ vdbeSorterIterZero(db, &pSorter->aIter[i]);
+ }
+ sqlite3DbFree(db, pSorter->aIter);
+ }
+ if( pSorter->pTemp1 ){
+ sqlite3OsCloseFree(pSorter->pTemp1);
+ }
+ vdbeSorterRecordFree(db, pSorter->pRecord);
+ sqlite3DbFree(db, pSorter->pUnpacked);
+ sqlite3DbFree(db, pSorter);
+ pCsr->pSorter = 0;
+ }
+}
+
+/*
+** Allocate space for a file-handle and open a temporary file. If successful,
+** set *ppFile to point to the malloc'd file-handle and return SQLITE_OK.
+** Otherwise, set *ppFile to 0 and return an SQLite error code.
+*/
+static int vdbeSorterOpenTempFile(sqlite3 *db, sqlite3_file **ppFile){
+ int dummy;
+ return sqlite3OsOpenMalloc(db->pVfs, 0, ppFile,
+ SQLITE_OPEN_TEMP_JOURNAL |
+ SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE |
+ SQLITE_OPEN_EXCLUSIVE | SQLITE_OPEN_DELETEONCLOSE, &dummy
+ );
+}
+
+/*
+** Merge the two sorted lists p1 and p2 into a single list.
+** Set *ppOut to the head of the new list.
+*/
+static void vdbeSorterMerge(
+ const VdbeCursor *pCsr, /* For pKeyInfo */
+ SorterRecord *p1, /* First list to merge */
+ SorterRecord *p2, /* Second list to merge */
+ SorterRecord **ppOut /* OUT: Head of merged list */
+){
+ SorterRecord *pFinal = 0;
+ SorterRecord **pp = &pFinal;
+ void *pVal2 = p2 ? p2->pVal : 0;
+
+ while( p1 && p2 ){
+ int res;
+ vdbeSorterCompare(pCsr, 0, p1->pVal, p1->nVal, pVal2, p2->nVal, &res);
+ if( res<=0 ){
+ *pp = p1;
+ pp = &p1->pNext;
+ p1 = p1->pNext;
+ pVal2 = 0;
+ }else{
+ *pp = p2;
+ pp = &p2->pNext;
+ p2 = p2->pNext;
+ if( p2==0 ) break;
+ pVal2 = p2->pVal;
+ }
+ }
+ *pp = p1 ? p1 : p2;
+ *ppOut = pFinal;
+}
+
+/*
+** Sort the linked list of records headed at pCsr->pRecord. Return SQLITE_OK
+** if successful, or an SQLite error code (i.e. SQLITE_NOMEM) if an error
+** occurs.
+*/
+static int vdbeSorterSort(const VdbeCursor *pCsr){
+ int i;
+ SorterRecord **aSlot;
+ SorterRecord *p;
+ VdbeSorter *pSorter = pCsr->pSorter;
+
+ aSlot = (SorterRecord **)sqlite3MallocZero(64 * sizeof(SorterRecord *));
+ if( !aSlot ){
+ return SQLITE_NOMEM;
+ }
+
+ p = pSorter->pRecord;
+ while( p ){
+ SorterRecord *pNext = p->pNext;
+ p->pNext = 0;
+ for(i=0; aSlot[i]; i++){
+ vdbeSorterMerge(pCsr, p, aSlot[i], &p);
+ aSlot[i] = 0;
+ }
+ aSlot[i] = p;
+ p = pNext;
+ }
+
+ p = 0;
+ for(i=0; i<64; i++){
+ vdbeSorterMerge(pCsr, p, aSlot[i], &p);
+ }
+ pSorter->pRecord = p;
+
+ sqlite3_free(aSlot);
+ return SQLITE_OK;
+}
+
+/*
+** Initialize a file-writer object.
+*/
+static void fileWriterInit(
+ sqlite3 *db, /* Database (for malloc) */
+ sqlite3_file *pFile, /* File to write to */
+ FileWriter *p, /* Object to populate */
+ i64 iStart /* Offset of pFile to begin writing at */
+){
+ int nBuf = sqlite3BtreeGetPageSize(db->aDb[0].pBt);
+
+ memset(p, 0, sizeof(FileWriter));
+ p->aBuffer = (u8 *)sqlite3DbMallocRaw(db, nBuf);
+ if( !p->aBuffer ){
+ p->eFWErr = SQLITE_NOMEM;
+ }else{
+ p->iBufEnd = p->iBufStart = (iStart % nBuf);
+ p->iWriteOff = iStart - p->iBufStart;
+ p->nBuffer = nBuf;
+ p->pFile = pFile;
+ }
+}
+
+/*
+** Write nData bytes of data to the file-write object. Return SQLITE_OK
+** if successful, or an SQLite error code if an error occurs.
+*/
+static void fileWriterWrite(FileWriter *p, u8 *pData, int nData){
+ int nRem = nData;
+ while( nRem>0 && p->eFWErr==0 ){
+ int nCopy = nRem;
+ if( nCopy>(p->nBuffer - p->iBufEnd) ){
+ nCopy = p->nBuffer - p->iBufEnd;
+ }
+
+ memcpy(&p->aBuffer[p->iBufEnd], &pData[nData-nRem], nCopy);
+ p->iBufEnd += nCopy;
+ if( p->iBufEnd==p->nBuffer ){
+ p->eFWErr = sqlite3OsWrite(p->pFile,
+ &p->aBuffer[p->iBufStart], p->iBufEnd - p->iBufStart,
+ p->iWriteOff + p->iBufStart
+ );
+ p->iBufStart = p->iBufEnd = 0;
+ p->iWriteOff += p->nBuffer;
+ }
+ assert( p->iBufEnd<p->nBuffer );
+
+ nRem -= nCopy;
+ }
+}
+
+/*
+** Flush any buffered data to disk and clean up the file-writer object.
+** The results of using the file-writer after this call are undefined.
+** Return SQLITE_OK if flushing the buffered data succeeds or is not
+** required. Otherwise, return an SQLite error code.
+**
+** Before returning, set *piEof to the offset immediately following the
+** last byte written to the file.
+*/
+static int fileWriterFinish(sqlite3 *db, FileWriter *p, i64 *piEof){
+ int rc;
+ if( p->eFWErr==0 && ALWAYS(p->aBuffer) && p->iBufEnd>p->iBufStart ){
+ p->eFWErr = sqlite3OsWrite(p->pFile,
+ &p->aBuffer[p->iBufStart], p->iBufEnd - p->iBufStart,
+ p->iWriteOff + p->iBufStart
+ );
+ }
+ *piEof = (p->iWriteOff + p->iBufEnd);
+ sqlite3DbFree(db, p->aBuffer);
+ rc = p->eFWErr;
+ memset(p, 0, sizeof(FileWriter));
+ return rc;
+}
+
+/*
+** Write value iVal encoded as a varint to the file-write object. Return
+** SQLITE_OK if successful, or an SQLite error code if an error occurs.
+*/
+static void fileWriterWriteVarint(FileWriter *p, u64 iVal){
+ int nByte;
+ u8 aByte[10];
+ nByte = sqlite3PutVarint(aByte, iVal);
+ fileWriterWrite(p, aByte, nByte);
+}
+
+/*
+** Write the current contents of the in-memory linked-list to a PMA. Return
+** SQLITE_OK if successful, or an SQLite error code otherwise.
+**
+** The format of a PMA is:
+**
+** * A varint. This varint contains the total number of bytes of content
+** in the PMA (not including the varint itself).
+**
+** * One or more records packed end-to-end in order of ascending keys.
+** Each record consists of a varint followed by a blob of data (the
+** key). The varint is the number of bytes in the blob of data.
+*/
+static int vdbeSorterListToPMA(sqlite3 *db, const VdbeCursor *pCsr){
+ int rc = SQLITE_OK; /* Return code */
+ VdbeSorter *pSorter = pCsr->pSorter;
+ FileWriter writer;
+
+ memset(&writer, 0, sizeof(FileWriter));
+
+ if( pSorter->nInMemory==0 ){
+ assert( pSorter->pRecord==0 );
+ return rc;
+ }
+
+ rc = vdbeSorterSort(pCsr);
+
+ /* If the first temporary PMA file has not been opened, open it now. */
+ if( rc==SQLITE_OK && pSorter->pTemp1==0 ){
+ rc = vdbeSorterOpenTempFile(db, &pSorter->pTemp1);
+ assert( rc!=SQLITE_OK || pSorter->pTemp1 );
+ assert( pSorter->iWriteOff==0 );
+ assert( pSorter->nPMA==0 );
+ }
+
+ if( rc==SQLITE_OK ){
+ SorterRecord *p;
+ SorterRecord *pNext = 0;
+
+ fileWriterInit(db, pSorter->pTemp1, &writer, pSorter->iWriteOff);
+ pSorter->nPMA++;
+ fileWriterWriteVarint(&writer, pSorter->nInMemory);
+ for(p=pSorter->pRecord; p; p=pNext){
+ pNext = p->pNext;
+ fileWriterWriteVarint(&writer, p->nVal);
+ fileWriterWrite(&writer, p->pVal, p->nVal);
+ sqlite3DbFree(db, p);
+ }
+ pSorter->pRecord = p;
+ rc = fileWriterFinish(db, &writer, &pSorter->iWriteOff);
+ }
+
+ return rc;
+}
+
+/*
+** Add a record to the sorter.
+*/
+SQLITE_PRIVATE int sqlite3VdbeSorterWrite(
+ sqlite3 *db, /* Database handle */
+ const VdbeCursor *pCsr, /* Sorter cursor */
+ Mem *pVal /* Memory cell containing record */
+){
+ VdbeSorter *pSorter = pCsr->pSorter;
+ int rc = SQLITE_OK; /* Return Code */
+ SorterRecord *pNew; /* New list element */
+
+ assert( pSorter );
+ pSorter->nInMemory += sqlite3VarintLen(pVal->n) + pVal->n;
+
+ pNew = (SorterRecord *)sqlite3DbMallocRaw(db, pVal->n + sizeof(SorterRecord));
+ if( pNew==0 ){
+ rc = SQLITE_NOMEM;
+ }else{
+ pNew->pVal = (void *)&pNew[1];
+ memcpy(pNew->pVal, pVal->z, pVal->n);
+ pNew->nVal = pVal->n;
+ pNew->pNext = pSorter->pRecord;
+ pSorter->pRecord = pNew;
+ }
+
+ /* See if the contents of the sorter should now be written out. They
+ ** are written out when either of the following are true:
+ **
+ ** * The total memory allocated for the in-memory list is greater
+ ** than (page-size * cache-size), or
+ **
+ ** * The total memory allocated for the in-memory list is greater
+ ** than (page-size * 10) and sqlite3HeapNearlyFull() returns true.
+ */
+ if( rc==SQLITE_OK && pSorter->mxPmaSize>0 && (
+ (pSorter->nInMemory>pSorter->mxPmaSize)
+ || (pSorter->nInMemory>pSorter->mnPmaSize && sqlite3HeapNearlyFull())
+ )){
+#ifdef SQLITE_DEBUG
+ i64 nExpect = pSorter->iWriteOff
+ + sqlite3VarintLen(pSorter->nInMemory)
+ + pSorter->nInMemory;
+#endif
+ rc = vdbeSorterListToPMA(db, pCsr);
+ pSorter->nInMemory = 0;
+ assert( rc!=SQLITE_OK || (nExpect==pSorter->iWriteOff) );
+ }
+
+ return rc;
+}
+
+/*
+** Helper function for sqlite3VdbeSorterRewind().
+*/
+static int vdbeSorterInitMerge(
+ sqlite3 *db, /* Database handle */
+ const VdbeCursor *pCsr, /* Cursor handle for this sorter */
+ i64 *pnByte /* Sum of bytes in all opened PMAs */
+){
+ VdbeSorter *pSorter = pCsr->pSorter;
+ int rc = SQLITE_OK; /* Return code */
+ int i; /* Used to iterator through aIter[] */
+ i64 nByte = 0; /* Total bytes in all opened PMAs */
+
+ /* Initialize the iterators. */
+ for(i=0; i<SORTER_MAX_MERGE_COUNT; i++){
+ VdbeSorterIter *pIter = &pSorter->aIter[i];
+ rc = vdbeSorterIterInit(db, pSorter, pSorter->iReadOff, pIter, &nByte);
+ pSorter->iReadOff = pIter->iEof;
+ assert( rc!=SQLITE_OK || pSorter->iReadOff<=pSorter->iWriteOff );
+ if( rc!=SQLITE_OK || pSorter->iReadOff>=pSorter->iWriteOff ) break;
+ }
+
+ /* Initialize the aTree[] array. */
+ for(i=pSorter->nTree-1; rc==SQLITE_OK && i>0; i--){
+ rc = vdbeSorterDoCompare(pCsr, i);
+ }
+
+ *pnByte = nByte;
+ return rc;
+}
+
+/*
+** Once the sorter has been populated, this function is called to prepare
+** for iterating through its contents in sorted order.
+*/
+SQLITE_PRIVATE int sqlite3VdbeSorterRewind(sqlite3 *db, const VdbeCursor *pCsr, int *pbEof){
+ VdbeSorter *pSorter = pCsr->pSorter;
+ int rc; /* Return code */
+ sqlite3_file *pTemp2 = 0; /* Second temp file to use */
+ i64 iWrite2 = 0; /* Write offset for pTemp2 */
+ int nIter; /* Number of iterators used */
+ int nByte; /* Bytes of space required for aIter/aTree */
+ int N = 2; /* Power of 2 >= nIter */
+
+ assert( pSorter );
+
+ /* If no data has been written to disk, then do not do so now. Instead,
+ ** sort the VdbeSorter.pRecord list. The vdbe layer will read data directly
+ ** from the in-memory list. */
+ if( pSorter->nPMA==0 ){
+ *pbEof = !pSorter->pRecord;
+ assert( pSorter->aTree==0 );
+ return vdbeSorterSort(pCsr);
+ }
+
+ /* Write the current in-memory list to a PMA. */
+ rc = vdbeSorterListToPMA(db, pCsr);
+ if( rc!=SQLITE_OK ) return rc;
+
+ /* Allocate space for aIter[] and aTree[]. */
+ nIter = pSorter->nPMA;
+ if( nIter>SORTER_MAX_MERGE_COUNT ) nIter = SORTER_MAX_MERGE_COUNT;
+ assert( nIter>0 );
+ while( N<nIter ) N += N;
+ nByte = N * (sizeof(int) + sizeof(VdbeSorterIter));
+ pSorter->aIter = (VdbeSorterIter *)sqlite3DbMallocZero(db, nByte);
+ if( !pSorter->aIter ) return SQLITE_NOMEM;
+ pSorter->aTree = (int *)&pSorter->aIter[N];
+ pSorter->nTree = N;
+
+ do {
+ int iNew; /* Index of new, merged, PMA */
+
+ for(iNew=0;
+ rc==SQLITE_OK && iNew*SORTER_MAX_MERGE_COUNT<pSorter->nPMA;
+ iNew++
+ ){
+ int rc2; /* Return code from fileWriterFinish() */
+ FileWriter writer; /* Object used to write to disk */
+ i64 nWrite; /* Number of bytes in new PMA */
+
+ memset(&writer, 0, sizeof(FileWriter));
+
+ /* If there are SORTER_MAX_MERGE_COUNT or less PMAs in file pTemp1,
+ ** initialize an iterator for each of them and break out of the loop.
+ ** These iterators will be incrementally merged as the VDBE layer calls
+ ** sqlite3VdbeSorterNext().
+ **
+ ** Otherwise, if pTemp1 contains more than SORTER_MAX_MERGE_COUNT PMAs,
+ ** initialize interators for SORTER_MAX_MERGE_COUNT of them. These PMAs
+ ** are merged into a single PMA that is written to file pTemp2.
+ */
+ rc = vdbeSorterInitMerge(db, pCsr, &nWrite);
+ assert( rc!=SQLITE_OK || pSorter->aIter[ pSorter->aTree[1] ].pFile );
+ if( rc!=SQLITE_OK || pSorter->nPMA<=SORTER_MAX_MERGE_COUNT ){
+ break;
+ }
+
+ /* Open the second temp file, if it is not already open. */
+ if( pTemp2==0 ){
+ assert( iWrite2==0 );
+ rc = vdbeSorterOpenTempFile(db, &pTemp2);
+ }
+
+ if( rc==SQLITE_OK ){
+ int bEof = 0;
+ fileWriterInit(db, pTemp2, &writer, iWrite2);
+ fileWriterWriteVarint(&writer, nWrite);
+ while( rc==SQLITE_OK && bEof==0 ){
+ VdbeSorterIter *pIter = &pSorter->aIter[ pSorter->aTree[1] ];
+ assert( pIter->pFile );
+
+ fileWriterWriteVarint(&writer, pIter->nKey);
+ fileWriterWrite(&writer, pIter->aKey, pIter->nKey);
+ rc = sqlite3VdbeSorterNext(db, pCsr, &bEof);
+ }
+ rc2 = fileWriterFinish(db, &writer, &iWrite2);
+ if( rc==SQLITE_OK ) rc = rc2;
+ }
+ }
+
+ if( pSorter->nPMA<=SORTER_MAX_MERGE_COUNT ){
+ break;
+ }else{
+ sqlite3_file *pTmp = pSorter->pTemp1;
+ pSorter->nPMA = iNew;
+ pSorter->pTemp1 = pTemp2;
+ pTemp2 = pTmp;
+ pSorter->iWriteOff = iWrite2;
+ pSorter->iReadOff = 0;
+ iWrite2 = 0;
+ }
+ }while( rc==SQLITE_OK );
+
+ if( pTemp2 ){
+ sqlite3OsCloseFree(pTemp2);
+ }
+ *pbEof = (pSorter->aIter[pSorter->aTree[1]].pFile==0);
+ return rc;
+}
+
+/*
+** Advance to the next element in the sorter.
+*/
+SQLITE_PRIVATE int sqlite3VdbeSorterNext(sqlite3 *db, const VdbeCursor *pCsr, int *pbEof){
+ VdbeSorter *pSorter = pCsr->pSorter;
+ int rc; /* Return code */
+
+ if( pSorter->aTree ){
+ int iPrev = pSorter->aTree[1];/* Index of iterator to advance */
+ int i; /* Index of aTree[] to recalculate */
+
+ rc = vdbeSorterIterNext(db, &pSorter->aIter[iPrev]);
+ for(i=(pSorter->nTree+iPrev)/2; rc==SQLITE_OK && i>0; i=i/2){
+ rc = vdbeSorterDoCompare(pCsr, i);
+ }
+
+ *pbEof = (pSorter->aIter[pSorter->aTree[1]].pFile==0);
+ }else{
+ SorterRecord *pFree = pSorter->pRecord;
+ pSorter->pRecord = pFree->pNext;
+ pFree->pNext = 0;
+ vdbeSorterRecordFree(db, pFree);
+ *pbEof = !pSorter->pRecord;
+ rc = SQLITE_OK;
+ }
+ return rc;
+}
+
+/*
+** Return a pointer to a buffer owned by the sorter that contains the
+** current key.
+*/
+static void *vdbeSorterRowkey(
+ const VdbeSorter *pSorter, /* Sorter object */
+ int *pnKey /* OUT: Size of current key in bytes */
+){
+ void *pKey;
+ if( pSorter->aTree ){
+ VdbeSorterIter *pIter;
+ pIter = &pSorter->aIter[ pSorter->aTree[1] ];
+ *pnKey = pIter->nKey;
+ pKey = pIter->aKey;
+ }else{
+ *pnKey = pSorter->pRecord->nVal;
+ pKey = pSorter->pRecord->pVal;
+ }
+ return pKey;
+}
+
+/*
+** Copy the current sorter key into the memory cell pOut.
+*/
+SQLITE_PRIVATE int sqlite3VdbeSorterRowkey(const VdbeCursor *pCsr, Mem *pOut){
+ VdbeSorter *pSorter = pCsr->pSorter;
+ void *pKey; int nKey; /* Sorter key to copy into pOut */
+
+ pKey = vdbeSorterRowkey(pSorter, &nKey);
+ if( sqlite3VdbeMemGrow(pOut, nKey, 0) ){
+ return SQLITE_NOMEM;
+ }
+ pOut->n = nKey;
+ MemSetTypeFlag(pOut, MEM_Blob);
+ memcpy(pOut->z, pKey, nKey);
+
+ return SQLITE_OK;
+}
+
+/*
+** Compare the key in memory cell pVal with the key that the sorter cursor
+** passed as the first argument currently points to. For the purposes of
+** the comparison, ignore the rowid field at the end of each record.
+**
+** If an error occurs, return an SQLite error code (i.e. SQLITE_NOMEM).
+** Otherwise, set *pRes to a negative, zero or positive value if the
+** key in pVal is smaller than, equal to or larger than the current sorter
+** key.
+*/
+SQLITE_PRIVATE int sqlite3VdbeSorterCompare(
+ const VdbeCursor *pCsr, /* Sorter cursor */
+ Mem *pVal, /* Value to compare to current sorter key */
+ int *pRes /* OUT: Result of comparison */
+){
+ VdbeSorter *pSorter = pCsr->pSorter;
+ void *pKey; int nKey; /* Sorter key to compare pVal with */
+
+ pKey = vdbeSorterRowkey(pSorter, &nKey);
+ vdbeSorterCompare(pCsr, 1, pVal->z, pVal->n, pKey, nKey, pRes);
+ return SQLITE_OK;
+}
+
+/************** End of vdbesort.c ********************************************/
/************** Begin file journal.c *****************************************/
/*
** 2007 August 22
@@ -69472,6 +72041,14 @@ static int createFile(JournalFile *p){
assert(p->iSize<=p->nBuf);
rc = sqlite3OsWrite(p->pReal, p->zBuf, p->iSize, 0);
}
+ if( rc!=SQLITE_OK ){
+ /* If an error occurred while writing to the file, close it before
+ ** returning. This way, SQLite uses the in-memory journal data to
+ ** roll back changes made to the internal page-cache before this
+ ** function was called. */
+ sqlite3OsClose(pReal);
+ p->pReal = 0;
+ }
}
}
return rc;
@@ -69641,6 +72218,16 @@ SQLITE_PRIVATE int sqlite3JournalCreate(sqlite3_file *p){
return createFile((JournalFile *)p);
}
+/*
+** The file-handle passed as the only argument is guaranteed to be an open
+** file. It may or may not be of class JournalFile. If the file is a
+** JournalFile, and the underlying file on disk has not yet been opened,
+** return 0. Otherwise, return 1.
+*/
+SQLITE_PRIVATE int sqlite3JournalExists(sqlite3_file *p){
+ return (p->pMethods!=&JournalFileMethods || ((JournalFile *)p)->pReal!=0);
+}
+
/*
** Return the number of bytes required to store a JournalFile that uses vfs
** pVfs to create the underlying on-disk files.
@@ -69927,6 +72514,8 @@ SQLITE_PRIVATE int sqlite3MemJournalSize(void){
** This file contains routines used for walking the parser tree for
** an SQL statement.
*/
+/* #include <stdlib.h> */
+/* #include <string.h> */
/*
@@ -70037,13 +72626,19 @@ SQLITE_PRIVATE int sqlite3WalkSelect(Walker *pWalker, Select *p){
int rc;
if( p==0 || pWalker->xSelectCallback==0 ) return WRC_Continue;
rc = WRC_Continue;
- while( p ){
+ pWalker->walkerDepth++;
+ while( p ){
rc = pWalker->xSelectCallback(pWalker, p);
if( rc ) break;
- if( sqlite3WalkSelectExpr(pWalker, p) ) return WRC_Abort;
- if( sqlite3WalkSelectFrom(pWalker, p) ) return WRC_Abort;
+ if( sqlite3WalkSelectExpr(pWalker, p)
+ || sqlite3WalkSelectFrom(pWalker, p)
+ ){
+ pWalker->walkerDepth--;
+ return WRC_Abort;
+ }
p = p->pPrior;
}
+ pWalker->walkerDepth--;
return rc & WRC_Abort;
}
@@ -70065,6 +72660,31 @@ SQLITE_PRIVATE int sqlite3WalkSelect(Walker *pWalker, Select *p){
** resolve all identifiers by associating them with a particular
** table and column.
*/
+/* #include <stdlib.h> */
+/* #include <string.h> */
+
+/*
+** Walk the expression tree pExpr and increase the aggregate function
+** depth (the Expr.op2 field) by N on every TK_AGG_FUNCTION node.
+** This needs to occur when copying a TK_AGG_FUNCTION node from an
+** outer query into an inner subquery.
+**
+** incrAggFunctionDepth(pExpr,n) is the main routine. incrAggDepth(..)
+** is a helper function - a callback for the tree walker.
+*/
+static int incrAggDepth(Walker *pWalker, Expr *pExpr){
+ if( pExpr->op==TK_AGG_FUNCTION ) pExpr->op2 += pWalker->u.i;
+ return WRC_Continue;
+}
+static void incrAggFunctionDepth(Expr *pExpr, int N){
+ if( N>0 ){
+ Walker w;
+ memset(&w, 0, sizeof(w));
+ w.xExprCallback = incrAggDepth;
+ w.u.i = N;
+ sqlite3WalkExpr(&w, pExpr);
+ }
+}
/*
** Turn the pExpr expression into an alias for the iCol-th column of the
@@ -70092,13 +72712,29 @@ SQLITE_PRIVATE int sqlite3WalkSelect(Walker *pWalker, Select *p){
** The result of random()%5 in the GROUP BY clause is probably different
** from the result in the result-set. We might fix this someday. Or
** then again, we might not...
+**
+** If the reference is followed by a COLLATE operator, then make sure
+** the COLLATE operator is preserved. For example:
+**
+** SELECT a+b, c+d FROM t1 ORDER BY 1 COLLATE nocase;
+**
+** Should be transformed into:
+**
+** SELECT a+b, c+d FROM t1 ORDER BY (a+b) COLLATE nocase;
+**
+** The nSubquery parameter specifies how many levels of subquery the
+** alias is removed from the original expression. The usually value is
+** zero but it might be more if the alias is contained within a subquery
+** of the original expression. The Expr.op2 field of TK_AGG_FUNCTION
+** structures must be increased by the nSubquery amount.
*/
static void resolveAlias(
Parse *pParse, /* Parsing context */
ExprList *pEList, /* A result set */
int iCol, /* A column in the result set. 0..pEList->nExpr-1 */
Expr *pExpr, /* Transform this into an alias to the result set */
- const char *zType /* "GROUP" or "ORDER" or "" */
+ const char *zType, /* "GROUP" or "ORDER" or "" */
+ int nSubquery /* Number of subqueries that the label is moving */
){
Expr *pOrig; /* The iCol-th column of the result set */
Expr *pDup; /* Copy of pOrig */
@@ -70109,43 +72745,86 @@ static void resolveAlias(
assert( pOrig!=0 );
assert( pOrig->flags & EP_Resolved );
db = pParse->db;
+ pDup = sqlite3ExprDup(db, pOrig, 0);
+ if( pDup==0 ) return;
if( pOrig->op!=TK_COLUMN && zType[0]!='G' ){
- pDup = sqlite3ExprDup(db, pOrig, 0);
+ incrAggFunctionDepth(pDup, nSubquery);
pDup = sqlite3PExpr(pParse, TK_AS, pDup, 0, 0);
if( pDup==0 ) return;
if( pEList->a[iCol].iAlias==0 ){
pEList->a[iCol].iAlias = (u16)(++pParse->nAlias);
}
pDup->iTable = pEList->a[iCol].iAlias;
- }else if( ExprHasProperty(pOrig, EP_IntValue) || pOrig->u.zToken==0 ){
- pDup = sqlite3ExprDup(db, pOrig, 0);
- if( pDup==0 ) return;
- }else{
- char *zToken = pOrig->u.zToken;
- assert( zToken!=0 );
- pOrig->u.zToken = 0;
- pDup = sqlite3ExprDup(db, pOrig, 0);
- pOrig->u.zToken = zToken;
- if( pDup==0 ) return;
- assert( (pDup->flags & (EP_Reduced|EP_TokenOnly))==0 );
- pDup->flags2 |= EP2_MallocedToken;
- pDup->u.zToken = sqlite3DbStrDup(db, zToken);
}
- if( pExpr->flags & EP_ExpCollate ){
- pDup->pColl = pExpr->pColl;
- pDup->flags |= EP_ExpCollate;
+ if( pExpr->op==TK_COLLATE ){
+ pDup = sqlite3ExprAddCollateString(pParse, pDup, pExpr->u.zToken);
}
/* Before calling sqlite3ExprDelete(), set the EP_Static flag. This
** prevents ExprDelete() from deleting the Expr structure itself,
** allowing it to be repopulated by the memcpy() on the following line.
+ ** The pExpr->u.zToken might point into memory that will be freed by the
+ ** sqlite3DbFree(db, pDup) on the last line of this block, so be sure to
+ ** make a copy of the token before doing the sqlite3DbFree().
*/
ExprSetProperty(pExpr, EP_Static);
sqlite3ExprDelete(db, pExpr);
memcpy(pExpr, pDup, sizeof(*pExpr));
+ if( !ExprHasProperty(pExpr, EP_IntValue) && pExpr->u.zToken!=0 ){
+ assert( (pExpr->flags & (EP_Reduced|EP_TokenOnly))==0 );
+ pExpr->u.zToken = sqlite3DbStrDup(db, pExpr->u.zToken);
+ pExpr->flags2 |= EP2_MallocedToken;
+ }
sqlite3DbFree(db, pDup);
}
+
+/*
+** Return TRUE if the name zCol occurs anywhere in the USING clause.
+**
+** Return FALSE if the USING clause is NULL or if it does not contain
+** zCol.
+*/
+static int nameInUsingClause(IdList *pUsing, const char *zCol){
+ if( pUsing ){
+ int k;
+ for(k=0; k<pUsing->nId; k++){
+ if( sqlite3StrICmp(pUsing->a[k].zName, zCol)==0 ) return 1;
+ }
+ }
+ return 0;
+}
+
+/*
+** Subqueries stores the original database, table and column names for their
+** result sets in ExprList.a[].zSpan, in the form "DATABASE.TABLE.COLUMN".
+** Check to see if the zSpan given to this routine matches the zDb, zTab,
+** and zCol. If any of zDb, zTab, and zCol are NULL then those fields will
+** match anything.
+*/
+SQLITE_PRIVATE int sqlite3MatchSpanName(
+ const char *zSpan,
+ const char *zCol,
+ const char *zTab,
+ const char *zDb
+){
+ int n;
+ for(n=0; ALWAYS(zSpan[n]) && zSpan[n]!='.'; n++){}
+ if( zDb && (sqlite3StrNICmp(zSpan, zDb, n)!=0 || zDb[n]!=0) ){
+ return 0;
+ }
+ zSpan += n+1;
+ for(n=0; ALWAYS(zSpan[n]) && zSpan[n]!='.'; n++){}
+ if( zTab && (sqlite3StrNICmp(zSpan, zTab, n)!=0 || zTab[n]!=0) ){
+ return 0;
+ }
+ zSpan += n+1;
+ if( zCol && sqlite3StrICmp(zSpan, zCol)!=0 ){
+ return 0;
+ }
+ return 1;
+}
+
/*
** Given the name of a column of the form X.Y.Z or Y.Z or just Z, look up
** that name in the set of source tables in pSrcList and make the pExpr
@@ -70181,9 +72860,10 @@ static int lookupName(
NameContext *pNC, /* The name context used to resolve the name */
Expr *pExpr /* Make this EXPR node point to the selected column */
){
- int i, j; /* Loop counters */
+ int i, j; /* Loop counters */
int cnt = 0; /* Number of matching column names */
int cntTab = 0; /* Number of matching table names */
+ int nSubquery = 0; /* How many levels of subquery */
sqlite3 *db = pParse->db; /* The database connection */
struct SrcList_item *pItem; /* Use for looping over pSrcList items */
struct SrcList_item *pMatch = 0; /* The matching pSrcList item */
@@ -70193,13 +72873,27 @@ static int lookupName(
assert( pNC ); /* the name context cannot be NULL. */
assert( zCol ); /* The Z in X.Y.Z cannot be NULL */
- assert( ~ExprHasAnyProperty(pExpr, EP_TokenOnly|EP_Reduced) );
+ assert( !ExprHasAnyProperty(pExpr, EP_TokenOnly|EP_Reduced) );
/* Initialize the node to no-match */
pExpr->iTable = -1;
pExpr->pTab = 0;
ExprSetIrreducible(pExpr);
+ /* Translate the schema name in zDb into a pointer to the corresponding
+ ** schema. If not found, pSchema will remain NULL and nothing will match
+ ** resulting in an appropriate error message toward the end of this routine
+ */
+ if( zDb ){
+ for(i=0; i<db->nDb; i++){
+ assert( db->aDb[i].zName );
+ if( sqlite3StrICmp(db->aDb[i].zName,zDb)==0 ){
+ pSchema = db->aDb[i].pSchema;
+ break;
+ }
+ }
+ }
+
/* Start at the inner-most context and move outward until a match is found */
while( pNC && cnt==0 ){
ExprList *pEList;
@@ -70208,68 +72902,62 @@ static int lookupName(
if( pSrcList ){
for(i=0, pItem=pSrcList->a; i<pSrcList->nSrc; i++, pItem++){
Table *pTab;
- int iDb;
Column *pCol;
pTab = pItem->pTab;
assert( pTab!=0 && pTab->zName!=0 );
- iDb = sqlite3SchemaToIndex(db, pTab->pSchema);
assert( pTab->nCol>0 );
- if( zTab ){
- if( pItem->zAlias ){
- char *zTabName = pItem->zAlias;
- if( sqlite3StrICmp(zTabName, zTab)!=0 ) continue;
- }else{
- char *zTabName = pTab->zName;
- if( NEVER(zTabName==0) || sqlite3StrICmp(zTabName, zTab)!=0 ){
- continue;
- }
- if( zDb!=0 && sqlite3StrICmp(db->aDb[iDb].zName, zDb)!=0 ){
- continue;
+ if( pItem->pSelect && (pItem->pSelect->selFlags & SF_NestedFrom)!=0 ){
+ int hit = 0;
+ pEList = pItem->pSelect->pEList;
+ for(j=0; j<pEList->nExpr; j++){
+ if( sqlite3MatchSpanName(pEList->a[j].zSpan, zCol, zTab, zDb) ){
+ cnt++;
+ cntTab = 2;
+ pMatch = pItem;
+ pExpr->iColumn = j;
+ hit = 1;
}
}
+ if( hit || zTab==0 ) continue;
+ }
+ if( zDb && pTab->pSchema!=pSchema ){
+ continue;
+ }
+ if( zTab ){
+ const char *zTabName = pItem->zAlias ? pItem->zAlias : pTab->zName;
+ assert( zTabName!=0 );
+ if( sqlite3StrICmp(zTabName, zTab)!=0 ){
+ continue;
+ }
}
if( 0==(cntTab++) ){
- pExpr->iTable = pItem->iCursor;
- pExpr->pTab = pTab;
- pSchema = pTab->pSchema;
pMatch = pItem;
}
for(j=0, pCol=pTab->aCol; j<pTab->nCol; j++, pCol++){
if( sqlite3StrICmp(pCol->zName, zCol)==0 ){
- IdList *pUsing;
+ /* If there has been exactly one prior match and this match
+ ** is for the right-hand table of a NATURAL JOIN or is in a
+ ** USING clause, then skip this match.
+ */
+ if( cnt==1 ){
+ if( pItem->jointype & JT_NATURAL ) continue;
+ if( nameInUsingClause(pItem->pUsing, zCol) ) continue;
+ }
cnt++;
- pExpr->iTable = pItem->iCursor;
- pExpr->pTab = pTab;
pMatch = pItem;
- pSchema = pTab->pSchema;
/* Substitute the rowid (column -1) for the INTEGER PRIMARY KEY */
pExpr->iColumn = j==pTab->iPKey ? -1 : (i16)j;
- if( i<pSrcList->nSrc-1 ){
- if( pItem[1].jointype & JT_NATURAL ){
- /* If this match occurred in the left table of a natural join,
- ** then skip the right table to avoid a duplicate match */
- pItem++;
- i++;
- }else if( (pUsing = pItem[1].pUsing)!=0 ){
- /* If this match occurs on a column that is in the USING clause
- ** of a join, skip the search of the right table of the join
- ** to avoid a duplicate match there. */
- int k;
- for(k=0; k<pUsing->nId; k++){
- if( sqlite3StrICmp(pUsing->a[k].zName, zCol)==0 ){
- pItem++;
- i++;
- break;
- }
- }
- }
- }
break;
}
}
}
- }
+ if( pMatch ){
+ pExpr->iTable = pMatch->iCursor;
+ pExpr->pTab = pMatch->pTab;
+ pSchema = pExpr->pTab->pSchema;
+ }
+ } /* if( pSrcList ) */
#ifndef SQLITE_OMIT_TRIGGER
/* If we have not already resolved the name, then maybe
@@ -70354,11 +73042,11 @@ static int lookupName(
assert( pExpr->x.pList==0 );
assert( pExpr->x.pSelect==0 );
pOrig = pEList->a[j].pExpr;
- if( !pNC->allowAgg && ExprHasProperty(pOrig, EP_Agg) ){
+ if( (pNC->ncFlags&NC_AllowAgg)==0 && ExprHasProperty(pOrig, EP_Agg) ){
sqlite3ErrorMsg(pParse, "misuse of aliased aggregate %s", zAs);
return WRC_Abort;
}
- resolveAlias(pParse, pEList, j, pExpr, "");
+ resolveAlias(pParse, pEList, j, pExpr, "", nSubquery);
cnt = 1;
pMatch = 0;
assert( zTab==0 && zDb==0 );
@@ -70372,6 +73060,7 @@ static int lookupName(
*/
if( cnt==0 ){
pNC = pNC->pNext;
+ nSubquery++;
}
}
@@ -70576,7 +73265,7 @@ static int resolveExprStep(Walker *pWalker, Expr *pExpr){
nId = sqlite3Strlen30(zId);
pDef = sqlite3FindFunction(pParse->db, zId, nId, n, enc, 0);
if( pDef==0 ){
- pDef = sqlite3FindFunction(pParse->db, zId, nId, -1, enc, 0);
+ pDef = sqlite3FindFunction(pParse->db, zId, nId, -2, enc, 0);
if( pDef==0 ){
no_such_func = 1;
}else{
@@ -70599,11 +73288,11 @@ static int resolveExprStep(Walker *pWalker, Expr *pExpr){
}
}
#endif
- if( is_agg && !pNC->allowAgg ){
+ if( is_agg && (pNC->ncFlags & NC_AllowAgg)==0 ){
sqlite3ErrorMsg(pParse, "misuse of aggregate function %.*s()", nId,zId);
pNC->nErr++;
is_agg = 0;
- }else if( no_such_func ){
+ }else if( no_such_func && pParse->db->init.busy==0 ){
sqlite3ErrorMsg(pParse, "no such function: %.*s", nId, zId);
pNC->nErr++;
}else if( wrong_num_args ){
@@ -70611,13 +73300,19 @@ static int resolveExprStep(Walker *pWalker, Expr *pExpr){
nId, zId);
pNC->nErr++;
}
+ if( is_agg ) pNC->ncFlags &= ~NC_AllowAgg;
+ sqlite3WalkExprList(pWalker, pList);
if( is_agg ){
+ NameContext *pNC2 = pNC;
pExpr->op = TK_AGG_FUNCTION;
- pNC->hasAgg = 1;
+ pExpr->op2 = 0;
+ while( pNC2 && !sqlite3FunctionUsesThisSrc(pExpr, pNC2->pSrcList) ){
+ pExpr->op2++;
+ pNC2 = pNC2->pNext;
+ }
+ if( pNC2 ) pNC2->ncFlags |= NC_HasAgg;
+ pNC->ncFlags |= NC_AllowAgg;
}
- if( is_agg ) pNC->allowAgg = 0;
- sqlite3WalkExprList(pWalker, pList);
- if( is_agg ) pNC->allowAgg = 1;
/* FIX ME: Compute pExpr->affinity based on the expected return
** type of the function
*/
@@ -70632,7 +73327,7 @@ static int resolveExprStep(Walker *pWalker, Expr *pExpr){
if( ExprHasProperty(pExpr, EP_xIsSelect) ){
int nRef = pNC->nRef;
#ifndef SQLITE_OMIT_CHECK
- if( pNC->isCheck ){
+ if( (pNC->ncFlags & NC_IsCheck)!=0 ){
sqlite3ErrorMsg(pParse,"subqueries prohibited in CHECK constraints");
}
#endif
@@ -70646,7 +73341,7 @@ static int resolveExprStep(Walker *pWalker, Expr *pExpr){
}
#ifndef SQLITE_OMIT_CHECK
case TK_VARIABLE: {
- if( pNC->isCheck ){
+ if( (pNC->ncFlags & NC_IsCheck)!=0 ){
sqlite3ErrorMsg(pParse,"parameters prohibited in CHECK constraints");
}
break;
@@ -70728,7 +73423,7 @@ static int resolveOrderByTermToExprList(
nc.pParse = pParse;
nc.pSrcList = pSelect->pSrc;
nc.pEList = pEList;
- nc.allowAgg = 1;
+ nc.ncFlags = NC_AllowAgg;
nc.nErr = 0;
db = pParse->db;
savedSuppErr = db->suppressErr;
@@ -70816,7 +73511,7 @@ static int resolveCompoundOrderBy(
int iCol = -1;
Expr *pE, *pDup;
if( pItem->done ) continue;
- pE = pItem->pExpr;
+ pE = sqlite3ExprSkipCollate(pItem->pExpr);
if( sqlite3ExprIsInteger(pE, &iCol) ){
if( iCol<=0 || iCol>pEList->nExpr ){
resolveOutOfRangeError(pParse, "ORDER", i+1, pEList->nExpr);
@@ -70834,15 +73529,21 @@ static int resolveCompoundOrderBy(
}
}
if( iCol>0 ){
- CollSeq *pColl = pE->pColl;
- int flags = pE->flags & EP_ExpCollate;
+ /* Convert the ORDER BY term into an integer column number iCol,
+ ** taking care to preserve the COLLATE clause if it exists */
+ Expr *pNew = sqlite3Expr(db, TK_INTEGER, 0);
+ if( pNew==0 ) return 1;
+ pNew->flags |= EP_IntValue;
+ pNew->u.iValue = iCol;
+ if( pItem->pExpr==pE ){
+ pItem->pExpr = pNew;
+ }else{
+ assert( pItem->pExpr->op==TK_COLLATE );
+ assert( pItem->pExpr->pLeft==pE );
+ pItem->pExpr->pLeft = pNew;
+ }
sqlite3ExprDelete(db, pE);
- pItem->pExpr = pE = sqlite3Expr(db, TK_INTEGER, 0);
- if( pE==0 ) return 1;
- pE->pColl = pColl;
- pE->flags |= EP_IntValue | flags;
- pE->u.iValue = iCol;
- pItem->iCol = (u16)iCol;
+ pItem->iOrderByCol = (u16)iCol;
pItem->done = 1;
}else{
moreToDo = 1;
@@ -70891,12 +73592,12 @@ SQLITE_PRIVATE int sqlite3ResolveOrderGroupBy(
pEList = pSelect->pEList;
assert( pEList!=0 ); /* sqlite3SelectNew() guarantees this */
for(i=0, pItem=pOrderBy->a; i<pOrderBy->nExpr; i++, pItem++){
- if( pItem->iCol ){
- if( pItem->iCol>pEList->nExpr ){
+ if( pItem->iOrderByCol ){
+ if( pItem->iOrderByCol>pEList->nExpr ){
resolveOutOfRangeError(pParse, zType, i+1, pEList->nExpr);
return 1;
}
- resolveAlias(pParse, pEList, pItem->iCol-1, pItem->pExpr, zType);
+ resolveAlias(pParse, pEList, pItem->iOrderByCol-1, pItem->pExpr, zType,0);
}
}
return 0;
@@ -70926,7 +73627,7 @@ static int resolveOrderGroupBy(
ExprList *pOrderBy, /* An ORDER BY or GROUP BY clause to resolve */
const char *zType /* Either "ORDER" or "GROUP", as appropriate */
){
- int i; /* Loop counter */
+ int i, j; /* Loop counters */
int iCol; /* Column number */
struct ExprList_item *pItem; /* A term of the ORDER BY clause */
Parse *pParse; /* Parsing context */
@@ -70943,26 +73644,31 @@ static int resolveOrderGroupBy(
** a copy of the iCol-th result-set column. The subsequent call to
** sqlite3ResolveOrderGroupBy() will convert the expression to a
** copy of the iCol-th result-set expression. */
- pItem->iCol = (u16)iCol;
+ pItem->iOrderByCol = (u16)iCol;
continue;
}
- if( sqlite3ExprIsInteger(pE, &iCol) ){
+ if( sqlite3ExprIsInteger(sqlite3ExprSkipCollate(pE), &iCol) ){
/* The ORDER BY term is an integer constant. Again, set the column
** number so that sqlite3ResolveOrderGroupBy() will convert the
** order-by term to a copy of the result-set expression */
- if( iCol<1 ){
+ if( iCol<1 || iCol>0xffff ){
resolveOutOfRangeError(pParse, zType, i+1, nResult);
return 1;
}
- pItem->iCol = (u16)iCol;
+ pItem->iOrderByCol = (u16)iCol;
continue;
}
/* Otherwise, treat the ORDER BY term as an ordinary expression */
- pItem->iCol = 0;
+ pItem->iOrderByCol = 0;
if( sqlite3ResolveExprNames(pNC, pE) ){
return 1;
}
+ for(j=0; j<pSelect->pEList->nExpr; j++){
+ if( sqlite3ExprCompare(pE, pSelect->pEList->a[j].pExpr)==0 ){
+ pItem->iOrderByCol = j+1;
+ }
+ }
}
return sqlite3ResolveOrderGroupBy(pParse, pSelect, pOrderBy, zType);
}
@@ -71022,10 +73728,37 @@ static int resolveSelectStep(Walker *pWalker, Select *p){
return WRC_Abort;
}
+ /* Recursively resolve names in all subqueries
+ */
+ for(i=0; i<p->pSrc->nSrc; i++){
+ struct SrcList_item *pItem = &p->pSrc->a[i];
+ if( pItem->pSelect ){
+ NameContext *pNC; /* Used to iterate name contexts */
+ int nRef = 0; /* Refcount for pOuterNC and outer contexts */
+ const char *zSavedContext = pParse->zAuthContext;
+
+ /* Count the total number of references to pOuterNC and all of its
+ ** parent contexts. After resolving references to expressions in
+ ** pItem->pSelect, check if this value has changed. If so, then
+ ** SELECT statement pItem->pSelect must be correlated. Set the
+ ** pItem->isCorrelated flag if this is the case. */
+ for(pNC=pOuterNC; pNC; pNC=pNC->pNext) nRef += pNC->nRef;
+
+ if( pItem->zName ) pParse->zAuthContext = pItem->zName;
+ sqlite3ResolveSelectNames(pParse, pItem->pSelect, pOuterNC);
+ pParse->zAuthContext = zSavedContext;
+ if( pParse->nErr || db->mallocFailed ) return WRC_Abort;
+
+ for(pNC=pOuterNC; pNC; pNC=pNC->pNext) nRef -= pNC->nRef;
+ assert( pItem->isCorrelated==0 && nRef<=0 );
+ pItem->isCorrelated = (nRef!=0);
+ }
+ }
+
/* Set up the local name-context to pass to sqlite3ResolveExprNames() to
** resolve the result-set expression list.
*/
- sNC.allowAgg = 1;
+ sNC.ncFlags = NC_AllowAgg;
sNC.pSrcList = p->pSrc;
sNC.pNext = pOuterNC;
@@ -71039,28 +73772,15 @@ static int resolveSelectStep(Walker *pWalker, Select *p){
}
}
- /* Recursively resolve names in all subqueries
- */
- for(i=0; i<p->pSrc->nSrc; i++){
- struct SrcList_item *pItem = &p->pSrc->a[i];
- if( pItem->pSelect ){
- const char *zSavedContext = pParse->zAuthContext;
- if( pItem->zName ) pParse->zAuthContext = pItem->zName;
- sqlite3ResolveSelectNames(pParse, pItem->pSelect, pOuterNC);
- pParse->zAuthContext = zSavedContext;
- if( pParse->nErr || db->mallocFailed ) return WRC_Abort;
- }
- }
-
/* If there are no aggregate functions in the result-set, and no GROUP BY
** expression, do not allow aggregates in any of the other expressions.
*/
assert( (p->selFlags & SF_Aggregate)==0 );
pGroupBy = p->pGroupBy;
- if( pGroupBy || sNC.hasAgg ){
+ if( pGroupBy || (sNC.ncFlags & NC_HasAgg)!=0 ){
p->selFlags |= SF_Aggregate;
}else{
- sNC.allowAgg = 0;
+ sNC.ncFlags &= ~NC_AllowAgg;
}
/* If a HAVING clause is present, then there must be a GROUP BY clause.
@@ -71089,7 +73809,7 @@ static int resolveSelectStep(Walker *pWalker, Select *p){
** outer queries
*/
sNC.pNext = 0;
- sNC.allowAgg = 1;
+ sNC.ncFlags |= NC_AllowAgg;
/* Process the ORDER BY clause for singleton SELECT statements.
** The ORDER BY clause for compounds SELECT statements is handled
@@ -71177,7 +73897,7 @@ static int resolveSelectStep(Walker *pWalker, Select *p){
**
** Function calls are checked to make sure that the function is
** defined and that the correct number of arguments are specified.
-** If the function is an aggregate function, then the pNC->hasAgg is
+** If the function is an aggregate function, then the NC_HasAgg flag is
** set and the opcode is changed from TK_FUNCTION to TK_AGG_FUNCTION.
** If an expression contains aggregate functions then the EP_Agg
** property on the expression is set.
@@ -71189,7 +73909,7 @@ SQLITE_PRIVATE int sqlite3ResolveExprNames(
NameContext *pNC, /* Namespace to resolve expressions in. */
Expr *pExpr /* The expression to be analyzed. */
){
- int savedHasAgg;
+ u8 savedHasAgg;
Walker w;
if( pExpr==0 ) return 0;
@@ -71202,8 +73922,8 @@ SQLITE_PRIVATE int sqlite3ResolveExprNames(
pParse->nHeight += pExpr->nHeight;
}
#endif
- savedHasAgg = pNC->hasAgg;
- pNC->hasAgg = 0;
+ savedHasAgg = pNC->ncFlags & NC_HasAgg;
+ pNC->ncFlags &= ~NC_HasAgg;
w.xExprCallback = resolveExprStep;
w.xSelectCallback = resolveSelectStep;
w.pParse = pNC->pParse;
@@ -71215,10 +73935,10 @@ SQLITE_PRIVATE int sqlite3ResolveExprNames(
if( pNC->nErr>0 || w.pParse->nErr>0 ){
ExprSetProperty(pExpr, EP_Error);
}
- if( pNC->hasAgg ){
+ if( pNC->ncFlags & NC_HasAgg ){
ExprSetProperty(pExpr, EP_Agg);
}else if( savedHasAgg ){
- pNC->hasAgg = 1;
+ pNC->ncFlags |= NC_HasAgg;
}
return ExprHasProperty(pExpr, EP_Error);
}
@@ -71285,7 +74005,9 @@ SQLITE_PRIVATE void sqlite3ResolveSelectNames(
** SELECT * FROM t1 WHERE (select a from t1);
*/
SQLITE_PRIVATE char sqlite3ExprAffinity(Expr *pExpr){
- int op = pExpr->op;
+ int op;
+ pExpr = sqlite3ExprSkipCollate(pExpr);
+ op = pExpr->op;
if( op==TK_SELECT ){
assert( pExpr->flags&EP_xIsSelect );
return sqlite3ExprAffinity(pExpr->x.pSelect->pEList->a[0].pExpr);
@@ -71310,66 +74032,94 @@ SQLITE_PRIVATE char sqlite3ExprAffinity(Expr *pExpr){
}
/*
-** Set the explicit collating sequence for an expression to the
-** collating sequence supplied in the second argument.
+** Set the collating sequence for expression pExpr to be the collating
+** sequence named by pToken. Return a pointer to a new Expr node that
+** implements the COLLATE operator.
+**
+** If a memory allocation error occurs, that fact is recorded in pParse->db
+** and the pExpr parameter is returned unchanged.
*/
-SQLITE_PRIVATE Expr *sqlite3ExprSetColl(Expr *pExpr, CollSeq *pColl){
- if( pExpr && pColl ){
- pExpr->pColl = pColl;
- pExpr->flags |= EP_ExpCollate;
+SQLITE_PRIVATE Expr *sqlite3ExprAddCollateToken(Parse *pParse, Expr *pExpr, Token *pCollName){
+ if( pCollName->n>0 ){
+ Expr *pNew = sqlite3ExprAlloc(pParse->db, TK_COLLATE, pCollName, 1);
+ if( pNew ){
+ pNew->pLeft = pExpr;
+ pNew->flags |= EP_Collate;
+ pExpr = pNew;
+ }
}
return pExpr;
}
+SQLITE_PRIVATE Expr *sqlite3ExprAddCollateString(Parse *pParse, Expr *pExpr, const char *zC){
+ Token s;
+ assert( zC!=0 );
+ s.z = zC;
+ s.n = sqlite3Strlen30(s.z);
+ return sqlite3ExprAddCollateToken(pParse, pExpr, &s);
+}
/*
-** Set the collating sequence for expression pExpr to be the collating
-** sequence named by pToken. Return a pointer to the revised expression.
-** The collating sequence is marked as "explicit" using the EP_ExpCollate
-** flag. An explicit collating sequence will override implicit
-** collating sequences.
+** Skip over any TK_COLLATE and/or TK_AS operators at the root of
+** an expression.
*/
-SQLITE_PRIVATE Expr *sqlite3ExprSetCollByToken(Parse *pParse, Expr *pExpr, Token *pCollName){
- char *zColl = 0; /* Dequoted name of collation sequence */
- CollSeq *pColl;
- sqlite3 *db = pParse->db;
- zColl = sqlite3NameFromToken(db, pCollName);
- pColl = sqlite3LocateCollSeq(pParse, zColl);
- sqlite3ExprSetColl(pExpr, pColl);
- sqlite3DbFree(db, zColl);
+SQLITE_PRIVATE Expr *sqlite3ExprSkipCollate(Expr *pExpr){
+ while( pExpr && (pExpr->op==TK_COLLATE || pExpr->op==TK_AS) ){
+ pExpr = pExpr->pLeft;
+ }
return pExpr;
}
/*
-** Return the default collation sequence for the expression pExpr. If
-** there is no default collation type, return 0.
+** Return the collation sequence for the expression pExpr. If
+** there is no defined collating sequence, return NULL.
+**
+** The collating sequence might be determined by a COLLATE operator
+** or by the presence of a column with a defined collating sequence.
+** COLLATE operators take first precedence. Left operands take
+** precedence over right operands.
*/
SQLITE_PRIVATE CollSeq *sqlite3ExprCollSeq(Parse *pParse, Expr *pExpr){
+ sqlite3 *db = pParse->db;
CollSeq *pColl = 0;
Expr *p = pExpr;
while( p ){
- int op;
- pColl = p->pColl;
- if( pColl ) break;
- op = p->op;
- if( p->pTab!=0 && (
- op==TK_AGG_COLUMN || op==TK_COLUMN || op==TK_REGISTER || op==TK_TRIGGER
- )){
+ int op = p->op;
+ if( op==TK_CAST || op==TK_UPLUS ){
+ p = p->pLeft;
+ continue;
+ }
+ assert( op!=TK_REGISTER || p->op2!=TK_COLLATE );
+ if( op==TK_COLLATE ){
+ if( db->init.busy ){
+ /* Do not report errors when parsing while the schema */
+ pColl = sqlite3FindCollSeq(db, ENC(db), p->u.zToken, 0);
+ }else{
+ pColl = sqlite3GetCollSeq(pParse, ENC(db), 0, p->u.zToken);
+ }
+ break;
+ }
+ if( p->pTab!=0
+ && (op==TK_AGG_COLUMN || op==TK_COLUMN
+ || op==TK_REGISTER || op==TK_TRIGGER)
+ ){
/* op==TK_REGISTER && p->pTab!=0 happens when pExpr was originally
** a TK_COLUMN but was previously evaluated and cached in a register */
- const char *zColl;
int j = p->iColumn;
if( j>=0 ){
- sqlite3 *db = pParse->db;
- zColl = p->pTab->aCol[j].zColl;
+ const char *zColl = p->pTab->aCol[j].zColl;
pColl = sqlite3FindCollSeq(db, ENC(db), zColl, 0);
- pExpr->pColl = pColl;
}
break;
}
- if( op!=TK_CAST && op!=TK_UPLUS ){
+ if( p->flags & EP_Collate ){
+ if( ALWAYS(p->pLeft) && (p->pLeft->flags & EP_Collate)!=0 ){
+ p = p->pLeft;
+ }else{
+ p = p->pRight;
+ }
+ }else{
break;
}
- p = p->pLeft;
}
if( sqlite3CheckCollSeq(pParse, pColl) ){
pColl = 0;
@@ -71473,12 +74223,10 @@ SQLITE_PRIVATE CollSeq *sqlite3BinaryCompareCollSeq(
){
CollSeq *pColl;
assert( pLeft );
- if( pLeft->flags & EP_ExpCollate ){
- assert( pLeft->pColl );
- pColl = pLeft->pColl;
- }else if( pRight && pRight->flags & EP_ExpCollate ){
- assert( pRight->pColl );
- pColl = pRight->pColl;
+ if( pLeft->flags & EP_Collate ){
+ pColl = sqlite3ExprCollSeq(pParse, pLeft);
+ }else if( pRight && (pRight->flags & EP_Collate)!=0 ){
+ pColl = sqlite3ExprCollSeq(pParse, pRight);
}else{
pColl = sqlite3ExprCollSeq(pParse, pLeft);
if( !pColl ){
@@ -71657,7 +74405,8 @@ SQLITE_PRIVATE Expr *sqlite3ExprAlloc(
}else{
int c;
pNew->u.zToken = (char*)&pNew[1];
- memcpy(pNew->u.zToken, pToken->z, pToken->n);
+ assert( pToken->z!=0 || pToken->n==0 );
+ if( pToken->n ) memcpy(pNew->u.zToken, pToken->z, pToken->n);
pNew->u.zToken[pToken->n] = 0;
if( dequote && nExtra>=3
&& ((c = pToken->z[0])=='\'' || c=='"' || c=='[' || c=='`') ){
@@ -71707,17 +74456,11 @@ SQLITE_PRIVATE void sqlite3ExprAttachSubtrees(
}else{
if( pRight ){
pRoot->pRight = pRight;
- if( pRight->flags & EP_ExpCollate ){
- pRoot->flags |= EP_ExpCollate;
- pRoot->pColl = pRight->pColl;
- }
+ pRoot->flags |= EP_Collate & pRight->flags;
}
if( pLeft ){
pRoot->pLeft = pLeft;
- if( pLeft->flags & EP_ExpCollate ){
- pRoot->flags |= EP_ExpCollate;
- pRoot->pColl = pLeft->pColl;
- }
+ pRoot->flags |= EP_Collate & pLeft->flags;
}
exprSetHeight(pRoot);
}
@@ -71737,8 +74480,14 @@ SQLITE_PRIVATE Expr *sqlite3PExpr(
Expr *pRight, /* Right operand */
const Token *pToken /* Argument token */
){
- Expr *p = sqlite3ExprAlloc(pParse->db, op, pToken, 1);
- sqlite3ExprAttachSubtrees(pParse->db, p, pLeft, pRight);
+ Expr *p;
+ if( op==TK_AND && pLeft && pRight ){
+ /* Take advantage of short-circuit false optimization for AND */
+ p = sqlite3ExprAnd(pParse->db, pLeft, pRight);
+ }else{
+ p = sqlite3ExprAlloc(pParse->db, op, pToken, 1);
+ sqlite3ExprAttachSubtrees(pParse->db, p, pLeft, pRight);
+ }
if( p ) {
sqlite3ExprCheckHeight(pParse, p->nHeight);
}
@@ -71746,14 +74495,40 @@ SQLITE_PRIVATE Expr *sqlite3PExpr(
}
/*
+** Return 1 if an expression must be FALSE in all cases and 0 if the
+** expression might be true. This is an optimization. If is OK to
+** return 0 here even if the expression really is always false (a
+** false negative). But it is a bug to return 1 if the expression
+** might be true in some rare circumstances (a false positive.)
+**
+** Note that if the expression is part of conditional for a
+** LEFT JOIN, then we cannot determine at compile-time whether or not
+** is it true or false, so always return 0.
+*/
+static int exprAlwaysFalse(Expr *p){
+ int v = 0;
+ if( ExprHasProperty(p, EP_FromJoin) ) return 0;
+ if( !sqlite3ExprIsInteger(p, &v) ) return 0;
+ return v==0;
+}
+
+/*
** Join two expressions using an AND operator. If either expression is
** NULL, then just return the other expression.
+**
+** If one side or the other of the AND is known to be false, then instead
+** of returning an AND expression, just return a constant expression with
+** a value of false.
*/
SQLITE_PRIVATE Expr *sqlite3ExprAnd(sqlite3 *db, Expr *pLeft, Expr *pRight){
if( pLeft==0 ){
return pRight;
}else if( pRight==0 ){
return pLeft;
+ }else if( exprAlwaysFalse(pLeft) || exprAlwaysFalse(pRight) ){
+ sqlite3ExprDelete(db, pLeft);
+ sqlite3ExprDelete(db, pRight);
+ return sqlite3ExprAlloc(db, TK_INTEGER, &sqlite3IntTokens[0], 0);
}else{
Expr *pNew = sqlite3ExprAlloc(db, TK_AND, 0, 0);
sqlite3ExprAttachSubtrees(db, pNew, pLeft, pRight);
@@ -71837,7 +74612,7 @@ SQLITE_PRIVATE void sqlite3ExprAssignVarNumber(Parse *pParse, Expr *pExpr){
*/
ynVar i;
for(i=0; i<pParse->nzVar; i++){
- if( pParse->azVar[i] && memcmp(pParse->azVar[i],z,n+1)==0 ){
+ if( pParse->azVar[i] && strcmp(pParse->azVar[i],z)==0 ){
pExpr->iColumn = x = (ynVar)i+1;
break;
}
@@ -71943,7 +74718,7 @@ static int dupedExprStructSize(Expr *p, int flags){
assert( !ExprHasProperty(p, EP_FromJoin) );
assert( (p->flags2 & EP2_MallocedToken)==0 );
assert( (p->flags2 & EP2_Irreducible)==0 );
- if( p->pLeft || p->pRight || p->pColl || p->x.pList ){
+ if( p->pLeft || p->pRight || p->x.pList ){
nSize = EXPR_REDUCEDSIZE | EP_Reduced;
}else{
nSize = EXPR_TOKENONLYSIZE | EP_TokenOnly;
@@ -72109,8 +74884,9 @@ SQLITE_PRIVATE ExprList *sqlite3ExprListDup(sqlite3 *db, ExprList *p, int flags)
pNew = sqlite3DbMallocRaw(db, sizeof(*pNew) );
if( pNew==0 ) return 0;
pNew->iECursor = 0;
- pNew->nExpr = pNew->nAlloc = p->nExpr;
- pNew->a = pItem = sqlite3DbMallocRaw(db, p->nExpr*sizeof(p->a[0]) );
+ pNew->nExpr = i = p->nExpr;
+ if( (flags & EXPRDUP_REDUCE)==0 ) for(i=1; i<p->nExpr; i+=i){}
+ pNew->a = pItem = sqlite3DbMallocRaw(db, i*sizeof(p->a[0]) );
if( pItem==0 ){
sqlite3DbFree(db, pNew);
return 0;
@@ -72123,7 +74899,7 @@ SQLITE_PRIVATE ExprList *sqlite3ExprListDup(sqlite3 *db, ExprList *p, int flags)
pItem->zSpan = sqlite3DbStrDup(db, pOldItem->zSpan);
pItem->sortOrder = pOldItem->sortOrder;
pItem->done = 0;
- pItem->iCol = pOldItem->iCol;
+ pItem->iOrderByCol = pOldItem->iOrderByCol;
pItem->iAlias = pOldItem->iAlias;
}
return pNew;
@@ -72150,12 +74926,16 @@ SQLITE_PRIVATE SrcList *sqlite3SrcListDup(sqlite3 *db, SrcList *p, int flags){
struct SrcList_item *pNewItem = &pNew->a[i];
struct SrcList_item *pOldItem = &p->a[i];
Table *pTab;
+ pNewItem->pSchema = pOldItem->pSchema;
pNewItem->zDatabase = sqlite3DbStrDup(db, pOldItem->zDatabase);
pNewItem->zName = sqlite3DbStrDup(db, pOldItem->zName);
pNewItem->zAlias = sqlite3DbStrDup(db, pOldItem->zAlias);
pNewItem->jointype = pOldItem->jointype;
pNewItem->iCursor = pOldItem->iCursor;
- pNewItem->isPopulated = pOldItem->isPopulated;
+ pNewItem->addrFillSub = pOldItem->addrFillSub;
+ pNewItem->regReturn = pOldItem->regReturn;
+ pNewItem->isCorrelated = pOldItem->isCorrelated;
+ pNewItem->viaCoroutine = pOldItem->viaCoroutine;
pNewItem->zIndex = sqlite3DbStrDup(db, pOldItem->zIndex);
pNewItem->notIndexed = pOldItem->notIndexed;
pNewItem->pIndex = pOldItem->pIndex;
@@ -72176,12 +74956,15 @@ SQLITE_PRIVATE IdList *sqlite3IdListDup(sqlite3 *db, IdList *p){
if( p==0 ) return 0;
pNew = sqlite3DbMallocRaw(db, sizeof(*pNew) );
if( pNew==0 ) return 0;
- pNew->nId = pNew->nAlloc = p->nId;
+ pNew->nId = p->nId;
pNew->a = sqlite3DbMallocRaw(db, p->nId*sizeof(p->a[0]) );
if( pNew->a==0 ){
sqlite3DbFree(db, pNew);
return 0;
}
+ /* Note that because the size of the allocation for p->a[] is not
+ ** necessarily a power of two, sqlite3IdListAppend() may not be called
+ ** on the duplicate created by this function. */
for(i=0; i<p->nId; i++){
struct IdList_item *pNewItem = &pNew->a[i];
struct IdList_item *pOldItem = &p->a[i];
@@ -72191,7 +74974,7 @@ SQLITE_PRIVATE IdList *sqlite3IdListDup(sqlite3 *db, IdList *p){
return pNew;
}
SQLITE_PRIVATE Select *sqlite3SelectDup(sqlite3 *db, Select *p, int flags){
- Select *pNew;
+ Select *pNew, *pPrior;
if( p==0 ) return 0;
pNew = sqlite3DbMallocRaw(db, sizeof(*p) );
if( pNew==0 ) return 0;
@@ -72202,7 +74985,9 @@ SQLITE_PRIVATE Select *sqlite3SelectDup(sqlite3 *db, Select *p, int flags){
pNew->pHaving = sqlite3ExprDup(db, p->pHaving, flags);
pNew->pOrderBy = sqlite3ExprListDup(db, p->pOrderBy, flags);
pNew->op = p->op;
- pNew->pPrior = sqlite3SelectDup(db, p->pPrior, flags);
+ pNew->pPrior = pPrior = sqlite3SelectDup(db, p->pPrior, flags);
+ if( pPrior ) pPrior->pNext = pNew;
+ pNew->pNext = 0;
pNew->pLimit = sqlite3ExprDup(db, p->pLimit, flags);
pNew->pOffset = sqlite3ExprDup(db, p->pOffset, flags);
pNew->iLimit = 0;
@@ -72241,17 +75026,16 @@ SQLITE_PRIVATE ExprList *sqlite3ExprListAppend(
if( pList==0 ){
goto no_mem;
}
- assert( pList->nAlloc==0 );
- }
- if( pList->nAlloc<=pList->nExpr ){
+ pList->a = sqlite3DbMallocRaw(db, sizeof(pList->a[0]));
+ if( pList->a==0 ) goto no_mem;
+ }else if( (pList->nExpr & (pList->nExpr-1))==0 ){
struct ExprList_item *a;
- int n = pList->nAlloc*2 + 4;
- a = sqlite3DbRealloc(db, pList->a, n*sizeof(pList->a[0]));
+ assert( pList->nExpr>0 );
+ a = sqlite3DbRealloc(db, pList->a, pList->nExpr*2*sizeof(pList->a[0]));
if( a==0 ){
goto no_mem;
}
pList->a = a;
- pList->nAlloc = sqlite3DbMallocSize(db, a)/sizeof(a[0]);
}
assert( pList->a!=0 );
if( 1 ){
@@ -72342,8 +75126,7 @@ SQLITE_PRIVATE void sqlite3ExprListDelete(sqlite3 *db, ExprList *pList){
int i;
struct ExprList_item *pItem;
if( pList==0 ) return;
- assert( pList->a!=0 || (pList->nExpr==0 && pList->nAlloc==0) );
- assert( pList->nExpr<=pList->nAlloc );
+ assert( pList->a!=0 || pList->nExpr==0 );
for(pItem=pList->a, i=0; i<pList->nExpr; i++, pItem++){
sqlite3ExprDelete(db, pItem->pExpr);
sqlite3DbFree(db, pItem->zName);
@@ -72625,25 +75408,44 @@ static int isCandidateForInOpt(Select *p){
#endif /* SQLITE_OMIT_SUBQUERY */
/*
+** Code an OP_Once instruction and allocate space for its flag. Return the
+** address of the new instruction.
+*/
+SQLITE_PRIVATE int sqlite3CodeOnce(Parse *pParse){
+ Vdbe *v = sqlite3GetVdbe(pParse); /* Virtual machine being coded */
+ return sqlite3VdbeAddOp1(v, OP_Once, pParse->nOnce++);
+}
+
+/*
** This function is used by the implementation of the IN (...) operator.
-** It's job is to find or create a b-tree structure that may be used
-** either to test for membership of the (...) set or to iterate through
-** its members, skipping duplicates.
+** The pX parameter is the expression on the RHS of the IN operator, which
+** might be either a list of expressions or a subquery.
+**
+** The job of this routine is to find or create a b-tree object that can
+** be used either to test for membership in the RHS set or to iterate through
+** all members of the RHS set, skipping duplicates.
+**
+** A cursor is opened on the b-tree object that the RHS of the IN operator
+** and pX->iTable is set to the index of that cursor.
**
-** The index of the cursor opened on the b-tree (database table, database index
-** or ephermal table) is stored in pX->iTable before this function returns.
** The returned value of this function indicates the b-tree type, as follows:
**
-** IN_INDEX_ROWID - The cursor was opened on a database table.
-** IN_INDEX_INDEX - The cursor was opened on a database index.
-** IN_INDEX_EPH - The cursor was opened on a specially created and
-** populated epheremal table.
+** IN_INDEX_ROWID - The cursor was opened on a database table.
+** IN_INDEX_INDEX_ASC - The cursor was opened on an ascending index.
+** IN_INDEX_INDEX_DESC - The cursor was opened on a descending index.
+** IN_INDEX_EPH - The cursor was opened on a specially created and
+** populated epheremal table.
**
-** An existing b-tree may only be used if the SELECT is of the simple
-** form:
+** An existing b-tree might be used if the RHS expression pX is a simple
+** subquery such as:
**
** SELECT <column> FROM <table>
**
+** If the RHS of the IN operator is a list or a more complex subquery, then
+** an ephemeral table might need to be generated from the RHS and then
+** pX->iTable made to point to the ephermeral table instead of an
+** existing table.
+**
** If the prNotFound parameter is 0, then the b-tree will be used to iterate
** through the set members, skipping any duplicates. In this case an
** epheremal table must be used unless the selected <column> is guaranteed
@@ -72684,6 +75486,7 @@ SQLITE_PRIVATE int sqlite3FindInIndex(Parse *pParse, Expr *pX, int *prNotFound){
int eType = 0; /* Type of RHS table. IN_INDEX_* */
int iTab = pParse->nTab++; /* Cursor of the RHS table */
int mustBeUnique = (prNotFound==0); /* True if RHS must be unique */
+ Vdbe *v = sqlite3GetVdbe(pParse); /* Virtual machine being coded */
assert( pX->op==TK_IN );
@@ -72694,11 +75497,18 @@ SQLITE_PRIVATE int sqlite3FindInIndex(Parse *pParse, Expr *pX, int *prNotFound){
p = (ExprHasProperty(pX, EP_xIsSelect) ? pX->x.pSelect : 0);
if( ALWAYS(pParse->nErr==0) && isCandidateForInOpt(p) ){
sqlite3 *db = pParse->db; /* Database connection */
- Expr *pExpr = p->pEList->a[0].pExpr; /* Expression <column> */
- int iCol = pExpr->iColumn; /* Index of column <column> */
- Vdbe *v = sqlite3GetVdbe(pParse); /* Virtual machine being coded */
- Table *pTab = p->pSrc->a[0].pTab; /* Table <table>. */
+ Table *pTab; /* Table <table>. */
+ Expr *pExpr; /* Expression <column> */
+ int iCol; /* Index of column <column> */
int iDb; /* Database idx for pTab */
+
+ assert( p ); /* Because of isCandidateForInOpt(p) */
+ assert( p->pEList!=0 ); /* Because of isCandidateForInOpt(p) */
+ assert( p->pEList->a[0].pExpr!=0 ); /* Because of isCandidateForInOpt(p) */
+ assert( p->pSrc!=0 ); /* Because of isCandidateForInOpt(p) */
+ pTab = p->pSrc->a[0].pTab;
+ pExpr = p->pEList->a[0].pExpr;
+ iCol = pExpr->iColumn;
/* Code an OP_VerifyCookie and OP_TableLock for <table>. */
iDb = sqlite3SchemaToIndex(db, pTab->pSchema);
@@ -72711,11 +75521,9 @@ SQLITE_PRIVATE int sqlite3FindInIndex(Parse *pParse, Expr *pX, int *prNotFound){
*/
assert(v);
if( iCol<0 ){
- int iMem = ++pParse->nMem;
int iAddr;
- iAddr = sqlite3VdbeAddOp1(v, OP_If, iMem);
- sqlite3VdbeAddOp2(v, OP_Integer, 1, iMem);
+ iAddr = sqlite3CodeOnce(pParse);
sqlite3OpenTable(pParse, iTab, iDb, pTab, OP_OpenRead);
eType = IN_INDEX_ROWID;
@@ -72733,30 +75541,29 @@ SQLITE_PRIVATE int sqlite3FindInIndex(Parse *pParse, Expr *pX, int *prNotFound){
** comparison is the same as the affinity of the column. If
** it is not, it is not possible to use any index.
*/
- char aff = comparisonAffinity(pX);
- int affinity_ok = (pTab->aCol[iCol].affinity==aff||aff==SQLITE_AFF_NONE);
+ int affinity_ok = sqlite3IndexAffinityOk(pX, pTab->aCol[iCol].affinity);
for(pIdx=pTab->pIndex; pIdx && eType==0 && affinity_ok; pIdx=pIdx->pNext){
if( (pIdx->aiColumn[0]==iCol)
&& sqlite3FindCollSeq(db, ENC(db), pIdx->azColl[0], 0)==pReq
&& (!mustBeUnique || (pIdx->nColumn==1 && pIdx->onError!=OE_None))
){
- int iMem = ++pParse->nMem;
int iAddr;
char *pKey;
pKey = (char *)sqlite3IndexKeyinfo(pParse, pIdx);
- iAddr = sqlite3VdbeAddOp1(v, OP_If, iMem);
- sqlite3VdbeAddOp2(v, OP_Integer, 1, iMem);
+ iAddr = sqlite3CodeOnce(pParse);
sqlite3VdbeAddOp4(v, OP_OpenRead, iTab, pIdx->tnum, iDb,
pKey,P4_KEYINFO_HANDOFF);
VdbeComment((v, "%s", pIdx->zName));
- eType = IN_INDEX_INDEX;
+ assert( IN_INDEX_INDEX_DESC == IN_INDEX_INDEX_ASC+1 );
+ eType = IN_INDEX_INDEX_ASC + pIdx->aSortOrder[0];
sqlite3VdbeJumpHere(v, iAddr);
if( prNotFound && !pTab->aCol[iCol].notNull ){
*prNotFound = ++pParse->nMem;
+ sqlite3VdbeAddOp2(v, OP_Null, 0, *prNotFound);
}
}
}
@@ -72772,6 +75579,7 @@ SQLITE_PRIVATE int sqlite3FindInIndex(Parse *pParse, Expr *pX, int *prNotFound){
eType = IN_INDEX_EPH;
if( prNotFound ){
*prNotFound = rMayHaveNull = ++pParse->nMem;
+ sqlite3VdbeAddOp2(v, OP_Null, 0, *prNotFound);
}else{
testcase( pParse->nQueryLoop>(double)1 );
pParse->nQueryLoop = (double)1;
@@ -72828,7 +75636,7 @@ SQLITE_PRIVATE int sqlite3CodeSubselect(
int rMayHaveNull, /* Register that records whether NULLs exist in RHS */
int isRowid /* If true, LHS of IN operator is a rowid */
){
- int testAddr = 0; /* One-time test address */
+ int testAddr = -1; /* One-time test address */
int rReg = 0; /* Register storing resulting */
Vdbe *v = sqlite3GetVdbe(pParse);
if( NEVER(v==0) ) return 0;
@@ -72844,17 +75652,14 @@ SQLITE_PRIVATE int sqlite3CodeSubselect(
** If all of the above are false, then we can run this code just once
** save the results, and reuse the same result on subsequent invocations.
*/
- if( !ExprHasAnyProperty(pExpr, EP_VarSelect) && !pParse->pTriggerTab ){
- int mem = ++pParse->nMem;
- sqlite3VdbeAddOp1(v, OP_If, mem);
- testAddr = sqlite3VdbeAddOp2(v, OP_Integer, 1, mem);
- assert( testAddr>0 || pParse->db->mallocFailed );
+ if( !ExprHasAnyProperty(pExpr, EP_VarSelect) ){
+ testAddr = sqlite3CodeOnce(pParse);
}
#ifndef SQLITE_OMIT_EXPLAIN
if( pParse->explain==2 ){
char *zMsg = sqlite3MPrintf(
- pParse->db, "EXECUTE %s%s SUBQUERY %d", testAddr?"":"CORRELATED ",
+ pParse->db, "EXECUTE %s%s SUBQUERY %d", testAddr>=0?"":"CORRELATED ",
pExpr->op==TK_IN?"LIST":"SCALAR", pParse->iNextSelectId
);
sqlite3VdbeAddOp4(v, OP_Explain, pParse->iSelectId, 0, 0, zMsg, P4_DYNAMIC);
@@ -72865,6 +75670,7 @@ SQLITE_PRIVATE int sqlite3CodeSubselect(
case TK_IN: {
char affinity; /* Affinity of the LHS of the IN */
KeyInfo keyInfo; /* Keyinfo for the generated table */
+ static u8 sortOrder = 0; /* Fake aSortOrder for keyInfo */
int addr; /* Address of OP_OpenEphemeral instruction */
Expr *pLeft = pExpr->pLeft; /* the LHS of the IN operator */
@@ -72892,6 +75698,7 @@ SQLITE_PRIVATE int sqlite3CodeSubselect(
if( rMayHaveNull==0 ) sqlite3VdbeChangeP5(v, BTREE_UNORDERED);
memset(&keyInfo, 0, sizeof(keyInfo));
keyInfo.nField = 1;
+ keyInfo.aSortOrder = &sortOrder;
if( ExprHasProperty(pExpr, EP_xIsSelect) ){
/* Case 1: expr IN (SELECT ...)
@@ -72904,7 +75711,7 @@ SQLITE_PRIVATE int sqlite3CodeSubselect(
assert( !isRowid );
sqlite3SelectDestInit(&dest, SRT_Set, pExpr->iTable);
- dest.affinity = (u8)affinity;
+ dest.affSdst = (u8)affinity;
assert( (pExpr->iTable&0x0000FFFF)==pExpr->iTable );
pExpr->x.pSelect->iLimit = 0;
if( sqlite3Select(pParse, pExpr->x.pSelect, &dest) ){
@@ -72932,6 +75739,7 @@ SQLITE_PRIVATE int sqlite3CodeSubselect(
affinity = SQLITE_AFF_NONE;
}
keyInfo.aColl[0] = sqlite3ExprCollSeq(pParse, pExpr->pLeft);
+ keyInfo.aSortOrder = &sortOrder;
/* Loop through each expression in <exprlist>. */
r1 = sqlite3GetTempReg(pParse);
@@ -72946,9 +75754,9 @@ SQLITE_PRIVATE int sqlite3CodeSubselect(
** this code only executes once. Because for a non-constant
** expression we need to rerun this code each time.
*/
- if( testAddr && !sqlite3ExprIsConstant(pE2) ){
- sqlite3VdbeChangeToNoop(v, testAddr-1, 2);
- testAddr = 0;
+ if( testAddr>=0 && !sqlite3ExprIsConstant(pE2) ){
+ sqlite3VdbeChangeToNoop(v, testAddr);
+ testAddr = -1;
}
/* Evaluate the expression and insert it into the temp table */
@@ -72997,11 +75805,11 @@ SQLITE_PRIVATE int sqlite3CodeSubselect(
sqlite3SelectDestInit(&dest, 0, ++pParse->nMem);
if( pExpr->op==TK_SELECT ){
dest.eDest = SRT_Mem;
- sqlite3VdbeAddOp2(v, OP_Null, 0, dest.iParm);
+ sqlite3VdbeAddOp2(v, OP_Null, 0, dest.iSDParm);
VdbeComment((v, "Init subquery result"));
}else{
dest.eDest = SRT_Exists;
- sqlite3VdbeAddOp2(v, OP_Integer, 0, dest.iParm);
+ sqlite3VdbeAddOp2(v, OP_Integer, 0, dest.iSDParm);
VdbeComment((v, "Init EXISTS result"));
}
sqlite3ExprDelete(pParse->db, pSel->pLimit);
@@ -73011,14 +75819,14 @@ SQLITE_PRIVATE int sqlite3CodeSubselect(
if( sqlite3Select(pParse, pSel, &dest) ){
return 0;
}
- rReg = dest.iParm;
+ rReg = dest.iSDParm;
ExprSetIrreducible(pExpr);
break;
}
}
- if( testAddr ){
- sqlite3VdbeJumpHere(v, testAddr-1);
+ if( testAddr>=0 ){
+ sqlite3VdbeJumpHere(v, testAddr);
}
sqlite3ExprCachePop(pParse, 1);
@@ -73258,7 +76066,7 @@ SQLITE_PRIVATE void sqlite3ExprCacheStore(Parse *pParse, int iTab, int iCol, int
** for testing only - to verify that SQLite always gets the same answer
** with and without the column cache.
*/
- if( pParse->db->flags & SQLITE_ColumnCache ) return;
+ if( OptimizationDisabled(pParse->db, SQLITE_ColumnCache) ) return;
/* First replace any existing entry.
**
@@ -73267,15 +76075,6 @@ SQLITE_PRIVATE void sqlite3ExprCacheStore(Parse *pParse, int iTab, int iCol, int
*/
#ifndef NDEBUG
for(i=0, p=pParse->aColCache; i<SQLITE_N_COLCACHE; i++, p++){
-#if 0 /* This code wold remove the entry from the cache if it existed */
- if( p->iReg && p->iTable==iTab && p->iColumn==iCol ){
- cacheEntryClear(pParse, p);
- p->iLevel = pParse->iCacheLevel;
- p->iReg = iReg;
- p->lru = pParse->iCacheCnt++;
- return;
- }
-#endif
assert( p->iReg==0 || p->iTable!=iTab || p->iColumn!=iCol );
}
#endif
@@ -73410,7 +76209,8 @@ SQLITE_PRIVATE int sqlite3ExprCodeGetColumn(
Table *pTab, /* Description of the table we are reading from */
int iColumn, /* Index of the table column */
int iTable, /* The cursor pointing to the table */
- int iReg /* Store results here */
+ int iReg, /* Store results here */
+ u8 p5 /* P5 value for OP_Column */
){
Vdbe *v = pParse->pVdbe;
int i;
@@ -73425,7 +76225,11 @@ SQLITE_PRIVATE int sqlite3ExprCodeGetColumn(
}
assert( v!=0 );
sqlite3ExprCodeGetColumnOfTable(v, pTab, iTable, iColumn, iReg);
- sqlite3ExprCacheStore(pParse, iTable, iColumn, iReg);
+ if( p5 ){
+ sqlite3VdbeChangeP5(v, p5);
+ }else{
+ sqlite3ExprCacheStore(pParse, iTable, iColumn, iReg);
+ }
return iReg;
}
@@ -73459,8 +76263,8 @@ SQLITE_PRIVATE void sqlite3ExprCacheAffinityChange(Parse *pParse, int iStart, in
SQLITE_PRIVATE void sqlite3ExprCodeMove(Parse *pParse, int iFrom, int iTo, int nReg){
int i;
struct yColCache *p;
- if( NEVER(iFrom==iTo) ) return;
- sqlite3VdbeAddOp3(pParse->pVdbe, OP_Move, iFrom, iTo, nReg);
+ assert( iFrom>=iTo+nReg || iFrom+nReg<=iTo );
+ sqlite3VdbeAddOp3(pParse->pVdbe, OP_Move, iFrom, iTo, nReg-1);
for(i=0, p=pParse->aColCache; i<SQLITE_N_COLCACHE; i++, p++){
int x = p->iReg;
if( x>=iFrom && x<iFrom+nReg ){
@@ -73469,18 +76273,6 @@ SQLITE_PRIVATE void sqlite3ExprCodeMove(Parse *pParse, int iFrom, int iTo, int n
}
}
-/*
-** Generate code to copy content from registers iFrom...iFrom+nReg-1
-** over to iTo..iTo+nReg-1.
-*/
-SQLITE_PRIVATE void sqlite3ExprCodeCopy(Parse *pParse, int iFrom, int iTo, int nReg){
- int i;
- if( NEVER(iFrom==iTo) ) return;
- for(i=0; i<nReg; i++){
- sqlite3VdbeAddOp2(pParse->pVdbe, OP_Copy, iFrom+i, iTo+i);
- }
-}
-
#if defined(SQLITE_DEBUG) || defined(SQLITE_COVERAGE_TEST)
/*
** Return true if any register in the range iFrom..iTo (inclusive)
@@ -73540,7 +76332,7 @@ SQLITE_PRIVATE int sqlite3ExprCodeTarget(Parse *pParse, Expr *pExpr, int target)
inReg = pCol->iMem;
break;
}else if( pAggInfo->useSortingIdx ){
- sqlite3VdbeAddOp3(v, OP_Column, pAggInfo->sortingIdx,
+ sqlite3VdbeAddOp3(v, OP_Column, pAggInfo->sortingIdxPTab,
pCol->iSorterColumn, target);
break;
}
@@ -73553,7 +76345,8 @@ SQLITE_PRIVATE int sqlite3ExprCodeTarget(Parse *pParse, Expr *pExpr, int target)
inReg = pExpr->iColumn + pParse->ckBase;
}else{
inReg = sqlite3ExprCodeGetColumn(pParse, pExpr->pTab,
- pExpr->iColumn, pExpr->iTable, target);
+ pExpr->iColumn, pExpr->iTable, target,
+ pExpr->op2);
}
break;
}
@@ -73830,6 +76623,25 @@ SQLITE_PRIVATE int sqlite3ExprCodeTarget(Parse *pParse, Expr *pExpr, int target)
if( pFarg ){
r1 = sqlite3GetTempRange(pParse, nFarg);
+
+ /* For length() and typeof() functions with a column argument,
+ ** set the P5 parameter to the OP_Column opcode to OPFLAG_LENGTHARG
+ ** or OPFLAG_TYPEOFARG respectively, to avoid unnecessary data
+ ** loading.
+ */
+ if( (pDef->flags & (SQLITE_FUNC_LENGTH|SQLITE_FUNC_TYPEOF))!=0 ){
+ u8 exprOp;
+ assert( nFarg==1 );
+ assert( pFarg->a[0].pExpr!=0 );
+ exprOp = pFarg->a[0].pExpr->op;
+ if( exprOp==TK_COLUMN || exprOp==TK_AGG_COLUMN ){
+ assert( SQLITE_FUNC_LENGTH==OPFLAG_LENGTHARG );
+ assert( SQLITE_FUNC_TYPEOF==OPFLAG_TYPEOFARG );
+ testcase( pDef->flags==SQLITE_FUNC_LENGTH );
+ pFarg->a[0].pExpr->op2 = pDef->flags;
+ }
+ }
+
sqlite3ExprCachePush(pParse); /* Ticket 2ea2425d34be */
sqlite3ExprCodeExprList(pParse, pFarg, r1, 1);
sqlite3ExprCachePop(pParse, 1); /* Ticket 2ea2425d34be */
@@ -73932,6 +76744,7 @@ SQLITE_PRIVATE int sqlite3ExprCodeTarget(Parse *pParse, Expr *pExpr, int target)
sqlite3ReleaseTempReg(pParse, r4);
break;
}
+ case TK_COLLATE:
case TK_UPLUS: {
inReg = sqlite3ExprCodeTarget(pParse, pExpr->pLeft, target);
break;
@@ -74098,7 +76911,8 @@ SQLITE_PRIVATE int sqlite3ExprCodeTarget(Parse *pParse, Expr *pExpr, int target)
sqlite3VdbeAddOp4(
v, OP_Halt, SQLITE_OK, OE_Ignore, 0, pExpr->u.zToken,0);
}else{
- sqlite3HaltConstraint(pParse, pExpr->affinity, pExpr->u.zToken, 0);
+ sqlite3HaltConstraint(pParse, SQLITE_CONSTRAINT_TRIGGER,
+ pExpr->affinity, pExpr->u.zToken, 0);
}
break;
@@ -74186,6 +77000,279 @@ SQLITE_PRIVATE int sqlite3ExprCodeAndCache(Parse *pParse, Expr *pExpr, int targe
return inReg;
}
+#if defined(SQLITE_ENABLE_TREE_EXPLAIN)
+/*
+** Generate a human-readable explanation of an expression tree.
+*/
+SQLITE_PRIVATE void sqlite3ExplainExpr(Vdbe *pOut, Expr *pExpr){
+ int op; /* The opcode being coded */
+ const char *zBinOp = 0; /* Binary operator */
+ const char *zUniOp = 0; /* Unary operator */
+ if( pExpr==0 ){
+ op = TK_NULL;
+ }else{
+ op = pExpr->op;
+ }
+ switch( op ){
+ case TK_AGG_COLUMN: {
+ sqlite3ExplainPrintf(pOut, "AGG{%d:%d}",
+ pExpr->iTable, pExpr->iColumn);
+ break;
+ }
+ case TK_COLUMN: {
+ if( pExpr->iTable<0 ){
+ /* This only happens when coding check constraints */
+ sqlite3ExplainPrintf(pOut, "COLUMN(%d)", pExpr->iColumn);
+ }else{
+ sqlite3ExplainPrintf(pOut, "{%d:%d}",
+ pExpr->iTable, pExpr->iColumn);
+ }
+ break;
+ }
+ case TK_INTEGER: {
+ if( pExpr->flags & EP_IntValue ){
+ sqlite3ExplainPrintf(pOut, "%d", pExpr->u.iValue);
+ }else{
+ sqlite3ExplainPrintf(pOut, "%s", pExpr->u.zToken);
+ }
+ break;
+ }
+#ifndef SQLITE_OMIT_FLOATING_POINT
+ case TK_FLOAT: {
+ sqlite3ExplainPrintf(pOut,"%s", pExpr->u.zToken);
+ break;
+ }
+#endif
+ case TK_STRING: {
+ sqlite3ExplainPrintf(pOut,"%Q", pExpr->u.zToken);
+ break;
+ }
+ case TK_NULL: {
+ sqlite3ExplainPrintf(pOut,"NULL");
+ break;
+ }
+#ifndef SQLITE_OMIT_BLOB_LITERAL
+ case TK_BLOB: {
+ sqlite3ExplainPrintf(pOut,"%s", pExpr->u.zToken);
+ break;
+ }
+#endif
+ case TK_VARIABLE: {
+ sqlite3ExplainPrintf(pOut,"VARIABLE(%s,%d)",
+ pExpr->u.zToken, pExpr->iColumn);
+ break;
+ }
+ case TK_REGISTER: {
+ sqlite3ExplainPrintf(pOut,"REGISTER(%d)", pExpr->iTable);
+ break;
+ }
+ case TK_AS: {
+ sqlite3ExplainExpr(pOut, pExpr->pLeft);
+ break;
+ }
+#ifndef SQLITE_OMIT_CAST
+ case TK_CAST: {
+ /* Expressions of the form: CAST(pLeft AS token) */
+ const char *zAff = "unk";
+ switch( sqlite3AffinityType(pExpr->u.zToken) ){
+ case SQLITE_AFF_TEXT: zAff = "TEXT"; break;
+ case SQLITE_AFF_NONE: zAff = "NONE"; break;
+ case SQLITE_AFF_NUMERIC: zAff = "NUMERIC"; break;
+ case SQLITE_AFF_INTEGER: zAff = "INTEGER"; break;
+ case SQLITE_AFF_REAL: zAff = "REAL"; break;
+ }
+ sqlite3ExplainPrintf(pOut, "CAST-%s(", zAff);
+ sqlite3ExplainExpr(pOut, pExpr->pLeft);
+ sqlite3ExplainPrintf(pOut, ")");
+ break;
+ }
+#endif /* SQLITE_OMIT_CAST */
+ case TK_LT: zBinOp = "LT"; break;
+ case TK_LE: zBinOp = "LE"; break;
+ case TK_GT: zBinOp = "GT"; break;
+ case TK_GE: zBinOp = "GE"; break;
+ case TK_NE: zBinOp = "NE"; break;
+ case TK_EQ: zBinOp = "EQ"; break;
+ case TK_IS: zBinOp = "IS"; break;
+ case TK_ISNOT: zBinOp = "ISNOT"; break;
+ case TK_AND: zBinOp = "AND"; break;
+ case TK_OR: zBinOp = "OR"; break;
+ case TK_PLUS: zBinOp = "ADD"; break;
+ case TK_STAR: zBinOp = "MUL"; break;
+ case TK_MINUS: zBinOp = "SUB"; break;
+ case TK_REM: zBinOp = "REM"; break;
+ case TK_BITAND: zBinOp = "BITAND"; break;
+ case TK_BITOR: zBinOp = "BITOR"; break;
+ case TK_SLASH: zBinOp = "DIV"; break;
+ case TK_LSHIFT: zBinOp = "LSHIFT"; break;
+ case TK_RSHIFT: zBinOp = "RSHIFT"; break;
+ case TK_CONCAT: zBinOp = "CONCAT"; break;
+
+ case TK_UMINUS: zUniOp = "UMINUS"; break;
+ case TK_UPLUS: zUniOp = "UPLUS"; break;
+ case TK_BITNOT: zUniOp = "BITNOT"; break;
+ case TK_NOT: zUniOp = "NOT"; break;
+ case TK_ISNULL: zUniOp = "ISNULL"; break;
+ case TK_NOTNULL: zUniOp = "NOTNULL"; break;
+
+ case TK_COLLATE: {
+ sqlite3ExplainExpr(pOut, pExpr->pLeft);
+ sqlite3ExplainPrintf(pOut,".COLLATE(%s)",pExpr->u.zToken);
+ break;
+ }
+
+ case TK_AGG_FUNCTION:
+ case TK_CONST_FUNC:
+ case TK_FUNCTION: {
+ ExprList *pFarg; /* List of function arguments */
+ if( ExprHasAnyProperty(pExpr, EP_TokenOnly) ){
+ pFarg = 0;
+ }else{
+ pFarg = pExpr->x.pList;
+ }
+ if( op==TK_AGG_FUNCTION ){
+ sqlite3ExplainPrintf(pOut, "AGG_FUNCTION%d:%s(",
+ pExpr->op2, pExpr->u.zToken);
+ }else{
+ sqlite3ExplainPrintf(pOut, "FUNCTION:%s(", pExpr->u.zToken);
+ }
+ if( pFarg ){
+ sqlite3ExplainExprList(pOut, pFarg);
+ }
+ sqlite3ExplainPrintf(pOut, ")");
+ break;
+ }
+#ifndef SQLITE_OMIT_SUBQUERY
+ case TK_EXISTS: {
+ sqlite3ExplainPrintf(pOut, "EXISTS(");
+ sqlite3ExplainSelect(pOut, pExpr->x.pSelect);
+ sqlite3ExplainPrintf(pOut,")");
+ break;
+ }
+ case TK_SELECT: {
+ sqlite3ExplainPrintf(pOut, "(");
+ sqlite3ExplainSelect(pOut, pExpr->x.pSelect);
+ sqlite3ExplainPrintf(pOut, ")");
+ break;
+ }
+ case TK_IN: {
+ sqlite3ExplainPrintf(pOut, "IN(");
+ sqlite3ExplainExpr(pOut, pExpr->pLeft);
+ sqlite3ExplainPrintf(pOut, ",");
+ if( ExprHasProperty(pExpr, EP_xIsSelect) ){
+ sqlite3ExplainSelect(pOut, pExpr->x.pSelect);
+ }else{
+ sqlite3ExplainExprList(pOut, pExpr->x.pList);
+ }
+ sqlite3ExplainPrintf(pOut, ")");
+ break;
+ }
+#endif /* SQLITE_OMIT_SUBQUERY */
+
+ /*
+ ** x BETWEEN y AND z
+ **
+ ** This is equivalent to
+ **
+ ** x>=y AND x<=z
+ **
+ ** X is stored in pExpr->pLeft.
+ ** Y is stored in pExpr->pList->a[0].pExpr.
+ ** Z is stored in pExpr->pList->a[1].pExpr.
+ */
+ case TK_BETWEEN: {
+ Expr *pX = pExpr->pLeft;
+ Expr *pY = pExpr->x.pList->a[0].pExpr;
+ Expr *pZ = pExpr->x.pList->a[1].pExpr;
+ sqlite3ExplainPrintf(pOut, "BETWEEN(");
+ sqlite3ExplainExpr(pOut, pX);
+ sqlite3ExplainPrintf(pOut, ",");
+ sqlite3ExplainExpr(pOut, pY);
+ sqlite3ExplainPrintf(pOut, ",");
+ sqlite3ExplainExpr(pOut, pZ);
+ sqlite3ExplainPrintf(pOut, ")");
+ break;
+ }
+ case TK_TRIGGER: {
+ /* If the opcode is TK_TRIGGER, then the expression is a reference
+ ** to a column in the new.* or old.* pseudo-tables available to
+ ** trigger programs. In this case Expr.iTable is set to 1 for the
+ ** new.* pseudo-table, or 0 for the old.* pseudo-table. Expr.iColumn
+ ** is set to the column of the pseudo-table to read, or to -1 to
+ ** read the rowid field.
+ */
+ sqlite3ExplainPrintf(pOut, "%s(%d)",
+ pExpr->iTable ? "NEW" : "OLD", pExpr->iColumn);
+ break;
+ }
+ case TK_CASE: {
+ sqlite3ExplainPrintf(pOut, "CASE(");
+ sqlite3ExplainExpr(pOut, pExpr->pLeft);
+ sqlite3ExplainPrintf(pOut, ",");
+ sqlite3ExplainExprList(pOut, pExpr->x.pList);
+ break;
+ }
+#ifndef SQLITE_OMIT_TRIGGER
+ case TK_RAISE: {
+ const char *zType = "unk";
+ switch( pExpr->affinity ){
+ case OE_Rollback: zType = "rollback"; break;
+ case OE_Abort: zType = "abort"; break;
+ case OE_Fail: zType = "fail"; break;
+ case OE_Ignore: zType = "ignore"; break;
+ }
+ sqlite3ExplainPrintf(pOut, "RAISE-%s(%s)", zType, pExpr->u.zToken);
+ break;
+ }
+#endif
+ }
+ if( zBinOp ){
+ sqlite3ExplainPrintf(pOut,"%s(", zBinOp);
+ sqlite3ExplainExpr(pOut, pExpr->pLeft);
+ sqlite3ExplainPrintf(pOut,",");
+ sqlite3ExplainExpr(pOut, pExpr->pRight);
+ sqlite3ExplainPrintf(pOut,")");
+ }else if( zUniOp ){
+ sqlite3ExplainPrintf(pOut,"%s(", zUniOp);
+ sqlite3ExplainExpr(pOut, pExpr->pLeft);
+ sqlite3ExplainPrintf(pOut,")");
+ }
+}
+#endif /* defined(SQLITE_ENABLE_TREE_EXPLAIN) */
+
+#if defined(SQLITE_ENABLE_TREE_EXPLAIN)
+/*
+** Generate a human-readable explanation of an expression list.
+*/
+SQLITE_PRIVATE void sqlite3ExplainExprList(Vdbe *pOut, ExprList *pList){
+ int i;
+ if( pList==0 || pList->nExpr==0 ){
+ sqlite3ExplainPrintf(pOut, "(empty-list)");
+ return;
+ }else if( pList->nExpr==1 ){
+ sqlite3ExplainExpr(pOut, pList->a[0].pExpr);
+ }else{
+ sqlite3ExplainPush(pOut);
+ for(i=0; i<pList->nExpr; i++){
+ sqlite3ExplainPrintf(pOut, "item[%d] = ", i);
+ sqlite3ExplainPush(pOut);
+ sqlite3ExplainExpr(pOut, pList->a[i].pExpr);
+ sqlite3ExplainPop(pOut);
+ if( pList->a[i].zName ){
+ sqlite3ExplainPrintf(pOut, " AS %s", pList->a[i].zName);
+ }
+ if( pList->a[i].bSpanIsTab ){
+ sqlite3ExplainPrintf(pOut, " (%s)", pList->a[i].zSpan);
+ }
+ if( i<pList->nExpr-1 ){
+ sqlite3ExplainNL(pOut);
+ }
+ }
+ sqlite3ExplainPop(pOut);
+ }
+}
+#endif /* SQLITE_DEBUG */
+
/*
** Return TRUE if pExpr is an constant expression that is appropriate
** for factoring out of a loop. Appropriate expressions are:
@@ -74258,6 +77345,9 @@ static int evalConstExpr(Walker *pWalker, Expr *pExpr){
case TK_REGISTER: {
return WRC_Prune;
}
+ case TK_COLLATE: {
+ return WRC_Continue;
+ }
case TK_FUNCTION:
case TK_AGG_FUNCTION:
case TK_CONST_FUNC: {
@@ -74279,9 +77369,11 @@ static int evalConstExpr(Walker *pWalker, Expr *pExpr){
}
if( isAppropriateForFactoring(pExpr) ){
int r1 = ++pParse->nMem;
- int r2;
- r2 = sqlite3ExprCodeTarget(pParse, pExpr, r1);
- if( NEVER(r1!=r2) ) sqlite3ReleaseTempReg(pParse, r1);
+ int r2 = sqlite3ExprCodeTarget(pParse, pExpr, r1);
+ /* If r2!=r1, it means that register r1 is never used. That is harmless
+ ** but suboptimal, so we want to know about the situation to fix it.
+ ** Hence the following assert: */
+ assert( r2==r1 );
pExpr->op2 = pExpr->op;
pExpr->op = TK_REGISTER;
pExpr->iTable = r2;
@@ -74309,7 +77401,7 @@ static int evalConstExpr(Walker *pWalker, Expr *pExpr){
SQLITE_PRIVATE void sqlite3ExprCodeConstants(Parse *pParse, Expr *pExpr){
Walker w;
if( pParse->cookieGoto ) return;
- if( (pParse->db->flags & SQLITE_FactorOutConst)!=0 ) return;
+ if( OptimizationDisabled(pParse->db, SQLITE_FactorOutConst) ) return;
w.xExprCallback = evalConstExpr;
w.xSelectCallback = 0;
w.pParse = pParse;
@@ -74424,7 +77516,7 @@ SQLITE_PRIVATE void sqlite3ExprIfTrue(Parse *pParse, Expr *pExpr, int dest, int
int r1, r2;
assert( jumpIfNull==SQLITE_JUMPIFNULL || jumpIfNull==0 );
- if( NEVER(v==0) ) return; /* Existance of VDBE checked by caller */
+ if( NEVER(v==0) ) return; /* Existence of VDBE checked by caller */
if( NEVER(pExpr==0) ) return; /* No way this can happen */
op = pExpr->op;
switch( op ){
@@ -74544,7 +77636,7 @@ SQLITE_PRIVATE void sqlite3ExprIfFalse(Parse *pParse, Expr *pExpr, int dest, int
int r1, r2;
assert( jumpIfNull==SQLITE_JUMPIFNULL || jumpIfNull==0 );
- if( NEVER(v==0) ) return; /* Existance of VDBE checked by caller */
+ if( NEVER(v==0) ) return; /* Existence of VDBE checked by caller */
if( pExpr==0 ) return;
/* The value of pExpr->op and op are related as follows:
@@ -74698,7 +77790,15 @@ SQLITE_PRIVATE int sqlite3ExprCompare(Expr *pA, Expr *pB){
return 2;
}
if( (pA->flags & EP_Distinct)!=(pB->flags & EP_Distinct) ) return 2;
- if( pA->op!=pB->op ) return 2;
+ if( pA->op!=pB->op ){
+ if( pA->op==TK_COLLATE && sqlite3ExprCompare(pA->pLeft, pB)<2 ){
+ return 1;
+ }
+ if( pB->op==TK_COLLATE && sqlite3ExprCompare(pA, pB->pLeft)<2 ){
+ return 1;
+ }
+ return 2;
+ }
if( sqlite3ExprCompare(pA->pLeft, pB->pLeft) ) return 2;
if( sqlite3ExprCompare(pA->pRight, pB->pRight) ) return 2;
if( sqlite3ExprListCompare(pA->x.pList, pB->x.pList) ) return 2;
@@ -74707,14 +77807,12 @@ SQLITE_PRIVATE int sqlite3ExprCompare(Expr *pA, Expr *pB){
if( !ExprHasProperty(pB, EP_IntValue) || pA->u.iValue!=pB->u.iValue ){
return 2;
}
- }else if( pA->op!=TK_COLUMN && pA->u.zToken ){
+ }else if( pA->op!=TK_COLUMN && ALWAYS(pA->op!=TK_AGG_COLUMN) && pA->u.zToken){
if( ExprHasProperty(pB, EP_IntValue) || NEVER(pB->u.zToken==0) ) return 2;
- if( sqlite3StrICmp(pA->u.zToken,pB->u.zToken)!=0 ){
- return 2;
+ if( strcmp(pA->u.zToken,pB->u.zToken)!=0 ){
+ return pA->op==TK_COLLATE ? 1 : 2;
}
}
- if( (pA->flags & EP_ExpCollate)!=(pB->flags & EP_ExpCollate) ) return 1;
- if( (pA->flags & EP_ExpCollate)!=0 && pA->pColl!=pB->pColl ) return 2;
return 0;
}
@@ -74745,6 +77843,63 @@ SQLITE_PRIVATE int sqlite3ExprListCompare(ExprList *pA, ExprList *pB){
}
/*
+** An instance of the following structure is used by the tree walker
+** to count references to table columns in the arguments of an
+** aggregate function, in order to implement the
+** sqlite3FunctionThisSrc() routine.
+*/
+struct SrcCount {
+ SrcList *pSrc; /* One particular FROM clause in a nested query */
+ int nThis; /* Number of references to columns in pSrcList */
+ int nOther; /* Number of references to columns in other FROM clauses */
+};
+
+/*
+** Count the number of references to columns.
+*/
+static int exprSrcCount(Walker *pWalker, Expr *pExpr){
+ /* The NEVER() on the second term is because sqlite3FunctionUsesThisSrc()
+ ** is always called before sqlite3ExprAnalyzeAggregates() and so the
+ ** TK_COLUMNs have not yet been converted into TK_AGG_COLUMN. If
+ ** sqlite3FunctionUsesThisSrc() is used differently in the future, the
+ ** NEVER() will need to be removed. */
+ if( pExpr->op==TK_COLUMN || NEVER(pExpr->op==TK_AGG_COLUMN) ){
+ int i;
+ struct SrcCount *p = pWalker->u.pSrcCount;
+ SrcList *pSrc = p->pSrc;
+ for(i=0; i<pSrc->nSrc; i++){
+ if( pExpr->iTable==pSrc->a[i].iCursor ) break;
+ }
+ if( i<pSrc->nSrc ){
+ p->nThis++;
+ }else{
+ p->nOther++;
+ }
+ }
+ return WRC_Continue;
+}
+
+/*
+** Determine if any of the arguments to the pExpr Function reference
+** pSrcList. Return true if they do. Also return true if the function
+** has no arguments or has only constant arguments. Return false if pExpr
+** references columns but not columns of tables found in pSrcList.
+*/
+SQLITE_PRIVATE int sqlite3FunctionUsesThisSrc(Expr *pExpr, SrcList *pSrcList){
+ Walker w;
+ struct SrcCount cnt;
+ assert( pExpr->op==TK_AGG_FUNCTION );
+ memset(&w, 0, sizeof(w));
+ w.xExprCallback = exprSrcCount;
+ w.u.pSrcCount = &cnt;
+ cnt.pSrc = pSrcList;
+ cnt.nThis = 0;
+ cnt.nOther = 0;
+ sqlite3WalkExprList(&w, pExpr->x.pList);
+ return cnt.nThis>0 || cnt.nOther==0;
+}
+
+/*
** Add a new element to the pAggInfo->aCol[] array. Return the index of
** the new element. Return a negative number if malloc fails.
*/
@@ -74754,9 +77909,7 @@ static int addAggInfoColumn(sqlite3 *db, AggInfo *pInfo){
db,
pInfo->aCol,
sizeof(pInfo->aCol[0]),
- 3,
&pInfo->nColumn,
- &pInfo->nColumnAlloc,
&i
);
return i;
@@ -74772,9 +77925,7 @@ static int addAggInfoFunc(sqlite3 *db, AggInfo *pInfo){
db,
pInfo->aFunc,
sizeof(pInfo->aFunc[0]),
- 3,
&pInfo->nFunc,
- &pInfo->nFuncAlloc,
&i
);
return i;
@@ -74863,9 +78014,9 @@ static int analyzeAggregate(Walker *pWalker, Expr *pExpr){
return WRC_Prune;
}
case TK_AGG_FUNCTION: {
- /* The pNC->nDepth==0 test causes aggregate functions in subqueries
- ** to be ignored */
- if( pNC->nDepth==0 ){
+ if( (pNC->ncFlags & NC_InAggFunc)==0
+ && pWalker->walkerDepth==pExpr->op2
+ ){
/* Check to see if pExpr is a duplicate of another aggregate
** function that is already in the pAggInfo structure
*/
@@ -74903,33 +78054,31 @@ static int analyzeAggregate(Walker *pWalker, Expr *pExpr){
pExpr->iAgg = (i16)i;
pExpr->pAggInfo = pAggInfo;
return WRC_Prune;
+ }else{
+ return WRC_Continue;
}
}
}
return WRC_Continue;
}
static int analyzeAggregatesInSelect(Walker *pWalker, Select *pSelect){
- NameContext *pNC = pWalker->u.pNC;
- if( pNC->nDepth==0 ){
- pNC->nDepth++;
- sqlite3WalkSelect(pWalker, pSelect);
- pNC->nDepth--;
- return WRC_Prune;
- }else{
- return WRC_Continue;
- }
+ UNUSED_PARAMETER(pWalker);
+ UNUSED_PARAMETER(pSelect);
+ return WRC_Continue;
}
/*
-** Analyze the given expression looking for aggregate functions and
-** for variables that need to be added to the pParse->aAgg[] array.
-** Make additional entries to the pParse->aAgg[] array as necessary.
+** Analyze the pExpr expression looking for aggregate functions and
+** for variables that need to be added to AggInfo object that pNC->pAggInfo
+** points to. Additional entries are made on the AggInfo object as
+** necessary.
**
** This routine should only be called after the expression has been
** analyzed by sqlite3ResolveExprNames().
*/
SQLITE_PRIVATE void sqlite3ExprAnalyzeAggregates(NameContext *pNC, Expr *pExpr){
Walker w;
+ memset(&w, 0, sizeof(w));
w.xExprCallback = analyzeAggregate;
w.xSelectCallback = analyzeAggregatesInSelect;
w.u.pNC = pNC;
@@ -75010,6 +78159,14 @@ SQLITE_PRIVATE void sqlite3ReleaseTempRange(Parse *pParse, int iReg, int nReg){
}
}
+/*
+** Mark all temporary registers as being unavailable for reuse.
+*/
+SQLITE_PRIVATE void sqlite3ClearTempRegCache(Parse *pParse){
+ pParse->nTempReg = 0;
+ pParse->nRangeReg = 0;
+}
+
/************** End of expr.c ************************************************/
/************** Begin file alter.c *******************************************/
/*
@@ -75427,7 +78584,7 @@ SQLITE_PRIVATE void sqlite3AlterRenameTable(
assert( pSrc->nSrc==1 );
assert( sqlite3BtreeHoldsAllMutexes(pParse->db) );
- pTab = sqlite3LocateTable(pParse, 0, pSrc->a[0].zName, pSrc->a[0].zDatabase);
+ pTab = sqlite3LocateTableItem(pParse, 0, &pSrc->a[0]);
if( !pTab ) goto exit_rename_table;
iDb = sqlite3SchemaToIndex(pParse->db, pTab->pSchema);
zDb = db->aDb[iDb].zName;
@@ -75543,7 +78700,7 @@ SQLITE_PRIVATE void sqlite3AlterRenameTable(
"WHEN name LIKE 'sqlite_autoindex%%' AND type='index' THEN "
"'sqlite_autoindex_' || %Q || substr(name,%d+18) "
"ELSE name END "
- "WHERE tbl_name=%Q AND "
+ "WHERE tbl_name=%Q COLLATE nocase AND "
"(type='table' OR type='index' OR type='trigger');",
zDb, SCHEMA_TABLE(iDb), zName, zName, zName,
#ifndef SQLITE_OMIT_TRIGGER
@@ -75677,7 +78834,7 @@ SQLITE_PRIVATE void sqlite3AlterFinishAddColumn(Parse *pParse, Token *pColDef){
** If there is a NOT NULL constraint, then the default value for the
** column must not be NULL.
*/
- if( pCol->isPrimKey ){
+ if( pCol->colFlags & COLFLAG_PRIMKEY ){
sqlite3ErrorMsg(pParse, "Cannot add a PRIMARY KEY column");
return;
}
@@ -75770,7 +78927,7 @@ SQLITE_PRIVATE void sqlite3AlterBeginAddColumn(Parse *pParse, SrcList *pSrc){
assert( pParse->pNewTable==0 );
assert( sqlite3BtreeHoldsAllMutexes(db) );
if( db->mallocFailed ) goto exit_begin_add_column;
- pTab = sqlite3LocateTable(pParse, 0, pSrc->a[0].zName, pSrc->a[0].zDatabase);
+ pTab = sqlite3LocateTableItem(pParse, 0, &pSrc->a[0]);
if( !pTab ) goto exit_begin_add_column;
#ifndef SQLITE_OMIT_VIRTUALTABLE
@@ -75852,22 +79009,124 @@ exit_begin_add_column:
**
*************************************************************************
** This file contains code associated with the ANALYZE command.
+**
+** The ANALYZE command gather statistics about the content of tables
+** and indices. These statistics are made available to the query planner
+** to help it make better decisions about how to perform queries.
+**
+** The following system tables are or have been supported:
+**
+** CREATE TABLE sqlite_stat1(tbl, idx, stat);
+** CREATE TABLE sqlite_stat2(tbl, idx, sampleno, sample);
+** CREATE TABLE sqlite_stat3(tbl, idx, nEq, nLt, nDLt, sample);
+**
+** Additional tables might be added in future releases of SQLite.
+** The sqlite_stat2 table is not created or used unless the SQLite version
+** is between 3.6.18 and 3.7.8, inclusive, and unless SQLite is compiled
+** with SQLITE_ENABLE_STAT2. The sqlite_stat2 table is deprecated.
+** The sqlite_stat2 table is superceded by sqlite_stat3, which is only
+** created and used by SQLite versions 3.7.9 and later and with
+** SQLITE_ENABLE_STAT3 defined. The fucntionality of sqlite_stat3
+** is a superset of sqlite_stat2.
+**
+** Format of sqlite_stat1:
+**
+** There is normally one row per index, with the index identified by the
+** name in the idx column. The tbl column is the name of the table to
+** which the index belongs. In each such row, the stat column will be
+** a string consisting of a list of integers. The first integer in this
+** list is the number of rows in the index and in the table. The second
+** integer is the average number of rows in the index that have the same
+** value in the first column of the index. The third integer is the average
+** number of rows in the index that have the same value for the first two
+** columns. The N-th integer (for N>1) is the average number of rows in
+** the index which have the same value for the first N-1 columns. For
+** a K-column index, there will be K+1 integers in the stat column. If
+** the index is unique, then the last integer will be 1.
+**
+** The list of integers in the stat column can optionally be followed
+** by the keyword "unordered". The "unordered" keyword, if it is present,
+** must be separated from the last integer by a single space. If the
+** "unordered" keyword is present, then the query planner assumes that
+** the index is unordered and will not use the index for a range query.
+**
+** If the sqlite_stat1.idx column is NULL, then the sqlite_stat1.stat
+** column contains a single integer which is the (estimated) number of
+** rows in the table identified by sqlite_stat1.tbl.
+**
+** Format of sqlite_stat2:
+**
+** The sqlite_stat2 is only created and is only used if SQLite is compiled
+** with SQLITE_ENABLE_STAT2 and if the SQLite version number is between
+** 3.6.18 and 3.7.8. The "stat2" table contains additional information
+** about the distribution of keys within an index. The index is identified by
+** the "idx" column and the "tbl" column is the name of the table to which
+** the index belongs. There are usually 10 rows in the sqlite_stat2
+** table for each index.
+**
+** The sqlite_stat2 entries for an index that have sampleno between 0 and 9
+** inclusive are samples of the left-most key value in the index taken at
+** evenly spaced points along the index. Let the number of samples be S
+** (10 in the standard build) and let C be the number of rows in the index.
+** Then the sampled rows are given by:
+**
+** rownumber = (i*C*2 + C)/(S*2)
+**
+** For i between 0 and S-1. Conceptually, the index space is divided into
+** S uniform buckets and the samples are the middle row from each bucket.
+**
+** The format for sqlite_stat2 is recorded here for legacy reference. This
+** version of SQLite does not support sqlite_stat2. It neither reads nor
+** writes the sqlite_stat2 table. This version of SQLite only supports
+** sqlite_stat3.
+**
+** Format for sqlite_stat3:
+**
+** The sqlite_stat3 is an enhancement to sqlite_stat2. A new name is
+** used to avoid compatibility problems.
+**
+** The format of the sqlite_stat3 table is similar to the format of
+** the sqlite_stat2 table. There are multiple entries for each index.
+** The idx column names the index and the tbl column is the table of the
+** index. If the idx and tbl columns are the same, then the sample is
+** of the INTEGER PRIMARY KEY. The sample column is a value taken from
+** the left-most column of the index. The nEq column is the approximate
+** number of entires in the index whose left-most column exactly matches
+** the sample. nLt is the approximate number of entires whose left-most
+** column is less than the sample. The nDLt column is the approximate
+** number of distinct left-most entries in the index that are less than
+** the sample.
+**
+** Future versions of SQLite might change to store a string containing
+** multiple integers values in the nDLt column of sqlite_stat3. The first
+** integer will be the number of prior index entires that are distinct in
+** the left-most column. The second integer will be the number of prior index
+** entries that are distinct in the first two columns. The third integer
+** will be the number of prior index entries that are distinct in the first
+** three columns. And so forth. With that extension, the nDLt field is
+** similar in function to the sqlite_stat1.stat field.
+**
+** There can be an arbitrary number of sqlite_stat3 entries per index.
+** The ANALYZE command will typically generate sqlite_stat3 tables
+** that contain between 10 and 40 samples which are distributed across
+** the key space, though not uniformly, and which include samples with
+** largest possible nEq values.
*/
#ifndef SQLITE_OMIT_ANALYZE
/*
** This routine generates code that opens the sqlite_stat1 table for
** writing with cursor iStatCur. If the library was built with the
-** SQLITE_ENABLE_STAT2 macro defined, then the sqlite_stat2 table is
+** SQLITE_ENABLE_STAT3 macro defined, then the sqlite_stat3 table is
** opened for writing using cursor (iStatCur+1)
**
** If the sqlite_stat1 tables does not previously exist, it is created.
-** Similarly, if the sqlite_stat2 table does not exist and the library
-** is compiled with SQLITE_ENABLE_STAT2 defined, it is created.
+** Similarly, if the sqlite_stat3 table does not exist and the library
+** is compiled with SQLITE_ENABLE_STAT3 defined, it is created.
**
** Argument zWhere may be a pointer to a buffer containing a table name,
** or it may be a NULL pointer. If it is not NULL, then all entries in
-** the sqlite_stat1 and (if applicable) sqlite_stat2 tables associated
+** the sqlite_stat1 and (if applicable) sqlite_stat3 tables associated
** with the named table are deleted. If zWhere==0, then code is generated
** to delete all stat table entries.
*/
@@ -75883,8 +79142,8 @@ static void openStatTable(
const char *zCols;
} aTable[] = {
{ "sqlite_stat1", "tbl,idx,stat" },
-#ifdef SQLITE_ENABLE_STAT2
- { "sqlite_stat2", "tbl,idx,sampleno,sample" },
+#ifdef SQLITE_ENABLE_STAT3
+ { "sqlite_stat3", "tbl,idx,neq,nlt,ndlt,sample" },
#endif
};
@@ -75900,6 +79159,9 @@ static void openStatTable(
assert( sqlite3VdbeDb(v)==db );
pDb = &db->aDb[iDb];
+ /* Create new statistic tables if they do not exist, or clear them
+ ** if they do already exist.
+ */
for(i=0; i<ArraySize(aTable); i++){
const char *zTab = aTable[i].zName;
Table *pStat;
@@ -75912,7 +79174,7 @@ static void openStatTable(
"CREATE TABLE %Q.%s(%s)", pDb->zName, zTab, aTable[i].zCols
);
aRoot[i] = pParse->regRoot;
- aCreateTbl[i] = 1;
+ aCreateTbl[i] = OPFLAG_P2ISREG;
}else{
/* The table already exists. If zWhere is not NULL, delete all entries
** associated with the table zWhere. If zWhere is NULL, delete the
@@ -75930,7 +79192,7 @@ static void openStatTable(
}
}
- /* Open the sqlite_stat[12] tables for writing. */
+ /* Open the sqlite_stat[13] tables for writing. */
for(i=0; i<ArraySize(aTable); i++){
sqlite3VdbeAddOp3(v, OP_OpenWrite, iStatCur+i, aRoot[i], iDb);
sqlite3VdbeChangeP4(v, -1, (char *)3, P4_INT32);
@@ -75939,6 +79201,225 @@ static void openStatTable(
}
/*
+** Recommended number of samples for sqlite_stat3
+*/
+#ifndef SQLITE_STAT3_SAMPLES
+# define SQLITE_STAT3_SAMPLES 24
+#endif
+
+/*
+** Three SQL functions - stat3_init(), stat3_push(), and stat3_pop() -
+** share an instance of the following structure to hold their state
+** information.
+*/
+typedef struct Stat3Accum Stat3Accum;
+struct Stat3Accum {
+ tRowcnt nRow; /* Number of rows in the entire table */
+ tRowcnt nPSample; /* How often to do a periodic sample */
+ int iMin; /* Index of entry with minimum nEq and hash */
+ int mxSample; /* Maximum number of samples to accumulate */
+ int nSample; /* Current number of samples */
+ u32 iPrn; /* Pseudo-random number used for sampling */
+ struct Stat3Sample {
+ i64 iRowid; /* Rowid in main table of the key */
+ tRowcnt nEq; /* sqlite_stat3.nEq */
+ tRowcnt nLt; /* sqlite_stat3.nLt */
+ tRowcnt nDLt; /* sqlite_stat3.nDLt */
+ u8 isPSample; /* True if a periodic sample */
+ u32 iHash; /* Tiebreaker hash */
+ } *a; /* An array of samples */
+};
+
+#ifdef SQLITE_ENABLE_STAT3
+/*
+** Implementation of the stat3_init(C,S) SQL function. The two parameters
+** are the number of rows in the table or index (C) and the number of samples
+** to accumulate (S).
+**
+** This routine allocates the Stat3Accum object.
+**
+** The return value is the Stat3Accum object (P).
+*/
+static void stat3Init(
+ sqlite3_context *context,
+ int argc,
+ sqlite3_value **argv
+){
+ Stat3Accum *p;
+ tRowcnt nRow;
+ int mxSample;
+ int n;
+
+ UNUSED_PARAMETER(argc);
+ nRow = (tRowcnt)sqlite3_value_int64(argv[0]);
+ mxSample = sqlite3_value_int(argv[1]);
+ n = sizeof(*p) + sizeof(p->a[0])*mxSample;
+ p = sqlite3MallocZero( n );
+ if( p==0 ){
+ sqlite3_result_error_nomem(context);
+ return;
+ }
+ p->a = (struct Stat3Sample*)&p[1];
+ p->nRow = nRow;
+ p->mxSample = mxSample;
+ p->nPSample = p->nRow/(mxSample/3+1) + 1;
+ sqlite3_randomness(sizeof(p->iPrn), &p->iPrn);
+ sqlite3_result_blob(context, p, sizeof(p), sqlite3_free);
+}
+static const FuncDef stat3InitFuncdef = {
+ 2, /* nArg */
+ SQLITE_UTF8, /* iPrefEnc */
+ 0, /* flags */
+ 0, /* pUserData */
+ 0, /* pNext */
+ stat3Init, /* xFunc */
+ 0, /* xStep */
+ 0, /* xFinalize */
+ "stat3_init", /* zName */
+ 0, /* pHash */
+ 0 /* pDestructor */
+};
+
+
+/*
+** Implementation of the stat3_push(nEq,nLt,nDLt,rowid,P) SQL function. The
+** arguments describe a single key instance. This routine makes the
+** decision about whether or not to retain this key for the sqlite_stat3
+** table.
+**
+** The return value is NULL.
+*/
+static void stat3Push(
+ sqlite3_context *context,
+ int argc,
+ sqlite3_value **argv
+){
+ Stat3Accum *p = (Stat3Accum*)sqlite3_value_blob(argv[4]);
+ tRowcnt nEq = sqlite3_value_int64(argv[0]);
+ tRowcnt nLt = sqlite3_value_int64(argv[1]);
+ tRowcnt nDLt = sqlite3_value_int64(argv[2]);
+ i64 rowid = sqlite3_value_int64(argv[3]);
+ u8 isPSample = 0;
+ u8 doInsert = 0;
+ int iMin = p->iMin;
+ struct Stat3Sample *pSample;
+ int i;
+ u32 h;
+
+ UNUSED_PARAMETER(context);
+ UNUSED_PARAMETER(argc);
+ if( nEq==0 ) return;
+ h = p->iPrn = p->iPrn*1103515245 + 12345;
+ if( (nLt/p->nPSample)!=((nEq+nLt)/p->nPSample) ){
+ doInsert = isPSample = 1;
+ }else if( p->nSample<p->mxSample ){
+ doInsert = 1;
+ }else{
+ if( nEq>p->a[iMin].nEq || (nEq==p->a[iMin].nEq && h>p->a[iMin].iHash) ){
+ doInsert = 1;
+ }
+ }
+ if( !doInsert ) return;
+ if( p->nSample==p->mxSample ){
+ assert( p->nSample - iMin - 1 >= 0 );
+ memmove(&p->a[iMin], &p->a[iMin+1], sizeof(p->a[0])*(p->nSample-iMin-1));
+ pSample = &p->a[p->nSample-1];
+ }else{
+ pSample = &p->a[p->nSample++];
+ }
+ pSample->iRowid = rowid;
+ pSample->nEq = nEq;
+ pSample->nLt = nLt;
+ pSample->nDLt = nDLt;
+ pSample->iHash = h;
+ pSample->isPSample = isPSample;
+
+ /* Find the new minimum */
+ if( p->nSample==p->mxSample ){
+ pSample = p->a;
+ i = 0;
+ while( pSample->isPSample ){
+ i++;
+ pSample++;
+ assert( i<p->nSample );
+ }
+ nEq = pSample->nEq;
+ h = pSample->iHash;
+ iMin = i;
+ for(i++, pSample++; i<p->nSample; i++, pSample++){
+ if( pSample->isPSample ) continue;
+ if( pSample->nEq<nEq
+ || (pSample->nEq==nEq && pSample->iHash<h)
+ ){
+ iMin = i;
+ nEq = pSample->nEq;
+ h = pSample->iHash;
+ }
+ }
+ p->iMin = iMin;
+ }
+}
+static const FuncDef stat3PushFuncdef = {
+ 5, /* nArg */
+ SQLITE_UTF8, /* iPrefEnc */
+ 0, /* flags */
+ 0, /* pUserData */
+ 0, /* pNext */
+ stat3Push, /* xFunc */
+ 0, /* xStep */
+ 0, /* xFinalize */
+ "stat3_push", /* zName */
+ 0, /* pHash */
+ 0 /* pDestructor */
+};
+
+/*
+** Implementation of the stat3_get(P,N,...) SQL function. This routine is
+** used to query the results. Content is returned for the Nth sqlite_stat3
+** row where N is between 0 and S-1 and S is the number of samples. The
+** value returned depends on the number of arguments.
+**
+** argc==2 result: rowid
+** argc==3 result: nEq
+** argc==4 result: nLt
+** argc==5 result: nDLt
+*/
+static void stat3Get(
+ sqlite3_context *context,
+ int argc,
+ sqlite3_value **argv
+){
+ int n = sqlite3_value_int(argv[1]);
+ Stat3Accum *p = (Stat3Accum*)sqlite3_value_blob(argv[0]);
+
+ assert( p!=0 );
+ if( p->nSample<=n ) return;
+ switch( argc ){
+ case 2: sqlite3_result_int64(context, p->a[n].iRowid); break;
+ case 3: sqlite3_result_int64(context, p->a[n].nEq); break;
+ case 4: sqlite3_result_int64(context, p->a[n].nLt); break;
+ default: sqlite3_result_int64(context, p->a[n].nDLt); break;
+ }
+}
+static const FuncDef stat3GetFuncdef = {
+ -1, /* nArg */
+ SQLITE_UTF8, /* iPrefEnc */
+ 0, /* flags */
+ 0, /* pUserData */
+ 0, /* pNext */
+ stat3Get, /* xFunc */
+ 0, /* xStep */
+ 0, /* xFinalize */
+ "stat3_get", /* zName */
+ 0, /* pHash */
+ 0 /* pDestructor */
+};
+#endif /* SQLITE_ENABLE_STAT3 */
+
+
+
+
+/*
** Generate code to do an analysis of all indices associated with
** a single table.
*/
@@ -75960,20 +79441,27 @@ static void analyzeOneTable(
int iDb; /* Index of database containing pTab */
int regTabname = iMem++; /* Register containing table name */
int regIdxname = iMem++; /* Register containing index name */
- int regSampleno = iMem++; /* Register containing next sample number */
- int regCol = iMem++; /* Content of a column analyzed table */
+ int regStat1 = iMem++; /* The stat column of sqlite_stat1 */
+#ifdef SQLITE_ENABLE_STAT3
+ int regNumEq = regStat1; /* Number of instances. Same as regStat1 */
+ int regNumLt = iMem++; /* Number of keys less than regSample */
+ int regNumDLt = iMem++; /* Number of distinct keys less than regSample */
+ int regSample = iMem++; /* The next sample value */
+ int regRowid = regSample; /* Rowid of a sample */
+ int regAccum = iMem++; /* Register to hold Stat3Accum object */
+ int regLoop = iMem++; /* Loop counter */
+ int regCount = iMem++; /* Number of rows in the table or index */
+ int regTemp1 = iMem++; /* Intermediate register */
+ int regTemp2 = iMem++; /* Intermediate register */
+ int once = 1; /* One-time initialization */
+ int shortJump = 0; /* Instruction address */
+ int iTabCur = pParse->nTab++; /* Table cursor */
+#endif
+ int regCol = iMem++; /* Content of a column in analyzed table */
int regRec = iMem++; /* Register holding completed record */
int regTemp = iMem++; /* Temporary use register */
- int regRowid = iMem++; /* Rowid for the inserted record */
+ int regNewRowid = iMem++; /* Rowid for the inserted record */
-#ifdef SQLITE_ENABLE_STAT2
- int addr = 0; /* Instruction address */
- int regTemp2 = iMem++; /* Temporary use register */
- int regSamplerecno = iMem++; /* Index of next sample to record */
- int regRecno = iMem++; /* Current sample index */
- int regLast = iMem++; /* Index of last sample to record */
- int regFirst = iMem++; /* Index of first sample to record */
-#endif
v = sqlite3GetVdbe(pParse);
if( v==0 || NEVER(pTab==0) ){
@@ -75983,7 +79471,7 @@ static void analyzeOneTable(
/* Do not gather statistics on views or virtual tables */
return;
}
- if( memcmp(pTab->zName, "sqlite_", 7)==0 ){
+ if( sqlite3_strnicmp(pTab->zName, "sqlite_", 7)==0 ){
/* Do not gather statistics on system tables */
return;
}
@@ -76006,9 +79494,14 @@ static void analyzeOneTable(
for(pIdx=pTab->pIndex; pIdx; pIdx=pIdx->pNext){
int nCol;
KeyInfo *pKey;
+ int addrIfNot = 0; /* address of OP_IfNot */
+ int *aChngAddr; /* Array of jump instruction addresses */
if( pOnlyIdx && pOnlyIdx!=pIdx ) continue;
+ VdbeNoopComment((v, "Begin analysis of %s", pIdx->zName));
nCol = pIdx->nColumn;
+ aChngAddr = sqlite3DbMallocRaw(db, sizeof(int)*nCol);
+ if( aChngAddr==0 ) continue;
pKey = sqlite3IndexKeyinfo(pParse, pIdx);
if( iMem+1+(nCol*2)>pParse->nMem ){
pParse->nMem = iMem+1+(nCol*2);
@@ -76023,31 +79516,21 @@ static void analyzeOneTable(
/* Populate the register containing the index name. */
sqlite3VdbeAddOp4(v, OP_String8, 0, regIdxname, 0, pIdx->zName, 0);
-#ifdef SQLITE_ENABLE_STAT2
-
- /* If this iteration of the loop is generating code to analyze the
- ** first index in the pTab->pIndex list, then register regLast has
- ** not been populated. In this case populate it now. */
- if( pTab->pIndex==pIdx ){
- sqlite3VdbeAddOp2(v, OP_Integer, SQLITE_INDEX_SAMPLES, regSamplerecno);
- sqlite3VdbeAddOp2(v, OP_Integer, SQLITE_INDEX_SAMPLES*2-1, regTemp);
- sqlite3VdbeAddOp2(v, OP_Integer, SQLITE_INDEX_SAMPLES*2, regTemp2);
-
- sqlite3VdbeAddOp2(v, OP_Count, iIdxCur, regLast);
- sqlite3VdbeAddOp2(v, OP_Null, 0, regFirst);
- addr = sqlite3VdbeAddOp3(v, OP_Lt, regSamplerecno, 0, regLast);
- sqlite3VdbeAddOp3(v, OP_Divide, regTemp2, regLast, regFirst);
- sqlite3VdbeAddOp3(v, OP_Multiply, regLast, regTemp, regLast);
- sqlite3VdbeAddOp2(v, OP_AddImm, regLast, SQLITE_INDEX_SAMPLES*2-2);
- sqlite3VdbeAddOp3(v, OP_Divide, regTemp2, regLast, regLast);
- sqlite3VdbeJumpHere(v, addr);
- }
-
- /* Zero the regSampleno and regRecno registers. */
- sqlite3VdbeAddOp2(v, OP_Integer, 0, regSampleno);
- sqlite3VdbeAddOp2(v, OP_Integer, 0, regRecno);
- sqlite3VdbeAddOp2(v, OP_Copy, regFirst, regSamplerecno);
-#endif
+#ifdef SQLITE_ENABLE_STAT3
+ if( once ){
+ once = 0;
+ sqlite3OpenTable(pParse, iTabCur, iDb, pTab, OP_OpenRead);
+ }
+ sqlite3VdbeAddOp2(v, OP_Count, iIdxCur, regCount);
+ sqlite3VdbeAddOp2(v, OP_Integer, SQLITE_STAT3_SAMPLES, regTemp1);
+ sqlite3VdbeAddOp2(v, OP_Integer, 0, regNumEq);
+ sqlite3VdbeAddOp2(v, OP_Integer, 0, regNumLt);
+ sqlite3VdbeAddOp2(v, OP_Integer, -1, regNumDLt);
+ sqlite3VdbeAddOp3(v, OP_Null, 0, regSample, regAccum);
+ sqlite3VdbeAddOp4(v, OP_Function, 1, regCount, regAccum,
+ (char*)&stat3InitFuncdef, P4_FUNCDEF);
+ sqlite3VdbeChangeP5(v, 2);
+#endif /* SQLITE_ENABLE_STAT3 */
/* The block of memory cells initialized here is used as follows.
**
@@ -76077,75 +79560,83 @@ static void analyzeOneTable(
endOfLoop = sqlite3VdbeMakeLabel(v);
sqlite3VdbeAddOp2(v, OP_Rewind, iIdxCur, endOfLoop);
topOfLoop = sqlite3VdbeCurrentAddr(v);
- sqlite3VdbeAddOp2(v, OP_AddImm, iMem, 1);
+ sqlite3VdbeAddOp2(v, OP_AddImm, iMem, 1); /* Increment row counter */
for(i=0; i<nCol; i++){
CollSeq *pColl;
sqlite3VdbeAddOp3(v, OP_Column, iIdxCur, i, regCol);
if( i==0 ){
-#ifdef SQLITE_ENABLE_STAT2
- /* Check if the record that cursor iIdxCur points to contains a
- ** value that should be stored in the sqlite_stat2 table. If so,
- ** store it. */
- int ne = sqlite3VdbeAddOp3(v, OP_Ne, regRecno, 0, regSamplerecno);
- assert( regTabname+1==regIdxname
- && regTabname+2==regSampleno
- && regTabname+3==regCol
- );
- sqlite3VdbeChangeP5(v, SQLITE_JUMPIFNULL);
- sqlite3VdbeAddOp4(v, OP_MakeRecord, regTabname, 4, regRec, "aaab", 0);
- sqlite3VdbeAddOp2(v, OP_NewRowid, iStatCur+1, regRowid);
- sqlite3VdbeAddOp3(v, OP_Insert, iStatCur+1, regRec, regRowid);
-
- /* Calculate new values for regSamplerecno and regSampleno.
- **
- ** sampleno = sampleno + 1
- ** samplerecno = samplerecno+(remaining records)/(remaining samples)
- */
- sqlite3VdbeAddOp2(v, OP_AddImm, regSampleno, 1);
- sqlite3VdbeAddOp3(v, OP_Subtract, regRecno, regLast, regTemp);
- sqlite3VdbeAddOp2(v, OP_AddImm, regTemp, -1);
- sqlite3VdbeAddOp2(v, OP_Integer, SQLITE_INDEX_SAMPLES, regTemp2);
- sqlite3VdbeAddOp3(v, OP_Subtract, regSampleno, regTemp2, regTemp2);
- sqlite3VdbeAddOp3(v, OP_Divide, regTemp2, regTemp, regTemp);
- sqlite3VdbeAddOp3(v, OP_Add, regSamplerecno, regTemp, regSamplerecno);
-
- sqlite3VdbeJumpHere(v, ne);
- sqlite3VdbeAddOp2(v, OP_AddImm, regRecno, 1);
-#endif
-
/* Always record the very first row */
- sqlite3VdbeAddOp1(v, OP_IfNot, iMem+1);
+ addrIfNot = sqlite3VdbeAddOp1(v, OP_IfNot, iMem+1);
}
assert( pIdx->azColl!=0 );
assert( pIdx->azColl[i]!=0 );
pColl = sqlite3LocateCollSeq(pParse, pIdx->azColl[i]);
- sqlite3VdbeAddOp4(v, OP_Ne, regCol, 0, iMem+nCol+i+1,
- (char*)pColl, P4_COLLSEQ);
+ aChngAddr[i] = sqlite3VdbeAddOp4(v, OP_Ne, regCol, 0, iMem+nCol+i+1,
+ (char*)pColl, P4_COLLSEQ);
sqlite3VdbeChangeP5(v, SQLITE_NULLEQ);
- }
- if( db->mallocFailed ){
- /* If a malloc failure has occurred, then the result of the expression
- ** passed as the second argument to the call to sqlite3VdbeJumpHere()
- ** below may be negative. Which causes an assert() to fail (or an
- ** out-of-bounds write if SQLITE_DEBUG is not defined). */
- return;
+ VdbeComment((v, "jump if column %d changed", i));
+#ifdef SQLITE_ENABLE_STAT3
+ if( i==0 ){
+ sqlite3VdbeAddOp2(v, OP_AddImm, regNumEq, 1);
+ VdbeComment((v, "incr repeat count"));
+ }
+#endif
}
sqlite3VdbeAddOp2(v, OP_Goto, 0, endOfLoop);
for(i=0; i<nCol; i++){
- int addr2 = sqlite3VdbeCurrentAddr(v) - (nCol*2);
+ sqlite3VdbeJumpHere(v, aChngAddr[i]); /* Set jump dest for the OP_Ne */
if( i==0 ){
- sqlite3VdbeJumpHere(v, addr2-1); /* Set jump dest for the OP_IfNot */
+ sqlite3VdbeJumpHere(v, addrIfNot); /* Jump dest for OP_IfNot */
+#ifdef SQLITE_ENABLE_STAT3
+ sqlite3VdbeAddOp4(v, OP_Function, 1, regNumEq, regTemp2,
+ (char*)&stat3PushFuncdef, P4_FUNCDEF);
+ sqlite3VdbeChangeP5(v, 5);
+ sqlite3VdbeAddOp3(v, OP_Column, iIdxCur, pIdx->nColumn, regRowid);
+ sqlite3VdbeAddOp3(v, OP_Add, regNumEq, regNumLt, regNumLt);
+ sqlite3VdbeAddOp2(v, OP_AddImm, regNumDLt, 1);
+ sqlite3VdbeAddOp2(v, OP_Integer, 1, regNumEq);
+#endif
}
- sqlite3VdbeJumpHere(v, addr2); /* Set jump dest for the OP_Ne */
sqlite3VdbeAddOp2(v, OP_AddImm, iMem+i+1, 1);
sqlite3VdbeAddOp3(v, OP_Column, iIdxCur, i, iMem+nCol+i+1);
}
+ sqlite3DbFree(db, aChngAddr);
- /* End of the analysis loop. */
+ /* Always jump here after updating the iMem+1...iMem+1+nCol counters */
sqlite3VdbeResolveLabel(v, endOfLoop);
+
sqlite3VdbeAddOp2(v, OP_Next, iIdxCur, topOfLoop);
sqlite3VdbeAddOp1(v, OP_Close, iIdxCur);
+#ifdef SQLITE_ENABLE_STAT3
+ sqlite3VdbeAddOp4(v, OP_Function, 1, regNumEq, regTemp2,
+ (char*)&stat3PushFuncdef, P4_FUNCDEF);
+ sqlite3VdbeChangeP5(v, 5);
+ sqlite3VdbeAddOp2(v, OP_Integer, -1, regLoop);
+ shortJump =
+ sqlite3VdbeAddOp2(v, OP_AddImm, regLoop, 1);
+ sqlite3VdbeAddOp4(v, OP_Function, 1, regAccum, regTemp1,
+ (char*)&stat3GetFuncdef, P4_FUNCDEF);
+ sqlite3VdbeChangeP5(v, 2);
+ sqlite3VdbeAddOp1(v, OP_IsNull, regTemp1);
+ sqlite3VdbeAddOp3(v, OP_NotExists, iTabCur, shortJump, regTemp1);
+ sqlite3VdbeAddOp3(v, OP_Column, iTabCur, pIdx->aiColumn[0], regSample);
+ sqlite3ColumnDefault(v, pTab, pIdx->aiColumn[0], regSample);
+ sqlite3VdbeAddOp4(v, OP_Function, 1, regAccum, regNumEq,
+ (char*)&stat3GetFuncdef, P4_FUNCDEF);
+ sqlite3VdbeChangeP5(v, 3);
+ sqlite3VdbeAddOp4(v, OP_Function, 1, regAccum, regNumLt,
+ (char*)&stat3GetFuncdef, P4_FUNCDEF);
+ sqlite3VdbeChangeP5(v, 4);
+ sqlite3VdbeAddOp4(v, OP_Function, 1, regAccum, regNumDLt,
+ (char*)&stat3GetFuncdef, P4_FUNCDEF);
+ sqlite3VdbeChangeP5(v, 5);
+ sqlite3VdbeAddOp4(v, OP_MakeRecord, regTabname, 6, regRec, "bbbbbb", 0);
+ sqlite3VdbeAddOp2(v, OP_NewRowid, iStatCur+1, regNewRowid);
+ sqlite3VdbeAddOp3(v, OP_Insert, iStatCur+1, regRec, regNewRowid);
+ sqlite3VdbeAddOp2(v, OP_Goto, 0, shortJump);
+ sqlite3VdbeJumpHere(v, shortJump+2);
+#endif
/* Store the results in sqlite_stat1.
**
@@ -76165,22 +79656,22 @@ static void analyzeOneTable(
** If K>0 then it is always the case the D>0 so division by zero
** is never possible.
*/
- sqlite3VdbeAddOp2(v, OP_SCopy, iMem, regSampleno);
+ sqlite3VdbeAddOp2(v, OP_SCopy, iMem, regStat1);
if( jZeroRows<0 ){
jZeroRows = sqlite3VdbeAddOp1(v, OP_IfNot, iMem);
}
for(i=0; i<nCol; i++){
sqlite3VdbeAddOp4(v, OP_String8, 0, regTemp, 0, " ", 0);
- sqlite3VdbeAddOp3(v, OP_Concat, regTemp, regSampleno, regSampleno);
+ sqlite3VdbeAddOp3(v, OP_Concat, regTemp, regStat1, regStat1);
sqlite3VdbeAddOp3(v, OP_Add, iMem, iMem+i+1, regTemp);
sqlite3VdbeAddOp2(v, OP_AddImm, regTemp, -1);
sqlite3VdbeAddOp3(v, OP_Divide, iMem+i+1, regTemp, regTemp);
sqlite3VdbeAddOp1(v, OP_ToInt, regTemp);
- sqlite3VdbeAddOp3(v, OP_Concat, regTemp, regSampleno, regSampleno);
+ sqlite3VdbeAddOp3(v, OP_Concat, regTemp, regStat1, regStat1);
}
sqlite3VdbeAddOp4(v, OP_MakeRecord, regTabname, 3, regRec, "aaa", 0);
- sqlite3VdbeAddOp2(v, OP_NewRowid, iStatCur, regRowid);
- sqlite3VdbeAddOp3(v, OP_Insert, iStatCur, regRec, regRowid);
+ sqlite3VdbeAddOp2(v, OP_NewRowid, iStatCur, regNewRowid);
+ sqlite3VdbeAddOp3(v, OP_Insert, iStatCur, regRec, regNewRowid);
sqlite3VdbeChangeP5(v, OPFLAG_APPEND);
}
@@ -76190,22 +79681,23 @@ static void analyzeOneTable(
if( pTab->pIndex==0 ){
sqlite3VdbeAddOp3(v, OP_OpenRead, iIdxCur, pTab->tnum, iDb);
VdbeComment((v, "%s", pTab->zName));
- sqlite3VdbeAddOp2(v, OP_Count, iIdxCur, regSampleno);
+ sqlite3VdbeAddOp2(v, OP_Count, iIdxCur, regStat1);
sqlite3VdbeAddOp1(v, OP_Close, iIdxCur);
- jZeroRows = sqlite3VdbeAddOp1(v, OP_IfNot, regSampleno);
+ jZeroRows = sqlite3VdbeAddOp1(v, OP_IfNot, regStat1);
}else{
sqlite3VdbeJumpHere(v, jZeroRows);
jZeroRows = sqlite3VdbeAddOp0(v, OP_Goto);
}
sqlite3VdbeAddOp2(v, OP_Null, 0, regIdxname);
sqlite3VdbeAddOp4(v, OP_MakeRecord, regTabname, 3, regRec, "aaa", 0);
- sqlite3VdbeAddOp2(v, OP_NewRowid, iStatCur, regRowid);
- sqlite3VdbeAddOp3(v, OP_Insert, iStatCur, regRec, regRowid);
+ sqlite3VdbeAddOp2(v, OP_NewRowid, iStatCur, regNewRowid);
+ sqlite3VdbeAddOp3(v, OP_Insert, iStatCur, regRec, regNewRowid);
sqlite3VdbeChangeP5(v, OPFLAG_APPEND);
if( pParse->nMem<regRec ) pParse->nMem = regRec;
sqlite3VdbeJumpHere(v, jZeroRows);
}
+
/*
** Generate code that will cause the most recent index analysis to
** be loaded into internal hash tables where is can be used.
@@ -76229,7 +79721,7 @@ static void analyzeDatabase(Parse *pParse, int iDb){
sqlite3BeginWriteOperation(pParse, 0, iDb);
iStatCur = pParse->nTab;
- pParse->nTab += 2;
+ pParse->nTab += 3;
openStatTable(pParse, iDb, iStatCur, 0, 0);
iMem = pParse->nMem+1;
assert( sqlite3SchemaMutexHeld(db, iDb, 0) );
@@ -76254,7 +79746,7 @@ static void analyzeTable(Parse *pParse, Table *pTab, Index *pOnlyIdx){
iDb = sqlite3SchemaToIndex(pParse->db, pTab->pSchema);
sqlite3BeginWriteOperation(pParse, 0, iDb);
iStatCur = pParse->nTab;
- pParse->nTab += 2;
+ pParse->nTab += 3;
if( pOnlyIdx ){
openStatTable(pParse, iDb, iStatCur, pOnlyIdx->zName, "idx");
}else{
@@ -76359,7 +79851,7 @@ static int analysisLoader(void *pData, int argc, char **argv, char **NotUsed){
Index *pIndex;
Table *pTable;
int i, c, n;
- unsigned int v;
+ tRowcnt v;
const char *z;
assert( argc==3 );
@@ -76389,7 +79881,7 @@ static int analysisLoader(void *pData, int argc, char **argv, char **NotUsed){
if( pIndex==0 ) break;
pIndex->aiRowEst[i] = v;
if( *z==' ' ) z++;
- if( memcmp(z, "unordered", 10)==0 ){
+ if( strcmp(z, "unordered")==0 ){
pIndex->bUnordered = 1;
break;
}
@@ -76402,10 +79894,10 @@ static int analysisLoader(void *pData, int argc, char **argv, char **NotUsed){
** and its contents.
*/
SQLITE_PRIVATE void sqlite3DeleteIndexSamples(sqlite3 *db, Index *pIdx){
-#ifdef SQLITE_ENABLE_STAT2
+#ifdef SQLITE_ENABLE_STAT3
if( pIdx->aSample ){
int j;
- for(j=0; j<SQLITE_INDEX_SAMPLES; j++){
+ for(j=0; j<pIdx->nSample; j++){
IndexSample *p = &pIdx->aSample[j];
if( p->eType==SQLITE_TEXT || p->eType==SQLITE_BLOB ){
sqlite3DbFree(db, p->u.z);
@@ -76413,25 +79905,158 @@ SQLITE_PRIVATE void sqlite3DeleteIndexSamples(sqlite3 *db, Index *pIdx){
}
sqlite3DbFree(db, pIdx->aSample);
}
+ if( db && db->pnBytesFreed==0 ){
+ pIdx->nSample = 0;
+ pIdx->aSample = 0;
+ }
#else
UNUSED_PARAMETER(db);
UNUSED_PARAMETER(pIdx);
#endif
}
+#ifdef SQLITE_ENABLE_STAT3
/*
-** Load the content of the sqlite_stat1 and sqlite_stat2 tables. The
+** Load content from the sqlite_stat3 table into the Index.aSample[]
+** arrays of all indices.
+*/
+static int loadStat3(sqlite3 *db, const char *zDb){
+ int rc; /* Result codes from subroutines */
+ sqlite3_stmt *pStmt = 0; /* An SQL statement being run */
+ char *zSql; /* Text of the SQL statement */
+ Index *pPrevIdx = 0; /* Previous index in the loop */
+ int idx = 0; /* slot in pIdx->aSample[] for next sample */
+ int eType; /* Datatype of a sample */
+ IndexSample *pSample; /* A slot in pIdx->aSample[] */
+
+ assert( db->lookaside.bEnabled==0 );
+ if( !sqlite3FindTable(db, "sqlite_stat3", zDb) ){
+ return SQLITE_OK;
+ }
+
+ zSql = sqlite3MPrintf(db,
+ "SELECT idx,count(*) FROM %Q.sqlite_stat3"
+ " GROUP BY idx", zDb);
+ if( !zSql ){
+ return SQLITE_NOMEM;
+ }
+ rc = sqlite3_prepare(db, zSql, -1, &pStmt, 0);
+ sqlite3DbFree(db, zSql);
+ if( rc ) return rc;
+
+ while( sqlite3_step(pStmt)==SQLITE_ROW ){
+ char *zIndex; /* Index name */
+ Index *pIdx; /* Pointer to the index object */
+ int nSample; /* Number of samples */
+
+ zIndex = (char *)sqlite3_column_text(pStmt, 0);
+ if( zIndex==0 ) continue;
+ nSample = sqlite3_column_int(pStmt, 1);
+ pIdx = sqlite3FindIndex(db, zIndex, zDb);
+ if( pIdx==0 ) continue;
+ assert( pIdx->nSample==0 );
+ pIdx->nSample = nSample;
+ pIdx->aSample = sqlite3DbMallocZero(db, nSample*sizeof(IndexSample));
+ pIdx->avgEq = pIdx->aiRowEst[1];
+ if( pIdx->aSample==0 ){
+ db->mallocFailed = 1;
+ sqlite3_finalize(pStmt);
+ return SQLITE_NOMEM;
+ }
+ }
+ rc = sqlite3_finalize(pStmt);
+ if( rc ) return rc;
+
+ zSql = sqlite3MPrintf(db,
+ "SELECT idx,neq,nlt,ndlt,sample FROM %Q.sqlite_stat3", zDb);
+ if( !zSql ){
+ return SQLITE_NOMEM;
+ }
+ rc = sqlite3_prepare(db, zSql, -1, &pStmt, 0);
+ sqlite3DbFree(db, zSql);
+ if( rc ) return rc;
+
+ while( sqlite3_step(pStmt)==SQLITE_ROW ){
+ char *zIndex; /* Index name */
+ Index *pIdx; /* Pointer to the index object */
+ int i; /* Loop counter */
+ tRowcnt sumEq; /* Sum of the nEq values */
+
+ zIndex = (char *)sqlite3_column_text(pStmt, 0);
+ if( zIndex==0 ) continue;
+ pIdx = sqlite3FindIndex(db, zIndex, zDb);
+ if( pIdx==0 ) continue;
+ if( pIdx==pPrevIdx ){
+ idx++;
+ }else{
+ pPrevIdx = pIdx;
+ idx = 0;
+ }
+ assert( idx<pIdx->nSample );
+ pSample = &pIdx->aSample[idx];
+ pSample->nEq = (tRowcnt)sqlite3_column_int64(pStmt, 1);
+ pSample->nLt = (tRowcnt)sqlite3_column_int64(pStmt, 2);
+ pSample->nDLt = (tRowcnt)sqlite3_column_int64(pStmt, 3);
+ if( idx==pIdx->nSample-1 ){
+ if( pSample->nDLt>0 ){
+ for(i=0, sumEq=0; i<=idx-1; i++) sumEq += pIdx->aSample[i].nEq;
+ pIdx->avgEq = (pSample->nLt - sumEq)/pSample->nDLt;
+ }
+ if( pIdx->avgEq<=0 ) pIdx->avgEq = 1;
+ }
+ eType = sqlite3_column_type(pStmt, 4);
+ pSample->eType = (u8)eType;
+ switch( eType ){
+ case SQLITE_INTEGER: {
+ pSample->u.i = sqlite3_column_int64(pStmt, 4);
+ break;
+ }
+ case SQLITE_FLOAT: {
+ pSample->u.r = sqlite3_column_double(pStmt, 4);
+ break;
+ }
+ case SQLITE_NULL: {
+ break;
+ }
+ default: assert( eType==SQLITE_TEXT || eType==SQLITE_BLOB ); {
+ const char *z = (const char *)(
+ (eType==SQLITE_BLOB) ?
+ sqlite3_column_blob(pStmt, 4):
+ sqlite3_column_text(pStmt, 4)
+ );
+ int n = z ? sqlite3_column_bytes(pStmt, 4) : 0;
+ pSample->nByte = n;
+ if( n < 1){
+ pSample->u.z = 0;
+ }else{
+ pSample->u.z = sqlite3DbMallocRaw(db, n);
+ if( pSample->u.z==0 ){
+ db->mallocFailed = 1;
+ sqlite3_finalize(pStmt);
+ return SQLITE_NOMEM;
+ }
+ memcpy(pSample->u.z, z, n);
+ }
+ }
+ }
+ }
+ return sqlite3_finalize(pStmt);
+}
+#endif /* SQLITE_ENABLE_STAT3 */
+
+/*
+** Load the content of the sqlite_stat1 and sqlite_stat3 tables. The
** contents of sqlite_stat1 are used to populate the Index.aiRowEst[]
-** arrays. The contents of sqlite_stat2 are used to populate the
+** arrays. The contents of sqlite_stat3 are used to populate the
** Index.aSample[] arrays.
**
** If the sqlite_stat1 table is not present in the database, SQLITE_ERROR
-** is returned. In this case, even if SQLITE_ENABLE_STAT2 was defined
-** during compilation and the sqlite_stat2 table is present, no data is
+** is returned. In this case, even if SQLITE_ENABLE_STAT3 was defined
+** during compilation and the sqlite_stat3 table is present, no data is
** read from it.
**
-** If SQLITE_ENABLE_STAT2 was defined during compilation and the
-** sqlite_stat2 table is not present in the database, SQLITE_ERROR is
+** If SQLITE_ENABLE_STAT3 was defined during compilation and the
+** sqlite_stat3 table is not present in the database, SQLITE_ERROR is
** returned. However, in this case, data is read from the sqlite_stat1
** table (if it is present) before returning.
**
@@ -76453,8 +80078,10 @@ SQLITE_PRIVATE int sqlite3AnalysisLoad(sqlite3 *db, int iDb){
for(i=sqliteHashFirst(&db->aDb[iDb].pSchema->idxHash);i;i=sqliteHashNext(i)){
Index *pIdx = sqliteHashData(i);
sqlite3DefaultRowEst(pIdx);
+#ifdef SQLITE_ENABLE_STAT3
sqlite3DeleteIndexSamples(db, pIdx);
pIdx->aSample = 0;
+#endif
}
/* Check to make sure the sqlite_stat1 table exists */
@@ -76466,7 +80093,7 @@ SQLITE_PRIVATE int sqlite3AnalysisLoad(sqlite3 *db, int iDb){
/* Load new statistics out of the sqlite_stat1 table */
zSql = sqlite3MPrintf(db,
- "SELECT tbl, idx, stat FROM %Q.sqlite_stat1", sInfo.zDatabase);
+ "SELECT tbl,idx,stat FROM %Q.sqlite_stat1", sInfo.zDatabase);
if( zSql==0 ){
rc = SQLITE_NOMEM;
}else{
@@ -76475,78 +80102,13 @@ SQLITE_PRIVATE int sqlite3AnalysisLoad(sqlite3 *db, int iDb){
}
- /* Load the statistics from the sqlite_stat2 table. */
-#ifdef SQLITE_ENABLE_STAT2
- if( rc==SQLITE_OK && !sqlite3FindTable(db, "sqlite_stat2", sInfo.zDatabase) ){
- rc = SQLITE_ERROR;
- }
+ /* Load the statistics from the sqlite_stat3 table. */
+#ifdef SQLITE_ENABLE_STAT3
if( rc==SQLITE_OK ){
- sqlite3_stmt *pStmt = 0;
-
- zSql = sqlite3MPrintf(db,
- "SELECT idx,sampleno,sample FROM %Q.sqlite_stat2", sInfo.zDatabase);
- if( !zSql ){
- rc = SQLITE_NOMEM;
- }else{
- rc = sqlite3_prepare(db, zSql, -1, &pStmt, 0);
- sqlite3DbFree(db, zSql);
- }
-
- if( rc==SQLITE_OK ){
- while( sqlite3_step(pStmt)==SQLITE_ROW ){
- char *zIndex; /* Index name */
- Index *pIdx; /* Pointer to the index object */
-
- zIndex = (char *)sqlite3_column_text(pStmt, 0);
- pIdx = zIndex ? sqlite3FindIndex(db, zIndex, sInfo.zDatabase) : 0;
- if( pIdx ){
- int iSample = sqlite3_column_int(pStmt, 1);
- if( iSample<SQLITE_INDEX_SAMPLES && iSample>=0 ){
- int eType = sqlite3_column_type(pStmt, 2);
-
- if( pIdx->aSample==0 ){
- static const int sz = sizeof(IndexSample)*SQLITE_INDEX_SAMPLES;
- pIdx->aSample = (IndexSample *)sqlite3DbMallocRaw(0, sz);
- if( pIdx->aSample==0 ){
- db->mallocFailed = 1;
- break;
- }
- memset(pIdx->aSample, 0, sz);
- }
-
- assert( pIdx->aSample );
- {
- IndexSample *pSample = &pIdx->aSample[iSample];
- pSample->eType = (u8)eType;
- if( eType==SQLITE_INTEGER || eType==SQLITE_FLOAT ){
- pSample->u.r = sqlite3_column_double(pStmt, 2);
- }else if( eType==SQLITE_TEXT || eType==SQLITE_BLOB ){
- const char *z = (const char *)(
- (eType==SQLITE_BLOB) ?
- sqlite3_column_blob(pStmt, 2):
- sqlite3_column_text(pStmt, 2)
- );
- int n = sqlite3_column_bytes(pStmt, 2);
- if( n>24 ){
- n = 24;
- }
- pSample->nByte = (u8)n;
- if( n < 1){
- pSample->u.z = 0;
- }else{
- pSample->u.z = sqlite3DbStrNDup(0, z, n);
- if( pSample->u.z==0 ){
- db->mallocFailed = 1;
- break;
- }
- }
- }
- }
- }
- }
- }
- rc = sqlite3_finalize(pStmt);
- }
+ int lookasideEnabled = db->lookaside.bEnabled;
+ db->lookaside.bEnabled = 0;
+ rc = loadStat3(db, sInfo.zDatabase);
+ db->lookaside.bEnabled = lookasideEnabled;
}
#endif
@@ -76671,7 +80233,7 @@ static void attachFunc(
}
}
- /* Allocate the new entry in the db->aDb[] array and initialise the schema
+ /* Allocate the new entry in the db->aDb[] array and initialize the schema
** hash tables.
*/
if( db->aDb==db->aDbStatic ){
@@ -76688,7 +80250,7 @@ static void attachFunc(
/* Open the database file. If the btree is successfully opened, use
** it to obtain the database schema. At this point the schema may
- ** or may not be initialised.
+ ** or may not be initialized.
*/
flags = db->openFlags;
rc = sqlite3ParseUri(db->pVfs->zName, zFile, &flags, &pVfs, &zPath, &zErr);
@@ -76778,7 +80340,7 @@ static void attachFunc(
db->aDb[iDb].pBt = 0;
db->aDb[iDb].pSchema = 0;
}
- sqlite3ResetInternalSchema(db, -1);
+ sqlite3ResetAllSchemasOfConnection(db);
db->nDb = iDb;
if( rc==SQLITE_NOMEM || rc==SQLITE_IOERR_NOMEM ){
db->mallocFailed = 1;
@@ -76850,7 +80412,7 @@ static void detachFunc(
sqlite3BtreeClose(pDb->pBt);
pDb->pBt = 0;
pDb->pSchema = 0;
- sqlite3ResetInternalSchema(db, -1);
+ sqlite3ResetAllSchemasOfConnection(db);
return;
detach_error:
@@ -76996,6 +80558,7 @@ SQLITE_PRIVATE int sqlite3FixInit(
assert( db->nDb>iDb );
pFix->pParse = pParse;
pFix->zDb = db->aDb[iDb].zName;
+ pFix->pSchema = db->aDb[iDb].pSchema;
pFix->zType = zType;
pFix->pName = pName;
return 1;
@@ -77026,14 +80589,15 @@ SQLITE_PRIVATE int sqlite3FixSrcList(
if( NEVER(pList==0) ) return 0;
zDb = pFix->zDb;
for(i=0, pItem=pList->a; i<pList->nSrc; i++, pItem++){
- if( pItem->zDatabase==0 ){
- pItem->zDatabase = sqlite3DbStrDup(pFix->pParse->db, zDb);
- }else if( sqlite3StrICmp(pItem->zDatabase,zDb)!=0 ){
+ if( pItem->zDatabase && sqlite3StrICmp(pItem->zDatabase, zDb) ){
sqlite3ErrorMsg(pFix->pParse,
"%s %T cannot reference objects in database %s",
pFix->zType, pFix->pName, pItem->zDatabase);
return 1;
}
+ sqlite3DbFree(pFix->pParse->db, pItem->zDatabase);
+ pItem->zDatabase = 0;
+ pItem->pSchema = pFix->pSchema;
#if !defined(SQLITE_OMIT_VIEW) || !defined(SQLITE_OMIT_TRIGGER)
if( sqlite3FixSelect(pFix, pItem->pSelect) ) return 1;
if( sqlite3FixExpr(pFix, pItem->pOn) ) return 1;
@@ -77499,6 +81063,7 @@ SQLITE_PRIVATE void sqlite3FinishCoding(Parse *pParse){
sqlite3 *db;
Vdbe *v;
+ assert( pParse->pToplevel==0 );
db = pParse->db;
if( db->mallocFailed ) return;
if( pParse->nested ) return;
@@ -77692,6 +81257,31 @@ SQLITE_PRIVATE Table *sqlite3LocateTable(
}
/*
+** Locate the table identified by *p.
+**
+** This is a wrapper around sqlite3LocateTable(). The difference between
+** sqlite3LocateTable() and this function is that this function restricts
+** the search to schema (p->pSchema) if it is not NULL. p->pSchema may be
+** non-NULL if it is part of a view or trigger program definition. See
+** sqlite3FixSrcList() for details.
+*/
+SQLITE_PRIVATE Table *sqlite3LocateTableItem(
+ Parse *pParse,
+ int isView,
+ struct SrcList_item *p
+){
+ const char *zDb;
+ assert( p->pSchema==0 || p->zDatabase==0 );
+ if( p->pSchema ){
+ int iDb = sqlite3SchemaToIndex(pParse->db, p->pSchema);
+ zDb = pParse->db->aDb[iDb].zName;
+ }else{
+ zDb = p->zDatabase;
+ }
+ return sqlite3LocateTable(pParse, isView, p->zName, zDb);
+}
+
+/*
** Locate the in-memory structure that describes
** a particular index given the name of that index
** and the name of the database that contains the index.
@@ -77766,58 +81356,15 @@ SQLITE_PRIVATE void sqlite3UnlinkAndDeleteIndex(sqlite3 *db, int iDb, const char
}
/*
-** Erase all schema information from the in-memory hash tables of
-** a single database. This routine is called to reclaim memory
-** before the database closes. It is also called during a rollback
-** if there were schema changes during the transaction or if a
-** schema-cookie mismatch occurs.
+** Look through the list of open database files in db->aDb[] and if
+** any have been closed, remove them from the list. Reallocate the
+** db->aDb[] structure to a smaller size, if possible.
**
-** If iDb<0 then reset the internal schema tables for all database
-** files. If iDb>=0 then reset the internal schema for only the
-** single file indicated.
+** Entry 0 (the "main" database) and entry 1 (the "temp" database)
+** are never candidates for being collapsed.
*/
-SQLITE_PRIVATE void sqlite3ResetInternalSchema(sqlite3 *db, int iDb){
+SQLITE_PRIVATE void sqlite3CollapseDatabaseArray(sqlite3 *db){
int i, j;
- assert( iDb<db->nDb );
-
- if( iDb>=0 ){
- /* Case 1: Reset the single schema identified by iDb */
- Db *pDb = &db->aDb[iDb];
- assert( sqlite3SchemaMutexHeld(db, iDb, 0) );
- assert( pDb->pSchema!=0 );
- sqlite3SchemaClear(pDb->pSchema);
-
- /* If any database other than TEMP is reset, then also reset TEMP
- ** since TEMP might be holding triggers that reference tables in the
- ** other database.
- */
- if( iDb!=1 ){
- pDb = &db->aDb[1];
- assert( pDb->pSchema!=0 );
- sqlite3SchemaClear(pDb->pSchema);
- }
- return;
- }
- /* Case 2 (from here to the end): Reset all schemas for all attached
- ** databases. */
- assert( iDb<0 );
- sqlite3BtreeEnterAll(db);
- for(i=0; i<db->nDb; i++){
- Db *pDb = &db->aDb[i];
- if( pDb->pSchema ){
- sqlite3SchemaClear(pDb->pSchema);
- }
- }
- db->flags &= ~SQLITE_InternChanges;
- sqlite3VtabUnlockList(db);
- sqlite3BtreeLeaveAll(db);
-
- /* If one or more of the auxiliary database files has been closed,
- ** then remove them from the auxiliary database list. We take the
- ** opportunity to do this here since we have just deleted all of the
- ** schema hash tables and therefore do not have to make any changes
- ** to any of those tables.
- */
for(i=j=2; i<db->nDb; i++){
struct Db *pDb = &db->aDb[i];
if( pDb->pBt==0 ){
@@ -77840,6 +81387,51 @@ SQLITE_PRIVATE void sqlite3ResetInternalSchema(sqlite3 *db, int iDb){
}
/*
+** Reset the schema for the database at index iDb. Also reset the
+** TEMP schema.
+*/
+SQLITE_PRIVATE void sqlite3ResetOneSchema(sqlite3 *db, int iDb){
+ Db *pDb;
+ assert( iDb<db->nDb );
+
+ /* Case 1: Reset the single schema identified by iDb */
+ pDb = &db->aDb[iDb];
+ assert( sqlite3SchemaMutexHeld(db, iDb, 0) );
+ assert( pDb->pSchema!=0 );
+ sqlite3SchemaClear(pDb->pSchema);
+
+ /* If any database other than TEMP is reset, then also reset TEMP
+ ** since TEMP might be holding triggers that reference tables in the
+ ** other database.
+ */
+ if( iDb!=1 ){
+ pDb = &db->aDb[1];
+ assert( pDb->pSchema!=0 );
+ sqlite3SchemaClear(pDb->pSchema);
+ }
+ return;
+}
+
+/*
+** Erase all schema information from all attached databases (including
+** "main" and "temp") for a single database connection.
+*/
+SQLITE_PRIVATE void sqlite3ResetAllSchemasOfConnection(sqlite3 *db){
+ int i;
+ sqlite3BtreeEnterAll(db);
+ for(i=0; i<db->nDb; i++){
+ Db *pDb = &db->aDb[i];
+ if( pDb->pSchema ){
+ sqlite3SchemaClear(pDb->pSchema);
+ }
+ }
+ db->flags &= ~SQLITE_InternChanges;
+ sqlite3VtabUnlockList(db);
+ sqlite3BtreeLeaveAll(db);
+ sqlite3CollapseDatabaseArray(db);
+}
+
+/*
** This routine is called when a commit occurs.
*/
SQLITE_PRIVATE void sqlite3CommitInternalChanges(sqlite3 *db){
@@ -77874,9 +81466,16 @@ static void sqliteDeleteColumnNames(sqlite3 *db, Table *pTable){
** the table data structure from the hash table. But it does destroy
** memory structures of the indices and foreign keys associated with
** the table.
+**
+** The db parameter is optional. It is needed if the Table object
+** contains lookaside memory. (Table objects in the schema do not use
+** lookaside memory, but some ephemeral Table objects do.) Or the
+** db parameter can be used with db->pnBytesFreed to measure the memory
+** used by the Table object.
*/
SQLITE_PRIVATE void sqlite3DeleteTable(sqlite3 *db, Table *pTable){
Index *pIndex, *pNext;
+ TESTONLY( int nLookaside; ) /* Used to verify lookaside not used for schema */
assert( !pTable || pTable->nRef>0 );
@@ -77884,6 +81483,12 @@ SQLITE_PRIVATE void sqlite3DeleteTable(sqlite3 *db, Table *pTable){
if( !pTable ) return;
if( ((!db || db->pnBytesFreed==0) && (--pTable->nRef)>0) ) return;
+ /* Record the number of outstanding lookaside allocations in schema Tables
+ ** prior to doing any free() operations. Since schema Tables do not use
+ ** lookaside, this number should not change. */
+ TESTONLY( nLookaside = (db && (pTable->tabFlags & TF_Ephemeral)==0) ?
+ db->lookaside.nOut : 0 );
+
/* Delete all indices associated with this table. */
for(pIndex = pTable->pIndex; pIndex; pIndex=pNext){
pNext = pIndex->pNext;
@@ -77891,7 +81496,7 @@ SQLITE_PRIVATE void sqlite3DeleteTable(sqlite3 *db, Table *pTable){
if( !db || db->pnBytesFreed==0 ){
char *zName = pIndex->zName;
TESTONLY ( Index *pOld = ) sqlite3HashInsert(
- &pIndex->pSchema->idxHash, zName, sqlite3Strlen30(zName), 0
+ &pIndex->pSchema->idxHash, zName, sqlite3Strlen30(zName), 0
);
assert( db==0 || sqlite3SchemaMutexHeld(db, 0, pIndex->pSchema) );
assert( pOld==pIndex || pOld==0 );
@@ -77909,12 +81514,15 @@ SQLITE_PRIVATE void sqlite3DeleteTable(sqlite3 *db, Table *pTable){
sqlite3DbFree(db, pTable->zColAff);
sqlite3SelectDelete(db, pTable->pSelect);
#ifndef SQLITE_OMIT_CHECK
- sqlite3ExprDelete(db, pTable->pCheck);
+ sqlite3ExprListDelete(db, pTable->pCheck);
#endif
#ifndef SQLITE_OMIT_VIRTUALTABLE
sqlite3VtabClear(db, pTable);
#endif
sqlite3DbFree(db, pTable);
+
+ /* Verify that no lookaside memory was used by schema tables */
+ assert( nLookaside==0 || nLookaside==db->lookaside.nOut );
}
/*
@@ -78523,7 +82131,7 @@ SQLITE_PRIVATE void sqlite3AddPrimaryKey(
pTab->tabFlags |= TF_HasPrimaryKey;
if( pList==0 ){
iCol = pTab->nCol - 1;
- pTab->aCol[iCol].isPrimKey = 1;
+ pTab->aCol[iCol].colFlags |= COLFLAG_PRIMKEY;
}else{
for(i=0; i<pList->nExpr; i++){
for(iCol=0; iCol<pTab->nCol; iCol++){
@@ -78532,7 +82140,7 @@ SQLITE_PRIVATE void sqlite3AddPrimaryKey(
}
}
if( iCol<pTab->nCol ){
- pTab->aCol[iCol].isPrimKey = 1;
+ pTab->aCol[iCol].colFlags |= COLFLAG_PRIMKEY;
}
}
if( pList->nExpr>1 ) iCol = -1;
@@ -78572,15 +82180,17 @@ SQLITE_PRIVATE void sqlite3AddCheckConstraint(
Parse *pParse, /* Parsing context */
Expr *pCheckExpr /* The check expression */
){
- sqlite3 *db = pParse->db;
#ifndef SQLITE_OMIT_CHECK
Table *pTab = pParse->pNewTable;
if( pTab && !IN_DECLARE_VTAB ){
- pTab->pCheck = sqlite3ExprAnd(db, pTab->pCheck, pCheckExpr);
+ pTab->pCheck = sqlite3ExprListAppend(pParse, pTab->pCheck, pCheckExpr);
+ if( pParse->constraintName.n ){
+ sqlite3ExprListSetName(pParse, pTab->pCheck, &pParse->constraintName, 1);
+ }
}else
#endif
{
- sqlite3ExprDelete(db, pCheckExpr);
+ sqlite3ExprDelete(pParse->db, pCheckExpr);
}
}
@@ -78647,10 +82257,7 @@ SQLITE_PRIVATE CollSeq *sqlite3LocateCollSeq(Parse *pParse, const char *zName){
pColl = sqlite3FindCollSeq(db, enc, zName, initbusy);
if( !initbusy && (!pColl || !pColl->xCmp) ){
- pColl = sqlite3GetCollSeq(db, enc, pColl, zName);
- if( !pColl ){
- sqlite3ErrorMsg(pParse, "no such collation sequence: %s", zName);
- }
+ pColl = sqlite3GetCollSeq(pParse, enc, pColl, zName);
}
return pColl;
@@ -78850,6 +82457,8 @@ SQLITE_PRIVATE void sqlite3EndTable(
if( p->pCheck ){
SrcList sSrc; /* Fake SrcList for pParse->pNewTable */
NameContext sNC; /* Name context for pParse->pNewTable */
+ ExprList *pList; /* List of all CHECK constraints */
+ int i; /* Loop counter */
memset(&sNC, 0, sizeof(sNC));
memset(&sSrc, 0, sizeof(sSrc));
@@ -78859,9 +82468,12 @@ SQLITE_PRIVATE void sqlite3EndTable(
sSrc.a[0].iCursor = -1;
sNC.pParse = pParse;
sNC.pSrcList = &sSrc;
- sNC.isCheck = 1;
- if( sqlite3ResolveExprNames(&sNC, p->pCheck) ){
- return;
+ sNC.ncFlags = NC_IsCheck;
+ pList = p->pCheck;
+ for(i=0; i<pList->nExpr; i++){
+ if( sqlite3ResolveExprNames(&sNC, pList->a[i].pExpr) ){
+ return;
+ }
}
}
#endif /* !defined(SQLITE_OMIT_CHECK) */
@@ -78928,7 +82540,7 @@ SQLITE_PRIVATE void sqlite3EndTable(
assert(pParse->nTab==1);
sqlite3VdbeAddOp3(v, OP_OpenWrite, 1, pParse->regRoot, iDb);
- sqlite3VdbeChangeP5(v, 1);
+ sqlite3VdbeChangeP5(v, OPFLAG_P2ISREG);
pParse->nTab = 2;
sqlite3SelectDestInit(&dest, SRT_Table, 1);
sqlite3Select(pParse, pSelect, &dest);
@@ -79010,7 +82622,6 @@ SQLITE_PRIVATE void sqlite3EndTable(
return;
}
pParse->pNewTable = 0;
- db->nTable++;
db->flags |= SQLITE_InternChanges;
#ifndef SQLITE_OMIT_ALTERTABLE
@@ -79046,7 +82657,7 @@ SQLITE_PRIVATE void sqlite3CreateView(
const char *z;
Token sEnd;
DbFixer sFix;
- Token *pName;
+ Token *pName = 0;
int iDb;
sqlite3 *db = pParse->db;
@@ -79345,6 +82956,7 @@ static void destroyTable(Parse *pParse, Table *pTab){
return;
}else{
int iDb = sqlite3SchemaToIndex(pParse->db, pTab->pSchema);
+ assert( iDb>=0 && iDb<pParse->db->nDb );
destroyRootPage(pParse, iLargest, iDb);
iDestroyed = iLargest;
}
@@ -79353,6 +82965,100 @@ static void destroyTable(Parse *pParse, Table *pTab){
}
/*
+** Remove entries from the sqlite_statN tables (for N in (1,2,3))
+** after a DROP INDEX or DROP TABLE command.
+*/
+static void sqlite3ClearStatTables(
+ Parse *pParse, /* The parsing context */
+ int iDb, /* The database number */
+ const char *zType, /* "idx" or "tbl" */
+ const char *zName /* Name of index or table */
+){
+ int i;
+ const char *zDbName = pParse->db->aDb[iDb].zName;
+ for(i=1; i<=3; i++){
+ char zTab[24];
+ sqlite3_snprintf(sizeof(zTab),zTab,"sqlite_stat%d",i);
+ if( sqlite3FindTable(pParse->db, zTab, zDbName) ){
+ sqlite3NestedParse(pParse,
+ "DELETE FROM %Q.%s WHERE %s=%Q",
+ zDbName, zTab, zType, zName
+ );
+ }
+ }
+}
+
+/*
+** Generate code to drop a table.
+*/
+SQLITE_PRIVATE void sqlite3CodeDropTable(Parse *pParse, Table *pTab, int iDb, int isView){
+ Vdbe *v;
+ sqlite3 *db = pParse->db;
+ Trigger *pTrigger;
+ Db *pDb = &db->aDb[iDb];
+
+ v = sqlite3GetVdbe(pParse);
+ assert( v!=0 );
+ sqlite3BeginWriteOperation(pParse, 1, iDb);
+
+#ifndef SQLITE_OMIT_VIRTUALTABLE
+ if( IsVirtual(pTab) ){
+ sqlite3VdbeAddOp0(v, OP_VBegin);
+ }
+#endif
+
+ /* Drop all triggers associated with the table being dropped. Code
+ ** is generated to remove entries from sqlite_master and/or
+ ** sqlite_temp_master if required.
+ */
+ pTrigger = sqlite3TriggerList(pParse, pTab);
+ while( pTrigger ){
+ assert( pTrigger->pSchema==pTab->pSchema ||
+ pTrigger->pSchema==db->aDb[1].pSchema );
+ sqlite3DropTriggerPtr(pParse, pTrigger);
+ pTrigger = pTrigger->pNext;
+ }
+
+#ifndef SQLITE_OMIT_AUTOINCREMENT
+ /* Remove any entries of the sqlite_sequence table associated with
+ ** the table being dropped. This is done before the table is dropped
+ ** at the btree level, in case the sqlite_sequence table needs to
+ ** move as a result of the drop (can happen in auto-vacuum mode).
+ */
+ if( pTab->tabFlags & TF_Autoincrement ){
+ sqlite3NestedParse(pParse,
+ "DELETE FROM %Q.sqlite_sequence WHERE name=%Q",
+ pDb->zName, pTab->zName
+ );
+ }
+#endif
+
+ /* Drop all SQLITE_MASTER table and index entries that refer to the
+ ** table. The program name loops through the master table and deletes
+ ** every row that refers to a table of the same name as the one being
+ ** dropped. Triggers are handled separately because a trigger can be
+ ** created in the temp database that refers to a table in another
+ ** database.
+ */
+ sqlite3NestedParse(pParse,
+ "DELETE FROM %Q.%s WHERE tbl_name=%Q and type!='trigger'",
+ pDb->zName, SCHEMA_TABLE(iDb), pTab->zName);
+ if( !isView && !IsVirtual(pTab) ){
+ destroyTable(pParse, pTab);
+ }
+
+ /* Remove the table entry from SQLite's internal schema and modify
+ ** the schema cookie.
+ */
+ if( IsVirtual(pTab) ){
+ sqlite3VdbeAddOp4(v, OP_VDestroy, iDb, 0, 0, pTab->zName, 0);
+ }
+ sqlite3VdbeAddOp4(v, OP_DropTable, iDb, 0, 0, pTab->zName, 0);
+ sqlite3ChangeCookie(pParse, iDb);
+ sqliteViewResetAll(db, iDb);
+}
+
+/*
** This routine is called to do the work of a DROP TABLE statement.
** pName is the name of the table to be dropped.
*/
@@ -79368,8 +83074,7 @@ SQLITE_PRIVATE void sqlite3DropTable(Parse *pParse, SrcList *pName, int isView,
assert( pParse->nErr==0 );
assert( pName->nSrc==1 );
if( noErr ) db->suppressErr++;
- pTab = sqlite3LocateTable(pParse, isView,
- pName->a[0].zName, pName->a[0].zDatabase);
+ pTab = sqlite3LocateTableItem(pParse, isView, &pName->a[0]);
if( noErr ) db->suppressErr--;
if( pTab==0 ){
@@ -79420,7 +83125,8 @@ SQLITE_PRIVATE void sqlite3DropTable(Parse *pParse, SrcList *pName, int isView,
}
}
#endif
- if( sqlite3StrNICmp(pTab->zName, "sqlite_", 7)==0 ){
+ if( sqlite3StrNICmp(pTab->zName, "sqlite_", 7)==0
+ && sqlite3StrNICmp(pTab->zName, "sqlite_stat", 11)!=0 ){
sqlite3ErrorMsg(pParse, "table %s may not be dropped", pTab->zName);
goto exit_drop_table;
}
@@ -79444,75 +83150,11 @@ SQLITE_PRIVATE void sqlite3DropTable(Parse *pParse, SrcList *pName, int isView,
*/
v = sqlite3GetVdbe(pParse);
if( v ){
- Trigger *pTrigger;
- Db *pDb = &db->aDb[iDb];
sqlite3BeginWriteOperation(pParse, 1, iDb);
-
-#ifndef SQLITE_OMIT_VIRTUALTABLE
- if( IsVirtual(pTab) ){
- sqlite3VdbeAddOp0(v, OP_VBegin);
- }
-#endif
+ sqlite3ClearStatTables(pParse, iDb, "tbl", pTab->zName);
sqlite3FkDropTable(pParse, pName, pTab);
-
- /* Drop all triggers associated with the table being dropped. Code
- ** is generated to remove entries from sqlite_master and/or
- ** sqlite_temp_master if required.
- */
- pTrigger = sqlite3TriggerList(pParse, pTab);
- while( pTrigger ){
- assert( pTrigger->pSchema==pTab->pSchema ||
- pTrigger->pSchema==db->aDb[1].pSchema );
- sqlite3DropTriggerPtr(pParse, pTrigger);
- pTrigger = pTrigger->pNext;
- }
-
-#ifndef SQLITE_OMIT_AUTOINCREMENT
- /* Remove any entries of the sqlite_sequence table associated with
- ** the table being dropped. This is done before the table is dropped
- ** at the btree level, in case the sqlite_sequence table needs to
- ** move as a result of the drop (can happen in auto-vacuum mode).
- */
- if( pTab->tabFlags & TF_Autoincrement ){
- sqlite3NestedParse(pParse,
- "DELETE FROM %s.sqlite_sequence WHERE name=%Q",
- pDb->zName, pTab->zName
- );
- }
-#endif
-
- /* Drop all SQLITE_MASTER table and index entries that refer to the
- ** table. The program name loops through the master table and deletes
- ** every row that refers to a table of the same name as the one being
- ** dropped. Triggers are handled seperately because a trigger can be
- ** created in the temp database that refers to a table in another
- ** database.
- */
- sqlite3NestedParse(pParse,
- "DELETE FROM %Q.%s WHERE tbl_name=%Q and type!='trigger'",
- pDb->zName, SCHEMA_TABLE(iDb), pTab->zName);
-
- /* Drop any statistics from the sqlite_stat1 table, if it exists */
- if( sqlite3FindTable(db, "sqlite_stat1", db->aDb[iDb].zName) ){
- sqlite3NestedParse(pParse,
- "DELETE FROM %Q.sqlite_stat1 WHERE tbl=%Q", pDb->zName, pTab->zName
- );
- }
-
- if( !isView && !IsVirtual(pTab) ){
- destroyTable(pParse, pTab);
- }
-
- /* Remove the table entry from SQLite's internal schema and modify
- ** the schema cookie.
- */
- if( IsVirtual(pTab) ){
- sqlite3VdbeAddOp4(v, OP_VDestroy, iDb, 0, 0, pTab->zName, 0);
- }
- sqlite3VdbeAddOp4(v, OP_DropTable, iDb, 0, 0, pTab->zName, 0);
- sqlite3ChangeCookie(pParse, iDb);
+ sqlite3CodeDropTable(pParse, pTab, iDb, isView);
}
- sqliteViewResetAll(db, iDb);
exit_drop_table:
sqlite3SrcListDelete(db, pName);
@@ -79680,11 +83322,12 @@ static void sqlite3RefillIndex(Parse *pParse, Index *pIndex, int memRootPage){
Table *pTab = pIndex->pTable; /* The table that is indexed */
int iTab = pParse->nTab++; /* Btree cursor used for pTab */
int iIdx = pParse->nTab++; /* Btree cursor used for pIndex */
+ int iSorter; /* Cursor opened by OpenSorter (if in use) */
int addr1; /* Address of top of loop */
+ int addr2; /* Address to jump to for next iteration */
int tnum; /* Root page of index */
Vdbe *v; /* Generate code into this virtual machine */
KeyInfo *pKey; /* KeyInfo for index */
- int regIdxKey; /* Registers containing the index key */
int regRecord; /* Register holding assemblied index record */
sqlite3 *db = pParse->db; /* The database connection */
int iDb = sqlite3SchemaToIndex(db, pIndex->pSchema);
@@ -79710,38 +83353,44 @@ static void sqlite3RefillIndex(Parse *pParse, Index *pIndex, int memRootPage){
pKey = sqlite3IndexKeyinfo(pParse, pIndex);
sqlite3VdbeAddOp4(v, OP_OpenWrite, iIdx, tnum, iDb,
(char *)pKey, P4_KEYINFO_HANDOFF);
- if( memRootPage>=0 ){
- sqlite3VdbeChangeP5(v, 1);
- }
+ sqlite3VdbeChangeP5(v, OPFLAG_BULKCSR|((memRootPage>=0)?OPFLAG_P2ISREG:0));
+
+ /* Open the sorter cursor if we are to use one. */
+ iSorter = pParse->nTab++;
+ sqlite3VdbeAddOp4(v, OP_SorterOpen, iSorter, 0, 0, (char*)pKey, P4_KEYINFO);
+
+ /* Open the table. Loop through all rows of the table, inserting index
+ ** records into the sorter. */
sqlite3OpenTable(pParse, iTab, iDb, pTab, OP_OpenRead);
addr1 = sqlite3VdbeAddOp2(v, OP_Rewind, iTab, 0);
regRecord = sqlite3GetTempReg(pParse);
- regIdxKey = sqlite3GenerateIndexKey(pParse, pIndex, iTab, regRecord, 1);
+
+ sqlite3GenerateIndexKey(pParse, pIndex, iTab, regRecord, 1);
+ sqlite3VdbeAddOp2(v, OP_SorterInsert, iSorter, regRecord);
+ sqlite3VdbeAddOp2(v, OP_Next, iTab, addr1+1);
+ sqlite3VdbeJumpHere(v, addr1);
+ addr1 = sqlite3VdbeAddOp2(v, OP_SorterSort, iSorter, 0);
if( pIndex->onError!=OE_None ){
- const int regRowid = regIdxKey + pIndex->nColumn;
- const int j2 = sqlite3VdbeCurrentAddr(v) + 2;
- void * const pRegKey = SQLITE_INT_TO_PTR(regIdxKey);
-
- /* The registers accessed by the OP_IsUnique opcode were allocated
- ** using sqlite3GetTempRange() inside of the sqlite3GenerateIndexKey()
- ** call above. Just before that function was freed they were released
- ** (made available to the compiler for reuse) using
- ** sqlite3ReleaseTempRange(). So in some ways having the OP_IsUnique
- ** opcode use the values stored within seems dangerous. However, since
- ** we can be sure that no other temp registers have been allocated
- ** since sqlite3ReleaseTempRange() was called, it is safe to do so.
- */
- sqlite3VdbeAddOp4(v, OP_IsUnique, iIdx, j2, regRowid, pRegKey, P4_INT32);
- sqlite3HaltConstraint(
- pParse, OE_Abort, "indexed columns are not unique", P4_STATIC);
+ int j2 = sqlite3VdbeCurrentAddr(v) + 3;
+ sqlite3VdbeAddOp2(v, OP_Goto, 0, j2);
+ addr2 = sqlite3VdbeCurrentAddr(v);
+ sqlite3VdbeAddOp3(v, OP_SorterCompare, iSorter, j2, regRecord);
+ sqlite3HaltConstraint(pParse, SQLITE_CONSTRAINT_UNIQUE,
+ OE_Abort, "indexed columns are not unique", P4_STATIC
+ );
+ }else{
+ addr2 = sqlite3VdbeCurrentAddr(v);
}
- sqlite3VdbeAddOp2(v, OP_IdxInsert, iIdx, regRecord);
+ sqlite3VdbeAddOp2(v, OP_SorterData, iSorter, regRecord);
+ sqlite3VdbeAddOp3(v, OP_IdxInsert, iIdx, regRecord, 1);
sqlite3VdbeChangeP5(v, OPFLAG_USESEEKRESULT);
sqlite3ReleaseTempReg(pParse, regRecord);
- sqlite3VdbeAddOp2(v, OP_Next, iTab, addr1+1);
+ sqlite3VdbeAddOp2(v, OP_SorterNext, iSorter, addr2);
sqlite3VdbeJumpHere(v, addr1);
+
sqlite3VdbeAddOp1(v, OP_Close, iTab);
sqlite3VdbeAddOp1(v, OP_Close, iIdx);
+ sqlite3VdbeAddOp1(v, OP_Close, iSorter);
}
/*
@@ -79811,9 +83460,10 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex(
assert( pName1 && pName2 );
iDb = sqlite3TwoPartName(pParse, pName1, pName2, &pName);
if( iDb<0 ) goto exit_create_index;
+ assert( pName && pName->z );
#ifndef SQLITE_OMIT_TEMPDB
- /* If the index name was unqualified, check if the the table
+ /* If the index name was unqualified, check if the table
** is a temp table. If so, set the database to 1. Do not do this
** if initialising a database schema.
*/
@@ -79832,12 +83482,13 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex(
** sqlite3FixSrcList can never fail. */
assert(0);
}
- pTab = sqlite3LocateTable(pParse, 0, pTblName->a[0].zName,
- pTblName->a[0].zDatabase);
- if( !pTab || db->mallocFailed ) goto exit_create_index;
+ pTab = sqlite3LocateTableItem(pParse, 0, &pTblName->a[0]);
+ assert( db->mallocFailed==0 || pTab==0 );
+ if( pTab==0 ) goto exit_create_index;
assert( db->aDb[iDb].pSchema==pTab->pSchema );
}else{
assert( pName==0 );
+ assert( pStart==0 );
pTab = pParse->pNewTable;
if( !pTab ) goto exit_create_index;
iDb = sqlite3SchemaToIndex(db, pTab->pSchema);
@@ -79847,7 +83498,7 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex(
assert( pTab!=0 );
assert( pParse->nErr==0 );
if( sqlite3StrNICmp(pTab->zName, "sqlite_", 7)==0
- && memcmp(&pTab->zName[7],"altertab_",9)!=0 ){
+ && sqlite3StrNICmp(&pTab->zName[7],"altertab_",9)!=0 ){
sqlite3ErrorMsg(pParse, "table %s may not be indexed", pTab->zName);
goto exit_create_index;
}
@@ -79880,6 +83531,7 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex(
if( pName ){
zName = sqlite3NameFromToken(db, pName);
if( zName==0 ) goto exit_create_index;
+ assert( pName->z!=0 );
if( SQLITE_OK!=sqlite3CheckObjectName(pParse, zName) ){
goto exit_create_index;
}
@@ -79943,10 +83595,8 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex(
for(i=0; i<pList->nExpr; i++){
Expr *pExpr = pList->a[i].pExpr;
if( pExpr ){
- CollSeq *pColl = pExpr->pColl;
- /* Either pColl!=0 or there was an OOM failure. But if an OOM
- ** failure we have quit before reaching this point. */
- if( ALWAYS(pColl) ){
+ CollSeq *pColl = sqlite3ExprCollSeq(pParse, pExpr);
+ if( pColl ){
nExtra += (1 + sqlite3Strlen30(pColl->zName));
}
}
@@ -79958,21 +83608,25 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex(
nName = sqlite3Strlen30(zName);
nCol = pList->nExpr;
pIndex = sqlite3DbMallocZero(db,
- sizeof(Index) + /* Index structure */
- sizeof(int)*nCol + /* Index.aiColumn */
- sizeof(int)*(nCol+1) + /* Index.aiRowEst */
- sizeof(char *)*nCol + /* Index.azColl */
- sizeof(u8)*nCol + /* Index.aSortOrder */
- nName + 1 + /* Index.zName */
- nExtra /* Collation sequence names */
+ ROUND8(sizeof(Index)) + /* Index structure */
+ ROUND8(sizeof(tRowcnt)*(nCol+1)) + /* Index.aiRowEst */
+ sizeof(char *)*nCol + /* Index.azColl */
+ sizeof(int)*nCol + /* Index.aiColumn */
+ sizeof(u8)*nCol + /* Index.aSortOrder */
+ nName + 1 + /* Index.zName */
+ nExtra /* Collation sequence names */
);
if( db->mallocFailed ){
goto exit_create_index;
}
- pIndex->azColl = (char**)(&pIndex[1]);
+ zExtra = (char*)pIndex;
+ pIndex->aiRowEst = (tRowcnt*)&zExtra[ROUND8(sizeof(Index))];
+ pIndex->azColl = (char**)
+ ((char*)pIndex->aiRowEst + ROUND8(sizeof(tRowcnt)*nCol+1));
+ assert( EIGHT_BYTE_ALIGNMENT(pIndex->aiRowEst) );
+ assert( EIGHT_BYTE_ALIGNMENT(pIndex->azColl) );
pIndex->aiColumn = (int *)(&pIndex->azColl[nCol]);
- pIndex->aiRowEst = (unsigned *)(&pIndex->aiColumn[nCol]);
- pIndex->aSortOrder = (u8 *)(&pIndex->aiRowEst[nCol+1]);
+ pIndex->aSortOrder = (u8 *)(&pIndex->aiColumn[nCol]);
pIndex->zName = (char *)(&pIndex->aSortOrder[nCol]);
zExtra = (char *)(&pIndex->zName[nName+1]);
memcpy(pIndex->zName, zName, nName+1);
@@ -80005,6 +83659,7 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex(
const char *zColName = pListItem->zName;
Column *pTabCol;
int requestedSortOrder;
+ CollSeq *pColl; /* Collating sequence */
char *zColl; /* Collation sequence name */
for(j=0, pTabCol=pTab->aCol; j<pTab->nCol; j++, pTabCol++){
@@ -80017,14 +83672,11 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex(
goto exit_create_index;
}
pIndex->aiColumn[i] = j;
- /* Justification of the ALWAYS(pListItem->pExpr->pColl): Because of
- ** the way the "idxlist" non-terminal is constructed by the parser,
- ** if pListItem->pExpr is not null then either pListItem->pExpr->pColl
- ** must exist or else there must have been an OOM error. But if there
- ** was an OOM error, we would never reach this point. */
- if( pListItem->pExpr && ALWAYS(pListItem->pExpr->pColl) ){
+ if( pListItem->pExpr
+ && (pColl = sqlite3ExprCollSeq(pParse, pListItem->pExpr))!=0
+ ){
int nColl;
- zColl = pListItem->pExpr->pColl->zName;
+ zColl = pColl->zName;
nColl = sqlite3Strlen30(zColl) + 1;
assert( nExtra>=nColl );
memcpy(zExtra, zColl, nColl);
@@ -80034,7 +83686,7 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex(
}else{
zColl = pTab->aCol[j].zColl;
if( !zColl ){
- zColl = db->pDfltColl->zName;
+ zColl = "BINARY";
}
}
if( !db->init.busy && !sqlite3LocateCollSeq(pParse, zColl) ){
@@ -80091,7 +83743,7 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex(
** However the ON CONFLICT clauses are different. If both this
** constraint and the previous equivalent constraint have explicit
** ON CONFLICT clauses this is an error. Otherwise, use the
- ** explicitly specified behaviour for the index.
+ ** explicitly specified behavior for the index.
*/
if( !(pIdx->onError==OE_Default || pIndex->onError==OE_Default) ){
sqlite3ErrorMsg(pParse,
@@ -80163,7 +83815,7 @@ SQLITE_PRIVATE Index *sqlite3CreateIndex(
/* A named index with an explicit CREATE INDEX statement */
zStmt = sqlite3MPrintf(db, "CREATE%s INDEX %.*s",
onError==OE_None ? "" : " UNIQUE",
- pEnd->z - pName->z + 1,
+ (int)(pEnd->z - pName->z) + 1,
pName->z);
}else{
/* An automatic index created by a PRIMARY KEY or UNIQUE constraint */
@@ -80249,9 +83901,9 @@ exit_create_index:
** are based on typical values found in actual indices.
*/
SQLITE_PRIVATE void sqlite3DefaultRowEst(Index *pIdx){
- unsigned *a = pIdx->aiRowEst;
+ tRowcnt *a = pIdx->aiRowEst;
int i;
- unsigned n;
+ tRowcnt n;
assert( a!=0 );
a[0] = pIdx->pTable->nRowEst;
if( a[0]<10 ) a[0] = 10;
@@ -80321,15 +83973,9 @@ SQLITE_PRIVATE void sqlite3DropIndex(Parse *pParse, SrcList *pName, int ifExists
sqlite3BeginWriteOperation(pParse, 1, iDb);
sqlite3NestedParse(pParse,
"DELETE FROM %Q.%s WHERE name=%Q AND type='index'",
- db->aDb[iDb].zName, SCHEMA_TABLE(iDb),
- pIndex->zName
+ db->aDb[iDb].zName, SCHEMA_TABLE(iDb), pIndex->zName
);
- if( sqlite3FindTable(db, "sqlite_stat1", db->aDb[iDb].zName) ){
- sqlite3NestedParse(pParse,
- "DELETE FROM %Q.sqlite_stat1 WHERE idx=%Q",
- db->aDb[iDb].zName, pIndex->zName
- );
- }
+ sqlite3ClearStatTables(pParse, iDb, "idx", pIndex->zName);
sqlite3ChangeCookie(pParse, iDb);
destroyRootPage(pParse, pIndex->tnum, iDb);
sqlite3VdbeAddOp4(v, OP_DropIndex, iDb, 0, 0, pIndex->zName, 0);
@@ -80340,45 +83986,43 @@ exit_drop_index:
}
/*
-** pArray is a pointer to an array of objects. Each object in the
-** array is szEntry bytes in size. This routine allocates a new
-** object on the end of the array.
+** pArray is a pointer to an array of objects. Each object in the
+** array is szEntry bytes in size. This routine uses sqlite3DbRealloc()
+** to extend the array so that there is space for a new object at the end.
**
-** *pnEntry is the number of entries already in use. *pnAlloc is
-** the previously allocated size of the array. initSize is the
-** suggested initial array size allocation.
+** When this function is called, *pnEntry contains the current size of
+** the array (in entries - so the allocation is ((*pnEntry) * szEntry) bytes
+** in total).
**
-** The index of the new entry is returned in *pIdx.
+** If the realloc() is successful (i.e. if no OOM condition occurs), the
+** space allocated for the new object is zeroed, *pnEntry updated to
+** reflect the new size of the array and a pointer to the new allocation
+** returned. *pIdx is set to the index of the new array entry in this case.
**
-** This routine returns a pointer to the array of objects. This
-** might be the same as the pArray parameter or it might be a different
-** pointer if the array was resized.
+** Otherwise, if the realloc() fails, *pIdx is set to -1, *pnEntry remains
+** unchanged and a copy of pArray returned.
*/
SQLITE_PRIVATE void *sqlite3ArrayAllocate(
sqlite3 *db, /* Connection to notify of malloc failures */
void *pArray, /* Array of objects. Might be reallocated */
int szEntry, /* Size of each object in the array */
- int initSize, /* Suggested initial allocation, in elements */
int *pnEntry, /* Number of objects currently in use */
- int *pnAlloc, /* Current size of the allocation, in elements */
int *pIdx /* Write the index of a new slot here */
){
char *z;
- if( *pnEntry >= *pnAlloc ){
- void *pNew;
- int newSize;
- newSize = (*pnAlloc)*2 + initSize;
- pNew = sqlite3DbRealloc(db, pArray, newSize*szEntry);
+ int n = *pnEntry;
+ if( (n & (n-1))==0 ){
+ int sz = (n==0) ? 1 : 2*n;
+ void *pNew = sqlite3DbRealloc(db, pArray, sz*szEntry);
if( pNew==0 ){
*pIdx = -1;
return pArray;
}
- *pnAlloc = sqlite3DbMallocSize(db, pNew)/szEntry;
pArray = pNew;
}
z = (char*)pArray;
- memset(&z[*pnEntry * szEntry], 0, szEntry);
- *pIdx = *pnEntry;
+ memset(&z[n * szEntry], 0, szEntry);
+ *pIdx = n;
++*pnEntry;
return pArray;
}
@@ -80394,15 +84038,12 @@ SQLITE_PRIVATE IdList *sqlite3IdListAppend(sqlite3 *db, IdList *pList, Token *pT
if( pList==0 ){
pList = sqlite3DbMallocZero(db, sizeof(IdList) );
if( pList==0 ) return 0;
- pList->nAlloc = 0;
}
pList->a = sqlite3ArrayAllocate(
db,
pList->a,
sizeof(pList->a[0]),
- 5,
&pList->nId,
- &pList->nAlloc,
&i
);
if( i<0 ){
@@ -80701,8 +84342,9 @@ SQLITE_PRIVATE void sqlite3SrcListIndexedBy(Parse *pParse, SrcList *p, Token *pI
** operator with A. This routine shifts that operator over to B.
*/
SQLITE_PRIVATE void sqlite3SrcListShiftJoinType(SrcList *p){
- if( p && p->a ){
+ if( p ){
int i;
+ assert( p->a || p->nSrc==0 );
for(i=p->nSrc-1; i>0; i--){
p->a[i].jointype = p->a[i-1].jointype;
}
@@ -80740,13 +84382,10 @@ SQLITE_PRIVATE void sqlite3BeginTransaction(Parse *pParse, int type){
** Commit a transaction
*/
SQLITE_PRIVATE void sqlite3CommitTransaction(Parse *pParse){
- sqlite3 *db;
Vdbe *v;
assert( pParse!=0 );
- db = pParse->db;
- assert( db!=0 );
-/* if( db->aDb[0].pBt==0 ) return; */
+ assert( pParse->db!=0 );
if( sqlite3AuthCheck(pParse, SQLITE_TRANSACTION, "COMMIT", 0, 0) ){
return;
}
@@ -80760,13 +84399,10 @@ SQLITE_PRIVATE void sqlite3CommitTransaction(Parse *pParse){
** Rollback a transaction
*/
SQLITE_PRIVATE void sqlite3RollbackTransaction(Parse *pParse){
- sqlite3 *db;
Vdbe *v;
assert( pParse!=0 );
- db = pParse->db;
- assert( db!=0 );
-/* if( db->aDb[0].pBt==0 ) return; */
+ assert( pParse->db!=0 );
if( sqlite3AuthCheck(pParse, SQLITE_TRANSACTION, "ROLLBACK", 0, 0) ){
return;
}
@@ -80854,6 +84490,15 @@ SQLITE_PRIVATE int sqlite3OpenTempDatabase(Parse *pParse){
SQLITE_PRIVATE void sqlite3CodeVerifySchema(Parse *pParse, int iDb){
Parse *pToplevel = sqlite3ParseToplevel(pParse);
+#ifndef SQLITE_OMIT_TRIGGER
+ if( pToplevel!=pParse ){
+ /* This branch is taken if a trigger is currently being coded. In this
+ ** case, set cookieGoto to a non-zero value to show that this function
+ ** has been called. This is used by the sqlite3ExprCodeConstants()
+ ** function. */
+ pParse->cookieGoto = -1;
+ }
+#endif
if( pToplevel->cookieGoto==0 ){
Vdbe *v = sqlite3GetVdbe(pToplevel);
if( v==0 ) return; /* This only happens if there was a prior error */
@@ -80951,12 +84596,19 @@ SQLITE_PRIVATE void sqlite3MayAbort(Parse *pParse){
** error. The onError parameter determines which (if any) of the statement
** and/or current transaction is rolled back.
*/
-SQLITE_PRIVATE void sqlite3HaltConstraint(Parse *pParse, int onError, char *p4, int p4type){
+SQLITE_PRIVATE void sqlite3HaltConstraint(
+ Parse *pParse, /* Parsing context */
+ int errCode, /* extended error code */
+ int onError, /* Constraint type */
+ char *p4, /* Error message */
+ int p4type /* P4_STATIC or P4_TRANSIENT */
+){
Vdbe *v = sqlite3GetVdbe(pParse);
+ assert( (errCode&0xff)==SQLITE_CONSTRAINT );
if( onError==OE_Abort ){
sqlite3MayAbort(pParse);
}
- sqlite3VdbeAddOp4(v, OP_Halt, SQLITE_CONSTRAINT, onError, 0, p4, p4type);
+ sqlite3VdbeAddOp4(v, OP_Halt, errCode, onError, 0, p4, p4type);
}
/*
@@ -81203,17 +84855,18 @@ static int synthCollSeq(sqlite3 *db, CollSeq *pColl){
**
** The return value is either the collation sequence to be used in database
** db for collation type name zName, length nName, or NULL, if no collation
-** sequence can be found.
+** sequence can be found. If no collation is found, leave an error message.
**
** See also: sqlite3LocateCollSeq(), sqlite3FindCollSeq()
*/
SQLITE_PRIVATE CollSeq *sqlite3GetCollSeq(
- sqlite3* db, /* The database connection */
+ Parse *pParse, /* Parsing context */
u8 enc, /* The desired encoding for the collating sequence */
CollSeq *pColl, /* Collating sequence with native encoding, or NULL */
const char *zName /* Collating sequence name */
){
CollSeq *p;
+ sqlite3 *db = pParse->db;
p = pColl;
if( !p ){
@@ -81230,6 +84883,9 @@ SQLITE_PRIVATE CollSeq *sqlite3GetCollSeq(
p = 0;
}
assert( !p || p->xCmp );
+ if( p==0 ){
+ sqlite3ErrorMsg(pParse, "no such collation sequence: %s", zName);
+ }
return p;
}
@@ -81248,10 +84904,8 @@ SQLITE_PRIVATE int sqlite3CheckCollSeq(Parse *pParse, CollSeq *pColl){
if( pColl ){
const char *zName = pColl->zName;
sqlite3 *db = pParse->db;
- CollSeq *p = sqlite3GetCollSeq(db, ENC(db), pColl, zName);
+ CollSeq *p = sqlite3GetCollSeq(pParse, ENC(db), pColl, zName);
if( !p ){
- sqlite3ErrorMsg(pParse, "no such collation sequence: %s", zName);
- pParse->nErr++;
return SQLITE_ERROR;
}
assert( p==pColl );
@@ -81351,38 +85005,57 @@ SQLITE_PRIVATE CollSeq *sqlite3FindCollSeq(
** that uses encoding enc. The value returned indicates how well the
** request is matched. A higher value indicates a better match.
**
+** If nArg is -1 that means to only return a match (non-zero) if p->nArg
+** is also -1. In other words, we are searching for a function that
+** takes a variable number of arguments.
+**
+** If nArg is -2 that means that we are searching for any function
+** regardless of the number of arguments it uses, so return a positive
+** match score for any
+**
** The returned value is always between 0 and 6, as follows:
**
-** 0: Not a match, or if nArg<0 and the function is has no implementation.
-** 1: A variable arguments function that prefers UTF-8 when a UTF-16
-** encoding is requested, or vice versa.
-** 2: A variable arguments function that uses UTF-16BE when UTF-16LE is
-** requested, or vice versa.
-** 3: A variable arguments function using the same text encoding.
-** 4: A function with the exact number of arguments requested that
-** prefers UTF-8 when a UTF-16 encoding is requested, or vice versa.
-** 5: A function with the exact number of arguments requested that
-** prefers UTF-16LE when UTF-16BE is requested, or vice versa.
-** 6: An exact match.
-**
-*/
-static int matchQuality(FuncDef *p, int nArg, u8 enc){
- int match = 0;
- if( p->nArg==-1 || p->nArg==nArg
- || (nArg==-1 && (p->xFunc!=0 || p->xStep!=0))
- ){
+** 0: Not a match.
+** 1: UTF8/16 conversion required and function takes any number of arguments.
+** 2: UTF16 byte order change required and function takes any number of args.
+** 3: encoding matches and function takes any number of arguments
+** 4: UTF8/16 conversion required - argument count matches exactly
+** 5: UTF16 byte order conversion required - argument count matches exactly
+** 6: Perfect match: encoding and argument count match exactly.
+**
+** If nArg==(-2) then any function with a non-null xStep or xFunc is
+** a perfect match and any function with both xStep and xFunc NULL is
+** a non-match.
+*/
+#define FUNC_PERFECT_MATCH 6 /* The score for a perfect match */
+static int matchQuality(
+ FuncDef *p, /* The function we are evaluating for match quality */
+ int nArg, /* Desired number of arguments. (-1)==any */
+ u8 enc /* Desired text encoding */
+){
+ int match;
+
+ /* nArg of -2 is a special case */
+ if( nArg==(-2) ) return (p->xFunc==0 && p->xStep==0) ? 0 : FUNC_PERFECT_MATCH;
+
+ /* Wrong number of arguments means "no match" */
+ if( p->nArg!=nArg && p->nArg>=0 ) return 0;
+
+ /* Give a better score to a function with a specific number of arguments
+ ** than to function that accepts any number of arguments. */
+ if( p->nArg==nArg ){
+ match = 4;
+ }else{
match = 1;
- if( p->nArg==nArg || nArg==-1 ){
- match = 4;
- }
- if( enc==p->iPrefEnc ){
- match += 2;
- }
- else if( (enc==SQLITE_UTF16LE && p->iPrefEnc==SQLITE_UTF16BE) ||
- (enc==SQLITE_UTF16BE && p->iPrefEnc==SQLITE_UTF16LE) ){
- match += 1;
- }
}
+
+ /* Bonus points if the text encoding matches */
+ if( enc==p->iPrefEnc ){
+ match += 2; /* Exact encoding match */
+ }else if( (enc & p->iPrefEnc & 2)!=0 ){
+ match += 1; /* Both are UTF16, but with different byte orders */
+ }
+
return match;
}
@@ -81438,13 +85111,12 @@ SQLITE_PRIVATE void sqlite3FuncDefInsert(
**
** If the createFlag argument is true, then a new (blank) FuncDef
** structure is created and liked into the "db" structure if a
-** no matching function previously existed. When createFlag is true
-** and the nArg parameter is -1, then only a function that accepts
-** any number of arguments will be returned.
+** no matching function previously existed.
**
-** If createFlag is false and nArg is -1, then the first valid
-** function found is returned. A function is valid if either xFunc
-** or xStep is non-zero.
+** If nArg is -2, then the first valid function found is returned. A
+** function is valid if either xFunc or xStep is non-zero. The nArg==(-2)
+** case is used to see if zName is a valid function name for some number
+** of arguments. If nArg is -2, then createFlag must be 0.
**
** If createFlag is false, then a function with the required name and
** number of arguments may be returned even if the eTextRep flag does not
@@ -81456,14 +85128,15 @@ SQLITE_PRIVATE FuncDef *sqlite3FindFunction(
int nName, /* Number of characters in the name */
int nArg, /* Number of arguments. -1 means any number */
u8 enc, /* Preferred text encoding */
- int createFlag /* Create new entry if true and does not otherwise exist */
+ u8 createFlag /* Create new entry if true and does not otherwise exist */
){
FuncDef *p; /* Iterator variable */
FuncDef *pBest = 0; /* Best match found so far */
int bestScore = 0; /* Score of best match */
int h; /* Hash value */
-
+ assert( nArg>=(-2) );
+ assert( nArg>=(-1) || createFlag==0 );
assert( enc==SQLITE_UTF8 || enc==SQLITE_UTF16LE || enc==SQLITE_UTF16BE );
h = (sqlite3UpperToLower[(u8)zName[0]] + nName) % ArraySize(db->aFunc.a);
@@ -81509,7 +85182,7 @@ SQLITE_PRIVATE FuncDef *sqlite3FindFunction(
** exact match for the name, number of arguments and encoding, then add a
** new entry to the hash table and return it.
*/
- if( createFlag && (bestScore<6 || pBest->nArg!=nArg) &&
+ if( createFlag && bestScore<FUNC_PERFECT_MATCH &&
(pBest = sqlite3DbMallocZero(db, sizeof(*pBest)+nName+1))!=0 ){
pBest->zName = (char *)&pBest[1];
pBest->nArg = (u16)nArg;
@@ -81619,7 +85292,7 @@ SQLITE_PRIVATE Table *sqlite3SrcListLookup(Parse *pParse, SrcList *pSrc){
struct SrcList_item *pItem = pSrc->a;
Table *pTab;
assert( pItem && pSrc->nSrc==1 );
- pTab = sqlite3LocateTable(pParse, 0, pItem->zName, pItem->zDatabase);
+ pTab = sqlite3LocateTableItem(pParse, 0, pItem);
sqlite3DeleteTable(pParse->db, pItem->pTab);
pItem->pTab = pTab;
if( pTab ){
@@ -81680,29 +85353,28 @@ SQLITE_PRIVATE void sqlite3MaterializeView(
int iCur /* Cursor number for ephemerial table */
){
SelectDest dest;
- Select *pDup;
+ Select *pSel;
+ SrcList *pFrom;
sqlite3 *db = pParse->db;
+ int iDb = sqlite3SchemaToIndex(db, pView->pSchema);
- pDup = sqlite3SelectDup(db, pView->pSelect, 0);
- if( pWhere ){
- SrcList *pFrom;
-
- pWhere = sqlite3ExprDup(db, pWhere, 0);
- pFrom = sqlite3SrcListAppend(db, 0, 0, 0);
- if( pFrom ){
- assert( pFrom->nSrc==1 );
- pFrom->a[0].zAlias = sqlite3DbStrDup(db, pView->zName);
- pFrom->a[0].pSelect = pDup;
- assert( pFrom->a[0].pOn==0 );
- assert( pFrom->a[0].pUsing==0 );
- }else{
- sqlite3SelectDelete(db, pDup);
- }
- pDup = sqlite3SelectNew(pParse, 0, pFrom, pWhere, 0, 0, 0, 0, 0, 0);
+ pWhere = sqlite3ExprDup(db, pWhere, 0);
+ pFrom = sqlite3SrcListAppend(db, 0, 0, 0);
+
+ if( pFrom ){
+ assert( pFrom->nSrc==1 );
+ pFrom->a[0].zName = sqlite3DbStrDup(db, pView->zName);
+ pFrom->a[0].zDatabase = sqlite3DbStrDup(db, db->aDb[iDb].zName);
+ assert( pFrom->a[0].pOn==0 );
+ assert( pFrom->a[0].pUsing==0 );
}
+
+ pSel = sqlite3SelectNew(pParse, 0, pFrom, pWhere, 0, 0, 0, 0, 0, 0);
+ if( pSel ) pSel->selFlags |= SF_Materialize;
+
sqlite3SelectDestInit(&dest, SRT_EphemTab, iCur);
- sqlite3Select(pParse, pDup, &dest);
- sqlite3SelectDelete(db, pDup);
+ sqlite3Select(pParse, pSel, &dest);
+ sqlite3SelectDelete(db, pSel);
}
#endif /* !defined(SQLITE_OMIT_VIEW) && !defined(SQLITE_OMIT_TRIGGER) */
@@ -81735,7 +85407,6 @@ SQLITE_PRIVATE Expr *sqlite3LimitWhere(
*/
if( pOrderBy && (pLimit == 0) ) {
sqlite3ErrorMsg(pParse, "ORDER BY without LIMIT on %s", zStmtType);
- pParse->parseError = 1;
goto limit_where_cleanup_2;
}
@@ -81958,9 +85629,11 @@ SQLITE_PRIVATE void sqlite3DeleteFrom(
/* Collect rowids of every row to be deleted.
*/
sqlite3VdbeAddOp2(v, OP_Null, 0, iRowSet);
- pWInfo = sqlite3WhereBegin(pParse, pTabList, pWhere,0,WHERE_DUPLICATES_OK);
+ pWInfo = sqlite3WhereBegin(
+ pParse, pTabList, pWhere, 0, 0, WHERE_DUPLICATES_OK, 0
+ );
if( pWInfo==0 ) goto delete_from_cleanup;
- regRowid = sqlite3ExprCodeGetColumn(pParse, pTab, -1, iCur, iRowid);
+ regRowid = sqlite3ExprCodeGetColumn(pParse, pTab, -1, iCur, iRowid, 0);
sqlite3VdbeAddOp2(v, OP_RowSetAdd, iRowSet, regRowid);
if( db->flags & SQLITE_CountRows ){
sqlite3VdbeAddOp2(v, OP_AddImm, memCnt, 1);
@@ -82224,7 +85897,9 @@ SQLITE_PRIVATE int sqlite3GenerateIndexKey(
}
if( doMakeRec ){
const char *zAff;
- if( pTab->pSelect || (pParse->db->flags & SQLITE_IdxRealAsInt)!=0 ){
+ if( pTab->pSelect
+ || OptimizationDisabled(pParse->db, SQLITE_IdxRealAsInt)
+ ){
zAff = 0;
}else{
zAff = sqlite3IndexAffinityStr(v, pIdx);
@@ -82256,6 +85931,8 @@ SQLITE_PRIVATE int sqlite3GenerateIndexKey(
** sqliteRegisterBuildinFunctions() found at the bottom of the file.
** All other code has file scope.
*/
+/* #include <stdlib.h> */
+/* #include <assert.h> */
/*
** Return the collating function associated with a function.
@@ -82265,6 +85942,14 @@ static CollSeq *sqlite3GetFuncCollSeq(sqlite3_context *context){
}
/*
+** Indicate that the accumulator load should be skipped on this
+** iteration of the aggregate loop.
+*/
+static void sqlite3SkipAccumulatorLoad(sqlite3_context *context){
+ context->skipFlag = 1;
+}
+
+/*
** Implementation of the non-aggregate min() and max() functions
*/
static void minmaxFunc(
@@ -82397,6 +86082,56 @@ static void absFunc(sqlite3_context *context, int argc, sqlite3_value **argv){
}
/*
+** Implementation of the instr() function.
+**
+** instr(haystack,needle) finds the first occurrence of needle
+** in haystack and returns the number of previous characters plus 1,
+** or 0 if needle does not occur within haystack.
+**
+** If both haystack and needle are BLOBs, then the result is one more than
+** the number of bytes in haystack prior to the first occurrence of needle,
+** or 0 if needle never occurs in haystack.
+*/
+static void instrFunc(
+ sqlite3_context *context,
+ int argc,
+ sqlite3_value **argv
+){
+ const unsigned char *zHaystack;
+ const unsigned char *zNeedle;
+ int nHaystack;
+ int nNeedle;
+ int typeHaystack, typeNeedle;
+ int N = 1;
+ int isText;
+
+ UNUSED_PARAMETER(argc);
+ typeHaystack = sqlite3_value_type(argv[0]);
+ typeNeedle = sqlite3_value_type(argv[1]);
+ if( typeHaystack==SQLITE_NULL || typeNeedle==SQLITE_NULL ) return;
+ nHaystack = sqlite3_value_bytes(argv[0]);
+ nNeedle = sqlite3_value_bytes(argv[1]);
+ if( typeHaystack==SQLITE_BLOB && typeNeedle==SQLITE_BLOB ){
+ zHaystack = sqlite3_value_blob(argv[0]);
+ zNeedle = sqlite3_value_blob(argv[1]);
+ isText = 0;
+ }else{
+ zHaystack = sqlite3_value_text(argv[0]);
+ zNeedle = sqlite3_value_text(argv[1]);
+ isText = 1;
+ }
+ while( nNeedle<=nHaystack && memcmp(zHaystack, zNeedle, nNeedle)!=0 ){
+ N++;
+ do{
+ nHaystack--;
+ zHaystack++;
+ }while( isText && (zHaystack[0]&0xc0)==0x80 );
+ }
+ if( nNeedle>nHaystack ) N = 0;
+ sqlite3_result_int(context, N);
+}
+
+/*
** Implementation of the substr() function.
**
** substr(x,p1,p2) returns p2 characters of x[] beginning with p1.
@@ -82568,16 +86303,15 @@ static void upperFunc(sqlite3_context *context, int argc, sqlite3_value **argv){
if( z2 ){
z1 = contextMalloc(context, ((i64)n)+1);
if( z1 ){
- memcpy(z1, z2, n+1);
- for(i=0; z1[i]; i++){
- z1[i] = (char)sqlite3Toupper(z1[i]);
+ for(i=0; i<n; i++){
+ z1[i] = (char)sqlite3Toupper(z2[i]);
}
- sqlite3_result_text(context, z1, -1, sqlite3_free);
+ sqlite3_result_text(context, z1, n, sqlite3_free);
}
}
}
static void lowerFunc(sqlite3_context *context, int argc, sqlite3_value **argv){
- u8 *z1;
+ char *z1;
const char *z2;
int i, n;
UNUSED_PARAMETER(argc);
@@ -82588,42 +86322,22 @@ static void lowerFunc(sqlite3_context *context, int argc, sqlite3_value **argv){
if( z2 ){
z1 = contextMalloc(context, ((i64)n)+1);
if( z1 ){
- memcpy(z1, z2, n+1);
- for(i=0; z1[i]; i++){
- z1[i] = sqlite3Tolower(z1[i]);
+ for(i=0; i<n; i++){
+ z1[i] = sqlite3Tolower(z2[i]);
}
- sqlite3_result_text(context, (char *)z1, -1, sqlite3_free);
+ sqlite3_result_text(context, z1, n, sqlite3_free);
}
}
}
-
-#if 0 /* This function is never used. */
-/*
-** The COALESCE() and IFNULL() functions used to be implemented as shown
-** here. But now they are implemented as VDBE code so that unused arguments
-** do not have to be computed. This legacy implementation is retained as
-** comment.
-*/
/*
-** Implementation of the IFNULL(), NVL(), and COALESCE() functions.
-** All three do the same thing. They return the first non-NULL
-** argument.
+** The COALESCE() and IFNULL() functions are implemented as VDBE code so
+** that unused argument values do not have to be computed. However, we
+** still need some kind of function implementation for this routines in
+** the function table. That function implementation will never be called
+** so it doesn't matter what the implementation is. We might as well use
+** the "version()" function as a substitute.
*/
-static void ifnullFunc(
- sqlite3_context *context,
- int argc,
- sqlite3_value **argv
-){
- int i;
- for(i=0; i<argc; i++){
- if( SQLITE_NULL!=sqlite3_value_type(argv[i]) ){
- sqlite3_result_value(context, argv[i]);
- break;
- }
- }
-}
-#endif /* NOT USED */
#define ifnullFunc versionFunc /* Substitute function - never called */
/*
@@ -82646,7 +86360,7 @@ static void randomFunc(
** 2s complement of that positive value. The end result can
** therefore be no less than -9223372036854775807.
*/
- r = -(r ^ (((sqlite3_int64)1)<<63));
+ r = -(r & LARGEST_INT64);
}
sqlite3_result_int64(context, r);
}
@@ -82742,7 +86456,7 @@ struct compareInfo {
** whereas only characters less than 0x80 do in ASCII.
*/
#if defined(SQLITE_EBCDIC)
-# define sqlite3Utf8Read(A,C) (*(A++))
+# define sqlite3Utf8Read(A) (*((*A)++))
# define GlogUpperToLower(A) A = sqlite3UpperToLower[A]
#else
# define GlogUpperToLower(A) if( !((A)&~0x7f) ){ A = sqlite3UpperToLower[A]; }
@@ -82799,18 +86513,18 @@ static int patternCompare(
u8 noCase = pInfo->noCase;
int prevEscape = 0; /* True if the previous character was 'escape' */
- while( (c = sqlite3Utf8Read(zPattern,&zPattern))!=0 ){
- if( !prevEscape && c==matchAll ){
- while( (c=sqlite3Utf8Read(zPattern,&zPattern)) == matchAll
+ while( (c = sqlite3Utf8Read(&zPattern))!=0 ){
+ if( c==matchAll && !prevEscape ){
+ while( (c=sqlite3Utf8Read(&zPattern)) == matchAll
|| c == matchOne ){
- if( c==matchOne && sqlite3Utf8Read(zString, &zString)==0 ){
+ if( c==matchOne && sqlite3Utf8Read(&zString)==0 ){
return 0;
}
}
if( c==0 ){
return 1;
}else if( c==esc ){
- c = sqlite3Utf8Read(zPattern, &zPattern);
+ c = sqlite3Utf8Read(&zPattern);
if( c==0 ){
return 0;
}
@@ -82822,25 +86536,25 @@ static int patternCompare(
}
return *zString!=0;
}
- while( (c2 = sqlite3Utf8Read(zString,&zString))!=0 ){
+ while( (c2 = sqlite3Utf8Read(&zString))!=0 ){
if( noCase ){
GlogUpperToLower(c2);
GlogUpperToLower(c);
while( c2 != 0 && c2 != c ){
- c2 = sqlite3Utf8Read(zString, &zString);
+ c2 = sqlite3Utf8Read(&zString);
GlogUpperToLower(c2);
}
}else{
while( c2 != 0 && c2 != c ){
- c2 = sqlite3Utf8Read(zString, &zString);
+ c2 = sqlite3Utf8Read(&zString);
}
}
if( c2==0 ) return 0;
if( patternCompare(zPattern,zString,pInfo,esc) ) return 1;
}
return 0;
- }else if( !prevEscape && c==matchOne ){
- if( sqlite3Utf8Read(zString, &zString)==0 ){
+ }else if( c==matchOne && !prevEscape ){
+ if( sqlite3Utf8Read(&zString)==0 ){
return 0;
}
}else if( c==matchSet ){
@@ -82848,20 +86562,20 @@ static int patternCompare(
assert( esc==0 ); /* This only occurs for GLOB, not LIKE */
seen = 0;
invert = 0;
- c = sqlite3Utf8Read(zString, &zString);
+ c = sqlite3Utf8Read(&zString);
if( c==0 ) return 0;
- c2 = sqlite3Utf8Read(zPattern, &zPattern);
+ c2 = sqlite3Utf8Read(&zPattern);
if( c2=='^' ){
invert = 1;
- c2 = sqlite3Utf8Read(zPattern, &zPattern);
+ c2 = sqlite3Utf8Read(&zPattern);
}
if( c2==']' ){
if( c==']' ) seen = 1;
- c2 = sqlite3Utf8Read(zPattern, &zPattern);
+ c2 = sqlite3Utf8Read(&zPattern);
}
while( c2 && c2!=']' ){
if( c2=='-' && zPattern[0]!=']' && zPattern[0]!=0 && prior_c>0 ){
- c2 = sqlite3Utf8Read(zPattern, &zPattern);
+ c2 = sqlite3Utf8Read(&zPattern);
if( c>=prior_c && c<=c2 ) seen = 1;
prior_c = 0;
}else{
@@ -82870,7 +86584,7 @@ static int patternCompare(
}
prior_c = c2;
}
- c2 = sqlite3Utf8Read(zPattern, &zPattern);
+ c2 = sqlite3Utf8Read(&zPattern);
}
if( c2==0 || (seen ^ invert)==0 ){
return 0;
@@ -82878,7 +86592,7 @@ static int patternCompare(
}else if( esc==c && !prevEscape ){
prevEscape = 1;
}else{
- c2 = sqlite3Utf8Read(zString, &zString);
+ c2 = sqlite3Utf8Read(&zString);
if( noCase ){
GlogUpperToLower(c);
GlogUpperToLower(c2);
@@ -82950,7 +86664,7 @@ static void likeFunc(
"ESCAPE expression must be a single character", -1);
return;
}
- escape = sqlite3Utf8Read(zEsc, &zEsc);
+ escape = sqlite3Utf8Read(&zEsc);
}
if( zA && zB ){
struct compareInfo *pInfo = sqlite3_user_data(context);
@@ -83093,8 +86807,19 @@ static void quoteFunc(sqlite3_context *context, int argc, sqlite3_value **argv){
assert( argc==1 );
UNUSED_PARAMETER(argc);
switch( sqlite3_value_type(argv[0]) ){
- case SQLITE_INTEGER:
case SQLITE_FLOAT: {
+ double r1, r2;
+ char zBuf[50];
+ r1 = sqlite3_value_double(argv[0]);
+ sqlite3_snprintf(sizeof(zBuf), zBuf, "%!.15g", r1);
+ sqlite3AtoF(zBuf, &r2, 20, SQLITE_UTF8);
+ if( r1!=r2 ){
+ sqlite3_snprintf(sizeof(zBuf), zBuf, "%!.20e", r1);
+ }
+ sqlite3_result_text(context, zBuf, -1, SQLITE_TRANSIENT);
+ break;
+ }
+ case SQLITE_INTEGER: {
sqlite3_result_value(context, argv[0]);
break;
}
@@ -83151,6 +86876,62 @@ static void quoteFunc(sqlite3_context *context, int argc, sqlite3_value **argv){
}
/*
+** The unicode() function. Return the integer unicode code-point value
+** for the first character of the input string.
+*/
+static void unicodeFunc(
+ sqlite3_context *context,
+ int argc,
+ sqlite3_value **argv
+){
+ const unsigned char *z = sqlite3_value_text(argv[0]);
+ (void)argc;
+ if( z && z[0] ) sqlite3_result_int(context, sqlite3Utf8Read(&z));
+}
+
+/*
+** The char() function takes zero or more arguments, each of which is
+** an integer. It constructs a string where each character of the string
+** is the unicode character for the corresponding integer argument.
+*/
+static void charFunc(
+ sqlite3_context *context,
+ int argc,
+ sqlite3_value **argv
+){
+ unsigned char *z, *zOut;
+ int i;
+ zOut = z = sqlite3_malloc( argc*4 );
+ if( z==0 ){
+ sqlite3_result_error_nomem(context);
+ return;
+ }
+ for(i=0; i<argc; i++){
+ sqlite3_int64 x;
+ unsigned c;
+ x = sqlite3_value_int64(argv[i]);
+ if( x<0 || x>0x10ffff ) x = 0xfffd;
+ c = (unsigned)(x & 0x1fffff);
+ if( c<0x00080 ){
+ *zOut++ = (u8)(c&0xFF);
+ }else if( c<0x00800 ){
+ *zOut++ = 0xC0 + (u8)((c>>6)&0x1F);
+ *zOut++ = 0x80 + (u8)(c & 0x3F);
+ }else if( c<0x10000 ){
+ *zOut++ = 0xE0 + (u8)((c>>12)&0x0F);
+ *zOut++ = 0x80 + (u8)((c>>6) & 0x3F);
+ *zOut++ = 0x80 + (u8)(c & 0x3F);
+ }else{
+ *zOut++ = 0xF0 + (u8)((c>>18) & 0x07);
+ *zOut++ = 0x80 + (u8)((c>>12) & 0x3F);
+ *zOut++ = 0x80 + (u8)((c>>6) & 0x3F);
+ *zOut++ = 0x80 + (u8)(c & 0x3F);
+ } \
+ }
+ sqlite3_result_text(context, (char*)z, (int)(zOut-z), sqlite3_free);
+}
+
+/*
** The hex() function. Interpret the argument as a blob. Return
** a hexadecimal rendering as text.
*/
@@ -83572,11 +87353,12 @@ static void minmaxStep(
Mem *pBest;
UNUSED_PARAMETER(NotUsed);
- if( sqlite3_value_type(argv[0])==SQLITE_NULL ) return;
pBest = (Mem *)sqlite3_aggregate_context(context, sizeof(*pBest));
if( !pBest ) return;
- if( pBest->flags ){
+ if( sqlite3_value_type(argv[0])==SQLITE_NULL ){
+ if( pBest->flags ) sqlite3SkipAccumulatorLoad(context);
+ }else if( pBest->flags ){
int max;
int cmp;
CollSeq *pColl = sqlite3GetFuncCollSeq(context);
@@ -83592,6 +87374,8 @@ static void minmaxStep(
cmp = sqlite3MemCompare(pBest, pArg, pColl);
if( (max && cmp<0) || (!max && cmp>0) ){
sqlite3VdbeMemCopy(pBest, pArg);
+ }else{
+ sqlite3SkipAccumulatorLoad(context);
}
}else{
sqlite3VdbeMemCopy(pBest, pArg);
@@ -83601,7 +87385,7 @@ static void minMaxFinalize(sqlite3_context *context){
sqlite3_value *pRes;
pRes = (sqlite3_value *)sqlite3_aggregate_context(context, 0);
if( pRes ){
- if( ALWAYS(pRes->flags) ){
+ if( pRes->flags ){
sqlite3_result_value(context, pRes);
}
sqlite3VdbeMemRelease(pRes);
@@ -83769,10 +87553,13 @@ SQLITE_PRIVATE void sqlite3RegisterGlobalFunctions(void){
FUNCTION(max, -1, 1, 1, minmaxFunc ),
FUNCTION(max, 0, 1, 1, 0 ),
AGGREGATE(max, 1, 1, 1, minmaxStep, minMaxFinalize ),
- FUNCTION(typeof, 1, 0, 0, typeofFunc ),
- FUNCTION(length, 1, 0, 0, lengthFunc ),
+ FUNCTION2(typeof, 1, 0, 0, typeofFunc, SQLITE_FUNC_TYPEOF),
+ FUNCTION2(length, 1, 0, 0, lengthFunc, SQLITE_FUNC_LENGTH),
+ FUNCTION(instr, 2, 0, 0, instrFunc ),
FUNCTION(substr, 2, 0, 0, substrFunc ),
FUNCTION(substr, 3, 0, 0, substrFunc ),
+ FUNCTION(unicode, 1, 0, 0, unicodeFunc ),
+ FUNCTION(char, -1, 0, 0, charFunc ),
FUNCTION(abs, 1, 0, 0, absFunc ),
#ifndef SQLITE_OMIT_FLOATING_POINT
FUNCTION(round, 1, 0, 0, roundFunc ),
@@ -83782,11 +87569,9 @@ SQLITE_PRIVATE void sqlite3RegisterGlobalFunctions(void){
FUNCTION(lower, 1, 0, 0, lowerFunc ),
FUNCTION(coalesce, 1, 0, 0, 0 ),
FUNCTION(coalesce, 0, 0, 0, 0 ),
-/* FUNCTION(coalesce, -1, 0, 0, ifnullFunc ), */
- {-1,SQLITE_UTF8,SQLITE_FUNC_COALESCE,0,0,ifnullFunc,0,0,"coalesce",0,0},
+ FUNCTION2(coalesce, -1, 0, 0, ifnullFunc, SQLITE_FUNC_COALESCE),
FUNCTION(hex, 1, 0, 0, hexFunc ),
-/* FUNCTION(ifnull, 2, 0, 0, ifnullFunc ), */
- {2,SQLITE_UTF8,SQLITE_FUNC_COALESCE,0,0,ifnullFunc,0,0,"ifnull",0,0},
+ FUNCTION2(ifnull, 2, 0, 0, ifnullFunc, SQLITE_FUNC_COALESCE),
FUNCTION(random, 0, 0, 0, randomFunc ),
FUNCTION(randomblob, 1, 0, 0, randomBlob ),
FUNCTION(nullif, 2, 0, 1, nullifFunc ),
@@ -83866,8 +87651,9 @@ SQLITE_PRIVATE void sqlite3RegisterGlobalFunctions(void){
** --------------------------
**
** Foreign keys in SQLite come in two flavours: deferred and immediate.
-** If an immediate foreign key constraint is violated, SQLITE_CONSTRAINT
-** is returned and the current statement transaction rolled back. If a
+** If an immediate foreign key constraint is violated,
+** SQLITE_CONSTRAINT_FOREIGNKEY is returned and the current
+** statement transaction rolled back. If a
** deferred foreign key constraint is violated, no action is taken
** immediately. However if the application attempts to commit the
** transaction before fixing the constraint violation, the attempt fails.
@@ -83931,7 +87717,8 @@ SQLITE_PRIVATE void sqlite3RegisterGlobalFunctions(void){
** Immediate constraints are usually handled similarly. The only difference
** is that the counter used is stored as part of each individual statement
** object (struct Vdbe). If, after the statement has run, its immediate
-** constraint counter is greater than zero, it returns SQLITE_CONSTRAINT
+** constraint counter is greater than zero,
+** it returns SQLITE_CONSTRAINT_FOREIGNKEY
** and the statement transaction is rolled back. An exception is an INSERT
** statement that inserts a single row only (no triggers). In this case,
** instead of using a counter, an exception is thrown immediately if the
@@ -83987,7 +87774,7 @@ SQLITE_PRIVATE void sqlite3RegisterGlobalFunctions(void){
** A foreign key constraint requires that the key columns in the parent
** table are collectively subject to a UNIQUE or PRIMARY KEY constraint.
** Given that pParent is the parent table for foreign key constraint pFKey,
-** search the schema a unique index on the parent key columns.
+** search the schema for a unique index on the parent key columns.
**
** If successful, zero is returned. If the parent key is an INTEGER PRIMARY
** KEY column, then output variable *ppIdx is set to NULL. Otherwise, *ppIdx
@@ -84023,7 +87810,7 @@ SQLITE_PRIVATE void sqlite3RegisterGlobalFunctions(void){
** into pParse. If an OOM error occurs, non-zero is returned and the
** pParse->db->mallocFailed flag is set.
*/
-static int locateFkeyIndex(
+SQLITE_PRIVATE int sqlite3FkLocateIndex(
Parse *pParse, /* Parse context to store any error in */
Table *pParent, /* Parent table of FK constraint pFKey */
FKey *pFKey, /* Foreign key to find index for */
@@ -84120,7 +87907,9 @@ static int locateFkeyIndex(
if( !pIdx ){
if( !pParse->disableTriggers ){
- sqlite3ErrorMsg(pParse, "foreign key mismatch");
+ sqlite3ErrorMsg(pParse,
+ "foreign key mismatch - \"%w\" referencing \"%w\"",
+ pFKey->pFrom->zName, pFKey->zTo);
}
sqlite3DbFree(pParse->db, aiCol);
return 1;
@@ -84269,8 +88058,8 @@ static void fkLookupParent(
** incrementing a counter. This is necessary as the VM code is being
** generated for will not open a statement transaction. */
assert( nIncr==1 );
- sqlite3HaltConstraint(
- pParse, OE_Abort, "foreign key constraint failed", P4_STATIC
+ sqlite3HaltConstraint(pParse, SQLITE_CONSTRAINT_FOREIGNKEY,
+ OE_Abort, "foreign key constraint failed", P4_STATIC
);
}else{
if( nIncr>0 && pFKey->isDeferred==0 ){
@@ -84356,12 +88145,15 @@ static void fkScanChildren(
** expression to the parent key column defaults. */
if( pIdx ){
Column *pCol;
+ const char *zColl;
iCol = pIdx->aiColumn[i];
pCol = &pTab->aCol[iCol];
if( pTab->iPKey==iCol ) iCol = -1;
pLeft->iTable = regData+iCol+1;
pLeft->affinity = pCol->affinity;
- pLeft->pColl = sqlite3LocateCollSeq(pParse, pCol->zColl);
+ zColl = pCol->zColl;
+ if( zColl==0 ) zColl = db->pDfltColl->zName;
+ pLeft = sqlite3ExprAddCollateString(pParse, pLeft, zColl);
}else{
pLeft->iTable = regData;
pLeft->affinity = SQLITE_AFF_INTEGER;
@@ -84405,7 +88197,7 @@ static void fkScanChildren(
** clause. If the constraint is not deferred, throw an exception for
** each row found. Otherwise, for deferred constraints, increment the
** deferred constraint counter by nIncr for each row selected. */
- pWInfo = sqlite3WhereBegin(pParse, pSrc, pWhere, 0, 0);
+ pWInfo = sqlite3WhereBegin(pParse, pSrc, pWhere, 0, 0, 0, 0);
if( nIncr>0 && pFKey->isDeferred==0 ){
sqlite3ParseToplevel(pParse)->mayAbort = 1;
}
@@ -84507,8 +88299,8 @@ SQLITE_PRIVATE void sqlite3FkDropTable(Parse *pParse, SrcList *pName, Table *pTa
** any modifications to the schema are made. This is because statement
** transactions are not able to rollback schema changes. */
sqlite3VdbeAddOp2(v, OP_FkIfZero, 0, sqlite3VdbeCurrentAddr(v)+2);
- sqlite3HaltConstraint(
- pParse, OE_Abort, "foreign key constraint failed", P4_STATIC
+ sqlite3HaltConstraint(pParse, SQLITE_CONSTRAINT_FOREIGNKEY,
+ OE_Abort, "foreign key constraint failed", P4_STATIC
);
if( iSkip ){
@@ -84578,8 +88370,25 @@ SQLITE_PRIVATE void sqlite3FkCheck(
}else{
pTo = sqlite3LocateTable(pParse, 0, pFKey->zTo, zDb);
}
- if( !pTo || locateFkeyIndex(pParse, pTo, pFKey, &pIdx, &aiFree) ){
+ if( !pTo || sqlite3FkLocateIndex(pParse, pTo, pFKey, &pIdx, &aiFree) ){
+ assert( isIgnoreErrors==0 || (regOld!=0 && regNew==0) );
if( !isIgnoreErrors || db->mallocFailed ) return;
+ if( pTo==0 ){
+ /* If isIgnoreErrors is true, then a table is being dropped. In this
+ ** case SQLite runs a "DELETE FROM xxx" on the table being dropped
+ ** before actually dropping it in order to check FK constraints.
+ ** If the parent table of an FK constraint on the current table is
+ ** missing, behave as if it is empty. i.e. decrement the relevant
+ ** FK counter for each row of the current table with non-NULL keys.
+ */
+ Vdbe *v = sqlite3GetVdbe(pParse);
+ int iJump = sqlite3VdbeCurrentAddr(v) + pFKey->nCol + 1;
+ for(i=0; i<pFKey->nCol; i++){
+ int iReg = pFKey->aCol[i].iFrom + regOld + 1;
+ sqlite3VdbeAddOp2(v, OP_IsNull, iReg, iJump);
+ }
+ sqlite3VdbeAddOp2(v, OP_FkCounter, pFKey->isDeferred, -1);
+ }
continue;
}
assert( pFKey->nCol==1 || (aiFree && pIdx) );
@@ -84641,7 +88450,7 @@ SQLITE_PRIVATE void sqlite3FkCheck(
continue;
}
- if( locateFkeyIndex(pParse, pTab, pFKey, &pIdx, &aiCol) ){
+ if( sqlite3FkLocateIndex(pParse, pTab, pFKey, &pIdx, &aiCol) ){
if( !isIgnoreErrors || db->mallocFailed ) return;
continue;
}
@@ -84696,7 +88505,7 @@ SQLITE_PRIVATE u32 sqlite3FkOldmask(
}
for(p=sqlite3FkReferences(pTab); p; p=p->pNextTo){
Index *pIdx = 0;
- locateFkeyIndex(pParse, pTab, p, &pIdx, 0);
+ sqlite3FkLocateIndex(pParse, pTab, p, &pIdx, 0);
if( pIdx ){
for(i=0; i<pIdx->nColumn; i++) mask |= COLUMN_MASK(pIdx->aiColumn[i]);
}
@@ -84753,7 +88562,8 @@ SQLITE_PRIVATE int sqlite3FkRequired(
int iKey;
for(iKey=0; iKey<pTab->nCol; iKey++){
Column *pCol = &pTab->aCol[iKey];
- if( (zKey ? !sqlite3StrICmp(pCol->zName, zKey) : pCol->isPrimKey) ){
+ if( (zKey ? !sqlite3StrICmp(pCol->zName, zKey)
+ : (pCol->colFlags & COLFLAG_PRIMKEY)!=0) ){
if( aChange[iKey]>=0 ) return 1;
if( iKey==pTab->iPKey && chngRowid ) return 1;
}
@@ -84821,7 +88631,7 @@ static Trigger *fkActionTrigger(
int i; /* Iterator variable */
Expr *pWhen = 0; /* WHEN clause for the trigger */
- if( locateFkeyIndex(pParse, pTab, pFKey, &pIdx, &aiCol) ) return 0;
+ if( sqlite3FkLocateIndex(pParse, pTab, pFKey, &pIdx, &aiCol) ) return 0;
assert( aiCol || pFKey->nCol==1 );
for(i=0; i<pFKey->nCol; i++){
@@ -84952,6 +88762,7 @@ static Trigger *fkActionTrigger(
fkTriggerDelete(db, pTrigger);
return 0;
}
+ assert( pStep!=0 );
switch( action ){
case OE_Restrict:
@@ -85073,7 +88884,7 @@ SQLITE_PRIVATE void sqlite3OpenTable(
int opcode /* OP_OpenRead or OP_OpenWrite */
){
Vdbe *v;
- if( IsVirtual(pTab) ) return;
+ assert( !IsVirtual(pTab) );
v = sqlite3GetVdbe(p);
assert( opcode==OP_OpenWrite || opcode==OP_OpenRead );
sqlite3TableLock(p, iDb, pTab->tnum, (opcode==OP_OpenWrite)?1:0, pTab->zName);
@@ -85095,7 +88906,7 @@ SQLITE_PRIVATE void sqlite3OpenTable(
** 'd' INTEGER
** 'e' REAL
**
-** An extra 'b' is appended to the end of the string to cover the
+** An extra 'd' is appended to the end of the string to cover the
** rowid that appears as the last column in every index.
**
** Memory for the buffer containing the column index affinity string
@@ -85123,7 +88934,7 @@ SQLITE_PRIVATE const char *sqlite3IndexAffinityStr(Vdbe *v, Index *pIdx){
for(n=0; n<pIdx->nColumn; n++){
pIdx->zColAff[n] = pTab->aCol[pIdx->aiColumn[n]].affinity;
}
- pIdx->zColAff[n++] = SQLITE_AFF_NONE;
+ pIdx->zColAff[n++] = SQLITE_AFF_INTEGER;
pIdx->zColAff[n] = 0;
}
@@ -85287,6 +89098,7 @@ SQLITE_PRIVATE void sqlite3AutoincrementBegin(Parse *pParse){
memId = p->regCtr;
assert( sqlite3SchemaMutexHeld(db, 0, pDb->pSchema) );
sqlite3OpenTable(pParse, 0, p->iDb, pDb->pSchema->pSeqTab, OP_OpenRead);
+ sqlite3VdbeAddOp3(v, OP_Null, 0, memId, memId+1);
addr = sqlite3VdbeCurrentAddr(v);
sqlite3VdbeAddOp4(v, OP_String8, 0, memId-1, 0, p->pTab->zName, 0);
sqlite3VdbeAddOp2(v, OP_Rewind, 0, addr+9);
@@ -85367,6 +89179,97 @@ SQLITE_PRIVATE void sqlite3AutoincrementEnd(Parse *pParse){
#endif /* SQLITE_OMIT_AUTOINCREMENT */
+/*
+** Generate code for a co-routine that will evaluate a subquery one
+** row at a time.
+**
+** The pSelect parameter is the subquery that the co-routine will evaluation.
+** Information about the location of co-routine and the registers it will use
+** is returned by filling in the pDest object.
+**
+** Registers are allocated as follows:
+**
+** pDest->iSDParm The register holding the next entry-point of the
+** co-routine. Run the co-routine to its next breakpoint
+** by calling "OP_Yield $X" where $X is pDest->iSDParm.
+**
+** pDest->iSDParm+1 The register holding the "completed" flag for the
+** co-routine. This register is 0 if the previous Yield
+** generated a new result row, or 1 if the subquery
+** has completed. If the Yield is called again
+** after this register becomes 1, then the VDBE will
+** halt with an SQLITE_INTERNAL error.
+**
+** pDest->iSdst First result register.
+**
+** pDest->nSdst Number of result registers.
+**
+** This routine handles all of the register allocation and fills in the
+** pDest structure appropriately.
+**
+** Here is a schematic of the generated code assuming that X is the
+** co-routine entry-point register reg[pDest->iSDParm], that EOF is the
+** completed flag reg[pDest->iSDParm+1], and R and S are the range of
+** registers that hold the result set, reg[pDest->iSdst] through
+** reg[pDest->iSdst+pDest->nSdst-1]:
+**
+** X <- A
+** EOF <- 0
+** goto B
+** A: setup for the SELECT
+** loop rows in the SELECT
+** load results into registers R..S
+** yield X
+** end loop
+** cleanup after the SELECT
+** EOF <- 1
+** yield X
+** halt-error
+** B:
+**
+** To use this subroutine, the caller generates code as follows:
+**
+** [ Co-routine generated by this subroutine, shown above ]
+** S: yield X
+** if EOF goto E
+** if skip this row, goto C
+** if terminate loop, goto E
+** deal with this row
+** C: goto S
+** E:
+*/
+SQLITE_PRIVATE int sqlite3CodeCoroutine(Parse *pParse, Select *pSelect, SelectDest *pDest){
+ int regYield; /* Register holding co-routine entry-point */
+ int regEof; /* Register holding co-routine completion flag */
+ int addrTop; /* Top of the co-routine */
+ int j1; /* Jump instruction */
+ int rc; /* Result code */
+ Vdbe *v; /* VDBE under construction */
+
+ regYield = ++pParse->nMem;
+ regEof = ++pParse->nMem;
+ v = sqlite3GetVdbe(pParse);
+ addrTop = sqlite3VdbeCurrentAddr(v);
+ sqlite3VdbeAddOp2(v, OP_Integer, addrTop+2, regYield); /* X <- A */
+ VdbeComment((v, "Co-routine entry point"));
+ sqlite3VdbeAddOp2(v, OP_Integer, 0, regEof); /* EOF <- 0 */
+ VdbeComment((v, "Co-routine completion flag"));
+ sqlite3SelectDestInit(pDest, SRT_Coroutine, regYield);
+ j1 = sqlite3VdbeAddOp2(v, OP_Goto, 0, 0);
+ rc = sqlite3Select(pParse, pSelect, pDest);
+ assert( pParse->nErr==0 || rc );
+ if( pParse->db->mallocFailed && rc==SQLITE_OK ) rc = SQLITE_NOMEM;
+ if( rc ) return rc;
+ sqlite3VdbeAddOp2(v, OP_Integer, 1, regEof); /* EOF <- 1 */
+ sqlite3VdbeAddOp1(v, OP_Yield, regYield); /* yield X */
+ sqlite3VdbeAddOp2(v, OP_Halt, SQLITE_INTERNAL, OE_Abort);
+ VdbeComment((v, "End of coroutine"));
+ sqlite3VdbeJumpHere(v, j1); /* label B: */
+ return rc;
+}
+
+
+
/* Forward declaration */
static int xferOptimization(
Parse *pParse, /* Parser context */
@@ -85615,55 +89518,16 @@ SQLITE_PRIVATE void sqlite3Insert(
** co-routine is the common header to the 3rd and 4th templates.
*/
if( pSelect ){
- /* Data is coming from a SELECT. Generate code to implement that SELECT
- ** as a co-routine. The code is common to both the 3rd and 4th
- ** templates:
- **
- ** EOF <- 0
- ** X <- A
- ** goto B
- ** A: setup for the SELECT
- ** loop over the tables in the SELECT
- ** load value into register R..R+n
- ** yield X
- ** end loop
- ** cleanup after the SELECT
- ** EOF <- 1
- ** yield X
- ** halt-error
- **
- ** On each invocation of the co-routine, it puts a single row of the
- ** SELECT result into registers dest.iMem...dest.iMem+dest.nMem-1.
- ** (These output registers are allocated by sqlite3Select().) When
- ** the SELECT completes, it sets the EOF flag stored in regEof.
- */
- int rc, j1;
-
- regEof = ++pParse->nMem;
- sqlite3VdbeAddOp2(v, OP_Integer, 0, regEof); /* EOF <- 0 */
- VdbeComment((v, "SELECT eof flag"));
- sqlite3SelectDestInit(&dest, SRT_Coroutine, ++pParse->nMem);
- addrSelect = sqlite3VdbeCurrentAddr(v)+2;
- sqlite3VdbeAddOp2(v, OP_Integer, addrSelect-1, dest.iParm);
- j1 = sqlite3VdbeAddOp2(v, OP_Goto, 0, 0);
- VdbeComment((v, "Jump over SELECT coroutine"));
-
- /* Resolve the expressions in the SELECT statement and execute it. */
- rc = sqlite3Select(pParse, pSelect, &dest);
- assert( pParse->nErr==0 || rc );
- if( rc || NEVER(pParse->nErr) || db->mallocFailed ){
- goto insert_cleanup;
- }
- sqlite3VdbeAddOp2(v, OP_Integer, 1, regEof); /* EOF <- 1 */
- sqlite3VdbeAddOp1(v, OP_Yield, dest.iParm); /* yield X */
- sqlite3VdbeAddOp2(v, OP_Halt, SQLITE_INTERNAL, OE_Abort);
- VdbeComment((v, "End of SELECT coroutine"));
- sqlite3VdbeJumpHere(v, j1); /* label B: */
+ /* Data is coming from a SELECT. Generate a co-routine to run that
+ ** SELECT. */
+ int rc = sqlite3CodeCoroutine(pParse, pSelect, &dest);
+ if( rc ) goto insert_cleanup;
- regFromSelect = dest.iMem;
+ regEof = dest.iSDParm + 1;
+ regFromSelect = dest.iSdst;
assert( pSelect->pEList );
nColumn = pSelect->pEList->nExpr;
- assert( dest.nMem==nColumn );
+ assert( dest.nSdst==nColumn );
/* Set useTempTable to TRUE if the result of the SELECT statement
** should be written into a temporary table (template 4). Set to
@@ -85699,7 +89563,7 @@ SQLITE_PRIVATE void sqlite3Insert(
regRec = sqlite3GetTempReg(pParse);
regTempRowid = sqlite3GetTempReg(pParse);
sqlite3VdbeAddOp2(v, OP_OpenEphemeral, srcTab, nColumn);
- addrTop = sqlite3VdbeAddOp1(v, OP_Yield, dest.iParm);
+ addrTop = sqlite3VdbeAddOp1(v, OP_Yield, dest.iSDParm);
addrIf = sqlite3VdbeAddOp1(v, OP_If, regEof);
sqlite3VdbeAddOp3(v, OP_MakeRecord, regFromSelect, nColumn, regRec);
sqlite3VdbeAddOp2(v, OP_NewRowid, srcTab, regTempRowid);
@@ -85836,7 +89700,7 @@ SQLITE_PRIVATE void sqlite3Insert(
** goto C
** D: ...
*/
- addrCont = sqlite3VdbeAddOp1(v, OP_Yield, dest.iParm);
+ addrCont = sqlite3VdbeAddOp1(v, OP_Yield, dest.iSDParm);
addrInsTop = sqlite3VdbeAddOp1(v, OP_If, regEof);
}
@@ -86154,7 +90018,7 @@ insert_cleanup:
** cause sqlite3_exec() to return immediately
** with SQLITE_CONSTRAINT.
**
-** any FAIL Sqlite_exec() returns immediately with a
+** any FAIL Sqlite3_exec() returns immediately with a
** return code of SQLITE_CONSTRAINT. The
** transaction is not rolled back and any
** prior changes are retained.
@@ -86204,9 +90068,11 @@ SQLITE_PRIVATE void sqlite3GenerateConstraintChecks(
int regData; /* Register containing first data column */
int iCur; /* Table cursor number */
Index *pIdx; /* Pointer to one of the indices */
+ sqlite3 *db; /* Database connection */
int seenReplace = 0; /* True if REPLACE is used to resolve INT PK conflict */
int regOldRowid = (rowidChng && isUpdate) ? rowidChng : regRowid;
+ db = pParse->db;
v = sqlite3GetVdbe(pParse);
assert( v!=0 );
assert( pTab->pSelect==0 ); /* This table is not a VIEW */
@@ -86238,8 +90104,8 @@ SQLITE_PRIVATE void sqlite3GenerateConstraintChecks(
case OE_Fail: {
char *zMsg;
sqlite3VdbeAddOp3(v, OP_HaltIfNull,
- SQLITE_CONSTRAINT, onError, regData+i);
- zMsg = sqlite3MPrintf(pParse->db, "%s.%s may not be NULL",
+ SQLITE_CONSTRAINT_NOTNULL, onError, regData+i);
+ zMsg = sqlite3MPrintf(db, "%s.%s may not be NULL",
pTab->zName, pTab->aCol[i].zName);
sqlite3VdbeChangeP4(v, -1, zMsg, P4_DYNAMIC);
break;
@@ -86261,18 +90127,28 @@ SQLITE_PRIVATE void sqlite3GenerateConstraintChecks(
/* Test all CHECK constraints
*/
#ifndef SQLITE_OMIT_CHECK
- if( pTab->pCheck && (pParse->db->flags & SQLITE_IgnoreChecks)==0 ){
- int allOk = sqlite3VdbeMakeLabel(v);
+ if( pTab->pCheck && (db->flags & SQLITE_IgnoreChecks)==0 ){
+ ExprList *pCheck = pTab->pCheck;
pParse->ckBase = regData;
- sqlite3ExprIfTrue(pParse, pTab->pCheck, allOk, SQLITE_JUMPIFNULL);
onError = overrideError!=OE_Default ? overrideError : OE_Abort;
- if( onError==OE_Ignore ){
- sqlite3VdbeAddOp2(v, OP_Goto, 0, ignoreDest);
- }else{
- if( onError==OE_Replace ) onError = OE_Abort; /* IMP: R-15569-63625 */
- sqlite3HaltConstraint(pParse, onError, 0, 0);
+ for(i=0; i<pCheck->nExpr; i++){
+ int allOk = sqlite3VdbeMakeLabel(v);
+ sqlite3ExprIfTrue(pParse, pCheck->a[i].pExpr, allOk, SQLITE_JUMPIFNULL);
+ if( onError==OE_Ignore ){
+ sqlite3VdbeAddOp2(v, OP_Goto, 0, ignoreDest);
+ }else{
+ char *zConsName = pCheck->a[i].zName;
+ if( onError==OE_Replace ) onError = OE_Abort; /* IMP: R-15569-63625 */
+ if( zConsName ){
+ zConsName = sqlite3MPrintf(db, "constraint %s failed", zConsName);
+ }else{
+ zConsName = 0;
+ }
+ sqlite3HaltConstraint(pParse, SQLITE_CONSTRAINT_CHECK,
+ onError, zConsName, P4_DYNAMIC);
+ }
+ sqlite3VdbeResolveLabel(v, allOk);
}
- sqlite3VdbeResolveLabel(v, allOk);
}
#endif /* !defined(SQLITE_OMIT_CHECK) */
@@ -86300,14 +90176,14 @@ SQLITE_PRIVATE void sqlite3GenerateConstraintChecks(
case OE_Rollback:
case OE_Abort:
case OE_Fail: {
- sqlite3HaltConstraint(
- pParse, onError, "PRIMARY KEY must be unique", P4_STATIC);
+ sqlite3HaltConstraint(pParse, SQLITE_CONSTRAINT_PRIMARYKEY,
+ onError, "PRIMARY KEY must be unique", P4_STATIC);
break;
}
case OE_Replace: {
/* If there are DELETE triggers on this table and the
** recursive-triggers flag is set, call GenerateRowDelete() to
- ** remove the conflicting row from the the table. This will fire
+ ** remove the conflicting row from the table. This will fire
** the triggers and remove both the table and index b-tree entries.
**
** Otherwise, if there are no triggers or the recursive-triggers
@@ -86328,7 +90204,7 @@ SQLITE_PRIVATE void sqlite3GenerateConstraintChecks(
** table.
*/
Trigger *pTrigger = 0;
- if( pParse->db->flags&SQLITE_RecTriggers ){
+ if( db->flags&SQLITE_RecTriggers ){
pTrigger = sqlite3TriggersExist(pParse, pTab, TK_DELETE, 0, 0);
}
if( pTrigger || sqlite3FkRequired(pParse, pTab, 0, 0) ){
@@ -86417,7 +90293,7 @@ SQLITE_PRIVATE void sqlite3GenerateConstraintChecks(
char *zErr;
sqlite3StrAccumInit(&errMsg, 0, 0, 200);
- errMsg.db = pParse->db;
+ errMsg.db = db;
zSep = pIdx->nColumn>1 ? "columns " : "column ";
for(j=0; j<pIdx->nColumn; j++){
char *zCol = pTab->aCol[pIdx->aiColumn[j]].zName;
@@ -86428,7 +90304,8 @@ SQLITE_PRIVATE void sqlite3GenerateConstraintChecks(
sqlite3StrAccumAppend(&errMsg,
pIdx->nColumn>1 ? " are not unique" : " is not unique", -1);
zErr = sqlite3StrAccumFinish(&errMsg);
- sqlite3HaltConstraint(pParse, onError, zErr, 0);
+ sqlite3HaltConstraint(pParse, SQLITE_CONSTRAINT_UNIQUE,
+ onError, zErr, 0);
sqlite3DbFree(errMsg.db, zErr);
break;
}
@@ -86441,7 +90318,7 @@ SQLITE_PRIVATE void sqlite3GenerateConstraintChecks(
Trigger *pTrigger = 0;
assert( onError==OE_Replace );
sqlite3MultiWrite(pParse);
- if( pParse->db->flags&SQLITE_RecTriggers ){
+ if( db->flags&SQLITE_RecTriggers ){
pTrigger = sqlite3TriggersExist(pParse, pTab, TK_DELETE, 0, 0);
}
sqlite3GenerateRowDelete(
@@ -86626,31 +90503,25 @@ static int xferCompatibleIndex(Index *pDest, Index *pSrc){
**
** INSERT INTO tab1 SELECT * FROM tab2;
**
-** This optimization is only attempted if
-**
-** (1) tab1 and tab2 have identical schemas including all the
-** same indices and constraints
-**
-** (2) tab1 and tab2 are different tables
-**
-** (3) There must be no triggers on tab1
+** The xfer optimization transfers raw records from tab2 over to tab1.
+** Columns are not decoded and reassemblied, which greatly improves
+** performance. Raw index records are transferred in the same way.
**
-** (4) The result set of the SELECT statement is "*"
+** The xfer optimization is only attempted if tab1 and tab2 are compatible.
+** There are lots of rules for determining compatibility - see comments
+** embedded in the code for details.
**
-** (5) The SELECT statement has no WHERE, HAVING, ORDER BY, GROUP BY,
-** or LIMIT clause.
+** This routine returns TRUE if the optimization is guaranteed to be used.
+** Sometimes the xfer optimization will only work if the destination table
+** is empty - a factor that can only be determined at run-time. In that
+** case, this routine generates code for the xfer optimization but also
+** does a test to see if the destination table is empty and jumps over the
+** xfer optimization code if the test fails. In that case, this routine
+** returns FALSE so that the caller will know to go ahead and generate
+** an unoptimized transfer. This routine also returns FALSE if there
+** is no chance that the xfer optimization can be applied.
**
-** (6) The SELECT statement is a simple (not a compound) select that
-** contains only tab2 in its FROM clause
-**
-** This method for implementing the INSERT transfers raw records from
-** tab2 over to tab1. The columns are not decoded. Raw records from
-** the indices of tab2 are transfered to tab1 as well. In so doing,
-** the resulting tab1 has much less fragmentation.
-**
-** This routine returns TRUE if the optimization is attempted. If any
-** of the conditions above fail so that the optimization should not
-** be attempted, then this routine returns FALSE.
+** This optimization is particularly useful at making VACUUM run faster.
*/
static int xferOptimization(
Parse *pParse, /* Parser context */
@@ -86687,10 +90558,8 @@ static int xferOptimization(
}
#endif
if( onError==OE_Default ){
- onError = OE_Abort;
- }
- if( onError!=OE_Abort && onError!=OE_Rollback ){
- return 0; /* Cannot do OR REPLACE or OR IGNORE or OR FAIL */
+ if( pDest->iPKey>=0 ) onError = pDest->keyConf;
+ if( onError==OE_Default ) onError = OE_Abort;
}
assert(pSelect->pSrc); /* allocated even if there is no FROM clause */
if( pSelect->pSrc->nSrc!=1 ){
@@ -86735,7 +90604,7 @@ static int xferOptimization(
** we have to check the semantics.
*/
pItem = pSelect->pSrc->a;
- pSrc = sqlite3LocateTable(pParse, 0, pItem->zName, pItem->zDatabase);
+ pSrc = sqlite3LocateTableItem(pParse, 0, pItem);
if( pSrc==0 ){
return 0; /* FROM clause does not contain a real table */
}
@@ -86779,7 +90648,7 @@ static int xferOptimization(
}
}
#ifndef SQLITE_OMIT_CHECK
- if( pDest->pCheck && sqlite3ExprCompare(pSrc->pCheck, pDest->pCheck) ){
+ if( pDest->pCheck && sqlite3ExprListCompare(pSrc->pCheck, pDest->pCheck) ){
return 0; /* Tables have different CHECK constraints. Ticket #2252 */
}
#endif
@@ -86795,14 +90664,13 @@ static int xferOptimization(
return 0;
}
#endif
+ if( (pParse->db->flags & SQLITE_CountRows)!=0 ){
+ return 0; /* xfer opt does not play well with PRAGMA count_changes */
+ }
- /* If we get this far, it means either:
- **
- ** * We can always do the transfer if the table contains an
- ** an integer primary key
- **
- ** * We can conditionally do the transfer if the destination
- ** table is empty.
+ /* If we get this far, it means that the xfer optimization is at
+ ** least a possibility, though it might only work if the destination
+ ** table (tab1) is initially empty.
*/
#ifdef SQLITE_TEST
sqlite3_xferopt_count++;
@@ -86814,16 +90682,23 @@ static int xferOptimization(
iDest = pParse->nTab++;
regAutoinc = autoIncBegin(pParse, iDbDest, pDest);
sqlite3OpenTable(pParse, iDest, iDbDest, pDest, OP_OpenWrite);
- if( (pDest->iPKey<0 && pDest->pIndex!=0) || destHasUniqueIdx ){
- /* If tables do not have an INTEGER PRIMARY KEY and there
- ** are indices to be copied and the destination is not empty,
- ** we have to disallow the transfer optimization because the
- ** the rowids might change which will mess up indexing.
+ if( (pDest->iPKey<0 && pDest->pIndex!=0) /* (1) */
+ || destHasUniqueIdx /* (2) */
+ || (onError!=OE_Abort && onError!=OE_Rollback) /* (3) */
+ ){
+ /* In some circumstances, we are able to run the xfer optimization
+ ** only if the destination table is initially empty. This code makes
+ ** that determination. Conditions under which the destination must
+ ** be empty:
+ **
+ ** (1) There is no INTEGER PRIMARY KEY but there are indices.
+ ** (If the destination is not initially empty, the rowid fields
+ ** of index entries might need to change.)
+ **
+ ** (2) The destination has a unique index. (The xfer optimization
+ ** is unable to test uniqueness.)
**
- ** Or if the destination has a UNIQUE index and is not empty,
- ** we also disallow the transfer optimization because we cannot
- ** insure that all entries in the union of DEST and SRC will be
- ** unique.
+ ** (3) onError is something other than OE_Abort and OE_Rollback.
*/
addr1 = sqlite3VdbeAddOp2(v, OP_Rewind, iDest, 0);
emptyDestTest = sqlite3VdbeAddOp2(v, OP_Goto, 0, 0);
@@ -86838,8 +90713,8 @@ static int xferOptimization(
if( pDest->iPKey>=0 ){
addr1 = sqlite3VdbeAddOp2(v, OP_Rowid, iSrc, regRowid);
addr2 = sqlite3VdbeAddOp3(v, OP_NotExists, iDest, 0, regRowid);
- sqlite3HaltConstraint(
- pParse, onError, "PRIMARY KEY must be unique", P4_STATIC);
+ sqlite3HaltConstraint(pParse, SQLITE_CONSTRAINT_PRIMARYKEY,
+ onError, "PRIMARY KEY must be unique", P4_STATIC);
sqlite3VdbeJumpHere(v, addr2);
autoIncStep(pParse, regAutoinc, regRowid);
}else if( pDest->pIndex==0 ){
@@ -87109,8 +90984,10 @@ struct sqlite3_api_routines {
int (*busy_timeout)(sqlite3*,int ms);
int (*changes)(sqlite3*);
int (*close)(sqlite3*);
- int (*collation_needed)(sqlite3*,void*,void(*)(void*,sqlite3*,int eTextRep,const char*));
- int (*collation_needed16)(sqlite3*,void*,void(*)(void*,sqlite3*,int eTextRep,const void*));
+ int (*collation_needed)(sqlite3*,void*,void(*)(void*,sqlite3*,
+ int eTextRep,const char*));
+ int (*collation_needed16)(sqlite3*,void*,void(*)(void*,sqlite3*,
+ int eTextRep,const void*));
const void * (*column_blob)(sqlite3_stmt*,int iCol);
int (*column_bytes)(sqlite3_stmt*,int iCol);
int (*column_bytes16)(sqlite3_stmt*,int iCol);
@@ -87135,10 +91012,18 @@ struct sqlite3_api_routines {
void * (*commit_hook)(sqlite3*,int(*)(void*),void*);
int (*complete)(const char*sql);
int (*complete16)(const void*sql);
- int (*create_collation)(sqlite3*,const char*,int,void*,int(*)(void*,int,const void*,int,const void*));
- int (*create_collation16)(sqlite3*,const void*,int,void*,int(*)(void*,int,const void*,int,const void*));
- int (*create_function)(sqlite3*,const char*,int,int,void*,void (*xFunc)(sqlite3_context*,int,sqlite3_value**),void (*xStep)(sqlite3_context*,int,sqlite3_value**),void (*xFinal)(sqlite3_context*));
- int (*create_function16)(sqlite3*,const void*,int,int,void*,void (*xFunc)(sqlite3_context*,int,sqlite3_value**),void (*xStep)(sqlite3_context*,int,sqlite3_value**),void (*xFinal)(sqlite3_context*));
+ int (*create_collation)(sqlite3*,const char*,int,void*,
+ int(*)(void*,int,const void*,int,const void*));
+ int (*create_collation16)(sqlite3*,const void*,int,void*,
+ int(*)(void*,int,const void*,int,const void*));
+ int (*create_function)(sqlite3*,const char*,int,int,void*,
+ void (*xFunc)(sqlite3_context*,int,sqlite3_value**),
+ void (*xStep)(sqlite3_context*,int,sqlite3_value**),
+ void (*xFinal)(sqlite3_context*));
+ int (*create_function16)(sqlite3*,const void*,int,int,void*,
+ void (*xFunc)(sqlite3_context*,int,sqlite3_value**),
+ void (*xStep)(sqlite3_context*,int,sqlite3_value**),
+ void (*xFinal)(sqlite3_context*));
int (*create_module)(sqlite3*,const char*,const sqlite3_module*,void*);
int (*data_count)(sqlite3_stmt*pStmt);
sqlite3 * (*db_handle)(sqlite3_stmt*);
@@ -87183,16 +91068,19 @@ struct sqlite3_api_routines {
void (*result_text16le)(sqlite3_context*,const void*,int,void(*)(void*));
void (*result_value)(sqlite3_context*,sqlite3_value*);
void * (*rollback_hook)(sqlite3*,void(*)(void*),void*);
- int (*set_authorizer)(sqlite3*,int(*)(void*,int,const char*,const char*,const char*,const char*),void*);
+ int (*set_authorizer)(sqlite3*,int(*)(void*,int,const char*,const char*,
+ const char*,const char*),void*);
void (*set_auxdata)(sqlite3_context*,int,void*,void (*)(void*));
char * (*snprintf)(int,char*,const char*,...);
int (*step)(sqlite3_stmt*);
- int (*table_column_metadata)(sqlite3*,const char*,const char*,const char*,char const**,char const**,int*,int*,int*);
+ int (*table_column_metadata)(sqlite3*,const char*,const char*,const char*,
+ char const**,char const**,int*,int*,int*);
void (*thread_cleanup)(void);
int (*total_changes)(sqlite3*);
void * (*trace)(sqlite3*,void(*xTrace)(void*,const char*),void*);
int (*transfer_bindings)(sqlite3_stmt*,sqlite3_stmt*);
- void * (*update_hook)(sqlite3*,void(*)(void*,int ,char const*,char const*,sqlite_int64),void*);
+ void * (*update_hook)(sqlite3*,void(*)(void*,int ,char const*,char const*,
+ sqlite_int64),void*);
void * (*user_data)(sqlite3_context*);
const void * (*value_blob)(sqlite3_value*);
int (*value_bytes)(sqlite3_value*);
@@ -87214,15 +91102,19 @@ struct sqlite3_api_routines {
int (*prepare16_v2)(sqlite3*,const void*,int,sqlite3_stmt**,const void**);
int (*clear_bindings)(sqlite3_stmt*);
/* Added by 3.4.1 */
- int (*create_module_v2)(sqlite3*,const char*,const sqlite3_module*,void*,void (*xDestroy)(void *));
+ int (*create_module_v2)(sqlite3*,const char*,const sqlite3_module*,void*,
+ void (*xDestroy)(void *));
/* Added by 3.5.0 */
int (*bind_zeroblob)(sqlite3_stmt*,int,int);
int (*blob_bytes)(sqlite3_blob*);
int (*blob_close)(sqlite3_blob*);
- int (*blob_open)(sqlite3*,const char*,const char*,const char*,sqlite3_int64,int,sqlite3_blob**);
+ int (*blob_open)(sqlite3*,const char*,const char*,const char*,sqlite3_int64,
+ int,sqlite3_blob**);
int (*blob_read)(sqlite3_blob*,void*,int,int);
int (*blob_write)(sqlite3_blob*,const void*,int,int);
- int (*create_collation_v2)(sqlite3*,const char*,int,void*,int(*)(void*,int,const void*,int,const void*),void(*)(void*));
+ int (*create_collation_v2)(sqlite3*,const char*,int,void*,
+ int(*)(void*,int,const void*,int,const void*),
+ void(*)(void*));
int (*file_control)(sqlite3*,const char*,int,void*);
sqlite3_int64 (*memory_highwater)(int);
sqlite3_int64 (*memory_used)(void);
@@ -87258,7 +91150,11 @@ struct sqlite3_api_routines {
int (*backup_step)(sqlite3_backup*,int);
const char *(*compileoption_get)(int);
int (*compileoption_used)(const char*);
- int (*create_function_v2)(sqlite3*,const char*,int,int,void*,void (*xFunc)(sqlite3_context*,int,sqlite3_value**),void (*xStep)(sqlite3_context*,int,sqlite3_value**),void (*xFinal)(sqlite3_context*),void(*xDestroy)(void*));
+ int (*create_function_v2)(sqlite3*,const char*,int,int,void*,
+ void (*xFunc)(sqlite3_context*,int,sqlite3_value**),
+ void (*xStep)(sqlite3_context*,int,sqlite3_value**),
+ void (*xFinal)(sqlite3_context*),
+ void(*xDestroy)(void*));
int (*db_config)(sqlite3*,int,...);
sqlite3_mutex *(*db_mutex)(sqlite3*);
int (*db_status)(sqlite3*,int,int*,int*,int);
@@ -87272,6 +91168,23 @@ struct sqlite3_api_routines {
int (*wal_autocheckpoint)(sqlite3*,int);
int (*wal_checkpoint)(sqlite3*,const char*);
void *(*wal_hook)(sqlite3*,int(*)(void*,sqlite3*,const char*,int),void*);
+ int (*blob_reopen)(sqlite3_blob*,sqlite3_int64);
+ int (*vtab_config)(sqlite3*,int op,...);
+ int (*vtab_on_conflict)(sqlite3*);
+ /* Version 3.7.16 and later */
+ int (*close_v2)(sqlite3*);
+ const char *(*db_filename)(sqlite3*,const char*);
+ int (*db_readonly)(sqlite3*,const char*);
+ int (*db_release_memory)(sqlite3*);
+ const char *(*errstr)(int);
+ int (*stmt_busy)(sqlite3_stmt*);
+ int (*stmt_readonly)(sqlite3_stmt*);
+ int (*stricmp)(const char*,const char*);
+ int (*uri_boolean)(const char*,const char*,int);
+ sqlite3_int64 (*uri_int64)(const char*,const char*,sqlite3_int64);
+ const char *(*uri_parameter)(const char*,const char*);
+ char *(*vsnprintf)(int,char*,const char*,va_list);
+ int (*wal_checkpoint_v2)(sqlite3*,const char*,int,int*,int*);
};
/*
@@ -87472,6 +91385,23 @@ struct sqlite3_api_routines {
#define sqlite3_wal_autocheckpoint sqlite3_api->wal_autocheckpoint
#define sqlite3_wal_checkpoint sqlite3_api->wal_checkpoint
#define sqlite3_wal_hook sqlite3_api->wal_hook
+#define sqlite3_blob_reopen sqlite3_api->blob_reopen
+#define sqlite3_vtab_config sqlite3_api->vtab_config
+#define sqlite3_vtab_on_conflict sqlite3_api->vtab_on_conflict
+/* Version 3.7.16 and later */
+#define sqlite3_close_v2 sqlite3_api->close_v2
+#define sqlite3_db_filename sqlite3_api->db_filename
+#define sqlite3_db_readonly sqlite3_api->db_readonly
+#define sqlite3_db_release_memory sqlite3_api->db_release_memory
+#define sqlite3_errstr sqlite3_api->errstr
+#define sqlite3_stmt_busy sqlite3_api->stmt_busy
+#define sqlite3_stmt_readonly sqlite3_api->stmt_readonly
+#define sqlite3_stricmp sqlite3_api->stricmp
+#define sqlite3_uri_boolean sqlite3_api->uri_boolean
+#define sqlite3_uri_int64 sqlite3_api->uri_int64
+#define sqlite3_uri_parameter sqlite3_api->uri_parameter
+#define sqlite3_uri_vsnprintf sqlite3_api->vsnprintf
+#define sqlite3_wal_checkpoint_v2 sqlite3_api->wal_checkpoint_v2
#endif /* SQLITE_CORE */
#define SQLITE_EXTENSION_INIT1 const sqlite3_api_routines *sqlite3_api = 0;
@@ -87481,6 +91411,7 @@ struct sqlite3_api_routines {
/************** End of sqlite3ext.h ******************************************/
/************** Continuing where we left off in loadext.c ********************/
+/* #include <string.h> */
#ifndef SQLITE_OMIT_LOAD_EXTENSION
@@ -87546,6 +91477,8 @@ struct sqlite3_api_routines {
# define sqlite3_create_module 0
# define sqlite3_create_module_v2 0
# define sqlite3_declare_vtab 0
+# define sqlite3_vtab_config 0
+# define sqlite3_vtab_on_conflict 0
#endif
#ifdef SQLITE_OMIT_SHARED_CACHE
@@ -87569,6 +91502,7 @@ struct sqlite3_api_routines {
#define sqlite3_blob_open 0
#define sqlite3_blob_read 0
#define sqlite3_blob_write 0
+#define sqlite3_blob_reopen 0
#endif
/*
@@ -87834,6 +91768,22 @@ static const sqlite3_api_routines sqlite3Apis = {
0,
0,
#endif
+ sqlite3_blob_reopen,
+ sqlite3_vtab_config,
+ sqlite3_vtab_on_conflict,
+ sqlite3_close_v2,
+ sqlite3_db_filename,
+ sqlite3_db_readonly,
+ sqlite3_db_release_memory,
+ sqlite3_errstr,
+ sqlite3_stmt_busy,
+ sqlite3_stmt_readonly,
+ sqlite3_stricmp,
+ sqlite3_uri_boolean,
+ sqlite3_uri_int64,
+ sqlite3_uri_parameter,
+ sqlite3_vsnprintf,
+ sqlite3_wal_checkpoint_v2
};
/*
@@ -87859,7 +91809,7 @@ static int sqlite3LoadExtension(
int (*xInit)(sqlite3*,char**,const sqlite3_api_routines*);
char *zErrmsg = 0;
void **aHandle;
- const int nMsg = 300;
+ int nMsg = 300 + sqlite3Strlen30(zFile);
if( pzErrMsg ) *pzErrMsg = 0;
@@ -87896,6 +91846,7 @@ static int sqlite3LoadExtension(
sqlite3OsDlSym(pVfs, handle, zProc);
if( xInit==0 ){
if( pzErrMsg ){
+ nMsg += sqlite3Strlen30(zProc);
*pzErrMsg = zErrmsg = sqlite3_malloc(nMsg);
if( zErrmsg ){
sqlite3_snprintf(nMsg, zErrmsg,
@@ -88080,6 +92031,7 @@ SQLITE_API void sqlite3_reset_auto_extension(void){
SQLITE_PRIVATE void sqlite3AutoLoadExtensions(sqlite3 *db){
int i;
int go = 1;
+ int rc;
int (*xInit)(sqlite3*,char**,const sqlite3_api_routines*);
wsdAutoextInit;
@@ -88102,8 +92054,8 @@ SQLITE_PRIVATE void sqlite3AutoLoadExtensions(sqlite3 *db){
}
sqlite3_mutex_leave(mutex);
zErrmsg = 0;
- if( xInit && xInit(db, &zErrmsg, &sqlite3Apis) ){
- sqlite3Error(db, SQLITE_ERROR,
+ if( xInit && (rc = xInit(db, &zErrmsg, &sqlite3Apis))!=0 ){
+ sqlite3Error(db, rc,
"automatic extension loading failed: %s", zErrmsg);
go = 0;
}
@@ -88130,14 +92082,15 @@ SQLITE_PRIVATE void sqlite3AutoLoadExtensions(sqlite3 *db){
/*
** Interpret the given string as a safety level. Return 0 for OFF,
** 1 for ON or NORMAL and 2 for FULL. Return 1 for an empty or
-** unrecognized string argument.
+** unrecognized string argument. The FULL option is disallowed
+** if the omitFull parameter it 1.
**
** Note that the values returned are one less that the values that
** should be passed into sqlite3BtreeSetSafetyLevel(). The is done
** to support legacy SQL code. The safety level used to be boolean
** and older scripts may have used numbers 0 for OFF and 1 for ON.
*/
-static u8 getSafetyLevel(const char *z){
+static u8 getSafetyLevel(const char *z, int omitFull, int dflt){
/* 123456789 123456789 */
static const char zText[] = "onoffalseyestruefull";
static const u8 iOffset[] = {0, 1, 2, 4, 9, 12, 16};
@@ -88148,19 +92101,19 @@ static u8 getSafetyLevel(const char *z){
return (u8)sqlite3Atoi(z);
}
n = sqlite3Strlen30(z);
- for(i=0; i<ArraySize(iLength); i++){
+ for(i=0; i<ArraySize(iLength)-omitFull; i++){
if( iLength[i]==n && sqlite3StrNICmp(&zText[iOffset[i]],z,n)==0 ){
return iValue[i];
}
}
- return 1;
+ return dflt;
}
/*
** Interpret the given string as a boolean value.
*/
-SQLITE_PRIVATE u8 sqlite3GetBoolean(const char *z){
- return getSafetyLevel(z)&1;
+SQLITE_PRIVATE u8 sqlite3GetBoolean(const char *z, int dflt){
+ return getSafetyLevel(z,1,dflt)!=0;
}
/* The sqlite3GetBoolean() function is used by other modules but the
@@ -88231,7 +92184,7 @@ static int invalidateTempStorage(Parse *pParse){
}
sqlite3BtreeClose(db->aDb[1].pBt);
db->aDb[1].pBt = 0;
- sqlite3ResetInternalSchema(db, -1);
+ sqlite3ResetAllSchemasOfConnection(db);
}
return SQLITE_OK;
}
@@ -88297,13 +92250,15 @@ static int flagPragma(Parse *pParse, const char *zLeft, const char *zRight){
{ "sql_trace", SQLITE_SqlTrace },
{ "vdbe_listing", SQLITE_VdbeListing },
{ "vdbe_trace", SQLITE_VdbeTrace },
+ { "vdbe_addoptrace", SQLITE_VdbeAddopTrace},
+ { "vdbe_debug", SQLITE_SqlTrace | SQLITE_VdbeListing
+ | SQLITE_VdbeTrace },
#endif
#ifndef SQLITE_OMIT_CHECK
{ "ignore_check_constraints", SQLITE_IgnoreChecks },
#endif
/* The following is VERY experimental */
{ "writable_schema", SQLITE_WriteSchema|SQLITE_RecoveryMode },
- { "omit_readlock", SQLITE_NoReadlock },
/* TODO: Maybe it shouldn't be possible to change the ReadUncommitted
** flag if there are any active statements. */
@@ -88335,7 +92290,7 @@ static int flagPragma(Parse *pParse, const char *zLeft, const char *zRight){
mask &= ~(SQLITE_ForeignKeys);
}
- if( sqlite3GetBoolean(zRight) ){
+ if( sqlite3GetBoolean(zRight, 0) ){
db->flags |= mask;
}else{
db->flags &= ~mask;
@@ -88426,9 +92381,12 @@ SQLITE_PRIVATE void sqlite3Pragma(
const char *zDb = 0; /* The database name */
Token *pId; /* Pointer to <id> token */
int iDb; /* Database index for <database> */
- sqlite3 *db = pParse->db;
- Db *pDb;
- Vdbe *v = pParse->pVdbe = sqlite3VdbeCreate(db);
+ char *aFcntl[4]; /* Argument to SQLITE_FCNTL_PRAGMA */
+ int rc; /* return value form SQLITE_FCNTL_PRAGMA */
+ sqlite3 *db = pParse->db; /* The database connection */
+ Db *pDb; /* The specific database being pragmaed */
+ Vdbe *v = pParse->pVdbe = sqlite3VdbeCreate(db); /* Prepared statement */
+
if( v==0 ) return;
sqlite3VdbeRunOnlyOnce(v);
pParse->nMem = 2;
@@ -88459,8 +92417,37 @@ SQLITE_PRIVATE void sqlite3Pragma(
if( sqlite3AuthCheck(pParse, SQLITE_PRAGMA, zLeft, zRight, zDb) ){
goto pragma_out;
}
+
+ /* Send an SQLITE_FCNTL_PRAGMA file-control to the underlying VFS
+ ** connection. If it returns SQLITE_OK, then assume that the VFS
+ ** handled the pragma and generate a no-op prepared statement.
+ */
+ aFcntl[0] = 0;
+ aFcntl[1] = zLeft;
+ aFcntl[2] = zRight;
+ aFcntl[3] = 0;
+ db->busyHandler.nBusy = 0;
+ rc = sqlite3_file_control(db, zDb, SQLITE_FCNTL_PRAGMA, (void*)aFcntl);
+ if( rc==SQLITE_OK ){
+ if( aFcntl[0] ){
+ int mem = ++pParse->nMem;
+ sqlite3VdbeAddOp4(v, OP_String8, 0, mem, 0, aFcntl[0], 0);
+ sqlite3VdbeSetNumCols(v, 1);
+ sqlite3VdbeSetColName(v, 0, COLNAME_NAME, "result", SQLITE_STATIC);
+ sqlite3VdbeAddOp2(v, OP_ResultRow, mem, 1);
+ sqlite3_free(aFcntl[0]);
+ }
+ }else if( rc!=SQLITE_NOTFOUND ){
+ if( aFcntl[0] ){
+ sqlite3ErrorMsg(pParse, "%s", aFcntl[0]);
+ sqlite3_free(aFcntl[0]);
+ }
+ pParse->nErr++;
+ pParse->rc = rc;
+ }else
+
-#ifndef SQLITE_OMIT_PAGER_PRAGMAS
+#if !defined(SQLITE_OMIT_PAGER_PRAGMAS) && !defined(SQLITE_OMIT_DEPRECATED)
/*
** PRAGMA [database.]default_cache_size
** PRAGMA [database.]default_cache_size=N
@@ -88509,7 +92496,9 @@ SQLITE_PRIVATE void sqlite3Pragma(
sqlite3BtreeSetCacheSize(pDb->pBt, pDb->pSchema->cache_size);
}
}else
+#endif /* !SQLITE_OMIT_PAGER_PRAGMAS && !SQLITE_OMIT_DEPRECATED */
+#if !defined(SQLITE_OMIT_PAGER_PRAGMAS)
/*
** PRAGMA [database.]page_size
** PRAGMA [database.]page_size=N
@@ -88530,7 +92519,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
** buffer that the pager module resizes using sqlite3_realloc().
*/
db->nextPagesize = sqlite3Atoi(zRight);
- if( SQLITE_NOMEM==sqlite3BtreeSetPageSize(pBt, db->nextPagesize, -1, 0) ){
+ if( SQLITE_NOMEM==sqlite3BtreeSetPageSize(pBt, db->nextPagesize,-1,0) ){
db->mallocFailed = 1;
}
}
@@ -88549,7 +92538,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
int b = -1;
assert( pBt!=0 );
if( zRight ){
- b = sqlite3GetBoolean(zRight);
+ b = sqlite3GetBoolean(zRight, 0);
}
if( pId2->n==0 && b>=0 ){
int ii;
@@ -88570,6 +92559,10 @@ SQLITE_PRIVATE void sqlite3Pragma(
** second form attempts to change this setting. Both
** forms return the current setting.
**
+ ** The absolute value of N is used. This is undocumented and might
+ ** change. The only purpose is to provide an easy way to test
+ ** the sqlite3AbsInt32() function.
+ **
** PRAGMA [database.]page_count
**
** Return the number of pages in the specified database.
@@ -88581,10 +92574,11 @@ SQLITE_PRIVATE void sqlite3Pragma(
if( sqlite3ReadSchema(pParse) ) goto pragma_out;
sqlite3CodeVerifySchema(pParse, iDb);
iReg = ++pParse->nMem;
- if( zLeft[0]=='p' ){
+ if( sqlite3Tolower(zLeft[0])=='p' ){
sqlite3VdbeAddOp2(v, OP_Pagecount, iDb, iReg);
}else{
- sqlite3VdbeAddOp3(v, OP_MaxPgcnt, iDb, iReg, sqlite3Atoi(zRight));
+ sqlite3VdbeAddOp3(v, OP_MaxPgcnt, iDb, iReg,
+ sqlite3AbsInt32(sqlite3Atoi(zRight)));
}
sqlite3VdbeAddOp2(v, OP_ResultRow, iReg, 1);
sqlite3VdbeSetNumCols(v, 1);
@@ -88647,8 +92641,10 @@ SQLITE_PRIVATE void sqlite3Pragma(
int eMode; /* One of the PAGER_JOURNALMODE_XXX symbols */
int ii; /* Loop counter */
- /* Force the schema to be loaded on all databases. This cases all
- ** database files to be opened and the journal_modes set. */
+ /* Force the schema to be loaded on all databases. This causes all
+ ** database files to be opened and the journal_modes set. This is
+ ** necessary because subsequent processing must know if the databases
+ ** are in WAL mode. */
if( sqlite3ReadSchema(pParse) ){
goto pragma_out;
}
@@ -88737,7 +92733,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
** creates the database file. It is important that it is created
** as an auto-vacuum capable db.
*/
- int rc = sqlite3BtreeSetAutoVacuum(pBt, eAuto);
+ rc = sqlite3BtreeSetAutoVacuum(pBt, eAuto);
if( rc==SQLITE_OK && (eAuto==1 || eAuto==2) ){
/* When setting the auto_vacuum mode to either "full" or
** "incremental", write the value of meta[6] in the database
@@ -88796,14 +92792,11 @@ SQLITE_PRIVATE void sqlite3Pragma(
** PRAGMA [database.]cache_size=N
**
** The first form reports the current local setting for the
- ** page cache size. The local setting can be different from
- ** the persistent cache size value that is stored in the database
- ** file itself. The value returned is the maximum number of
- ** pages in the page cache. The second form sets the local
- ** page cache size value. It does not change the persistent
- ** cache size stored on the disk so the cache size will revert
- ** to its default value when the database is closed and reopened.
- ** N should be a positive integer.
+ ** page cache size. The second form sets the local
+ ** page cache size value. If N is positive then that is the
+ ** number of pages in the cache. If N is negative, then the
+ ** number of pages is adjusted so that the cache uses -N kibibytes
+ ** of memory.
*/
if( sqlite3StrICmp(zLeft,"cache_size")==0 ){
if( sqlite3ReadSchema(pParse) ) goto pragma_out;
@@ -88811,7 +92804,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
if( !zRight ){
returnSingleInt(pParse, "cache_size", pDb->pSchema->cache_size);
}else{
- int size = sqlite3AbsInt32(sqlite3Atoi(zRight));
+ int size = sqlite3Atoi(zRight);
pDb->pSchema->cache_size = size;
sqlite3BtreeSetCacheSize(pDb->pBt, pDb->pSchema->cache_size);
}
@@ -88858,7 +92851,6 @@ SQLITE_PRIVATE void sqlite3Pragma(
}else{
#ifndef SQLITE_OMIT_WSD
if( zRight[0] ){
- int rc;
int res;
rc = sqlite3OsAccess(db->pVfs, zRight, SQLITE_ACCESS_READWRITE, &res);
if( rc!=SQLITE_OK || res==0 ){
@@ -88882,6 +92874,50 @@ SQLITE_PRIVATE void sqlite3Pragma(
}
}else
+#if SQLITE_OS_WIN
+ /*
+ ** PRAGMA data_store_directory
+ ** PRAGMA data_store_directory = ""|"directory_name"
+ **
+ ** Return or set the local value of the data_store_directory flag. Changing
+ ** the value sets a specific directory to be used for database files that
+ ** were specified with a relative pathname. Setting to a null string reverts
+ ** to the default database directory, which for database files specified with
+ ** a relative path will probably be based on the current directory for the
+ ** process. Database file specified with an absolute path are not impacted
+ ** by this setting, regardless of its value.
+ **
+ */
+ if( sqlite3StrICmp(zLeft, "data_store_directory")==0 ){
+ if( !zRight ){
+ if( sqlite3_data_directory ){
+ sqlite3VdbeSetNumCols(v, 1);
+ sqlite3VdbeSetColName(v, 0, COLNAME_NAME,
+ "data_store_directory", SQLITE_STATIC);
+ sqlite3VdbeAddOp4(v, OP_String8, 0, 1, 0, sqlite3_data_directory, 0);
+ sqlite3VdbeAddOp2(v, OP_ResultRow, 1, 1);
+ }
+ }else{
+#ifndef SQLITE_OMIT_WSD
+ if( zRight[0] ){
+ int res;
+ rc = sqlite3OsAccess(db->pVfs, zRight, SQLITE_ACCESS_READWRITE, &res);
+ if( rc!=SQLITE_OK || res==0 ){
+ sqlite3ErrorMsg(pParse, "not a writable directory");
+ goto pragma_out;
+ }
+ }
+ sqlite3_free(sqlite3_data_directory);
+ if( zRight[0] ){
+ sqlite3_data_directory = sqlite3_mprintf("%s", zRight);
+ }else{
+ sqlite3_data_directory = 0;
+ }
+#endif /* SQLITE_OMIT_WSD */
+ }
+ }else
+#endif
+
#if !defined(SQLITE_ENABLE_LOCKING_STYLE)
# if defined(__APPLE__)
# define SQLITE_ENABLE_LOCKING_STYLE 1
@@ -88903,7 +92939,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
Pager *pPager = sqlite3BtreePager(pDb->pBt);
char *proxy_file_path = NULL;
sqlite3_file *pFile = sqlite3PagerFile(pPager);
- sqlite3OsFileControl(pFile, SQLITE_GET_LOCKPROXYFILE,
+ sqlite3OsFileControlHint(pFile, SQLITE_GET_LOCKPROXYFILE,
&proxy_file_path);
if( proxy_file_path ){
@@ -88950,7 +92986,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
sqlite3ErrorMsg(pParse,
"Safety level may not be changed inside a transaction");
}else{
- pDb->safety_level = getSafetyLevel(zRight)+1;
+ pDb->safety_level = getSafetyLevel(zRight,0,1)+1;
}
}
}else
@@ -88981,11 +93017,14 @@ SQLITE_PRIVATE void sqlite3Pragma(
if( sqlite3ReadSchema(pParse) ) goto pragma_out;
pTab = sqlite3FindTable(db, zRight, zDb);
if( pTab ){
- int i;
+ int i, k;
int nHidden = 0;
Column *pCol;
+ Index *pPk;
+ for(pPk=pTab->pIndex; pPk && pPk->autoIndex!=2; pPk=pPk->pNext){}
sqlite3VdbeSetNumCols(v, 6);
pParse->nMem = 6;
+ sqlite3CodeVerifySchema(pParse, iDb);
sqlite3VdbeSetColName(v, 0, COLNAME_NAME, "cid", SQLITE_STATIC);
sqlite3VdbeSetColName(v, 1, COLNAME_NAME, "name", SQLITE_STATIC);
sqlite3VdbeSetColName(v, 2, COLNAME_NAME, "type", SQLITE_STATIC);
@@ -89008,7 +93047,14 @@ SQLITE_PRIVATE void sqlite3Pragma(
}else{
sqlite3VdbeAddOp2(v, OP_Null, 0, 5);
}
- sqlite3VdbeAddOp2(v, OP_Integer, pCol->isPrimKey, 6);
+ if( (pCol->colFlags & COLFLAG_PRIMKEY)==0 ){
+ k = 0;
+ }else if( pPk==0 ){
+ k = 1;
+ }else{
+ for(k=1; ALWAYS(k<=pTab->nCol) && pPk->aiColumn[k-1]!=i; k++){}
+ }
+ sqlite3VdbeAddOp2(v, OP_Integer, k, 6);
sqlite3VdbeAddOp2(v, OP_ResultRow, 1, 6);
}
}
@@ -89024,6 +93070,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
pTab = pIdx->pTable;
sqlite3VdbeSetNumCols(v, 3);
pParse->nMem = 3;
+ sqlite3CodeVerifySchema(pParse, iDb);
sqlite3VdbeSetColName(v, 0, COLNAME_NAME, "seqno", SQLITE_STATIC);
sqlite3VdbeSetColName(v, 1, COLNAME_NAME, "cid", SQLITE_STATIC);
sqlite3VdbeSetColName(v, 2, COLNAME_NAME, "name", SQLITE_STATIC);
@@ -89050,6 +93097,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
int i = 0;
sqlite3VdbeSetNumCols(v, 3);
pParse->nMem = 3;
+ sqlite3CodeVerifySchema(pParse, iDb);
sqlite3VdbeSetColName(v, 0, COLNAME_NAME, "seq", SQLITE_STATIC);
sqlite3VdbeSetColName(v, 1, COLNAME_NAME, "name", SQLITE_STATIC);
sqlite3VdbeSetColName(v, 2, COLNAME_NAME, "unique", SQLITE_STATIC);
@@ -89113,6 +93161,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
int i = 0;
sqlite3VdbeSetNumCols(v, 8);
pParse->nMem = 8;
+ sqlite3CodeVerifySchema(pParse, iDb);
sqlite3VdbeSetColName(v, 0, COLNAME_NAME, "id", SQLITE_STATIC);
sqlite3VdbeSetColName(v, 1, COLNAME_NAME, "seq", SQLITE_STATIC);
sqlite3VdbeSetColName(v, 2, COLNAME_NAME, "table", SQLITE_STATIC);
@@ -89146,10 +93195,126 @@ SQLITE_PRIVATE void sqlite3Pragma(
}else
#endif /* !defined(SQLITE_OMIT_FOREIGN_KEY) */
+#ifndef SQLITE_OMIT_FOREIGN_KEY
+#ifndef SQLITE_OMIT_TRIGGER
+ if( sqlite3StrICmp(zLeft, "foreign_key_check")==0 ){
+ FKey *pFK; /* A foreign key constraint */
+ Table *pTab; /* Child table contain "REFERENCES" keyword */
+ Table *pParent; /* Parent table that child points to */
+ Index *pIdx; /* Index in the parent table */
+ int i; /* Loop counter: Foreign key number for pTab */
+ int j; /* Loop counter: Field of the foreign key */
+ HashElem *k; /* Loop counter: Next table in schema */
+ int x; /* result variable */
+ int regResult; /* 3 registers to hold a result row */
+ int regKey; /* Register to hold key for checking the FK */
+ int regRow; /* Registers to hold a row from pTab */
+ int addrTop; /* Top of a loop checking foreign keys */
+ int addrOk; /* Jump here if the key is OK */
+ int *aiCols; /* child to parent column mapping */
+
+ if( sqlite3ReadSchema(pParse) ) goto pragma_out;
+ regResult = pParse->nMem+1;
+ pParse->nMem += 4;
+ regKey = ++pParse->nMem;
+ regRow = ++pParse->nMem;
+ v = sqlite3GetVdbe(pParse);
+ sqlite3VdbeSetNumCols(v, 4);
+ sqlite3VdbeSetColName(v, 0, COLNAME_NAME, "table", SQLITE_STATIC);
+ sqlite3VdbeSetColName(v, 1, COLNAME_NAME, "rowid", SQLITE_STATIC);
+ sqlite3VdbeSetColName(v, 2, COLNAME_NAME, "parent", SQLITE_STATIC);
+ sqlite3VdbeSetColName(v, 3, COLNAME_NAME, "fkid", SQLITE_STATIC);
+ sqlite3CodeVerifySchema(pParse, iDb);
+ k = sqliteHashFirst(&db->aDb[iDb].pSchema->tblHash);
+ while( k ){
+ if( zRight ){
+ pTab = sqlite3LocateTable(pParse, 0, zRight, zDb);
+ k = 0;
+ }else{
+ pTab = (Table*)sqliteHashData(k);
+ k = sqliteHashNext(k);
+ }
+ if( pTab==0 || pTab->pFKey==0 ) continue;
+ sqlite3TableLock(pParse, iDb, pTab->tnum, 0, pTab->zName);
+ if( pTab->nCol+regRow>pParse->nMem ) pParse->nMem = pTab->nCol + regRow;
+ sqlite3OpenTable(pParse, 0, iDb, pTab, OP_OpenRead);
+ sqlite3VdbeAddOp4(v, OP_String8, 0, regResult, 0, pTab->zName,
+ P4_TRANSIENT);
+ for(i=1, pFK=pTab->pFKey; pFK; i++, pFK=pFK->pNextFrom){
+ pParent = sqlite3LocateTable(pParse, 0, pFK->zTo, zDb);
+ if( pParent==0 ) break;
+ pIdx = 0;
+ sqlite3TableLock(pParse, iDb, pParent->tnum, 0, pParent->zName);
+ x = sqlite3FkLocateIndex(pParse, pParent, pFK, &pIdx, 0);
+ if( x==0 ){
+ if( pIdx==0 ){
+ sqlite3OpenTable(pParse, i, iDb, pParent, OP_OpenRead);
+ }else{
+ KeyInfo *pKey = sqlite3IndexKeyinfo(pParse, pIdx);
+ sqlite3VdbeAddOp3(v, OP_OpenRead, i, pIdx->tnum, iDb);
+ sqlite3VdbeChangeP4(v, -1, (char*)pKey, P4_KEYINFO_HANDOFF);
+ }
+ }else{
+ k = 0;
+ break;
+ }
+ }
+ if( pFK ) break;
+ if( pParse->nTab<i ) pParse->nTab = i;
+ addrTop = sqlite3VdbeAddOp1(v, OP_Rewind, 0);
+ for(i=1, pFK=pTab->pFKey; pFK; i++, pFK=pFK->pNextFrom){
+ pParent = sqlite3LocateTable(pParse, 0, pFK->zTo, zDb);
+ assert( pParent!=0 );
+ pIdx = 0;
+ aiCols = 0;
+ x = sqlite3FkLocateIndex(pParse, pParent, pFK, &pIdx, &aiCols);
+ assert( x==0 );
+ addrOk = sqlite3VdbeMakeLabel(v);
+ if( pIdx==0 ){
+ int iKey = pFK->aCol[0].iFrom;
+ assert( iKey>=0 && iKey<pTab->nCol );
+ if( iKey!=pTab->iPKey ){
+ sqlite3VdbeAddOp3(v, OP_Column, 0, iKey, regRow);
+ sqlite3ColumnDefault(v, pTab, iKey, regRow);
+ sqlite3VdbeAddOp2(v, OP_IsNull, regRow, addrOk);
+ sqlite3VdbeAddOp2(v, OP_MustBeInt, regRow,
+ sqlite3VdbeCurrentAddr(v)+3);
+ }else{
+ sqlite3VdbeAddOp2(v, OP_Rowid, 0, regRow);
+ }
+ sqlite3VdbeAddOp3(v, OP_NotExists, i, 0, regRow);
+ sqlite3VdbeAddOp2(v, OP_Goto, 0, addrOk);
+ sqlite3VdbeJumpHere(v, sqlite3VdbeCurrentAddr(v)-2);
+ }else{
+ for(j=0; j<pFK->nCol; j++){
+ sqlite3ExprCodeGetColumnOfTable(v, pTab, 0,
+ aiCols ? aiCols[j] : pFK->aCol[0].iFrom, regRow+j);
+ sqlite3VdbeAddOp2(v, OP_IsNull, regRow+j, addrOk);
+ }
+ sqlite3VdbeAddOp3(v, OP_MakeRecord, regRow, pFK->nCol, regKey);
+ sqlite3VdbeChangeP4(v, -1,
+ sqlite3IndexAffinityStr(v,pIdx), P4_TRANSIENT);
+ sqlite3VdbeAddOp4Int(v, OP_Found, i, addrOk, regKey, 0);
+ }
+ sqlite3VdbeAddOp2(v, OP_Rowid, 0, regResult+1);
+ sqlite3VdbeAddOp4(v, OP_String8, 0, regResult+2, 0,
+ pFK->zTo, P4_TRANSIENT);
+ sqlite3VdbeAddOp2(v, OP_Integer, i-1, regResult+3);
+ sqlite3VdbeAddOp2(v, OP_ResultRow, regResult, 4);
+ sqlite3VdbeResolveLabel(v, addrOk);
+ sqlite3DbFree(db, aiCols);
+ }
+ sqlite3VdbeAddOp2(v, OP_Next, 0, addrTop+1);
+ sqlite3VdbeJumpHere(v, addrTop);
+ }
+ }else
+#endif /* !defined(SQLITE_OMIT_TRIGGER) */
+#endif /* !defined(SQLITE_OMIT_FOREIGN_KEY) */
+
#ifndef NDEBUG
if( sqlite3StrICmp(zLeft, "parser_trace")==0 ){
if( zRight ){
- if( sqlite3GetBoolean(zRight) ){
+ if( sqlite3GetBoolean(zRight, 0) ){
sqlite3ParserTrace(stderr, "parser: ");
}else{
sqlite3ParserTrace(0, 0);
@@ -89163,7 +93328,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
*/
if( sqlite3StrICmp(zLeft, "case_sensitive_like")==0 ){
if( zRight ){
- sqlite3RegisterLikeFunctions(db, sqlite3GetBoolean(zRight));
+ sqlite3RegisterLikeFunctions(db, sqlite3GetBoolean(zRight, 0));
}
}else
@@ -89192,7 +93357,20 @@ SQLITE_PRIVATE void sqlite3Pragma(
{ OP_ResultRow, 3, 1, 0},
};
- int isQuick = (zLeft[0]=='q');
+ int isQuick = (sqlite3Tolower(zLeft[0])=='q');
+
+ /* If the PRAGMA command was of the form "PRAGMA <db>.integrity_check",
+ ** then iDb is set to the index of the database identified by <db>.
+ ** In this case, the integrity of database iDb only is verified by
+ ** the VDBE created below.
+ **
+ ** Otherwise, if the command was simply "PRAGMA integrity_check" (or
+ ** "PRAGMA quick_check"), then iDb is set to 0. In this case, set iDb
+ ** to -1 here, to indicate that the VDBE should verify the integrity
+ ** of all attached databases. */
+ assert( iDb>=0 );
+ assert( iDb==0 || pId2->z );
+ if( pId2->z==0 ) iDb = -1;
/* Initialize the VDBE program */
if( sqlite3ReadSchema(pParse) ) goto pragma_out;
@@ -89217,6 +93395,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
int cnt = 0;
if( OMIT_TEMPDB && i==1 ) continue;
+ if( iDb>=0 && i!=iDb ) continue;
sqlite3CodeVerifySchema(pParse, i);
addr = sqlite3VdbeAddOp1(v, OP_IfPos, 1); /* Halt if out of errors */
@@ -89228,7 +93407,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
** Begin by filling registers 2, 3, ... with the root pages numbers
** for all tables and indices in the database.
*/
- assert( sqlite3SchemaMutexHeld(db, iDb, 0) );
+ assert( sqlite3SchemaMutexHeld(db, i, 0) );
pTbls = &db->aDb[i].pSchema->tblHash;
for(x=sqliteHashFirst(pTbls); x; x=sqliteHashNext(x)){
Table *pTab = sqliteHashData(x);
@@ -89253,7 +93432,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
sqlite3VdbeAddOp4(v, OP_String8, 0, 3, 0,
sqlite3MPrintf(db, "*** in database %s ***\n", db->aDb[i].zName),
P4_DYNAMIC);
- sqlite3VdbeAddOp3(v, OP_Move, 2, 4, 1);
+ sqlite3VdbeAddOp2(v, OP_Move, 2, 4);
sqlite3VdbeAddOp3(v, OP_Concat, 4, 3, 2);
sqlite3VdbeAddOp2(v, OP_ResultRow, 2, 1);
sqlite3VdbeJumpHere(v, addr);
@@ -89546,6 +93725,32 @@ SQLITE_PRIVATE void sqlite3Pragma(
}else
#endif
+ /*
+ ** PRAGMA shrink_memory
+ **
+ ** This pragma attempts to free as much memory as possible from the
+ ** current database connection.
+ */
+ if( sqlite3StrICmp(zLeft, "shrink_memory")==0 ){
+ sqlite3_db_release_memory(db);
+ }else
+
+ /*
+ ** PRAGMA busy_timeout
+ ** PRAGMA busy_timeout = N
+ **
+ ** Call sqlite3_busy_timeout(db, N). Return the current timeout value
+ ** if one is set. If no busy handler or a different busy handler is set
+ ** then 0 is returned. Setting the busy_timeout to 0 or negative
+ ** disables the timeout.
+ */
+ if( sqlite3StrICmp(zLeft, "busy_timeout")==0 ){
+ if( zRight ){
+ sqlite3_busy_timeout(db, sqlite3Atoi(zRight));
+ }
+ returnSingleInt(pParse, "timeout", db->busyTimeout);
+ }else
+
#if defined(SQLITE_DEBUG) || defined(SQLITE_TEST)
/*
** Report the current state of file logs for all databases
@@ -89561,13 +93766,12 @@ SQLITE_PRIVATE void sqlite3Pragma(
sqlite3VdbeSetColName(v, 1, COLNAME_NAME, "status", SQLITE_STATIC);
for(i=0; i<db->nDb; i++){
Btree *pBt;
- Pager *pPager;
const char *zState = "unknown";
int j;
if( db->aDb[i].zName==0 ) continue;
sqlite3VdbeAddOp4(v, OP_String8, 0, 1, 0, db->aDb[i].zName, P4_STATIC);
pBt = db->aDb[i].pBt;
- if( pBt==0 || (pPager = sqlite3BtreePager(pBt))==0 ){
+ if( pBt==0 || sqlite3BtreePager(pBt)==0 ){
zState = "closed";
}else if( sqlite3_file_control(db, i ? db->aDb[i].zName : 0,
SQLITE_FCNTL_LOCKSTATE, &j)==SQLITE_OK ){
@@ -89604,7 +93808,7 @@ SQLITE_PRIVATE void sqlite3Pragma(
}else
#endif
#if defined(SQLITE_HAS_CODEC) || defined(SQLITE_ENABLE_CEROD)
- if( sqlite3StrICmp(zLeft, "activate_extensions")==0 ){
+ if( sqlite3StrICmp(zLeft, "activate_extensions")==0 && zRight ){
#ifdef SQLITE_HAS_CODEC
if( sqlite3StrNICmp(zRight, "see-", 4)==0 ){
sqlite3_activate_see(&zRight[4]);
@@ -89776,7 +93980,9 @@ SQLITE_PRIVATE int sqlite3InitCallback(void *pInit, int argc, char **argv, char
static int sqlite3InitOne(sqlite3 *db, int iDb, char **pzErrMsg){
int rc;
int i;
+#ifndef SQLITE_OMIT_DEPRECATED
int size;
+#endif
Table *pTab;
Db *pDb;
char const *azArg[4];
@@ -89819,7 +94025,7 @@ static int sqlite3InitOne(sqlite3 *db, int iDb, char **pzErrMsg){
/* zMasterSchema and zInitScript are set to point at the master schema
** and initialisation script appropriate for the database being
- ** initialised. zMasterName is the name of the master table.
+ ** initialized. zMasterName is the name of the master table.
*/
if( !OMIT_TEMPDB && iDb==1 ){
zMasterSchema = temp_master_schema;
@@ -89899,12 +94105,15 @@ static int sqlite3InitOne(sqlite3 *db, int iDb, char **pzErrMsg){
*/
if( meta[BTREE_TEXT_ENCODING-1] ){ /* text encoding */
if( iDb==0 ){
+#ifndef SQLITE_OMIT_UTF16
u8 encoding;
/* If opening the main database, set ENC(db). */
encoding = (u8)meta[BTREE_TEXT_ENCODING-1] & 3;
if( encoding==0 ) encoding = SQLITE_UTF8;
ENC(db) = encoding;
- db->pDfltColl = sqlite3FindCollSeq(db, SQLITE_UTF8, "BINARY", 0);
+#else
+ ENC(db) = SQLITE_UTF8;
+#endif
}else{
/* If opening an attached database, the encoding much match ENC(db) */
if( meta[BTREE_TEXT_ENCODING-1]!=ENC(db) ){
@@ -89920,9 +94129,13 @@ static int sqlite3InitOne(sqlite3 *db, int iDb, char **pzErrMsg){
pDb->pSchema->enc = ENC(db);
if( pDb->pSchema->cache_size==0 ){
+#ifndef SQLITE_OMIT_DEPRECATED
size = sqlite3AbsInt32(meta[BTREE_DEFAULT_CACHE_SIZE-1]);
if( size==0 ){ size = SQLITE_DEFAULT_CACHE_SIZE; }
pDb->pSchema->cache_size = size;
+#else
+ pDb->pSchema->cache_size = SQLITE_DEFAULT_CACHE_SIZE;
+#endif
sqlite3BtreeSetCacheSize(pDb->pBt, pDb->pSchema->cache_size);
}
@@ -89980,7 +94193,7 @@ static int sqlite3InitOne(sqlite3 *db, int iDb, char **pzErrMsg){
}
if( db->mallocFailed ){
rc = SQLITE_NOMEM;
- sqlite3ResetInternalSchema(db, -1);
+ sqlite3ResetAllSchemasOfConnection(db);
}
if( rc==SQLITE_OK || (db->flags&SQLITE_RecoveryMode)){
/* Black magic: If the SQLITE_RecoveryMode flag is set, then consider
@@ -90033,11 +94246,11 @@ SQLITE_PRIVATE int sqlite3Init(sqlite3 *db, char **pzErrMsg){
if( DbHasProperty(db, i, DB_SchemaLoaded) || i==1 ) continue;
rc = sqlite3InitOne(db, i, pzErrMsg);
if( rc ){
- sqlite3ResetInternalSchema(db, i);
+ sqlite3ResetOneSchema(db, i);
}
}
- /* Once all the other databases have been initialised, load the schema
+ /* Once all the other databases have been initialized, load the schema
** for the TEMP database. This is loaded last, as the TEMP database
** schema may contain references to objects in other databases.
*/
@@ -90046,7 +94259,7 @@ SQLITE_PRIVATE int sqlite3Init(sqlite3 *db, char **pzErrMsg){
&& !DbHasProperty(db, 1, DB_SchemaLoaded) ){
rc = sqlite3InitOne(db, 1, pzErrMsg);
if( rc ){
- sqlite3ResetInternalSchema(db, 1);
+ sqlite3ResetOneSchema(db, 1);
}
}
#endif
@@ -90060,7 +94273,7 @@ SQLITE_PRIVATE int sqlite3Init(sqlite3 *db, char **pzErrMsg){
}
/*
-** This routine is a no-op if the database schema is already initialised.
+** This routine is a no-op if the database schema is already initialized.
** Otherwise, the schema is loaded. An error code is returned.
*/
SQLITE_PRIVATE int sqlite3ReadSchema(Parse *pParse){
@@ -90114,7 +94327,7 @@ static void schemaIsValid(Parse *pParse){
sqlite3BtreeGetMeta(pBt, BTREE_SCHEMA_VERSION, (u32 *)&cookie);
assert( sqlite3SchemaMutexHeld(db, iDb, 0) );
if( cookie!=db->aDb[iDb].pSchema->schema_cookie ){
- sqlite3ResetInternalSchema(db, iDb);
+ sqlite3ResetOneSchema(db, iDb);
pParse->rc = SQLITE_SCHEMA;
}
@@ -90344,6 +94557,7 @@ static int sqlite3LockAndPrepare(
}
sqlite3BtreeLeaveAll(db);
sqlite3_mutex_leave(db->mutex);
+ assert( rc==SQLITE_OK || *ppStmt==0 );
return rc;
}
@@ -90538,10 +94752,10 @@ static void clearSelect(sqlite3 *db, Select *p){
*/
SQLITE_PRIVATE void sqlite3SelectDestInit(SelectDest *pDest, int eDest, int iParm){
pDest->eDest = (u8)eDest;
- pDest->iParm = iParm;
- pDest->affinity = 0;
- pDest->iMem = 0;
- pDest->nMem = 0;
+ pDest->iSDParm = iParm;
+ pDest->affSdst = 0;
+ pDest->iSdst = 0;
+ pDest->nSdst = 0;
}
@@ -90557,7 +94771,7 @@ SQLITE_PRIVATE Select *sqlite3SelectNew(
ExprList *pGroupBy, /* the GROUP BY clause */
Expr *pHaving, /* the HAVING clause */
ExprList *pOrderBy, /* the ORDER BY clause */
- int isDistinct, /* true if the DISTINCT keyword is present */
+ u16 selFlags, /* Flag parameters, such as SF_Distinct */
Expr *pLimit, /* LIMIT value. NULL means not used */
Expr *pOffset /* OFFSET value. NULL means no offset */
){
@@ -90567,6 +94781,7 @@ SQLITE_PRIVATE Select *sqlite3SelectNew(
pNew = sqlite3DbMallocZero(db, sizeof(*pNew) );
assert( db->mallocFailed || !pOffset || pLimit ); /* OFFSET implies LIMIT */
if( pNew==0 ){
+ assert( db->mallocFailed );
pNew = &standin;
memset(pNew, 0, sizeof(*pNew));
}
@@ -90574,12 +94789,13 @@ SQLITE_PRIVATE Select *sqlite3SelectNew(
pEList = sqlite3ExprListAppend(pParse, 0, sqlite3Expr(db,TK_ALL,0));
}
pNew->pEList = pEList;
+ if( pSrc==0 ) pSrc = sqlite3DbMallocZero(db, sizeof(*pSrc));
pNew->pSrc = pSrc;
pNew->pWhere = pWhere;
pNew->pGroupBy = pGroupBy;
pNew->pHaving = pHaving;
pNew->pOrderBy = pOrderBy;
- pNew->selFlags = isDistinct ? SF_Distinct : 0;
+ pNew->selFlags = selFlags;
pNew->op = TK_SELECT;
pNew->pLimit = pLimit;
pNew->pOffset = pOffset;
@@ -90591,7 +94807,10 @@ SQLITE_PRIVATE Select *sqlite3SelectNew(
clearSelect(db, pNew);
if( pNew!=&standin ) sqlite3DbFree(db, pNew);
pNew = 0;
+ }else{
+ assert( pNew->pSrc!=0 || pParse->nErr>0 );
}
+ assert( pNew!=&standin );
return pNew;
}
@@ -90921,12 +95140,18 @@ static void pushOntoSorter(
int nExpr = pOrderBy->nExpr;
int regBase = sqlite3GetTempRange(pParse, nExpr+2);
int regRecord = sqlite3GetTempReg(pParse);
+ int op;
sqlite3ExprCacheClear(pParse);
sqlite3ExprCodeExprList(pParse, pOrderBy, regBase, 0);
sqlite3VdbeAddOp2(v, OP_Sequence, pOrderBy->iECursor, regBase+nExpr);
sqlite3ExprCodeMove(pParse, regData, regBase+nExpr+1, 1);
sqlite3VdbeAddOp3(v, OP_MakeRecord, regBase, nExpr + 2, regRecord);
- sqlite3VdbeAddOp2(v, OP_IdxInsert, pOrderBy->iECursor, regRecord);
+ if( pSelect->selFlags & SF_UseSorter ){
+ op = OP_SorterInsert;
+ }else{
+ op = OP_IdxInsert;
+ }
+ sqlite3VdbeAddOp2(v, op, pOrderBy->iECursor, regRecord);
sqlite3ReleaseTempReg(pParse, regRecord);
sqlite3ReleaseTempRange(pParse, regBase, nExpr+2);
if( pSelect->iLimit ){
@@ -91017,6 +95242,19 @@ static int checkForMultiColumnSelectError(
#endif
/*
+** An instance of the following object is used to record information about
+** how to process the DISTINCT keyword, to simplify passing that information
+** into the selectInnerLoop() routine.
+*/
+typedef struct DistinctCtx DistinctCtx;
+struct DistinctCtx {
+ u8 isTnct; /* True if the DISTINCT keyword is present */
+ u8 eTnctType; /* One of the WHERE_DISTINCT_* operators */
+ int tabTnct; /* Ephemeral table used for DISTINCT processing */
+ int addrTnct; /* Address of OP_OpenEphemeral opcode for tabTnct */
+};
+
+/*
** This routine generates the code for the inside of the inner loop
** of a SELECT.
**
@@ -91032,7 +95270,7 @@ static void selectInnerLoop(
int srcTab, /* Pull data from this table */
int nColumn, /* Number of columns in the source table */
ExprList *pOrderBy, /* If not NULL, sort results using this key */
- int distinct, /* If >=0, make sure results are distinct */
+ DistinctCtx *pDistinct, /* If not NULL, info on how to process DISTINCT */
SelectDest *pDest, /* How to dispose of the results */
int iContinue, /* Jump here to continue with next row */
int iBreak /* Jump here to break out of the inner loop */
@@ -91042,13 +95280,13 @@ static void selectInnerLoop(
int hasDistinct; /* True if the DISTINCT keyword is present */
int regResult; /* Start of memory holding result set */
int eDest = pDest->eDest; /* How to dispose of results */
- int iParm = pDest->iParm; /* First argument to disposal method */
+ int iParm = pDest->iSDParm; /* First argument to disposal method */
int nResultCol; /* Number of result columns */
assert( v );
if( NEVER(v==0) ) return;
assert( pEList!=0 );
- hasDistinct = distinct>=0;
+ hasDistinct = pDistinct ? pDistinct->eTnctType : WHERE_DISTINCT_NOOP;
if( pOrderBy==0 && !hasDistinct ){
codeOffset(v, p, iContinue);
}
@@ -91060,14 +95298,14 @@ static void selectInnerLoop(
}else{
nResultCol = pEList->nExpr;
}
- if( pDest->iMem==0 ){
- pDest->iMem = pParse->nMem+1;
- pDest->nMem = nResultCol;
+ if( pDest->iSdst==0 ){
+ pDest->iSdst = pParse->nMem+1;
+ pDest->nSdst = nResultCol;
pParse->nMem += nResultCol;
}else{
- assert( pDest->nMem==nResultCol );
+ assert( pDest->nSdst==nResultCol );
}
- regResult = pDest->iMem;
+ regResult = pDest->iSdst;
if( nColumn>0 ){
for(i=0; i<nColumn; i++){
sqlite3VdbeAddOp3(v, OP_Column, srcTab, i, regResult+i);
@@ -91088,7 +95326,55 @@ static void selectInnerLoop(
if( hasDistinct ){
assert( pEList!=0 );
assert( pEList->nExpr==nColumn );
- codeDistinct(pParse, distinct, iContinue, nColumn, regResult);
+ switch( pDistinct->eTnctType ){
+ case WHERE_DISTINCT_ORDERED: {
+ VdbeOp *pOp; /* No longer required OpenEphemeral instr. */
+ int iJump; /* Jump destination */
+ int regPrev; /* Previous row content */
+
+ /* Allocate space for the previous row */
+ regPrev = pParse->nMem+1;
+ pParse->nMem += nColumn;
+
+ /* Change the OP_OpenEphemeral coded earlier to an OP_Null
+ ** sets the MEM_Cleared bit on the first register of the
+ ** previous value. This will cause the OP_Ne below to always
+ ** fail on the first iteration of the loop even if the first
+ ** row is all NULLs.
+ */
+ sqlite3VdbeChangeToNoop(v, pDistinct->addrTnct);
+ pOp = sqlite3VdbeGetOp(v, pDistinct->addrTnct);
+ pOp->opcode = OP_Null;
+ pOp->p1 = 1;
+ pOp->p2 = regPrev;
+
+ iJump = sqlite3VdbeCurrentAddr(v) + nColumn;
+ for(i=0; i<nColumn; i++){
+ CollSeq *pColl = sqlite3ExprCollSeq(pParse, pEList->a[i].pExpr);
+ if( i<nColumn-1 ){
+ sqlite3VdbeAddOp3(v, OP_Ne, regResult+i, iJump, regPrev+i);
+ }else{
+ sqlite3VdbeAddOp3(v, OP_Eq, regResult+i, iContinue, regPrev+i);
+ }
+ sqlite3VdbeChangeP4(v, -1, (const char *)pColl, P4_COLLSEQ);
+ sqlite3VdbeChangeP5(v, SQLITE_NULLEQ);
+ }
+ assert( sqlite3VdbeCurrentAddr(v)==iJump );
+ sqlite3VdbeAddOp3(v, OP_Copy, regResult, regPrev, nColumn-1);
+ break;
+ }
+
+ case WHERE_DISTINCT_UNIQUE: {
+ sqlite3VdbeChangeToNoop(v, pDistinct->addrTnct);
+ break;
+ }
+
+ default: {
+ assert( pDistinct->eTnctType==WHERE_DISTINCT_UNORDERED );
+ codeDistinct(pParse, pDistinct->tabTnct, iContinue, nColumn, regResult);
+ break;
+ }
+ }
if( pOrderBy==0 ){
codeOffset(v, p, iContinue);
}
@@ -91146,7 +95432,8 @@ static void selectInnerLoop(
*/
case SRT_Set: {
assert( nColumn==1 );
- p->affinity = sqlite3CompareAffinity(pEList->a[0].pExpr, pDest->affinity);
+ pDest->affSdst =
+ sqlite3CompareAffinity(pEList->a[0].pExpr, pDest->affSdst);
if( pOrderBy ){
/* At first glance you would think we could optimize out the
** ORDER BY in this case since the order of entries in the set
@@ -91155,7 +95442,7 @@ static void selectInnerLoop(
pushOntoSorter(pParse, pOrderBy, p, regResult);
}else{
int r1 = sqlite3GetTempReg(pParse);
- sqlite3VdbeAddOp4(v, OP_MakeRecord, regResult, 1, r1, &p->affinity, 1);
+ sqlite3VdbeAddOp4(v, OP_MakeRecord, regResult,1,r1, &pDest->affSdst, 1);
sqlite3ExprCacheAffinityChange(pParse, regResult, 1);
sqlite3VdbeAddOp2(v, OP_IdxInsert, iParm, r1);
sqlite3ReleaseTempReg(pParse, r1);
@@ -91201,7 +95488,7 @@ static void selectInnerLoop(
pushOntoSorter(pParse, pOrderBy, p, r1);
sqlite3ReleaseTempReg(pParse, r1);
}else if( eDest==SRT_Coroutine ){
- sqlite3VdbeAddOp1(v, OP_Yield, pDest->iParm);
+ sqlite3VdbeAddOp1(v, OP_Yield, pDest->iSDParm);
}else{
sqlite3VdbeAddOp2(v, OP_ResultRow, regResult, nColumn);
sqlite3ExprCacheAffinityChange(pParse, regResult, nColumn);
@@ -91381,7 +95668,7 @@ static void generateSortTail(
ExprList *pOrderBy = p->pOrderBy;
int eDest = pDest->eDest;
- int iParm = pDest->iParm;
+ int iParm = pDest->iSDParm;
int regRow;
int regRowid;
@@ -91395,9 +95682,20 @@ static void generateSortTail(
}else{
regRowid = sqlite3GetTempReg(pParse);
}
- addr = 1 + sqlite3VdbeAddOp2(v, OP_Sort, iTab, addrBreak);
- codeOffset(v, p, addrContinue);
- sqlite3VdbeAddOp3(v, OP_Column, iTab, pOrderBy->nExpr + 1, regRow);
+ if( p->selFlags & SF_UseSorter ){
+ int regSortOut = ++pParse->nMem;
+ int ptab2 = pParse->nTab++;
+ sqlite3VdbeAddOp3(v, OP_OpenPseudo, ptab2, regSortOut, pOrderBy->nExpr+2);
+ addr = 1 + sqlite3VdbeAddOp2(v, OP_SorterSort, iTab, addrBreak);
+ codeOffset(v, p, addrContinue);
+ sqlite3VdbeAddOp2(v, OP_SorterData, iTab, regSortOut);
+ sqlite3VdbeAddOp3(v, OP_Column, ptab2, pOrderBy->nExpr+1, regRow);
+ sqlite3VdbeChangeP5(v, OPFLAG_CLEARCACHE);
+ }else{
+ addr = 1 + sqlite3VdbeAddOp2(v, OP_Sort, iTab, addrBreak);
+ codeOffset(v, p, addrContinue);
+ sqlite3VdbeAddOp3(v, OP_Column, iTab, pOrderBy->nExpr+1, regRow);
+ }
switch( eDest ){
case SRT_Table:
case SRT_EphemTab: {
@@ -91411,7 +95709,8 @@ static void generateSortTail(
#ifndef SQLITE_OMIT_SUBQUERY
case SRT_Set: {
assert( nColumn==1 );
- sqlite3VdbeAddOp4(v, OP_MakeRecord, regRow, 1, regRowid, &p->affinity, 1);
+ sqlite3VdbeAddOp4(v, OP_MakeRecord, regRow, 1, regRowid,
+ &pDest->affSdst, 1);
sqlite3ExprCacheAffinityChange(pParse, regRow, 1);
sqlite3VdbeAddOp2(v, OP_IdxInsert, iParm, regRowid);
break;
@@ -91429,17 +95728,17 @@ static void generateSortTail(
testcase( eDest==SRT_Output );
testcase( eDest==SRT_Coroutine );
for(i=0; i<nColumn; i++){
- assert( regRow!=pDest->iMem+i );
- sqlite3VdbeAddOp3(v, OP_Column, pseudoTab, i, pDest->iMem+i);
+ assert( regRow!=pDest->iSdst+i );
+ sqlite3VdbeAddOp3(v, OP_Column, pseudoTab, i, pDest->iSdst+i);
if( i==0 ){
sqlite3VdbeChangeP5(v, OPFLAG_CLEARCACHE);
}
}
if( eDest==SRT_Output ){
- sqlite3VdbeAddOp2(v, OP_ResultRow, pDest->iMem, nColumn);
- sqlite3ExprCacheAffinityChange(pParse, pDest->iMem, nColumn);
+ sqlite3VdbeAddOp2(v, OP_ResultRow, pDest->iSdst, nColumn);
+ sqlite3ExprCacheAffinityChange(pParse, pDest->iSdst, nColumn);
}else{
- sqlite3VdbeAddOp1(v, OP_Yield, pDest->iParm);
+ sqlite3VdbeAddOp1(v, OP_Yield, pDest->iSDParm);
}
break;
}
@@ -91450,7 +95749,11 @@ static void generateSortTail(
/* The bottom of the loop
*/
sqlite3VdbeResolveLabel(v, addrContinue);
- sqlite3VdbeAddOp2(v, OP_Next, iTab, addr);
+ if( p->selFlags & SF_UseSorter ){
+ sqlite3VdbeAddOp2(v, OP_SorterNext, iTab, addr);
+ }else{
+ sqlite3VdbeAddOp2(v, OP_Next, iTab, addr);
+ }
sqlite3VdbeResolveLabel(v, addrBreak);
if( eDest==SRT_Output || eDest==SRT_Coroutine ){
sqlite3VdbeAddOp2(v, OP_Close, pseudoTab, 0);
@@ -91722,7 +96025,7 @@ static void generateColumnNames(
static int selectColumnsFromExprList(
Parse *pParse, /* Parsing context */
ExprList *pEList, /* Expr list from which to derive column names */
- int *pnCol, /* Write the number of columns here */
+ i16 *pnCol, /* Write the number of columns here */
Column **paCol /* Write the new column list here */
){
sqlite3 *db = pParse->db; /* Database connection */
@@ -91734,22 +96037,31 @@ static int selectColumnsFromExprList(
char *zName; /* Column name */
int nName; /* Size of name in zName[] */
- *pnCol = nCol = pEList->nExpr;
- aCol = *paCol = sqlite3DbMallocZero(db, sizeof(aCol[0])*nCol);
- if( aCol==0 ) return SQLITE_NOMEM;
+ if( pEList ){
+ nCol = pEList->nExpr;
+ aCol = sqlite3DbMallocZero(db, sizeof(aCol[0])*nCol);
+ testcase( aCol==0 );
+ }else{
+ nCol = 0;
+ aCol = 0;
+ }
+ *pnCol = nCol;
+ *paCol = aCol;
+
for(i=0, pCol=aCol; i<nCol; i++, pCol++){
/* Get an appropriate name for the column
*/
- p = pEList->a[i].pExpr;
- assert( p->pRight==0 || ExprHasProperty(p->pRight, EP_IntValue)
- || p->pRight->u.zToken==0 || p->pRight->u.zToken[0]!=0 );
+ p = sqlite3ExprSkipCollate(pEList->a[i].pExpr);
if( (zName = pEList->a[i].zName)!=0 ){
/* If the column contains an "AS <name>" phrase, use <name> as the name */
zName = sqlite3DbStrDup(db, zName);
}else{
Expr *pColExpr = p; /* The expression that is the result column name */
Table *pTab; /* Table associated with this expression */
- while( pColExpr->op==TK_DOT ) pColExpr = pColExpr->pRight;
+ while( pColExpr->op==TK_DOT ){
+ pColExpr = pColExpr->pRight;
+ assert( pColExpr!=0 );
+ }
if( pColExpr->op==TK_COLUMN && ALWAYS(pColExpr->pTab!=0) ){
/* For columns use the column name name */
int iCol = pColExpr->iColumn;
@@ -91777,6 +96089,9 @@ static int selectColumnsFromExprList(
for(j=cnt=0; j<i; j++){
if( sqlite3StrICmp(aCol[j].zName, zName)==0 ){
char *zNewName;
+ int k;
+ for(k=nName-1; k>1 && sqlite3Isdigit(zName[k]); k--){}
+ if( zName[k]==':' ) nName = k;
zName[nName] = 0;
zNewName = sqlite3MPrintf(db, "%s:%d", zName, ++cnt);
sqlite3DbFree(db, zName);
@@ -92075,7 +96390,7 @@ static int multiSelect(
*/
if( dest.eDest==SRT_EphemTab ){
assert( p->pEList );
- sqlite3VdbeAddOp2(v, OP_OpenEphemeral, dest.iParm, p->pEList->nExpr);
+ sqlite3VdbeAddOp2(v, OP_OpenEphemeral, dest.iSDParm, p->pEList->nExpr);
sqlite3VdbeChangeP5(v, BTREE_UNORDERED);
dest.eDest = SRT_Table;
}
@@ -92085,8 +96400,12 @@ static int multiSelect(
*/
assert( p->pEList && pPrior->pEList );
if( p->pEList->nExpr!=pPrior->pEList->nExpr ){
- sqlite3ErrorMsg(pParse, "SELECTs to the left and right of %s"
- " do not have the same number of result columns", selectOpName(p->op));
+ if( p->selFlags & SF_Values ){
+ sqlite3ErrorMsg(pParse, "all VALUES must have the same number of terms");
+ }else{
+ sqlite3ErrorMsg(pParse, "SELECTs to the left and right of %s"
+ " do not have the same number of result columns", selectOpName(p->op));
+ }
rc = 1;
goto multi_select_end;
}
@@ -92104,6 +96423,8 @@ static int multiSelect(
int addr = 0;
int nLimit;
assert( !pPrior->pLimit );
+ pPrior->iLimit = p->iLimit;
+ pPrior->iOffset = p->iOffset;
pPrior->pLimit = p->pLimit;
pPrior->pOffset = p->pOffset;
explainSetInteger(iSub1, pParse->iNextSelectId);
@@ -92157,7 +96478,7 @@ static int multiSelect(
** of a 3-way or more compound */
assert( p->pLimit==0 ); /* Not allowed on leftward elements */
assert( p->pOffset==0 ); /* Not allowed on leftward elements */
- unionTab = dest.iParm;
+ unionTab = dest.iSDParm;
}else{
/* We will need to create our own temporary table to hold the
** intermediate results.
@@ -92214,7 +96535,7 @@ static int multiSelect(
/* Convert the data in the temporary table into whatever form
** it is that we currently need.
*/
- assert( unionTab==dest.iParm || dest.eDest!=priorOp );
+ assert( unionTab==dest.iSDParm || dest.eDest!=priorOp );
if( dest.eDest!=priorOp ){
int iCont, iBreak, iStart;
assert( p->pEList );
@@ -92229,7 +96550,7 @@ static int multiSelect(
sqlite3VdbeAddOp2(v, OP_Rewind, unionTab, iBreak);
iStart = sqlite3VdbeCurrentAddr(v);
selectInnerLoop(pParse, p, p->pEList, unionTab, p->pEList->nExpr,
- 0, -1, &dest, iCont, iBreak);
+ 0, 0, &dest, iCont, iBreak);
sqlite3VdbeResolveLabel(v, iCont);
sqlite3VdbeAddOp2(v, OP_Next, unionTab, iStart);
sqlite3VdbeResolveLabel(v, iBreak);
@@ -92278,7 +96599,7 @@ static int multiSelect(
p->pLimit = 0;
pOffset = p->pOffset;
p->pOffset = 0;
- intersectdest.iParm = tab2;
+ intersectdest.iSDParm = tab2;
explainSetInteger(iSub2, pParse->iNextSelectId);
rc = sqlite3Select(pParse, p, &intersectdest);
testcase( rc!=SQLITE_OK );
@@ -92307,7 +96628,7 @@ static int multiSelect(
sqlite3VdbeAddOp4Int(v, OP_NotFound, tab2, iCont, r1, 0);
sqlite3ReleaseTempReg(pParse, r1);
selectInnerLoop(pParse, p, p->pEList, tab1, p->pEList->nExpr,
- 0, -1, &dest, iCont, iBreak);
+ 0, 0, &dest, iCont, iBreak);
sqlite3VdbeResolveLabel(v, iCont);
sqlite3VdbeAddOp2(v, OP_Next, tab1, iStart);
sqlite3VdbeResolveLabel(v, iBreak);
@@ -92353,6 +96674,7 @@ static int multiSelect(
*apColl = db->pDfltColl;
}
}
+ pKeyInfo->aSortOrder = (u8*)apColl;
for(pLoop=p; pLoop; pLoop=pLoop->pPrior){
for(i=0; i<2; i++){
@@ -92372,8 +96694,8 @@ static int multiSelect(
}
multi_select_end:
- pDest->iMem = dest.iMem;
- pDest->nMem = dest.nMem;
+ pDest->iSdst = dest.iSdst;
+ pDest->nSdst = dest.nSdst;
sqlite3SelectDelete(db, pDelete);
return rc;
}
@@ -92383,8 +96705,8 @@ multi_select_end:
** Code an output subroutine for a coroutine implementation of a
** SELECT statment.
**
-** The data to be output is contained in pIn->iMem. There are
-** pIn->nMem columns to be output. pDest is where the output should
+** The data to be output is contained in pIn->iSdst. There are
+** pIn->nSdst columns to be output. pDest is where the output should
** be sent.
**
** regReturn is the number of the register holding the subroutine
@@ -92422,16 +96744,16 @@ static int generateOutputSubroutine(
if( regPrev ){
int j1, j2;
j1 = sqlite3VdbeAddOp1(v, OP_IfNot, regPrev);
- j2 = sqlite3VdbeAddOp4(v, OP_Compare, pIn->iMem, regPrev+1, pIn->nMem,
+ j2 = sqlite3VdbeAddOp4(v, OP_Compare, pIn->iSdst, regPrev+1, pIn->nSdst,
(char*)pKeyInfo, p4type);
sqlite3VdbeAddOp3(v, OP_Jump, j2+2, iContinue, j2+2);
sqlite3VdbeJumpHere(v, j1);
- sqlite3ExprCodeCopy(pParse, pIn->iMem, regPrev+1, pIn->nMem);
+ sqlite3VdbeAddOp3(v, OP_Copy, pIn->iSdst, regPrev+1, pIn->nSdst-1);
sqlite3VdbeAddOp2(v, OP_Integer, 1, regPrev);
}
if( pParse->db->mallocFailed ) return 0;
- /* Suppress the the first OFFSET entries if there is an OFFSET clause
+ /* Suppress the first OFFSET entries if there is an OFFSET clause
*/
codeOffset(v, p, iContinue);
@@ -92444,9 +96766,9 @@ static int generateOutputSubroutine(
int r2 = sqlite3GetTempReg(pParse);
testcase( pDest->eDest==SRT_Table );
testcase( pDest->eDest==SRT_EphemTab );
- sqlite3VdbeAddOp3(v, OP_MakeRecord, pIn->iMem, pIn->nMem, r1);
- sqlite3VdbeAddOp2(v, OP_NewRowid, pDest->iParm, r2);
- sqlite3VdbeAddOp3(v, OP_Insert, pDest->iParm, r1, r2);
+ sqlite3VdbeAddOp3(v, OP_MakeRecord, pIn->iSdst, pIn->nSdst, r1);
+ sqlite3VdbeAddOp2(v, OP_NewRowid, pDest->iSDParm, r2);
+ sqlite3VdbeAddOp3(v, OP_Insert, pDest->iSDParm, r1, r2);
sqlite3VdbeChangeP5(v, OPFLAG_APPEND);
sqlite3ReleaseTempReg(pParse, r2);
sqlite3ReleaseTempReg(pParse, r1);
@@ -92460,13 +96782,13 @@ static int generateOutputSubroutine(
*/
case SRT_Set: {
int r1;
- assert( pIn->nMem==1 );
- p->affinity =
- sqlite3CompareAffinity(p->pEList->a[0].pExpr, pDest->affinity);
+ assert( pIn->nSdst==1 );
+ pDest->affSdst =
+ sqlite3CompareAffinity(p->pEList->a[0].pExpr, pDest->affSdst);
r1 = sqlite3GetTempReg(pParse);
- sqlite3VdbeAddOp4(v, OP_MakeRecord, pIn->iMem, 1, r1, &p->affinity, 1);
- sqlite3ExprCacheAffinityChange(pParse, pIn->iMem, 1);
- sqlite3VdbeAddOp2(v, OP_IdxInsert, pDest->iParm, r1);
+ sqlite3VdbeAddOp4(v, OP_MakeRecord, pIn->iSdst, 1, r1, &pDest->affSdst,1);
+ sqlite3ExprCacheAffinityChange(pParse, pIn->iSdst, 1);
+ sqlite3VdbeAddOp2(v, OP_IdxInsert, pDest->iSDParm, r1);
sqlite3ReleaseTempReg(pParse, r1);
break;
}
@@ -92475,7 +96797,7 @@ static int generateOutputSubroutine(
/* If any row exist in the result set, record that fact and abort.
*/
case SRT_Exists: {
- sqlite3VdbeAddOp2(v, OP_Integer, 1, pDest->iParm);
+ sqlite3VdbeAddOp2(v, OP_Integer, 1, pDest->iSDParm);
/* The LIMIT clause will terminate the loop for us */
break;
}
@@ -92486,23 +96808,23 @@ static int generateOutputSubroutine(
** of the scan loop.
*/
case SRT_Mem: {
- assert( pIn->nMem==1 );
- sqlite3ExprCodeMove(pParse, pIn->iMem, pDest->iParm, 1);
+ assert( pIn->nSdst==1 );
+ sqlite3ExprCodeMove(pParse, pIn->iSdst, pDest->iSDParm, 1);
/* The LIMIT clause will jump out of the loop for us */
break;
}
#endif /* #ifndef SQLITE_OMIT_SUBQUERY */
/* The results are stored in a sequence of registers
- ** starting at pDest->iMem. Then the co-routine yields.
+ ** starting at pDest->iSdst. Then the co-routine yields.
*/
case SRT_Coroutine: {
- if( pDest->iMem==0 ){
- pDest->iMem = sqlite3GetTempRange(pParse, pIn->nMem);
- pDest->nMem = pIn->nMem;
+ if( pDest->iSdst==0 ){
+ pDest->iSdst = sqlite3GetTempRange(pParse, pIn->nSdst);
+ pDest->nSdst = pIn->nSdst;
}
- sqlite3ExprCodeMove(pParse, pIn->iMem, pDest->iMem, pDest->nMem);
- sqlite3VdbeAddOp1(v, OP_Yield, pDest->iParm);
+ sqlite3ExprCodeMove(pParse, pIn->iSdst, pDest->iSdst, pDest->nSdst);
+ sqlite3VdbeAddOp1(v, OP_Yield, pDest->iSDParm);
break;
}
@@ -92516,8 +96838,8 @@ static int generateOutputSubroutine(
*/
default: {
assert( pDest->eDest==SRT_Output );
- sqlite3VdbeAddOp2(v, OP_ResultRow, pIn->iMem, pIn->nMem);
- sqlite3ExprCacheAffinityChange(pParse, pIn->iMem, pIn->nMem);
+ sqlite3VdbeAddOp2(v, OP_ResultRow, pIn->iSdst, pIn->nSdst);
+ sqlite3ExprCacheAffinityChange(pParse, pIn->iSdst, pIn->nSdst);
break;
}
}
@@ -92693,8 +97015,8 @@ static int multiSelectOrderBy(
for(i=1; db->mallocFailed==0 && i<=p->pEList->nExpr; i++){
struct ExprList_item *pItem;
for(j=0, pItem=pOrderBy->a; j<nOrderBy; j++, pItem++){
- assert( pItem->iCol>0 );
- if( pItem->iCol==i ) break;
+ assert( pItem->iOrderByCol>0 );
+ if( pItem->iOrderByCol==i ) break;
}
if( j==nOrderBy ){
Expr *pNew = sqlite3Expr(db, TK_INTEGER, 0);
@@ -92702,7 +97024,7 @@ static int multiSelectOrderBy(
pNew->flags |= EP_IntValue;
pNew->u.iValue = i;
pOrderBy = sqlite3ExprListAppend(pParse, pOrderBy, pNew);
- pOrderBy->a[nOrderBy++].iCol = (u16)i;
+ if( pOrderBy ) pOrderBy->a[nOrderBy++].iOrderByCol = (u16)i;
}
}
}
@@ -92718,8 +97040,8 @@ static int multiSelectOrderBy(
if( aPermute ){
struct ExprList_item *pItem;
for(i=0, pItem=pOrderBy->a; i<nOrderBy; i++, pItem++){
- assert( pItem->iCol>0 && pItem->iCol<=p->pEList->nExpr );
- aPermute[i] = pItem->iCol - 1;
+ assert( pItem->iOrderByCol>0 && pItem->iOrderByCol<=p->pEList->nExpr );
+ aPermute[i] = pItem->iOrderByCol - 1;
}
pKeyMerge =
sqlite3DbMallocRaw(db, sizeof(*pKeyMerge)+nOrderBy*(sizeof(CollSeq*)+1));
@@ -92730,12 +97052,13 @@ static int multiSelectOrderBy(
for(i=0; i<nOrderBy; i++){
CollSeq *pColl;
Expr *pTerm = pOrderBy->a[i].pExpr;
- if( pTerm->flags & EP_ExpCollate ){
- pColl = pTerm->pColl;
+ if( pTerm->flags & EP_Collate ){
+ pColl = sqlite3ExprCollSeq(pParse, pTerm);
}else{
pColl = multiSelectCollSeq(pParse, p, aPermute[i]);
- pTerm->flags |= EP_ExpCollate;
- pTerm->pColl = pColl;
+ if( pColl==0 ) pColl = db->pDfltColl;
+ pOrderBy->a[i].pExpr =
+ sqlite3ExprAddCollateString(pParse, pTerm, pColl->zName);
}
pKeyMerge->aColl[i] = pColl;
pKeyMerge->aSortOrder[i] = pOrderBy->a[i].sortOrder;
@@ -92759,7 +97082,8 @@ static int multiSelectOrderBy(
}else{
int nExpr = p->pEList->nExpr;
assert( nOrderBy>=nExpr || db->mallocFailed );
- regPrev = sqlite3GetTempRange(pParse, nExpr+1);
+ regPrev = pParse->nMem+1;
+ pParse->nMem += nExpr+1;
sqlite3VdbeAddOp2(v, OP_Integer, 0, regPrev);
pKeyDup = sqlite3DbMallocZero(db,
sizeof(*pKeyDup) + nExpr*(sizeof(CollSeq*)+1) );
@@ -92936,16 +97260,11 @@ static int multiSelectOrderBy(
*/
sqlite3VdbeResolveLabel(v, labelCmpr);
sqlite3VdbeAddOp4(v, OP_Permutation, 0, 0, 0, (char*)aPermute, P4_INTARRAY);
- sqlite3VdbeAddOp4(v, OP_Compare, destA.iMem, destB.iMem, nOrderBy,
+ sqlite3VdbeAddOp4(v, OP_Compare, destA.iSdst, destB.iSdst, nOrderBy,
(char*)pKeyMerge, P4_KEYINFO_HANDOFF);
+ sqlite3VdbeChangeP5(v, OPFLAG_PERMUTE);
sqlite3VdbeAddOp3(v, OP_Jump, addrAltB, addrAeqB, addrAgtB);
- /* Release temporary registers
- */
- if( regPrev ){
- sqlite3ReleaseTempRange(pParse, regPrev, nOrderBy+1);
- }
-
/* Jump to the this point in order to terminate the query.
*/
sqlite3VdbeResolveLabel(v, labelEnd);
@@ -93005,9 +97324,6 @@ static Expr *substExpr(
assert( pEList!=0 && pExpr->iColumn<pEList->nExpr );
assert( pExpr->pLeft==0 && pExpr->pRight==0 );
pNew = sqlite3ExprDup(db, pEList->a[pExpr->iColumn].pExpr, 0);
- if( pNew && pExpr->pColl ){
- pNew->pColl = pExpr->pColl;
- }
sqlite3ExprDelete(db, pExpr);
pExpr = pNew;
}
@@ -93062,9 +97378,8 @@ static void substSelect(
#if !defined(SQLITE_OMIT_SUBQUERY) || !defined(SQLITE_OMIT_VIEW)
/*
-** This routine attempts to flatten subqueries in order to speed
-** execution. It returns 1 if it makes changes and 0 if no flattening
-** occurs.
+** This routine attempts to flatten subqueries as a performance optimization.
+** This routine returns 1 if it makes changes and 0 if no flattening occurs.
**
** To understand the concept of flattening, consider the following
** query:
@@ -93106,7 +97421,10 @@ static void substSelect(
** (6) The subquery does not use aggregates or the outer query is not
** DISTINCT.
**
-** (7) The subquery has a FROM clause.
+** (7) The subquery has a FROM clause. TODO: For subqueries without
+** A FROM clause, consider adding a FROM close with the special
+** table sqlite_once that consists of a single row containing a
+** single NULL.
**
** (8) The subquery does not use LIMIT or the outer query is not a join.
**
@@ -93139,11 +97457,20 @@ static void substSelect(
**
** * is not itself part of a compound select,
** * is not an aggregate or DISTINCT query, and
-** * has no other tables or sub-selects in the FROM clause.
+** * is not a join
**
** The parent and sub-query may contain WHERE clauses. Subject to
** rules (11), (13) and (14), they may also contain ORDER BY,
-** LIMIT and OFFSET clauses.
+** LIMIT and OFFSET clauses. The subquery cannot use any compound
+** operator other than UNION ALL because all the other compound
+** operators have an implied DISTINCT which is disallowed by
+** restriction (4).
+**
+** Also, each component of the sub-query must return the same number
+** of result columns. This is actually a requirement for any compound
+** SELECT statement, but all the code here does is make sure that no
+** such (illegal) sub-query is flattened. The caller will detect the
+** syntax error and return a detailed message.
**
** (18) If the sub-query is a compound select, then all terms of the
** ORDER by clause of the parent must be simple references to
@@ -93155,7 +97482,7 @@ static void substSelect(
** (20) If the sub-query is a compound select, then it must not use
** an ORDER BY clause. Ticket #3773. We could relax this constraint
** somewhat by saying that the terms of the ORDER BY clause must
-** appear as unmodified result columns in the outer query. But
+** appear as unmodified result columns in the outer query. But we
** have other optimizations in mind to deal with that case.
**
** (21) The subquery does not use LIMIT or the outer query is not
@@ -93195,7 +97522,7 @@ static int flattenSubquery(
*/
assert( p!=0 );
assert( p->pPrior==0 ); /* Unable to flatten compound queries */
- if( db->flags & SQLITE_QueryFlattener ) return 0;
+ if( OptimizationDisabled(db, SQLITE_QueryFlattener) ) return 0;
pSrc = p->pSrc;
assert( pSrc && iFrom>=0 && iFrom<pSrc->nSrc );
pSubitem = &pSrc->a[iFrom];
@@ -93284,19 +97611,22 @@ static int flattenSubquery(
for(pSub1=pSub; pSub1; pSub1=pSub1->pPrior){
testcase( (pSub1->selFlags & (SF_Distinct|SF_Aggregate))==SF_Distinct );
testcase( (pSub1->selFlags & (SF_Distinct|SF_Aggregate))==SF_Aggregate );
+ assert( pSub->pSrc!=0 );
if( (pSub1->selFlags & (SF_Distinct|SF_Aggregate))!=0
|| (pSub1->pPrior && pSub1->op!=TK_ALL)
- || NEVER(pSub1->pSrc==0) || pSub1->pSrc->nSrc!=1
+ || pSub1->pSrc->nSrc<1
+ || pSub->pEList->nExpr!=pSub1->pEList->nExpr
){
return 0;
}
+ testcase( pSub1->pSrc->nSrc>1 );
}
/* Restriction 18. */
if( p->pOrderBy ){
int ii;
for(ii=0; ii<p->pOrderBy->nExpr; ii++){
- if( p->pOrderBy->a[ii].iCol==0 ) return 0;
+ if( p->pOrderBy->a[ii].iOrderByCol==0 ) return 0;
}
}
}
@@ -93305,7 +97635,8 @@ static int flattenSubquery(
/* Authorize the subquery */
pParse->zAuthContext = pSubitem->zName;
- sqlite3AuthCheck(pParse, SQLITE_SELECT, 0, 0, 0);
+ TESTONLY(i =) sqlite3AuthCheck(pParse, SQLITE_SELECT, 0, 0, 0);
+ testcase( i==SQLITE_DENY );
pParse->zAuthContext = zSavedAuthContext;
/* If the sub-query is a compound SELECT statement, then (by restrictions
@@ -93345,12 +97676,15 @@ static int flattenSubquery(
Select *pNew;
ExprList *pOrderBy = p->pOrderBy;
Expr *pLimit = p->pLimit;
+ Expr *pOffset = p->pOffset;
Select *pPrior = p->pPrior;
p->pOrderBy = 0;
p->pSrc = 0;
p->pPrior = 0;
p->pLimit = 0;
+ p->pOffset = 0;
pNew = sqlite3SelectDup(db, p, 0);
+ p->pOffset = pOffset;
p->pLimit = pLimit;
p->pOrderBy = pOrderBy;
p->pSrc = pSrc;
@@ -93480,10 +97814,9 @@ static int flattenSubquery(
pList = pParent->pEList;
for(i=0; i<pList->nExpr; i++){
if( pList->a[i].zName==0 ){
- const char *zSpan = pList->a[i].zSpan;
- if( ALWAYS(zSpan) ){
- pList->a[i].zName = sqlite3DbStrDup(db, zSpan);
- }
+ char *zName = sqlite3DbStrDup(db, pList->a[i].zSpan);
+ sqlite3Dequote(zName);
+ pList->a[i].zName = zName;
}
}
substExprList(db, pParent->pEList, iParent, pSub->pEList);
@@ -93544,34 +97877,43 @@ static int flattenSubquery(
#endif /* !defined(SQLITE_OMIT_SUBQUERY) || !defined(SQLITE_OMIT_VIEW) */
/*
-** Analyze the SELECT statement passed as an argument to see if it
-** is a min() or max() query. Return WHERE_ORDERBY_MIN or WHERE_ORDERBY_MAX if
-** it is, or 0 otherwise. At present, a query is considered to be
-** a min()/max() query if:
+** Based on the contents of the AggInfo structure indicated by the first
+** argument, this function checks if the following are true:
**
-** 1. There is a single object in the FROM clause.
+** * the query contains just a single aggregate function,
+** * the aggregate function is either min() or max(), and
+** * the argument to the aggregate function is a column value.
**
-** 2. There is a single expression in the result set, and it is
-** either min(x) or max(x), where x is a column reference.
+** If all of the above are true, then WHERE_ORDERBY_MIN or WHERE_ORDERBY_MAX
+** is returned as appropriate. Also, *ppMinMax is set to point to the
+** list of arguments passed to the aggregate before returning.
+**
+** Or, if the conditions above are not met, *ppMinMax is set to 0 and
+** WHERE_ORDERBY_NORMAL is returned.
*/
-static u8 minMaxQuery(Select *p){
- Expr *pExpr;
- ExprList *pEList = p->pEList;
+static u8 minMaxQuery(AggInfo *pAggInfo, ExprList **ppMinMax){
+ int eRet = WHERE_ORDERBY_NORMAL; /* Return value */
- if( pEList->nExpr!=1 ) return WHERE_ORDERBY_NORMAL;
- pExpr = pEList->a[0].pExpr;
- if( pExpr->op!=TK_AGG_FUNCTION ) return 0;
- if( NEVER(ExprHasProperty(pExpr, EP_xIsSelect)) ) return 0;
- pEList = pExpr->x.pList;
- if( pEList==0 || pEList->nExpr!=1 ) return 0;
- if( pEList->a[0].pExpr->op!=TK_AGG_COLUMN ) return WHERE_ORDERBY_NORMAL;
- assert( !ExprHasProperty(pExpr, EP_IntValue) );
- if( sqlite3StrICmp(pExpr->u.zToken,"min")==0 ){
- return WHERE_ORDERBY_MIN;
- }else if( sqlite3StrICmp(pExpr->u.zToken,"max")==0 ){
- return WHERE_ORDERBY_MAX;
+ *ppMinMax = 0;
+ if( pAggInfo->nFunc==1 ){
+ Expr *pExpr = pAggInfo->aFunc[0].pExpr; /* Aggregate function */
+ ExprList *pEList = pExpr->x.pList; /* Arguments to agg function */
+
+ assert( pExpr->op==TK_AGG_FUNCTION );
+ if( pEList && pEList->nExpr==1 && pEList->a[0].pExpr->op==TK_AGG_COLUMN ){
+ const char *zFunc = pExpr->u.zToken;
+ if( sqlite3StrICmp(zFunc, "min")==0 ){
+ eRet = WHERE_ORDERBY_MIN;
+ *ppMinMax = pEList;
+ }else if( sqlite3StrICmp(zFunc, "max")==0 ){
+ eRet = WHERE_ORDERBY_MAX;
+ *ppMinMax = pEList;
+ }
+ }
}
- return WHERE_ORDERBY_NORMAL;
+
+ assert( *ppMinMax==0 || (*ppMinMax)->nExpr==1 );
+ return eRet;
}
/*
@@ -93602,6 +97944,7 @@ static Table *isSimpleCount(Select *p, AggInfo *pAggInfo){
if( IsVirtual(pTab) ) return 0;
if( pExpr->op!=TK_AGG_FUNCTION ) return 0;
+ if( NEVER(pAggInfo->nFunc==0) ) return 0;
if( (pAggInfo->aFunc[0].pFunc->flags&SQLITE_FUNC_COUNT)==0 ) return 0;
if( pExpr->flags&EP_Distinct ) return 0;
@@ -93665,14 +98008,16 @@ static int selectExpander(Walker *pWalker, Select *p){
ExprList *pEList;
struct SrcList_item *pFrom;
sqlite3 *db = pParse->db;
+ Expr *pE, *pRight, *pExpr;
+ u16 selFlags = p->selFlags;
+ p->selFlags |= SF_Expanded;
if( db->mallocFailed ){
return WRC_Abort;
}
- if( NEVER(p->pSrc==0) || (p->selFlags & SF_Expanded)!=0 ){
+ if( NEVER(p->pSrc==0) || (selFlags & SF_Expanded)!=0 ){
return WRC_Prune;
}
- p->selFlags |= SF_Expanded;
pTabList = p->pSrc;
pEList = p->pEList;
@@ -93713,9 +98058,14 @@ static int selectExpander(Walker *pWalker, Select *p){
}else{
/* An ordinary table or view name in the FROM clause */
assert( pFrom->pTab==0 );
- pFrom->pTab = pTab =
- sqlite3LocateTable(pParse,0,pFrom->zName,pFrom->zDatabase);
+ pFrom->pTab = pTab = sqlite3LocateTableItem(pParse, 0, pFrom);
if( pTab==0 ) return WRC_Abort;
+ if( pTab->nRef==0xffff ){
+ sqlite3ErrorMsg(pParse, "too many references to \"%s\": max 65535",
+ pTab->zName);
+ pFrom->pTab = 0;
+ return WRC_Abort;
+ }
pTab->nRef++;
#if !defined(SQLITE_OMIT_VIEW) || !defined (SQLITE_OMIT_VIRTUALTABLE)
if( pTab->pSelect || IsVirtual(pTab) ){
@@ -93751,7 +98101,7 @@ static int selectExpander(Walker *pWalker, Select *p){
** that need expanding.
*/
for(k=0; k<pEList->nExpr; k++){
- Expr *pE = pEList->a[k].pExpr;
+ pE = pEList->a[k].pExpr;
if( pE->op==TK_ALL ) break;
assert( pE->op!=TK_DOT || pE->pRight!=0 );
assert( pE->op!=TK_DOT || (pE->pLeft!=0 && pE->pLeft->op==TK_ID) );
@@ -93769,10 +98119,18 @@ static int selectExpander(Walker *pWalker, Select *p){
int longNames = (flags & SQLITE_FullColNames)!=0
&& (flags & SQLITE_ShortColNames)==0;
+ /* When processing FROM-clause subqueries, it is always the case
+ ** that full_column_names=OFF and short_column_names=ON. The
+ ** sqlite3ResultSetOfSelect() routine makes it so. */
+ assert( (p->selFlags & SF_NestedFrom)==0
+ || ((flags & SQLITE_FullColNames)==0 &&
+ (flags & SQLITE_ShortColNames)!=0) );
+
for(k=0; k<pEList->nExpr; k++){
- Expr *pE = a[k].pExpr;
- assert( pE->op!=TK_DOT || pE->pRight!=0 );
- if( pE->op!=TK_ALL && (pE->op!=TK_DOT || pE->pRight->op!=TK_ALL) ){
+ pE = a[k].pExpr;
+ pRight = pE->pRight;
+ assert( pE->op!=TK_DOT || pRight!=0 );
+ if( pE->op!=TK_ALL && (pE->op!=TK_DOT || pRight->op!=TK_ALL) ){
/* This particular expression does not need to be expanded.
*/
pNew = sqlite3ExprListAppend(pParse, pNew, a[k].pExpr);
@@ -93787,32 +98145,43 @@ static int selectExpander(Walker *pWalker, Select *p){
/* This expression is a "*" or a "TABLE.*" and needs to be
** expanded. */
int tableSeen = 0; /* Set to 1 when TABLE matches */
- char *zTName; /* text of name of TABLE */
+ char *zTName = 0; /* text of name of TABLE */
if( pE->op==TK_DOT ){
assert( pE->pLeft!=0 );
assert( !ExprHasProperty(pE->pLeft, EP_IntValue) );
zTName = pE->pLeft->u.zToken;
- }else{
- zTName = 0;
}
for(i=0, pFrom=pTabList->a; i<pTabList->nSrc; i++, pFrom++){
Table *pTab = pFrom->pTab;
+ Select *pSub = pFrom->pSelect;
char *zTabName = pFrom->zAlias;
+ const char *zSchemaName = 0;
+ int iDb;
if( zTabName==0 ){
zTabName = pTab->zName;
}
if( db->mallocFailed ) break;
- if( zTName && sqlite3StrICmp(zTName, zTabName)!=0 ){
- continue;
+ if( pSub==0 || (pSub->selFlags & SF_NestedFrom)==0 ){
+ pSub = 0;
+ if( zTName && sqlite3StrICmp(zTName, zTabName)!=0 ){
+ continue;
+ }
+ iDb = sqlite3SchemaToIndex(db, pTab->pSchema);
+ zSchemaName = iDb>=0 ? db->aDb[iDb].zName : "*";
}
- tableSeen = 1;
for(j=0; j<pTab->nCol; j++){
- Expr *pExpr, *pRight;
char *zName = pTab->aCol[j].zName;
char *zColname; /* The computed column name */
char *zToFree; /* Malloced string that needs to be freed */
Token sColname; /* Computed column name as a token */
+ assert( zName );
+ if( zTName && pSub
+ && sqlite3MatchSpanName(pSub->pEList->a[j].zSpan, 0, zTName, 0)==0
+ ){
+ continue;
+ }
+
/* If a column is marked as 'hidden' (currently only possible
** for virtual tables), do not include it in the expanded
** result-set list.
@@ -93821,6 +98190,7 @@ static int selectExpander(Walker *pWalker, Select *p){
assert(IsVirtual(pTab));
continue;
}
+ tableSeen = 1;
if( i>0 && zTName==0 ){
if( (pFrom->jointype & JT_NATURAL)!=0
@@ -93843,6 +98213,10 @@ static int selectExpander(Walker *pWalker, Select *p){
Expr *pLeft;
pLeft = sqlite3Expr(db, TK_ID, zTabName);
pExpr = sqlite3PExpr(pParse, TK_DOT, pLeft, pRight, 0);
+ if( zSchemaName ){
+ pLeft = sqlite3Expr(db, TK_ID, zSchemaName);
+ pExpr = sqlite3PExpr(pParse, TK_DOT, pLeft, pExpr, 0);
+ }
if( longNames ){
zColname = sqlite3MPrintf(db, "%s.%s", zTabName, zName);
zToFree = zColname;
@@ -93854,6 +98228,18 @@ static int selectExpander(Walker *pWalker, Select *p){
sColname.z = zColname;
sColname.n = sqlite3Strlen30(zColname);
sqlite3ExprListSetName(pParse, pNew, &sColname, 0);
+ if( pNew && (p->selFlags & SF_NestedFrom)!=0 ){
+ struct ExprList_item *pX = &pNew->a[pNew->nExpr-1];
+ if( pSub ){
+ pX->zSpan = sqlite3DbStrDup(db, pSub->pEList->a[j].zSpan);
+ testcase( pX->zSpan==0 );
+ }else{
+ pX->zSpan = sqlite3MPrintf(db, "%s.%s.%s",
+ zSchemaName, zTabName, zColname);
+ testcase( pX->zSpan==0 );
+ }
+ pX->bSpanIsTab = 1;
+ }
sqlite3DbFree(db, zToFree);
}
}
@@ -93973,7 +98359,7 @@ static void sqlite3SelectAddTypeInfo(Parse *pParse, Select *pSelect){
/*
-** This routine sets of a SELECT statement for processing. The
+** This routine sets up a SELECT statement for processing. The
** following is accomplished:
**
** * VDBE Cursor numbers are assigned to all FROM-clause terms.
@@ -93992,6 +98378,7 @@ SQLITE_PRIVATE void sqlite3SelectPrep(
sqlite3 *db;
if( NEVER(p==0) ) return;
db = pParse->db;
+ if( db->mallocFailed ) return;
if( p->selFlags & SF_HasTypeInfo ) return;
sqlite3SelectExpand(pParse, p);
if( pParse->nErr || db->mallocFailed ) return;
@@ -94005,7 +98392,8 @@ SQLITE_PRIVATE void sqlite3SelectPrep(
**
** The aggregate accumulator is a set of memory cells that hold
** intermediate results while calculating an aggregate. This
-** routine simply stores NULLs in all of those memory cells.
+** routine generates code that stores NULLs in all of those memory
+** cells.
*/
static void resetAccumulator(Parse *pParse, AggInfo *pAggInfo){
Vdbe *v = pParse->pVdbe;
@@ -94058,6 +98446,8 @@ static void finalizeAggFunctions(Parse *pParse, AggInfo *pAggInfo){
static void updateAccumulator(Parse *pParse, AggInfo *pAggInfo){
Vdbe *v = pParse->pVdbe;
int i;
+ int regHit = 0;
+ int addrHitTest = 0;
struct AggInfo_func *pF;
struct AggInfo_col *pC;
@@ -94093,7 +98483,8 @@ static void updateAccumulator(Parse *pParse, AggInfo *pAggInfo){
if( !pColl ){
pColl = pParse->db->pDfltColl;
}
- sqlite3VdbeAddOp4(v, OP_CollSeq, 0, 0, 0, (char *)pColl, P4_COLLSEQ);
+ if( regHit==0 && pAggInfo->nAccumulator ) regHit = ++pParse->nMem;
+ sqlite3VdbeAddOp4(v, OP_CollSeq, regHit, 0, 0, (char *)pColl, P4_COLLSEQ);
}
sqlite3VdbeAddOp4(v, OP_AggStep, 0, regAgg, pF->iMem,
(void*)pF->pFunc, P4_FUNCDEF);
@@ -94116,12 +98507,18 @@ static void updateAccumulator(Parse *pParse, AggInfo *pAggInfo){
** Another solution would be to change the OP_SCopy used to copy cached
** values to an OP_Copy.
*/
+ if( regHit ){
+ addrHitTest = sqlite3VdbeAddOp1(v, OP_If, regHit);
+ }
sqlite3ExprCacheClear(pParse);
for(i=0, pC=pAggInfo->aCol; i<pAggInfo->nAccumulator; i++, pC++){
sqlite3ExprCode(pParse, pC->pExpr, pC->iMem);
}
pAggInfo->directMode = 0;
sqlite3ExprCacheClear(pParse);
+ if( addrHitTest ){
+ sqlite3VdbeJumpHere(v, addrHitTest);
+ }
}
/*
@@ -94164,23 +98561,24 @@ static void explainSimpleCount(
**
** SRT_Mem Only valid if the result is a single column.
** Store the first column of the first result row
-** in register pDest->iParm then abandon the rest
+** in register pDest->iSDParm then abandon the rest
** of the query. This destination implies "LIMIT 1".
**
** SRT_Set The result must be a single column. Store each
-** row of result as the key in table pDest->iParm.
-** Apply the affinity pDest->affinity before storing
+** row of result as the key in table pDest->iSDParm.
+** Apply the affinity pDest->affSdst before storing
** results. Used to implement "IN (SELECT ...)".
**
-** SRT_Union Store results as a key in a temporary table pDest->iParm.
+** SRT_Union Store results as a key in a temporary table
+** identified by pDest->iSDParm.
**
-** SRT_Except Remove results from the temporary table pDest->iParm.
+** SRT_Except Remove results from the temporary table pDest->iSDParm.
**
-** SRT_Table Store results in temporary table pDest->iParm.
+** SRT_Table Store results in temporary table pDest->iSDParm.
** This is like SRT_EphemTab except that the table
** is assumed to already be open.
**
-** SRT_EphemTab Create an temporary table pDest->iParm and store
+** SRT_EphemTab Create an temporary table pDest->iSDParm and store
** the result there. The cursor is left open after
** returning. This is like SRT_Table except that
** this destination uses OP_OpenEphemeral to create
@@ -94188,9 +98586,9 @@ static void explainSimpleCount(
**
** SRT_Coroutine Generate a co-routine that returns a new row of
** results each time it is invoked. The entry point
-** of the co-routine is stored in register pDest->iParm.
+** of the co-routine is stored in register pDest->iSDParm.
**
-** SRT_Exists Store a 1 in memory cell pDest->iParm if the result
+** SRT_Exists Store a 1 in memory cell pDest->iSDParm if the result
** set is not empty.
**
** SRT_Discard Throw the results away. This is used by SELECT
@@ -94219,10 +98617,9 @@ SQLITE_PRIVATE int sqlite3Select(
ExprList *pOrderBy; /* The ORDER BY clause. May be NULL */
ExprList *pGroupBy; /* The GROUP BY clause. May be NULL */
Expr *pHaving; /* The HAVING clause. May be NULL */
- int isDistinct; /* True if the DISTINCT keyword is present */
- int distinct; /* Table to use for the distinct set */
int rc = 1; /* Value to return from this function */
int addrSortIndex; /* Address of an OP_OpenEphemeral instruction */
+ DistinctCtx sDistinct; /* Info on how to code the DISTINCT keyword */
AggInfo sAggInfo; /* Information used by aggregate queries */
int iEnd; /* Address of the end of the query */
sqlite3 *db; /* The database connection */
@@ -94281,7 +98678,20 @@ SQLITE_PRIVATE int sqlite3Select(
Select *pSub = pItem->pSelect;
int isAggSub;
- if( pSub==0 || pItem->isPopulated ) continue;
+ if( pSub==0 ) continue;
+
+ /* Sometimes the code for a subquery will be generated more than
+ ** once, if the subquery is part of the WHERE clause in a LEFT JOIN,
+ ** for example. In that case, do not regenerate the code to manifest
+ ** a view or the co-routine to implement a view. The first instance
+ ** is sufficient, though the subroutine to manifest the view does need
+ ** to be invoked again. */
+ if( pItem->addrFillSub ){
+ if( pItem->viaCoroutine==0 ){
+ sqlite3VdbeAddOp2(v, OP_Gosub, pItem->regReturn, pItem->addrFillSub);
+ }
+ continue;
+ }
/* Increment Parse.nHeight by the height of the largest expression
** tree refered to by this, the parent select. The child select
@@ -94292,21 +98702,81 @@ SQLITE_PRIVATE int sqlite3Select(
*/
pParse->nHeight += sqlite3SelectExprHeight(p);
- /* Check to see if the subquery can be absorbed into the parent. */
isAggSub = (pSub->selFlags & SF_Aggregate)!=0;
if( flattenSubquery(pParse, p, i, isAgg, isAggSub) ){
+ /* This subquery can be absorbed into its parent. */
if( isAggSub ){
isAgg = 1;
p->selFlags |= SF_Aggregate;
}
i = -1;
+ }else if( pTabList->nSrc==1 && (p->selFlags & SF_Materialize)==0
+ && OptimizationEnabled(db, SQLITE_SubqCoroutine)
+ ){
+ /* Implement a co-routine that will return a single row of the result
+ ** set on each invocation.
+ */
+ int addrTop;
+ int addrEof;
+ pItem->regReturn = ++pParse->nMem;
+ addrEof = ++pParse->nMem;
+ /* Before coding the OP_Goto to jump to the start of the main routine,
+ ** ensure that the jump to the verify-schema routine has already
+ ** been coded. Otherwise, the verify-schema would likely be coded as
+ ** part of the co-routine. If the main routine then accessed the
+ ** database before invoking the co-routine for the first time (for
+ ** example to initialize a LIMIT register from a sub-select), it would
+ ** be doing so without having verified the schema version and obtained
+ ** the required db locks. See ticket d6b36be38. */
+ sqlite3CodeVerifySchema(pParse, -1);
+ sqlite3VdbeAddOp0(v, OP_Goto);
+ addrTop = sqlite3VdbeAddOp1(v, OP_OpenPseudo, pItem->iCursor);
+ sqlite3VdbeChangeP5(v, 1);
+ VdbeComment((v, "coroutine for %s", pItem->pTab->zName));
+ pItem->addrFillSub = addrTop;
+ sqlite3VdbeAddOp2(v, OP_Integer, 0, addrEof);
+ sqlite3VdbeChangeP5(v, 1);
+ sqlite3SelectDestInit(&dest, SRT_Coroutine, pItem->regReturn);
+ explainSetInteger(pItem->iSelectId, (u8)pParse->iNextSelectId);
+ sqlite3Select(pParse, pSub, &dest);
+ pItem->pTab->nRowEst = (unsigned)pSub->nSelectRow;
+ pItem->viaCoroutine = 1;
+ sqlite3VdbeChangeP2(v, addrTop, dest.iSdst);
+ sqlite3VdbeChangeP3(v, addrTop, dest.nSdst);
+ sqlite3VdbeAddOp2(v, OP_Integer, 1, addrEof);
+ sqlite3VdbeAddOp1(v, OP_Yield, pItem->regReturn);
+ VdbeComment((v, "end %s", pItem->pTab->zName));
+ sqlite3VdbeJumpHere(v, addrTop-1);
+ sqlite3ClearTempRegCache(pParse);
}else{
+ /* Generate a subroutine that will fill an ephemeral table with
+ ** the content of this subquery. pItem->addrFillSub will point
+ ** to the address of the generated subroutine. pItem->regReturn
+ ** is a register allocated to hold the subroutine return address
+ */
+ int topAddr;
+ int onceAddr = 0;
+ int retAddr;
+ assert( pItem->addrFillSub==0 );
+ pItem->regReturn = ++pParse->nMem;
+ topAddr = sqlite3VdbeAddOp2(v, OP_Integer, 0, pItem->regReturn);
+ pItem->addrFillSub = topAddr+1;
+ VdbeNoopComment((v, "materialize %s", pItem->pTab->zName));
+ if( pItem->isCorrelated==0 ){
+ /* If the subquery is no correlated and if we are not inside of
+ ** a trigger, then we only need to compute the value of the subquery
+ ** once. */
+ onceAddr = sqlite3CodeOnce(pParse);
+ }
sqlite3SelectDestInit(&dest, SRT_EphemTab, pItem->iCursor);
- assert( pItem->isPopulated==0 );
explainSetInteger(pItem->iSelectId, (u8)pParse->iNextSelectId);
sqlite3Select(pParse, pSub, &dest);
- pItem->isPopulated = 1;
pItem->pTab->nRowEst = (unsigned)pSub->nSelectRow;
+ if( onceAddr ) sqlite3VdbeJumpHere(v, onceAddr);
+ retAddr = sqlite3VdbeAddOp1(v, OP_Return, pItem->regReturn);
+ VdbeComment((v, "end %s", pItem->pTab->zName));
+ sqlite3VdbeChangeP1(v, topAddr, retAddr);
+ sqlite3ClearTempRegCache(pParse);
}
if( /*pParse->nErr ||*/ db->mallocFailed ){
goto select_end;
@@ -94322,7 +98792,7 @@ SQLITE_PRIVATE int sqlite3Select(
pWhere = p->pWhere;
pGroupBy = p->pGroupBy;
pHaving = p->pHaving;
- isDistinct = (p->selFlags & SF_Distinct)!=0;
+ sDistinct.isTnct = (p->selFlags & SF_Distinct)!=0;
#ifndef SQLITE_OMIT_COMPOUND_SELECT
/* If there is are a sequence of queries, do the earlier ones first.
@@ -94349,16 +98819,6 @@ SQLITE_PRIVATE int sqlite3Select(
}
#endif
- /* If possible, rewrite the query to use GROUP BY instead of DISTINCT.
- ** GROUP BY might use an index, DISTINCT never does.
- */
- assert( p->pGroupBy==0 || (p->selFlags & SF_Aggregate)!=0 );
- if( (p->selFlags & (SF_Distinct|SF_Aggregate))==SF_Distinct ){
- p->pGroupBy = sqlite3ExprListDup(db, p->pEList, 0);
- pGroupBy = p->pGroupBy;
- p->selFlags &= ~SF_Distinct;
- }
-
/* If there is both a GROUP BY and an ORDER BY clause and they are
** identical, then disable the ORDER BY clause since the GROUP BY
** will cause elements to come out in the correct order. This is
@@ -94367,10 +98827,38 @@ SQLITE_PRIVATE int sqlite3Select(
** to disable this optimization for testing purposes.
*/
if( sqlite3ExprListCompare(p->pGroupBy, pOrderBy)==0
- && (db->flags & SQLITE_GroupByOrder)==0 ){
+ && OptimizationEnabled(db, SQLITE_GroupByOrder) ){
pOrderBy = 0;
}
+ /* If the query is DISTINCT with an ORDER BY but is not an aggregate, and
+ ** if the select-list is the same as the ORDER BY list, then this query
+ ** can be rewritten as a GROUP BY. In other words, this:
+ **
+ ** SELECT DISTINCT xyz FROM ... ORDER BY xyz
+ **
+ ** is transformed to:
+ **
+ ** SELECT xyz FROM ... GROUP BY xyz
+ **
+ ** The second form is preferred as a single index (or temp-table) may be
+ ** used for both the ORDER BY and DISTINCT processing. As originally
+ ** written the query must use a temp-table for at least one of the ORDER
+ ** BY and DISTINCT, and an index or separate temp-table for the other.
+ */
+ if( (p->selFlags & (SF_Distinct|SF_Aggregate))==SF_Distinct
+ && sqlite3ExprListCompare(pOrderBy, p->pEList)==0
+ ){
+ p->selFlags &= ~SF_Distinct;
+ p->pGroupBy = sqlite3ExprListDup(db, p->pEList, 0);
+ pGroupBy = p->pGroupBy;
+ pOrderBy = 0;
+ /* Notice that even thought SF_Distinct has been cleared from p->selFlags,
+ ** the sDistinct.isTnct is still set. Hence, isTnct represents the
+ ** original setting of the SF_Distinct flag, not the current setting */
+ assert( sDistinct.isTnct );
+ }
+
/* If there is an ORDER BY clause, then this sorting
** index might end up being unused if the data can be
** extracted in pre-sorted order. If that is the case, then the
@@ -94393,7 +98881,7 @@ SQLITE_PRIVATE int sqlite3Select(
/* If the output is destined for a temporary table, open that table.
*/
if( pDest->eDest==SRT_EphemTab ){
- sqlite3VdbeAddOp2(v, OP_OpenEphemeral, pDest->iParm, pEList->nExpr);
+ sqlite3VdbeAddOp2(v, OP_OpenEphemeral, pDest->iSDParm, pEList->nExpr);
}
/* Set the limiter.
@@ -94401,50 +98889,55 @@ SQLITE_PRIVATE int sqlite3Select(
iEnd = sqlite3VdbeMakeLabel(v);
p->nSelectRow = (double)LARGEST_INT64;
computeLimitRegisters(pParse, p, iEnd);
+ if( p->iLimit==0 && addrSortIndex>=0 ){
+ sqlite3VdbeGetOp(v, addrSortIndex)->opcode = OP_SorterOpen;
+ p->selFlags |= SF_UseSorter;
+ }
/* Open a virtual index to use for the distinct set.
*/
if( p->selFlags & SF_Distinct ){
- KeyInfo *pKeyInfo;
- assert( isAgg || pGroupBy );
- distinct = pParse->nTab++;
- pKeyInfo = keyInfoFromExprList(pParse, p->pEList);
- sqlite3VdbeAddOp4(v, OP_OpenEphemeral, distinct, 0, 0,
- (char*)pKeyInfo, P4_KEYINFO_HANDOFF);
+ sDistinct.tabTnct = pParse->nTab++;
+ sDistinct.addrTnct = sqlite3VdbeAddOp4(v, OP_OpenEphemeral,
+ sDistinct.tabTnct, 0, 0,
+ (char*)keyInfoFromExprList(pParse, p->pEList),
+ P4_KEYINFO_HANDOFF);
sqlite3VdbeChangeP5(v, BTREE_UNORDERED);
+ sDistinct.eTnctType = WHERE_DISTINCT_UNORDERED;
}else{
- distinct = -1;
+ sDistinct.eTnctType = WHERE_DISTINCT_NOOP;
}
- /* Aggregate and non-aggregate queries are handled differently */
if( !isAgg && pGroupBy==0 ){
- /* This case is for non-aggregate queries
- ** Begin the database scan
- */
- pWInfo = sqlite3WhereBegin(pParse, pTabList, pWhere, &pOrderBy, 0);
+ /* No aggregate functions and no GROUP BY clause */
+ ExprList *pDist = (sDistinct.isTnct ? p->pEList : 0);
+
+ /* Begin the database scan. */
+ pWInfo = sqlite3WhereBegin(pParse, pTabList, pWhere, pOrderBy, pDist, 0,0);
if( pWInfo==0 ) goto select_end;
if( pWInfo->nRowOut < p->nSelectRow ) p->nSelectRow = pWInfo->nRowOut;
+ if( pWInfo->eDistinct ) sDistinct.eTnctType = pWInfo->eDistinct;
+ if( pOrderBy && pWInfo->nOBSat==pOrderBy->nExpr ) pOrderBy = 0;
/* If sorting index that was created by a prior OP_OpenEphemeral
** instruction ended up not being needed, then change the OP_OpenEphemeral
** into an OP_Noop.
*/
if( addrSortIndex>=0 && pOrderBy==0 ){
- sqlite3VdbeChangeToNoop(v, addrSortIndex, 1);
+ sqlite3VdbeChangeToNoop(v, addrSortIndex);
p->addrOpenEphm[2] = -1;
}
- /* Use the standard inner loop
- */
- assert(!isDistinct);
- selectInnerLoop(pParse, p, pEList, 0, 0, pOrderBy, -1, pDest,
+ /* Use the standard inner loop. */
+ selectInnerLoop(pParse, p, pEList, 0, 0, pOrderBy, &sDistinct, pDest,
pWInfo->iContinue, pWInfo->iBreak);
/* End the database scan loop.
*/
sqlite3WhereEnd(pWInfo);
}else{
- /* This is the processing for aggregate queries */
+ /* This case when there exist aggregate functions or a GROUP BY clause
+ ** or both */
NameContext sNC; /* Name context for processing aggregate information */
int iAMem; /* First Mem address for storing current GROUP BY */
int iBMem; /* First Mem address for previous GROUP BY */
@@ -94454,6 +98947,8 @@ SQLITE_PRIVATE int sqlite3Select(
int iAbortFlag; /* Mem address which causes query abort if positive */
int groupBySort; /* Rows come from source in GROUP BY order */
int addrEnd; /* End of processing for this SELECT */
+ int sortPTab = 0; /* Pseudotable used to decode sorting results */
+ int sortOut = 0; /* Output register from the sorter */
/* Remove any and all aliases between the result set and the
** GROUP BY clause.
@@ -94495,7 +98990,9 @@ SQLITE_PRIVATE int sqlite3Select(
sAggInfo.nAccumulator = sAggInfo.nColumn;
for(i=0; i<sAggInfo.nFunc; i++){
assert( !ExprHasProperty(sAggInfo.aFunc[i].pExpr, EP_xIsSelect) );
+ sNC.ncFlags |= NC_InAggFunc;
sqlite3ExprAnalyzeAggList(&sNC, sAggInfo.aFunc[i].pExpr->x.pList);
+ sNC.ncFlags &= ~NC_InAggFunc;
}
if( db->mallocFailed ) goto select_end;
@@ -94515,12 +99012,12 @@ SQLITE_PRIVATE int sqlite3Select(
/* If there is a GROUP BY clause we might need a sorting index to
** implement it. Allocate that sorting index now. If it turns out
- ** that we do not need it after all, the OpenEphemeral instruction
+ ** that we do not need it after all, the OP_SorterOpen instruction
** will be converted into a Noop.
*/
sAggInfo.sortingIdx = pParse->nTab++;
pKeyInfo = keyInfoFromExprList(pParse, pGroupBy);
- addrSortingIdx = sqlite3VdbeAddOp4(v, OP_OpenEphemeral,
+ addrSortingIdx = sqlite3VdbeAddOp4(v, OP_SorterOpen,
sAggInfo.sortingIdx, sAggInfo.nSortingColumn,
0, (char*)pKeyInfo, P4_KEYINFO_HANDOFF);
@@ -94540,6 +99037,7 @@ SQLITE_PRIVATE int sqlite3Select(
VdbeComment((v, "clear abort flag"));
sqlite3VdbeAddOp2(v, OP_Integer, 0, iUseFlag);
VdbeComment((v, "indicate accumulator empty"));
+ sqlite3VdbeAddOp3(v, OP_Null, 0, iAMem, iAMem+pGroupBy->nExpr-1);
/* Begin a loop that will extract all source rows in GROUP BY order.
** This might involve two separate loops with an OP_Sort in between, or
@@ -94547,14 +99045,13 @@ SQLITE_PRIVATE int sqlite3Select(
** in the right order to begin with.
*/
sqlite3VdbeAddOp2(v, OP_Gosub, regReset, addrReset);
- pWInfo = sqlite3WhereBegin(pParse, pTabList, pWhere, &pGroupBy, 0);
+ pWInfo = sqlite3WhereBegin(pParse, pTabList, pWhere, pGroupBy, 0, 0, 0);
if( pWInfo==0 ) goto select_end;
- if( pGroupBy==0 ){
+ if( pWInfo->nOBSat==pGroupBy->nExpr ){
/* The optimizer is able to deliver rows in group by order so
** we do not have to sort. The OP_OpenEphemeral table will be
** cancelled later because we still need to use the pKeyInfo
*/
- pGroupBy = p->pGroupBy;
groupBySort = 0;
}else{
/* Rows are coming out in undetermined order. We have to push
@@ -94568,7 +99065,8 @@ SQLITE_PRIVATE int sqlite3Select(
int nGroupBy;
explainTempTable(pParse,
- isDistinct && !(p->selFlags&SF_Distinct)?"DISTINCT":"GROUP BY");
+ (sDistinct.isTnct && (p->selFlags&SF_Distinct)==0) ?
+ "DISTINCT" : "GROUP BY");
groupBySort = 1;
nGroupBy = pGroupBy->nExpr;
@@ -94592,7 +99090,7 @@ SQLITE_PRIVATE int sqlite3Select(
int r2;
r2 = sqlite3ExprCodeGetColumn(pParse,
- pCol->pTab, pCol->iColumn, pCol->iTable, r1);
+ pCol->pTab, pCol->iColumn, pCol->iTable, r1, 0);
if( r1!=r2 ){
sqlite3VdbeAddOp2(v, OP_SCopy, r2, r1);
}
@@ -94601,11 +99099,14 @@ SQLITE_PRIVATE int sqlite3Select(
}
regRecord = sqlite3GetTempReg(pParse);
sqlite3VdbeAddOp3(v, OP_MakeRecord, regBase, nCol, regRecord);
- sqlite3VdbeAddOp2(v, OP_IdxInsert, sAggInfo.sortingIdx, regRecord);
+ sqlite3VdbeAddOp2(v, OP_SorterInsert, sAggInfo.sortingIdx, regRecord);
sqlite3ReleaseTempReg(pParse, regRecord);
sqlite3ReleaseTempRange(pParse, regBase, nCol);
sqlite3WhereEnd(pWInfo);
- sqlite3VdbeAddOp2(v, OP_Sort, sAggInfo.sortingIdx, addrEnd);
+ sAggInfo.sortingIdxPTab = sortPTab = pParse->nTab++;
+ sortOut = sqlite3GetTempReg(pParse);
+ sqlite3VdbeAddOp3(v, OP_OpenPseudo, sortPTab, sortOut, nCol);
+ sqlite3VdbeAddOp2(v, OP_SorterSort, sAggInfo.sortingIdx, addrEnd);
VdbeComment((v, "GROUP BY sort"));
sAggInfo.useSortingIdx = 1;
sqlite3ExprCacheClear(pParse);
@@ -94618,9 +99119,13 @@ SQLITE_PRIVATE int sqlite3Select(
*/
addrTopOfLoop = sqlite3VdbeCurrentAddr(v);
sqlite3ExprCacheClear(pParse);
+ if( groupBySort ){
+ sqlite3VdbeAddOp2(v, OP_SorterData, sAggInfo.sortingIdx, sortOut);
+ }
for(j=0; j<pGroupBy->nExpr; j++){
if( groupBySort ){
- sqlite3VdbeAddOp3(v, OP_Column, sAggInfo.sortingIdx, j, iBMem+j);
+ sqlite3VdbeAddOp3(v, OP_Column, sortPTab, j, iBMem+j);
+ if( j==0 ) sqlite3VdbeChangeP5(v, OPFLAG_CLEARCACHE);
}else{
sAggInfo.directMode = 1;
sqlite3ExprCode(pParse, pGroupBy->a[j].pExpr, iBMem+j);
@@ -94659,10 +99164,10 @@ SQLITE_PRIVATE int sqlite3Select(
/* End of the loop
*/
if( groupBySort ){
- sqlite3VdbeAddOp2(v, OP_Next, sAggInfo.sortingIdx, addrTopOfLoop);
+ sqlite3VdbeAddOp2(v, OP_SorterNext, sAggInfo.sortingIdx, addrTopOfLoop);
}else{
sqlite3WhereEnd(pWInfo);
- sqlite3VdbeChangeToNoop(v, addrSortingIdx, 1);
+ sqlite3VdbeChangeToNoop(v, addrSortingIdx);
}
/* Output the final row of result
@@ -94693,7 +99198,7 @@ SQLITE_PRIVATE int sqlite3Select(
finalizeAggFunctions(pParse, &sAggInfo);
sqlite3ExprIfFalse(pParse, pHaving, addrOutputRow+1, SQLITE_JUMPIFNULL);
selectInnerLoop(pParse, p, p->pEList, 0, 0, pOrderBy,
- distinct, pDest,
+ &sDistinct, pDest,
addrOutputRow+1, addrSetAbort);
sqlite3VdbeAddOp1(v, OP_Return, regOutputRow);
VdbeComment((v, "end groupby result generator"));
@@ -94781,7 +99286,7 @@ SQLITE_PRIVATE int sqlite3Select(
** value of x, the only row required).
**
** A special flag must be passed to sqlite3WhereBegin() to slightly
- ** modify behaviour as follows:
+ ** modify behavior as follows:
**
** + If the query is a "SELECT min(x)", then the loop coded by
** where.c should not iterate over any values with a NULL value
@@ -94793,10 +99298,17 @@ SQLITE_PRIVATE int sqlite3Select(
** Refer to code and comments in where.c for details.
*/
ExprList *pMinMax = 0;
- u8 flag = minMaxQuery(p);
+ u8 flag = WHERE_ORDERBY_NORMAL;
+
+ assert( p->pGroupBy==0 );
+ assert( flag==0 );
+ if( p->pHaving==0 ){
+ flag = minMaxQuery(&sAggInfo, &pMinMax);
+ }
+ assert( flag==0 || (pMinMax!=0 && pMinMax->nExpr==1) );
+
if( flag ){
- assert( !ExprHasProperty(p->pEList->a[0].pExpr, EP_xIsSelect) );
- pMinMax = sqlite3ExprListDup(db, p->pEList->a[0].pExpr->x.pList,0);
+ pMinMax = sqlite3ExprListDup(db, pMinMax, 0);
pDel = pMinMax;
if( pMinMax && !db->mallocFailed ){
pMinMax->a[0].sortOrder = flag!=WHERE_ORDERBY_MIN ?1:0;
@@ -94809,13 +99321,14 @@ SQLITE_PRIVATE int sqlite3Select(
** of output.
*/
resetAccumulator(pParse, &sAggInfo);
- pWInfo = sqlite3WhereBegin(pParse, pTabList, pWhere, &pMinMax, flag);
+ pWInfo = sqlite3WhereBegin(pParse, pTabList, pWhere, pMinMax,0,flag,0);
if( pWInfo==0 ){
sqlite3ExprListDelete(db, pDel);
goto select_end;
}
updateAccumulator(pParse, &sAggInfo);
- if( !pMinMax && flag ){
+ assert( pMinMax==0 || pMinMax->nExpr==1 );
+ if( pWInfo->nOBSat>0 ){
sqlite3VdbeAddOp2(v, OP_Goto, 0, pWInfo->iBreak);
VdbeComment((v, "%s() by index",
(flag==WHERE_ORDERBY_MIN?"min":"max")));
@@ -94826,7 +99339,7 @@ SQLITE_PRIVATE int sqlite3Select(
pOrderBy = 0;
sqlite3ExprIfFalse(pParse, pHaving, addrEnd, SQLITE_JUMPIFNULL);
- selectInnerLoop(pParse, p, p->pEList, 0, 0, 0, -1,
+ selectInnerLoop(pParse, p, p->pEList, 0, 0, 0, 0,
pDest, addrEnd, addrEnd);
sqlite3ExprListDelete(db, pDel);
}
@@ -94834,7 +99347,7 @@ SQLITE_PRIVATE int sqlite3Select(
} /* endif aggregate query */
- if( distinct>=0 ){
+ if( sDistinct.eTnctType==WHERE_DISTINCT_UNORDERED ){
explainTempTable(pParse, "DISTINCT");
}
@@ -94872,101 +99385,104 @@ select_end:
return rc;
}
-#if defined(SQLITE_DEBUG)
+#if defined(SQLITE_ENABLE_TREE_EXPLAIN)
/*
-*******************************************************************************
-** The following code is used for testing and debugging only. The code
-** that follows does not appear in normal builds.
-**
-** These routines are used to print out the content of all or part of a
-** parse structures such as Select or Expr. Such printouts are useful
-** for helping to understand what is happening inside the code generator
-** during the execution of complex SELECT statements.
-**
-** These routine are not called anywhere from within the normal
-** code base. Then are intended to be called from within the debugger
-** or from temporary "printf" statements inserted for debugging.
+** Generate a human-readable description of a the Select object.
*/
-SQLITE_PRIVATE void sqlite3PrintExpr(Expr *p){
- if( !ExprHasProperty(p, EP_IntValue) && p->u.zToken ){
- sqlite3DebugPrintf("(%s", p->u.zToken);
- }else{
- sqlite3DebugPrintf("(%d", p->op);
- }
- if( p->pLeft ){
- sqlite3DebugPrintf(" ");
- sqlite3PrintExpr(p->pLeft);
- }
- if( p->pRight ){
- sqlite3DebugPrintf(" ");
- sqlite3PrintExpr(p->pRight);
- }
- sqlite3DebugPrintf(")");
-}
-SQLITE_PRIVATE void sqlite3PrintExprList(ExprList *pList){
- int i;
- for(i=0; i<pList->nExpr; i++){
- sqlite3PrintExpr(pList->a[i].pExpr);
- if( i<pList->nExpr-1 ){
- sqlite3DebugPrintf(", ");
+static void explainOneSelect(Vdbe *pVdbe, Select *p){
+ sqlite3ExplainPrintf(pVdbe, "SELECT ");
+ if( p->selFlags & (SF_Distinct|SF_Aggregate) ){
+ if( p->selFlags & SF_Distinct ){
+ sqlite3ExplainPrintf(pVdbe, "DISTINCT ");
+ }
+ if( p->selFlags & SF_Aggregate ){
+ sqlite3ExplainPrintf(pVdbe, "agg_flag ");
}
+ sqlite3ExplainNL(pVdbe);
+ sqlite3ExplainPrintf(pVdbe, " ");
}
-}
-SQLITE_PRIVATE void sqlite3PrintSelect(Select *p, int indent){
- sqlite3DebugPrintf("%*sSELECT(%p) ", indent, "", p);
- sqlite3PrintExprList(p->pEList);
- sqlite3DebugPrintf("\n");
- if( p->pSrc ){
- char *zPrefix;
+ sqlite3ExplainExprList(pVdbe, p->pEList);
+ sqlite3ExplainNL(pVdbe);
+ if( p->pSrc && p->pSrc->nSrc ){
int i;
- zPrefix = "FROM";
+ sqlite3ExplainPrintf(pVdbe, "FROM ");
+ sqlite3ExplainPush(pVdbe);
for(i=0; i<p->pSrc->nSrc; i++){
struct SrcList_item *pItem = &p->pSrc->a[i];
- sqlite3DebugPrintf("%*s ", indent+6, zPrefix);
- zPrefix = "";
+ sqlite3ExplainPrintf(pVdbe, "{%d,*} = ", pItem->iCursor);
if( pItem->pSelect ){
- sqlite3DebugPrintf("(\n");
- sqlite3PrintSelect(pItem->pSelect, indent+10);
- sqlite3DebugPrintf("%*s)", indent+8, "");
+ sqlite3ExplainSelect(pVdbe, pItem->pSelect);
+ if( pItem->pTab ){
+ sqlite3ExplainPrintf(pVdbe, " (tabname=%s)", pItem->pTab->zName);
+ }
}else if( pItem->zName ){
- sqlite3DebugPrintf("%s", pItem->zName);
- }
- if( pItem->pTab ){
- sqlite3DebugPrintf("(table: %s)", pItem->pTab->zName);
+ sqlite3ExplainPrintf(pVdbe, "%s", pItem->zName);
}
if( pItem->zAlias ){
- sqlite3DebugPrintf(" AS %s", pItem->zAlias);
+ sqlite3ExplainPrintf(pVdbe, " (AS %s)", pItem->zAlias);
}
- if( i<p->pSrc->nSrc-1 ){
- sqlite3DebugPrintf(",");
+ if( pItem->jointype & JT_LEFT ){
+ sqlite3ExplainPrintf(pVdbe, " LEFT-JOIN");
}
- sqlite3DebugPrintf("\n");
+ sqlite3ExplainNL(pVdbe);
}
+ sqlite3ExplainPop(pVdbe);
}
if( p->pWhere ){
- sqlite3DebugPrintf("%*s WHERE ", indent, "");
- sqlite3PrintExpr(p->pWhere);
- sqlite3DebugPrintf("\n");
+ sqlite3ExplainPrintf(pVdbe, "WHERE ");
+ sqlite3ExplainExpr(pVdbe, p->pWhere);
+ sqlite3ExplainNL(pVdbe);
}
if( p->pGroupBy ){
- sqlite3DebugPrintf("%*s GROUP BY ", indent, "");
- sqlite3PrintExprList(p->pGroupBy);
- sqlite3DebugPrintf("\n");
+ sqlite3ExplainPrintf(pVdbe, "GROUPBY ");
+ sqlite3ExplainExprList(pVdbe, p->pGroupBy);
+ sqlite3ExplainNL(pVdbe);
}
if( p->pHaving ){
- sqlite3DebugPrintf("%*s HAVING ", indent, "");
- sqlite3PrintExpr(p->pHaving);
- sqlite3DebugPrintf("\n");
+ sqlite3ExplainPrintf(pVdbe, "HAVING ");
+ sqlite3ExplainExpr(pVdbe, p->pHaving);
+ sqlite3ExplainNL(pVdbe);
}
if( p->pOrderBy ){
- sqlite3DebugPrintf("%*s ORDER BY ", indent, "");
- sqlite3PrintExprList(p->pOrderBy);
- sqlite3DebugPrintf("\n");
+ sqlite3ExplainPrintf(pVdbe, "ORDERBY ");
+ sqlite3ExplainExprList(pVdbe, p->pOrderBy);
+ sqlite3ExplainNL(pVdbe);
+ }
+ if( p->pLimit ){
+ sqlite3ExplainPrintf(pVdbe, "LIMIT ");
+ sqlite3ExplainExpr(pVdbe, p->pLimit);
+ sqlite3ExplainNL(pVdbe);
+ }
+ if( p->pOffset ){
+ sqlite3ExplainPrintf(pVdbe, "OFFSET ");
+ sqlite3ExplainExpr(pVdbe, p->pOffset);
+ sqlite3ExplainNL(pVdbe);
}
}
+SQLITE_PRIVATE void sqlite3ExplainSelect(Vdbe *pVdbe, Select *p){
+ if( p==0 ){
+ sqlite3ExplainPrintf(pVdbe, "(null-select)");
+ return;
+ }
+ while( p->pPrior ){
+ p->pPrior->pNext = p;
+ p = p->pPrior;
+ }
+ sqlite3ExplainPush(pVdbe);
+ while( p ){
+ explainOneSelect(pVdbe, p);
+ p = p->pNext;
+ if( p==0 ) break;
+ sqlite3ExplainNL(pVdbe);
+ sqlite3ExplainPrintf(pVdbe, "%s\n", selectOpName(p->op));
+ }
+ sqlite3ExplainPrintf(pVdbe, "END");
+ sqlite3ExplainPop(pVdbe);
+}
+
/* End of the structure debug printing code
*****************************************************************************/
-#endif /* defined(SQLITE_TEST) || defined(SQLITE_DEBUG) */
+#endif /* defined(SQLITE_ENABLE_TREE_EXPLAIN) */
/************** End of select.c **********************************************/
/************** Begin file table.c *******************************************/
@@ -94988,6 +99504,8 @@ SQLITE_PRIVATE void sqlite3PrintSelect(Select *p, int indent){
** These routines are in a separate files so that they will not be linked
** if they are not used.
*/
+/* #include <stdlib.h> */
+/* #include <string.h> */
#ifndef SQLITE_OMIT_GET_TABLE
@@ -95279,21 +99797,34 @@ SQLITE_PRIVATE void sqlite3BeginTrigger(
iDb = 1;
pName = pName1;
}else{
- /* Figure out the db that the the trigger will be created in */
+ /* Figure out the db that the trigger will be created in */
iDb = sqlite3TwoPartName(pParse, pName1, pName2, &pName);
if( iDb<0 ){
goto trigger_cleanup;
}
}
+ if( !pTableName || db->mallocFailed ){
+ goto trigger_cleanup;
+ }
+
+ /* A long-standing parser bug is that this syntax was allowed:
+ **
+ ** CREATE TRIGGER attached.demo AFTER INSERT ON attached.tab ....
+ ** ^^^^^^^^
+ **
+ ** To maintain backwards compatibility, ignore the database
+ ** name on pTableName if we are reparsing our of SQLITE_MASTER.
+ */
+ if( db->init.busy && iDb!=1 ){
+ sqlite3DbFree(db, pTableName->a[0].zDatabase);
+ pTableName->a[0].zDatabase = 0;
+ }
/* If the trigger name was unqualified, and the table is a temp table,
** then set iDb to 1 to create the trigger in the temporary database.
** If sqlite3SrcListLookup() returns 0, indicating the table does not
** exist, the error is caught by the block below.
*/
- if( !pTableName || db->mallocFailed ){
- goto trigger_cleanup;
- }
pTab = sqlite3SrcListLookup(pParse, pTableName);
if( db->init.busy==0 && pName2->n==0 && pTab
&& pTab->pSchema==db->aDb[1].pSchema ){
@@ -95884,6 +100415,15 @@ static int codeTriggerProgram(
*/
pParse->eOrconf = (orconf==OE_Default)?pStep->orconf:(u8)orconf;
+ /* Clear the cookieGoto flag. When coding triggers, the cookieGoto
+ ** variable is used as a flag to indicate to sqlite3ExprCodeConstants()
+ ** that it is not safe to refactor constants (this happens after the
+ ** start of the first loop in the SQL statement is coded - at that
+ ** point code may be conditionally executed, so it is no longer safe to
+ ** initialize constant register values). */
+ assert( pParse->cookieGoto==0 || pParse->cookieGoto==-1 );
+ pParse->cookieGoto = 0;
+
switch( pStep->op ){
case TK_UPDATE: {
sqlite3Update(pParse,
@@ -96059,6 +100599,7 @@ static TriggerPrg *codeRowTrigger(
}
pProgram->nMem = pSubParse->nMem;
pProgram->nCsr = pSubParse->nTab;
+ pProgram->nOnce = pSubParse->nOnce;
pProgram->token = (void *)pTrigger;
pPrg->aColmask[0] = pSubParse->oldmask;
pPrg->aColmask[1] = pSubParse->newmask;
@@ -96406,8 +100947,8 @@ SQLITE_PRIVATE void sqlite3Update(
int regRowCount = 0; /* A count of rows changed */
int regOldRowid; /* The old rowid */
int regNewRowid; /* The new rowid */
- int regNew;
- int regOld = 0;
+ int regNew; /* Content of the NEW.* table in triggers */
+ int regOld = 0; /* Content of OLD.* table in triggers */
int regRowSet = 0; /* Rowset of rows to be updated */
memset(&sContext, 0, sizeof(sContext));
@@ -96556,6 +101097,7 @@ SQLITE_PRIVATE void sqlite3Update(
#endif
/* Allocate required registers. */
+ regRowSet = ++pParse->nMem;
regOldRowid = regNewRowid = ++pParse->nMem;
if( pTrigger || hasFK ){
regOld = pParse->nMem + 1;
@@ -96590,8 +101132,10 @@ SQLITE_PRIVATE void sqlite3Update(
/* Begin the database scan
*/
- sqlite3VdbeAddOp2(v, OP_Null, 0, regOldRowid);
- pWInfo = sqlite3WhereBegin(pParse, pTabList, pWhere,0, WHERE_ONEPASS_DESIRED);
+ sqlite3VdbeAddOp3(v, OP_Null, 0, regRowSet, regOldRowid);
+ pWInfo = sqlite3WhereBegin(
+ pParse, pTabList, pWhere, 0, 0, WHERE_ONEPASS_DESIRED, 0
+ );
if( pWInfo==0 ) goto update_cleanup;
okOnePass = pWInfo->okOnePass;
@@ -96599,7 +101143,6 @@ SQLITE_PRIVATE void sqlite3Update(
*/
sqlite3VdbeAddOp2(v, OP_Rowid, iCur, regOldRowid);
if( !okOnePass ){
- regRowSet = ++pParse->nMem;
sqlite3VdbeAddOp2(v, OP_RowSetAdd, regRowSet, regOldRowid);
}
@@ -96634,6 +101177,7 @@ SQLITE_PRIVATE void sqlite3Update(
}
}
for(i=0, pIdx=pTab->pIndex; pIdx; pIdx=pIdx->pNext, i++){
+ assert( aRegIdx );
if( openAll || aRegIdx[i]>0 ){
KeyInfo *pKey = sqlite3IndexKeyinfo(pParse, pIdx);
sqlite3VdbeAddOp4(v, OP_OpenWrite, iCur+i+1, pIdx->tnum, iDb,
@@ -96702,9 +101246,10 @@ SQLITE_PRIVATE void sqlite3Update(
newmask = sqlite3TriggerColmask(
pParse, pTrigger, pChanges, 1, TRIGGER_BEFORE, pTab, onError
);
+ sqlite3VdbeAddOp3(v, OP_Null, 0, regNew, regNew+pTab->nCol-1);
for(i=0; i<pTab->nCol; i++){
if( i==pTab->iPKey ){
- sqlite3VdbeAddOp2(v, OP_Null, 0, regNew+i);
+ /*sqlite3VdbeAddOp2(v, OP_Null, 0, regNew+i);*/
}else{
j = aXRef[i];
if( j>=0 ){
@@ -96734,7 +101279,7 @@ SQLITE_PRIVATE void sqlite3Update(
/* The row-trigger may have deleted the row being updated. In this
** case, jump to the next row. No updates or AFTER triggers are
- ** required. This behaviour - what happens when the row being updated
+ ** required. This behavior - what happens when the row being updated
** is deleted or renamed by a BEFORE trigger - is left undefined in the
** documentation.
*/
@@ -96807,6 +101352,7 @@ SQLITE_PRIVATE void sqlite3Update(
/* Close all tables */
for(i=0, pIdx=pTab->pIndex; pIdx; pIdx=pIdx->pNext, i++){
+ assert( aRegIdx );
if( openAll || aRegIdx[i]>0 ){
sqlite3VdbeAddOp2(v, OP_Close, iCur+i+1, 0);
}
@@ -96994,7 +101540,7 @@ static int execSql(sqlite3 *db, char **pzErrMsg, const char *zSql){
return sqlite3_errcode(db);
}
VVA_ONLY( rc = ) sqlite3_step(pStmt);
- assert( rc!=SQLITE_ROW );
+ assert( rc!=SQLITE_ROW || (db->flags&SQLITE_CountRows) );
return vacuumFinalize(db, pStmt, pzErrMsg);
}
@@ -97034,6 +101580,7 @@ SQLITE_PRIVATE void sqlite3Vacuum(Parse *pParse){
Vdbe *v = sqlite3GetVdbe(pParse);
if( v ){
sqlite3VdbeAddOp2(v, OP_Vacuum, 0, 0);
+ sqlite3VdbeUsesBtree(v, 0);
}
return;
}
@@ -97125,6 +101672,18 @@ SQLITE_PRIVATE int sqlite3RunVacuum(char **pzErrMsg, sqlite3 *db){
}
#endif
+ rc = execSql(db, pzErrMsg, "PRAGMA vacuum_db.synchronous=OFF");
+ if( rc!=SQLITE_OK ) goto end_of_vacuum;
+
+ /* Begin a transaction and take an exclusive lock on the main database
+ ** file. This is done before the sqlite3BtreeGetPageSize(pMain) call below,
+ ** to ensure that we do not try to change the page-size on a WAL database.
+ */
+ rc = execSql(db, pzErrMsg, "BEGIN;");
+ if( rc!=SQLITE_OK ) goto end_of_vacuum;
+ rc = sqlite3BtreeBeginTrans(pMain, 2);
+ if( rc!=SQLITE_OK ) goto end_of_vacuum;
+
/* Do not attempt to change the page size for a WAL database */
if( sqlite3PagerGetJournalMode(sqlite3BtreePager(pMain))
==PAGER_JOURNALMODE_WAL ){
@@ -97138,20 +101697,12 @@ SQLITE_PRIVATE int sqlite3RunVacuum(char **pzErrMsg, sqlite3 *db){
rc = SQLITE_NOMEM;
goto end_of_vacuum;
}
- rc = execSql(db, pzErrMsg, "PRAGMA vacuum_db.synchronous=OFF");
- if( rc!=SQLITE_OK ){
- goto end_of_vacuum;
- }
#ifndef SQLITE_OMIT_AUTOVACUUM
sqlite3BtreeSetAutoVacuum(pTemp, db->nextAutovac>=0 ? db->nextAutovac :
sqlite3BtreeGetAutoVacuum(pMain));
#endif
- /* Begin a transaction */
- rc = execSql(db, pzErrMsg, "BEGIN EXCLUSIVE;");
- if( rc!=SQLITE_OK ) goto end_of_vacuum;
-
/* Query the schema of the main database. Create a mirror schema
** in the temporary database.
*/
@@ -97212,13 +101763,11 @@ SQLITE_PRIVATE int sqlite3RunVacuum(char **pzErrMsg, sqlite3 *db){
);
if( rc ) goto end_of_vacuum;
- /* At this point, unless the main db was completely empty, there is now a
- ** transaction open on the vacuum database, but not on the main database.
- ** Open a btree level transaction on the main database. This allows a
- ** call to sqlite3BtreeCopyFile(). The main database btree level
- ** transaction is then committed, so the SQL level never knows it was
- ** opened for writing. This way, the SQL transaction used to create the
- ** temporary database never needs to be committed.
+ /* At this point, there is a write transaction open on both the
+ ** vacuum database and the main database. Assuming no error occurs,
+ ** both transactions are closed by this block - the main database
+ ** transaction by sqlite3BtreeCopyFile() and the other by an explicit
+ ** call to sqlite3BtreeCommit().
*/
{
u32 meta;
@@ -97286,7 +101835,7 @@ end_of_vacuum:
/* This both clears the schemas and reduces the size of the db->aDb[]
** array. */
- sqlite3ResetInternalSchema(db, -1);
+ sqlite3ResetAllSchemasOfConnection(db);
return rc;
}
@@ -97318,8 +101867,8 @@ end_of_vacuum:
** are invoked only from within xCreate and xConnect methods.
*/
struct VtabCtx {
- Table *pTab;
- VTable *pVTable;
+ VTable *pVTable; /* The virtual table being constructed */
+ Table *pTab; /* The Table object to which the virtual table belongs */
};
/*
@@ -97334,33 +101883,35 @@ static int createModule(
void *pAux, /* Context pointer for xCreate/xConnect */
void (*xDestroy)(void *) /* Module destructor function */
){
- int rc, nName;
- Module *pMod;
+ int rc = SQLITE_OK;
+ int nName;
sqlite3_mutex_enter(db->mutex);
nName = sqlite3Strlen30(zName);
- pMod = (Module *)sqlite3DbMallocRaw(db, sizeof(Module) + nName + 1);
- if( pMod ){
- Module *pDel;
- char *zCopy = (char *)(&pMod[1]);
- memcpy(zCopy, zName, nName+1);
- pMod->zName = zCopy;
- pMod->pModule = pModule;
- pMod->pAux = pAux;
- pMod->xDestroy = xDestroy;
- pDel = (Module *)sqlite3HashInsert(&db->aModule, zCopy, nName, (void*)pMod);
- if( pDel && pDel->xDestroy ){
- sqlite3ResetInternalSchema(db, -1);
- pDel->xDestroy(pDel->pAux);
- }
- sqlite3DbFree(db, pDel);
- if( pDel==pMod ){
- db->mallocFailed = 1;
+ if( sqlite3HashFind(&db->aModule, zName, nName) ){
+ rc = SQLITE_MISUSE_BKPT;
+ }else{
+ Module *pMod;
+ pMod = (Module *)sqlite3DbMallocRaw(db, sizeof(Module) + nName + 1);
+ if( pMod ){
+ Module *pDel;
+ char *zCopy = (char *)(&pMod[1]);
+ memcpy(zCopy, zName, nName+1);
+ pMod->zName = zCopy;
+ pMod->pModule = pModule;
+ pMod->pAux = pAux;
+ pMod->xDestroy = xDestroy;
+ pDel = (Module *)sqlite3HashInsert(&db->aModule,zCopy,nName,(void*)pMod);
+ assert( pDel==0 || pDel==pMod );
+ if( pDel ){
+ db->mallocFailed = 1;
+ sqlite3DbFree(db, pDel);
+ }
}
- }else if( xDestroy ){
- xDestroy(pAux);
}
- rc = sqlite3ApiExit(db, SQLITE_OK);
+ rc = sqlite3ApiExit(db, rc);
+ if( rc!=SQLITE_OK && xDestroy ) xDestroy(pAux);
+
sqlite3_mutex_leave(db->mutex);
return rc;
}
@@ -97425,7 +101976,7 @@ SQLITE_PRIVATE void sqlite3VtabUnlock(VTable *pVTab){
assert( db );
assert( pVTab->nRef>0 );
- assert( sqlite3SafetyCheckOk(db) );
+ assert( db->magic==SQLITE_MAGIC_OPEN || db->magic==SQLITE_MAGIC_ZOMBIE );
pVTab->nRef--;
if( pVTab->nRef==0 ){
@@ -97476,6 +102027,31 @@ static VTable *vtabDisconnectAll(sqlite3 *db, Table *p){
return pRet;
}
+/*
+** Table *p is a virtual table. This function removes the VTable object
+** for table *p associated with database connection db from the linked
+** list in p->pVTab. It also decrements the VTable ref count. This is
+** used when closing database connection db to free all of its VTable
+** objects without disturbing the rest of the Schema object (which may
+** be being used by other shared-cache connections).
+*/
+SQLITE_PRIVATE void sqlite3VtabDisconnect(sqlite3 *db, Table *p){
+ VTable **ppVTab;
+
+ assert( IsVirtual(p) );
+ assert( sqlite3BtreeHoldsAllMutexes(db) );
+ assert( sqlite3_mutex_held(db->mutex) );
+
+ for(ppVTab=&p->pVTable; *ppVTab; ppVTab=&(*ppVTab)->pNext){
+ if( (*ppVTab)->db==db ){
+ VTable *pVTab = *ppVTab;
+ *ppVTab = pVTab->pNext;
+ sqlite3VtabUnlock(pVTab);
+ break;
+ }
+ }
+}
+
/*
** Disconnect all the virtual table objects in the sqlite3.pDisconnect list.
@@ -97533,7 +102109,7 @@ SQLITE_PRIVATE void sqlite3VtabClear(sqlite3 *db, Table *p){
if( p->azModuleArg ){
int i;
for(i=0; i<p->nModuleArg; i++){
- sqlite3DbFree(db, p->azModuleArg[i]);
+ if( i!=1 ) sqlite3DbFree(db, p->azModuleArg[i]);
}
sqlite3DbFree(db, p->azModuleArg);
}
@@ -97574,13 +102150,14 @@ SQLITE_PRIVATE void sqlite3VtabBeginParse(
Parse *pParse, /* Parsing context */
Token *pName1, /* Name of new table, or database name */
Token *pName2, /* Name of new table or NULL */
- Token *pModuleName /* Name of the module for the virtual table */
+ Token *pModuleName, /* Name of the module for the virtual table */
+ int ifNotExists /* No error if the table already exists */
){
int iDb; /* The database the table is being created in */
Table *pTable; /* The new virtual table */
sqlite3 *db; /* Database connection */
- sqlite3StartTable(pParse, pName1, pName2, 0, 0, 1, 0);
+ sqlite3StartTable(pParse, pName1, pName2, 0, 0, 1, ifNotExists);
pTable = pParse->pNewTable;
if( pTable==0 ) return;
assert( 0==pTable->pIndex );
@@ -97592,7 +102169,7 @@ SQLITE_PRIVATE void sqlite3VtabBeginParse(
pTable->tabFlags |= TF_Virtual;
pTable->nModuleArg = 0;
addModuleArgument(db, pTable, sqlite3NameFromToken(db, pModuleName));
- addModuleArgument(db, pTable, sqlite3DbStrDup(db, db->aDb[iDb].zName));
+ addModuleArgument(db, pTable, 0);
addModuleArgument(db, pTable, sqlite3DbStrDup(db, pTable->zName));
pParse->sNameToken.n = (int)(&pModuleName->z[pModuleName->n] - pName1->z);
@@ -97615,7 +102192,7 @@ SQLITE_PRIVATE void sqlite3VtabBeginParse(
** virtual table currently under construction in pParse->pTable.
*/
static void addArgumentToVtab(Parse *pParse){
- if( pParse->sArg.z && ALWAYS(pParse->pNewTable) ){
+ if( pParse->sArg.z && pParse->pNewTable ){
const char *z = (const char*)pParse->sArg.z;
int n = pParse->sArg.n;
sqlite3 *db = pParse->db;
@@ -97742,13 +102319,14 @@ static int vtabCallConstructor(
int (*xConstruct)(sqlite3*,void*,int,const char*const*,sqlite3_vtab**,char**),
char **pzErr
){
- VtabCtx sCtx;
+ VtabCtx sCtx, *pPriorCtx;
VTable *pVTable;
int rc;
const char *const*azArg = (const char *const*)pTab->azModuleArg;
int nArg = pTab->nModuleArg;
char *zErr = 0;
char *zModuleName = sqlite3MPrintf(db, "%s", pTab->zName);
+ int iDb;
if( !zModuleName ){
return SQLITE_NOMEM;
@@ -97762,14 +102340,18 @@ static int vtabCallConstructor(
pVTable->db = db;
pVTable->pMod = pMod;
+ iDb = sqlite3SchemaToIndex(db, pTab->pSchema);
+ pTab->azModuleArg[1] = db->aDb[iDb].zName;
+
/* Invoke the virtual table constructor */
assert( &db->pVtabCtx );
assert( xConstruct );
sCtx.pTab = pTab;
sCtx.pVTable = pVTable;
+ pPriorCtx = db->pVtabCtx;
db->pVtabCtx = &sCtx;
rc = xConstruct(db, pMod->pAux, nArg, azArg, &pVTable->pVtab, &zErr);
- db->pVtabCtx = 0;
+ db->pVtabCtx = pPriorCtx;
if( rc==SQLITE_NOMEM ) db->mallocFailed = 1;
if( SQLITE_OK!=rc ){
@@ -97795,7 +102377,7 @@ static int vtabCallConstructor(
/* If everything went according to plan, link the new VTable structure
** into the linked list headed by pTab->pVTable. Then loop through the
** columns of the table to see if any of them contain the token "hidden".
- ** If so, set the Column.isHidden flag and remove the token from
+ ** If so, set the Column COLFLAG_HIDDEN flag and remove the token from
** the type string. */
pVTable->pNext = pTab->pVTable;
pTab->pVTable = pVTable;
@@ -97826,7 +102408,7 @@ static int vtabCallConstructor(
assert(zType[i-1]==' ');
zType[i-1] = '\0';
}
- pTab->aCol[iCol].isHidden = 1;
+ pTab->aCol[iCol].colFlags |= COLFLAG_HIDDEN;
}
}
}
@@ -98187,7 +102769,7 @@ SQLITE_PRIVATE int sqlite3VtabSavepoint(sqlite3 *db, int op, int iSavepoint){
for(i=0; rc==SQLITE_OK && i<db->nVTrans; i++){
VTable *pVTab = db->aVTrans[i];
const sqlite3_module *pMod = pVTab->pMod->pModule;
- if( pMod->iVersion>=2 ){
+ if( pVTab->pVtab && pMod->iVersion>=2 ){
int (*xMethod)(sqlite3_vtab *, int);
switch( op ){
case SAVEPOINT_BEGIN:
@@ -98202,7 +102784,7 @@ SQLITE_PRIVATE int sqlite3VtabSavepoint(sqlite3 *db, int op, int iSavepoint){
break;
}
if( xMethod && pVTab->iSavepoint>iSavepoint ){
- rc = xMethod(db->aVTrans[i]->pVtab, iSavepoint);
+ rc = xMethod(pVTab->pVtab, iSavepoint);
}
}
}
@@ -98387,9 +102969,10 @@ SQLITE_API int sqlite3_vtab_config(sqlite3 *db, int op, ...){
** Trace output macros
*/
#if defined(SQLITE_TEST) || defined(SQLITE_DEBUG)
-SQLITE_PRIVATE int sqlite3WhereTrace = 0;
+/***/ int sqlite3WhereTrace = 0;
#endif
-#if defined(SQLITE_TEST) && defined(SQLITE_DEBUG)
+#if defined(SQLITE_DEBUG) \
+ && (defined(SQLITE_TEST) || defined(SQLITE_ENABLE_WHERETRACE))
# define WHERETRACE(X) if(sqlite3WhereTrace) sqlite3DebugPrintf X
#else
# define WHERETRACE(X)
@@ -98461,8 +103044,8 @@ struct WhereTerm {
int leftCursor; /* Cursor number of X in "X <op> <expr>" */
union {
int leftColumn; /* Column number of X in "X <op> <expr>" */
- WhereOrInfo *pOrInfo; /* Extra information if eOperator==WO_OR */
- WhereAndInfo *pAndInfo; /* Extra information if eOperator==WO_AND */
+ WhereOrInfo *pOrInfo; /* Extra information if (eOperator & WO_OR)!=0 */
+ WhereAndInfo *pAndInfo; /* Extra information if (eOperator& WO_AND)!=0 */
} u;
u16 eOperator; /* A WO_xx value describing <op> */
u8 wtFlags; /* TERM_xxx bit flags. See below */
@@ -98482,21 +103065,30 @@ struct WhereTerm {
#define TERM_ORINFO 0x10 /* Need to free the WhereTerm.u.pOrInfo object */
#define TERM_ANDINFO 0x20 /* Need to free the WhereTerm.u.pAndInfo obj */
#define TERM_OR_OK 0x40 /* Used during OR-clause processing */
-#ifdef SQLITE_ENABLE_STAT2
+#ifdef SQLITE_ENABLE_STAT3
# define TERM_VNULL 0x80 /* Manufactured x>NULL or x<=NULL term */
#else
-# define TERM_VNULL 0x00 /* Disabled if not using stat2 */
+# define TERM_VNULL 0x00 /* Disabled if not using stat3 */
#endif
/*
** An instance of the following structure holds all information about a
** WHERE clause. Mostly this is a container for one or more WhereTerms.
+**
+** Explanation of pOuter: For a WHERE clause of the form
+**
+** a AND ((b AND c) OR (d AND e)) AND f
+**
+** There are separate WhereClause objects for the whole clause and for
+** the subclauses "(b AND c)" and "(d AND e)". The pOuter field of the
+** subclauses points to the WhereClause object for the whole clause.
*/
struct WhereClause {
Parse *pParse; /* The parser context */
WhereMaskSet *pMaskSet; /* Mapping of table cursor numbers to bitmasks */
- Bitmask vmask; /* Bitmask identifying virtual table cursors */
+ WhereClause *pOuter; /* Outer conjunction */
u8 op; /* Split operator. TK_AND or TK_OR */
+ u16 wctrlFlags; /* Might include WHERE_AND_ONLY */
int nTerm; /* Number of terms */
int nSlot; /* Number of entries in a[] */
WhereTerm *a; /* Each a[] describes a term of the WHERE cluase */
@@ -98580,6 +103172,7 @@ struct WhereCost {
#define WO_ISNULL 0x080
#define WO_OR 0x100 /* Two or more OR-connected terms */
#define WO_AND 0x200 /* Two or more AND-connected terms */
+#define WO_EQUIV 0x400 /* Of the form A==B, both columns */
#define WO_NOOP 0x800 /* This term does not restrict search space */
#define WO_ALL 0xfff /* Mask of all possible WO_* values */
@@ -98606,17 +103199,55 @@ struct WhereCost {
#define WHERE_COLUMN_NULL 0x00080000 /* x IS NULL */
#define WHERE_INDEXED 0x000f0000 /* Anything that uses an index */
#define WHERE_NOT_FULLSCAN 0x100f3000 /* Does not do a full table scan */
-#define WHERE_IN_ABLE 0x000f1000 /* Able to support an IN operator */
+#define WHERE_IN_ABLE 0x080f1000 /* Able to support an IN operator */
#define WHERE_TOP_LIMIT 0x00100000 /* x<EXPR or x<=EXPR constraint */
#define WHERE_BTM_LIMIT 0x00200000 /* x>EXPR or x>=EXPR constraint */
#define WHERE_BOTH_LIMIT 0x00300000 /* Both x>EXPR and x<EXPR */
-#define WHERE_IDX_ONLY 0x00800000 /* Use index only - omit table */
-#define WHERE_ORDERBY 0x01000000 /* Output will appear in correct order */
-#define WHERE_REVERSE 0x02000000 /* Scan in reverse order */
-#define WHERE_UNIQUE 0x04000000 /* Selects no more than one row */
+#define WHERE_IDX_ONLY 0x00400000 /* Use index only - omit table */
+#define WHERE_ORDERED 0x00800000 /* Output will appear in correct order */
+#define WHERE_REVERSE 0x01000000 /* Scan in reverse order */
+#define WHERE_UNIQUE 0x02000000 /* Selects no more than one row */
+#define WHERE_ALL_UNIQUE 0x04000000 /* This and all prior have one row */
+#define WHERE_OB_UNIQUE 0x00004000 /* Values in ORDER BY columns are
+ ** different for every output row */
#define WHERE_VIRTUALTABLE 0x08000000 /* Use virtual-table processing */
#define WHERE_MULTI_OR 0x10000000 /* OR using multiple indices */
#define WHERE_TEMP_INDEX 0x20000000 /* Uses an ephemeral index */
+#define WHERE_DISTINCT 0x40000000 /* Correct order for DISTINCT */
+#define WHERE_COVER_SCAN 0x80000000 /* Full scan of a covering index */
+
+/*
+** This module contains many separate subroutines that work together to
+** find the best indices to use for accessing a particular table in a query.
+** An instance of the following structure holds context information about the
+** index search so that it can be more easily passed between the various
+** routines.
+*/
+typedef struct WhereBestIdx WhereBestIdx;
+struct WhereBestIdx {
+ Parse *pParse; /* Parser context */
+ WhereClause *pWC; /* The WHERE clause */
+ struct SrcList_item *pSrc; /* The FROM clause term to search */
+ Bitmask notReady; /* Mask of cursors not available */
+ Bitmask notValid; /* Cursors not available for any purpose */
+ ExprList *pOrderBy; /* The ORDER BY clause */
+ ExprList *pDistinct; /* The select-list if query is DISTINCT */
+ sqlite3_index_info **ppIdxInfo; /* Index information passed to xBestIndex */
+ int i, n; /* Which loop is being coded; # of loops */
+ WhereLevel *aLevel; /* Info about outer loops */
+ WhereCost cost; /* Lowest cost query plan */
+};
+
+/*
+** Return TRUE if the probe cost is less than the baseline cost
+*/
+static int compareCost(const WhereCost *pProbe, const WhereCost *pBaseline){
+ if( pProbe->rCost<pBaseline->rCost ) return 1;
+ if( pProbe->rCost>pBaseline->rCost ) return 0;
+ if( pProbe->plan.nOBSat>pBaseline->plan.nOBSat ) return 1;
+ if( pProbe->plan.nRow<pBaseline->plan.nRow ) return 1;
+ return 0;
+}
/*
** Initialize a preallocated WhereClause structure.
@@ -98624,14 +103255,16 @@ struct WhereCost {
static void whereClauseInit(
WhereClause *pWC, /* The WhereClause to be initialized */
Parse *pParse, /* The parsing context */
- WhereMaskSet *pMaskSet /* Mapping from table cursor numbers to bitmasks */
+ WhereMaskSet *pMaskSet, /* Mapping from table cursor numbers to bitmasks */
+ u16 wctrlFlags /* Might include WHERE_AND_ONLY */
){
pWC->pParse = pParse;
pWC->pMaskSet = pMaskSet;
+ pWC->pOuter = 0;
pWC->nTerm = 0;
pWC->nSlot = ArraySize(pWC->aStatic);
pWC->a = pWC->aStatic;
- pWC->vmask = 0;
+ pWC->wctrlFlags = wctrlFlags;
}
/* Forward reference */
@@ -98717,7 +103350,7 @@ static int whereClauseInsert(WhereClause *pWC, Expr *p, u8 wtFlags){
pWC->nSlot = sqlite3DbMallocSize(db, pWC->a)/sizeof(pWC->a[0]);
}
pTerm = &pWC->a[idx = pWC->nTerm++];
- pTerm->pExpr = p;
+ pTerm->pExpr = sqlite3ExprSkipCollate(p);
pTerm->wtFlags = wtFlags;
pTerm->pWC = pWC;
pTerm->iParent = -1;
@@ -98830,11 +103463,19 @@ static Bitmask exprListTableUsage(WhereMaskSet *pMaskSet, ExprList *pList){
static Bitmask exprSelectTableUsage(WhereMaskSet *pMaskSet, Select *pS){
Bitmask mask = 0;
while( pS ){
+ SrcList *pSrc = pS->pSrc;
mask |= exprListTableUsage(pMaskSet, pS->pEList);
mask |= exprListTableUsage(pMaskSet, pS->pGroupBy);
mask |= exprListTableUsage(pMaskSet, pS->pOrderBy);
mask |= exprTableUsage(pMaskSet, pS->pWhere);
mask |= exprTableUsage(pMaskSet, pS->pHaving);
+ if( ALWAYS(pSrc!=0) ){
+ int i;
+ for(i=0; i<pSrc->nSrc; i++){
+ mask |= exprSelectTableUsage(pMaskSet, pSrc->a[i].pSelect);
+ mask |= exprTableUsage(pMaskSet, pSrc->a[i].pOn);
+ }
+ }
pS = pS->pPrior;
}
return mask;
@@ -98869,23 +103510,32 @@ static int allowedOp(int op){
** Commute a comparison operator. Expressions of the form "X op Y"
** are converted into "Y op X".
**
-** If a collation sequence is associated with either the left or right
+** If left/right precedence rules come into play when determining the
+** collating
** side of the comparison, it remains associated with the same side after
** the commutation. So "Y collate NOCASE op X" becomes
-** "X collate NOCASE op Y". This is because any collation sequence on
+** "X op Y". This is because any collation sequence on
** the left hand side of a comparison overrides any collation sequence
-** attached to the right. For the same reason the EP_ExpCollate flag
+** attached to the right. For the same reason the EP_Collate flag
** is not commuted.
*/
static void exprCommute(Parse *pParse, Expr *pExpr){
- u16 expRight = (pExpr->pRight->flags & EP_ExpCollate);
- u16 expLeft = (pExpr->pLeft->flags & EP_ExpCollate);
+ u16 expRight = (pExpr->pRight->flags & EP_Collate);
+ u16 expLeft = (pExpr->pLeft->flags & EP_Collate);
assert( allowedOp(pExpr->op) && pExpr->op!=TK_IN );
- pExpr->pRight->pColl = sqlite3ExprCollSeq(pParse, pExpr->pRight);
- pExpr->pLeft->pColl = sqlite3ExprCollSeq(pParse, pExpr->pLeft);
- SWAP(CollSeq*,pExpr->pRight->pColl,pExpr->pLeft->pColl);
- pExpr->pRight->flags = (pExpr->pRight->flags & ~EP_ExpCollate) | expLeft;
- pExpr->pLeft->flags = (pExpr->pLeft->flags & ~EP_ExpCollate) | expRight;
+ if( expRight==expLeft ){
+ /* Either X and Y both have COLLATE operator or neither do */
+ if( expRight ){
+ /* Both X and Y have COLLATE operators. Make sure X is always
+ ** used by clearing the EP_Collate flag from Y. */
+ pExpr->pRight->flags &= ~EP_Collate;
+ }else if( sqlite3ExprCollSeq(pParse, pExpr->pLeft)!=0 ){
+ /* Neither X nor Y have COLLATE operators, but X has a non-default
+ ** collating sequence. So add the EP_Collate marker on X to cause
+ ** it to be searched first. */
+ pExpr->pLeft->flags |= EP_Collate;
+ }
+ }
SWAP(Expr*,pExpr->pRight,pExpr->pLeft);
if( pExpr->op>=TK_GT ){
assert( TK_LT==TK_GT+2 );
@@ -98926,6 +103576,23 @@ static u16 operatorMask(int op){
** where X is a reference to the iColumn of table iCur and <op> is one of
** the WO_xx operator codes specified by the op parameter.
** Return a pointer to the term. Return 0 if not found.
+**
+** The term returned might by Y=<expr> if there is another constraint in
+** the WHERE clause that specifies that X=Y. Any such constraints will be
+** identified by the WO_EQUIV bit in the pTerm->eOperator field. The
+** aEquiv[] array holds X and all its equivalents, with each SQL variable
+** taking up two slots in aEquiv[]. The first slot is for the cursor number
+** and the second is for the column number. There are 22 slots in aEquiv[]
+** so that means we can look for X plus up to 10 other equivalent values.
+** Hence a search for X will return <expr> if X=A1 and A1=A2 and A2=A3
+** and ... and A9=A10 and A10=<expr>.
+**
+** If there are multiple terms in the WHERE clause of the form "X <op> <expr>"
+** then try for the one with no dependencies on <expr> - in other words where
+** <expr> is a constant expression of some kind. Only return entries of
+** the form "X <op> Y" where Y is a column in another table if no terms of
+** the form "X <op> <const-expr>" exist. If no terms with a constant RHS
+** exist, try to return a term that does not use WO_EQUIV.
*/
static WhereTerm *findTerm(
WhereClause *pWC, /* The WHERE clause to be searched */
@@ -98935,43 +103602,85 @@ static WhereTerm *findTerm(
u32 op, /* Mask of WO_xx values describing operator */
Index *pIdx /* Must be compatible with this index, if not NULL */
){
- WhereTerm *pTerm;
- int k;
- assert( iCur>=0 );
- op &= WO_ALL;
- for(pTerm=pWC->a, k=pWC->nTerm; k; k--, pTerm++){
- if( pTerm->leftCursor==iCur
- && (pTerm->prereqRight & notReady)==0
- && pTerm->u.leftColumn==iColumn
- && (pTerm->eOperator & op)!=0
- ){
- if( pIdx && pTerm->eOperator!=WO_ISNULL ){
- Expr *pX = pTerm->pExpr;
- CollSeq *pColl;
- char idxaff;
- int j;
- Parse *pParse = pWC->pParse;
-
- idxaff = pIdx->pTable->aCol[iColumn].affinity;
- if( !sqlite3IndexAffinityOk(pX, idxaff) ) continue;
+ WhereTerm *pTerm; /* Term being examined as possible result */
+ WhereTerm *pResult = 0; /* The answer to return */
+ WhereClause *pWCOrig = pWC; /* Original pWC value */
+ int j, k; /* Loop counters */
+ Expr *pX; /* Pointer to an expression */
+ Parse *pParse; /* Parsing context */
+ int iOrigCol = iColumn; /* Original value of iColumn */
+ int nEquiv = 2; /* Number of entires in aEquiv[] */
+ int iEquiv = 2; /* Number of entries of aEquiv[] processed so far */
+ int aEquiv[22]; /* iCur,iColumn and up to 10 other equivalents */
- /* Figure out the collation sequence required from an index for
- ** it to be useful for optimising expression pX. Store this
- ** value in variable pColl.
- */
- assert(pX->pLeft);
- pColl = sqlite3BinaryCompareCollSeq(pParse, pX->pLeft, pX->pRight);
- assert(pColl || pParse->nErr);
-
- for(j=0; pIdx->aiColumn[j]!=iColumn; j++){
- if( NEVER(j>=pIdx->nColumn) ) return 0;
+ assert( iCur>=0 );
+ aEquiv[0] = iCur;
+ aEquiv[1] = iColumn;
+ for(;;){
+ for(pWC=pWCOrig; pWC; pWC=pWC->pOuter){
+ for(pTerm=pWC->a, k=pWC->nTerm; k; k--, pTerm++){
+ if( pTerm->leftCursor==iCur
+ && pTerm->u.leftColumn==iColumn
+ ){
+ if( (pTerm->prereqRight & notReady)==0
+ && (pTerm->eOperator & op & WO_ALL)!=0
+ ){
+ if( iOrigCol>=0 && pIdx && (pTerm->eOperator & WO_ISNULL)==0 ){
+ CollSeq *pColl;
+ char idxaff;
+
+ pX = pTerm->pExpr;
+ pParse = pWC->pParse;
+ idxaff = pIdx->pTable->aCol[iOrigCol].affinity;
+ if( !sqlite3IndexAffinityOk(pX, idxaff) ){
+ continue;
+ }
+
+ /* Figure out the collation sequence required from an index for
+ ** it to be useful for optimising expression pX. Store this
+ ** value in variable pColl.
+ */
+ assert(pX->pLeft);
+ pColl = sqlite3BinaryCompareCollSeq(pParse,pX->pLeft,pX->pRight);
+ if( pColl==0 ) pColl = pParse->db->pDfltColl;
+
+ for(j=0; pIdx->aiColumn[j]!=iOrigCol; j++){
+ if( NEVER(j>=pIdx->nColumn) ) return 0;
+ }
+ if( sqlite3StrICmp(pColl->zName, pIdx->azColl[j]) ){
+ continue;
+ }
+ }
+ if( pTerm->prereqRight==0 ){
+ pResult = pTerm;
+ goto findTerm_success;
+ }else if( pResult==0 ){
+ pResult = pTerm;
+ }
+ }
+ if( (pTerm->eOperator & WO_EQUIV)!=0
+ && nEquiv<ArraySize(aEquiv)
+ ){
+ pX = sqlite3ExprSkipCollate(pTerm->pExpr->pRight);
+ assert( pX->op==TK_COLUMN );
+ for(j=0; j<nEquiv; j+=2){
+ if( aEquiv[j]==pX->iTable && aEquiv[j+1]==pX->iColumn ) break;
+ }
+ if( j==nEquiv ){
+ aEquiv[j] = pX->iTable;
+ aEquiv[j+1] = pX->iColumn;
+ nEquiv += 2;
+ }
+ }
}
- if( pColl && sqlite3StrICmp(pColl->zName, pIdx->azColl[j]) ) continue;
}
- return pTerm;
}
+ if( iEquiv>=nEquiv ) break;
+ iCur = aEquiv[iEquiv++];
+ iColumn = aEquiv[iEquiv++];
}
- return 0;
+findTerm_success:
+ return pResult;
}
/* Forward reference */
@@ -99026,7 +103735,10 @@ static int isLikeOrGlob(
#endif
pList = pExpr->x.pList;
pLeft = pList->a[1].pExpr;
- if( pLeft->op!=TK_COLUMN || sqlite3ExprAffinity(pLeft)!=SQLITE_AFF_TEXT ){
+ if( pLeft->op!=TK_COLUMN
+ || sqlite3ExprAffinity(pLeft)!=SQLITE_AFF_TEXT
+ || IsVirtual(pLeft->pTab)
+ ){
/* IMP: R-02065-49465 The left-hand side of the LIKE or GLOB operator must
** be the name of an indexed column with TEXT affinity. */
return 0;
@@ -99045,7 +103757,7 @@ static int isLikeOrGlob(
if( pVal && sqlite3_value_type(pVal)==SQLITE_TEXT ){
z = (char *)sqlite3_value_text(pVal);
}
- sqlite3VdbeSetVarmask(pParse->pVdbe, iCol); /* IMP: R-23257-02778 */
+ sqlite3VdbeSetVarmask(pParse->pVdbe, iCol);
assert( pRight->op==TK_VARIABLE || pRight->op==TK_REGISTER );
}else if( op==TK_STRING ){
z = pRight->u.zToken;
@@ -99063,7 +103775,7 @@ static int isLikeOrGlob(
*ppPrefix = pPrefix;
if( op==TK_VARIABLE ){
Vdbe *v = pParse->pVdbe;
- sqlite3VdbeSetVarmask(v, pRight->iColumn); /* IMP: R-23257-02778 */
+ sqlite3VdbeSetVarmask(v, pRight->iColumn);
if( *pisComplete && pRight->u.zToken[1] ){
/* If the rhs of the LIKE expression is a variable, and the current
** value of the variable means there is no need to invoke the LIKE
@@ -99154,7 +103866,7 @@ static void transferJoinMarkings(Expr *pDerived, Expr *pBase){
**
** CASE 1:
**
-** If all subterms are of the form T.C=expr for some single column of C
+** If all subterms are of the form T.C=expr for some single column of C and
** a single table T (as shown in example B above) then create a new virtual
** term that is an equivalent IN expression. In other words, if the term
** being analyzed is:
@@ -99232,7 +103944,7 @@ static void exprAnalyzeOrTerm(
if( pOrInfo==0 ) return;
pTerm->wtFlags |= TERM_ORINFO;
pOrWc = &pOrInfo->wc;
- whereClauseInit(pOrWc, pWC->pParse, pMaskSet);
+ whereClauseInit(pOrWc, pWC->pParse, pMaskSet, pWC->wctrlFlags);
whereSplit(pOrWc, pExpr, TK_OR);
exprAnalyzeAll(pSrc, pOrWc);
if( db->mallocFailed ) return;
@@ -99242,11 +103954,10 @@ static void exprAnalyzeOrTerm(
** Compute the set of tables that might satisfy cases 1 or 2.
*/
indexable = ~(Bitmask)0;
- chngToIN = ~(pWC->vmask);
+ chngToIN = ~(Bitmask)0;
for(i=pOrWc->nTerm-1, pOrTerm=pOrWc->a; i>=0 && indexable; i--, pOrTerm++){
if( (pOrTerm->eOperator & WO_SINGLE)==0 ){
WhereAndInfo *pAndInfo;
- assert( pOrTerm->eOperator==0 );
assert( (pOrTerm->wtFlags & (TERM_ANDINFO|TERM_ORINFO))==0 );
chngToIN = 0;
pAndInfo = sqlite3DbMallocRaw(db, sizeof(*pAndInfo));
@@ -99259,9 +103970,10 @@ static void exprAnalyzeOrTerm(
pOrTerm->wtFlags |= TERM_ANDINFO;
pOrTerm->eOperator = WO_AND;
pAndWC = &pAndInfo->wc;
- whereClauseInit(pAndWC, pWC->pParse, pMaskSet);
+ whereClauseInit(pAndWC, pWC->pParse, pMaskSet, pWC->wctrlFlags);
whereSplit(pAndWC, pOrTerm->pExpr, TK_AND);
exprAnalyzeAll(pSrc, pAndWC);
+ pAndWC->pOuter = pWC;
testcase( db->mallocFailed );
if( !db->mallocFailed ){
for(j=0, pAndTerm=pAndWC->a; j<pAndWC->nTerm; j++, pAndTerm++){
@@ -99284,7 +103996,7 @@ static void exprAnalyzeOrTerm(
b |= getMask(pMaskSet, pOther->leftCursor);
}
indexable &= b;
- if( pOrTerm->eOperator!=WO_EQ ){
+ if( (pOrTerm->eOperator & WO_EQ)==0 ){
chngToIN = 0;
}else{
chngToIN &= b;
@@ -99335,7 +104047,7 @@ static void exprAnalyzeOrTerm(
for(j=0; j<2 && !okToChngToIN; j++){
pOrTerm = pOrWc->a;
for(i=pOrWc->nTerm-1; i>=0; i--, pOrTerm++){
- assert( pOrTerm->eOperator==WO_EQ );
+ assert( pOrTerm->eOperator & WO_EQ );
pOrTerm->wtFlags &= ~TERM_OR_OK;
if( pOrTerm->leftCursor==iCursor ){
/* This is the 2-bit case and we are on the second iteration and
@@ -99361,7 +104073,7 @@ static void exprAnalyzeOrTerm(
/* No candidate table+column was found. This can only occur
** on the second iteration */
assert( j==1 );
- assert( (chngToIN&(chngToIN-1))==0 );
+ assert( IsPowerOfTwo(chngToIN) );
assert( chngToIN==getMask(pMaskSet, iCursor) );
break;
}
@@ -99371,7 +104083,7 @@ static void exprAnalyzeOrTerm(
** table and column is common to every term in the OR clause */
okToChngToIN = 1;
for(; i>=0 && okToChngToIN; i--, pOrTerm++){
- assert( pOrTerm->eOperator==WO_EQ );
+ assert( pOrTerm->eOperator & WO_EQ );
if( pOrTerm->leftCursor!=iCursor ){
pOrTerm->wtFlags &= ~TERM_OR_OK;
}else if( pOrTerm->u.leftColumn!=iColumn ){
@@ -99407,7 +104119,7 @@ static void exprAnalyzeOrTerm(
for(i=pOrWc->nTerm-1, pOrTerm=pOrWc->a; i>=0; i--, pOrTerm++){
if( (pOrTerm->wtFlags & TERM_OR_OK)==0 ) continue;
- assert( pOrTerm->eOperator==WO_EQ );
+ assert( pOrTerm->eOperator & WO_EQ );
assert( pOrTerm->leftCursor==iCursor );
assert( pOrTerm->u.leftColumn==iColumn );
pDup = sqlite3ExprDup(db, pOrTerm->pExpr->pRight, 0);
@@ -99437,7 +104149,6 @@ static void exprAnalyzeOrTerm(
}
#endif /* !SQLITE_OMIT_OR_OPTIMIZATION && !SQLITE_OMIT_SUBQUERY */
-
/*
** The input to this routine is an WhereTerm structure with only the
** "pExpr" field filled in. The job of this routine is to analyze the
@@ -99480,6 +104191,7 @@ static void exprAnalyze(
pTerm = &pWC->a[idxTerm];
pMaskSet = pWC->pMaskSet;
pExpr = pTerm->pExpr;
+ assert( pExpr->op!=TK_AS && pExpr->op!=TK_COLLATE );
prereqLeft = exprTableUsage(pMaskSet, pExpr->pLeft);
op = pExpr->op;
if( op==TK_IN ){
@@ -99505,17 +104217,19 @@ static void exprAnalyze(
pTerm->leftCursor = -1;
pTerm->iParent = -1;
pTerm->eOperator = 0;
- if( allowedOp(op) && (pTerm->prereqRight & prereqLeft)==0 ){
- Expr *pLeft = pExpr->pLeft;
- Expr *pRight = pExpr->pRight;
+ if( allowedOp(op) ){
+ Expr *pLeft = sqlite3ExprSkipCollate(pExpr->pLeft);
+ Expr *pRight = sqlite3ExprSkipCollate(pExpr->pRight);
+ u16 opMask = (pTerm->prereqRight & prereqLeft)==0 ? WO_ALL : WO_EQUIV;
if( pLeft->op==TK_COLUMN ){
pTerm->leftCursor = pLeft->iTable;
pTerm->u.leftColumn = pLeft->iColumn;
- pTerm->eOperator = operatorMask(op);
+ pTerm->eOperator = operatorMask(op) & opMask;
}
if( pRight && pRight->op==TK_COLUMN ){
WhereTerm *pNew;
Expr *pDup;
+ u16 eExtraOp = 0; /* Extra bits for pNew->eOperator */
if( pTerm->leftCursor>=0 ){
int idxNew;
pDup = sqlite3ExprDup(db, pExpr, 0);
@@ -99530,18 +104244,25 @@ static void exprAnalyze(
pTerm = &pWC->a[idxTerm];
pTerm->nChild = 1;
pTerm->wtFlags |= TERM_COPIED;
+ if( pExpr->op==TK_EQ
+ && !ExprHasProperty(pExpr, EP_FromJoin)
+ && OptimizationEnabled(db, SQLITE_Transitive)
+ ){
+ pTerm->eOperator |= WO_EQUIV;
+ eExtraOp = WO_EQUIV;
+ }
}else{
pDup = pExpr;
pNew = pTerm;
}
exprCommute(pParse, pDup);
- pLeft = pDup->pLeft;
+ pLeft = sqlite3ExprSkipCollate(pDup->pLeft);
pNew->leftCursor = pLeft->iTable;
pNew->u.leftColumn = pLeft->iColumn;
testcase( (prereqLeft | extraRight) != prereqLeft );
pNew->prereqRight = prereqLeft | extraRight;
pNew->prereqAll = prereqAll;
- pNew->eOperator = operatorMask(pDup->op);
+ pNew->eOperator = (operatorMask(pDup->op) + eExtraOp) & opMask;
}
}
@@ -99614,7 +104335,7 @@ static void exprAnalyze(
Expr *pNewExpr2;
int idxNew1;
int idxNew2;
- CollSeq *pColl; /* Collating sequence to use */
+ Token sCollSeqName; /* Name of collating sequence */
pLeft = pExpr->x.pList->a[1].pExpr;
pStr2 = sqlite3ExprDup(db, pStr1, 0);
@@ -99636,16 +104357,19 @@ static void exprAnalyze(
}
*pC = c + 1;
}
- pColl = sqlite3FindCollSeq(db, SQLITE_UTF8, noCase ? "NOCASE" : "BINARY",0);
+ sCollSeqName.z = noCase ? "NOCASE" : "BINARY";
+ sCollSeqName.n = 6;
+ pNewExpr1 = sqlite3ExprDup(db, pLeft, 0);
pNewExpr1 = sqlite3PExpr(pParse, TK_GE,
- sqlite3ExprSetColl(sqlite3ExprDup(db,pLeft,0), pColl),
- pStr1, 0);
+ sqlite3ExprAddCollateToken(pParse,pNewExpr1,&sCollSeqName),
+ pStr1, 0);
idxNew1 = whereClauseInsert(pWC, pNewExpr1, TERM_VIRTUAL|TERM_DYNAMIC);
testcase( idxNew1==0 );
exprAnalyze(pSrc, pWC, idxNew1);
+ pNewExpr2 = sqlite3ExprDup(db, pLeft, 0);
pNewExpr2 = sqlite3PExpr(pParse, TK_LT,
- sqlite3ExprSetColl(sqlite3ExprDup(db,pLeft,0), pColl),
- pStr2, 0);
+ sqlite3ExprAddCollateToken(pParse,pNewExpr2,&sCollSeqName),
+ pStr2, 0);
idxNew2 = whereClauseInsert(pWC, pNewExpr2, TERM_VIRTUAL|TERM_DYNAMIC);
testcase( idxNew2==0 );
exprAnalyze(pSrc, pWC, idxNew2);
@@ -99695,8 +104419,8 @@ static void exprAnalyze(
}
#endif /* SQLITE_OMIT_VIRTUALTABLE */
-#ifdef SQLITE_ENABLE_STAT2
- /* When sqlite_stat2 histogram data is available an operator of the
+#ifdef SQLITE_ENABLE_STAT3
+ /* When sqlite_stat3 histogram data is available an operator of the
** form "x IS NOT NULL" can sometimes be evaluated more efficiently
** as "x>NULL" if x is not an INTEGER PRIMARY KEY. So construct a
** virtual term of that form.
@@ -99734,7 +104458,7 @@ static void exprAnalyze(
pNewTerm->prereqAll = pTerm->prereqAll;
}
}
-#endif /* SQLITE_ENABLE_STAT2 */
+#endif /* SQLITE_ENABLE_STAT */
/* Prevent ON clause terms of a LEFT JOIN from being used to drive
** an index for tables to the left of the join.
@@ -99743,167 +104467,164 @@ static void exprAnalyze(
}
/*
-** Return TRUE if any of the expressions in pList->a[iFirst...] contain
-** a reference to any table other than the iBase table.
+** This function searches the expression list passed as the second argument
+** for an expression of type TK_COLUMN that refers to the same column and
+** uses the same collation sequence as the iCol'th column of index pIdx.
+** Argument iBase is the cursor number used for the table that pIdx refers
+** to.
+**
+** If such an expression is found, its index in pList->a[] is returned. If
+** no expression is found, -1 is returned.
*/
-static int referencesOtherTables(
- ExprList *pList, /* Search expressions in ths list */
- WhereMaskSet *pMaskSet, /* Mapping from tables to bitmaps */
- int iFirst, /* Be searching with the iFirst-th expression */
- int iBase /* Ignore references to this table */
+static int findIndexCol(
+ Parse *pParse, /* Parse context */
+ ExprList *pList, /* Expression list to search */
+ int iBase, /* Cursor for table associated with pIdx */
+ Index *pIdx, /* Index to match column of */
+ int iCol /* Column of index to match */
){
- Bitmask allowed = ~getMask(pMaskSet, iBase);
- while( iFirst<pList->nExpr ){
- if( (exprTableUsage(pMaskSet, pList->a[iFirst++].pExpr)&allowed)!=0 ){
- return 1;
+ int i;
+ const char *zColl = pIdx->azColl[iCol];
+
+ for(i=0; i<pList->nExpr; i++){
+ Expr *p = sqlite3ExprSkipCollate(pList->a[i].pExpr);
+ if( p->op==TK_COLUMN
+ && p->iColumn==pIdx->aiColumn[iCol]
+ && p->iTable==iBase
+ ){
+ CollSeq *pColl = sqlite3ExprCollSeq(pParse, pList->a[i].pExpr);
+ if( ALWAYS(pColl) && 0==sqlite3StrICmp(pColl->zName, zColl) ){
+ return i;
+ }
}
}
- return 0;
-}
+ return -1;
+}
/*
-** This routine decides if pIdx can be used to satisfy the ORDER BY
-** clause. If it can, it returns 1. If pIdx cannot satisfy the
-** ORDER BY clause, this routine returns 0.
+** This routine determines if pIdx can be used to assist in processing a
+** DISTINCT qualifier. In other words, it tests whether or not using this
+** index for the outer loop guarantees that rows with equal values for
+** all expressions in the pDistinct list are delivered grouped together.
**
-** pOrderBy is an ORDER BY clause from a SELECT statement. pTab is the
-** left-most table in the FROM clause of that same SELECT statement and
-** the table has a cursor number of "base". pIdx is an index on pTab.
+** For example, the query
**
-** nEqCol is the number of columns of pIdx that are used as equality
-** constraints. Any of these columns may be missing from the ORDER BY
-** clause and the match can still be a success.
+** SELECT DISTINCT a, b, c FROM tbl WHERE a = ?
**
-** All terms of the ORDER BY that match against the index must be either
-** ASC or DESC. (Terms of the ORDER BY clause past the end of a UNIQUE
-** index do not need to satisfy this constraint.) The *pbRev value is
-** set to 1 if the ORDER BY clause is all DESC and it is set to 0 if
-** the ORDER BY clause is all ASC.
+** can benefit from any index on columns "b" and "c".
*/
-static int isSortingIndex(
- Parse *pParse, /* Parsing context */
- WhereMaskSet *pMaskSet, /* Mapping from table cursor numbers to bitmaps */
- Index *pIdx, /* The index we are testing */
- int base, /* Cursor number for the table to be sorted */
- ExprList *pOrderBy, /* The ORDER BY clause */
- int nEqCol, /* Number of index columns with == constraints */
- int wsFlags, /* Index usages flags */
- int *pbRev /* Set to 1 if ORDER BY is DESC */
+static int isDistinctIndex(
+ Parse *pParse, /* Parsing context */
+ WhereClause *pWC, /* The WHERE clause */
+ Index *pIdx, /* The index being considered */
+ int base, /* Cursor number for the table pIdx is on */
+ ExprList *pDistinct, /* The DISTINCT expressions */
+ int nEqCol /* Number of index columns with == */
){
- int i, j; /* Loop counters */
- int sortOrder = 0; /* XOR of index and ORDER BY sort direction */
- int nTerm; /* Number of ORDER BY terms */
- struct ExprList_item *pTerm; /* A term of the ORDER BY clause */
- sqlite3 *db = pParse->db;
+ Bitmask mask = 0; /* Mask of unaccounted for pDistinct exprs */
+ int i; /* Iterator variable */
- assert( pOrderBy!=0 );
- nTerm = pOrderBy->nExpr;
- assert( nTerm>0 );
+ assert( pDistinct!=0 );
+ if( pIdx->zName==0 || pDistinct->nExpr>=BMS ) return 0;
+ testcase( pDistinct->nExpr==BMS-1 );
- /* Argument pIdx must either point to a 'real' named index structure,
- ** or an index structure allocated on the stack by bestBtreeIndex() to
- ** represent the rowid index that is part of every table. */
- assert( pIdx->zName || (pIdx->nColumn==1 && pIdx->aiColumn[0]==-1) );
+ /* Loop through all the expressions in the distinct list. If any of them
+ ** are not simple column references, return early. Otherwise, test if the
+ ** WHERE clause contains a "col=X" clause. If it does, the expression
+ ** can be ignored. If it does not, and the column does not belong to the
+ ** same table as index pIdx, return early. Finally, if there is no
+ ** matching "col=X" expression and the column is on the same table as pIdx,
+ ** set the corresponding bit in variable mask.
+ */
+ for(i=0; i<pDistinct->nExpr; i++){
+ WhereTerm *pTerm;
+ Expr *p = sqlite3ExprSkipCollate(pDistinct->a[i].pExpr);
+ if( p->op!=TK_COLUMN ) return 0;
+ pTerm = findTerm(pWC, p->iTable, p->iColumn, ~(Bitmask)0, WO_EQ, 0);
+ if( pTerm ){
+ Expr *pX = pTerm->pExpr;
+ CollSeq *p1 = sqlite3BinaryCompareCollSeq(pParse, pX->pLeft, pX->pRight);
+ CollSeq *p2 = sqlite3ExprCollSeq(pParse, p);
+ if( p1==p2 ) continue;
+ }
+ if( p->iTable!=base ) return 0;
+ mask |= (((Bitmask)1) << i);
+ }
- /* Match terms of the ORDER BY clause against columns of
- ** the index.
+ for(i=nEqCol; mask && i<pIdx->nColumn; i++){
+ int iExpr = findIndexCol(pParse, pDistinct, base, pIdx, i);
+ if( iExpr<0 ) break;
+ mask &= ~(((Bitmask)1) << iExpr);
+ }
+
+ return (mask==0);
+}
+
+
+/*
+** Return true if the DISTINCT expression-list passed as the third argument
+** is redundant. A DISTINCT list is redundant if the database contains a
+** UNIQUE index that guarantees that the result of the query will be distinct
+** anyway.
+*/
+static int isDistinctRedundant(
+ Parse *pParse,
+ SrcList *pTabList,
+ WhereClause *pWC,
+ ExprList *pDistinct
+){
+ Table *pTab;
+ Index *pIdx;
+ int i;
+ int iBase;
+
+ /* If there is more than one table or sub-select in the FROM clause of
+ ** this query, then it will not be possible to show that the DISTINCT
+ ** clause is redundant. */
+ if( pTabList->nSrc!=1 ) return 0;
+ iBase = pTabList->a[0].iCursor;
+ pTab = pTabList->a[0].pTab;
+
+ /* If any of the expressions is an IPK column on table iBase, then return
+ ** true. Note: The (p->iTable==iBase) part of this test may be false if the
+ ** current SELECT is a correlated sub-query.
+ */
+ for(i=0; i<pDistinct->nExpr; i++){
+ Expr *p = sqlite3ExprSkipCollate(pDistinct->a[i].pExpr);
+ if( p->op==TK_COLUMN && p->iTable==iBase && p->iColumn<0 ) return 1;
+ }
+
+ /* Loop through all indices on the table, checking each to see if it makes
+ ** the DISTINCT qualifier redundant. It does so if:
**
- ** Note that indices have pIdx->nColumn regular columns plus
- ** one additional column containing the rowid. The rowid column
- ** of the index is also allowed to match against the ORDER BY
- ** clause.
+ ** 1. The index is itself UNIQUE, and
+ **
+ ** 2. All of the columns in the index are either part of the pDistinct
+ ** list, or else the WHERE clause contains a term of the form "col=X",
+ ** where X is a constant value. The collation sequences of the
+ ** comparison and select-list expressions must match those of the index.
+ **
+ ** 3. All of those index columns for which the WHERE clause does not
+ ** contain a "col=X" term are subject to a NOT NULL constraint.
*/
- for(i=j=0, pTerm=pOrderBy->a; j<nTerm && i<=pIdx->nColumn; i++){
- Expr *pExpr; /* The expression of the ORDER BY pTerm */
- CollSeq *pColl; /* The collating sequence of pExpr */
- int termSortOrder; /* Sort order for this term */
- int iColumn; /* The i-th column of the index. -1 for rowid */
- int iSortOrder; /* 1 for DESC, 0 for ASC on the i-th index term */
- const char *zColl; /* Name of the collating sequence for i-th index term */
-
- pExpr = pTerm->pExpr;
- if( pExpr->op!=TK_COLUMN || pExpr->iTable!=base ){
- /* Can not use an index sort on anything that is not a column in the
- ** left-most table of the FROM clause */
- break;
- }
- pColl = sqlite3ExprCollSeq(pParse, pExpr);
- if( !pColl ){
- pColl = db->pDfltColl;
- }
- if( pIdx->zName && i<pIdx->nColumn ){
- iColumn = pIdx->aiColumn[i];
- if( iColumn==pIdx->pTable->iPKey ){
- iColumn = -1;
- }
- iSortOrder = pIdx->aSortOrder[i];
- zColl = pIdx->azColl[i];
- }else{
- iColumn = -1;
- iSortOrder = 0;
- zColl = pColl->zName;
- }
- if( pExpr->iColumn!=iColumn || sqlite3StrICmp(pColl->zName, zColl) ){
- /* Term j of the ORDER BY clause does not match column i of the index */
- if( i<nEqCol ){
- /* If an index column that is constrained by == fails to match an
- ** ORDER BY term, that is OK. Just ignore that column of the index
- */
- continue;
- }else if( i==pIdx->nColumn ){
- /* Index column i is the rowid. All other terms match. */
- break;
- }else{
- /* If an index column fails to match and is not constrained by ==
- ** then the index cannot satisfy the ORDER BY constraint.
- */
- return 0;
- }
- }
- assert( pIdx->aSortOrder!=0 || iColumn==-1 );
- assert( pTerm->sortOrder==0 || pTerm->sortOrder==1 );
- assert( iSortOrder==0 || iSortOrder==1 );
- termSortOrder = iSortOrder ^ pTerm->sortOrder;
- if( i>nEqCol ){
- if( termSortOrder!=sortOrder ){
- /* Indices can only be used if all ORDER BY terms past the
- ** equality constraints are all either DESC or ASC. */
- return 0;
+ for(pIdx=pTab->pIndex; pIdx; pIdx=pIdx->pNext){
+ if( pIdx->onError==OE_None ) continue;
+ for(i=0; i<pIdx->nColumn; i++){
+ int iCol = pIdx->aiColumn[i];
+ if( 0==findTerm(pWC, iBase, iCol, ~(Bitmask)0, WO_EQ, pIdx) ){
+ int iIdxCol = findIndexCol(pParse, pDistinct, iBase, pIdx, i);
+ if( iIdxCol<0 || pTab->aCol[pIdx->aiColumn[i]].notNull==0 ){
+ break;
+ }
}
- }else{
- sortOrder = termSortOrder;
}
- j++;
- pTerm++;
- if( iColumn<0 && !referencesOtherTables(pOrderBy, pMaskSet, j, base) ){
- /* If the indexed column is the primary key and everything matches
- ** so far and none of the ORDER BY terms to the right reference other
- ** tables in the join, then we are assured that the index can be used
- ** to sort because the primary key is unique and so none of the other
- ** columns will make any difference
- */
- j = nTerm;
+ if( i==pIdx->nColumn ){
+ /* This index implies that the DISTINCT qualifier is redundant. */
+ return 1;
}
}
- *pbRev = sortOrder!=0;
- if( j>=nTerm ){
- /* All terms of the ORDER BY clause are covered by this index so
- ** this index can be used for sorting. */
- return 1;
- }
- if( pIdx->onError!=OE_None && i==pIdx->nColumn
- && (wsFlags & WHERE_COLUMN_NULL)==0
- && !referencesOtherTables(pOrderBy, pMaskSet, j, base) ){
- /* All terms of this index match some prefix of the ORDER BY clause
- ** and the index is UNIQUE and no terms on the tail of the ORDER BY
- ** clause reference other tables in a join. If this is all true then
- ** the order by clause is superfluous. Not that if the matching
- ** condition is IS NULL then the result is not necessarily unique
- ** even on a UNIQUE index, so disallow those cases. */
- return 1;
- }
return 0;
}
@@ -99971,9 +104692,7 @@ static void TRACE_IDX_OUTPUTS(sqlite3_index_info *p){
/*
** Required because bestIndex() is called by bestOrClauseIndex()
*/
-static void bestIndex(
- Parse*, WhereClause*, struct SrcList_item*,
- Bitmask, Bitmask, ExprList*, WhereCost*);
+static void bestIndex(WhereBestIdx*);
/*
** This routine attempts to find an scanning strategy that can be used
@@ -99982,31 +104701,28 @@ static void bestIndex(
** The table associated with FROM clause term pSrc may be either a
** regular B-Tree table or a virtual table.
*/
-static void bestOrClauseIndex(
- Parse *pParse, /* The parsing context */
- WhereClause *pWC, /* The WHERE clause */
- struct SrcList_item *pSrc, /* The FROM clause term to search */
- Bitmask notReady, /* Mask of cursors not available for indexing */
- Bitmask notValid, /* Cursors not available for any purpose */
- ExprList *pOrderBy, /* The ORDER BY clause */
- WhereCost *pCost /* Lowest cost query plan */
-){
+static void bestOrClauseIndex(WhereBestIdx *p){
#ifndef SQLITE_OMIT_OR_OPTIMIZATION
- const int iCur = pSrc->iCursor; /* The cursor of the table to be accessed */
+ WhereClause *pWC = p->pWC; /* The WHERE clause */
+ struct SrcList_item *pSrc = p->pSrc; /* The FROM clause term to search */
+ const int iCur = pSrc->iCursor; /* The cursor of the table */
const Bitmask maskSrc = getMask(pWC->pMaskSet, iCur); /* Bitmask for pSrc */
WhereTerm * const pWCEnd = &pWC->a[pWC->nTerm]; /* End of pWC->a[] */
- WhereTerm *pTerm; /* A single term of the WHERE clause */
+ WhereTerm *pTerm; /* A single term of the WHERE clause */
- /* No OR-clause optimization allowed if the INDEXED BY or NOT INDEXED clauses
- ** are used */
+ /* The OR-clause optimization is disallowed if the INDEXED BY or
+ ** NOT INDEXED clauses are used or if the WHERE_AND_ONLY bit is set. */
if( pSrc->notIndexed || pSrc->pIndex!=0 ){
return;
}
+ if( pWC->wctrlFlags & WHERE_AND_ONLY ){
+ return;
+ }
/* Search the WHERE clause terms for a usable WO_OR term. */
for(pTerm=pWC->a; pTerm<pWCEnd; pTerm++){
- if( pTerm->eOperator==WO_OR
- && ((pTerm->prereqAll & ~maskSrc) & notReady)==0
+ if( (pTerm->eOperator & WO_OR)!=0
+ && ((pTerm->prereqAll & ~maskSrc) & p->notReady)==0
&& (pTerm->u.pOrInfo->indexable & maskSrc)!=0
){
WhereClause * const pOrWC = &pTerm->u.pOrInfo->wc;
@@ -100016,35 +104732,42 @@ static void bestOrClauseIndex(
double rTotal = 0;
double nRow = 0;
Bitmask used = 0;
+ WhereBestIdx sBOI;
+ sBOI = *p;
+ sBOI.pOrderBy = 0;
+ sBOI.pDistinct = 0;
+ sBOI.ppIdxInfo = 0;
for(pOrTerm=pOrWC->a; pOrTerm<pOrWCEnd; pOrTerm++){
- WhereCost sTermCost;
WHERETRACE(("... Multi-index OR testing for term %d of %d....\n",
(pOrTerm - pOrWC->a), (pTerm - pWC->a)
));
- if( pOrTerm->eOperator==WO_AND ){
- WhereClause *pAndWC = &pOrTerm->u.pAndInfo->wc;
- bestIndex(pParse, pAndWC, pSrc, notReady, notValid, 0, &sTermCost);
+ if( (pOrTerm->eOperator& WO_AND)!=0 ){
+ sBOI.pWC = &pOrTerm->u.pAndInfo->wc;
+ bestIndex(&sBOI);
}else if( pOrTerm->leftCursor==iCur ){
WhereClause tempWC;
tempWC.pParse = pWC->pParse;
tempWC.pMaskSet = pWC->pMaskSet;
+ tempWC.pOuter = pWC;
tempWC.op = TK_AND;
tempWC.a = pOrTerm;
+ tempWC.wctrlFlags = 0;
tempWC.nTerm = 1;
- bestIndex(pParse, &tempWC, pSrc, notReady, notValid, 0, &sTermCost);
+ sBOI.pWC = &tempWC;
+ bestIndex(&sBOI);
}else{
continue;
}
- rTotal += sTermCost.rCost;
- nRow += sTermCost.plan.nRow;
- used |= sTermCost.used;
- if( rTotal>=pCost->rCost ) break;
+ rTotal += sBOI.cost.rCost;
+ nRow += sBOI.cost.plan.nRow;
+ used |= sBOI.cost.used;
+ if( rTotal>=p->cost.rCost ) break;
}
/* If there is an ORDER BY clause, increase the scan cost to account
** for the cost of the sort. */
- if( pOrderBy!=0 ){
+ if( p->pOrderBy!=0 ){
WHERETRACE(("... sorting increases OR cost %.9g to %.9g\n",
rTotal, rTotal+nRow*estLog(nRow)));
rTotal += nRow*estLog(nRow);
@@ -100054,12 +104777,13 @@ static void bestOrClauseIndex(
** less than the current cost stored in pCost, replace the contents
** of pCost. */
WHERETRACE(("... multi-index OR cost=%.9g nrow=%.9g\n", rTotal, nRow));
- if( rTotal<pCost->rCost ){
- pCost->rCost = rTotal;
- pCost->used = used;
- pCost->plan.nRow = nRow;
- pCost->plan.wsFlags = flags;
- pCost->plan.u.pTerm = pTerm;
+ if( rTotal<p->cost.rCost ){
+ p->cost.rCost = rTotal;
+ p->cost.used = used;
+ p->cost.plan.nRow = nRow;
+ p->cost.plan.nOBSat = p->i ? p->aLevel[p->i-1].plan.nOBSat : 0;
+ p->cost.plan.wsFlags = flags;
+ p->cost.plan.u.pTerm = pTerm;
}
}
}
@@ -100079,7 +104803,7 @@ static int termCanDriveIndex(
){
char aff;
if( pTerm->leftCursor!=pSrc->iCursor ) return 0;
- if( pTerm->eOperator!=WO_EQ ) return 0;
+ if( (pTerm->eOperator & WO_EQ)==0 ) return 0;
if( (pTerm->prereqRight & notReady)!=0 ) return 0;
aff = pSrc->pTab->aCol[pTerm->u.leftColumn].affinity;
if( !sqlite3IndexAffinityOk(pTerm->pExpr, aff) ) return 0;
@@ -100096,39 +104820,50 @@ static int termCanDriveIndex(
** is taken into account, then alter the query plan to use the
** transient index.
*/
-static void bestAutomaticIndex(
- Parse *pParse, /* The parsing context */
- WhereClause *pWC, /* The WHERE clause */
- struct SrcList_item *pSrc, /* The FROM clause term to search */
- Bitmask notReady, /* Mask of cursors that are not available */
- WhereCost *pCost /* Lowest cost query plan */
-){
- double nTableRow; /* Rows in the input table */
- double logN; /* log(nTableRow) */
+static void bestAutomaticIndex(WhereBestIdx *p){
+ Parse *pParse = p->pParse; /* The parsing context */
+ WhereClause *pWC = p->pWC; /* The WHERE clause */
+ struct SrcList_item *pSrc = p->pSrc; /* The FROM clause term to search */
+ double nTableRow; /* Rows in the input table */
+ double logN; /* log(nTableRow) */
double costTempIdx; /* per-query cost of the transient index */
WhereTerm *pTerm; /* A single term of the WHERE clause */
WhereTerm *pWCEnd; /* End of pWC->a[] */
Table *pTable; /* Table tht might be indexed */
+ if( pParse->nQueryLoop<=(double)1 ){
+ /* There is no point in building an automatic index for a single scan */
+ return;
+ }
if( (pParse->db->flags & SQLITE_AutoIndex)==0 ){
/* Automatic indices are disabled at run-time */
return;
}
- if( (pCost->plan.wsFlags & WHERE_NOT_FULLSCAN)!=0 ){
+ if( (p->cost.plan.wsFlags & WHERE_NOT_FULLSCAN)!=0
+ && (p->cost.plan.wsFlags & WHERE_COVER_SCAN)==0
+ ){
/* We already have some kind of index in use for this query. */
return;
}
+ if( pSrc->viaCoroutine ){
+ /* Cannot index a co-routine */
+ return;
+ }
if( pSrc->notIndexed ){
/* The NOT INDEXED clause appears in the SQL. */
return;
}
+ if( pSrc->isCorrelated ){
+ /* The source is a correlated sub-query. No point in indexing it. */
+ return;
+ }
assert( pParse->nQueryLoop >= (double)1 );
pTable = pSrc->pTab;
nTableRow = pTable->nRowEst;
logN = estLog(nTableRow);
costTempIdx = 2*logN*(nTableRow/pParse->nQueryLoop + 1);
- if( costTempIdx>=pCost->rCost ){
+ if( costTempIdx>=p->cost.rCost ){
/* The cost of creating the transient table would be greater than
** doing the full table scan */
return;
@@ -100137,19 +104872,19 @@ static void bestAutomaticIndex(
/* Search for any equality comparison term */
pWCEnd = &pWC->a[pWC->nTerm];
for(pTerm=pWC->a; pTerm<pWCEnd; pTerm++){
- if( termCanDriveIndex(pTerm, pSrc, notReady) ){
+ if( termCanDriveIndex(pTerm, pSrc, p->notReady) ){
WHERETRACE(("auto-index reduces cost from %.1f to %.1f\n",
- pCost->rCost, costTempIdx));
- pCost->rCost = costTempIdx;
- pCost->plan.nRow = logN + 1;
- pCost->plan.wsFlags = WHERE_TEMP_INDEX;
- pCost->used = pTerm->prereqRight;
+ p->cost.rCost, costTempIdx));
+ p->cost.rCost = costTempIdx;
+ p->cost.plan.nRow = logN + 1;
+ p->cost.plan.wsFlags = WHERE_TEMP_INDEX;
+ p->cost.used = pTerm->prereqRight;
break;
}
}
}
#else
-# define bestAutomaticIndex(A,B,C,D,E) /* no-op */
+# define bestAutomaticIndex(A) /* no-op */
#endif /* SQLITE_OMIT_AUTOMATIC_INDEX */
@@ -100172,7 +104907,6 @@ static void constructAutomaticIndex(
int nByte; /* Byte of memory needed for pIdx */
Index *pIdx; /* Object describing the transient index */
Vdbe *v; /* Prepared statement under construction */
- int regIsInit; /* Register set by initialization */
int addrInit; /* Address of the initialization bypass jump */
Table *pTable; /* The table being indexed */
KeyInfo *pKeyinfo; /* Key information for the index */
@@ -100189,9 +104923,7 @@ static void constructAutomaticIndex(
** transient index on 2nd and subsequent iterations of the loop. */
v = pParse->pVdbe;
assert( v!=0 );
- regIsInit = ++pParse->nMem;
- addrInit = sqlite3VdbeAddOp1(v, OP_If, regIsInit);
- sqlite3VdbeAddOp2(v, OP_Integer, 1, regIsInit);
+ addrInit = sqlite3CodeOnce(pParse);
/* Count the number of columns that will be added to the index
** and used to match WHERE clause constraints */
@@ -100313,12 +105045,11 @@ static void constructAutomaticIndex(
** responsibility of the caller to eventually release the structure
** by passing the pointer returned by this function to sqlite3_free().
*/
-static sqlite3_index_info *allocateIndexInfo(
- Parse *pParse,
- WhereClause *pWC,
- struct SrcList_item *pSrc,
- ExprList *pOrderBy
-){
+static sqlite3_index_info *allocateIndexInfo(WhereBestIdx *p){
+ Parse *pParse = p->pParse;
+ WhereClause *pWC = p->pWC;
+ struct SrcList_item *pSrc = p->pSrc;
+ ExprList *pOrderBy = p->pOrderBy;
int i, j;
int nTerm;
struct sqlite3_index_constraint *pIdxCons;
@@ -100334,10 +105065,11 @@ static sqlite3_index_info *allocateIndexInfo(
** to this virtual table */
for(i=nTerm=0, pTerm=pWC->a; i<pWC->nTerm; i++, pTerm++){
if( pTerm->leftCursor != pSrc->iCursor ) continue;
- assert( (pTerm->eOperator&(pTerm->eOperator-1))==0 );
- testcase( pTerm->eOperator==WO_IN );
- testcase( pTerm->eOperator==WO_ISNULL );
- if( pTerm->eOperator & (WO_IN|WO_ISNULL) ) continue;
+ assert( IsPowerOfTwo(pTerm->eOperator & ~WO_EQUIV) );
+ testcase( pTerm->eOperator & WO_IN );
+ testcase( pTerm->eOperator & WO_ISNULL );
+ if( pTerm->eOperator & (WO_ISNULL) ) continue;
+ if( pTerm->wtFlags & TERM_VNULL ) continue;
nTerm++;
}
@@ -100347,12 +105079,13 @@ static sqlite3_index_info *allocateIndexInfo(
*/
nOrderBy = 0;
if( pOrderBy ){
- for(i=0; i<pOrderBy->nExpr; i++){
+ int n = pOrderBy->nExpr;
+ for(i=0; i<n; i++){
Expr *pExpr = pOrderBy->a[i].pExpr;
if( pExpr->op!=TK_COLUMN || pExpr->iTable!=pSrc->iCursor ) break;
}
- if( i==pOrderBy->nExpr ){
- nOrderBy = pOrderBy->nExpr;
+ if( i==n){
+ nOrderBy = n;
}
}
@@ -100383,14 +105116,18 @@ static sqlite3_index_info *allocateIndexInfo(
pUsage;
for(i=j=0, pTerm=pWC->a; i<pWC->nTerm; i++, pTerm++){
+ u8 op;
if( pTerm->leftCursor != pSrc->iCursor ) continue;
- assert( (pTerm->eOperator&(pTerm->eOperator-1))==0 );
- testcase( pTerm->eOperator==WO_IN );
- testcase( pTerm->eOperator==WO_ISNULL );
- if( pTerm->eOperator & (WO_IN|WO_ISNULL) ) continue;
+ assert( IsPowerOfTwo(pTerm->eOperator & ~WO_EQUIV) );
+ testcase( pTerm->eOperator & WO_IN );
+ testcase( pTerm->eOperator & WO_ISNULL );
+ if( pTerm->eOperator & (WO_ISNULL) ) continue;
+ if( pTerm->wtFlags & TERM_VNULL ) continue;
pIdxCons[j].iColumn = pTerm->u.leftColumn;
pIdxCons[j].iTermOffset = i;
- pIdxCons[j].op = (u8)pTerm->eOperator;
+ op = (u8)pTerm->eOperator & WO_ALL;
+ if( op==WO_IN ) op = WO_EQ;
+ pIdxCons[j].op = op;
/* The direct assignment in the previous line is possible only because
** the WO_ and SQLITE_INDEX_CONSTRAINT_ codes are identical. The
** following asserts verify this fact. */
@@ -100400,7 +105137,7 @@ static sqlite3_index_info *allocateIndexInfo(
assert( WO_GT==SQLITE_INDEX_CONSTRAINT_GT );
assert( WO_GE==SQLITE_INDEX_CONSTRAINT_GE );
assert( WO_MATCH==SQLITE_INDEX_CONSTRAINT_MATCH );
- assert( pTerm->eOperator & (WO_EQ|WO_LT|WO_LE|WO_GT|WO_GE|WO_MATCH) );
+ assert( pTerm->eOperator & (WO_IN|WO_EQ|WO_LT|WO_LE|WO_GT|WO_GE|WO_MATCH) );
j++;
}
for(i=0; i<nOrderBy; i++){
@@ -100475,38 +105212,34 @@ static int vtabBestIndex(Parse *pParse, Table *pTab, sqlite3_index_info *p){
** routine takes care of freeing the sqlite3_index_info structure after
** everybody has finished with it.
*/
-static void bestVirtualIndex(
- Parse *pParse, /* The parsing context */
- WhereClause *pWC, /* The WHERE clause */
- struct SrcList_item *pSrc, /* The FROM clause term to search */
- Bitmask notReady, /* Mask of cursors not available for index */
- Bitmask notValid, /* Cursors not valid for any purpose */
- ExprList *pOrderBy, /* The order by clause */
- WhereCost *pCost, /* Lowest cost query plan */
- sqlite3_index_info **ppIdxInfo /* Index information passed to xBestIndex */
-){
+static void bestVirtualIndex(WhereBestIdx *p){
+ Parse *pParse = p->pParse; /* The parsing context */
+ WhereClause *pWC = p->pWC; /* The WHERE clause */
+ struct SrcList_item *pSrc = p->pSrc; /* The FROM clause term to search */
Table *pTab = pSrc->pTab;
sqlite3_index_info *pIdxInfo;
struct sqlite3_index_constraint *pIdxCons;
struct sqlite3_index_constraint_usage *pUsage;
WhereTerm *pTerm;
- int i, j;
+ int i, j, k;
int nOrderBy;
+ int sortOrder; /* Sort order for IN clauses */
+ int bAllowIN; /* Allow IN optimizations */
double rCost;
/* Make sure wsFlags is initialized to some sane value. Otherwise, if the
** malloc in allocateIndexInfo() fails and this function returns leaving
** wsFlags in an uninitialized state, the caller may behave unpredictably.
*/
- memset(pCost, 0, sizeof(*pCost));
- pCost->plan.wsFlags = WHERE_VIRTUALTABLE;
+ memset(&p->cost, 0, sizeof(p->cost));
+ p->cost.plan.wsFlags = WHERE_VIRTUALTABLE;
/* If the sqlite3_index_info structure has not been previously
** allocated and initialized, then allocate and initialize it now.
*/
- pIdxInfo = *ppIdxInfo;
+ pIdxInfo = *p->ppIdxInfo;
if( pIdxInfo==0 ){
- *ppIdxInfo = pIdxInfo = allocateIndexInfo(pParse, pWC, pSrc, pOrderBy);
+ *p->ppIdxInfo = pIdxInfo = allocateIndexInfo(p);
}
if( pIdxInfo==0 ){
return;
@@ -100526,65 +105259,102 @@ static void bestVirtualIndex(
assert( pTab->azModuleArg && pTab->azModuleArg[0] );
assert( sqlite3GetVTable(pParse->db, pTab) );
- /* Set the aConstraint[].usable fields and initialize all
- ** output variables to zero.
- **
- ** aConstraint[].usable is true for constraints where the right-hand
- ** side contains only references to tables to the left of the current
- ** table. In other words, if the constraint is of the form:
- **
- ** column = expr
- **
- ** and we are evaluating a join, then the constraint on column is
- ** only valid if all tables referenced in expr occur to the left
- ** of the table containing column.
- **
- ** The aConstraints[] array contains entries for all constraints
- ** on the current table. That way we only have to compute it once
- ** even though we might try to pick the best index multiple times.
- ** For each attempt at picking an index, the order of tables in the
- ** join might be different so we have to recompute the usable flag
- ** each time.
- */
- pIdxCons = *(struct sqlite3_index_constraint**)&pIdxInfo->aConstraint;
- pUsage = pIdxInfo->aConstraintUsage;
- for(i=0; i<pIdxInfo->nConstraint; i++, pIdxCons++){
- j = pIdxCons->iTermOffset;
- pTerm = &pWC->a[j];
- pIdxCons->usable = (pTerm->prereqRight&notReady) ? 0 : 1;
- }
- memset(pUsage, 0, sizeof(pUsage[0])*pIdxInfo->nConstraint);
- if( pIdxInfo->needToFreeIdxStr ){
- sqlite3_free(pIdxInfo->idxStr);
- }
- pIdxInfo->idxStr = 0;
- pIdxInfo->idxNum = 0;
- pIdxInfo->needToFreeIdxStr = 0;
- pIdxInfo->orderByConsumed = 0;
- /* ((double)2) In case of SQLITE_OMIT_FLOATING_POINT... */
- pIdxInfo->estimatedCost = SQLITE_BIG_DBL / ((double)2);
- nOrderBy = pIdxInfo->nOrderBy;
- if( !pOrderBy ){
- pIdxInfo->nOrderBy = 0;
- }
-
- if( vtabBestIndex(pParse, pTab, pIdxInfo) ){
- return;
- }
+ /* Try once or twice. On the first attempt, allow IN optimizations.
+ ** If an IN optimization is accepted by the virtual table xBestIndex
+ ** method, but the pInfo->aConstrainUsage.omit flag is not set, then
+ ** the query will not work because it might allow duplicate rows in
+ ** output. In that case, run the xBestIndex method a second time
+ ** without the IN constraints. Usually this loop only runs once.
+ ** The loop will exit using a "break" statement.
+ */
+ for(bAllowIN=1; 1; bAllowIN--){
+ assert( bAllowIN==0 || bAllowIN==1 );
- pIdxCons = *(struct sqlite3_index_constraint**)&pIdxInfo->aConstraint;
- for(i=0; i<pIdxInfo->nConstraint; i++){
- if( pUsage[i].argvIndex>0 ){
- pCost->used |= pWC->a[pIdxCons[i].iTermOffset].prereqRight;
+ /* Set the aConstraint[].usable fields and initialize all
+ ** output variables to zero.
+ **
+ ** aConstraint[].usable is true for constraints where the right-hand
+ ** side contains only references to tables to the left of the current
+ ** table. In other words, if the constraint is of the form:
+ **
+ ** column = expr
+ **
+ ** and we are evaluating a join, then the constraint on column is
+ ** only valid if all tables referenced in expr occur to the left
+ ** of the table containing column.
+ **
+ ** The aConstraints[] array contains entries for all constraints
+ ** on the current table. That way we only have to compute it once
+ ** even though we might try to pick the best index multiple times.
+ ** For each attempt at picking an index, the order of tables in the
+ ** join might be different so we have to recompute the usable flag
+ ** each time.
+ */
+ pIdxCons = *(struct sqlite3_index_constraint**)&pIdxInfo->aConstraint;
+ pUsage = pIdxInfo->aConstraintUsage;
+ for(i=0; i<pIdxInfo->nConstraint; i++, pIdxCons++){
+ j = pIdxCons->iTermOffset;
+ pTerm = &pWC->a[j];
+ if( (pTerm->prereqRight&p->notReady)==0
+ && (bAllowIN || (pTerm->eOperator & WO_IN)==0)
+ ){
+ pIdxCons->usable = 1;
+ }else{
+ pIdxCons->usable = 0;
+ }
+ }
+ memset(pUsage, 0, sizeof(pUsage[0])*pIdxInfo->nConstraint);
+ if( pIdxInfo->needToFreeIdxStr ){
+ sqlite3_free(pIdxInfo->idxStr);
}
+ pIdxInfo->idxStr = 0;
+ pIdxInfo->idxNum = 0;
+ pIdxInfo->needToFreeIdxStr = 0;
+ pIdxInfo->orderByConsumed = 0;
+ /* ((double)2) In case of SQLITE_OMIT_FLOATING_POINT... */
+ pIdxInfo->estimatedCost = SQLITE_BIG_DBL / ((double)2);
+ nOrderBy = pIdxInfo->nOrderBy;
+ if( !p->pOrderBy ){
+ pIdxInfo->nOrderBy = 0;
+ }
+
+ if( vtabBestIndex(pParse, pTab, pIdxInfo) ){
+ return;
+ }
+
+ sortOrder = SQLITE_SO_ASC;
+ pIdxCons = *(struct sqlite3_index_constraint**)&pIdxInfo->aConstraint;
+ for(i=0; i<pIdxInfo->nConstraint; i++, pIdxCons++){
+ if( pUsage[i].argvIndex>0 ){
+ j = pIdxCons->iTermOffset;
+ pTerm = &pWC->a[j];
+ p->cost.used |= pTerm->prereqRight;
+ if( (pTerm->eOperator & WO_IN)!=0 ){
+ if( pUsage[i].omit==0 ){
+ /* Do not attempt to use an IN constraint if the virtual table
+ ** says that the equivalent EQ constraint cannot be safely omitted.
+ ** If we do attempt to use such a constraint, some rows might be
+ ** repeated in the output. */
+ break;
+ }
+ for(k=0; k<pIdxInfo->nOrderBy; k++){
+ if( pIdxInfo->aOrderBy[k].iColumn==pIdxCons->iColumn ){
+ sortOrder = pIdxInfo->aOrderBy[k].desc;
+ break;
+ }
+ }
+ }
+ }
+ }
+ if( i>=pIdxInfo->nConstraint ) break;
}
-
+
/* If there is an ORDER BY clause, and the selected virtual table index
** does not satisfy it, increase the cost of the scan accordingly. This
** matches the processing for non-virtual tables in bestBtreeIndex().
*/
rCost = pIdxInfo->estimatedCost;
- if( pOrderBy && pIdxInfo->orderByConsumed==0 ){
+ if( p->pOrderBy && pIdxInfo->orderByConsumed==0 ){
rCost += estLog(rCost)*rCost;
}
@@ -100596,94 +105366,114 @@ static void bestVirtualIndex(
** is defined.
*/
if( (SQLITE_BIG_DBL/((double)2))<rCost ){
- pCost->rCost = (SQLITE_BIG_DBL/((double)2));
+ p->cost.rCost = (SQLITE_BIG_DBL/((double)2));
}else{
- pCost->rCost = rCost;
+ p->cost.rCost = rCost;
}
- pCost->plan.u.pVtabIdx = pIdxInfo;
+ p->cost.plan.u.pVtabIdx = pIdxInfo;
if( pIdxInfo->orderByConsumed ){
- pCost->plan.wsFlags |= WHERE_ORDERBY;
+ assert( sortOrder==0 || sortOrder==1 );
+ p->cost.plan.wsFlags |= WHERE_ORDERED + sortOrder*WHERE_REVERSE;
+ p->cost.plan.nOBSat = nOrderBy;
+ }else{
+ p->cost.plan.nOBSat = p->i ? p->aLevel[p->i-1].plan.nOBSat : 0;
}
- pCost->plan.nEq = 0;
+ p->cost.plan.nEq = 0;
pIdxInfo->nOrderBy = nOrderBy;
/* Try to find a more efficient access pattern by using multiple indexes
** to optimize an OR expression within the WHERE clause.
*/
- bestOrClauseIndex(pParse, pWC, pSrc, notReady, notValid, pOrderBy, pCost);
+ bestOrClauseIndex(p);
}
#endif /* SQLITE_OMIT_VIRTUALTABLE */
+#ifdef SQLITE_ENABLE_STAT3
/*
-** Argument pIdx is a pointer to an index structure that has an array of
-** SQLITE_INDEX_SAMPLES evenly spaced samples of the first indexed column
-** stored in Index.aSample. These samples divide the domain of values stored
-** the index into (SQLITE_INDEX_SAMPLES+1) regions.
-** Region 0 contains all values less than the first sample value. Region
-** 1 contains values between the first and second samples. Region 2 contains
-** values between samples 2 and 3. And so on. Region SQLITE_INDEX_SAMPLES
-** contains values larger than the last sample.
-**
-** If the index contains many duplicates of a single value, then it is
-** possible that two or more adjacent samples can hold the same value.
-** When that is the case, the smallest possible region code is returned
-** when roundUp is false and the largest possible region code is returned
-** when roundUp is true.
-**
-** If successful, this function determines which of the regions value
-** pVal lies in, sets *piRegion to the region index (a value between 0
-** and SQLITE_INDEX_SAMPLES+1, inclusive) and returns SQLITE_OK.
-** Or, if an OOM occurs while converting text values between encodings,
-** SQLITE_NOMEM is returned and *piRegion is undefined.
-*/
-#ifdef SQLITE_ENABLE_STAT2
-static int whereRangeRegion(
+** Estimate the location of a particular key among all keys in an
+** index. Store the results in aStat as follows:
+**
+** aStat[0] Est. number of rows less than pVal
+** aStat[1] Est. number of rows equal to pVal
+**
+** Return SQLITE_OK on success.
+*/
+static int whereKeyStats(
Parse *pParse, /* Database connection */
Index *pIdx, /* Index to consider domain of */
sqlite3_value *pVal, /* Value to consider */
- int roundUp, /* Return largest valid region if true */
- int *piRegion /* OUT: Region of domain in which value lies */
+ int roundUp, /* Round up if true. Round down if false */
+ tRowcnt *aStat /* OUT: stats written here */
){
+ tRowcnt n;
+ IndexSample *aSample;
+ int i, eType;
+ int isEq = 0;
+ i64 v;
+ double r, rS;
+
assert( roundUp==0 || roundUp==1 );
- if( ALWAYS(pVal) ){
- IndexSample *aSample = pIdx->aSample;
- int i = 0;
- int eType = sqlite3_value_type(pVal);
-
- if( eType==SQLITE_INTEGER || eType==SQLITE_FLOAT ){
- double r = sqlite3_value_double(pVal);
- for(i=0; i<SQLITE_INDEX_SAMPLES; i++){
- if( aSample[i].eType==SQLITE_NULL ) continue;
- if( aSample[i].eType>=SQLITE_TEXT ) break;
- if( roundUp ){
- if( aSample[i].u.r>r ) break;
- }else{
- if( aSample[i].u.r>=r ) break;
+ assert( pIdx->nSample>0 );
+ if( pVal==0 ) return SQLITE_ERROR;
+ n = pIdx->aiRowEst[0];
+ aSample = pIdx->aSample;
+ eType = sqlite3_value_type(pVal);
+
+ if( eType==SQLITE_INTEGER ){
+ v = sqlite3_value_int64(pVal);
+ r = (i64)v;
+ for(i=0; i<pIdx->nSample; i++){
+ if( aSample[i].eType==SQLITE_NULL ) continue;
+ if( aSample[i].eType>=SQLITE_TEXT ) break;
+ if( aSample[i].eType==SQLITE_INTEGER ){
+ if( aSample[i].u.i>=v ){
+ isEq = aSample[i].u.i==v;
+ break;
}
+ }else{
+ assert( aSample[i].eType==SQLITE_FLOAT );
+ if( aSample[i].u.r>=r ){
+ isEq = aSample[i].u.r==r;
+ break;
+ }
+ }
+ }
+ }else if( eType==SQLITE_FLOAT ){
+ r = sqlite3_value_double(pVal);
+ for(i=0; i<pIdx->nSample; i++){
+ if( aSample[i].eType==SQLITE_NULL ) continue;
+ if( aSample[i].eType>=SQLITE_TEXT ) break;
+ if( aSample[i].eType==SQLITE_FLOAT ){
+ rS = aSample[i].u.r;
+ }else{
+ rS = aSample[i].u.i;
}
- }else if( eType==SQLITE_NULL ){
- i = 0;
- if( roundUp ){
- while( i<SQLITE_INDEX_SAMPLES && aSample[i].eType==SQLITE_NULL ) i++;
+ if( rS>=r ){
+ isEq = rS==r;
+ break;
+ }
+ }
+ }else if( eType==SQLITE_NULL ){
+ i = 0;
+ if( aSample[0].eType==SQLITE_NULL ) isEq = 1;
+ }else{
+ assert( eType==SQLITE_TEXT || eType==SQLITE_BLOB );
+ for(i=0; i<pIdx->nSample; i++){
+ if( aSample[i].eType==SQLITE_TEXT || aSample[i].eType==SQLITE_BLOB ){
+ break;
}
- }else{
+ }
+ if( i<pIdx->nSample ){
sqlite3 *db = pParse->db;
CollSeq *pColl;
const u8 *z;
- int n;
-
- /* pVal comes from sqlite3ValueFromExpr() so the type cannot be NULL */
- assert( eType==SQLITE_TEXT || eType==SQLITE_BLOB );
-
if( eType==SQLITE_BLOB ){
z = (const u8 *)sqlite3_value_blob(pVal);
pColl = db->pDfltColl;
assert( pColl->enc==SQLITE_UTF8 );
}else{
- pColl = sqlite3GetCollSeq(db, SQLITE_UTF8, 0, *pIdx->azColl);
+ pColl = sqlite3GetCollSeq(pParse, SQLITE_UTF8, 0, *pIdx->azColl);
if( pColl==0 ){
- sqlite3ErrorMsg(pParse, "no such collation sequence: %s",
- *pIdx->azColl);
return SQLITE_ERROR;
}
z = (const u8 *)sqlite3ValueText(pVal, pColl->enc);
@@ -100693,12 +105483,12 @@ static int whereRangeRegion(
assert( z && pColl && pColl->xCmp );
}
n = sqlite3ValueBytes(pVal, pColl->enc);
-
- for(i=0; i<SQLITE_INDEX_SAMPLES; i++){
+
+ for(; i<pIdx->nSample; i++){
int c;
int eSampletype = aSample[i].eType;
- if( eSampletype==SQLITE_NULL || eSampletype<eType ) continue;
- if( (eSampletype!=eType) ) break;
+ if( eSampletype<eType ) continue;
+ if( eSampletype!=eType ) break;
#ifndef SQLITE_OMIT_UTF16
if( pColl->enc!=SQLITE_UTF8 ){
int nSample;
@@ -100716,16 +105506,47 @@ static int whereRangeRegion(
{
c = pColl->xCmp(pColl->pUser, aSample[i].nByte, aSample[i].u.z, n, z);
}
- if( c-roundUp>=0 ) break;
+ if( c>=0 ){
+ if( c==0 ) isEq = 1;
+ break;
+ }
}
}
+ }
- assert( i>=0 && i<=SQLITE_INDEX_SAMPLES );
- *piRegion = i;
+ /* At this point, aSample[i] is the first sample that is greater than
+ ** or equal to pVal. Or if i==pIdx->nSample, then all samples are less
+ ** than pVal. If aSample[i]==pVal, then isEq==1.
+ */
+ if( isEq ){
+ assert( i<pIdx->nSample );
+ aStat[0] = aSample[i].nLt;
+ aStat[1] = aSample[i].nEq;
+ }else{
+ tRowcnt iLower, iUpper, iGap;
+ if( i==0 ){
+ iLower = 0;
+ iUpper = aSample[0].nLt;
+ }else{
+ iUpper = i>=pIdx->nSample ? n : aSample[i].nLt;
+ iLower = aSample[i-1].nEq + aSample[i-1].nLt;
+ }
+ aStat[1] = pIdx->avgEq;
+ if( iLower>=iUpper ){
+ iGap = 0;
+ }else{
+ iGap = iUpper - iLower;
+ }
+ if( roundUp ){
+ iGap = (iGap*2)/3;
+ }else{
+ iGap = iGap/3;
+ }
+ aStat[0] = iLower + iGap;
}
return SQLITE_OK;
}
-#endif /* #ifdef SQLITE_ENABLE_STAT2 */
+#endif /* SQLITE_ENABLE_STAT3 */
/*
** If expression pExpr represents a literal value, set *pp to point to
@@ -100743,7 +105564,7 @@ static int whereRangeRegion(
**
** If an error occurs, return an error code. Otherwise, SQLITE_OK.
*/
-#ifdef SQLITE_ENABLE_STAT2
+#ifdef SQLITE_ENABLE_STAT3
static int valueFromExpr(
Parse *pParse,
Expr *pExpr,
@@ -100754,7 +105575,7 @@ static int valueFromExpr(
|| (pExpr->op==TK_REGISTER && pExpr->op2==TK_VARIABLE)
){
int iVar = pExpr->iColumn;
- sqlite3VdbeSetVarmask(pParse->pVdbe, iVar); /* IMP: R-23257-02778 */
+ sqlite3VdbeSetVarmask(pParse->pVdbe, iVar);
*pp = sqlite3VdbeGetValue(pParse->pReprepare, iVar, aff);
return SQLITE_OK;
}
@@ -100791,17 +105612,15 @@ static int valueFromExpr(
**
** then nEq should be passed 0.
**
-** The returned value is an integer between 1 and 100, inclusive. A return
-** value of 1 indicates that the proposed range scan is expected to visit
-** approximately 1/100th (1%) of the rows selected by the nEq equality
-** constraints (if any). A return value of 100 indicates that it is expected
-** that the range scan will visit every row (100%) selected by the equality
-** constraints.
+** The returned value is an integer divisor to reduce the estimated
+** search space. A return value of 1 means that range constraints are
+** no help at all. A return value of 2 means range constraints are
+** expected to reduce the search space by half. And so forth...
**
-** In the absence of sqlite_stat2 ANALYZE data, each range inequality
-** reduces the search space by 3/4ths. Hence a single constraint (x>?)
-** results in a return of 25 and a range constraint (x>? AND x<?) results
-** in a return of 6.
+** In the absence of sqlite_stat3 ANALYZE data, each range inequality
+** reduces the search space by a factor of 4. Hence a single constraint (x>?)
+** results in a return of 4 and a range constraint (x>? AND x<?) results
+** in a return of 16.
*/
static int whereRangeScanEst(
Parse *pParse, /* Parsing & code generating context */
@@ -100809,84 +105628,72 @@ static int whereRangeScanEst(
int nEq, /* index into p->aCol[] of the range-compared column */
WhereTerm *pLower, /* Lower bound on the range. ex: "x>123" Might be NULL */
WhereTerm *pUpper, /* Upper bound on the range. ex: "x<455" Might be NULL */
- int *piEst /* OUT: Return value */
+ double *pRangeDiv /* OUT: Reduce search space by this divisor */
){
int rc = SQLITE_OK;
-#ifdef SQLITE_ENABLE_STAT2
+#ifdef SQLITE_ENABLE_STAT3
- if( nEq==0 && p->aSample ){
- sqlite3_value *pLowerVal = 0;
- sqlite3_value *pUpperVal = 0;
- int iEst;
- int iLower = 0;
- int iUpper = SQLITE_INDEX_SAMPLES;
- int roundUpUpper = 0;
- int roundUpLower = 0;
+ if( nEq==0 && p->nSample ){
+ sqlite3_value *pRangeVal;
+ tRowcnt iLower = 0;
+ tRowcnt iUpper = p->aiRowEst[0];
+ tRowcnt a[2];
u8 aff = p->pTable->aCol[p->aiColumn[0]].affinity;
if( pLower ){
Expr *pExpr = pLower->pExpr->pRight;
- rc = valueFromExpr(pParse, pExpr, aff, &pLowerVal);
- assert( pLower->eOperator==WO_GT || pLower->eOperator==WO_GE );
- roundUpLower = (pLower->eOperator==WO_GT) ?1:0;
+ rc = valueFromExpr(pParse, pExpr, aff, &pRangeVal);
+ assert( (pLower->eOperator & (WO_GT|WO_GE))!=0 );
+ if( rc==SQLITE_OK
+ && whereKeyStats(pParse, p, pRangeVal, 0, a)==SQLITE_OK
+ ){
+ iLower = a[0];
+ if( (pLower->eOperator & WO_GT)!=0 ) iLower += a[1];
+ }
+ sqlite3ValueFree(pRangeVal);
}
if( rc==SQLITE_OK && pUpper ){
Expr *pExpr = pUpper->pExpr->pRight;
- rc = valueFromExpr(pParse, pExpr, aff, &pUpperVal);
- assert( pUpper->eOperator==WO_LT || pUpper->eOperator==WO_LE );
- roundUpUpper = (pUpper->eOperator==WO_LE) ?1:0;
- }
-
- if( rc!=SQLITE_OK || (pLowerVal==0 && pUpperVal==0) ){
- sqlite3ValueFree(pLowerVal);
- sqlite3ValueFree(pUpperVal);
- goto range_est_fallback;
- }else if( pLowerVal==0 ){
- rc = whereRangeRegion(pParse, p, pUpperVal, roundUpUpper, &iUpper);
- if( pLower ) iLower = iUpper/2;
- }else if( pUpperVal==0 ){
- rc = whereRangeRegion(pParse, p, pLowerVal, roundUpLower, &iLower);
- if( pUpper ) iUpper = (iLower + SQLITE_INDEX_SAMPLES + 1)/2;
- }else{
- rc = whereRangeRegion(pParse, p, pUpperVal, roundUpUpper, &iUpper);
- if( rc==SQLITE_OK ){
- rc = whereRangeRegion(pParse, p, pLowerVal, roundUpLower, &iLower);
+ rc = valueFromExpr(pParse, pExpr, aff, &pRangeVal);
+ assert( (pUpper->eOperator & (WO_LT|WO_LE))!=0 );
+ if( rc==SQLITE_OK
+ && whereKeyStats(pParse, p, pRangeVal, 1, a)==SQLITE_OK
+ ){
+ iUpper = a[0];
+ if( (pUpper->eOperator & WO_LE)!=0 ) iUpper += a[1];
}
+ sqlite3ValueFree(pRangeVal);
}
- WHERETRACE(("range scan regions: %d..%d\n", iLower, iUpper));
-
- iEst = iUpper - iLower;
- testcase( iEst==SQLITE_INDEX_SAMPLES );
- assert( iEst<=SQLITE_INDEX_SAMPLES );
- if( iEst<1 ){
- *piEst = 50/SQLITE_INDEX_SAMPLES;
- }else{
- *piEst = (iEst*100)/SQLITE_INDEX_SAMPLES;
+ if( rc==SQLITE_OK ){
+ if( iUpper<=iLower ){
+ *pRangeDiv = (double)p->aiRowEst[0];
+ }else{
+ *pRangeDiv = (double)p->aiRowEst[0]/(double)(iUpper - iLower);
+ }
+ WHERETRACE(("range scan regions: %u..%u div=%g\n",
+ (u32)iLower, (u32)iUpper, *pRangeDiv));
+ return SQLITE_OK;
}
- sqlite3ValueFree(pLowerVal);
- sqlite3ValueFree(pUpperVal);
- return rc;
}
-range_est_fallback:
#else
UNUSED_PARAMETER(pParse);
UNUSED_PARAMETER(p);
UNUSED_PARAMETER(nEq);
#endif
assert( pLower || pUpper );
- *piEst = 100;
- if( pLower && (pLower->wtFlags & TERM_VNULL)==0 ) *piEst /= 4;
- if( pUpper ) *piEst /= 4;
+ *pRangeDiv = (double)1;
+ if( pLower && (pLower->wtFlags & TERM_VNULL)==0 ) *pRangeDiv *= (double)4;
+ if( pUpper ) *pRangeDiv *= (double)4;
return rc;
}
-#ifdef SQLITE_ENABLE_STAT2
+#ifdef SQLITE_ENABLE_STAT3
/*
** Estimate the number of rows that will be returned based on
** an equality constraint x=VALUE and where that VALUE occurs in
** the histogram data. This only works when x is the left-most
-** column of an index and sqlite_stat2 histogram data is available
+** column of an index and sqlite_stat3 histogram data is available
** for that index. When pExpr==NULL that means the constraint is
** "x IS NULL" instead of "x=VALUE".
**
@@ -100906,12 +105713,12 @@ static int whereEqualScanEst(
double *pnRow /* Write the revised row estimate here */
){
sqlite3_value *pRhs = 0; /* VALUE on right-hand side of pTerm */
- int iLower, iUpper; /* Range of histogram regions containing pRhs */
u8 aff; /* Column affinity */
int rc; /* Subfunction return code */
- double nRowEst; /* New estimate of the number of rows */
+ tRowcnt a[2]; /* Statistics */
assert( p->aSample!=0 );
+ assert( p->nSample>0 );
aff = p->pTable->aCol[p->aiColumn[0]].affinity;
if( pExpr ){
rc = valueFromExpr(pParse, pExpr, aff, &pRhs);
@@ -100920,26 +105727,18 @@ static int whereEqualScanEst(
pRhs = sqlite3ValueNew(pParse->db);
}
if( pRhs==0 ) return SQLITE_NOTFOUND;
- rc = whereRangeRegion(pParse, p, pRhs, 0, &iLower);
- if( rc ) goto whereEqualScanEst_cancel;
- rc = whereRangeRegion(pParse, p, pRhs, 1, &iUpper);
- if( rc ) goto whereEqualScanEst_cancel;
- WHERETRACE(("equality scan regions: %d..%d\n", iLower, iUpper));
- if( iLower>=iUpper ){
- nRowEst = p->aiRowEst[0]/(SQLITE_INDEX_SAMPLES*2);
- if( nRowEst<*pnRow ) *pnRow = nRowEst;
- }else{
- nRowEst = (iUpper-iLower)*p->aiRowEst[0]/SQLITE_INDEX_SAMPLES;
- *pnRow = nRowEst;
+ rc = whereKeyStats(pParse, p, pRhs, 0, a);
+ if( rc==SQLITE_OK ){
+ WHERETRACE(("equality scan regions: %d\n", (int)a[1]));
+ *pnRow = a[1];
}
-
whereEqualScanEst_cancel:
sqlite3ValueFree(pRhs);
return rc;
}
-#endif /* defined(SQLITE_ENABLE_STAT2) */
+#endif /* defined(SQLITE_ENABLE_STAT3) */
-#ifdef SQLITE_ENABLE_STAT2
+#ifdef SQLITE_ENABLE_STAT3
/*
** Estimate the number of rows that will be returned based on
** an IN constraint where the right-hand side of the IN operator
@@ -100962,66 +105761,315 @@ static int whereInScanEst(
ExprList *pList, /* The value list on the RHS of "x IN (v1,v2,v3,...)" */
double *pnRow /* Write the revised row estimate here */
){
- sqlite3_value *pVal = 0; /* One value from list */
- int iLower, iUpper; /* Range of histogram regions containing pRhs */
- u8 aff; /* Column affinity */
- int rc = SQLITE_OK; /* Subfunction return code */
- double nRowEst; /* New estimate of the number of rows */
- int nSpan = 0; /* Number of histogram regions spanned */
- int nSingle = 0; /* Histogram regions hit by a single value */
- int nNotFound = 0; /* Count of values that are not constants */
- int i; /* Loop counter */
- u8 aSpan[SQLITE_INDEX_SAMPLES+1]; /* Histogram regions that are spanned */
- u8 aSingle[SQLITE_INDEX_SAMPLES+1]; /* Histogram regions hit once */
+ int rc = SQLITE_OK; /* Subfunction return code */
+ double nEst; /* Number of rows for a single term */
+ double nRowEst = (double)0; /* New estimate of the number of rows */
+ int i; /* Loop counter */
assert( p->aSample!=0 );
- aff = p->pTable->aCol[p->aiColumn[0]].affinity;
- memset(aSpan, 0, sizeof(aSpan));
- memset(aSingle, 0, sizeof(aSingle));
- for(i=0; i<pList->nExpr; i++){
- sqlite3ValueFree(pVal);
- rc = valueFromExpr(pParse, pList->a[i].pExpr, aff, &pVal);
- if( rc ) break;
- if( pVal==0 || sqlite3_value_type(pVal)==SQLITE_NULL ){
- nNotFound++;
- continue;
- }
- rc = whereRangeRegion(pParse, p, pVal, 0, &iLower);
- if( rc ) break;
- rc = whereRangeRegion(pParse, p, pVal, 1, &iUpper);
- if( rc ) break;
- if( iLower>=iUpper ){
- aSingle[iLower] = 1;
- }else{
- assert( iLower>=0 && iUpper<=SQLITE_INDEX_SAMPLES );
- while( iLower<iUpper ) aSpan[iLower++] = 1;
- }
+ for(i=0; rc==SQLITE_OK && i<pList->nExpr; i++){
+ nEst = p->aiRowEst[0];
+ rc = whereEqualScanEst(pParse, p, pList->a[i].pExpr, &nEst);
+ nRowEst += nEst;
}
if( rc==SQLITE_OK ){
- for(i=nSpan=0; i<=SQLITE_INDEX_SAMPLES; i++){
- if( aSpan[i] ){
- nSpan++;
- }else if( aSingle[i] ){
- nSingle++;
- }
- }
- nRowEst = (nSpan*2+nSingle)*p->aiRowEst[0]/(2*SQLITE_INDEX_SAMPLES)
- + nNotFound*p->aiRowEst[1];
if( nRowEst > p->aiRowEst[0] ) nRowEst = p->aiRowEst[0];
*pnRow = nRowEst;
- WHERETRACE(("IN row estimate: nSpan=%d, nSingle=%d, nNotFound=%d, est=%g\n",
- nSpan, nSingle, nNotFound, nRowEst));
+ WHERETRACE(("IN row estimate: est=%g\n", nRowEst));
}
- sqlite3ValueFree(pVal);
return rc;
}
-#endif /* defined(SQLITE_ENABLE_STAT2) */
+#endif /* defined(SQLITE_ENABLE_STAT3) */
+/*
+** Check to see if column iCol of the table with cursor iTab will appear
+** in sorted order according to the current query plan.
+**
+** Return values:
+**
+** 0 iCol is not ordered
+** 1 iCol has only a single value
+** 2 iCol is in ASC order
+** 3 iCol is in DESC order
+*/
+static int isOrderedColumn(
+ WhereBestIdx *p,
+ int iTab,
+ int iCol
+){
+ int i, j;
+ WhereLevel *pLevel = &p->aLevel[p->i-1];
+ Index *pIdx;
+ u8 sortOrder;
+ for(i=p->i-1; i>=0; i--, pLevel--){
+ if( pLevel->iTabCur!=iTab ) continue;
+ if( (pLevel->plan.wsFlags & WHERE_ALL_UNIQUE)!=0 ){
+ return 1;
+ }
+ assert( (pLevel->plan.wsFlags & WHERE_ORDERED)!=0 );
+ if( (pIdx = pLevel->plan.u.pIdx)!=0 ){
+ if( iCol<0 ){
+ sortOrder = 0;
+ testcase( (pLevel->plan.wsFlags & WHERE_REVERSE)!=0 );
+ }else{
+ int n = pIdx->nColumn;
+ for(j=0; j<n; j++){
+ if( iCol==pIdx->aiColumn[j] ) break;
+ }
+ if( j>=n ) return 0;
+ sortOrder = pIdx->aSortOrder[j];
+ testcase( (pLevel->plan.wsFlags & WHERE_REVERSE)!=0 );
+ }
+ }else{
+ if( iCol!=(-1) ) return 0;
+ sortOrder = 0;
+ testcase( (pLevel->plan.wsFlags & WHERE_REVERSE)!=0 );
+ }
+ if( (pLevel->plan.wsFlags & WHERE_REVERSE)!=0 ){
+ assert( sortOrder==0 || sortOrder==1 );
+ testcase( sortOrder==1 );
+ sortOrder = 1 - sortOrder;
+ }
+ return sortOrder+2;
+ }
+ return 0;
+}
+
+/*
+** This routine decides if pIdx can be used to satisfy the ORDER BY
+** clause, either in whole or in part. The return value is the
+** cumulative number of terms in the ORDER BY clause that are satisfied
+** by the index pIdx and other indices in outer loops.
+**
+** The table being queried has a cursor number of "base". pIdx is the
+** index that is postulated for use to access the table.
+**
+** The *pbRev value is set to 0 order 1 depending on whether or not
+** pIdx should be run in the forward order or in reverse order.
+*/
+static int isSortingIndex(
+ WhereBestIdx *p, /* Best index search context */
+ Index *pIdx, /* The index we are testing */
+ int base, /* Cursor number for the table to be sorted */
+ int *pbRev, /* Set to 1 for reverse-order scan of pIdx */
+ int *pbObUnique /* ORDER BY column values will different in every row */
+){
+ int i; /* Number of pIdx terms used */
+ int j; /* Number of ORDER BY terms satisfied */
+ int sortOrder = 2; /* 0: forward. 1: backward. 2: unknown */
+ int nTerm; /* Number of ORDER BY terms */
+ struct ExprList_item *pOBItem;/* A term of the ORDER BY clause */
+ Table *pTab = pIdx->pTable; /* Table that owns index pIdx */
+ ExprList *pOrderBy; /* The ORDER BY clause */
+ Parse *pParse = p->pParse; /* Parser context */
+ sqlite3 *db = pParse->db; /* Database connection */
+ int nPriorSat; /* ORDER BY terms satisfied by outer loops */
+ int seenRowid = 0; /* True if an ORDER BY rowid term is seen */
+ int uniqueNotNull; /* pIdx is UNIQUE with all terms are NOT NULL */
+ int outerObUnique; /* Outer loops generate different values in
+ ** every row for the ORDER BY columns */
+
+ if( p->i==0 ){
+ nPriorSat = 0;
+ outerObUnique = 1;
+ }else{
+ u32 wsFlags = p->aLevel[p->i-1].plan.wsFlags;
+ nPriorSat = p->aLevel[p->i-1].plan.nOBSat;
+ if( (wsFlags & WHERE_ORDERED)==0 ){
+ /* This loop cannot be ordered unless the next outer loop is
+ ** also ordered */
+ return nPriorSat;
+ }
+ if( OptimizationDisabled(db, SQLITE_OrderByIdxJoin) ){
+ /* Only look at the outer-most loop if the OrderByIdxJoin
+ ** optimization is disabled */
+ return nPriorSat;
+ }
+ testcase( wsFlags & WHERE_OB_UNIQUE );
+ testcase( wsFlags & WHERE_ALL_UNIQUE );
+ outerObUnique = (wsFlags & (WHERE_OB_UNIQUE|WHERE_ALL_UNIQUE))!=0;
+ }
+ pOrderBy = p->pOrderBy;
+ assert( pOrderBy!=0 );
+ if( pIdx->bUnordered ){
+ /* Hash indices (indicated by the "unordered" tag on sqlite_stat1) cannot
+ ** be used for sorting */
+ return nPriorSat;
+ }
+ nTerm = pOrderBy->nExpr;
+ uniqueNotNull = pIdx->onError!=OE_None;
+ assert( nTerm>0 );
+
+ /* Argument pIdx must either point to a 'real' named index structure,
+ ** or an index structure allocated on the stack by bestBtreeIndex() to
+ ** represent the rowid index that is part of every table. */
+ assert( pIdx->zName || (pIdx->nColumn==1 && pIdx->aiColumn[0]==-1) );
+
+ /* Match terms of the ORDER BY clause against columns of
+ ** the index.
+ **
+ ** Note that indices have pIdx->nColumn regular columns plus
+ ** one additional column containing the rowid. The rowid column
+ ** of the index is also allowed to match against the ORDER BY
+ ** clause.
+ */
+ j = nPriorSat;
+ for(i=0,pOBItem=&pOrderBy->a[j]; j<nTerm && i<=pIdx->nColumn; i++){
+ Expr *pOBExpr; /* The expression of the ORDER BY pOBItem */
+ CollSeq *pColl; /* The collating sequence of pOBExpr */
+ int termSortOrder; /* Sort order for this term */
+ int iColumn; /* The i-th column of the index. -1 for rowid */
+ int iSortOrder; /* 1 for DESC, 0 for ASC on the i-th index term */
+ int isEq; /* Subject to an == or IS NULL constraint */
+ int isMatch; /* ORDER BY term matches the index term */
+ const char *zColl; /* Name of collating sequence for i-th index term */
+ WhereTerm *pConstraint; /* A constraint in the WHERE clause */
+
+ /* If the next term of the ORDER BY clause refers to anything other than
+ ** a column in the "base" table, then this index will not be of any
+ ** further use in handling the ORDER BY. */
+ pOBExpr = sqlite3ExprSkipCollate(pOBItem->pExpr);
+ if( pOBExpr->op!=TK_COLUMN || pOBExpr->iTable!=base ){
+ break;
+ }
+
+ /* Find column number and collating sequence for the next entry
+ ** in the index */
+ if( pIdx->zName && i<pIdx->nColumn ){
+ iColumn = pIdx->aiColumn[i];
+ if( iColumn==pIdx->pTable->iPKey ){
+ iColumn = -1;
+ }
+ iSortOrder = pIdx->aSortOrder[i];
+ zColl = pIdx->azColl[i];
+ assert( zColl!=0 );
+ }else{
+ iColumn = -1;
+ iSortOrder = 0;
+ zColl = 0;
+ }
+
+ /* Check to see if the column number and collating sequence of the
+ ** index match the column number and collating sequence of the ORDER BY
+ ** clause entry. Set isMatch to 1 if they both match. */
+ if( pOBExpr->iColumn==iColumn ){
+ if( zColl ){
+ pColl = sqlite3ExprCollSeq(pParse, pOBItem->pExpr);
+ if( !pColl ) pColl = db->pDfltColl;
+ isMatch = sqlite3StrICmp(pColl->zName, zColl)==0;
+ }else{
+ isMatch = 1;
+ }
+ }else{
+ isMatch = 0;
+ }
+
+ /* termSortOrder is 0 or 1 for whether or not the access loop should
+ ** run forward or backwards (respectively) in order to satisfy this
+ ** term of the ORDER BY clause. */
+ assert( pOBItem->sortOrder==0 || pOBItem->sortOrder==1 );
+ assert( iSortOrder==0 || iSortOrder==1 );
+ termSortOrder = iSortOrder ^ pOBItem->sortOrder;
+
+ /* If X is the column in the index and ORDER BY clause, check to see
+ ** if there are any X= or X IS NULL constraints in the WHERE clause. */
+ pConstraint = findTerm(p->pWC, base, iColumn, p->notReady,
+ WO_EQ|WO_ISNULL|WO_IN, pIdx);
+ if( pConstraint==0 ){
+ isEq = 0;
+ }else if( (pConstraint->eOperator & WO_IN)!=0 ){
+ isEq = 0;
+ }else if( (pConstraint->eOperator & WO_ISNULL)!=0 ){
+ uniqueNotNull = 0;
+ isEq = 1; /* "X IS NULL" means X has only a single value */
+ }else if( pConstraint->prereqRight==0 ){
+ isEq = 1; /* Constraint "X=constant" means X has only a single value */
+ }else{
+ Expr *pRight = pConstraint->pExpr->pRight;
+ if( pRight->op==TK_COLUMN ){
+ WHERETRACE((" .. isOrderedColumn(tab=%d,col=%d)",
+ pRight->iTable, pRight->iColumn));
+ isEq = isOrderedColumn(p, pRight->iTable, pRight->iColumn);
+ WHERETRACE((" -> isEq=%d\n", isEq));
+
+ /* If the constraint is of the form X=Y where Y is an ordered value
+ ** in an outer loop, then make sure the sort order of Y matches the
+ ** sort order required for X. */
+ if( isMatch && isEq>=2 && isEq!=pOBItem->sortOrder+2 ){
+ testcase( isEq==2 );
+ testcase( isEq==3 );
+ break;
+ }
+ }else{
+ isEq = 0; /* "X=expr" places no ordering constraints on X */
+ }
+ }
+ if( !isMatch ){
+ if( isEq==0 ){
+ break;
+ }else{
+ continue;
+ }
+ }else if( isEq!=1 ){
+ if( sortOrder==2 ){
+ sortOrder = termSortOrder;
+ }else if( termSortOrder!=sortOrder ){
+ break;
+ }
+ }
+ j++;
+ pOBItem++;
+ if( iColumn<0 ){
+ seenRowid = 1;
+ break;
+ }else if( pTab->aCol[iColumn].notNull==0 && isEq!=1 ){
+ testcase( isEq==0 );
+ testcase( isEq==2 );
+ testcase( isEq==3 );
+ uniqueNotNull = 0;
+ }
+ }
+ if( seenRowid ){
+ uniqueNotNull = 1;
+ }else if( uniqueNotNull==0 || i<pIdx->nColumn ){
+ uniqueNotNull = 0;
+ }
+
+ /* If we have not found at least one ORDER BY term that matches the
+ ** index, then show no progress. */
+ if( pOBItem==&pOrderBy->a[nPriorSat] ) return nPriorSat;
+
+ /* Either the outer queries must generate rows where there are no two
+ ** rows with the same values in all ORDER BY columns, or else this
+ ** loop must generate just a single row of output. Example: Suppose
+ ** the outer loops generate A=1 and A=1, and this loop generates B=3
+ ** and B=4. Then without the following test, ORDER BY A,B would
+ ** generate the wrong order output: 1,3 1,4 1,3 1,4
+ */
+ if( outerObUnique==0 && uniqueNotNull==0 ) return nPriorSat;
+ *pbObUnique = uniqueNotNull;
+
+ /* Return the necessary scan order back to the caller */
+ *pbRev = sortOrder & 1;
+
+ /* If there was an "ORDER BY rowid" term that matched, or it is only
+ ** possible for a single row from this table to match, then skip over
+ ** any additional ORDER BY terms dealing with this table.
+ */
+ if( uniqueNotNull ){
+ /* Advance j over additional ORDER BY terms associated with base */
+ WhereMaskSet *pMS = p->pWC->pMaskSet;
+ Bitmask m = ~getMask(pMS, base);
+ while( j<nTerm && (exprTableUsage(pMS, pOrderBy->a[j].pExpr)&m)==0 ){
+ j++;
+ }
+ }
+ return j;
+}
/*
** Find the best query plan for accessing a particular table. Write the
-** best query plan and its cost into the WhereCost object supplied as the
-** last parameter.
+** best query plan and its cost into the p->cost.
**
** The lowest cost plan wins. The cost is an estimate of the amount of
** CPU and disk I/O needed to process the requested result.
@@ -101041,33 +106089,33 @@ static int whereInScanEst(
** SQLITE_BIG_DBL. If a plan is found that uses the named index,
** then the cost is calculated in the usual way.
**
-** If a NOT INDEXED clause (pSrc->notIndexed!=0) was attached to the table
+** If a NOT INDEXED clause was attached to the table
** in the SELECT statement, then no indexes are considered. However, the
** selected plan may still take advantage of the built-in rowid primary key
** index.
*/
-static void bestBtreeIndex(
- Parse *pParse, /* The parsing context */
- WhereClause *pWC, /* The WHERE clause */
- struct SrcList_item *pSrc, /* The FROM clause term to search */
- Bitmask notReady, /* Mask of cursors not available for indexing */
- Bitmask notValid, /* Cursors not available for any purpose */
- ExprList *pOrderBy, /* The ORDER BY clause */
- WhereCost *pCost /* Lowest cost query plan */
-){
+static void bestBtreeIndex(WhereBestIdx *p){
+ Parse *pParse = p->pParse; /* The parsing context */
+ WhereClause *pWC = p->pWC; /* The WHERE clause */
+ struct SrcList_item *pSrc = p->pSrc; /* The FROM clause term to search */
int iCur = pSrc->iCursor; /* The cursor of the table to be accessed */
Index *pProbe; /* An index we are evaluating */
Index *pIdx; /* Copy of pProbe, or zero for IPK index */
int eqTermMask; /* Current mask of valid equality operators */
int idxEqTermMask; /* Index mask of valid equality operators */
Index sPk; /* A fake index object for the primary key */
- unsigned int aiRowEstPk[2]; /* The aiRowEst[] value for the sPk index */
+ tRowcnt aiRowEstPk[2]; /* The aiRowEst[] value for the sPk index */
int aiColumnPk = -1; /* The aColumn[] value for the sPk index */
- int wsFlagMask; /* Allowed flags in pCost->plan.wsFlag */
+ int wsFlagMask; /* Allowed flags in p->cost.plan.wsFlag */
+ int nPriorSat; /* ORDER BY terms satisfied by outer loops */
+ int nOrderBy; /* Number of ORDER BY terms */
+ char bSortInit; /* Initializer for bSort in inner loop */
+ char bDistInit; /* Initializer for bDist in inner loop */
+
/* Initialize the cost to a worst-case value */
- memset(pCost, 0, sizeof(*pCost));
- pCost->rCost = SQLITE_BIG_DBL;
+ memset(&p->cost, 0, sizeof(p->cost));
+ p->cost.rCost = SQLITE_BIG_DBL;
/* If the pSrc table is the right table of a LEFT JOIN then we may not
** use an index to satisfy IS NULL constraints on that table. This is
@@ -101113,22 +106161,29 @@ static void bestBtreeIndex(
pIdx = 0;
}
+ nOrderBy = p->pOrderBy ? p->pOrderBy->nExpr : 0;
+ if( p->i ){
+ nPriorSat = p->aLevel[p->i-1].plan.nOBSat;
+ bSortInit = nPriorSat<nOrderBy;
+ bDistInit = 0;
+ }else{
+ nPriorSat = 0;
+ bSortInit = nOrderBy>0;
+ bDistInit = p->pDistinct!=0;
+ }
+
/* Loop over all indices looking for the best one to use
*/
for(; pProbe; pIdx=pProbe=pProbe->pNext){
- const unsigned int * const aiRowEst = pProbe->aiRowEst;
- double cost; /* Cost of using pProbe */
- double nRow; /* Estimated number of rows in result set */
- double log10N; /* base-10 logarithm of nRow (inexact) */
- int rev; /* True to scan in reverse order */
- int wsFlags = 0;
- Bitmask used = 0;
+ const tRowcnt * const aiRowEst = pProbe->aiRowEst;
+ WhereCost pc; /* Cost of using pProbe */
+ double log10N = (double)1; /* base-10 logarithm of nRow (inexact) */
/* The following variables are populated based on the properties of
** index being evaluated. They are then used to determine the expected
** cost and number of rows returned.
**
- ** nEq:
+ ** pc.plan.nEq:
** Number of equality terms that can be implemented using the index.
** In other words, the number of initial fields in the index that
** are used in == or IN or NOT NULL constraints of the WHERE clause.
@@ -101159,20 +106214,22 @@ static void bestBtreeIndex(
** IN operator must be a SELECT, not a value list, for this variable
** to be true.
**
- ** estBound:
- ** An estimate on the amount of the table that must be searched. A
- ** value of 100 means the entire table is searched. Range constraints
- ** might reduce this to a value less than 100 to indicate that only
- ** a fraction of the table needs searching. In the absence of
- ** sqlite_stat2 ANALYZE data, a single inequality reduces the search
- ** space to 1/4rd its original size. So an x>? constraint reduces
- ** estBound to 25. Two constraints (x>? AND x<?) reduce estBound to 6.
+ ** rangeDiv:
+ ** An estimate of a divisor by which to reduce the search space due
+ ** to inequality constraints. In the absence of sqlite_stat3 ANALYZE
+ ** data, a single inequality reduces the search space to 1/4rd its
+ ** original size (rangeDiv==4). Two inequalities reduce the search
+ ** space to 1/16th of its original size (rangeDiv==16).
**
** bSort:
** Boolean. True if there is an ORDER BY clause that will require an
** external sort (i.e. scanning the index being evaluated will not
** correctly order records).
**
+ ** bDist:
+ ** Boolean. True if there is a DISTINCT clause that will require an
+ ** external btree.
+ **
** bLookup:
** Boolean. True if a table lookup is required for each index entry
** visited. In other words, true if this is not a covering index.
@@ -101188,27 +106245,35 @@ static void bestBtreeIndex(
** SELECT a, b FROM tbl WHERE a = 1;
** SELECT a, b, c FROM tbl WHERE a = 1;
*/
- int nEq; /* Number of == or IN terms matching index */
int bInEst = 0; /* True if "x IN (SELECT...)" seen */
int nInMul = 1; /* Number of distinct equalities to lookup */
- int estBound = 100; /* Estimated reduction in search space */
+ double rangeDiv = (double)1; /* Estimated reduction in search space */
int nBound = 0; /* Number of range constraints seen */
- int bSort = 0; /* True if external sort required */
- int bLookup = 0; /* True if not a covering index */
+ char bSort = bSortInit; /* True if external sort required */
+ char bDist = bDistInit; /* True if index cannot help with DISTINCT */
+ char bLookup = 0; /* True if not a covering index */
WhereTerm *pTerm; /* A single term of the WHERE clause */
-#ifdef SQLITE_ENABLE_STAT2
+#ifdef SQLITE_ENABLE_STAT3
WhereTerm *pFirstTerm = 0; /* First term matching the index */
#endif
- /* Determine the values of nEq and nInMul */
- for(nEq=0; nEq<pProbe->nColumn; nEq++){
- int j = pProbe->aiColumn[nEq];
- pTerm = findTerm(pWC, iCur, j, notReady, eqTermMask, pIdx);
+ WHERETRACE((
+ " %s(%s):\n",
+ pSrc->pTab->zName, (pIdx ? pIdx->zName : "ipk")
+ ));
+ memset(&pc, 0, sizeof(pc));
+ pc.plan.nOBSat = nPriorSat;
+
+ /* Determine the values of pc.plan.nEq and nInMul */
+ for(pc.plan.nEq=0; pc.plan.nEq<pProbe->nColumn; pc.plan.nEq++){
+ int j = pProbe->aiColumn[pc.plan.nEq];
+ pTerm = findTerm(pWC, iCur, j, p->notReady, eqTermMask, pIdx);
if( pTerm==0 ) break;
- wsFlags |= (WHERE_COLUMN_EQ|WHERE_ROWID_EQ);
+ pc.plan.wsFlags |= (WHERE_COLUMN_EQ|WHERE_ROWID_EQ);
+ testcase( pTerm->pWC!=pWC );
if( pTerm->eOperator & WO_IN ){
Expr *pExpr = pTerm->pExpr;
- wsFlags |= WHERE_COLUMN_IN;
+ pc.plan.wsFlags |= WHERE_COLUMN_IN;
if( ExprHasProperty(pExpr, EP_xIsSelect) ){
/* "x IN (SELECT ...)": Assume the SELECT returns 25 rows */
nInMul *= 25;
@@ -101218,64 +106283,96 @@ static void bestBtreeIndex(
nInMul *= pExpr->x.pList->nExpr;
}
}else if( pTerm->eOperator & WO_ISNULL ){
- wsFlags |= WHERE_COLUMN_NULL;
+ pc.plan.wsFlags |= WHERE_COLUMN_NULL;
}
-#ifdef SQLITE_ENABLE_STAT2
- if( nEq==0 && pProbe->aSample ) pFirstTerm = pTerm;
+#ifdef SQLITE_ENABLE_STAT3
+ if( pc.plan.nEq==0 && pProbe->aSample ) pFirstTerm = pTerm;
#endif
- used |= pTerm->prereqRight;
+ pc.used |= pTerm->prereqRight;
}
-
- /* Determine the value of estBound. */
- if( nEq<pProbe->nColumn && pProbe->bUnordered==0 ){
- int j = pProbe->aiColumn[nEq];
- if( findTerm(pWC, iCur, j, notReady, WO_LT|WO_LE|WO_GT|WO_GE, pIdx) ){
- WhereTerm *pTop = findTerm(pWC, iCur, j, notReady, WO_LT|WO_LE, pIdx);
- WhereTerm *pBtm = findTerm(pWC, iCur, j, notReady, WO_GT|WO_GE, pIdx);
- whereRangeScanEst(pParse, pProbe, nEq, pBtm, pTop, &estBound);
+
+ /* If the index being considered is UNIQUE, and there is an equality
+ ** constraint for all columns in the index, then this search will find
+ ** at most a single row. In this case set the WHERE_UNIQUE flag to
+ ** indicate this to the caller.
+ **
+ ** Otherwise, if the search may find more than one row, test to see if
+ ** there is a range constraint on indexed column (pc.plan.nEq+1) that
+ ** can be optimized using the index.
+ */
+ if( pc.plan.nEq==pProbe->nColumn && pProbe->onError!=OE_None ){
+ testcase( pc.plan.wsFlags & WHERE_COLUMN_IN );
+ testcase( pc.plan.wsFlags & WHERE_COLUMN_NULL );
+ if( (pc.plan.wsFlags & (WHERE_COLUMN_IN|WHERE_COLUMN_NULL))==0 ){
+ pc.plan.wsFlags |= WHERE_UNIQUE;
+ if( p->i==0 || (p->aLevel[p->i-1].plan.wsFlags & WHERE_ALL_UNIQUE)!=0 ){
+ pc.plan.wsFlags |= WHERE_ALL_UNIQUE;
+ }
+ }
+ }else if( pProbe->bUnordered==0 ){
+ int j;
+ j = (pc.plan.nEq==pProbe->nColumn ? -1 : pProbe->aiColumn[pc.plan.nEq]);
+ if( findTerm(pWC, iCur, j, p->notReady, WO_LT|WO_LE|WO_GT|WO_GE, pIdx) ){
+ WhereTerm *pTop, *pBtm;
+ pTop = findTerm(pWC, iCur, j, p->notReady, WO_LT|WO_LE, pIdx);
+ pBtm = findTerm(pWC, iCur, j, p->notReady, WO_GT|WO_GE, pIdx);
+ whereRangeScanEst(pParse, pProbe, pc.plan.nEq, pBtm, pTop, &rangeDiv);
if( pTop ){
nBound = 1;
- wsFlags |= WHERE_TOP_LIMIT;
- used |= pTop->prereqRight;
+ pc.plan.wsFlags |= WHERE_TOP_LIMIT;
+ pc.used |= pTop->prereqRight;
+ testcase( pTop->pWC!=pWC );
}
if( pBtm ){
nBound++;
- wsFlags |= WHERE_BTM_LIMIT;
- used |= pBtm->prereqRight;
+ pc.plan.wsFlags |= WHERE_BTM_LIMIT;
+ pc.used |= pBtm->prereqRight;
+ testcase( pBtm->pWC!=pWC );
}
- wsFlags |= (WHERE_COLUMN_RANGE|WHERE_ROWID_RANGE);
- }
- }else if( pProbe->onError!=OE_None ){
- testcase( wsFlags & WHERE_COLUMN_IN );
- testcase( wsFlags & WHERE_COLUMN_NULL );
- if( (wsFlags & (WHERE_COLUMN_IN|WHERE_COLUMN_NULL))==0 ){
- wsFlags |= WHERE_UNIQUE;
+ pc.plan.wsFlags |= (WHERE_COLUMN_RANGE|WHERE_ROWID_RANGE);
}
}
/* If there is an ORDER BY clause and the index being considered will
** naturally scan rows in the required order, set the appropriate flags
- ** in wsFlags. Otherwise, if there is an ORDER BY clause but the index
- ** will scan rows in a different order, set the bSort variable. */
- if( pOrderBy ){
- if( (wsFlags & WHERE_COLUMN_IN)==0
- && pProbe->bUnordered==0
- && isSortingIndex(pParse, pWC->pMaskSet, pProbe, iCur, pOrderBy,
- nEq, wsFlags, &rev)
- ){
- wsFlags |= WHERE_ROWID_RANGE|WHERE_COLUMN_RANGE|WHERE_ORDERBY;
- wsFlags |= (rev ? WHERE_REVERSE : 0);
- }else{
- bSort = 1;
- }
+ ** in pc.plan.wsFlags. Otherwise, if there is an ORDER BY clause but
+ ** the index will scan rows in a different order, set the bSort
+ ** variable. */
+ if( bSort && (pSrc->jointype & JT_LEFT)==0 ){
+ int bRev = 2;
+ int bObUnique = 0;
+ WHERETRACE((" --> before isSortIndex: nPriorSat=%d\n",nPriorSat));
+ pc.plan.nOBSat = isSortingIndex(p, pProbe, iCur, &bRev, &bObUnique);
+ WHERETRACE((" --> after isSortIndex: bRev=%d bObU=%d nOBSat=%d\n",
+ bRev, bObUnique, pc.plan.nOBSat));
+ if( nPriorSat<pc.plan.nOBSat || (pc.plan.wsFlags & WHERE_ALL_UNIQUE)!=0 ){
+ pc.plan.wsFlags |= WHERE_ORDERED;
+ if( bObUnique ) pc.plan.wsFlags |= WHERE_OB_UNIQUE;
+ }
+ if( nOrderBy==pc.plan.nOBSat ){
+ bSort = 0;
+ pc.plan.wsFlags |= WHERE_ROWID_RANGE|WHERE_COLUMN_RANGE;
+ }
+ if( bRev & 1 ) pc.plan.wsFlags |= WHERE_REVERSE;
+ }
+
+ /* If there is a DISTINCT qualifier and this index will scan rows in
+ ** order of the DISTINCT expressions, clear bDist and set the appropriate
+ ** flags in pc.plan.wsFlags. */
+ if( bDist
+ && isDistinctIndex(pParse, pWC, pProbe, iCur, p->pDistinct, pc.plan.nEq)
+ && (pc.plan.wsFlags & WHERE_COLUMN_IN)==0
+ ){
+ bDist = 0;
+ pc.plan.wsFlags |= WHERE_ROWID_RANGE|WHERE_COLUMN_RANGE|WHERE_DISTINCT;
}
/* If currently calculating the cost of using an index (not the IPK
** index), determine if all required column data may be obtained without
** using the main table (i.e. if the index is a covering
** index for this query). If it is, set the WHERE_IDX_ONLY flag in
- ** wsFlags. Otherwise, set the bLookup variable to true. */
- if( pIdx && wsFlags ){
+ ** pc.plan.wsFlags. Otherwise, set the bLookup variable to true. */
+ if( pIdx ){
Bitmask m = pSrc->colUsed;
int j;
for(j=0; j<pIdx->nColumn; j++){
@@ -101285,7 +106382,7 @@ static void bestBtreeIndex(
}
}
if( m==0 ){
- wsFlags |= WHERE_IDX_ONLY;
+ pc.plan.wsFlags |= WHERE_IDX_ONLY;
}else{
bLookup = 1;
}
@@ -101295,34 +106392,41 @@ static void bestBtreeIndex(
** Estimate the number of rows of output. For an "x IN (SELECT...)"
** constraint, do not let the estimate exceed half the rows in the table.
*/
- nRow = (double)(aiRowEst[nEq] * nInMul);
- if( bInEst && nRow*2>aiRowEst[0] ){
- nRow = aiRowEst[0]/2;
- nInMul = (int)(nRow / aiRowEst[nEq]);
+ pc.plan.nRow = (double)(aiRowEst[pc.plan.nEq] * nInMul);
+ if( bInEst && pc.plan.nRow*2>aiRowEst[0] ){
+ pc.plan.nRow = aiRowEst[0]/2;
+ nInMul = (int)(pc.plan.nRow / aiRowEst[pc.plan.nEq]);
}
-#ifdef SQLITE_ENABLE_STAT2
- /* If the constraint is of the form x=VALUE and histogram
+#ifdef SQLITE_ENABLE_STAT3
+ /* If the constraint is of the form x=VALUE or x IN (E1,E2,...)
+ ** and we do not think that values of x are unique and if histogram
** data is available for column x, then it might be possible
** to get a better estimate on the number of rows based on
** VALUE and how common that value is according to the histogram.
*/
- if( nRow>(double)1 && nEq==1 && pFirstTerm!=0 ){
+ if( pc.plan.nRow>(double)1 && pc.plan.nEq==1
+ && pFirstTerm!=0 && aiRowEst[1]>1 ){
+ assert( (pFirstTerm->eOperator & (WO_EQ|WO_ISNULL|WO_IN))!=0 );
if( pFirstTerm->eOperator & (WO_EQ|WO_ISNULL) ){
- testcase( pFirstTerm->eOperator==WO_EQ );
- testcase( pFirstTerm->eOperator==WO_ISNULL );
- whereEqualScanEst(pParse, pProbe, pFirstTerm->pExpr->pRight, &nRow);
- }else if( pFirstTerm->eOperator==WO_IN && bInEst==0 ){
- whereInScanEst(pParse, pProbe, pFirstTerm->pExpr->x.pList, &nRow);
+ testcase( pFirstTerm->eOperator & WO_EQ );
+ testcase( pFirstTerm->eOperator & WO_EQUIV );
+ testcase( pFirstTerm->eOperator & WO_ISNULL );
+ whereEqualScanEst(pParse, pProbe, pFirstTerm->pExpr->pRight,
+ &pc.plan.nRow);
+ }else if( bInEst==0 ){
+ assert( pFirstTerm->eOperator & WO_IN );
+ whereInScanEst(pParse, pProbe, pFirstTerm->pExpr->x.pList,
+ &pc.plan.nRow);
}
}
-#endif /* SQLITE_ENABLE_STAT2 */
+#endif /* SQLITE_ENABLE_STAT3 */
/* Adjust the number of output rows and downward to reflect rows
** that are excluded by range constraints.
*/
- nRow = (nRow * (double)estBound) / (double)100;
- if( nRow<1 ) nRow = 1;
+ pc.plan.nRow = pc.plan.nRow/rangeDiv;
+ if( pc.plan.nRow<1 ) pc.plan.nRow = 1;
/* Experiments run on real SQLite databases show that the time needed
** to do a binary search to locate a row in a table or index is roughly
@@ -101332,12 +106436,24 @@ static void bestBtreeIndex(
** slower with larger records, presumably because fewer records fit
** on one page and hence more pages have to be fetched.
**
- ** The ANALYZE command and the sqlite_stat1 and sqlite_stat2 tables do
+ ** The ANALYZE command and the sqlite_stat1 and sqlite_stat3 tables do
** not give us data on the relative sizes of table and index records.
** So this computation assumes table records are about twice as big
** as index records
*/
- if( (wsFlags & WHERE_NOT_FULLSCAN)==0 ){
+ if( (pc.plan.wsFlags&~(WHERE_REVERSE|WHERE_ORDERED|WHERE_OB_UNIQUE))
+ ==WHERE_IDX_ONLY
+ && (pWC->wctrlFlags & WHERE_ONEPASS_DESIRED)==0
+ && sqlite3GlobalConfig.bUseCis
+ && OptimizationEnabled(pParse->db, SQLITE_CoverIdxScan)
+ ){
+ /* This index is not useful for indexing, but it is a covering index.
+ ** A full-scan of the index might be a little faster than a full-scan
+ ** of the table, so give this case a cost slightly less than a table
+ ** scan. */
+ pc.rCost = aiRowEst[0]*3 + pProbe->nColumn;
+ pc.plan.wsFlags |= WHERE_COVER_SCAN|WHERE_COLUMN_RANGE;
+ }else if( (pc.plan.wsFlags & WHERE_NOT_FULLSCAN)==0 ){
/* The cost of a full table scan is a number of move operations equal
** to the number of rows in the table.
**
@@ -101347,10 +106463,15 @@ static void bestBtreeIndex(
** decision and one which we expect to revisit in the future. But
** it seems to be working well enough at the moment.
*/
- cost = aiRowEst[0]*4;
+ pc.rCost = aiRowEst[0]*4;
+ pc.plan.wsFlags &= ~WHERE_IDX_ONLY;
+ if( pIdx ){
+ pc.plan.wsFlags &= ~WHERE_ORDERED;
+ pc.plan.nOBSat = nPriorSat;
+ }
}else{
log10N = estLog(aiRowEst[0]);
- cost = nRow;
+ pc.rCost = pc.plan.nRow;
if( pIdx ){
if( bLookup ){
/* For an index lookup followed by a table lookup:
@@ -101358,20 +106479,20 @@ static void bestBtreeIndex(
** + nRow steps through the index
** + nRow table searches to lookup the table entry using the rowid
*/
- cost += (nInMul + nRow)*log10N;
+ pc.rCost += (nInMul + pc.plan.nRow)*log10N;
}else{
/* For a covering index:
** nInMul index searches to find the initial entry
** + nRow steps through the index
*/
- cost += nInMul*log10N;
+ pc.rCost += nInMul*log10N;
}
}else{
/* For a rowid primary key lookup:
** nInMult table searches to find the initial entry for each range
** + nRow steps through the table
*/
- cost += nInMul*log10N;
+ pc.rCost += nInMul*log10N;
}
}
@@ -101382,7 +106503,12 @@ static void bestBtreeIndex(
** difference and select C of 3.0.
*/
if( bSort ){
- cost += nRow*estLog(nRow)*3;
+ double m = estLog(pc.plan.nRow*(nOrderBy - pc.plan.nOBSat)/nOrderBy);
+ m *= (double)(pc.plan.nOBSat ? 2 : 3);
+ pc.rCost += pc.plan.nRow*m;
+ }
+ if( bDist ){
+ pc.rCost += pc.plan.nRow*estLog(pc.plan.nRow)*3;
}
/**** Cost of using this index has now been computed ****/
@@ -101403,25 +106529,25 @@ static void bestBtreeIndex(
** might be selected even when there exists an optimal index that has
** no such dependency.
*/
- if( nRow>2 && cost<=pCost->rCost ){
+ if( pc.plan.nRow>2 && pc.rCost<=p->cost.rCost ){
int k; /* Loop counter */
- int nSkipEq = nEq; /* Number of == constraints to skip */
+ int nSkipEq = pc.plan.nEq; /* Number of == constraints to skip */
int nSkipRange = nBound; /* Number of < constraints to skip */
Bitmask thisTab; /* Bitmap for pSrc */
thisTab = getMask(pWC->pMaskSet, iCur);
- for(pTerm=pWC->a, k=pWC->nTerm; nRow>2 && k; k--, pTerm++){
+ for(pTerm=pWC->a, k=pWC->nTerm; pc.plan.nRow>2 && k; k--, pTerm++){
if( pTerm->wtFlags & TERM_VIRTUAL ) continue;
- if( (pTerm->prereqAll & notValid)!=thisTab ) continue;
+ if( (pTerm->prereqAll & p->notValid)!=thisTab ) continue;
if( pTerm->eOperator & (WO_EQ|WO_IN|WO_ISNULL) ){
if( nSkipEq ){
- /* Ignore the first nEq equality matches since the index
+ /* Ignore the first pc.plan.nEq equality matches since the index
** has already accounted for these */
nSkipEq--;
}else{
/* Assume each additional equality match reduces the result
** set size by a factor of 10 */
- nRow /= 10;
+ pc.plan.nRow /= 10;
}
}else if( pTerm->eOperator & (WO_LT|WO_LE|WO_GT|WO_GE) ){
if( nSkipRange ){
@@ -101435,37 +106561,33 @@ static void bestBtreeIndex(
** more selective intentionally because of the subjective
** observation that indexed range constraints really are more
** selective in practice, on average. */
- nRow /= 3;
+ pc.plan.nRow /= 3;
}
- }else if( pTerm->eOperator!=WO_NOOP ){
+ }else if( (pTerm->eOperator & WO_NOOP)==0 ){
/* Any other expression lowers the output row count by half */
- nRow /= 2;
+ pc.plan.nRow /= 2;
}
}
- if( nRow<2 ) nRow = 2;
+ if( pc.plan.nRow<2 ) pc.plan.nRow = 2;
}
WHERETRACE((
- "%s(%s): nEq=%d nInMul=%d estBound=%d bSort=%d bLookup=%d wsFlags=0x%x\n"
- " notReady=0x%llx log10N=%.1f nRow=%.1f cost=%.1f used=0x%llx\n",
- pSrc->pTab->zName, (pIdx ? pIdx->zName : "ipk"),
- nEq, nInMul, estBound, bSort, bLookup, wsFlags,
- notReady, log10N, nRow, cost, used
+ " nEq=%d nInMul=%d rangeDiv=%d bSort=%d bLookup=%d wsFlags=0x%08x\n"
+ " notReady=0x%llx log10N=%.1f nRow=%.1f cost=%.1f\n"
+ " used=0x%llx nOBSat=%d\n",
+ pc.plan.nEq, nInMul, (int)rangeDiv, bSort, bLookup, pc.plan.wsFlags,
+ p->notReady, log10N, pc.plan.nRow, pc.rCost, pc.used,
+ pc.plan.nOBSat
));
/* If this index is the best we have seen so far, then record this
- ** index and its cost in the pCost structure.
+ ** index and its cost in the p->cost structure.
*/
- if( (!pIdx || wsFlags)
- && (cost<pCost->rCost || (cost<=pCost->rCost && nRow<pCost->plan.nRow))
- ){
- pCost->rCost = cost;
- pCost->used = used;
- pCost->plan.nRow = nRow;
- pCost->plan.wsFlags = (wsFlags&wsFlagMask);
- pCost->plan.nEq = nEq;
- pCost->plan.u.pIdx = pIdx;
+ if( (!pIdx || pc.plan.wsFlags) && compareCost(&pc, &p->cost) ){
+ p->cost = pc;
+ p->cost.plan.wsFlags &= wsFlagMask;
+ p->cost.plan.u.pIdx = pIdx;
}
/* If there was an INDEXED BY clause, then only that one index is
@@ -101480,27 +106602,26 @@ static void bestBtreeIndex(
/* If there is no ORDER BY clause and the SQLITE_ReverseOrder flag
** is set, then reverse the order that the index will be scanned
** in. This is used for application testing, to help find cases
- ** where application behaviour depends on the (undefined) order that
+ ** where application behavior depends on the (undefined) order that
** SQLite outputs rows in in the absence of an ORDER BY clause. */
- if( !pOrderBy && pParse->db->flags & SQLITE_ReverseOrder ){
- pCost->plan.wsFlags |= WHERE_REVERSE;
+ if( !p->pOrderBy && pParse->db->flags & SQLITE_ReverseOrder ){
+ p->cost.plan.wsFlags |= WHERE_REVERSE;
}
- assert( pOrderBy || (pCost->plan.wsFlags&WHERE_ORDERBY)==0 );
- assert( pCost->plan.u.pIdx==0 || (pCost->plan.wsFlags&WHERE_ROWID_EQ)==0 );
+ assert( p->pOrderBy || (p->cost.plan.wsFlags&WHERE_ORDERED)==0 );
+ assert( p->cost.plan.u.pIdx==0 || (p->cost.plan.wsFlags&WHERE_ROWID_EQ)==0 );
assert( pSrc->pIndex==0
- || pCost->plan.u.pIdx==0
- || pCost->plan.u.pIdx==pSrc->pIndex
+ || p->cost.plan.u.pIdx==0
+ || p->cost.plan.u.pIdx==pSrc->pIndex
);
- WHERETRACE(("best index is: %s\n",
- ((pCost->plan.wsFlags & WHERE_NOT_FULLSCAN)==0 ? "none" :
- pCost->plan.u.pIdx ? pCost->plan.u.pIdx->zName : "ipk")
- ));
+ WHERETRACE((" best index is %s cost=%.1f\n",
+ p->cost.plan.u.pIdx ? p->cost.plan.u.pIdx->zName : "ipk",
+ p->cost.rCost));
- bestOrClauseIndex(pParse, pWC, pSrc, notReady, notValid, pOrderBy, pCost);
- bestAutomaticIndex(pParse, pWC, pSrc, notReady, pCost);
- pCost->plan.wsFlags |= eqTermMask;
+ bestOrClauseIndex(p);
+ bestAutomaticIndex(p);
+ p->cost.plan.wsFlags |= eqTermMask;
}
/*
@@ -101508,28 +106629,28 @@ static void bestBtreeIndex(
** best query plan and its cost into the WhereCost object supplied
** as the last parameter. This function may calculate the cost of
** both real and virtual table scans.
+**
+** This function does not take ORDER BY or DISTINCT into account. Nor
+** does it remember the virtual table query plan. All it does is compute
+** the cost while determining if an OR optimization is applicable. The
+** details will be reconsidered later if the optimization is found to be
+** applicable.
*/
-static void bestIndex(
- Parse *pParse, /* The parsing context */
- WhereClause *pWC, /* The WHERE clause */
- struct SrcList_item *pSrc, /* The FROM clause term to search */
- Bitmask notReady, /* Mask of cursors not available for indexing */
- Bitmask notValid, /* Cursors not available for any purpose */
- ExprList *pOrderBy, /* The ORDER BY clause */
- WhereCost *pCost /* Lowest cost query plan */
-){
+static void bestIndex(WhereBestIdx *p){
#ifndef SQLITE_OMIT_VIRTUALTABLE
- if( IsVirtual(pSrc->pTab) ){
- sqlite3_index_info *p = 0;
- bestVirtualIndex(pParse, pWC, pSrc, notReady, notValid, pOrderBy, pCost,&p);
- if( p->needToFreeIdxStr ){
- sqlite3_free(p->idxStr);
- }
- sqlite3DbFree(pParse->db, p);
+ if( IsVirtual(p->pSrc->pTab) ){
+ sqlite3_index_info *pIdxInfo = 0;
+ p->ppIdxInfo = &pIdxInfo;
+ bestVirtualIndex(p);
+ assert( pIdxInfo!=0 || p->pParse->db->mallocFailed );
+ if( pIdxInfo && pIdxInfo->needToFreeIdxStr ){
+ sqlite3_free(pIdxInfo->idxStr);
+ }
+ sqlite3DbFree(p->pParse->db, pIdxInfo);
}else
#endif
{
- bestBtreeIndex(pParse, pWC, pSrc, notReady, notValid, pOrderBy, pCost);
+ bestBtreeIndex(p);
}
}
@@ -101628,7 +106749,8 @@ static void codeApplyAffinity(Parse *pParse, int base, int n, char *zAff){
static int codeEqualityTerm(
Parse *pParse, /* The parsing context */
WhereTerm *pTerm, /* The term of the WHERE clause to be coded */
- WhereLevel *pLevel, /* When level of the FROM clause we are working on */
+ WhereLevel *pLevel, /* The level of the FROM clause we are working on */
+ int iEq, /* Index of the equality term within this level */
int iTarget /* Attempt to leave results in this register */
){
Expr *pX = pTerm->pExpr;
@@ -101646,12 +106768,26 @@ static int codeEqualityTerm(
int eType;
int iTab;
struct InLoop *pIn;
+ u8 bRev = (pLevel->plan.wsFlags & WHERE_REVERSE)!=0;
+ if( (pLevel->plan.wsFlags & WHERE_INDEXED)!=0
+ && pLevel->plan.u.pIdx->aSortOrder[iEq]
+ ){
+ testcase( iEq==0 );
+ testcase( iEq==pLevel->plan.u.pIdx->nColumn-1 );
+ testcase( iEq>0 && iEq+1<pLevel->plan.u.pIdx->nColumn );
+ testcase( bRev );
+ bRev = !bRev;
+ }
assert( pX->op==TK_IN );
iReg = iTarget;
eType = sqlite3FindInIndex(pParse, pX, 0);
+ if( eType==IN_INDEX_INDEX_DESC ){
+ testcase( bRev );
+ bRev = !bRev;
+ }
iTab = pX->iTable;
- sqlite3VdbeAddOp2(v, OP_Rewind, iTab, 0);
+ sqlite3VdbeAddOp2(v, bRev ? OP_Last : OP_Rewind, iTab, 0);
assert( pLevel->plan.wsFlags & WHERE_IN_ABLE );
if( pLevel->u.in.nIn==0 ){
pLevel->addrNxt = sqlite3VdbeMakeLabel(v);
@@ -101669,6 +106805,7 @@ static int codeEqualityTerm(
}else{
pIn->addrInTop = sqlite3VdbeAddOp3(v, OP_Column, iTab, 0, iReg);
}
+ pIn->eEndLoopOp = bRev ? OP_Prev : OP_Next;
sqlite3VdbeAddOp1(v, OP_IsNull, iReg);
}else{
pLevel->u.in.nIn = 0;
@@ -101758,12 +106895,12 @@ static int codeAllEqualityTerms(
int r1;
int k = pIdx->aiColumn[j];
pTerm = findTerm(pWC, iCur, k, notReady, pLevel->plan.wsFlags, pIdx);
- if( NEVER(pTerm==0) ) break;
+ if( pTerm==0 ) break;
/* The following true for indices with redundant columns.
** Ex: CREATE INDEX i1 ON t1(a,b,a); SELECT * FROM t1 WHERE a=0 AND b=0; */
testcase( (pTerm->wtFlags & TERM_CODED)!=0 );
testcase( pTerm->wtFlags & TERM_VIRTUAL ); /* EV: R-30575-11662 */
- r1 = codeEqualityTerm(pParse, pTerm, pLevel, regBase+j);
+ r1 = codeEqualityTerm(pParse, pTerm, pLevel, j, regBase+j);
if( r1!=regBase+j ){
if( nReg==1 ){
sqlite3ReleaseTempReg(pParse, regBase);
@@ -101852,10 +106989,12 @@ static char *explainIndexRange(sqlite3 *db, WhereLevel *pLevel, Table *pTab){
j = i;
if( pPlan->wsFlags&WHERE_BTM_LIMIT ){
- explainAppendTerm(&txt, i++, aCol[aiColumn[j]].zName, ">");
+ char *z = (j==pIndex->nColumn ) ? "rowid" : aCol[aiColumn[j]].zName;
+ explainAppendTerm(&txt, i++, z, ">");
}
if( pPlan->wsFlags&WHERE_TOP_LIMIT ){
- explainAppendTerm(&txt, i, aCol[aiColumn[j]].zName, "<");
+ char *z = (j==pIndex->nColumn ) ? "rowid" : aCol[aiColumn[j]].zName;
+ explainAppendTerm(&txt, i, z, "<");
}
sqlite3StrAccumAppend(&txt, ")", 1);
return sqlite3StrAccumFinish(&txt);
@@ -102005,12 +107144,23 @@ static Bitmask codeOneLoopStart(
VdbeComment((v, "init LEFT JOIN no-match flag"));
}
+ /* Special case of a FROM clause subquery implemented as a co-routine */
+ if( pTabItem->viaCoroutine ){
+ int regYield = pTabItem->regReturn;
+ sqlite3VdbeAddOp2(v, OP_Integer, pTabItem->addrFillSub-1, regYield);
+ pLevel->p2 = sqlite3VdbeAddOp1(v, OP_Yield, regYield);
+ VdbeComment((v, "next row of co-routine %s", pTabItem->pTab->zName));
+ sqlite3VdbeAddOp2(v, OP_If, regYield+1, addrBrk);
+ pLevel->op = OP_Goto;
+ }else
+
#ifndef SQLITE_OMIT_VIRTUALTABLE
if( (pLevel->plan.wsFlags & WHERE_VIRTUALTABLE)!=0 ){
/* Case 0: The table is a virtual-table. Use the VFilter and VNext
** to access the data.
*/
int iReg; /* P3 Value for OP_VFilter */
+ int addrNotFound;
sqlite3_index_info *pVtabIdx = pLevel->plan.u.pVtabIdx;
int nConstraint = pVtabIdx->nConstraint;
struct sqlite3_index_constraint_usage *aUsage =
@@ -102020,11 +107170,18 @@ static Bitmask codeOneLoopStart(
sqlite3ExprCachePush(pParse);
iReg = sqlite3GetTempRange(pParse, nConstraint+2);
+ addrNotFound = pLevel->addrBrk;
for(j=1; j<=nConstraint; j++){
for(k=0; k<nConstraint; k++){
if( aUsage[k].argvIndex==j ){
- int iTerm = aConstraint[k].iTermOffset;
- sqlite3ExprCode(pParse, pWC->a[iTerm].pExpr->pRight, iReg+j+1);
+ int iTarget = iReg+j+1;
+ pTerm = &pWC->a[aConstraint[k].iTermOffset];
+ if( pTerm->eOperator & WO_IN ){
+ codeEqualityTerm(pParse, pTerm, pLevel, k, iTarget);
+ addrNotFound = pLevel->addrNxt;
+ }else{
+ sqlite3ExprCode(pParse, pTerm->pExpr->pRight, iTarget);
+ }
break;
}
}
@@ -102032,7 +107189,7 @@ static Bitmask codeOneLoopStart(
}
sqlite3VdbeAddOp2(v, OP_Integer, pVtabIdx->idxNum, iReg);
sqlite3VdbeAddOp2(v, OP_Integer, j-1, iReg+1);
- sqlite3VdbeAddOp4(v, OP_VFilter, iCur, addrBrk, iReg, pVtabIdx->idxStr,
+ sqlite3VdbeAddOp4(v, OP_VFilter, iCur, addrNotFound, iReg, pVtabIdx->idxStr,
pVtabIdx->needToFreeIdxStr ? P4_MPRINTF : P4_STATIC);
pVtabIdx->needToFreeIdxStr = 0;
for(j=0; j<nConstraint; j++){
@@ -102059,13 +107216,13 @@ static Bitmask codeOneLoopStart(
pTerm = findTerm(pWC, iCur, -1, notReady, WO_EQ|WO_IN, 0);
assert( pTerm!=0 );
assert( pTerm->pExpr!=0 );
- assert( pTerm->leftCursor==iCur );
assert( omitTable==0 );
testcase( pTerm->wtFlags & TERM_VIRTUAL ); /* EV: R-30575-11662 */
- iRowidReg = codeEqualityTerm(pParse, pTerm, pLevel, iReleaseReg);
+ iRowidReg = codeEqualityTerm(pParse, pTerm, pLevel, 0, iReleaseReg);
addrNxt = pLevel->addrNxt;
sqlite3VdbeAddOp2(v, OP_MustBeInt, iRowidReg, addrNxt);
sqlite3VdbeAddOp3(v, OP_NotExists, iCur, addrNxt, iRowidReg);
+ sqlite3ExprCacheAffinityChange(pParse, iRowidReg, 1);
sqlite3ExprCacheStore(pParse, iCur, -1, iRowidReg);
VdbeComment((v, "pk"));
pLevel->op = OP_Noop;
@@ -102212,7 +107369,7 @@ static Bitmask codeOneLoopStart(
pIdx = pLevel->plan.u.pIdx;
iIdxCur = pLevel->iIdxCur;
- k = pIdx->aiColumn[nEq]; /* Column for inequality constraints */
+ k = (nEq==pIdx->nColumn ? -1 : pIdx->aiColumn[nEq]);
/* If this loop satisfies a sort order (pOrderBy) request that
** was passed to this function to implement a "SELECT min(x) ..."
@@ -102223,7 +107380,7 @@ static Bitmask codeOneLoopStart(
** this requires some special handling.
*/
if( (wctrlFlags&WHERE_ORDERBY_MIN)!=0
- && (pLevel->plan.wsFlags&WHERE_ORDERBY)
+ && (pLevel->plan.wsFlags&WHERE_ORDERED)
&& (pIdx->nColumn>nEq)
){
/* assert( pOrderBy->nExpr==1 ); */
@@ -102258,7 +107415,9 @@ static Bitmask codeOneLoopStart(
** a forward order scan on a descending index, interchange the
** start and end terms (pRangeStart and pRangeEnd).
*/
- if( nEq<pIdx->nColumn && bRev==(pIdx->aSortOrder[nEq]==SQLITE_SO_ASC) ){
+ if( (nEq<pIdx->nColumn && bRev==(pIdx->aSortOrder[nEq]==SQLITE_SO_ASC))
+ || (bRev && pIdx->nColumn==nEq)
+ ){
SWAP(WhereTerm *, pRangeEnd, pRangeStart);
}
@@ -102384,6 +107543,11 @@ static Bitmask codeOneLoopStart(
pLevel->op = OP_Next;
}
pLevel->p1 = iIdxCur;
+ if( pLevel->plan.wsFlags & WHERE_COVER_SCAN ){
+ pLevel->p5 = SQLITE_STMTSTATUS_FULLSCAN_STEP;
+ }else{
+ assert( pLevel->p5==0 );
+ }
}else
#ifndef SQLITE_OMIT_OR_OPTIMIZATION
@@ -102429,6 +107593,8 @@ static Bitmask codeOneLoopStart(
*/
WhereClause *pOrWc; /* The OR-clause broken out into subterms */
SrcList *pOrTab; /* Shortened table list or OR-clause generation */
+ Index *pCov = 0; /* Potential covering index (or NULL) */
+ int iCovCur = pParse->nTab++; /* Cursor used for index scans (if any) */
int regReturn = ++pParse->nMem; /* Register used with OP_Gosub */
int regRowset = 0; /* Register for RowSet object */
@@ -102436,17 +107602,18 @@ static Bitmask codeOneLoopStart(
int iLoopBody = sqlite3VdbeMakeLabel(v); /* Start of loop body */
int iRetInit; /* Address of regReturn init */
int untestedTerms = 0; /* Some terms not completely tested */
- int ii;
+ int ii; /* Loop counter */
+ Expr *pAndExpr = 0; /* An ".. AND (...)" expression */
pTerm = pLevel->plan.u.pTerm;
assert( pTerm!=0 );
- assert( pTerm->eOperator==WO_OR );
+ assert( pTerm->eOperator & WO_OR );
assert( (pTerm->wtFlags & TERM_ORINFO)!=0 );
pOrWc = &pTerm->u.pOrInfo->wc;
pLevel->op = OP_Return;
pLevel->p1 = regReturn;
- /* Set up a new SrcList ni pOrTab containing the table being scanned
+ /* Set up a new SrcList in pOrTab containing the table being scanned
** by this loop in the a[0] slot and all notReady tables in a[1..] slots.
** This becomes the SrcList in the recursive call to sqlite3WhereBegin().
*/
@@ -102486,15 +107653,47 @@ static Bitmask codeOneLoopStart(
}
iRetInit = sqlite3VdbeAddOp2(v, OP_Integer, 0, regReturn);
+ /* If the original WHERE clause is z of the form: (x1 OR x2 OR ...) AND y
+ ** Then for every term xN, evaluate as the subexpression: xN AND z
+ ** That way, terms in y that are factored into the disjunction will
+ ** be picked up by the recursive calls to sqlite3WhereBegin() below.
+ **
+ ** Actually, each subexpression is converted to "xN AND w" where w is
+ ** the "interesting" terms of z - terms that did not originate in the
+ ** ON or USING clause of a LEFT JOIN, and terms that are usable as
+ ** indices.
+ */
+ if( pWC->nTerm>1 ){
+ int iTerm;
+ for(iTerm=0; iTerm<pWC->nTerm; iTerm++){
+ Expr *pExpr = pWC->a[iTerm].pExpr;
+ if( ExprHasProperty(pExpr, EP_FromJoin) ) continue;
+ if( pWC->a[iTerm].wtFlags & (TERM_VIRTUAL|TERM_ORINFO) ) continue;
+ if( (pWC->a[iTerm].eOperator & WO_ALL)==0 ) continue;
+ pExpr = sqlite3ExprDup(pParse->db, pExpr, 0);
+ pAndExpr = sqlite3ExprAnd(pParse->db, pAndExpr, pExpr);
+ }
+ if( pAndExpr ){
+ pAndExpr = sqlite3PExpr(pParse, TK_AND, 0, pAndExpr, 0);
+ }
+ }
+
for(ii=0; ii<pOrWc->nTerm; ii++){
WhereTerm *pOrTerm = &pOrWc->a[ii];
- if( pOrTerm->leftCursor==iCur || pOrTerm->eOperator==WO_AND ){
+ if( pOrTerm->leftCursor==iCur || (pOrTerm->eOperator & WO_AND)!=0 ){
WhereInfo *pSubWInfo; /* Info for single OR-term scan */
+ Expr *pOrExpr = pOrTerm->pExpr;
+ if( pAndExpr ){
+ pAndExpr->pLeft = pOrExpr;
+ pOrExpr = pAndExpr;
+ }
/* Loop through table entries that match term pOrTerm. */
- pSubWInfo = sqlite3WhereBegin(pParse, pOrTab, pOrTerm->pExpr, 0,
- WHERE_OMIT_OPEN | WHERE_OMIT_CLOSE |
- WHERE_FORCE_TABLE | WHERE_ONETABLE_ONLY);
+ pSubWInfo = sqlite3WhereBegin(pParse, pOrTab, pOrExpr, 0, 0,
+ WHERE_OMIT_OPEN_CLOSE | WHERE_AND_ONLY |
+ WHERE_FORCE_TABLE | WHERE_ONETABLE_ONLY, iCovCur);
+ assert( pSubWInfo || pParse->nErr || pParse->db->mallocFailed );
if( pSubWInfo ){
+ WhereLevel *pLvl;
explainOneScan(
pParse, pOrTab, &pSubWInfo->a[0], iLevel, pLevel->iFrom, 0
);
@@ -102502,7 +107701,7 @@ static Bitmask codeOneLoopStart(
int iSet = ((ii==pOrWc->nTerm-1)?-1:ii);
int r;
r = sqlite3ExprCodeGetColumn(pParse, pTabItem->pTab, -1, iCur,
- regRowid);
+ regRowid, 0);
sqlite3VdbeAddOp4Int(v, OP_RowSetTest, regRowset,
sqlite3VdbeCurrentAddr(v)+2, r, iSet);
}
@@ -102515,11 +107714,40 @@ static Bitmask codeOneLoopStart(
*/
if( pSubWInfo->untestedTerms ) untestedTerms = 1;
+ /* If all of the OR-connected terms are optimized using the same
+ ** index, and the index is opened using the same cursor number
+ ** by each call to sqlite3WhereBegin() made by this loop, it may
+ ** be possible to use that index as a covering index.
+ **
+ ** If the call to sqlite3WhereBegin() above resulted in a scan that
+ ** uses an index, and this is either the first OR-connected term
+ ** processed or the index is the same as that used by all previous
+ ** terms, set pCov to the candidate covering index. Otherwise, set
+ ** pCov to NULL to indicate that no candidate covering index will
+ ** be available.
+ */
+ pLvl = &pSubWInfo->a[0];
+ if( (pLvl->plan.wsFlags & WHERE_INDEXED)!=0
+ && (pLvl->plan.wsFlags & WHERE_TEMP_INDEX)==0
+ && (ii==0 || pLvl->plan.u.pIdx==pCov)
+ ){
+ assert( pLvl->iIdxCur==iCovCur );
+ pCov = pLvl->plan.u.pIdx;
+ }else{
+ pCov = 0;
+ }
+
/* Finish the loop through table entries that match term pOrTerm. */
sqlite3WhereEnd(pSubWInfo);
}
}
}
+ pLevel->u.pCovidx = pCov;
+ if( pCov ) pLevel->iIdxCur = iCovCur;
+ if( pAndExpr ){
+ pAndExpr->pLeft = 0;
+ sqlite3ExprDelete(pParse->db, pAndExpr);
+ }
sqlite3VdbeChangeP1(v, iRetInit, sqlite3VdbeCurrentAddr(v));
sqlite3VdbeAddOp2(v, OP_Goto, 0, pLevel->addrBrk);
sqlite3VdbeResolveLabel(v, iLoopBody);
@@ -102714,40 +107942,46 @@ static void whereInfoFree(sqlite3 *db, WhereInfo *pWInfo){
**
** ORDER BY CLAUSE PROCESSING
**
-** *ppOrderBy is a pointer to the ORDER BY clause of a SELECT statement,
+** pOrderBy is a pointer to the ORDER BY clause of a SELECT statement,
** if there is one. If there is no ORDER BY clause or if this routine
-** is called from an UPDATE or DELETE statement, then ppOrderBy is NULL.
+** is called from an UPDATE or DELETE statement, then pOrderBy is NULL.
**
** If an index can be used so that the natural output order of the table
** scan is correct for the ORDER BY clause, then that index is used and
-** *ppOrderBy is set to NULL. This is an optimization that prevents an
-** unnecessary sort of the result set if an index appropriate for the
-** ORDER BY clause already exists.
+** the returned WhereInfo.nOBSat field is set to pOrderBy->nExpr. This
+** is an optimization that prevents an unnecessary sort of the result set
+** if an index appropriate for the ORDER BY clause already exists.
**
** If the where clause loops cannot be arranged to provide the correct
-** output order, then the *ppOrderBy is unchanged.
+** output order, then WhereInfo.nOBSat is 0.
*/
SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
Parse *pParse, /* The parser context */
SrcList *pTabList, /* A list of all tables to be scanned */
Expr *pWhere, /* The WHERE clause */
- ExprList **ppOrderBy, /* An ORDER BY clause, or NULL */
- u16 wctrlFlags /* One of the WHERE_* flags defined in sqliteInt.h */
+ ExprList *pOrderBy, /* An ORDER BY clause, or NULL */
+ ExprList *pDistinct, /* The select-list for DISTINCT queries - or NULL */
+ u16 wctrlFlags, /* One of the WHERE_* flags defined in sqliteInt.h */
+ int iIdxCur /* If WHERE_ONETABLE_ONLY is set, index cursor number */
){
- int i; /* Loop counter */
int nByteWInfo; /* Num. bytes allocated for WhereInfo struct */
int nTabList; /* Number of elements in pTabList */
WhereInfo *pWInfo; /* Will become the return value of this function */
Vdbe *v = pParse->pVdbe; /* The virtual database engine */
Bitmask notReady; /* Cursors that are not yet positioned */
+ WhereBestIdx sWBI; /* Best index search context */
WhereMaskSet *pMaskSet; /* The expression mask set */
- WhereClause *pWC; /* Decomposition of the WHERE clause */
- struct SrcList_item *pTabItem; /* A single entry from pTabList */
- WhereLevel *pLevel; /* A single level in the pWInfo list */
- int iFrom; /* First unused FROM clause element */
+ WhereLevel *pLevel; /* A single level in pWInfo->a[] */
+ int iFrom; /* First unused FROM clause element */
int andFlags; /* AND-ed combination of all pWC->a[].wtFlags */
+ int ii; /* Loop counter */
sqlite3 *db; /* Database connection */
+
+ /* Variable initialization */
+ memset(&sWBI, 0, sizeof(sWBI));
+ sWBI.pParse = pParse;
+
/* The number of tables in the FROM clause is limited by the number of
** bits in a Bitmask
*/
@@ -102787,18 +108021,23 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
pWInfo->pParse = pParse;
pWInfo->pTabList = pTabList;
pWInfo->iBreak = sqlite3VdbeMakeLabel(v);
- pWInfo->pWC = pWC = (WhereClause *)&((u8 *)pWInfo)[nByteWInfo];
+ pWInfo->pWC = sWBI.pWC = (WhereClause *)&((u8 *)pWInfo)[nByteWInfo];
pWInfo->wctrlFlags = wctrlFlags;
pWInfo->savedNQueryLoop = pParse->nQueryLoop;
- pMaskSet = (WhereMaskSet*)&pWC[1];
+ pMaskSet = (WhereMaskSet*)&sWBI.pWC[1];
+ sWBI.aLevel = pWInfo->a;
+
+ /* Disable the DISTINCT optimization if SQLITE_DistinctOpt is set via
+ ** sqlite3_test_ctrl(SQLITE_TESTCTRL_OPTIMIZATIONS,...) */
+ if( OptimizationDisabled(db, SQLITE_DistinctOpt) ) pDistinct = 0;
/* Split the WHERE clause into separate subexpressions where each
** subexpression is separated by an AND operator.
*/
initMaskSet(pMaskSet);
- whereClauseInit(pWC, pParse, pMaskSet);
+ whereClauseInit(sWBI.pWC, pParse, pMaskSet, wctrlFlags);
sqlite3ExprCodeConstants(pParse, pWhere);
- whereSplit(pWC, pWhere, TK_AND); /* IMP: R-15842-53296 */
+ whereSplit(sWBI.pWC, pWhere, TK_AND); /* IMP: R-15842-53296 */
/* Special case: a WHERE clause that is constant. Evaluate the
** expression and either jump over all of the code or fall thru.
@@ -102819,30 +108058,19 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
** bitmask for all tables to the left of the join. Knowing the bitmask
** for all tables to the left of a left join is important. Ticket #3015.
**
- ** Configure the WhereClause.vmask variable so that bits that correspond
- ** to virtual table cursors are set. This is used to selectively disable
- ** the OR-to-IN transformation in exprAnalyzeOrTerm(). It is not helpful
- ** with virtual tables.
- **
** Note that bitmasks are created for all pTabList->nSrc tables in
** pTabList, not just the first nTabList tables. nTabList is normally
** equal to pTabList->nSrc but might be shortened to 1 if the
** WHERE_ONETABLE_ONLY flag is set.
*/
- assert( pWC->vmask==0 && pMaskSet->n==0 );
- for(i=0; i<pTabList->nSrc; i++){
- createMask(pMaskSet, pTabList->a[i].iCursor);
-#ifndef SQLITE_OMIT_VIRTUALTABLE
- if( ALWAYS(pTabList->a[i].pTab) && IsVirtual(pTabList->a[i].pTab) ){
- pWC->vmask |= ((Bitmask)1 << i);
- }
-#endif
+ for(ii=0; ii<pTabList->nSrc; ii++){
+ createMask(pMaskSet, pTabList->a[ii].iCursor);
}
#ifndef NDEBUG
{
Bitmask toTheLeft = 0;
- for(i=0; i<pTabList->nSrc; i++){
- Bitmask m = getMask(pMaskSet, pTabList->a[i].iCursor);
+ for(ii=0; ii<pTabList->nSrc; ii++){
+ Bitmask m = getMask(pMaskSet, pTabList->a[ii].iCursor);
assert( (m-1)==toTheLeft );
toTheLeft |= m;
}
@@ -102854,11 +108082,20 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
** want to analyze these virtual terms, so start analyzing at the end
** and work forward so that the added virtual terms are never processed.
*/
- exprAnalyzeAll(pTabList, pWC);
+ exprAnalyzeAll(pTabList, sWBI.pWC);
if( db->mallocFailed ){
goto whereBeginError;
}
+ /* Check if the DISTINCT qualifier, if there is one, is redundant.
+ ** If it is, then set pDistinct to NULL and WhereInfo.eDistinct to
+ ** WHERE_DISTINCT_UNIQUE to tell the caller to ignore the DISTINCT.
+ */
+ if( pDistinct && isDistinctRedundant(pParse, pTabList, sWBI.pWC, pDistinct) ){
+ pDistinct = 0;
+ pWInfo->eDistinct = WHERE_DISTINCT_UNIQUE;
+ }
+
/* Chose the best index to use for each table in the FROM clause.
**
** This loop fills in the following fields:
@@ -102874,22 +108111,26 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
** This loop also figures out the nesting order of tables in the FROM
** clause.
*/
- notReady = ~(Bitmask)0;
+ sWBI.notValid = ~(Bitmask)0;
+ sWBI.pOrderBy = pOrderBy;
+ sWBI.n = nTabList;
+ sWBI.pDistinct = pDistinct;
andFlags = ~0;
WHERETRACE(("*** Optimizer Start ***\n"));
- for(i=iFrom=0, pLevel=pWInfo->a; i<nTabList; i++, pLevel++){
+ for(sWBI.i=iFrom=0, pLevel=pWInfo->a; sWBI.i<nTabList; sWBI.i++, pLevel++){
WhereCost bestPlan; /* Most efficient plan seen so far */
Index *pIdx; /* Index for FROM table at pTabItem */
int j; /* For looping over FROM tables */
int bestJ = -1; /* The value of j */
Bitmask m; /* Bitmask value for j or bestJ */
int isOptimal; /* Iterator for optimal/non-optimal search */
+ int ckOptimal; /* Do the optimal scan check */
int nUnconstrained; /* Number tables without INDEXED BY */
Bitmask notIndexed; /* Mask of tables that cannot use an index */
memset(&bestPlan, 0, sizeof(bestPlan));
bestPlan.rCost = SQLITE_BIG_DBL;
- WHERETRACE(("*** Begin search for loop %d ***\n", i));
+ WHERETRACE(("*** Begin search for loop %d ***\n", sWBI.i));
/* Loop through the remaining entries in the FROM clause to find the
** next nested loop. The loop tests all FROM clause entries
@@ -102905,8 +108146,8 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
** by waiting for other tables to run first. This "optimal" test works
** by first assuming that the FROM clause is on the inner loop and finding
** its query plan, then checking to see if that query plan uses any
- ** other FROM clause terms that are notReady. If no notReady terms are
- ** used then the "optimal" query plan works.
+ ** other FROM clause terms that are sWBI.notValid. If no notValid terms
+ ** are used then the "optimal" query plan works.
**
** Note that the WhereCost.nRow parameter for an optimal scan might
** not be as small as it would be if the table really were the innermost
@@ -102918,10 +108159,8 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
** strategies were found by the first iteration. This second iteration
** is used to search for the lowest cost scan overall.
**
- ** Previous versions of SQLite performed only the second iteration -
- ** the next outermost loop was always that with the lowest overall
- ** cost. However, this meant that SQLite could select the wrong plan
- ** for scripts such as the following:
+ ** Without the optimal scan step (the first iteration) a suboptimal
+ ** plan might be chosen for queries like this:
**
** CREATE TABLE t1(a, b);
** CREATE TABLE t2(c, d);
@@ -102936,57 +108175,89 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
*/
nUnconstrained = 0;
notIndexed = 0;
- for(isOptimal=(iFrom<nTabList-1); isOptimal>=0 && bestJ<0; isOptimal--){
- Bitmask mask; /* Mask of tables not yet ready */
- for(j=iFrom, pTabItem=&pTabList->a[j]; j<nTabList; j++, pTabItem++){
- int doNotReorder; /* True if this table should not be reordered */
- WhereCost sCost; /* Cost information from best[Virtual]Index() */
- ExprList *pOrderBy; /* ORDER BY clause for index to optimize */
-
- doNotReorder = (pTabItem->jointype & (JT_LEFT|JT_CROSS))!=0;
- if( j!=iFrom && doNotReorder ) break;
- m = getMask(pMaskSet, pTabItem->iCursor);
- if( (m & notReady)==0 ){
+
+ /* The optimal scan check only occurs if there are two or more tables
+ ** available to be reordered */
+ if( iFrom==nTabList-1 ){
+ ckOptimal = 0; /* Common case of just one table in the FROM clause */
+ }else{
+ ckOptimal = -1;
+ for(j=iFrom, sWBI.pSrc=&pTabList->a[j]; j<nTabList; j++, sWBI.pSrc++){
+ m = getMask(pMaskSet, sWBI.pSrc->iCursor);
+ if( (m & sWBI.notValid)==0 ){
if( j==iFrom ) iFrom++;
continue;
}
- mask = (isOptimal ? m : notReady);
- pOrderBy = ((i==0 && ppOrderBy )?*ppOrderBy:0);
- if( pTabItem->pIndex==0 ) nUnconstrained++;
+ if( j>iFrom && (sWBI.pSrc->jointype & (JT_LEFT|JT_CROSS))!=0 ) break;
+ if( ++ckOptimal ) break;
+ if( (sWBI.pSrc->jointype & JT_LEFT)!=0 ) break;
+ }
+ }
+ assert( ckOptimal==0 || ckOptimal==1 );
+
+ for(isOptimal=ckOptimal; isOptimal>=0 && bestJ<0; isOptimal--){
+ for(j=iFrom, sWBI.pSrc=&pTabList->a[j]; j<nTabList; j++, sWBI.pSrc++){
+ if( j>iFrom && (sWBI.pSrc->jointype & (JT_LEFT|JT_CROSS))!=0 ){
+ /* This break and one like it in the ckOptimal computation loop
+ ** above prevent table reordering across LEFT and CROSS JOINs.
+ ** The LEFT JOIN case is necessary for correctness. The prohibition
+ ** against reordering across a CROSS JOIN is an SQLite feature that
+ ** allows the developer to control table reordering */
+ break;
+ }
+ m = getMask(pMaskSet, sWBI.pSrc->iCursor);
+ if( (m & sWBI.notValid)==0 ){
+ assert( j>iFrom );
+ continue;
+ }
+ sWBI.notReady = (isOptimal ? m : sWBI.notValid);
+ if( sWBI.pSrc->pIndex==0 ) nUnconstrained++;
- WHERETRACE(("=== trying table %d with isOptimal=%d ===\n",
- j, isOptimal));
- assert( pTabItem->pTab );
+ WHERETRACE((" === trying table %d (%s) with isOptimal=%d ===\n",
+ j, sWBI.pSrc->pTab->zName, isOptimal));
+ assert( sWBI.pSrc->pTab );
#ifndef SQLITE_OMIT_VIRTUALTABLE
- if( IsVirtual(pTabItem->pTab) ){
- sqlite3_index_info **pp = &pWInfo->a[j].pIdxInfo;
- bestVirtualIndex(pParse, pWC, pTabItem, mask, notReady, pOrderBy,
- &sCost, pp);
+ if( IsVirtual(sWBI.pSrc->pTab) ){
+ sWBI.ppIdxInfo = &pWInfo->a[j].pIdxInfo;
+ bestVirtualIndex(&sWBI);
}else
#endif
{
- bestBtreeIndex(pParse, pWC, pTabItem, mask, notReady, pOrderBy,
- &sCost);
+ bestBtreeIndex(&sWBI);
}
- assert( isOptimal || (sCost.used&notReady)==0 );
+ assert( isOptimal || (sWBI.cost.used&sWBI.notValid)==0 );
/* If an INDEXED BY clause is present, then the plan must use that
** index if it uses any index at all */
- assert( pTabItem->pIndex==0
- || (sCost.plan.wsFlags & WHERE_NOT_FULLSCAN)==0
- || sCost.plan.u.pIdx==pTabItem->pIndex );
+ assert( sWBI.pSrc->pIndex==0
+ || (sWBI.cost.plan.wsFlags & WHERE_NOT_FULLSCAN)==0
+ || sWBI.cost.plan.u.pIdx==sWBI.pSrc->pIndex );
- if( isOptimal && (sCost.plan.wsFlags & WHERE_NOT_FULLSCAN)==0 ){
+ if( isOptimal && (sWBI.cost.plan.wsFlags & WHERE_NOT_FULLSCAN)==0 ){
notIndexed |= m;
}
+ if( isOptimal ){
+ pWInfo->a[j].rOptCost = sWBI.cost.rCost;
+ }else if( ckOptimal ){
+ /* If two or more tables have nearly the same outer loop cost, but
+ ** very different inner loop (optimal) cost, we want to choose
+ ** for the outer loop that table which benefits the least from
+ ** being in the inner loop. The following code scales the
+ ** outer loop cost estimate to accomplish that. */
+ WHERETRACE((" scaling cost from %.1f to %.1f\n",
+ sWBI.cost.rCost,
+ sWBI.cost.rCost/pWInfo->a[j].rOptCost));
+ sWBI.cost.rCost /= pWInfo->a[j].rOptCost;
+ }
/* Conditions under which this table becomes the best so far:
**
** (1) The table must not depend on other tables that have not
- ** yet run.
+ ** yet run. (In other words, it must not depend on tables
+ ** in inner loops.)
**
- ** (2) A full-table-scan plan cannot supercede indexed plan unless
- ** the full-table-scan is an "optimal" plan as defined above.
+ ** (2) (This rule was removed on 2012-11-09. The scaling of the
+ ** cost using the optimal scan cost made this rule obsolete.)
**
** (3) All tables have an INDEXED BY clause or this table lacks an
** INDEXED BY clause or this table uses the specific
@@ -102997,46 +108268,61 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
** The NEVER() comes about because rule (2) above prevents
** An indexable full-table-scan from reaching rule (3).
**
- ** (4) The plan cost must be lower than prior plans or else the
- ** cost must be the same and the number of rows must be lower.
+ ** (4) The plan cost must be lower than prior plans, where "cost"
+ ** is defined by the compareCost() function above.
*/
- if( (sCost.used&notReady)==0 /* (1) */
- && (bestJ<0 || (notIndexed&m)!=0 /* (2) */
- || (bestPlan.plan.wsFlags & WHERE_NOT_FULLSCAN)==0
- || (sCost.plan.wsFlags & WHERE_NOT_FULLSCAN)!=0)
- && (nUnconstrained==0 || pTabItem->pIndex==0 /* (3) */
- || NEVER((sCost.plan.wsFlags & WHERE_NOT_FULLSCAN)!=0))
- && (bestJ<0 || sCost.rCost<bestPlan.rCost /* (4) */
- || (sCost.rCost<=bestPlan.rCost
- && sCost.plan.nRow<bestPlan.plan.nRow))
+ if( (sWBI.cost.used&sWBI.notValid)==0 /* (1) */
+ && (nUnconstrained==0 || sWBI.pSrc->pIndex==0 /* (3) */
+ || NEVER((sWBI.cost.plan.wsFlags & WHERE_NOT_FULLSCAN)!=0))
+ && (bestJ<0 || compareCost(&sWBI.cost, &bestPlan)) /* (4) */
){
- WHERETRACE(("=== table %d is best so far"
- " with cost=%g and nRow=%g\n",
- j, sCost.rCost, sCost.plan.nRow));
- bestPlan = sCost;
+ WHERETRACE((" === table %d (%s) is best so far\n"
+ " cost=%.1f, nRow=%.1f, nOBSat=%d, wsFlags=%08x\n",
+ j, sWBI.pSrc->pTab->zName,
+ sWBI.cost.rCost, sWBI.cost.plan.nRow,
+ sWBI.cost.plan.nOBSat, sWBI.cost.plan.wsFlags));
+ bestPlan = sWBI.cost;
bestJ = j;
}
- if( doNotReorder ) break;
+
+ /* In a join like "w JOIN x LEFT JOIN y JOIN z" make sure that
+ ** table y (and not table z) is always the next inner loop inside
+ ** of table x. */
+ if( (sWBI.pSrc->jointype & JT_LEFT)!=0 ) break;
}
}
assert( bestJ>=0 );
- assert( notReady & getMask(pMaskSet, pTabList->a[bestJ].iCursor) );
- WHERETRACE(("*** Optimizer selects table %d for loop %d"
- " with cost=%g and nRow=%g\n",
- bestJ, pLevel-pWInfo->a, bestPlan.rCost, bestPlan.plan.nRow));
- if( (bestPlan.plan.wsFlags & WHERE_ORDERBY)!=0 ){
- *ppOrderBy = 0;
+ assert( sWBI.notValid & getMask(pMaskSet, pTabList->a[bestJ].iCursor) );
+ assert( bestJ==iFrom || (pTabList->a[iFrom].jointype & JT_LEFT)==0 );
+ testcase( bestJ>iFrom && (pTabList->a[iFrom].jointype & JT_CROSS)!=0 );
+ testcase( bestJ>iFrom && bestJ<nTabList-1
+ && (pTabList->a[bestJ+1].jointype & JT_LEFT)!=0 );
+ WHERETRACE(("*** Optimizer selects table %d (%s) for loop %d with:\n"
+ " cost=%.1f, nRow=%.1f, nOBSat=%d, wsFlags=0x%08x\n",
+ bestJ, pTabList->a[bestJ].pTab->zName,
+ pLevel-pWInfo->a, bestPlan.rCost, bestPlan.plan.nRow,
+ bestPlan.plan.nOBSat, bestPlan.plan.wsFlags));
+ if( (bestPlan.plan.wsFlags & WHERE_DISTINCT)!=0 ){
+ assert( pWInfo->eDistinct==0 );
+ pWInfo->eDistinct = WHERE_DISTINCT_ORDERED;
}
andFlags &= bestPlan.plan.wsFlags;
pLevel->plan = bestPlan.plan;
+ pLevel->iTabCur = pTabList->a[bestJ].iCursor;
testcase( bestPlan.plan.wsFlags & WHERE_INDEXED );
testcase( bestPlan.plan.wsFlags & WHERE_TEMP_INDEX );
if( bestPlan.plan.wsFlags & (WHERE_INDEXED|WHERE_TEMP_INDEX) ){
- pLevel->iIdxCur = pParse->nTab++;
+ if( (wctrlFlags & WHERE_ONETABLE_ONLY)
+ && (bestPlan.plan.wsFlags & WHERE_TEMP_INDEX)==0
+ ){
+ pLevel->iIdxCur = iIdxCur;
+ }else{
+ pLevel->iIdxCur = pParse->nTab++;
+ }
}else{
pLevel->iIdxCur = -1;
}
- notReady &= ~getMask(pMaskSet, pTabList->a[bestJ].iCursor);
+ sWBI.notValid &= ~getMask(pMaskSet, pTabList->a[bestJ].iCursor);
pLevel->iFrom = (u8)bestJ;
if( bestPlan.plan.nRow>=(double)1 ){
pParse->nQueryLoop *= bestPlan.plan.nRow;
@@ -103064,12 +108350,19 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
if( pParse->nErr || db->mallocFailed ){
goto whereBeginError;
}
+ if( nTabList ){
+ pLevel--;
+ pWInfo->nOBSat = pLevel->plan.nOBSat;
+ }else{
+ pWInfo->nOBSat = 0;
+ }
/* If the total query only selects a single row, then the ORDER BY
** clause is irrelevant.
*/
- if( (andFlags & WHERE_UNIQUE)!=0 && ppOrderBy ){
- *ppOrderBy = 0;
+ if( (andFlags & WHERE_UNIQUE)!=0 && pOrderBy ){
+ assert( nTabList==0 || (pLevel->plan.wsFlags & WHERE_ALL_UNIQUE)!=0 );
+ pWInfo->nOBSat = pOrderBy->nExpr;
}
/* If the caller is an UPDATE or DELETE statement that is requesting
@@ -103089,13 +108382,13 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
sqlite3CodeVerifySchema(pParse, -1); /* Insert the cookie verifier Goto */
notReady = ~(Bitmask)0;
pWInfo->nRowOut = (double)1;
- for(i=0, pLevel=pWInfo->a; i<nTabList; i++, pLevel++){
+ for(ii=0, pLevel=pWInfo->a; ii<nTabList; ii++, pLevel++){
Table *pTab; /* Table to open */
int iDb; /* Index of database containing table/index */
+ struct SrcList_item *pTabItem;
pTabItem = &pTabList->a[pLevel->iFrom];
pTab = pTabItem->pTab;
- pLevel->iTabCur = pTabItem->iCursor;
pWInfo->nRowOut *= pLevel->plan.nRow;
iDb = sqlite3SchemaToIndex(db, pTab->pSchema);
if( (pTab->tabFlags & TF_Ephemeral)!=0 || pTab->pSelect ){
@@ -103106,10 +108399,12 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
const char *pVTab = (const char *)sqlite3GetVTable(db, pTab);
int iCur = pTabItem->iCursor;
sqlite3VdbeAddOp4(v, OP_VOpen, iCur, 0, 0, pVTab, P4_VTAB);
+ }else if( IsVirtual(pTab) ){
+ /* noop */
}else
#endif
if( (pLevel->plan.wsFlags & WHERE_IDX_ONLY)==0
- && (wctrlFlags & WHERE_OMIT_OPEN)==0 ){
+ && (wctrlFlags & WHERE_OMIT_OPEN_CLOSE)==0 ){
int op = pWInfo->okOnePass ? OP_OpenWrite : OP_OpenRead;
sqlite3OpenTable(pParse, pTabItem->iCursor, iDb, pTab, op);
testcase( pTab->nCol==BMS-1 );
@@ -103127,21 +108422,21 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
}
#ifndef SQLITE_OMIT_AUTOMATIC_INDEX
if( (pLevel->plan.wsFlags & WHERE_TEMP_INDEX)!=0 ){
- constructAutomaticIndex(pParse, pWC, pTabItem, notReady, pLevel);
+ constructAutomaticIndex(pParse, sWBI.pWC, pTabItem, notReady, pLevel);
}else
#endif
if( (pLevel->plan.wsFlags & WHERE_INDEXED)!=0 ){
Index *pIx = pLevel->plan.u.pIdx;
KeyInfo *pKey = sqlite3IndexKeyinfo(pParse, pIx);
- int iIdxCur = pLevel->iIdxCur;
+ int iIndexCur = pLevel->iIdxCur;
assert( pIx->pSchema==pTab->pSchema );
- assert( iIdxCur>=0 );
- sqlite3VdbeAddOp4(v, OP_OpenRead, iIdxCur, pIx->tnum, iDb,
+ assert( iIndexCur>=0 );
+ sqlite3VdbeAddOp4(v, OP_OpenRead, iIndexCur, pIx->tnum, iDb,
(char*)pKey, P4_KEYINFO_HANDOFF);
VdbeComment((v, "%s", pIx->zName));
}
sqlite3CodeVerifySchema(pParse, iDb);
- notReady &= ~getMask(pWC->pMaskSet, pTabItem->iCursor);
+ notReady &= ~getMask(sWBI.pWC->pMaskSet, pTabItem->iCursor);
}
pWInfo->iTop = sqlite3VdbeCurrentAddr(v);
if( db->mallocFailed ) goto whereBeginError;
@@ -103151,10 +108446,10 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
** program.
*/
notReady = ~(Bitmask)0;
- for(i=0; i<nTabList; i++){
- pLevel = &pWInfo->a[i];
- explainOneScan(pParse, pTabList, pLevel, i, pLevel->iFrom, wctrlFlags);
- notReady = codeOneLoopStart(pWInfo, i, wctrlFlags, notReady);
+ for(ii=0; ii<nTabList; ii++){
+ pLevel = &pWInfo->a[ii];
+ explainOneScan(pParse, pTabList, pLevel, ii, pLevel->iFrom, wctrlFlags);
+ notReady = codeOneLoopStart(pWInfo, ii, wctrlFlags, notReady);
pWInfo->iContinue = pLevel->addrCont;
}
@@ -103165,16 +108460,20 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
** the index is listed as "{}". If the primary key is used the
** index name is '*'.
*/
- for(i=0; i<nTabList; i++){
+ for(ii=0; ii<nTabList; ii++){
char *z;
int n;
- pLevel = &pWInfo->a[i];
+ int w;
+ struct SrcList_item *pTabItem;
+
+ pLevel = &pWInfo->a[ii];
+ w = pLevel->plan.wsFlags;
pTabItem = &pTabList->a[pLevel->iFrom];
z = pTabItem->zAlias;
if( z==0 ) z = pTabItem->pTab->zName;
n = sqlite3Strlen30(z);
if( n+nQPlan < sizeof(sqlite3_query_plan)-10 ){
- if( pLevel->plan.wsFlags & WHERE_IDX_ONLY ){
+ if( (w & WHERE_IDX_ONLY)!=0 && (w & WHERE_COVER_SCAN)==0 ){
memcpy(&sqlite3_query_plan[nQPlan], "{}", 2);
nQPlan += 2;
}else{
@@ -103183,12 +108482,12 @@ SQLITE_PRIVATE WhereInfo *sqlite3WhereBegin(
}
sqlite3_query_plan[nQPlan++] = ' ';
}
- testcase( pLevel->plan.wsFlags & WHERE_ROWID_EQ );
- testcase( pLevel->plan.wsFlags & WHERE_ROWID_RANGE );
- if( pLevel->plan.wsFlags & (WHERE_ROWID_EQ|WHERE_ROWID_RANGE) ){
+ testcase( w & WHERE_ROWID_EQ );
+ testcase( w & WHERE_ROWID_RANGE );
+ if( w & (WHERE_ROWID_EQ|WHERE_ROWID_RANGE) ){
memcpy(&sqlite3_query_plan[nQPlan], "* ", 2);
nQPlan += 2;
- }else if( (pLevel->plan.wsFlags & WHERE_INDEXED)!=0 ){
+ }else if( (w & WHERE_INDEXED)!=0 && (w & WHERE_COVER_SCAN)==0 ){
n = sqlite3Strlen30(pLevel->plan.u.pIdx->zName);
if( n+nQPlan < sizeof(sqlite3_query_plan)-2 ){
memcpy(&sqlite3_query_plan[nQPlan], pLevel->plan.u.pIdx->zName, n);
@@ -103249,7 +108548,7 @@ SQLITE_PRIVATE void sqlite3WhereEnd(WhereInfo *pWInfo){
sqlite3VdbeResolveLabel(v, pLevel->addrNxt);
for(j=pLevel->u.in.nIn, pIn=&pLevel->u.in.aInLoop[j-1]; j>0; j--, pIn--){
sqlite3VdbeJumpHere(v, pIn->addrInTop+1);
- sqlite3VdbeAddOp2(v, OP_Next, pIn->iCur, pIn->addrInTop);
+ sqlite3VdbeAddOp2(v, pIn->eEndLoopOp, pIn->iCur, pIn->addrInTop);
sqlite3VdbeJumpHere(v, pIn->addrInTop-1);
}
sqlite3DbFree(db, pLevel->u.in.aInLoop);
@@ -103284,12 +108583,13 @@ SQLITE_PRIVATE void sqlite3WhereEnd(WhereInfo *pWInfo){
*/
assert( pWInfo->nLevel==1 || pWInfo->nLevel==pTabList->nSrc );
for(i=0, pLevel=pWInfo->a; i<pWInfo->nLevel; i++, pLevel++){
+ Index *pIdx = 0;
struct SrcList_item *pTabItem = &pTabList->a[pLevel->iFrom];
Table *pTab = pTabItem->pTab;
assert( pTab!=0 );
if( (pTab->tabFlags & TF_Ephemeral)==0
&& pTab->pSelect==0
- && (pWInfo->wctrlFlags & WHERE_OMIT_CLOSE)==0
+ && (pWInfo->wctrlFlags & WHERE_OMIT_OPEN_CLOSE)==0
){
int ws = pLevel->plan.wsFlags;
if( !pWInfo->okOnePass && (ws & WHERE_IDX_ONLY)==0 ){
@@ -103313,12 +108613,15 @@ SQLITE_PRIVATE void sqlite3WhereEnd(WhereInfo *pWInfo){
** that reference the table and converts them into opcodes that
** reference the index.
*/
- if( (pLevel->plan.wsFlags & WHERE_INDEXED)!=0 && !db->mallocFailed){
+ if( pLevel->plan.wsFlags & WHERE_INDEXED ){
+ pIdx = pLevel->plan.u.pIdx;
+ }else if( pLevel->plan.wsFlags & WHERE_MULTI_OR ){
+ pIdx = pLevel->u.pCovidx;
+ }
+ if( pIdx && !db->mallocFailed){
int k, j, last;
VdbeOp *pOp;
- Index *pIdx = pLevel->plan.u.pIdx;
- assert( pIdx!=0 );
pOp = sqlite3VdbeGetOp(v, pWInfo->iTop);
last = sqlite3VdbeCurrentAddr(v);
for(k=pWInfo->iTop; k<last; k++, pOp++){
@@ -103361,6 +108664,7 @@ SQLITE_PRIVATE void sqlite3WhereEnd(WhereInfo *pWInfo){
*/
/* First off, code is included that follows the "include" declaration
** in the input grammar file. */
+/* #include <stdio.h> */
/*
@@ -103389,7 +108693,7 @@ struct LimitVal {
*/
struct LikeOp {
Token eOperator; /* "like" or "glob" or "regexp" */
- int not; /* True if the NOT keyword is present */
+ int bNot; /* True if the NOT keyword is present */
};
/*
@@ -103408,6 +108712,14 @@ struct TrigEvent { int a; IdList * b; };
*/
struct AttachKey { int type; Token key; };
+/*
+** One or more VALUES claues
+*/
+struct ValueList {
+ ExprList *pList;
+ Select *pSelect;
+};
+
/* This is a utility routine used to set the ExprSpan.zStart and
** ExprSpan.zEnd values of pOut so that the span covers the complete
@@ -103531,26 +108843,28 @@ struct AttachKey { int type; Token key; };
** defined, then do no error processing.
*/
#define YYCODETYPE unsigned char
-#define YYNOCODE 253
+#define YYNOCODE 251
#define YYACTIONTYPE unsigned short int
#define YYWILDCARD 67
#define sqlite3ParserTOKENTYPE Token
typedef union {
int yyinit;
sqlite3ParserTOKENTYPE yy0;
- int yy4;
- struct TrigEvent yy90;
- ExprSpan yy118;
- TriggerStep* yy203;
- u8 yy210;
- struct {int value; int mask;} yy215;
- SrcList* yy259;
- struct LimitVal yy292;
- Expr* yy314;
- ExprList* yy322;
- struct LikeOp yy342;
- IdList* yy384;
- Select* yy387;
+ struct LimitVal yy64;
+ Expr* yy122;
+ Select* yy159;
+ IdList* yy180;
+ struct {int value; int mask;} yy207;
+ u8 yy258;
+ u16 yy305;
+ struct LikeOp yy318;
+ TriggerStep* yy327;
+ ExprSpan yy342;
+ SrcList* yy347;
+ int yy392;
+ struct TrigEvent yy410;
+ ExprList* yy442;
+ struct ValueList yy487;
} YYMINORTYPE;
#ifndef YYSTACKDEPTH
#define YYSTACKDEPTH 100
@@ -103559,8 +108873,8 @@ typedef union {
#define sqlite3ParserARG_PDECL ,Parse *pParse
#define sqlite3ParserARG_FETCH Parse *pParse = yypParser->pParse
#define sqlite3ParserARG_STORE yypParser->pParse = pParse
-#define YYNSTATE 630
-#define YYNRULE 329
+#define YYNSTATE 627
+#define YYNRULE 327
#define YYFALLBACK 1
#define YY_NO_ACTION (YYNSTATE+YYNRULE+2)
#define YY_ACCEPT_ACTION (YYNSTATE+YYNRULE+1)
@@ -103630,473 +108944,474 @@ static const YYMINORTYPE yyzerominor = { 0 };
** shifting non-terminals after a reduce.
** yy_default[] Default action for each state.
*/
-#define YY_ACTTAB_COUNT (1557)
+#define YY_ACTTAB_COUNT (1564)
static const YYACTIONTYPE yy_action[] = {
- /* 0 */ 313, 960, 186, 419, 2, 172, 627, 597, 55, 55,
- /* 10 */ 55, 55, 48, 53, 53, 53, 53, 52, 52, 51,
- /* 20 */ 51, 51, 50, 238, 302, 283, 623, 622, 516, 515,
- /* 30 */ 590, 584, 55, 55, 55, 55, 282, 53, 53, 53,
- /* 40 */ 53, 52, 52, 51, 51, 51, 50, 238, 6, 56,
- /* 50 */ 57, 47, 582, 581, 583, 583, 54, 54, 55, 55,
- /* 60 */ 55, 55, 608, 53, 53, 53, 53, 52, 52, 51,
- /* 70 */ 51, 51, 50, 238, 313, 597, 409, 330, 579, 579,
- /* 80 */ 32, 53, 53, 53, 53, 52, 52, 51, 51, 51,
- /* 90 */ 50, 238, 330, 217, 620, 619, 166, 411, 624, 382,
- /* 100 */ 379, 378, 7, 491, 590, 584, 200, 199, 198, 58,
- /* 110 */ 377, 300, 414, 621, 481, 66, 623, 622, 621, 580,
- /* 120 */ 254, 601, 94, 56, 57, 47, 582, 581, 583, 583,
- /* 130 */ 54, 54, 55, 55, 55, 55, 671, 53, 53, 53,
- /* 140 */ 53, 52, 52, 51, 51, 51, 50, 238, 313, 532,
- /* 150 */ 226, 506, 507, 133, 177, 139, 284, 385, 279, 384,
- /* 160 */ 169, 197, 342, 398, 251, 226, 253, 275, 388, 167,
- /* 170 */ 139, 284, 385, 279, 384, 169, 570, 236, 590, 584,
- /* 180 */ 672, 240, 275, 157, 620, 619, 554, 437, 51, 51,
- /* 190 */ 51, 50, 238, 343, 439, 553, 438, 56, 57, 47,
- /* 200 */ 582, 581, 583, 583, 54, 54, 55, 55, 55, 55,
- /* 210 */ 465, 53, 53, 53, 53, 52, 52, 51, 51, 51,
- /* 220 */ 50, 238, 313, 390, 52, 52, 51, 51, 51, 50,
- /* 230 */ 238, 391, 166, 491, 566, 382, 379, 378, 409, 440,
- /* 240 */ 579, 579, 252, 440, 607, 66, 377, 513, 621, 49,
- /* 250 */ 46, 147, 590, 584, 621, 16, 466, 189, 621, 441,
- /* 260 */ 442, 673, 526, 441, 340, 577, 595, 64, 194, 482,
- /* 270 */ 434, 56, 57, 47, 582, 581, 583, 583, 54, 54,
- /* 280 */ 55, 55, 55, 55, 30, 53, 53, 53, 53, 52,
- /* 290 */ 52, 51, 51, 51, 50, 238, 313, 593, 593, 593,
- /* 300 */ 387, 578, 606, 493, 259, 351, 258, 411, 1, 623,
- /* 310 */ 622, 496, 623, 622, 65, 240, 623, 622, 597, 443,
- /* 320 */ 237, 239, 414, 341, 237, 602, 590, 584, 18, 603,
- /* 330 */ 166, 601, 87, 382, 379, 378, 67, 623, 622, 38,
- /* 340 */ 623, 622, 176, 270, 377, 56, 57, 47, 582, 581,
- /* 350 */ 583, 583, 54, 54, 55, 55, 55, 55, 175, 53,
- /* 360 */ 53, 53, 53, 52, 52, 51, 51, 51, 50, 238,
- /* 370 */ 313, 396, 233, 411, 531, 565, 317, 620, 619, 44,
- /* 380 */ 620, 619, 240, 206, 620, 619, 597, 266, 414, 268,
- /* 390 */ 409, 597, 579, 579, 352, 184, 505, 601, 73, 533,
- /* 400 */ 590, 584, 466, 548, 190, 620, 619, 576, 620, 619,
- /* 410 */ 547, 383, 551, 35, 332, 575, 574, 600, 504, 56,
- /* 420 */ 57, 47, 582, 581, 583, 583, 54, 54, 55, 55,
- /* 430 */ 55, 55, 567, 53, 53, 53, 53, 52, 52, 51,
- /* 440 */ 51, 51, 50, 238, 313, 411, 561, 561, 528, 364,
- /* 450 */ 259, 351, 258, 183, 361, 549, 524, 374, 411, 597,
- /* 460 */ 414, 240, 560, 560, 409, 604, 579, 579, 328, 601,
- /* 470 */ 93, 623, 622, 414, 590, 584, 237, 564, 559, 559,
- /* 480 */ 520, 402, 601, 87, 409, 210, 579, 579, 168, 421,
- /* 490 */ 950, 519, 950, 56, 57, 47, 582, 581, 583, 583,
- /* 500 */ 54, 54, 55, 55, 55, 55, 192, 53, 53, 53,
- /* 510 */ 53, 52, 52, 51, 51, 51, 50, 238, 313, 600,
- /* 520 */ 293, 563, 511, 234, 357, 146, 475, 475, 367, 411,
- /* 530 */ 562, 411, 358, 542, 425, 171, 411, 215, 144, 620,
- /* 540 */ 619, 544, 318, 353, 414, 203, 414, 275, 590, 584,
- /* 550 */ 549, 414, 174, 601, 94, 601, 79, 558, 471, 61,
- /* 560 */ 601, 79, 421, 949, 350, 949, 34, 56, 57, 47,
- /* 570 */ 582, 581, 583, 583, 54, 54, 55, 55, 55, 55,
- /* 580 */ 535, 53, 53, 53, 53, 52, 52, 51, 51, 51,
- /* 590 */ 50, 238, 313, 307, 424, 394, 272, 49, 46, 147,
- /* 600 */ 349, 322, 4, 411, 491, 312, 321, 425, 568, 492,
- /* 610 */ 216, 264, 407, 575, 574, 429, 66, 549, 414, 621,
- /* 620 */ 540, 602, 590, 584, 13, 603, 621, 601, 72, 12,
- /* 630 */ 618, 617, 616, 202, 210, 621, 546, 469, 422, 319,
- /* 640 */ 148, 56, 57, 47, 582, 581, 583, 583, 54, 54,
- /* 650 */ 55, 55, 55, 55, 338, 53, 53, 53, 53, 52,
- /* 660 */ 52, 51, 51, 51, 50, 238, 313, 600, 600, 411,
- /* 670 */ 39, 21, 37, 170, 237, 875, 411, 572, 572, 201,
- /* 680 */ 144, 473, 538, 331, 414, 474, 143, 146, 630, 628,
- /* 690 */ 334, 414, 353, 601, 68, 168, 590, 584, 132, 365,
- /* 700 */ 601, 96, 307, 423, 530, 336, 49, 46, 147, 568,
- /* 710 */ 406, 216, 549, 360, 529, 56, 57, 47, 582, 581,
- /* 720 */ 583, 583, 54, 54, 55, 55, 55, 55, 411, 53,
- /* 730 */ 53, 53, 53, 52, 52, 51, 51, 51, 50, 238,
- /* 740 */ 313, 411, 605, 414, 484, 510, 172, 422, 597, 318,
- /* 750 */ 496, 485, 601, 99, 411, 142, 414, 411, 231, 411,
- /* 760 */ 540, 411, 359, 629, 2, 601, 97, 426, 308, 414,
- /* 770 */ 590, 584, 414, 20, 414, 621, 414, 621, 601, 106,
- /* 780 */ 503, 601, 105, 601, 108, 601, 109, 204, 28, 56,
- /* 790 */ 57, 47, 582, 581, 583, 583, 54, 54, 55, 55,
- /* 800 */ 55, 55, 411, 53, 53, 53, 53, 52, 52, 51,
- /* 810 */ 51, 51, 50, 238, 313, 411, 597, 414, 411, 276,
- /* 820 */ 214, 600, 411, 366, 213, 381, 601, 134, 274, 500,
- /* 830 */ 414, 167, 130, 414, 621, 411, 354, 414, 376, 601,
- /* 840 */ 135, 129, 601, 100, 590, 584, 601, 104, 522, 521,
- /* 850 */ 414, 621, 224, 273, 600, 167, 327, 282, 600, 601,
- /* 860 */ 103, 468, 521, 56, 57, 47, 582, 581, 583, 583,
- /* 870 */ 54, 54, 55, 55, 55, 55, 411, 53, 53, 53,
- /* 880 */ 53, 52, 52, 51, 51, 51, 50, 238, 313, 411,
- /* 890 */ 27, 414, 411, 375, 276, 167, 359, 544, 50, 238,
- /* 900 */ 601, 95, 128, 223, 414, 411, 165, 414, 411, 621,
- /* 910 */ 411, 621, 612, 601, 102, 372, 601, 76, 590, 584,
- /* 920 */ 414, 570, 236, 414, 470, 414, 167, 621, 188, 601,
- /* 930 */ 98, 225, 601, 138, 601, 137, 232, 56, 45, 47,
- /* 940 */ 582, 581, 583, 583, 54, 54, 55, 55, 55, 55,
- /* 950 */ 411, 53, 53, 53, 53, 52, 52, 51, 51, 51,
- /* 960 */ 50, 238, 313, 276, 276, 414, 411, 276, 544, 459,
- /* 970 */ 359, 171, 209, 479, 601, 136, 628, 334, 621, 621,
- /* 980 */ 125, 414, 621, 368, 411, 621, 257, 540, 589, 588,
- /* 990 */ 601, 75, 590, 584, 458, 446, 23, 23, 124, 414,
- /* 1000 */ 326, 325, 621, 427, 324, 309, 600, 288, 601, 92,
- /* 1010 */ 586, 585, 57, 47, 582, 581, 583, 583, 54, 54,
- /* 1020 */ 55, 55, 55, 55, 411, 53, 53, 53, 53, 52,
- /* 1030 */ 52, 51, 51, 51, 50, 238, 313, 587, 411, 414,
- /* 1040 */ 411, 207, 611, 476, 171, 472, 160, 123, 601, 91,
- /* 1050 */ 323, 261, 15, 414, 464, 414, 411, 621, 411, 354,
- /* 1060 */ 222, 411, 601, 74, 601, 90, 590, 584, 159, 264,
- /* 1070 */ 158, 414, 461, 414, 621, 600, 414, 121, 120, 25,
- /* 1080 */ 601, 89, 601, 101, 621, 601, 88, 47, 582, 581,
- /* 1090 */ 583, 583, 54, 54, 55, 55, 55, 55, 544, 53,
- /* 1100 */ 53, 53, 53, 52, 52, 51, 51, 51, 50, 238,
- /* 1110 */ 43, 405, 263, 3, 610, 264, 140, 415, 622, 24,
- /* 1120 */ 410, 11, 456, 594, 118, 155, 219, 452, 408, 621,
- /* 1130 */ 621, 621, 156, 43, 405, 621, 3, 286, 621, 113,
- /* 1140 */ 415, 622, 111, 445, 411, 400, 557, 403, 545, 10,
- /* 1150 */ 411, 408, 264, 110, 205, 436, 541, 566, 453, 414,
- /* 1160 */ 621, 621, 63, 621, 435, 414, 411, 621, 601, 94,
- /* 1170 */ 403, 621, 411, 337, 601, 86, 150, 40, 41, 534,
- /* 1180 */ 566, 414, 242, 264, 42, 413, 412, 414, 600, 595,
- /* 1190 */ 601, 85, 191, 333, 107, 451, 601, 84, 621, 539,
- /* 1200 */ 40, 41, 420, 230, 411, 149, 316, 42, 413, 412,
- /* 1210 */ 398, 127, 595, 315, 621, 399, 278, 625, 181, 414,
- /* 1220 */ 593, 593, 593, 592, 591, 14, 450, 411, 601, 71,
- /* 1230 */ 240, 621, 43, 405, 264, 3, 615, 180, 264, 415,
- /* 1240 */ 622, 614, 414, 593, 593, 593, 592, 591, 14, 621,
- /* 1250 */ 408, 601, 70, 621, 417, 33, 405, 613, 3, 411,
- /* 1260 */ 264, 411, 415, 622, 418, 626, 178, 509, 8, 403,
- /* 1270 */ 241, 416, 126, 408, 414, 621, 414, 449, 208, 566,
- /* 1280 */ 240, 221, 621, 601, 83, 601, 82, 599, 297, 277,
- /* 1290 */ 296, 30, 403, 31, 395, 264, 295, 397, 489, 40,
- /* 1300 */ 41, 411, 566, 220, 621, 294, 42, 413, 412, 271,
- /* 1310 */ 621, 595, 600, 621, 59, 60, 414, 269, 267, 623,
- /* 1320 */ 622, 36, 40, 41, 621, 601, 81, 598, 235, 42,
- /* 1330 */ 413, 412, 621, 621, 595, 265, 344, 411, 248, 556,
- /* 1340 */ 173, 185, 593, 593, 593, 592, 591, 14, 218, 29,
- /* 1350 */ 621, 543, 414, 305, 304, 303, 179, 301, 411, 566,
- /* 1360 */ 454, 601, 80, 289, 335, 593, 593, 593, 592, 591,
- /* 1370 */ 14, 411, 287, 414, 151, 392, 246, 260, 411, 196,
- /* 1380 */ 195, 523, 601, 69, 411, 245, 414, 526, 537, 285,
- /* 1390 */ 389, 595, 621, 414, 536, 601, 17, 362, 153, 414,
- /* 1400 */ 466, 463, 601, 78, 154, 414, 462, 152, 601, 77,
- /* 1410 */ 355, 255, 621, 455, 601, 9, 621, 386, 444, 517,
- /* 1420 */ 247, 621, 593, 593, 593, 621, 621, 244, 621, 243,
- /* 1430 */ 430, 518, 292, 621, 329, 621, 145, 393, 280, 513,
- /* 1440 */ 291, 131, 621, 514, 621, 621, 311, 621, 259, 346,
- /* 1450 */ 249, 621, 621, 229, 314, 621, 228, 512, 227, 240,
- /* 1460 */ 494, 488, 310, 164, 487, 486, 373, 480, 163, 262,
- /* 1470 */ 369, 371, 162, 26, 212, 478, 477, 161, 141, 363,
- /* 1480 */ 467, 122, 339, 187, 119, 348, 347, 117, 116, 115,
- /* 1490 */ 114, 112, 182, 457, 320, 22, 433, 432, 448, 19,
- /* 1500 */ 609, 431, 428, 62, 193, 596, 573, 298, 555, 552,
- /* 1510 */ 571, 404, 290, 380, 498, 510, 495, 306, 281, 499,
- /* 1520 */ 250, 5, 497, 460, 345, 447, 569, 550, 238, 299,
- /* 1530 */ 527, 525, 508, 961, 502, 501, 961, 401, 961, 211,
- /* 1540 */ 490, 356, 256, 961, 483, 961, 961, 961, 961, 961,
- /* 1550 */ 961, 961, 961, 961, 961, 961, 370,
+ /* 0 */ 309, 955, 184, 417, 2, 171, 624, 594, 56, 56,
+ /* 10 */ 56, 56, 49, 54, 54, 54, 54, 53, 53, 52,
+ /* 20 */ 52, 52, 51, 233, 620, 619, 298, 620, 619, 234,
+ /* 30 */ 587, 581, 56, 56, 56, 56, 19, 54, 54, 54,
+ /* 40 */ 54, 53, 53, 52, 52, 52, 51, 233, 605, 57,
+ /* 50 */ 58, 48, 579, 578, 580, 580, 55, 55, 56, 56,
+ /* 60 */ 56, 56, 541, 54, 54, 54, 54, 53, 53, 52,
+ /* 70 */ 52, 52, 51, 233, 309, 594, 325, 196, 195, 194,
+ /* 80 */ 33, 54, 54, 54, 54, 53, 53, 52, 52, 52,
+ /* 90 */ 51, 233, 617, 616, 165, 617, 616, 380, 377, 376,
+ /* 100 */ 407, 532, 576, 576, 587, 581, 303, 422, 375, 59,
+ /* 110 */ 53, 53, 52, 52, 52, 51, 233, 50, 47, 146,
+ /* 120 */ 574, 545, 65, 57, 58, 48, 579, 578, 580, 580,
+ /* 130 */ 55, 55, 56, 56, 56, 56, 213, 54, 54, 54,
+ /* 140 */ 54, 53, 53, 52, 52, 52, 51, 233, 309, 223,
+ /* 150 */ 539, 420, 170, 176, 138, 280, 383, 275, 382, 168,
+ /* 160 */ 489, 551, 409, 668, 620, 619, 271, 438, 409, 438,
+ /* 170 */ 550, 604, 67, 482, 507, 618, 599, 412, 587, 581,
+ /* 180 */ 600, 483, 618, 412, 618, 598, 91, 439, 440, 439,
+ /* 190 */ 335, 598, 73, 669, 222, 266, 480, 57, 58, 48,
+ /* 200 */ 579, 578, 580, 580, 55, 55, 56, 56, 56, 56,
+ /* 210 */ 670, 54, 54, 54, 54, 53, 53, 52, 52, 52,
+ /* 220 */ 51, 233, 309, 279, 232, 231, 1, 132, 200, 385,
+ /* 230 */ 620, 619, 617, 616, 278, 435, 289, 563, 175, 262,
+ /* 240 */ 409, 264, 437, 497, 436, 166, 441, 568, 336, 568,
+ /* 250 */ 201, 537, 587, 581, 599, 412, 165, 594, 600, 380,
+ /* 260 */ 377, 376, 597, 598, 92, 523, 618, 569, 569, 592,
+ /* 270 */ 375, 57, 58, 48, 579, 578, 580, 580, 55, 55,
+ /* 280 */ 56, 56, 56, 56, 597, 54, 54, 54, 54, 53,
+ /* 290 */ 53, 52, 52, 52, 51, 233, 309, 463, 617, 616,
+ /* 300 */ 590, 590, 590, 174, 272, 396, 409, 272, 409, 548,
+ /* 310 */ 397, 620, 619, 68, 326, 620, 619, 620, 619, 618,
+ /* 320 */ 546, 412, 618, 412, 471, 594, 587, 581, 472, 598,
+ /* 330 */ 92, 598, 92, 52, 52, 52, 51, 233, 513, 512,
+ /* 340 */ 206, 322, 363, 464, 221, 57, 58, 48, 579, 578,
+ /* 350 */ 580, 580, 55, 55, 56, 56, 56, 56, 529, 54,
+ /* 360 */ 54, 54, 54, 53, 53, 52, 52, 52, 51, 233,
+ /* 370 */ 309, 396, 409, 396, 597, 372, 386, 530, 347, 617,
+ /* 380 */ 616, 575, 202, 617, 616, 617, 616, 412, 620, 619,
+ /* 390 */ 145, 255, 346, 254, 577, 598, 74, 351, 45, 489,
+ /* 400 */ 587, 581, 235, 189, 464, 544, 167, 296, 187, 469,
+ /* 410 */ 479, 67, 62, 39, 618, 546, 597, 345, 573, 57,
+ /* 420 */ 58, 48, 579, 578, 580, 580, 55, 55, 56, 56,
+ /* 430 */ 56, 56, 6, 54, 54, 54, 54, 53, 53, 52,
+ /* 440 */ 52, 52, 51, 233, 309, 562, 558, 407, 528, 576,
+ /* 450 */ 576, 344, 255, 346, 254, 182, 617, 616, 503, 504,
+ /* 460 */ 314, 409, 557, 235, 166, 271, 409, 352, 564, 181,
+ /* 470 */ 407, 546, 576, 576, 587, 581, 412, 537, 556, 561,
+ /* 480 */ 517, 412, 618, 249, 598, 16, 7, 36, 467, 598,
+ /* 490 */ 92, 516, 618, 57, 58, 48, 579, 578, 580, 580,
+ /* 500 */ 55, 55, 56, 56, 56, 56, 541, 54, 54, 54,
+ /* 510 */ 54, 53, 53, 52, 52, 52, 51, 233, 309, 327,
+ /* 520 */ 572, 571, 525, 558, 560, 394, 871, 246, 409, 248,
+ /* 530 */ 171, 392, 594, 219, 407, 409, 576, 576, 502, 557,
+ /* 540 */ 364, 145, 510, 412, 407, 229, 576, 576, 587, 581,
+ /* 550 */ 412, 598, 92, 381, 269, 556, 166, 400, 598, 69,
+ /* 560 */ 501, 419, 945, 199, 945, 198, 546, 57, 58, 48,
+ /* 570 */ 579, 578, 580, 580, 55, 55, 56, 56, 56, 56,
+ /* 580 */ 568, 54, 54, 54, 54, 53, 53, 52, 52, 52,
+ /* 590 */ 51, 233, 309, 317, 419, 944, 508, 944, 308, 597,
+ /* 600 */ 594, 565, 490, 212, 173, 247, 423, 615, 614, 613,
+ /* 610 */ 323, 197, 143, 405, 572, 571, 489, 66, 50, 47,
+ /* 620 */ 146, 594, 587, 581, 232, 231, 559, 427, 67, 555,
+ /* 630 */ 15, 618, 186, 543, 303, 421, 35, 206, 432, 423,
+ /* 640 */ 552, 57, 58, 48, 579, 578, 580, 580, 55, 55,
+ /* 650 */ 56, 56, 56, 56, 205, 54, 54, 54, 54, 53,
+ /* 660 */ 53, 52, 52, 52, 51, 233, 309, 569, 569, 260,
+ /* 670 */ 268, 597, 12, 373, 568, 166, 409, 313, 409, 420,
+ /* 680 */ 409, 473, 473, 365, 618, 50, 47, 146, 597, 594,
+ /* 690 */ 468, 412, 166, 412, 351, 412, 587, 581, 32, 598,
+ /* 700 */ 94, 598, 97, 598, 95, 627, 625, 329, 142, 50,
+ /* 710 */ 47, 146, 333, 349, 358, 57, 58, 48, 579, 578,
+ /* 720 */ 580, 580, 55, 55, 56, 56, 56, 56, 409, 54,
+ /* 730 */ 54, 54, 54, 53, 53, 52, 52, 52, 51, 233,
+ /* 740 */ 309, 409, 388, 412, 409, 22, 565, 404, 212, 362,
+ /* 750 */ 389, 598, 104, 359, 409, 156, 412, 409, 603, 412,
+ /* 760 */ 537, 331, 569, 569, 598, 103, 493, 598, 105, 412,
+ /* 770 */ 587, 581, 412, 260, 549, 618, 11, 598, 106, 521,
+ /* 780 */ 598, 133, 169, 457, 456, 170, 35, 601, 618, 57,
+ /* 790 */ 58, 48, 579, 578, 580, 580, 55, 55, 56, 56,
+ /* 800 */ 56, 56, 409, 54, 54, 54, 54, 53, 53, 52,
+ /* 810 */ 52, 52, 51, 233, 309, 409, 259, 412, 409, 50,
+ /* 820 */ 47, 146, 357, 318, 355, 598, 134, 527, 352, 337,
+ /* 830 */ 412, 409, 356, 412, 357, 409, 357, 618, 598, 98,
+ /* 840 */ 129, 598, 102, 618, 587, 581, 412, 21, 235, 618,
+ /* 850 */ 412, 618, 211, 143, 598, 101, 30, 167, 598, 93,
+ /* 860 */ 350, 535, 203, 57, 58, 48, 579, 578, 580, 580,
+ /* 870 */ 55, 55, 56, 56, 56, 56, 409, 54, 54, 54,
+ /* 880 */ 54, 53, 53, 52, 52, 52, 51, 233, 309, 409,
+ /* 890 */ 526, 412, 409, 425, 215, 305, 597, 551, 141, 598,
+ /* 900 */ 100, 40, 409, 38, 412, 409, 550, 412, 409, 228,
+ /* 910 */ 220, 314, 598, 77, 500, 598, 96, 412, 587, 581,
+ /* 920 */ 412, 338, 253, 412, 218, 598, 137, 379, 598, 136,
+ /* 930 */ 28, 598, 135, 270, 715, 210, 481, 57, 58, 48,
+ /* 940 */ 579, 578, 580, 580, 55, 55, 56, 56, 56, 56,
+ /* 950 */ 409, 54, 54, 54, 54, 53, 53, 52, 52, 52,
+ /* 960 */ 51, 233, 309, 409, 272, 412, 409, 315, 147, 597,
+ /* 970 */ 272, 626, 2, 598, 76, 209, 409, 127, 412, 618,
+ /* 980 */ 126, 412, 409, 621, 235, 618, 598, 90, 374, 598,
+ /* 990 */ 89, 412, 587, 581, 27, 260, 350, 412, 618, 598,
+ /* 1000 */ 75, 321, 541, 541, 125, 598, 88, 320, 278, 597,
+ /* 1010 */ 618, 57, 46, 48, 579, 578, 580, 580, 55, 55,
+ /* 1020 */ 56, 56, 56, 56, 409, 54, 54, 54, 54, 53,
+ /* 1030 */ 53, 52, 52, 52, 51, 233, 309, 409, 450, 412,
+ /* 1040 */ 164, 284, 282, 272, 609, 424, 304, 598, 87, 370,
+ /* 1050 */ 409, 477, 412, 409, 608, 409, 607, 602, 618, 618,
+ /* 1060 */ 598, 99, 586, 585, 122, 412, 587, 581, 412, 618,
+ /* 1070 */ 412, 618, 618, 598, 86, 366, 598, 17, 598, 85,
+ /* 1080 */ 319, 185, 519, 518, 583, 582, 58, 48, 579, 578,
+ /* 1090 */ 580, 580, 55, 55, 56, 56, 56, 56, 409, 54,
+ /* 1100 */ 54, 54, 54, 53, 53, 52, 52, 52, 51, 233,
+ /* 1110 */ 309, 584, 409, 412, 409, 260, 260, 260, 408, 591,
+ /* 1120 */ 474, 598, 84, 170, 409, 466, 518, 412, 121, 412,
+ /* 1130 */ 618, 618, 618, 618, 618, 598, 83, 598, 72, 412,
+ /* 1140 */ 587, 581, 51, 233, 625, 329, 470, 598, 71, 257,
+ /* 1150 */ 159, 120, 14, 462, 157, 158, 117, 260, 448, 447,
+ /* 1160 */ 446, 48, 579, 578, 580, 580, 55, 55, 56, 56,
+ /* 1170 */ 56, 56, 618, 54, 54, 54, 54, 53, 53, 52,
+ /* 1180 */ 52, 52, 51, 233, 44, 403, 260, 3, 409, 459,
+ /* 1190 */ 260, 413, 619, 118, 398, 10, 25, 24, 554, 348,
+ /* 1200 */ 217, 618, 406, 412, 409, 618, 4, 44, 403, 618,
+ /* 1210 */ 3, 598, 82, 618, 413, 619, 455, 542, 115, 412,
+ /* 1220 */ 538, 401, 536, 274, 506, 406, 251, 598, 81, 216,
+ /* 1230 */ 273, 563, 618, 243, 453, 618, 154, 618, 618, 618,
+ /* 1240 */ 449, 416, 623, 110, 401, 618, 409, 236, 64, 123,
+ /* 1250 */ 487, 41, 42, 531, 563, 204, 409, 267, 43, 411,
+ /* 1260 */ 410, 412, 265, 592, 108, 618, 107, 434, 332, 598,
+ /* 1270 */ 80, 412, 618, 263, 41, 42, 443, 618, 409, 598,
+ /* 1280 */ 70, 43, 411, 410, 433, 261, 592, 149, 618, 597,
+ /* 1290 */ 256, 237, 188, 412, 590, 590, 590, 589, 588, 13,
+ /* 1300 */ 618, 598, 18, 328, 235, 618, 44, 403, 360, 3,
+ /* 1310 */ 418, 461, 339, 413, 619, 227, 124, 590, 590, 590,
+ /* 1320 */ 589, 588, 13, 618, 406, 409, 618, 409, 139, 34,
+ /* 1330 */ 403, 387, 3, 148, 622, 312, 413, 619, 311, 330,
+ /* 1340 */ 412, 460, 412, 401, 180, 353, 412, 406, 598, 79,
+ /* 1350 */ 598, 78, 250, 563, 598, 9, 618, 612, 611, 610,
+ /* 1360 */ 618, 8, 452, 442, 242, 415, 401, 618, 239, 235,
+ /* 1370 */ 179, 238, 428, 41, 42, 288, 563, 618, 618, 618,
+ /* 1380 */ 43, 411, 410, 618, 144, 592, 618, 618, 177, 61,
+ /* 1390 */ 618, 596, 391, 620, 619, 287, 41, 42, 414, 618,
+ /* 1400 */ 293, 30, 393, 43, 411, 410, 292, 618, 592, 31,
+ /* 1410 */ 618, 395, 291, 60, 230, 37, 590, 590, 590, 589,
+ /* 1420 */ 588, 13, 214, 553, 183, 290, 172, 301, 300, 299,
+ /* 1430 */ 178, 297, 595, 563, 451, 29, 285, 390, 540, 590,
+ /* 1440 */ 590, 590, 589, 588, 13, 283, 520, 534, 150, 533,
+ /* 1450 */ 241, 281, 384, 192, 191, 324, 515, 514, 276, 240,
+ /* 1460 */ 510, 523, 307, 511, 128, 592, 509, 225, 226, 486,
+ /* 1470 */ 485, 224, 152, 491, 464, 306, 484, 163, 153, 371,
+ /* 1480 */ 478, 151, 162, 258, 369, 161, 367, 208, 475, 476,
+ /* 1490 */ 26, 160, 465, 140, 361, 131, 590, 590, 590, 116,
+ /* 1500 */ 119, 454, 343, 155, 114, 342, 113, 112, 445, 111,
+ /* 1510 */ 130, 109, 431, 316, 426, 430, 23, 429, 20, 606,
+ /* 1520 */ 190, 507, 255, 341, 244, 63, 294, 593, 310, 570,
+ /* 1530 */ 277, 402, 354, 235, 567, 496, 495, 492, 494, 302,
+ /* 1540 */ 458, 378, 286, 245, 566, 5, 252, 547, 193, 444,
+ /* 1550 */ 233, 340, 207, 524, 368, 505, 334, 522, 499, 399,
+ /* 1560 */ 295, 498, 956, 488,
};
static const YYCODETYPE yy_lookahead[] = {
/* 0 */ 19, 142, 143, 144, 145, 24, 1, 26, 77, 78,
/* 10 */ 79, 80, 81, 82, 83, 84, 85, 86, 87, 88,
- /* 20 */ 89, 90, 91, 92, 15, 98, 26, 27, 7, 8,
- /* 30 */ 49, 50, 77, 78, 79, 80, 109, 82, 83, 84,
- /* 40 */ 85, 86, 87, 88, 89, 90, 91, 92, 22, 68,
+ /* 20 */ 89, 90, 91, 92, 26, 27, 15, 26, 27, 197,
+ /* 30 */ 49, 50, 77, 78, 79, 80, 204, 82, 83, 84,
+ /* 40 */ 85, 86, 87, 88, 89, 90, 91, 92, 23, 68,
/* 50 */ 69, 70, 71, 72, 73, 74, 75, 76, 77, 78,
- /* 60 */ 79, 80, 23, 82, 83, 84, 85, 86, 87, 88,
- /* 70 */ 89, 90, 91, 92, 19, 94, 112, 19, 114, 115,
+ /* 60 */ 79, 80, 166, 82, 83, 84, 85, 86, 87, 88,
+ /* 70 */ 89, 90, 91, 92, 19, 94, 19, 105, 106, 107,
/* 80 */ 25, 82, 83, 84, 85, 86, 87, 88, 89, 90,
- /* 90 */ 91, 92, 19, 22, 94, 95, 96, 150, 150, 99,
- /* 100 */ 100, 101, 76, 150, 49, 50, 105, 106, 107, 54,
- /* 110 */ 110, 158, 165, 165, 161, 162, 26, 27, 165, 113,
- /* 120 */ 16, 174, 175, 68, 69, 70, 71, 72, 73, 74,
- /* 130 */ 75, 76, 77, 78, 79, 80, 118, 82, 83, 84,
- /* 140 */ 85, 86, 87, 88, 89, 90, 91, 92, 19, 23,
- /* 150 */ 92, 97, 98, 24, 96, 97, 98, 99, 100, 101,
- /* 160 */ 102, 25, 97, 216, 60, 92, 62, 109, 221, 25,
- /* 170 */ 97, 98, 99, 100, 101, 102, 86, 87, 49, 50,
- /* 180 */ 118, 116, 109, 25, 94, 95, 32, 97, 88, 89,
- /* 190 */ 90, 91, 92, 128, 104, 41, 106, 68, 69, 70,
+ /* 90 */ 91, 92, 94, 95, 96, 94, 95, 99, 100, 101,
+ /* 100 */ 112, 205, 114, 115, 49, 50, 22, 23, 110, 54,
+ /* 110 */ 86, 87, 88, 89, 90, 91, 92, 221, 222, 223,
+ /* 120 */ 23, 120, 25, 68, 69, 70, 71, 72, 73, 74,
+ /* 130 */ 75, 76, 77, 78, 79, 80, 22, 82, 83, 84,
+ /* 140 */ 85, 86, 87, 88, 89, 90, 91, 92, 19, 92,
+ /* 150 */ 23, 67, 25, 96, 97, 98, 99, 100, 101, 102,
+ /* 160 */ 150, 32, 150, 118, 26, 27, 109, 150, 150, 150,
+ /* 170 */ 41, 161, 162, 180, 181, 165, 113, 165, 49, 50,
+ /* 180 */ 117, 188, 165, 165, 165, 173, 174, 170, 171, 170,
+ /* 190 */ 171, 173, 174, 118, 184, 16, 186, 68, 69, 70,
/* 200 */ 71, 72, 73, 74, 75, 76, 77, 78, 79, 80,
- /* 210 */ 11, 82, 83, 84, 85, 86, 87, 88, 89, 90,
- /* 220 */ 91, 92, 19, 19, 86, 87, 88, 89, 90, 91,
- /* 230 */ 92, 27, 96, 150, 66, 99, 100, 101, 112, 150,
- /* 240 */ 114, 115, 138, 150, 161, 162, 110, 103, 165, 222,
- /* 250 */ 223, 224, 49, 50, 165, 22, 57, 24, 165, 170,
- /* 260 */ 171, 118, 94, 170, 171, 23, 98, 25, 185, 186,
- /* 270 */ 243, 68, 69, 70, 71, 72, 73, 74, 75, 76,
- /* 280 */ 77, 78, 79, 80, 126, 82, 83, 84, 85, 86,
- /* 290 */ 87, 88, 89, 90, 91, 92, 19, 129, 130, 131,
- /* 300 */ 88, 23, 172, 173, 105, 106, 107, 150, 22, 26,
- /* 310 */ 27, 181, 26, 27, 22, 116, 26, 27, 26, 230,
- /* 320 */ 231, 197, 165, 230, 231, 113, 49, 50, 204, 117,
- /* 330 */ 96, 174, 175, 99, 100, 101, 22, 26, 27, 136,
- /* 340 */ 26, 27, 118, 16, 110, 68, 69, 70, 71, 72,
- /* 350 */ 73, 74, 75, 76, 77, 78, 79, 80, 118, 82,
+ /* 210 */ 118, 82, 83, 84, 85, 86, 87, 88, 89, 90,
+ /* 220 */ 91, 92, 19, 98, 86, 87, 22, 24, 160, 88,
+ /* 230 */ 26, 27, 94, 95, 109, 97, 224, 66, 118, 60,
+ /* 240 */ 150, 62, 104, 23, 106, 25, 229, 230, 229, 230,
+ /* 250 */ 160, 150, 49, 50, 113, 165, 96, 26, 117, 99,
+ /* 260 */ 100, 101, 194, 173, 174, 94, 165, 129, 130, 98,
+ /* 270 */ 110, 68, 69, 70, 71, 72, 73, 74, 75, 76,
+ /* 280 */ 77, 78, 79, 80, 194, 82, 83, 84, 85, 86,
+ /* 290 */ 87, 88, 89, 90, 91, 92, 19, 11, 94, 95,
+ /* 300 */ 129, 130, 131, 118, 150, 215, 150, 150, 150, 25,
+ /* 310 */ 220, 26, 27, 22, 213, 26, 27, 26, 27, 165,
+ /* 320 */ 25, 165, 165, 165, 30, 94, 49, 50, 34, 173,
+ /* 330 */ 174, 173, 174, 88, 89, 90, 91, 92, 7, 8,
+ /* 340 */ 160, 187, 48, 57, 187, 68, 69, 70, 71, 72,
+ /* 350 */ 73, 74, 75, 76, 77, 78, 79, 80, 23, 82,
/* 360 */ 83, 84, 85, 86, 87, 88, 89, 90, 91, 92,
- /* 370 */ 19, 214, 215, 150, 23, 23, 155, 94, 95, 22,
- /* 380 */ 94, 95, 116, 160, 94, 95, 94, 60, 165, 62,
- /* 390 */ 112, 26, 114, 115, 128, 23, 36, 174, 175, 88,
- /* 400 */ 49, 50, 57, 120, 22, 94, 95, 23, 94, 95,
- /* 410 */ 120, 51, 25, 136, 169, 170, 171, 194, 58, 68,
+ /* 370 */ 19, 215, 150, 215, 194, 19, 220, 88, 220, 94,
+ /* 380 */ 95, 23, 160, 94, 95, 94, 95, 165, 26, 27,
+ /* 390 */ 95, 105, 106, 107, 113, 173, 174, 217, 22, 150,
+ /* 400 */ 49, 50, 116, 119, 57, 120, 50, 158, 22, 21,
+ /* 410 */ 161, 162, 232, 136, 165, 120, 194, 237, 23, 68,
/* 420 */ 69, 70, 71, 72, 73, 74, 75, 76, 77, 78,
- /* 430 */ 79, 80, 23, 82, 83, 84, 85, 86, 87, 88,
- /* 440 */ 89, 90, 91, 92, 19, 150, 12, 12, 23, 228,
- /* 450 */ 105, 106, 107, 23, 233, 25, 165, 19, 150, 94,
- /* 460 */ 165, 116, 28, 28, 112, 174, 114, 115, 108, 174,
- /* 470 */ 175, 26, 27, 165, 49, 50, 231, 11, 44, 44,
- /* 480 */ 46, 46, 174, 175, 112, 160, 114, 115, 50, 22,
- /* 490 */ 23, 57, 25, 68, 69, 70, 71, 72, 73, 74,
- /* 500 */ 75, 76, 77, 78, 79, 80, 119, 82, 83, 84,
- /* 510 */ 85, 86, 87, 88, 89, 90, 91, 92, 19, 194,
- /* 520 */ 225, 23, 23, 215, 19, 95, 105, 106, 107, 150,
- /* 530 */ 23, 150, 27, 23, 67, 25, 150, 206, 207, 94,
- /* 540 */ 95, 166, 104, 218, 165, 22, 165, 109, 49, 50,
- /* 550 */ 120, 165, 25, 174, 175, 174, 175, 23, 21, 234,
- /* 560 */ 174, 175, 22, 23, 239, 25, 25, 68, 69, 70,
+ /* 430 */ 79, 80, 22, 82, 83, 84, 85, 86, 87, 88,
+ /* 440 */ 89, 90, 91, 92, 19, 23, 12, 112, 23, 114,
+ /* 450 */ 115, 63, 105, 106, 107, 23, 94, 95, 97, 98,
+ /* 460 */ 104, 150, 28, 116, 25, 109, 150, 150, 23, 23,
+ /* 470 */ 112, 25, 114, 115, 49, 50, 165, 150, 44, 11,
+ /* 480 */ 46, 165, 165, 16, 173, 174, 76, 136, 100, 173,
+ /* 490 */ 174, 57, 165, 68, 69, 70, 71, 72, 73, 74,
+ /* 500 */ 75, 76, 77, 78, 79, 80, 166, 82, 83, 84,
+ /* 510 */ 85, 86, 87, 88, 89, 90, 91, 92, 19, 169,
+ /* 520 */ 170, 171, 23, 12, 23, 214, 138, 60, 150, 62,
+ /* 530 */ 24, 215, 26, 216, 112, 150, 114, 115, 36, 28,
+ /* 540 */ 213, 95, 103, 165, 112, 205, 114, 115, 49, 50,
+ /* 550 */ 165, 173, 174, 51, 23, 44, 25, 46, 173, 174,
+ /* 560 */ 58, 22, 23, 22, 25, 160, 120, 68, 69, 70,
/* 570 */ 71, 72, 73, 74, 75, 76, 77, 78, 79, 80,
- /* 580 */ 205, 82, 83, 84, 85, 86, 87, 88, 89, 90,
- /* 590 */ 91, 92, 19, 22, 23, 216, 23, 222, 223, 224,
- /* 600 */ 63, 220, 35, 150, 150, 163, 220, 67, 166, 167,
- /* 610 */ 168, 150, 169, 170, 171, 161, 162, 25, 165, 165,
- /* 620 */ 150, 113, 49, 50, 25, 117, 165, 174, 175, 35,
- /* 630 */ 7, 8, 9, 160, 160, 165, 120, 100, 67, 247,
- /* 640 */ 248, 68, 69, 70, 71, 72, 73, 74, 75, 76,
- /* 650 */ 77, 78, 79, 80, 193, 82, 83, 84, 85, 86,
- /* 660 */ 87, 88, 89, 90, 91, 92, 19, 194, 194, 150,
- /* 670 */ 135, 24, 137, 35, 231, 138, 150, 129, 130, 206,
- /* 680 */ 207, 30, 27, 213, 165, 34, 118, 95, 0, 1,
- /* 690 */ 2, 165, 218, 174, 175, 50, 49, 50, 22, 48,
- /* 700 */ 174, 175, 22, 23, 23, 244, 222, 223, 224, 166,
- /* 710 */ 167, 168, 120, 239, 23, 68, 69, 70, 71, 72,
+ /* 580 */ 230, 82, 83, 84, 85, 86, 87, 88, 89, 90,
+ /* 590 */ 91, 92, 19, 215, 22, 23, 23, 25, 163, 194,
+ /* 600 */ 94, 166, 167, 168, 25, 138, 67, 7, 8, 9,
+ /* 610 */ 108, 206, 207, 169, 170, 171, 150, 22, 221, 222,
+ /* 620 */ 223, 26, 49, 50, 86, 87, 23, 161, 162, 23,
+ /* 630 */ 22, 165, 24, 120, 22, 23, 25, 160, 241, 67,
+ /* 640 */ 176, 68, 69, 70, 71, 72, 73, 74, 75, 76,
+ /* 650 */ 77, 78, 79, 80, 160, 82, 83, 84, 85, 86,
+ /* 660 */ 87, 88, 89, 90, 91, 92, 19, 129, 130, 150,
+ /* 670 */ 23, 194, 35, 23, 230, 25, 150, 155, 150, 67,
+ /* 680 */ 150, 105, 106, 107, 165, 221, 222, 223, 194, 94,
+ /* 690 */ 23, 165, 25, 165, 217, 165, 49, 50, 25, 173,
+ /* 700 */ 174, 173, 174, 173, 174, 0, 1, 2, 118, 221,
+ /* 710 */ 222, 223, 193, 219, 237, 68, 69, 70, 71, 72,
/* 720 */ 73, 74, 75, 76, 77, 78, 79, 80, 150, 82,
/* 730 */ 83, 84, 85, 86, 87, 88, 89, 90, 91, 92,
- /* 740 */ 19, 150, 173, 165, 181, 182, 24, 67, 26, 104,
- /* 750 */ 181, 188, 174, 175, 150, 39, 165, 150, 52, 150,
- /* 760 */ 150, 150, 150, 144, 145, 174, 175, 249, 250, 165,
- /* 770 */ 49, 50, 165, 52, 165, 165, 165, 165, 174, 175,
- /* 780 */ 29, 174, 175, 174, 175, 174, 175, 160, 22, 68,
+ /* 740 */ 19, 150, 19, 165, 150, 24, 166, 167, 168, 227,
+ /* 750 */ 27, 173, 174, 231, 150, 25, 165, 150, 172, 165,
+ /* 760 */ 150, 242, 129, 130, 173, 174, 180, 173, 174, 165,
+ /* 770 */ 49, 50, 165, 150, 176, 165, 35, 173, 174, 165,
+ /* 780 */ 173, 174, 35, 23, 23, 25, 25, 173, 165, 68,
/* 790 */ 69, 70, 71, 72, 73, 74, 75, 76, 77, 78,
/* 800 */ 79, 80, 150, 82, 83, 84, 85, 86, 87, 88,
- /* 810 */ 89, 90, 91, 92, 19, 150, 94, 165, 150, 150,
- /* 820 */ 160, 194, 150, 213, 160, 52, 174, 175, 23, 23,
- /* 830 */ 165, 25, 22, 165, 165, 150, 150, 165, 52, 174,
- /* 840 */ 175, 22, 174, 175, 49, 50, 174, 175, 190, 191,
- /* 850 */ 165, 165, 240, 23, 194, 25, 187, 109, 194, 174,
- /* 860 */ 175, 190, 191, 68, 69, 70, 71, 72, 73, 74,
+ /* 810 */ 89, 90, 91, 92, 19, 150, 193, 165, 150, 221,
+ /* 820 */ 222, 223, 150, 213, 19, 173, 174, 23, 150, 97,
+ /* 830 */ 165, 150, 27, 165, 150, 150, 150, 165, 173, 174,
+ /* 840 */ 22, 173, 174, 165, 49, 50, 165, 52, 116, 165,
+ /* 850 */ 165, 165, 206, 207, 173, 174, 126, 50, 173, 174,
+ /* 860 */ 128, 27, 160, 68, 69, 70, 71, 72, 73, 74,
/* 870 */ 75, 76, 77, 78, 79, 80, 150, 82, 83, 84,
/* 880 */ 85, 86, 87, 88, 89, 90, 91, 92, 19, 150,
- /* 890 */ 22, 165, 150, 23, 150, 25, 150, 166, 91, 92,
- /* 900 */ 174, 175, 22, 217, 165, 150, 102, 165, 150, 165,
- /* 910 */ 150, 165, 150, 174, 175, 19, 174, 175, 49, 50,
- /* 920 */ 165, 86, 87, 165, 23, 165, 25, 165, 24, 174,
- /* 930 */ 175, 187, 174, 175, 174, 175, 205, 68, 69, 70,
+ /* 890 */ 23, 165, 150, 23, 216, 25, 194, 32, 39, 173,
+ /* 900 */ 174, 135, 150, 137, 165, 150, 41, 165, 150, 52,
+ /* 910 */ 238, 104, 173, 174, 29, 173, 174, 165, 49, 50,
+ /* 920 */ 165, 219, 238, 165, 238, 173, 174, 52, 173, 174,
+ /* 930 */ 22, 173, 174, 23, 23, 160, 25, 68, 69, 70,
/* 940 */ 71, 72, 73, 74, 75, 76, 77, 78, 79, 80,
/* 950 */ 150, 82, 83, 84, 85, 86, 87, 88, 89, 90,
- /* 960 */ 91, 92, 19, 150, 150, 165, 150, 150, 166, 23,
- /* 970 */ 150, 25, 160, 20, 174, 175, 1, 2, 165, 165,
- /* 980 */ 104, 165, 165, 43, 150, 165, 240, 150, 49, 50,
- /* 990 */ 174, 175, 49, 50, 23, 23, 25, 25, 53, 165,
- /* 1000 */ 187, 187, 165, 23, 187, 25, 194, 205, 174, 175,
- /* 1010 */ 71, 72, 69, 70, 71, 72, 73, 74, 75, 76,
+ /* 960 */ 91, 92, 19, 150, 150, 165, 150, 245, 246, 194,
+ /* 970 */ 150, 144, 145, 173, 174, 160, 150, 22, 165, 165,
+ /* 980 */ 22, 165, 150, 150, 116, 165, 173, 174, 52, 173,
+ /* 990 */ 174, 165, 49, 50, 22, 150, 128, 165, 165, 173,
+ /* 1000 */ 174, 187, 166, 166, 22, 173, 174, 187, 109, 194,
+ /* 1010 */ 165, 68, 69, 70, 71, 72, 73, 74, 75, 76,
/* 1020 */ 77, 78, 79, 80, 150, 82, 83, 84, 85, 86,
- /* 1030 */ 87, 88, 89, 90, 91, 92, 19, 98, 150, 165,
- /* 1040 */ 150, 160, 150, 59, 25, 53, 104, 22, 174, 175,
- /* 1050 */ 213, 138, 5, 165, 1, 165, 150, 165, 150, 150,
- /* 1060 */ 240, 150, 174, 175, 174, 175, 49, 50, 118, 150,
- /* 1070 */ 35, 165, 27, 165, 165, 194, 165, 108, 127, 76,
- /* 1080 */ 174, 175, 174, 175, 165, 174, 175, 70, 71, 72,
- /* 1090 */ 73, 74, 75, 76, 77, 78, 79, 80, 166, 82,
+ /* 1030 */ 87, 88, 89, 90, 91, 92, 19, 150, 193, 165,
+ /* 1040 */ 102, 205, 205, 150, 150, 247, 248, 173, 174, 19,
+ /* 1050 */ 150, 20, 165, 150, 150, 150, 150, 150, 165, 165,
+ /* 1060 */ 173, 174, 49, 50, 104, 165, 49, 50, 165, 165,
+ /* 1070 */ 165, 165, 165, 173, 174, 43, 173, 174, 173, 174,
+ /* 1080 */ 187, 24, 190, 191, 71, 72, 69, 70, 71, 72,
+ /* 1090 */ 73, 74, 75, 76, 77, 78, 79, 80, 150, 82,
/* 1100 */ 83, 84, 85, 86, 87, 88, 89, 90, 91, 92,
- /* 1110 */ 19, 20, 193, 22, 150, 150, 150, 26, 27, 76,
- /* 1120 */ 150, 22, 1, 150, 119, 121, 217, 20, 37, 165,
- /* 1130 */ 165, 165, 16, 19, 20, 165, 22, 205, 165, 119,
- /* 1140 */ 26, 27, 108, 128, 150, 150, 150, 56, 150, 22,
- /* 1150 */ 150, 37, 150, 127, 160, 23, 150, 66, 193, 165,
- /* 1160 */ 165, 165, 16, 165, 23, 165, 150, 165, 174, 175,
- /* 1170 */ 56, 165, 150, 65, 174, 175, 15, 86, 87, 88,
- /* 1180 */ 66, 165, 140, 150, 93, 94, 95, 165, 194, 98,
- /* 1190 */ 174, 175, 22, 3, 164, 193, 174, 175, 165, 150,
- /* 1200 */ 86, 87, 4, 180, 150, 248, 251, 93, 94, 95,
- /* 1210 */ 216, 180, 98, 251, 165, 221, 150, 149, 6, 165,
- /* 1220 */ 129, 130, 131, 132, 133, 134, 193, 150, 174, 175,
- /* 1230 */ 116, 165, 19, 20, 150, 22, 149, 151, 150, 26,
- /* 1240 */ 27, 149, 165, 129, 130, 131, 132, 133, 134, 165,
- /* 1250 */ 37, 174, 175, 165, 149, 19, 20, 13, 22, 150,
- /* 1260 */ 150, 150, 26, 27, 146, 147, 151, 150, 25, 56,
- /* 1270 */ 152, 159, 154, 37, 165, 165, 165, 193, 160, 66,
- /* 1280 */ 116, 193, 165, 174, 175, 174, 175, 194, 199, 150,
- /* 1290 */ 200, 126, 56, 124, 123, 150, 201, 122, 150, 86,
- /* 1300 */ 87, 150, 66, 193, 165, 202, 93, 94, 95, 150,
- /* 1310 */ 165, 98, 194, 165, 125, 22, 165, 150, 150, 26,
- /* 1320 */ 27, 135, 86, 87, 165, 174, 175, 203, 226, 93,
- /* 1330 */ 94, 95, 165, 165, 98, 150, 218, 150, 193, 157,
- /* 1340 */ 118, 157, 129, 130, 131, 132, 133, 134, 5, 104,
- /* 1350 */ 165, 211, 165, 10, 11, 12, 13, 14, 150, 66,
- /* 1360 */ 17, 174, 175, 210, 246, 129, 130, 131, 132, 133,
- /* 1370 */ 134, 150, 210, 165, 31, 121, 33, 150, 150, 86,
- /* 1380 */ 87, 176, 174, 175, 150, 42, 165, 94, 211, 210,
- /* 1390 */ 150, 98, 165, 165, 211, 174, 175, 150, 55, 165,
- /* 1400 */ 57, 150, 174, 175, 61, 165, 150, 64, 174, 175,
- /* 1410 */ 150, 150, 165, 150, 174, 175, 165, 104, 150, 184,
- /* 1420 */ 150, 165, 129, 130, 131, 165, 165, 150, 165, 150,
- /* 1430 */ 150, 176, 150, 165, 47, 165, 150, 150, 176, 103,
- /* 1440 */ 150, 22, 165, 178, 165, 165, 179, 165, 105, 106,
- /* 1450 */ 107, 165, 165, 229, 111, 165, 92, 176, 229, 116,
- /* 1460 */ 184, 176, 179, 156, 176, 176, 18, 157, 156, 237,
- /* 1470 */ 45, 157, 156, 135, 157, 157, 238, 156, 68, 157,
- /* 1480 */ 189, 189, 139, 219, 22, 157, 18, 192, 192, 192,
- /* 1490 */ 192, 189, 219, 199, 157, 242, 40, 157, 199, 242,
- /* 1500 */ 153, 157, 38, 245, 196, 166, 232, 198, 177, 177,
- /* 1510 */ 232, 227, 209, 178, 166, 182, 166, 148, 177, 177,
- /* 1520 */ 209, 196, 177, 199, 209, 199, 166, 208, 92, 195,
- /* 1530 */ 174, 174, 183, 252, 183, 183, 252, 191, 252, 235,
- /* 1540 */ 186, 241, 241, 252, 186, 252, 252, 252, 252, 252,
- /* 1550 */ 252, 252, 252, 252, 252, 252, 236,
+ /* 1110 */ 19, 98, 150, 165, 150, 150, 150, 150, 150, 150,
+ /* 1120 */ 59, 173, 174, 25, 150, 190, 191, 165, 53, 165,
+ /* 1130 */ 165, 165, 165, 165, 165, 173, 174, 173, 174, 165,
+ /* 1140 */ 49, 50, 91, 92, 1, 2, 53, 173, 174, 138,
+ /* 1150 */ 104, 22, 5, 1, 35, 118, 127, 150, 193, 193,
+ /* 1160 */ 193, 70, 71, 72, 73, 74, 75, 76, 77, 78,
+ /* 1170 */ 79, 80, 165, 82, 83, 84, 85, 86, 87, 88,
+ /* 1180 */ 89, 90, 91, 92, 19, 20, 150, 22, 150, 27,
+ /* 1190 */ 150, 26, 27, 108, 150, 22, 76, 76, 150, 25,
+ /* 1200 */ 193, 165, 37, 165, 150, 165, 22, 19, 20, 165,
+ /* 1210 */ 22, 173, 174, 165, 26, 27, 23, 150, 119, 165,
+ /* 1220 */ 150, 56, 150, 150, 150, 37, 16, 173, 174, 193,
+ /* 1230 */ 150, 66, 165, 193, 1, 165, 121, 165, 165, 165,
+ /* 1240 */ 20, 146, 147, 119, 56, 165, 150, 152, 16, 154,
+ /* 1250 */ 150, 86, 87, 88, 66, 160, 150, 150, 93, 94,
+ /* 1260 */ 95, 165, 150, 98, 108, 165, 127, 23, 65, 173,
+ /* 1270 */ 174, 165, 165, 150, 86, 87, 128, 165, 150, 173,
+ /* 1280 */ 174, 93, 94, 95, 23, 150, 98, 15, 165, 194,
+ /* 1290 */ 150, 140, 22, 165, 129, 130, 131, 132, 133, 134,
+ /* 1300 */ 165, 173, 174, 3, 116, 165, 19, 20, 150, 22,
+ /* 1310 */ 4, 150, 217, 26, 27, 179, 179, 129, 130, 131,
+ /* 1320 */ 132, 133, 134, 165, 37, 150, 165, 150, 164, 19,
+ /* 1330 */ 20, 150, 22, 246, 149, 249, 26, 27, 249, 244,
+ /* 1340 */ 165, 150, 165, 56, 6, 150, 165, 37, 173, 174,
+ /* 1350 */ 173, 174, 150, 66, 173, 174, 165, 149, 149, 13,
+ /* 1360 */ 165, 25, 150, 150, 150, 149, 56, 165, 150, 116,
+ /* 1370 */ 151, 150, 150, 86, 87, 150, 66, 165, 165, 165,
+ /* 1380 */ 93, 94, 95, 165, 150, 98, 165, 165, 151, 22,
+ /* 1390 */ 165, 194, 150, 26, 27, 150, 86, 87, 159, 165,
+ /* 1400 */ 199, 126, 123, 93, 94, 95, 200, 165, 98, 124,
+ /* 1410 */ 165, 122, 201, 125, 225, 135, 129, 130, 131, 132,
+ /* 1420 */ 133, 134, 5, 157, 157, 202, 118, 10, 11, 12,
+ /* 1430 */ 13, 14, 203, 66, 17, 104, 210, 121, 211, 129,
+ /* 1440 */ 130, 131, 132, 133, 134, 210, 175, 211, 31, 211,
+ /* 1450 */ 33, 210, 104, 86, 87, 47, 175, 183, 175, 42,
+ /* 1460 */ 103, 94, 178, 177, 22, 98, 175, 92, 228, 175,
+ /* 1470 */ 175, 228, 55, 183, 57, 178, 175, 156, 61, 18,
+ /* 1480 */ 157, 64, 156, 235, 157, 156, 45, 157, 236, 157,
+ /* 1490 */ 135, 156, 189, 68, 157, 218, 129, 130, 131, 22,
+ /* 1500 */ 189, 199, 157, 156, 192, 18, 192, 192, 199, 192,
+ /* 1510 */ 218, 189, 40, 157, 38, 157, 240, 157, 240, 153,
+ /* 1520 */ 196, 181, 105, 106, 107, 243, 198, 166, 111, 230,
+ /* 1530 */ 176, 226, 239, 116, 230, 176, 166, 166, 176, 148,
+ /* 1540 */ 199, 177, 209, 209, 166, 196, 239, 208, 185, 199,
+ /* 1550 */ 92, 209, 233, 173, 234, 182, 139, 173, 182, 191,
+ /* 1560 */ 195, 182, 250, 186,
};
-#define YY_SHIFT_USE_DFLT (-74)
-#define YY_SHIFT_COUNT (418)
-#define YY_SHIFT_MIN (-73)
-#define YY_SHIFT_MAX (1468)
+#define YY_SHIFT_USE_DFLT (-70)
+#define YY_SHIFT_COUNT (416)
+#define YY_SHIFT_MIN (-69)
+#define YY_SHIFT_MAX (1487)
static const short yy_shift_ofst[] = {
- /* 0 */ 975, 1114, 1343, 1114, 1213, 1213, 90, 90, 0, -19,
- /* 10 */ 1213, 1213, 1213, 1213, 1213, 345, 445, 721, 1091, 1213,
- /* 20 */ 1213, 1213, 1213, 1213, 1213, 1213, 1213, 1213, 1213, 1213,
- /* 30 */ 1213, 1213, 1213, 1213, 1213, 1213, 1213, 1213, 1213, 1213,
- /* 40 */ 1213, 1213, 1213, 1213, 1213, 1213, 1213, 1236, 1213, 1213,
- /* 50 */ 1213, 1213, 1213, 1213, 1213, 1213, 1213, 1213, 1213, 1213,
- /* 60 */ 1213, 199, 445, 445, 835, 835, 365, 1164, 55, 647,
- /* 70 */ 573, 499, 425, 351, 277, 203, 129, 795, 795, 795,
- /* 80 */ 795, 795, 795, 795, 795, 795, 795, 795, 795, 795,
- /* 90 */ 795, 795, 795, 795, 795, 869, 795, 943, 1017, 1017,
- /* 100 */ -69, -45, -45, -45, -45, -45, -1, 58, 138, 100,
- /* 110 */ 445, 445, 445, 445, 445, 445, 445, 445, 445, 445,
- /* 120 */ 445, 445, 445, 445, 445, 445, 537, 438, 445, 445,
- /* 130 */ 445, 445, 445, 365, 807, 1436, -74, -74, -74, 1293,
- /* 140 */ 73, 434, 434, 311, 314, 290, 283, 286, 540, 467,
- /* 150 */ 445, 445, 445, 445, 445, 445, 445, 445, 445, 445,
- /* 160 */ 445, 445, 445, 445, 445, 445, 445, 445, 445, 445,
- /* 170 */ 445, 445, 445, 445, 445, 445, 445, 445, 445, 445,
- /* 180 */ 445, 445, 65, 722, 722, 722, 688, 266, 1164, 1164,
- /* 190 */ 1164, -74, -74, -74, 136, 168, 168, 234, 360, 360,
- /* 200 */ 360, 430, 372, 435, 352, 278, 126, -36, -36, -36,
- /* 210 */ -36, 421, 651, -36, -36, 592, 292, 212, 623, 158,
- /* 220 */ 204, 204, 505, 158, 505, 144, 365, 154, 365, 154,
- /* 230 */ 645, 154, 204, 154, 154, 535, 548, 548, 365, 387,
- /* 240 */ 508, 233, 1464, 1222, 1222, 1456, 1456, 1222, 1462, 1410,
- /* 250 */ 1165, 1468, 1468, 1468, 1468, 1222, 1165, 1462, 1410, 1410,
- /* 260 */ 1222, 1448, 1338, 1425, 1222, 1222, 1448, 1222, 1448, 1222,
- /* 270 */ 1448, 1419, 1313, 1313, 1313, 1387, 1364, 1364, 1419, 1313,
- /* 280 */ 1336, 1313, 1387, 1313, 1313, 1254, 1245, 1254, 1245, 1254,
- /* 290 */ 1245, 1222, 1222, 1186, 1189, 1175, 1169, 1171, 1165, 1164,
- /* 300 */ 1243, 1244, 1244, 1212, 1212, 1212, 1212, -74, -74, -74,
- /* 310 */ -74, -74, -74, 939, 104, 680, 571, 327, 1, 980,
- /* 320 */ 26, 972, 971, 946, 901, 870, 830, 806, 54, 21,
- /* 330 */ -73, 510, 242, 1198, 1190, 1170, 1042, 1161, 1108, 1146,
- /* 340 */ 1141, 1132, 1015, 1127, 1026, 1034, 1020, 1107, 1004, 1116,
- /* 350 */ 1121, 1005, 1099, 951, 1043, 1003, 969, 1045, 1035, 950,
- /* 360 */ 1053, 1047, 1025, 942, 913, 992, 1019, 945, 984, 940,
- /* 370 */ 876, 904, 953, 896, 748, 804, 880, 786, 868, 819,
- /* 380 */ 805, 810, 773, 751, 766, 706, 716, 691, 681, 568,
- /* 390 */ 655, 638, 676, 516, 541, 594, 599, 567, 541, 534,
- /* 400 */ 507, 527, 498, 523, 466, 382, 409, 384, 357, 6,
- /* 410 */ 240, 224, 143, 62, 18, 71, 39, 9, 5,
+ /* 0 */ 1143, 1188, 1417, 1188, 1287, 1287, 138, 138, -2, -19,
+ /* 10 */ 1287, 1287, 1287, 1287, 347, 362, 129, 129, 795, 1165,
+ /* 20 */ 1287, 1287, 1287, 1287, 1287, 1287, 1287, 1287, 1287, 1287,
+ /* 30 */ 1287, 1287, 1287, 1287, 1287, 1287, 1287, 1287, 1287, 1287,
+ /* 40 */ 1287, 1287, 1287, 1287, 1287, 1287, 1287, 1287, 1310, 1287,
+ /* 50 */ 1287, 1287, 1287, 1287, 1287, 1287, 1287, 1287, 1287, 1287,
+ /* 60 */ 1287, 1287, 286, 362, 362, 538, 538, 231, 1253, 55,
+ /* 70 */ 721, 647, 573, 499, 425, 351, 277, 203, 869, 869,
+ /* 80 */ 869, 869, 869, 869, 869, 869, 869, 869, 869, 869,
+ /* 90 */ 869, 869, 869, 943, 869, 1017, 1091, 1091, -69, -45,
+ /* 100 */ -45, -45, -45, -45, -1, 24, 245, 362, 362, 362,
+ /* 110 */ 362, 362, 362, 362, 362, 362, 362, 362, 362, 362,
+ /* 120 */ 362, 362, 362, 388, 356, 362, 362, 362, 362, 362,
+ /* 130 */ 732, 868, 231, 1051, 1458, -70, -70, -70, 1367, 57,
+ /* 140 */ 434, 434, 289, 291, 285, 1, 204, 572, 539, 362,
+ /* 150 */ 362, 362, 362, 362, 362, 362, 362, 362, 362, 362,
+ /* 160 */ 362, 362, 362, 362, 362, 362, 362, 362, 362, 362,
+ /* 170 */ 362, 362, 362, 362, 362, 362, 362, 362, 362, 362,
+ /* 180 */ 362, 506, 506, 506, 705, 1253, 1253, 1253, -70, -70,
+ /* 190 */ -70, 171, 171, 160, 502, 502, 502, 446, 432, 511,
+ /* 200 */ 422, 358, 335, -12, -12, -12, -12, 576, 294, -12,
+ /* 210 */ -12, 295, 595, 141, 600, 730, 723, 723, 805, 730,
+ /* 220 */ 805, 439, 911, 231, 865, 231, 865, 807, 865, 723,
+ /* 230 */ 766, 633, 633, 231, 284, 63, 608, 1476, 1308, 1308,
+ /* 240 */ 1472, 1472, 1308, 1477, 1425, 1275, 1487, 1487, 1487, 1487,
+ /* 250 */ 1308, 1461, 1275, 1477, 1425, 1425, 1308, 1461, 1355, 1441,
+ /* 260 */ 1308, 1308, 1461, 1308, 1461, 1308, 1461, 1442, 1348, 1348,
+ /* 270 */ 1348, 1408, 1375, 1375, 1442, 1348, 1357, 1348, 1408, 1348,
+ /* 280 */ 1348, 1316, 1331, 1316, 1331, 1316, 1331, 1308, 1308, 1280,
+ /* 290 */ 1288, 1289, 1285, 1279, 1275, 1253, 1336, 1346, 1346, 1338,
+ /* 300 */ 1338, 1338, 1338, -70, -70, -70, -70, -70, -70, 1013,
+ /* 310 */ 467, 612, 84, 179, -28, 870, 410, 761, 760, 667,
+ /* 320 */ 650, 531, 220, 361, 331, 125, 127, 97, 1306, 1300,
+ /* 330 */ 1270, 1151, 1272, 1203, 1232, 1261, 1244, 1148, 1174, 1139,
+ /* 340 */ 1156, 1124, 1220, 1115, 1210, 1233, 1099, 1193, 1184, 1174,
+ /* 350 */ 1173, 1029, 1121, 1120, 1085, 1162, 1119, 1037, 1152, 1147,
+ /* 360 */ 1129, 1046, 1011, 1093, 1098, 1075, 1061, 1032, 960, 1057,
+ /* 370 */ 1031, 1030, 899, 938, 982, 936, 972, 958, 910, 955,
+ /* 380 */ 875, 885, 908, 857, 859, 867, 804, 590, 834, 747,
+ /* 390 */ 818, 513, 611, 741, 673, 637, 611, 606, 603, 579,
+ /* 400 */ 501, 541, 468, 386, 445, 395, 376, 281, 185, 120,
+ /* 410 */ 92, 75, 45, 114, 25, 11, 5,
};
-#define YY_REDUCE_USE_DFLT (-142)
-#define YY_REDUCE_COUNT (312)
-#define YY_REDUCE_MIN (-141)
-#define YY_REDUCE_MAX (1369)
+#define YY_REDUCE_USE_DFLT (-169)
+#define YY_REDUCE_COUNT (308)
+#define YY_REDUCE_MIN (-168)
+#define YY_REDUCE_MAX (1391)
static const short yy_reduce_ofst[] = {
- /* 0 */ -141, 994, 1118, 223, 157, -53, 93, 89, 83, 375,
- /* 10 */ 386, 381, 379, 308, 295, 325, -47, 27, 1240, 1234,
- /* 20 */ 1228, 1221, 1208, 1187, 1151, 1111, 1109, 1077, 1054, 1022,
- /* 30 */ 1016, 1000, 911, 908, 906, 890, 888, 874, 834, 816,
- /* 40 */ 800, 760, 758, 755, 742, 739, 726, 685, 672, 668,
- /* 50 */ 665, 652, 611, 609, 607, 604, 591, 578, 526, 519,
- /* 60 */ 453, 474, 454, 461, 443, 245, 442, 473, 484, 484,
- /* 70 */ 484, 484, 484, 484, 484, 484, 484, 484, 484, 484,
- /* 80 */ 484, 484, 484, 484, 484, 484, 484, 484, 484, 484,
- /* 90 */ 484, 484, 484, 484, 484, 484, 484, 484, 484, 484,
- /* 100 */ 484, 484, 484, 484, 484, 484, 484, 130, 484, 484,
- /* 110 */ 1145, 909, 1110, 1088, 1084, 1033, 1002, 965, 820, 837,
- /* 120 */ 746, 686, 612, 817, 610, 919, 221, 563, 814, 813,
- /* 130 */ 744, 669, 470, 543, 484, 484, 484, 484, 484, 291,
- /* 140 */ 569, 671, 658, 970, 1290, 1287, 1286, 1282, 518, 518,
- /* 150 */ 1280, 1279, 1277, 1270, 1268, 1263, 1261, 1260, 1256, 1251,
- /* 160 */ 1247, 1227, 1185, 1168, 1167, 1159, 1148, 1139, 1117, 1066,
- /* 170 */ 1049, 1006, 998, 996, 995, 973, 970, 966, 964, 892,
- /* 180 */ 762, -52, 881, 932, 802, 731, 619, 812, 664, 660,
- /* 190 */ 627, 392, 331, 124, 1358, 1357, 1356, 1354, 1352, 1351,
- /* 200 */ 1349, 1319, 1334, 1346, 1334, 1334, 1334, 1334, 1334, 1334,
- /* 210 */ 1334, 1320, 1304, 1334, 1334, 1319, 1360, 1325, 1369, 1326,
- /* 220 */ 1315, 1311, 1301, 1324, 1300, 1335, 1350, 1345, 1348, 1342,
- /* 230 */ 1333, 1341, 1303, 1332, 1331, 1284, 1278, 1274, 1339, 1309,
- /* 240 */ 1308, 1347, 1258, 1344, 1340, 1257, 1253, 1337, 1273, 1302,
- /* 250 */ 1299, 1298, 1297, 1296, 1295, 1328, 1294, 1264, 1292, 1291,
- /* 260 */ 1322, 1321, 1238, 1232, 1318, 1317, 1316, 1314, 1312, 1310,
- /* 270 */ 1307, 1283, 1289, 1288, 1285, 1276, 1229, 1224, 1267, 1281,
- /* 280 */ 1265, 1262, 1235, 1255, 1205, 1183, 1179, 1177, 1162, 1140,
- /* 290 */ 1153, 1184, 1182, 1102, 1124, 1103, 1095, 1090, 1089, 1093,
- /* 300 */ 1112, 1115, 1086, 1105, 1092, 1087, 1068, 962, 955, 957,
- /* 310 */ 1031, 1023, 1030,
+ /* 0 */ -141, 90, 1095, 222, 158, 156, 19, 17, 10, -104,
+ /* 10 */ 378, 316, 311, 12, 180, 249, 598, 464, 397, 1181,
+ /* 20 */ 1177, 1175, 1128, 1106, 1096, 1054, 1038, 974, 964, 962,
+ /* 30 */ 948, 905, 903, 900, 887, 874, 832, 826, 816, 813,
+ /* 40 */ 800, 758, 755, 752, 742, 739, 726, 685, 681, 668,
+ /* 50 */ 665, 652, 607, 604, 594, 591, 578, 530, 528, 526,
+ /* 60 */ 385, 18, 477, 466, 519, 444, 350, 435, 405, 488,
+ /* 70 */ 488, 488, 488, 488, 488, 488, 488, 488, 488, 488,
+ /* 80 */ 488, 488, 488, 488, 488, 488, 488, 488, 488, 488,
+ /* 90 */ 488, 488, 488, 488, 488, 488, 488, 488, 488, 488,
+ /* 100 */ 488, 488, 488, 488, 488, 488, 488, 1040, 678, 1036,
+ /* 110 */ 1007, 967, 966, 965, 845, 686, 610, 684, 317, 672,
+ /* 120 */ 893, 327, 623, 522, -7, 820, 814, 157, 154, 101,
+ /* 130 */ 702, 494, 580, 488, 488, 488, 488, 488, 614, 586,
+ /* 140 */ 935, 892, 968, 1245, 1242, 1234, 1225, 798, 798, 1222,
+ /* 150 */ 1221, 1218, 1214, 1213, 1212, 1202, 1195, 1191, 1161, 1158,
+ /* 160 */ 1140, 1135, 1123, 1112, 1107, 1100, 1080, 1074, 1073, 1072,
+ /* 170 */ 1070, 1067, 1048, 1044, 969, 968, 907, 906, 904, 894,
+ /* 180 */ 833, 837, 836, 340, 827, 815, 775, 68, 722, 646,
+ /* 190 */ -168, 1384, 1380, 1377, 1379, 1376, 1373, 1339, 1365, 1368,
+ /* 200 */ 1365, 1365, 1365, 1365, 1365, 1365, 1365, 1320, 1319, 1365,
+ /* 210 */ 1365, 1339, 1378, 1349, 1391, 1350, 1342, 1334, 1307, 1341,
+ /* 220 */ 1293, 1364, 1363, 1371, 1362, 1370, 1359, 1340, 1354, 1333,
+ /* 230 */ 1305, 1304, 1299, 1361, 1328, 1324, 1366, 1282, 1360, 1358,
+ /* 240 */ 1278, 1276, 1356, 1292, 1322, 1309, 1317, 1315, 1314, 1312,
+ /* 250 */ 1345, 1347, 1302, 1277, 1311, 1303, 1337, 1335, 1252, 1248,
+ /* 260 */ 1332, 1330, 1329, 1327, 1326, 1323, 1321, 1297, 1301, 1295,
+ /* 270 */ 1294, 1290, 1243, 1240, 1284, 1291, 1286, 1283, 1274, 1281,
+ /* 280 */ 1271, 1238, 1241, 1236, 1235, 1227, 1226, 1267, 1266, 1189,
+ /* 290 */ 1229, 1223, 1211, 1206, 1201, 1197, 1239, 1237, 1219, 1216,
+ /* 300 */ 1209, 1208, 1185, 1089, 1086, 1087, 1137, 1136, 1164,
};
static const YYACTIONTYPE yy_default[] = {
- /* 0 */ 635, 870, 959, 959, 959, 870, 899, 899, 959, 759,
- /* 10 */ 959, 959, 959, 959, 868, 959, 959, 933, 959, 959,
- /* 20 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 959,
- /* 30 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 959,
- /* 40 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 959,
- /* 50 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 959,
- /* 60 */ 959, 959, 959, 959, 899, 899, 674, 763, 794, 959,
- /* 70 */ 959, 959, 959, 959, 959, 959, 959, 932, 934, 809,
- /* 80 */ 808, 802, 801, 912, 774, 799, 792, 785, 796, 871,
- /* 90 */ 864, 865, 863, 867, 872, 959, 795, 831, 848, 830,
- /* 100 */ 842, 847, 854, 846, 843, 833, 832, 666, 834, 835,
- /* 110 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 959,
- /* 120 */ 959, 959, 959, 959, 959, 959, 661, 728, 959, 959,
- /* 130 */ 959, 959, 959, 959, 836, 837, 851, 850, 849, 959,
- /* 140 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 959,
- /* 150 */ 959, 939, 937, 959, 883, 959, 959, 959, 959, 959,
- /* 160 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 959,
- /* 170 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 959,
- /* 180 */ 959, 641, 959, 759, 759, 759, 635, 959, 959, 959,
- /* 190 */ 959, 951, 763, 753, 719, 959, 959, 959, 959, 959,
- /* 200 */ 959, 959, 959, 959, 959, 959, 959, 804, 742, 922,
- /* 210 */ 924, 959, 905, 740, 663, 761, 676, 751, 643, 798,
- /* 220 */ 776, 776, 917, 798, 917, 700, 959, 788, 959, 788,
- /* 230 */ 697, 788, 776, 788, 788, 866, 959, 959, 959, 760,
- /* 240 */ 751, 959, 944, 767, 767, 936, 936, 767, 810, 732,
- /* 250 */ 798, 739, 739, 739, 739, 767, 798, 810, 732, 732,
- /* 260 */ 767, 658, 911, 909, 767, 767, 658, 767, 658, 767,
- /* 270 */ 658, 876, 730, 730, 730, 715, 880, 880, 876, 730,
- /* 280 */ 700, 730, 715, 730, 730, 780, 775, 780, 775, 780,
- /* 290 */ 775, 767, 767, 959, 793, 781, 791, 789, 798, 959,
- /* 300 */ 718, 651, 651, 640, 640, 640, 640, 956, 956, 951,
- /* 310 */ 702, 702, 684, 959, 959, 959, 959, 959, 959, 959,
- /* 320 */ 885, 959, 959, 959, 959, 959, 959, 959, 959, 959,
- /* 330 */ 959, 959, 959, 959, 636, 946, 959, 959, 943, 959,
- /* 340 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 959,
- /* 350 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 915,
- /* 360 */ 959, 959, 959, 959, 959, 959, 908, 907, 959, 959,
- /* 370 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 959,
- /* 380 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 959,
- /* 390 */ 959, 959, 959, 959, 790, 959, 782, 959, 869, 959,
- /* 400 */ 959, 959, 959, 959, 959, 959, 959, 959, 959, 745,
- /* 410 */ 819, 959, 818, 822, 817, 668, 959, 649, 959, 632,
- /* 420 */ 637, 955, 958, 957, 954, 953, 952, 947, 945, 942,
- /* 430 */ 941, 940, 938, 935, 931, 889, 887, 894, 893, 892,
- /* 440 */ 891, 890, 888, 886, 884, 805, 803, 800, 797, 930,
- /* 450 */ 882, 741, 738, 737, 657, 948, 914, 923, 921, 811,
- /* 460 */ 920, 919, 918, 916, 913, 900, 807, 806, 733, 874,
- /* 470 */ 873, 660, 904, 903, 902, 906, 910, 901, 769, 659,
- /* 480 */ 656, 665, 722, 721, 729, 727, 726, 725, 724, 723,
- /* 490 */ 720, 667, 675, 686, 714, 699, 698, 879, 881, 878,
- /* 500 */ 877, 707, 706, 712, 711, 710, 709, 708, 705, 704,
- /* 510 */ 703, 696, 695, 701, 694, 717, 716, 713, 693, 736,
- /* 520 */ 735, 734, 731, 692, 691, 690, 822, 689, 688, 828,
- /* 530 */ 827, 815, 858, 756, 755, 754, 766, 765, 778, 777,
- /* 540 */ 813, 812, 779, 764, 758, 757, 773, 772, 771, 770,
- /* 550 */ 762, 752, 784, 787, 786, 783, 860, 768, 857, 929,
- /* 560 */ 928, 927, 926, 925, 862, 861, 829, 826, 679, 680,
- /* 570 */ 898, 896, 897, 895, 682, 681, 678, 677, 859, 747,
- /* 580 */ 746, 855, 852, 844, 840, 856, 853, 845, 841, 839,
- /* 590 */ 838, 824, 823, 821, 820, 816, 825, 670, 748, 744,
- /* 600 */ 743, 814, 750, 749, 687, 685, 683, 664, 662, 655,
- /* 610 */ 653, 652, 654, 650, 648, 647, 646, 645, 644, 673,
- /* 620 */ 672, 671, 669, 668, 642, 639, 638, 634, 633, 631,
+ /* 0 */ 632, 866, 954, 954, 866, 866, 954, 954, 954, 756,
+ /* 10 */ 954, 954, 954, 864, 954, 954, 784, 784, 928, 954,
+ /* 20 */ 954, 954, 954, 954, 954, 954, 954, 954, 954, 954,
+ /* 30 */ 954, 954, 954, 954, 954, 954, 954, 954, 954, 954,
+ /* 40 */ 954, 954, 954, 954, 954, 954, 954, 954, 954, 954,
+ /* 50 */ 954, 954, 954, 954, 954, 954, 954, 954, 954, 954,
+ /* 60 */ 954, 954, 954, 954, 954, 954, 954, 671, 760, 790,
+ /* 70 */ 954, 954, 954, 954, 954, 954, 954, 954, 927, 929,
+ /* 80 */ 798, 797, 907, 771, 795, 788, 792, 867, 860, 861,
+ /* 90 */ 859, 863, 868, 954, 791, 827, 844, 826, 838, 843,
+ /* 100 */ 850, 842, 839, 829, 828, 830, 831, 954, 954, 954,
+ /* 110 */ 954, 954, 954, 954, 954, 954, 954, 954, 954, 954,
+ /* 120 */ 954, 954, 954, 658, 725, 954, 954, 954, 954, 954,
+ /* 130 */ 954, 954, 954, 832, 833, 847, 846, 845, 954, 663,
+ /* 140 */ 954, 954, 954, 954, 954, 954, 954, 954, 954, 954,
+ /* 150 */ 934, 932, 954, 879, 954, 954, 954, 954, 954, 954,
+ /* 160 */ 954, 954, 954, 954, 954, 954, 954, 954, 954, 954,
+ /* 170 */ 954, 954, 954, 954, 954, 954, 954, 954, 954, 954,
+ /* 180 */ 638, 756, 756, 756, 632, 954, 954, 954, 946, 760,
+ /* 190 */ 750, 954, 954, 954, 954, 954, 954, 954, 954, 954,
+ /* 200 */ 954, 954, 954, 800, 739, 917, 919, 954, 900, 737,
+ /* 210 */ 660, 758, 673, 748, 640, 794, 773, 773, 912, 794,
+ /* 220 */ 912, 696, 719, 954, 784, 954, 784, 693, 784, 773,
+ /* 230 */ 862, 954, 954, 954, 757, 748, 954, 939, 764, 764,
+ /* 240 */ 931, 931, 764, 806, 729, 794, 736, 736, 736, 736,
+ /* 250 */ 764, 655, 794, 806, 729, 729, 764, 655, 906, 904,
+ /* 260 */ 764, 764, 655, 764, 655, 764, 655, 872, 727, 727,
+ /* 270 */ 727, 711, 876, 876, 872, 727, 696, 727, 711, 727,
+ /* 280 */ 727, 777, 772, 777, 772, 777, 772, 764, 764, 954,
+ /* 290 */ 789, 778, 787, 785, 794, 954, 714, 648, 648, 637,
+ /* 300 */ 637, 637, 637, 951, 951, 946, 698, 698, 681, 954,
+ /* 310 */ 954, 954, 954, 954, 954, 954, 881, 954, 954, 954,
+ /* 320 */ 954, 954, 954, 954, 954, 954, 954, 954, 954, 633,
+ /* 330 */ 941, 954, 954, 938, 954, 954, 954, 954, 799, 954,
+ /* 340 */ 954, 954, 954, 954, 954, 954, 954, 954, 954, 916,
+ /* 350 */ 954, 954, 954, 954, 954, 954, 954, 910, 954, 954,
+ /* 360 */ 954, 954, 954, 954, 903, 902, 954, 954, 954, 954,
+ /* 370 */ 954, 954, 954, 954, 954, 954, 954, 954, 954, 954,
+ /* 380 */ 954, 954, 954, 954, 954, 954, 954, 954, 954, 954,
+ /* 390 */ 954, 954, 786, 954, 779, 954, 865, 954, 954, 954,
+ /* 400 */ 954, 954, 954, 954, 954, 954, 954, 742, 815, 954,
+ /* 410 */ 814, 818, 813, 665, 954, 646, 954, 629, 634, 950,
+ /* 420 */ 953, 952, 949, 948, 947, 942, 940, 937, 936, 935,
+ /* 430 */ 933, 930, 926, 885, 883, 890, 889, 888, 887, 886,
+ /* 440 */ 884, 882, 880, 801, 796, 793, 925, 878, 738, 735,
+ /* 450 */ 734, 654, 943, 909, 918, 805, 804, 807, 915, 914,
+ /* 460 */ 913, 911, 908, 895, 803, 802, 730, 870, 869, 657,
+ /* 470 */ 899, 898, 897, 901, 905, 896, 766, 656, 653, 662,
+ /* 480 */ 717, 718, 726, 724, 723, 722, 721, 720, 716, 664,
+ /* 490 */ 672, 710, 695, 694, 875, 877, 874, 873, 703, 702,
+ /* 500 */ 708, 707, 706, 705, 704, 701, 700, 699, 692, 691,
+ /* 510 */ 697, 690, 713, 712, 709, 689, 733, 732, 731, 728,
+ /* 520 */ 688, 687, 686, 818, 685, 684, 824, 823, 811, 854,
+ /* 530 */ 753, 752, 751, 763, 762, 775, 774, 809, 808, 776,
+ /* 540 */ 761, 755, 754, 770, 769, 768, 767, 759, 749, 781,
+ /* 550 */ 783, 782, 780, 856, 765, 853, 924, 923, 922, 921,
+ /* 560 */ 920, 858, 857, 825, 822, 676, 677, 893, 892, 894,
+ /* 570 */ 891, 679, 678, 675, 674, 855, 744, 743, 851, 848,
+ /* 580 */ 840, 836, 852, 849, 841, 837, 835, 834, 820, 819,
+ /* 590 */ 817, 816, 812, 821, 667, 745, 741, 740, 810, 747,
+ /* 600 */ 746, 683, 682, 680, 661, 659, 652, 650, 649, 651,
+ /* 610 */ 647, 645, 644, 643, 642, 641, 670, 669, 668, 666,
+ /* 620 */ 665, 639, 636, 635, 631, 630, 628,
};
/* The next table maps tokens into fallback tokens. If a construct
@@ -104221,6 +109536,7 @@ struct yyParser {
typedef struct yyParser yyParser;
#ifndef NDEBUG
+/* #include <stdio.h> */
static FILE *yyTraceFILE = 0;
static char *yyTracePrompt = 0;
#endif /* NDEBUG */
@@ -104298,26 +109614,26 @@ static const char *const yyTokenName[] = {
"select", "column", "columnid", "type",
"carglist", "id", "ids", "typetoken",
"typename", "signed", "plus_num", "minus_num",
- "carg", "ccons", "term", "expr",
- "onconf", "sortorder", "autoinc", "idxlist_opt",
- "refargs", "defer_subclause", "refarg", "refact",
- "init_deferred_pred_opt", "conslist", "tcons", "idxlist",
+ "ccons", "term", "expr", "onconf",
+ "sortorder", "autoinc", "idxlist_opt", "refargs",
+ "defer_subclause", "refarg", "refact", "init_deferred_pred_opt",
+ "conslist", "tconscomma", "tcons", "idxlist",
"defer_subclause_opt", "orconf", "resolvetype", "raisetype",
"ifexists", "fullname", "oneselect", "multiselect_op",
"distinct", "selcollist", "from", "where_opt",
"groupby_opt", "having_opt", "orderby_opt", "limit_opt",
"sclp", "as", "seltablist", "stl_prefix",
"joinop", "indexed_opt", "on_opt", "using_opt",
- "joinop2", "inscollist", "sortlist", "sortitem",
- "nexprlist", "setlist", "insert_cmd", "inscollist_opt",
- "itemlist", "exprlist", "likeop", "between_op",
- "in_op", "case_operand", "case_exprlist", "case_else",
- "uniqueflag", "collate", "nmnum", "plus_opt",
- "number", "trigger_decl", "trigger_cmd_list", "trigger_time",
- "trigger_event", "foreach_clause", "when_clause", "trigger_cmd",
- "trnm", "tridxby", "database_kw_opt", "key_opt",
- "add_column_fullname", "kwcolumn_opt", "create_vtab", "vtabarglist",
- "vtabarg", "vtabargtoken", "lp", "anylist",
+ "joinop2", "inscollist", "sortlist", "nexprlist",
+ "setlist", "insert_cmd", "inscollist_opt", "valuelist",
+ "exprlist", "likeop", "between_op", "in_op",
+ "case_operand", "case_exprlist", "case_else", "uniqueflag",
+ "collate", "nmnum", "number", "trigger_decl",
+ "trigger_cmd_list", "trigger_time", "trigger_event", "foreach_clause",
+ "when_clause", "trigger_cmd", "trnm", "tridxby",
+ "database_kw_opt", "key_opt", "add_column_fullname", "kwcolumn_opt",
+ "create_vtab", "vtabarglist", "vtabarg", "vtabargtoken",
+ "lp", "anylist",
};
#endif /* NDEBUG */
@@ -104378,46 +109694,46 @@ static const char *const yyRuleName[] = {
/* 50 */ "typename ::= typename ids",
/* 51 */ "signed ::= plus_num",
/* 52 */ "signed ::= minus_num",
- /* 53 */ "carglist ::= carglist carg",
+ /* 53 */ "carglist ::= carglist ccons",
/* 54 */ "carglist ::=",
- /* 55 */ "carg ::= CONSTRAINT nm ccons",
- /* 56 */ "carg ::= ccons",
- /* 57 */ "ccons ::= DEFAULT term",
- /* 58 */ "ccons ::= DEFAULT LP expr RP",
- /* 59 */ "ccons ::= DEFAULT PLUS term",
- /* 60 */ "ccons ::= DEFAULT MINUS term",
- /* 61 */ "ccons ::= DEFAULT id",
- /* 62 */ "ccons ::= NULL onconf",
- /* 63 */ "ccons ::= NOT NULL onconf",
- /* 64 */ "ccons ::= PRIMARY KEY sortorder onconf autoinc",
- /* 65 */ "ccons ::= UNIQUE onconf",
- /* 66 */ "ccons ::= CHECK LP expr RP",
- /* 67 */ "ccons ::= REFERENCES nm idxlist_opt refargs",
- /* 68 */ "ccons ::= defer_subclause",
- /* 69 */ "ccons ::= COLLATE ids",
- /* 70 */ "autoinc ::=",
- /* 71 */ "autoinc ::= AUTOINCR",
- /* 72 */ "refargs ::=",
- /* 73 */ "refargs ::= refargs refarg",
- /* 74 */ "refarg ::= MATCH nm",
- /* 75 */ "refarg ::= ON INSERT refact",
- /* 76 */ "refarg ::= ON DELETE refact",
- /* 77 */ "refarg ::= ON UPDATE refact",
- /* 78 */ "refact ::= SET NULL",
- /* 79 */ "refact ::= SET DEFAULT",
- /* 80 */ "refact ::= CASCADE",
- /* 81 */ "refact ::= RESTRICT",
- /* 82 */ "refact ::= NO ACTION",
- /* 83 */ "defer_subclause ::= NOT DEFERRABLE init_deferred_pred_opt",
- /* 84 */ "defer_subclause ::= DEFERRABLE init_deferred_pred_opt",
- /* 85 */ "init_deferred_pred_opt ::=",
- /* 86 */ "init_deferred_pred_opt ::= INITIALLY DEFERRED",
- /* 87 */ "init_deferred_pred_opt ::= INITIALLY IMMEDIATE",
- /* 88 */ "conslist_opt ::=",
- /* 89 */ "conslist_opt ::= COMMA conslist",
- /* 90 */ "conslist ::= conslist COMMA tcons",
- /* 91 */ "conslist ::= conslist tcons",
- /* 92 */ "conslist ::= tcons",
+ /* 55 */ "ccons ::= CONSTRAINT nm",
+ /* 56 */ "ccons ::= DEFAULT term",
+ /* 57 */ "ccons ::= DEFAULT LP expr RP",
+ /* 58 */ "ccons ::= DEFAULT PLUS term",
+ /* 59 */ "ccons ::= DEFAULT MINUS term",
+ /* 60 */ "ccons ::= DEFAULT id",
+ /* 61 */ "ccons ::= NULL onconf",
+ /* 62 */ "ccons ::= NOT NULL onconf",
+ /* 63 */ "ccons ::= PRIMARY KEY sortorder onconf autoinc",
+ /* 64 */ "ccons ::= UNIQUE onconf",
+ /* 65 */ "ccons ::= CHECK LP expr RP",
+ /* 66 */ "ccons ::= REFERENCES nm idxlist_opt refargs",
+ /* 67 */ "ccons ::= defer_subclause",
+ /* 68 */ "ccons ::= COLLATE ids",
+ /* 69 */ "autoinc ::=",
+ /* 70 */ "autoinc ::= AUTOINCR",
+ /* 71 */ "refargs ::=",
+ /* 72 */ "refargs ::= refargs refarg",
+ /* 73 */ "refarg ::= MATCH nm",
+ /* 74 */ "refarg ::= ON INSERT refact",
+ /* 75 */ "refarg ::= ON DELETE refact",
+ /* 76 */ "refarg ::= ON UPDATE refact",
+ /* 77 */ "refact ::= SET NULL",
+ /* 78 */ "refact ::= SET DEFAULT",
+ /* 79 */ "refact ::= CASCADE",
+ /* 80 */ "refact ::= RESTRICT",
+ /* 81 */ "refact ::= NO ACTION",
+ /* 82 */ "defer_subclause ::= NOT DEFERRABLE init_deferred_pred_opt",
+ /* 83 */ "defer_subclause ::= DEFERRABLE init_deferred_pred_opt",
+ /* 84 */ "init_deferred_pred_opt ::=",
+ /* 85 */ "init_deferred_pred_opt ::= INITIALLY DEFERRED",
+ /* 86 */ "init_deferred_pred_opt ::= INITIALLY IMMEDIATE",
+ /* 87 */ "conslist_opt ::=",
+ /* 88 */ "conslist_opt ::= COMMA conslist",
+ /* 89 */ "conslist ::= conslist tconscomma tcons",
+ /* 90 */ "conslist ::= tcons",
+ /* 91 */ "tconscomma ::= COMMA",
+ /* 92 */ "tconscomma ::=",
/* 93 */ "tcons ::= CONSTRAINT nm",
/* 94 */ "tcons ::= PRIMARY KEY LP idxlist autoinc RP onconf",
/* 95 */ "tcons ::= UNIQUE LP idxlist RP onconf",
@@ -104478,182 +109794,180 @@ static const char *const yyRuleName[] = {
/* 150 */ "using_opt ::=",
/* 151 */ "orderby_opt ::=",
/* 152 */ "orderby_opt ::= ORDER BY sortlist",
- /* 153 */ "sortlist ::= sortlist COMMA sortitem sortorder",
- /* 154 */ "sortlist ::= sortitem sortorder",
- /* 155 */ "sortitem ::= expr",
- /* 156 */ "sortorder ::= ASC",
- /* 157 */ "sortorder ::= DESC",
- /* 158 */ "sortorder ::=",
- /* 159 */ "groupby_opt ::=",
- /* 160 */ "groupby_opt ::= GROUP BY nexprlist",
- /* 161 */ "having_opt ::=",
- /* 162 */ "having_opt ::= HAVING expr",
- /* 163 */ "limit_opt ::=",
- /* 164 */ "limit_opt ::= LIMIT expr",
- /* 165 */ "limit_opt ::= LIMIT expr OFFSET expr",
- /* 166 */ "limit_opt ::= LIMIT expr COMMA expr",
- /* 167 */ "cmd ::= DELETE FROM fullname indexed_opt where_opt",
- /* 168 */ "where_opt ::=",
- /* 169 */ "where_opt ::= WHERE expr",
- /* 170 */ "cmd ::= UPDATE orconf fullname indexed_opt SET setlist where_opt",
- /* 171 */ "setlist ::= setlist COMMA nm EQ expr",
- /* 172 */ "setlist ::= nm EQ expr",
- /* 173 */ "cmd ::= insert_cmd INTO fullname inscollist_opt VALUES LP itemlist RP",
- /* 174 */ "cmd ::= insert_cmd INTO fullname inscollist_opt select",
- /* 175 */ "cmd ::= insert_cmd INTO fullname inscollist_opt DEFAULT VALUES",
- /* 176 */ "insert_cmd ::= INSERT orconf",
- /* 177 */ "insert_cmd ::= REPLACE",
- /* 178 */ "itemlist ::= itemlist COMMA expr",
- /* 179 */ "itemlist ::= expr",
- /* 180 */ "inscollist_opt ::=",
- /* 181 */ "inscollist_opt ::= LP inscollist RP",
- /* 182 */ "inscollist ::= inscollist COMMA nm",
- /* 183 */ "inscollist ::= nm",
- /* 184 */ "expr ::= term",
- /* 185 */ "expr ::= LP expr RP",
- /* 186 */ "term ::= NULL",
- /* 187 */ "expr ::= id",
- /* 188 */ "expr ::= JOIN_KW",
- /* 189 */ "expr ::= nm DOT nm",
- /* 190 */ "expr ::= nm DOT nm DOT nm",
- /* 191 */ "term ::= INTEGER|FLOAT|BLOB",
- /* 192 */ "term ::= STRING",
- /* 193 */ "expr ::= REGISTER",
- /* 194 */ "expr ::= VARIABLE",
- /* 195 */ "expr ::= expr COLLATE ids",
- /* 196 */ "expr ::= CAST LP expr AS typetoken RP",
- /* 197 */ "expr ::= ID LP distinct exprlist RP",
- /* 198 */ "expr ::= ID LP STAR RP",
- /* 199 */ "term ::= CTIME_KW",
- /* 200 */ "expr ::= expr AND expr",
- /* 201 */ "expr ::= expr OR expr",
- /* 202 */ "expr ::= expr LT|GT|GE|LE expr",
- /* 203 */ "expr ::= expr EQ|NE expr",
- /* 204 */ "expr ::= expr BITAND|BITOR|LSHIFT|RSHIFT expr",
- /* 205 */ "expr ::= expr PLUS|MINUS expr",
- /* 206 */ "expr ::= expr STAR|SLASH|REM expr",
- /* 207 */ "expr ::= expr CONCAT expr",
- /* 208 */ "likeop ::= LIKE_KW",
- /* 209 */ "likeop ::= NOT LIKE_KW",
- /* 210 */ "likeop ::= MATCH",
- /* 211 */ "likeop ::= NOT MATCH",
- /* 212 */ "expr ::= expr likeop expr",
- /* 213 */ "expr ::= expr likeop expr ESCAPE expr",
- /* 214 */ "expr ::= expr ISNULL|NOTNULL",
- /* 215 */ "expr ::= expr NOT NULL",
- /* 216 */ "expr ::= expr IS expr",
- /* 217 */ "expr ::= expr IS NOT expr",
- /* 218 */ "expr ::= NOT expr",
- /* 219 */ "expr ::= BITNOT expr",
- /* 220 */ "expr ::= MINUS expr",
- /* 221 */ "expr ::= PLUS expr",
- /* 222 */ "between_op ::= BETWEEN",
- /* 223 */ "between_op ::= NOT BETWEEN",
- /* 224 */ "expr ::= expr between_op expr AND expr",
- /* 225 */ "in_op ::= IN",
- /* 226 */ "in_op ::= NOT IN",
- /* 227 */ "expr ::= expr in_op LP exprlist RP",
- /* 228 */ "expr ::= LP select RP",
- /* 229 */ "expr ::= expr in_op LP select RP",
- /* 230 */ "expr ::= expr in_op nm dbnm",
- /* 231 */ "expr ::= EXISTS LP select RP",
- /* 232 */ "expr ::= CASE case_operand case_exprlist case_else END",
- /* 233 */ "case_exprlist ::= case_exprlist WHEN expr THEN expr",
- /* 234 */ "case_exprlist ::= WHEN expr THEN expr",
- /* 235 */ "case_else ::= ELSE expr",
- /* 236 */ "case_else ::=",
- /* 237 */ "case_operand ::= expr",
- /* 238 */ "case_operand ::=",
- /* 239 */ "exprlist ::= nexprlist",
- /* 240 */ "exprlist ::=",
- /* 241 */ "nexprlist ::= nexprlist COMMA expr",
- /* 242 */ "nexprlist ::= expr",
- /* 243 */ "cmd ::= createkw uniqueflag INDEX ifnotexists nm dbnm ON nm LP idxlist RP",
- /* 244 */ "uniqueflag ::= UNIQUE",
- /* 245 */ "uniqueflag ::=",
- /* 246 */ "idxlist_opt ::=",
- /* 247 */ "idxlist_opt ::= LP idxlist RP",
- /* 248 */ "idxlist ::= idxlist COMMA nm collate sortorder",
- /* 249 */ "idxlist ::= nm collate sortorder",
- /* 250 */ "collate ::=",
- /* 251 */ "collate ::= COLLATE ids",
- /* 252 */ "cmd ::= DROP INDEX ifexists fullname",
- /* 253 */ "cmd ::= VACUUM",
- /* 254 */ "cmd ::= VACUUM nm",
- /* 255 */ "cmd ::= PRAGMA nm dbnm",
- /* 256 */ "cmd ::= PRAGMA nm dbnm EQ nmnum",
- /* 257 */ "cmd ::= PRAGMA nm dbnm LP nmnum RP",
- /* 258 */ "cmd ::= PRAGMA nm dbnm EQ minus_num",
- /* 259 */ "cmd ::= PRAGMA nm dbnm LP minus_num RP",
- /* 260 */ "nmnum ::= plus_num",
- /* 261 */ "nmnum ::= nm",
- /* 262 */ "nmnum ::= ON",
- /* 263 */ "nmnum ::= DELETE",
- /* 264 */ "nmnum ::= DEFAULT",
- /* 265 */ "plus_num ::= plus_opt number",
+ /* 153 */ "sortlist ::= sortlist COMMA expr sortorder",
+ /* 154 */ "sortlist ::= expr sortorder",
+ /* 155 */ "sortorder ::= ASC",
+ /* 156 */ "sortorder ::= DESC",
+ /* 157 */ "sortorder ::=",
+ /* 158 */ "groupby_opt ::=",
+ /* 159 */ "groupby_opt ::= GROUP BY nexprlist",
+ /* 160 */ "having_opt ::=",
+ /* 161 */ "having_opt ::= HAVING expr",
+ /* 162 */ "limit_opt ::=",
+ /* 163 */ "limit_opt ::= LIMIT expr",
+ /* 164 */ "limit_opt ::= LIMIT expr OFFSET expr",
+ /* 165 */ "limit_opt ::= LIMIT expr COMMA expr",
+ /* 166 */ "cmd ::= DELETE FROM fullname indexed_opt where_opt",
+ /* 167 */ "where_opt ::=",
+ /* 168 */ "where_opt ::= WHERE expr",
+ /* 169 */ "cmd ::= UPDATE orconf fullname indexed_opt SET setlist where_opt",
+ /* 170 */ "setlist ::= setlist COMMA nm EQ expr",
+ /* 171 */ "setlist ::= nm EQ expr",
+ /* 172 */ "cmd ::= insert_cmd INTO fullname inscollist_opt valuelist",
+ /* 173 */ "cmd ::= insert_cmd INTO fullname inscollist_opt select",
+ /* 174 */ "cmd ::= insert_cmd INTO fullname inscollist_opt DEFAULT VALUES",
+ /* 175 */ "insert_cmd ::= INSERT orconf",
+ /* 176 */ "insert_cmd ::= REPLACE",
+ /* 177 */ "valuelist ::= VALUES LP nexprlist RP",
+ /* 178 */ "valuelist ::= valuelist COMMA LP exprlist RP",
+ /* 179 */ "inscollist_opt ::=",
+ /* 180 */ "inscollist_opt ::= LP inscollist RP",
+ /* 181 */ "inscollist ::= inscollist COMMA nm",
+ /* 182 */ "inscollist ::= nm",
+ /* 183 */ "expr ::= term",
+ /* 184 */ "expr ::= LP expr RP",
+ /* 185 */ "term ::= NULL",
+ /* 186 */ "expr ::= id",
+ /* 187 */ "expr ::= JOIN_KW",
+ /* 188 */ "expr ::= nm DOT nm",
+ /* 189 */ "expr ::= nm DOT nm DOT nm",
+ /* 190 */ "term ::= INTEGER|FLOAT|BLOB",
+ /* 191 */ "term ::= STRING",
+ /* 192 */ "expr ::= REGISTER",
+ /* 193 */ "expr ::= VARIABLE",
+ /* 194 */ "expr ::= expr COLLATE ids",
+ /* 195 */ "expr ::= CAST LP expr AS typetoken RP",
+ /* 196 */ "expr ::= ID LP distinct exprlist RP",
+ /* 197 */ "expr ::= ID LP STAR RP",
+ /* 198 */ "term ::= CTIME_KW",
+ /* 199 */ "expr ::= expr AND expr",
+ /* 200 */ "expr ::= expr OR expr",
+ /* 201 */ "expr ::= expr LT|GT|GE|LE expr",
+ /* 202 */ "expr ::= expr EQ|NE expr",
+ /* 203 */ "expr ::= expr BITAND|BITOR|LSHIFT|RSHIFT expr",
+ /* 204 */ "expr ::= expr PLUS|MINUS expr",
+ /* 205 */ "expr ::= expr STAR|SLASH|REM expr",
+ /* 206 */ "expr ::= expr CONCAT expr",
+ /* 207 */ "likeop ::= LIKE_KW",
+ /* 208 */ "likeop ::= NOT LIKE_KW",
+ /* 209 */ "likeop ::= MATCH",
+ /* 210 */ "likeop ::= NOT MATCH",
+ /* 211 */ "expr ::= expr likeop expr",
+ /* 212 */ "expr ::= expr likeop expr ESCAPE expr",
+ /* 213 */ "expr ::= expr ISNULL|NOTNULL",
+ /* 214 */ "expr ::= expr NOT NULL",
+ /* 215 */ "expr ::= expr IS expr",
+ /* 216 */ "expr ::= expr IS NOT expr",
+ /* 217 */ "expr ::= NOT expr",
+ /* 218 */ "expr ::= BITNOT expr",
+ /* 219 */ "expr ::= MINUS expr",
+ /* 220 */ "expr ::= PLUS expr",
+ /* 221 */ "between_op ::= BETWEEN",
+ /* 222 */ "between_op ::= NOT BETWEEN",
+ /* 223 */ "expr ::= expr between_op expr AND expr",
+ /* 224 */ "in_op ::= IN",
+ /* 225 */ "in_op ::= NOT IN",
+ /* 226 */ "expr ::= expr in_op LP exprlist RP",
+ /* 227 */ "expr ::= LP select RP",
+ /* 228 */ "expr ::= expr in_op LP select RP",
+ /* 229 */ "expr ::= expr in_op nm dbnm",
+ /* 230 */ "expr ::= EXISTS LP select RP",
+ /* 231 */ "expr ::= CASE case_operand case_exprlist case_else END",
+ /* 232 */ "case_exprlist ::= case_exprlist WHEN expr THEN expr",
+ /* 233 */ "case_exprlist ::= WHEN expr THEN expr",
+ /* 234 */ "case_else ::= ELSE expr",
+ /* 235 */ "case_else ::=",
+ /* 236 */ "case_operand ::= expr",
+ /* 237 */ "case_operand ::=",
+ /* 238 */ "exprlist ::= nexprlist",
+ /* 239 */ "exprlist ::=",
+ /* 240 */ "nexprlist ::= nexprlist COMMA expr",
+ /* 241 */ "nexprlist ::= expr",
+ /* 242 */ "cmd ::= createkw uniqueflag INDEX ifnotexists nm dbnm ON nm LP idxlist RP",
+ /* 243 */ "uniqueflag ::= UNIQUE",
+ /* 244 */ "uniqueflag ::=",
+ /* 245 */ "idxlist_opt ::=",
+ /* 246 */ "idxlist_opt ::= LP idxlist RP",
+ /* 247 */ "idxlist ::= idxlist COMMA nm collate sortorder",
+ /* 248 */ "idxlist ::= nm collate sortorder",
+ /* 249 */ "collate ::=",
+ /* 250 */ "collate ::= COLLATE ids",
+ /* 251 */ "cmd ::= DROP INDEX ifexists fullname",
+ /* 252 */ "cmd ::= VACUUM",
+ /* 253 */ "cmd ::= VACUUM nm",
+ /* 254 */ "cmd ::= PRAGMA nm dbnm",
+ /* 255 */ "cmd ::= PRAGMA nm dbnm EQ nmnum",
+ /* 256 */ "cmd ::= PRAGMA nm dbnm LP nmnum RP",
+ /* 257 */ "cmd ::= PRAGMA nm dbnm EQ minus_num",
+ /* 258 */ "cmd ::= PRAGMA nm dbnm LP minus_num RP",
+ /* 259 */ "nmnum ::= plus_num",
+ /* 260 */ "nmnum ::= nm",
+ /* 261 */ "nmnum ::= ON",
+ /* 262 */ "nmnum ::= DELETE",
+ /* 263 */ "nmnum ::= DEFAULT",
+ /* 264 */ "plus_num ::= PLUS number",
+ /* 265 */ "plus_num ::= number",
/* 266 */ "minus_num ::= MINUS number",
/* 267 */ "number ::= INTEGER|FLOAT",
- /* 268 */ "plus_opt ::= PLUS",
- /* 269 */ "plus_opt ::=",
- /* 270 */ "cmd ::= createkw trigger_decl BEGIN trigger_cmd_list END",
- /* 271 */ "trigger_decl ::= temp TRIGGER ifnotexists nm dbnm trigger_time trigger_event ON fullname foreach_clause when_clause",
- /* 272 */ "trigger_time ::= BEFORE",
- /* 273 */ "trigger_time ::= AFTER",
- /* 274 */ "trigger_time ::= INSTEAD OF",
- /* 275 */ "trigger_time ::=",
- /* 276 */ "trigger_event ::= DELETE|INSERT",
- /* 277 */ "trigger_event ::= UPDATE",
- /* 278 */ "trigger_event ::= UPDATE OF inscollist",
- /* 279 */ "foreach_clause ::=",
- /* 280 */ "foreach_clause ::= FOR EACH ROW",
- /* 281 */ "when_clause ::=",
- /* 282 */ "when_clause ::= WHEN expr",
- /* 283 */ "trigger_cmd_list ::= trigger_cmd_list trigger_cmd SEMI",
- /* 284 */ "trigger_cmd_list ::= trigger_cmd SEMI",
- /* 285 */ "trnm ::= nm",
- /* 286 */ "trnm ::= nm DOT nm",
- /* 287 */ "tridxby ::=",
- /* 288 */ "tridxby ::= INDEXED BY nm",
- /* 289 */ "tridxby ::= NOT INDEXED",
- /* 290 */ "trigger_cmd ::= UPDATE orconf trnm tridxby SET setlist where_opt",
- /* 291 */ "trigger_cmd ::= insert_cmd INTO trnm inscollist_opt VALUES LP itemlist RP",
- /* 292 */ "trigger_cmd ::= insert_cmd INTO trnm inscollist_opt select",
- /* 293 */ "trigger_cmd ::= DELETE FROM trnm tridxby where_opt",
- /* 294 */ "trigger_cmd ::= select",
- /* 295 */ "expr ::= RAISE LP IGNORE RP",
- /* 296 */ "expr ::= RAISE LP raisetype COMMA nm RP",
- /* 297 */ "raisetype ::= ROLLBACK",
- /* 298 */ "raisetype ::= ABORT",
- /* 299 */ "raisetype ::= FAIL",
- /* 300 */ "cmd ::= DROP TRIGGER ifexists fullname",
- /* 301 */ "cmd ::= ATTACH database_kw_opt expr AS expr key_opt",
- /* 302 */ "cmd ::= DETACH database_kw_opt expr",
- /* 303 */ "key_opt ::=",
- /* 304 */ "key_opt ::= KEY expr",
- /* 305 */ "database_kw_opt ::= DATABASE",
- /* 306 */ "database_kw_opt ::=",
- /* 307 */ "cmd ::= REINDEX",
- /* 308 */ "cmd ::= REINDEX nm dbnm",
- /* 309 */ "cmd ::= ANALYZE",
- /* 310 */ "cmd ::= ANALYZE nm dbnm",
- /* 311 */ "cmd ::= ALTER TABLE fullname RENAME TO nm",
- /* 312 */ "cmd ::= ALTER TABLE add_column_fullname ADD kwcolumn_opt column",
- /* 313 */ "add_column_fullname ::= fullname",
- /* 314 */ "kwcolumn_opt ::=",
- /* 315 */ "kwcolumn_opt ::= COLUMNKW",
- /* 316 */ "cmd ::= create_vtab",
- /* 317 */ "cmd ::= create_vtab LP vtabarglist RP",
- /* 318 */ "create_vtab ::= createkw VIRTUAL TABLE nm dbnm USING nm",
- /* 319 */ "vtabarglist ::= vtabarg",
- /* 320 */ "vtabarglist ::= vtabarglist COMMA vtabarg",
- /* 321 */ "vtabarg ::=",
- /* 322 */ "vtabarg ::= vtabarg vtabargtoken",
- /* 323 */ "vtabargtoken ::= ANY",
- /* 324 */ "vtabargtoken ::= lp anylist RP",
- /* 325 */ "lp ::= LP",
- /* 326 */ "anylist ::=",
- /* 327 */ "anylist ::= anylist LP anylist RP",
- /* 328 */ "anylist ::= anylist ANY",
+ /* 268 */ "cmd ::= createkw trigger_decl BEGIN trigger_cmd_list END",
+ /* 269 */ "trigger_decl ::= temp TRIGGER ifnotexists nm dbnm trigger_time trigger_event ON fullname foreach_clause when_clause",
+ /* 270 */ "trigger_time ::= BEFORE",
+ /* 271 */ "trigger_time ::= AFTER",
+ /* 272 */ "trigger_time ::= INSTEAD OF",
+ /* 273 */ "trigger_time ::=",
+ /* 274 */ "trigger_event ::= DELETE|INSERT",
+ /* 275 */ "trigger_event ::= UPDATE",
+ /* 276 */ "trigger_event ::= UPDATE OF inscollist",
+ /* 277 */ "foreach_clause ::=",
+ /* 278 */ "foreach_clause ::= FOR EACH ROW",
+ /* 279 */ "when_clause ::=",
+ /* 280 */ "when_clause ::= WHEN expr",
+ /* 281 */ "trigger_cmd_list ::= trigger_cmd_list trigger_cmd SEMI",
+ /* 282 */ "trigger_cmd_list ::= trigger_cmd SEMI",
+ /* 283 */ "trnm ::= nm",
+ /* 284 */ "trnm ::= nm DOT nm",
+ /* 285 */ "tridxby ::=",
+ /* 286 */ "tridxby ::= INDEXED BY nm",
+ /* 287 */ "tridxby ::= NOT INDEXED",
+ /* 288 */ "trigger_cmd ::= UPDATE orconf trnm tridxby SET setlist where_opt",
+ /* 289 */ "trigger_cmd ::= insert_cmd INTO trnm inscollist_opt valuelist",
+ /* 290 */ "trigger_cmd ::= insert_cmd INTO trnm inscollist_opt select",
+ /* 291 */ "trigger_cmd ::= DELETE FROM trnm tridxby where_opt",
+ /* 292 */ "trigger_cmd ::= select",
+ /* 293 */ "expr ::= RAISE LP IGNORE RP",
+ /* 294 */ "expr ::= RAISE LP raisetype COMMA nm RP",
+ /* 295 */ "raisetype ::= ROLLBACK",
+ /* 296 */ "raisetype ::= ABORT",
+ /* 297 */ "raisetype ::= FAIL",
+ /* 298 */ "cmd ::= DROP TRIGGER ifexists fullname",
+ /* 299 */ "cmd ::= ATTACH database_kw_opt expr AS expr key_opt",
+ /* 300 */ "cmd ::= DETACH database_kw_opt expr",
+ /* 301 */ "key_opt ::=",
+ /* 302 */ "key_opt ::= KEY expr",
+ /* 303 */ "database_kw_opt ::= DATABASE",
+ /* 304 */ "database_kw_opt ::=",
+ /* 305 */ "cmd ::= REINDEX",
+ /* 306 */ "cmd ::= REINDEX nm dbnm",
+ /* 307 */ "cmd ::= ANALYZE",
+ /* 308 */ "cmd ::= ANALYZE nm dbnm",
+ /* 309 */ "cmd ::= ALTER TABLE fullname RENAME TO nm",
+ /* 310 */ "cmd ::= ALTER TABLE add_column_fullname ADD kwcolumn_opt column",
+ /* 311 */ "add_column_fullname ::= fullname",
+ /* 312 */ "kwcolumn_opt ::=",
+ /* 313 */ "kwcolumn_opt ::= COLUMNKW",
+ /* 314 */ "cmd ::= create_vtab",
+ /* 315 */ "cmd ::= create_vtab LP vtabarglist RP",
+ /* 316 */ "create_vtab ::= createkw VIRTUAL TABLE ifnotexists nm dbnm USING nm",
+ /* 317 */ "vtabarglist ::= vtabarg",
+ /* 318 */ "vtabarglist ::= vtabarglist COMMA vtabarg",
+ /* 319 */ "vtabarg ::=",
+ /* 320 */ "vtabarg ::= vtabarg vtabargtoken",
+ /* 321 */ "vtabargtoken ::= ANY",
+ /* 322 */ "vtabargtoken ::= lp anylist RP",
+ /* 323 */ "lp ::= LP",
+ /* 324 */ "anylist ::=",
+ /* 325 */ "anylist ::= anylist LP anylist RP",
+ /* 326 */ "anylist ::= anylist ANY",
};
#endif /* NDEBUG */
@@ -104735,29 +110049,28 @@ static void yy_destructor(
case 160: /* select */
case 194: /* oneselect */
{
-sqlite3SelectDelete(pParse->db, (yypminor->yy387));
+sqlite3SelectDelete(pParse->db, (yypminor->yy159));
}
break;
- case 174: /* term */
- case 175: /* expr */
+ case 173: /* term */
+ case 174: /* expr */
{
-sqlite3ExprDelete(pParse->db, (yypminor->yy118).pExpr);
+sqlite3ExprDelete(pParse->db, (yypminor->yy342).pExpr);
}
break;
- case 179: /* idxlist_opt */
+ case 178: /* idxlist_opt */
case 187: /* idxlist */
case 197: /* selcollist */
case 200: /* groupby_opt */
case 202: /* orderby_opt */
case 204: /* sclp */
case 214: /* sortlist */
- case 216: /* nexprlist */
- case 217: /* setlist */
- case 220: /* itemlist */
- case 221: /* exprlist */
- case 226: /* case_exprlist */
+ case 215: /* nexprlist */
+ case 216: /* setlist */
+ case 220: /* exprlist */
+ case 225: /* case_exprlist */
{
-sqlite3ExprListDelete(pParse->db, (yypminor->yy322));
+sqlite3ExprListDelete(pParse->db, (yypminor->yy442));
}
break;
case 193: /* fullname */
@@ -104765,37 +110078,44 @@ sqlite3ExprListDelete(pParse->db, (yypminor->yy322));
case 206: /* seltablist */
case 207: /* stl_prefix */
{
-sqlite3SrcListDelete(pParse->db, (yypminor->yy259));
+sqlite3SrcListDelete(pParse->db, (yypminor->yy347));
}
break;
case 199: /* where_opt */
case 201: /* having_opt */
case 210: /* on_opt */
- case 215: /* sortitem */
- case 225: /* case_operand */
- case 227: /* case_else */
- case 238: /* when_clause */
- case 243: /* key_opt */
+ case 224: /* case_operand */
+ case 226: /* case_else */
+ case 236: /* when_clause */
+ case 241: /* key_opt */
{
-sqlite3ExprDelete(pParse->db, (yypminor->yy314));
+sqlite3ExprDelete(pParse->db, (yypminor->yy122));
}
break;
case 211: /* using_opt */
case 213: /* inscollist */
- case 219: /* inscollist_opt */
+ case 218: /* inscollist_opt */
{
-sqlite3IdListDelete(pParse->db, (yypminor->yy384));
+sqlite3IdListDelete(pParse->db, (yypminor->yy180));
}
break;
- case 234: /* trigger_cmd_list */
- case 239: /* trigger_cmd */
+ case 219: /* valuelist */
{
-sqlite3DeleteTriggerStep(pParse->db, (yypminor->yy203));
+
+ sqlite3ExprListDelete(pParse->db, (yypminor->yy487).pList);
+ sqlite3SelectDelete(pParse->db, (yypminor->yy487).pSelect);
+
}
break;
- case 236: /* trigger_event */
+ case 232: /* trigger_cmd_list */
+ case 237: /* trigger_cmd */
{
-sqlite3IdListDelete(pParse->db, (yypminor->yy90).b);
+sqlite3DeleteTriggerStep(pParse->db, (yypminor->yy327));
+}
+ break;
+ case 234: /* trigger_event */
+{
+sqlite3IdListDelete(pParse->db, (yypminor->yy410).b);
}
break;
default: break; /* If no destructor action specified: do nothing */
@@ -104984,7 +110304,6 @@ static void yyStackOverflow(yyParser *yypParser, YYMINORTYPE *yypMinor){
UNUSED_PARAMETER(yypMinor); /* Silence some compiler warnings */
sqlite3ErrorMsg(pParse, "parser stack overflow");
- pParse->parseError = 1;
sqlite3ParserARG_STORE; /* Suppress warning about unused %extra_argument var */
}
@@ -105096,44 +110415,44 @@ static const struct {
{ 169, 1 },
{ 164, 2 },
{ 164, 0 },
+ { 172, 2 },
+ { 172, 2 },
+ { 172, 4 },
+ { 172, 3 },
+ { 172, 3 },
+ { 172, 2 },
+ { 172, 2 },
{ 172, 3 },
+ { 172, 5 },
+ { 172, 2 },
+ { 172, 4 },
+ { 172, 4 },
{ 172, 1 },
- { 173, 2 },
- { 173, 4 },
- { 173, 3 },
- { 173, 3 },
- { 173, 2 },
- { 173, 2 },
- { 173, 3 },
- { 173, 5 },
- { 173, 2 },
- { 173, 4 },
- { 173, 4 },
- { 173, 1 },
- { 173, 2 },
- { 178, 0 },
- { 178, 1 },
- { 180, 0 },
- { 180, 2 },
+ { 172, 2 },
+ { 177, 0 },
+ { 177, 1 },
+ { 179, 0 },
+ { 179, 2 },
+ { 181, 2 },
+ { 181, 3 },
+ { 181, 3 },
+ { 181, 3 },
{ 182, 2 },
- { 182, 3 },
- { 182, 3 },
- { 182, 3 },
- { 183, 2 },
+ { 182, 2 },
+ { 182, 1 },
+ { 182, 1 },
+ { 182, 2 },
+ { 180, 3 },
+ { 180, 2 },
+ { 183, 0 },
{ 183, 2 },
- { 183, 1 },
- { 183, 1 },
{ 183, 2 },
- { 181, 3 },
- { 181, 2 },
- { 184, 0 },
- { 184, 2 },
- { 184, 2 },
{ 159, 0 },
{ 159, 2 },
- { 185, 3 },
- { 185, 2 },
+ { 184, 3 },
+ { 184, 1 },
{ 185, 1 },
+ { 185, 0 },
{ 186, 2 },
{ 186, 7 },
{ 186, 5 },
@@ -105141,8 +110460,8 @@ static const struct {
{ 186, 10 },
{ 188, 0 },
{ 188, 1 },
- { 176, 0 },
- { 176, 3 },
+ { 175, 0 },
+ { 175, 3 },
{ 189, 0 },
{ 189, 2 },
{ 190, 1 },
@@ -105196,10 +110515,9 @@ static const struct {
{ 202, 3 },
{ 214, 4 },
{ 214, 2 },
- { 215, 1 },
- { 177, 1 },
- { 177, 1 },
- { 177, 0 },
+ { 176, 1 },
+ { 176, 1 },
+ { 176, 0 },
{ 200, 0 },
{ 200, 3 },
{ 201, 0 },
@@ -105212,87 +110530,87 @@ static const struct {
{ 199, 0 },
{ 199, 2 },
{ 147, 7 },
- { 217, 5 },
- { 217, 3 },
- { 147, 8 },
+ { 216, 5 },
+ { 216, 3 },
+ { 147, 5 },
{ 147, 5 },
{ 147, 6 },
- { 218, 2 },
- { 218, 1 },
- { 220, 3 },
- { 220, 1 },
- { 219, 0 },
- { 219, 3 },
+ { 217, 2 },
+ { 217, 1 },
+ { 219, 4 },
+ { 219, 5 },
+ { 218, 0 },
+ { 218, 3 },
{ 213, 3 },
{ 213, 1 },
- { 175, 1 },
- { 175, 3 },
{ 174, 1 },
- { 175, 1 },
- { 175, 1 },
- { 175, 3 },
- { 175, 5 },
+ { 174, 3 },
+ { 173, 1 },
{ 174, 1 },
{ 174, 1 },
- { 175, 1 },
- { 175, 1 },
- { 175, 3 },
- { 175, 6 },
- { 175, 5 },
- { 175, 4 },
+ { 174, 3 },
+ { 174, 5 },
+ { 173, 1 },
+ { 173, 1 },
{ 174, 1 },
- { 175, 3 },
- { 175, 3 },
- { 175, 3 },
- { 175, 3 },
- { 175, 3 },
- { 175, 3 },
- { 175, 3 },
- { 175, 3 },
- { 222, 1 },
- { 222, 2 },
+ { 174, 1 },
+ { 174, 3 },
+ { 174, 6 },
+ { 174, 5 },
+ { 174, 4 },
+ { 173, 1 },
+ { 174, 3 },
+ { 174, 3 },
+ { 174, 3 },
+ { 174, 3 },
+ { 174, 3 },
+ { 174, 3 },
+ { 174, 3 },
+ { 174, 3 },
+ { 221, 1 },
+ { 221, 2 },
+ { 221, 1 },
+ { 221, 2 },
+ { 174, 3 },
+ { 174, 5 },
+ { 174, 2 },
+ { 174, 3 },
+ { 174, 3 },
+ { 174, 4 },
+ { 174, 2 },
+ { 174, 2 },
+ { 174, 2 },
+ { 174, 2 },
{ 222, 1 },
{ 222, 2 },
- { 175, 3 },
- { 175, 5 },
- { 175, 2 },
- { 175, 3 },
- { 175, 3 },
- { 175, 4 },
- { 175, 2 },
- { 175, 2 },
- { 175, 2 },
- { 175, 2 },
+ { 174, 5 },
{ 223, 1 },
{ 223, 2 },
- { 175, 5 },
+ { 174, 5 },
+ { 174, 3 },
+ { 174, 5 },
+ { 174, 4 },
+ { 174, 4 },
+ { 174, 5 },
+ { 225, 5 },
+ { 225, 4 },
+ { 226, 2 },
+ { 226, 0 },
{ 224, 1 },
- { 224, 2 },
- { 175, 5 },
- { 175, 3 },
- { 175, 5 },
- { 175, 4 },
- { 175, 4 },
- { 175, 5 },
- { 226, 5 },
- { 226, 4 },
- { 227, 2 },
- { 227, 0 },
- { 225, 1 },
- { 225, 0 },
- { 221, 1 },
- { 221, 0 },
- { 216, 3 },
- { 216, 1 },
+ { 224, 0 },
+ { 220, 1 },
+ { 220, 0 },
+ { 215, 3 },
+ { 215, 1 },
{ 147, 11 },
- { 228, 1 },
- { 228, 0 },
- { 179, 0 },
- { 179, 3 },
+ { 227, 1 },
+ { 227, 0 },
+ { 178, 0 },
+ { 178, 3 },
{ 187, 5 },
{ 187, 3 },
- { 229, 0 },
- { 229, 2 },
+ { 228, 0 },
+ { 228, 2 },
{ 147, 4 },
{ 147, 1 },
{ 147, 2 },
@@ -105301,75 +110619,74 @@ static const struct {
{ 147, 6 },
{ 147, 5 },
{ 147, 6 },
- { 230, 1 },
- { 230, 1 },
- { 230, 1 },
- { 230, 1 },
- { 230, 1 },
+ { 229, 1 },
+ { 229, 1 },
+ { 229, 1 },
+ { 229, 1 },
+ { 229, 1 },
{ 170, 2 },
+ { 170, 1 },
{ 171, 2 },
- { 232, 1 },
- { 231, 1 },
- { 231, 0 },
+ { 230, 1 },
{ 147, 5 },
- { 233, 11 },
- { 235, 1 },
- { 235, 1 },
- { 235, 2 },
- { 235, 0 },
- { 236, 1 },
- { 236, 1 },
- { 236, 3 },
- { 237, 0 },
- { 237, 3 },
- { 238, 0 },
- { 238, 2 },
+ { 231, 11 },
+ { 233, 1 },
+ { 233, 1 },
+ { 233, 2 },
+ { 233, 0 },
+ { 234, 1 },
+ { 234, 1 },
{ 234, 3 },
- { 234, 2 },
- { 240, 1 },
- { 240, 3 },
- { 241, 0 },
- { 241, 3 },
- { 241, 2 },
- { 239, 7 },
- { 239, 8 },
- { 239, 5 },
- { 239, 5 },
- { 239, 1 },
- { 175, 4 },
- { 175, 6 },
+ { 235, 0 },
+ { 235, 3 },
+ { 236, 0 },
+ { 236, 2 },
+ { 232, 3 },
+ { 232, 2 },
+ { 238, 1 },
+ { 238, 3 },
+ { 239, 0 },
+ { 239, 3 },
+ { 239, 2 },
+ { 237, 7 },
+ { 237, 5 },
+ { 237, 5 },
+ { 237, 5 },
+ { 237, 1 },
+ { 174, 4 },
+ { 174, 6 },
{ 191, 1 },
{ 191, 1 },
{ 191, 1 },
{ 147, 4 },
{ 147, 6 },
{ 147, 3 },
- { 243, 0 },
- { 243, 2 },
- { 242, 1 },
- { 242, 0 },
+ { 241, 0 },
+ { 241, 2 },
+ { 240, 1 },
+ { 240, 0 },
{ 147, 1 },
{ 147, 3 },
{ 147, 1 },
{ 147, 3 },
{ 147, 6 },
{ 147, 6 },
- { 244, 1 },
- { 245, 0 },
- { 245, 1 },
+ { 242, 1 },
+ { 243, 0 },
+ { 243, 1 },
{ 147, 1 },
{ 147, 4 },
- { 246, 7 },
+ { 244, 8 },
+ { 245, 1 },
+ { 245, 3 },
+ { 246, 0 },
+ { 246, 2 },
{ 247, 1 },
{ 247, 3 },
- { 248, 0 },
- { 248, 2 },
- { 249, 1 },
- { 249, 3 },
- { 250, 1 },
- { 251, 0 },
- { 251, 4 },
- { 251, 2 },
+ { 248, 1 },
+ { 249, 0 },
+ { 249, 4 },
+ { 249, 2 },
};
static void yy_accept(yyParser*); /* Forward Declaration */
@@ -105437,17 +110754,17 @@ static void yy_reduce(
{ sqlite3FinishCoding(pParse); }
break;
case 9: /* cmd ::= BEGIN transtype trans_opt */
-{sqlite3BeginTransaction(pParse, yymsp[-1].minor.yy4);}
+{sqlite3BeginTransaction(pParse, yymsp[-1].minor.yy392);}
break;
case 13: /* transtype ::= */
-{yygotominor.yy4 = TK_DEFERRED;}
+{yygotominor.yy392 = TK_DEFERRED;}
break;
case 14: /* transtype ::= DEFERRED */
case 15: /* transtype ::= IMMEDIATE */ yytestcase(yyruleno==15);
case 16: /* transtype ::= EXCLUSIVE */ yytestcase(yyruleno==16);
case 115: /* multiselect_op ::= UNION */ yytestcase(yyruleno==115);
case 117: /* multiselect_op ::= EXCEPT|INTERSECT */ yytestcase(yyruleno==117);
-{yygotominor.yy4 = yymsp[0].major;}
+{yygotominor.yy392 = yymsp[0].major;}
break;
case 17: /* cmd ::= COMMIT trans_opt */
case 18: /* cmd ::= END trans_opt */ yytestcase(yyruleno==18);
@@ -105473,7 +110790,7 @@ static void yy_reduce(
break;
case 26: /* create_table ::= createkw temp TABLE ifnotexists nm dbnm */
{
- sqlite3StartTable(pParse,&yymsp[-1].minor.yy0,&yymsp[0].minor.yy0,yymsp[-4].minor.yy4,0,0,yymsp[-2].minor.yy4);
+ sqlite3StartTable(pParse,&yymsp[-1].minor.yy0,&yymsp[0].minor.yy0,yymsp[-4].minor.yy392,0,0,yymsp[-2].minor.yy392);
}
break;
case 27: /* createkw ::= CREATE */
@@ -105484,27 +110801,24 @@ static void yy_reduce(
break;
case 28: /* ifnotexists ::= */
case 31: /* temp ::= */ yytestcase(yyruleno==31);
- case 70: /* autoinc ::= */ yytestcase(yyruleno==70);
- case 83: /* defer_subclause ::= NOT DEFERRABLE init_deferred_pred_opt */ yytestcase(yyruleno==83);
- case 85: /* init_deferred_pred_opt ::= */ yytestcase(yyruleno==85);
- case 87: /* init_deferred_pred_opt ::= INITIALLY IMMEDIATE */ yytestcase(yyruleno==87);
+ case 69: /* autoinc ::= */ yytestcase(yyruleno==69);
+ case 82: /* defer_subclause ::= NOT DEFERRABLE init_deferred_pred_opt */ yytestcase(yyruleno==82);
+ case 84: /* init_deferred_pred_opt ::= */ yytestcase(yyruleno==84);
+ case 86: /* init_deferred_pred_opt ::= INITIALLY IMMEDIATE */ yytestcase(yyruleno==86);
case 98: /* defer_subclause_opt ::= */ yytestcase(yyruleno==98);
case 109: /* ifexists ::= */ yytestcase(yyruleno==109);
- case 120: /* distinct ::= ALL */ yytestcase(yyruleno==120);
- case 121: /* distinct ::= */ yytestcase(yyruleno==121);
- case 222: /* between_op ::= BETWEEN */ yytestcase(yyruleno==222);
- case 225: /* in_op ::= IN */ yytestcase(yyruleno==225);
-{yygotominor.yy4 = 0;}
+ case 221: /* between_op ::= BETWEEN */ yytestcase(yyruleno==221);
+ case 224: /* in_op ::= IN */ yytestcase(yyruleno==224);
+{yygotominor.yy392 = 0;}
break;
case 29: /* ifnotexists ::= IF NOT EXISTS */
case 30: /* temp ::= TEMP */ yytestcase(yyruleno==30);
- case 71: /* autoinc ::= AUTOINCR */ yytestcase(yyruleno==71);
- case 86: /* init_deferred_pred_opt ::= INITIALLY DEFERRED */ yytestcase(yyruleno==86);
+ case 70: /* autoinc ::= AUTOINCR */ yytestcase(yyruleno==70);
+ case 85: /* init_deferred_pred_opt ::= INITIALLY DEFERRED */ yytestcase(yyruleno==85);
case 108: /* ifexists ::= IF EXISTS */ yytestcase(yyruleno==108);
- case 119: /* distinct ::= DISTINCT */ yytestcase(yyruleno==119);
- case 223: /* between_op ::= NOT BETWEEN */ yytestcase(yyruleno==223);
- case 226: /* in_op ::= NOT IN */ yytestcase(yyruleno==226);
-{yygotominor.yy4 = 1;}
+ case 222: /* between_op ::= NOT BETWEEN */ yytestcase(yyruleno==222);
+ case 225: /* in_op ::= NOT IN */ yytestcase(yyruleno==225);
+{yygotominor.yy392 = 1;}
break;
case 32: /* create_table_args ::= LP columnlist conslist_opt RP */
{
@@ -105513,8 +110827,8 @@ static void yy_reduce(
break;
case 33: /* create_table_args ::= AS select */
{
- sqlite3EndTable(pParse,0,0,yymsp[0].minor.yy387);
- sqlite3SelectDelete(pParse->db, yymsp[0].minor.yy387);
+ sqlite3EndTable(pParse,0,0,yymsp[0].minor.yy159);
+ sqlite3SelectDelete(pParse->db, yymsp[0].minor.yy159);
}
break;
case 36: /* column ::= columnid type carglist */
@@ -105527,6 +110841,7 @@ static void yy_reduce(
{
sqlite3AddColumn(pParse,&yymsp[0].minor.yy0);
yygotominor.yy0 = yymsp[0].minor.yy0;
+ pParse->constraintName.n = 0;
}
break;
case 38: /* id ::= ID */
@@ -105541,16 +110856,17 @@ static void yy_reduce(
case 128: /* as ::= ids */ yytestcase(yyruleno==128);
case 138: /* dbnm ::= DOT nm */ yytestcase(yyruleno==138);
case 147: /* indexed_opt ::= INDEXED BY nm */ yytestcase(yyruleno==147);
- case 251: /* collate ::= COLLATE ids */ yytestcase(yyruleno==251);
- case 260: /* nmnum ::= plus_num */ yytestcase(yyruleno==260);
- case 261: /* nmnum ::= nm */ yytestcase(yyruleno==261);
- case 262: /* nmnum ::= ON */ yytestcase(yyruleno==262);
- case 263: /* nmnum ::= DELETE */ yytestcase(yyruleno==263);
- case 264: /* nmnum ::= DEFAULT */ yytestcase(yyruleno==264);
- case 265: /* plus_num ::= plus_opt number */ yytestcase(yyruleno==265);
+ case 250: /* collate ::= COLLATE ids */ yytestcase(yyruleno==250);
+ case 259: /* nmnum ::= plus_num */ yytestcase(yyruleno==259);
+ case 260: /* nmnum ::= nm */ yytestcase(yyruleno==260);
+ case 261: /* nmnum ::= ON */ yytestcase(yyruleno==261);
+ case 262: /* nmnum ::= DELETE */ yytestcase(yyruleno==262);
+ case 263: /* nmnum ::= DEFAULT */ yytestcase(yyruleno==263);
+ case 264: /* plus_num ::= PLUS number */ yytestcase(yyruleno==264);
+ case 265: /* plus_num ::= number */ yytestcase(yyruleno==265);
case 266: /* minus_num ::= MINUS number */ yytestcase(yyruleno==266);
case 267: /* number ::= INTEGER|FLOAT */ yytestcase(yyruleno==267);
- case 285: /* trnm ::= nm */ yytestcase(yyruleno==285);
+ case 283: /* trnm ::= nm */ yytestcase(yyruleno==283);
{yygotominor.yy0 = yymsp[0].minor.yy0;}
break;
case 45: /* type ::= typetoken */
@@ -105571,189 +110887,206 @@ static void yy_reduce(
case 50: /* typename ::= typename ids */
{yygotominor.yy0.z=yymsp[-1].minor.yy0.z; yygotominor.yy0.n=yymsp[0].minor.yy0.n+(int)(yymsp[0].minor.yy0.z-yymsp[-1].minor.yy0.z);}
break;
- case 57: /* ccons ::= DEFAULT term */
- case 59: /* ccons ::= DEFAULT PLUS term */ yytestcase(yyruleno==59);
-{sqlite3AddDefaultValue(pParse,&yymsp[0].minor.yy118);}
+ case 55: /* ccons ::= CONSTRAINT nm */
+ case 93: /* tcons ::= CONSTRAINT nm */ yytestcase(yyruleno==93);
+{pParse->constraintName = yymsp[0].minor.yy0;}
+ break;
+ case 56: /* ccons ::= DEFAULT term */
+ case 58: /* ccons ::= DEFAULT PLUS term */ yytestcase(yyruleno==58);
+{sqlite3AddDefaultValue(pParse,&yymsp[0].minor.yy342);}
break;
- case 58: /* ccons ::= DEFAULT LP expr RP */
-{sqlite3AddDefaultValue(pParse,&yymsp[-1].minor.yy118);}
+ case 57: /* ccons ::= DEFAULT LP expr RP */
+{sqlite3AddDefaultValue(pParse,&yymsp[-1].minor.yy342);}
break;
- case 60: /* ccons ::= DEFAULT MINUS term */
+ case 59: /* ccons ::= DEFAULT MINUS term */
{
ExprSpan v;
- v.pExpr = sqlite3PExpr(pParse, TK_UMINUS, yymsp[0].minor.yy118.pExpr, 0, 0);
+ v.pExpr = sqlite3PExpr(pParse, TK_UMINUS, yymsp[0].minor.yy342.pExpr, 0, 0);
v.zStart = yymsp[-1].minor.yy0.z;
- v.zEnd = yymsp[0].minor.yy118.zEnd;
+ v.zEnd = yymsp[0].minor.yy342.zEnd;
sqlite3AddDefaultValue(pParse,&v);
}
break;
- case 61: /* ccons ::= DEFAULT id */
+ case 60: /* ccons ::= DEFAULT id */
{
ExprSpan v;
spanExpr(&v, pParse, TK_STRING, &yymsp[0].minor.yy0);
sqlite3AddDefaultValue(pParse,&v);
}
break;
- case 63: /* ccons ::= NOT NULL onconf */
-{sqlite3AddNotNull(pParse, yymsp[0].minor.yy4);}
+ case 62: /* ccons ::= NOT NULL onconf */
+{sqlite3AddNotNull(pParse, yymsp[0].minor.yy392);}
break;
- case 64: /* ccons ::= PRIMARY KEY sortorder onconf autoinc */
-{sqlite3AddPrimaryKey(pParse,0,yymsp[-1].minor.yy4,yymsp[0].minor.yy4,yymsp[-2].minor.yy4);}
+ case 63: /* ccons ::= PRIMARY KEY sortorder onconf autoinc */
+{sqlite3AddPrimaryKey(pParse,0,yymsp[-1].minor.yy392,yymsp[0].minor.yy392,yymsp[-2].minor.yy392);}
break;
- case 65: /* ccons ::= UNIQUE onconf */
-{sqlite3CreateIndex(pParse,0,0,0,0,yymsp[0].minor.yy4,0,0,0,0);}
+ case 64: /* ccons ::= UNIQUE onconf */
+{sqlite3CreateIndex(pParse,0,0,0,0,yymsp[0].minor.yy392,0,0,0,0);}
break;
- case 66: /* ccons ::= CHECK LP expr RP */
-{sqlite3AddCheckConstraint(pParse,yymsp[-1].minor.yy118.pExpr);}
+ case 65: /* ccons ::= CHECK LP expr RP */
+{sqlite3AddCheckConstraint(pParse,yymsp[-1].minor.yy342.pExpr);}
break;
- case 67: /* ccons ::= REFERENCES nm idxlist_opt refargs */
-{sqlite3CreateForeignKey(pParse,0,&yymsp[-2].minor.yy0,yymsp[-1].minor.yy322,yymsp[0].minor.yy4);}
+ case 66: /* ccons ::= REFERENCES nm idxlist_opt refargs */
+{sqlite3CreateForeignKey(pParse,0,&yymsp[-2].minor.yy0,yymsp[-1].minor.yy442,yymsp[0].minor.yy392);}
break;
- case 68: /* ccons ::= defer_subclause */
-{sqlite3DeferForeignKey(pParse,yymsp[0].minor.yy4);}
+ case 67: /* ccons ::= defer_subclause */
+{sqlite3DeferForeignKey(pParse,yymsp[0].minor.yy392);}
break;
- case 69: /* ccons ::= COLLATE ids */
+ case 68: /* ccons ::= COLLATE ids */
{sqlite3AddCollateType(pParse, &yymsp[0].minor.yy0);}
break;
- case 72: /* refargs ::= */
-{ yygotominor.yy4 = OE_None*0x0101; /* EV: R-19803-45884 */}
+ case 71: /* refargs ::= */
+{ yygotominor.yy392 = OE_None*0x0101; /* EV: R-19803-45884 */}
break;
- case 73: /* refargs ::= refargs refarg */
-{ yygotominor.yy4 = (yymsp[-1].minor.yy4 & ~yymsp[0].minor.yy215.mask) | yymsp[0].minor.yy215.value; }
+ case 72: /* refargs ::= refargs refarg */
+{ yygotominor.yy392 = (yymsp[-1].minor.yy392 & ~yymsp[0].minor.yy207.mask) | yymsp[0].minor.yy207.value; }
break;
- case 74: /* refarg ::= MATCH nm */
- case 75: /* refarg ::= ON INSERT refact */ yytestcase(yyruleno==75);
-{ yygotominor.yy215.value = 0; yygotominor.yy215.mask = 0x000000; }
+ case 73: /* refarg ::= MATCH nm */
+ case 74: /* refarg ::= ON INSERT refact */ yytestcase(yyruleno==74);
+{ yygotominor.yy207.value = 0; yygotominor.yy207.mask = 0x000000; }
break;
- case 76: /* refarg ::= ON DELETE refact */
-{ yygotominor.yy215.value = yymsp[0].minor.yy4; yygotominor.yy215.mask = 0x0000ff; }
+ case 75: /* refarg ::= ON DELETE refact */
+{ yygotominor.yy207.value = yymsp[0].minor.yy392; yygotominor.yy207.mask = 0x0000ff; }
break;
- case 77: /* refarg ::= ON UPDATE refact */
-{ yygotominor.yy215.value = yymsp[0].minor.yy4<<8; yygotominor.yy215.mask = 0x00ff00; }
+ case 76: /* refarg ::= ON UPDATE refact */
+{ yygotominor.yy207.value = yymsp[0].minor.yy392<<8; yygotominor.yy207.mask = 0x00ff00; }
break;
- case 78: /* refact ::= SET NULL */
-{ yygotominor.yy4 = OE_SetNull; /* EV: R-33326-45252 */}
+ case 77: /* refact ::= SET NULL */
+{ yygotominor.yy392 = OE_SetNull; /* EV: R-33326-45252 */}
break;
- case 79: /* refact ::= SET DEFAULT */
-{ yygotominor.yy4 = OE_SetDflt; /* EV: R-33326-45252 */}
+ case 78: /* refact ::= SET DEFAULT */
+{ yygotominor.yy392 = OE_SetDflt; /* EV: R-33326-45252 */}
break;
- case 80: /* refact ::= CASCADE */
-{ yygotominor.yy4 = OE_Cascade; /* EV: R-33326-45252 */}
+ case 79: /* refact ::= CASCADE */
+{ yygotominor.yy392 = OE_Cascade; /* EV: R-33326-45252 */}
break;
- case 81: /* refact ::= RESTRICT */
-{ yygotominor.yy4 = OE_Restrict; /* EV: R-33326-45252 */}
+ case 80: /* refact ::= RESTRICT */
+{ yygotominor.yy392 = OE_Restrict; /* EV: R-33326-45252 */}
break;
- case 82: /* refact ::= NO ACTION */
-{ yygotominor.yy4 = OE_None; /* EV: R-33326-45252 */}
+ case 81: /* refact ::= NO ACTION */
+{ yygotominor.yy392 = OE_None; /* EV: R-33326-45252 */}
break;
- case 84: /* defer_subclause ::= DEFERRABLE init_deferred_pred_opt */
+ case 83: /* defer_subclause ::= DEFERRABLE init_deferred_pred_opt */
case 99: /* defer_subclause_opt ::= defer_subclause */ yytestcase(yyruleno==99);
case 101: /* onconf ::= ON CONFLICT resolvetype */ yytestcase(yyruleno==101);
case 104: /* resolvetype ::= raisetype */ yytestcase(yyruleno==104);
-{yygotominor.yy4 = yymsp[0].minor.yy4;}
+{yygotominor.yy392 = yymsp[0].minor.yy392;}
break;
- case 88: /* conslist_opt ::= */
+ case 87: /* conslist_opt ::= */
{yygotominor.yy0.n = 0; yygotominor.yy0.z = 0;}
break;
- case 89: /* conslist_opt ::= COMMA conslist */
+ case 88: /* conslist_opt ::= COMMA conslist */
{yygotominor.yy0 = yymsp[-1].minor.yy0;}
break;
+ case 91: /* tconscomma ::= COMMA */
+{pParse->constraintName.n = 0;}
+ break;
case 94: /* tcons ::= PRIMARY KEY LP idxlist autoinc RP onconf */
-{sqlite3AddPrimaryKey(pParse,yymsp[-3].minor.yy322,yymsp[0].minor.yy4,yymsp[-2].minor.yy4,0);}
+{sqlite3AddPrimaryKey(pParse,yymsp[-3].minor.yy442,yymsp[0].minor.yy392,yymsp[-2].minor.yy392,0);}
break;
case 95: /* tcons ::= UNIQUE LP idxlist RP onconf */
-{sqlite3CreateIndex(pParse,0,0,0,yymsp[-2].minor.yy322,yymsp[0].minor.yy4,0,0,0,0);}
+{sqlite3CreateIndex(pParse,0,0,0,yymsp[-2].minor.yy442,yymsp[0].minor.yy392,0,0,0,0);}
break;
case 96: /* tcons ::= CHECK LP expr RP onconf */
-{sqlite3AddCheckConstraint(pParse,yymsp[-2].minor.yy118.pExpr);}
+{sqlite3AddCheckConstraint(pParse,yymsp[-2].minor.yy342.pExpr);}
break;
case 97: /* tcons ::= FOREIGN KEY LP idxlist RP REFERENCES nm idxlist_opt refargs defer_subclause_opt */
{
- sqlite3CreateForeignKey(pParse, yymsp[-6].minor.yy322, &yymsp[-3].minor.yy0, yymsp[-2].minor.yy322, yymsp[-1].minor.yy4);
- sqlite3DeferForeignKey(pParse, yymsp[0].minor.yy4);
+ sqlite3CreateForeignKey(pParse, yymsp[-6].minor.yy442, &yymsp[-3].minor.yy0, yymsp[-2].minor.yy442, yymsp[-1].minor.yy392);
+ sqlite3DeferForeignKey(pParse, yymsp[0].minor.yy392);
}
break;
case 100: /* onconf ::= */
-{yygotominor.yy4 = OE_Default;}
+{yygotominor.yy392 = OE_Default;}
break;
case 102: /* orconf ::= */
-{yygotominor.yy210 = OE_Default;}
+{yygotominor.yy258 = OE_Default;}
break;
case 103: /* orconf ::= OR resolvetype */
-{yygotominor.yy210 = (u8)yymsp[0].minor.yy4;}
+{yygotominor.yy258 = (u8)yymsp[0].minor.yy392;}
break;
case 105: /* resolvetype ::= IGNORE */
-{yygotominor.yy4 = OE_Ignore;}
+{yygotominor.yy392 = OE_Ignore;}
break;
case 106: /* resolvetype ::= REPLACE */
-{yygotominor.yy4 = OE_Replace;}
+{yygotominor.yy392 = OE_Replace;}
break;
case 107: /* cmd ::= DROP TABLE ifexists fullname */
{
- sqlite3DropTable(pParse, yymsp[0].minor.yy259, 0, yymsp[-1].minor.yy4);
+ sqlite3DropTable(pParse, yymsp[0].minor.yy347, 0, yymsp[-1].minor.yy392);
}
break;
case 110: /* cmd ::= createkw temp VIEW ifnotexists nm dbnm AS select */
{
- sqlite3CreateView(pParse, &yymsp[-7].minor.yy0, &yymsp[-3].minor.yy0, &yymsp[-2].minor.yy0, yymsp[0].minor.yy387, yymsp[-6].minor.yy4, yymsp[-4].minor.yy4);
+ sqlite3CreateView(pParse, &yymsp[-7].minor.yy0, &yymsp[-3].minor.yy0, &yymsp[-2].minor.yy0, yymsp[0].minor.yy159, yymsp[-6].minor.yy392, yymsp[-4].minor.yy392);
}
break;
case 111: /* cmd ::= DROP VIEW ifexists fullname */
{
- sqlite3DropTable(pParse, yymsp[0].minor.yy259, 1, yymsp[-1].minor.yy4);
+ sqlite3DropTable(pParse, yymsp[0].minor.yy347, 1, yymsp[-1].minor.yy392);
}
break;
case 112: /* cmd ::= select */
{
SelectDest dest = {SRT_Output, 0, 0, 0, 0};
- sqlite3Select(pParse, yymsp[0].minor.yy387, &dest);
- sqlite3SelectDelete(pParse->db, yymsp[0].minor.yy387);
+ sqlite3Select(pParse, yymsp[0].minor.yy159, &dest);
+ sqlite3ExplainBegin(pParse->pVdbe);
+ sqlite3ExplainSelect(pParse->pVdbe, yymsp[0].minor.yy159);
+ sqlite3ExplainFinish(pParse->pVdbe);
+ sqlite3SelectDelete(pParse->db, yymsp[0].minor.yy159);
}
break;
case 113: /* select ::= oneselect */
-{yygotominor.yy387 = yymsp[0].minor.yy387;}
+{yygotominor.yy159 = yymsp[0].minor.yy159;}
break;
case 114: /* select ::= select multiselect_op oneselect */
{
- if( yymsp[0].minor.yy387 ){
- yymsp[0].minor.yy387->op = (u8)yymsp[-1].minor.yy4;
- yymsp[0].minor.yy387->pPrior = yymsp[-2].minor.yy387;
+ if( yymsp[0].minor.yy159 ){
+ yymsp[0].minor.yy159->op = (u8)yymsp[-1].minor.yy392;
+ yymsp[0].minor.yy159->pPrior = yymsp[-2].minor.yy159;
}else{
- sqlite3SelectDelete(pParse->db, yymsp[-2].minor.yy387);
+ sqlite3SelectDelete(pParse->db, yymsp[-2].minor.yy159);
}
- yygotominor.yy387 = yymsp[0].minor.yy387;
+ yygotominor.yy159 = yymsp[0].minor.yy159;
}
break;
case 116: /* multiselect_op ::= UNION ALL */
-{yygotominor.yy4 = TK_ALL;}
+{yygotominor.yy392 = TK_ALL;}
break;
case 118: /* oneselect ::= SELECT distinct selcollist from where_opt groupby_opt having_opt orderby_opt limit_opt */
{
- yygotominor.yy387 = sqlite3SelectNew(pParse,yymsp[-6].minor.yy322,yymsp[-5].minor.yy259,yymsp[-4].minor.yy314,yymsp[-3].minor.yy322,yymsp[-2].minor.yy314,yymsp[-1].minor.yy322,yymsp[-7].minor.yy4,yymsp[0].minor.yy292.pLimit,yymsp[0].minor.yy292.pOffset);
+ yygotominor.yy159 = sqlite3SelectNew(pParse,yymsp[-6].minor.yy442,yymsp[-5].minor.yy347,yymsp[-4].minor.yy122,yymsp[-3].minor.yy442,yymsp[-2].minor.yy122,yymsp[-1].minor.yy442,yymsp[-7].minor.yy305,yymsp[0].minor.yy64.pLimit,yymsp[0].minor.yy64.pOffset);
}
break;
+ case 119: /* distinct ::= DISTINCT */
+{yygotominor.yy305 = SF_Distinct;}
+ break;
+ case 120: /* distinct ::= ALL */
+ case 121: /* distinct ::= */ yytestcase(yyruleno==121);
+{yygotominor.yy305 = 0;}
+ break;
case 122: /* sclp ::= selcollist COMMA */
- case 247: /* idxlist_opt ::= LP idxlist RP */ yytestcase(yyruleno==247);
-{yygotominor.yy322 = yymsp[-1].minor.yy322;}
+ case 246: /* idxlist_opt ::= LP idxlist RP */ yytestcase(yyruleno==246);
+{yygotominor.yy442 = yymsp[-1].minor.yy442;}
break;
case 123: /* sclp ::= */
case 151: /* orderby_opt ::= */ yytestcase(yyruleno==151);
- case 159: /* groupby_opt ::= */ yytestcase(yyruleno==159);
- case 240: /* exprlist ::= */ yytestcase(yyruleno==240);
- case 246: /* idxlist_opt ::= */ yytestcase(yyruleno==246);
-{yygotominor.yy322 = 0;}
+ case 158: /* groupby_opt ::= */ yytestcase(yyruleno==158);
+ case 239: /* exprlist ::= */ yytestcase(yyruleno==239);
+ case 245: /* idxlist_opt ::= */ yytestcase(yyruleno==245);
+{yygotominor.yy442 = 0;}
break;
case 124: /* selcollist ::= sclp expr as */
{
- yygotominor.yy322 = sqlite3ExprListAppend(pParse, yymsp[-2].minor.yy322, yymsp[-1].minor.yy118.pExpr);
- if( yymsp[0].minor.yy0.n>0 ) sqlite3ExprListSetName(pParse, yygotominor.yy322, &yymsp[0].minor.yy0, 1);
- sqlite3ExprListSetSpan(pParse,yygotominor.yy322,&yymsp[-1].minor.yy118);
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse, yymsp[-2].minor.yy442, yymsp[-1].minor.yy342.pExpr);
+ if( yymsp[0].minor.yy0.n>0 ) sqlite3ExprListSetName(pParse, yygotominor.yy442, &yymsp[0].minor.yy0, 1);
+ sqlite3ExprListSetSpan(pParse,yygotominor.yy442,&yymsp[-1].minor.yy342);
}
break;
case 125: /* selcollist ::= sclp STAR */
{
Expr *p = sqlite3Expr(pParse->db, TK_ALL, 0);
- yygotominor.yy322 = sqlite3ExprListAppend(pParse, yymsp[-1].minor.yy322, p);
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse, yymsp[-1].minor.yy442, p);
}
break;
case 126: /* selcollist ::= sclp nm DOT STAR */
@@ -105761,50 +111094,60 @@ static void yy_reduce(
Expr *pRight = sqlite3PExpr(pParse, TK_ALL, 0, 0, &yymsp[0].minor.yy0);
Expr *pLeft = sqlite3PExpr(pParse, TK_ID, 0, 0, &yymsp[-2].minor.yy0);
Expr *pDot = sqlite3PExpr(pParse, TK_DOT, pLeft, pRight, 0);
- yygotominor.yy322 = sqlite3ExprListAppend(pParse,yymsp[-3].minor.yy322, pDot);
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse,yymsp[-3].minor.yy442, pDot);
}
break;
case 129: /* as ::= */
{yygotominor.yy0.n = 0;}
break;
case 130: /* from ::= */
-{yygotominor.yy259 = sqlite3DbMallocZero(pParse->db, sizeof(*yygotominor.yy259));}
+{yygotominor.yy347 = sqlite3DbMallocZero(pParse->db, sizeof(*yygotominor.yy347));}
break;
case 131: /* from ::= FROM seltablist */
{
- yygotominor.yy259 = yymsp[0].minor.yy259;
- sqlite3SrcListShiftJoinType(yygotominor.yy259);
+ yygotominor.yy347 = yymsp[0].minor.yy347;
+ sqlite3SrcListShiftJoinType(yygotominor.yy347);
}
break;
case 132: /* stl_prefix ::= seltablist joinop */
{
- yygotominor.yy259 = yymsp[-1].minor.yy259;
- if( ALWAYS(yygotominor.yy259 && yygotominor.yy259->nSrc>0) ) yygotominor.yy259->a[yygotominor.yy259->nSrc-1].jointype = (u8)yymsp[0].minor.yy4;
+ yygotominor.yy347 = yymsp[-1].minor.yy347;
+ if( ALWAYS(yygotominor.yy347 && yygotominor.yy347->nSrc>0) ) yygotominor.yy347->a[yygotominor.yy347->nSrc-1].jointype = (u8)yymsp[0].minor.yy392;
}
break;
case 133: /* stl_prefix ::= */
-{yygotominor.yy259 = 0;}
+{yygotominor.yy347 = 0;}
break;
case 134: /* seltablist ::= stl_prefix nm dbnm as indexed_opt on_opt using_opt */
{
- yygotominor.yy259 = sqlite3SrcListAppendFromTerm(pParse,yymsp[-6].minor.yy259,&yymsp[-5].minor.yy0,&yymsp[-4].minor.yy0,&yymsp[-3].minor.yy0,0,yymsp[-1].minor.yy314,yymsp[0].minor.yy384);
- sqlite3SrcListIndexedBy(pParse, yygotominor.yy259, &yymsp[-2].minor.yy0);
+ yygotominor.yy347 = sqlite3SrcListAppendFromTerm(pParse,yymsp[-6].minor.yy347,&yymsp[-5].minor.yy0,&yymsp[-4].minor.yy0,&yymsp[-3].minor.yy0,0,yymsp[-1].minor.yy122,yymsp[0].minor.yy180);
+ sqlite3SrcListIndexedBy(pParse, yygotominor.yy347, &yymsp[-2].minor.yy0);
}
break;
case 135: /* seltablist ::= stl_prefix LP select RP as on_opt using_opt */
{
- yygotominor.yy259 = sqlite3SrcListAppendFromTerm(pParse,yymsp[-6].minor.yy259,0,0,&yymsp[-2].minor.yy0,yymsp[-4].minor.yy387,yymsp[-1].minor.yy314,yymsp[0].minor.yy384);
+ yygotominor.yy347 = sqlite3SrcListAppendFromTerm(pParse,yymsp[-6].minor.yy347,0,0,&yymsp[-2].minor.yy0,yymsp[-4].minor.yy159,yymsp[-1].minor.yy122,yymsp[0].minor.yy180);
}
break;
case 136: /* seltablist ::= stl_prefix LP seltablist RP as on_opt using_opt */
{
- if( yymsp[-6].minor.yy259==0 && yymsp[-2].minor.yy0.n==0 && yymsp[-1].minor.yy314==0 && yymsp[0].minor.yy384==0 ){
- yygotominor.yy259 = yymsp[-4].minor.yy259;
+ if( yymsp[-6].minor.yy347==0 && yymsp[-2].minor.yy0.n==0 && yymsp[-1].minor.yy122==0 && yymsp[0].minor.yy180==0 ){
+ yygotominor.yy347 = yymsp[-4].minor.yy347;
+ }else if( yymsp[-4].minor.yy347->nSrc==1 ){
+ yygotominor.yy347 = sqlite3SrcListAppendFromTerm(pParse,yymsp[-6].minor.yy347,0,0,&yymsp[-2].minor.yy0,0,yymsp[-1].minor.yy122,yymsp[0].minor.yy180);
+ if( yygotominor.yy347 ){
+ struct SrcList_item *pNew = &yygotominor.yy347->a[yygotominor.yy347->nSrc-1];
+ struct SrcList_item *pOld = yymsp[-4].minor.yy347->a;
+ pNew->zName = pOld->zName;
+ pNew->zDatabase = pOld->zDatabase;
+ pOld->zName = pOld->zDatabase = 0;
+ }
+ sqlite3SrcListDelete(pParse->db, yymsp[-4].minor.yy347);
}else{
Select *pSubquery;
- sqlite3SrcListShiftJoinType(yymsp[-4].minor.yy259);
- pSubquery = sqlite3SelectNew(pParse,0,yymsp[-4].minor.yy259,0,0,0,0,0,0,0);
- yygotominor.yy259 = sqlite3SrcListAppendFromTerm(pParse,yymsp[-6].minor.yy259,0,0,&yymsp[-2].minor.yy0,pSubquery,yymsp[-1].minor.yy314,yymsp[0].minor.yy384);
+ sqlite3SrcListShiftJoinType(yymsp[-4].minor.yy347);
+ pSubquery = sqlite3SelectNew(pParse,0,yymsp[-4].minor.yy347,0,0,0,0,SF_NestedFrom,0,0);
+ yygotominor.yy347 = sqlite3SrcListAppendFromTerm(pParse,yymsp[-6].minor.yy347,0,0,&yymsp[-2].minor.yy0,pSubquery,yymsp[-1].minor.yy122,yymsp[0].minor.yy180);
}
}
break;
@@ -105813,322 +111156,340 @@ static void yy_reduce(
{yygotominor.yy0.z=0; yygotominor.yy0.n=0;}
break;
case 139: /* fullname ::= nm dbnm */
-{yygotominor.yy259 = sqlite3SrcListAppend(pParse->db,0,&yymsp[-1].minor.yy0,&yymsp[0].minor.yy0);}
+{yygotominor.yy347 = sqlite3SrcListAppend(pParse->db,0,&yymsp[-1].minor.yy0,&yymsp[0].minor.yy0);}
break;
case 140: /* joinop ::= COMMA|JOIN */
-{ yygotominor.yy4 = JT_INNER; }
+{ yygotominor.yy392 = JT_INNER; }
break;
case 141: /* joinop ::= JOIN_KW JOIN */
-{ yygotominor.yy4 = sqlite3JoinType(pParse,&yymsp[-1].minor.yy0,0,0); }
+{ yygotominor.yy392 = sqlite3JoinType(pParse,&yymsp[-1].minor.yy0,0,0); }
break;
case 142: /* joinop ::= JOIN_KW nm JOIN */
-{ yygotominor.yy4 = sqlite3JoinType(pParse,&yymsp[-2].minor.yy0,&yymsp[-1].minor.yy0,0); }
+{ yygotominor.yy392 = sqlite3JoinType(pParse,&yymsp[-2].minor.yy0,&yymsp[-1].minor.yy0,0); }
break;
case 143: /* joinop ::= JOIN_KW nm nm JOIN */
-{ yygotominor.yy4 = sqlite3JoinType(pParse,&yymsp[-3].minor.yy0,&yymsp[-2].minor.yy0,&yymsp[-1].minor.yy0); }
+{ yygotominor.yy392 = sqlite3JoinType(pParse,&yymsp[-3].minor.yy0,&yymsp[-2].minor.yy0,&yymsp[-1].minor.yy0); }
break;
case 144: /* on_opt ::= ON expr */
- case 155: /* sortitem ::= expr */ yytestcase(yyruleno==155);
- case 162: /* having_opt ::= HAVING expr */ yytestcase(yyruleno==162);
- case 169: /* where_opt ::= WHERE expr */ yytestcase(yyruleno==169);
- case 235: /* case_else ::= ELSE expr */ yytestcase(yyruleno==235);
- case 237: /* case_operand ::= expr */ yytestcase(yyruleno==237);
-{yygotominor.yy314 = yymsp[0].minor.yy118.pExpr;}
+ case 161: /* having_opt ::= HAVING expr */ yytestcase(yyruleno==161);
+ case 168: /* where_opt ::= WHERE expr */ yytestcase(yyruleno==168);
+ case 234: /* case_else ::= ELSE expr */ yytestcase(yyruleno==234);
+ case 236: /* case_operand ::= expr */ yytestcase(yyruleno==236);
+{yygotominor.yy122 = yymsp[0].minor.yy342.pExpr;}
break;
case 145: /* on_opt ::= */
- case 161: /* having_opt ::= */ yytestcase(yyruleno==161);
- case 168: /* where_opt ::= */ yytestcase(yyruleno==168);
- case 236: /* case_else ::= */ yytestcase(yyruleno==236);
- case 238: /* case_operand ::= */ yytestcase(yyruleno==238);
-{yygotominor.yy314 = 0;}
+ case 160: /* having_opt ::= */ yytestcase(yyruleno==160);
+ case 167: /* where_opt ::= */ yytestcase(yyruleno==167);
+ case 235: /* case_else ::= */ yytestcase(yyruleno==235);
+ case 237: /* case_operand ::= */ yytestcase(yyruleno==237);
+{yygotominor.yy122 = 0;}
break;
case 148: /* indexed_opt ::= NOT INDEXED */
{yygotominor.yy0.z=0; yygotominor.yy0.n=1;}
break;
case 149: /* using_opt ::= USING LP inscollist RP */
- case 181: /* inscollist_opt ::= LP inscollist RP */ yytestcase(yyruleno==181);
-{yygotominor.yy384 = yymsp[-1].minor.yy384;}
+ case 180: /* inscollist_opt ::= LP inscollist RP */ yytestcase(yyruleno==180);
+{yygotominor.yy180 = yymsp[-1].minor.yy180;}
break;
case 150: /* using_opt ::= */
- case 180: /* inscollist_opt ::= */ yytestcase(yyruleno==180);
-{yygotominor.yy384 = 0;}
+ case 179: /* inscollist_opt ::= */ yytestcase(yyruleno==179);
+{yygotominor.yy180 = 0;}
break;
case 152: /* orderby_opt ::= ORDER BY sortlist */
- case 160: /* groupby_opt ::= GROUP BY nexprlist */ yytestcase(yyruleno==160);
- case 239: /* exprlist ::= nexprlist */ yytestcase(yyruleno==239);
-{yygotominor.yy322 = yymsp[0].minor.yy322;}
+ case 159: /* groupby_opt ::= GROUP BY nexprlist */ yytestcase(yyruleno==159);
+ case 238: /* exprlist ::= nexprlist */ yytestcase(yyruleno==238);
+{yygotominor.yy442 = yymsp[0].minor.yy442;}
break;
- case 153: /* sortlist ::= sortlist COMMA sortitem sortorder */
+ case 153: /* sortlist ::= sortlist COMMA expr sortorder */
{
- yygotominor.yy322 = sqlite3ExprListAppend(pParse,yymsp[-3].minor.yy322,yymsp[-1].minor.yy314);
- if( yygotominor.yy322 ) yygotominor.yy322->a[yygotominor.yy322->nExpr-1].sortOrder = (u8)yymsp[0].minor.yy4;
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse,yymsp[-3].minor.yy442,yymsp[-1].minor.yy342.pExpr);
+ if( yygotominor.yy442 ) yygotominor.yy442->a[yygotominor.yy442->nExpr-1].sortOrder = (u8)yymsp[0].minor.yy392;
}
break;
- case 154: /* sortlist ::= sortitem sortorder */
+ case 154: /* sortlist ::= expr sortorder */
{
- yygotominor.yy322 = sqlite3ExprListAppend(pParse,0,yymsp[-1].minor.yy314);
- if( yygotominor.yy322 && ALWAYS(yygotominor.yy322->a) ) yygotominor.yy322->a[0].sortOrder = (u8)yymsp[0].minor.yy4;
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse,0,yymsp[-1].minor.yy342.pExpr);
+ if( yygotominor.yy442 && ALWAYS(yygotominor.yy442->a) ) yygotominor.yy442->a[0].sortOrder = (u8)yymsp[0].minor.yy392;
}
break;
- case 156: /* sortorder ::= ASC */
- case 158: /* sortorder ::= */ yytestcase(yyruleno==158);
-{yygotominor.yy4 = SQLITE_SO_ASC;}
+ case 155: /* sortorder ::= ASC */
+ case 157: /* sortorder ::= */ yytestcase(yyruleno==157);
+{yygotominor.yy392 = SQLITE_SO_ASC;}
break;
- case 157: /* sortorder ::= DESC */
-{yygotominor.yy4 = SQLITE_SO_DESC;}
+ case 156: /* sortorder ::= DESC */
+{yygotominor.yy392 = SQLITE_SO_DESC;}
break;
- case 163: /* limit_opt ::= */
-{yygotominor.yy292.pLimit = 0; yygotominor.yy292.pOffset = 0;}
+ case 162: /* limit_opt ::= */
+{yygotominor.yy64.pLimit = 0; yygotominor.yy64.pOffset = 0;}
break;
- case 164: /* limit_opt ::= LIMIT expr */
-{yygotominor.yy292.pLimit = yymsp[0].minor.yy118.pExpr; yygotominor.yy292.pOffset = 0;}
+ case 163: /* limit_opt ::= LIMIT expr */
+{yygotominor.yy64.pLimit = yymsp[0].minor.yy342.pExpr; yygotominor.yy64.pOffset = 0;}
break;
- case 165: /* limit_opt ::= LIMIT expr OFFSET expr */
-{yygotominor.yy292.pLimit = yymsp[-2].minor.yy118.pExpr; yygotominor.yy292.pOffset = yymsp[0].minor.yy118.pExpr;}
+ case 164: /* limit_opt ::= LIMIT expr OFFSET expr */
+{yygotominor.yy64.pLimit = yymsp[-2].minor.yy342.pExpr; yygotominor.yy64.pOffset = yymsp[0].minor.yy342.pExpr;}
break;
- case 166: /* limit_opt ::= LIMIT expr COMMA expr */
-{yygotominor.yy292.pOffset = yymsp[-2].minor.yy118.pExpr; yygotominor.yy292.pLimit = yymsp[0].minor.yy118.pExpr;}
+ case 165: /* limit_opt ::= LIMIT expr COMMA expr */
+{yygotominor.yy64.pOffset = yymsp[-2].minor.yy342.pExpr; yygotominor.yy64.pLimit = yymsp[0].minor.yy342.pExpr;}
break;
- case 167: /* cmd ::= DELETE FROM fullname indexed_opt where_opt */
+ case 166: /* cmd ::= DELETE FROM fullname indexed_opt where_opt */
{
- sqlite3SrcListIndexedBy(pParse, yymsp[-2].minor.yy259, &yymsp[-1].minor.yy0);
- sqlite3DeleteFrom(pParse,yymsp[-2].minor.yy259,yymsp[0].minor.yy314);
+ sqlite3SrcListIndexedBy(pParse, yymsp[-2].minor.yy347, &yymsp[-1].minor.yy0);
+ sqlite3DeleteFrom(pParse,yymsp[-2].minor.yy347,yymsp[0].minor.yy122);
}
break;
- case 170: /* cmd ::= UPDATE orconf fullname indexed_opt SET setlist where_opt */
+ case 169: /* cmd ::= UPDATE orconf fullname indexed_opt SET setlist where_opt */
{
- sqlite3SrcListIndexedBy(pParse, yymsp[-4].minor.yy259, &yymsp[-3].minor.yy0);
- sqlite3ExprListCheckLength(pParse,yymsp[-1].minor.yy322,"set list");
- sqlite3Update(pParse,yymsp[-4].minor.yy259,yymsp[-1].minor.yy322,yymsp[0].minor.yy314,yymsp[-5].minor.yy210);
+ sqlite3SrcListIndexedBy(pParse, yymsp[-4].minor.yy347, &yymsp[-3].minor.yy0);
+ sqlite3ExprListCheckLength(pParse,yymsp[-1].minor.yy442,"set list");
+ sqlite3Update(pParse,yymsp[-4].minor.yy347,yymsp[-1].minor.yy442,yymsp[0].minor.yy122,yymsp[-5].minor.yy258);
}
break;
- case 171: /* setlist ::= setlist COMMA nm EQ expr */
+ case 170: /* setlist ::= setlist COMMA nm EQ expr */
{
- yygotominor.yy322 = sqlite3ExprListAppend(pParse, yymsp[-4].minor.yy322, yymsp[0].minor.yy118.pExpr);
- sqlite3ExprListSetName(pParse, yygotominor.yy322, &yymsp[-2].minor.yy0, 1);
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse, yymsp[-4].minor.yy442, yymsp[0].minor.yy342.pExpr);
+ sqlite3ExprListSetName(pParse, yygotominor.yy442, &yymsp[-2].minor.yy0, 1);
}
break;
- case 172: /* setlist ::= nm EQ expr */
+ case 171: /* setlist ::= nm EQ expr */
{
- yygotominor.yy322 = sqlite3ExprListAppend(pParse, 0, yymsp[0].minor.yy118.pExpr);
- sqlite3ExprListSetName(pParse, yygotominor.yy322, &yymsp[-2].minor.yy0, 1);
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse, 0, yymsp[0].minor.yy342.pExpr);
+ sqlite3ExprListSetName(pParse, yygotominor.yy442, &yymsp[-2].minor.yy0, 1);
}
break;
- case 173: /* cmd ::= insert_cmd INTO fullname inscollist_opt VALUES LP itemlist RP */
-{sqlite3Insert(pParse, yymsp[-5].minor.yy259, yymsp[-1].minor.yy322, 0, yymsp[-4].minor.yy384, yymsp[-7].minor.yy210);}
+ case 172: /* cmd ::= insert_cmd INTO fullname inscollist_opt valuelist */
+{sqlite3Insert(pParse, yymsp[-2].minor.yy347, yymsp[0].minor.yy487.pList, yymsp[0].minor.yy487.pSelect, yymsp[-1].minor.yy180, yymsp[-4].minor.yy258);}
break;
- case 174: /* cmd ::= insert_cmd INTO fullname inscollist_opt select */
-{sqlite3Insert(pParse, yymsp[-2].minor.yy259, 0, yymsp[0].minor.yy387, yymsp[-1].minor.yy384, yymsp[-4].minor.yy210);}
+ case 173: /* cmd ::= insert_cmd INTO fullname inscollist_opt select */
+{sqlite3Insert(pParse, yymsp[-2].minor.yy347, 0, yymsp[0].minor.yy159, yymsp[-1].minor.yy180, yymsp[-4].minor.yy258);}
break;
- case 175: /* cmd ::= insert_cmd INTO fullname inscollist_opt DEFAULT VALUES */
-{sqlite3Insert(pParse, yymsp[-3].minor.yy259, 0, 0, yymsp[-2].minor.yy384, yymsp[-5].minor.yy210);}
+ case 174: /* cmd ::= insert_cmd INTO fullname inscollist_opt DEFAULT VALUES */
+{sqlite3Insert(pParse, yymsp[-3].minor.yy347, 0, 0, yymsp[-2].minor.yy180, yymsp[-5].minor.yy258);}
break;
- case 176: /* insert_cmd ::= INSERT orconf */
-{yygotominor.yy210 = yymsp[0].minor.yy210;}
+ case 175: /* insert_cmd ::= INSERT orconf */
+{yygotominor.yy258 = yymsp[0].minor.yy258;}
break;
- case 177: /* insert_cmd ::= REPLACE */
-{yygotominor.yy210 = OE_Replace;}
+ case 176: /* insert_cmd ::= REPLACE */
+{yygotominor.yy258 = OE_Replace;}
break;
- case 178: /* itemlist ::= itemlist COMMA expr */
- case 241: /* nexprlist ::= nexprlist COMMA expr */ yytestcase(yyruleno==241);
-{yygotominor.yy322 = sqlite3ExprListAppend(pParse,yymsp[-2].minor.yy322,yymsp[0].minor.yy118.pExpr);}
+ case 177: /* valuelist ::= VALUES LP nexprlist RP */
+{
+ yygotominor.yy487.pList = yymsp[-1].minor.yy442;
+ yygotominor.yy487.pSelect = 0;
+}
break;
- case 179: /* itemlist ::= expr */
- case 242: /* nexprlist ::= expr */ yytestcase(yyruleno==242);
-{yygotominor.yy322 = sqlite3ExprListAppend(pParse,0,yymsp[0].minor.yy118.pExpr);}
+ case 178: /* valuelist ::= valuelist COMMA LP exprlist RP */
+{
+ Select *pRight = sqlite3SelectNew(pParse, yymsp[-1].minor.yy442, 0, 0, 0, 0, 0, 0, 0, 0);
+ if( yymsp[-4].minor.yy487.pList ){
+ yymsp[-4].minor.yy487.pSelect = sqlite3SelectNew(pParse, yymsp[-4].minor.yy487.pList, 0, 0, 0, 0, 0, 0, 0, 0);
+ yymsp[-4].minor.yy487.pList = 0;
+ }
+ yygotominor.yy487.pList = 0;
+ if( yymsp[-4].minor.yy487.pSelect==0 || pRight==0 ){
+ sqlite3SelectDelete(pParse->db, pRight);
+ sqlite3SelectDelete(pParse->db, yymsp[-4].minor.yy487.pSelect);
+ yygotominor.yy487.pSelect = 0;
+ }else{
+ pRight->op = TK_ALL;
+ pRight->pPrior = yymsp[-4].minor.yy487.pSelect;
+ pRight->selFlags |= SF_Values;
+ pRight->pPrior->selFlags |= SF_Values;
+ yygotominor.yy487.pSelect = pRight;
+ }
+}
break;
- case 182: /* inscollist ::= inscollist COMMA nm */
-{yygotominor.yy384 = sqlite3IdListAppend(pParse->db,yymsp[-2].minor.yy384,&yymsp[0].minor.yy0);}
+ case 181: /* inscollist ::= inscollist COMMA nm */
+{yygotominor.yy180 = sqlite3IdListAppend(pParse->db,yymsp[-2].minor.yy180,&yymsp[0].minor.yy0);}
break;
- case 183: /* inscollist ::= nm */
-{yygotominor.yy384 = sqlite3IdListAppend(pParse->db,0,&yymsp[0].minor.yy0);}
+ case 182: /* inscollist ::= nm */
+{yygotominor.yy180 = sqlite3IdListAppend(pParse->db,0,&yymsp[0].minor.yy0);}
break;
- case 184: /* expr ::= term */
-{yygotominor.yy118 = yymsp[0].minor.yy118;}
+ case 183: /* expr ::= term */
+{yygotominor.yy342 = yymsp[0].minor.yy342;}
break;
- case 185: /* expr ::= LP expr RP */
-{yygotominor.yy118.pExpr = yymsp[-1].minor.yy118.pExpr; spanSet(&yygotominor.yy118,&yymsp[-2].minor.yy0,&yymsp[0].minor.yy0);}
+ case 184: /* expr ::= LP expr RP */
+{yygotominor.yy342.pExpr = yymsp[-1].minor.yy342.pExpr; spanSet(&yygotominor.yy342,&yymsp[-2].minor.yy0,&yymsp[0].minor.yy0);}
break;
- case 186: /* term ::= NULL */
- case 191: /* term ::= INTEGER|FLOAT|BLOB */ yytestcase(yyruleno==191);
- case 192: /* term ::= STRING */ yytestcase(yyruleno==192);
-{spanExpr(&yygotominor.yy118, pParse, yymsp[0].major, &yymsp[0].minor.yy0);}
+ case 185: /* term ::= NULL */
+ case 190: /* term ::= INTEGER|FLOAT|BLOB */ yytestcase(yyruleno==190);
+ case 191: /* term ::= STRING */ yytestcase(yyruleno==191);
+{spanExpr(&yygotominor.yy342, pParse, yymsp[0].major, &yymsp[0].minor.yy0);}
break;
- case 187: /* expr ::= id */
- case 188: /* expr ::= JOIN_KW */ yytestcase(yyruleno==188);
-{spanExpr(&yygotominor.yy118, pParse, TK_ID, &yymsp[0].minor.yy0);}
+ case 186: /* expr ::= id */
+ case 187: /* expr ::= JOIN_KW */ yytestcase(yyruleno==187);
+{spanExpr(&yygotominor.yy342, pParse, TK_ID, &yymsp[0].minor.yy0);}
break;
- case 189: /* expr ::= nm DOT nm */
+ case 188: /* expr ::= nm DOT nm */
{
Expr *temp1 = sqlite3PExpr(pParse, TK_ID, 0, 0, &yymsp[-2].minor.yy0);
Expr *temp2 = sqlite3PExpr(pParse, TK_ID, 0, 0, &yymsp[0].minor.yy0);
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_DOT, temp1, temp2, 0);
- spanSet(&yygotominor.yy118,&yymsp[-2].minor.yy0,&yymsp[0].minor.yy0);
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_DOT, temp1, temp2, 0);
+ spanSet(&yygotominor.yy342,&yymsp[-2].minor.yy0,&yymsp[0].minor.yy0);
}
break;
- case 190: /* expr ::= nm DOT nm DOT nm */
+ case 189: /* expr ::= nm DOT nm DOT nm */
{
Expr *temp1 = sqlite3PExpr(pParse, TK_ID, 0, 0, &yymsp[-4].minor.yy0);
Expr *temp2 = sqlite3PExpr(pParse, TK_ID, 0, 0, &yymsp[-2].minor.yy0);
Expr *temp3 = sqlite3PExpr(pParse, TK_ID, 0, 0, &yymsp[0].minor.yy0);
Expr *temp4 = sqlite3PExpr(pParse, TK_DOT, temp2, temp3, 0);
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_DOT, temp1, temp4, 0);
- spanSet(&yygotominor.yy118,&yymsp[-4].minor.yy0,&yymsp[0].minor.yy0);
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_DOT, temp1, temp4, 0);
+ spanSet(&yygotominor.yy342,&yymsp[-4].minor.yy0,&yymsp[0].minor.yy0);
}
break;
- case 193: /* expr ::= REGISTER */
+ case 192: /* expr ::= REGISTER */
{
/* When doing a nested parse, one can include terms in an expression
** that look like this: #1 #2 ... These terms refer to registers
** in the virtual machine. #N is the N-th register. */
if( pParse->nested==0 ){
sqlite3ErrorMsg(pParse, "near \"%T\": syntax error", &yymsp[0].minor.yy0);
- yygotominor.yy118.pExpr = 0;
+ yygotominor.yy342.pExpr = 0;
}else{
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_REGISTER, 0, 0, &yymsp[0].minor.yy0);
- if( yygotominor.yy118.pExpr ) sqlite3GetInt32(&yymsp[0].minor.yy0.z[1], &yygotominor.yy118.pExpr->iTable);
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_REGISTER, 0, 0, &yymsp[0].minor.yy0);
+ if( yygotominor.yy342.pExpr ) sqlite3GetInt32(&yymsp[0].minor.yy0.z[1], &yygotominor.yy342.pExpr->iTable);
}
- spanSet(&yygotominor.yy118, &yymsp[0].minor.yy0, &yymsp[0].minor.yy0);
+ spanSet(&yygotominor.yy342, &yymsp[0].minor.yy0, &yymsp[0].minor.yy0);
}
break;
- case 194: /* expr ::= VARIABLE */
+ case 193: /* expr ::= VARIABLE */
{
- spanExpr(&yygotominor.yy118, pParse, TK_VARIABLE, &yymsp[0].minor.yy0);
- sqlite3ExprAssignVarNumber(pParse, yygotominor.yy118.pExpr);
- spanSet(&yygotominor.yy118, &yymsp[0].minor.yy0, &yymsp[0].minor.yy0);
+ spanExpr(&yygotominor.yy342, pParse, TK_VARIABLE, &yymsp[0].minor.yy0);
+ sqlite3ExprAssignVarNumber(pParse, yygotominor.yy342.pExpr);
+ spanSet(&yygotominor.yy342, &yymsp[0].minor.yy0, &yymsp[0].minor.yy0);
}
break;
- case 195: /* expr ::= expr COLLATE ids */
+ case 194: /* expr ::= expr COLLATE ids */
{
- yygotominor.yy118.pExpr = sqlite3ExprSetCollByToken(pParse, yymsp[-2].minor.yy118.pExpr, &yymsp[0].minor.yy0);
- yygotominor.yy118.zStart = yymsp[-2].minor.yy118.zStart;
- yygotominor.yy118.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
+ yygotominor.yy342.pExpr = sqlite3ExprAddCollateToken(pParse, yymsp[-2].minor.yy342.pExpr, &yymsp[0].minor.yy0);
+ yygotominor.yy342.zStart = yymsp[-2].minor.yy342.zStart;
+ yygotominor.yy342.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
}
break;
- case 196: /* expr ::= CAST LP expr AS typetoken RP */
+ case 195: /* expr ::= CAST LP expr AS typetoken RP */
{
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_CAST, yymsp[-3].minor.yy118.pExpr, 0, &yymsp[-1].minor.yy0);
- spanSet(&yygotominor.yy118,&yymsp[-5].minor.yy0,&yymsp[0].minor.yy0);
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_CAST, yymsp[-3].minor.yy342.pExpr, 0, &yymsp[-1].minor.yy0);
+ spanSet(&yygotominor.yy342,&yymsp[-5].minor.yy0,&yymsp[0].minor.yy0);
}
break;
- case 197: /* expr ::= ID LP distinct exprlist RP */
+ case 196: /* expr ::= ID LP distinct exprlist RP */
{
- if( yymsp[-1].minor.yy322 && yymsp[-1].minor.yy322->nExpr>pParse->db->aLimit[SQLITE_LIMIT_FUNCTION_ARG] ){
+ if( yymsp[-1].minor.yy442 && yymsp[-1].minor.yy442->nExpr>pParse->db->aLimit[SQLITE_LIMIT_FUNCTION_ARG] ){
sqlite3ErrorMsg(pParse, "too many arguments on function %T", &yymsp[-4].minor.yy0);
}
- yygotominor.yy118.pExpr = sqlite3ExprFunction(pParse, yymsp[-1].minor.yy322, &yymsp[-4].minor.yy0);
- spanSet(&yygotominor.yy118,&yymsp[-4].minor.yy0,&yymsp[0].minor.yy0);
- if( yymsp[-2].minor.yy4 && yygotominor.yy118.pExpr ){
- yygotominor.yy118.pExpr->flags |= EP_Distinct;
+ yygotominor.yy342.pExpr = sqlite3ExprFunction(pParse, yymsp[-1].minor.yy442, &yymsp[-4].minor.yy0);
+ spanSet(&yygotominor.yy342,&yymsp[-4].minor.yy0,&yymsp[0].minor.yy0);
+ if( yymsp[-2].minor.yy305 && yygotominor.yy342.pExpr ){
+ yygotominor.yy342.pExpr->flags |= EP_Distinct;
}
}
break;
- case 198: /* expr ::= ID LP STAR RP */
+ case 197: /* expr ::= ID LP STAR RP */
{
- yygotominor.yy118.pExpr = sqlite3ExprFunction(pParse, 0, &yymsp[-3].minor.yy0);
- spanSet(&yygotominor.yy118,&yymsp[-3].minor.yy0,&yymsp[0].minor.yy0);
+ yygotominor.yy342.pExpr = sqlite3ExprFunction(pParse, 0, &yymsp[-3].minor.yy0);
+ spanSet(&yygotominor.yy342,&yymsp[-3].minor.yy0,&yymsp[0].minor.yy0);
}
break;
- case 199: /* term ::= CTIME_KW */
+ case 198: /* term ::= CTIME_KW */
{
/* The CURRENT_TIME, CURRENT_DATE, and CURRENT_TIMESTAMP values are
** treated as functions that return constants */
- yygotominor.yy118.pExpr = sqlite3ExprFunction(pParse, 0,&yymsp[0].minor.yy0);
- if( yygotominor.yy118.pExpr ){
- yygotominor.yy118.pExpr->op = TK_CONST_FUNC;
+ yygotominor.yy342.pExpr = sqlite3ExprFunction(pParse, 0,&yymsp[0].minor.yy0);
+ if( yygotominor.yy342.pExpr ){
+ yygotominor.yy342.pExpr->op = TK_CONST_FUNC;
}
- spanSet(&yygotominor.yy118, &yymsp[0].minor.yy0, &yymsp[0].minor.yy0);
+ spanSet(&yygotominor.yy342, &yymsp[0].minor.yy0, &yymsp[0].minor.yy0);
}
break;
- case 200: /* expr ::= expr AND expr */
- case 201: /* expr ::= expr OR expr */ yytestcase(yyruleno==201);
- case 202: /* expr ::= expr LT|GT|GE|LE expr */ yytestcase(yyruleno==202);
- case 203: /* expr ::= expr EQ|NE expr */ yytestcase(yyruleno==203);
- case 204: /* expr ::= expr BITAND|BITOR|LSHIFT|RSHIFT expr */ yytestcase(yyruleno==204);
- case 205: /* expr ::= expr PLUS|MINUS expr */ yytestcase(yyruleno==205);
- case 206: /* expr ::= expr STAR|SLASH|REM expr */ yytestcase(yyruleno==206);
- case 207: /* expr ::= expr CONCAT expr */ yytestcase(yyruleno==207);
-{spanBinaryExpr(&yygotominor.yy118,pParse,yymsp[-1].major,&yymsp[-2].minor.yy118,&yymsp[0].minor.yy118);}
+ case 199: /* expr ::= expr AND expr */
+ case 200: /* expr ::= expr OR expr */ yytestcase(yyruleno==200);
+ case 201: /* expr ::= expr LT|GT|GE|LE expr */ yytestcase(yyruleno==201);
+ case 202: /* expr ::= expr EQ|NE expr */ yytestcase(yyruleno==202);
+ case 203: /* expr ::= expr BITAND|BITOR|LSHIFT|RSHIFT expr */ yytestcase(yyruleno==203);
+ case 204: /* expr ::= expr PLUS|MINUS expr */ yytestcase(yyruleno==204);
+ case 205: /* expr ::= expr STAR|SLASH|REM expr */ yytestcase(yyruleno==205);
+ case 206: /* expr ::= expr CONCAT expr */ yytestcase(yyruleno==206);
+{spanBinaryExpr(&yygotominor.yy342,pParse,yymsp[-1].major,&yymsp[-2].minor.yy342,&yymsp[0].minor.yy342);}
break;
- case 208: /* likeop ::= LIKE_KW */
- case 210: /* likeop ::= MATCH */ yytestcase(yyruleno==210);
-{yygotominor.yy342.eOperator = yymsp[0].minor.yy0; yygotominor.yy342.not = 0;}
+ case 207: /* likeop ::= LIKE_KW */
+ case 209: /* likeop ::= MATCH */ yytestcase(yyruleno==209);
+{yygotominor.yy318.eOperator = yymsp[0].minor.yy0; yygotominor.yy318.bNot = 0;}
break;
- case 209: /* likeop ::= NOT LIKE_KW */
- case 211: /* likeop ::= NOT MATCH */ yytestcase(yyruleno==211);
-{yygotominor.yy342.eOperator = yymsp[0].minor.yy0; yygotominor.yy342.not = 1;}
+ case 208: /* likeop ::= NOT LIKE_KW */
+ case 210: /* likeop ::= NOT MATCH */ yytestcase(yyruleno==210);
+{yygotominor.yy318.eOperator = yymsp[0].minor.yy0; yygotominor.yy318.bNot = 1;}
break;
- case 212: /* expr ::= expr likeop expr */
+ case 211: /* expr ::= expr likeop expr */
{
ExprList *pList;
- pList = sqlite3ExprListAppend(pParse,0, yymsp[0].minor.yy118.pExpr);
- pList = sqlite3ExprListAppend(pParse,pList, yymsp[-2].minor.yy118.pExpr);
- yygotominor.yy118.pExpr = sqlite3ExprFunction(pParse, pList, &yymsp[-1].minor.yy342.eOperator);
- if( yymsp[-1].minor.yy342.not ) yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_NOT, yygotominor.yy118.pExpr, 0, 0);
- yygotominor.yy118.zStart = yymsp[-2].minor.yy118.zStart;
- yygotominor.yy118.zEnd = yymsp[0].minor.yy118.zEnd;
- if( yygotominor.yy118.pExpr ) yygotominor.yy118.pExpr->flags |= EP_InfixFunc;
+ pList = sqlite3ExprListAppend(pParse,0, yymsp[0].minor.yy342.pExpr);
+ pList = sqlite3ExprListAppend(pParse,pList, yymsp[-2].minor.yy342.pExpr);
+ yygotominor.yy342.pExpr = sqlite3ExprFunction(pParse, pList, &yymsp[-1].minor.yy318.eOperator);
+ if( yymsp[-1].minor.yy318.bNot ) yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_NOT, yygotominor.yy342.pExpr, 0, 0);
+ yygotominor.yy342.zStart = yymsp[-2].minor.yy342.zStart;
+ yygotominor.yy342.zEnd = yymsp[0].minor.yy342.zEnd;
+ if( yygotominor.yy342.pExpr ) yygotominor.yy342.pExpr->flags |= EP_InfixFunc;
}
break;
- case 213: /* expr ::= expr likeop expr ESCAPE expr */
+ case 212: /* expr ::= expr likeop expr ESCAPE expr */
{
ExprList *pList;
- pList = sqlite3ExprListAppend(pParse,0, yymsp[-2].minor.yy118.pExpr);
- pList = sqlite3ExprListAppend(pParse,pList, yymsp[-4].minor.yy118.pExpr);
- pList = sqlite3ExprListAppend(pParse,pList, yymsp[0].minor.yy118.pExpr);
- yygotominor.yy118.pExpr = sqlite3ExprFunction(pParse, pList, &yymsp[-3].minor.yy342.eOperator);
- if( yymsp[-3].minor.yy342.not ) yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_NOT, yygotominor.yy118.pExpr, 0, 0);
- yygotominor.yy118.zStart = yymsp[-4].minor.yy118.zStart;
- yygotominor.yy118.zEnd = yymsp[0].minor.yy118.zEnd;
- if( yygotominor.yy118.pExpr ) yygotominor.yy118.pExpr->flags |= EP_InfixFunc;
+ pList = sqlite3ExprListAppend(pParse,0, yymsp[-2].minor.yy342.pExpr);
+ pList = sqlite3ExprListAppend(pParse,pList, yymsp[-4].minor.yy342.pExpr);
+ pList = sqlite3ExprListAppend(pParse,pList, yymsp[0].minor.yy342.pExpr);
+ yygotominor.yy342.pExpr = sqlite3ExprFunction(pParse, pList, &yymsp[-3].minor.yy318.eOperator);
+ if( yymsp[-3].minor.yy318.bNot ) yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_NOT, yygotominor.yy342.pExpr, 0, 0);
+ yygotominor.yy342.zStart = yymsp[-4].minor.yy342.zStart;
+ yygotominor.yy342.zEnd = yymsp[0].minor.yy342.zEnd;
+ if( yygotominor.yy342.pExpr ) yygotominor.yy342.pExpr->flags |= EP_InfixFunc;
}
break;
- case 214: /* expr ::= expr ISNULL|NOTNULL */
-{spanUnaryPostfix(&yygotominor.yy118,pParse,yymsp[0].major,&yymsp[-1].minor.yy118,&yymsp[0].minor.yy0);}
+ case 213: /* expr ::= expr ISNULL|NOTNULL */
+{spanUnaryPostfix(&yygotominor.yy342,pParse,yymsp[0].major,&yymsp[-1].minor.yy342,&yymsp[0].minor.yy0);}
break;
- case 215: /* expr ::= expr NOT NULL */
-{spanUnaryPostfix(&yygotominor.yy118,pParse,TK_NOTNULL,&yymsp[-2].minor.yy118,&yymsp[0].minor.yy0);}
+ case 214: /* expr ::= expr NOT NULL */
+{spanUnaryPostfix(&yygotominor.yy342,pParse,TK_NOTNULL,&yymsp[-2].minor.yy342,&yymsp[0].minor.yy0);}
break;
- case 216: /* expr ::= expr IS expr */
+ case 215: /* expr ::= expr IS expr */
{
- spanBinaryExpr(&yygotominor.yy118,pParse,TK_IS,&yymsp[-2].minor.yy118,&yymsp[0].minor.yy118);
- binaryToUnaryIfNull(pParse, yymsp[0].minor.yy118.pExpr, yygotominor.yy118.pExpr, TK_ISNULL);
+ spanBinaryExpr(&yygotominor.yy342,pParse,TK_IS,&yymsp[-2].minor.yy342,&yymsp[0].minor.yy342);
+ binaryToUnaryIfNull(pParse, yymsp[0].minor.yy342.pExpr, yygotominor.yy342.pExpr, TK_ISNULL);
}
break;
- case 217: /* expr ::= expr IS NOT expr */
+ case 216: /* expr ::= expr IS NOT expr */
{
- spanBinaryExpr(&yygotominor.yy118,pParse,TK_ISNOT,&yymsp[-3].minor.yy118,&yymsp[0].minor.yy118);
- binaryToUnaryIfNull(pParse, yymsp[0].minor.yy118.pExpr, yygotominor.yy118.pExpr, TK_NOTNULL);
+ spanBinaryExpr(&yygotominor.yy342,pParse,TK_ISNOT,&yymsp[-3].minor.yy342,&yymsp[0].minor.yy342);
+ binaryToUnaryIfNull(pParse, yymsp[0].minor.yy342.pExpr, yygotominor.yy342.pExpr, TK_NOTNULL);
}
break;
- case 218: /* expr ::= NOT expr */
- case 219: /* expr ::= BITNOT expr */ yytestcase(yyruleno==219);
-{spanUnaryPrefix(&yygotominor.yy118,pParse,yymsp[-1].major,&yymsp[0].minor.yy118,&yymsp[-1].minor.yy0);}
+ case 217: /* expr ::= NOT expr */
+ case 218: /* expr ::= BITNOT expr */ yytestcase(yyruleno==218);
+{spanUnaryPrefix(&yygotominor.yy342,pParse,yymsp[-1].major,&yymsp[0].minor.yy342,&yymsp[-1].minor.yy0);}
break;
- case 220: /* expr ::= MINUS expr */
-{spanUnaryPrefix(&yygotominor.yy118,pParse,TK_UMINUS,&yymsp[0].minor.yy118,&yymsp[-1].minor.yy0);}
+ case 219: /* expr ::= MINUS expr */
+{spanUnaryPrefix(&yygotominor.yy342,pParse,TK_UMINUS,&yymsp[0].minor.yy342,&yymsp[-1].minor.yy0);}
break;
- case 221: /* expr ::= PLUS expr */
-{spanUnaryPrefix(&yygotominor.yy118,pParse,TK_UPLUS,&yymsp[0].minor.yy118,&yymsp[-1].minor.yy0);}
+ case 220: /* expr ::= PLUS expr */
+{spanUnaryPrefix(&yygotominor.yy342,pParse,TK_UPLUS,&yymsp[0].minor.yy342,&yymsp[-1].minor.yy0);}
break;
- case 224: /* expr ::= expr between_op expr AND expr */
+ case 223: /* expr ::= expr between_op expr AND expr */
{
- ExprList *pList = sqlite3ExprListAppend(pParse,0, yymsp[-2].minor.yy118.pExpr);
- pList = sqlite3ExprListAppend(pParse,pList, yymsp[0].minor.yy118.pExpr);
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_BETWEEN, yymsp[-4].minor.yy118.pExpr, 0, 0);
- if( yygotominor.yy118.pExpr ){
- yygotominor.yy118.pExpr->x.pList = pList;
+ ExprList *pList = sqlite3ExprListAppend(pParse,0, yymsp[-2].minor.yy342.pExpr);
+ pList = sqlite3ExprListAppend(pParse,pList, yymsp[0].minor.yy342.pExpr);
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_BETWEEN, yymsp[-4].minor.yy342.pExpr, 0, 0);
+ if( yygotominor.yy342.pExpr ){
+ yygotominor.yy342.pExpr->x.pList = pList;
}else{
sqlite3ExprListDelete(pParse->db, pList);
}
- if( yymsp[-3].minor.yy4 ) yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_NOT, yygotominor.yy118.pExpr, 0, 0);
- yygotominor.yy118.zStart = yymsp[-4].minor.yy118.zStart;
- yygotominor.yy118.zEnd = yymsp[0].minor.yy118.zEnd;
+ if( yymsp[-3].minor.yy392 ) yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_NOT, yygotominor.yy342.pExpr, 0, 0);
+ yygotominor.yy342.zStart = yymsp[-4].minor.yy342.zStart;
+ yygotominor.yy342.zEnd = yymsp[0].minor.yy342.zEnd;
}
break;
- case 227: /* expr ::= expr in_op LP exprlist RP */
+ case 226: /* expr ::= expr in_op LP exprlist RP */
{
- if( yymsp[-1].minor.yy322==0 ){
+ if( yymsp[-1].minor.yy442==0 ){
/* Expressions of the form
**
** expr1 IN ()
@@ -106137,226 +111498,224 @@ static void yy_reduce(
** simplify to constants 0 (false) and 1 (true), respectively,
** regardless of the value of expr1.
*/
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_INTEGER, 0, 0, &sqlite3IntTokens[yymsp[-3].minor.yy4]);
- sqlite3ExprDelete(pParse->db, yymsp[-4].minor.yy118.pExpr);
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_INTEGER, 0, 0, &sqlite3IntTokens[yymsp[-3].minor.yy392]);
+ sqlite3ExprDelete(pParse->db, yymsp[-4].minor.yy342.pExpr);
}else{
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_IN, yymsp[-4].minor.yy118.pExpr, 0, 0);
- if( yygotominor.yy118.pExpr ){
- yygotominor.yy118.pExpr->x.pList = yymsp[-1].minor.yy322;
- sqlite3ExprSetHeight(pParse, yygotominor.yy118.pExpr);
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_IN, yymsp[-4].minor.yy342.pExpr, 0, 0);
+ if( yygotominor.yy342.pExpr ){
+ yygotominor.yy342.pExpr->x.pList = yymsp[-1].minor.yy442;
+ sqlite3ExprSetHeight(pParse, yygotominor.yy342.pExpr);
}else{
- sqlite3ExprListDelete(pParse->db, yymsp[-1].minor.yy322);
+ sqlite3ExprListDelete(pParse->db, yymsp[-1].minor.yy442);
}
- if( yymsp[-3].minor.yy4 ) yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_NOT, yygotominor.yy118.pExpr, 0, 0);
+ if( yymsp[-3].minor.yy392 ) yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_NOT, yygotominor.yy342.pExpr, 0, 0);
}
- yygotominor.yy118.zStart = yymsp[-4].minor.yy118.zStart;
- yygotominor.yy118.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
+ yygotominor.yy342.zStart = yymsp[-4].minor.yy342.zStart;
+ yygotominor.yy342.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
}
break;
- case 228: /* expr ::= LP select RP */
+ case 227: /* expr ::= LP select RP */
{
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_SELECT, 0, 0, 0);
- if( yygotominor.yy118.pExpr ){
- yygotominor.yy118.pExpr->x.pSelect = yymsp[-1].minor.yy387;
- ExprSetProperty(yygotominor.yy118.pExpr, EP_xIsSelect);
- sqlite3ExprSetHeight(pParse, yygotominor.yy118.pExpr);
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_SELECT, 0, 0, 0);
+ if( yygotominor.yy342.pExpr ){
+ yygotominor.yy342.pExpr->x.pSelect = yymsp[-1].minor.yy159;
+ ExprSetProperty(yygotominor.yy342.pExpr, EP_xIsSelect);
+ sqlite3ExprSetHeight(pParse, yygotominor.yy342.pExpr);
}else{
- sqlite3SelectDelete(pParse->db, yymsp[-1].minor.yy387);
+ sqlite3SelectDelete(pParse->db, yymsp[-1].minor.yy159);
}
- yygotominor.yy118.zStart = yymsp[-2].minor.yy0.z;
- yygotominor.yy118.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
+ yygotominor.yy342.zStart = yymsp[-2].minor.yy0.z;
+ yygotominor.yy342.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
}
break;
- case 229: /* expr ::= expr in_op LP select RP */
+ case 228: /* expr ::= expr in_op LP select RP */
{
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_IN, yymsp[-4].minor.yy118.pExpr, 0, 0);
- if( yygotominor.yy118.pExpr ){
- yygotominor.yy118.pExpr->x.pSelect = yymsp[-1].minor.yy387;
- ExprSetProperty(yygotominor.yy118.pExpr, EP_xIsSelect);
- sqlite3ExprSetHeight(pParse, yygotominor.yy118.pExpr);
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_IN, yymsp[-4].minor.yy342.pExpr, 0, 0);
+ if( yygotominor.yy342.pExpr ){
+ yygotominor.yy342.pExpr->x.pSelect = yymsp[-1].minor.yy159;
+ ExprSetProperty(yygotominor.yy342.pExpr, EP_xIsSelect);
+ sqlite3ExprSetHeight(pParse, yygotominor.yy342.pExpr);
}else{
- sqlite3SelectDelete(pParse->db, yymsp[-1].minor.yy387);
+ sqlite3SelectDelete(pParse->db, yymsp[-1].minor.yy159);
}
- if( yymsp[-3].minor.yy4 ) yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_NOT, yygotominor.yy118.pExpr, 0, 0);
- yygotominor.yy118.zStart = yymsp[-4].minor.yy118.zStart;
- yygotominor.yy118.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
+ if( yymsp[-3].minor.yy392 ) yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_NOT, yygotominor.yy342.pExpr, 0, 0);
+ yygotominor.yy342.zStart = yymsp[-4].minor.yy342.zStart;
+ yygotominor.yy342.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
}
break;
- case 230: /* expr ::= expr in_op nm dbnm */
+ case 229: /* expr ::= expr in_op nm dbnm */
{
SrcList *pSrc = sqlite3SrcListAppend(pParse->db, 0,&yymsp[-1].minor.yy0,&yymsp[0].minor.yy0);
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_IN, yymsp[-3].minor.yy118.pExpr, 0, 0);
- if( yygotominor.yy118.pExpr ){
- yygotominor.yy118.pExpr->x.pSelect = sqlite3SelectNew(pParse, 0,pSrc,0,0,0,0,0,0,0);
- ExprSetProperty(yygotominor.yy118.pExpr, EP_xIsSelect);
- sqlite3ExprSetHeight(pParse, yygotominor.yy118.pExpr);
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_IN, yymsp[-3].minor.yy342.pExpr, 0, 0);
+ if( yygotominor.yy342.pExpr ){
+ yygotominor.yy342.pExpr->x.pSelect = sqlite3SelectNew(pParse, 0,pSrc,0,0,0,0,0,0,0);
+ ExprSetProperty(yygotominor.yy342.pExpr, EP_xIsSelect);
+ sqlite3ExprSetHeight(pParse, yygotominor.yy342.pExpr);
}else{
sqlite3SrcListDelete(pParse->db, pSrc);
}
- if( yymsp[-2].minor.yy4 ) yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_NOT, yygotominor.yy118.pExpr, 0, 0);
- yygotominor.yy118.zStart = yymsp[-3].minor.yy118.zStart;
- yygotominor.yy118.zEnd = yymsp[0].minor.yy0.z ? &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n] : &yymsp[-1].minor.yy0.z[yymsp[-1].minor.yy0.n];
+ if( yymsp[-2].minor.yy392 ) yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_NOT, yygotominor.yy342.pExpr, 0, 0);
+ yygotominor.yy342.zStart = yymsp[-3].minor.yy342.zStart;
+ yygotominor.yy342.zEnd = yymsp[0].minor.yy0.z ? &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n] : &yymsp[-1].minor.yy0.z[yymsp[-1].minor.yy0.n];
}
break;
- case 231: /* expr ::= EXISTS LP select RP */
+ case 230: /* expr ::= EXISTS LP select RP */
{
- Expr *p = yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_EXISTS, 0, 0, 0);
+ Expr *p = yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_EXISTS, 0, 0, 0);
if( p ){
- p->x.pSelect = yymsp[-1].minor.yy387;
+ p->x.pSelect = yymsp[-1].minor.yy159;
ExprSetProperty(p, EP_xIsSelect);
sqlite3ExprSetHeight(pParse, p);
}else{
- sqlite3SelectDelete(pParse->db, yymsp[-1].minor.yy387);
+ sqlite3SelectDelete(pParse->db, yymsp[-1].minor.yy159);
}
- yygotominor.yy118.zStart = yymsp[-3].minor.yy0.z;
- yygotominor.yy118.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
+ yygotominor.yy342.zStart = yymsp[-3].minor.yy0.z;
+ yygotominor.yy342.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
}
break;
- case 232: /* expr ::= CASE case_operand case_exprlist case_else END */
+ case 231: /* expr ::= CASE case_operand case_exprlist case_else END */
{
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_CASE, yymsp[-3].minor.yy314, yymsp[-1].minor.yy314, 0);
- if( yygotominor.yy118.pExpr ){
- yygotominor.yy118.pExpr->x.pList = yymsp[-2].minor.yy322;
- sqlite3ExprSetHeight(pParse, yygotominor.yy118.pExpr);
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_CASE, yymsp[-3].minor.yy122, yymsp[-1].minor.yy122, 0);
+ if( yygotominor.yy342.pExpr ){
+ yygotominor.yy342.pExpr->x.pList = yymsp[-2].minor.yy442;
+ sqlite3ExprSetHeight(pParse, yygotominor.yy342.pExpr);
}else{
- sqlite3ExprListDelete(pParse->db, yymsp[-2].minor.yy322);
+ sqlite3ExprListDelete(pParse->db, yymsp[-2].minor.yy442);
}
- yygotominor.yy118.zStart = yymsp[-4].minor.yy0.z;
- yygotominor.yy118.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
+ yygotominor.yy342.zStart = yymsp[-4].minor.yy0.z;
+ yygotominor.yy342.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
}
break;
- case 233: /* case_exprlist ::= case_exprlist WHEN expr THEN expr */
+ case 232: /* case_exprlist ::= case_exprlist WHEN expr THEN expr */
{
- yygotominor.yy322 = sqlite3ExprListAppend(pParse,yymsp[-4].minor.yy322, yymsp[-2].minor.yy118.pExpr);
- yygotominor.yy322 = sqlite3ExprListAppend(pParse,yygotominor.yy322, yymsp[0].minor.yy118.pExpr);
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse,yymsp[-4].minor.yy442, yymsp[-2].minor.yy342.pExpr);
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse,yygotominor.yy442, yymsp[0].minor.yy342.pExpr);
}
break;
- case 234: /* case_exprlist ::= WHEN expr THEN expr */
+ case 233: /* case_exprlist ::= WHEN expr THEN expr */
{
- yygotominor.yy322 = sqlite3ExprListAppend(pParse,0, yymsp[-2].minor.yy118.pExpr);
- yygotominor.yy322 = sqlite3ExprListAppend(pParse,yygotominor.yy322, yymsp[0].minor.yy118.pExpr);
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse,0, yymsp[-2].minor.yy342.pExpr);
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse,yygotominor.yy442, yymsp[0].minor.yy342.pExpr);
}
break;
- case 243: /* cmd ::= createkw uniqueflag INDEX ifnotexists nm dbnm ON nm LP idxlist RP */
+ case 240: /* nexprlist ::= nexprlist COMMA expr */
+{yygotominor.yy442 = sqlite3ExprListAppend(pParse,yymsp[-2].minor.yy442,yymsp[0].minor.yy342.pExpr);}
+ break;
+ case 241: /* nexprlist ::= expr */
+{yygotominor.yy442 = sqlite3ExprListAppend(pParse,0,yymsp[0].minor.yy342.pExpr);}
+ break;
+ case 242: /* cmd ::= createkw uniqueflag INDEX ifnotexists nm dbnm ON nm LP idxlist RP */
{
sqlite3CreateIndex(pParse, &yymsp[-6].minor.yy0, &yymsp[-5].minor.yy0,
- sqlite3SrcListAppend(pParse->db,0,&yymsp[-3].minor.yy0,0), yymsp[-1].minor.yy322, yymsp[-9].minor.yy4,
- &yymsp[-10].minor.yy0, &yymsp[0].minor.yy0, SQLITE_SO_ASC, yymsp[-7].minor.yy4);
+ sqlite3SrcListAppend(pParse->db,0,&yymsp[-3].minor.yy0,0), yymsp[-1].minor.yy442, yymsp[-9].minor.yy392,
+ &yymsp[-10].minor.yy0, &yymsp[0].minor.yy0, SQLITE_SO_ASC, yymsp[-7].minor.yy392);
}
break;
- case 244: /* uniqueflag ::= UNIQUE */
- case 298: /* raisetype ::= ABORT */ yytestcase(yyruleno==298);
-{yygotominor.yy4 = OE_Abort;}
+ case 243: /* uniqueflag ::= UNIQUE */
+ case 296: /* raisetype ::= ABORT */ yytestcase(yyruleno==296);
+{yygotominor.yy392 = OE_Abort;}
break;
- case 245: /* uniqueflag ::= */
-{yygotominor.yy4 = OE_None;}
+ case 244: /* uniqueflag ::= */
+{yygotominor.yy392 = OE_None;}
break;
- case 248: /* idxlist ::= idxlist COMMA nm collate sortorder */
+ case 247: /* idxlist ::= idxlist COMMA nm collate sortorder */
{
- Expr *p = 0;
- if( yymsp[-1].minor.yy0.n>0 ){
- p = sqlite3Expr(pParse->db, TK_COLUMN, 0);
- sqlite3ExprSetCollByToken(pParse, p, &yymsp[-1].minor.yy0);
- }
- yygotominor.yy322 = sqlite3ExprListAppend(pParse,yymsp[-4].minor.yy322, p);
- sqlite3ExprListSetName(pParse,yygotominor.yy322,&yymsp[-2].minor.yy0,1);
- sqlite3ExprListCheckLength(pParse, yygotominor.yy322, "index");
- if( yygotominor.yy322 ) yygotominor.yy322->a[yygotominor.yy322->nExpr-1].sortOrder = (u8)yymsp[0].minor.yy4;
+ Expr *p = sqlite3ExprAddCollateToken(pParse, 0, &yymsp[-1].minor.yy0);
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse,yymsp[-4].minor.yy442, p);
+ sqlite3ExprListSetName(pParse,yygotominor.yy442,&yymsp[-2].minor.yy0,1);
+ sqlite3ExprListCheckLength(pParse, yygotominor.yy442, "index");
+ if( yygotominor.yy442 ) yygotominor.yy442->a[yygotominor.yy442->nExpr-1].sortOrder = (u8)yymsp[0].minor.yy392;
}
break;
- case 249: /* idxlist ::= nm collate sortorder */
+ case 248: /* idxlist ::= nm collate sortorder */
{
- Expr *p = 0;
- if( yymsp[-1].minor.yy0.n>0 ){
- p = sqlite3PExpr(pParse, TK_COLUMN, 0, 0, 0);
- sqlite3ExprSetCollByToken(pParse, p, &yymsp[-1].minor.yy0);
- }
- yygotominor.yy322 = sqlite3ExprListAppend(pParse,0, p);
- sqlite3ExprListSetName(pParse, yygotominor.yy322, &yymsp[-2].minor.yy0, 1);
- sqlite3ExprListCheckLength(pParse, yygotominor.yy322, "index");
- if( yygotominor.yy322 ) yygotominor.yy322->a[yygotominor.yy322->nExpr-1].sortOrder = (u8)yymsp[0].minor.yy4;
+ Expr *p = sqlite3ExprAddCollateToken(pParse, 0, &yymsp[-1].minor.yy0);
+ yygotominor.yy442 = sqlite3ExprListAppend(pParse,0, p);
+ sqlite3ExprListSetName(pParse, yygotominor.yy442, &yymsp[-2].minor.yy0, 1);
+ sqlite3ExprListCheckLength(pParse, yygotominor.yy442, "index");
+ if( yygotominor.yy442 ) yygotominor.yy442->a[yygotominor.yy442->nExpr-1].sortOrder = (u8)yymsp[0].minor.yy392;
}
break;
- case 250: /* collate ::= */
+ case 249: /* collate ::= */
{yygotominor.yy0.z = 0; yygotominor.yy0.n = 0;}
break;
- case 252: /* cmd ::= DROP INDEX ifexists fullname */
-{sqlite3DropIndex(pParse, yymsp[0].minor.yy259, yymsp[-1].minor.yy4);}
+ case 251: /* cmd ::= DROP INDEX ifexists fullname */
+{sqlite3DropIndex(pParse, yymsp[0].minor.yy347, yymsp[-1].minor.yy392);}
break;
- case 253: /* cmd ::= VACUUM */
- case 254: /* cmd ::= VACUUM nm */ yytestcase(yyruleno==254);
+ case 252: /* cmd ::= VACUUM */
+ case 253: /* cmd ::= VACUUM nm */ yytestcase(yyruleno==253);
{sqlite3Vacuum(pParse);}
break;
- case 255: /* cmd ::= PRAGMA nm dbnm */
+ case 254: /* cmd ::= PRAGMA nm dbnm */
{sqlite3Pragma(pParse,&yymsp[-1].minor.yy0,&yymsp[0].minor.yy0,0,0);}
break;
- case 256: /* cmd ::= PRAGMA nm dbnm EQ nmnum */
+ case 255: /* cmd ::= PRAGMA nm dbnm EQ nmnum */
{sqlite3Pragma(pParse,&yymsp[-3].minor.yy0,&yymsp[-2].minor.yy0,&yymsp[0].minor.yy0,0);}
break;
- case 257: /* cmd ::= PRAGMA nm dbnm LP nmnum RP */
+ case 256: /* cmd ::= PRAGMA nm dbnm LP nmnum RP */
{sqlite3Pragma(pParse,&yymsp[-4].minor.yy0,&yymsp[-3].minor.yy0,&yymsp[-1].minor.yy0,0);}
break;
- case 258: /* cmd ::= PRAGMA nm dbnm EQ minus_num */
+ case 257: /* cmd ::= PRAGMA nm dbnm EQ minus_num */
{sqlite3Pragma(pParse,&yymsp[-3].minor.yy0,&yymsp[-2].minor.yy0,&yymsp[0].minor.yy0,1);}
break;
- case 259: /* cmd ::= PRAGMA nm dbnm LP minus_num RP */
+ case 258: /* cmd ::= PRAGMA nm dbnm LP minus_num RP */
{sqlite3Pragma(pParse,&yymsp[-4].minor.yy0,&yymsp[-3].minor.yy0,&yymsp[-1].minor.yy0,1);}
break;
- case 270: /* cmd ::= createkw trigger_decl BEGIN trigger_cmd_list END */
+ case 268: /* cmd ::= createkw trigger_decl BEGIN trigger_cmd_list END */
{
Token all;
all.z = yymsp[-3].minor.yy0.z;
all.n = (int)(yymsp[0].minor.yy0.z - yymsp[-3].minor.yy0.z) + yymsp[0].minor.yy0.n;
- sqlite3FinishTrigger(pParse, yymsp[-1].minor.yy203, &all);
+ sqlite3FinishTrigger(pParse, yymsp[-1].minor.yy327, &all);
}
break;
- case 271: /* trigger_decl ::= temp TRIGGER ifnotexists nm dbnm trigger_time trigger_event ON fullname foreach_clause when_clause */
+ case 269: /* trigger_decl ::= temp TRIGGER ifnotexists nm dbnm trigger_time trigger_event ON fullname foreach_clause when_clause */
{
- sqlite3BeginTrigger(pParse, &yymsp[-7].minor.yy0, &yymsp[-6].minor.yy0, yymsp[-5].minor.yy4, yymsp[-4].minor.yy90.a, yymsp[-4].minor.yy90.b, yymsp[-2].minor.yy259, yymsp[0].minor.yy314, yymsp[-10].minor.yy4, yymsp[-8].minor.yy4);
+ sqlite3BeginTrigger(pParse, &yymsp[-7].minor.yy0, &yymsp[-6].minor.yy0, yymsp[-5].minor.yy392, yymsp[-4].minor.yy410.a, yymsp[-4].minor.yy410.b, yymsp[-2].minor.yy347, yymsp[0].minor.yy122, yymsp[-10].minor.yy392, yymsp[-8].minor.yy392);
yygotominor.yy0 = (yymsp[-6].minor.yy0.n==0?yymsp[-7].minor.yy0:yymsp[-6].minor.yy0);
}
break;
- case 272: /* trigger_time ::= BEFORE */
- case 275: /* trigger_time ::= */ yytestcase(yyruleno==275);
-{ yygotominor.yy4 = TK_BEFORE; }
+ case 270: /* trigger_time ::= BEFORE */
+ case 273: /* trigger_time ::= */ yytestcase(yyruleno==273);
+{ yygotominor.yy392 = TK_BEFORE; }
break;
- case 273: /* trigger_time ::= AFTER */
-{ yygotominor.yy4 = TK_AFTER; }
+ case 271: /* trigger_time ::= AFTER */
+{ yygotominor.yy392 = TK_AFTER; }
break;
- case 274: /* trigger_time ::= INSTEAD OF */
-{ yygotominor.yy4 = TK_INSTEAD;}
+ case 272: /* trigger_time ::= INSTEAD OF */
+{ yygotominor.yy392 = TK_INSTEAD;}
break;
- case 276: /* trigger_event ::= DELETE|INSERT */
- case 277: /* trigger_event ::= UPDATE */ yytestcase(yyruleno==277);
-{yygotominor.yy90.a = yymsp[0].major; yygotominor.yy90.b = 0;}
+ case 274: /* trigger_event ::= DELETE|INSERT */
+ case 275: /* trigger_event ::= UPDATE */ yytestcase(yyruleno==275);
+{yygotominor.yy410.a = yymsp[0].major; yygotominor.yy410.b = 0;}
break;
- case 278: /* trigger_event ::= UPDATE OF inscollist */
-{yygotominor.yy90.a = TK_UPDATE; yygotominor.yy90.b = yymsp[0].minor.yy384;}
+ case 276: /* trigger_event ::= UPDATE OF inscollist */
+{yygotominor.yy410.a = TK_UPDATE; yygotominor.yy410.b = yymsp[0].minor.yy180;}
break;
- case 281: /* when_clause ::= */
- case 303: /* key_opt ::= */ yytestcase(yyruleno==303);
-{ yygotominor.yy314 = 0; }
+ case 279: /* when_clause ::= */
+ case 301: /* key_opt ::= */ yytestcase(yyruleno==301);
+{ yygotominor.yy122 = 0; }
break;
- case 282: /* when_clause ::= WHEN expr */
- case 304: /* key_opt ::= KEY expr */ yytestcase(yyruleno==304);
-{ yygotominor.yy314 = yymsp[0].minor.yy118.pExpr; }
+ case 280: /* when_clause ::= WHEN expr */
+ case 302: /* key_opt ::= KEY expr */ yytestcase(yyruleno==302);
+{ yygotominor.yy122 = yymsp[0].minor.yy342.pExpr; }
break;
- case 283: /* trigger_cmd_list ::= trigger_cmd_list trigger_cmd SEMI */
+ case 281: /* trigger_cmd_list ::= trigger_cmd_list trigger_cmd SEMI */
{
- assert( yymsp[-2].minor.yy203!=0 );
- yymsp[-2].minor.yy203->pLast->pNext = yymsp[-1].minor.yy203;
- yymsp[-2].minor.yy203->pLast = yymsp[-1].minor.yy203;
- yygotominor.yy203 = yymsp[-2].minor.yy203;
+ assert( yymsp[-2].minor.yy327!=0 );
+ yymsp[-2].minor.yy327->pLast->pNext = yymsp[-1].minor.yy327;
+ yymsp[-2].minor.yy327->pLast = yymsp[-1].minor.yy327;
+ yygotominor.yy327 = yymsp[-2].minor.yy327;
}
break;
- case 284: /* trigger_cmd_list ::= trigger_cmd SEMI */
+ case 282: /* trigger_cmd_list ::= trigger_cmd SEMI */
{
- assert( yymsp[-1].minor.yy203!=0 );
- yymsp[-1].minor.yy203->pLast = yymsp[-1].minor.yy203;
- yygotominor.yy203 = yymsp[-1].minor.yy203;
+ assert( yymsp[-1].minor.yy327!=0 );
+ yymsp[-1].minor.yy327->pLast = yymsp[-1].minor.yy327;
+ yygotominor.yy327 = yymsp[-1].minor.yy327;
}
break;
- case 286: /* trnm ::= nm DOT nm */
+ case 284: /* trnm ::= nm DOT nm */
{
yygotominor.yy0 = yymsp[0].minor.yy0;
sqlite3ErrorMsg(pParse,
@@ -106364,121 +111723,121 @@ static void yy_reduce(
"statements within triggers");
}
break;
- case 288: /* tridxby ::= INDEXED BY nm */
+ case 286: /* tridxby ::= INDEXED BY nm */
{
sqlite3ErrorMsg(pParse,
"the INDEXED BY clause is not allowed on UPDATE or DELETE statements "
"within triggers");
}
break;
- case 289: /* tridxby ::= NOT INDEXED */
+ case 287: /* tridxby ::= NOT INDEXED */
{
sqlite3ErrorMsg(pParse,
"the NOT INDEXED clause is not allowed on UPDATE or DELETE statements "
"within triggers");
}
break;
- case 290: /* trigger_cmd ::= UPDATE orconf trnm tridxby SET setlist where_opt */
-{ yygotominor.yy203 = sqlite3TriggerUpdateStep(pParse->db, &yymsp[-4].minor.yy0, yymsp[-1].minor.yy322, yymsp[0].minor.yy314, yymsp[-5].minor.yy210); }
+ case 288: /* trigger_cmd ::= UPDATE orconf trnm tridxby SET setlist where_opt */
+{ yygotominor.yy327 = sqlite3TriggerUpdateStep(pParse->db, &yymsp[-4].minor.yy0, yymsp[-1].minor.yy442, yymsp[0].minor.yy122, yymsp[-5].minor.yy258); }
break;
- case 291: /* trigger_cmd ::= insert_cmd INTO trnm inscollist_opt VALUES LP itemlist RP */
-{yygotominor.yy203 = sqlite3TriggerInsertStep(pParse->db, &yymsp[-5].minor.yy0, yymsp[-4].minor.yy384, yymsp[-1].minor.yy322, 0, yymsp[-7].minor.yy210);}
+ case 289: /* trigger_cmd ::= insert_cmd INTO trnm inscollist_opt valuelist */
+{yygotominor.yy327 = sqlite3TriggerInsertStep(pParse->db, &yymsp[-2].minor.yy0, yymsp[-1].minor.yy180, yymsp[0].minor.yy487.pList, yymsp[0].minor.yy487.pSelect, yymsp[-4].minor.yy258);}
break;
- case 292: /* trigger_cmd ::= insert_cmd INTO trnm inscollist_opt select */
-{yygotominor.yy203 = sqlite3TriggerInsertStep(pParse->db, &yymsp[-2].minor.yy0, yymsp[-1].minor.yy384, 0, yymsp[0].minor.yy387, yymsp[-4].minor.yy210);}
+ case 290: /* trigger_cmd ::= insert_cmd INTO trnm inscollist_opt select */
+{yygotominor.yy327 = sqlite3TriggerInsertStep(pParse->db, &yymsp[-2].minor.yy0, yymsp[-1].minor.yy180, 0, yymsp[0].minor.yy159, yymsp[-4].minor.yy258);}
break;
- case 293: /* trigger_cmd ::= DELETE FROM trnm tridxby where_opt */
-{yygotominor.yy203 = sqlite3TriggerDeleteStep(pParse->db, &yymsp[-2].minor.yy0, yymsp[0].minor.yy314);}
+ case 291: /* trigger_cmd ::= DELETE FROM trnm tridxby where_opt */
+{yygotominor.yy327 = sqlite3TriggerDeleteStep(pParse->db, &yymsp[-2].minor.yy0, yymsp[0].minor.yy122);}
break;
- case 294: /* trigger_cmd ::= select */
-{yygotominor.yy203 = sqlite3TriggerSelectStep(pParse->db, yymsp[0].minor.yy387); }
+ case 292: /* trigger_cmd ::= select */
+{yygotominor.yy327 = sqlite3TriggerSelectStep(pParse->db, yymsp[0].minor.yy159); }
break;
- case 295: /* expr ::= RAISE LP IGNORE RP */
+ case 293: /* expr ::= RAISE LP IGNORE RP */
{
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_RAISE, 0, 0, 0);
- if( yygotominor.yy118.pExpr ){
- yygotominor.yy118.pExpr->affinity = OE_Ignore;
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_RAISE, 0, 0, 0);
+ if( yygotominor.yy342.pExpr ){
+ yygotominor.yy342.pExpr->affinity = OE_Ignore;
}
- yygotominor.yy118.zStart = yymsp[-3].minor.yy0.z;
- yygotominor.yy118.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
+ yygotominor.yy342.zStart = yymsp[-3].minor.yy0.z;
+ yygotominor.yy342.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
}
break;
- case 296: /* expr ::= RAISE LP raisetype COMMA nm RP */
+ case 294: /* expr ::= RAISE LP raisetype COMMA nm RP */
{
- yygotominor.yy118.pExpr = sqlite3PExpr(pParse, TK_RAISE, 0, 0, &yymsp[-1].minor.yy0);
- if( yygotominor.yy118.pExpr ) {
- yygotominor.yy118.pExpr->affinity = (char)yymsp[-3].minor.yy4;
+ yygotominor.yy342.pExpr = sqlite3PExpr(pParse, TK_RAISE, 0, 0, &yymsp[-1].minor.yy0);
+ if( yygotominor.yy342.pExpr ) {
+ yygotominor.yy342.pExpr->affinity = (char)yymsp[-3].minor.yy392;
}
- yygotominor.yy118.zStart = yymsp[-5].minor.yy0.z;
- yygotominor.yy118.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
+ yygotominor.yy342.zStart = yymsp[-5].minor.yy0.z;
+ yygotominor.yy342.zEnd = &yymsp[0].minor.yy0.z[yymsp[0].minor.yy0.n];
}
break;
- case 297: /* raisetype ::= ROLLBACK */
-{yygotominor.yy4 = OE_Rollback;}
+ case 295: /* raisetype ::= ROLLBACK */
+{yygotominor.yy392 = OE_Rollback;}
break;
- case 299: /* raisetype ::= FAIL */
-{yygotominor.yy4 = OE_Fail;}
+ case 297: /* raisetype ::= FAIL */
+{yygotominor.yy392 = OE_Fail;}
break;
- case 300: /* cmd ::= DROP TRIGGER ifexists fullname */
+ case 298: /* cmd ::= DROP TRIGGER ifexists fullname */
{
- sqlite3DropTrigger(pParse,yymsp[0].minor.yy259,yymsp[-1].minor.yy4);
+ sqlite3DropTrigger(pParse,yymsp[0].minor.yy347,yymsp[-1].minor.yy392);
}
break;
- case 301: /* cmd ::= ATTACH database_kw_opt expr AS expr key_opt */
+ case 299: /* cmd ::= ATTACH database_kw_opt expr AS expr key_opt */
{
- sqlite3Attach(pParse, yymsp[-3].minor.yy118.pExpr, yymsp[-1].minor.yy118.pExpr, yymsp[0].minor.yy314);
+ sqlite3Attach(pParse, yymsp[-3].minor.yy342.pExpr, yymsp[-1].minor.yy342.pExpr, yymsp[0].minor.yy122);
}
break;
- case 302: /* cmd ::= DETACH database_kw_opt expr */
+ case 300: /* cmd ::= DETACH database_kw_opt expr */
{
- sqlite3Detach(pParse, yymsp[0].minor.yy118.pExpr);
+ sqlite3Detach(pParse, yymsp[0].minor.yy342.pExpr);
}
break;
- case 307: /* cmd ::= REINDEX */
+ case 305: /* cmd ::= REINDEX */
{sqlite3Reindex(pParse, 0, 0);}
break;
- case 308: /* cmd ::= REINDEX nm dbnm */
+ case 306: /* cmd ::= REINDEX nm dbnm */
{sqlite3Reindex(pParse, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0);}
break;
- case 309: /* cmd ::= ANALYZE */
+ case 307: /* cmd ::= ANALYZE */
{sqlite3Analyze(pParse, 0, 0);}
break;
- case 310: /* cmd ::= ANALYZE nm dbnm */
+ case 308: /* cmd ::= ANALYZE nm dbnm */
{sqlite3Analyze(pParse, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0);}
break;
- case 311: /* cmd ::= ALTER TABLE fullname RENAME TO nm */
+ case 309: /* cmd ::= ALTER TABLE fullname RENAME TO nm */
{
- sqlite3AlterRenameTable(pParse,yymsp[-3].minor.yy259,&yymsp[0].minor.yy0);
+ sqlite3AlterRenameTable(pParse,yymsp[-3].minor.yy347,&yymsp[0].minor.yy0);
}
break;
- case 312: /* cmd ::= ALTER TABLE add_column_fullname ADD kwcolumn_opt column */
+ case 310: /* cmd ::= ALTER TABLE add_column_fullname ADD kwcolumn_opt column */
{
sqlite3AlterFinishAddColumn(pParse, &yymsp[0].minor.yy0);
}
break;
- case 313: /* add_column_fullname ::= fullname */
+ case 311: /* add_column_fullname ::= fullname */
{
pParse->db->lookaside.bEnabled = 0;
- sqlite3AlterBeginAddColumn(pParse, yymsp[0].minor.yy259);
+ sqlite3AlterBeginAddColumn(pParse, yymsp[0].minor.yy347);
}
break;
- case 316: /* cmd ::= create_vtab */
+ case 314: /* cmd ::= create_vtab */
{sqlite3VtabFinishParse(pParse,0);}
break;
- case 317: /* cmd ::= create_vtab LP vtabarglist RP */
+ case 315: /* cmd ::= create_vtab LP vtabarglist RP */
{sqlite3VtabFinishParse(pParse,&yymsp[0].minor.yy0);}
break;
- case 318: /* create_vtab ::= createkw VIRTUAL TABLE nm dbnm USING nm */
+ case 316: /* create_vtab ::= createkw VIRTUAL TABLE ifnotexists nm dbnm USING nm */
{
- sqlite3VtabBeginParse(pParse, &yymsp[-3].minor.yy0, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0);
+ sqlite3VtabBeginParse(pParse, &yymsp[-3].minor.yy0, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, yymsp[-4].minor.yy392);
}
break;
- case 321: /* vtabarg ::= */
+ case 319: /* vtabarg ::= */
{sqlite3VtabArgInit(pParse);}
break;
- case 323: /* vtabargtoken ::= ANY */
- case 324: /* vtabargtoken ::= lp anylist RP */ yytestcase(yyruleno==324);
- case 325: /* lp ::= LP */ yytestcase(yyruleno==325);
+ case 321: /* vtabargtoken ::= ANY */
+ case 322: /* vtabargtoken ::= lp anylist RP */ yytestcase(yyruleno==322);
+ case 323: /* lp ::= LP */ yytestcase(yyruleno==323);
{sqlite3VtabArgExtend(pParse,&yymsp[0].minor.yy0);}
break;
default:
@@ -106498,32 +111857,28 @@ static void yy_reduce(
/* (44) type ::= */ yytestcase(yyruleno==44);
/* (51) signed ::= plus_num */ yytestcase(yyruleno==51);
/* (52) signed ::= minus_num */ yytestcase(yyruleno==52);
- /* (53) carglist ::= carglist carg */ yytestcase(yyruleno==53);
+ /* (53) carglist ::= carglist ccons */ yytestcase(yyruleno==53);
/* (54) carglist ::= */ yytestcase(yyruleno==54);
- /* (55) carg ::= CONSTRAINT nm ccons */ yytestcase(yyruleno==55);
- /* (56) carg ::= ccons */ yytestcase(yyruleno==56);
- /* (62) ccons ::= NULL onconf */ yytestcase(yyruleno==62);
- /* (90) conslist ::= conslist COMMA tcons */ yytestcase(yyruleno==90);
- /* (91) conslist ::= conslist tcons */ yytestcase(yyruleno==91);
- /* (92) conslist ::= tcons */ yytestcase(yyruleno==92);
- /* (93) tcons ::= CONSTRAINT nm */ yytestcase(yyruleno==93);
- /* (268) plus_opt ::= PLUS */ yytestcase(yyruleno==268);
- /* (269) plus_opt ::= */ yytestcase(yyruleno==269);
- /* (279) foreach_clause ::= */ yytestcase(yyruleno==279);
- /* (280) foreach_clause ::= FOR EACH ROW */ yytestcase(yyruleno==280);
- /* (287) tridxby ::= */ yytestcase(yyruleno==287);
- /* (305) database_kw_opt ::= DATABASE */ yytestcase(yyruleno==305);
- /* (306) database_kw_opt ::= */ yytestcase(yyruleno==306);
- /* (314) kwcolumn_opt ::= */ yytestcase(yyruleno==314);
- /* (315) kwcolumn_opt ::= COLUMNKW */ yytestcase(yyruleno==315);
- /* (319) vtabarglist ::= vtabarg */ yytestcase(yyruleno==319);
- /* (320) vtabarglist ::= vtabarglist COMMA vtabarg */ yytestcase(yyruleno==320);
- /* (322) vtabarg ::= vtabarg vtabargtoken */ yytestcase(yyruleno==322);
- /* (326) anylist ::= */ yytestcase(yyruleno==326);
- /* (327) anylist ::= anylist LP anylist RP */ yytestcase(yyruleno==327);
- /* (328) anylist ::= anylist ANY */ yytestcase(yyruleno==328);
+ /* (61) ccons ::= NULL onconf */ yytestcase(yyruleno==61);
+ /* (89) conslist ::= conslist tconscomma tcons */ yytestcase(yyruleno==89);
+ /* (90) conslist ::= tcons */ yytestcase(yyruleno==90);
+ /* (92) tconscomma ::= */ yytestcase(yyruleno==92);
+ /* (277) foreach_clause ::= */ yytestcase(yyruleno==277);
+ /* (278) foreach_clause ::= FOR EACH ROW */ yytestcase(yyruleno==278);
+ /* (285) tridxby ::= */ yytestcase(yyruleno==285);
+ /* (303) database_kw_opt ::= DATABASE */ yytestcase(yyruleno==303);
+ /* (304) database_kw_opt ::= */ yytestcase(yyruleno==304);
+ /* (312) kwcolumn_opt ::= */ yytestcase(yyruleno==312);
+ /* (313) kwcolumn_opt ::= COLUMNKW */ yytestcase(yyruleno==313);
+ /* (317) vtabarglist ::= vtabarg */ yytestcase(yyruleno==317);
+ /* (318) vtabarglist ::= vtabarglist COMMA vtabarg */ yytestcase(yyruleno==318);
+ /* (320) vtabarg ::= vtabarg vtabargtoken */ yytestcase(yyruleno==320);
+ /* (324) anylist ::= */ yytestcase(yyruleno==324);
+ /* (325) anylist ::= anylist LP anylist RP */ yytestcase(yyruleno==325);
+ /* (326) anylist ::= anylist ANY */ yytestcase(yyruleno==326);
break;
};
+ assert( yyruleno>=0 && yyruleno<sizeof(yyRuleInfo)/sizeof(yyRuleInfo[0]) );
yygoto = yyRuleInfo[yyruleno].lhs;
yysize = yyRuleInfo[yyruleno].nrhs;
yypParser->yyidx -= yysize;
@@ -106585,7 +111940,6 @@ static void yy_syntax_error(
UNUSED_PARAMETER(yymajor); /* Silence some compiler warnings */
assert( TOKEN.z[0] ); /* The tokenizer always gives us a token */
sqlite3ErrorMsg(pParse, "near \"%T\": syntax error", &TOKEN);
- pParse->parseError = 1;
sqlite3ParserARG_STORE; /* Suppress warning about unused %extra_argument variable */
}
@@ -106634,7 +111988,9 @@ SQLITE_PRIVATE void sqlite3Parser(
){
YYMINORTYPE yyminorunion;
int yyact; /* The parser action. */
+#if !defined(YYERRORSYMBOL) && !defined(YYNOERRORRECOVERY)
int yyendofinput; /* True if we are at the end of input */
+#endif
#ifdef YYERRORSYMBOL
int yyerrorhit = 0; /* True if yymajor has invoked an error */
#endif
@@ -106657,7 +112013,9 @@ SQLITE_PRIVATE void sqlite3Parser(
yypParser->yystack[0].major = 0;
}
yyminorunion.yy0 = yyminor;
+#if !defined(YYERRORSYMBOL) && !defined(YYNOERRORRECOVERY)
yyendofinput = (yymajor==0);
+#endif
sqlite3ParserARG_STORE;
#ifndef NDEBUG
@@ -106669,7 +112027,6 @@ SQLITE_PRIVATE void sqlite3Parser(
do{
yyact = yy_find_shift_action(yypParser,(YYCODETYPE)yymajor);
if( yyact<YYNSTATE ){
- assert( !yyendofinput ); /* Impossible to shift the $ token */
yy_shift(yypParser,yyact,yymajor,&yyminorunion);
yypParser->yyerrcnt--;
yymajor = YYNOCODE;
@@ -106796,6 +112153,7 @@ SQLITE_PRIVATE void sqlite3Parser(
** individual tokens and sends those tokens one-by-one over to the
** parser for analysis.
*/
+/* #include <stdlib.h> */
/*
** The charMap() macro maps alphabetic characters into their
@@ -107176,7 +112534,7 @@ SQLITE_PRIVATE int sqlite3GetToken(const unsigned char *z, int *tokenType){
}
case '-': {
if( z[1]=='-' ){
- /* IMP: R-15891-05542 -- syntax diagram for comments */
+ /* IMP: R-50417-27976 -- syntax diagram for comments */
for(i=2; (c=z[i])!=0 && c!='\n'; i++){}
*tokenType = TK_SPACE; /* IMP: R-22934-25134 */
return i;
@@ -107209,7 +112567,7 @@ SQLITE_PRIVATE int sqlite3GetToken(const unsigned char *z, int *tokenType){
*tokenType = TK_SLASH;
return 1;
}
- /* IMP: R-15891-05542 -- syntax diagram for comments */
+ /* IMP: R-50417-27976 -- syntax diagram for comments */
for(i=3, c=z[2]; (c!='*' || z[i]!='/') && (c=z[i])!=0; i++){}
if( c ) i++;
*tokenType = TK_SPACE; /* IMP: R-22934-25134 */
@@ -108003,8 +113361,8 @@ SQLITE_API const char *sqlite3_sourceid(void){ return SQLITE_SOURCE_ID; }
*/
SQLITE_API int sqlite3_libversion_number(void){ return SQLITE_VERSION_NUMBER; }
-/* IMPLEMENTATION-OF: R-54823-41343 The sqlite3_threadsafe() function returns
-** zero if and only if SQLite was compiled mutexing code omitted due to
+/* IMPLEMENTATION-OF: R-20790-14025 The sqlite3_threadsafe() function returns
+** zero if and only if SQLite was compiled with mutexing code omitted due to
** the SQLITE_THREADSAFE compile-time option being set to 0.
*/
SQLITE_API int sqlite3_threadsafe(void){ return SQLITE_THREADSAFE; }
@@ -108029,6 +113387,15 @@ SQLITE_PRIVATE void (*sqlite3IoTrace)(const char*, ...) = 0;
SQLITE_API char *sqlite3_temp_directory = 0;
/*
+** If the following global variable points to a string which is the
+** name of a directory, then that directory will be used to store
+** all database files specified with a relative pathname.
+**
+** See also the "PRAGMA data_store_directory" SQL command.
+*/
+SQLITE_API char *sqlite3_data_directory = 0;
+
+/*
** Initialize SQLite.
**
** This routine must be called to initialize the memory allocation,
@@ -108060,7 +113427,7 @@ SQLITE_API char *sqlite3_temp_directory = 0;
** without blocking.
*/
SQLITE_API int sqlite3_initialize(void){
- sqlite3_mutex *pMaster; /* The main static mutex */
+ MUTEX_LOGIC( sqlite3_mutex *pMaster; ) /* The main static mutex */
int rc; /* Result code */
#ifdef SQLITE_OMIT_WSD
@@ -108077,6 +113444,13 @@ SQLITE_API int sqlite3_initialize(void){
*/
if( sqlite3GlobalConfig.isInit ) return SQLITE_OK;
+#ifdef SQLITE_ENABLE_SQLLOG
+ {
+ extern void sqlite3_init_sqllog(void);
+ sqlite3_init_sqllog();
+ }
+#endif
+
/* Make sure the mutex subsystem is initialized. If unable to
** initialize the mutex subsystem, return early with the error.
** If the system is so sick that we are unable to allocate a mutex,
@@ -108094,7 +113468,7 @@ SQLITE_API int sqlite3_initialize(void){
** malloc subsystem - this implies that the allocation of a static
** mutex must not require support from the malloc subsystem.
*/
- pMaster = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER);
+ MUTEX_LOGIC( pMaster = sqlite3MutexAlloc(SQLITE_MUTEX_STATIC_MASTER); )
sqlite3_mutex_enter(pMaster);
sqlite3GlobalConfig.isMutexInit = 1;
if( !sqlite3GlobalConfig.isMallocInit ){
@@ -108188,6 +113562,16 @@ SQLITE_API int sqlite3_initialize(void){
#endif
#endif
+ /* Do extra initialization steps requested by the SQLITE_EXTRA_INIT
+ ** compile-time option.
+ */
+#ifdef SQLITE_EXTRA_INIT
+ if( rc==SQLITE_OK && sqlite3GlobalConfig.isInit ){
+ int SQLITE_EXTRA_INIT(const char*);
+ rc = SQLITE_EXTRA_INIT(0);
+ }
+#endif
+
return rc;
}
@@ -108201,6 +113585,10 @@ SQLITE_API int sqlite3_initialize(void){
*/
SQLITE_API int sqlite3_shutdown(void){
if( sqlite3GlobalConfig.isInit ){
+#ifdef SQLITE_EXTRA_SHUTDOWN
+ void SQLITE_EXTRA_SHUTDOWN(void);
+ SQLITE_EXTRA_SHUTDOWN();
+#endif
sqlite3_os_end();
sqlite3_reset_auto_extension();
sqlite3GlobalConfig.isInit = 0;
@@ -108212,6 +113600,18 @@ SQLITE_API int sqlite3_shutdown(void){
if( sqlite3GlobalConfig.isMallocInit ){
sqlite3MallocEnd();
sqlite3GlobalConfig.isMallocInit = 0;
+
+#ifndef SQLITE_OMIT_SHUTDOWN_DIRECTORIES
+ /* The heap subsystem has now been shutdown and these values are supposed
+ ** to be NULL or point to memory that was obtained from sqlite3_malloc(),
+ ** which would rely on that heap subsystem; therefore, make sure these
+ ** values cannot refer to heap memory that was just invalidated when the
+ ** heap subsystem was shutdown. This is only done if the current call to
+ ** this function resulted in the heap subsystem actually being shutdown.
+ */
+ sqlite3_data_directory = 0;
+ sqlite3_temp_directory = 0;
+#endif
}
if( sqlite3GlobalConfig.isMutexInit ){
sqlite3MutexEnd();
@@ -108309,16 +113709,25 @@ SQLITE_API int sqlite3_config(int op, ...){
}
case SQLITE_CONFIG_PCACHE: {
- /* Specify an alternative page cache implementation */
- sqlite3GlobalConfig.pcache = *va_arg(ap, sqlite3_pcache_methods*);
+ /* no-op */
break;
}
-
case SQLITE_CONFIG_GETPCACHE: {
- if( sqlite3GlobalConfig.pcache.xInit==0 ){
+ /* now an error */
+ rc = SQLITE_ERROR;
+ break;
+ }
+
+ case SQLITE_CONFIG_PCACHE2: {
+ /* Specify an alternative page cache implementation */
+ sqlite3GlobalConfig.pcache2 = *va_arg(ap, sqlite3_pcache_methods2*);
+ break;
+ }
+ case SQLITE_CONFIG_GETPCACHE2: {
+ if( sqlite3GlobalConfig.pcache2.xInit==0 ){
sqlite3PCacheSetDefault();
}
- *va_arg(ap, sqlite3_pcache_methods*) = sqlite3GlobalConfig.pcache;
+ *va_arg(ap, sqlite3_pcache_methods2*) = sqlite3GlobalConfig.pcache2;
break;
}
@@ -108385,6 +113794,20 @@ SQLITE_API int sqlite3_config(int op, ...){
break;
}
+ case SQLITE_CONFIG_COVERING_INDEX_SCAN: {
+ sqlite3GlobalConfig.bUseCis = va_arg(ap, int);
+ break;
+ }
+
+#ifdef SQLITE_ENABLE_SQLLOG
+ case SQLITE_CONFIG_SQLLOG: {
+ typedef void(*SQLLOGFUNC_t)(void*, sqlite3*, const char*, int);
+ sqlite3GlobalConfig.xSqllog = va_arg(ap, SQLLOGFUNC_t);
+ sqlite3GlobalConfig.pSqllogArg = va_arg(ap, void *);
+ break;
+ }
+#endif
+
default: {
rc = SQLITE_ERROR;
break;
@@ -108417,21 +113840,21 @@ static int setupLookaside(sqlite3 *db, void *pBuf, int sz, int cnt){
if( db->lookaside.bMalloced ){
sqlite3_free(db->lookaside.pStart);
}
- /* The size of a lookaside slot needs to be larger than a pointer
- ** to be useful.
+ /* The size of a lookaside slot after ROUNDDOWN8 needs to be larger
+ ** than a pointer to be useful.
*/
+ sz = ROUNDDOWN8(sz); /* IMP: R-33038-09382 */
if( sz<=(int)sizeof(LookasideSlot*) ) sz = 0;
if( cnt<0 ) cnt = 0;
if( sz==0 || cnt==0 ){
sz = 0;
pStart = 0;
}else if( pBuf==0 ){
- sz = ROUNDDOWN8(sz); /* IMP: R-33038-09382 */
sqlite3BeginBenignMalloc();
pStart = sqlite3Malloc( sz*cnt ); /* IMP: R-61949-35727 */
sqlite3EndBenignMalloc();
+ if( pStart ) cnt = sqlite3MallocSize(pStart)/sz;
}else{
- sz = ROUNDDOWN8(sz); /* IMP: R-33038-09382 */
pStart = pBuf;
}
db->lookaside.pStart = pStart;
@@ -108466,6 +113889,26 @@ SQLITE_API sqlite3_mutex *sqlite3_db_mutex(sqlite3 *db){
}
/*
+** Free up as much memory as we can from the given database
+** connection.
+*/
+SQLITE_API int sqlite3_db_release_memory(sqlite3 *db){
+ int i;
+ sqlite3_mutex_enter(db->mutex);
+ sqlite3BtreeEnterAll(db);
+ for(i=0; i<db->nDb; i++){
+ Btree *pBt = db->aDb[i].pBt;
+ if( pBt ){
+ Pager *pPager = sqlite3BtreePager(pBt);
+ sqlite3PagerShrink(pPager);
+ }
+ }
+ sqlite3BtreeLeaveAll(db);
+ sqlite3_mutex_leave(db->mutex);
+ return SQLITE_OK;
+}
+
+/*
** Configuration settings for an individual database connection
*/
SQLITE_API int sqlite3_db_config(sqlite3 *db, int op, ...){
@@ -108632,12 +114075,48 @@ static void functionDestroy(sqlite3 *db, FuncDef *p){
}
/*
-** Close an existing SQLite database
+** Disconnect all sqlite3_vtab objects that belong to database connection
+** db. This is called when db is being closed.
*/
-SQLITE_API int sqlite3_close(sqlite3 *db){
- HashElem *i; /* Hash table iterator */
+static void disconnectAllVtab(sqlite3 *db){
+#ifndef SQLITE_OMIT_VIRTUALTABLE
+ int i;
+ sqlite3BtreeEnterAll(db);
+ for(i=0; i<db->nDb; i++){
+ Schema *pSchema = db->aDb[i].pSchema;
+ if( db->aDb[i].pSchema ){
+ HashElem *p;
+ for(p=sqliteHashFirst(&pSchema->tblHash); p; p=sqliteHashNext(p)){
+ Table *pTab = (Table *)sqliteHashData(p);
+ if( IsVirtual(pTab) ) sqlite3VtabDisconnect(db, pTab);
+ }
+ }
+ }
+ sqlite3BtreeLeaveAll(db);
+#else
+ UNUSED_PARAMETER(db);
+#endif
+}
+
+/*
+** Return TRUE if database connection db has unfinalized prepared
+** statements or unfinished sqlite3_backup objects.
+*/
+static int connectionIsBusy(sqlite3 *db){
int j;
+ assert( sqlite3_mutex_held(db->mutex) );
+ if( db->pVdbe ) return 1;
+ for(j=0; j<db->nDb; j++){
+ Btree *pBt = db->aDb[j].pBt;
+ if( pBt && sqlite3BtreeIsInBackup(pBt) ) return 1;
+ }
+ return 0;
+}
+/*
+** Close an existing SQLite database
+*/
+static int sqlite3Close(sqlite3 *db, int forceZombie){
if( !db ){
return SQLITE_OK;
}
@@ -108646,10 +114125,10 @@ SQLITE_API int sqlite3_close(sqlite3 *db){
}
sqlite3_mutex_enter(db->mutex);
- /* Force xDestroy calls on all virtual tables */
- sqlite3ResetInternalSchema(db, -1);
+ /* Force xDisconnect calls on all virtual tables */
+ disconnectAllVtab(db);
- /* If a transaction is open, the ResetInternalSchema() call above
+ /* If a transaction is open, the disconnectAllVtab() call above
** will not have called the xDisconnect() method on any virtual
** tables in the db->aVTrans[] array. The following sqlite3VtabRollback()
** call will do so. We need to do this before the check for active
@@ -108658,28 +114137,74 @@ SQLITE_API int sqlite3_close(sqlite3 *db){
*/
sqlite3VtabRollback(db);
- /* If there are any outstanding VMs, return SQLITE_BUSY. */
- if( db->pVdbe ){
- sqlite3Error(db, SQLITE_BUSY,
- "unable to close due to unfinalised statements");
+ /* Legacy behavior (sqlite3_close() behavior) is to return
+ ** SQLITE_BUSY if the connection can not be closed immediately.
+ */
+ if( !forceZombie && connectionIsBusy(db) ){
+ sqlite3Error(db, SQLITE_BUSY, "unable to close due to unfinalized "
+ "statements or unfinished backups");
sqlite3_mutex_leave(db->mutex);
return SQLITE_BUSY;
}
- assert( sqlite3SafetyCheckSickOrOk(db) );
- for(j=0; j<db->nDb; j++){
- Btree *pBt = db->aDb[j].pBt;
- if( pBt && sqlite3BtreeIsInBackup(pBt) ){
- sqlite3Error(db, SQLITE_BUSY,
- "unable to close due to unfinished backup operation");
- sqlite3_mutex_leave(db->mutex);
- return SQLITE_BUSY;
- }
+#ifdef SQLITE_ENABLE_SQLLOG
+ if( sqlite3GlobalConfig.xSqllog ){
+ /* Closing the handle. Fourth parameter is passed the value 2. */
+ sqlite3GlobalConfig.xSqllog(sqlite3GlobalConfig.pSqllogArg, db, 0, 2);
+ }
+#endif
+
+ /* Convert the connection into a zombie and then close it.
+ */
+ db->magic = SQLITE_MAGIC_ZOMBIE;
+ sqlite3LeaveMutexAndCloseZombie(db);
+ return SQLITE_OK;
+}
+
+/*
+** Two variations on the public interface for closing a database
+** connection. The sqlite3_close() version returns SQLITE_BUSY and
+** leaves the connection option if there are unfinalized prepared
+** statements or unfinished sqlite3_backups. The sqlite3_close_v2()
+** version forces the connection to become a zombie if there are
+** unclosed resources, and arranges for deallocation when the last
+** prepare statement or sqlite3_backup closes.
+*/
+SQLITE_API int sqlite3_close(sqlite3 *db){ return sqlite3Close(db,0); }
+SQLITE_API int sqlite3_close_v2(sqlite3 *db){ return sqlite3Close(db,1); }
+
+
+/*
+** Close the mutex on database connection db.
+**
+** Furthermore, if database connection db is a zombie (meaning that there
+** has been a prior call to sqlite3_close(db) or sqlite3_close_v2(db)) and
+** every sqlite3_stmt has now been finalized and every sqlite3_backup has
+** finished, then free all resources.
+*/
+SQLITE_PRIVATE void sqlite3LeaveMutexAndCloseZombie(sqlite3 *db){
+ HashElem *i; /* Hash table iterator */
+ int j;
+
+ /* If there are outstanding sqlite3_stmt or sqlite3_backup objects
+ ** or if the connection has not yet been closed by sqlite3_close_v2(),
+ ** then just leave the mutex and return.
+ */
+ if( db->magic!=SQLITE_MAGIC_ZOMBIE || connectionIsBusy(db) ){
+ sqlite3_mutex_leave(db->mutex);
+ return;
}
+ /* If we reach this point, it means that the database connection has
+ ** closed all sqlite3_stmt and sqlite3_backup objects and has been
+ ** passed to sqlite3_close (meaning that it is a zombie). Therefore,
+ ** go ahead and free all resources.
+ */
+
/* Free any outstanding Savepoint structures. */
sqlite3CloseSavepoints(db);
+ /* Close all database connections */
for(j=0; j<db->nDb; j++){
struct Db *pDb = &db->aDb[j];
if( pDb->pBt ){
@@ -108690,15 +114215,22 @@ SQLITE_API int sqlite3_close(sqlite3 *db){
}
}
}
- sqlite3ResetInternalSchema(db, -1);
+ /* Clear the TEMP schema separately and last */
+ if( db->aDb[1].pSchema ){
+ sqlite3SchemaClear(db->aDb[1].pSchema);
+ }
+ sqlite3VtabUnlockList(db);
+
+ /* Free up the array of auxiliary databases */
+ sqlite3CollapseDatabaseArray(db);
+ assert( db->nDb<=2 );
+ assert( db->aDb==db->aDbStatic );
/* Tell the code in notify.c that the connection no longer holds any
** locks and does not require any further unlock-notify callbacks.
*/
sqlite3ConnectionClosed(db);
- assert( db->nDb<=2 );
- assert( db->aDb==db->aDbStatic );
for(j=0; j<ArraySize(db->aFunc.a); j++){
FuncDef *pNext, *pHash, *p;
for(p=db->aFunc.a[j]; p; p=pHash){
@@ -108756,32 +114288,35 @@ SQLITE_API int sqlite3_close(sqlite3 *db){
sqlite3_free(db->lookaside.pStart);
}
sqlite3_free(db);
- return SQLITE_OK;
}
/*
-** Rollback all database files.
+** Rollback all database files. If tripCode is not SQLITE_OK, then
+** any open cursors are invalidated ("tripped" - as in "tripping a circuit
+** breaker") and made to return tripCode if there are any further
+** attempts to use that cursor.
*/
-SQLITE_PRIVATE void sqlite3RollbackAll(sqlite3 *db){
+SQLITE_PRIVATE void sqlite3RollbackAll(sqlite3 *db, int tripCode){
int i;
int inTrans = 0;
assert( sqlite3_mutex_held(db->mutex) );
sqlite3BeginBenignMalloc();
for(i=0; i<db->nDb; i++){
- if( db->aDb[i].pBt ){
- if( sqlite3BtreeIsInTrans(db->aDb[i].pBt) ){
+ Btree *p = db->aDb[i].pBt;
+ if( p ){
+ if( sqlite3BtreeIsInTrans(p) ){
inTrans = 1;
}
- sqlite3BtreeRollback(db->aDb[i].pBt);
+ sqlite3BtreeRollback(p, tripCode);
db->aDb[i].inTrans = 0;
}
}
sqlite3VtabRollback(db);
sqlite3EndBenignMalloc();
- if( db->flags&SQLITE_InternChanges ){
+ if( (db->flags&SQLITE_InternChanges)!=0 && db->init.busy==0 ){
sqlite3ExpirePreparedStatements(db);
- sqlite3ResetInternalSchema(db, -1);
+ sqlite3ResetAllSchemasOfConnection(db);
}
/* Any deferred constraint violations have now been resolved. */
@@ -108827,12 +114362,21 @@ SQLITE_PRIVATE const char *sqlite3ErrStr(int rc){
/* SQLITE_RANGE */ "bind or column index out of range",
/* SQLITE_NOTADB */ "file is encrypted or is not a database",
};
- rc &= 0xff;
- if( ALWAYS(rc>=0) && rc<(int)(sizeof(aMsg)/sizeof(aMsg[0])) && aMsg[rc]!=0 ){
- return aMsg[rc];
- }else{
- return "unknown error";
+ const char *zErr = "unknown error";
+ switch( rc ){
+ case SQLITE_ABORT_ROLLBACK: {
+ zErr = "abort due to ROLLBACK";
+ break;
+ }
+ default: {
+ rc &= 0xff;
+ if( ALWAYS(rc>=0) && rc<ArraySize(aMsg) && aMsg[rc]!=0 ){
+ zErr = aMsg[rc];
+ }
+ break;
+ }
}
+ return zErr;
}
/*
@@ -108912,6 +114456,7 @@ SQLITE_API int sqlite3_busy_handler(
db->busyHandler.xFunc = xBusy;
db->busyHandler.pArg = pArg;
db->busyHandler.nBusy = 0;
+ db->busyTimeout = 0;
sqlite3_mutex_leave(db->mutex);
return SQLITE_OK;
}
@@ -108949,8 +114494,8 @@ SQLITE_API void sqlite3_progress_handler(
*/
SQLITE_API int sqlite3_busy_timeout(sqlite3 *db, int ms){
if( ms>0 ){
- db->busyTimeout = ms;
sqlite3_busy_handler(db, sqliteDefaultBusyCallback, (void*)db);
+ db->busyTimeout = ms;
}else{
sqlite3_busy_handler(db, 0, 0);
}
@@ -109158,13 +114703,13 @@ SQLITE_API int sqlite3_overload_function(
int nArg
){
int nName = sqlite3Strlen30(zName);
- int rc;
+ int rc = SQLITE_OK;
sqlite3_mutex_enter(db->mutex);
if( sqlite3FindFunction(db, zName, nName, nArg, SQLITE_UTF8, 0)==0 ){
- sqlite3CreateFunc(db, zName, nArg, SQLITE_UTF8,
- 0, sqlite3InvalidFunction, 0, 0, 0);
+ rc = sqlite3CreateFunc(db, zName, nArg, SQLITE_UTF8,
+ 0, sqlite3InvalidFunction, 0, 0, 0);
}
- rc = sqlite3ApiExit(db, SQLITE_OK);
+ rc = sqlite3ApiExit(db, rc);
sqlite3_mutex_leave(db->mutex);
return rc;
}
@@ -109210,9 +114755,8 @@ SQLITE_API void *sqlite3_profile(
}
#endif /* SQLITE_OMIT_TRACE */
-/*** EXPERIMENTAL ***
-**
-** Register a function to be invoked when a transaction comments.
+/*
+** Register a function to be invoked when a transaction commits.
** If the invoked function returns non-zero, then the commit becomes a
** rollback.
*/
@@ -109565,6 +115109,15 @@ SQLITE_API int sqlite3_extended_errcode(sqlite3 *db){
}
/*
+** Return a string that describes the kind of error specified in the
+** argument. For now, this simply calls the internal sqlite3ErrStr()
+** function.
+*/
+SQLITE_API const char *sqlite3_errstr(int rc){
+ return sqlite3ErrStr(rc);
+}
+
+/*
** Create a new collating function for database "db". The name is zName
** and the encoding is enc.
*/
@@ -109572,7 +115125,6 @@ static int createCollation(
sqlite3* db,
const char *zName,
u8 enc,
- u8 collType,
void* pCtx,
int(*xCompare)(void*,int,const void*,int,const void*),
void(*xDel)(void*)
@@ -109637,7 +115189,6 @@ static int createCollation(
pColl->pUser = pCtx;
pColl->xDel = xDel;
pColl->enc = (u8)(enc2 | (enc & SQLITE_UTF16_ALIGNED));
- pColl->type = collType;
sqlite3Error(db, SQLITE_OK, 0);
return SQLITE_OK;
}
@@ -109913,10 +115464,12 @@ SQLITE_PRIVATE int sqlite3ParseUri(
{ "ro", SQLITE_OPEN_READONLY },
{ "rw", SQLITE_OPEN_READWRITE },
{ "rwc", SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE },
+ { "memory", SQLITE_OPEN_MEMORY },
{ 0, 0 }
};
- mask = SQLITE_OPEN_READONLY|SQLITE_OPEN_READWRITE|SQLITE_OPEN_CREATE;
+ mask = SQLITE_OPEN_READONLY | SQLITE_OPEN_READWRITE
+ | SQLITE_OPEN_CREATE | SQLITE_OPEN_MEMORY;
aMode = aOpenMode;
limit = mask & flags;
zModeType = "access";
@@ -109937,7 +115490,7 @@ SQLITE_PRIVATE int sqlite3ParseUri(
rc = SQLITE_ERROR;
goto parse_uri_out;
}
- if( mode>limit ){
+ if( (mode & ~SQLITE_OPEN_MEMORY)>limit ){
*pzErrMsg = sqlite3_mprintf("%s mode not allowed: %s",
zModeType, zVal);
rc = SQLITE_PERM;
@@ -109956,6 +115509,7 @@ SQLITE_PRIVATE int sqlite3ParseUri(
memcpy(zFile, zUri, nUri);
zFile[nUri] = '\0';
zFile[nUri+1] = '\0';
+ flags &= ~SQLITE_OPEN_URI;
}
*ppVfs = sqlite3_vfs_find(zVfs);
@@ -110098,14 +115652,10 @@ static int openDatabase(
** and UTF-16, so add a version for each to avoid any unnecessary
** conversions. The only error that can occur here is a malloc() failure.
*/
- createCollation(db, "BINARY", SQLITE_UTF8, SQLITE_COLL_BINARY, 0,
- binCollFunc, 0);
- createCollation(db, "BINARY", SQLITE_UTF16BE, SQLITE_COLL_BINARY, 0,
- binCollFunc, 0);
- createCollation(db, "BINARY", SQLITE_UTF16LE, SQLITE_COLL_BINARY, 0,
- binCollFunc, 0);
- createCollation(db, "RTRIM", SQLITE_UTF8, SQLITE_COLL_USER, (void*)1,
- binCollFunc, 0);
+ createCollation(db, "BINARY", SQLITE_UTF8, 0, binCollFunc, 0);
+ createCollation(db, "BINARY", SQLITE_UTF16BE, 0, binCollFunc, 0);
+ createCollation(db, "BINARY", SQLITE_UTF16LE, 0, binCollFunc, 0);
+ createCollation(db, "RTRIM", SQLITE_UTF8, (void*)1, binCollFunc, 0);
if( db->mallocFailed ){
goto opendb_out;
}
@@ -110113,8 +115663,7 @@ static int openDatabase(
assert( db->pDfltColl!=0 );
/* Also add a UTF-8 case-insensitive collation sequence. */
- createCollation(db, "NOCASE", SQLITE_UTF8, SQLITE_COLL_NOCASE, 0,
- nocaseCollatingFunc, 0);
+ createCollation(db, "NOCASE", SQLITE_UTF8, 0, nocaseCollatingFunc, 0);
/* Parse the filename/URI argument. */
db->openFlags = flags;
@@ -110163,10 +115712,13 @@ static int openDatabase(
/* Load automatic extensions - extensions that have been registered
** using the sqlite3_automatic_extension() API.
*/
- sqlite3AutoLoadExtensions(db);
rc = sqlite3_errcode(db);
- if( rc!=SQLITE_OK ){
- goto opendb_out;
+ if( rc==SQLITE_OK ){
+ sqlite3AutoLoadExtensions(db);
+ rc = sqlite3_errcode(db);
+ if( rc!=SQLITE_OK ){
+ goto opendb_out;
+ }
}
#ifdef SQLITE_ENABLE_FTS1
@@ -110226,6 +115778,7 @@ opendb_out:
sqlite3_mutex_leave(db->mutex);
}
rc = sqlite3_errcode(db);
+ assert( db!=0 || rc==SQLITE_NOMEM );
if( rc==SQLITE_NOMEM ){
sqlite3_close(db);
db = 0;
@@ -110233,6 +115786,13 @@ opendb_out:
db->magic = SQLITE_MAGIC_SICK;
}
*ppDb = db;
+#ifdef SQLITE_ENABLE_SQLLOG
+ if( sqlite3GlobalConfig.xSqllog ){
+ /* Opening a db handle. Fourth parameter is passed 0. */
+ void *pArg = sqlite3GlobalConfig.pSqllogArg;
+ sqlite3GlobalConfig.xSqllog(pArg, db, zFilename, 0);
+ }
+#endif
return sqlite3ApiExit(0, rc);
}
@@ -110306,7 +115866,7 @@ SQLITE_API int sqlite3_create_collation(
int rc;
sqlite3_mutex_enter(db->mutex);
assert( !db->mallocFailed );
- rc = createCollation(db, zName, (u8)enc, SQLITE_COLL_USER, pCtx, xCompare, 0);
+ rc = createCollation(db, zName, (u8)enc, pCtx, xCompare, 0);
rc = sqlite3ApiExit(db, rc);
sqlite3_mutex_leave(db->mutex);
return rc;
@@ -110326,7 +115886,7 @@ SQLITE_API int sqlite3_create_collation_v2(
int rc;
sqlite3_mutex_enter(db->mutex);
assert( !db->mallocFailed );
- rc = createCollation(db, zName, (u8)enc, SQLITE_COLL_USER, pCtx, xCompare, xDel);
+ rc = createCollation(db, zName, (u8)enc, pCtx, xCompare, xDel);
rc = sqlite3ApiExit(db, rc);
sqlite3_mutex_leave(db->mutex);
return rc;
@@ -110349,7 +115909,7 @@ SQLITE_API int sqlite3_create_collation16(
assert( !db->mallocFailed );
zName8 = sqlite3Utf16to8(db, zName, -1, SQLITE_UTF16NATIVE);
if( zName8 ){
- rc = createCollation(db, zName8, (u8)enc, SQLITE_COLL_USER, pCtx, xCompare, 0);
+ rc = createCollation(db, zName8, (u8)enc, pCtx, xCompare, 0);
sqlite3DbFree(db, zName8);
}
rc = sqlite3ApiExit(db, rc);
@@ -110538,7 +116098,7 @@ SQLITE_API int sqlite3_table_column_metadata(
zDataType = pCol->zType;
zCollSeq = pCol->zColl;
notnull = pCol->notNull!=0;
- primarykey = pCol->isPrimKey!=0;
+ primarykey = (pCol->colFlags & COLFLAG_PRIMKEY)!=0;
autoinc = pTab->iPKey==iCol && (pTab->tabFlags & TF_Autoincrement)!=0;
}else{
zDataType = "INTEGER";
@@ -110606,35 +116166,27 @@ SQLITE_API int sqlite3_extended_result_codes(sqlite3 *db, int onoff){
*/
SQLITE_API int sqlite3_file_control(sqlite3 *db, const char *zDbName, int op, void *pArg){
int rc = SQLITE_ERROR;
- int iDb;
+ Btree *pBtree;
+
sqlite3_mutex_enter(db->mutex);
- if( zDbName==0 ){
- iDb = 0;
- }else{
- for(iDb=0; iDb<db->nDb; iDb++){
- if( strcmp(db->aDb[iDb].zName, zDbName)==0 ) break;
- }
- }
- if( iDb<db->nDb ){
- Btree *pBtree = db->aDb[iDb].pBt;
- if( pBtree ){
- Pager *pPager;
- sqlite3_file *fd;
- sqlite3BtreeEnter(pBtree);
- pPager = sqlite3BtreePager(pBtree);
- assert( pPager!=0 );
- fd = sqlite3PagerFile(pPager);
- assert( fd!=0 );
- if( op==SQLITE_FCNTL_FILE_POINTER ){
- *(sqlite3_file**)pArg = fd;
- rc = SQLITE_OK;
- }else if( fd->pMethods ){
- rc = sqlite3OsFileControl(fd, op, pArg);
- }else{
- rc = SQLITE_NOTFOUND;
- }
- sqlite3BtreeLeave(pBtree);
+ pBtree = sqlite3DbNameToBtree(db, zDbName);
+ if( pBtree ){
+ Pager *pPager;
+ sqlite3_file *fd;
+ sqlite3BtreeEnter(pBtree);
+ pPager = sqlite3BtreePager(pBtree);
+ assert( pPager!=0 );
+ fd = sqlite3PagerFile(pPager);
+ assert( fd!=0 );
+ if( op==SQLITE_FCNTL_FILE_POINTER ){
+ *(sqlite3_file**)pArg = fd;
+ rc = SQLITE_OK;
+ }else if( fd->pMethods ){
+ rc = sqlite3OsFileControl(fd, op, pArg);
+ }else{
+ rc = SQLITE_NOTFOUND;
}
+ sqlite3BtreeLeave(pBtree);
}
sqlite3_mutex_leave(db->mutex);
return rc;
@@ -110809,8 +116361,7 @@ SQLITE_API int sqlite3_test_control(int op, ...){
*/
case SQLITE_TESTCTRL_OPTIMIZATIONS: {
sqlite3 *db = va_arg(ap, sqlite3*);
- int x = va_arg(ap,int);
- db->flags = (x & SQLITE_OptMask) | (db->flags & ~SQLITE_OptMask);
+ db->dbOptFlags = (u16)(va_arg(ap, int) & 0xffff);
break;
}
@@ -110832,15 +116383,6 @@ SQLITE_API int sqlite3_test_control(int op, ...){
}
#endif
- /* sqlite3_test_control(SQLITE_TESTCTRL_PGHDRSZ)
- **
- ** Return the size of a pcache header in bytes.
- */
- case SQLITE_TESTCTRL_PGHDRSZ: {
- rc = sizeof(PgHdr);
- break;
- }
-
/* sqlite3_test_control(SQLITE_TESTCTRL_SCRATCHMALLOC, sz, &pNew, pFree);
**
** Pass pFree into sqlite3ScratchFree().
@@ -110868,6 +116410,22 @@ SQLITE_API int sqlite3_test_control(int op, ...){
break;
}
+#if defined(SQLITE_ENABLE_TREE_EXPLAIN)
+ /* sqlite3_test_control(SQLITE_TESTCTRL_EXPLAIN_STMT,
+ ** sqlite3_stmt*,const char**);
+ **
+ ** If compiled with SQLITE_ENABLE_TREE_EXPLAIN, each sqlite3_stmt holds
+ ** a string that describes the optimized parse tree. This test-control
+ ** returns a pointer to that string.
+ */
+ case SQLITE_TESTCTRL_EXPLAIN_STMT: {
+ sqlite3_stmt *pStmt = va_arg(ap, sqlite3_stmt*);
+ const char **pzRet = va_arg(ap, const char**);
+ *pzRet = sqlite3VdbeExplanation((Vdbe*)pStmt);
+ break;
+ }
+#endif
+
}
va_end(ap);
#endif /* SQLITE_OMIT_BUILTIN_TEST */
@@ -110886,6 +116444,7 @@ SQLITE_API int sqlite3_test_control(int op, ...){
** returns a NULL pointer.
*/
SQLITE_API const char *sqlite3_uri_parameter(const char *zFilename, const char *zParam){
+ if( zFilename==0 ) return 0;
zFilename += sqlite3Strlen30(zFilename) + 1;
while( zFilename[0] ){
int x = strcmp(zFilename, zParam);
@@ -110896,6 +116455,64 @@ SQLITE_API const char *sqlite3_uri_parameter(const char *zFilename, const char *
return 0;
}
+/*
+** Return a boolean value for a query parameter.
+*/
+SQLITE_API int sqlite3_uri_boolean(const char *zFilename, const char *zParam, int bDflt){
+ const char *z = sqlite3_uri_parameter(zFilename, zParam);
+ bDflt = bDflt!=0;
+ return z ? sqlite3GetBoolean(z, bDflt) : bDflt;
+}
+
+/*
+** Return a 64-bit integer value for a query parameter.
+*/
+SQLITE_API sqlite3_int64 sqlite3_uri_int64(
+ const char *zFilename, /* Filename as passed to xOpen */
+ const char *zParam, /* URI parameter sought */
+ sqlite3_int64 bDflt /* return if parameter is missing */
+){
+ const char *z = sqlite3_uri_parameter(zFilename, zParam);
+ sqlite3_int64 v;
+ if( z && sqlite3Atoi64(z, &v, sqlite3Strlen30(z), SQLITE_UTF8)==SQLITE_OK ){
+ bDflt = v;
+ }
+ return bDflt;
+}
+
+/*
+** Return the Btree pointer identified by zDbName. Return NULL if not found.
+*/
+SQLITE_PRIVATE Btree *sqlite3DbNameToBtree(sqlite3 *db, const char *zDbName){
+ int i;
+ for(i=0; i<db->nDb; i++){
+ if( db->aDb[i].pBt
+ && (zDbName==0 || sqlite3StrICmp(zDbName, db->aDb[i].zName)==0)
+ ){
+ return db->aDb[i].pBt;
+ }
+ }
+ return 0;
+}
+
+/*
+** Return the filename of the database associated with a database
+** connection.
+*/
+SQLITE_API const char *sqlite3_db_filename(sqlite3 *db, const char *zDbName){
+ Btree *pBt = sqlite3DbNameToBtree(db, zDbName);
+ return pBt ? sqlite3BtreeGetFilename(pBt) : 0;
+}
+
+/*
+** Return 1 if database is read-only or 0 if read/write. Return -1 if
+** no such database exists.
+*/
+SQLITE_API int sqlite3_db_readonly(sqlite3 *db, const char *zDbName){
+ Btree *pBt = sqlite3DbNameToBtree(db, zDbName);
+ return pBt ? sqlite3PagerIsreadonly(sqlite3BtreePager(pBt)) : -1;
+}
+
/************** End of main.c ************************************************/
/************** Begin file notify.c ******************************************/
/*
@@ -111303,7 +116920,7 @@ SQLITE_PRIVATE void sqlite3ConnectionClosed(sqlite3 *db){
** A doclist is stored like this:
**
** array {
-** varint docid;
+** varint docid; (delta from previous doclist)
** array { (position list for column 0)
** varint position; (2 more than the delta from previous position)
** }
@@ -111334,8 +116951,8 @@ SQLITE_PRIVATE void sqlite3ConnectionClosed(sqlite3 *db){
** at D signals the start of a new column; the 1 at E indicates that the
** new column is column number 1. There are two positions at 12 and 45
** (14-2 and 35-2+12). The 0 at H indicate the end-of-document. The
-** 234 at I is the next docid. It has one position 72 (72-2) and then
-** terminates with the 0 at K.
+** 234 at I is the delta to next docid (357). It has one position 70
+** (72-2) and then terminates with the 0 at K.
**
** A "position-list" is the list of positions for multiple columns for
** a single docid. A "column-list" is the set of positions for a single
@@ -111519,10 +117136,6 @@ SQLITE_PRIVATE void sqlite3ConnectionClosed(sqlite3 *db){
** will eventually overtake the earlier data and knock it out. The
** query logic likewise merges doclists so that newer data knocks out
** older data.
-**
-** TODO(shess) Provide a VACUUM type operation to clear out all
-** deletions and duplications. This would basically be a forced merge
-** into a single segment.
*/
/************** Include fts3Int.h in the middle of fts3.c ********************/
@@ -111556,7 +117169,13 @@ SQLITE_PRIVATE void sqlite3ConnectionClosed(sqlite3 *db){
# define SQLITE_ENABLE_FTS3
#endif
-#ifdef SQLITE_ENABLE_FTS3
+#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3)
+
+/* If not building as part of the core, include sqlite3ext.h. */
+#ifndef SQLITE_CORE
+SQLITE_API extern const sqlite3_api_routines *sqlite3_api;
+#endif
+
/************** Include fts3_tokenizer.h in the middle of fts3Int.h **********/
/************** Begin file fts3_tokenizer.h **********************************/
/*
@@ -111612,7 +117231,7 @@ typedef struct sqlite3_tokenizer_cursor sqlite3_tokenizer_cursor;
struct sqlite3_tokenizer_module {
/*
- ** Structure version. Should always be set to 0.
+ ** Structure version. Should always be set to 0 or 1.
*/
int iVersion;
@@ -111630,7 +117249,7 @@ struct sqlite3_tokenizer_module {
** This method should return either SQLITE_OK (0), or an SQLite error
** code. If SQLITE_OK is returned, then *ppTokenizer should be set
** to point at the newly created tokenizer structure. The generic
- ** sqlite3_tokenizer.pModule variable should not be initialised by
+ ** sqlite3_tokenizer.pModule variable should not be initialized by
** this callback. The caller will do so.
*/
int (*xCreate)(
@@ -111693,6 +117312,15 @@ struct sqlite3_tokenizer_module {
int *piEndOffset, /* OUT: Byte offset of end of token in input buffer */
int *piPosition /* OUT: Number of tokens returned before this one */
);
+
+ /***********************************************************************
+ ** Methods below this point are only available if iVersion>=1.
+ */
+
+ /*
+ ** Configure the language id of a tokenizer cursor.
+ */
+ int (*xLanguageid)(sqlite3_tokenizer_cursor *pCsr, int iLangid);
};
struct sqlite3_tokenizer {
@@ -111726,7 +117354,7 @@ int fts3_term_cnt(int iTerm, int iCol);
** May you share freely, never taking more than you give.
**
*************************************************************************
-** This is the header file for the generic hash-table implemenation
+** This is the header file for the generic hash-table implementation
** used in SQLite. We've modified it slightly to serve as a standalone
** hash table implementation for the full-text indexing module.
**
@@ -111859,6 +117487,9 @@ SQLITE_PRIVATE Fts3HashElem *sqlite3Fts3HashFindElem(const Fts3Hash *, const voi
#ifndef MIN
# define MIN(x,y) ((x)<(y)?(x):(y))
#endif
+#ifndef MAX
+# define MAX(x,y) ((x)>(y)?(x):(y))
+#endif
/*
** Maximum length of a varint encoded integer. The varint format is different
@@ -111913,7 +117544,7 @@ SQLITE_PRIVATE Fts3HashElem *sqlite3Fts3HashFindElem(const Fts3Hash *, const voi
# define NEVER(X) (0)
#else
# define ALWAYS(x) (x)
-# define NEVER(X) (x)
+# define NEVER(x) (x)
#endif
/*
@@ -111923,6 +117554,7 @@ typedef unsigned char u8; /* 1-byte (or larger) unsigned integer */
typedef short int i16; /* 2-byte (or larger) signed integer */
typedef unsigned int u32; /* 4-byte unsigned integer */
typedef sqlite3_uint64 u64; /* 8-byte unsigned integer */
+typedef sqlite3_int64 i64; /* 8-byte signed integer */
/*
** Macro used to suppress compiler warnings for unused parameters.
@@ -111949,6 +117581,13 @@ typedef sqlite3_uint64 u64; /* 8-byte unsigned integer */
#endif /* SQLITE_AMALGAMATION */
+#ifdef SQLITE_DEBUG
+SQLITE_PRIVATE int sqlite3Fts3Corrupt(void);
+# define FTS_CORRUPT_VTAB sqlite3Fts3Corrupt()
+#else
+# define FTS_CORRUPT_VTAB SQLITE_CORRUPT_VTAB
+#endif
+
typedef struct Fts3Table Fts3Table;
typedef struct Fts3Cursor Fts3Cursor;
typedef struct Fts3Expr Fts3Expr;
@@ -111976,36 +117615,45 @@ struct Fts3Table {
int nColumn; /* number of named columns in virtual table */
char **azColumn; /* column names. malloced */
sqlite3_tokenizer *pTokenizer; /* tokenizer for inserts and queries */
+ char *zContentTbl; /* content=xxx option, or NULL */
+ char *zLanguageid; /* languageid=xxx option, or NULL */
+ u8 bAutoincrmerge; /* True if automerge=1 */
+ u32 nLeafAdd; /* Number of leaf blocks added this trans */
/* Precompiled statements used by the implementation. Each of these
** statements is run and reset within a single virtual table API call.
*/
- sqlite3_stmt *aStmt[27];
+ sqlite3_stmt *aStmt[37];
char *zReadExprlist;
char *zWriteExprlist;
int nNodeSize; /* Soft limit for node size */
+ u8 bFts4; /* True for FTS4, false for FTS3 */
u8 bHasStat; /* True if %_stat table exists */
u8 bHasDocsize; /* True if %_docsize table exists */
u8 bDescIdx; /* True if doclists are in reverse order */
+ u8 bIgnoreSavepoint; /* True to ignore xSavepoint invocations */
int nPgsz; /* Page size for host database */
char *zSegmentsTbl; /* Name of %_segments table */
sqlite3_blob *pSegments; /* Blob handle open on %_segments table */
- /* TODO: Fix the first paragraph of this comment.
- **
- ** The following hash table is used to buffer pending index updates during
- ** transactions. Variable nPendingData estimates the memory size of the
- ** pending data, including hash table overhead, but not malloc overhead.
- ** When nPendingData exceeds nMaxPendingData, the buffer is flushed
- ** automatically. Variable iPrevDocid is the docid of the most recently
- ** inserted record.
+ /*
+ ** The following array of hash tables is used to buffer pending index
+ ** updates during transactions. All pending updates buffered at any one
+ ** time must share a common language-id (see the FTS4 langid= feature).
+ ** The current language id is stored in variable iPrevLangid.
**
** A single FTS4 table may have multiple full-text indexes. For each index
** there is an entry in the aIndex[] array. Index 0 is an index of all the
** terms that appear in the document set. Each subsequent index in aIndex[]
** is an index of prefixes of a specific length.
+ **
+ ** Variable nPendingData contains an estimate the memory consumed by the
+ ** pending data structures, including hash table overhead, but not including
+ ** malloc overhead. When nPendingData exceeds nMaxPendingData, all hash
+ ** tables are flushed to disk. Variable iPrevDocid is the docid of the most
+ ** recently inserted record.
*/
int nIndex; /* Size of aIndex[] */
struct Fts3Index {
@@ -112015,12 +117663,13 @@ struct Fts3Table {
int nMaxPendingData; /* Max pending data before flush to disk */
int nPendingData; /* Current bytes of pending data */
sqlite_int64 iPrevDocid; /* Docid of most recently inserted document */
+ int iPrevLangid; /* Langid of recently inserted document */
-#if defined(SQLITE_DEBUG)
+#if defined(SQLITE_DEBUG) || defined(SQLITE_COVERAGE_TEST)
/* State variables used for validating that the transaction control
** methods of the virtual table are called at appropriate times. These
- ** values do not contribution to the FTS computation; they are used for
- ** verifying the SQLite core.
+ ** values do not contribute to FTS functionality; they are used for
+ ** verifying the operation of the SQLite core.
*/
int inTransaction; /* True after xBegin but before xCommit/xRollback */
int mxSavepoint; /* Largest valid xSavepoint integer */
@@ -112039,6 +117688,7 @@ struct Fts3Cursor {
u8 isRequireSeek; /* True if must seek pStmt to %_content row */
sqlite3_stmt *pStmt; /* Prepared statement in use by the cursor */
Fts3Expr *pExpr; /* Parsed MATCH query string */
+ int iLangid; /* Language being queried for */
int nPhrase; /* Number of matchable phrases in query */
Fts3DeferredToken *pDeferred; /* Deferred search tokens, if any */
sqlite3_int64 iPrevId; /* Previous id read from aDoclist */
@@ -112089,7 +117739,7 @@ struct Fts3Doclist {
int bFreeList; /* True if pList should be sqlite3_free()d */
char *pList; /* Pointer to position list following iDocid */
int nList; /* Length of position list */
-} doclist;
+};
/*
** A "phrase" is a sequence of one or more tokens that must match in
@@ -112101,6 +117751,7 @@ struct Fts3PhraseToken {
char *z; /* Text of the token */
int n; /* Number of bytes in buffer z */
int isPrefix; /* True if token ends with a "*" character */
+ int bFirst; /* True if token must appear at position 0 */
/* Variables above this point are populated when the expression is
** parsed (by code in fts3_expr.c). Below this point the variables are
@@ -112184,23 +117835,34 @@ SQLITE_PRIVATE int sqlite3Fts3UpdateMethod(sqlite3_vtab*,int,sqlite3_value**,sql
SQLITE_PRIVATE int sqlite3Fts3PendingTermsFlush(Fts3Table *);
SQLITE_PRIVATE void sqlite3Fts3PendingTermsClear(Fts3Table *);
SQLITE_PRIVATE int sqlite3Fts3Optimize(Fts3Table *);
-SQLITE_PRIVATE int sqlite3Fts3SegReaderNew(int, sqlite3_int64,
+SQLITE_PRIVATE int sqlite3Fts3SegReaderNew(int, int, sqlite3_int64,
sqlite3_int64, sqlite3_int64, const char *, int, Fts3SegReader**);
SQLITE_PRIVATE int sqlite3Fts3SegReaderPending(
Fts3Table*,int,const char*,int,int,Fts3SegReader**);
SQLITE_PRIVATE void sqlite3Fts3SegReaderFree(Fts3SegReader *);
-SQLITE_PRIVATE int sqlite3Fts3AllSegdirs(Fts3Table*, int, int, sqlite3_stmt **);
+SQLITE_PRIVATE int sqlite3Fts3AllSegdirs(Fts3Table*, int, int, int, sqlite3_stmt **);
SQLITE_PRIVATE int sqlite3Fts3ReadLock(Fts3Table *);
SQLITE_PRIVATE int sqlite3Fts3ReadBlock(Fts3Table*, sqlite3_int64, char **, int*, int*);
SQLITE_PRIVATE int sqlite3Fts3SelectDoctotal(Fts3Table *, sqlite3_stmt **);
SQLITE_PRIVATE int sqlite3Fts3SelectDocsize(Fts3Table *, sqlite3_int64, sqlite3_stmt **);
+#ifndef SQLITE_DISABLE_FTS4_DEFERRED
SQLITE_PRIVATE void sqlite3Fts3FreeDeferredTokens(Fts3Cursor *);
SQLITE_PRIVATE int sqlite3Fts3DeferToken(Fts3Cursor *, Fts3PhraseToken *, int);
SQLITE_PRIVATE int sqlite3Fts3CacheDeferredDoclists(Fts3Cursor *);
SQLITE_PRIVATE void sqlite3Fts3FreeDeferredDoclists(Fts3Cursor *);
+SQLITE_PRIVATE int sqlite3Fts3DeferredTokenList(Fts3DeferredToken *, char **, int *);
+#else
+# define sqlite3Fts3FreeDeferredTokens(x)
+# define sqlite3Fts3DeferToken(x,y,z) SQLITE_OK
+# define sqlite3Fts3CacheDeferredDoclists(x) SQLITE_OK
+# define sqlite3Fts3FreeDeferredDoclists(x)
+# define sqlite3Fts3DeferredTokenList(x,y,z) SQLITE_OK
+#endif
+
SQLITE_PRIVATE void sqlite3Fts3SegmentsClose(Fts3Table *);
+SQLITE_PRIVATE int sqlite3Fts3MaxLevel(Fts3Table *, int *);
/* Special values interpreted by sqlite3SegReaderCursor() */
#define FTS3_SEGCURSOR_PENDING -1
@@ -112210,8 +117872,8 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStart(Fts3Table*, Fts3MultiSegReader*, Ft
SQLITE_PRIVATE int sqlite3Fts3SegReaderStep(Fts3Table *, Fts3MultiSegReader *);
SQLITE_PRIVATE void sqlite3Fts3SegReaderFinish(Fts3MultiSegReader *);
-SQLITE_PRIVATE int sqlite3Fts3SegReaderCursor(
- Fts3Table *, int, int, const char *, int, int, int, Fts3MultiSegReader *);
+SQLITE_PRIVATE int sqlite3Fts3SegReaderCursor(Fts3Table *,
+ int, int, int, const char *, int, int, int, Fts3MultiSegReader *);
/* Flags allowed as part of the 4th argument to SegmentReaderIterate() */
#define FTS3_SEGMENT_REQUIRE_POS 0x00000001
@@ -112219,6 +117881,7 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderCursor(
#define FTS3_SEGMENT_COLUMN_FILTER 0x00000004
#define FTS3_SEGMENT_PREFIX 0x00000008
#define FTS3_SEGMENT_SCAN 0x00000010
+#define FTS3_SEGMENT_FIRST 0x00000020
/* Type passed as 4th argument to SegmentReaderIterate() */
struct Fts3SegFilter {
@@ -112251,6 +117914,8 @@ struct Fts3MultiSegReader {
int nDoclist; /* Size of aDoclist[] in bytes */
};
+SQLITE_PRIVATE int sqlite3Fts3Incrmerge(Fts3Table*,int,int);
+
/* fts3.c */
SQLITE_PRIVATE int sqlite3Fts3PutVarint(char *, sqlite3_int64);
SQLITE_PRIVATE int sqlite3Fts3GetVarint(const char *, sqlite_int64 *);
@@ -112258,8 +117923,9 @@ SQLITE_PRIVATE int sqlite3Fts3GetVarint32(const char *, int *);
SQLITE_PRIVATE int sqlite3Fts3VarintLen(sqlite3_uint64);
SQLITE_PRIVATE void sqlite3Fts3Dequote(char *);
SQLITE_PRIVATE void sqlite3Fts3DoclistPrev(int,char*,int,char**,sqlite3_int64*,int*,u8*);
-
SQLITE_PRIVATE int sqlite3Fts3EvalPhraseStats(Fts3Cursor *, Fts3Expr *, u32 *);
+SQLITE_PRIVATE int sqlite3Fts3FirstFilter(sqlite3_int64, char *, int, char *);
+SQLITE_PRIVATE void sqlite3Fts3CreateStatTable(int*, Fts3Table*);
/* fts3_tokenizer.c */
SQLITE_PRIVATE const char *sqlite3Fts3NextToken(const char *, int *);
@@ -112277,8 +117943,8 @@ SQLITE_PRIVATE void sqlite3Fts3Snippet(sqlite3_context *, Fts3Cursor *, const ch
SQLITE_PRIVATE void sqlite3Fts3Matchinfo(sqlite3_context *, Fts3Cursor *, const char *);
/* fts3_expr.c */
-SQLITE_PRIVATE int sqlite3Fts3ExprParse(sqlite3_tokenizer *,
- char **, int, int, const char *, int, Fts3Expr **
+SQLITE_PRIVATE int sqlite3Fts3ExprParse(sqlite3_tokenizer *, int,
+ char **, int, int, int, const char *, int, Fts3Expr **
);
SQLITE_PRIVATE void sqlite3Fts3ExprFree(Fts3Expr *);
#ifdef SQLITE_TEST
@@ -112286,33 +117952,31 @@ SQLITE_PRIVATE int sqlite3Fts3ExprInitTestInterface(sqlite3 *db);
SQLITE_PRIVATE int sqlite3Fts3InitTerm(sqlite3 *db);
#endif
+SQLITE_PRIVATE int sqlite3Fts3OpenTokenizer(sqlite3_tokenizer *, int, const char *, int,
+ sqlite3_tokenizer_cursor **
+);
+
/* fts3_aux.c */
SQLITE_PRIVATE int sqlite3Fts3InitAux(sqlite3 *db);
-SQLITE_PRIVATE int sqlite3Fts3TermSegReaderCursor(
- Fts3Cursor *pCsr, /* Virtual table cursor handle */
- const char *zTerm, /* Term to query for */
- int nTerm, /* Size of zTerm in bytes */
- int isPrefix, /* True for a prefix search */
- Fts3MultiSegReader **ppSegcsr /* OUT: Allocated seg-reader cursor */
-);
-
SQLITE_PRIVATE void sqlite3Fts3EvalPhraseCleanup(Fts3Phrase *);
-SQLITE_PRIVATE int sqlite3Fts3EvalStart(Fts3Cursor *, Fts3Expr *, int);
-SQLITE_PRIVATE int sqlite3Fts3EvalNext(Fts3Cursor *pCsr);
-
SQLITE_PRIVATE int sqlite3Fts3MsrIncrStart(
Fts3Table*, Fts3MultiSegReader*, int, const char*, int);
SQLITE_PRIVATE int sqlite3Fts3MsrIncrNext(
Fts3Table *, Fts3MultiSegReader *, sqlite3_int64 *, char **, int *);
-SQLITE_PRIVATE char *sqlite3Fts3EvalPhrasePoslist(Fts3Cursor *, Fts3Expr *, int iCol);
+SQLITE_PRIVATE int sqlite3Fts3EvalPhrasePoslist(Fts3Cursor *, Fts3Expr *, int iCol, char **);
SQLITE_PRIVATE int sqlite3Fts3MsrOvfl(Fts3Cursor *, Fts3MultiSegReader *, int *);
SQLITE_PRIVATE int sqlite3Fts3MsrIncrRestart(Fts3MultiSegReader *pCsr);
-SQLITE_PRIVATE int sqlite3Fts3DeferredTokenList(Fts3DeferredToken *, char **, int *);
+/* fts3_unicode2.c (functions generated by parsing unicode text files) */
+#ifdef SQLITE_ENABLE_FTS4_UNICODE61
+SQLITE_PRIVATE int sqlite3FtsUnicodeFold(int, int);
+SQLITE_PRIVATE int sqlite3FtsUnicodeIsalnum(int);
+SQLITE_PRIVATE int sqlite3FtsUnicodeIsdiacritic(int);
+#endif
-#endif /* SQLITE_ENABLE_FTS3 */
+#endif /* !SQLITE_CORE || SQLITE_ENABLE_FTS3 */
#endif /* _FTSINT_H */
/************** End of fts3Int.h *********************************************/
@@ -112323,11 +117987,22 @@ SQLITE_PRIVATE int sqlite3Fts3DeferredTokenList(Fts3DeferredToken *, char **, in
# define SQLITE_CORE 1
#endif
+/* #include <assert.h> */
+/* #include <stdlib.h> */
+/* #include <stddef.h> */
+/* #include <stdio.h> */
+/* #include <string.h> */
+/* #include <stdarg.h> */
#ifndef SQLITE_CORE
SQLITE_EXTENSION_INIT1
#endif
+static int fts3EvalNext(Fts3Cursor *pCsr);
+static int fts3EvalStart(Fts3Cursor *pCsr);
+static int fts3TermSegReaderCursor(
+ Fts3Cursor *, const char *, int, int, Fts3MultiSegReader **);
+
/*
** Write a 64-bit variable-length integer to memory starting at p[0].
** The length of data written will be between 1 and FTS3_VARINT_MAX bytes.
@@ -112449,7 +118124,7 @@ static void fts3GetReverseVarint(
sqlite3_int64 *pVal
){
sqlite3_int64 iVal;
- char *p = *pp;
+ char *p;
/* Pointer p now points at the first byte past the varint we are
** interested in. So, unless the doclist is corrupt, the 0x80 bit is
@@ -112479,6 +118154,8 @@ static int fts3DisconnectMethod(sqlite3_vtab *pVtab){
sqlite3_free(p->zSegmentsTbl);
sqlite3_free(p->zReadExprlist);
sqlite3_free(p->zWriteExprlist);
+ sqlite3_free(p->zContentTbl);
+ sqlite3_free(p->zLanguageid);
/* Invoke the tokenizer destructor to free the tokenizer. */
p->pTokenizer->pModule->xDestroy(p->pTokenizer);
@@ -112518,16 +118195,19 @@ static void fts3DbExec(
** The xDestroy() virtual table method.
*/
static int fts3DestroyMethod(sqlite3_vtab *pVtab){
- int rc = SQLITE_OK; /* Return code */
Fts3Table *p = (Fts3Table *)pVtab;
- sqlite3 *db = p->db;
+ int rc = SQLITE_OK; /* Return code */
+ const char *zDb = p->zDb; /* Name of database (e.g. "main", "temp") */
+ sqlite3 *db = p->db; /* Database handle */
/* Drop the shadow tables */
- fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_content'", p->zDb, p->zName);
- fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_segments'", p->zDb,p->zName);
- fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_segdir'", p->zDb, p->zName);
- fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_docsize'", p->zDb, p->zName);
- fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_stat'", p->zDb, p->zName);
+ if( p->zContentTbl==0 ){
+ fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_content'", zDb, p->zName);
+ }
+ fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_segments'", zDb,p->zName);
+ fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_segdir'", zDb, p->zName);
+ fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_docsize'", zDb, p->zName);
+ fts3DbExec(&rc, db, "DROP TABLE IF EXISTS %Q.'%q_stat'", zDb, p->zName);
/* If everything has worked, invoke fts3DisconnectMethod() to free the
** memory associated with the Fts3Table structure and return SQLITE_OK.
@@ -112552,7 +118232,9 @@ static void fts3DeclareVtab(int *pRc, Fts3Table *p){
int rc; /* Return code */
char *zSql; /* SQL statement passed to declare_vtab() */
char *zCols; /* List of user defined columns */
+ const char *zLanguageid;
+ zLanguageid = (p->zLanguageid ? p->zLanguageid : "__langid");
sqlite3_vtab_config(p->db, SQLITE_VTAB_CONSTRAINT_SUPPORT, 1);
/* Create a list of user columns for the virtual table */
@@ -112563,7 +118245,8 @@ static void fts3DeclareVtab(int *pRc, Fts3Table *p){
/* Create the whole "CREATE TABLE" statement to pass to SQLite */
zSql = sqlite3_mprintf(
- "CREATE TABLE x(%s %Q HIDDEN, docid HIDDEN)", zCols, p->zName
+ "CREATE TABLE x(%s %Q HIDDEN, docid HIDDEN, %Q HIDDEN)",
+ zCols, p->zName, zLanguageid
);
if( !zCols || !zSql ){
rc = SQLITE_NOMEM;
@@ -112578,6 +118261,18 @@ static void fts3DeclareVtab(int *pRc, Fts3Table *p){
}
/*
+** Create the %_stat table if it does not already exist.
+*/
+SQLITE_PRIVATE void sqlite3Fts3CreateStatTable(int *pRc, Fts3Table *p){
+ fts3DbExec(pRc, p->db,
+ "CREATE TABLE IF NOT EXISTS %Q.'%q_stat'"
+ "(id INTEGER PRIMARY KEY, value BLOB);",
+ p->zDb, p->zName
+ );
+ if( (*pRc)==SQLITE_OK ) p->bHasStat = 1;
+}
+
+/*
** Create the backing store tables (%_content, %_segments and %_segdir)
** required by the FTS3 table passed as the only argument. This is done
** as part of the vtab xCreate() method.
@@ -112589,23 +118284,31 @@ static void fts3DeclareVtab(int *pRc, Fts3Table *p){
static int fts3CreateTables(Fts3Table *p){
int rc = SQLITE_OK; /* Return code */
int i; /* Iterator variable */
- char *zContentCols; /* Columns of %_content table */
sqlite3 *db = p->db; /* The database connection */
- /* Create a list of user columns for the content table */
- zContentCols = sqlite3_mprintf("docid INTEGER PRIMARY KEY");
- for(i=0; zContentCols && i<p->nColumn; i++){
- char *z = p->azColumn[i];
- zContentCols = sqlite3_mprintf("%z, 'c%d%q'", zContentCols, i, z);
+ if( p->zContentTbl==0 ){
+ const char *zLanguageid = p->zLanguageid;
+ char *zContentCols; /* Columns of %_content table */
+
+ /* Create a list of user columns for the content table */
+ zContentCols = sqlite3_mprintf("docid INTEGER PRIMARY KEY");
+ for(i=0; zContentCols && i<p->nColumn; i++){
+ char *z = p->azColumn[i];
+ zContentCols = sqlite3_mprintf("%z, 'c%d%q'", zContentCols, i, z);
+ }
+ if( zLanguageid && zContentCols ){
+ zContentCols = sqlite3_mprintf("%z, langid", zContentCols, zLanguageid);
+ }
+ if( zContentCols==0 ) rc = SQLITE_NOMEM;
+
+ /* Create the content table */
+ fts3DbExec(&rc, db,
+ "CREATE TABLE %Q.'%q_content'(%s)",
+ p->zDb, p->zName, zContentCols
+ );
+ sqlite3_free(zContentCols);
}
- if( zContentCols==0 ) rc = SQLITE_NOMEM;
- /* Create the content table */
- fts3DbExec(&rc, db,
- "CREATE TABLE %Q.'%q_content'(%s)",
- p->zDb, p->zName, zContentCols
- );
- sqlite3_free(zContentCols);
/* Create other tables */
fts3DbExec(&rc, db,
"CREATE TABLE %Q.'%q_segments'(blockid INTEGER PRIMARY KEY, block BLOB);",
@@ -112629,11 +118332,9 @@ static int fts3CreateTables(Fts3Table *p){
p->zDb, p->zName
);
}
+ assert( p->bHasStat==p->bFts4 );
if( p->bHasStat ){
- fts3DbExec(&rc, db,
- "CREATE TABLE %Q.'%q_stat'(id INTEGER PRIMARY KEY, value BLOB);",
- p->zDb, p->zName
- );
+ sqlite3Fts3CreateStatTable(&rc, p);
}
return rc;
}
@@ -112715,6 +118416,7 @@ static void fts3Appendf(
char *z;
va_start(ap, zFormat);
z = sqlite3_vmprintf(zFormat, ap);
+ va_end(ap);
if( z && *pz ){
char *z2 = sqlite3_mprintf("%s%s", *pz, z);
sqlite3_free(z);
@@ -112739,7 +118441,7 @@ static void fts3Appendf(
static char *fts3QuoteId(char const *zInput){
int nRet;
char *zRet;
- nRet = 2 + strlen(zInput)*2 + 1;
+ nRet = 2 + (int)strlen(zInput)*2 + 1;
zRet = sqlite3_malloc(nRet);
if( zRet ){
int i;
@@ -112756,8 +118458,8 @@ static char *fts3QuoteId(char const *zInput){
}
/*
-** Return a list of comma separated SQL expressions that could be used
-** in a SELECT statement such as the following:
+** Return a list of comma separated SQL expressions and a FROM clause that
+** could be used in a SELECT statement such as the following:
**
** SELECT <list of expressions> FROM %_content AS x ...
**
@@ -112768,7 +118470,7 @@ static char *fts3QuoteId(char const *zInput){
** table has the three user-defined columns "a", "b", and "c", the following
** string is returned:
**
-** "docid, unzip(x.'a'), unzip(x.'b'), unzip(x.'c')"
+** "docid, unzip(x.'a'), unzip(x.'b'), unzip(x.'c') FROM %_content AS x"
**
** The pointer returned points to a buffer allocated by sqlite3_malloc(). It
** is the responsibility of the caller to eventually free it.
@@ -112784,16 +118486,34 @@ static char *fts3ReadExprList(Fts3Table *p, const char *zFunc, int *pRc){
char *zFunction;
int i;
- if( !zFunc ){
- zFunction = "";
+ if( p->zContentTbl==0 ){
+ if( !zFunc ){
+ zFunction = "";
+ }else{
+ zFree = zFunction = fts3QuoteId(zFunc);
+ }
+ fts3Appendf(pRc, &zRet, "docid");
+ for(i=0; i<p->nColumn; i++){
+ fts3Appendf(pRc, &zRet, ",%s(x.'c%d%q')", zFunction, i, p->azColumn[i]);
+ }
+ if( p->zLanguageid ){
+ fts3Appendf(pRc, &zRet, ", x.%Q", "langid");
+ }
+ sqlite3_free(zFree);
}else{
- zFree = zFunction = fts3QuoteId(zFunc);
- }
- fts3Appendf(pRc, &zRet, "docid");
- for(i=0; i<p->nColumn; i++){
- fts3Appendf(pRc, &zRet, ",%s(x.'c%d%q')", zFunction, i, p->azColumn[i]);
+ fts3Appendf(pRc, &zRet, "rowid");
+ for(i=0; i<p->nColumn; i++){
+ fts3Appendf(pRc, &zRet, ", x.'%q'", p->azColumn[i]);
+ }
+ if( p->zLanguageid ){
+ fts3Appendf(pRc, &zRet, ", x.%Q", p->zLanguageid);
+ }
}
- sqlite3_free(zFree);
+ fts3Appendf(pRc, &zRet, " FROM '%q'.'%q%s' AS x",
+ p->zDb,
+ (p->zContentTbl ? p->zContentTbl : p->zName),
+ (p->zContentTbl ? "" : "_content")
+ );
return zRet;
}
@@ -112832,13 +118552,30 @@ static char *fts3WriteExprList(Fts3Table *p, const char *zFunc, int *pRc){
for(i=0; i<p->nColumn; i++){
fts3Appendf(pRc, &zRet, ",%s(?)", zFunction);
}
+ if( p->zLanguageid ){
+ fts3Appendf(pRc, &zRet, ", ?");
+ }
sqlite3_free(zFree);
return zRet;
}
+/*
+** This function interprets the string at (*pp) as a non-negative integer
+** value. It reads the integer and sets *pnOut to the value read, then
+** sets *pp to point to the byte immediately following the last byte of
+** the integer value.
+**
+** Only decimal digits ('0'..'9') may be part of an integer value.
+**
+** If *pp does not being with a decimal digit SQLITE_ERROR is returned and
+** the output value undefined. Otherwise SQLITE_OK is returned.
+**
+** This function is used when parsing the "prefix=" FTS4 parameter.
+*/
static int fts3GobbleInt(const char **pp, int *pnOut){
- const char *p = *pp;
- int nInt = 0;
+ const char *p; /* Iterator pointer */
+ int nInt = 0; /* Output value */
+
for(p=*pp; p[0]>='0' && p[0]<='9'; p++){
nInt = nInt * 10 + (p[0] - '0');
}
@@ -112848,15 +118585,30 @@ static int fts3GobbleInt(const char **pp, int *pnOut){
return SQLITE_OK;
}
-
+/*
+** This function is called to allocate an array of Fts3Index structures
+** representing the indexes maintained by the current FTS table. FTS tables
+** always maintain the main "terms" index, but may also maintain one or
+** more "prefix" indexes, depending on the value of the "prefix=" parameter
+** (if any) specified as part of the CREATE VIRTUAL TABLE statement.
+**
+** Argument zParam is passed the value of the "prefix=" option if one was
+** specified, or NULL otherwise.
+**
+** If no error occurs, SQLITE_OK is returned and *apIndex set to point to
+** the allocated array. *pnIndex is set to the number of elements in the
+** array. If an error does occur, an SQLite error code is returned.
+**
+** Regardless of whether or not an error is returned, it is the responsibility
+** of the caller to call sqlite3_free() on the output array to free it.
+*/
static int fts3PrefixParameter(
const char *zParam, /* ABC in prefix=ABC parameter to parse */
int *pnIndex, /* OUT: size of *apIndex[] array */
- struct Fts3Index **apIndex, /* OUT: Array of indexes for this table */
- struct Fts3Index **apFree /* OUT: Free this with sqlite3_free() */
+ struct Fts3Index **apIndex /* OUT: Array of indexes for this table */
){
- struct Fts3Index *aIndex;
- int nIndex = 1;
+ struct Fts3Index *aIndex; /* Allocated array */
+ int nIndex = 1; /* Number of entries in array */
if( zParam && zParam[0] ){
const char *p;
@@ -112867,7 +118619,7 @@ static int fts3PrefixParameter(
}
aIndex = sqlite3_malloc(sizeof(struct Fts3Index) * nIndex);
- *apIndex = *apFree = aIndex;
+ *apIndex = aIndex;
*pnIndex = nIndex;
if( !aIndex ){
return SQLITE_NOMEM;
@@ -112889,6 +118641,91 @@ static int fts3PrefixParameter(
}
/*
+** This function is called when initializing an FTS4 table that uses the
+** content=xxx option. It determines the number of and names of the columns
+** of the new FTS4 table.
+**
+** The third argument passed to this function is the value passed to the
+** config=xxx option (i.e. "xxx"). This function queries the database for
+** a table of that name. If found, the output variables are populated
+** as follows:
+**
+** *pnCol: Set to the number of columns table xxx has,
+**
+** *pnStr: Set to the total amount of space required to store a copy
+** of each columns name, including the nul-terminator.
+**
+** *pazCol: Set to point to an array of *pnCol strings. Each string is
+** the name of the corresponding column in table xxx. The array
+** and its contents are allocated using a single allocation. It
+** is the responsibility of the caller to free this allocation
+** by eventually passing the *pazCol value to sqlite3_free().
+**
+** If the table cannot be found, an error code is returned and the output
+** variables are undefined. Or, if an OOM is encountered, SQLITE_NOMEM is
+** returned (and the output variables are undefined).
+*/
+static int fts3ContentColumns(
+ sqlite3 *db, /* Database handle */
+ const char *zDb, /* Name of db (i.e. "main", "temp" etc.) */
+ const char *zTbl, /* Name of content table */
+ const char ***pazCol, /* OUT: Malloc'd array of column names */
+ int *pnCol, /* OUT: Size of array *pazCol */
+ int *pnStr /* OUT: Bytes of string content */
+){
+ int rc = SQLITE_OK; /* Return code */
+ char *zSql; /* "SELECT *" statement on zTbl */
+ sqlite3_stmt *pStmt = 0; /* Compiled version of zSql */
+
+ zSql = sqlite3_mprintf("SELECT * FROM %Q.%Q", zDb, zTbl);
+ if( !zSql ){
+ rc = SQLITE_NOMEM;
+ }else{
+ rc = sqlite3_prepare(db, zSql, -1, &pStmt, 0);
+ }
+ sqlite3_free(zSql);
+
+ if( rc==SQLITE_OK ){
+ const char **azCol; /* Output array */
+ int nStr = 0; /* Size of all column names (incl. 0x00) */
+ int nCol; /* Number of table columns */
+ int i; /* Used to iterate through columns */
+
+ /* Loop through the returned columns. Set nStr to the number of bytes of
+ ** space required to store a copy of each column name, including the
+ ** nul-terminator byte. */
+ nCol = sqlite3_column_count(pStmt);
+ for(i=0; i<nCol; i++){
+ const char *zCol = sqlite3_column_name(pStmt, i);
+ nStr += (int)strlen(zCol) + 1;
+ }
+
+ /* Allocate and populate the array to return. */
+ azCol = (const char **)sqlite3_malloc(sizeof(char *) * nCol + nStr);
+ if( azCol==0 ){
+ rc = SQLITE_NOMEM;
+ }else{
+ char *p = (char *)&azCol[nCol];
+ for(i=0; i<nCol; i++){
+ const char *zCol = sqlite3_column_name(pStmt, i);
+ int n = (int)strlen(zCol)+1;
+ memcpy(p, zCol, n);
+ azCol[i] = p;
+ p += n;
+ }
+ }
+ sqlite3_finalize(pStmt);
+
+ /* Set the output variables. */
+ *pnCol = nCol;
+ *pnStr = nStr;
+ *pazCol = azCol;
+ }
+
+ return rc;
+}
+
+/*
** This function is the implementation of both the xConnect and xCreate
** methods of the FTS3 virtual table.
**
@@ -112924,8 +118761,7 @@ static int fts3InitVtab(
sqlite3_tokenizer *pTokenizer = 0; /* Tokenizer for this table */
int nIndex; /* Size of aIndex[] array */
- struct Fts3Index *aIndex; /* Array of indexes for this table */
- struct Fts3Index *aFree = 0; /* Free this before returning */
+ struct Fts3Index *aIndex = 0; /* Array of indexes for this table */
/* The results of parsing supported FTS4 key=value options: */
int bNoDocsize = 0; /* True to omit %_docsize table */
@@ -112933,6 +118769,8 @@ static int fts3InitVtab(
char *zPrefix = 0; /* Prefix parameter value (or NULL) */
char *zCompress = 0; /* compress=? parameter (or NULL) */
char *zUncompress = 0; /* uncompress=? parameter (or NULL) */
+ char *zContent = 0; /* content=? parameter (or NULL) */
+ char *zLanguageid = 0; /* languageid=? parameter (or NULL) */
assert( strlen(argv[0])==4 );
assert( (sqlite3_strnicmp(argv[0], "fts4", 4)==0 && isFts4)
@@ -112976,13 +118814,14 @@ static int fts3InitVtab(
struct Fts4Option {
const char *zOpt;
int nOpt;
- char **pzVar;
} aFts4Opt[] = {
- { "matchinfo", 9, 0 }, /* 0 -> MATCHINFO */
- { "prefix", 6, 0 }, /* 1 -> PREFIX */
- { "compress", 8, 0 }, /* 2 -> COMPRESS */
- { "uncompress", 10, 0 }, /* 3 -> UNCOMPRESS */
- { "order", 5, 0 } /* 4 -> ORDER */
+ { "matchinfo", 9 }, /* 0 -> MATCHINFO */
+ { "prefix", 6 }, /* 1 -> PREFIX */
+ { "compress", 8 }, /* 2 -> COMPRESS */
+ { "uncompress", 10 }, /* 3 -> UNCOMPRESS */
+ { "order", 5 }, /* 4 -> ORDER */
+ { "content", 7 }, /* 5 -> CONTENT */
+ { "languageid", 10 } /* 6 -> LANGUAGEID */
};
int iOpt;
@@ -113028,13 +118867,26 @@ static int fts3InitVtab(
case 4: /* ORDER */
if( (strlen(zVal)!=3 || sqlite3_strnicmp(zVal, "asc", 3))
- && (strlen(zVal)!=4 || sqlite3_strnicmp(zVal, "desc", 3))
+ && (strlen(zVal)!=4 || sqlite3_strnicmp(zVal, "desc", 4))
){
*pzErr = sqlite3_mprintf("unrecognized order: %s", zVal);
rc = SQLITE_ERROR;
}
bDescIdx = (zVal[0]=='d' || zVal[0]=='D');
break;
+
+ case 5: /* CONTENT */
+ sqlite3_free(zContent);
+ zContent = zVal;
+ zVal = 0;
+ break;
+
+ case 6: /* LANGUAGEID */
+ assert( iOpt==6 );
+ sqlite3_free(zLanguageid);
+ zLanguageid = zVal;
+ zVal = 0;
+ break;
}
}
sqlite3_free(zVal);
@@ -113047,6 +118899,39 @@ static int fts3InitVtab(
aCol[nCol++] = z;
}
}
+
+ /* If a content=xxx option was specified, the following:
+ **
+ ** 1. Ignore any compress= and uncompress= options.
+ **
+ ** 2. If no column names were specified as part of the CREATE VIRTUAL
+ ** TABLE statement, use all columns from the content table.
+ */
+ if( rc==SQLITE_OK && zContent ){
+ sqlite3_free(zCompress);
+ sqlite3_free(zUncompress);
+ zCompress = 0;
+ zUncompress = 0;
+ if( nCol==0 ){
+ sqlite3_free((void*)aCol);
+ aCol = 0;
+ rc = fts3ContentColumns(db, argv[1], zContent, &aCol, &nCol, &nString);
+
+ /* If a languageid= option was specified, remove the language id
+ ** column from the aCol[] array. */
+ if( rc==SQLITE_OK && zLanguageid ){
+ int j;
+ for(j=0; j<nCol; j++){
+ if( sqlite3_stricmp(zLanguageid, aCol[j])==0 ){
+ int k;
+ for(k=j; k<nCol; k++) aCol[k] = aCol[k+1];
+ nCol--;
+ break;
+ }
+ }
+ }
+ }
+ }
if( rc!=SQLITE_OK ) goto fts3_init_out;
if( nCol==0 ){
@@ -113062,7 +118947,7 @@ static int fts3InitVtab(
}
assert( pTokenizer );
- rc = fts3PrefixParameter(zPrefix, &nIndex, &aIndex, &aFree);
+ rc = fts3PrefixParameter(zPrefix, &nIndex, &aIndex);
if( rc==SQLITE_ERROR ){
assert( zPrefix );
*pzErr = sqlite3_mprintf("error parsing prefix parameter: %s", zPrefix);
@@ -113090,7 +118975,13 @@ static int fts3InitVtab(
p->nMaxPendingData = FTS3_MAX_PENDING_DATA;
p->bHasDocsize = (isFts4 && bNoDocsize==0);
p->bHasStat = isFts4;
+ p->bFts4 = isFts4;
p->bDescIdx = bDescIdx;
+ p->bAutoincrmerge = 0xff; /* 0xff means setting unknown */
+ p->zContentTbl = zContent;
+ p->zLanguageid = zLanguageid;
+ zContent = 0;
+ zLanguageid = 0;
TESTONLY( p->inTransaction = -1 );
TESTONLY( p->mxSavepoint = -1 );
@@ -113139,6 +119030,16 @@ static int fts3InitVtab(
rc = fts3CreateTables(p);
}
+ /* Check to see if a legacy fts3 table has been "upgraded" by the
+ ** addition of a %_stat table so that it can use incremental merge.
+ */
+ if( !isFts4 && !isCreate ){
+ int rc2 = SQLITE_OK;
+ fts3DbExec(&rc2, db, "SELECT 1 FROM %Q.'%q_stat' WHERE id=2",
+ p->zDb, p->zName);
+ if( rc2==SQLITE_OK ) p->bHasStat = 1;
+ }
+
/* Figure out the page-size for the database. This is required in order to
** estimate the cost of loading large doclists from the database. */
fts3DatabasePageSize(&rc, p);
@@ -113149,9 +119050,11 @@ static int fts3InitVtab(
fts3_init_out:
sqlite3_free(zPrefix);
- sqlite3_free(aFree);
+ sqlite3_free(aIndex);
sqlite3_free(zCompress);
sqlite3_free(zUncompress);
+ sqlite3_free(zContent);
+ sqlite3_free(zLanguageid);
sqlite3_free((void *)aCol);
if( rc!=SQLITE_OK ){
if( p ){
@@ -113203,6 +119106,7 @@ static int fts3BestIndexMethod(sqlite3_vtab *pVTab, sqlite3_index_info *pInfo){
Fts3Table *p = (Fts3Table *)pVTab;
int i; /* Iterator variable */
int iCons = -1; /* Index of constraint to use */
+ int iLangidCons = -1; /* Index of langid=x constraint, if present */
/* By default use a full table scan. This is an expensive option,
** so search through the constraints to see if a more efficient
@@ -113215,7 +119119,8 @@ static int fts3BestIndexMethod(sqlite3_vtab *pVTab, sqlite3_index_info *pInfo){
if( pCons->usable==0 ) continue;
/* A direct lookup on the rowid or docid column. Assign a cost of 1.0. */
- if( pCons->op==SQLITE_INDEX_CONSTRAINT_EQ
+ if( iCons<0
+ && pCons->op==SQLITE_INDEX_CONSTRAINT_EQ
&& (pCons->iColumn<0 || pCons->iColumn==p->nColumn+1 )
){
pInfo->idxNum = FTS3_DOCID_SEARCH;
@@ -113238,7 +119143,13 @@ static int fts3BestIndexMethod(sqlite3_vtab *pVTab, sqlite3_index_info *pInfo){
pInfo->idxNum = FTS3_FULLTEXT_SEARCH + pCons->iColumn;
pInfo->estimatedCost = 2.0;
iCons = i;
- break;
+ }
+
+ /* Equality constraint on the langid column */
+ if( pCons->op==SQLITE_INDEX_CONSTRAINT_EQ
+ && pCons->iColumn==p->nColumn + 2
+ ){
+ iLangidCons = i;
}
}
@@ -113246,6 +119157,9 @@ static int fts3BestIndexMethod(sqlite3_vtab *pVTab, sqlite3_index_info *pInfo){
pInfo->aConstraintUsage[iCons].argvIndex = 1;
pInfo->aConstraintUsage[iCons].omit = 1;
}
+ if( iLangidCons>=0 ){
+ pInfo->aConstraintUsage[iLangidCons].argvIndex = 2;
+ }
/* Regardless of the strategy selected, FTS can deliver rows in rowid (or
** docid) order. Both ascending and descending are possible.
@@ -113304,34 +119218,63 @@ static int fts3CloseMethod(sqlite3_vtab_cursor *pCursor){
}
/*
+** If pCsr->pStmt has not been prepared (i.e. if pCsr->pStmt==0), then
+** compose and prepare an SQL statement of the form:
+**
+** "SELECT <columns> FROM %_content WHERE rowid = ?"
+**
+** (or the equivalent for a content=xxx table) and set pCsr->pStmt to
+** it. If an error occurs, return an SQLite error code.
+**
+** Otherwise, set *ppStmt to point to pCsr->pStmt and return SQLITE_OK.
+*/
+static int fts3CursorSeekStmt(Fts3Cursor *pCsr, sqlite3_stmt **ppStmt){
+ int rc = SQLITE_OK;
+ if( pCsr->pStmt==0 ){
+ Fts3Table *p = (Fts3Table *)pCsr->base.pVtab;
+ char *zSql;
+ zSql = sqlite3_mprintf("SELECT %s WHERE rowid = ?", p->zReadExprlist);
+ if( !zSql ) return SQLITE_NOMEM;
+ rc = sqlite3_prepare_v2(p->db, zSql, -1, &pCsr->pStmt, 0);
+ sqlite3_free(zSql);
+ }
+ *ppStmt = pCsr->pStmt;
+ return rc;
+}
+
+/*
** Position the pCsr->pStmt statement so that it is on the row
** of the %_content table that contains the last match. Return
** SQLITE_OK on success.
*/
static int fts3CursorSeek(sqlite3_context *pContext, Fts3Cursor *pCsr){
+ int rc = SQLITE_OK;
if( pCsr->isRequireSeek ){
- sqlite3_bind_int64(pCsr->pStmt, 1, pCsr->iPrevId);
- pCsr->isRequireSeek = 0;
- if( SQLITE_ROW==sqlite3_step(pCsr->pStmt) ){
- return SQLITE_OK;
- }else{
- int rc = sqlite3_reset(pCsr->pStmt);
- if( rc==SQLITE_OK ){
- /* If no row was found and no error has occured, then the %_content
- ** table is missing a row that is present in the full-text index.
- ** The data structures are corrupt.
- */
- rc = SQLITE_CORRUPT_VTAB;
- }
- pCsr->isEof = 1;
- if( pContext ){
- sqlite3_result_error_code(pContext, rc);
+ sqlite3_stmt *pStmt = 0;
+
+ rc = fts3CursorSeekStmt(pCsr, &pStmt);
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_int64(pCsr->pStmt, 1, pCsr->iPrevId);
+ pCsr->isRequireSeek = 0;
+ if( SQLITE_ROW==sqlite3_step(pCsr->pStmt) ){
+ return SQLITE_OK;
+ }else{
+ rc = sqlite3_reset(pCsr->pStmt);
+ if( rc==SQLITE_OK && ((Fts3Table *)pCsr->base.pVtab)->zContentTbl==0 ){
+ /* If no row was found and no error has occurred, then the %_content
+ ** table is missing a row that is present in the full-text index.
+ ** The data structures are corrupt. */
+ rc = FTS_CORRUPT_VTAB;
+ pCsr->isEof = 1;
+ }
}
- return rc;
}
- }else{
- return SQLITE_OK;
}
+
+ if( rc!=SQLITE_OK && pContext ){
+ sqlite3_result_error_code(pContext, rc);
+ }
+ return rc;
}
/*
@@ -113381,7 +119324,7 @@ static int fts3ScanInteriorNode(
zCsr += sqlite3Fts3GetVarint(zCsr, &iChild);
zCsr += sqlite3Fts3GetVarint(zCsr, &iChild);
if( zCsr>zEnd ){
- return SQLITE_CORRUPT_VTAB;
+ return FTS_CORRUPT_VTAB;
}
while( zCsr<zEnd && (piFirst || piLast) ){
@@ -113399,7 +119342,7 @@ static int fts3ScanInteriorNode(
zCsr += sqlite3Fts3GetVarint32(zCsr, &nSuffix);
if( nPrefix<0 || nSuffix<0 || &zCsr[nSuffix]>zEnd ){
- rc = SQLITE_CORRUPT_VTAB;
+ rc = FTS_CORRUPT_VTAB;
goto finish_scan;
}
if( nPrefix+nSuffix>nAlloc ){
@@ -113412,6 +119355,7 @@ static int fts3ScanInteriorNode(
}
zBuffer = zNew;
}
+ assert( zBuffer );
memcpy(&zBuffer[nPrefix], zCsr, nSuffix);
nBuffer = nPrefix + nSuffix;
zCsr += nSuffix;
@@ -113740,8 +119684,6 @@ static void fts3PoslistMerge(
}
/*
-** nToken==1 searches for adjacent positions.
-**
** This function is used to merge two position lists into one. When it is
** called, *pp1 and *pp2 must both point to position lists. A position-list is
** the part of a doclist that follows each document id. For example, if a row
@@ -113761,6 +119703,8 @@ static void fts3PoslistMerge(
** *pp1 so that (pos(*pp2)>pos(*pp1) && pos(*pp2)-pos(*pp1)<=nToken). i.e.
** when the *pp1 token appears before the *pp2 token, but not more than nToken
** slots before it.
+**
+** e.g. nToken==1 searches for adjacent positions.
*/
static int fts3PoslistPhraseMerge(
char **pp, /* IN/OUT: Preallocated output buffer */
@@ -113770,7 +119714,7 @@ static int fts3PoslistPhraseMerge(
char **pp1, /* IN/OUT: Left input list */
char **pp2 /* IN/OUT: Right input list */
){
- char *p = (pp ? *pp : 0);
+ char *p = *pp;
char *p1 = *pp1;
char *p2 = *pp2;
int iCol1 = 0;
@@ -113779,7 +119723,7 @@ static int fts3PoslistPhraseMerge(
/* Never set both isSaveLeft and isExact for the same invocation. */
assert( isSaveLeft==0 || isExact==0 );
- assert( *p1!=0 && *p2!=0 );
+ assert( p!=0 && *p1!=0 && *p2!=0 );
if( *p1==POS_COLUMN ){
p1++;
p1 += sqlite3Fts3GetVarint32(p1, &iCol1);
@@ -113796,7 +119740,7 @@ static int fts3PoslistPhraseMerge(
sqlite3_int64 iPos1 = 0;
sqlite3_int64 iPos2 = 0;
- if( pp && iCol1 ){
+ if( iCol1 ){
*p++ = POS_COLUMN;
p += sqlite3Fts3PutVarint(p, iCol1);
}
@@ -113811,16 +119755,10 @@ static int fts3PoslistPhraseMerge(
|| (isExact==0 && iPos2>iPos1 && iPos2<=iPos1+nToken)
){
sqlite3_int64 iSave;
- if( !pp ){
- fts3PoslistCopy(0, &p2);
- fts3PoslistCopy(0, &p1);
- *pp1 = p1;
- *pp2 = p2;
- return 1;
- }
iSave = isSaveLeft ? iPos1 : iPos2;
fts3PutDeltaVarint(&p, &iPrev, iSave+2); iPrev -= 2;
pSave = 0;
+ assert( p );
}
if( (!isSaveLeft && iPos2<=(iPos1+nToken)) || iPos2<=iPos1 ){
if( (*p2&0xFE)==0 ) break;
@@ -113869,7 +119807,7 @@ static int fts3PoslistPhraseMerge(
fts3PoslistCopy(0, &p1);
*pp1 = p1;
*pp2 = p2;
- if( !pp || *pp==p ){
+ if( *pp==p ){
return 0;
}
*p++ = 0x00;
@@ -113927,22 +119865,34 @@ static int fts3PoslistNearMerge(
}
/*
-** A pointer to an instance of this structure is used as the context
-** argument to sqlite3Fts3SegReaderIterate()
+** An instance of this function is used to merge together the (potentially
+** large number of) doclists for each term that matches a prefix query.
+** See function fts3TermSelectMerge() for details.
*/
typedef struct TermSelect TermSelect;
struct TermSelect {
- int isReqPos;
- char *aaOutput[16]; /* Malloc'd output buffer */
- int anOutput[16]; /* Size of output in bytes */
+ char *aaOutput[16]; /* Malloc'd output buffers */
+ int anOutput[16]; /* Size each output buffer in bytes */
};
-
+/*
+** This function is used to read a single varint from a buffer. Parameter
+** pEnd points 1 byte past the end of the buffer. When this function is
+** called, if *pp points to pEnd or greater, then the end of the buffer
+** has been reached. In this case *pp is set to 0 and the function returns.
+**
+** If *pp does not point to or past pEnd, then a single varint is read
+** from *pp. *pp is then set to point 1 byte past the end of the read varint.
+**
+** If bDescIdx is false, the value read is added to *pVal before returning.
+** If it is true, the value read is subtracted from *pVal before this
+** function returns.
+*/
static void fts3GetDeltaVarint3(
- char **pp,
- char *pEnd,
- int bDescIdx,
- sqlite3_int64 *pVal
+ char **pp, /* IN/OUT: Point to read varint from */
+ char *pEnd, /* End of buffer */
+ int bDescIdx, /* True if docids are descending */
+ sqlite3_int64 *pVal /* IN/OUT: Integer value */
){
if( *pp>=pEnd ){
*pp = 0;
@@ -113957,6 +119907,21 @@ static void fts3GetDeltaVarint3(
}
}
+/*
+** This function is used to write a single varint to a buffer. The varint
+** is written to *pp. Before returning, *pp is set to point 1 byte past the
+** end of the value written.
+**
+** If *pbFirst is zero when this function is called, the value written to
+** the buffer is that of parameter iVal.
+**
+** If *pbFirst is non-zero when this function is called, then the value
+** written is either (iVal-*piPrev) (if bDescIdx is zero) or (*piPrev-iVal)
+** (if bDescIdx is non-zero).
+**
+** Before returning, this function always sets *pbFirst to 1 and *piPrev
+** to the value of parameter iVal.
+*/
static void fts3PutDeltaVarint3(
char **pp, /* IN/OUT: Output pointer */
int bDescIdx, /* True for descending docids */
@@ -113977,10 +119942,34 @@ static void fts3PutDeltaVarint3(
*pbFirst = 1;
}
-#define COMPARE_DOCID(i1, i2) ((bDescIdx?-1:1) * (i1-i2))
+/*
+** This macro is used by various functions that merge doclists. The two
+** arguments are 64-bit docid values. If the value of the stack variable
+** bDescDoclist is 0 when this macro is invoked, then it returns (i1-i2).
+** Otherwise, (i2-i1).
+**
+** Using this makes it easier to write code that can merge doclists that are
+** sorted in either ascending or descending order.
+*/
+#define DOCID_CMP(i1, i2) ((bDescDoclist?-1:1) * (i1-i2))
+
+/*
+** This function does an "OR" merge of two doclists (output contains all
+** positions contained in either argument doclist). If the docids in the
+** input doclists are sorted in ascending order, parameter bDescDoclist
+** should be false. If they are sorted in ascending order, it should be
+** passed a non-zero value.
+**
+** If no error occurs, *paOut is set to point at an sqlite3_malloc'd buffer
+** containing the output doclist and SQLITE_OK is returned. In this case
+** *pnOut is set to the number of bytes in the output doclist.
+**
+** If an error occurs, an SQLite error code is returned. The output values
+** are undefined in this case.
+*/
static int fts3DoclistOrMerge(
- int bDescIdx, /* True if arguments are desc */
+ int bDescDoclist, /* True if arguments are desc */
char *a1, int n1, /* First doclist */
char *a2, int n2, /* Second doclist */
char **paOut, int *pnOut /* OUT: Malloc'd doclist */
@@ -113998,38 +119987,81 @@ static int fts3DoclistOrMerge(
*paOut = 0;
*pnOut = 0;
- aOut = sqlite3_malloc(n1+n2);
+
+ /* Allocate space for the output. Both the input and output doclists
+ ** are delta encoded. If they are in ascending order (bDescDoclist==0),
+ ** then the first docid in each list is simply encoded as a varint. For
+ ** each subsequent docid, the varint stored is the difference between the
+ ** current and previous docid (a positive number - since the list is in
+ ** ascending order).
+ **
+ ** The first docid written to the output is therefore encoded using the
+ ** same number of bytes as it is in whichever of the input lists it is
+ ** read from. And each subsequent docid read from the same input list
+ ** consumes either the same or less bytes as it did in the input (since
+ ** the difference between it and the previous value in the output must
+ ** be a positive value less than or equal to the delta value read from
+ ** the input list). The same argument applies to all but the first docid
+ ** read from the 'other' list. And to the contents of all position lists
+ ** that will be copied and merged from the input to the output.
+ **
+ ** However, if the first docid copied to the output is a negative number,
+ ** then the encoding of the first docid from the 'other' input list may
+ ** be larger in the output than it was in the input (since the delta value
+ ** may be a larger positive integer than the actual docid).
+ **
+ ** The space required to store the output is therefore the sum of the
+ ** sizes of the two inputs, plus enough space for exactly one of the input
+ ** docids to grow.
+ **
+ ** A symetric argument may be made if the doclists are in descending
+ ** order.
+ */
+ aOut = sqlite3_malloc(n1+n2+FTS3_VARINT_MAX-1);
if( !aOut ) return SQLITE_NOMEM;
p = aOut;
fts3GetDeltaVarint3(&p1, pEnd1, 0, &i1);
fts3GetDeltaVarint3(&p2, pEnd2, 0, &i2);
while( p1 || p2 ){
- sqlite3_int64 iDiff = COMPARE_DOCID(i1, i2);
+ sqlite3_int64 iDiff = DOCID_CMP(i1, i2);
if( p2 && p1 && iDiff==0 ){
- fts3PutDeltaVarint3(&p, bDescIdx, &iPrev, &bFirstOut, i1);
+ fts3PutDeltaVarint3(&p, bDescDoclist, &iPrev, &bFirstOut, i1);
fts3PoslistMerge(&p, &p1, &p2);
- fts3GetDeltaVarint3(&p1, pEnd1, bDescIdx, &i1);
- fts3GetDeltaVarint3(&p2, pEnd2, bDescIdx, &i2);
+ fts3GetDeltaVarint3(&p1, pEnd1, bDescDoclist, &i1);
+ fts3GetDeltaVarint3(&p2, pEnd2, bDescDoclist, &i2);
}else if( !p2 || (p1 && iDiff<0) ){
- fts3PutDeltaVarint3(&p, bDescIdx, &iPrev, &bFirstOut, i1);
+ fts3PutDeltaVarint3(&p, bDescDoclist, &iPrev, &bFirstOut, i1);
fts3PoslistCopy(&p, &p1);
- fts3GetDeltaVarint3(&p1, pEnd1, bDescIdx, &i1);
+ fts3GetDeltaVarint3(&p1, pEnd1, bDescDoclist, &i1);
}else{
- fts3PutDeltaVarint3(&p, bDescIdx, &iPrev, &bFirstOut, i2);
+ fts3PutDeltaVarint3(&p, bDescDoclist, &iPrev, &bFirstOut, i2);
fts3PoslistCopy(&p, &p2);
- fts3GetDeltaVarint3(&p2, pEnd2, bDescIdx, &i2);
+ fts3GetDeltaVarint3(&p2, pEnd2, bDescDoclist, &i2);
}
}
*paOut = aOut;
- *pnOut = (p-aOut);
+ *pnOut = (int)(p-aOut);
+ assert( *pnOut<=n1+n2+FTS3_VARINT_MAX-1 );
return SQLITE_OK;
}
+/*
+** This function does a "phrase" merge of two doclists. In a phrase merge,
+** the output contains a copy of each position from the right-hand input
+** doclist for which there is a position in the left-hand input doclist
+** exactly nDist tokens before it.
+**
+** If the docids in the input doclists are sorted in ascending order,
+** parameter bDescDoclist should be false. If they are sorted in ascending
+** order, it should be passed a non-zero value.
+**
+** The right-hand input doclist is overwritten by this function.
+*/
static void fts3DoclistPhraseMerge(
- int bDescIdx, /* True if arguments are desc */
+ int bDescDoclist, /* True if arguments are desc */
int nDist, /* Distance from left to right (1=adjacent) */
char *aLeft, int nLeft, /* Left doclist */
char *aRight, int *pnRight /* IN/OUT: Right/output doclist */
@@ -114052,30 +120084,80 @@ static void fts3DoclistPhraseMerge(
fts3GetDeltaVarint3(&p2, pEnd2, 0, &i2);
while( p1 && p2 ){
- sqlite3_int64 iDiff = COMPARE_DOCID(i1, i2);
+ sqlite3_int64 iDiff = DOCID_CMP(i1, i2);
if( iDiff==0 ){
char *pSave = p;
sqlite3_int64 iPrevSave = iPrev;
int bFirstOutSave = bFirstOut;
- fts3PutDeltaVarint3(&p, bDescIdx, &iPrev, &bFirstOut, i1);
+ fts3PutDeltaVarint3(&p, bDescDoclist, &iPrev, &bFirstOut, i1);
if( 0==fts3PoslistPhraseMerge(&p, nDist, 0, 1, &p1, &p2) ){
p = pSave;
iPrev = iPrevSave;
bFirstOut = bFirstOutSave;
}
- fts3GetDeltaVarint3(&p1, pEnd1, bDescIdx, &i1);
- fts3GetDeltaVarint3(&p2, pEnd2, bDescIdx, &i2);
+ fts3GetDeltaVarint3(&p1, pEnd1, bDescDoclist, &i1);
+ fts3GetDeltaVarint3(&p2, pEnd2, bDescDoclist, &i2);
}else if( iDiff<0 ){
fts3PoslistCopy(0, &p1);
- fts3GetDeltaVarint3(&p1, pEnd1, bDescIdx, &i1);
+ fts3GetDeltaVarint3(&p1, pEnd1, bDescDoclist, &i1);
}else{
fts3PoslistCopy(0, &p2);
- fts3GetDeltaVarint3(&p2, pEnd2, bDescIdx, &i2);
+ fts3GetDeltaVarint3(&p2, pEnd2, bDescDoclist, &i2);
}
}
- *pnRight = p - aOut;
+ *pnRight = (int)(p - aOut);
+}
+
+/*
+** Argument pList points to a position list nList bytes in size. This
+** function checks to see if the position list contains any entries for
+** a token in position 0 (of any column). If so, it writes argument iDelta
+** to the output buffer pOut, followed by a position list consisting only
+** of the entries from pList at position 0, and terminated by an 0x00 byte.
+** The value returned is the number of bytes written to pOut (if any).
+*/
+SQLITE_PRIVATE int sqlite3Fts3FirstFilter(
+ sqlite3_int64 iDelta, /* Varint that may be written to pOut */
+ char *pList, /* Position list (no 0x00 term) */
+ int nList, /* Size of pList in bytes */
+ char *pOut /* Write output here */
+){
+ int nOut = 0;
+ int bWritten = 0; /* True once iDelta has been written */
+ char *p = pList;
+ char *pEnd = &pList[nList];
+
+ if( *p!=0x01 ){
+ if( *p==0x02 ){
+ nOut += sqlite3Fts3PutVarint(&pOut[nOut], iDelta);
+ pOut[nOut++] = 0x02;
+ bWritten = 1;
+ }
+ fts3ColumnlistCopy(0, &p);
+ }
+
+ while( p<pEnd && *p==0x01 ){
+ sqlite3_int64 iCol;
+ p++;
+ p += sqlite3Fts3GetVarint(p, &iCol);
+ if( *p==0x02 ){
+ if( bWritten==0 ){
+ nOut += sqlite3Fts3PutVarint(&pOut[nOut], iDelta);
+ bWritten = 1;
+ }
+ pOut[nOut++] = 0x01;
+ nOut += sqlite3Fts3PutVarint(&pOut[nOut], iCol);
+ pOut[nOut++] = 0x02;
+ }
+ fts3ColumnlistCopy(0, &p);
+ }
+ if( bWritten ){
+ pOut[nOut++] = 0x00;
+ }
+
+ return nOut;
}
@@ -114088,7 +120170,7 @@ static void fts3DoclistPhraseMerge(
** the responsibility of the caller to free any doclists left in the
** TermSelect.aaOutput[] array.
*/
-static int fts3TermSelectMerge(Fts3Table *p, TermSelect *pTS){
+static int fts3TermSelectFinishMerge(Fts3Table *p, TermSelect *pTS){
char *aOut = 0;
int nOut = 0;
int i;
@@ -114129,24 +120211,25 @@ static int fts3TermSelectMerge(Fts3Table *p, TermSelect *pTS){
}
/*
-** This function is used as the sqlite3Fts3SegReaderIterate() callback when
-** querying the full-text index for a doclist associated with a term or
-** term-prefix.
+** Merge the doclist aDoclist/nDoclist into the TermSelect object passed
+** as the first argument. The merge is an "OR" merge (see function
+** fts3DoclistOrMerge() for details).
+**
+** This function is called with the doclist for each term that matches
+** a queried prefix. It merges all these doclists into one, the doclist
+** for the specified prefix. Since there can be a very large number of
+** doclists to merge, the merging is done pair-wise using the TermSelect
+** object.
+**
+** This function returns SQLITE_OK if the merge is successful, or an
+** SQLite error code (SQLITE_NOMEM) if an error occurs.
*/
-static int fts3TermSelectCb(
- Fts3Table *p, /* Virtual table object */
- void *pContext, /* Pointer to TermSelect structure */
- char *zTerm,
- int nTerm,
- char *aDoclist,
- int nDoclist
+static int fts3TermSelectMerge(
+ Fts3Table *p, /* FTS table handle */
+ TermSelect *pTS, /* TermSelect object to merge into */
+ char *aDoclist, /* Pointer to doclist */
+ int nDoclist /* Size of aDoclist in bytes */
){
- TermSelect *pTS = (TermSelect *)pContext;
-
- UNUSED_PARAMETER(p);
- UNUSED_PARAMETER(zTerm);
- UNUSED_PARAMETER(nTerm);
-
if( pTS->aaOutput[0]==0 ){
/* If this is the first term selected, copy the doclist to the output
** buffer using memcpy(). */
@@ -114217,19 +120300,27 @@ static int fts3SegReaderCursorAppend(
return SQLITE_OK;
}
+/*
+** Add seg-reader objects to the Fts3MultiSegReader object passed as the
+** 8th argument.
+**
+** This function returns SQLITE_OK if successful, or an SQLite error code
+** otherwise.
+*/
static int fts3SegReaderCursor(
Fts3Table *p, /* FTS3 table handle */
+ int iLangid, /* Language id */
int iIndex, /* Index to search (from 0 to p->nIndex-1) */
int iLevel, /* Level of segments to scan */
const char *zTerm, /* Term to query for */
int nTerm, /* Size of zTerm in bytes */
int isPrefix, /* True for a prefix search */
int isScan, /* True to scan from zTerm to EOF */
- Fts3MultiSegReader *pCsr /* Cursor object to populate */
+ Fts3MultiSegReader *pCsr /* Cursor object to populate */
){
- int rc = SQLITE_OK;
- int rc2;
- sqlite3_stmt *pStmt = 0;
+ int rc = SQLITE_OK; /* Error code */
+ sqlite3_stmt *pStmt = 0; /* Statement to iterate through segments */
+ int rc2; /* Result of sqlite3_reset() */
/* If iLevel is less than 0 and this is not a scan, include a seg-reader
** for the pending-terms. If this is a scan, then this call must be being
@@ -114247,7 +120338,7 @@ static int fts3SegReaderCursor(
if( iLevel!=FTS3_SEGCURSOR_PENDING ){
if( rc==SQLITE_OK ){
- rc = sqlite3Fts3AllSegdirs(p, iIndex, iLevel, &pStmt);
+ rc = sqlite3Fts3AllSegdirs(p, iLangid, iIndex, iLevel, &pStmt);
}
while( rc==SQLITE_OK && SQLITE_ROW==(rc = sqlite3_step(pStmt)) ){
@@ -114270,7 +120361,9 @@ static int fts3SegReaderCursor(
}
rc = sqlite3Fts3SegReaderNew(pCsr->nSegment+1,
- iStartBlock, iLeavesEndBlock, iEndBlock, zRoot, nRoot, &pSeg
+ (isPrefix==0 && isScan==0),
+ iStartBlock, iLeavesEndBlock,
+ iEndBlock, zRoot, nRoot, &pSeg
);
if( rc!=SQLITE_OK ) goto finished;
rc = fts3SegReaderCursorAppend(pCsr, pSeg);
@@ -114290,6 +120383,7 @@ static int fts3SegReaderCursor(
*/
SQLITE_PRIVATE int sqlite3Fts3SegReaderCursor(
Fts3Table *p, /* FTS3 table handle */
+ int iLangid, /* Language-id to search */
int iIndex, /* Index to search (from 0 to p->nIndex-1) */
int iLevel, /* Level of segments to scan */
const char *zTerm, /* Term to query for */
@@ -114307,35 +120401,51 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderCursor(
assert( FTS3_SEGCURSOR_ALL<0 && FTS3_SEGCURSOR_PENDING<0 );
assert( isPrefix==0 || isScan==0 );
- /* "isScan" is only set to true by the ft4aux module, an ordinary
- ** full-text tables. */
- assert( isScan==0 || p->aIndex==0 );
-
memset(pCsr, 0, sizeof(Fts3MultiSegReader));
-
return fts3SegReaderCursor(
- p, iIndex, iLevel, zTerm, nTerm, isPrefix, isScan, pCsr
+ p, iLangid, iIndex, iLevel, zTerm, nTerm, isPrefix, isScan, pCsr
);
}
+/*
+** In addition to its current configuration, have the Fts3MultiSegReader
+** passed as the 4th argument also scan the doclist for term zTerm/nTerm.
+**
+** SQLITE_OK is returned if no error occurs, otherwise an SQLite error code.
+*/
static int fts3SegReaderCursorAddZero(
- Fts3Table *p,
- const char *zTerm,
- int nTerm,
- Fts3MultiSegReader *pCsr
-){
- return fts3SegReaderCursor(p, 0, FTS3_SEGCURSOR_ALL, zTerm, nTerm, 0, 0,pCsr);
+ Fts3Table *p, /* FTS virtual table handle */
+ int iLangid,
+ const char *zTerm, /* Term to scan doclist of */
+ int nTerm, /* Number of bytes in zTerm */
+ Fts3MultiSegReader *pCsr /* Fts3MultiSegReader to modify */
+){
+ return fts3SegReaderCursor(p,
+ iLangid, 0, FTS3_SEGCURSOR_ALL, zTerm, nTerm, 0, 0,pCsr
+ );
}
-
-SQLITE_PRIVATE int sqlite3Fts3TermSegReaderCursor(
+/*
+** Open an Fts3MultiSegReader to scan the doclist for term zTerm/nTerm. Or,
+** if isPrefix is true, to scan the doclist for all terms for which
+** zTerm/nTerm is a prefix. If successful, return SQLITE_OK and write
+** a pointer to the new Fts3MultiSegReader to *ppSegcsr. Otherwise, return
+** an SQLite error code.
+**
+** It is the responsibility of the caller to free this object by eventually
+** passing it to fts3SegReaderCursorFree()
+**
+** SQLITE_OK is returned if no error occurs, otherwise an SQLite error code.
+** Output parameter *ppSegcsr is set to 0 if an error occurs.
+*/
+static int fts3TermSegReaderCursor(
Fts3Cursor *pCsr, /* Virtual table cursor handle */
const char *zTerm, /* Term to query for */
int nTerm, /* Size of zTerm in bytes */
int isPrefix, /* True for a prefix search */
Fts3MultiSegReader **ppSegcsr /* OUT: Allocated seg-reader cursor */
){
- Fts3MultiSegReader *pSegcsr; /* Object to allocate and return */
+ Fts3MultiSegReader *pSegcsr; /* Object to allocate and return */
int rc = SQLITE_NOMEM; /* Return code */
pSegcsr = sqlite3_malloc(sizeof(Fts3MultiSegReader));
@@ -114348,8 +120458,9 @@ SQLITE_PRIVATE int sqlite3Fts3TermSegReaderCursor(
for(i=1; bFound==0 && i<p->nIndex; i++){
if( p->aIndex[i].nPrefix==nTerm ){
bFound = 1;
- rc = sqlite3Fts3SegReaderCursor(
- p, i, FTS3_SEGCURSOR_ALL, zTerm, nTerm, 0, 0, pSegcsr);
+ rc = sqlite3Fts3SegReaderCursor(p, pCsr->iLangid,
+ i, FTS3_SEGCURSOR_ALL, zTerm, nTerm, 0, 0, pSegcsr
+ );
pSegcsr->bLookup = 1;
}
}
@@ -114357,19 +120468,21 @@ SQLITE_PRIVATE int sqlite3Fts3TermSegReaderCursor(
for(i=1; bFound==0 && i<p->nIndex; i++){
if( p->aIndex[i].nPrefix==nTerm+1 ){
bFound = 1;
- rc = sqlite3Fts3SegReaderCursor(
- p, i, FTS3_SEGCURSOR_ALL, zTerm, nTerm, 1, 0, pSegcsr
+ rc = sqlite3Fts3SegReaderCursor(p, pCsr->iLangid,
+ i, FTS3_SEGCURSOR_ALL, zTerm, nTerm, 1, 0, pSegcsr
);
if( rc==SQLITE_OK ){
- rc = fts3SegReaderCursorAddZero(p, zTerm, nTerm, pSegcsr);
+ rc = fts3SegReaderCursorAddZero(
+ p, pCsr->iLangid, zTerm, nTerm, pSegcsr
+ );
}
}
}
}
if( bFound==0 ){
- rc = sqlite3Fts3SegReaderCursor(
- p, 0, FTS3_SEGCURSOR_ALL, zTerm, nTerm, isPrefix, 0, pSegcsr
+ rc = sqlite3Fts3SegReaderCursor(p, pCsr->iLangid,
+ 0, FTS3_SEGCURSOR_ALL, zTerm, nTerm, isPrefix, 0, pSegcsr
);
pSegcsr->bLookup = !isPrefix;
}
@@ -114379,42 +120492,36 @@ SQLITE_PRIVATE int sqlite3Fts3TermSegReaderCursor(
return rc;
}
+/*
+** Free an Fts3MultiSegReader allocated by fts3TermSegReaderCursor().
+*/
static void fts3SegReaderCursorFree(Fts3MultiSegReader *pSegcsr){
sqlite3Fts3SegReaderFinish(pSegcsr);
sqlite3_free(pSegcsr);
}
/*
-** This function retreives the doclist for the specified term (or term
-** prefix) from the database.
-**
-** The returned doclist may be in one of two formats, depending on the
-** value of parameter isReqPos. If isReqPos is zero, then the doclist is
-** a sorted list of delta-compressed docids (a bare doclist). If isReqPos
-** is non-zero, then the returned list is in the same format as is stored
-** in the database without the found length specifier at the start of on-disk
-** doclists.
+** This function retrieves the doclist for the specified term (or term
+** prefix) from the database.
*/
static int fts3TermSelect(
Fts3Table *p, /* Virtual table handle */
Fts3PhraseToken *pTok, /* Token to query for */
int iColumn, /* Column to query (or -ve for all columns) */
- int isReqPos, /* True to include position lists in output */
int *pnOut, /* OUT: Size of buffer at *ppOut */
char **ppOut /* OUT: Malloced result buffer */
){
int rc; /* Return code */
- Fts3MultiSegReader *pSegcsr; /* Seg-reader cursor for this term */
- TermSelect tsc; /* Context object for fts3TermSelectCb() */
+ Fts3MultiSegReader *pSegcsr; /* Seg-reader cursor for this term */
+ TermSelect tsc; /* Object for pair-wise doclist merging */
Fts3SegFilter filter; /* Segment term filter configuration */
pSegcsr = pTok->pSegcsr;
memset(&tsc, 0, sizeof(TermSelect));
- tsc.isReqPos = isReqPos;
- filter.flags = FTS3_SEGMENT_IGNORE_EMPTY
+ filter.flags = FTS3_SEGMENT_IGNORE_EMPTY | FTS3_SEGMENT_REQUIRE_POS
| (pTok->isPrefix ? FTS3_SEGMENT_PREFIX : 0)
- | (isReqPos ? FTS3_SEGMENT_REQUIRE_POS : 0)
+ | (pTok->bFirst ? FTS3_SEGMENT_FIRST : 0)
| (iColumn<p->nColumn ? FTS3_SEGMENT_COLUMN_FILTER : 0);
filter.iCol = iColumn;
filter.zTerm = pTok->z;
@@ -114424,13 +120531,11 @@ static int fts3TermSelect(
while( SQLITE_OK==rc
&& SQLITE_ROW==(rc = sqlite3Fts3SegReaderStep(p, pSegcsr))
){
- rc = fts3TermSelectCb(p, (void *)&tsc,
- pSegcsr->zTerm, pSegcsr->nTerm, pSegcsr->aDoclist, pSegcsr->nDoclist
- );
+ rc = fts3TermSelectMerge(p, &tsc, pSegcsr->aDoclist, pSegcsr->nDoclist);
}
if( rc==SQLITE_OK ){
- rc = fts3TermSelectMerge(p, &tsc);
+ rc = fts3TermSelectFinishMerge(p, &tsc);
}
if( rc==SQLITE_OK ){
*ppOut = tsc.aaOutput[0];
@@ -114456,24 +120561,15 @@ static int fts3TermSelect(
** that the doclist is simply a list of docids stored as delta encoded
** varints.
*/
-static int fts3DoclistCountDocids(int isPoslist, char *aList, int nList){
+static int fts3DoclistCountDocids(char *aList, int nList){
int nDoc = 0; /* Return value */
if( aList ){
char *aEnd = &aList[nList]; /* Pointer to one byte after EOF */
char *p = aList; /* Cursor */
- if( !isPoslist ){
- /* The number of docids in the list is the same as the number of
- ** varints. In FTS3 a varint consists of a single byte with the 0x80
- ** bit cleared and zero or more bytes with the 0x80 bit set. So to
- ** count the varints in the buffer, just count the number of bytes
- ** with the 0x80 bit clear. */
- while( p<aEnd ) nDoc += (((*p++)&0x80)==0);
- }else{
- while( p<aEnd ){
- nDoc++;
- while( (*p++)&0x80 ); /* Skip docid varint */
- fts3PoslistCopy(0, &p); /* Skip over position list */
- }
+ while( p<aEnd ){
+ nDoc++;
+ while( (*p++)&0x80 ); /* Skip docid varint */
+ fts3PoslistCopy(0, &p); /* Skip over position list */
}
}
@@ -114503,7 +120599,7 @@ static int fts3NextMethod(sqlite3_vtab_cursor *pCursor){
rc = SQLITE_OK;
}
}else{
- rc = sqlite3Fts3EvalNext((Fts3Cursor *)pCursor);
+ rc = fts3EvalNext((Fts3Cursor *)pCursor);
}
assert( ((Fts3Table *)pCsr->base.pVtab)->pSegments==0 );
return rc;
@@ -114541,7 +120637,7 @@ static int fts3FilterMethod(
UNUSED_PARAMETER(nVal);
assert( idxNum>=0 && idxNum<=(FTS3_FULLTEXT_SEARCH+p->nColumn) );
- assert( nVal==0 || nVal==1 );
+ assert( nVal==0 || nVal==1 || nVal==2 );
assert( (nVal==0)==(idxNum==FTS3_FULLSCAN_SEARCH) );
assert( p->pSegments==0 );
@@ -114566,8 +120662,11 @@ static int fts3FilterMethod(
return SQLITE_NOMEM;
}
- rc = sqlite3Fts3ExprParse(p->pTokenizer, p->azColumn, p->nColumn,
- iCol, zQuery, -1, &pCsr->pExpr
+ pCsr->iLangid = 0;
+ if( nVal==2 ) pCsr->iLangid = sqlite3_value_int(apVal[1]);
+
+ rc = sqlite3Fts3ExprParse(p->pTokenizer, pCsr->iLangid,
+ p->azColumn, p->bFts4, p->nColumn, iCol, zQuery, -1, &pCsr->pExpr
);
if( rc!=SQLITE_OK ){
if( rc==SQLITE_ERROR ){
@@ -114580,7 +120679,7 @@ static int fts3FilterMethod(
rc = sqlite3Fts3ReadLock(p);
if( rc!=SQLITE_OK ) return rc;
- rc = sqlite3Fts3EvalStart(pCsr, pCsr->pExpr, 1);
+ rc = fts3EvalStart(pCsr);
sqlite3Fts3SegmentsClose(p);
if( rc!=SQLITE_OK ) return rc;
@@ -114594,23 +120693,24 @@ static int fts3FilterMethod(
** row by docid.
*/
if( idxNum==FTS3_FULLSCAN_SEARCH ){
- const char *zSort = (pCsr->bDesc ? "DESC" : "ASC");
- const char *zTmpl = "SELECT %s FROM %Q.'%q_content' AS x ORDER BY docid %s";
- zSql = sqlite3_mprintf(zTmpl, p->zReadExprlist, p->zDb, p->zName, zSort);
- }else{
- const char *zTmpl = "SELECT %s FROM %Q.'%q_content' AS x WHERE docid = ?";
- zSql = sqlite3_mprintf(zTmpl, p->zReadExprlist, p->zDb, p->zName);
+ zSql = sqlite3_mprintf(
+ "SELECT %s ORDER BY rowid %s",
+ p->zReadExprlist, (pCsr->bDesc ? "DESC" : "ASC")
+ );
+ if( zSql ){
+ rc = sqlite3_prepare_v2(p->db, zSql, -1, &pCsr->pStmt, 0);
+ sqlite3_free(zSql);
+ }else{
+ rc = SQLITE_NOMEM;
+ }
+ }else if( idxNum==FTS3_DOCID_SEARCH ){
+ rc = fts3CursorSeekStmt(pCsr, &pCsr->pStmt);
+ if( rc==SQLITE_OK ){
+ rc = sqlite3_bind_value(pCsr->pStmt, 1, apVal[0]);
+ }
}
- if( !zSql ) return SQLITE_NOMEM;
- rc = sqlite3_prepare_v2(p->db, zSql, -1, &pCsr->pStmt, 0);
- sqlite3_free(zSql);
if( rc!=SQLITE_OK ) return rc;
- if( idxNum==FTS3_DOCID_SEARCH ){
- rc = sqlite3_bind_value(pCsr->pStmt, 1, apVal[0]);
- if( rc!=SQLITE_OK ) return rc;
- }
-
return fts3NextMethod(pCursor);
}
@@ -114637,10 +120737,17 @@ static int fts3RowidMethod(sqlite3_vtab_cursor *pCursor, sqlite_int64 *pRowid){
/*
** This is the xColumn method, called by SQLite to request a value from
** the row that the supplied cursor currently points to.
+**
+** If:
+**
+** (iCol < p->nColumn) -> The value of the iCol'th user column.
+** (iCol == p->nColumn) -> Magic column with the same name as the table.
+** (iCol == p->nColumn+1) -> Docid column
+** (iCol == p->nColumn+2) -> Langid column
*/
static int fts3ColumnMethod(
sqlite3_vtab_cursor *pCursor, /* Cursor to retrieve value from */
- sqlite3_context *pContext, /* Context for sqlite3_result_xxx() calls */
+ sqlite3_context *pCtx, /* Context for sqlite3_result_xxx() calls */
int iCol /* Index of column to read value from */
){
int rc = SQLITE_OK; /* Return Code */
@@ -114648,22 +120755,34 @@ static int fts3ColumnMethod(
Fts3Table *p = (Fts3Table *)pCursor->pVtab;
/* The column value supplied by SQLite must be in range. */
- assert( iCol>=0 && iCol<=p->nColumn+1 );
+ assert( iCol>=0 && iCol<=p->nColumn+2 );
if( iCol==p->nColumn+1 ){
/* This call is a request for the "docid" column. Since "docid" is an
** alias for "rowid", use the xRowid() method to obtain the value.
*/
- sqlite3_result_int64(pContext, pCsr->iPrevId);
+ sqlite3_result_int64(pCtx, pCsr->iPrevId);
}else if( iCol==p->nColumn ){
/* The extra column whose name is the same as the table.
- ** Return a blob which is a pointer to the cursor.
- */
- sqlite3_result_blob(pContext, &pCsr, sizeof(pCsr), SQLITE_TRANSIENT);
+ ** Return a blob which is a pointer to the cursor. */
+ sqlite3_result_blob(pCtx, &pCsr, sizeof(pCsr), SQLITE_TRANSIENT);
+ }else if( iCol==p->nColumn+2 && pCsr->pExpr ){
+ sqlite3_result_int64(pCtx, pCsr->iLangid);
}else{
+ /* The requested column is either a user column (one that contains
+ ** indexed data), or the language-id column. */
rc = fts3CursorSeek(0, pCsr);
+
if( rc==SQLITE_OK ){
- sqlite3_result_value(pContext, sqlite3_column_value(pCsr->pStmt, iCol+1));
+ if( iCol==p->nColumn+2 ){
+ int iLangid = 0;
+ if( p->zLanguageid ){
+ iLangid = sqlite3_column_int(pCsr->pStmt, p->nColumn+1);
+ }
+ sqlite3_result_int(pCtx, iLangid);
+ }else if( sqlite3_data_count(pCsr->pStmt)>(iCol+1) ){
+ sqlite3_result_value(pCtx, sqlite3_column_value(pCsr->pStmt, iCol+1));
+ }
}
}
@@ -114690,8 +120809,42 @@ static int fts3UpdateMethod(
** hash-table to the database.
*/
static int fts3SyncMethod(sqlite3_vtab *pVtab){
- int rc = sqlite3Fts3PendingTermsFlush((Fts3Table *)pVtab);
- sqlite3Fts3SegmentsClose((Fts3Table *)pVtab);
+
+ /* Following an incremental-merge operation, assuming that the input
+ ** segments are not completely consumed (the usual case), they are updated
+ ** in place to remove the entries that have already been merged. This
+ ** involves updating the leaf block that contains the smallest unmerged
+ ** entry and each block (if any) between the leaf and the root node. So
+ ** if the height of the input segment b-trees is N, and input segments
+ ** are merged eight at a time, updating the input segments at the end
+ ** of an incremental-merge requires writing (8*(1+N)) blocks. N is usually
+ ** small - often between 0 and 2. So the overhead of the incremental
+ ** merge is somewhere between 8 and 24 blocks. To avoid this overhead
+ ** dwarfing the actual productive work accomplished, the incremental merge
+ ** is only attempted if it will write at least 64 leaf blocks. Hence
+ ** nMinMerge.
+ **
+ ** Of course, updating the input segments also involves deleting a bunch
+ ** of blocks from the segments table. But this is not considered overhead
+ ** as it would also be required by a crisis-merge that used the same input
+ ** segments.
+ */
+ const u32 nMinMerge = 64; /* Minimum amount of incr-merge work to do */
+
+ Fts3Table *p = (Fts3Table*)pVtab;
+ int rc = sqlite3Fts3PendingTermsFlush(p);
+
+ if( rc==SQLITE_OK && p->bAutoincrmerge==1 && p->nLeafAdd>(nMinMerge/16) ){
+ int mxLevel = 0; /* Maximum relative level value in db */
+ int A; /* Incr-merge parameter A */
+
+ rc = sqlite3Fts3MaxLevel(p, &mxLevel);
+ assert( rc==SQLITE_OK || mxLevel==0 );
+ A = p->nLeafAdd * mxLevel;
+ A += (A/2);
+ if( A>(int)nMinMerge ) rc = sqlite3Fts3Incrmerge(p, A, 8);
+ }
+ sqlite3Fts3SegmentsClose(p);
return rc;
}
@@ -114699,13 +120852,14 @@ static int fts3SyncMethod(sqlite3_vtab *pVtab){
** Implementation of xBegin() method. This is a no-op.
*/
static int fts3BeginMethod(sqlite3_vtab *pVtab){
- TESTONLY( Fts3Table *p = (Fts3Table*)pVtab );
+ Fts3Table *p = (Fts3Table*)pVtab;
UNUSED_PARAMETER(pVtab);
assert( p->pSegments==0 );
assert( p->nPendingData==0 );
assert( p->inTransaction!=1 );
TESTONLY( p->inTransaction = 1 );
TESTONLY( p->mxSavepoint = -1; );
+ p->nLeafAdd = 0;
return SQLITE_OK;
}
@@ -114746,7 +120900,7 @@ static int fts3RollbackMethod(sqlite3_vtab *pVtab){
*/
static void fts3ReversePoslist(char *pStart, char **ppPoslist){
char *p = &(*ppPoslist)[-2];
- char c;
+ char c = 0;
while( p>pStart && (c=*p--)==0 );
while( p>pStart && (*p & 0x80) | c ){
@@ -114955,15 +121109,22 @@ static int fts3RenameMethod(
sqlite3 *db = p->db; /* Database connection */
int rc; /* Return Code */
+ /* As it happens, the pending terms table is always empty here. This is
+ ** because an "ALTER TABLE RENAME TABLE" statement inside a transaction
+ ** always opens a savepoint transaction. And the xSavepoint() method
+ ** flushes the pending terms table. But leave the (no-op) call to
+ ** PendingTermsFlush() in in case that changes.
+ */
+ assert( p->nPendingData==0 );
rc = sqlite3Fts3PendingTermsFlush(p);
- if( rc!=SQLITE_OK ){
- return rc;
+
+ if( p->zContentTbl==0 ){
+ fts3DbExec(&rc, db,
+ "ALTER TABLE %Q.'%q_content' RENAME TO '%q_content';",
+ p->zDb, p->zName, zName
+ );
}
- fts3DbExec(&rc, db,
- "ALTER TABLE %Q.'%q_content' RENAME TO '%q_content';",
- p->zDb, p->zName, zName
- );
if( p->bHasDocsize ){
fts3DbExec(&rc, db,
"ALTER TABLE %Q.'%q_docsize' RENAME TO '%q_docsize';",
@@ -114987,13 +121148,28 @@ static int fts3RenameMethod(
return rc;
}
+/*
+** The xSavepoint() method.
+**
+** Flush the contents of the pending-terms table to disk.
+*/
static int fts3SavepointMethod(sqlite3_vtab *pVtab, int iSavepoint){
+ int rc = SQLITE_OK;
UNUSED_PARAMETER(iSavepoint);
assert( ((Fts3Table *)pVtab)->inTransaction );
assert( ((Fts3Table *)pVtab)->mxSavepoint < iSavepoint );
TESTONLY( ((Fts3Table *)pVtab)->mxSavepoint = iSavepoint );
- return fts3SyncMethod(pVtab);
+ if( ((Fts3Table *)pVtab)->bIgnoreSavepoint==0 ){
+ rc = fts3SyncMethod(pVtab);
+ }
+ return rc;
}
+
+/*
+** The xRelease() method.
+**
+** This is a no-op.
+*/
static int fts3ReleaseMethod(sqlite3_vtab *pVtab, int iSavepoint){
TESTONLY( Fts3Table *p = (Fts3Table*)pVtab );
UNUSED_PARAMETER(iSavepoint);
@@ -115003,6 +121179,12 @@ static int fts3ReleaseMethod(sqlite3_vtab *pVtab, int iSavepoint){
TESTONLY( p->mxSavepoint = iSavepoint-1 );
return SQLITE_OK;
}
+
+/*
+** The xRollbackTo() method.
+**
+** Discard the contents of the pending terms table.
+*/
static int fts3RollbackToMethod(sqlite3_vtab *pVtab, int iSavepoint){
Fts3Table *p = (Fts3Table*)pVtab;
UNUSED_PARAMETER(iSavepoint);
@@ -115062,12 +121244,15 @@ static void hashDestroy(void *p){
*/
SQLITE_PRIVATE void sqlite3Fts3SimpleTokenizerModule(sqlite3_tokenizer_module const**ppModule);
SQLITE_PRIVATE void sqlite3Fts3PorterTokenizerModule(sqlite3_tokenizer_module const**ppModule);
+#ifdef SQLITE_ENABLE_FTS4_UNICODE61
+SQLITE_PRIVATE void sqlite3Fts3UnicodeTokenizer(sqlite3_tokenizer_module const**ppModule);
+#endif
#ifdef SQLITE_ENABLE_ICU
SQLITE_PRIVATE void sqlite3Fts3IcuTokenizerModule(sqlite3_tokenizer_module const**ppModule);
#endif
/*
-** Initialise the fts3 extension. If this extension is built as part
+** Initialize the fts3 extension. If this extension is built as part
** of the sqlite library, then this function is called directly by
** SQLite. If fts3 is built as a dynamically loadable extension, this
** function is called by the sqlite3_extension_init() entry point.
@@ -115077,12 +121262,19 @@ SQLITE_PRIVATE int sqlite3Fts3Init(sqlite3 *db){
Fts3Hash *pHash = 0;
const sqlite3_tokenizer_module *pSimple = 0;
const sqlite3_tokenizer_module *pPorter = 0;
+#ifdef SQLITE_ENABLE_FTS4_UNICODE61
+ const sqlite3_tokenizer_module *pUnicode = 0;
+#endif
#ifdef SQLITE_ENABLE_ICU
const sqlite3_tokenizer_module *pIcu = 0;
sqlite3Fts3IcuTokenizerModule(&pIcu);
#endif
+#ifdef SQLITE_ENABLE_FTS4_UNICODE61
+ sqlite3Fts3UnicodeTokenizer(&pUnicode);
+#endif
+
#ifdef SQLITE_TEST
rc = sqlite3Fts3InitTerm(db);
if( rc!=SQLITE_OK ) return rc;
@@ -115094,7 +121286,7 @@ SQLITE_PRIVATE int sqlite3Fts3Init(sqlite3 *db){
sqlite3Fts3SimpleTokenizerModule(&pSimple);
sqlite3Fts3PorterTokenizerModule(&pPorter);
- /* Allocate and initialise the hash-table used to store tokenizers. */
+ /* Allocate and initialize the hash-table used to store tokenizers. */
pHash = sqlite3_malloc(sizeof(Fts3Hash));
if( !pHash ){
rc = SQLITE_NOMEM;
@@ -115106,6 +121298,10 @@ SQLITE_PRIVATE int sqlite3Fts3Init(sqlite3 *db){
if( rc==SQLITE_OK ){
if( sqlite3Fts3HashInsert(pHash, "simple", 7, (void *)pSimple)
|| sqlite3Fts3HashInsert(pHash, "porter", 7, (void *)pPorter)
+
+#ifdef SQLITE_ENABLE_FTS4_UNICODE61
+ || sqlite3Fts3HashInsert(pHash, "unicode61", 10, (void *)pUnicode)
+#endif
#ifdef SQLITE_ENABLE_ICU
|| (pIcu && sqlite3Fts3HashInsert(pHash, "icu", 4, (void *)pIcu))
#endif
@@ -115152,18 +121348,6 @@ SQLITE_PRIVATE int sqlite3Fts3Init(sqlite3 *db){
return rc;
}
-#if !SQLITE_CORE
-SQLITE_API int sqlite3_extension_init(
- sqlite3 *db,
- char **pzErrMsg,
- const sqlite3_api_routines *pApi
-){
- SQLITE_EXTENSION_INIT2(pApi)
- return sqlite3Fts3Init(db);
-}
-#endif
-
-
/*
** Allocate an Fts3MultiSegReader for each token in the expression headed
** by pExpr.
@@ -115180,11 +121364,11 @@ SQLITE_API int sqlite3_extension_init(
** doclist and then traversed.
*/
static void fts3EvalAllocateReaders(
- Fts3Cursor *pCsr,
- Fts3Expr *pExpr,
+ Fts3Cursor *pCsr, /* FTS cursor handle */
+ Fts3Expr *pExpr, /* Allocate readers for this expression */
int *pnToken, /* OUT: Total number of tokens in phrase. */
int *pnOr, /* OUT: Total number of OR nodes in expr. */
- int *pRc
+ int *pRc /* IN/OUT: Error code */
){
if( pExpr && SQLITE_OK==*pRc ){
if( pExpr->eType==FTSQUERY_PHRASE ){
@@ -115193,7 +121377,7 @@ static void fts3EvalAllocateReaders(
*pnToken += nToken;
for(i=0; i<nToken; i++){
Fts3PhraseToken *pToken = &pExpr->pPhrase->aToken[i];
- int rc = sqlite3Fts3TermSegReaderCursor(pCsr,
+ int rc = fts3TermSegReaderCursor(pCsr,
pToken->z, pToken->n, pToken->isPrefix, &pToken->pSegcsr
);
if( rc!=SQLITE_OK ){
@@ -115211,12 +121395,20 @@ static void fts3EvalAllocateReaders(
}
}
+/*
+** Arguments pList/nList contain the doclist for token iToken of phrase p.
+** It is merged into the main doclist stored in p->doclist.aAll/nAll.
+**
+** This function assumes that pList points to a buffer allocated using
+** sqlite3_malloc(). This function takes responsibility for eventually
+** freeing the buffer.
+*/
static void fts3EvalPhraseMergeToken(
- Fts3Table *pTab,
- Fts3Phrase *p,
- int iToken,
- char *pList,
- int nList
+ Fts3Table *pTab, /* FTS Table pointer */
+ Fts3Phrase *p, /* Phrase to merge pList/nList into */
+ int iToken, /* Token pList/nList corresponds to */
+ char *pList, /* Pointer to doclist */
+ int nList /* Number of bytes in pList */
){
assert( iToken!=p->iDoclistToken );
@@ -115265,9 +121457,15 @@ static void fts3EvalPhraseMergeToken(
if( iToken>p->iDoclistToken ) p->iDoclistToken = iToken;
}
+/*
+** Load the doclist for phrase p into p->doclist.aAll/nAll. The loaded doclist
+** does not take deferred tokens into account.
+**
+** SQLITE_OK is returned if no error occurs, otherwise an SQLite error code.
+*/
static int fts3EvalPhraseLoad(
- Fts3Cursor *pCsr,
- Fts3Phrase *p
+ Fts3Cursor *pCsr, /* FTS Cursor handle */
+ Fts3Phrase *p /* Phrase object */
){
Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab;
int iToken;
@@ -115280,7 +121478,7 @@ static int fts3EvalPhraseLoad(
if( pToken->pSegcsr ){
int nThis = 0;
char *pThis = 0;
- rc = fts3TermSelect(pTab, pToken, p->iColumn, 1, &nThis, &pThis);
+ rc = fts3TermSelect(pTab, pToken, p->iColumn, &nThis, &pThis);
if( rc==SQLITE_OK ){
fts3EvalPhraseMergeToken(pTab, p, iToken, pThis, nThis);
}
@@ -115291,25 +121489,32 @@ static int fts3EvalPhraseLoad(
return rc;
}
+/*
+** This function is called on each phrase after the position lists for
+** any deferred tokens have been loaded into memory. It updates the phrases
+** current position list to include only those positions that are really
+** instances of the phrase (after considering deferred tokens). If this
+** means that the phrase does not appear in the current row, doclist.pList
+** and doclist.nList are both zeroed.
+**
+** SQLITE_OK is returned if no error occurs, otherwise an SQLite error code.
+*/
static int fts3EvalDeferredPhrase(Fts3Cursor *pCsr, Fts3Phrase *pPhrase){
- int iToken;
- int rc = SQLITE_OK;
-
- int nMaxUndeferred = pPhrase->iDoclistToken;
- char *aPoslist = 0;
- int nPoslist = 0;
- int iPrev = -1;
+ int iToken; /* Used to iterate through phrase tokens */
+ char *aPoslist = 0; /* Position list for deferred tokens */
+ int nPoslist = 0; /* Number of bytes in aPoslist */
+ int iPrev = -1; /* Token number of previous deferred token */
assert( pPhrase->doclist.bFreeList==0 );
- for(iToken=0; rc==SQLITE_OK && iToken<pPhrase->nToken; iToken++){
+ for(iToken=0; iToken<pPhrase->nToken; iToken++){
Fts3PhraseToken *pToken = &pPhrase->aToken[iToken];
Fts3DeferredToken *pDeferred = pToken->pDeferred;
if( pDeferred ){
char *pList;
int nList;
- rc = sqlite3Fts3DeferredTokenList(pDeferred, &pList, &nList);
+ int rc = sqlite3Fts3DeferredTokenList(pDeferred, &pList, &nList);
if( rc!=SQLITE_OK ) return rc;
if( pList==0 ){
@@ -115331,7 +121536,7 @@ static int fts3EvalDeferredPhrase(Fts3Cursor *pCsr, Fts3Phrase *pPhrase){
fts3PoslistPhraseMerge(&aOut, iToken-iPrev, 0, 1, &p1, &p2);
sqlite3_free(aPoslist);
aPoslist = pList;
- nPoslist = aOut - aPoslist;
+ nPoslist = (int)(aOut - aPoslist);
if( nPoslist==0 ){
sqlite3_free(aPoslist);
pPhrase->doclist.pList = 0;
@@ -115344,6 +121549,7 @@ static int fts3EvalDeferredPhrase(Fts3Cursor *pCsr, Fts3Phrase *pPhrase){
}
if( iPrev>=0 ){
+ int nMaxUndeferred = pPhrase->iDoclistToken;
if( nMaxUndeferred<0 ){
pPhrase->doclist.pList = aPoslist;
pPhrase->doclist.nList = nPoslist;
@@ -115374,7 +121580,7 @@ static int fts3EvalDeferredPhrase(Fts3Cursor *pCsr, Fts3Phrase *pPhrase){
pPhrase->doclist.pList = aOut;
if( fts3PoslistPhraseMerge(&aOut, nDistance, 0, 1, &p1, &p2) ){
pPhrase->doclist.bFreeList = 1;
- pPhrase->doclist.nList = (aOut - pPhrase->doclist.pList);
+ pPhrase->doclist.nList = (int)(aOut - pPhrase->doclist.pList);
}else{
sqlite3_free(aOut);
pPhrase->doclist.pList = 0;
@@ -115392,9 +121598,15 @@ static int fts3EvalDeferredPhrase(Fts3Cursor *pCsr, Fts3Phrase *pPhrase){
** expression to initialize the mechanism for returning rows. Once this
** function has been called successfully on an Fts3Phrase, it may be
** used with fts3EvalPhraseNext() to iterate through the matching docids.
+**
+** If parameter bOptOk is true, then the phrase may (or may not) use the
+** incremental loading strategy. Otherwise, the entire doclist is loaded into
+** memory within this call.
+**
+** SQLITE_OK is returned if no error occurs, otherwise an SQLite error code.
*/
static int fts3EvalPhraseStart(Fts3Cursor *pCsr, int bOptOk, Fts3Phrase *p){
- int rc;
+ int rc; /* Error code */
Fts3PhraseToken *pFirst = &p->aToken[0];
Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab;
@@ -115403,6 +121615,7 @@ static int fts3EvalPhraseStart(Fts3Cursor *pCsr, int bOptOk, Fts3Phrase *p){
&& p->nToken==1
&& pFirst->pSegcsr
&& pFirst->pSegcsr->bLookup
+ && pFirst->bFirst==0
){
/* Use the incremental approach. */
int iCol = (p->iColumn >= pTab->nColumn ? -1 : p->iColumn);
@@ -115422,7 +121635,13 @@ static int fts3EvalPhraseStart(Fts3Cursor *pCsr, int bOptOk, Fts3Phrase *p){
/*
** This function is used to iterate backwards (from the end to start)
-** through doclists.
+** through doclists. It is used by this module to iterate through phrase
+** doclists in reverse and by the fts3_write.c module to iterate through
+** pending-terms lists when writing to databases with "order=desc".
+**
+** The doclist may be sorted in ascending (parameter bDescIdx==0) or
+** descending (parameter bDescIdx==1) order of docid. Regardless, this
+** function iterates from the end of the doclist to the beginning.
*/
SQLITE_PRIVATE void sqlite3Fts3DoclistPrev(
int bDescIdx, /* True if the doclist is desc */
@@ -115430,7 +121649,7 @@ SQLITE_PRIVATE void sqlite3Fts3DoclistPrev(
int nDoclist, /* Length of aDoclist in bytes */
char **ppIter, /* IN/OUT: Iterator pointer */
sqlite3_int64 *piDocid, /* IN/OUT: Docid pointer */
- int *pnList, /* IN/OUT: List length pointer */
+ int *pnList, /* OUT: List length pointer */
u8 *pbEof /* OUT: End-of-file flag */
){
char *p = *ppIter;
@@ -115457,7 +121676,7 @@ SQLITE_PRIVATE void sqlite3Fts3DoclistPrev(
iMul = (bDescIdx ? -1 : 1);
}
- *pnList = pEnd - pNext;
+ *pnList = (int)(pEnd - pNext);
*ppIter = pNext;
*piDocid = iDocid;
}else{
@@ -115471,13 +121690,48 @@ SQLITE_PRIVATE void sqlite3Fts3DoclistPrev(
}else{
char *pSave = p;
fts3ReversePoslist(aDoclist, &p);
- *pnList = (pSave - p);
+ *pnList = (int)(pSave - p);
}
*ppIter = p;
}
}
/*
+** Iterate forwards through a doclist.
+*/
+SQLITE_PRIVATE void sqlite3Fts3DoclistNext(
+ int bDescIdx, /* True if the doclist is desc */
+ char *aDoclist, /* Pointer to entire doclist */
+ int nDoclist, /* Length of aDoclist in bytes */
+ char **ppIter, /* IN/OUT: Iterator pointer */
+ sqlite3_int64 *piDocid, /* IN/OUT: Docid pointer */
+ u8 *pbEof /* OUT: End-of-file flag */
+){
+ char *p = *ppIter;
+
+ assert( nDoclist>0 );
+ assert( *pbEof==0 );
+ assert( p || *piDocid==0 );
+ assert( !p || (p>=aDoclist && p<=&aDoclist[nDoclist]) );
+
+ if( p==0 ){
+ p = aDoclist;
+ p += sqlite3Fts3GetVarint(p, piDocid);
+ }else{
+ fts3PoslistCopy(0, &p);
+ if( p>=&aDoclist[nDoclist] ){
+ *pbEof = 1;
+ }else{
+ sqlite3_int64 iVar;
+ p += sqlite3Fts3GetVarint(p, &iVar);
+ *piDocid += ((bDescIdx ? -1 : 1) * iVar);
+ }
+ }
+
+ *ppIter = p;
+}
+
+/*
** Attempt to move the phrase iterator to point to the next matching docid.
** If an error occurs, return an SQLite error code. Otherwise, return
** SQLITE_OK.
@@ -115487,9 +121741,9 @@ SQLITE_PRIVATE void sqlite3Fts3DoclistPrev(
** successfully advanced, *pbEof is set to 0.
*/
static int fts3EvalPhraseNext(
- Fts3Cursor *pCsr,
- Fts3Phrase *p,
- u8 *pbEof
+ Fts3Cursor *pCsr, /* FTS Cursor handle */
+ Fts3Phrase *p, /* Phrase object to advance to next docid */
+ u8 *pbEof /* OUT: Set to 1 if EOF */
){
int rc = SQLITE_OK;
Fts3Doclist *pDL = &p->doclist;
@@ -115531,14 +121785,14 @@ static int fts3EvalPhraseNext(
}
pDL->pList = pIter;
fts3PoslistCopy(0, &pIter);
- pDL->nList = (pIter - pDL->pList);
+ pDL->nList = (int)(pIter - pDL->pList);
/* pIter now points just past the 0x00 that terminates the position-
** list for document pDL->iDocid. However, if this position-list was
- ** edited in place by fts3EvalNearTrim2(), then pIter may not actually
+ ** edited in place by fts3EvalNearTrim(), then pIter may not actually
** point to the start of the next docid value. The following line deals
** with this case by advancing pIter past the zero-padding added by
- ** fts3EvalNearTrim2(). */
+ ** fts3EvalNearTrim(). */
while( pIter<pEnd && *pIter==0 ) pIter++;
pDL->pNextDocid = pIter;
@@ -115550,11 +121804,27 @@ static int fts3EvalPhraseNext(
return rc;
}
+/*
+**
+** If *pRc is not SQLITE_OK when this function is called, it is a no-op.
+** Otherwise, fts3EvalPhraseStart() is called on all phrases within the
+** expression. Also the Fts3Expr.bDeferred variable is set to true for any
+** expressions for which all descendent tokens are deferred.
+**
+** If parameter bOptOk is zero, then it is guaranteed that the
+** Fts3Phrase.doclist.aAll/nAll variables contain the entire doclist for
+** each phrase in the expression (subject to deferred token processing).
+** Or, if bOptOk is non-zero, then one or more tokens within the expression
+** may be loaded incrementally, meaning doclist.aAll/nAll is not available.
+**
+** If an error occurs within this function, *pRc is set to an SQLite error
+** code before returning.
+*/
static void fts3EvalStartReaders(
- Fts3Cursor *pCsr,
- Fts3Expr *pExpr,
- int bOptOk,
- int *pRc
+ Fts3Cursor *pCsr, /* FTS Cursor handle */
+ Fts3Expr *pExpr, /* Expression to initialize phrases in */
+ int bOptOk, /* True to enable incremental loading */
+ int *pRc /* IN/OUT: Error code */
){
if( pExpr && SQLITE_OK==*pRc ){
if( pExpr->eType==FTSQUERY_PHRASE ){
@@ -115573,25 +121843,44 @@ static void fts3EvalStartReaders(
}
}
+/*
+** An array of the following structures is assembled as part of the process
+** of selecting tokens to defer before the query starts executing (as part
+** of the xFilter() method). There is one element in the array for each
+** token in the FTS expression.
+**
+** Tokens are divided into AND/NEAR clusters. All tokens in a cluster belong
+** to phrases that are connected only by AND and NEAR operators (not OR or
+** NOT). When determining tokens to defer, each AND/NEAR cluster is considered
+** separately. The root of a tokens AND/NEAR cluster is stored in
+** Fts3TokenAndCost.pRoot.
+*/
typedef struct Fts3TokenAndCost Fts3TokenAndCost;
struct Fts3TokenAndCost {
Fts3Phrase *pPhrase; /* The phrase the token belongs to */
int iToken; /* Position of token in phrase */
Fts3PhraseToken *pToken; /* The token itself */
- Fts3Expr *pRoot;
- int nOvfl;
+ Fts3Expr *pRoot; /* Root of NEAR/AND cluster */
+ int nOvfl; /* Number of overflow pages to load doclist */
int iCol; /* The column the token must match */
};
+/*
+** This function is used to populate an allocated Fts3TokenAndCost array.
+**
+** If *pRc is not SQLITE_OK when this function is called, it is a no-op.
+** Otherwise, if an error occurs during execution, *pRc is set to an
+** SQLite error code.
+*/
static void fts3EvalTokenCosts(
- Fts3Cursor *pCsr,
- Fts3Expr *pRoot,
- Fts3Expr *pExpr,
- Fts3TokenAndCost **ppTC,
- Fts3Expr ***ppOr,
- int *pRc
+ Fts3Cursor *pCsr, /* FTS Cursor handle */
+ Fts3Expr *pRoot, /* Root of current AND/NEAR cluster */
+ Fts3Expr *pExpr, /* Expression to consider */
+ Fts3TokenAndCost **ppTC, /* Write new entries to *(*ppTC)++ */
+ Fts3Expr ***ppOr, /* Write new OR root to *(*ppOr)++ */
+ int *pRc /* IN/OUT: Error code */
){
- if( *pRc==SQLITE_OK && pExpr ){
+ if( *pRc==SQLITE_OK ){
if( pExpr->eType==FTSQUERY_PHRASE ){
Fts3Phrase *pPhrase = pExpr->pPhrase;
int i;
@@ -115605,6 +121894,11 @@ static void fts3EvalTokenCosts(
*pRc = sqlite3Fts3MsrOvfl(pCsr, pTC->pToken->pSegcsr, &pTC->nOvfl);
}
}else if( pExpr->eType!=FTSQUERY_NOT ){
+ assert( pExpr->eType==FTSQUERY_OR
+ || pExpr->eType==FTSQUERY_AND
+ || pExpr->eType==FTSQUERY_NEAR
+ );
+ assert( pExpr->pLeft && pExpr->pRight );
if( pExpr->eType==FTSQUERY_OR ){
pRoot = pExpr->pLeft;
**ppOr = pRoot;
@@ -115621,19 +121915,30 @@ static void fts3EvalTokenCosts(
}
}
+/*
+** Determine the average document (row) size in pages. If successful,
+** write this value to *pnPage and return SQLITE_OK. Otherwise, return
+** an SQLite error code.
+**
+** The average document size in pages is calculated by first calculating
+** determining the average size in bytes, B. If B is less than the amount
+** of data that will fit on a single leaf page of an intkey table in
+** this database, then the average docsize is 1. Otherwise, it is 1 plus
+** the number of overflow pages consumed by a record B bytes in size.
+*/
static int fts3EvalAverageDocsize(Fts3Cursor *pCsr, int *pnPage){
if( pCsr->nRowAvg==0 ){
/* The average document size, which is required to calculate the cost
- ** of each doclist, has not yet been determined. Read the required
- ** data from the %_stat table to calculate it.
- **
- ** Entry 0 of the %_stat table is a blob containing (nCol+1) FTS3
- ** varints, where nCol is the number of columns in the FTS3 table.
- ** The first varint is the number of documents currently stored in
- ** the table. The following nCol varints contain the total amount of
- ** data stored in all rows of each column of the table, from left
- ** to right.
- */
+ ** of each doclist, has not yet been determined. Read the required
+ ** data from the %_stat table to calculate it.
+ **
+ ** Entry 0 of the %_stat table is a blob containing (nCol+1) FTS3
+ ** varints, where nCol is the number of columns in the FTS3 table.
+ ** The first varint is the number of documents currently stored in
+ ** the table. The following nCol varints contain the total amount of
+ ** data stored in all rows of each column of the table, from left
+ ** to right.
+ */
int rc;
Fts3Table *p = (Fts3Table*)pCsr->base.pVtab;
sqlite3_stmt *pStmt;
@@ -115654,7 +121959,7 @@ static int fts3EvalAverageDocsize(Fts3Cursor *pCsr, int *pnPage){
}
if( nDoc==0 || nByte==0 ){
sqlite3_reset(pStmt);
- return SQLITE_CORRUPT_VTAB;
+ return FTS_CORRUPT_VTAB;
}
pCsr->nDoc = nDoc;
@@ -115668,68 +121973,130 @@ static int fts3EvalAverageDocsize(Fts3Cursor *pCsr, int *pnPage){
return SQLITE_OK;
}
+/*
+** This function is called to select the tokens (if any) that will be
+** deferred. The array aTC[] has already been populated when this is
+** called.
+**
+** This function is called once for each AND/NEAR cluster in the
+** expression. Each invocation determines which tokens to defer within
+** the cluster with root node pRoot. See comments above the definition
+** of struct Fts3TokenAndCost for more details.
+**
+** If no error occurs, SQLITE_OK is returned and sqlite3Fts3DeferToken()
+** called on each token to defer. Otherwise, an SQLite error code is
+** returned.
+*/
static int fts3EvalSelectDeferred(
- Fts3Cursor *pCsr,
- Fts3Expr *pRoot,
- Fts3TokenAndCost *aTC,
- int nTC
+ Fts3Cursor *pCsr, /* FTS Cursor handle */
+ Fts3Expr *pRoot, /* Consider tokens with this root node */
+ Fts3TokenAndCost *aTC, /* Array of expression tokens and costs */
+ int nTC /* Number of entries in aTC[] */
){
- int nDocSize = 0;
- int nDocEst = 0;
- int rc = SQLITE_OK;
Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab;
- int ii;
-
- int nOvfl = 0;
- int nTerm = 0;
+ int nDocSize = 0; /* Number of pages per doc loaded */
+ int rc = SQLITE_OK; /* Return code */
+ int ii; /* Iterator variable for various purposes */
+ int nOvfl = 0; /* Total overflow pages used by doclists */
+ int nToken = 0; /* Total number of tokens in cluster */
+
+ int nMinEst = 0; /* The minimum count for any phrase so far. */
+ int nLoad4 = 1; /* (Phrases that will be loaded)^4. */
+
+ /* Tokens are never deferred for FTS tables created using the content=xxx
+ ** option. The reason being that it is not guaranteed that the content
+ ** table actually contains the same data as the index. To prevent this from
+ ** causing any problems, the deferred token optimization is completely
+ ** disabled for content=xxx tables. */
+ if( pTab->zContentTbl ){
+ return SQLITE_OK;
+ }
+ /* Count the tokens in this AND/NEAR cluster. If none of the doclists
+ ** associated with the tokens spill onto overflow pages, or if there is
+ ** only 1 token, exit early. No tokens to defer in this case. */
for(ii=0; ii<nTC; ii++){
if( aTC[ii].pRoot==pRoot ){
nOvfl += aTC[ii].nOvfl;
- nTerm++;
+ nToken++;
}
}
- if( nOvfl==0 || nTerm<2 ) return SQLITE_OK;
+ if( nOvfl==0 || nToken<2 ) return SQLITE_OK;
+ /* Obtain the average docsize (in pages). */
rc = fts3EvalAverageDocsize(pCsr, &nDocSize);
+ assert( rc!=SQLITE_OK || nDocSize>0 );
- for(ii=0; ii<nTerm && rc==SQLITE_OK; ii++){
- int jj;
- Fts3TokenAndCost *pTC = 0;
- for(jj=0; jj<nTC; jj++){
- if( aTC[jj].pToken && aTC[jj].pRoot==pRoot
- && (!pTC || aTC[jj].nOvfl<pTC->nOvfl)
+ /* Iterate through all tokens in this AND/NEAR cluster, in ascending order
+ ** of the number of overflow pages that will be loaded by the pager layer
+ ** to retrieve the entire doclist for the token from the full-text index.
+ ** Load the doclists for tokens that are either:
+ **
+ ** a. The cheapest token in the entire query (i.e. the one visited by the
+ ** first iteration of this loop), or
+ **
+ ** b. Part of a multi-token phrase.
+ **
+ ** After each token doclist is loaded, merge it with the others from the
+ ** same phrase and count the number of documents that the merged doclist
+ ** contains. Set variable "nMinEst" to the smallest number of documents in
+ ** any phrase doclist for which 1 or more token doclists have been loaded.
+ ** Let nOther be the number of other phrases for which it is certain that
+ ** one or more tokens will not be deferred.
+ **
+ ** Then, for each token, defer it if loading the doclist would result in
+ ** loading N or more overflow pages into memory, where N is computed as:
+ **
+ ** (nMinEst + 4^nOther - 1) / (4^nOther)
+ */
+ for(ii=0; ii<nToken && rc==SQLITE_OK; ii++){
+ int iTC; /* Used to iterate through aTC[] array. */
+ Fts3TokenAndCost *pTC = 0; /* Set to cheapest remaining token. */
+
+ /* Set pTC to point to the cheapest remaining token. */
+ for(iTC=0; iTC<nTC; iTC++){
+ if( aTC[iTC].pToken && aTC[iTC].pRoot==pRoot
+ && (!pTC || aTC[iTC].nOvfl<pTC->nOvfl)
){
- pTC = &aTC[jj];
+ pTC = &aTC[iTC];
}
}
assert( pTC );
- /* At this point pTC points to the cheapest remaining token. */
- if( ii==0 ){
- if( pTC->nOvfl ){
- nDocEst = (pTC->nOvfl * pTab->nPgsz + pTab->nPgsz) / 10;
- }else{
+ if( ii && pTC->nOvfl>=((nMinEst+(nLoad4/4)-1)/(nLoad4/4))*nDocSize ){
+ /* The number of overflow pages to load for this (and therefore all
+ ** subsequent) tokens is greater than the estimated number of pages
+ ** that will be loaded if all subsequent tokens are deferred.
+ */
+ Fts3PhraseToken *pToken = pTC->pToken;
+ rc = sqlite3Fts3DeferToken(pCsr, pToken, pTC->iCol);
+ fts3SegReaderCursorFree(pToken->pSegcsr);
+ pToken->pSegcsr = 0;
+ }else{
+ /* Set nLoad4 to the value of (4^nOther) for the next iteration of the
+ ** for-loop. Except, limit the value to 2^24 to prevent it from
+ ** overflowing the 32-bit integer it is stored in. */
+ if( ii<12 ) nLoad4 = nLoad4*4;
+
+ if( ii==0 || pTC->pPhrase->nToken>1 ){
+ /* Either this is the cheapest token in the entire query, or it is
+ ** part of a multi-token phrase. Either way, the entire doclist will
+ ** (eventually) be loaded into memory. It may as well be now. */
Fts3PhraseToken *pToken = pTC->pToken;
int nList = 0;
char *pList = 0;
- rc = fts3TermSelect(pTab, pToken, pTC->iCol, 1, &nList, &pList);
+ rc = fts3TermSelect(pTab, pToken, pTC->iCol, &nList, &pList);
assert( rc==SQLITE_OK || pList==0 );
-
if( rc==SQLITE_OK ){
- nDocEst = fts3DoclistCountDocids(1, pList, nList);
+ int nCount;
fts3EvalPhraseMergeToken(pTab, pTC->pPhrase, pTC->iToken,pList,nList);
+ nCount = fts3DoclistCountDocids(
+ pTC->pPhrase->doclist.aAll, pTC->pPhrase->doclist.nAll
+ );
+ if( ii==0 || nCount<nMinEst ) nMinEst = nCount;
}
}
- }else{
- if( pTC->nOvfl>=(nDocEst*nDocSize) ){
- Fts3PhraseToken *pToken = pTC->pToken;
- rc = sqlite3Fts3DeferToken(pCsr, pToken, pTC->iCol);
- fts3SegReaderCursorFree(pToken->pSegcsr);
- pToken->pSegcsr = 0;
- }
- nDocEst = 1 + (nDocEst/4);
}
pTC->pToken = 0;
}
@@ -115737,36 +122104,30 @@ static int fts3EvalSelectDeferred(
return rc;
}
-SQLITE_PRIVATE int sqlite3Fts3EvalStart(Fts3Cursor *pCsr, Fts3Expr *pExpr, int bOptOk){
+/*
+** This function is called from within the xFilter method. It initializes
+** the full-text query currently stored in pCsr->pExpr. To iterate through
+** the results of a query, the caller does:
+**
+** fts3EvalStart(pCsr);
+** while( 1 ){
+** fts3EvalNext(pCsr);
+** if( pCsr->bEof ) break;
+** ... return row pCsr->iPrevId to the caller ...
+** }
+*/
+static int fts3EvalStart(Fts3Cursor *pCsr){
Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab;
int rc = SQLITE_OK;
int nToken = 0;
int nOr = 0;
/* Allocate a MultiSegReader for each token in the expression. */
- fts3EvalAllocateReaders(pCsr, pExpr, &nToken, &nOr, &rc);
-
- /* Call fts3EvalPhraseStart() on all phrases in the expression. TODO:
- ** This call will eventually also be responsible for determining which
- ** tokens are 'deferred' until the document text is loaded into memory.
- **
- ** Each token in each phrase is dealt with using one of the following
- ** three strategies:
- **
- ** 1. Entire doclist loaded into memory as part of the
- ** fts3EvalStartReaders() call.
- **
- ** 2. Doclist loaded into memory incrementally, as part of each
- ** sqlite3Fts3EvalNext() call.
- **
- ** 3. Token doclist is never loaded. Instead, documents are loaded into
- ** memory and scanned for the token as part of the sqlite3Fts3EvalNext()
- ** call. This is known as a "deferred" token.
- */
+ fts3EvalAllocateReaders(pCsr, pCsr->pExpr, &nToken, &nOr, &rc);
- /* If bOptOk is true, check if there are any tokens that should be deferred.
- */
- if( rc==SQLITE_OK && bOptOk && nToken>1 && pTab->bHasStat ){
+ /* Determine which, if any, tokens in the expression should be deferred. */
+#ifndef SQLITE_DISABLE_FTS4_DEFERRED
+ if( rc==SQLITE_OK && nToken>1 && pTab->bFts4 ){
Fts3TokenAndCost *aTC;
Fts3Expr **apOr;
aTC = (Fts3TokenAndCost *)sqlite3_malloc(
@@ -115782,9 +122143,9 @@ SQLITE_PRIVATE int sqlite3Fts3EvalStart(Fts3Cursor *pCsr, Fts3Expr *pExpr, int b
Fts3TokenAndCost *pTC = aTC;
Fts3Expr **ppOr = apOr;
- fts3EvalTokenCosts(pCsr, 0, pExpr, &pTC, &ppOr, &rc);
- nToken = pTC-aTC;
- nOr = ppOr-apOr;
+ fts3EvalTokenCosts(pCsr, 0, pCsr->pExpr, &pTC, &ppOr, &rc);
+ nToken = (int)(pTC-aTC);
+ nOr = (int)(ppOr-apOr);
if( rc==SQLITE_OK ){
rc = fts3EvalSelectDeferred(pCsr, 0, aTC, nToken);
@@ -115796,12 +122157,16 @@ SQLITE_PRIVATE int sqlite3Fts3EvalStart(Fts3Cursor *pCsr, Fts3Expr *pExpr, int b
sqlite3_free(aTC);
}
}
+#endif
- fts3EvalStartReaders(pCsr, pExpr, bOptOk, &rc);
+ fts3EvalStartReaders(pCsr, pCsr->pExpr, 1, &rc);
return rc;
}
-static void fts3EvalZeroPoslist(Fts3Phrase *pPhrase){
+/*
+** Invalidate the current position list for phrase pPhrase.
+*/
+static void fts3EvalInvalidatePoslist(Fts3Phrase *pPhrase){
if( pPhrase->doclist.bFreeList ){
sqlite3_free(pPhrase->doclist.pList);
}
@@ -115810,8 +122175,30 @@ static void fts3EvalZeroPoslist(Fts3Phrase *pPhrase){
pPhrase->doclist.bFreeList = 0;
}
-static int fts3EvalNearTrim2(
- int nNear,
+/*
+** This function is called to edit the position list associated with
+** the phrase object passed as the fifth argument according to a NEAR
+** condition. For example:
+**
+** abc NEAR/5 "def ghi"
+**
+** Parameter nNear is passed the NEAR distance of the expression (5 in
+** the example above). When this function is called, *paPoslist points to
+** the position list, and *pnToken is the number of phrase tokens in, the
+** phrase on the other side of the NEAR operator to pPhrase. For example,
+** if pPhrase refers to the "def ghi" phrase, then *paPoslist points to
+** the position list associated with phrase "abc".
+**
+** All positions in the pPhrase position list that are not sufficiently
+** close to a position in the *paPoslist position list are removed. If this
+** leaves 0 positions, zero is returned. Otherwise, non-zero.
+**
+** Before returning, *paPoslist is set to point to the position lsit
+** associated with pPhrase. And *pnToken is set to the number of tokens in
+** pPhrase.
+*/
+static int fts3EvalNearTrim(
+ int nNear, /* NEAR distance. As in "NEAR/nNear". */
char *aTmp, /* Temporary space to use */
char **paPoslist, /* IN/OUT: Position list */
int *pnToken, /* IN/OUT: Tokens in phrase of *paPoslist */
@@ -115831,7 +122218,7 @@ static int fts3EvalNearTrim2(
&pOut, aTmp, nParam1, nParam2, paPoslist, &p2
);
if( res ){
- nNew = (pOut - pPhrase->doclist.pList) - 1;
+ nNew = (int)(pOut - pPhrase->doclist.pList) - 1;
assert( pPhrase->doclist.pList[nNew]=='\0' );
assert( nNew<=pPhrase->doclist.nList && nNew>0 );
memset(&pPhrase->doclist.pList[nNew], 0, pPhrase->doclist.nList - nNew);
@@ -115843,89 +122230,54 @@ static int fts3EvalNearTrim2(
return res;
}
-static int fts3EvalNearTest(Fts3Expr *pExpr, int *pRc){
- int res = 1;
-
- /* The following block runs if pExpr is the root of a NEAR query.
- ** For example, the query:
- **
- ** "w" NEAR "x" NEAR "y" NEAR "z"
- **
- ** which is represented in tree form as:
- **
- ** |
- ** +--NEAR--+ <-- root of NEAR query
- ** | |
- ** +--NEAR--+ "z"
- ** | |
- ** +--NEAR--+ "y"
- ** | |
- ** "w" "x"
- **
- ** The right-hand child of a NEAR node is always a phrase. The
- ** left-hand child may be either a phrase or a NEAR node. There are
- ** no exceptions to this.
- */
- if( *pRc==SQLITE_OK
- && pExpr->eType==FTSQUERY_NEAR
- && pExpr->bEof==0
- && (pExpr->pParent==0 || pExpr->pParent->eType!=FTSQUERY_NEAR)
- ){
- Fts3Expr *p;
- int nTmp = 0; /* Bytes of temp space */
- char *aTmp; /* Temp space for PoslistNearMerge() */
-
- /* Allocate temporary working space. */
- for(p=pExpr; p->pLeft; p=p->pLeft){
- nTmp += p->pRight->pPhrase->doclist.nList;
- }
- nTmp += p->pPhrase->doclist.nList;
- aTmp = sqlite3_malloc(nTmp*2);
- if( !aTmp ){
- *pRc = SQLITE_NOMEM;
- res = 0;
- }else{
- char *aPoslist = p->pPhrase->doclist.pList;
- int nToken = p->pPhrase->nToken;
-
- for(p=p->pParent;res && p && p->eType==FTSQUERY_NEAR; p=p->pParent){
- Fts3Phrase *pPhrase = p->pRight->pPhrase;
- int nNear = p->nNear;
- res = fts3EvalNearTrim2(nNear, aTmp, &aPoslist, &nToken, pPhrase);
- }
-
- aPoslist = pExpr->pRight->pPhrase->doclist.pList;
- nToken = pExpr->pRight->pPhrase->nToken;
- for(p=pExpr->pLeft; p && res; p=p->pLeft){
- int nNear = p->pParent->nNear;
- Fts3Phrase *pPhrase = (
- p->eType==FTSQUERY_NEAR ? p->pRight->pPhrase : p->pPhrase
- );
- res = fts3EvalNearTrim2(nNear, aTmp, &aPoslist, &nToken, pPhrase);
- }
- }
-
- sqlite3_free(aTmp);
- }
-
- return res;
-}
-
/*
-** This macro is used by the fts3EvalNext() function. The two arguments are
-** 64-bit docid values. If the current query is "ORDER BY docid ASC", then
-** the macro returns (i1 - i2). Or if it is "ORDER BY docid DESC", then
-** it returns (i2 - i1). This allows the same code to be used for merging
-** doclists in ascending or descending order.
+** This function is a no-op if *pRc is other than SQLITE_OK when it is called.
+** Otherwise, it advances the expression passed as the second argument to
+** point to the next matching row in the database. Expressions iterate through
+** matching rows in docid order. Ascending order if Fts3Cursor.bDesc is zero,
+** or descending if it is non-zero.
+**
+** If an error occurs, *pRc is set to an SQLite error code. Otherwise, if
+** successful, the following variables in pExpr are set:
+**
+** Fts3Expr.bEof (non-zero if EOF - there is no next row)
+** Fts3Expr.iDocid (valid if bEof==0. The docid of the next row)
+**
+** If the expression is of type FTSQUERY_PHRASE, and the expression is not
+** at EOF, then the following variables are populated with the position list
+** for the phrase for the visited row:
+**
+** FTs3Expr.pPhrase->doclist.nList (length of pList in bytes)
+** FTs3Expr.pPhrase->doclist.pList (pointer to position list)
+**
+** It says above that this function advances the expression to the next
+** matching row. This is usually true, but there are the following exceptions:
+**
+** 1. Deferred tokens are not taken into account. If a phrase consists
+** entirely of deferred tokens, it is assumed to match every row in
+** the db. In this case the position-list is not populated at all.
+**
+** Or, if a phrase contains one or more deferred tokens and one or
+** more non-deferred tokens, then the expression is advanced to the
+** next possible match, considering only non-deferred tokens. In other
+** words, if the phrase is "A B C", and "B" is deferred, the expression
+** is advanced to the next row that contains an instance of "A * C",
+** where "*" may match any single token. The position list in this case
+** is populated as for "A * C" before returning.
+**
+** 2. NEAR is treated as AND. If the expression is "x NEAR y", it is
+** advanced to point to the next row that matches "x AND y".
+**
+** See fts3EvalTestDeferredAndNear() for details on testing if a row is
+** really a match, taking into account deferred tokens and NEAR operators.
*/
-#define DOCID_CMP(i1, i2) ((pCsr->bDesc?-1:1) * (i1-i2))
-
-static void fts3EvalNext(
- Fts3Cursor *pCsr,
- Fts3Expr *pExpr,
- int *pRc
+static void fts3EvalNextRow(
+ Fts3Cursor *pCsr, /* FTS Cursor handle */
+ Fts3Expr *pExpr, /* Expr. to advance to next matching row */
+ int *pRc /* IN/OUT: Error code */
){
if( *pRc==SQLITE_OK ){
+ int bDescDoclist = pCsr->bDesc; /* Used by DOCID_CMP() macro */
assert( pExpr->bEof==0 );
pExpr->bStart = 1;
@@ -115935,28 +122287,32 @@ static void fts3EvalNext(
Fts3Expr *pLeft = pExpr->pLeft;
Fts3Expr *pRight = pExpr->pRight;
assert( !pLeft->bDeferred || !pRight->bDeferred );
+
if( pLeft->bDeferred ){
- fts3EvalNext(pCsr, pRight, pRc);
+ /* LHS is entirely deferred. So we assume it matches every row.
+ ** Advance the RHS iterator to find the next row visited. */
+ fts3EvalNextRow(pCsr, pRight, pRc);
pExpr->iDocid = pRight->iDocid;
pExpr->bEof = pRight->bEof;
}else if( pRight->bDeferred ){
- fts3EvalNext(pCsr, pLeft, pRc);
+ /* RHS is entirely deferred. So we assume it matches every row.
+ ** Advance the LHS iterator to find the next row visited. */
+ fts3EvalNextRow(pCsr, pLeft, pRc);
pExpr->iDocid = pLeft->iDocid;
pExpr->bEof = pLeft->bEof;
}else{
- fts3EvalNext(pCsr, pLeft, pRc);
- fts3EvalNext(pCsr, pRight, pRc);
-
+ /* Neither the RHS or LHS are deferred. */
+ fts3EvalNextRow(pCsr, pLeft, pRc);
+ fts3EvalNextRow(pCsr, pRight, pRc);
while( !pLeft->bEof && !pRight->bEof && *pRc==SQLITE_OK ){
sqlite3_int64 iDiff = DOCID_CMP(pLeft->iDocid, pRight->iDocid);
if( iDiff==0 ) break;
if( iDiff<0 ){
- fts3EvalNext(pCsr, pLeft, pRc);
+ fts3EvalNextRow(pCsr, pLeft, pRc);
}else{
- fts3EvalNext(pCsr, pRight, pRc);
+ fts3EvalNextRow(pCsr, pRight, pRc);
}
}
-
pExpr->iDocid = pLeft->iDocid;
pExpr->bEof = (pLeft->bEof || pRight->bEof);
}
@@ -115972,12 +122328,12 @@ static void fts3EvalNext(
assert( pRight->bStart || pLeft->iDocid==pRight->iDocid );
if( pRight->bEof || (pLeft->bEof==0 && iCmp<0) ){
- fts3EvalNext(pCsr, pLeft, pRc);
+ fts3EvalNextRow(pCsr, pLeft, pRc);
}else if( pLeft->bEof || (pRight->bEof==0 && iCmp>0) ){
- fts3EvalNext(pCsr, pRight, pRc);
+ fts3EvalNextRow(pCsr, pRight, pRc);
}else{
- fts3EvalNext(pCsr, pLeft, pRc);
- fts3EvalNext(pCsr, pRight, pRc);
+ fts3EvalNextRow(pCsr, pLeft, pRc);
+ fts3EvalNextRow(pCsr, pRight, pRc);
}
pExpr->bEof = (pLeft->bEof && pRight->bEof);
@@ -115996,17 +122352,17 @@ static void fts3EvalNext(
Fts3Expr *pRight = pExpr->pRight;
if( pRight->bStart==0 ){
- fts3EvalNext(pCsr, pRight, pRc);
+ fts3EvalNextRow(pCsr, pRight, pRc);
assert( *pRc!=SQLITE_OK || pRight->bStart );
}
- fts3EvalNext(pCsr, pLeft, pRc);
+ fts3EvalNextRow(pCsr, pLeft, pRc);
if( pLeft->bEof==0 ){
while( !*pRc
&& !pRight->bEof
&& DOCID_CMP(pLeft->iDocid, pRight->iDocid)>0
){
- fts3EvalNext(pCsr, pRight, pRc);
+ fts3EvalNextRow(pCsr, pRight, pRc);
}
}
pExpr->iDocid = pLeft->iDocid;
@@ -116016,7 +122372,7 @@ static void fts3EvalNext(
default: {
Fts3Phrase *pPhrase = pExpr->pPhrase;
- fts3EvalZeroPoslist(pPhrase);
+ fts3EvalInvalidatePoslist(pPhrase);
*pRc = fts3EvalPhraseNext(pCsr, pPhrase, &pExpr->bEof);
pExpr->iDocid = pPhrase->doclist.iDocid;
break;
@@ -116025,15 +122381,120 @@ static void fts3EvalNext(
}
}
-static int fts3EvalDeferredTest(Fts3Cursor *pCsr, Fts3Expr *pExpr, int *pRc){
- int bHit = 1;
+/*
+** If *pRc is not SQLITE_OK, or if pExpr is not the root node of a NEAR
+** cluster, then this function returns 1 immediately.
+**
+** Otherwise, it checks if the current row really does match the NEAR
+** expression, using the data currently stored in the position lists
+** (Fts3Expr->pPhrase.doclist.pList/nList) for each phrase in the expression.
+**
+** If the current row is a match, the position list associated with each
+** phrase in the NEAR expression is edited in place to contain only those
+** phrase instances sufficiently close to their peers to satisfy all NEAR
+** constraints. In this case it returns 1. If the NEAR expression does not
+** match the current row, 0 is returned. The position lists may or may not
+** be edited if 0 is returned.
+*/
+static int fts3EvalNearTest(Fts3Expr *pExpr, int *pRc){
+ int res = 1;
+
+ /* The following block runs if pExpr is the root of a NEAR query.
+ ** For example, the query:
+ **
+ ** "w" NEAR "x" NEAR "y" NEAR "z"
+ **
+ ** which is represented in tree form as:
+ **
+ ** |
+ ** +--NEAR--+ <-- root of NEAR query
+ ** | |
+ ** +--NEAR--+ "z"
+ ** | |
+ ** +--NEAR--+ "y"
+ ** | |
+ ** "w" "x"
+ **
+ ** The right-hand child of a NEAR node is always a phrase. The
+ ** left-hand child may be either a phrase or a NEAR node. There are
+ ** no exceptions to this - it's the way the parser in fts3_expr.c works.
+ */
+ if( *pRc==SQLITE_OK
+ && pExpr->eType==FTSQUERY_NEAR
+ && pExpr->bEof==0
+ && (pExpr->pParent==0 || pExpr->pParent->eType!=FTSQUERY_NEAR)
+ ){
+ Fts3Expr *p;
+ int nTmp = 0; /* Bytes of temp space */
+ char *aTmp; /* Temp space for PoslistNearMerge() */
+
+ /* Allocate temporary working space. */
+ for(p=pExpr; p->pLeft; p=p->pLeft){
+ nTmp += p->pRight->pPhrase->doclist.nList;
+ }
+ nTmp += p->pPhrase->doclist.nList;
+ if( nTmp==0 ){
+ res = 0;
+ }else{
+ aTmp = sqlite3_malloc(nTmp*2);
+ if( !aTmp ){
+ *pRc = SQLITE_NOMEM;
+ res = 0;
+ }else{
+ char *aPoslist = p->pPhrase->doclist.pList;
+ int nToken = p->pPhrase->nToken;
+
+ for(p=p->pParent;res && p && p->eType==FTSQUERY_NEAR; p=p->pParent){
+ Fts3Phrase *pPhrase = p->pRight->pPhrase;
+ int nNear = p->nNear;
+ res = fts3EvalNearTrim(nNear, aTmp, &aPoslist, &nToken, pPhrase);
+ }
+
+ aPoslist = pExpr->pRight->pPhrase->doclist.pList;
+ nToken = pExpr->pRight->pPhrase->nToken;
+ for(p=pExpr->pLeft; p && res; p=p->pLeft){
+ int nNear;
+ Fts3Phrase *pPhrase;
+ assert( p->pParent && p->pParent->pLeft==p );
+ nNear = p->pParent->nNear;
+ pPhrase = (
+ p->eType==FTSQUERY_NEAR ? p->pRight->pPhrase : p->pPhrase
+ );
+ res = fts3EvalNearTrim(nNear, aTmp, &aPoslist, &nToken, pPhrase);
+ }
+ }
+
+ sqlite3_free(aTmp);
+ }
+ }
+
+ return res;
+}
+
+/*
+** This function is a helper function for fts3EvalTestDeferredAndNear().
+** Assuming no error occurs or has occurred, It returns non-zero if the
+** expression passed as the second argument matches the row that pCsr
+** currently points to, or zero if it does not.
+**
+** If *pRc is not SQLITE_OK when this function is called, it is a no-op.
+** If an error occurs during execution of this function, *pRc is set to
+** the appropriate SQLite error code. In this case the returned value is
+** undefined.
+*/
+static int fts3EvalTestExpr(
+ Fts3Cursor *pCsr, /* FTS cursor handle */
+ Fts3Expr *pExpr, /* Expr to test. May or may not be root. */
+ int *pRc /* IN/OUT: Error code */
+){
+ int bHit = 1; /* Return value */
if( *pRc==SQLITE_OK ){
switch( pExpr->eType ){
case FTSQUERY_NEAR:
case FTSQUERY_AND:
bHit = (
- fts3EvalDeferredTest(pCsr, pExpr->pLeft, pRc)
- && fts3EvalDeferredTest(pCsr, pExpr->pRight, pRc)
+ fts3EvalTestExpr(pCsr, pExpr->pLeft, pRc)
+ && fts3EvalTestExpr(pCsr, pExpr->pRight, pRc)
&& fts3EvalNearTest(pExpr, pRc)
);
@@ -116059,43 +122520,46 @@ static int fts3EvalDeferredTest(Fts3Cursor *pCsr, Fts3Expr *pExpr, int *pRc){
Fts3Expr *p;
for(p=pExpr; p->pPhrase==0; p=p->pLeft){
if( p->pRight->iDocid==pCsr->iPrevId ){
- fts3EvalZeroPoslist(p->pRight->pPhrase);
+ fts3EvalInvalidatePoslist(p->pRight->pPhrase);
}
}
if( p->iDocid==pCsr->iPrevId ){
- fts3EvalZeroPoslist(p->pPhrase);
+ fts3EvalInvalidatePoslist(p->pPhrase);
}
}
break;
case FTSQUERY_OR: {
- int bHit1 = fts3EvalDeferredTest(pCsr, pExpr->pLeft, pRc);
- int bHit2 = fts3EvalDeferredTest(pCsr, pExpr->pRight, pRc);
+ int bHit1 = fts3EvalTestExpr(pCsr, pExpr->pLeft, pRc);
+ int bHit2 = fts3EvalTestExpr(pCsr, pExpr->pRight, pRc);
bHit = bHit1 || bHit2;
break;
}
case FTSQUERY_NOT:
bHit = (
- fts3EvalDeferredTest(pCsr, pExpr->pLeft, pRc)
- && !fts3EvalDeferredTest(pCsr, pExpr->pRight, pRc)
+ fts3EvalTestExpr(pCsr, pExpr->pLeft, pRc)
+ && !fts3EvalTestExpr(pCsr, pExpr->pRight, pRc)
);
break;
default: {
+#ifndef SQLITE_DISABLE_FTS4_DEFERRED
if( pCsr->pDeferred
&& (pExpr->iDocid==pCsr->iPrevId || pExpr->bDeferred)
){
Fts3Phrase *pPhrase = pExpr->pPhrase;
assert( pExpr->bDeferred || pPhrase->doclist.bFreeList==0 );
if( pExpr->bDeferred ){
- fts3EvalZeroPoslist(pPhrase);
+ fts3EvalInvalidatePoslist(pPhrase);
}
*pRc = fts3EvalDeferredPhrase(pCsr, pPhrase);
bHit = (pPhrase->doclist.pList!=0);
pExpr->iDocid = pCsr->iPrevId;
- }else{
+ }else
+#endif
+ {
bHit = (pExpr->bEof==0 && pExpr->iDocid==pCsr->iPrevId);
}
break;
@@ -116106,27 +122570,49 @@ static int fts3EvalDeferredTest(Fts3Cursor *pCsr, Fts3Expr *pExpr, int *pRc){
}
/*
-** Return 1 if both of the following are true:
+** This function is called as the second part of each xNext operation when
+** iterating through the results of a full-text query. At this point the
+** cursor points to a row that matches the query expression, with the
+** following caveats:
+**
+** * Up until this point, "NEAR" operators in the expression have been
+** treated as "AND".
+**
+** * Deferred tokens have not yet been considered.
+**
+** If *pRc is not SQLITE_OK when this function is called, it immediately
+** returns 0. Otherwise, it tests whether or not after considering NEAR
+** operators and deferred tokens the current row is still a match for the
+** expression. It returns 1 if both of the following are true:
**
** 1. *pRc is SQLITE_OK when this function returns, and
**
** 2. After scanning the current FTS table row for the deferred tokens,
-** it is determined that the row does not match the query.
+** it is determined that the row does *not* match the query.
**
** Or, if no error occurs and it seems the current row does match the FTS
** query, return 0.
*/
-static int fts3EvalLoadDeferred(Fts3Cursor *pCsr, int *pRc){
+static int fts3EvalTestDeferredAndNear(Fts3Cursor *pCsr, int *pRc){
int rc = *pRc;
int bMiss = 0;
if( rc==SQLITE_OK ){
+
+ /* If there are one or more deferred tokens, load the current row into
+ ** memory and scan it to determine the position list for each deferred
+ ** token. Then, see if this row is really a match, considering deferred
+ ** tokens and NEAR operators (neither of which were taken into account
+ ** earlier, by fts3EvalNextRow()).
+ */
if( pCsr->pDeferred ){
rc = fts3CursorSeek(0, pCsr);
if( rc==SQLITE_OK ){
rc = sqlite3Fts3CacheDeferredDoclists(pCsr);
}
}
- bMiss = (0==fts3EvalDeferredTest(pCsr, pCsr->pExpr, &rc));
+ bMiss = (0==fts3EvalTestExpr(pCsr, pCsr->pExpr, &rc));
+
+ /* Free the position-lists accumulated for each deferred token above. */
sqlite3Fts3FreeDeferredDoclists(pCsr);
*pRc = rc;
}
@@ -116137,7 +122623,7 @@ static int fts3EvalLoadDeferred(Fts3Cursor *pCsr, int *pRc){
** Advance to the next document that matches the FTS expression in
** Fts3Cursor.pExpr.
*/
-SQLITE_PRIVATE int sqlite3Fts3EvalNext(Fts3Cursor *pCsr){
+static int fts3EvalNext(Fts3Cursor *pCsr){
int rc = SQLITE_OK; /* Return Code */
Fts3Expr *pExpr = pCsr->pExpr;
assert( pCsr->isEof==0 );
@@ -116149,19 +122635,19 @@ SQLITE_PRIVATE int sqlite3Fts3EvalNext(Fts3Cursor *pCsr){
sqlite3_reset(pCsr->pStmt);
}
assert( sqlite3_data_count(pCsr->pStmt)==0 );
- fts3EvalNext(pCsr, pExpr, &rc);
+ fts3EvalNextRow(pCsr, pExpr, &rc);
pCsr->isEof = pExpr->bEof;
pCsr->isRequireSeek = 1;
pCsr->isMatchinfoNeeded = 1;
pCsr->iPrevId = pExpr->iDocid;
- }while( pCsr->isEof==0 && fts3EvalLoadDeferred(pCsr, &rc) );
+ }while( pCsr->isEof==0 && fts3EvalTestDeferredAndNear(pCsr, &rc) );
}
return rc;
}
/*
** Restart interation for expression pExpr so that the next call to
-** sqlite3Fts3EvalNext() visits the first row. Do not allow incremental
+** fts3EvalNext() visits the first row. Do not allow incremental
** loading or merging of phrase doclists for this iteration.
**
** If *pRc is other than SQLITE_OK when this function is called, it is
@@ -116177,7 +122663,7 @@ static void fts3EvalRestart(
Fts3Phrase *pPhrase = pExpr->pPhrase;
if( pPhrase ){
- fts3EvalZeroPoslist(pPhrase);
+ fts3EvalInvalidatePoslist(pPhrase);
if( pPhrase->bIncr ){
assert( pPhrase->nToken==1 );
assert( pPhrase->aToken[0].pSegcsr );
@@ -116293,14 +122779,14 @@ static int fts3EvalGatherStats(
assert( sqlite3_data_count(pCsr->pStmt)==0 );
/* Advance to the next document */
- fts3EvalNext(pCsr, pRoot, &rc);
+ fts3EvalNextRow(pCsr, pRoot, &rc);
pCsr->isEof = pRoot->bEof;
pCsr->isRequireSeek = 1;
pCsr->isMatchinfoNeeded = 1;
pCsr->iPrevId = pRoot->iDocid;
}while( pCsr->isEof==0
&& pRoot->eType==FTSQUERY_NEAR
- && fts3EvalLoadDeferred(pCsr, &rc)
+ && fts3EvalTestDeferredAndNear(pCsr, &rc)
);
if( rc==SQLITE_OK && pCsr->isEof==0 ){
@@ -116322,10 +122808,10 @@ static int fts3EvalGatherStats(
*/
fts3EvalRestart(pCsr, pRoot, &rc);
do {
- fts3EvalNext(pCsr, pRoot, &rc);
+ fts3EvalNextRow(pCsr, pRoot, &rc);
assert( pRoot->bEof==0 );
}while( pRoot->iDocid!=iDocid && rc==SQLITE_OK );
- fts3EvalLoadDeferred(pCsr, &rc);
+ fts3EvalTestDeferredAndNear(pCsr, &rc);
}
}
return rc;
@@ -116399,7 +122885,7 @@ SQLITE_PRIVATE int sqlite3Fts3EvalPhraseStats(
** of the current row.
**
** More specifically, the returned buffer contains 1 varint for each
-** occurence of the phrase in the column, stored using the normal (delta+2)
+** occurrence of the phrase in the column, stored using the normal (delta+2)
** compression and is terminated by either an 0x01 or 0x00 byte. For example,
** if the requested column contains "a b X c d X X" and the position-list
** for 'X' is requested, the buffer returned may contain:
@@ -116409,26 +122895,87 @@ SQLITE_PRIVATE int sqlite3Fts3EvalPhraseStats(
** This function works regardless of whether or not the phrase is deferred,
** incremental, or neither.
*/
-SQLITE_PRIVATE char *sqlite3Fts3EvalPhrasePoslist(
+SQLITE_PRIVATE int sqlite3Fts3EvalPhrasePoslist(
Fts3Cursor *pCsr, /* FTS3 cursor object */
Fts3Expr *pExpr, /* Phrase to return doclist for */
- int iCol /* Column to return position list for */
+ int iCol, /* Column to return position list for */
+ char **ppOut /* OUT: Pointer to position list */
){
Fts3Phrase *pPhrase = pExpr->pPhrase;
Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab;
- char *pIter = pPhrase->doclist.pList;
+ char *pIter;
int iThis;
+ sqlite3_int64 iDocid;
+ /* If this phrase is applies specifically to some column other than
+ ** column iCol, return a NULL pointer. */
+ *ppOut = 0;
assert( iCol>=0 && iCol<pTab->nColumn );
- if( !pIter
- || pExpr->bEof
- || pExpr->iDocid!=pCsr->iPrevId
- || (pPhrase->iColumn<pTab->nColumn && pPhrase->iColumn!=iCol)
- ){
- return 0;
+ if( (pPhrase->iColumn<pTab->nColumn && pPhrase->iColumn!=iCol) ){
+ return SQLITE_OK;
}
- assert( pPhrase->doclist.nList>0 );
+ iDocid = pExpr->iDocid;
+ pIter = pPhrase->doclist.pList;
+ if( iDocid!=pCsr->iPrevId || pExpr->bEof ){
+ int bDescDoclist = pTab->bDescIdx; /* For DOCID_CMP macro */
+ int bOr = 0;
+ u8 bEof = 0;
+ Fts3Expr *p;
+
+ /* Check if this phrase descends from an OR expression node. If not,
+ ** return NULL. Otherwise, the entry that corresponds to docid
+ ** pCsr->iPrevId may lie earlier in the doclist buffer. */
+ for(p=pExpr->pParent; p; p=p->pParent){
+ if( p->eType==FTSQUERY_OR ) bOr = 1;
+ }
+ if( bOr==0 ) return SQLITE_OK;
+
+ /* This is the descendent of an OR node. In this case we cannot use
+ ** an incremental phrase. Load the entire doclist for the phrase
+ ** into memory in this case. */
+ if( pPhrase->bIncr ){
+ int rc = SQLITE_OK;
+ int bEofSave = pExpr->bEof;
+ fts3EvalRestart(pCsr, pExpr, &rc);
+ while( rc==SQLITE_OK && !pExpr->bEof ){
+ fts3EvalNextRow(pCsr, pExpr, &rc);
+ if( bEofSave==0 && pExpr->iDocid==iDocid ) break;
+ }
+ pIter = pPhrase->doclist.pList;
+ assert( rc!=SQLITE_OK || pPhrase->bIncr==0 );
+ if( rc!=SQLITE_OK ) return rc;
+ }
+
+ if( pExpr->bEof ){
+ pIter = 0;
+ iDocid = 0;
+ }
+ bEof = (pPhrase->doclist.nAll==0);
+ assert( bDescDoclist==0 || bDescDoclist==1 );
+ assert( pCsr->bDesc==0 || pCsr->bDesc==1 );
+
+ if( pCsr->bDesc==bDescDoclist ){
+ int dummy;
+ while( (pIter==0 || DOCID_CMP(iDocid, pCsr->iPrevId)>0 ) && bEof==0 ){
+ sqlite3Fts3DoclistPrev(
+ bDescDoclist, pPhrase->doclist.aAll, pPhrase->doclist.nAll,
+ &pIter, &iDocid, &dummy, &bEof
+ );
+ }
+ }else{
+ while( (pIter==0 || DOCID_CMP(iDocid, pCsr->iPrevId)<0 ) && bEof==0 ){
+ sqlite3Fts3DoclistNext(
+ bDescDoclist, pPhrase->doclist.aAll, pPhrase->doclist.nAll,
+ &pIter, &iDocid, &bEof
+ );
+ }
+ }
+
+ if( bEof || iDocid!=pCsr->iPrevId ) pIter = 0;
+ }
+ if( pIter==0 ) return SQLITE_OK;
+
if( *pIter==0x01 ){
pIter++;
pIter += sqlite3Fts3GetVarint32(pIter, &iThis);
@@ -116442,7 +122989,8 @@ SQLITE_PRIVATE char *sqlite3Fts3EvalPhrasePoslist(
pIter += sqlite3Fts3GetVarint32(pIter, &iThis);
}
- return ((iCol==iThis)?pIter:0);
+ *ppOut = ((iCol==iThis)?pIter:0);
+ return SQLITE_OK;
}
/*
@@ -116456,7 +123004,7 @@ SQLITE_PRIVATE void sqlite3Fts3EvalPhraseCleanup(Fts3Phrase *pPhrase){
if( pPhrase ){
int i;
sqlite3_free(pPhrase->doclist.aAll);
- fts3EvalZeroPoslist(pPhrase);
+ fts3EvalInvalidatePoslist(pPhrase);
memset(&pPhrase->doclist, 0, sizeof(Fts3Doclist));
for(i=0; i<pPhrase->nToken; i++){
fts3SegReaderCursorFree(pPhrase->aToken[i].pSegcsr);
@@ -116465,6 +123013,30 @@ SQLITE_PRIVATE void sqlite3Fts3EvalPhraseCleanup(Fts3Phrase *pPhrase){
}
}
+
+/*
+** Return SQLITE_CORRUPT_VTAB.
+*/
+#ifdef SQLITE_DEBUG
+SQLITE_PRIVATE int sqlite3Fts3Corrupt(){
+ return SQLITE_CORRUPT_VTAB;
+}
+#endif
+
+#if !SQLITE_CORE
+/*
+** Initialize API pointer table, if required.
+*/
+SQLITE_API int sqlite3_extension_init(
+ sqlite3 *db,
+ char **pzErrMsg,
+ const sqlite3_api_routines *pApi
+){
+ SQLITE_EXTENSION_INIT2(pApi)
+ return sqlite3Fts3Init(db);
+}
+#endif
+
#endif
/************** End of fts3.c ************************************************/
@@ -116484,6 +123056,8 @@ SQLITE_PRIVATE void sqlite3Fts3EvalPhraseCleanup(Fts3Phrase *pPhrase){
*/
#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3)
+/* #include <string.h> */
+/* #include <assert.h> */
typedef struct Fts3auxTable Fts3auxTable;
typedef struct Fts3auxCursor Fts3auxCursor;
@@ -116547,9 +123121,9 @@ static int fts3auxConnectMethod(
}
zDb = argv[1];
- nDb = strlen(zDb);
+ nDb = (int)strlen(zDb);
zFts3 = argv[3];
- nFts3 = strlen(zFts3);
+ nFts3 = (int)strlen(zFts3);
rc = sqlite3_declare_vtab(db, FTS3_TERMS_SCHEMA);
if( rc!=SQLITE_OK ) return rc;
@@ -116844,7 +123418,7 @@ static int fts3auxFilterMethod(
if( pCsr->zStop==0 ) return SQLITE_NOMEM;
}
- rc = sqlite3Fts3SegReaderCursor(pFts3, 0, FTS3_SEGCURSOR_ALL,
+ rc = sqlite3Fts3SegReaderCursor(pFts3, 0, 0, FTS3_SEGCURSOR_ALL,
pCsr->filter.zTerm, pCsr->filter.nTerm, 0, isScan, &pCsr->csr
);
if( rc==SQLITE_OK ){
@@ -117022,6 +123596,8 @@ SQLITE_API int sqlite3_fts3_enable_parentheses = 0;
*/
#define SQLITE_FTS3_DEFAULT_NEAR_PARAM 10
+/* #include <string.h> */
+/* #include <assert.h> */
/*
** isNot:
@@ -117034,7 +123610,9 @@ SQLITE_API int sqlite3_fts3_enable_parentheses = 0;
typedef struct ParseContext ParseContext;
struct ParseContext {
sqlite3_tokenizer *pTokenizer; /* Tokenizer module */
+ int iLangid; /* Language id used with tokenizer */
const char **azCol; /* Array of column names for fts3 table */
+ int bFts4; /* True to allow FTS4-only syntax */
int nCol; /* Number of entries in azCol[] */
int iDefaultCol; /* Default column to query */
int isNot; /* True if getNextNode() sees a unary - */
@@ -117046,7 +123624,7 @@ struct ParseContext {
** This function is equivalent to the standard isspace() function.
**
** The standard isspace() can be awkward to use safely, because although it
-** is defined to accept an argument of type int, its behaviour when passed
+** is defined to accept an argument of type int, its behavior when passed
** an integer that falls outside of the range of the unsigned char type
** is undefined (and sometimes, "undefined" means segfault). This wrapper
** is defined to accept an argument of type char, and always returns 0 for
@@ -117068,6 +123646,33 @@ static void *fts3MallocZero(int nByte){
return pRet;
}
+SQLITE_PRIVATE int sqlite3Fts3OpenTokenizer(
+ sqlite3_tokenizer *pTokenizer,
+ int iLangid,
+ const char *z,
+ int n,
+ sqlite3_tokenizer_cursor **ppCsr
+){
+ sqlite3_tokenizer_module const *pModule = pTokenizer->pModule;
+ sqlite3_tokenizer_cursor *pCsr = 0;
+ int rc;
+
+ rc = pModule->xOpen(pTokenizer, z, n, &pCsr);
+ assert( rc==SQLITE_OK || pCsr==0 );
+ if( rc==SQLITE_OK ){
+ pCsr->pTokenizer = pTokenizer;
+ if( pModule->iVersion>=1 ){
+ rc = pModule->xLanguageid(pCsr, iLangid);
+ if( rc!=SQLITE_OK ){
+ pModule->xClose(pCsr);
+ pCsr = 0;
+ }
+ }
+ }
+ *ppCsr = pCsr;
+ return rc;
+}
+
/*
** Extract the next token from buffer z (length n) using the tokenizer
@@ -117095,15 +123700,13 @@ static int getNextToken(
Fts3Expr *pRet = 0;
int nConsumed = 0;
- rc = pModule->xOpen(pTokenizer, z, n, &pCursor);
+ rc = sqlite3Fts3OpenTokenizer(pTokenizer, pParse->iLangid, z, n, &pCursor);
if( rc==SQLITE_OK ){
const char *zToken;
- int nToken, iStart, iEnd, iPosition;
+ int nToken = 0, iStart = 0, iEnd = 0, iPosition = 0;
int nByte; /* total space to allocate */
- pCursor->pTokenizer = pTokenizer;
rc = pModule->xNext(pCursor, &zToken, &nToken, &iStart, &iEnd, &iPosition);
-
if( rc==SQLITE_OK ){
nByte = sizeof(Fts3Expr) + sizeof(Fts3Phrase) + nToken;
pRet = (Fts3Expr *)fts3MallocZero(nByte);
@@ -117122,9 +123725,21 @@ static int getNextToken(
pRet->pPhrase->aToken[0].isPrefix = 1;
iEnd++;
}
- if( !sqlite3_fts3_enable_parentheses && iStart>0 && z[iStart-1]=='-' ){
- pParse->isNot = 1;
+
+ while( 1 ){
+ if( !sqlite3_fts3_enable_parentheses
+ && iStart>0 && z[iStart-1]=='-'
+ ){
+ pParse->isNot = 1;
+ iStart--;
+ }else if( pParse->bFts4 && iStart>0 && z[iStart-1]=='^' ){
+ pRet->pPhrase->aToken[0].bFirst = 1;
+ iStart--;
+ }else{
+ break;
+ }
}
+
}
nConsumed = iEnd;
}
@@ -117197,13 +123812,13 @@ static int getNextString(
** appends buffer zTemp to buffer p, and fills in the Fts3Expr and Fts3Phrase
** structures.
*/
- rc = pModule->xOpen(pTokenizer, zInput, nInput, &pCursor);
+ rc = sqlite3Fts3OpenTokenizer(
+ pTokenizer, pParse->iLangid, zInput, nInput, &pCursor);
if( rc==SQLITE_OK ){
int ii;
- pCursor->pTokenizer = pTokenizer;
for(ii=0; rc==SQLITE_OK; ii++){
const char *zByte;
- int nByte, iBegin, iEnd, iPos;
+ int nByte = 0, iBegin = 0, iEnd = 0, iPos = 0;
rc = pModule->xNext(pCursor, &zByte, &nByte, &iBegin, &iEnd, &iPos);
if( rc==SQLITE_OK ){
Fts3PhraseToken *pToken;
@@ -117223,6 +123838,7 @@ static int getNextString(
pToken->n = nByte;
pToken->isPrefix = (iEnd<nInput && zInput[iEnd]=='*');
+ pToken->bFirst = (iBegin>0 && zInput[iBegin-1]=='^');
nToken = ii+1;
}
}
@@ -117244,8 +123860,12 @@ static int getNextString(
p->pPhrase->nToken = nToken;
zBuf = (char *)&p->pPhrase->aToken[nToken];
- memcpy(zBuf, zTemp, nTemp);
- sqlite3_free(zTemp);
+ if( zTemp ){
+ memcpy(zBuf, zTemp, nTemp);
+ sqlite3_free(zTemp);
+ }else{
+ assert( nTemp==0 );
+ }
for(jj=0; jj<p->pPhrase->nToken; jj++){
p->pPhrase->aToken[jj].z = zBuf;
@@ -117669,7 +124289,9 @@ exprparse_out:
*/
SQLITE_PRIVATE int sqlite3Fts3ExprParse(
sqlite3_tokenizer *pTokenizer, /* Tokenizer module */
+ int iLangid, /* Language id for tokenizer */
char **azCol, /* Array of column names for fts3 table */
+ int bFts4, /* True to allow FTS4-only syntax */
int nCol, /* Number of entries in azCol[] */
int iDefaultCol, /* Default column to query */
const char *z, int n, /* Text of MATCH query */
@@ -117678,11 +124300,14 @@ SQLITE_PRIVATE int sqlite3Fts3ExprParse(
int nParsed;
int rc;
ParseContext sParse;
+
+ memset(&sParse, 0, sizeof(ParseContext));
sParse.pTokenizer = pTokenizer;
+ sParse.iLangid = iLangid;
sParse.azCol = (const char **)azCol;
sParse.nCol = nCol;
sParse.iDefaultCol = iDefaultCol;
- sParse.nNest = 0;
+ sParse.bFts4 = bFts4;
if( z==0 ){
*ppExpr = 0;
return SQLITE_OK;
@@ -117723,6 +124348,7 @@ SQLITE_PRIVATE void sqlite3Fts3ExprFree(Fts3Expr *p){
#ifdef SQLITE_TEST
+/* #include <stdio.h> */
/*
** Function to query the hash-table of tokenizers (see README.tokenizers).
@@ -117871,7 +124497,7 @@ static void fts3ExprTest(
}
rc = sqlite3Fts3ExprParse(
- pTokenizer, azCol, nCol, nCol, zExpr, nExpr, &pExpr
+ pTokenizer, 0, azCol, 0, nCol, nCol, zExpr, nExpr, &pExpr
);
if( rc!=SQLITE_OK && rc!=SQLITE_NOMEM ){
sqlite3_result_error(context, "Error parsing expression", -1);
@@ -117933,6 +124559,9 @@ SQLITE_PRIVATE int sqlite3Fts3ExprInitTestInterface(sqlite3* db){
*/
#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3)
+/* #include <assert.h> */
+/* #include <stdlib.h> */
+/* #include <string.h> */
/*
@@ -118313,6 +124942,10 @@ SQLITE_PRIVATE void *sqlite3Fts3HashInsert(
*/
#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3)
+/* #include <assert.h> */
+/* #include <stdlib.h> */
+/* #include <stdio.h> */
+/* #include <string.h> */
/*
@@ -118323,7 +124956,7 @@ typedef struct porter_tokenizer {
} porter_tokenizer;
/*
-** Class derived from sqlit3_tokenizer_cursor
+** Class derived from sqlite3_tokenizer_cursor
*/
typedef struct porter_tokenizer_cursor {
sqlite3_tokenizer_cursor base;
@@ -118913,6 +125546,7 @@ static const sqlite3_tokenizer_module porterTokenizerModule = {
porterOpen,
porterClose,
porterNext,
+ 0
};
/*
@@ -118954,12 +125588,10 @@ SQLITE_PRIVATE void sqlite3Fts3PorterTokenizerModule(
** * The FTS3 module is being built into the core of
** SQLite (in which case SQLITE_ENABLE_FTS3 is defined).
*/
-#ifndef SQLITE_CORE
- SQLITE_EXTENSION_INIT1
-#endif
-
#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3)
+/* #include <assert.h> */
+/* #include <string.h> */
/*
** Implementation of the SQL scalar function for accessing the underlying
@@ -119135,14 +125767,15 @@ SQLITE_PRIVATE int sqlite3Fts3InitTokenizer(
#ifdef SQLITE_TEST
+/* #include <tcl.h> */
+/* #include <string.h> */
/*
** Implementation of a special SQL scalar function for testing tokenizers
** designed to be used in concert with the Tcl testing framework. This
-** function must be called with two arguments:
+** function must be called with two or more arguments:
**
-** SELECT <function-name>(<key-name>, <input-string>);
-** SELECT <function-name>(<key-name>, <pointer>);
+** SELECT <function-name>(<key-name>, ..., <input-string>);
**
** where <function-name> is the name passed as the second argument
** to the sqlite3Fts3InitHashTable() function (e.g. 'fts3_tokenizer')
@@ -119179,27 +125812,27 @@ static void testFunc(
const char *zInput;
int nInput;
- const char *zArg = 0;
+ const char *azArg[64];
const char *zToken;
- int nToken;
- int iStart;
- int iEnd;
- int iPos;
+ int nToken = 0;
+ int iStart = 0;
+ int iEnd = 0;
+ int iPos = 0;
+ int i;
Tcl_Obj *pRet;
- assert( argc==2 || argc==3 );
+ if( argc<2 ){
+ sqlite3_result_error(context, "insufficient arguments", -1);
+ return;
+ }
nName = sqlite3_value_bytes(argv[0]);
zName = (const char *)sqlite3_value_text(argv[0]);
nInput = sqlite3_value_bytes(argv[argc-1]);
zInput = (const char *)sqlite3_value_text(argv[argc-1]);
- if( argc==3 ){
- zArg = (const char *)sqlite3_value_text(argv[1]);
- }
-
pHash = (Fts3Hash *)sqlite3_user_data(context);
p = (sqlite3_tokenizer_module *)sqlite3Fts3HashFind(pHash, zName, nName+1);
@@ -119213,16 +125846,19 @@ static void testFunc(
pRet = Tcl_NewObj();
Tcl_IncrRefCount(pRet);
- if( SQLITE_OK!=p->xCreate(zArg ? 1 : 0, &zArg, &pTokenizer) ){
+ for(i=1; i<argc-1; i++){
+ azArg[i-1] = (const char *)sqlite3_value_text(argv[i]);
+ }
+
+ if( SQLITE_OK!=p->xCreate(argc-2, azArg, &pTokenizer) ){
zErr = "error in xCreate()";
goto finish;
}
pTokenizer->pModule = p;
- if( SQLITE_OK!=p->xOpen(pTokenizer, zInput, nInput, &pCsr) ){
+ if( sqlite3Fts3OpenTokenizer(pTokenizer, 0, zInput, nInput, &pCsr) ){
zErr = "error in xOpen()";
goto finish;
}
- pCsr->pTokenizer = pTokenizer;
while( SQLITE_OK==p->xNext(pCsr, &zToken, &nToken, &iStart, &iEnd, &iPos) ){
Tcl_ListObjAppendElement(0, pRet, Tcl_NewIntObj(iPos));
@@ -119356,7 +125992,7 @@ static void intTestFunc(
/*
** Set up SQL objects in database db used to access the contents of
** the hash table pointed to by argument pHash. The hash table must
-** been initialised to use string keys, and to take a private copy
+** been initialized to use string keys, and to take a private copy
** of the key when a value is inserted. i.e. by a call similar to:
**
** sqlite3Fts3HashInit(pHash, FTS3_HASH_STRING, 1);
@@ -119398,10 +126034,7 @@ SQLITE_PRIVATE int sqlite3Fts3InitHashTable(
}
#ifdef SQLITE_TEST
if( SQLITE_OK==rc ){
- rc = sqlite3_create_function(db, zTest, 2, any, p, testFunc, 0, 0);
- }
- if( SQLITE_OK==rc ){
- rc = sqlite3_create_function(db, zTest, 3, any, p, testFunc, 0, 0);
+ rc = sqlite3_create_function(db, zTest, -1, any, p, testFunc, 0, 0);
}
if( SQLITE_OK==rc ){
rc = sqlite3_create_function(db, zTest2, 0, any, pdb, intTestFunc, 0, 0);
@@ -119446,6 +126079,10 @@ SQLITE_PRIVATE int sqlite3Fts3InitHashTable(
*/
#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3)
+/* #include <assert.h> */
+/* #include <stdlib.h> */
+/* #include <stdio.h> */
+/* #include <string.h> */
typedef struct simple_tokenizer {
@@ -119634,6 +126271,7 @@ static const sqlite3_tokenizer_module simpleTokenizerModule = {
simpleOpen,
simpleClose,
simpleNext,
+ 0,
};
/*
@@ -119671,6 +126309,12 @@ SQLITE_PRIVATE void sqlite3Fts3SimpleTokenizerModule(
#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3)
+/* #include <string.h> */
+/* #include <assert.h> */
+/* #include <stdlib.h> */
+
+
+#define FTS_MAX_APPENDABLE_HEIGHT 16
/*
** When full-text index nodes are loaded from disk, the buffer that they
@@ -119711,6 +126355,29 @@ int test_fts3_node_chunk_threshold = (4*1024)*4;
# define FTS3_NODE_CHUNK_THRESHOLD (FTS3_NODE_CHUNKSIZE*4)
#endif
+/*
+** The two values that may be meaningfully bound to the :1 parameter in
+** statements SQL_REPLACE_STAT and SQL_SELECT_STAT.
+*/
+#define FTS_STAT_DOCTOTAL 0
+#define FTS_STAT_INCRMERGEHINT 1
+#define FTS_STAT_AUTOINCRMERGE 2
+
+/*
+** If FTS_LOG_MERGES is defined, call sqlite3_log() to report each automatic
+** and incremental merge operation that takes place. This is used for
+** debugging FTS only, it should not usually be turned on in production
+** systems.
+*/
+#ifdef FTS3_LOG_MERGES
+static void fts3LogMerge(int nMerge, sqlite3_int64 iAbsLevel){
+ sqlite3_log(SQLITE_OK, "%d-way merge from level %d", nMerge, (int)iAbsLevel);
+}
+#else
+#define fts3LogMerge(x, y)
+#endif
+
+
typedef struct PendingList PendingList;
typedef struct SegmentNode SegmentNode;
typedef struct SegmentWriter SegmentWriter;
@@ -119758,6 +126425,8 @@ struct Fts3DeferredToken {
*/
struct Fts3SegReader {
int iIdx; /* Index within level, or 0x7FFFFFFF for PT */
+ u8 bLookup; /* True for a lookup only */
+ u8 rootOnly; /* True for a root-only reader */
sqlite3_int64 iStartBlock; /* Rowid of first leaf block to traverse */
sqlite3_int64 iLeafEndBlock; /* Rowid of final leaf block to traverse */
@@ -119791,7 +126460,7 @@ struct Fts3SegReader {
};
#define fts3SegReaderIsPending(p) ((p)->ppNextElem!=0)
-#define fts3SegReaderIsRootOnly(p) ((p)->aNode==(char *)&(p)[1])
+#define fts3SegReaderIsRootOnly(p) ((p)->rootOnly!=0)
/*
** An instance of this structure is used to create a segment b-tree in the
@@ -119871,13 +126540,22 @@ struct SegmentNode {
#define SQL_DELETE_DOCSIZE 19
#define SQL_REPLACE_DOCSIZE 20
#define SQL_SELECT_DOCSIZE 21
-#define SQL_SELECT_DOCTOTAL 22
-#define SQL_REPLACE_DOCTOTAL 23
+#define SQL_SELECT_STAT 22
+#define SQL_REPLACE_STAT 23
#define SQL_SELECT_ALL_PREFIX_LEVEL 24
#define SQL_DELETE_ALL_TERMS_SEGDIR 25
-
#define SQL_DELETE_SEGDIR_RANGE 26
+#define SQL_SELECT_ALL_LANGID 27
+#define SQL_FIND_MERGE_LEVEL 28
+#define SQL_MAX_LEAF_NODE_ESTIMATE 29
+#define SQL_DELETE_SEGDIR_ENTRY 30
+#define SQL_SHIFT_SEGDIR_ENTRY 31
+#define SQL_SELECT_SEGDIR 32
+#define SQL_CHOMP_SEGDIR 33
+#define SQL_SEGMENT_IS_APPENDABLE 34
+#define SQL_SELECT_INDEXES 35
+#define SQL_SELECT_MXLEVEL 36
/*
** This function is used to obtain an SQLite prepared statement handle
@@ -119904,11 +126582,11 @@ static int fts3SqlStmt(
/* 4 */ "DELETE FROM %Q.'%q_segdir'",
/* 5 */ "DELETE FROM %Q.'%q_docsize'",
/* 6 */ "DELETE FROM %Q.'%q_stat'",
-/* 7 */ "SELECT %s FROM %Q.'%q_content' AS x WHERE rowid=?",
+/* 7 */ "SELECT %s WHERE rowid=?",
/* 8 */ "SELECT (SELECT max(idx) FROM %Q.'%q_segdir' WHERE level = ?) + 1",
-/* 9 */ "INSERT INTO %Q.'%q_segments'(blockid, block) VALUES(?, ?)",
+/* 9 */ "REPLACE INTO %Q.'%q_segments'(blockid, block) VALUES(?, ?)",
/* 10 */ "SELECT coalesce((SELECT max(blockid) FROM %Q.'%q_segments') + 1, 1)",
-/* 11 */ "INSERT INTO %Q.'%q_segdir' VALUES(?,?,?,?,?,?)",
+/* 11 */ "REPLACE INTO %Q.'%q_segdir' VALUES(?,?,?,?,?,?)",
/* Return segments in order from oldest to newest.*/
/* 12 */ "SELECT idx, start_block, leaves_end_block, end_block, root "
@@ -119926,13 +126604,61 @@ static int fts3SqlStmt(
/* 19 */ "DELETE FROM %Q.'%q_docsize' WHERE docid = ?",
/* 20 */ "REPLACE INTO %Q.'%q_docsize' VALUES(?,?)",
/* 21 */ "SELECT size FROM %Q.'%q_docsize' WHERE docid=?",
-/* 22 */ "SELECT value FROM %Q.'%q_stat' WHERE id=0",
-/* 23 */ "REPLACE INTO %Q.'%q_stat' VALUES(0,?)",
+/* 22 */ "SELECT value FROM %Q.'%q_stat' WHERE id=?",
+/* 23 */ "REPLACE INTO %Q.'%q_stat' VALUES(?,?)",
/* 24 */ "",
/* 25 */ "",
/* 26 */ "DELETE FROM %Q.'%q_segdir' WHERE level BETWEEN ? AND ?",
-
+/* 27 */ "SELECT DISTINCT level / (1024 * ?) FROM %Q.'%q_segdir'",
+
+/* This statement is used to determine which level to read the input from
+** when performing an incremental merge. It returns the absolute level number
+** of the oldest level in the db that contains at least ? segments. Or,
+** if no level in the FTS index contains more than ? segments, the statement
+** returns zero rows. */
+/* 28 */ "SELECT level FROM %Q.'%q_segdir' GROUP BY level HAVING count(*)>=?"
+ " ORDER BY (level %% 1024) ASC LIMIT 1",
+
+/* Estimate the upper limit on the number of leaf nodes in a new segment
+** created by merging the oldest :2 segments from absolute level :1. See
+** function sqlite3Fts3Incrmerge() for details. */
+/* 29 */ "SELECT 2 * total(1 + leaves_end_block - start_block) "
+ " FROM %Q.'%q_segdir' WHERE level = ? AND idx < ?",
+
+/* SQL_DELETE_SEGDIR_ENTRY
+** Delete the %_segdir entry on absolute level :1 with index :2. */
+/* 30 */ "DELETE FROM %Q.'%q_segdir' WHERE level = ? AND idx = ?",
+
+/* SQL_SHIFT_SEGDIR_ENTRY
+** Modify the idx value for the segment with idx=:3 on absolute level :2
+** to :1. */
+/* 31 */ "UPDATE %Q.'%q_segdir' SET idx = ? WHERE level=? AND idx=?",
+
+/* SQL_SELECT_SEGDIR
+** Read a single entry from the %_segdir table. The entry from absolute
+** level :1 with index value :2. */
+/* 32 */ "SELECT idx, start_block, leaves_end_block, end_block, root "
+ "FROM %Q.'%q_segdir' WHERE level = ? AND idx = ?",
+
+/* SQL_CHOMP_SEGDIR
+** Update the start_block (:1) and root (:2) fields of the %_segdir
+** entry located on absolute level :3 with index :4. */
+/* 33 */ "UPDATE %Q.'%q_segdir' SET start_block = ?, root = ?"
+ "WHERE level = ? AND idx = ?",
+
+/* SQL_SEGMENT_IS_APPENDABLE
+** Return a single row if the segment with end_block=? is appendable. Or
+** no rows otherwise. */
+/* 34 */ "SELECT 1 FROM %Q.'%q_segments' WHERE blockid=? AND block IS NULL",
+
+/* SQL_SELECT_INDEXES
+** Return the list of valid segment indexes for absolute level ? */
+/* 35 */ "SELECT idx FROM %Q.'%q_segdir' WHERE level=? ORDER BY 1 ASC",
+
+/* SQL_SELECT_MXLEVEL
+** Return the largest relative level in the FTS index or indexes. */
+/* 36 */ "SELECT max( level %% 1024 ) FROM %Q.'%q_segdir'"
};
int rc = SQLITE_OK;
sqlite3_stmt *pStmt;
@@ -119946,7 +126672,7 @@ static int fts3SqlStmt(
if( eStmt==SQL_CONTENT_INSERT ){
zSql = sqlite3_mprintf(azSql[eStmt], p->zDb, p->zName, p->zWriteExprlist);
}else if( eStmt==SQL_SELECT_CONTENT_BY_ROWID ){
- zSql = sqlite3_mprintf(azSql[eStmt], p->zReadExprlist, p->zDb, p->zName);
+ zSql = sqlite3_mprintf(azSql[eStmt], p->zReadExprlist);
}else{
zSql = sqlite3_mprintf(azSql[eStmt], p->zDb, p->zName);
}
@@ -119970,26 +126696,22 @@ static int fts3SqlStmt(
return rc;
}
+
static int fts3SelectDocsize(
Fts3Table *pTab, /* FTS3 table handle */
- int eStmt, /* Either SQL_SELECT_DOCSIZE or DOCTOTAL */
sqlite3_int64 iDocid, /* Docid to bind for SQL_SELECT_DOCSIZE */
sqlite3_stmt **ppStmt /* OUT: Statement handle */
){
sqlite3_stmt *pStmt = 0; /* Statement requested from fts3SqlStmt() */
int rc; /* Return code */
- assert( eStmt==SQL_SELECT_DOCSIZE || eStmt==SQL_SELECT_DOCTOTAL );
-
- rc = fts3SqlStmt(pTab, eStmt, &pStmt, 0);
+ rc = fts3SqlStmt(pTab, SQL_SELECT_DOCSIZE, &pStmt, 0);
if( rc==SQLITE_OK ){
- if( eStmt==SQL_SELECT_DOCSIZE ){
- sqlite3_bind_int64(pStmt, 1, iDocid);
- }
+ sqlite3_bind_int64(pStmt, 1, iDocid);
rc = sqlite3_step(pStmt);
if( rc!=SQLITE_ROW || sqlite3_column_type(pStmt, 0)!=SQLITE_BLOB ){
rc = sqlite3_reset(pStmt);
- if( rc==SQLITE_OK ) rc = SQLITE_CORRUPT_VTAB;
+ if( rc==SQLITE_OK ) rc = FTS_CORRUPT_VTAB;
pStmt = 0;
}else{
rc = SQLITE_OK;
@@ -120004,7 +126726,21 @@ SQLITE_PRIVATE int sqlite3Fts3SelectDoctotal(
Fts3Table *pTab, /* Fts3 table handle */
sqlite3_stmt **ppStmt /* OUT: Statement handle */
){
- return fts3SelectDocsize(pTab, SQL_SELECT_DOCTOTAL, 0, ppStmt);
+ sqlite3_stmt *pStmt = 0;
+ int rc;
+ rc = fts3SqlStmt(pTab, SQL_SELECT_STAT, &pStmt, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_int(pStmt, 1, FTS_STAT_DOCTOTAL);
+ if( sqlite3_step(pStmt)!=SQLITE_ROW
+ || sqlite3_column_type(pStmt, 0)!=SQLITE_BLOB
+ ){
+ rc = sqlite3_reset(pStmt);
+ if( rc==SQLITE_OK ) rc = FTS_CORRUPT_VTAB;
+ pStmt = 0;
+ }
+ }
+ *ppStmt = pStmt;
+ return rc;
}
SQLITE_PRIVATE int sqlite3Fts3SelectDocsize(
@@ -120012,7 +126748,7 @@ SQLITE_PRIVATE int sqlite3Fts3SelectDocsize(
sqlite3_int64 iDocid, /* Docid to read size data for */
sqlite3_stmt **ppStmt /* OUT: Statement handle */
){
- return fts3SelectDocsize(pTab, SQL_SELECT_DOCSIZE, iDocid, ppStmt);
+ return fts3SelectDocsize(pTab, iDocid, ppStmt);
}
/*
@@ -120057,21 +126793,66 @@ static void fts3SqlExec(
** not what users expect when they get SQLITE_LOCKED_SHAREDCACHE. It can
** still happen if the user reads data directly from the %_segments or
** %_segdir tables instead of going through FTS3 though.
+**
+** This reasoning does not apply to a content=xxx table.
*/
SQLITE_PRIVATE int sqlite3Fts3ReadLock(Fts3Table *p){
int rc; /* Return code */
sqlite3_stmt *pStmt; /* Statement used to obtain lock */
- rc = fts3SqlStmt(p, SQL_SELECT_CONTENT_BY_ROWID, &pStmt, 0);
- if( rc==SQLITE_OK ){
- sqlite3_bind_null(pStmt, 1);
- sqlite3_step(pStmt);
- rc = sqlite3_reset(pStmt);
+ if( p->zContentTbl==0 ){
+ rc = fts3SqlStmt(p, SQL_SELECT_CONTENT_BY_ROWID, &pStmt, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_null(pStmt, 1);
+ sqlite3_step(pStmt);
+ rc = sqlite3_reset(pStmt);
+ }
+ }else{
+ rc = SQLITE_OK;
}
+
return rc;
}
/*
+** FTS maintains a separate indexes for each language-id (a 32-bit integer).
+** Within each language id, a separate index is maintained to store the
+** document terms, and each configured prefix size (configured the FTS
+** "prefix=" option). And each index consists of multiple levels ("relative
+** levels").
+**
+** All three of these values (the language id, the specific index and the
+** level within the index) are encoded in 64-bit integer values stored
+** in the %_segdir table on disk. This function is used to convert three
+** separate component values into the single 64-bit integer value that
+** can be used to query the %_segdir table.
+**
+** Specifically, each language-id/index combination is allocated 1024
+** 64-bit integer level values ("absolute levels"). The main terms index
+** for language-id 0 is allocate values 0-1023. The first prefix index
+** (if any) for language-id 0 is allocated values 1024-2047. And so on.
+** Language 1 indexes are allocated immediately following language 0.
+**
+** So, for a system with nPrefix prefix indexes configured, the block of
+** absolute levels that corresponds to language-id iLangid and index
+** iIndex starts at absolute level ((iLangid * (nPrefix+1) + iIndex) * 1024).
+*/
+static sqlite3_int64 getAbsoluteLevel(
+ Fts3Table *p, /* FTS3 table handle */
+ int iLangid, /* Language id */
+ int iIndex, /* Index in p->aIndex[] */
+ int iLevel /* Level of segments */
+){
+ sqlite3_int64 iBase; /* First absolute level for iLangid/iIndex */
+ assert( iLangid>=0 );
+ assert( p->nIndex>0 );
+ assert( iIndex>=0 && iIndex<p->nIndex );
+
+ iBase = ((sqlite3_int64)iLangid * p->nIndex + iIndex) * FTS3_SEGDIR_MAXLEVEL;
+ return iBase + iLevel;
+}
+
+/*
** Set *ppStmt to a statement handle that may be used to iterate through
** all rows in the %_segdir table, from oldest to newest. If successful,
** return SQLITE_OK. If an error occurs while preparing the statement,
@@ -120090,8 +126871,9 @@ SQLITE_PRIVATE int sqlite3Fts3ReadLock(Fts3Table *p){
*/
SQLITE_PRIVATE int sqlite3Fts3AllSegdirs(
Fts3Table *p, /* FTS3 table */
+ int iLangid, /* Language being queried */
int iIndex, /* Index for p->aIndex[] */
- int iLevel, /* Level to select */
+ int iLevel, /* Level to select (relative level) */
sqlite3_stmt **ppStmt /* OUT: Compiled statement */
){
int rc;
@@ -120105,14 +126887,16 @@ SQLITE_PRIVATE int sqlite3Fts3AllSegdirs(
/* "SELECT * FROM %_segdir WHERE level BETWEEN ? AND ? ORDER BY ..." */
rc = fts3SqlStmt(p, SQL_SELECT_LEVEL_RANGE, &pStmt, 0);
if( rc==SQLITE_OK ){
- sqlite3_bind_int(pStmt, 1, iIndex*FTS3_SEGDIR_MAXLEVEL);
- sqlite3_bind_int(pStmt, 2, (iIndex+1)*FTS3_SEGDIR_MAXLEVEL-1);
+ sqlite3_bind_int64(pStmt, 1, getAbsoluteLevel(p, iLangid, iIndex, 0));
+ sqlite3_bind_int64(pStmt, 2,
+ getAbsoluteLevel(p, iLangid, iIndex, FTS3_SEGDIR_MAXLEVEL-1)
+ );
}
}else{
/* "SELECT * FROM %_segdir WHERE level = ? ORDER BY ..." */
rc = fts3SqlStmt(p, SQL_SELECT_LEVEL, &pStmt, 0);
if( rc==SQLITE_OK ){
- sqlite3_bind_int(pStmt, 1, iLevel+iIndex*FTS3_SEGDIR_MAXLEVEL);
+ sqlite3_bind_int64(pStmt, 1, getAbsoluteLevel(p, iLangid, iIndex,iLevel));
}
}
*ppStmt = pStmt;
@@ -120278,18 +127062,19 @@ static int fts3PendingTermsAddOne(
*/
static int fts3PendingTermsAdd(
Fts3Table *p, /* Table into which text will be inserted */
+ int iLangid, /* Language id to use */
const char *zText, /* Text of document to be inserted */
int iCol, /* Column into which text is being inserted */
- u32 *pnWord /* OUT: Number of tokens inserted */
+ u32 *pnWord /* IN/OUT: Incr. by number tokens inserted */
){
int rc;
- int iStart;
- int iEnd;
- int iPos;
+ int iStart = 0;
+ int iEnd = 0;
+ int iPos = 0;
int nWord = 0;
char const *zToken;
- int nToken;
+ int nToken = 0;
sqlite3_tokenizer *pTokenizer = p->pTokenizer;
sqlite3_tokenizer_module const *pModule = pTokenizer->pModule;
@@ -120307,11 +127092,10 @@ static int fts3PendingTermsAdd(
return SQLITE_OK;
}
- rc = pModule->xOpen(pTokenizer, zText, -1, &pCsr);
+ rc = sqlite3Fts3OpenTokenizer(pTokenizer, iLangid, zText, -1, &pCsr);
if( rc!=SQLITE_OK ){
return rc;
}
- pCsr->pTokenizer = pTokenizer;
xNext = pModule->xNext;
while( SQLITE_OK==rc
@@ -120345,7 +127129,7 @@ static int fts3PendingTermsAdd(
}
pModule->xClose(pCsr);
- *pnWord = nWord;
+ *pnWord += nWord;
return (rc==SQLITE_DONE ? SQLITE_OK : rc);
}
@@ -120354,18 +127138,28 @@ static int fts3PendingTermsAdd(
** fts3PendingTermsAdd() are to add term/position-list pairs for the
** contents of the document with docid iDocid.
*/
-static int fts3PendingTermsDocid(Fts3Table *p, sqlite_int64 iDocid){
+static int fts3PendingTermsDocid(
+ Fts3Table *p, /* Full-text table handle */
+ int iLangid, /* Language id of row being written */
+ sqlite_int64 iDocid /* Docid of row being written */
+){
+ assert( iLangid>=0 );
+
/* TODO(shess) Explore whether partially flushing the buffer on
** forced-flush would provide better performance. I suspect that if
** we ordered the doclists by size and flushed the largest until the
** buffer was half empty, that would let the less frequent terms
** generate longer doclists.
*/
- if( iDocid<=p->iPrevDocid || p->nPendingData>p->nMaxPendingData ){
+ if( iDocid<=p->iPrevDocid
+ || p->iPrevLangid!=iLangid
+ || p->nPendingData>p->nMaxPendingData
+ ){
int rc = sqlite3Fts3PendingTermsFlush(p);
if( rc!=SQLITE_OK ) return rc;
}
p->iPrevDocid = iDocid;
+ p->iPrevLangid = iLangid;
return SQLITE_OK;
}
@@ -120394,11 +127188,16 @@ SQLITE_PRIVATE void sqlite3Fts3PendingTermsClear(Fts3Table *p){
** Argument apVal is the same as the similarly named argument passed to
** fts3InsertData(). Parameter iDocid is the docid of the new row.
*/
-static int fts3InsertTerms(Fts3Table *p, sqlite3_value **apVal, u32 *aSz){
+static int fts3InsertTerms(
+ Fts3Table *p,
+ int iLangid,
+ sqlite3_value **apVal,
+ u32 *aSz
+){
int i; /* Iterator variable */
for(i=2; i<p->nColumn+2; i++){
const char *zText = (const char *)sqlite3_value_text(apVal[i]);
- int rc = fts3PendingTermsAdd(p, zText, i-2, &aSz[i-2]);
+ int rc = fts3PendingTermsAdd(p, iLangid, zText, i-2, &aSz[i-2]);
if( rc!=SQLITE_OK ){
return rc;
}
@@ -120419,6 +127218,7 @@ static int fts3InsertTerms(Fts3Table *p, sqlite3_value **apVal, u32 *aSz){
** apVal[p->nColumn+1] Right-most user-defined column
** apVal[p->nColumn+2] Hidden column with same name as table
** apVal[p->nColumn+3] Hidden "docid" column (alias for rowid)
+** apVal[p->nColumn+4] Hidden languageid column
*/
static int fts3InsertData(
Fts3Table *p, /* Full-text table */
@@ -120428,6 +127228,18 @@ static int fts3InsertData(
int rc; /* Return code */
sqlite3_stmt *pContentInsert; /* INSERT INTO %_content VALUES(...) */
+ if( p->zContentTbl ){
+ sqlite3_value *pRowid = apVal[p->nColumn+3];
+ if( sqlite3_value_type(pRowid)==SQLITE_NULL ){
+ pRowid = apVal[1];
+ }
+ if( sqlite3_value_type(pRowid)!=SQLITE_INTEGER ){
+ return SQLITE_CONSTRAINT;
+ }
+ *piDocid = sqlite3_value_int64(pRowid);
+ return SQLITE_OK;
+ }
+
/* Locate the statement handle used to insert data into the %_content
** table. The SQL for this statement is:
**
@@ -120437,9 +127249,13 @@ static int fts3InsertData(
** defined columns in the FTS3 table, plus one for the docid field.
*/
rc = fts3SqlStmt(p, SQL_CONTENT_INSERT, &pContentInsert, &apVal[1]);
- if( rc!=SQLITE_OK ){
- return rc;
+ if( rc==SQLITE_OK && p->zLanguageid ){
+ rc = sqlite3_bind_int(
+ pContentInsert, p->nColumn+2,
+ sqlite3_value_int(apVal[p->nColumn+4])
+ );
}
+ if( rc!=SQLITE_OK ) return rc;
/* There is a quirk here. The users INSERT statement may have specified
** a value for the "rowid" field, for the "docid" field, or for both.
@@ -120478,14 +127294,16 @@ static int fts3InsertData(
** Remove all data from the FTS3 table. Clear the hash table containing
** pending terms.
*/
-static int fts3DeleteAll(Fts3Table *p){
+static int fts3DeleteAll(Fts3Table *p, int bContent){
int rc = SQLITE_OK; /* Return code */
/* Discard the contents of the pending-terms hash table. */
sqlite3Fts3PendingTermsClear(p);
- /* Delete everything from the %_content, %_segments and %_segdir tables. */
- fts3SqlExec(&rc, p, SQL_DELETE_ALL_CONTENT, 0);
+ /* Delete everything from the shadow tables. Except, leave %_content as
+ ** is if bContent is false. */
+ assert( p->zContentTbl==0 || bContent==0 );
+ if( bContent ) fts3SqlExec(&rc, p, SQL_DELETE_ALL_CONTENT, 0);
fts3SqlExec(&rc, p, SQL_DELETE_ALL_SEGMENTS, 0);
fts3SqlExec(&rc, p, SQL_DELETE_ALL_SEGDIR, 0);
if( p->bHasDocsize ){
@@ -120498,6 +127316,15 @@ static int fts3DeleteAll(Fts3Table *p){
}
/*
+**
+*/
+static int langidFromSelect(Fts3Table *p, sqlite3_stmt *pSelect){
+ int iLangid = 0;
+ if( p->zLanguageid ) iLangid = sqlite3_column_int(pSelect, p->nColumn+1);
+ return iLangid;
+}
+
+/*
** The first element in the apVal[] array is assumed to contain the docid
** (an integer) of a row about to be deleted. Remove all terms from the
** full-text index.
@@ -120506,26 +127333,31 @@ static void fts3DeleteTerms(
int *pRC, /* Result code */
Fts3Table *p, /* The FTS table to delete from */
sqlite3_value *pRowid, /* The docid to be deleted */
- u32 *aSz /* Sizes of deleted document written here */
+ u32 *aSz, /* Sizes of deleted document written here */
+ int *pbFound /* OUT: Set to true if row really does exist */
){
int rc;
sqlite3_stmt *pSelect;
+ assert( *pbFound==0 );
if( *pRC ) return;
rc = fts3SqlStmt(p, SQL_SELECT_CONTENT_BY_ROWID, &pSelect, &pRowid);
if( rc==SQLITE_OK ){
if( SQLITE_ROW==sqlite3_step(pSelect) ){
int i;
- for(i=1; i<=p->nColumn; i++){
+ int iLangid = langidFromSelect(p, pSelect);
+ rc = fts3PendingTermsDocid(p, iLangid, sqlite3_column_int64(pSelect, 0));
+ for(i=1; rc==SQLITE_OK && i<=p->nColumn; i++){
const char *zText = (const char *)sqlite3_column_text(pSelect, i);
- rc = fts3PendingTermsAdd(p, zText, -1, &aSz[i-1]);
- if( rc!=SQLITE_OK ){
- sqlite3_reset(pSelect);
- *pRC = rc;
- return;
- }
+ rc = fts3PendingTermsAdd(p, iLangid, zText, -1, &aSz[i-1]);
aSz[p->nColumn] += sqlite3_column_bytes(pSelect, i);
}
+ if( rc!=SQLITE_OK ){
+ sqlite3_reset(pSelect);
+ *pRC = rc;
+ return;
+ }
+ *pbFound = 1;
}
rc = sqlite3_reset(pSelect);
}else{
@@ -120538,7 +127370,7 @@ static void fts3DeleteTerms(
** Forward declaration to account for the circular dependency between
** functions fts3SegmentMerge() and fts3AllocateSegdirIdx().
*/
-static int fts3SegmentMerge(Fts3Table *, int, int);
+static int fts3SegmentMerge(Fts3Table *, int, int, int);
/*
** This function allocates a new level iLevel index in the segdir table.
@@ -120557,6 +127389,7 @@ static int fts3SegmentMerge(Fts3Table *, int, int);
*/
static int fts3AllocateSegdirIdx(
Fts3Table *p,
+ int iLangid, /* Language id */
int iIndex, /* Index for p->aIndex */
int iLevel,
int *piIdx
@@ -120565,10 +127398,15 @@ static int fts3AllocateSegdirIdx(
sqlite3_stmt *pNextIdx; /* Query for next idx at level iLevel */
int iNext = 0; /* Result of query pNextIdx */
+ assert( iLangid>=0 );
+ assert( p->nIndex>=1 );
+
/* Set variable iNext to the next available segdir index at level iLevel. */
rc = fts3SqlStmt(p, SQL_NEXT_SEGMENT_INDEX, &pNextIdx, 0);
if( rc==SQLITE_OK ){
- sqlite3_bind_int(pNextIdx, 1, iIndex*FTS3_SEGDIR_MAXLEVEL + iLevel);
+ sqlite3_bind_int64(
+ pNextIdx, 1, getAbsoluteLevel(p, iLangid, iIndex, iLevel)
+ );
if( SQLITE_ROW==sqlite3_step(pNextIdx) ){
iNext = sqlite3_column_int(pNextIdx, 0);
}
@@ -120582,7 +127420,8 @@ static int fts3AllocateSegdirIdx(
** if iNext is less than FTS3_MERGE_COUNT, allocate index iNext.
*/
if( iNext>=FTS3_MERGE_COUNT ){
- rc = fts3SegmentMerge(p, iIndex, iLevel);
+ fts3LogMerge(16, getAbsoluteLevel(p, iLangid, iIndex, iLevel));
+ rc = fts3SegmentMerge(p, iLangid, iIndex, iLevel);
*piIdx = 0;
}else{
*piIdx = iNext;
@@ -120629,7 +127468,7 @@ SQLITE_PRIVATE int sqlite3Fts3ReadBlock(
int rc; /* Return code */
/* pnBlob must be non-NULL. paBlob may be NULL or non-NULL. */
- assert( pnBlob);
+ assert( pnBlob );
if( p->pSegments ){
rc = sqlite3_blob_reopen(p->pSegments, iBlockid);
@@ -120716,6 +127555,18 @@ static int fts3SegReaderRequire(Fts3SegReader *pReader, char *pFrom, int nByte){
}
/*
+** Set an Fts3SegReader cursor to point at EOF.
+*/
+static void fts3SegReaderSetEof(Fts3SegReader *pSeg){
+ if( !fts3SegReaderIsRootOnly(pSeg) ){
+ sqlite3_free(pSeg->aNode);
+ sqlite3_blob_close(pSeg->pBlob);
+ pSeg->pBlob = 0;
+ }
+ pSeg->aNode = 0;
+}
+
+/*
** Move the iterator passed as the first argument to the next term in the
** segment. If successful, SQLITE_OK is returned. If there is no next term,
** SQLITE_DONE. Otherwise, an SQLite error code.
@@ -120754,12 +127605,7 @@ static int fts3SegReaderNext(
return SQLITE_OK;
}
- if( !fts3SegReaderIsRootOnly(pReader) ){
- sqlite3_free(pReader->aNode);
- sqlite3_blob_close(pReader->pBlob);
- pReader->pBlob = 0;
- }
- pReader->aNode = 0;
+ fts3SegReaderSetEof(pReader);
/* If iCurrentBlock>=iLeafEndBlock, this is an EOF condition. All leaf
** blocks have already been traversed. */
@@ -120793,7 +127639,7 @@ static int fts3SegReaderNext(
if( nPrefix<0 || nSuffix<=0
|| &pNext[nSuffix]>&pReader->aNode[pReader->nNode]
){
- return SQLITE_CORRUPT_VTAB;
+ return FTS_CORRUPT_VTAB;
}
if( nPrefix+nSuffix>pReader->nTermAlloc ){
@@ -120823,7 +127669,7 @@ static int fts3SegReaderNext(
if( &pReader->aDoclist[pReader->nDoclist]>&pReader->aNode[pReader->nNode]
|| (pReader->nPopulate==0 && pReader->aDoclist[pReader->nDoclist-1])
){
- return SQLITE_CORRUPT_VTAB;
+ return FTS_CORRUPT_VTAB;
}
return SQLITE_OK;
}
@@ -120925,6 +127771,7 @@ static int fts3SegReaderNextDocid(
*pnOffsetList = (int)(p - pReader->pOffsetList - 1);
}
+ /* List may have been edited in place by fts3EvalNearTrim() */
while( p<pEnd && *p==0 ) p++;
/* If there are no more entries in the doclist, set pOffsetList to
@@ -120963,7 +127810,7 @@ SQLITE_PRIVATE int sqlite3Fts3MsrOvfl(
int rc = SQLITE_OK;
int pgsz = p->nPgsz;
- assert( p->bHasStat );
+ assert( p->bFts4 );
assert( pgsz>0 );
for(ii=0; rc==SQLITE_OK && ii<pMsr->nSegment; ii++){
@@ -121006,6 +127853,7 @@ SQLITE_PRIVATE void sqlite3Fts3SegReaderFree(Fts3SegReader *pReader){
*/
SQLITE_PRIVATE int sqlite3Fts3SegReaderNew(
int iAge, /* Segment "age". */
+ int bLookup, /* True for a lookup only */
sqlite3_int64 iStartLeaf, /* First leaf to traverse */
sqlite3_int64 iEndLeaf, /* Final leaf to traverse */
sqlite3_int64 iEndBlock, /* Final block of segment */
@@ -121013,7 +127861,6 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderNew(
int nRoot, /* Size of buffer containing root node */
Fts3SegReader **ppReader /* OUT: Allocated Fts3SegReader */
){
- int rc = SQLITE_OK; /* Return code */
Fts3SegReader *pReader; /* Newly allocated SegReader object */
int nExtra = 0; /* Bytes to allocate segment root node */
@@ -121028,6 +127875,7 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderNew(
}
memset(pReader, 0, sizeof(Fts3SegReader));
pReader->iIdx = iAge;
+ pReader->bLookup = bLookup!=0;
pReader->iStartBlock = iStartLeaf;
pReader->iLeafEndBlock = iEndLeaf;
pReader->iEndBlock = iEndBlock;
@@ -121035,19 +127883,15 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderNew(
if( nExtra ){
/* The entire segment is stored in the root node. */
pReader->aNode = (char *)&pReader[1];
+ pReader->rootOnly = 1;
pReader->nNode = nRoot;
memcpy(pReader->aNode, zRoot, nRoot);
memset(&pReader->aNode[nRoot], 0, FTS3_NODE_PADDING);
}else{
pReader->iCurrentBlock = iStartLeaf-1;
}
-
- if( rc==SQLITE_OK ){
- *ppReader = pReader;
- }else{
- sqlite3Fts3SegReaderFree(pReader);
- }
- return rc;
+ *ppReader = pReader;
+ return SQLITE_OK;
}
/*
@@ -121097,6 +127941,7 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderPending(
Fts3SegReader **ppReader /* OUT: SegReader for pending-terms */
){
Fts3SegReader *pReader = 0; /* Fts3SegReader object to return */
+ Fts3HashElem *pE; /* Iterator variable */
Fts3HashElem **aElem = 0; /* Array of term hash entries to scan */
int nElem = 0; /* Size of array at aElem */
int rc = SQLITE_OK; /* Return Code */
@@ -121105,7 +127950,6 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderPending(
pHash = &p->aIndex[iIndex].hPending;
if( bPrefix ){
int nAlloc = 0; /* Size of allocated array at aElem */
- Fts3HashElem *pE = 0; /* Iterator variable */
for(pE=fts3HashFirst(pHash); pE; pE=fts3HashNext(pE)){
char *zKey = (char *)fts3HashKey(pE);
@@ -121139,8 +127983,13 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderPending(
}else{
/* The query is a simple term lookup that matches at most one term in
- ** the index. All that is required is a straight hash-lookup. */
- Fts3HashElem *pE = fts3HashFindElem(pHash, zTerm, nTerm);
+ ** the index. All that is required is a straight hash-lookup.
+ **
+ ** Because the stack address of pE may be accessed via the aElem pointer
+ ** below, the "Fts3HashElem *pE" must be declared so that it is valid
+ ** within this entire function, not just this "else{...}" block.
+ */
+ pE = fts3HashFindElem(pHash, zTerm, nTerm);
if( pE ){
aElem = &pE;
nElem = 1;
@@ -121320,12 +128169,33 @@ static int fts3WriteSegment(
return rc;
}
+/*
+** Find the largest relative level number in the table. If successful, set
+** *pnMax to this value and return SQLITE_OK. Otherwise, if an error occurs,
+** set *pnMax to zero and return an SQLite error code.
+*/
+SQLITE_PRIVATE int sqlite3Fts3MaxLevel(Fts3Table *p, int *pnMax){
+ int rc;
+ int mxLevel = 0;
+ sqlite3_stmt *pStmt = 0;
+
+ rc = fts3SqlStmt(p, SQL_SELECT_MXLEVEL, &pStmt, 0);
+ if( rc==SQLITE_OK ){
+ if( SQLITE_ROW==sqlite3_step(pStmt) ){
+ mxLevel = sqlite3_column_int(pStmt, 0);
+ }
+ rc = sqlite3_reset(pStmt);
+ }
+ *pnMax = mxLevel;
+ return rc;
+}
+
/*
** Insert a record into the %_segdir table.
*/
static int fts3WriteSegdir(
Fts3Table *p, /* Virtual table handle */
- int iLevel, /* Value for "level" field */
+ sqlite3_int64 iLevel, /* Value for "level" field (absolute level) */
int iIdx, /* Value for "idx" field */
sqlite3_int64 iStartBlock, /* Value for "start_block" field */
sqlite3_int64 iLeafEndBlock, /* Value for "leaves_end_block" field */
@@ -121336,7 +128206,7 @@ static int fts3WriteSegdir(
sqlite3_stmt *pStmt;
int rc = fts3SqlStmt(p, SQL_INSERT_SEGDIR, &pStmt, 0);
if( rc==SQLITE_OK ){
- sqlite3_bind_int(pStmt, 1, iLevel);
+ sqlite3_bind_int64(pStmt, 1, iLevel);
sqlite3_bind_int(pStmt, 2, iIdx);
sqlite3_bind_int64(pStmt, 3, iStartBlock);
sqlite3_bind_int64(pStmt, 4, iLeafEndBlock);
@@ -121636,6 +128506,7 @@ static int fts3SegWriterAdd(
/* The current leaf node is full. Write it out to the database. */
rc = fts3WriteSegment(p, pWriter->iFree++, pWriter->aData, nData);
if( rc!=SQLITE_OK ) return rc;
+ p->nLeafAdd++;
/* Add the current term to the interior node tree. The term added to
** the interior tree must:
@@ -121719,7 +128590,7 @@ static int fts3SegWriterAdd(
static int fts3SegWriterFlush(
Fts3Table *p, /* Virtual table handle */
SegmentWriter *pWriter, /* SegmentWriter to flush to the db */
- int iLevel, /* Value for 'level' column of %_segdir */
+ sqlite3_int64 iLevel, /* Value for 'level' column of %_segdir */
int iIdx /* Value for 'idx' column of %_segdir */
){
int rc; /* Return code */
@@ -121744,6 +128615,7 @@ static int fts3SegWriterFlush(
rc = fts3WriteSegdir(
p, iLevel, iIdx, 0, 0, 0, pWriter->aData, pWriter->nData);
}
+ p->nLeafAdd++;
return rc;
}
@@ -121773,12 +128645,18 @@ static void fts3SegWriterFree(SegmentWriter *pWriter){
static int fts3IsEmpty(Fts3Table *p, sqlite3_value *pRowid, int *pisEmpty){
sqlite3_stmt *pStmt;
int rc;
- rc = fts3SqlStmt(p, SQL_IS_EMPTY, &pStmt, &pRowid);
- if( rc==SQLITE_OK ){
- if( SQLITE_ROW==sqlite3_step(pStmt) ){
- *pisEmpty = sqlite3_column_int(pStmt, 0);
+ if( p->zContentTbl ){
+ /* If using the content=xxx option, assume the table is never empty */
+ *pisEmpty = 0;
+ rc = SQLITE_OK;
+ }else{
+ rc = fts3SqlStmt(p, SQL_IS_EMPTY, &pStmt, &pRowid);
+ if( rc==SQLITE_OK ){
+ if( SQLITE_ROW==sqlite3_step(pStmt) ){
+ *pisEmpty = sqlite3_column_int(pStmt, 0);
+ }
+ rc = sqlite3_reset(pStmt);
}
- rc = sqlite3_reset(pStmt);
}
return rc;
}
@@ -121791,7 +128669,12 @@ static int fts3IsEmpty(Fts3Table *p, sqlite3_value *pRowid, int *pisEmpty){
**
** Return SQLITE_OK if successful, or an SQLite error code if not.
*/
-static int fts3SegmentMaxLevel(Fts3Table *p, int iIndex, int *pnMax){
+static int fts3SegmentMaxLevel(
+ Fts3Table *p,
+ int iLangid,
+ int iIndex,
+ sqlite3_int64 *pnMax
+){
sqlite3_stmt *pStmt;
int rc;
assert( iIndex>=0 && iIndex<p->nIndex );
@@ -121804,15 +128687,40 @@ static int fts3SegmentMaxLevel(Fts3Table *p, int iIndex, int *pnMax){
*/
rc = fts3SqlStmt(p, SQL_SELECT_SEGDIR_MAX_LEVEL, &pStmt, 0);
if( rc!=SQLITE_OK ) return rc;
- sqlite3_bind_int(pStmt, 1, iIndex*FTS3_SEGDIR_MAXLEVEL);
- sqlite3_bind_int(pStmt, 2, (iIndex+1)*FTS3_SEGDIR_MAXLEVEL - 1);
+ sqlite3_bind_int64(pStmt, 1, getAbsoluteLevel(p, iLangid, iIndex, 0));
+ sqlite3_bind_int64(pStmt, 2,
+ getAbsoluteLevel(p, iLangid, iIndex, FTS3_SEGDIR_MAXLEVEL-1)
+ );
if( SQLITE_ROW==sqlite3_step(pStmt) ){
- *pnMax = sqlite3_column_int(pStmt, 0);
+ *pnMax = sqlite3_column_int64(pStmt, 0);
}
return sqlite3_reset(pStmt);
}
/*
+** Delete all entries in the %_segments table associated with the segment
+** opened with seg-reader pSeg. This function does not affect the contents
+** of the %_segdir table.
+*/
+static int fts3DeleteSegment(
+ Fts3Table *p, /* FTS table handle */
+ Fts3SegReader *pSeg /* Segment to delete */
+){
+ int rc = SQLITE_OK; /* Return code */
+ if( pSeg->iStartBlock ){
+ sqlite3_stmt *pDelete; /* SQL statement to delete rows */
+ rc = fts3SqlStmt(p, SQL_DELETE_SEGMENTS_RANGE, &pDelete, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_int64(pDelete, 1, pSeg->iStartBlock);
+ sqlite3_bind_int64(pDelete, 2, pSeg->iEndBlock);
+ sqlite3_step(pDelete);
+ rc = sqlite3_reset(pDelete);
+ }
+ }
+ return rc;
+}
+
+/*
** This function is used after merging multiple segments into a single large
** segment to delete the old, now redundant, segment b-trees. Specifically,
** it:
@@ -121828,24 +128736,18 @@ static int fts3SegmentMaxLevel(Fts3Table *p, int iIndex, int *pnMax){
*/
static int fts3DeleteSegdir(
Fts3Table *p, /* Virtual table handle */
+ int iLangid, /* Language id */
int iIndex, /* Index for p->aIndex */
int iLevel, /* Level of %_segdir entries to delete */
Fts3SegReader **apSegment, /* Array of SegReader objects */
int nReader /* Size of array apSegment */
){
- int rc; /* Return Code */
+ int rc = SQLITE_OK; /* Return Code */
int i; /* Iterator variable */
- sqlite3_stmt *pDelete; /* SQL statement to delete rows */
+ sqlite3_stmt *pDelete = 0; /* SQL statement to delete rows */
- rc = fts3SqlStmt(p, SQL_DELETE_SEGMENTS_RANGE, &pDelete, 0);
for(i=0; rc==SQLITE_OK && i<nReader; i++){
- Fts3SegReader *pSegment = apSegment[i];
- if( pSegment->iStartBlock ){
- sqlite3_bind_int64(pDelete, 1, pSegment->iStartBlock);
- sqlite3_bind_int64(pDelete, 2, pSegment->iEndBlock);
- sqlite3_step(pDelete);
- rc = sqlite3_reset(pDelete);
- }
+ rc = fts3DeleteSegment(p, apSegment[i]);
}
if( rc!=SQLITE_OK ){
return rc;
@@ -121855,13 +128757,17 @@ static int fts3DeleteSegdir(
if( iLevel==FTS3_SEGCURSOR_ALL ){
rc = fts3SqlStmt(p, SQL_DELETE_SEGDIR_RANGE, &pDelete, 0);
if( rc==SQLITE_OK ){
- sqlite3_bind_int(pDelete, 1, iIndex*FTS3_SEGDIR_MAXLEVEL);
- sqlite3_bind_int(pDelete, 2, (iIndex+1) * FTS3_SEGDIR_MAXLEVEL - 1);
+ sqlite3_bind_int64(pDelete, 1, getAbsoluteLevel(p, iLangid, iIndex, 0));
+ sqlite3_bind_int64(pDelete, 2,
+ getAbsoluteLevel(p, iLangid, iIndex, FTS3_SEGDIR_MAXLEVEL-1)
+ );
}
}else{
rc = fts3SqlStmt(p, SQL_DELETE_SEGDIR_LEVEL, &pDelete, 0);
if( rc==SQLITE_OK ){
- sqlite3_bind_int(pDelete, 1, iIndex*FTS3_SEGDIR_MAXLEVEL + iLevel);
+ sqlite3_bind_int64(
+ pDelete, 1, getAbsoluteLevel(p, iLangid, iIndex, iLevel)
+ );
}
}
@@ -121881,9 +128787,13 @@ static int fts3DeleteSegdir(
**
** If there are no entries in the input position list for column iCol, then
** *pnList is set to zero before returning.
+**
+** If parameter bZero is non-zero, then any part of the input list following
+** the end of the output list is zeroed before returning.
*/
static void fts3ColumnFilter(
int iCol, /* Column to filter on */
+ int bZero, /* Zero out anything following *ppList */
char **ppList, /* IN/OUT: Pointer to position list */
int *pnList /* IN/OUT: Size of buffer *ppList in bytes */
){
@@ -121912,6 +128822,9 @@ static void fts3ColumnFilter(
p += sqlite3Fts3GetVarint32(p, &iCurrent);
}
+ if( bZero && &pList[nList]!=pEnd ){
+ memset(&pList[nList], 0, pEnd - &pList[nList]);
+ }
*ppList = pList;
*pnList = nList;
}
@@ -121985,19 +128898,19 @@ SQLITE_PRIVATE int sqlite3Fts3MsrIncrNext(
if( rc!=SQLITE_OK ) return rc;
fts3SegReaderSort(pMsr->apSegment, nMerge, j, xCmp);
+ if( nList>0 && fts3SegReaderIsPending(apSegment[0]) ){
+ rc = fts3MsrBufferData(pMsr, pList, nList+1);
+ if( rc!=SQLITE_OK ) return rc;
+ assert( (pMsr->aBuffer[nList] & 0xFE)==0x00 );
+ pList = pMsr->aBuffer;
+ }
+
if( pMsr->iColFilter>=0 ){
- fts3ColumnFilter(pMsr->iColFilter, &pList, &nList);
+ fts3ColumnFilter(pMsr->iColFilter, 1, &pList, &nList);
}
if( nList>0 ){
- if( fts3SegReaderIsPending(apSegment[0]) ){
- rc = fts3MsrBufferData(pMsr, pList, nList+1);
- if( rc!=SQLITE_OK ) return rc;
- *paPoslist = pMsr->aBuffer;
- assert( (pMsr->aBuffer[nList] & 0xFE)==0x00 );
- }else{
- *paPoslist = pList;
- }
+ *paPoslist = pList;
*piDocid = iDocid;
*pnPoslist = nList;
break;
@@ -122024,11 +128937,16 @@ static int fts3SegReaderStart(
** b-tree leaf nodes contain more than one term.
*/
for(i=0; pCsr->bRestart==0 && i<pCsr->nSegment; i++){
+ int res = 0;
Fts3SegReader *pSeg = pCsr->apSegment[i];
do {
int rc = fts3SegReaderNext(p, pSeg, 0);
if( rc!=SQLITE_OK ) return rc;
- }while( zTerm && fts3SegReaderTermCmp(pSeg, zTerm, nTerm)<0 );
+ }while( zTerm && (res = fts3SegReaderTermCmp(pSeg, zTerm, nTerm))<0 );
+
+ if( pSeg->bLookup && res!=0 ){
+ fts3SegReaderSetEof(pSeg);
+ }
}
fts3SegReaderSort(pCsr->apSegment, nSeg, nSeg, fts3SegReaderCmp);
@@ -122130,6 +129048,7 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep(
int isColFilter = (pCsr->pFilter->flags & FTS3_SEGMENT_COLUMN_FILTER);
int isPrefix = (pCsr->pFilter->flags & FTS3_SEGMENT_PREFIX);
int isScan = (pCsr->pFilter->flags & FTS3_SEGMENT_SCAN);
+ int isFirst = (pCsr->pFilter->flags & FTS3_SEGMENT_FIRST);
Fts3SegReader **apSegment = pCsr->apSegment;
int nSegment = pCsr->nSegment;
@@ -122148,7 +129067,12 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep(
** forward. Then sort the list in order of current term again.
*/
for(i=0; i<pCsr->nAdvance; i++){
- rc = fts3SegReaderNext(p, apSegment[i], 0);
+ Fts3SegReader *pSeg = apSegment[i];
+ if( pSeg->bLookup ){
+ fts3SegReaderSetEof(pSeg);
+ }else{
+ rc = fts3SegReaderNext(p, pSeg, 0);
+ }
if( rc!=SQLITE_OK ) return rc;
}
fts3SegReaderSort(apSegment, nSegment, pCsr->nAdvance, fts3SegReaderCmp);
@@ -122189,6 +129113,7 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep(
assert( isIgnoreEmpty || (isRequirePos && !isColFilter) );
if( nMerge==1
&& !isIgnoreEmpty
+ && !isFirst
&& (p->bDescIdx==0 || fts3SegReaderIsPending(apSegment[0])==0)
){
pCsr->nDoclist = apSegment[0]->nDoclist;
@@ -122228,7 +129153,7 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep(
}
if( isColFilter ){
- fts3ColumnFilter(pFilter->iCol, &pList, &nList);
+ fts3ColumnFilter(pFilter->iCol, 0, &pList, &nList);
}
if( !isIgnoreEmpty || nList>0 ){
@@ -122254,12 +129179,24 @@ SQLITE_PRIVATE int sqlite3Fts3SegReaderStep(
}
pCsr->aBuffer = aNew;
}
- nDoclist += sqlite3Fts3PutVarint(&pCsr->aBuffer[nDoclist], iDelta);
- iPrev = iDocid;
- if( isRequirePos ){
- memcpy(&pCsr->aBuffer[nDoclist], pList, nList);
- nDoclist += nList;
- pCsr->aBuffer[nDoclist++] = '\0';
+
+ if( isFirst ){
+ char *a = &pCsr->aBuffer[nDoclist];
+ int nWrite;
+
+ nWrite = sqlite3Fts3FirstFilter(iDelta, pList, nList, a);
+ if( nWrite ){
+ iPrev = iDocid;
+ nDoclist += nWrite;
+ }
+ }else{
+ nDoclist += sqlite3Fts3PutVarint(&pCsr->aBuffer[nDoclist], iDelta);
+ iPrev = iDocid;
+ if( isRequirePos ){
+ memcpy(&pCsr->aBuffer[nDoclist], pList, nList);
+ nDoclist += nList;
+ pCsr->aBuffer[nDoclist++] = '\0';
+ }
}
}
@@ -122306,13 +129243,18 @@ SQLITE_PRIVATE void sqlite3Fts3SegReaderFinish(
** Otherwise, if successful, SQLITE_OK is returned. If an error occurs,
** an SQLite error code is returned.
*/
-static int fts3SegmentMerge(Fts3Table *p, int iIndex, int iLevel){
+static int fts3SegmentMerge(
+ Fts3Table *p,
+ int iLangid, /* Language id to merge */
+ int iIndex, /* Index in p->aIndex[] to merge */
+ int iLevel /* Level to merge */
+){
int rc; /* Return code */
int iIdx = 0; /* Index of new segment */
- int iNewLevel = 0; /* Level/index to create new segment at */
+ sqlite3_int64 iNewLevel = 0; /* Level/index to create new segment at */
SegmentWriter *pWriter = 0; /* Used to write the new, merged, segment */
Fts3SegFilter filter; /* Segment term filter condition */
- Fts3MultiSegReader csr; /* Cursor to iterate through level(s) */
+ Fts3MultiSegReader csr; /* Cursor to iterate through level(s) */
int bIgnoreEmpty = 0; /* True to ignore empty segments */
assert( iLevel==FTS3_SEGCURSOR_ALL
@@ -122322,36 +129264,36 @@ static int fts3SegmentMerge(Fts3Table *p, int iIndex, int iLevel){
assert( iLevel<FTS3_SEGDIR_MAXLEVEL );
assert( iIndex>=0 && iIndex<p->nIndex );
- rc = sqlite3Fts3SegReaderCursor(p, iIndex, iLevel, 0, 0, 1, 0, &csr);
+ rc = sqlite3Fts3SegReaderCursor(p, iLangid, iIndex, iLevel, 0, 0, 1, 0, &csr);
if( rc!=SQLITE_OK || csr.nSegment==0 ) goto finished;
if( iLevel==FTS3_SEGCURSOR_ALL ){
/* This call is to merge all segments in the database to a single
- ** segment. The level of the new segment is equal to the the numerically
+ ** segment. The level of the new segment is equal to the numerically
** greatest segment level currently present in the database for this
** index. The idx of the new segment is always 0. */
if( csr.nSegment==1 ){
rc = SQLITE_DONE;
goto finished;
}
- rc = fts3SegmentMaxLevel(p, iIndex, &iNewLevel);
+ rc = fts3SegmentMaxLevel(p, iLangid, iIndex, &iNewLevel);
bIgnoreEmpty = 1;
}else if( iLevel==FTS3_SEGCURSOR_PENDING ){
- iNewLevel = iIndex * FTS3_SEGDIR_MAXLEVEL;
- rc = fts3AllocateSegdirIdx(p, iIndex, 0, &iIdx);
+ iNewLevel = getAbsoluteLevel(p, iLangid, iIndex, 0);
+ rc = fts3AllocateSegdirIdx(p, iLangid, iIndex, 0, &iIdx);
}else{
/* This call is to merge all segments at level iLevel. find the next
** available segment index at level iLevel+1. The call to
** fts3AllocateSegdirIdx() will merge the segments at level iLevel+1 to
** a single iLevel+2 segment if necessary. */
- rc = fts3AllocateSegdirIdx(p, iIndex, iLevel+1, &iIdx);
- iNewLevel = iIndex * FTS3_SEGDIR_MAXLEVEL + iLevel+1;
+ rc = fts3AllocateSegdirIdx(p, iLangid, iIndex, iLevel+1, &iIdx);
+ iNewLevel = getAbsoluteLevel(p, iLangid, iIndex, iLevel+1);
}
if( rc!=SQLITE_OK ) goto finished;
assert( csr.nSegment>0 );
- assert( iNewLevel>=(iIndex*FTS3_SEGDIR_MAXLEVEL) );
- assert( iNewLevel<((iIndex+1)*FTS3_SEGDIR_MAXLEVEL) );
+ assert( iNewLevel>=getAbsoluteLevel(p, iLangid, iIndex, 0) );
+ assert( iNewLevel<getAbsoluteLevel(p, iLangid, iIndex,FTS3_SEGDIR_MAXLEVEL) );
memset(&filter, 0, sizeof(Fts3SegFilter));
filter.flags = FTS3_SEGMENT_REQUIRE_POS;
@@ -122368,7 +129310,9 @@ static int fts3SegmentMerge(Fts3Table *p, int iIndex, int iLevel){
assert( pWriter );
if( iLevel!=FTS3_SEGCURSOR_PENDING ){
- rc = fts3DeleteSegdir(p, iIndex, iLevel, csr.apSegment, csr.nSegment);
+ rc = fts3DeleteSegdir(
+ p, iLangid, iIndex, iLevel, csr.apSegment, csr.nSegment
+ );
if( rc!=SQLITE_OK ) goto finished;
}
rc = fts3SegWriterFlush(p, pWriter, iNewLevel, iIdx);
@@ -122386,11 +129330,28 @@ static int fts3SegmentMerge(Fts3Table *p, int iIndex, int iLevel){
SQLITE_PRIVATE int sqlite3Fts3PendingTermsFlush(Fts3Table *p){
int rc = SQLITE_OK;
int i;
+
for(i=0; rc==SQLITE_OK && i<p->nIndex; i++){
- rc = fts3SegmentMerge(p, i, FTS3_SEGCURSOR_PENDING);
+ rc = fts3SegmentMerge(p, p->iPrevLangid, i, FTS3_SEGCURSOR_PENDING);
if( rc==SQLITE_DONE ) rc = SQLITE_OK;
}
sqlite3Fts3PendingTermsClear(p);
+
+ /* Determine the auto-incr-merge setting if unknown. If enabled,
+ ** estimate the number of leaf blocks of content to be written
+ */
+ if( rc==SQLITE_OK && p->bHasStat
+ && p->bAutoincrmerge==0xff && p->nLeafAdd>0
+ ){
+ sqlite3_stmt *pStmt = 0;
+ rc = fts3SqlStmt(p, SQL_SELECT_STAT, &pStmt, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_int(pStmt, 1, FTS_STAT_AUTOINCRMERGE);
+ rc = sqlite3_step(pStmt);
+ p->bAutoincrmerge = (rc==SQLITE_ROW && sqlite3_column_int(pStmt, 0));
+ rc = sqlite3_reset(pStmt);
+ }
+ }
return rc;
}
@@ -122435,9 +129396,9 @@ static void fts3DecodeIntArray(
** a blob of varints.
*/
static void fts3InsertDocsize(
- int *pRC, /* Result code */
- Fts3Table *p, /* Table into which to insert */
- u32 *aSz /* Sizes of each column */
+ int *pRC, /* Result code */
+ Fts3Table *p, /* Table into which to insert */
+ u32 *aSz /* Sizes of each column, in tokens */
){
char *pBlob; /* The BLOB encoding of the document size */
int nBlob; /* Number of bytes in the BLOB */
@@ -122501,12 +129462,13 @@ static void fts3UpdateDocTotals(
return;
}
pBlob = (char*)&a[nStat];
- rc = fts3SqlStmt(p, SQL_SELECT_DOCTOTAL, &pStmt, 0);
+ rc = fts3SqlStmt(p, SQL_SELECT_STAT, &pStmt, 0);
if( rc ){
sqlite3_free(a);
*pRC = rc;
return;
}
+ sqlite3_bind_int(pStmt, 1, FTS_STAT_DOCTOTAL);
if( sqlite3_step(pStmt)==SQLITE_ROW ){
fts3DecodeIntArray(nStat, a,
sqlite3_column_blob(pStmt, 0),
@@ -122514,7 +129476,12 @@ static void fts3UpdateDocTotals(
}else{
memset(a, 0, sizeof(u32)*(nStat) );
}
- sqlite3_reset(pStmt);
+ rc = sqlite3_reset(pStmt);
+ if( rc!=SQLITE_OK ){
+ sqlite3_free(a);
+ *pRC = rc;
+ return;
+ }
if( nChng<0 && a[0]<(u32)(-nChng) ){
a[0] = 0;
}else{
@@ -122530,29 +129497,47 @@ static void fts3UpdateDocTotals(
a[i+1] = x;
}
fts3EncodeIntArray(nStat, a, pBlob, &nBlob);
- rc = fts3SqlStmt(p, SQL_REPLACE_DOCTOTAL, &pStmt, 0);
+ rc = fts3SqlStmt(p, SQL_REPLACE_STAT, &pStmt, 0);
if( rc ){
sqlite3_free(a);
*pRC = rc;
return;
}
- sqlite3_bind_blob(pStmt, 1, pBlob, nBlob, SQLITE_STATIC);
+ sqlite3_bind_int(pStmt, 1, FTS_STAT_DOCTOTAL);
+ sqlite3_bind_blob(pStmt, 2, pBlob, nBlob, SQLITE_STATIC);
sqlite3_step(pStmt);
*pRC = sqlite3_reset(pStmt);
sqlite3_free(a);
}
+/*
+** Merge the entire database so that there is one segment for each
+** iIndex/iLangid combination.
+*/
static int fts3DoOptimize(Fts3Table *p, int bReturnDone){
- int i;
int bSeenDone = 0;
- int rc = SQLITE_OK;
- for(i=0; rc==SQLITE_OK && i<p->nIndex; i++){
- rc = fts3SegmentMerge(p, i, FTS3_SEGCURSOR_ALL);
- if( rc==SQLITE_DONE ){
- bSeenDone = 1;
- rc = SQLITE_OK;
+ int rc;
+ sqlite3_stmt *pAllLangid = 0;
+
+ rc = fts3SqlStmt(p, SQL_SELECT_ALL_LANGID, &pAllLangid, 0);
+ if( rc==SQLITE_OK ){
+ int rc2;
+ sqlite3_bind_int(pAllLangid, 1, p->nIndex);
+ while( sqlite3_step(pAllLangid)==SQLITE_ROW ){
+ int i;
+ int iLangid = sqlite3_column_int(pAllLangid, 0);
+ for(i=0; rc==SQLITE_OK && i<p->nIndex; i++){
+ rc = fts3SegmentMerge(p, iLangid, i, FTS3_SEGCURSOR_ALL);
+ if( rc==SQLITE_DONE ){
+ bSeenDone = 1;
+ rc = SQLITE_OK;
+ }
+ }
}
+ rc2 = sqlite3_reset(pAllLangid);
+ if( rc==SQLITE_OK ) rc = rc2;
}
+
sqlite3Fts3SegmentsClose(p);
sqlite3Fts3PendingTermsClear(p);
@@ -122560,6 +129545,1768 @@ static int fts3DoOptimize(Fts3Table *p, int bReturnDone){
}
/*
+** This function is called when the user executes the following statement:
+**
+** INSERT INTO <tbl>(<tbl>) VALUES('rebuild');
+**
+** The entire FTS index is discarded and rebuilt. If the table is one
+** created using the content=xxx option, then the new index is based on
+** the current contents of the xxx table. Otherwise, it is rebuilt based
+** on the contents of the %_content table.
+*/
+static int fts3DoRebuild(Fts3Table *p){
+ int rc; /* Return Code */
+
+ rc = fts3DeleteAll(p, 0);
+ if( rc==SQLITE_OK ){
+ u32 *aSz = 0;
+ u32 *aSzIns = 0;
+ u32 *aSzDel = 0;
+ sqlite3_stmt *pStmt = 0;
+ int nEntry = 0;
+
+ /* Compose and prepare an SQL statement to loop through the content table */
+ char *zSql = sqlite3_mprintf("SELECT %s" , p->zReadExprlist);
+ if( !zSql ){
+ rc = SQLITE_NOMEM;
+ }else{
+ rc = sqlite3_prepare_v2(p->db, zSql, -1, &pStmt, 0);
+ sqlite3_free(zSql);
+ }
+
+ if( rc==SQLITE_OK ){
+ int nByte = sizeof(u32) * (p->nColumn+1)*3;
+ aSz = (u32 *)sqlite3_malloc(nByte);
+ if( aSz==0 ){
+ rc = SQLITE_NOMEM;
+ }else{
+ memset(aSz, 0, nByte);
+ aSzIns = &aSz[p->nColumn+1];
+ aSzDel = &aSzIns[p->nColumn+1];
+ }
+ }
+
+ while( rc==SQLITE_OK && SQLITE_ROW==sqlite3_step(pStmt) ){
+ int iCol;
+ int iLangid = langidFromSelect(p, pStmt);
+ rc = fts3PendingTermsDocid(p, iLangid, sqlite3_column_int64(pStmt, 0));
+ memset(aSz, 0, sizeof(aSz[0]) * (p->nColumn+1));
+ for(iCol=0; rc==SQLITE_OK && iCol<p->nColumn; iCol++){
+ const char *z = (const char *) sqlite3_column_text(pStmt, iCol+1);
+ rc = fts3PendingTermsAdd(p, iLangid, z, iCol, &aSz[iCol]);
+ aSz[p->nColumn] += sqlite3_column_bytes(pStmt, iCol+1);
+ }
+ if( p->bHasDocsize ){
+ fts3InsertDocsize(&rc, p, aSz);
+ }
+ if( rc!=SQLITE_OK ){
+ sqlite3_finalize(pStmt);
+ pStmt = 0;
+ }else{
+ nEntry++;
+ for(iCol=0; iCol<=p->nColumn; iCol++){
+ aSzIns[iCol] += aSz[iCol];
+ }
+ }
+ }
+ if( p->bFts4 ){
+ fts3UpdateDocTotals(&rc, p, aSzIns, aSzDel, nEntry);
+ }
+ sqlite3_free(aSz);
+
+ if( pStmt ){
+ int rc2 = sqlite3_finalize(pStmt);
+ if( rc==SQLITE_OK ){
+ rc = rc2;
+ }
+ }
+ }
+
+ return rc;
+}
+
+
+/*
+** This function opens a cursor used to read the input data for an
+** incremental merge operation. Specifically, it opens a cursor to scan
+** the oldest nSeg segments (idx=0 through idx=(nSeg-1)) in absolute
+** level iAbsLevel.
+*/
+static int fts3IncrmergeCsr(
+ Fts3Table *p, /* FTS3 table handle */
+ sqlite3_int64 iAbsLevel, /* Absolute level to open */
+ int nSeg, /* Number of segments to merge */
+ Fts3MultiSegReader *pCsr /* Cursor object to populate */
+){
+ int rc; /* Return Code */
+ sqlite3_stmt *pStmt = 0; /* Statement used to read %_segdir entry */
+ int nByte; /* Bytes allocated at pCsr->apSegment[] */
+
+ /* Allocate space for the Fts3MultiSegReader.aCsr[] array */
+ memset(pCsr, 0, sizeof(*pCsr));
+ nByte = sizeof(Fts3SegReader *) * nSeg;
+ pCsr->apSegment = (Fts3SegReader **)sqlite3_malloc(nByte);
+
+ if( pCsr->apSegment==0 ){
+ rc = SQLITE_NOMEM;
+ }else{
+ memset(pCsr->apSegment, 0, nByte);
+ rc = fts3SqlStmt(p, SQL_SELECT_LEVEL, &pStmt, 0);
+ }
+ if( rc==SQLITE_OK ){
+ int i;
+ int rc2;
+ sqlite3_bind_int64(pStmt, 1, iAbsLevel);
+ assert( pCsr->nSegment==0 );
+ for(i=0; rc==SQLITE_OK && sqlite3_step(pStmt)==SQLITE_ROW && i<nSeg; i++){
+ rc = sqlite3Fts3SegReaderNew(i, 0,
+ sqlite3_column_int64(pStmt, 1), /* segdir.start_block */
+ sqlite3_column_int64(pStmt, 2), /* segdir.leaves_end_block */
+ sqlite3_column_int64(pStmt, 3), /* segdir.end_block */
+ sqlite3_column_blob(pStmt, 4), /* segdir.root */
+ sqlite3_column_bytes(pStmt, 4), /* segdir.root */
+ &pCsr->apSegment[i]
+ );
+ pCsr->nSegment++;
+ }
+ rc2 = sqlite3_reset(pStmt);
+ if( rc==SQLITE_OK ) rc = rc2;
+ }
+
+ return rc;
+}
+
+typedef struct IncrmergeWriter IncrmergeWriter;
+typedef struct NodeWriter NodeWriter;
+typedef struct Blob Blob;
+typedef struct NodeReader NodeReader;
+
+/*
+** An instance of the following structure is used as a dynamic buffer
+** to build up nodes or other blobs of data in.
+**
+** The function blobGrowBuffer() is used to extend the allocation.
+*/
+struct Blob {
+ char *a; /* Pointer to allocation */
+ int n; /* Number of valid bytes of data in a[] */
+ int nAlloc; /* Allocated size of a[] (nAlloc>=n) */
+};
+
+/*
+** This structure is used to build up buffers containing segment b-tree
+** nodes (blocks).
+*/
+struct NodeWriter {
+ sqlite3_int64 iBlock; /* Current block id */
+ Blob key; /* Last key written to the current block */
+ Blob block; /* Current block image */
+};
+
+/*
+** An object of this type contains the state required to create or append
+** to an appendable b-tree segment.
+*/
+struct IncrmergeWriter {
+ int nLeafEst; /* Space allocated for leaf blocks */
+ int nWork; /* Number of leaf pages flushed */
+ sqlite3_int64 iAbsLevel; /* Absolute level of input segments */
+ int iIdx; /* Index of *output* segment in iAbsLevel+1 */
+ sqlite3_int64 iStart; /* Block number of first allocated block */
+ sqlite3_int64 iEnd; /* Block number of last allocated block */
+ NodeWriter aNodeWriter[FTS_MAX_APPENDABLE_HEIGHT];
+};
+
+/*
+** An object of the following type is used to read data from a single
+** FTS segment node. See the following functions:
+**
+** nodeReaderInit()
+** nodeReaderNext()
+** nodeReaderRelease()
+*/
+struct NodeReader {
+ const char *aNode;
+ int nNode;
+ int iOff; /* Current offset within aNode[] */
+
+ /* Output variables. Containing the current node entry. */
+ sqlite3_int64 iChild; /* Pointer to child node */
+ Blob term; /* Current term */
+ const char *aDoclist; /* Pointer to doclist */
+ int nDoclist; /* Size of doclist in bytes */
+};
+
+/*
+** If *pRc is not SQLITE_OK when this function is called, it is a no-op.
+** Otherwise, if the allocation at pBlob->a is not already at least nMin
+** bytes in size, extend (realloc) it to be so.
+**
+** If an OOM error occurs, set *pRc to SQLITE_NOMEM and leave pBlob->a
+** unmodified. Otherwise, if the allocation succeeds, update pBlob->nAlloc
+** to reflect the new size of the pBlob->a[] buffer.
+*/
+static void blobGrowBuffer(Blob *pBlob, int nMin, int *pRc){
+ if( *pRc==SQLITE_OK && nMin>pBlob->nAlloc ){
+ int nAlloc = nMin;
+ char *a = (char *)sqlite3_realloc(pBlob->a, nAlloc);
+ if( a ){
+ pBlob->nAlloc = nAlloc;
+ pBlob->a = a;
+ }else{
+ *pRc = SQLITE_NOMEM;
+ }
+ }
+}
+
+/*
+** Attempt to advance the node-reader object passed as the first argument to
+** the next entry on the node.
+**
+** Return an error code if an error occurs (SQLITE_NOMEM is possible).
+** Otherwise return SQLITE_OK. If there is no next entry on the node
+** (e.g. because the current entry is the last) set NodeReader->aNode to
+** NULL to indicate EOF. Otherwise, populate the NodeReader structure output
+** variables for the new entry.
+*/
+static int nodeReaderNext(NodeReader *p){
+ int bFirst = (p->term.n==0); /* True for first term on the node */
+ int nPrefix = 0; /* Bytes to copy from previous term */
+ int nSuffix = 0; /* Bytes to append to the prefix */
+ int rc = SQLITE_OK; /* Return code */
+
+ assert( p->aNode );
+ if( p->iChild && bFirst==0 ) p->iChild++;
+ if( p->iOff>=p->nNode ){
+ /* EOF */
+ p->aNode = 0;
+ }else{
+ if( bFirst==0 ){
+ p->iOff += sqlite3Fts3GetVarint32(&p->aNode[p->iOff], &nPrefix);
+ }
+ p->iOff += sqlite3Fts3GetVarint32(&p->aNode[p->iOff], &nSuffix);
+
+ blobGrowBuffer(&p->term, nPrefix+nSuffix, &rc);
+ if( rc==SQLITE_OK ){
+ memcpy(&p->term.a[nPrefix], &p->aNode[p->iOff], nSuffix);
+ p->term.n = nPrefix+nSuffix;
+ p->iOff += nSuffix;
+ if( p->iChild==0 ){
+ p->iOff += sqlite3Fts3GetVarint32(&p->aNode[p->iOff], &p->nDoclist);
+ p->aDoclist = &p->aNode[p->iOff];
+ p->iOff += p->nDoclist;
+ }
+ }
+ }
+
+ assert( p->iOff<=p->nNode );
+
+ return rc;
+}
+
+/*
+** Release all dynamic resources held by node-reader object *p.
+*/
+static void nodeReaderRelease(NodeReader *p){
+ sqlite3_free(p->term.a);
+}
+
+/*
+** Initialize a node-reader object to read the node in buffer aNode/nNode.
+**
+** If successful, SQLITE_OK is returned and the NodeReader object set to
+** point to the first entry on the node (if any). Otherwise, an SQLite
+** error code is returned.
+*/
+static int nodeReaderInit(NodeReader *p, const char *aNode, int nNode){
+ memset(p, 0, sizeof(NodeReader));
+ p->aNode = aNode;
+ p->nNode = nNode;
+
+ /* Figure out if this is a leaf or an internal node. */
+ if( p->aNode[0] ){
+ /* An internal node. */
+ p->iOff = 1 + sqlite3Fts3GetVarint(&p->aNode[1], &p->iChild);
+ }else{
+ p->iOff = 1;
+ }
+
+ return nodeReaderNext(p);
+}
+
+/*
+** This function is called while writing an FTS segment each time a leaf o
+** node is finished and written to disk. The key (zTerm/nTerm) is guaranteed
+** to be greater than the largest key on the node just written, but smaller
+** than or equal to the first key that will be written to the next leaf
+** node.
+**
+** The block id of the leaf node just written to disk may be found in
+** (pWriter->aNodeWriter[0].iBlock) when this function is called.
+*/
+static int fts3IncrmergePush(
+ Fts3Table *p, /* Fts3 table handle */
+ IncrmergeWriter *pWriter, /* Writer object */
+ const char *zTerm, /* Term to write to internal node */
+ int nTerm /* Bytes at zTerm */
+){
+ sqlite3_int64 iPtr = pWriter->aNodeWriter[0].iBlock;
+ int iLayer;
+
+ assert( nTerm>0 );
+ for(iLayer=1; ALWAYS(iLayer<FTS_MAX_APPENDABLE_HEIGHT); iLayer++){
+ sqlite3_int64 iNextPtr = 0;
+ NodeWriter *pNode = &pWriter->aNodeWriter[iLayer];
+ int rc = SQLITE_OK;
+ int nPrefix;
+ int nSuffix;
+ int nSpace;
+
+ /* Figure out how much space the key will consume if it is written to
+ ** the current node of layer iLayer. Due to the prefix compression,
+ ** the space required changes depending on which node the key is to
+ ** be added to. */
+ nPrefix = fts3PrefixCompress(pNode->key.a, pNode->key.n, zTerm, nTerm);
+ nSuffix = nTerm - nPrefix;
+ nSpace = sqlite3Fts3VarintLen(nPrefix);
+ nSpace += sqlite3Fts3VarintLen(nSuffix) + nSuffix;
+
+ if( pNode->key.n==0 || (pNode->block.n + nSpace)<=p->nNodeSize ){
+ /* If the current node of layer iLayer contains zero keys, or if adding
+ ** the key to it will not cause it to grow to larger than nNodeSize
+ ** bytes in size, write the key here. */
+
+ Blob *pBlk = &pNode->block;
+ if( pBlk->n==0 ){
+ blobGrowBuffer(pBlk, p->nNodeSize, &rc);
+ if( rc==SQLITE_OK ){
+ pBlk->a[0] = (char)iLayer;
+ pBlk->n = 1 + sqlite3Fts3PutVarint(&pBlk->a[1], iPtr);
+ }
+ }
+ blobGrowBuffer(pBlk, pBlk->n + nSpace, &rc);
+ blobGrowBuffer(&pNode->key, nTerm, &rc);
+
+ if( rc==SQLITE_OK ){
+ if( pNode->key.n ){
+ pBlk->n += sqlite3Fts3PutVarint(&pBlk->a[pBlk->n], nPrefix);
+ }
+ pBlk->n += sqlite3Fts3PutVarint(&pBlk->a[pBlk->n], nSuffix);
+ memcpy(&pBlk->a[pBlk->n], &zTerm[nPrefix], nSuffix);
+ pBlk->n += nSuffix;
+
+ memcpy(pNode->key.a, zTerm, nTerm);
+ pNode->key.n = nTerm;
+ }
+ }else{
+ /* Otherwise, flush the current node of layer iLayer to disk.
+ ** Then allocate a new, empty sibling node. The key will be written
+ ** into the parent of this node. */
+ rc = fts3WriteSegment(p, pNode->iBlock, pNode->block.a, pNode->block.n);
+
+ assert( pNode->block.nAlloc>=p->nNodeSize );
+ pNode->block.a[0] = (char)iLayer;
+ pNode->block.n = 1 + sqlite3Fts3PutVarint(&pNode->block.a[1], iPtr+1);
+
+ iNextPtr = pNode->iBlock;
+ pNode->iBlock++;
+ pNode->key.n = 0;
+ }
+
+ if( rc!=SQLITE_OK || iNextPtr==0 ) return rc;
+ iPtr = iNextPtr;
+ }
+
+ assert( 0 );
+ return 0;
+}
+
+/*
+** Append a term and (optionally) doclist to the FTS segment node currently
+** stored in blob *pNode. The node need not contain any terms, but the
+** header must be written before this function is called.
+**
+** A node header is a single 0x00 byte for a leaf node, or a height varint
+** followed by the left-hand-child varint for an internal node.
+**
+** The term to be appended is passed via arguments zTerm/nTerm. For a
+** leaf node, the doclist is passed as aDoclist/nDoclist. For an internal
+** node, both aDoclist and nDoclist must be passed 0.
+**
+** If the size of the value in blob pPrev is zero, then this is the first
+** term written to the node. Otherwise, pPrev contains a copy of the
+** previous term. Before this function returns, it is updated to contain a
+** copy of zTerm/nTerm.
+**
+** It is assumed that the buffer associated with pNode is already large
+** enough to accommodate the new entry. The buffer associated with pPrev
+** is extended by this function if requrired.
+**
+** If an error (i.e. OOM condition) occurs, an SQLite error code is
+** returned. Otherwise, SQLITE_OK.
+*/
+static int fts3AppendToNode(
+ Blob *pNode, /* Current node image to append to */
+ Blob *pPrev, /* Buffer containing previous term written */
+ const char *zTerm, /* New term to write */
+ int nTerm, /* Size of zTerm in bytes */
+ const char *aDoclist, /* Doclist (or NULL) to write */
+ int nDoclist /* Size of aDoclist in bytes */
+){
+ int rc = SQLITE_OK; /* Return code */
+ int bFirst = (pPrev->n==0); /* True if this is the first term written */
+ int nPrefix; /* Size of term prefix in bytes */
+ int nSuffix; /* Size of term suffix in bytes */
+
+ /* Node must have already been started. There must be a doclist for a
+ ** leaf node, and there must not be a doclist for an internal node. */
+ assert( pNode->n>0 );
+ assert( (pNode->a[0]=='\0')==(aDoclist!=0) );
+
+ blobGrowBuffer(pPrev, nTerm, &rc);
+ if( rc!=SQLITE_OK ) return rc;
+
+ nPrefix = fts3PrefixCompress(pPrev->a, pPrev->n, zTerm, nTerm);
+ nSuffix = nTerm - nPrefix;
+ memcpy(pPrev->a, zTerm, nTerm);
+ pPrev->n = nTerm;
+
+ if( bFirst==0 ){
+ pNode->n += sqlite3Fts3PutVarint(&pNode->a[pNode->n], nPrefix);
+ }
+ pNode->n += sqlite3Fts3PutVarint(&pNode->a[pNode->n], nSuffix);
+ memcpy(&pNode->a[pNode->n], &zTerm[nPrefix], nSuffix);
+ pNode->n += nSuffix;
+
+ if( aDoclist ){
+ pNode->n += sqlite3Fts3PutVarint(&pNode->a[pNode->n], nDoclist);
+ memcpy(&pNode->a[pNode->n], aDoclist, nDoclist);
+ pNode->n += nDoclist;
+ }
+
+ assert( pNode->n<=pNode->nAlloc );
+
+ return SQLITE_OK;
+}
+
+/*
+** Append the current term and doclist pointed to by cursor pCsr to the
+** appendable b-tree segment opened for writing by pWriter.
+**
+** Return SQLITE_OK if successful, or an SQLite error code otherwise.
+*/
+static int fts3IncrmergeAppend(
+ Fts3Table *p, /* Fts3 table handle */
+ IncrmergeWriter *pWriter, /* Writer object */
+ Fts3MultiSegReader *pCsr /* Cursor containing term and doclist */
+){
+ const char *zTerm = pCsr->zTerm;
+ int nTerm = pCsr->nTerm;
+ const char *aDoclist = pCsr->aDoclist;
+ int nDoclist = pCsr->nDoclist;
+ int rc = SQLITE_OK; /* Return code */
+ int nSpace; /* Total space in bytes required on leaf */
+ int nPrefix; /* Size of prefix shared with previous term */
+ int nSuffix; /* Size of suffix (nTerm - nPrefix) */
+ NodeWriter *pLeaf; /* Object used to write leaf nodes */
+
+ pLeaf = &pWriter->aNodeWriter[0];
+ nPrefix = fts3PrefixCompress(pLeaf->key.a, pLeaf->key.n, zTerm, nTerm);
+ nSuffix = nTerm - nPrefix;
+
+ nSpace = sqlite3Fts3VarintLen(nPrefix);
+ nSpace += sqlite3Fts3VarintLen(nSuffix) + nSuffix;
+ nSpace += sqlite3Fts3VarintLen(nDoclist) + nDoclist;
+
+ /* If the current block is not empty, and if adding this term/doclist
+ ** to the current block would make it larger than Fts3Table.nNodeSize
+ ** bytes, write this block out to the database. */
+ if( pLeaf->block.n>0 && (pLeaf->block.n + nSpace)>p->nNodeSize ){
+ rc = fts3WriteSegment(p, pLeaf->iBlock, pLeaf->block.a, pLeaf->block.n);
+ pWriter->nWork++;
+
+ /* Add the current term to the parent node. The term added to the
+ ** parent must:
+ **
+ ** a) be greater than the largest term on the leaf node just written
+ ** to the database (still available in pLeaf->key), and
+ **
+ ** b) be less than or equal to the term about to be added to the new
+ ** leaf node (zTerm/nTerm).
+ **
+ ** In other words, it must be the prefix of zTerm 1 byte longer than
+ ** the common prefix (if any) of zTerm and pWriter->zTerm.
+ */
+ if( rc==SQLITE_OK ){
+ rc = fts3IncrmergePush(p, pWriter, zTerm, nPrefix+1);
+ }
+
+ /* Advance to the next output block */
+ pLeaf->iBlock++;
+ pLeaf->key.n = 0;
+ pLeaf->block.n = 0;
+
+ nSuffix = nTerm;
+ nSpace = 1;
+ nSpace += sqlite3Fts3VarintLen(nSuffix) + nSuffix;
+ nSpace += sqlite3Fts3VarintLen(nDoclist) + nDoclist;
+ }
+
+ blobGrowBuffer(&pLeaf->block, pLeaf->block.n + nSpace, &rc);
+
+ if( rc==SQLITE_OK ){
+ if( pLeaf->block.n==0 ){
+ pLeaf->block.n = 1;
+ pLeaf->block.a[0] = '\0';
+ }
+ rc = fts3AppendToNode(
+ &pLeaf->block, &pLeaf->key, zTerm, nTerm, aDoclist, nDoclist
+ );
+ }
+
+ return rc;
+}
+
+/*
+** This function is called to release all dynamic resources held by the
+** merge-writer object pWriter, and if no error has occurred, to flush
+** all outstanding node buffers held by pWriter to disk.
+**
+** If *pRc is not SQLITE_OK when this function is called, then no attempt
+** is made to write any data to disk. Instead, this function serves only
+** to release outstanding resources.
+**
+** Otherwise, if *pRc is initially SQLITE_OK and an error occurs while
+** flushing buffers to disk, *pRc is set to an SQLite error code before
+** returning.
+*/
+static void fts3IncrmergeRelease(
+ Fts3Table *p, /* FTS3 table handle */
+ IncrmergeWriter *pWriter, /* Merge-writer object */
+ int *pRc /* IN/OUT: Error code */
+){
+ int i; /* Used to iterate through non-root layers */
+ int iRoot; /* Index of root in pWriter->aNodeWriter */
+ NodeWriter *pRoot; /* NodeWriter for root node */
+ int rc = *pRc; /* Error code */
+
+ /* Set iRoot to the index in pWriter->aNodeWriter[] of the output segment
+ ** root node. If the segment fits entirely on a single leaf node, iRoot
+ ** will be set to 0. If the root node is the parent of the leaves, iRoot
+ ** will be 1. And so on. */
+ for(iRoot=FTS_MAX_APPENDABLE_HEIGHT-1; iRoot>=0; iRoot--){
+ NodeWriter *pNode = &pWriter->aNodeWriter[iRoot];
+ if( pNode->block.n>0 ) break;
+ assert( *pRc || pNode->block.nAlloc==0 );
+ assert( *pRc || pNode->key.nAlloc==0 );
+ sqlite3_free(pNode->block.a);
+ sqlite3_free(pNode->key.a);
+ }
+
+ /* Empty output segment. This is a no-op. */
+ if( iRoot<0 ) return;
+
+ /* The entire output segment fits on a single node. Normally, this means
+ ** the node would be stored as a blob in the "root" column of the %_segdir
+ ** table. However, this is not permitted in this case. The problem is that
+ ** space has already been reserved in the %_segments table, and so the
+ ** start_block and end_block fields of the %_segdir table must be populated.
+ ** And, by design or by accident, released versions of FTS cannot handle
+ ** segments that fit entirely on the root node with start_block!=0.
+ **
+ ** Instead, create a synthetic root node that contains nothing but a
+ ** pointer to the single content node. So that the segment consists of a
+ ** single leaf and a single interior (root) node.
+ **
+ ** Todo: Better might be to defer allocating space in the %_segments
+ ** table until we are sure it is needed.
+ */
+ if( iRoot==0 ){
+ Blob *pBlock = &pWriter->aNodeWriter[1].block;
+ blobGrowBuffer(pBlock, 1 + FTS3_VARINT_MAX, &rc);
+ if( rc==SQLITE_OK ){
+ pBlock->a[0] = 0x01;
+ pBlock->n = 1 + sqlite3Fts3PutVarint(
+ &pBlock->a[1], pWriter->aNodeWriter[0].iBlock
+ );
+ }
+ iRoot = 1;
+ }
+ pRoot = &pWriter->aNodeWriter[iRoot];
+
+ /* Flush all currently outstanding nodes to disk. */
+ for(i=0; i<iRoot; i++){
+ NodeWriter *pNode = &pWriter->aNodeWriter[i];
+ if( pNode->block.n>0 && rc==SQLITE_OK ){
+ rc = fts3WriteSegment(p, pNode->iBlock, pNode->block.a, pNode->block.n);
+ }
+ sqlite3_free(pNode->block.a);
+ sqlite3_free(pNode->key.a);
+ }
+
+ /* Write the %_segdir record. */
+ if( rc==SQLITE_OK ){
+ rc = fts3WriteSegdir(p,
+ pWriter->iAbsLevel+1, /* level */
+ pWriter->iIdx, /* idx */
+ pWriter->iStart, /* start_block */
+ pWriter->aNodeWriter[0].iBlock, /* leaves_end_block */
+ pWriter->iEnd, /* end_block */
+ pRoot->block.a, pRoot->block.n /* root */
+ );
+ }
+ sqlite3_free(pRoot->block.a);
+ sqlite3_free(pRoot->key.a);
+
+ *pRc = rc;
+}
+
+/*
+** Compare the term in buffer zLhs (size in bytes nLhs) with that in
+** zRhs (size in bytes nRhs) using memcmp. If one term is a prefix of
+** the other, it is considered to be smaller than the other.
+**
+** Return -ve if zLhs is smaller than zRhs, 0 if it is equal, or +ve
+** if it is greater.
+*/
+static int fts3TermCmp(
+ const char *zLhs, int nLhs, /* LHS of comparison */
+ const char *zRhs, int nRhs /* RHS of comparison */
+){
+ int nCmp = MIN(nLhs, nRhs);
+ int res;
+
+ res = memcmp(zLhs, zRhs, nCmp);
+ if( res==0 ) res = nLhs - nRhs;
+
+ return res;
+}
+
+
+/*
+** Query to see if the entry in the %_segments table with blockid iEnd is
+** NULL. If no error occurs and the entry is NULL, set *pbRes 1 before
+** returning. Otherwise, set *pbRes to 0.
+**
+** Or, if an error occurs while querying the database, return an SQLite
+** error code. The final value of *pbRes is undefined in this case.
+**
+** This is used to test if a segment is an "appendable" segment. If it
+** is, then a NULL entry has been inserted into the %_segments table
+** with blockid %_segdir.end_block.
+*/
+static int fts3IsAppendable(Fts3Table *p, sqlite3_int64 iEnd, int *pbRes){
+ int bRes = 0; /* Result to set *pbRes to */
+ sqlite3_stmt *pCheck = 0; /* Statement to query database with */
+ int rc; /* Return code */
+
+ rc = fts3SqlStmt(p, SQL_SEGMENT_IS_APPENDABLE, &pCheck, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_int64(pCheck, 1, iEnd);
+ if( SQLITE_ROW==sqlite3_step(pCheck) ) bRes = 1;
+ rc = sqlite3_reset(pCheck);
+ }
+
+ *pbRes = bRes;
+ return rc;
+}
+
+/*
+** This function is called when initializing an incremental-merge operation.
+** It checks if the existing segment with index value iIdx at absolute level
+** (iAbsLevel+1) can be appended to by the incremental merge. If it can, the
+** merge-writer object *pWriter is initialized to write to it.
+**
+** An existing segment can be appended to by an incremental merge if:
+**
+** * It was initially created as an appendable segment (with all required
+** space pre-allocated), and
+**
+** * The first key read from the input (arguments zKey and nKey) is
+** greater than the largest key currently stored in the potential
+** output segment.
+*/
+static int fts3IncrmergeLoad(
+ Fts3Table *p, /* Fts3 table handle */
+ sqlite3_int64 iAbsLevel, /* Absolute level of input segments */
+ int iIdx, /* Index of candidate output segment */
+ const char *zKey, /* First key to write */
+ int nKey, /* Number of bytes in nKey */
+ IncrmergeWriter *pWriter /* Populate this object */
+){
+ int rc; /* Return code */
+ sqlite3_stmt *pSelect = 0; /* SELECT to read %_segdir entry */
+
+ rc = fts3SqlStmt(p, SQL_SELECT_SEGDIR, &pSelect, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_int64 iStart = 0; /* Value of %_segdir.start_block */
+ sqlite3_int64 iLeafEnd = 0; /* Value of %_segdir.leaves_end_block */
+ sqlite3_int64 iEnd = 0; /* Value of %_segdir.end_block */
+ const char *aRoot = 0; /* Pointer to %_segdir.root buffer */
+ int nRoot = 0; /* Size of aRoot[] in bytes */
+ int rc2; /* Return code from sqlite3_reset() */
+ int bAppendable = 0; /* Set to true if segment is appendable */
+
+ /* Read the %_segdir entry for index iIdx absolute level (iAbsLevel+1) */
+ sqlite3_bind_int64(pSelect, 1, iAbsLevel+1);
+ sqlite3_bind_int(pSelect, 2, iIdx);
+ if( sqlite3_step(pSelect)==SQLITE_ROW ){
+ iStart = sqlite3_column_int64(pSelect, 1);
+ iLeafEnd = sqlite3_column_int64(pSelect, 2);
+ iEnd = sqlite3_column_int64(pSelect, 3);
+ nRoot = sqlite3_column_bytes(pSelect, 4);
+ aRoot = sqlite3_column_blob(pSelect, 4);
+ }else{
+ return sqlite3_reset(pSelect);
+ }
+
+ /* Check for the zero-length marker in the %_segments table */
+ rc = fts3IsAppendable(p, iEnd, &bAppendable);
+
+ /* Check that zKey/nKey is larger than the largest key the candidate */
+ if( rc==SQLITE_OK && bAppendable ){
+ char *aLeaf = 0;
+ int nLeaf = 0;
+
+ rc = sqlite3Fts3ReadBlock(p, iLeafEnd, &aLeaf, &nLeaf, 0);
+ if( rc==SQLITE_OK ){
+ NodeReader reader;
+ for(rc = nodeReaderInit(&reader, aLeaf, nLeaf);
+ rc==SQLITE_OK && reader.aNode;
+ rc = nodeReaderNext(&reader)
+ ){
+ assert( reader.aNode );
+ }
+ if( fts3TermCmp(zKey, nKey, reader.term.a, reader.term.n)<=0 ){
+ bAppendable = 0;
+ }
+ nodeReaderRelease(&reader);
+ }
+ sqlite3_free(aLeaf);
+ }
+
+ if( rc==SQLITE_OK && bAppendable ){
+ /* It is possible to append to this segment. Set up the IncrmergeWriter
+ ** object to do so. */
+ int i;
+ int nHeight = (int)aRoot[0];
+ NodeWriter *pNode;
+
+ pWriter->nLeafEst = (int)((iEnd - iStart) + 1)/FTS_MAX_APPENDABLE_HEIGHT;
+ pWriter->iStart = iStart;
+ pWriter->iEnd = iEnd;
+ pWriter->iAbsLevel = iAbsLevel;
+ pWriter->iIdx = iIdx;
+
+ for(i=nHeight+1; i<FTS_MAX_APPENDABLE_HEIGHT; i++){
+ pWriter->aNodeWriter[i].iBlock = pWriter->iStart + i*pWriter->nLeafEst;
+ }
+
+ pNode = &pWriter->aNodeWriter[nHeight];
+ pNode->iBlock = pWriter->iStart + pWriter->nLeafEst*nHeight;
+ blobGrowBuffer(&pNode->block, MAX(nRoot, p->nNodeSize), &rc);
+ if( rc==SQLITE_OK ){
+ memcpy(pNode->block.a, aRoot, nRoot);
+ pNode->block.n = nRoot;
+ }
+
+ for(i=nHeight; i>=0 && rc==SQLITE_OK; i--){
+ NodeReader reader;
+ pNode = &pWriter->aNodeWriter[i];
+
+ rc = nodeReaderInit(&reader, pNode->block.a, pNode->block.n);
+ while( reader.aNode && rc==SQLITE_OK ) rc = nodeReaderNext(&reader);
+ blobGrowBuffer(&pNode->key, reader.term.n, &rc);
+ if( rc==SQLITE_OK ){
+ memcpy(pNode->key.a, reader.term.a, reader.term.n);
+ pNode->key.n = reader.term.n;
+ if( i>0 ){
+ char *aBlock = 0;
+ int nBlock = 0;
+ pNode = &pWriter->aNodeWriter[i-1];
+ pNode->iBlock = reader.iChild;
+ rc = sqlite3Fts3ReadBlock(p, reader.iChild, &aBlock, &nBlock, 0);
+ blobGrowBuffer(&pNode->block, MAX(nBlock, p->nNodeSize), &rc);
+ if( rc==SQLITE_OK ){
+ memcpy(pNode->block.a, aBlock, nBlock);
+ pNode->block.n = nBlock;
+ }
+ sqlite3_free(aBlock);
+ }
+ }
+ nodeReaderRelease(&reader);
+ }
+ }
+
+ rc2 = sqlite3_reset(pSelect);
+ if( rc==SQLITE_OK ) rc = rc2;
+ }
+
+ return rc;
+}
+
+/*
+** Determine the largest segment index value that exists within absolute
+** level iAbsLevel+1. If no error occurs, set *piIdx to this value plus
+** one before returning SQLITE_OK. Or, if there are no segments at all
+** within level iAbsLevel, set *piIdx to zero.
+**
+** If an error occurs, return an SQLite error code. The final value of
+** *piIdx is undefined in this case.
+*/
+static int fts3IncrmergeOutputIdx(
+ Fts3Table *p, /* FTS Table handle */
+ sqlite3_int64 iAbsLevel, /* Absolute index of input segments */
+ int *piIdx /* OUT: Next free index at iAbsLevel+1 */
+){
+ int rc;
+ sqlite3_stmt *pOutputIdx = 0; /* SQL used to find output index */
+
+ rc = fts3SqlStmt(p, SQL_NEXT_SEGMENT_INDEX, &pOutputIdx, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_int64(pOutputIdx, 1, iAbsLevel+1);
+ sqlite3_step(pOutputIdx);
+ *piIdx = sqlite3_column_int(pOutputIdx, 0);
+ rc = sqlite3_reset(pOutputIdx);
+ }
+
+ return rc;
+}
+
+/*
+** Allocate an appendable output segment on absolute level iAbsLevel+1
+** with idx value iIdx.
+**
+** In the %_segdir table, a segment is defined by the values in three
+** columns:
+**
+** start_block
+** leaves_end_block
+** end_block
+**
+** When an appendable segment is allocated, it is estimated that the
+** maximum number of leaf blocks that may be required is the sum of the
+** number of leaf blocks consumed by the input segments, plus the number
+** of input segments, multiplied by two. This value is stored in stack
+** variable nLeafEst.
+**
+** A total of 16*nLeafEst blocks are allocated when an appendable segment
+** is created ((1 + end_block - start_block)==16*nLeafEst). The contiguous
+** array of leaf nodes starts at the first block allocated. The array
+** of interior nodes that are parents of the leaf nodes start at block
+** (start_block + (1 + end_block - start_block) / 16). And so on.
+**
+** In the actual code below, the value "16" is replaced with the
+** pre-processor macro FTS_MAX_APPENDABLE_HEIGHT.
+*/
+static int fts3IncrmergeWriter(
+ Fts3Table *p, /* Fts3 table handle */
+ sqlite3_int64 iAbsLevel, /* Absolute level of input segments */
+ int iIdx, /* Index of new output segment */
+ Fts3MultiSegReader *pCsr, /* Cursor that data will be read from */
+ IncrmergeWriter *pWriter /* Populate this object */
+){
+ int rc; /* Return Code */
+ int i; /* Iterator variable */
+ int nLeafEst = 0; /* Blocks allocated for leaf nodes */
+ sqlite3_stmt *pLeafEst = 0; /* SQL used to determine nLeafEst */
+ sqlite3_stmt *pFirstBlock = 0; /* SQL used to determine first block */
+
+ /* Calculate nLeafEst. */
+ rc = fts3SqlStmt(p, SQL_MAX_LEAF_NODE_ESTIMATE, &pLeafEst, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_int64(pLeafEst, 1, iAbsLevel);
+ sqlite3_bind_int64(pLeafEst, 2, pCsr->nSegment);
+ if( SQLITE_ROW==sqlite3_step(pLeafEst) ){
+ nLeafEst = sqlite3_column_int(pLeafEst, 0);
+ }
+ rc = sqlite3_reset(pLeafEst);
+ }
+ if( rc!=SQLITE_OK ) return rc;
+
+ /* Calculate the first block to use in the output segment */
+ rc = fts3SqlStmt(p, SQL_NEXT_SEGMENTS_ID, &pFirstBlock, 0);
+ if( rc==SQLITE_OK ){
+ if( SQLITE_ROW==sqlite3_step(pFirstBlock) ){
+ pWriter->iStart = sqlite3_column_int64(pFirstBlock, 0);
+ pWriter->iEnd = pWriter->iStart - 1;
+ pWriter->iEnd += nLeafEst * FTS_MAX_APPENDABLE_HEIGHT;
+ }
+ rc = sqlite3_reset(pFirstBlock);
+ }
+ if( rc!=SQLITE_OK ) return rc;
+
+ /* Insert the marker in the %_segments table to make sure nobody tries
+ ** to steal the space just allocated. This is also used to identify
+ ** appendable segments. */
+ rc = fts3WriteSegment(p, pWriter->iEnd, 0, 0);
+ if( rc!=SQLITE_OK ) return rc;
+
+ pWriter->iAbsLevel = iAbsLevel;
+ pWriter->nLeafEst = nLeafEst;
+ pWriter->iIdx = iIdx;
+
+ /* Set up the array of NodeWriter objects */
+ for(i=0; i<FTS_MAX_APPENDABLE_HEIGHT; i++){
+ pWriter->aNodeWriter[i].iBlock = pWriter->iStart + i*pWriter->nLeafEst;
+ }
+ return SQLITE_OK;
+}
+
+/*
+** Remove an entry from the %_segdir table. This involves running the
+** following two statements:
+**
+** DELETE FROM %_segdir WHERE level = :iAbsLevel AND idx = :iIdx
+** UPDATE %_segdir SET idx = idx - 1 WHERE level = :iAbsLevel AND idx > :iIdx
+**
+** The DELETE statement removes the specific %_segdir level. The UPDATE
+** statement ensures that the remaining segments have contiguously allocated
+** idx values.
+*/
+static int fts3RemoveSegdirEntry(
+ Fts3Table *p, /* FTS3 table handle */
+ sqlite3_int64 iAbsLevel, /* Absolute level to delete from */
+ int iIdx /* Index of %_segdir entry to delete */
+){
+ int rc; /* Return code */
+ sqlite3_stmt *pDelete = 0; /* DELETE statement */
+
+ rc = fts3SqlStmt(p, SQL_DELETE_SEGDIR_ENTRY, &pDelete, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_int64(pDelete, 1, iAbsLevel);
+ sqlite3_bind_int(pDelete, 2, iIdx);
+ sqlite3_step(pDelete);
+ rc = sqlite3_reset(pDelete);
+ }
+
+ return rc;
+}
+
+/*
+** One or more segments have just been removed from absolute level iAbsLevel.
+** Update the 'idx' values of the remaining segments in the level so that
+** the idx values are a contiguous sequence starting from 0.
+*/
+static int fts3RepackSegdirLevel(
+ Fts3Table *p, /* FTS3 table handle */
+ sqlite3_int64 iAbsLevel /* Absolute level to repack */
+){
+ int rc; /* Return code */
+ int *aIdx = 0; /* Array of remaining idx values */
+ int nIdx = 0; /* Valid entries in aIdx[] */
+ int nAlloc = 0; /* Allocated size of aIdx[] */
+ int i; /* Iterator variable */
+ sqlite3_stmt *pSelect = 0; /* Select statement to read idx values */
+ sqlite3_stmt *pUpdate = 0; /* Update statement to modify idx values */
+
+ rc = fts3SqlStmt(p, SQL_SELECT_INDEXES, &pSelect, 0);
+ if( rc==SQLITE_OK ){
+ int rc2;
+ sqlite3_bind_int64(pSelect, 1, iAbsLevel);
+ while( SQLITE_ROW==sqlite3_step(pSelect) ){
+ if( nIdx>=nAlloc ){
+ int *aNew;
+ nAlloc += 16;
+ aNew = sqlite3_realloc(aIdx, nAlloc*sizeof(int));
+ if( !aNew ){
+ rc = SQLITE_NOMEM;
+ break;
+ }
+ aIdx = aNew;
+ }
+ aIdx[nIdx++] = sqlite3_column_int(pSelect, 0);
+ }
+ rc2 = sqlite3_reset(pSelect);
+ if( rc==SQLITE_OK ) rc = rc2;
+ }
+
+ if( rc==SQLITE_OK ){
+ rc = fts3SqlStmt(p, SQL_SHIFT_SEGDIR_ENTRY, &pUpdate, 0);
+ }
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_int64(pUpdate, 2, iAbsLevel);
+ }
+
+ assert( p->bIgnoreSavepoint==0 );
+ p->bIgnoreSavepoint = 1;
+ for(i=0; rc==SQLITE_OK && i<nIdx; i++){
+ if( aIdx[i]!=i ){
+ sqlite3_bind_int(pUpdate, 3, aIdx[i]);
+ sqlite3_bind_int(pUpdate, 1, i);
+ sqlite3_step(pUpdate);
+ rc = sqlite3_reset(pUpdate);
+ }
+ }
+ p->bIgnoreSavepoint = 0;
+
+ sqlite3_free(aIdx);
+ return rc;
+}
+
+static void fts3StartNode(Blob *pNode, int iHeight, sqlite3_int64 iChild){
+ pNode->a[0] = (char)iHeight;
+ if( iChild ){
+ assert( pNode->nAlloc>=1+sqlite3Fts3VarintLen(iChild) );
+ pNode->n = 1 + sqlite3Fts3PutVarint(&pNode->a[1], iChild);
+ }else{
+ assert( pNode->nAlloc>=1 );
+ pNode->n = 1;
+ }
+}
+
+/*
+** The first two arguments are a pointer to and the size of a segment b-tree
+** node. The node may be a leaf or an internal node.
+**
+** This function creates a new node image in blob object *pNew by copying
+** all terms that are greater than or equal to zTerm/nTerm (for leaf nodes)
+** or greater than zTerm/nTerm (for internal nodes) from aNode/nNode.
+*/
+static int fts3TruncateNode(
+ const char *aNode, /* Current node image */
+ int nNode, /* Size of aNode in bytes */
+ Blob *pNew, /* OUT: Write new node image here */
+ const char *zTerm, /* Omit all terms smaller than this */
+ int nTerm, /* Size of zTerm in bytes */
+ sqlite3_int64 *piBlock /* OUT: Block number in next layer down */
+){
+ NodeReader reader; /* Reader object */
+ Blob prev = {0, 0, 0}; /* Previous term written to new node */
+ int rc = SQLITE_OK; /* Return code */
+ int bLeaf = aNode[0]=='\0'; /* True for a leaf node */
+
+ /* Allocate required output space */
+ blobGrowBuffer(pNew, nNode, &rc);
+ if( rc!=SQLITE_OK ) return rc;
+ pNew->n = 0;
+
+ /* Populate new node buffer */
+ for(rc = nodeReaderInit(&reader, aNode, nNode);
+ rc==SQLITE_OK && reader.aNode;
+ rc = nodeReaderNext(&reader)
+ ){
+ if( pNew->n==0 ){
+ int res = fts3TermCmp(reader.term.a, reader.term.n, zTerm, nTerm);
+ if( res<0 || (bLeaf==0 && res==0) ) continue;
+ fts3StartNode(pNew, (int)aNode[0], reader.iChild);
+ *piBlock = reader.iChild;
+ }
+ rc = fts3AppendToNode(
+ pNew, &prev, reader.term.a, reader.term.n,
+ reader.aDoclist, reader.nDoclist
+ );
+ if( rc!=SQLITE_OK ) break;
+ }
+ if( pNew->n==0 ){
+ fts3StartNode(pNew, (int)aNode[0], reader.iChild);
+ *piBlock = reader.iChild;
+ }
+ assert( pNew->n<=pNew->nAlloc );
+
+ nodeReaderRelease(&reader);
+ sqlite3_free(prev.a);
+ return rc;
+}
+
+/*
+** Remove all terms smaller than zTerm/nTerm from segment iIdx in absolute
+** level iAbsLevel. This may involve deleting entries from the %_segments
+** table, and modifying existing entries in both the %_segments and %_segdir
+** tables.
+**
+** SQLITE_OK is returned if the segment is updated successfully. Or an
+** SQLite error code otherwise.
+*/
+static int fts3TruncateSegment(
+ Fts3Table *p, /* FTS3 table handle */
+ sqlite3_int64 iAbsLevel, /* Absolute level of segment to modify */
+ int iIdx, /* Index within level of segment to modify */
+ const char *zTerm, /* Remove terms smaller than this */
+ int nTerm /* Number of bytes in buffer zTerm */
+){
+ int rc = SQLITE_OK; /* Return code */
+ Blob root = {0,0,0}; /* New root page image */
+ Blob block = {0,0,0}; /* Buffer used for any other block */
+ sqlite3_int64 iBlock = 0; /* Block id */
+ sqlite3_int64 iNewStart = 0; /* New value for iStartBlock */
+ sqlite3_int64 iOldStart = 0; /* Old value for iStartBlock */
+ sqlite3_stmt *pFetch = 0; /* Statement used to fetch segdir */
+
+ rc = fts3SqlStmt(p, SQL_SELECT_SEGDIR, &pFetch, 0);
+ if( rc==SQLITE_OK ){
+ int rc2; /* sqlite3_reset() return code */
+ sqlite3_bind_int64(pFetch, 1, iAbsLevel);
+ sqlite3_bind_int(pFetch, 2, iIdx);
+ if( SQLITE_ROW==sqlite3_step(pFetch) ){
+ const char *aRoot = sqlite3_column_blob(pFetch, 4);
+ int nRoot = sqlite3_column_bytes(pFetch, 4);
+ iOldStart = sqlite3_column_int64(pFetch, 1);
+ rc = fts3TruncateNode(aRoot, nRoot, &root, zTerm, nTerm, &iBlock);
+ }
+ rc2 = sqlite3_reset(pFetch);
+ if( rc==SQLITE_OK ) rc = rc2;
+ }
+
+ while( rc==SQLITE_OK && iBlock ){
+ char *aBlock = 0;
+ int nBlock = 0;
+ iNewStart = iBlock;
+
+ rc = sqlite3Fts3ReadBlock(p, iBlock, &aBlock, &nBlock, 0);
+ if( rc==SQLITE_OK ){
+ rc = fts3TruncateNode(aBlock, nBlock, &block, zTerm, nTerm, &iBlock);
+ }
+ if( rc==SQLITE_OK ){
+ rc = fts3WriteSegment(p, iNewStart, block.a, block.n);
+ }
+ sqlite3_free(aBlock);
+ }
+
+ /* Variable iNewStart now contains the first valid leaf node. */
+ if( rc==SQLITE_OK && iNewStart ){
+ sqlite3_stmt *pDel = 0;
+ rc = fts3SqlStmt(p, SQL_DELETE_SEGMENTS_RANGE, &pDel, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_int64(pDel, 1, iOldStart);
+ sqlite3_bind_int64(pDel, 2, iNewStart-1);
+ sqlite3_step(pDel);
+ rc = sqlite3_reset(pDel);
+ }
+ }
+
+ if( rc==SQLITE_OK ){
+ sqlite3_stmt *pChomp = 0;
+ rc = fts3SqlStmt(p, SQL_CHOMP_SEGDIR, &pChomp, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_int64(pChomp, 1, iNewStart);
+ sqlite3_bind_blob(pChomp, 2, root.a, root.n, SQLITE_STATIC);
+ sqlite3_bind_int64(pChomp, 3, iAbsLevel);
+ sqlite3_bind_int(pChomp, 4, iIdx);
+ sqlite3_step(pChomp);
+ rc = sqlite3_reset(pChomp);
+ }
+ }
+
+ sqlite3_free(root.a);
+ sqlite3_free(block.a);
+ return rc;
+}
+
+/*
+** This function is called after an incrmental-merge operation has run to
+** merge (or partially merge) two or more segments from absolute level
+** iAbsLevel.
+**
+** Each input segment is either removed from the db completely (if all of
+** its data was copied to the output segment by the incrmerge operation)
+** or modified in place so that it no longer contains those entries that
+** have been duplicated in the output segment.
+*/
+static int fts3IncrmergeChomp(
+ Fts3Table *p, /* FTS table handle */
+ sqlite3_int64 iAbsLevel, /* Absolute level containing segments */
+ Fts3MultiSegReader *pCsr, /* Chomp all segments opened by this cursor */
+ int *pnRem /* Number of segments not deleted */
+){
+ int i;
+ int nRem = 0;
+ int rc = SQLITE_OK;
+
+ for(i=pCsr->nSegment-1; i>=0 && rc==SQLITE_OK; i--){
+ Fts3SegReader *pSeg = 0;
+ int j;
+
+ /* Find the Fts3SegReader object with Fts3SegReader.iIdx==i. It is hiding
+ ** somewhere in the pCsr->apSegment[] array. */
+ for(j=0; ALWAYS(j<pCsr->nSegment); j++){
+ pSeg = pCsr->apSegment[j];
+ if( pSeg->iIdx==i ) break;
+ }
+ assert( j<pCsr->nSegment && pSeg->iIdx==i );
+
+ if( pSeg->aNode==0 ){
+ /* Seg-reader is at EOF. Remove the entire input segment. */
+ rc = fts3DeleteSegment(p, pSeg);
+ if( rc==SQLITE_OK ){
+ rc = fts3RemoveSegdirEntry(p, iAbsLevel, pSeg->iIdx);
+ }
+ *pnRem = 0;
+ }else{
+ /* The incremental merge did not copy all the data from this
+ ** segment to the upper level. The segment is modified in place
+ ** so that it contains no keys smaller than zTerm/nTerm. */
+ const char *zTerm = pSeg->zTerm;
+ int nTerm = pSeg->nTerm;
+ rc = fts3TruncateSegment(p, iAbsLevel, pSeg->iIdx, zTerm, nTerm);
+ nRem++;
+ }
+ }
+
+ if( rc==SQLITE_OK && nRem!=pCsr->nSegment ){
+ rc = fts3RepackSegdirLevel(p, iAbsLevel);
+ }
+
+ *pnRem = nRem;
+ return rc;
+}
+
+/*
+** Store an incr-merge hint in the database.
+*/
+static int fts3IncrmergeHintStore(Fts3Table *p, Blob *pHint){
+ sqlite3_stmt *pReplace = 0;
+ int rc; /* Return code */
+
+ rc = fts3SqlStmt(p, SQL_REPLACE_STAT, &pReplace, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_bind_int(pReplace, 1, FTS_STAT_INCRMERGEHINT);
+ sqlite3_bind_blob(pReplace, 2, pHint->a, pHint->n, SQLITE_STATIC);
+ sqlite3_step(pReplace);
+ rc = sqlite3_reset(pReplace);
+ }
+
+ return rc;
+}
+
+/*
+** Load an incr-merge hint from the database. The incr-merge hint, if one
+** exists, is stored in the rowid==1 row of the %_stat table.
+**
+** If successful, populate blob *pHint with the value read from the %_stat
+** table and return SQLITE_OK. Otherwise, if an error occurs, return an
+** SQLite error code.
+*/
+static int fts3IncrmergeHintLoad(Fts3Table *p, Blob *pHint){
+ sqlite3_stmt *pSelect = 0;
+ int rc;
+
+ pHint->n = 0;
+ rc = fts3SqlStmt(p, SQL_SELECT_STAT, &pSelect, 0);
+ if( rc==SQLITE_OK ){
+ int rc2;
+ sqlite3_bind_int(pSelect, 1, FTS_STAT_INCRMERGEHINT);
+ if( SQLITE_ROW==sqlite3_step(pSelect) ){
+ const char *aHint = sqlite3_column_blob(pSelect, 0);
+ int nHint = sqlite3_column_bytes(pSelect, 0);
+ if( aHint ){
+ blobGrowBuffer(pHint, nHint, &rc);
+ if( rc==SQLITE_OK ){
+ memcpy(pHint->a, aHint, nHint);
+ pHint->n = nHint;
+ }
+ }
+ }
+ rc2 = sqlite3_reset(pSelect);
+ if( rc==SQLITE_OK ) rc = rc2;
+ }
+
+ return rc;
+}
+
+/*
+** If *pRc is not SQLITE_OK when this function is called, it is a no-op.
+** Otherwise, append an entry to the hint stored in blob *pHint. Each entry
+** consists of two varints, the absolute level number of the input segments
+** and the number of input segments.
+**
+** If successful, leave *pRc set to SQLITE_OK and return. If an error occurs,
+** set *pRc to an SQLite error code before returning.
+*/
+static void fts3IncrmergeHintPush(
+ Blob *pHint, /* Hint blob to append to */
+ i64 iAbsLevel, /* First varint to store in hint */
+ int nInput, /* Second varint to store in hint */
+ int *pRc /* IN/OUT: Error code */
+){
+ blobGrowBuffer(pHint, pHint->n + 2*FTS3_VARINT_MAX, pRc);
+ if( *pRc==SQLITE_OK ){
+ pHint->n += sqlite3Fts3PutVarint(&pHint->a[pHint->n], iAbsLevel);
+ pHint->n += sqlite3Fts3PutVarint(&pHint->a[pHint->n], (i64)nInput);
+ }
+}
+
+/*
+** Read the last entry (most recently pushed) from the hint blob *pHint
+** and then remove the entry. Write the two values read to *piAbsLevel and
+** *pnInput before returning.
+**
+** If no error occurs, return SQLITE_OK. If the hint blob in *pHint does
+** not contain at least two valid varints, return SQLITE_CORRUPT_VTAB.
+*/
+static int fts3IncrmergeHintPop(Blob *pHint, i64 *piAbsLevel, int *pnInput){
+ const int nHint = pHint->n;
+ int i;
+
+ i = pHint->n-2;
+ while( i>0 && (pHint->a[i-1] & 0x80) ) i--;
+ while( i>0 && (pHint->a[i-1] & 0x80) ) i--;
+
+ pHint->n = i;
+ i += sqlite3Fts3GetVarint(&pHint->a[i], piAbsLevel);
+ i += sqlite3Fts3GetVarint32(&pHint->a[i], pnInput);
+ if( i!=nHint ) return SQLITE_CORRUPT_VTAB;
+
+ return SQLITE_OK;
+}
+
+
+/*
+** Attempt an incremental merge that writes nMerge leaf blocks.
+**
+** Incremental merges happen nMin segments at a time. The two
+** segments to be merged are the nMin oldest segments (the ones with
+** the smallest indexes) in the highest level that contains at least
+** nMin segments. Multiple merges might occur in an attempt to write the
+** quota of nMerge leaf blocks.
+*/
+SQLITE_PRIVATE int sqlite3Fts3Incrmerge(Fts3Table *p, int nMerge, int nMin){
+ int rc; /* Return code */
+ int nRem = nMerge; /* Number of leaf pages yet to be written */
+ Fts3MultiSegReader *pCsr; /* Cursor used to read input data */
+ Fts3SegFilter *pFilter; /* Filter used with cursor pCsr */
+ IncrmergeWriter *pWriter; /* Writer object */
+ int nSeg = 0; /* Number of input segments */
+ sqlite3_int64 iAbsLevel = 0; /* Absolute level number to work on */
+ Blob hint = {0, 0, 0}; /* Hint read from %_stat table */
+ int bDirtyHint = 0; /* True if blob 'hint' has been modified */
+
+ /* Allocate space for the cursor, filter and writer objects */
+ const int nAlloc = sizeof(*pCsr) + sizeof(*pFilter) + sizeof(*pWriter);
+ pWriter = (IncrmergeWriter *)sqlite3_malloc(nAlloc);
+ if( !pWriter ) return SQLITE_NOMEM;
+ pFilter = (Fts3SegFilter *)&pWriter[1];
+ pCsr = (Fts3MultiSegReader *)&pFilter[1];
+
+ rc = fts3IncrmergeHintLoad(p, &hint);
+ while( rc==SQLITE_OK && nRem>0 ){
+ const i64 nMod = FTS3_SEGDIR_MAXLEVEL * p->nIndex;
+ sqlite3_stmt *pFindLevel = 0; /* SQL used to determine iAbsLevel */
+ int bUseHint = 0; /* True if attempting to append */
+
+ /* Search the %_segdir table for the absolute level with the smallest
+ ** relative level number that contains at least nMin segments, if any.
+ ** If one is found, set iAbsLevel to the absolute level number and
+ ** nSeg to nMin. If no level with at least nMin segments can be found,
+ ** set nSeg to -1.
+ */
+ rc = fts3SqlStmt(p, SQL_FIND_MERGE_LEVEL, &pFindLevel, 0);
+ sqlite3_bind_int(pFindLevel, 1, nMin);
+ if( sqlite3_step(pFindLevel)==SQLITE_ROW ){
+ iAbsLevel = sqlite3_column_int64(pFindLevel, 0);
+ nSeg = nMin;
+ }else{
+ nSeg = -1;
+ }
+ rc = sqlite3_reset(pFindLevel);
+
+ /* If the hint read from the %_stat table is not empty, check if the
+ ** last entry in it specifies a relative level smaller than or equal
+ ** to the level identified by the block above (if any). If so, this
+ ** iteration of the loop will work on merging at the hinted level.
+ */
+ if( rc==SQLITE_OK && hint.n ){
+ int nHint = hint.n;
+ sqlite3_int64 iHintAbsLevel = 0; /* Hint level */
+ int nHintSeg = 0; /* Hint number of segments */
+
+ rc = fts3IncrmergeHintPop(&hint, &iHintAbsLevel, &nHintSeg);
+ if( nSeg<0 || (iAbsLevel % nMod) >= (iHintAbsLevel % nMod) ){
+ iAbsLevel = iHintAbsLevel;
+ nSeg = nHintSeg;
+ bUseHint = 1;
+ bDirtyHint = 1;
+ }else{
+ /* This undoes the effect of the HintPop() above - so that no entry
+ ** is removed from the hint blob. */
+ hint.n = nHint;
+ }
+ }
+
+ /* If nSeg is less that zero, then there is no level with at least
+ ** nMin segments and no hint in the %_stat table. No work to do.
+ ** Exit early in this case. */
+ if( nSeg<0 ) break;
+
+ /* Open a cursor to iterate through the contents of the oldest nSeg
+ ** indexes of absolute level iAbsLevel. If this cursor is opened using
+ ** the 'hint' parameters, it is possible that there are less than nSeg
+ ** segments available in level iAbsLevel. In this case, no work is
+ ** done on iAbsLevel - fall through to the next iteration of the loop
+ ** to start work on some other level. */
+ memset(pWriter, 0, nAlloc);
+ pFilter->flags = FTS3_SEGMENT_REQUIRE_POS;
+ if( rc==SQLITE_OK ){
+ rc = fts3IncrmergeCsr(p, iAbsLevel, nSeg, pCsr);
+ }
+ if( SQLITE_OK==rc && pCsr->nSegment==nSeg
+ && SQLITE_OK==(rc = sqlite3Fts3SegReaderStart(p, pCsr, pFilter))
+ && SQLITE_ROW==(rc = sqlite3Fts3SegReaderStep(p, pCsr))
+ ){
+ int iIdx = 0; /* Largest idx in level (iAbsLevel+1) */
+ rc = fts3IncrmergeOutputIdx(p, iAbsLevel, &iIdx);
+ if( rc==SQLITE_OK ){
+ if( bUseHint && iIdx>0 ){
+ const char *zKey = pCsr->zTerm;
+ int nKey = pCsr->nTerm;
+ rc = fts3IncrmergeLoad(p, iAbsLevel, iIdx-1, zKey, nKey, pWriter);
+ }else{
+ rc = fts3IncrmergeWriter(p, iAbsLevel, iIdx, pCsr, pWriter);
+ }
+ }
+
+ if( rc==SQLITE_OK && pWriter->nLeafEst ){
+ fts3LogMerge(nSeg, iAbsLevel);
+ do {
+ rc = fts3IncrmergeAppend(p, pWriter, pCsr);
+ if( rc==SQLITE_OK ) rc = sqlite3Fts3SegReaderStep(p, pCsr);
+ if( pWriter->nWork>=nRem && rc==SQLITE_ROW ) rc = SQLITE_OK;
+ }while( rc==SQLITE_ROW );
+
+ /* Update or delete the input segments */
+ if( rc==SQLITE_OK ){
+ nRem -= (1 + pWriter->nWork);
+ rc = fts3IncrmergeChomp(p, iAbsLevel, pCsr, &nSeg);
+ if( nSeg!=0 ){
+ bDirtyHint = 1;
+ fts3IncrmergeHintPush(&hint, iAbsLevel, nSeg, &rc);
+ }
+ }
+ }
+
+ fts3IncrmergeRelease(p, pWriter, &rc);
+ }
+
+ sqlite3Fts3SegReaderFinish(pCsr);
+ }
+
+ /* Write the hint values into the %_stat table for the next incr-merger */
+ if( bDirtyHint && rc==SQLITE_OK ){
+ rc = fts3IncrmergeHintStore(p, &hint);
+ }
+
+ sqlite3_free(pWriter);
+ sqlite3_free(hint.a);
+ return rc;
+}
+
+/*
+** Convert the text beginning at *pz into an integer and return
+** its value. Advance *pz to point to the first character past
+** the integer.
+*/
+static int fts3Getint(const char **pz){
+ const char *z = *pz;
+ int i = 0;
+ while( (*z)>='0' && (*z)<='9' ) i = 10*i + *(z++) - '0';
+ *pz = z;
+ return i;
+}
+
+/*
+** Process statements of the form:
+**
+** INSERT INTO table(table) VALUES('merge=A,B');
+**
+** A and B are integers that decode to be the number of leaf pages
+** written for the merge, and the minimum number of segments on a level
+** before it will be selected for a merge, respectively.
+*/
+static int fts3DoIncrmerge(
+ Fts3Table *p, /* FTS3 table handle */
+ const char *zParam /* Nul-terminated string containing "A,B" */
+){
+ int rc;
+ int nMin = (FTS3_MERGE_COUNT / 2);
+ int nMerge = 0;
+ const char *z = zParam;
+
+ /* Read the first integer value */
+ nMerge = fts3Getint(&z);
+
+ /* If the first integer value is followed by a ',', read the second
+ ** integer value. */
+ if( z[0]==',' && z[1]!='\0' ){
+ z++;
+ nMin = fts3Getint(&z);
+ }
+
+ if( z[0]!='\0' || nMin<2 ){
+ rc = SQLITE_ERROR;
+ }else{
+ rc = SQLITE_OK;
+ if( !p->bHasStat ){
+ assert( p->bFts4==0 );
+ sqlite3Fts3CreateStatTable(&rc, p);
+ }
+ if( rc==SQLITE_OK ){
+ rc = sqlite3Fts3Incrmerge(p, nMerge, nMin);
+ }
+ sqlite3Fts3SegmentsClose(p);
+ }
+ return rc;
+}
+
+/*
+** Process statements of the form:
+**
+** INSERT INTO table(table) VALUES('automerge=X');
+**
+** where X is an integer. X==0 means to turn automerge off. X!=0 means
+** turn it on. The setting is persistent.
+*/
+static int fts3DoAutoincrmerge(
+ Fts3Table *p, /* FTS3 table handle */
+ const char *zParam /* Nul-terminated string containing boolean */
+){
+ int rc = SQLITE_OK;
+ sqlite3_stmt *pStmt = 0;
+ p->bAutoincrmerge = fts3Getint(&zParam)!=0;
+ if( !p->bHasStat ){
+ assert( p->bFts4==0 );
+ sqlite3Fts3CreateStatTable(&rc, p);
+ if( rc ) return rc;
+ }
+ rc = fts3SqlStmt(p, SQL_REPLACE_STAT, &pStmt, 0);
+ if( rc ) return rc;;
+ sqlite3_bind_int(pStmt, 1, FTS_STAT_AUTOINCRMERGE);
+ sqlite3_bind_int(pStmt, 2, p->bAutoincrmerge);
+ sqlite3_step(pStmt);
+ rc = sqlite3_reset(pStmt);
+ return rc;
+}
+
+/*
+** Return a 64-bit checksum for the FTS index entry specified by the
+** arguments to this function.
+*/
+static u64 fts3ChecksumEntry(
+ const char *zTerm, /* Pointer to buffer containing term */
+ int nTerm, /* Size of zTerm in bytes */
+ int iLangid, /* Language id for current row */
+ int iIndex, /* Index (0..Fts3Table.nIndex-1) */
+ i64 iDocid, /* Docid for current row. */
+ int iCol, /* Column number */
+ int iPos /* Position */
+){
+ int i;
+ u64 ret = (u64)iDocid;
+
+ ret += (ret<<3) + iLangid;
+ ret += (ret<<3) + iIndex;
+ ret += (ret<<3) + iCol;
+ ret += (ret<<3) + iPos;
+ for(i=0; i<nTerm; i++) ret += (ret<<3) + zTerm[i];
+
+ return ret;
+}
+
+/*
+** Return a checksum of all entries in the FTS index that correspond to
+** language id iLangid. The checksum is calculated by XORing the checksums
+** of each individual entry (see fts3ChecksumEntry()) together.
+**
+** If successful, the checksum value is returned and *pRc set to SQLITE_OK.
+** Otherwise, if an error occurs, *pRc is set to an SQLite error code. The
+** return value is undefined in this case.
+*/
+static u64 fts3ChecksumIndex(
+ Fts3Table *p, /* FTS3 table handle */
+ int iLangid, /* Language id to return cksum for */
+ int iIndex, /* Index to cksum (0..p->nIndex-1) */
+ int *pRc /* OUT: Return code */
+){
+ Fts3SegFilter filter;
+ Fts3MultiSegReader csr;
+ int rc;
+ u64 cksum = 0;
+
+ assert( *pRc==SQLITE_OK );
+
+ memset(&filter, 0, sizeof(filter));
+ memset(&csr, 0, sizeof(csr));
+ filter.flags = FTS3_SEGMENT_REQUIRE_POS|FTS3_SEGMENT_IGNORE_EMPTY;
+ filter.flags |= FTS3_SEGMENT_SCAN;
+
+ rc = sqlite3Fts3SegReaderCursor(
+ p, iLangid, iIndex, FTS3_SEGCURSOR_ALL, 0, 0, 0, 1,&csr
+ );
+ if( rc==SQLITE_OK ){
+ rc = sqlite3Fts3SegReaderStart(p, &csr, &filter);
+ }
+
+ if( rc==SQLITE_OK ){
+ while( SQLITE_ROW==(rc = sqlite3Fts3SegReaderStep(p, &csr)) ){
+ char *pCsr = csr.aDoclist;
+ char *pEnd = &pCsr[csr.nDoclist];
+
+ i64 iDocid = 0;
+ i64 iCol = 0;
+ i64 iPos = 0;
+
+ pCsr += sqlite3Fts3GetVarint(pCsr, &iDocid);
+ while( pCsr<pEnd ){
+ i64 iVal = 0;
+ pCsr += sqlite3Fts3GetVarint(pCsr, &iVal);
+ if( pCsr<pEnd ){
+ if( iVal==0 || iVal==1 ){
+ iCol = 0;
+ iPos = 0;
+ if( iVal ){
+ pCsr += sqlite3Fts3GetVarint(pCsr, &iCol);
+ }else{
+ pCsr += sqlite3Fts3GetVarint(pCsr, &iVal);
+ iDocid += iVal;
+ }
+ }else{
+ iPos += (iVal - 2);
+ cksum = cksum ^ fts3ChecksumEntry(
+ csr.zTerm, csr.nTerm, iLangid, iIndex, iDocid,
+ (int)iCol, (int)iPos
+ );
+ }
+ }
+ }
+ }
+ }
+ sqlite3Fts3SegReaderFinish(&csr);
+
+ *pRc = rc;
+ return cksum;
+}
+
+/*
+** Check if the contents of the FTS index match the current contents of the
+** content table. If no error occurs and the contents do match, set *pbOk
+** to true and return SQLITE_OK. Or if the contents do not match, set *pbOk
+** to false before returning.
+**
+** If an error occurs (e.g. an OOM or IO error), return an SQLite error
+** code. The final value of *pbOk is undefined in this case.
+*/
+static int fts3IntegrityCheck(Fts3Table *p, int *pbOk){
+ int rc = SQLITE_OK; /* Return code */
+ u64 cksum1 = 0; /* Checksum based on FTS index contents */
+ u64 cksum2 = 0; /* Checksum based on %_content contents */
+ sqlite3_stmt *pAllLangid = 0; /* Statement to return all language-ids */
+
+ /* This block calculates the checksum according to the FTS index. */
+ rc = fts3SqlStmt(p, SQL_SELECT_ALL_LANGID, &pAllLangid, 0);
+ if( rc==SQLITE_OK ){
+ int rc2;
+ sqlite3_bind_int(pAllLangid, 1, p->nIndex);
+ while( rc==SQLITE_OK && sqlite3_step(pAllLangid)==SQLITE_ROW ){
+ int iLangid = sqlite3_column_int(pAllLangid, 0);
+ int i;
+ for(i=0; i<p->nIndex; i++){
+ cksum1 = cksum1 ^ fts3ChecksumIndex(p, iLangid, i, &rc);
+ }
+ }
+ rc2 = sqlite3_reset(pAllLangid);
+ if( rc==SQLITE_OK ) rc = rc2;
+ }
+
+ /* This block calculates the checksum according to the %_content table */
+ rc = fts3SqlStmt(p, SQL_SELECT_ALL_LANGID, &pAllLangid, 0);
+ if( rc==SQLITE_OK ){
+ sqlite3_tokenizer_module const *pModule = p->pTokenizer->pModule;
+ sqlite3_stmt *pStmt = 0;
+ char *zSql;
+
+ zSql = sqlite3_mprintf("SELECT %s" , p->zReadExprlist);
+ if( !zSql ){
+ rc = SQLITE_NOMEM;
+ }else{
+ rc = sqlite3_prepare_v2(p->db, zSql, -1, &pStmt, 0);
+ sqlite3_free(zSql);
+ }
+
+ while( rc==SQLITE_OK && SQLITE_ROW==sqlite3_step(pStmt) ){
+ i64 iDocid = sqlite3_column_int64(pStmt, 0);
+ int iLang = langidFromSelect(p, pStmt);
+ int iCol;
+
+ for(iCol=0; rc==SQLITE_OK && iCol<p->nColumn; iCol++){
+ const char *zText = (const char *)sqlite3_column_text(pStmt, iCol+1);
+ int nText = sqlite3_column_bytes(pStmt, iCol+1);
+ sqlite3_tokenizer_cursor *pT = 0;
+
+ rc = sqlite3Fts3OpenTokenizer(p->pTokenizer, iLang, zText, nText, &pT);
+ while( rc==SQLITE_OK ){
+ char const *zToken; /* Buffer containing token */
+ int nToken = 0; /* Number of bytes in token */
+ int iDum1 = 0, iDum2 = 0; /* Dummy variables */
+ int iPos = 0; /* Position of token in zText */
+
+ rc = pModule->xNext(pT, &zToken, &nToken, &iDum1, &iDum2, &iPos);
+ if( rc==SQLITE_OK ){
+ int i;
+ cksum2 = cksum2 ^ fts3ChecksumEntry(
+ zToken, nToken, iLang, 0, iDocid, iCol, iPos
+ );
+ for(i=1; i<p->nIndex; i++){
+ if( p->aIndex[i].nPrefix<=nToken ){
+ cksum2 = cksum2 ^ fts3ChecksumEntry(
+ zToken, p->aIndex[i].nPrefix, iLang, i, iDocid, iCol, iPos
+ );
+ }
+ }
+ }
+ }
+ if( pT ) pModule->xClose(pT);
+ if( rc==SQLITE_DONE ) rc = SQLITE_OK;
+ }
+ }
+
+ sqlite3_finalize(pStmt);
+ }
+
+ *pbOk = (cksum1==cksum2);
+ return rc;
+}
+
+/*
+** Run the integrity-check. If no error occurs and the current contents of
+** the FTS index are correct, return SQLITE_OK. Or, if the contents of the
+** FTS index are incorrect, return SQLITE_CORRUPT_VTAB.
+**
+** Or, if an error (e.g. an OOM or IO error) occurs, return an SQLite
+** error code.
+**
+** The integrity-check works as follows. For each token and indexed token
+** prefix in the document set, a 64-bit checksum is calculated (by code
+** in fts3ChecksumEntry()) based on the following:
+**
+** + The index number (0 for the main index, 1 for the first prefix
+** index etc.),
+** + The token (or token prefix) text itself,
+** + The language-id of the row it appears in,
+** + The docid of the row it appears in,
+** + The column it appears in, and
+** + The tokens position within that column.
+**
+** The checksums for all entries in the index are XORed together to create
+** a single checksum for the entire index.
+**
+** The integrity-check code calculates the same checksum in two ways:
+**
+** 1. By scanning the contents of the FTS index, and
+** 2. By scanning and tokenizing the content table.
+**
+** If the two checksums are identical, the integrity-check is deemed to have
+** passed.
+*/
+static int fts3DoIntegrityCheck(
+ Fts3Table *p /* FTS3 table handle */
+){
+ int rc;
+ int bOk = 0;
+ rc = fts3IntegrityCheck(p, &bOk);
+ if( rc==SQLITE_OK && bOk==0 ) rc = SQLITE_CORRUPT_VTAB;
+ return rc;
+}
+
+/*
** Handle a 'special' INSERT of the form:
**
** "INSERT INTO tbl(tbl) VALUES(<expr>)"
@@ -122576,6 +131323,14 @@ static int fts3SpecialInsert(Fts3Table *p, sqlite3_value *pVal){
return SQLITE_NOMEM;
}else if( nVal==8 && 0==sqlite3_strnicmp(zVal, "optimize", 8) ){
rc = fts3DoOptimize(p, 0);
+ }else if( nVal==7 && 0==sqlite3_strnicmp(zVal, "rebuild", 7) ){
+ rc = fts3DoRebuild(p);
+ }else if( nVal==15 && 0==sqlite3_strnicmp(zVal, "integrity-check", 15) ){
+ rc = fts3DoIntegrityCheck(p);
+ }else if( nVal>6 && 0==sqlite3_strnicmp(zVal, "merge=", 6) ){
+ rc = fts3DoIncrmerge(p, &zVal[6]);
+ }else if( nVal>10 && 0==sqlite3_strnicmp(zVal, "automerge=", 10) ){
+ rc = fts3DoAutoincrmerge(p, &zVal[10]);
#ifdef SQLITE_TEST
}else if( nVal>9 && 0==sqlite3_strnicmp(zVal, "nodesize=", 9) ){
p->nNodeSize = atoi(&zVal[9]);
@@ -122591,6 +131346,7 @@ static int fts3SpecialInsert(Fts3Table *p, sqlite3_value *pVal){
return rc;
}
+#ifndef SQLITE_DISABLE_FTS4_DEFERRED
/*
** Delete all cached deferred doclists. Deferred doclists are cached
** (allocated) by the sqlite3Fts3CacheDeferredDoclists() function.
@@ -122644,18 +131400,18 @@ SQLITE_PRIVATE int sqlite3Fts3CacheDeferredDoclists(Fts3Cursor *pCsr){
const char *zText = (const char *)sqlite3_column_text(pCsr->pStmt, i+1);
sqlite3_tokenizer_cursor *pTC = 0;
- rc = pModule->xOpen(pT, zText, -1, &pTC);
+ rc = sqlite3Fts3OpenTokenizer(pT, pCsr->iLangid, zText, -1, &pTC);
while( rc==SQLITE_OK ){
char const *zToken; /* Buffer containing token */
- int nToken; /* Number of bytes in token */
- int iDum1, iDum2; /* Dummy variables */
- int iPos; /* Position of token in zText */
+ int nToken = 0; /* Number of bytes in token */
+ int iDum1 = 0, iDum2 = 0; /* Dummy variables */
+ int iPos = 0; /* Position of token in zText */
- pTC->pTokenizer = pT;
rc = pModule->xNext(pTC, &zToken, &nToken, &iDum1, &iDum2, &iPos);
for(pDef=pCsr->pDeferred; pDef && rc==SQLITE_OK; pDef=pDef->pNext){
Fts3PhraseToken *pPT = pDef->pToken;
if( (pDef->iCol>=p->nColumn || pDef->iCol==i)
+ && (pPT->bFirst==0 || iPos==0)
&& (pPT->n==nToken || (pPT->isPrefix && pPT->n<nToken))
&& (0==memcmp(zToken, pPT->z, pPT->n))
){
@@ -122728,6 +131484,7 @@ SQLITE_PRIVATE int sqlite3Fts3DeferToken(
return SQLITE_OK;
}
+#endif
/*
** SQLite value pRowid contains the rowid of a row that may or may not be
@@ -122737,26 +131494,32 @@ SQLITE_PRIVATE int sqlite3Fts3DeferToken(
static int fts3DeleteByRowid(
Fts3Table *p,
sqlite3_value *pRowid,
- int *pnDoc,
+ int *pnChng, /* IN/OUT: Decrement if row is deleted */
u32 *aSzDel
){
- int isEmpty = 0;
- int rc = fts3IsEmpty(p, pRowid, &isEmpty);
- if( rc==SQLITE_OK ){
- if( isEmpty ){
- /* Deleting this row means the whole table is empty. In this case
- ** delete the contents of all three tables and throw away any
- ** data in the pendingTerms hash table. */
- rc = fts3DeleteAll(p);
- *pnDoc = *pnDoc - 1;
- }else{
- sqlite3_int64 iRemove = sqlite3_value_int64(pRowid);
- rc = fts3PendingTermsDocid(p, iRemove);
- fts3DeleteTerms(&rc, p, pRowid, aSzDel);
- fts3SqlExec(&rc, p, SQL_DELETE_CONTENT, &pRowid);
- if( sqlite3_changes(p->db) ) *pnDoc = *pnDoc - 1;
- if( p->bHasDocsize ){
- fts3SqlExec(&rc, p, SQL_DELETE_DOCSIZE, &pRowid);
+ int rc = SQLITE_OK; /* Return code */
+ int bFound = 0; /* True if *pRowid really is in the table */
+
+ fts3DeleteTerms(&rc, p, pRowid, aSzDel, &bFound);
+ if( bFound && rc==SQLITE_OK ){
+ int isEmpty = 0; /* Deleting *pRowid leaves the table empty */
+ rc = fts3IsEmpty(p, pRowid, &isEmpty);
+ if( rc==SQLITE_OK ){
+ if( isEmpty ){
+ /* Deleting this row means the whole table is empty. In this case
+ ** delete the contents of all three tables and throw away any
+ ** data in the pendingTerms hash table. */
+ rc = fts3DeleteAll(p, 1);
+ *pnChng = 0;
+ memset(aSzDel, 0, sizeof(u32) * (p->nColumn+1) * 2);
+ }else{
+ *pnChng = *pnChng - 1;
+ if( p->zContentTbl==0 ){
+ fts3SqlExec(&rc, p, SQL_DELETE_CONTENT, &pRowid);
+ }
+ if( p->bHasDocsize ){
+ fts3SqlExec(&rc, p, SQL_DELETE_DOCSIZE, &pRowid);
+ }
}
}
}
@@ -122766,7 +131529,16 @@ static int fts3DeleteByRowid(
/*
** This function does the work for the xUpdate method of FTS3 virtual
-** tables.
+** tables. The schema of the virtual table being:
+**
+** CREATE TABLE <table name>(
+** <user columns>,
+** <table name> HIDDEN,
+** docid HIDDEN,
+** <langid> HIDDEN
+** );
+**
+**
*/
SQLITE_PRIVATE int sqlite3Fts3UpdateMethod(
sqlite3_vtab *pVtab, /* FTS3 vtab object */
@@ -122777,13 +131549,16 @@ SQLITE_PRIVATE int sqlite3Fts3UpdateMethod(
Fts3Table *p = (Fts3Table *)pVtab;
int rc = SQLITE_OK; /* Return Code */
int isRemove = 0; /* True for an UPDATE or DELETE */
- sqlite3_int64 iRemove = 0; /* Rowid removed by UPDATE or DELETE */
u32 *aSzIns = 0; /* Sizes of inserted documents */
- u32 *aSzDel; /* Sizes of deleted documents */
+ u32 *aSzDel = 0; /* Sizes of deleted documents */
int nChng = 0; /* Net change in number of documents */
int bInsertDone = 0;
assert( p->pSegments==0 );
+ assert(
+ nArg==1 /* DELETE operations */
+ || nArg==(2 + p->nColumn + 3) /* INSERT or UPDATE operations */
+ );
/* Check for a "special" INSERT operation. One of the form:
**
@@ -122797,14 +131572,19 @@ SQLITE_PRIVATE int sqlite3Fts3UpdateMethod(
goto update_out;
}
+ if( nArg>1 && sqlite3_value_int(apVal[2 + p->nColumn + 2])<0 ){
+ rc = SQLITE_CONSTRAINT;
+ goto update_out;
+ }
+
/* Allocate space to hold the change in document sizes */
- aSzIns = sqlite3_malloc( sizeof(aSzIns[0])*(p->nColumn+1)*2 );
- if( aSzIns==0 ){
+ aSzDel = sqlite3_malloc( sizeof(aSzDel[0])*(p->nColumn+1)*2 );
+ if( aSzDel==0 ){
rc = SQLITE_NOMEM;
goto update_out;
}
- aSzDel = &aSzIns[p->nColumn+1];
- memset(aSzIns, 0, sizeof(aSzIns[0])*(p->nColumn+1)*2);
+ aSzIns = &aSzDel[p->nColumn+1];
+ memset(aSzDel, 0, sizeof(aSzDel[0])*(p->nColumn+1)*2);
/* If this is an INSERT operation, or an UPDATE that modifies the rowid
** value, then this operation requires constraint handling.
@@ -122815,7 +131595,7 @@ SQLITE_PRIVATE int sqlite3Fts3UpdateMethod(
** detect the conflict and return SQLITE_CONSTRAINT before beginning to
** modify the database file.
*/
- if( nArg>1 ){
+ if( nArg>1 && p->zContentTbl==0 ){
/* Find the value object that holds the new rowid value. */
sqlite3_value *pNewRowid = apVal[3+p->nColumn];
if( sqlite3_value_type(pNewRowid)==SQLITE_NULL ){
@@ -122860,20 +131640,23 @@ SQLITE_PRIVATE int sqlite3Fts3UpdateMethod(
assert( sqlite3_value_type(apVal[0])==SQLITE_INTEGER );
rc = fts3DeleteByRowid(p, apVal[0], &nChng, aSzDel);
isRemove = 1;
- iRemove = sqlite3_value_int64(apVal[0]);
}
/* If this is an INSERT or UPDATE operation, insert the new record. */
if( nArg>1 && rc==SQLITE_OK ){
+ int iLangid = sqlite3_value_int(apVal[2 + p->nColumn + 2]);
if( bInsertDone==0 ){
rc = fts3InsertData(p, apVal, pRowid);
- if( rc==SQLITE_CONSTRAINT ) rc = SQLITE_CORRUPT_VTAB;
+ if( rc==SQLITE_CONSTRAINT && p->zContentTbl==0 ){
+ rc = FTS_CORRUPT_VTAB;
+ }
}
- if( rc==SQLITE_OK && (!isRemove || *pRowid!=iRemove) ){
- rc = fts3PendingTermsDocid(p, *pRowid);
+ if( rc==SQLITE_OK && (!isRemove || *pRowid!=p->iPrevDocid ) ){
+ rc = fts3PendingTermsDocid(p, iLangid, *pRowid);
}
if( rc==SQLITE_OK ){
- rc = fts3InsertTerms(p, apVal, aSzIns);
+ assert( p->iPrevDocid==*pRowid );
+ rc = fts3InsertTerms(p, iLangid, apVal, aSzIns);
}
if( p->bHasDocsize ){
fts3InsertDocsize(&rc, p, aSzIns);
@@ -122881,12 +131664,12 @@ SQLITE_PRIVATE int sqlite3Fts3UpdateMethod(
nChng++;
}
- if( p->bHasStat ){
+ if( p->bFts4 ){
fts3UpdateDocTotals(&rc, p, aSzIns, aSzDel, nChng);
}
update_out:
- sqlite3_free(aSzIns);
+ sqlite3_free(aSzDel);
sqlite3Fts3SegmentsClose(p);
return rc;
}
@@ -122932,6 +131715,8 @@ SQLITE_PRIVATE int sqlite3Fts3Optimize(Fts3Table *p){
#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3)
+/* #include <string.h> */
+/* #include <assert.h> */
/*
** Characters that may appear in the second argument to matchinfo().
@@ -123276,23 +132061,27 @@ static int fts3SnippetFindPositions(Fts3Expr *pExpr, int iPhrase, void *ctx){
SnippetIter *p = (SnippetIter *)ctx;
SnippetPhrase *pPhrase = &p->aPhrase[iPhrase];
char *pCsr;
+ int rc;
pPhrase->nToken = pExpr->pPhrase->nToken;
-
- pCsr = sqlite3Fts3EvalPhrasePoslist(p->pCsr, pExpr, p->iCol);
+ rc = sqlite3Fts3EvalPhrasePoslist(p->pCsr, pExpr, p->iCol, &pCsr);
+ assert( rc==SQLITE_OK || pCsr==0 );
if( pCsr ){
int iFirst = 0;
pPhrase->pList = pCsr;
fts3GetDeltaPosition(&pCsr, &iFirst);
+ assert( iFirst>=0 );
pPhrase->pHead = pCsr;
pPhrase->pTail = pCsr;
pPhrase->iHead = iFirst;
pPhrase->iTail = iFirst;
}else{
- assert( pPhrase->pList==0 && pPhrase->pHead==0 && pPhrase->pTail==0 );
+ assert( rc!=SQLITE_OK || (
+ pPhrase->pList==0 && pPhrase->pHead==0 && pPhrase->pTail==0
+ ));
}
- return SQLITE_OK;
+ return rc;
}
/*
@@ -123301,9 +132090,9 @@ static int fts3SnippetFindPositions(Fts3Expr *pExpr, int iPhrase, void *ctx){
** is the snippet with the highest score, where scores are calculated
** by adding:
**
-** (a) +1 point for each occurence of a matchable phrase in the snippet.
+** (a) +1 point for each occurrence of a matchable phrase in the snippet.
**
-** (b) +1000 points for the first occurence of each matchable phrase in
+** (b) +1000 points for the first occurrence of each matchable phrase in
** the snippet for which the corresponding mCovered bit is not set.
**
** The selected snippet parameters are stored in structure *pFragment before
@@ -123447,6 +132236,7 @@ static int fts3StringAppend(
*/
static int fts3SnippetShift(
Fts3Table *pTab, /* FTS3 table snippet comes from */
+ int iLangid, /* Language id to use in tokenizing */
int nSnippet, /* Number of tokens desired for snippet */
const char *zDoc, /* Document text to extract snippet from */
int nDoc, /* Size of buffer zDoc in bytes */
@@ -123482,13 +132272,12 @@ static int fts3SnippetShift(
/* Open a cursor on zDoc/nDoc. Check if there are (nSnippet+nDesired)
** or more tokens in zDoc/nDoc.
*/
- rc = pMod->xOpen(pTab->pTokenizer, zDoc, nDoc, &pC);
+ rc = sqlite3Fts3OpenTokenizer(pTab->pTokenizer, iLangid, zDoc, nDoc, &pC);
if( rc!=SQLITE_OK ){
return rc;
}
- pC->pTokenizer = pTab->pTokenizer;
while( rc==SQLITE_OK && iCurrent<(nSnippet+nDesired) ){
- const char *ZDUMMY; int DUMMY1, DUMMY2, DUMMY3;
+ const char *ZDUMMY; int DUMMY1 = 0, DUMMY2 = 0, DUMMY3 = 0;
rc = pMod->xNext(pC, &ZDUMMY, &DUMMY1, &DUMMY2, &DUMMY3, &iCurrent);
}
pMod->xClose(pC);
@@ -123532,8 +132321,6 @@ static int fts3SnippetText(
int iCol = pFragment->iCol+1; /* Query column to extract text from */
sqlite3_tokenizer_module *pMod; /* Tokenizer module methods object */
sqlite3_tokenizer_cursor *pC; /* Tokenizer cursor open on zDoc/nDoc */
- const char *ZDUMMY; /* Dummy argument used with tokenizer */
- int DUMMY1; /* Dummy argument used with tokenizer */
zDoc = (const char *)sqlite3_column_text(pCsr->pStmt, iCol);
if( zDoc==0 ){
@@ -123546,17 +132333,29 @@ static int fts3SnippetText(
/* Open a token cursor on the document. */
pMod = (sqlite3_tokenizer_module *)pTab->pTokenizer->pModule;
- rc = pMod->xOpen(pTab->pTokenizer, zDoc, nDoc, &pC);
+ rc = sqlite3Fts3OpenTokenizer(pTab->pTokenizer, pCsr->iLangid, zDoc,nDoc,&pC);
if( rc!=SQLITE_OK ){
return rc;
}
- pC->pTokenizer = pTab->pTokenizer;
while( rc==SQLITE_OK ){
- int iBegin; /* Offset in zDoc of start of token */
- int iFin; /* Offset in zDoc of end of token */
- int isHighlight; /* True for highlighted terms */
-
+ const char *ZDUMMY; /* Dummy argument used with tokenizer */
+ int DUMMY1 = -1; /* Dummy argument used with tokenizer */
+ int iBegin = 0; /* Offset in zDoc of start of token */
+ int iFin = 0; /* Offset in zDoc of end of token */
+ int isHighlight = 0; /* True for highlighted terms */
+
+ /* Variable DUMMY1 is initialized to a negative value above. Elsewhere
+ ** in the FTS code the variable that the third argument to xNext points to
+ ** is initialized to zero before the first (*but not necessarily
+ ** subsequent*) call to xNext(). This is done for a particular application
+ ** that needs to know whether or not the tokenizer is being used for
+ ** snippet generation or for some other purpose.
+ **
+ ** Extreme care is required when writing code to depend on this
+ ** initialization. It is not a documented part of the tokenizer interface.
+ ** If a tokenizer is used directly by any code outside of FTS, this
+ ** convention might not be respected. */
rc = pMod->xNext(pC, &ZDUMMY, &DUMMY1, &iBegin, &iFin, &iCurrent);
if( rc!=SQLITE_OK ){
if( rc==SQLITE_DONE ){
@@ -123572,7 +132371,9 @@ static int fts3SnippetText(
if( !isShiftDone ){
int n = nDoc - iBegin;
- rc = fts3SnippetShift(pTab, nSnippet, &zDoc[iBegin], n, &iPos, &hlmask);
+ rc = fts3SnippetShift(
+ pTab, pCsr->iLangid, nSnippet, &zDoc[iBegin], n, &iPos, &hlmask
+ );
isShiftDone = 1;
/* Now that the shift has been done, check if the initial "..." are
@@ -123684,13 +132485,14 @@ static int fts3ExprLocalHitsCb(
int iPhrase, /* Phrase number */
void *pCtx /* Pointer to MatchInfo structure */
){
+ int rc = SQLITE_OK;
MatchInfo *p = (MatchInfo *)pCtx;
int iStart = iPhrase * p->nCol * 3;
int i;
- for(i=0; i<p->nCol; i++){
+ for(i=0; i<p->nCol && rc==SQLITE_OK; i++){
char *pCsr;
- pCsr = sqlite3Fts3EvalPhrasePoslist(p->pCursor, pExpr, i);
+ rc = sqlite3Fts3EvalPhrasePoslist(p->pCursor, pExpr, i, &pCsr);
if( pCsr ){
p->aMatchinfo[iStart+i*3] = fts3ColumnlistCount(&pCsr);
}else{
@@ -123698,7 +132500,7 @@ static int fts3ExprLocalHitsCb(
}
}
- return SQLITE_OK;
+ return rc;
}
static int fts3MatchinfoCheck(
@@ -123708,8 +132510,8 @@ static int fts3MatchinfoCheck(
){
if( (cArg==FTS3_MATCHINFO_NPHRASE)
|| (cArg==FTS3_MATCHINFO_NCOL)
- || (cArg==FTS3_MATCHINFO_NDOC && pTab->bHasStat)
- || (cArg==FTS3_MATCHINFO_AVGLENGTH && pTab->bHasStat)
+ || (cArg==FTS3_MATCHINFO_NDOC && pTab->bFts4)
+ || (cArg==FTS3_MATCHINFO_AVGLENGTH && pTab->bFts4)
|| (cArg==FTS3_MATCHINFO_LENGTH && pTab->bHasDocsize)
|| (cArg==FTS3_MATCHINFO_LCS)
|| (cArg==FTS3_MATCHINFO_HITS)
@@ -123764,7 +132566,7 @@ static int fts3MatchinfoSelectDoctotal(
a = sqlite3_column_blob(pStmt, 0);
a += sqlite3Fts3GetVarint(a, &nDoc);
- if( nDoc==0 ) return SQLITE_CORRUPT_VTAB;
+ if( nDoc==0 ) return FTS_CORRUPT_VTAB;
*pnDoc = (u32)nDoc;
if( paLen ) *paLen = a;
@@ -123859,8 +132661,10 @@ static int fts3MatchinfoLcs(Fts3Cursor *pCsr, MatchInfo *pInfo){
int nLive = 0; /* Number of iterators in aIter not at EOF */
for(i=0; i<pInfo->nPhrase; i++){
+ int rc;
LcsIterator *pIt = &aIter[i];
- pIt->pRead = sqlite3Fts3EvalPhrasePoslist(pCsr, pIt->pExpr, iCol);
+ rc = sqlite3Fts3EvalPhrasePoslist(pCsr, pIt->pExpr, iCol, &pIt->pRead);
+ if( rc!=SQLITE_OK ) return rc;
if( pIt->pRead ){
pIt->iPos = pIt->iPosOffset;
fts3LcsIteratorAdvance(&aIter[i]);
@@ -124212,9 +133016,10 @@ static int fts3ExprTermOffsetInit(Fts3Expr *pExpr, int iPhrase, void *ctx){
int iTerm; /* For looping through nTerm phrase terms */
char *pList; /* Pointer to position list for phrase */
int iPos = 0; /* First position in position-list */
+ int rc;
UNUSED_PARAMETER(iPhrase);
- pList = sqlite3Fts3EvalPhrasePoslist(p->pCsr, pExpr, p->iCol);
+ rc = sqlite3Fts3EvalPhrasePoslist(p->pCsr, pExpr, p->iCol, &pList);
nTerm = pExpr->pPhrase->nToken;
if( pList ){
fts3GetDeltaPosition(&pList, &iPos);
@@ -124228,7 +133033,7 @@ static int fts3ExprTermOffsetInit(Fts3Expr *pExpr, int iPhrase, void *ctx){
pT->iPos = iPos;
}
- return SQLITE_OK;
+ return rc;
}
/*
@@ -124240,8 +133045,6 @@ SQLITE_PRIVATE void sqlite3Fts3Offsets(
){
Fts3Table *pTab = (Fts3Table *)pCsr->base.pVtab;
sqlite3_tokenizer_module const *pMod = pTab->pTokenizer->pModule;
- const char *ZDUMMY; /* Dummy argument used with xNext() */
- int NDUMMY; /* Dummy argument used with xNext() */
int rc; /* Return Code */
int nToken; /* Number of tokens in query */
int iCol; /* Column currently being processed */
@@ -124274,9 +133077,11 @@ SQLITE_PRIVATE void sqlite3Fts3Offsets(
*/
for(iCol=0; iCol<pTab->nColumn; iCol++){
sqlite3_tokenizer_cursor *pC; /* Tokenizer cursor */
- int iStart;
- int iEnd;
- int iCurrent;
+ const char *ZDUMMY; /* Dummy argument used with xNext() */
+ int NDUMMY = 0; /* Dummy argument used with xNext() */
+ int iStart = 0;
+ int iEnd = 0;
+ int iCurrent = 0;
const char *zDoc;
int nDoc;
@@ -124305,9 +133110,10 @@ SQLITE_PRIVATE void sqlite3Fts3Offsets(
}
/* Initialize a tokenizer iterator to iterate through column iCol. */
- rc = pMod->xOpen(pTab->pTokenizer, zDoc, nDoc, &pC);
+ rc = sqlite3Fts3OpenTokenizer(pTab->pTokenizer, pCsr->iLangid,
+ zDoc, nDoc, &pC
+ );
if( rc!=SQLITE_OK ) goto offsets_out;
- pC->pTokenizer = pTab->pTokenizer;
rc = pMod->xNext(pC, &ZDUMMY, &NDUMMY, &iStart, &iEnd, &iCurrent);
while( rc==SQLITE_OK ){
@@ -124325,7 +133131,7 @@ SQLITE_PRIVATE void sqlite3Fts3Offsets(
if( !pTerm ){
/* All offsets for this column have been gathered. */
- break;
+ rc = SQLITE_DONE;
}else{
assert( iCurrent<=iMinPos );
if( 0==(0xFE&*pTerm->pList) ){
@@ -124342,8 +133148,8 @@ SQLITE_PRIVATE void sqlite3Fts3Offsets(
"%d %d %d %d ", iCol, pTerm-sCtx.aTerm, iStart, iEnd-iStart
);
rc = fts3StringAppend(&res, aBuffer, -1);
- }else if( rc==SQLITE_DONE ){
- rc = SQLITE_CORRUPT_VTAB;
+ }else if( rc==SQLITE_DONE && pTab->zContentTbl==0 ){
+ rc = FTS_CORRUPT_VTAB;
}
}
}
@@ -124415,6 +133221,769 @@ SQLITE_PRIVATE void sqlite3Fts3Matchinfo(
#endif
/************** End of fts3_snippet.c ****************************************/
+/************** Begin file fts3_unicode.c ************************************/
+/*
+** 2012 May 24
+**
+** The author disclaims copyright to this source code. In place of
+** a legal notice, here is a blessing:
+**
+** May you do good and not evil.
+** May you find forgiveness for yourself and forgive others.
+** May you share freely, never taking more than you give.
+**
+******************************************************************************
+**
+** Implementation of the "unicode" full-text-search tokenizer.
+*/
+
+#ifdef SQLITE_ENABLE_FTS4_UNICODE61
+
+#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3)
+
+/* #include <assert.h> */
+/* #include <stdlib.h> */
+/* #include <stdio.h> */
+/* #include <string.h> */
+
+
+/*
+** The following two macros - READ_UTF8 and WRITE_UTF8 - have been copied
+** from the sqlite3 source file utf.c. If this file is compiled as part
+** of the amalgamation, they are not required.
+*/
+#ifndef SQLITE_AMALGAMATION
+
+static const unsigned char sqlite3Utf8Trans1[] = {
+ 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+ 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f,
+ 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x16, 0x17,
+ 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, 0x1f,
+ 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+ 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f,
+ 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
+ 0x00, 0x01, 0x02, 0x03, 0x00, 0x01, 0x00, 0x00,
+};
+
+#define READ_UTF8(zIn, zTerm, c) \
+ c = *(zIn++); \
+ if( c>=0xc0 ){ \
+ c = sqlite3Utf8Trans1[c-0xc0]; \
+ while( zIn!=zTerm && (*zIn & 0xc0)==0x80 ){ \
+ c = (c<<6) + (0x3f & *(zIn++)); \
+ } \
+ if( c<0x80 \
+ || (c&0xFFFFF800)==0xD800 \
+ || (c&0xFFFFFFFE)==0xFFFE ){ c = 0xFFFD; } \
+ }
+
+#define WRITE_UTF8(zOut, c) { \
+ if( c<0x00080 ){ \
+ *zOut++ = (u8)(c&0xFF); \
+ } \
+ else if( c<0x00800 ){ \
+ *zOut++ = 0xC0 + (u8)((c>>6)&0x1F); \
+ *zOut++ = 0x80 + (u8)(c & 0x3F); \
+ } \
+ else if( c<0x10000 ){ \
+ *zOut++ = 0xE0 + (u8)((c>>12)&0x0F); \
+ *zOut++ = 0x80 + (u8)((c>>6) & 0x3F); \
+ *zOut++ = 0x80 + (u8)(c & 0x3F); \
+ }else{ \
+ *zOut++ = 0xF0 + (u8)((c>>18) & 0x07); \
+ *zOut++ = 0x80 + (u8)((c>>12) & 0x3F); \
+ *zOut++ = 0x80 + (u8)((c>>6) & 0x3F); \
+ *zOut++ = 0x80 + (u8)(c & 0x3F); \
+ } \
+}
+
+#endif /* ifndef SQLITE_AMALGAMATION */
+
+typedef struct unicode_tokenizer unicode_tokenizer;
+typedef struct unicode_cursor unicode_cursor;
+
+struct unicode_tokenizer {
+ sqlite3_tokenizer base;
+ int bRemoveDiacritic;
+ int nException;
+ int *aiException;
+};
+
+struct unicode_cursor {
+ sqlite3_tokenizer_cursor base;
+ const unsigned char *aInput; /* Input text being tokenized */
+ int nInput; /* Size of aInput[] in bytes */
+ int iOff; /* Current offset within aInput[] */
+ int iToken; /* Index of next token to be returned */
+ char *zToken; /* storage for current token */
+ int nAlloc; /* space allocated at zToken */
+};
+
+
+/*
+** Destroy a tokenizer allocated by unicodeCreate().
+*/
+static int unicodeDestroy(sqlite3_tokenizer *pTokenizer){
+ if( pTokenizer ){
+ unicode_tokenizer *p = (unicode_tokenizer *)pTokenizer;
+ sqlite3_free(p->aiException);
+ sqlite3_free(p);
+ }
+ return SQLITE_OK;
+}
+
+/*
+** As part of a tokenchars= or separators= option, the CREATE VIRTUAL TABLE
+** statement has specified that the tokenizer for this table shall consider
+** all characters in string zIn/nIn to be separators (if bAlnum==0) or
+** token characters (if bAlnum==1).
+**
+** For each codepoint in the zIn/nIn string, this function checks if the
+** sqlite3FtsUnicodeIsalnum() function already returns the desired result.
+** If so, no action is taken. Otherwise, the codepoint is added to the
+** unicode_tokenizer.aiException[] array. For the purposes of tokenization,
+** the return value of sqlite3FtsUnicodeIsalnum() is inverted for all
+** codepoints in the aiException[] array.
+**
+** If a standalone diacritic mark (one that sqlite3FtsUnicodeIsdiacritic()
+** identifies as a diacritic) occurs in the zIn/nIn string it is ignored.
+** It is not possible to change the behavior of the tokenizer with respect
+** to these codepoints.
+*/
+static int unicodeAddExceptions(
+ unicode_tokenizer *p, /* Tokenizer to add exceptions to */
+ int bAlnum, /* Replace Isalnum() return value with this */
+ const char *zIn, /* Array of characters to make exceptions */
+ int nIn /* Length of z in bytes */
+){
+ const unsigned char *z = (const unsigned char *)zIn;
+ const unsigned char *zTerm = &z[nIn];
+ int iCode;
+ int nEntry = 0;
+
+ assert( bAlnum==0 || bAlnum==1 );
+
+ while( z<zTerm ){
+ READ_UTF8(z, zTerm, iCode);
+ assert( (sqlite3FtsUnicodeIsalnum(iCode) & 0xFFFFFFFE)==0 );
+ if( sqlite3FtsUnicodeIsalnum(iCode)!=bAlnum
+ && sqlite3FtsUnicodeIsdiacritic(iCode)==0
+ ){
+ nEntry++;
+ }
+ }
+
+ if( nEntry ){
+ int *aNew; /* New aiException[] array */
+ int nNew; /* Number of valid entries in array aNew[] */
+
+ aNew = sqlite3_realloc(p->aiException, (p->nException+nEntry)*sizeof(int));
+ if( aNew==0 ) return SQLITE_NOMEM;
+ nNew = p->nException;
+
+ z = (const unsigned char *)zIn;
+ while( z<zTerm ){
+ READ_UTF8(z, zTerm, iCode);
+ if( sqlite3FtsUnicodeIsalnum(iCode)!=bAlnum
+ && sqlite3FtsUnicodeIsdiacritic(iCode)==0
+ ){
+ int i, j;
+ for(i=0; i<nNew && aNew[i]<iCode; i++);
+ for(j=nNew; j>i; j--) aNew[j] = aNew[j-1];
+ aNew[i] = iCode;
+ nNew++;
+ }
+ }
+ p->aiException = aNew;
+ p->nException = nNew;
+ }
+
+ return SQLITE_OK;
+}
+
+/*
+** Return true if the p->aiException[] array contains the value iCode.
+*/
+static int unicodeIsException(unicode_tokenizer *p, int iCode){
+ if( p->nException>0 ){
+ int *a = p->aiException;
+ int iLo = 0;
+ int iHi = p->nException-1;
+
+ while( iHi>=iLo ){
+ int iTest = (iHi + iLo) / 2;
+ if( iCode==a[iTest] ){
+ return 1;
+ }else if( iCode>a[iTest] ){
+ iLo = iTest+1;
+ }else{
+ iHi = iTest-1;
+ }
+ }
+ }
+
+ return 0;
+}
+
+/*
+** Return true if, for the purposes of tokenization, codepoint iCode is
+** considered a token character (not a separator).
+*/
+static int unicodeIsAlnum(unicode_tokenizer *p, int iCode){
+ assert( (sqlite3FtsUnicodeIsalnum(iCode) & 0xFFFFFFFE)==0 );
+ return sqlite3FtsUnicodeIsalnum(iCode) ^ unicodeIsException(p, iCode);
+}
+
+/*
+** Create a new tokenizer instance.
+*/
+static int unicodeCreate(
+ int nArg, /* Size of array argv[] */
+ const char * const *azArg, /* Tokenizer creation arguments */
+ sqlite3_tokenizer **pp /* OUT: New tokenizer handle */
+){
+ unicode_tokenizer *pNew; /* New tokenizer object */
+ int i;
+ int rc = SQLITE_OK;
+
+ pNew = (unicode_tokenizer *) sqlite3_malloc(sizeof(unicode_tokenizer));
+ if( pNew==NULL ) return SQLITE_NOMEM;
+ memset(pNew, 0, sizeof(unicode_tokenizer));
+ pNew->bRemoveDiacritic = 1;
+
+ for(i=0; rc==SQLITE_OK && i<nArg; i++){
+ const char *z = azArg[i];
+ int n = strlen(z);
+
+ if( n==19 && memcmp("remove_diacritics=1", z, 19)==0 ){
+ pNew->bRemoveDiacritic = 1;
+ }
+ else if( n==19 && memcmp("remove_diacritics=0", z, 19)==0 ){
+ pNew->bRemoveDiacritic = 0;
+ }
+ else if( n>=11 && memcmp("tokenchars=", z, 11)==0 ){
+ rc = unicodeAddExceptions(pNew, 1, &z[11], n-11);
+ }
+ else if( n>=11 && memcmp("separators=", z, 11)==0 ){
+ rc = unicodeAddExceptions(pNew, 0, &z[11], n-11);
+ }
+ else{
+ /* Unrecognized argument */
+ rc = SQLITE_ERROR;
+ }
+ }
+
+ if( rc!=SQLITE_OK ){
+ unicodeDestroy((sqlite3_tokenizer *)pNew);
+ pNew = 0;
+ }
+ *pp = (sqlite3_tokenizer *)pNew;
+ return rc;
+}
+
+/*
+** Prepare to begin tokenizing a particular string. The input
+** string to be tokenized is pInput[0..nBytes-1]. A cursor
+** used to incrementally tokenize this string is returned in
+** *ppCursor.
+*/
+static int unicodeOpen(
+ sqlite3_tokenizer *p, /* The tokenizer */
+ const char *aInput, /* Input string */
+ int nInput, /* Size of string aInput in bytes */
+ sqlite3_tokenizer_cursor **pp /* OUT: New cursor object */
+){
+ unicode_cursor *pCsr;
+
+ pCsr = (unicode_cursor *)sqlite3_malloc(sizeof(unicode_cursor));
+ if( pCsr==0 ){
+ return SQLITE_NOMEM;
+ }
+ memset(pCsr, 0, sizeof(unicode_cursor));
+
+ pCsr->aInput = (const unsigned char *)aInput;
+ if( aInput==0 ){
+ pCsr->nInput = 0;
+ }else if( nInput<0 ){
+ pCsr->nInput = (int)strlen(aInput);
+ }else{
+ pCsr->nInput = nInput;
+ }
+
+ *pp = &pCsr->base;
+ UNUSED_PARAMETER(p);
+ return SQLITE_OK;
+}
+
+/*
+** Close a tokenization cursor previously opened by a call to
+** simpleOpen() above.
+*/
+static int unicodeClose(sqlite3_tokenizer_cursor *pCursor){
+ unicode_cursor *pCsr = (unicode_cursor *) pCursor;
+ sqlite3_free(pCsr->zToken);
+ sqlite3_free(pCsr);
+ return SQLITE_OK;
+}
+
+/*
+** Extract the next token from a tokenization cursor. The cursor must
+** have been opened by a prior call to simpleOpen().
+*/
+static int unicodeNext(
+ sqlite3_tokenizer_cursor *pC, /* Cursor returned by simpleOpen */
+ const char **paToken, /* OUT: Token text */
+ int *pnToken, /* OUT: Number of bytes at *paToken */
+ int *piStart, /* OUT: Starting offset of token */
+ int *piEnd, /* OUT: Ending offset of token */
+ int *piPos /* OUT: Position integer of token */
+){
+ unicode_cursor *pCsr = (unicode_cursor *)pC;
+ unicode_tokenizer *p = ((unicode_tokenizer *)pCsr->base.pTokenizer);
+ int iCode;
+ char *zOut;
+ const unsigned char *z = &pCsr->aInput[pCsr->iOff];
+ const unsigned char *zStart = z;
+ const unsigned char *zEnd;
+ const unsigned char *zTerm = &pCsr->aInput[pCsr->nInput];
+
+ /* Scan past any delimiter characters before the start of the next token.
+ ** Return SQLITE_DONE early if this takes us all the way to the end of
+ ** the input. */
+ while( z<zTerm ){
+ READ_UTF8(z, zTerm, iCode);
+ if( unicodeIsAlnum(p, iCode) ) break;
+ zStart = z;
+ }
+ if( zStart>=zTerm ) return SQLITE_DONE;
+
+ zOut = pCsr->zToken;
+ do {
+ int iOut;
+
+ /* Grow the output buffer if required. */
+ if( (zOut-pCsr->zToken)>=(pCsr->nAlloc-4) ){
+ char *zNew = sqlite3_realloc(pCsr->zToken, pCsr->nAlloc+64);
+ if( !zNew ) return SQLITE_NOMEM;
+ zOut = &zNew[zOut - pCsr->zToken];
+ pCsr->zToken = zNew;
+ pCsr->nAlloc += 64;
+ }
+
+ /* Write the folded case of the last character read to the output */
+ zEnd = z;
+ iOut = sqlite3FtsUnicodeFold(iCode, p->bRemoveDiacritic);
+ if( iOut ){
+ WRITE_UTF8(zOut, iOut);
+ }
+
+ /* If the cursor is not at EOF, read the next character */
+ if( z>=zTerm ) break;
+ READ_UTF8(z, zTerm, iCode);
+ }while( unicodeIsAlnum(p, iCode)
+ || sqlite3FtsUnicodeIsdiacritic(iCode)
+ );
+
+ /* Set the output variables and return. */
+ pCsr->iOff = (z - pCsr->aInput);
+ *paToken = pCsr->zToken;
+ *pnToken = zOut - pCsr->zToken;
+ *piStart = (zStart - pCsr->aInput);
+ *piEnd = (zEnd - pCsr->aInput);
+ *piPos = pCsr->iToken++;
+ return SQLITE_OK;
+}
+
+/*
+** Set *ppModule to a pointer to the sqlite3_tokenizer_module
+** structure for the unicode tokenizer.
+*/
+SQLITE_PRIVATE void sqlite3Fts3UnicodeTokenizer(sqlite3_tokenizer_module const **ppModule){
+ static const sqlite3_tokenizer_module module = {
+ 0,
+ unicodeCreate,
+ unicodeDestroy,
+ unicodeOpen,
+ unicodeClose,
+ unicodeNext,
+ 0,
+ };
+ *ppModule = &module;
+}
+
+#endif /* !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3) */
+#endif /* ifndef SQLITE_ENABLE_FTS4_UNICODE61 */
+
+/************** End of fts3_unicode.c ****************************************/
+/************** Begin file fts3_unicode2.c ***********************************/
+/*
+** 2012 May 25
+**
+** The author disclaims copyright to this source code. In place of
+** a legal notice, here is a blessing:
+**
+** May you do good and not evil.
+** May you find forgiveness for yourself and forgive others.
+** May you share freely, never taking more than you give.
+**
+******************************************************************************
+*/
+
+/*
+** DO NOT EDIT THIS MACHINE GENERATED FILE.
+*/
+
+#if defined(SQLITE_ENABLE_FTS4_UNICODE61)
+#if defined(SQLITE_ENABLE_FTS3) || defined(SQLITE_ENABLE_FTS4)
+
+/* #include <assert.h> */
+
+/*
+** Return true if the argument corresponds to a unicode codepoint
+** classified as either a letter or a number. Otherwise false.
+**
+** The results are undefined if the value passed to this function
+** is less than zero.
+*/
+SQLITE_PRIVATE int sqlite3FtsUnicodeIsalnum(int c){
+ /* Each unsigned integer in the following array corresponds to a contiguous
+ ** range of unicode codepoints that are not either letters or numbers (i.e.
+ ** codepoints for which this function should return 0).
+ **
+ ** The most significant 22 bits in each 32-bit value contain the first
+ ** codepoint in the range. The least significant 10 bits are used to store
+ ** the size of the range (always at least 1). In other words, the value
+ ** ((C<<22) + N) represents a range of N codepoints starting with codepoint
+ ** C. It is not possible to represent a range larger than 1023 codepoints
+ ** using this format.
+ */
+ const static unsigned int aEntry[] = {
+ 0x00000030, 0x0000E807, 0x00016C06, 0x0001EC2F, 0x0002AC07,
+ 0x0002D001, 0x0002D803, 0x0002EC01, 0x0002FC01, 0x00035C01,
+ 0x0003DC01, 0x000B0804, 0x000B480E, 0x000B9407, 0x000BB401,
+ 0x000BBC81, 0x000DD401, 0x000DF801, 0x000E1002, 0x000E1C01,
+ 0x000FD801, 0x00120808, 0x00156806, 0x00162402, 0x00163C01,
+ 0x00164437, 0x0017CC02, 0x00180005, 0x00181816, 0x00187802,
+ 0x00192C15, 0x0019A804, 0x0019C001, 0x001B5001, 0x001B580F,
+ 0x001B9C07, 0x001BF402, 0x001C000E, 0x001C3C01, 0x001C4401,
+ 0x001CC01B, 0x001E980B, 0x001FAC09, 0x001FD804, 0x00205804,
+ 0x00206C09, 0x00209403, 0x0020A405, 0x0020C00F, 0x00216403,
+ 0x00217801, 0x0023901B, 0x00240004, 0x0024E803, 0x0024F812,
+ 0x00254407, 0x00258804, 0x0025C001, 0x00260403, 0x0026F001,
+ 0x0026F807, 0x00271C02, 0x00272C03, 0x00275C01, 0x00278802,
+ 0x0027C802, 0x0027E802, 0x00280403, 0x0028F001, 0x0028F805,
+ 0x00291C02, 0x00292C03, 0x00294401, 0x0029C002, 0x0029D401,
+ 0x002A0403, 0x002AF001, 0x002AF808, 0x002B1C03, 0x002B2C03,
+ 0x002B8802, 0x002BC002, 0x002C0403, 0x002CF001, 0x002CF807,
+ 0x002D1C02, 0x002D2C03, 0x002D5802, 0x002D8802, 0x002DC001,
+ 0x002E0801, 0x002EF805, 0x002F1803, 0x002F2804, 0x002F5C01,
+ 0x002FCC08, 0x00300403, 0x0030F807, 0x00311803, 0x00312804,
+ 0x00315402, 0x00318802, 0x0031FC01, 0x00320802, 0x0032F001,
+ 0x0032F807, 0x00331803, 0x00332804, 0x00335402, 0x00338802,
+ 0x00340802, 0x0034F807, 0x00351803, 0x00352804, 0x00355C01,
+ 0x00358802, 0x0035E401, 0x00360802, 0x00372801, 0x00373C06,
+ 0x00375801, 0x00376008, 0x0037C803, 0x0038C401, 0x0038D007,
+ 0x0038FC01, 0x00391C09, 0x00396802, 0x003AC401, 0x003AD006,
+ 0x003AEC02, 0x003B2006, 0x003C041F, 0x003CD00C, 0x003DC417,
+ 0x003E340B, 0x003E6424, 0x003EF80F, 0x003F380D, 0x0040AC14,
+ 0x00412806, 0x00415804, 0x00417803, 0x00418803, 0x00419C07,
+ 0x0041C404, 0x0042080C, 0x00423C01, 0x00426806, 0x0043EC01,
+ 0x004D740C, 0x004E400A, 0x00500001, 0x0059B402, 0x005A0001,
+ 0x005A6C02, 0x005BAC03, 0x005C4803, 0x005CC805, 0x005D4802,
+ 0x005DC802, 0x005ED023, 0x005F6004, 0x005F7401, 0x0060000F,
+ 0x0062A401, 0x0064800C, 0x0064C00C, 0x00650001, 0x00651002,
+ 0x0066C011, 0x00672002, 0x00677822, 0x00685C05, 0x00687802,
+ 0x0069540A, 0x0069801D, 0x0069FC01, 0x006A8007, 0x006AA006,
+ 0x006C0005, 0x006CD011, 0x006D6823, 0x006E0003, 0x006E840D,
+ 0x006F980E, 0x006FF004, 0x00709014, 0x0070EC05, 0x0071F802,
+ 0x00730008, 0x00734019, 0x0073B401, 0x0073C803, 0x00770027,
+ 0x0077F004, 0x007EF401, 0x007EFC03, 0x007F3403, 0x007F7403,
+ 0x007FB403, 0x007FF402, 0x00800065, 0x0081A806, 0x0081E805,
+ 0x00822805, 0x0082801A, 0x00834021, 0x00840002, 0x00840C04,
+ 0x00842002, 0x00845001, 0x00845803, 0x00847806, 0x00849401,
+ 0x00849C01, 0x0084A401, 0x0084B801, 0x0084E802, 0x00850005,
+ 0x00852804, 0x00853C01, 0x00864264, 0x00900027, 0x0091000B,
+ 0x0092704E, 0x00940200, 0x009C0475, 0x009E53B9, 0x00AD400A,
+ 0x00B39406, 0x00B3BC03, 0x00B3E404, 0x00B3F802, 0x00B5C001,
+ 0x00B5FC01, 0x00B7804F, 0x00B8C00C, 0x00BA001A, 0x00BA6C59,
+ 0x00BC00D6, 0x00BFC00C, 0x00C00005, 0x00C02019, 0x00C0A807,
+ 0x00C0D802, 0x00C0F403, 0x00C26404, 0x00C28001, 0x00C3EC01,
+ 0x00C64002, 0x00C6580A, 0x00C70024, 0x00C8001F, 0x00C8A81E,
+ 0x00C94001, 0x00C98020, 0x00CA2827, 0x00CB003F, 0x00CC0100,
+ 0x01370040, 0x02924037, 0x0293F802, 0x02983403, 0x0299BC10,
+ 0x029A7C01, 0x029BC008, 0x029C0017, 0x029C8002, 0x029E2402,
+ 0x02A00801, 0x02A01801, 0x02A02C01, 0x02A08C09, 0x02A0D804,
+ 0x02A1D004, 0x02A20002, 0x02A2D011, 0x02A33802, 0x02A38012,
+ 0x02A3E003, 0x02A4980A, 0x02A51C0D, 0x02A57C01, 0x02A60004,
+ 0x02A6CC1B, 0x02A77802, 0x02A8A40E, 0x02A90C01, 0x02A93002,
+ 0x02A97004, 0x02A9DC03, 0x02A9EC01, 0x02AAC001, 0x02AAC803,
+ 0x02AADC02, 0x02AAF802, 0x02AB0401, 0x02AB7802, 0x02ABAC07,
+ 0x02ABD402, 0x02AF8C0B, 0x03600001, 0x036DFC02, 0x036FFC02,
+ 0x037FFC02, 0x03E3FC01, 0x03EC7801, 0x03ECA401, 0x03EEC810,
+ 0x03F4F802, 0x03F7F002, 0x03F8001A, 0x03F88007, 0x03F8C023,
+ 0x03F95013, 0x03F9A004, 0x03FBFC01, 0x03FC040F, 0x03FC6807,
+ 0x03FCEC06, 0x03FD6C0B, 0x03FF8007, 0x03FFA007, 0x03FFE405,
+ 0x04040003, 0x0404DC09, 0x0405E411, 0x0406400C, 0x0407402E,
+ 0x040E7C01, 0x040F4001, 0x04215C01, 0x04247C01, 0x0424FC01,
+ 0x04280403, 0x04281402, 0x04283004, 0x0428E003, 0x0428FC01,
+ 0x04294009, 0x0429FC01, 0x042CE407, 0x04400003, 0x0440E016,
+ 0x04420003, 0x0442C012, 0x04440003, 0x04449C0E, 0x04450004,
+ 0x04460003, 0x0446CC0E, 0x04471404, 0x045AAC0D, 0x0491C004,
+ 0x05BD442E, 0x05BE3C04, 0x074000F6, 0x07440027, 0x0744A4B5,
+ 0x07480046, 0x074C0057, 0x075B0401, 0x075B6C01, 0x075BEC01,
+ 0x075C5401, 0x075CD401, 0x075D3C01, 0x075DBC01, 0x075E2401,
+ 0x075EA401, 0x075F0C01, 0x07BBC002, 0x07C0002C, 0x07C0C064,
+ 0x07C2800F, 0x07C2C40E, 0x07C3040F, 0x07C3440F, 0x07C4401F,
+ 0x07C4C03C, 0x07C5C02B, 0x07C7981D, 0x07C8402B, 0x07C90009,
+ 0x07C94002, 0x07CC0021, 0x07CCC006, 0x07CCDC46, 0x07CE0014,
+ 0x07CE8025, 0x07CF1805, 0x07CF8011, 0x07D0003F, 0x07D10001,
+ 0x07D108B6, 0x07D3E404, 0x07D4003E, 0x07D50004, 0x07D54018,
+ 0x07D7EC46, 0x07D9140B, 0x07DA0046, 0x07DC0074, 0x38000401,
+ 0x38008060, 0x380400F0, 0x3C000001, 0x3FFFF401, 0x40000001,
+ 0x43FFF401,
+ };
+ static const unsigned int aAscii[4] = {
+ 0xFFFFFFFF, 0xFC00FFFF, 0xF8000001, 0xF8000001,
+ };
+
+ if( c<128 ){
+ return ( (aAscii[c >> 5] & (1 << (c & 0x001F)))==0 );
+ }else if( c<(1<<22) ){
+ unsigned int key = (((unsigned int)c)<<10) | 0x000003FF;
+ int iRes;
+ int iHi = sizeof(aEntry)/sizeof(aEntry[0]) - 1;
+ int iLo = 0;
+ while( iHi>=iLo ){
+ int iTest = (iHi + iLo) / 2;
+ if( key >= aEntry[iTest] ){
+ iRes = iTest;
+ iLo = iTest+1;
+ }else{
+ iHi = iTest-1;
+ }
+ }
+ assert( aEntry[0]<key );
+ assert( key>=aEntry[iRes] );
+ return (((unsigned int)c) >= ((aEntry[iRes]>>10) + (aEntry[iRes]&0x3FF)));
+ }
+ return 1;
+}
+
+
+/*
+** If the argument is a codepoint corresponding to a lowercase letter
+** in the ASCII range with a diacritic added, return the codepoint
+** of the ASCII letter only. For example, if passed 235 - "LATIN
+** SMALL LETTER E WITH DIAERESIS" - return 65 ("LATIN SMALL LETTER
+** E"). The resuls of passing a codepoint that corresponds to an
+** uppercase letter are undefined.
+*/
+static int remove_diacritic(int c){
+ unsigned short aDia[] = {
+ 0, 1797, 1848, 1859, 1891, 1928, 1940, 1995,
+ 2024, 2040, 2060, 2110, 2168, 2206, 2264, 2286,
+ 2344, 2383, 2472, 2488, 2516, 2596, 2668, 2732,
+ 2782, 2842, 2894, 2954, 2984, 3000, 3028, 3336,
+ 3456, 3696, 3712, 3728, 3744, 3896, 3912, 3928,
+ 3968, 4008, 4040, 4106, 4138, 4170, 4202, 4234,
+ 4266, 4296, 4312, 4344, 4408, 4424, 4472, 4504,
+ 6148, 6198, 6264, 6280, 6360, 6429, 6505, 6529,
+ 61448, 61468, 61534, 61592, 61642, 61688, 61704, 61726,
+ 61784, 61800, 61836, 61880, 61914, 61948, 61998, 62122,
+ 62154, 62200, 62218, 62302, 62364, 62442, 62478, 62536,
+ 62554, 62584, 62604, 62640, 62648, 62656, 62664, 62730,
+ 62924, 63050, 63082, 63274, 63390,
+ };
+ char aChar[] = {
+ '\0', 'a', 'c', 'e', 'i', 'n', 'o', 'u', 'y', 'y', 'a', 'c',
+ 'd', 'e', 'e', 'g', 'h', 'i', 'j', 'k', 'l', 'n', 'o', 'r',
+ 's', 't', 'u', 'u', 'w', 'y', 'z', 'o', 'u', 'a', 'i', 'o',
+ 'u', 'g', 'k', 'o', 'j', 'g', 'n', 'a', 'e', 'i', 'o', 'r',
+ 'u', 's', 't', 'h', 'a', 'e', 'o', 'y', '\0', '\0', '\0', '\0',
+ '\0', '\0', '\0', '\0', 'a', 'b', 'd', 'd', 'e', 'f', 'g', 'h',
+ 'h', 'i', 'k', 'l', 'l', 'm', 'n', 'p', 'r', 'r', 's', 't',
+ 'u', 'v', 'w', 'w', 'x', 'y', 'z', 'h', 't', 'w', 'y', 'a',
+ 'e', 'i', 'o', 'u', 'y',
+ };
+
+ unsigned int key = (((unsigned int)c)<<3) | 0x00000007;
+ int iRes = 0;
+ int iHi = sizeof(aDia)/sizeof(aDia[0]) - 1;
+ int iLo = 0;
+ while( iHi>=iLo ){
+ int iTest = (iHi + iLo) / 2;
+ if( key >= aDia[iTest] ){
+ iRes = iTest;
+ iLo = iTest+1;
+ }else{
+ iHi = iTest-1;
+ }
+ }
+ assert( key>=aDia[iRes] );
+ return ((c > (aDia[iRes]>>3) + (aDia[iRes]&0x07)) ? c : (int)aChar[iRes]);
+};
+
+
+/*
+** Return true if the argument interpreted as a unicode codepoint
+** is a diacritical modifier character.
+*/
+SQLITE_PRIVATE int sqlite3FtsUnicodeIsdiacritic(int c){
+ unsigned int mask0 = 0x08029FDF;
+ unsigned int mask1 = 0x000361F8;
+ if( c<768 || c>817 ) return 0;
+ return (c < 768+32) ?
+ (mask0 & (1 << (c-768))) :
+ (mask1 & (1 << (c-768-32)));
+}
+
+
+/*
+** Interpret the argument as a unicode codepoint. If the codepoint
+** is an upper case character that has a lower case equivalent,
+** return the codepoint corresponding to the lower case version.
+** Otherwise, return a copy of the argument.
+**
+** The results are undefined if the value passed to this function
+** is less than zero.
+*/
+SQLITE_PRIVATE int sqlite3FtsUnicodeFold(int c, int bRemoveDiacritic){
+ /* Each entry in the following array defines a rule for folding a range
+ ** of codepoints to lower case. The rule applies to a range of nRange
+ ** codepoints starting at codepoint iCode.
+ **
+ ** If the least significant bit in flags is clear, then the rule applies
+ ** to all nRange codepoints (i.e. all nRange codepoints are upper case and
+ ** need to be folded). Or, if it is set, then the rule only applies to
+ ** every second codepoint in the range, starting with codepoint C.
+ **
+ ** The 7 most significant bits in flags are an index into the aiOff[]
+ ** array. If a specific codepoint C does require folding, then its lower
+ ** case equivalent is ((C + aiOff[flags>>1]) & 0xFFFF).
+ **
+ ** The contents of this array are generated by parsing the CaseFolding.txt
+ ** file distributed as part of the "Unicode Character Database". See
+ ** http://www.unicode.org for details.
+ */
+ static const struct TableEntry {
+ unsigned short iCode;
+ unsigned char flags;
+ unsigned char nRange;
+ } aEntry[] = {
+ {65, 14, 26}, {181, 64, 1}, {192, 14, 23},
+ {216, 14, 7}, {256, 1, 48}, {306, 1, 6},
+ {313, 1, 16}, {330, 1, 46}, {376, 116, 1},
+ {377, 1, 6}, {383, 104, 1}, {385, 50, 1},
+ {386, 1, 4}, {390, 44, 1}, {391, 0, 1},
+ {393, 42, 2}, {395, 0, 1}, {398, 32, 1},
+ {399, 38, 1}, {400, 40, 1}, {401, 0, 1},
+ {403, 42, 1}, {404, 46, 1}, {406, 52, 1},
+ {407, 48, 1}, {408, 0, 1}, {412, 52, 1},
+ {413, 54, 1}, {415, 56, 1}, {416, 1, 6},
+ {422, 60, 1}, {423, 0, 1}, {425, 60, 1},
+ {428, 0, 1}, {430, 60, 1}, {431, 0, 1},
+ {433, 58, 2}, {435, 1, 4}, {439, 62, 1},
+ {440, 0, 1}, {444, 0, 1}, {452, 2, 1},
+ {453, 0, 1}, {455, 2, 1}, {456, 0, 1},
+ {458, 2, 1}, {459, 1, 18}, {478, 1, 18},
+ {497, 2, 1}, {498, 1, 4}, {502, 122, 1},
+ {503, 134, 1}, {504, 1, 40}, {544, 110, 1},
+ {546, 1, 18}, {570, 70, 1}, {571, 0, 1},
+ {573, 108, 1}, {574, 68, 1}, {577, 0, 1},
+ {579, 106, 1}, {580, 28, 1}, {581, 30, 1},
+ {582, 1, 10}, {837, 36, 1}, {880, 1, 4},
+ {886, 0, 1}, {902, 18, 1}, {904, 16, 3},
+ {908, 26, 1}, {910, 24, 2}, {913, 14, 17},
+ {931, 14, 9}, {962, 0, 1}, {975, 4, 1},
+ {976, 140, 1}, {977, 142, 1}, {981, 146, 1},
+ {982, 144, 1}, {984, 1, 24}, {1008, 136, 1},
+ {1009, 138, 1}, {1012, 130, 1}, {1013, 128, 1},
+ {1015, 0, 1}, {1017, 152, 1}, {1018, 0, 1},
+ {1021, 110, 3}, {1024, 34, 16}, {1040, 14, 32},
+ {1120, 1, 34}, {1162, 1, 54}, {1216, 6, 1},
+ {1217, 1, 14}, {1232, 1, 88}, {1329, 22, 38},
+ {4256, 66, 38}, {4295, 66, 1}, {4301, 66, 1},
+ {7680, 1, 150}, {7835, 132, 1}, {7838, 96, 1},
+ {7840, 1, 96}, {7944, 150, 8}, {7960, 150, 6},
+ {7976, 150, 8}, {7992, 150, 8}, {8008, 150, 6},
+ {8025, 151, 8}, {8040, 150, 8}, {8072, 150, 8},
+ {8088, 150, 8}, {8104, 150, 8}, {8120, 150, 2},
+ {8122, 126, 2}, {8124, 148, 1}, {8126, 100, 1},
+ {8136, 124, 4}, {8140, 148, 1}, {8152, 150, 2},
+ {8154, 120, 2}, {8168, 150, 2}, {8170, 118, 2},
+ {8172, 152, 1}, {8184, 112, 2}, {8186, 114, 2},
+ {8188, 148, 1}, {8486, 98, 1}, {8490, 92, 1},
+ {8491, 94, 1}, {8498, 12, 1}, {8544, 8, 16},
+ {8579, 0, 1}, {9398, 10, 26}, {11264, 22, 47},
+ {11360, 0, 1}, {11362, 88, 1}, {11363, 102, 1},
+ {11364, 90, 1}, {11367, 1, 6}, {11373, 84, 1},
+ {11374, 86, 1}, {11375, 80, 1}, {11376, 82, 1},
+ {11378, 0, 1}, {11381, 0, 1}, {11390, 78, 2},
+ {11392, 1, 100}, {11499, 1, 4}, {11506, 0, 1},
+ {42560, 1, 46}, {42624, 1, 24}, {42786, 1, 14},
+ {42802, 1, 62}, {42873, 1, 4}, {42877, 76, 1},
+ {42878, 1, 10}, {42891, 0, 1}, {42893, 74, 1},
+ {42896, 1, 4}, {42912, 1, 10}, {42922, 72, 1},
+ {65313, 14, 26},
+ };
+ static const unsigned short aiOff[] = {
+ 1, 2, 8, 15, 16, 26, 28, 32,
+ 37, 38, 40, 48, 63, 64, 69, 71,
+ 79, 80, 116, 202, 203, 205, 206, 207,
+ 209, 210, 211, 213, 214, 217, 218, 219,
+ 775, 7264, 10792, 10795, 23228, 23256, 30204, 54721,
+ 54753, 54754, 54756, 54787, 54793, 54809, 57153, 57274,
+ 57921, 58019, 58363, 61722, 65268, 65341, 65373, 65406,
+ 65408, 65410, 65415, 65424, 65436, 65439, 65450, 65462,
+ 65472, 65476, 65478, 65480, 65482, 65488, 65506, 65511,
+ 65514, 65521, 65527, 65528, 65529,
+ };
+
+ int ret = c;
+
+ assert( c>=0 );
+ assert( sizeof(unsigned short)==2 && sizeof(unsigned char)==1 );
+
+ if( c<128 ){
+ if( c>='A' && c<='Z' ) ret = c + ('a' - 'A');
+ }else if( c<65536 ){
+ int iHi = sizeof(aEntry)/sizeof(aEntry[0]) - 1;
+ int iLo = 0;
+ int iRes = -1;
+
+ while( iHi>=iLo ){
+ int iTest = (iHi + iLo) / 2;
+ int cmp = (c - aEntry[iTest].iCode);
+ if( cmp>=0 ){
+ iRes = iTest;
+ iLo = iTest+1;
+ }else{
+ iHi = iTest-1;
+ }
+ }
+ assert( iRes<0 || c>=aEntry[iRes].iCode );
+
+ if( iRes>=0 ){
+ const struct TableEntry *p = &aEntry[iRes];
+ if( c<(p->iCode + p->nRange) && 0==(0x01 & p->flags & (p->iCode ^ c)) ){
+ ret = (c + (aiOff[p->flags>>1])) & 0x0000FFFF;
+ assert( ret>0 );
+ }
+ }
+
+ if( bRemoveDiacritic ) ret = remove_diacritic(ret);
+ }
+
+ else if( c>=66560 && c<66600 ){
+ ret = c + 40;
+ }
+
+ return ret;
+}
+#endif /* defined(SQLITE_ENABLE_FTS3) || defined(SQLITE_ENABLE_FTS4) */
+#endif /* !defined(SQLITE_ENABLE_FTS4_UNICODE61) */
+
+/************** End of fts3_unicode2.c ***************************************/
/************** Begin file rtree.c *******************************************/
/*
** 2001 September 15
@@ -124519,6 +134088,8 @@ SQLITE_PRIVATE void sqlite3Fts3Matchinfo(
#else
#endif
+/* #include <string.h> */
+/* #include <assert.h> */
#ifndef SQLITE_AMALGAMATION
#include "sqlite3rtree.h"
@@ -124597,6 +134168,19 @@ struct Rtree {
#define RTREE_COORD_INT32 1
/*
+** If SQLITE_RTREE_INT_ONLY is defined, then this virtual table will
+** only deal with integer coordinates. No floating point operations
+** will be done.
+*/
+#ifdef SQLITE_RTREE_INT_ONLY
+ typedef sqlite3_int64 RtreeDValue; /* High accuracy coordinate */
+ typedef int RtreeValue; /* Low accuracy coordinate */
+#else
+ typedef double RtreeDValue; /* High accuracy coordinate */
+ typedef float RtreeValue; /* Low accuracy coordinate */
+#endif
+
+/*
** The minimum number of cells allowed for a node is a third of the
** maximum. In Gutman's notation:
**
@@ -124631,20 +134215,25 @@ struct RtreeCursor {
};
union RtreeCoord {
- float f;
+ RtreeValue f;
int i;
};
/*
** The argument is an RtreeCoord. Return the value stored within the RtreeCoord
-** formatted as a double. This macro assumes that local variable pRtree points
-** to the Rtree structure associated with the RtreeCoord.
+** formatted as a RtreeDValue (double or int64). This macro assumes that local
+** variable pRtree points to the Rtree structure associated with the
+** RtreeCoord.
*/
-#define DCOORD(coord) ( \
- (pRtree->eCoordType==RTREE_COORD_REAL32) ? \
- ((double)coord.f) : \
- ((double)coord.i) \
-)
+#ifdef SQLITE_RTREE_INT_ONLY
+# define DCOORD(coord) ((RtreeDValue)coord.i)
+#else
+# define DCOORD(coord) ( \
+ (pRtree->eCoordType==RTREE_COORD_REAL32) ? \
+ ((double)coord.f) : \
+ ((double)coord.i) \
+ )
+#endif
/*
** A search constraint.
@@ -124652,8 +134241,8 @@ union RtreeCoord {
struct RtreeConstraint {
int iCoord; /* Index of constrained coordinate */
int op; /* Constraining operation */
- double rValue; /* Constraint value. */
- int (*xGeom)(sqlite3_rtree_geometry *, int, double *, int *);
+ RtreeDValue rValue; /* Constraint value. */
+ int (*xGeom)(sqlite3_rtree_geometry*, int, RtreeDValue*, int*);
sqlite3_rtree_geometry *pGeom; /* Constraint callback argument for a MATCH */
};
@@ -124701,10 +134290,10 @@ struct RtreeCell {
*/
struct RtreeMatchArg {
u32 magic; /* Always RTREE_GEOMETRY_MAGIC */
- int (*xGeom)(sqlite3_rtree_geometry *, int, double *, int *);
+ int (*xGeom)(sqlite3_rtree_geometry *, int, RtreeDValue*, int *);
void *pContext;
int nParam;
- double aParam[1];
+ RtreeDValue aParam[1];
};
/*
@@ -124716,7 +134305,7 @@ struct RtreeMatchArg {
** the geometry callback function).
*/
struct RtreeGeomCallback {
- int (*xGeom)(sqlite3_rtree_geometry *, int, double *, int *);
+ int (*xGeom)(sqlite3_rtree_geometry*, int, RtreeDValue*, int*);
void *pContext;
};
@@ -125282,7 +134871,7 @@ static int testRtreeGeom(
int *pbRes /* OUT: Test result */
){
int i;
- double aCoord[RTREE_MAX_DIMENSIONS*2];
+ RtreeDValue aCoord[RTREE_MAX_DIMENSIONS*2];
int nCoord = pRtree->nDim*2;
assert( pConstraint->op==RTREE_MATCH );
@@ -125312,8 +134901,8 @@ static int testRtreeCell(Rtree *pRtree, RtreeCursor *pCursor, int *pbEof){
nodeGetCell(pRtree, pCursor->pNode, pCursor->iCell, &cell);
for(ii=0; bRes==0 && ii<pCursor->nConstraint; ii++){
RtreeConstraint *p = &pCursor->aConstraint[ii];
- double cell_min = DCOORD(cell.aCoord[(p->iCoord>>1)*2]);
- double cell_max = DCOORD(cell.aCoord[(p->iCoord>>1)*2+1]);
+ RtreeDValue cell_min = DCOORD(cell.aCoord[(p->iCoord>>1)*2]);
+ RtreeDValue cell_max = DCOORD(cell.aCoord[(p->iCoord>>1)*2+1]);
assert(p->op==RTREE_LE || p->op==RTREE_LT || p->op==RTREE_GE
|| p->op==RTREE_GT || p->op==RTREE_EQ || p->op==RTREE_MATCH
@@ -125365,7 +134954,7 @@ static int testRtreeEntry(Rtree *pRtree, RtreeCursor *pCursor, int *pbEof){
nodeGetCell(pRtree, pCursor->pNode, pCursor->iCell, &cell);
for(ii=0; ii<pCursor->nConstraint; ii++){
RtreeConstraint *p = &pCursor->aConstraint[ii];
- double coord = DCOORD(cell.aCoord[p->iCoord]);
+ RtreeDValue coord = DCOORD(cell.aCoord[p->iCoord]);
int res;
assert(p->op==RTREE_LE || p->op==RTREE_LT || p->op==RTREE_GE
|| p->op==RTREE_GT || p->op==RTREE_EQ || p->op==RTREE_MATCH
@@ -125563,9 +135152,12 @@ static int rtreeColumn(sqlite3_vtab_cursor *cur, sqlite3_context *ctx, int i){
}else{
RtreeCoord c;
nodeGetCoord(pRtree, pCsr->pNode, pCsr->iCell, i-1, &c);
+#ifndef SQLITE_RTREE_INT_ONLY
if( pRtree->eCoordType==RTREE_COORD_REAL32 ){
sqlite3_result_double(ctx, c.f);
- }else{
+ }else
+#endif
+ {
assert( pRtree->eCoordType==RTREE_COORD_INT32 );
sqlite3_result_int(ctx, c.i);
}
@@ -125607,12 +135199,12 @@ static int deserializeGeometry(sqlite3_value *pValue, RtreeConstraint *pCons){
int nBlob;
/* Check that value is actually a blob. */
- if( !sqlite3_value_type(pValue)==SQLITE_BLOB ) return SQLITE_ERROR;
+ if( sqlite3_value_type(pValue)!=SQLITE_BLOB ) return SQLITE_ERROR;
/* Check that the blob is roughly the right size. */
nBlob = sqlite3_value_bytes(pValue);
if( nBlob<(int)sizeof(RtreeMatchArg)
- || ((nBlob-sizeof(RtreeMatchArg))%sizeof(double))!=0
+ || ((nBlob-sizeof(RtreeMatchArg))%sizeof(RtreeDValue))!=0
){
return SQLITE_ERROR;
}
@@ -125626,7 +135218,7 @@ static int deserializeGeometry(sqlite3_value *pValue, RtreeConstraint *pCons){
memcpy(p, sqlite3_value_blob(pValue), nBlob);
if( p->magic!=RTREE_GEOMETRY_MAGIC
- || nBlob!=(int)(sizeof(RtreeMatchArg) + (p->nParam-1)*sizeof(double))
+ || nBlob!=(int)(sizeof(RtreeMatchArg) + (p->nParam-1)*sizeof(RtreeDValue))
){
sqlite3_free(pGeom);
return SQLITE_ERROR;
@@ -125682,7 +135274,8 @@ static int rtreeFilter(
rc = SQLITE_NOMEM;
}else{
memset(pCsr->aConstraint, 0, sizeof(RtreeConstraint)*argc);
- assert( (idxStr==0 && argc==0) || (int)strlen(idxStr)==argc*2 );
+ assert( (idxStr==0 && argc==0)
+ || (idxStr && (int)strlen(idxStr)==argc*2) );
for(ii=0; ii<argc; ii++){
RtreeConstraint *p = &pCsr->aConstraint[ii];
p->op = idxStr[ii*2];
@@ -125697,7 +135290,11 @@ static int rtreeFilter(
break;
}
}else{
+#ifdef SQLITE_RTREE_INT_ONLY
+ p->rValue = sqlite3_value_int64(argv[ii]);
+#else
p->rValue = sqlite3_value_double(argv[ii]);
+#endif
}
}
}
@@ -125831,11 +135428,11 @@ static int rtreeBestIndex(sqlite3_vtab *tab, sqlite3_index_info *pIdxInfo){
/*
** Return the N-dimensional volumn of the cell stored in *p.
*/
-static float cellArea(Rtree *pRtree, RtreeCell *p){
- float area = 1.0;
+static RtreeDValue cellArea(Rtree *pRtree, RtreeCell *p){
+ RtreeDValue area = (RtreeDValue)1;
int ii;
for(ii=0; ii<(pRtree->nDim*2); ii+=2){
- area = (float)(area * (DCOORD(p->aCoord[ii+1]) - DCOORD(p->aCoord[ii])));
+ area = (area * (DCOORD(p->aCoord[ii+1]) - DCOORD(p->aCoord[ii])));
}
return area;
}
@@ -125844,11 +135441,11 @@ static float cellArea(Rtree *pRtree, RtreeCell *p){
** Return the margin length of cell p. The margin length is the sum
** of the objects size in each dimension.
*/
-static float cellMargin(Rtree *pRtree, RtreeCell *p){
- float margin = 0.0;
+static RtreeDValue cellMargin(Rtree *pRtree, RtreeCell *p){
+ RtreeDValue margin = (RtreeDValue)0;
int ii;
for(ii=0; ii<(pRtree->nDim*2); ii+=2){
- margin += (float)(DCOORD(p->aCoord[ii+1]) - DCOORD(p->aCoord[ii]));
+ margin += (DCOORD(p->aCoord[ii+1]) - DCOORD(p->aCoord[ii]));
}
return margin;
}
@@ -125893,8 +135490,8 @@ static int cellContains(Rtree *pRtree, RtreeCell *p1, RtreeCell *p2){
/*
** Return the amount cell p would grow by if it were unioned with pCell.
*/
-static float cellGrowth(Rtree *pRtree, RtreeCell *p, RtreeCell *pCell){
- float area;
+static RtreeDValue cellGrowth(Rtree *pRtree, RtreeCell *p, RtreeCell *pCell){
+ RtreeDValue area;
RtreeCell cell;
memcpy(&cell, p, sizeof(RtreeCell));
area = cellArea(pRtree, &cell);
@@ -125903,7 +135500,7 @@ static float cellGrowth(Rtree *pRtree, RtreeCell *p, RtreeCell *pCell){
}
#if VARIANT_RSTARTREE_CHOOSESUBTREE || VARIANT_RSTARTREE_SPLIT
-static float cellOverlap(
+static RtreeDValue cellOverlap(
Rtree *pRtree,
RtreeCell *p,
RtreeCell *aCell,
@@ -125911,7 +135508,7 @@ static float cellOverlap(
int iExclude
){
int ii;
- float overlap = 0.0;
+ RtreeDValue overlap = 0.0;
for(ii=0; ii<nCell; ii++){
#if VARIANT_RSTARTREE_CHOOSESUBTREE
if( ii!=iExclude )
@@ -125921,10 +135518,9 @@ static float cellOverlap(
#endif
{
int jj;
- float o = 1.0;
+ RtreeDValue o = (RtreeDValue)1;
for(jj=0; jj<(pRtree->nDim*2); jj+=2){
- double x1;
- double x2;
+ RtreeDValue x1, x2;
x1 = MAX(DCOORD(p->aCoord[jj]), DCOORD(aCell[ii].aCoord[jj]));
x2 = MIN(DCOORD(p->aCoord[jj+1]), DCOORD(aCell[ii].aCoord[jj+1]));
@@ -125933,7 +135529,7 @@ static float cellOverlap(
o = 0.0;
break;
}else{
- o = o * (float)(x2-x1);
+ o = o * (x2-x1);
}
}
overlap += o;
@@ -125944,7 +135540,7 @@ static float cellOverlap(
#endif
#if VARIANT_RSTARTREE_CHOOSESUBTREE
-static float cellOverlapEnlargement(
+static RtreeDValue cellOverlapEnlargement(
Rtree *pRtree,
RtreeCell *p,
RtreeCell *pInsert,
@@ -125952,12 +135548,11 @@ static float cellOverlapEnlargement(
int nCell,
int iExclude
){
- double before;
- double after;
+ RtreeDValue before, after;
before = cellOverlap(pRtree, p, aCell, nCell, iExclude);
cellUnion(pRtree, p, pInsert);
after = cellOverlap(pRtree, p, aCell, nCell, iExclude);
- return (float)(after-before);
+ return (after-before);
}
#endif
@@ -125981,9 +135576,12 @@ static int ChooseLeaf(
int iCell;
sqlite3_int64 iBest = 0;
- float fMinGrowth = 0.0;
- float fMinArea = 0.0;
- float fMinOverlap = 0.0;
+ RtreeDValue fMinGrowth = 0.0;
+ RtreeDValue fMinArea = 0.0;
+#if VARIANT_RSTARTREE_CHOOSESUBTREE
+ RtreeDValue fMinOverlap = 0.0;
+ RtreeDValue overlap;
+#endif
int nCell = NCELL(pNode);
RtreeCell cell;
@@ -126013,9 +135611,8 @@ static int ChooseLeaf(
*/
for(iCell=0; iCell<nCell; iCell++){
int bBest = 0;
- float growth;
- float area;
- float overlap = 0.0;
+ RtreeDValue growth;
+ RtreeDValue area;
nodeGetCell(pRtree, pNode, iCell, &cell);
growth = cellGrowth(pRtree, &cell, pCell);
area = cellArea(pRtree, &cell);
@@ -126023,6 +135620,8 @@ static int ChooseLeaf(
#if VARIANT_RSTARTREE_CHOOSESUBTREE
if( ii==(pRtree->iDepth-1) ){
overlap = cellOverlapEnlargement(pRtree,&cell,pCell,aCell,nCell,iCell);
+ }else{
+ overlap = 0.0;
}
if( (iCell==0)
|| (overlap<fMinOverlap)
@@ -126030,6 +135629,7 @@ static int ChooseLeaf(
|| (overlap==fMinOverlap && growth==fMinGrowth && area<fMinArea)
){
bBest = 1;
+ fMinOverlap = overlap;
}
#else
if( iCell==0||growth<fMinGrowth||(growth==fMinGrowth && area<fMinArea) ){
@@ -126037,7 +135637,6 @@ static int ChooseLeaf(
}
#endif
if( bBest ){
- fMinOverlap = overlap;
fMinGrowth = growth;
fMinArea = area;
iBest = cell.iRowid;
@@ -126140,7 +135739,7 @@ static void LinearPickSeeds(
int i;
int iLeftSeed = 0;
int iRightSeed = 1;
- float maxNormalInnerWidth = 0.0;
+ RtreeDValue maxNormalInnerWidth = (RtreeDValue)0;
/* Pick two "seed" cells from the array of cells. The algorithm used
** here is the LinearPickSeeds algorithm from Gutman[1984]. The
@@ -126148,18 +135747,18 @@ static void LinearPickSeeds(
** variables iLeftSeek and iRightSeed.
*/
for(i=0; i<pRtree->nDim; i++){
- float x1 = DCOORD(aCell[0].aCoord[i*2]);
- float x2 = DCOORD(aCell[0].aCoord[i*2+1]);
- float x3 = x1;
- float x4 = x2;
+ RtreeDValue x1 = DCOORD(aCell[0].aCoord[i*2]);
+ RtreeDValue x2 = DCOORD(aCell[0].aCoord[i*2+1]);
+ RtreeDValue x3 = x1;
+ RtreeDValue x4 = x2;
int jj;
int iCellLeft = 0;
int iCellRight = 0;
for(jj=1; jj<nCell; jj++){
- float left = DCOORD(aCell[jj].aCoord[i*2]);
- float right = DCOORD(aCell[jj].aCoord[i*2+1]);
+ RtreeDValue left = DCOORD(aCell[jj].aCoord[i*2]);
+ RtreeDValue right = DCOORD(aCell[jj].aCoord[i*2+1]);
if( left<x1 ) x1 = left;
if( right>x4 ) x4 = right;
@@ -126174,7 +135773,7 @@ static void LinearPickSeeds(
}
if( x4!=x1 ){
- float normalwidth = (x3 - x2) / (x4 - x1);
+ RtreeDValue normalwidth = (x3 - x2) / (x4 - x1);
if( normalwidth>maxNormalInnerWidth ){
iLeftSeed = iCellLeft;
iRightSeed = iCellRight;
@@ -126203,13 +135802,13 @@ static RtreeCell *QuadraticPickNext(
#define FABS(a) ((a)<0.0?-1.0*(a):(a))
int iSelect = -1;
- float fDiff;
+ RtreeDValue fDiff;
int ii;
for(ii=0; ii<nCell; ii++){
if( aiUsed[ii]==0 ){
- float left = cellGrowth(pRtree, pLeftBox, &aCell[ii]);
- float right = cellGrowth(pRtree, pLeftBox, &aCell[ii]);
- float diff = FABS(right-left);
+ RtreeDValue left = cellGrowth(pRtree, pLeftBox, &aCell[ii]);
+ RtreeDValue right = cellGrowth(pRtree, pLeftBox, &aCell[ii]);
+ RtreeDValue diff = FABS(right-left);
if( iSelect<0 || diff>fDiff ){
fDiff = diff;
iSelect = ii;
@@ -126236,13 +135835,13 @@ static void QuadraticPickSeeds(
int iLeftSeed = 0;
int iRightSeed = 1;
- float fWaste = 0.0;
+ RtreeDValue fWaste = 0.0;
for(ii=0; ii<nCell; ii++){
for(jj=ii+1; jj<nCell; jj++){
- float right = cellArea(pRtree, &aCell[jj]);
- float growth = cellGrowth(pRtree, &aCell[ii], &aCell[jj]);
- float waste = growth - right;
+ RtreeDValue right = cellArea(pRtree, &aCell[jj]);
+ RtreeDValue growth = cellGrowth(pRtree, &aCell[ii], &aCell[jj]);
+ RtreeDValue waste = growth - right;
if( waste>fWaste ){
iLeftSeed = ii;
@@ -126277,7 +135876,7 @@ static void QuadraticPickSeeds(
static void SortByDistance(
int *aIdx,
int nIdx,
- float *aDistance,
+ RtreeDValue *aDistance,
int *aSpare
){
if( nIdx>1 ){
@@ -126303,8 +135902,8 @@ static void SortByDistance(
aIdx[iLeft+iRight] = aLeft[iLeft];
iLeft++;
}else{
- float fLeft = aDistance[aLeft[iLeft]];
- float fRight = aDistance[aRight[iRight]];
+ RtreeDValue fLeft = aDistance[aLeft[iLeft]];
+ RtreeDValue fRight = aDistance[aRight[iRight]];
if( fLeft<fRight ){
aIdx[iLeft+iRight] = aLeft[iLeft];
iLeft++;
@@ -126320,8 +135919,8 @@ static void SortByDistance(
{
int jj;
for(jj=1; jj<nIdx; jj++){
- float left = aDistance[aIdx[jj-1]];
- float right = aDistance[aIdx[jj]];
+ RtreeDValue left = aDistance[aIdx[jj-1]];
+ RtreeDValue right = aDistance[aIdx[jj]];
assert( left<=right );
}
}
@@ -126364,10 +135963,10 @@ static void SortByDimension(
memcpy(aSpare, aLeft, sizeof(int)*nLeft);
aLeft = aSpare;
while( iLeft<nLeft || iRight<nRight ){
- double xleft1 = DCOORD(aCell[aLeft[iLeft]].aCoord[iDim*2]);
- double xleft2 = DCOORD(aCell[aLeft[iLeft]].aCoord[iDim*2+1]);
- double xright1 = DCOORD(aCell[aRight[iRight]].aCoord[iDim*2]);
- double xright2 = DCOORD(aCell[aRight[iRight]].aCoord[iDim*2+1]);
+ RtreeDValue xleft1 = DCOORD(aCell[aLeft[iLeft]].aCoord[iDim*2]);
+ RtreeDValue xleft2 = DCOORD(aCell[aLeft[iLeft]].aCoord[iDim*2+1]);
+ RtreeDValue xright1 = DCOORD(aCell[aRight[iRight]].aCoord[iDim*2]);
+ RtreeDValue xright2 = DCOORD(aCell[aRight[iRight]].aCoord[iDim*2+1]);
if( (iLeft!=nLeft) && ((iRight==nRight)
|| (xleft1<xright1)
|| (xleft1==xright1 && xleft2<xright2)
@@ -126385,10 +135984,10 @@ static void SortByDimension(
{
int jj;
for(jj=1; jj<nIdx; jj++){
- float xleft1 = aCell[aIdx[jj-1]].aCoord[iDim*2];
- float xleft2 = aCell[aIdx[jj-1]].aCoord[iDim*2+1];
- float xright1 = aCell[aIdx[jj]].aCoord[iDim*2];
- float xright2 = aCell[aIdx[jj]].aCoord[iDim*2+1];
+ RtreeDValue xleft1 = aCell[aIdx[jj-1]].aCoord[iDim*2];
+ RtreeDValue xleft2 = aCell[aIdx[jj-1]].aCoord[iDim*2+1];
+ RtreeDValue xright1 = aCell[aIdx[jj]].aCoord[iDim*2];
+ RtreeDValue xright2 = aCell[aIdx[jj]].aCoord[iDim*2+1];
assert( xleft1<=xright1 && (xleft1<xright1 || xleft2<=xright2) );
}
}
@@ -126415,7 +136014,7 @@ static int splitNodeStartree(
int iBestDim = 0;
int iBestSplit = 0;
- float fBestMargin = 0.0;
+ RtreeDValue fBestMargin = 0.0;
int nByte = (pRtree->nDim+1)*(sizeof(int*)+nCell*sizeof(int));
@@ -126436,9 +136035,9 @@ static int splitNodeStartree(
}
for(ii=0; ii<pRtree->nDim; ii++){
- float margin = 0.0;
- float fBestOverlap = 0.0;
- float fBestArea = 0.0;
+ RtreeDValue margin = 0.0;
+ RtreeDValue fBestOverlap = 0.0;
+ RtreeDValue fBestArea = 0.0;
int iBestLeft = 0;
int nLeft;
@@ -126450,8 +136049,8 @@ static int splitNodeStartree(
RtreeCell left;
RtreeCell right;
int kk;
- float overlap;
- float area;
+ RtreeDValue overlap;
+ RtreeDValue area;
memcpy(&left, &aCell[aaSorted[ii][0]], sizeof(RtreeCell));
memcpy(&right, &aCell[aaSorted[ii][nCell-1]], sizeof(RtreeCell));
@@ -126534,7 +136133,7 @@ static int splitNodeGuttman(
for(i=nCell-2; i>0; i--){
RtreeCell *pNext;
pNext = PickNext(pRtree, aCell, nCell, pBboxLeft, pBboxRight, aiUsed);
- float diff =
+ RtreeDValue diff =
cellGrowth(pRtree, pBboxLeft, pNext) -
cellGrowth(pRtree, pBboxRight, pNext)
;
@@ -126867,32 +136466,34 @@ static int Reinsert(
int *aOrder;
int *aSpare;
RtreeCell *aCell;
- float *aDistance;
+ RtreeDValue *aDistance;
int nCell;
- float aCenterCoord[RTREE_MAX_DIMENSIONS];
+ RtreeDValue aCenterCoord[RTREE_MAX_DIMENSIONS];
int iDim;
int ii;
int rc = SQLITE_OK;
+ int n;
- memset(aCenterCoord, 0, sizeof(float)*RTREE_MAX_DIMENSIONS);
+ memset(aCenterCoord, 0, sizeof(RtreeDValue)*RTREE_MAX_DIMENSIONS);
nCell = NCELL(pNode)+1;
+ n = (nCell+1)&(~1);
/* Allocate the buffers used by this operation. The allocation is
** relinquished before this function returns.
*/
- aCell = (RtreeCell *)sqlite3_malloc(nCell * (
- sizeof(RtreeCell) + /* aCell array */
- sizeof(int) + /* aOrder array */
- sizeof(int) + /* aSpare array */
- sizeof(float) /* aDistance array */
+ aCell = (RtreeCell *)sqlite3_malloc(n * (
+ sizeof(RtreeCell) + /* aCell array */
+ sizeof(int) + /* aOrder array */
+ sizeof(int) + /* aSpare array */
+ sizeof(RtreeDValue) /* aDistance array */
));
if( !aCell ){
return SQLITE_NOMEM;
}
- aOrder = (int *)&aCell[nCell];
- aSpare = (int *)&aOrder[nCell];
- aDistance = (float *)&aSpare[nCell];
+ aOrder = (int *)&aCell[n];
+ aSpare = (int *)&aOrder[n];
+ aDistance = (RtreeDValue *)&aSpare[n];
for(ii=0; ii<nCell; ii++){
if( ii==(nCell-1) ){
@@ -126902,19 +136503,19 @@ static int Reinsert(
}
aOrder[ii] = ii;
for(iDim=0; iDim<pRtree->nDim; iDim++){
- aCenterCoord[iDim] += (float)DCOORD(aCell[ii].aCoord[iDim*2]);
- aCenterCoord[iDim] += (float)DCOORD(aCell[ii].aCoord[iDim*2+1]);
+ aCenterCoord[iDim] += DCOORD(aCell[ii].aCoord[iDim*2]);
+ aCenterCoord[iDim] += DCOORD(aCell[ii].aCoord[iDim*2+1]);
}
}
for(iDim=0; iDim<pRtree->nDim; iDim++){
- aCenterCoord[iDim] = (float)(aCenterCoord[iDim]/((float)nCell*2.0));
+ aCenterCoord[iDim] = (aCenterCoord[iDim]/(nCell*(RtreeDValue)2));
}
for(ii=0; ii<nCell; ii++){
aDistance[ii] = 0.0;
for(iDim=0; iDim<pRtree->nDim; iDim++){
- float coord = (float)(DCOORD(aCell[ii].aCoord[iDim*2+1]) -
- DCOORD(aCell[ii].aCoord[iDim*2]));
+ RtreeDValue coord = (DCOORD(aCell[ii].aCoord[iDim*2+1]) -
+ DCOORD(aCell[ii].aCoord[iDim*2]));
aDistance[ii] += (coord-aCenterCoord[iDim])*(coord-aCenterCoord[iDim]);
}
}
@@ -127044,12 +136645,12 @@ static int newRowid(Rtree *pRtree, i64 *piRowid){
*/
static int rtreeDeleteRowid(Rtree *pRtree, sqlite3_int64 iDelete){
int rc; /* Return code */
- RtreeNode *pLeaf; /* Leaf node containing record iDelete */
+ RtreeNode *pLeaf = 0; /* Leaf node containing record iDelete */
int iCell; /* Index of iDelete cell in pLeaf */
RtreeNode *pRoot; /* Root node of rtree structure */
- /* Obtain a reference to the root node to initialise Rtree.iDepth */
+ /* Obtain a reference to the root node to initialize Rtree.iDepth */
rc = nodeAcquire(pRtree, 1, 0, &pRoot);
/* Obtain a reference to the leaf node that contains the entry
@@ -127124,6 +136725,36 @@ static int rtreeDeleteRowid(Rtree *pRtree, sqlite3_int64 iDelete){
}
/*
+** Rounding constants for float->double conversion.
+*/
+#define RNDTOWARDS (1.0 - 1.0/8388608.0) /* Round towards zero */
+#define RNDAWAY (1.0 + 1.0/8388608.0) /* Round away from zero */
+
+#if !defined(SQLITE_RTREE_INT_ONLY)
+/*
+** Convert an sqlite3_value into an RtreeValue (presumably a float)
+** while taking care to round toward negative or positive, respectively.
+*/
+static RtreeValue rtreeValueDown(sqlite3_value *v){
+ double d = sqlite3_value_double(v);
+ float f = (float)d;
+ if( f>d ){
+ f = (float)(d*(d<0 ? RNDAWAY : RNDTOWARDS));
+ }
+ return f;
+}
+static RtreeValue rtreeValueUp(sqlite3_value *v){
+ double d = sqlite3_value_double(v);
+ float f = (float)d;
+ if( f<d ){
+ f = (float)(d*(d<0 ? RNDTOWARDS : RNDAWAY));
+ }
+ return f;
+}
+#endif /* !defined(SQLITE_RTREE_INT_ONLY) */
+
+
+/*
** The xUpdate method for rtree module virtual tables.
*/
static int rtreeUpdate(
@@ -127156,16 +136787,19 @@ static int rtreeUpdate(
/* Populate the cell.aCoord[] array. The first coordinate is azData[3]. */
assert( nData==(pRtree->nDim*2 + 3) );
+#ifndef SQLITE_RTREE_INT_ONLY
if( pRtree->eCoordType==RTREE_COORD_REAL32 ){
for(ii=0; ii<(pRtree->nDim*2); ii+=2){
- cell.aCoord[ii].f = (float)sqlite3_value_double(azData[ii+3]);
- cell.aCoord[ii+1].f = (float)sqlite3_value_double(azData[ii+4]);
+ cell.aCoord[ii].f = rtreeValueDown(azData[ii+3]);
+ cell.aCoord[ii+1].f = rtreeValueUp(azData[ii+4]);
if( cell.aCoord[ii].f>cell.aCoord[ii+1].f ){
rc = SQLITE_CONSTRAINT;
goto constraint;
}
}
- }else{
+ }else
+#endif
+ {
for(ii=0; ii<(pRtree->nDim*2); ii+=2){
cell.aCoord[ii].i = sqlite3_value_int(azData[ii+3]);
cell.aCoord[ii+1].i = sqlite3_value_int(azData[ii+4]);
@@ -127214,7 +136848,7 @@ static int rtreeUpdate(
*/
if( rc==SQLITE_OK && nData>1 ){
/* Insert the new record into the r-tree */
- RtreeNode *pLeaf;
+ RtreeNode *pLeaf = 0;
/* Figure out the rowid of the new row. */
if( bHaveRowid==0 ){
@@ -127400,7 +137034,8 @@ static int getIntFromStmt(sqlite3 *db, const char *zSql, int *piVal){
static int getNodeSize(
sqlite3 *db, /* Database handle */
Rtree *pRtree, /* Rtree handle */
- int isCreate /* True for xCreate, false for xConnect */
+ int isCreate, /* True for xCreate, false for xConnect */
+ char **pzErr /* OUT: Error message, if any */
){
int rc;
char *zSql;
@@ -127413,6 +137048,8 @@ static int getNodeSize(
if( (4+pRtree->nBytesPerCell*RTREE_MAXCELLS)<pRtree->iNodeSize ){
pRtree->iNodeSize = 4+pRtree->nBytesPerCell*RTREE_MAXCELLS;
}
+ }else{
+ *pzErr = sqlite3_mprintf("%s", sqlite3_errmsg(db));
}
}else{
zSql = sqlite3_mprintf(
@@ -127420,6 +137057,9 @@ static int getNodeSize(
pRtree->zDb, pRtree->zName
);
rc = getIntFromStmt(db, zSql, &pRtree->iNodeSize);
+ if( rc!=SQLITE_OK ){
+ *pzErr = sqlite3_mprintf("%s", sqlite3_errmsg(db));
+ }
}
sqlite3_free(zSql);
@@ -127465,8 +137105,8 @@ static int rtreeInit(
sqlite3_vtab_config(db, SQLITE_VTAB_CONSTRAINT_SUPPORT, 1);
/* Allocate the sqlite3_vtab structure */
- nDb = strlen(argv[1]);
- nName = strlen(argv[2]);
+ nDb = (int)strlen(argv[1]);
+ nName = (int)strlen(argv[2]);
pRtree = (Rtree *)sqlite3_malloc(sizeof(Rtree)+nDb+nName+2);
if( !pRtree ){
return SQLITE_NOMEM;
@@ -127483,7 +137123,7 @@ static int rtreeInit(
memcpy(pRtree->zName, argv[2], nName);
/* Figure out the node size to use. */
- rc = getNodeSize(db, pRtree, isCreate);
+ rc = getNodeSize(db, pRtree, isCreate, pzErr);
/* Create/Connect to the underlying relational database schema. If
** that is successful, call sqlite3_declare_vtab() to configure
@@ -127561,10 +137201,16 @@ static void rtreenode(sqlite3_context *ctx, int nArg, sqlite3_value **apArg){
nodeGetCell(&tree, &node, ii, &cell);
sqlite3_snprintf(512-nCell,&zCell[nCell],"%lld", cell.iRowid);
- nCell = strlen(zCell);
+ nCell = (int)strlen(zCell);
for(jj=0; jj<tree.nDim*2; jj++){
- sqlite3_snprintf(512-nCell,&zCell[nCell]," %f",(double)cell.aCoord[jj].f);
- nCell = strlen(zCell);
+#ifndef SQLITE_RTREE_INT_ONLY
+ sqlite3_snprintf(512-nCell,&zCell[nCell], " %f",
+ (double)cell.aCoord[jj].f);
+#else
+ sqlite3_snprintf(512-nCell,&zCell[nCell], " %d",
+ cell.aCoord[jj].i);
+#endif
+ nCell = (int)strlen(zCell);
}
if( zText ){
@@ -127605,7 +137251,11 @@ SQLITE_PRIVATE int sqlite3RtreeInit(sqlite3 *db){
rc = sqlite3_create_function(db, "rtreedepth", 1, utf8, 0,rtreedepth, 0, 0);
}
if( rc==SQLITE_OK ){
+#ifdef SQLITE_RTREE_INT_ONLY
+ void *c = (void *)RTREE_COORD_INT32;
+#else
void *c = (void *)RTREE_COORD_REAL32;
+#endif
rc = sqlite3_create_module_v2(db, "rtree", &rtreeModule, c, 0);
}
if( rc==SQLITE_OK ){
@@ -127639,7 +137289,7 @@ static void geomCallback(sqlite3_context *ctx, int nArg, sqlite3_value **aArg){
RtreeMatchArg *pBlob;
int nBlob;
- nBlob = sizeof(RtreeMatchArg) + (nArg-1)*sizeof(double);
+ nBlob = sizeof(RtreeMatchArg) + (nArg-1)*sizeof(RtreeDValue);
pBlob = (RtreeMatchArg *)sqlite3_malloc(nBlob);
if( !pBlob ){
sqlite3_result_error_nomem(ctx);
@@ -127650,7 +137300,11 @@ static void geomCallback(sqlite3_context *ctx, int nArg, sqlite3_value **aArg){
pBlob->pContext = pGeomCtx->pContext;
pBlob->nParam = nArg;
for(i=0; i<nArg; i++){
+#ifdef SQLITE_RTREE_INT_ONLY
+ pBlob->aParam[i] = sqlite3_value_int64(aArg[i]);
+#else
pBlob->aParam[i] = sqlite3_value_double(aArg[i]);
+#endif
}
sqlite3_result_blob(ctx, pBlob, nBlob, doSqlite3Free);
}
@@ -127662,7 +137316,7 @@ static void geomCallback(sqlite3_context *ctx, int nArg, sqlite3_value **aArg){
SQLITE_API int sqlite3_rtree_geometry_callback(
sqlite3 *db,
const char *zGeom,
- int (*xGeom)(sqlite3_rtree_geometry *, int, double *, int *),
+ int (*xGeom)(sqlite3_rtree_geometry *, int, RtreeDValue *, int *),
void *pContext
){
RtreeGeomCallback *pGeomCtx; /* Context object for new user-function */
@@ -127733,6 +137387,7 @@ SQLITE_API int sqlite3_extension_init(
#include <unicode/ustring.h>
#include <unicode/ucol.h>
+/* #include <assert.h> */
#ifndef SQLITE_CORE
SQLITE_EXTENSION_INIT1
@@ -128212,8 +137867,12 @@ SQLITE_API int sqlite3_extension_init(
#if !defined(SQLITE_CORE) || defined(SQLITE_ENABLE_FTS3)
#ifdef SQLITE_ENABLE_ICU
+/* #include <assert.h> */
+/* #include <string.h> */
#include <unicode/ubrk.h>
+/* #include <unicode/ucol.h> */
+/* #include <unicode/ustring.h> */
#include <unicode/utf16.h>
typedef struct IcuTokenizer IcuTokenizer;
@@ -128302,13 +137961,16 @@ static int icuOpen(
*ppCursor = 0;
- if( nInput<0 ){
+ if( zInput==0 ){
+ nInput = 0;
+ zInput = "";
+ }else if( nInput<0 ){
nInput = strlen(zInput);
}
nChar = nInput+1;
pCsr = (IcuCursor *)sqlite3_malloc(
sizeof(IcuCursor) + /* IcuCursor */
- nChar * sizeof(UChar) + /* IcuCursor.aChar[] */
+ ((nChar+3)&~3) * sizeof(UChar) + /* IcuCursor.aChar[] */
(nChar+1) * sizeof(int) /* IcuCursor.aOffset[] */
);
if( !pCsr ){
@@ -128316,7 +137978,7 @@ static int icuOpen(
}
memset(pCsr, 0, sizeof(IcuCursor));
pCsr->aChar = (UChar *)&pCsr[1];
- pCsr->aOffset = (int *)&pCsr->aChar[nChar];
+ pCsr->aOffset = (int *)&pCsr->aChar[(nChar+3)&~3];
pCsr->aOffset[iOut] = iInput;
U8_NEXT(zInput, iInput, nInput, c);
@@ -128388,7 +138050,7 @@ static int icuNext(
while( iStart<iEnd ){
int iWhite = iStart;
- U8_NEXT(pCsr->aChar, iWhite, pCsr->nChar, c);
+ U16_NEXT(pCsr->aChar, iWhite, pCsr->nChar, c);
if( u_isspace(c) ){
iStart = iWhite;
}else{
diff --git a/src/3rdparty/sqlite/sqlite3.h b/src/3rdparty/sqlite/sqlite3.h
index ed9edbd202..1332eb1628 100644
--- a/src/3rdparty/sqlite/sqlite3.h
+++ b/src/3rdparty/sqlite/sqlite3.h
@@ -107,9 +107,9 @@ extern "C" {
** [sqlite3_libversion_number()], [sqlite3_sourceid()],
** [sqlite_version()] and [sqlite_source_id()].
*/
-#define SQLITE_VERSION "3.7.7.1"
-#define SQLITE_VERSION_NUMBER 3007007
-#define SQLITE_SOURCE_ID "2011-06-28 17:39:05 af0d91adf497f5f36ec3813f04235a6e195a605f"
+#define SQLITE_VERSION "3.7.16.1"
+#define SQLITE_VERSION_NUMBER 3007016
+#define SQLITE_SOURCE_ID "2013-03-29 13:44:34 527231bc67285f01fb18d4451b28f61da3c4e39d"
/*
** CAPI3REF: Run-Time Library Version Numbers
@@ -177,7 +177,7 @@ SQLITE_API const char *sqlite3_compileoption_get(int N);
** CAPI3REF: Test To See If The Library Is Threadsafe
**
** ^The sqlite3_threadsafe() function returns zero if and only if
-** SQLite was compiled mutexing code omitted due to the
+** SQLite was compiled with mutexing code omitted due to the
** [SQLITE_THREADSAFE] compile-time option being set to 0.
**
** SQLite can be compiled with or without mutexes. When
@@ -219,7 +219,8 @@ SQLITE_API int sqlite3_threadsafe(void);
** the opaque structure named "sqlite3". It is useful to think of an sqlite3
** pointer as an object. The [sqlite3_open()], [sqlite3_open16()], and
** [sqlite3_open_v2()] interfaces are its constructors, and [sqlite3_close()]
-** is its destructor. There are many other interfaces (such as
+** and [sqlite3_close_v2()] are its destructors. There are many other
+** interfaces (such as
** [sqlite3_prepare_v2()], [sqlite3_create_function()], and
** [sqlite3_busy_timeout()] to name but three) that are methods on an
** sqlite3 object.
@@ -266,28 +267,46 @@ typedef sqlite_uint64 sqlite3_uint64;
/*
** CAPI3REF: Closing A Database Connection
**
-** ^The sqlite3_close() routine is the destructor for the [sqlite3] object.
-** ^Calls to sqlite3_close() return SQLITE_OK if the [sqlite3] object is
-** successfully destroyed and all associated resources are deallocated.
-**
-** Applications must [sqlite3_finalize | finalize] all [prepared statements]
-** and [sqlite3_blob_close | close] all [BLOB handles] associated with
-** the [sqlite3] object prior to attempting to close the object. ^If
-** sqlite3_close() is called on a [database connection] that still has
-** outstanding [prepared statements] or [BLOB handles], then it returns
-** SQLITE_BUSY.
-**
-** ^If [sqlite3_close()] is invoked while a transaction is open,
+** ^The sqlite3_close() and sqlite3_close_v2() routines are destructors
+** for the [sqlite3] object.
+** ^Calls to sqlite3_close() and sqlite3_close_v2() return SQLITE_OK if
+** the [sqlite3] object is successfully destroyed and all associated
+** resources are deallocated.
+**
+** ^If the database connection is associated with unfinalized prepared
+** statements or unfinished sqlite3_backup objects then sqlite3_close()
+** will leave the database connection open and return [SQLITE_BUSY].
+** ^If sqlite3_close_v2() is called with unfinalized prepared statements
+** and unfinished sqlite3_backups, then the database connection becomes
+** an unusable "zombie" which will automatically be deallocated when the
+** last prepared statement is finalized or the last sqlite3_backup is
+** finished. The sqlite3_close_v2() interface is intended for use with
+** host languages that are garbage collected, and where the order in which
+** destructors are called is arbitrary.
+**
+** Applications should [sqlite3_finalize | finalize] all [prepared statements],
+** [sqlite3_blob_close | close] all [BLOB handles], and
+** [sqlite3_backup_finish | finish] all [sqlite3_backup] objects associated
+** with the [sqlite3] object prior to attempting to close the object. ^If
+** sqlite3_close_v2() is called on a [database connection] that still has
+** outstanding [prepared statements], [BLOB handles], and/or
+** [sqlite3_backup] objects then it returns SQLITE_OK but the deallocation
+** of resources is deferred until all [prepared statements], [BLOB handles],
+** and [sqlite3_backup] objects are also destroyed.
+**
+** ^If an [sqlite3] object is destroyed while a transaction is open,
** the transaction is automatically rolled back.
**
-** The C parameter to [sqlite3_close(C)] must be either a NULL
+** The C parameter to [sqlite3_close(C)] and [sqlite3_close_v2(C)]
+** must be either a NULL
** pointer or an [sqlite3] object pointer obtained
** from [sqlite3_open()], [sqlite3_open16()], or
** [sqlite3_open_v2()], and not previously closed.
-** ^Calling sqlite3_close() with a NULL pointer argument is a
-** harmless no-op.
+** ^Calling sqlite3_close() or sqlite3_close_v2() with a NULL pointer
+** argument is a harmless no-op.
*/
-SQLITE_API int sqlite3_close(sqlite3 *);
+SQLITE_API int sqlite3_close(sqlite3*);
+SQLITE_API int sqlite3_close_v2(sqlite3*);
/*
** The type for a callback function.
@@ -371,7 +390,7 @@ SQLITE_API int sqlite3_exec(
** KEYWORDS: {result code} {result codes}
**
** Many SQLite functions return an integer result code from the set shown
-** here in order to indicates success or failure.
+** here in order to indicate success or failure.
**
** New error codes may be added in future versions of SQLite.
**
@@ -455,12 +474,26 @@ SQLITE_API int sqlite3_exec(
#define SQLITE_IOERR_SHMLOCK (SQLITE_IOERR | (20<<8))
#define SQLITE_IOERR_SHMMAP (SQLITE_IOERR | (21<<8))
#define SQLITE_IOERR_SEEK (SQLITE_IOERR | (22<<8))
+#define SQLITE_IOERR_DELETE_NOENT (SQLITE_IOERR | (23<<8))
#define SQLITE_LOCKED_SHAREDCACHE (SQLITE_LOCKED | (1<<8))
#define SQLITE_BUSY_RECOVERY (SQLITE_BUSY | (1<<8))
#define SQLITE_CANTOPEN_NOTEMPDIR (SQLITE_CANTOPEN | (1<<8))
+#define SQLITE_CANTOPEN_ISDIR (SQLITE_CANTOPEN | (2<<8))
+#define SQLITE_CANTOPEN_FULLPATH (SQLITE_CANTOPEN | (3<<8))
#define SQLITE_CORRUPT_VTAB (SQLITE_CORRUPT | (1<<8))
#define SQLITE_READONLY_RECOVERY (SQLITE_READONLY | (1<<8))
#define SQLITE_READONLY_CANTLOCK (SQLITE_READONLY | (2<<8))
+#define SQLITE_READONLY_ROLLBACK (SQLITE_READONLY | (3<<8))
+#define SQLITE_ABORT_ROLLBACK (SQLITE_ABORT | (2<<8))
+#define SQLITE_CONSTRAINT_CHECK (SQLITE_CONSTRAINT | (1<<8))
+#define SQLITE_CONSTRAINT_COMMITHOOK (SQLITE_CONSTRAINT | (2<<8))
+#define SQLITE_CONSTRAINT_FOREIGNKEY (SQLITE_CONSTRAINT | (3<<8))
+#define SQLITE_CONSTRAINT_FUNCTION (SQLITE_CONSTRAINT | (4<<8))
+#define SQLITE_CONSTRAINT_NOTNULL (SQLITE_CONSTRAINT | (5<<8))
+#define SQLITE_CONSTRAINT_PRIMARYKEY (SQLITE_CONSTRAINT | (6<<8))
+#define SQLITE_CONSTRAINT_TRIGGER (SQLITE_CONSTRAINT | (7<<8))
+#define SQLITE_CONSTRAINT_UNIQUE (SQLITE_CONSTRAINT | (8<<8))
+#define SQLITE_CONSTRAINT_VTAB (SQLITE_CONSTRAINT | (9<<8))
/*
** CAPI3REF: Flags For File Open Operations
@@ -476,6 +509,7 @@ SQLITE_API int sqlite3_exec(
#define SQLITE_OPEN_EXCLUSIVE 0x00000010 /* VFS only */
#define SQLITE_OPEN_AUTOPROXY 0x00000020 /* VFS only */
#define SQLITE_OPEN_URI 0x00000040 /* Ok for sqlite3_open_v2() */
+#define SQLITE_OPEN_MEMORY 0x00000080 /* Ok for sqlite3_open_v2() */
#define SQLITE_OPEN_MAIN_DB 0x00000100 /* VFS only */
#define SQLITE_OPEN_TEMP_DB 0x00000200 /* VFS only */
#define SQLITE_OPEN_TRANSIENT_DB 0x00000400 /* VFS only */
@@ -495,7 +529,7 @@ SQLITE_API int sqlite3_exec(
** CAPI3REF: Device Characteristics
**
** The xDeviceCharacteristics method of the [sqlite3_io_methods]
-** object returns an integer which is a vector of the these
+** object returns an integer which is a vector of these
** bit values expressing I/O characteristics of the mass storage
** device that holds the file that the [sqlite3_io_methods]
** refers to.
@@ -509,7 +543,11 @@ SQLITE_API int sqlite3_exec(
** first then the size of the file is extended, never the other
** way around. The SQLITE_IOCAP_SEQUENTIAL property means that
** information is written to disk in the same order as calls
-** to xWrite().
+** to xWrite(). The SQLITE_IOCAP_POWERSAFE_OVERWRITE property means that
+** after reboot following a crash or power loss, the only bytes in a
+** file that were written at the application level might have changed
+** and that adjacent bytes, even bytes within the same sector are
+** guaranteed to be unchanged.
*/
#define SQLITE_IOCAP_ATOMIC 0x00000001
#define SQLITE_IOCAP_ATOMIC512 0x00000002
@@ -523,6 +561,7 @@ SQLITE_API int sqlite3_exec(
#define SQLITE_IOCAP_SAFE_APPEND 0x00000200
#define SQLITE_IOCAP_SEQUENTIAL 0x00000400
#define SQLITE_IOCAP_UNDELETABLE_WHEN_OPEN 0x00000800
+#define SQLITE_IOCAP_POWERSAFE_OVERWRITE 0x00001000
/*
** CAPI3REF: File Locking Levels
@@ -711,7 +750,8 @@ struct sqlite3_io_methods {
** into an integer that the pArg argument points to. This capability
** is used during testing and only needs to be supported when SQLITE_TEST
** is defined.
-**
+** <ul>
+** <li>[[SQLITE_FCNTL_SIZE_HINT]]
** The [SQLITE_FCNTL_SIZE_HINT] opcode is used by SQLite to give the VFS
** layer a hint of how large the database file will grow to be during the
** current transaction. This hint is not guaranteed to be accurate but it
@@ -719,6 +759,7 @@ struct sqlite3_io_methods {
** file space based on this hint in order to help writes to the database
** file run faster.
**
+** <li>[[SQLITE_FCNTL_CHUNK_SIZE]]
** The [SQLITE_FCNTL_CHUNK_SIZE] opcode is used to request that the VFS
** extends and truncates the database file in chunks of a size specified
** by the user. The fourth argument to [sqlite3_file_control()] should
@@ -727,11 +768,13 @@ struct sqlite3_io_methods {
** chunks (say 1MB at a time), may reduce file-system fragmentation and
** improve performance on some systems.
**
+** <li>[[SQLITE_FCNTL_FILE_POINTER]]
** The [SQLITE_FCNTL_FILE_POINTER] opcode is used to obtain a pointer
** to the [sqlite3_file] object associated with a particular database
** connection. See the [sqlite3_file_control()] documentation for
** additional information.
**
+** <li>[[SQLITE_FCNTL_SYNC_OMITTED]]
** ^(The [SQLITE_FCNTL_SYNC_OMITTED] opcode is generated internally by
** SQLite and sent to all VFSes in place of a call to the xSync method
** when the database connection has [PRAGMA synchronous] set to OFF.)^
@@ -741,16 +784,127 @@ struct sqlite3_io_methods {
** Applications should not call [sqlite3_file_control()] with this
** opcode as doing so may disrupt the operation of the specialized VFSes
** that do require it.
+**
+** <li>[[SQLITE_FCNTL_WIN32_AV_RETRY]]
+** ^The [SQLITE_FCNTL_WIN32_AV_RETRY] opcode is used to configure automatic
+** retry counts and intervals for certain disk I/O operations for the
+** windows [VFS] in order to provide robustness in the presence of
+** anti-virus programs. By default, the windows VFS will retry file read,
+** file write, and file delete operations up to 10 times, with a delay
+** of 25 milliseconds before the first retry and with the delay increasing
+** by an additional 25 milliseconds with each subsequent retry. This
+** opcode allows these two values (10 retries and 25 milliseconds of delay)
+** to be adjusted. The values are changed for all database connections
+** within the same process. The argument is a pointer to an array of two
+** integers where the first integer i the new retry count and the second
+** integer is the delay. If either integer is negative, then the setting
+** is not changed but instead the prior value of that setting is written
+** into the array entry, allowing the current retry settings to be
+** interrogated. The zDbName parameter is ignored.
+**
+** <li>[[SQLITE_FCNTL_PERSIST_WAL]]
+** ^The [SQLITE_FCNTL_PERSIST_WAL] opcode is used to set or query the
+** persistent [WAL | Write Ahead Log] setting. By default, the auxiliary
+** write ahead log and shared memory files used for transaction control
+** are automatically deleted when the latest connection to the database
+** closes. Setting persistent WAL mode causes those files to persist after
+** close. Persisting the files is useful when other processes that do not
+** have write permission on the directory containing the database file want
+** to read the database file, as the WAL and shared memory files must exist
+** in order for the database to be readable. The fourth parameter to
+** [sqlite3_file_control()] for this opcode should be a pointer to an integer.
+** That integer is 0 to disable persistent WAL mode or 1 to enable persistent
+** WAL mode. If the integer is -1, then it is overwritten with the current
+** WAL persistence setting.
+**
+** <li>[[SQLITE_FCNTL_POWERSAFE_OVERWRITE]]
+** ^The [SQLITE_FCNTL_POWERSAFE_OVERWRITE] opcode is used to set or query the
+** persistent "powersafe-overwrite" or "PSOW" setting. The PSOW setting
+** determines the [SQLITE_IOCAP_POWERSAFE_OVERWRITE] bit of the
+** xDeviceCharacteristics methods. The fourth parameter to
+** [sqlite3_file_control()] for this opcode should be a pointer to an integer.
+** That integer is 0 to disable zero-damage mode or 1 to enable zero-damage
+** mode. If the integer is -1, then it is overwritten with the current
+** zero-damage mode setting.
+**
+** <li>[[SQLITE_FCNTL_OVERWRITE]]
+** ^The [SQLITE_FCNTL_OVERWRITE] opcode is invoked by SQLite after opening
+** a write transaction to indicate that, unless it is rolled back for some
+** reason, the entire database file will be overwritten by the current
+** transaction. This is used by VACUUM operations.
+**
+** <li>[[SQLITE_FCNTL_VFSNAME]]
+** ^The [SQLITE_FCNTL_VFSNAME] opcode can be used to obtain the names of
+** all [VFSes] in the VFS stack. The names are of all VFS shims and the
+** final bottom-level VFS are written into memory obtained from
+** [sqlite3_malloc()] and the result is stored in the char* variable
+** that the fourth parameter of [sqlite3_file_control()] points to.
+** The caller is responsible for freeing the memory when done. As with
+** all file-control actions, there is no guarantee that this will actually
+** do anything. Callers should initialize the char* variable to a NULL
+** pointer in case this file-control is not implemented. This file-control
+** is intended for diagnostic use only.
+**
+** <li>[[SQLITE_FCNTL_PRAGMA]]
+** ^Whenever a [PRAGMA] statement is parsed, an [SQLITE_FCNTL_PRAGMA]
+** file control is sent to the open [sqlite3_file] object corresponding
+** to the database file to which the pragma statement refers. ^The argument
+** to the [SQLITE_FCNTL_PRAGMA] file control is an array of
+** pointers to strings (char**) in which the second element of the array
+** is the name of the pragma and the third element is the argument to the
+** pragma or NULL if the pragma has no argument. ^The handler for an
+** [SQLITE_FCNTL_PRAGMA] file control can optionally make the first element
+** of the char** argument point to a string obtained from [sqlite3_mprintf()]
+** or the equivalent and that string will become the result of the pragma or
+** the error message if the pragma fails. ^If the
+** [SQLITE_FCNTL_PRAGMA] file control returns [SQLITE_NOTFOUND], then normal
+** [PRAGMA] processing continues. ^If the [SQLITE_FCNTL_PRAGMA]
+** file control returns [SQLITE_OK], then the parser assumes that the
+** VFS has handled the PRAGMA itself and the parser generates a no-op
+** prepared statement. ^If the [SQLITE_FCNTL_PRAGMA] file control returns
+** any result code other than [SQLITE_OK] or [SQLITE_NOTFOUND], that means
+** that the VFS encountered an error while handling the [PRAGMA] and the
+** compilation of the PRAGMA fails with an error. ^The [SQLITE_FCNTL_PRAGMA]
+** file control occurs at the beginning of pragma statement analysis and so
+** it is able to override built-in [PRAGMA] statements.
+**
+** <li>[[SQLITE_FCNTL_BUSYHANDLER]]
+** ^This file-control may be invoked by SQLite on the database file handle
+** shortly after it is opened in order to provide a custom VFS with access
+** to the connections busy-handler callback. The argument is of type (void **)
+** - an array of two (void *) values. The first (void *) actually points
+** to a function of type (int (*)(void *)). In order to invoke the connections
+** busy-handler, this function should be invoked with the second (void *) in
+** the array as the only argument. If it returns non-zero, then the operation
+** should be retried. If it returns zero, the custom VFS should abandon the
+** current operation.
+**
+** <li>[[SQLITE_FCNTL_TEMPFILENAME]]
+** ^Application can invoke this file-control to have SQLite generate a
+** temporary filename using the same algorithm that is followed to generate
+** temporary filenames for TEMP tables and other internal uses. The
+** argument should be a char** which will be filled with the filename
+** written into memory obtained from [sqlite3_malloc()]. The caller should
+** invoke [sqlite3_free()] on the result to avoid a memory leak.
+**
+** </ul>
*/
-#define SQLITE_FCNTL_LOCKSTATE 1
-#define SQLITE_GET_LOCKPROXYFILE 2
-#define SQLITE_SET_LOCKPROXYFILE 3
-#define SQLITE_LAST_ERRNO 4
-#define SQLITE_FCNTL_SIZE_HINT 5
-#define SQLITE_FCNTL_CHUNK_SIZE 6
-#define SQLITE_FCNTL_FILE_POINTER 7
-#define SQLITE_FCNTL_SYNC_OMITTED 8
-
+#define SQLITE_FCNTL_LOCKSTATE 1
+#define SQLITE_GET_LOCKPROXYFILE 2
+#define SQLITE_SET_LOCKPROXYFILE 3
+#define SQLITE_LAST_ERRNO 4
+#define SQLITE_FCNTL_SIZE_HINT 5
+#define SQLITE_FCNTL_CHUNK_SIZE 6
+#define SQLITE_FCNTL_FILE_POINTER 7
+#define SQLITE_FCNTL_SYNC_OMITTED 8
+#define SQLITE_FCNTL_WIN32_AV_RETRY 9
+#define SQLITE_FCNTL_PERSIST_WAL 10
+#define SQLITE_FCNTL_OVERWRITE 11
+#define SQLITE_FCNTL_VFSNAME 12
+#define SQLITE_FCNTL_POWERSAFE_OVERWRITE 13
+#define SQLITE_FCNTL_PRAGMA 14
+#define SQLITE_FCNTL_BUSYHANDLER 15
+#define SQLITE_FCNTL_TEMPFILENAME 16
/*
** CAPI3REF: Mutex Handle
@@ -805,7 +959,7 @@ typedef struct sqlite3_mutex sqlite3_mutex;
** from xFullPathname() with an optional suffix added.
** ^If a suffix is added to the zFilename parameter, it will
** consist of a single "-" character followed by no more than
-** 10 alphanumeric and/or "-" characters.
+** 11 alphanumeric and/or "-" characters.
** ^SQLite further guarantees that
** the string will be valid and unchanged until xClose() is
** called. Because of the previous sentence,
@@ -1178,16 +1332,10 @@ SQLITE_API int sqlite3_db_config(sqlite3*, int op, ...);
** order to verify that SQLite recovers gracefully from such
** conditions.
**
-** The xMalloc and xFree methods must work like the
-** malloc() and free() functions from the standard C library.
-** The xRealloc method must work like realloc() from the standard C library
-** with the exception that if the second argument to xRealloc is zero,
-** xRealloc must be a no-op - it must not perform any allocation or
-** deallocation. ^SQLite guarantees that the second argument to
+** The xMalloc, xRealloc, and xFree methods must work like the
+** malloc(), realloc() and free() functions from the standard C library.
+** ^SQLite guarantees that the second argument to
** xRealloc is always a value returned by a prior call to xRoundup.
-** And so in cases where xRoundup always returns a positive number,
-** xRealloc can perform exactly as the standard library realloc() and
-** still be in compliance with this specification.
**
** xSize should return the allocated size of a memory allocation
** previously obtained from xMalloc or xRealloc. The allocated size
@@ -1342,7 +1490,7 @@ struct sqlite3_mem_methods {
** <dd> ^This option specifies a static memory buffer that SQLite can use for
** the database page cache with the default page cache implementation.
** This configuration should not be used if an application-define page
-** cache implementation is loaded using the SQLITE_CONFIG_PCACHE option.
+** cache implementation is loaded using the SQLITE_CONFIG_PCACHE2 option.
** There are three arguments to this option: A pointer to 8-byte aligned
** memory, the size of each page buffer (sz), and the number of pages (N).
** The sz argument should be the size of the largest database page
@@ -1373,8 +1521,8 @@ struct sqlite3_mem_methods {
** allocator is engaged to handle all of SQLites memory allocation needs.
** The first pointer (the memory pointer) must be aligned to an 8-byte
** boundary or subsequent behavior of SQLite will be undefined.
-** The minimum allocation size is capped at 2^12. Reasonable values
-** for the minimum allocation size are 2^5 through 2^8.</dd>
+** The minimum allocation size is capped at 2**12. Reasonable values
+** for the minimum allocation size are 2**5 through 2**8.</dd>
**
** [[SQLITE_CONFIG_MUTEX]] <dt>SQLITE_CONFIG_MUTEX</dt>
** <dd> ^(This option takes a single argument which is a pointer to an
@@ -1411,15 +1559,15 @@ struct sqlite3_mem_methods {
** verb to [sqlite3_db_config()] can be used to change the lookaside
** configuration on individual connections.)^ </dd>
**
-** [[SQLITE_CONFIG_PCACHE]] <dt>SQLITE_CONFIG_PCACHE</dt>
+** [[SQLITE_CONFIG_PCACHE2]] <dt>SQLITE_CONFIG_PCACHE2</dt>
** <dd> ^(This option takes a single argument which is a pointer to
-** an [sqlite3_pcache_methods] object. This object specifies the interface
+** an [sqlite3_pcache_methods2] object. This object specifies the interface
** to a custom page cache implementation.)^ ^SQLite makes a copy of the
** object and uses it for page cache memory allocations.</dd>
**
-** [[SQLITE_CONFIG_GETPCACHE]] <dt>SQLITE_CONFIG_GETPCACHE</dt>
+** [[SQLITE_CONFIG_GETPCACHE2]] <dt>SQLITE_CONFIG_GETPCACHE2</dt>
** <dd> ^(This option takes a single argument which is a pointer to an
-** [sqlite3_pcache_methods] object. SQLite copies of the current
+** [sqlite3_pcache_methods2] object. SQLite copies of the current
** page cache implementation into that object.)^ </dd>
**
** [[SQLITE_CONFIG_LOG]] <dt>SQLITE_CONFIG_LOG</dt>
@@ -1452,6 +1600,39 @@ struct sqlite3_mem_methods {
** database connection is opened. By default, URI handling is globally
** disabled. The default value may be changed by compiling with the
** [SQLITE_USE_URI] symbol defined.
+**
+** [[SQLITE_CONFIG_COVERING_INDEX_SCAN]] <dt>SQLITE_CONFIG_COVERING_INDEX_SCAN
+** <dd> This option takes a single integer argument which is interpreted as
+** a boolean in order to enable or disable the use of covering indices for
+** full table scans in the query optimizer. The default setting is determined
+** by the [SQLITE_ALLOW_COVERING_INDEX_SCAN] compile-time option, or is "on"
+** if that compile-time option is omitted.
+** The ability to disable the use of covering indices for full table scans
+** is because some incorrectly coded legacy applications might malfunction
+** malfunction when the optimization is enabled. Providing the ability to
+** disable the optimization allows the older, buggy application code to work
+** without change even with newer versions of SQLite.
+**
+** [[SQLITE_CONFIG_PCACHE]] [[SQLITE_CONFIG_GETPCACHE]]
+** <dt>SQLITE_CONFIG_PCACHE and SQLITE_CONFIG_GETPCACHE
+** <dd> These options are obsolete and should not be used by new code.
+** They are retained for backwards compatibility but are now no-ops.
+** </dl>
+**
+** [[SQLITE_CONFIG_SQLLOG]]
+** <dt>SQLITE_CONFIG_SQLLOG
+** <dd>This option is only available if sqlite is compiled with the
+** SQLITE_ENABLE_SQLLOG pre-processor macro defined. The first argument should
+** be a pointer to a function of type void(*)(void*,sqlite3*,const char*, int).
+** The second should be of type (void*). The callback is invoked by the library
+** in three separate circumstances, identified by the value passed as the
+** fourth parameter. If the fourth parameter is 0, then the database connection
+** passed as the second argument has just been opened. The third argument
+** points to a buffer containing the name of the main database file. If the
+** fourth parameter is 1, then the SQL statement that the third parameter
+** points to has just been executed. Or, if the fourth parameter is 2, then
+** the connection being passed as the second parameter is being closed. The
+** third parameter is passed NULL In this case.
** </dl>
*/
#define SQLITE_CONFIG_SINGLETHREAD 1 /* nil */
@@ -1467,10 +1648,14 @@ struct sqlite3_mem_methods {
#define SQLITE_CONFIG_GETMUTEX 11 /* sqlite3_mutex_methods* */
/* previously SQLITE_CONFIG_CHUNKALLOC 12 which is now unused. */
#define SQLITE_CONFIG_LOOKASIDE 13 /* int int */
-#define SQLITE_CONFIG_PCACHE 14 /* sqlite3_pcache_methods* */
-#define SQLITE_CONFIG_GETPCACHE 15 /* sqlite3_pcache_methods* */
+#define SQLITE_CONFIG_PCACHE 14 /* no-op */
+#define SQLITE_CONFIG_GETPCACHE 15 /* no-op */
#define SQLITE_CONFIG_LOG 16 /* xFunc, void* */
#define SQLITE_CONFIG_URI 17 /* int */
+#define SQLITE_CONFIG_PCACHE2 18 /* sqlite3_pcache_methods2* */
+#define SQLITE_CONFIG_GETPCACHE2 19 /* sqlite3_pcache_methods2* */
+#define SQLITE_CONFIG_COVERING_INDEX_SCAN 20 /* int */
+#define SQLITE_CONFIG_SQLLOG 21 /* xSqllog, void* */
/*
** CAPI3REF: Database Connection Configuration Options
@@ -1955,7 +2140,7 @@ SQLITE_API void sqlite3_free_table(char **result);
** All of the usual printf() formatting options apply. In addition, there
** is are "%q", "%Q", and "%z" options.
**
-** ^(The %q option works like %s in that it substitutes a null-terminated
+** ^(The %q option works like %s in that it substitutes a nul-terminated
** string from the argument list. But %q also doubles every '\'' character.
** %q is designed for use inside a string literal.)^ By doubling each '\''
** character it escapes that character and allows it to be inserted into
@@ -2068,12 +2253,12 @@ SQLITE_API char *sqlite3_vsnprintf(int,char*,const char*, va_list);
** implementation of these routines to be omitted. That capability
** is no longer provided. Only built-in memory allocators can be used.
**
-** The Windows OS interface layer calls
+** Prior to SQLite version 3.7.10, the Windows OS interface layer called
** the system malloc() and free() directly when converting
** filenames between the UTF-8 encoding used by SQLite
** and whatever filename encoding is used by the particular Windows
-** installation. Memory allocation errors are detected, but
-** they are reported back as [SQLITE_CANTOPEN] or
+** installation. Memory allocation errors were detected, but
+** they were reported back as [SQLITE_CANTOPEN] or
** [SQLITE_IOERR] rather than [SQLITE_NOMEM].
**
** The pointer arguments to [sqlite3_free()] and [sqlite3_realloc()]
@@ -2474,18 +2659,20 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*);
** present, then the VFS specified by the option takes precedence over
** the value passed as the fourth parameter to sqlite3_open_v2().
**
-** <li> <b>mode</b>: ^(The mode parameter may be set to either "ro", "rw" or
-** "rwc". Attempting to set it to any other value is an error)^.
+** <li> <b>mode</b>: ^(The mode parameter may be set to either "ro", "rw",
+** "rwc", or "memory". Attempting to set it to any other value is
+** an error)^.
** ^If "ro" is specified, then the database is opened for read-only
** access, just as if the [SQLITE_OPEN_READONLY] flag had been set in the
-** third argument to sqlite3_prepare_v2(). ^If the mode option is set to
+** third argument to sqlite3_open_v2(). ^If the mode option is set to
** "rw", then the database is opened for read-write (but not create)
** access, as if SQLITE_OPEN_READWRITE (but not SQLITE_OPEN_CREATE) had
** been set. ^Value "rwc" is equivalent to setting both
-** SQLITE_OPEN_READWRITE and SQLITE_OPEN_CREATE. ^If sqlite3_open_v2() is
-** used, it is an error to specify a value for the mode parameter that is
-** less restrictive than that specified by the flags passed as the third
-** parameter.
+** SQLITE_OPEN_READWRITE and SQLITE_OPEN_CREATE. ^If the mode option is
+** set to "memory" then a pure [in-memory database] that never reads
+** or writes from disk is used. ^It is an error to specify a value for
+** the mode parameter that is less restrictive than that specified by
+** the flags passed in the third parameter to sqlite3_open_v2().
**
** <li> <b>cache</b>: ^The cache parameter may be set to either "shared" or
** "private". ^Setting it to "shared" is equivalent to setting the
@@ -2493,7 +2680,7 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*);
** sqlite3_open_v2(). ^Setting the cache parameter to "private" is
** equivalent to setting the SQLITE_OPEN_PRIVATECACHE bit.
** ^If sqlite3_open_v2() is used and the "cache" parameter is present in
-** a URI filename, its value overrides any behaviour requested by setting
+** a URI filename, its value overrides any behavior requested by setting
** SQLITE_OPEN_PRIVATECACHE or SQLITE_OPEN_SHAREDCACHE flag.
** </ul>
**
@@ -2544,6 +2731,12 @@ SQLITE_API void sqlite3_progress_handler(sqlite3*, int, int(*)(void*), void*);
** codepage is currently defined. Filenames containing international
** characters must be converted to UTF-8 prior to passing them into
** sqlite3_open() or sqlite3_open_v2().
+**
+** <b>Note to Windows Runtime users:</b> The temporary directory must be set
+** prior to calling sqlite3_open() or sqlite3_open_v2(). Otherwise, various
+** features that require the use of temporary files may fail.
+**
+** See also: [sqlite3_temp_directory]
*/
SQLITE_API int sqlite3_open(
const char *filename, /* Database filename (UTF-8) */
@@ -2563,21 +2756,45 @@ SQLITE_API int sqlite3_open_v2(
/*
** CAPI3REF: Obtain Values For URI Parameters
**
-** This is a utility routine, useful to VFS implementations, that checks
+** These are utility routines, useful to VFS implementations, that check
** to see if a database file was a URI that contained a specific query
-** parameter, and if so obtains the value of the query parameter.
-**
-** The zFilename argument is the filename pointer passed into the xOpen()
-** method of a VFS implementation. The zParam argument is the name of the
-** query parameter we seek. This routine returns the value of the zParam
-** parameter if it exists. If the parameter does not exist, this routine
-** returns a NULL pointer.
-**
-** If the zFilename argument to this function is not a pointer that SQLite
-** passed into the xOpen VFS method, then the behavior of this routine
-** is undefined and probably undesirable.
+** parameter, and if so obtains the value of that query parameter.
+**
+** If F is the database filename pointer passed into the xOpen() method of
+** a VFS implementation when the flags parameter to xOpen() has one or
+** more of the [SQLITE_OPEN_URI] or [SQLITE_OPEN_MAIN_DB] bits set and
+** P is the name of the query parameter, then
+** sqlite3_uri_parameter(F,P) returns the value of the P
+** parameter if it exists or a NULL pointer if P does not appear as a
+** query parameter on F. If P is a query parameter of F
+** has no explicit value, then sqlite3_uri_parameter(F,P) returns
+** a pointer to an empty string.
+**
+** The sqlite3_uri_boolean(F,P,B) routine assumes that P is a boolean
+** parameter and returns true (1) or false (0) according to the value
+** of P. The sqlite3_uri_boolean(F,P,B) routine returns true (1) if the
+** value of query parameter P is one of "yes", "true", or "on" in any
+** case or if the value begins with a non-zero number. The
+** sqlite3_uri_boolean(F,P,B) routines returns false (0) if the value of
+** query parameter P is one of "no", "false", or "off" in any case or
+** if the value begins with a numeric zero. If P is not a query
+** parameter on F or if the value of P is does not match any of the
+** above, then sqlite3_uri_boolean(F,P,B) returns (B!=0).
+**
+** The sqlite3_uri_int64(F,P,D) routine converts the value of P into a
+** 64-bit signed integer and returns that integer, or D if P does not
+** exist. If the value of P is something other than an integer, then
+** zero is returned.
+**
+** If F is a NULL pointer, then sqlite3_uri_parameter(F,P) returns NULL and
+** sqlite3_uri_boolean(F,P,B) returns B. If F is not a NULL pointer and
+** is not a database file pathname pointer that SQLite passed into the xOpen
+** VFS method, then the behavior of this routine is undefined and probably
+** undesirable.
*/
SQLITE_API const char *sqlite3_uri_parameter(const char *zFilename, const char *zParam);
+SQLITE_API int sqlite3_uri_boolean(const char *zFile, const char *zParam, int bDefault);
+SQLITE_API sqlite3_int64 sqlite3_uri_int64(const char*, const char*, sqlite3_int64);
/*
@@ -2599,6 +2816,11 @@ SQLITE_API const char *sqlite3_uri_parameter(const char *zFilename, const char *
** However, the error string might be overwritten or deallocated by
** subsequent calls to other SQLite interface functions.)^
**
+** ^The sqlite3_errstr() interface returns the English-language text
+** that describes the [result code], as UTF-8.
+** ^(Memory to hold the error message string is managed internally
+** and must not be freed by the application)^.
+**
** When the serialized [threading mode] is in use, it might be the
** case that a second error occurs on a separate thread in between
** the time of the first error and the call to these interfaces.
@@ -2617,6 +2839,7 @@ SQLITE_API int sqlite3_errcode(sqlite3 *db);
SQLITE_API int sqlite3_extended_errcode(sqlite3 *db);
SQLITE_API const char *sqlite3_errmsg(sqlite3*);
SQLITE_API const void *sqlite3_errmsg16(sqlite3*);
+SQLITE_API const char *sqlite3_errstr(int);
/*
** CAPI3REF: SQL Statement Object
@@ -2773,7 +2996,8 @@ SQLITE_API int sqlite3_limit(sqlite3*, int id, int newVal);
** that the supplied string is nul-terminated, then there is a small
** performance advantage to be gained by passing an nByte parameter that
** is equal to the number of bytes in the input string <i>including</i>
-** the nul-terminator bytes.
+** the nul-terminator bytes as this saves SQLite from having to
+** make a copy of the input string.
**
** ^If pzTail is not NULL then *pzTail is made to point to the first byte
** past the end of the first SQL statement in zSql. These routines only
@@ -2824,7 +3048,7 @@ SQLITE_API int sqlite3_limit(sqlite3*, int id, int newVal);
** ^The specific value of WHERE-clause [parameter] might influence the
** choice of query plan if the parameter is the left-hand side of a [LIKE]
** or [GLOB] operator or if the parameter is compared to an indexed column
-** and the [SQLITE_ENABLE_STAT2] compile-time option is enabled.
+** and the [SQLITE_ENABLE_STAT3] compile-time option is enabled.
** the
** </li>
** </ol>
@@ -2899,6 +3123,25 @@ SQLITE_API const char *sqlite3_sql(sqlite3_stmt *pStmt);
SQLITE_API int sqlite3_stmt_readonly(sqlite3_stmt *pStmt);
/*
+** CAPI3REF: Determine If A Prepared Statement Has Been Reset
+**
+** ^The sqlite3_stmt_busy(S) interface returns true (non-zero) if the
+** [prepared statement] S has been stepped at least once using
+** [sqlite3_step(S)] but has not run to completion and/or has not
+** been reset using [sqlite3_reset(S)]. ^The sqlite3_stmt_busy(S)
+** interface returns false if S is a NULL pointer. If S is not a
+** NULL pointer and is not a pointer to a valid [prepared statement]
+** object, then the behavior is undefined and probably undesirable.
+**
+** This interface can be used in combination [sqlite3_next_stmt()]
+** to locate all prepared statements associated with a database
+** connection that are in need of being reset. This can be used,
+** for example, in diagnostic routines to search for prepared
+** statements that are holding a transaction open.
+*/
+SQLITE_API int sqlite3_stmt_busy(sqlite3_stmt*);
+
+/*
** CAPI3REF: Dynamically Typed Value Object
** KEYWORDS: {protected sqlite3_value} {unprotected sqlite3_value}
**
@@ -2992,8 +3235,18 @@ typedef struct sqlite3_context sqlite3_context;
** ^(In those routines that have a fourth argument, its value is the
** number of bytes in the parameter. To be clear: the value is the
** number of <u>bytes</u> in the value, not the number of characters.)^
-** ^If the fourth parameter is negative, the length of the string is
+** ^If the fourth parameter to sqlite3_bind_text() or sqlite3_bind_text16()
+** is negative, then the length of the string is
** the number of bytes up to the first zero terminator.
+** If the fourth parameter to sqlite3_bind_blob() is negative, then
+** the behavior is undefined.
+** If a non-negative fourth parameter is provided to sqlite3_bind_text()
+** or sqlite3_bind_text16() then that parameter must be the byte offset
+** where the NUL terminator would occur assuming the string were NUL
+** terminated. If any NUL characters occur at byte offsets less than
+** the value of the fourth parameter then the resulting string value will
+** contain embedded NULs. The result of expressions involving strings
+** with embedded NULs is undefined.
**
** ^The fifth argument to sqlite3_bind_blob(), sqlite3_bind_text(), and
** sqlite3_bind_text16() is a destructor used to dispose of the BLOB or
@@ -3327,6 +3580,12 @@ SQLITE_API int sqlite3_step(sqlite3_stmt*);
** (via calls to the [sqlite3_column_int | sqlite3_column_*()] of
** interfaces) then sqlite3_data_count(P) returns 0.
** ^The sqlite3_data_count(P) routine also returns 0 if P is a NULL pointer.
+** ^The sqlite3_data_count(P) routine returns 0 if the previous call to
+** [sqlite3_step](P) returned [SQLITE_DONE]. ^The sqlite3_data_count(P)
+** will return non-zero if previous call to [sqlite3_step](P) returned
+** [SQLITE_ROW], except in the case of the [PRAGMA incremental_vacuum]
+** where it always returns zero since each step of that multi-step
+** pragma returns 0 columns of data.
**
** See also: [sqlite3_column_count()]
*/
@@ -3426,7 +3685,7 @@ SQLITE_API int sqlite3_data_count(sqlite3_stmt *pStmt);
** bytes in the string, not the number of characters.
**
** ^Strings returned by sqlite3_column_text() and sqlite3_column_text16(),
-** even empty strings, are always zero terminated. ^The return
+** even empty strings, are always zero-terminated. ^The return
** value from sqlite3_column_blob() for a zero-length BLOB is a NULL pointer.
**
** ^The object returned by [sqlite3_column_value()] is an
@@ -3739,7 +3998,8 @@ SQLITE_API SQLITE_DEPRECATED int sqlite3_expired(sqlite3_stmt*);
SQLITE_API SQLITE_DEPRECATED int sqlite3_transfer_bindings(sqlite3_stmt*, sqlite3_stmt*);
SQLITE_API SQLITE_DEPRECATED int sqlite3_global_recover(void);
SQLITE_API SQLITE_DEPRECATED void sqlite3_thread_cleanup(void);
-SQLITE_API SQLITE_DEPRECATED int sqlite3_memory_alarm(void(*)(void*,sqlite3_int64,int),void*,sqlite3_int64);
+SQLITE_API SQLITE_DEPRECATED int sqlite3_memory_alarm(void(*)(void*,sqlite3_int64,int),
+ void*,sqlite3_int64);
#endif
/*
@@ -3819,14 +4079,17 @@ SQLITE_API int sqlite3_value_numeric_type(sqlite3_value*);
** In those cases, sqlite3_aggregate_context() might be called for the
** first time from within xFinal().)^
**
-** ^The sqlite3_aggregate_context(C,N) routine returns a NULL pointer if N is
-** less than or equal to zero or if a memory allocate error occurs.
+** ^The sqlite3_aggregate_context(C,N) routine returns a NULL pointer
+** when first called if N is less than or equal to zero or if a memory
+** allocate error occurs.
**
** ^(The amount of space allocated by sqlite3_aggregate_context(C,N) is
** determined by the N parameter on first successful call. Changing the
** value of N in subsequent call to sqlite3_aggregate_context() within
** the same aggregate function instance will not resize the memory
-** allocation.)^
+** allocation.)^ Within the xFinal callback, it is customary to set
+** N=0 in calls to sqlite3_aggregate_context(C,N) so that no
+** pointless memory allocations occur.
**
** ^SQLite automatically frees the memory allocated by
** sqlite3_aggregate_context() when the aggregate query concludes.
@@ -3977,11 +4240,11 @@ typedef void (*sqlite3_destructor_type)(void*);
** the error code is SQLITE_ERROR. ^A subsequent call to sqlite3_result_error()
** or sqlite3_result_error16() resets the error code to SQLITE_ERROR.
**
-** ^The sqlite3_result_toobig() interface causes SQLite to throw an error
-** indicating that a string or BLOB is too long to represent.
+** ^The sqlite3_result_error_toobig() interface causes SQLite to throw an
+** error indicating that a string or BLOB is too long to represent.
**
-** ^The sqlite3_result_nomem() interface causes SQLite to throw an error
-** indicating that a memory allocation failed.
+** ^The sqlite3_result_error_nomem() interface causes SQLite to throw an
+** error indicating that a memory allocation failed.
**
** ^The sqlite3_result_int() interface sets the return value
** of the application-defined function to be the 32-bit signed integer
@@ -4006,7 +4269,12 @@ typedef void (*sqlite3_destructor_type)(void*);
** ^If the 3rd parameter to the sqlite3_result_text* interfaces
** is non-negative, then as many bytes (not characters) of the text
** pointed to by the 2nd parameter are taken as the application-defined
-** function result.
+** function result. If the 3rd parameter is non-negative, then it
+** must be the byte offset into the string where the NUL terminator would
+** appear if the string where NUL terminated. If any NUL characters occur
+** in the string at a byte offset that is less than the value of the 3rd
+** parameter, then the resulting string will contain embedded NULs and the
+** result of expressions operating on strings with embedded NULs is undefined.
** ^If the 4th parameter to the sqlite3_result_text* interfaces
** or sqlite3_result_blob is a non-NULL pointer, then SQLite calls that
** function as the destructor on the text or BLOB result when it has
@@ -4283,10 +4551,62 @@ SQLITE_API int sqlite3_sleep(int);
** Hence, if this variable is modified directly, either it should be
** made NULL or made to point to memory obtained from [sqlite3_malloc]
** or else the use of the [temp_store_directory pragma] should be avoided.
+**
+** <b>Note to Windows Runtime users:</b> The temporary directory must be set
+** prior to calling [sqlite3_open] or [sqlite3_open_v2]. Otherwise, various
+** features that require the use of temporary files may fail. Here is an
+** example of how to do this using C++ with the Windows Runtime:
+**
+** <blockquote><pre>
+** LPCWSTR zPath = Windows::Storage::ApplicationData::Current->
+** &nbsp; TemporaryFolder->Path->Data();
+** char zPathBuf&#91;MAX_PATH + 1&#93;;
+** memset(zPathBuf, 0, sizeof(zPathBuf));
+** WideCharToMultiByte(CP_UTF8, 0, zPath, -1, zPathBuf, sizeof(zPathBuf),
+** &nbsp; NULL, NULL);
+** sqlite3_temp_directory = sqlite3_mprintf("%s", zPathBuf);
+** </pre></blockquote>
*/
SQLITE_API SQLITE_EXTERN char *sqlite3_temp_directory;
/*
+** CAPI3REF: Name Of The Folder Holding Database Files
+**
+** ^(If this global variable is made to point to a string which is
+** the name of a folder (a.k.a. directory), then all database files
+** specified with a relative pathname and created or accessed by
+** SQLite when using a built-in windows [sqlite3_vfs | VFS] will be assumed
+** to be relative to that directory.)^ ^If this variable is a NULL
+** pointer, then SQLite assumes that all database files specified
+** with a relative pathname are relative to the current directory
+** for the process. Only the windows VFS makes use of this global
+** variable; it is ignored by the unix VFS.
+**
+** Changing the value of this variable while a database connection is
+** open can result in a corrupt database.
+**
+** It is not safe to read or modify this variable in more than one
+** thread at a time. It is not safe to read or modify this variable
+** if a [database connection] is being used at the same time in a separate
+** thread.
+** It is intended that this variable be set once
+** as part of process initialization and before any SQLite interface
+** routines have been called and that this variable remain unchanged
+** thereafter.
+**
+** ^The [data_store_directory pragma] may modify this variable and cause
+** it to point to memory obtained from [sqlite3_malloc]. ^Furthermore,
+** the [data_store_directory pragma] always assumes that any string
+** that this variable points to is held in memory obtained from
+** [sqlite3_malloc] and the pragma may attempt to free that memory
+** using [sqlite3_free].
+** Hence, if this variable is modified directly, either it should be
+** made NULL or made to point to memory obtained from [sqlite3_malloc]
+** or else the use of the [data_store_directory pragma] should be avoided.
+*/
+SQLITE_API SQLITE_EXTERN char *sqlite3_data_directory;
+
+/*
** CAPI3REF: Test For Auto-Commit Mode
** KEYWORDS: {autocommit mode}
**
@@ -4322,6 +4642,31 @@ SQLITE_API int sqlite3_get_autocommit(sqlite3*);
SQLITE_API sqlite3 *sqlite3_db_handle(sqlite3_stmt*);
/*
+** CAPI3REF: Return The Filename For A Database Connection
+**
+** ^The sqlite3_db_filename(D,N) interface returns a pointer to a filename
+** associated with database N of connection D. ^The main database file
+** has the name "main". If there is no attached database N on the database
+** connection D, or if database N is a temporary or in-memory database, then
+** a NULL pointer is returned.
+**
+** ^The filename returned by this function is the output of the
+** xFullPathname method of the [VFS]. ^In other words, the filename
+** will be an absolute pathname, even if the filename used
+** to open the database originally was a URI or relative pathname.
+*/
+SQLITE_API const char *sqlite3_db_filename(sqlite3 *db, const char *zDbName);
+
+/*
+** CAPI3REF: Determine if a database is read-only
+**
+** ^The sqlite3_db_readonly(D,N) interface returns 1 if the database N
+** of connection D is read-only, 0 if it is read/write, or -1 if N is not
+** the name of a database on connection D.
+*/
+SQLITE_API int sqlite3_db_readonly(sqlite3 *db, const char *zDbName);
+
+/*
** CAPI3REF: Find the next prepared statement
**
** ^This interface returns a pointer to the next [prepared statement] after
@@ -4356,13 +4701,15 @@ SQLITE_API sqlite3_stmt *sqlite3_next_stmt(sqlite3 *pDb, sqlite3_stmt *pStmt);
** on the same [database connection] D, or NULL for
** the first call for each function on D.
**
+** The commit and rollback hook callbacks are not reentrant.
** The callback implementation must not do anything that will modify
** the database connection that invoked the callback. Any actions
** to modify the database connection must be deferred until after the
** completion of the [sqlite3_step()] call that triggered the commit
** or rollback hook in the first place.
-** Note that [sqlite3_prepare_v2()] and [sqlite3_step()] both modify their
-** database connections for the meaning of "modify" in this paragraph.
+** Note that running any other SQL statements, including SELECT statements,
+** or merely calling [sqlite3_prepare_v2()] and [sqlite3_step()] will modify
+** the database connections for the meaning of "modify" in this paragraph.
**
** ^Registering a NULL function disables the callback.
**
@@ -4437,7 +4784,6 @@ SQLITE_API void *sqlite3_update_hook(
/*
** CAPI3REF: Enable Or Disable Shared Pager Cache
-** KEYWORDS: {shared cache}
**
** ^(This routine enables or disables the sharing of the database cache
** and schema data structures between [database connection | connections]
@@ -4460,6 +4806,9 @@ SQLITE_API void *sqlite3_update_hook(
** future releases of SQLite. Applications that care about shared
** cache setting should set it explicitly.
**
+** This interface is threadsafe on processors where writing a
+** 32-bit integer is atomic.
+**
** See Also: [SQLite Shared-Cache Mode]
*/
SQLITE_API int sqlite3_enable_shared_cache(int);
@@ -4475,10 +4824,25 @@ SQLITE_API int sqlite3_enable_shared_cache(int);
** which might be more or less than the amount requested.
** ^The sqlite3_release_memory() routine is a no-op returning zero
** if SQLite is not compiled with [SQLITE_ENABLE_MEMORY_MANAGEMENT].
+**
+** See also: [sqlite3_db_release_memory()]
*/
SQLITE_API int sqlite3_release_memory(int);
/*
+** CAPI3REF: Free Memory Used By A Database Connection
+**
+** ^The sqlite3_db_release_memory(D) interface attempts to free as much heap
+** memory as possible from database connection D. Unlike the
+** [sqlite3_release_memory()] interface, this interface is effect even
+** when then [SQLITE_ENABLE_MEMORY_MANAGEMENT] compile-time option is
+** omitted.
+**
+** See also: [sqlite3_release_memory()]
+*/
+SQLITE_API int sqlite3_db_release_memory(sqlite3*);
+
+/*
** CAPI3REF: Impose A Limit On Heap Size
**
** ^The sqlite3_soft_heap_limit64() interface sets and/or queries the
@@ -4492,7 +4856,8 @@ SQLITE_API int sqlite3_release_memory(int);
** is advisory only.
**
** ^The return value from sqlite3_soft_heap_limit64() is the size of
-** the soft heap limit prior to the call. ^If the argument N is negative
+** the soft heap limit prior to the call, or negative in the case of an
+** error. ^If the argument N is negative
** then no change is made to the soft heap limit. Hence, the current
** size of the soft heap limit can be determined by invoking
** sqlite3_soft_heap_limit64() with a negative argument.
@@ -4508,7 +4873,7 @@ SQLITE_API int sqlite3_release_memory(int);
** [sqlite3_config]([SQLITE_CONFIG_MEMSTATUS],...) start-time option and
** the [SQLITE_DEFAULT_MEMSTATUS] compile-time option.
** <li> An alternative page cache implementation is specified using
-** [sqlite3_config]([SQLITE_CONFIG_PCACHE],...).
+** [sqlite3_config]([SQLITE_CONFIG_PCACHE2],...).
** <li> The page cache allocates from its own memory pool supplied
** by [sqlite3_config]([SQLITE_CONFIG_PAGECACHE],...) rather than
** from the heap.
@@ -5249,17 +5614,16 @@ SQLITE_API int sqlite3_vfs_unregister(sqlite3_vfs*);
** implementations are available in the SQLite core:
**
** <ul>
-** <li> SQLITE_MUTEX_OS2
-** <li> SQLITE_MUTEX_PTHREAD
+** <li> SQLITE_MUTEX_PTHREADS
** <li> SQLITE_MUTEX_W32
** <li> SQLITE_MUTEX_NOOP
** </ul>)^
**
** ^The SQLITE_MUTEX_NOOP implementation is a set of routines
** that does no real locking and is appropriate for use in
-** a single-threaded application. ^The SQLITE_MUTEX_OS2,
-** SQLITE_MUTEX_PTHREAD, and SQLITE_MUTEX_W32 implementations
-** are appropriate for use on OS/2, Unix, and Windows.
+** a single-threaded application. ^The SQLITE_MUTEX_PTHREADS and
+** SQLITE_MUTEX_W32 implementations are appropriate for use on Unix
+** and Windows.
**
** ^(If SQLite is compiled with the SQLITE_MUTEX_APPDEF preprocessor
** macro defined (with "-DSQLITE_MUTEX_APPDEF=1"), then no mutex
@@ -5448,7 +5812,7 @@ struct sqlite3_mutex_methods {
** ^These routines should return true if the mutex in their argument
** is held or not held, respectively, by the calling thread.
**
-** ^The implementation is not required to provided versions of these
+** ^The implementation is not required to provide versions of these
** routines that actually work. If the implementation does not provide working
** versions of these routines, it should at least provide stubs that always
** return true so that one does not get spurious assertion failures.
@@ -5576,9 +5940,9 @@ SQLITE_API int sqlite3_test_control(int op, ...);
#define SQLITE_TESTCTRL_RESERVE 14
#define SQLITE_TESTCTRL_OPTIMIZATIONS 15
#define SQLITE_TESTCTRL_ISKEYWORD 16
-#define SQLITE_TESTCTRL_PGHDRSZ 17
-#define SQLITE_TESTCTRL_SCRATCHMALLOC 18
-#define SQLITE_TESTCTRL_LOCALTIME_FAULT 19
+#define SQLITE_TESTCTRL_SCRATCHMALLOC 17
+#define SQLITE_TESTCTRL_LOCALTIME_FAULT 18
+#define SQLITE_TESTCTRL_EXPLAIN_STMT 19
#define SQLITE_TESTCTRL_LAST 19
/*
@@ -5789,6 +6153,29 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r
** the database connection.)^
** ^The highwater mark associated with SQLITE_DBSTATUS_STMT_USED is always 0.
** </dd>
+**
+** [[SQLITE_DBSTATUS_CACHE_HIT]] ^(<dt>SQLITE_DBSTATUS_CACHE_HIT</dt>
+** <dd>This parameter returns the number of pager cache hits that have
+** occurred.)^ ^The highwater mark associated with SQLITE_DBSTATUS_CACHE_HIT
+** is always 0.
+** </dd>
+**
+** [[SQLITE_DBSTATUS_CACHE_MISS]] ^(<dt>SQLITE_DBSTATUS_CACHE_MISS</dt>
+** <dd>This parameter returns the number of pager cache misses that have
+** occurred.)^ ^The highwater mark associated with SQLITE_DBSTATUS_CACHE_MISS
+** is always 0.
+** </dd>
+**
+** [[SQLITE_DBSTATUS_CACHE_WRITE]] ^(<dt>SQLITE_DBSTATUS_CACHE_WRITE</dt>
+** <dd>This parameter returns the number of dirty cache entries that have
+** been written to disk. Specifically, the number of pages written to the
+** wal file in wal mode databases, or the number of pages written to the
+** database file in rollback mode databases. Any pages written as part of
+** transaction rollback or database recovery operations are not included.
+** If an IO or other error occurs while writing a page to disk, the effect
+** on subsequent SQLITE_DBSTATUS_CACHE_WRITE requests is undefined.)^ ^The
+** highwater mark associated with SQLITE_DBSTATUS_CACHE_WRITE is always 0.
+** </dd>
** </dl>
*/
#define SQLITE_DBSTATUS_LOOKASIDE_USED 0
@@ -5798,7 +6185,10 @@ SQLITE_API int sqlite3_db_status(sqlite3*, int op, int *pCur, int *pHiwtr, int r
#define SQLITE_DBSTATUS_LOOKASIDE_HIT 4
#define SQLITE_DBSTATUS_LOOKASIDE_MISS_SIZE 5
#define SQLITE_DBSTATUS_LOOKASIDE_MISS_FULL 6
-#define SQLITE_DBSTATUS_MAX 6 /* Largest defined DBSTATUS */
+#define SQLITE_DBSTATUS_CACHE_HIT 7
+#define SQLITE_DBSTATUS_CACHE_MISS 8
+#define SQLITE_DBSTATUS_CACHE_WRITE 9
+#define SQLITE_DBSTATUS_MAX 9 /* Largest defined DBSTATUS */
/*
@@ -5852,7 +6242,6 @@ SQLITE_API int sqlite3_stmt_status(sqlite3_stmt*, int op,int resetFlg);
** A non-zero value in this counter may indicate an opportunity to
** improvement performance by adding permanent indices that do not
** need to be reinitialized each time the statement is run.</dd>
-**
** </dl>
*/
#define SQLITE_STMTSTATUS_FULLSCAN_STEP 1
@@ -5868,17 +6257,33 @@ SQLITE_API int sqlite3_stmt_status(sqlite3_stmt*, int op,int resetFlg);
** sqlite3_pcache object except by holding and passing pointers
** to the object.
**
-** See [sqlite3_pcache_methods] for additional information.
+** See [sqlite3_pcache_methods2] for additional information.
*/
typedef struct sqlite3_pcache sqlite3_pcache;
/*
+** CAPI3REF: Custom Page Cache Object
+**
+** The sqlite3_pcache_page object represents a single page in the
+** page cache. The page cache will allocate instances of this
+** object. Various methods of the page cache use pointers to instances
+** of this object as parameters or as their return value.
+**
+** See [sqlite3_pcache_methods2] for additional information.
+*/
+typedef struct sqlite3_pcache_page sqlite3_pcache_page;
+struct sqlite3_pcache_page {
+ void *pBuf; /* The content of the page */
+ void *pExtra; /* Extra information associated with the page */
+};
+
+/*
** CAPI3REF: Application Defined Page Cache.
** KEYWORDS: {page cache}
**
-** ^(The [sqlite3_config]([SQLITE_CONFIG_PCACHE], ...) interface can
+** ^(The [sqlite3_config]([SQLITE_CONFIG_PCACHE2], ...) interface can
** register an alternative page cache implementation by passing in an
-** instance of the sqlite3_pcache_methods structure.)^
+** instance of the sqlite3_pcache_methods2 structure.)^
** In many applications, most of the heap memory allocated by
** SQLite is used for the page cache.
** By implementing a
@@ -5892,7 +6297,7 @@ typedef struct sqlite3_pcache sqlite3_pcache;
** extreme measure that is only needed by the most demanding applications.
** The built-in page cache is recommended for most uses.
**
-** ^(The contents of the sqlite3_pcache_methods structure are copied to an
+** ^(The contents of the sqlite3_pcache_methods2 structure are copied to an
** internal buffer by SQLite within the call to [sqlite3_config]. Hence
** the application may discard the parameter after the call to
** [sqlite3_config()] returns.)^
@@ -5901,7 +6306,7 @@ typedef struct sqlite3_pcache sqlite3_pcache;
** ^(The xInit() method is called once for each effective
** call to [sqlite3_initialize()])^
** (usually only once during the lifetime of the process). ^(The xInit()
-** method is passed a copy of the sqlite3_pcache_methods.pArg value.)^
+** method is passed a copy of the sqlite3_pcache_methods2.pArg value.)^
** The intent of the xInit() method is to set up global data structures
** required by the custom page cache implementation.
** ^(If the xInit() method is NULL, then the
@@ -5928,17 +6333,15 @@ typedef struct sqlite3_pcache sqlite3_pcache;
** SQLite will typically create one cache instance for each open database file,
** though this is not guaranteed. ^The
** first parameter, szPage, is the size in bytes of the pages that must
-** be allocated by the cache. ^szPage will not be a power of two. ^szPage
-** will the page size of the database file that is to be cached plus an
-** increment (here called "R") of less than 250. SQLite will use the
-** extra R bytes on each page to store metadata about the underlying
-** database page on disk. The value of R depends
+** be allocated by the cache. ^szPage will always a power of two. ^The
+** second parameter szExtra is a number of bytes of extra storage
+** associated with each page cache entry. ^The szExtra parameter will
+** a number less than 250. SQLite will use the
+** extra szExtra bytes on each page to store metadata about the underlying
+** database page on disk. The value passed into szExtra depends
** on the SQLite version, the target platform, and how SQLite was compiled.
-** ^(R is constant for a particular build of SQLite. Except, there are two
-** distinct values of R when SQLite is compiled with the proprietary
-** ZIPVFS extension.)^ ^The second argument to
-** xCreate(), bPurgeable, is true if the cache being created will
-** be used to cache database pages of a file stored on disk, or
+** ^The third argument to xCreate(), bPurgeable, is true if the cache being
+** created will be used to cache database pages of a file stored on disk, or
** false if it is used for an in-memory database. The cache implementation
** does not have to do anything special based with the value of bPurgeable;
** it is purely advisory. ^On a cache where bPurgeable is false, SQLite will
@@ -5962,11 +6365,16 @@ typedef struct sqlite3_pcache sqlite3_pcache;
**
** [[the xFetch() page cache methods]]
** The xFetch() method locates a page in the cache and returns a pointer to
-** the page, or a NULL pointer.
-** A "page", in this context, means a buffer of szPage bytes aligned at an
-** 8-byte boundary. The page to be fetched is determined by the key. ^The
-** minimum key value is 1. After it has been retrieved using xFetch, the page
-** is considered to be "pinned".
+** an sqlite3_pcache_page object associated with that page, or a NULL pointer.
+** The pBuf element of the returned sqlite3_pcache_page object will be a
+** pointer to a buffer of szPage bytes used to store the content of a
+** single database page. The pExtra element of sqlite3_pcache_page will be
+** a pointer to the szExtra bytes of extra storage that SQLite has requested
+** for each entry in the page cache.
+**
+** The page to be fetched is determined by the key. ^The minimum key value
+** is 1. After it has been retrieved using xFetch, the page is considered
+** to be "pinned".
**
** If the requested page is already in the page cache, then the page cache
** implementation must return a pointer to the page buffer with its content
@@ -5975,7 +6383,7 @@ typedef struct sqlite3_pcache sqlite3_pcache;
** parameter to help it determined what action to take:
**
** <table border=1 width=85% align=center>
-** <tr><th> createFlag <th> Behaviour when page is not already in cache
+** <tr><th> createFlag <th> Behavior when page is not already in cache
** <tr><td> 0 <td> Do not allocate a new page. Return NULL.
** <tr><td> 1 <td> Allocate a new page if it easy and convenient to do so.
** Otherwise return NULL.
@@ -6019,8 +6427,37 @@ typedef struct sqlite3_pcache sqlite3_pcache;
** ^The xDestroy() method is used to delete a cache allocated by xCreate().
** All resources associated with the specified cache should be freed. ^After
** calling the xDestroy() method, SQLite considers the [sqlite3_pcache*]
-** handle invalid, and will not use it with any other sqlite3_pcache_methods
+** handle invalid, and will not use it with any other sqlite3_pcache_methods2
** functions.
+**
+** [[the xShrink() page cache method]]
+** ^SQLite invokes the xShrink() method when it wants the page cache to
+** free up as much of heap memory as possible. The page cache implementation
+** is not obligated to free any memory, but well-behaved implementations should
+** do their best.
+*/
+typedef struct sqlite3_pcache_methods2 sqlite3_pcache_methods2;
+struct sqlite3_pcache_methods2 {
+ int iVersion;
+ void *pArg;
+ int (*xInit)(void*);
+ void (*xShutdown)(void*);
+ sqlite3_pcache *(*xCreate)(int szPage, int szExtra, int bPurgeable);
+ void (*xCachesize)(sqlite3_pcache*, int nCachesize);
+ int (*xPagecount)(sqlite3_pcache*);
+ sqlite3_pcache_page *(*xFetch)(sqlite3_pcache*, unsigned key, int createFlag);
+ void (*xUnpin)(sqlite3_pcache*, sqlite3_pcache_page*, int discard);
+ void (*xRekey)(sqlite3_pcache*, sqlite3_pcache_page*,
+ unsigned oldKey, unsigned newKey);
+ void (*xTruncate)(sqlite3_pcache*, unsigned iLimit);
+ void (*xDestroy)(sqlite3_pcache*);
+ void (*xShrink)(sqlite3_pcache*);
+};
+
+/*
+** This is the obsolete pcache_methods object that has now been replaced
+** by sqlite3_pcache_methods2. This object is not used by SQLite. It is
+** retained in the header file for backwards compatibility only.
*/
typedef struct sqlite3_pcache_methods sqlite3_pcache_methods;
struct sqlite3_pcache_methods {
@@ -6037,6 +6474,7 @@ struct sqlite3_pcache_methods {
void (*xDestroy)(sqlite3_pcache*);
};
+
/*
** CAPI3REF: Online Backup Object
**
@@ -6366,11 +6804,12 @@ SQLITE_API int sqlite3_unlock_notify(
/*
** CAPI3REF: String Comparison
**
-** ^The [sqlite3_strnicmp()] API allows applications and extensions to
-** compare the contents of two buffers containing UTF-8 strings in a
-** case-independent fashion, using the same definition of case independence
-** that SQLite uses internally when comparing identifiers.
+** ^The [sqlite3_stricmp()] and [sqlite3_strnicmp()] APIs allow applications
+** and extensions to compare the contents of two buffers containing UTF-8
+** strings in a case-independent fashion, using the same definition of "case
+** independence" that SQLite uses internally when comparing identifiers.
*/
+SQLITE_API int sqlite3_stricmp(const char *, const char *);
SQLITE_API int sqlite3_strnicmp(const char *, const char *, int);
/*
@@ -6705,7 +7144,11 @@ typedef struct sqlite3_rtree_geometry sqlite3_rtree_geometry;
SQLITE_API int sqlite3_rtree_geometry_callback(
sqlite3 *db,
const char *zGeom,
- int (*xGeom)(sqlite3_rtree_geometry *, int nCoord, double *aCoord, int *pRes),
+#ifdef SQLITE_RTREE_INT_ONLY
+ int (*xGeom)(sqlite3_rtree_geometry*, int n, sqlite3_int64 *a, int *pRes),
+#else
+ int (*xGeom)(sqlite3_rtree_geometry*, int n, double *a, int *pRes),
+#endif
void *pContext
);
diff --git a/src/android/android.pro b/src/android/android.pro
new file mode 100644
index 0000000000..a5db78e32f
--- /dev/null
+++ b/src/android/android.pro
@@ -0,0 +1,2 @@
+TEMPLATE = subdirs
+SUBDIRS = jar java
diff --git a/src/android/jar/AndroidManifest.xml b/src/android/jar/AndroidManifest.xml
new file mode 100644
index 0000000000..ebc6fcfea7
--- /dev/null
+++ b/src/android/jar/AndroidManifest.xml
@@ -0,0 +1,4 @@
+<?xml version='1.0' encoding='utf-8'?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="1" android:versionName="1.0" package="org.qtproject.qt5.android">
+ <supports-screens android:largeScreens="true" android:normalScreens="true" android:anyDensity="true" android:smallScreens="true"/>
+</manifest>
diff --git a/src/android/jar/jar.pro b/src/android/jar/jar.pro
new file mode 100644
index 0000000000..1955f16142
--- /dev/null
+++ b/src/android/jar/jar.pro
@@ -0,0 +1,19 @@
+CONFIG += java
+TARGET = QtAndroid
+DESTDIR = $$[QT_INSTALL_PREFIX/get]/jar
+
+PATHPREFIX = $$PWD/src/org/qtproject/qt5/android/
+
+JAVACLASSPATH += $$PWD/src/
+JAVASOURCES += \
+ $$PATHPREFIX/QtActivityDelegate.java \
+ $$PATHPREFIX/QtEditText.java \
+ $$PATHPREFIX/QtInputConnection.java \
+ $$PATHPREFIX/QtLayout.java \
+ $$PATHPREFIX/QtNative.java \
+ $$PATHPREFIX/QtNativeLibrariesDir.java \
+ $$PATHPREFIX/QtSurface.java
+
+# install
+target.path = $$[QT_INSTALL_PREFIX]/jar
+INSTALLS += target
diff --git a/src/android/jar/res/values/strings.xml b/src/android/jar/res/values/strings.xml
new file mode 100644
index 0000000000..1021b5478a
--- /dev/null
+++ b/src/android/jar/res/values/strings.xml
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+ <string name="app_name">QtJar</string>
+</resources>
diff --git a/src/android/jar/src/org/qtproject/qt5/android/QtActivityDelegate.java b/src/android/jar/src/org/qtproject/qt5/android/QtActivityDelegate.java
new file mode 100644
index 0000000000..dedfc9d417
--- /dev/null
+++ b/src/android/jar/src/org/qtproject/qt5/android/QtActivityDelegate.java
@@ -0,0 +1,806 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Android port of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+package org.qtproject.qt5.android;
+
+import java.io.File;
+import java.io.FileWriter;
+import java.io.IOException;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.Iterator;
+
+import android.app.Activity;
+import android.content.Context;
+import android.content.pm.PackageManager;
+import android.content.pm.PackageManager.NameNotFoundException;
+import android.content.res.Configuration;
+import android.graphics.Rect;
+import android.os.Build;
+import android.os.Bundle;
+import android.text.method.MetaKeyKeyListener;
+import android.util.DisplayMetrics;
+import android.util.Log;
+import android.view.ContextMenu;
+import android.view.ContextMenu.ContextMenuInfo;
+import android.view.KeyCharacterMap;
+import android.view.KeyEvent;
+import android.view.Menu;
+import android.view.MenuItem;
+import android.view.View;
+import android.view.ViewGroup;
+import android.view.WindowManager;
+import android.view.inputmethod.InputMethodManager;
+
+public class QtActivityDelegate
+{
+ private Activity m_activity = null;
+ private Method m_super_dispatchKeyEvent = null;
+ private Method m_super_onRestoreInstanceState = null;
+ private Method m_super_onRetainNonConfigurationInstance = null;
+ private Method m_super_onSaveInstanceState = null;
+ private Method m_super_onKeyDown = null;
+ private Method m_super_onKeyUp = null;
+ private Method m_super_onConfigurationChanged = null;
+
+ private static final String NATIVE_LIBRARIES_KEY = "native.libraries";
+ private static final String BUNDLED_LIBRARIES_KEY = "bundled.libraries";
+ private static final String MAIN_LIBRARY_KEY = "main.library";
+ private static final String ENVIRONMENT_VARIABLES_KEY = "environment.variables";
+ private static final String APPLICATION_PARAMETERS_KEY = "application.parameters";
+ private static final String STATIC_INIT_CLASSES_KEY = "static.init.classes";
+ private static final String NECESSITAS_API_LEVEL_KEY = "necessitas.api.level";
+
+ private static String m_environmentVariables = null;
+ private static String m_applicationParameters = null;
+
+ private int m_currentOrientation = Configuration.ORIENTATION_UNDEFINED;
+
+ private String m_mainLib;
+ private long m_metaState;
+ private int m_lastChar = 0;
+ private boolean m_fullScreen = false;
+ private boolean m_started = false;
+ private QtSurface m_surface = null;
+ private QtLayout m_layout = null;
+ private QtEditText m_editText = null;
+ private InputMethodManager m_imm = null;
+ private boolean m_quitApp = true;
+ private Process m_debuggerProcess = null; // debugger process
+
+ public boolean m_keyboardIsVisible = false;
+ public boolean m_keyboardIsHiding = false;
+
+ public QtLayout getQtLayout()
+ {
+ return m_layout;
+ }
+
+ public QtSurface getQtSurface()
+ {
+ return m_surface;
+ }
+
+ public void redrawWindow(int left, int top, int right, int bottom)
+ {
+ m_surface.drawBitmap(new Rect(left, top, right, bottom));
+ }
+
+ public void setFullScreen(boolean enterFullScreen)
+ {
+ if (m_fullScreen == enterFullScreen)
+ return;
+
+ if (m_fullScreen = enterFullScreen) {
+ m_activity.getWindow().addFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
+ m_activity.getWindow().clearFlags(WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN);
+ } else {
+ m_activity.getWindow().addFlags(WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN);
+ m_activity.getWindow().clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
+ }
+ }
+
+ // case status
+ private final int ImhNoAutoUppercase = 0x2;
+ private final int ImhPreferUppercase = 0x8;
+ @SuppressWarnings("unused")
+ private final int ImhPreferLowercase = 0x10;
+ private final int ImhUppercaseOnly = 0x40000;
+ private final int ImhLowercaseOnly = 0x80000;
+
+ // options
+ private final int ImhNoPredictiveText = 0x20;
+
+ // layout
+ private final int ImhHiddenText = 0x1;
+ private final int ImhPreferNumbers = 0x4;
+ private final int ImhMultiLine = 0x400;
+ private final int ImhDigitsOnly = 0x10000;
+ private final int ImhFormattedNumbersOnly = 0x20000;
+ private final int ImhDialableCharactersOnly = 0x100000;
+ private final int ImhEmailCharactersOnly = 0x200000;
+ private final int ImhUrlCharactersOnly = 0x400000;
+
+ public void resetSoftwareKeyboard()
+ {
+ if (m_imm == null)
+ return;
+ m_editText.postDelayed(new Runnable() {
+ @Override
+ public void run() {
+ m_imm.restartInput(m_editText);
+ }
+ }, 5);
+ }
+
+ public void showSoftwareKeyboard(int x, int y, int width, int height, int inputHints)
+ {
+ if (m_imm == null)
+ return;
+ if (height > m_surface.getHeight()*2/3)
+ m_activity.getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_UNCHANGED | WindowManager.LayoutParams.SOFT_INPUT_ADJUST_RESIZE);
+ else
+ m_activity.getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_UNCHANGED | WindowManager.LayoutParams.SOFT_INPUT_ADJUST_PAN);
+
+ int initialCapsMode = 0;
+ int imeOptions = android.view.inputmethod.EditorInfo.IME_ACTION_DONE;
+ int inputType = android.text.InputType.TYPE_CLASS_TEXT;
+
+ if ((inputHints & ImhMultiLine) != 0) {
+ inputType = android.text.InputType.TYPE_CLASS_TEXT | android.text.InputType.TYPE_TEXT_FLAG_MULTI_LINE;
+ imeOptions = android.view.inputmethod.EditorInfo.IME_FLAG_NO_ENTER_ACTION;
+ }
+
+ if (((inputHints & ImhNoAutoUppercase) != 0 || (inputHints & ImhPreferUppercase) != 0)
+ && (inputHints & ImhLowercaseOnly) == 0) {
+ initialCapsMode = android.text.TextUtils.CAP_MODE_SENTENCES;
+ }
+
+ if ((inputHints & ImhUppercaseOnly) != 0)
+ initialCapsMode = android.text.TextUtils.CAP_MODE_CHARACTERS;
+
+ if ((inputHints & ImhHiddenText) != 0)
+ inputType = android.text.InputType.TYPE_TEXT_VARIATION_PASSWORD;
+
+ if ((inputHints & ImhPreferNumbers) != 0)
+ inputType = android.text.InputType.TYPE_CLASS_NUMBER;
+
+ if ((inputHints & ImhDigitsOnly) != 0)
+ inputType = android.text.InputType.TYPE_CLASS_NUMBER;
+
+ if ((inputHints & ImhFormattedNumbersOnly) != 0) {
+ inputType = android.text.InputType.TYPE_CLASS_NUMBER
+ | android.text.InputType.TYPE_NUMBER_FLAG_DECIMAL
+ | android.text.InputType.TYPE_NUMBER_FLAG_SIGNED;
+ }
+
+ if ((inputHints & ImhDialableCharactersOnly) != 0)
+ inputType = android.text.InputType.TYPE_CLASS_PHONE;
+
+ if ((inputHints & ImhEmailCharactersOnly) != 0)
+ inputType = android.text.InputType.TYPE_TEXT_VARIATION_EMAIL_ADDRESS;
+
+ if ((inputHints & ImhUrlCharactersOnly) != 0) {
+ inputType = android.text.InputType.TYPE_TEXT_VARIATION_URI;
+ imeOptions = android.view.inputmethod.EditorInfo.IME_ACTION_GO;
+ }
+
+ if ((inputHints & ImhNoPredictiveText) != 0) {
+ //android.text.InputType.TYPE_TEXT_FLAG_NO_SUGGESTIONS | android.text.InputType.TYPE_CLASS_TEXT;
+ inputType = android.text.InputType.TYPE_CLASS_TEXT | android.text.InputType.TYPE_TEXT_VARIATION_VISIBLE_PASSWORD;
+ }
+
+ m_editText.setInitialCapsMode(initialCapsMode);
+ m_editText.setImeOptions(imeOptions);
+ m_editText.setInputType(inputType);
+
+ m_layout.removeView(m_editText);
+ m_layout.addView(m_editText, new QtLayout.LayoutParams(width, height, x, y));
+ m_editText.bringToFront();
+ m_editText.requestFocus();
+ m_editText.postDelayed(new Runnable() {
+ @Override
+ public void run() {
+ m_imm.showSoftInput(m_editText, 0);
+ m_keyboardIsVisible = true;
+ m_keyboardIsHiding = false;
+ m_editText.postDelayed(new Runnable() {
+ @Override
+ public void run() {
+ m_imm.restartInput(m_editText);
+ }
+ }, 25);
+ }
+ }, 15);
+ }
+
+ public void hideSoftwareKeyboard()
+ {
+ if (m_imm == null)
+ return;
+ m_imm.hideSoftInputFromWindow(m_editText.getWindowToken(), 0);
+ m_keyboardIsVisible = false;
+ m_keyboardIsHiding = false;
+ }
+
+ public boolean isSoftwareKeyboardVisible()
+ {
+ return m_keyboardIsVisible;
+ }
+
+ String getAppIconSize(Activity a)
+ {
+ int size = a.getResources().getDimensionPixelSize(android.R.dimen.app_icon_size);
+ if (size < 36 || size > 512) { // check size sanity
+ DisplayMetrics metrics = new DisplayMetrics();
+ a.getWindowManager().getDefaultDisplay().getMetrics(metrics);
+ size = metrics.densityDpi/10*3;
+ if (size < 36)
+ size = 36;
+
+ if (size > 512)
+ size = 512;
+ }
+ return "\tQT_ANDROID_APP_ICON_SIZE=" + size;
+ }
+
+ public void updateSelection(int selStart, int selEnd, int candidatesStart, int candidatesEnd)
+ {
+ if (m_imm == null)
+ return;
+
+ m_imm.updateSelection(m_editText, selStart, selEnd, candidatesStart, candidatesEnd);
+ }
+
+ public boolean loadApplication(Activity activity, ClassLoader classLoader, Bundle loaderParams)
+ {
+ /// check parameters integrity
+ if (!loaderParams.containsKey(NATIVE_LIBRARIES_KEY)
+ || !loaderParams.containsKey(BUNDLED_LIBRARIES_KEY)
+ || !loaderParams.containsKey(ENVIRONMENT_VARIABLES_KEY)) {
+ return false;
+ }
+
+ m_activity = activity;
+ QtNative.setActivity(m_activity, this);
+ QtNative.setClassLoader(classLoader);
+ if (loaderParams.containsKey(STATIC_INIT_CLASSES_KEY)) {
+ for (String className: loaderParams.getStringArray(STATIC_INIT_CLASSES_KEY)) {
+ if (className.length() == 0)
+ continue;
+
+ try {
+ @SuppressWarnings("rawtypes")
+ Class initClass = classLoader.loadClass(className);
+ Object staticInitDataObject = initClass.newInstance(); // create an instance
+ Method m = initClass.getMethod("setActivity", Activity.class, Object.class);
+ m.invoke(staticInitDataObject, m_activity, this);
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+ }
+ }
+ QtNative.loadQtLibraries(loaderParams.getStringArrayList(NATIVE_LIBRARIES_KEY));
+ ArrayList<String> libraries = loaderParams.getStringArrayList(BUNDLED_LIBRARIES_KEY);
+ QtNative.loadBundledLibraries(libraries, QtNativeLibrariesDir.nativeLibrariesDir(m_activity));
+ m_mainLib = loaderParams.getString(MAIN_LIBRARY_KEY);
+ // older apps provide the main library as the last bundled library; look for this if the main library isn't provided
+ if (null == m_mainLib && libraries.size() > 0)
+ m_mainLib = libraries.get(libraries.size() - 1);
+
+ try {
+ m_super_dispatchKeyEvent = m_activity.getClass().getMethod("super_dispatchKeyEvent", KeyEvent.class);
+ m_super_onRestoreInstanceState = m_activity.getClass().getMethod("super_onRestoreInstanceState", Bundle.class);
+ m_super_onRetainNonConfigurationInstance = m_activity.getClass().getMethod("super_onRetainNonConfigurationInstance");
+ m_super_onSaveInstanceState = m_activity.getClass().getMethod("super_onSaveInstanceState", Bundle.class);
+ m_super_onKeyDown = m_activity.getClass().getMethod("super_onKeyDown", Integer.TYPE, KeyEvent.class);
+ m_super_onKeyUp = m_activity.getClass().getMethod("super_onKeyUp", Integer.TYPE, KeyEvent.class);
+ m_super_onConfigurationChanged = m_activity.getClass().getMethod("super_onConfigurationChanged", Configuration.class);
+ } catch (Exception e) {
+ e.printStackTrace();
+ return false;
+ }
+
+ int necessitasApiLevel = 1;
+ if (loaderParams.containsKey(NECESSITAS_API_LEVEL_KEY))
+ necessitasApiLevel = loaderParams.getInt(NECESSITAS_API_LEVEL_KEY);
+
+ m_environmentVariables = loaderParams.getString(ENVIRONMENT_VARIABLES_KEY);
+ String additionalEnvironmentVariables = "QT_ANDROID_FONTS_MONOSPACE=Droid Sans Mono;Droid Sans;Droid Sans Fallback"
+ + "\tNECESSITAS_API_LEVEL=" + necessitasApiLevel
+ + "\tHOME=" + m_activity.getFilesDir().getAbsolutePath()
+ + "\tTMPDIR=" + m_activity.getFilesDir().getAbsolutePath();
+ if (android.os.Build.VERSION.SDK_INT < 14)
+ additionalEnvironmentVariables += "\tQT_ANDROID_FONTS=Droid Sans;Droid Sans Fallback";
+ else
+ additionalEnvironmentVariables += "\tQT_ANDROID_FONTS=Roboto;Droid Sans;Droid Sans Fallback";
+
+ additionalEnvironmentVariables += getAppIconSize(activity);
+
+ if (m_environmentVariables != null && m_environmentVariables.length() > 0)
+ m_environmentVariables = additionalEnvironmentVariables + "\t" + m_environmentVariables;
+ else
+ m_environmentVariables = additionalEnvironmentVariables;
+
+ if (loaderParams.containsKey(APPLICATION_PARAMETERS_KEY))
+ m_applicationParameters = loaderParams.getString(APPLICATION_PARAMETERS_KEY);
+ else
+ m_applicationParameters = "";
+
+ return true;
+ }
+
+ public void debugLog(String msg)
+ {
+ Log.i(QtNative.QtTAG, "DEBUGGER: " + msg);
+ }
+
+ public boolean startApplication()
+ {
+ // start application
+ try {
+ // FIXME turn on debuggable check
+ // if the applications is debuggable and it has a native debug request
+ Bundle extras = m_activity.getIntent().getExtras();
+ if ( /*(ai.flags&ApplicationInfo.FLAG_DEBUGGABLE) != 0
+ &&*/ extras != null
+ && extras.containsKey("native_debug")
+ && extras.getString("native_debug").equals("true")) {
+ try {
+ String packagePath =
+ m_activity.getPackageManager().getApplicationInfo(m_activity.getPackageName(),
+ PackageManager.GET_CONFIGURATIONS).dataDir + "/";
+ String gdbserverPath =
+ extras.containsKey("gdbserver_path")
+ ? extras.getString("gdbserver_path")
+ : packagePath+"lib/gdbserver ";
+
+ String socket =
+ extras.containsKey("gdbserver_socket")
+ ? extras.getString("gdbserver_socket")
+ : "+debug-socket";
+
+ // start debugger
+ m_debuggerProcess = Runtime.getRuntime().exec(gdbserverPath
+ + socket
+ + " --attach "
+ + android.os.Process.myPid(),
+ null,
+ new File(packagePath));
+ } catch (IOException ioe) {
+ Log.e(QtNative.QtTAG,"Can't start debugger" + ioe.getMessage());
+ } catch (SecurityException se) {
+ Log.e(QtNative.QtTAG,"Can't start debugger" + se.getMessage());
+ } catch (NameNotFoundException e) {
+ Log.e(QtNative.QtTAG,"Can't start debugger" + e.getMessage());
+ }
+ }
+
+
+ if ( /*(ai.flags&ApplicationInfo.FLAG_DEBUGGABLE) != 0
+ &&*/ extras != null
+ && extras.containsKey("debug_ping")
+ && extras.getString("debug_ping").equals("true")) {
+ try {
+ debugLog("extra parameters: " + extras);
+ String packageName = m_activity.getPackageName();
+ String pingFile = extras.getString("ping_file");
+ String pongFile = extras.getString("pong_file");
+ String gdbserverSocket = extras.getString("gdbserver_socket");
+ String gdbserverCommand = extras.getString("gdbserver_command");
+ boolean usePing = pingFile != null;
+ boolean usePong = pongFile != null;
+ boolean useSocket = gdbserverSocket != null;
+ int napTime = 200; // milliseconds between file accesses
+ int timeOut = 30000; // ms until we give up on ping and pong
+ int maxAttempts = timeOut / napTime;
+
+ if (usePing) {
+ debugLog("removing ping file " + pingFile);
+ File ping = new File(pingFile);
+ if (ping.exists()) {
+ if (!ping.delete())
+ debugLog("ping file cannot be deleted");
+ }
+ }
+
+ if (usePong) {
+ debugLog("removing pong file " + pongFile);
+ File pong = new File(pongFile);
+ if (pong.exists()) {
+ if (!pong.delete())
+ debugLog("pong file cannot be deleted");
+ }
+ }
+
+ debugLog("starting " + gdbserverCommand);
+ m_debuggerProcess = Runtime.getRuntime().exec(gdbserverCommand);
+ debugLog("gdbserver started");
+
+ if (useSocket) {
+ int i;
+ for (i = 0; i < maxAttempts; ++i) {
+ debugLog("waiting for socket at " + gdbserverSocket + ", attempt " + i);
+ File file = new File(gdbserverSocket);
+ if (file.exists()) {
+ file.setReadable(true, false);
+ file.setWritable(true, false);
+ file.setExecutable(true, false);
+ break;
+ }
+ Thread.sleep(napTime);
+ }
+
+ if (i == maxAttempts) {
+ debugLog("time out when waiting for socket");
+ return false;
+ }
+
+ debugLog("socket ok");
+ } else {
+ debugLog("socket not used");
+ }
+
+ if (usePing) {
+ // Tell we are ready.
+ debugLog("writing ping at " + pingFile);
+ FileWriter writer = new FileWriter(pingFile);
+ writer.write("" + android.os.Process.myPid());
+ writer.close();
+ File file = new File(pingFile);
+ file.setReadable(true, false);
+ file.setWritable(true, false);
+ file.setExecutable(true, false);
+ debugLog("wrote ping");
+ } else {
+ debugLog("ping not requested");
+ }
+
+ // Wait until other side is ready.
+ if (usePong) {
+ int i;
+ for (i = 0; i < maxAttempts; ++i) {
+ debugLog("waiting for pong at " + pongFile + ", attempt " + i);
+ File file = new File(pongFile);
+ if (file.exists()) {
+ file.delete();
+ break;
+ }
+ debugLog("go to sleep");
+ Thread.sleep(napTime);
+ }
+
+ if (i == maxAttempts) {
+ debugLog("time out when waiting for pong file");
+ return false;
+ }
+
+ debugLog("got pong " + pongFile);
+ } else {
+ debugLog("pong not requested");
+ }
+
+ } catch (IOException ioe) {
+ Log.e(QtNative.QtTAG,"Can't start debugger" + ioe.getMessage());
+ } catch (SecurityException se) {
+ Log.e(QtNative.QtTAG,"Can't start debugger" + se.getMessage());
+ }
+ }
+
+ if (/*(ai.flags&ApplicationInfo.FLAG_DEBUGGABLE) != 0
+ &&*/ extras != null
+ && extras.containsKey("qml_debug")
+ && extras.getString("qml_debug").equals("true")) {
+ String qmljsdebugger;
+ if (extras.containsKey("qmljsdebugger")) {
+ qmljsdebugger = extras.getString("qmljsdebugger");
+ qmljsdebugger.replaceAll("\\s", ""); // remove whitespace for security
+ } else {
+ qmljsdebugger = "port:3768";
+ }
+ m_applicationParameters += "\t-qmljsdebugger=" + qmljsdebugger;
+ }
+
+ if (null == m_surface)
+ onCreate(null);
+ String nativeLibraryDir = QtNativeLibrariesDir.nativeLibrariesDir(m_activity);
+ m_surface.applicationStarted( QtNative.startApplication(m_applicationParameters,
+ m_environmentVariables,
+ m_mainLib,
+ nativeLibraryDir));
+ m_started = true;
+ return true;
+ } catch (Exception e) {
+ e.printStackTrace();
+ return false;
+ }
+ }
+
+ public void onTerminate()
+ {
+ QtNative.terminateQt();
+ }
+
+ public void onCreate(Bundle savedInstanceState)
+ {
+ m_quitApp = true;
+ if (null == savedInstanceState) {
+ DisplayMetrics metrics = new DisplayMetrics();
+ m_activity.getWindowManager().getDefaultDisplay().getMetrics(metrics);
+ QtNative.setApplicationDisplayMetrics(metrics.widthPixels, metrics.heightPixels,
+ metrics.widthPixels, metrics.heightPixels,
+ metrics.xdpi, metrics.ydpi, metrics.scaledDensity);
+ }
+ m_layout = new QtLayout(m_activity);
+ m_surface = new QtSurface(m_activity, 0);
+ m_editText = new QtEditText(m_activity);
+ m_imm = (InputMethodManager)m_activity.getSystemService(Context.INPUT_METHOD_SERVICE);
+ m_layout.addView(m_surface,0);
+ m_activity.setContentView(m_layout,
+ new ViewGroup.LayoutParams(ViewGroup.LayoutParams.FILL_PARENT,
+ ViewGroup.LayoutParams.FILL_PARENT));
+ m_layout.bringChildToFront(m_surface);
+ m_activity.registerForContextMenu(m_layout);
+
+ m_currentOrientation = m_activity.getResources().getConfiguration().orientation;
+ }
+
+ public void onConfigurationChanged(Configuration configuration)
+ {
+ try {
+ m_super_onConfigurationChanged.invoke(m_activity, configuration);
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+
+ if (configuration.orientation != m_currentOrientation
+ && m_currentOrientation != Configuration.ORIENTATION_UNDEFINED) {
+ QtNative.handleOrientationChanged(configuration.orientation);
+ }
+
+ m_currentOrientation = configuration.orientation;
+ }
+
+ public void onDestroy()
+ {
+ if (m_quitApp) {
+ if (m_debuggerProcess != null)
+ m_debuggerProcess.destroy();
+ System.exit(0);// FIXME remove it or find a better way
+ }
+ }
+
+ public void onRestoreInstanceState(Bundle savedInstanceState)
+ {
+ try {
+ m_super_onRestoreInstanceState.invoke(m_activity, savedInstanceState);
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+// setFullScreen(savedInstanceState.getBoolean("FullScreen"));
+ m_started = savedInstanceState.getBoolean("Started");
+ if (m_started)
+ m_surface.applicationStarted(true);
+ }
+
+ public void onResume()
+ {
+ // fire all lostActions
+ synchronized (QtNative.m_mainActivityMutex)
+ {
+ Iterator<Runnable> itr = QtNative.getLostActions().iterator();
+ while (itr.hasNext())
+ m_activity.runOnUiThread(itr.next());
+
+ if (m_started) {
+ QtNative.clearLostActions();
+ QtNative.updateWindow();
+ }
+ }
+ }
+
+ public Object onRetainNonConfigurationInstance()
+ {
+ try {
+ m_super_onRetainNonConfigurationInstance.invoke(m_activity);
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+ m_quitApp = false;
+ return true;
+ }
+
+ public void onSaveInstanceState(Bundle outState) {
+ try {
+ m_super_onSaveInstanceState.invoke(m_activity, outState);
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+ outState.putBoolean("FullScreen", m_fullScreen);
+ outState.putBoolean("Started", m_started);
+ }
+
+ public boolean onKeyDown(int keyCode, KeyEvent event)
+ {
+ if (!m_started)
+ return false;
+
+ if (keyCode == KeyEvent.KEYCODE_MENU) {
+ try {
+ return (Boolean)m_super_onKeyDown.invoke(m_activity, keyCode, event);
+ } catch (Exception e) {
+ e.printStackTrace();
+ return false;
+ }
+ }
+
+ m_metaState = MetaKeyKeyListener.handleKeyDown(m_metaState, keyCode, event);
+ int c = event.getUnicodeChar(MetaKeyKeyListener.getMetaState(m_metaState));
+ int lc = c;
+ m_metaState = MetaKeyKeyListener.adjustMetaAfterKeypress(m_metaState);
+
+ if ((c & KeyCharacterMap.COMBINING_ACCENT) != 0) {
+ c = c & KeyCharacterMap.COMBINING_ACCENT_MASK;
+ int composed = KeyEvent.getDeadChar(m_lastChar, c);
+ c = composed;
+ }
+
+ m_lastChar = lc;
+ if (keyCode != KeyEvent.KEYCODE_BACK)
+ QtNative.keyDown(keyCode, c, event.getMetaState());
+
+ return true;
+ }
+
+ public boolean onKeyUp(int keyCode, KeyEvent event)
+ {
+ if (!m_started)
+ return false;
+
+ if (keyCode == KeyEvent.KEYCODE_MENU) {
+ try {
+ return (Boolean)m_super_onKeyUp.invoke(m_activity, keyCode, event);
+ } catch (Exception e) {
+ e.printStackTrace();
+ return false;
+ }
+ }
+
+ if (keyCode == KeyEvent.KEYCODE_BACK && m_keyboardIsVisible)
+ {
+ if (!m_keyboardIsHiding)
+ hideSoftwareKeyboard();
+ return true;
+ }
+
+ m_metaState = MetaKeyKeyListener.handleKeyUp(m_metaState, keyCode, event);
+ QtNative.keyUp(keyCode, event.getUnicodeChar(), event.getMetaState());
+ return true;
+ }
+
+ public boolean dispatchKeyEvent(KeyEvent event)
+ {
+ if (m_started
+ && event.getAction() == KeyEvent.ACTION_MULTIPLE
+ && event.getCharacters() != null
+ && event.getCharacters().length() == 1
+ && event.getKeyCode() == 0) {
+ QtNative.keyDown(0, event.getCharacters().charAt(0), event.getMetaState());
+ QtNative.keyUp(0, event.getCharacters().charAt(0), event.getMetaState());
+ }
+
+ try {
+ return (Boolean) m_super_dispatchKeyEvent.invoke(m_activity, event);
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+ return false;
+ }
+
+ private boolean m_opionsMenuIsVisible = false;
+ public boolean onCreateOptionsMenu(Menu menu)
+ {
+ menu.clear();
+ return true;
+ }
+ public boolean onPrepareOptionsMenu(Menu menu)
+ {
+ m_opionsMenuIsVisible = true;
+ return QtNative.onPrepareOptionsMenu(menu);
+ }
+
+ public boolean onOptionsItemSelected(MenuItem item)
+ {
+ return QtNative.onOptionsItemSelected(item.getItemId(), item.isChecked());
+ }
+
+ public void onOptionsMenuClosed(Menu menu)
+ {
+ m_opionsMenuIsVisible = false;
+ QtNative.onOptionsMenuClosed(menu);
+ }
+
+ public void resetOptionsMenu()
+ {
+ if (m_opionsMenuIsVisible)
+ m_activity.closeOptionsMenu();
+ }
+ private boolean m_contextMenuVisible = false;
+ public void onCreateContextMenu(ContextMenu menu,
+ View v,
+ ContextMenuInfo menuInfo)
+ {
+ menu.clearHeader();
+ QtNative.onCreateContextMenu(menu);
+ m_contextMenuVisible = true;
+ }
+
+ public void onContextMenuClosed(Menu menu)
+ {
+ if (!m_contextMenuVisible) {
+ Log.e(QtNative.QtTAG, "invalid onContextMenuClosed call");
+ return;
+ }
+ m_contextMenuVisible = false;
+ QtNative.onContextMenuClosed(menu);
+ }
+
+ public boolean onContextItemSelected(MenuItem item)
+ {
+ return QtNative.onContextItemSelected(item.getItemId(), item.isChecked());
+ }
+
+ public void openContextMenu()
+ {
+ m_layout.postDelayed(new Runnable() {
+ @Override
+ public void run() {
+ m_activity.openContextMenu(m_layout);
+ }
+ }, 10);
+ }
+
+ public void closeContextMenu()
+ {
+ m_activity.closeContextMenu();
+ }
+}
diff --git a/src/android/jar/src/org/qtproject/qt5/android/QtEditText.java b/src/android/jar/src/org/qtproject/qt5/android/QtEditText.java
new file mode 100644
index 0000000000..b95e0c070c
--- /dev/null
+++ b/src/android/jar/src/org/qtproject/qt5/android/QtEditText.java
@@ -0,0 +1,97 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Android port of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+package org.qtproject.qt5.android;
+
+import android.content.Context;
+import android.text.InputType;
+import android.view.View;
+import android.view.inputmethod.EditorInfo;
+import android.view.inputmethod.InputConnection;
+
+public class QtEditText extends View
+{
+ QtInputConnection m_inputConnection;
+ int m_initialCapsMode = 0;
+ int m_imeOptions = 0;
+ int m_inputType = InputType.TYPE_CLASS_TEXT;
+
+ public void setImeOptions(int m_imeOptions)
+ {
+ this.m_imeOptions = m_imeOptions;
+ }
+
+ public void setInitialCapsMode(int m_initialCapsMode)
+ {
+ this.m_initialCapsMode = m_initialCapsMode;
+ }
+
+
+ public void setInputType(int m_inputType)
+ {
+ this.m_inputType = m_inputType;
+ }
+
+ public QtEditText(Context context)
+ {
+ super(context);
+ setFocusable(true);
+ setFocusableInTouchMode(true);
+ m_inputConnection = new QtInputConnection(this);
+ }
+
+ @Override
+ public InputConnection onCreateInputConnection(EditorInfo outAttrs)
+ {
+ outAttrs.inputType = m_inputType;
+ outAttrs.imeOptions = m_imeOptions;
+ outAttrs.initialCapsMode = m_initialCapsMode;
+ outAttrs.imeOptions |= EditorInfo.IME_FLAG_NO_EXTRACT_UI;
+ return m_inputConnection;
+ }
+// // DEBUG CODE
+// @Override
+// protected void onDraw(Canvas canvas) {
+// canvas.drawARGB(127, 255, 0, 255);
+// super.onDraw(canvas);
+// }
+}
diff --git a/src/android/jar/src/org/qtproject/qt5/android/QtInputConnection.java b/src/android/jar/src/org/qtproject/qt5/android/QtInputConnection.java
new file mode 100644
index 0000000000..3bcec030b5
--- /dev/null
+++ b/src/android/jar/src/org/qtproject/qt5/android/QtInputConnection.java
@@ -0,0 +1,244 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Android port of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+package org.qtproject.qt5.android;
+
+import android.content.Context;
+import android.os.Build;
+import android.view.View;
+import android.view.inputmethod.BaseInputConnection;
+import android.view.inputmethod.CompletionInfo;
+import android.view.inputmethod.ExtractedText;
+import android.view.inputmethod.ExtractedTextRequest;
+import android.view.inputmethod.InputMethodManager;
+
+class QtExtractedText
+{
+ public int partialEndOffset;
+ public int partialStartOffset;
+ public int selectionEnd;
+ public int selectionStart;
+ public int startOffset;
+ public String text;
+}
+
+class QtNativeInputConnection
+{
+ static native boolean commitText(String text, int newCursorPosition);
+ static native boolean commitCompletion(String text, int position);
+ static native boolean deleteSurroundingText(int leftLength, int rightLength);
+ static native boolean finishComposingText();
+ static native int getCursorCapsMode(int reqModes);
+ static native QtExtractedText getExtractedText(int hintMaxChars, int hintMaxLines, int flags);
+ static native String getSelectedText(int flags);
+ static native String getTextAfterCursor(int length, int flags);
+ static native String getTextBeforeCursor(int length, int flags);
+ static native boolean setComposingText(String text, int newCursorPosition);
+ static native boolean setSelection(int start, int end);
+ static native boolean selectAll();
+ static native boolean cut();
+ static native boolean copy();
+ static native boolean copyURL();
+ static native boolean paste();
+}
+
+public class QtInputConnection extends BaseInputConnection
+{
+ private static final int ID_SELECT_ALL = android.R.id.selectAll;
+ private static final int ID_CUT = android.R.id.cut;
+ private static final int ID_COPY = android.R.id.copy;
+ private static final int ID_PASTE = android.R.id.paste;
+ private static final int ID_COPY_URL = android.R.id.copyUrl;
+ private static final int ID_SWITCH_INPUT_METHOD = android.R.id.switchInputMethod;
+ private static final int ID_ADD_TO_DICTIONARY = android.R.id.addToDictionary;
+
+ View m_view;
+ boolean m_closing;
+ public QtInputConnection(View targetView)
+ {
+ super(targetView, true);
+ m_view = targetView;
+ m_closing = false;
+ }
+
+ @Override
+ public boolean beginBatchEdit()
+ {
+ m_closing = false;
+ return true;
+ }
+
+ @Override
+ public boolean endBatchEdit()
+ {
+ m_closing = false;
+ return true;
+ }
+
+ @Override
+ public boolean commitCompletion(CompletionInfo text)
+ {
+ m_closing = false;
+ return QtNativeInputConnection.commitCompletion(text.getText().toString(), text.getPosition());
+ }
+
+ @Override
+ public boolean commitText(CharSequence text, int newCursorPosition)
+ {
+ m_closing = false;
+ return QtNativeInputConnection.commitText(text.toString(), newCursorPosition);
+ }
+
+ @Override
+ public boolean deleteSurroundingText(int leftLength, int rightLength)
+ {
+ m_closing = false;
+ return QtNativeInputConnection.deleteSurroundingText(leftLength, rightLength);
+ }
+
+ @Override
+ public boolean finishComposingText()
+ {
+ if (m_closing) {
+ QtNative.activityDelegate().m_keyboardIsHiding = true;
+ m_view.postDelayed(new Runnable() {
+ @Override
+ public void run() {
+ if (QtNative.activityDelegate().m_keyboardIsHiding)
+ QtNative.activityDelegate().m_keyboardIsVisible=false;
+ }
+ }, 5000); // it seems finishComposingText comes musch faster than onKeyUp event,
+ // so we must delay hide notification
+ m_closing = false;
+ } else {
+ m_closing = true;
+ }
+ return QtNativeInputConnection.finishComposingText();
+ }
+
+ @Override
+ public int getCursorCapsMode(int reqModes)
+ {
+ return QtNativeInputConnection.getCursorCapsMode(reqModes);
+ }
+
+ @Override
+ public ExtractedText getExtractedText(ExtractedTextRequest request, int flags)
+ {
+ QtExtractedText qExtractedText = QtNativeInputConnection.getExtractedText(request.hintMaxChars,
+ request.hintMaxLines,
+ flags);
+ ExtractedText extractedText = new ExtractedText();
+ extractedText.partialEndOffset = qExtractedText.partialEndOffset;
+ extractedText.partialStartOffset = qExtractedText.partialStartOffset;
+ extractedText.selectionEnd = qExtractedText.selectionEnd;
+ extractedText.selectionStart = qExtractedText.selectionStart;
+ extractedText.startOffset = qExtractedText.startOffset;
+ extractedText.text = qExtractedText.text;
+ return extractedText;
+ }
+
+ public CharSequence getSelectedText(int flags)
+ {
+ return QtNativeInputConnection.getSelectedText(flags);
+ }
+
+ @Override
+ public CharSequence getTextAfterCursor(int length, int flags)
+ {
+ return QtNativeInputConnection.getTextAfterCursor(length, flags);
+ }
+
+ @Override
+ public CharSequence getTextBeforeCursor(int length, int flags)
+ {
+ return QtNativeInputConnection.getTextBeforeCursor(length, flags);
+ }
+
+ @Override
+ public boolean performContextMenuAction(int id)
+ {
+ switch (id) {
+ case ID_SELECT_ALL:
+ return QtNativeInputConnection.selectAll();
+ case ID_COPY:
+ return QtNativeInputConnection.copy();
+ case ID_COPY_URL:
+ return QtNativeInputConnection.copyURL();
+ case ID_CUT:
+ return QtNativeInputConnection.cut();
+ case ID_PASTE:
+ return QtNativeInputConnection.paste();
+
+ case ID_SWITCH_INPUT_METHOD:
+ InputMethodManager imm = (InputMethodManager)m_view.getContext().getSystemService(Context.INPUT_METHOD_SERVICE);
+ if (imm != null)
+ imm.showInputMethodPicker();
+
+ return true;
+
+ case ID_ADD_TO_DICTIONARY:
+// TODO
+// String word = m_editable.subSequence(0, m_editable.length()).toString();
+// if (word != null) {
+// Intent i = new Intent("com.android.settings.USER_DICTIONARY_INSERT");
+// i.putExtra("word", word);
+// i.setFlags(i.getFlags() | Intent.FLAG_ACTIVITY_NEW_TASK);
+// m_view.getContext().startActivity(i);
+// }
+ return true;
+ }
+ return super.performContextMenuAction(id);
+ }
+
+ @Override
+ public boolean setComposingText(CharSequence text, int newCursorPosition)
+ {
+ return QtNativeInputConnection.setComposingText(text.toString(), newCursorPosition);
+ }
+
+ @Override
+ public boolean setSelection(int start, int end)
+ {
+ return QtNativeInputConnection.setSelection(start, end);
+ }
+}
diff --git a/src/android/jar/src/org/qtproject/qt5/android/QtLayout.java b/src/android/jar/src/org/qtproject/qt5/android/QtLayout.java
new file mode 100644
index 0000000000..043dab5ce8
--- /dev/null
+++ b/src/android/jar/src/org/qtproject/qt5/android/QtLayout.java
@@ -0,0 +1,201 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Android port of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+package org.qtproject.qt5.android;
+
+import android.content.Context;
+import android.util.AttributeSet;
+import android.view.View;
+import android.view.ViewGroup;
+
+public class QtLayout extends ViewGroup
+{
+ public QtLayout(Context context)
+ {
+ super(context);
+ }
+
+ public QtLayout(Context context, AttributeSet attrs)
+ {
+ super(context, attrs);
+ }
+
+ public QtLayout(Context context, AttributeSet attrs, int defStyle)
+ {
+ super(context, attrs, defStyle);
+ }
+
+ @Override
+ protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec)
+ {
+ int count = getChildCount();
+
+ int maxHeight = 0;
+ int maxWidth = 0;
+
+ // Find out how big everyone wants to be
+ measureChildren(widthMeasureSpec, heightMeasureSpec);
+
+ // Find rightmost and bottom-most child
+ for (int i = 0; i < count; i++) {
+ View child = getChildAt(i);
+ if (child.getVisibility() != GONE) {
+ int childRight;
+ int childBottom;
+
+ QtLayout.LayoutParams lp
+ = (QtLayout.LayoutParams) child.getLayoutParams();
+
+ childRight = lp.x + child.getMeasuredWidth();
+ childBottom = lp.y + child.getMeasuredHeight();
+
+ maxWidth = Math.max(maxWidth, childRight);
+ maxHeight = Math.max(maxHeight, childBottom);
+ }
+ }
+
+ // Check against minimum height and width
+ maxHeight = Math.max(maxHeight, getSuggestedMinimumHeight());
+ maxWidth = Math.max(maxWidth, getSuggestedMinimumWidth());
+
+ setMeasuredDimension(resolveSize(maxWidth, widthMeasureSpec),
+ resolveSize(maxHeight, heightMeasureSpec));
+ }
+
+ /**
+ * Returns a set of layout parameters with a width of
+ * {@link android.view.ViewGroup.LayoutParams#WRAP_CONTENT},
+ * a height of {@link android.view.ViewGroup.LayoutParams#WRAP_CONTENT}
+ * and with the coordinates (0, 0).
+ */
+ @Override
+ protected ViewGroup.LayoutParams generateDefaultLayoutParams()
+ {
+ return new LayoutParams(android.view.ViewGroup.LayoutParams.WRAP_CONTENT,
+ android.view.ViewGroup.LayoutParams.WRAP_CONTENT,
+ 0,
+ 0);
+ }
+
+ @Override
+ protected void onLayout(boolean changed, int l, int t, int r, int b)
+ {
+ int count = getChildCount();
+
+ for (int i = 0; i < count; i++) {
+ View child = getChildAt(i);
+ if (child.getVisibility() != GONE) {
+ QtLayout.LayoutParams lp =
+ (QtLayout.LayoutParams) child.getLayoutParams();
+
+ int childLeft = lp.x;
+ int childTop = lp.y;
+ child.layout(childLeft, childTop,
+ childLeft + child.getMeasuredWidth(),
+ childTop + child.getMeasuredHeight());
+
+ }
+ }
+ }
+
+ // Override to allow type-checking of LayoutParams.
+ @Override
+ protected boolean checkLayoutParams(ViewGroup.LayoutParams p)
+ {
+ return p instanceof QtLayout.LayoutParams;
+ }
+
+ @Override
+ protected ViewGroup.LayoutParams generateLayoutParams(ViewGroup.LayoutParams p)
+ {
+ return new LayoutParams(p);
+ }
+
+ /**
+ * Per-child layout information associated with AbsoluteLayout.
+ * See
+ * {@link android.R.styleable#AbsoluteLayout_Layout Absolute Layout Attributes}
+ * for a list of all child view attributes that this class supports.
+ */
+ public static class LayoutParams extends ViewGroup.LayoutParams
+ {
+ /**
+ * The horizontal, or X, location of the child within the view group.
+ */
+ public int x;
+ /**
+ * The vertical, or Y, location of the child within the view group.
+ */
+ public int y;
+
+ /**
+ * Creates a new set of layout parameters with the specified width,
+ * height and location.
+ *
+ * @param width the width, either {@link #FILL_PARENT},
+ {@link #WRAP_CONTENT} or a fixed size in pixels
+ * @param height the height, either {@link #FILL_PARENT},
+ {@link #WRAP_CONTENT} or a fixed size in pixels
+ * @param x the X location of the child
+ * @param y the Y location of the child
+ */
+ public LayoutParams(int width, int height, int x, int y)
+ {
+ super(width, height);
+ this.x = x;
+ this.y = y;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ public LayoutParams(ViewGroup.LayoutParams source)
+ {
+ super(source);
+ }
+ }
+
+ public void bringChildFront(int child)
+ {
+ bringChildToFront(getChildAt(child));
+ }
+}
diff --git a/src/android/jar/src/org/qtproject/qt5/android/QtNative.java b/src/android/jar/src/org/qtproject/qt5/android/QtNative.java
new file mode 100644
index 0000000000..4586ae2002
--- /dev/null
+++ b/src/android/jar/src/org/qtproject/qt5/android/QtNative.java
@@ -0,0 +1,583 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Android port of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+package org.qtproject.qt5.android;
+
+import java.io.File;
+import java.util.ArrayList;
+import java.util.concurrent.Semaphore;
+
+import android.app.Activity;
+import android.content.Context;
+import android.content.Intent;
+import android.net.Uri;
+import android.os.Build;
+import android.text.ClipboardManager;
+import android.util.Log;
+import android.view.ContextMenu;
+import android.view.Menu;
+import android.view.MotionEvent;
+
+public class QtNative
+{
+ private static Activity m_activity = null;
+ private static QtActivityDelegate m_activityDelegate = null;
+ public static Object m_mainActivityMutex = new Object(); // mutex used to synchronize runnable operations
+
+ public static final String QtTAG = "Qt JAVA"; // string used for Log.x
+ private static ArrayList<Runnable> m_lostActions = new ArrayList<Runnable>(); // a list containing all actions which could not be performed (e.g. the main activity is destroyed, etc.)
+ private static boolean m_started = false;
+ private static int m_displayMetricsScreenWidthPixels = 0;
+ private static int m_displayMetricsScreenHeightPixels = 0;
+ private static int m_displayMetricsDesktopWidthPixels = 0;
+ private static int m_displayMetricsDesktopHeightPixels = 0;
+ private static double m_displayMetricsXDpi = .0;
+ private static double m_displayMetricsYDpi = .0;
+ private static double m_displayMetricsScaledDensity = 1.0;
+ private static int m_oldx, m_oldy;
+ private static final int m_moveThreshold = 0;
+ private static ClipboardManager m_clipboardManager = null;
+
+ private static ClassLoader m_classLoader = null;
+ public static ClassLoader classLoader()
+ {
+ return m_classLoader;
+ }
+
+ public static void setClassLoader(ClassLoader classLoader)
+ {
+ m_classLoader = classLoader;
+ }
+
+ public static Activity activity()
+ {
+ synchronized (m_mainActivityMutex) {
+ return m_activity;
+ }
+ }
+
+ public static QtActivityDelegate activityDelegate()
+ {
+ synchronized (m_mainActivityMutex) {
+ return m_activityDelegate;
+ }
+ }
+
+ public static void openURL(String url)
+ {
+ Uri uri = Uri.parse(url);
+ Intent intent = new Intent(Intent.ACTION_VIEW, uri);
+ activity().startActivity(intent);
+ }
+
+ // this method loads full path libs
+ public static void loadQtLibraries(ArrayList<String> libraries)
+ {
+ if (libraries == null)
+ return;
+
+ for (String libName : libraries) {
+ try {
+ File f = new File(libName);
+ if (f.exists())
+ System.load(libName);
+ } catch (SecurityException e) {
+ Log.i(QtTAG, "Can't load '" + libName + "'", e);
+ } catch (Exception e) {
+ Log.i(QtTAG, "Can't load '" + libName + "'", e);
+ }
+ }
+ }
+
+ // this method loads bundled libs by name.
+ public static void loadBundledLibraries(ArrayList<String> libraries, String nativeLibraryDir)
+ {
+ if (libraries == null)
+ return;
+
+ for (String libName : libraries) {
+ try {
+ File f = new File(nativeLibraryDir+"lib"+libName+".so");
+ if (f.exists())
+ System.load(f.getAbsolutePath());
+ else
+ Log.i(QtTAG, "Can't find '" + f.getAbsolutePath());
+ } catch (Exception e) {
+ Log.i(QtTAG, "Can't load '" + libName + "'", e);
+ }
+ }
+ }
+
+ public static void setActivity(Activity qtMainActivity, QtActivityDelegate qtActivityDelegate)
+ {
+ synchronized (m_mainActivityMutex) {
+ m_activity = qtMainActivity;
+ m_activityDelegate = qtActivityDelegate;
+ }
+ }
+
+ static public ArrayList<Runnable> getLostActions()
+ {
+ return m_lostActions;
+ }
+
+ static public void clearLostActions()
+ {
+ m_lostActions.clear();
+ }
+
+ private static boolean runAction(Runnable action)
+ {
+ synchronized (m_mainActivityMutex) {
+ if (m_activity == null)
+ m_lostActions.add(action);
+ else
+ m_activity.runOnUiThread(action);
+ return m_activity != null;
+ }
+ }
+
+ public static boolean startApplication(String params,
+ String environment,
+ String mainLibrary,
+ String nativeLibraryDir) throws Exception
+ {
+ File f = new File(nativeLibraryDir + "lib" + mainLibrary + ".so");
+ if (!f.exists())
+ throw new Exception("Can't find main library '" + mainLibrary + "'");
+
+ if (params == null)
+ params = "-platform\tandroid";
+
+ boolean res = false;
+ synchronized (m_mainActivityMutex) {
+ res = startQtAndroidPlugin();
+ setDisplayMetrics(m_displayMetricsScreenWidthPixels,
+ m_displayMetricsScreenHeightPixels,
+ m_displayMetricsDesktopWidthPixels,
+ m_displayMetricsDesktopHeightPixels,
+ m_displayMetricsXDpi,
+ m_displayMetricsYDpi,
+ m_displayMetricsScaledDensity);
+ if (params.length() > 0)
+ params = "\t" + params;
+ startQtApplication(f.getAbsolutePath() + "\t" + params, environment);
+ m_started = true;
+ }
+ return res;
+ }
+
+ public static void setApplicationDisplayMetrics(int screenWidthPixels,
+ int screenHeightPixels,
+ int desktopWidthPixels,
+ int desktopHeightPixels,
+ double XDpi,
+ double YDpi,
+ double scaledDensity)
+ {
+ /* Fix buggy dpi report */
+ if (XDpi < android.util.DisplayMetrics.DENSITY_LOW)
+ XDpi = android.util.DisplayMetrics.DENSITY_LOW;
+ if (YDpi < android.util.DisplayMetrics.DENSITY_LOW)
+ YDpi = android.util.DisplayMetrics.DENSITY_LOW;
+
+ synchronized (m_mainActivityMutex) {
+ if (m_started) {
+ setDisplayMetrics(screenWidthPixels,
+ screenHeightPixels,
+ desktopWidthPixels,
+ desktopHeightPixels,
+ XDpi,
+ YDpi,
+ scaledDensity);
+ } else {
+ m_displayMetricsScreenWidthPixels = screenWidthPixels;
+ m_displayMetricsScreenHeightPixels = screenHeightPixels;
+ m_displayMetricsDesktopWidthPixels = desktopWidthPixels;
+ m_displayMetricsDesktopHeightPixels = desktopHeightPixels;
+ m_displayMetricsXDpi = XDpi;
+ m_displayMetricsYDpi = YDpi;
+ m_displayMetricsScaledDensity = scaledDensity;
+ }
+ }
+ }
+
+ public static void pauseApplication()
+ {
+ synchronized (m_mainActivityMutex) {
+ if (m_started)
+ pauseQtApp();
+ }
+ }
+
+ public static void resumeApplication()
+ {
+ synchronized (m_mainActivityMutex) {
+ if (m_started) {
+ resumeQtApp();
+ updateWindow();
+ }
+ }
+ }
+
+ // application methods
+ public static native void startQtApplication(String params, String env);
+ public static native void startQtApp(String params, String env);
+ public static native void pauseQtApp();
+ public static native void resumeQtApp();
+ public static native boolean startQtAndroidPlugin();
+ public static native void quitQtAndroidPlugin();
+ public static native void terminateQt();
+ // application methods
+
+ private static void quitApp()
+ {
+ m_activity.finish();
+ }
+
+ private static void redrawSurface(final int left, final int top, final int right, final int bottom )
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_activityDelegate.redrawWindow(left, top, right, bottom);
+ }
+ });
+ }
+
+ //@ANDROID-9
+ static private int getAction(int index, MotionEvent event)
+ {
+ int action = event.getActionMasked();
+ if (action == MotionEvent.ACTION_MOVE) {
+ int hsz = event.getHistorySize();
+ if (hsz > 0) {
+ if (Math.abs(event.getX(index) - event.getHistoricalX(index, hsz-1)) > 1
+ || Math.abs(event.getY(index) - event.getHistoricalY(index, hsz-1)) > 1) {
+ return 1;
+ } else {
+ return 2;
+ }
+ }
+ return 1;
+ }
+ if (action == MotionEvent.ACTION_DOWN || action == MotionEvent.ACTION_POINTER_DOWN && index == event.getActionIndex()) {
+ return 0;
+ } else if (action == MotionEvent.ACTION_UP || action == MotionEvent.ACTION_POINTER_UP && index == event.getActionIndex()) {
+ return 3;
+ }
+ return 2;
+ }
+ //@ANDROID-9
+
+ static public void sendTouchEvent(MotionEvent event, int id)
+ {
+ //@ANDROID-5
+ touchBegin(id);
+ for (int i=0;i<event.getPointerCount();i++) {
+ touchAdd(id,
+ event.getPointerId(i),
+ getAction(i, event),
+ i == 0,
+ (int)event.getX(i),
+ (int)event.getY(i),
+ event.getSize(i),
+ event.getPressure(i));
+ }
+
+ switch (event.getAction()) {
+ case MotionEvent.ACTION_DOWN:
+ touchEnd(id,0);
+ break;
+
+ case MotionEvent.ACTION_UP:
+ touchEnd(id,2);
+ break;
+
+ default:
+ touchEnd(id,1);
+ }
+ //@ANDROID-5
+
+ switch (event.getAction()) {
+ case MotionEvent.ACTION_UP:
+ mouseUp(id,(int) event.getX(), (int) event.getY());
+ break;
+
+ case MotionEvent.ACTION_DOWN:
+ mouseDown(id,(int) event.getX(), (int) event.getY());
+ m_oldx = (int) event.getX();
+ m_oldy = (int) event.getY();
+ break;
+
+ case MotionEvent.ACTION_MOVE:
+ int dx = (int) (event.getX() - m_oldx);
+ int dy = (int) (event.getY() - m_oldy);
+ if (Math.abs(dx) > m_moveThreshold || Math.abs(dy) > m_moveThreshold) {
+ mouseMove(id, (int) event.getX(), (int) event.getY());
+ m_oldx = (int) event.getX();
+ m_oldy = (int) event.getY();
+ }
+ break;
+ }
+ }
+
+ static public void sendTrackballEvent(MotionEvent event, int id)
+ {
+ switch (event.getAction()) {
+ case MotionEvent.ACTION_UP:
+ mouseUp(id, (int) event.getX(), (int) event.getY());
+ break;
+
+ case MotionEvent.ACTION_DOWN:
+ mouseDown(id, (int) event.getX(), (int) event.getY());
+ m_oldx = (int) event.getX();
+ m_oldy = (int) event.getY();
+ break;
+
+ case MotionEvent.ACTION_MOVE:
+ int dx = (int) (event.getX() - m_oldx);
+ int dy = (int) (event.getY() - m_oldy);
+ if (Math.abs(dx) > 5 || Math.abs(dy) > 5) {
+ mouseMove(id, (int) event.getX(), (int) event.getY());
+ m_oldx = (int) event.getX();
+ m_oldy = (int) event.getY();
+ }
+ break;
+ }
+ }
+
+ private static void updateSelection(final int selStart,
+ final int selEnd,
+ final int candidatesStart,
+ final int candidatesEnd)
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_activityDelegate.updateSelection(selStart, selEnd, candidatesStart, candidatesEnd);
+ }
+ });
+ }
+
+ private static void showSoftwareKeyboard(final int x,
+ final int y,
+ final int width,
+ final int height,
+ final int inputHints )
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_activityDelegate.showSoftwareKeyboard(x, y, width, height, inputHints);
+ }
+ });
+ }
+
+ private static void resetSoftwareKeyboard()
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_activityDelegate.resetSoftwareKeyboard();
+ }
+ });
+ }
+
+ private static void hideSoftwareKeyboard()
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_activityDelegate.hideSoftwareKeyboard();
+ }
+ });
+ }
+
+ private static boolean isSoftwareKeyboardVisible()
+ {
+ Semaphore semaphore = new Semaphore(1);
+ Boolean ret = false;
+ class RunnableRes implements Runnable {
+ @SuppressWarnings("unused")
+ Boolean returnValue = null;
+ Semaphore semaphore = null;
+ RunnableRes(Boolean ret, Semaphore sem) {
+ semaphore = sem;
+ returnValue = ret;
+ }
+ @Override
+ public void run() {
+ returnValue = m_activityDelegate.isSoftwareKeyboardVisible();
+ semaphore.release();
+ }
+ }
+
+ runAction(new RunnableRes(ret, semaphore));
+ try {
+ semaphore.acquire();
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+ return ret;
+ }
+
+ private static void setFullScreen(final boolean fullScreen)
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_activityDelegate.setFullScreen(fullScreen);
+ updateWindow();
+ }
+ });
+ }
+
+ private static void registerClipboardManager()
+ {
+ final Semaphore semaphore = new Semaphore(1);
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_clipboardManager = (android.text.ClipboardManager) m_activity.getSystemService(Context.CLIPBOARD_SERVICE);
+ semaphore.release();
+ }
+ });
+ try {
+ semaphore.acquire();
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+ }
+
+ private static void setClipboardText(String text)
+ {
+ m_clipboardManager.setText(text);
+ }
+
+ private static boolean hasClipboardText()
+ {
+ return m_clipboardManager.hasText();
+ }
+
+ private static String getClipboardText()
+ {
+ return m_clipboardManager.getText().toString();
+ }
+
+ private static void openContextMenu()
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_activityDelegate.openContextMenu();
+ }
+ });
+ }
+
+ private static void closeContextMenu()
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_activityDelegate.closeContextMenu();
+ }
+ });
+ }
+
+ private static void resetOptionsMenu()
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_activityDelegate.resetOptionsMenu();
+ }
+ });
+ }
+
+ // screen methods
+ public static native void setDisplayMetrics(int screenWidthPixels,
+ int screenHeightPixels,
+ int desktopWidthPixels,
+ int desktopHeightPixels,
+ double XDpi,
+ double YDpi,
+ double scaledDensity);
+ public static native void handleOrientationChanged(int newOrientation);
+ // screen methods
+
+ // pointer methods
+ public static native void mouseDown(int winId, int x, int y);
+ public static native void mouseUp(int winId, int x, int y);
+ public static native void mouseMove(int winId, int x, int y);
+ public static native void touchBegin(int winId);
+ public static native void touchAdd(int winId, int pointerId, int action, boolean primary, int x, int y, float size, float pressure);
+ public static native void touchEnd(int winId, int action);
+ public static native void longPress(int winId, int x, int y);
+ // pointer methods
+
+ // keyboard methods
+ public static native void keyDown(int key, int unicode, int modifier);
+ public static native void keyUp(int key, int unicode, int modifier);
+ // keyboard methods
+
+ // surface methods
+ public static native void destroySurface();
+ public static native void setSurface(Object surface);
+ public static native void lockSurface();
+ public static native void unlockSurface();
+ // surface methods
+
+ // window methods
+ public static native void updateWindow();
+ // window methods
+
+ // menu methods
+ public static native boolean onPrepareOptionsMenu(Menu menu);
+ public static native boolean onOptionsItemSelected(int itemId, boolean checked);
+ public static native void onOptionsMenuClosed(Menu menu);
+
+ public static native void onCreateContextMenu(ContextMenu menu);
+ public static native boolean onContextItemSelected(int itemId, boolean checked);
+ public static native void onContextMenuClosed(Menu menu);
+ // menu methods
+}
diff --git a/src/android/jar/src/org/qtproject/qt5/android/QtNativeLibrariesDir.java b/src/android/jar/src/org/qtproject/qt5/android/QtNativeLibrariesDir.java
new file mode 100644
index 0000000000..219ea13f1a
--- /dev/null
+++ b/src/android/jar/src/org/qtproject/qt5/android/QtNativeLibrariesDir.java
@@ -0,0 +1,61 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Android port of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+package org.qtproject.qt5.android;
+
+import android.app.Activity;
+import android.content.pm.ApplicationInfo;
+import android.content.pm.PackageManager.NameNotFoundException;
+
+public class QtNativeLibrariesDir {
+ public static String nativeLibrariesDir(Activity activity)
+ {
+ String m_nativeLibraryDir = null;
+ try {
+ ApplicationInfo ai = activity.getPackageManager().getApplicationInfo(activity.getPackageName(), 0);
+ m_nativeLibraryDir = ai.nativeLibraryDir+"/";
+ } catch (NameNotFoundException e) {
+ e.printStackTrace();
+ }
+ return m_nativeLibraryDir;
+ }
+}
diff --git a/src/android/jar/src/org/qtproject/qt5/android/QtSurface.java b/src/android/jar/src/org/qtproject/qt5/android/QtSurface.java
new file mode 100644
index 0000000000..b994a43ac4
--- /dev/null
+++ b/src/android/jar/src/org/qtproject/qt5/android/QtSurface.java
@@ -0,0 +1,207 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Android port of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+package org.qtproject.qt5.android;
+
+import android.app.Activity;
+import android.content.Context;
+import android.graphics.Bitmap;
+import android.graphics.Canvas;
+import android.graphics.Rect;
+import android.graphics.PixelFormat;
+import android.util.DisplayMetrics;
+import android.util.Log;
+import android.view.GestureDetector;
+import android.view.MotionEvent;
+import android.view.SurfaceHolder;
+import android.view.SurfaceView;
+
+public class QtSurface extends SurfaceView implements SurfaceHolder.Callback
+{
+ private Bitmap m_bitmap = null;
+ private boolean m_started = false;
+ private boolean m_usesGL = false;
+ private GestureDetector m_gestureDetector;
+
+ public QtSurface(Context context, int id)
+ {
+ super(context);
+ setFocusable(true);
+ getHolder().addCallback(this);
+ getHolder().setType(SurfaceHolder.SURFACE_TYPE_GPU);
+ setId(id);
+ m_gestureDetector =
+ new GestureDetector(context, new GestureDetector.SimpleOnGestureListener() {
+ public void onLongPress(MotionEvent event) {
+ if (!m_started)
+ return;
+ QtNative.longPress(getId(), (int) event.getX(), (int) event.getY());
+ }
+ });
+ m_gestureDetector.setIsLongpressEnabled(true);
+ }
+
+ public void applicationStarted(boolean usesGL)
+ {
+ m_started = true;
+ m_usesGL = usesGL;
+ if (getWidth() < 1 || getHeight() < 1)
+ return;
+ if (m_usesGL) {
+ QtNative.setSurface(getHolder().getSurface());
+ } else {
+ QtNative.lockSurface();
+ QtNative.setSurface(null);
+ m_bitmap = Bitmap.createBitmap(getWidth(), getHeight(), Bitmap.Config.RGB_565);
+ QtNative.setSurface(m_bitmap);
+ QtNative.unlockSurface();
+ }
+ }
+
+ @Override
+ public void surfaceCreated(SurfaceHolder holder)
+ {
+ DisplayMetrics metrics = new DisplayMetrics();
+ ((Activity) getContext()).getWindowManager().getDefaultDisplay().getMetrics(metrics);
+ QtNative.setApplicationDisplayMetrics(metrics.widthPixels,
+ metrics.heightPixels, getWidth(), getHeight(), metrics.xdpi, metrics.ydpi, metrics.scaledDensity);
+
+ if (m_usesGL)
+ holder.setFormat(PixelFormat.RGBA_8888);
+
+// if (!m_started)
+// return;
+//
+// if (m_usesGL)
+// QtApplication.setSurface(holder.getSurface());
+// else
+// {
+// QtApplication.lockSurface();
+// QtApplication.setSurface(null);
+// m_bitmap=Bitmap.createBitmap(getWidth(), getHeight(), Bitmap.Config.RGB_565);
+// QtApplication.setSurface(m_bitmap);
+// QtApplication.unlockSurface();
+// }
+ }
+
+ @Override
+ public void surfaceChanged(SurfaceHolder holder, int format, int width, int height)
+ {
+ if (width<1 || height<1)
+ return;
+
+ DisplayMetrics metrics = new DisplayMetrics();
+ ((Activity) getContext()).getWindowManager().getDefaultDisplay().getMetrics(metrics);
+ QtNative.setApplicationDisplayMetrics(metrics.widthPixels,
+ metrics.heightPixels,
+ width,
+ height,
+ metrics.xdpi,
+ metrics.ydpi,
+ metrics.scaledDensity);
+
+ if (!m_started)
+ return;
+
+ if (m_usesGL) {
+ QtNative.setSurface(holder.getSurface());
+ } else {
+ QtNative.lockSurface();
+ QtNative.setSurface(null);
+ m_bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.RGB_565);
+ QtNative.setSurface(m_bitmap);
+ QtNative.unlockSurface();
+ QtNative.updateWindow();
+ }
+ }
+
+ @Override
+ public void surfaceDestroyed(SurfaceHolder holder)
+ {
+ if (m_usesGL) {
+ QtNative.destroySurface();
+ } else {
+ if (!m_started)
+ return;
+
+ QtNative.lockSurface();
+ QtNative.setSurface(null);
+ QtNative.unlockSurface();
+ }
+ }
+
+ public void drawBitmap(Rect rect)
+ {
+ if (!m_started)
+ return;
+ QtNative.lockSurface();
+ if (null != m_bitmap) {
+ try {
+ Canvas cv = getHolder().lockCanvas(rect);
+ cv.drawBitmap(m_bitmap, rect, rect, null);
+ getHolder().unlockCanvasAndPost(cv);
+ } catch (Exception e) {
+ Log.e(QtNative.QtTAG, "Can't create main activity", e);
+ }
+ }
+ QtNative.unlockSurface();
+ }
+
+ @Override
+ public boolean onTouchEvent(MotionEvent event)
+ {
+ if (!m_started)
+ return false;
+ QtNative.sendTouchEvent(event, getId());
+ m_gestureDetector.onTouchEvent(event);
+ return true;
+ }
+
+ @Override
+ public boolean onTrackballEvent(MotionEvent event)
+ {
+ if (!m_started)
+ return false;
+ QtNative.sendTrackballEvent(event, getId());
+ return true;
+ }
+}
diff --git a/src/android/java/AndroidManifest.xml b/src/android/java/AndroidManifest.xml
new file mode 100644
index 0000000000..6a407dcb6e
--- /dev/null
+++ b/src/android/java/AndroidManifest.xml
@@ -0,0 +1,33 @@
+<?xml version='1.0' encoding='utf-8'?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="1" android:versionName="1.0" package="org.qtproject.example">
+ <application android:name="org.qtproject.qt5.android.bindings.QtApplication" android:label="@string/app_name">
+ <activity android:name="org.qtproject.qt5.android.bindings.QtActivity" android:label="@string/app_name" android:configChanges="orientation|locale|fontScale|keyboard|keyboardHidden" >
+ <intent-filter>
+ <action android:name="android.intent.action.MAIN"/>
+ <category android:name="android.intent.category.LAUNCHER"/>
+ </intent-filter>
+ <meta-data android:name="android.app.qt_sources_resource_id" android:resource="@array/qt_sources"/>
+ <meta-data android:name="android.app.repository" android:value="@string/repository"/>
+ <meta-data android:name="android.app.qt_libs_resource_id" android:resource="@array/qt_libs"/>
+ <meta-data android:name="android.app.bundled_libs_resource_id" android:resource="@array/bundled_libs"/>
+ <meta-data android:name="android.app.lib_name" android:value=""/>
+ <!-- Run with local libs -->
+ <meta-data android:name="android.app.use_local_qt_libs" android:value="0"/>
+ <meta-data android:name="android.app.libs_prefix" android:value="/data/local/tmp/qt/"/>
+ <meta-data android:name="android.app.load_local_libs" android:value=""/>
+ <meta-data android:name="android.app.load_local_jars" android:value=""/>
+ <meta-data android:name="android.app.static_init_classes" android:value=""/>
+ <!-- Messages maps -->
+ <meta-data android:name="android.app.ministro_not_found_msg" android:value="@string/ministro_not_found_msg"/>
+ <meta-data android:name="android.app.ministro_needed_msg" android:value="@string/ministro_needed_msg"/>
+ <meta-data android:name="android.app.fatal_error_msg" android:value="@string/fatal_error_msg"/>
+ <!-- Messages maps -->
+ <!-- Splash screen -->
+ <meta-data android:name="android.app.splash_screen" android:resource="@layout/splash"/>
+ <!-- Splash screen -->
+ </activity>
+ </application>
+ <supports-screens android:largeScreens="true" android:normalScreens="true" android:anyDensity="true" android:smallScreens="true"/>
+ <uses-permission android:name="android.permission.INTERNET"/>
+ <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
+</manifest>
diff --git a/src/android/java/java.pro b/src/android/java/java.pro
new file mode 100644
index 0000000000..22c8ecc034
--- /dev/null
+++ b/src/android/java/java.pro
@@ -0,0 +1,11 @@
+CONFIG -= qt
+
+javaresources.files = \
+ $$PWD/AndroidManifest.xml \
+ $$PWD/version.xml \
+ $$PWD/res \
+ $$PWD/src
+
+javaresources.path = $$[QT_INSTALL_PREFIX]/src/android/java
+
+INSTALLS += javaresources
diff --git a/src/android/java/res/layout/splash.xml b/src/android/java/res/layout/splash.xml
new file mode 100644
index 0000000000..6b0d492dd5
--- /dev/null
+++ b/src/android/java/res/layout/splash.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:orientation="vertical"
+ android:layout_width="fill_parent"
+ android:layout_height="fill_parent"
+ android:layout_gravity="center"
+ >
+ <ImageView
+ android:layout_width="fill_parent"
+ android:layout_height="fill_parent"
+ android:scaleType="fitXY"
+ />
+</LinearLayout>
diff --git a/src/android/java/res/values-de/strings.xml b/src/android/java/res/values-de/strings.xml
new file mode 100644
index 0000000000..320d9ec33f
--- /dev/null
+++ b/src/android/java/res/values-de/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Ministro-Dienst wurde nicht gefunden.\nAnwendung kann nicht gestartet werden</string>
+ <string name="ministro_needed_msg">Diese Anwendung benötigt den Ministro-Dienst. Möchten Sie ihn installieren?</string>
+ <string name="fatal_error_msg">In Ihrer Anwendung ist ein schwerwiegender Fehler aufgetreten, sie kann nicht fortgesetzt werden</string>
+</resources>
diff --git a/src/android/java/res/values-el/strings.xml b/src/android/java/res/values-el/strings.xml
new file mode 100644
index 0000000000..3cab212f2b
--- /dev/null
+++ b/src/android/java/res/values-el/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Δεν ήταν δυνατή η εύρεση της υπηρεσίας Ministro. Δεν είναι δυνατή η εκκίνηση της εφαρμογής.</string>
+ <string name="ministro_needed_msg">Η εφαρμογή απαιτεί την υπηρεσία Ministro. Να εγκατασταθεί η υπηρεσία?</string>
+ <string name="fatal_error_msg">Παρουσιάστηκε ένα κρίσιμο σφάλμα και η εφαρμογή δεν μπορεί να συνεχίσει.</string>
+</resources>
diff --git a/src/android/java/res/values-es/strings.xml b/src/android/java/res/values-es/strings.xml
new file mode 100644
index 0000000000..cf0b54d0b0
--- /dev/null
+++ b/src/android/java/res/values-es/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Servicio Ministro inesistente. Imposible ejecutar la aplicación.</string>
+ <string name="ministro_needed_msg">Esta aplicación requiere el servicio Ministro. Instalarlo?</string>
+ <string name="fatal_error_msg">La aplicación ha causado un error grave y no es posible continuar.</string>
+</resources>
diff --git a/src/android/java/res/values-et/strings.xml b/src/android/java/res/values-et/strings.xml
new file mode 100644
index 0000000000..d55a3c1471
--- /dev/null
+++ b/src/android/java/res/values-et/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Ei suuda leida Ministro teenust.\nProgrammi ei saa käivitada.</string>
+ <string name="ministro_needed_msg">See programm vajab Ministro teenust.\nKas soovite paigaldada?</string>
+ <string name="fatal_error_msg">Programmiga juhtus fataalne viga.\nKahjuks ei saa jätkata.</string>
+</resources>
diff --git a/src/android/java/res/values-fa/strings.xml b/src/android/java/res/values-fa/strings.xml
new file mode 100644
index 0000000000..a8d1b87444
--- /dev/null
+++ b/src/android/java/res/values-fa/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">سرویس Ministro را پیدا نمی‌کند. برنامه نمی‌تواند آغاز شود.</string>
+ <string name="ministro_needed_msg">این نرم‌افزار به سرویس Ministro احتیاج دارد. آیا دوست دارید آن را نصب کنید؟</string>
+ <string name="fatal_error_msg">خطایی اساسی در برنامه‌تان رخ داد و اجرای برنامه نمی‌تواند ادامه یابد.</string>
+</resources>
diff --git a/src/android/java/res/values-fr/strings.xml b/src/android/java/res/values-fr/strings.xml
new file mode 100644
index 0000000000..efc0fb6e1e
--- /dev/null
+++ b/src/android/java/res/values-fr/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Le service Ministro est introuvable.\nL\'application ne peut pas démarrer.</string>
+ <string name="ministro_needed_msg">Cette application requiert le service Ministro. Voulez-vous l\'installer?</string>
+ <string name="fatal_error_msg">Votre application a rencontré une erreur fatale et ne peut pas continuer.</string>
+</resources>
diff --git a/src/android/java/res/values-id/strings.xml b/src/android/java/res/values-id/strings.xml
new file mode 100644
index 0000000000..aaa5bda0de
--- /dev/null
+++ b/src/android/java/res/values-id/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Layanan Ministro tidak bisa ditemukan.\nAplikasi tidak bisa dimulai.</string>
+ <string name="ministro_needed_msg">Aplikasi ini membutuhkan layanan Ministro. Apakah Anda ingin menginstalnya?</string>
+ <string name="fatal_error_msg">Aplikasi Anda mengalami kesalahan fatal dan tidak dapat melanjutkan.</string>
+</resources>
diff --git a/src/android/java/res/values-it/strings.xml b/src/android/java/res/values-it/strings.xml
new file mode 100644
index 0000000000..4773419c44
--- /dev/null
+++ b/src/android/java/res/values-it/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Servizio Ministro inesistente. Impossibile eseguire \nl\'applicazione.</string>
+ <string name="ministro_needed_msg">Questa applicazione richiede il servizio Ministro.Installarlo?</string>
+ <string name="fatal_error_msg">L\'applicazione ha provocato un errore grave e non puo\' continuare.</string>
+</resources>
diff --git a/src/android/java/res/values-ja/strings.xml b/src/android/java/res/values-ja/strings.xml
new file mode 100644
index 0000000000..ba1cfda9ec
--- /dev/null
+++ b/src/android/java/res/values-ja/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Ministroサービスが見つかりません。\nアプリケーションが起動できません。</string>
+ <string name="ministro_needed_msg">このアプリケーションにはMinistroサービスが必要です。 インストールしてもよろしいですか?</string>
+ <string name="fatal_error_msg">アプリケーションで致命的なエラーが発生したため続行できません。</string>
+</resources>
diff --git a/src/android/java/res/values-ms/strings.xml b/src/android/java/res/values-ms/strings.xml
new file mode 100644
index 0000000000..6e3952eaec
--- /dev/null
+++ b/src/android/java/res/values-ms/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Tidak jumpa servis Ministro.\nAplikasi tidak boleh dimulakan.</string>
+ <string name="ministro_needed_msg">Aplikasi ini memerlukan servis Ministro. Adakah anda ingin pasang servis itu?</string>
+ <string name="fatal_error_msg">Aplikasi anda menemui ralat muat dan tidak boleh diteruskan.</string>
+</resources>
diff --git a/src/android/java/res/values-nb/strings.xml b/src/android/java/res/values-nb/strings.xml
new file mode 100644
index 0000000000..8a550e99a2
--- /dev/null
+++ b/src/android/java/res/values-nb/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Kan ikke finne tjenesten Ministro. Applikasjonen kan ikke starte.</string>
+ <string name="ministro_needed_msg">Denne applikasjonen krever tjenesten Ministro. Vil du installere denne?</string>
+ <string name="fatal_error_msg">Applikasjonen fikk en kritisk feil og kan ikke fortsette</string>
+</resources>
diff --git a/src/android/java/res/values-nl/strings.xml b/src/android/java/res/values-nl/strings.xml
new file mode 100644
index 0000000000..8a45a724ff
--- /dev/null
+++ b/src/android/java/res/values-nl/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">De Ministro service is niet gevonden.\nDe applicatie kan niet starten.</string>
+ <string name="ministro_needed_msg">Deze applicatie maakt gebruik van de Ministro service. Wilt u deze installeren?</string>
+ <string name="fatal_error_msg">Er is een fatale fout in de applicatie opgetreden. De applicatie kan niet verder gaan.</string>
+</resources>
diff --git a/src/android/java/res/values-pl/strings.xml b/src/android/java/res/values-pl/strings.xml
new file mode 100644
index 0000000000..9fefc92dcd
--- /dev/null
+++ b/src/android/java/res/values-pl/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Usługa Ministro nie została znaleziona.\nAplikacja nie może zostać uruchomiona.</string>
+ <string name="ministro_needed_msg">Aplikacja wymaga usługi Ministro. Czy chcesz ją zainstalować?</string>
+ <string name="fatal_error_msg">Wystąpił błąd krytyczny. Aplikacja zostanie zamknięta.</string>
+</resources>
diff --git a/src/android/java/res/values-pt-rBR/strings.xml b/src/android/java/res/values-pt-rBR/strings.xml
new file mode 100644
index 0000000000..67ac3f9f98
--- /dev/null
+++ b/src/android/java/res/values-pt-rBR/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Não foi possível encontrar o serviço Ministro.\nA aplicação não pode iniciar.</string>
+ <string name="ministro_needed_msg">Essa aplicação requer o serviço Ministro. Gostaria de instalá-lo?</string>
+ <string name="fatal_error_msg">Sua aplicação encontrou um erro fatal e não pode continuar.</string>
+</resources>
diff --git a/src/android/java/res/values-ro/strings.xml b/src/android/java/res/values-ro/strings.xml
new file mode 100644
index 0000000000..f88a442b35
--- /dev/null
+++ b/src/android/java/res/values-ro/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Serviciul Ministro nu poate fi găsit.\nAplicaţia nu poate porni.</string>
+ <string name="ministro_needed_msg">Această aplicaţie necesită serviciul Ministro.\nDoriţi să-l instalaţi?</string>
+ <string name="fatal_error_msg">Aplicaţia dumneavoastră a întâmpinat o eroare fatală şi nu poate continua.</string>
+</resources>
diff --git a/src/android/java/res/values-rs/strings.xml b/src/android/java/res/values-rs/strings.xml
new file mode 100644
index 0000000000..3194ce9022
--- /dev/null
+++ b/src/android/java/res/values-rs/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Ministro servise nije pronađen. Aplikacija ne može biti pokrenuta.</string>
+ <string name="ministro_needed_msg">Ova aplikacija zahteva Ministro servis. Želite li da ga instalirate?</string>
+ <string name="fatal_error_msg">Vaša aplikacija je naišla na fatalnu grešku i ne može nastaviti sa radom.</string>
+</resources>
diff --git a/src/android/java/res/values-ru/strings.xml b/src/android/java/res/values-ru/strings.xml
new file mode 100644
index 0000000000..d3cee80f9d
--- /dev/null
+++ b/src/android/java/res/values-ru/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">Сервис Ministro не найден.\nПриложение нельзя запустить.</string>
+ <string name="ministro_needed_msg">Этому приложению необходим сервис Ministro. Вы хотите его установить?</string>
+ <string name="fatal_error_msg">Ваше приложение столкнулось с фатальной ошибкой и не может более работать.</string>
+</resources>
diff --git a/src/android/java/res/values-zh-rCN/strings.xml b/src/android/java/res/values-zh-rCN/strings.xml
new file mode 100644
index 0000000000..2eb1269880
--- /dev/null
+++ b/src/android/java/res/values-zh-rCN/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">无法找到Ministro服务。\n应用程序无法启动。</string>
+ <string name="ministro_needed_msg">此应用程序需要Ministro服务。您想安装它吗?</string>
+ <string name="fatal_error_msg">您的应用程序遇到一个致命错误导致它无法继续。</string>
+</resources>
diff --git a/src/android/java/res/values-zh-rTW/strings.xml b/src/android/java/res/values-zh-rTW/strings.xml
new file mode 100644
index 0000000000..f6e68efa52
--- /dev/null
+++ b/src/android/java/res/values-zh-rTW/strings.xml
@@ -0,0 +1,6 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="ministro_not_found_msg">無法找到Ministro服務。\n應用程序無法啟動。</string>
+ <string name="ministro_needed_msg">此應用程序需要Ministro服務。您想安裝它嗎?</string>
+ <string name="fatal_error_msg">您的應用程序遇到一個致命錯誤導致它無法繼續。</string>
+</resources>
diff --git a/src/android/java/res/values/libs.xml b/src/android/java/res/values/libs.xml
new file mode 100644
index 0000000000..f47174e3d3
--- /dev/null
+++ b/src/android/java/res/values/libs.xml
@@ -0,0 +1,11 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <array name="qt_sources">
+ <item>https://files.kde.org/necessitas/ministro/android/necessitas/qt5/latest</item>
+ </array>
+ <string name="repository">default</string>
+ <array name="qt_libs">
+ <item>Qt5Core</item>
+ </array>
+ <array name="bundled_libs"/>
+</resources>
diff --git a/src/android/java/res/values/strings.xml b/src/android/java/res/values/strings.xml
new file mode 100644
index 0000000000..bd6928fe59
--- /dev/null
+++ b/src/android/java/res/values/strings.xml
@@ -0,0 +1,7 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <string name="app_name"></string>
+ <string name="ministro_not_found_msg">Can\'t find Ministro service.\nThe application can\'t start.</string>
+ <string name="ministro_needed_msg">This application requires Ministro service. Would you like to install it?</string>
+ <string name="fatal_error_msg">Your application encountered a fatal error and cannot continue.</string>
+</resources>
diff --git a/src/android/java/src/org/kde/necessitas/ministro/IMinistro.aidl b/src/android/java/src/org/kde/necessitas/ministro/IMinistro.aidl
new file mode 100644
index 0000000000..236a62f63e
--- /dev/null
+++ b/src/android/java/src/org/kde/necessitas/ministro/IMinistro.aidl
@@ -0,0 +1,50 @@
+/*
+ Copyright (c) 2011-2013, BogDan Vatra <bogdan@kde.org>
+ Contact: http://www.qt-project.org/legal
+
+ 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 AUTHOR ``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 AUTHOR 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.
+*/
+
+
+package org.kde.necessitas.ministro;
+
+import org.kde.necessitas.ministro.IMinistroCallback;
+
+interface IMinistro
+{
+/**
+* Check/download required libs to run the application
+*
+* param callback - interface used by Minsitro service to notify the client when the loader is ready
+* param parameters
+* parameters fields:
+* * Key Name Key type Explanations
+* "sources" StringArray Sources list from where Ministro will download the libs. Make sure you are using ONLY secure locations.
+* "repository" String Overwrites the default Ministro repository. Possible values: default, stable, testing and unstable
+* "required.modules" StringArray Required modules by your application
+* "application.title" String Application name, used to show more informations to user
+* "qt.provider" String Qt libs provider, currently only "necessitas" is supported.
+* "minimum.ministro.api" Integer Minimum Ministro API level, used to check if Ministro service compatible with your application. Current API Level is 3 !
+* "minimum.qt.version" Integer Minimim Qt version (e.g. 0x040800, which means Qt 4.8.0, check http://qt-project.org/doc/qt-4.8/qtglobal.html#QT_VERSION)!
+*/
+ void requestLoader(in IMinistroCallback callback, in Bundle parameters);
+}
diff --git a/src/android/java/src/org/kde/necessitas/ministro/IMinistroCallback.aidl b/src/android/java/src/org/kde/necessitas/ministro/IMinistroCallback.aidl
new file mode 100644
index 0000000000..0bcb5285b8
--- /dev/null
+++ b/src/android/java/src/org/kde/necessitas/ministro/IMinistroCallback.aidl
@@ -0,0 +1,55 @@
+/*
+ Copyright (c) 2011-2013, BogDan Vatra <bogdan@kde.org>
+ Contact: http://www.qt-project.org/legal
+
+ 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 AUTHOR ``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 AUTHOR 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.
+*/
+
+package org.kde.necessitas.ministro;
+
+oneway interface IMinistroCallback {
+/**
+* This method is called by the Ministro service back into the application which
+* implements this interface.
+*
+* param in - loaderParams
+* loaderParams fields:
+* * Key Name Key type Explanations
+* * "error.code" Integer See below
+* * "error.message" String Missing if no error, otherwise will contain the error message translated into phone language where available.
+* * "dex.path" String The list of jar/apk files containing classes and resources, needed to be passed to application DexClassLoader
+* * "lib.path" String The list of directories containing native libraries; may be missing, needed to be passed to application DexClassLoader
+* * "loader.class.name" String Loader class name.
+*
+* "error.code" field possible errors:
+* - 0 no error.
+* - 1 incompatible Ministro version. Ministro needs to be upgraded.
+* - 2 not all modules could be satisfy.
+* - 3 invalid parameters
+* - 4 invalid qt version
+* - 5 download canceled
+*
+* The parameter contains additional fields which are used by the loader to start your application, so it must be passed to the loader.
+*/
+
+ void loaderReady(in Bundle loaderParams);
+}
diff --git a/src/android/java/src/org/qtproject/qt5/android/bindings/QtActivity.java b/src/android/java/src/org/qtproject/qt5/android/bindings/QtActivity.java
new file mode 100644
index 0000000000..dfb638fbb0
--- /dev/null
+++ b/src/android/java/src/org/qtproject/qt5/android/bindings/QtActivity.java
@@ -0,0 +1,1295 @@
+/*
+ Copyright (c) 2012-2013, BogDan Vatra <bogdan@kde.org>
+ Contact: http://www.qt-project.org/legal
+
+ 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 AUTHOR ``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 AUTHOR 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.
+*/
+
+package org.qtproject.qt5.android.bindings;
+
+import java.io.File;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.Arrays;
+
+import org.kde.necessitas.ministro.IMinistro;
+import org.kde.necessitas.ministro.IMinistroCallback;
+
+import android.app.Activity;
+import android.app.AlertDialog;
+import android.app.Dialog;
+import android.content.ComponentName;
+import android.content.Context;
+import android.content.DialogInterface;
+import android.content.Intent;
+import android.content.ServiceConnection;
+import android.content.pm.ActivityInfo;
+import android.content.pm.PackageManager;
+import android.content.pm.PackageManager.NameNotFoundException;
+import android.content.res.Configuration;
+import android.content.res.Resources.Theme;
+import android.graphics.Bitmap;
+import android.graphics.Canvas;
+import android.net.Uri;
+import android.os.Bundle;
+import android.os.IBinder;
+import android.os.RemoteException;
+import android.util.AttributeSet;
+import android.util.Log;
+import android.view.ContextMenu;
+import android.view.ContextMenu.ContextMenuInfo;
+import android.view.KeyEvent;
+import android.view.Menu;
+import android.view.MenuItem;
+import android.view.MotionEvent;
+import android.view.View;
+import android.view.Window;
+import android.view.WindowManager.LayoutParams;
+import android.view.accessibility.AccessibilityEvent;
+import dalvik.system.DexClassLoader;
+
+//@ANDROID-11
+import android.app.Fragment;
+import android.view.ActionMode;
+import android.view.ActionMode.Callback;
+//@ANDROID-11
+
+public class QtActivity extends Activity
+{
+ private final static int MINISTRO_INSTALL_REQUEST_CODE = 0xf3ee; // request code used to know when Ministro instalation is finished
+ private static final int MINISTRO_API_LEVEL = 3; // Ministro api level (check IMinistro.aidl file)
+ private static final int NECESSITAS_API_LEVEL = 2; // Necessitas api level used by platform plugin
+ private static final int QT_VERSION = 0x050100; // This app requires at least Qt version 5.1.0
+
+ private static final String ERROR_CODE_KEY = "error.code";
+ private static final String ERROR_MESSAGE_KEY = "error.message";
+ private static final String DEX_PATH_KEY = "dex.path";
+ private static final String LIB_PATH_KEY = "lib.path";
+ private static final String LOADER_CLASS_NAME_KEY = "loader.class.name";
+ private static final String NATIVE_LIBRARIES_KEY = "native.libraries";
+ private static final String ENVIRONMENT_VARIABLES_KEY = "environment.variables";
+ private static final String APPLICATION_PARAMETERS_KEY = "application.parameters";
+ private static final String BUNDLED_LIBRARIES_KEY = "bundled.libraries";
+ private static final String MAIN_LIBRARY_KEY = "main.library";
+ private static final String STATIC_INIT_CLASSES_KEY = "static.init.classes";
+ private static final String NECESSITAS_API_LEVEL_KEY = "necessitas.api.level";
+
+ /// Ministro server parameter keys
+ private static final String REQUIRED_MODULES_KEY = "required.modules";
+ private static final String APPLICATION_TITLE_KEY = "application.title";
+ private static final String MINIMUM_MINISTRO_API_KEY = "minimum.ministro.api";
+ private static final String MINIMUM_QT_VERSION_KEY = "minimum.qt.version";
+ private static final String SOURCES_KEY = "sources"; // needs MINISTRO_API_LEVEL >=3 !!!
+ // Use this key to specify any 3rd party sources urls
+ // Ministro will download these repositories into their
+ // own folders, check http://community.kde.org/Necessitas/Ministro
+ // for more details.
+
+ private static final String REPOSITORY_KEY = "repository"; // use this key to overwrite the default ministro repsitory
+
+ private static final String APPLICATION_PARAMETERS = null; // use this variable to pass any parameters to your application,
+ // the parameters must not contain any white spaces
+ // and must be separated with "\t"
+ // e.g "-param1\t-param2=value2\t-param3\tvalue3"
+
+ private static final String ENVIRONMENT_VARIABLES = "QT_USE_ANDROID_NATIVE_STYLE=0\t";
+ // use this variable to add any environment variables to your application.
+ // the env vars must be separated with "\t"
+ // e.g. "ENV_VAR1=1\tENV_VAR2=2\t"
+ // Currently the following vars are used by the android plugin:
+ // * QT_USE_ANDROID_NATIVE_STYLE - 1 to use the android widget style if available,
+ // note that the android style plugin in Qt 5.1 is not fully functional.
+
+ private static final int INCOMPATIBLE_MINISTRO_VERSION = 1; // Incompatible Ministro version. Ministro needs to be upgraded.
+ private ActivityInfo m_activityInfo = null; // activity info object, used to access the libs and the strings
+ private DexClassLoader m_classLoader = null; // loader object
+ private String[] m_sources = {"https://files.kde.org/necessitas/ministro/android/necessitas/qt5/latest"}; // Make sure you are using ONLY secure locations
+ private String m_repository = "default"; // Overwrites the default Ministro repository
+ // Possible values:
+ // * default - Ministro default repository set with "Ministro configuration tool".
+ // By default the stable version is used. Only this or stable repositories should
+ // be used in production.
+ // * stable - stable repository, only this and default repositories should be used
+ // in production.
+ // * testing - testing repository, DO NOT use this repository in production,
+ // this repository is used to push a new release, and should be used to test your application.
+ // * unstable - unstable repository, DO NOT use this repository in production,
+ // this repository is used to push Qt snapshots.
+ private String[] m_qtLibs = null; // required qt libs
+
+ // this function is used to load and start the loader
+ private void loadApplication(Bundle loaderParams)
+ {
+ try {
+ final int errorCode = loaderParams.getInt(ERROR_CODE_KEY);
+ if (errorCode != 0) {
+ if (errorCode == INCOMPATIBLE_MINISTRO_VERSION) {
+ downloadUpgradeMinistro(loaderParams.getString(ERROR_MESSAGE_KEY));
+ return;
+ }
+
+ // fatal error, show the error and quit
+ AlertDialog errorDialog = new AlertDialog.Builder(QtActivity.this).create();
+ errorDialog.setMessage(loaderParams.getString(ERROR_MESSAGE_KEY));
+ errorDialog.setButton(getResources().getString(android.R.string.ok), new DialogInterface.OnClickListener() {
+ @Override
+ public void onClick(DialogInterface dialog, int which) {
+ finish();
+ }
+ });
+ errorDialog.show();
+ return;
+ }
+
+ // add all bundled Qt libs to loader params
+ ArrayList<String> libs = new ArrayList<String>();
+ if ( m_activityInfo.metaData.containsKey("android.app.bundled_libs_resource_id") )
+ libs.addAll(Arrays.asList(getResources().getStringArray(m_activityInfo.metaData.getInt("android.app.bundled_libs_resource_id"))));
+
+ String libName = null;
+ if ( m_activityInfo.metaData.containsKey("android.app.lib_name") ) {
+ libName = m_activityInfo.metaData.getString("android.app.lib_name");
+ loaderParams.putString(MAIN_LIBRARY_KEY, libName); //main library contains main() function
+ }
+
+ loaderParams.putStringArrayList(BUNDLED_LIBRARIES_KEY, libs);
+ loaderParams.putInt(NECESSITAS_API_LEVEL_KEY, NECESSITAS_API_LEVEL);
+
+ // load and start QtLoader class
+ m_classLoader = new DexClassLoader(loaderParams.getString(DEX_PATH_KEY), // .jar/.apk files
+ getDir("outdex", Context.MODE_PRIVATE).getAbsolutePath(), // directory where optimized DEX files should be written.
+ loaderParams.containsKey(LIB_PATH_KEY) ? loaderParams.getString(LIB_PATH_KEY) : null, // libs folder (if exists)
+ getClassLoader()); // parent loader
+
+ @SuppressWarnings("rawtypes")
+ Class loaderClass = m_classLoader.loadClass(loaderParams.getString(LOADER_CLASS_NAME_KEY)); // load QtLoader class
+ Object qtLoader = loaderClass.newInstance(); // create an instance
+ Method perpareAppMethod = qtLoader.getClass().getMethod("loadApplication",
+ Activity.class,
+ ClassLoader.class,
+ Bundle.class);
+ if (!(Boolean)perpareAppMethod.invoke(qtLoader, this, m_classLoader, loaderParams))
+ throw new Exception("");
+
+ QtApplication.setQtActivityDelegate(qtLoader);
+
+ // now load the application library so it's accessible from this class loader
+ if (libName != null)
+ System.loadLibrary(libName);
+
+ Method startAppMethod=qtLoader.getClass().getMethod("startApplication");
+ if (!(Boolean)startAppMethod.invoke(qtLoader))
+ throw new Exception("");
+
+ } catch (Exception e) {
+ e.printStackTrace();
+ AlertDialog errorDialog = new AlertDialog.Builder(QtActivity.this).create();
+ if (m_activityInfo.metaData.containsKey("android.app.fatal_error_msg"))
+ errorDialog.setMessage(m_activityInfo.metaData.getString("android.app.fatal_error_msg"));
+ else
+ errorDialog.setMessage("Fatal error, your application can't be started.");
+
+ errorDialog.setButton(getResources().getString(android.R.string.ok), new DialogInterface.OnClickListener() {
+ @Override
+ public void onClick(DialogInterface dialog, int which) {
+ finish();
+ }
+ });
+ errorDialog.show();
+ }
+ }
+
+ private ServiceConnection m_ministroConnection=new ServiceConnection() {
+ private IMinistro m_service = null;
+ @Override
+ public void onServiceConnected(ComponentName name, IBinder service)
+ {
+ m_service = IMinistro.Stub.asInterface(service);
+ try {
+ if (m_service!=null) {
+ Bundle parameters= new Bundle();
+ parameters.putStringArray(REQUIRED_MODULES_KEY, m_qtLibs);
+ parameters.putString(APPLICATION_TITLE_KEY, (String)QtActivity.this.getTitle());
+ parameters.putInt(MINIMUM_MINISTRO_API_KEY, MINISTRO_API_LEVEL);
+ parameters.putInt(MINIMUM_QT_VERSION_KEY, QT_VERSION);
+ parameters.putString(ENVIRONMENT_VARIABLES_KEY, ENVIRONMENT_VARIABLES);
+ if (null!=APPLICATION_PARAMETERS)
+ parameters.putString(APPLICATION_PARAMETERS_KEY, APPLICATION_PARAMETERS);
+ parameters.putStringArray(SOURCES_KEY, m_sources);
+ parameters.putString(REPOSITORY_KEY, m_repository);
+ m_service.requestLoader(m_ministroCallback, parameters);
+ }
+ } catch (RemoteException e) {
+ e.printStackTrace();
+ }
+ }
+
+ private IMinistroCallback m_ministroCallback = new IMinistroCallback.Stub() {
+ // this function is called back by Ministro.
+ @Override
+ public void loaderReady(final Bundle loaderParams) throws RemoteException {
+ runOnUiThread(new Runnable() {
+ @Override
+ public void run() {
+ unbindService(m_ministroConnection);
+ loadApplication(loaderParams);
+ }
+ });
+ }
+ };
+
+ @Override
+ public void onServiceDisconnected(ComponentName name) {
+ m_service = null;
+ }
+ };
+
+ private void downloadUpgradeMinistro(String msg)
+ {
+ AlertDialog.Builder downloadDialog = new AlertDialog.Builder(this);
+ downloadDialog.setMessage(msg);
+ downloadDialog.setPositiveButton(android.R.string.yes, new DialogInterface.OnClickListener() {
+ @Override
+ public void onClick(DialogInterface dialogInterface, int i) {
+ try {
+ Uri uri = Uri.parse("market://search?q=pname:org.kde.necessitas.ministro");
+ Intent intent = new Intent(Intent.ACTION_VIEW, uri);
+ startActivityForResult(intent, MINISTRO_INSTALL_REQUEST_CODE);
+ } catch (Exception e) {
+ e.printStackTrace();
+ ministroNotFound();
+ }
+ }
+ });
+
+ downloadDialog.setNegativeButton(android.R.string.no, new DialogInterface.OnClickListener() {
+ @Override
+ public void onClick(DialogInterface dialogInterface, int i) {
+ QtActivity.this.finish();
+ }
+ });
+ downloadDialog.show();
+ }
+
+ private void ministroNotFound()
+ {
+ AlertDialog errorDialog = new AlertDialog.Builder(QtActivity.this).create();
+
+ if (m_activityInfo.metaData.containsKey("android.app.ministro_not_found_msg"))
+ errorDialog.setMessage(m_activityInfo.metaData.getString("android.app.ministro_not_found_msg"));
+ else
+ errorDialog.setMessage("Can't find Ministro service.\nThe application can't start.");
+
+ errorDialog.setButton(getResources().getString(android.R.string.ok), new DialogInterface.OnClickListener() {
+ @Override
+ public void onClick(DialogInterface dialog, int which) {
+ finish();
+ }
+ });
+ errorDialog.show();
+ }
+
+ private void startApp(final boolean firstStart)
+ {
+ try {
+ if (m_activityInfo.metaData.containsKey("android.app.qt_sources_resource_id")) {
+ int resourceId = m_activityInfo.metaData.getInt("android.app.qt_sources_resource_id");
+ m_sources = getResources().getStringArray(resourceId);
+ }
+
+ if (m_activityInfo.metaData.containsKey("android.app.repository"))
+ m_repository = m_activityInfo.metaData.getString("android.app.repository");
+
+ if (m_activityInfo.metaData.containsKey("android.app.qt_libs_resource_id")) {
+ int resourceId = m_activityInfo.metaData.getInt("android.app.qt_libs_resource_id");
+ m_qtLibs = getResources().getStringArray(resourceId);
+ }
+
+ if (m_activityInfo.metaData.containsKey("android.app.use_local_qt_libs")
+ && m_activityInfo.metaData.getInt("android.app.use_local_qt_libs") == 1) {
+ ArrayList<String> libraryList = new ArrayList<String>();
+
+ String localPrefix = "/data/local/tmp/qt/";
+ if (m_activityInfo.metaData.containsKey("android.app.libs_prefix"))
+ localPrefix = m_activityInfo.metaData.getString("android.app.libs_prefix");
+
+ if (m_qtLibs != null) {
+ for (int i=0;i<m_qtLibs.length;i++)
+ libraryList.add(localPrefix+"lib/lib"+m_qtLibs[i]+".so");
+ }
+
+ if (m_activityInfo.metaData.containsKey("android.app.load_local_libs")) {
+ String[] extraLibs = m_activityInfo.metaData.getString("android.app.load_local_libs").split(":");
+ for (String lib : extraLibs) {
+ if (lib.length() > 0)
+ libraryList.add(localPrefix + lib);
+ }
+ }
+
+ String dexPaths = new String();
+ String pathSeparator = System.getProperty("path.separator", ":");
+ if (m_activityInfo.metaData.containsKey("android.app.load_local_jars")) {
+ String[] jarFiles = m_activityInfo.metaData.getString("android.app.load_local_jars").split(":");
+ for (String jar:jarFiles) {
+ if (jar.length() > 0) {
+ if (dexPaths.length() > 0)
+ dexPaths += pathSeparator;
+ dexPaths += localPrefix + jar;
+ }
+ }
+ }
+
+ Bundle loaderParams = new Bundle();
+ loaderParams.putInt(ERROR_CODE_KEY, 0);
+ loaderParams.putString(DEX_PATH_KEY, dexPaths);
+ loaderParams.putString(LOADER_CLASS_NAME_KEY, "org.qtproject.qt5.android.QtActivityDelegate");
+ if (m_activityInfo.metaData.containsKey("android.app.static_init_classes")) {
+ loaderParams.putStringArray(STATIC_INIT_CLASSES_KEY,
+ m_activityInfo.metaData.getString("android.app.static_init_classes").split(":"));
+ }
+ loaderParams.putStringArrayList(NATIVE_LIBRARIES_KEY, libraryList);
+ loaderParams.putString(ENVIRONMENT_VARIABLES_KEY, ENVIRONMENT_VARIABLES
+ + "QT_QPA_EGLFS_HIDECURSOR=1"
+ + "\tQML2_IMPORT_PATH=" + localPrefix + "/qml"
+ + "\tQML_IMPORT_PATH=" + localPrefix + "/imports"
+ + "\tQT_PLUGIN_PATH=" + localPrefix + "/plugins");
+ loadApplication(loaderParams);
+ return;
+ }
+
+ try {
+ if (!bindService(new Intent(org.kde.necessitas.ministro.IMinistro.class.getCanonicalName()),
+ m_ministroConnection,
+ Context.BIND_AUTO_CREATE)) {
+ throw new SecurityException("");
+ }
+ } catch (Exception e) {
+ if (firstStart) {
+ String msg = "This application requires Ministro service. Would you like to install it?";
+ if (m_activityInfo.metaData.containsKey("android.app.ministro_needed_msg"))
+ msg = m_activityInfo.metaData.getString("android.app.ministro_needed_msg");
+ downloadUpgradeMinistro(msg);
+ } else {
+ ministroNotFound();
+ }
+ }
+ } catch (Exception e) {
+ Log.e(QtApplication.QtTAG, "Can't create main activity", e);
+ }
+ }
+
+
+
+ /////////////////////////// forward all notifications ////////////////////////////
+ /////////////////////////// Super class calls ////////////////////////////////////
+ /////////////// PLEASE DO NOT CHANGE THE FOLLOWING CODE //////////////////////////
+ //////////////////////////////////////////////////////////////////////////////////
+
+ @Override
+ public boolean dispatchKeyEvent(KeyEvent event)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.dispatchKeyEvent != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.dispatchKeyEvent, event);
+ else
+ return super.dispatchKeyEvent(event);
+ }
+ public boolean super_dispatchKeyEvent(KeyEvent event)
+ {
+ return super.dispatchKeyEvent(event);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean dispatchPopulateAccessibilityEvent(AccessibilityEvent event)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.dispatchPopulateAccessibilityEvent != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.dispatchPopulateAccessibilityEvent, event);
+ else
+ return super.dispatchPopulateAccessibilityEvent(event);
+ }
+ public boolean super_dispatchPopulateAccessibilityEvent(AccessibilityEvent event)
+ {
+ return super_dispatchPopulateAccessibilityEvent(event);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean dispatchTouchEvent(MotionEvent ev)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.dispatchTouchEvent != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.dispatchTouchEvent, ev);
+ else
+ return super.dispatchTouchEvent(ev);
+ }
+ public boolean super_dispatchTouchEvent(MotionEvent event)
+ {
+ return super.dispatchTouchEvent(event);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean dispatchTrackballEvent(MotionEvent ev)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.dispatchTrackballEvent != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.dispatchTrackballEvent, ev);
+ else
+ return super.dispatchTrackballEvent(ev);
+ }
+ public boolean super_dispatchTrackballEvent(MotionEvent event)
+ {
+ return super.dispatchTrackballEvent(event);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onActivityResult(int requestCode, int resultCode, Intent data)
+ {
+
+ if (QtApplication.m_delegateObject != null && QtApplication.onActivityResult != null) {
+ QtApplication.invokeDelegateMethod(QtApplication.onActivityResult, requestCode, resultCode, data);
+ return;
+ }
+ if (requestCode == MINISTRO_INSTALL_REQUEST_CODE)
+ startApp(false);
+ super.onActivityResult(requestCode, resultCode, data);
+ }
+ public void super_onActivityResult(int requestCode, int resultCode, Intent data)
+ {
+ super.onActivityResult(requestCode, resultCode, data);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onApplyThemeResource(Theme theme, int resid, boolean first)
+ {
+ if (!QtApplication.invokeDelegate(theme, resid, first).invoked)
+ super.onApplyThemeResource(theme, resid, first);
+ }
+ public void super_onApplyThemeResource(Theme theme, int resid, boolean first)
+ {
+ super.onApplyThemeResource(theme, resid, first);
+ }
+ //---------------------------------------------------------------------------
+
+
+ @Override
+ protected void onChildTitleChanged(Activity childActivity, CharSequence title)
+ {
+ if (!QtApplication.invokeDelegate(childActivity, title).invoked)
+ super.onChildTitleChanged(childActivity, title);
+ }
+ public void super_onChildTitleChanged(Activity childActivity, CharSequence title)
+ {
+ super.onChildTitleChanged(childActivity, title);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onConfigurationChanged(Configuration newConfig)
+ {
+ if (!QtApplication.invokeDelegate(newConfig).invoked)
+ super.onConfigurationChanged(newConfig);
+ }
+ public void super_onConfigurationChanged(Configuration newConfig)
+ {
+ super.onConfigurationChanged(newConfig);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onContentChanged()
+ {
+ if (!QtApplication.invokeDelegate().invoked)
+ super.onContentChanged();
+ }
+ public void super_onContentChanged()
+ {
+ super.onContentChanged();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onContextItemSelected(MenuItem item)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(item);
+ if (res.invoked)
+ return (Boolean)res.methodReturns;
+ else
+ return super.onContextItemSelected(item);
+ }
+ public boolean super_onContextItemSelected(MenuItem item)
+ {
+ return super.onContextItemSelected(item);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onContextMenuClosed(Menu menu)
+ {
+ if (!QtApplication.invokeDelegate(menu).invoked)
+ super.onContextMenuClosed(menu);
+ }
+ public void super_onContextMenuClosed(Menu menu)
+ {
+ super.onContextMenuClosed(menu);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onCreate(Bundle savedInstanceState)
+ {
+ super.onCreate(savedInstanceState);
+ if (QtApplication.m_delegateObject != null && QtApplication.onCreate != null) {
+ QtApplication.invokeDelegateMethod(QtApplication.onCreate, savedInstanceState);
+ return;
+ }
+
+ requestWindowFeature(Window.FEATURE_NO_TITLE);
+ try {
+ m_activityInfo = getPackageManager().getActivityInfo(getComponentName(), PackageManager.GET_META_DATA);
+ } catch (NameNotFoundException e) {
+ e.printStackTrace();
+ finish();
+ return;
+ }
+
+ if (null == getLastNonConfigurationInstance()) {
+ // if splash screen is defined, then show it
+ if (m_activityInfo.metaData.containsKey("android.app.splash_screen") )
+ setContentView(m_activityInfo.metaData.getInt("android.app.splash_screen"));
+ startApp(true);
+ }
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onCreateContextMenu(ContextMenu menu, View v, ContextMenuInfo menuInfo)
+ {
+ if (!QtApplication.invokeDelegate(menu, v, menuInfo).invoked)
+ super.onCreateContextMenu(menu, v, menuInfo);
+ }
+ public void super_onCreateContextMenu(ContextMenu menu, View v, ContextMenuInfo menuInfo)
+ {
+ super.onCreateContextMenu(menu, v, menuInfo);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public CharSequence onCreateDescription()
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate();
+ if (res.invoked)
+ return (CharSequence)res.methodReturns;
+ else
+ return super.onCreateDescription();
+ }
+ public CharSequence super_onCreateDescription()
+ {
+ return super.onCreateDescription();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected Dialog onCreateDialog(int id)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(id);
+ if (res.invoked)
+ return (Dialog)res.methodReturns;
+ else
+ return super.onCreateDialog(id);
+ }
+ public Dialog super_onCreateDialog(int id)
+ {
+ return super.onCreateDialog(id);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onCreateOptionsMenu(Menu menu)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(menu);
+ if (res.invoked)
+ return (Boolean)res.methodReturns;
+ else
+ return super.onCreateOptionsMenu(menu);
+ }
+ public boolean super_onCreateOptionsMenu(Menu menu)
+ {
+ return super.onCreateOptionsMenu(menu);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onCreatePanelMenu(int featureId, Menu menu)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(featureId, menu);
+ if (res.invoked)
+ return (Boolean)res.methodReturns;
+ else
+ return super.onCreatePanelMenu(featureId, menu);
+ }
+ public boolean super_onCreatePanelMenu(int featureId, Menu menu)
+ {
+ return super.onCreatePanelMenu(featureId, menu);
+ }
+ //---------------------------------------------------------------------------
+
+
+ @Override
+ public View onCreatePanelView(int featureId)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(featureId);
+ if (res.invoked)
+ return (View)res.methodReturns;
+ else
+ return super.onCreatePanelView(featureId);
+ }
+ public View super_onCreatePanelView(int featureId)
+ {
+ return super.onCreatePanelView(featureId);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onCreateThumbnail(Bitmap outBitmap, Canvas canvas)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(outBitmap, canvas);
+ if (res.invoked)
+ return (Boolean)res.methodReturns;
+ else
+ return super.onCreateThumbnail(outBitmap, canvas);
+ }
+ public boolean super_onCreateThumbnail(Bitmap outBitmap, Canvas canvas)
+ {
+ return super.onCreateThumbnail(outBitmap, canvas);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public View onCreateView(String name, Context context, AttributeSet attrs)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(name, context, attrs);
+ if (res.invoked)
+ return (View)res.methodReturns;
+ else
+ return super.onCreateView(name, context, attrs);
+ }
+ public View super_onCreateView(String name, Context context, AttributeSet attrs)
+ {
+ return super.onCreateView(name, context, attrs);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onDestroy()
+ {
+ super.onDestroy();
+ QtApplication.invokeDelegate();
+ }
+ //---------------------------------------------------------------------------
+
+
+ @Override
+ public boolean onKeyDown(int keyCode, KeyEvent event)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.onKeyDown != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.onKeyDown, keyCode, event);
+ else
+ return super.onKeyDown(keyCode, event);
+ }
+ public boolean super_onKeyDown(int keyCode, KeyEvent event)
+ {
+ return super.onKeyDown(keyCode, event);
+ }
+ //---------------------------------------------------------------------------
+
+
+ @Override
+ public boolean onKeyMultiple(int keyCode, int repeatCount, KeyEvent event)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.onKeyMultiple != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.onKeyMultiple, keyCode, repeatCount, event);
+ else
+ return super.onKeyMultiple(keyCode, repeatCount, event);
+ }
+ public boolean super_onKeyMultiple(int keyCode, int repeatCount, KeyEvent event)
+ {
+ return super.onKeyMultiple(keyCode, repeatCount, event);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onKeyUp(int keyCode, KeyEvent event)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.onKeyDown != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.onKeyUp, keyCode, event);
+ else
+ return super.onKeyUp(keyCode, event);
+ }
+ public boolean super_onKeyUp(int keyCode, KeyEvent event)
+ {
+ return super.onKeyUp(keyCode, event);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onLowMemory()
+ {
+ if (!QtApplication.invokeDelegate().invoked)
+ super.onLowMemory();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onMenuItemSelected(int featureId, MenuItem item)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(featureId, item);
+ if (res.invoked)
+ return (Boolean)res.methodReturns;
+ else
+ return super.onMenuItemSelected(featureId, item);
+ }
+ public boolean super_onMenuItemSelected(int featureId, MenuItem item)
+ {
+ return super.onMenuItemSelected(featureId, item);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onMenuOpened(int featureId, Menu menu)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(featureId, menu);
+ if (res.invoked)
+ return (Boolean)res.methodReturns;
+ else
+ return super.onMenuOpened(featureId, menu);
+ }
+ public boolean super_onMenuOpened(int featureId, Menu menu)
+ {
+ return super.onMenuOpened(featureId, menu);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onNewIntent(Intent intent)
+ {
+ if (!QtApplication.invokeDelegate(intent).invoked)
+ super.onNewIntent(intent);
+ }
+ public void super_onNewIntent(Intent intent)
+ {
+ super.onNewIntent(intent);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onOptionsItemSelected(MenuItem item)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(item);
+ if (res.invoked)
+ return (Boolean)res.methodReturns;
+ else
+ return super.onOptionsItemSelected(item);
+ }
+ public boolean super_onOptionsItemSelected(MenuItem item)
+ {
+ return super.onOptionsItemSelected(item);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onOptionsMenuClosed(Menu menu)
+ {
+ if (!QtApplication.invokeDelegate(menu).invoked)
+ super.onOptionsMenuClosed(menu);
+ }
+ public void super_onOptionsMenuClosed(Menu menu)
+ {
+ super.onOptionsMenuClosed(menu);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onPanelClosed(int featureId, Menu menu)
+ {
+ if (!QtApplication.invokeDelegate(featureId, menu).invoked)
+ super.onPanelClosed(featureId, menu);
+ }
+ public void super_onPanelClosed(int featureId, Menu menu)
+ {
+ super.onPanelClosed(featureId, menu);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onPause()
+ {
+ super.onPause();
+ QtApplication.invokeDelegate();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onPostCreate(Bundle savedInstanceState)
+ {
+ super.onPostCreate(savedInstanceState);
+ QtApplication.invokeDelegate(savedInstanceState);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onPostResume()
+ {
+ super.onPostResume();
+ QtApplication.invokeDelegate();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onPrepareDialog(int id, Dialog dialog)
+ {
+ if (!QtApplication.invokeDelegate(id, dialog).invoked)
+ super.onPrepareDialog(id, dialog);
+ }
+ public void super_onPrepareDialog(int id, Dialog dialog)
+ {
+ super.onPrepareDialog(id, dialog);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onPrepareOptionsMenu(Menu menu)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(menu);
+ if (res.invoked)
+ return (Boolean)res.methodReturns;
+ else
+ return super.onPrepareOptionsMenu(menu);
+ }
+ public boolean super_onPrepareOptionsMenu(Menu menu)
+ {
+ return super.onPrepareOptionsMenu(menu);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onPreparePanel(int featureId, View view, Menu menu)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(featureId, view, menu);
+ if (res.invoked)
+ return (Boolean)res.methodReturns;
+ else
+ return super.onPreparePanel(featureId, view, menu);
+ }
+ public boolean super_onPreparePanel(int featureId, View view, Menu menu)
+ {
+ return super.onPreparePanel(featureId, view, menu);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onRestart()
+ {
+ super.onRestart();
+ QtApplication.invokeDelegate();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onRestoreInstanceState(Bundle savedInstanceState)
+ {
+ if (!QtApplication.invokeDelegate(savedInstanceState).invoked)
+ super.onRestoreInstanceState(savedInstanceState);
+ }
+ public void super_onRestoreInstanceState(Bundle savedInstanceState)
+ {
+ super.onRestoreInstanceState(savedInstanceState);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onResume()
+ {
+ super.onResume();
+ QtApplication.invokeDelegate();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public Object onRetainNonConfigurationInstance()
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate();
+ if (res.invoked)
+ return res.methodReturns;
+ else
+ return super.onRetainNonConfigurationInstance();
+ }
+ public Object super_onRetainNonConfigurationInstance()
+ {
+ return super.onRetainNonConfigurationInstance();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onSaveInstanceState(Bundle outState)
+ {
+ if (!QtApplication.invokeDelegate(outState).invoked)
+ super.onSaveInstanceState(outState);
+ }
+ public void super_onSaveInstanceState(Bundle outState)
+ {
+ super.onSaveInstanceState(outState);
+
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onSearchRequested()
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate();
+ if (res.invoked)
+ return (Boolean)res.methodReturns;
+ else
+ return super.onSearchRequested();
+ }
+ public boolean super_onSearchRequested()
+ {
+ return super.onSearchRequested();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onStart()
+ {
+ super.onStart();
+ QtApplication.invokeDelegate();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onStop()
+ {
+ super.onStop();
+ QtApplication.invokeDelegate();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onTitleChanged(CharSequence title, int color)
+ {
+ if (!QtApplication.invokeDelegate(title, color).invoked)
+ super.onTitleChanged(title, color);
+ }
+ public void super_onTitleChanged(CharSequence title, int color)
+ {
+ super.onTitleChanged(title, color);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onTouchEvent(MotionEvent event)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.onTouchEvent != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.onTouchEvent, event);
+ else
+ return super.onTouchEvent(event);
+ }
+ public boolean super_onTouchEvent(MotionEvent event)
+ {
+ return super.onTouchEvent(event);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onTrackballEvent(MotionEvent event)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.onTrackballEvent != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.onTrackballEvent, event);
+ else
+ return super.onTrackballEvent(event);
+ }
+ public boolean super_onTrackballEvent(MotionEvent event)
+ {
+ return super.onTrackballEvent(event);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onUserInteraction()
+ {
+ if (!QtApplication.invokeDelegate().invoked)
+ super.onUserInteraction();
+ }
+ public void super_onUserInteraction()
+ {
+ super.onUserInteraction();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onUserLeaveHint()
+ {
+ if (!QtApplication.invokeDelegate().invoked)
+ super.onUserLeaveHint();
+ }
+ public void super_onUserLeaveHint()
+ {
+ super.onUserLeaveHint();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onWindowAttributesChanged(LayoutParams params)
+ {
+ if (!QtApplication.invokeDelegate(params).invoked)
+ super.onWindowAttributesChanged(params);
+ }
+ public void super_onWindowAttributesChanged(LayoutParams params)
+ {
+ super.onWindowAttributesChanged(params);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onWindowFocusChanged(boolean hasFocus)
+ {
+ if (!QtApplication.invokeDelegate(hasFocus).invoked)
+ super.onWindowFocusChanged(hasFocus);
+ }
+ public void super_onWindowFocusChanged(boolean hasFocus)
+ {
+ super.onWindowFocusChanged(hasFocus);
+ }
+ //---------------------------------------------------------------------------
+
+ //////////////// Activity API 5 /////////////
+//@ANDROID-5
+ @Override
+ public void onAttachedToWindow()
+ {
+ if (!QtApplication.invokeDelegate().invoked)
+ super.onAttachedToWindow();
+ }
+ public void super_onAttachedToWindow()
+ {
+ super.onAttachedToWindow();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onBackPressed()
+ {
+ if (!QtApplication.invokeDelegate().invoked)
+ super.onBackPressed();
+ }
+ public void super_onBackPressed()
+ {
+ super.onBackPressed();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onDetachedFromWindow()
+ {
+ if (!QtApplication.invokeDelegate().invoked)
+ super.onDetachedFromWindow();
+ }
+ public void super_onDetachedFromWindow()
+ {
+ super.onDetachedFromWindow();
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onKeyLongPress(int keyCode, KeyEvent event)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.onKeyLongPress != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.onKeyLongPress, keyCode, event);
+ else
+ return super.onKeyLongPress(keyCode, event);
+ }
+ public boolean super_onKeyLongPress(int keyCode, KeyEvent event)
+ {
+ return super.onKeyLongPress(keyCode, event);
+ }
+ //---------------------------------------------------------------------------
+//@ANDROID-5
+
+//////////////// Activity API 8 /////////////
+//@ANDROID-8
+@Override
+ protected Dialog onCreateDialog(int id, Bundle args)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(id, args);
+ if (res.invoked)
+ return (Dialog)res.methodReturns;
+ else
+ return super.onCreateDialog(id, args);
+ }
+ public Dialog super_onCreateDialog(int id, Bundle args)
+ {
+ return super.onCreateDialog(id, args);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ protected void onPrepareDialog(int id, Dialog dialog, Bundle args)
+ {
+ if (!QtApplication.invokeDelegate(id, dialog, args).invoked)
+ super.onPrepareDialog(id, dialog, args);
+ }
+ public void super_onPrepareDialog(int id, Dialog dialog, Bundle args)
+ {
+ super.onPrepareDialog(id, dialog, args);
+ }
+ //---------------------------------------------------------------------------
+//@ANDROID-8
+ //////////////// Activity API 11 /////////////
+
+//@ANDROID-11
+ @Override
+ public boolean dispatchKeyShortcutEvent(KeyEvent event)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.dispatchKeyShortcutEvent != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.dispatchKeyShortcutEvent, event);
+ else
+ return super.dispatchKeyShortcutEvent(event);
+ }
+ public boolean super_dispatchKeyShortcutEvent(KeyEvent event)
+ {
+ return super.dispatchKeyShortcutEvent(event);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onActionModeFinished(ActionMode mode)
+ {
+ if (!QtApplication.invokeDelegate(mode).invoked)
+ super.onActionModeFinished(mode);
+ }
+ public void super_onActionModeFinished(ActionMode mode)
+ {
+ super.onActionModeFinished(mode);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onActionModeStarted(ActionMode mode)
+ {
+ if (!QtApplication.invokeDelegate(mode).invoked)
+ super.onActionModeStarted(mode);
+ }
+ public void super_onActionModeStarted(ActionMode mode)
+ {
+ super.onActionModeStarted(mode);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public void onAttachFragment(Fragment fragment)
+ {
+ if (!QtApplication.invokeDelegate(fragment).invoked)
+ super.onAttachFragment(fragment);
+ }
+ public void super_onAttachFragment(Fragment fragment)
+ {
+ super.onAttachFragment(fragment);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public View onCreateView(View parent, String name, Context context, AttributeSet attrs)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(parent, name, context, attrs);
+ if (res.invoked)
+ return (View)res.methodReturns;
+ else
+ return super.onCreateView(parent, name, context, attrs);
+ }
+ public View super_onCreateView(View parent, String name, Context context,
+ AttributeSet attrs) {
+ return super.onCreateView(parent, name, context, attrs);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onKeyShortcut(int keyCode, KeyEvent event)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.onKeyShortcut != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.onKeyShortcut, keyCode,event);
+ else
+ return super.onKeyShortcut(keyCode, event);
+ }
+ public boolean super_onKeyShortcut(int keyCode, KeyEvent event)
+ {
+ return super.onKeyShortcut(keyCode, event);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public ActionMode onWindowStartingActionMode(Callback callback)
+ {
+ QtApplication.InvokeResult res = QtApplication.invokeDelegate(callback);
+ if (res.invoked)
+ return (ActionMode)res.methodReturns;
+ else
+ return super.onWindowStartingActionMode(callback);
+ }
+ public ActionMode super_onWindowStartingActionMode(Callback callback)
+ {
+ return super.onWindowStartingActionMode(callback);
+ }
+ //---------------------------------------------------------------------------
+//@ANDROID-11
+ //////////////// Activity API 12 /////////////
+
+//@ANDROID-12
+ @Override
+ public boolean dispatchGenericMotionEvent(MotionEvent ev)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.dispatchGenericMotionEvent != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.dispatchGenericMotionEvent, ev);
+ else
+ return super.dispatchGenericMotionEvent(ev);
+ }
+ public boolean super_dispatchGenericMotionEvent(MotionEvent event)
+ {
+ return super.dispatchGenericMotionEvent(event);
+ }
+ //---------------------------------------------------------------------------
+
+ @Override
+ public boolean onGenericMotionEvent(MotionEvent event)
+ {
+ if (QtApplication.m_delegateObject != null && QtApplication.onGenericMotionEvent != null)
+ return (Boolean) QtApplication.invokeDelegateMethod(QtApplication.onGenericMotionEvent, event);
+ else
+ return super.onGenericMotionEvent(event);
+ }
+ public boolean super_onGenericMotionEvent(MotionEvent event)
+ {
+ return super.onGenericMotionEvent(event);
+ }
+ //---------------------------------------------------------------------------
+//@ANDROID-12
+
+}
diff --git a/src/android/java/src/org/qtproject/qt5/android/bindings/QtApplication.java b/src/android/java/src/org/qtproject/qt5/android/bindings/QtApplication.java
new file mode 100644
index 0000000000..4de1c833f5
--- /dev/null
+++ b/src/android/java/src/org/qtproject/qt5/android/bindings/QtApplication.java
@@ -0,0 +1,149 @@
+/*
+ Copyright (c) 2012-2013, BogDan Vatra <bogdan@kde.org>
+ Contact: http://www.qt-project.org/legal
+
+ 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 AUTHOR ``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 AUTHOR 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.
+*/
+
+package org.qtproject.qt5.android.bindings;
+
+import java.lang.reflect.Field;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.HashMap;
+
+import android.app.Application;
+
+public class QtApplication extends Application
+{
+ public final static String QtTAG = "Qt";
+ public static Object m_delegateObject = null;
+ public static HashMap<String, ArrayList<Method>> m_delegateMethods= new HashMap<String, ArrayList<Method>>();
+ public static Method dispatchKeyEvent = null;
+ public static Method dispatchPopulateAccessibilityEvent = null;
+ public static Method dispatchTouchEvent = null;
+ public static Method dispatchTrackballEvent = null;
+ public static Method onKeyDown = null;
+ public static Method onKeyMultiple = null;
+ public static Method onKeyUp = null;
+ public static Method onTouchEvent = null;
+ public static Method onTrackballEvent = null;
+ public static Method onActivityResult = null;
+ public static Method onCreate = null;
+ public static Method onKeyLongPress = null;
+ public static Method dispatchKeyShortcutEvent = null;
+ public static Method onKeyShortcut = null;
+ public static Method dispatchGenericMotionEvent = null;
+ public static Method onGenericMotionEvent = null;
+
+ public static void setQtActivityDelegate(Object listener)
+ {
+ QtApplication.m_delegateObject = listener;
+
+ ArrayList<Method> delegateMethods = new ArrayList<Method>();
+ for (Method m : listener.getClass().getMethods()) {
+ if (m.getDeclaringClass().getName().startsWith("org.qtproject.qt5.android"))
+ delegateMethods.add(m);
+ }
+
+ ArrayList<Field> applicationFields = new ArrayList<Field>();
+ for (Field f : QtApplication.class.getFields()) {
+ if (f.getDeclaringClass().getName().equals(QtApplication.class.getName()))
+ applicationFields.add(f);
+ }
+
+ for (Method delegateMethod : delegateMethods) {
+ try {
+ QtActivity.class.getDeclaredMethod(delegateMethod.getName(), delegateMethod.getParameterTypes());
+ if (QtApplication.m_delegateMethods.containsKey(delegateMethod.getName())) {
+ QtApplication.m_delegateMethods.get(delegateMethod.getName()).add(delegateMethod);
+ } else {
+ ArrayList<Method> delegateSet = new ArrayList<Method>();
+ delegateSet.add(delegateMethod);
+ QtApplication.m_delegateMethods.put(delegateMethod.getName(), delegateSet);
+ }
+ for (Field applicationField:applicationFields) {
+ if (applicationField.getName().equals(delegateMethod.getName())) {
+ try {
+ applicationField.set(null, delegateMethod);
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+ }
+ }
+ } catch (Exception e) {
+ }
+ }
+ }
+
+ @Override
+ public void onTerminate() {
+ if (m_delegateObject != null && m_delegateMethods.containsKey("onTerminate"))
+ invokeDelegateMethod(m_delegateMethods.get("onTerminate").get(0));
+ super.onTerminate();
+ }
+
+ public static class InvokeResult
+ {
+ public boolean invoked = false;
+ public Object methodReturns = null;
+ }
+
+ private static int stackDeep=-1;
+ public static InvokeResult invokeDelegate(Object... args)
+ {
+ InvokeResult result = new InvokeResult();
+ if (m_delegateObject == null)
+ return result;
+ StackTraceElement[] elements = Thread.currentThread().getStackTrace();
+ if (-1 == stackDeep) {
+ String activityClassName = QtActivity.class.getCanonicalName();
+ for (int it=0;it<elements.length;it++)
+ if (elements[it].getClassName().equals(activityClassName)) {
+ stackDeep = it;
+ break;
+ }
+ }
+ final String methodName=elements[stackDeep].getMethodName();
+ if (-1 == stackDeep || !m_delegateMethods.containsKey(methodName))
+ return result;
+
+ for (Method m : m_delegateMethods.get(methodName)) {
+ if (m.getParameterTypes().length == args.length) {
+ result.methodReturns = invokeDelegateMethod(m, args);
+ result.invoked = true;
+ return result;
+ }
+ }
+ return result;
+ }
+
+ public static Object invokeDelegateMethod(Method m, Object... args)
+ {
+ try {
+ return m.invoke(m_delegateObject, args);
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+ return null;
+ }
+}
diff --git a/src/android/java/version.xml b/src/android/java/version.xml
new file mode 100644
index 0000000000..e709357ba6
--- /dev/null
+++ b/src/android/java/version.xml
@@ -0,0 +1,8 @@
+<version value="5">
+ <ignore>
+ <file>AndroidManifest.xml</file>
+ <file>libs.xml</file>
+ <file>logo.png</file>
+ <file>icon.png</file>
+ </ignore>
+</version>
diff --git a/src/angle/angle.pro b/src/angle/angle.pro
index b4dbf8cf21..721caf880a 100644
--- a/src/angle/angle.pro
+++ b/src/angle/angle.pro
@@ -1,19 +1,10 @@
TEMPLATE = subdirs
SUBDIRS += src
-# We need to call syncqt manually instead of using "load(qt_module_headers)" for several reasons:
+# We do it this way instead of letting load(qt_module) handle it for two reasons:
# 1) qt_module_headers assumes the TARGET is the same as the include directory (eg: libGLESv2 != GLES2)
# 2) If we made a 'QtANGLE' module, the include directory would be flattened which won't work since
# we need to support "#include <GLES2/gl2.h>"
-!build_pass {
- qtPrepareTool(QMAKE_SYNCQT, syncqt)
- QTDIR = $$[QT_HOST_PREFIX]
- exists($$QTDIR/.qmake.cache): \
- mod_component_base = $$QTDIR
- else: \
- mod_component_base = $$dirname(_QMAKE_CACHE_)
- QMAKE_SYNCQT += -minimal -module KHR -module EGL -module GLES2 \
- -version none -outdir $$mod_component_base $$dirname(_QMAKE_CONF_)
- !silent:message($$QMAKE_SYNCQT)
- system($$QMAKE_SYNCQT)|error("Failed to run: $$QMAKE_SYNCQT")
-}
+CONFIG += minimal_syncqt
+QMAKE_SYNCQT_OPTIONS = -module KHR -module EGL -module GLES2 -version none
+load(qt_module_headers)
diff --git a/src/angle/patches/0001-Dynamically-resolve-functions-of-dwmapi.dll.patch b/src/angle/patches/0001-Dynamically-resolve-functions-of-dwmapi.dll.patch
index f58cfe2d03..b259aa3f80 100644
--- a/src/angle/patches/0001-Dynamically-resolve-functions-of-dwmapi.dll.patch
+++ b/src/angle/patches/0001-Dynamically-resolve-functions-of-dwmapi.dll.patch
@@ -1,7 +1,7 @@
-From a5ed22f7c9aa51eebbd3ec48904a4c0999dcced6 Mon Sep 17 00:00:00 2001
-From: Friedemann Kleint <Friedemann.Kleint@digia.com>
-Date: Tue, 6 Nov 2012 09:22:18 +0100
-Subject: [PATCH] Dynamically resolve functions of dwmapi.dll.
+From 211954dffc6a0ee52db130017ae4bea00e80748f Mon Sep 17 00:00:00 2001
+From: Friedemann Kleint <Friedemann.Klient@digia.com>
+Date: Mon, 18 Mar 2013 15:35:13 +0200
+Subject: [PATCH 1/6] Dynamically resolve functions of dwmapi.dll.
The library is not present on Windows XP, for which /DELAYLOAD
is used in ANGLE. However, as this causes problems with MinGW,
@@ -10,24 +10,24 @@ use dynamic resolution.
Task-number: QTBUG-27741
Change-Id: I16214d6f98a184d89858c50ee5306371ea25469e
---
- src/3rdparty/angle/src/libEGL/Surface.cpp | 39 +++++++++++++++++++++--------
+ src/3rdparty/angle/src/libEGL/Surface.cpp | 39 ++++++++++++++++++++++++++++-----------
1 file changed, 28 insertions(+), 11 deletions(-)
diff --git a/src/3rdparty/angle/src/libEGL/Surface.cpp b/src/3rdparty/angle/src/libEGL/Surface.cpp
-index 732c404..34df14c 100644
+index 78203b0..5ece724 100644
--- a/src/3rdparty/angle/src/libEGL/Surface.cpp
+++ b/src/3rdparty/angle/src/libEGL/Surface.cpp
-@@ -73,6 +73,9 @@ Surface::~Surface()
+@@ -71,6 +71,9 @@ Surface::~Surface()
bool Surface::initialize()
{
+ typedef HRESULT (STDAPICALLTYPE *PtrDwmIsCompositionEnabled)(BOOL*);
+ typedef HRESULT (STDAPICALLTYPE *PtrDwmSetPresentParameters)(HWND, DWM_PRESENT_PARAMETERS *);
+
- ASSERT(!mSwapChain && !mOffscreenTexture && !mDepthStencil);
-
if (!resetSwapChain())
-@@ -82,17 +85,31 @@ bool Surface::initialize()
+ return false;
+
+@@ -78,17 +81,31 @@ bool Surface::initialize()
// to minimize the amount of queuing done by DWM between our calls to
// present and the actual screen.
if (mWindow && (getComparableOSVersion() >= versionWindowsVista)) {
@@ -71,5 +71,5 @@ index 732c404..34df14c 100644
}
--
-1.7.10.msysgit.1
+1.8.1.msysgit.1
diff --git a/src/angle/patches/0001-Make-it-possible-to-link-ANGLE-statically-for-single.patch b/src/angle/patches/0001-Make-it-possible-to-link-ANGLE-statically-for-single.patch
new file mode 100644
index 0000000000..9133ac73ae
--- /dev/null
+++ b/src/angle/patches/0001-Make-it-possible-to-link-ANGLE-statically-for-single.patch
@@ -0,0 +1,218 @@
+From cbe9afef7cd467c41353e8a41544d86807be7dd2 Mon Sep 17 00:00:00 2001
+From: Friedemann Kleint <Friedemann.Kleint@digia.com>
+Date: Thu, 14 Feb 2013 09:40:30 +0100
+Subject: [PATCH] Make it possible to link ANGLE statically for single-thread
+ use.
+
+Fix exports and provide static instances of thread-local
+data depending on QT_OPENGL_ES_2_ANGLE_STATIC.
+
+Change-Id: Ifab25a820adf5953bb3b09036de53dbf7f1a7fd5
+---
+ src/3rdparty/angle/include/KHR/khrplatform.h | 3 +-
+ src/3rdparty/angle/src/libEGL/main.cpp | 58 ++++++++++++++--------------
+ src/3rdparty/angle/src/libGLESv2/main.cpp | 32 ++++++++++-----
+ 3 files changed, 53 insertions(+), 40 deletions(-)
+
+diff --git a/src/3rdparty/angle/include/KHR/khrplatform.h b/src/3rdparty/angle/include/KHR/khrplatform.h
+index 56c676c..18a104e 100644
+--- a/src/3rdparty/angle/include/KHR/khrplatform.h
++++ b/src/3rdparty/angle/include/KHR/khrplatform.h
+@@ -97,7 +97,8 @@
+ *-------------------------------------------------------------------------
+ * This precedes the return type of the function in the function prototype.
+ */
+-#if defined(_WIN32) && !defined(__SCITECH_SNAP__)
++
++#if defined(_WIN32) && !defined(__SCITECH_SNAP__) && !defined(QT_OPENGL_ES_2_ANGLE_STATIC)
+ # define KHRONOS_APICALL __declspec(dllimport)
+ #elif defined (__SYMBIAN32__)
+ # define KHRONOS_APICALL IMPORT_C
+diff --git a/src/3rdparty/angle/src/libEGL/main.cpp b/src/3rdparty/angle/src/libEGL/main.cpp
+index dc24c4f..614bcf6 100644
+--- a/src/3rdparty/angle/src/libEGL/main.cpp
++++ b/src/3rdparty/angle/src/libEGL/main.cpp
+@@ -10,6 +10,8 @@
+
+ #include "common/debug.h"
+
++#ifndef QT_OPENGL_ES_2_ANGLE_STATIC
++
+ static DWORD currentTLS = TLS_OUT_OF_INDEXES;
+
+ extern "C" BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, LPVOID reserved)
+@@ -86,76 +88,72 @@ extern "C" BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, LPVOID reserved
+ return TRUE;
+ }
+
++static inline egl::Current *current()
++{
++ return (egl::Current*)TlsGetValue(currentTLS);
++}
++
++#else // !QT_OPENGL_ES_2_ANGLE_STATIC
++
++static egl::Current *current()
++{
++ // No precautions for thread safety taken as ANGLE is used single-threaded in Qt.
++ static egl::Current curr = { EGL_SUCCESS, EGL_OPENGL_ES_API, EGL_NO_DISPLAY, EGL_NO_SURFACE, EGL_NO_SURFACE };
++ return &curr;
++}
++
++#endif // QT_OPENGL_ES_2_ANGLE_STATIC
++
+ namespace egl
+ {
+ void setCurrentError(EGLint error)
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
+-
+- current->error = error;
++ current()->error = error;
+ }
+
+ EGLint getCurrentError()
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
+-
+- return current->error;
++ return current()->error;
+ }
+
+ void setCurrentAPI(EGLenum API)
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
+-
+- current->API = API;
++ current()->API = API;
+ }
+
+ EGLenum getCurrentAPI()
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
+-
+- return current->API;
++ return current()->API;
+ }
+
+ void setCurrentDisplay(EGLDisplay dpy)
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
+-
+- current->display = dpy;
++ current()->display = dpy;
+ }
+
+ EGLDisplay getCurrentDisplay()
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
+-
+- return current->display;
++ return current()->display;
+ }
+
+ void setCurrentDrawSurface(EGLSurface surface)
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
+-
+- current->drawSurface = surface;
++ current()->drawSurface = surface;
+ }
+
+ EGLSurface getCurrentDrawSurface()
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
+-
+- return current->drawSurface;
++ return current()->drawSurface;
+ }
+
+ void setCurrentReadSurface(EGLSurface surface)
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
+-
+- current->readSurface = surface;
++ current()->readSurface = surface;
+ }
+
+ EGLSurface getCurrentReadSurface()
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
+-
+- return current->readSurface;
++ return current()->readSurface;
+ }
+ }
+
+diff --git a/src/3rdparty/angle/src/libGLESv2/main.cpp b/src/3rdparty/angle/src/libGLESv2/main.cpp
+index 6e678c2..3853e41 100644
+--- a/src/3rdparty/angle/src/libGLESv2/main.cpp
++++ b/src/3rdparty/angle/src/libGLESv2/main.cpp
+@@ -14,6 +14,8 @@
+
+ #include "libGLESv2/Framebuffer.h"
+
++#ifndef QT_OPENGL_ES_2_ANGLE_STATIC
++
+ static DWORD currentTLS = TLS_OUT_OF_INDEXES;
+
+ extern "C" BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, LPVOID reserved)
+@@ -72,14 +74,30 @@ extern "C" BOOL WINAPI DllMain(HINSTANCE instance, DWORD reason, LPVOID reserved
+ return TRUE;
+ }
+
++static gl::Current *current()
++{
++ return (gl::Current*)TlsGetValue(currentTLS);
++}
++
++#else // !QT_OPENGL_ES_2_ANGLE_STATIC
++
++static inline gl::Current *current()
++{
++ // No precautions for thread safety taken as ANGLE is used single-threaded in Qt.
++ static gl::Current curr = { 0, 0 };
++ return &curr;
++}
++
++#endif // QT_OPENGL_ES_2_ANGLE_STATIC
++
+ namespace gl
+ {
+ void makeCurrent(Context *context, egl::Display *display, egl::Surface *surface)
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
++ Current *curr = current();
+
+- current->context = context;
+- current->display = display;
++ curr->context = context;
++ curr->display = display;
+
+ if (context && display && surface)
+ {
+@@ -89,9 +107,7 @@ void makeCurrent(Context *context, egl::Display *display, egl::Surface *surface)
+
+ Context *getContext()
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
+-
+- return current->context;
++ return current()->context;
+ }
+
+ Context *getNonLostContext()
+@@ -115,9 +131,7 @@ Context *getNonLostContext()
+
+ egl::Display *getDisplay()
+ {
+- Current *current = (Current*)TlsGetValue(currentTLS);
+-
+- return current->display;
++ return current()->display;
+ }
+
+ IDirect3DDevice9 *getDevice()
+--
+1.8.0.msysgit.0
+
diff --git a/src/angle/patches/0003-Fix-Float16ToFloat32.py.patch b/src/angle/patches/0003-Fix-Float16ToFloat32.py.patch
deleted file mode 100644
index c37ab43fb9..0000000000
--- a/src/angle/patches/0003-Fix-Float16ToFloat32.py.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-From e4f894847ebefe54f9a9f9911c38dc3efe77c260 Mon Sep 17 00:00:00 2001
-From: Jason Barron <jason.barron@digia.com>
-Date: Tue, 16 Oct 2012 10:34:32 +0200
-Subject: [PATCH 3/3] Fix Float16ToFloat32.py.
-
-To ensure generation of compilable code, the script should
-be using the alternate form of the hex string formatter to
-be sure it gets prefixed by '0x'.
-
-Also remove an extra '=' character.
-
-This issue has been reported upstream to the ANGLE team:
-
- http://code.google.com/p/angleproject/issues/detail?id=376
-
-Change-Id: I8ccf017afcfbd2c2f52ed291b89f29ba597c9c41
----
- src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.py | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.py b/src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.py
-index ae646ff..fb2964e 100644
---- a/src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.py
-+++ b/src/3rdparty/angle/src/libGLESv2/Float16ToFloat32.py
-@@ -56,22 +56,22 @@ namespace gl
-
- print "const static unsigned g_mantissa[2048] = {"
- for i in range(0, 2048):
-- print " %08x," % convertMantissa(i)
-+ print " %#10x," % convertMantissa(i)
- print "};\n"
-
- print "const static unsigned g_exponent[64] = {"
- for i in range(0, 64):
-- print " %08x," % convertExponent(i)
-+ print " %#10x," % convertExponent(i)
- print "};\n"
-
- print "const static unsigned g_offset[64] = {"
- for i in range(0, 64):
-- print " %08x," % convertOffset(i)
-+ print " %#10x," % convertOffset(i)
- print "};\n"
-
- print """float float16ToFloat32(unsigned short h)
- {
-- unsigned i32 = =g_mantissa[g_offset[h >> 10] + (h & 0x3ff)] + g_exponent[h >> 10];
-+ unsigned i32 = g_mantissa[g_offset[h >> 10] + (h & 0x3ff)] + g_exponent[h >> 10];
- return *(float*) &i32;
- }
- }
---
-1.7.11.msysgit.1
-
diff --git a/src/angle/patches/0004-Fix-black-screen-after-minimizing-OpenGL-window-with.patch b/src/angle/patches/0004-Fix-black-screen-after-minimizing-OpenGL-window-with.patch
index 372b9238af..29852c57fa 100644
--- a/src/angle/patches/0004-Fix-black-screen-after-minimizing-OpenGL-window-with.patch
+++ b/src/angle/patches/0004-Fix-black-screen-after-minimizing-OpenGL-window-with.patch
@@ -1,7 +1,8 @@
-From 85e9ba49580e307e1213c87cdbfdc301848f497f Mon Sep 17 00:00:00 2001
+From 0b8f4889511d7aa8f9f07b16dbf204f378e127a6 Mon Sep 17 00:00:00 2001
From: Miikka Heikkinen <miikka.heikkinen@digia.com>
-Date: Tue, 20 Nov 2012 13:23:27 +0200
-Subject: [PATCH] Fix black screen after minimizing OpenGL window with ANGLE
+Date: Mon, 18 Mar 2013 16:27:07 +0200
+Subject: [PATCH 3/6] Fix black screen after minimizing OpenGL window with
+ ANGLE
CreateTexture will fail on zero dimensions, so just release old target
and reset dimensions when resetSwapChain is called with zero size area.
@@ -10,14 +11,14 @@ Task-number: QTBUG-27994
Change-Id: I1e500c4fd4b92f7d9ea2a49a44f3fb930b575cd1
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
---
- src/3rdparty/angle/src/libEGL/Surface.cpp | 16 ++++++++++++++++
- 1 files changed, 16 insertions(+), 0 deletions(-)
+ src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.cpp | 15 +++++++++++++++
+ 1 file changed, 15 insertions(+)
-diff --git a/src/3rdparty/angle/src/libEGL/Surface.cpp b/src/3rdparty/angle/src/libEGL/Surface.cpp
-index 8e920ab..174b403 100644
---- a/src/3rdparty/angle/src/libEGL/Surface.cpp
-+++ b/src/3rdparty/angle/src/libEGL/Surface.cpp
-@@ -224,6 +224,22 @@ bool Surface::resetSwapChain(int backbufferWidth, int backbufferHeight)
+diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.cpp
+index 0324d01..f57a874 100644
+--- a/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.cpp
++++ b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain9.cpp
+@@ -137,6 +137,21 @@ EGLint SwapChain9::reset(int backbufferWidth, int backbufferHeight, EGLint swapI
pShareHandle = &mShareHandle;
}
@@ -32,14 +33,13 @@ index 8e920ab..174b403 100644
+
+ mWidth = backbufferWidth;
+ mHeight = backbufferHeight;
-+ mPresentIntervalDirty = false;
+
-+ return true;
++ return EGL_SUCCESS;
+ }
+
result = device->CreateTexture(backbufferWidth, backbufferHeight, 1, D3DUSAGE_RENDERTARGET,
- mConfig->mRenderTargetFormat, D3DPOOL_DEFAULT, &mOffscreenTexture, pShareHandle);
- if (FAILED(result))
+ gl_d3d9::ConvertRenderbufferFormat(mBackBufferFormat), D3DPOOL_DEFAULT,
+ &mOffscreenTexture, pShareHandle);
--
-1.7.4.msysgit.0
+1.8.1.msysgit.1
diff --git a/src/angle/patches/0005-Fix-build-when-SSE2-is-not-available.patch b/src/angle/patches/0005-Fix-build-when-SSE2-is-not-available.patch
index 7519e3ba63..72211aeee0 100644
--- a/src/angle/patches/0005-Fix-build-when-SSE2-is-not-available.patch
+++ b/src/angle/patches/0005-Fix-build-when-SSE2-is-not-available.patch
@@ -1,7 +1,7 @@
-From 45a06cc846dbe451bf42c5b3f617729f208743b1 Mon Sep 17 00:00:00 2001
+From 61abac6f8da2ed1ca3ab74c8c65e5fd1be3d85ad Mon Sep 17 00:00:00 2001
From: Andy Shaw <andy.shaw@digia.com>
-Date: Wed, 28 Nov 2012 15:38:58 +0100
-Subject: [PATCH] Fix build when SSE2 is not available.
+Date: Mon, 18 Mar 2013 16:36:40 +0200
+Subject: [PATCH 4/6] Fix build when SSE2 is not available.
Although SSE2 support is detected at runtime it still may not be
available at build time, so we have to ensure it only uses SSE2
@@ -9,41 +9,41 @@ when it is available at build time too.
Change-Id: I86c45a6466ab4cec79aa0f62b0d5230a78ad825a
---
- src/3rdparty/angle/src/libGLESv2/Texture.cpp | 4 ++++
- 1 files changed, 4 insertions(+), 0 deletions(-)
+ src/3rdparty/angle/src/libGLESv2/renderer/Image9.cpp | 4 ++++
+ 1 file changed, 4 insertions(+)
-diff --git a/src/3rdparty/angle/src/libGLESv2/Texture.cpp b/src/3rdparty/angle/src/libGLESv2/Texture.cpp
-index af430bf..0ea475d 100644
---- a/src/3rdparty/angle/src/libGLESv2/Texture.cpp
-+++ b/src/3rdparty/angle/src/libGLESv2/Texture.cpp
-@@ -378,11 +378,13 @@ void Image::loadData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height
+diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Image9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Image9.cpp
+index b3dcc59..53030b7 100644
+--- a/src/3rdparty/angle/src/libGLESv2/renderer/Image9.cpp
++++ b/src/3rdparty/angle/src/libGLESv2/renderer/Image9.cpp
+@@ -373,11 +373,13 @@ void Image9::loadData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei heigh
switch (mInternalFormat)
{
case GL_ALPHA8_EXT:
+#if defined(__SSE2__)
- if (supportsSSE2())
+ if (gl::supportsSSE2())
{
- loadAlphaDataSSE2(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ loadAlphaDataToBGRASSE2(width, height, inputPitch, input, locked.Pitch, locked.pBits);
}
else
+#endif
{
- loadAlphaData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ loadAlphaDataToBGRA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
}
-@@ -418,11 +420,13 @@ void Image::loadData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei height
- loadRGB565Data(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+@@ -413,11 +415,13 @@ void Image9::loadData(GLint xoffset, GLint yoffset, GLsizei width, GLsizei heigh
+ loadRGB565DataToBGRA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
break;
case GL_RGBA8_OES:
+#if defined(__SSE2__)
- if (supportsSSE2())
+ if (gl::supportsSSE2())
{
- loadRGBAUByteDataSSE2(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ loadRGBAUByteDataToBGRASSE2(width, height, inputPitch, input, locked.Pitch, locked.pBits);
}
else
+#endif
{
- loadRGBAUByteData(width, height, inputPitch, input, locked.Pitch, locked.pBits);
+ loadRGBAUByteDataToBGRA(width, height, inputPitch, input, locked.Pitch, locked.pBits);
}
---
-1.7.9.msysgit.0
+--
+1.8.1.msysgit.1
diff --git a/src/angle/patches/0006-ANGLE-Do-not-reset-the-share-handle-when-resetting-t.patch b/src/angle/patches/0006-ANGLE-Do-not-reset-the-share-handle-when-resetting-t.patch
deleted file mode 100644
index 7d4c7af3f8..0000000000
--- a/src/angle/patches/0006-ANGLE-Do-not-reset-the-share-handle-when-resetting-t.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 7a2483c26eebf1c06924143108186eae59d85d98 Mon Sep 17 00:00:00 2001
-From: Zeno Albisser <zeno@webkit.org>
-Date: Fri, 30 Nov 2012 13:20:44 +0100
-Subject: [PATCH] ANGLE: Do not reset the share handle when resetting the swap
- chain.
-
-This change only affects the ANGLE_surface_d3d_texture_2d_share_handle
-extension. The patch is necessary to have WebGL running in Qt/WebKit2.
-
-If the share handle is reset, we are loosing the reference to the
-EGLSurface and cannot actually reuse it in a different context anymore.
-
-Change-Id: I0138432dd8ff60ea57e7e591cfa2f8db1d324f53
----
- src/3rdparty/angle/src/libEGL/Surface.cpp | 1 -
- 1 file changed, 1 deletion(-)
-
-diff --git a/src/3rdparty/angle/src/libEGL/Surface.cpp b/src/3rdparty/angle/src/libEGL/Surface.cpp
-index 174b403..d9e1887 100644
---- a/src/3rdparty/angle/src/libEGL/Surface.cpp
-+++ b/src/3rdparty/angle/src/libEGL/Surface.cpp
-@@ -217,7 +217,6 @@ bool Surface::resetSwapChain(int backbufferWidth, int backbufferHeight)
- mDepthStencil = NULL;
- }
-
-- mShareHandle = NULL;
- HANDLE *pShareHandle = NULL;
- if (!mWindow && mDisplay->shareHandleSupported())
- {
---
-1.7.9.5
-
diff --git a/src/angle/patches/0006-Make-DX9-DX11-mutually-exclusive.patch b/src/angle/patches/0006-Make-DX9-DX11-mutually-exclusive.patch
new file mode 100644
index 0000000000..1e7ab82771
--- /dev/null
+++ b/src/angle/patches/0006-Make-DX9-DX11-mutually-exclusive.patch
@@ -0,0 +1,140 @@
+From a5c113dda327ad3015312c2836b794929d4771ff Mon Sep 17 00:00:00 2001
+From: Andrew Knight <andrew.knight@digia.com>
+Date: Thu, 21 Mar 2013 17:12:02 +0200
+Subject: [PATCH 5/6] Make DX9/DX11 mutually exclusive
+
+ANGLE dx11proto supports DX9 fallback when DX11 is unavailable. This
+patch removes the fallback mechanism and requires that the library be
+chosen at build time (by defining ANGLE_ENABLE_D3D11). This is required
+for WinRT, because d3d9 is not a support library on that platform.
+---
+ src/3rdparty/angle/src/common/RefCountObject.cpp | 1 -
+ src/3rdparty/angle/src/common/debug.cpp | 4 ++++
+ src/3rdparty/angle/src/libGLESv2/Texture.cpp | 6 +++++-
+ src/3rdparty/angle/src/libGLESv2/precompiled.h | 9 ++++++---
+ src/3rdparty/angle/src/libGLESv2/renderer/Renderer.cpp | 37 +++++++++++--------------------------
+ 5 files changed, 26 insertions(+), 31 deletions(-)
+
+diff --git a/src/3rdparty/angle/src/common/RefCountObject.cpp b/src/3rdparty/angle/src/common/RefCountObject.cpp
+index 0364adf..c1ef90c 100644
+--- a/src/3rdparty/angle/src/common/RefCountObject.cpp
++++ b/src/3rdparty/angle/src/common/RefCountObject.cpp
+@@ -1,4 +1,3 @@
+-#include "precompiled.h"
+ //
+ // Copyright (c) 2002-2010 The ANGLE Project Authors. All rights reserved.
+ // Use of this source code is governed by a BSD-style license that can be
+diff --git a/src/3rdparty/angle/src/common/debug.cpp b/src/3rdparty/angle/src/common/debug.cpp
+index 2333740..438d397 100644
+--- a/src/3rdparty/angle/src/common/debug.cpp
++++ b/src/3rdparty/angle/src/common/debug.cpp
+@@ -8,7 +8,11 @@
+
+ #include "common/debug.h"
+ #include "common/system.h"
++#ifdef ANGLE_ENABLE_D3D11
++typedef DWORD D3DCOLOR;
++#else
+ #include <d3d9.h>
++#endif
+
+ namespace gl
+ {
+diff --git a/src/3rdparty/angle/src/libGLESv2/Texture.cpp b/src/3rdparty/angle/src/libGLESv2/Texture.cpp
+index ae83037..461357a 100644
+--- a/src/3rdparty/angle/src/libGLESv2/Texture.cpp
++++ b/src/3rdparty/angle/src/libGLESv2/Texture.cpp
+@@ -14,7 +14,11 @@
+ #include "libGLESv2/main.h"
+ #include "libGLESv2/mathutil.h"
+ #include "libGLESv2/utilities.h"
+-#include "libGLESv2/renderer/Blit.h"
++#if defined(ANGLE_ENABLE_D3D11)
++# define D3DFMT_UNKNOWN DXGI_FORMAT_UNKNOWN
++#else
++# include "libGLESv2/renderer/Blit.h"
++#endif
+ #include "libGLESv2/Renderbuffer.h"
+ #include "libGLESv2/renderer/Image.h"
+ #include "libGLESv2/renderer/Renderer.h"
+diff --git a/src/3rdparty/angle/src/libGLESv2/precompiled.h b/src/3rdparty/angle/src/libGLESv2/precompiled.h
+index a850d57..b8b043c 100644
+--- a/src/3rdparty/angle/src/libGLESv2/precompiled.h
++++ b/src/3rdparty/angle/src/libGLESv2/precompiled.h
+@@ -32,9 +32,12 @@
+ #include <unordered_map>
+ #include <vector>
+
+-#include <d3d9.h>
+-#include <D3D11.h>
+-#include <dxgi.h>
++#if defined(ANGLE_ENABLE_D3D11)
++# include <D3D11.h>
++# include <dxgi.h>
++#else
++# include <d3d9.h>
++#endif
+ #include <D3Dcompiler.h>
+
+ #ifdef _MSC_VER
+diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/Renderer.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer.cpp
+index 8fd3425..64e52c1 100644
+--- a/src/3rdparty/angle/src/libGLESv2/renderer/Renderer.cpp
++++ b/src/3rdparty/angle/src/libGLESv2/renderer/Renderer.cpp
+@@ -10,14 +10,13 @@
+ #include "libGLESv2/main.h"
+ #include "libGLESv2/Program.h"
+ #include "libGLESv2/renderer/Renderer.h"
+-#include "libGLESv2/renderer/Renderer9.h"
+-#include "libGLESv2/renderer/Renderer11.h"
+-#include "libGLESv2/utilities.h"
+-
+-#if !defined(ANGLE_ENABLE_D3D11)
+-// Enables use of the Direct3D 11 API, when available
+-#define ANGLE_ENABLE_D3D11 0
++#if defined(ANGLE_ENABLE_D3D11)
++# include "libGLESv2/renderer/Renderer11.h"
++# define D3DERR_OUTOFVIDEOMEMORY MAKE_HRESULT( 1, 0x876, 380 )
++#else
++# include "libGLESv2/renderer/Renderer9.h"
+ #endif
++#include "libGLESv2/utilities.h"
+
+ #if !defined(ANGLE_COMPILE_OPTIMIZATION_LEVEL)
+ #define ANGLE_COMPILE_OPTIMIZATION_LEVEL D3DCOMPILE_OPTIMIZATION_LEVEL3
+@@ -174,27 +173,13 @@ rx::Renderer *glCreateRenderer(egl::Display *display, HDC hDc, bool softwareDevi
+ {
+ rx::Renderer *renderer = NULL;
+ EGLint status = EGL_BAD_ALLOC;
+-
+- if (ANGLE_ENABLE_D3D11)
+- {
+- renderer = new rx::Renderer11(display, hDc);
+-
+- if (renderer)
+- {
+- status = renderer->initialize();
+- }
+-
+- if (status == EGL_SUCCESS)
+- {
+- return renderer;
+- }
+-
+- // Failed to create a D3D11 renderer, try creating a D3D9 renderer
+- delete renderer;
+- }
+
++#if defined(ANGLE_ENABLE_D3D11)
++ renderer = new rx::Renderer11(display, hDc);
++#else
+ renderer = new rx::Renderer9(display, hDc, softwareDevice);
+-
++#endif
++
+ if (renderer)
+ {
+ status = renderer->initialize();
+--
+1.8.1.msysgit.1
+
diff --git a/src/angle/patches/0007-ANGLE-Fix-typedefs-for-Win64.patch b/src/angle/patches/0007-ANGLE-Fix-typedefs-for-Win64.patch
index ed744bbbd9..63e5bd635b 100644
--- a/src/angle/patches/0007-ANGLE-Fix-typedefs-for-Win64.patch
+++ b/src/angle/patches/0007-ANGLE-Fix-typedefs-for-Win64.patch
@@ -1,21 +1,19 @@
-From cf01d1953de652910734d0e01b032da99194590d Mon Sep 17 00:00:00 2001
+From a8f8f0858f59e6b8e344dfb0bb87e264aac0a13f Mon Sep 17 00:00:00 2001
From: Jonathan Liu <net147@gmail.com>
-Date: Tue, 18 Dec 2012 00:37:11 +1100
-Subject: [PATCH] ANGLE: Fix typedefs for Win64
+Date: Thu, 21 Mar 2013 17:28:54 +0200
+Subject: [PATCH 6/6] ANGLE: Fix typedefs for Win64
The long int type is incorrect for Windows 64-bit as LLP64 is used
there.
-
-Change-Id: If4ccf49d6bb0cd7ba4ff2997cebfdbe5e7e9711c
---
src/3rdparty/angle/include/KHR/khrplatform.h | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/src/3rdparty/angle/include/KHR/khrplatform.h b/src/3rdparty/angle/include/KHR/khrplatform.h
-index 8ec0d19..56c676c 100644
+index b169773..18a104e 100644
--- a/src/3rdparty/angle/include/KHR/khrplatform.h
+++ b/src/3rdparty/angle/include/KHR/khrplatform.h
-@@ -221,10 +221,17 @@ typedef signed char khronos_int8_t;
+@@ -222,10 +222,17 @@ typedef signed char khronos_int8_t;
typedef unsigned char khronos_uint8_t;
typedef signed short int khronos_int16_t;
typedef unsigned short int khronos_uint16_t;
@@ -34,5 +32,5 @@ index 8ec0d19..56c676c 100644
#if KHRONOS_SUPPORT_FLOAT
/*
--
-1.8.0.1
+1.8.1.msysgit.1
diff --git a/src/angle/patches/0008-ANGLE-DX11-Prevent-assert-when-view-is-minimized-or-.patch b/src/angle/patches/0008-ANGLE-DX11-Prevent-assert-when-view-is-minimized-or-.patch
new file mode 100644
index 0000000000..47ecc25f0c
--- /dev/null
+++ b/src/angle/patches/0008-ANGLE-DX11-Prevent-assert-when-view-is-minimized-or-.patch
@@ -0,0 +1,58 @@
+From 654677720bd856b59387cfd034f441eba8c0e97f Mon Sep 17 00:00:00 2001
+From: Andrew Knight <andrew.knight@digia.com>
+Date: Thu, 4 Apr 2013 14:21:58 +0300
+Subject: [PATCH] ANGLE DX11: Prevent assert when view is minimized or size
+ goes to 0x0
+
+This allows the Direct3D 11 version of ANGLE to gracefully allow
+surfaces with dimensions of 0. This is important because Qt may resize
+the surface to 0x0 because of window minimization or other user
+action (window resize). As EGL specifies that empty (0x0) surfaces are
+valid, this makes sure an assert doesn't occur in the case that a valid
+surface is resized to an empty one.
+
+Change-Id: Ia60c4c694090d03c1da7f43c56e90b925c8eab6d
+---
+ src/3rdparty/angle/src/libEGL/Surface.cpp | 9 ++++++++-
+ src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.cpp | 3 +++
+ 2 files changed, 11 insertions(+), 1 deletion(-)
+
+diff --git a/src/3rdparty/angle/src/libEGL/Surface.cpp b/src/3rdparty/angle/src/libEGL/Surface.cpp
+index 5ece724..8387443 100644
+--- a/src/3rdparty/angle/src/libEGL/Surface.cpp
++++ b/src/3rdparty/angle/src/libEGL/Surface.cpp
+@@ -172,9 +172,16 @@ bool Surface::resetSwapChain()
+
+ bool Surface::resizeSwapChain(int backbufferWidth, int backbufferHeight)
+ {
+- ASSERT(backbufferWidth >= 0 && backbufferHeight >= 0);
+ ASSERT(mSwapChain);
+
++ // Prevent bad swap chain resize by calling reset if size is invalid
++ if (backbufferWidth < 1 || backbufferHeight < 1)
++ {
++ mWidth = backbufferWidth;
++ mHeight = backbufferHeight;
++ return mSwapChain->reset(0, 0, mSwapInterval) == EGL_SUCCESS;
++ }
++
+ EGLint status = mSwapChain->resize(backbufferWidth, backbufferHeight);
+
+ if (status == EGL_CONTEXT_LOST)
+diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.cpp
+index 87422be..98f8875 100644
+--- a/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.cpp
++++ b/src/3rdparty/angle/src/libGLESv2/renderer/SwapChain11.cpp
+@@ -368,6 +368,9 @@ EGLint SwapChain11::resize(EGLint backbufferWidth, EGLint backbufferHeight)
+ return EGL_BAD_ACCESS;
+ }
+
++ if (!mSwapChain)
++ reset(backbufferWidth, backbufferHeight, mSwapInterval);
++
+ // Can only call resize if we have already created our swap buffer and resources
+ ASSERT(mSwapChain && mBackBufferTexture && mBackBufferRTView);
+
+--
+1.8.1.msysgit.1
+
diff --git a/src/angle/patches/0009-ANGLE-Avoid-memory-copies-on-buffers-when-data-is-nu.patch b/src/angle/patches/0009-ANGLE-Avoid-memory-copies-on-buffers-when-data-is-nu.patch
new file mode 100644
index 0000000000..cecff5c0e8
--- /dev/null
+++ b/src/angle/patches/0009-ANGLE-Avoid-memory-copies-on-buffers-when-data-is-nu.patch
@@ -0,0 +1,72 @@
+From cde4cd6155791355872f635491630c21c791e7f4 Mon Sep 17 00:00:00 2001
+From: Andrew Knight <andrew.knight@digia.com>
+Date: Fri, 5 Apr 2013 15:11:59 +0300
+Subject: [PATCH] ANGLE: Avoid memory copies on buffers when data is null
+
+With data=0, ANGLE can crash when setting the buffer data. As this
+should be a legal operation, don't perform a memcpy when data is null.
+
+Change-Id: I3fa1260482549b1da50d7a68001a65decb98f258
+---
+ src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.cpp | 22 ++++++++++++++++------
+ src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.cpp | 3 ++-
+ 2 files changed, 18 insertions(+), 7 deletions(-)
+
+diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.cpp
+index 4c37bdb..7fe9e6b 100644
+--- a/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.cpp
++++ b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage11.cpp
+@@ -182,7 +182,8 @@ void BufferStorage11::setData(const void* data, unsigned int size, unsigned int
+ return gl::error(GL_OUT_OF_MEMORY);
+ }
+
+- memcpy(mappedResource.pData, data, size);
++ if (data)
++ memcpy(mappedResource.pData, data, size);
+
+ context->Unmap(mStagingBuffer, 0);
+ }
+@@ -211,12 +212,21 @@ void BufferStorage11::setData(const void* data, unsigned int size, unsigned int
+ mBufferSize = 0;
+ }
+
+- D3D11_SUBRESOURCE_DATA initialData;
+- initialData.pSysMem = data;
+- initialData.SysMemPitch = size;
+- initialData.SysMemSlicePitch = 0;
+
+- result = device->CreateBuffer(&bufferDesc, &initialData, &mBuffer);
++ if (data)
++ {
++ D3D11_SUBRESOURCE_DATA initialData;
++ initialData.pSysMem = data;
++ initialData.SysMemPitch = size;
++ initialData.SysMemSlicePitch = 0;
++
++ result = device->CreateBuffer(&bufferDesc, &initialData, &mBuffer);
++ }
++ else
++ {
++ result = device->CreateBuffer(&bufferDesc, NULL, &mBuffer);
++ }
++
+ if (FAILED(result))
+ {
+ return gl::error(GL_OUT_OF_MEMORY);
+diff --git a/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.cpp b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.cpp
+index 7fc14fc..4468461 100644
+--- a/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.cpp
++++ b/src/3rdparty/angle/src/libGLESv2/renderer/BufferStorage9.cpp
+@@ -54,7 +54,8 @@ void BufferStorage9::setData(const void* data, unsigned int size, unsigned int o
+ }
+
+ mSize = std::max(mSize, offset + size);
+- memcpy(reinterpret_cast<char*>(mMemory) + offset, data, size);
++ if (data)
++ memcpy(reinterpret_cast<char*>(mMemory) + offset, data, size);
+ }
+
+ void BufferStorage9::clear()
+--
+1.8.1.msysgit.1
+
diff --git a/src/angle/src/common/common.pri b/src/angle/src/common/common.pri
index c7d2a2d5ae..d16202b6d6 100644
--- a/src/angle/src/common/common.pri
+++ b/src/angle/src/common/common.pri
@@ -40,6 +40,8 @@ win32-msvc2012 {
}
}
+static: DEFINES *= QT_OPENGL_ES_2_ANGLE_STATIC
+
HEADERS += \
$$ANGLE_DIR/src/common/angleutils.h \
$$ANGLE_DIR/src/common/debug.h \
diff --git a/src/angle/src/compiler/preprocessor/preprocessor.pro b/src/angle/src/compiler/preprocessor/preprocessor.pro
index 62476008b3..432c8dcf32 100644
--- a/src/angle/src/compiler/preprocessor/preprocessor.pro
+++ b/src/angle/src/compiler/preprocessor/preprocessor.pro
@@ -4,43 +4,43 @@ TARGET = $$qtLibraryTarget(preprocessor)
include(../../config.pri)
-INCLUDEPATH = $$ANGLE_DIR/src/compiler/preprocessor/new
+INCLUDEPATH = $$ANGLE_DIR/src/compiler/preprocessor
DEFINES += _SECURE_SCL=0
FLEX_SOURCES = \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Tokenizer.l
+ $$ANGLE_DIR/src/compiler/preprocessor/Tokenizer.l
BISON_SOURCES = \
- $$ANGLE_DIR/src/compiler/preprocessor/new/ExpressionParser.y
+ $$ANGLE_DIR/src/compiler/preprocessor/ExpressionParser.y
HEADERS += \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Diagnostics.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/DirectiveHandler.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/DirectiveParser.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/ExpressionParser.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Input.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Lexer.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Macro.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/MacroExpander.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/numeric_lex.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/pp_utils.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Preprocessor.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/SourceLocation.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Token.h \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Tokenizer.h
+ $$ANGLE_DIR/src/compiler/preprocessor/DiagnosticsBase.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/DirectiveHandlerBase.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/DirectiveParser.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/ExpressionParser.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/Input.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/Lexer.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/Macro.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/MacroExpander.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/numeric_lex.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/pp_utils.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/Preprocessor.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/SourceLocation.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/Token.h \
+ $$ANGLE_DIR/src/compiler/preprocessor/Tokenizer.h
SOURCES += \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Diagnostics.cpp \
- $$ANGLE_DIR/src/compiler/preprocessor/new/DirectiveHandler.cpp \
- $$ANGLE_DIR/src/compiler/preprocessor/new/DirectiveParser.cpp \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Input.cpp \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Lexer.cpp \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Macro.cpp \
- $$ANGLE_DIR/src/compiler/preprocessor/new/MacroExpander.cpp \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Preprocessor.cpp \
- $$ANGLE_DIR/src/compiler/preprocessor/new/Token.cpp
+ $$ANGLE_DIR/src/compiler/preprocessor/DiagnosticsBase.cpp \
+ $$ANGLE_DIR/src/compiler/preprocessor/DirectiveHandlerBase.cpp \
+ $$ANGLE_DIR/src/compiler/preprocessor/DirectiveParser.cpp \
+ $$ANGLE_DIR/src/compiler/preprocessor/Input.cpp \
+ $$ANGLE_DIR/src/compiler/preprocessor/Lexer.cpp \
+ $$ANGLE_DIR/src/compiler/preprocessor/Macro.cpp \
+ $$ANGLE_DIR/src/compiler/preprocessor/MacroExpander.cpp \
+ $$ANGLE_DIR/src/compiler/preprocessor/Preprocessor.cpp \
+ $$ANGLE_DIR/src/compiler/preprocessor/Token.cpp
# NOTE: 'win_flex' and 'bison' can be found in qt5/gnuwin32/bin
flex.commands = $$addGnuPath(win_flex) --noline --nounistd --outfile=${QMAKE_FILE_BASE}.cpp ${QMAKE_FILE_NAME}
diff --git a/src/angle/src/compiler/translator_common.pro b/src/angle/src/compiler/translator_common.pro
index 2d867a921e..cafbb1595d 100644
--- a/src/angle/src/compiler/translator_common.pro
+++ b/src/angle/src/compiler/translator_common.pro
@@ -48,22 +48,12 @@ HEADERS += \
$$ANGLE_DIR/src/compiler/ValidateLimitations.h \
$$ANGLE_DIR/src/compiler/VariableInfo.h \
$$ANGLE_DIR/src/compiler/VariablePacker.h \
- $$ANGLE_DIR/src/compiler/preprocessor/atom.h \
- $$ANGLE_DIR/src/compiler/preprocessor/compile.h \
- $$ANGLE_DIR/src/compiler/preprocessor/cpp.h \
- $$ANGLE_DIR/src/compiler/preprocessor/length_limits.h \
- $$ANGLE_DIR/src/compiler/preprocessor/memory.h \
- $$ANGLE_DIR/src/compiler/preprocessor/parser.h \
- $$ANGLE_DIR/src/compiler/preprocessor/preprocess.h \
- $$ANGLE_DIR/src/compiler/preprocessor/scanner.h \
- $$ANGLE_DIR/src/compiler/preprocessor/slglobals.h \
- $$ANGLE_DIR/src/compiler/preprocessor/symbols.h \
- $$ANGLE_DIR/src/compiler/preprocessor/tokens.h \
$$ANGLE_DIR/src/compiler/timing/RestrictFragmentShaderTiming.h \
$$ANGLE_DIR/src/compiler/timing/RestrictVertexShaderTiming.h \
$$ANGLE_DIR/src/compiler/depgraph/DependencyGraph.h \
$$ANGLE_DIR/src/compiler/depgraph/DependencyGraphBuilder.h \
- $$ANGLE_DIR/src/compiler/depgraph/DependencyGraphOutput.h
+ $$ANGLE_DIR/src/compiler/depgraph/DependencyGraphOutput.h \
+ $$ANGLE_DIR/src/third_party/compiler/ArrayBoundsClamper.h
SOURCES += \
$$ANGLE_DIR/src/compiler/BuiltInFunctionEmulator.cpp \
@@ -93,19 +83,13 @@ SOURCES += \
$$ANGLE_DIR/src/compiler/ValidateLimitations.cpp \
$$ANGLE_DIR/src/compiler/VariableInfo.cpp \
$$ANGLE_DIR/src/compiler/VariablePacker.cpp \
- $$ANGLE_DIR/src/compiler/preprocessor/atom.c \
- $$ANGLE_DIR/src/compiler/preprocessor/cpp.c \
- $$ANGLE_DIR/src/compiler/preprocessor/cppstruct.c \
- $$ANGLE_DIR/src/compiler/preprocessor/memory.c \
- $$ANGLE_DIR/src/compiler/preprocessor/scanner.c \
- $$ANGLE_DIR/src/compiler/preprocessor/symbols.c \
- $$ANGLE_DIR/src/compiler/preprocessor/tokens.c \
$$ANGLE_DIR/src/compiler/depgraph/DependencyGraph.cpp \
$$ANGLE_DIR/src/compiler/depgraph/DependencyGraphBuilder.cpp \
$$ANGLE_DIR/src/compiler/depgraph/DependencyGraphOutput.cpp \
$$ANGLE_DIR/src/compiler/depgraph/DependencyGraphTraverse.cpp \
$$ANGLE_DIR/src/compiler/timing/RestrictFragmentShaderTiming.cpp \
- $$ANGLE_DIR/src/compiler/timing/RestrictVertexShaderTiming.cpp
+ $$ANGLE_DIR/src/compiler/timing/RestrictVertexShaderTiming.cpp \
+ $$ANGLE_DIR/src/third_party/compiler/ArrayBoundsClamper.cpp
# NOTE: 'win_flex' and 'bison' can be found in qt5/gnuwin32/bin
flex.commands = $$addGnuPath(win_flex) --noline --nounistd --outfile=${QMAKE_FILE_BASE}_lex.cpp ${QMAKE_FILE_NAME}
diff --git a/src/angle/src/compiler/translator_hlsl.pro b/src/angle/src/compiler/translator_hlsl.pro
index 048e2a48fd..6b17f14d2e 100644
--- a/src/angle/src/compiler/translator_hlsl.pro
+++ b/src/angle/src/compiler/translator_hlsl.pro
@@ -14,7 +14,8 @@ HEADERS += \
$$ANGLE_DIR/src/compiler/OutputHLSL.h \
$$ANGLE_DIR/src/compiler/SearchSymbol.h \
$$ANGLE_DIR/src/compiler/TranslatorHLSL.h \
- $$ANGLE_DIR/src/compiler/UnfoldShortCircuit.h
+ $$ANGLE_DIR/src/compiler/UnfoldShortCircuit.h \
+ $$ANGLE_DIR/src/compiler/Uniform.h
SOURCES += \
$$ANGLE_DIR/src/compiler/CodeGenHLSL.cpp \
@@ -22,4 +23,5 @@ SOURCES += \
$$ANGLE_DIR/src/compiler/OutputHLSL.cpp \
$$ANGLE_DIR/src/compiler/SearchSymbol.cpp \
$$ANGLE_DIR/src/compiler/TranslatorHLSL.cpp \
- $$ANGLE_DIR/src/compiler/UnfoldShortCircuit.cpp
+ $$ANGLE_DIR/src/compiler/UnfoldShortCircuit.cpp \
+ $$ANGLE_DIR/src/compiler/Uniform.cpp
diff --git a/src/angle/src/config.pri b/src/angle/src/config.pri
index 73fbc2e13b..923a40597e 100644
--- a/src/angle/src/config.pri
+++ b/src/angle/src/config.pri
@@ -46,6 +46,11 @@ DEFINES += ANGLE_DISABLE_TRACE \
ANGLE_COMPILE_OPTIMIZATION_LEVEL=D3DCOMPILE_OPTIMIZATION_LEVEL0 \
ANGLE_USE_NEW_PREPROCESSOR=1
+angle_d3d11 {
+ DEFINES += ANGLE_ENABLE_D3D11
+ !build_pass: message("Enabling D3D11 mode for ANGLE")
+}
+
CONFIG(debug, debug|release) {
DEFINES += _DEBUG
} else {
diff --git a/src/angle/src/libEGL/libEGL.pro b/src/angle/src/libEGL/libEGL.pro
index 6f3bc25cfb..c0d021ccab 100644
--- a/src/angle/src/libEGL/libEGL.pro
+++ b/src/angle/src/libEGL/libEGL.pro
@@ -6,8 +6,13 @@ include(../common/common.pri)
# Note: ANGLE is patched to dynamically resolve DwmIsCompositionEnabled DwmSetPresentParameters
# in Surface.cpp, which would otherwise require -ldwmapi, which does not exist on Windows XP
# (QTBUG-27741).
-LIBS += -ld3d9 -ldxguid \
- -L$$QT_BUILD_TREE/lib -l$$qtLibraryTarget(libGLESv2)
+
+angle_d3d11 {
+ LIBS += -ld3d11
+} else {
+ LIBS += -ld3d9
+}
+LIBS += -ldxguid -L$$QT_BUILD_TREE/lib -l$$qtLibraryTarget(libGLESv2)
HEADERS += \
$$ANGLE_DIR/src/libEGL/Config.h \
diff --git a/src/angle/src/libGLESv2/libGLESv2.pro b/src/angle/src/libGLESv2/libGLESv2.pro
index 2412a01b82..681cd1be19 100644
--- a/src/angle/src/libGLESv2/libGLESv2.pro
+++ b/src/angle/src/libGLESv2/libGLESv2.pro
@@ -4,10 +4,15 @@ CONFIG += simd
include(../common/common.pri)
-INCLUDEPATH += $$OUT_PWD/..
+INCLUDEPATH += $$OUT_PWD/.. $$ANGLE_DIR/src/libGLESv2
# Remember to adapt tools/configure/configureapp.cpp if the Direct X version changes.
-LIBS += -ld3d9 -ld3dcompiler
+angle_d3d11 {
+ LIBS += -ldxgi -ld3d11
+} else {
+ LIBS += -ld3d9
+}
+LIBS += -ldxguid -ld3dcompiler
STATICLIBS = translator_common translator_hlsl preprocessor
for(libname, STATICLIBS) {
@@ -19,15 +24,13 @@ for(libname, STATICLIBS) {
}
HEADERS += \
+ $$ANGLE_DIR/src/third_party/murmurhash/MurmurHash3.h \
$$ANGLE_DIR/src/libGLESv2/BinaryStream.h \
- $$ANGLE_DIR/src/libGLESv2/Blit.h \
$$ANGLE_DIR/src/libGLESv2/Buffer.h \
$$ANGLE_DIR/src/libGLESv2/Context.h \
- $$ANGLE_DIR/src/libGLESv2/D3DConstantTable.h \
$$ANGLE_DIR/src/libGLESv2/Fence.h \
$$ANGLE_DIR/src/libGLESv2/Framebuffer.h \
$$ANGLE_DIR/src/libGLESv2/HandleAllocator.h \
- $$ANGLE_DIR/src/libGLESv2/IndexDataManager.h \
$$ANGLE_DIR/src/libGLESv2/main.h \
$$ANGLE_DIR/src/libGLESv2/mathutil.h \
$$ANGLE_DIR/src/libGLESv2/Program.h \
@@ -38,20 +41,31 @@ HEADERS += \
$$ANGLE_DIR/src/libGLESv2/ResourceManager.h \
$$ANGLE_DIR/src/libGLESv2/Shader.h \
$$ANGLE_DIR/src/libGLESv2/Texture.h \
+ $$ANGLE_DIR/src/libGLESv2/Uniform.h \
$$ANGLE_DIR/src/libGLESv2/utilities.h \
$$ANGLE_DIR/src/libGLESv2/vertexconversion.h \
- $$ANGLE_DIR/src/libGLESv2/VertexDataManager.h
+ $$ANGLE_DIR/src/libGLESv2/precompiled.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/BufferStorage.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Image.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/IndexBuffer.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/IndexDataManager.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Renderer.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/RenderTarget.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/ShaderExecutable.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/SwapChain.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/TextureStorage.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/VertexBuffer.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/VertexDataManager.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/VertexDeclarationCache.h
SOURCES += \
- $$ANGLE_DIR/src/libGLESv2/Blit.cpp \
+ $$ANGLE_DIR/src/third_party/murmurhash/MurmurHash3.cpp \
$$ANGLE_DIR/src/libGLESv2/Buffer.cpp \
$$ANGLE_DIR/src/libGLESv2/Context.cpp \
- $$ANGLE_DIR/src/libGLESv2/D3DConstantTable.cpp \
$$ANGLE_DIR/src/libGLESv2/Fence.cpp \
- $$ANGLE_DIR/src/libGLESv2/Framebuffer.cpp \
$$ANGLE_DIR/src/libGLESv2/Float16ToFloat32.cpp \
+ $$ANGLE_DIR/src/libGLESv2/Framebuffer.cpp \
$$ANGLE_DIR/src/libGLESv2/HandleAllocator.cpp \
- $$ANGLE_DIR/src/libGLESv2/IndexDataManager.cpp \
$$ANGLE_DIR/src/libGLESv2/libGLESv2.cpp \
$$ANGLE_DIR/src/libGLESv2/main.cpp \
$$ANGLE_DIR/src/libGLESv2/Program.cpp \
@@ -61,10 +75,84 @@ SOURCES += \
$$ANGLE_DIR/src/libGLESv2/ResourceManager.cpp \
$$ANGLE_DIR/src/libGLESv2/Shader.cpp \
$$ANGLE_DIR/src/libGLESv2/Texture.cpp \
+ $$ANGLE_DIR/src/libGLESv2/Uniform.cpp \
$$ANGLE_DIR/src/libGLESv2/utilities.cpp \
- $$ANGLE_DIR/src/libGLESv2/VertexDataManager.cpp
+ $$ANGLE_DIR/src/libGLESv2/precompiled.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/BufferStorage.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Image.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/IndexBuffer.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/IndexDataManager.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Renderer.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/TextureStorage.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/VertexBuffer.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/VertexDataManager.cpp
-SSE2_SOURCES += $$ANGLE_DIR/src/libGLESv2/TextureSSE2.cpp
+sse2:SOURCES += $$ANGLE_DIR/src/libGLESv2/renderer/ImageSSE2.cpp
+
+angle_d3d11 {
+ HEADERS += \
+ $$ANGLE_DIR/src/libGLESv2/renderer/BufferStorage11.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Fence11.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Image11.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/IndexBuffer11.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/InputLayoutCache.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Query11.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Renderer11.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/renderer11_utils.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/RenderTarget11.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/RenderStateCache.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/ShaderExecutable11.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/SwapChain11.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/TextureStorage11.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/VertexBuffer11.h
+
+ SOURCES += \
+ $$ANGLE_DIR/src/libGLESv2/renderer/BufferStorage11.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Fence11.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Image11.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/IndexBuffer11.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/InputLayoutCache.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Query11.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Renderer11.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/renderer11_utils.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/RenderTarget11.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/RenderStateCache.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/ShaderExecutable11.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/SwapChain11.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/TextureStorage11.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/VertexBuffer11.cpp
+} else {
+ HEADERS += \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Blit.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/BufferStorage9.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Fence9.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Image9.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/IndexBuffer9.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Query9.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Renderer9.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/renderer9_utils.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/RenderTarget9.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/ShaderExecutable9.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/SwapChain9.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/TextureStorage9.h \
+ $$ANGLE_DIR/src/libGLESv2/renderer/VertexBuffer9.h
+
+ SOURCES += \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Blit.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/BufferStorage9.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Fence9.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Image9.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/IndexBuffer9.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Query9.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/Renderer9.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/renderer9_utils.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/RenderTarget9.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/ShaderExecutable9.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/SwapChain9.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/TextureStorage9.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/VertexBuffer9.cpp \
+ $$ANGLE_DIR/src/libGLESv2/renderer/VertexDeclarationCache.cpp
+}
!static {
DEF_FILE = $$ANGLE_DIR/src/libGLESv2/$${TARGET}.def
@@ -77,27 +165,71 @@ float_converter.commands = python $$ANGLE_DIR/src/libGLESv2/Float16ToFloat32.py
QMAKE_EXTRA_TARGETS += float_converter
# Generate the shader header files.
-PS_INPUT = $$ANGLE_DIR/src/libGLESv2/shaders/Blit.ps
-VS_INPUT = $$ANGLE_DIR/src/libGLESv2/shaders/Blit.vs
+PS_INPUT = $$ANGLE_DIR/src/libGLESv2/renderer/shaders/Blit.ps
+VS_INPUT = $$ANGLE_DIR/src/libGLESv2/renderer/shaders/Blit.vs
+PASSTHROUGH_INPUT = $$ANGLE_DIR/src/libGLESv2/renderer/shaders/Passthrough11.hlsl
+CLEAR_INPUT = $$ANGLE_DIR/src/libGLESv2/renderer/shaders/Clear11.hlsl
PIXEL_SHADERS = passthroughps luminanceps componentmaskps
+PIXEL_SHADERS_PASSTHROUGH = PassthroughRGBA PassthroughRGB \
+ PassthroughLum PassthroughLumAlpha
VERTEX_SHADERS = standardvs flipyvs
-SHADER_DIR = $$OUT_PWD/shaders
+VERTEX_SHADERS_PASSTHROUGH = Passthrough
+CLEAR_SHADERS = Clear
+SHADER_DIR = $$OUT_PWD/renderer/shaders/compiled
for (ps, PIXEL_SHADERS) {
- fxc_$${ps}.commands = $$FXC /nologo /E $$ps /T ps_2_0 /Fh ${QMAKE_FILE_OUT} ${QMAKE_FILE_NAME}
- fxc_$${ps}.output = $$SHADER_DIR/$${ps}.h
- fxc_$${ps}.input = PS_INPUT
- fxc_$${ps}.dependency_type = TYPE_C
- fxc_$${ps}.variable_out = HEADERS
- QMAKE_EXTRA_COMPILERS += fxc_$${ps}
+ fxc_ps_$${ps}.commands = $$FXC /nologo /E $$ps /T ps_2_0 /Fh ${QMAKE_FILE_OUT} ${QMAKE_FILE_NAME}
+ fxc_ps_$${ps}.output = $$SHADER_DIR/$${ps}.h
+ fxc_ps_$${ps}.input = PS_INPUT
+ fxc_ps_$${ps}.dependency_type = TYPE_C
+ fxc_ps_$${ps}.variable_out = HEADERS
+ fxc_ps_$${ps}.CONFIG += target_predeps
+ QMAKE_EXTRA_COMPILERS += fxc_ps_$${ps}
+}
+for (ps, PIXEL_SHADERS_PASSTHROUGH) {
+ fxc_ps_$${ps}.commands = $$FXC /nologo /E PS_$$ps /T ps_4_0 /Fh ${QMAKE_FILE_OUT} ${QMAKE_FILE_NAME}
+ fxc_ps_$${ps}.output = $$SHADER_DIR/$${ps}11ps.h
+ fxc_ps_$${ps}.input = PASSTHROUGH_INPUT
+ fxc_ps_$${ps}.dependency_type = TYPE_C
+ fxc_ps_$${ps}.variable_out = HEADERS
+ fxc_ps_$${ps}.CONFIG += target_predeps
+ QMAKE_EXTRA_COMPILERS += fxc_ps_$${ps}
+}
+for (ps, CLEAR_SHADERS) {
+ fxc_ps_$${ps}.commands = $$FXC /nologo /E PS_$$ps /T ps_4_0 /Fh ${QMAKE_FILE_OUT} ${QMAKE_FILE_NAME}
+ fxc_ps_$${ps}.output = $$SHADER_DIR/$${ps}11ps.h
+ fxc_ps_$${ps}.input = CLEAR_INPUT
+ fxc_ps_$${ps}.dependency_type = TYPE_C
+ fxc_ps_$${ps}.variable_out = HEADERS
+ fxc_ps_$${ps}.CONFIG += target_predeps
+ QMAKE_EXTRA_COMPILERS += fxc_ps_$${ps}
}
for (vs, VERTEX_SHADERS) {
- fxc_$${vs}.commands = $$FXC /nologo /E $$vs /T vs_2_0 /Fh ${QMAKE_FILE_OUT} ${QMAKE_FILE_NAME}
- fxc_$${vs}.output = $$SHADER_DIR/$${vs}.h
- fxc_$${vs}.input = VS_INPUT
- fxc_$${vs}.dependency_type = TYPE_C
- fxc_$${vs}.variable_out = HEADERS
- QMAKE_EXTRA_COMPILERS += fxc_$${vs}
+ fxc_vs_$${vs}.commands = $$FXC /nologo /E $$vs /T vs_2_0 /Fh ${QMAKE_FILE_OUT} ${QMAKE_FILE_NAME}
+ fxc_vs_$${vs}.output = $$SHADER_DIR/$${vs}.h
+ fxc_vs_$${vs}.input = VS_INPUT
+ fxc_vs_$${vs}.dependency_type = TYPE_C
+ fxc_vs_$${vs}.variable_out = HEADERS
+ fxc_vs_$${vs}.CONFIG += target_predeps
+ QMAKE_EXTRA_COMPILERS += fxc_vs_$${vs}
+}
+for (vs, VERTEX_SHADERS_PASSTHROUGH) {
+ fxc_vs_$${vs}.commands = $$FXC /nologo /E VS_$$vs /T vs_4_0 /Fh ${QMAKE_FILE_OUT} ${QMAKE_FILE_NAME}
+ fxc_vs_$${vs}.output = $$SHADER_DIR/$${vs}11vs.h
+ fxc_vs_$${vs}.input = PASSTHROUGH_INPUT
+ fxc_vs_$${vs}.dependency_type = TYPE_C
+ fxc_vs_$${vs}.variable_out = HEADERS
+ fxc_vs_$${vs}.CONFIG += target_predeps
+ QMAKE_EXTRA_COMPILERS += fxc_vs_$${vs}
+}
+for (vs, CLEAR_SHADERS) {
+ fxc_vs_$${vs}.commands = $$FXC /nologo /E VS_$$vs /T vs_4_0 /Fh ${QMAKE_FILE_OUT} ${QMAKE_FILE_NAME}
+ fxc_vs_$${vs}.output = $$SHADER_DIR/$${vs}11vs.h
+ fxc_vs_$${vs}.input = CLEAR_INPUT
+ fxc_vs_$${vs}.dependency_type = TYPE_C
+ fxc_vs_$${vs}.variable_out = HEADERS
+ fxc_vs_$${vs}.CONFIG += target_predeps
+ QMAKE_EXTRA_COMPILERS += fxc_vs_$${vs}
}
load(qt_installs)
diff --git a/src/concurrent/qtconcurrent_global.h b/src/concurrent/qtconcurrent_global.h
index d98319d3c0..965d33f3d9 100644
--- a/src/concurrent/qtconcurrent_global.h
+++ b/src/concurrent/qtconcurrent_global.h
@@ -44,7 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
#ifndef QT_STATIC
@@ -58,6 +57,5 @@ QT_BEGIN_NAMESPACE
#endif
QT_END_NAMESPACE
-QT_END_HEADER
#endif // include guard
diff --git a/src/concurrent/qtconcurrentcompilertest.h b/src/concurrent/qtconcurrentcompilertest.h
index 7b78e3a307..7652a6946f 100644
--- a/src/concurrent/qtconcurrentcompilertest.h
+++ b/src/concurrent/qtconcurrentcompilertest.h
@@ -46,7 +46,6 @@
#ifndef QT_NO_CONCURRENT
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
namespace QtPrivate {
@@ -64,7 +63,6 @@ public:
}
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/concurrent/qtconcurrentexception.h b/src/concurrent/qtconcurrentexception.h
index de7f74eaef..21fdb25c2d 100644
--- a/src/concurrent/qtconcurrentexception.h
+++ b/src/concurrent/qtconcurrentexception.h
@@ -48,7 +48,6 @@
#include <QtCore/qexception.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -65,7 +64,6 @@ typedef Q_DECL_DEPRECATED QUnhandledException UnhandledException;
} // namespace QtConcurrent
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_QFUTURE
diff --git a/src/concurrent/qtconcurrentfilter.cpp b/src/concurrent/qtconcurrentfilter.cpp
index 72362b7d8a..ef0229a695 100644
--- a/src/concurrent/qtconcurrentfilter.cpp
+++ b/src/concurrent/qtconcurrentfilter.cpp
@@ -148,7 +148,7 @@
QtConcurrent::filter(), QtConcurrent::filtered(), and
QtConcurrent::filteredReduced() accept function objects, which can be used to
- add state to a function call. The result_type typedef must define the
+ add state to a function call. The result_type typedef must define the
result type of the function call operator:
\snippet code/src_concurrent_qtconcurrentfilter.cpp 13
diff --git a/src/concurrent/qtconcurrentfilter.h b/src/concurrent/qtconcurrentfilter.h
index cac57f6084..4c6f2ed896 100644
--- a/src/concurrent/qtconcurrentfilter.h
+++ b/src/concurrent/qtconcurrentfilter.h
@@ -49,7 +49,6 @@
#include <QtConcurrent/qtconcurrentfilterkernel.h>
#include <QtConcurrent/qtconcurrentfunctionwrappers.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -261,7 +260,6 @@ OutputSequence blockingFiltered(Iterator begin, Iterator end, KeepFunctor keep)
#endif // Q_QDOC
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/concurrent/qtconcurrentfilterkernel.h b/src/concurrent/qtconcurrentfilterkernel.h
index 7e1555d4d8..63e77ab40d 100644
--- a/src/concurrent/qtconcurrentfilterkernel.h
+++ b/src/concurrent/qtconcurrentfilterkernel.h
@@ -50,7 +50,6 @@
#include <QtConcurrent/qtconcurrentmapkernel.h>
#include <QtConcurrent/qtconcurrentreducekernel.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -343,7 +342,6 @@ inline ThreadEngineStarter<ResultType> startFilteredReduced(Iterator begin, Iter
#endif // Q_QDOC
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/concurrent/qtconcurrentfunctionwrappers.h b/src/concurrent/qtconcurrentfunctionwrappers.h
index 3925d0eda5..abd316b7fa 100644
--- a/src/concurrent/qtconcurrentfunctionwrappers.h
+++ b/src/concurrent/qtconcurrentfunctionwrappers.h
@@ -47,7 +47,6 @@
#ifndef QT_NO_CONCURRENT
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -297,7 +296,6 @@ struct MapResultType<QStringList, U(C::*)() const>
#endif //Q_QDOC
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/concurrent/qtconcurrentiteratekernel.h b/src/concurrent/qtconcurrentiteratekernel.h
index d4a6a72650..70a7f161de 100644
--- a/src/concurrent/qtconcurrentiteratekernel.h
+++ b/src/concurrent/qtconcurrentiteratekernel.h
@@ -52,7 +52,6 @@
#include <iterator>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -303,7 +302,6 @@ public:
#endif //Q_QDOC
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/concurrent/qtconcurrentmap.cpp b/src/concurrent/qtconcurrentmap.cpp
index 2dba3779ff..9718baf48f 100644
--- a/src/concurrent/qtconcurrentmap.cpp
+++ b/src/concurrent/qtconcurrentmap.cpp
@@ -56,7 +56,7 @@
/*!
\enum QtConcurrent::ReduceOption
- This enum specifies the order of which results from the map or filter
+ This enum specifies the order of which results from the map or filter
function are passed to the reduce function.
\value UnorderedReduce Reduction is done in an arbitrary order.
@@ -197,7 +197,7 @@
QtConcurrent::map(), QtConcurrent::mapped(), and
QtConcurrent::mappedReduced() accept function objects, which can be used to
- add state to a function call. The result_type typedef must define the
+ add state to a function call. The result_type typedef must define the
result type of the function call operator:
\snippet code/src_concurrent_qtconcurrentmap.cpp 14
@@ -347,7 +347,7 @@
Calls \a function once for each item from \a begin to \a end and returns a
container with the results. Specify the type of container as the a template
argument, like this:
-
+
\code
QList<int> ints = QtConcurrent::blockingMapped<QList<int> >(beginIterator, endIterator, fn);
\endcode
diff --git a/src/concurrent/qtconcurrentmap.h b/src/concurrent/qtconcurrentmap.h
index d98ec59da3..bc1c3638d9 100644
--- a/src/concurrent/qtconcurrentmap.h
+++ b/src/concurrent/qtconcurrentmap.h
@@ -51,7 +51,6 @@
#include <QtConcurrent/qtconcurrentfunctionwrappers.h>
#include <QtCore/qstringlist.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -312,7 +311,6 @@ typename QtPrivate::MapResultType<Iterator, MapFunctor>::ResultType blockingMapp
#endif // Q_QDOC
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/concurrent/qtconcurrentmapkernel.h b/src/concurrent/qtconcurrentmapkernel.h
index 2d42b24653..6817cd3e29 100644
--- a/src/concurrent/qtconcurrentmapkernel.h
+++ b/src/concurrent/qtconcurrentmapkernel.h
@@ -49,7 +49,6 @@
#include <QtConcurrent/qtconcurrentiteratekernel.h>
#include <QtConcurrent/qtconcurrentreducekernel.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -81,7 +80,7 @@ public:
runIteration(it, i, 0);
advance(it, 1);
}
-
+
return false;
}
};
@@ -265,7 +264,6 @@ inline ThreadEngineStarter<ResultType> startMappedReduced(Iterator begin, Iterat
#endif //Q_QDOC
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/concurrent/qtconcurrentmedian.h b/src/concurrent/qtconcurrentmedian.h
index e1840ed3fd..7d3b50a45b 100644
--- a/src/concurrent/qtconcurrentmedian.h
+++ b/src/concurrent/qtconcurrentmedian.h
@@ -49,7 +49,6 @@
#include <QtCore/qvector.h>
#include <QtCore/qalgorithms.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -122,7 +121,6 @@ private:
#endif //Q_QDOC
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/concurrent/qtconcurrentreducekernel.h b/src/concurrent/qtconcurrentreducekernel.h
index 54bfcdeefe..dcf4b92319 100644
--- a/src/concurrent/qtconcurrentreducekernel.h
+++ b/src/concurrent/qtconcurrentreducekernel.h
@@ -54,7 +54,6 @@
#include <QtCore/qthreadpool.h>
#include <QtCore/qvector.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -140,7 +139,7 @@ class ReduceKernel
public:
ReduceKernel(ReduceOptions _reduceOptions)
- : reduceOptions(_reduceOptions), progress(0), resultsMapSize(0),
+ : reduceOptions(_reduceOptions), progress(0), resultsMapSize(0),
threadCount(QThreadPool::globalInstance()->maxThreadCount())
{ }
@@ -247,7 +246,6 @@ struct SequenceHolder2 : public Base
} // namespace QtConcurrent
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/concurrent/qtconcurrentrun.cpp b/src/concurrent/qtconcurrentrun.cpp
index 880441cfc3..4ab1399c0c 100644
--- a/src/concurrent/qtconcurrentrun.cpp
+++ b/src/concurrent/qtconcurrentrun.cpp
@@ -47,63 +47,63 @@
separate thread.
\ingroup thread
-
+
This function is a part of the \l {Concurrent Programming}{Qt Concurrent} framework.
The QtConcurrent::run() function runs a function in a separate thread.
The return value of the function is made available through the QFuture API.
-
+
\section1 Running a Function in a Separate Thread
-
+
To run a function in another thread, use QtConcurrent::run():
-
+
\snippet code/src_concurrent_qtconcurrentrun.cpp 0
-
+
This will run \e aFunction in a separate thread obtained from the default
QThreadPool. You can use the QFuture and QFutureWatcher classes to monitor
the status of the function.
-
+
\section1 Passing Arguments to the Function
Passing arguments to the function is done by adding them to the
QtConcurrent::run() call immediately after the function name. For example:
-
+
\snippet code/src_concurrent_qtconcurrentrun.cpp 1
-
+
A copy of each argument is made at the point where QtConcurrent::run() is
called, and these values are passed to the thread when it begins executing
the function. Changes made to the arguments after calling
QtConcurrent::run() are \e not visible to the thread.
-
+
\section1 Returning Values from the Function
-
+
Any return value from the function is available via QFuture:
-
+
\snippet code/src_concurrent_qtconcurrentrun.cpp 2
-
+
As documented above, passing arguments is done like this:
-
+
\snippet code/src_concurrent_qtconcurrentrun.cpp 3
-
+
Note that the QFuture::result() function blocks and waits for the result
to become available. Use QFutureWatcher to get notification when the
function has finished execution and the result is available.
-
+
\section1 Additional API Features
-
+
\section2 Using Member Functions
-
+
QtConcurrent::run() also accepts pointers to member functions. The first
argument must be either a const reference or a pointer to an instance of
the class. Passing by const reference is useful when calling const member
functions; passing by pointer is useful for calling non-const member
functions that modify the instance.
-
+
For example, calling QByteArray::split() (a const member function) in a
separate thread is done like this:
-
+
\snippet code/src_concurrent_qtconcurrentrun.cpp 4
-
+
Calling a non-const member function is done like this:
\snippet code/src_concurrent_qtconcurrentrun.cpp 5
@@ -115,17 +115,17 @@
\l{http://www.boost.org/libs/bind/bind.html}{Boost} or
\l{http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2005/n1836.pdf}
{C++ TR1 Library Extensions}.
-
+
You can use boost::bind() or std::tr1::bind() to \e bind a number of
arguments to a function when called. There are number of reasons for doing
this:
-
+
\list
\li To call a function that takes more than 5 arguments.
\li To simplify calling a function with constant arguments.
\li Changing the order of arguments.
\endlist
-
+
See the documentation for the relevant functions for details on how to use
the bind API.
@@ -137,14 +137,14 @@
/*!
\fn QFuture<T> QtConcurrent::run(Function function, ...);
\relates <QtConcurrentRun>
-
+
Runs \a function in a separate thread. The thread is taken from the global
QThreadPool. Note that the function may not run immediately; the function
will only be run when a thread is available.
-
+
T is the same type as the return value of \a function. Non-void return
values can be accessed via the QFuture::result() function.
-
+
Note that the QFuture returned by QtConcurrent::run() does not support
canceling, pausing, or progress reporting. The QFuture returned can only
be used to query for the running/finished status and the return value of
diff --git a/src/concurrent/qtconcurrentrun.h b/src/concurrent/qtconcurrentrun.h
index 4dadc111dd..0bfe4bfd0a 100644
--- a/src/concurrent/qtconcurrentrun.h
+++ b/src/concurrent/qtconcurrentrun.h
@@ -50,7 +50,6 @@
#include <QtConcurrent/qtconcurrentrunbase.h>
#include <QtConcurrent/qtconcurrentstoredfunctioncall.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -340,7 +339,6 @@ QFuture<T> run(const Class *object, T (Class::*fn)(Param1, Param2, Param3, Param
#endif // Q_QDOC
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/concurrent/qtconcurrentrunbase.h b/src/concurrent/qtconcurrentrunbase.h
index e7ed6207c9..bd24c42ce2 100644
--- a/src/concurrent/qtconcurrentrunbase.h
+++ b/src/concurrent/qtconcurrentrunbase.h
@@ -50,7 +50,6 @@
#include <QtCore/qrunnable.h>
#include <QtCore/qthreadpool.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -147,7 +146,6 @@ public:
#endif //Q_QDOC
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/concurrent/qtconcurrentstoredfunctioncall.h b/src/concurrent/qtconcurrentstoredfunctioncall.h
index aa590a3fb8..8d49ab3dfc 100644
--- a/src/concurrent/qtconcurrentstoredfunctioncall.h
+++ b/src/concurrent/qtconcurrentstoredfunctioncall.h
@@ -48,7 +48,6 @@
#ifndef QT_NO_CONCURRENT
#include <QtConcurrent/qtconcurrentrunbase.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -1305,7 +1304,6 @@ private:
#endif // Q_QDOC
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/concurrent/qtconcurrentthreadengine.h b/src/concurrent/qtconcurrentthreadengine.h
index 378ee07170..a3ee8ca202 100644
--- a/src/concurrent/qtconcurrentthreadengine.h
+++ b/src/concurrent/qtconcurrentthreadengine.h
@@ -54,7 +54,6 @@
#include <QtCore/qatomic.h>
#include <QtCore/qsemaphore.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -273,7 +272,6 @@ inline ThreadEngineStarter<typename ThreadEngine::ResultType> startThreadEngine(
#endif //Q_QDOC
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_CONCURRENT
diff --git a/src/corelib/Qt5CTestMacros.cmake b/src/corelib/Qt5CTestMacros.cmake
index 60b98a7138..e507c8009e 100644
--- a/src/corelib/Qt5CTestMacros.cmake
+++ b/src/corelib/Qt5CTestMacros.cmake
@@ -19,6 +19,21 @@ if (CMAKE_TOOLCHAIN_FILE)
list(APPEND BUILD_OPTIONS_LIST "-DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE}")
endif()
+if (NO_WIDGETS)
+ list(APPEND BUILD_OPTIONS_LIST "-DNO_WIDGETS=True")
+endif()
+if (NO_DBUS)
+ list(APPEND BUILD_OPTIONS_LIST "-DNO_DBUS=True")
+endif()
+
+foreach(module ${CMAKE_MODULES_UNDER_TEST})
+ list(APPEND BUILD_OPTIONS_LIST
+ "-DCMAKE_${module}_MODULE_MAJOR_VERSION=${CMAKE_${module}_MODULE_MAJOR_VERSION}"
+ "-DCMAKE_${module}_MODULE_MINOR_VERSION=${CMAKE_${module}_MODULE_MINOR_VERSION}"
+ "-DCMAKE_${module}_MODULE_PATCH_VERSION=${CMAKE_${module}_MODULE_PATCH_VERSION}"
+ )
+endforeach()
+
macro(expect_pass _dir)
string(REPLACE "(" "_" testname "${_dir}")
string(REPLACE ")" "_" testname "${testname}")
@@ -80,7 +95,7 @@ function(test_module_includes)
set(packages_string
"
${packages_string}
- find_package(Qt5${_package} REQUIRED)
+ find_package(Qt5${_package} 5.0.0 REQUIRED)
"
)
endforeach()
@@ -88,24 +103,31 @@ function(test_module_includes)
while(all_args)
list(GET all_args 0 qtmodule)
list(REMOVE_AT all_args 0 1)
+
+ set(CMAKE_MODULE_VERSION ${CMAKE_${qtmodule}_MODULE_MAJOR_VERSION}.${CMAKE_${qtmodule}_MODULE_MINOR_VERSION}.${CMAKE_${qtmodule}_MODULE_PATCH_VERSION} )
+
set(packages_string
"${packages_string}
- find_package(Qt5${qtmodule} REQUIRED)
+ find_package(Qt5${qtmodule} 5.0.0 REQUIRED)
include_directories(\${Qt5${qtmodule}_INCLUDE_DIRS})
- add_definitions(\${Qt5${qtmodule}_DEFINITIONS})\n"
- )
+ add_definitions(\${Qt5${qtmodule}_DEFINITIONS})
- # Because the CI system tests built packages before installation,
- # the include dir allowing module-includes for the new module is not
- # the same as the dir for QtCore (because that is at the installation
- # location). The CI system is untypical here in that it attempts to use
- # packages while they are in an intermediate state, so we work around
- # that in the test system.
- set(packages_string
- "${packages_string}
- include_directories(\"\${Qt5${qtmodule}_DIR}/../../../include\")\n"
+ if(NOT \"\${Qt5${qtmodule}_VERSION}\" VERSION_EQUAL ${CMAKE_MODULE_VERSION})
+ message(SEND_ERROR \"Qt5${qtmodule}_VERSION variable was not ${CMAKE_MODULE_VERSION}. Got \${Qt5${qtmodule}_VERSION} instead.\")
+ endif()
+ if(NOT \"\${Qt5${qtmodule}_VERSION_MAJOR}\" VERSION_EQUAL ${CMAKE_${qtmodule}_MODULE_MAJOR_VERSION})
+ message(SEND_ERROR \"Qt5${qtmodule}_VERSION_MAJOR variable was not ${CMAKE_${qtmodule}_MODULE_MAJOR_VERSION}. Got \${Qt5${qtmodule}_VERSION_MAJOR} instead.\")
+ endif()
+ if(NOT \"\${Qt5${qtmodule}_VERSION_MINOR}\" VERSION_EQUAL ${CMAKE_${qtmodule}_MODULE_MINOR_VERSION})
+ message(SEND_ERROR \"Qt5${qtmodule}_VERSION_MINOR variable was not ${CMAKE_${qtmodule}_MODULE_MINOR_VERSION}. Got \${Qt5${qtmodule}_VERSION_MINOR} instead.\")
+ endif()
+ if(NOT \"\${Qt5${qtmodule}_VERSION_PATCH}\" VERSION_EQUAL ${CMAKE_${qtmodule}_MODULE_PATCH_VERSION})
+ message(SEND_ERROR \"Qt5${qtmodule}_VERSION_PATCH variable was not ${CMAKE_${qtmodule}_MODULE_PATCH_VERSION}. Got \${Qt5${qtmodule}_VERSION_PATCH} instead.\")
+ endif()
+ if(NOT \"\${Qt5${qtmodule}_VERSION_STRING}\" VERSION_EQUAL ${CMAKE_MODULE_VERSION})
+ message(SEND_ERROR \"Qt5${qtmodule}_VERSION_STRING variable was not ${CMAKE_MODULE_VERSION}. Got \${Qt5${qtmodule}_VERSION_STRING} instead.\")
+ endif()\n"
)
-
set(libraries_string "${libraries_string} Qt5::${qtmodule}")
endwhile()
@@ -127,18 +149,23 @@ function(test_module_includes)
set(instances_string "")
while(all_args)
list(GET all_args 0 qtmodule)
- list(GET all_args 1 qtinclude)
+ list(GET all_args 1 qtclass)
+ if (${qtclass}_NAMESPACE)
+ set(qtinstancetype ${${qtclass}_NAMESPACE}::${qtclass})
+ else()
+ set(qtinstancetype ${qtclass})
+ endif()
list(REMOVE_AT all_args 0 1)
set(includes_string
"${includes_string}
- #include <${qtinclude}>
- #include <Qt${qtmodule}/${qtinclude}>
+ #include <${qtclass}>
+ #include <Qt${qtmodule}/${qtclass}>
#include <Qt${qtmodule}>
#include <Qt${qtmodule}/Qt${qtmodule}>"
)
set(instances_string
"${instances_string}
- ${qtinclude} local${qtinclude};
+ ${qtinstancetype} local${qtclass};
")
endwhile()
diff --git a/src/corelib/Qt5Config.cmake.in b/src/corelib/Qt5Config.cmake.in
new file mode 100644
index 0000000000..408dd64496
--- /dev/null
+++ b/src/corelib/Qt5Config.cmake.in
@@ -0,0 +1,43 @@
+
+if (CMAKE_VERSION VERSION_LESS 2.8.9)
+ message(FATAL_ERROR \"Qt5 requires at least CMake version 2.8.9\")
+endif()
+
+if (NOT Qt5_FIND_COMPONENTS)
+ set(Qt5_NOT_FOUND_MESSAGE \"The Qt5 package requires at least one component\")
+ set(Qt5_FOUND False)
+ return()
+endif()
+
+set(_Qt5_FIND_PARTS_REQUIRED)
+if (Qt5_FIND_REQUIRED)
+ set(_Qt5_FIND_PARTS_REQUIRED REQUIRED)
+endif()
+set(_Qt5_FIND_PARTS_QUIET)
+if (Qt5_FIND_QUIETLY)
+ set(_Qt5_FIND_PARTS_QUIET QUIET)
+endif()
+
+get_filename_component(_qt5_install_prefix \"${CMAKE_CURRENT_LIST_DIR}/$${CMAKE_RELATIVE_INSTALL_DIR}\" ABSOLUTE)
+
+set(_Qt5_NOTFOUND_MESSAGE)
+
+foreach(module ${Qt5_FIND_COMPONENTS})
+ find_package(Qt5${module}
+ ${_Qt5_FIND_PARTS_QUIET}
+ ${_Qt5_FIND_PARTS_REQUIRED}
+ PATHS \"${_qt5_install_prefix}\" NO_DEFAULT_PATH
+ )
+ if (NOT Qt5${module}_FOUND)
+ if (Qt5_FIND_REQUIRED_${module})
+ set(_Qt5_NOTFOUND_MESSAGE \"${_Qt5_NOTFOUND_MESSAGE}Failed to find Qt5 component \\\"${module}\\\" config file at \\\"${_qt5_install_prefix}/lib/cmake/Qt5${module}/Qt5${module}Config.cmake\\\"\\n\")
+ elseif(NOT Qt5_FIND_QUIETLY)
+ message(WARNING \"Failed to find Qt5 component \\\"${module}\\\" config file at \\\"${_qt5_install_prefix}/lib/cmake/Qt5${module}/Qt5${module}Config.cmake\\\"\")
+ endif()
+ endif()
+endforeach()
+
+if (_Qt5_NOTFOUND_MESSAGE)
+ set(Qt5_NOT_FOUND_MESSAGE \"${_Qt5_NOTFOUND_MESSAGE}\")
+ set(Qt5_FOUND False)
+endif()
diff --git a/src/corelib/Qt5CoreConfigExtras.cmake.in b/src/corelib/Qt5CoreConfigExtras.cmake.in
index 4e0fcda20e..379fb5d10e 100644
--- a/src/corelib/Qt5CoreConfigExtras.cmake.in
+++ b/src/corelib/Qt5CoreConfigExtras.cmake.in
@@ -41,23 +41,34 @@ set(Qt5Core_QMAKE_EXECUTABLE Qt5::qmake)
set(Qt5Core_MOC_EXECUTABLE Qt5::moc)
set(Qt5Core_RCC_EXECUTABLE Qt5::rcc)
-!!IF isEmpty(CMAKE_ARCHDATA_DIR_IS_ABSOLUTE)
-list(APPEND Qt5Core_INCLUDE_DIRS \"${_qt5Core_install_prefix}/$$CMAKE_INCLUDE_DIR\" \"${_qt5Core_install_prefix}/$${CMAKE_ARCHDATA_DIR}/mkspecs/$${CMAKE_MKSPEC}\")
+set_property(TARGET Qt5::Core PROPERTY INTERFACE_QT_MAJOR_VERSION 5)
+set_property(TARGET Qt5::Core APPEND PROPERTY
+ COMPATIBLE_INTERFACE_STRING QT_MAJOR_VERSION
+)
+
+!!IF isEmpty(CMAKE_HOST_DATA_DIR_IS_ABSOLUTE)
+set(_qt5_corelib_extra_includes \"${_qt5Core_install_prefix}/$${CMAKE_HOST_DATA_DIR}/mkspecs/$${CMAKE_MKSPEC}\")
!!ELSE
-list(APPEND Qt5Core_INCLUDE_DIRS \"$$CMAKE_INCLUDE_DIR\" \"$${CMAKE_ARCHDATA_DIR}mkspecs/$${CMAKE_MKSPEC}\")
+set(_qt5_corelib_extra_includes \"$${CMAKE_HOST_DATA_DIR}mkspecs/$${CMAKE_MKSPEC}\")
!!ENDIF
+list(APPEND Qt5Core_INCLUDE_DIRS ${_qt5_corelib_extra_includes})
+set_property(TARGET Qt5::Core APPEND PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${_qt5_corelib_extra_includes})
+set(_qt5_corelib_extra_includes)
+
!!IF !isEmpty(CMAKE_ADD_FPIE_FLAGS)
# Targets using Qt need to use the POSITION_INDEPENDENT_CODE property. The
# Qt5_POSITION_INDEPENDENT_CODE variable is used in the # qt5_use_module
# macro to add it.
set(Qt5_POSITION_INDEPENDENT_CODE True)
+set_property(TARGET Qt5::Core PROPERTY INTERFACE_POSITION_INDEPENDENT_CODE \"ON\")
set(Qt5Core_EXECUTABLE_COMPILE_FLAGS \"-fPIE\")
!!ENDIF
!!IF !isEmpty(QT_NAMESPACE)
list(APPEND Qt5Core_DEFINITIONS -DQT_NAMESPACE=$$QT_NAMESPACE)
list(APPEND Qt5Core_COMPILE_DEFINITIONS QT_NAMESPACE=$$QT_NAMESPACE)
+set_property(TARGET Qt5::Core APPEND PROPERTY INTERFACE_COMPILE_DEFINITIONS QT_NAMESPACE=$$QT_NAMESPACE)
!!ENDIF
!!IF contains(QT_CONFIG, reduce_exports)
@@ -95,6 +106,25 @@ if (NOT TARGET Qt5::WinMain)
!!ENDIF
)
!!ENDIF
+
+ if (NOT CMAKE_VERSION VERSION_LESS 2.8.11 AND NOT Qt5_NO_LINK_QTMAIN)
+ set(_isExe $<STREQUAL:$<TARGET_PROPERTY:TYPE>,EXECUTABLE>)
+ set(_isWin32 $<BOOL:$<TARGET_PROPERTY:WIN32_EXECUTABLE>>)
+ set(_isNotExcluded $<NOT:$<BOOL:$<TARGET_PROPERTY:Qt5_NO_LINK_QTMAIN>>>)
+ set(_isPolicyNEW $<TARGET_POLICY:CMP0020>)
+ get_target_property(_configs Qt5::Core IMPORTED_CONFIGURATIONS)
+ foreach(_config ${_configs})
+ set_property(TARGET Qt5::Core APPEND PROPERTY
+ IMPORTED_LINK_INTERFACE_LIBRARIES_${_config}
+ $<$<AND:${_isExe},${_isWin32},${_isNotExcluded},${_isPolicyNEW}>:Qt5::WinMain>
+ )
+ endforeach()
+ unset(_configs)
+ unset(_isExe)
+ unset(_isWin32)
+ unset(_isNotExcluded)
+ unset(_isPolicyNEW)
+ endif()
endif()
!!ENDIF
diff --git a/src/corelib/animation/qabstractanimation.h b/src/corelib/animation/qabstractanimation.h
index e1884aa533..f1aa6c0d78 100644
--- a/src/corelib/animation/qabstractanimation.h
+++ b/src/corelib/animation/qabstractanimation.h
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -177,6 +175,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QABSTRACTANIMATION_H
diff --git a/src/corelib/animation/qanimationgroup.h b/src/corelib/animation/qanimationgroup.h
index 987efa0f94..cf32f844d3 100644
--- a/src/corelib/animation/qanimationgroup.h
+++ b/src/corelib/animation/qanimationgroup.h
@@ -44,8 +44,6 @@
#include <QtCore/qabstractanimation.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -82,6 +80,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QANIMATIONGROUP_H
diff --git a/src/corelib/animation/qparallelanimationgroup.h b/src/corelib/animation/qparallelanimationgroup.h
index ad9c0ccae7..31810cfca2 100644
--- a/src/corelib/animation/qparallelanimationgroup.h
+++ b/src/corelib/animation/qparallelanimationgroup.h
@@ -44,8 +44,6 @@
#include <QtCore/qanimationgroup.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -80,6 +78,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPARALLELANIMATIONGROUP
diff --git a/src/corelib/animation/qpauseanimation.h b/src/corelib/animation/qpauseanimation.h
index 49abad4e5f..5c770015ef 100644
--- a/src/corelib/animation/qpauseanimation.h
+++ b/src/corelib/animation/qpauseanimation.h
@@ -44,8 +44,6 @@
#include <QtCore/qanimationgroup.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -78,6 +76,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPAUSEANIMATION_H
diff --git a/src/corelib/animation/qpropertyanimation.h b/src/corelib/animation/qpropertyanimation.h
index 7b53eb3d96..f6b92cb515 100644
--- a/src/corelib/animation/qpropertyanimation.h
+++ b/src/corelib/animation/qpropertyanimation.h
@@ -44,8 +44,6 @@
#include <QtCore/qvariantanimation.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -83,6 +81,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPROPERTYANIMATION_H
diff --git a/src/corelib/animation/qsequentialanimationgroup.cpp b/src/corelib/animation/qsequentialanimationgroup.cpp
index 2fbb844367..42debea782 100644
--- a/src/corelib/animation/qsequentialanimationgroup.cpp
+++ b/src/corelib/animation/qsequentialanimationgroup.cpp
@@ -266,8 +266,8 @@ QSequentialAnimationGroup::~QSequentialAnimationGroup()
/*!
Adds a pause of \a msecs to this animation group.
- The pause is considered as a special type of animation, thus
- \l{QAnimationGroup::animationCount()}{animationCount} will be
+ The pause is considered as a special type of animation, thus
+ \l{QAnimationGroup::animationCount()}{animationCount} will be
increased by one.
\sa insertPause(), QAnimationGroup::addAnimation()
diff --git a/src/corelib/animation/qsequentialanimationgroup.h b/src/corelib/animation/qsequentialanimationgroup.h
index 9070720669..51b4227599 100644
--- a/src/corelib/animation/qsequentialanimationgroup.h
+++ b/src/corelib/animation/qsequentialanimationgroup.h
@@ -44,8 +44,6 @@
#include <QtCore/qanimationgroup.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -90,6 +88,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QSEQUENTIALANIMATIONGROUP_H
diff --git a/src/corelib/animation/qvariantanimation.cpp b/src/corelib/animation/qvariantanimation.cpp
index 72a7c7264a..f69d9dd8de 100644
--- a/src/corelib/animation/qvariantanimation.cpp
+++ b/src/corelib/animation/qvariantanimation.cpp
@@ -222,7 +222,7 @@ void QVariantAnimationPrivate::updateInterpolator()
interpolator = getInterpolator(type);
else
interpolator = 0;
-
+
//we make sure that the interpolator is always set to something
if (!interpolator)
interpolator = &defaultInterpolator;
@@ -252,7 +252,7 @@ void QVariantAnimationPrivate::recalculateCurrentInterval(bool force/*=false*/)
qMakePair(progress, QVariant()),
animationValueLessThan);
if (it == keyValues.constBegin()) {
- //the item pointed to by it is the start element in the range
+ //the item pointed to by it is the start element in the range
if (it->first == 0 && keyValues.count() > 1) {
currentInterval.start = *it;
currentInterval.end = *(it+1);
diff --git a/src/corelib/animation/qvariantanimation.h b/src/corelib/animation/qvariantanimation.h
index b5ebbd235a..83018c30ae 100644
--- a/src/corelib/animation/qvariantanimation.h
+++ b/src/corelib/animation/qvariantanimation.h
@@ -48,8 +48,6 @@
#include <QtCore/qvariant.h>
#include <QtCore/qpair.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -124,6 +122,4 @@ void qRegisterAnimationInterpolator(QVariant (*func)(const T &from, const T &to,
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QVARIANTANIMATION_H
diff --git a/src/corelib/arch/qatomic_alpha.h b/src/corelib/arch/qatomic_alpha.h
index b842859336..71cb112d47 100644
--- a/src/corelib/arch/qatomic_alpha.h
+++ b/src/corelib/arch/qatomic_alpha.h
@@ -44,10 +44,17 @@
#include <QtCore/qoldbasicatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
+#if 0
+// silence syncqt warnings
+QT_END_NAMESPACE
+QT_END_HEADER
+
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
+#endif
+
#define Q_ATOMIC_INT_REFERENCE_COUNTING_IS_ALWAYS_NATIVE
inline bool QBasicAtomicInt::isReferenceCountingNative()
@@ -517,6 +524,4 @@ Q_INLINE_TEMPLATE T *QBasicAtomicPointer<T>::fetchAndAddOrdered(qptrdiff valueTo
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_ALPHA_H
diff --git a/src/corelib/arch/qatomic_armv5.h b/src/corelib/arch/qatomic_armv5.h
index cdb9c8f979..e0a50b3c24 100644
--- a/src/corelib/arch/qatomic_armv5.h
+++ b/src/corelib/arch/qatomic_armv5.h
@@ -45,15 +45,12 @@
#include <QtCore/qgenericatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
@@ -167,12 +164,20 @@ __asm T QBasicAtomicOps<4>::fetchAndStoreRelaxed(T &_q_value, T newValue) Q_DECL
template<> template <typename T> inline
T QBasicAtomicOps<4>::fetchAndStoreRelaxed(T &_q_value, T newValue) Q_DECL_NOTHROW
{
+#if defined(__thumb__)
+ register T originalValue;
+ do {
+ originalValue = _q_value;
+ } while (_q_cmpxchg(originalValue, newValue, &_q_value) != 0);
+ return originalValue;
+#else
T originalValue;
asm volatile("swp %0,%2,[%3]"
: "=&r"(originalValue), "=m" (_q_value)
: "r"(newValue), "r"(&_q_value)
: "cc", "memory");
return originalValue;
+#endif
}
#endif // Q_CC_RVCT
@@ -190,6 +195,4 @@ T QBasicAtomicOps<4>::fetchAndAddRelaxed(T &_q_value, typename QAtomicAdditiveTy
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_ARMV5_H
diff --git a/src/corelib/arch/qatomic_armv6.h b/src/corelib/arch/qatomic_armv6.h
index 38ab1983d6..7f5939e391 100644
--- a/src/corelib/arch/qatomic_armv6.h
+++ b/src/corelib/arch/qatomic_armv6.h
@@ -45,15 +45,12 @@
#include <QtCore/qgenericatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
@@ -729,6 +726,4 @@ void QBasicAtomicOps<size>::orderedMemoryFence(const T &) Q_DECL_NOTHROW
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_ARMV6_H
diff --git a/src/corelib/arch/qatomic_armv7.h b/src/corelib/arch/qatomic_armv7.h
index fc5dbc9175..1929ae0ab3 100644
--- a/src/corelib/arch/qatomic_armv7.h
+++ b/src/corelib/arch/qatomic_armv7.h
@@ -54,11 +54,12 @@
#if 0
// silence syncqt warnings
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
+
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
#endif
#endif // QATOMIC_ARMV7_H
diff --git a/src/corelib/arch/qatomic_bfin.h b/src/corelib/arch/qatomic_bfin.h
index 24c9ea77e1..79519308a4 100644
--- a/src/corelib/arch/qatomic_bfin.h
+++ b/src/corelib/arch/qatomic_bfin.h
@@ -44,10 +44,17 @@
#include <QtCore/qoldbasicatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
+#if 0
+// silence syncqt warnings
+QT_END_NAMESPACE
+QT_END_HEADER
+
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
+#endif
+
#define Q_ATOMIC_INT_REFERENCE_COUNTING_IS_NOT_NATIVE
inline bool QBasicAtomicInt::isReferenceCountingNative()
@@ -340,6 +347,4 @@ Q_INLINE_TEMPLATE T *QBasicAtomicPointer<T>::fetchAndAddRelease(qptrdiff valueTo
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_BFIN_H
diff --git a/src/corelib/arch/qatomic_bootstrap.h b/src/corelib/arch/qatomic_bootstrap.h
index 5b2a2f86fd..160e0abdf3 100644
--- a/src/corelib/arch/qatomic_bootstrap.h
+++ b/src/corelib/arch/qatomic_bootstrap.h
@@ -45,15 +45,12 @@
#include <QtCore/qgenericatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
@@ -98,6 +95,4 @@ template <typename T> struct QAtomicOps: QGenericAtomicOps<QAtomicOps<T> >
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_BOOTSTRAP_H
diff --git a/src/corelib/arch/qatomic_cxx11.h b/src/corelib/arch/qatomic_cxx11.h
index f7a7ba4295..3119edaf45 100644
--- a/src/corelib/arch/qatomic_cxx11.h
+++ b/src/corelib/arch/qatomic_cxx11.h
@@ -45,14 +45,12 @@
#include <QtCore/qgenericatomic.h>
#include <atomic>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
@@ -247,6 +245,5 @@ template <typename T> struct QAtomicOps
#endif
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QATOMIC_CXX0X_H
diff --git a/src/corelib/arch/qatomic_gcc.h b/src/corelib/arch/qatomic_gcc.h
index 0940ed082f..bd296053e5 100644
--- a/src/corelib/arch/qatomic_gcc.h
+++ b/src/corelib/arch/qatomic_gcc.h
@@ -44,14 +44,12 @@
#include <QtCore/qgenericatomic.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
@@ -132,6 +130,4 @@ template <typename T> struct QAtomicOps: QGenericAtomicOps<QAtomicOps<T> >
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_GCC_H
diff --git a/src/corelib/arch/qatomic_ia64.h b/src/corelib/arch/qatomic_ia64.h
index 1a5259aa09..ed72036076 100644
--- a/src/corelib/arch/qatomic_ia64.h
+++ b/src/corelib/arch/qatomic_ia64.h
@@ -45,15 +45,12 @@
#include <QtCore/qgenericatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
@@ -222,28 +219,28 @@ inline int QBasicAtomicInt::fetchAndStoreAcquire(int newValue)
inline bool QBasicAtomicInt::testAndSetRelaxed(int expectedValue, int newValue)
{
register int expectedValueCopy = expectedValue;
- return (static_cast<int>(_InterlockedCompareExchange(&_q_value,
- newValue,
- expectedValueCopy))
- == expectedValue);
+ return (static_cast<int>(_InterlockedCompareExchange(&_q_value,
+ newValue,
+ expectedValueCopy))
+ == expectedValue);
}
inline bool QBasicAtomicInt::testAndSetAcquire(int expectedValue, int newValue)
{
register int expectedValueCopy = expectedValue;
- return (static_cast<int>(_InterlockedCompareExchange_acq(reinterpret_cast<volatile uint *>(&_q_value),
- newValue,
- expectedValueCopy))
- == expectedValue);
+ return (static_cast<int>(_InterlockedCompareExchange_acq(reinterpret_cast<volatile uint *>(&_q_value),
+ newValue,
+ expectedValueCopy))
+ == expectedValue);
}
inline bool QBasicAtomicInt::testAndSetRelease(int expectedValue, int newValue)
{
register int expectedValueCopy = expectedValue;
- return (static_cast<int>(_InterlockedCompareExchange_rel(reinterpret_cast<volatile uint *>(&_q_value),
- newValue,
- expectedValueCopy))
- == expectedValue);
+ return (static_cast<int>(_InterlockedCompareExchange_rel(reinterpret_cast<volatile uint *>(&_q_value),
+ newValue,
+ expectedValueCopy))
+ == expectedValue);
}
inline int QBasicAtomicInt::fetchAndAddAcquire(int valueToAdd)
@@ -289,10 +286,10 @@ template <typename T>
Q_INLINE_TEMPLATE bool QBasicAtomicPointer<T>::testAndSetRelaxed(T *expectedValue, T *newValue)
{
register T *expectedValueCopy = expectedValue;
- return (_InterlockedCompareExchangePointer(reinterpret_cast<void * volatile*>(&_q_value),
- newValue,
- expectedValueCopy)
- == expectedValue);
+ return (_InterlockedCompareExchangePointer(reinterpret_cast<void * volatile*>(&_q_value),
+ newValue,
+ expectedValueCopy)
+ == expectedValue);
}
template <typename T>
@@ -304,7 +301,7 @@ Q_INLINE_TEMPLATE bool QBasicAtomicPointer<T>::testAndSetAcquire(T *expectedValu
};
x = &_q_value;
register T *expectedValueCopy = expectedValue;
- return (_InterlockedCompareExchange64_acq(p, quintptr(newValue), quintptr(expectedValueCopy))
+ return (_InterlockedCompareExchange64_acq(p, quintptr(newValue), quintptr(expectedValueCopy))
== quintptr(expectedValue));
}
@@ -1089,6 +1086,4 @@ T QBasicAtomicOps<size>::fetchAndAddOrdered(T &_q_value, typename QAtomicAdditiv
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_IA64_H
diff --git a/src/corelib/arch/qatomic_integrity.h b/src/corelib/arch/qatomic_integrity.h
index 50654e6713..f8cfc8ce5b 100644
--- a/src/corelib/arch/qatomic_integrity.h
+++ b/src/corelib/arch/qatomic_integrity.h
@@ -45,10 +45,17 @@
#include <QtCore/qoldbasicatomic.h>
#include <INTEGRITY.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
+#if 0
+// silence syncqt warnings
+QT_END_NAMESPACE
+QT_END_HEADER
+
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
+#endif
+
#define qt_i2addr(a) reinterpret_cast<Address *>(const_cast<int *>(a))
#define qt_p2addr(a) reinterpret_cast<Address *>(const_cast<void *>(a))
#define qt_addr(a) reinterpret_cast<Address>(a)
@@ -284,7 +291,5 @@ Q_INLINE_TEMPLATE T *QBasicAtomicPointer<T>::fetchAndAddRelease(qptrdiff valueTo
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_INTEGRITY_H
diff --git a/src/corelib/arch/qatomic_mips.h b/src/corelib/arch/qatomic_mips.h
index 98ac928184..7716750332 100644
--- a/src/corelib/arch/qatomic_mips.h
+++ b/src/corelib/arch/qatomic_mips.h
@@ -45,15 +45,12 @@
#include <QtCore/qgenericatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
@@ -362,6 +359,4 @@ T QBasicAtomicOps<8>::fetchAndAddRelaxed(T &_q_value, typename QAtomicAdditiveTy
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_MIPS_H
diff --git a/src/corelib/arch/qatomic_msvc.h b/src/corelib/arch/qatomic_msvc.h
index 58b2f30bb7..4f91e3d9da 100644
--- a/src/corelib/arch/qatomic_msvc.h
+++ b/src/corelib/arch/qatomic_msvc.h
@@ -214,14 +214,12 @@ extern "C" {
////////////////////////////////////////////////////////////////////////////////////////////////////
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
@@ -383,6 +381,4 @@ inline T *QAtomicOps<T *>::fetchAndAddRelaxed(T *&_q_value, qptrdiff valueToAdd)
#undef QT_INTERLOCKED_EXCHANGE_ADD_POINTER
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_MSVC_H
diff --git a/src/corelib/arch/qatomic_power.h b/src/corelib/arch/qatomic_power.h
index 5e4de3f9fd..ad1c619d56 100644
--- a/src/corelib/arch/qatomic_power.h
+++ b/src/corelib/arch/qatomic_power.h
@@ -44,10 +44,17 @@
#include <QtCore/qoldbasicatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
+#if 0
+// silence syncqt warnings
+QT_END_NAMESPACE
+QT_END_HEADER
+
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
+#endif
+
#define Q_ATOMIC_INT_REFERENCE_COUNTING_IS_ALWAYS_NATIVE
inline bool QBasicAtomicInt::isReferenceCountingNative()
@@ -511,6 +518,4 @@ Q_INLINE_TEMPLATE T *QBasicAtomicPointer<T>::fetchAndAddOrdered(qptrdiff valueTo
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_POWER_H
diff --git a/src/corelib/arch/qatomic_s390.h b/src/corelib/arch/qatomic_s390.h
index c24c243c03..0469f44e5f 100644
--- a/src/corelib/arch/qatomic_s390.h
+++ b/src/corelib/arch/qatomic_s390.h
@@ -44,10 +44,17 @@
#include <QtCore/qoldbasicatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
+#if 0
+// silence syncqt warnings
+QT_END_NAMESPACE
+QT_END_HEADER
+
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
+#endif
+
#define Q_ATOMIC_INT_REFERENCE_COUNTING_IS_ALWAYS_NATIVE
inline bool QBasicAtomicInt::isReferenceCountingNative()
@@ -423,6 +430,4 @@ Q_INLINE_TEMPLATE T *QBasicAtomicPointer<T>::fetchAndAddRelease(qptrdiff valueTo
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_S390_H
diff --git a/src/corelib/arch/qatomic_sh4a.h b/src/corelib/arch/qatomic_sh4a.h
index 0fd96d1f0f..08f75e44f2 100644
--- a/src/corelib/arch/qatomic_sh4a.h
+++ b/src/corelib/arch/qatomic_sh4a.h
@@ -44,14 +44,15 @@
#include <QtCore/qoldbasicatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
+#if 0
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
+#endif
#define Q_ATOMIC_INT_REFERENCE_COUNTING_IS_ALWAYS_NATIVE
diff --git a/src/corelib/arch/qatomic_sparc.h b/src/corelib/arch/qatomic_sparc.h
index 1bf625fbb1..8aea33ce85 100644
--- a/src/corelib/arch/qatomic_sparc.h
+++ b/src/corelib/arch/qatomic_sparc.h
@@ -44,10 +44,17 @@
#include <QtCore/qoldbasicatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
+#if 0
+// silence syncqt warnings
+QT_END_NAMESPACE
+QT_END_HEADER
+
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
+#endif
+
#if defined(_LP64)
#define Q_ATOMIC_INT_REFERENCE_COUNTING_IS_ALWAYS_NATIVE
@@ -522,6 +529,4 @@ Q_INLINE_TEMPLATE T *QBasicAtomicPointer<T>::fetchAndAddRelease(qptrdiff valueTo
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_SPARC_H
diff --git a/src/corelib/arch/qatomic_unix.h b/src/corelib/arch/qatomic_unix.h
index 0e9c105d57..03c7d2eee8 100644
--- a/src/corelib/arch/qatomic_unix.h
+++ b/src/corelib/arch/qatomic_unix.h
@@ -44,14 +44,12 @@
#include <QtCore/qgenericatomic.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
@@ -112,6 +110,4 @@ struct QAtomicOps<T *> : QGenericAtomicOps<QAtomicOps<T *> >
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_UNIX_H
diff --git a/src/corelib/arch/qatomic_vxworks.h b/src/corelib/arch/qatomic_vxworks.h
index a8664cf752..57e3b6a32b 100644
--- a/src/corelib/arch/qatomic_vxworks.h
+++ b/src/corelib/arch/qatomic_vxworks.h
@@ -42,8 +42,6 @@
#ifndef QATOMIC_VXWORKS_H
#define QATOMIC_VXWORKS_H
-QT_BEGIN_HEADER
-
#if defined(__ppc)
# include <QtCore/qatomic_power.h>
#else // generic implementation with taskLock()
@@ -56,14 +54,28 @@ QT_BEGIN_HEADER
# include <vxWorksCommon.h>
# include <taskLib.h>
#else
+#if defined(_WRS_KERNEL)
extern "C" int taskLock();
extern "C" int taskUnlock();
+#else
+inline int taskLock() { return 0; }
+inline int taskUnlock() { return 0; }
+#endif
#endif
QT_BEGIN_NAMESPACE
+#if 0
+// silence syncqt warnings
+QT_END_NAMESPACE
+QT_END_HEADER
+
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
+#endif
+
#define Q_ATOMIC_INT_REFERENCE_COUNTING_IS_NOT_NATIVE
inline bool QBasicAtomicInt::isReferenceCountingNative()
@@ -315,6 +327,4 @@ QT_END_NAMESPACE
#endif // generic implementation with taskLock()
-QT_END_HEADER
-
#endif // QATOMIC_VXWORKS_H
diff --git a/src/corelib/arch/qatomic_x86.h b/src/corelib/arch/qatomic_x86.h
index 077cfd1336..f8180ad9d6 100644
--- a/src/corelib/arch/qatomic_x86.h
+++ b/src/corelib/arch/qatomic_x86.h
@@ -45,15 +45,12 @@
#include <QtCore/qgenericatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
@@ -423,6 +420,4 @@ template <> struct QBasicAtomicOps<8>: QGenericAtomicOps<QBasicAtomicOps<8> >
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_X86_H
diff --git a/src/corelib/arch/sparc/arch.pri b/src/corelib/arch/sparc/arch.pri
index b3ca399640..a201c83c6a 100644
--- a/src/corelib/arch/sparc/arch.pri
+++ b/src/corelib/arch/sparc/arch.pri
@@ -3,7 +3,7 @@
#
*-64* {
SOURCES += $$PWD/qatomic64.s
-}
+}
else {
SOURCES += $$PWD/qatomic32.s \
$$PWD/qatomic_sparc.cpp
diff --git a/src/corelib/arch/sparc/qatomic_sparc.cpp b/src/corelib/arch/sparc/qatomic_sparc.cpp
index d0a9eb8d29..8ea270e90a 100644
--- a/src/corelib/arch/sparc/qatomic_sparc.cpp
+++ b/src/corelib/arch/sparc/qatomic_sparc.cpp
@@ -60,7 +60,7 @@ Q_CORE_EXPORT int q_atomic_lock_int(volatile int *addr)
sched_yield();
returnValue = *addr;
} while (returnValue == INT_MIN);
-
+
// try again
returnValue = q_atomic_trylock_int(addr);
} while (returnValue == INT_MIN);
diff --git a/src/corelib/codecs/qeuckrcodec.cpp b/src/corelib/codecs/qeuckrcodec.cpp
index a6d75666d5..20ba1e85d6 100644
--- a/src/corelib/codecs/qeuckrcodec.cpp
+++ b/src/corelib/codecs/qeuckrcodec.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-// Most of the cp949 code was originally written by Joon-Kyu Park, and is included
+// Most of the cp949 code was originally written by Joon-Kyu Park, and is included
// in Qt with the author's permission and the grateful thanks of the Qt team.
/*! \class QEucKrCodec
@@ -3405,7 +3405,7 @@ QByteArray QCP949Codec::convertFromUnicode(const QChar *uc, int len, ConverterSt
row = internal_code / 178;
column = internal_code % 178;
}
- else {
+ else {
// code between a1-fe
internal_code -= 3008;
row = internal_code / 84;
diff --git a/src/corelib/codecs/qiconvcodec.cpp b/src/corelib/codecs/qiconvcodec.cpp
index 01b90fe527..60b13ac4e1 100644
--- a/src/corelib/codecs/qiconvcodec.cpp
+++ b/src/corelib/codecs/qiconvcodec.cpp
@@ -374,7 +374,7 @@ QByteArray QIconvCodec::convertFromUnicode(const QChar *uc, int len, ConverterSt
delete temporaryState;
return QString(uc, len).toLatin1();
}
-
+
size_t outBytesLeft = len;
QByteArray ba(outBytesLeft, Qt::Uninitialized);
outBytes = ba.data();
diff --git a/src/corelib/codecs/qicucodec.cpp b/src/corelib/codecs/qicucodec.cpp
index 000f6872b5..9afae8c0ee 100644
--- a/src/corelib/codecs/qicucodec.cpp
+++ b/src/corelib/codecs/qicucodec.cpp
@@ -457,7 +457,8 @@ QTextCodec *QIcuCodec::codecForNameUnlocked(const char *name)
if (!qstrcmp(name, "windows-874-2000")
|| !qstrcmp(name, "windows-874")
|| !qstrcmp(name, "MS874")
- || !qstrcmp(name, "x-windows-874"))
+ || !qstrcmp(name, "x-windows-874")
+ || !qstrcmp(name, "ISO 8859-11"))
name = "TIS-620";
UErrorCode error = U_ZERO_ERROR;
diff --git a/src/corelib/codecs/qjpunicode.cpp b/src/corelib/codecs/qjpunicode.cpp
index 95ffe11f75..9513621dfe 100644
--- a/src/corelib/codecs/qjpunicode.cpp
+++ b/src/corelib/codecs/qjpunicode.cpp
@@ -10537,7 +10537,7 @@ static unsigned short const sjis208ibmvdc_unicode[] = {
uint QJpUnicodeConv::sjisibmvdcToUnicode(uint h, uint l) const
{
- if (((rule & IBM_VDC) || (rule & Microsoft_CP932)) && IsSjisIBMVDCChar1(h))
+ if (((rule & IBM_VDC) || (rule & Microsoft_CP932)) && IsSjisIBMVDCChar1(h))
return sjis208ibmvdc_unicode[((h - 0x00fa)*189 + (l-0x0040))];
else
return 0;
@@ -10632,9 +10632,9 @@ static unsigned short const cp932_ed_ee_unicode[] = {
uint QJpUnicodeConv::cp932ToUnicode(uint h, uint l) const
{
if (rule & Microsoft_CP932) {
- if (h == 0x0087 && (l >= 0x0040 && l <= 0x009c))
+ if (h == 0x0087 && (l >= 0x0040 && l <= 0x009c))
return cp932_87_unicode[l-0x0040];
- else if ((h == 0x00ed || h == 0x00ee) && (l >= 0x0040 && l <= 0x00fc))
+ else if ((h == 0x00ed || h == 0x00ee) && (l >= 0x0040 && l <= 0x00fc))
return cp932_ed_ee_unicode[((h - 0x00ed)*189 + (l-0x0040))];
}
return 0;
diff --git a/src/corelib/codecs/qtextcodec.cpp b/src/corelib/codecs/qtextcodec.cpp
index 0e671518ef..1a5c9f6766 100644
--- a/src/corelib/codecs/qtextcodec.cpp
+++ b/src/corelib/codecs/qtextcodec.cpp
@@ -89,7 +89,7 @@
#include <stdlib.h>
#include <ctype.h>
#include <locale.h>
-#if defined (_XOPEN_UNIX) && !defined(Q_OS_QNX) && !defined(Q_OS_OSF) && !defined(Q_OS_LINUX_ANDROID)
+#if defined (_XOPEN_UNIX) && !defined(Q_OS_QNX) && !defined(Q_OS_OSF) && !defined(Q_OS_ANDROID)
# include <langinfo.h>
#endif
@@ -1043,28 +1043,30 @@ QString QTextDecoder::toUnicode(const QByteArray &ba)
QTextCodec *QTextCodec::codecForHtml(const QByteArray &ba, QTextCodec *defaultCodec)
{
// determine charset
- int pos;
- QTextCodec *c = 0;
-
- c = QTextCodec::codecForUtfText(ba, c);
+ QTextCodec *c = QTextCodec::codecForUtfText(ba, 0);
if (!c) {
QByteArray header = ba.left(512).toLower();
- if ((pos = header.indexOf("http-equiv=")) != -1) {
- if ((pos = header.lastIndexOf("meta ", pos)) != -1) {
- pos = header.indexOf("charset=", pos) + int(strlen("charset="));
- if (pos != -1) {
- int pos2 = header.indexOf('\"', pos+1);
- QByteArray cs = header.mid(pos, pos2-pos);
- // qDebug("found charset: %s", cs.data());
- c = QTextCodec::codecForName(cs);
+ int pos = header.indexOf("meta ");
+ if (pos != -1) {
+ pos = header.indexOf("charset=", pos);
+ if (pos != -1) {
+ pos += qstrlen("charset=");
+
+ int pos2 = pos;
+ // The attribute can be closed with either """, "'", ">" or "/",
+ // none of which are valid charset characters.
+ while (++pos2 < header.size()) {
+ char ch = header.at(pos2);
+ if (ch == '\"' || ch == '\'' || ch == '>') {
+ c = QTextCodec::codecForName(header.mid(pos, pos2 - pos));
+ return c ? c : defaultCodec;
+ }
}
}
}
}
- if (!c)
- c = defaultCodec;
- return c;
+ return defaultCodec;
}
/*!
diff --git a/src/corelib/codecs/qtextcodec.h b/src/corelib/codecs/qtextcodec.h
index ac0bc77ea5..35ff83a27a 100644
--- a/src/corelib/codecs/qtextcodec.h
+++ b/src/corelib/codecs/qtextcodec.h
@@ -45,8 +45,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -166,6 +164,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEXTCODEC_H
diff --git a/src/corelib/codecs/qtextcodec_p.h b/src/corelib/codecs/qtextcodec_p.h
index 18629f4bf3..0fec1e80c7 100644
--- a/src/corelib/codecs/qtextcodec_p.h
+++ b/src/corelib/codecs/qtextcodec_p.h
@@ -60,7 +60,7 @@ QT_BEGIN_NAMESPACE
#ifndef QT_NO_TEXTCODEC
-#if defined(Q_OS_MAC) || defined(Q_OS_IOS) || defined(Q_OS_LINUX_ANDROID) || defined(Q_OS_QNX)
+#if defined(Q_OS_MAC) || defined(Q_OS_IOS) || defined(Q_OS_ANDROID) || defined(Q_OS_QNX)
#define QT_LOCALE_IS_UTF8
#endif
diff --git a/src/corelib/corelib.pro b/src/corelib/corelib.pro
index 4462203a11..3b7eb11229 100644
--- a/src/corelib/corelib.pro
+++ b/src/corelib/corelib.pro
@@ -16,6 +16,12 @@ win32-g++*:QMAKE_CXXFLAGS_CXX11 = -std=gnu++0x
QMAKE_DOCS = $$PWD/doc/qtcore.qdocconf
+ANDROID_JAR_DEPENDENCIES = \
+ jar/QtAndroid.jar
+ANDROID_LIB_DEPENDENCIES = \
+ plugins/platforms/android/libqtforandroid.so \
+ libs/libgnustl_shared.so
+
load(qt_module)
include(animation/animation.pri)
@@ -63,10 +69,19 @@ ctest_macros_file.input = $$PWD/Qt5CTestMacros.cmake
ctest_macros_file.output = $$DESTDIR/cmake/Qt5Core/Qt5CTestMacros.cmake
ctest_macros_file.CONFIG = verbatim
-QMAKE_SUBSTITUTES += ctest_macros_file
+cmake_umbrella_config_file.input = $$PWD/Qt5Config.cmake.in
+cmake_umbrella_config_file.output = $$DESTDIR/cmake/Qt5/Qt5Config.cmake
+
+cmake_umbrella_config_version_file.input = $$PWD/../../mkspecs/features/data/cmake/Qt5ConfigVersion.cmake.in
+cmake_umbrella_config_version_file.output = $$DESTDIR/cmake/Qt5/Qt5ConfigVersion.cmake
+
+cmake_qt5_umbrella_module_files.files = $$cmake_umbrella_config_file.output $$cmake_umbrella_config_version_file.output
+cmake_qt5_umbrella_module_files.path = $$[QT_INSTALL_LIBS]/cmake/Qt5
+
+QMAKE_SUBSTITUTES += ctest_macros_file cmake_umbrella_config_file cmake_umbrella_config_version_file
ctest_qt5_module_files.files += $$ctest_macros_file.output
ctest_qt5_module_files.path = $$[QT_INSTALL_LIBS]/cmake/Qt5Core
-INSTALLS += ctest_qt5_module_files
+INSTALLS += ctest_qt5_module_files cmake_qt5_umbrella_module_files
diff --git a/src/corelib/doc/snippets/code/doc_src_properties.cpp b/src/corelib/doc/snippets/code/doc_src_properties.cpp
index 9a25918d47..7a70200cce 100644
--- a/src/corelib/doc/snippets/code/doc_src_properties.cpp
+++ b/src/corelib/doc/snippets/code/doc_src_properties.cpp
@@ -40,8 +40,8 @@
//! [0]
Q_PROPERTY(type name
- READ getFunction
- [WRITE setFunction]
+ (READ getFunction [WRITE setFunction] |
+ MEMBER memberName [(READ getFunction | WRITE setFunction)])
[RESET resetFunction]
[NOTIFY notifySignal]
[REVISION int]
@@ -130,3 +130,20 @@ object->setProperty("priority", "VeryHigh");
//! [7]
Q_CLASSINFO("Version", "3.0.0")
//! [7]
+
+//! [8]
+ Q_PROPERTY(QColor color MEMBER m_color NOTIFY colorChanged)
+ Q_PROPERTY(qreal spacing MEMBER m_spacing NOTIFY spacingChanged)
+ Q_PROPERTY(QString text MEMBER m_text NOTIFY textChanged)
+ ...
+signals:
+ void colorChanged();
+ void spacingChanged();
+ void textChanged(const QString &newText);
+
+private:
+ QColor m_color;
+ qreal m_spacing;
+ QString m_text;
+//! [8]
+
diff --git a/src/corelib/doc/snippets/code/src_corelib_global_qglobal.cpp b/src/corelib/doc/snippets/code/src_corelib_global_qglobal.cpp
index 7d7d71ac50..59f05592be 100644
--- a/src/corelib/doc/snippets/code/src_corelib_global_qglobal.cpp
+++ b/src/corelib/doc/snippets/code/src_corelib_global_qglobal.cpp
@@ -501,7 +501,7 @@ namespace QT_NAMESPACE {
//! [43]
class MyClass : public QObject
{
-
+
private:
Q_DISABLE_COPY(MyClass)
};
@@ -511,7 +511,7 @@ class MyClass : public QObject
//! [44]
class MyClass : public QObject
{
-
+
private:
MyClass(const MyClass &);
MyClass &operator=(const MyClass &);
diff --git a/src/corelib/doc/snippets/code/src_corelib_kernel_qabstractitemmodel.cpp b/src/corelib/doc/snippets/code/src_corelib_kernel_qabstractitemmodel.cpp
index 2f81b15752..c448c75206 100644
--- a/src/corelib/doc/snippets/code/src_corelib_kernel_qabstractitemmodel.cpp
+++ b/src/corelib/doc/snippets/code/src_corelib_kernel_qabstractitemmodel.cpp
@@ -97,3 +97,37 @@ beginResetModel();
myData.clear();
endResetModel();
//! [11]
+
+//! [12]
+class CustomDataProxy : public QSortFilterProxyModel
+{
+ Q_OBJECT
+public:
+ CustomDataProxy(QObject *parent)
+ : QSortFilterProxyModel(parent)
+ {
+ }
+
+ ...
+
+ QVariant data(const QModelIndex &index, int role)
+ {
+ if (role != Qt::BackgroundRole)
+ return QSortFilterProxyModel::data(index, role);
+
+ if (m_customData.contains(index.row()))
+ return m_customData.value(index.row());
+ return QSortFilterProxyModel::data(index, role);
+ }
+
+private slots:
+ void resetInternalData()
+ {
+ m_customData.clear();
+ }
+
+private:
+ QHash<int, QVariant> m_customData;
+};
+//! [12]
+
diff --git a/src/corelib/doc/snippets/code/src_corelib_kernel_qcoreapplication.cpp b/src/corelib/doc/snippets/code/src_corelib_kernel_qcoreapplication.cpp
index cbb5a9db5d..c349a6dbba 100644
--- a/src/corelib/doc/snippets/code/src_corelib_kernel_qcoreapplication.cpp
+++ b/src/corelib/doc/snippets/code/src_corelib_kernel_qcoreapplication.cpp
@@ -57,7 +57,14 @@ foreach (const QString &path, app.libraryPaths())
//! [3]
+// Called once QCoreApplication exists
+static void preRoutineMyDebugTool()
+{
+ MyDebugTool* tool = new MyDebugTool(QCoreApplication::instance());
+ QCoreApplication::instance()->installEventFilter(tool);
+}
+Q_COREAPP_STARTUP_FUNCTION(preRoutineMyDebugTool)
//! [3]
diff --git a/src/corelib/doc/snippets/code/src_corelib_kernel_qmath.cpp b/src/corelib/doc/snippets/code/src_corelib_kernel_qmath.cpp
new file mode 100644
index 0000000000..71a2a09a7d
--- /dev/null
+++ b/src/corelib/doc/snippets/code/src_corelib_kernel_qmath.cpp
@@ -0,0 +1,63 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Laszlo Papp <lpapp@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the documentation 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$
+**
+****************************************************************************/
+
+//! [0]
+float degrees = 180.0f
+float radians = qDegreesToRadians(degrees)
+//! [0]
+
+
+//! [1]
+double degrees = 180.0
+double radians = qDegreesToRadians(degrees)
+//! [1]
+
+
+//! [2]
+float radians = float(M_PI)
+float degrees = qRadiansToDegrees(radians)
+//! [2]
+
+
+//! [3]
+double radians = M_PI
+double degrees = qRadiansToDegrees(radians)
+//! [3]
+
diff --git a/src/corelib/doc/snippets/code/src_corelib_kernel_qobject.cpp b/src/corelib/doc/snippets/code/src_corelib_kernel_qobject.cpp
index bafd3f8eb8..68df53e0da 100644
--- a/src/corelib/doc/snippets/code/src_corelib_kernel_qobject.cpp
+++ b/src/corelib/doc/snippets/code/src_corelib_kernel_qobject.cpp
@@ -374,6 +374,7 @@ Q_PROPERTY(type name
[WRITE setFunction]
[RESET resetFunction]
[NOTIFY notifySignal]
+ [REVISION int]
[DESIGNABLE bool]
[SCRIPTABLE bool]
[STORED bool]
diff --git a/src/corelib/doc/snippets/code/src_corelib_thread_qwaitcondition_unix.cpp b/src/corelib/doc/snippets/code/src_corelib_thread_qwaitcondition_unix.cpp
index de1a7cea19..92a6e77866 100644
--- a/src/corelib/doc/snippets/code/src_corelib_thread_qwaitcondition_unix.cpp
+++ b/src/corelib/doc/snippets/code/src_corelib_thread_qwaitcondition_unix.cpp
@@ -84,6 +84,6 @@ forever {
mutex.lock();
}
keyPressed.wakeAll();
- mutex.unlock();
+ mutex.unlock();
}
//! [3]
diff --git a/src/corelib/doc/snippets/code/src_corelib_tools_qbytearray.cpp b/src/corelib/doc/snippets/code/src_corelib_tools_qbytearray.cpp
index 7e221cfaab..4f8c4c095e 100644
--- a/src/corelib/doc/snippets/code/src_corelib_tools_qbytearray.cpp
+++ b/src/corelib/doc/snippets/code/src_corelib_tools_qbytearray.cpp
@@ -405,7 +405,7 @@ QString tmp = "test";
QByteArray text = tmp.toLocal8Bit();
char *data = new char[text.size()]
strcpy(data, text.data());
-delete [] data;
+delete [] data;
//! [46]
//! [47]
diff --git a/src/corelib/doc/snippets/code/src_corelib_tools_qpoint.cpp b/src/corelib/doc/snippets/code/src_corelib_tools_qpoint.cpp
index a83fd9a71f..8c6751cbaa 100644
--- a/src/corelib/doc/snippets/code/src_corelib_tools_qpoint.cpp
+++ b/src/corelib/doc/snippets/code/src_corelib_tools_qpoint.cpp
@@ -79,6 +79,13 @@ p *= 2.5; // p becomes (-3, 10)
//! [5]
+//! [16]
+QPoint p( 3, 7);
+QPoint q(-1, 4);
+int lengthSquared = QPoint::dotProduct(p, q); // lengthSquared becomes 25
+//! [16]
+
+
//! [6]
QPoint p(-3, 10);
p /= 2.5; // p becomes (-1, 4)
@@ -147,3 +154,10 @@ p *= 2.5; // p becomes (-2.75, 10.25)
QPointF p(-2.75, 10.25);
p /= 2.5; // p becomes (-1.1, 4.1)
//! [15]
+
+
+//! [17]
+QPointF p( 3.1, 7.1);
+QPointF q(-1.0, 4.1);
+int lengthSquared = QPointF::dotProduct(p, q); // lengthSquared becomes 26.01
+//! [17]
diff --git a/src/corelib/doc/snippets/fileinfo/main.cpp b/src/corelib/doc/snippets/fileinfo/main.cpp
index 57d7e32cb5..50acdb2550 100644
--- a/src/corelib/doc/snippets/fileinfo/main.cpp
+++ b/src/corelib/doc/snippets/fileinfo/main.cpp
@@ -54,12 +54,12 @@ int main(int argc, char *argv[])
QFileInfo fileInfo1("~/examples/191697/.");
QFileInfo fileInfo2("~/examples/191697/..");
QFileInfo fileInfo3("~/examples/191697/main.cpp");
-//! [0]
-//! [1]
+//! [0]
+//! [1]
QFileInfo fileInfo4(".");
QFileInfo fileInfo5("..");
QFileInfo fileInfo6("main.cpp");
-//! [1]
+//! [1]
qDebug() << fileInfo1.fileName();
qDebug() << fileInfo2.fileName();
diff --git a/src/corelib/doc/snippets/qmessageauthenticationcode/main.cpp b/src/corelib/doc/snippets/qmessageauthenticationcode/main.cpp
new file mode 100644
index 0000000000..4441fbd9a1
--- /dev/null
+++ b/src/corelib/doc/snippets/qmessageauthenticationcode/main.cpp
@@ -0,0 +1,62 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Ruslan Nigmatullin <euroelessar@yandex.ru>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the documentation 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$
+**
+****************************************************************************/
+
+#include <QtCore>
+
+int main(int argc, char *argv[])
+{
+ QCoreApplication app(argc, argv);
+
+//! [0]
+ QByteArray key = "key";
+ QByteArray message = "The quick brown fox jumps over the lazy dog";
+//! [0]
+
+//! [1]
+ QMessageAuthenticationCode code(QCryptographicHash::Sha1);
+ code.setKey(key);
+ code.addData(message);
+ code.result().toHex(); // returns "de7c9b85b8b78aa6bc8a7a36f70a90701c9db4d9"
+//! [1]
+
+//! [2]
+ QMessageAuthenticationCode::hash(message, key, QCryptographicHash::Sha1).toHex();
+//! [2]
+}
diff --git a/src/corelib/doc/snippets/qmetaobject-revision/main.cpp b/src/corelib/doc/snippets/qmetaobject-revision/main.cpp
new file mode 100644
index 0000000000..99a860b778
--- /dev/null
+++ b/src/corelib/doc/snippets/qmetaobject-revision/main.cpp
@@ -0,0 +1,72 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Research In Motion.
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the documentation 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$
+**
+****************************************************************************/
+
+#include <QApplication>
+#include <QMetaObject>
+#include <QMetaMethod>
+#include <QMetaProperty>
+#include <QDebug>
+#include "window.h"
+
+void exposeMethod(const QMetaMethod &)
+{
+}
+
+void exposeProperty(const QMetaProperty &)
+{
+}
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+//! [Window class using revision]
+ Window window;
+ int expectedRevision = 0;
+ const QMetaObject *windowMetaObject = window.metaObject();
+ for (int i=0; i < windowMetaObject->methodCount(); i++)
+ if (windowMetaObject->method(i).revision() <= expectedRevision)
+ exposeMethod(windowMetaObject->method(i));
+ for (int i=0; i < windowMetaObject->propertyCount(); i++)
+ if (windowMetaObject->property(i).revision() <= expectedRevision)
+ exposeProperty(windowMetaObject->property(i));
+//! [Window class using revision]
+ window.show();
+ return app.exec();
+}
diff --git a/src/corelib/doc/snippets/qmetaobject-revision/qmetaobject-revision.pro b/src/corelib/doc/snippets/qmetaobject-revision/qmetaobject-revision.pro
new file mode 100644
index 0000000000..ec9d7db658
--- /dev/null
+++ b/src/corelib/doc/snippets/qmetaobject-revision/qmetaobject-revision.pro
@@ -0,0 +1,4 @@
+QT += widgets
+HEADERS = window.h
+SOURCES = main.cpp \
+ window.cpp
diff --git a/src/corelib/doc/snippets/qmetaobject-revision/window.cpp b/src/corelib/doc/snippets/qmetaobject-revision/window.cpp
new file mode 100644
index 0000000000..0315f831be
--- /dev/null
+++ b/src/corelib/doc/snippets/qmetaobject-revision/window.cpp
@@ -0,0 +1,66 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Research In Motion.
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the documentation 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$
+**
+****************************************************************************/
+
+#include "window.h"
+
+Window::Window()
+{
+}
+
+int Window::normalProperty()
+{
+ return 0;
+}
+
+int Window::newProperty()
+{
+ return 1;
+}
+
+void Window::normalMethod()
+{
+ show();
+}
+
+void Window::newMethod()
+{
+ // Can be hidden from users expecting the initial API
+ show();
+}
diff --git a/src/corelib/doc/snippets/qmetaobject-revision/window.h b/src/corelib/doc/snippets/qmetaobject-revision/window.h
new file mode 100644
index 0000000000..6e56f3dfef
--- /dev/null
+++ b/src/corelib/doc/snippets/qmetaobject-revision/window.h
@@ -0,0 +1,63 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Research In Motion.
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the documentation 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$
+**
+****************************************************************************/
+
+#ifndef WINDOW_H
+#define WINDOW_H
+
+#include <QWidget>
+
+//! [Window class with revision]
+class Window : public QWidget
+{
+ Q_OBJECT
+ Q_PROPERTY(int normalProperty READ normalProperty)
+ Q_PROPERTY(int newProperty READ newProperty REVISION 1)
+
+public:
+ Window();
+ int normalProperty();
+ int newProperty();
+public slots:
+ void normalMethod();
+ Q_REVISION(1) void newMethod();
+};
+//! [Window class with revision]
+
+#endif
diff --git a/src/corelib/doc/snippets/qstring/main.cpp b/src/corelib/doc/snippets/qstring/main.cpp
index 6ee3088138..bf45a31c29 100644
--- a/src/corelib/doc/snippets/qstring/main.cpp
+++ b/src/corelib/doc/snippets/qstring/main.cpp
@@ -552,7 +552,7 @@ void Widget::replaceFunction()
//! [86]
QString equis = "xxxxxx";
equis.replace("xx", "x");
- // equis == "xxx"
+ // equis == "xxx"
//! [86]
//! [87]
diff --git a/src/corelib/doc/snippets/sharedemployee/employee.h b/src/corelib/doc/snippets/sharedemployee/employee.h
index 8025015a2e..2df1f71c51 100644
--- a/src/corelib/doc/snippets/sharedemployee/employee.h
+++ b/src/corelib/doc/snippets/sharedemployee/employee.h
@@ -69,11 +69,11 @@ class Employee
setName(name);
}
//! [2] //! [7]
- Employee(const Employee &other)
- : d (other.d)
- {
- }
-//! [7]
+ Employee(const Employee &other)
+ : d (other.d)
+ {
+ }
+//! [7]
//! [3]
void setId(int id) { d->id = id; }
//! [3] //! [4]
diff --git a/src/corelib/doc/snippets/signalmapper/filereader.cpp b/src/corelib/doc/snippets/signalmapper/filereader.cpp
index 42660b9551..cb83ea9362 100644
--- a/src/corelib/doc/snippets/signalmapper/filereader.cpp
+++ b/src/corelib/doc/snippets/signalmapper/filereader.cpp
@@ -73,7 +73,7 @@ FileReader::FileReader(QWidget *parent)
/*
//! [2]
//slower due to signature normalization at runtime
-
+
connect(signalMapper, SIGNAL(mapped(const QString &)),
this, SLOT(readFile(const QString &)));
//! [2]
@@ -93,7 +93,7 @@ FileReader::FileReader(QWidget *parent)
void FileReader::readFile(const QString &filename)
{
QFile file(filename);
-
+
if (!file.open(QIODevice::ReadOnly)) {
QMessageBox::information(this, tr("Unable to open file"),
file.errorString());
diff --git a/src/corelib/doc/snippets/statemachine/eventtest.cpp b/src/corelib/doc/snippets/statemachine/eventtest.cpp
index c83e92ab77..7454344680 100644
--- a/src/corelib/doc/snippets/statemachine/eventtest.cpp
+++ b/src/corelib/doc/snippets/statemachine/eventtest.cpp
@@ -55,11 +55,11 @@ protected:
if (wrappedEvent->type() == QEvent::KeyPress) {
QKeyEvent *keyEvent = static_cast<QKeyEvent *>(wrappedEvent);
// Do your event test
- }
+ }
}
return false;
}
-//![0]
+//![0]
void onTransition(QEvent *event)
{
diff --git a/src/corelib/doc/snippets/statemachine/main4.cpp b/src/corelib/doc/snippets/statemachine/main4.cpp
index f1ecabd535..19b40a10b4 100644
--- a/src/corelib/doc/snippets/statemachine/main4.cpp
+++ b/src/corelib/doc/snippets/statemachine/main4.cpp
@@ -69,7 +69,7 @@ protected:
StringEvent *se = static_cast<StringEvent*>(e);
return (m_value == se->value);
}
-
+
virtual void onTransition(QEvent *) {}
private:
diff --git a/src/corelib/doc/snippets/streaming/main.cpp b/src/corelib/doc/snippets/streaming/main.cpp
index 66808a5a6b..673df075ee 100644
--- a/src/corelib/doc/snippets/streaming/main.cpp
+++ b/src/corelib/doc/snippets/streaming/main.cpp
@@ -85,12 +85,12 @@ int main(int argc, char *argv[])
QByteArray byteArray;
QDataStream stream(&byteArray, QIODevice::WriteOnly);
stream << m;
-
+
// display
qDebug() << m.id << m.releaseDate << m.title;
Movie m2;
-
+
int id2;
QString title2;
QDate date2;
diff --git a/src/corelib/doc/snippets/timers/timers.cpp b/src/corelib/doc/snippets/timers/timers.cpp
index 4d74e7cc27..8257bf57a7 100644
--- a/src/corelib/doc/snippets/timers/timers.cpp
+++ b/src/corelib/doc/snippets/timers/timers.cpp
@@ -74,5 +74,5 @@ Foo::Foo()
int main()
{
-
+
}
diff --git a/src/corelib/doc/src/objectmodel/object.qdoc b/src/corelib/doc/src/objectmodel/object.qdoc
index 281c1a30cb..89a781da39 100644
--- a/src/corelib/doc/src/objectmodel/object.qdoc
+++ b/src/corelib/doc/src/objectmodel/object.qdoc
@@ -66,16 +66,12 @@
by Qt's own \l{moc}{Meta-Object Compiler (moc)}.
The meta-object system is a C++ extension that makes the language
- better suited to true component GUI programming. Although
- templates can be used to extend C++, the meta-object system
- provides benefits using standard C++ that cannot be achieved with
- templates; see \l{Why Doesn't Qt Use Templates for Signals and
- Slots?}
+ better suited to true component GUI programming.
\section1 Important Classes
These classes form the basis of the Qt Object Model.
-
+
\annotatedlist objectmodel
\target Identity vs Value
@@ -112,7 +108,7 @@
at runtime that are not declared in the C++ class. If we copy a Qt
Object, should the copy include the properties that were added to
the original?
-
+
\endlist
For these reasons, Qt Objects should be treated as identities, not
diff --git a/src/corelib/doc/src/objectmodel/properties.qdoc b/src/corelib/doc/src/objectmodel/properties.qdoc
index 39f5e80eaa..d1690c5908 100644
--- a/src/corelib/doc/src/objectmodel/properties.qdoc
+++ b/src/corelib/doc/src/objectmodel/properties.qdoc
@@ -53,16 +53,22 @@
\snippet code/doc_src_properties.cpp 1
+ Here is an example showing how to export member variables as Qt
+ properties using the \c MEMBER keyword.
+ Note that a \c NOTIFY signal must be specified to allow QML property bindings.
+
+ \snippet code/doc_src_properties.cpp 8
+
A property behaves like a class data member, but it has additional
features accessible through the \l {Meta-Object System}.
- \list
+ \list
- \li A \c READ accessor function is required. It is for reading the
- property value. Ideally, a const function is used for this purpose,
- and it must return either the property's type or a pointer or
- reference to that type. e.g., QWidget::focus is a read-only property
- with \c READ function, QWidget::hasFocus().
+ \li A \c READ accessor function is required if no \c MEMBER variable was
+ specified. It is for reading the property value. Ideally, a const function
+ is used for this purpose, and it must return either the property's type or a
+ pointer or reference to that type. e.g., QWidget::focus is a read-only
+ property with \c READ function, QWidget::hasFocus().
\li A \c WRITE accessor function is optional. It is for setting the
property value. It must return void and must take exactly one
@@ -71,6 +77,13 @@
QWidget::setEnabled(). Read-only properties do not need \c WRITE
functions. e.g., QWidget::focus has no \c WRITE function.
+ \li A \c MEMBER variable association is required if no \c READ accessor
+ function is specified. This makes the given member variable
+ readable and writable without the need of creating \c READ and \c WRITE accessor
+ functions. It's still possible to use \c READ or \c WRITE accessor functions in
+ addition to \c MEMBER variable association (but not both), if you need to
+ control the variable access.
+
\li A \c RESET function is optional. It is for setting the property
back to its context specific default value. e.g., QWidget::cursor
has the typical \c READ and \c WRITE functions, QWidget::cursor()
@@ -82,10 +95,14 @@
\li A \c NOTIFY signal is optional. If defined, it should specify one
existing signal in that class that is emitted whenever the value
of the property changes.
+ \c NOTIFY signals for \c MEMBER variables must take zero or one parameter,
+ which must be of the same type as the property. The parameter will take the
+ new value of the property.
\li A \c REVISION number is optional. If included, it defines
the property and its notifier signal to be used in a particular
- revision of the API that is exposed to QML.
+ revision of the API (usually for exposure to QML). If not included, it
+ defaults to 0.
\li The \c DESIGNABLE attribute indicates whether the property
should be visible in the property editor of GUI design tool (e.g.,
@@ -114,7 +131,7 @@
gets and sets a widget's \c USER property.
\li The presence of the \c CONSTANT attibute indicates that the property
- value is constant. For a given object instance, the READ method of a
+ value is constant. For a given object instance, the READ method of a
constant property must return the same value every time it is called. This
constant value may be different for different instances of the object. A
constant property cannot have a WRITE method or a NOTIFY signal.
@@ -256,7 +273,7 @@
Q_DECLARE_METATYPE() macro so that their values can be stored in
QVariant objects. This makes them suitable for use with both
static properties declared using the Q_PROPERTY() macro in class
- definitions and dynamic properties created at run-time.
+ definitions and dynamic properties created at run-time.
\sa Q_DECLARE_METATYPE(), QMetaType, QVariant
diff --git a/src/corelib/doc/src/objectmodel/signalsandslots.qdoc b/src/corelib/doc/src/objectmodel/signalsandslots.qdoc
index d897c4b9a7..4e285f2966 100644
--- a/src/corelib/doc/src/objectmodel/signalsandslots.qdoc
+++ b/src/corelib/doc/src/objectmodel/signalsandslots.qdoc
@@ -365,7 +365,7 @@
arguments can have default values. Consider QObject::destroyed():
\code
- void destroyed(QObject* = 0);
+ void destroyed(QObject* = 0);
\endcode
When a QObject is deleted, it emits this QObject::destroyed()
@@ -434,7 +434,7 @@
handle each signal differently.
Suppose you have three push buttons that determine which file you
- will open: "Tax File", "Accounts File", or "Report File".
+ will open: "Tax File", "Accounts File", or "Report File".
In order to open the correct file, you use QSignalMapper::setMapping() to
map all the clicked() signals to a QSignalMapper object. Then you connect
diff --git a/src/corelib/global/global.pri b/src/corelib/global/global.pri
index 01756c8419..6ac32cd35d 100644
--- a/src/corelib/global/global.pri
+++ b/src/corelib/global/global.pri
@@ -9,6 +9,7 @@ HEADERS += \
global/qendian.h \
global/qnumeric_p.h \
global/qnumeric.h \
+ global/qglobalstatic.h \
global/qlibraryinfo.h \
global/qlogging.h \
global/qtypeinfo.h \
@@ -19,6 +20,7 @@ HEADERS += \
SOURCES += \
global/qglobal.cpp \
+ global/qglobalstatic.cpp \
global/qlibraryinfo.cpp \
global/qmalloc.cpp \
global/qnumeric.cpp \
diff --git a/src/corelib/global/qcompilerdetection.h b/src/corelib/global/qcompilerdetection.h
index d062ea0d15..e547d58c2e 100644
--- a/src/corelib/global/qcompilerdetection.h
+++ b/src/corelib/global/qcompilerdetection.h
@@ -157,6 +157,10 @@
# define Q_CC_CLANG
# define Q_ASSUME_IMPL(expr) if (expr){} else __builtin_unreachable()
# define Q_UNREACHABLE_IMPL() __builtin_unreachable()
+# if !defined(__has_extension)
+# /* Compatibility with older Clang versions */
+# define __has_extension __has_feature
+# endif
# else
/* Plain GCC */
# if (__GNUC__ * 100 + __GNUC_MINOR__) >= 405
@@ -179,6 +183,7 @@
# define Q_TYPEOF(expr) __typeof__(expr)
# define Q_DECL_DEPRECATED __attribute__ ((__deprecated__))
# define Q_DECL_ALIGN(n) __attribute__((__aligned__(n)))
+# define Q_DECL_UNUSED __attribute__((__unused__))
# define Q_LIKELY(expr) __builtin_expect(!!(expr), true)
# define Q_UNLIKELY(expr) __builtin_expect(!!(expr), false)
# define Q_NORETURN __attribute__((__noreturn__))
@@ -816,6 +821,9 @@
#ifndef Q_DECL_HIDDEN
# define Q_DECL_HIDDEN
#endif
+#ifndef Q_DECL_UNUSED
+# define Q_DECL_UNUSED
+#endif
#ifndef Q_FUNC_INFO
# if defined(Q_OS_SOLARIS) || defined(Q_CC_XLC)
# define Q_FUNC_INFO __FILE__ "(line number unavailable)"
@@ -862,6 +870,7 @@
const bool valueOfExpression = Expr;\
Q_ASSERT_X(valueOfExpression, "Q_ASSUME()", "Assumption in Q_ASSUME(\"" #Expr "\") was not correct");\
Q_ASSUME_IMPL(valueOfExpression);\
+ Q_UNUSED(valueOfExpression); /* the value may not be used if Q_ASSERT_X and Q_ASSUME_IMPL are noop */\
} while (0)
#endif // QCOMPILERDETECTION_H
diff --git a/src/corelib/global/qendian.h b/src/corelib/global/qendian.h
index cdffb10d5a..c9c4d23aab 100644
--- a/src/corelib/global/qendian.h
+++ b/src/corelib/global/qendian.h
@@ -52,8 +52,6 @@
#include <byteswap.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -386,6 +384,4 @@ template <> inline qint8 qbswap<qint8>(qint8 source)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QENDIAN_H
diff --git a/src/corelib/global/qfeatures.h b/src/corelib/global/qfeatures.h
index 7ae4863da3..daf853b916 100644
--- a/src/corelib/global/qfeatures.h
+++ b/src/corelib/global/qfeatures.h
@@ -154,6 +154,9 @@
// Properties
//#define QT_NO_PROPERTIES
+// QRegularExpression
+//#define QT_NO_REGULAREXPRESSION
+
// Resize Handler
//#define QT_NO_RESIZEHANDLER
@@ -235,7 +238,7 @@
// QWheelEvent
//#define QT_NO_WHEELEVENT
-//
+//
//#define QT_NO_XMLSTREAM
// Animation
diff --git a/src/corelib/global/qfeatures.txt b/src/corelib/global/qfeatures.txt
index a97309b876..43db585643 100644
--- a/src/corelib/global/qfeatures.txt
+++ b/src/corelib/global/qfeatures.txt
@@ -28,6 +28,13 @@ Requires:
Name: CssParser
SeeAlso: ???
+Feature: REGULAREXPRESSION
+Description: Perl-compatible regular expression APIs
+Section: Kernel
+Requires:
+Name: QRegularExpression
+SeeAlso: ???
+
Feature: CONCURRENT
Description: Provides a high-level multi-threaded APIs
Section: Kernel
@@ -318,7 +325,7 @@ SeeAlso: ???
Feature: COMBOBOX
Description: Supports comboboxes presenting a list of options to the user.
Section: Widgets
-Requires: LINEEDIT STANDARDITEMMODEL LISTVIEW
+Requires: LINEEDIT STANDARDITEMMODEL LISTVIEW
Name: QComboBox
SeeAlso: ???
@@ -509,7 +516,7 @@ SeeAlso: ???
Feature: WHATSTHIS
Description: Supports displaying "What's this" help.
Section: Widgets
-Requires: TOOLBUTTON
+Requires: TOOLBUTTON
Name: QWhatsThis
SeeAlso: ???
@@ -629,7 +636,7 @@ SeeAlso: ???
Feature: DIRMODEL
Description: Supports a data model for the local filesystem.
Section: ItemViews
-Requires: ITEMVIEWS FILESYSTEMMODEL
+Requires: ITEMVIEWS FILESYSTEMMODEL
Name: QDirModel
SeeAlso: ???
@@ -1023,7 +1030,7 @@ SeeAlso: ???
Feature: SYSTEMTRAYICON
Description: Provides an icon for an application in the system tray.
Section: Utilities
-Requires:
+Requires:
Name: QSystemTrayIcon
SeeAlso: ???
diff --git a/src/corelib/global/qflags.h b/src/corelib/global/qflags.h
index 4b75383213..4722fe2282 100644
--- a/src/corelib/global/qflags.h
+++ b/src/corelib/global/qflags.h
@@ -47,8 +47,6 @@
#include <QtCore/qtypeinfo.h>
#include <QtCore/qtypetraits.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QFlag
@@ -152,6 +150,4 @@ typedef uint Flags;
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFLAGS_H
diff --git a/src/corelib/global/qglobal.cpp b/src/corelib/global/qglobal.cpp
index f0fb9c1a02..9995daf1e9 100644
--- a/src/corelib/global/qglobal.cpp
+++ b/src/corelib/global/qglobal.cpp
@@ -68,7 +68,7 @@
# endif
#endif
-#if defined(Q_OS_VXWORKS)
+#if defined(Q_OS_VXWORKS) && defined(_WRS_KERNEL)
# include <envLib.h>
#endif
@@ -1073,10 +1073,25 @@ bool qSharedBuild() Q_DECL_NOTHROW
*/
/*!
+ \macro Q_OS_WIN
+ \relates <QtGlobal>
+
+ Defined on all supported versions of Windows. That is, if
+ \l Q_OS_WIN32, \l Q_OS_WIN64 or \l Q_OS_WINCE is defined.
+*/
+
+/*!
\macro Q_OS_WIN32
\relates <QtGlobal>
- Defined on all supported versions of Windows.
+ Defined on 32-bit and 64-bit versions of Windows (not on Windows CE).
+*/
+
+/*!
+ \macro Q_OS_WIN64
+ \relates <QtGlobal>
+
+ Defined on 64-bit versions of Windows.
*/
/*!
@@ -2109,7 +2124,7 @@ QString qt_error_string(int errorCode)
uses the new replacement function in VC, and calls the standard C
library's implementation on all other platforms.
- \sa qputenv()
+ \sa qputenv(), qEnvironmentVariableIsSet(), qEnvironmentVariableIsEmpty()
*/
QByteArray qgetenv(const char *varName)
{
@@ -2132,10 +2147,9 @@ QByteArray qgetenv(const char *varName)
/*!
\relates <QtGlobal>
- \internal
+ \since 5.1
- This function checks whether the environment variable \a varName
- is empty.
+ Returns whether the environment variable \a varName is empty.
Equivalent to
\code
@@ -2162,10 +2176,9 @@ bool qEnvironmentVariableIsEmpty(const char *varName) Q_DECL_NOEXCEPT
/*!
\relates <QtGlobal>
- \internal
+ \since 5.1
- This function checks whether the environment variable \a varName
- is set.
+ Returns whether the environment variable \a varName is set.
Equivalent to
\code
@@ -2193,6 +2206,10 @@ bool qEnvironmentVariableIsSet(const char *varName) Q_DECL_NOEXCEPT
\a varName. It will create the variable if it does not exist. It
returns 0 if the variable could not be set.
+ Calling qputenv with an empty value removes the environment variable on
+ Windows, and makes it set (but empty) on Unix. Prefer using qunsetenv()
+ for fully portable behavior.
+
\note qputenv() was introduced because putenv() from the standard
C library was deprecated in VC2005 (and later versions). qputenv()
uses the replacement function in VC, and calls the standard C
@@ -2219,6 +2236,39 @@ bool qputenv(const char *varName, const QByteArray& value)
#endif
}
+/*!
+ \relates <QtGlobal>
+
+ This function deletes the variable \a varName from the environment.
+
+ Returns true on success.
+
+ \since 5.1
+
+ \sa qputenv(), qgetenv()
+*/
+bool qunsetenv(const char *varName)
+{
+#if defined(_MSC_VER) && _MSC_VER >= 1400
+ return _putenv_s(varName, "") == 0;
+#elif (defined(_POSIX_VERSION) && (_POSIX_VERSION-0) >= 200112L) || defined(Q_OS_BSD4)
+ // POSIX.1-2001 and BSD have unsetenv
+ return unsetenv(varName) == 0;
+#elif defined(Q_CC_MINGW)
+ // On mingw, putenv("var=") removes "var" from the environment
+ QByteArray buffer(varName);
+ buffer += '=';
+ return putenv(buffer.constData()) == 0;
+#else
+ // Fallback to putenv("var=") which will insert an empty var into the
+ // environment and leak it
+ QByteArray buffer(varName);
+ buffer += '=';
+ char *envVar = qstrdup(buffer.constData());
+ return putenv(envVar) == 0;
+#endif
+}
+
#if defined(Q_OS_UNIX) && !defined(QT_NO_THREAD)
# if defined(Q_OS_INTEGRITY) && defined(__GHS_VERSION_NUMBER) && (__GHS_VERSION_NUMBER < 500)
@@ -2814,8 +2864,7 @@ bool QInternal::activateCallbacks(Callback cb, void **parameters)
As a rule of thumb, \c QT_BEGIN_NAMESPACE should appear in all Qt header
and Qt source files after the last \c{#include} line and before the first
- declaration. In Qt headers using \c QT_BEGIN_HEADER, \c QT_BEGIN_NAMESPACE
- follows \c QT_BEGIN_HEADER immediately.
+ declaration.
If that rule can't be followed because, e.g., \c{#include} lines and
declarations are wildly mixed, place \c QT_BEGIN_NAMESPACE before
diff --git a/src/corelib/global/qglobal.h b/src/corelib/global/qglobal.h
index 13bdc7553f..58c4256aa5 100644
--- a/src/corelib/global/qglobal.h
+++ b/src/corelib/global/qglobal.h
@@ -45,11 +45,11 @@
#include <stddef.h>
-#define QT_VERSION_STR "5.0.2"
+#define QT_VERSION_STR "5.1.0"
/*
QT_VERSION is (major << 16) + (minor << 8) + patch.
*/
-#define QT_VERSION 0x050002
+#define QT_VERSION 0x050100
/*
can be used like #if (QT_VERSION >= QT_VERSION_CHECK(4, 4, 0))
*/
@@ -151,6 +151,7 @@ namespace QT_NAMESPACE {}
#endif /* __cplusplus */
+// ### Qt6: remove me.
#define QT_BEGIN_HEADER
#define QT_END_HEADER
@@ -158,7 +159,6 @@ namespace QT_NAMESPACE {}
# define QT_LARGEFILE_SUPPORT 64
#endif
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
/*
@@ -470,7 +470,7 @@ typedef qptrdiff qintptr;
# else
# define QT_ENSURE_STACK_ALIGNED_FOR_SSE
# endif
-# define QT_WIN_CALLBACK CALLBACK QT_ENSURE_STACK_ALIGNED_FOR_SSE
+# define QT_WIN_CALLBACK CALLBACK QT_ENSURE_STACK_ALIGNED_FOR_SSE
#endif
typedef int QNoImplicitBoolCast;
@@ -512,6 +512,16 @@ template <typename T>
Q_DECL_CONSTEXPR inline const T &qBound(const T &min, const T &val, const T &max)
{ return qMax(min, qMin(max, val)); }
+#ifdef Q_OS_DARWIN
+# define QT_MAC_PLATFORM_SDK_EQUAL_OR_ABOVE(osx, ios) \
+ (defined(__MAC_OS_X_VERSION_MAX_ALLOWED) && __MAC_OS_X_VERSION_MAX_ALLOWED >= osx) || \
+ (defined(__IPHONE_OS_VERSION_MAX_ALLOWED) && __IPHONE_OS_VERSION_MAX_ALLOWED >= ios)
+
+# define QT_MAC_DEPLOYMENT_TARGET_BELOW(osx, ios) \
+ (defined(__MAC_OS_X_VERSION_MIN_REQUIRED) && osx != __MAC_NA && __MAC_OS_X_VERSION_MIN_REQUIRED < osx) || \
+ (defined(__IPHONE_OS_VERSION_MIN_REQUIRED) && ios != __IPHONE_NA && __IPHONE_OS_VERSION_MIN_REQUIRED < ios)
+#endif
+
/*
Data stream functions are provided by many classes (defined in qdatastream.h)
*/
@@ -664,133 +674,14 @@ typedef void (*QFunctionPointer)();
# define Q_UNIMPLEMENTED() qWarning("%s:%d: %s: Unimplemented code.", __FILE__, __LINE__, Q_FUNC_INFO)
#endif
-#if defined(QT_NO_THREAD)
-
-template <typename T>
-class QGlobalStatic
-{
-public:
- T *pointer;
- inline QGlobalStatic(T *p) : pointer(p) { }
- inline ~QGlobalStatic() { pointer = 0; }
-};
-
-#define Q_GLOBAL_STATIC(TYPE, NAME) \
- static TYPE *NAME() \
- { \
- static TYPE thisVariable; \
- static QGlobalStatic<TYPE > thisGlobalStatic(&thisVariable); \
- return thisGlobalStatic.pointer; \
- }
-
-#define Q_GLOBAL_STATIC_WITH_ARGS(TYPE, NAME, ARGS) \
- static TYPE *NAME() \
- { \
- static TYPE thisVariable ARGS; \
- static QGlobalStatic<TYPE > thisGlobalStatic(&thisVariable); \
- return thisGlobalStatic.pointer; \
- }
-
-#define Q_GLOBAL_STATIC_WITH_INITIALIZER(TYPE, NAME, INITIALIZER) \
- static TYPE *NAME() \
- { \
- static TYPE thisVariable; \
- static QGlobalStatic<TYPE > thisGlobalStatic(0); \
- if (!thisGlobalStatic.pointer) { \
- TYPE *x = thisGlobalStatic.pointer = &thisVariable; \
- INITIALIZER; \
- } \
- return thisGlobalStatic.pointer; \
- }
-
-#else
-
-// forward declaration, since qatomic.h needs qglobal.h
-template <typename T> class QBasicAtomicPointer;
-
-// POD for Q_GLOBAL_STATIC
-template <typename T>
-class QGlobalStatic
-{
-public:
- QBasicAtomicPointer<T> pointer;
- bool destroyed;
-};
-
-// Created as a function-local static to delete a QGlobalStatic<T>
-template <typename T>
-class QGlobalStaticDeleter
-{
-public:
- QGlobalStatic<T> &globalStatic;
- QGlobalStaticDeleter(QGlobalStatic<T> &_globalStatic)
- : globalStatic(_globalStatic)
- { }
-
- inline ~QGlobalStaticDeleter()
- {
- delete globalStatic.pointer.load();
- globalStatic.pointer.store(0);
- globalStatic.destroyed = true;
- }
-};
-
-#define Q_GLOBAL_STATIC(TYPE, NAME) \
- static TYPE *NAME() \
- { \
- static QGlobalStatic<TYPE > thisGlobalStatic \
- = { Q_BASIC_ATOMIC_INITIALIZER(0), false }; \
- if (!thisGlobalStatic.pointer.load() && !thisGlobalStatic.destroyed) { \
- TYPE *x = new TYPE; \
- if (!thisGlobalStatic.pointer.testAndSetOrdered(0, x)) \
- delete x; \
- else \
- static QGlobalStaticDeleter<TYPE > cleanup(thisGlobalStatic); \
- } \
- return thisGlobalStatic.pointer.load(); \
- }
-
-#define Q_GLOBAL_STATIC_WITH_ARGS(TYPE, NAME, ARGS) \
- static TYPE *NAME() \
- { \
- static QGlobalStatic<TYPE > thisGlobalStatic \
- = { Q_BASIC_ATOMIC_INITIALIZER(0), false }; \
- if (!thisGlobalStatic.pointer.load() && !thisGlobalStatic.destroyed) { \
- TYPE *x = new TYPE ARGS; \
- if (!thisGlobalStatic.pointer.testAndSetOrdered(0, x)) \
- delete x; \
- else \
- static QGlobalStaticDeleter<TYPE > cleanup(thisGlobalStatic); \
- } \
- return thisGlobalStatic.pointer.load(); \
- }
-
-#define Q_GLOBAL_STATIC_WITH_INITIALIZER(TYPE, NAME, INITIALIZER) \
- static TYPE *NAME() \
- { \
- static QGlobalStatic<TYPE > thisGlobalStatic \
- = { Q_BASIC_ATOMIC_INITIALIZER(0), false }; \
- if (!thisGlobalStatic.pointer.load() && !thisGlobalStatic.destroyed) { \
- QScopedPointer<TYPE > x(new TYPE); \
- INITIALIZER; \
- if (thisGlobalStatic.pointer.testAndSetOrdered(0, x.data())) { \
- static QGlobalStaticDeleter<TYPE > cleanup(thisGlobalStatic); \
- x.take(); \
- } \
- } \
- return thisGlobalStatic.pointer.load(); \
- }
-
-#endif
-
Q_DECL_CONSTEXPR static inline bool qFuzzyCompare(double p1, double p2)
{
- return (qAbs(p1 - p2) <= 0.000000000001 * qMin(qAbs(p1), qAbs(p2)));
+ return (qAbs(p1 - p2) * 1000000000000. <= qMin(qAbs(p1), qAbs(p2)));
}
Q_DECL_CONSTEXPR static inline bool qFuzzyCompare(float p1, float p2)
{
- return (qAbs(p1 - p2) <= 0.00001f * qMin(qAbs(p1), qAbs(p2)));
+ return (qAbs(p1 - p2) * 100000.f <= qMin(qAbs(p1), qAbs(p2)));
}
/*!
@@ -1053,6 +944,7 @@ Q_CORE_EXPORT QString qtTrId(const char *id, int n = -1);
class QByteArray;
Q_CORE_EXPORT QByteArray qgetenv(const char *varName);
Q_CORE_EXPORT bool qputenv(const char *varName, const QByteArray& value);
+Q_CORE_EXPORT bool qunsetenv(const char *varName);
Q_CORE_EXPORT bool qEnvironmentVariableIsEmpty(const char *varName) Q_DECL_NOEXCEPT;
Q_CORE_EXPORT bool qEnvironmentVariableIsSet(const char *varName) Q_DECL_NOEXCEPT;
@@ -1087,7 +979,8 @@ template <typename T> struct QEnableIf<true, T> { typedef T Type; };
}
QT_END_NAMESPACE
-QT_END_HEADER
+// Q_GLOBAL_STATIC
+#include <QtCore/qglobalstatic.h>
// qDebug and friends
#include <QtCore/qlogging.h>
diff --git a/src/corelib/global/qglobalstatic.cpp b/src/corelib/global/qglobalstatic.cpp
new file mode 100644
index 0000000000..8474d132b4
--- /dev/null
+++ b/src/corelib/global/qglobalstatic.cpp
@@ -0,0 +1,524 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Intel Corporation.
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qglobalstatic.h"
+
+/*!
+ \macro Q_GLOBAL_STATIC(Type, VariableName)
+ \since 5.1
+ \relates QGlobalStatic
+
+ Creates a global and static object of type \l QGlobalStatic, of name \a
+ VariableName and that behaves as a pointer to \a Type. The object created
+ by Q_GLOBAL_STATIC initializes itself on the first use, which means that it
+ will not increase the application or the library's load time. Additionally,
+ the object is initialized in a thread-safe manner on all platforms.
+
+ The typical use of this macro is as follows, in a global context (that is,
+ outside of any function bodies):
+
+ \code
+ Q_GLOBAL_STATIC(MyType, staticType)
+ \endcode
+
+ This macro is intended to replace global static objects that are not POD
+ (Plain Old Data, or in C++11 terms, not made of a trivial type), hence the
+ name. For example, the following C++ code creates a global static:
+
+ \code
+ static MyType staticType;
+ \endcode
+
+ Compared to Q_GLOBAL_STATIC, and assuming that \c MyType is a class or
+ struct that has a constructor, a destructor, or is otherwise non-POD, the
+ above has the following drawbacks:
+
+ \list
+ \li it requires load-time initialization of \c MyType (that is, the
+ default constructor for \c MyType is called when the library or
+ application is loaded);
+
+ \li the type will be initialized even if it is never used;
+
+ \li the order of initialization and destruction among different
+ translation units is not determined, leading to possible uses before
+ initialization or after destruction;
+
+ \li if it is found inside a function (that is, not global), it will be
+ initialized on first use, but many current compilers (as of 2013) do
+ not guarantee that the initialization will be thread-safe;
+ \endlist
+
+ The Q_GLOBAL_STATIC macro solves all of the above problems by guaranteeing
+ thread-safe initialization on first use and allowing the user to query for
+ whether the type has already been destroyed, to avoid the
+ use-after-destruction problem (see QGlobalStatic::isDestroyed()).
+
+ \section1 Constructor and destructor
+
+ For Q_GLOBAL_STATIC, the type \c Type must be publicly
+ default-constructible and publicly destructible. For
+ Q_GLOBAL_STATIC_WITH_ARGS(), there must be a public constructor that
+ matches the arguments passed.
+
+ It is not possible to use Q_GLOBAL_STATIC with types that have protected or
+ private default constructors or destructors (for Q_GLOBAL_STATIC_WITH_ARGS(),
+ a protected or private constructor matching the arguments). If the type in
+ question has those members as protected, it is possible to overcome the
+ issue by deriving from the type and creating public a constructor and
+ destructor. If the type has them as private, a friend declaration is
+ necessary before deriving.
+
+ For example, the following is enough to create \c MyType based on a
+ previously-defined \c MyOtherType which has a protected default constructor
+ and/or a protected destructor (or has them as private, but that defines \c
+ MyType as a friend).
+
+ \code
+ class MyType : public MyOtherType { };
+ Q_GLOBAL_STATIC(MyType, staticType)
+ \endcode
+
+ No body for \c MyType is required since the destructor is an implicit
+ member and so is the default constructor if no other constructors are
+ defined. For use with Q_GLOBAL_STATIC_WITH_ARGS(), however, a suitable
+ constructor body is necessary:
+
+ \code
+ class MyType : public MyOtherType
+ {
+ public:
+ MyType(int i) : MyOtherType(i) {}
+ };
+ Q_GLOBAL_STATIC_WITH_ARGS(MyType, staticType, (42))
+ \endcode
+
+ Alternatively, if the compiler supports C++11 inheriting constructors, one could write:
+
+ \code
+ class MyType : public MyOtherType
+ {
+ public:
+ using MyOtherType::MyOtherType;
+ };
+ Q_GLOBAL_STATIC_WITH_ARGS(MyType, staticType, (42))
+ \endcode
+
+ \section1 Placement
+
+ The Q_GLOBAL_STATIC macro creates a type that is necessarily static, at the
+ global scope. It is not possible to place the Q_GLOBAL_STATIC macro inside
+ a function (doing so will result in compilation errors).
+
+ More importantly, this macro should be placed in source files, never in
+ headers. Since the resulting object is has static linkage, if the macro is
+ placed in a header and included by multiple source files, the object will
+ be defined multiple times and will not cause linking errors. Instead, each
+ translation unit will refer to a different object, which could lead to
+ subtle and hard-to-track errors.
+
+ \section1 Non-recommended uses
+
+ Note that the macro is not recommended for use with types that are POD or
+ that have C++11 constexpr constructors (trivially constructible and
+ destructible). For those types, it is still recommended to use regular
+ static, whether global or function-local.
+
+ This macro will work, but it will add unnecessary overhead.
+
+ \section1 Reentrancy, thread-safety, deadlocks, and exception-safety on construction
+
+ The Q_GLOBAL_STATIC macro creates an object that initializes itself on
+ first use in a thread-safe manner: if multiple threads attempt to
+ initialize the object at the same time, only one thread will proceed to
+ initialize, while all other threads wait for completion.
+
+ If the initialization process throws an exception, the initialization is
+ deemed not complete and will be attempted again when control reaches any
+ use of the object. If there are any threads waiting for initialization, one
+ of them will be woken up to attempt to initialize.
+
+ The macro makes no guarantee about reentrancy from the same thread. If the
+ global static object is accessed directly or indirectly from inside the
+ constructor, a deadlock will surely happen.
+
+ In addition, if two Q_GLOBAL_STATIC objects are being initialized on two
+ different threads and each one's initialization sequence accesses the
+ other, a deadlock might happen. For that reason, it is recommended to keep
+ global static constructors simple or, failing that, to ensure that there's
+ no cross-dependency of uses of global static during construction.
+
+ \section1 Destruction
+
+ If the object is never used during the lifetime of the program, aside from
+ the QGlobalStatic::exists() and QGlobalStatic::isDestroyed() functions, the
+ contents of type \a Type will not be created and there will not be any
+ exit-time operation.
+
+ If the object is created, it will be destroyed at exit-time, similar to the
+ C \c atexit function. On most systems, in fact, the destructor will also be
+ called if the library or plugin is unloaded from memory before exit.
+
+ Since the destruction is meant to happen at program exit, no thread-safety
+ is provided. This includes the case of plugin or library unload. In
+ addition, since destructors are not supposed to throw exceptions, no
+ exception safety is provided either.
+
+ However, reentrancy is permitted: during destruction, it is possible to
+ access the global static object and the pointer returned will be the same
+ as it was before destruction began. After the destruction has completed,
+ accessing the global static object is not permitted, except as noted in the
+ \l QGlobalStatic API.
+
+ \omit
+ \section1 Compatibility with Qt 4 and Qt 5.0
+
+ This macro, in its current form and behavior, was introduced in Qt 5.1.
+ Prior to that version, Qt had another macro with the same name that was
+ private API. This section is not meant to document how to use
+ Q_GLOBAL_STATIC in those versions, but instead to serve as a porting guide
+ for Qt code that used those macros.
+
+ The Qt 4 Q_GLOBAL_STATIC macro differed in behavior in the following ways:
+
+ \list
+ \li the object created was not of type \l QGlobalStatic, but instead
+ it was a function that returned a pointer to \a Type; that means the
+ \l QGlobalStatic API was not present;
+
+ \li the initialization was thread-safe, but not guaranteed to be
+ unique: instead, if N threads tried to initialize the object at the
+ same time, N objects would be created on the heap and N-1 would be
+ destroyed;
+
+ \li the object was always created on the heap.
+ \endlist
+
+ \section1 Implementation details
+
+ Q_GLOBAL_STATIC is implemented by creating a QBasicAtomicInt called the \c
+ guard and a free, inline function called \c innerFunction. The guard
+ variable is initialized to value 0 (chosen so that the guard can be placed
+ in the .bss section of the binary file), which denotes that construction
+ has not yet taken place (uninitialized). The inner function is implemented
+ by the helper macro Q_GLOBAL_STATIC_INTERNAL.
+
+ Both the guard variable and the inner function are passed as template
+ parameters to QGlobalStatic, along with the type \a Type. Both should also
+ have static linkage or be placed inside an anonymous namespace, so that the
+ visibility of Q_GLOBAL_STATIC is that of a global static. To permit
+ multiple Q_GLOBAL_STATIC per translation unit, the guard variable and the
+ inner function must have unique names, which can be accomplished by
+ concatenating with \a VariableName or by placing them in a namespace that
+ has \a VariableName as part of the name. To simplify and improve
+ readability on Q_GLOBAL_STATIC_INTERNAL, we chose the namespace solution.
+ It's also required for C++98 builds, since static symbols cannot be used as
+ template parameters.
+
+ The guard variable can assume the following values:
+
+ \list
+ \li -2: object was once initialized but has been destroyed already;
+ \li -1: object was initialized and is still valid;
+ \li 0: object was not initialized yet;
+ \li +1: object is being initialized and any threads encountering this
+ value must wait for completion (not used in the current implementation).
+ \endlist
+
+ Collectively, all positive values indicate that the initialization is
+ progressing and must be waited on, whereas all negative values indicate
+ that the initialization has terminated and must not be attempted again.
+ Positive values are not used in the current implementation, but were in
+ earlier versions. They could be used again in the future.
+
+ The QGlobalStatic::exists() and QGlobalStatic::isDestroyed() functions
+ operate solely on the guard variable: the former returns true if the guard
+ is negative, whereas the latter returns true only if it is -2.
+
+ The Q_GLOBAL_STATIC_INTERNAL macro implements the actual construction and
+ destruction. There are two implementations of it: one for compilers that
+ support thread-safe initialization of function-local statics and one for
+ compilers that don't. Thread-safe initialization is required by C++11 in
+ [stmt.decl], but as of the time of this writing, only compilers based on
+ the IA-64 C++ ABI implemented it properly. The implementation requiring
+ thread-safe initialization is also used on the Qt bootstrapped tools, which
+ define QT_NO_THREAD.
+
+ The implementation requiring thread-safe initialization from the compiler
+ is the simplest: it creates the \a Type object as a function-local static
+ and returns its address. The actual object is actually inside a holder
+ structure so holder's destructor can set the guard variable to the value -2
+ (destroyed) when the type has finished destruction. Since we need to set
+ the guard \b after the destruction has finished, this code needs to be in a
+ base struct's destructor. And it only sets to -2 (destroyed) if it finds
+ the guard at -1 (initialized): this is done to ensure that the guard isn't
+ set to -2 in the event the type's constructor threw an exception. A holder
+ structure is used to avoid creating two statics, which the ABI might
+ require duplicating the thread-safe control structures for.
+
+ The other implementation is similar to Qt 4's Q_GLOBAL_STATIC, but unlike
+ that one, it uses a \l QBasicMutex to provide locking. It is also more
+ efficient memory-wise. It use a simple double-checked locking of the mutex
+ and then creates the contents on the heap. After that, it creates a
+ function-local structure called "Cleanup", whose destructor will be run at
+ program exit and will actually destroy the contents.
+
+ \endomit
+
+ \sa Q_GLOBAL_STATIC_WITH_ARGS(), QGlobalStatic
+*/
+
+/*!
+ \macro Q_GLOBAL_STATIC_WITH_ARGS(Type, VariableName, Arguments)
+ \since 5.1
+ \relates QGlobalStatic
+
+ Creates a global and static object of type \l QGlobalStatic, of name \a
+ VariableName, initialized by the arguments \a Arguments and that behaves as
+ a pointer to \a Type. The object created by Q_GLOBAL_STATIC_WITH_ARGS
+ initializes itself on the first use, which means that it will not increase
+ the application or the library's load time. Additionally, the object is
+ initialized in a thread-safe manner on all platforms.
+
+ The typical use of this macro is as follows, in a global context (that is,
+ outside of any function bodies):
+
+ \code
+ Q_GLOBAL_STATIC_WITH_ARGS(MyType, staticType, (42, "Hello", "World"))
+ \endcode
+
+ The \a Arguments macro parameter must always include the parentheses or, if
+ C++11 uniform initialization is allowed, the braces.
+
+ Aside from the actual initialization of the contents with the supplied
+ arguments, this macro behaves identically to Q_GLOBAL_STATIC(). Please
+ see that macro's documentation for more information.
+
+ \sa Q_GLOBAL_STATIC(), QGlobalStatic
+*/
+
+/*!
+ \class QGlobalStatic
+ \threadsafe
+ \inmodule QtCore
+ \since 5.1
+ \brief The QGlobalStatic class is used to implement a global static object
+
+ The QGlobalStatic class is the front-end API exported when
+ Q_GLOBAL_STATIC() is used. See the documentation for the macro for a
+ discussion on when to use it and its requirements.
+
+ Normally, you will never use this class directly, but instead you will use
+ the Q_GLOBAL_STATIC() or Q_GLOBAL_STATIC_WITH_ARGS() macros, as
+ follows:
+
+ \code
+ Q_GLOBAL_STATIC(MyType, staticType)
+ \endcode
+
+ The above example creates an object of type QGlobalStatic called \c
+ staticType. After the above declaration, the \c staticType object may be
+ used as if it were a pointer, guaranteed to be initialized exactly once. In
+ addition to the use as a pointer, the object offers two methods to
+ determine the current status of the global: exists() and isDestroyed().
+
+ \sa Q_GLOBAL_STATIC(), Q_GLOBAL_STATIC_WITH_ARGS()
+*/
+
+/*!
+ \typedef QGlobalStatic::Type
+
+ This type is equivalent to the \c Type parameter passed to the
+ Q_GLOBAL_STATIC() or Q_GLOBAL_STATIC_WITH_ARGS() macros. It is used in the
+ return types of some functions.
+*/
+
+/*!
+ \fn bool QGlobalStatic::isDestroyed() const
+
+ This function returns true if the global static object has already
+ completed destruction (that is, if the destructor for the type has already
+ returned). In specific, note that this function returns false if
+ the destruction is still in progress.
+
+ Once this function has returned true once, it will never return
+ false again until either the program is restarted or the plugin or library
+ containing the global static is unloaded and reloaded.
+
+ This function is safe to call at any point in the program execution: it
+ cannot fail and cannot cause a deadlock. Additionally, it will not cause
+ the contents to be created if they have not yet been created.
+
+ This function is useful in code that may be executed at program shutdown,
+ to determine whether the contents may still be accessed or not.
+
+ \omit
+ Due to the non-atomic nature of destruction, it's possible that
+ QGlobalStatic::isDestroyed might return false for a short time after the
+ destructor has finished. However, since the destructor is only run in an
+ environment where concurrent multithreaded access is impossible, no one can
+ see that state. (omitted because it's useless information)
+ \endomit
+
+ \sa exists()
+*/
+
+/*!
+ \fn bool QGlobalStatic::exists() const
+
+ This function returns true if the global static object has already
+ completed initialization (that is, if the constructor for the type has
+ already returned). In specific, note that this function returns false if
+ the initialization is still in progress.
+
+ Once this function has returned true once, it will never return false again
+ until either the program is restarted or the plugin or library containing
+ the global static is unloaded and reloaded.
+
+ This function is safe to call at any point in the program execution: it
+ cannot fail and cannot cause a deadlock. Additionally, it will not cause
+ the contents to be created if they have not yet been created.
+
+ This function is useful if one can determine the initial conditions of the
+ global static object and would prefer to avoid a possibly expensive
+ construction operation.
+
+ For example, in the following code sample, this function is used to
+ short-circuit the creation of the global static called \c globalState and
+ returns a default value:
+
+ \code
+ Q_GLOBAL_STATIC(MyType, globalState)
+ QString someState()
+ {
+ if (globalState.exists())
+ return globalState->someState;
+ return QString();
+ }
+ \endcode
+
+ \b{Thread-safety notice:} this function is thread-safe in the sense that it
+ may be called from any thread at any time and will always return a valid
+ reply. But due to the non-atomic nature of construction, this function may
+ return false for a short time after the construction has completed.
+
+ \b{Memory ordering notice:} this function does not impose any memory
+ ordering guarantees. That is instead provided by the accessor functions
+ that return the pointer or reference to the contents. If you bypass the
+ accessor functions and attempt to access some global state set by the
+ constructor, be sure to use the correct memory ordering semantics provided
+ by \l QAtomicInt or \l QAtomicPointer.
+
+ \sa isDestroyed()
+*/
+
+/*!
+ \fn QGlobalStatic::operator Type*()
+
+ This function returns the address of the contents of this global static. If
+ the contents have not yet been created, they will be created thread-safely
+ by this function. If the contents have already been destroyed, this
+ function will return a null pointer.
+
+ This function can be used, for example, to store the pointer to the
+ contents of the global static in a local variable, thus avoiding multiple
+ calls to the function. The implementation of Q_GLOBAL_STATIC() is quite
+ efficient already, but in performance-critical sections it might be useful
+ to help the compiler a little. For example:
+
+ \code
+ Q_GLOBAL_STATIC(MyType, globalState)
+ QString someState()
+ {
+ MyType *state = globalState;
+ if (!state) {
+ // we're in a post-destruction state
+ return QString();
+ }
+ if (state->condition)
+ return state->value1;
+ else
+ return state->value2;
+ }
+ \endcode
+
+ \sa operator->(), operator*()
+*/
+
+/*!
+ \fn Type *QGlobalStatic::operator()()
+ \deprecated
+
+ This function returns the address of the contents of this global static. If
+ the contents have not yet been created, they will be created thread-safely
+ by this function. If the contents have already been destroyed, this
+ function will return a null pointer.
+
+ This function is equivalent to \l {operator Type *()}. It is provided for
+ compatibility with the private Q_GLOBAL_STATIC implementation that existed
+ in Qt 4.x and 5.0. New code should avoid using it and should instead treat
+ the object as a smart pointer.
+*/
+
+/*!
+ \fn Type *QGlobalStatic::operator->()
+
+ This function returns the address of the contents of this global static. If
+ the contents have not yet been created, they will be created thread-safely
+ by this function.
+
+ This function does not check if the contents have already been destroyed and
+ will never return null. If this function is called after the object has
+ been destroyed, it will return a dangling pointer that should not be
+ dereferenced.
+*/
+
+/*!
+ \fn Type &QGlobalStatic::operator*()
+
+ This function returns a reference to the contents of this global static. If
+ the contents have not yet been created, they will be created thread-safely
+ by this function.
+
+ This function does not check if the contents have already been destroyed.
+ If this function is called after the object has been destroyed, it will
+ return an invalid reference that must not be used.
+*/
diff --git a/src/corelib/global/qglobalstatic.h b/src/corelib/global/qglobalstatic.h
new file mode 100644
index 0000000000..a6268e057e
--- /dev/null
+++ b/src/corelib/global/qglobalstatic.h
@@ -0,0 +1,142 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Intel Corporation
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtCore/qglobal.h>
+
+#ifndef QGLOBALSTATIC_H
+#define QGLOBALSTATIC_H
+
+#include <QtCore/qatomic.h>
+
+QT_BEGIN_NAMESPACE
+
+namespace QtGlobalStatic {
+enum GuardValues {
+ Destroyed = -2,
+ Initialized = -1,
+ Uninitialized = 0,
+ Initializing = 1
+};
+}
+
+#if defined(QT_NO_THREAD) || defined(Q_CC_GNU)
+// some compilers support thread-safe statics
+// The IA-64 C++ ABI requires this, so we know that all GCC versions since 3.4
+// support it. C++11 also requires this behavior.
+// Clang and Intel CC masquerade as GCC when compiling on Linux and Mac OS X.
+
+#define Q_GLOBAL_STATIC_INTERNAL(ARGS) \
+ Q_DECL_HIDDEN inline Type *innerFunction() \
+ { \
+ struct HolderBase { \
+ ~HolderBase() Q_DECL_NOTHROW \
+ { if (guard.load() == QtGlobalStatic::Initialized) \
+ guard.store(QtGlobalStatic::Destroyed); } \
+ }; \
+ static struct Holder : public HolderBase { \
+ Type value; \
+ Holder() \
+ Q_DECL_NOEXCEPT_EXPR(noexcept(Type ARGS)) \
+ : value ARGS \
+ { guard.store(QtGlobalStatic::Initialized); } \
+ } holder; \
+ return &holder.value; \
+ }
+#else
+// We don't know if this compiler supports thread-safe global statics
+// so use our own locked implementation
+
+QT_END_NAMESPACE
+#include <QtCore/qmutex.h>
+QT_BEGIN_NAMESPACE
+
+#define Q_GLOBAL_STATIC_INTERNAL(ARGS) \
+ Q_DECL_HIDDEN inline Type *innerFunction() \
+ { \
+ static Type *d; \
+ static QBasicMutex mutex; \
+ int x = guard.loadAcquire(); \
+ if (Q_UNLIKELY(x >= QtGlobalStatic::Uninitialized)) { \
+ QMutexLocker locker(&mutex); \
+ if (guard.load() == QtGlobalStatic::Uninitialized) { \
+ d = new Type ARGS; \
+ static struct Cleanup { \
+ ~Cleanup() { \
+ delete d; \
+ guard.store(QtGlobalStatic::Destroyed); \
+ } \
+ } cleanup; \
+ guard.store(QtGlobalStatic::Initialized); \
+ } \
+ } \
+ return d; \
+ }
+#endif
+
+// this class must be POD, unless the compiler supports thread-safe statics
+template <typename T, T *(&innerFunction)(), QBasicAtomicInt &guard>
+struct QGlobalStatic
+{
+ typedef T Type;
+
+ bool isDestroyed() const { return guard.load() <= QtGlobalStatic::Destroyed; }
+ bool exists() const { return guard.load() == QtGlobalStatic::Initialized; }
+ operator Type *() { if (isDestroyed()) return 0; return innerFunction(); }
+ Type *operator()() { if (isDestroyed()) return 0; return innerFunction(); }
+ Type *operator->() { return innerFunction(); }
+ Type &operator*() { return *innerFunction(); }
+};
+
+#define Q_GLOBAL_STATIC_WITH_ARGS(TYPE, NAME, ARGS) \
+ namespace { namespace Q_QGS_ ## NAME { \
+ typedef TYPE Type; \
+ QBasicAtomicInt guard = Q_BASIC_ATOMIC_INITIALIZER(QtGlobalStatic::Uninitialized); \
+ Q_GLOBAL_STATIC_INTERNAL(ARGS) \
+ } } \
+ static QGlobalStatic<TYPE, \
+ Q_QGS_ ## NAME::innerFunction, \
+ Q_QGS_ ## NAME::guard> NAME;
+
+#define Q_GLOBAL_STATIC(TYPE, NAME) \
+ Q_GLOBAL_STATIC_WITH_ARGS(TYPE, NAME, ())
+
+QT_END_NAMESPACE
+#endif // QGLOBALSTATIC_H
diff --git a/src/corelib/global/qisenum.h b/src/corelib/global/qisenum.h
index 073d5a591f..577007b455 100644
--- a/src/corelib/global/qisenum.h
+++ b/src/corelib/global/qisenum.h
@@ -62,9 +62,6 @@
#endif
// shut up syncqt
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QISENUM_H
diff --git a/src/corelib/global/qlibraryinfo.h b/src/corelib/global/qlibraryinfo.h
index 054231b084..1a00a14caf 100644
--- a/src/corelib/global/qlibraryinfo.h
+++ b/src/corelib/global/qlibraryinfo.h
@@ -45,8 +45,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qdatetime.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class Q_CORE_EXPORT QLibraryInfo
@@ -103,6 +101,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLIBRARYINFO_H
diff --git a/src/corelib/global/qlogging.cpp b/src/corelib/global/qlogging.cpp
index 60ba19e625..f95e1e9447 100644
--- a/src/corelib/global/qlogging.cpp
+++ b/src/corelib/global/qlogging.cpp
@@ -57,6 +57,10 @@
#include <slog2.h>
#endif
+#ifdef Q_OS_ANDROID
+#include <android/log.h>
+#endif
+
#include <stdio.h>
QT_BEGIN_NAMESPACE
@@ -72,8 +76,8 @@ static bool isFatal(QtMsgType msgType)
if (msgType == QtFatalMsg)
return true;
- if (msgType == QtWarningMsg) {
- static bool fatalWarnings = qEnvironmentVariableIsSet("QT_FATAL_WARNINGS");
+ if (msgType == QtWarningMsg || msgType == QtCriticalMsg) {
+ static bool fatalWarnings = !qEnvironmentVariableIsEmpty("QT_FATAL_WARNINGS");
return fatalWarnings;
}
@@ -115,6 +119,7 @@ static bool isFatal(QtMsgType msgType)
extern bool usingWinMain;
#endif
+#ifdef Q_OS_WIN
static inline void convert_to_wchar_t_elided(wchar_t *d, size_t space, const char *s) Q_DECL_NOEXCEPT
{
size_t len = qstrlen(s);
@@ -128,6 +133,7 @@ static inline void convert_to_wchar_t_elided(wchar_t *d, size_t space, const cha
*d++ = *s++;
*d++ = 0;
}
+#endif
#if !defined(QT_NO_EXCEPTIONS)
/*!
@@ -165,9 +171,7 @@ static void qEmergencyOut(QtMsgType msgType, const char *msg, va_list ap) Q_DECL
fflush(stderr);
#endif
- if (msgType == QtFatalMsg
- || (msgType == QtWarningMsg
- && qEnvironmentVariableIsSet("QT_FATAL_WARNINGS"))) {
+ if (isFatal(msgType)) {
#if defined(Q_CC_MSVC) && defined(QT_DEBUG) && defined(_DEBUG) && defined(_CRT_ERROR)
// get the current report mode
int reportMode = _CrtSetReportMode(_CRT_ERROR, _CRTDBG_MODE_WNDW);
@@ -521,6 +525,11 @@ static const char functionTokenC[] = "%{function}";
static const char pidTokenC[] = "%{pid}";
static const char appnameTokenC[] = "%{appname}";
static const char threadidTokenC[] = "%{threadid}";
+static const char ifDebugTokenC[] = "%{if-debug}";
+static const char ifWarningTokenC[] = "%{if-warning}";
+static const char ifCriticalTokenC[] = "%{if-critical}";
+static const char ifFatalTokenC[] = "%{if-fatal}";
+static const char endifTokenC[] = "%{endif}";
static const char emptyTokenC[] = "";
static const char defaultPattern[] = "%{message}";
@@ -607,6 +616,10 @@ void QMessagePattern::setPattern(const QString &pattern)
tokens = new const char*[lexemes.size() + 1];
tokens[lexemes.size()] = 0;
+ bool nestedIfError = false;
+ bool inIf = false;
+ QString error;
+
for (int i = 0; i < lexemes.size(); ++i) {
const QString lexeme = lexemes.at(i);
if (lexeme.startsWith(QLatin1String("%{"))
@@ -630,23 +643,28 @@ void QMessagePattern::setPattern(const QString &pattern)
tokens[i] = appnameTokenC;
else if (lexeme == QLatin1String(threadidTokenC))
tokens[i] = threadidTokenC;
- else {
- tokens[i] = emptyTokenC;
- QString error = QStringLiteral("QT_MESSAGE_PATTERN: Unknown placeholder %1\n")
+#define IF_TOKEN(LEVEL) \
+ else if (lexeme == QLatin1String(LEVEL)) { \
+ if (inIf) \
+ nestedIfError = true; \
+ tokens[i] = LEVEL; \
+ inIf = true; \
+ }
+ IF_TOKEN(ifDebugTokenC)
+ IF_TOKEN(ifWarningTokenC)
+ IF_TOKEN(ifCriticalTokenC)
+ IF_TOKEN(ifFatalTokenC)
+#undef IF_TOKEN
+ else if (lexeme == QLatin1String(endifTokenC)) {
+ tokens[i] = endifTokenC;
+ if (!inIf && !nestedIfError)
+ error += QStringLiteral("QT_MESSAGE_PATTERN: %{endif} without an %{if-*}\n");
+ inIf = false;
+ } else {
+ tokens[i] = emptyTokenC;
+ error += QStringLiteral("QT_MESSAGE_PATTERN: Unknown placeholder %1\n")
.arg(lexeme);
-
-#if defined(Q_OS_WINCE)
- OutputDebugString(reinterpret_cast<const wchar_t*>(error.utf16()));
- continue;
-#elif defined(Q_OS_WIN) && defined(QT_BUILD_CORE_LIB)
- if (usingWinMain) {
- OutputDebugString(reinterpret_cast<const wchar_t*>(error.utf16()));
- continue;
- }
-#endif
- fprintf(stderr, "%s", error.toLocal8Bit().constData());
- fflush(stderr);
}
} else {
char *literal = new char[lexeme.size() + 1];
@@ -656,6 +674,24 @@ void QMessagePattern::setPattern(const QString &pattern)
tokens[i] = literal;
}
}
+ if (nestedIfError)
+ error += QStringLiteral("QT_MESSAGE_PATTERN: %{if-*} cannot be nested\n");
+ else if (inIf)
+ error += QStringLiteral("QT_MESSAGE_PATTERN: missing %{endif}\n");
+ if (!error.isEmpty()) {
+#if defined(Q_OS_WINCE)
+ OutputDebugString(reinterpret_cast<const wchar_t*>(error.utf16()));
+ if (0)
+#elif defined(Q_OS_WIN) && defined(QT_BUILD_CORE_LIB)
+ if (usingWinMain) {
+ OutputDebugString(reinterpret_cast<const wchar_t*>(error.utf16()));
+ } else
+#endif
+ {
+ fprintf(stderr, "%s", error.toLocal8Bit().constData());
+ fflush(stderr);
+ }
+ }
literals = new const char*[literalsVar.size() + 1];
literals[literalsVar.size()] = 0;
memcpy(literals, literalsVar.constData(), literalsVar.size() * sizeof(const char*));
@@ -735,10 +771,16 @@ Q_CORE_EXPORT QString qMessageFormatString(QtMsgType type, const QMessageLogCont
if (pattern->tokens[0] == 0)
return message;
+ bool skip = false;
+
// we do not convert file, function, line literals to local encoding due to overhead
for (int i = 0; pattern->tokens[i] != 0; ++i) {
const char *token = pattern->tokens[i];
- if (token == messageTokenC) {
+ if (token == endifTokenC) {
+ skip = false;
+ } else if (skip) {
+ // do nothing
+ } else if (token == messageTokenC) {
message.append(str);
} else if (token == categoryTokenC) {
message.append(QLatin1String(context.category));
@@ -770,6 +812,14 @@ Q_CORE_EXPORT QString qMessageFormatString(QtMsgType type, const QMessageLogCont
message.append(QLatin1String("0x"));
message.append(QString::number(qlonglong(QThread::currentThread()->currentThread()), 16));
#endif
+#define HANDLE_IF_TOKEN(LEVEL) \
+ } else if (token == if##LEVEL##TokenC) { \
+ skip = type != Qt##LEVEL##Msg;
+ HANDLE_IF_TOKEN(Debug)
+ HANDLE_IF_TOKEN(Warning)
+ HANDLE_IF_TOKEN(Critical)
+ HANDLE_IF_TOKEN(Fatal)
+#undef HANDLE_IF_TOKEN
} else {
message.append(QLatin1String(token));
}
@@ -787,6 +837,24 @@ Q_CORE_EXPORT QtMsgHandler qInstallMsgHandler(QtMsgHandler);
static QtMsgHandler msgHandler = 0; // pointer to debug handler (without context)
static QtMessageHandler messageHandler = 0; // pointer to debug handler (with context)
+#ifdef Q_OS_ANDROID
+static void android_default_message_handler(QtMsgType type,
+ const QMessageLogContext &context,
+ const QString &message)
+{
+ android_LogPriority priority;
+ switch (type) {
+ case QtDebugMsg: priority = ANDROID_LOG_DEBUG; break;
+ case QtWarningMsg: priority = ANDROID_LOG_WARN; break;
+ case QtCriticalMsg: priority = ANDROID_LOG_ERROR; break;
+ case QtFatalMsg: priority = ANDROID_LOG_FATAL; break;
+ };
+
+ __android_log_print(priority, "Qt", "%s:%d (%s): %s", qPrintable(context.file), context.line,
+ qPrintable(context.function), qPrintable(message));
+}
+#endif //Q_OS_ANDROID
+
/*!
\internal
*/
@@ -807,6 +875,8 @@ static void qDefaultMessageHandler(QtMsgType type, const QMessageLogContext &con
#if defined(QT_USE_SLOG2)
slog2_default_handler(type, logMessage.toLocal8Bit().constData());
+#elif defined(Q_OS_ANDROID)
+ android_default_message_handler(type, context, logMessage);
#else
fprintf(stderr, "%s", logMessage.toLocal8Bit().constData());
fflush(stderr);
@@ -819,7 +889,7 @@ static void qDefaultMessageHandler(QtMsgType type, const QMessageLogContext &con
static void qDefaultMsgHandler(QtMsgType type, const char *buf)
{
QMessageLogContext emptyContext;
- qDefaultMessageHandler(type, emptyContext, QLatin1String(buf));
+ qDefaultMessageHandler(type, emptyContext, QString::fromLocal8Bit(buf));
}
static void qt_message_print(QtMsgType msgType, const QMessageLogContext &context, const QString &message)
@@ -1009,6 +1079,15 @@ void qErrnoWarning(int code, const char *msg, ...)
\row \li \c %{type} \li "debug", "warning", "critical" or "fatal"
\endtable
+ You can also use conditionals on the type of the message using \c %{if-debug},
+ \c %{if-warning}, \c %{if-critical} or \c %{if-fatal} followed by an \c %{endif}.
+ What is inside the \c %{if-*} and \c %{endif} will only be printed if the type matches.
+
+ Example:
+ \code
+ QT_MESSAGE_PATTERN="[%{if-debug}D%{endif}%{if-warning}W%{endif}%{if-critical}C%{endif}%{if-fatal}F%{endif}] %{file}:%{line} - %{message}"
+ \endcode
+
The default \a pattern is "%{message}".
The \a pattern can also be changed at runtime by setting the QT_MESSAGE_PATTERN
diff --git a/src/corelib/global/qlogging.h b/src/corelib/global/qlogging.h
index 7d8f7313c8..a6f244698d 100644
--- a/src/corelib/global/qlogging.h
+++ b/src/corelib/global/qlogging.h
@@ -49,7 +49,6 @@
#pragma qt_no_master_include
#endif
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
/*
@@ -172,6 +171,4 @@ Q_CORE_EXPORT QtMessageHandler qInstallMessageHandler(QtMessageHandler);
Q_CORE_EXPORT void qSetMessagePattern(const QString &messagePattern);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLOGGING_H
diff --git a/src/corelib/global/qnamespace.h b/src/corelib/global/qnamespace.h
index e6cd166832..f130288a24 100644
--- a/src/corelib/global/qnamespace.h
+++ b/src/corelib/global/qnamespace.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -65,7 +63,7 @@ Qt {
Q_ENUMS(ScrollBarPolicy FocusPolicy ContextMenuPolicy)
Q_ENUMS(ArrowType ToolButtonStyle PenStyle PenCapStyle PenJoinStyle BrushStyle)
Q_ENUMS(FillRule MaskMode BGMode ClipOperation SizeMode)
- Q_ENUMS(Axis Corner LayoutDirection SizeHint Orientation DropAction)
+ Q_ENUMS(Axis Corner Edge LayoutDirection SizeHint Orientation DropAction)
Q_FLAGS(Alignment Orientations DropActions)
Q_FLAGS(DockWidgetAreas ToolBarAreas)
Q_ENUMS(DockWidgetArea ToolBarArea)
@@ -286,6 +284,7 @@ public:
SplashScreen = ToolTip | Dialog,
Desktop = 0x00000010 | Window,
SubWindow = 0x00000012,
+ ForeignWindow = 0x00000020 | Window,
WindowType_Mask = 0x000000ff,
MSWindowsFixedSizeDialogHint = 0x00000100,
@@ -327,6 +326,15 @@ public:
Q_DECLARE_FLAGS(WindowStates, WindowState)
+ enum ApplicationState {
+ ApplicationSuspended = 0x00000000,
+ ApplicationHidden = 0x00000001,
+ ApplicationInactive = 0x00000002,
+ ApplicationActive = 0x00000004
+ };
+
+ Q_DECLARE_FLAGS(ApplicationStates, ApplicationState)
+
enum ScreenOrientation {
PrimaryOrientation = 0x00000000,
PortraitOrientation = 0x00000001,
@@ -490,6 +498,7 @@ public:
AA_X11InitThreads = 10,
AA_SynthesizeTouchForUnhandledMouseEvents = 11,
AA_SynthesizeMouseForUnhandledTouchEvents = 12,
+ AA_UseHighDpiPixmaps = 13,
// Add new attributes before this line
AA_AttributeCount
@@ -1194,6 +1203,13 @@ public:
BottomRightCorner = 0x00003
};
+ enum Edge {
+ TopEdge = 0x00001,
+ LeftEdge = 0x00002,
+ RightEdge = 0x00004,
+ BottomEdge = 0x00008
+ };
+
enum ConnectionType {
AutoConnection,
DirectConnection,
@@ -1300,6 +1316,8 @@ public:
ImhPreferLatin = 0x200,
+ ImhMultiLine = 0x400,
+
ImhDigitsOnly = 0x10000,
ImhFormattedNumbersOnly = 0x20000,
ImhUppercaseOnly = 0x40000,
@@ -1397,7 +1415,8 @@ public:
ItemIsDropEnabled = 8,
ItemIsUserCheckable = 16,
ItemIsEnabled = 32,
- ItemIsTristate = 64
+ ItemIsTristate = 64,
+ ItemNeverHasChildren = 128
};
Q_DECLARE_FLAGS(ItemFlags, ItemFlag)
@@ -1603,6 +1622,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QNAMESPACE_H
diff --git a/src/corelib/global/qnamespace.qdoc b/src/corelib/global/qnamespace.qdoc
index cb18dde724..b6ce9e03fd 100644
--- a/src/corelib/global/qnamespace.qdoc
+++ b/src/corelib/global/qnamespace.qdoc
@@ -167,6 +167,14 @@
to left button mouse events instead. This attribute is enabled
by default.
+ \value AA_UseHighDpiPixmaps Make QIcon::pixmap() generate high-dpi pixmaps
+ that can be larger than the requested size. Such pixmaps will have
+ devicePixelRatio set to a value higher than 1.
+
+ After setting this attribute application code that uses pixmap
+ sizes in layout geometry calculations should typically divide by
+ QPixmap::devicePixelRatio() to get device-independent layout geometry.
+
\omitvalue AA_AttributeCount
*/
@@ -1710,6 +1718,17 @@
*/
/*!
+ \enum Qt::Edge
+
+ This enum type specifies an edge in a rectangle:
+
+ \value TopEdge The top edge of the rectangle.
+ \value LeftEdge The left edge of the rectangle.
+ \value RightEdge The right edge of the rectangle.
+ \value BottomEdge The bottom edge of the rectangle.
+*/
+
+/*!
\enum Qt::ScrollBarPolicy
This enum type describes the various modes of QAbstractScrollArea's scroll
@@ -1783,6 +1802,36 @@
*/
/*!
+ \enum Qt::ApplicationState
+
+ \keyword application state
+
+ This enum type is used to specify the current state of the application.
+
+ The states are
+
+ \value ApplicationSuspended The application is about to suspend. When entering this state, the
+ application should save its state, cease all activities, and be
+ prepared for code execution to stop. While suspended, the
+ application can be killed at any time without further warnings
+ (e.g. when low memory forces the OS to purge suspended applications).
+ \value ApplicationHidden The application is hidden and runs in the background. This
+ is the normal state for applications that need to do background
+ processing, like playing music, while the user interacts with
+ other applications. The application should free up all graphical
+ resources when entering this state.
+ \value ApplicationInactive The application is visible, but not selected to be in front.
+ On desktop platforms, this typically means that the user
+ activated another application. On mobile platforms, it is
+ more common to enter this state when the OS is interrupting
+ the user with e.g. incoming calls or SMS-messages.
+ While in this state, consider reducing CPU-intensive tasks.
+ \value ApplicationActive The application is visible and selected to be in front.
+
+ \since 5.1
+*/
+
+/*!
\enum Qt::ScreenOrientation
This enum type specifies the various orientations a screen might have.
@@ -1936,6 +1985,10 @@
\value SubWindow Indicates that this widget is a sub-window, such
as a QMdiSubWindow widget.
+ \value ForeignWindow Indicates that this window object is a handle
+ representing a native platform window created by
+ another process or by manually using native code.
+
There are also a number of flags which you can use to customize
the appearance of top-level windows. These have no effect on other
windows:
@@ -2315,6 +2368,8 @@
\value ImhTime The text editor functions as a time field.
\value ImhPreferLatin Latin characters are preferred (but not required).
+ \value ImhMultiLine Multiple lines can be entered into the text field.
+
Flags that restrict input (exclusive flags):
\value ImhDigitsOnly Only digits are allowed.
@@ -2441,6 +2496,7 @@
\value ItemIsUserCheckable It can be checked or unchecked by the user.
\value ItemIsEnabled The user can interact with the item.
\value ItemIsTristate The item is checkable with three separate states.
+ \value ItemNeverHasChildren The item never has child items.
Note that checkable items need to be given both a suitable set of flags
and an initial state, indicating whether the item is checked or not.
@@ -2448,6 +2504,9 @@
to be explicitly set for instances of QListWidgetItem, QTableWidgetItem,
and QTreeWidgetItem.
+ Note that it is undefined behavior to reimplement QAbstractItemModel::hasChildren
+ to return true for an index if that index has the Qt::ItemNeverHasChildren flag set.
+
\sa QAbstractItemModel
*/
diff --git a/src/corelib/global/qnumeric.h b/src/corelib/global/qnumeric.h
index f8e84825c0..25db5443eb 100644
--- a/src/corelib/global/qnumeric.h
+++ b/src/corelib/global/qnumeric.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -65,6 +63,4 @@ Q_CORE_EXPORT double qInf();
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QNUMERIC_H
diff --git a/src/corelib/global/qprocessordetection.h b/src/corelib/global/qprocessordetection.h
index c005c5446e..178afb1db6 100644
--- a/src/corelib/global/qprocessordetection.h
+++ b/src/corelib/global/qprocessordetection.h
@@ -118,6 +118,7 @@
# define Q_PROCESSOR_ARM_V6
# define Q_PROCESSOR_ARM_V5
# elif defined(__ARM_ARCH_5TEJ__) \
+ || defined(__ARM_ARCH_5TE__) \
|| (defined(__TARGET_ARCH_ARM) && __TARGET_ARCH_ARM-0 >= 5) \
|| (defined(_M_ARM) && _M_ARM-0 >= 5)
# define Q_PROCESSOR_ARM_V5
@@ -279,9 +280,9 @@
# if defined(__BYTE_ORDER__) && (__BYTE_ORDER__ == Q_BIG_ENDIAN || __BYTE_ORDER__ == Q_LITTLE_ENDIAN)
// Reuse __BYTE_ORDER__ as-is, since our Q_*_ENDIAN #defines match the preprocessor defaults
# define Q_BYTE_ORDER __BYTE_ORDER__
-# elif defined(__BIG_ENDIAN__)
+# elif defined(__BIG_ENDIAN__) || defined(_big_endian__) || defined(_BIG_ENDIAN)
# define Q_BYTE_ORDER Q_BIG_ENDIAN
-# elif defined(__LITTLE_ENDIAN__) \
+# elif defined(__LITTLE_ENDIAN__) || defined(_little_endian__) || defined(_LITTLE_ENDIAN) \
|| defined(_WIN32_WCE) // Windows CE is always little-endian according to MSDN.
# define Q_BYTE_ORDER Q_LITTLE_ENDIAN
# else
diff --git a/src/corelib/global/qsysinfo.h b/src/corelib/global/qsysinfo.h
index c95c1674eb..edeef3c461 100644
--- a/src/corelib/global/qsysinfo.h
+++ b/src/corelib/global/qsysinfo.h
@@ -44,7 +44,6 @@
#ifndef QSYSINFO_H
#define QSYSINFO_H
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
/*
@@ -151,6 +150,4 @@ public:
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSYSINFO_H
diff --git a/src/corelib/global/qsystemdetection.h b/src/corelib/global/qsystemdetection.h
index 5f9671932f..0caac3d797 100644
--- a/src/corelib/global/qsystemdetection.h
+++ b/src/corelib/global/qsystemdetection.h
@@ -50,6 +50,8 @@
The operating system, must be one of: (Q_OS_x)
DARWIN - Darwin OS (synonym for Q_OS_MAC)
+ MAC - Mac OS X or iOS (iPhoneOS)
+ IOS - iOS (treated as a variant of Mac OS)
MSDOS - MS-DOS and Windows
OS2 - OS/2
OS2EMX - XFree86 on OS/2 (not PM)
@@ -78,6 +80,7 @@
LYNX - LynxOS
BSD4 - Any BSD 4.4 system
UNIX - Any UNIX BSD/SYSV system
+ ANDROID - Android platform
*/
#if defined(__APPLE__) && (defined(__GNUC__) || defined(__xlC__) || defined(__xlc__))
@@ -88,6 +91,9 @@
# else
# define Q_OS_DARWIN32
# endif
+#elif defined(ANDROID)
+# define Q_OS_ANDROID
+# define Q_OS_LINUX
#elif defined(__CYGWIN__)
# define Q_OS_CYGWIN
#elif !defined(SAG_COM) && (defined(WIN64) || defined(_WIN64) || defined(__WIN64__))
@@ -166,6 +172,10 @@
# elif defined(Q_OS_DARWIN32)
# define Q_OS_MAC32
# endif
+# include <TargetConditionals.h>
+# if defined(TARGET_OS_IPHONE) && TARGET_OS_IPHONE
+# define Q_OS_IOS
+# endif
#endif
#if defined(Q_OS_WIN)
@@ -175,30 +185,50 @@
#endif
#ifdef Q_OS_DARWIN
-# ifdef MAC_OS_X_VERSION_MIN_REQUIRED
-# undef MAC_OS_X_VERSION_MIN_REQUIRED
+# include <Availability.h>
+# if !defined(__MAC_OS_X_VERSION_MIN_REQUIRED) || __MAC_OS_X_VERSION_MIN_REQUIRED < __MAC_10_6
+# undef __MAC_OS_X_VERSION_MIN_REQUIRED
+# define __MAC_OS_X_VERSION_MIN_REQUIRED __MAC_10_6
# endif
-# define MAC_OS_X_VERSION_MIN_REQUIRED MAC_OS_X_VERSION_10_4
# include <AvailabilityMacros.h>
-# if !defined(MAC_OS_X_VERSION_10_3)
-# define MAC_OS_X_VERSION_10_3 MAC_OS_X_VERSION_10_2 + 1
+# if !defined(MAC_OS_X_VERSION_MIN_REQUIRED) || MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_6
+# undef MAC_OS_X_VERSION_MIN_REQUIRED
+# define MAC_OS_X_VERSION_MIN_REQUIRED MAC_OS_X_VERSION_10_6
# endif
-# if !defined(MAC_OS_X_VERSION_10_4)
-# define MAC_OS_X_VERSION_10_4 MAC_OS_X_VERSION_10_3 + 1
+#
+# // Numerical checks are preferred to named checks, but to be safe
+# // we define the missing version names in case Qt uses them.
+#
+# if !defined(__MAC_10_7)
+# define __MAC_10_7 1070
# endif
-# if !defined(MAC_OS_X_VERSION_10_5)
-# define MAC_OS_X_VERSION_10_5 MAC_OS_X_VERSION_10_4 + 1
-# endif
-# if !defined(MAC_OS_X_VERSION_10_6)
-# define MAC_OS_X_VERSION_10_6 MAC_OS_X_VERSION_10_5 + 1
+# if !defined(__MAC_10_8)
+# define __MAC_10_8 1080
# endif
# if !defined(MAC_OS_X_VERSION_10_7)
-# define MAC_OS_X_VERSION_10_7 MAC_OS_X_VERSION_10_6 + 1
+# define MAC_OS_X_VERSION_10_7 1070
# endif
# if !defined(MAC_OS_X_VERSION_10_8)
-# define MAC_OS_X_VERSION_10_8 MAC_OS_X_VERSION_10_7 + 1
+# define MAC_OS_X_VERSION_10_8 1080
+# endif
+#
+# if !defined(__IPHONE_4_3)
+# define __IPHONE_4_3 40300
+# endif
+# if !defined(__IPHONE_5_0)
+# define __IPHONE_5_0 50000
+# endif
+# if !defined(__IPHONE_5_1)
+# define __IPHONE_5_1 50100
+# endif
+# if !defined(__IPHONE_6_0)
+# define __IPHONE_6_0 60000
+# endif
+# if !defined(__IPHONE_6_1)
+# define __IPHONE_6_1 60100
# endif
-# if (MAC_OS_X_VERSION_MAX_ALLOWED > MAC_OS_X_VERSION_10_8)
+#
+# if (__MAC_OS_X_VERSION_MAX_ALLOWED > __MAC_10_8)
# warning "This version of Mac OS X is unsupported"
# endif
#endif
diff --git a/src/corelib/global/qt_windows.h b/src/corelib/global/qt_windows.h
index 26b55336ed..c3266c5487 100644
--- a/src/corelib/global/qt_windows.h
+++ b/src/corelib/global/qt_windows.h
@@ -42,6 +42,11 @@
#ifndef QT_WINDOWS_H
#define QT_WINDOWS_H
+#if 0
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
+#endif
+
#if defined(Q_CC_BOR)
// Borland's windows.h does not set these correctly, resulting in
// unusable WinSDK standard dialogs
diff --git a/src/corelib/global/qtypeinfo.h b/src/corelib/global/qtypeinfo.h
index 754aa6712b..8e34c9792d 100644
--- a/src/corelib/global/qtypeinfo.h
+++ b/src/corelib/global/qtypeinfo.h
@@ -44,7 +44,6 @@
#ifndef QTYPEINFO_H
#define QTYPEINFO_H
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
/*
@@ -241,6 +240,4 @@ Q_DECLARE_TYPEINFO(long double, Q_PRIMITIVE_TYPE);
#endif
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTYPEINFO_H
diff --git a/src/corelib/global/qtypetraits.h b/src/corelib/global/qtypetraits.h
index 54b48667b4..2ae66da92b 100644
--- a/src/corelib/global/qtypetraits.h
+++ b/src/corelib/global/qtypetraits.h
@@ -109,7 +109,6 @@
#include <utility> // For pair
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
namespace QtPrivate {
@@ -246,6 +245,10 @@ template<> struct is_integral<unsigned long long> : true_type { };
template <class T> struct is_integral<const T> : is_integral<T> { };
template <class T> struct is_integral<volatile T> : is_integral<T> { };
template <class T> struct is_integral<const volatile T> : is_integral<T> { };
+#if defined (Q_COMPILER_UNICODE_STRINGS)
+template<> struct is_integral<char16_t> : true_type { };
+template<> struct is_integral<char32_t> : true_type { };
+#endif
// is_floating_point is false except for the built-in floating-point types.
// A cv-qualified type is integral if and only if the underlying type is.
@@ -505,6 +508,4 @@ Q_STATIC_ASSERT(( is_signed<qint64>::value));
} // namespace QtPrivate
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTYPETRAITS_H
diff --git a/src/corelib/io/io.pri b/src/corelib/io/io.pri
index f57dcebe33..3688642bcb 100644
--- a/src/corelib/io/io.pri
+++ b/src/corelib/io/io.pri
@@ -18,14 +18,19 @@ HEADERS += \
io/qipaddress_p.h \
io/qiodevice.h \
io/qiodevice_p.h \
+ io/qlockfile.h \
+ io/qlockfile_p.h \
io/qnoncontiguousbytedevice_p.h \
io/qprocess.h \
io/qprocess_p.h \
io/qtextstream.h \
+ io/qtextstream_p.h \
io/qtemporarydir.h \
io/qtemporaryfile.h \
+ io/qtemporaryfile_p.h \
io/qresource_p.h \
io/qresource_iterator_p.h \
+ io/qsavefile.h \
io/qstandardpaths.h \
io/qurl.h \
io/qurl_p.h \
@@ -58,6 +63,7 @@ SOURCES += \
io/qfileinfo.cpp \
io/qipaddress.cpp \
io/qiodevice.cpp \
+ io/qlockfile.cpp \
io/qnoncontiguousbytedevice.cpp \
io/qprocess.cpp \
io/qtextstream.cpp \
@@ -65,6 +71,7 @@ SOURCES += \
io/qtemporaryfile.cpp \
io/qresource.cpp \
io/qresource_iterator.cpp \
+ io/qsavefile.cpp \
io/qstandardpaths.cpp \
io/qurl.cpp \
io/qurlidna.cpp \
@@ -81,6 +88,7 @@ SOURCES += \
win32 {
SOURCES += io/qsettings_win.cpp
SOURCES += io/qfsfileengine_win.cpp
+ SOURCES += io/qlockfile_win.cpp
SOURCES += io/qfilesystemwatcher_win.cpp
HEADERS += io/qfilesystemwatcher_win_p.h
@@ -105,15 +113,15 @@ win32 {
SOURCES += \
io/qfsfileengine_unix.cpp \
io/qfilesystemengine_unix.cpp \
+ io/qlockfile_unix.cpp \
io/qprocess_unix.cpp \
io/qfilesystemiterator_unix.cpp \
- !nacl:macx-*: {
- SOURCES += io/qfilesystemengine_mac.cpp
+ !nacl:mac: {
SOURCES += io/qsettings_mac.cpp
}
- macx-*: {
- !ios {
+ mac {
+ macx {
SOURCES += io/qstandardpaths_mac.cpp
} else {
SOURCES += io/qstandardpaths_unix.cpp
@@ -124,13 +132,13 @@ win32 {
SOURCES += io/qstandardpaths_unix.cpp
}
- linux-*|if(qnx:contains(QT_CONFIG, inotify)) {
+ linux|if(qnx:contains(QT_CONFIG, inotify)) {
SOURCES += io/qfilesystemwatcher_inotify.cpp
HEADERS += io/qfilesystemwatcher_inotify_p.h
}
!nacl {
- freebsd-*|macx-*|darwin-*|openbsd-*:{
+ freebsd-*|mac|darwin-*|openbsd-*:{
SOURCES += io/qfilesystemwatcher_kqueue.cpp
HEADERS += io/qfilesystemwatcher_kqueue_p.h
}
diff --git a/src/corelib/io/qabstractfileengine.cpp b/src/corelib/io/qabstractfileengine.cpp
index 2d9cb85d9f..9cdbbbbb25 100644
--- a/src/corelib/io/qabstractfileengine.cpp
+++ b/src/corelib/io/qabstractfileengine.cpp
@@ -400,6 +400,19 @@ bool QAbstractFileEngine::close()
}
/*!
+ \since 5.1
+
+ Flushes and syncs the file to disk.
+
+ Returns true if successful; otherwise returns false.
+ The default implementation always returns false.
+*/
+bool QAbstractFileEngine::syncToDisk()
+{
+ return false;
+}
+
+/*!
Flushes the open file, returning true if successful; otherwise returns
false.
@@ -496,6 +509,24 @@ bool QAbstractFileEngine::rename(const QString &newName)
}
/*!
+ \since 5.1
+
+ Requests that the file be renamed to \a newName in the file
+ system. If the new name already exists, it must be overwritten.
+ If the operation succeeds, returns true; otherwise returns
+ false.
+
+ This virtual function must be reimplemented by all subclasses.
+
+ \sa setFileName()
+ */
+bool QAbstractFileEngine::renameOverwrite(const QString &newName)
+{
+ Q_UNUSED(newName);
+ return false;
+}
+
+/*!
Creates a link from the file currently specified by fileName() to
\a newName. What a link is depends on the underlying filesystem
(be it a shortcut on Windows or a symbolic link on Unix). Returns
diff --git a/src/corelib/io/qabstractfileengine_p.h b/src/corelib/io/qabstractfileengine_p.h
index 868b086b57..dd64e3d71f 100644
--- a/src/corelib/io/qabstractfileengine_p.h
+++ b/src/corelib/io/qabstractfileengine_p.h
@@ -66,7 +66,7 @@ class QVariant;
class QAbstractFileEngineIterator;
class QAbstractFileEnginePrivate;
-class Q_AUTOTEST_EXPORT QAbstractFileEngine
+class Q_CORE_EXPORT QAbstractFileEngine
{
public:
enum FileFlag {
@@ -124,6 +124,7 @@ public:
virtual bool open(QIODevice::OpenMode openMode);
virtual bool close();
virtual bool flush();
+ virtual bool syncToDisk();
virtual qint64 size() const;
virtual qint64 pos() const;
virtual bool seek(qint64 pos);
@@ -131,6 +132,7 @@ public:
virtual bool remove();
virtual bool copy(const QString &newName);
virtual bool rename(const QString &newName);
+ virtual bool renameOverwrite(const QString &newName);
virtual bool link(const QString &newName);
virtual bool mkdir(const QString &dirName, bool createParentDirectories) const;
virtual bool rmdir(const QString &dirName, bool recurseParentDirectories) const;
@@ -208,7 +210,7 @@ private:
Q_DECLARE_OPERATORS_FOR_FLAGS(QAbstractFileEngine::FileFlags)
-class Q_AUTOTEST_EXPORT QAbstractFileEngineHandler
+class Q_CORE_EXPORT QAbstractFileEngineHandler
{
public:
QAbstractFileEngineHandler();
@@ -217,7 +219,7 @@ public:
};
class QAbstractFileEngineIteratorPrivate;
-class Q_AUTOTEST_EXPORT QAbstractFileEngineIterator
+class Q_CORE_EXPORT QAbstractFileEngineIterator
{
public:
QAbstractFileEngineIterator(QDir::Filters filters, const QStringList &nameFilters);
diff --git a/src/corelib/io/qbuffer.h b/src/corelib/io/qbuffer.h
index f246f1375f..de0fe9f36a 100644
--- a/src/corelib/io/qbuffer.h
+++ b/src/corelib/io/qbuffer.h
@@ -45,8 +45,6 @@
#include <QtCore/qiodevice.h>
#include <QtCore/qbytearray.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -106,6 +104,4 @@ inline void QBuffer::setData(const char *adata, int alen)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QBUFFER_H
diff --git a/src/corelib/io/qdatastream.cpp b/src/corelib/io/qdatastream.cpp
index 544e9e8592..ae9b667b58 100644
--- a/src/corelib/io/qdatastream.cpp
+++ b/src/corelib/io/qdatastream.cpp
@@ -251,7 +251,7 @@ QT_BEGIN_NAMESPACE
return retVal;
enum {
- DefaultStreamVersion = QDataStream::Qt_5_0
+ DefaultStreamVersion = QDataStream::Qt_5_1
};
/*!
@@ -539,6 +539,7 @@ void QDataStream::setByteOrder(ByteOrder bo)
\value Qt_4_8 Same as Qt_4_6.
\value Qt_4_9 Same as Qt_4_6.
\value Qt_5_0 Version 13 (Qt 5.0)
+ \value Qt_5_1 Same as Qt_5_0.
\sa setVersion(), version()
*/
@@ -570,6 +571,7 @@ void QDataStream::setByteOrder(ByteOrder bo)
\table
\header \li Qt Version \li QDataStream Version
+ \row \li Qt 5.0 \li 13
\row \li Qt 4.6 \li 12
\row \li Qt 4.5 \li 11
\row \li Qt 4.4 \li 10
@@ -742,7 +744,7 @@ QDataStream &QDataStream::operator>>(bool &i)
*/
QDataStream &QDataStream::operator>>(float &f)
-{
+{
if (version() >= QDataStream::Qt_4_6
&& floatingPointPrecision() == QDataStream::DoublePrecision) {
double d;
diff --git a/src/corelib/io/qdatastream.h b/src/corelib/io/qdatastream.h
index 092f3a15b3..6017ba5e7d 100644
--- a/src/corelib/io/qdatastream.h
+++ b/src/corelib/io/qdatastream.h
@@ -50,8 +50,6 @@
#error qdatastream.h must be included before any header file that defines Status
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -87,8 +85,9 @@ public:
Qt_4_7 = Qt_4_6,
Qt_4_8 = Qt_4_7,
Qt_4_9 = Qt_4_8,
- Qt_5_0 = 13
-#if QT_VERSION >= 0x050100
+ Qt_5_0 = 13,
+ Qt_5_1 = Qt_5_0
+#if QT_VERSION >= 0x050200
#error Add the datastream version for this Qt version
#endif
};
@@ -434,6 +433,4 @@ inline QDataStream& operator<<(QDataStream& s, const QPair<T1, T2>& p)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDATASTREAM_H
diff --git a/src/corelib/io/qdebug.cpp b/src/corelib/io/qdebug.cpp
index bd43963139..9cb5609dac 100644
--- a/src/corelib/io/qdebug.cpp
+++ b/src/corelib/io/qdebug.cpp
@@ -47,6 +47,9 @@
#endif
#include "qdebug.h"
+#include <private/qtextstream_p.h>
+
+QT_BEGIN_NAMESPACE
// This file is needed to force compilation of QDebug into the kernel library.
@@ -170,6 +173,8 @@
between writes.
\since 5.0
+
+ \sa QDebugStateSaver
*/
/*!
@@ -179,6 +184,8 @@
automatic insertion of spaces is disabled.
\since 5.0
+
+ \sa QDebugStateSaver
*/
/*!
@@ -321,3 +328,69 @@
\fn QDebug &QDebug::operator<<(QTextStreamManipulator m)
\internal
*/
+
+/*!
+ \class QDebugStateSaver
+
+ \brief Convenience class for custom QDebug operators
+
+ Saves the settings used by QDebug, and restores them upon destruction.
+
+ The automatic insertion of spaces between writes is one of the settings
+ that QDebugStateSaver stores for the duration of the current block.
+
+ The settings of the internal QTextStream are also saved and restored,
+ so that using << hex in a QDebug operator doesn't affect other QDebug
+ operators.
+
+ \since 5.1
+*/
+
+class QDebugStateSaverPrivate
+{
+public:
+ QDebugStateSaverPrivate(QDebug &dbg)
+ : m_dbg(dbg),
+ m_spaces(dbg.autoInsertSpaces()),
+ m_streamParams(dbg.stream->ts.d_ptr->params)
+ {
+ }
+ void restoreState()
+ {
+ m_dbg.setAutoInsertSpaces(m_spaces);
+ m_dbg.stream->ts.d_ptr->params = m_streamParams;
+ }
+
+ QDebug &m_dbg;
+
+ // QDebug state
+ const bool m_spaces;
+
+ // QTextStream state
+ const QTextStreamPrivate::Params m_streamParams;
+};
+
+
+/*!
+ Creates a QDebugStateSaver instance, which saves the settings
+ currently used by \a dbg.
+
+ \sa QDebug::setAutoInsertSpaces(), QDebug::autoInsertSpaces()
+*/
+QDebugStateSaver::QDebugStateSaver(QDebug &dbg)
+ : d(new QDebugStateSaverPrivate(dbg))
+{
+}
+
+/*!
+ Destroyes a QDebugStateSaver instance, which restores the settings
+ used by \a dbg when the QDebugStateSaver instance was created.
+
+ \sa QDebug::setAutoInsertSpaces(), QDebug::autoInsertSpaces()
+*/
+QDebugStateSaver::~QDebugStateSaver()
+{
+ d->restoreState();
+}
+
+QT_END_NAMESPACE
diff --git a/src/corelib/io/qdebug.h b/src/corelib/io/qdebug.h
index be8252fbb2..ce72fcd26d 100644
--- a/src/corelib/io/qdebug.h
+++ b/src/corelib/io/qdebug.h
@@ -53,14 +53,13 @@
#include <QtCore/qset.h>
#include <QtCore/qcontiguouscache.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class Q_CORE_EXPORT QDebug
{
friend class QMessageLogger;
+ friend class QDebugStateSaverPrivate;
struct Stream {
Stream(QIODevice *device) : ts(device), ref(1), type(QtDebugMsg), space(true), message_output(false) {}
Stream(QString *string) : ts(string, QIODevice::WriteOnly), ref(1), type(QtDebugMsg), space(true), message_output(false) {}
@@ -132,6 +131,17 @@ public:
Q_DECLARE_SHARED(QDebug)
+class QDebugStateSaverPrivate;
+class Q_CORE_EXPORT QDebugStateSaver
+{
+public:
+ QDebugStateSaver(QDebug &dbg);
+ ~QDebugStateSaver();
+private:
+ Q_DISABLE_COPY(QDebugStateSaver)
+ QScopedPointer<QDebugStateSaverPrivate> d;
+};
+
class QNoDebug
{
public:
@@ -279,6 +289,4 @@ inline QDebug operator<<(QDebug debug, const QFlags<T> &flags)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDEBUG_H
diff --git a/src/corelib/io/qdir.h b/src/corelib/io/qdir.h
index 00091bb0d1..dbb6d93d2e 100644
--- a/src/corelib/io/qdir.h
+++ b/src/corelib/io/qdir.h
@@ -47,8 +47,6 @@
#include <QtCore/qstringlist.h>
#include <QtCore/qshareddata.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -236,6 +234,4 @@ Q_CORE_EXPORT QDebug operator<<(QDebug debug, const QDir &dir);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDIR_H
diff --git a/src/corelib/io/qdiriterator.h b/src/corelib/io/qdiriterator.h
index f0601e602e..4a96005570 100644
--- a/src/corelib/io/qdiriterator.h
+++ b/src/corelib/io/qdiriterator.h
@@ -44,8 +44,6 @@
#include <QtCore/qdir.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -91,6 +89,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QDirIterator::IteratorFlags)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/io/qfile.h b/src/corelib/io/qfile.h
index 2e86af3703..2e75e29995 100644
--- a/src/corelib/io/qfile.h
+++ b/src/corelib/io/qfile.h
@@ -50,8 +50,6 @@
#error qfile.h must be included before any header file that defines open
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QTemporaryFile;
@@ -154,6 +152,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFILE_H
diff --git a/src/corelib/io/qfiledevice.cpp b/src/corelib/io/qfiledevice.cpp
index b49c3406ee..8825ec33b3 100644
--- a/src/corelib/io/qfiledevice.cpp
+++ b/src/corelib/io/qfiledevice.cpp
@@ -100,7 +100,7 @@ void QFileDevicePrivate::setError(QFileDevice::FileError err, int errNum)
\value ReadError An error occurred when reading from the file.
\value WriteError An error occurred when writing to the file.
\value FatalError A fatal error occurred.
- \value ResourceError
+ \value ResourceError Out of resources (e.g., too many open files, out of memory, etc.)
\value OpenError The file could not be opened.
\value AbortError The operation was aborted.
\value TimeOutError A timeout occurred.
diff --git a/src/corelib/io/qfiledevice.h b/src/corelib/io/qfiledevice.h
index fc07097b1c..fc2779086a 100644
--- a/src/corelib/io/qfiledevice.h
+++ b/src/corelib/io/qfiledevice.h
@@ -45,8 +45,6 @@
#include <QtCore/qiodevice.h>
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QFileDevicePrivate;
@@ -142,6 +140,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QFileDevice::Permissions)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFILEDEVICE_H
diff --git a/src/corelib/io/qfileinfo.h b/src/corelib/io/qfileinfo.h
index 938114f9d1..211c18d0a0 100644
--- a/src/corelib/io/qfileinfo.h
+++ b/src/corelib/io/qfileinfo.h
@@ -47,8 +47,6 @@
#include <QtCore/qshareddata.h>
#include <QtCore/qmetatype.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -159,6 +157,4 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QFileInfo)
-QT_END_HEADER
-
#endif // QFILEINFO_H
diff --git a/src/corelib/io/qfilesystemengine.cpp b/src/corelib/io/qfilesystemengine.cpp
index 0fd77fbeb5..71ecc4a0a0 100644
--- a/src/corelib/io/qfilesystemengine.cpp
+++ b/src/corelib/io/qfilesystemengine.cpp
@@ -272,8 +272,7 @@ void QFileSystemMetaData::fillFromStatBuf(const QT_STATBUF &statBuffer)
// Attributes
entryFlags |= QFileSystemMetaData::ExistsAttribute;
size_ = statBuffer.st_size;
-#if defined (Q_OS_MAC) && !defined(Q_OS_IOS) \
- && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5
+#if defined (Q_OS_MAC) && !defined(Q_OS_IOS)
if (statBuffer.st_flags & UF_HIDDEN) {
entryFlags |= QFileSystemMetaData::HiddenAttribute;
knownFlagsMask |= QFileSystemMetaData::HiddenAttribute;
diff --git a/src/corelib/io/qfilesystemengine_unix.cpp b/src/corelib/io/qfilesystemengine_unix.cpp
index 4af01f6730..4bfb03a41e 100644
--- a/src/corelib/io/qfilesystemengine_unix.cpp
+++ b/src/corelib/io/qfilesystemengine_unix.cpp
@@ -169,7 +169,7 @@ QFileSystemEntry QFileSystemEngine::canonicalName(const QFileSystemEntry &entry,
if (entry.isEmpty() || entry.isRoot())
return entry;
-#if !defined(Q_OS_MAC) && !defined(Q_OS_QNX) && _POSIX_VERSION < 200809L
+#if !defined(Q_OS_MAC) && !defined(Q_OS_QNX) && !defined(Q_OS_ANDROID) && _POSIX_VERSION < 200809L
// realpath(X,0) is not supported
Q_UNUSED(data);
return QFileSystemEntry(slowCanonicalized(absoluteName(entry).filePath()));
@@ -286,7 +286,7 @@ QString QFileSystemEngine::resolveUserName(uint userId)
struct passwd *pw = 0;
#if !defined(Q_OS_INTEGRITY)
-#if !defined(QT_NO_THREAD) && defined(_POSIX_THREAD_SAFE_FUNCTIONS) && !defined(Q_OS_OPENBSD)
+#if !defined(QT_NO_THREAD) && defined(_POSIX_THREAD_SAFE_FUNCTIONS) && !defined(Q_OS_OPENBSD) && !defined(Q_OS_VXWORKS)
struct passwd entry;
getpwuid_r(userId, &entry, buf.data(), buf.size(), &pw);
#else
@@ -310,7 +310,7 @@ QString QFileSystemEngine::resolveGroupName(uint groupId)
struct group *gr = 0;
#if !defined(Q_OS_INTEGRITY)
-#if !defined(QT_NO_THREAD) && defined(_POSIX_THREAD_SAFE_FUNCTIONS) && !defined(Q_OS_OPENBSD)
+#if !defined(QT_NO_THREAD) && defined(_POSIX_THREAD_SAFE_FUNCTIONS) && !defined(Q_OS_OPENBSD) && !defined(Q_OS_VXWORKS)
size_max = sysconf(_SC_GETGR_R_SIZE_MAX);
if (size_max == -1)
size_max = 1024;
@@ -360,12 +360,10 @@ bool QFileSystemEngine::fillMetaData(const QFileSystemEntry &entry, QFileSystemM
if (!data.hasFlags(QFileSystemMetaData::DirectoryType))
what |= QFileSystemMetaData::DirectoryType;
}
-# if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5
if (what & QFileSystemMetaData::HiddenAttribute) {
// Mac OS >= 10.5: st_flags & UF_HIDDEN
what |= QFileSystemMetaData::PosixStatFlags;
}
-# endif // MAC_OS_X_VERSION_MAX_ALLOWED...
#endif // defined(Q_OS_MAC) && !defined(Q_OS_IOS)
if (what & QFileSystemMetaData::PosixStatFlags)
@@ -685,8 +683,16 @@ QFileSystemEntry QFileSystemEngine::currentPath()
}
#else
char currentName[PATH_MAX+1];
- if (::getcwd(currentName, PATH_MAX))
+ if (::getcwd(currentName, PATH_MAX)) {
+#if defined(Q_OS_VXWORKS) && defined(VXWORKS_VXSIM)
+ QByteArray dir(currentName);
+ if (dir.indexOf(':') < dir.indexOf('/'))
+ dir.remove(0, dir.indexOf(':')+1);
+
+ qstrncpy(currentName, dir.constData(), PATH_MAX);
+#endif
result = QFileSystemEntry(QByteArray(currentName), QFileSystemEntry::FromNativePath());
+ }
# if defined(QT_DEBUG)
if (result.isEmpty())
qWarning("QFileSystemEngine::currentPath: getcwd() failed");
diff --git a/src/corelib/io/qfilesystemengine_win.cpp b/src/corelib/io/qfilesystemengine_win.cpp
index 5bd9903da1..bee7689535 100644
--- a/src/corelib/io/qfilesystemengine_win.cpp
+++ b/src/corelib/io/qfilesystemengine_win.cpp
@@ -145,8 +145,10 @@ Q_CORE_EXPORT int qt_ntfs_permission_lookup = 0;
static QString qfsPrivateCurrentDir = QLatin1String("");
// As none of the functions we try to resolve do exist on Windows CE
// we use QT_NO_LIBRARY to shorten everything up a little bit.
+#ifndef QT_NO_LIBRARY
#define QT_NO_LIBRARY 1
#endif
+#endif
#if !defined(QT_NO_LIBRARY)
QT_BEGIN_INCLUDE_NAMESPACE
diff --git a/src/corelib/io/qfilesystemwatcher.h b/src/corelib/io/qfilesystemwatcher.h
index e2f48ce0bf..5a326075ba 100644
--- a/src/corelib/io/qfilesystemwatcher.h
+++ b/src/corelib/io/qfilesystemwatcher.h
@@ -46,8 +46,6 @@
#ifndef QT_NO_FILESYSTEMWATCHER
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -90,7 +88,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_FILESYSTEMWATCHER
#endif // QFILESYSTEMWATCHER_H
diff --git a/src/corelib/io/qfilesystemwatcher_win.cpp b/src/corelib/io/qfilesystemwatcher_win.cpp
index fa0711461c..6ac6a3fbd9 100644
--- a/src/corelib/io/qfilesystemwatcher_win.cpp
+++ b/src/corelib/io/qfilesystemwatcher_win.cpp
@@ -207,7 +207,7 @@ QStringList QWindowsFileSystemWatcherEngine::addPaths(const QStringList &paths,
this, SIGNAL(fileChanged(QString,bool)));
connect(thread, SIGNAL(directoryChanged(QString,bool)),
this, SIGNAL(directoryChanged(QString,bool)));
-
+
thread->msg = '@';
thread->start();
threads.append(thread);
diff --git a/src/corelib/io/qfsfileengine.cpp b/src/corelib/io/qfsfileengine.cpp
index b1d7ca9dd1..f0f3c935e6 100644
--- a/src/corelib/io/qfsfileengine.cpp
+++ b/src/corelib/io/qfsfileengine.cpp
@@ -128,7 +128,7 @@ void QFSFileEnginePrivate::init()
#ifdef Q_OS_WIN
fileAttrib = INVALID_FILE_ATTRIBUTES;
fileHandle = INVALID_HANDLE_VALUE;
- mapHandle = INVALID_HANDLE_VALUE;
+ mapHandle = NULL;
#ifndef Q_OS_WINCE
cachedFd = -1;
#endif
@@ -419,6 +419,17 @@ bool QFSFileEngine::flush()
}
/*!
+ \reimp
+*/
+bool QFSFileEngine::syncToDisk()
+{
+ Q_D(QFSFileEngine);
+ if ((d->openMode & QIODevice::WriteOnly) == 0)
+ return true;
+ return d->nativeSyncToDisk();
+}
+
+/*!
\internal
*/
bool QFSFileEnginePrivate::flushFh()
@@ -908,6 +919,11 @@ bool QFSFileEngine::supportsExtension(Extension extension) const
\reimp
*/
+
+/*! \fn bool QFSFileEngine::renameOverwrite(const QString &newName)
+ \reimp
+*/
+
/*! \fn bool QFSFileEngine::rmdir(const QString &name, bool recurseParentDirectories) const
\reimp
*/
diff --git a/src/corelib/io/qfsfileengine_p.h b/src/corelib/io/qfsfileengine_p.h
index d19310b6b6..21f38fea1d 100644
--- a/src/corelib/io/qfsfileengine_p.h
+++ b/src/corelib/io/qfsfileengine_p.h
@@ -81,6 +81,7 @@ public:
bool open(QIODevice::OpenMode flags, FILE *fh);
bool close();
bool flush();
+ bool syncToDisk();
qint64 size() const;
qint64 pos() const;
bool seek(qint64);
@@ -88,6 +89,7 @@ public:
bool remove();
bool copy(const QString &newName);
bool rename(const QString &newName);
+ bool renameOverwrite(const QString &newName);
bool link(const QString &newName);
bool mkdir(const QString &dirName, bool createParentDirectories) const;
bool rmdir(const QString &dirName, bool recurseParentDirectories) const;
@@ -149,6 +151,7 @@ public:
bool nativeClose();
bool closeFdFh();
bool nativeFlush();
+ bool nativeSyncToDisk();
bool flushFh();
qint64 nativeSize() const;
#ifndef Q_OS_WIN
diff --git a/src/corelib/io/qfsfileengine_unix.cpp b/src/corelib/io/qfsfileengine_unix.cpp
index 482f65e7f6..a5f077bd0b 100644
--- a/src/corelib/io/qfsfileengine_unix.cpp
+++ b/src/corelib/io/qfsfileengine_unix.cpp
@@ -258,6 +258,23 @@ bool QFSFileEnginePrivate::nativeFlush()
/*!
\internal
+ \since 5.1
+*/
+bool QFSFileEnginePrivate::nativeSyncToDisk()
+{
+ Q_Q(QFSFileEngine);
+#if defined(_POSIX_SYNCHRONIZED_IO) && _POSIX_SYNCHRONIZED_IO > 0
+ const int ret = fdatasync(nativeHandle());
+#else
+ const int ret = fsync(nativeHandle());
+#endif
+ if (ret != 0)
+ q->setError(QFile::WriteError, qt_error_string(errno));
+ return ret == 0;
+}
+
+/*!
+ \internal
*/
qint64 QFSFileEnginePrivate::nativeRead(char *data, qint64 len)
{
@@ -388,6 +405,12 @@ bool QFSFileEngine::copy(const QString &newName)
return ret;
}
+bool QFSFileEngine::renameOverwrite(const QString &newName)
+{
+ // On Unix, rename() overwrites.
+ return rename(newName);
+}
+
bool QFSFileEngine::rename(const QString &newName)
{
Q_D(QFSFileEngine);
diff --git a/src/corelib/io/qfsfileengine_win.cpp b/src/corelib/io/qfsfileengine_win.cpp
index 1cb3c03c30..41526d1eac 100644
--- a/src/corelib/io/qfsfileengine_win.cpp
+++ b/src/corelib/io/qfsfileengine_win.cpp
@@ -198,15 +198,25 @@ bool QFSFileEnginePrivate::nativeFlush()
return true;
}
- // Windows native mode; flushing is
- // unnecessary. FlushFileBuffers(), the equivalent of sync() or
- // fsync() on Unix, does a low-level flush to the disk, and we
- // don't expose an API for this.
+ // Windows native mode; flushing is unnecessary.
return true;
}
/*
\internal
+ \since 5.1
+*/
+bool QFSFileEnginePrivate::nativeSyncToDisk()
+{
+ if (fh || fd != -1) {
+ // stdlib / stdio mode. No API available.
+ return false;
+ }
+ return FlushFileBuffers(fileHandle);
+}
+
+/*
+ \internal
*/
qint64 QFSFileEnginePrivate::nativeSize() const
{
@@ -507,6 +517,17 @@ bool QFSFileEngine::rename(const QString &newName)
return ret;
}
+bool QFSFileEngine::renameOverwrite(const QString &newName)
+{
+ Q_D(QFSFileEngine);
+ bool ret = ::MoveFileEx((wchar_t*)d->fileEntry.nativeFilePath().utf16(),
+ (wchar_t*)QFileSystemEntry(newName).nativeFilePath().utf16(),
+ MOVEFILE_REPLACE_EXISTING) != 0;
+ if (!ret)
+ setError(QFile::RenameError, QSystemError(::GetLastError(), QSystemError::NativeError).toString());
+ return ret;
+}
+
bool QFSFileEngine::mkdir(const QString &name, bool createParentDirectories) const
{
return QFileSystemEngine::createDirectory(QFileSystemEntry(name), createParentDirectories);
@@ -900,7 +921,7 @@ uchar *QFSFileEnginePrivate::map(qint64 offset, qint64 size,
return 0;
}
- if (mapHandle == INVALID_HANDLE_VALUE) {
+ if (mapHandle == NULL) {
// get handle to the file
HANDLE handle = fileHandle;
@@ -933,7 +954,7 @@ uchar *QFSFileEnginePrivate::map(qint64 offset, qint64 size,
// first create the file mapping handle
DWORD protection = (openMode & QIODevice::WriteOnly) ? PAGE_READWRITE : PAGE_READONLY;
mapHandle = ::CreateFileMapping(handle, 0, protection, 0, 0, 0);
- if (mapHandle == INVALID_HANDLE_VALUE) {
+ if (mapHandle == NULL) {
q->setError(QFile::PermissionsError, qt_error_string());
#ifdef Q_USE_DEPRECATED_MAP_API
::CloseHandle(handle);
@@ -976,6 +997,7 @@ uchar *QFSFileEnginePrivate::map(qint64 offset, qint64 size,
}
::CloseHandle(mapHandle);
+ mapHandle = NULL;
return 0;
}
@@ -995,7 +1017,7 @@ bool QFSFileEnginePrivate::unmap(uchar *ptr)
maps.remove(ptr);
if (maps.isEmpty()) {
::CloseHandle(mapHandle);
- mapHandle = INVALID_HANDLE_VALUE;
+ mapHandle = NULL;
}
return true;
diff --git a/src/corelib/io/qiodevice.cpp b/src/corelib/io/qiodevice.cpp
index 4df9c6b911..c8a3f86137 100644
--- a/src/corelib/io/qiodevice.cpp
+++ b/src/corelib/io/qiodevice.cpp
@@ -1372,7 +1372,7 @@ qint64 QIODevice::write(const char *data, qint64 maxSize)
\since 4.5
\overload
-
+
Writes data from a zero-terminated string of 8-bit characters to the
device. Returns the number of bytes that were actually written, or
-1 if an error occurred. This is equivalent to
diff --git a/src/corelib/io/qiodevice.h b/src/corelib/io/qiodevice.h
index 96a8971639..cdc90f21bb 100644
--- a/src/corelib/io/qiodevice.h
+++ b/src/corelib/io/qiodevice.h
@@ -42,6 +42,7 @@
#ifndef QIODEVICE_H
#define QIODEVICE_H
+#include <QtCore/qglobal.h>
#ifndef QT_NO_QOBJECT
#include <QtCore/qobject.h>
#else
@@ -54,8 +55,6 @@
#error qiodevice.h must be included before any header file that defines open
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -177,6 +176,4 @@ Q_CORE_EXPORT QDebug operator<<(QDebug debug, QIODevice::OpenMode modes);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QIODEVICE_H
diff --git a/src/corelib/io/qlockfile.cpp b/src/corelib/io/qlockfile.cpp
new file mode 100644
index 0000000000..5d56a67f48
--- /dev/null
+++ b/src/corelib/io/qlockfile.cpp
@@ -0,0 +1,346 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 David Faure <faure+bluesystems@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qlockfile.h"
+#include "qlockfile_p.h"
+
+#include <QtCore/qthread.h>
+#include <QtCore/qelapsedtimer.h>
+#include <QtCore/qdatetime.h>
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QLockFile
+ \inmodule QtCore
+ \brief The QLockFile class provides locking between processes using a file.
+ \since 5.1
+
+ A lock file can be used to prevent multiple processes from accessing concurrently
+ the same resource. For instance, a configuration file on disk, or a socket, a port,
+ a region of shared memory...
+
+ Serialization is only guaranteed if all processes that access the shared resource
+ use QLockFile, with the same file path.
+
+ QLockFile supports two use cases:
+ to protect a resource for a short-term operation (e.g. verifying if a configuration
+ file has changed before saving new settings), and for long-lived protection of a
+ resource (e.g. a document opened by a user in an editor) for an indefinite amount of time.
+
+ When protecting for a short-term operation, it is acceptable to call lock() and wait
+ until any running operation finishes.
+ When protecting a resource over a long time, however, the application should always
+ call setStaleLockTime(0) and then tryLock() with a short timeout, in order to
+ warn the user that the resource is locked.
+
+ If the process holding the lock crashes, the lock file stays on disk and can prevent
+ any other process from accessing the shared resource, ever. For this reason, QLockFile
+ tries to detect such a "stale" lock file, based on the process ID written into the file,
+ and (in case that process ID got reused meanwhile), on the last modification time of
+ the lock file (30s by default, for the use case of a short-lived operation).
+ If the lock file is found to be stale, it will be deleted.
+
+ For the use case of protecting a resource over a long time, you should therefore call
+ setStaleLockTime(0), and when tryLock() returns LockFailedError, inform the user
+ that the document is locked, possibly using getLockInfo() for more details.
+*/
+
+/*!
+ \enum QLockFile::LockError
+
+ This enum describes the result of the last call to lock() or tryLock().
+
+ \value NoError The lock was acquired successfully.
+ \value LockFailedError The lock could not be acquired because another process holds it.
+ \value PermissionError The lock file could not be created, for lack of permissions
+ in the parent directory.
+ \value UnknownError Another error happened, for instance a full partition
+ prevented writing out the lock file.
+*/
+
+/*!
+ Constructs a new lock file object.
+ The object is created in an unlocked state.
+ When calling lock() or tryLock(), a lock file named \a fileName will be created,
+ if it doesn't already exist.
+
+ \sa lock(), unlock()
+*/
+QLockFile::QLockFile(const QString &fileName)
+ : d_ptr(new QLockFilePrivate(fileName))
+{
+}
+
+/*!
+ Destroys the lock file object.
+ If the lock was acquired, this will release the lock, by deleting the lock file.
+*/
+QLockFile::~QLockFile()
+{
+ unlock();
+}
+
+/*!
+ Sets \a staleLockTime to be the time in milliseconds after which
+ a lock file is considered stale.
+ The default value is 30000, i.e. 30 seconds.
+ If your application typically keeps the file locked for more than 30 seconds
+ (for instance while saving megabytes of data for 2 minutes), you should set
+ a bigger value using setStaleLockTime().
+
+ The value of \a staleLockTime is used by lock() and tryLock() in order
+ to determine when an existing lock file is considered stale, i.e. left over
+ by a crashed process. This is useful for the case where the PID got reused
+ meanwhile, so the only way to detect a stale lock file is by the fact that
+ it has been around for a long time.
+
+ \sa staleLockTime()
+*/
+void QLockFile::setStaleLockTime(int staleLockTime)
+{
+ Q_D(QLockFile);
+ d->staleLockTime = staleLockTime;
+}
+
+/*!
+ Returns the time in milliseconds after which
+ a lock file is considered stale.
+
+ \sa setStaleLockTime()
+*/
+int QLockFile::staleLockTime() const
+{
+ Q_D(const QLockFile);
+ return d->staleLockTime;
+}
+
+/*!
+ Returns true if the lock was acquired by this QLockFile instance,
+ otherwise returns false.
+
+ \sa lock(), unlock(), tryLock()
+*/
+bool QLockFile::isLocked() const
+{
+ Q_D(const QLockFile);
+ return d->isLocked;
+}
+
+/*!
+ Creates the lock file.
+
+ If another process (or another thread) has created the lock file already,
+ this function will block until that process (or thread) releases it.
+
+ Calling this function multiple times on the same lock from the same
+ thread without unlocking first is not allowed. This function will
+ \e dead-lock when the file is locked recursively.
+
+ Returns true if the lock was acquired, false if it could not be acquired
+ due to an unrecoverable error, such as no permissions in the parent directory.
+
+ \sa unlock(), tryLock()
+*/
+bool QLockFile::lock()
+{
+ return tryLock(-1);
+}
+
+/*!
+ Attempts to create the lock file. This function returns true if the
+ lock was obtained; otherwise it returns false. If another process (or
+ another thread) has created the lock file already, this function will
+ wait for at most \a timeout milliseconds for the lock file to become
+ available.
+
+ Note: Passing a negative number as the \a timeout is equivalent to
+ calling lock(), i.e. this function will wait forever until the lock
+ file can be locked if \a timeout is negative.
+
+ If the lock was obtained, it must be released with unlock()
+ before another process (or thread) can successfully lock it.
+
+ Calling this function multiple times on the same lock from the same
+ thread without unlocking first is not allowed, this function will
+ \e always return false when attempting to lock the file recursively.
+
+ \sa lock(), unlock()
+*/
+bool QLockFile::tryLock(int timeout)
+{
+ Q_D(QLockFile);
+ QElapsedTimer timer;
+ if (timeout > 0)
+ timer.start();
+ int sleepTime = 100;
+ forever {
+ d->lockError = d->tryLock_sys();
+ switch (d->lockError) {
+ case NoError:
+ d->isLocked = true;
+ return true;
+ case PermissionError:
+ case UnknownError:
+ return false;
+ case LockFailedError:
+ if (!d->isLocked && d->isApparentlyStale()) {
+ // Stale lock from another thread/process
+ // Ensure two processes don't remove it at the same time
+ QLockFile rmlock(d->fileName + QStringLiteral(".rmlock"));
+ if (rmlock.tryLock()) {
+ if (d->isApparentlyStale() && d->removeStaleLock())
+ continue;
+ }
+ }
+ break;
+ }
+ if (timeout == 0 || (timeout > 0 && timer.hasExpired(timeout)))
+ return false;
+ QThread::msleep(sleepTime);
+ if (sleepTime < 5 * 1000)
+ sleepTime *= 2;
+ }
+ // not reached
+ return false;
+}
+
+/*!
+ \fn void QLockFile::unlock()
+ Releases the lock, by deleting the lock file.
+
+ Calling unlock() without locking the file first, does nothing.
+
+ \sa lock(), tryLock()
+*/
+
+/*!
+ Retrieves information about the current owner of the lock file.
+
+ If tryLock() returns false, and error() returns LockFailedError,
+ this function can be called to find out more information about the existing
+ lock file:
+ \list
+ \li the PID of the application (returned in \a pid)
+ \li the \a hostname it's running on (useful in case of networked filesystems),
+ \li the name of the application which created it (returned in \a appname),
+ \endlist
+
+ Note that tryLock() automatically deleted the file if there is no
+ running application with this PID, so LockFailedError can only happen if there is
+ an application with this PID (it could be unrelated though).
+
+ This can be used to inform users about the existing lock file and give them
+ the choice to delete it. After removing the file using removeStaleLockFile(),
+ the application can call tryLock() again.
+
+ This function returns true if the information could be successfully retrieved, false
+ if the lock file doesn't exist or doesn't contain the expected data.
+ This can happen if the lock file was deleted between the time where tryLock() failed
+ and the call to this function. Simply call tryLock() again if this happens.
+*/
+bool QLockFile::getLockInfo(qint64 *pid, QString *hostname, QString *appname) const
+{
+ Q_D(const QLockFile);
+ return d->getLockInfo(pid, hostname, appname);
+}
+
+bool QLockFilePrivate::getLockInfo(qint64 *pid, QString *hostname, QString *appname) const
+{
+ QFile reader(fileName);
+ if (!reader.open(QIODevice::ReadOnly))
+ return false;
+
+ QByteArray pidLine = reader.readLine();
+ pidLine.chop(1);
+ QByteArray appNameLine = reader.readLine();
+ appNameLine.chop(1);
+ QByteArray hostNameLine = reader.readLine();
+ hostNameLine.chop(1);
+ if (pidLine.isEmpty() || appNameLine.isEmpty())
+ return false;
+
+ qint64 thePid = pidLine.toLongLong();
+ if (pid)
+ *pid = thePid;
+ if (appname)
+ *appname = QString::fromUtf8(appNameLine);
+ if (hostname)
+ *hostname = QString::fromUtf8(hostNameLine);
+ return thePid > 0;
+}
+
+/*!
+ Attempts to forcefully remove an existing lock file.
+
+ Calling this is not recommended when protecting a short-lived operation: QLockFile
+ already takes care of removing lock files after they are older than staleLockTime().
+
+ This method should only be called when protecting a resource for a long time, i.e.
+ with staleLockTime(0), and after tryLock() returned LockFailedError, and the user
+ agreed on removing the lock file.
+
+ Returns true on success, false if the lock file couldn't be removed. This happens
+ on Windows, when the application owning the lock is still running.
+*/
+bool QLockFile::removeStaleLockFile()
+{
+ Q_D(QLockFile);
+ if (d->isLocked) {
+ qWarning("removeStaleLockFile can only be called when not holding the lock");
+ return false;
+ }
+ return d->removeStaleLock();
+}
+
+/*!
+ Returns the lock file error status.
+
+ If tryLock() returns false, this function can be called to find out
+ the reason why the locking failed.
+*/
+QLockFile::LockError QLockFile::error() const
+{
+ Q_D(const QLockFile);
+ return d->lockError;
+}
+
+QT_END_NAMESPACE
diff --git a/src/corelib/io/qlockfile.h b/src/corelib/io/qlockfile.h
new file mode 100644
index 0000000000..d46f07ab7b
--- /dev/null
+++ b/src/corelib/io/qlockfile.h
@@ -0,0 +1,87 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 David Faure <faure+bluesystems@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QLOCKFILE_H
+#define QLOCKFILE_H
+
+#include <QtCore/qstring.h>
+#include <QtCore/qscopedpointer.h>
+
+QT_BEGIN_NAMESPACE
+
+class QLockFilePrivate;
+
+class Q_CORE_EXPORT QLockFile
+{
+public:
+ QLockFile(const QString &fileName);
+ ~QLockFile();
+
+ bool lock();
+ bool tryLock(int timeout = 0);
+ void unlock();
+
+ void setStaleLockTime(int);
+ int staleLockTime() const;
+
+ bool isLocked() const;
+ bool getLockInfo(qint64 *pid, QString *hostname, QString *appname) const;
+ bool removeStaleLockFile();
+
+ enum LockError {
+ NoError = 0,
+ LockFailedError = 1,
+ PermissionError = 2,
+ UnknownError = 3
+ };
+ LockError error() const;
+
+protected:
+ QScopedPointer<QLockFilePrivate> d_ptr;
+
+private:
+ Q_DECLARE_PRIVATE(QLockFile)
+ Q_DISABLE_COPY(QLockFile)
+};
+
+QT_END_NAMESPACE
+
+#endif // QLOCKFILE_H
diff --git a/src/corelib/io/qlockfile_p.h b/src/corelib/io/qlockfile_p.h
new file mode 100644
index 0000000000..e046e87cf4
--- /dev/null
+++ b/src/corelib/io/qlockfile_p.h
@@ -0,0 +1,104 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 David Faure <faure+bluesystems@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QLOCKFILE_P_H
+#define QLOCKFILE_P_H
+
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists purely as an
+// implementation detail. This header file may change from version to
+// version without notice, or even be removed.
+//
+// We mean it.
+//
+
+#include <QtCore/qlockfile.h>
+#include <QtCore/qfile.h>
+
+#ifdef Q_OS_WIN
+#include <qt_windows.h>
+#endif
+
+QT_BEGIN_NAMESPACE
+
+class QLockFilePrivate
+{
+public:
+ QLockFilePrivate(const QString &fn)
+ : fileName(fn),
+#ifdef Q_OS_WIN
+ fileHandle(INVALID_HANDLE_VALUE),
+#else
+ fileHandle(-1),
+#endif
+ staleLockTime(30 * 1000), // 30 seconds
+ lockError(QLockFile::NoError),
+ isLocked(false)
+ {
+ }
+ QLockFile::LockError tryLock_sys();
+ bool removeStaleLock();
+ bool getLockInfo(qint64 *pid, QString *hostname, QString *appname) const;
+ // Returns true if the lock belongs to dead PID, or is old.
+ // The attempt to delete it will tell us if it was really stale or not, though.
+ bool isApparentlyStale() const;
+
+#ifdef Q_OS_UNIX
+ static int checkFcntlWorksAfterFlock();
+#endif
+
+ QString fileName;
+#ifdef Q_OS_WIN
+ Qt::HANDLE fileHandle;
+#else
+ int fileHandle;
+#endif
+ int staleLockTime; // "int milliseconds" is big enough for 24 days
+ QLockFile::LockError lockError;
+ bool isLocked;
+};
+
+QT_END_NAMESPACE
+
+#endif /* QLOCKFILE_P_H */
diff --git a/src/corelib/io/qlockfile_unix.cpp b/src/corelib/io/qlockfile_unix.cpp
new file mode 100644
index 0000000000..ed3b399fbf
--- /dev/null
+++ b/src/corelib/io/qlockfile_unix.cpp
@@ -0,0 +1,207 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 David Faure <faure+bluesystems@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "private/qlockfile_p.h"
+
+#include "QtCore/qtemporaryfile.h"
+#include "QtCore/qcoreapplication.h"
+#include "QtCore/qfileinfo.h"
+#include "QtCore/qdebug.h"
+
+#include "private/qcore_unix_p.h" // qt_safe_open
+#include "private/qabstractfileengine_p.h"
+#include "private/qtemporaryfile_p.h"
+
+#include <sys/file.h> // flock
+#include <sys/types.h> // kill
+#include <signal.h> // kill
+
+QT_BEGIN_NAMESPACE
+
+static QString localHostName() // from QHostInfo::localHostName()
+{
+ char hostName[512];
+ if (gethostname(hostName, sizeof(hostName)) == -1)
+ return QString();
+ hostName[sizeof(hostName) - 1] = '\0';
+ return QString::fromLocal8Bit(hostName);
+}
+
+// ### merge into qt_safe_write?
+static qint64 qt_write_loop(int fd, const char *data, qint64 len)
+{
+ qint64 pos = 0;
+ while (pos < len) {
+ const qint64 ret = qt_safe_write(fd, data + pos, len - pos);
+ if (ret == -1) // e.g. partition full
+ return pos;
+ pos += ret;
+ }
+ return pos;
+}
+
+int QLockFilePrivate::checkFcntlWorksAfterFlock()
+{
+ QTemporaryFile file;
+ if (!file.open())
+ return -2;
+ const int fd = file.d_func()->engine()->handle();
+ if (flock(fd, LOCK_EX | LOCK_NB) == -1) // other threads, and other processes on a local fs
+ return -3;
+ struct flock flockData;
+ flockData.l_type = F_WRLCK;
+ flockData.l_whence = SEEK_SET;
+ flockData.l_start = 0;
+ flockData.l_len = 0; // 0 = entire file
+ flockData.l_pid = getpid();
+ if (fcntl(fd, F_SETLK, &flockData) == -1) // for networked filesystems
+ return 0;
+ return 1;
+}
+
+static QBasicAtomicInt fcntlOK = Q_BASIC_ATOMIC_INITIALIZER(-1);
+
+/*!
+ \internal
+ Checks that the OS isn't using POSIX locks to emulate flock().
+ Mac OS X is one of those.
+*/
+static bool fcntlWorksAfterFlock()
+{
+ int value = fcntlOK.load();
+ if (Q_UNLIKELY(value == -1)) {
+ value = QLockFilePrivate::checkFcntlWorksAfterFlock();
+ fcntlOK.store(value);
+ }
+ return value == 1;
+}
+
+static bool setNativeLocks(int fd)
+{
+ if (flock(fd, LOCK_EX | LOCK_NB) == -1) // other threads, and other processes on a local fs
+ return false;
+ struct flock flockData;
+ flockData.l_type = F_WRLCK;
+ flockData.l_whence = SEEK_SET;
+ flockData.l_start = 0;
+ flockData.l_len = 0; // 0 = entire file
+ flockData.l_pid = getpid();
+ if (fcntlWorksAfterFlock() && fcntl(fd, F_SETLK, &flockData) == -1) // for networked filesystems
+ return false;
+ return true;
+}
+
+QLockFile::LockError QLockFilePrivate::tryLock_sys()
+{
+ const QByteArray lockFileName = QFile::encodeName(fileName);
+ const int fd = qt_safe_open(lockFileName.constData(), O_WRONLY | O_CREAT | O_EXCL, 0644);
+ if (fd < 0) {
+ switch (errno) {
+ case EEXIST:
+ return QLockFile::LockFailedError;
+ case EACCES:
+ case EROFS:
+ return QLockFile::PermissionError;
+ default:
+ return QLockFile::UnknownError;
+ }
+ }
+ // Ensure nobody else can delete the file while we have it
+ if (!setNativeLocks(fd))
+ qWarning() << "setNativeLocks failed:" << strerror(errno);
+
+ // We hold the lock, continue.
+ fileHandle = fd;
+
+ // Assemble data, to write in a single call to write
+ // (otherwise we'd have to check every write call)
+ QByteArray fileData;
+ fileData += QByteArray::number(QCoreApplication::applicationPid());
+ fileData += '\n';
+ fileData += qAppName().toUtf8();
+ fileData += '\n';
+ fileData += localHostName().toUtf8();
+ fileData += '\n';
+
+ QLockFile::LockError error = QLockFile::NoError;
+ if (qt_write_loop(fd, fileData.constData(), fileData.size()) < fileData.size())
+ error = QLockFile::UnknownError; // partition full
+ return error;
+}
+
+bool QLockFilePrivate::removeStaleLock()
+{
+ const QByteArray lockFileName = QFile::encodeName(fileName);
+ const int fd = qt_safe_open(lockFileName.constData(), O_WRONLY, 0644);
+ if (fd < 0) // gone already?
+ return false;
+ bool success = setNativeLocks(fd) && (::unlink(lockFileName) == 0);
+ close(fd);
+ return success;
+}
+
+bool QLockFilePrivate::isApparentlyStale() const
+{
+ qint64 pid;
+ QString hostname, appname;
+ if (!getLockInfo(&pid, &hostname, &appname))
+ return false;
+ if (hostname == localHostName()) {
+ if (::kill(pid, 0) == -1 && errno == ESRCH)
+ return true; // PID doesn't exist anymore
+ }
+ const qint64 age = QFileInfo(fileName).lastModified().msecsTo(QDateTime::currentDateTime());
+ return staleLockTime > 0 && age > staleLockTime;
+}
+
+void QLockFile::unlock()
+{
+ Q_D(QLockFile);
+ if (!d->isLocked)
+ return;
+ close(d->fileHandle);
+ d->fileHandle = -1;
+ QFile::remove(d->fileName);
+ d->lockError = QLockFile::NoError;
+ d->isLocked = false;
+}
+
+QT_END_NAMESPACE
diff --git a/src/corelib/io/qlockfile_win.cpp b/src/corelib/io/qlockfile_win.cpp
new file mode 100644
index 0000000000..b5f6d9f3da
--- /dev/null
+++ b/src/corelib/io/qlockfile_win.cpp
@@ -0,0 +1,138 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 David Faure <faure+bluesystems@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "private/qlockfile_p.h"
+#include "private/qfilesystementry_p.h"
+#include <qt_windows.h>
+
+#include "QtCore/qcoreapplication.h"
+#include "QtCore/qfileinfo.h"
+#include "QtCore/qdatetime.h"
+#include "QtCore/qdebug.h"
+
+QT_BEGIN_NAMESPACE
+
+QLockFile::LockError QLockFilePrivate::tryLock_sys()
+{
+ SECURITY_ATTRIBUTES securityAtts = { sizeof(SECURITY_ATTRIBUTES), NULL, FALSE };
+ const QFileSystemEntry fileEntry(fileName);
+ // When writing, allow others to read.
+ // When reading, QFile will allow others to read and write, all good.
+ // Adding FILE_SHARE_DELETE would allow forceful deletion of stale files,
+ // but Windows doesn't allow recreating it while this handle is open anyway,
+ // so this would only create confusion (can't lock, but no lock file to read from).
+ const DWORD dwShareMode = FILE_SHARE_READ;
+ HANDLE fh = CreateFile((const wchar_t*)fileEntry.nativeFilePath().utf16(),
+ GENERIC_WRITE,
+ dwShareMode,
+ &securityAtts,
+ CREATE_NEW, // error if already exists
+ FILE_ATTRIBUTE_NORMAL,
+ NULL);
+ if (fh == INVALID_HANDLE_VALUE) {
+ const DWORD lastError = GetLastError();
+ switch (lastError) {
+ case ERROR_SHARING_VIOLATION:
+ case ERROR_ALREADY_EXISTS:
+ case ERROR_FILE_EXISTS:
+ case ERROR_ACCESS_DENIED: // readonly file, or file still in use by another process. Assume the latter, since we don't create it readonly.
+ return QLockFile::LockFailedError;
+ default:
+ qWarning() << "Got unexpected locking error" << lastError;
+ return QLockFile::UnknownError;
+ }
+ }
+
+ // We hold the lock, continue.
+ fileHandle = fh;
+ // Assemble data, to write in a single call to write
+ // (otherwise we'd have to check every write call)
+ QByteArray fileData;
+ fileData += QByteArray::number(QCoreApplication::applicationPid());
+ fileData += '\n';
+ fileData += qAppName().toUtf8();
+ fileData += '\n';
+ //fileData += localHostname(); // gethostname requires winsock init, see QHostInfo...
+ fileData += '\n';
+ DWORD bytesWritten = 0;
+ QLockFile::LockError error = QLockFile::NoError;
+ if (!WriteFile(fh, fileData.constData(), fileData.size(), &bytesWritten, NULL) || !FlushFileBuffers(fh))
+ error = QLockFile::UnknownError; // partition full
+ return error;
+}
+
+bool QLockFilePrivate::removeStaleLock()
+{
+ // QFile::remove fails on Windows if the other process is still using the file, so it's not stale.
+ return QFile::remove(fileName);
+}
+
+bool QLockFilePrivate::isApparentlyStale() const
+{
+ qint64 pid;
+ QString hostname, appname;
+ if (!getLockInfo(&pid, &hostname, &appname))
+ return false;
+
+ HANDLE procHandle = ::OpenProcess(PROCESS_QUERY_INFORMATION, FALSE, pid);
+ if (!procHandle)
+ return true;
+ // We got a handle but check if process is still alive
+ DWORD dwR = ::WaitForSingleObject(procHandle, 0);
+ ::CloseHandle(procHandle);
+ if (dwR == WAIT_TIMEOUT)
+ return true;
+ const qint64 age = QFileInfo(fileName).lastModified().msecsTo(QDateTime::currentDateTime());
+ return staleLockTime > 0 && age > staleLockTime;
+}
+
+void QLockFile::unlock()
+{
+ Q_D(QLockFile);
+ if (!d->isLocked)
+ return;
+ CloseHandle(d->fileHandle);
+ QFile::remove(d->fileName);
+ d->lockError = QLockFile::NoError;
+ d->isLocked = false;
+}
+
+QT_END_NAMESPACE
diff --git a/src/corelib/io/qnoncontiguousbytedevice.cpp b/src/corelib/io/qnoncontiguousbytedevice.cpp
index 2bac7c761c..253aa2aafb 100644
--- a/src/corelib/io/qnoncontiguousbytedevice.cpp
+++ b/src/corelib/io/qnoncontiguousbytedevice.cpp
@@ -388,9 +388,16 @@ bool QNonContiguousByteDeviceIoDeviceImpl::reset()
{
if (resetDisabled)
return false;
-
- if (device->seek(initialPosition)) {
+ bool reset = (initialPosition == 0) ? device->reset() : device->seek(initialPosition);
+ if (reset) {
eof = false; // assume eof is false, it will be true after a read has been attempted
+ totalAdvancements = 0; //reset the progress counter
+ if (currentReadBuffer) {
+ delete currentReadBuffer;
+ currentReadBuffer = 0;
+ }
+ currentReadBufferAmount = 0;
+ currentReadBufferPosition = 0;
return true;
}
diff --git a/src/corelib/io/qprocess.cpp b/src/corelib/io/qprocess.cpp
index 8409e7e479..3993cf5002 100644
--- a/src/corelib/io/qprocess.cpp
+++ b/src/corelib/io/qprocess.cpp
@@ -458,6 +458,9 @@ void QProcessPrivate::Channel::clear()
the program you want to run as arguments to start(). Arguments
are supplied as individual strings in a QStringList.
+ Alternatively, you can set the program to run with setProgram()
+ and setArguments(), and then call start() or open().
+
For example, the following code snippet runs the analog clock
example in the Fusion style on X11 platforms by passing strings
containing "-style" and "fusion" as two items in the list of
@@ -1946,6 +1949,58 @@ void QProcess::start(const QString &program, const QStringList &arguments, OpenM
return;
}
+ d->program = program;
+ d->arguments = arguments;
+
+ open(mode);
+}
+
+/*!
+ \since 5.1
+ \overload
+
+ Starts the program set by setProgram() with arguments set by setArguments().
+ The OpenMode is set to \a mode.
+
+ This method is a convenient alias to open().
+
+ \sa open(), setProgram(), setArguments()
+ */
+void QProcess::start(OpenMode mode)
+{
+ open(mode);
+}
+
+/*!
+ Starts the program set by setProgram() in a new process, if none is already
+ running, passing the command line arguments set by setArguments(). The OpenMode
+ is set to \a mode.
+
+ The QProcess object will immediately enter the Starting state. If the
+ process starts successfully, QProcess will emit started(); otherwise,
+ error() will be emitted. If the QProcess object is already running a
+ process, a warning may be printed at the console, the function will return false,
+ and the existing process will continue running.
+
+ \note Processes are started asynchronously, which means the started()
+ and error() signals may be delayed. Call waitForStarted() to make
+ sure the process has started (or has failed to start) and those signals
+ have been emitted. In this regard, a true return value merly means the process
+ was correcty initialized, not that the program was actually started.
+
+*/
+bool QProcess::open(OpenMode mode)
+{
+ Q_D(QProcess);
+ if (d->processState != NotRunning) {
+ qWarning("QProcess::start: Process is already running");
+ return false;
+ }
+ if (d->program.isEmpty()) {
+ qWarning("QProcess::start: program not set");
+ return false;
+ }
+
#if defined QPROCESS_DEBUG
qDebug() << "QProcess::start(" << program << ',' << arguments << ',' << mode << ')';
#endif
@@ -1967,14 +2022,13 @@ void QProcess::start(const QString &program, const QStringList &arguments, OpenM
d->stdoutChannel.closed = false;
d->stderrChannel.closed = false;
- d->program = program;
- d->arguments = arguments;
-
d->exitCode = 0;
d->exitStatus = NormalExit;
d->processError = QProcess::UnknownError;
d->errorString.clear();
d->startProcess();
+
+ return true;
}
@@ -2074,6 +2128,24 @@ QString QProcess::program() const
}
/*!
+ \since 5.1
+
+ Set the \a program to use when starting the process.
+ That function must be call before open()
+
+ \sa start(), setArguments(), program()
+*/
+void QProcess::setProgram(const QString &program)
+{
+ Q_D(QProcess);
+ if (d->processState != NotRunning) {
+ qWarning("QProcess::setProgram: Process is already running");
+ return;
+ }
+ d->program = program;
+}
+
+/*!
Returns the command line arguments the process was last started with.
\sa start()
@@ -2085,6 +2157,24 @@ QStringList QProcess::arguments() const
}
/*!
+ \since 5.1
+
+ Set the \a arguments to pass to the called program when starting the process.
+ That function must be call before open()
+
+ \sa start(), setProgram(), arguments()
+*/
+void QProcess::setArguments(const QStringList &arguments)
+{
+ Q_D(QProcess);
+ if (d->processState != NotRunning) {
+ qWarning("QProcess::setProgram: Process is already running");
+ return;
+ }
+ d->arguments = arguments;
+}
+
+/*!
Attempts to terminate the process.
The process may not exit as a result of calling this function (it is given
diff --git a/src/corelib/io/qprocess.h b/src/corelib/io/qprocess.h
index 2c6746b0ab..29adf37f74 100644
--- a/src/corelib/io/qprocess.h
+++ b/src/corelib/io/qprocess.h
@@ -46,8 +46,6 @@
#include <QtCore/qstringlist.h>
#include <QtCore/qshareddata.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -138,8 +136,14 @@ public:
void start(const QString &program, const QStringList &arguments, OpenMode mode = ReadWrite);
void start(const QString &command, OpenMode mode = ReadWrite);
+ void start(OpenMode mode = ReadWrite);
+ bool open(OpenMode mode = ReadWrite) Q_DECL_OVERRIDE;
+
QString program() const;
+ void setProgram(const QString &program);
+
QStringList arguments() const;
+ void setArguments(const QStringList & arguments);
ProcessChannelMode readChannelMode() const;
void setReadChannelMode(ProcessChannelMode mode);
@@ -261,6 +265,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPROCESS_H
diff --git a/src/corelib/io/qprocess_unix.cpp b/src/corelib/io/qprocess_unix.cpp
index e159bf8f30..7f7066271b 100644
--- a/src/corelib/io/qprocess_unix.cpp
+++ b/src/corelib/io/qprocess_unix.cpp
@@ -328,16 +328,18 @@ void QProcessManager::unlock()
mutex.unlock();
}
-static void qt_create_pipe(int *pipe)
+static int qt_create_pipe(int *pipe)
{
if (pipe[0] != -1)
qt_safe_close(pipe[0]);
if (pipe[1] != -1)
qt_safe_close(pipe[1]);
- if (qt_safe_pipe(pipe) != 0) {
+ int pipe_ret = qt_safe_pipe(pipe);
+ if (pipe_ret != 0) {
qWarning("QProcessPrivate::createPipe: Cannot create pipe %p: %s",
pipe, qPrintable(qt_error_string(errno)));
}
+ return pipe_ret;
}
void QProcessPrivate::destroyPipe(int *pipe)
@@ -374,10 +376,11 @@ bool QProcessPrivate::createChannel(Channel &channel)
if (channel.type == Channel::Normal) {
// we're piping this channel to our own process
- qt_create_pipe(channel.pipe);
+ if (qt_create_pipe(channel.pipe) != 0)
+ return false;
// create the socket notifiers
- if (threadData->eventDispatcher) {
+ if (threadData->hasEventDispatcher()) {
if (&channel == &stdinChannel) {
channel.notifier = new QSocketNotifier(channel.pipe[1],
QSocketNotifier::Write, q);
@@ -458,7 +461,8 @@ bool QProcessPrivate::createChannel(Channel &channel)
Q_ASSERT(sink->pipe[0] == INVALID_Q_PIPE && sink->pipe[1] == INVALID_Q_PIPE);
Q_PIPE pipe[2] = { -1, -1 };
- qt_create_pipe(pipe);
+ if (qt_create_pipe(pipe) != 0)
+ return false;
sink->pipe[0] = pipe[0];
source->pipe[1] = pipe[1];
@@ -548,12 +552,17 @@ void QProcessPrivate::startProcess()
// Initialize pipes
if (!createChannel(stdinChannel) ||
!createChannel(stdoutChannel) ||
- !createChannel(stderrChannel))
+ !createChannel(stderrChannel) ||
+ qt_create_pipe(childStartedPipe) != 0 ||
+ qt_create_pipe(deathPipe) != 0) {
+ processError = QProcess::FailedToStart;
+ q->setErrorString(qt_error_string(errno));
+ emit q->error(processError);
+ cleanup();
return;
- qt_create_pipe(childStartedPipe);
- qt_create_pipe(deathPipe);
+ }
- if (threadData->eventDispatcher) {
+ if (threadData->hasEventDispatcher()) {
startupSocketNotifier = new QSocketNotifier(childStartedPipe[0],
QSocketNotifier::Read, q);
QObject::connect(startupSocketNotifier, SIGNAL(activated(int)),
@@ -1001,9 +1010,9 @@ static int select_msecs(int nfds, fd_set *fdread, fd_set *fdwrite, int timeout)
if (timeout < 0)
return qt_safe_select(nfds, fdread, fdwrite, 0, 0);
- struct timeval tv;
+ struct timespec tv;
tv.tv_sec = timeout / 1000;
- tv.tv_usec = (timeout % 1000) * 1000;
+ tv.tv_nsec = (timeout % 1000) * 1000 * 1000;
return qt_safe_select(nfds, fdread, fdwrite, 0, &tv);
}
@@ -1339,10 +1348,15 @@ bool QProcessPrivate::startDetached(const QString &program, const QStringList &a
// To catch the startup of the child
int startedPipe[2];
- qt_safe_pipe(startedPipe);
+ if (qt_safe_pipe(startedPipe) != 0)
+ return false;
// To communicate the pid of the child
int pidPipe[2];
- qt_safe_pipe(pidPipe);
+ if (qt_safe_pipe(pidPipe) != 0) {
+ qt_safe_close(startedPipe[0]);
+ qt_safe_close(startedPipe[1]);
+ return false;
+ }
pid_t childPid = fork();
if (childPid == 0) {
diff --git a/src/corelib/io/qprocess_win.cpp b/src/corelib/io/qprocess_win.cpp
index 693778e629..0f36c3adbf 100644
--- a/src/corelib/io/qprocess_win.cpp
+++ b/src/corelib/io/qprocess_win.cpp
@@ -312,11 +312,13 @@ void QProcessPrivate::destroyChannel(Channel *channel)
}
} else if (channel == &stdoutChannel) {
if (stdoutReader) {
+ stdoutReader->stop();
stdoutReader->deleteLater();
stdoutReader = 0;
}
} else if (channel == &stderrChannel) {
if (stderrReader) {
+ stderrReader->stop();
stderrReader->deleteLater();
stderrReader = 0;
}
@@ -526,7 +528,7 @@ void QProcessPrivate::startProcess()
if (!pid)
return;
- if (threadData->eventDispatcher) {
+ if (threadData->hasEventDispatcher()) {
processFinishedNotifier = new QWinEventNotifier(pid->hProcess, q);
QObject::connect(processFinishedNotifier, SIGNAL(activated(HANDLE)), q, SLOT(_q_processDied()));
processFinishedNotifier->setEnabled(true);
@@ -795,8 +797,8 @@ void QProcessPrivate::findExitCode()
DWORD theExitCode;
if (GetExitCodeProcess(pid->hProcess, &theExitCode)) {
exitCode = theExitCode;
- //### for now we assume a crash if exit code is less than -1 or the magic number
- crashed = (exitCode == 0xf291 || (int)exitCode < 0);
+ crashed = (exitCode == 0xf291 // our magic number, see killProcess
+ || (theExitCode >= 0x80000000 && theExitCode < 0xD0000000));
}
}
diff --git a/src/corelib/io/qprocess_wince.cpp b/src/corelib/io/qprocess_wince.cpp
index 4d3f550db5..712748aa59 100644
--- a/src/corelib/io/qprocess_wince.cpp
+++ b/src/corelib/io/qprocess_wince.cpp
@@ -158,7 +158,7 @@ void QProcessPrivate::startProcess()
if (!pid)
return;
- if (threadData->eventDispatcher) {
+ if (threadData->hasEventDispatcher()) {
processFinishedNotifier = new QWinEventNotifier(pid->hProcess, q);
QObject::connect(processFinishedNotifier, SIGNAL(activated(HANDLE)), q, SLOT(_q_processDied()));
processFinishedNotifier->setEnabled(true);
diff --git a/src/corelib/io/qresource.cpp b/src/corelib/io/qresource.cpp
index 0ce3ce3611..7dfc9b977c 100644
--- a/src/corelib/io/qresource.cpp
+++ b/src/corelib/io/qresource.cpp
@@ -62,15 +62,6 @@
//#define DEBUG_RESOURCE_MATCH
-#if defined(Q_OS_VXWORKS)
-# if defined(m_data)
-# undef m_data
-# endif
-# if defined(m_len)
-# undef m_len
-# endif
-#endif
-
QT_BEGIN_NAMESPACE
diff --git a/src/corelib/io/qresource.h b/src/corelib/io/qresource.h
index 1623792e0b..88467bd53b 100644
--- a/src/corelib/io/qresource.h
+++ b/src/corelib/io/qresource.h
@@ -47,8 +47,6 @@
#include <QtCore/qstringlist.h>
#include <QtCore/qlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -98,6 +96,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QRESOURCE_H
diff --git a/src/corelib/io/qresource_p.h b/src/corelib/io/qresource_p.h
index 3fdaa41206..d632ac70be 100644
--- a/src/corelib/io/qresource_p.h
+++ b/src/corelib/io/qresource_p.h
@@ -109,7 +109,7 @@ public:
virtual Iterator *beginEntryList(QDir::Filters filters, const QStringList &filterNames);
virtual Iterator *endEntryList();
-
+
bool extension(Extension extension, const ExtensionOption *option = 0, ExtensionReturn *output = 0);
bool supportsExtension(Extension extension) const;
};
diff --git a/src/corelib/io/qsavefile.cpp b/src/corelib/io/qsavefile.cpp
new file mode 100644
index 0000000000..f8b5ebcabd
--- /dev/null
+++ b/src/corelib/io/qsavefile.cpp
@@ -0,0 +1,383 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 David Faure <faure@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qplatformdefs.h"
+#include "qsavefile.h"
+#include "private/qsavefile_p.h"
+#include "qfileinfo.h"
+#include "qabstractfileengine_p.h"
+#include "qdebug.h"
+#include "qtemporaryfile.h"
+#include "private/qiodevice_p.h"
+#include "private/qtemporaryfile_p.h"
+#ifdef Q_OS_UNIX
+#include <errno.h>
+#endif
+
+QT_BEGIN_NAMESPACE
+
+QSaveFilePrivate::QSaveFilePrivate()
+ : writeError(QFileDevice::NoError),
+ useTemporaryFile(true),
+ directWriteFallback(false)
+{
+}
+
+QSaveFilePrivate::~QSaveFilePrivate()
+{
+}
+
+/*!
+ \class QSaveFile
+ \inmodule QtCore
+ \brief The QSaveFile class provides an interface for safely writing to files.
+
+ \ingroup io
+
+ \reentrant
+
+ \since 5.1
+
+ QSaveFile is an I/O device for writing text and binary files, without losing
+ existing data if the writing operation fails.
+
+ While writing, the contents will be written to a temporary file, and if
+ no error happened, commit() will move it to the final file. This ensures that
+ no data at the final file is lost in case an error happens while writing,
+ and no partially-written file is ever present at the final location. Always
+ use QSaveFile when saving entire documents to disk.
+
+ QSaveFile automatically detects errors while writing, such as the full partition
+ situation, where write() cannot write all the bytes. It will remember that
+ an error happened, and will discard the temporary file in commit().
+
+ Much like with QFile, the file is opened with open(). Data is usually read
+ and written using QDataStream or QTextStream, but you can also call the
+ QIODevice-inherited functions read(), readLine(), readAll(), write().
+
+ Unlike QFile, calling close() is not allowed. commit() replaces it. If commit()
+ was not called and the QSaveFile instance is destroyed, the temporary file is
+ discarded.
+
+ To abort saving due to an application error, call cancelWriting(), so that
+ even a call to commit() later on will not save.
+
+ \sa QTextStream, QDataStream, QFileInfo, QDir, QFile, QTemporaryFile
+*/
+
+/*!
+ Constructs a new file object with the given \a parent.
+*/
+QSaveFile::QSaveFile(QObject *parent)
+ : QFileDevice(*new QSaveFilePrivate, parent)
+{
+}
+/*!
+ Constructs a new file object to represent the file with the given \a name.
+*/
+QSaveFile::QSaveFile(const QString &name)
+ : QFileDevice(*new QSaveFilePrivate, 0)
+{
+ Q_D(QSaveFile);
+ d->fileName = name;
+}
+/*!
+ Constructs a new file object with the given \a parent to represent the
+ file with the specified \a name.
+*/
+QSaveFile::QSaveFile(const QString &name, QObject *parent)
+ : QFileDevice(*new QSaveFilePrivate, parent)
+{
+ Q_D(QSaveFile);
+ d->fileName = name;
+}
+
+/*!
+ Destroys the file object, discarding the saved contents unless commit() was called.
+*/
+QSaveFile::~QSaveFile()
+{
+ Q_D(QSaveFile);
+ QFileDevice::close();
+ if (d->fileEngine) {
+ d->fileEngine->remove();
+ delete d->fileEngine;
+ d->fileEngine = 0;
+ }
+}
+
+/*!
+ Returns the name set by setFileName() or to the QSaveFile
+ constructor.
+
+ \sa setFileName()
+*/
+QString QSaveFile::fileName() const
+{
+ return d_func()->fileName;
+}
+
+/*!
+ Sets the \a name of the file. The name can have no path, a
+ relative path, or an absolute path.
+
+ \sa QFile::setFileName(), fileName()
+*/
+void QSaveFile::setFileName(const QString &name)
+{
+ d_func()->fileName = name;
+}
+
+/*!
+ Opens the file using OpenMode \a mode, returning true if successful;
+ otherwise false.
+
+ Important: the \a mode must include QIODevice::WriteOnly.
+ It may also have additional flags, such as QIODevice::Text and QIODevice::Unbuffered.
+
+ QIODevice::ReadWrite and QIODevice::Append are not supported at the moment.
+
+ \sa QIODevice::OpenMode, setFileName()
+*/
+bool QSaveFile::open(OpenMode mode)
+{
+ Q_D(QSaveFile);
+ if (isOpen()) {
+ qWarning("QSaveFile::open: File (%s) already open", qPrintable(fileName()));
+ return false;
+ }
+ unsetError();
+ if ((mode & (ReadOnly | WriteOnly)) == 0) {
+ qWarning("QSaveFile::open: Open mode not specified");
+ return false;
+ }
+ // In the future we could implement ReadWrite by copying from the existing file to the temp file...
+ if ((mode & ReadOnly) || (mode & Append)) {
+ qWarning("QSaveFile::open: Unsupported open mode 0x%x", int(mode));
+ return false;
+ }
+
+ // check if existing file is writable
+ QFileInfo existingFile(d->fileName);
+ if (existingFile.exists() && !existingFile.isWritable()) {
+ d->setError(QFileDevice::WriteError, QSaveFile::tr("Existing file %1 is not writable").arg(d->fileName));
+ d->writeError = QFileDevice::WriteError;
+ return false;
+ }
+ d->fileEngine = new QTemporaryFileEngine(d->fileName);
+ // Same as in QFile: QIODevice provides the buffering, so there's no need to request it from the file engine.
+ if (!d->fileEngine->open(mode | QIODevice::Unbuffered)) {
+ QFileDevice::FileError err = d->fileEngine->error();
+#ifdef Q_OS_UNIX
+ if (d->directWriteFallback && err == QFileDevice::OpenError && errno == EACCES) {
+ delete d->fileEngine;
+ d->fileEngine = QAbstractFileEngine::create(d->fileName);
+ if (d->fileEngine->open(mode | QIODevice::Unbuffered)) {
+ d->useTemporaryFile = false;
+ QFileDevice::open(mode);
+ return true;
+ }
+ err = d->fileEngine->error();
+ }
+#endif
+ if (err == QFileDevice::UnspecifiedError)
+ err = QFileDevice::OpenError;
+ d->setError(err, d->fileEngine->errorString());
+ delete d->fileEngine;
+ d->fileEngine = 0;
+ return false;
+ }
+
+ d->useTemporaryFile = true;
+ QFileDevice::open(mode);
+ if (existingFile.exists())
+ setPermissions(existingFile.permissions());
+ return true;
+}
+
+/*!
+ \reimp
+ This method has been made private so that it cannot be called, in order to prevent mistakes.
+ In order to finish writing the file, call commit().
+ If instead you want to abort writing, call cancelWriting().
+*/
+void QSaveFile::close()
+{
+ qFatal("QSaveFile::close called");
+}
+
+/*!
+ Commits the changes to disk, if all previous writes were successful.
+
+ It is mandatory to call this at the end of the saving operation, otherwise the file will be
+ discarded.
+
+ If an error happened during writing, deletes the temporary file and returns false.
+ Otherwise, renames it to the final fileName and returns true on success.
+ Finally, closes the device.
+
+ \sa cancelWriting()
+*/
+bool QSaveFile::commit()
+{
+ Q_D(QSaveFile);
+ if (!d->fileEngine)
+ return false;
+
+ if (!isOpen()) {
+ qWarning("QSaveFile::commit: File (%s) is not open", qPrintable(fileName()));
+ return false;
+ }
+ QFileDevice::close(); // calls flush()
+
+ // Sync to disk if possible. Ignore errors (e.g. not supported).
+ d->fileEngine->syncToDisk();
+
+ if (d->useTemporaryFile) {
+ if (d->writeError != QFileDevice::NoError) {
+ d->fileEngine->remove();
+ d->writeError = QFileDevice::NoError;
+ delete d->fileEngine;
+ d->fileEngine = 0;
+ return false;
+ }
+ // atomically replace old file with new file
+ // Can't use QFile::rename for that, must use the file engine directly
+ Q_ASSERT(d->fileEngine);
+ if (!d->fileEngine->renameOverwrite(d->fileName)) {
+ d->setError(d->fileEngine->error(), d->fileEngine->errorString());
+ d->fileEngine->remove();
+ delete d->fileEngine;
+ d->fileEngine = 0;
+ return false;
+ }
+ }
+ delete d->fileEngine;
+ d->fileEngine = 0;
+ return true;
+}
+
+/*!
+ Cancels writing the new file.
+
+ If the application changes its mind while saving, it can call cancelWriting(),
+ which sets an error code so that commit() will discard the temporary file.
+
+ Alternatively, it can simply make sure not to call commit().
+
+ Further write operations are possible after calling this method, but none
+ of it will have any effect, the written file will be discarded.
+
+ This method has no effect when direct write fallback is used. This is the case
+ when saving over an existing file in a readonly directory: no temporary file can
+ be created, so the existing file is overwritten no matter what, and cancelWriting()
+ cannot do anything about that, the contents of the existing file will be lost.
+
+ \sa commit()
+*/
+void QSaveFile::cancelWriting()
+{
+ Q_D(QSaveFile);
+ if (!isOpen())
+ return;
+ d->setError(QFileDevice::WriteError, QSaveFile::tr("Writing canceled by application"));
+ d->writeError = QFileDevice::WriteError;
+}
+
+/*!
+ \reimp
+*/
+qint64 QSaveFile::writeData(const char *data, qint64 len)
+{
+ Q_D(QSaveFile);
+ if (d->writeError != QFileDevice::NoError)
+ return -1;
+
+ const qint64 ret = QFileDevice::writeData(data, len);
+
+ if (d->error != QFileDevice::NoError)
+ d->writeError = d->error;
+ return ret;
+}
+
+/*!
+ Allows writing over the existing file if necessary.
+
+ QSaveFile creates a temporary file in the same directory as the final
+ file and atomically renames it. However this is not possible if the
+ directory permissions do not allow creating new files.
+ In order to preserve atomicity guarantees, open() fails when it
+ cannot create the temporary file.
+
+ In order to allow users to edit files with write permissions in a
+ directory with restricted permissions, call setDirectWriteFallback() with
+ \a enabled set to true, and the following calls to open() will fallback to
+ opening the existing file directly and writing into it, without the use of
+ a temporary file.
+ This does not have atomicity guarantees, i.e. an application crash or
+ for instance a power failure could lead to a partially-written file on disk.
+ It also means cancelWriting() has no effect, in such a case.
+
+ Typically, to save documents edited by the user, call setDirectWriteFallback(true),
+ and to save application internal files (configuration files, data files, ...), keep
+ the default setting which ensures atomicity.
+
+ \sa directWriteFallback()
+*/
+void QSaveFile::setDirectWriteFallback(bool enabled)
+{
+ Q_D(QSaveFile);
+ d->directWriteFallback = enabled;
+}
+
+/*!
+ Returns true if the fallback solution for saving files in read-only
+ directories is enabled.
+
+ \sa setDirectWriteFallback()
+*/
+bool QSaveFile::directWriteFallback() const
+{
+ Q_D(const QSaveFile);
+ return d->directWriteFallback;
+}
+
+QT_END_NAMESPACE
diff --git a/src/corelib/io/qsavefile.h b/src/corelib/io/qsavefile.h
new file mode 100644
index 0000000000..6d81f58d42
--- /dev/null
+++ b/src/corelib/io/qsavefile.h
@@ -0,0 +1,93 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 David Faure <faure@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QSAVEFILE_H
+#define QSAVEFILE_H
+
+#include <QtCore/qfiledevice.h>
+#include <QtCore/qstring.h>
+
+#ifdef open
+#error qsavefile.h must be included before any header file that defines open
+#endif
+
+QT_BEGIN_NAMESPACE
+
+
+class QAbstractFileEngine;
+class QSaveFilePrivate;
+
+class Q_CORE_EXPORT QSaveFile : public QFileDevice
+{
+ Q_OBJECT
+ Q_DECLARE_PRIVATE(QSaveFile)
+
+public:
+
+ explicit QSaveFile(const QString &name);
+ explicit QSaveFile(QObject *parent = 0);
+ explicit QSaveFile(const QString &name, QObject *parent);
+ ~QSaveFile();
+
+ QString fileName() const Q_DECL_OVERRIDE;
+ void setFileName(const QString &name);
+
+ bool open(OpenMode flags) Q_DECL_OVERRIDE;
+ bool commit();
+
+ void cancelWriting();
+
+ void setDirectWriteFallback(bool enabled);
+ bool directWriteFallback() const;
+
+protected:
+ qint64 writeData(const char *data, qint64 len) Q_DECL_OVERRIDE;
+
+private:
+ void close() Q_DECL_OVERRIDE;
+
+private:
+ Q_DISABLE_COPY(QSaveFile)
+};
+
+QT_END_NAMESPACE
+
+#endif // QSAVEFILE_H
diff --git a/src/widgets/styles/qmacstylepixmaps_mac_p.h b/src/corelib/io/qsavefile_p.h
index f76383a2d4..53a8b5eb34 100644
--- a/src/widgets/styles/qmacstylepixmaps_mac_p.h
+++ b/src/corelib/io/qsavefile_p.h
@@ -1,9 +1,9 @@
/****************************************************************************
**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2013 David Faure <faure@kde.org>
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtCore module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -39,8 +39,8 @@
**
****************************************************************************/
-#ifndef QMACSTYLEPIXMAPS_MAC_P_H
-#define QMACSTYLEPIXMAPS_MAC_P_H
+#ifndef QSAVEFILE_P_H
+#define QSAVEFILE_P_H
//
// W A R N I N G
@@ -53,20 +53,26 @@
// We mean it.
//
-static const char * const qt_mac_toolbar_ext[]={
- "14 9 4 1",
- "# c #858585",
- "b c #d9d9d9",
- ". c #dbdbdb",
- "a c None",
- ".###..###.aaaa",
- "a.###..###.aaa",
- "aab###bb###baa",
- "aaab###bb###ba",
- "aaaa.###..###.",
- "aaa.###..###.a",
- "aab###bb###baa",
- "ab###bb###baaa",
- ".###..###.aaaa"};
+#include "private/qfiledevice_p.h"
-#endif // QMACSTYLEPIXMAPS_MAC_P_H
+QT_BEGIN_NAMESPACE
+
+class QSaveFilePrivate : public QFileDevicePrivate
+{
+ Q_DECLARE_PUBLIC(QSaveFile)
+
+protected:
+ QSaveFilePrivate();
+ ~QSaveFilePrivate();
+
+ QString fileName;
+
+ QFileDevice::FileError writeError;
+
+ bool useTemporaryFile;
+ bool directWriteFallback;
+};
+
+QT_END_NAMESPACE
+
+#endif // QSAVEFILE_P_H
diff --git a/src/corelib/io/qsettings.cpp b/src/corelib/io/qsettings.cpp
index d7b100ba3c..a0904fea24 100644
--- a/src/corelib/io/qsettings.cpp
+++ b/src/corelib/io/qsettings.cpp
@@ -1074,7 +1074,7 @@ static void initDefaultPaths(QMutexLocker *locker)
QString systemPath;
locker->unlock();
-
+
/*
QLibraryInfo::location() uses QSettings, so in order to
avoid a dead-lock, we can't hold the global mutex while
@@ -3198,7 +3198,7 @@ bool QSettings::isWritable() const
}
/*!
-
+
Sets the value of setting \a key to \a value. If the \a key already
exists, the previous value is overwritten.
@@ -3465,7 +3465,7 @@ void QSettings::setPath(Format format, Scope scope, const QString &path)
\typedef QSettings::SettingsMap
Typedef for QMap<QString, QVariant>.
-
+
\sa registerFormat()
*/
@@ -3477,8 +3477,8 @@ void QSettings::setPath(Format format, Scope scope, const QString &path)
\snippet code/src_corelib_io_qsettings.cpp 27
\c ReadFunc is used in \c registerFormat() as a pointer to a function
- that reads a set of key/value pairs. \c ReadFunc should read all the
- options in one pass, and return all the settings in the \c SettingsMap
+ that reads a set of key/value pairs. \c ReadFunc should read all the
+ options in one pass, and return all the settings in the \c SettingsMap
container, which is initially empty.
\sa WriteFunc, registerFormat()
@@ -3491,7 +3491,7 @@ void QSettings::setPath(Format format, Scope scope, const QString &path)
\snippet code/src_corelib_io_qsettings.cpp 28
- \c WriteFunc is used in \c registerFormat() as a pointer to a function
+ \c WriteFunc is used in \c registerFormat() as a pointer to a function
that writes a set of key/value pairs. \c WriteFunc is only called once,
so you need to output the settings in one go.
diff --git a/src/corelib/io/qsettings.h b/src/corelib/io/qsettings.h
index 99b8ac108f..a720b3d709 100644
--- a/src/corelib/io/qsettings.h
+++ b/src/corelib/io/qsettings.h
@@ -47,8 +47,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qscopedpointer.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
@@ -198,6 +196,4 @@ QT_END_NAMESPACE
#endif // QT_NO_SETTINGS
-QT_END_HEADER
-
#endif // QSETTINGS_H
diff --git a/src/corelib/io/qsettings_win.cpp b/src/corelib/io/qsettings_win.cpp
index bd127e621e..9ce14f1851 100644
--- a/src/corelib/io/qsettings_win.cpp
+++ b/src/corelib/io/qsettings_win.cpp
@@ -569,7 +569,7 @@ QWinSettingsPrivate::~QWinSettingsPrivate()
{
if (deleteWriteHandleOnExit && writeHandle() != 0) {
#if defined(Q_OS_WINCE)
- remove(regList.at(0).key());
+ remove(regList.at(0).key());
#else
QString emptyKey;
DWORD res = RegDeleteKey(writeHandle(), reinterpret_cast<const wchar_t *>(emptyKey.utf16()));
diff --git a/src/corelib/io/qstandardpaths.h b/src/corelib/io/qstandardpaths.h
index 9b95d26ce1..d8b6d24f57 100644
--- a/src/corelib/io/qstandardpaths.h
+++ b/src/corelib/io/qstandardpaths.h
@@ -44,8 +44,6 @@
#include <QtCore/qstringlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -85,7 +83,9 @@ public:
static QString locate(StandardLocation type, const QString &fileName, LocateOptions options = LocateFile);
static QStringList locateAll(StandardLocation type, const QString &fileName, LocateOptions options = LocateFile);
+#ifndef QT_BOOTSTRAPPED
static QString displayName(StandardLocation type);
+#endif
static QString findExecutable(const QString &executableName, const QStringList &paths = QStringList());
@@ -102,6 +102,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTANDARDPATHS_H
diff --git a/src/corelib/io/qstandardpaths_win.cpp b/src/corelib/io/qstandardpaths_win.cpp
index 478db6c299..d4e0779381 100644
--- a/src/corelib/io/qstandardpaths_win.cpp
+++ b/src/corelib/io/qstandardpaths_win.cpp
@@ -160,10 +160,10 @@ QString QStandardPaths::writableLocation(StandardLocation type)
// Although Microsoft has a Cache key it is a pointer to IE's cache, not a cache
// location for everyone. Most applications seem to be using a
// cache directory located in their AppData directory
- return writableLocation(DataLocation) + QLatin1String("\\cache");
+ return writableLocation(DataLocation) + QLatin1String("/cache");
case GenericCacheLocation:
- return writableLocation(GenericDataLocation) + QLatin1String("\\cache");
+ return writableLocation(GenericDataLocation) + QLatin1String("/cache");
case RuntimeLocation:
case HomeLocation:
diff --git a/src/corelib/io/qtemporarydir.cpp b/src/corelib/io/qtemporarydir.cpp
index 6782fcb986..755c31f371 100644
--- a/src/corelib/io/qtemporarydir.cpp
+++ b/src/corelib/io/qtemporarydir.cpp
@@ -52,7 +52,7 @@
#endif
#include <stdlib.h> // mkdtemp
-#if defined(Q_OS_QNX) || defined(Q_OS_WIN)
+#if defined(Q_OS_QNX) || defined(Q_OS_WIN) || defined(Q_OS_ANDROID)
#include <private/qfilesystemengine_p.h>
#endif
@@ -94,9 +94,9 @@ static QString defaultTemplateName()
return QDir::tempPath() + QLatin1Char('/') + baseName + QLatin1String("-XXXXXX");
}
-#if defined(Q_OS_QNX ) || defined(Q_OS_WIN)
-static char *mkdtemp(char *templateName)
+static char *q_mkdtemp(char *templateName)
{
+#if defined(Q_OS_QNX ) || defined(Q_OS_WIN) || defined(Q_OS_ANDROID)
static const char letters[] = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";
const size_t length = strlen(templateName);
@@ -137,17 +137,17 @@ static char *mkdtemp(char *templateName)
}
}
return 0;
-}
-#elif defined(Q_OS_LINUX_ANDROID)
-extern char *mkdtemp(char *);
+#else
+ return mkdtemp(templateName);
#endif
+}
void QTemporaryDirPrivate::create(const QString &templateName)
{
QByteArray buffer = QFile::encodeName(templateName);
if (!buffer.endsWith("XXXXXX"))
buffer += "XXXXXX";
- if (mkdtemp(buffer.data())) { // modifies buffer
+ if (q_mkdtemp(buffer.data())) { // modifies buffer
success = true;
path = QFile::decodeName(buffer.constData());
}
diff --git a/src/corelib/io/qtemporarydir.h b/src/corelib/io/qtemporarydir.h
index b22c8f9329..47252cb5e5 100644
--- a/src/corelib/io/qtemporarydir.h
+++ b/src/corelib/io/qtemporarydir.h
@@ -45,8 +45,6 @@
#include <QtCore/qdir.h>
#include <QtCore/QScopedPointer>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -79,6 +77,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEMPORARYDIR_H
diff --git a/src/corelib/io/qtemporaryfile.cpp b/src/corelib/io/qtemporaryfile.cpp
index 9408727d25..c2f421843c 100644
--- a/src/corelib/io/qtemporaryfile.cpp
+++ b/src/corelib/io/qtemporaryfile.cpp
@@ -44,10 +44,9 @@
#ifndef QT_NO_TEMPORARYFILE
#include "qplatformdefs.h"
+#include "private/qtemporaryfile_p.h"
#include "private/qfile_p.h"
-#include "private/qfsfileengine_p.h"
#include "private/qsystemerror_p.h"
-#include "private/qfilesystemengine_p.h"
#if !defined(Q_OS_WIN)
#include "private/qcore_unix_p.h" // overrides QT_OPEN
@@ -161,7 +160,14 @@ static bool createFileFromTemplate(NativeFileHandle &file,
return true;
DWORD err = GetLastError();
- if (err != ERROR_FILE_EXISTS) {
+ if (err == ERROR_ACCESS_DENIED) {
+ DWORD attributes = GetFileAttributes((const wchar_t *)path.constData());
+ if (attributes == INVALID_FILE_ATTRIBUTES) {
+ // Potential write error (read-only parent directory, etc.).
+ error = QSystemError(err, QSystemError::NativeError);
+ return false;
+ } // else file already exists as a directory.
+ } else if (err != ERROR_FILE_EXISTS) {
error = QSystemError(err, QSystemError::NativeError);
return false;
}
@@ -218,36 +224,6 @@ static bool createFileFromTemplate(NativeFileHandle &file,
}
//************* QTemporaryFileEngine
-class QTemporaryFileEngine : public QFSFileEngine
-{
- Q_DECLARE_PRIVATE(QFSFileEngine)
-public:
- QTemporaryFileEngine(const QString &file, bool fileIsTemplate = true)
- : QFSFileEngine(), filePathIsTemplate(fileIsTemplate),
- filePathWasTemplate(fileIsTemplate)
- {
- Q_D(QFSFileEngine);
- d->fileEntry = QFileSystemEntry(file);
-
- if (!filePathIsTemplate)
- QFSFileEngine::setFileName(file);
- }
-
- ~QTemporaryFileEngine();
-
- bool isReallyOpen();
- void setFileName(const QString &file);
- void setFileTemplate(const QString &fileTemplate);
-
- bool open(QIODevice::OpenMode flags);
- bool remove();
- bool rename(const QString &newName);
- bool close();
-
- bool filePathIsTemplate;
- bool filePathWasTemplate;
-};
-
QTemporaryFileEngine::~QTemporaryFileEngine()
{
QFSFileEngine::close();
@@ -398,6 +374,12 @@ bool QTemporaryFileEngine::rename(const QString &newName)
return QFSFileEngine::rename(newName);
}
+bool QTemporaryFileEngine::renameOverwrite(const QString &newName)
+{
+ QFSFileEngine::close();
+ return QFSFileEngine::renameOverwrite(newName);
+}
+
bool QTemporaryFileEngine::close()
{
// Don't close the file, just seek to the front.
@@ -407,19 +389,6 @@ bool QTemporaryFileEngine::close()
}
//************* QTemporaryFilePrivate
-class QTemporaryFilePrivate : public QFilePrivate
-{
- Q_DECLARE_PUBLIC(QTemporaryFile)
-
-protected:
- QTemporaryFilePrivate();
- ~QTemporaryFilePrivate();
-
- QAbstractFileEngine *engine() const;
-
- bool autoRemove;
- QString templateName;
-};
QTemporaryFilePrivate::QTemporaryFilePrivate() : autoRemove(true)
{
@@ -440,7 +409,7 @@ QAbstractFileEngine *QTemporaryFilePrivate::engine() const
return fileEngine;
}
-static QString defaultTemplateName()
+QString QTemporaryFilePrivate::defaultTemplateName()
{
QString baseName;
#if defined(QT_BUILD_CORE_LIB)
@@ -506,7 +475,7 @@ QTemporaryFile::QTemporaryFile()
: QFile(*new QTemporaryFilePrivate)
{
Q_D(QTemporaryFile);
- d->templateName = defaultTemplateName();
+ d->templateName = QTemporaryFilePrivate::defaultTemplateName();
}
QTemporaryFile::QTemporaryFile(const QString &templateName)
@@ -529,7 +498,7 @@ QTemporaryFile::QTemporaryFile()
: QFile(*new QTemporaryFilePrivate, 0)
{
Q_D(QTemporaryFile);
- d->templateName = defaultTemplateName();
+ d->templateName = QTemporaryFilePrivate::defaultTemplateName();
}
/*!
@@ -565,7 +534,7 @@ QTemporaryFile::QTemporaryFile(QObject *parent)
: QFile(*new QTemporaryFilePrivate, parent)
{
Q_D(QTemporaryFile);
- d->templateName = defaultTemplateName();
+ d->templateName = QTemporaryFilePrivate::defaultTemplateName();
}
/*!
diff --git a/src/corelib/io/qtemporaryfile.h b/src/corelib/io/qtemporaryfile.h
index b497d9de93..09aa53c33b 100644
--- a/src/corelib/io/qtemporaryfile.h
+++ b/src/corelib/io/qtemporaryfile.h
@@ -49,14 +49,13 @@
#error qtemporaryfile.h must be included before any header file that defines open
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#ifndef QT_NO_TEMPORARYFILE
class QTemporaryFilePrivate;
+class QLockFilePrivate;
class Q_CORE_EXPORT QTemporaryFile : public QFile
{
@@ -98,6 +97,7 @@ protected:
private:
friend class QFile;
+ friend class QLockFilePrivate;
Q_DISABLE_COPY(QTemporaryFile)
};
@@ -105,6 +105,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEMPORARYFILE_H
diff --git a/src/corelib/io/qtemporaryfile_p.h b/src/corelib/io/qtemporaryfile_p.h
new file mode 100644
index 0000000000..d274f60ecc
--- /dev/null
+++ b/src/corelib/io/qtemporaryfile_p.h
@@ -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 QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QTEMPORARYFILE_P_H
+#define QTEMPORARYFILE_P_H
+
+#include "private/qfsfileengine_p.h"
+#include "private/qfilesystemengine_p.h"
+#include "private/qfile_p.h"
+
+QT_BEGIN_NAMESPACE
+
+class QTemporaryFilePrivate : public QFilePrivate
+{
+ Q_DECLARE_PUBLIC(QTemporaryFile)
+
+protected:
+ QTemporaryFilePrivate();
+ ~QTemporaryFilePrivate();
+
+ QAbstractFileEngine *engine() const;
+
+ bool autoRemove;
+ QString templateName;
+
+ static QString defaultTemplateName();
+
+ friend class QLockFilePrivate;
+};
+
+class QTemporaryFileEngine : public QFSFileEngine
+{
+ Q_DECLARE_PRIVATE(QFSFileEngine)
+public:
+ QTemporaryFileEngine(const QString &file, bool fileIsTemplate = true)
+ : QFSFileEngine(), filePathIsTemplate(fileIsTemplate),
+ filePathWasTemplate(fileIsTemplate)
+ {
+ Q_D(QFSFileEngine);
+ d->fileEntry = QFileSystemEntry(file);
+
+ if (!filePathIsTemplate)
+ QFSFileEngine::setFileName(file);
+ }
+
+ ~QTemporaryFileEngine();
+
+ bool isReallyOpen();
+ void setFileName(const QString &file);
+ void setFileTemplate(const QString &fileTemplate);
+
+ bool open(QIODevice::OpenMode flags);
+ bool remove();
+ bool rename(const QString &newName);
+ bool renameOverwrite(const QString &newName);
+ bool close();
+
+ bool filePathIsTemplate;
+ bool filePathWasTemplate;
+};
+
+QT_END_NAMESPACE
+
+#endif /* QTEMPORARYFILE_P_H */
+
diff --git a/src/corelib/io/qtextstream.cpp b/src/corelib/io/qtextstream.cpp
index 70c6eed9da..8459cdd158 100644
--- a/src/corelib/io/qtextstream.cpp
+++ b/src/corelib/io/qtextstream.cpp
@@ -226,12 +226,10 @@ static const int QTEXTSTREAM_BUFFERSIZE = 16384;
*/
#include "qtextstream.h"
+#include "private/qtextstream_p.h"
#include "qbuffer.h"
#include "qfile.h"
#include "qnumeric.h"
-#ifndef QT_NO_TEXTCODEC
-#include "qtextcodec.h"
-#endif
#ifndef Q_OS_WINCE
#include <locale.h>
#endif
@@ -315,119 +313,7 @@ QT_END_NAMESPACE
QT_BEGIN_NAMESPACE
-#ifndef QT_NO_QOBJECT
-class QDeviceClosedNotifier : public QObject
-{
- Q_OBJECT
-public:
- inline QDeviceClosedNotifier()
- { }
-
- inline void setupDevice(QTextStream *stream, QIODevice *device)
- {
- disconnect();
- if (device)
- connect(device, SIGNAL(aboutToClose()), this, SLOT(flushStream()));
- this->stream = stream;
- }
-
-public Q_SLOTS:
- inline void flushStream() { stream->flush(); }
-
-private:
- QTextStream *stream;
-};
-#endif
-
//-------------------------------------------------------------------
-class QTextStreamPrivate
-{
- Q_DECLARE_PUBLIC(QTextStream)
-public:
- QTextStreamPrivate(QTextStream *q_ptr);
- ~QTextStreamPrivate();
- void reset();
-
- // device
- QIODevice *device;
-#ifndef QT_NO_QOBJECT
- QDeviceClosedNotifier deviceClosedNotifier;
-#endif
- bool deleteDevice;
-
- // string
- QString *string;
- int stringOffset;
- QIODevice::OpenMode stringOpenMode;
-
-#ifndef QT_NO_TEXTCODEC
- // codec
- QTextCodec *codec;
- QTextCodec::ConverterState readConverterState;
- QTextCodec::ConverterState writeConverterState;
- QTextCodec::ConverterState *readConverterSavedState;
- bool autoDetectUnicode;
-#endif
-
- // i/o
- enum TokenDelimiter {
- Space,
- NotSpace,
- EndOfLine
- };
-
- QString read(int maxlen);
- bool scan(const QChar **ptr, int *tokenLength,
- int maxlen, TokenDelimiter delimiter);
- inline const QChar *readPtr() const;
- inline void consumeLastToken();
- inline void consume(int nchars);
- void saveConverterState(qint64 newPos);
- void restoreToSavedConverterState();
- int lastTokenSize;
-
- // Return value type for getNumber()
- enum NumberParsingStatus {
- npsOk,
- npsMissingDigit,
- npsInvalidPrefix
- };
-
- inline bool getChar(QChar *ch);
- inline void ungetChar(QChar ch);
- NumberParsingStatus getNumber(qulonglong *l);
- bool getReal(double *f);
-
- inline void write(const QString &data);
- inline void putString(const QString &ch, bool number = false);
- void putNumber(qulonglong number, bool negative);
-
- // buffers
- bool fillReadBuffer(qint64 maxBytes = -1);
- void resetReadBuffer();
- void flushWriteBuffer();
- QString writeBuffer;
- QString readBuffer;
- int readBufferOffset;
- int readConverterSavedStateOffset; //the offset between readBufferStartDevicePos and that start of the buffer
- qint64 readBufferStartDevicePos;
-
- // streaming parameters
- int realNumberPrecision;
- int integerBase;
- int fieldWidth;
- QChar padChar;
- QTextStream::FieldAlignment fieldAlignment;
- QTextStream::RealNumberNotation realNumberNotation;
- QTextStream::NumberFlags numberFlags;
-
- // status
- QTextStream::Status status;
-
- QLocale locale;
-
- QTextStream *q_ptr;
-};
/*!
\internal
@@ -481,10 +367,7 @@ static void copyConverterStateHelper(QTextCodec::ConverterState *dest,
}
#endif
-/*!
- \internal
-*/
-void QTextStreamPrivate::reset()
+void QTextStreamPrivate::Params::reset()
{
realNumberPrecision = 6;
integerBase = 0;
@@ -493,6 +376,14 @@ void QTextStreamPrivate::reset()
fieldAlignment = QTextStream::AlignRight;
realNumberNotation = QTextStream::SmartNotation;
numberFlags = 0;
+}
+
+/*!
+ \internal
+*/
+void QTextStreamPrivate::reset()
+{
+ params.reset();
device = 0;
deleteDevice = false;
@@ -985,15 +876,17 @@ inline void QTextStreamPrivate::putString(const QString &s, bool number)
QString tmp = s;
// handle padding
- int padSize = fieldWidth - s.size();
+ int padSize = params.fieldWidth - s.size();
if (padSize > 0) {
- QString pad(padSize, padChar);
- if (fieldAlignment == QTextStream::AlignLeft) {
- tmp.append(QString(padSize, padChar));
- } else if (fieldAlignment == QTextStream::AlignRight
- || fieldAlignment == QTextStream::AlignAccountingStyle) {
- tmp.prepend(QString(padSize, padChar));
- if (fieldAlignment == QTextStream::AlignAccountingStyle && number) {
+ QString pad(padSize, params.padChar);
+ switch (params.fieldAlignment) {
+ case QTextStream::AlignLeft:
+ tmp.append(pad);
+ break;
+ case QTextStream::AlignRight:
+ case QTextStream::AlignAccountingStyle:
+ tmp.prepend(pad);
+ if (params.fieldAlignment == QTextStream::AlignAccountingStyle && number) {
const QChar sign = s.size() > 0 ? s.at(0) : QChar();
if (sign == locale.negativeSign() || sign == locale.positiveSign()) {
QChar *data = tmp.data();
@@ -1001,9 +894,11 @@ inline void QTextStreamPrivate::putString(const QString &s, bool number)
data[0] = sign;
}
}
- } else if (fieldAlignment == QTextStream::AlignCenter) {
- tmp.prepend(QString(padSize/2, padChar));
- tmp.append(QString(padSize - padSize/2, padChar));
+ break;
+ case QTextStream::AlignCenter:
+ tmp.prepend(QString(padSize/2, params.padChar));
+ tmp.append(QString(padSize - padSize/2, params.padChar));
+ break;
}
}
@@ -1175,13 +1070,7 @@ void QTextStream::reset()
{
Q_D(QTextStream);
- d->realNumberPrecision = 6;
- d->integerBase = 0;
- d->fieldWidth = 0;
- d->padChar = QLatin1Char(' ');
- d->fieldAlignment = QTextStream::AlignRight;
- d->realNumberNotation = QTextStream::SmartNotation;
- d->numberFlags = 0;
+ d->params.reset();
}
/*!
@@ -1400,7 +1289,7 @@ QString *QTextStream::string() const
void QTextStream::setFieldAlignment(FieldAlignment mode)
{
Q_D(QTextStream);
- d->fieldAlignment = mode;
+ d->params.fieldAlignment = mode;
}
/*!
@@ -1411,7 +1300,7 @@ void QTextStream::setFieldAlignment(FieldAlignment mode)
QTextStream::FieldAlignment QTextStream::fieldAlignment() const
{
Q_D(const QTextStream);
- return d->fieldAlignment;
+ return d->params.fieldAlignment;
}
/*!
@@ -1432,7 +1321,7 @@ QTextStream::FieldAlignment QTextStream::fieldAlignment() const
void QTextStream::setPadChar(QChar ch)
{
Q_D(QTextStream);
- d->padChar = ch;
+ d->params.padChar = ch;
}
/*!
@@ -1443,7 +1332,7 @@ void QTextStream::setPadChar(QChar ch)
QChar QTextStream::padChar() const
{
Q_D(const QTextStream);
- return d->padChar;
+ return d->params.padChar;
}
/*!
@@ -1461,7 +1350,7 @@ QChar QTextStream::padChar() const
void QTextStream::setFieldWidth(int width)
{
Q_D(QTextStream);
- d->fieldWidth = width;
+ d->params.fieldWidth = width;
}
/*!
@@ -1472,7 +1361,7 @@ void QTextStream::setFieldWidth(int width)
int QTextStream::fieldWidth() const
{
Q_D(const QTextStream);
- return d->fieldWidth;
+ return d->params.fieldWidth;
}
/*!
@@ -1486,7 +1375,7 @@ int QTextStream::fieldWidth() const
void QTextStream::setNumberFlags(NumberFlags flags)
{
Q_D(QTextStream);
- d->numberFlags = flags;
+ d->params.numberFlags = flags;
}
/*!
@@ -1497,7 +1386,7 @@ void QTextStream::setNumberFlags(NumberFlags flags)
QTextStream::NumberFlags QTextStream::numberFlags() const
{
Q_D(const QTextStream);
- return d->numberFlags;
+ return d->params.numberFlags;
}
/*!
@@ -1513,7 +1402,7 @@ QTextStream::NumberFlags QTextStream::numberFlags() const
void QTextStream::setIntegerBase(int base)
{
Q_D(QTextStream);
- d->integerBase = base;
+ d->params.integerBase = base;
}
/*!
@@ -1525,7 +1414,7 @@ void QTextStream::setIntegerBase(int base)
int QTextStream::integerBase() const
{
Q_D(const QTextStream);
- return d->integerBase;
+ return d->params.integerBase;
}
/*!
@@ -1539,7 +1428,7 @@ int QTextStream::integerBase() const
void QTextStream::setRealNumberNotation(RealNumberNotation notation)
{
Q_D(QTextStream);
- d->realNumberNotation = notation;
+ d->params.realNumberNotation = notation;
}
/*!
@@ -1550,7 +1439,7 @@ void QTextStream::setRealNumberNotation(RealNumberNotation notation)
QTextStream::RealNumberNotation QTextStream::realNumberNotation() const
{
Q_D(const QTextStream);
- return d->realNumberNotation;
+ return d->params.realNumberNotation;
}
/*!
@@ -1567,10 +1456,10 @@ void QTextStream::setRealNumberPrecision(int precision)
Q_D(QTextStream);
if (precision < 0) {
qWarning("QTextStream::setRealNumberPrecision: Invalid precision (%d)", precision);
- d->realNumberPrecision = 6;
+ d->params.realNumberPrecision = 6;
return;
}
- d->realNumberPrecision = precision;
+ d->params.realNumberPrecision = precision;
}
/*!
@@ -1582,7 +1471,7 @@ void QTextStream::setRealNumberPrecision(int precision)
int QTextStream::realNumberPrecision() const
{
Q_D(const QTextStream);
- return d->realNumberPrecision;
+ return d->params.realNumberPrecision;
}
/*!
@@ -1722,7 +1611,7 @@ QTextStreamPrivate::NumberParsingStatus QTextStreamPrivate::getNumber(qulonglong
consumeLastToken();
// detect int encoding
- int base = integerBase;
+ int base = params.integerBase;
if (base == 0) {
QChar ch;
if (!getChar(&ch))
@@ -2300,6 +2189,7 @@ void QTextStreamPrivate::putNumber(qulonglong number, bool negative)
QString result;
unsigned flags = 0;
+ const QTextStream::NumberFlags numberFlags = params.numberFlags;
if (numberFlags & QTextStream::ShowBase)
flags |= QLocalePrivate::ShowBase;
if (numberFlags & QTextStream::ForceSign)
@@ -2315,7 +2205,7 @@ void QTextStreamPrivate::putNumber(qulonglong number, bool negative)
flags |= QLocalePrivate::ThousandsGroup;
const QLocalePrivate *dd = locale.d;
- int base = integerBase ? integerBase : 10;
+ int base = params.integerBase ? params.integerBase : 10;
if (negative && base == 10) {
result = dd->longLongToString(-static_cast<qlonglong>(number), -1,
base, -1, flags);
@@ -2330,7 +2220,7 @@ void QTextStreamPrivate::putNumber(qulonglong number, bool negative)
result = dd->unsLongLongToString(number, -1, base, -1, flags);
// workaround for backward compatibility - in octal form with
// ShowBase flag set zero should be written as '00'
- if (number == 0 && base == 8 && numberFlags & QTextStream::ShowBase
+ if (number == 0 && base == 8 && params.numberFlags & QTextStream::ShowBase
&& result == QLatin1String("0")) {
result.prepend(QLatin1Char('0'));
}
@@ -2524,7 +2414,7 @@ QTextStream &QTextStream::operator<<(double f)
flags |= QLocalePrivate::Alternate;
const QLocalePrivate *dd = d->locale.d;
- QString num = dd->doubleToString(f, d->realNumberPrecision, form, -1, flags);
+ QString num = dd->doubleToString(f, d->params.realNumberPrecision, form, -1, flags);
d->putString(num, true);
return *this;
}
@@ -2605,13 +2495,13 @@ QTextStream &QTextStream::operator<<(const void *ptr)
{
Q_D(QTextStream);
CHECK_VALID_STREAM(*this);
- int oldBase = d->integerBase;
- NumberFlags oldFlags = d->numberFlags;
- d->integerBase = 16;
- d->numberFlags |= ShowBase;
+ const int oldBase = d->params.integerBase;
+ const NumberFlags oldFlags = d->params.numberFlags;
+ d->params.integerBase = 16;
+ d->params.numberFlags |= ShowBase;
d->putNumber(reinterpret_cast<quintptr>(ptr), false);
- d->integerBase = oldBase;
- d->numberFlags = oldFlags;
+ d->params.integerBase = oldBase;
+ d->params.numberFlags = oldFlags;
return *this;
}
@@ -3130,7 +3020,3 @@ QLocale QTextStream::locale() const
QT_END_NAMESPACE
-#ifndef QT_NO_QOBJECT
-#include "qtextstream.moc"
-#endif
-
diff --git a/src/corelib/io/qtextstream.h b/src/corelib/io/qtextstream.h
index 3c25e0587a..6d143bdca7 100644
--- a/src/corelib/io/qtextstream.h
+++ b/src/corelib/io/qtextstream.h
@@ -54,8 +54,6 @@
#error qtextstream.h must be included before any header file that defines Status
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -194,6 +192,7 @@ public:
private:
Q_DISABLE_COPY(QTextStream)
+ friend class QDebugStateSaverPrivate;
QScopedPointer<QTextStreamPrivate> d_ptr;
};
@@ -284,6 +283,4 @@ inline QTextStreamManipulator qSetRealNumberPrecision(int precision)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEXTSTREAM_H
diff --git a/src/corelib/io/qtextstream_p.h b/src/corelib/io/qtextstream_p.h
new file mode 100644
index 0000000000..d5d5288426
--- /dev/null
+++ b/src/corelib/io/qtextstream_p.h
@@ -0,0 +1,185 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QTEXTSTREAM_P_H
+#define QTEXTSTREAM_P_H
+
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists purely as an
+// implementation detail. This header file may change from version to
+// version without notice, or even be removed.
+//
+// We mean it.
+//
+
+#include "qtextstream.h"
+#ifndef QT_NO_TEXTCODEC
+#include "qtextcodec.h"
+#endif
+
+QT_BEGIN_NAMESPACE
+
+#ifndef QT_NO_QOBJECT
+class QDeviceClosedNotifier : public QObject
+{
+ Q_OBJECT
+public:
+ inline QDeviceClosedNotifier()
+ { }
+
+ inline void setupDevice(QTextStream *stream, QIODevice *device)
+ {
+ disconnect();
+ if (device)
+ connect(device, SIGNAL(aboutToClose()), this, SLOT(flushStream()));
+ this->stream = stream;
+ }
+
+public Q_SLOTS:
+ inline void flushStream() { stream->flush(); }
+
+private:
+ QTextStream *stream;
+};
+#endif
+
+class QTextStreamPrivate
+{
+ Q_DECLARE_PUBLIC(QTextStream)
+public:
+ QTextStreamPrivate(QTextStream *q_ptr);
+ ~QTextStreamPrivate();
+ void reset();
+
+ // device
+ QIODevice *device;
+#ifndef QT_NO_QOBJECT
+ QDeviceClosedNotifier deviceClosedNotifier;
+#endif
+ bool deleteDevice;
+
+ // string
+ QString *string;
+ int stringOffset;
+ QIODevice::OpenMode stringOpenMode;
+
+#ifndef QT_NO_TEXTCODEC
+ // codec
+ QTextCodec *codec;
+ QTextCodec::ConverterState readConverterState;
+ QTextCodec::ConverterState writeConverterState;
+ QTextCodec::ConverterState *readConverterSavedState;
+ bool autoDetectUnicode;
+#endif
+
+ // i/o
+ enum TokenDelimiter {
+ Space,
+ NotSpace,
+ EndOfLine
+ };
+
+ QString read(int maxlen);
+ bool scan(const QChar **ptr, int *tokenLength,
+ int maxlen, TokenDelimiter delimiter);
+ inline const QChar *readPtr() const;
+ inline void consumeLastToken();
+ inline void consume(int nchars);
+ void saveConverterState(qint64 newPos);
+ void restoreToSavedConverterState();
+ int lastTokenSize;
+
+ // Return value type for getNumber()
+ enum NumberParsingStatus {
+ npsOk,
+ npsMissingDigit,
+ npsInvalidPrefix
+ };
+
+ inline bool getChar(QChar *ch);
+ inline void ungetChar(QChar ch);
+ NumberParsingStatus getNumber(qulonglong *l);
+ bool getReal(double *f);
+
+ inline void write(const QString &data);
+ inline void putString(const QString &ch, bool number = false);
+ void putNumber(qulonglong number, bool negative);
+
+ // buffers
+ bool fillReadBuffer(qint64 maxBytes = -1);
+ void resetReadBuffer();
+ void flushWriteBuffer();
+ QString writeBuffer;
+ QString readBuffer;
+ int readBufferOffset;
+ int readConverterSavedStateOffset; //the offset between readBufferStartDevicePos and that start of the buffer
+ qint64 readBufferStartDevicePos;
+
+ // streaming parameters
+ class Params
+ {
+ public:
+ void reset();
+
+ int realNumberPrecision;
+ int integerBase;
+ int fieldWidth;
+ QChar padChar;
+ QTextStream::FieldAlignment fieldAlignment;
+ QTextStream::RealNumberNotation realNumberNotation;
+ QTextStream::NumberFlags numberFlags;
+ };
+ Params params;
+
+ // status
+ QTextStream::Status status;
+
+ QLocale locale;
+
+ QTextStream *q_ptr;
+};
+
+QT_END_NAMESPACE
+
+#endif // QTEXTSTREAM_P_H
diff --git a/src/corelib/io/qtldurl.cpp b/src/corelib/io/qtldurl.cpp
index 436e6a4568..dd4301e9f1 100644
--- a/src/corelib/io/qtldurl.cpp
+++ b/src/corelib/io/qtldurl.cpp
@@ -51,12 +51,22 @@ QT_BEGIN_NAMESPACE
static bool containsTLDEntry(const QString &entry)
{
int index = qt_hash(entry) % tldCount;
- int currentDomainIndex = tldIndices[index];
- while (currentDomainIndex < tldIndices[index+1]) {
- QString currentEntry = QString::fromUtf8(tldData + currentDomainIndex);
+
+ // select the right chunk from the big table
+ short chunk = 0;
+ uint chunkIndex = tldIndices[index], offset = 0;
+ while (tldIndices[index] >= tldChunks[chunk] && chunk < tldChunkCount) {
+ chunkIndex -= tldChunks[chunk];
+ offset += tldChunks[chunk];
+ chunk++;
+ }
+
+ // check all the entries from the given index
+ while (chunkIndex < tldIndices[index+1] - offset) {
+ QString currentEntry = QString::fromUtf8(tldData[chunk] + chunkIndex);
if (currentEntry == entry)
return true;
- currentDomainIndex += qstrlen(tldData + currentDomainIndex) + 1; // +1 for the ending \0
+ chunkIndex += qstrlen(tldData[chunk] + chunkIndex) + 1; // +1 for the ending \0
}
return false;
}
diff --git a/src/corelib/io/qurl.cpp b/src/corelib/io/qurl.cpp
index 7ff23d931c..c71bb3afac 100644
--- a/src/corelib/io/qurl.cpp
+++ b/src/corelib/io/qurl.cpp
@@ -333,11 +333,6 @@ static inline QString ftpScheme()
return QStringLiteral("ftp");
}
-static inline QString httpScheme()
-{
- return QStringLiteral("http");
-}
-
static inline QString fileScheme()
{
return QStringLiteral("file");
@@ -660,7 +655,7 @@ static const ushort encodedFragmentActions[] = {
encode(']'), // 6
0
};
-static const ushort * const decodedFragmentInUrlActions = 0;
+//static const ushort * const decodedFragmentInUrlActions = 0;
static const ushort * const decodedFragmentInIsolationActions = 0;
// the query is handled specially: the decodedQueryXXX tables are run with
@@ -3765,6 +3760,37 @@ QString QUrl::errorString() const
}
/*!
+ \since 5.1
+
+ Converts a list of \a urls into a list of QStrings, using toString(\a options).
+*/
+QStringList QUrl::toStringList(const QList<QUrl> &urls, FormattingOptions options)
+{
+ QStringList lst;
+ lst.reserve(urls.size());
+ foreach (const QUrl &url, urls)
+ lst.append(url.toString(options));
+ return lst;
+
+}
+
+/*!
+ \since 5.1
+
+ Converts a list of strings representing \a urls into a list of urls, using QUrl(str, \a mode).
+ Note that this means all strings must be urls, not for instance local paths.
+*/
+QList<QUrl> QUrl::fromStringList(const QStringList &urls, ParsingMode mode)
+{
+ QList<QUrl> lst;
+ lst.reserve(urls.size());
+ foreach (const QString &str, urls) {
+ lst.append(QUrl(str, mode));
+ }
+ return lst;
+}
+
+/*!
\typedef QUrl::DataPtr
\internal
*/
diff --git a/src/corelib/io/qurl.h b/src/corelib/io/qurl.h
index bd35b44f17..de4ce754fb 100644
--- a/src/corelib/io/qurl.h
+++ b/src/corelib/io/qurl.h
@@ -50,8 +50,6 @@
#include <QtCore/qpair.h>
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -322,6 +320,9 @@ public:
static QString fromAce(const QByteArray &);
static QByteArray toAce(const QString &);
static QStringList idnWhitelist();
+ static QStringList toStringList(const QList<QUrl> &uris, FormattingOptions options = FormattingOptions(PrettyDecoded));
+ static QList<QUrl> fromStringList(const QStringList &uris, ParsingMode mode = TolerantMode);
+
static void setIdnWhitelist(const QStringList &);
friend Q_CORE_EXPORT uint qHash(const QUrl &url, uint seed = 0) Q_DECL_NOTHROW;
@@ -381,6 +382,4 @@ QT_END_NAMESPACE
# include <QtCore/qurlquery.h>
#endif
-QT_END_HEADER
-
#endif // QURL_H
diff --git a/src/corelib/io/qurlidna.cpp b/src/corelib/io/qurlidna.cpp
index e2cd481035..fac1703da8 100644
--- a/src/corelib/io/qurlidna.cpp
+++ b/src/corelib/io/qurlidna.cpp
@@ -2336,27 +2336,42 @@ Q_AUTOTEST_EXPORT QString qt_punycodeDecoder(const QString &pc)
}
static const char * const idn_whitelist[] = {
- "ac", "ar", "at",
+ "ac", "ar", "asia", "at",
"biz", "br",
- "cat", "ch", "cl", "cn",
+ "cat", "ch", "cl", "cn", "com",
"de", "dk",
"es",
"fi",
"gr",
"hu",
- "info", "io", "is",
+ "il", "info", "io", "is", "ir",
"jp",
"kr",
- "li", "lt",
+ "li", "lt", "lu", "lv",
"museum",
- "no",
+ "name", "net", "no", "nu", "nz",
"org",
+ "pl", "pr",
"se", "sh",
- "th", "tm", "tw",
+ "tel", "th", "tm", "tw",
+ "ua",
"vn",
+ "xn--fiqs8s", // China
+ "xn--fiqz9s", // China
+ "xn--fzc2c9e2c", // Sri Lanka
+ "xn--j6w193g", // Hong Kong
+ "xn--kprw13d", // Taiwan
+ "xn--kpry57d", // Taiwan
+ "xn--mgba3a4f16a", // Iran
+ "xn--mgba3a4fra", // Iran
"xn--mgbaam7a8h", // UAE
+ "xn--mgbayh7gpa", // Jordan
"xn--mgberp4a5d4ar", // Saudi Arabia
- "xn--wgbh1c" // Egypt
+ "xn--ogbpf8fl", // Syria
+ "xn--p1ai", // Russian Federation
+ "xn--wgbh1c", // Egypt
+ "xn--wgbl6a", // Qatar
+ "xn--xkc2al3hye2a" // Sri Lanka
};
static const size_t idn_whitelist_size = sizeof idn_whitelist / sizeof *idn_whitelist;
diff --git a/src/corelib/io/qurlquery.cpp b/src/corelib/io/qurlquery.cpp
index 23c0b948e8..547084840f 100644
--- a/src/corelib/io/qurlquery.cpp
+++ b/src/corelib/io/qurlquery.cpp
@@ -49,6 +49,7 @@ QT_BEGIN_NAMESPACE
/*!
\class QUrlQuery
\inmodule QtCore
+ \since 5.0
\brief The QUrlQuery class provides a way to manipulate a key-value pairs in
a URL's query.
diff --git a/src/corelib/io/qurlquery.h b/src/corelib/io/qurlquery.h
index 319fe3cf22..c515bf78c7 100644
--- a/src/corelib/io/qurlquery.h
+++ b/src/corelib/io/qurlquery.h
@@ -50,8 +50,6 @@
#include <QtCore/qstringlist.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QUrlQueryPrivate;
@@ -173,6 +171,4 @@ inline QList<QByteArray> QUrl::allEncodedQueryItemValues(const QByteArray &key)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QURLQUERY_H
diff --git a/src/corelib/io/qurltlds_p.h b/src/corelib/io/qurltlds_p.h
index f4f525ced7..dfc69f500b 100644
--- a/src/corelib/io/qurltlds_p.h
+++ b/src/corelib/io/qurltlds_p.h
@@ -59,6423 +59,9898 @@ QT_BEGIN_NAMESPACE
// for instructions see the program at
// util/corelib/qurl-generateTLDs
-static const quint16 tldCount = 3949;
-static const quint16 tldIndices[] = {
+static const quint16 tldCount = 6063;
+static const quint32 tldIndices[] = {
0,
-7,
-14,
-14,
-20,
-51,
-61,
-93,
-100,
-100,
-116,
-159,
-167,
-180,
-180,
-193,
-234,
-234,
-234,
-255,
-255,
-255,
-280,
-280,
+13,
+19,
+36,
+66,
+90,
+90,
+113,
+130,
+151,
+151,
+151,
+168,
+179,
+196,
+203,
+222,
+222,
+237,
+237,
+251,
+258,
287,
287,
-295,
-303,
-313,
-326,
-326,
-380,
-393,
-413,
-419,
-419,
-419,
-424,
-438,
-438,
-469,
-515,
-515,
-515,
-534,
-534,
-557,
-557,
-557,
-557,
-572,
-572,
-572,
-579,
-587,
-597,
-612,
-612,
-624,
-636,
-648,
-662,
-687,
-709,
-714,
-740,
-766,
-789,
-789,
-805,
-805,
-810,
-815,
-815,
-824,
-824,
-831,
-857,
-869,
-891,
-891,
-916,
-916,
-916,
-927,
-934,
-964,
-971,
+287,
+287,
+287,
+314,
+336,
+352,
+352,
+352,
+369,
+369,
+377,
+396,
+396,
+396,
+405,
+405,
+431,
+431,
+442,
+451,
+485,
+495,
+509,
+509,
+509,
+524,
+524,
+533,
+533,
+552,
+552,
+552,
+552,
+577,
+577,
+593,
+593,
+593,
+593,
+593,
+593,
+622,
+643,
+643,
+658,
+691,
+703,
+715,
+731,
+731,
+747,
+781,
+793,
+793,
+814,
+826,
+851,
+851,
+866,
+885,
+914,
+929,
+929,
+929,
+941,
+947,
+947,
987,
987,
987,
-1008,
-1008,
-1016,
-1016,
-1030,
-1030,
-1052,
-1075,
-1075,
-1082,
-1087,
-1115,
-1135,
-1135,
-1135,
-1172,
-1178,
-1178,
-1178,
-1202,
-1207,
-1220,
-1220,
-1266,
-1266,
-1266,
-1266,
-1272,
-1290,
-1316,
-1316,
-1332,
-1332,
-1339,
-1339,
-1352,
-1352,
-1389,
-1389,
-1408,
-1415,
-1437,
-1444,
-1489,
-1489,
-1502,
-1502,
-1512,
-1518,
-1539,
-1555,
-1562,
+1003,
+1061,
+1080,
+1080,
+1080,
+1104,
+1104,
+1138,
+1148,
+1148,
+1148,
+1148,
+1160,
+1179,
+1179,
+1208,
+1208,
+1225,
+1225,
+1273,
+1273,
+1291,
+1291,
+1304,
+1304,
+1304,
+1304,
+1318,
+1335,
+1335,
+1335,
+1349,
+1349,
+1364,
+1364,
+1364,
+1364,
+1402,
+1402,
+1402,
+1402,
+1430,
+1455,
+1506,
+1537,
+1537,
+1559,
+1573,
+1578,
+1578,
+1578,
+1578,
1584,
-1598,
-1607,
-1607,
-1607,
-1632,
-1652,
-1652,
-1658,
-1658,
-1675,
+1592,
+1599,
+1599,
+1599,
+1606,
+1641,
+1641,
+1663,
+1663,
+1663,
+1663,
+1663,
1682,
-1709,
-1733,
-1748,
-1776,
-1783,
-1783,
-1790,
-1797,
-1826,
-1850,
-1850,
-1856,
-1880,
-1887,
-1901,
-1921,
-1947,
-1961,
-1967,
-1967,
-1967,
-1972,
-1986,
-1986,
-1986,
-2009,
-2029,
-2029,
-2047,
-2061,
-2075,
-2075,
-2075,
-2075,
-2075,
-2075,
-2082,
-2082,
-2124,
-2124,
-2129,
-2162,
-2162,
-2162,
-2236,
-2256,
-2263,
-2276,
-2283,
-2313,
-2313,
-2347,
-2380,
-2387,
-2387,
-2387,
-2431,
-2438,
-2445,
-2452,
-2459,
-2459,
-2469,
-2490,
-2516,
-2527,
-2540,
-2540,
-2586,
-2610,
-2630,
-2630,
-2653,
-2660,
-2669,
-2693,
-2693,
-2710,
-2710,
-2719,
-2719,
-2734,
-2740,
-2740,
-2753,
-2753,
-2763,
-2770,
-2775,
-2782,
-2789,
-2802,
-2820,
-2827,
-2827,
-2841,
-2855,
-2855,
-2865,
-2872,
-2884,
-2884,
-2919,
-2937,
-2955,
-2962,
-3012,
-3042,
-3073,
-3083,
-3083,
-3100,
-3105,
-3112,
-3131,
-3131,
-3166,
-3180,
-3187,
-3194,
-3211,
-3218,
-3223,
-3233,
-3249,
-3259,
-3268,
-3314,
-3314,
-3324,
-3324,
-3336,
-3336,
-3336,
+1682,
+1689,
+1689,
+1689,
+1715,
+1731,
+1731,
+1741,
+1761,
+1777,
+1777,
+1777,
+1777,
+1777,
+1796,
+1796,
+1824,
+1847,
+1847,
+1854,
+1876,
+1876,
+1876,
+1908,
+1908,
+1925,
+1952,
+1974,
+1991,
+2010,
+2010,
+2010,
+2010,
+2028,
+2048,
+2066,
+2066,
+2091,
+2119,
+2151,
+2151,
+2151,
+2175,
+2175,
+2175,
+2205,
+2219,
+2232,
+2281,
+2281,
+2281,
+2302,
+2311,
+2327,
+2327,
+2327,
+2340,
+2340,
+2340,
+2368,
+2386,
+2404,
+2414,
+2423,
+2423,
+2423,
+2423,
+2443,
+2443,
+2450,
+2487,
+2487,
+2487,
+2487,
+2494,
+2509,
+2509,
+2509,
+2535,
+2545,
+2615,
+2615,
+2615,
+2633,
+2633,
+2641,
+2688,
+2688,
+2688,
+2702,
+2708,
+2730,
+2748,
+2748,
+2748,
+2748,
+2764,
+2798,
+2807,
+2815,
+2826,
+2826,
+2835,
+2864,
+2864,
+2898,
+2898,
+2905,
+2915,
+2922,
+2922,
+2938,
+2938,
+2967,
+2967,
+2967,
+2986,
+2986,
+3002,
+3008,
+3018,
+3052,
+3066,
+3099,
+3099,
+3115,
+3115,
+3115,
+3159,
+3159,
+3172,
+3186,
+3186,
+3262,
+3262,
+3262,
+3305,
3336,
3350,
-3363,
-3376,
-3398,
-3416,
-3445,
-3464,
-3488,
-3488,
-3497,
-3545,
-3552,
-3552,
-3552,
-3566,
-3573,
-3573,
-3573,
-3581,
-3581,
-3603,
-3603,
-3615,
-3621,
-3621,
-3683,
-3683,
-3710,
-3710,
-3716,
-3716,
-3748,
-3770,
-3791,
-3803,
-3810,
-3817,
-3833,
-3846,
-3846,
-3852,
-3876,
-3876,
-3882,
-3903,
-3910,
-3939,
-3939,
-3939,
-3947,
-3962,
-3962,
-3981,
-3994,
-4021,
-4030,
-4042,
-4085,
-4085,
-4096,
-4096,
-4104,
-4123,
-4123,
-4123,
-4143,
-4154,
-4164,
-4194,
-4194,
-4194,
-4205,
-4205,
-4222,
-4238,
-4301,
-4309,
-4322,
-4331,
-4331,
-4331,
-4331,
-4331,
-4347,
-4365,
-4375,
-4375,
-4385,
-4398,
-4412,
-4430,
-4430,
-4437,
-4447,
-4463,
-4472,
-4472,
-4472,
-4484,
-4484,
-4484,
-4484,
-4484,
-4490,
-4490,
-4511,
-4511,
-4522,
-4522,
-4522,
-4522,
-4528,
-4528,
+3394,
+3411,
+3411,
+3424,
+3483,
+3505,
+3532,
+3532,
+3532,
+3538,
+3538,
+3561,
+3575,
+3580,
+3601,
+3601,
+3601,
+3601,
+3601,
+3601,
+3601,
+3601,
+3635,
+3635,
+3635,
+3686,
+3704,
+3704,
+3736,
+3749,
+3783,
+3783,
+3816,
+3840,
+3877,
+3885,
+3885,
+3885,
+3885,
+3907,
+3944,
+3944,
+3956,
+3963,
+3963,
+3963,
+3963,
+3975,
+3975,
+3975,
+3993,
+4038,
+4062,
+4062,
+4062,
+4071,
+4071,
+4084,
+4097,
+4119,
+4119,
+4119,
+4135,
+4135,
+4166,
+4178,
+4178,
+4208,
+4225,
+4285,
+4300,
+4300,
+4300,
+4300,
+4318,
+4318,
+4318,
+4336,
+4348,
+4354,
+4354,
+4388,
+4388,
+4416,
+4433,
+4433,
+4433,
+4433,
+4433,
+4433,
+4450,
+4450,
+4450,
+4450,
+4467,
+4467,
+4480,
+4514,
+4524,
4534,
-4551,
-4551,
-4551,
-4564,
-4583,
-4583,
-4611,
-4611,
-4611,
-4622,
-4622,
-4649,
-4668,
-4677,
-4692,
-4692,
-4692,
-4705,
-4723,
-4723,
-4723,
-4729,
-4729,
-4743,
-4743,
-4750,
-4750,
-4763,
-4770,
-4776,
-4776,
-4776,
-4793,
-4811,
-4811,
-4811,
-4821,
-4821,
-4841,
-4857,
-4891,
-4897,
-4903,
-4903,
-4903,
-4919,
-4935,
-4942,
-4958,
-4958,
-4975,
-4975,
-4975,
-4985,
-4985,
-5020,
-5032,
+4552,
+4552,
+4572,
+4572,
+4599,
+4641,
+4659,
+4659,
+4659,
+4666,
+4666,
+4666,
+4717,
+4769,
+4785,
+4797,
+4797,
+4815,
+4853,
+4859,
+4868,
+4894,
+4894,
+4894,
+4920,
+4930,
+4972,
+4972,
+5005,
+5005,
+5023,
+5023,
5032,
-5040,
-5053,
-5068,
-5079,
-5079,
-5101,
-5115,
-5115,
-5135,
-5154,
-5161,
-5161,
-5168,
-5168,
-5184,
-5210,
-5210,
-5238,
-5255,
-5278,
-5285,
-5308,
-5318,
-5327,
-5327,
-5333,
-5333,
-5340,
-5348,
-5355,
-5366,
-5377,
-5384,
-5408,
-5415,
-5422,
-5435,
-5442,
-5482,
-5482,
-5482,
-5482,
-5498,
-5527,
-5534,
-5541,
-5572,
-5572,
-5572,
-5579,
-5591,
-5602,
-5602,
-5621,
-5621,
-5646,
-5664,
-5671,
-5671,
-5681,
-5696,
-5707,
-5716,
-5716,
-5723,
-5723,
-5732,
+5059,
+5059,
+5080,
+5094,
+5100,
+5100,
+5100,
+5100,
+5100,
+5118,
+5145,
+5145,
+5145,
+5153,
+5221,
+5256,
+5289,
+5296,
+5306,
+5306,
+5343,
+5343,
+5343,
+5362,
+5369,
+5433,
+5451,
+5451,
+5451,
+5470,
+5470,
+5470,
+5490,
+5506,
+5528,
+5548,
+5548,
+5548,
+5548,
+5563,
+5576,
+5585,
+5636,
+5636,
+5661,
+5661,
+5668,
+5685,
+5698,
+5715,
5742,
-5742,
-5763,
-5770,
-5776,
-5790,
-5790,
-5797,
-5806,
-5816,
-5832,
-5882,
-5882,
-5882,
-5882,
-5893,
-5934,
-5934,
-5965,
-5965,
-5980,
-5980,
-5980,
-5980,
-6007,
-6017,
-6034,
-6051,
-6065,
-6075,
-6075,
-6091,
-6097,
-6097,
-6109,
-6109,
-6109,
-6122,
-6147,
-6168,
-6168,
-6191,
-6191,
-6191,
-6191,
-6191,
-6198,
-6217,
-6224,
-6224,
-6231,
-6245,
-6252,
-6252,
-6270,
-6270,
-6284,
-6305,
-6315,
-6322,
-6322,
-6322,
-6329,
-6329,
-6329,
-6353,
-6361,
-6361,
-6375,
-6391,
-6405,
-6405,
-6415,
-6431,
-6431,
-6431,
-6431,
-6458,
-6475,
-6475,
-6475,
-6482,
-6489,
-6496,
-6496,
-6503,
-6520,
-6520,
-6520,
-6527,
-6527,
+5748,
+5756,
+5800,
+5800,
+5800,
+5827,
+5827,
+5846,
+5864,
+5910,
+5926,
+5941,
+5952,
+5952,
+5958,
+5958,
+5976,
+5985,
+5991,
+5991,
+5991,
+5998,
+5998,
+5998,
+6011,
+6011,
+6060,
+6076,
+6088,
+6105,
+6124,
+6124,
+6124,
+6157,
+6157,
+6157,
+6157,
+6174,
+6190,
+6190,
+6190,
+6209,
+6228,
+6228,
+6228,
+6228,
+6234,
+6234,
+6234,
+6234,
+6234,
+6249,
+6264,
+6264,
+6290,
+6308,
+6346,
+6362,
+6362,
+6400,
+6420,
+6432,
+6455,
+6455,
+6464,
+6491,
+6491,
+6491,
+6497,
+6524,
+6544,
+6544,
+6544,
6544,
-6561,
-6573,
-6573,
-6580,
-6580,
-6587,
-6587,
-6592,
-6592,
-6592,
-6592,
-6599,
-6599,
-6612,
-6633,
-6649,
-6649,
-6669,
-6676,
-6683,
-6683,
-6713,
-6720,
-6727,
-6736,
-6736,
-6746,
-6770,
-6807,
-6814,
-6827,
-6846,
-6846,
-6864,
-6864,
-6864,
-6864,
-6881,
-6888,
-6888,
-6888,
+6559,
+6576,
+6619,
+6682,
+6682,
+6716,
+6716,
+6716,
+6716,
+6716,
+6716,
+6730,
+6745,
+6783,
+6783,
+6801,
+6817,
+6841,
+6841,
+6858,
+6858,
6914,
-6935,
-6935,
-6935,
-6953,
-6959,
-6966,
-6983,
-6983,
-6983,
-7013,
-7023,
-7023,
-7023,
-7023,
+6925,
+6943,
+6954,
+6954,
+6954,
+6973,
+6973,
+6973,
+6987,
+6987,
+6987,
+7005,
7037,
-7044,
-7058,
-7079,
-7086,
-7123,
-7134,
-7155,
-7168,
+7037,
+7050,
+7050,
+7075,
+7090,
+7090,
+7096,
+7108,
+7124,
+7124,
+7136,
+7136,
+7146,
+7169,
7178,
-7203,
-7227,
-7236,
-7258,
-7265,
-7274,
-7274,
-7303,
-7303,
-7314,
-7314,
-7345,
-7352,
-7367,
-7377,
-7388,
-7388,
-7402,
-7402,
-7409,
-7421,
-7421,
-7467,
-7484,
-7484,
-7484,
+7197,
+7197,
+7197,
+7204,
+7204,
+7268,
+7268,
+7288,
+7311,
+7311,
+7321,
+7334,
+7334,
+7387,
+7417,
+7426,
+7444,
+7444,
+7460,
+7470,
7491,
-7532,
-7532,
-7539,
-7546,
-7546,
-7553,
-7573,
-7573,
-7573,
-7580,
-7587,
-7594,
-7594,
-7594,
-7606,
-7606,
-7637,
-7637,
-7637,
-7664,
-7664,
-7664,
-7677,
-7684,
-7701,
-7723,
-7723,
-7723,
-7723,
-7734,
-7734,
-7734,
-7748,
-7748,
-7748,
-7748,
-7759,
-7759,
-7775,
-7775,
-7782,
-7789,
-7817,
-7824,
-7831,
-7836,
-7865,
-7865,
+7516,
+7516,
+7535,
+7535,
+7555,
+7555,
+7555,
+7555,
+7575,
+7597,
+7597,
+7597,
+7597,
+7607,
+7627,
+7627,
+7652,
+7710,
+7710,
+7719,
+7737,
+7737,
+7737,
+7737,
+7737,
+7747,
+7747,
+7753,
+7773,
+7773,
+7793,
+7828,
+7841,
+7860,
+7860,
+7876,
7876,
7901,
7901,
-7908,
-7918,
-7938,
-7945,
-7945,
-7957,
-7964,
-7979,
-7986,
-7994,
-8007,
-8007,
-8014,
-8021,
-8061,
-8061,
-8071,
-8088,
-8131,
-8138,
-8153,
-8160,
-8160,
-8160,
-8175,
-8183,
+7901,
+7911,
+7911,
+7911,
+7911,
+7924,
+7941,
+7951,
+7983,
+7983,
+7990,
+8008,
+8008,
+8018,
+8018,
+8031,
+8056,
+8063,
+8077,
+8077,
+8090,
+8100,
+8165,
+8192,
+8192,
+8192,
+8192,
+8197,
8197,
-8211,
-8211,
-8211,
-8243,
-8243,
-8243,
-8243,
-8259,
-8259,
-8259,
-8259,
-8259,
-8266,
-8275,
-8281,
-8281,
-8281,
-8281,
-8288,
-8288,
+8197,
+8197,
+8197,
+8197,
+8227,
+8237,
+8253,
+8253,
8309,
8309,
8309,
-8330,
-8330,
-8330,
-8330,
-8337,
-8343,
-8343,
-8360,
-8370,
-8370,
-8380,
-8380,
-8386,
-8386,
-8397,
-8415,
-8415,
-8428,
-8454,
-8460,
-8475,
-8492,
-8526,
+8309,
+8329,
+8329,
+8329,
+8345,
+8378,
+8398,
+8420,
+8420,
+8420,
+8436,
+8452,
+8497,
+8538,
8554,
8554,
8583,
8583,
8583,
-8598,
-8607,
-8617,
-8617,
+8616,
8642,
8652,
8652,
-8652,
-8662,
-8688,
-8688,
-8704,
-8704,
-8747,
-8765,
-8775,
-8783,
-8811,
-8835,
-8835,
-8835,
-8850,
-8859,
-8884,
-8910,
-8919,
-8952,
-8978,
-8978,
-8991,
-8991,
-8991,
-8999,
-8999,
-8999,
-9030,
-9030,
-9030,
-9030,
-9030,
-9041,
-9048,
-9048,
-9054,
-9054,
-9054,
-9086,
-9108,
-9108,
-9119,
-9119,
-9130,
-9144,
-9152,
-9161,
-9174,
-9194,
-9207,
-9207,
-9207,
-9232,
-9242,
-9242,
-9271,
-9290,
-9308,
-9308,
-9308,
-9308,
-9320,
-9333,
-9343,
-9356,
-9379,
-9379,
+8672,
+8690,
+8699,
+8699,
+8715,
+8715,
+8737,
+8767,
+8767,
+8767,
+8780,
+8800,
+8837,
+8867,
+8896,
+8931,
+8948,
+8959,
+8981,
+9002,
+9008,
+9017,
+9017,
+9017,
+9017,
+9044,
+9044,
+9044,
+9069,
+9087,
+9087,
+9087,
+9087,
+9104,
+9136,
+9173,
+9173,
+9199,
+9199,
+9199,
+9199,
+9222,
+9233,
+9257,
+9257,
+9257,
+9272,
+9272,
+9284,
+9316,
+9346,
+9346,
+9346,
+9362,
9379,
-9395,
-9395,
-9406,
-9419,
-9419,
-9419,
-9419,
-9450,
-9485,
-9485,
-9497,
-9497,
-9505,
-9517,
-9528,
-9528,
+9404,
+9413,
+9413,
+9413,
+9439,
+9439,
+9447,
+9460,
+9479,
+9479,
+9486,
+9499,
+9506,
+9506,
+9513,
9551,
-9564,
-9586,
-9586,
-9608,
-9608,
-9626,
-9626,
-9626,
-9653,
-9653,
-9681,
-9681,
-9681,
-9698,
-9698,
-9698,
-9714,
-9729,
-9737,
-9737,
-9765,
-9765,
-9765,
-9765,
-9765,
-9825,
-9844,
-9866,
-9880,
-9880,
-9880,
-9880,
-9886,
-9895,
-9895,
-9895,
-9895,
-9895,
-9913,
-9913,
-9924,
-9958,
-9958,
-9967,
-9975,
-9975,
-9975,
-9981,
-9998,
-9998,
-9998,
+9551,
+9577,
+9577,
+9634,
+9634,
+9671,
+9693,
+9700,
+9700,
+9732,
+9774,
+9774,
+9780,
+9827,
+9851,
+9875,
+9875,
+9911,
+9937,
+9937,
+9944,
+9944,
+9944,
+9964,
+9992,
+9999,
+9999,
+9999,
+10006,
10012,
-10036,
-10036,
-10066,
-10079,
-10097,
+10019,
+10026,
+10047,
+10059,
+10059,
+10076,
+10083,
+10083,
+10083,
+10089,
+10089,
+10089,
+10096,
10121,
-10133,
-10142,
-10142,
-10142,
-10156,
-10173,
-10173,
-10173,
-10196,
-10205,
-10205,
-10205,
-10205,
-10218,
-10234,
-10240,
-10240,
-10240,
-10264,
-10273,
-10286,
-10286,
-10286,
-10286,
-10299,
-10299,
-10309,
-10309,
-10339,
-10358,
-10358,
-10374,
-10374,
-10390,
-10390,
-10413,
-10413,
-10439,
-10461,
-10467,
+10121,
+10137,
+10137,
+10137,
+10137,
+10154,
+10161,
+10161,
+10168,
+10177,
+10177,
+10231,
+10238,
+10261,
+10268,
+10288,
+10295,
+10303,
+10320,
+10344,
+10387,
+10421,
+10421,
+10421,
10467,
10467,
-10492,
-10492,
10501,
-10528,
-10528,
-10528,
-10539,
-10583,
-10583,
-10583,
-10613,
-10613,
-10619,
-10628,
-10645,
-10645,
-10645,
-10650,
-10671,
-10687,
-10709,
-10709,
-10709,
-10709,
-10709,
-10727,
+10517,
+10535,
+10552,
+10577,
+10577,
+10577,
+10577,
+10577,
+10615,
+10621,
+10639,
+10639,
+10639,
+10682,
+10682,
+10698,
+10698,
+10716,
10727,
-10727,
-10727,
-10733,
-10733,
-10768,
-10768,
-10773,
-10780,
-10788,
-10788,
+10750,
+10774,
+10781,
10797,
-10797,
-10835,
-10835,
-10845,
-10852,
-10861,
-10861,
-10861,
-10861,
-10861,
-10861,
-10861,
-10875,
-10888,
-10907,
-10907,
-10907,
-10920,
-10920,
-10932,
-10946,
-10977,
-10977,
-10997,
-11008,
-11037,
-11059,
-11059,
-11059,
-11067,
-11067,
-11067,
-11067,
-11067,
-11077,
-11091,
-11102,
+10804,
+10804,
+10804,
+10816,
+10836,
+10850,
+10850,
+10857,
+10857,
+10878,
+10878,
+10934,
+10934,
+10934,
+10934,
+10934,
+10934,
+10934,
+10941,
+10941,
+10941,
+10948,
+10973,
+10984,
+11015,
+11015,
+11015,
+11041,
+11058,
+11066,
+11066,
+11066,
+11087,
+11097,
11102,
-11112,
-11125,
+11108,
+11115,
+11122,
+11122,
+11122,
11129,
-11129,
-11154,
-11154,
-11154,
-11164,
-11164,
-11189,
-11189,
-11189,
-11189,
-11189,
-11196,
-11196,
-11227,
-11238,
-11247,
-11256,
-11265,
-11265,
-11286,
+11160,
+11194,
+11194,
+11215,
+11224,
+11224,
+11280,
+11297,
11307,
-11330,
-11337,
-11378,
-11378,
-11389,
-11413,
-11454,
-11469,
-11475,
-11475,
-11475,
-11475,
-11503,
-11503,
-11503,
-11503,
-11534,
-11534,
-11550,
-11550,
-11557,
-11557,
-11557,
-11557,
-11574,
-11585,
-11585,
-11603,
-11626,
-11643,
-11643,
-11643,
-11643,
-11663,
-11663,
-11682,
-11696,
-11696,
-11696,
-11696,
-11706,
-11706,
-11706,
-11706,
-11723,
-11723,
-11757,
-11757,
-11773,
-11795,
-11813,
-11836,
-11836,
-11883,
-11903,
-11952,
-11965,
-11965,
-11984,
-11997,
-12008,
-12008,
-12008,
-12024,
-12043,
-12065,
-12071,
-12099,
-12129,
-12140,
-12140,
-12146,
-12161,
-12161,
-12161,
-12161,
-12167,
-12167,
-12180,
-12186,
-12208,
-12226,
-12243,
-12243,
-12252,
-12252,
-12274,
-12289,
-12302,
-12302,
-12313,
-12313,
-12313,
-12313,
-12358,
-12358,
-12358,
-12369,
-12375,
-12391,
-12391,
-12391,
-12391,
-12405,
-12410,
-12416,
-12416,
-12436,
-12436,
-12436,
-12443,
-12443,
-12462,
-12477,
-12492,
-12492,
-12503,
-12519,
-12525,
-12531,
-12571,
-12571,
-12591,
-12591,
-12601,
-12641,
-12641,
-12641,
-12657,
-12657,
-12657,
-12699,
-12699,
-12699,
-12712,
-12728,
-12744,
-12761,
-12769,
-12782,
-12793,
-12823,
-12836,
-12851,
-12863,
-12890,
-12900,
-12900,
-12900,
-12910,
-12910,
-12924,
-12924,
-12924,
-12924,
-12924,
-12952,
-12984,
-13003,
-13038,
-13038,
-13056,
-13056,
-13056,
+11319,
+11352,
+11364,
+11364,
+11399,
+11399,
+11430,
+11430,
+11445,
+11478,
+11500,
+11508,
+11526,
+11526,
+11539,
+11539,
+11583,
+11583,
+11624,
+11654,
+11654,
+11661,
+11679,
+11714,
+11721,
+11733,
+11769,
+11778,
+11786,
+11805,
+11820,
+11857,
+11864,
+11877,
+11877,
+11892,
+11892,
+11892,
+11908,
+11915,
+11922,
+11940,
+11947,
+11975,
+11998,
+12021,
+12028,
+12028,
+12046,
+12068,
+12086,
+12109,
+12116,
+12130,
+12150,
+12150,
+12150,
+12150,
+12157,
+12182,
+12205,
+12212,
+12219,
+12219,
+12229,
+12229,
+12229,
+12250,
+12271,
+12285,
+12285,
+12292,
+12330,
+12330,
+12349,
+12349,
+12357,
+12357,
+12357,
+12357,
+12389,
+12409,
+12409,
+12448,
+12459,
+12473,
+12480,
+12489,
+12489,
+12497,
+12535,
+12542,
+12568,
+12575,
+12590,
+12620,
+12645,
+12652,
+12665,
+12672,
+12683,
+12683,
+12709,
+12716,
+12723,
+12746,
+12746,
+12746,
+12771,
+12771,
+12796,
+12796,
+12803,
+12803,
+12803,
+12838,
+12856,
+12872,
+12872,
+12872,
+12872,
+12872,
+12872,
+12889,
+12899,
+12899,
+12899,
+12899,
+12917,
+12934,
+12934,
+12947,
+12969,
+12969,
+12976,
+13012,
13056,
-13074,
-13081,
-13093,
-13103,
-13103,
-13112,
-13119,
-13132,
-13132,
-13132,
-13141,
-13151,
-13183,
-13193,
-13206,
-13206,
-13206,
-13236,
-13252,
-13267,
-13267,
-13294,
-13307,
-13307,
-13307,
-13343,
-13349,
-13349,
-13349,
-13375,
-13375,
-13375,
-13384,
-13384,
-13384,
-13393,
-13393,
-13393,
-13402,
-13414,
-13425,
-13445,
-13467,
-13485,
-13499,
-13509,
-13528,
-13528,
-13549,
-13549,
-13559,
-13570,
-13570,
-13570,
-13570,
-13598,
-13637,
-13647,
-13647,
-13661,
-13673,
-13682,
-13687,
-13694,
-13694,
-13720,
-13733,
-13742,
-13748,
-13771,
-13795,
-13795,
-13814,
-13821,
-13821,
-13855,
-13862,
-13862,
-13862,
-13874,
-13874,
-13897,
-13909,
-13909,
-13947,
-13947,
-13952,
-13952,
-13970,
-13979,
-13979,
-13979,
-14008,
-14049,
-14049,
-14049,
-14049,
-14049,
-14049,
-14060,
-14083,
-14083,
-14091,
-14101,
-14101,
-14101,
-14101,
-14118,
-14136,
-14195,
-14195,
-14195,
-14213,
-14213,
-14232,
-14232,
-14253,
-14253,
+13063,
+13092,
+13118,
+13142,
+13163,
+13202,
+13237,
+13256,
+13284,
+13295,
+13302,
+13326,
+13355,
+13372,
+13383,
+13398,
+13424,
+13452,
+13452,
+13452,
+13494,
+13533,
+13547,
+13547,
+13551,
+13558,
+13610,
+13657,
+13665,
+13692,
+13692,
+13707,
+13714,
+13714,
+13714,
+13728,
+13728,
+13750,
+13763,
+13782,
+13782,
+13819,
+13840,
+13840,
+13858,
+13867,
+13888,
+13925,
+13925,
+13950,
+13960,
+13960,
+13974,
+14014,
+14051,
+14067,
+14086,
+14095,
+14102,
+14102,
+14102,
+14123,
+14123,
+14123,
+14144,
+14168,
+14168,
+14175,
+14175,
+14175,
+14175,
+14186,
+14237,
+14237,
14258,
-14275,
-14275,
-14304,
-14311,
-14311,
-14318,
-14318,
-14318,
-14318,
-14318,
-14318,
-14325,
-14325,
-14345,
-14345,
-14379,
-14389,
-14422,
-14422,
-14422,
-14422,
-14435,
-14441,
-14441,
-14460,
-14460,
-14471,
-14471,
-14481,
-14495,
-14495,
-14495,
-14502,
-14502,
-14502,
-14502,
-14524,
-14533,
-14541,
-14552,
-14552,
-14552,
-14552,
-14563,
-14563,
-14568,
-14568,
-14585,
-14595,
-14602,
-14628,
-14628,
-14645,
-14672,
-14678,
-14697,
-14697,
-14734,
-14757,
-14764,
-14771,
-14771,
-14771,
-14796,
-14815,
-14822,
-14845,
-14861,
-14861,
-14861,
-14873,
-14873,
-14873,
-14902,
-14920,
-14920,
-14926,
-14926,
-14926,
-14941,
-14949,
-14949,
-14949,
-14949,
-14949,
-14960,
-14960,
-14971,
-14971,
-14998,
-15003,
-15003,
-15003,
-15013,
-15013,
-15027,
-15027,
-15027,
-15043,
-15053,
-15063,
-15074,
-15083,
-15093,
-15093,
-15121,
-15121,
-15128,
-15128,
-15144,
-15144,
-15144,
-15144,
-15165,
-15170,
-15170,
-15170,
-15170,
-15170,
-15170,
-15170,
-15186,
-15206,
-15206,
-15206,
-15224,
-15236,
-15236,
-15252,
-15258,
-15258,
-15258,
-15258,
-15264,
-15277,
-15288,
-15307,
-15307,
-15318,
-15328,
-15328,
-15334,
-15334,
-15363,
-15399,
-15399,
-15422,
-15438,
-15447,
-15447,
-15456,
-15456,
-15456,
-15495,
-15495,
-15495,
-15495,
-15511,
-15511,
-15530,
-15557,
-15566,
-15582,
-15590,
-15590,
-15604,
-15604,
-15625,
-15635,
-15655,
-15655,
-15655,
-15655,
-15655,
-15665,
-15675,
-15675,
-15675,
-15675,
-15675,
-15682,
-15682,
-15682,
-15694,
-15719,
-15749,
-15749,
-15794,
-15794,
-15837,
-15854,
-15854,
-15861,
-15861,
-15861,
-15861,
-15884,
-15900,
-15911,
-15931,
-15931,
-15931,
-15931,
-15931,
-15963,
-15963,
-15996,
-16006,
-16013,
-16024,
+14258,
+14258,
+14292,
+14292,
+14328,
+14338,
+14338,
+14338,
+14364,
+14390,
+14390,
+14423,
+14454,
+14469,
+14512,
+14512,
+14512,
+14512,
+14512,
+14512,
+14512,
+14525,
+14535,
+14550,
+14572,
+14578,
+14591,
+14603,
+14603,
+14603,
+14619,
+14619,
+14619,
+14619,
+14656,
+14679,
+14700,
+14725,
+14725,
+14725,
+14725,
+14725,
+14730,
+14751,
+14767,
+14767,
+14767,
+14767,
+14787,
+14820,
+14837,
+14837,
+14865,
+14865,
+14882,
+14882,
+14882,
+14882,
+14882,
+14892,
+14892,
+14892,
+14912,
+14929,
+14947,
+14947,
+14947,
+14947,
+14947,
+14947,
+14966,
+15018,
+15034,
+15044,
+15055,
+15055,
+15073,
+15118,
+15118,
+15118,
+15146,
+15158,
+15169,
+15175,
+15175,
+15175,
+15181,
+15181,
+15181,
+15247,
+15279,
+15292,
+15292,
+15292,
+15292,
+15326,
+15331,
+15365,
+15389,
+15398,
+15412,
+15426,
+15433,
+15433,
+15433,
+15433,
+15469,
+15490,
+15490,
+15506,
+15523,
+15553,
+15553,
+15571,
+15571,
+15585,
+15602,
+15602,
+15602,
+15602,
+15602,
+15631,
+15658,
+15669,
+15699,
+15716,
+15716,
+15757,
+15789,
+15796,
+15796,
+15796,
+15796,
+15815,
+15840,
+15898,
+15898,
+15919,
+15933,
+15933,
+15940,
+15946,
+15946,
+15964,
+15964,
+15964,
+15973,
+15979,
+16008,
+16019,
+16019,
16034,
-16049,
-16049,
-16049,
-16059,
-16059,
-16059,
-16059,
-16059,
-16059,
-16059,
-16064,
-16075,
-16104,
-16104,
-16117,
-16124,
-16124,
-16124,
-16124,
-16130,
-16145,
-16159,
-16190,
-16193,
-16196,
-16210,
-16224,
-16243,
-16255,
-16261,
-16280,
-16283,
-16292,
-16295,
-16295,
-16301,
-16304,
+16042,
+16057,
+16073,
+16095,
+16095,
+16112,
+16121,
+16139,
+16139,
+16139,
+16148,
+16148,
+16148,
+16148,
+16165,
+16187,
+16187,
+16199,
+16199,
+16215,
+16215,
+16215,
+16231,
+16240,
+16284,
+16305,
+16305,
16322,
-16325,
-16328,
-16349,
-16355,
-16382,
-16408,
-16414,
-16414,
-16414,
-16458,
-16477,
-16480,
-16485,
-16488,
-16514,
-16520,
-16530,
-16530,
-16546,
-16562,
-16597,
-16603,
-16622,
-16622,
-16646,
-16669,
-16672,
-16715,
-16715,
-16715,
-16718,
-16718,
-16727,
-16733,
-16752,
-16770,
-16787,
-16794,
-16810,
-16827,
-16840,
-16850,
-16876,
-16901,
-16901,
-16901,
-16916,
-16919,
-16926,
-16943,
-16972,
-16978,
-16978,
-16978,
-16981,
-17008,
-17008,
-17016,
-17053,
-17053,
-17053,
-17053,
-17072,
-17086,
-17105,
-17139,
-17153,
-17162,
-17162,
-17177,
-17177,
-17177,
-17177,
-17195,
-17218,
-17221,
-17221,
-17237,
-17276,
-17276,
-17300,
-17319,
-17339,
-17357,
-17370,
-17383,
-17400,
-17407,
-17419,
-17439,
-17439,
-17449,
-17465,
-17475,
-17504,
-17527,
-17527,
-17534,
-17548,
-17564,
-17564,
-17598,
-17598,
-17601,
-17630,
-17649,
-17669,
-17669,
-17679,
-17686,
+16343,
+16362,
+16383,
+16393,
+16393,
+16411,
+16419,
+16425,
+16436,
+16461,
+16468,
+16468,
+16468,
+16490,
+16490,
+16490,
+16507,
+16528,
+16528,
+16528,
+16538,
+16555,
+16566,
+16566,
+16590,
+16590,
+16605,
+16623,
+16636,
+16636,
+16636,
+16656,
+16666,
+16696,
+16713,
+16743,
+16760,
+16781,
+16797,
+16811,
+16811,
+16823,
+16838,
+16859,
+16879,
+16879,
+16879,
+16902,
+16908,
+16908,
+16908,
+16908,
+16966,
+16966,
+16966,
+16975,
+16992,
+16992,
+16992,
+17033,
+17069,
+17069,
+17100,
+17117,
+17133,
+17151,
+17151,
+17159,
+17203,
+17203,
+17220,
+17226,
+17226,
+17245,
+17245,
+17259,
+17259,
+17269,
+17295,
+17295,
+17295,
+17353,
+17386,
+17394,
+17394,
+17394,
+17409,
+17409,
+17442,
+17442,
+17454,
+17509,
+17509,
+17509,
+17532,
+17532,
+17532,
+17550,
+17561,
+17561,
+17561,
+17561,
+17561,
+17561,
+17561,
+17561,
+17561,
+17575,
+17581,
+17581,
+17581,
+17620,
+17627,
+17640,
+17640,
+17677,
+17677,
+17688,
+17688,
+17722,
+17734,
+17747,
+17757,
+17757,
17757,
-17776,
-17796,
-17810,
-17840,
-17840,
-17877,
-17884,
-17884,
-17911,
-17936,
-17970,
+17803,
+17820,
+17846,
+17892,
+17892,
+17899,
+17899,
+17919,
+17919,
+17968,
17980,
-17995,
-17995,
-18008,
-18011,
-18036,
-18075,
-18097,
-18097,
-18104,
-18115,
-18115,
-18129,
-18134,
-18141,
-18141,
-18157,
-18180,
-18190,
-18217,
-18224,
-18252,
-18284,
-18284,
-18296,
-18299,
-18312,
-18322,
-18338,
-18348,
-18348,
-18363,
-18372,
-18387,
-18387,
-18390,
+17996,
+18021,
+18021,
+18021,
+18021,
+18050,
+18050,
+18072,
+18102,
+18119,
+18119,
+18132,
+18132,
+18132,
+18146,
+18146,
+18165,
+18184,
+18184,
+18192,
+18192,
+18192,
+18223,
+18223,
+18223,
+18231,
+18231,
+18231,
+18231,
+18257,
+18270,
+18300,
+18313,
+18331,
+18331,
+18331,
+18351,
+18351,
+18382,
+18392,
+18392,
+18392,
18402,
+18402,
+18418,
18445,
-18445,
-18445,
-18466,
-18479,
-18479,
-18498,
-18508,
-18511,
-18511,
-18511,
-18511,
-18511,
-18526,
-18558,
-18586,
-18622,
+18519,
+18519,
+18528,
+18542,
+18571,
+18595,
+18616,
+18628,
+18628,
18643,
-18670,
-18686,
-18710,
-18720,
-18739,
-18739,
-18742,
-18745,
-18771,
-18774,
-18777,
-18791,
-18813,
-18816,
-18822,
-18839,
-18845,
-18851,
-18854,
-18878,
-18881,
-18896,
-18896,
-18899,
-18926,
-18937,
-18940,
-18953,
-18963,
-19010,
-19010,
-19017,
-19046,
-19060,
-19060,
-19087,
-19095,
-19101,
-19101,
-19128,
-19146,
-19157,
-19157,
-19188,
+18678,
+18690,
+18715,
+18731,
+18731,
+18751,
+18763,
+18763,
+18763,
+18779,
+18793,
+18793,
+18824,
+18840,
+18840,
+18856,
+18856,
+18864,
+18864,
+18902,
+18902,
+18933,
+18946,
+18946,
+18946,
+18946,
+18946,
+18946,
+18955,
+18955,
+18973,
+18979,
+18992,
+18992,
+18992,
+19008,
+19016,
+19016,
+19033,
+19033,
+19044,
+19044,
+19044,
+19044,
+19082,
+19129,
+19149,
19198,
-19205,
-19223,
-19230,
-19255,
-19280,
-19280,
-19283,
-19292,
-19301,
-19320,
-19323,
-19323,
-19341,
-19341,
-19365,
-19378,
-19381,
-19394,
-19423,
-19433,
-19440,
+19210,
+19210,
+19210,
+19219,
+19219,
+19219,
+19227,
+19261,
+19261,
+19268,
+19291,
+19319,
+19319,
+19319,
+19331,
+19359,
+19369,
+19369,
+19384,
+19384,
+19406,
+19413,
19466,
-19490,
-19490,
-19490,
-19497,
-19504,
-19511,
-19511,
-19518,
-19545,
-19568,
-19575,
-19575,
-19583,
-19586,
-19592,
-19592,
-19609,
-19622,
-19629,
-19641,
-19641,
-19656,
-19673,
-19700,
-19723,
-19733,
-19746,
-19759,
-19769,
-19782,
-19789,
-19795,
-19831,
-19834,
-19841,
-19851,
-19854,
-19880,
-19895,
-19898,
-19898,
-19911,
-19922,
-19950,
-20020,
+19482,
+19482,
+19494,
+19515,
+19522,
+19570,
+19570,
+19570,
+19610,
+19625,
+19632,
+19639,
+19658,
+19665,
+19672,
+19672,
+19679,
+19679,
+19692,
+19719,
+19749,
+19756,
+19776,
+19807,
+19817,
+19817,
+19837,
+19844,
+19876,
+19906,
+19906,
+19923,
+19923,
+19942,
+19958,
+19973,
+19995,
+20002,
+20023,
20030,
-20059,
-20062,
-20089,
-20107,
-20151,
-20154,
-20175,
+20036,
+20036,
+20060,
+20060,
+20066,
+20073,
+20108,
+20116,
+20131,
+20131,
+20131,
+20166,
+20183,
+20202,
20205,
-20208,
-20229,
-20229,
-20255,
-20261,
-20261,
-20283,
-20335,
-20362,
-20385,
-20392,
-20392,
-20392,
-20392,
-20418,
-20418,
-20418,
+20215,
+20233,
+20233,
+20236,
+20243,
+20253,
+20281,
+20284,
+20294,
+20297,
+20315,
+20355,
+20400,
+20415,
20418,
+20428,
20443,
-20446,
-20446,
-20452,
-20452,
+20461,
20467,
-20467,
-20489,
-20489,
-20498,
-20525,
-20554,
-20560,
+20470,
+20476,
+20499,
+20499,
+20513,
+20513,
+20516,
+20523,
+20546,
+20549,
20575,
-20589,
-20589,
-20589,
-20614,
-20652,
-20659,
-20659,
-20668,
-20679,
-20679,
-20679,
-20685,
+20615,
+20615,
+20618,
+20682,
20685,
-20685,
-20685,
-20685,
-20685,
-20696,
-20733,
-20760,
-20766,
-20769,
-20792,
-20792,
-20792,
-20792,
-20813,
-20813,
-20813,
-20813,
-20826,
-20826,
-20846,
-20862,
-20880,
+20691,
+20700,
+20727,
+20776,
+20779,
+20800,
+20816,
+20858,
20887,
-20901,
-20908,
-20933,
-20938,
-20958,
-20969,
-20978,
-20978,
-20978,
-20985,
-20985,
-20985,
-21000,
-21010,
-21010,
-21014,
-21026,
-21033,
-21041,
-21041,
-21051,
-21051,
-21064,
-21071,
-21113,
-21120,
-21120,
-21127,
-21134,
-21142,
-21164,
-21164,
-21164,
-21188,
-21195,
-21208,
-21215,
-21226,
-21226,
-21226,
-21238,
-21249,
-21255,
-21255,
-21265,
-21279,
-21296,
-21301,
-21315,
-21321,
-21331,
-21331,
-21331,
-21337,
-21343,
-21343,
-21351,
-21351,
-21361,
-21368,
-21383,
-21383,
-21389,
-21413,
-21437,
-21449,
-21462,
-21478,
-21506,
-21534,
-21546,
-21546,
-21557,
-21580,
-21595,
-21595,
-21595,
-21595,
-21626,
-21626,
-21646,
-21670,
-21676,
-21688,
-21688,
-21716,
-21731,
-21762,
-21762,
-21762,
-21762,
-21762,
-21783,
-21789,
-21799,
-21828,
-21828,
+20898,
+20898,
+20898,
+20923,
+20926,
+20949,
+20952,
+20959,
+20965,
+20974,
+20980,
+20996,
+20996,
+21021,
+21039,
+21039,
+21052,
+21055,
+21076,
+21079,
+21091,
+21094,
+21114,
+21114,
+21117,
+21117,
+21124,
+21143,
+21196,
+21196,
+21196,
+21196,
+21196,
+21205,
+21212,
+21261,
+21278,
+21293,
+21333,
+21354,
+21366,
+21373,
+21408,
+21433,
+21439,
+21442,
+21442,
+21445,
+21448,
+21460,
+21463,
+21466,
+21476,
+21479,
+21529,
+21568,
+21574,
+21574,
+21577,
+21604,
+21611,
+21611,
+21631,
+21649,
+21689,
+21692,
+21714,
+21752,
+21752,
+21780,
+21787,
+21813,
21837,
-21845,
-21868,
-21874,
-21874,
-21880,
-21880,
-21889,
-21901,
-21910,
-21941,
-21941,
-21959,
-21959,
-21959,
-21966,
-21966,
-21972,
-21972,
-21995,
-22011,
+21840,
+21857,
+21885,
+21888,
+21888,
+21911,
+21918,
+21928,
+21928,
+21934,
+21970,
+21983,
+21992,
+22012,
+22019,
+22036,
22043,
-22043,
-22051,
-22051,
-22060,
-22060,
-22060,
-22074,
-22086,
-22086,
-22099,
-22099,
-22120,
-22120,
-22134,
-22144,
-22150,
-22158,
-22164,
-22164,
-22171,
-22199,
-22210,
-22210,
-22210,
-22220,
+22050,
+22078,
+22112,
+22115,
+22122,
+22125,
+22174,
+22208,
+22211,
+22221,
22228,
22228,
-22239,
-22261,
-22304,
-22304,
-22312,
-22349,
-22349,
-22349,
-22357,
-22381,
-22381,
-22390,
-22390,
-22390,
-22390,
-22402,
-22413,
-22413,
-22422,
-22422,
-22445,
-22445,
-22445,
-22456,
-22456,
+22240,
+22254,
+22254,
+22273,
+22291,
+22327,
+22355,
+22358,
+22368,
+22368,
+22368,
+22368,
+22384,
+22397,
+22415,
+22418,
+22418,
+22439,
+22459,
+22459,
22469,
-22479,
-22501,
-22512,
-22528,
-22528,
-22528,
-22528,
-22528,
-22528,
-22528,
-22540,
+22488,
+22507,
+22524,
+22524,
22540,
+22543,
22546,
22546,
22546,
22546,
-22569,
-22591,
-22591,
-22591,
-22591,
-22610,
-22655,
-22655,
-22667,
-22667,
-22677,
-22677,
-22692,
-22692,
-22702,
-22702,
-22702,
-22717,
-22736,
+22553,
+22575,
+22581,
+22584,
+22587,
+22595,
+22607,
+22607,
+22614,
+22624,
+22650,
+22686,
+22699,
+22705,
+22718,
22750,
-22755,
-22780,
-22785,
-22822,
-22844,
-22859,
-22871,
-22909,
-22949,
-22962,
-22973,
-22979,
-22988,
-23007,
-23027,
-23035,
-23072,
-23082,
-23082,
-23109,
-23116,
-23130,
-23158,
-23166,
-23166,
-23172,
-23177,
-23189,
-23219,
-23219,
-23250,
-23273,
-23281,
-23281,
-23281,
-23281,
-23281,
+22753,
+22772,
+22782,
+22789,
+22825,
+22838,
+22890,
+22913,
+22916,
+22926,
+22932,
+22946,
+22986,
+22986,
+23015,
+23050,
+23073,
+23076,
+23079,
+23101,
+23132,
+23152,
+23211,
+23237,
+23240,
+23259,
+23284,
23287,
-23287,
-23299,
-23305,
-23315,
-23315,
-23321,
-23328,
-23334,
-23355,
-23355,
-23355,
-23355,
-23355,
-23366,
-23390,
-23396,
-23396,
-23396,
-23396,
-23402,
-23418,
-23424,
-23424,
-23438,
-23446,
-23446,
-23446,
-23500,
-23525,
-23569,
-23592,
-23592,
-23592,
-23605,
-23614,
-23614,
-23614,
-23627,
-23633,
-23657,
-23673,
-23673,
-23673,
-23689,
-23689,
-23701,
-23701,
-23701,
-23713,
-23713,
-23713,
-23738,
-23758,
-23775,
-23775,
-23794,
-23794,
-23803,
-23803,
-23803,
-23803,
-23813,
-23826,
-23845,
-23845,
-23845,
-23845,
-23872,
-23872,
-23872,
-23888,
-23888,
-23900,
-23900,
-23906,
-23906,
-23906,
-23906,
-23906,
-23924,
-23924,
-23924,
-23930,
-23930,
-23939,
-23949,
-23971,
-23971,
-23971,
-24000,
-24012,
-24042,
-24042,
-24042,
-24042,
-24042,
-24070,
-24076,
-24094,
-24094,
-24094,
-24123,
-24123,
-24123,
-24134,
-24150,
+23302,
+23308,
+23311,
+23311,
+23311,
+23318,
+23325,
+23339,
+23352,
+23369,
+23380,
+23430,
+23437,
+23457,
+23460,
+23466,
+23473,
+23516,
+23519,
+23522,
+23534,
+23549,
+23568,
+23589,
+23609,
+23631,
+23642,
+23645,
+23676,
+23683,
+23693,
+23696,
+23730,
+23746,
+23790,
+23807,
+23819,
+23840,
+23843,
+23843,
+23868,
+23885,
+23898,
+23905,
+23921,
+23921,
+23938,
+23979,
+23988,
+23994,
+24022,
+24029,
+24059,
+24059,
+24081,
+24100,
+24100,
+24107,
+24131,
24150,
-24150,
-24150,
-24150,
-24150,
-24155,
-24179,
-24179,
-24189,
-24189,
-24189,
-24198,
-24198,
-24218,
-24218,
-24218,
-24234,
-24251,
-24257,
-24276,
+24181,
+24181,
+24184,
+24187,
+24209,
+24239,
+24252,
+24265,
+24271,
+24274,
+24300,
24305,
-24321,
-24321,
-24321,
-24334,
-24334,
-24334,
-24349,
-24356,
-24361,
-24372,
-24372,
-24372,
-24388,
-24396,
-24396,
-24402,
-24410,
-24410,
-24428,
-24428,
-24450,
-24450,
+24308,
+24311,
+24314,
+24330,
+24333,
+24333,
+24333,
+24336,
+24339,
+24345,
+24348,
+24351,
+24378,
+24384,
+24422,
+24435,
+24446,
24467,
-24485,
-24495,
-24495,
-24495,
-24507,
-24507,
-24514,
-24531,
-24531,
-24531,
+24470,
+24473,
+24492,
+24505,
+24508,
+24508,
24531,
-24531,
-24537,
-24537,
-24558,
-24572,
-24584,
-24584,
-24601,
-24601,
-24607,
-24615,
-24615,
-24632,
-24632,
-24632,
-24632,
-24661,
-24676,
-24676,
-24724,
-24751,
-24751,
-24774,
-24774,
-24783,
-24793,
-24793,
-24793,
-24813,
-24819,
-24819,
-24826,
-24826,
-24842,
-24858,
-24872,
-24872,
-24890,
-24890,
-24890,
-24890,
-24890,
-24890,
-24890,
-24890,
-24890,
-24906,
-24906,
-24917,
-24928,
-24947,
-24947,
-24947,
-24947,
-24947,
-24947,
-24947,
-24947,
-24947,
-24963,
-24983,
-24991,
-24991,
-24991,
-24991,
-24991,
-24991,
-24991,
-24991,
-25007,
-25007,
-25007,
-25007,
-25007,
-25007,
-25007,
-25030,
-25040,
-25040,
-25040,
-25040,
-25040,
-25059,
-25097,
+24551,
+24593,
+24617,
+24640,
+24652,
+24652,
+24668,
+24668,
+24668,
+24717,
+24748,
+24748,
+24766,
+24769,
+24775,
+24791,
+24791,
+24829,
+24829,
+24851,
+24861,
+24867,
+24913,
+24946,
+24946,
+24965,
+24968,
+24968,
+24981,
+24981,
+24994,
+24994,
+25009,
+25012,
+25015,
+25026,
+25031,
+25043,
+25043,
+25056,
+25056,
+25056,
+25056,
+25062,
+25075,
+25099,
+25106,
+25118,
+25118,
+25118,
+25118,
+25126,
25132,
-25149,
-25159,
-25169,
-25169,
-25169,
-25192,
-25192,
-25192,
-25192,
-25205,
-25205,
-25216,
-25221,
-25221,
-25233,
-25233,
-25240,
-25250,
-25256,
-25273,
-25273,
-25303,
-25321,
-25321,
-25321,
-25333,
-25333,
-25333,
-25333,
-25370,
-25370,
-25402,
-25418,
-25418,
-25439,
-25439,
-25454,
-25454,
-25454,
-25463,
-25477,
-25526,
-25526,
-25526,
-25526,
-25545,
-25562,
-25572,
-25572,
-25582,
-25582,
-25582,
+25183,
+25183,
+25200,
+25219,
+25225,
+25241,
+25247,
+25259,
+25274,
+25322,
+25322,
+25336,
+25336,
+25336,
+25360,
+25368,
+25368,
+25368,
+25374,
+25381,
+25387,
+25398,
+25417,
+25417,
+25417,
+25431,
+25466,
+25492,
+25500,
+25549,
+25569,
+25569,
+25590,
+25590,
25597,
-25610,
-25634,
-25641,
-25641,
-25641,
-25668,
-25668,
-25675,
-25707,
-25727,
-25727,
-25741,
-25756,
-25756,
-25779,
-25811,
-25811,
-25811,
-25817,
-25817,
-25817,
-25827,
-25827,
-25827,
-25827,
-25827,
-25836,
-25836,
-25836,
-25836,
-25850,
-25850,
+25616,
+25622,
+25640,
+25640,
+25640,
+25655,
+25655,
+25671,
+25671,
+25691,
+25706,
+25706,
+25706,
+25738,
+25738,
+25746,
+25759,
+25759,
+25781,
+25781,
+25802,
+25815,
25860,
-25884,
-25901,
-25922,
-25936,
-25946,
-25969,
-25969,
-25969,
-25969,
-25975,
-25975,
-25987,
-25987,
-26065,
-26065,
+25860,
+25867,
+25877,
+25877,
+25877,
+25913,
+25913,
+25953,
+25980,
+26002,
+26013,
+26026,
+26026,
+26032,
+26032,
+26038,
+26050,
+26050,
+26059,
26065,
-26084,
-26084,
-26103,
+26071,
+26087,
+26122,
26128,
-26141,
-26151,
-26169,
-26169,
-26169,
-26180,
-26191,
-26191,
-26191,
-26197,
-26197,
-26205,
-26211,
-26235,
-26235,
-26235,
-26235,
-26235,
-26235,
-26245,
-26245,
-26259,
-26259,
-26259,
-26259,
-26284,
-26284,
-26325,
-26325,
-26355,
-26364,
-26364,
-26402,
-26418,
-26418,
-26425,
-26432,
-26432,
-26454,
-26504,
-26513,
-26525,
-26525,
-26525,
-26525,
-26525,
-26545,
-26545,
-26571,
-26590,
-26597,
-26597,
-26597,
-26597,
-26597,
+26146,
+26164,
+26185,
+26212,
+26212,
+26229,
+26229,
+26236,
+26248,
+26266,
+26290,
+26311,
+26311,
+26311,
+26311,
+26321,
+26352,
+26365,
+26371,
+26371,
+26394,
+26403,
+26435,
+26435,
+26435,
+26435,
+26485,
+26516,
+26522,
+26528,
+26565,
+26565,
+26600,
26639,
-26648,
-26659,
-26666,
-26672,
-26672,
-26672,
-26672,
-26672,
-26694,
-26701,
-26701,
-26701,
-26724,
-26724,
-26746,
-26753,
-26774,
-26774,
-26774,
-26774,
-26806,
-26824,
-26824,
-26830,
-26852,
-26882,
-26882,
-26889,
-26889,
-26889,
-26889,
-26889,
-26889,
-26903,
-26911,
-26918,
-26918,
-26928,
-26948,
-26948,
-26970,
-26970,
-26985,
-26996,
-27045,
-27045,
-27058,
-27058,
-27068,
-27068,
-27104,
-27155,
-27155,
-27155,
-27155,
-27155,
-27172,
-27172,
-27172,
-27172,
-27189,
-27195,
-27195,
-27223,
-27223,
-27223,
-27223,
-27244,
-27290,
-27322,
-27332,
-27364,
+26649,
+26649,
+26649,
+26649,
+26700,
+26735,
+26745,
+26759,
+26778,
+26778,
+26801,
+26810,
+26810,
+26829,
+26836,
+26849,
+26849,
+26856,
+26856,
+26874,
+26883,
+26883,
+26883,
+26883,
+26899,
+26915,
+26915,
+26915,
+26915,
+26936,
+26951,
+26958,
+26958,
+26975,
+26994,
+27000,
+27010,
+27041,
+27066,
+27073,
+27110,
+27150,
+27150,
+27168,
+27168,
+27175,
+27184,
+27184,
+27184,
+27196,
+27209,
+27224,
+27242,
+27242,
+27248,
+27248,
+27278,
+27298,
+27314,
+27320,
+27363,
27371,
27371,
-27371,
-27401,
-27401,
-27417,
-27417,
+27393,
+27399,
+27399,
+27405,
+27405,
+27405,
+27411,
+27418,
+27425,
+27431,
27431,
-27470,
-27470,
-27470,
-27470,
-27484,
-27484,
-27484,
-27484,
-27484,
-27496,
-27496,
-27515,
-27515,
-27543,
-27560,
-27576,
-27604,
-27622,
-27631,
-27631,
-27638,
-27649,
-27672,
-27682,
-27682,
-27682,
-27707,
-27717,
-27724,
-27732,
-27755,
-27755,
-27755,
-27768,
-27768,
-27783,
-27789,
-27799,
-27799,
-27799,
-27818,
-27826,
-27838,
-27848,
-27848,
-27848,
-27855,
-27862,
-27862,
-27896,
-27921,
-27921,
-27943,
-27954,
-27954,
-27976,
-27976,
-27976,
-27985,
-28002,
-28012,
-28019,
-28034,
-28034,
-28046,
-28068,
-28097,
-28122,
-28122,
-28131,
-28137,
-28151,
-28151,
-28172,
-28190,
+27455,
+27469,
+27475,
+27475,
+27475,
+27475,
+27475,
+27500,
+27500,
+27523,
+27523,
+27558,
+27574,
+27580,
+27650,
+27663,
+27679,
+27679,
+27733,
+27745,
+27754,
+27761,
+27774,
+27774,
+27782,
+27816,
+27854,
+27854,
+27875,
+27875,
+27875,
+27930,
+27947,
+27967,
+27967,
+27979,
+27986,
+28007,
+28015,
+28036,
+28036,
+28060,
+28060,
+28078,
+28078,
+28078,
+28085,
+28085,
+28091,
+28105,
+28119,
+28119,
+28157,
+28157,
+28163,
+28175,
+28196,
+28196,
28196,
-28211,
-28211,
-28264,
-28273,
-28286,
-28324,
-28324,
-28324,
-28354,
-28354,
-28361,
-28397,
-28417,
-28417,
-28424,
-28435,
-28461,
-28461,
-28470,
-28483,
-28483,
-28483,
-28483,
-28483,
-28483,
-28483,
-28515,
-28531,
-28531,
+28230,
+28230,
+28230,
+28230,
+28256,
+28265,
+28265,
+28281,
+28281,
+28299,
+28310,
+28325,
+28325,
+28344,
+28353,
+28353,
+28389,
+28389,
+28389,
+28399,
+28421,
+28444,
+28444,
+28478,
+28525,
+28525,
28549,
-28575,
-28575,
-28575,
-28582,
-28599,
-28615,
-28630,
-28630,
+28549,
+28579,
+28579,
+28594,
+28607,
+28621,
+28638,
28672,
-28711,
-28723,
-28723,
-28731,
-28752,
-28752,
-28752,
-28763,
-28763,
-28775,
-28775,
-28775,
-28775,
-28775,
-28775,
-28805,
-28814,
-28830,
-28861,
-28882,
-28882,
-28902,
-28918,
-28937,
-28952,
-28959,
-28998,
-29009,
-29009,
-29009,
-29009,
-29019,
-29019,
-29019,
-29019,
-29019,
-29057,
-29069,
-29076,
-29076,
-29076,
-29076,
-29076,
-29082,
-29082,
-29082,
-29117,
-29117,
-29117,
+28679,
+28679,
+28679,
+28690,
+28738,
+28748,
+28748,
+28748,
+28748,
+28748,
+28769,
+28803,
+28810,
+28810,
+28819,
+28819,
+28819,
+28826,
+28853,
+28853,
+28853,
+28860,
+28873,
+28898,
+28898,
+28913,
+28913,
+28913,
+28930,
+28930,
+28956,
+28981,
+29024,
+29024,
+29044,
+29044,
+29074,
+29085,
+29104,
29117,
-29134,
-29134,
-29159,
-29159,
-29185,
-29185,
-29196,
-29196,
-29242,
-29248,
-29256,
-29280,
-29301,
-29307,
-29307,
-29307,
-29314,
-29314,
-29338,
-29356,
-29367,
-29367,
-29381,
-29391,
-29399,
-29399,
-29414,
-29434,
-29434,
-29441,
-29473,
-29484,
-29503,
-29520,
-29520,
-29548,
-29565,
-29572,
-29572,
-29572,
-29572,
-29572,
-29597,
-29597,
-29620,
-29655,
-29660,
-29660,
-29660,
-29667,
-29674,
-29688,
-29698,
-29705,
-29728,
-29740,
-29740,
-29761,
-29761,
-29767,
-29780,
-29787,
-29794,
-29794,
-29807,
-29820,
-29820,
-29820,
-29820,
-29832,
-29844,
-29855,
-29855,
-29855,
-29867,
-29867,
-29867,
-29867,
-29881,
-29881,
-29905,
-29905,
-29905,
-29923,
-29923,
-29948,
-29948,
-29948,
-29976,
-29986,
-29996,
-29996,
-30030,
-30030,
-30054,
-30054,
-30070,
-30070,
-30070,
-30077,
-30077,
-30087,
-30107,
-30107,
-30115,
-30141,
-30178,
-30178,
-30201,
-30201,
-30201,
-30207,
-30229,
-30239,
-30254,
-30268,
-30277,
-30311,
-30323,
-30323,
-30331,
-30331,
-30331,
-30331,
-30331,
-30353,
-30365,
-30374,
-30374,
-30374,
-30380,
-30380,
-30380,
-30380,
-30410,
-30410,
-30410,
-30443,
-30443,
-30453,
-30462,
-30472,
-30472,
-30472,
-30472,
-30472,
-30472,
-30489,
-30500,
-30500,
-30500,
-30532,
-30532,
-30553,
-30577,
-30599,
-30599,
-30609,
-30640,
-30640,
-30640,
-30664,
-30676,
-30676,
-30676,
-30692,
-30719,
-30728,
-30728,
-30742,
-30742,
-30749,
-30749,
-30760,
-30770,
-30770,
-30783,
-30783,
-30783,
-30804,
-30847,
-30847,
-30847,
-30847,
-30857,
-30857,
-30857,
-30857,
-30875,
-30875,
-30895,
-30895,
-30921,
-30926,
-30926,
-30926,
+29125,
+29125,
+29146,
+29153,
+29153,
+29160,
+29175,
+29189,
+29189,
+29214,
+29214,
+29214,
+29224,
+29224,
+29224,
+29234,
+29299,
+29318,
+29325,
+29325,
+29343,
+29400,
+29417,
+29417,
+29436,
+29436,
+29436,
+29436,
+29454,
+29460,
+29460,
+29478,
+29478,
+29478,
+29487,
+29487,
+29516,
+29516,
+29549,
+29559,
+29559,
+29576,
+29587,
+29609,
+29609,
+29630,
+29630,
+29644,
+29644,
+29644,
+29644,
+29664,
+29664,
+29686,
+29711,
+29734,
+29734,
+29741,
+29752,
+29752,
+29778,
+29798,
+29805,
+29819,
+29835,
+29842,
+29849,
+29866,
+29884,
+29891,
+29891,
+29919,
+29943,
+29993,
+30000,
+30010,
+30016,
+30046,
+30069,
+30085,
+30085,
+30102,
+30124,
+30143,
+30150,
+30150,
+30169,
+30169,
+30216,
+30230,
+30256,
+30256,
+30265,
+30280,
+30304,
+30320,
+30324,
+30340,
+30354,
+30364,
+30382,
+30396,
+30396,
+30407,
+30457,
+30473,
+30490,
+30490,
+30490,
+30514,
+30514,
+30539,
+30562,
+30583,
+30615,
+30622,
+30622,
+30629,
+30638,
+30662,
+30662,
+30688,
+30712,
+30712,
+30721,
+30721,
+30721,
+30721,
+30721,
+30758,
+30792,
+30811,
+30811,
+30811,
+30843,
+30843,
+30876,
+30876,
+30876,
+30876,
+30889,
+30909,
+30923,
30945,
30945,
-30945,
-30945,
-30959,
-30959,
-30959,
-30959,
-30972,
-30972,
-30984,
-31011,
-31011,
-31048,
-31056,
-31056,
-31070,
-31077,
-31077,
-31110,
-31110,
-31115,
-31122,
-31139,
-31159,
-31159,
-31165,
-31171,
-31171,
-31197,
-31204,
-31211,
-31211,
-31221,
-31228,
-31228,
-31245,
-31245,
-31245,
-31252,
-31265,
-31265,
-31265,
-31265,
-31294,
-31305,
-31320,
-31333,
-31333,
-31333,
-31343,
-31350,
-31357,
-31369,
-31369,
-31379,
-31385,
-31391,
-31407,
-31407,
-31407,
-31423,
-31423,
-31423,
-31434,
-31454,
-31470,
-31511,
-31521,
-31521,
-31521,
-31542,
-31582,
-31582,
-31597,
-31597,
-31597,
-31614,
-31623,
-31645,
-31645,
+30980,
+31031,
+31059,
+31078,
+31108,
+31125,
+31137,
+31174,
+31200,
+31200,
+31200,
+31200,
+31207,
+31237,
+31237,
+31259,
+31279,
+31307,
+31335,
+31378,
+31378,
+31378,
+31378,
+31397,
+31437,
+31443,
+31467,
+31467,
+31483,
+31527,
+31537,
+31548,
+31557,
+31564,
+31564,
+31589,
+31603,
+31647,
31661,
-31661,
-31669,
-31669,
-31676,
-31676,
-31706,
-31720,
-31726,
-31743,
-31785,
-31804,
-31817,
-31817,
-31835,
-31846,
-31863,
-31885,
-31885,
-31896,
-31907,
-31907,
-31907,
-31922,
-31922,
-31929,
-31929,
-31929,
-31936,
-31943,
-31949,
-31949,
-31949,
-31959,
-32006,
-32024,
-32031,
-32031,
-32038,
-32063,
-32095,
-32095,
-32105,
-32105,
-32105,
-32105,
-32105,
-32125,
-32134,
-32140,
-32176,
-32185,
-32195,
-32195,
-32195,
-32195,
-32202,
-32202,
-32218,
-32236,
-32259,
-32294,
+31677,
+31677,
+31690,
+31709,
+31709,
+31762,
+31769,
+31776,
+31799,
+31841,
+31841,
+31848,
+31869,
+31875,
+31875,
+31904,
+31904,
+31925,
+31939,
+31952,
+31984,
+31984,
+31984,
+32029,
+32029,
+32029,
+32045,
+32055,
+32086,
+32086,
+32124,
+32152,
+32152,
+32159,
+32159,
+32184,
+32190,
+32211,
+32231,
+32231,
+32238,
+32261,
+32268,
+32284,
+32284,
+32284,
+32284,
32300,
-32305,
-32305,
-32305,
32323,
-32337,
-32352,
-32359,
-32374,
-32381,
-32388,
-32388,
-32388,
-32402,
+32351,
+32358,
+32396,
+32396,
+32396,
32402,
32402,
-32402,
-32418,
-32428,
-32428,
-32428,
-32450,
-32450,
-32450,
-32462,
-32467,
-32480,
-32480,
-32480,
-32487,
-32502,
-32509,
-32525,
-32560,
-32570,
-32583,
-32597,
-32623,
-32637,
-32644,
-32667,
-32707,
-32725,
-32725,
-32747,
-32747,
-32751,
-32758,
-32789,
-32807,
-32824,
-32824,
-32824,
-32824,
-32843,
-32843,
-32850,
-32876,
-32908,
-32915,
-32946,
-32965,
-32965,
-32982,
-33002,
-33009,
-33029,
-33064,
-33084,
-33098,
-33098,
-33098,
-33098,
+32414,
+32414,
+32438,
+32449,
+32455,
+32483,
+32490,
+32510,
+32541,
+32548,
+32578,
+32585,
+32592,
+32592,
+32592,
+32616,
+32625,
+32641,
+32671,
+32681,
+32681,
+32688,
+32711,
+32737,
+32754,
+32761,
+32761,
+32777,
+32810,
+32817,
+32817,
+32817,
+32817,
+32817,
+32844,
+32867,
+32901,
+32943,
+32956,
+32974,
+32983,
+33004,
+33004,
+33050,
+33066,
+33072,
+33072,
+33080,
+33080,
33110,
33110,
-33151,
-33158,
-33180,
-33198,
-33205,
-33227,
-33227,
-33237,
-33237,
-33253,
-33258,
-33277,
-33292,
-33315,
-33315,
-33333,
-33348,
-33348,
-33348,
+33134,
+33157,
+33164,
+33200,
+33200,
+33207,
+33244,
+33244,
+33309,
+33316,
+33316,
+33316,
+33316,
+33316,
+33323,
+33341,
33348,
-33348,
-33348,
-33348,
-33355,
-33355,
-33355,
-33390,
-33408,
-33423,
-33437,
-33452,
-33458,
-33465,
-33480,
-33480,
+33361,
+33394,
+33394,
+33394,
+33394,
+33432,
+33442,
+33470,
+33470,
+33470,
+33487,
33487,
-33494,
-33504,
-33511,
-33551,
-33551,
-33558,
-33589,
-33595,
-33595,
+33487,
+33516,
+33548,
+33562,
+33562,
+33569,
+33584,
+33584,
+33584,
33602,
-33627,
-33644,
-33668,
-33668,
-33668,
-33676,
-33676,
-33716,
-33728,
-33747,
-33747,
-33769,
-33775,
-33789,
-33803,
-33803,
-33810,
-33810,
-33810,
-33820,
-33820,
-33820,
-33820,
-33843,
-33843,
-33843,
-33879,
-33889,
-33889,
-33889,
-33903,
-33917,
-33931,
-33959,
-33993,
-34000,
-34014,
-34037,
-34043,
-34055,
-34055,
+33621,
+33621,
+33629,
+33645,
+33645,
+33652,
+33652,
+33672,
+33691,
+33707,
+33714,
+33721,
+33721,
+33735,
+33766,
+33772,
+33772,
+33772,
+33779,
+33779,
+33824,
+33844,
+33844,
+33850,
+33867,
+33867,
+33874,
+33874,
+33874,
+33874,
+33901,
+33946,
+33960,
+33971,
+34019,
+34050,
34077,
-34083,
-34090,
-34099,
-34099,
-34115,
-34115,
-34133,
-34140,
-34167,
-34172,
-34184,
-34221,
-34245,
-34252,
-34252,
+34084,
+34103,
+34110,
+34121,
+34128,
+34157,
+34193,
+34193,
+34220,
34259,
-34318,
+34272,
+34272,
+34272,
+34279,
+34294,
+34300,
+34313,
34318,
34325,
-34325,
-34352,
-34400,
-34415,
-34422,
-34422,
-34431,
-34438,
-34445,
-34445,
-34473,
-34473,
-34489,
-34489,
-34489,
-34489,
-34499,
-34499,
-34499,
-34516,
-34536,
-34551,
-34564,
-34580,
-34580,
-34580,
-34589,
+34333,
+34347,
+34354,
+34361,
+34368,
+34368,
+34368,
+34408,
+34433,
+34467,
+34504,
+34504,
+34547,
+34547,
+34554,
+34561,
+34561,
+34561,
+34582,
34589,
-34589,
-34613,
-34648,
-34648,
-34648,
-34655,
-34664,
-34681,
-34681,
-34698,
-34698,
-34720,
-34736,
+34611,
+34627,
+34637,
+34637,
+34637,
+34641,
+34666,
+34666,
+34683,
+34690,
+34690,
+34699,
+34699,
+34716,
34749,
34749,
-34765,
-34778,
-34785,
-34795,
-34819,
-34819,
-34829,
-34841,
-34848,
-34854,
-34854,
-34854,
-34878,
-34894,
-34894,
-34900,
-34917,
-34934,
-34940,
-34970,
-34998,
-34998,
-35004,
-35004,
-35012,
-35012,
-35012,
-35020,
-35020,
-35032,
-35038,
-35062,
-35062,
-35062,
-35068,
-35068,
-35082,
-35092,
-35096,
-35107,
-35118,
-35134,
-35155,
-35155,
-35166,
-35178,
-35178,
-35195,
-35201,
-35201,
-35201,
-35226,
-35226,
+34756,
+34756,
+34756,
+34756,
+34777,
+34777,
+34777,
+34820,
+34827,
+34862,
+34874,
+34881,
+34881,
+34903,
+34903,
+34903,
+34920,
+34949,
+34949,
+34949,
+34949,
+34968,
+34968,
+35003,
+35003,
+35015,
+35039,
+35039,
+35081,
+35093,
+35093,
+35115,
+35115,
+35132,
+35132,
+35132,
+35132,
+35157,
35226,
-35226,
-35256,
-35262,
-35272,
-35280,
+35241,
+35248,
+35266,
+35266,
+35273,
+35273,
+35273,
+35273,
+35299,
35299,
-35332,
-35354,
-35354,
-35354,
-35370,
-35386,
-35417,
-35417,
-35460,
-35473,
-35478,
-35495,
-35504,
-35504,
-35518,
-35552,
-35589,
-35624,
-35624,
-35637,
-35637,
-35643,
-35643,
-35669,
-35682,
-35695,
-35702,
-35709,
-35709,
-35726,
-35739,
-35749,
-35756,
-35756,
-35778,
-35803,
-35810,
-35829,
-35883,
+35306,
+35334,
+35365,
+35365,
+35406,
+35428,
+35428,
+35441,
+35474,
+35506,
+35506,
+35529,
+35529,
+35548,
+35555,
+35574,
+35574,
+35574,
+35595,
+35630,
+35644,
+35649,
+35698,
+35750,
+35750,
+35762,
+35762,
+35762,
+35798,
+35842,
+35849,
+35866,
+35878,
+35885,
+35892,
35899,
-35905,
-35911,
-35911,
+35899,
+35906,
+35906,
+35906,
35923,
-35947,
-35954,
-35980,
-35987,
-36034,
-36052,
-36063,
-36095,
-36106,
-36106,
+35944,
+35951,
+35961,
+35978,
+35984,
+35992,
+36023,
+36060,
+36076,
+36085,
36113,
-36120,
-36140,
-36140,
-36153,
-36160,
-36160,
-36167,
-36203,
-36203,
-36218,
-36218,
-36225,
-36253,
-36259,
-36284,
-36296,
-36310,
-36324,
-36331,
-36344,
-36367,
-36367,
-36367,
-36412,
-36412,
-36422,
-36463,
-36463,
-36463,
-36479,
-36490,
-36513,
-36520,
-36520,
-36527,
-36527,
-36527,
-36540,
-36574,
-36594,
-36594,
-36605,
-36621,
-36621,
-36641,
-36641,
-36641,
-36659,
-36682,
-36682,
-36682,
-36682,
-36705,
-36705,
-36705,
-36720,
-36720,
-36755,
-36755,
-36771,
-36771,
-36771,
-36788,
-36806,
-36835,
-36845,
-36875,
-36875,
-36903,
-36921,
-36928,
-36928,
-36940,
-36940,
-36940,
-36966,
-36966,
-36973,
-36983,
-36998,
-37004,
-37014,
-37024,
-37024,
-37032,
-37038,
-37038,
-37061,
-37074,
-37074,
-37091,
-37098,
-37105,
-37105,
-37133,
-37141,
-37141,
-37148,
-37191,
-37191,
-37197,
-37197,
-37210,
-37224,
-37224,
-37231,
-37250,
-37257,
-37273,
-37273,
-37280,
-37287,
-37294,
-37300,
-37307,
-37330,
-37348,
-37348,
-37359,
-37359,
-37359,
-37377,
-37392,
-37398,
-37412,
-37431,
-37469,
-37486,
-37508,
-37517,
-37535,
-37535,
-37542,
-37542,
-37549,
-37549,
-37549,
-37549,
-37556,
-37576,
-37576,
-37583,
-37590,
-37597,
-37604,
-37604,
-37621,
-37635,
-37676,
-37676,
-37704,
-37711,
-37728,
+36144,
+36144,
+36159,
+36166,
+36166,
+36173,
+36173,
+36201,
+36201,
+36220,
+36227,
+36227,
+36227,
+36247,
+36263,
+36270,
+36270,
+36315,
+36315,
+36322,
+36330,
+36354,
+36408,
+36420,
+36420,
+36440,
+36454,
+36454,
+36454,
+36461,
+36474,
+36529,
+36569,
+36667,
+36674,
+36674,
+36700,
+36707,
+36707,
+36714,
+36721,
+36721,
+36731,
+36760,
+36781,
+36793,
+36800,
+36800,
+36847,
+36854,
+36868,
+36938,
+36945,
+36967,
+36967,
+36992,
+37008,
+37050,
+37050,
+37050,
+37068,
+37081,
+37088,
+37113,
+37145,
+37145,
+37145,
+37145,
+37165,
+37171,
+37171,
+37198,
+37198,
+37211,
+37239,
+37247,
+37298,
+37341,
+37341,
+37367,
+37400,
+37422,
+37458,
+37492,
+37530,
+37530,
+37530,
+37537,
+37551,
+37566,
+37592,
+37614,
+37614,
+37631,
+37638,
+37645,
+37652,
+37664,
+37702,
+37714,
+37721,
37728,
-37737,
-37737,
-37737,
-37750,
-37757,
-37778,
-37785,
-37785,
-37819,
-37826,
-37833,
-37843,
-37850,
-37869,
-37914,
-37921,
-37935,
+37740,
+37770,
+37770,
+37793,
+37809,
+37830,
+37830,
+37841,
+37841,
+37867,
+37867,
+37883,
+37890,
+37890,
+37910,
+37926,
37942,
-37949,
-37982,
-38013,
-38013,
-38013,
-38023,
-38057,
-38077,
-38097,
-38110,
-38117,
-38123,
-38133,
-38133,
-38133,
-38140,
-38140,
-38148,
-38159,
-38179,
-38192,
-38205,
-38218,
-38218,
-38218,
-38218,
-38218,
-38218,
-38218,
-38218,
-38218,
-38218,
-38218,
-38218,
-38225,
-38225,
-38230,
-38246,
-38258,
-38280,
-38287,
-38294,
-38294,
-38294,
-38301,
-38318,
-38318,
-38340,
-38371,
-38371,
-38384,
-38420,
-38440,
-38453,
-38481,
-38506,
-38522,
-38534,
+37957,
+37991,
+38010,
+38010,
+38026,
+38079,
+38086,
+38093,
+38112,
+38119,
+38136,
+38136,
+38155,
+38189,
+38210,
+38220,
+38248,
+38278,
+38278,
+38314,
+38339,
+38339,
+38354,
+38370,
+38385,
+38399,
+38417,
+38441,
+38469,
+38476,
+38483,
+38499,
+38499,
+38499,
+38521,
38559,
-38559,
-38559,
-38564,
-38564,
-38581,
-38604,
-38604,
-38611,
-38620,
-38626,
-38635,
-38635,
-38635,
-38666,
-38674,
+38599,
+38617,
+38624,
+38624,
+38660,
+38673,
38688,
-38693,
-38710,
-38722,
-38722,
-38722,
-38729,
-38734,
-38752,
-38792,
-38818,
-38825,
+38742,
+38774,
+38774,
+38799,
+38799,
+38830,
+38861,
+38861,
38861,
+38861,
+38861,
+38890,
38902,
-38934,
-38949,
-38949,
-38960,
-38969,
-38985,
-38985,
-38996,
-39013,
-39024,
-39024,
-39032,
-39061,
-39074,
+38909,
+38944,
+38989,
+39007,
+39045,
+39063,
39089,
-39123,
-39123,
-39123,
-39140,
-39161,
-39180,
-39206,
-39215,
-39254,
-39261,
-39277,
-39284,
-39314,
-39314,
-39330,
-39340,
-39340,
-39371,
-39371,
-39392,
+39096,
+39109,
+39109,
+39114,
+39127,
+39162,
+39177,
+39177,
+39200,
+39218,
+39226,
+39226,
+39257,
+39293,
+39293,
+39324,
+39324,
+39352,
+39364,
+39364,
+39377,
+39395,
+39395,
+39413,
39430,
-39430,
-39437,
-39444,
-39461,
-39468,
-39468,
-39485,
-39517,
-39524,
-39538,
-39543,
-39548,
-39555,
+39459,
+39469,
+39469,
+39479,
+39479,
+39479,
+39503,
+39518,
+39528,
+39528,
+39528,
+39540,
+39565,
+39565,
39581,
-39588,
-39588,
-39609,
-39609,
-39616,
-39652,
+39605,
+39622,
+39653,
+39670,
39670,
-39677,
-39677,
-39684,
-39691,
-39702,
-39717,
-39717,
-39717,
-39724,
-39749,
-39760,
-39766,
-39775,
-39791,
-39791,
-39814,
-39827,
-39827,
-39837,
-39859};
+39670,
+39670,
+39683,
+39689,
+39708,
+39743,
+39743,
+39743,
+39743,
+39743,
+39750,
+39750,
+39750,
+39761,
+39761,
+39777,
+39805,
+39845,
+39855,
+39855,
+39855,
+39855,
+39887,
+39887,
+39887,
+39887,
+39916,
+39916,
+39936,
+39943,
+39962,
+39962,
+39976,
+39976,
+40005,
+40011,
+40011,
+40011,
+40039,
+40051,
+40071,
+40087,
+40087,
+40087,
+40099,
+40099,
+40099,
+40148,
+40170,
+40170,
+40183,
+40183,
+40210,
+40210,
+40210,
+40210,
+40210,
+40221,
+40221,
+40221,
+40221,
+40243,
+40271,
+40271,
+40293,
+40309,
+40314,
+40329,
+40329,
+40354,
+40354,
+40354,
+40354,
+40373,
+40383,
+40383,
+40383,
+40383,
+40396,
+40404,
+40411,
+40417,
+40417,
+40417,
+40417,
+40424,
+40462,
+40473,
+40473,
+40479,
+40479,
+40510,
+40539,
+40539,
+40539,
+40539,
+40539,
+40539,
+40539,
+40556,
+40556,
+40577,
+40588,
+40588,
+40588,
+40588,
+40597,
+40614,
+40623,
+40623,
+40623,
+40623,
+40635,
+40635,
+40635,
+40652,
+40652,
+40652,
+40663,
+40702,
+40724,
+40724,
+40724,
+40724,
+40724,
+40750,
+40750,
+40759,
+40781,
+40781,
+40791,
+40817,
+40817,
+40817,
+40817,
+40817,
+40840,
+40891,
+40891,
+40891,
+40936,
+40990,
+40997,
+41022,
+41071,
+41086,
+41086,
+41102,
+41110,
+41131,
+41157,
+41157,
+41198,
+41216,
+41216,
+41216,
+41235,
+41235,
+41235,
+41247,
+41273,
+41273,
+41273,
+41286,
+41286,
+41320,
+41351,
+41377,
+41403,
+41403,
+41416,
+41426,
+41426,
+41442,
+41458,
+41458,
+41458,
+41470,
+41470,
+41487,
+41498,
+41525,
+41525,
+41544,
+41550,
+41581,
+41598,
+41608,
+41645,
+41654,
+41687,
+41715,
+41715,
+41721,
+41763,
+41776,
+41800,
+41800,
+41800,
+41826,
+41853,
+41879,
+41879,
+41898,
+41908,
+41908,
+41908,
+41926,
+41926,
+41926,
+41943,
+41962,
+41972,
+41998,
+42013,
+42027,
+42027,
+42064,
+42064,
+42073,
+42073,
+42087,
+42101,
+42101,
+42138,
+42148,
+42185,
+42185,
+42208,
+42244,
+42284,
+42284,
+42311,
+42311,
+42321,
+42367,
+42367,
+42367,
+42413,
+42413,
+42427,
+42427,
+42447,
+42486,
+42486,
+42486,
+42509,
+42518,
+42556,
+42556,
+42556,
+42568,
+42586,
+42586,
+42586,
+42605,
+42605,
+42605,
+42628,
+42638,
+42651,
+42651,
+42651,
+42660,
+42681,
+42731,
+42769,
+42769,
+42769,
+42794,
+42802,
+42831,
+42862,
+42862,
+42862,
+42862,
+42911,
+42911,
+42931,
+42946,
+42946,
+42977,
+42994,
+43024,
+43024,
+43024,
+43030,
+43030,
+43084,
+43116,
+43163,
+43163,
+43175,
+43175,
+43175,
+43175,
+43175,
+43175,
+43200,
+43206,
+43206,
+43217,
+43249,
+43249,
+43268,
+43268,
+43285,
+43285,
+43306,
+43306,
+43306,
+43306,
+43324,
+43342,
+43342,
+43361,
+43375,
+43375,
+43375,
+43391,
+43418,
+43424,
+43424,
+43436,
+43443,
+43443,
+43443,
+43473,
+43473,
+43473,
+43486,
+43486,
+43501,
+43501,
+43534,
+43552,
+43567,
+43583,
+43583,
+43599,
+43599,
+43621,
+43621,
+43630,
+43646,
+43663,
+43663,
+43680,
+43680,
+43680,
+43692,
+43720,
+43753,
+43765,
+43778,
+43795,
+43795,
+43795,
+43811,
+43811,
+43811,
+43823,
+43879,
+43895,
+43895,
+43930,
+43930,
+43954,
+43954,
+43971,
+43971,
+43971,
+44004,
+44029,
+44038,
+44048,
+44060,
+44060,
+44060,
+44066,
+44075,
+44090,
+44100,
+44137,
+44157,
+44166,
+44175,
+44175,
+44180,
+44188,
+44210,
+44220,
+44220,
+44220,
+44220,
+44220,
+44220,
+44236,
+44246,
+44255,
+44279,
+44279,
+44302,
+44332,
+44332,
+44332,
+44352,
+44368,
+44391,
+44391,
+44391,
+44420,
+44420,
+44444,
+44479,
+44479,
+44497,
+44510,
+44510,
+44510,
+44510,
+44510,
+44510,
+44543,
+44550,
+44550,
+44557,
+44623,
+44623,
+44642,
+44642,
+44642,
+44679,
+44691,
+44774,
+44774,
+44774,
+44819,
+44836,
+44895,
+44895,
+44930,
+44945,
+44945,
+45013,
+45020,
+45083,
+45099,
+45111,
+45119,
+45129,
+45136,
+45148,
+45148,
+45148,
+45154,
+45171,
+45171,
+45171,
+45171,
+45171,
+45182,
+45182,
+45208,
+45217,
+45255,
+45255,
+45274,
+45274,
+45274,
+45303,
+45309,
+45323,
+45323,
+45354,
+45363,
+45372,
+45372,
+45388,
+45421,
+45449,
+45463,
+45477,
+45504,
+45504,
+45521,
+45521,
+45537,
+45556,
+45556,
+45563,
+45569,
+45569,
+45569,
+45587,
+45593,
+45611,
+45616,
+45616,
+45628,
+45648,
+45692,
+45710,
+45740,
+45773,
+45787,
+45805,
+45811,
+45828,
+45828,
+45861,
+45875,
+45881,
+45881,
+45881,
+45891,
+45891,
+45908,
+45920,
+45920,
+45932,
+45932,
+45932,
+45932,
+45947,
+45966,
+45966,
+46003,
+46039,
+46045,
+46081,
+46087,
+46104,
+46133,
+46150,
+46165,
+46176,
+46176,
+46176,
+46176,
+46181,
+46187,
+46187,
+46187,
+46187,
+46196,
+46202,
+46202,
+46202,
+46213,
+46213,
+46218,
+46218,
+46235,
+46235,
+46235,
+46235,
+46240,
+46302,
+46302,
+46324,
+46324,
+46324,
+46324,
+46324,
+46324,
+46324,
+46324,
+46344,
+46344,
+46356,
+46365,
+46365,
+46396,
+46396,
+46402,
+46430,
+46444,
+46467,
+46492,
+46492,
+46534,
+46563,
+46563,
+46584,
+46595,
+46605,
+46616,
+46616,
+46629,
+46629,
+46654,
+46660,
+46676,
+46676,
+46676,
+46682,
+46682,
+46682,
+46682,
+46711,
+46728,
+46728,
+46728,
+46728,
+46782,
+46797,
+46802,
+46818,
+46818,
+46824,
+46853,
+46853,
+46870,
+46876,
+46876,
+46928,
+46961,
+46981,
+46981,
+47023,
+47023,
+47023,
+47023,
+47075,
+47112,
+47134,
+47146,
+47162,
+47172,
+47172,
+47172,
+47177,
+47177,
+47177,
+47182,
+47193,
+47193,
+47214,
+47256,
+47278,
+47289,
+47338,
+47344,
+47344,
+47367,
+47367,
+47414,
+47423,
+47423,
+47434,
+47451,
+47464,
+47464,
+47464,
+47464,
+47464,
+47479,
+47479,
+47520,
+47520,
+47533,
+47546,
+47552,
+47561,
+47573,
+47573,
+47573,
+47591,
+47591,
+47591,
+47591,
+47596,
+47609,
+47609,
+47620,
+47650,
+47650,
+47650,
+47655,
+47693,
+47708,
+47708,
+47732,
+47737,
+47742,
+47754,
+47768,
+47800,
+47818,
+47818,
+47829,
+47850,
+47850,
+47908,
+47908,
+47930,
+47936,
+47936,
+47978,
+47978,
+47983,
+48002,
+48012,
+48025,
+48025,
+48034,
+48049,
+48083,
+48093,
+48138,
+48138,
+48153,
+48182,
+48205,
+48205,
+48205,
+48212,
+48212,
+48212,
+48234,
+48234,
+48234,
+48234,
+48250,
+48264,
+48264,
+48280,
+48280,
+48295,
+48295,
+48295,
+48295,
+48319,
+48319,
+48319,
+48328,
+48328,
+48334,
+48356,
+48356,
+48362,
+48419,
+48469,
+48488,
+48494,
+48534,
+48534,
+48559,
+48569,
+48583,
+48604,
+48620,
+48670,
+48688,
+48688,
+48697,
+48710,
+48710,
+48710,
+48724,
+48751,
+48757,
+48770,
+48782,
+48797,
+48835,
+48835,
+48840,
+48886,
+48906,
+48922,
+48931,
+48931,
+48951,
+48951,
+48951,
+48962,
+48962,
+48969,
+49033,
+49033,
+49033,
+49074,
+49116,
+49116,
+49123,
+49130,
+49130,
+49164,
+49170,
+49187,
+49206,
+49215,
+49234,
+49261,
+49261,
+49273,
+49324,
+49324,
+49357,
+49404,
+49404,
+49429,
+49448,
+49448,
+49466,
+49472,
+49499,
+49499,
+49499,
+49543,
+49572,
+49579,
+49622,
+49632,
+49685,
+49724,
+49724,
+49724,
+49724,
+49724,
+49761,
+49769,
+49769,
+49797,
+49797,
+49832,
+49832,
+49832,
+49859,
+49859,
+49873,
+49884,
+49884,
+49920,
+49920,
+49931,
+49947,
+49961,
+49978,
+50008,
+50038,
+50038,
+50038,
+50060,
+50076,
+50089,
+50089,
+50089,
+50102,
+50130,
+50130,
+50146,
+50146,
+50146,
+50151,
+50159,
+50184,
+50206,
+50233,
+50250,
+50250,
+50266,
+50274,
+50274,
+50274,
+50274,
+50287,
+50315,
+50315,
+50315,
+50327,
+50327,
+50334,
+50334,
+50366,
+50372,
+50402,
+50402,
+50434,
+50474,
+50494,
+50494,
+50510,
+50510,
+50510,
+50510,
+50510,
+50510,
+50515,
+50515,
+50536,
+50557,
+50578,
+50595,
+50595,
+50595,
+50620,
+50626,
+50626,
+50644,
+50656,
+50671,
+50671,
+50671,
+50695,
+50730,
+50730,
+50740,
+50746,
+50750,
+50765,
+50771,
+50771,
+50817,
+50817,
+50828,
+50837,
+50837,
+50844,
+50844,
+50894,
+50894,
+50905,
+50905,
+50905,
+50944,
+50944,
+50944,
+50975,
+51011,
+51024,
+51024,
+51024,
+51042,
+51042,
+51042,
+51054,
+51054,
+51064,
+51073,
+51073,
+51073,
+51073,
+51073,
+51073,
+51098,
+51117,
+51117,
+51117,
+51137,
+51137,
+51137,
+51200,
+51221,
+51246,
+51246,
+51272,
+51307,
+51334,
+51334,
+51334,
+51334,
+51354,
+51354,
+51370,
+51377,
+51377,
+51415,
+51431,
+51431,
+51431,
+51450,
+51450,
+51456,
+51499,
+51517,
+51529,
+51550,
+51550,
+51558,
+51569,
+51569,
+51569,
+51569,
+51569,
+51569,
+51584,
+51584,
+51584,
+51598,
+51638,
+51638,
+51638,
+51671,
+51683,
+51710,
+51710,
+51731,
+51766,
+51775,
+51808,
+51829,
+51861,
+51861,
+51861,
+51877,
+51877,
+51889,
+51889,
+51889,
+51911,
+51946,
+51946,
+51966,
+51966,
+51966,
+51966,
+51980,
+51985,
+51997,
+51997,
+51997,
+51997,
+52004,
+52004,
+52004,
+52004,
+52017,
+52032,
+52032,
+52032,
+52063,
+52063,
+52076,
+52095,
+52107,
+52121,
+52121,
+52121,
+52121,
+52121,
+52121,
+52149,
+52184,
+52213,
+52213,
+52213,
+52213,
+52213,
+52213,
+52246,
+52257,
+52286,
+52286,
+52316,
+52316,
+52329,
+52329,
+52329,
+52365,
+52365,
+52365,
+52365,
+52372,
+52386,
+52386,
+52412,
+52420,
+52430,
+52430,
+52436,
+52436,
+52448,
+52454,
+52454,
+52454,
+52479,
+52497,
+52497,
+52512,
+52531,
+52531,
+52551,
+52571,
+52609,
+52609,
+52623,
+52623,
+52635,
+52656,
+52656,
+52668,
+52689,
+52689,
+52706,
+52706,
+52716,
+52716,
+52732,
+52749,
+52755,
+52772,
+52772,
+52772,
+52772,
+52801,
+52801,
+52830,
+52841,
+52841,
+52841,
+52864,
+52864,
+52864,
+52864,
+52864,
+52875,
+52885,
+52893,
+52914,
+52936,
+52960,
+52980,
+53001,
+53001,
+53001,
+53001,
+53001,
+53023,
+53039,
+53039,
+53039,
+53056,
+53069,
+53069,
+53127,
+53145,
+53162,
+53162,
+53183,
+53199,
+53230,
+53244,
+53251,
+53251,
+53269,
+53269,
+53284,
+53320,
+53326,
+53326,
+53359,
+53359,
+53377,
+53404,
+53404,
+53436,
+53454,
+53471,
+53481,
+53498,
+53517,
+53517,
+53517,
+53517,
+53536,
+53557,
+53603,
+53617,
+53617,
+53636,
+53663,
+53663,
+53682,
+53682,
+53702,
+53702,
+53702,
+53717,
+53717,
+53757,
+53769,
+53788,
+53788,
+53788,
+53788,
+53788,
+53809,
+53809,
+53823,
+53840,
+53840,
+53866,
+53907,
+53942,
+53942,
+53942,
+53979,
+54003,
+54003,
+54024,
+54024,
+54024,
+54024,
+54024,
+54043,
+54043,
+54059,
+54069,
+54110,
+54131,
+54142,
+54160,
+54177,
+54177,
+54177,
+54187,
+54187,
+54205,
+54212,
+54212,
+54244,
+54270,
+54280,
+54292,
+54292,
+54292,
+54309,
+54309,
+54335,
+54335,
+54335,
+54343,
+54365,
+54379,
+54379,
+54414,
+54414,
+54414,
+54414,
+54414,
+54448,
+54448,
+54458,
+54490,
+54496,
+54513,
+54521,
+54583,
+54583,
+54603,
+54637,
+54658,
+54658,
+54666,
+54682,
+54691,
+54691,
+54726,
+54743,
+54784,
+54784,
+54794,
+54825,
+54825,
+54825,
+54839,
+54866,
+54866,
+54899,
+54899,
+54908,
+54908,
+54936,
+54936,
+54942,
+54942,
+54977,
+54977,
+54977,
+54977,
+54977,
+54977,
+54977,
+54977,
+54977,
+54988,
+54988,
+54995,
+55056,
+55082,
+55082,
+55082,
+55092,
+55104,
+55128,
+55128,
+55148,
+55170,
+55170,
+55170,
+55210,
+55229,
+55251,
+55308,
+55308,
+55326,
+55336,
+55355,
+55355,
+55355,
+55355,
+55368,
+55375,
+55382,
+55382,
+55382,
+55389,
+55389,
+55389,
+55415,
+55425,
+55467,
+55467,
+55481,
+55492,
+55492,
+55492,
+55516,
+55516,
+55516,
+55529,
+55540,
+55540,
+55560,
+55560,
+55577,
+55577,
+55577,
+55584,
+55584,
+55602,
+55602,
+55602,
+55638,
+55638,
+55655,
+55655,
+55655,
+55655,
+55655,
+55672,
+55680,
+55680,
+55698,
+55715,
+55754,
+55762,
+55802,
+55802,
+55802,
+55808,
+55825,
+55825,
+55825,
+55865,
+55865,
+55865,
+55885,
+55891,
+55901,
+55901,
+55918,
+55945,
+55945,
+55971,
+55978,
+55991,
+56004,
+56011,
+56026,
+56026,
+56041,
+56049,
+56049,
+56071,
+56122,
+56122,
+56149,
+56149,
+56149,
+56169,
+56169,
+56181,
+56181,
+56181,
+56181,
+56181,
+56196,
+56196,
+56255,
+56281,
+56281,
+56299,
+56299,
+56336,
+56342,
+56342,
+56375,
+56381,
+56381,
+56381,
+56387,
+56410,
+56426,
+56426,
+56436,
+56436,
+56436,
+56457,
+56457,
+56457,
+56464,
+56464,
+56478,
+56490,
+56490,
+56490,
+56511,
+56511,
+56517,
+56531,
+56548,
+56548,
+56548,
+56554,
+56570,
+56593,
+56605,
+56619,
+56619,
+56638,
+56638,
+56638,
+56638,
+56650,
+56668,
+56685,
+56698,
+56698,
+56698,
+56709,
+56722,
+56739,
+56739,
+56755,
+56773,
+56812,
+56828,
+56834,
+56865,
+56865,
+56865,
+56865,
+56871,
+56893,
+56911,
+56937,
+56937,
+56937,
+56937,
+56976,
+56976,
+57000,
+57009,
+57027,
+57073,
+57073,
+57124,
+57124,
+57149,
+57190,
+57221,
+57243,
+57253,
+57279,
+57300,
+57300,
+57338,
+57338,
+57338,
+57347,
+57359,
+57380,
+57380,
+57380,
+57403,
+57409,
+57424,
+57433,
+57450,
+57472,
+57472,
+57480,
+57480,
+57480,
+57480,
+57491,
+57518,
+57518,
+57518,
+57533,
+57533,
+57533,
+57533,
+57553,
+57553,
+57553,
+57588,
+57595,
+57610,
+57619,
+57619,
+57661,
+57691,
+57691,
+57691,
+57691,
+57707,
+57713,
+57731,
+57731,
+57750,
+57750,
+57756,
+57791,
+57791,
+57791,
+57791,
+57791,
+57805,
+57829,
+57867,
+57867,
+57867,
+57873,
+57893,
+57912,
+57912,
+57948,
+57948,
+57973,
+57979,
+57979,
+57979,
+57990,
+58009,
+58027,
+58039,
+58056,
+58056,
+58080,
+58080,
+58080,
+58115,
+58115,
+58115,
+58115,
+58122,
+58122,
+58122,
+58122,
+58122,
+58153,
+58168,
+58175,
+58175,
+58188,
+58212,
+58237,
+58237,
+58237,
+58275,
+58275,
+58275,
+58275,
+58313,
+58322,
+58343,
+58352,
+58379,
+58379,
+58388,
+58401,
+58418,
+58430,
+58444,
+58469,
+58479,
+58484,
+58503,
+58521,
+58545,
+58572,
+58582,
+58597,
+58630,
+58630,
+58637,
+58654,
+58654,
+58690,
+58690,
+58697,
+58707,
+58713,
+58713,
+58713,
+58730,
+58730,
+58730,
+58763,
+58817,
+58817,
+58817,
+58817,
+58838,
+58838,
+58838,
+58866,
+58902,
+58902,
+58902,
+58911,
+58911,
+58930,
+58930,
+58960,
+58960,
+58988,
+59006,
+59043,
+59061,
+59061,
+59097,
+59122,
+59122,
+59122,
+59122,
+59122,
+59122,
+59122,
+59122,
+59151,
+59167,
+59187,
+59204,
+59212,
+59222,
+59222,
+59222,
+59238,
+59266,
+59285,
+59300,
+59315,
+59315,
+59315,
+59330,
+59343,
+59375,
+59375,
+59395,
+59413,
+59428,
+59428,
+59428,
+59456,
+59466,
+59486,
+59508,
+59508,
+59517,
+59524,
+59542,
+59542,
+59549,
+59549,
+59557,
+59571,
+59587,
+59587,
+59642,
+59668,
+59679,
+59679,
+59694,
+59734,
+59744,
+59758,
+59771,
+59771,
+59786,
+59793,
+59802,
+59820,
+59831,
+59870,
+59896,
+59896,
+59917,
+59932,
+59932,
+59942,
+59942,
+59962,
+59969,
+59969,
+60007,
+60038,
+60050,
+60057,
+60064,
+60102,
+60102,
+60109,
+60116,
+60132,
+60146,
+60165,
+60181,
+60201,
+60201,
+60208,
+60224,
+60245,
+60328,
+60328,
+60335,
+60342,
+60349,
+60349,
+60401,
+60401,
+60401,
+60436,
+60467,
+60467,
+60474,
+60497,
+60504,
+60545,
+60545,
+60569,
+60592,
+60632,
+60638,
+60645,
+60654,
+60654,
+60654,
+60684,
+60684,
+60701,
+60701,
+60718,
+60744,
+60751,
+60751,
+60751,
+60751,
+60776,
+60792,
+60799,
+60799,
+60806,
+60806,
+60845,
+60872,
+60890,
+60890,
+60930,
+60930,
+60930,
+60930,
+60930,
+60948,
+60992,
+61000,
+61000,
+61017,
+61017,
+61044,
+61061,
+61087,
+61107,
+61107,
+61107,
+61107,
+61123,
+61123,
+61142,
+61142,
+61142,
+61184,
+61207,
+61227,
+61227,
+61276,
+61283,
+61290,
+61313,
+61342,
+61376,
+61383,
+61383,
+61390,
+61390,
+61415,
+61424,
+61449,
+61461,
+61461,
+61495,
+61495,
+61502,
+61502,
+61548,
+61548,
+61548,
+61570,
+61602,
+61619,
+61628,
+61628,
+61628,
+61659,
+61673,
+61680,
+61706,
+61729,
+61753,
+61753,
+61753,
+61753,
+61763,
+61796,
+61796,
+61813,
+61820,
+61820,
+61845,
+61852,
+61877,
+61884,
+61904,
+61912,
+61912,
+61912,
+61949,
+61949,
+61961,
+61961,
+61968,
+61968,
+61968,
+61968,
+62014,
+62026,
+62047,
+62068,
+62075,
+62075,
+62082,
+62089,
+62099,
+62128,
+62155,
+62184,
+62184,
+62213,
+62220,
+62245,
+62274,
+62318,
+62338,
+62359,
+62359,
+62359,
+62388,
+62408,
+62415,
+62415,
+62421,
+62421,
+62429,
+62440,
+62440,
+62470,
+62470,
+62470,
+62494,
+62535,
+62542,
+62549,
+62556,
+62564,
+62571,
+62578,
+62611,
+62618,
+62645,
+62655,
+62667,
+62676,
+62701,
+62720,
+62720,
+62727,
+62752,
+62759,
+62766,
+62782,
+62794,
+62794,
+62804,
+62804,
+62814,
+62831,
+62839,
+62846,
+62852,
+62886,
+62886,
+62900,
+62910,
+62929,
+62943,
+62950,
+62972,
+62985,
+62985,
+62985,
+62998,
+63014,
+63041,
+63067,
+63067,
+63085,
+63101,
+63108,
+63108,
+63115,
+63135,
+63135,
+63142,
+63149,
+63149,
+63156,
+63173,
+63173,
+63180,
+63212,
+63219,
+63236,
+63236,
+63247,
+63298,
+63310,
+63343,
+63343,
+63343,
+63356,
+63356,
+63374,
+63374,
+63374,
+63374,
+63381,
+63401,
+63421,
+63436,
+63459,
+63459,
+63500,
+63506,
+63516,
+63528,
+63551,
+63551,
+63567,
+63615,
+63615,
+63651,
+63679,
+63693,
+63700,
+63734,
+63734,
+63748,
+63763,
+63763,
+63763,
+63775,
+63815,
+63861,
+63884,
+63884,
+63899,
+63907,
+63943,
+63943,
+63950,
+63950,
+63964,
+63964,
+63964,
+63996,
+64003,
+64012,
+64012,
+64106,
+64124,
+64131,
+64131,
+64138,
+64158,
+64158,
+64177,
+64208,
+64208,
+64220,
+64220,
+64220,
+64235,
+64243,
+64258,
+64258,
+64280,
+64290,
+64301,
+64321,
+64334,
+64341,
+64357,
+64400,
+64400,
+64407,
+64407,
+64414,
+64414,
+64433,
+64454,
+64472,
+64502,
+64523,
+64523,
+64582,
+64589,
+64589,
+64619,
+64619,
+64619,
+64619,
+64638,
+64638,
+64638,
+64648,
+64660,
+64660,
+64676,
+64676,
+64695,
+64705,
+64705,
+64732,
+64732,
+64732,
+64738,
+64764,
+64774,
+64787,
+64830,
+64854,
+64888,
+64893,
+64902,
+64938,
+64967,
+64997,
+64997,
+65015,
+65046,
+65072,
+65072,
+65097,
+65110,
+65110,
+65110,
+65110,
+65110,
+65110,
+65122,
+65122,
+65122,
+65129,
+65170,
+65187,
+65187,
+65210,
+65228,
+65235,
+65251,
+65259,
+65259,
+65259,
+65274,
+65274,
+65287,
+65307,
+65323,
+65323,
+65323,
+65362,
+65384,
+65384,
+65400,
+65400,
+65400,
+65400,
+65423,
+65430,
+65457,
+65457,
+65457,
+65476,
+65476,
+65476,
+65476,
+65486,
+65486,
+65521,
+65550,
+65550,
+65550,
+65584,
+65584,
+65584,
+65584,
+65584,
+65601,
+65621,
+65631,
+65672,
+65692,
+65719,
+65719,
+65743,
+65766,
+65766,
+65782,
+65788,
+65828,
+65854,
+65868,
+65877,
+65897,
+65909,
+65936,
+65936,
+65948,
+65948,
+65968,
+65989,
+65989,
+65989,
+65989,
+66016,
+66016,
+66032,
+66039,
+66039,
+66039,
+66055,
+66066,
+66098,
+66114,
+66140,
+66140,
+66174,
+66174,
+66174,
+66220,
+66249,
+66249,
+66249,
+66249,
+66268,
+66276,
+66295,
+66314,
+66322,
+66343,
+66343,
+66343,
+66395,
+66395,
+66413,
+66413,
+66422,
+66430,
+66430,
+66449,
+66449,
+66460,
+66486,
+66492,
+66492,
+66492,
+66492,
+66492,
+66492,
+66510,
+66510,
+66519,
+66530,
+66563,
+66563,
+66573,
+66573,
+66573,
+66612,
+66612,
+66612,
+66625,
+66625,
+66642,
+66642,
+66642,
+66658,
+66672,
+66672,
+66680,
+66715,
+66724,
+66724,
+66740,
+66745,
+66753,
+66769,
+66802,
+66802,
+66802,
+66802,
+66829,
+66843,
+66858,
+66875,
+66893,
+66893,
+66893,
+66933,
+66933,
+66945,
+66945,
+66945,
+66945,
+66956,
+66976,
+66976,
+66976,
+66985,
+67003,
+67003,
+67010,
+67031,
+67031,
+67051,
+67064,
+67083,
+67091,
+67116,
+67116,
+67141,
+67190,
+67220,
+67220,
+67220,
+67233,
+67241,
+67241,
+67275,
+67281,
+67292,
+67302,
+67302,
+67315,
+67379,
+67395,
+67405,
+67421,
+67421,
+67475,
+67483,
+67526,
+67526,
+67546,
+67546,
+67546,
+67571,
+67579,
+67637,
+67659,
+67676,
+67676,
+67676,
+67705,
+67723,
+67739,
+67739,
+67777,
+67792,
+67792,
+67811,
+67811,
+67819,
+67860,
+67876,
+67876,
+67899,
+67915,
+67955,
+67955,
+67969,
+67979,
+67991,
+67991,
+67991,
+68006,
+68020,
+68020,
+68020,
+68045,
+68057,
+68072,
+68072,
+68086,
+68097,
+68113,
+68120,
+68129,
+68136,
+68155,
+68170,
+68170,
+68195,
+68241,
+68258,
+68287,
+68313,
+68325,
+68342,
+68384,
+68416,
+68427,
+68461,
+68461,
+68476,
+68498,
+68498,
+68506,
+68513,
+68533,
+68546,
+68563,
+68563,
+68581,
+68621,
+68634,
+68657,
+68657,
+68657,
+68676,
+68707,
+68726,
+68739,
+68753,
+68753,
+68753,
+68753,
+68765,
+68798,
+68804,
+68819,
+68819,
+68819,
+68847,
+68856,
+68872,
+68872,
+68904,
+68915,
+68942,
+68953,
+68962,
+68980,
+69007,
+69013,
+69024,
+69038,
+69069,
+69082,
+69108,
+69116,
+69134,
+69157,
+69180,
+69180,
+69201,
+69217,
+69217,
+69234,
+69257,
+69257,
+69257,
+69312,
+69312,
+69330,
+69343,
+69360,
+69360,
+69383,
+69402,
+69423,
+69434,
+69455,
+69455,
+69488,
+69496,
+69541,
+69559,
+69559,
+69578,
+69587,
+69587,
+69622,
+69622,
+69630,
+69654,
+69667,
+69674,
+69685,
+69696,
+69734,
+69749,
+69759,
+69759,
+69759,
+69759,
+69790,
+69805,
+69805,
+69823,
+69823,
+69823,
+69839,
+69861,
+69871,
+69871,
+69871,
+69916,
+69916,
+69931,
+69931,
+69931,
+69931,
+69949,
+70014,
+70026,
+70026,
+70026,
+70050,
+70077,
+70113,
+70152,
+70165,
+70182,
+70191,
+70191,
+70191,
+70206,
+70206,
+70206,
+70206,
+70206,
+70230,
+70230,
+70230,
+70230,
+70244,
+70244,
+70244,
+70251,
+70251,
+70251,
+70288,
+70315,
+70357,
+70363,
+70363,
+70376,
+70376,
+70387,
+70387,
+70397,
+70397,
+70397,
+70434,
+70460,
+70476,
+70476,
+70476,
+70507,
+70507,
+70515,
+70534,
+70534,
+70554,
+70570,
+70580,
+70594,
+70623,
+70623,
+70641,
+70641,
+70641,
+70641,
+70641,
+70674,
+70704,
+70735,
+70735,
+70735,
+70748,
+70748,
+70757,
+70802,
+70852,
+70873,
+70873,
+70892,
+70923,
+70923,
+70935,
+70935,
+70941,
+70941,
+70960,
+70980,
+70980,
+71023,
+71034,
+71034,
+71034,
+71045,
+71045,
+71045,
+71045,
+71045,
+71083,
+71093,
+71115,
+71115,
+71131,
+71131,
+71131,
+71141,
+71148,
+71148,
+71166,
+71186,
+71186,
+71201,
+71209,
+71209,
+71238,
+71246,
+71246,
+71246,
+71246,
+71258,
+71258,
+71258,
+71258,
+71276,
+71276,
+71276,
+71291,
+71309,
+71309,
+71309,
+71309,
+71318,
+71318,
+71318,
+71332,
+71342,
+71342,
+71356,
+71388,
+71388,
+71397,
+71407,
+71407,
+71407,
+71425,
+71436,
+71436,
+71466,
+71466,
+71491,
+71491,
+71527,
+71540,
+71540,
+71560,
+71584,
+71600,
+71600,
+71632,
+71648,
+71678,
+71689,
+71703,
+71703,
+71727,
+71742,
+71742,
+71742,
+71759,
+71759,
+71774,
+71780,
+71780,
+71780,
+71799,
+71819,
+71819,
+71837,
+71849,
+71867,
+71867,
+71867,
+71867,
+71867,
+71867,
+71867,
+71867,
+71867,
+71890,
+71890,
+71941,
+71941,
+71972,
+72002,
+72016,
+72037,
+72053,
+72053,
+72053,
+72053,
+72106,
+72131,
+72131,
+72131,
+72152,
+72159,
+72159,
+72171,
+72176,
+72207,
+72207,
+72207,
+72207,
+72221,
+72221,
+72237,
+72264,
+72264,
+72264,
+72280,
+72289,
+72307,
+72326,
+72343,
+72343,
+72343,
+72370,
+72370,
+72370,
+72370,
+72370,
+72396,
+72402,
+72402,
+72402,
+72430,
+72430,
+72449,
+72489,
+72499,
+72499,
+72550,
+72550,
+72573,
+72588,
+72623,
+72623,
+72623,
+72641,
+72652,
+72670,
+72684,
+72684,
+72684,
+72684,
+72699,
+72699,
+72699,
+72699,
+72699,
+72718,
+72769,
+72774,
+72786,
+72799,
+72799,
+72799,
+72837,
+72867,
+72915,
+72935,
+72935,
+72935,
+72953,
+72973,
+72973,
+72973,
+72973,
+73005,
+73005,
+73018,
+73018,
+73028,
+73058,
+73068,
+73068,
+73090,
+73102,
+73114,
+73142,
+73180,
+73180,
+73223,
+73247,
+73247,
+73247,
+73247,
+73247,
+73247,
+73247,
+73256,
+73256,
+73304,
+73321,
+73328,
+73328,
+73328,
+73389,
+73405,
+73405,
+73425,
+73425,
+73425,
+73443,
+73460,
+73476,
+73476,
+73498,
+73518,
+73533,
+73563,
+73591,
+73628,
+73628,
+73648,
+73667,
+73736,
+73736,
+73736,
+73756,
+73756,
+73756,
+73803,
+73803,
+73803,
+73803,
+73831,
+73863,
+73875,
+73875,
+73875,
+73875,
+73875,
+73908,
+73931,
+73942,
+73942,
+73953,
+73982,
+74007,
+74066,
+74075,
+74075,
+74108,
+74108,
+74108,
+74114,
+74167,
+74178,
+74178,
+74178,
+74199,
+74199,
+74218,
+74218,
+74248,
+74248,
+74248,
+74248,
+74248,
+74272,
+74272,
+74290,
+74326,
+74349,
+74349,
+74349,
+74367,
+74367,
+74367,
+74385,
+74410,
+74429,
+74429,
+74475,
+74497,
+74497,
+74513,
+74527,
+74551,
+74581,
+74581,
+74581,
+74638,
+74644,
+74644,
+74665,
+74691,
+74691,
+74691,
+74691,
+74701,
+74701,
+74708,
+74721,
+74721,
+74721,
+74761,
+74801,
+74801,
+74808,
+74825,
+74833,
+74833,
+74850,
+74870,
+74870,
+74893,
+74893,
+74928,
+74928,
+74928,
+74928,
+74938,
+74938,
+74938,
+74938,
+74938,
+74938,
+74938,
+74938,
+74949,
+74949,
+74981,
+75000,
+75019,
+75029,
+75029,
+75029,
+75044,
+75054,
+75071,
+75071,
+75089,
+75103,
+75103,
+75103,
+75103,
+75103,
+75103,
+75103,
+75103,
+75103,
+75103,
+75120,
+75120,
+75120,
+75120,
+75165,
+75165,
+75165,
+75165,
+75185,
+75191,
+75208,
+75208,
+75236,
+75252,
+75269,
+75292,
+75311,
+75318,
+75318,
+75344,
+75359,
+75359,
+75359,
+75423,
+75423,
+75444,
+75444,
+75444,
+75457,
+75464,
+75476,
+75493,
+75516,
+75516,
+75516,
+75532,
+75539};
-static const char tldData[] = {
-"com.cn\0"
-"com.co\0"
-"hb.cn\0"
-"med.br\0conf.lv\0wallonie.museum\0"
-"namsos.no\0"
-"\xe7\xb6\xb2\xe7\xbb\x9c.hk\0farmers.museum\0rel.pl\0"
-"com.cu\0"
-"military.museum\0"
-"*.jm\0convent.museum\0cymru.museum\0malvik.no\0"
-"univ.sn\0"
-"gliding.aero\0"
-"wodzislaw.pl\0"
-"com.dm\0!pref.iwate.jp\0tran\xc3\xb8y.no\0pila.pl\0"
-"mb.it\0*.ke\0lib.ri.us\0"
-"com.ec\0*.kh\0tr\xc3\xb8gstad.no\0"
-"com.ee\0"
-"mobi.gp\0"
+static const char *tldData[] = {
+"vgs.no\0ah.no\0"
+"ma.us\0"
+"mizunami.gifu.jp\0"
+"saitama.jp\0kimino.wakayama.jp\0"
+"int.bo\0cambridge.museum\0"
+"andasuolo.no\0lardal.no\0"
+"transport.museum\0"
+"nishinomiya.hyogo.jp\0"
+"is-into-cars.com\0"
+"karlsoy.no\0"
+"bungoono.oita.jp\0"
+"int.ci\0"
+"chikujo.fukuoka.jp\0"
+"aisai.aichi.jp\0"
+"os.hedmark.no\0"
+"int.co\0"
+"komaki.aichi.jp\0seki.gifu.jp\0"
+"wanouchi.gifu.jp\0lib.ri.us\0"
+"higashiosaka.osaka.jp\0"
+"org\0cechire.com\0"
+"satte.saitama.jp\0"
+"berg.no\0"
+"saitama.saitama.jp\0"
+"cc.sd.us\0"
+"act.gov.au\0mansion.museum\0"
+"fe.it\0y.se\0"
+"gunma.jp\0"
+"otoyo.kochi.jp\0miyoshi.saitama.jp\0"
+"sa.gov.au\0"
+"online.museum\0"
+"abiko.chiba.jp\0"
+"!educ.ar\0"
+"agematsu.nagano.jp\0"
+"akiruno.tokyo.jp\0lund.no\0"
+"kasuga.hyogo.jp\0"
+"nakano.tokyo.jp\0homeunix.net\0"
+"ambulance.aero\0sv.it\0"
+"shiso.hyogo.jp\0"
+"fuso.aichi.jp\0delmenhorst.museum\0"
+"dali.museum\0"
+"brindisi.it\0"
+"midori.gunma.jp\0"
+"nantan.kyoto.jp\0"
+"takaishi.osaka.jp\0imizu.toyama.jp\0"
+"tonsberg.no\0"
+"countryestate.museum\0"
+"rawa-maz.pl\0"
+"yokoshibahikari.chiba.jp\0"
+"ontario.museum\0"
+"certification.aero\0"
+"franziskaner.museum\0cc.nj.us\0"
+"genkai.saga.jp\0"
+"tysfjord.no\0"
+"ra.it\0"
+"air-traffic-control.aero\0ina.ibaraki.jp\0"
+"in-the-band.net\0"
+"ainan.ehime.jp\0oita.oita.jp\0!national-library-scotland.uk\0"
+"kamiichi.toyama.jp\0"
+"ogata.akita.jp\0smola.no\0"
+"matsushima.miyagi.jp\0langev\xc3\xa5g.no\0"
+"vard\xc3\xb8.no\0"
+"limanowa.pl\0"
+"is-a-bruinsfan.org\0"
+"yufu.oita.jp\0berkeley.museum\0"
+"torino.it\0per.la\0"
+"noheji.aomori.jp\0koebenhavn.museum\0isa-geek.com\0"
+"choyo.kumamoto.jp\0"
+"s\xc3\xb8r-odal.no\0"
+"int.is\0bir.ru\0"
+"jefferson.museum\0"
+"brasil.museum\0"
+"sologne.museum\0"
+"shimosuwa.nagano.jp\0setagaya.tokyo.jp\0"
+"tokoname.aichi.jp\0lerdal.no\0"
+"!retina.ar\0boston.museum\0"
+"bologna.it\0kimobetsu.hokkaido.jp\0yuzawa.niigata.jp\0"
+"obuse.nagano.jp\0gs.svalbard.no\0"
+"furudono.fukushima.jp\0"
+"isla.pr\0ny.us\0"
+"5.bg\0"
+"lt.ua\0"
"gran.no\0"
-"wa.gov.au\0"
-"com.dz\0kg.kr\0"
-"zoological.museum\0gjerstad.no\0haugesund.no\0kharkov.ua\0"
-"walbrzych.pl\0"
-"civilization.museum\0"
-"ha.no\0"
-"*.kw\0"
-"med.ec\0com.es\0"
-"med.ee\0otago.museum\0svelvik.no\0"
-"art.ht\0amber.museum\0elvendrell.museum\0rost.no\0"
-"jx.cn\0gratangen.no\0"
-"association.aero\0ca.it\0"
-"zaporizhzhe.ua\0"
-"com.fr\0"
-"szex.hu\0"
-"e-burg.ru\0"
-"com.ge\0bokn.no\0"
+"per.nf\0"
+"int.la\0"
+"kumakogen.ehime.jp\0nasu.tochigi.jp\0"
+"shirataka.yamagata.jp\0"
+"vet.br\0graz.museum\0"
+"int.lk\0"
+"plc.co.im\0md.us\0k12.gu.us\0"
+"wildlife.museum\0"
+"stokke.no\0"
+"stordal.no\0oskol.ru\0"
+"kosaka.akita.jp\0"
+"kitami.hokkaido.jp\0"
+"higashimatsuyama.saitama.jp\0"
+"s\xc3\xb8rreisa.no\0poznan.pl\0"
+"\xd1\x81\xd1\x80\xd0\xb1\0"
+"tokuyama.yamaguchi.jp\0"
+"tosa.kochi.jp\0est-le-patron.com\0"
+"hachijo.tokyo.jp\0"
+"ibaraki.osaka.jp\0rindal.no\0"
+"taishi.osaka.jp\0ol.no\0"
+"int.mv\0lib.az.us\0"
+"int.mw\0hjartdal.no\0"
+"imb.br\0\xc3\xb8ksnes.no\0"
+"ishikawa.jp\0osen.no\0"
+"nakamura.kochi.jp\0"
+"seiyo.ehime.jp\0mincom.tn\0"
+"chieti.it\0sakado.saitama.jp\0"
+"enebakk.no\0cc.ca.us\0from-hi.com\0"
+"kokonoe.oita.jp\0auto.pl\0"
+"venice.it\0shimada.shizuoka.jp\0"
+"surrey.museum\0"
+"audnedaln.no\0"
+"minamifurano.hokkaido.jp\0axis.museum\0webhop.info\0"
+"is-not-certified.com\0"
+"volda.no\0"
+"is-a-lawyer.com\0"
+"oga.akita.jp\0"
+"higashimatsushima.miyagi.jp\0"
+"tonaki.okinawa.jp\0"
+"somna.no\0rovno.ua\0"
+"nt.gov.au\0"
+"cc.pr.us\0"
+"cs.it\0bieszczady.pl\0"
+"per.sg\0"
+"research.museum\0endoftheinternet.org\0"
+"int.pt\0"
+"costume.museum\0"
+"eisenbahn.museum\0slask.pl\0"
+"gdynia.pl\0"
+"wa.au\0pol.dz\0fukui.jp\0higashishirakawa.gifu.jp\0botanicalgarden.museum\0"
+"automotive.museum\0"
+"sshn.se\0"
+"nogata.fukuoka.jp\0cc.nm.us\0is-an-anarchist.com\0"
+"dontexist.com\0"
+"an.it\0"
+"uenohara.yamanashi.jp\0"
+"midtre-gauldal.no\0"
+"hm.no\0komvux.se\0"
+"hidaka.wakayama.jp\0hobby-site.org\0"
+"giske.no\0"
+"sund.no\0"
+"troms\xc3\xb8.no\0"
+"zagan.pl\0"
+"chikusei.ibaraki.jp\0wlocl.pl\0"
+"in-addr.arpa\0notaires.fr\0altai.ru\0"
+"int.ru\0"
+"aquila.it\0"
+"int.rw\0"
+"ito.shizuoka.jp\0"
+"missoula.museum\0kolobrzeg.pl\0"
+"assabu.hokkaido.jp\0"
+"sld.do\0meloy.no\0"
+"ak.us\0"
+"k12.md.us\0"
+"kawanishi.yamagata.jp\0is-lost.org\0"
+"ochi.kochi.jp\0"
+"amami.kagoshima.jp\0gamo.shiga.jp\0"
+"yamazoe.nara.jp\0"
+"shirako.chiba.jp\0matsuda.kanagawa.jp\0int.tj\0"
+"ota.tokyo.jp\0"
+"kicks-ass.net\0"
+"yamato.fukushima.jp\0shinjo.okayama.jp\0baltimore.museum\0ushistory.museum\0pro\0"
+"mallorca.museum\0hoyanger.no\0hobby-site.com\0"
+"narvik.no\0olsztyn.pl\0warmia.pl\0"
+"pol.ht\0int.tt\0"
+"mizusawa.iwate.jp\0h\xc3\xb8yanger.no\0przeworsk.pl\0"
+"matsuno.ehime.jp\0"
+"folkebibl.no\0"
+"pb.ao\0taranto.it\0nomi.ishikawa.jp\0chizu.tottori.jp\0alta.no\0"
+"8.bg\0okazaki.aichi.jp\0"
+"goshiki.hyogo.jp\0lib.wi.us\0"
+"or.at\0"
+"stateofdelaware.museum\0"
+"modern.museum\0"
+"\xd1\x80\xd1\x84\0"
+"or.bi\0himi.toyama.jp\0"
+"kitaaiki.nagano.jp\0toga.toyama.jp\0"
+"kutchan.hokkaido.jp\0tamaki.mie.jp\0finnoy.no\0int.vn\0"
+"fujisawa.iwate.jp\0"
+"homebuilt.aero\0cranbrook.museum\0"
+"kv\xc3\xa6""fjord.no\0"
+"or.ci\0saigawa.fukuoka.jp\0kutno.pl\0"
+"asuke.aichi.jp\0kanonji.kagawa.jp\0"
+"higashikagawa.kagawa.jp\0"
+"inashiki.ibaraki.jp\0matta-varjjat.no\0"
+"lviv.ua\0"
+"or.cr\0mitane.akita.jp\0"
+"*.kitakyushu.jp\0fujikawa.shizuoka.jp\0"
+"egersund.no\0"
+"srv.br\0"
+"belgorod.ru\0"
+"v\xc3\xa5gs\xc3\xb8y.no\0fh.se\0"
+"tsuruta.aomori.jp\0shibuya.tokyo.jp\0k12.va.us\0"
+"kamishihoro.hokkaido.jp\0"
+"sogne.no\0"
+"turystyka.pl\0"
+"gujo.gifu.jp\0"
+"experts-comptables.fr\0"
+"yame.fukuoka.jp\0"
+"annaka.gunma.jp\0kawagoe.mie.jp\0"
+"wakayama.jp\0"
+"openair.museum\0operaunite.com\0"
+"wakuya.miyagi.jp\0"
+"bjarkoy.no\0ivano-frankivsk.ua\0dyndns.tv\0is-a-linux-user.org\0"
+"olbiatempio.it\0"
+"etne.no\0fosnes.no\0"
+"ginoza.okinawa.jp\0"
+"krager\xc3\xb8.no\0"
+"vn.ua\0"
+"jx.cn\0bill.museum\0home.dyndns.org\0"
+"lecco.it\0bihoro.hokkaido.jp\0"
+"asaka.saitama.jp\0"
+"tagajo.miyagi.jp\0"
+"maintenance.aero\0"
+"nordreisa.no\0"
+"kamogawa.chiba.jp\0nebraska.museum\0"
+"lib.nm.us\0"
+"r\xc3\xa1isa.no\0"
+"historisch.museum\0"
+"is-a-republican.com\0"
+"prd.fr\0yonaguni.okinawa.jp\0"
+"bristol.museum\0crafts.museum\0blogsite.org\0"
+"kasamatsu.gifu.jp\0"
+"fin.ec\0"
+"slg.br\0seirou.niigata.jp\0cahcesuolo.no\0from-ma.com\0"
+"ba.it\0aq.it\0exhibition.museum\0heimatunduhren.museum\0"
+"rg.it\0dyndns.ws\0"
+"homedns.org\0"
+"kakogawa.hyogo.jp\0"
+"chikushino.fukuoka.jp\0mito.ibaraki.jp\0"
+"dc.us\0"
+"terni.it\0"
+"or.id\0yoshida.shizuoka.jp\0"
+"fukaya.saitama.jp\0rost.no\0"
+"aomori.jp\0"
+"aeroport.fr\0sabae.fukui.jp\0geology.museum\0"
+"yakage.okayama.jp\0rahkkeravju.no\0"
+"kasama.ibaraki.jp\0"
+"frana.no\0"
+"hatoyama.saitama.jp\0za.org\0"
+"kitayama.wakayama.jp\0"
+"bilbao.museum\0"
+"or.it\0"
+"!nawrastelecom.om\0"
+"nanjo.okinawa.jp\0k12.me.us\0"
+"mobi.gp\0"
+"daisen.akita.jp\0bizen.okayama.jp\0hembygdsforbund.museum\0salangen.no\0"
+"yoshikawa.saitama.jp\0homelinux.com\0"
+"or.jp\0farmers.museum\0from-ri.com\0"
+"\xe1\x83\x92\xe1\x83\x94\0"
+"\xc3\xa5snes.no\0"
+"assisi.museum\0muos\xc3\xa1t.no\0kemerovo.ru\0"
+"musashino.tokyo.jp\0"
+"sld.pa\0"
+"kushimoto.wakayama.jp\0virginia.museum\0is-a-financialadvisor.com\0"
+"yuasa.wakayama.jp\0"
+"yachimata.chiba.jp\0"
+"\xc3\xa5seral.no\0klabu.no\0"
+"onna.okinawa.jp\0"
+"hikone.shiga.jp\0or.kr\0"
+"tranby.no\0lib.vt.us\0"
+"carrier.museum\0"
+"isa-geek.net\0"
+"orsta.no\0"
+"toyone.aichi.jp\0fortmissoula.museum\0zoology.museum\0"
+"historicalsociety.museum\0"
+"prd.km\0"
+"iheya.okinawa.jp\0"
+"kongsberg.no\0"
+"dreamhosters.com\0"
+"chicago.museum\0gjerdrum.no\0"
+"pe.ca\0"
+"cpa.pro\0"
+"makurazaki.kagoshima.jp\0mashiki.kumamoto.jp\0"
+"sondrio.it\0masaki.ehime.jp\0"
+"numazu.shizuoka.jp\0"
+"kawanishi.nara.jp\0"
+"futaba.fukushima.jp\0nachikatsuura.wakayama.jp\0"
+"airguard.museum\0"
+"society.museum\0"
+"ulm.museum\0"
+"or.na\0"
+"tohma.hokkaido.jp\0"
+"masoy.no\0"
+"or.mu\0"
+"prd.mg\0"
+"!omanpost.om\0"
+"izumizaki.fukushima.jp\0nishikatsura.yamanashi.jp\0"
+"miyazu.kyoto.jp\0"
+"unj\xc3\xa1rga.no\0"
+"noshiro.akita.jp\0"
+"ryokami.saitama.jp\0"
+"carboniaiglesias.it\0homeunix.org\0"
+"australia.museum\0"
+"sowa.ibaraki.jp\0"
+"urausu.hokkaido.jp\0"
+"kaisei.kanagawa.jp\0"
+"vt.it\0"
+"virtual.museum\0"
+"hs.kr\0brand.se\0"
+"daejeon.kr\0seaport.museum\0"
+"takaoka.toyama.jp\0"
+"kitakata.fukushima.jp\0fribourg.museum\0"
+"montreal.museum\0"
+"higashiyama.kyoto.jp\0\xd8\xa7\xd9\x84\xd8\xb3\xd8\xb9\xd9\x88\xd8\xaf\xd9\x8a\xd9\x87\0"
+"chitose.hokkaido.jp\0"
+"engine.aero\0"
+"rome.it\0medical.museum\0"
+"tjome.no\0"
+"asti.it\0reggio-calabria.it\0"
+"or.pw\0"
+"to.it\0murayama.yamagata.jp\0"
+"shiraoi.hokkaido.jp\0"
+"joshkar-ola.ru\0"
+"fetsund.no\0wa.us\0"
+"nakaniikawa.toyama.jp\0wroclaw.pl\0lib.nh.us\0"
+"ragusa.it\0nakanojo.gunma.jp\0r\xc3\xa5""de.no\0barrell-of-knowledge.info\0"
+"yuza.yamagata.jp\0moareke.no\0cv.ua\0"
+"anjo.aichi.jp\0"
+"!omanmobile.om\0"
+"fukuroi.shizuoka.jp\0space-to-rent.com\0"
+"torahime.shiga.jp\0"
+"gojome.akita.jp\0"
+"at.it\0yawara.ibaraki.jp\0"
+"\xd8\xa7\xd9\x84\xd8\xb3\xd8\xb9\xd9\x88\xd8\xaf\xd9\x8a\xd8\xa9\0"
+"okutama.tokyo.jp\0naturbruksgymn.se\0est-mon-blogueur.com\0"
+"gj\xc3\xb8vik.no\0"
+"marylhurst.museum\0"
+"ferrara.it\0"
+"shimonita.gunma.jp\0"
+"chernivtsi.ua\0"
+"yusuhara.kochi.jp\0"
+"indianmarket.museum\0from-nm.com\0"
+"chambagri.fr\0"
+"yono.saitama.jp\0romsa.no\0"
+"lucerne.museum\0"
+"pe.it\0"
+"from-mn.com\0"
+"kurgan.ru\0or.th\0"
+"udmurtia.ru\0"
+"k12.nj.us\0"
+"c.bg\0atami.shizuoka.jp\0"
+"herad.no\0"
+"midatlantic.museum\0"
+"\xd1\x83\xd0\xba\xd1\x80\0"
+"inazawa.aichi.jp\0matsumoto.nagano.jp\0francaise.museum\0horten.no\0"
+"isehara.kanagawa.jp\0"
+"fuji.shizuoka.jp\0or.ug\0"
+"oppdal.no\0"
+"or.tz\0\xd9\x82\xd8\xb7\xd8\xb1\0"
+"!nacion.ar\0shiroi.chiba.jp\0muncie.museum\0from-ct.com\0"
+"television.museum\0doomdns.com\0"
+"bod\xc3\xb8.no\0"
+"seihi.nagasaki.jp\0"
+"memorial.museum\0"
+"slupsk.pl\0"
+"arkhangelsk.ru\0or.us\0"
+"pe.kr\0is-a-bulls-fan.com\0"
+"matsubara.osaka.jp\0"
+"ishigaki.okinawa.jp\0"
+"nysa.pl\0from-nv.com\0"
+"ishikawa.fukushima.jp\0"
+"drobak.no\0"
+"stpetersburg.museum\0"
+"andria-trani-barletta.it\0"
+"aibetsu.hokkaido.jp\0plants.museum\0silk.museum\0holtalen.no\0"
+"lakas.hu\0"
+"gs.of.no\0rauma.no\0"
+"modena.it\0"
+"kh.ua\0"
+"togitsu.nagasaki.jp\0"
+"newhampshire.museum\0"
+"oirase.aomori.jp\0grajewo.pl\0fin.tn\0"
+"depot.museum\0"
+"nayoro.hokkaido.jp\0"
+"forgot.her.name\0"
+"sande.more-og-romsdal.no\0"
+"reklam.hu\0"
+"\xc3\xa5krehamn.no\0"
+"ancona.it\0h\xc3\xa5.no\0"
+"lib.as.us\0"
+"marketplace.aero\0schweiz.museum\0"
+"eu.int\0"
+"urasoe.okinawa.jp\0"
+"kaluga.ru\0"
+"godo.gifu.jp\0"
+"kitagawa.kochi.jp\0kr.com\0"
+"pvt.ge\0"
+"usuki.oita.jp\0"
+"mino.gifu.jp\0"
+"rovigo.it\0"
+"yamada.fukuoka.jp\0amakusa.kumamoto.jp\0lajolla.museum\0uzhgorod.ua\0"
+"shimane.jp\0workshop.museum\0"
+"aero\0"
+"shikatsu.aichi.jp\0warszawa.pl\0"
+"wegrow.pl\0"
+"koga.fukuoka.jp\0"
+"funabashi.chiba.jp\0moriya.ibaraki.jp\0yamaga.kumamoto.jp\0"
+"act.edu.au\0mbone.pl\0"
+"ikaruga.nara.jp\0"
+"shinichi.hiroshima.jp\0gjesdal.no\0"
+"hanawa.fukushima.jp\0"
+"tr.it\0wakasa.fukui.jp\0"
+"\xe0\xa6\xac\xe0\xa6\xbe\xe0\xa6\x82\xe0\xa6\xb2\xe0\xa6\xbe\0"
+"olbia-tempio.it\0"
+"aizumisato.fukushima.jp\0convent.museum\0bd.se\0"
+"fukuchi.fukuoka.jp\0takino.hyogo.jp\0vt.us\0"
+"yazu.tottori.jp\0"
+"kagoshima.jp\0loyalist.museum\0"
+"kitahiroshima.hokkaido.jp\0fed.us\0"
+"sandnessj\xc3\xb8""en.no\0varoy.no\0"
+"hurdal.no\0"
+"salem.museum\0jar.ru\0"
+"yaizu.shizuoka.jp\0"
+"cc.nv.us\0"
+"airtraffic.aero\0"
+"bg.it\0sukumo.kochi.jp\0"
+"rm.it\0nishiokoppe.hokkaido.jp\0"
+"house.museum\0"
+"aizumi.tokushima.jp\0"
+"hitachinaka.ibaraki.jp\0kicks-ass.org\0"
+"hokuryu.hokkaido.jp\0k12.or.us\0"
+"geisei.kochi.jp\0tatarstan.ru\0"
+"toyotsu.fukuoka.jp\0meguro.tokyo.jp\0"
+"myoko.niigata.jp\0"
+"bronnoy.no\0"
+"nishikawa.yamagata.jp\0"
+"minamata.kumamoto.jp\0"
+"gd.cn\0"
+"trana.no\0"
+"takasaki.gunma.jp\0cc.ma.us\0"
+"trani-barletta-andria.it\0"
+"\xe0\xaa\xad\xe0\xaa\xbe\xe0\xaa\xb0\xe0\xaa\xa4\0c.la\0"
+"hanno.saitama.jp\0"
+"ami.ibaraki.jp\0kurotaki.nara.jp\0"
+"\xd8\xa7\xdb\x8c\xd8\xb1\xd8\xa7\xd9\x86.ir\0boldlygoingnowhere.org\0"
+"f.bg\0unjarga.no\0lib.ia.us\0"
+"\xc3\xb8rskog.no\0tingvoll.no\0"
+"webhop.org\0"
+"grue.no\0dyndns-blog.com\0"
+"dyndns-web.com\0"
+"zakopane.pl\0"
+"britishcolumbia.museum\0turek.pl\0"
+"omi.nagano.jp\0is-an-actor.com\0"
+"ms.it\0gov.nc.tr\0"
+"kijo.miyazaki.jp\0"
+"starostwo.gov.pl\0mobi.tt\0"
+"gs.ah.no\0"
+"minobu.yamanashi.jp\0tr.no\0"
+"mobi.tz\0"
+"rakkestad.no\0"
+"org.ac\0from-az.net\0"
+"org.ae\0"
+"org.af\0bj.cn\0"
+"org.ag\0"
+"org.ai\0"
+"nanae.hokkaido.jp\0oshino.yamanashi.jp\0"
+"org.al\0takashima.shiga.jp\0"
+"org.an\0naha.okinawa.jp\0matsuzaki.shizuoka.jp\0bahn.museum\0"
+"chungbuk.kr\0biev\xc3\xa1t.no\0homelinux.net\0"
+"org.ba\0umi.fukuoka.jp\0"
+"org.bb\0"
+"mihama.wakayama.jp\0cyber.museum\0"
+"org.au\0yorii.saitama.jp\0hagi.yamaguchi.jp\0"
+"ms.kr\0"
+"org.bh\0fujikawa.yamanashi.jp\0floro.no\0oryol.ru\0"
+"org.bi\0sakahogi.gifu.jp\0"
+"org.az\0niimi.okayama.jp\0"
+"aguni.okinawa.jp\0sells-for-less.com\0"
+"org.bm\0tsukuba.ibaraki.jp\0"
+"org.bo\0"
+"org.br\0r\xc3\xa6lingen.no\0"
+"org.bs\0kuriyama.hokkaido.jp\0"
+"org.bt\0"
+"org.bw\0"
+"nf.ca\0"
+"org.ci\0"
+"org.bz\0"
+"hirogawa.wakayama.jp\0"
"mordovia.ru\0"
-"com.gh\0*.mm\0"
-"com.gi\0z.se\0"
-"cahcesuolo.no\0"
-"hurdal.no\0joshkar-ola.ru\0"
-"cadaques.museum\0ma.us\0"
-"a.bg\0"
-"com.gn\0bozen.it\0tambov.ru\0"
-"*.gifu.jp\0*.tokyo.jp\0*.mt\0"
-"com.gp\0travel\0cc.tx.us\0"
-"com.gr\0hemne.no\0"
-"*.ni\0"
-"*.mz\0"
-"cc.il.us\0"
-"com.gy\0"
-"zj.cn\0oksnes.no\0museum.tt\0"
-"com.hk\0*.np\0"
-"rc.it\0baseball.museum\0"
-"com.hn\0exhibition.museum\0"
-"h\xc3\xa1""bmer.no\0"
+"org.cn\0k12.vt.us\0"
+"org.co\0"
+"if.ua\0"
+"org.cu\0"
+"futsu.nagasaki.jp\0hu.net\0"
+"dyndns-pics.com\0"
+"karumai.iwate.jp\0"
+"org.dm\0"
+"org.do\0"
+"risor.no\0"
+"kujukuri.chiba.jp\0abashiri.hokkaido.jp\0novosibirsk.ru\0"
+"org.ec\0"
+"ballangen.no\0k12.co.us\0"
+"org.ee\0"
+"navuotna.no\0pisz.pl\0"
+"org.eg\0"
+"mobi.na\0"
+"tonami.toyama.jp\0"
+"org.dz\0sci.eg\0\xc3\xa5rdal.no\0"
+"environmentalconservation.museum\0edunet.tn\0"
+"murakami.niigata.jp\0usarts.museum\0"
+"eidfjord.no\0e-burg.ru\0from-mt.com\0from-nd.com\0"
+"karasuyama.tochigi.jp\0utah.museum\0"
+"maritimo.museum\0"
+"union.aero\0org.es\0"
+"esan.hokkaido.jp\0"
+"namegawa.saitama.jp\0c.se\0"
+"anamizu.ishikawa.jp\0kitakami.iwate.jp\0"
+"ga.us\0"
+"qld.au\0gjemnes.no\0"
+"ichinoseki.iwate.jp\0makinohara.shizuoka.jp\0"
+"bahccavuotna.no\0"
+"is-an-actress.com\0"
+"karm\xc3\xb8y.no\0"
+"org.ge\0cesena-forli.it\0"
+"vantaa.museum\0gaular.no\0"
+"org.gg\0"
+"org.gh\0cc.ny.us\0"
+"org.gi\0"
+"from-dc.com\0"
+"fitjar.no\0vyatka.ru\0"
+"org.gn\0museum\0"
+"org.gp\0"
+"org.gr\0beppu.oita.jp\0"
+"groundhandling.aero\0org.gt\0okegawa.saitama.jp\0lib.ky.us\0"
+"org.hk\0"
+"org.hn\0"
+"presidio.museum\0cc.md.us\0"
+"bolzano.it\0"
+"sosa.chiba.jp\0koenig.ru\0iki.fi\0"
+"org.ht\0ebetsu.hokkaido.jp\0"
+"fuel.aero\0org.hu\0"
+"hole.no\0"
+"blog.br\0tosu.saga.jp\0"
+"k12.nh.us\0"
+"i.bg\0"
+"rs.ba\0"
+"org.im\0"
+"org.in\0"
+"org.iq\0"
+"lel.br\0org.ir\0kasahara.gifu.jp\0"
+"org.is\0chofu.tokyo.jp\0notodden.no\0"
+"org.je\0spjelkavik.no\0"
+"vefsn.no\0"
+"fukuoka.jp\0yamanobe.yamagata.jp\0yamanakako.yamanashi.jp\0"
+"yaese.okinawa.jp\0"
+"baikal.ru\0"
+"from-me.org\0"
+"kanazawa.ishikawa.jp\0nowaruda.pl\0"
+"swidnica.pl\0"
+"org.jo\0!city.yokohama.jp\0olkusz.pl\0"
+"higashiura.aichi.jp\0mosjoen.no\0"
+"vestv\xc3\xa5g\xc3\xb8y.no\0"
+"takahama.aichi.jp\0dyn-o-saur.com\0"
+"shimabara.nagasaki.jp\0"
+"ebiz.tw\0"
+"caserta.it\0org.kg\0"
+"sc.cn\0org.ki\0"
+"aizuwakamatsu.fukushima.jp\0is-a-teacher.com\0"
+"sado.niigata.jp\0org.km\0resistance.museum\0"
+"togo.aichi.jp\0org.kn\0skien.no\0"
+"org.kp\0"
+"org.la\0kommune.no\0"
+"vic.edu.au\0miyoshi.aichi.jp\0org.lb\0"
+"org.lc\0"
+"cagliari.it\0"
+"uscountryestate.museum\0h\xc3\xb8nefoss.no\0"
+"gs.ol.no\0"
+"riik.ee\0"
+"g12.br\0ms.us\0nc.us\0"
+"org.ky\0agro.pl\0"
+"org.kz\0landes.museum\0doesntexist.com\0"
+"org.lk\0"
+"holt\xc3\xa5len.no\0"
+"nedre-eiker.no\0"
+"org.ma\0naroy.no\0"
+"org.lr\0"
+"org.ls\0"
+"tagawa.fukuoka.jp\0"
+"org.me\0"
+"nonoichi.ishikawa.jp\0org.lv\0"
+"org.mg\0horology.museum\0"
+"utazas.hu\0ako.hyogo.jp\0"
+"org.ly\0"
+"org.mk\0sandnes.no\0"
+"ayabe.kyoto.jp\0org.ml\0"
+"office-on-the.net\0"
+"minato.tokyo.jp\0org.mn\0"
+"org.mo\0"
+"koryo.nara.jp\0"
+"org.na\0balsfjord.no\0"
+"org.mu\0"
+"hyuga.miyazaki.jp\0org.mv\0"
+"perso.ht\0org.mw\0org.ng\0"
+"org.mx\0"
+"org.my\0"
+"powiat.pl\0"
+"kinokawa.wakayama.jp\0"
+"shichinohe.aomori.jp\0"
+"ru.com\0se.com\0"
+"org.nr\0"
+"environment.museum\0planetarium.museum\0"
+"niigata.niigata.jp\0"
+"name.hr\0"
+"asago.hyogo.jp\0is-very-nice.org\0"
+"hirata.fukushima.jp\0"
+"sera.hiroshima.jp\0shizuoka.shizuoka.jp\0"
+"nrw.museum\0"
+"palace.museum\0"
+"org.pa\0"
+"cc.ak.us\0"
+"wiki.br\0"
+"shimotsuke.tochigi.jp\0org.pe\0press.se\0"
+"org.pf\0"
+"nishiizu.shizuoka.jp\0f.se\0"
+"org.ph\0"
+"is-a-llama.com\0"
+"kamikawa.saitama.jp\0elblag.pl\0"
+"kochi.jp\0gs.hm.no\0org.pk\0"
+"org.pl\0"
+"paleo.museum\0"
+"org.pn\0"
+"torsken.no\0"
+"iwafune.tochigi.jp\0org.qa\0"
+"org.pr\0"
+"org.ps\0"
+"bato.tochigi.jp\0org.pt\0"
+"isumi.chiba.jp\0and\xc3\xb8y.no\0"
+"tatsuno.nagano.jp\0org.py\0"
+"pub.sa\0"
+"portal.museum\0is-into-cartoons.com\0"
+"sasayama.hyogo.jp\0"
+"ibigawa.gifu.jp\0"
+"uruma.okinawa.jp\0"
+"orskog.no\0"
+"cincinnati.museum\0"
+"farmstead.museum\0"
+"ftpaccess.cc\0"
+"castres.museum\0org.ro\0"
+"org.sa\0"
+"sassari.it\0saka.hiroshima.jp\0org.sb\0"
+"higashihiroshima.hiroshima.jp\0org.rs\0org.sc\0"
+"org.sd\0"
+"tokai.aichi.jp\0org.ru\0org.se\0"
+"games.hu\0pn.it\0v\xc3\xa6r\xc3\xb8y.no\0"
+"amsterdam.museum\0org.sg\0"
+"campobasso.it\0org.sh\0"
+"forli-cesena.it\0corvette.museum\0ath.cx\0"
+"yokawa.hyogo.jp\0is-a-socialist.com\0"
+"tjeldsund.no\0az.us\0"
+"student.aero\0name.eg\0org.sl\0"
+"l.bg\0sc.kr\0"
+"org.sn\0"
+"frankfurt.museum\0org.so\0"
+"barcelona.museum\0from-wy.com\0"
+"is-an-artist.com\0"
+"dvrdns.org\0"
+"ikata.ehime.jp\0"
+"dr.na\0steinkjer.no\0org.st\0"
+"yao.osaka.jp\0british.museum\0"
+"grosseto.it\0gemological.museum\0lipetsk.ru\0"
+"civilization.museum\0iron.museum\0org.sy\0"
+"org.sz\0org.tj\0"
+"tel\0"
+"org.tm\0"
+"honbetsu.hokkaido.jp\0minamioguni.kumamoto.jp\0org.tn\0"
+"name.az\0ohira.miyagi.jp\0s\xc3\xb8ndre-land.no\0org.to\0"
+"intl.tn\0"
+"schlesisches.museum\0org.ua\0"
+"cesenaforli.it\0"
+"org.tt\0"
+"org.tw\0org.ug\0"
+"takehara.hiroshima.jp\0"
+"bible.museum\0"
+"narashino.chiba.jp\0"
+"tsubame.niigata.jp\0hinohara.tokyo.jp\0"
+"minamiawaji.hyogo.jp\0"
+"is-into-anime.com\0"
+"press.ma\0"
+"nishihara.okinawa.jp\0"
+"kita.osaka.jp\0kazo.saitama.jp\0org.vc\0"
+"tagami.niigata.jp\0org.ve\0"
+"lebork.pl\0"
+"chuo.osaka.jp\0"
+"kashiwa.chiba.jp\0turen.tn\0org.uy\0org.vi\0"
+"flakstad.no\0org.uz\0isa-hockeynut.com\0"
+"kyuragi.saga.jp\0"
+"ichikai.tochigi.jp\0"
+"aoste.it\0"
+"org.vn\0"
+"mishima.fukushima.jp\0"
+"funagata.yamagata.jp\0"
+"from-ms.com\0from-nc.com\0"
+"psc.br\0"
+"gorlice.pl\0"
+"nl.ca\0chippubetsu.hokkaido.jp\0tone.ibaraki.jp\0i.ph\0"
+"etajima.hiroshima.jp\0"
+"uji.kyoto.jp\0sakai.osaka.jp\0la.us\0"
+"aukra.no\0stranda.no\0stryn.no\0org.ws\0"
+"tromsa.no\0"
+"ind.br\0yoichi.hokkaido.jp\0"
+"sayama.osaka.jp\0usenet.pl\0"
+"amusement.aero\0maniwa.okayama.jp\0"
+"katowice.pl\0is-a-nascarfan.com\0"
+"okawa.kochi.jp\0"
+"tomisato.chiba.jp\0cadaques.museum\0cc.dc.us\0"
+"space.museum\0"
+"afjord.no\0"
+"oharu.aichi.jp\0"
+"koriyama.fukushima.jp\0"
+"il.us\0"
+"n\xc3\xa1vuotna.no\0"
+"satx.museum\0"
+"misato.akita.jp\0"
+"katsuragi.wakayama.jp\0history.museum\0"
+"pharmacien.fr\0rieti.it\0"
+"assassination.museum\0"
+"j\xc3\xb8rpeland.no\0r\xc3\xb8yken.no\0"
+"i.se\0"
+"miyoshi.hiroshima.jp\0"
+"computer.museum\0"
+"tsubata.ishikawa.jp\0"
+"kawakita.ishikawa.jp\0for-the.biz\0"
+"fortworth.museum\0"
+"akita.akita.jp\0storfjord.no\0"
+"b\xc3\xa1hccavuotna.no\0"
+"andebu.no\0"
+"taketomi.okinawa.jp\0"
+"isshiki.aichi.jp\0"
+"taiji.wakayama.jp\0"
+"haebaru.okinawa.jp\0"
+"dell-ogliastra.it\0historichouses.museum\0trogstad.no\0"
+"tx.us\0k12.pa.us\0"
+"lib.ks.us\0"
+"kherson.ua\0"
+"uonuma.niigata.jp\0"
+"bifuka.hokkaido.jp\0kouhoku.saga.jp\0luster.no\0"
+"gotsu.shimane.jp\0r\xc3\xb8""d\xc3\xb8y.no\0"
+"skiptvet.no\0"
+"press.aero\0"
+"sc.ug\0"
+"sc.tz\0"
+"hekinan.aichi.jp\0kariya.aichi.jp\0kounosu.saitama.jp\0quebec.museum\0"
+"ind.gt\0kuromatsunai.hokkaido.jp\0"
+"money.museum\0"
+"historical.museum\0sc.us\0k12.mn.us\0"
+"o.bg\0"
+"chesapeakebay.museum\0ringerike.no\0"
+"fst.br\0shitara.aichi.jp\0"
+"urn.arpa\0"
+"homelinux.org\0"
+"ina.nagano.jp\0"
+"its.me\0"
+"kawakami.nagano.jp\0miyada.nagano.jp\0"
+"ishikari.hokkaido.jp\0"
+"national.museum\0"
+"imabari.ehime.jp\0"
+"akaiwa.okayama.jp\0rhcloud.com\0"
+"kamaishi.iwate.jp\0"
+"joyo.kyoto.jp\0"
+"ind.in\0school.na\0"
+"kiso.nagano.jp\0sevastopol.ua\0"
+"shimoichi.nara.jp\0loten.no\0"
+"selfip.net\0"
+"a\xc3\xa9roport.ci\0ascoli-piceno.it\0"
+"nuremberg.museum\0"
+"otaki.saitama.jp\0chuvashia.ru\0defense.tn\0"
+"mibu.tochigi.jp\0mitaka.tokyo.jp\0"
+"odo.br\0"
+"koori.fukushima.jp\0"
+"omuta.fukuoka.jp\0med.pro\0"
+"tomioka.gunma.jp\0kitakata.miyazaki.jp\0arteducation.museum\0"
+"yamatotakada.nara.jp\0"
+"brunel.museum\0"
+"vik.no\0"
+"sf.no\0"
+"is-a-designer.com\0"
+"perso.sn\0"
+"lg.jp\0"
+"hayashima.okayama.jp\0name.vn\0"
+"gangwon.kr\0"
+"atlanta.museum\0"
+"coop.ht\0"
+"veterinaire.km\0"
+"gda.pl\0cc.wa.us\0"
+"qsl.br\0mitsue.nara.jp\0"
+"oumu.hokkaido.jp\0"
+"zarow.pl\0"
+"kisarazu.chiba.jp\0"
+"perso.tn\0"
+"ono.fukushima.jp\0"
+"tas.au\0nordre-land.no\0"
+"kanagawa.jp\0"
+"pasadena.museum\0"
+"uto.kumamoto.jp\0"
+"sport.hu\0"
+"yamatokoriyama.nara.jp\0stj\xc3\xb8rdal.no\0name.tj\0"
+"nishigo.fukushima.jp\0"
+"nikko.tochigi.jp\0"
+"tsushima.nagasaki.jp\0"
+"palmsprings.museum\0"
+"coop.br\0yaroslavl.ru\0"
+"meldal.no\0"
+"takasago.hyogo.jp\0"
+"name.tt\0"
+"nl.no\0"
+"webhop.net\0"
+"nic.im\0sayama.saitama.jp\0"
+"nic.in\0"
+"tomakomai.hokkaido.jp\0"
+"agano.niigata.jp\0"
+"\xd9\x85\xd8\xb5\xd8\xb1\0go.dyndns.org\0"
+"savona.it\0"
+"kodaira.tokyo.jp\0"
+"qld.gov.au\0"
+"kashiwara.osaka.jp\0l.se\0"
+"veterinaire.fr\0"
+"university.museum\0"
+"haugesund.no\0"
+"hokuto.yamanashi.jp\0"
+"lib.ok.us\0"
+"pesarourbino.it\0n\xc3\xb8tter\xc3\xb8y.no\0"
+"2000.hu\0froya.no\0"
+"genova.it\0saskatchewan.museum\0"
+"isleofman.museum\0"
+"video.hu\0smolensk.ru\0"
+"taira.toyama.jp\0"
+"masfjorden.no\0"
+"jessheim.no\0"
+"science.museum\0"
+"cc.or.us\0from-pa.com\0"
+"muroran.hokkaido.jp\0"
+"bs.it\0ube.yamaguchi.jp\0"
+"si.it\0"
+"catering.aero\0esashi.hokkaido.jp\0newmexico.museum\0tana.no\0"
+"opole.pl\0"
+"iruma.saitama.jp\0"
+"hiroo.hokkaido.jp\0ogawa.ibaraki.jp\0rv.ua\0"
+"nakatsugawa.gifu.jp\0\xc3\xa1k\xc5\x8boluokta.no\0"
+"naie.hokkaido.jp\0kvinnherad.no\0"
+"pilot.aero\0ws.na\0"
+"yahaba.iwate.jp\0"
+"birthplace.museum\0"
+"name.qa\0"
+"tahara.aichi.jp\0hashikami.aomori.jp\0name.pr\0"
+"filatelia.museum\0"
+"pt.it\0"
+"chattanooga.museum\0"
+"*.yokohama.jp\0"
+"k12.mo.us\0"
+"r.bg\0yugawara.kanagawa.jp\0"
+"geometre-expert.fr\0koka.shiga.jp\0fundacio.museum\0hamar.no\0"
+"yamanouchi.nagano.jp\0\xc3\xa5lesund.no\0"
+"name.na\0"
+"village.museum\0"
+"shinkamigoto.nagasaki.jp\0name.mv\0"
+"orkanger.no\0"
+"mikasa.hokkaido.jp\0name.my\0balestrand.no\0kr\xc3\xa5""anghke.no\0"
+"no.it\0pesaro-urbino.it\0"
+"kamikawa.hyogo.jp\0"
+"\xd8\xa8\xda\xbe\xd8\xa7\xd8\xb1\xd8\xaa\0"
+"botany.museum\0"
+"cc.na\0"
+"ntr.br\0sango.nara.jp\0masuda.shimane.jp\0"
+"ind.tn\0"
+"trondheim.no\0"
+"fermo.it\0kagamino.okayama.jp\0odda.no\0"
+"askvoll.no\0"
+"tottori.tottori.jp\0bronnoysund.no\0"
+"ena.gifu.jp\0"
+"\xd9\x81\xd9\x84\xd8\xb3\xd8\xb7\xd9\x8a\xd9\x86\0"
+"evenes.no\0"
+"shiriuchi.hokkaido.jp\0hino.tokyo.jp\0lib.vi.us\0"
+"iide.yamagata.jp\0"
+"sande.m\xc3\xb8re-og-romsdal.no\0"
+"shibata.niigata.jp\0botanicgarden.museum\0lg.ua\0"
+"\xc3\xa5s.no\0"
+"namegata.ibaraki.jp\0"
+"architecture.museum\0fineart.museum\0ostrowwlkp.pl\0"
+"sorreisa.no\0"
+"psi.br\0cc.vt.us\0"
+"barrel-of-knowledge.info\0"
+"kunitomi.miyazaki.jp\0name.mk\0"
+"stor-elvdal.no\0uy.com\0"
+"bonn.museum\0budejju.no\0rnu.tn\0"
+"chiyoda.gunma.jp\0"
+"yoro.gifu.jp\0"
+"yasu.shiga.jp\0"
+"amagasaki.hyogo.jp\0"
+"m\xc3\xa1tta-v\xc3\xa1rjjat.no\0"
+"jur.pro\0"
+"mukawa.hokkaido.jp\0narviika.no\0"
+"name.jo\0"
+"marburg.museum\0tysv\xc3\xa6r.no\0"
+"lorenskog.no\0"
+"aland.fi\0yonezawa.yamagata.jp\0"
+"gyeongnam.kr\0"
+"maebashi.gunma.jp\0"
+"tateshina.nagano.jp\0"
+"yamato.kanagawa.jp\0dyndns.info\0"
+"mosvik.no\0"
+"crimea.ua\0"
+"laakesvuemie.no\0"
+"her\xc3\xb8y.m\xc3\xb8re-og-romsdal.no\0"
+"embetsu.hokkaido.jp\0chiyoda.tokyo.jp\0kudamatsu.yamaguchi.jp\0gop.pk\0nic.tj\0"
+"yalta.ua\0"
+"oregon.museum\0"
+"naples.it\0ginan.gifu.jp\0o.se\0"
+"va.it\0tamayu.shimane.jp\0"
+"ninomiya.kanagawa.jp\0"
+"orenburg.ru\0"
+"academy.museum\0"
+"miyakonojo.miyazaki.jp\0appspot.com\0"
+"moma.museum\0"
+"lib.nv.us\0readmyblog.org\0"
+"wake.okayama.jp\0"
+"kusu.oita.jp\0ing.pa\0"
+"blogdns.org\0"
+"is-a-doctor.com\0"
+"london.museum\0"
+"group.aero\0fukumitsu.toyama.jp\0"
+"osaki.miyagi.jp\0"
+"is-a-techie.com\0"
+"!nel.uk\0"
+"otake.hiroshima.jp\0shinonsen.hyogo.jp\0"
+"oshima.yamaguchi.jp\0mari-el.ru\0"
+"obu.aichi.jp\0"
+"bykle.no\0"
+"yasuoka.nagano.jp\0"
+"gs.cn\0"
+"\xd8\xa7\xd9\x84\xd8\xa7\xd8\xb1\xd8\xaf\xd9\x86\0"
+"chuo.fukuoka.jp\0"
+"aero.tt\0"
+"tokai.ibaraki.jp\0"
+"nsw.edu.au\0"
+"suzu.ishikawa.jp\0kitagawa.miyazaki.jp\0"
+"kawaminami.miyazaki.jp\0aisho.shiga.jp\0gs.tr.no\0"
+"bungotakada.oita.jp\0"
+"center.museum\0maritime.museum\0timekeeping.museum\0"
+"u.bg\0ecn.br\0"
+"yamal.ru\0"
+"aero.mv\0"
+"botanical.museum\0at-band-camp.net\0"
+"isa.us\0"
+"kasumigaura.ibaraki.jp\0"
+"ogawa.nagano.jp\0oppegard.no\0"
+"avellino.it\0"
+"samukawa.kanagawa.jp\0nat.tn\0"
+"b\xc3\xb8mlo.no\0"
+"gov.ac\0asso.fr\0"
+"gov.ae\0konan.aichi.jp\0"
+"gov.af\0"
+"research.aero\0omitama.ibaraki.jp\0kita.tokyo.jp\0va.no\0"
+"okaya.nagano.jp\0"
+"zhitomir.ua\0"
+"communication.museum\0"
+"gov.al\0"
+"kanra.gunma.jp\0kamisu.ibaraki.jp\0googlecode.com\0"
+"sandefjord.no\0astrakhan.ru\0kamchatka.ru\0"
+"gov.ba\0asso.gp\0"
+"gov.bb\0"
+"gov.as\0"
+"okinawa.okinawa.jp\0"
+"gov.au\0"
+"gov.bf\0"
+"gov.bh\0"
+"gov.az\0bv.nl\0"
+"pisa.it\0showa.yamanashi.jp\0"
+"kawajima.saitama.jp\0uw.gov.pl\0"
+"gov.bm\0"
+"kunimi.fukushima.jp\0"
+"gov.bo\0vologda.ru\0servebbs.net\0"
+"lib.ut.us\0"
+"gov.br\0naval.museum\0"
+"gov.bs\0"
+"gov.bt\0gov.cd\0minakami.gunma.jp\0"
+"asso.ht\0ovre-eiker.no\0coop.tt\0"
+"nt.edu.au\0mat.br\0"
+"gov.by\0bale.museum\0"
+"gov.bz\0cc.ga.us\0"
+"aga.niigata.jp\0"
+"gov.cl\0fredrikstad.no\0"
+"gov.cm\0"
+"gov.cn\0bushey.museum\0"
+"gov.co\0"
+"nu.ca\0"
+"kamiamakusa.kumamoto.jp\0"
+"aa.no\0"
+"gov.cu\0"
+"omachi.saga.jp\0k12.wy.us\0lib.ca.us\0"
+"coop.mv\0"
+"gov.cx\0coop.mw\0"
+"asso.bj\0venezia.it\0windmill.museum\0"
+"ac\0likes-pie.com\0"
+"ad\0gov.dm\0kepno.pl\0"
+"ae\0"
+"af\0gov.do\0"
+"aerodrome.aero\0ag\0"
+"ai\0"
+"gov.ec\0"
+"milano.it\0"
+"al\0gov.ee\0oguni.kumamoto.jp\0"
+"am\0"
+"an\0gov.eg\0"
+"ao\0"
+"kumiyama.kyoto.jp\0"
+"aq\0ba\0asso.ci\0gov.dz\0hidaka.hokkaido.jp\0"
+"bb\0hongo.hiroshima.jp\0shishikui.tokushima.jp\0"
+"as\0blogdns.com\0"
+"at\0"
+"be\0idv.hk\0"
+"agents.aero\0bf\0"
+"aw\0bg\0notteroy.no\0"
+"ax\0bh\0"
+"bi\0"
+"az\0bj\0"
+"higashiizu.shizuoka.jp\0"
+"bm\0norilsk.ru\0"
+"bo\0"
+"gos.pk\0"
+"ca\0yawatahama.ehime.jp\0"
+"br\0"
+"bs\0cc\0chiropractic.museum\0"
+"bt\0cd\0\xe7\xae\x87\xe4\xba\xba.hk\0en.it\0clock.museum\0r.se\0"
+"cf\0"
+"bw\0cg\0kobayashi.miyazaki.jp\0aurskog-h\xc3\xb8land.no\0valer.hedmark.no\0"
+"ch\0"
+"by\0ci\0"
+"gv.ao\0bz\0"
+"osakasayama.osaka.jp\0wv.us\0"
+"cl\0gov.ge\0tozsde.hu\0nakagyo.kyoto.jp\0homeftp.org\0"
+"cm\0"
+"cn\0gov.gg\0bus.museum\0"
+"gv.at\0co\0gov.gh\0"
+"consultant.aero\0gov.gi\0kahoku.ishikawa.jp\0"
+"shobara.hiroshima.jp\0coop.py\0"
+"cr\0asso.dz\0"
+"cu\0de\0gov.gn\0getmyip.com\0"
+"cv\0"
+"kasai.hyogo.jp\0amur.ru\0"
+"cx\0"
+"gov.gr\0"
+"cz\0dj\0"
+"dk\0ci.it\0"
+"so.it\0"
+"express.aero\0dm\0"
+"do\0tomigusuku.okinawa.jp\0"
+"oseto.nagasaki.jp\0"
+"gov.hk\0va.us\0"
+"ec\0"
+"izumozaki.niigata.jp\0"
+"ee\0"
+"principe.st\0"
+"eg\0"
+"is-a-bookkeeper.com\0"
+"dz\0"
+"gov.ie\0"
+"showa.fukushima.jp\0"
+"noboribetsu.hokkaido.jp\0tourism.tn\0cc.ms.us\0cc.nc.us\0"
+"es\0pz.it\0"
+"gov.im\0"
+"eu\0gov.in\0coop.km\0!british-library.uk\0\xd8\xa7\xdb\x8c\xd8\xb1\xd8\xa7\xd9\x86\0"
+"artcenter.museum\0"
+"suwa.nagano.jp\0"
+"gov.iq\0nationalfirearms.museum\0lubin.pl\0"
+"fi\0gov.ir\0aver\xc3\xb8y.no\0"
+"x.bg\0gov.is\0"
+"gov.it\0"
+"radio.br\0gov.je\0sasebo.nagasaki.jp\0"
+"fm\0monzaedellabrianza.it\0"
+"ad.jp\0"
+"fo\0"
+"ga\0"
+"fr\0"
+"from-nj.com\0"
+"gd\0"
+"ge\0"
+"gf\0gov.jo\0"
+"gg\0"
+"gh\0eiheiji.fukui.jp\0shintomi.miyazaki.jp\0odesa.ua\0"
+"gi\0gifu.jp\0rockart.museum\0homeunix.com\0"
+"nu.it\0"
+"gl\0"
+"gm\0publ.pt\0forgot.his.name\0"
+"gov.kg\0"
+"gp\0gov.ki\0karmoy.no\0"
+"gq\0kr\xc3\xb8""dsherad.no\0"
+"far.br\0gr\0roma.museum\0endofinternet.net\0"
+"gs\0"
+"gt\0gov.km\0inder\xc3\xb8y.no\0"
+"nakama.fukuoka.jp\0gov.kn\0kvanangen.no\0"
+"gw\0taiki.hokkaido.jp\0gov.kp\0"
+"gov.la\0"
+"gy\0haga.tochigi.jp\0gov.lb\0"
+"gobo.wakayama.jp\0gov.lc\0"
+"hk\0"
+"natori.miyagi.jp\0"
+"hm\0crotone.it\0snillfjord.no\0"
+"hn\0"
+"chiryu.aichi.jp\0gov.ky\0"
+"gov.kz\0"
+"hr\0gov.lk\0"
+"ht\0id\0"
+"hu\0ie\0nanbu.yamanashi.jp\0nesseby.no\0"
+"ono.fukui.jp\0"
+"vikna.no\0"
+"gov.ma\0bashkiria.ru\0"
+"gov.lr\0"
+"niihama.ehime.jp\0"
+"gov.lt\0"
+"gov.me\0"
+"im\0shonai.fukuoka.jp\0gov.lv\0"
+"in\0gov.mg\0gorge.museum\0dyndns.org\0"
+"io\0"
+"gov.ly\0"
+"iq\0"
+"ir\0campidanomedio.it\0nichinan.miyazaki.jp\0gov.mk\0"
+"is\0minamitane.kagoshima.jp\0gov.ml\0"
+"it\0"
+"je\0gov.mn\0"
+"gov.mo\0"
+"*.nagoya.jp\0"
+"gov.mr\0est.pr\0"
+"kinko.kagoshima.jp\0"
+"gov.mu\0dudinka.ru\0"
+"kouyama.kagoshima.jp\0gov.mv\0rnrt.tn\0"
+"gov.mw\0gov.ng\0swiebodzin.pl\0"
+"jo\0"
+"jp\0gov.my\0"
+"columbia.museum\0"
+"udono.mie.jp\0"
+"nx.cn\0oristano.it\0"
+"kg\0"
+"ki\0bygland.no\0gov.nr\0"
+"toyoura.hokkaido.jp\0"
+"\xe6\x94\xbf\xe5\xba\x9c.hk\0"
+"taishi.hyogo.jp\0km\0"
+"miyako.iwate.jp\0kn\0"
+"hamatama.saga.jp\0"
+"la\0stavropol.ru\0"
+"kr\0"
+"lc\0"
+"cn.com\0"
+"tarumizu.kagoshima.jp\0"
+"ky\0li\0"
+"kz\0"
+"lk\0"
+"tver.ru\0"
+"uvic.museum\0"
+"gov.ph\0"
+"lyngen.no\0"
+"koto.tokyo.jp\0ma\0cc.az.us\0"
+"sannan.hyogo.jp\0gov.pk\0sells-it.net\0"
+"ls\0mc\0gov.pl\0"
+"lt\0md\0"
+"lu\0me\0gov.pn\0"
+"lv\0meland.no\0u.se\0servegame.org\0"
+"mg\0"
+"mh\0other.nf\0gov.qa\0"
+"ly\0gov.pr\0"
+"gov.ps\0"
+"\xe7\xbb\x84\xe7\xbb\x87.hk\0nishio.aichi.jp\0mk\0gov.pt\0"
+"ml\0miasta.pl\0"
+"iwamizawa.hokkaido.jp\0ikeda.osaka.jp\0sejny.pl\0wy.us\0"
+"kesennuma.miyagi.jp\0mn\0"
+"mo\0"
+"mp\0gov.py\0"
+"mq\0na\0"
+"mr\0selfip.org\0"
+"tsuruoka.yamagata.jp\0ms\0touch.museum\0nc\0"
+"matsumoto.kagoshima.jp\0mu\0ne\0"
+"lecce.it\0wassamu.hokkaido.jp\0mv\0nf\0"
+"hirono.fukushima.jp\0mw\0"
+"mx\0"
+"my\0"
+"hamamatsu.shizuoka.jp\0"
+"rikubetsu.hokkaido.jp\0jamal.ru\0"
+"nl\0nieruchomosci.pl\0"
+"cl.it\0hisayama.fukuoka.jp\0minami.kyoto.jp\0arai.shizuoka.jp\0"
+"sr.it\0kikonai.hokkaido.jp\0"
+"no\0"
+"yakumo.hokkaido.jp\0"
+"keisen.fukuoka.jp\0idv.tw\0"
+"nr\0"
+"b\xc3\xa5""d\xc3\xa5""ddj\xc3\xa5.no\0"
+"ut.us\0"
+"nu\0"
+"gov.sa\0"
+"gov.sb\0"
+"gov.rs\0gov.sc\0"
+"hi.cn\0gov.sd\0"
+"orkdal.no\0gov.ru\0"
+"fuoisku.no\0"
+"shiraoka.saitama.jp\0building.museum\0gov.rw\0gov.sg\0"
+"gov.sh\0"
+"co.ae\0aeroclub.aero\0"
+"pa\0"
+"co.ag\0"
+"gov.sl\0"
+"ag.it\0higashi.okinawa.jp\0lancashire.museum\0"
+"pe\0"
+"pf\0"
+"oygarden.no\0"
+"!siemens.om\0ph\0"
+"aikawa.kanagawa.jp\0"
+"co.ao\0tempioolbia.it\0"
+"lierne.no\0pk\0gov.st\0"
+"co.ba\0force.museum\0pl\0"
+"pm\0asso.re\0"
+"pn\0"
+"co.at\0dep.no\0irkutsk.ru\0gov.sx\0"
+"gov.sy\0"
+"qa\0gov.tj\0"
+"pr\0"
+"historyofscience.museum\0ps\0gov.tl\0"
+"co.bi\0pt\0gov.tm\0"
+"higashinaruse.akita.jp\0madrid.museum\0gov.tn\0"
+"gov.to\0\xe0\xb9\x84\xe0\xb8\x97\xe0\xb8\xa2\0"
+"pw\0cc.la.us\0"
+"tarui.gifu.jp\0gov.ua\0"
+"py\0"
+"kyotango.kyoto.jp\0gov.tt\0"
+"tourism.pl\0co.ca\0"
+"leirfjord.no\0"
+"gov.tw\0"
+"tenkawa.nara.jp\0"
+"minowa.nagano.jp\0"
+"co.bw\0takazaki.miyazaki.jp\0ullensvang.no\0"
+"andoy.no\0"
+"co.ci\0"
+"finland.museum\0tysnes.no\0re\0"
+"e12.ve\0"
+"co.cl\0austevoll.no\0wolomin.pl\0"
+"kunstunddesign.museum\0"
+"k\xc3\xa5""fjord.no\0gov.vc\0"
+"gov.ve\0"
+"co.cr\0kasuga.fukuoka.jp\0"
+"iris.arpa\0cc.il.us\0"
+"latina.it\0copenhagen.museum\0ro\0"
+"sa\0"
+"sb\0"
+"mc.it\0um.gov.pl\0rs\0sc\0"
+"futtsu.chiba.jp\0incheon.kr\0sd\0"
+"ru\0se\0gov.vn\0"
+"oppeg\xc3\xa5rd.no\0"
+"rw\0sg\0"
+"sh\0"
+"cnt.br\0harima.hyogo.jp\0si\0"
+"1.bg\0"
+"sk\0"
+"sl\0"
+"sm\0"
+"plaza.museum\0sn\0"
+"so\0"
+"sr\0"
+"tc\0"
+"st\0td\0"
+"su\0"
+"tf\0"
+"nishiawakura.okayama.jp\0tg\0"
+"sx\0th\0"
+"unbi.ba\0sumita.iwate.jp\0forsand.no\0sy\0"
+"sz\0tj\0gov.ws\0"
+"asso.nc\0tk\0"
+"artgallery.museum\0tl\0"
+"tm\0"
+"tn\0"
+"toda.saitama.jp\0to\0"
+"for-some.biz\0"
+"ua\0"
+"yatsushiro.kumamoto.jp\0"
+"!rakpetroleum.om\0tt\0"
+"taishin.fukushima.jp\0beeldengeluid.museum\0"
+"hellas.museum\0tv\0gr.com\0"
+"fujimi.nagano.jp\0tw\0ug\0"
+"rennesoy.no\0"
+"asahi.nagano.jp\0"
+"ogano.saitama.jp\0mjondalen.no\0loabat.no\0cc.tx.us\0"
+"kikuchi.kumamoto.jp\0gniezno.pl\0"
+"iwaizumi.iwate.jp\0"
+"va\0"
+"co.gg\0"
+"nesset.no\0us\0vc\0"
+"parma.it\0hasama.oita.jp\0b\xc3\xa1l\xc3\xa1t.no\0ve\0"
+"kashima.ibaraki.jp\0vg\0"
+"k12.ut.us\0"
+"uy\0vi\0"
+"monza-e-della-brianza.it\0ebina.kanagawa.jp\0uz\0"
+"kosa.kumamoto.jp\0nagi.okayama.jp\0"
+"yomitan.okinawa.jp\0"
+"vn\0"
+"ouda.nara.jp\0"
+"ogliastra.it\0"
+"co.gy\0cc.sc.us\0"
+"vu\0"
+"wf\0"
+"webhop.biz\0"
+"x.se\0"
+"farm.museum\0"
+"nord-fron.no\0"
+"co.id\0"
+"mil.ac\0co.hu\0"
+"suzuka.mie.jp\0sigdal.no\0"
+"mil.ae\0"
+"forde.no\0ws\0"
+"ivgu.no\0"
+"co.im\0"
+"mil.al\0co.in\0uchiko.ehime.jp\0mer\xc3\xa5ker.no\0s\xc3\xb8rum.no\0"
+"vibo-valentia.it\0"
+"nango.fukushima.jp\0"
+"co.ir\0"
+"mil.ba\0\xc3\xa5mot.no\0"
+"co.it\0"
+"te.it\0co.je\0"
+"ostre-toten.no\0"
+"engineer.aero\0kumamoto.jp\0nativeamerican.museum\0"
+"miyama.mie.jp\0"
+"mil.az\0nagawa.nagano.jp\0"
+"eng.pro\0"
+"co.jp\0"
+"mil.bo\0"
+"hl.cn\0"
+"sk\xc3\xa1nit.no\0"
+"mil.br\0uda.nara.jp\0"
+"pvt.k12.ma.us\0"
+"medio-campidano.it\0columbus.museum\0"
+"sakaiminato.tottori.jp\0yt\0"
+"asso.km\0"
+"mil.by\0higashiyodogawa.osaka.jp\0nanbu.tottori.jp\0"
+"intelligence.museum\0"
+"mil.cl\0aioi.hyogo.jp\0"
+"mil.cn\0"
+"mil.co\0levanger.no\0"
+"co.kr\0"
+"co.lc\0from-wi.com\0"
+"kawai.iwate.jp\0"
+"b\xc3\xb8.telemark.no\0"
+"tsurugi.ishikawa.jp\0"
+"flekkefjord.no\0"
+"furniture.museum\0newyork.museum\0"
+"asso.mc\0"
+"mil.do\0co.ma\0"
+"nagara.chiba.jp\0co.ls\0"
+"mil.ec\0bolt.hu\0co.me\0"
+"uhren.museum\0"
+"joso.ibaraki.jp\0niyodogawa.kochi.jp\0gs.sf.no\0"
+"mil.eg\0"
+"lib.il.us\0"
+"umaji.kochi.jp\0kurashiki.okayama.jp\0"
+"kakinoki.shimane.jp\0oishida.yamagata.jp\0"
+"bearalv\xc3\xa1hki.no\0sokndal.no\0"
+"wa.gov.au\0sx.cn\0co.na\0"
+"art.museum\0"
+"mo-i-rana.no\0"
+"co.mu\0"
+"co.mw\0"
+"design.aero\0"
+"vadso.no\0"
+"am.br\0"
+"co.nl\0"
+"hidaka.kochi.jp\0"
+"tokushima.jp\0communications.museum\0"
+"co.no\0"
+"oh.us\0blogdns.net\0"
+"4.bg\0nord-odal.no\0"
+"kumamoto.kumamoto.jp\0"
+"altoadige.it\0koto.shiga.jp\0"
+"yasaka.nagano.jp\0"
+"mil.ge\0"
+"jaworzno.pl\0"
+"saito.miyazaki.jp\0"
+"mil.gh\0toyoake.aichi.jp\0"
+"mombetsu.hokkaido.jp\0"
+"fauske.no\0"
+"nishi.fukuoka.jp\0alaska.museum\0"
+"marnardal.no\0"
+"on.ca\0"
+"higashikurume.tokyo.jp\0"
+"gs.nl.no\0"
+"mil.gt\0reggioemilia.it\0r\xc3\xb8st.no\0"
+"fnd.br\0bjark\xc3\xb8y.no\0l\xc3\xa6rdal.no\0tromso.no\0krakow.pl\0"
+"takahashi.okayama.jp\0hasvik.no\0"
+"co.pl\0"
+"zt.ua\0"
+"katsuyama.fukui.jp\0co.pn\0homeftp.net\0"
+"mil.hn\0fuchu.tokyo.jp\0omaha.museum\0"
+"date.hokkaido.jp\0shimokawa.hokkaido.jp\0"
+"tyumen.ru\0"
+"mil.id\0philadelphiaarea.museum\0sanfrancisco.museum\0"
+"honjo.akita.jp\0living.museum\0co.pw\0"
+"beiarn.no\0"
+"ullensaker.no\0"
+"tozawa.yamagata.jp\0"
+"aya.miyazaki.jp\0uk.net\0"
+"sklep.pl\0"
+"hokuto.hokkaido.jp\0"
+"mil.in\0"
+"tsaritsyn.ru\0"
+"mil.iq\0"
+"minami.fukuoka.jp\0"
+"naklo.pl\0"
+"susaki.kochi.jp\0"
+"karatsu.saga.jp\0"
+"fg.it\0badajoz.museum\0"
+"for-better.biz\0"
+"mil.jo\0"
+"midsund.no\0co.rs\0"
+"shimane.shimane.jp\0"
+"hi.us\0"
+"d\xc3\xb8nna.no\0"
+"york.museum\0spydeberg.no\0co.rw\0"
+"hamatonbetsu.hokkaido.jp\0"
+"mil.kg\0"
+"!nic.ar\0kagami.kochi.jp\0dynalias.com\0"
+"civilaviation.aero\0modelling.aero\0uz.ua\0"
+"nanao.ishikawa.jp\0"
+"mil.km\0"
+"modum.no\0"
+"badaddja.no\0"
+"mil.kr\0co.st\0"
+"oi.kanagawa.jp\0"
+"author.aero\0cr.it\0"
+"co.th\0"
+"versailles.museum\0co.sz\0co.tj\0"
+"encyclopedic.museum\0"
+"mil.kz\0grong.no\0"
+"co.tm\0"
+"minamiboso.chiba.jp\0lib.ma.us\0servebbs.org\0"
+"kiev.ua\0"
+"journalist.aero\0co.ua\0"
+"te.ua\0"
+"co.tt\0"
+"co.ug\0"
+"mil.lv\0"
+"mil.mg\0"
+"co.tz\0"
+"council.aero\0ibaraki.jp\0"
+"family.museum\0"
+"rc.it\0"
+"hl.no\0ostrowiec.pl\0co.us\0"
+"!statecouncil.om\0co.ve\0"
+"!congresodelalengua3.ar\0nalchik.ru\0"
+"mil.mv\0halsa.no\0"
+"co.vi\0"
+"takayama.gifu.jp\0fujishiro.ibaraki.jp\0os.hordaland.no\0sirdal.no\0co.uz\0"
+"fj.cn\0mil.my\0"
+"kazuno.akita.jp\0"
+"unzen.nagasaki.jp\0mizuho.tokyo.jp\0indianapolis.museum\0"
+"from-id.com\0"
+"hurum.no\0"
+"mil.no\0"
+"pordenone.it\0"
+"kvam.no\0"
+"mutsuzawa.chiba.jp\0artdeco.museum\0"
+"hamada.shimane.jp\0philadelphia.museum\0"
+"kudoyama.wakayama.jp\0"
+"mishima.shizuoka.jp\0minami-alps.yamanashi.jp\0k12.mi.us\0"
+"nanmoku.gunma.jp\0"
+"ashikaga.tochigi.jp\0"
+"from-wv.com\0"
+"\xe5\x8f\xb0\xe6\xb9\xbe\0"
+"kawatana.nagasaki.jp\0"
+"oslo.no\0"
+"fukuchiyama.kyoto.jp\0"
+"kisofukushima.nagano.jp\0"
+"okayama.jp\0mil.pe\0"
+"mil.ph\0"
+"mi.it\0"
+"russia.museum\0"
+"abo.pa\0mil.pl\0"
+"nobeoka.miyazaki.jp\0shinjuku.tokyo.jp\0"
+"ok.us\0"
+"7.bg\0mil.qa\0"
+"verran.no\0suwalki.pl\0"
+"onjuku.chiba.jp\0szczytno.pl\0lv.ua\0"
+"mitou.yamaguchi.jp\0mil.py\0"
+"chita.ru\0"
+"hirono.iwate.jp\0"
+"embroidery.museum\0"
+"mad.museum\0"
+"kawaue.gifu.jp\0"
+"shiiba.miyazaki.jp\0"
+"asnes.no\0"
+"media.hu\0sande.vestfold.no\0\xd8\xb9\xd9\x85\xd8\xa7\xd9\x86\0"
+"lib.de.us\0"
+"erotika.hu\0ski.museum\0"
+"parti.se\0on-the-web.tv\0"
+"works.aero\0gb.com\0dyndns-free.com\0"
+"biz.bb\0firm.ht\0rifu.miyagi.jp\0watari.miyagi.jp\0"
+"takagi.nagano.jp\0biz.at\0"
+"surgeonshall.museum\0skanit.no\0"
+"florida.museum\0"
+"kani.gifu.jp\0"
+"biz.az\0mil.ru\0"
+"isesaki.gunma.jp\0"
+"firm.in\0yusui.kagoshima.jp\0mil.rw\0"
+"mil.sh\0"
+"inderoy.no\0"
+"software.aero\0kushiro.hokkaido.jp\0pyatigorsk.ru\0"
+"bindal.no\0"
+"sakegawa.yamagata.jp\0"
+"ninohe.iwate.jp\0yonago.tottori.jp\0"
+"mil.st\0"
+"galsa.no\0"
+"mil.sy\0"
+"salvadordali.museum\0mil.tj\0"
+"mil.tm\0"
+"for-our.info\0"
+"shikama.miyagi.jp\0mil.to\0"
+"yaotsu.gifu.jp\0"
+"niki.hokkaido.jp\0"
+"hikawa.shimane.jp\0stat.no\0"
+"joetsu.niigata.jp\0mil.tw\0"
+"firm.co\0bruxelles.museum\0endofinternet.org\0"
+"asahi.mie.jp\0mil.tz\0"
+"sor-varanger.no\0dynathome.net\0"
+"skoczow.pl\0"
+"shonai.yamagata.jp\0"
+"stadt.museum\0"
+"roma.it\0"
+"shijonawate.osaka.jp\0"
+"mil.vc\0"
+"mil.ve\0"
+"honai.ehime.jp\0"
+"muko.kyoto.jp\0"
+"karpacz.pl\0mil.uy\0us.com\0"
+"k12.az.us\0"
+"\xe6\x95\x99\xe8\x82\xb2.hk\0"
+"monza-brianza.it\0shingo.aomori.jp\0toshima.tokyo.jp\0prochowice.pl\0"
+"kuju.oita.jp\0cr.ua\0"
+"eid.no\0"
+"kyowa.hokkaido.jp\0"
+"higashikagura.hokkaido.jp\0otari.nagano.jp\0kiyama.saga.jp\0"
+"rochester.museum\0"
+"fuchu.hiroshima.jp\0"
+"hasuda.saitama.jp\0"
+"ap.it\0"
+"fm.br\0dagestan.ru\0"
+"gs.va.no\0"
+"shinshiro.aichi.jp\0lowicz.pl\0"
+"taiwa.miyagi.jp\0yekaterinburg.ru\0"
+"wielun.pl\0"
+"geelvinck.museum\0"
+"slattum.no\0"
+"utsunomiya.tochigi.jp\0"
+"bern.museum\0rivne.ua\0"
+"miners.museum\0"
+"com.ac\0kraanghke.no\0"
+"pa.it\0davvenj\xc3\xa1rga.no\0"
+"com.af\0tsushima.aichi.jp\0"
+"com.ag\0asmatart.museum\0"
+"com.ai\0"
+"etnedal.no\0"
+"com.al\0snaase.no\0media.pl\0"
+"sula.no\0vanylven.no\0"
+"com.an\0"
+"torino.museum\0"
+"helsinki.museum\0"
+"com.ba\0"
+"com.bb\0"
+"kimitsu.chiba.jp\0"
+"tarama.okinawa.jp\0"
+"com.au\0"
+"com.aw\0\xe4\xb8\xaa\xe4\xba\xba.hk\0aremark.no\0"
+"com.bh\0vestre-slidre.no\0"
+"com.bi\0goto.nagasaki.jp\0higashisumiyoshi.osaka.jp\0"
+"com.az\0"
+"rollag.no\0"
+"bc.ca\0"
+"com.bm\0oceanographique.museum\0"
+"mesaverde.museum\0mi.th\0"
+"com.bo\0gs.aa.no\0"
+"jerusalem.museum\0"
+"com.br\0is-a-green.com\0"
+"com.bs\0nagasaki.jp\0"
+"com.bt\0"
+"nishiwaki.hyogo.jp\0"
+"verbania.it\0takarazuka.hyogo.jp\0georgia.museum\0"
+"com.by\0com.ci\0"
+"com.bz\0uchinomi.kagawa.jp\0"
+"ehime.jp\0"
+"shinjo.nara.jp\0"
+"com.cn\0shiki.saitama.jp\0"
+"com.co\0cc.wv.us\0"
+"xxx\0"
+"tychy.pl\0nkz.ru\0"
+"tobe.ehime.jp\0"
+"strand.no\0"
+"biz.ki\0ivanovo.ru\0"
+"com.cu\0com.de\0"
+"s\xc3\xa1l\xc3\xa1t.no\0"
+"hichiso.gifu.jp\0nirasaki.yamanashi.jp\0flesberg.no\0"
+"mi.us\0k12.il.us\0"
+"jgora.pl\0sumy.ua\0"
+"com.dm\0izumo.shimane.jp\0"
+"com.do\0hiranai.aomori.jp\0"
+"jor.br\0!city.sendai.jp\0"
+"omaezaki.shizuoka.jp\0"
+"turin.it\0nissedal.no\0skierva.no\0"
+"com.ec\0"
+"com.ee\0"
+"cc.va.us\0"
+"com.eg\0nagano.nagano.jp\0"
+"halloffame.museum\0leka.no\0"
+"com.dz\0morioka.iwate.jp\0"
+"lesja.no\0"
+"vibovalentia.it\0nishi.osaka.jp\0kg.kr\0"
+"!city.kawasaki.jp\0flanders.museum\0"
+"com.es\0florence.it\0"
+"kumano.hiroshima.jp\0from-sd.com\0"
+"mo.cn\0yamagata.nagano.jp\0!nic.tr\0"
+"yamanashi.jp\0"
+"is-with-theband.com\0"
+"canada.museum\0"
+"bardu.no\0tr\xc3\xb8gstad.no\0"
+"fm.it\0biz.mv\0bialowieza.pl\0!nic.uk\0"
+"com.fr\0vs.it\0kunohe.iwate.jp\0aoki.nagano.jp\0biz.mw\0"
+"izumi.osaka.jp\0koeln.museum\0"
+"gulen.no\0ruovat.no\0"
+"agr.br\0com.ge\0nes.buskerud.no\0"
+"fukudomi.saga.jp\0"
+"dnsdojo.com\0"
+"com.gh\0hitachi.ibaraki.jp\0selfip.biz\0"
+"com.gi\0nakagawa.nagano.jp\0"
+"biz.nr\0"
+"com.gn\0nishiaizu.fukushima.jp\0"
+"com.gp\0bearalvahki.no\0"
+"m\xc3\xa5lselv.no\0kchr.ru\0"
+"com.gr\0tosashimizu.kochi.jp\0"
+"tas.gov.au\0nosegawa.nara.jp\0"
+"com.gt\0kanan.osaka.jp\0oyer.no\0\xe0\xa4\xad\xe0\xa4\xbe\xe0\xa4\xb0\xe0\xa4\xa4\0"
+"shinagawa.tokyo.jp\0"
+"com.gy\0tn.it\0kyoto.jp\0kurume.fukuoka.jp\0"
+"yk.ca\0"
+"com.hk\0itako.ibaraki.jp\0"
+"hammarfeasta.no\0"
+"broker.aero\0com.hn\0shinshinotsu.hokkaido.jp\0"
+"k12.ri.us\0"
+"czeladz.pl\0"
+"dovre.no\0"
"com.hr\0"
-"fg.it\0stathelle.no\0defense.tn\0"
-"com.ht\0"
-"qld.gov.au\0*.nz\0"
-"davvenj\xc3\xa1rga.no\0*.om\0"
-"vang.no\0"
-"*.kumamoto.jp\0"
-"vercelli.it\0usenet.pl\0"
-"com.io\0stalbans.museum\0"
-"com.iq\0"
-"*.pg\0"
-"com.is\0klabu.no\0skiptvet.no\0"
-"med.ht\0field.museum\0"
-"gr.it\0gj\xc3\xb8vik.no\0tromsa.no\0lib.mi.us\0"
-"ca.na\0"
-"hagebostad.no\0k12.ma.us\0"
-"*.qa\0"
-"*.niigata.jp\0"
-"monzaebrianza.it\0com.jo\0comunica\xc3\xa7\xc3\xb5""es.museum\0"
-"gr.jp\0"
-"ballangen.no\0*.py\0"
-"scienceandindustry.museum\0"
-"nuoro.it\0com.kg\0"
+"com.ht\0ebino.miyazaki.jp\0"
+"celtic.museum\0"
+"fujimi.saitama.jp\0biz.pk\0dyndns-at-home.com\0"
+"asn.au\0biz.pl\0"
+"kanzaki.saga.jp\0"
+"nannestad.no\0"
+"yachiyo.ibaraki.jp\0"
+"kaizuka.osaka.jp\0r\xc3\xa5holt.no\0biz.pr\0is-into-games.com\0"
+"\xe9\xa6\x99\xe6\xb8\xaf\0"
+"com.io\0"
+"ri.it\0komoro.nagano.jp\0"
+"com.iq\0gyokuto.kumamoto.jp\0googleapis.com\0"
+"com.is\0"
+"issmarterthanyou.com\0"
+"de.us\0"
+"castle.museum\0!parliament.uk\0"
+"shimodate.ibaraki.jp\0"
+"g\xc3\xa1ivuotna.no\0"
+"kviteseid.no\0"
+"yabu.hyogo.jp\0naamesjevuemie.no\0"
+"com.jo\0science-fiction.museum\0zaporizhzhe.ua\0"
+"tanabe.kyoto.jp\0"
+"aejrie.no\0"
+"sakae.nagano.jp\0is-a-nurse.com\0"
+"moriguchi.osaka.jp\0stjordalshalsen.no\0"
+"pd.it\0ot.it\0com.kg\0tokke.no\0"
"com.ki\0"
-"im.it\0idv.tw\0"
-"*.akita.jp\0com.km\0r\xc3\xb8ros.no\0sopot.pl\0"
-"!pref.yamanashi.jp\0"
+"bibai.hokkaido.jp\0tsk.ru\0"
+"fm.no\0"
+"com.km\0kirovograd.ua\0"
+"b.bg\0tomi.nagano.jp\0"
"com.kp\0"
-"!pref.kochi.jp\0com.la\0"
+"ballooning.aero\0com.la\0"
"com.lb\0"
-"com.lc\0stjordalshalsen.no\0sigdal.no\0cc.nm.us\0"
-"samnanger.no\0"
-"drobak.no\0"
-"vt.it\0"
-"catering.aero\0com.ky\0"
-"com.kz\0cc.ca.us\0"
-"com.lk\0"
-"grosseto.it\0mosvik.no\0"
-"namsskogan.no\0"
-"loten.no\0"
-"chirurgiens-dentistes.fr\0"
-"com.lr\0bremanger.no\0"
-"gs.cn\0"
-"com.lv\0lib.co.us\0"
-"com.mg\0"
-"passenger-association.aero\0"
-"com.ly\0yekaterinburg.ru\0"
-"vladivostok.ru\0"
-"com.mk\0beeldengeluid.museum\0"
+"com.lc\0lutsk.ua\0"
+"yatomi.aichi.jp\0"
+"virtuel.museum\0firm.ro\0"
+"navigation.aero\0b.br\0com.ky\0"
+"com.kz\0"
+"tenei.fukushima.jp\0chungnam.kr\0com.lk\0"
+"mo.it\0"
+"dnsdojo.org\0"
+"com.lr\0\xd8\xa7\xd9\x84\xd8\xb3\xd8\xb9\xd9\x88\xd8\xaf\xdb\x8c\xd8\xa9\0"
+"opoczno.pl\0"
+"pa.us\0"
+"saga.jp\0kvinesdal.no\0biz.tj\0"
+"com.lv\0"
+"gose.nara.jp\0com.mg\0"
+"nagaokakyo.kyoto.jp\0tcm.museum\0"
+"com.ly\0"
+"kawasaki.miyagi.jp\0cieszyn.pl\0"
+"com.mk\0"
"com.ml\0"
-"art.pl\0"
-"com.mo\0"
-"britishcolumbia.museum\0tx.us\0"
-"com.na\0sakhalin.ru\0*.sv\0"
-"mc.it\0"
-"amsterdam.museum\0udm.ru\0"
+"com.mo\0siljan.no\0biz.tt\0"
+"akita.jp\0"
+"com.na\0cc.wy.us\0"
+"riodejaneiro.museum\0marine.ru\0"
+"averoy.no\0"
"com.mu\0"
-"com.mv\0com.nf\0"
-"com.mw\0com.ng\0il.us\0"
-"geometre-expert.fr\0com.mx\0"
-"med.ly\0com.my\0"
-"ag.it\0"
-"*.tr\0"
-"!pref.oita.jp\0"
-"hoyanger.no\0skedsmo.no\0"
-"com.nr\0turystyka.pl\0"
-"koebenhavn.museum\0"
-"quebec.museum\0"
-"stord.no\0*.uk\0"
-"act.au\0"
-"br.it\0cb.it\0gyeonggi.kr\0jobs.tt\0lib.hi.us\0"
-"*.ve\0"
-"*.saga.jp\0wildlife.museum\0com.pa\0"
-"monzabrianza.it\0sciencehistory.museum\0stange.no\0oskol.ru\0principe.st\0*.uy\0"
-"plaza.museum\0com.pe\0"
-"com.pf\0"
-"eigersund.no\0"
+"com.mv\0com.nf\0tolga.no\0"
+"com.mw\0com.ng\0vladimir.ru\0"
+"com.mx\0deatnu.no\0"
+"com.my\0"
+"mihara.kochi.jp\0"
+"hyllestad.no\0melhus.no\0lib.co.us\0"
+"eng.br\0"
+"mashike.hokkaido.jp\0com.nr\0"
+"minamiminowa.nagano.jp\0"
+"moroyama.saitama.jp\0moscow.museum\0"
+"phoenix.museum\0vladikavkaz.ru\0from-nh.com\0"
+"jan-mayen.no\0"
+"granvin.no\0khv.ru\0"
+"cc.ut.us\0"
+"mj\xc3\xb8ndalen.no\0biz.vn\0"
+"accident-investigation.aero\0v\xc3\xa5ler.hedmark.no\0"
+"kisosaki.mie.jp\0"
+"nb.ca\0"
+"firm.nf\0"
+"biz\0doshi.yamanashi.jp\0com.pa\0"
+"lib.ar.us\0dyndns-ip.com\0"
+"fukushima.fukushima.jp\0"
+"com.pe\0"
+"misasa.tottori.jp\0fuossko.no\0com.pf\0"
"com.ph\0"
-"manx.museum\0marylhurst.museum\0"
-"md.ci\0pi.it\0schweiz.museum\0com.pk\0"
-"grp.lk\0fr\xc3\xb8ya.no\0com.pl\0press.se\0"
-"us.com\0"
-"b.bg\0cremona.it\0communication.museum\0art.sn\0"
-"med.pa\0"
-"com.pr\0"
+"tokashiki.okinawa.jp\0\xc4\x8d\xc3\xa1hcesuolo.no\0"
+"moriyama.shiga.jp\0museumcenter.museum\0hof.no\0vegarshei.no\0com.pk\0"
+"com.pl\0"
+"com.qa\0"
+"imperia.it\0com.pr\0"
"com.ps\0"
-"com.pt\0"
-"k12.in.us\0"
-"ah.cn\0bahcavuotna.no\0"
-"sondrio.it\0arkhangelsk.ru\0"
-"cargo.aero\0"
-"council.aero\0"
-"museum.mv\0hattfjelldal.no\0spydeberg.no\0med.pl\0"
-"niepce.museum\0museum.mw\0"
-"anthropology.museum\0"
-"pharmacien.fr\0smola.no\0"
-"fin.ec\0"
-"selbu.no\0"
-"workinggroup.aero\0nm.us\0"
-"museum.no\0com.re\0"
-"cc.vt.us\0"
-"village.museum\0"
-"ca.us\0"
-"*.sapporo.jp\0"
-"teramo.it\0"
+"vv.it\0com.pt\0"
+"ayagawa.kagawa.jp\0davvenjarga.no\0"
+"iwakuni.yamaguchi.jp\0com.py\0k12.dc.us\0"
+"royken.no\0"
+"pri.ee\0nishikata.tochigi.jp\0"
+"urawa.saitama.jp\0"
+"equipment.aero\0sweden.museum\0"
+"kyowa.akita.jp\0guovdageaidnu.no\0"
+"ogaki.gifu.jp\0"
+"com.re\0"
+"emergency.aero\0"
+"ikusaka.nagano.jp\0"
+"hirosaki.aomori.jp\0"
+"jobs.tt\0"
+"maryland.museum\0"
"com.ro\0"
-"*.ye\0"
-"com.sa\0"
-"com.sb\0"
-"so.it\0com.sc\0"
-"jolster.no\0com.sd\0"
+"com.sa\0is-found.org\0"
+"usa.oita.jp\0com.sb\0"
+"frogn.no\0com.sc\0"
+"com.sd\0"
"com.ru\0"
"com.rw\0com.sg\0"
-"sydney.museum\0"
-"sa.edu.au\0"
-"tom.ru\0"
-"com.sl\0*.za\0"
-"\xe7\xbd\x91\xe7\xb5\xa1.hk\0naturbruksgymn.se\0com.sn\0"
-"assedic.fr\0com.so\0"
-"!pref.mie.jp\0*.yu\0"
-"med.sa\0"
-"newspaper.museum\0holmestrand.no\0dnepropetrovsk.ua\0"
-"christiansburg.museum\0roan.no\0"
-"pesaro-urbino.it\0med.sd\0com.st\0"
-"s\xc3\xb8gne.no\0"
-"nuernberg.museum\0"
-"*.zm\0"
-"com.sy\0"
-"*.nagano.jp\0com.tj\0"
-"nt.gov.au\0news.hu\0paderborn.museum\0"
-"boston.museum\0"
-"com.tn\0"
+"inawashiro.fukushima.jp\0com.sh\0"
+"yn.cn\0"
+"com.sl\0"
+"togakushi.nagano.jp\0unazuki.toyama.jp\0com.sn\0"
+"porsanger.no\0com.so\0"
+"av.it\0"
+"gc.ca\0okinawa.jp\0"
+"com.st\0"
+"asn.lv\0namdalseid.no\0tn.us\0"
+"amber.museum\0com.sy\0broke-it.net\0podzone.net\0"
+"net.ac\0com.tj\0"
+"selfip.com\0"
+"net.ae\0ofunato.iwate.jp\0shichikashuku.miyagi.jp\0"
+"net.af\0yoita.niigata.jp\0com.tm\0"
+"net.ag\0com.tn\0dynalias.net\0"
"com.to\0"
-"broadcast.museum\0"
+"net.ai\0eidsberg.no\0"
"com.ua\0"
-"*.zw\0"
-"baikal.ru\0"
-"bykle.no\0com.tt\0"
-"verdal.no\0"
-"roros.no\0"
-"fi.cr\0carboniaiglesias.it\0chuvashia.ru\0com.tw\0"
-"k12.ca.us\0"
-"eidsvoll.no\0"
-"*.ishikawa.jp\0"
-"dolls.museum\0"
-"naval.museum\0"
-"karasjok.no\0tysvar.no\0"
-"bielawa.pl\0com.vc\0"
-"svalbard.no\0deatnu.no\0rnd.ru\0"
-"grandrapids.museum\0"
-"bauern.museum\0k12.pr.us\0"
-"press.ma\0"
-"*.kagawa.jp\0fribourg.museum\0przeworsk.pl\0com.vi\0"
-"com.uz\0"
-"babia-gora.pl\0"
-"com.vn\0"
-"med.pro\0"
-"suedtirol.it\0kursk.ru\0"
-"bonn.museum\0"
-"lt.it\0"
-"design.aero\0microlight.aero\0americanantiques.museum\0meland.no\0"
-"insurance.aero\0aarborte.no\0"
-"kh.ua\0"
-"macerata.it\0architecture.museum\0"
-"rovigo.it\0rawa-maz.pl\0"
-"store.nf\0levanger.no\0"
-"b\xc3\xa1jddar.no\0"
-"not.br\0"
-"com.ws\0"
-"!pref.kagawa.jp\0"
-"!omanpost.om\0"
-"vt.us\0"
-"gs.ah.no\0vladikavkaz.ru\0"
-"no.it\0"
-"in.na\0szkola.pl\0a.se\0"
-"aid.pl\0"
-"workshop.museum\0vegarshei.no\0"
-"sund.no\0"
-"bs.it\0flora.no\0"
-"agriculture.museum\0"
-"koeln.museum\0"
-"minnesota.museum\0k12.il.us\0"
-"froya.no\0"
-"aeroport.fr\0"
-"davvenjarga.no\0zgora.pl\0ivano-frankivsk.ua\0"
-"*.gunma.jp\0"
-"amot.no\0"
-"mus.br\0chungbuk.kr\0"
-"ggf.br\0lorenskog.no\0"
-"jeonbuk.kr\0"
-"k12.vi.us\0"
-"c.bg\0sande.more-og-romsdal.no\0"
-"perugia.it\0"
-"massa-carrara.it\0"
-"michigan.museum\0"
-"archaeology.museum\0mosj\xc3\xb8""en.no\0czest.pl\0koenig.ru\0\xe0\xb6\xbd\xe0\xb6\x82\xe0\xb6\x9a\xe0\xb7\x8f\0"
-"mobi.tt\0"
-"kraanghke.no\0"
-"cc.in.us\0"
-"re.it\0lib.vt.us\0"
-"dell-ogliastra.it\0"
-"s\xc3\xb8mna.no\0"
-"k12.wv.us\0"
-"gok.pk\0fh.se\0"
-"luzern.museum\0"
-"fi.it\0swidnica.pl\0"
-"cbg.ru\0"
-"latina.it\0"
-"vibovalentia.it\0"
-"modum.no\0"
-"safety.aero\0"
-"sp.it\0"
-"science.museum\0ah.no\0"
-"norddal.no\0"
-"cc.na\0"
-"re.kr\0"
-"dielddanuorri.no\0"
-"force.museum\0"
-"torino.it\0cc.md.us\0"
-"artanddesign.museum\0pisz.pl\0"
-"olsztyn.pl\0"
-"unsa.ba\0rade.no\0vinnica.ua\0"
-"in.rs\0astrakhan.ru\0"
-"sogne.no\0"
-"homebuilt.aero\0"
-"polkowice.pl\0"
-"hole.no\0health.vn\0"
-"fj.cn\0"
-"davvesiida.no\0"
-"vic.au\0"
-"kongsberg.no\0"
-"pub.sa\0"
-"vv.it\0"
-"!pref.tottori.jp\0"
-"*.sendai.jp\0in.th\0"
-"lib.pa.us\0"
-"chiropractic.museum\0"
-"mobi.na\0aca.pro\0"
-"konyvelo.hu\0sciencecenters.museum\0"
-"he.cn\0"
-"in.ua\0"
-"!city.nagoya.jp\0"
-"muenchen.museum\0"
-"psi.br\0"
-"maryland.museum\0"
-"!statecouncil.om\0"
-"tr\xc3\xa6na.no\0"
-"!pref.yamagata.jp\0jewishart.museum\0"
-"lu.it\0me.it\0"
-"chel.ru\0"
-"tatarstan.ru\0"
-"adult.ht\0in.us\0"
-"kafjord.no\0"
-"\xd7\x99\xd7\xa8\xd7\x95\xd7\xa9\xd7\x9c\xd7\x99\xd7\x9d.museum\0"
-"net.ac\0k12.ec\0"
-"net.ae\0bashkiria.ru\0"
-"net.af\0!omantel.om\0"
-"net.ag\0"
-"net.ai\0"
-"!pref.toyama.jp\0"
-"net.al\0timekeeping.museum\0"
-"net.an\0design.museum\0fin.tn\0"
-"ethnology.museum\0"
-"perso.ht\0asker.no\0b.se\0"
-"net.ba\0"
-"net.bb\0flanders.museum\0"
-"mincom.tn\0"
-"frana.no\0"
-"bt.it\0"
-"net.bh\0"
-"auto.pl\0"
+"lugansk.ua\0"
+"net.al\0"
+"nishihara.kumamoto.jp\0com.tt\0"
+"net.an\0cymru.museum\0heritage.museum\0"
+"sarpsborg.no\0com.tw\0com.ug\0"
+"net.ba\0higashiyamato.tokyo.jp\0\xd8\xaa\xd9\x88\xd9\x86\xd8\xb3\0"
+"net.bb\0pg.it\0"
+"net.au\0"
+"meiwa.gunma.jp\0"
+"as.us\0"
+"net.bh\0ri.us\0"
+"e.bg\0"
"net.az\0"
-"treviso.it\0"
-"war.museum\0"
+"roan.no\0"
+"com.vc\0\xe5\x8f\xb0\xe7\x81\xa3\0"
"net.bm\0"
-"langevag.no\0m\xc3\xa5lselv.no\0"
+"com.ve\0"
"net.bo\0"
-"gol.no\0"
-"folkebibl.no\0"
-"net.br\0"
-"net.bs\0troandin.no\0saotome.st\0lib.tn.us\0"
-"md.us\0k12.ut.us\0"
-"d.bg\0cambridge.museum\0\xc3\xa5s.no\0"
+"net.br\0com.uy\0com.vi\0fuettertdasnetz.de\0"
+"net.bs\0tran\xc3\xb8y.no\0com.uz\0"
+"net.bt\0higashiomi.shiga.jp\0kms.ru\0"
+"accident-prevention.aero\0from-ca.com\0"
+"ozora.hokkaido.jp\0com.vn\0dyndns-server.com\0"
"net.ci\0"
"net.bz\0"
-"sch.ae\0undersea.museum\0odda.no\0"
+"livinghistory.museum\0"
"net.cn\0"
-"net.co\0c.la\0"
-"gliwice.pl\0"
-"aurskog-h\xc3\xb8land.no\0"
-"andria-trani-barletta.it\0"
-"net.cu\0loab\xc3\xa1t.no\0"
-"rep.kp\0"
-"\xe7\xbb\x84\xe7\xb9\x94.hk\0"
-"gallery.museum\0"
-"\xc3\xb8rland.no\0"
-"store.ro\0"
-"net.dm\0"
-"somna.no\0"
-"hemnes.no\0"
-"ringebu.no\0k12.ky.us\0"
-"net.ec\0"
-"dn.ua\0"
-"tarnobrzeg.pl\0"
-"soc.lk\0"
-"romsa.no\0"
-"bamble.no\0"
-"net.dz\0lutsk.ua\0"
-"barlettatraniandria.it\0ta.it\0countryestate.museum\0"
-"kaszuby.pl\0"
-"*.yamaguchi.jp\0cranbrook.museum\0store.st\0"
-"southcarolina.museum\0lib.md.us\0"
-"textile.museum\0"
-"cheltenham.museum\0hurum.no\0"
-"*.oita.jp\0"
-"shop.ht\0cc.me.us\0"
-"shop.hu\0turin.it\0"
-"louvre.museum\0"
-"k12.ar.us\0"
-"consulting.aero\0"
-"gv.ao\0"
-"sauherad.no\0"
-"gv.at\0net.ge\0"
-"ostre-toten.no\0lib.ok.us\0"
-"net.gg\0pilots.museum\0"
-"2000.hu\0geology.museum\0"
-"net.gn\0"
-"mazowsze.pl\0bir.ru\0"
+"net.co\0ryuoh.shiga.jp\0"
+"krokstadelva.no\0"
+"lib.wa.us\0"
+"cat\0"
+"oz.au\0net.cu\0from-sc.com\0"
+"chocolate.museum\0"
+"sch.ae\0"
+"iwate.jp\0"
+"museum.tt\0com.ws\0"
+"net.dm\0selje.no\0is-very-good.org\0"
+"net.do\0"
+"net.ec\0gildesk\xc3\xa5l.no\0"
+"moriyoshi.akita.jp\0rl.no\0mo.us\0blogspot.re\0"
+"net.eg\0"
+"hachioji.tokyo.jp\0childrens.museum\0"
+"shizuoka.jp\0"
+"net.dz\0"
+"minamiizu.shizuoka.jp\0"
+"is-a-patsfan.org\0"
+"inagawa.hyogo.jp\0blogspot.ro\0"
+"yamagata.jp\0gsm.pl\0"
+"suldal.no\0dlugoleka.pl\0blogspot.se\0"
+"blogspot.sg\0"
+"\xd8\xa7\xd9\x8a\xd8\xb1\xd8\xa7\xd9\x86\0dnsalias.com\0"
+"kamikawa.hokkaido.jp\0kamoenai.hokkaido.jp\0"
+"blogspot.sk\0"
+"siracusa.it\0k12.wi.us\0"
+"oksnes.no\0\xed\x95\x9c\xea\xb5\xad\0"
+"vardo.no\0starachowice.pl\0"
+"net.ge\0ishinomaki.miyagi.jp\0oji.nara.jp\0\xd8\xa7\xd9\x84\xd8\xb3\xd8\xb9\xd9\x88\xd8\xaf\xdb\x8c\xdb\x83\0blogspot.td\0"
+"trustee.museum\0"
+"net.gg\0"
+"misato.saitama.jp\0"
+"ppg.br\0"
+"net.gn\0chikuho.fukuoka.jp\0"
"net.gp\0"
-"net.gr\0"
-"oxford.museum\0"
-"per.la\0"
-"eastafrica.museum\0"
-"meeres.museum\0"
-"net.gy\0*.shizuoka.jp\0"
-"\xe5\x95\x86\xe6\xa5\xad.tw\0"
-"net.hk\0"
+"osoyro.no\0dyndns-office.com\0"
+"net.gr\0higashikawa.hokkaido.jp\0"
+"net.gt\0monzabrianza.it\0mr.no\0eidsvoll.no\0"
+"aridagawa.wakayama.jp\0"
+"sykkylven.no\0"
+"minamiaiki.nagano.jp\0blogspot.tw\0"
+"net.gy\0naturhistorisches.museum\0"
+"net.hk\0zaporizhzhia.ua\0"
+"mifune.kumamoto.jp\0"
"net.hn\0"
-"philadelphiaarea.museum\0"
-"osen.no\0"
+"kahoku.yamagata.jp\0"
+"asakawa.fukushima.jp\0"
+"barlettatraniandria.it\0blogspot.mr\0"
"net.ht\0net.id\0"
-"fundacio.museum\0"
-"j\xc3\xb8rpeland.no\0"
-"\xe6\x95\x99\xe8\x82\xb2.hk\0"
-"divtasvuodna.no\0"
-"student.aero\0sch.gg\0net.im\0"
-"\xe7\xbd\x91\xe7\xbb\x9c.cn\0net.in\0"
+"b.se\0"
+"ud.it\0tsuchiura.ibaraki.jp\0naturalhistory.museum\0"
+"matsushige.tokushima.jp\0nanto.toyama.jp\0from-al.com\0"
+"blogspot.mx\0"
+"nagakute.aichi.jp\0zamami.okinawa.jp\0"
+"net.im\0ikawa.akita.jp\0lib.ne.us\0blogspot.nl\0"
+"net.in\0"
+"yokkaichi.mie.jp\0"
+"blogspot.no\0"
"net.iq\0"
"net.ir\0"
"net.is\0"
"net.je\0"
-"kepno.pl\0lapy.pl\0"
-"per.nf\0"
-"gov\0*.shimane.jp\0"
-"artcenter.museum\0"
-"k\xc3\xa5""fjord.no\0"
-"net.jo\0"
-"eu.int\0"
-"c.se\0"
+"from.hr\0cc.oh.us\0"
+"biratori.hokkaido.jp\0"
+"sch.gg\0"
+"taxi.aero\0"
+"bi.it\0treviso.it\0"
+"ro.it\0"
+"mine.nu\0"
+"net.jo\0tenri.nara.jp\0alvdal.no\0"
+"ikeda.hokkaido.jp\0here-for-more.info\0"
+"owani.aomori.jp\0"
+"uri.arpa\0"
+"tsukui.kanagawa.jp\0bryne.no\0"
+"shibetsu.hokkaido.jp\0grozny.ru\0"
+"jewelry.museum\0"
"net.kg\0"
-"ce.it\0net.ki\0"
-"sch.id\0os.hedmark.no\0"
-"columbus.museum\0"
-"arteducation.museum\0"
+"net.ki\0"
+"sakura.chiba.jp\0nittedal.no\0"
+"kawazu.shizuoka.jp\0"
"net.kn\0"
-"kr.com\0"
-"net.la\0bushey.museum\0cc.gu.us\0"
-"net.lb\0"
+"net.la\0hoylandet.no\0"
+"net.lb\0\xc3\xa5mli.no\0"
"net.lc\0"
-"gs.bu.no\0"
-"e164.arpa\0"
-"chieti.it\0labour.museum\0"
-"sch.ir\0creation.museum\0krodsherad.no\0"
-"net.ky\0"
-"net.kz\0me.us\0"
-"e.bg\0sch.je\0net.lk\0"
-"zlg.br\0suwalki.pl\0"
-"\xe5\x80\x8b\xe4\xba\xba.hk\0net.ma\0"
-"net.lr\0"
-"sch.jo\0notaires.km\0net.me\0"
-"net.lv\0karate.museum\0"
-"net.ly\0karm\xc3\xb8y.no\0"
-"rg.it\0"
+"mihama.fukui.jp\0yamagata.gifu.jp\0blogspot.pt\0"
+"sch.id\0"
+"aca.pro\0"
+"sanjo.niigata.jp\0net.ky\0"
+"tsukumi.oita.jp\0net.kz\0oceanographic.museum\0k12.nm.us\0"
+"h.bg\0net.lk\0"
+"miharu.fukushima.jp\0"
+"aknoluokta.no\0"
+"net.ma\0"
+"tw.cn\0net.lr\0"
+"kamikitayama.nara.jp\0miyashiro.saitama.jp\0chernihiv.ua\0"
+"ichikawa.hyogo.jp\0comunica\xc3\xa7\xc3\xb5""es.museum\0"
+"sch.ir\0oki.fukuoka.jp\0yoshioka.gunma.jp\0akkeshi.hokkaido.jp\0net.me\0kazimierz-dolny.pl\0blogspot.it\0"
+"net.lv\0"
+"sch.je\0yoshida.saitama.jp\0"
+"net.ly\0"
"net.mk\0"
-"net.ml\0evenes.no\0"
-"ngo.lk\0net.mo\0egyptian.museum\0"
-"marine.ru\0"
-"realestate.pl\0"
+"net.ml\0"
+"museum.mv\0"
+"hokkaido.jp\0net.mo\0museum.mw\0"
+"\xc3\xa1lt\xc3\xa1.no\0vestnes.no\0"
+"blogspot.jp\0"
+"sch.jo\0"
+"yokoze.saitama.jp\0stathelle.no\0blogspot.com.ar\0"
"net.mu\0"
"net.mv\0net.nf\0"
-"net.mw\0net.ng\0gda.pl\0"
+"adult.ht\0ne.jp\0coldwar.museum\0net.mw\0net.ng\0museum.no\0blogspot.com.au\0"
"net.mx\0"
-"freemasonry.museum\0net.my\0enebakk.no\0"
-"karlsoy.no\0"
-"\xe7\xbd\x91\xe7\xbb\x9c.hk\0\xc3\xb8rskog.no\0"
-"randaberg.no\0"
-"club.aero\0"
-"certification.aero\0sr.it\0"
-"center.museum\0so.gov.pl\0"
-"caa.aero\0"
-"sch.lk\0tvedestrand.no\0"
+"skydiving.aero\0net.my\0"
+"nakasatsunai.hokkaido.jp\0"
+"undersea.museum\0"
+"kainan.wakayama.jp\0sebastopol.ua\0cc.hi.us\0"
+"gamagori.aichi.jp\0"
+"gyeongbuk.kr\0"
"net.nr\0"
-"luroy.no\0"
-"aukra.no\0s\xc3\xa1lat.no\0lib.me.us\0"
-"ddr.museum\0"
-"york.museum\0stryn.no\0k12.nm.us\0"
-"per.sg\0"
-"judaica.museum\0"
-"verona.it\0"
-"agdenes.no\0"
-"cng.br\0sch.ly\0"
-"net.pa\0"
-"author.aero\0"
-"naturalhistory.museum\0steiermark.museum\0bu.no\0"
-"sn\xc3\xa5sa.no\0net.pe\0"
-"net.ph\0"
-"savannahga.museum\0batsfjord.no\0lib.oh.us\0"
+"jorpeland.no\0blogspot.kr\0"
+"bellevue.museum\0blogspot.com.br\0"
+"kanegasaki.iwate.jp\0"
+"ne.kr\0"
+"aosta.it\0mima.tokushima.jp\0"
+"pro.az\0km.ua\0"
+"nakanoto.ishikawa.jp\0sch.lk\0"
+"nome.pt\0"
+"nagareyama.chiba.jp\0himeji.hyogo.jp\0denmark.museum\0"
+"echizen.fukui.jp\0net.pa\0\xe4\xb8\xad\xe5\x9b\xbd\0from-oh.com\0"
+"kongsvinger.no\0ringebu.no\0"
+"tsukigata.hokkaido.jp\0m\xc3\xa5s\xc3\xb8y.no\0"
+"pro.br\0net.pe\0bar.pro\0"
+"viterbo.it\0heroy.more-og-romsdal.no\0"
+"omihachiman.shiga.jp\0labor.museum\0"
+"toho.fukuoka.jp\0tome.miyagi.jp\0net.ph\0"
"net.pk\0"
-"net.pl\0"
-"net.pn\0"
-"washingtondc.museum\0"
+"sch.ly\0net.pl\0"
+"saijo.ehime.jp\0"
+"shiojiri.nagano.jp\0net.pn\0"
+"newport.museum\0\xe4\xb8\xad\xe5\x9c\x8b\0"
+"\xe6\x95\x8e\xe8\x82\xb2.hk\0net.qa\0"
"net.pr\0"
"net.ps\0"
"net.pt\0"
-"nordkapp.no\0"
-"emergency.aero\0krokstadelva.no\0"
-"satx.museum\0ngo.ph\0omsk.ru\0"
-"texas.museum\0"
-"ngo.pl\0"
-"mantova.it\0gu.us\0"
-"!pref.shiga.jp\0isa.us\0"
-"usa.museum\0"
-"gb.net\0k12.vi\0"
-"iveland.no\0"
-"tempio-olbia.it\0"
+"akrehamn.no\0"
+"oshu.iwate.jp\0lincoln.museum\0fjell.no\0"
+"selfip.info\0"
+"hol.no\0"
+"net.py\0"
+"blogspot.fi\0"
+"kakegawa.shizuoka.jp\0cc.co.us\0"
+"com\0schoenbrunn.museum\0"
+"microlight.aero\0"
+"shimogo.fukushima.jp\0"
+"leirvik.no\0"
+"veg\xc3\xa5rshei.no\0blogspot.fr\0"
+"blogspot.com.es\0"
+"pro.ec\0"
+"civilisation.museum\0"
+"g\xc3\xa1\xc5\x8bgaviika.no\0"
+"nago.okinawa.jp\0"
+"station.museum\0"
+"akashi.hyogo.jp\0ichinohe.iwate.jp\0"
+"tsukiyono.gunma.jp\0"
+"b\xc3\xa1hcavuotna.no\0"
+"notogawa.shiga.jp\0sciencehistory.museum\0s\xc3\xb8r-fron.no\0"
"net.sa\0"
"net.sb\0"
-"works.aero\0net.sc\0komvux.se\0"
+"net.sc\0blogspot.gr\0"
"net.sd\0"
-"net.ru\0"
-"0.bg\0"
-"forlicesena.it\0net.rw\0net.sg\0"
-"klodzko.pl\0"
-"detroit.museum\0wegrow.pl\0"
-"net.sl\0"
-"glogow.pl\0"
-"store.bb\0air.museum\0"
-"net.so\0"
-"katowice.pl\0"
-"nsk.ru\0"
-"pisa.it\0eid.no\0"
-"net.st\0"
-"film.hu\0"
-"tuva.ru\0d.se\0"
+"mandal.no\0net.ru\0"
+"net.rw\0e.se\0net.sg\0"
+"flight.aero\0alabama.museum\0net.sh\0"
+"dgca.aero\0dominic.ua\0"
+"vestby.no\0"
+"kuroishi.aomori.jp\0gs.hl.no\0"
+"sorfold.no\0net.sl\0blogspot.hk\0"
+"nemuro.hokkaido.jp\0l\xc3\xa1hppi.no\0wi.us\0"
+"tsuno.miyazaki.jp\0net.so\0"
+"giessen.museum\0"
+"l\xc3\xb8ten.no\0dn.ua\0"
+"wada.nagano.jp\0"
+"sch.qa\0net.st\0"
+"shiroishi.saga.jp\0"
+"blogspot.hu\0blogspot.ie\0"
+"teramo.it\0kuzumaki.iwate.jp\0"
"net.th\0"
"net.sy\0"
-"viterbo.it\0tsaritsyn.ru\0perso.sn\0net.tj\0"
-"lib.gu.us\0"
-"plc.co.im\0sec.ps\0"
-"r\xc3\xa1hkker\xc3\xa1vju.no\0kazimierz-dolny.pl\0net.tn\0"
-"net.to\0"
-"veterinaire.km\0"
+"net.tj\0cc.ok.us\0"
+"uozu.toyama.jp\0net.tm\0"
+"bl.it\0naoshima.kagawa.jp\0ne.pw\0net.tn\0"
+"ohi.fukui.jp\0fusa.no\0net.to\0blogspot.in\0"
+"hirakata.osaka.jp\0"
"net.ua\0"
-"info.ht\0net.tt\0"
-"info.hu\0"
-"exchange.aero\0"
-"sch.sa\0net.tw\0"
-"andriatranibarletta.it\0perso.tn\0"
-"f.bg\0malselv.no\0"
+"fujiyoshida.yamanashi.jp\0beskidy.pl\0"
+"ed.ao\0net.tt\0"
+"kochi.kochi.jp\0"
+"southcarolina.museum\0valle.no\0blogspot.be\0dnsdojo.net\0"
+"tomika.gifu.jp\0muosat.no\0net.tw\0"
+"minamiyamashiro.kyoto.jp\0"
+"itano.tokushima.jp\0blogspot.bj\0"
+"tainai.niigata.jp\0zachpomor.pl\0"
+"komono.mie.jp\0project.museum\0"
+"blogspot.ca\0"
"net.vc\0"
-"trana.no\0"
-"ns.ca\0"
-"net.vi\0"
-"lucca.it\0oristano.it\0"
-"usarts.museum\0net.vn\0"
-"gon.pk\0"
-"pl.ua\0"
-"eastcoast.museum\0"
-"novara.it\0"
-"k12.ks.us\0"
-"dp.ua\0"
-"nesseby.no\0"
-"!pref.wakayama.jp\0"
-"repbody.aero\0"
-"jamison.museum\0lugansk.ua\0"
-"ss.it\0"
-"alessandria.it\0"
-"hadsel.no\0net.ws\0"
-"\xe0\xae\x9a\xe0\xae\xbf\xe0\xae\x99\xe0\xaf\x8d\xe0\xae\x95\xe0\xae\xaa\xe0\xaf\x8d\xe0\xae\xaa\xe0\xaf\x82\xe0\xae\xb0\xe0\xaf\x8d\0"
-"veterinaire.fr\0leirfjord.no\0"
-"massacarrara.it\0north.museum\0"
-"project.museum\0"
-"other.nf\0"
-"k12.nh.us\0"
-"mat.br\0artgallery.museum\0"
-"sr.gov.pl\0"
-"gamvik.no\0"
-"info.ec\0lancashire.museum\0"
-"fm.br\0ltd.co.im\0"
-"americana.museum\0southwest.museum\0cc.ak.us\0"
-"enna.it\0lunner.no\0"
-"v\xc3\xa5gan.no\0"
-"mari.ru\0"
-"accident-investigation.aero\0"
-"sor-aurdal.no\0lib.ny.us\0"
-"novosibirsk.ru\0"
-"bjugn.no\0"
-"n\xc3\xa6r\xc3\xb8y.no\0ostrowwlkp.pl\0"
-"info.bb\0foundation.museum\0"
-"brand.se\0"
-"info.at\0!pref.akita.jp\0l\xc3\xb8ten.no\0"
-"coal.museum\0miners.museum\0"
-"glass.museum\0"
-"info.az\0"
-"frog.museum\0szczytno.pl\0nov.ru\0"
-"sunndal.no\0"
-"gen.in\0"
-"gx.cn\0"
-"web.co\0*.mie.jp\0hobol.no\0\xe5\x8f\xb0\xe6\xb9\xbe\0"
-"logistics.aero\0plo.ps\0"
-"erotika.hu\0"
-"torsken.no\0"
-"exeter.museum\0"
-"info.co\0"
-"selje.no\0"
-"storfjord.no\0"
-"barum.no\0lind\xc3\xa5s.no\0"
+"aerobatic.aero\0benevento.it\0sch.sa\0"
+"nakadomari.aomori.jp\0ibara.okayama.jp\0net.ve\0"
+"elvendrell.museum\0"
+"pro.ht\0tomari.hokkaido.jp\0blogspot.cf\0"
+"hikimi.shimane.jp\0"
+"net.uy\0net.vi\0blogspot.ch\0"
+"net.uz\0"
+"servebbs.com\0"
+"k.bg\0"
+"ed.ci\0net.vn\0"
+"paragliding.aero\0otobe.hokkaido.jp\0"
+"sakai.fukui.jp\0"
+"rikuzentakata.iwate.jp\0"
+"journalism.museum\0"
+"news.hu\0"
+"susono.shizuoka.jp\0blogspot.de\0"
+"ed.cr\0mediocampidano.it\0blogspot.cv\0"
+"soma.fukushima.jp\0blogspot.com\0"
+"blogspot.cz\0is-a-player.com\0"
+"blogspot.dk\0"
+"consulado.st\0"
+"shingu.fukuoka.jp\0"
+"inami.wakayama.jp\0"
+"education.museum\0"
+"sciencecenters.museum\0net.ws\0"
+"lib.ga.us\0"
+"bergen.no\0"
+"prato.it\0shiwa.iwate.jp\0"
+"bo.nordland.no\0"
+"foggia.it\0"
+"pp.az\0ne.ug\0"
+"chirurgiens-dentistes.fr\0"
+"toyama.jp\0ne.tz\0"
+"forum.hu\0chita.aichi.jp\0"
+"nisshin.aichi.jp\0"
+"lc.it\0mitake.gifu.jp\0solund.no\0"
+"ogose.saitama.jp\0"
+"kunst.museum\0"
+"ne.us\0"
+"furukawa.miyagi.jp\0"
+"nakatombetsu.hokkaido.jp\0lib.tn.us\0"
+"\xc3\xa5l.no\0"
+"fareast.ru\0"
+"railroad.museum\0"
+"yamaguchi.jp\0sakae.chiba.jp\0"
+"atsuma.hokkaido.jp\0minamimaki.nagano.jp\0"
+"marker.no\0"
+"yabuki.fukushima.jp\0from-ak.com\0"
+"settlers.museum\0rubtsovsk.ru\0"
+"akabira.hokkaido.jp\0"
+"pro.na\0"
+"yurihonjo.akita.jp\0"
+"kuji.iwate.jp\0"
+"morotsuka.miyazaki.jp\0pro.mv\0"
+"mx.na\0"
+"cargo.aero\0ohira.tochigi.jp\0"
+"fyresdal.no\0"
+"trieste.it\0tokyo.jp\0"
+"midori.chiba.jp\0"
+"manx.museum\0"
+"soo.kagoshima.jp\0kunstsammlung.museum\0rzeszow.pl\0"
+"samegawa.fukushima.jp\0"
"leasing.aero\0"
-"championship.aero\0fst.br\0"
-"lierne.no\0"
-"!gobiernoelectronico.ar\0""1.bg\0"
-"corporation.museum\0"
-"al.it\0*.miyagi.jp\0"
-"*.aomori.jp\0"
-"\xd8\xa7\xd9\x84\xd8\xa7\xd8\xb1\xd8\xaf\xd9\x86\0"
-"amursk.ru\0"
-"vestvagoy.no\0"
-"\xd8\xa7\xdb\x8c\xd8\xb1\xd8\xa7\xd9\x86.ir\0cc.fl.us\0"
-"os.hordaland.no\0"
-"pistoia.it\0"
-"tver.ru\0e.se\0"
-"res.in\0*.yamagata.jp\0syzran.ru\0"
-"capebreton.museum\0sandnessj\xc3\xb8""en.no\0"
-"ternopil.ua\0"
-"shop.pl\0"
-"tank.museum\0"
-"m\xc3\xa5s\xc3\xb8y.no\0"
-"potenza.it\0time.museum\0"
-"mjondalen.no\0"
-"eng.br\0nedre-eiker.no\0"
-"air-surveillance.aero\0"
-"nt.au\0am.br\0pn.it\0"
-"oystre-slidre.no\0ug.gov.pl\0"
-"g.bg\0nesodden.no\0vologda.ru\0"
-"parma.it\0tula.ru\0"
-"*.nara.jp\0ak.us\0"
-"nt.ca\0konin.pl\0"
-"kiev.ua\0"
-"skierv\xc3\xa1.no\0vestre-toten.no\0"
-"ri.it\0botanical.museum\0farsund.no\0veg\xc3\xa5rshei.no\0dagestan.ru\0"
-"ind.br\0k-uralsk.ru\0"
-"rahkkeravju.no\0cmw.ru\0"
-"canada.museum\0"
-"fm.it\0"
-"cc.wi.us\0"
-"web.id\0aver\xc3\xb8y.no\0"
-"dudinka.ru\0"
-"baghdad.museum\0fitjar.no\0grane.no\0"
-"gs.fm.no\0"
-"sumy.ua\0"
-"al.no\0"
-"westfalen.museum\0"
-"oregon.museum\0"
-"bruxelles.museum\0elk.pl\0"
-"planetarium.museum\0sn\xc3\xa5""ase.no\0"
-"s\xc3\xb8rreisa.no\0"
-"gs.st.no\0skien.no\0"
-"bible.museum\0ivanovo.ru\0"
-"avellino.it\0"
-"tgory.pl\0"
-"family.museum\0"
-"ppg.br\0k12.as.us\0"
-"trader.aero\0gorlice.pl\0"
-"cc.al.us\0"
-"ogliastra.it\0"
-"is.it\0lib.nv.us\0"
-"dr.na\0"
-"media.hu\0nesna.no\0fl.us\0"
-"uri.arpa\0"
-"bjerkreim.no\0"
-"charter.aero\0"
-"genova.it\0"
-"it.ao\0botany.museum\0hapmir.no\0"
-"educational.museum\0"
-"helsinki.museum\0"
-"memorial.museum\0"
-"web.lk\0pharmacy.museum\0"
-"aircraft.aero\0appspot.com\0"
-"ferrara.it\0beskidy.pl\0"
-"hi.cn\0"
-"taxi.aero\0flekkefjord.no\0"
-"varoy.no\0"
-"ragusa.it\0ambulance.museum\0"
-"can.museum\0"
-"*.osaka.jp\0isleofman.museum\0fm.no\0warmia.pl\0"
-"educator.aero\0asmatart.museum\0"
-"mi.it\0"
-"kutno.pl\0"
-"skedsmokorset.no\0"
-"2.bg\0"
-"*.kagoshima.jp\0km.ua\0"
-"!city.sendai.jp\0"
-"web.nf\0st.no\0cc.ri.us\0"
-"reggiocalabria.it\0"
-"wi.us\0"
-"ancona.it\0newjersey.museum\0nnov.ru\0"
-"f.se\0"
-"ind.in\0"
-"info.vn\0"
-"andoy.no\0"
-"ch.it\0fredrikstad.no\0guovdageaidnu.no\0"
-"fjaler.no\0"
-"sa.com\0"
-"gs.nt.no\0"
-"masfjorden.no\0"
-"pordenone.it\0"
-"po.it\0basel.museum\0"
-"chambagri.fr\0"
-"h.bg\0web.pk\0"
-"london.museum\0"
-"sciencecenter.museum\0\xe0\xb9\x84\xe0\xb8\x97\xe0\xb8\xa2\0"
-"unbi.ba\0augustow.pl\0"
-"wolomin.pl\0"
-"notaires.fr\0tcm.museum\0al.us\0"
-"nu.ca\0!pref.nagano.jp\0"
-"info.tn\0"
-"lib.wa.us\0"
-"ed.ao\0info.tt\0"
-"barreau.bj\0"
-"k12.wy.us\0"
-"pp.az\0gop.pk\0"
-"int\0"
-"l\xc3\xb8renskog.no\0podhale.pl\0"
-"voagat.no\0"
-"telekommunikation.museum\0"
-"qld.au\0"
-"te.it\0freiburg.museum\0snasa.no\0"
-"gjemnes.no\0"
-"sejny.pl\0"
-"media.pl\0"
-"skjak.no\0"
-"watchandclock.museum\0"
-"ed.ci\0pacific.museum\0"
-"theater.museum\0info.ro\0"
-"uk.com\0"
-"campobasso.it\0aquarium.museum\0tysv\xc3\xa6r.no\0"
-"kragero.no\0"
-"windmill.museum\0info.sd\0"
-"sologne.museum\0sande.m\xc3\xb8re-og-romsdal.no\0"
-"nt.no\0cc.mi.us\0"
-"ed.cr\0"
-"academy.museum\0zachpomor.pl\0"
-"tananger.no\0v\xc3\xa1rgg\xc3\xa1t.no\0ri.us\0"
+"higashi.fukuoka.jp\0kids.us\0"
+"assedic.fr\0"
+"state.museum\0czest.pl\0"
+"wallonie.museum\0podzone.org\0"
+"hitoyoshi.kumamoto.jp\0"
+"hamura.tokyo.jp\0"
+"h.se\0"
+"minoh.osaka.jp\0"
+"tako.chiba.jp\0kafjord.no\0"
+"freemasonry.museum\0"
+"lib.mo.us\0"
+"ed.jp\0pro.pr\0"
+"film.hu\0"
+"act.au\0"
+"in.na\0"
+"no.com\0"
+"higashiizumo.shimane.jp\0elburg.museum\0"
+"siedlce.pl\0"
+"bo.it\0"
+"chikugo.fukuoka.jp\0from-mo.com\0"
+"!city.kitakyushu.jp\0sopot.pl\0"
+"togura.nagano.jp\0"
+"handson.museum\0sb.ua\0"
+"rennebu.no\0"
+"milan.it\0"
+"kamioka.akita.jp\0"
+"cc.mi.us\0"
+"from-de.com\0"
+"urayasu.chiba.jp\0"
+"varggat.no\0"
+"takatsuki.shiga.jp\0k12.ms.us\0k12.nc.us\0"
+"n.bg\0sakaki.nagano.jp\0"
+"uwajima.ehime.jp\0skaun.no\0"
+"kursk.ru\0"
+"tabayama.yamanashi.jp\0"
+"ryazan.ru\0"
+"oyabe.toyama.jp\0health.vn\0"
+"higashiyoshino.nara.jp\0"
+"isen.kagoshima.jp\0nogi.tochigi.jp\0broadcast.museum\0"
+"iitate.fukushima.jp\0yawata.kyoto.jp\0daegu.kr\0"
+"obihiro.hokkaido.jp\0rebun.hokkaido.jp\0kamo.niigata.jp\0"
+"vrn.ru\0"
+"higashimurayama.tokyo.jp\0"
+"ora.gunma.jp\0shimoji.okinawa.jp\0pro.tt\0lib.wv.us\0"
+"odate.akita.jp\0"
+"shoo.okayama.jp\0"
+"tula.ru\0"
+"uchinada.ishikawa.jp\0"
+"sh.cn\0kawahara.tottori.jp\0"
+"ingatlan.hu\0chikuma.nagano.jp\0vaksdal.no\0"
+"foundation.museum\0"
+"lewismiller.museum\0"
+"trentino.it\0"
+"qc.ca\0piacenza.it\0bokn.no\0"
+"in.rs\0tom.ru\0"
+"cng.br\0lebesby.no\0nh.us\0k12.ia.us\0"
+"noto.ishikawa.jp\0arita.saga.jp\0"
+"svizzera.museum\0ask\xc3\xb8y.no\0"
+"kiyose.tokyo.jp\0frosta.no\0"
+"ks.ua\0pro.vn\0"
+"namsos.no\0"
"federation.aero\0"
-"web.tj\0"
-"matta-varjjat.no\0"
-"steigen.no\0"
-"local\0akrehamn.no\0"
-"!pref.chiba.jp\0info.pk\0"
-"info.pl\0""6bone.pl\0"
-"klepp.no\0kherson.ua\0"
-"ketrzyn.pl\0info.pr\0"
-"sweden.museum\0"
-"lardal.no\0"
-"!retina.ar\0gz.cn\0"
-"barletta-trani-andria.it\0vikna.no\0"
-"bearalv\xc3\xa1hki.no\0"
-"broker.aero\0gov.nc.tr\0"
-"info.na\0k12.fl.us\0"
-"hembygdsforbund.museum\0"
-"entertainment.aero\0jerusalem.museum\0l\xc3\xa6rdal.no\0"
-"hitra.no\0sogndal.no\0"
-"farmequipment.museum\0info.mv\0info.nf\0\xc3\xa5lg\xc3\xa5rd.no\0"
-"la-spezia.it\0"
-"skanland.no\0fam.pk\0"
-"skole.museum\0"
-"art.museum\0"
-"presidio.museum\0"
-"3.bg\0public.museum\0"
-"h\xc3\xb8yanger.no\0zagan.pl\0"
-"an.it\0"
-"philadelphia.museum\0info.nr\0"
-"pesarourbino.it\0g\xc3\xa1ivuotna.no\0"
+"naumburg.museum\0"
+"szczecin.pl\0"
+"koza.wakayama.jp\0"
"poltava.ua\0"
-"nt.ro\0"
-"station.museum\0"
-"mi.th\0"
-"altoadige.it\0"
-"nu.it\0"
-"usculture.museum\0g.se\0"
-"h\xc3\xa1mm\xc3\xa1rfeasta.no\0"
-"daegu.kr\0info.la\0"
-"dovre.no\0"
-"ci.it\0horology.museum\0"
-"bergbau.museum\0"
-"press.museum\0"
-"gangwon.kr\0"
-"!city.kitakyushu.jp\0sor-varanger.no\0cc.hi.us\0"
-"fuossko.no\0"
-"zp.ua\0"
-"american.museum\0"
-"fl\xc3\xa5.no\0mi.us\0"
-"i.bg\0"
-"od.ua\0"
-"encyclopedic.museum\0"
-"ind.tn\0"
-"midatlantic.museum\0"
-"newyork.museum\0"
-"castres.museum\0"
-"act.edu.au\0"
-"topology.museum\0"
-"ed.jp\0"
-"of.by\0"
-"iris.arpa\0inf.br\0askim.no\0pyatigorsk.ru\0"
-"nord-fron.no\0nsn.us\0"
-"beardu.no\0"
-"agrar.hu\0corvette.museum\0chtr.k12.ma.us\0"
+"sorum.no\0ed.pw\0from-ky.com\0"
+"nishiazai.shiga.jp\0"
+"in.th\0"
+"moseushi.hokkaido.jp\0sn\xc3\xa5sa.no\0"
+"nankoku.kochi.jp\0"
+"orland.no\0"
+"miyoshi.tokushima.jp\0larvik.no\0ks.us\0"
+"loppa.no\0"
+"*.kobe.jp\0childrensgarden.museum\0"
+"sakai.ibaraki.jp\0\xd8\xa7\xd9\x84\xd9\x8a\xd9\x85\xd9\x86\0"
+"in.ua\0"
+"inf.br\0\xe7\xbd\x91\xe7\xb5\xa1.hk\0h\xc3\xb8ylandet.no\0skedsmo.no\0"
+"dynalias.org\0"
+"kurobe.toyama.jp\0gol.no\0"
+"not.br\0shingu.wakayama.jp\0"
+"nakai.kanagawa.jp\0cc.de.us\0"
+"azumino.nagano.jp\0rade.no\0"
+"dyndns-at-work.com\0"
+"travel.pl\0"
+"katsuura.chiba.jp\0"
+"oiso.kanagawa.jp\0"
+"it.ao\0cim.br\0in.us\0"
+"bamble.no\0"
+"inf.cu\0mimata.miyazaki.jp\0"
+"bo.telemark.no\0"
+"karasjohka.no\0"
+"hanyu.saitama.jp\0artanddesign.museum\0"
+"padua.it\0"
+"health.museum\0"
+"edu\0aseral.no\0"
+"carbonia-iglesias.it\0nikaho.akita.jp\0"
+"r\xc3\xb8ros.no\0"
+"matsudo.chiba.jp\0yoshinogari.saga.jp\0"
+"\xc3\xb8ystre-slidre.no\0k.se\0"
+"bodo.no\0holmestrand.no\0vestvagoy.no\0"
+"horokanai.hokkaido.jp\0matsue.shimane.jp\0"
+"oyodo.nara.jp\0dnsalias.net\0"
+"fr\xc3\xb8ya.no\0"
+"monzaebrianza.it\0katagami.akita.jp\0istmein.de\0"
+"tochigi.tochigi.jp\0lea\xc5\x8bgaviika.no\0komforb.se\0"
+"design.museum\0"
+"hanamigawa.chiba.jp\0"
+"zj.cn\0nahari.kochi.jp\0discovery.museum\0"
+"carraramassa.it\0elk.pl\0"
+"cc.pa.us\0"
+"kaga.ishikawa.jp\0tokamachi.niigata.jp\0"
+"br.it\0cb.it\0"
+"plc.ly\0agrinet.tn\0"
+"gs.fm.no\0surgut.ru\0"
+"usa.museum\0pp.ru\0pp.se\0"
+"lib.la.us\0"
+"go.ci\0\xe8\x87\xba\xe7\x81\xa3\0"
+"rodoy.no\0"
+"niikappu.hokkaido.jp\0"
+"kure.hiroshima.jp\0fudai.iwate.jp\0maizuru.kyoto.jp\0"
+"passenger-association.aero\0iveland.no\0"
+"go.cr\0takayama.nagano.jp\0"
+"game.tw\0"
+"tvedestrand.no\0chernovtsy.ua\0"
+"entertainment.aero\0trader.aero\0"
+"shikaoi.hokkaido.jp\0komagane.nagano.jp\0travel.tt\0"
+"katsushika.tokyo.jp\0"
+"suita.osaka.jp\0"
+"nasushiobara.tochigi.jp\0za.com\0"
+"q.bg\0cody.museum\0"
+"esp.br\0sagamihara.kanagawa.jp\0"
+"pp.ua\0"
+"andriatranibarletta.it\0mikawa.yamagata.jp\0naustdal.no\0"
+"takinoue.hokkaido.jp\0gs.oslo.no\0"
+"shiroishi.miyagi.jp\0community.museum\0bievat.no\0"
+"from-ia.com\0"
+"rep.kp\0luxembourg.museum\0"
+"sk.ca\0"
+"vic.gov.au\0"
+"yamanashi.yamanashi.jp\0hemne.no\0"
+"ulsan.kr\0k12.ky.us\0"
+"is-a-caterer.com\0"
+"kozagawa.wakayama.jp\0"
+"capebreton.museum\0"
+"is-a-musician.com\0"
+"kaita.hiroshima.jp\0"
+"seto.aichi.jp\0"
+"yoshino.nara.jp\0"
+"muenster.museum\0os\xc3\xb8yro.no\0"
+"li.it\0"
+"hokksund.no\0"
+"snz.ru\0"
+"hannan.osaka.jp\0brumunddal.no\0"
+"fukushima.jp\0"
+"tgory.pl\0kv.ua\0"
+"hachinohe.aomori.jp\0media.museum\0"
+"hidaka.saitama.jp\0"
+"oto.fukuoka.jp\0"
+"kozaki.chiba.jp\0"
+"sandnessjoen.no\0"
+"christiansburg.museum\0"
+"res.aero\0"
+"ashiya.hyogo.jp\0"
+"soeda.fukuoka.jp\0"
+"nuernberg.museum\0"
+"sakhalin.ru\0"
+"go.id\0soundandvision.museum\0"
+"tajimi.gifu.jp\0tonosho.kagawa.jp\0"
+"from-ut.com\0"
+"aki.kochi.jp\0"
+"niiza.saitama.jp\0"
+"stalowa-wola.pl\0"
+"from-ne.com\0"
+"tado.mie.jp\0abeno.osaka.jp\0bergbau.museum\0dallas.museum\0"
+"inf.mk\0cc.tn.us\0"
+"onomichi.hiroshima.jp\0saga.saga.jp\0"
+"go.it\0motoyama.kochi.jp\0"
+"iwakura.aichi.jp\0"
+"kashihara.nara.jp\0inagi.tokyo.jp\0"
+"\xe7\xbd\x91\xe7\xbb\x9c.cn\0judaica.museum\0"
+"ilawa.pl\0"
+"lib.pr.us\0"
+"buryatia.ru\0"
+"go.jp\0"
+"snasa.no\0"
+"otaki.chiba.jp\0"
+"mielno.pl\0"
+"tachiarai.fukuoka.jp\0settsu.osaka.jp\0"
+"hikari.yamaguchi.jp\0"
+"cc.as.us\0"
+"cc.ri.us\0"
+"jobs\0"
+"mail.pl\0"
+"santacruz.museum\0n.se\0"
+"hapmir.no\0"
+"go.kr\0k12.sc.us\0"
+"lib.ny.us\0"
+"nuoro.it\0"
+"sogndal.no\0sosnowiec.pl\0"
+"asaminami.hiroshima.jp\0"
+"isernia.it\0froland.no\0vang.no\0"
+"nanporo.hokkaido.jp\0"
+"dyndns-wiki.com\0"
+"bari.it\0bahcavuotna.no\0"
+"panama.museum\0santafe.museum\0"
+"ce.it\0shirakawa.gifu.jp\0"
+"aircraft.aero\0ptz.ru\0iamallama.com\0"
+"takayama.gunma.jp\0"
+"ama.aichi.jp\0"
+"yakumo.shimane.jp\0taito.tokyo.jp\0"
+"cmw.ru\0"
+"res.in\0"
+"hb.cn\0tohnosho.chiba.jp\0kashiba.nara.jp\0soni.nara.jp\0ostroleka.pl\0"
+"aogashima.tokyo.jp\0"
+"minano.saitama.jp\0lur\xc3\xb8y.no\0cc.mo.us\0"
+"gjerstad.no\0"
+"yashiro.hyogo.jp\0hitachiomiya.ibaraki.jp\0hakone.kanagawa.jp\0watch-and-clock.museum\0"
+"pv.it\0toyohashi.aichi.jp\0okuizumo.shimane.jp\0"
+"shop.ht\0olawa.pl\0"
+"shop.hu\0sukagawa.fukushima.jp\0marugame.kagawa.jp\0v\xc3\xa5g\xc3\xa5.no\0"
+"\xe7\xb5\x84\xe7\xbb\x87.hk\0usantiques.museum\0udm.ru\0"
+"railway.museum\0"
+"t.bg\0tsubetsu.hokkaido.jp\0kariwa.niigata.jp\0tsurugashima.saitama.jp\0"
+"etc.br\0"
+"obira.hokkaido.jp\0ide.kyoto.jp\0educational.museum\0bydgoszcz.pl\0"
"figueres.museum\0"
-"!pref.gunma.jp\0medizinhistorisches.museum\0"
-"tjeldsund.no\0"
-"nebraska.museum\0"
-"bellevue.museum\0"
-"abo.pa\0k12.al.us\0"
-"info.ki\0"
-"inf.cu\0sv.it\0"
-"jfk.museum\0"
-"!city.osaka.jp\0swinoujscie.pl\0"
-"bydgoszcz.pl\0"
-"!city.kyoto.jp\0"
-"uvic.museum\0"
-"madrid.museum\0steinkjer.no\0"
-"lib.ma.us\0"
-"sirdal.no\0"
-"n\xc3\xb8tter\xc3\xb8y.no\0"
-"taranto.it\0starnberg.museum\0"
-"vic.gov.au\0pvt.ge\0pors\xc3\xa1\xc5\x8bgu.no\0"
-"naroy.no\0ris\xc3\xb8r.no\0"
-"va.it\0salem.museum\0starachowice.pl\0"
-"!nawrastelecom.om\0"
-"town.museum\0te.ua\0"
-"se.net\0"
-"kemerovo.ru\0"
-"lerdal.no\0"
-"gs.va.no\0"
-"kms.ru\0"
-"consulado.st\0"
+"langevag.no\0"
+"tinn.no\0"
+"\xe7\xbd\x91\xe7\xbb\x9c.hk\0"
+"ens.tn\0"
+"vercelli.it\0"
+"ac.ae\0"
+"newspaper.museum\0"
+"potenza.it\0"
+"komatsushima.tokushima.jp\0"
+"gs.rl.no\0"
+"nakayama.yamagata.jp\0abu.yamaguchi.jp\0"
+"lind\xc3\xa5s.no\0pila.pl\0"
+"ac.at\0tamatsukuri.ibaraki.jp\0"
+"ac.be\0"
+"durham.museum\0"
+"sn.cn\0kadena.okinawa.jp\0atm.pl\0"
"haram.no\0"
-"tysnes.no\0"
-"!pref.ibaraki.jp\0hamburg.museum\0"
-"\xc3\xa5rdal.no\0"
-"airline.aero\0"
-"crew.aero\0newhampshire.museum\0"
-"muenster.museum\0"
-"aerodrome.aero\0"
-"heroy.nordland.no\0belau.pw\0"
-"kamchatka.ru\0"
-"b\xc3\xa5""d\xc3\xa5""ddj\xc3\xa5.no\0lillehammer.no\0hi.us\0"
-"hk.cn\0"
-"!city.kobe.jp\0berlevag.no\0"
-"ardal.no\0"
-"askoy.no\0"
-"vardo.no\0"
-"fyresdal.no\0"
-"sassari.it\0"
-"video.hu\0drammen.no\0"
-"lyngen.no\0nakhodka.ru\0"
-"ip6.arpa\0games.hu\0"
-"online.museum\0"
-"k12.sd.us\0"
-"4.bg\0sebastopol.ua\0"
-"ao.it\0atlanta.museum\0"
-"lebork.pl\0"
-"ravenna.it\0"
-"railway.museum\0songdalen.no\0"
-"!pref.shimane.jp\0delaware.museum\0ed.pw\0"
-"f\xc3\xb8rde.no\0"
-"living.museum\0"
-"juif.museum\0"
-"lomza.pl\0"
-"h.se\0"
-"!bl.uk\0"
-"portland.museum\0\xe7\xb5\x84\xe7\xb9\x94.tw\0"
-"stj\xc3\xb8rdal.no\0"
-"lecce.it\0"
-"bz.it\0"
-"farmstead.museum\0va.no\0"
-"express.aero\0!nacion.ar\0"
-"presse.km\0gs.of.no\0"
-"\xe5\x8f\xb0\xe7\x81\xa3\0"
-"og.ao\0gyeongbuk.kr\0vestv\xc3\xa5g\xc3\xb8y.no\0"
-"prd.fr\0"
-"pp.ru\0pp.se\0"
-"forum.hu\0!pref.saga.jp\0"
-"kvalsund.no\0"
-"!city.kawasaki.jp\0n\xc3\xa5\xc3\xa5mesjevuemie.no\0"
-"j.bg\0"
-"vlaanderen.museum\0"
-"cc.va.us\0"
-"\xd8\xa7\xd9\x8a\xd8\xb1\xd8\xa7\xd9\x86.ir\0alabama.museum\0"
-"school.museum\0her\xc3\xb8y.m\xc3\xb8re-og-romsdal.no\0"
-"\xc3\xa5seral.no\0"
-"traniandriabarletta.it\0"
-"flog.br\0"
-"presse.ml\0"
-"k\xc3\xa1r\xc3\xa1\xc5\xa1johka.no\0"
-"historisch.museum\0"
-"farm.museum\0palmsprings.museum\0oslo.no\0dyroy.no\0stranda.no\0"
-"gs.rl.no\0r\xc3\xa5""de.no\0"
-"bomlo.no\0s\xc3\xb8rum.no\0"
-"jan-mayen.no\0ivgu.no\0"
-"coop\0"
-"agr.br\0k12.ak.us\0"
-"!nic.ar\0catanzaro.it\0fusa.no\0"
-"hu.com\0"
-"inf.mk\0"
-"vet.br\0"
-"k12.mt.us\0k12.nd.us\0"
-"vlog.br\0\xe5\x85\xac\xe5\x8f\xb8.cn\0sandnessjoen.no\0"
-"lib.az.us\0"
-"nsw.edu.au\0of.no\0\xc3\xb8stre-toten.no\0"
-"*.okinawa.jp\0"
-"vb.it\0"
-"asso.fr\0firenze.it\0"
-"trieste.it\0"
-"\xe5\x85\xac\xe5\x8f\xb8.hk\0"
-"museet.museum\0"
-"prd.km\0"
-"navuotna.no\0lib.ca.us\0"
-"cc.nv.us\0"
-"asso.gp\0"
-"meraker.no\0"
-"h\xc3\xa1pmir.no\0"
-"i.ph\0"
-"sx.cn\0jeonnam.kr\0"
-"halden.no\0"
-"fed.us\0"
-"medio-campidano.it\0tsk.ru\0"
-"barcelona.museum\0"
-"giessen.museum\0roma.museum\0"
-"hl.cn\0"
-"\xe0\xae\x87\xe0\xae\xb2\xe0\xae\x99\xe0\xaf\x8d\xe0\xae\x95\xe0\xaf\x88\0"
-"biz.bb\0benevento.it\0rl.no\0bygland.no\0"
-"port.fr\0asso.ht\0prd.mg\0"
-"biz.at\0"
-"tra.kp\0"
-"*.aichi.jp\0khabarovsk.ru\0"
-"campidano-medio.it\0"
-"biz.az\0"
-"newmexico.museum\0va.us\0"
+"aichi.jp\0"
+"mihama.aichi.jp\0"
+"mizumaki.fukuoka.jp\0serveftp.net\0"
+"portland.museum\0from-in.com\0"
+"hagebostad.no\0"
+"nara.jp\0go.pw\0"
+"sa.edu.au\0ukiha.fukuoka.jp\0"
+"*.ar\0nyny.museum\0"
+"media.aero\0*.bd\0"
+"ine.kyoto.jp\0bu.no\0"
+"br.com\0"
+"ac.ci\0"
+"onagawa.miyagi.jp\0"
+"nt.au\0"
+"ac.cn\0from-tx.com\0"
+"*.bn\0"
+"sor-odal.no\0"
+"ac.cr\0ikeda.gifu.jp\0"
+"sobetsu.hokkaido.jp\0culture.museum\0zgrad.ru\0"
+"tadotsu.kagawa.jp\0"
+"machida.tokyo.jp\0chernigov.ua\0"
+"kembuchi.hokkaido.jp\0from-mi.com\0"
+"sor-aurdal.no\0"
+"pippu.hokkaido.jp\0"
+"nt.ca\0"
+"mitoyo.kagawa.jp\0"
+"*.ck\0tsuwano.shimane.jp\0gs.mr.no\0"
+"toyo.kochi.jp\0"
+"ky.us\0"
+"tranoy.no\0"
+"br\xc3\xb8nn\xc3\xb8ysund.no\0"
+"hemsedal.no\0"
+"rendalen.no\0"
+"*.cy\0utsira.no\0"
+"takasu.hokkaido.jp\0"
+"correios-e-telecomunica\xc3\xa7\xc3\xb5""es.museum\0"
+"tsuyama.okayama.jp\0beauxarts.museum\0"
+"gr.it\0"
+"firenze.it\0misugi.mie.jp\0and.museum\0"
+"go.th\0"
+"semboku.akita.jp\0"
+"tokushima.tokushima.jp\0go.tj\0"
+"buzen.fukuoka.jp\0"
+"land-4-sale.us\0"
+"nyc.museum\0"
+"mobi\0"
+"gr.jp\0"
+"raisa.no\0"
+"go.ug\0"
+"*.er\0go.tz\0"
+"*.et\0"
+"vc.it\0h\xc3\xa1pmir.no\0"
+"*.fj\0"
+"scientist.aero\0*.fk\0yamato.kumamoto.jp\0modalen.no\0stargard.pl\0"
+"ac.gn\0sumida.tokyo.jp\0"
+"historisches.museum\0"
+"kvits\xc3\xb8y.no\0"
+"store.nf\0"
+"yoka.hyogo.jp\0omachi.nagano.jp\0"
+"ch.it\0"
+"overhalla.no\0likescandy.com\0"
+"www.ro\0se.net\0"
+"nakamichi.yamanashi.jp\0"
+"adm.br\0dnipropetrovsk.ua\0"
+"vindafjord.no\0k12.ak.us\0is-a-rockstar.com\0"
+"ac.id\0minamiechizen.fukui.jp\0"
+"*.gu\0children.museum\0"
+"tsu.mie.jp\0"
+"fr\xc3\xa6na.no\0"
+"gliwice.pl\0"
+"he.cn\0aid.pl\0"
+"ac.im\0kishiwada.osaka.jp\0"
+"ac.in\0"
"finearts.museum\0"
-"murmansk.ru\0"
-"\xc3\xb8rsta.no\0radom.pl\0k12.sc.us\0"
-"5.bg\0kvinesdal.no\0"
-"ap.it\0"
-"*.fukushima.jp\0"
-"asso.bj\0"
-"mad.museum\0"
-"lebesby.no\0"
-"og.it\0glas.museum\0sauda.no\0"
-"i.se\0"
-"k12.tx.us\0"
-"asso.ci\0mk.ua\0"
-"cesena-forli.it\0"
-"lowicz.pl\0"
-"k12.id.us\0"
-"tas.gov.au\0"
-"lukow.pl\0"
-"utazas.hu\0"
-"maritimo.museum\0bjark\xc3\xb8y.no\0"
-"adm.br\0"
-"pr.it\0lib.vi.us\0"
-"bergamo.it\0k12.va.us\0"
-"k.bg\0"
-"railroad.museum\0"
-"!british-library.uk\0"
-"cincinnati.museum\0"
-"sorreisa.no\0"
-"asso.dz\0!nel.uk\0"
-"rm.it\0"
-"nv.us\0"
-"nx.cn\0gos.pk\0"
-"vic.edu.au\0"
-"biella.it\0tjome.no\0"
-"r\xc3\xb8yken.no\0"
-"beiarn.no\0"
-"qc.ca\0"
-"georgia.museum\0square.museum\0"
-"labor.museum\0omasvuotna.no\0cc.la.us\0"
-"br.com\0reggioemilia.it\0"
-"kristiansund.no\0"
-"sorum.no\0"
-"orsta.no\0"
-"furniture.museum\0surrey.museum\0eng.pro\0"
-"asn.lv\0balat.no\0"
-"lavangen.no\0sld.pa\0"
-"fla.no\0k12.ms.us\0k12.nc.us\0"
-"bardu.no\0"
+"ac.ir\0"
+"\xe5\x80\x8b\xe4\xba\xba.hk\0lucca.it\0odessa.ua\0"
+"massa-carrara.it\0"
+"happou.akita.jp\0colonialwilliamsburg.museum\0k12.nv.us\0"
+"w.bg\0lib.in.us\0"
+"*.il\0"
+"scotland.museum\0"
+"ac.jp\0"
+"shimoda.shizuoka.jp\0is-by.us\0"
+"kui.hiroshima.jp\0"
+"us.na\0"
+"reggio-emilia.it\0asahi.ibaraki.jp\0saintlouis.museum\0"
+"kashima.saga.jp\0arboretum.museum\0"
+"bandai.fukushima.jp\0"
+"chikuhoku.nagano.jp\0hayakawa.yamanashi.jp\0"
+"*.jm\0namikata.ehime.jp\0haibara.shizuoka.jp\0bytom.pl\0"
+"furano.hokkaido.jp\0zushi.kanagawa.jp\0"
+"\xe7\xbb\x84\xe7\xb9\x94.hk\0*.sendai.jp\0"
+"ulan-ude.ru\0"
+"ac.kr\0beardu.no\0"
+"lib.gu.us\0"
+"*.ke\0"
+"*.kh\0"
+"vinnica.ua\0"
+"takahata.yamagata.jp\0"
+"honjyo.akita.jp\0scienceandindustry.museum\0"
+"tokorozawa.saitama.jp\0"
+"meraker.no\0"
+"katsuragi.nara.jp\0h\xc3\xa1mm\xc3\xa1rfeasta.no\0bialystok.pl\0"
+"ac.ma\0"
+"lo.it\0akagi.shimane.jp\0"
+"tawaramoto.nara.jp\0obanazawa.yamagata.jp\0ac.me\0"
+"genoa.it\0"
+"iz.hr\0*.kw\0"
+"og.ao\0yakutia.ru\0"
+"taku.saga.jp\0"
+"heguri.nara.jp\0"
+"mansions.museum\0folldal.no\0omasvuotna.no\0"
+"cherkassy.ua\0"
+"trainer.aero\0"
+"ac.mu\0"
+"cc.wi.us\0"
+"ac.mw\0ac.ng\0"
+"cartoonart.museum\0"
+"*.mm\0"
+"paris.museum\0"
+"can.museum\0"
+"juedisches.museum\0from-vt.com\0"
+"*.mt\0"
+"narita.chiba.jp\0fukushima.hokkaido.jp\0"
+"awaji.hyogo.jp\0"
+"lodi.it\0is-uberleet.com\0"
+"*.ni\0"
+"*.mz\0"
+"engerdal.no\0"
+"square.museum\0"
+"saroma.hokkaido.jp\0neues.museum\0"
+"reggiocalabria.it\0"
+"*.np\0ac.pa\0"
+"mb.ca\0seika.kyoto.jp\0"
+"higashiagatsuma.gunma.jp\0iizuna.nagano.jp\0nesoddtangen.no\0"
+"nakatane.kagoshima.jp\0"
+"nt.no\0"
+"tendo.yamagata.jp\0brandywinevalley.museum\0"
+"*.nz\0"
+"kunitachi.tokyo.jp\0"
+"b\xc3\xa6rum.no\0"
+"*.om\0tuva.ru\0"
+"balat.no\0"
+"sue.fukuoka.jp\0"
+"iwata.shizuoka.jp\0tysvar.no\0ac.pr\0"
+"skodje.no\0"
+"ama.shimane.jp\0illustration.museum\0idrett.no\0"
+"better-than.tv\0"
+"ashiya.fukuoka.jp\0leksvik.no\0"
+"*.pg\0wloclawek.pl\0t.se\0"
+"mie.jp\0"
+"kawamata.fukushima.jp\0"
"donostia.museum\0"
-"club.tw\0"
-"elburg.museum\0"
-"gs.hl.no\0lodingen.no\0"
-"samara.ru\0"
-"vc.it\0*.nagasaki.jp\0"
-"fosnes.no\0"
-"fuel.aero\0"
+"is-a-chef.org\0"
+"guernsey.museum\0"
+"saku.nagano.jp\0"
+"minamisanriku.miyagi.jp\0"
+"penza.ru\0"
+"ta.it\0"
+"kawanabe.kagoshima.jp\0"
+"ac.rs\0"
+"okayama.okayama.jp\0kamiizumi.saitama.jp\0annefrank.museum\0"
+"association.aero\0gushikami.okinawa.jp\0ac.ru\0ac.se\0"
+"zentsuji.kagawa.jp\0"
+"ac.rw\0"
+"nagahama.shiga.jp\0narusawa.yamanashi.jp\0"
+"telekommunikation.museum\0"
+"crew.aero\0"
+"services.aero\0"
+"gx.cn\0konan.shiga.jp\0"
+"misaki.osaka.jp\0"
+"fukui.fukui.jp\0toya.hokkaido.jp\0toyonaka.osaka.jp\0"
+"sugito.saitama.jp\0"
+"cc.ne.us\0"
+"hornindal.no\0"
+"noda.iwate.jp\0"
+"wakkanai.hokkaido.jp\0nt.ro\0"
+"ac.th\0"
+"ringsaker.no\0"
+"ac.sz\0ac.tj\0"
+"arq.br\0nnov.ru\0"
+"itami.hyogo.jp\0kashiwazaki.niigata.jp\0"
+"z.bg\0"
+"eti.br\0showa.gunma.jp\0unnan.shimane.jp\0sos.pl\0"
+"rishiri.hokkaido.jp\0"
+"aso.kumamoto.jp\0"
+"store.ro\0"
+"otofuke.hokkaido.jp\0"
+"*.sv\0ac.ug\0"
+"ae.org\0"
+"iida.nagano.jp\0kitanakagusuku.okinawa.jp\0ac.tz\0teaches-yoga.com\0"
+"shimokitayama.nara.jp\0arakawa.saitama.jp\0"
+"og.it\0joboji.iwate.jp\0kainan.tokushima.jp\0"
+"ski.no\0"
+"lib.ee\0"
+"itakura.gunma.jp\0sor-fron.no\0*.tr\0"
+"vf.no\0"
+"astronomy.museum\0"
+"takatsuki.osaka.jp\0"
+"store.st\0"
+"rokunohe.aomori.jp\0"
+"kiyokawa.kanagawa.jp\0od.ua\0"
+"kvalsund.no\0"
+"ashoro.hokkaido.jp\0utazu.kagawa.jp\0ibestad.no\0*.uk\0"
+"urbinopesaro.it\0lyngdal.no\0ac.vn\0"
+"koshu.yamanashi.jp\0michigan.museum\0r\xc3\xb8mskog.no\0"
+"kitagata.saga.jp\0omsk.ru\0"
+"mashiko.tochigi.jp\0"
+"kofu.yamanashi.jp\0"
+"mb.it\0"
+"medizinhistorisches.museum\0"
+"inuyama.aichi.jp\0dnsalias.org\0is-a-chef.com\0"
+"otaki.nagano.jp\0austrheim.no\0"
+"ar.com\0"
+"0.bg\0anthropology.museum\0hvaler.no\0shop.pl\0"
+"lib.va.us\0"
+"fukusaki.hyogo.jp\0baths.museum\0culturalcenter.museum\0"
+"show.aero\0iraq.museum\0r\xc3\xa1hkker\xc3\xa1vju.no\0"
+"kamakura.kanagawa.jp\0toyono.osaka.jp\0"
+"vega.no\0"
+"sumoto.hyogo.jp\0film.museum\0"
+"kadogawa.miyazaki.jp\0garden.museum\0"
+"schokoladen.museum\0!nls.uk\0"
+"konskowola.pl\0"
+"legnica.pl\0"
+"caltanissetta.it\0wajima.ishikawa.jp\0"
+"mragowo.pl\0"
+"hattfjelldal.no\0"
+"kuwana.mie.jp\0"
+"tsuga.tochigi.jp\0"
+"itayanagi.aomori.jp\0v\xc3\xa5gan.no\0"
+"museumvereniging.museum\0zp.ua\0"
+"kawanehon.shizuoka.jp\0"
+"american.museum\0"
+"dolls.museum\0"
+"\xe0\xa6\xad\xe0\xa6\xbe\xe0\xa6\xb0\xe0\xa6\xa4\0"
+"hiroshima.jp\0betainabox.com\0"
+"kawaba.gunma.jp\0"
+"*.ye\0"
+"law.pro\0"
+"kin.okinawa.jp\0skj\xc3\xa5k.no\0"
+"is-a-conservative.com\0"
+"americana.museum\0k12.vi.us\0"
+"yamada.toyama.jp\0"
+"miasa.nagano.jp\0"
+"conf.au\0"
+"aure.no\0*.za\0"
+"oizumi.gunma.jp\0lodingen.no\0"
+"from-or.com\0"
"qc.com\0"
-"skjervoy.no\0"
-"bill.museum\0kv\xc3\xa6""fjord.no\0"
-"skydiving.aero\0*.tokushima.jp\0"
-"!congresodelalengua3.ar\0laquila.it\0k12.ct.us\0"
-"gorge.museum\0linz.museum\0sherbrooke.museum\0"
-"tranoy.no\0ing.pa\0"
-"ptz.ru\0"
-"kr.it\0prato.it\0stat.no\0"
+"fc.it\0farmequipment.museum\0w.se\0"
+"vi.it\0"
+"archaeological.museum\0moss.no\0"
+"khakassia.ru\0*.zm\0isteingeek.de\0"
+"izumi.kagoshima.jp\0imageandsound.museum\0"
+"suisse.museum\0gu.us\0"
+"tajiri.osaka.jp\0"
+"*.zw\0"
+"kiyosato.hokkaido.jp\0"
+"takaharu.miyazaki.jp\0"
+"takanabe.miyazaki.jp\0"
+"paroch.k12.ma.us\0"
+"hatsukaichi.hiroshima.jp\0"
+"cn.it\0"
+"ranzan.saitama.jp\0"
+"murmansk.ru\0"
+"hamburg.museum\0"
+"es.kr\0heroy.nordland.no\0"
+"barletta-trani-andria.it\0lib.me.us\0"
+"hob\xc3\xb8l.no\0"
+"ck.ua\0"
+"gov\0"
+"city.hu\0fhs.no\0"
+"hk.cn\0"
+"ascolipiceno.it\0motorcycle.museum\0skanland.no\0"
+"qld.edu.au\0"
+"cc.nh.us\0"
+"gub.uy\0"
+"trani-andria-barletta.it\0birkenes.no\0is-a-cpa.com\0"
+"trapani.it\0"
+"art.br\0kibichuo.okayama.jp\0tananger.no\0"
+"otama.fukushima.jp\0kiho.mie.jp\0"
+"nose.osaka.jp\0nakagawa.tokushima.jp\0"
+"is-slick.com\0"
+"assn.lk\0\xe5\x95\x86\xe6\xa5\xad.tw\0"
+"from-ga.com\0"
+"\xe6\x96\xb0\xe5\x8a\xa0\xe5\x9d\xa1\0"
+"cc.ks.us\0"
+"kamagaya.chiba.jp\0grp.lk\0"
+"hioki.kagoshima.jp\0"
+"nagato.yamaguchi.jp\0"
+"control.aero\0gliding.aero\0tsumagoi.gunma.jp\0nishitosa.kochi.jp\0"
+"kitadaito.okinawa.jp\0"
+"art.do\0zoological.museum\0"
+"toyako.hokkaido.jp\0plo.ps\0"
+"cq.cn\0kadoma.osaka.jp\0basel.museum\0"
+"osakikamijima.hiroshima.jp\0"
+"elverum.no\0cc.in.us\0"
+"shingu.hyogo.jp\0"
+"art.dz\0"
+"avoues.fr\0lu.it\0me.it\0nerima.tokyo.jp\0"
+"military.museum\0"
+"satosho.okayama.jp\0"
+"st.no\0"
+"3.bg\0yamagata.ibaraki.jp\0humanities.museum\0"
+"championship.aero\0"
+"does-it.net\0"
+"higashi.fukushima.jp\0"
+"taxi.br\0"
+"kharkiv.ua\0"
+"ushuaia.museum\0"
+"kumano.mie.jp\0"
+"unsa.ba\0shimamoto.osaka.jp\0wodzislaw.pl\0"
+"yokosuka.kanagawa.jp\0is-leet.com\0"
+"jevnaker.no\0"
+"minamiashigara.kanagawa.jp\0"
+"ryugasaki.ibaraki.jp\0"
+"tsuno.kochi.jp\0flora.no\0kuzbass.ru\0"
+"nesna.no\0"
+"yachiyo.chiba.jp\0civilwar.museum\0"
+"matsumae.hokkaido.jp\0"
+"kumatori.osaka.jp\0namsskogan.no\0"
+"knowsitall.info\0"
+"linz.museum\0"
+"sakuragawa.ibaraki.jp\0"
+"toride.ibaraki.jp\0traeumtgerade.de\0"
+"store.bb\0jolster.no\0"
+"pilots.museum\0"
+"asia\0"
+"kustanai.ru\0"
+"art.ht\0"
+"pubol.museum\0"
+"england.museum\0"
+"shimizu.shizuoka.jp\0kartuzy.pl\0"
+"volgograd.ru\0"
+"tateyama.toyama.jp\0"
+"augustow.pl\0"
+"askoy.no\0z.se\0"
+"obama.nagasaki.jp\0k12.ca.us\0"
+"higashine.yamagata.jp\0wales.museum\0"
+"kiwa.mie.jp\0izena.okinawa.jp\0"
+"js.cn\0kanna.gunma.jp\0from-tn.com\0"
+"brescia.it\0"
+"aip.ee\0otoineppu.hokkaido.jp\0"
+"sakyo.kyoto.jp\0kami.miyagi.jp\0"
+"serveftp.org\0"
+"miyama.fukuoka.jp\0hakui.ishikawa.jp\0"
+"adv.br\0"
+"exeter.museum\0"
+"nichinan.tottori.jp\0vi.us\0"
+"enna.it\0"
+"flor\xc3\xb8.no\0"
+"cn.ua\0"
+"from-co.net\0"
+"hn.cn\0"
+"andria-barletta-trani.it\0"
+"himeshima.oita.jp\0"
+"boleslawiec.pl\0"
+"nishiarita.saga.jp\0"
+"al.it\0sydney.museum\0"
+"washingtondc.museum\0"
+"iglesiascarbonia.it\0kanuma.tochigi.jp\0"
+"educator.aero\0"
+"from-ny.net\0"
+"watchandclock.museum\0"
+"frog.museum\0"
+"takamori.kumamoto.jp\0"
+"is-a-blogger.com\0"
+"habmer.no\0"
+"consulting.aero\0"
+"ogawa.saitama.jp\0"
+"fi.cr\0"
+"hanggliding.aero\0"
+"minamiise.mie.jp\0\xc3\xa5lg\xc3\xa5rd.no\0"
+"ueda.nagano.jp\0lebtimnetz.de\0"
+"karelia.ru\0"
+"zlg.br\0koge.tottori.jp\0"
+"kvitsoy.no\0"
+"vagsoy.no\0"
+"time.no\0"
+"toyotomi.hokkaido.jp\0"
+"tj.cn\0nes.akershus.no\0"
+"med.br\0fujioka.gunma.jp\0"
+"imakane.hokkaido.jp\0"
+"yamakita.kanagawa.jp\0"
+"okinoshima.shimane.jp\0"
+"gs.jan-mayen.no\0"
+"kasugai.aichi.jp\0"
+"texas.museum\0"
+"tsugaru.aomori.jp\0miyawaka.fukuoka.jp\0otsuki.yamanashi.jp\0"
+"6.bg\0suedtirol.it\0"
+"koya.wakayama.jp\0"
+"shikokuchuo.ehime.jp\0"
"\xd0\xb8\xd0\xba\xd0\xbe\xd0\xbc.museum\0"
-"cosenza.it\0"
-"stj\xc3\xb8rdalshalsen.no\0"
-"finland.museum\0leka.no\0cc.pr.us\0"
-"historichouses.museum\0s\xc3\xa1l\xc3\xa1t.no\0"
-"venice.it\0"
-"biz.ki\0"
-"g\xc3\xa1ls\xc3\xa1.no\0"
-"\xe7\xbb\x84\xe7\xbb\x87.hk\0"
-"*.yamanashi.jp\0"
-"rad\xc3\xb8y.no\0"
-"6.bg\0"
-"fareast.ru\0"
-"paragliding.aero\0ba.it\0aq.it\0"
-"sk\xc3\xa5nland.no\0"
-"its.me\0"
-"us.na\0"
-"hl.no\0cc.ga.us\0"
-"ac\0granvin.no\0"
-"ad\0qld.edu.au\0!city.sapporo.jp\0"
-"ae\0"
-"af\0"
-"ag\0crotone.it\0"
-"dallas.museum\0"
-"ai\0brussels.museum\0"
-"dali.museum\0"
-"la.us\0"
-"al\0salzburg.museum\0"
-"am\0"
-"an\0cl.it\0"
-"ao\0"
-"aq\0ba\0"
-"bb\0"
-"as\0lajolla.museum\0"
-"at\0"
-"be\0"
-"bf\0inderoy.no\0snz.ru\0"
-"aw\0bg\0"
-"ax\0bh\0cim.br\0ltd.gi\0biz.mv\0"
-"bi\0xz.cn\0\xe7\xb5\x84\xe7\xb9\x94.hk\0biz.mw\0"
-"az\0bj\0"
-"bm\0tranibarlettaandria.it\0naamesjevuemie.no\0"
-"chattanooga.museum\0"
-"bo\0"
-"l.bg\0"
-"ca\0"
-"br\0stateofdelaware.museum\0"
-"bs\0cc\0"
-"cd\0biz.nr\0"
-"cf\0berlev\xc3\xa5g.no\0"
-"bw\0cg\0snaase.no\0"
-"ch\0harvestcelebration.museum\0ck.ua\0"
-"by\0ci\0"
-"bz\0bahccavuotna.no\0"
-"cl\0yuzhno-sakhalinsk.ru\0"
-"cm\0halsa.no\0lyngdal.no\0"
-"cn\0"
-"co\0rn.it\0childrens.museum\0frankfurt.museum\0"
-"cr\0"
-"pskov.ru\0"
-"cu\0de\0"
-"cv\0fr.it\0lib.ky.us\0"
-"aseral.no\0kvam.no\0"
-"cx\0hellas.museum\0"
-"hof.no\0"
-"cz\0dj\0k12.la.us\0"
-"dk\0moscow.museum\0"
-"sosnowiec.pl\0"
-"dm\0biz.pk\0"
-"schokoladen.museum\0biz.pl\0"
-"far.br\0arna.no\0tynset.no\0"
-"even\xc3\xa1\xc5\xa1\xc5\xa1i.no\0"
-"ec\0"
-"biz.pr\0"
-"ee\0celtic.museum\0"
-"scientist.aero\0modern.museum\0"
-"pr.us\0"
-"dz\0"
-"mj\xc3\xb8ndalen.no\0s\xc3\xb8r-odal.no\0"
-"!nic.tr\0"
-"conference.aero\0vestnes.no\0k12.mn.us\0"
-"!pref.hiroshima.jp\0"
-"es\0trapani.it\0"
-"fermo.it\0vard\xc3\xb8.no\0"
-"eu\0gs.hm.no\0r\xc3\xb8""d\xc3\xb8y.no\0stordal.no\0"
-"gc.ca\0!nhs.uk\0"
-"jgora.pl\0"
-"fi\0stjordal.no\0"
-"fm\0!mediaphone.om\0"
-"kirov.ru\0pvt.k12.ma.us\0"
-"fo\0"
-"ga\0hyllestad.no\0"
-"gov.ac\0fr\0andriabarlettatrani.it\0ga.us\0"
-"gov.ae\0gd\0estate.museum\0"
-"gov.af\0ge\0tolga.no\0"
-"gf\0asso.re\0cc.oh.us\0"
-"gg\0florida.museum\0"
-"presse.ci\0gh\0"
-"gi\0k12.dc.us\0"
-"ltd.lk\0orland.no\0"
-"gov.al\0"
-"gl\0tokke.no\0"
-"hanggliding.aero\0gm\0"
-"hareid.no\0"
-"gov.ba\0tj.cn\0gp\0"
-"gov.bb\0gq\0"
-"gov.as\0gr\0agrigento.it\0lc.it\0"
-"gs\0kalmykia.ru\0aero.tt\0"
-"gov.bf\0"
-"county.museum\0"
-"gov.bh\0hn.cn\0gw\0"
-"gov.az\0gy\0assn.lk\0guernsey.museum\0"
-"hk\0"
-"gov.bm\0h\xc3\xa6gebostad.no\0biz.tj\0"
-"hm\0computer.museum\0"
-"gov.bo\0hn\0kl\xc3\xa6""bu.no\0"
-"pulawy.pl\0"
-"gov.br\0"
-"trd.br\0gov.bs\0hr\0reggio-calabria.it\0historyofscience.museum\0lipetsk.ru\0"
-"gov.cd\0*.nagoya.jp\0"
-"ht\0id\0spjelkavik.no\0"
-"hu\0ie\0aero.mv\0"
-"marketplace.aero\0mn.it\0biz.tt\0"
-"gov.by\0saintlouis.museum\0mer\xc3\xa5ker.no\0"
-"gov.bz\0"
-"7.bg\0gov.cl\0virtual.museum\0"
-"gov.cm\0vennesla.no\0kr.ua\0"
-"gov.cn\0im\0ar.it\0galsa.no\0rovno.ua\0"
-"gov.co\0in\0"
-"io\0limanowa.pl\0"
-"iq\0k12.ga.us\0"
-"ir\0"
-"riik.ee\0is\0\xc3\xa1laheadju.no\0"
-"gov.cu\0it\0hawaii.museum\0seaport.museum\0"
-"je\0pubol.museum\0hm.no\0"
-"gov.cx\0"
-"*.chiba.jp\0"
-"*.kawasaki.jp\0"
-"k.se\0"
-"gov.dm\0"
-"aland.fi\0vik.no\0"
-"yk.ca\0jo\0kobierzyce.pl\0"
-"jp\0biz.vn\0"
-"presse.fr\0lib.il.us\0\xe9\xa6\x99\xe6\xb8\xaf\0"
-"gov.ec\0"
-"transport.museum\0bronnoy.no\0"
-"slg.br\0gov.ee\0asso.nc\0bievat.no\0"
-"nyny.museum\0"
-"kg\0"
-"mo-i-rana.no\0"
-"gov.dz\0ki\0"
+"kameyama.mie.jp\0missile.museum\0"
+"fhv.se\0hu.com\0"
+"art.pl\0"
+"tamano.okayama.jp\0"
+"taketa.oita.jp\0"
+"\xc3\xb8yer.no\0oystre-slidre.no\0rad\xc3\xb8y.no\0"
+"me.tz\0"
+"takahagi.ibaraki.jp\0steam.museum\0"
+"technology.museum\0"
+"med.ec\0asakuchi.okayama.jp\0"
+"med.ee\0stavanger.no\0merseine.nu\0"
+"al.no\0porsangu.no\0"
+"stavern.no\0me.us\0"
+"lib.ct.us\0"
+"emp.br\0tr\xc3\xa6na.no\0"
+"kayabe.hokkaido.jp\0"
+"sekigahara.gifu.jp\0"
+"udine.it\0shacknet.nu\0"
+"presse.km\0posts-and-telecommunications.museum\0"
+"is-a-chef.net\0"
+"gokase.miyazaki.jp\0"
+"choshi.chiba.jp\0podhale.pl\0"
+"archaeology.museum\0"
+"localhistory.museum\0"
+"krasnoyarsk.ru\0"
+"minamidaito.okinawa.jp\0yorkshire.museum\0"
+"lavangen.no\0"
+"oyamazaki.kyoto.jp\0"
+"nagasaki.nagasaki.jp\0"
+"\xc3\xa1laheadju.no\0"
+"kameoka.kyoto.jp\0"
+"bielawa.pl\0\xd8\xa7\xd9\x84\xd8\xac\xd8\xb2\xd8\xa7\xd8\xa6\xd8\xb1\0"
+"\xd7\x99\xd7\xa8\xd7\x95\xd7\xa9\xd7\x9c\xd7\x99\xd7\x9d.museum\0art.sn\0from-pr.com\0"
+"takata.fukuoka.jp\0dielddanuorri.no\0"
+"fujisato.akita.jp\0association.museum\0"
+"gouv.fr\0fi.it\0presse.ml\0"
+"nakagawa.hokkaido.jp\0"
+"tanabe.wakayama.jp\0"
"monmouth.museum\0"
-"suldal.no\0"
-"bc.ca\0km\0zt.ua\0"
-"pt.it\0kn\0"
-"fineart.museum\0"
-"la\0"
-"kr\0gulen.no\0"
-"m.bg\0mo.cn\0lc\0alaheadju.no\0g\xc3\xa1\xc5\x8bgaviika.no\0"
-"nowaruda.pl\0cc.ut.us\0"
-"br\xc3\xb8nn\xc3\xb8y.no\0"
-"ky\0li\0overhalla.no\0"
-"kz\0khv.ru\0"
-"lk\0"
-"artdeco.museum\0"
-"ma\0fortworth.museum\0kostroma.ru\0"
-"ro.it\0kirkenes.no\0vestby.no\0"
-"urbino-pesaro.it\0ls\0mc\0alstahaug.no\0"
-"blog.br\0gov.ge\0lt\0md\0"
-"lu\0me\0botanicgarden.museum\0"
-"gov.gg\0lv\0oh.us\0"
-"gov.gh\0mg\0valley.museum\0"
-"gov.gi\0mh\0"
-"ly\0sandiego.museum\0"
-"mk\0"
-"ml\0"
-"gov.gn\0rollag.no\0naklo.pl\0"
-"mn\0"
-"mo\0"
-"mp\0leirvik.no\0"
-"gov.gr\0mq\0na\0cc.ks.us\0"
-"mr\0"
-"ms\0nc\0"
-"valer.hedmark.no\0"
-"mu\0ne\0"
-"mv\0nf\0"
-"mw\0"
-"mx\0nord-odal.no\0jur.pro\0"
-"my\0"
-"gov.hk\0name.hr\0"
-"nl\0"
-"astronomy.museum\0lib.nm.us\0"
-"catania.it\0"
-"no\0"
-"skjerv\xc3\xb8y.no\0"
-"k12.ne.us\0"
-"monza-e-della-brianza.it\0!pref.fukushima.jp\0nr\0"
-"gov.ie\0"
-"stuttgart.museum\0nu\0cc.mn.us\0"
-"karasjohka.no\0"
-"engine.aero\0bearalvahki.no\0"
-"oyer.no\0"
-"ve.it\0"
-"gov.im\0froland.no\0cc.ar.us\0"
-"gov.in\0magadan.ru\0"
-"pescara.it\0"
-"gov.iq\0usdecorativearts.museum\0"
-"gov.ir\0pa\0"
-"gov.is\0"
-"gov.it\0lavagis.no\0"
-"gov.je\0"
-"naustdal.no\0pe\0k12.or.us\0"
-"gd.cn\0carraramassa.it\0pf\0"
-"ph\0"
-"cc.ny.us\0"
-"rissa.no\0"
-"info\0pk\0pomorze.pl\0"
-"pl\0"
-"gov.jo\0asso.km\0pn\0"
-"*.okayama.jp\0cieszyn.pl\0"
-"freight.aero\0"
-"pr\0"
-"narvik.no\0ps\0"
-"!pref.aichi.jp\0elverum.no\0pt\0"
-"edunet.tn\0"
-"gov.kg\0"
-"flatanger.no\0marker.no\0pw\0"
-"gov.ki\0nuremberg.museum\0"
-"aip.ee\0"
-"gov.km\0"
-"gov.kn\0"
-"gov.kp\0"
-"rieti.it\0gov.la\0bajddar.no\0"
-"gov.lb\0aviation.museum\0"
-"gov.lc\0"
-"asso.mc\0"
-"re\0"
-"ut.us\0"
-"sa.gov.au\0gov.ky\0"
-"mo.it\0gov.kz\0"
-"gov.lk\0"
-"iraq.museum\0"
-"badajoz.museum\0"
-"8.bg\0inder\xc3\xb8y.no\0"
-"monticello.museum\0ro\0ks.ua\0"
-"gov.ma\0svizzera.museum\0"
-"gov.lr\0sa\0"
-"matera.it\0sb\0"
-"gov.lt\0rs\0sc\0"
-"gov.me\0sd\0"
-"gov.lv\0ru\0se\0"
-"gov.mg\0"
-"rw\0sg\0"
-"gov.ly\0assisi.museum\0kids.museum\0sh\0"
-"si\0"
-"gov.mk\0"
-"gov.ml\0sk\0"
-"sl\0"
-"gov.mn\0airguard.museum\0sm\0"
-"gov.mo\0l.se\0sn\0"
-"so\0"
-"gov.mr\0ks.us\0"
-"name.az\0sr\0"
-"naturhistorisches.museum\0tc\0"
-"trainer.aero\0cn.it\0urbinopesaro.it\0gov.mu\0nativeamerican.museum\0st\0td\0"
-"gov.mv\0su\0"
-"trentino.it\0gov.mw\0gov.ng\0tf\0"
-"tg\0"
-"co.ae\0venezia.it\0gov.my\0th\0"
-"!pref.ehime.jp\0sy\0"
-"co.ag\0lewismiller.museum\0ostrowiec.pl\0sz\0tj\0"
-"tk\0"
-"motorcycle.museum\0tl\0"
-"birdart.museum\0trogstad.no\0tm\0"
-"tn\0"
-"humanities.museum\0to\0"
-"pu.it\0gov.nr\0ua\0lib.ut.us\0"
-"co.ao\0"
-"co.ba\0trondheim.no\0tt\0"
-"in-addr.arpa\0tempioolbia.it\0!city.yokohama.jp\0mn.us\0"
-"n.bg\0schoenbrunn.museum\0tv\0"
-"co.at\0aremark.no\0tw\0ug\0"
-"jus.br\0"
-"co.bi\0bialowieza.pl\0ar.us\0"
-"audnedaln.no\0kustanai.ru\0"
-"va\0"
-"us\0vc\0"
-"newport.museum\0"
-"kopervik.no\0gov.ph\0vg\0"
-"ny.us\0vi\0"
-"co.bw\0finn\xc3\xb8y.no\0gov.pk\0uz\0"
-"honefoss.no\0gov.pl\0lanbib.se\0"
-"co.ci\0"
-"gov.pn\0intl.tn\0"
-"act.gov.au\0vn\0"
-"television.museum\0gov.pr\0"
-"sykkylven.no\0v\xc3\xa5ler.hedmark.no\0gov.ps\0"
-"gov.pt\0"
-"co.cr\0vu\0"
-"legnica.pl\0"
-"sa.au\0"
-"bjarkoy.no\0"
-"openair.museum\0birkenes.no\0lib.nj.us\0"
-"fylkesbibl.no\0holt\xc3\xa5len.no\0"
-"iz.hr\0"
-"ws\0"
-"oceanographique.museum\0"
-"b\xc3\xa1id\xc3\xa1r.no\0cc.mo.us\0"
-"\xc3\xb8ygarden.no\0"
-"contemporary.museum\0"
-"gb.com\0cc.as.us\0"
-"belluno.it\0gov.sa\0"
-"gov.sb\0"
-"gov.rs\0gov.sc\0"
-"gov.sd\0"
-"!pref.nagasaki.jp\0gov.ru\0"
-"asia\0"
-"sa.cr\0gov.rw\0gov.sg\0"
-"kuzbass.ru\0"
-"gs.vf.no\0"
-"gov.sl\0"
-"norfolk.museum\0"
-"k12.de.us\0"
-"mil\0"
-"rendalen.no\0"
-"gov.st\0"
-"agro.pl\0"
-"orkdal.no\0"
-"le.it\0gov.sy\0"
-"gov.tj\0"
-"co.gg\0nore-og-uvdal.no\0v\xc3\xa5ler.\xc3\xb8stfold.no\0"
-"gov.tl\0"
-"gov.tn\0"
-"gov.to\0"
-"kids.us\0"
-"equipment.aero\0gov.ua\0"
-"!city.niigata.jp\0gov.tt\0"
-"sel.no\0"
-"l\xc3\xa4ns.museum\0"
-"gov.tw\0"
-"rennebu.no\0"
-"egersund.no\0"
-"medecin.km\0"
-"co.gy\0"
-"!mecon.ar\0"
-"berlin.museum\0"
-"carrara-massa.it\0"
-"9.bg\0"
-"pri.ee\0gov.vc\0"
-"at.it\0"
-"muosat.no\0"
-"co.id\0"
-"co.hu\0"
-"etne.no\0"
-"\xc3\xa1lt\xc3\xa1.no\0"
-"gov.vn\0"
-"modelling.aero\0"
-"co.im\0"
-"co.in\0\xc3\xa5krehamn.no\0m.se\0"
-"gouv.fr\0*.kitakyushu.jp\0"
-"narviika.no\0"
-"rennes\xc3\xb8y.no\0"
-"co.ir\0afjord.no\0"
-"lea\xc5\x8bgaviika.no\0buryatia.ru\0"
-"co.it\0coastaldefence.museum\0"
-"co.je\0vf.no\0"
-"osteroy.no\0"
-"uslivinghistory.museum\0"
-"aerobatic.aero\0"
-"mesaverde.museum\0mining.museum\0"
-"a\xc3\xa9roport.ci\0gov.ws\0"
-"co.jp\0copenhagen.museum\0"
-"pv.it\0"
-"r\xc3\xb8mskog.no\0"
-"vossevangen.no\0porsanger.no\0"
-"salat.no\0mo.us\0"
-"o.bg\0imperia.it\0carrier.museum\0"
-"carbonia-iglesias.it\0"
-"as.us\0"
-"alvdal.no\0"
-"state.museum\0mandal.no\0cn.ua\0"
-"cuneo.it\0"
+"dyr\xc3\xb8y.no\0"
+"takikawa.hokkaido.jp\0urakawa.hokkaido.jp\0"
+"shibecha.hokkaido.jp\0"
+"sand\xc3\xb8y.no\0"
+"collection.museum\0"
+"kusatsu.gunma.jp\0"
+"pulawy.pl\0"
+"monticello.museum\0"
+"med.ht\0"
+"ct.it\0otago.museum\0alaheadju.no\0"
+"omotego.fukushima.jp\0name\0"
+"balsan.it\0"
+"ogi.saga.jp\0"
+"okawa.fukuoka.jp\0"
+"norfolk.museum\0n\xc3\xa6r\xc3\xb8y.no\0"
"gouv.ht\0"
-"!city.okayama.jp\0co.kr\0"
-"co.lc\0"
-"sa.it\0"
-"donna.no\0"
-"sortland.no\0"
-"tomsk.ru\0"
-"birthplace.museum\0l\xc3\xb8""dingen.no\0"
-"ge.it\0orenburg.ru\0"
-"cn.com\0"
-"co.ma\0"
-"co.ls\0skaun.no\0name.vn\0"
-"navigation.aero\0"
-"cagliari.it\0co.me\0portal.museum\0"
+"kaminokawa.tochigi.jp\0"
+"hammerfest.no\0"
+"hiraya.nagano.jp\0settlement.museum\0"
+"toei.aichi.jp\0santabarbara.museum\0"
+"\xc3\xb8rsta.no\0"
+"ao.it\0sano.tochigi.jp\0jondal.no\0"
+"re.it\0"
+"kamitsue.oita.jp\0"
+"sola.no\0"
+"laspezia.it\0luzern.museum\0salat.no\0stv.ru\0est-a-la-maison.com\0"
+"avocat.fr\0sm\xc3\xb8la.no\0"
+"bando.ibaraki.jp\0kawakami.nara.jp\0"
+"*.kawasaki.jp\0ngo.lk\0"
"gouv.bj\0"
-"udine.it\0"
-"engineer.aero\0"
-"szczecin.pl\0"
-"wales.museum\0"
-"co.na\0bo.telemark.no\0"
-"austin.museum\0"
-"k12.mo.us\0"
-"co.mu\0"
-"gouv.ci\0"
-"co.mw\0"
-"esp.br\0"
-"naturalhistorymuseum.museum\0"
-"mosjoen.no\0"
-"solund.no\0"
-"name.tj\0"
-"sand\xc3\xb8y.no\0"
-"kunstunddesign.museum\0"
-"cartoonart.museum\0collection.museum\0gsm.pl\0"
-"aure.no\0"
-"!pref.yamaguchi.jp\0historical.museum\0"
-"name.tt\0"
-"england.museum\0valle.no\0"
-"cc.ok.us\0"
-"salangen.no\0"
-"gloppen.no\0"
-"cc.co.us\0"
-"contemporaryart.museum\0"
-"tas.edu.au\0"
-"trading.aero\0"
-"mazury.pl\0"
-"!pref.aomori.jp\0co.pl\0"
-"opoczno.pl\0"
-"*.kobe.jp\0co.pn\0"
-"oppegard.no\0"
-"co.pw\0"
-"saltdal.no\0smolensk.ru\0"
-"na.it\0\xc4\x8d\xc3\xa1hcesuolo.no\0"
-"vgs.no\0evenassi.no\0"
-"parachuting.aero\0jl.cn\0maritime.museum\0bd.se\0"
-"badaddja.no\0"
-"bergen.no\0"
-"brussel.museum\0"
-"avoues.fr\0"
-"cesenaforli.it\0"
-"oregontrail.museum\0"
-"ullensaker.no\0"
-"jobs\0"
-"accident-prevention.aero\0"
-"n.se\0"
-"association.museum\0california.museum\0"
-"cultural.museum\0co.rs\0"
-"zoology.museum\0"
-"pruszkow.pl\0"
-"control.aero\0nt.edu.au\0net\0komforb.se\0"
-"lincoln.museum\0aurland.no\0name.pr\0co.rw\0"
-"ostroleka.pl\0"
-"isernia.it\0"
-"tm.fr\0"
-"gs.ol.no\0"
-"nb.ca\0marnardal.no\0"
-"williamsburg.museum\0"
-"!jet.uk\0"
-"suisse.museum\0\xc3\xa5""fjord.no\0flakstad.no\0"
-"karmoy.no\0"
-"yn.cn\0chesapeakebay.museum\0"
-"nsw.au\0"
-"amur.ru\0co.st\0"
-"imb.br\0siellak.no\0\xe7\xb6\xb2\xe8\xb7\xaf.tw\0"
-"name.na\0"
-"co.th\0"
-"p.bg\0"
-"co.sz\0co.tj\0"
-"name.mv\0\xc3\xa5lesund.no\0lib.in.us\0"
-"lucerne.museum\0naumburg.museum\0"
-"society.museum\0name.my\0"
-"tinn.no\0"
-"co.tt\0"
-"unj\xc3\xa1rga.no\0"
-"co.ug\0"
-"lib.wy.us\0"
-"co.tz\0"
-"ass.km\0"
-"ok.us\0"
-"tm.hu\0kongsvinger.no\0"
-"ibestad.no\0"
-"juedisches.museum\0co.us\0"
-"cq.cn\0"
-"rs.ba\0"
-"wa.edu.au\0co.vi\0"
-"co.uz\0"
-"health.museum\0"
-"grue.no\0"
-"automotive.museum\0journalism.museum\0settlement.museum\0"
-"qh.cn\0interactive.museum\0"
-"snillfjord.no\0!national-library-scotland.uk\0"
-"balsfjord.no\0lib.nh.us\0"
-"kolobrzeg.pl\0"
-"gs.tm.no\0"
-"h\xc3\xb8nefoss.no\0"
-"ol.no\0"
-"music.museum\0moareke.no\0"
-"b\xc3\xb8.nordland.no\0"
-"name.mk\0lier.no\0"
-"eidfjord.no\0"
-"sc.cn\0tm.km\0"
-"jelenia-gora.pl\0sanok.pl\0"
-"intelligence.museum\0"
-"srv.br\0elblag.pl\0"
-"judygarland.museum\0"
-"padua.it\0"
-"k12.co.us\0"
-"lindesnes.no\0"
-"name.jo\0izhevsk.ru\0"
-"yorkshire.museum\0mel\xc3\xb8y.no\0"
-"tm.mc\0lib.pr.us\0"
-"hjartdal.no\0"
+"sennan.osaka.jp\0"
+"greta.fr\0"
+"minamiuonuma.niigata.jp\0h\xc3\xa1""bmer.no\0"
+"sanuki.kagawa.jp\0"
+"cosenza.it\0kota.aichi.jp\0takko.aomori.jp\0"
+"gamvik.no\0"
+"kaneyama.fukushima.jp\0cc.ky.us\0"
+"stjohn.museum\0"
+"habikino.osaka.jp\0askim.no\0"
+"gouv.ci\0musashimurayama.tokyo.jp\0"
+"gs.bu.no\0"
+"teshikaga.hokkaido.jp\0al.us\0"
+"re.kr\0"
+"kyotamba.kyoto.jp\0minnesota.museum\0"
+"ise.mie.jp\0"
+"med.ly\0"
+"safety.aero\0kyonan.chiba.jp\0koga.ibaraki.jp\0skedsmokorset.no\0"
+"!www.ck\0sherbrooke.museum\0"
+"\xe7\xb6\xb2\xe7\xb5\xa1.cn\0"
+"b\xc3\xa1jddar.no\0"
+"fuchu.toyama.jp\0conf.lv\0"
+"yonabaru.okinawa.jp\0"
+"9.bg\0ujiie.tochigi.jp\0"
+"numata.hokkaido.jp\0luroy.no\0sortland.no\0"
+"yamamoto.miyagi.jp\0"
+"morimachi.shizuoka.jp\0"
+"iijima.nagano.jp\0ichikawamisato.yamanashi.jp\0upow.gov.pl\0"
+"losangeles.museum\0"
+"club.aero\0"
+"kommunalforbund.se\0"
+"drangedal.no\0"
+"ngo.ph\0"
+"tur.br\0"
+"ngo.pl\0"
+"nishinoomote.kagoshima.jp\0"
+"lib.dc.us\0"
+"chihayaakasaka.osaka.jp\0eastafrica.museum\0"
+"leitungsen.de\0"
+"aurland.no\0"
+"misawa.aomori.jp\0med.pa\0"
+"inabe.mie.jp\0"
+"laquila.it\0"
+"tm.fr\0toon.ehime.jp\0"
+"kusatsu.shiga.jp\0"
+"med.pl\0"
+"hofu.yamaguchi.jp\0"
+"mamurogawa.yamagata.jp\0vinnytsia.ua\0"
+"miyota.nagano.jp\0"
+"parachuting.aero\0"
+"suli.hu\0"
+"yasugi.shimane.jp\0"
+"johana.toyama.jp\0"
+"yaita.tochigi.jp\0!nawras.om\0izhevsk.ru\0"
+"frei.no\0"
+"kumenan.okayama.jp\0kikugawa.shizuoka.jp\0"
+"vr.it\0"
+"ambulance.museum\0"
+"tsunan.niigata.jp\0matsubushi.saitama.jp\0"
+"ichiba.tokushima.jp\0"
+"tm.hu\0"
+"\xe7\xb6\xb2\xe7\xb5\xa1.hk\0"
+"id.au\0perugia.it\0"
+"gotemba.shizuoka.jp\0fla.no\0"
+"kamikoani.akita.jp\0sec.ps\0"
+"med.sa\0"
+"skole.museum\0"
+"airport.aero\0"
+"med.sd\0"
+"sibenik.museum\0"
+"sondre-land.no\0"
+"jpn.com\0"
+"shimamaki.hokkaido.jp\0"
+"owariasahi.aichi.jp\0utashinai.hokkaido.jp\0hotel.tz\0"
+"namie.fukushima.jp\0komi.ru\0"
+"malvik.no\0lib.nj.us\0"
+"k-uralsk.ru\0"
+"xz.cn\0lukow.pl\0"
+"iiyama.nagano.jp\0steiermark.museum\0radom.pl\0blogspot.co.at\0"
+"saltdal.no\0vladivostok.ru\0"
+"int\0kira.aichi.jp\0"
+"flog.br\0shiranuka.hokkaido.jp\0nsk.ru\0"
+"ar.it\0"
+"tono.iwate.jp\0fujiidera.osaka.jp\0"
+"tm.km\0"
+"ct.us\0"
+"kuchinotsu.nagasaki.jp\0"
+"shinto.gunma.jp\0"
+"trysil.no\0"
+"saves-the-whales.com\0"
+"off.ai\0"
+"county.museum\0"
+"tank.museum\0"
+"is-a-hard-worker.com\0"
+"pc.it\0"
+"tm.mc\0kyiv.ua\0"
+"onojo.fukuoka.jp\0"
"tm.mg\0"
-"bari.it\0milano.it\0"
-"lg.jp\0"
-"zgrad.ru\0"
-"sm\xc3\xb8la.no\0"
-"communications.museum\0"
-"arts.co\0seoul.kr\0engerdal.no\0"
+"onga.fukuoka.jp\0"
+"a.bg\0vlog.br\0lib.id.us\0"
+"kalmykia.ru\0"
+"alto-adige.it\0"
+"shibukawa.gunma.jp\0"
+"toba.mie.jp\0"
+"misato.shimane.jp\0"
+"kitahata.saga.jp\0"
+"for-more.biz\0"
+"siellak.no\0"
+"la-spezia.it\0"
+"mn.it\0seljord.no\0"
+"mihama.chiba.jp\0"
+"miyako.fukuoka.jp\0"
+"fujinomiya.shizuoka.jp\0moka.tochigi.jp\0"
+"cultural.museum\0"
+"tm.no\0"
+"kamisato.saitama.jp\0magadan.ru\0"
+"mk.ua\0"
+"\xe0\xae\x87\xe0\xae\xa8\xe0\xaf\x8d\xe0\xae\xa4\xe0\xae\xbf\xe0\xae\xaf\xe0\xae\xbe\0"
+"motobu.okinawa.jp\0"
+"r\xc3\xb8yrvik.no\0is-a-geek.com\0"
+"shizukuishi.iwate.jp\0omura.nagasaki.jp\0"
+"rec.br\0kai.yamanashi.jp\0"
+"monza.it\0"
+"teo.br\0pescara.it\0"
+"yugawa.fukushima.jp\0circus.museum\0kirkenes.no\0"
+"air-surveillance.aero\0br\xc3\xb8nn\xc3\xb8y.no\0roros.no\0rnd.ru\0"
+"pharmacy.museum\0gs.nt.no\0"
+"bmd.br\0takizawa.iwate.jp\0bunkyo.tokyo.jp\0"
+"motegi.tochigi.jp\0youth.museum\0"
+"gob.bo\0tamba.hyogo.jp\0"
+"lib.tx.us\0"
+"kitashiobara.fukushima.jp\0"
+"rec.co\0kautokeino.no\0"
+"baseball.museum\0dinosaur.museum\0tm.pl\0"
+"grane.no\0"
"oster\xc3\xb8y.no\0"
-"\xe6\x95\x8e\xe8\x82\xb2.hk\0foggia.it\0verran.no\0"
-"orskog.no\0voronezh.ru\0kv.ua\0"
-"av.it\0"
-"tm.no\0nissedal.no\0"
-"historisches.museum\0gs.mr.no\0"
-"medecin.fr\0"
-"montreal.museum\0"
-"o.se\0"
-"!metro.tokyo.jp\0sola.no\0"
-"k12.tn.us\0"
-"floro.no\0"
-"milan.it\0*.shiga.jp\0"
-"berkeley.museum\0"
-"maintenance.aero\0"
-"ws.na\0"
-"lindas.no\0cc.ia.us\0"
-"brescia.it\0embroidery.museum\0"
-"arezzo.it\0tm.pl\0"
-"r\xc3\xa6lingen.no\0"
-"burghof.museum\0"
-"rec.br\0"
-"q.bg\0"
-"!nawras.om\0"
-"hammarfeasta.no\0"
-"moss.no\0"
-"on.ca\0"
-"gouv.rw\0"
-"luxembourg.museum\0"
-"rec.co\0british.museum\0"
-"reggio-emilia.it\0"
-"gouv.sn\0lib.wv.us\0"
-"avocat.fr\0"
-"simbirsk.ru\0"
-"jar.ru\0"
-"monza-brianza.it\0"
-"tm.ro\0"
-"imageandsound.museum\0"
-"jpn.com\0mr.no\0"
-"siracusa.it\0"
-"norilsk.ru\0tm.se\0"
-"tn.it\0"
-"jeju.kr\0"
-"!pref.fukuoka.jp\0"
-"*.hyogo.jp\0portlligat.museum\0"
-"!pref.osaka.jp\0"
-"siena.it\0sc.kr\0omaha.museum\0saskatchewan.museum\0"
-"phoenix.museum\0vanylven.no\0"
-"botanicalgarden.museum\0"
-"turek.pl\0"
-"vagsoy.no\0"
-"riodejaneiro.museum\0"
-"vi.it\0"
-"uy.com\0"
-"kristiansand.no\0"
-"sd.cn\0trento.it\0"
-"muncie.museum\0"
-"berg.no\0meldal.no\0"
-"nes.buskerud.no\0"
-"saratov.ru\0"
-"gs.oslo.no\0"
-"harstad.no\0vaga.no\0"
-"research.museum\0"
-"brunel.museum\0ia.us\0"
-"test.tj\0"
-"columbia.museum\0"
-"ms.it\0stockholm.museum\0"
-"reklam.hu\0"
-"pomorskie.pl\0lg.ua\0"
-"bg.it\0historicalsociety.museum\0rns.tn\0"
-"mallorca.museum\0surgut.ru\0cc.sc.us\0"
-"ushistory.museum\0"
-"palana.ru\0"
-"snoasa.no\0"
-"naturalsciences.museum\0"
-"yaroslavl.ru\0"
-"unjarga.no\0"
-"p.se\0"
-"ingatlan.hu\0"
-"irc.pl\0"
-"savona.it\0"
-"cr.it\0"
-"test.ru\0cc.tn.us\0"
-"ms.kr\0museumvereniging.museum\0"
-"time.no\0k12.ia.us\0"
-"vladimir.ru\0"
-"correios-e-telecomunica\xc3\xa7\xc3\xb5""es.museum\0"
-"gouv.km\0nationalfirearms.museum\0"
-"m\xc3\xa1latvuopmi.no\0"
-"aero\0yosemite.museum\0"
-"r.bg\0school.na\0"
-"cc.vi.us\0"
-"*.wakayama.jp\0"
-"beauxarts.museum\0averoy.no\0ullensvang.no\0bar.pro\0"
-"!city.hiroshima.jp\0"
-"b\xc3\xa1hccavuotna.no\0"
-"frosta.no\0"
-"gdynia.pl\0"
-"medical.museum\0"
-"embaixada.st\0"
-"balsan.it\0vantaa.museum\0"
-"za.net\0"
-"!city.saitama.jp\0lib.ks.us\0"
-"fnd.br\0"
-"ru.com\0se.com\0hol.no\0modalen.no\0"
-"gouv.ml\0chukotka.ru\0"
-"malopolska.pl\0"
-"mansion.museum\0"
-"iki.fi\0children.museum\0"
-"cyber.museum\0rec.nf\0mo\xc3\xa5reke.no\0"
-"to.it\0"
-"hasvik.no\0"
-"\xc3\xb8yer.no\0"
-"arts.ro\0sc.ug\0"
-"lib.ar.us\0"
-"sc.tz\0cc.ms.us\0cc.nc.us\0"
-"etc.br\0poznan.pl\0"
-"cnt.br\0viking.museum\0"
-"*.miyazaki.jp\0"
-"melhus.no\0"
-"skodje.no\0vevelstad.no\0"
-"sc.us\0"
-"upow.gov.pl\0"
-"!city.fukuoka.jp\0brandywinevalley.museum\0natuurwetenschappen.museum\0tranby.no\0"
-"bahn.museum\0msk.ru\0"
-"delmenhorst.museum\0"
-"russia.museum\0fuoisku.no\0"
-"shell.museum\0"
-"r\xc3\xa1isa.no\0"
-"hs.kr\0udmurtia.ru\0"
-"palermo.it\0"
-"pilot.aero\0"
-"tn.us\0"
-"priv.hu\0"
-"li.it\0"
-"kr\xc3\xa5""anghke.no\0mosreg.ru\0"
-"lib.fl.us\0"
-"plants.museum\0"
-"ulsan.kr\0national.museum\0"
-"mil.ac\0!pref.nara.jp\0surgeonshall.museum\0"
-"mil.ae\0santacruz.museum\0vi.us\0"
-"wlocl.pl\0"
-"mt.it\0napoli.it\0alaska.museum\0arts.nf\0"
-"missoula.museum\0"
-"rec.ro\0"
-"mil.al\0"
-"marburg.museum\0waw.pl\0"
-"pharmaciens.km\0indianapolis.museum\0larsson.museum\0"
-"cc.sd.us\0"
-"mil.ba\0mobi\0"
-"indianmarket.museum\0"
-"recreation.aero\0padova.it\0"
-"varese.it\0parti.se\0"
-"mil.az\0"
-"mil.bo\0!pref.kagoshima.jp\0khmelnitskiy.ua\0"
-"rygge.no\0"
-"os\xc3\xb8yro.no\0"
-"mil.br\0"
-"cs.it\0"
-"austevoll.no\0fjell.no\0"
-"mil.by\0"
-"!pref.tokushima.jp\0org\0"
-"mil.cn\0gs.svalbard.no\0"
-"mil.co\0"
-"pz.it\0lib.va.us\0\xd1\x80\xd1\x84\0"
-"\xe4\xb8\xaa\xe4\xba\xba.hk\0ms.us\0nc.us\0k12.wi.us\0"
-"s.bg\0drangedal.no\0"
-"en.it\0"
-"culturalcenter.museum\0"
-"house.museum\0divttasvuotna.no\0"
-"fhs.no\0"
-"circus.museum\0"
-"priv.at\0"
-"mil.ec\0"
-"ruovat.no\0"
-"midsund.no\0vagan.no\0"
-"casadelamoneda.museum\0"
-"bristol.museum\0"
-"and.museum\0"
-"ascolipiceno.it\0computerhistory.museum\0vyatka.ru\0"
-"uhren.museum\0"
-"lahppi.no\0"
-"*.yokohama.jp\0cody.museum\0lib.al.us\0"
-"colonialwilliamsburg.museum\0indian.museum\0cc.ky.us\0"
-"tp.it\0biev\xc3\xa1t.no\0"
-"can.br\0royken.no\0"
+"eidskog.no\0lanbib.se\0"
+"gob.cl\0kristiansund.no\0"
"id.ir\0"
-"mediocampidano.it\0tromso.no\0"
-"kartuzy.pl\0k12.ok.us\0"
-"*.saitama.jp\0stjohn.museum\0m\xc3\xa1tta-v\xc3\xa1rjjat.no\0"
-"mil.ge\0trani-barletta-andria.it\0"
-"lib.as.us\0"
-"swiebodzin.pl\0cc.mt.us\0cc.nd.us\0"
-"mil.gh\0"
-"science-fiction.museum\0\xd9\x82\xd8\xb7\xd8\xb1\0"
-"airtraffic.aero\0"
-"konskowola.pl\0"
-"scienceandhistory.museum\0nysa.pl\0sd.us\0"
-"balestrand.no\0"
-"oygarden.no\0"
-"her\xc3\xb8y.nordland.no\0"
-"!pref.ishikawa.jp\0strand.no\0"
-"\xe7\xb5\x84\xe7\xbb\x87.hk\0mil.hn\0"
-"gob.bo\0volda.no\0"
-"losangeles.museum\0larvik.no\0"
-"university.museum\0"
-"cc.dc.us\0"
-"mil.id\0"
-"sorfold.no\0"
-"watch-and-clock.museum\0"
-"flor\xc3\xb8.no\0"
-"nittedal.no\0oppeg\xc3\xa5rd.no\0"
-"k12.ri.us\0"
-"gob.cl\0"
-"komi.ru\0"
-"government.aero\0mil.in\0"
-"mil.iq\0id.lv\0"
-"culture.museum\0"
-"id.ly\0"
-"raholt.no\0"
-"lubin.pl\0grozny.ru\0"
-"kchr.ru\0"
-"nikolaev.ua\0"
-"lib.sd.us\0"
-"de.com\0"
-"mil.jo\0"
-"*.kanagawa.jp\0gaular.no\0miasta.pl\0"
-"bi.it\0rnu.tn\0uzhgorod.ua\0"
-"idrett.no\0v\xc3\xa5gs\xc3\xb8y.no\0"
-"wroclaw.pl\0"
-"res.aero\0ne.jp\0mil.kg\0"
-"\xc3\xa5mli.no\0"
-"education.museum\0"
-"dgca.aero\0"
-"mil.km\0"
-"trolley.museum\0"
-"cci.fr\0r.se\0"
-"archaeological.museum\0"
-"monzaedellabrianza.it\0mil.kr\0"
-"gob.es\0kvafjord.no\0ky.us\0"
-"lecco.it\0"
-"ct.it\0"
+"iwate.iwate.jp\0"
+"hotel.lk\0"
+"omiya.saitama.jp\0"
+"tanagura.fukushima.jp\0"
+"perm.ru\0"
+"\xc3\xb8rland.no\0"
+"western.museum\0from-va.com\0"
+"game-server.cc\0"
+"gob.do\0hita.oita.jp\0"
+"ashibetsu.hokkaido.jp\0zgorzelec.pl\0"
+"gob.ec\0"
+"blogspot.co.il\0"
+"barum.no\0"
+"bozen.it\0kotohira.kagawa.jp\0tm.ro\0gouv.rw\0"
+"varese.it\0hirokawa.fukuoka.jp\0"
+"ia.us\0k12.ct.us\0"
+"tm.se\0"
+"gouv.sn\0lib.or.us\0"
+"is-a-therapist.com\0"
+"pc.pl\0"
+"gob.es\0seiro.niigata.jp\0farsund.no\0"
"magazine.aero\0"
-"operaunite.com\0ne.kr\0"
-"mil.kz\0skoczow.pl\0"
-"nf.ca\0"
-"western.museum\0"
-"kunst.museum\0gaivuotna.no\0karpacz.pl\0spb.ru\0cc.id.us\0"
-"slask.pl\0"
-"youth.museum\0"
-"adv.br\0campidanomedio.it\0!songfest.om\0"
-"geelvinck.museum\0\xd8\xa7\xd9\x85\xd8\xa7\xd8\xb1\xd8\xa7\xd8\xaa\0"
-"mil.lv\0"
-"fie.ee\0mil.mg\0mt.us\0nd.us\0k12.vt.us\0"
-"t.bg\0ushuaia.museum\0"
-"off.ai\0"
-"irkutsk.ru\0"
-"stor-elvdal.no\0tourism.tn\0"
-"penza.ru\0"
-"bj.cn\0\xe4\xb8\xad\xe5\x9b\xbd\0"
-"civilwar.museum\0mil.mv\0opole.pl\0"
-"nes.akershus.no\0"
-"mil.my\0karelia.ru\0"
-"como.it\0sande.vestfold.no\0"
-"\xe4\xb8\xad\xe5\x9c\x8b\0"
-"gob.hn\0lib.la.us\0"
-"mil.no\0cc.wv.us\0"
-"boleslawiec.pl\0"
-"!pref.niigata.jp\0gs.sf.no\0dc.us\0k12.mi.us\0"
-"museum\0dep.no\0kv\xc3\xa6nangen.no\0l\xc3\xa1hppi.no\0"
-"film.museum\0"
-"frei.no\0"
-"notodden.no\0risor.no\0"
-"messina.it\0"
-"eidsberg.no\0"
-"krakow.pl\0lib.mt.us\0lib.nd.us\0"
-"rauma.no\0"
-"mulhouse.museum\0"
-"sibenik.museum\0grong.no\0mil.pe\0"
-"budejju.no\0k12.nv.us\0"
-"stavanger.no\0mil.ph\0"
-"forli-cesena.it\0"
-"naples.it\0cc.ne.us\0"
-"s\xc3\xb8r-aurdal.no\0"
-"mil.pl\0"
-"vibo-valentia.it\0ski.museum\0siedlce.pl\0"
-"bus.museum\0"
-"tozsde.hu\0"
-"!pref.shizuoka.jp\0santabarbara.museum\0"
-"zhitomir.ua\0"
-"pro.az\0"
-"ne.pw\0"
-"pro.br\0orkanger.no\0b\xc3\xb8.telemark.no\0"
-"roma.it\0cc.ct.us\0"
-"heritage.museum\0giske.no\0"
-"!pref.kumamoto.jp\0prof.pr\0"
-"*.kochi.jp\0"
-"andria-barletta-trani.it\0*.toyama.jp\0sveio.no\0"
-"id.us\0"
-"bolt.hu\0"
-"fetsund.no\0porsgrunn.no\0"
-"iglesias-carbonia.it\0"
-"sf.no\0"
-"mil.ru\0"
-"from.hr\0asnes.no\0mil.rw\0"
-"alesund.no\0sos.pl\0"
-"livorno.it\0"
-"crafts.museum\0"
-"aquila.it\0"
-"vega.no\0"
-"jewelry.museum\0"
-"sk\xc3\xa1nit.no\0chita.ru\0"
-"pro.ec\0"
-"fortmissoula.museum\0j\xc3\xb8lster.no\0"
-"pro\0mil.st\0"
-"busan.kr\0lib.ga.us\0"
-"dellogliastra.it\0"
-"aosta.it\0chungnam.kr\0gob.mx\0"
-"mil.sy\0k12.hi.us\0"
-"mil.tj\0"
-"ulan-ude.ru\0mil.to\0wv.us\0"
-"luster.no\0volgograd.ru\0"
-"pa.it\0kommunalforbund.se\0lib.tx.us\0"
-"s.se\0"
-"qsl.br\0"
-"mil.tw\0"
-"est.pr\0ens.tn\0"
-"lib.id.us\0"
-"mil.tz\0"
-"uscountryestate.museum\0"
-"agents.aero\0"
-"\xc3\xb8vre-eiker.no\0ne.ug\0"
-"pb.ao\0"
-"gob.pa\0ne.tz\0"
-"tur.br\0"
-"mil.vc\0"
-"or.at\0gob.pe\0"
-"s\xc3\xb8r-fron.no\0"
-"or.bi\0ne.us\0"
-"u.bg\0gob.pk\0"
-"stavern.no\0"
-"brindisi.it\0"
-"aknoluokta.no\0"
-"!pref.kyoto.jp\0tydal.no\0"
-"plc.ly\0muos\xc3\xa1t.no\0"
-"or.ci\0hamaroy.no\0priv.pl\0"
-"vestre-slidre.no\0gniezno.pl\0"
-"\xe7\xae\x87\xe4\xba\xba.hk\0"
-"andebu.no\0"
-"nieruchomosci.pl\0\xd8\xa7\xd9\x84\xd8\xb3\xd8\xb9\xd9\x88\xd8\xaf\xd9\x8a\xd8\xa9\0"
-"or.cr\0pro.ht\0bolzano.it\0"
-"ct.us\0k12.md.us\0"
-"za.org\0"
-"!icnet.uk\0"
-"localhistory.museum\0"
-"firm.ht\0"
-"lel.br\0tr.it\0kvanangen.no\0"
-"sondre-land.no\0t\xc3\xb8nsberg.no\0vefsn.no\0"
-"nature.museum\0yamal.ru\0"
-"rv.ua\0"
-"lans.museum\0lib.ne.us\0"
-"lur\xc3\xb8y.no\0"
-"eu.com\0firm.in\0"
-"hjelmeland.no\0"
-"gs.tr.no\0"
-"casino.hu\0essex.museum\0tourism.pl\0"
-"rennesoy.no\0"
-"priv.no\0"
-"baths.museum\0mytis.ru\0"
-"tingvoll.no\0"
-"cc.az.us\0"
-"sh.cn\0"
-"!pref.miyazaki.jp\0s\xc3\xb8rfold.no\0"
-"aurskog-holand.no\0malatvuopmi.no\0"
-"lib.ct.us\0"
-"cc.pa.us\0"
-"pa.gov.pl\0"
-"firm.co\0cc.de.us\0"
-"nrw.museum\0"
-"daejeon.kr\0livinghistory.museum\0"
-"gildeskal.no\0lund.no\0"
-"\xc3\xb8ksnes.no\0stavropol.ru\0"
-"b\xc3\xa6rum.no\0r\xc3\xb8yrvik.no\0"
-"osoyro.no\0"
-"priv.me\0sula.no\0!parliament.uk\0"
-"nationalheritage.museum\0"
-"jaworzno.pl\0"
-"dinosaur.museum\0"
-"garden.museum\0trust.museum\0"
-"turen.tn\0"
-"kautokeino.no\0"
-"pro.na\0"
-"gorizia.it\0"
-"siljan.no\0"
-"or.id\0pro.mv\0"
-"bieszczady.pl\0www.ro\0"
-"lib.ee\0antiques.museum\0brasil.museum\0tr.no\0"
-"aejrie.no\0"
-"!pref.hokkaido.jp\0"
-"schlesisches.museum\0"
-"huissier-justice.fr\0or.it\0"
-"t.se\0"
-"environment.museum\0"
-"vindafjord.no\0"
-"edu.ac\0or.jp\0"
-"tree.museum\0"
-"groundhandling.aero\0edu.af\0"
-"rochester.museum\0sanfrancisco.museum\0"
-"ebiz.tw\0"
-"kirovograd.ua\0"
+"ueno.gunma.jp\0\xe7\xb6\xb2\xe8\xb7\xaf.tw\0"
+"ayase.kanagawa.jp\0kitaura.miyazaki.jp\0"
+"cz.it\0"
+"tp.it\0ikoma.nara.jp\0"
+"presse.ci\0konin.pl\0"
+"id.lv\0eigersund.no\0nore-og-uvdal.no\0"
+"yoshimi.saitama.jp\0fl.us\0"
+"id.ly\0"
+"dyndns.biz\0"
+"ohkura.yamagata.jp\0"
+"vlaanderen.museum\0"
+"surnadal.no\0"
+"urbino-pesaro.it\0"
+"evenassi.no\0from-ok.com\0"
+"tara.saga.jp\0hashimoto.wakayama.jp\0"
+"gob.gt\0"
+"hotel.hu\0gs.vf.no\0\xe0\xb6\xbd\xe0\xb6\x82\xe0\xb6\x9a\xe0\xb7\x8f\0"
+"groks-the.info\0"
+"!bl.uk\0"
+"ota.gunma.jp\0"
+"gob.hn\0kitagata.gifu.jp\0"
+"airline.aero\0simbirsk.ru\0"
+"katashina.gunma.jp\0hiraizumi.iwate.jp\0"
+"hirado.nagasaki.jp\0corporation.museum\0"
+"volyn.ua\0"
+"fujisawa.kanagawa.jp\0"
+"6bone.pl\0"
+"gifu.gifu.jp\0kami.kochi.jp\0"
+"molde.no\0"
+"essex.museum\0"
+"tatsuno.hyogo.jp\0"
+"cherkasy.ua\0"
+"sayo.hyogo.jp\0"
+"ar.us\0is-an-engineer.com\0"
+"k12.ma.us\0"
+"d.bg\0"
+"shimofusa.chiba.jp\0"
+"california.museum\0"
+"songdalen.no\0svelvik.no\0"
+"vic.au\0setouchi.okayama.jp\0"
+"presse.fr\0"
+"theater.museum\0"
+"leg.br\0harvestcelebration.museum\0"
+"mus.br\0"
+"towada.aomori.jp\0"
+"mochizuki.nagano.jp\0is-a-knight.org\0"
+"nsn.us\0"
+"lindas.no\0"
+"na.it\0"
+"paderborn.museum\0"
+"catanzaro.it\0wajiki.tokushima.jp\0"
+"gosen.niigata.jp\0busan.kr\0clinton.museum\0embaixada.st\0"
+"\xe7\xb6\xb2\xe7\xbb\x9c.hk\0jfk.museum\0"
+"hanamaki.iwate.jp\0mielec.pl\0"
+"casadelamoneda.museum\0hjelmeland.no\0"
+"cc.gu.us\0"
+"is-a-anarchist.com\0"
+"\xc3\xb8stre-toten.no\0is-a-geek.org\0"
+"katori.chiba.jp\0myphotos.cc\0"
+"hakata.fukuoka.jp\0"
+"oguchi.aichi.jp\0hachirogata.akita.jp\0"
+"eniwa.hokkaido.jp\0"
+"tottori.jp\0okagaki.fukuoka.jp\0mn.us\0"
+"bergamo.it\0noda.chiba.jp\0"
+"coastaldefence.museum\0rec.nf\0"
+"izu.shizuoka.jp\0"
+"karuizawa.nagano.jp\0"
+"tadaoka.osaka.jp\0"
+"gouv.km\0"
+"lunner.no\0"
+"topology.museum\0"
+"maibara.shiga.jp\0ostroda.pl\0"
+"takamori.nagano.jp\0"
+"larsson.museum\0"
+"obama.fukui.jp\0"
+"gob.mx\0amot.no\0"
+"hida.gifu.jp\0"
+"alessandria.it\0nagiso.nagano.jp\0"
+"shunan.yamaguchi.jp\0"
+"ogawara.miyagi.jp\0"
+"ritto.shiga.jp\0"
+"tsuru.yamanashi.jp\0lomza.pl\0"
+"f\xc3\xb8rde.no\0"
+"yokaichiba.chiba.jp\0"
+"\xc3\xb8ygarden.no\0pskov.ru\0"
+"chiba.jp\0"
+"irc.pl\0"
+"fr.it\0mo\xc3\xa5reke.no\0"
+"gen.in\0"
+"gouv.ml\0"
+"estate.museum\0"
+"id.us\0k12.de.us\0"
+"aomori.aomori.jp\0naturalhistorymuseum.museum\0lib.pa.us\0"
+"iwaki.fukushima.jp\0gob.pa\0"
+"vaapste.no\0"
+"kosei.shiga.jp\0"
+"shirosato.ibaraki.jp\0gob.pe\0from-la.net\0"
+"tj\xc3\xb8me.no\0"
+"viking.museum\0"
+"neat-url.com\0"
+"chelyabinsk.ru\0"
+"gob.pk\0"
+"selbu.no\0"
+"shari.hokkaido.jp\0"
+"gausdal.no\0"
+"edu.ac\0catania.it\0ureshino.mie.jp\0a.se\0"
+"ts.it\0is-a-celticsfan.org\0"
+"edu.af\0school.museum\0"
+"blogspot.co.uk\0"
+"k12.ar.us\0"
+"lib.mt.us\0lib.nd.us\0"
"edu.al\0"
-"edu.an\0\xc3\xa1k\xc5\x8boluokta.no\0v\xc3\xa5g\xc3\xa5.no\0"
-"v.bg\0"
+"edu.an\0entomology.museum\0gildeskal.no\0"
+"gallery.museum\0stuff-4-sale.us\0"
+"nesodden.no\0"
"edu.ba\0"
-"edu.bb\0nesset.no\0"
-"hornindal.no\0pro.pr\0"
-"or.kr\0"
-"az.us\0"
-"edu.bh\0volkenkunde.museum\0"
-"edu.bi\0"
-"edu.az\0"
-"b\xc3\xb8mlo.no\0"
+"edu.bb\0"
+"iizuka.fukuoka.jp\0shikabe.hokkaido.jp\0"
+"edu.au\0"
+"rec.ro\0"
+"chosei.chiba.jp\0"
+"edu.bh\0msk.ru\0"
+"edu.bi\0sauherad.no\0"
+"edu.az\0ardal.no\0"
+"rn.it\0game-host.org\0"
"edu.bm\0"
-"edu.bo\0tyumen.ru\0"
+"histoire.museum\0"
+"edu.bo\0mihama.mie.jp\0"
+"massacarrara.it\0mobara.chiba.jp\0aogaki.hyogo.jp\0hatogaya.saitama.jp\0oe.yamagata.jp\0"
"edu.br\0"
-"edu.bs\0pa.us\0"
-"alto-adige.it\0whaling.museum\0"
-"*.iwate.jp\0"
-"edu.ci\0law.pro\0"
-"edu.bz\0de.us\0"
-"lib.ak.us\0"
+"edu.bs\0"
+"edu.bt\0"
+"tamakawa.fukushima.jp\0uslivinghistory.museum\0waw.pl\0"
+"tas.edu.au\0edu.ci\0yura.wakayama.jp\0"
+"edu.bz\0niepce.museum\0baidar.no\0"
+"mod.gi\0"
+"vicenza.it\0gets-it.net\0"
"edu.cn\0"
-"edu.co\0"
-"laspezia.it\0"
-"baidar.no\0"
-"ts.it\0"
-"or.na\0"
-"edu.cu\0hotel.lk\0"
-"show.aero\0or.mu\0"
-"sandnes.no\0"
-"museumcenter.museum\0"
-"edu.dm\0kazan.ru\0"
-"biz\0caltanissetta.it\0odessa.ua\0k12.oh.us\0"
-"crimea.ua\0"
-"research.aero\0lom.no\0"
-"edu.ec\0florence.it\0clock.museum\0sshn.se\0"
-"edu.ee\0game.tw\0"
-"!pref.okinawa.jp\0"
-"ilawa.pl\0"
-"edu.dz\0indiana.museum\0"
-"gs.jan-mayen.no\0"
-"publ.pt\0"
-"nom.ad\0"
-"skanit.no\0gdansk.pl\0k12.pa.us\0"
-"nom.ag\0edu.es\0"
-"if.ua\0"
-"pro.tt\0lib.de.us\0"
-"environmentalconservation.museum\0cc.or.us\0"
-"bern.museum\0nat.tn\0"
-"rubtsovsk.ru\0"
-"!educ.ar\0masoy.no\0"
-"bologna.it\0"
-"\xc3\xa5snes.no\0fhv.se\0"
-"*.tottori.jp\0radoy.no\0"
-"romskog.no\0"
-"malbork.pl\0"
-"olbiatempio.it\0"
-"edu.ge\0"
-"edu.gh\0"
+"edu.co\0glass.museum\0sciencecenter.museum\0"
+"tv.bo\0neyagawa.osaka.jp\0"
+"pi.it\0arakawa.tokyo.jp\0"
+"isahaya.nagasaki.jp\0iwatsuki.saitama.jp\0"
+"tv.br\0"
+"edu.cu\0"
+"gs.st.no\0"
+"g.bg\0kamisunagawa.hokkaido.jp\0"
+"omigawa.chiba.jp\0"
+"edu.dm\0so.gov.pl\0"
+"sa.au\0nakagawa.fukuoka.jp\0"
+"edu.do\0"
+"edu.ec\0suginami.tokyo.jp\0"
+"hashima.gifu.jp\0"
+"edu.ee\0"
+"edu.eg\0"
+"mt.it\0hadano.kanagawa.jp\0dontexist.net\0"
+"edu.dz\0pistoia.it\0hobol.no\0"
+"warabi.saitama.jp\0"
+"trading.aero\0nsw.au\0kagawa.jp\0hadsel.no\0"
+"ooshika.nagano.jp\0"
+"edu.es\0isa.kagoshima.jp\0n\xc3\xa5\xc3\xa5mesjevuemie.no\0"
+"priv.hu\0"
+"jewishart.museum\0"
+"meeres.museum\0trust.museum\0"
+"suifu.ibaraki.jp\0"
+"oarai.ibaraki.jp\0bomlo.no\0"
+"sa.cr\0tarnobrzeg.pl\0"
+"conference.aero\0"
+"kasaoka.okayama.jp\0"
+"gjovik.no\0her\xc3\xb8y.nordland.no\0sk\xc3\xa5nland.no\0"
+"edu.ge\0wazuka.kyoto.jp\0"
+"syzran.ru\0k12.id.us\0"
+"edu.gh\0wakasa.tottori.jp\0fylkesbibl.no\0snoasa.no\0"
"edu.gi\0"
-"or.pw\0"
-"hob\xc3\xb8l.no\0"
-"nom.br\0edu.gn\0virginia.museum\0mbone.pl\0!nls.uk\0"
-"seljord.no\0pro.vn\0"
+"nom.ad\0"
+"kamifurano.hokkaido.jp\0"
+"kitamoto.saitama.jp\0targi.pl\0"
+"nom.ag\0kuki.saitama.jp\0arendal.no\0"
+"edu.gn\0"
"edu.gp\0"
-"edu.gr\0"
-"!uba.ar\0!pref.saitama.jp\0"
-"greta.fr\0gs.aa.no\0kvinnherad.no\0"
-"lib.sc.us\0"
-"js.cn\0nom.co\0edu.hk\0"
-"lesja.no\0"
-"bl.it\0"
-"edu.hn\0\xc3\xb8ystre-slidre.no\0mari-el.ru\0"
-"hotel.hu\0"
-"rindal.no\0"
-"edu.ht\0"
-"!pref.miyagi.jp\0"
-"midtre-gauldal.no\0"
-"xj.cn\0australia.museum\0"
-"ab.ca\0salvadordali.museum\0olawa.pl\0"
-"pc.it\0"
-"u.se\0"
-"edu.in\0b\xc3\xa1l\xc3\xa1t.no\0"
-"ln.cn\0alta.no\0"
-"chelyabinsk.ru\0"
+"edu.gr\0akishima.tokyo.jp\0"
+"cc.vi.us\0"
+"edu.gt\0toyokawa.aichi.jp\0"
+"nikolaev.ua\0"
+"meiwa.mie.jp\0kaneyama.yamagata.jp\0"
+"sel.no\0"
+"edu.hk\0is-an-entertainer.com\0is-certified.com\0"
+"edu.hn\0burghof.museum\0"
+"contemporary.museum\0from-wa.com\0"
+"s\xc3\xb8r-varanger.no\0"
+"klepp.no\0"
+"edu.ht\0fedje.no\0!mediaphone.om\0"
+"krodsherad.no\0"
+"web.co\0"
+"messina.it\0fussa.tokyo.jp\0"
+"nom.br\0divtasvuodna.no\0"
+"war.museum\0porsgrunn.no\0"
+"amursk.ru\0"
+"edu.in\0ge.it\0komatsu.ishikawa.jp\0"
+"is-very-evil.org\0"
"edu.iq\0"
-"ontario.museum\0"
-"edu.is\0"
+"edu.is\0erimo.hokkaido.jp\0"
"edu.it\0"
-"b\xc3\xa5tsfjord.no\0"
-"trysil.no\0or.th\0"
-"utsira.no\0"
-"nom.es\0edu.jo\0fhsk.se\0"
-"bale.museum\0"
-"w.bg\0"
-"lillesand.no\0"
+"nom.co\0univ.sn\0k12.tx.us\0"
+"web.do\0"
+"minami.tokushima.jp\0"
+"jeju.kr\0"
+"soc.lk\0grimstad.no\0kharkov.ua\0gb.net\0"
+"ralingen.no\0"
+"edu.jo\0"
+"miura.kanagawa.jp\0kunigami.okinawa.jp\0priv.at\0"
+"time.museum\0"
+"kaho.fukuoka.jp\0d.se\0"
+"tv.it\0blogspot.co.nz\0"
"edu.kg\0"
-"amusement.aero\0"
"edu.ki\0"
-"fauske.no\0or.ug\0"
-"int.az\0askvoll.no\0eidskog.no\0cv.ua\0"
-"algard.no\0"
-"edu.km\0or.tz\0"
-"nom.fr\0edu.kn\0"
-"*.ibaraki.jp\0hoylandet.no\0"
-"int.bo\0edu.kp\0"
+"ass.km\0"
+"k12.as.us\0"
+"lahppi.no\0\xe0\xae\x87\xe0\xae\xb2\xe0\xae\x99\xe0\xaf\x8d\xe0\xae\x95\xe0\xaf\x88\0"
+"edu.km\0lib.ms.us\0lib.nc.us\0"
+"izunokuni.shizuoka.jp\0edu.kn\0"
+"nakagusuku.okinawa.jp\0edu.kp\0"
"edu.la\0"
-"si.it\0edu.lb\0travel.pl\0"
-"edu.lc\0mx.na\0n\xc3\xa1vuotna.no\0ovre-eiker.no\0"
-"aa.no\0!siemens.om\0"
-"sciences.museum\0or.us\0"
-"cat\0"
-"edu.ky\0"
-"int.ci\0edu.kz\0firm.ro\0cc.wy.us\0"
-"edu.lk\0vaapste.no\0"
-"!pref.tochigi.jp\0"
-"int.co\0podlasie.pl\0"
-"edu.lr\0"
-"karikatur.museum\0jamal.ru\0"
-"gjovik.no\0krager\xc3\xb8.no\0k12.az.us\0"
-"edu.me\0"
-"ud.it\0edu.lv\0entomology.museum\0"
-"edu.mg\0moskenes.no\0"
-"\xe6\x94\xbf\xe5\xba\x9c.hk\0edu.ly\0"
-"stpetersburg.museum\0"
+"yashio.saitama.jp\0edu.lb\0"
+"nozawaonsen.nagano.jp\0edu.lc\0"
+"oguni.yamagata.jp\0jelenia-gora.pl\0gdansk.pl\0"
+"tobetsu.hokkaido.jp\0"
+"matsuura.nagasaki.jp\0"
+"nom.es\0daito.osaka.jp\0edu.ky\0"
+"ozu.ehime.jp\0edu.kz\0"
+"edu.lk\0"
+"sa.it\0"
+"lier.no\0"
+"cremona.it\0"
+"oamishirasato.chiba.jp\0edu.lr\0"
+"matsusaka.mie.jp\0edu.me\0"
+"minokamo.gifu.jp\0edu.lv\0divttasvuotna.no\0"
+"edu.mg\0"
+"nom.fr\0"
+"edu.ly\0"
+"club.tw\0"
"edu.mk\0"
-"edu.ml\0nordreisa.no\0"
-"!pref.fukui.jp\0lib.ms.us\0lib.nc.us\0"
-"edu.mn\0\xd9\x81\xd9\x84\xd8\xb3\xd8\xb7\xd9\x8a\xd9\x86\0"
-"fot.br\0edu.mo\0"
-"iron.museum\0"
-"asti.it\0annefrank.museum\0stv.ru\0cc.nh.us\0"
+"edu.ml\0"
+"wakayama.wakayama.jp\0skierv\xc3\xa1.no\0"
+"edu.mn\0"
+"edu.mo\0saratov.ru\0cc.me.us\0"
+"vdonsk.ru\0"
+"from-ar.com\0"
+"zgora.pl\0"
+"usculture.museum\0mari.ru\0"
+"daiwa.hiroshima.jp\0"
"edu.mv\0"
-"lodi.it\0edu.mw\0edu.ng\0"
-"gwangju.kr\0edu.mx\0"
+"edu.mw\0edu.ng\0kaszuby.pl\0"
+"edu.mx\0"
"edu.my\0"
-"soundandvision.museum\0"
-"lenvik.no\0"
-"ballooning.aero\0"
-"name\0"
-"jogasz.hu\0frogn.no\0"
-"history.museum\0"
-"consultant.aero\0edu.nr\0"
-"manchester.museum\0"
-"*.hiroshima.jp\0"
-"pol.dz\0"
-"*.tochigi.jp\0heimatunduhren.museum\0"
-"!pref.kanagawa.jp\0"
-"firm.nf\0edu.pa\0"
-"coop.ht\0pc.pl\0"
-"chicago.museum\0"
-"vn.ua\0"
-"edu.pe\0"
-"tana.no\0edu.pf\0"
+"usui.fukuoka.jp\0"
+"j.bg\0web.id\0"
+"sr.gov.pl\0"
+"s\xc3\xb8mna.no\0"
+"info.ht\0sauda.no\0"
+"info.hu\0"
+"edu.nr\0"
+"tv.na\0"
+"\xe0\xae\x9a\xe0\xae\xbf\xe0\xae\x99\xe0\xaf\x8d\xe0\xae\x95\xe0\xae\xaa\xe0\xaf\x8d\xe0\xae\xaa\xe0\xaf\x82\xe0\xae\xb0\xe0\xaf\x8d\0"
+"chuo.tokyo.jp\0"
+"s\xc3\xa1lat.no\0"
+"dazaifu.fukuoka.jp\0"
+"kawai.nara.jp\0"
+"eun.eg\0"
+"koshimizu.hokkaido.jp\0"
+"charter.aero\0"
+"thruhere.net\0"
+"usgarden.museum\0"
+"kanoya.kagoshima.jp\0edu.pa\0"
+"kihoku.ehime.jp\0kalisz.pl\0"
+"sakura.tochigi.jp\0"
+"agrar.hu\0edu.pe\0"
+"edu.pf\0"
"edu.ph\0"
-"nom.km\0"
-"travel.tt\0"
+"sd.cn\0oxford.museum\0"
"edu.pk\0"
-"experts-comptables.fr\0edu.pl\0bryansk.ru\0"
+"edu.pl\0"
"edu.pn\0"
-"evje-og-hornnes.no\0warszawa.pl\0"
-"ac.ae\0"
-"edu.pr\0"
-"vaksdal.no\0edu.ps\0dni.us\0"
-"po.gov.pl\0edu.pt\0"
-"nordre-land.no\0vadso.no\0"
-"rnrt.tn\0"
-"sport.hu\0!pref.gifu.jp\0voss.no\0targi.pl\0"
-"flesberg.no\0"
-"photography.museum\0"
-"modena.it\0tonsberg.no\0"
-"ac.at\0"
-"ac.be\0coop.br\0"
-"services.aero\0"
-"nom.mg\0"
-"wielun.pl\0"
-"jefferson.museum\0wy.us\0"
-"pd.it\0ot.it\0neues.museum\0slattum.no\0"
-"vdonsk.ru\0"
-"ar.com\0edu.sa\0"
-"\xc3\xa5l.no\0edu.sb\0"
+"arao.kumamoto.jp\0"
+"edu.qa\0"
+"kr.it\0nakijin.okinawa.jp\0edu.pr\0"
+"edu.ps\0"
+"fjaler.no\0edu.pt\0"
+"gotdns.org\0"
+"itoigawa.niigata.jp\0oregontrail.museum\0kvafjord.no\0"
+"mt.us\0nd.us\0"
+"freight.aero\0ando.nara.jp\0edu.py\0"
+"ino.kochi.jp\0"
+"portlligat.museum\0"
+"web.lk\0"
+"nom.km\0music.museum\0"
+"ishikawa.okinawa.jp\0"
+"chtr.k12.ma.us\0"
+"andriabarlettatrani.it\0"
+"nationalheritage.museum\0giehtavuoatna.no\0"
+"im.it\0"
+"hareid.no\0"
+"kids.museum\0"
+"kanmaki.nara.jp\0tra.kp\0"
+"numata.gunma.jp\0"
+"info.ec\0hizen.saga.jp\0labour.museum\0honefoss.no\0"
+"misato.wakayama.jp\0edu.sa\0lib.sd.us\0"
+"arts.co\0shima.mie.jp\0edu.sb\0"
"edu.rs\0edu.sc\0"
-"ac.ci\0int.is\0edu.sd\0!tsk.tr\0"
-"br\xc3\xb8nn\xc3\xb8ysund.no\0and\xc3\xb8y.no\0edu.ru\0"
-"pol.ht\0"
+"edu.sd\0"
+"tama.tokyo.jp\0t\xc3\xb8nsberg.no\0edu.ru\0"
"edu.rw\0edu.sg\0"
-"gyeongnam.kr\0olecko.pl\0"
-"ac.cn\0"
-"graz.museum\0"
-"coldwar.museum\0edu.sl\0"
-"ac.cr\0"
-"edu.sn\0"
-"hamar.no\0"
-"histoire.museum\0"
-"!city.shizuoka.jp\0"
+"komae.tokyo.jp\0"
+"mazowsze.pl\0"
+"shintoku.hokkaido.jp\0lans.museum\0edu.sl\0"
+"nom.mg\0l\xc3\xa4ns.museum\0web.nf\0skjak.no\0\xe7\xb5\x84\xe7\xb9\x94.tw\0"
+"info.bb\0chel.ru\0edu.sn\0"
+"trd.br\0info.at\0"
+"info.au\0"
+"chikuzen.fukuoka.jp\0asahi.toyama.jp\0"
"edu.st\0"
-"oceanographic.museum\0nh.us\0"
-"x.bg\0"
-"surnadal.no\0"
-"fc.it\0costume.museum\0stalowa-wola.pl\0"
-"valer.ostfold.no\0edu.sy\0"
+"info.az\0tv.sd\0"
+"shimonoseki.yamaguchi.jp\0edu.sy\0"
"edu.tj\0"
-"arq.br\0"
-"aeroclub.aero\0odo.br\0pe.ca\0\xe7\xb6\xb2\xe7\xb5\xa1.cn\0bronnoysund.no\0nom.pa\0"
+"radoy.no\0"
+"sasaguri.fukuoka.jp\0nakano.nagano.jp\0ogimi.okinawa.jp\0computerhistory.museum\0ug.gov.pl\0edu.tm\0"
+"abira.hokkaido.jp\0"
"edu.to\0"
-"paleo.museum\0nom.pe\0edu.ua\0"
-"int.la\0trustee.museum\0forsand.no\0krasnoyarsk.ru\0"
-"!pref.hyogo.jp\0"
-"edu.tt\0"
-"zarow.pl\0"
-"edu.tw\0"
+"edu.ua\0"
+"lavagis.no\0cc.al.us\0"
+"kopervik.no\0edu.tt\0"
+"nishimera.miyazaki.jp\0kuban.ru\0"
+"g.se\0edu.tw\0"
+"lillehammer.no\0"
+"info.co\0"
+"achi.nagano.jp\0"
+"karasjok.no\0pa.gov.pl\0"
+"lib.mn.us\0"
+"osteroy.no\0"
+"naganohara.gunma.jp\0"
+"web.pk\0dp.ua\0"
+"edu.vc\0"
+"minato.osaka.jp\0"
+"rotorcraft.aero\0uchihara.ibaraki.jp\0edu.ve\0"
+"nom.pa\0"
+"edu.uy\0"
+"nom.pe\0ternopil.ua\0"
+"h\xc3\xa6gebostad.no\0tv.tz\0"
+"iwade.wakayama.jp\0"
+"bn.it\0oyama.tochigi.jp\0edu.vn\0"
+"yukuhashi.fukuoka.jp\0"
+"rel.ht\0biei.hokkaido.jp\0cinema.museum\0yuzhno-sakhalinsk.ru\0"
"nom.pl\0"
-"community.museum\0kvitsoy.no\0"
-"int.lk\0tychy.pl\0"
-"k12.me.us\0"
-"jondal.no\0edu.vc\0"
-"illustration.museum\0"
-"clinton.museum\0"
-"tas.au\0es.kr\0"
-"production.aero\0"
-"rodoy.no\0"
-"database.museum\0bodo.no\0"
-"anthro.museum\0landes.museum\0edu.vn\0"
-"nom.re\0"
-"altai.ru\0"
-"filatelia.museum\0"
-"sk.ca\0lezajsk.pl\0"
-"rockart.museum\0int.mv\0"
-"int.mw\0herad.no\0"
-"eti.br\0ac.gn\0"
-"fedje.no\0nom.ro\0"
-"money.museum\0"
-"\xd9\x85\xd8\xb5\xd8\xb1\0"
-"horten.no\0"
-"gangaviika.no\0mielec.pl\0"
-"uw.gov.pl\0"
-"moma.museum\0"
-"edu.ws\0"
-"go.ci\0"
-"tv.bo\0technology.museum\0"
-"s\xc3\xb8ndre-land.no\0"
-"tv.br\0"
-"jor.br\0lib.dc.us\0"
-"arboretum.museum\0"
-"go.cr\0"
-"artsandcrafts.museum\0\xd8\xaa\xd9\x88\xd9\x86\xd8\xb3\0"
-"psc.br\0ac.id\0!city.chiba.jp\0"
-"wa.au\0"
-"rome.it\0"
-"amli.no\0"
-"ac.im\0lo.it\0"
-"ac.in\0"
-"\xe7\xb6\xb2\xe7\xb5\xa1.hk\0durham.museum\0"
-"ac.ir\0"
-"torino.museum\0"
-"loabat.no\0"
-"com\0"
-"nalchik.ru\0"
-"yakutia.ru\0"
-"settlers.museum\0"
-"!promocion.ar\0int.pt\0"
-"union.aero\0"
-"utah.museum\0"
-"giehtavuoatna.no\0"
-"ac.jp\0"
-"air-traffic-control.aero\0"
-"silk.museum\0usantiques.museum\0"
-"bn.it\0"
-"kalisz.pl\0"
-"perm.ru\0"
-"aoste.it\0bindal.no\0"
-"coloradoplateau.museum\0k12.gu.us\0"
-"frosinone.it\0forde.no\0"
+"ichinomiya.chiba.jp\0s\xc3\xb8gne.no\0"
+"izumisano.osaka.jp\0"
+"rimini.it\0"
+"skjervoy.no\0"
+"anpachi.gifu.jp\0"
+"verdal.no\0sanok.pl\0"
+"matera.it\0"
+"nagatoro.saitama.jp\0edu.ws\0"
+"po.it\0"
+"takatori.nara.jp\0dyroy.no\0"
+"!mecon.ar\0"
+"walbrzych.pl\0"
+"yamashina.kyoto.jp\0sandoy.no\0is-a-geek.net\0"
+"kunisaki.oita.jp\0nom.re\0"
+"hazu.aichi.jp\0k12.mt.us\0k12.nd.us\0"
+"m.bg\0"
+"ulvik.no\0"
+"asahi.chiba.jp\0rankoshi.hokkaido.jp\0"
+"stockholm.museum\0troandin.no\0"
+"berlev\xc3\xa5g.no\0pomorze.pl\0pl.ua\0"
+"itoman.okinawa.jp\0"
+"kasuya.fukuoka.jp\0skjerv\xc3\xb8y.no\0"
+"okoppe.hokkaido.jp\0nom.ro\0"
+"caa.aero\0togane.chiba.jp\0"
+"polkowice.pl\0"
+"mosj\xc3\xb8""en.no\0"
+"web.tj\0"
+"iglesias-carbonia.it\0stj\xc3\xb8rdalshalsen.no\0"
+"ogori.fukuoka.jp\0"
+"north.museum\0lib.wy.us\0"
+"scrapper-site.net\0"
+"eu.com\0"
+"database.museum\0"
+"vaga.no\0"
+"birdart.museum\0"
+"gratangen.no\0"
+"kasukabe.saitama.jp\0"
+"dyndns-home.com\0"
+"seranishi.hiroshima.jp\0asker.no\0nom.tm\0"
+"le.it\0brussels.museum\0"
+"is-a-hunter.com\0"
+"babia-gora.pl\0ustka.pl\0"
+"travel\0"
+"chijiwa.nagasaki.jp\0web.ve\0"
+"gaivuotna.no\0kr.ua\0"
+"\xe5\x85\xac\xe5\x8f\xb8.cn\0"
+"yamada.iwate.jp\0evje-og-hornnes.no\0"
+,
+
+"kamijima.ehime.jp\0malbork.pl\0"
+"otsu.shiga.jp\0kosuge.yamanashi.jp\0"
+"kakuda.miyagi.jp\0"
+"est-a-la-masion.com\0"
+"\xe5\x85\xac\xe5\x8f\xb8.hk\0"
+"chigasaki.kanagawa.jp\0writesthisblog.com\0"
+"szkola.pl\0k12.wa.us\0"
+"ookuwa.nagano.jp\0lib.sc.us\0"
+"info\0ujitawara.kyoto.jp\0"
+"tranibarlettaandria.it\0"
+"aviation.museum\0"
+"nm.cn\0"
+"antiques.museum\0ddr.museum\0l\xc3\xb8""dingen.no\0"
+"shibata.miyagi.jp\0priv.pl\0"
+"bauern.museum\0"
+"cc.ct.us\0"
+"tokigawa.saitama.jp\0"
+"pruszkow.pl\0"
+"belluno.it\0chonan.chiba.jp\0"
+"from-ks.com\0"
+"kannami.shizuoka.jp\0"
+"tatebayashi.gunma.jp\0"
+"rel.pl\0k12.tn.us\0lib.al.us\0"
+"oshima.tokyo.jp\0"
+"cbg.ru\0"
"epilepsy.museum\0"
-"olbia-tempio.it\0"
-"journalist.aero\0ac.kr\0*.sch.uk\0"
-"nic.im\0sciencesnaturelles.museum\0bedzin.pl\0"
-"nic.in\0pe.it\0"
-"w.se\0"
-"!pref.okayama.jp\0"
-"urn.arpa\0"
-"cinema.museum\0"
-"monza.it\0versailles.museum\0int.ru\0"
-"andasuolo.no\0skj\xc3\xa5k.no\0chernovtsy.ua\0"
-"nyc.museum\0int.rw\0paroch.k12.ma.us\0"
-"ringerike.no\0"
-"ac.ma\0"
-"org.ac\0civilaviation.aero\0"
-"rakkestad.no\0"
-"org.ae\0ac.me\0"
-"org.af\0"
-"org.ag\0"
-"org.ai\0stokke.no\0"
-"airport.aero\0"
-"finnoy.no\0"
-"org.al\0"
-"org.an\0y.bg\0habmer.no\0"
-"stadt.museum\0holtalen.no\0"
-"int.tj\0"
-"org.ba\0gjerdrum.no\0"
-"org.bb\0ascoli-piceno.it\0molde.no\0r\xc3\xb8st.no\0tysfjord.no\0"
-"pe.kr\0rybnik.pl\0"
-"go.id\0"
-"ac.mu\0"
-"ac.mw\0ac.ng\0"
-"org.bh\0\xc3\xa5mot.no\0rana.no\0"
-"org.bi\0"
-"org.az\0belgorod.ru\0int.tt\0"
-"ae.org\0"
-"group.aero\0posts-and-telecommunications.museum\0"
-"org.bm\0salerno.it\0"
-"etnedal.no\0"
-"org.bo\0*.hokkaido.jp\0donetsk.ua\0"
-"ostroda.pl\0"
-"org.br\0"
-"org.bs\0"
-"go.it\0h\xc3\xb8ylandet.no\0"
-"zgorzelec.pl\0"
-"org.bw\0"
-"org.ci\0"
-"org.bz\0vicenza.it\0resistance.museum\0"
-"missile.museum\0"
-"org.cn\0"
-"org.co\0assassination.museum\0"
-"go.jp\0"
-"tv.it\0austrheim.no\0ac.pa\0"
-"verbania.it\0"
-"palace.museum\0"
-"tmp.br\0int.vn\0"
-"org.cu\0"
-"paris.museum\0"
-"media.aero\0hokksund.no\0"
-"arts.museum\0gemological.museum\0hammerfest.no\0"
-"k12.ny.us\0"
-"org.dm\0hemsedal.no\0ringsaker.no\0sklep.pl\0"
-"h\xc3\xa5.no\0cc.nj.us\0"
-"rzeszow.pl\0"
-"go.kr\0gjesdal.no\0ac.pr\0"
-"org.ec\0"
-"org.ee\0"
-"media.museum\0"
-"terni.it\0touch.museum\0zakopane.pl\0"
-"journal.aero\0org.dz\0"
-"incheon.kr\0"
-"b\xc3\xa1hcavuotna.no\0"
-"leksvik.no\0ulvik.no\0"
+"spy.museum\0"
+"!city.sapporo.jp\0kanie.aichi.jp\0"
+"mulhouse.museum\0"
+"taki.mie.jp\0gangaviika.no\0"
+"v\xc3\xa5ler.\xc3\xb8stfold.no\0gok.pk\0!jet.uk\0"
+"\xd8\xa7\xd9\x8a\xd8\xb1\xd8\xa7\xd9\x86.ir\0sagae.yamagata.jp\0austin.museum\0"
+"manno.kagawa.jp\0lillesand.no\0"
+"kitaakita.akita.jp\0"
+"priv.no\0"
+"campidano-medio.it\0"
+"lapy.pl\0lezajsk.pl\0"
+"info.ve\0"
+"shakotan.hokkaido.jp\0"
+"takahama.fukui.jp\0kiryu.gunma.jp\0arna.no\0sunndal.no\0"
+"nagai.yamagata.jp\0"
+"tomsk.ru\0"
+"info.vn\0"
+"agriculture.museum\0"
+"jeonbuk.kr\0"
+"realestate.pl\0from-md.com\0"
+"ca.it\0"
"plantation.museum\0"
-"org.es\0loyalist.museum\0"
-"gildesk\xc3\xa5l.no\0bytom.pl\0"
-"bo.nordland.no\0"
-"ambulance.aero\0iglesiascarbonia.it\0"
-"tw.cn\0\xe6\x96\xb0\xe5\x8a\xa0\xe5\x9d\xa1\0"
-"chocolate.museum\0"
-"pittsburgh.museum\0"
-"royrvik.no\0sor-odal.no\0ac.rs\0"
-"kaluga.ru\0"
-"org.ge\0erotica.hu\0ac.ru\0ac.se\0"
-"org.gg\0leangaviika.no\0ac.rw\0"
-"org.gh\0v\xc3\xa6r\xc3\xb8y.no\0"
-"org.gi\0"
-"jevnaker.no\0"
-"org.gn\0tv.na\0leikanger.no\0"
-"org.gp\0"
-"ask\xc3\xb8y.no\0"
-"org.gr\0wroc.pl\0"
-"ad.jp\0"
-"powiat.pl\0"
-"tj\xc3\xb8me.no\0"
-"coop.tt\0"
-"ac.th\0"
-"mragowo.pl\0ac.sz\0ac.tj\0"
-"org.hk\0bo.it\0"
-"philately.museum\0"
-"org.hn\0"
-"fet.no\0"
-"axis.museum\0mansions.museum\0"
-"wiki.br\0"
-"org.ht\0"
-"org.hu\0piacenza.it\0scotland.museum\0cpa.pro\0"
-"ac.ug\0"
-"coop.mv\0x.se\0"
-"coop.mw\0ac.tz\0"
-"bmd.br\0"
-"org.im\0ralingen.no\0"
-"org.in\0"
-"cz.it\0lib.ia.us\0"
-"org.iq\0"
-"org.ir\0"
-"org.is\0"
-"nl.ca\0"
-"org.je\0"
-"childrensgarden.museum\0"
-"kvits\xc3\xb8y.no\0go.pw\0"
-"sokndal.no\0"
-"ra.it\0grimstad.no\0"
-"denmark.museum\0"
-"ac.vn\0"
-"ecn.br\0org.jo\0"
-"bialystok.pl\0nj.us\0"
-"z.bg\0bilbao.museum\0stargard.pl\0nic.tj\0"
-"eisenbahn.museum\0"
-"fe.it\0bryne.no\0vrn.ru\0"
-"cc.wa.us\0"
-"sex.hu\0skierva.no\0"
-"org.kg\0"
-"org.ki\0"
-"org.km\0"
-"org.kn\0khakassia.ru\0"
-"org.kp\0"
-"org.la\0"
-"org.lb\0"
-"org.lc\0"
-"francaise.museum\0"
-"panama.museum\0"
-"rotorcraft.aero\0gateway.museum\0olkusz.pl\0"
-"org.ky\0czeladz.pl\0ryazan.ru\0"
-"org.kz\0"
-"org.lk\0dyr\xc3\xb8y.no\0"
-"raisa.no\0"
-"dlugoleka.pl\0"
-"org.ma\0"
-"org.lr\0prochowice.pl\0"
-"org.ls\0"
-"org.me\0sandoy.no\0s\xc3\xb8r-varanger.no\0"
-"org.lv\0"
-"org.mg\0"
-"tel\0go.th\0"
-"org.ly\0"
-"steam.museum\0go.tj\0"
-"org.mk\0pasadena.museum\0jessheim.no\0lib.mn.us\0"
-"org.ml\0"
-"software.aero\0"
-"org.mn\0"
-"org.mo\0"
-"*.fukui.jp\0decorativearts.museum\0"
-"spy.museum\0org.na\0jorpeland.no\0"
-"vads\xc3\xb8.no\0"
-"org.mu\0building.museum\0gausdal.no\0"
-"org.mv\0nannestad.no\0"
-"org.mw\0org.ng\0go.ug\0"
-"vr.it\0org.mx\0"
-"org.my\0"
-"go.tz\0"
-"oppdal.no\0"
-"uk.net\0"
-"coop.km\0"
-"*.kyoto.jp\0"
-"sarpsborg.no\0org.nr\0"
-"chernigov.ua\0"
-"ha.cn\0no.com\0"
-"space.museum\0"
-"org.pa\0"
-"*.ar\0"
-"usgarden.museum\0"
-"*.bd\0org.pe\0"
-"*.au\0org.pf\0um.gov.pl\0"
-"bio.br\0"
-"org.ph\0"
-"org.pk\0"
-"fr\xc3\xa6na.no\0org.pl\0"
-"nord-aurdal.no\0org.pn\0"
-"*.bn\0handson.museum\0agrinet.tn\0"
-"kviteseid.no\0"
-"rel.ht\0virtuel.museum\0atm.pl\0org.pr\0"
-"org.ps\0cherkassy.ua\0"
-"org.pt\0wa.us\0"
-"*.bt\0arendal.no\0magnitka.ru\0"
-"depot.museum\0porsangu.no\0"
-"laakesvuemie.no\0"
-"sor-fron.no\0"
-"heroy.more-og-romsdal.no\0"
-"*.ck\0"
-"!rakpetroleum.om\0"
-"kr\xc3\xb8""dsherad.no\0mail.pl\0"
-"mod.gi\0"
-"gs.nl.no\0"
-"mb.ca\0"
"pavia.it\0"
-"civilisation.museum\0folldal.no\0"
-"suli.hu\0"
-"brumunddal.no\0"
-"*.cy\0"
-"pg.it\0troms\xc3\xb8.no\0"
-"sex.pl\0y.se\0"
-"org.ro\0"
-"*.do\0"
-"caserta.it\0org.sa\0"
-"za.com\0halloffame.museum\0org.sb\0lviv.ua\0"
-"mill.museum\0org.rs\0org.sc\0"
-"org.sd\0"
-"idv.hk\0!omanmobile.om\0org.ru\0org.se\0"
-"langev\xc3\xa5g.no\0r\xc3\xa5holt.no\0starostwo.gov.pl\0"
-"trani-andria-barletta.it\0org.sg\0"
-"*.eg\0hvaler.no\0"
-"*.ehime.jp\0"
-"gmina.pl\0"
-"bod\xc3\xb8.no\0org.sl\0"
-"edu\0org.sn\0"
-"org.so\0lib.wi.us\0"
-"kommune.no\0"
-"nome.pt\0"
-"*.er\0namdalseid.no\0k12.wa.us\0"
-"nm.cn\0org.st\0"
-"*.et\0d\xc3\xb8nna.no\0"
-"jewish.museum\0preservation.museum\0"
-"slupsk.pl\0org.sy\0"
-"art.br\0org.sz\0org.tj\0"
-"ntr.br\0*.fj\0ski.no\0"
-"*.fk\0rimini.it\0grajewo.pl\0"
-"loppa.no\0"
-"franziskaner.museum\0notteroy.no\0org.tn\0"
-"org.to\0"
-"nesoddtangen.no\0"
-"org.ua\0"
-"discovery.museum\0wloclawek.pl\0"
-"lakas.hu\0org.tt\0"
-"kurgan.ru\0"
-"baltimore.museum\0nkz.ru\0org.tw\0"
-"com.ac\0castle.museum\0"
-"*.fukuoka.jp\0sandefjord.no\0varggat.no\0"
-"com.af\0"
-"com.ag\0"
-"ato.br\0k12.nj.us\0"
-"com.ai\0"
-"city.hu\0oryol.ru\0"
-"com.al\0nl.no\0mielno.pl\0cc.ma.us\0"
-"org.vc\0"
-"com.an\0g12.br\0"
-"*.gt\0"
-"*.gu\0"
-"com.ba\0"
-"com.bb\0americanart.museum\0"
-"org.vi\0"
-"kunstsammlung.museum\0"
-"com.aw\0"
-"flight.aero\0com.bh\0lib.mo.us\0org.vn\0"
-"com.bi\0adygeya.ru\0"
-"com.az\0"
-"art.dz\0"
-"com.bm\0"
+"jeonnam.kr\0"
+"jogasz.hu\0klodzko.pl\0kostroma.ru\0"
+"ltd.co.im\0"
+"koshigaya.saitama.jp\0dyndns-remote.com\0"
+"coop\0arts.ro\0"
+"hyogo.jp\0priv.me\0"
+"stalbans.museum\0"
+"pr.it\0test.tj\0"
+"info.tn\0"
+"kouzushima.tokyo.jp\0pacific.museum\0"
+"gs.tm.no\0"
+"sd.us\0k12.ne.us\0"
+"p.bg\0"
+"info.tt\0"
+"khmelnitskiy.ua\0"
+"decorativearts.museum\0alesund.no\0"
+"ginowan.okinawa.jp\0info.tz\0"
+"mining.museum\0"
+"\xc3\xb8vre-eiker.no\0"
+"gonohe.aomori.jp\0"
+"aurskog-holand.no\0"
+"kagamiishi.fukushima.jp\0m\xc3\xa1latvuopmi.no\0"
+"podlasie.pl\0"
+"malselv.no\0"
+"odawara.kanagawa.jp\0"
+"rygge.no\0"
+"arida.wakayama.jp\0"
+"dni.us\0"
+"info.ro\0codespot.com\0"
+"ca.na\0kv\xc3\xa6nangen.no\0"
+"ome.tokyo.jp\0"
+"atsugi.kanagawa.jp\0"
+"info.sd\0"
+"egyptian.museum\0cc.ia.us\0"
+"suzaka.nagano.jp\0test.ru\0"
+"kumejima.okinawa.jp\0\xe0\xa8\xad\xe0\xa8\xbe\xe0\xa8\xb0\xe0\xa8\xa4\0groks-this.info\0"
+"public.museum\0\xe0\xb0\xad\xe0\xb0\xbe\xe0\xb0\xb0\xe0\xb0\xa4\xe0\xb1\x8d\0"
+"ono.hyogo.jp\0"
+"arts.nf\0"
+"iwama.ibaraki.jp\0kamimine.saga.jp\0"
+"nj.us\0"
+"mantova.it\0"
+"padova.it\0"
+"samnanger.no\0"
+"yuki.ibaraki.jp\0higashitsuno.kochi.jp\0sciencesnaturelles.museum\0"
+"miho.ibaraki.jp\0"
+"hemnes.no\0"
+"yosemite.museum\0"
+"tochio.niigata.jp\0whaling.museum\0is-an-accountant.com\0"
+"info.pk\0"
+"soja.okayama.jp\0voagat.no\0info.pl\0cc.fl.us\0"
+"sekikawa.niigata.jp\0"
+"is.it\0photography.museum\0"
+"info.pr\0"
+"aizubange.fukushima.jp\0jinsekikogen.hiroshima.jp\0rissa.no\0"
+"napoli.it\0glas.museum\0"
+"\xe7\xb5\x84\xe7\xb9\x94.hk\0rns.tn\0"
+"k12.wv.us\0is-a-candidate.org\0"
+"ushiku.ibaraki.jp\0"
+"production.aero\0"
+"fukagawa.hokkaido.jp\0philately.museum\0"
+"miyake.nara.jp\0"
+"akune.kagoshima.jp\0"
+"info.na\0"
+"fujikawaguchiko.yamanashi.jp\0from-il.com\0"
+"ozu.kumamoto.jp\0"
+"exchange.aero\0gmina.pl\0"
+"info.mv\0info.nf\0"
+"kosai.shizuoka.jp\0steigen.no\0homeip.net\0"
+"chuo.chiba.jp\0"
+"tambov.ru\0"
+"j\xc3\xb8lster.no\0"
+"omi.niigata.jp\0"
+"mil\0lib.ak.us\0"
+"muika.niigata.jp\0info.nr\0"
+"berlevag.no\0"
+"indiana.museum\0"
+"jewish.museum\0"
"dr\xc3\xb8""bak.no\0"
-"com.bo\0isla.pr\0"
-"com.br\0"
-"com.bs\0ustka.pl\0kuban.ru\0"
-"press.aero\0"
-"vs.it\0"
-"meloy.no\0"
-"*.il\0ulm.museum\0"
-"com.by\0com.ci\0genoa.it\0"
-"com.bz\0sn.cn\0"
-"lib.or.us\0"
-"santafe.museum\0org.ws\0"
+"government.aero\0"
+"ltd.gi\0"
+"cc.ar.us\0"
+"gon.pk\0"
+"marumori.miyagi.jp\0"
+"gateway.museum\0"
+"fujimino.saitama.jp\0m.se\0"
+"takanezawa.tochigi.jp\0vads\xc3\xb8.no\0dontexist.org\0"
+"info.la\0belau.pw\0"
+"ibaraki.ibaraki.jp\0po.gov.pl\0"
+"even\xc3\xa1\xc5\xa1\xc5\xa1i.no\0loab\xc3\xa1t.no\0"
+"coal.museum\0"
+"karikatur.museum\0"
+"miyazaki.miyazaki.jp\0ketrzyn.pl\0k12.sd.us\0"
+"fukuyama.hiroshima.jp\0lib.oh.us\0"
+"hamaroy.no\0"
+"nishinoshima.shimane.jp\0samara.ru\0"
+"ikeda.fukui.jp\0"
+"mel\xc3\xb8y.no\0chukotka.ru\0"
+"port.fr\0"
+"us.org\0"
+"kumagaya.saitama.jp\0"
+"*.sapporo.jp\0"
+"westfalen.museum\0"
+"yahiko.niigata.jp\0"
+"ichinomiya.aichi.jp\0naruto.tokushima.jp\0"
+"tmp.br\0bt.it\0"
+"donna.no\0khabarovsk.ru\0"
+"saikai.nagasaki.jp\0"
+"ato.br\0sex.hu\0daigo.ibaraki.jp\0"
+"izumiotsu.osaka.jp\0"
+"\xd8\xa7\xd9\x84\xd9\x85\xd8\xba\xd8\xb1\xd8\xa8\0"
+"davvesiida.no\0"
+"gyeonggi.kr\0"
+"coloradoplateau.museum\0olecko.pl\0"
+"ha.cn\0"
+"forlicesena.it\0"
+"taka.hyogo.jp\0kita.kyoto.jp\0"
+"cc.mn.us\0"
+"mutsu.aomori.jp\0"
+"shimotsuma.ibaraki.jp\0rybnik.pl\0"
+"\xd8\xb3\xd9\x88\xd8\xb1\xd9\x8a\xd8\xa7\0"
+"livorno.it\0pu.it\0verona.it\0"
+"\xd8\xb3\xd9\x88\xd8\xb1\xd9\x8a\xd8\xa9\0"
+"sveio.no\0"
+"kurate.fukuoka.jp\0"
+"natuurwetenschappen.museum\0"
+"ca.us\0"
+"bryansk.ru\0"
+"s.bg\0seoul.kr\0"
+"watarai.mie.jp\0muenchen.museum\0"
+"iyo.ehime.jp\0"
+"starnberg.museum\0tydal.no\0"
+"info.ki\0"
+"fet.no\0finn\xc3\xb8y.no\0"
+"kagoshima.kagoshima.jp\0"
+"naturalsciences.museum\0"
+"artsandcrafts.museum\0"
+"sakurai.nara.jp\0"
+"carrara-massa.it\0"
+"shirakawa.fukushima.jp\0"
+"mitsuke.niigata.jp\0museet.museum\0is-a-photographer.com\0"
+"shioya.tochigi.jp\0"
+"randaberg.no\0"
+"ojiya.niigata.jp\0"
+"ltd.lk\0pr.us\0k12.ks.us\0"
+"osaka.jp\0lib.hi.us\0"
+"horonobe.hokkaido.jp\0"
+"kragero.no\0"
+"kawaguchi.saitama.jp\0"
+"hara.nagano.jp\0itabashi.tokyo.jp\0"
+"fl\xc3\xa5.no\0"
+"otsuki.kochi.jp\0leangaviika.no\0pors\xc3\xa1\xc5\x8bgu.no\0"
+"savannahga.museum\0"
+"volkenkunde.museum\0"
+"cc.id.us\0"
+"kashima.kumamoto.jp\0swinoujscie.pl\0"
+"prof.pr\0"
+"ab.ca\0is-a-democrat.com\0"
+"press.museum\0"
+"uk.com\0"
+"bajddar.no\0"
+"medecin.km\0"
+"iki.nagasaki.jp\0shirahama.wakayama.jp\0"
+"ip6.arpa\0nm.us\0"
+"lib.fl.us\0"
+"yanagawa.fukuoka.jp\0donetsk.ua\0"
+"s\xc3\xb8r-aurdal.no\0"
+"qh.cn\0mill.museum\0"
+"naka.ibaraki.jp\0"
+"kamitonda.wakayama.jp\0"
+"mosreg.ru\0"
+"gorizia.it\0kushima.miyazaki.jp\0berlin.museum\0"
+"ns.ca\0shiga.jp\0"
+"cheltenham.museum\0"
+"kawachinagano.osaka.jp\0fujieda.shizuoka.jp\0nakhodka.ru\0k12.ga.us\0"
+"magnitka.ru\0"
+"uki.kumamoto.jp\0wroc.pl\0"
+"stange.no\0stuff-4-sale.org\0"
+"tsuruga.fukui.jp\0nagasu.kumamoto.jp\0"
+"biella.it\0buyshouses.net\0is-a-guru.com\0"
+"vevelstad.no\0"
+"nyuzen.toyama.jp\0"
+"bjugn.no\0"
+"motosu.gifu.jp\0"
+"usdecorativearts.museum\0"
+"anthro.museum\0"
+"sex.pl\0"
+"americanantiques.museum\0rennes\xc3\xb8y.no\0"
+"arezzo.it\0hakuba.nagano.jp\0"
+"jamison.museum\0is-a-painter.com\0mypets.ws\0"
+"ln.cn\0"
+"hiji.oita.jp\0"
+"air.museum\0"
+"palana.ru\0"
+"toki.gifu.jp\0sakata.yamagata.jp\0p.se\0"
+"vb.it\0funahashi.toyama.jp\0"
+"hino.tottori.jp\0"
+"logistics.aero\0ohda.shimane.jp\0"
+"amli.no\0"
+"yatsuka.shimane.jp\0"
+"chichibu.saitama.jp\0"
+"sciences.museum\0"
+"wa.edu.au\0"
+"ouchi.saga.jp\0"
+"pittsburgh.museum\0gloppen.no\0"
+"kamigori.hyogo.jp\0"
+"valer.ostfold.no\0is-a-soxfan.org\0"
+"net\0halden.no\0dyndns-work.com\0"
+"oita.jp\0hinode.tokyo.jp\0sa.com\0"
+"leikanger.no\0"
+"stord.no\0"
+"sarufutsu.hokkaido.jp\0alstahaug.no\0k12.al.us\0"
+"shinanomachi.nagano.jp\0edogawa.tokyo.jp\0k12.pr.us\0"
+"hakodate.hokkaido.jp\0"
+"tobishima.aichi.jp\0"
+"ogasawara.tokyo.jp\0stjordal.no\0"
+"aarborte.no\0"
+"xj.cn\0"
+"kyotanabe.kyoto.jp\0"
+"williamsburg.museum\0"
+"nabari.mie.jp\0namerikawa.toyama.jp\0rana.no\0"
+"gwangju.kr\0"
+"agdenes.no\0"
+"hitachiota.ibaraki.jp\0ha.no\0tynset.no\0"
+"k12.ok.us\0"
+"v.bg\0eco.br\0algard.no\0"
+"khmelnytskyi.ua\0"
+"nagano.jp\0"
+"jus.br\0"
+"tanohata.iwate.jp\0"
+"hakusan.ishikawa.jp\0"
+"detroit.museum\0"
+"szex.hu\0"
+"asahikawa.hokkaido.jp\0nov.ru\0"
+"fhsk.se\0"
+"voronezh.ru\0"
+"date.fukushima.jp\0"
+"textile.museum\0"
+"toyosato.shiga.jp\0"
+"mytis.ru\0"
+"valley.museum\0"
+"mazury.pl\0"
+"imari.saga.jp\0"
+"insurance.aero\0tomiya.miyagi.jp\0"
+"siena.it\0"
+"novara.it\0"
+"ichihara.chiba.jp\0"
+"tochigi.jp\0"
+"b\xc3\xa5tsfjord.no\0doesntexist.org\0"
+"is-a-personaltrainer.com\0"
+"uryu.hokkaido.jp\0interactive.museum\0"
+"!songfest.om\0"
+"mihara.hiroshima.jp\0"
+"field.museum\0adygeya.ru\0"
+"yasuda.kochi.jp\0"
+"yokote.akita.jp\0dyndns-mail.com\0"
+"salzburg.museum\0"
+"is-very-bad.org\0worse-than.tv\0"
+"sn\xc3\xa5""ase.no\0"
+"indian.museum\0"
+"anan.nagano.jp\0vagan.no\0"
+"baghdad.museum\0"
+"k\xc3\xa1r\xc3\xa1\xc5\xa1johka.no\0"
+"simple-url.com\0"
+"of.by\0"
+"shiogama.miyagi.jp\0"
+"huissier-justice.fr\0"
+"shika.ishikawa.jp\0"
+"from-fl.com\0"
+"drammen.no\0fam.pk\0"
+"contemporaryart.museum\0"
+"bio.br\0handa.aichi.jp\0ikeda.nagano.jp\0is-saved.org\0"
+"inzai.chiba.jp\0soka.saitama.jp\0"
+"s\xc3\xb8rfold.no\0sellsyourhome.org\0"
+"louvre.museum\0"
+"yanaizu.fukushima.jp\0"
+"kiyosu.aichi.jp\0"
+"ichikawa.chiba.jp\0kawanishi.hyogo.jp\0sakawa.kochi.jp\0"
+"konyvelo.hu\0lindesnes.no\0"
+"!promocion.ar\0lom.no\0"
+"k12.ec\0"
+"tree.museum\0"
+"s.se\0"
+"ve.it\0juif.museum\0flatanger.no\0"
+"kobierzyce.pl\0"
+"chino.nagano.jp\0"
+"kristiansand.no\0norddal.no\0"
+"b\xc3\xb8.nordland.no\0"
+"kirov.ru\0"
+"tomobe.ibaraki.jp\0"
+"jl.cn\0frosinone.it\0"
+"toyooka.hyogo.jp\0"
+"tsuiki.fukuoka.jp\0hitra.no\0"
+"bz.it\0yotsukaido.chiba.jp\0"
+"sp.it\0"
+"ariake.saga.jp\0scrapping.cc\0"
+"iwanai.hokkaido.jp\0"
+"erotica.hu\0sumoto.kumamoto.jp\0glogow.pl\0"
+"lib.mi.us\0"
+"tateyama.chiba.jp\0semine.miyagi.jp\0vestre-toten.no\0"
+"dellogliastra.it\0sm.ua\0"
+"brussel.museum\0"
+"hasami.nagasaki.jp\0sells-for-u.com\0"
+"anan.tokushima.jp\0"
+"barreau.bj\0"
+"cc.mt.us\0cc.nd.us\0"
+"l\xc3\xb8renskog.no\0"
+"trolley.museum\0"
+"okuma.fukushima.jp\0"
+"hirara.okinawa.jp\0kaminoyama.yamagata.jp\0k12.oh.us\0"
+"y.bg\0"
+"miyazaki.jp\0"
+"repbody.aero\0"
+"sannohe.aomori.jp\0shimizu.hokkaido.jp\0"
+"judygarland.museum\0gotdns.com\0"
+"toyota.aichi.jp\0oketo.hokkaido.jp\0zao.miyagi.jp\0"
+"ohtawara.tochigi.jp\0"
+"workinggroup.aero\0"
+"matsukawa.nagano.jp\0"
+"mugi.tokushima.jp\0karate.museum\0"
+"bjerkreim.no\0"
+"miyagi.jp\0"
+"!city.kobe.jp\0aquarium.museum\0"
+"k12.la.us\0"
+"pharmaciens.km\0de.com\0"
+"!omantel.om\0"
+"zhytomyr.ua\0"
+"kawara.fukuoka.jp\0raholt.no\0"
+"medecin.fr\0saiki.oita.jp\0v\xc3\xa1rgg\xc3\xa1t.no\0"
+"kotoura.tottori.jp\0moskenes.no\0vennesla.no\0"
+"rishirifuji.hokkaido.jp\0"
+"cuneo.it\0"
+"takamatsu.kagawa.jp\0malatvuopmi.no\0pomorskie.pl\0"
+"otsuchi.iwate.jp\0"
+"spb.ru\0"
+"recreation.aero\0misaki.okayama.jp\0k12.in.us\0ham-radio-op.net\0"
+"freiburg.museum\0"
+"journal.aero\0fot.br\0"
+"asahi.yamagata.jp\0"
+"ah.cn\0saotome.st\0"
+"delaware.museum\0"
+"tondabayashi.osaka.jp\0"
+"!uba.ar\0notaires.km\0"
+"nord-aurdal.no\0"
+"furubira.hokkaido.jp\0kazan.ru\0"
+"shisui.chiba.jp\0town.museum\0"
+"inatsuki.fukuoka.jp\0yuu.yamaguchi.jp\0"
+"munakata.fukuoka.jp\0"
+"matsuyama.ehime.jp\0"
+"traniandriabarletta.it\0toyama.toyama.jp\0grandrapids.museum\0lenvik.no\0"
+"toyota.yamaguchi.jp\0"
+"niigata.jp\0yamatsuri.fukushima.jp\0batsfjord.no\0"
+"ravenna.it\0zama.kanagawa.jp\0"
+"is-a-landscaper.com\0is-gone.com\0"
+"doomdns.org\0"
+"shinjo.yamagata.jp\0hawaii.museum\0"
+"trento.it\0taiki.mie.jp\0"
+"royrvik.no\0"
+"palermo.it\0"
+"arts.museum\0newjersey.museum\0"
+"scienceandhistory.museum\0"
+"sunagawa.hokkaido.jp\0tabuse.yamaguchi.jp\0chuo.yamanashi.jp\0"
+"*.sch.uk\0"
+"southwest.museum\0of.no\0k12.fl.us\0"
+"md.ci\0"
+"haboro.hokkaido.jp\0iwanuma.miyagi.jp\0adachi.tokyo.jp\0"
+"harstad.no\0"
+"kunneppu.hokkaido.jp\0"
+"tachikawa.tokyo.jp\0"
+"agrigento.it\0murata.miyagi.jp\0"
+"macerata.it\0b\xc3\xa1id\xc3\xa1r.no\0"
+"kurogi.fukuoka.jp\0"
+"misato.miyagi.jp\0americanart.museum\0"
+"sanagochi.tokushima.jp\0"
+"nanyo.yamagata.jp\0"
+"otaru.hokkaido.jp\0"
+"bremanger.no\0nordkapp.no\0"
+"kawagoe.saitama.jp\0"
+"sodegaura.chiba.jp\0creation.museum\0romskog.no\0"
+"hiratsuka.kanagawa.jp\0"
+"muroto.kochi.jp\0"
+"miki.hyogo.jp\0"
+"g\xc3\xa1ls\xc3\xa1.no\0isa-geek.org\0"
+"eastcoast.museum\0shell.museum\0"
+"salerno.it\0shinyoshitomi.fukuoka.jp\0is-a-libertarian.com\0"
+"ss.it\0"
+"fuefuki.yamanashi.jp\0"
+"voss.no\0dnepropetrovsk.ua\0"
+"lib.md.us\0"
+"ggf.br\0"
+"nara.nara.jp\0"
+"gz.cn\0kakamigahara.gifu.jp\0!teledata.mz\0"
+"!gobiernoelectronico.ar\0katano.osaka.jp\0"
+"jp.net\0"
+"ethnology.museum\0"
+"krym.ua\0"
+"e164.arpa\0fie.ee\0"
+"preservation.museum\0"
+"como.it\0ina.saitama.jp\0"
+"tempio-olbia.it\0kokubunji.tokyo.jp\0"
+"k12.ny.us\0"
+"\xc3\xa5""fjord.no\0"
+"kamo.kyoto.jp\0is-very-sweet.org\0"
+"kuroiso.tochigi.jp\0"
+"nagaoka.niigata.jp\0"
+"kl\xc3\xa6""bu.no\0"
+"vossevangen.no\0"
+"casino.hu\0"
+"stuttgart.museum\0"
+"tamamura.gunma.jp\0"
+"malopolska.pl\0"
+"is-a-student.com\0"
+"naka.hiroshima.jp\0higashichichibu.saitama.jp\0"
+"mykolaiv.ua\0!mod.uk\0"
+"lt.it\0"
+"honjo.saitama.jp\0"
+"manchester.museum\0bedzin.pl\0"
+"sandiego.museum\0"
+"sakuho.nagano.jp\0"
+"nv.us\0is-a-liberal.com\0"
+"2.bg\0nature.museum\0"
+"za.net\0"
+"!city.nagoya.jp\0ris\xc3\xb8r.no\0"
+"sanda.hyogo.jp\0"
+"satsumasendai.kagoshima.jp\0kizu.kyoto.jp\0is-a-cubicle-slave.com\0"
+"yamagata.yamagata.jp\0"
+"\xd8\xa7\xd9\x85\xd8\xa7\xd8\xb1\xd8\xa7\xd8\xaa\0"
+"k12.vi\0"
+"svalbard.no\0"
+"koganei.tokyo.jp\0"
+"cci.fr\0inami.toyama.jp\0"
+"misconfused.org\0"
+"int.az\0"
};
+static const quint16 tldChunkCount = 2;
+static const quint32 tldChunks[] = {65521, 75539};
+
QT_END_NAMESPACE
#endif // QURLTLD_P_H
diff --git a/src/corelib/io/qwindowspipereader.cpp b/src/corelib/io/qwindowspipereader.cpp
index efadb357a9..2cb5845768 100644
--- a/src/corelib/io/qwindowspipereader.cpp
+++ b/src/corelib/io/qwindowspipereader.cpp
@@ -64,7 +64,7 @@ QWindowsPipeReader::QWindowsPipeReader(QObject *parent)
connect(dataReadNotifier, &QWinOverlappedIoNotifier::notified, this, &QWindowsPipeReader::notified);
}
-static void qt_cancelIo(HANDLE handle, OVERLAPPED *overlapped)
+static bool qt_cancelIo(HANDLE handle, OVERLAPPED *overlapped)
{
typedef BOOL (WINAPI *PtrCancelIoEx)(HANDLE, LPOVERLAPPED);
static PtrCancelIoEx ptrCancelIoEx = 0;
@@ -74,16 +74,18 @@ static void qt_cancelIo(HANDLE handle, OVERLAPPED *overlapped)
ptrCancelIoEx = PtrCancelIoEx(GetProcAddress(kernel32, "CancelIoEx"));
}
if (ptrCancelIoEx)
- ptrCancelIoEx(handle, overlapped);
+ return ptrCancelIoEx(handle, overlapped);
else
- CancelIo(handle);
+ return CancelIo(handle);
}
QWindowsPipeReader::~QWindowsPipeReader()
{
if (readSequenceStarted) {
- qt_cancelIo(handle, &overlapped);
- dataReadNotifier->waitForNotified(-1, &overlapped);
+ if (qt_cancelIo(handle, &overlapped))
+ dataReadNotifier->waitForNotified(-1, &overlapped);
+ else
+ qErrnoWarning("QWindowsPipeReader: qt_cancelIo on handle %x failed.", handle);
}
}
diff --git a/src/corelib/io/qwindowspipereader_p.h b/src/corelib/io/qwindowspipereader_p.h
index d29e77b034..ea3d3c271f 100644
--- a/src/corelib/io/qwindowspipereader_p.h
+++ b/src/corelib/io/qwindowspipereader_p.h
@@ -60,8 +60,6 @@
#include <qt_windows.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -117,6 +115,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWINDOWSPIPEREADER_P_H
diff --git a/src/corelib/io/qwindowspipewriter_p.h b/src/corelib/io/qwindowspipewriter_p.h
index fa2b386788..62cd49d66a 100644
--- a/src/corelib/io/qwindowspipewriter_p.h
+++ b/src/corelib/io/qwindowspipewriter_p.h
@@ -59,8 +59,6 @@
#include <qwaitcondition.h>
#include <qt_windows.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -156,6 +154,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_PROCESS
diff --git a/src/corelib/io/qwinoverlappedionotifier_p.h b/src/corelib/io/qwinoverlappedionotifier_p.h
index f117e31535..451bedf7cf 100644
--- a/src/corelib/io/qwinoverlappedionotifier_p.h
+++ b/src/corelib/io/qwinoverlappedionotifier_p.h
@@ -57,8 +57,6 @@
#include <qt_windows.h>
#include <qqueue.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QWinIoCompletionPort;
@@ -112,6 +110,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWINOVERLAPPEDIONOTIFIER_P_H
diff --git a/src/corelib/itemmodels/qabstractitemmodel.cpp b/src/corelib/itemmodels/qabstractitemmodel.cpp
index 12029f4a23..f152dec5e6 100644
--- a/src/corelib/itemmodels/qabstractitemmodel.cpp
+++ b/src/corelib/itemmodels/qabstractitemmodel.cpp
@@ -866,6 +866,27 @@ void QAbstractItemModelPrivate::columnsRemoved(const QModelIndex &parent,
}
/*!
+ \since 4.8
+
+ This slot is called just after the internal data of a model is cleared
+ while it is being reset.
+
+ This slot is provided the convenience of subclasses of concrete proxy
+ models, such as subclasses of QSortFilterProxyModel which maintain extra
+ data.
+
+ \snippet code/src_corelib_kernel_qabstractitemmodel.cpp 12
+
+ \note Due to a mistake, this slot is missing in Qt 5.0.
+
+ \sa modelAboutToBeReset(), modelReset()
+*/
+void QAbstractItemModel::resetInternalData()
+{
+
+}
+
+/*!
\class QModelIndex
\inmodule QtCore
@@ -1658,6 +1679,9 @@ bool QAbstractItemModel::hasIndex(int row, int column, const QModelIndex &parent
Use rowCount() on the parent to find out the number of children.
+ Note that it is undefined behavior to report that a particular index hasChildren
+ with this method if the same index has the flag Qt::ItemNeverHasChildren set.
+
\sa parent(), index()
*/
bool QAbstractItemModel::hasChildren(const QModelIndex &parent) const
@@ -2088,9 +2112,8 @@ void QAbstractItemModel::fetchMore(const QModelIndex &)
The default implementation always returns false.
- If canFetchMore() returns true, QAbstractItemView will call fetchMore().
- However, the fetchMore() function is only called when the model is being
- populated incrementally.
+ If canFetchMore() returns true, the fetchMore() function should
+ be called. This is the behavior of QAbstractItemView, for example.
\sa fetchMore()
*/
@@ -3054,6 +3077,7 @@ void QAbstractItemModel::endResetModel()
{
Q_D(QAbstractItemModel);
d->invalidatePersistentIndexes();
+ QMetaObject::invokeMethod(this, "resetInternalData");
emit modelReset(QPrivateSignal());
}
@@ -3271,6 +3295,17 @@ bool QAbstractTableModel::hasChildren(const QModelIndex &parent) const
}
/*!
+ \reimp
+ */
+Qt::ItemFlags QAbstractTableModel::flags(const QModelIndex &index) const
+{
+ Qt::ItemFlags f = QAbstractItemModel::flags(index);
+ if (index.isValid())
+ f |= Qt::ItemNeverHasChildren;
+ return f;
+}
+
+/*!
\class QAbstractListModel
\inmodule QtCore
\brief The QAbstractListModel class provides an abstract model that can be
@@ -3391,6 +3426,17 @@ QModelIndex QAbstractListModel::parent(const QModelIndex & /* index */) const
}
/*!
+ \reimp
+ */
+Qt::ItemFlags QAbstractListModel::flags(const QModelIndex &index) const
+{
+ Qt::ItemFlags f = QAbstractItemModel::flags(index);
+ if (index.isValid())
+ f |= Qt::ItemNeverHasChildren;
+ return f;
+}
+
+/*!
\internal
Returns the number of columns in the list with the given \a parent.
diff --git a/src/corelib/itemmodels/qabstractitemmodel.h b/src/corelib/itemmodels/qabstractitemmodel.h
index 793a1ba169..6a57ccaca8 100644
--- a/src/corelib/itemmodels/qabstractitemmodel.h
+++ b/src/corelib/itemmodels/qabstractitemmodel.h
@@ -47,8 +47,6 @@
#include <QtCore/qhash.h>
#include <QtCore/qvector.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -332,6 +330,10 @@ public Q_SLOTS:
virtual bool submit();
virtual void revert();
+protected Q_SLOTS:
+ // Qt 6: Make virtual
+ void resetInternalData();
+
protected:
QAbstractItemModel(QAbstractItemModelPrivate &dd, QObject *parent = 0);
@@ -421,6 +423,7 @@ public:
bool dropMimeData(const QMimeData *data, Qt::DropAction action,
int row, int column, const QModelIndex &parent);
+ Qt::ItemFlags flags(const QModelIndex &index) const Q_DECL_OVERRIDE;
protected:
QAbstractTableModel(QAbstractItemModelPrivate &dd, QObject *parent);
@@ -441,6 +444,8 @@ public:
QModelIndex index(int row, int column = 0, const QModelIndex &parent = QModelIndex()) const;
bool dropMimeData(const QMimeData *data, Qt::DropAction action,
int row, int column, const QModelIndex &parent);
+
+ Qt::ItemFlags flags(const QModelIndex &index) const Q_DECL_OVERRIDE;
protected:
QAbstractListModel(QAbstractItemModelPrivate &dd, QObject *parent);
@@ -473,6 +478,4 @@ inline uint qHash(const QModelIndex &index)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QABSTRACTITEMMODEL_H
diff --git a/src/corelib/itemmodels/qabstractproxymodel.cpp b/src/corelib/itemmodels/qabstractproxymodel.cpp
index ed5d0e9a85..d435c4bcf5 100644
--- a/src/corelib/itemmodels/qabstractproxymodel.cpp
+++ b/src/corelib/itemmodels/qabstractproxymodel.cpp
@@ -91,6 +91,7 @@ QT_BEGIN_NAMESPACE
//detects the deletion of the source model
void QAbstractProxyModelPrivate::_q_sourceModelDestroyed()
{
+ invalidatePersistentIndexes();
model = QAbstractItemModelPrivate::staticEmptyModel();
}
@@ -148,6 +149,15 @@ void QAbstractProxyModel::setSourceModel(QAbstractItemModel *sourceModel)
}
/*!
+ Clears the roleNames of this proxy model.
+*/
+void QAbstractProxyModel::resetInternalData()
+{
+ Q_D(QAbstractProxyModel);
+ d->roleNames = d->model->roleNames();
+}
+
+/*!
Returns the model that contains the data that is available through the proxy model.
*/
QAbstractItemModel *QAbstractProxyModel::sourceModel() const
@@ -262,8 +272,7 @@ QVariant QAbstractProxyModel::headerData(int section, Qt::Orientation orientatio
*/
QMap<int, QVariant> QAbstractProxyModel::itemData(const QModelIndex &proxyIndex) const
{
- Q_D(const QAbstractProxyModel);
- return d->model->itemData(mapToSource(proxyIndex));
+ return QAbstractItemModel::itemData(proxyIndex);
}
/*!
@@ -289,8 +298,7 @@ bool QAbstractProxyModel::setData(const QModelIndex &index, const QVariant &valu
*/
bool QAbstractProxyModel::setItemData(const QModelIndex &index, const QMap< int, QVariant >& roles)
{
- Q_D(QAbstractProxyModel);
- return d->model->setItemData(mapToSource(index), roles);
+ return QAbstractItemModel::setItemData(index, roles);
}
/*!
diff --git a/src/corelib/itemmodels/qabstractproxymodel.h b/src/corelib/itemmodels/qabstractproxymodel.h
index e7a47214f8..9b26d6cead 100644
--- a/src/corelib/itemmodels/qabstractproxymodel.h
+++ b/src/corelib/itemmodels/qabstractproxymodel.h
@@ -44,8 +44,6 @@
#include <QtCore/qabstractitemmodel.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -103,6 +101,9 @@ Q_SIGNALS:
#endif
);
+protected Q_SLOTS:
+ void resetInternalData();
+
protected:
QAbstractProxyModel(QAbstractProxyModelPrivate &, QObject *parent);
@@ -116,6 +117,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QABSTRACTPROXYMODEL_H
diff --git a/src/corelib/itemmodels/qidentityproxymodel.h b/src/corelib/itemmodels/qidentityproxymodel.h
index 4125683f77..8a416c97bc 100644
--- a/src/corelib/itemmodels/qidentityproxymodel.h
+++ b/src/corelib/itemmodels/qidentityproxymodel.h
@@ -47,8 +47,6 @@
#ifndef QT_NO_IDENTITYPROXYMODEL
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -113,8 +111,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_IDENTITYPROXYMODEL
#endif // QIDENTITYPROXYMODEL_H
diff --git a/src/corelib/itemmodels/qitemselectionmodel.h b/src/corelib/itemmodels/qitemselectionmodel.h
index dd5f6061cd..2a1a4b0a2d 100644
--- a/src/corelib/itemmodels/qitemselectionmodel.h
+++ b/src/corelib/itemmodels/qitemselectionmodel.h
@@ -47,8 +47,6 @@
#include <QtCore/qlist.h>
#include <QtCore/qabstractitemmodel.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -253,6 +251,4 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QItemSelectionRange &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QITEMSELECTIONMODEL_H
diff --git a/src/corelib/itemmodels/qsortfilterproxymodel.cpp b/src/corelib/itemmodels/qsortfilterproxymodel.cpp
index e5bdd83dc3..67b0d98402 100644
--- a/src/corelib/itemmodels/qsortfilterproxymodel.cpp
+++ b/src/corelib/itemmodels/qsortfilterproxymodel.cpp
@@ -295,7 +295,8 @@ typedef QHash<QModelIndex, QSortFilterProxyModelPrivate::Mapping *> IndexMap;
void QSortFilterProxyModelPrivate::_q_sourceModelDestroyed()
{
QAbstractProxyModelPrivate::_q_sourceModelDestroyed();
- _q_clearMapping();
+ qDeleteAll(source_index_mapping);
+ source_index_mapping.clear();
}
void QSortFilterProxyModelPrivate::remove_from_mapping(const QModelIndex &source_parent)
diff --git a/src/corelib/itemmodels/qsortfilterproxymodel.h b/src/corelib/itemmodels/qsortfilterproxymodel.h
index ffebec5283..a37c892c6c 100644
--- a/src/corelib/itemmodels/qsortfilterproxymodel.h
+++ b/src/corelib/itemmodels/qsortfilterproxymodel.h
@@ -48,8 +48,6 @@
#include <QtCore/qregexp.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -198,8 +196,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_SORTFILTERPROXYMODEL
#endif // QSORTFILTERPROXYMODEL_H
diff --git a/src/corelib/itemmodels/qstringlistmodel.cpp b/src/corelib/itemmodels/qstringlistmodel.cpp
index c6fabfcaee..31c9137c79 100644
--- a/src/corelib/itemmodels/qstringlistmodel.cpp
+++ b/src/corelib/itemmodels/qstringlistmodel.cpp
@@ -170,9 +170,9 @@ QVariant QStringListModel::data(const QModelIndex &index, int role) const
Qt::ItemFlags QStringListModel::flags(const QModelIndex &index) const
{
if (!index.isValid())
- return QAbstractItemModel::flags(index) | Qt::ItemIsDropEnabled;
+ return QAbstractListModel::flags(index) | Qt::ItemIsDropEnabled;
- return QAbstractItemModel::flags(index) | Qt::ItemIsEditable | Qt::ItemIsDragEnabled | Qt::ItemIsDropEnabled;
+ return QAbstractListModel::flags(index) | Qt::ItemIsEditable | Qt::ItemIsDragEnabled | Qt::ItemIsDropEnabled;
}
/*!
diff --git a/src/corelib/itemmodels/qstringlistmodel.h b/src/corelib/itemmodels/qstringlistmodel.h
index 22e9294f74..3514b27508 100644
--- a/src/corelib/itemmodels/qstringlistmodel.h
+++ b/src/corelib/itemmodels/qstringlistmodel.h
@@ -45,8 +45,6 @@
#include <QtCore/qabstractitemmodel.h>
#include <QtCore/qstringlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -86,6 +84,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTRINGLISTMODEL_H
diff --git a/src/corelib/json/qjsonarray.h b/src/corelib/json/qjsonarray.h
index 24c04d2942..1474ccae41 100644
--- a/src/corelib/json/qjsonarray.h
+++ b/src/corelib/json/qjsonarray.h
@@ -45,8 +45,6 @@
#include <QtCore/qjsonvalue.h>
#include <QtCore/qiterator.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QDebug;
@@ -219,6 +217,4 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QJsonArray &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QJSONARRAY_H
diff --git a/src/corelib/json/qjsondocument.cpp b/src/corelib/json/qjsondocument.cpp
index 550cc76b0d..bdb46528d3 100644
--- a/src/corelib/json/qjsondocument.cpp
+++ b/src/corelib/json/qjsondocument.cpp
@@ -303,15 +303,50 @@ QVariant QJsonDocument::toVariant() const
*/
QByteArray QJsonDocument::toJson() const
{
+ return toJson(Indented);
+}
+
+/*!
+ \enum QJsonDocument::JsonFormat
+
+ This value defines the format of the JSON byte array produced
+ when converting to a QJsonDocument using toJson().
+
+ \value Indented Defines human readable output as follows:
+ \code
+ {
+ "Array": [
+ true,
+ 999,
+ "string"
+ ],
+ "Key": "Value",
+ "null": null
+ }
+ \endcode
+
+ \value Compact Defines a compact output as follows:
+ \code
+ {"Array": [true,999,"string"],"Key": "Value","null": null}
+ \endcode
+ */
+
+/*!
+ Converts the QJsonDocument to a UTF-8 encoded JSON document in the provided \a format.
+
+ \sa fromJson(), JsonFormat
+ */
+QByteArray QJsonDocument::toJson(JsonFormat format) const
+{
if (!d)
return QByteArray();
QByteArray json;
if (d->header->root()->isArray())
- QJsonPrivate::Writer::arrayToJson(static_cast<QJsonPrivate::Array *>(d->header->root()), json, 0);
+ QJsonPrivate::Writer::arrayToJson(static_cast<QJsonPrivate::Array *>(d->header->root()), json, 0, (format == Compact));
else
- QJsonPrivate::Writer::objectToJson(static_cast<QJsonPrivate::Object *>(d->header->root()), json, 0);
+ QJsonPrivate::Writer::objectToJson(static_cast<QJsonPrivate::Object *>(d->header->root()), json, 0, (format == Compact));
return json;
}
diff --git a/src/corelib/json/qjsondocument.h b/src/corelib/json/qjsondocument.h
index 675ee75dbf..4d4f3885dc 100644
--- a/src/corelib/json/qjsondocument.h
+++ b/src/corelib/json/qjsondocument.h
@@ -44,8 +44,6 @@
#include <QtCore/qjsonvalue.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QDebug;
@@ -109,8 +107,19 @@ public:
static QJsonDocument fromVariant(const QVariant &variant);
QVariant toVariant() const;
+ enum JsonFormat {
+ Indented,
+ Compact
+ };
+
static QJsonDocument fromJson(const QByteArray &json, QJsonParseError *error = 0);
- QByteArray toJson() const;
+
+#ifdef Q_QDOC
+ QByteArray toJson(JsonFormat format = Indented) const;
+#else
+ QByteArray toJson() const; //### Merge in Qt6
+ QByteArray toJson(JsonFormat format) const;
+#endif
bool isEmpty() const;
bool isArray() const;
@@ -144,6 +153,4 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QJsonDocument &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QJSONDOCUMENT_H
diff --git a/src/corelib/json/qjsonobject.h b/src/corelib/json/qjsonobject.h
index 4168e4b633..8226b614b4 100644
--- a/src/corelib/json/qjsonobject.h
+++ b/src/corelib/json/qjsonobject.h
@@ -45,8 +45,6 @@
#include <QtCore/qjsonvalue.h>
#include <QtCore/qiterator.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QDebug;
@@ -214,6 +212,4 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QJsonObject &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QJSONOBJECT_H
diff --git a/src/corelib/json/qjsonvalue.h b/src/corelib/json/qjsonvalue.h
index 38f4a03c0f..b8bdf55aa3 100644
--- a/src/corelib/json/qjsonvalue.h
+++ b/src/corelib/json/qjsonvalue.h
@@ -45,8 +45,6 @@
#include <QtCore/qglobal.h>
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QDebug;
@@ -184,6 +182,4 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QJsonValue &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QJSONVALUE_H
diff --git a/src/corelib/kernel/kernel.pri b/src/corelib/kernel/kernel.pri
index 34e32a721d..5a8499d723 100644
--- a/src/corelib/kernel/kernel.pri
+++ b/src/corelib/kernel/kernel.pri
@@ -131,7 +131,7 @@ unix|integrity {
contains(QT_CONFIG, clock-gettime):include($$QT_SOURCE_TREE/config.tests/unix/clock-gettime/clock-gettime.pri)
- !linux-android-* {
+ !android {
SOURCES += kernel/qsharedmemory_unix.cpp \
kernel/qsystemsemaphore_unix.cpp
} else {
diff --git a/src/corelib/kernel/qabstracteventdispatcher.cpp b/src/corelib/kernel/qabstracteventdispatcher.cpp
index c4e02c0347..6558893036 100644
--- a/src/corelib/kernel/qabstracteventdispatcher.cpp
+++ b/src/corelib/kernel/qabstracteventdispatcher.cpp
@@ -172,7 +172,7 @@ QAbstractEventDispatcher::~QAbstractEventDispatcher()
QAbstractEventDispatcher *QAbstractEventDispatcher::instance(QThread *thread)
{
QThreadData *data = thread ? QThreadData::get2(thread) : QThreadData::current();
- return data->eventDispatcher;
+ return data->eventDispatcher.load();
}
/*!
diff --git a/src/corelib/kernel/qabstracteventdispatcher.h b/src/corelib/kernel/qabstracteventdispatcher.h
index c07c395a84..6f21cefa4e 100644
--- a/src/corelib/kernel/qabstracteventdispatcher.h
+++ b/src/corelib/kernel/qabstracteventdispatcher.h
@@ -45,8 +45,6 @@
#include <QtCore/qobject.h>
#include <QtCore/qeventloop.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QAbstractNativeEventFilter;
@@ -129,6 +127,4 @@ protected:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QABSTRACTEVENTDISPATCHER_H
diff --git a/src/corelib/kernel/qabstractnativeeventfilter.cpp b/src/corelib/kernel/qabstractnativeeventfilter.cpp
index ad5e7f888c..b38e225f0d 100644
--- a/src/corelib/kernel/qabstractnativeeventfilter.cpp
+++ b/src/corelib/kernel/qabstractnativeeventfilter.cpp
@@ -61,6 +61,7 @@ QT_BEGIN_NAMESPACE
*/
QAbstractNativeEventFilter::QAbstractNativeEventFilter()
{
+ Q_UNUSED(d);
}
/*!
diff --git a/src/corelib/kernel/qabstractnativeeventfilter.h b/src/corelib/kernel/qabstractnativeeventfilter.h
index 09701a4923..9d1db2c19b 100644
--- a/src/corelib/kernel/qabstractnativeeventfilter.h
+++ b/src/corelib/kernel/qabstractnativeeventfilter.h
@@ -44,8 +44,6 @@
#include <QtCore/qnamespace.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QAbstractNativeEventFilterPrivate;
@@ -65,6 +63,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif /* QABSTRACTNATIVEEVENTFILTER_H */
diff --git a/src/corelib/kernel/qbasictimer.h b/src/corelib/kernel/qbasictimer.h
index 4fdb00d633..432e4d58c8 100644
--- a/src/corelib/kernel/qbasictimer.h
+++ b/src/corelib/kernel/qbasictimer.h
@@ -45,8 +45,6 @@
#include <QtCore/qglobal.h>
#include <QtCore/qnamespace.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -70,6 +68,4 @@ Q_DECLARE_TYPEINFO(QBasicTimer, Q_MOVABLE_TYPE);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QBASICTIMER_H
diff --git a/src/corelib/kernel/qcore_mac_p.h b/src/corelib/kernel/qcore_mac_p.h
index c3a3afaf6c..4211a23e0f 100644
--- a/src/corelib/kernel/qcore_mac_p.h
+++ b/src/corelib/kernel/qcore_mac_p.h
@@ -57,12 +57,14 @@
# define __IMAGECAPTURE__
#endif
-#if defined(QT_BUILD_QMAKE) || defined(QT_BOOTSTRAPPED)
+#if defined(QT_BOOTSTRAPPED)
#include <ApplicationServices/ApplicationServices.h>
#else
#include <CoreFoundation/CoreFoundation.h>
#endif
+#include "qglobal.h"
+
#ifndef Q_OS_IOS
#include <CoreServices/CoreServices.h>
#endif
@@ -106,6 +108,7 @@ public:
return *this;
}
inline T *operator&() { return &type; }
+ template <typename X> X as() const { return reinterpret_cast<X>(type); }
static QCFType constructFromGet(const T &t)
{
CFRetain(t);
@@ -136,14 +139,4 @@ private:
QT_END_NAMESPACE
-#if (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_5)
-#ifndef __LP64__
- typedef float CGFloat;
- typedef int NSInteger;
- typedef unsigned int NSUInteger;
- #define SRefCon SInt32
- #define URefCon UInt32
-#endif
-#endif
-
#endif // QCORE_MAC_P_H
diff --git a/src/corelib/kernel/qcore_unix.cpp b/src/corelib/kernel/qcore_unix.cpp
index cc5479876d..241658acb1 100644
--- a/src/corelib/kernel/qcore_unix.cpp
+++ b/src/corelib/kernel/qcore_unix.cpp
@@ -60,8 +60,8 @@
QT_BEGIN_NAMESPACE
-static inline bool time_update(struct timeval *tv, const struct timeval &start,
- const struct timeval &timeout)
+static inline bool time_update(struct timespec *tv, const struct timespec &start,
+ const struct timespec &timeout)
{
if (!QElapsedTimer::isMonotonic()) {
// we cannot recalculate the timeout without a monotonic clock as the time may have changed
@@ -69,13 +69,13 @@ static inline bool time_update(struct timeval *tv, const struct timeval &start,
}
// clock source is monotonic, so we can recalculate how much timeout is left
- struct timeval now = qt_gettime();
+ struct timespec now = qt_gettime();
*tv = timeout + start - now;
return tv->tv_sec >= 0;
}
int qt_safe_select(int nfds, fd_set *fdread, fd_set *fdwrite, fd_set *fdexcept,
- const struct timeval *orig_timeout)
+ const struct timespec *orig_timeout)
{
if (!orig_timeout) {
// no timeout -> block forever
@@ -84,13 +84,20 @@ int qt_safe_select(int nfds, fd_set *fdread, fd_set *fdwrite, fd_set *fdexcept,
return ret;
}
- timeval start = qt_gettime();
- timeval timeout = *orig_timeout;
+ timespec start = qt_gettime();
+ timespec timeout = *orig_timeout;
// loop and recalculate the timeout as needed
int ret;
forever {
- ret = ::select(nfds, fdread, fdwrite, fdexcept, &timeout);
+#ifndef Q_OS_QNX
+ ret = ::pselect(nfds, fdread, fdwrite, fdexcept, &timeout, 0);
+#else
+ timeval timeoutVal;
+ timeoutVal.tv_sec = timeout.tv_sec;
+ timeoutVal.tv_usec = timeout.tv_nsec / 1000;
+ ret = ::select(nfds, fdread, fdwrite, fdexcept, &timeoutVal);
+#endif
if (ret != -1 || errno != EINTR)
return ret;
diff --git a/src/corelib/kernel/qcore_unix_p.h b/src/corelib/kernel/qcore_unix_p.h
index 6342b0362a..b68146cd6c 100644
--- a/src/corelib/kernel/qcore_unix_p.h
+++ b/src/corelib/kernel/qcore_unix_p.h
@@ -100,49 +100,49 @@ using namespace QT_PREPEND_NAMESPACE(QtLibcSupplement);
QT_BEGIN_NAMESPACE
-// Internal operator functions for timevals
-inline timeval &normalizedTimeval(timeval &t)
+// Internal operator functions for timespecs
+inline timespec &normalizedTimespec(timespec &t)
{
- while (t.tv_usec >= 1000000) {
+ while (t.tv_nsec >= 1000000000) {
++t.tv_sec;
- t.tv_usec -= 1000000;
+ t.tv_nsec -= 1000000000;
}
- while (t.tv_usec < 0) {
+ while (t.tv_nsec < 0) {
--t.tv_sec;
- t.tv_usec += 1000000;
+ t.tv_nsec += 1000000000;
}
return t;
}
-inline bool operator<(const timeval &t1, const timeval &t2)
-{ return t1.tv_sec < t2.tv_sec || (t1.tv_sec == t2.tv_sec && t1.tv_usec < t2.tv_usec); }
-inline bool operator==(const timeval &t1, const timeval &t2)
-{ return t1.tv_sec == t2.tv_sec && t1.tv_usec == t2.tv_usec; }
-inline timeval &operator+=(timeval &t1, const timeval &t2)
+inline bool operator<(const timespec &t1, const timespec &t2)
+{ return t1.tv_sec < t2.tv_sec || (t1.tv_sec == t2.tv_sec && t1.tv_nsec < t2.tv_nsec); }
+inline bool operator==(const timespec &t1, const timespec &t2)
+{ return t1.tv_sec == t2.tv_sec && t1.tv_nsec == t2.tv_nsec; }
+inline timespec &operator+=(timespec &t1, const timespec &t2)
{
t1.tv_sec += t2.tv_sec;
- t1.tv_usec += t2.tv_usec;
- return normalizedTimeval(t1);
+ t1.tv_nsec += t2.tv_nsec;
+ return normalizedTimespec(t1);
}
-inline timeval operator+(const timeval &t1, const timeval &t2)
+inline timespec operator+(const timespec &t1, const timespec &t2)
{
- timeval tmp;
+ timespec tmp;
tmp.tv_sec = t1.tv_sec + t2.tv_sec;
- tmp.tv_usec = t1.tv_usec + t2.tv_usec;
- return normalizedTimeval(tmp);
+ tmp.tv_nsec = t1.tv_nsec + t2.tv_nsec;
+ return normalizedTimespec(tmp);
}
-inline timeval operator-(const timeval &t1, const timeval &t2)
+inline timespec operator-(const timespec &t1, const timespec &t2)
{
- timeval tmp;
+ timespec tmp;
tmp.tv_sec = t1.tv_sec - (t2.tv_sec - 1);
- tmp.tv_usec = t1.tv_usec - (t2.tv_usec + 1000000);
- return normalizedTimeval(tmp);
+ tmp.tv_nsec = t1.tv_nsec - (t2.tv_nsec + 1000000000);
+ return normalizedTimespec(tmp);
}
-inline timeval operator*(const timeval &t1, int mul)
+inline timespec operator*(const timespec &t1, int mul)
{
- timeval tmp;
+ timespec tmp;
tmp.tv_sec = t1.tv_sec * mul;
- tmp.tv_usec = t1.tv_usec * mul;
- return normalizedTimeval(tmp);
+ tmp.tv_nsec = t1.tv_nsec * mul;
+ return normalizedTimespec(tmp);
}
inline void qt_ignore_sigpipe()
@@ -335,11 +335,11 @@ static inline pid_t qt_safe_waitpid(pid_t pid, int *status, int options)
#endif
// in qelapsedtimer_mac.cpp or qtimestamp_unix.cpp
-timeval qt_gettime() Q_DECL_NOTHROW;
+timespec qt_gettime() Q_DECL_NOTHROW;
void qt_nanosleep(timespec amount);
Q_CORE_EXPORT int qt_safe_select(int nfds, fd_set *fdread, fd_set *fdwrite, fd_set *fdexcept,
- const struct timeval *tv);
+ const struct timespec *tv);
// according to X/OPEN we have to define semun ourselves
// we use prefix as on some systems sem.h will have it
diff --git a/src/corelib/kernel/qcoreapplication.cpp b/src/corelib/kernel/qcoreapplication.cpp
index ec808424f9..100e014e99 100644
--- a/src/corelib/kernel/qcoreapplication.cpp
+++ b/src/corelib/kernel/qcoreapplication.cpp
@@ -42,9 +42,11 @@
#include "qcoreapplication.h"
#include "qcoreapplication_p.h"
+#ifndef QT_NO_QOBJECT
#include "qabstracteventdispatcher.h"
#include "qcoreevent.h"
#include "qeventloop.h"
+#endif
#include "qcorecmdlineargs_p.h"
#include <qdatastream.h>
#include <qdebug.h>
@@ -55,10 +57,12 @@
#include <private/qprocess_p.h>
#include <qstandardpaths.h>
#include <qtextcodec.h>
+#ifndef QT_NO_QOBJECT
#include <qthread.h>
#include <qthreadpool.h>
#include <qthreadstorage.h>
#include <private/qthread_p.h>
+#endif
#include <qelapsedtimer.h>
#include <qlibraryinfo.h>
#include <qvarlengtharray.h>
@@ -66,6 +70,7 @@
#include <private/qfunctions_p.h>
#include <private/qlocale_p.h>
+#ifndef QT_NO_QOBJECT
#if defined(Q_OS_UNIX)
# if defined(Q_OS_BLACKBERRY)
# include "qeventdispatcher_blackberry_p.h"
@@ -78,10 +83,10 @@
# include "qeventdispatcher_unix_p.h"
# endif
#endif
-
#ifdef Q_OS_WIN
# include "qeventdispatcher_win_p.h"
#endif
+#endif // QT_NO_QOBJECT
#ifdef Q_OS_MAC
# include "qcore_mac_p.h"
@@ -91,6 +96,7 @@
#ifdef Q_OS_UNIX
# include <locale.h>
+# include <unistd.h>
#endif
#ifdef Q_OS_VXWORKS
@@ -99,6 +105,7 @@
QT_BEGIN_NAMESPACE
+#ifndef QT_NO_QOBJECT
class QMutexUnlocker
{
public:
@@ -113,6 +120,7 @@ private:
QMutex *mtx;
};
+#endif
#if defined(Q_OS_WIN) || defined(Q_OS_MAC)
extern QString qAppFileName();
@@ -183,19 +191,47 @@ void QCoreApplicationPrivate::processCommandLineArguments()
// Support for introspection
+#ifndef QT_NO_QOBJECT
QSignalSpyCallbackSet Q_CORE_EXPORT qt_signal_spy_callback_set = { 0, 0, 0, 0 };
void qt_register_signal_spy_callbacks(const QSignalSpyCallbackSet &callback_set)
{
qt_signal_spy_callback_set = callback_set;
}
+#endif
extern "C" void Q_CORE_EXPORT qt_startup_hook()
{
}
+typedef QList<QtStartUpFunction> QStartUpFuncList;
+Q_GLOBAL_STATIC(QStartUpFuncList, preRList)
typedef QList<QtCleanUpFunction> QVFuncList;
Q_GLOBAL_STATIC(QVFuncList, postRList)
+#ifndef QT_NO_QOBJECT
+static QBasicMutex globalPreRoutinesMutex;
+#endif
+
+/*!
+ \internal
+
+ Adds a global routine that will be called from the QCoreApplication
+ constructor. The public API is Q_COREAPP_STARTUP_FUNCTION.
+*/
+void qAddPreRoutine(QtStartUpFunction p)
+{
+ QStartUpFuncList *list = preRList();
+ if (!list)
+ return;
+ // Due to C++11 parallel dynamic initialization, this can be called
+ // from multiple threads.
+#ifndef QT_NO_THREAD
+ QMutexLocker locker(&globalPreRoutinesMutex);
+#endif
+ if (QCoreApplication::instance())
+ p();
+ list->prepend(p); // in case QCoreApplication is re-created, see qt_call_pre_routines
+}
void qAddPostRoutine(QtCleanUpFunction p)
{
@@ -213,6 +249,21 @@ void qRemovePostRoutine(QtCleanUpFunction p)
list->removeAll(p);
}
+static void qt_call_pre_routines()
+{
+ QStartUpFuncList *list = preRList();
+ if (!list)
+ return;
+#ifndef QT_NO_THREAD
+ QMutexLocker locker(&globalPreRoutinesMutex);
+#endif
+ // Unlike qt_call_post_routines, we don't empty the list, because
+ // Q_COREAPP_STARTUP_FUNCTION is a macro, so the user expects
+ // the function to be executed every time QCoreApplication is created.
+ for (int i = 0; i < list->count(); ++i)
+ list->at(i)();
+}
+
void Q_CORE_EXPORT qt_call_post_routines()
{
QVFuncList *list = 0;
@@ -230,12 +281,15 @@ void Q_CORE_EXPORT qt_call_post_routines()
}
+// initialized in qcoreapplication and in qtextstream autotest when setlocale is called.
+static bool qt_locale_initialized = false;
+
+#ifndef QT_NO_QOBJECT
+
// app starting up if false
bool QCoreApplicationPrivate::is_app_running = false;
// app closing down if true
bool QCoreApplicationPrivate::is_app_closing = false;
-// initialized in qcoreapplication and in qtextstream autotest when setlocale is called.
-static bool qt_locale_initialized = false;
Q_CORE_EXPORT uint qGlobalPostedEventsCount()
{
@@ -243,14 +297,17 @@ Q_CORE_EXPORT uint qGlobalPostedEventsCount()
return currentThreadData->postEventList.size() - currentThreadData->postEventList.startOffset;
}
-QCoreApplication *QCoreApplication::self = 0;
QAbstractEventDispatcher *QCoreApplicationPrivate::eventDispatcher = 0;
-uint QCoreApplicationPrivate::attribs = (1 << Qt::AA_SynthesizeMouseForUnhandledTouchEvents);
#ifdef Q_OS_UNIX
Qt::HANDLE qt_application_thread_id = 0;
#endif
+#endif // QT_NO_QOBJECT
+
+QCoreApplication *QCoreApplication::self = 0;
+uint QCoreApplicationPrivate::attribs = (1 << Qt::AA_SynthesizeMouseForUnhandledTouchEvents);
+
struct QCoreApplicationData {
QCoreApplicationData() {
#ifndef QT_NO_LIBRARY
@@ -261,13 +318,13 @@ struct QCoreApplicationData {
#ifndef QT_NO_LIBRARY
delete app_libpaths;
#endif
-
+#ifndef QT_NO_QOBJECT
// cleanup the QAdoptedThread created for the main() thread
- if (QCoreApplicationPrivate::theMainThread) {
- QThreadData *data = QThreadData::get2(QCoreApplicationPrivate::theMainThread);
- QCoreApplicationPrivate::theMainThread = 0;
- data->deref(); // deletes the data and the adopted thread
- }
+ if (QCoreApplicationPrivate::theMainThread) {
+ QThreadData *data = QThreadData::get2(QCoreApplicationPrivate::theMainThread);
+ data->deref(); // deletes the data and the adopted thread
+ }
+#endif
}
#ifdef Q_OS_BLACKBERRY
@@ -309,20 +366,29 @@ struct QCoreApplicationData {
Q_GLOBAL_STATIC(QCoreApplicationData, coreappdata)
+#ifndef QT_NO_QOBJECT
static bool quitLockRefEnabled = true;
+#endif
QCoreApplicationPrivate::QCoreApplicationPrivate(int &aargc, char **aargv, uint flags)
- : QObjectPrivate()
- , argc(aargc)
+ :
+#ifndef QT_NO_QOBJECT
+ QObjectPrivate(),
+#endif
+ argc(aargc)
, argv(aargv)
#ifdef Q_OS_WIN
, origArgc(aargc)
, origArgv(new char *[aargc])
#endif
, application_type(0)
+#ifndef QT_NO_QOBJECT
, in_exec(false)
, aboutToQuitEmitted(false)
, threadData_clean(false)
+#else
+ , q_ptr(0)
+#endif
{
app_compile_version = flags & 0xffffff;
static const char *const empty = "";
@@ -330,27 +396,35 @@ QCoreApplicationPrivate::QCoreApplicationPrivate(int &aargc, char **aargv, uint
argc = 0;
argv = (char **)&empty; // ouch! careful with QCoreApplication::argv()!
}
+#ifdef Q_OS_WIN
+ qCopy(argv, argv + argc, origArgv);
+#endif
+
+#ifndef QT_NO_QOBJECT
QCoreApplicationPrivate::is_app_closing = false;
-#if defined(Q_OS_UNIX)
+# if defined(Q_OS_UNIX)
qt_application_thread_id = QThread::currentThreadId();
-#elif defined(Q_OS_WIN)
- qCopy(argv, argv + argc, origArgv);
-#endif
+# endif
// note: this call to QThread::currentThread() may end up setting theMainThread!
if (QThread::currentThread() != theMainThread)
qWarning("WARNING: QApplication was not created in the main() thread.");
+#endif
}
QCoreApplicationPrivate::~QCoreApplicationPrivate()
{
+#ifndef QT_NO_QOBJECT
cleanupThreadData();
+#endif
#ifdef Q_OS_WIN
delete [] origArgv;
#endif
}
+#ifndef QT_NO_QOBJECT
+
void QCoreApplicationPrivate::cleanupThreadData()
{
if (threadData && !threadData_clean) {
@@ -423,6 +497,8 @@ void QCoreApplicationPrivate::checkReceiverThread(QObject *receiver)
}
#endif
+#endif // QT_NO_QOBJECT
+
void QCoreApplicationPrivate::appendApplicationPathToLibraryPaths()
{
#ifndef QT_NO_LIBRARY
@@ -544,13 +620,18 @@ void QCoreApplicationPrivate::initLocale()
\internal
*/
QCoreApplication::QCoreApplication(QCoreApplicationPrivate &p)
+#ifdef QT_NO_QOBJECT
+ : d_ptr(&p)
+#else
: QObject(p, 0)
+#endif
{
init();
// note: it is the subclasses' job to call
// QCoreApplicationPrivate::eventDispatcher->startingUp();
}
+#ifndef QT_NO_QOBJECT
/*!
Flushes the platform specific event queues.
@@ -567,6 +648,7 @@ void QCoreApplication::flush()
if (self && self->d_func()->eventDispatcher)
self->d_func()->eventDispatcher->flush();
}
+#endif
/*!
Constructs a Qt kernel application. Kernel applications are
@@ -587,16 +669,23 @@ QCoreApplication::QCoreApplication(int &argc, char **argv
, int _internal
#endif
)
+#ifdef QT_NO_QOBJECT
+ : d_ptr(new QCoreApplicationPrivate(argc, argv, _internal))
+#else
: QObject(*new QCoreApplicationPrivate(argc, argv, _internal))
+#endif
{
init();
+#ifndef QT_NO_QOBJECT
QCoreApplicationPrivate::eventDispatcher->startingUp();
+#endif
}
// ### move to QCoreApplicationPrivate constructor?
void QCoreApplication::init()
{
+ d_ptr->q_ptr = this;
Q_D(QCoreApplication);
QCoreApplicationPrivate::initLocale();
@@ -604,9 +693,10 @@ void QCoreApplication::init()
Q_ASSERT_X(!self, "QCoreApplication", "there should be only one application object");
QCoreApplication::self = this;
+#ifndef QT_NO_QOBJECT
// use the event dispatcher created by the app programmer (if any)
if (!QCoreApplicationPrivate::eventDispatcher)
- QCoreApplicationPrivate::eventDispatcher = d->threadData->eventDispatcher;
+ QCoreApplicationPrivate::eventDispatcher = d->threadData->eventDispatcher.load();
// otherwise we create one
if (!QCoreApplicationPrivate::eventDispatcher)
d->createEventDispatcher();
@@ -618,17 +708,20 @@ void QCoreApplication::init()
}
d->threadData->eventDispatcher = QCoreApplicationPrivate::eventDispatcher;
+#endif
#ifndef QT_NO_LIBRARY
if (coreappdata()->app_libpaths)
d->appendApplicationPathToLibraryPaths();
#endif
+#ifndef QT_NO_QOBJECT
#if defined(Q_OS_UNIX) && !(defined(QT_NO_PROCESS))
// Make sure the process manager thread object is created in the main
// thread.
QProcessPrivate::initializeProcessManager();
#endif
+#endif
#ifdef QT_EVAL
extern void qt_core_eval_init(uint);
@@ -637,7 +730,12 @@ void QCoreApplication::init()
d->processCommandLineArguments();
+ qt_call_pre_routines();
qt_startup_hook();
+
+#ifndef QT_NO_QOBJECT
+ QCoreApplicationPrivate::is_app_running = true; // No longer starting up.
+#endif
}
/*!
@@ -648,8 +746,10 @@ QCoreApplication::~QCoreApplication()
qt_call_post_routines();
self = 0;
+#ifndef QT_NO_QOBJECT
QCoreApplicationPrivate::is_app_closing = true;
QCoreApplicationPrivate::is_app_running = false;
+#endif
#if !defined(QT_NO_THREAD)
// Synchronize and stop the global thread pool threads.
@@ -663,10 +763,12 @@ QCoreApplication::~QCoreApplication()
globalThreadPool->waitForDone();
#endif
+#ifndef QT_NO_QOBJECT
d_func()->threadData->eventDispatcher = 0;
if (QCoreApplicationPrivate::eventDispatcher)
QCoreApplicationPrivate::eventDispatcher->closingDown();
QCoreApplicationPrivate::eventDispatcher = 0;
+#endif
#ifndef QT_NO_LIBRARY
delete coreappdata()->app_libpaths;
@@ -708,6 +810,8 @@ bool QCoreApplication::testAttribute(Qt::ApplicationAttribute attribute)
}
+#ifndef QT_NO_QOBJECT
+
/*!
\property QCoreApplication::quitLockEnabled
@@ -934,9 +1038,9 @@ bool QCoreApplication::closingDown()
void QCoreApplication::processEvents(QEventLoop::ProcessEventsFlags flags)
{
QThreadData *data = QThreadData::current();
- if (!data->eventDispatcher)
+ if (!data->hasEventDispatcher())
return;
- data->eventDispatcher->processEvents(flags);
+ data->eventDispatcher.load()->processEvents(flags);
}
/*!
@@ -958,11 +1062,11 @@ void QCoreApplication::processEvents(QEventLoop::ProcessEventsFlags flags)
void QCoreApplication::processEvents(QEventLoop::ProcessEventsFlags flags, int maxtime)
{
QThreadData *data = QThreadData::current();
- if (!data->eventDispatcher)
+ if (!data->hasEventDispatcher())
return;
QElapsedTimer start;
start.start();
- while (data->eventDispatcher->processEvents(flags & ~QEventLoop::WaitForMoreEvents)) {
+ while (data->eventDispatcher.load()->processEvents(flags & ~QEventLoop::WaitForMoreEvents)) {
if (start.elapsed() > maxtime)
break;
}
@@ -1161,8 +1265,9 @@ void QCoreApplication::postEvent(QObject *receiver, QEvent *event, int priority)
data->canWait = false;
locker.unlock();
- if (data->eventDispatcher)
- data->eventDispatcher->wakeUp();
+ QAbstractEventDispatcher* dispatcher = data->eventDispatcher.loadAcquire();
+ if (dispatcher)
+ dispatcher->wakeUp();
}
/*!
@@ -1282,8 +1387,8 @@ void QCoreApplicationPrivate::sendPostedEvents(QObject *receiver, int event_type
}
--data->postEventList.recursion;
- if (!data->postEventList.recursion && !data->canWait && data->eventDispatcher)
- data->eventDispatcher->wakeUp();
+ if (!data->postEventList.recursion && !data->canWait && data->hasEventDispatcher())
+ data->eventDispatcher.load()->wakeUp();
// clear the global list, i.e. remove everything that was
// delivered.
@@ -1570,6 +1675,8 @@ void QCoreApplication::quit()
\sa quit()
*/
+#endif // QT_NO_QOBJECT
+
#ifndef QT_NO_TRANSLATION
/*!
Adds the translation file \a translationFile to the list of
@@ -1611,8 +1718,11 @@ bool QCoreApplication::installTranslator(QTranslator *translationFile)
return false;
#endif
+#ifndef QT_NO_QOBJECT
QEvent ev(QEvent::LanguageChange);
QCoreApplication::sendEvent(self, &ev);
+#endif
+
return true;
}
@@ -1634,10 +1744,12 @@ bool QCoreApplication::removeTranslator(QTranslator *translationFile)
return false;
QCoreApplicationPrivate *d = self->d_func();
if (d->translators.removeAll(translationFile)) {
+#ifndef QT_NO_QOBJECT
if (!self->closingDown()) {
QEvent ev(QEvent::LanguageChange);
QCoreApplication::sendEvent(self, &ev);
}
+#endif
return true;
}
return false;
@@ -1748,6 +1860,19 @@ bool QCoreApplicationPrivate::isTranslatorInstalled(QTranslator *translator)
&& QCoreApplication::self->d_func()->translators.contains(translator);
}
+#else
+
+QString QCoreApplication::translate(const char *context, const char *sourceText,
+ const char *disambiguation, int n)
+{
+ Q_UNUSED(context)
+ Q_UNUSED(disambiguation)
+ QString ret = QString::fromUtf8(sourceText);
+ if (n >= 0)
+ ret.replace(QLatin1String("%n"), QString::number(n));
+ return ret;
+}
+
#endif //QT_NO_TRANSLATE
/*!
@@ -1999,9 +2124,23 @@ QStringList QCoreApplication::arguments()
\sa organizationDomain, applicationName
*/
+/*!
+ \fn void QCoreApplication::organizationNameChanged()
+ \internal
+
+ While not useful from C++ due to how organizationName is normally set once on
+ startup, this is still needed for QML so that bindings are reevaluated after
+ that initial change.
+*/
void QCoreApplication::setOrganizationName(const QString &orgName)
{
+ if (coreappdata()->orgName == orgName)
+ return;
coreappdata()->orgName = orgName;
+#ifndef QT_NO_QOBJECT
+ if (QCoreApplication::self)
+ emit QCoreApplication::self->organizationNameChanged();
+#endif
}
QString QCoreApplication::organizationName()
@@ -2027,9 +2166,21 @@ QString QCoreApplication::organizationName()
\sa organizationName, applicationName, applicationVersion
*/
+/*!
+ \fn void QCoreApplication::organizationDomainChanged()
+ \internal
+
+ Primarily for QML, see organizationNameChanged.
+*/
void QCoreApplication::setOrganizationDomain(const QString &orgDomain)
{
+ if (coreappdata()->orgDomain == orgDomain)
+ return;
coreappdata()->orgDomain = orgDomain;
+#ifndef QT_NO_QOBJECT
+ if (QCoreApplication::self)
+ emit QCoreApplication::self->organizationDomainChanged();
+#endif
}
QString QCoreApplication::organizationDomain()
@@ -2049,9 +2200,21 @@ QString QCoreApplication::organizationDomain()
\sa organizationName, organizationDomain, applicationVersion, applicationFilePath
*/
+/*!
+ \fn void QCoreApplication::applicationNameChanged()
+ \internal
+
+ Primarily for QML, see organizationNameChanged.
+*/
void QCoreApplication::setApplicationName(const QString &application)
{
+ if (coreappdata()->application == application)
+ return;
coreappdata()->application = application;
+#ifndef QT_NO_QOBJECT
+ if (QCoreApplication::self)
+ emit QCoreApplication::self->applicationNameChanged();
+#endif
}
QString QCoreApplication::applicationName()
@@ -2078,9 +2241,21 @@ Q_CORE_EXPORT QString qt_applicationName_noFallback()
\sa applicationName, organizationName, organizationDomain
*/
+/*!
+ \fn void QCoreApplication::applicationVersionChanged()
+ \internal
+
+ Primarily for QML, see organizationNameChanged.
+*/
void QCoreApplication::setApplicationVersion(const QString &version)
{
+ if (coreappdata()->applicationVersion == version)
+ return;
coreappdata()->applicationVersion = version;
+#ifndef QT_NO_QOBJECT
+ if (QCoreApplication::self)
+ emit QCoreApplication::self->applicationVersionChanged();
+#endif
}
QString QCoreApplication::applicationVersion()
@@ -2229,6 +2404,8 @@ void QCoreApplication::removeLibraryPath(const QString &path)
#endif //QT_NO_LIBRARY
+#ifndef QT_NO_QOBJECT
+
/*!
Installs an event filter \a filterObj for all native events
received by the application in the main thread.
@@ -2324,6 +2501,33 @@ void QCoreApplication::setEventDispatcher(QAbstractEventDispatcher *eventDispatc
mainThread->setEventDispatcher(eventDispatcher);
}
+#endif // QT_NO_QOBJECT
+
+/*!
+ \macro Q_COREAPP_STARTUP_FUNCTION(QtStartUpFunction ptr)
+ \since 5.1
+ \relates QCoreApplication
+ \reentrant
+
+ Adds a global function that will be called from the QCoreApplication
+ constructor. This macro is normally used to initialize libraries
+ for program-wide functionality, without requiring the application to
+ call into the library for initialization.
+
+ The function specified by \a ptr should take no arguments and should
+ return nothing. For example:
+
+ \snippet code/src_corelib_kernel_qcoreapplication.cpp 3
+
+ Note that the startup function will run at the end of the QCoreApplication constructor,
+ before any GUI initialization. If GUI code is required in the function,
+ use a timer (or a queued invocation) to perform the initialization later on,
+ from the event loop.
+
+ If QCoreApplication is deleted and another QCoreApplication is created,
+ the startup function will be invoked again.
+*/
+
/*!
\fn void qAddPostRoutine(QtCleanUpFunction ptr)
\relates QCoreApplication
diff --git a/src/corelib/kernel/qcoreapplication.h b/src/corelib/kernel/qcoreapplication.h
index 0a87689ff3..ae17aeec0e 100644
--- a/src/corelib/kernel/qcoreapplication.h
+++ b/src/corelib/kernel/qcoreapplication.h
@@ -42,15 +42,21 @@
#ifndef QCOREAPPLICATION_H
#define QCOREAPPLICATION_H
+#include <QtCore/qglobal.h>
+#include <QtCore/qstring.h>
+#ifndef QT_NO_QOBJECT
#include <QtCore/qobject.h>
#include <QtCore/qcoreevent.h>
#include <QtCore/qeventloop.h>
+#else
+#include <QtCore/qscopedpointer.h>
+#endif
+#ifndef QT_NO_QOBJECT
#if defined(Q_OS_WIN) && !defined(tagMSG)
typedef struct tagMSG MSG;
#endif
-
-QT_BEGIN_HEADER
+#endif
QT_BEGIN_NAMESPACE
@@ -65,14 +71,19 @@ class QAbstractNativeEventFilter;
#define qApp QCoreApplication::instance()
-class Q_CORE_EXPORT QCoreApplication : public QObject
+class Q_CORE_EXPORT QCoreApplication
+#ifndef QT_NO_QOBJECT
+ : public QObject
+#endif
{
+#ifndef QT_NO_QOBJECT
Q_OBJECT
- Q_PROPERTY(QString applicationName READ applicationName WRITE setApplicationName)
- Q_PROPERTY(QString applicationVersion READ applicationVersion WRITE setApplicationVersion)
- Q_PROPERTY(QString organizationName READ organizationName WRITE setOrganizationName)
- Q_PROPERTY(QString organizationDomain READ organizationDomain WRITE setOrganizationDomain)
+ Q_PROPERTY(QString applicationName READ applicationName WRITE setApplicationName NOTIFY applicationNameChanged)
+ Q_PROPERTY(QString applicationVersion READ applicationVersion WRITE setApplicationVersion NOTIFY applicationVersionChanged)
+ Q_PROPERTY(QString organizationName READ organizationName WRITE setOrganizationName NOTIFY organizationNameChanged)
+ Q_PROPERTY(QString organizationDomain READ organizationDomain WRITE setOrganizationDomain NOTIFY organizationDomainChanged)
Q_PROPERTY(bool quitLockEnabled READ isQuitLockEnabled WRITE setQuitLockEnabled)
+#endif
Q_DECLARE_PRIVATE(QCoreApplication)
public:
@@ -103,6 +114,7 @@ public:
static QCoreApplication *instance() { return self; }
+#ifndef QT_NO_QOBJECT
static int exec();
static void processEvents(QEventLoop::ProcessEventsFlags flags = QEventLoop::AllEvents);
static void processEvents(QEventLoop::ProcessEventsFlags flags, int maxtime);
@@ -120,6 +132,7 @@ public:
static bool startingUp();
static bool closingDown();
+#endif
static QString applicationDirPath();
static QString applicationFilePath();
@@ -148,6 +161,7 @@ public:
{ return translate(context, key, disambiguation, n); }
#endif
+#ifndef QT_NO_QOBJECT
static void flush();
void installNativeEventFilter(QAbstractNativeEventFilter *filterObj);
@@ -166,17 +180,29 @@ Q_SIGNALS:
#endif
);
+ void organizationNameChanged();
+ void organizationDomainChanged();
+ void applicationNameChanged();
+ void applicationVersionChanged();
+
protected:
bool event(QEvent *);
virtual bool compressEvent(QEvent *, QObject *receiver, QPostEventList *);
+#endif // QT_NO_QOBJECT
protected:
QCoreApplication(QCoreApplicationPrivate &p);
+#ifdef QT_NO_QOBJECT
+ QScopedPointer<QCoreApplicationPrivate> d_ptr;
+#endif
+
private:
+#ifndef QT_NO_QOBJECT
static bool sendSpontaneousEvent(QObject *receiver, QEvent *event);
bool notifyInternal(QObject *receiver, QEvent *event);
+#endif
void init();
@@ -184,7 +210,6 @@ private:
Q_DISABLE_COPY(QCoreApplication)
- friend class QEventDispatcherUNIXPrivate;
friend class QApplication;
friend class QApplicationPrivate;
friend class QGuiApplication;
@@ -193,46 +218,59 @@ private:
friend class QWidget;
friend class QWidgetWindow;
friend class QWidgetPrivate;
+#ifndef QT_NO_QOBJECT
+ friend class QEventDispatcherUNIXPrivate;
friend class QCocoaEventDispatcherPrivate;
friend bool qt_sendSpontaneousEvent(QObject*, QEvent*);
+#endif
friend Q_CORE_EXPORT QString qAppName();
friend class QClassFactory;
};
+#ifndef QT_NO_QOBJECT
inline bool QCoreApplication::sendEvent(QObject *receiver, QEvent *event)
{ if (event) event->spont = false; return self ? self->notifyInternal(receiver, event) : false; }
inline bool QCoreApplication::sendSpontaneousEvent(QObject *receiver, QEvent *event)
{ if (event) event->spont = true; return self ? self->notifyInternal(receiver, event) : false; }
+#endif
-#ifdef QT_NO_TRANSLATION
-inline QString QCoreApplication::translate(const char *, const char *sourceText, const char *, int)
-{
- return QString::fromUtf8(sourceText);
-}
+#ifdef QT_NO_DEPRECATED
+# define QT_DECLARE_DEPRECATED_TR_FUNCTIONS(context)
+#else
+# define QT_DECLARE_DEPRECATED_TR_FUNCTIONS(context) \
+ QT_DEPRECATED static inline QString trUtf8(const char *sourceText, const char *disambiguation = 0, int n = -1) \
+ { return QCoreApplication::translate(#context, sourceText, disambiguation, n); }
#endif
#define Q_DECLARE_TR_FUNCTIONS(context) \
public: \
static inline QString tr(const char *sourceText, const char *disambiguation = 0, int n = -1) \
{ return QCoreApplication::translate(#context, sourceText, disambiguation, n); } \
- QT_DEPRECATED static inline QString trUtf8(const char *sourceText, const char *disambiguation = 0, int n = -1) \
- { return QCoreApplication::translate(#context, sourceText, disambiguation, n); } \
+ QT_DECLARE_DEPRECATED_TR_FUNCTIONS(context) \
private:
+typedef void (*QtStartUpFunction)();
typedef void (*QtCleanUpFunction)();
+Q_CORE_EXPORT void qAddPreRoutine(QtStartUpFunction);
Q_CORE_EXPORT void qAddPostRoutine(QtCleanUpFunction);
Q_CORE_EXPORT void qRemovePostRoutine(QtCleanUpFunction);
Q_CORE_EXPORT QString qAppName(); // get application name
+#define Q_COREAPP_STARTUP_FUNCTION(AFUNC) \
+ static void AFUNC ## _ctor_function() { \
+ qAddPreRoutine(AFUNC); \
+ } \
+ Q_CONSTRUCTOR_FUNCTION(AFUNC ## _ctor_function)
+
+#ifndef QT_NO_QOBJECT
#if defined(Q_OS_WIN) && !defined(QT_NO_DEBUG_STREAM)
Q_CORE_EXPORT QString decodeMSG(const MSG &);
Q_CORE_EXPORT QDebug operator<<(QDebug, const MSG &);
#endif
+#endif
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOREAPPLICATION_H
diff --git a/src/corelib/kernel/qcoreapplication_p.h b/src/corelib/kernel/qcoreapplication_p.h
index 36ba0663b7..563a3b2093 100644
--- a/src/corelib/kernel/qcoreapplication_p.h
+++ b/src/corelib/kernel/qcoreapplication_p.h
@@ -56,7 +56,9 @@
#include "QtCore/qcoreapplication.h"
#include "QtCore/qtranslator.h"
#include "QtCore/qsettings.h"
+#ifndef QT_NO_QOBJECT
#include "private/qobject_p.h"
+#endif
QT_BEGIN_NAMESPACE
@@ -64,7 +66,10 @@ typedef QList<QTranslator*> QTranslatorList;
class QAbstractEventDispatcher;
-class Q_CORE_EXPORT QCoreApplicationPrivate : public QObjectPrivate
+class Q_CORE_EXPORT QCoreApplicationPrivate
+#ifndef QT_NO_QOBJECT
+ : public QObjectPrivate
+#endif
{
Q_DECLARE_PUBLIC(QCoreApplication)
@@ -77,23 +82,27 @@ public:
QCoreApplicationPrivate(int &aargc, char **aargv, uint flags);
~QCoreApplicationPrivate();
+ QString appName() const;
+
+#ifdef Q_OS_MAC
+ static QString macMenuBarName();
+#endif
+
+ static void initLocale();
+
+ static bool checkInstance(const char *method);
+
+#ifndef QT_NO_QOBJECT
bool sendThroughApplicationEventFilters(QObject *, QEvent *);
bool sendThroughObjectEventFilters(QObject *, QEvent *);
bool notify_helper(QObject *, QEvent *);
- QString appName() const;
virtual void createEventDispatcher();
static void removePostedEvent(QEvent *);
#ifdef Q_OS_WIN
static void removePostedTimerEvent(QObject *object, int timerId);
#endif
-#ifdef Q_OS_MAC
- static QString macMenuBarName();
-#endif
-
- static void initLocale();
-
QAtomicInt quitLockRef;
void ref();
void deref();
@@ -104,12 +113,14 @@ public:
static QThread *theMainThread;
static QThread *mainThread();
- static bool checkInstance(const char *method);
static void sendPostedEvents(QObject *receiver, int event_type, QThreadData *data);
#if !defined (QT_NO_DEBUG) || defined (QT_MAC_FRAMEWORK_BUILD)
void checkReceiverThread(QObject *receiver);
#endif
+ void cleanupThreadData();
+#endif // QT_NO_QOBJECT
+
int &argc;
char **argv;
#ifdef Q_OS_WIN
@@ -117,24 +128,27 @@ public:
char **origArgv; // store unmodified arguments for QCoreApplication::arguments()
#endif
void appendApplicationPathToLibraryPaths(void);
- void cleanupThreadData();
#ifndef QT_NO_TRANSLATION
QTranslatorList translators;
+
+ static bool isTranslatorInstalled(QTranslator *translator);
#endif
+
uint application_type;
- bool in_exec;
- bool aboutToQuitEmitted;
- bool threadData_clean;
QString cachedApplicationDirPath;
QString cachedApplicationFilePath;
- static bool isTranslatorInstalled(QTranslator *translator);
+#ifndef QT_NO_QOBJECT
+ bool in_exec;
+ bool aboutToQuitEmitted;
+ bool threadData_clean;
static QAbstractEventDispatcher *eventDispatcher;
static bool is_app_running;
static bool is_app_closing;
+#endif
static uint attribs;
static inline bool testAttribute(uint flag) { return attribs & (1 << flag); }
@@ -143,6 +157,10 @@ public:
void processCommandLineArguments();
QString qmljs_debug_arguments; // a string containing arguments for js/qml debugging.
inline QString qmljsDebugArgumentsString() { return qmljs_debug_arguments; }
+
+#ifdef QT_NO_QOBJECT
+ QCoreApplication *q_ptr;
+#endif
};
QT_END_NAMESPACE
diff --git a/src/corelib/kernel/qcoreapplication_win.cpp b/src/corelib/kernel/qcoreapplication_win.cpp
index 3cb89e8fcd..93e45d3984 100644
--- a/src/corelib/kernel/qcoreapplication_win.cpp
+++ b/src/corelib/kernel/qcoreapplication_win.cpp
@@ -43,10 +43,12 @@
#include "qcoreapplication_p.h"
#include "qstringlist.h"
#include "qvector.h"
-#include "qmutex.h"
#include "qfileinfo.h"
#include "qcorecmdlineargs_p.h"
+#ifndef QT_NO_QOBJECT
+#include "qmutex.h"
#include <private/qthread_p.h>
+#endif
#include <ctype.h>
#include <qt_windows.h>
@@ -157,6 +159,8 @@ void qWinMain(HINSTANCE instance, HINSTANCE prevInstance, LPSTR cmdParam,
Q_UNUSED(prevInstance);
}
+#ifndef QT_NO_QOBJECT
+
void QCoreApplicationPrivate::removePostedTimerEvent(QObject *object, int timerId)
{
QThreadData *data = object->d_func()->threadData;
@@ -996,4 +1000,6 @@ QDebug operator<<(QDebug dbg, const MSG &msg)
}
#endif
+#endif // QT_NO_QOBJECT
+
QT_END_NAMESPACE
diff --git a/src/corelib/kernel/qcoreevent.cpp b/src/corelib/kernel/qcoreevent.cpp
index 7f91d61189..09fe7c60ca 100644
--- a/src/corelib/kernel/qcoreevent.cpp
+++ b/src/corelib/kernel/qcoreevent.cpp
@@ -98,12 +98,13 @@ QT_BEGIN_NAMESPACE
\value ActionChanged An action has been changed (QActionEvent).
\value ActionRemoved An action has been removed (QActionEvent).
\value ActivationChange A widget's top-level window activation state has changed.
- \value ApplicationActivate The application has been made available to the user.
- \value ApplicationActivated This enum has been deprecated. Use ApplicationActivate instead.
- \value ApplicationDeactivate The application has been suspended, and is unavailable to the user.
+ \value ApplicationActivate This enum has been deprecated. Use ApplicationStateChange instead.
+ \value ApplicationActivated This enum has been deprecated. Use ApplicationStateChange instead.
+ \value ApplicationDeactivate This enum has been deprecated. Use ApplicationStateChange instead.
\value ApplicationFontChange The default application font has changed.
\value ApplicationLayoutDirectionChange The default application layout direction has changed.
\value ApplicationPaletteChange The default application palette has changed.
+ \value ApplicationStateChange The state of the application has changed.
\value ApplicationWindowIconChange The application's icon has changed.
\value ChildAdded An object gets a child (QChildEvent).
\value ChildPolished A widget child gets polished (QChildEvent).
@@ -264,7 +265,9 @@ QT_BEGIN_NAMESPACE
\omitvalue Style
\omitvalue StyleAnimationUpdate
\omitvalue ZeroTimerEvent
+ \omitvalue ApplicationActivate
\omitvalue ApplicationActivated
+ \omitvalue ApplicationDeactivate
\omitvalue ApplicationDeactivated
\omitvalue MacGLWindowChange
\omitvalue MacGLClearDrawable
diff --git a/src/corelib/kernel/qcoreevent.h b/src/corelib/kernel/qcoreevent.h
index d35b5198a9..2ca0a7d0b0 100644
--- a/src/corelib/kernel/qcoreevent.h
+++ b/src/corelib/kernel/qcoreevent.h
@@ -46,8 +46,6 @@
#include <QtCore/qbytearray.h>
#include <QtCore/qobjectdefs.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -169,9 +167,9 @@ public:
ToolBarChange = 120, // toolbar visibility toggled
- ApplicationActivate = 121, // application has been changed to active
+ ApplicationActivate = 121, // deprecated. Use ApplicationStateChange instead.
ApplicationActivated = ApplicationActivate, // deprecated
- ApplicationDeactivate = 122, // application has been changed to inactive
+ ApplicationDeactivate = 122, // deprecated. Use ApplicationStateChange instead.
ApplicationDeactivated = ApplicationDeactivate, // deprecated
QueryWhatsThis = 123, // query what's this widget help
@@ -278,6 +276,7 @@ public:
PlatformPanel = 212,
StyleAnimationUpdate = 213, // style animation target should be updated
+ ApplicationStateChange = 214,
// 512 reserved for Qt Jambi's MetaCall event
// 513 reserved for Qt Jambi's DeleteOnMainThread event
@@ -377,6 +376,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOREEVENT_H
diff --git a/src/corelib/kernel/qeventdispatcher_blackberry.cpp b/src/corelib/kernel/qeventdispatcher_blackberry.cpp
index 3e958ee277..5206334c09 100644
--- a/src/corelib/kernel/qeventdispatcher_blackberry.cpp
+++ b/src/corelib/kernel/qeventdispatcher_blackberry.cpp
@@ -271,13 +271,13 @@ void QEventDispatcherBlackberry::unregisterSocketNotifier(QSocketNotifier *notif
}
}
-static inline int timevalToMillisecs(const timeval &tv)
+static inline int timespecToMillisecs(const timespec &tv)
{
- return (tv.tv_sec * 1000) + (tv.tv_usec / 1000);
+ return (tv.tv_sec * 1000) + (tv.tv_nsec / 1000000);
}
int QEventDispatcherBlackberry::select(int nfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds,
- timeval *timeout)
+ timespec *timeout)
{
Q_UNUSED(nfds);
Q_D(QEventDispatcherBlackberry);
@@ -306,9 +306,9 @@ int QEventDispatcherBlackberry::select(int nfds, fd_set *readfds, fd_set *writef
// Convert timeout to milliseconds
int timeoutTotal = -1;
if (timeout)
- timeoutTotal = timevalToMillisecs(*timeout);
+ timeoutTotal = timespecToMillisecs(*timeout);
int timeoutLeft = timeoutTotal;
- timeval startTime = qt_gettime();
+ timespec startTime = qt_gettime();
// This loop exists such that we can drain the bps event queue of all native events
// more efficiently than if we were to return control to Qt after each event. This
@@ -332,16 +332,16 @@ int QEventDispatcherBlackberry::select(int nfds, fd_set *readfds, fd_set *writef
// Update the timeout
// Clock source is monotonic, so we can recalculate how much timeout is left
if (timeoutTotal != -1) {
- timeval t2 = qt_gettime();
+ timespec t2 = qt_gettime();
timeoutLeft = timeoutTotal
- - (timevalToMillisecs(t2) - timevalToMillisecs(startTime));
+ - (timespecToMillisecs(t2) - timespecToMillisecs(startTime));
if (timeoutLeft < 0)
timeoutLeft = 0;
}
- timeval tnext;
+ timespec tnext;
if (d->timerList.timerWait(tnext)) {
- int timeoutNext = timevalToMillisecs(tnext);
+ int timeoutNext = timespecToMillisecs(tnext);
if (timeoutNext < timeoutLeft || timeoutTotal == -1) {
timeoutTotal = timeoutLeft = timeoutNext;
startTime = qt_gettime();
diff --git a/src/corelib/kernel/qeventdispatcher_blackberry_p.h b/src/corelib/kernel/qeventdispatcher_blackberry_p.h
index 79ed21dbf2..5a4c3a9dcd 100644
--- a/src/corelib/kernel/qeventdispatcher_blackberry_p.h
+++ b/src/corelib/kernel/qeventdispatcher_blackberry_p.h
@@ -77,7 +77,7 @@ protected:
QEventDispatcherBlackberry(QEventDispatcherBlackberryPrivate &dd, QObject *parent = 0);
int select(int nfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds,
- timeval *timeout);
+ timespec *timeout);
int ioEvents(int fd);
};
diff --git a/src/corelib/kernel/qeventdispatcher_glib.cpp b/src/corelib/kernel/qeventdispatcher_glib.cpp
index c6680d6a80..e87e830c39 100644
--- a/src/corelib/kernel/qeventdispatcher_glib.cpp
+++ b/src/corelib/kernel/qeventdispatcher_glib.cpp
@@ -131,9 +131,9 @@ struct GTimerSource
static gboolean timerSourcePrepareHelper(GTimerSource *src, gint *timeout)
{
- timeval tv = { 0l, 0l };
+ timespec tv = { 0l, 0l };
if (!(src->processEventsFlags & QEventLoop::X11ExcludeTimers) && src->timerList.timerWait(tv))
- *timeout = (tv.tv_sec * 1000) + ((tv.tv_usec + 999) / 1000);
+ *timeout = (tv.tv_sec * 1000) + ((tv.tv_nsec + 999999) / 1000 / 1000);
else
*timeout = -1;
@@ -259,10 +259,11 @@ static gboolean postEventSourcePrepare(GSource *s, gint *timeout)
gint dummy;
if (!timeout)
timeout = &dummy;
- *timeout = data->canWait ? -1 : 0;
+ const bool canWait = data->canWaitLocked();
+ *timeout = canWait ? -1 : 0;
GPostEventSource *source = reinterpret_cast<GPostEventSource *>(s);
- return (!data->canWait
+ return (!canWait
|| (source->serialNumber.load() != source->lastSerialNumber));
}
@@ -293,12 +294,14 @@ static GSourceFuncs postEventSourceFuncs = {
QEventDispatcherGlibPrivate::QEventDispatcherGlibPrivate(GMainContext *context)
: mainContext(context)
{
+#if GLIB_MAJOR_VERSION == 2 && GLIB_MINOR_VERSION < 32
if (qEnvironmentVariableIsEmpty("QT_NO_THREADED_GLIB")) {
static QBasicMutex mutex;
QMutexLocker locker(&mutex);
if (!g_thread_supported())
g_thread_init(NULL);
}
+#endif
if (mainContext) {
g_main_context_ref(mainContext);
diff --git a/src/corelib/kernel/qeventdispatcher_unix.cpp b/src/corelib/kernel/qeventdispatcher_unix.cpp
index acdc7635e8..69363bc3c9 100644
--- a/src/corelib/kernel/qeventdispatcher_unix.cpp
+++ b/src/corelib/kernel/qeventdispatcher_unix.cpp
@@ -56,6 +56,10 @@
#include <stdio.h>
#include <stdlib.h>
+#ifndef QT_NO_EVENTFD
+# include <sys/eventfd.h>
+#endif
+
// VxWorks doesn't correctly set the _POSIX_... options
#if defined(Q_OS_VXWORKS)
# if defined(_POSIX_MONOTONIC_CLOCK) && (_POSIX_MONOTONIC_CLOCK <= 0)
@@ -109,7 +113,7 @@ QEventDispatcherUNIXPrivate::QEventDispatcherUNIXPrivate()
}
#elif defined(Q_OS_VXWORKS)
char name[20];
- qsnprintf(name, sizeof(name), "/pipe/qt_%08x", int(taskIdCurrent));
+ qsnprintf(name, sizeof(name), "/pipe/qt_%08x", int(taskIdSelf()));
// make sure there is no pipe with this name
pipeDevDelete(name, true);
@@ -127,6 +131,12 @@ QEventDispatcherUNIXPrivate::QEventDispatcherUNIXPrivate()
}
}
#else
+# ifndef QT_NO_EVENTFD
+ thread_pipe[0] = eventfd(0, EFD_NONBLOCK | EFD_CLOEXEC);
+ if (thread_pipe[0] != -1)
+ thread_pipe[1] = -1;
+ else // fall through the next "if"
+# endif
if (qt_safe_pipe(thread_pipe, O_NONBLOCK) == -1) {
perror("QEventDispatcherUNIXPrivate(): Unable to create thread pipe");
pipefail = true;
@@ -137,8 +147,6 @@ QEventDispatcherUNIXPrivate::QEventDispatcherUNIXPrivate()
qFatal("QEventDispatcherUNIXPrivate(): Can not continue without a thread pipe");
sn_highest = -1;
-
- interrupt = false;
}
QEventDispatcherUNIXPrivate::~QEventDispatcherUNIXPrivate()
@@ -149,20 +157,21 @@ QEventDispatcherUNIXPrivate::~QEventDispatcherUNIXPrivate()
close(thread_pipe[0]);
char name[20];
- qsnprintf(name, sizeof(name), "/pipe/qt_%08x", int(taskIdCurrent));
+ qsnprintf(name, sizeof(name), "/pipe/qt_%08x", int(taskIdSelf()));
pipeDevDelete(name, true);
#else
// cleanup the common parts of the event loop
close(thread_pipe[0]);
- close(thread_pipe[1]);
+ if (thread_pipe[1] != -1)
+ close(thread_pipe[1]);
#endif
// cleanup timers
qDeleteAll(timerList);
}
-int QEventDispatcherUNIXPrivate::doSelect(QEventLoop::ProcessEventsFlags flags, timeval *timeout)
+int QEventDispatcherUNIXPrivate::doSelect(QEventLoop::ProcessEventsFlags flags, timespec *timeout)
{
Q_Q(QEventDispatcherUNIX);
@@ -279,9 +288,18 @@ int QEventDispatcherUNIXPrivate::processThreadWakeUp(int nsel)
::read(thread_pipe[0], c, sizeof(c));
::ioctl(thread_pipe[0], FIOFLUSH, 0);
#else
- char c[16];
- while (::read(thread_pipe[0], c, sizeof(c)) > 0)
- ;
+# ifndef QT_NO_EVENTFD
+ if (thread_pipe[1] == -1) {
+ // eventfd
+ eventfd_t value;
+ eventfd_read(thread_pipe[0], &value);
+ } else
+# endif
+ {
+ char c[16];
+ while (::read(thread_pipe[0], c, sizeof(c)) > 0) {
+ }
+ }
#endif
if (!wakeUps.testAndSetRelease(1, 0)) {
// hopefully, this is dead code
@@ -302,12 +320,10 @@ QEventDispatcherUNIX::QEventDispatcherUNIX(QEventDispatcherUNIXPrivate &dd, QObj
QEventDispatcherUNIX::~QEventDispatcherUNIX()
{
- Q_D(QEventDispatcherUNIX);
- d->threadData->eventDispatcher = 0;
}
int QEventDispatcherUNIX::select(int nfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds,
- timeval *timeout)
+ timespec *timeout)
{
return qt_safe_select(nfds, readfds, writefds, exceptfds, timeout);
}
@@ -564,24 +580,24 @@ int QEventDispatcherUNIX::activateSocketNotifiers()
bool QEventDispatcherUNIX::processEvents(QEventLoop::ProcessEventsFlags flags)
{
Q_D(QEventDispatcherUNIX);
- d->interrupt = false;
+ d->interrupt.store(0);
// we are awake, broadcast it
emit awake();
QCoreApplicationPrivate::sendPostedEvents(0, 0, d->threadData);
int nevents = 0;
- const bool canWait = (d->threadData->canWait
- && !d->interrupt
+ const bool canWait = (d->threadData->canWaitLocked()
+ && !d->interrupt.load()
&& (flags & QEventLoop::WaitForMoreEvents));
if (canWait)
emit aboutToBlock();
- if (!d->interrupt) {
+ if (!d->interrupt.load()) {
// return the maximum time we can wait for an event.
- timeval *tm = 0;
- timeval wait_tm = { 0l, 0l };
+ timespec *tm = 0;
+ timespec wait_tm = { 0l, 0l };
if (!(flags & QEventLoop::X11ExcludeTimers)) {
if (d->timerList.timerWait(wait_tm))
tm = &wait_tm;
@@ -593,7 +609,7 @@ bool QEventDispatcherUNIX::processEvents(QEventLoop::ProcessEventsFlags flags)
// no time to wait
tm->tv_sec = 0l;
- tm->tv_usec = 0l;
+ tm->tv_nsec = 0l;
}
nevents = d->doSelect(flags, tm);
@@ -630,6 +646,15 @@ void QEventDispatcherUNIX::wakeUp()
{
Q_D(QEventDispatcherUNIX);
if (d->wakeUps.testAndSetAcquire(0, 1)) {
+#ifndef QT_NO_EVENTFD
+ if (d->thread_pipe[1] == -1) {
+ // eventfd
+ eventfd_t value = 1;
+ int ret;
+ EINTR_LOOP(ret, eventfd_write(d->thread_pipe[0], value));
+ return;
+ }
+#endif
char c = 0;
qt_safe_write( d->thread_pipe[1], &c, 1 );
}
@@ -638,7 +663,7 @@ void QEventDispatcherUNIX::wakeUp()
void QEventDispatcherUNIX::interrupt()
{
Q_D(QEventDispatcherUNIX);
- d->interrupt = true;
+ d->interrupt.store(1);
wakeUp();
}
diff --git a/src/corelib/kernel/qeventdispatcher_unix_p.h b/src/corelib/kernel/qeventdispatcher_unix_p.h
index afebe2fb7e..5d69d5e396 100644
--- a/src/corelib/kernel/qeventdispatcher_unix_p.h
+++ b/src/corelib/kernel/qeventdispatcher_unix_p.h
@@ -61,9 +61,7 @@
#include "QtCore/qvarlengtharray.h"
#include "private/qtimerinfo_unix_p.h"
-#if defined(Q_OS_VXWORKS)
-# include <sys/times.h>
-#else
+#if !defined(Q_OS_VXWORKS)
# include <sys/time.h>
# if (!defined(Q_OS_HPUX) || defined(__ia64)) && !defined(Q_OS_NACL)
# include <sys/select.h>
@@ -132,7 +130,7 @@ protected:
virtual int select(int nfds,
fd_set *readfds, fd_set *writefds, fd_set *exceptfds,
- timeval *timeout);
+ timespec *timeout);
};
class Q_CORE_EXPORT QEventDispatcherUNIXPrivate : public QAbstractEventDispatcherPrivate
@@ -143,11 +141,14 @@ public:
QEventDispatcherUNIXPrivate();
~QEventDispatcherUNIXPrivate();
- int doSelect(QEventLoop::ProcessEventsFlags flags, timeval *timeout);
+ int doSelect(QEventLoop::ProcessEventsFlags flags, timespec *timeout);
virtual int initThreadWakeUp();
virtual int processThreadWakeUp(int nsel);
bool mainThread;
+
+ // note for eventfd(7) support:
+ // if thread_pipe[1] is -1, then eventfd(7) is in use and is stored in thread_pipe[0]
int thread_pipe[2];
// highest fd for all socket notifiers
@@ -161,7 +162,7 @@ public:
QSockNotType::List sn_pending_list;
QAtomicInt wakeUps;
- bool interrupt;
+ QAtomicInt interrupt; // bool
};
QT_END_NAMESPACE
diff --git a/src/corelib/kernel/qeventloop.cpp b/src/corelib/kernel/qeventloop.cpp
index fe254b5593..3cb6890821 100644
--- a/src/corelib/kernel/qeventloop.cpp
+++ b/src/corelib/kernel/qeventloop.cpp
@@ -103,7 +103,7 @@ QEventLoop::QEventLoop(QObject *parent)
Q_D(QEventLoop);
if (!QCoreApplication::instance()) {
qWarning("QEventLoop: Cannot be used without QApplication");
- } else if (!d->threadData->eventDispatcher) {
+ } else if (!d->threadData->eventDispatcher.load()) {
QThreadPrivate::createEventDispatcher(d->threadData);
}
}
@@ -131,9 +131,9 @@ QEventLoop::~QEventLoop()
bool QEventLoop::processEvents(ProcessEventsFlags flags)
{
Q_D(QEventLoop);
- if (!d->threadData->eventDispatcher)
+ if (!d->threadData->eventDispatcher.load())
return false;
- return d->threadData->eventDispatcher->processEvents(flags);
+ return d->threadData->eventDispatcher.load()->processEvents(flags);
}
/*!
@@ -180,7 +180,7 @@ int QEventLoop::exec(ProcessEventsFlags flags)
LoopReference(QEventLoopPrivate *d, QMutexLocker &locker) : d(d), locker(locker), exceptionCaught(true)
{
d->inExec = true;
- d->exit = false;
+ d->exit.storeRelease(false);
++d->threadData->loopLevel;
d->threadData->eventLoops.push(d->q_func());
locker.unlock();
@@ -208,11 +208,11 @@ int QEventLoop::exec(ProcessEventsFlags flags)
if (app && app->thread() == thread())
QCoreApplication::removePostedEvents(app, QEvent::Quit);
- while (!d->exit)
+ while (!d->exit.loadAcquire())
processEvents(flags | WaitForMoreEvents | EventLoopExec);
ref.exceptionCaught = false;
- return d->returnCode;
+ return d->returnCode.load();
}
/*!
@@ -234,7 +234,7 @@ int QEventLoop::exec(ProcessEventsFlags flags)
void QEventLoop::processEvents(ProcessEventsFlags flags, int maxTime)
{
Q_D(QEventLoop);
- if (!d->threadData->eventDispatcher)
+ if (!d->threadData->eventDispatcher.load())
return;
QElapsedTimer start;
@@ -263,12 +263,12 @@ void QEventLoop::processEvents(ProcessEventsFlags flags, int maxTime)
void QEventLoop::exit(int returnCode)
{
Q_D(QEventLoop);
- if (!d->threadData->eventDispatcher)
+ if (!d->threadData->eventDispatcher.load())
return;
- d->returnCode = returnCode;
- d->exit = true;
- d->threadData->eventDispatcher->interrupt();
+ d->returnCode.store(returnCode);
+ d->exit.storeRelease(true);
+ d->threadData->eventDispatcher.load()->interrupt();
}
/*!
@@ -281,7 +281,7 @@ void QEventLoop::exit(int returnCode)
bool QEventLoop::isRunning() const
{
Q_D(const QEventLoop);
- return !d->exit;
+ return !d->exit.loadAcquire();
}
/*!
@@ -292,9 +292,9 @@ bool QEventLoop::isRunning() const
void QEventLoop::wakeUp()
{
Q_D(QEventLoop);
- if (!d->threadData->eventDispatcher)
+ if (!d->threadData->eventDispatcher.load())
return;
- d->threadData->eventDispatcher->wakeUp();
+ d->threadData->eventDispatcher.load()->wakeUp();
}
diff --git a/src/corelib/kernel/qeventloop.h b/src/corelib/kernel/qeventloop.h
index d4141a05bc..926be08265 100644
--- a/src/corelib/kernel/qeventloop.h
+++ b/src/corelib/kernel/qeventloop.h
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -106,6 +104,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QEVENTLOOP_H
diff --git a/src/corelib/kernel/qeventloop_p.h b/src/corelib/kernel/qeventloop_p.h
index 21a1dcda4c..30c61ca759 100644
--- a/src/corelib/kernel/qeventloop_p.h
+++ b/src/corelib/kernel/qeventloop_p.h
@@ -44,8 +44,6 @@
#include "qobject_p.h"
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QEventLoopPrivate : public QObjectPrivate
@@ -53,13 +51,17 @@ class QEventLoopPrivate : public QObjectPrivate
Q_DECLARE_PUBLIC(QEventLoop)
public:
inline QEventLoopPrivate()
- : exit(true), inExec(false), returnCode(-1)
- { }
+ : inExec(false)
+ {
+ returnCode.store(-1);
+ exit.store(true);
+ }
QAtomicInt quitLockRef;
- bool exit, inExec;
- int returnCode;
+ QBasicAtomicInt exit; // bool
+ QBasicAtomicInt returnCode;
+ bool inExec;
void ref()
{
@@ -76,6 +78,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QEVENTLOOP_P_H
diff --git a/src/corelib/kernel/qfunctions_nacl.h b/src/corelib/kernel/qfunctions_nacl.h
index 2cb9d16c95..c15b9756d0 100644
--- a/src/corelib/kernel/qfunctions_nacl.h
+++ b/src/corelib/kernel/qfunctions_nacl.h
@@ -42,6 +42,8 @@
#ifndef QFUNCTIONS_NACL_H
#define QFUNCTIONS_NACL_H
+#include <QtCore/qglobal.h>
+
#ifdef Q_OS_NACL
#include <sys/types.h>
@@ -52,8 +54,6 @@
#define PTHREAD_CANCEL_ENABLE 2
#define PTHREAD_INHERIT_SCHED 3
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -69,7 +69,7 @@ int pthread_cancel(pthread_t thread);
int pthread_attr_setinheritsched(pthread_attr_t *attr,
int inheritsched);
-int pthread_attr_getinheritsched(const pthread_attr_t *attr,
+int pthread_attr_getinheritsched(const pthread_attr_t *attr,
int *inheritsched);
// event dispatcher, select
@@ -89,8 +89,6 @@ int select(int nfds, fd_set * readfds, fd_set * writefds, fd_set * errorfds, str
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //Q_OS_NACL
#endif //QFUNCTIONS_NACL_H
diff --git a/src/corelib/kernel/qfunctions_p.h b/src/corelib/kernel/qfunctions_p.h
index 57c6a8f295..6e094f1ed3 100644
--- a/src/corelib/kernel/qfunctions_p.h
+++ b/src/corelib/kernel/qfunctions_p.h
@@ -72,8 +72,5 @@
# define Q_STATIC_GLOBAL_INLINE_OPERATOR static inline
#endif
-QT_BEGIN_HEADER
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/kernel/qfunctions_vxworks.cpp b/src/corelib/kernel/qfunctions_vxworks.cpp
index 2174588757..e1abecb9d6 100644
--- a/src/corelib/kernel/qfunctions_vxworks.cpp
+++ b/src/corelib/kernel/qfunctions_vxworks.cpp
@@ -46,7 +46,9 @@
#include "qplatformdefs.h"
#include "qfunctions_vxworks.h"
+#if defined(_WRS_KERNEL)
#include <vmLib.h>
+#endif
#include <selectLib.h>
#include <ioLib.h>
@@ -74,10 +76,12 @@ void *lfind(const void* key, const void* base, size_t* elements, size_t size,
// no rand_r(), but rand()
// NOTE: this implementation is wrong for multi threaded applications,
// but there is no way to get it right on VxWorks (in kernel mode)
+#if defined(_WRS_KERNEL)
int rand_r(unsigned int * /*seedp*/)
{
return rand();
}
+#endif
// no usleep() support
int usleep(unsigned int usec)
@@ -92,7 +96,7 @@ int usleep(unsigned int usec)
// gettimeofday() is declared, but is missing from the library
// It IS however defined in the Curtis-Wright X11 libraries, so
// we have to make the symbol 'weak'
-#if defined(Q_CC_DIAB)
+#if defined(Q_CC_DIAB) && !defined(VXWORKS_DKM) && !defined(VXWORKS_RTP)
# pragma weak gettimeofday
#endif
int gettimeofday(struct timeval *tv, void /*struct timezone*/ *)
@@ -118,7 +122,11 @@ int gettimeofday(struct timeval *tv, void /*struct timezone*/ *)
// neither getpagesize() or sysconf(_SC_PAGESIZE) are available
int getpagesize()
{
+#if defined(_WRS_KERNEL)
return vmPageSizeGet();
+#else
+ return sysconf(_SC_PAGESIZE);
+#endif
}
// symlinks are not supported (lstat is now just a call to stat - see qplatformdefs.h)
diff --git a/src/corelib/kernel/qfunctions_vxworks.h b/src/corelib/kernel/qfunctions_vxworks.h
index 6339903cff..e33401a86a 100644
--- a/src/corelib/kernel/qfunctions_vxworks.h
+++ b/src/corelib/kernel/qfunctions_vxworks.h
@@ -41,6 +41,9 @@
#ifndef QFUNCTIONS_VXWORKS_H
#define QFUNCTIONS_VXWORKS_H
+
+#include <QtCore/qglobal.h>
+
#ifdef Q_OS_VXWORKS
#include <unistd.h>
@@ -52,7 +55,11 @@
#include <errno.h>
#include <sys/types.h>
#include <sys/ioctl.h>
+#if defined(_WRS_KERNEL)
#include <sys/times.h>
+#else
+#include <sys/time.h>
+#endif
#include <sys/socket.h>
#include <sys/stat.h>
#include <sys/wait.h>
@@ -61,15 +68,50 @@
#include <net/if.h>
#endif
-QT_BEGIN_HEADER
+// VxWorks has public header mbuf.h which defines following variables for DKM.
+// Let's undef those to because they overlap with Qt variable names-
+// File mbuf.h is included in headers <netinet/in.h> <net/if.h>, so make sure
+// that those are included before undef's.
+#if defined(mbuf)
+# undef mbuf
+#endif
+#if defined(m_data)
+# undef m_data
+#endif
+#if defined(m_type)
+# undef m_type
+#endif
+#if defined(m_next)
+# undef m_next
+#endif
+#if defined(m_len)
+# undef m_len
+#endif
+#if defined(m_flags)
+# undef m_flags
+#endif
+#if defined(m_hdr)
+# undef m_hdr
+#endif
+#if defined(m_ext)
+# undef m_ext
+#endif
+#if defined(m_act)
+# undef m_act
+#endif
+#if defined(m_nextpkt)
+# undef m_nextpkt
+#endif
+#if defined(m_pkthdr)
+# undef m_pkthdr
+#endif
+
QT_BEGIN_NAMESPACE
#ifdef QT_BUILD_CORE_LIB
#endif
QT_END_NAMESPACE
-QT_END_HEADER
-
#ifndef RTLD_LOCAL
#define RTLD_LOCAL 0
@@ -95,17 +137,23 @@ void *lfind(const void* key, const void* base, size_t* elements, size_t size,
// no rand_r(), but rand()
// NOTE: this implementation is wrong for multi threaded applications,
// but there is no way to get it right on VxWorks (in kernel mode)
+#if defined(_WRS_KERNEL)
int rand_r(unsigned int * /*seedp*/);
+#endif
// no usleep() support
int usleep(unsigned int);
+#if defined(VXWORKS_DKM) || defined(VXWORKS_RTP)
+int gettimeofday(struct timeval *, void *);
+#else
// gettimeofday() is declared, but is missing from the library.
// It IS however defined in the Curtis-Wright X11 libraries, so
// we have to make the symbol 'weak'
int gettimeofday(struct timeval *tv, void /*struct timezone*/ *) __attribute__((weak));
+#endif
-// neither getpagesize() or sysconf(_SC_PAGESIZE) are available
+// getpagesize() not available
int getpagesize();
// symlinks are not supported (lstat is now just a call to stat - see qplatformdefs.h)
diff --git a/src/corelib/kernel/qfunctions_wince.h b/src/corelib/kernel/qfunctions_wince.h
index e20a4ceaca..ab7bbe3f99 100644
--- a/src/corelib/kernel/qfunctions_wince.h
+++ b/src/corelib/kernel/qfunctions_wince.h
@@ -41,6 +41,9 @@
#ifndef QFUNCTIONS_WINCE_H
#define QFUNCTIONS_WINCE_H
+
+#include <QtCore/qglobal.h>
+
#ifdef Q_OS_WINCE
#include <stdio.h>
#include <stdlib.h>
@@ -56,15 +59,12 @@
#include <winsock.h>
#include <ceconfig.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
#ifdef QT_BUILD_CORE_LIB
#endif
QT_END_NAMESPACE
-QT_END_HEADER
-
// The standard SDK misses this define...
#define _control87 _controlfp
diff --git a/src/corelib/kernel/qmath.cpp b/src/corelib/kernel/qmath.cpp
index 1d6fcc2cd6..8f900e2101 100644
--- a/src/corelib/kernel/qmath.cpp
+++ b/src/corelib/kernel/qmath.cpp
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2013 Laszlo Papp <lpapp@kde.org>
** Contact: http://www.qt-project.org/legal
**
** This file is part of the QtCore module of the Qt Toolkit.
@@ -302,4 +303,90 @@ const qreal qt_sine_table[QT_SINE_TABLE_SIZE] = {
qreal(-0.024541228522912448)
};
+/*!
+ \headerfile <QtMath>
+ \title Generic Math Declarations
+ \ingroup funclists
+
+ \brief The <QtMath> header file includes generic math declarations.
+
+ The global declarations include \l{functions}.
+
+ These functions are partly convenience definitions for basic
+ operations, for instance not available in the Standard Template Library et
+ al.
+*/
+
+/*!
+ \fn float qDegreesToRadians(float degrees)
+ \relates <QtMath>
+ \since 5.1
+
+ \brief The function converts the \a degrees in float to radians.
+
+ The purpose of the function is to aid the conversion as such a convenient
+ function is not part of the Standard Template Library, i.e. in <cmath> or
+ elsewhere.
+
+ Example:
+
+ \snippet code/src_corelib_kernel_qmath.cpp 0
+
+ \sa qRadiansToDegrees()
+*/
+
+/*!
+ \fn double qDegreesToRadians(double degrees)
+ \relates <QtMath>
+ \since 5.1
+
+ \brief The function converts the \a degrees in double to radians.
+
+ The purpose of the function is to aid the conversion as such a convenient
+ function is not part of the Standard Template Library, i.e. in <cmath> or
+ elsewhere.
+
+ Example:
+
+ \snippet code/src_corelib_kernel_qmath.cpp 1
+
+ \sa qRadiansToDegrees()
+*/
+
+/*!
+ \fn float qRadiansToDegrees(float radians)
+ \relates <QtMath>
+ \since 5.1
+
+ \brief The function converts the \a radians in float to degrees.
+
+ The purpose of the function is to aid the conversion as such a convenient
+ function is not part of the Standard Template Library, i.e. in <cmath> or
+ elsewhere.
+
+ Example:
+
+ \snippet code/src_corelib_kernel_qmath.cpp 2
+
+ \sa qDegreesToRadians()
+*/
+
+/*!
+ \fn double qRadiansToDegrees(double radians)
+ \relates <QtMath>
+ \since 5.1
+
+ \brief The function converts the \a radians in double to degrees.
+
+ The purpose of the function is to aid the conversion as such a convenient
+ function is not part of the Standard Template Library, i.e. in <cmath> or
+ elsewhere.
+
+ Example:
+
+ \snippet code/src_corelib_kernel_qmath.cpp 3
+
+ \sa qDegreesToRadians()
+*/
+
QT_END_NAMESPACE
diff --git a/src/corelib/kernel/qmath.h b/src/corelib/kernel/qmath.h
index 097200d690..21e23b9eb0 100644
--- a/src/corelib/kernel/qmath.h
+++ b/src/corelib/kernel/qmath.h
@@ -42,12 +42,14 @@
#ifndef QMATH_H
#define QMATH_H
+#if 0
+#pragma qt_class(QtMath)
+#endif
+
#include <math.h>
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -264,8 +266,26 @@ inline qreal qFastCos(qreal x)
return qt_sine_table[si] - (qt_sine_table[ci] + 0.5 * qt_sine_table[si] * d) * d;
}
-QT_END_NAMESPACE
+Q_DECL_CONSTEXPR inline float qDegreesToRadians(float degrees)
+{
+ return degrees * float(M_PI/180);
+}
+
+Q_DECL_CONSTEXPR inline double qDegreesToRadians(double degrees)
+{
+ return degrees * (M_PI / 180);
+}
+
+Q_DECL_CONSTEXPR inline float qRadiansToDegrees(float radians)
+{
+ return radians * float(180/M_PI);
+}
-QT_END_HEADER
+Q_DECL_CONSTEXPR inline double qRadiansToDegrees(double radians)
+{
+ return radians * (180 / M_PI);
+}
+
+QT_END_NAMESPACE
#endif // QMATH_H
diff --git a/src/corelib/kernel/qmath.qdoc b/src/corelib/kernel/qmath.qdoc
index 448b167662..06d8db9277 100644
--- a/src/corelib/kernel/qmath.qdoc
+++ b/src/corelib/kernel/qmath.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\headerfile <QtCore/qmath.h>
\title Math Functions
\ingroup funclists
@@ -35,11 +35,11 @@
/*!
\fn int qCeil(qreal v)
- Return the ceiling of the value \a v.
+ Return the ceiling of the value \a v.
The ceiling is the smallest integer that is not less than \a v.
For example, if \a v is 41.2, then the ceiling is 42.
-
+
\relates <QtCore/qmath.h>
\sa qFloor()
*/
diff --git a/src/corelib/kernel/qmetaobject.cpp b/src/corelib/kernel/qmetaobject.cpp
index 14d96e96fd..00d20d9300 100644
--- a/src/corelib/kernel/qmetaobject.cpp
+++ b/src/corelib/kernel/qmetaobject.cpp
@@ -1001,7 +1001,7 @@ int QMetaObject::indexOfProperty(const char *name) const
Q_ASSERT(priv(this->d.data)->revision >= 3);
if (priv(this->d.data)->flags & DynamicMetaObject) {
- QAbstractDynamicMetaObject *me =
+ QAbstractDynamicMetaObject *me =
const_cast<QAbstractDynamicMetaObject *>(static_cast<const QAbstractDynamicMetaObject *>(this));
return me->createProperty(name, 0);
@@ -1854,7 +1854,10 @@ const char *QMetaMethod::typeName() const
way in the function declaration:
\code
- #define THISISTESTTAG // tag text
+ #ifndef Q_MOC_RUN
+ // define the tag text
+ # define THISISTESTTAG
+ #endif
...
private slots:
THISISTESTTAG void testFunc();
@@ -1871,8 +1874,13 @@ const char *QMetaMethod::typeName() const
qDebug() << mm.tag(); // prints THISISTESTTAG
\endcode
- For the moment,
- \c moc doesn't support any special tags.
+ For the moment, \c moc will extract and record all tags, but it will not
+ handle any of them specially.
+
+ \note Since Qt 5.0, \c moc expands preprocessor macros, so it is necessary
+ to surround the definition with \c #ifndef \c Q_MOC_RUN, as shown in the
+ example above. This was not required in Qt 4. The code as shown above works
+ with Qt 4 too.
*/
const char *QMetaMethod::tag() const
{
@@ -1904,9 +1912,9 @@ int QMetaMethod::methodIndex() const
return QMetaMethodPrivate::get(this)->ownMethodIndex() + mobj->methodOffset();
}
+// This method has been around for a while, but the documentation was marked \internal until 5.1
/*!
- \internal
-
+ \since 5.1
Returns the method revision if one was
specified by Q_REVISION, otherwise returns 0.
*/
@@ -2041,8 +2049,8 @@ QMetaMethod QMetaMethod::fromSignalImpl(const QMetaObject *metaObject, void **si
\snippet code/src_corelib_kernel_qmetaobject.cpp 8
- QMetaObject::normalizedSignature() is used here to ensure that the format
- of the signature is what invoke() expects. E.g. extra whitespace is
+ QMetaObject::normalizedSignature() is used here to ensure that the format
+ of the signature is what invoke() expects. E.g. extra whitespace is
removed.
If the "compute" slot does not take exactly one QString, one int
@@ -2550,7 +2558,7 @@ static QByteArray qualifiedName(const QMetaEnum &e)
A property has a name() and a type(), as well as various
attributes that specify its behavior: isReadable(), isWritable(),
- isDesignable(), isScriptable(), and isStored().
+ isDesignable(), isScriptable(), revision(), and isStored().
If the property is an enumeration, isEnumType() returns true; if the
property is an enumeration that is also a flag (i.e. its values
@@ -2970,7 +2978,7 @@ QMetaMethod QMetaProperty::notifySignal() const
{
int id = notifySignalIndex();
if (id != -1)
- return mobj->method(id);
+ return mobj->method(id);
else
return QMetaMethod();
}
@@ -2978,7 +2986,7 @@ QMetaMethod QMetaProperty::notifySignal() const
/*!
\since 4.6
- Returns the index of the property change notifying signal if one was
+ Returns the index of the property change notifying signal if one was
specified, otherwise returns -1.
\sa hasNotifySignal()
@@ -2994,8 +3002,9 @@ int QMetaProperty::notifySignalIndex() const
}
}
+// This method has been around for a while, but the documentation was marked \internal until 5.1
/*!
- \internal
+ \since 5.1
Returns the property revision if one was
specified by REVISION, otherwise returns 0.
diff --git a/src/corelib/kernel/qmetaobject.h b/src/corelib/kernel/qmetaobject.h
index 6d6b849d75..23fc89ffe3 100644
--- a/src/corelib/kernel/qmetaobject.h
+++ b/src/corelib/kernel/qmetaobject.h
@@ -45,8 +45,6 @@
#include <QtCore/qobjectdefs.h>
#include <QtCore/qvariant.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -274,6 +272,4 @@ Q_DECLARE_TYPEINFO(QMetaClassInfo, Q_MOVABLE_TYPE);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMETAOBJECT_H
diff --git a/src/corelib/kernel/qmetatype.cpp b/src/corelib/kernel/qmetatype.cpp
index abf220ebd4..b9f7462b12 100644
--- a/src/corelib/kernel/qmetatype.cpp
+++ b/src/corelib/kernel/qmetatype.cpp
@@ -959,11 +959,11 @@ bool QMetaType::save(QDataStream &stream, int type, const void *data)
break;
#endif
#ifndef QT_BOOTSTRAPPED
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
case QMetaType::QRegularExpression:
stream << *static_cast<const NS(QRegularExpression)*>(data);
break;
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
case QMetaType::QEasingCurve:
stream << *static_cast<const NS(QEasingCurve)*>(data);
break;
@@ -1182,11 +1182,11 @@ bool QMetaType::load(QDataStream &stream, int type, void *data)
break;
#endif
#ifndef QT_BOOTSTRAPPED
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
case QMetaType::QRegularExpression:
stream >> *static_cast< NS(QRegularExpression)*>(data);
break;
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
case QMetaType::QEasingCurve:
stream >> *static_cast< NS(QEasingCurve)*>(data);
break;
diff --git a/src/corelib/kernel/qmetatype.h b/src/corelib/kernel/qmetatype.h
index 3ffbfb8385..aed998f2e2 100644
--- a/src/corelib/kernel/qmetatype.h
+++ b/src/corelib/kernel/qmetatype.h
@@ -56,8 +56,6 @@
#error qmetatype.h must be included before any header file that defines Bool
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -534,6 +532,9 @@ struct QMetaTypeId2
static inline Q_DECL_CONSTEXPR int qt_metatype_id() { return QMetaTypeId<T>::qt_metatype_id(); }
};
+template <typename T>
+struct QMetaTypeId2<const T&> : QMetaTypeId2<T> {};
+
namespace QtPrivate {
template <typename T, bool Defined = QMetaTypeId2<T>::Defined>
struct QMetaTypeIdHelper {
@@ -633,30 +634,30 @@ void qRegisterMetaTypeStreamOperators(const char *typeName
#endif // QT_NO_DATASTREAM
template <typename T>
-inline Q_DECL_CONSTEXPR int qMetaTypeId(
-#ifndef Q_QDOC
- T * /* dummy */ = 0
-#endif
-)
+inline Q_DECL_CONSTEXPR int qMetaTypeId()
{
Q_STATIC_ASSERT_X(QMetaTypeId2<T>::Defined, "Type is not registered, please use the Q_DECLARE_METATYPE macro to make it known to Qt's meta-object system");
return QMetaTypeId2<T>::qt_metatype_id();
}
template <typename T>
-inline Q_DECL_CONSTEXPR int qRegisterMetaType(
-#if !defined(Q_QDOC) && !defined(Q_CC_SUN)
- T * dummy = 0
-#endif
-)
+inline Q_DECL_CONSTEXPR int qRegisterMetaType()
{
-#ifdef Q_CC_SUN
- return qMetaTypeId(static_cast<T *>(0));
-#else
- return qMetaTypeId(dummy);
-#endif
+ return qMetaTypeId<T>();
}
+#if QT_DEPRECATED_SINCE(5, 1) && !defined(Q_QDOC)
+// There used to be a T *dummy = 0 argument in Qt 4.0 to support MSVC6
+template <typename T>
+QT_DEPRECATED inline Q_DECL_CONSTEXPR int qMetaTypeId(T *)
+{ return qMetaTypeId<T>(); }
+#ifndef Q_CC_SUN
+template <typename T>
+QT_DEPRECATED inline Q_DECL_CONSTEXPR int qRegisterMetaType(T *)
+{ return qRegisterMetaType<T>(); }
+#endif
+#endif
+
template <typename T>
struct QMetaTypeIdQObject<T*, /* isPointerToTypeDerivedFromQObject */ true>
{
@@ -669,12 +670,12 @@ struct QMetaTypeIdQObject<T*, /* isPointerToTypeDerivedFromQObject */ true>
static QBasicAtomicInt metatype_id = Q_BASIC_ATOMIC_INITIALIZER(0);
if (const int id = metatype_id.loadAcquire())
return id;
- const int len = int(strlen(T::staticMetaObject.className()));
- QVarLengthArray<char, 16> classNameStar;
- classNameStar.append(T::staticMetaObject.className(), len);
- classNameStar.append('*');
- const int newId = qRegisterNormalizedMetaType<T*>( \
- QByteArray(classNameStar.constData(), classNameStar.size()),
+ const char * const cName = T::staticMetaObject.className();
+ QByteArray typeName;
+ typeName.reserve(int(strlen(cName)) + 1);
+ typeName.append(cName).append('*');
+ const int newId = qRegisterNormalizedMetaType<T*>(
+ typeName,
reinterpret_cast<T**>(quintptr(-1)));
metatype_id.storeRelease(newId);
return newId;
@@ -756,17 +757,18 @@ struct QMetaTypeId< SINGLE_ARG_TEMPLATE<T> > \
static QBasicAtomicInt metatype_id = Q_BASIC_ATOMIC_INITIALIZER(0); \
if (const int id = metatype_id.load()) \
return id; \
- QVarLengthArray<char, 24> name; \
- name.append(#SINGLE_ARG_TEMPLATE, int(sizeof(#SINGLE_ARG_TEMPLATE)) - 1); \
- name.append('<'); \
const char *tName = QMetaType::typeName(qMetaTypeId<T>()); \
Q_ASSERT(tName); \
- name.append(tName, int(strlen(tName))); \
- if (name.last() == '>') \
- name.append(' '); \
- name.append('>'); \
- const int newId = qRegisterNormalizedMetaType< SINGLE_ARG_TEMPLATE<T> >( \
- QByteArray(name.constData(), name.size()), \
+ const int tNameLen = qstrlen(tName); \
+ QByteArray typeName; \
+ typeName.reserve(sizeof(#SINGLE_ARG_TEMPLATE) + 1 + tNameLen + 1 + 1); \
+ typeName.append(#SINGLE_ARG_TEMPLATE, sizeof(#SINGLE_ARG_TEMPLATE) - 1) \
+ .append('<').append(tName, tNameLen); \
+ if (typeName.endsWith('>')) \
+ typeName.append(' '); \
+ typeName.append('>'); \
+ const int newId = qRegisterNormalizedMetaType< SINGLE_ARG_TEMPLATE<T> >( \
+ typeName, \
reinterpret_cast< SINGLE_ARG_TEMPLATE<T> *>(quintptr(-1))); \
metatype_id.storeRelease(newId); \
return newId; \
@@ -785,21 +787,21 @@ struct QMetaTypeId< DOUBLE_ARG_TEMPLATE<T, U> > \
static QBasicAtomicInt metatype_id = Q_BASIC_ATOMIC_INITIALIZER(0); \
if (const int id = metatype_id.loadAcquire()) \
return id; \
- QVarLengthArray<char, 24> name; \
- name.append(#DOUBLE_ARG_TEMPLATE, sizeof(#DOUBLE_ARG_TEMPLATE) - 1); \
- name.append('<'); \
const char *tName = QMetaType::typeName(qMetaTypeId<T>()); \
- Q_ASSERT(tName); \
- name.append(tName, int(strlen(tName))); \
- name.append(','); \
const char *uName = QMetaType::typeName(qMetaTypeId<U>()); \
+ Q_ASSERT(tName); \
Q_ASSERT(uName); \
- name.append(uName, int(strlen(uName))); \
- if (name.last() == '>') \
- name.append(' '); \
- name.append('>'); \
+ const int tNameLen = qstrlen(tName); \
+ const int uNameLen = qstrlen(uName); \
+ QByteArray typeName; \
+ typeName.reserve(sizeof(#DOUBLE_ARG_TEMPLATE) + 1 + tNameLen + 1 + uNameLen + 1 + 1); \
+ typeName.append(#DOUBLE_ARG_TEMPLATE, sizeof(#DOUBLE_ARG_TEMPLATE) - 1) \
+ .append('<').append(tName, tNameLen).append(',').append(uName, uNameLen); \
+ if (typeName.endsWith('>')) \
+ typeName.append(' '); \
+ typeName.append('>'); \
const int newId = qRegisterNormalizedMetaType< DOUBLE_ARG_TEMPLATE<T, U> >(\
- QByteArray(name.constData(), name.size()), \
+ typeName, \
reinterpret_cast< DOUBLE_ARG_TEMPLATE<T, U> *>(quintptr(-1))); \
metatype_id.storeRelease(newId); \
return newId; \
@@ -826,7 +828,13 @@ struct QMetaTypeId_ ## SMART_POINTER ## _QObjectStar<T, true> \
static QBasicAtomicInt metatype_id = Q_BASIC_ATOMIC_INITIALIZER(0); \
if (const int id = metatype_id.loadAcquire()) \
return id; \
- const int newId = qRegisterNormalizedMetaType< SMART_POINTER<T> >( #SMART_POINTER "<" + QByteArray(T::staticMetaObject.className()) + ">", \
+ const char * const cName = T::staticMetaObject.className(); \
+ QByteArray typeName; \
+ typeName.reserve(sizeof(#SMART_POINTER) + 1 + strlen(cName) + 1); \
+ typeName.append(#SMART_POINTER, sizeof(#SMART_POINTER) - 1) \
+ .append('<').append(cName).append('>'); \
+ const int newId = qRegisterNormalizedMetaType< SMART_POINTER<T> >( \
+ typeName, \
reinterpret_cast< SMART_POINTER<T> *>(quintptr(-1))); \
metatype_id.storeRelease(newId); \
return newId; \
@@ -980,6 +988,4 @@ QT_END_NAMESPACE
QT_FOR_EACH_STATIC_TYPE(Q_DECLARE_BUILTIN_METATYPE)
-QT_END_HEADER
-
#endif // QMETATYPE_H
diff --git a/src/corelib/kernel/qmetatype_p.h b/src/corelib/kernel/qmetatype_p.h
index 39bdd5e3bb..95b9e2e394 100644
--- a/src/corelib/kernel/qmetatype_p.h
+++ b/src/corelib/kernel/qmetatype_p.h
@@ -221,7 +221,7 @@ template<> struct TypeDefinition<QPointF> { static const bool IsAvailable = fals
#ifdef QT_NO_REGEXP
template<> struct TypeDefinition<QRegExp> { static const bool IsAvailable = false; };
#endif
-#if defined(QT_BOOTSTRAPPED) || defined(QT_NO_REGEXP)
+#if defined(QT_BOOTSTRAPPED) || defined(QT_NO_REGULAREXPRESSION)
template<> struct TypeDefinition<QRegularExpression> { static const bool IsAvailable = false; };
#endif
#ifdef QT_NO_SHORTCUT
diff --git a/src/corelib/kernel/qmimedata.h b/src/corelib/kernel/qmimedata.h
index 774a6e4986..84c73262b2 100644
--- a/src/corelib/kernel/qmimedata.h
+++ b/src/corelib/kernel/qmimedata.h
@@ -45,8 +45,6 @@
#include <QtCore/qvariant.h>
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -98,6 +96,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMIMEDATA_H
diff --git a/src/corelib/kernel/qobject.cpp b/src/corelib/kernel/qobject.cpp
index a82242939d..527a842d17 100644
--- a/src/corelib/kernel/qobject.cpp
+++ b/src/corelib/kernel/qobject.cpp
@@ -216,8 +216,8 @@ QObjectPrivate::~QObjectPrivate()
{
if (extraData && !extraData->runningTimers.isEmpty()) {
// unregister pending timers
- if (threadData->eventDispatcher)
- threadData->eventDispatcher->unregisterTimers(q_ptr);
+ if (threadData->eventDispatcher.load())
+ threadData->eventDispatcher.load()->unregisterTimers(q_ptr);
// release the timer ids back to the pool
for (int i = 0; i < extraData->runningTimers.size(); ++i)
@@ -927,7 +927,7 @@ QObjectPrivate::Connection::~Connection()
\relates QObject
Returns the given \a object cast to type T if the object is of type
- T (or of a subclass); otherwise returns 0. If \a object is 0 then
+ T (or of a subclass); otherwise returns 0. If \a object is 0 then
it will also return 0.
The class T must inherit (directly or indirectly) QObject and be
@@ -1074,7 +1074,7 @@ bool QObject::event(QEvent *e)
case QEvent::ThreadChange: {
Q_D(QObject);
QThreadData *threadData = d->threadData;
- QAbstractEventDispatcher *eventDispatcher = threadData->eventDispatcher;
+ QAbstractEventDispatcher *eventDispatcher = threadData->eventDispatcher.load();
if (eventDispatcher) {
QList<QAbstractEventDispatcher::TimerInfo> timers = eventDispatcher->registeredTimers(this);
if (!timers.isEmpty()) {
@@ -1354,9 +1354,9 @@ void QObjectPrivate::setThreadData_helper(QThreadData *currentData, QThreadData
++eventsMoved;
}
}
- if (eventsMoved > 0 && targetData->eventDispatcher) {
+ if (eventsMoved > 0 && targetData->eventDispatcher.load()) {
targetData->canWait = false;
- targetData->eventDispatcher->wakeUp();
+ targetData->eventDispatcher.load()->wakeUp();
}
// the current emitting thread shouldn't restore currentSender after calling moveToThread()
@@ -1379,7 +1379,7 @@ void QObjectPrivate::_q_reregisterTimers(void *pointer)
{
Q_Q(QObject);
QList<QAbstractEventDispatcher::TimerInfo> *timerList = reinterpret_cast<QList<QAbstractEventDispatcher::TimerInfo> *>(pointer);
- QAbstractEventDispatcher *eventDispatcher = threadData->eventDispatcher;
+ QAbstractEventDispatcher *eventDispatcher = threadData->eventDispatcher.load();
for (int i = 0; i < timerList->size(); ++i) {
const QAbstractEventDispatcher::TimerInfo &ti = timerList->at(i);
eventDispatcher->registerTimer(ti.timerId, ti.interval, ti.timerType, q);
@@ -1438,11 +1438,11 @@ int QObject::startTimer(int interval, Qt::TimerType timerType)
return 0;
}
- if (!d->threadData->eventDispatcher) {
+ if (!d->threadData->eventDispatcher.load()) {
qWarning("QObject::startTimer: QTimer can only be used with threads started with QThread");
return 0;
}
- int timerId = d->threadData->eventDispatcher->registerTimer(interval, timerType, this);
+ int timerId = d->threadData->eventDispatcher.load()->registerTimer(interval, timerType, this);
if (!d->extraData)
d->extraData = new QObjectPrivate::ExtraData;
d->extraData->runningTimers.append(timerId);
@@ -1472,8 +1472,8 @@ void QObject::killTimer(int id)
return;
}
- if (d->threadData->eventDispatcher)
- d->threadData->eventDispatcher->unregisterTimer(id);
+ if (d->threadData->eventDispatcher.load())
+ d->threadData->eventDispatcher.load()->unregisterTimer(id);
d->extraData->runningTimers.remove(at);
QAbstractEventDispatcherPrivate::releaseTimerId(id);
@@ -1690,7 +1690,7 @@ void qt_qFindChildren_helper(const QObject *parent, const QRegExp &re,
}
#endif // QT_NO_REGEXP
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
/*!
\internal
*/
@@ -1712,7 +1712,7 @@ void qt_qFindChildren_helper(const QObject *parent, const QRegularExpression &re
qt_qFindChildren_helper(obj, re, mo, list, options);
}
}
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
/*!
\internal
@@ -3089,8 +3089,8 @@ bool QMetaObject::disconnect(const QObject *sender, int signal_index,
/*!
\internal
-Disconnect a single signal connection. If QMetaObject::connect() has been called
-multiple times for the same sender, signal_index, receiver and method_index only
+Disconnect a single signal connection. If QMetaObject::connect() has been called
+multiple times for the same sender, signal_index, receiver and method_index only
one of these connections will be removed.
*/
bool QMetaObject::disconnectOne(const QObject *sender, int signal_index,
@@ -3219,6 +3219,9 @@ bool QMetaObjectPrivate::disconnect(const QObject *sender,
\snippet code/src_corelib_kernel_qobject.cpp 34
+ If \a object itself has a properly set object name, its own signals are also
+ connected to its respective slots.
+
\sa QObject::setObjectName()
*/
void QMetaObject::connectSlotsByName(QObject *o)
@@ -3227,39 +3230,66 @@ void QMetaObject::connectSlotsByName(QObject *o)
return;
const QMetaObject *mo = o->metaObject();
Q_ASSERT(mo);
- const QObjectList list = o->findChildren<QObject *>(QString());
+ const QObjectList list = // list of all objects to look for matching signals including...
+ o->findChildren<QObject *>(QString()) // all children of 'o'...
+ << o; // and the object 'o' itself
+
+ // for each method/slot of o ...
for (int i = 0; i < mo->methodCount(); ++i) {
- QByteArray slotSignature = mo->method(i).methodSignature();
+ const QByteArray slotSignature = mo->method(i).methodSignature();
const char *slot = slotSignature.constData();
Q_ASSERT(slot);
+
+ // ...that starts with "on_", ...
if (slot[0] != 'o' || slot[1] != 'n' || slot[2] != '_')
continue;
+
+ // ...we check each object in our list, ...
bool foundIt = false;
for(int j = 0; j < list.count(); ++j) {
const QObject *co = list.at(j);
- QByteArray objName = co->objectName().toLatin1();
- int len = objName.length();
- if (!len || qstrncmp(slot + 3, objName.data(), len) || slot[len+3] != '_')
+ const QByteArray coName = co->objectName().toLatin1();
+
+ // ...discarding those whose objectName is not fitting the pattern "on_<objectName>_...", ...
+ if (coName.isEmpty() || qstrncmp(slot + 3, coName.constData(), coName.size()) || slot[coName.size()+3] != '_')
continue;
+
+ const char *signal = slot + coName.size() + 4; // the 'signal' part of the slot name
+
+ // ...for the presence of a matching signal "on_<objectName>_<signal>".
const QMetaObject *smeta;
- int sigIndex = co->d_func()->signalIndex(slot + len + 4, &smeta);
- if (sigIndex < 0) { // search for compatible signals
+ int sigIndex = co->d_func()->signalIndex(signal, &smeta);
+ if (sigIndex < 0) {
+ // if no exactly fitting signal (name + complete parameter type list) could be found
+ // look for just any signal with the correct name and at least the slot's parameter list.
+ // Note: if more than one of thoses signals exist, the one that gets connected is
+ // chosen 'at random' (order of declaration in source file)
+ QList<QByteArray> compatibleSignals;
const QMetaObject *smo = co->metaObject();
- int slotlen = qstrlen(slot + len + 4) - 1;
- for (int k = 0; k < QMetaObjectPrivate::absoluteSignalCount(smo); ++k) {
- QMetaMethod method = QMetaObjectPrivate::signal(smo, k);
- if (!qstrncmp(method.methodSignature().constData(), slot + len + 4, slotlen)) {
+ int sigLen = qstrlen(signal) - 1; // ignore the trailing ')'
+ for (int k = QMetaObjectPrivate::absoluteSignalCount(smo)-1; k >= 0; --k) {
+ const QMetaMethod method = QMetaObjectPrivate::signal(smo, k);
+ if (!qstrncmp(method.methodSignature().constData(), signal, sigLen)) {
smeta = method.enclosingMetaObject();
sigIndex = k;
- break;
+ compatibleSignals.prepend(method.methodSignature());
}
}
+ if (compatibleSignals.size() > 1)
+ qWarning() << "QMetaObject::connectSlotsByName: Connecting slot" << slot
+ << "with the first of the following compatible signals:" << compatibleSignals;
}
+
if (sigIndex < 0)
continue;
+ // we connect it...
if (Connection(QMetaObjectPrivate::connect(co, sigIndex, smeta, o, i))) {
foundIt = true;
+ // ...and stop looking for further objects with the same name.
+ // Note: the Designer will make sure each object name is unique in the above
+ // 'list' but other code may create two child objects with the same name. In
+ // this case one is chosen 'at random'.
break;
}
}
@@ -3268,7 +3298,11 @@ void QMetaObject::connectSlotsByName(QObject *o)
while (mo->method(i + 1).attributes() & QMetaMethod::Cloned)
++i;
} else if (!(mo->method(i).attributes() & QMetaMethod::Cloned)) {
- qWarning("QMetaObject::connectSlotsByName: No matching signal for %s", slot);
+ // check if the slot has the following signature: "on_..._...(..."
+ int iParen = slotSignature.indexOf('(');
+ int iLastUnderscore = slotSignature.lastIndexOf('_', iParen-1);
+ if (iLastUnderscore > 3)
+ qWarning("QMetaObject::connectSlotsByName: No matching signal for %s", slot);
}
}
}
@@ -3334,7 +3368,7 @@ void QMetaObject::activate(QObject *sender, int signalOffset, int local_signal_i
return;
if (sender->d_func()->declarativeData && QAbstractDeclarativeData::signalEmitted)
- QAbstractDeclarativeData::signalEmitted(sender->d_func()->declarativeData, sender,
+ QAbstractDeclarativeData::signalEmitted(sender->d_func()->declarativeData, sender,
signal_index, argv);
void *empty_argv[] = { 0 };
@@ -4069,6 +4103,37 @@ QDebug operator<<(QDebug dbg, const QObject *o) {
*/
/*!
+ \macro Q_REVISION
+ \relates QObject
+
+ Apply this macro to definitions of member functions to tag them with a
+ revision number in the meta-object system. The macro is written before
+ the return type, as shown in the following example:
+
+ \snippet qmetaobject-revision/window.h Window class with revision
+
+ This is useful when using the meta-object system to dynamically expose
+ objects to another API, as you can match the version expected by multiple
+ versions of the other API. Consider the following simplified example:
+
+ \snippet qmetaobject-revision/main.cpp Window class using revision
+
+ Using the same Window class as the previous example, the newProperty and
+ newMethod would only be exposed in this code when the expected version is
+ 1 or greater.
+
+ Since all methods are considered to be in revision 0 if untagged, a tag
+ of Q_REVISION(0) is invalid and ignored.
+
+ This tag is not used by the meta-object system itself. Currently this is only
+ used by the QtQml module.
+
+ For a more generic string tag, see \l QMetaMethod::tag()
+
+ \sa QMetaMethod::revision()
+*/
+
+/*!
\macro Q_SET_OBJECT_NAME(Object)
\relates QObject
\since 5.0
@@ -4151,6 +4216,9 @@ void qDeleteInEventHandler(QObject *o)
\snippet code/src_corelib_kernel_qobject.cpp 25
make sure to declare the argument type with Q_DECLARE_METATYPE
+
+ \note The number of arguments in the signal or slot are limited to 6 if
+ the compiler does not support C++11 variadic templates.
*/
@@ -4181,6 +4249,10 @@ void qDeleteInEventHandler(QObject *o)
\snippet code/src_corelib_kernel_qobject.cpp 46
The connection will automatically disconnect if the sender is destroyed.
+
+ \note If the compiler does not support C++11 variadic templates, the number
+ of arguments in the signal or slot are limited to 6, and the functor object
+ must not have an overloaded or templated operator().
*/
/**
@@ -4194,7 +4266,7 @@ void qDeleteInEventHandler(QObject *o)
connecting to a static function or a functor
\a slot a pointer only used when using Qt::UniqueConnection
\a type the Qt::ConnctionType passed as argument to connect
- \a types an array of integer with the metatype id of the parametter of the signal
+ \a types an array of integer with the metatype id of the parameter of the signal
to be used with queued connection
must stay valid at least for the whole time of the connection, this function
do not take ownership. typically static data.
@@ -4209,7 +4281,7 @@ QMetaObject::Connection QObject::connectImpl(const QObject *sender, void **signa
const int *types, const QMetaObject *senderMetaObject)
{
if (!sender || !signal || !slotObj || !senderMetaObject) {
- qWarning("QObject::connect: invalid null parametter");
+ qWarning("QObject::connect: invalid null parameter");
if (slotObj)
slotObj->destroyIfLastRef();
return QMetaObject::Connection();
diff --git a/src/corelib/kernel/qobject.h b/src/corelib/kernel/qobject.h
index a2d7dcd7ef..aaa09fac50 100644
--- a/src/corelib/kernel/qobject.h
+++ b/src/corelib/kernel/qobject.h
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2013 Olivier Goffart <ogoffart@woboq.com>
** Contact: http://www.qt-project.org/legal
**
** This file is part of the QtCore module of the Qt Toolkit.
@@ -56,8 +57,6 @@
#include <QtCore/qobject_impl.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -73,7 +72,7 @@ class QWidget;
#ifndef QT_NO_REGEXP
class QRegExp;
#endif
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
class QRegularExpression;
#endif
#ifndef QT_NO_USERDATA
@@ -179,7 +178,7 @@ public:
}
#endif
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
template<typename T>
inline QList<T> findChildren(const QRegularExpression &re, Qt::FindChildOptions options = Qt::FindChildrenRecursively) const
{
@@ -267,27 +266,50 @@ public:
static inline typename QtPrivate::QEnableIf<QtPrivate::FunctionPointer<Func2>::ArgumentCount == -1, QMetaObject::Connection>::Type
connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal, Func2 slot)
{
+#if defined (Q_COMPILER_DECLTYPE) && defined (Q_COMPILER_VARIADIC_TEMPLATES)
+ typedef QtPrivate::FunctionPointer<Func1> SignalType;
+ const int FunctorArgumentCount = QtPrivate::ComputeFunctorArgumentCount<Func2 , typename SignalType::Arguments>::Value;
+
+ Q_STATIC_ASSERT_X((FunctorArgumentCount >= 0),
+ "Signal and slot arguments are not compatible.");
+ const int SlotArgumentCount = (FunctorArgumentCount >= 0) ? FunctorArgumentCount : 0;
+ typedef typename QtPrivate::FunctorReturnType<Func2, typename QtPrivate::List_Left<typename SignalType::Arguments, SlotArgumentCount>::Value>::Value SlotReturnType;
+#else
+ // Without variadic template, we don't detect the best overload of operator(). We just
+ // assume there is only one simple operator() and connect to &Func2::operator()
+
+ /* If you get an error such as:
+ couldn't deduce template parameter 'Func2Operator'
+ or
+ cannot resolve address of overloaded function
+ It means the functor does not have a single operator().
+ Functors with overloaded or templated operator() are only supported if the compiler supports
+ C++11 variadic templates
+ */
#ifndef Q_COMPILER_DECLTYPE //Workaround the lack of decltype using another function as indirection
return connect_functor(sender, signal, slot, &Func2::operator()); }
template <typename Func1, typename Func2, typename Func2Operator>
static inline QMetaObject::Connection connect_functor(const QObject *sender, Func1 signal, Func2 slot, Func2Operator) {
typedef QtPrivate::FunctionPointer<Func2Operator> SlotType ;
#else
-
typedef QtPrivate::FunctionPointer<decltype(&Func2::operator())> SlotType ;
#endif
typedef QtPrivate::FunctionPointer<Func1> SignalType;
+ typedef typename SlotType::ReturnType SlotReturnType;
+ const int SlotArgumentCount = SlotType::ArgumentCount;
- Q_STATIC_ASSERT_X(int(SignalType::ArgumentCount) >= int(SlotType::ArgumentCount),
+ Q_STATIC_ASSERT_X(int(SignalType::ArgumentCount) >= SlotArgumentCount,
"The slot requires more arguments than the signal provides.");
Q_STATIC_ASSERT_X((QtPrivate::CheckCompatibleArguments<typename SignalType::Arguments, typename SlotType::Arguments>::value),
"Signal and slot arguments are not compatible.");
- Q_STATIC_ASSERT_X((QtPrivate::AreArgumentsCompatible<typename SlotType::ReturnType, typename SignalType::ReturnType>::value),
+#endif
+
+ Q_STATIC_ASSERT_X((QtPrivate::AreArgumentsCompatible<SlotReturnType, typename SignalType::ReturnType>::value),
"Return type of the slot is not compatible with the return type of the signal.");
return connectImpl(sender, reinterpret_cast<void **>(&signal), sender, 0,
- new QtPrivate::QFunctorSlotObject<Func2, SlotType::ArgumentCount,
- typename QtPrivate::List_Left<typename SignalType::Arguments, SlotType::ArgumentCount>::Value,
+ new QtPrivate::QFunctorSlotObject<Func2, SlotArgumentCount,
+ typename QtPrivate::List_Left<typename SignalType::Arguments, SlotArgumentCount>::Value,
typename SignalType::ReturnType>(slot),
Qt::DirectConnection, 0, &SignalType::Object::staticMetaObject);
}
@@ -496,8 +518,6 @@ namespace QtPrivate {
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
#endif // QOBJECT_H
diff --git a/src/corelib/kernel/qobject_impl.h b/src/corelib/kernel/qobject_impl.h
index 7ed4d33e96..0b5631f2a6 100644
--- a/src/corelib/kernel/qobject_impl.h
+++ b/src/corelib/kernel/qobject_impl.h
@@ -45,7 +45,10 @@
#error Do not include qobject_impl.h directly
#endif
-QT_BEGIN_HEADER
+#if 0
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
+#endif
QT_BEGIN_NAMESPACE
@@ -207,6 +210,4 @@ namespace QtPrivate {
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/kernel/qobject_p.h b/src/corelib/kernel/qobject_p.h
index e4b4ce8b42..e849ec1599 100644
--- a/src/corelib/kernel/qobject_p.h
+++ b/src/corelib/kernel/qobject_p.h
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2013 Olivier Goffart <ogoffart@woboq.com>
** Contact: http://www.qt-project.org/legal
**
** This file is part of the QtCore module of the Qt Toolkit.
@@ -198,6 +199,14 @@ public:
inline void connectNotify(const QMetaMethod &signal);
inline void disconnectNotify(const QMetaMethod &signal);
+ template <typename Func1, typename Func2>
+ static inline QMetaObject::Connection connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal,
+ const typename QtPrivate::FunctionPointer<Func2>::Object *receiverPrivate, Func2 slot,
+ Qt::ConnectionType type = Qt::AutoConnection);
+
+ template <typename Func1, typename Func2>
+ static inline bool disconnect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal,
+ const typename QtPrivate::FunctionPointer<Func2>::Object *receiverPrivate, Func2 slot);
public:
ExtraData *extraData; // extra data set by the user
QThreadData *threadData; // id of the thread that owns the object
@@ -267,6 +276,74 @@ inline void QObjectPrivate::disconnectNotify(const QMetaMethod &signal)
q_ptr->disconnectNotify(signal);
}
+namespace QtPrivate {
+template<typename Func, typename Args, typename R> class QPrivateSlotObject : public QSlotObjectBase
+{
+ typedef QtPrivate::FunctionPointer<Func> FuncType;
+ Func function;
+ static void impl(int which, QSlotObjectBase *this_, QObject *r, void **a, bool *ret)
+ {
+ switch (which) {
+ case Destroy:
+ delete static_cast<QPrivateSlotObject*>(this_);
+ break;
+ case Call:
+ FuncType::template call<Args, R>(static_cast<QPrivateSlotObject*>(this_)->function,
+ static_cast<typename FuncType::Object *>(QObjectPrivate::get(r)), a);
+ break;
+ case Compare:
+ *ret = *reinterpret_cast<Func *>(a) == static_cast<QPrivateSlotObject*>(this_)->function;
+ break;
+ case NumOperations: ;
+ }
+ }
+public:
+ explicit QPrivateSlotObject(Func f) : QSlotObjectBase(&impl), function(f) {}
+};
+} //namespace QtPrivate
+
+template <typename Func1, typename Func2>
+inline QMetaObject::Connection QObjectPrivate::connect(const typename QtPrivate::FunctionPointer<Func1>::Object *sender, Func1 signal,
+ const typename QtPrivate::FunctionPointer<Func2>::Object *receiverPrivate, Func2 slot,
+ Qt::ConnectionType type)
+{
+ typedef QtPrivate::FunctionPointer<Func1> SignalType;
+ typedef QtPrivate::FunctionPointer<Func2> SlotType;
+ reinterpret_cast<typename SignalType::Object *>(0)->qt_check_for_QOBJECT_macro(*reinterpret_cast<typename SignalType::Object *>(0));
+
+ //compilation error if the arguments does not match.
+ Q_STATIC_ASSERT_X(int(SignalType::ArgumentCount) >= int(SlotType::ArgumentCount),
+ "The slot requires more arguments than the signal provides.");
+ Q_STATIC_ASSERT_X((QtPrivate::CheckCompatibleArguments<typename SignalType::Arguments, typename SlotType::Arguments>::value),
+ "Signal and slot arguments are not compatible.");
+ Q_STATIC_ASSERT_X((QtPrivate::AreArgumentsCompatible<typename SlotType::ReturnType, typename SignalType::ReturnType>::value),
+ "Return type of the slot is not compatible with the return type of the signal.");
+
+ const int *types = 0;
+ if (type == Qt::QueuedConnection || type == Qt::BlockingQueuedConnection)
+ types = QtPrivate::ConnectionTypes<typename SignalType::Arguments>::types();
+
+ return QObject::connectImpl(sender, reinterpret_cast<void **>(&signal),
+ receiverPrivate->q_func(), reinterpret_cast<void **>(&slot),
+ new QtPrivate::QPrivateSlotObject<Func2, typename QtPrivate::List_Left<typename SignalType::Arguments, SlotType::ArgumentCount>::Value,
+ typename SignalType::ReturnType>(slot),
+ type, types, &SignalType::Object::staticMetaObject);
+}
+
+template <typename Func1, typename Func2>
+bool QObjectPrivate::disconnect(const typename QtPrivate::FunctionPointer< Func1 >::Object* sender, Func1 signal,
+ const typename QtPrivate::FunctionPointer< Func2 >::Object* receiverPrivate, Func2 slot)
+{
+ typedef QtPrivate::FunctionPointer<Func1> SignalType;
+ typedef QtPrivate::FunctionPointer<Func2> SlotType;
+ reinterpret_cast<typename SignalType::Object *>(0)->qt_check_for_QOBJECT_macro(*reinterpret_cast<typename SignalType::Object *>(0));
+ //compilation error if the arguments does not match.
+ Q_STATIC_ASSERT_X((QtPrivate::CheckCompatibleArguments<typename SignalType::Arguments, typename SlotType::Arguments>::value),
+ "Signal and slot arguments are not compatible.");
+ return QObject::disconnectImpl(sender, reinterpret_cast<void **>(&signal),
+ receiverPrivate->q_func(), reinterpret_cast<void **>(&slot),
+ &SignalType::Object::staticMetaObject);
+}
Q_DECLARE_TYPEINFO(QObjectPrivate::Connection, Q_MOVABLE_TYPE);
Q_DECLARE_TYPEINFO(QObjectPrivate::Sender, Q_MOVABLE_TYPE);
diff --git a/src/corelib/kernel/qobjectcleanuphandler.h b/src/corelib/kernel/qobjectcleanuphandler.h
index 96faabc173..1f053cc34b 100644
--- a/src/corelib/kernel/qobjectcleanuphandler.h
+++ b/src/corelib/kernel/qobjectcleanuphandler.h
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -72,6 +70,4 @@ private Q_SLOTS:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QOBJECTCLEANUPHANDLER_H
diff --git a/src/corelib/kernel/qobjectdefs.h b/src/corelib/kernel/qobjectdefs.h
index a0617379d5..afbe1a5ece 100644
--- a/src/corelib/kernel/qobjectdefs.h
+++ b/src/corelib/kernel/qobjectdefs.h
@@ -46,8 +46,6 @@
#include <QtCore/qobjectdefs_impl.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -483,6 +481,4 @@ inline const QMetaObject *QMetaObject::superClass() const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QOBJECTDEFS_H
diff --git a/src/corelib/kernel/qobjectdefs_impl.h b/src/corelib/kernel/qobjectdefs_impl.h
index 68d8fdf961..4f44d9204e 100644
--- a/src/corelib/kernel/qobjectdefs_impl.h
+++ b/src/corelib/kernel/qobjectdefs_impl.h
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2013 Olivier Goffart <ogoffart@woboq.com>
** Contact: http://www.qt-project.org/legal
**
** This file is part of the QtCore module of the Qt Toolkit.
@@ -45,7 +46,10 @@
#error Do not include qobjectdefs_impl.h directly
#endif
-QT_BEGIN_HEADER
+#if 0
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
+#endif
QT_BEGIN_NAMESPACE
@@ -59,7 +63,7 @@ namespace QtPrivate {
/*
The following List classes are used to help to handle the list of arguments.
It follow the same principles as the lisp lists.
- List_Left<L,N> take a list and a number as a parametter and returns (via the Value typedef,
+ List_Left<L,N> take a list and a number as a parameter and returns (via the Value typedef,
the list composed of the first N element of the list
*/
#ifndef Q_COMPILER_VARIADIC_TEMPLATES
@@ -90,7 +94,7 @@ namespace QtPrivate {
template <typename T>
struct ApplyReturnValue {
void *data;
- ApplyReturnValue(void *data_) : data(data_) {}
+ explicit ApplyReturnValue(void *data_) : data(data_) {}
};
template<typename T, typename U>
void operator,(const T &value, const ApplyReturnValue<U> &container) {
@@ -113,7 +117,7 @@ namespace QtPrivate {
- ArgumentCount is the number of argument, or -1 if it is unknown
- the Object typedef is the Object of a pointer to member function
- the Arguments typedef is the list of argument (in a QtPrivate::List)
- - the Function typedef is an alias to the template parametter Func
+ - the Function typedef is an alias to the template parameter Func
- the call<Args, R>(f,o,args) method is used to call that slot
Args is the list of argument of the signal
R is the return type of the signal
@@ -594,13 +598,44 @@ namespace QtPrivate {
enum { value = AreArgumentsCompatible<typename RemoveConstRef<Arg1>::Type, typename RemoveConstRef<Arg2>::Type>::value
&& CheckCompatibleArguments<List<Tail1...>, List<Tail2...>>::value };
};
+#endif
+
+#if defined(Q_COMPILER_DECLTYPE) && defined(Q_COMPILER_VARIADIC_TEMPLATES)
+ /*
+ Find the maximum number of arguments a functor object can take and be still compatible with
+ the arguments from the signal.
+ Value is the number of arguments, or -1 if nothing matches.
+ */
+ template <typename Functor, typename ArgList> struct ComputeFunctorArgumentCount;
+
+ template <typename Functor, typename ArgList, bool Done> struct ComputeFunctorArgumentCountHelper
+ { enum { Value = -1 }; };
+ template <typename Functor, typename First, typename... ArgList>
+ struct ComputeFunctorArgumentCountHelper<Functor, List<First, ArgList...>, false>
+ : ComputeFunctorArgumentCount<Functor,
+ typename List_Left<List<First, ArgList...>, sizeof...(ArgList)>::Value> {};
+
+ template <typename Functor, typename... ArgList> struct ComputeFunctorArgumentCount<Functor, List<ArgList...>>
+ {
+ template <typename D> static D dummy();
+ template <typename F> static auto test(F f) -> decltype(((f.operator()((dummy<ArgList>())...)), int()));
+ static char test(...);
+ enum {
+ Ok = sizeof(test(dummy<Functor>())) == sizeof(int),
+ Value = Ok ? sizeof...(ArgList) : int(ComputeFunctorArgumentCountHelper<Functor, List<ArgList...>, Ok>::Value)
+ };
+ };
+ /* get the return type of a functor, given the signal argument list */
+ template <typename Functor, typename ArgList> struct FunctorReturnType;
+ template <typename Functor, typename ... ArgList> struct FunctorReturnType<Functor, List<ArgList...>> {
+ template <typename D> static D dummy();
+ typedef decltype(dummy<Functor>().operator()((dummy<ArgList>())...)) Value;
+ };
#endif
-}
+}
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/kernel/qpointer.cpp b/src/corelib/kernel/qpointer.cpp
index eea90be5eb..4fd6cd1779 100644
--- a/src/corelib/kernel/qpointer.cpp
+++ b/src/corelib/kernel/qpointer.cpp
@@ -158,6 +158,7 @@
/*!
\fn void QPointer::clear()
+ \since 5.0
Clears this QPointer object.
diff --git a/src/corelib/kernel/qpointer.h b/src/corelib/kernel/qpointer.h
index ebdeb156ba..230b6b66eb 100644
--- a/src/corelib/kernel/qpointer.h
+++ b/src/corelib/kernel/qpointer.h
@@ -46,67 +46,51 @@
#ifndef QT_NO_QOBJECT
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QVariant;
-class QPointerBase
-{
- QWeakPointer<QObject> wp;
-
-protected:
- inline QPointerBase() : wp() { }
- inline QPointerBase(QObject *p) : wp(p, true) { }
- // compiler-generated copy/move ctor/assignment operators are fine! (even though public)
- inline ~QPointerBase() { }
-
- inline QObject* data() const
- { return wp.data(); }
-
- inline void assign(QObject *p)
- { wp.assign(p); }
-
- inline bool isNull() const
- { return wp.isNull(); }
-
- inline void clear()
- { wp.clear(); }
-};
-
template <class T>
-class QPointer : private QPointerBase
+class QPointer
{
+ template<typename U>
+ struct TypeSelector
+ {
+ typedef QObject Type;
+ };
+ template<typename U>
+ struct TypeSelector<const U>
+ {
+ typedef const QObject Type;
+ };
+ typedef typename TypeSelector<T>::Type QObjectType;
+ QWeakPointer<QObjectType> wp;
public:
inline QPointer() { }
- inline QPointer(T *p) : QPointerBase(p) { }
+ inline QPointer(T *p) : wp(p, true) { }
// compiler-generated copy/move ctor/assignment operators are fine!
inline ~QPointer() { }
inline QPointer<T> &operator=(T* p)
- { QPointerBase::assign(p); return *this; }
+ { wp.assign(static_cast<QObjectType*>(p)); return *this; }
inline T* data() const
- { return static_cast<T*>(QPointerBase::data()); }
+ { return static_cast<T*>( wp.data()); }
inline T* operator->() const
{ return data(); }
inline T& operator*() const
{ return *data(); }
inline operator T*() const
{ return data(); }
-#ifdef Q_QDOC
- inline bool isNull() const;
- inline void clear();
-#else
- using QPointerBase::isNull;
- using QPointerBase::clear;
-#endif
+
+ inline bool isNull() const
+ { return wp.isNull(); }
+
+ inline void clear()
+ { wp.clear(); }
};
template <class T> Q_DECLARE_TYPEINFO_BODY(QPointer<T>, Q_MOVABLE_TYPE);
-#if (!defined(Q_CC_SUN) || (__SUNPRO_CC >= 0x580)) // ambiguity between const T * and T *
-
template <class T>
inline bool operator==(const T *o, const QPointer<T> &p)
{ return o == p.operator->(); }
@@ -115,18 +99,6 @@ template<class T>
inline bool operator==(const QPointer<T> &p, const T *o)
{ return p.operator->() == o; }
-#else
-
-template<class T>
-inline bool operator==(const void *o, const QPointer<T> &p)
-{ return o == p.operator->(); }
-
-template<class T>
-inline bool operator==(const QPointer<T> &p, const void *o)
-{ return p.operator->() == o; }
-
-#endif
-
template <class T>
inline bool operator==(T *o, const QPointer<T> &p)
{ return o == p.operator->(); }
@@ -139,9 +111,6 @@ template<class T>
inline bool operator==(const QPointer<T> &p1, const QPointer<T> &p2)
{ return p1.operator->() == p2.operator->(); }
-
-#if (!defined(Q_CC_SUN) || (__SUNPRO_CC >= 0x580)) // ambiguity between const T * and T *
-
template <class T>
inline bool operator!=(const T *o, const QPointer<T> &p)
{ return o != p.operator->(); }
@@ -150,18 +119,6 @@ template<class T>
inline bool operator!= (const QPointer<T> &p, const T *o)
{ return p.operator->() != o; }
-#else
-
-template<class T>
-inline bool operator!= (const void *o, const QPointer<T> &p)
-{ return o != p.operator->(); }
-
-template<class T>
-inline bool operator!= (const QPointer<T> &p, const void *o)
-{ return p.operator->() != o; }
-
-#endif
-
template <class T>
inline bool operator!=(T *o, const QPointer<T> &p)
{ return o != p.operator->(); }
@@ -174,17 +131,6 @@ template<class T>
inline bool operator!= (const QPointer<T> &p1, const QPointer<T> &p2)
{ return p1.operator->() != p2.operator->() ; }
-// Make MSVC < 1400 (2005) handle "if (NULL == p)" syntax
-#if defined(Q_CC_MSVC) && (_MSC_VER < 1400)
-template<class T>
-inline bool operator== (int i, const QPointer<T> &p)
-{ Q_ASSERT(i == 0); return !i && p.isNull(); }
-
-template<class T>
-inline bool operator!= (int i, const QPointer<T> &p)
-{ Q_ASSERT(i == 0); return !i && !p.isNull(); }
-#endif
-
template<typename T>
QPointer<T>
qPointerFromVariant(const QVariant &variant)
@@ -194,8 +140,6 @@ qPointerFromVariant(const QVariant &variant)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_QOBJECT
#endif // QPOINTER_H
diff --git a/src/corelib/kernel/qsharedmemory.h b/src/corelib/kernel/qsharedmemory.h
index d87ba02ac9..6b44548f44 100644
--- a/src/corelib/kernel/qsharedmemory.h
+++ b/src/corelib/kernel/qsharedmemory.h
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -114,7 +112,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSHAREDMEMORY_H
diff --git a/src/corelib/kernel/qsharedmemory_p.h b/src/corelib/kernel/qsharedmemory_p.h
index dd9856adf5..9f1e6c8aa1 100644
--- a/src/corelib/kernel/qsharedmemory_p.h
+++ b/src/corelib/kernel/qsharedmemory_p.h
@@ -69,7 +69,7 @@ namespace QSharedMemoryPrivate
#include "qsystemsemaphore.h"
#include "private/qobject_p.h"
-#if !defined(Q_OS_WIN) && !defined(Q_OS_LINUX_ANDROID)
+#if !defined(Q_OS_WIN) && !defined(Q_OS_ANDROID)
# include <sys/sem.h>
#endif
diff --git a/src/corelib/kernel/qsharedmemory_unix.cpp b/src/corelib/kernel/qsharedmemory_unix.cpp
index 7f13e3b1a2..fdd73657a9 100644
--- a/src/corelib/kernel/qsharedmemory_unix.cpp
+++ b/src/corelib/kernel/qsharedmemory_unix.cpp
@@ -151,9 +151,6 @@ key_t QSharedMemoryPrivate::handle()
*/
int QSharedMemoryPrivate::createUnixKeyFile(const QString &fileName)
{
- if (QFile::exists(fileName))
- return 0;
-
int fd = qt_safe_open(QFile::encodeName(fileName).constData(),
O_EXCL | O_CREAT | O_RDWR, 0640);
if (-1 == fd) {
diff --git a/src/corelib/kernel/qsignalmapper.h b/src/corelib/kernel/qsignalmapper.h
index f1f4428118..997e8e46de 100644
--- a/src/corelib/kernel/qsignalmapper.h
+++ b/src/corelib/kernel/qsignalmapper.h
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QSignalMapperPrivate;
@@ -86,6 +84,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSIGNALMAPPER_H
diff --git a/src/corelib/kernel/qsocketnotifier.cpp b/src/corelib/kernel/qsocketnotifier.cpp
index ad687491f1..e0c7f171c3 100644
--- a/src/corelib/kernel/qsocketnotifier.cpp
+++ b/src/corelib/kernel/qsocketnotifier.cpp
@@ -187,10 +187,10 @@ QSocketNotifier::QSocketNotifier(qintptr socket, Type type, QObject *parent)
d->sntype = type;
d->snenabled = true;
- if (!d->threadData->eventDispatcher) {
+ if (!d->threadData->eventDispatcher.load()) {
qWarning("QSocketNotifier: Can only be used with threads started with QThread");
} else {
- d->threadData->eventDispatcher->registerSocketNotifier(this);
+ d->threadData->eventDispatcher.load()->registerSocketNotifier(this);
}
}
@@ -273,12 +273,12 @@ void QSocketNotifier::setEnabled(bool enable)
return;
d->snenabled = enable;
- if (!d->threadData->eventDispatcher) // perhaps application/thread is shutting down
+ if (!d->threadData->eventDispatcher.load()) // perhaps application/thread is shutting down
return;
if (d->snenabled)
- d->threadData->eventDispatcher->registerSocketNotifier(this);
+ d->threadData->eventDispatcher.load()->registerSocketNotifier(this);
else
- d->threadData->eventDispatcher->unregisterSocketNotifier(this);
+ d->threadData->eventDispatcher.load()->unregisterSocketNotifier(this);
}
diff --git a/src/corelib/kernel/qsocketnotifier.h b/src/corelib/kernel/qsocketnotifier.h
index 97321521e4..8cc6b9c4c4 100644
--- a/src/corelib/kernel/qsocketnotifier.h
+++ b/src/corelib/kernel/qsocketnotifier.h
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QSocketNotifierPrivate;
@@ -84,6 +82,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSOCKETNOTIFIER_H
diff --git a/src/corelib/kernel/qsystemerror_p.h b/src/corelib/kernel/qsystemerror_p.h
index 94bfb5deb4..4b46011129 100644
--- a/src/corelib/kernel/qsystemerror_p.h
+++ b/src/corelib/kernel/qsystemerror_p.h
@@ -66,14 +66,14 @@ public:
StandardLibraryError,
NativeError
};
-
+
inline QSystemError(int error, ErrorScope scope);
inline QSystemError();
-
+
QString toString();
inline ErrorScope scope();
inline int error();
-
+
//data members
int errorCode;
ErrorScope errorScope;
diff --git a/src/corelib/kernel/qsystemsemaphore.h b/src/corelib/kernel/qsystemsemaphore.h
index 52547f0c1f..b7dd220832 100644
--- a/src/corelib/kernel/qsystemsemaphore.h
+++ b/src/corelib/kernel/qsystemsemaphore.h
@@ -45,8 +45,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qscopedpointer.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -96,7 +94,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSYSTEMSEMAPHORE_H
diff --git a/src/corelib/kernel/qsystemsemaphore_win.cpp b/src/corelib/kernel/qsystemsemaphore_win.cpp
index 6b064c1d52..835a9fde5b 100644
--- a/src/corelib/kernel/qsystemsemaphore_win.cpp
+++ b/src/corelib/kernel/qsystemsemaphore_win.cpp
@@ -46,7 +46,7 @@
#include <qt_windows.h>
QT_BEGIN_NAMESPACE
-
+
#ifndef QT_NO_SYSTEMSEMAPHORE
QSystemSemaphorePrivate::QSystemSemaphorePrivate() :
diff --git a/src/corelib/kernel/qtimer.h b/src/corelib/kernel/qtimer.h
index 9a90ecc772..3484f4dba8 100644
--- a/src/corelib/kernel/qtimer.h
+++ b/src/corelib/kernel/qtimer.h
@@ -42,13 +42,13 @@
#ifndef QTIMER_H
#define QTIMER_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_QOBJECT
#include <QtCore/qbasictimer.h> // conceptual inheritance
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -114,8 +114,6 @@ inline void QTimer::setSingleShot(bool asingleShot) { single = asingleShot; }
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_QOBJECT
#endif // QTIMER_H
diff --git a/src/corelib/kernel/qtimerinfo_unix.cpp b/src/corelib/kernel/qtimerinfo_unix.cpp
index 0eee425cf9..0e33fa697a 100644
--- a/src/corelib/kernel/qtimerinfo_unix.cpp
+++ b/src/corelib/kernel/qtimerinfo_unix.cpp
@@ -77,7 +77,7 @@ QTimerInfoList::QTimerInfoList()
msPerTick = 1000/ticksPerSecond;
} else {
// detected monotonic timers
- previousTime.tv_sec = previousTime.tv_usec = 0;
+ previousTime.tv_sec = previousTime.tv_nsec = 0;
previousTicks = 0;
ticksPerSecond = 0;
msPerTick = 0;
@@ -87,25 +87,24 @@ QTimerInfoList::QTimerInfoList()
firstTimerInfo = 0;
}
-timeval QTimerInfoList::updateCurrentTime()
+timespec QTimerInfoList::updateCurrentTime()
{
return (currentTime = qt_gettime());
}
#if ((_POSIX_MONOTONIC_CLOCK-0 <= 0) && !defined(Q_OS_MAC) && !defined(Q_OS_INTEGRITY)) || defined(QT_BOOTSTRAPPED)
-template <>
-timeval qAbs(const timeval &t)
+timespec qAbsTimespec(const timespec &t)
{
- timeval tmp = t;
+ timespec tmp = t;
if (tmp.tv_sec < 0) {
tmp.tv_sec = -tmp.tv_sec - 1;
- tmp.tv_usec -= 1000000;
+ tmp.tv_nsec -= 1000000000;
}
- if (tmp.tv_sec == 0 && tmp.tv_usec < 0) {
- tmp.tv_usec = -tmp.tv_usec;
+ if (tmp.tv_sec == 0 && tmp.tv_nsec < 0) {
+ tmp.tv_nsec = -tmp.tv_nsec;
}
- return normalizedTimeval(tmp);
+ return normalizedTimespec(tmp);
}
/*
@@ -115,7 +114,7 @@ timeval qAbs(const timeval &t)
If /a delta is nonzero, delta is set to our best guess at how much the system clock was changed.
*/
-bool QTimerInfoList::timeChanged(timeval *delta)
+bool QTimerInfoList::timeChanged(timespec *delta)
{
#ifdef Q_OS_NACL
Q_UNUSED(delta)
@@ -125,13 +124,13 @@ bool QTimerInfoList::timeChanged(timeval *delta)
clock_t currentTicks = times(&unused);
clock_t elapsedTicks = currentTicks - previousTicks;
- timeval elapsedTime = currentTime - previousTime;
+ timespec elapsedTime = currentTime - previousTime;
- timeval elapsedTimeTicks;
+ timespec elapsedTimeTicks;
elapsedTimeTicks.tv_sec = elapsedTicks / ticksPerSecond;
- elapsedTimeTicks.tv_usec = (((elapsedTicks * 1000) / ticksPerSecond) % 1000) * 1000;
+ elapsedTimeTicks.tv_nsec = (((elapsedTicks * 1000) / ticksPerSecond) % 1000) * 1000 * 1000;
- timeval dummy;
+ timespec dummy;
if (!delta)
delta = &dummy;
*delta = elapsedTime - elapsedTimeTicks;
@@ -141,16 +140,16 @@ bool QTimerInfoList::timeChanged(timeval *delta)
// If tick drift is more than 10% off compared to realtime, we assume that the clock has
// been set. Of course, we have to allow for the tick granularity as well.
- timeval tickGranularity;
+ timespec tickGranularity;
tickGranularity.tv_sec = 0;
- tickGranularity.tv_usec = msPerTick * 1000;
- return elapsedTimeTicks < ((qAbs(*delta) - tickGranularity) * 10);
+ tickGranularity.tv_nsec = msPerTick * 1000 * 1000;
+ return elapsedTimeTicks < ((qAbsTimespec(*delta) - tickGranularity) * 10);
}
/*
repair broken timer
*/
-void QTimerInfoList::timerRepair(const timeval &diff)
+void QTimerInfoList::timerRepair(const timespec &diff)
{
// repair all timers
for (int i = 0; i < size(); ++i) {
@@ -163,7 +162,7 @@ void QTimerInfoList::repairTimersIfNeeded()
{
if (QElapsedTimer::isMonotonic())
return;
- timeval delta;
+ timespec delta;
if (timeChanged(&delta))
timerRepair(delta);
}
@@ -190,27 +189,27 @@ void QTimerInfoList::timerInsert(QTimerInfo *ti)
insert(index+1, ti);
}
-inline timeval &operator+=(timeval &t1, int ms)
+inline timespec &operator+=(timespec &t1, int ms)
{
t1.tv_sec += ms / 1000;
- t1.tv_usec += ms % 1000 * 1000;
- return normalizedTimeval(t1);
+ t1.tv_nsec += ms % 1000 * 1000 * 1000;
+ return normalizedTimespec(t1);
}
-inline timeval operator+(const timeval &t1, int ms)
+inline timespec operator+(const timespec &t1, int ms)
{
- timeval t2 = t1;
+ timespec t2 = t1;
return t2 += ms;
}
-static timeval roundToMillisecond(timeval val)
+static timespec roundToMillisecond(timespec val)
{
// always round up
// worst case scenario is that the first trigger of a 1-ms timer is 0.999 ms late
- int us = val.tv_usec % 1000;
- val.tv_usec += 1000 - us;
- return normalizedTimeval(val);
+ int ns = val.tv_nsec % (1000 * 1000);
+ val.tv_nsec += 1000 * 1000 - ns;
+ return normalizedTimespec(val);
}
#ifdef QTIMERINFO_DEBUG
@@ -227,7 +226,7 @@ QDebug operator<<(QDebug s, Qt::TimerType t)
}
#endif
-static void calculateCoarseTimerTimeout(QTimerInfo *t, timeval currentTime)
+static void calculateCoarseTimerTimeout(QTimerInfo *t, timespec currentTime)
{
// The coarse timer works like this:
// - interval under 40 ms: round to even
@@ -246,7 +245,7 @@ static void calculateCoarseTimerTimeout(QTimerInfo *t, timeval currentTime)
// The objective is to make most timers wake up at the same time, thereby reducing CPU wakeups.
register uint interval = uint(t->interval);
- register uint msec = uint(t->timeout.tv_usec) / 1000;
+ register uint msec = uint(t->timeout.tv_nsec) / 1000 / 1000;
Q_ASSERT(interval >= 20);
// Calculate how much we can round and still keep within 5% error
@@ -328,16 +327,16 @@ static void calculateCoarseTimerTimeout(QTimerInfo *t, timeval currentTime)
recalculate:
if (msec == 1000u) {
++t->timeout.tv_sec;
- t->timeout.tv_usec = 0;
+ t->timeout.tv_nsec = 0;
} else {
- t->timeout.tv_usec = msec * 1000;
+ t->timeout.tv_nsec = msec * 1000 * 1000;
}
if (t->timeout < currentTime)
t->timeout += interval;
}
-static void calculateNextTimeout(QTimerInfo *t, timeval currentTime)
+static void calculateNextTimeout(QTimerInfo *t, timespec currentTime)
{
switch (t->timerType) {
case Qt::PreciseTimer:
@@ -383,9 +382,9 @@ static void calculateNextTimeout(QTimerInfo *t, timeval currentTime)
Returns the time to wait for the next timer, or null if no timers
are waiting.
*/
-bool QTimerInfoList::timerWait(timeval &tm)
+bool QTimerInfoList::timerWait(timespec &tm)
{
- timeval currentTime = updateCurrentTime();
+ timespec currentTime = updateCurrentTime();
repairTimersIfNeeded();
// Find first waiting timer not already active
@@ -406,7 +405,7 @@ bool QTimerInfoList::timerWait(timeval &tm)
} else {
// no time to wait
tm.tv_sec = 0;
- tm.tv_usec = 0;
+ tm.tv_nsec = 0;
}
return true;
@@ -419,9 +418,9 @@ bool QTimerInfoList::timerWait(timeval &tm)
*/
int QTimerInfoList::timerRemainingTime(int timerId)
{
- timeval currentTime = updateCurrentTime();
+ timespec currentTime = updateCurrentTime();
repairTimersIfNeeded();
- timeval tm = {0, 0};
+ timespec tm = {0, 0};
for (int i = 0; i < count(); ++i) {
register QTimerInfo *t = at(i);
@@ -429,7 +428,7 @@ int QTimerInfoList::timerRemainingTime(int timerId)
if (currentTime < t->timeout) {
// time to wait
tm = roundToMillisecond(t->timeout - currentTime);
- return tm.tv_sec*1000 + tm.tv_usec/1000;
+ return tm.tv_sec*1000 + tm.tv_nsec/1000/1000;
} else {
return 0;
}
@@ -452,7 +451,7 @@ void QTimerInfoList::registerTimer(int timerId, int interval, Qt::TimerType time
t->obj = object;
t->activateRef = 0;
- timeval expected = updateCurrentTime() + interval;
+ timespec expected = updateCurrentTime() + interval;
switch (timerType) {
case Qt::PreciseTimer:
@@ -487,10 +486,10 @@ void QTimerInfoList::registerTimer(int timerId, int interval, Qt::TimerType time
t->interval += 1;
t->interval >>= 1;
t->timeout.tv_sec = currentTime.tv_sec + t->interval;
- t->timeout.tv_usec = 0;
+ t->timeout.tv_nsec = 0;
// if we're past the half-second mark, increase the timeout again
- if (currentTime.tv_usec > 500*1000)
+ if (currentTime.tv_nsec > 500*1000*1000)
++t->timeout.tv_sec;
}
@@ -574,7 +573,7 @@ int QTimerInfoList::activateTimers()
int n_act = 0, maxCount = 0;
firstTimerInfo = 0;
- timeval currentTime = updateCurrentTime();
+ timespec currentTime = updateCurrentTime();
// qDebug() << "Thread" << QThread::currentThreadId() << "woken up at" << currentTime;
repairTimersIfNeeded();
diff --git a/src/corelib/kernel/qtimerinfo_unix_p.h b/src/corelib/kernel/qtimerinfo_unix_p.h
index 549062bd1f..ec7560429b 100644
--- a/src/corelib/kernel/qtimerinfo_unix_p.h
+++ b/src/corelib/kernel/qtimerinfo_unix_p.h
@@ -66,7 +66,7 @@ struct QTimerInfo {
int id; // - timer identifier
int interval; // - timer interval in milliseconds
Qt::TimerType timerType; // - timer type
- timeval timeout; // - when to actually fire
+ timespec timeout; // - when to actually fire
QObject *obj; // - object to receive event
QTimerInfo **activateRef; // - ref from activateTimers
@@ -80,13 +80,13 @@ struct QTimerInfo {
class Q_CORE_EXPORT QTimerInfoList : public QList<QTimerInfo*>
{
#if ((_POSIX_MONOTONIC_CLOCK-0 <= 0) && !defined(Q_OS_MAC)) || defined(QT_BOOTSTRAPPED)
- timeval previousTime;
+ timespec previousTime;
clock_t previousTicks;
int ticksPerSecond;
int msPerTick;
- bool timeChanged(timeval *delta);
- void timerRepair(const timeval &);
+ bool timeChanged(timespec *delta);
+ void timerRepair(const timespec &);
#endif
// state variables used by activateTimers()
@@ -95,13 +95,13 @@ class Q_CORE_EXPORT QTimerInfoList : public QList<QTimerInfo*>
public:
QTimerInfoList();
- timeval currentTime;
- timeval updateCurrentTime();
+ timespec currentTime;
+ timespec updateCurrentTime();
// must call updateCurrentTime() first!
void repairTimersIfNeeded();
- bool timerWait(timeval &);
+ bool timerWait(timespec &);
void timerInsert(QTimerInfo *);
int timerRemainingTime(int timerId);
diff --git a/src/corelib/kernel/qtranslator.h b/src/corelib/kernel/qtranslator.h
index 98c0b81c97..c3957aff3f 100644
--- a/src/corelib/kernel/qtranslator.h
+++ b/src/corelib/kernel/qtranslator.h
@@ -45,8 +45,6 @@
#include <QtCore/qobject.h>
#include <QtCore/qbytearray.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -87,6 +85,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTRANSLATOR_H
diff --git a/src/corelib/kernel/qvariant.cpp b/src/corelib/kernel/qvariant.cpp
index ad7ce708ad..bae4a837a0 100644
--- a/src/corelib/kernel/qvariant.cpp
+++ b/src/corelib/kernel/qvariant.cpp
@@ -971,7 +971,7 @@ Q_CORE_EXPORT void QVariantPrivate::registerHandler(const int /* Modules::Names
QVariant to convert between types given suitable data; it is still
possible to supply data which cannot actually be converted.
- For example, canConvert() would return true when called on a variant
+ For example, canConvert(Int) would return true when called on a variant
containing a string because, in principle, QVariant is able to convert
strings of numbers to integers.
However, if the string contains non-numeric characters, it cannot be
@@ -1529,10 +1529,13 @@ QVariant::QVariant(const QLocale &l)
QVariant::QVariant(const QRegExp &regExp)
: d(RegExp)
{ v_construct<QRegExp>(&d, regExp); }
+#endif // QT_NO_REGEXP
#ifndef QT_BOOTSTRAPPED
+#ifndef QT_NO_REGULAREXPRESSION
QVariant::QVariant(const QRegularExpression &re)
: d(RegularExpression)
{ v_construct<QRegularExpression>(&d, re); }
+#endif
QVariant::QVariant(const QUuid &uuid)
: d(Uuid)
{ v_construct<QUuid>(&d, uuid); }
@@ -1552,7 +1555,6 @@ QVariant::QVariant(const QJsonDocument &jsonDocument)
: d(QMetaType::QJsonDocument)
{ v_construct<QJsonDocument>(&d, jsonDocument); }
#endif // QT_BOOTSTRAPPED
-#endif // QT_NO_REGEXP
/*!
Returns the storage type of the value stored in the variant.
@@ -2222,6 +2224,7 @@ QRegExp QVariant::toRegExp() const
}
#endif
+#ifndef QT_BOOTSTRAPPED
/*!
\fn QRegularExpression QVariant::toRegularExpression() const
\since 5.0
@@ -2231,13 +2234,12 @@ QRegExp QVariant::toRegExp() const
\sa canConvert(), convert()
*/
-#ifndef QT_BOOTSTRAPPED
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
QRegularExpression QVariant::toRegularExpression() const
{
return qVariantToHelper<QRegularExpression>(d, handlerManager);
}
-#endif
+#endif // QT_NO_REGULAREXPRESSION
/*!
\since 5.0
diff --git a/src/corelib/kernel/qvariant.h b/src/corelib/kernel/qvariant.h
index d21f48f98c..6f212f5000 100644
--- a/src/corelib/kernel/qvariant.h
+++ b/src/corelib/kernel/qvariant.h
@@ -51,8 +51,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -76,8 +74,10 @@ class QRect;
class QRectF;
#ifndef QT_NO_REGEXP
class QRegExp;
-class QRegularExpression;
#endif // QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
+class QRegularExpression;
+#endif // QT_NO_REGULAREXPRESSION
class QTextFormat;
class QTextLength;
class QUrl;
@@ -240,11 +240,11 @@ class Q_CORE_EXPORT QVariant
QVariant(const QLocale &locale);
#ifndef QT_NO_REGEXP
QVariant(const QRegExp &regExp);
-#ifndef QT_BOOTSRAPPED
- QVariant(const QRegularExpression &re);
-#endif // QT_BOOTSTRAPPED
#endif // QT_NO_REGEXP
#ifndef QT_BOOTSTRAPPED
+#ifndef QT_NO_REGULAREXPRESSION
+ QVariant(const QRegularExpression &re);
+#endif // QT_NO_REGULAREXPRESSION
QVariant(const QUrl &url);
QVariant(const QEasingCurve &easing);
QVariant(const QUuid &uuid);
@@ -253,7 +253,7 @@ class Q_CORE_EXPORT QVariant
QVariant(const QJsonObject &jsonObject);
QVariant(const QJsonArray &jsonArray);
QVariant(const QJsonDocument &jsonDocument);
-#endif
+#endif // QT_BOOTSTRAPPED
QVariant& operator=(const QVariant &other);
#ifdef Q_COMPILER_RVALUE_REFS
@@ -313,11 +313,11 @@ class Q_CORE_EXPORT QVariant
QLocale toLocale() const;
#ifndef QT_NO_REGEXP
QRegExp toRegExp() const;
-#ifndef QT_BOOTSTRAPPED
- QRegularExpression toRegularExpression() const;
-#endif // QT_BOOTSTRAPPED
#endif // QT_NO_REGEXP
#ifndef QT_BOOTSTRAPPED
+#ifndef QT_NO_REGULAREXPRESSION
+ QRegularExpression toRegularExpression() const;
+#endif // QT_NO_REGULAREXPRESSION
QUrl toUrl() const;
QEasingCurve toEasingCurve() const;
QUuid toUuid() const;
@@ -326,7 +326,7 @@ class Q_CORE_EXPORT QVariant
QJsonObject toJsonObject() const;
QJsonArray toJsonArray() const;
QJsonDocument toJsonDocument() const;
-#endif
+#endif // QT_BOOTSTRAPPED
#ifndef QT_NO_DATASTREAM
void load(QDataStream &ds);
@@ -484,7 +484,7 @@ public:
template <typename T>
inline QVariant qVariantFromValue(const T &t)
{
- return QVariant(qMetaTypeId<T>(reinterpret_cast<T *>(0)), &t, QTypeInfo<T>::isPointer);
+ return QVariant(qMetaTypeId<T>(), &t, QTypeInfo<T>::isPointer);
}
template <>
@@ -494,7 +494,7 @@ template <typename T>
inline void qVariantSetValue(QVariant &v, const T &t)
{
//if possible we reuse the current QVariant private
- const uint type = qMetaTypeId<T>(reinterpret_cast<T *>(0));
+ const uint type = qMetaTypeId<T>();
QVariant::Private &d = v.data_ptr();
if (v.isDetached() && (type == d.type || (type <= uint(QVariant::Char) && d.type <= uint(QVariant::Char)))) {
d.type = type;
@@ -568,7 +568,7 @@ namespace QtPrivate {
{
static T metaType(const QVariant &v)
{
- const int vid = qMetaTypeId<T>(static_cast<T *>(0));
+ const int vid = qMetaTypeId<T>();
if (vid == v.userType())
return *reinterpret_cast<const T *>(v.constData());
if (vid < int(QMetaType::User)) {
@@ -620,6 +620,4 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QVariant::Type);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QVARIANT_H
diff --git a/src/corelib/kernel/qvariant_p.h b/src/corelib/kernel/qvariant_p.h
index e7940e0039..04b9d92f55 100644
--- a/src/corelib/kernel/qvariant_p.h
+++ b/src/corelib/kernel/qvariant_p.h
@@ -150,7 +150,7 @@ inline void v_construct(QVariant::Private *x, const T &t)
template <class T>
inline void v_clear(QVariant::Private *d, T* = 0)
{
-
+
if (!QVariantIntegrator<T>::CanUseInternalSpace) {
//now we need to cast
//because QVariant::PrivateShared doesn't have a virtual destructor
diff --git a/src/corelib/kernel/qwineventnotifier.cpp b/src/corelib/kernel/qwineventnotifier.cpp
index f24843dc4a..242702b304 100644
--- a/src/corelib/kernel/qwineventnotifier.cpp
+++ b/src/corelib/kernel/qwineventnotifier.cpp
@@ -135,7 +135,7 @@ QWinEventNotifier::QWinEventNotifier(HANDLE hEvent, QObject *parent)
: QObject(*new QWinEventNotifierPrivate(hEvent, false), parent)
{
Q_D(QWinEventNotifier);
- QAbstractEventDispatcher *eventDispatcher = d->threadData->eventDispatcher;
+ QAbstractEventDispatcher *eventDispatcher = d->threadData->eventDispatcher.load();
if (!eventDispatcher) {
qWarning("QWinEventNotifier: Can only be used with threads started with QThread");
} else {
@@ -208,7 +208,7 @@ void QWinEventNotifier::setEnabled(bool enable)
return;
d->enabled = enable;
- QAbstractEventDispatcher *eventDispatcher = d->threadData->eventDispatcher;
+ QAbstractEventDispatcher *eventDispatcher = d->threadData->eventDispatcher.load();
if (!eventDispatcher) // perhaps application is shutting down
return;
diff --git a/src/corelib/kernel/qwineventnotifier.h b/src/corelib/kernel/qwineventnotifier.h
index ca84054d71..56605d9aaa 100644
--- a/src/corelib/kernel/qwineventnotifier.h
+++ b/src/corelib/kernel/qwineventnotifier.h
@@ -47,8 +47,6 @@
#ifdef Q_OS_WIN
#include "QtCore/qt_windows.h"
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QWinEventNotifierPrivate;
@@ -83,8 +81,6 @@ protected:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // Q_OS_WIN
#endif // QWINEVENTNOTIFIER_H
diff --git a/src/corelib/mimetypes/qmimedatabase.cpp b/src/corelib/mimetypes/qmimedatabase.cpp
index d8b7a02a1b..a5f5a326d4 100644
--- a/src/corelib/mimetypes/qmimedatabase.cpp
+++ b/src/corelib/mimetypes/qmimedatabase.cpp
@@ -418,7 +418,7 @@ QMimeType QMimeDatabase::mimeTypeForFile(const QString &fileName, MatchMode mode
} else {
// Implemented as a wrapper around mimeTypeForFile(QFileInfo), so no mutex.
QFileInfo fileInfo(fileName);
- return mimeTypeForFile(fileInfo);
+ return mimeTypeForFile(fileInfo, mode);
}
}
diff --git a/src/corelib/mimetypes/qmimedatabase.h b/src/corelib/mimetypes/qmimedatabase.h
index a567d99749..17684e49da 100644
--- a/src/corelib/mimetypes/qmimedatabase.h
+++ b/src/corelib/mimetypes/qmimedatabase.h
@@ -45,7 +45,6 @@
#include <QtCore/qmimetype.h>
#include <QtCore/qstringlist.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
class QByteArray;
@@ -90,6 +89,4 @@ private:
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMIMEDATABASE_H
diff --git a/src/corelib/mimetypes/qmimetype.h b/src/corelib/mimetypes/qmimetype.h
index dcab8153ab..24d043eebc 100644
--- a/src/corelib/mimetypes/qmimetype.h
+++ b/src/corelib/mimetypes/qmimetype.h
@@ -45,7 +45,6 @@
#include <QtCore/qshareddata.h>
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
class QMimeTypePrivate;
@@ -112,6 +111,4 @@ protected:
Q_DECLARE_SHARED(QMimeType)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMIMETYPE_H
diff --git a/src/corelib/plugin/qfactoryinterface.h b/src/corelib/plugin/qfactoryinterface.h
index 59bce69022..88fb1bf599 100644
--- a/src/corelib/plugin/qfactoryinterface.h
+++ b/src/corelib/plugin/qfactoryinterface.h
@@ -45,8 +45,6 @@
#include <QtCore/qobject.h>
#include <QtCore/qstringlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -61,6 +59,4 @@ Q_DECLARE_INTERFACE(QFactoryInterface, "org.qt-project.Qt.QFactoryInterface")
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFACTORYINTERFACE_H
diff --git a/src/corelib/plugin/qlibrary.cpp b/src/corelib/plugin/qlibrary.cpp
index d17067684a..3432f9619d 100644
--- a/src/corelib/plugin/qlibrary.cpp
+++ b/src/corelib/plugin/qlibrary.cpp
@@ -79,8 +79,6 @@ QT_BEGIN_NAMESPACE
# define QT_NO_DEBUG_PLUGIN_CHECK
#endif
-static QBasicMutex qt_library_mutex;
-
/*!
\class QLibrary
\inmodule QtCore
@@ -339,46 +337,134 @@ static void installCoverageTool(QLibraryPrivate *libPrivate)
#endif
}
-typedef QMap<QString, QLibraryPrivate*> LibraryMap;
+class QLibraryStore
+{
+public:
+ inline ~QLibraryStore();
+ static inline QLibraryPrivate *findOrCreate(const QString &fileName, const QString &version);
+ static inline void releaseLibrary(QLibraryPrivate *lib);
+
+ static inline void cleanup();
-struct LibraryData {
+private:
+ static inline QLibraryStore *instance();
+
+ // all members and instance() are protected by qt_library_mutex
+ typedef QMap<QString, QLibraryPrivate*> LibraryMap;
LibraryMap libraryMap;
- QSet<QLibraryPrivate*> loadedLibs;
};
-Q_GLOBAL_STATIC(LibraryData, libraryData)
+static QBasicMutex qt_library_mutex;
+static QLibraryStore *qt_library_data = 0;
+
+QLibraryStore::~QLibraryStore()
+{
+ qt_library_data = 0;
+}
+
+inline void QLibraryStore::cleanup()
+{
+ QLibraryStore *data = qt_library_data;
+ if (!data)
+ return;
+
+ // find any libraries that are still loaded but have a no one attached to them
+ LibraryMap::Iterator it = data->libraryMap.begin();
+ for (; it != data->libraryMap.end(); ++it) {
+ QLibraryPrivate *lib = it.value();
+ if (lib->libraryRefCount.load() == 1) {
+ if (lib->libraryUnloadCount.load() > 0) {
+ Q_ASSERT(lib->pHnd);
+ lib->libraryUnloadCount.store(1);
+#ifdef __GLIBC__
+ // glibc has a bug in unloading from global destructors
+ // see https://bugzilla.novell.com/show_bug.cgi?id=622977
+ // and http://sourceware.org/bugzilla/show_bug.cgi?id=11941
+ lib->unload(QLibraryPrivate::NoUnloadSys);
+#else
+ lib->unload();
+#endif
+ }
+ delete lib;
+ it.value() = 0;
+ }
+ }
+
+ if (qt_debug_component()) {
+ // dump all objects that remain
+ foreach (QLibraryPrivate *lib, data->libraryMap) {
+ if (lib)
+ qDebug() << "On QtCore unload," << lib->fileName << "was leaked, with"
+ << lib->libraryRefCount.load() << "users";
+ }
+ }
+
+ delete data;
+}
+
+static void qlibraryCleanup()
+{
+ QLibraryStore::cleanup();
+}
+Q_DESTRUCTOR_FUNCTION(qlibraryCleanup)
+
+// must be called with a locked mutex
+QLibraryStore *QLibraryStore::instance()
+{
+ if (Q_UNLIKELY(!qt_library_data))
+ qt_library_data = new QLibraryStore;
+ return qt_library_data;
+}
-static LibraryMap *libraryMap()
+inline QLibraryPrivate *QLibraryStore::findOrCreate(const QString &fileName, const QString &version)
{
- LibraryData *data = libraryData();
- return data ? &data->libraryMap : 0;
+ QMutexLocker locker(&qt_library_mutex);
+ QLibraryStore *data = instance();
+
+ // check if this library is already loaded
+ QLibraryPrivate *lib = data->libraryMap.value(fileName);
+ if (!lib)
+ lib = new QLibraryPrivate(fileName, version);
+
+ // track this library
+ data->libraryMap.insert(fileName, lib);
+
+ lib->libraryRefCount.ref();
+ return lib;
+}
+
+inline void QLibraryStore::releaseLibrary(QLibraryPrivate *lib)
+{
+ QMutexLocker locker(&qt_library_mutex);
+ QLibraryStore *data = instance();
+
+ if (lib->libraryRefCount.deref()) {
+ // still in use
+ return;
+ }
+
+ // no one else is using
+ Q_ASSERT(lib->libraryUnloadCount.load() == 0);
+
+ QLibraryPrivate *that = data->libraryMap.take(lib->fileName);
+ Q_ASSERT(lib == that);
+ Q_UNUSED(that);
+ delete lib;
}
QLibraryPrivate::QLibraryPrivate(const QString &canonicalFileName, const QString &version)
: pHnd(0), fileName(canonicalFileName), fullVersion(version), instance(0),
loadHints(0),
- libraryRefCount(1), libraryUnloadCount(0), pluginState(MightBeAPlugin)
-{ libraryMap()->insert(canonicalFileName, this); }
+ libraryRefCount(0), libraryUnloadCount(0), pluginState(MightBeAPlugin)
+{ }
QLibraryPrivate *QLibraryPrivate::findOrCreate(const QString &fileName, const QString &version)
{
- QMutexLocker locker(&qt_library_mutex);
- if (QLibraryPrivate *lib = libraryMap()->value(fileName)) {
- lib->libraryRefCount.ref();
- return lib;
- }
-
- return new QLibraryPrivate(fileName, version);
+ return QLibraryStore::findOrCreate(fileName, version);
}
QLibraryPrivate::~QLibraryPrivate()
{
- LibraryMap * const map = libraryMap();
- if (map) {
- QLibraryPrivate *that = map->take(fileName);
- Q_ASSERT(this == that);
- Q_UNUSED(that);
- }
}
QFunctionPointer QLibraryPrivate::resolve(const char *symbol)
@@ -391,9 +477,10 @@ QFunctionPointer QLibraryPrivate::resolve(const char *symbol)
bool QLibraryPrivate::load()
{
- libraryUnloadCount.ref();
- if (pHnd)
+ if (pHnd) {
+ libraryUnloadCount.ref();
return true;
+ }
if (fileName.isEmpty())
return false;
@@ -403,32 +490,27 @@ bool QLibraryPrivate::load()
if (ret) {
//when loading a library we add a reference to it so that the QLibraryPrivate won't get deleted
//this allows to unload the library at a later time
- if (LibraryData *lib = libraryData()) {
- lib->loadedLibs += this;
- libraryRefCount.ref();
- }
-
+ libraryUnloadCount.ref();
+ libraryRefCount.ref();
installCoverageTool(this);
}
return ret;
}
-bool QLibraryPrivate::unload()
+bool QLibraryPrivate::unload(UnloadFlag flag)
{
if (!pHnd)
return false;
- if (!libraryUnloadCount.deref()) { // only unload if ALL QLibrary instance wanted to
+ if (libraryUnloadCount.load() > 0 && !libraryUnloadCount.deref()) { // only unload if ALL QLibrary instance wanted to
delete inst.data();
- if (unload_sys()) {
+ if (flag == NoUnloadSys || unload_sys()) {
if (qt_debug_component())
- qWarning() << "QLibraryPrivate::unload succeeded on" << fileName;
+ qWarning() << "QLibraryPrivate::unload succeeded on" << fileName
+ << (flag == NoUnloadSys ? "(faked)" : "");
//when the library is unloaded, we release the reference on it so that 'this'
//can get deleted
- if (LibraryData *lib = libraryData()) {
- if (lib->loadedLibs.remove(this))
- libraryRefCount.deref();
- }
+ libraryRefCount.deref();
pHnd = 0;
instance = 0;
}
@@ -439,9 +521,7 @@ bool QLibraryPrivate::unload()
void QLibraryPrivate::release()
{
- QMutexLocker locker(&qt_library_mutex);
- if (!libraryRefCount.deref())
- delete this;
+ QLibraryStore::releaseLibrary(this);
}
bool QLibraryPrivate::loadPlugin()
@@ -631,7 +711,7 @@ void QLibraryPrivate::updatePluginState()
hTempModule = ::LoadLibraryEx((wchar_t*)QDir::toNativeSeparators(fileName).utf16(), 0, dwFlags);
SetErrorMode(oldmode);
#else
- temporary_load = load_sys();
+ temporary_load = load();
#endif
}
QtPluginQueryVerificationDataFunction getMetaData = NULL;
@@ -656,11 +736,10 @@ void QLibraryPrivate::updatePluginState()
if (getMetaData)
ret = qt_get_metadata(getMetaData, this, &exceptionThrown);
+ if (temporary_load)
+ unload();
if (!exceptionThrown) {
- if (!ret) {
- if (temporary_load)
- unload_sys();
- } else {
+ if (ret) {
success = true;
}
retryLoadLibrary = false;
diff --git a/src/corelib/plugin/qlibrary.h b/src/corelib/plugin/qlibrary.h
index f99c69c2d7..865bb8c3e3 100644
--- a/src/corelib/plugin/qlibrary.h
+++ b/src/corelib/plugin/qlibrary.h
@@ -44,16 +44,8 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
-
-#if defined(QT_NO_LIBRARY) && defined(Q_OS_WIN)
-#undef QT_NO_LIBRARY
-#pragma message("QT_NO_LIBRARY is not supported on Windows")
-#endif
-
#ifndef QT_NO_LIBRARY
class QLibraryPrivate;
@@ -111,6 +103,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QLibrary::LoadHints)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QLIBRARY_H
diff --git a/src/corelib/plugin/qlibrary_p.h b/src/corelib/plugin/qlibrary_p.h
index 28bec300eb..abf11be9f7 100644
--- a/src/corelib/plugin/qlibrary_p.h
+++ b/src/corelib/plugin/qlibrary_p.h
@@ -71,6 +71,7 @@ QT_BEGIN_NAMESPACE
bool qt_debug_component();
+class QLibraryStore;
class QLibraryPrivate
{
public:
@@ -82,12 +83,14 @@ public:
#endif
pHnd;
+ enum UnloadFlag { UnloadSys, NoUnloadSys };
+
QString fileName, qualifiedFileName;
QString fullVersion;
bool load();
bool loadPlugin(); // loads and resolves instance
- bool unload();
+ bool unload(UnloadFlag flag = UnloadSys);
void release();
QFunctionPointer resolve(const char *);
@@ -124,11 +127,13 @@ private:
bool unload_sys();
QFunctionPointer resolve_sys(const char *);
+ /// counts how many QLibrary or QPluginLoader are attached to us, plus 1 if it's loaded
QAtomicInt libraryRefCount;
+ /// counts how many times load() or loadPlugin() were called
QAtomicInt libraryUnloadCount;
enum { IsAPlugin, IsNotAPlugin, MightBeAPlugin } pluginState;
- friend class QLibraryPrivateHasFriends;
+ friend class QLibraryStore;
};
QT_END_NAMESPACE
diff --git a/src/corelib/plugin/qlibrary_unix.cpp b/src/corelib/plugin/qlibrary_unix.cpp
index 5044d09e9b..2aed877e6b 100644
--- a/src/corelib/plugin/qlibrary_unix.cpp
+++ b/src/corelib/plugin/qlibrary_unix.cpp
@@ -56,7 +56,7 @@
#include <string.h>
#endif
-#if defined(Q_OS_VXWORKS) || defined (Q_OS_NACL)
+#if (defined(Q_OS_VXWORKS) && !defined(VXWORKS_RTP)) || defined (Q_OS_NACL)
#define QT_NO_DYNAMIC_LIBRARY
#endif
diff --git a/src/corelib/plugin/qlibrary_win.cpp b/src/corelib/plugin/qlibrary_win.cpp
index f066ff2df4..16445f1163 100644
--- a/src/corelib/plugin/qlibrary_win.cpp
+++ b/src/corelib/plugin/qlibrary_win.cpp
@@ -46,10 +46,7 @@
#include "qfileinfo.h"
#include <private/qfilesystementry_p.h>
-#if defined(QT_NO_LIBRARY) && defined(Q_OS_WIN)
-#undef QT_NO_LIBRARY
-#pragma message("QT_NO_LIBRARY is not supported on Windows")
-#endif
+#ifndef QT_NO_LIBRARY
#include <qt_windows.h>
@@ -166,3 +163,5 @@ QFunctionPointer QLibraryPrivate::resolve_sys(const char* symbol)
return QFunctionPointer(address);
}
QT_END_NAMESPACE
+
+#endif // QT_NO_LIBRARY
diff --git a/src/corelib/plugin/qplugin.h b/src/corelib/plugin/qplugin.h
index b6a533b793..b91a0e9900 100644
--- a/src/corelib/plugin/qplugin.h
+++ b/src/corelib/plugin/qplugin.h
@@ -45,8 +45,6 @@
#include <QtCore/qobject.h>
#include <QtCore/qpointer.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -139,6 +137,4 @@ void Q_CORE_EXPORT qRegisterStaticPluginFunction(QStaticPlugin staticPlugin);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // Q_PLUGIN_H
diff --git a/src/corelib/plugin/qplugin.qdoc b/src/corelib/plugin/qplugin.qdoc
index 74c4289017..eacfe995ae 100644
--- a/src/corelib/plugin/qplugin.qdoc
+++ b/src/corelib/plugin/qplugin.qdoc
@@ -43,7 +43,7 @@
to the interface class called \a ClassName. The \a Identifier must
be unique. For example:
- \snippet tools/plugandpaint/interfaces.h 3
+ \snippet plugins/interfaces.h 3
This macro is normally used right after the class definition for
\a ClassName, in a header file. See the
diff --git a/src/corelib/plugin/qpluginloader.h b/src/corelib/plugin/qpluginloader.h
index 7eb48d530c..8f8833e839 100644
--- a/src/corelib/plugin/qpluginloader.h
+++ b/src/corelib/plugin/qpluginloader.h
@@ -44,15 +44,8 @@
#include <QtCore/qlibrary.h>
-#if defined(QT_NO_LIBRARY) && defined(Q_OS_WIN)
-#undef QT_NO_LIBRARY
-#pragma message("QT_NO_LIBRARY is not supported on Windows")
-#endif
-
#ifndef QT_NO_LIBRARY
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QLibraryPrivate;
@@ -93,8 +86,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_LIBRARY
#endif //QPLUGINLOADER_H
diff --git a/src/corelib/plugin/quuid.cpp b/src/corelib/plugin/quuid.cpp
index 4ccf449ae2..4de83c62ee 100644
--- a/src/corelib/plugin/quuid.cpp
+++ b/src/corelib/plugin/quuid.cpp
@@ -279,7 +279,7 @@ static QUuid createFromName(const QUuid &ns, const QByteArray &baseData, QCrypto
The field layouts for the DCE versions listed in the table above
are specified in the \l{http://www.ietf.org/rfc/rfc4122.txt}
{Network Working Group UUID Specification}.
-
+
Most platforms provide a tool for generating new UUIDs, e.g. \c
uuidgen and \c guidgen. You can also use createUuid(). UUIDs
generated by createUuid() are of the random type. Their
@@ -534,23 +534,23 @@ QUuid QUuid::fromRfc4122(const QByteArray &bytes)
\header
\li Field #
\li Source
-
+
\row
\li 1
\li data1
-
+
\row
\li 2
\li data2
-
+
\row
\li 3
\li data3
-
+
\row
\li 4
\li data4[0] .. data4[1]
-
+
\row
\li 5
\li data4[2] .. data4[7]
diff --git a/src/corelib/plugin/quuid.h b/src/corelib/plugin/quuid.h
index bfd6759344..31b9890351 100644
--- a/src/corelib/plugin/quuid.h
+++ b/src/corelib/plugin/quuid.h
@@ -44,8 +44,6 @@
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
#if defined(Q_OS_WIN)
#ifndef GUID_DEFINED
#define GUID_DEFINED
@@ -84,11 +82,11 @@ public:
Sha1 = 5 // 0 1 0 1
};
-#ifdef Q_COMPILER_INITIALIZER_LISTS // UNIFORM_INITIALIZATION
- Q_DECL_CONSTEXPR QUuid()
- : data1(0), data2(0), data3(0), data4{0,0,0,0,0,0,0,0} {}
+#if defined(Q_COMPILER_INITIALIZER_LISTS) && !defined(Q_QDOC)
+ Q_DECL_CONSTEXPR QUuid() : data1(0), data2(0), data3(0), data4{0,0,0,0,0,0,0,0} {}
- Q_DECL_CONSTEXPR QUuid(uint l, ushort w1, ushort w2, uchar b1, uchar b2, uchar b3, uchar b4, uchar b5, uchar b6, uchar b7, uchar b8)
+ Q_DECL_CONSTEXPR QUuid(uint l, ushort w1, ushort w2, uchar b1, uchar b2, uchar b3,
+ uchar b4, uchar b5, uchar b6, uchar b7, uchar b8)
: data1(l), data2(w1), data3(w2), data4{b1, b2, b3, b4, b5, b6, b7, b8} {}
#else
QUuid()
@@ -149,7 +147,7 @@ public:
#if defined(Q_OS_WIN)
// On Windows we have a type GUID that is used by the platform API, so we
// provide convenience operators to cast from and to this type.
-#ifdef Q_COMPILER_INITIALIZER_LISTS // UNIFORM_INITIALIZATION
+#if defined(Q_COMPILER_INITIALIZER_LISTS) && !defined(Q_QDOC)
Q_DECL_CONSTEXPR QUuid(const GUID &guid)
: data1(guid.Data1), data2(guid.Data2), data3(guid.Data3),
data4{guid.Data4[0], guid.Data4[1], guid.Data4[2], guid.Data4[3],
@@ -227,6 +225,4 @@ Q_CORE_EXPORT uint qHash(const QUuid &uuid, uint seed = 0) Q_DECL_NOTHROW;
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QUUID_H
diff --git a/src/corelib/statemachine/qabstractstate.h b/src/corelib/statemachine/qabstractstate.h
index da13985316..a6ac248b85 100644
--- a/src/corelib/statemachine/qabstractstate.h
+++ b/src/corelib/statemachine/qabstractstate.h
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -96,6 +94,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/statemachine/qabstracttransition.h b/src/corelib/statemachine/qabstracttransition.h
index e8b2d0074f..a35ad4ca96 100644
--- a/src/corelib/statemachine/qabstracttransition.h
+++ b/src/corelib/statemachine/qabstracttransition.h
@@ -46,8 +46,6 @@
#include <QtCore/qlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -113,6 +111,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/statemachine/qeventtransition.h b/src/corelib/statemachine/qeventtransition.h
index 520c63e93b..f53a5e4732 100644
--- a/src/corelib/statemachine/qeventtransition.h
+++ b/src/corelib/statemachine/qeventtransition.h
@@ -45,8 +45,6 @@
#include <QtCore/qabstracttransition.h>
#include <QtCore/qcoreevent.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -89,6 +87,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/statemachine/qfinalstate.h b/src/corelib/statemachine/qfinalstate.h
index b0d8eb3a02..0343b99c1c 100644
--- a/src/corelib/statemachine/qfinalstate.h
+++ b/src/corelib/statemachine/qfinalstate.h
@@ -44,8 +44,6 @@
#include <QtCore/qabstractstate.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -74,6 +72,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/statemachine/qhistorystate.h b/src/corelib/statemachine/qhistorystate.h
index e35385b1a1..62278ac47a 100644
--- a/src/corelib/statemachine/qhistorystate.h
+++ b/src/corelib/statemachine/qhistorystate.h
@@ -44,8 +44,6 @@
#include <QtCore/qabstractstate.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -89,6 +87,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/statemachine/qsignaltransition.h b/src/corelib/statemachine/qsignaltransition.h
index 3038132da3..12f021d78e 100644
--- a/src/corelib/statemachine/qsignaltransition.h
+++ b/src/corelib/statemachine/qsignaltransition.h
@@ -44,8 +44,6 @@
#include <QtCore/qabstracttransition.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -84,6 +82,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/statemachine/qstate.h b/src/corelib/statemachine/qstate.h
index 8080c9062d..a5f2509ffb 100644
--- a/src/corelib/statemachine/qstate.h
+++ b/src/corelib/statemachine/qstate.h
@@ -46,8 +46,6 @@
#include <QtCore/qlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -129,6 +127,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/statemachine/qstatemachine.h b/src/corelib/statemachine/qstatemachine.h
index b33b95d25d..9305676bb5 100644
--- a/src/corelib/statemachine/qstatemachine.h
+++ b/src/corelib/statemachine/qstatemachine.h
@@ -50,8 +50,6 @@
#include <QtCore/qset.h>
#include <QtCore/qvariant.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -195,6 +193,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/statemachine/qstatemachine_p.h b/src/corelib/statemachine/qstatemachine_p.h
index dae3cb1988..a661d105cf 100644
--- a/src/corelib/statemachine/qstatemachine_p.h
+++ b/src/corelib/statemachine/qstatemachine_p.h
@@ -185,7 +185,7 @@ public:
void unregisterTransition(QAbstractTransition *transition);
void unregisterAllTransitions();
void handleTransitionSignal(QObject *sender, int signalIndex,
- void **args);
+ void **args);
void postInternalEvent(QEvent *e);
void postExternalEvent(QEvent *e);
@@ -195,7 +195,7 @@ public:
bool isExternalEventQueueEmpty();
void processEvents(EventProcessingMode processingMode);
void cancelAllDelayedEvents();
-
+
#ifndef QT_NO_PROPERTIES
typedef QPair<QPointer<QObject>, QByteArray> RestorableId;
QHash<QAbstractState*, QHash<RestorableId, QVariant> > registeredRestorablesForState;
@@ -235,7 +235,7 @@ public:
bool animated;
QPair<QList<QAbstractAnimation*>, QList<QAbstractAnimation*> >
- initializeAnimation(QAbstractAnimation *abstractAnimation,
+ initializeAnimation(QAbstractAnimation *abstractAnimation,
const QPropertyAssignment &prop);
QHash<QAbstractState*, QList<QAbstractAnimation*> > animationsForState;
@@ -274,7 +274,7 @@ public:
QHash<int, DelayedEvent> delayedEvents;
QHash<int, int> timerIdToDelayedEventId;
QMutex delayedEventsMutex;
-
+
typedef QEvent* (*f_cloneEvent)(QEvent*);
struct Handler {
f_cloneEvent cloneEvent;
diff --git a/src/corelib/thread/qatomic.cpp b/src/corelib/thread/qatomic.cpp
index 1c83f23df0..11623f80dc 100644
--- a/src/corelib/thread/qatomic.cpp
+++ b/src/corelib/thread/qatomic.cpp
@@ -49,7 +49,7 @@
For atomic operations on pointers, see the QAtomicPointer class.
- An \e atomic operation is a complex operation that completes without interruption.
+ An \e atomic operation is a complex operation that completes without interruption.
The QAtomicInt class provides atomic reference counting, test-and-set, fetch-and-store,
and fetch-and-add for integers.
diff --git a/src/corelib/thread/qatomic.h b/src/corelib/thread/qatomic.h
index 06cee4894e..1ccaecc135 100644
--- a/src/corelib/thread/qatomic.h
+++ b/src/corelib/thread/qatomic.h
@@ -46,8 +46,6 @@
#include <QtCore/qbasicatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -220,6 +218,4 @@ inline void qAtomicDetach(T *&d)
}
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QATOMIC_H
diff --git a/src/corelib/thread/qbasicatomic.h b/src/corelib/thread/qbasicatomic.h
index 70b69827c2..b5a402857c 100644
--- a/src/corelib/thread/qbasicatomic.h
+++ b/src/corelib/thread/qbasicatomic.h
@@ -44,7 +44,7 @@
#ifndef QBASICATOMIC_H
#define QBASICATOMIC_H
-#if defined(QT_MOC) || defined(QT_BUILD_QMAKE) || defined(QT_RCC) || defined(QT_UIC) || defined(QT_BOOTSTRAPPED)
+#if defined(QT_BOOTSTRAPPED)
# include <QtCore/qatomic_bootstrap.h>
// Compiler dependent implementation
@@ -101,15 +101,11 @@
// Only include if the implementation has been ported to QAtomicOps
#ifndef QOLDBASICATOMIC_H
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
#pragma qt_no_master_include
#pragma qt_sync_stop_processing
#endif
@@ -271,8 +267,6 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QOLDBASICATOMIC_H
#endif // QBASICATOMIC_H
diff --git a/src/corelib/thread/qexception.cpp b/src/corelib/thread/qexception.cpp
index 263f7d19fe..0c17399d33 100644
--- a/src/corelib/thread/qexception.cpp
+++ b/src/corelib/thread/qexception.cpp
@@ -47,7 +47,7 @@
QT_BEGIN_NAMESPACE
-/*!
+/*!
\class QException
\inmodule QtCore
\brief The QException class provides a base class for exceptions that can transferred across threads.
@@ -91,7 +91,7 @@ QT_BEGIN_NAMESPACE
\snippet code/src_corelib_thread_qexception.cpp 3
*/
-/*!
+/*!
\class QUnhandledException
\inmodule QtCore
diff --git a/src/corelib/thread/qexception.h b/src/corelib/thread/qexception.h
index fa944ce69d..accf0fc7b4 100644
--- a/src/corelib/thread/qexception.h
+++ b/src/corelib/thread/qexception.h
@@ -53,7 +53,6 @@
# include <exception>
#endif
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -116,7 +115,6 @@ public:
#endif // QT_NO_EXCEPTIONS
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_QFUTURE
diff --git a/src/corelib/thread/qfuture.h b/src/corelib/thread/qfuture.h
index d9c4f1af77..8071e80d1b 100644
--- a/src/corelib/thread/qfuture.h
+++ b/src/corelib/thread/qfuture.h
@@ -49,7 +49,6 @@
#include <QtCore/qfutureinterface.h>
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -269,7 +268,6 @@ QFuture<void> qToVoidFuture(const QFuture<T> &future)
}
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_QFUTURE
diff --git a/src/corelib/thread/qfuture.qdoc b/src/corelib/thread/qfuture.qdoc
index 4ab28e81b2..421e683c4a 100644
--- a/src/corelib/thread/qfuture.qdoc
+++ b/src/corelib/thread/qfuture.qdoc
@@ -58,7 +58,7 @@
use the isResultReadyAt() function to determine if a result is ready or
not. For QFuture objects that report more than one result, the
resultCount() function returns the number of continuous results. This
- means that it is always safe to iterate through the results from 0 to
+ means that it is always safe to iterate through the results from 0 to
resultCount().
QFuture provides a \l{Java-style iterators}{Java-style iterator}
diff --git a/src/corelib/thread/qfutureinterface.cpp b/src/corelib/thread/qfutureinterface.cpp
index f5590d95f8..0f7d04a7c5 100644
--- a/src/corelib/thread/qfutureinterface.cpp
+++ b/src/corelib/thread/qfutureinterface.cpp
@@ -288,7 +288,7 @@ void QFutureInterfaceBase::waitForResult(int resultIndex)
return;
lock.unlock();
- // To avoid deadlocks and reduce the number of threads used, try to
+ // To avoid deadlocks and reduce the number of threads used, try to
// run the runnable in the current thread.
QThreadPool::globalInstance()->d_func()->stealRunnable(d->runnable);
diff --git a/src/corelib/thread/qfutureinterface.h b/src/corelib/thread/qfutureinterface.h
index 6ab1409f55..e0a59697a1 100644
--- a/src/corelib/thread/qfutureinterface.h
+++ b/src/corelib/thread/qfutureinterface.h
@@ -50,7 +50,6 @@
#include <QtCore/qexception.h>
#include <QtCore/qresultstore.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -235,7 +234,7 @@ inline void QFutureInterface<T>::reportResults(const QVector<T> &_results, int b
this->reportResultsReady(resultCountBefore, store.count());
} else {
const int insertIndex = store.addResults(beginIndex, &_results, count);
- this->reportResultsReady(insertIndex, insertIndex + _results.count());
+ this->reportResultsReady(insertIndex, insertIndex + _results.count());
}
}
@@ -310,8 +309,6 @@ public:
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_QFUTURE
#endif // QFUTUREINTERFACE_H
diff --git a/src/corelib/thread/qfuturesynchronizer.h b/src/corelib/thread/qfuturesynchronizer.h
index 60960f7711..39dbfc52a8 100644
--- a/src/corelib/thread/qfuturesynchronizer.h
+++ b/src/corelib/thread/qfuturesynchronizer.h
@@ -46,7 +46,6 @@
#ifndef QT_NO_QFUTURE
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -81,7 +80,7 @@ public:
m_futures[i].cancel();
}
}
-
+
for (int i = 0; i < m_futures.count(); ++i) {
m_futures[i].waitForFinished();
}
@@ -113,8 +112,6 @@ protected:
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_QFUTURE
#endif // QFUTURESYNCHRONIZER_H
diff --git a/src/corelib/thread/qfuturewatcher.h b/src/corelib/thread/qfuturewatcher.h
index d41b6139b6..c78ed7a83b 100644
--- a/src/corelib/thread/qfuturewatcher.h
+++ b/src/corelib/thread/qfuturewatcher.h
@@ -48,7 +48,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -215,8 +214,6 @@ Q_INLINE_TEMPLATE void QFutureWatcher<void>::setFuture(const QFuture<void> &_fut
}
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_QFUTURE
#endif // QFUTUREWATCHER_H
diff --git a/src/corelib/thread/qgenericatomic.h b/src/corelib/thread/qgenericatomic.h
index 90f0223ccf..a0a851eabb 100644
--- a/src/corelib/thread/qgenericatomic.h
+++ b/src/corelib/thread/qgenericatomic.h
@@ -44,14 +44,12 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
@@ -241,6 +239,4 @@ template <typename BaseClass> struct QGenericAtomicOps
#undef always_inline
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGENERICATOMIC_H
diff --git a/src/corelib/thread/qmutex.h b/src/corelib/thread/qmutex.h
index 94bcdd1750..0bca0def22 100644
--- a/src/corelib/thread/qmutex.h
+++ b/src/corelib/thread/qmutex.h
@@ -46,8 +46,6 @@
#include <QtCore/qatomic.h>
#include <new>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -211,6 +209,4 @@ typedef QMutex QBasicMutex;
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMUTEX_H
diff --git a/src/corelib/thread/qmutex_p.h b/src/corelib/thread/qmutex_p.h
index 1b8bcd6b3a..bec2d934c1 100644
--- a/src/corelib/thread/qmutex_p.h
+++ b/src/corelib/thread/qmutex_p.h
@@ -70,6 +70,8 @@
# define QT_LINUX_FUTEX
#endif
+struct timespec;
+
QT_BEGIN_NAMESPACE
class QMutexData
@@ -137,6 +139,13 @@ public:
#endif //QT_LINUX_FUTEX
+#ifdef Q_OS_UNIX
+// helper functions for qmutex_unix.cpp and qwaitcondition_unix.cpp
+// they are in qwaitcondition_unix.cpp actually
+void qt_initialize_pthread_cond(pthread_cond_t *cond, const char *where);
+void qt_abstime_for_timeout(struct timespec *ts, int timeout);
+#endif
+
QT_END_NAMESPACE
#endif // QMUTEX_P_H
diff --git a/src/corelib/thread/qmutex_unix.cpp b/src/corelib/thread/qmutex_unix.cpp
index ef030cb49a..2f8c2e1dc8 100644
--- a/src/corelib/thread/qmutex_unix.cpp
+++ b/src/corelib/thread/qmutex_unix.cpp
@@ -42,11 +42,14 @@
#include "qplatformdefs.h"
#include "qmutex.h"
#include "qstring.h"
+#include "qelapsedtimer.h"
#ifndef QT_NO_THREAD
#include "qatomic.h"
#include "qmutex_p.h"
#include <errno.h>
+#include <sys/time.h>
+#include <time.h>
#if defined(Q_OS_VXWORKS) && defined(wakeup)
#undef wakeup
@@ -64,7 +67,7 @@ QMutexPrivate::QMutexPrivate()
: wakeup(false)
{
report_error(pthread_mutex_init(&mutex, NULL), "QMutex", "mutex init");
- report_error(pthread_cond_init(&cond, NULL), "QMutex", "cv init");
+ qt_initialize_pthread_cond(&cond, "QMutex");
}
QMutexPrivate::~QMutexPrivate()
@@ -81,12 +84,8 @@ bool QMutexPrivate::wait(int timeout)
if (timeout < 0) {
errorCode = pthread_cond_wait(&cond, &mutex);
} else {
- struct timeval tv;
- gettimeofday(&tv, 0);
timespec ti;
- ti.tv_nsec = (tv.tv_usec + (timeout % 1000) * 1000) * 1000;
- ti.tv_sec = tv.tv_sec + (timeout / 1000) + (ti.tv_nsec / 1000000000);
- ti.tv_nsec %= 1000000000;
+ qt_abstime_for_timeout(&ti, timeout);
errorCode = pthread_cond_timedwait(&cond, &mutex, &ti);
}
if (errorCode) {
diff --git a/src/corelib/thread/qoldbasicatomic.h b/src/corelib/thread/qoldbasicatomic.h
index 15785e2232..b755256ff7 100644
--- a/src/corelib/thread/qoldbasicatomic.h
+++ b/src/corelib/thread/qoldbasicatomic.h
@@ -44,16 +44,13 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#if 0
// silence syncqt warnings
QT_END_NAMESPACE
-QT_END_HEADER
-
+#pragma qt_sync_skip_header_check
#pragma qt_no_master_include
#pragma qt_sync_stop_processing
#endif
@@ -142,6 +139,5 @@ public:
#define Q_BASIC_ATOMIC_INITIALIZER(a) { (a) }
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QOLDBASICATOMIC_H
diff --git a/src/corelib/thread/qreadwritelock.cpp b/src/corelib/thread/qreadwritelock.cpp
index b6bb22b314..0de826fddf 100644
--- a/src/corelib/thread/qreadwritelock.cpp
+++ b/src/corelib/thread/qreadwritelock.cpp
@@ -93,7 +93,7 @@ QT_BEGIN_NAMESPACE
\sa QReadLocker, QWriteLocker, QMutex, QSemaphore
*/
-/*!
+/*!
\enum QReadWriteLock::RecursionMode
\since 4.4
diff --git a/src/corelib/thread/qreadwritelock.h b/src/corelib/thread/qreadwritelock.h
index 8217d4eacd..6815878ec5 100644
--- a/src/corelib/thread/qreadwritelock.h
+++ b/src/corelib/thread/qreadwritelock.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -231,6 +229,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QREADWRITELOCK_H
diff --git a/src/corelib/thread/qresultstore.cpp b/src/corelib/thread/qresultstore.cpp
index 940fd45027..65c2437064 100644
--- a/src/corelib/thread/qresultstore.cpp
+++ b/src/corelib/thread/qresultstore.cpp
@@ -97,7 +97,7 @@ bool ResultIteratorBase::canIncrementVectorIndex() const
return (m_vectorIndex + 1 < mapIterator.value().m_count);
}
-ResultStoreBase::ResultStoreBase()
+ResultStoreBase::ResultStoreBase()
: insertIndex(0), resultCount(0), m_filterMode(false), filteredResults(0) { }
void ResultStoreBase::setFilterMode(bool enable)
@@ -148,7 +148,7 @@ void ResultStoreBase::syncPendingResults()
// check if we can insert any of the pending results:
QMap<int, ResultItem>::iterator it = pendingResults.begin();
while (it != pendingResults.end()) {
- int index = it.key();
+ int index = it.key();
if (index != resultCount + filteredResults)
break;
@@ -165,7 +165,7 @@ int ResultStoreBase::addResult(int index, const void *result)
return insertResultItem(index, resultItem);
}
-int ResultStoreBase::addResults(int index, const void *results, int vectorSize, int totalCount)
+int ResultStoreBase::addResults(int index, const void *results, int vectorSize, int totalCount)
{
if (m_filterMode == false || vectorSize == totalCount) {
ResultItem resultItem(results, vectorSize);
@@ -218,7 +218,7 @@ ResultIteratorBase ResultStoreBase::resultAt(int index) const
}
const int vectorIndex = index - it.key();
-
+
if (vectorIndex >= it.value().count())
return ResultIteratorBase(m_results.end());
else if (it.value().isVector() == false && vectorIndex != 0)
diff --git a/src/corelib/thread/qresultstore.h b/src/corelib/thread/qresultstore.h
index 8c1787bc11..11ce23936d 100644
--- a/src/corelib/thread/qresultstore.h
+++ b/src/corelib/thread/qresultstore.h
@@ -49,7 +49,6 @@
#include <QtCore/qmap.h>
#include <QtCore/qdebug.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -149,7 +148,7 @@ protected:
bool m_filterMode;
QMap<int, ResultItem> pendingResults;
int filteredResults;
-
+
};
template <typename T>
@@ -234,7 +233,6 @@ public:
#endif //Q_QDOC
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_QFUTURE
diff --git a/src/corelib/thread/qrunnable.cpp b/src/corelib/thread/qrunnable.cpp
index eed716af37..e271582b9b 100644
--- a/src/corelib/thread/qrunnable.cpp
+++ b/src/corelib/thread/qrunnable.cpp
@@ -57,7 +57,7 @@
change the auto-deletion flag.
QThreadPool supports executing the same QRunnable more than once
- by calling QThreadPool::tryStart(this) from within the run() function.
+ by calling QThreadPool::tryStart(this) from within the run() function.
If autoDelete is enabled the QRunnable will be deleted when
the last thread exits the run function. Calling QThreadPool::start()
multiple times with the same QRunnable when autoDelete is enabled
diff --git a/src/corelib/thread/qrunnable.h b/src/corelib/thread/qrunnable.h
index ba03519872..a6cc095258 100644
--- a/src/corelib/thread/qrunnable.h
+++ b/src/corelib/thread/qrunnable.h
@@ -44,7 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -67,6 +66,5 @@ public:
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif
diff --git a/src/corelib/thread/qsemaphore.h b/src/corelib/thread/qsemaphore.h
index b47588ce62..40200151b0 100644
--- a/src/corelib/thread/qsemaphore.h
+++ b/src/corelib/thread/qsemaphore.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -77,6 +75,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSEMAPHORE_H
diff --git a/src/corelib/thread/qthread.cpp b/src/corelib/thread/qthread.cpp
index bd8c6341c1..4d5bee3154 100644
--- a/src/corelib/thread/qthread.cpp
+++ b/src/corelib/thread/qthread.cpp
@@ -76,6 +76,7 @@ QThreadData::~QThreadData()
// the problem...
if (this->thread == QCoreApplicationPrivate::theMainThread) {
QCoreApplicationPrivate::theMainThread = 0;
+ QThreadData::clearCurrentThreadData();
}
QThread *t = thread;
@@ -523,9 +524,9 @@ int QThread::exec()
Note that unlike the C library function of the same name, this
function \e does return to the caller -- it is event processing
- that stops.
-
- No QEventLoops will be started anymore in this thread until
+ that stops.
+
+ No QEventLoops will be started anymore in this thread until
QThread::exec() has been called again. If the eventloop in QThread::exec()
is not running then the next call to QThread::exec() will also return
immediately.
@@ -592,6 +593,16 @@ void QThread::run()
\sa Priority, priority(), start()
*/
+void QThread::setPriority(Priority priority)
+{
+ Q_D(QThread);
+ QMutexLocker locker(&d->mutex);
+ if (!d->running) {
+ qWarning("QThread::setPriority: Cannot set priority, thread is not running");
+ return;
+ }
+ d->setPriority(priority);
+}
/*!
\since 4.1
@@ -751,7 +762,7 @@ QThread::QThread(QThreadPrivate &dd, QObject *parent)
QAbstractEventDispatcher *QThread::eventDispatcher() const
{
Q_D(const QThread);
- return d->data->eventDispatcher;
+ return d->data->eventDispatcher.load();
}
/*!
@@ -766,7 +777,7 @@ QAbstractEventDispatcher *QThread::eventDispatcher() const
void QThread::setEventDispatcher(QAbstractEventDispatcher *eventDispatcher)
{
Q_D(QThread);
- if (d->data->eventDispatcher != 0) {
+ if (d->data->hasEventDispatcher()) {
qWarning("QThread::setEventDispatcher: An event dispatcher has already been created for this thread");
} else {
eventDispatcher->moveToThread(this);
diff --git a/src/corelib/thread/qthread.h b/src/corelib/thread/qthread.h
index c6c6167da7..19c0f82d86 100644
--- a/src/corelib/thread/qthread.h
+++ b/src/corelib/thread/qthread.h
@@ -46,8 +46,6 @@
#include <limits.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -164,6 +162,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTHREAD_H
diff --git a/src/corelib/thread/qthread_p.h b/src/corelib/thread/qthread_p.h
index 526633cafa..9d773b3c1c 100644
--- a/src/corelib/thread/qthread_p.h
+++ b/src/corelib/thread/qthread_p.h
@@ -142,6 +142,8 @@ public:
QThreadPrivate(QThreadData *d = 0);
~QThreadPrivate();
+ void setPriority(QThread::Priority prio);
+
mutable QMutex mutex;
QAtomicInt quitLockRef;
@@ -223,18 +225,27 @@ public:
~QThreadData();
static QThreadData *current();
+ static void clearCurrentThreadData();
static QThreadData *get2(QThread *thread)
{ Q_ASSERT_X(thread != 0, "QThread", "internal error"); return thread->d_func()->data; }
void ref();
void deref();
+ inline bool hasEventDispatcher() const
+ { return eventDispatcher.load() != 0; }
+
+ bool canWaitLocked()
+ {
+ QMutexLocker locker(&postEventList.mutex);
+ return canWait;
+ }
QThread *thread;
Qt::HANDLE threadId;
bool quitNow;
int loopLevel;
- QAbstractEventDispatcher *eventDispatcher;
+ QAtomicPointer<QAbstractEventDispatcher> eventDispatcher;
QStack<QEventLoop *> eventLoops;
QPostEventList postEventList;
bool canWait;
diff --git a/src/corelib/thread/qthread_unix.cpp b/src/corelib/thread/qthread_unix.cpp
index 8abf1d06ef..f123e1813b 100644
--- a/src/corelib/thread/qthread_unix.cpp
+++ b/src/corelib/thread/qthread_unix.cpp
@@ -204,6 +204,11 @@ static void clear_thread_data()
pthread_setspecific(current_thread_data_key, 0);
}
+void QThreadData::clearCurrentThreadData()
+{
+ clear_thread_data();
+}
+
QThreadData *QThreadData::current()
{
QThreadData *data = get_thread_data();
@@ -253,19 +258,19 @@ typedef void*(*QtThreadCallback)(void*);
void QThreadPrivate::createEventDispatcher(QThreadData *data)
{
#if defined(Q_OS_BLACKBERRY)
- data->eventDispatcher = new QEventDispatcherBlackberry;
+ data->eventDispatcher.storeRelease(new QEventDispatcherBlackberry);
#else
#if !defined(QT_NO_GLIB)
if (qEnvironmentVariableIsEmpty("QT_NO_GLIB")
&& qEnvironmentVariableIsEmpty("QT_NO_THREADED_GLIB")
&& QEventDispatcherGlib::versionSupported())
- data->eventDispatcher = new QEventDispatcherGlib;
+ data->eventDispatcher.storeRelease(new QEventDispatcherGlib);
else
#endif
- data->eventDispatcher = new QEventDispatcherUNIX;
+ data->eventDispatcher.storeRelease(new QEventDispatcherUNIX);
#endif
- data->eventDispatcher->startingUp();
+ data->eventDispatcher.load()->startingUp();
}
#ifndef QT_NO_THREAD
@@ -287,7 +292,7 @@ static void setCurrentThreadName(pthread_t threadId, const char *name)
void *QThreadPrivate::start(void *arg)
{
-#if !defined(Q_OS_LINUX_ANDROID)
+#if !defined(Q_OS_ANDROID)
pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, NULL);
#endif
pthread_cleanup_push(QThreadPrivate::finish, arg);
@@ -295,22 +300,23 @@ void *QThreadPrivate::start(void *arg)
QThread *thr = reinterpret_cast<QThread *>(arg);
QThreadData *data = QThreadData::get2(thr);
- // do we need to reset the thread priority?
- if (int(thr->d_func()->priority) & ThreadPriorityResetFlag) {
- thr->setPriority(QThread::Priority(thr->d_func()->priority & ~ThreadPriorityResetFlag));
- }
-
- data->threadId = (Qt::HANDLE)pthread_self();
- set_thread_data(data);
-
- data->ref();
{
QMutexLocker locker(&thr->d_func()->mutex);
+
+ // do we need to reset the thread priority?
+ if (int(thr->d_func()->priority) & ThreadPriorityResetFlag) {
+ thr->d_func()->setPriority(QThread::Priority(thr->d_func()->priority & ~ThreadPriorityResetFlag));
+ }
+
+ data->threadId = (Qt::HANDLE)pthread_self();
+ set_thread_data(data);
+
+ data->ref();
data->quitNow = thr->d_func()->exited;
}
- if (data->eventDispatcher) // custom event dispatcher set?
- data->eventDispatcher->startingUp();
+ if (data->eventDispatcher.load()) // custom event dispatcher set?
+ data->eventDispatcher.load()->startingUp();
else
createEventDispatcher(data);
@@ -326,7 +332,7 @@ void *QThreadPrivate::start(void *arg)
#endif
emit thr->started(QThread::QPrivateSignal());
-#if !defined(Q_OS_LINUX_ANDROID)
+#if !defined(Q_OS_ANDROID)
pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, NULL);
pthread_testcancel();
#endif
@@ -353,7 +359,7 @@ void QThreadPrivate::finish(void *arg)
QThreadStorageData::finish((void **)data);
locker.relock();
- QAbstractEventDispatcher *eventDispatcher = d->data->eventDispatcher;
+ QAbstractEventDispatcher *eventDispatcher = d->data->eventDispatcher.load();
if (eventDispatcher) {
d->data->eventDispatcher = 0;
locker.unlock();
@@ -415,6 +421,13 @@ int QThread::idealThreadCount() Q_DECL_NOTHROW
// IRIX
cores = (int)sysconf(_SC_NPROC_ONLN);
#elif defined(Q_OS_INTEGRITY)
+#if (__INTEGRITY_MAJOR_VERSION >= 10)
+ // Integrity V10+ does support multicore CPUs
+ Value processorCount;
+ if (GetProcessorCount(CurrentTask(), &processorCount) == 0)
+ cores = processorCount;
+ else
+#endif
// as of aug 2008 Integrity only supports one single core CPU
cores = 1;
#elif defined(Q_OS_VXWORKS)
@@ -488,8 +501,20 @@ static bool calculateUnixPriority(int priority, int *sched_policy, int *sched_pr
#endif
const int highestPriority = QThread::TimeCriticalPriority;
- int prio_min = sched_get_priority_min(*sched_policy);
- int prio_max = sched_get_priority_max(*sched_policy);
+ int prio_min;
+ int prio_max;
+#if defined(Q_OS_VXWORKS) && defined(VXWORKS_DKM)
+ // for other scheduling policies than SCHED_RR or SCHED_FIFO
+ prio_min = SCHED_FIFO_LOW_PRI;
+ prio_max = SCHED_FIFO_HIGH_PRI;
+
+ if ((*sched_policy == SCHED_RR) || (*sched_policy == SCHED_FIFO))
+#endif
+ {
+ prio_min = sched_get_priority_min(*sched_policy);
+ prio_max = sched_get_priority_max(*sched_policy);
+ }
+
if (prio_min == -1 || prio_max == -1)
return false;
@@ -612,7 +637,7 @@ void QThread::start(Priority priority)
void QThread::terminate()
{
-#if !defined(Q_OS_LINUX_ANDROID)
+#if !defined(Q_OS_ANDROID)
Q_D(QThread);
QMutexLocker locker(&d->mutex);
@@ -654,7 +679,7 @@ void QThread::setTerminationEnabled(bool enabled)
"Current thread was not started with QThread.");
Q_UNUSED(thr)
-#if defined(Q_OS_LINUX_ANDROID)
+#if defined(Q_OS_ANDROID)
Q_UNUSED(enabled);
#else
pthread_setcancelstate(enabled ? PTHREAD_CANCEL_ENABLE : PTHREAD_CANCEL_DISABLE, NULL);
@@ -663,16 +688,10 @@ void QThread::setTerminationEnabled(bool enabled)
#endif
}
-void QThread::setPriority(Priority priority)
+// Caller must lock the mutex
+void QThreadPrivate::setPriority(QThread::Priority threadPriority)
{
- Q_D(QThread);
- QMutexLocker locker(&d->mutex);
- if (!d->running) {
- qWarning("QThread::setPriority: Cannot set priority, thread is not running");
- return;
- }
-
- d->priority = priority;
+ priority = threadPriority;
// copied from start() with a few modifications:
@@ -680,7 +699,7 @@ void QThread::setPriority(Priority priority)
int sched_policy;
sched_param param;
- if (pthread_getschedparam(d->thread_id, &sched_policy, &param) != 0) {
+ if (pthread_getschedparam(thread_id, &sched_policy, &param) != 0) {
// failed to get the scheduling policy, don't bother setting
// the priority
qWarning("QThread::setPriority: Cannot get scheduler parameters");
@@ -696,15 +715,15 @@ void QThread::setPriority(Priority priority)
}
param.sched_priority = prio;
- int status = pthread_setschedparam(d->thread_id, sched_policy, &param);
+ int status = pthread_setschedparam(thread_id, sched_policy, &param);
# ifdef SCHED_IDLE
// were we trying to set to idle priority and failed?
if (status == -1 && sched_policy == SCHED_IDLE && errno == EINVAL) {
// reset to lowest priority possible
- pthread_getschedparam(d->thread_id, &sched_policy, &param);
+ pthread_getschedparam(thread_id, &sched_policy, &param);
param.sched_priority = sched_get_priority_min(sched_policy);
- pthread_setschedparam(d->thread_id, sched_policy, &param);
+ pthread_setschedparam(thread_id, sched_policy, &param);
}
# else
Q_UNUSED(status);
diff --git a/src/corelib/thread/qthread_win.cpp b/src/corelib/thread/qthread_win.cpp
index 8614330d6f..a0fac8eff2 100644
--- a/src/corelib/thread/qthread_win.cpp
+++ b/src/corelib/thread/qthread_win.cpp
@@ -96,6 +96,11 @@ Q_DESTRUCTOR_FUNCTION(qt_free_tls)
/*
QThreadData
*/
+void QThreadData::clearCurrentThreadData()
+{
+ TlsSetValue(qt_current_thread_data_tls_index, 0);
+}
+
QThreadData *QThreadData::current()
{
qt_create_tls();
@@ -301,8 +306,9 @@ void qt_set_thread_name(HANDLE threadId, LPCSTR threadName)
void QThreadPrivate::createEventDispatcher(QThreadData *data)
{
- data->eventDispatcher = new QEventDispatcherWin32;
- data->eventDispatcher->startingUp();
+ QEventDispatcherWin32 *theEventDispatcher = new QEventDispatcherWin32;
+ data->eventDispatcher.storeRelease(theEventDispatcher);
+ theEventDispatcher->startingUp();
}
#ifndef QT_NO_THREAD
@@ -323,8 +329,8 @@ unsigned int __stdcall QT_ENSURE_STACK_ALIGNED_FOR_SSE QThreadPrivate::start(voi
data->quitNow = thr->d_func()->exited;
}
- if (data->eventDispatcher) // custom event dispatcher set?
- data->eventDispatcher->startingUp();
+ if (data->eventDispatcher.load()) // custom event dispatcher set?
+ data->eventDispatcher.load()->startingUp();
else
createEventDispatcher(data);
@@ -359,7 +365,7 @@ void QThreadPrivate::finish(void *arg, bool lockAnyway)
QThreadStorageData::finish(tls_data);
locker.relock();
- QAbstractEventDispatcher *eventDispatcher = d->data->eventDispatcher;
+ QAbstractEventDispatcher *eventDispatcher = d->data->eventDispatcher.load();
if (eventDispatcher) {
d->data->eventDispatcher = 0;
locker.unlock();
@@ -582,55 +588,49 @@ void QThread::setTerminationEnabled(bool enabled)
}
}
-void QThread::setPriority(Priority priority)
+// Caller must hold the mutex
+void QThreadPrivate::setPriority(QThread::Priority threadPriority)
{
- Q_D(QThread);
- QMutexLocker locker(&d->mutex);
- if (!d->running) {
- qWarning("QThread::setPriority: Cannot set priority, thread is not running");
- return;
- }
-
// copied from start() with a few modifications:
int prio;
- d->priority = priority;
- switch (d->priority) {
- case IdlePriority:
+ priority = threadPriority;
+ switch (priority) {
+ case QThread::IdlePriority:
prio = THREAD_PRIORITY_IDLE;
break;
- case LowestPriority:
+ case QThread::LowestPriority:
prio = THREAD_PRIORITY_LOWEST;
break;
- case LowPriority:
+ case QThread::LowPriority:
prio = THREAD_PRIORITY_BELOW_NORMAL;
break;
- case NormalPriority:
+ case QThread::NormalPriority:
prio = THREAD_PRIORITY_NORMAL;
break;
- case HighPriority:
+ case QThread::HighPriority:
prio = THREAD_PRIORITY_ABOVE_NORMAL;
break;
- case HighestPriority:
+ case QThread::HighestPriority:
prio = THREAD_PRIORITY_HIGHEST;
break;
- case TimeCriticalPriority:
+ case QThread::TimeCriticalPriority:
prio = THREAD_PRIORITY_TIME_CRITICAL;
break;
- case InheritPriority:
+ case QThread::InheritPriority:
default:
qWarning("QThread::setPriority: Argument cannot be InheritPriority");
return;
}
- if (!SetThreadPriority(d->handle, prio)) {
+ if (!SetThreadPriority(handle, prio)) {
qErrnoWarning("QThread::setPriority: Failed to set thread priority");
}
}
diff --git a/src/corelib/thread/qthreadpool.cpp b/src/corelib/thread/qthreadpool.cpp
index 2b099706ff..1616fb9fab 100644
--- a/src/corelib/thread/qthreadpool.cpp
+++ b/src/corelib/thread/qthreadpool.cpp
@@ -133,7 +133,7 @@ void QThreadPoolThread::run()
// wait for work, exiting after the expiry timeout is reached
expired = !manager->runnableReady.wait(locker.mutex(), manager->expiryTimeout);
++manager->activeThreads;
-
+
if (expired)
--manager->waitingThreads;
}
@@ -223,7 +223,7 @@ void QThreadPoolPrivate::enqueueTask(QRunnable *runnable, int priority)
int QThreadPoolPrivate::activeThreadCount() const
{
- // To improve scalability this function is called without holding
+ // To improve scalability this function is called without holding
// the mutex lock -- keep it thread-safe.
return (allThreads.count()
- expiredThreads.count()
@@ -301,7 +301,7 @@ bool QThreadPoolPrivate::waitForDone(int msecs)
QElapsedTimer timer;
timer.start();
int t;
- while (!(queue.isEmpty() && activeThreads == 0) &&
+ while (!(queue.isEmpty() && activeThreads == 0) &&
((t = msecs - timer.elapsed()) > 0))
noActiveThreads.wait(locker.mutex(), t);
}
@@ -367,11 +367,11 @@ void QThreadPoolPrivate::stealRunnable(QRunnable *runnable)
\snippet code/src_corelib_concurrent_qthreadpool.cpp 0
- QThreadPool deletes the QRunnable automatically by default. Use
+ QThreadPool deletes the QRunnable automatically by default. Use
QRunnable::setAutoDelete() to change the auto-deletion flag.
QThreadPool supports executing the same QRunnable more than once
- by calling tryStart(this) from within QRunnable::run().
+ by calling tryStart(this) from within QRunnable::run().
If autoDelete is enabled the QRunnable will be deleted when
the last thread exits the run function. Calling start()
multiple times with the same QRunnable when autoDelete is enabled
@@ -595,8 +595,8 @@ void QThreadPool::releaseThread()
}
/*!
- Waits up to \a msecs milliseconds for all threads to exit and removes all
- threads from the thread pool. Returns true if all threads were removed;
+ Waits up to \a msecs milliseconds for all threads to exit and removes all
+ threads from the thread pool. Returns true if all threads were removed;
otherwise it returns false. If \a msecs is -1 (the default), the timeout
is ignored (waits for the last thread to exit).
*/
diff --git a/src/corelib/thread/qthreadpool.h b/src/corelib/thread/qthreadpool.h
index bc572fc8e8..ffc16dedbe 100644
--- a/src/corelib/thread/qthreadpool.h
+++ b/src/corelib/thread/qthreadpool.h
@@ -49,7 +49,6 @@
#ifndef QT_NO_THREAD
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -87,7 +86,6 @@ public:
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_THREAD
diff --git a/src/corelib/thread/qthreadstorage.h b/src/corelib/thread/qthreadstorage.h
index c98d181c1f..86285de84f 100644
--- a/src/corelib/thread/qthreadstorage.h
+++ b/src/corelib/thread/qthreadstorage.h
@@ -46,8 +46,6 @@
#ifndef QT_NO_THREAD
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -156,8 +154,6 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_THREAD
#endif // QTHREADSTORAGE_H
diff --git a/src/corelib/thread/qwaitcondition.h b/src/corelib/thread/qwaitcondition.h
index e8f51dad54..1468951373 100644
--- a/src/corelib/thread/qwaitcondition.h
+++ b/src/corelib/thread/qwaitcondition.h
@@ -46,8 +46,6 @@
#include <limits.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -99,6 +97,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWAITCONDITION_H
diff --git a/src/corelib/thread/qwaitcondition_unix.cpp b/src/corelib/thread/qwaitcondition_unix.cpp
index ab4e7872fb..616a4bdfb8 100644
--- a/src/corelib/thread/qwaitcondition_unix.cpp
+++ b/src/corelib/thread/qwaitcondition_unix.cpp
@@ -45,22 +45,66 @@
#include "qreadwritelock.h"
#include "qatomic.h"
#include "qstring.h"
+#include "qelapsedtimer.h"
+#include "private/qcore_unix_p.h"
#include "qmutex_p.h"
#include "qreadwritelock_p.h"
#include <errno.h>
+#include <sys/time.h>
+#include <time.h>
#ifndef QT_NO_THREAD
QT_BEGIN_NAMESPACE
+#ifdef Q_OS_ANDROID
+// Android lacks pthread_condattr_setclock, but it does have a nice function
+// for relative waits. Use weakref so we can determine at runtime whether it is
+// present.
+static int local_cond_timedwait_relative(pthread_cond_t*, pthread_mutex_t *, const timespec *)
+__attribute__((weakref("__pthread_cond_timedwait_relative")));
+#endif
+
static void report_error(int code, const char *where, const char *what)
{
if (code != 0)
qWarning("%s: %s failure: %s", where, what, qPrintable(qt_error_string(code)));
}
+void qt_initialize_pthread_cond(pthread_cond_t *cond, const char *where)
+{
+ pthread_condattr_t condattr;
+
+ pthread_condattr_init(&condattr);
+#if !defined(Q_OS_MAC) && !defined(Q_OS_ANDROID) && (_POSIX_MONOTONIC_CLOCK-0 >= 0)
+ if (QElapsedTimer::clockType() == QElapsedTimer::MonotonicClock)
+ pthread_condattr_setclock(&condattr, CLOCK_MONOTONIC);
+#endif
+ report_error(pthread_cond_init(cond, &condattr), where, "cv init");
+ pthread_condattr_destroy(&condattr);
+}
+
+void qt_abstime_for_timeout(timespec *ts, int timeout)
+{
+#ifdef Q_OS_MAC
+ // on Mac, qt_gettime() (on qelapsedtimer_mac.cpp) returns ticks related to the Mach absolute time
+ // that doesn't work with pthread
+ // Mac also doesn't have clock_gettime
+ struct timeval tv;
+ gettimeofday(&tv, 0);
+ ts->tv_sec = tv.tv_sec;
+ ts->tv_nsec = tv.tv_usec * 1000;
+#else
+ *ts = qt_gettime();
+#endif
+
+ ts->tv_sec += timeout / 1000;
+ ts->tv_nsec += timeout % 1000 * Q_UINT64_C(1000) * 1000;
+ normalizedTimespec(*ts);
+}
+
class QWaitConditionPrivate {
public:
pthread_mutex_t mutex;
@@ -68,20 +112,26 @@ public:
int waiters;
int wakeups;
+ int wait_relative(unsigned long time)
+ {
+ timespec ti;
+#ifdef Q_OS_ANDROID
+ if (Q_LIKELY(local_cond_timedwait_relative)) {
+ ti.tv_sec = time / 1000;
+ ti.tv_nsec = time % 1000 * Q_UINT64_C(1000) * 1000;
+ return local_cond_timedwait_relative(&cond, &mutex, &ti);
+ }
+#endif
+ qt_abstime_for_timeout(&ti, time);
+ return pthread_cond_timedwait(&cond, &mutex, &ti);
+ }
+
bool wait(unsigned long time)
{
int code;
forever {
if (time != ULONG_MAX) {
- struct timeval tv;
- gettimeofday(&tv, 0);
-
- timespec ti;
- ti.tv_nsec = (tv.tv_usec + (time % 1000) * 1000) * 1000;
- ti.tv_sec = tv.tv_sec + (time / 1000) + (ti.tv_nsec / 1000000000);
- ti.tv_nsec %= 1000000000;
-
- code = pthread_cond_timedwait(&cond, &mutex, &ti);
+ code = wait_relative(time);
} else {
code = pthread_cond_wait(&cond, &mutex);
}
@@ -114,7 +164,7 @@ QWaitCondition::QWaitCondition()
{
d = new QWaitConditionPrivate;
report_error(pthread_mutex_init(&d->mutex, NULL), "QWaitCondition", "mutex init");
- report_error(pthread_cond_init(&d->cond, NULL), "QWaitCondition", "cv init");
+ qt_initialize_pthread_cond(&d->cond, "QWaitCondition");
d->waiters = d->wakeups = 0;
}
diff --git a/src/corelib/thread/thread.pri b/src/corelib/thread/thread.pri
index 7247f2984e..13f0502b62 100644
--- a/src/corelib/thread/thread.pri
+++ b/src/corelib/thread/thread.pri
@@ -56,7 +56,7 @@ integrity:SOURCES += thread/qmutex_unix.cpp \
thread/qwaitcondition_unix.cpp
unix: {
- macx-* {
+ mac {
SOURCES += thread/qmutex_mac.cpp
} else:linux-*:!linux-lsb-* {
SOURCES += thread/qmutex_linux.cpp
diff --git a/src/corelib/tools/qalgorithms.h b/src/corelib/tools/qalgorithms.h
index 936ebd1cbb..e3b76886f1 100644
--- a/src/corelib/tools/qalgorithms.h
+++ b/src/corelib/tools/qalgorithms.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -520,6 +518,4 @@ Q_OUTOFLINE_TEMPLATE RandomAccessIterator qBinaryFindHelper(RandomAccessIterator
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QALGORITHMS_H
diff --git a/src/corelib/tools/qalgorithms.qdoc b/src/corelib/tools/qalgorithms.qdoc
index b4558722cb..cc544af868 100644
--- a/src/corelib/tools/qalgorithms.qdoc
+++ b/src/corelib/tools/qalgorithms.qdoc
@@ -70,7 +70,7 @@
\snippet code/doc_src_qalgorithms.cpp 1
Different algorithms can have different requirements for the
- iterators they accept. For example, qFill() accepts two
+ iterators they accept. For example, qFill() accepts two
\l {forward iterators}. The iterator types required are specified
for each algorithm. If an iterator of the wrong type is passed (for
example, if QList::ConstIterator is passed as an \l {output
@@ -369,7 +369,7 @@ of \a value in the variable passed as a reference in argument \a n.
This is the same as qSort(\a{container}.begin(), \a{container}.end());
*/
-/*!
+/*!
\fn void qStableSort(RandomAccessIterator begin, RandomAccessIterator end)
\relates <QtAlgorithms>
@@ -393,7 +393,7 @@ of \a value in the variable passed as a reference in argument \a n.
\sa qSort(), {random access iterators}
*/
-/*!
+/*!
\fn void qStableSort(RandomAccessIterator begin, RandomAccessIterator end, LessThan lessThan)
\relates <QtAlgorithms>
@@ -406,7 +406,7 @@ of \a value in the variable passed as a reference in argument \a n.
in case-insensitive alphabetical order:
\snippet code/doc_src_qalgorithms.cpp 16
-
+
Note that earlier versions of Qt allowed using a lessThan function that took its
arguments by non-const reference. From 4.3 and on this is no longer possible,
the arguments has to be passed by const reference or value.
@@ -423,7 +423,7 @@ of \a value in the variable passed as a reference in argument \a n.
property is often useful when sorting user-visible data.
*/
-/*!
+/*!
\fn void qStableSort(Container &container)
\relates <QtAlgorithms>
@@ -470,7 +470,7 @@ of \a value in the variable passed as a reference in argument \a n.
specified by the \a lessThan object.
*/
-/*!
+/*!
\fn void qLowerBound(const Container &container, const T &value)
\relates <QtAlgorithms>
@@ -520,7 +520,7 @@ of \a value in the variable passed as a reference in argument \a n.
specified by the \a lessThan object.
*/
-/*!
+/*!
\fn void qUpperBound(const Container &container, const T &value)
\relates <QtAlgorithms>
@@ -568,7 +568,7 @@ of \a value in the variable passed as a reference in argument \a n.
specified by the \a lessThan object.
*/
-/*!
+/*!
\fn void qBinaryFind(const Container &container, const T &value)
\relates <QtAlgorithms>
@@ -578,7 +578,7 @@ of \a value in the variable passed as a reference in argument \a n.
*/
-/*!
+/*!
\fn void qDeleteAll(ForwardIterator begin, ForwardIterator end)
\relates <QtAlgorithms>
@@ -601,7 +601,7 @@ of \a value in the variable passed as a reference in argument \a n.
\sa {forward iterators}
*/
-/*!
+/*!
\fn void qDeleteAll(const Container &c)
\relates <QtAlgorithms>
diff --git a/src/corelib/tools/qarraydata.h b/src/corelib/tools/qarraydata.h
index aab01c5f41..27f2606954 100644
--- a/src/corelib/tools/qarraydata.h
+++ b/src/corelib/tools/qarraydata.h
@@ -45,8 +45,6 @@
#include <QtCore/qrefcount.h>
#include <string.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
struct Q_CORE_EXPORT QArrayData
@@ -361,6 +359,4 @@ namespace QtPrivate {
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // include guard
diff --git a/src/corelib/tools/qarraydataops.h b/src/corelib/tools/qarraydataops.h
index 6c95e9364d..3cd8c51c07 100644
--- a/src/corelib/tools/qarraydataops.h
+++ b/src/corelib/tools/qarraydataops.h
@@ -47,8 +47,6 @@
#include <new>
#include <string.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
namespace QtPrivate {
@@ -423,6 +421,4 @@ struct QArrayDataOps
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // include guard
diff --git a/src/corelib/tools/qarraydatapointer.h b/src/corelib/tools/qarraydatapointer.h
index 52d054b035..533f7a306f 100644
--- a/src/corelib/tools/qarraydatapointer.h
+++ b/src/corelib/tools/qarraydatapointer.h
@@ -44,8 +44,6 @@
#include <QtCore/qarraydataops.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
template <class T>
@@ -219,6 +217,4 @@ namespace std
}
}
-QT_END_HEADER
-
#endif // include guard
diff --git a/src/corelib/tools/qbitarray.cpp b/src/corelib/tools/qbitarray.cpp
index 66ae7d21c2..2b459b2b1b 100644
--- a/src/corelib/tools/qbitarray.cpp
+++ b/src/corelib/tools/qbitarray.cpp
@@ -173,7 +173,7 @@ int QBitArray::count(bool on) const
while (len >= 24) {
quint32 v = quint32(bits[0]) | (quint32(bits[1]) << 8) | (quint32(bits[2]) << 16);
quint32 c = ((v & 0xfff) * Q_UINT64_C(0x1001001001001) & Q_UINT64_C(0x84210842108421)) % 0x1f;
- c += (((v & 0xfff000) >> 12) * Q_UINT64_C(0x1001001001001) & Q_UINT64_C(0x84210842108421)) % 0x1f;
+ c += (((v & 0xfff000) >> 12) * Q_UINT64_C(0x1001001001001) & Q_UINT64_C(0x84210842108421)) % 0x1f;
len -= 24;
bits += 3;
numBits += int(c);
@@ -467,7 +467,7 @@ QBitArray &QBitArray::operator&=(const QBitArray &other)
resize(qMax(size(), other.size()));
uchar *a1 = reinterpret_cast<uchar*>(d.data()) + 1;
const uchar *a2 = reinterpret_cast<const uchar*>(other.d.constData()) + 1;
- int n = other.d.size() -1 ;
+ int n = other.d.size() -1 ;
int p = d.size() - 1 - n;
while (n-- > 0)
*a1++ &= *a2++;
@@ -496,7 +496,7 @@ QBitArray &QBitArray::operator|=(const QBitArray &other)
resize(qMax(size(), other.size()));
uchar *a1 = reinterpret_cast<uchar*>(d.data()) + 1;
const uchar *a2 = reinterpret_cast<const uchar *>(other.d.constData()) + 1;
- int n = other.d.size() - 1;
+ int n = other.d.size() - 1;
while (n-- > 0)
*a1++ |= *a2++;
return *this;
diff --git a/src/corelib/tools/qbitarray.h b/src/corelib/tools/qbitarray.h
index e622d6515c..1103712627 100644
--- a/src/corelib/tools/qbitarray.h
+++ b/src/corelib/tools/qbitarray.h
@@ -44,8 +44,6 @@
#include <QtCore/qbytearray.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -176,6 +174,4 @@ Q_DECLARE_SHARED(QBitArray)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QBITARRAY_H
diff --git a/src/corelib/tools/qbytearray.cpp b/src/corelib/tools/qbytearray.cpp
index 950d291986..dc3f5f3be9 100644
--- a/src/corelib/tools/qbytearray.cpp
+++ b/src/corelib/tools/qbytearray.cpp
@@ -397,7 +397,7 @@ static const quint16 crc_tbl[16] = {
0xc60c, 0xd68d, 0xe70e, 0xf78f
};
-/*!
+/*!
\relates QByteArray
Returns the CRC-16 checksum of the first \a len bytes of \a data.
@@ -422,7 +422,7 @@ quint16 qChecksum(const char *data, uint len)
return ~crc & 0xffff;
}
-/*!
+/*!
\fn QByteArray qCompress(const QByteArray& data, int compressionLevel)
\relates QByteArray
@@ -1370,7 +1370,7 @@ QByteArray::QByteArray(int size, char ch)
}
/*!
- \internal
+ \internal
Constructs a byte array of size \a size with uninitialized contents.
*/
@@ -1904,7 +1904,7 @@ QByteArray &QByteArray::replace(const QByteArray &before, const QByteArray &afte
QByteArray aft = after;
if (after.d == d)
aft.detach();
-
+
return replace(before.constData(), before.size(), aft.constData(), aft.size());
}
@@ -1921,7 +1921,7 @@ QByteArray &QByteArray::replace(const char *c, const QByteArray &after)
QByteArray aft = after;
if (after.d == d)
aft.detach();
-
+
return replace(c, qstrlen(c), aft.constData(), aft.size());
}
@@ -1954,7 +1954,7 @@ QByteArray &QByteArray::replace(const char *before, int bsize, const char *after
memcpy(copy, before, bsize);
b = copy;
}
-
+
QByteArrayMatcher matcher(before, bsize);
int index = 0;
int len = d->size;
@@ -2044,8 +2044,8 @@ QByteArray &QByteArray::replace(const char *before, int bsize, const char *after
::free((char *)a);
if (b != before)
::free((char *)b);
-
-
+
+
return *this;
}
@@ -2274,7 +2274,7 @@ int QByteArray::indexOf(const char *c, int from) const
const int ol = qstrlen(c);
if (ol == 1)
return indexOf(*c, from);
-
+
const int l = d->size;
if (from > d->size || ol + from > l)
return -1;
@@ -3580,7 +3580,7 @@ QByteArray QByteArray::toBase64() const
return tmp;
}
-/*!
+/*!
\fn QByteArray &QByteArray::setNum(int n, int base)
Sets the byte array to the printed value of \a n in base \a base (10
@@ -3597,21 +3597,21 @@ QByteArray QByteArray::toBase64() const
\sa number(), toInt()
*/
-/*!
+/*!
\fn QByteArray &QByteArray::setNum(uint n, int base)
\overload
\sa toUInt()
*/
-/*!
+/*!
\fn QByteArray &QByteArray::setNum(short n, int base)
\overload
\sa toShort()
*/
-/*!
+/*!
\fn QByteArray &QByteArray::setNum(ushort n, int base)
\overload
@@ -3677,7 +3677,7 @@ QByteArray &QByteArray::setNum(qulonglong n, int base)
return *this;
}
-/*!
+/*!
\overload
Sets the byte array to the printed value of \a n, formatted in format
@@ -3736,7 +3736,7 @@ QByteArray &QByteArray::setNum(double n, char f, int prec)
return *this;
}
-/*!
+/*!
\fn QByteArray &QByteArray::setNum(float n, char f, int prec)
\overload
@@ -3806,7 +3806,7 @@ QByteArray QByteArray::number(qulonglong n, int base)
return s;
}
-/*!
+/*!
\overload
Returns a byte array that contains the printed value of \a n,
diff --git a/src/corelib/tools/qbytearray.h b/src/corelib/tools/qbytearray.h
index 8d03951073..f3cc301a49 100644
--- a/src/corelib/tools/qbytearray.h
+++ b/src/corelib/tools/qbytearray.h
@@ -66,8 +66,6 @@
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -610,8 +608,6 @@ Q_DECLARE_SHARED(QByteArray)
QT_END_NAMESPACE
-QT_END_HEADER
-
#ifdef QT_USE_QSTRINGBUILDER
#include <QtCore/qstring.h>
#endif
diff --git a/src/corelib/tools/qbytearraymatcher.cpp b/src/corelib/tools/qbytearraymatcher.cpp
index 59d7629c27..bcd6a56aad 100644
--- a/src/corelib/tools/qbytearraymatcher.cpp
+++ b/src/corelib/tools/qbytearraymatcher.cpp
@@ -164,6 +164,7 @@ QByteArrayMatcher::QByteArrayMatcher(const QByteArrayMatcher &other)
*/
QByteArrayMatcher::~QByteArrayMatcher()
{
+ Q_UNUSED(d);
}
/*!
diff --git a/src/corelib/tools/qbytearraymatcher.h b/src/corelib/tools/qbytearraymatcher.h
index 370116e643..da6a337a69 100644
--- a/src/corelib/tools/qbytearraymatcher.h
+++ b/src/corelib/tools/qbytearraymatcher.h
@@ -44,8 +44,6 @@
#include <QtCore/qbytearray.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -97,6 +95,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QBYTEARRAYMATCHER_H
diff --git a/src/corelib/tools/qcache.h b/src/corelib/tools/qcache.h
index 2d2b9f3d45..5890a94dc2 100644
--- a/src/corelib/tools/qcache.h
+++ b/src/corelib/tools/qcache.h
@@ -44,8 +44,6 @@
#include <QtCore/qhash.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -200,6 +198,4 @@ void QCache<Key,T>::trim(int m)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCACHE_H
diff --git a/src/corelib/tools/qchar.cpp b/src/corelib/tools/qchar.cpp
index 6fdb3215b0..8545276dac 100644
--- a/src/corelib/tools/qchar.cpp
+++ b/src/corelib/tools/qchar.cpp
@@ -263,6 +263,132 @@ QT_BEGIN_NAMESPACE
*/
/*!
+ \enum QChar::Script
+ \since 5.1
+
+ This enum type defines the Unicode script property values.
+
+ For details about the Unicode script property values see
+ \l{http://www.unicode.org/reports/tr24/}{Unicode Standard Annex #24}.
+
+ In order to conform to C/C++ naming conventions "Script_" is prepended
+ to the codes used in the Unicode Standard.
+
+ \value Script_Unknown For unassigned, private-use, noncharacter, and surrogate code points.
+ \value Script_Inherited For characters that may be used with multiple scripts
+ and that inherit their script from the preceding characters.
+ These include nonspacing marks, enclosing marks,
+ and zero width joiner/non-joiner characters.
+ \value Script_Common For characters that may be used with multiple scripts
+ and that do not inherit their script from the preceding characters.
+
+ \value Script_Latin
+ \value Script_Greek
+ \value Script_Cyrillic
+ \value Script_Armenian
+ \value Script_Hebrew
+ \value Script_Arabic
+ \value Script_Syriac
+ \value Script_Thaana
+ \value Script_Devanagari
+ \value Script_Bengali
+ \value Script_Gurmukhi
+ \value Script_Gujarati
+ \value Script_Oriya
+ \value Script_Tamil
+ \value Script_Telugu
+ \value Script_Kannada
+ \value Script_Malayalam
+ \value Script_Sinhala
+ \value Script_Thai
+ \value Script_Lao
+ \value Script_Tibetan
+ \value Script_Myanmar
+ \value Script_Georgian
+ \value Script_Hangul
+ \value Script_Ethiopic
+ \value Script_Cherokee
+ \value Script_CanadianAboriginal
+ \value Script_Ogham
+ \value Script_Runic
+ \value Script_Khmer
+ \value Script_Mongolian
+ \value Script_Hiragana
+ \value Script_Katakana
+ \value Script_Bopomofo
+ \value Script_Han
+ \value Script_Yi
+ \value Script_OldItalic
+ \value Script_Gothic
+ \value Script_Deseret
+ \value Script_Tagalog
+ \value Script_Hanunoo
+ \value Script_Buhid
+ \value Script_Tagbanwa
+ \value Script_Coptic
+ \value Script_Limbu
+ \value Script_TaiLe
+ \value Script_LinearB
+ \value Script_Ugaritic
+ \value Script_Shavian
+ \value Script_Osmanya
+ \value Script_Cypriot
+ \value Script_Braille
+ \value Script_Buginese
+ \value Script_NewTaiLue
+ \value Script_Glagolitic
+ \value Script_Tifinagh
+ \value Script_SylotiNagri
+ \value Script_OldPersian
+ \value Script_Kharoshthi
+ \value Script_Balinese
+ \value Script_Cuneiform
+ \value Script_Phoenician
+ \value Script_PhagsPa
+ \value Script_Nko
+ \value Script_Sundanese
+ \value Script_Lepcha
+ \value Script_OlChiki
+ \value Script_Vai
+ \value Script_Saurashtra
+ \value Script_KayahLi
+ \value Script_Rejang
+ \value Script_Lycian
+ \value Script_Carian
+ \value Script_Lydian
+ \value Script_Cham
+ \value Script_TaiTham
+ \value Script_TaiViet
+ \value Script_Avestan
+ \value Script_EgyptianHieroglyphs
+ \value Script_Samaritan
+ \value Script_Lisu
+ \value Script_Bamum
+ \value Script_Javanese
+ \value Script_MeeteiMayek
+ \value Script_ImperialAramaic
+ \value Script_OldSouthArabian
+ \value Script_InscriptionalParthian
+ \value Script_InscriptionalPahlavi
+ \value Script_OldTurkic
+ \value Script_Kaithi
+ \value Script_Batak
+ \value Script_Brahmi
+ \value Script_Mandaic
+ \value Script_Chakma
+ \value Script_MeroiticCursive
+ \value Script_MeroiticHieroglyphs
+ \value Script_Miao
+ \value Script_Sharada
+ \value Script_SoraSompeng
+ \value Script_Takri
+
+ \omitvalue ScriptCount
+
+ \sa script()
+*/
+
+/*!
\enum QChar::Direction
This enum type defines the Unicode direction attributes. See the
@@ -1159,6 +1285,27 @@ unsigned char QChar::combiningClass(uint ucs4)
}
/*!
+ \fn QChar::Script QChar::script() const
+ \since 5.1
+
+ Returns the Unicode script property value for this character.
+*/
+
+/*!
+ \overload
+ \since 5.1
+
+ Returns the Unicode script property value for the character specified in
+ its UCS-4-encoded form as \a ucs4.
+*/
+QChar::Script QChar::script(uint ucs4)
+{
+ if (ucs4 > LastValidCodePoint)
+ return QChar::Script_Unknown;
+ return (QChar::Script) qGetProp(ucs4)->script;
+}
+
+/*!
\fn QChar::UnicodeVersion QChar::unicodeVersion() const
Returns the Unicode version that introduced this character.
diff --git a/src/corelib/tools/qchar.h b/src/corelib/tools/qchar.h
index 20101db975..8afa05bb00 100644
--- a/src/corelib/tools/qchar.h
+++ b/src/corelib/tools/qchar.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -137,6 +135,130 @@ public:
Symbol_Other // So
};
+ enum Script
+ {
+ Script_Unknown,
+ Script_Inherited,
+ Script_Common,
+
+ Script_Latin,
+ Script_Greek,
+ Script_Cyrillic,
+ Script_Armenian,
+ Script_Hebrew,
+ Script_Arabic,
+ Script_Syriac,
+ Script_Thaana,
+ Script_Devanagari,
+ Script_Bengali,
+ Script_Gurmukhi,
+ Script_Gujarati,
+ Script_Oriya,
+ Script_Tamil,
+ Script_Telugu,
+ Script_Kannada,
+ Script_Malayalam,
+ Script_Sinhala,
+ Script_Thai,
+ Script_Lao,
+ Script_Tibetan,
+ Script_Myanmar,
+ Script_Georgian,
+ Script_Hangul,
+ Script_Ethiopic,
+ Script_Cherokee,
+ Script_CanadianAboriginal,
+ Script_Ogham,
+ Script_Runic,
+ Script_Khmer,
+ Script_Mongolian,
+ Script_Hiragana,
+ Script_Katakana,
+ Script_Bopomofo,
+ Script_Han,
+ Script_Yi,
+ Script_OldItalic,
+ Script_Gothic,
+ Script_Deseret,
+ Script_Tagalog,
+ Script_Hanunoo,
+ Script_Buhid,
+ Script_Tagbanwa,
+ Script_Coptic,
+
+ // Unicode 4.0 additions
+ Script_Limbu,
+ Script_TaiLe,
+ Script_LinearB,
+ Script_Ugaritic,
+ Script_Shavian,
+ Script_Osmanya,
+ Script_Cypriot,
+ Script_Braille,
+
+ // Unicode 4.1 additions
+ Script_Buginese,
+ Script_NewTaiLue,
+ Script_Glagolitic,
+ Script_Tifinagh,
+ Script_SylotiNagri,
+ Script_OldPersian,
+ Script_Kharoshthi,
+
+ // Unicode 5.0 additions
+ Script_Balinese,
+ Script_Cuneiform,
+ Script_Phoenician,
+ Script_PhagsPa,
+ Script_Nko,
+
+ // Unicode 5.1 additions
+ Script_Sundanese,
+ Script_Lepcha,
+ Script_OlChiki,
+ Script_Vai,
+ Script_Saurashtra,
+ Script_KayahLi,
+ Script_Rejang,
+ Script_Lycian,
+ Script_Carian,
+ Script_Lydian,
+ Script_Cham,
+
+ // Unicode 5.2 additions
+ Script_TaiTham,
+ Script_TaiViet,
+ Script_Avestan,
+ Script_EgyptianHieroglyphs,
+ Script_Samaritan,
+ Script_Lisu,
+ Script_Bamum,
+ Script_Javanese,
+ Script_MeeteiMayek,
+ Script_ImperialAramaic,
+ Script_OldSouthArabian,
+ Script_InscriptionalParthian,
+ Script_InscriptionalPahlavi,
+ Script_OldTurkic,
+ Script_Kaithi,
+
+ // Unicode 6.0 additions
+ Script_Batak,
+ Script_Brahmi,
+ Script_Mandaic,
+
+ // Unicode 6.1 additions
+ Script_Chakma,
+ Script_MeroiticCursive,
+ Script_MeroiticHieroglyphs,
+ Script_Miao,
+ Script_Sharada,
+ Script_SoraSompeng,
+ Script_Takri,
+
+ ScriptCount
+ };
+
enum Direction
{
DirL, DirR, DirEN, DirES, DirET, DirAN, DirCS, DirB, DirS, DirWS, DirON,
@@ -231,6 +353,8 @@ public:
inline QChar toTitleCase() const { return QChar::toTitleCase(ucs); }
inline QChar toCaseFolded() const { return QChar::toCaseFolded(ucs); }
+ inline Script script() const { return QChar::script(ucs); }
+
inline UnicodeVersion unicodeVersion() const { return QChar::unicodeVersion(ucs); }
#if QT_DEPRECATED_SINCE(5, 0)
@@ -316,6 +440,8 @@ public:
static uint QT_FASTCALL toTitleCase(uint ucs4);
static uint QT_FASTCALL toCaseFolded(uint ucs4);
+ static Script QT_FASTCALL script(uint ucs4);
+
static UnicodeVersion QT_FASTCALL unicodeVersion(uint ucs4);
static UnicodeVersion QT_FASTCALL currentUnicodeVersion();
@@ -398,6 +524,4 @@ Q_CORE_EXPORT QDataStream &operator>>(QDataStream &, QChar &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCHAR_H
diff --git a/src/corelib/tools/qcollator_p.h b/src/corelib/tools/qcollator_p.h
index 4420c6592e..51de205565 100644
--- a/src/corelib/tools/qcollator_p.h
+++ b/src/corelib/tools/qcollator_p.h
@@ -45,8 +45,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qlocale.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QCollatorPrivate;
@@ -119,6 +117,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOLLATOR_P_H
diff --git a/src/corelib/tools/qcontainerfwd.h b/src/corelib/tools/qcontainerfwd.h
index c4866253ee..6b79e40635 100644
--- a/src/corelib/tools/qcontainerfwd.h
+++ b/src/corelib/tools/qcontainerfwd.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -65,6 +63,4 @@ template <class T> class QVector;
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCONTAINERFWD_H
diff --git a/src/corelib/tools/qcontiguouscache.cpp b/src/corelib/tools/qcontiguouscache.cpp
index bfef234ae4..b92c4d3fe9 100644
--- a/src/corelib/tools/qcontiguouscache.cpp
+++ b/src/corelib/tools/qcontiguouscache.cpp
@@ -313,8 +313,8 @@ MyRecord record(int row) const
In most cases it is better to use either at() or insert().
- \note This non-const overload of operator[] requires QContiguousCache
- to make a deep copy. Use at() for read-only access to a non-const
+ \note This non-const overload of operator[] requires QContiguousCache
+ to make a deep copy. Use at() for read-only access to a non-const
QContiguousCache.
\sa insert(), at()
diff --git a/src/corelib/tools/qcontiguouscache.h b/src/corelib/tools/qcontiguouscache.h
index 1075284491..d601ddb819 100644
--- a/src/corelib/tools/qcontiguouscache.h
+++ b/src/corelib/tools/qcontiguouscache.h
@@ -46,8 +46,6 @@
#include <limits.h>
#include <new>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#undef QT_QCONTIGUOUSCACHE_DEBUG
@@ -464,6 +462,4 @@ inline T QContiguousCache<T>::takeLast()
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/tools/qcryptographichash.cpp b/src/corelib/tools/qcryptographichash.cpp
index 3f17fe15aa..32f5f0b33a 100644
--- a/src/corelib/tools/qcryptographichash.cpp
+++ b/src/corelib/tools/qcryptographichash.cpp
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2013 Richard J. Moore <rich@kde.org>.
** Contact: http://www.qt-project.org/legal
**
** This file is part of the QtCore module of the Qt Toolkit.
@@ -40,12 +41,51 @@
****************************************************************************/
#include <qcryptographichash.h>
+#include <qiodevice.h>
+
+#include "../../3rdparty/sha1/sha1.cpp"
+#ifndef QT_CRYPTOGRAPHICHASH_ONLY_SHA1
+// qdoc only needs SHA-1
#include "../../3rdparty/md5/md5.h"
#include "../../3rdparty/md5/md5.cpp"
#include "../../3rdparty/md4/md4.h"
#include "../../3rdparty/md4/md4.cpp"
-#include "../../3rdparty/sha1/sha1.cpp"
+
+typedef unsigned char BitSequence;
+typedef unsigned long long DataLength;
+typedef enum { SUCCESS = 0, FAIL = 1, BAD_HASHLEN = 2 } HashReturn;
+
+#include "../../3rdparty/sha3/KeccakSponge.c"
+typedef spongeState hashState;
+
+#include "../../3rdparty/sha3/KeccakNISTInterface.c"
+
+/*
+ This lets us choose between SHA3 implementations at build time.
+ */
+typedef spongeState SHA3Context;
+typedef HashReturn (SHA3Init)(hashState *state, int hashbitlen);
+typedef HashReturn (SHA3Update)(hashState *state, const BitSequence *data, DataLength databitlen);
+typedef HashReturn (SHA3Final)(hashState *state, BitSequence *hashval);
+
+#if QT_POINTER_SIZE == 8 // 64 bit version
+
+#include "../../3rdparty/sha3/KeccakF-1600-opt64.c"
+
+static SHA3Init * const sha3Init = Init;
+static SHA3Update * const sha3Update = Update;
+static SHA3Final * const sha3Final = Final;
+
+#else // 32 bit optimised fallback
+
+#include "../../3rdparty/sha3/KeccakF-1600-opt32.c"
+
+static SHA3Init * const sha3Init = Init;
+static SHA3Update * const sha3Update = Update;
+static SHA3Final * const sha3Final = Final;
+
+#endif
/*
These #defines replace the typedefs needed by the RFC6234 code. Normally
@@ -88,8 +128,6 @@ static int SHA384_512AddLength(SHA512Context *context, unsigned int length);
#undef uint68_t
#undef int_least16_t
-#include <qiodevice.h>
-
static inline int SHA224_256AddLength(SHA256Context *context, unsigned int length)
{
QT_PREPEND_NAMESPACE(quint32) addTemp;
@@ -100,6 +138,7 @@ static inline int SHA384_512AddLength(SHA512Context *context, unsigned int lengt
QT_PREPEND_NAMESPACE(quint64) addTemp;
return SHA384_512AddLengthM(context, length);
}
+#endif // QT_CRYPTOGRAPHICHASH_ONLY_SHA1
QT_BEGIN_NAMESPACE
@@ -108,13 +147,16 @@ class QCryptographicHashPrivate
public:
QCryptographicHash::Algorithm method;
union {
+ Sha1State sha1Context;
+#ifndef QT_CRYPTOGRAPHICHASH_ONLY_SHA1
MD5Context md5Context;
md4_context md4Context;
- Sha1State sha1Context;
SHA224Context sha224Context;
SHA256Context sha256Context;
SHA384Context sha384Context;
SHA512Context sha512Context;
+ SHA3Context sha3Context;
+#endif
};
QByteArray result;
};
@@ -141,10 +183,14 @@ public:
\value Md4 Generate an MD4 hash sum
\value Md5 Generate an MD5 hash sum
\value Sha1 Generate an SHA-1 hash sum
- \value Sha224 Generate an SHA-224 hash sum. Introduced in Qt 5.0
- \value Sha256 Generate an SHA-256 hash sum. Introduced in Qt 5.0
- \value Sha384 Generate an SHA-384 hash sum. Introduced in Qt 5.0
- \value Sha512 Generate an SHA-512 hash sum. Introduced in Qt 5.0
+ \value Sha224 Generate an SHA-224 hash sum (SHA-2). Introduced in Qt 5.0
+ \value Sha256 Generate an SHA-256 hash sum (SHA-2). Introduced in Qt 5.0
+ \value Sha384 Generate an SHA-384 hash sum (SHA-2). Introduced in Qt 5.0
+ \value Sha512 Generate an SHA-512 hash sum (SHA-2). Introduced in Qt 5.0
+ \value Sha3_224 Generate an SHA3-224 hash sum. Introduced in Qt 5.1
+ \value Sha3_256 Generate an SHA3-256 hash sum. Introduced in Qt 5.1
+ \value Sha3_384 Generate an SHA3-384 hash sum. Introduced in Qt 5.1
+ \value Sha3_512 Generate an SHA3-512 hash sum. Introduced in Qt 5.1
*/
/*!
@@ -171,15 +217,21 @@ QCryptographicHash::~QCryptographicHash()
void QCryptographicHash::reset()
{
switch (d->method) {
+ case Sha1:
+ sha1InitState(&d->sha1Context);
+ break;
+#ifdef QT_CRYPTOGRAPHICHASH_ONLY_SHA1
+ default:
+ Q_ASSERT_X(false, "QCryptographicHash", "Method not compiled in");
+ Q_UNREACHABLE();
+ break;
+#else
case Md4:
md4_init(&d->md4Context);
break;
case Md5:
MD5Init(&d->md5Context);
break;
- case Sha1:
- sha1InitState(&d->sha1Context);
- break;
case Sha224:
SHA224Reset(&d->sha224Context);
break;
@@ -192,6 +244,19 @@ void QCryptographicHash::reset()
case Sha512:
SHA512Reset(&d->sha512Context);
break;
+ case Sha3_224:
+ sha3Init(&d->sha3Context, 224);
+ break;
+ case Sha3_256:
+ sha3Init(&d->sha3Context, 256);
+ break;
+ case Sha3_384:
+ sha3Init(&d->sha3Context, 384);
+ break;
+ case Sha3_512:
+ sha3Init(&d->sha3Context, 512);
+ break;
+#endif
}
d->result.clear();
}
@@ -203,15 +268,21 @@ void QCryptographicHash::reset()
void QCryptographicHash::addData(const char *data, int length)
{
switch (d->method) {
+ case Sha1:
+ sha1Update(&d->sha1Context, (const unsigned char *)data, length);
+ break;
+#ifdef QT_CRYPTOGRAPHICHASH_ONLY_SHA1
+ default:
+ Q_ASSERT_X(false, "QCryptographicHash", "Method not compiled in");
+ Q_UNREACHABLE();
+ break;
+#else
case Md4:
md4_update(&d->md4Context, (const unsigned char *)data, length);
break;
case Md5:
MD5Update(&d->md5Context, (const unsigned char *)data, length);
break;
- case Sha1:
- sha1Update(&d->sha1Context, (const unsigned char *)data, length);
- break;
case Sha224:
SHA224Input(&d->sha224Context, reinterpret_cast<const unsigned char *>(data), length);
break;
@@ -224,7 +295,20 @@ void QCryptographicHash::addData(const char *data, int length)
case Sha512:
SHA512Input(&d->sha512Context, reinterpret_cast<const unsigned char *>(data), length);
break;
- }
+ case Sha3_224:
+ sha3Update(&d->sha3Context, reinterpret_cast<const BitSequence *>(data), length*8);
+ break;
+ case Sha3_256:
+ sha3Update(&d->sha3Context, reinterpret_cast<const BitSequence *>(data), length*8);
+ break;
+ case Sha3_384:
+ sha3Update(&d->sha3Context, reinterpret_cast<const BitSequence *>(data), length*8);
+ break;
+ case Sha3_512:
+ sha3Update(&d->sha3Context, reinterpret_cast<const BitSequence *>(data), length*8);
+ break;
+#endif
+ }
d->result.clear();
}
@@ -266,10 +350,23 @@ bool QCryptographicHash::addData(QIODevice* device)
*/
QByteArray QCryptographicHash::result() const
{
- if (!d->result.isEmpty())
+ if (!d->result.isEmpty())
return d->result;
switch (d->method) {
+ case Sha1: {
+ Sha1State copy = d->sha1Context;
+ d->result.resize(20);
+ sha1FinalizeState(&copy);
+ sha1ToHash(&copy, (unsigned char *)d->result.data());
+ break;
+ }
+#ifdef QT_CRYPTOGRAPHICHASH_ONLY_SHA1
+ default:
+ Q_ASSERT_X(false, "QCryptographicHash", "Method not compiled in");
+ Q_UNREACHABLE();
+ break;
+#else
case Md4: {
md4_context copy = d->md4Context;
d->result.resize(MD4_RESULTLEN);
@@ -282,13 +379,6 @@ QByteArray QCryptographicHash::result() const
MD5Final(&copy, (unsigned char *)d->result.data());
break;
}
- case Sha1: {
- Sha1State copy = d->sha1Context;
- d->result.resize(20);
- sha1FinalizeState(&copy);
- sha1ToHash(&copy, (unsigned char *)d->result.data());
- break;
- }
case Sha224: {
SHA224Context copy = d->sha224Context;
d->result.resize(SHA224HashSize);
@@ -313,6 +403,31 @@ QByteArray QCryptographicHash::result() const
SHA512Result(&copy, reinterpret_cast<unsigned char *>(d->result.data()));
break;
}
+ case Sha3_224: {
+ SHA3Context copy = d->sha3Context;
+ d->result.resize(224/8);
+ sha3Final(&copy, reinterpret_cast<BitSequence *>(d->result.data()));
+ break;
+ }
+ case Sha3_256: {
+ SHA3Context copy = d->sha3Context;
+ d->result.resize(256/8);
+ sha3Final(&copy, reinterpret_cast<BitSequence *>(d->result.data()));
+ break;
+ }
+ case Sha3_384: {
+ SHA3Context copy = d->sha3Context;
+ d->result.resize(384/8);
+ sha3Final(&copy, reinterpret_cast<BitSequence *>(d->result.data()));
+ break;
+ }
+ case Sha3_512: {
+ SHA3Context copy = d->sha3Context;
+ d->result.resize(512/8);
+ sha3Final(&copy, reinterpret_cast<BitSequence *>(d->result.data()));
+ break;
+ }
+#endif
}
return d->result;
}
diff --git a/src/corelib/tools/qcryptographichash.h b/src/corelib/tools/qcryptographichash.h
index 1a7e3751e8..d4e75c4667 100644
--- a/src/corelib/tools/qcryptographichash.h
+++ b/src/corelib/tools/qcryptographichash.h
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2013 Richard J. Moore <rich@kde.org>.
** Contact: http://www.qt-project.org/legal
**
** This file is part of the QtCore module of the Qt Toolkit.
@@ -44,8 +45,6 @@
#include <QtCore/qbytearray.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -62,7 +61,11 @@ public:
Sha224,
Sha256,
Sha384,
- Sha512
+ Sha512,
+ Sha3_224,
+ Sha3_256,
+ Sha3_384,
+ Sha3_512
};
explicit QCryptographicHash(Algorithm method);
@@ -84,6 +87,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/tools/qdatetime.cpp b/src/corelib/tools/qdatetime.cpp
index 86a6a020cd..07b617ee2e 100644
--- a/src/corelib/tools/qdatetime.cpp
+++ b/src/corelib/tools/qdatetime.cpp
@@ -93,11 +93,6 @@ static inline QDate fixedDate(int y, int m, int d)
return result;
}
-static inline qint64 floordiv(qint64 a, qint64 b)
-{
- return (a - (a < 0 ? b-1 : 0)) / b;
-}
-
static inline qint64 floordiv(qint64 a, int b)
{
return (a - (a < 0 ? b-1 : 0)) / b;
@@ -548,8 +543,8 @@ int QDate::weekNumber(int *yearNumber) const
\li 12 = "Dec"
\endlist
- The month names will be localized according to the system's locale
- settings.
+ The month names will be localized according to the system's default
+ locale settings.
Returns an empty string if the date is invalid.
@@ -595,8 +590,8 @@ QString QDate::shortMonthName(int month, QDate::MonthNameType type)
\li 12 = "December"
\endlist
- The month names will be localized according to the system's locale
- settings.
+ The month names will be localized according to the system's default
+ locale settings.
Returns an empty string if the date is invalid.
@@ -637,8 +632,8 @@ QString QDate::longMonthName(int month, MonthNameType type)
\li 7 = "Sun"
\endlist
- The day names will be localized according to the system's locale
- settings.
+ The day names will be localized according to the system's default
+ locale settings.
Returns an empty string if the date is invalid.
@@ -679,8 +674,8 @@ QString QDate::shortDayName(int weekday, MonthNameType type)
\li 7 = "Sunday"
\endlist
- The day names will be localized according to the system's locale
- settings.
+ The day names will be localized according to the system's default
+ locale settings.
Returns an empty string if the date is invalid.
@@ -717,8 +712,8 @@ QString QDate::longDayName(int weekday, MonthNameType type)
If the \a format is Qt::TextDate, the string is formatted in
the default way. QDate::shortDayName() and QDate::shortMonthName()
are used to generate the string, so the day and month names will
- be localized names. An example of this formatting is
- "Sat May 20 1995".
+ be localized names using the default locale from the system. An
+ example of this formatting is "Sat May 20 1995".
If the \a format is Qt::ISODate, the string format corresponds
to the ISO 8601 extended specification for representations of
@@ -2405,9 +2400,9 @@ uint QDateTime::toTime_t() const
(Qt::UTC). On systems that do not support time zones this function
will behave as if local time were Qt::UTC.
- Note that there are possible values for \a msecs that lie outside the
- valid range of QDateTime, both negative and positive. The behavior of
- this function is undefined for those values.
+ Note that passing the minimum of \c qint64
+ (\c{std::numeric_limits<qint64>::min()}) to \a msecs will result in
+ undefined behavior.
\sa toMSecsSinceEpoch(), setTime_t()
*/
@@ -4010,7 +4005,7 @@ static QDateTimePrivate::Spec utcToLocal(QDate &date, QTime &time)
time = QTime();
return QDateTimePrivate::LocalUnknown;
} else {
- int deltaDays = fakeDate.daysTo(date);
+ qint64 deltaDays = fakeDate.daysTo(date);
date = QDate(brokenDown->tm_year + 1900, brokenDown->tm_mon + 1, brokenDown->tm_mday);
time = QTime(brokenDown->tm_hour, brokenDown->tm_min, brokenDown->tm_sec, time.msec());
date = date.addDays(deltaDays);
@@ -4045,6 +4040,16 @@ static void localToUtc(QDate &date, QTime &time, int isdst)
_tzset();
#endif
time_t secsSince1Jan1970UTC = mktime(&localTM);
+#ifdef Q_OS_QNX
+ //mktime sometimes fails on QNX. Following workaround converts the date and time then manually
+ if (secsSince1Jan1970UTC == (time_t)-1) {
+ QDateTime tempTime = QDateTime(date, time, Qt::UTC);;
+ tempTime = tempTime.addMSecs(timezone * 1000);
+ date = tempTime.date();
+ time = tempTime.time();
+ return;
+ }
+#endif
#endif
tm *brokenDown = 0;
#if defined(Q_OS_WINCE)
@@ -4078,7 +4083,7 @@ static void localToUtc(QDate &date, QTime &time, int isdst)
date = QDate(1970, 1, 1);
time = QTime();
} else {
- int deltaDays = fakeDate.daysTo(date);
+ qint64 deltaDays = fakeDate.daysTo(date);
date = QDate(brokenDown->tm_year + 1900, brokenDown->tm_mon + 1, brokenDown->tm_mday);
time = QTime(brokenDown->tm_hour, brokenDown->tm_min, brokenDown->tm_sec, time.msec());
date = date.addDays(deltaDays);
diff --git a/src/corelib/tools/qdatetime.h b/src/corelib/tools/qdatetime.h
index ae545eda4f..d1cc10c877 100644
--- a/src/corelib/tools/qdatetime.h
+++ b/src/corelib/tools/qdatetime.h
@@ -48,8 +48,6 @@
#include <limits>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -296,6 +294,4 @@ Q_CORE_EXPORT uint qHash(const QTime &key, uint seed = 0) Q_DECL_NOTHROW;
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDATETIME_H
diff --git a/src/corelib/tools/qdatetime_p.h b/src/corelib/tools/qdatetime_p.h
index 4f61e34bf9..c70571d509 100644
--- a/src/corelib/tools/qdatetime_p.h
+++ b/src/corelib/tools/qdatetime_p.h
@@ -101,6 +101,9 @@ public:
void getUTC(QDate &outDate, QTime &outTime) const;
static QDateTime addMSecs(const QDateTime &dt, qint64 msecs);
static void addMSecs(QDate &utcDate, QTime &utcTime, qint64 msecs);
+
+ static inline qint64 minJd() { return QDate::minJd(); }
+ static inline qint64 maxJd() { return QDate::maxJd(); }
};
#ifndef QT_BOOTSTRAPPED
diff --git a/src/corelib/tools/qeasingcurve.h b/src/corelib/tools/qeasingcurve.h
index cb8519d204..2e65754989 100644
--- a/src/corelib/tools/qeasingcurve.h
+++ b/src/corelib/tools/qeasingcurve.h
@@ -50,8 +50,6 @@
# include <QtCore/qpoint.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -142,6 +140,4 @@ Q_CORE_EXPORT QDataStream &operator>>(QDataStream &, QEasingCurve &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/tools/qelapsedtimer.h b/src/corelib/tools/qelapsedtimer.h
index 3fb9c6bffe..b06afe4ab4 100644
--- a/src/corelib/tools/qelapsedtimer.h
+++ b/src/corelib/tools/qelapsedtimer.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -89,6 +87,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QELAPSEDTIMER_H
diff --git a/src/corelib/tools/qelapsedtimer_mac.cpp b/src/corelib/tools/qelapsedtimer_mac.cpp
index 611098779c..19056d1bd9 100644
--- a/src/corelib/tools/qelapsedtimer_mac.cpp
+++ b/src/corelib/tools/qelapsedtimer_mac.cpp
@@ -76,14 +76,14 @@ static qint64 absoluteToMSecs(qint64 cpuTime)
return absoluteToNSecs(cpuTime) / 1000000;
}
-timeval qt_gettime() Q_DECL_NOTHROW
+timespec qt_gettime() Q_DECL_NOTHROW
{
- timeval tv;
+ timespec tv;
uint64_t cpu_time = mach_absolute_time();
uint64_t nsecs = absoluteToNSecs(cpu_time);
tv.tv_sec = nsecs / 1000000000ull;
- tv.tv_usec = (nsecs / 1000) - (tv.tv_sec * 1000000);
+ tv.tv_nsec = nsecs - (tv.tv_sec * 1000000000ull);
return tv;
}
diff --git a/src/corelib/tools/qelapsedtimer_unix.cpp b/src/corelib/tools/qelapsedtimer_unix.cpp
index e719358ce0..f81a723aa5 100644
--- a/src/corelib/tools/qelapsedtimer_unix.cpp
+++ b/src/corelib/tools/qelapsedtimer_unix.cpp
@@ -43,8 +43,12 @@
#define _POSIX_C_SOURCE 200809L
#include "qelapsedtimer.h"
+#ifdef Q_OS_VXWORKS
+#include "qfunctions_vxworks.h"
+#else
#include <sys/time.h>
#include <time.h>
+#endif
#include <unistd.h>
#include <qatomic.h>
@@ -168,14 +172,14 @@ static inline void do_gettime(qint64 *sec, qint64 *frac)
}
// used in qcore_unix.cpp and qeventdispatcher_unix.cpp
-timeval qt_gettime() Q_DECL_NOTHROW
+struct timespec qt_gettime() Q_DECL_NOTHROW
{
qint64 sec, frac;
do_gettime(&sec, &frac);
- timeval tv;
+ timespec tv;
tv.tv_sec = sec;
- tv.tv_usec = frac / 1000;
+ tv.tv_nsec = frac;
return tv;
}
diff --git a/src/corelib/tools/qfreelist_p.h b/src/corelib/tools/qfreelist_p.h
index 3de0d0b204..5e90a03d7f 100644
--- a/src/corelib/tools/qfreelist_p.h
+++ b/src/corelib/tools/qfreelist_p.h
@@ -55,8 +55,6 @@
#include <QtCore/qatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -288,6 +286,4 @@ inline void QFreeList<T, ConstantsType>::release(int id)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFREELIST_P_H
diff --git a/src/corelib/tools/qharfbuzz_p.h b/src/corelib/tools/qharfbuzz_p.h
index 1cbfb03f63..27ddb44e91 100644
--- a/src/corelib/tools/qharfbuzz_p.h
+++ b/src/corelib/tools/qharfbuzz_p.h
@@ -53,11 +53,308 @@
#ifndef QHARFBUZZ_P_H
#define QHARFBUZZ_P_H
-#include <QtCore/qglobal.h>
-#include <private/harfbuzz-shaper.h>
+#include <QtCore/qchar.h>
+
+#if defined(QT_BUILD_CORE_LIB)
+# include <harfbuzz-shaper.h>
+#else
+// a minimal set of HB types required for Qt libs other than Core
+extern "C" {
+
+typedef enum {
+ /* no error */
+ HB_Err_Ok = 0x0000,
+ HB_Err_Not_Covered = 0xFFFF,
+
+ /* _hb_err() is called whenever returning the following errors,
+ * and in a couple places for HB_Err_Not_Covered too. */
+
+ /* programmer error */
+ HB_Err_Invalid_Argument = 0x1A66,
+
+ /* font error */
+ HB_Err_Invalid_SubTable_Format = 0x157F,
+ HB_Err_Invalid_SubTable = 0x1570,
+ HB_Err_Read_Error = 0x6EAD,
+
+ /* system error */
+ HB_Err_Out_Of_Memory = 0xDEAD
+} HB_Error;
+
+typedef QT_PREPEND_NAMESPACE(qint8) hb_int8;
+typedef QT_PREPEND_NAMESPACE(quint8) hb_uint8;
+typedef QT_PREPEND_NAMESPACE(qint16) hb_int16;
+typedef QT_PREPEND_NAMESPACE(quint16) hb_uint16;
+typedef QT_PREPEND_NAMESPACE(qint32) hb_int32;
+typedef QT_PREPEND_NAMESPACE(quint32) hb_uint32;
+
+typedef hb_uint8 HB_Bool;
+typedef hb_uint8 HB_Byte;
+typedef hb_uint16 HB_UShort;
+typedef hb_uint32 HB_UInt;
+typedef hb_int8 HB_Char;
+typedef hb_int16 HB_Short;
+typedef hb_int32 HB_Int;
+typedef hb_uint16 HB_UChar16;
+typedef hb_uint32 HB_UChar32;
+typedef hb_uint32 HB_Glyph;
+typedef hb_int32 HB_Fixed; /* 26.6 */
+typedef hb_int32 HB_16Dot16; /* 16.16 */
+typedef hb_uint32 HB_Tag;
+
+typedef struct {
+ HB_Fixed x;
+ HB_Fixed y;
+} HB_FixedPoint;
+
+typedef enum {
+ HB_Script_Common,
+ HB_Script_Greek,
+ HB_Script_Cyrillic,
+ HB_Script_Armenian,
+ HB_Script_Hebrew,
+ HB_Script_Arabic,
+ HB_Script_Syriac,
+ HB_Script_Thaana,
+ HB_Script_Devanagari,
+ HB_Script_Bengali,
+ HB_Script_Gurmukhi,
+ HB_Script_Gujarati,
+ HB_Script_Oriya,
+ HB_Script_Tamil,
+ HB_Script_Telugu,
+ HB_Script_Kannada,
+ HB_Script_Malayalam,
+ HB_Script_Sinhala,
+ HB_Script_Thai,
+ HB_Script_Lao,
+ HB_Script_Tibetan,
+ HB_Script_Myanmar,
+ HB_Script_Georgian,
+ HB_Script_Hangul,
+ HB_Script_Ogham,
+ HB_Script_Runic,
+ HB_Script_Khmer,
+ HB_Script_Nko,
+ HB_Script_Inherited,
+ HB_ScriptCount = HB_Script_Inherited
+} HB_Script;
+
+typedef enum {
+ HB_NoJustification= 0, /* Justification can't be applied after this glyph */
+ HB_Arabic_Space = 1, /* This glyph represents a space inside arabic text */
+ HB_Character = 2, /* Inter-character justification point follows this glyph */
+ HB_Space = 4, /* This glyph represents a blank outside an Arabic run */
+ HB_Arabic_Normal = 7, /* Normal Middle-Of-Word glyph that connects to the right (begin) */
+ HB_Arabic_Waw = 8, /* Next character is final form of Waw/Ain/Qaf/Fa */
+ HB_Arabic_BaRa = 9, /* Next two chars are Ba + Ra/Ya/AlefMaksura */
+ HB_Arabic_Alef = 10, /* Next character is final form of Alef/Tah/Lam/Kaf/Gaf */
+ HB_Arabic_HaaDal = 11, /* Next character is final form of Haa/Dal/Taa Marbutah */
+ HB_Arabic_Seen = 12, /* Initial or Medial form Of Seen/Sad */
+ HB_Arabic_Kashida = 13 /* Kashida(U+640) in middle of word */
+} HB_JustificationClass;
+
+#ifdef __xlC__
+typedef unsigned hb_bitfield;
+#else
+typedef hb_uint8 hb_bitfield;
+#endif
+
+typedef struct {
+ hb_bitfield justification :4; /* Justification class */
+ hb_bitfield clusterStart :1; /* First glyph of representation of cluster */
+ hb_bitfield mark :1; /* needs to be positioned around base char */
+ hb_bitfield zeroWidth :1; /* ZWJ, ZWNJ etc, with no width */
+ hb_bitfield dontPrint :1;
+ hb_bitfield combiningClass :8;
+} HB_GlyphAttributes;
+
+typedef void * HB_GDEF;
+typedef void * HB_GSUB;
+typedef void * HB_GPOS;
+typedef void * HB_Buffer;
+
+typedef HB_Error (*HB_GetFontTableFunc)(void *font, HB_Tag tag, HB_Byte *buffer, HB_UInt *length);
+
+typedef struct HB_FaceRec_ {
+ HB_Bool isSymbolFont;
+
+ HB_GDEF gdef;
+ HB_GSUB gsub;
+ HB_GPOS gpos;
+ HB_Bool supported_scripts[HB_ScriptCount];
+ HB_Buffer buffer;
+ HB_Script current_script;
+ int current_flags; /* HB_ShaperFlags */
+ HB_Bool has_opentype_kerning;
+ HB_Bool glyphs_substituted;
+ HB_GlyphAttributes *tmpAttributes;
+ unsigned int *tmpLogClusters;
+ int length;
+ int orig_nglyphs;
+ void *font_for_init;
+ HB_GetFontTableFunc get_font_table_func;
+} HB_FaceRec;
+
+typedef struct {
+ HB_Fixed x, y;
+ HB_Fixed width, height;
+ HB_Fixed xOffset, yOffset;
+} HB_GlyphMetrics;
+
+typedef enum {
+ HB_FontAscent
+} HB_FontMetric;
+
+struct HB_Font_;
+typedef struct HB_Font_ *HB_Font;
+typedef struct HB_FaceRec_ *HB_Face;
+
+typedef struct {
+ HB_Bool (*convertStringToGlyphIndices)(HB_Font font, const HB_UChar16 *string, hb_uint32 length, HB_Glyph *glyphs, hb_uint32 *numGlyphs, HB_Bool rightToLeft);
+ void (*getGlyphAdvances)(HB_Font font, const HB_Glyph *glyphs, hb_uint32 numGlyphs, HB_Fixed *advances, int flags /*HB_ShaperFlag*/);
+ HB_Bool (*canRender)(HB_Font font, const HB_UChar16 *string, hb_uint32 length);
+ /* implementation needs to make sure to load a scaled glyph, so /no/ FT_LOAD_NO_SCALE */
+ HB_Error (*getPointInOutline)(HB_Font font, HB_Glyph glyph, int flags /*HB_ShaperFlag*/, hb_uint32 point, HB_Fixed *xpos, HB_Fixed *ypos, hb_uint32 *nPoints);
+ void (*getGlyphMetrics)(HB_Font font, HB_Glyph glyph, HB_GlyphMetrics *metrics);
+ HB_Fixed (*getFontMetric)(HB_Font font, HB_FontMetric metric);
+} HB_FontClass;
+
+typedef struct HB_Font_ {
+ const HB_FontClass *klass;
+
+ /* Metrics */
+ HB_UShort x_ppem, y_ppem;
+ HB_16Dot16 x_scale, y_scale;
+
+ void *userData;
+} HB_FontRec;
+
+typedef enum {
+ HB_LeftToRight = 0,
+ HB_RightToLeft = 1
+} HB_StringToGlyphsFlags;
+
+typedef enum {
+ HB_ShaperFlag_Default = 0,
+ HB_ShaperFlag_NoKerning = 1,
+ HB_ShaperFlag_UseDesignMetrics = 2
+} HB_ShaperFlag;
+
+typedef struct
+{
+ hb_uint32 pos;
+ hb_uint32 length;
+ HB_Script script;
+ hb_uint8 bidiLevel;
+} HB_ScriptItem;
+
+typedef struct HB_ShaperItem_ HB_ShaperItem;
+
+struct HB_ShaperItem_ {
+ const HB_UChar16 *string; /* input: the Unicode UTF16 text to be shaped */
+ hb_uint32 stringLength; /* input: the length of the input in 16-bit words */
+ HB_ScriptItem item; /* input: the current run to be shaped: a run of text all in the same script that is a substring of <string> */
+ HB_Font font; /* input: the font: scale, units and function pointers supplying glyph indices and metrics */
+ HB_Face face; /* input: the shaper state; current script, access to the OpenType tables , etc. */
+ int shaperFlags; /* input (unused) should be set to 0; intended to support flags defined in HB_ShaperFlag */
+ HB_Bool glyphIndicesPresent; /* input: true if the <glyphs> array contains glyph indices ready to be shaped */
+ hb_uint32 initialGlyphCount; /* input: if glyphIndicesPresent is true, the number of glyph indices in the <glyphs> array */
+
+ hb_uint32 num_glyphs; /* input: capacity of output arrays <glyphs>, <attributes>, <advances>, <offsets>, and <log_clusters>; */
+ /* output: required capacity (may be larger than actual capacity) */
+
+ HB_Glyph *glyphs; /* output: <num_glyphs> indices of shaped glyphs */
+ HB_GlyphAttributes *attributes; /* output: <num_glyphs> glyph attributes */
+ HB_Fixed *advances; /* output: <num_glyphs> advances */
+ HB_FixedPoint *offsets; /* output: <num_glyphs> offsets */
+ unsigned short *log_clusters; /* output: for each output glyph, the index in the input of the start of its logical cluster */
+
+ /* internal */
+ HB_Bool kerning_applied; /* output: true if kerning was applied by the shaper */
+};
+
+}
+
+#endif // QT_BUILD_CORE_LIB
+
QT_BEGIN_NAMESPACE
+static inline HB_Script script_to_hbscript(uchar script)
+{
+ switch (script) {
+ case QChar::Script_Inherited: return HB_Script_Inherited;
+ case QChar::Script_Common: return HB_Script_Common;
+ case QChar::Script_Arabic: return HB_Script_Arabic;
+ case QChar::Script_Armenian: return HB_Script_Armenian;
+ case QChar::Script_Bengali: return HB_Script_Bengali;
+ case QChar::Script_Cyrillic: return HB_Script_Cyrillic;
+ case QChar::Script_Devanagari: return HB_Script_Devanagari;
+ case QChar::Script_Georgian: return HB_Script_Georgian;
+ case QChar::Script_Greek: return HB_Script_Greek;
+ case QChar::Script_Gujarati: return HB_Script_Gujarati;
+ case QChar::Script_Gurmukhi: return HB_Script_Gurmukhi;
+ case QChar::Script_Hangul: return HB_Script_Hangul;
+ case QChar::Script_Hebrew: return HB_Script_Hebrew;
+ case QChar::Script_Kannada: return HB_Script_Kannada;
+ case QChar::Script_Khmer: return HB_Script_Khmer;
+ case QChar::Script_Lao: return HB_Script_Lao;
+ case QChar::Script_Malayalam: return HB_Script_Malayalam;
+ case QChar::Script_Myanmar: return HB_Script_Myanmar;
+ case QChar::Script_Ogham: return HB_Script_Ogham;
+ case QChar::Script_Oriya: return HB_Script_Oriya;
+ case QChar::Script_Runic: return HB_Script_Runic;
+ case QChar::Script_Sinhala: return HB_Script_Sinhala;
+ case QChar::Script_Syriac: return HB_Script_Syriac;
+ case QChar::Script_Tamil: return HB_Script_Tamil;
+ case QChar::Script_Telugu: return HB_Script_Telugu;
+ case QChar::Script_Thaana: return HB_Script_Thaana;
+ case QChar::Script_Thai: return HB_Script_Thai;
+ case QChar::Script_Tibetan: return HB_Script_Tibetan;
+ case QChar::Script_Nko: return HB_Script_Nko;
+ default: break;
+ };
+ return HB_Script_Common;
+}
+
+static inline uchar hbscript_to_script(uchar script)
+{
+ switch (script) {
+ case HB_Script_Inherited: return QChar::Script_Inherited;
+ case HB_Script_Common: return QChar::Script_Common;
+ case HB_Script_Arabic: return QChar::Script_Arabic;
+ case HB_Script_Armenian: return QChar::Script_Armenian;
+ case HB_Script_Bengali: return QChar::Script_Bengali;
+ case HB_Script_Cyrillic: return QChar::Script_Cyrillic;
+ case HB_Script_Devanagari: return QChar::Script_Devanagari;
+ case HB_Script_Georgian: return QChar::Script_Georgian;
+ case HB_Script_Greek: return QChar::Script_Greek;
+ case HB_Script_Gujarati: return QChar::Script_Gujarati;
+ case HB_Script_Gurmukhi: return QChar::Script_Gurmukhi;
+ case HB_Script_Hangul: return QChar::Script_Hangul;
+ case HB_Script_Hebrew: return QChar::Script_Hebrew;
+ case HB_Script_Kannada: return QChar::Script_Kannada;
+ case HB_Script_Khmer: return QChar::Script_Khmer;
+ case HB_Script_Lao: return QChar::Script_Lao;
+ case HB_Script_Malayalam: return QChar::Script_Malayalam;
+ case HB_Script_Myanmar: return QChar::Script_Myanmar;
+ case HB_Script_Ogham: return QChar::Script_Ogham;
+ case HB_Script_Oriya: return QChar::Script_Oriya;
+ case HB_Script_Runic: return QChar::Script_Runic;
+ case HB_Script_Sinhala: return QChar::Script_Sinhala;
+ case HB_Script_Syriac: return QChar::Script_Syriac;
+ case HB_Script_Tamil: return QChar::Script_Tamil;
+ case HB_Script_Telugu: return QChar::Script_Telugu;
+ case HB_Script_Thaana: return QChar::Script_Thaana;
+ case HB_Script_Thai: return QChar::Script_Thai;
+ case HB_Script_Tibetan: return QChar::Script_Tibetan;
+ case HB_Script_Nko: return QChar::Script_Nko;
+ default: break;
+ };
+ return QChar::Script_Common;
+}
+
Q_CORE_EXPORT HB_Bool qShapeItem(HB_ShaperItem *item);
// ### temporary
@@ -70,4 +367,4 @@ Q_DECLARE_TYPEINFO(HB_FixedPoint, Q_PRIMITIVE_TYPE);
QT_END_NAMESPACE
-#endif
+#endif // QHARFBUZZ_P_H
diff --git a/src/corelib/tools/qhash.cpp b/src/corelib/tools/qhash.cpp
index 0103a208f3..ed756cbeb6 100644
--- a/src/corelib/tools/qhash.cpp
+++ b/src/corelib/tools/qhash.cpp
@@ -574,7 +574,7 @@ void QHashData::checkSanity()
\fn uint qHash(const QPair<T1, T2> &key, uint seed = 0)
\since 5.0
\relates QHash
-
+
Returns the hash value for the \a key, using \a seed to seed the calculation.
Types \c T1 and \c T2 must be supported by qHash().
@@ -924,6 +924,16 @@ void QHashData::checkSanity()
\sa clear()
*/
+/*! \fn QHash::QHash(std::initializer_list<std::pair<Key,T> > list)
+ \since 5.1
+
+ Constructs a hash with a copy of each of the elements in the
+ initializer list \a list.
+
+ This function is only available if the program is being
+ compiled in C++11 mode.
+*/
+
/*! \fn QHash::QHash(const QHash<Key, T> &other)
Constructs a copy of \a other.
@@ -1981,6 +1991,16 @@ void QHashData::checkSanity()
Constructs an empty hash.
*/
+/*! \fn QMultiHash::QMultiHash(std::initializer_list<std::pair<Key,T> > list)
+ \since 5.1
+
+ Constructs a multi hash with a copy of each of the elements in the
+ initializer list \a list.
+
+ This function is only available if the program is being
+ compiled in C++11 mode.
+*/
+
/*! \fn QMultiHash::QMultiHash(const QHash<Key, T> &other)
Constructs a copy of \a other (which can be a QHash or a
diff --git a/src/corelib/tools/qhash.h b/src/corelib/tools/qhash.h
index 98965b9121..5d9238f453 100644
--- a/src/corelib/tools/qhash.h
+++ b/src/corelib/tools/qhash.h
@@ -48,7 +48,9 @@
#include <QtCore/qpair.h>
#include <QtCore/qrefcount.h>
-QT_BEGIN_HEADER
+#ifdef Q_COMPILER_INITIALIZER_LISTS
+#include <initializer_list>
+#endif
QT_BEGIN_NAMESPACE
@@ -285,6 +287,15 @@ class QHash
public:
inline QHash() : d(const_cast<QHashData *>(&QHashData::shared_null)) { }
+#ifdef Q_COMPILER_INITIALIZER_LISTS
+ inline QHash(std::initializer_list<std::pair<Key,T> > list)
+ : d(const_cast<QHashData *>(&QHashData::shared_null))
+ {
+ reserve(list.size());
+ for (typename std::initializer_list<std::pair<Key,T> >::const_iterator it = list.begin(); it != list.end(); ++it)
+ insert(it->first, it->second);
+ }
+#endif
inline QHash(const QHash<Key, T> &other) : d(other.d) { d->ref.ref(); if (!d->sharable) detach(); }
inline ~QHash() { if (!d->ref.deref()) freeData(d); }
@@ -921,6 +932,14 @@ class QMultiHash : public QHash<Key, T>
{
public:
QMultiHash() {}
+#ifdef Q_COMPILER_INITIALIZER_LISTS
+ inline QMultiHash(std::initializer_list<std::pair<Key,T> > list)
+ {
+ this->reserve(list.size());
+ for (typename std::initializer_list<std::pair<Key,T> >::const_iterator it = list.begin(); it != list.end(); ++it)
+ insert(it->first, it->second);
+ }
+#endif
QMultiHash(const QHash<Key, T> &other) : QHash<Key, T>(other) {}
inline void swap(QMultiHash<Key, T> &other) { QHash<Key, T>::swap(other); } // prevent QMultiHash<->QHash swaps
@@ -1034,6 +1053,4 @@ Q_DECLARE_MUTABLE_ASSOCIATIVE_ITERATOR(Hash)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QHASH_H
diff --git a/src/corelib/tools/qiterator.h b/src/corelib/tools/qiterator.h
index ad2d8bae41..3b86edd750 100644
--- a/src/corelib/tools/qiterator.h
+++ b/src/corelib/tools/qiterator.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#define Q_DECLARE_SEQUENTIAL_ITERATOR(C) \
@@ -190,6 +188,4 @@ public: \
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QITERATOR_H
diff --git a/src/corelib/tools/qiterator.qdoc b/src/corelib/tools/qiterator.qdoc
index 798d25e050..25914967a9 100644
--- a/src/corelib/tools/qiterator.qdoc
+++ b/src/corelib/tools/qiterator.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\class QListIterator
\inmodule QtCore
@@ -78,7 +78,7 @@
\sa QMutableListIterator, QList::const_iterator
*/
-/*!
+/*!
\class QLinkedListIterator
\inmodule QtCore
@@ -126,7 +126,7 @@
\sa QMutableLinkedListIterator, QLinkedList::const_iterator
*/
-/*!
+/*!
\class QVectorIterator
\inmodule QtCore
\brief The QVectorIterator class provides a Java-style const iterator for QVector and QStack.
@@ -178,7 +178,7 @@
\sa QMutableVectorIterator, QVector::const_iterator
*/
-/*!
+/*!
\class QSetIterator
\inmodule QtCore
\brief The QSetIterator class provides a Java-style const iterator for QSet.
@@ -225,7 +225,7 @@
\sa QMutableSetIterator, QSet::const_iterator
*/
-/*!
+/*!
\class QMutableListIterator
\inmodule QtCore
@@ -291,7 +291,7 @@
\sa QListIterator, QList::iterator
*/
-/*!
+/*!
\class QMutableLinkedListIterator
\inmodule QtCore
@@ -352,7 +352,7 @@
\sa QLinkedListIterator, QLinkedList::iterator
*/
-/*!
+/*!
\class QMutableVectorIterator
\inmodule QtCore
@@ -418,7 +418,7 @@
\sa QVectorIterator, QVector::iterator
*/
-/*!
+/*!
\class QMutableSetIterator
\inmodule QtCore
\since 4.2
@@ -869,7 +869,7 @@
\sa remove(), setValue()
*/
-/*!
+/*!
\class QMapIterator
\inmodule QtCore
@@ -921,7 +921,7 @@
\sa QMutableMapIterator, QMap::const_iterator
*/
-/*!
+/*!
\class QHashIterator
\inmodule QtCore
@@ -973,7 +973,7 @@
\sa QMutableHashIterator, QHash::const_iterator
*/
-/*!
+/*!
\class QMutableMapIterator
\inmodule QtCore
@@ -1038,7 +1038,7 @@
\sa QMapIterator, QMap::iterator
*/
-/*!
+/*!
\class QMutableHashIterator
\inmodule QtCore
diff --git a/src/corelib/tools/qline.cpp b/src/corelib/tools/qline.cpp
index 5d8368e930..3fb958fae6 100644
--- a/src/corelib/tools/qline.cpp
+++ b/src/corelib/tools/qline.cpp
@@ -374,7 +374,7 @@ QDataStream &operator>>(QDataStream &stream, QLine &line)
\value UnboundedIntersection The two lines intersect, but not
within the range defined by their lengths. This will be the case
- if the lines are not parallel.
+ if the lines are not parallel.
intersect() will also return this value if the intersect point is
within the start and end point of only one of the lines.
@@ -499,9 +499,9 @@ QDataStream &operator>>(QDataStream &stream, QLine &line)
Sets the length of the line to the given \a length. QLineF will
move the end point - p2() - of the line to give the line its new length.
-
+
If the line is a null line, the length will remain zero regardless
- of the length specified.
+ of the length specified.
\sa length(), isNull()
*/
diff --git a/src/corelib/tools/qline.h b/src/corelib/tools/qline.h
index cf87067b61..69e8a8245a 100644
--- a/src/corelib/tools/qline.h
+++ b/src/corelib/tools/qline.h
@@ -44,8 +44,6 @@
#include <QtCore/qpoint.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -421,6 +419,4 @@ Q_CORE_EXPORT QDataStream &operator>>(QDataStream &, QLineF &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLINE_H
diff --git a/src/corelib/tools/qlinkedlist.h b/src/corelib/tools/qlinkedlist.h
index 383d6eb990..b9ca1b964a 100644
--- a/src/corelib/tools/qlinkedlist.h
+++ b/src/corelib/tools/qlinkedlist.h
@@ -48,8 +48,6 @@
#include <iterator>
#include <list>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -501,6 +499,4 @@ Q_DECLARE_MUTABLE_SEQUENTIAL_ITERATOR(LinkedList)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLINKEDLIST_H
diff --git a/src/corelib/tools/qlist.cpp b/src/corelib/tools/qlist.cpp
index 49f5ae4210..760c944c29 100644
--- a/src/corelib/tools/qlist.cpp
+++ b/src/corelib/tools/qlist.cpp
@@ -511,7 +511,8 @@ void **QListData::erase(void **xi)
Construct a list from the std::initializer_list specified by \a args.
- This constructor is only enabled if the compiler supports C++0x
+ This constructor is only enabled if the compiler supports C++11 initializer
+ lists.
*/
/*! \fn QList::~QList()
diff --git a/src/corelib/tools/qlist.h b/src/corelib/tools/qlist.h
index 98326e5e00..0592c24e9f 100644
--- a/src/corelib/tools/qlist.h
+++ b/src/corelib/tools/qlist.h
@@ -57,8 +57,6 @@
#include <limits.h>
#include <string.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -910,6 +908,4 @@ Q_DECLARE_MUTABLE_SEQUENTIAL_ITERATOR(List)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLIST_H
diff --git a/src/corelib/tools/qlocale.cpp b/src/corelib/tools/qlocale.cpp
index 365033d84a..4aaa1af688 100644
--- a/src/corelib/tools/qlocale.cpp
+++ b/src/corelib/tools/qlocale.cpp
@@ -164,14 +164,14 @@ QLocale::Country QLocalePrivate::codeToCountry(const QString &code)
return QLocale::AnyCountry;
}
-QString QLocalePrivate::languageCode() const
+QString QLocalePrivate::languageToCode(QLocale::Language language)
{
- if (m_data->m_language_id == QLocale::AnyLanguage)
+ if (language == QLocale::AnyLanguage)
return QString();
- if (m_data->m_language_id == QLocale::C)
+ if (language == QLocale::C)
return QLatin1String("C");
- const unsigned char *c = language_code_list + 3*(uint(m_data->m_language_id));
+ const unsigned char *c = language_code_list + 3*(uint(language));
QString code(c[2] == 0 ? 2 : 3, Qt::Uninitialized);
@@ -183,20 +183,20 @@ QString QLocalePrivate::languageCode() const
return code;
}
-QString QLocalePrivate::scriptCode() const
+QString QLocalePrivate::scriptToCode(QLocale::Script script)
{
- if (m_data->m_script_id == QLocale::AnyScript || m_data->m_script_id > QLocale::LastScript)
+ if (script == QLocale::AnyScript || script > QLocale::LastScript)
return QString();
- const unsigned char *c = script_code_list + 4*(uint(m_data->m_script_id));
+ const unsigned char *c = script_code_list + 4*(uint(script));
return QString::fromLatin1((const char *)c, 4);
}
-QString QLocalePrivate::countryCode() const
+QString QLocalePrivate::countryToCode(QLocale::Country country)
{
- if (m_data->m_country_id == QLocale::AnyCountry)
+ if (country == QLocale::AnyCountry)
return QString();
- const unsigned char *c = country_code_list + 3*(uint(m_data->m_country_id));
+ const unsigned char *c = country_code_list + 3*(uint(country));
QString code(c[2] == 0 ? 2 : 3, Qt::Uninitialized);
@@ -1327,6 +1327,224 @@ double QLocale::toDouble(const QString &s, bool *ok) const
}
/*!
+ Returns the short int represented by the localized string \a s.
+
+ If the conversion fails the function returns 0.
+
+ If \a ok is not null, failure is reported by setting *ok to false, and
+ success by setting *ok to true.
+
+ This function ignores leading and trailing whitespace.
+
+ \sa toUShort(), toString()
+
+ \since 5.1
+*/
+
+short QLocale::toShort(const QStringRef &s, bool *ok) const
+{
+ qlonglong i = toLongLong(s, ok);
+ if (i < SHRT_MIN || i > SHRT_MAX) {
+ if (ok)
+ *ok = false;
+ return 0;
+ }
+ return short(i);
+}
+
+/*!
+ Returns the unsigned short int represented by the localized string \a s.
+
+ If the conversion fails the function returns 0.
+
+ If \a ok is not null, failure is reported by setting *ok to false, and
+ success by setting *ok to true.
+
+ This function ignores leading and trailing whitespace.
+
+ \sa toShort(), toString()
+
+ \since 5.1
+*/
+
+ushort QLocale::toUShort(const QStringRef &s, bool *ok) const
+{
+ qulonglong i = toULongLong(s, ok);
+ if (i > USHRT_MAX) {
+ if (ok)
+ *ok = false;
+ return 0;
+ }
+ return ushort(i);
+}
+
+/*!
+ Returns the int represented by the localized string \a s.
+
+ If the conversion fails the function returns 0.
+
+ If \a ok is not null, failure is reported by setting *ok to false, and
+ success by setting *ok to true.
+
+ This function ignores leading and trailing whitespace.
+
+ \sa toUInt(), toString()
+
+ \since 5.1
+*/
+
+int QLocale::toInt(const QStringRef &s, bool *ok) const
+{
+ qlonglong i = toLongLong(s, ok);
+ if (i < INT_MIN || i > INT_MAX) {
+ if (ok)
+ *ok = false;
+ return 0;
+ }
+ return int(i);
+}
+
+/*!
+ Returns the unsigned int represented by the localized string \a s.
+
+ If the conversion fails the function returns 0.
+
+ If \a ok is not null, failure is reported by setting *ok to false, and
+ success by setting *ok to true.
+
+ This function ignores leading and trailing whitespace.
+
+ \sa toInt(), toString()
+
+ \since 5.1
+*/
+
+uint QLocale::toUInt(const QStringRef &s, bool *ok) const
+{
+ qulonglong i = toULongLong(s, ok);
+ if (i > UINT_MAX) {
+ if (ok)
+ *ok = false;
+ return 0;
+ }
+ return uint(i);
+}
+
+/*!
+ Returns the long long int represented by the localized string \a s.
+
+ If the conversion fails the function returns 0.
+
+ If \a ok is not null, failure is reported by setting *ok to false, and
+ success by setting *ok to true.
+
+ This function ignores leading and trailing whitespace.
+
+ \sa toInt(), toULongLong(), toDouble(), toString()
+
+ \since 5.1
+*/
+
+
+qlonglong QLocale::toLongLong(const QStringRef &s, bool *ok) const
+{
+ QLocalePrivate::GroupSeparatorMode mode
+ = d->m_numberOptions & RejectGroupSeparator
+ ? QLocalePrivate::FailOnGroupSeparators
+ : QLocalePrivate::ParseGroupSeparators;
+
+ return d->stringToLongLong(s, 10, ok, mode);
+}
+
+/*!
+ Returns the unsigned long long int represented by the localized
+ string \a s.
+
+ If the conversion fails the function returns 0.
+
+ If \a ok is not null, failure is reported by setting *ok to false, and
+ success by setting *ok to true.
+
+ This function ignores leading and trailing whitespace.
+
+ \sa toLongLong(), toInt(), toDouble(), toString()
+
+ \since 5.1
+*/
+
+qulonglong QLocale::toULongLong(const QStringRef &s, bool *ok) const
+{
+ QLocalePrivate::GroupSeparatorMode mode
+ = d->m_numberOptions & RejectGroupSeparator
+ ? QLocalePrivate::FailOnGroupSeparators
+ : QLocalePrivate::ParseGroupSeparators;
+
+ return d->stringToUnsLongLong(s, 10, ok, mode);
+}
+
+/*!
+ Returns the float represented by the localized string \a s, or 0.0
+ if the conversion failed.
+
+ If \a ok is not null, reports failure by setting
+ *ok to false and success by setting *ok to true.
+
+ This function ignores leading and trailing whitespace.
+
+ \sa toDouble(), toInt(), toString()
+
+ \since 5.1
+*/
+
+float QLocale::toFloat(const QStringRef &s, bool *ok) const
+{
+ bool myOk;
+ double d = toDouble(s, &myOk);
+ if (!myOk || d > QT_MAX_FLOAT || d < -QT_MAX_FLOAT) {
+ if (ok)
+ *ok = false;
+ return 0.0;
+ }
+ if (ok)
+ *ok = true;
+ return float(d);
+}
+
+/*!
+ Returns the double represented by the localized string \a s, or
+ 0.0 if the conversion failed.
+
+ If \a ok is not null, reports failure by setting
+ *ok to false and success by setting *ok to true.
+
+ Unlike QString::toDouble(), this function does not fall back to
+ the "C" locale if the string cannot be interpreted in this
+ locale.
+
+ \snippet code/src_corelib_tools_qlocale.cpp 3
+
+ Notice that the last conversion returns 1234.0, because '.' is the
+ thousands group separator in the German locale.
+
+ This function ignores leading and trailing whitespace.
+
+ \sa toFloat(), toInt(), toString()
+
+ \since 5.1
+*/
+
+double QLocale::toDouble(const QStringRef &s, bool *ok) const
+{
+ QLocalePrivate::GroupSeparatorMode mode
+ = d->m_numberOptions & RejectGroupSeparator
+ ? QLocalePrivate::FailOnGroupSeparators
+ : QLocalePrivate::ParseGroupSeparators;
+
+ return d->stringToDouble(s, ok, mode);
+}
+
+
+/*!
Returns a localized string representation of \a i.
\sa toLongLong()
@@ -2240,20 +2458,27 @@ QLocale::MeasurementSystem QLocale::measurementSystem() const
*/
Qt::LayoutDirection QLocale::textDirection() const
{
- switch (language()) {
- case QLocale::Arabic:
- case QLocale::Hebrew:
- case QLocale::Persian:
- case QLocale::Pashto:
- case QLocale::Urdu:
- case QLocale::Syriac:
- case QLocale::Divehi:
+ switch (script()) {
+ case QLocale::ArabicScript:
+ case QLocale::AvestanScript:
+ case QLocale::CypriotScript:
+ case QLocale::HebrewScript:
+ case QLocale::ImperialAramaicScript:
+ case QLocale::InscriptionalPahlaviScript:
+ case QLocale::InscriptionalParthianScript:
+ case QLocale::KharoshthiScript:
+ case QLocale::LydianScript:
+ case QLocale::MandaeanScript:
+ case QLocale::MeroiticCursiveScript:
+ case QLocale::MeroiticScript:
+ case QLocale::SamaritanScript:
+ case QLocale::SyriacScript:
+ case QLocale::ThaanaScript:
+ case QLocale::NkoScript:
+ case QLocale::OldSouthArabianScript:
+ case QLocale::OrkhonScript:
+ case QLocale::PhoenicianScript:
return Qt::RightToLeft;
- case QLocale::Punjabi:
- case QLocale::Uzbek:
- if (script() == QLocale::ArabicScript)
- return Qt::RightToLeft;
- // fall through
default:
break;
}
@@ -2892,12 +3117,12 @@ QString QLocalePrivate::unsLongLongToString(const QChar zero, const QChar group,
number. We can't detect junk here, since we don't even know the base
of the number.
*/
-bool QLocalePrivate::numberToCLocale(const QString &num,
+bool QLocalePrivate::numberToCLocale(const QChar *str, int len,
GroupSeparatorMode group_sep_mode,
CharBuff *result) const
{
- const QChar *uc = num.unicode();
- int l = num.length();
+ const QChar *uc = str;
+ int l = len;
int idx = 0;
// Skip whitespace
@@ -3043,7 +3268,13 @@ double QLocalePrivate::stringToDouble(const QString &number, bool *ok,
GroupSeparatorMode group_sep_mode) const
{
CharBuff buff;
- if (!numberToCLocale(group().unicode() == 0xa0 ? number.trimmed() : number,
+ // Do not use the ternary operator - triggers msvc2012 bug in optimized builds
+ QString trimmedNumber;
+ if (group().unicode() == 0xa0)
+ trimmedNumber = number.trimmed();
+ else
+ trimmedNumber = number;
+ if (!numberToCLocale(trimmedNumber.unicode(), trimmedNumber.size(),
group_sep_mode, &buff)) {
if (ok != 0)
*ok = false;
@@ -3056,7 +3287,13 @@ qlonglong QLocalePrivate::stringToLongLong(const QString &number, int base,
bool *ok, GroupSeparatorMode group_sep_mode) const
{
CharBuff buff;
- if (!numberToCLocale(group().unicode() == 0xa0 ? number.trimmed() : number,
+ // Do not use the ternary operator - triggers msvc2012 bug in optimized builds
+ QString trimmedNumber;
+ if (group().unicode() == 0xa0)
+ trimmedNumber = number.trimmed();
+ else
+ trimmedNumber = number;
+ if (!numberToCLocale(trimmedNumber.unicode(), trimmedNumber.size(),
group_sep_mode, &buff)) {
if (ok != 0)
*ok = false;
@@ -3070,7 +3307,13 @@ qulonglong QLocalePrivate::stringToUnsLongLong(const QString &number, int base,
bool *ok, GroupSeparatorMode group_sep_mode) const
{
CharBuff buff;
- if (!numberToCLocale(group().unicode() == 0xa0 ? number.trimmed() : number,
+ // Do not use the ternary operator - triggers msvc2012 bug in optimized builds
+ QString trimmedNumber;
+ if (group().unicode() == 0xa0)
+ trimmedNumber = number.trimmed();
+ else
+ trimmedNumber = number;
+ if (!numberToCLocale(trimmedNumber.unicode(), trimmedNumber.size(),
group_sep_mode, &buff)) {
if (ok != 0)
*ok = false;
@@ -3080,6 +3323,64 @@ qulonglong QLocalePrivate::stringToUnsLongLong(const QString &number, int base,
return bytearrayToUnsLongLong(buff.constData(), base, ok);
}
+double QLocalePrivate::stringToDouble(const QStringRef &number, bool *ok,
+ GroupSeparatorMode group_sep_mode) const
+{
+ CharBuff buff;
+ QStringRef trimmedNumber;
+ // Do not use the ternary operator - triggers msvc2012 bug in optimized builds
+ if (group().unicode() == 0xa0)
+ trimmedNumber = number.trimmed();
+ else
+ trimmedNumber = number;
+ if (!numberToCLocale(trimmedNumber.unicode(), trimmedNumber.size(),
+ group_sep_mode, &buff)) {
+ if (ok != 0)
+ *ok = false;
+ return 0.0;
+ }
+ return bytearrayToDouble(buff.constData(), ok);
+}
+
+qlonglong QLocalePrivate::stringToLongLong(const QStringRef &number, int base,
+ bool *ok, GroupSeparatorMode group_sep_mode) const
+{
+ CharBuff buff;
+ QStringRef trimmedNumber;
+ // Do not use the ternary operator - triggers msvc2012 bug in optimized builds
+ if (group().unicode() == 0xa0)
+ trimmedNumber = number.trimmed();
+ else
+ trimmedNumber = number;
+ if (!numberToCLocale(trimmedNumber.unicode(), trimmedNumber.size(),
+ group_sep_mode, &buff)) {
+ if (ok != 0)
+ *ok = false;
+ return 0;
+ }
+
+ return bytearrayToLongLong(buff.constData(), base, ok);
+}
+
+qulonglong QLocalePrivate::stringToUnsLongLong(const QStringRef &number, int base,
+ bool *ok, GroupSeparatorMode group_sep_mode) const
+{
+ CharBuff buff;
+ QStringRef trimmedNumber;
+ // Do not use the ternary operator - triggers msvc2012 bug in optimized builds
+ if (group().unicode() == 0xa0)
+ trimmedNumber = number.trimmed();
+ else
+ trimmedNumber = number;
+ if (!numberToCLocale(trimmedNumber.unicode(), trimmedNumber.size(),
+ group_sep_mode, &buff)) {
+ if (ok != 0)
+ *ok = false;
+ return 0;
+ }
+
+ return bytearrayToUnsLongLong(buff.constData(), base, ok);
+}
double QLocalePrivate::bytearrayToDouble(const char *num, bool *ok, bool *overflow)
{
diff --git a/src/corelib/tools/qlocale.h b/src/corelib/tools/qlocale.h
index 4283a31c43..78fa336b7c 100644
--- a/src/corelib/tools/qlocale.h
+++ b/src/corelib/tools/qlocale.h
@@ -47,8 +47,6 @@
#include <QtCore/qobjectdefs.h>
#include <QtCore/qshareddata.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -69,6 +67,7 @@ class Q_CORE_EXPORT QLocale
Q_ENUMS(Country)
Q_ENUMS(MeasurementSystem)
friend class QString;
+ friend class QStringRef;
friend class QByteArray;
friend class QIntValidator;
friend class QDoubleValidatorPrivate;
@@ -207,7 +206,7 @@ public:
Turkish = 125,
Turkmen = 126,
Tahitian = 127,
- Uigur = 128,
+ Uighur = 128,
Ukrainian = 129,
Urdu = 130,
Uzbek = 131,
@@ -340,6 +339,57 @@ public:
Kako = 258,
Meta = 259,
Ngiemboon = 260,
+ Aragonese = 261,
+ Akkadian = 262,
+ AncientEgyptian = 263,
+ AncientGreek = 264,
+ Aramaic = 265,
+ Balinese = 266,
+ Bamun = 267,
+ BatakToba = 268,
+ Buginese = 269,
+ Buhid = 270,
+ Carian = 271,
+ Chakma = 272,
+ ClassicalMandaic = 273,
+ Coptic = 274,
+ Dogri = 275,
+ EasternCham = 276,
+ EasternKayah = 277,
+ Etruscan = 278,
+ Gothic = 279,
+ Hanunoo = 280,
+ Ingush = 281,
+ LargeFloweryMiao = 282,
+ Lepcha = 283,
+ Limbu = 284,
+ Lisu = 285,
+ Lu = 286,
+ Lycian = 287,
+ Lydian = 288,
+ Mandingo = 289,
+ Manipuri = 290,
+ Meroitic = 291,
+ NorthernThai = 292,
+ OldIrish = 293,
+ OldNorse = 294,
+ OldPersian = 295,
+ OldTurkish = 296,
+ Pahlavi = 297,
+ Parthian = 298,
+ Phoenician = 299,
+ PrakritLanguage = 300,
+ Rejang = 301,
+ Sabaean = 302,
+ Samaritan = 303,
+ Santali = 304,
+ Saurashtra = 305,
+ Sora = 306,
+ Sylheti = 307,
+ Tagbanwa = 308,
+ TaiDam = 309,
+ TaiNua = 310,
+ Ugaritic = 311,
Norwegian = NorwegianBokmal,
Moldavian = Romanian,
SerboCroatian = Serbian,
@@ -353,7 +403,8 @@ public:
RhaetoRomance = Romansh,
Chewa = Nyanja,
Frisian = WesternFrisian,
- LastLanguage = Ngiemboon
+ Uigur = Uighur,
+ LastLanguage = Ugaritic
};
enum Script {
@@ -393,9 +444,78 @@ public:
SyriacScript = 33,
YiScript = 34,
VaiScript = 35,
+ AvestanScript = 36,
+ BalineseScript = 37,
+ BamumScript = 38,
+ BatakScript = 39,
+ BopomofoScript = 40,
+ BrahmiScript = 41,
+ BugineseScript = 42,
+ BuhidScript = 43,
+ CanadianAboriginalScript = 44,
+ CarianScript = 45,
+ ChakmaScript = 46,
+ ChamScript = 47,
+ CopticScript = 48,
+ CypriotScript = 49,
+ EgyptianHieroglyphsScript = 50,
+ FraserScript = 51,
+ GlagoliticScript = 52,
+ GothicScript = 53,
+ HanScript = 54,
+ HangulScript = 55,
+ HanunooScript = 56,
+ ImperialAramaicScript = 57,
+ InscriptionalPahlaviScript = 58,
+ InscriptionalParthianScript = 59,
+ JavaneseScript = 60,
+ KaithiScript = 61,
+ KatakanaScript = 62,
+ KayahLiScript = 63,
+ KharoshthiScript = 64,
+ LannaScript = 65,
+ LepchaScript = 66,
+ LimbuScript = 67,
+ LinearBScript = 68,
+ LycianScript = 69,
+ LydianScript = 70,
+ MandaeanScript = 71,
+ MeiteiMayekScript = 72,
+ MeroiticScript = 73,
+ MeroiticCursiveScript = 74,
+ NkoScript = 75,
+ NewTaiLueScript = 76,
+ OghamScript = 77,
+ OlChikiScript = 78,
+ OldItalicScript = 79,
+ OldPersianScript = 80,
+ OldSouthArabianScript = 81,
+ OrkhonScript = 82,
+ OsmanyaScript = 83,
+ PhagsPaScript = 84,
+ PhoenicianScript = 85,
+ PollardPhoneticScript = 86,
+ RejangScript = 87,
+ RunicScript = 88,
+ SamaritanScript = 89,
+ SaurashtraScript = 90,
+ SharadaScript = 91,
+ ShavianScript = 92,
+ SoraSompengScript = 93,
+ CuneiformScript = 94,
+ SundaneseScript = 95,
+ SylotiNagriScript = 96,
+ TagalogScript = 97,
+ TagbanwaScript = 98,
+ TaiLeScript = 99,
+ TaiVietScript = 100,
+ TakriScript = 101,
+ UgariticScript = 102,
+ BrailleScript = 103,
+ HiraganaScript = 104,
SimplifiedChineseScript = SimplifiedHanScript,
TraditionalChineseScript = TraditionalHanScript,
- LastScript = VaiScript
+ LastScript = HiraganaScript
};
enum Country {
AnyCountry = 0,
@@ -712,6 +832,15 @@ public:
float toFloat(const QString &s, bool *ok = 0) const;
double toDouble(const QString &s, bool *ok = 0) const;
+ short toShort(const QStringRef &s, bool *ok = 0) const;
+ ushort toUShort(const QStringRef &s, bool *ok = 0) const;
+ int toInt(const QStringRef &s, bool *ok = 0) const;
+ uint toUInt(const QStringRef &s, bool *ok = 0) const;
+ qlonglong toLongLong(const QStringRef &s, bool *ok = 0) const;
+ qulonglong toULongLong(const QStringRef &s, bool *ok = 0) const;
+ float toFloat(const QStringRef &s, bool *ok = 0) const;
+ double toDouble(const QStringRef &s, bool *ok = 0) const;
+
QString toString(qlonglong i) const;
QString toString(qulonglong i) const;
inline QString toString(short i) const;
@@ -843,6 +972,4 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QLocale &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLOCALE_H
diff --git a/src/corelib/tools/qlocale.qdoc b/src/corelib/tools/qlocale.qdoc
index 8c76833fc1..150e4a18ce 100644
--- a/src/corelib/tools/qlocale.qdoc
+++ b/src/corelib/tools/qlocale.qdoc
@@ -92,7 +92,7 @@
\note For the current keyboard input locale take a look at
QInputMethod::locale().
- QLocale's data is based on Common Locale Data Repository v22.1.
+ QLocale's data is based on Common Locale Data Repository v23.
The double-to-string and string-to-double conversion functions are
covered by the following licenses:
@@ -289,7 +289,8 @@
\value Turkish
\value Turkmen
\value Twi Obsolete, please use Akan
- \value Uigur
+ \value Uighur
+ \value Uigur Obsolete, please use Uighur
\value Ukrainian
\value Urdu
\value Uzbek
@@ -401,6 +402,57 @@
\value Kako
\value Meta
\value Ngiemboon
+ \value Aragonese
+ \value Akkadian
+ \value AncientEgyptian
+ \value AncientGreek
+ \value Aramaic
+ \value Balinese
+ \value Bamun
+ \value BatakToba
+ \value Buginese
+ \value Buhid
+ \value Carian
+ \value Chakma
+ \value ClassicalMandaic
+ \value Coptic
+ \value Dogri
+ \value EasternCham
+ \value EasternKayah
+ \value Etruscan
+ \value Gothic
+ \value Hanunoo
+ \value Ingush
+ \value LargeFloweryMiao
+ \value Lepcha
+ \value Limbu
+ \value Lisu
+ \value Lu
+ \value Lycian
+ \value Lydian
+ \value Mandingo
+ \value Manipuri
+ \value Meroitic
+ \value NorthernThai
+ \value OldIrish
+ \value OldNorse
+ \value OldPersian
+ \value OldTurkish
+ \value Pahlavi
+ \value Parthian
+ \value Phoenician
+ \value PrakritLanguage
+ \value Rejang
+ \value Sabaean
+ \value Samaritan
+ \value Santali
+ \value Saurashtra
+ \value Sora
+ \value Sylheti
+ \value Tagbanwa
+ \value TaiDam
+ \value TaiNua
+ \value Ugaritic
\omitvalue LastLanguage
\sa language(), languageToString()
@@ -686,42 +738,111 @@
\value AnyScript
\value ArabicScript
- \value CyrillicScript
- \value DeseretScript
- \value GurmukhiScript
- \value SimplifiedHanScript same as SimplifiedChineseScript
- \value SimplifiedChineseScript same as SimplifiedHanScript
- \value TraditionalHanScript same as TraditionalChineseScript
- \value TraditionalChineseScript same as TraditionalHanScript
- \value LatinScript
- \value MongolianScript
- \value TifinaghScript
\value ArmenianScript
+ \value AvestanScript
+ \value BalineseScript
+ \value BamumScript
+ \value BatakScript
\value BengaliScript
+ \value BopomofoScript
+ \value BrahmiScript
+ \value BrailleScript
+ \value BugineseScript
+ \value BuhidScript
+ \value CanadianAboriginalScript
+ \value CarianScript
+ \value ChakmaScript
+ \value ChamScript
\value CherokeeScript
+ \value CopticScript
+ \value CypriotScript
+ \value CyrillicScript
+ \value DeseretScript
\value DevanagariScript
+ \value EgyptianHieroglyphsScript
\value EthiopicScript
+ \value FraserScript
\value GeorgianScript
+ \value GlagoliticScript
+ \value GothicScript
\value GreekScript
\value GujaratiScript
+ \value GurmukhiScript
+ \value HanScript
+ \value HangulScript
+ \value HanunooScript
\value HebrewScript
+ \value HiraganaScript
+ \value ImperialAramaicScript
+ \value InscriptionalPahlaviScript
+ \value InscriptionalParthianScript
\value JapaneseScript
- \value KhmerScript
+ \value JavaneseScript
+ \value KaithiScript
\value KannadaScript
+ \value KatakanaScript
+ \value KayahLiScript
+ \value KharoshthiScript
+ \value KhmerScript
\value KoreanScript
+ \value LannaScript
\value LaoScript
+ \value LatinScript
+ \value LepchaScript
+ \value LimbuScript
+ \value LinearBScript
+ \value LycianScript
+ \value LydianScript
\value MalayalamScript
+ \value MandaeanScript
+ \value MeiteiMayekScript
+ \value MeroiticScript
+ \value MeroiticCursiveScript
+ \value MongolianScript
\value MyanmarScript
+ \value NkoScript
+ \value NewTaiLueScript
+ \value OghamScript
+ \value OlChikiScript
+ \value OldItalicScript
+ \value OldPersianScript
+ \value OldSouthArabianScript
\value OriyaScript
+ \value OrkhonScript
+ \value OsmanyaScript
+ \value PhagsPaScript
+ \value PhoenicianScript
+ \value PollardPhoneticScript
+ \value RejangScript
+ \value RunicScript
+ \value SamaritanScript
+ \value SaurashtraScript
+ \value SharadaScript
+ \value ShavianScript
+ \value SimplifiedHanScript same as SimplifiedChineseScript
+ \value SimplifiedChineseScript same as SimplifiedHanScript
+ \value SinhalaScript
+ \value SoraSompengScript
+ \value CuneiformScript
+ \value SundaneseScript
+ \value SylotiNagriScript
+ \value SyriacScript
+ \value TagalogScript
+ \value TagbanwaScript
+ \value TaiLeScript
+ \value TaiVietScript
+ \value TakriScript
\value TamilScript
\value TeluguScript
\value ThaanaScript
\value ThaiScript
\value TibetanScript
- \value SinhalaScript
- \value SyriacScript
- \value YiScript
+ \value TifinaghScript
+ \value TraditionalHanScript same as TraditionalChineseScript
+ \value TraditionalChineseScript same as TraditionalHanScript
+ \value UgariticScript
\value VaiScript
+ \value YiScript
\omitvalue LastScript
\sa script(), scriptToString(), languageToString()
diff --git a/src/corelib/tools/qlocale_blackberry.cpp b/src/corelib/tools/qlocale_blackberry.cpp
new file mode 100644
index 0000000000..1db7b7d546
--- /dev/null
+++ b/src/corelib/tools/qlocale_blackberry.cpp
@@ -0,0 +1,315 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qlocale_blackberry.h"
+#include "qlocale_p.h"
+
+#include "qdatetime.h"
+
+#include "qcoreapplication.h"
+#include "private/qcore_unix_p.h"
+
+#include <errno.h>
+#include <sys/pps.h>
+#include <unistd.h>
+
+QT_BEGIN_NAMESPACE
+
+#ifndef QT_NO_SYSTEMLOCALE
+
+static const char ppsUomPath[] = "/pps/services/locale/uom";
+static const char ppsRegionLocalePath[] = "/pps/services/locale/settings";
+static const char ppsLanguageLocalePath[] = "/pps/services/confstr/_CS_LOCALE";
+static const char ppsHourFormatPath[] = "/pps/system/settings";
+
+static const size_t ppsBufferSize = 256;
+
+QBBSystemLocaleData::QBBSystemLocaleData()
+ : languageNotifier(0)
+ , regionNotifier(0)
+ , measurementNotifier(0)
+ , hourNotifier(0)
+{
+ if ((measurementFd = qt_safe_open(ppsUomPath, O_RDONLY)) == -1)
+ qWarning("Failed to open uom pps, errno=%d", errno);
+
+ if ((regionFd = qt_safe_open(ppsRegionLocalePath, O_RDONLY)) == -1)
+ qWarning("Failed to open region pps, errno=%d", errno);
+
+ if ((languageFd = qt_safe_open(ppsLanguageLocalePath, O_RDONLY)) == -1)
+ qWarning("Failed to open language pps, errno=%d", errno);
+
+ if ((hourFd = qt_safe_open(ppsHourFormatPath, O_RDONLY)) == -1)
+ qWarning("Failed to open hour format pps, errno=%d", errno);
+
+ // we cannot call this directly, because by the time this constructor is
+ // called, the event dispatcher has not yet been created, causing the
+ // subsequent call to QSocketNotifier constructor to fail.
+ QMetaObject::invokeMethod(this, "installSocketNotifiers", Qt::QueuedConnection);
+
+ readLanguageLocale();
+ readRegionLocale();
+ readMeasurementSystem();
+ readHourFormat();
+}
+
+QBBSystemLocaleData::~QBBSystemLocaleData()
+{
+ if (measurementFd != -1)
+ qt_safe_close(measurementFd);
+
+ if (languageFd != -1)
+ qt_safe_close(languageFd);
+
+ if (regionFd != -1)
+ qt_safe_close(regionFd);
+
+ if (hourFd != -1)
+ qt_safe_close(hourFd);
+}
+
+uint QBBSystemLocaleData::measurementSystem()
+{
+ return m_measurementSystem;
+}
+
+QVariant QBBSystemLocaleData::timeFormat(QLocale::FormatType formatType)
+{
+ return getCorrectFormat(regionLocale().timeFormat(formatType), formatType);
+}
+
+QVariant QBBSystemLocaleData::dateTimeFormat(QLocale::FormatType formatType)
+{
+ return getCorrectFormat(regionLocale().dateTimeFormat(formatType), formatType);
+}
+
+QLocale QBBSystemLocaleData::languageLocale()
+{
+ if (!lc_language.isEmpty())
+ return QLocale(QLatin1String(lc_language));
+
+ return QLocale::c();
+}
+
+QLocale QBBSystemLocaleData::regionLocale()
+{
+ if (!lc_region.isEmpty())
+ return QLocale(QLatin1String(lc_region));
+
+ return QLocale::c();
+}
+
+void QBBSystemLocaleData::installSocketNotifiers()
+{
+ Q_ASSERT(!languageNotifier || !regionNotifier || !measurementNotifier || !hourNotifier);
+ Q_ASSERT(QCoreApplication::instance());
+
+ languageNotifier = new QSocketNotifier(languageFd, QSocketNotifier::Read, this);
+ QObject::connect(languageNotifier, SIGNAL(activated(int)), this, SLOT(readLanguageLocale()));
+
+ regionNotifier = new QSocketNotifier(regionFd, QSocketNotifier::Read, this);
+ QObject::connect(regionNotifier, SIGNAL(activated(int)), this, SLOT(readRegionLocale()));
+
+ measurementNotifier = new QSocketNotifier(measurementFd, QSocketNotifier::Read, this);
+ QObject::connect(measurementNotifier, SIGNAL(activated(int)), this, SLOT(readMeasurementSystem()));
+
+ hourNotifier = new QSocketNotifier(hourFd, QSocketNotifier::Read, this);
+ QObject::connect(hourNotifier, SIGNAL(activated(int)), this, SLOT(readHourFormat()));
+}
+
+void QBBSystemLocaleData::readLanguageLocale()
+{
+ lc_language = readPpsValue("_CS_LOCALE", languageFd);
+}
+
+void QBBSystemLocaleData::readRegionLocale()
+{
+ lc_region = readPpsValue("region", regionFd);
+}
+
+void QBBSystemLocaleData::readMeasurementSystem()
+{
+ QByteArray measurement = readPpsValue("uom", measurementFd);
+ m_measurementSystem = (qstrcmp(measurement, "imperial") == 0) ? QLocale::ImperialSystem : QLocale::MetricSystem;
+}
+
+void QBBSystemLocaleData::readHourFormat()
+{
+ QByteArray hourFormat = readPpsValue("hourFormat", hourFd);
+ is24HourFormat = (qstrcmp(hourFormat, "24") == 0);
+}
+
+QByteArray QBBSystemLocaleData::readPpsValue(const char *ppsObject, int ppsFd)
+{
+ QByteArray result;
+ if (!ppsObject || ppsFd == -1)
+ return result;
+
+ char buffer[ppsBufferSize];
+
+ int bytes = qt_safe_read(ppsFd, buffer, ppsBufferSize - 1);
+ if (bytes == -1) {
+ qWarning("Failed to read Locale pps, errno=%d", errno);
+ return result;
+ }
+ // ensure data is null terminated
+ buffer[bytes] = '\0';
+
+ pps_decoder_t ppsDecoder;
+ pps_decoder_initialize(&ppsDecoder, 0);
+ if (pps_decoder_parse_pps_str(&ppsDecoder, buffer) == PPS_DECODER_OK) {
+ pps_decoder_push(&ppsDecoder, 0);
+ const char *ppsBuff;
+ if (pps_decoder_get_string(&ppsDecoder, ppsObject, &ppsBuff) == PPS_DECODER_OK) {
+ result = ppsBuff;
+ } else {
+ int val;
+ if (pps_decoder_get_int(&ppsDecoder, ppsObject, &val) == PPS_DECODER_OK)
+ result = QByteArray::number(val);
+ }
+ }
+
+ pps_decoder_cleanup(&ppsDecoder);
+
+ return result;
+}
+
+QString QBBSystemLocaleData::getCorrectFormat(const QString &baseFormat, QLocale::FormatType formatType)
+{
+ QString format = baseFormat;
+ if (is24HourFormat) {
+ if (format.contains(QStringLiteral("AP"), Qt::CaseInsensitive)) {
+ format.replace(QStringLiteral("AP"), QStringLiteral(""), Qt::CaseInsensitive);
+ format.replace(QStringLiteral("h"), QStringLiteral("H"), Qt::CaseSensitive);
+ }
+
+ } else {
+
+ if (!format.contains(QStringLiteral("AP"), Qt::CaseInsensitive)) {
+ format.contains(QStringLiteral("HH"), Qt::CaseSensitive) ?
+ format.replace(QStringLiteral("HH"), QStringLiteral("hh"), Qt::CaseSensitive) :
+ format.replace(QStringLiteral("H"), QStringLiteral("h"), Qt::CaseSensitive);
+
+ formatType == QLocale::LongFormat ? format.append(QStringLiteral(" AP t")) : format.append(QStringLiteral(" AP"));
+ }
+ }
+
+ return format;
+}
+
+Q_GLOBAL_STATIC(QBBSystemLocaleData, bbSysLocaleData)
+
+QLocale QSystemLocale::fallbackUiLocale() const
+{
+ return bbSysLocaleData()->languageLocale();
+}
+
+QVariant QSystemLocale::query(QueryType type, QVariant in) const
+{
+ QBBSystemLocaleData *d = bbSysLocaleData();
+
+ QReadLocker locker(&d->lock);
+
+ const QLocale &lc_language = d->languageLocale();
+ const QLocale &lc_region = d->regionLocale();
+
+ switch (type) {
+ case DecimalPoint:
+ return lc_region.decimalPoint();
+ case GroupSeparator:
+ return lc_region.groupSeparator();
+ case NegativeSign:
+ return lc_region.negativeSign();
+ case PositiveSign:
+ return lc_region.positiveSign();
+ case DateFormatLong:
+ return lc_region.dateFormat(QLocale::LongFormat);
+ case DateFormatShort:
+ return lc_region.dateFormat(QLocale::ShortFormat);
+ case TimeFormatLong:
+ return d->timeFormat(QLocale::LongFormat);
+ case TimeFormatShort:
+ return d->timeFormat(QLocale::ShortFormat);
+ case DateTimeFormatLong:
+ return d->dateTimeFormat(QLocale::LongFormat);
+ case DateTimeFormatShort:
+ return d->dateTimeFormat(QLocale::ShortFormat);
+ case DayNameLong:
+ return lc_language.dayName(in.toInt(), QLocale::LongFormat);
+ case DayNameShort:
+ return lc_language.dayName(in.toInt(), QLocale::ShortFormat);
+ case MonthNameLong:
+ return lc_language.monthName(in.toInt(), QLocale::LongFormat);
+ case MonthNameShort:
+ return lc_language.monthName(in.toInt(), QLocale::ShortFormat);
+ case DateToStringLong:
+ return lc_region.toString(in.toDate(), QLocale::LongFormat);
+ case DateToStringShort:
+ return lc_region.toString(in.toDate(), QLocale::ShortFormat);
+ case TimeToStringLong:
+ return lc_region.toString(in.toTime(), QLocale::LongFormat);
+ case TimeToStringShort:
+ return lc_region.toString(in.toTime(), QLocale::ShortFormat);
+ case DateTimeToStringShort:
+ return lc_region.toString(in.toDateTime(), d->dateTimeFormat(QLocale::ShortFormat).toString());
+ case DateTimeToStringLong:
+ return lc_region.toString(in.toDateTime(), d->dateTimeFormat(QLocale::LongFormat).toString());
+ case MeasurementSystem:
+ return d->measurementSystem();
+ case ZeroDigit:
+ return lc_region.zeroDigit();
+ case CountryId:
+ return lc_region.country();
+ case LanguageId:
+ return lc_language.language();
+ case AMText:
+ return lc_language.amText();
+ case PMText:
+ return lc_language.pmText();
+ default:
+ break;
+ }
+ return QVariant();
+}
+
+#endif
+
+QT_END_NAMESPACE
diff --git a/src/corelib/tools/qlocale_blackberry.h b/src/corelib/tools/qlocale_blackberry.h
new file mode 100644
index 0000000000..cc186f6c0f
--- /dev/null
+++ b/src/corelib/tools/qlocale_blackberry.h
@@ -0,0 +1,99 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QLOCALE_BLACKBERRY_H
+#define QLOCALE_BLACKBERRY_H
+
+#include <QtCore/qsocketnotifier.h>
+#include <QtCore/qreadwritelock.h>
+#include <QtCore/qlocale.h>
+
+QT_BEGIN_NAMESPACE
+
+#ifndef QT_NO_SYSTEMLOCALE
+
+class QBBSystemLocaleData : public QObject
+{
+ Q_OBJECT
+
+public:
+ QBBSystemLocaleData();
+ virtual ~QBBSystemLocaleData();
+ uint measurementSystem();
+ QVariant timeFormat(QLocale::FormatType);
+ QVariant dateTimeFormat(QLocale::FormatType);
+ QLocale languageLocale();
+ QLocale regionLocale();
+
+ QReadWriteLock lock;
+
+public Q_SLOTS:
+ void installSocketNotifiers();
+ void readLanguageLocale();
+ void readRegionLocale();
+ void readMeasurementSystem();
+ void readHourFormat();
+
+private:
+ QByteArray readPpsValue(const char *ppsObject, int ppsFd);
+ QString getCorrectFormat(const QString &baseFormat, QLocale::FormatType typeFormat);
+
+ QByteArray lc_language;
+ QByteArray lc_region;
+ uint m_measurementSystem;
+ bool is24HourFormat;
+
+ QSocketNotifier *languageNotifier;
+ QSocketNotifier *regionNotifier;
+ QSocketNotifier *measurementNotifier;
+ QSocketNotifier *hourNotifier;
+
+ int languageFd;
+ int regionFd;
+ int measurementFd;
+ int hourFd;
+};
+#endif // QT_NO_SYSTEMLOCALE
+
+QT_END_NAMESPACE
+
+#endif // QLOCALE_BLACKBERRY_H
+
diff --git a/src/corelib/tools/qlocale_data_p.h b/src/corelib/tools/qlocale_data_p.h
index c7e9e83dbd..6642f824ea 100644
--- a/src/corelib/tools/qlocale_data_p.h
+++ b/src/corelib/tools/qlocale_data_p.h
@@ -77,8 +77,8 @@ static const int ImperialMeasurementSystemsCount =
// GENERATED PART STARTS HERE
/*
- This part of the file was generated on 2012-11-23 from the
- Common Locale Data Repository v22.1
+ This part of the file was generated on 2013-03-16 from the
+ Common Locale Data Repository v23
http://www.unicode.org/cldr/
@@ -101,34 +101,45 @@ static const QLocaleId likely_subtags[] = {
{ 216, 0, 0 }, { 216, 2, 178 }, // av -> av_Cyrl_RU
{ 11, 0, 0 }, { 11, 7, 26 }, // ay -> ay_Latn_BO
{ 12, 0, 0 }, { 12, 7, 15 }, // az -> az_Latn_AZ
- { 12, 1, 0 }, { 12, 1, 102 }, // az_Arab -> az_Arab_IR
{ 12, 0, 102 }, { 12, 1, 102 }, // az_IR -> az_Arab_IR
+ { 12, 1, 0 }, { 12, 1, 102 }, // az_Arab -> az_Arab_IR
{ 13, 0, 0 }, { 13, 2, 178 }, // ba -> ba_Cyrl_RU
+ { 266, 0, 0 }, { 266, 7, 101 }, // ban -> ban_Latn_ID
{ 238, 0, 0 }, { 238, 7, 37 }, // bas -> bas_Latn_CM
+ { 267, 0, 0 }, { 267, 38, 37 }, // bax -> bax_Bamu_CM
+ { 268, 0, 0 }, { 268, 7, 101 }, // bbc -> bbc_Latn_ID
{ 22, 0, 0 }, { 22, 2, 20 }, // be -> be_Cyrl_BY
{ 195, 0, 0 }, { 195, 7, 239 }, // bem -> bem_Latn_ZM
{ 186, 0, 0 }, { 186, 7, 210 }, // bez -> bez_Latn_TZ
{ 20, 0, 0 }, { 20, 2, 33 }, // bg -> bg_Cyrl_BG
{ 18, 0, 0 }, { 18, 7, 229 }, // bi -> bi_Latn_VU
+ { 270, 0, 0 }, { 270, 7, 170 }, // bku -> bku_Latn_PH
{ 188, 0, 0 }, { 188, 7, 132 }, // bm -> bm_Latn_ML
{ 15, 0, 0 }, { 15, 11, 18 }, // bn -> bn_Beng_BD
{ 121, 0, 0 }, { 121, 31, 44 }, // bo -> bo_Tibt_CN
{ 19, 0, 0 }, { 19, 7, 74 }, // br -> br_Latn_FR
{ 215, 0, 0 }, { 215, 13, 100 }, // brx -> brx_Deva_IN
{ 142, 0, 0 }, { 142, 7, 27 }, // bs -> bs_Latn_BA
+ { 269, 0, 0 }, { 269, 7, 101 }, // bug -> bug_Latn_ID
{ 152, 0, 0 }, { 152, 14, 67 }, // byn -> byn_Ethi_ER
{ 24, 0, 0 }, { 24, 7, 197 }, // ca -> ca_Latn_ES
{ 156, 0, 0 }, { 156, 7, 157 }, // cch -> cch_Latn_NG
+ { 272, 0, 0 }, { 272, 11, 100 }, // ccp -> ccp_Beng_IN
{ 218, 0, 0 }, { 218, 2, 178 }, // ce -> ce_Cyrl_RU
{ 211, 0, 0 }, { 211, 7, 221 }, // cgg -> cgg_Latn_UG
{ 217, 0, 0 }, { 217, 7, 89 }, // ch -> ch_Latn_GU
{ 190, 0, 0 }, { 190, 12, 225 }, // chr -> chr_Cher_US
+ { 276, 0, 0 }, { 276, 47, 232 }, // cjm -> cjm_Cham_VN
+ { 26, 0, 0 }, { 26, 7, 74 }, // co -> co_Latn_FR
+ { 221, 0, 0 }, { 221, 44, 38 }, // cr -> cr_Cans_CA
{ 28, 0, 0 }, { 28, 7, 57 }, // cs -> cs_Latn_CZ
+ { 220, 0, 0 }, { 220, 2, 178 }, // cv -> cv_Cyrl_RU
{ 134, 0, 0 }, { 134, 7, 224 }, // cy -> cy_Latn_GB
{ 29, 0, 0 }, { 29, 7, 58 }, // da -> da_Latn_DK
{ 176, 0, 0 }, { 176, 7, 111 }, // dav -> dav_Latn_KE
{ 42, 0, 0 }, { 42, 7, 82 }, // de -> de_Latn_DE
{ 239, 0, 0 }, { 239, 7, 156 }, // dje -> dje_Latn_NE
+ { 275, 0, 0 }, { 275, 1, 100 }, // doi -> doi_Arab_IN
{ 240, 0, 0 }, { 240, 7, 37 }, // dua -> dua_Latn_CM
{ 143, 0, 0 }, { 143, 29, 131 }, // dv -> dv_Thaa_MV
{ 241, 0, 0 }, { 241, 7, 187 }, // dyo -> dyo_Latn_SN
@@ -137,6 +148,7 @@ static const QLocaleId likely_subtags[] = {
{ 161, 0, 0 }, { 161, 7, 83 }, // ee -> ee_Latn_GH
{ 43, 0, 0 }, { 43, 16, 85 }, // el -> el_Grek_GR
{ 31, 0, 0 }, { 31, 7, 225 }, // en -> en_Latn_US
+ { 32, 7, 0 }, { 32, 7, 184 }, // eo_Latn -> eo_Latn_SM
{ 111, 0, 0 }, { 111, 7, 197 }, // es -> es_Latn_ES
{ 33, 0, 0 }, { 33, 7, 68 }, // et -> et_Latn_EE
{ 14, 0, 0 }, { 14, 7, 197 }, // eu -> eu_Latn_ES
@@ -153,6 +165,7 @@ static const QLocaleId likely_subtags[] = {
{ 57, 0, 0 }, { 57, 7, 104 }, // ga -> ga_Latn_IE
{ 148, 0, 0 }, { 148, 7, 83 }, // gaa -> gaa_Latn_GH
{ 39, 0, 0 }, { 39, 7, 224 }, // gd -> gd_Latn_GB
+ { 153, 0, 0 }, { 153, 14, 69 }, // gez -> gez_Ethi_ET
{ 40, 0, 0 }, { 40, 7, 197 }, // gl -> gl_Latn_ES
{ 45, 0, 0 }, { 45, 7, 168 }, // gn -> gn_Latn_PY
{ 167, 0, 0 }, { 167, 7, 206 }, // gsw -> gsw_Latn_CH
@@ -161,19 +174,27 @@ static const QLocaleId likely_subtags[] = {
{ 144, 0, 0 }, { 144, 7, 224 }, // gv -> gv_Latn_GB
{ 144, 7, 0 }, { 144, 7, 251 }, // gv_Latn -> gv_Latn_IM
{ 47, 0, 0 }, { 47, 7, 157 }, // ha -> ha_Latn_NG
+ { 47, 0, 37 }, { 47, 1, 37 }, // ha_CM -> ha_Arab_CM
+ { 47, 0, 201 }, { 47, 1, 201 }, // ha_SD -> ha_Arab_SD
{ 163, 0, 0 }, { 163, 7, 225 }, // haw -> haw_Latn_US
{ 48, 0, 0 }, { 48, 18, 105 }, // he -> he_Hebr_IL
{ 49, 0, 0 }, { 49, 13, 100 }, // hi -> hi_Deva_IN
+ { 280, 0, 0 }, { 280, 7, 170 }, // hnn -> hnn_Latn_PH
{ 224, 0, 0 }, { 224, 7, 167 }, // ho -> ho_Latn_PG
{ 27, 0, 0 }, { 27, 7, 54 }, // hr -> hr_Latn_HR
{ 222, 0, 0 }, { 222, 7, 94 }, // ht -> ht_Latn_HT
{ 50, 0, 0 }, { 50, 7, 98 }, // hu -> hu_Latn_HU
{ 9, 0, 0 }, { 9, 10, 11 }, // hy -> hy_Armn_AM
+ { 53, 0, 0 }, { 53, 7, 74 }, // ia -> ia_Latn_FR
+ { 53, 7, 0 }, { 53, 7, 205 }, // ia_Latn -> ia_Latn_SE
{ 52, 0, 0 }, { 52, 7, 101 }, // id -> id_Latn_ID
{ 149, 0, 0 }, { 149, 7, 157 }, // ig -> ig_Latn_NG
{ 168, 0, 0 }, { 168, 34, 44 }, // ii -> ii_Yiii_CN
+ { 56, 0, 0 }, { 56, 7, 225 }, // ik -> ik_Latn_US
+ { 281, 0, 0 }, { 281, 2, 178 }, // inh -> inh_Cyrl_RU
{ 51, 0, 0 }, { 51, 7, 99 }, // is -> is_Latn_IS
{ 58, 0, 0 }, { 58, 7, 106 }, // it -> it_Latn_IT
+ { 55, 0, 0 }, { 55, 44, 38 }, // iu -> iu_Cans_CA
{ 59, 0, 0 }, { 59, 19, 108 }, // ja -> ja_Jpan_JP
{ 257, 0, 0 }, { 257, 7, 37 }, // jgo -> jgo_Latn_CM
{ 200, 0, 0 }, { 200, 7, 210 }, // jmc -> jmc_Latn_TZ
@@ -185,11 +206,18 @@ static const QLocaleId likely_subtags[] = {
{ 164, 0, 0 }, { 164, 7, 157 }, // kcg -> kcg_Latn_NG
{ 192, 0, 0 }, { 192, 7, 210 }, // kde -> kde_Latn_TZ
{ 196, 0, 0 }, { 196, 7, 39 }, // kea -> kea_Latn_CV
+ { 154, 0, 0 }, { 154, 7, 53 }, // kfo -> kfo_Latn_CI
{ 227, 0, 0 }, { 227, 7, 49 }, // kg -> kg_Latn_CD
+ { 286, 0, 0 }, { 286, 76, 44 }, // khb -> khb_Talu_CN
{ 208, 0, 0 }, { 208, 7, 132 }, // khq -> khq_Latn_ML
{ 178, 0, 0 }, { 178, 7, 111 }, // ki -> ki_Latn_KE
{ 228, 0, 0 }, { 228, 7, 148 }, // kj -> kj_Latn_NA
{ 63, 0, 0 }, { 63, 2, 110 }, // kk -> kk_Cyrl_KZ
+ { 63, 0, 1 }, { 63, 1, 1 }, // kk_AF -> kk_Arab_AF
+ { 63, 0, 44 }, { 63, 1, 44 }, // kk_CN -> kk_Arab_CN
+ { 63, 0, 102 }, { 63, 1, 102 }, // kk_IR -> kk_Arab_IR
+ { 63, 0, 143 }, { 63, 1, 143 }, // kk_MN -> kk_Arab_MN
+ { 63, 1, 0 }, { 63, 1, 44 }, // kk_Arab -> kk_Arab_CN
{ 258, 0, 0 }, { 258, 7, 37 }, // kkj -> kkj_Latn_CM
{ 44, 0, 0 }, { 44, 7, 86 }, // kl -> kl_Latn_GL
{ 198, 0, 0 }, { 198, 7, 111 }, // kln -> kln_Latn_KE
@@ -203,15 +231,29 @@ static const QLocaleId likely_subtags[] = {
{ 243, 0, 0 }, { 243, 7, 37 }, // ksf -> ksf_Latn_CM
{ 201, 0, 0 }, { 201, 7, 82 }, // ksh -> ksh_Latn_DE
{ 67, 0, 0 }, { 67, 7, 217 }, // ku -> ku_Latn_TR
- { 67, 1, 0 }, { 67, 1, 103 }, // ku_Arab -> ku_Arab_IQ
+ { 67, 0, 11 }, { 67, 1, 11 }, // ku_AM -> ku_Arab_AM
+ { 67, 0, 15 }, { 67, 1, 15 }, // ku_AZ -> ku_Arab_AZ
+ { 67, 0, 82 }, { 67, 1, 82 }, // ku_DE -> ku_Arab_DE
+ { 67, 0, 81 }, { 67, 1, 81 }, // ku_GE -> ku_Arab_GE
{ 67, 0, 103 }, { 67, 1, 103 }, // ku_IQ -> ku_Arab_IQ
+ { 67, 0, 119 }, { 67, 1, 119 }, // ku_LB -> ku_Arab_LB
+ { 67, 0, 218 }, { 67, 1, 218 }, // ku_TM -> ku_Arab_TM
+ { 67, 1, 0 }, { 67, 1, 103 }, // ku_Arab -> ku_Arab_IQ
{ 226, 0, 0 }, { 226, 2, 178 }, // kv -> kv_Cyrl_RU
{ 145, 0, 0 }, { 145, 7, 224 }, // kw -> kw_Latn_GB
{ 65, 0, 0 }, { 65, 2, 116 }, // ky -> ky_Cyrl_KG
+ { 65, 0, 44 }, { 65, 1, 44 }, // ky_CN -> ky_Arab_CN
+ { 65, 0, 217 }, { 65, 7, 217 }, // ky_TR -> ky_Latn_TR
+ { 65, 1, 0 }, { 65, 1, 44 }, // ky_Arab -> ky_Arab_CN
+ { 65, 7, 0 }, { 65, 7, 217 }, // ky_Latn -> ky_Latn_TR
{ 70, 0, 0 }, { 70, 7, 230 }, // la -> la_Latn_VA
{ 193, 0, 0 }, { 193, 7, 210 }, // lag -> lag_Latn_TZ
{ 231, 0, 0 }, { 231, 7, 125 }, // lb -> lb_Latn_LU
+ { 283, 0, 0 }, { 283, 66, 100 }, // lep -> lep_Lepc_IN
{ 194, 0, 0 }, { 194, 7, 221 }, // lg -> lg_Latn_UG
+ { 229, 0, 0 }, { 229, 7, 151 }, // li -> li_Latn_NL
+ { 284, 0, 0 }, { 284, 13, 150 }, // lif -> lif_Deva_NP
+ { 285, 0, 0 }, { 285, 51, 44 }, // lis -> lis_Lisu_CN
{ 72, 0, 0 }, { 72, 7, 49 }, // ln -> ln_Latn_CD
{ 69, 0, 0 }, { 69, 23, 117 }, // lo -> lo_Laoo_LA
{ 73, 0, 0 }, { 73, 7, 124 }, // lt -> lt_Latn_LT
@@ -219,6 +261,7 @@ static const QLocaleId likely_subtags[] = {
{ 210, 0, 0 }, { 210, 7, 111 }, // luo -> luo_Latn_KE
{ 204, 0, 0 }, { 204, 7, 111 }, // luy -> luy_Latn_KE
{ 71, 0, 0 }, { 71, 7, 118 }, // lv -> lv_Latn_LV
+ { 289, 0, 0 }, { 289, 7, 91 }, // man -> man_Latn_GN
{ 202, 0, 0 }, { 202, 7, 111 }, // mas -> mas_Latn_KE
{ 197, 0, 0 }, { 197, 7, 111 }, // mer -> mer_Latn_KE
{ 191, 0, 0 }, { 191, 7, 137 }, // mfe -> mfe_Latn_MU
@@ -232,8 +275,12 @@ static const QLocaleId likely_subtags[] = {
{ 82, 0, 0 }, { 82, 2, 143 }, // mn -> mn_Cyrl_MN
{ 82, 0, 44 }, { 82, 8, 44 }, // mn_CN -> mn_Mong_CN
{ 82, 8, 0 }, { 82, 8, 44 }, // mn_Mong -> mn_Mong_CN
+ { 290, 0, 0 }, { 290, 11, 100 }, // mni -> mni_Beng_IN
{ 80, 0, 0 }, { 80, 13, 100 }, // mr -> mr_Deva_IN
{ 76, 0, 0 }, { 76, 7, 130 }, // ms -> ms_Latn_MY
+ { 76, 0, 46 }, { 76, 1, 46 }, // ms_CC -> ms_Arab_CC
+ { 76, 0, 101 }, { 76, 1, 101 }, // ms_ID -> ms_Arab_ID
+ { 76, 1, 0 }, { 76, 1, 101 }, // ms_Arab -> ms_Arab_ID
{ 78, 0, 0 }, { 78, 7, 133 }, // mt -> mt_Latn_MT
{ 245, 0, 0 }, { 245, 7, 37 }, // mua -> mua_Latn_CM
{ 21, 0, 0 }, { 21, 25, 147 }, // my -> my_Mymr_MM
@@ -243,13 +290,16 @@ static const QLocaleId likely_subtags[] = {
{ 181, 0, 0 }, { 181, 7, 240 }, // nd -> nd_Latn_ZW
{ 170, 0, 0 }, { 170, 7, 82 }, // nds -> nds_Latn_DE
{ 84, 0, 0 }, { 84, 13, 150 }, // ne -> ne_Deva_NP
+ { 233, 0, 0 }, { 233, 7, 148 }, // ng -> ng_Latn_NA
{ 30, 0, 0 }, { 30, 7, 151 }, // nl -> nl_Latn_NL
{ 246, 0, 0 }, { 246, 7, 37 }, // nmg -> nmg_Latn_CM
{ 141, 0, 0 }, { 141, 7, 161 }, // nn -> nn_Latn_NO
{ 260, 0, 0 }, { 260, 7, 37 }, // nnh -> nnh_Latn_CM
+ { 292, 0, 0 }, { 292, 65, 211 }, // nod -> nod_Lana_TH
{ 171, 0, 0 }, { 171, 7, 195 }, // nr -> nr_Latn_ZA
{ 172, 0, 0 }, { 172, 7, 195 }, // nso -> nso_Latn_ZA
{ 247, 0, 0 }, { 247, 7, 201 }, // nus -> nus_Latn_SD
+ { 232, 0, 0 }, { 232, 7, 225 }, // nv -> nv_Latn_US
{ 165, 0, 0 }, { 165, 7, 129 }, // ny -> ny_Latn_MW
{ 185, 0, 0 }, { 185, 7, 221 }, // nyn -> nyn_Latn_UG
{ 86, 0, 0 }, { 86, 7, 74 }, // oc -> oc_Latn_FR
@@ -257,12 +307,13 @@ static const QLocaleId likely_subtags[] = {
{ 87, 0, 0 }, { 87, 26, 100 }, // or -> or_Orya_IN
{ 101, 0, 0 }, { 101, 2, 81 }, // os -> os_Cyrl_GE
{ 92, 0, 0 }, { 92, 4, 100 }, // pa -> pa_Guru_IN
- { 92, 1, 0 }, { 92, 1, 163 }, // pa_Arab -> pa_Arab_PK
{ 92, 0, 163 }, { 92, 1, 163 }, // pa_PK -> pa_Arab_PK
+ { 92, 1, 0 }, { 92, 1, 163 }, // pa_Arab -> pa_Arab_PK
{ 90, 0, 0 }, { 90, 7, 172 }, // pl -> pl_Latn_PL
{ 88, 0, 0 }, { 88, 1, 1 }, // ps -> ps_Arab_AF
{ 91, 0, 0 }, { 91, 7, 30 }, // pt -> pt_Latn_BR
{ 93, 0, 0 }, { 93, 7, 169 }, // qu -> qu_Latn_PE
+ { 301, 0, 0 }, { 301, 7, 101 }, // rej -> rej_Latn_ID
{ 94, 0, 0 }, { 94, 7, 206 }, // rm -> rm_Latn_CH
{ 68, 0, 0 }, { 68, 7, 35 }, // rn -> rn_Latn_BI
{ 95, 0, 0 }, { 95, 7, 177 }, // ro -> ro_Latn_RO
@@ -273,8 +324,11 @@ static const QLocaleId likely_subtags[] = {
{ 99, 0, 0 }, { 99, 13, 100 }, // sa -> sa_Deva_IN
{ 248, 0, 0 }, { 248, 2, 178 }, // sah -> sah_Cyrl_RU
{ 179, 0, 0 }, { 179, 7, 111 }, // saq -> saq_Latn_KE
+ { 304, 0, 0 }, { 304, 7, 100 }, // sat -> sat_Latn_IN
+ { 305, 0, 0 }, { 305, 90, 100 }, // saz -> saz_Saur_IN
{ 249, 0, 0 }, { 249, 7, 210 }, // sbp -> sbp_Latn_TZ
{ 105, 0, 0 }, { 105, 1, 100 }, // sd -> sd_Arab_IN
+ { 105, 13, 0 }, { 105, 13, 100 }, // sd_Deva -> sd_Deva_IN
{ 173, 0, 0 }, { 173, 7, 161 }, // se -> se_Latn_NO
{ 180, 0, 0 }, { 180, 7, 146 }, // seh -> seh_Latn_MZ
{ 213, 0, 0 }, { 213, 7, 132 }, // ses -> ses_Latn_ML
@@ -291,6 +345,9 @@ static const QLocaleId likely_subtags[] = {
{ 6, 0, 0 }, { 6, 7, 2 }, // sq -> sq_Latn_AL
{ 100, 0, 0 }, { 100, 2, 243 }, // sr -> sr_Cyrl_RS
{ 100, 0, 242 }, { 100, 7, 242 }, // sr_ME -> sr_Latn_ME
+ { 100, 0, 177 }, { 100, 7, 177 }, // sr_RO -> sr_Latn_RO
+ { 100, 0, 178 }, { 100, 7, 178 }, // sr_RU -> sr_Latn_RU
+ { 100, 0, 217 }, { 100, 7, 217 }, // sr_TR -> sr_Latn_TR
{ 107, 0, 0 }, { 107, 7, 195 }, // ss -> ss_Latn_ZA
{ 207, 0, 0 }, { 207, 7, 67 }, // ssy -> ssy_Latn_ER
{ 102, 0, 0 }, { 102, 7, 195 }, // st -> st_Latn_ZA
@@ -298,10 +355,16 @@ static const QLocaleId likely_subtags[] = {
{ 114, 0, 0 }, { 114, 7, 205 }, // sv -> sv_Latn_SE
{ 113, 0, 0 }, { 113, 7, 210 }, // sw -> sw_Latn_TZ
{ 250, 0, 0 }, { 250, 7, 49 }, // swc -> swc_Latn_CD
+ { 307, 0, 0 }, { 307, 11, 18 }, // syl -> syl_Beng_BD
+ { 151, 0, 0 }, { 151, 33, 207 }, // syr -> syr_Syrc_SY
{ 117, 0, 0 }, { 117, 27, 100 }, // ta -> ta_Taml_IN
+ { 308, 0, 0 }, { 308, 7, 170 }, // tbw -> tbw_Latn_PH
+ { 310, 0, 0 }, { 310, 99, 44 }, // tdd -> tdd_Tale_CN
{ 119, 0, 0 }, { 119, 28, 100 }, // te -> te_Telu_IN
{ 206, 0, 0 }, { 206, 7, 221 }, // teo -> teo_Latn_UG
{ 116, 0, 0 }, { 116, 2, 209 }, // tg -> tg_Cyrl_TJ
+ { 116, 0, 163 }, { 116, 1, 163 }, // tg_PK -> tg_Arab_PK
+ { 116, 1, 0 }, { 116, 1, 163 }, // tg_Arab -> tg_Arab_PK
{ 120, 0, 0 }, { 120, 30, 211 }, // th -> th_Thai_TH
{ 122, 0, 0 }, { 122, 14, 69 }, // ti -> ti_Ethi_ET
{ 157, 0, 0 }, { 157, 14, 67 }, // tig -> tig_Ethi_ER
@@ -316,25 +379,64 @@ static const QLocaleId likely_subtags[] = {
{ 127, 0, 0 }, { 127, 7, 77 }, // ty -> ty_Latn_PF
{ 212, 0, 0 }, { 212, 7, 145 }, // tzm -> tzm_Latn_MA
{ 128, 0, 0 }, { 128, 1, 44 }, // ug -> ug_Arab_CN
+ { 128, 0, 110 }, { 128, 2, 110 }, // ug_KZ -> ug_Cyrl_KZ
+ { 128, 0, 143 }, { 128, 2, 143 }, // ug_MN -> ug_Cyrl_MN
+ { 128, 2, 0 }, { 128, 2, 110 }, // ug_Cyrl -> ug_Cyrl_KZ
{ 129, 0, 0 }, { 129, 2, 222 }, // uk -> uk_Cyrl_UA
+ { 130, 0, 0 }, { 130, 1, 163 }, // ur -> ur_Arab_PK
+ { 131, 0, 0 }, { 131, 2, 228 }, // uz -> uz_Cyrl_UZ
+ { 131, 0, 1 }, { 131, 1, 1 }, // uz_AF -> uz_Arab_AF
+ { 131, 0, 218 }, { 131, 7, 218 }, // uz_TM -> uz_Latn_TM
+ { 131, 0, 217 }, { 131, 7, 217 }, // uz_TR -> uz_Latn_TR
+ { 131, 1, 0 }, { 131, 1, 1 }, // uz_Arab -> uz_Arab_AF
+ { 252, 0, 0 }, { 252, 35, 121 }, // vai -> vai_Vaii_LR
+ { 160, 0, 0 }, { 160, 7, 195 }, // ve -> ve_Latn_ZA
+ { 132, 0, 0 }, { 132, 7, 232 }, // vi -> vi_Latn_VN
+ { 187, 0, 0 }, { 187, 7, 210 }, // vun -> vun_Latn_TZ
+ { 236, 0, 0 }, { 236, 7, 21 }, // wa -> wa_Latn_BE
+ { 253, 0, 0 }, { 253, 7, 206 }, // wae -> wae_Latn_CH
+ { 162, 0, 0 }, { 162, 14, 69 }, // wal -> wal_Ethi_ET
+ { 135, 0, 0 }, { 135, 7, 187 }, // wo -> wo_Latn_SN
+ { 136, 0, 0 }, { 136, 7, 195 }, // xh -> xh_Latn_ZA
+ { 203, 0, 0 }, { 203, 7, 221 }, // xog -> xog_Latn_UG
+ { 254, 0, 0 }, { 254, 7, 37 }, // yav -> yav_Latn_CM
+ { 137, 0, 0 }, { 137, 18, 105 }, // yi -> yi_Hebr_IL
+ { 137, 18, 0 }, { 137, 18, 222 }, // yi_Hebr -> yi_Hebr_UA
+ { 138, 0, 0 }, { 138, 7, 157 }, // yo -> yo_Latn_NG
+ { 139, 0, 0 }, { 139, 7, 44 }, // za -> za_Latn_CN
+ { 25, 0, 0 }, { 25, 5, 44 }, // zh -> zh_Hans_CN
+ { 25, 0, 13 }, { 25, 6, 13 }, // zh_AU -> zh_Hant_AU
+ { 25, 0, 32 }, { 25, 6, 32 }, // zh_BN -> zh_Hant_BN
+ { 25, 0, 224 }, { 25, 6, 224 }, // zh_GB -> zh_Hant_GB
+ { 25, 0, 76 }, { 25, 6, 76 }, // zh_GF -> zh_Hant_GF
+ { 25, 0, 97 }, { 25, 6, 97 }, // zh_HK -> zh_Hant_HK
+ { 25, 0, 101 }, { 25, 6, 101 }, // zh_ID -> zh_Hant_ID
+ { 25, 0, 126 }, { 25, 6, 126 }, // zh_MO -> zh_Hant_MO
+ { 25, 0, 130 }, { 25, 6, 130 }, // zh_MY -> zh_Hant_MY
+ { 25, 0, 166 }, { 25, 6, 166 }, // zh_PA -> zh_Hant_PA
+ { 25, 0, 77 }, { 25, 6, 77 }, // zh_PF -> zh_Hant_PF
+ { 25, 0, 170 }, { 25, 6, 170 }, // zh_PH -> zh_Hant_PH
+ { 25, 0, 202 }, { 25, 6, 202 }, // zh_SR -> zh_Hant_SR
+ { 25, 0, 211 }, { 25, 6, 211 }, // zh_TH -> zh_Hant_TH
+ { 25, 0, 208 }, { 25, 6, 208 }, // zh_TW -> zh_Hant_TW
+ { 25, 0, 225 }, { 25, 6, 225 }, // zh_US -> zh_Hant_US
+ { 25, 0, 232 }, { 25, 6, 232 }, // zh_VN -> zh_Hant_VN
+ { 25, 54, 0 }, { 25, 5, 44 }, // zh_Hani -> zh_Hans_CN
+ { 25, 6, 0 }, { 25, 6, 208 }, // zh_Hant -> zh_Hant_TW
+ { 140, 0, 0 }, { 140, 7, 195 }, // zu -> zu_Latn_ZA
{ 0, 0, 5 }, { 24, 7, 5 }, // und_AD -> ca_Latn_AD
{ 0, 0, 223 }, { 8, 1, 223 }, // und_AE -> ar_Arab_AE
{ 0, 0, 1 }, { 89, 1, 1 }, // und_AF -> fa_Arab_AF
{ 0, 0, 2 }, { 6, 7, 2 }, // und_AL -> sq_Latn_AL
{ 0, 0, 11 }, { 9, 10, 11 }, // und_AM -> hy_Armn_AM
{ 0, 0, 6 }, { 91, 7, 6 }, // und_AO -> pt_Latn_AO
+ { 0, 0, 8 }, { 0, 7, 8 }, // und_AQ -> und_Latn_AQ
{ 0, 0, 10 }, { 111, 7, 10 }, // und_AR -> es_Latn_AR
{ 0, 0, 4 }, { 97, 7, 4 }, // und_AS -> sm_Latn_AS
{ 0, 0, 14 }, { 42, 7, 14 }, // und_AT -> de_Latn_AT
{ 0, 0, 12 }, { 30, 7, 12 }, // und_AW -> nl_Latn_AW
{ 0, 0, 248 }, { 114, 7, 248 }, // und_AX -> sv_Latn_AX
{ 0, 0, 15 }, { 12, 7, 15 }, // und_AZ -> az_Latn_AZ
- { 0, 1, 0 }, { 8, 1, 64 }, // und_Arab -> ar_Arab_EG
- { 0, 1, 44 }, { 128, 1, 44 }, // und_Arab_CN -> ug_Arab_CN
- { 0, 1, 100 }, { 130, 1, 100 }, // und_Arab_IN -> ur_Arab_IN
- { 0, 1, 157 }, { 47, 1, 157 }, // und_Arab_NG -> ha_Arab_NG
- { 0, 1, 163 }, { 130, 1, 163 }, // und_Arab_PK -> ur_Arab_PK
- { 0, 10, 0 }, { 9, 10, 11 }, // und_Armn -> hy_Armn_AM
{ 0, 0, 27 }, { 142, 7, 27 }, // und_BA -> bs_Latn_BA
{ 0, 0, 18 }, { 15, 11, 18 }, // und_BD -> bn_Beng_BD
{ 0, 0, 21 }, { 30, 7, 21 }, // und_BE -> nl_Latn_BE
@@ -348,8 +450,8 @@ static const QLocaleId likely_subtags[] = {
{ 0, 0, 26 }, { 111, 7, 26 }, // und_BO -> es_Latn_BO
{ 0, 0, 30 }, { 91, 7, 30 }, // und_BR -> pt_Latn_BR
{ 0, 0, 25 }, { 16, 31, 25 }, // und_BT -> dz_Tibt_BT
+ { 0, 0, 29 }, { 0, 7, 29 }, // und_BV -> und_Latn_BV
{ 0, 0, 20 }, { 22, 2, 20 }, // und_BY -> be_Cyrl_BY
- { 0, 11, 0 }, { 15, 11, 18 }, // und_Beng -> bn_Beng_BD
{ 0, 0, 49 }, { 113, 7, 49 }, // und_CD -> sw_Latn_CD
{ 0, 0, 41 }, { 37, 7, 41 }, // und_CF -> fr_Latn_CF
{ 0, 0, 50 }, { 37, 7, 50 }, // und_CG -> fr_Latn_CG
@@ -365,16 +467,11 @@ static const QLocaleId likely_subtags[] = {
{ 0, 0, 39 }, { 91, 7, 39 }, // und_CV -> pt_Latn_CV
{ 0, 0, 56 }, { 43, 16, 56 }, // und_CY -> el_Grek_CY
{ 0, 0, 57 }, { 28, 7, 57 }, // und_CZ -> cs_Latn_CZ
- { 0, 12, 0 }, { 190, 12, 225 }, // und_Cher -> chr_Cher_US
- { 0, 2, 0 }, { 96, 2, 178 }, // und_Cyrl -> ru_Cyrl_RU
- { 0, 2, 27 }, { 100, 2, 27 }, // und_Cyrl_BA -> sr_Cyrl_BA
- { 0, 2, 81 }, { 2, 2, 81 }, // und_Cyrl_GE -> ab_Cyrl_GE
{ 0, 0, 82 }, { 42, 7, 82 }, // und_DE -> de_Latn_DE
{ 0, 0, 59 }, { 4, 7, 59 }, // und_DJ -> aa_Latn_DJ
{ 0, 0, 58 }, { 29, 7, 58 }, // und_DK -> da_Latn_DK
{ 0, 0, 61 }, { 111, 7, 61 }, // und_DO -> es_Latn_DO
{ 0, 0, 3 }, { 8, 1, 3 }, // und_DZ -> ar_Arab_DZ
- { 0, 13, 0 }, { 49, 13, 100 }, // und_Deva -> hi_Deva_IN
{ 0, 0, 250 }, { 111, 7, 250 }, // und_EA -> es_Latn_EA
{ 0, 0, 63 }, { 111, 7, 63 }, // und_EC -> es_Latn_EC
{ 0, 0, 68 }, { 33, 7, 68 }, // und_EE -> et_Latn_EE
@@ -382,7 +479,7 @@ static const QLocaleId likely_subtags[] = {
{ 0, 0, 236 }, { 8, 1, 236 }, // und_EH -> ar_Arab_EH
{ 0, 0, 67 }, { 122, 14, 67 }, // und_ER -> ti_Ethi_ER
{ 0, 0, 197 }, { 111, 7, 197 }, // und_ES -> es_Latn_ES
- { 0, 14, 0 }, { 7, 14, 69 }, // und_Ethi -> am_Ethi_ET
+ { 0, 0, 69 }, { 7, 14, 69 }, // und_ET -> am_Ethi_ET
{ 0, 0, 73 }, { 36, 7, 73 }, // und_FI -> fi_Latn_FI
{ 0, 0, 71 }, { 34, 7, 71 }, // und_FO -> fo_Latn_FO
{ 0, 0, 74 }, { 37, 7, 74 }, // und_FR -> fr_Latn_FR
@@ -395,20 +492,15 @@ static const QLocaleId likely_subtags[] = {
{ 0, 0, 88 }, { 37, 7, 88 }, // und_GP -> fr_Latn_GP
{ 0, 0, 66 }, { 111, 7, 66 }, // und_GQ -> es_Latn_GQ
{ 0, 0, 85 }, { 43, 16, 85 }, // und_GR -> el_Grek_GR
+ { 0, 0, 196 }, { 0, 7, 196 }, // und_GS -> und_Latn_GS
{ 0, 0, 90 }, { 111, 7, 90 }, // und_GT -> es_Latn_GT
{ 0, 0, 92 }, { 91, 7, 92 }, // und_GW -> pt_Latn_GW
- { 0, 15, 0 }, { 41, 15, 81 }, // und_Geor -> ka_Geor_GE
- { 0, 16, 0 }, { 43, 16, 85 }, // und_Grek -> el_Grek_GR
- { 0, 17, 0 }, { 46, 17, 100 }, // und_Gujr -> gu_Gujr_IN
- { 0, 4, 0 }, { 92, 4, 100 }, // und_Guru -> pa_Guru_IN
{ 0, 0, 97 }, { 25, 6, 97 }, // und_HK -> zh_Hant_HK
+ { 0, 0, 95 }, { 0, 7, 95 }, // und_HM -> und_Latn_HM
{ 0, 0, 96 }, { 111, 7, 96 }, // und_HN -> es_Latn_HN
{ 0, 0, 54 }, { 27, 7, 54 }, // und_HR -> hr_Latn_HR
{ 0, 0, 94 }, { 222, 7, 94 }, // und_HT -> ht_Latn_HT
{ 0, 0, 98 }, { 50, 7, 98 }, // und_HU -> hu_Latn_HU
- { 0, 5, 0 }, { 25, 5, 44 }, // und_Hans -> zh_Hans_CN
- { 0, 6, 0 }, { 25, 6, 208 }, // und_Hant -> zh_Hant_TW
- { 0, 18, 0 }, { 48, 18, 105 }, // und_Hebr -> he_Hebr_IL
{ 0, 0, 238 }, { 111, 7, 238 }, // und_IC -> es_Latn_IC
{ 0, 0, 101 }, { 52, 7, 101 }, // und_ID -> id_Latn_ID
{ 0, 0, 105 }, { 48, 18, 105 }, // und_IL -> he_Hebr_IL
@@ -419,7 +511,6 @@ static const QLocaleId likely_subtags[] = {
{ 0, 0, 106 }, { 58, 7, 106 }, // und_IT -> it_Latn_IT
{ 0, 0, 109 }, { 8, 1, 109 }, // und_JO -> ar_Arab_JO
{ 0, 0, 108 }, { 59, 19, 108 }, // und_JP -> ja_Jpan_JP
- { 0, 19, 0 }, { 59, 19, 108 }, // und_Jpan -> ja_Jpan_JP
{ 0, 0, 116 }, { 65, 2, 116 }, // und_KG -> ky_Cyrl_KG
{ 0, 0, 36 }, { 23, 20, 36 }, // und_KH -> km_Khmr_KH
{ 0, 0, 48 }, { 8, 1, 48 }, // und_KM -> ar_Arab_KM
@@ -427,9 +518,6 @@ static const QLocaleId likely_subtags[] = {
{ 0, 0, 114 }, { 66, 22, 114 }, // und_KR -> ko_Kore_KR
{ 0, 0, 115 }, { 8, 1, 115 }, // und_KW -> ar_Arab_KW
{ 0, 0, 110 }, { 96, 2, 110 }, // und_KZ -> ru_Cyrl_KZ
- { 0, 20, 0 }, { 23, 20, 36 }, // und_Khmr -> km_Khmr_KH
- { 0, 21, 0 }, { 61, 21, 100 }, // und_Knda -> kn_Knda_IN
- { 0, 22, 0 }, { 66, 22, 114 }, // und_Kore -> ko_Kore_KR
{ 0, 0, 117 }, { 69, 23, 117 }, // und_LA -> lo_Laoo_LA
{ 0, 0, 119 }, { 8, 1, 119 }, // und_LB -> ar_Arab_LB
{ 0, 0, 123 }, { 42, 7, 123 }, // und_LI -> de_Latn_LI
@@ -439,17 +527,6 @@ static const QLocaleId likely_subtags[] = {
{ 0, 0, 125 }, { 37, 7, 125 }, // und_LU -> fr_Latn_LU
{ 0, 0, 118 }, { 71, 7, 118 }, // und_LV -> lv_Latn_LV
{ 0, 0, 122 }, { 8, 1, 122 }, // und_LY -> ar_Arab_LY
- { 0, 23, 0 }, { 69, 23, 117 }, // und_Laoo -> lo_Laoo_LA
- { 0, 7, 44 }, { 139, 7, 44 }, // und_Latn_CN -> za_Latn_CN
- { 0, 7, 56 }, { 125, 7, 56 }, // und_Latn_CY -> tr_Latn_CY
- { 0, 7, 3 }, { 37, 7, 3 }, // und_Latn_DZ -> fr_Latn_DZ
- { 0, 7, 67 }, { 4, 7, 67 }, // und_Latn_ER -> aa_Latn_ER
- { 0, 7, 48 }, { 37, 7, 48 }, // und_Latn_KM -> fr_Latn_KM
- { 0, 7, 145 }, { 37, 7, 145 }, // und_Latn_MA -> fr_Latn_MA
- { 0, 7, 127 }, { 6, 7, 127 }, // und_Latn_MK -> sq_Latn_MK
- { 0, 7, 136 }, { 37, 7, 136 }, // und_Latn_MR -> fr_Latn_MR
- { 0, 7, 207 }, { 37, 7, 207 }, // und_Latn_SY -> fr_Latn_SY
- { 0, 7, 216 }, { 37, 7, 216 }, // und_Latn_TN -> fr_Latn_TN
{ 0, 0, 145 }, { 8, 1, 145 }, // und_MA -> ar_Arab_MA
{ 0, 0, 142 }, { 37, 7, 142 }, // und_MC -> fr_Latn_MC
{ 0, 0, 141 }, { 95, 7, 141 }, // und_MD -> ro_Latn_MD
@@ -469,9 +546,6 @@ static const QLocaleId likely_subtags[] = {
{ 0, 0, 139 }, { 111, 7, 139 }, // und_MX -> es_Latn_MX
{ 0, 0, 130 }, { 76, 7, 130 }, // und_MY -> ms_Latn_MY
{ 0, 0, 146 }, { 91, 7, 146 }, // und_MZ -> pt_Latn_MZ
- { 0, 24, 0 }, { 77, 24, 100 }, // und_Mlym -> ml_Mlym_IN
- { 0, 8, 0 }, { 82, 8, 44 }, // und_Mong -> mn_Mong_CN
- { 0, 25, 0 }, { 21, 25, 147 }, // und_Mymr -> my_Mymr_MM
{ 0, 0, 148 }, { 228, 7, 148 }, // und_NA -> kj_Latn_NA
{ 0, 0, 153 }, { 37, 7, 153 }, // und_NC -> fr_Latn_NC
{ 0, 0, 156 }, { 47, 7, 156 }, // und_NE -> ha_Latn_NE
@@ -480,7 +554,6 @@ static const QLocaleId likely_subtags[] = {
{ 0, 0, 161 }, { 85, 7, 161 }, // und_NO -> nb_Latn_NO
{ 0, 0, 150 }, { 84, 13, 150 }, // und_NP -> ne_Deva_NP
{ 0, 0, 162 }, { 8, 1, 162 }, // und_OM -> ar_Arab_OM
- { 0, 26, 0 }, { 87, 26, 100 }, // und_Orya -> or_Orya_IN
{ 0, 0, 166 }, { 111, 7, 166 }, // und_PA -> es_Latn_PA
{ 0, 0, 169 }, { 111, 7, 169 }, // und_PE -> es_Latn_PE
{ 0, 0, 77 }, { 37, 7, 77 }, // und_PF -> fr_Latn_PF
@@ -512,8 +585,8 @@ static const QLocaleId likely_subtags[] = {
{ 0, 0, 185 }, { 91, 7, 185 }, // und_ST -> pt_Latn_ST
{ 0, 0, 65 }, { 111, 7, 65 }, // und_SV -> es_Latn_SV
{ 0, 0, 207 }, { 8, 1, 207 }, // und_SY -> ar_Arab_SY
- { 0, 32, 0 }, { 106, 32, 198 }, // und_Sinh -> si_Sinh_LK
{ 0, 0, 42 }, { 37, 7, 42 }, // und_TD -> fr_Latn_TD
+ { 0, 0, 78 }, { 37, 7, 78 }, // und_TF -> fr_Latn_TF
{ 0, 0, 212 }, { 37, 7, 212 }, // und_TG -> fr_Latn_TG
{ 0, 0, 211 }, { 120, 30, 211 }, // und_TH -> th_Thai_TH
{ 0, 0, 209 }, { 116, 2, 209 }, // und_TJ -> tg_Cyrl_TJ
@@ -524,12 +597,6 @@ static const QLocaleId likely_subtags[] = {
{ 0, 0, 217 }, { 125, 7, 217 }, // und_TR -> tr_Latn_TR
{ 0, 0, 208 }, { 25, 6, 208 }, // und_TW -> zh_Hant_TW
{ 0, 0, 210 }, { 113, 7, 210 }, // und_TZ -> sw_Latn_TZ
- { 0, 27, 0 }, { 117, 27, 100 }, // und_Taml -> ta_Taml_IN
- { 0, 28, 0 }, { 119, 28, 100 }, // und_Telu -> te_Telu_IN
- { 0, 9, 0 }, { 183, 9, 216 }, // und_Tfng -> shi_Tfng_TN
- { 0, 29, 0 }, { 143, 29, 131 }, // und_Thaa -> dv_Thaa_MV
- { 0, 30, 0 }, { 120, 30, 211 }, // und_Thai -> th_Thai_TH
- { 0, 31, 0 }, { 121, 31, 44 }, // und_Tibt -> bo_Tibt_CN
{ 0, 0, 222 }, { 129, 2, 222 }, // und_UA -> uk_Cyrl_UA
{ 0, 0, 221 }, { 113, 7, 221 }, // und_UG -> sw_Latn_UG
{ 0, 0, 227 }, { 111, 7, 227 }, // und_UY -> es_Latn_UY
@@ -538,35 +605,162 @@ static const QLocaleId likely_subtags[] = {
{ 0, 0, 231 }, { 111, 7, 231 }, // und_VE -> es_Latn_VE
{ 0, 0, 232 }, { 132, 7, 232 }, // und_VN -> vi_Latn_VN
{ 0, 0, 229 }, { 18, 7, 229 }, // und_VU -> bi_Latn_VU
- { 0, 35, 0 }, { 252, 35, 121 }, // und_Vaii -> vai_Vaii_LR
{ 0, 0, 235 }, { 37, 7, 235 }, // und_WF -> fr_Latn_WF
{ 0, 0, 183 }, { 97, 7, 183 }, // und_WS -> sm_Latn_WS
{ 0, 0, 237 }, { 8, 1, 237 }, // und_YE -> ar_Arab_YE
{ 0, 0, 138 }, { 37, 7, 138 }, // und_YT -> fr_Latn_YT
- { 0, 34, 0 }, { 168, 34, 44 }, // und_Yiii -> ii_Yiii_CN
- { 130, 0, 0 }, { 130, 1, 163 }, // ur -> ur_Arab_PK
- { 131, 0, 0 }, { 131, 2, 228 }, // uz -> uz_Cyrl_UZ
- { 131, 0, 1 }, { 131, 1, 1 }, // uz_AF -> uz_Arab_AF
- { 131, 1, 0 }, { 131, 1, 1 }, // uz_Arab -> uz_Arab_AF
- { 252, 0, 0 }, { 252, 35, 121 }, // vai -> vai_Vaii_LR
- { 160, 0, 0 }, { 160, 7, 195 }, // ve -> ve_Latn_ZA
- { 132, 0, 0 }, { 132, 7, 232 }, // vi -> vi_Latn_VN
- { 187, 0, 0 }, { 187, 7, 210 }, // vun -> vun_Latn_TZ
- { 253, 0, 0 }, { 253, 7, 206 }, // wae -> wae_Latn_CH
- { 162, 0, 0 }, { 162, 14, 69 }, // wal -> wal_Ethi_ET
- { 135, 0, 0 }, { 135, 7, 187 }, // wo -> wo_Latn_SN
- { 136, 0, 0 }, { 136, 7, 195 }, // xh -> xh_Latn_ZA
- { 203, 0, 0 }, { 203, 7, 221 }, // xog -> xog_Latn_UG
- { 254, 0, 0 }, { 254, 7, 37 }, // yav -> yav_Latn_CM
- { 137, 0, 0 }, { 137, 18, 105 }, // yi -> yi_Hebr_IL
- { 138, 0, 0 }, { 138, 7, 157 }, // yo -> yo_Latn_NG
- { 139, 0, 0 }, { 139, 7, 44 }, // za -> za_Latn_CN
- { 25, 0, 0 }, { 25, 5, 44 }, // zh -> zh_Hans_CN
- { 25, 0, 97 }, { 25, 6, 97 }, // zh_HK -> zh_Hant_HK
- { 25, 6, 0 }, { 25, 6, 208 }, // zh_Hant -> zh_Hant_TW
- { 25, 0, 126 }, { 25, 6, 126 }, // zh_MO -> zh_Hant_MO
- { 25, 0, 208 }, { 25, 6, 208 }, // zh_TW -> zh_Hant_TW
- { 140, 0, 0 }, { 140, 7, 195 } // zu -> zu_Latn_ZA
+ { 0, 1, 0 }, { 8, 1, 64 }, // und_Arab -> ar_Arab_EG
+ { 0, 1, 11 }, { 67, 1, 11 }, // und_Arab_AM -> ku_Arab_AM
+ { 0, 1, 15 }, { 67, 1, 15 }, // und_Arab_AZ -> ku_Arab_AZ
+ { 0, 1, 46 }, { 76, 1, 46 }, // und_Arab_CC -> ms_Arab_CC
+ { 0, 1, 44 }, { 128, 1, 44 }, // und_Arab_CN -> ug_Arab_CN
+ { 0, 1, 82 }, { 67, 1, 82 }, // und_Arab_DE -> ku_Arab_DE
+ { 0, 1, 224 }, { 62, 1, 224 }, // und_Arab_GB -> ks_Arab_GB
+ { 0, 1, 81 }, { 67, 1, 81 }, // und_Arab_GE -> ku_Arab_GE
+ { 0, 1, 101 }, { 76, 1, 101 }, // und_Arab_ID -> ms_Arab_ID
+ { 0, 1, 100 }, { 130, 1, 100 }, // und_Arab_IN -> ur_Arab_IN
+ { 0, 1, 143 }, { 63, 1, 143 }, // und_Arab_MN -> kk_Arab_MN
+ { 0, 1, 137 }, { 130, 1, 137 }, // und_Arab_MU -> ur_Arab_MU
+ { 0, 1, 157 }, { 47, 1, 157 }, // und_Arab_NG -> ha_Arab_NG
+ { 0, 1, 163 }, { 130, 1, 163 }, // und_Arab_PK -> ur_Arab_PK
+ { 0, 1, 209 }, { 89, 1, 209 }, // und_Arab_TJ -> fa_Arab_TJ
+ { 0, 1, 218 }, { 67, 1, 218 }, // und_Arab_TM -> ku_Arab_TM
+ { 0, 1, 217 }, { 67, 1, 217 }, // und_Arab_TR -> ku_Arab_TR
+ { 0, 57, 0 }, { 265, 57, 102 }, // und_Armi -> arc_Armi_IR
+ { 0, 10, 0 }, { 9, 10, 11 }, // und_Armn -> hy_Armn_AM
+ { 0, 36, 0 }, { 255, 36, 102 }, // und_Avst -> ae_Avst_IR
+ { 0, 37, 0 }, { 266, 37, 101 }, // und_Bali -> ban_Bali_ID
+ { 0, 38, 0 }, { 267, 38, 37 }, // und_Bamu -> bax_Bamu_CM
+ { 0, 39, 0 }, { 268, 39, 101 }, // und_Batk -> bbc_Batk_ID
+ { 0, 11, 0 }, { 15, 11, 18 }, // und_Beng -> bn_Beng_BD
+ { 0, 40, 0 }, { 25, 40, 208 }, // und_Bopo -> zh_Bopo_TW
+ { 0, 41, 0 }, { 300, 41, 100 }, // und_Brah -> pra_Brah_IN
+ { 0, 103, 0 }, { 0, 103, 74 }, // und_Brai -> und_Brai_FR
+ { 0, 42, 0 }, { 269, 42, 101 }, // und_Bugi -> bug_Bugi_ID
+ { 0, 43, 0 }, { 270, 43, 170 }, // und_Buhd -> bku_Buhd_PH
+ { 0, 46, 0 }, { 272, 46, 18 }, // und_Cakm -> ccp_Cakm_BD
+ { 0, 44, 0 }, { 221, 44, 38 }, // und_Cans -> cr_Cans_CA
+ { 0, 45, 0 }, { 271, 45, 217 }, // und_Cari -> xcr_Cari_TR
+ { 0, 47, 0 }, { 276, 47, 232 }, // und_Cham -> cjm_Cham_VN
+ { 0, 12, 0 }, { 190, 12, 225 }, // und_Cher -> chr_Cher_US
+ { 0, 48, 0 }, { 274, 48, 64 }, // und_Copt -> cop_Copt_EG
+ { 0, 49, 0 }, { 264, 49, 56 }, // und_Cprt -> grc_Cprt_CY
+ { 0, 2, 0 }, { 96, 2, 178 }, // und_Cyrl -> ru_Cyrl_RU
+ { 0, 2, 2 }, { 74, 2, 2 }, // und_Cyrl_AL -> mk_Cyrl_AL
+ { 0, 2, 27 }, { 100, 2, 27 }, // und_Cyrl_BA -> sr_Cyrl_BA
+ { 0, 2, 81 }, { 2, 2, 81 }, // und_Cyrl_GE -> ab_Cyrl_GE
+ { 0, 2, 85 }, { 74, 2, 85 }, // und_Cyrl_GR -> mk_Cyrl_GR
+ { 0, 2, 141 }, { 20, 2, 141 }, // und_Cyrl_MD -> bg_Cyrl_MD
+ { 0, 2, 172 }, { 22, 2, 172 }, // und_Cyrl_PL -> be_Cyrl_PL
+ { 0, 2, 177 }, { 20, 2, 177 }, // und_Cyrl_RO -> bg_Cyrl_RO
+ { 0, 2, 191 }, { 129, 2, 191 }, // und_Cyrl_SK -> uk_Cyrl_SK
+ { 0, 13, 0 }, { 49, 13, 100 }, // und_Deva -> hi_Deva_IN
+ { 0, 13, 25 }, { 84, 13, 25 }, // und_Deva_BT -> ne_Deva_BT
+ { 0, 50, 0 }, { 263, 50, 64 }, // und_Egyp -> egy_Egyp_EG
+ { 0, 14, 0 }, { 7, 14, 69 }, // und_Ethi -> am_Ethi_ET
+ { 0, 15, 0 }, { 41, 15, 81 }, // und_Geor -> ka_Geor_GE
+ { 0, 52, 0 }, { 219, 52, 33 }, // und_Glag -> cu_Glag_BG
+ { 0, 53, 0 }, { 279, 53, 222 }, // und_Goth -> got_Goth_UA
+ { 0, 16, 0 }, { 43, 16, 85 }, // und_Grek -> el_Grek_GR
+ { 0, 17, 0 }, { 46, 17, 100 }, // und_Gujr -> gu_Gujr_IN
+ { 0, 4, 0 }, { 92, 4, 100 }, // und_Guru -> pa_Guru_IN
+ { 0, 55, 0 }, { 66, 55, 114 }, // und_Hang -> ko_Hang_KR
+ { 0, 54, 0 }, { 25, 5, 44 }, // und_Hani -> zh_Hans_CN
+ { 0, 56, 0 }, { 280, 56, 170 }, // und_Hano -> hnn_Hano_PH
+ { 0, 5, 0 }, { 25, 5, 44 }, // und_Hans -> zh_Hans_CN
+ { 0, 6, 0 }, { 25, 6, 208 }, // und_Hant -> zh_Hant_TW
+ { 0, 18, 0 }, { 48, 18, 105 }, // und_Hebr -> he_Hebr_IL
+ { 0, 18, 222 }, { 137, 18, 222 }, // und_Hebr_UA -> yi_Hebr_UA
+ { 0, 104, 0 }, { 59, 104, 108 }, // und_Hira -> ja_Hira_JP
+ { 0, 79, 0 }, { 278, 79, 106 }, // und_Ital -> ett_Ital_IT
+ { 0, 60, 0 }, { 60, 60, 101 }, // und_Java -> jv_Java_ID
+ { 0, 19, 0 }, { 59, 19, 108 }, // und_Jpan -> ja_Jpan_JP
+ { 0, 63, 0 }, { 277, 63, 147 }, // und_Kali -> eky_Kali_MM
+ { 0, 62, 0 }, { 59, 62, 108 }, // und_Kana -> ja_Kana_JP
+ { 0, 64, 0 }, { 300, 64, 163 }, // und_Khar -> pra_Khar_PK
+ { 0, 20, 0 }, { 23, 20, 36 }, // und_Khmr -> km_Khmr_KH
+ { 0, 21, 0 }, { 61, 21, 100 }, // und_Knda -> kn_Knda_IN
+ { 0, 22, 0 }, { 66, 22, 114 }, // und_Kore -> ko_Kore_KR
+ { 0, 61, 0 }, { 17, 61, 100 }, // und_Kthi -> bh_Kthi_IN
+ { 0, 65, 0 }, { 292, 65, 211 }, // und_Lana -> nod_Lana_TH
+ { 0, 23, 0 }, { 69, 23, 117 }, // und_Laoo -> lo_Laoo_LA
+ { 0, 7, 1 }, { 126, 7, 1 }, // und_Latn_AF -> tk_Latn_AF
+ { 0, 7, 11 }, { 12, 7, 11 }, // und_Latn_AM -> az_Latn_AM
+ { 0, 7, 33 }, { 125, 7, 33 }, // und_Latn_BG -> tr_Latn_BG
+ { 0, 7, 44 }, { 139, 7, 44 }, // und_Latn_CN -> za_Latn_CN
+ { 0, 7, 56 }, { 125, 7, 56 }, // und_Latn_CY -> tr_Latn_CY
+ { 0, 7, 3 }, { 37, 7, 3 }, // und_Latn_DZ -> fr_Latn_DZ
+ { 0, 7, 67 }, { 4, 7, 67 }, // und_Latn_ER -> aa_Latn_ER
+ { 0, 7, 69 }, { 31, 7, 69 }, // und_Latn_ET -> en_Latn_ET
+ { 0, 7, 81 }, { 67, 7, 81 }, // und_Latn_GE -> ku_Latn_GE
+ { 0, 7, 85 }, { 125, 7, 85 }, // und_Latn_GR -> tr_Latn_GR
+ { 0, 7, 105 }, { 95, 7, 105 }, // und_Latn_IL -> ro_Latn_IL
+ { 0, 7, 102 }, { 126, 7, 102 }, // und_Latn_IR -> tk_Latn_IR
+ { 0, 7, 48 }, { 37, 7, 48 }, // und_Latn_KM -> fr_Latn_KM
+ { 0, 7, 110 }, { 42, 7, 110 }, // und_Latn_KZ -> de_Latn_KZ
+ { 0, 7, 119 }, { 37, 7, 119 }, // und_Latn_LB -> fr_Latn_LB
+ { 0, 7, 145 }, { 37, 7, 145 }, // und_Latn_MA -> fr_Latn_MA
+ { 0, 7, 127 }, { 6, 7, 127 }, // und_Latn_MK -> sq_Latn_MK
+ { 0, 7, 126 }, { 91, 7, 126 }, // und_Latn_MO -> pt_Latn_MO
+ { 0, 7, 136 }, { 37, 7, 136 }, // und_Latn_MR -> fr_Latn_MR
+ { 0, 7, 178 }, { 36, 7, 178 }, // und_Latn_RU -> fi_Latn_RU
+ { 0, 7, 194 }, { 110, 7, 194 }, // und_Latn_SO -> so_Latn_SO
+ { 0, 7, 207 }, { 37, 7, 207 }, // und_Latn_SY -> fr_Latn_SY
+ { 0, 7, 216 }, { 37, 7, 216 }, // und_Latn_TN -> fr_Latn_TN
+ { 0, 7, 208 }, { 174, 7, 208 }, // und_Latn_TW -> trv_Latn_TW
+ { 0, 7, 222 }, { 90, 7, 222 }, // und_Latn_UA -> pl_Latn_UA
+ { 0, 66, 0 }, { 283, 66, 100 }, // und_Lepc -> lep_Lepc_IN
+ { 0, 67, 0 }, { 284, 67, 100 }, // und_Limb -> lif_Limb_IN
+ { 0, 68, 0 }, { 264, 68, 85 }, // und_Linb -> grc_Linb_GR
+ { 0, 51, 0 }, { 285, 51, 44 }, // und_Lisu -> lis_Lisu_CN
+ { 0, 69, 0 }, { 287, 69, 217 }, // und_Lyci -> xlc_Lyci_TR
+ { 0, 70, 0 }, { 288, 70, 217 }, // und_Lydi -> xld_Lydi_TR
+ { 0, 71, 0 }, { 273, 71, 102 }, // und_Mand -> myz_Mand_IR
+ { 0, 74, 0 }, { 291, 74, 201 }, // und_Merc -> xmr_Merc_SD
+ { 0, 73, 0 }, { 291, 73, 201 }, // und_Mero -> xmr_Mero_SD
+ { 0, 24, 0 }, { 77, 24, 100 }, // und_Mlym -> ml_Mlym_IN
+ { 0, 8, 0 }, { 82, 8, 44 }, // und_Mong -> mn_Mong_CN
+ { 0, 72, 0 }, { 290, 72, 100 }, // und_Mtei -> mni_Mtei_IN
+ { 0, 25, 0 }, { 21, 25, 147 }, // und_Mymr -> my_Mymr_MM
+ { 0, 75, 0 }, { 289, 75, 91 }, // und_Nkoo -> man_Nkoo_GN
+ { 0, 77, 0 }, { 293, 77, 104 }, // und_Ogam -> sga_Ogam_IE
+ { 0, 78, 0 }, { 304, 78, 100 }, // und_Olck -> sat_Olck_IN
+ { 0, 82, 0 }, { 296, 82, 143 }, // und_Orkh -> otk_Orkh_MN
+ { 0, 26, 0 }, { 87, 26, 100 }, // und_Orya -> or_Orya_IN
+ { 0, 83, 0 }, { 110, 83, 194 }, // und_Osma -> so_Osma_SO
+ { 0, 58, 0 }, { 297, 58, 102 }, // und_Phli -> pal_Phli_IR
+ { 0, 85, 0 }, { 299, 85, 119 }, // und_Phnx -> phn_Phnx_LB
+ { 0, 86, 0 }, { 282, 86, 44 }, // und_Plrd -> hmd_Plrd_CN
+ { 0, 59, 0 }, { 298, 59, 102 }, // und_Prti -> xpr_Prti_IR
+ { 0, 87, 0 }, { 301, 87, 101 }, // und_Rjng -> rej_Rjng_ID
+ { 0, 88, 0 }, { 294, 88, 205 }, // und_Runr -> non_Runr_SE
+ { 0, 89, 0 }, { 303, 89, 105 }, // und_Samr -> smp_Samr_IL
+ { 0, 81, 0 }, { 302, 81, 237 }, // und_Sarb -> xsa_Sarb_YE
+ { 0, 90, 0 }, { 305, 90, 100 }, // und_Saur -> saz_Saur_IN
+ { 0, 92, 0 }, { 31, 92, 224 }, // und_Shaw -> en_Shaw_GB
+ { 0, 91, 0 }, { 99, 91, 100 }, // und_Shrd -> sa_Shrd_IN
+ { 0, 32, 0 }, { 106, 32, 198 }, // und_Sinh -> si_Sinh_LK
+ { 0, 93, 0 }, { 306, 93, 100 }, // und_Sora -> srb_Sora_IN
+ { 0, 95, 0 }, { 112, 95, 101 }, // und_Sund -> su_Sund_ID
+ { 0, 96, 0 }, { 307, 96, 18 }, // und_Sylo -> syl_Sylo_BD
+ { 0, 33, 0 }, { 151, 33, 207 }, // und_Syrc -> syr_Syrc_SY
+ { 0, 98, 0 }, { 308, 98, 170 }, // und_Tagb -> tbw_Tagb_PH
+ { 0, 101, 0 }, { 275, 101, 100 }, // und_Takr -> doi_Takr_IN
+ { 0, 99, 0 }, { 310, 99, 44 }, // und_Tale -> tdd_Tale_CN
+ { 0, 76, 0 }, { 286, 76, 44 }, // und_Talu -> khb_Talu_CN
+ { 0, 27, 0 }, { 117, 27, 100 }, // und_Taml -> ta_Taml_IN
+ { 0, 100, 0 }, { 309, 100, 232 }, // und_Tavt -> blt_Tavt_VN
+ { 0, 28, 0 }, { 119, 28, 100 }, // und_Telu -> te_Telu_IN
+ { 0, 9, 0 }, { 183, 9, 216 }, // und_Tfng -> shi_Tfng_TN
+ { 0, 97, 0 }, { 166, 97, 170 }, // und_Tglg -> fil_Tglg_PH
+ { 0, 29, 0 }, { 143, 29, 131 }, // und_Thaa -> dv_Thaa_MV
+ { 0, 30, 0 }, { 120, 30, 211 }, // und_Thai -> th_Thai_TH
+ { 0, 31, 0 }, { 121, 31, 44 }, // und_Tibt -> bo_Tibt_CN
+ { 0, 102, 0 }, { 311, 102, 207 }, // und_Ugar -> uga_Ugar_SY
+ { 0, 35, 0 }, { 252, 35, 121 }, // und_Vaii -> vai_Vaii_LR
+ { 0, 80, 0 }, { 295, 80, 102 }, // und_Xpeo -> peo_Xpeo_IR
+ { 0, 94, 0 }, { 262, 94, 103 }, // und_Xsux -> akk_Xsux_IQ
+ { 0, 34, 0 }, { 168, 34, 44 } // und_Yiii -> ii_Yiii_CN
};
static const quint16 locale_index[] = {
@@ -623,169 +817,169 @@ static const quint16 locale_index[] = {
205, // Hungarian
206, // Icelandic
207, // Indonesian
- 0, // Interlingua
+ 208, // Interlingua
0, // Interlingue
0, // Inuktitut
0, // Inupiak
- 208, // Irish
- 209, // Italian
- 212, // Japanese
+ 209, // Irish
+ 210, // Italian
+ 213, // Japanese
0, // Javanese
- 213, // Kannada
- 214, // Kashmiri
- 215, // Kazakh
- 216, // Kinyarwanda
- 217, // Kirghiz
- 218, // Korean
+ 214, // Kannada
+ 215, // Kashmiri
+ 216, // Kazakh
+ 217, // Kinyarwanda
+ 218, // Kirghiz
+ 219, // Korean
0, // Kurdish
- 220, // Rundi
- 221, // Lao
+ 221, // Rundi
+ 222, // Lao
0, // Latin
- 222, // Latvian
- 223, // Lingala
- 227, // Lithuanian
- 228, // Macedonian
- 229, // Malagasy
- 230, // Malay
- 233, // Malayalam
- 234, // Maltese
+ 223, // Latvian
+ 224, // Lingala
+ 228, // Lithuanian
+ 229, // Macedonian
+ 230, // Malagasy
+ 231, // Malay
+ 234, // Malayalam
+ 235, // Maltese
0, // Maori
- 235, // Marathi
+ 236, // Marathi
0, // Marshallese
- 0, // Mongolian
+ 237, // Mongolian
0, // Nauru
- 236, // Nepali
- 238, // NorwegianBokmal
+ 238, // Nepali
+ 240, // NorwegianBokmal
0, // Occitan
- 239, // Oriya
- 240, // Pashto
- 241, // Persian
- 243, // Polish
- 244, // Portuguese
- 253, // Punjabi
+ 241, // Oriya
+ 242, // Pashto
+ 243, // Persian
+ 245, // Polish
+ 246, // Portuguese
+ 255, // Punjabi
0, // Quechua
- 255, // Romansh
- 256, // Romanian
- 258, // Russian
+ 257, // Romansh
+ 258, // Romanian
+ 260, // Russian
0, // Samoan
- 264, // Sango
+ 266, // Sango
0, // Sanskrit
- 265, // Serbian
- 271, // Ossetic
- 273, // Southern Sotho
- 275, // Tswana
- 277, // Shona
+ 267, // Serbian
+ 273, // Ossetic
+ 275, // Southern Sotho
+ 277, // Tswana
+ 279, // Shona
0, // Sindhi
- 278, // Sinhala
- 279, // Swati
- 281, // Slovak
- 282, // Slovenian
- 283, // Somali
- 287, // Spanish
+ 280, // Sinhala
+ 281, // Swati
+ 283, // Slovak
+ 284, // Slovenian
+ 285, // Somali
+ 289, // Spanish
0, // Sundanese
- 313, // Swahili
- 316, // Swedish
+ 315, // Swahili
+ 318, // Swedish
0, // Sardinian
- 319, // Tajik
- 320, // Tamil
+ 321, // Tajik
+ 322, // Tamil
0, // Tatar
- 324, // Telugu
- 325, // Thai
- 326, // Tibetan
- 328, // Tigrinya
- 330, // Tongan
- 331, // Tsonga
- 332, // Turkish
+ 326, // Telugu
+ 327, // Thai
+ 328, // Tibetan
+ 330, // Tigrinya
+ 332, // Tongan
+ 333, // Tsonga
+ 334, // Turkish
0, // Turkmen
0, // Tahitian
- 0, // Uigur
- 334, // Ukrainian
- 335, // Urdu
- 337, // Uzbek
- 340, // Vietnamese
+ 0, // Uighur
+ 336, // Ukrainian
+ 337, // Urdu
+ 339, // Uzbek
+ 342, // Vietnamese
0, // Volapuk
- 341, // Welsh
+ 343, // Welsh
0, // Wolof
- 342, // Xhosa
+ 344, // Xhosa
0, // Yiddish
- 343, // Yoruba
+ 345, // Yoruba
0, // Zhuang
- 344, // Zulu
- 345, // NorwegianNynorsk
- 346, // Bosnian
+ 346, // Zulu
+ 347, // NorwegianNynorsk
+ 348, // Bosnian
0, // Divehi
- 348, // Manx
- 349, // Cornish
- 350, // Akan
- 351, // Konkani
+ 350, // Manx
+ 351, // Cornish
+ 352, // Akan
+ 353, // Konkani
0, // Ga
- 352, // Igbo
- 353, // Kamba
+ 354, // Igbo
+ 355, // Kamba
0, // Syriac
- 354, // Blin
+ 356, // Blin
0, // Geez
0, // Koro
0, // Sidamo
0, // Atsam
- 355, // Tigre
+ 357, // Tigre
0, // Jju
- 356, // Friulian
- 357, // Venda
- 358, // Ewe
- 360, // Walamo
- 361, // Hawaiian
+ 358, // Friulian
+ 359, // Venda
+ 360, // Ewe
+ 362, // Walamo
+ 363, // Hawaiian
0, // Tyap
0, // Nyanja
- 362, // Filipino
- 363, // Swiss German
- 364, // Sichuan Yi
+ 364, // Filipino
+ 365, // Swiss German
+ 366, // Sichuan Yi
0, // Kpelle
0, // Low German
- 365, // South Ndebele
- 366, // Northern Sotho
- 367, // Northern Sami
+ 367, // South Ndebele
+ 368, // Northern Sotho
+ 369, // Northern Sami
0, // Taroko
- 369, // Gusii
- 370, // Taita
- 371, // Fulah
- 372, // Kikuyu
- 373, // Samburu
- 374, // Sena
- 375, // North Ndebele
- 376, // Rombo
- 377, // Tachelhit
- 379, // Kabyle
- 380, // Nyankole
- 381, // Bena
- 382, // Vunjo
- 383, // Bambara
- 384, // Embu
- 385, // Cherokee
- 386, // Morisyen
- 387, // Makonde
- 388, // Langi
- 389, // Ganda
- 390, // Bemba
- 391, // Kabuverdianu
- 392, // Meru
- 393, // Kalenjin
- 394, // Nama
- 395, // Machame
- 396, // Colognian
- 397, // Masai
- 399, // Soga
- 400, // Luyia
- 401, // Asu
- 402, // Teso
- 404, // Saho
- 405, // Koyra Chiini
- 406, // Rwa
- 407, // Luo
- 408, // Chiga
- 409, // Central Morocco Tamazight
- 410, // Koyraboro Senni
- 411, // Shambala
- 412, // Bodo
+ 371, // Gusii
+ 372, // Taita
+ 373, // Fulah
+ 374, // Kikuyu
+ 375, // Samburu
+ 376, // Sena
+ 377, // North Ndebele
+ 378, // Rombo
+ 379, // Tachelhit
+ 381, // Kabyle
+ 382, // Nyankole
+ 383, // Bena
+ 384, // Vunjo
+ 385, // Bambara
+ 386, // Embu
+ 387, // Cherokee
+ 388, // Morisyen
+ 389, // Makonde
+ 390, // Langi
+ 391, // Ganda
+ 392, // Bemba
+ 393, // Kabuverdianu
+ 394, // Meru
+ 395, // Kalenjin
+ 396, // Nama
+ 397, // Machame
+ 398, // Colognian
+ 399, // Masai
+ 401, // Soga
+ 402, // Luyia
+ 403, // Asu
+ 404, // Teso
+ 406, // Saho
+ 407, // Koyra Chiini
+ 408, // Rwa
+ 409, // Luo
+ 410, // Chiga
+ 411, // Central Morocco Tamazight
+ 412, // Koyraboro Senni
+ 413, // Shambala
+ 414, // Bodo
0, // Avaric
0, // Chamorro
0, // Chechen
@@ -800,37 +994,88 @@ static const quint16 locale_index[] = {
0, // Kongo
0, // Kwanyama
0, // Limburgish
- 413, // LubaKatanga
+ 415, // LubaKatanga
0, // Luxembourgish
0, // Navaho
0, // Ndonga
0, // Ojibwa
0, // Pali
0, // Walloon
- 414, // Aghem
- 415, // Basaa
- 416, // Zarma
- 417, // Duala
- 418, // JolaFonyi
- 419, // Ewondo
- 420, // Bafia
- 421, // MakhuwaMeetto
- 422, // Mundang
- 423, // Kwasio
- 424, // Nuer
- 425, // Sakha
- 426, // Sangu
- 427, // Congo Swahili
- 428, // Tasawaq
- 429, // Vai
- 431, // Walser
- 432, // Yangben
+ 416, // Aghem
+ 417, // Basaa
+ 418, // Zarma
+ 419, // Duala
+ 420, // JolaFonyi
+ 421, // Ewondo
+ 422, // Bafia
+ 423, // MakhuwaMeetto
+ 424, // Mundang
+ 425, // Kwasio
+ 426, // Nuer
+ 427, // Sakha
+ 428, // Sangu
+ 429, // Congo Swahili
+ 430, // Tasawaq
+ 431, // Vai
+ 433, // Walser
+ 434, // Yangben
0, // Avestan
- 433, // Asturian
- 434, // Ngomba
- 435, // Kako
- 436, // Meta
- 437, // Ngiemboon
+ 435, // Asturian
+ 436, // Ngomba
+ 437, // Kako
+ 438, // Meta
+ 439, // Ngiemboon
+ 0, // Aragonese
+ 0, // Akkadian
+ 0, // AncientEgyptian
+ 0, // AncientGreek
+ 0, // Aramaic
+ 0, // Balinese
+ 0, // Bamun
+ 0, // BatakToba
+ 0, // Buginese
+ 0, // Buhid
+ 0, // Carian
+ 0, // Chakma
+ 0, // ClassicalMandaic
+ 0, // Coptic
+ 0, // Dogri
+ 0, // EasternCham
+ 0, // EasternKayah
+ 0, // Etruscan
+ 0, // Gothic
+ 0, // Hanunoo
+ 0, // Ingush
+ 0, // LargeFloweryMiao
+ 0, // Lepcha
+ 0, // Limbu
+ 0, // Lisu
+ 0, // Lu
+ 0, // Lycian
+ 0, // Lydian
+ 0, // Mandingo
+ 0, // Manipuri
+ 0, // Meroitic
+ 0, // NorthernThai
+ 0, // OldIrish
+ 0, // OldNorse
+ 0, // OldPersian
+ 0, // OldTurkish
+ 0, // Pahlavi
+ 0, // Parthian
+ 0, // Phoenician
+ 0, // PrakritLanguage
+ 0, // Rejang
+ 0, // Sabaean
+ 0, // Samaritan
+ 0, // Santali
+ 0, // Saurashtra
+ 0, // Sora
+ 0, // Sylheti
+ 0, // Tagbanwa
+ 0, // TaiDam
+ 0, // TaiNua
+ 0, // Ugaritic
0 // trailing 0
};
@@ -845,435 +1090,437 @@ static const QLocaleData locale_data[] = {
{ 5, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 72,10 , 82,17 , 18,7 , 25,12 , 653,48 , 701,92 , 134,24 , 653,48 , 701,92 , 134,24 , 290,21 , 311,58 , 369,14 , 290,21 , 311,58 , 369,14 , 4,3 , 4,3 , {90,65,82}, 11,1 , 31,27 , 4,4 , 8,6 , 50,9 , 59,11 , 2, 1, 7, 6, 7 }, // Afrikaans/Latin/SouthAfrica
{ 5, 7, 148, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 72,10 , 99,16 , 37,5 , 8,10 , 653,48 , 701,92 , 134,24 , 653,48 , 701,92 , 134,24 , 290,21 , 311,58 , 369,14 , 290,21 , 311,58 , 369,14 , 4,3 , 4,3 , {78,65,68}, 12,1 , 58,23 , 14,5 , 4,0 , 50,9 , 70,7 , 2, 1, 1, 6, 7 }, // Afrikaans/Latin/Namibia
{ 6, 7, 2, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 0,6 , 0,6 , 115,8 , 123,18 , 42,7 , 49,12 , 793,48 , 841,78 , 919,24 , 793,48 , 841,78 , 919,24 , 383,28 , 411,58 , 469,14 , 383,28 , 411,58 , 469,14 , 7,2 , 7,2 , {65,76,76}, 13,3 , 0,7 , 4,4 , 4,0 , 77,5 , 82,9 , 0, 0, 1, 6, 7 }, // Albanian/Latin/Albania
- { 6, 7, 127, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 0,6 , 0,6 , 115,8 , 123,18 , 42,7 , 49,12 , 793,48 , 841,78 , 919,24 , 793,48 , 841,78 , 919,24 , 383,28 , 411,58 , 469,14 , 383,28 , 411,58 , 469,14 , 7,2 , 7,2 , {77,75,68}, 0,0 , 0,7 , 4,4 , 4,0 , 77,5 , 91,8 , 2, 1, 1, 6, 7 }, // Albanian/Latin/Macedonia
- { 7, 14, 69, 46, 44, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 14,6 , 14,6 , 20,9 , 29,8 , 141,10 , 10,17 , 18,7 , 25,12 , 943,46 , 989,61 , 1050,24 , 1074,46 , 1120,62 , 1050,24 , 483,27 , 510,28 , 538,14 , 483,27 , 510,28 , 538,14 , 9,3 , 9,4 , {69,84,66}, 16,2 , 81,34 , 4,4 , 8,6 , 99,4 , 103,5 , 2, 1, 7, 6, 7 }, // Amharic/Ethiopic/Ethiopia
- { 8, 1, 64, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {69,71,80}, 18,5 , 115,70 , 14,5 , 19,6 , 108,7 , 115,3 , 2, 1, 6, 5, 6 }, // Arabic/Arabic/Egypt
- { 8, 1, 3, 44, 46, 59, 37, 48, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 179,8 , 161,18 , 18,7 , 25,12 , 1281,71 , 1281,71 , 1352,24 , 1281,71 , 1281,71 , 1352,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {68,90,68}, 23,5 , 185,91 , 14,5 , 19,6 , 108,7 , 118,7 , 2, 1, 6, 4, 5 }, // Arabic/Arabic/Algeria
- { 8, 1, 17, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {66,72,68}, 28,5 , 276,91 , 14,5 , 19,6 , 108,7 , 125,7 , 3, 0, 6, 5, 6 }, // Arabic/Arabic/Bahrain
- { 8, 1, 42, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {88,65,70}, 33,4 , 367,84 , 14,5 , 19,6 , 108,7 , 132,4 , 0, 0, 1, 6, 7 }, // Arabic/Arabic/Chad
- { 8, 1, 48, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {75,77,70}, 37,7 , 451,105 , 14,5 , 19,6 , 108,7 , 136,9 , 0, 0, 1, 6, 7 }, // Arabic/Arabic/Comoros
- { 8, 1, 59, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {68,74,70}, 0,0 , 556,84 , 14,5 , 19,6 , 108,7 , 145,6 , 0, 0, 6, 6, 7 }, // Arabic/Arabic/Djibouti
- { 8, 1, 67, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {69,82,78}, 0,0 , 640,91 , 14,5 , 19,6 , 108,7 , 151,7 , 2, 1, 1, 6, 7 }, // Arabic/Arabic/Eritrea
- { 8, 1, 103, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1376,92 , 1376,92 , 1468,24 , 1492,92 , 1376,92 , 1468,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {73,81,68}, 44,5 , 731,84 , 14,5 , 19,6 , 108,7 , 158,6 , 0, 0, 6, 5, 6 }, // Arabic/Arabic/Iraq
- { 8, 1, 105, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {73,76,83}, 49,1 , 815,133 , 14,5 , 19,6 , 108,7 , 164,7 , 2, 1, 7, 5, 6 }, // Arabic/Arabic/Israel
- { 8, 1, 109, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1376,92 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {74,79,68}, 50,5 , 948,84 , 14,5 , 19,6 , 108,7 , 171,6 , 3, 0, 6, 5, 6 }, // Arabic/Arabic/Jordan
- { 8, 1, 115, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {75,87,68}, 55,5 , 1032,84 , 14,5 , 19,6 , 108,7 , 177,6 , 3, 0, 6, 5, 6 }, // Arabic/Arabic/Kuwait
- { 8, 1, 119, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1376,92 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {76,66,80}, 60,5 , 1116,84 , 14,5 , 19,6 , 108,7 , 183,5 , 0, 0, 1, 6, 7 }, // Arabic/Arabic/Lebanon
- { 8, 1, 122, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {76,89,68}, 65,5 , 1200,77 , 14,5 , 19,6 , 108,7 , 188,5 , 3, 0, 6, 5, 6 }, // Arabic/Arabic/Libya
- { 8, 1, 136, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {77,82,79}, 70,5 , 1277,112 , 14,5 , 19,6 , 108,7 , 193,9 , 0, 0, 1, 6, 7 }, // Arabic/Arabic/Mauritania
- { 8, 1, 145, 44, 46, 59, 37, 48, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 179,8 , 161,18 , 18,7 , 25,12 , 1584,71 , 1655,71 , 1726,24 , 1655,71 , 1750,71 , 1821,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {77,65,68}, 75,5 , 1389,77 , 14,5 , 19,6 , 108,7 , 202,6 , 2, 1, 6, 5, 6 }, // Arabic/Arabic/Morocco
- { 8, 1, 162, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {79,77,82}, 80,5 , 1466,77 , 14,5 , 19,6 , 108,7 , 208,5 , 3, 0, 6, 4, 5 }, // Arabic/Arabic/Oman
- { 8, 1, 165, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {74,79,68}, 50,5 , 948,84 , 14,5 , 19,6 , 108,7 , 213,6 , 3, 0, 1, 6, 7 }, // Arabic/Arabic/PalestinianTerritories
- { 8, 1, 175, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {81,65,82}, 85,5 , 1543,70 , 4,4 , 4,0 , 108,7 , 219,3 , 2, 1, 6, 5, 6 }, // Arabic/Arabic/Qatar
- { 8, 1, 186, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {83,65,82}, 90,5 , 1613,77 , 4,4 , 4,0 , 108,7 , 222,24 , 2, 1, 6, 4, 5 }, // Arabic/Arabic/SaudiArabia
- { 8, 1, 194, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {83,79,83}, 0,0 , 1690,77 , 14,5 , 19,6 , 108,7 , 246,7 , 0, 0, 1, 6, 7 }, // Arabic/Arabic/Somalia
+ { 6, 7, 127, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 0,6 , 0,6 , 115,8 , 123,18 , 42,7 , 49,12 , 793,48 , 841,78 , 919,24 , 793,48 , 841,78 , 919,24 , 383,28 , 411,58 , 469,14 , 383,28 , 411,58 , 469,14 , 7,2 , 7,2 , {77,75,68}, 16,3 , 0,7 , 4,4 , 4,0 , 77,5 , 91,8 , 2, 1, 1, 6, 7 }, // Albanian/Latin/Macedonia
+ { 7, 14, 69, 46, 44, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 14,6 , 14,6 , 20,9 , 29,8 , 141,10 , 10,17 , 18,7 , 25,12 , 943,46 , 989,61 , 1050,24 , 1074,46 , 1120,62 , 1050,24 , 483,27 , 510,28 , 538,14 , 483,27 , 510,28 , 538,14 , 9,3 , 9,4 , {69,84,66}, 19,2 , 81,34 , 4,4 , 8,6 , 99,4 , 103,5 , 2, 1, 7, 6, 7 }, // Amharic/Ethiopic/Ethiopia
+ { 8, 1, 64, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {69,71,80}, 21,5 , 115,70 , 14,5 , 19,6 , 108,7 , 115,3 , 2, 1, 6, 5, 6 }, // Arabic/Arabic/Egypt
+ { 8, 1, 3, 44, 46, 59, 37, 48, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 179,8 , 161,18 , 18,7 , 25,12 , 1281,71 , 1281,71 , 1352,24 , 1281,71 , 1281,71 , 1352,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {68,90,68}, 26,5 , 185,91 , 14,5 , 19,6 , 108,7 , 118,7 , 2, 1, 6, 4, 5 }, // Arabic/Arabic/Algeria
+ { 8, 1, 17, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {66,72,68}, 31,5 , 276,91 , 14,5 , 19,6 , 108,7 , 125,7 , 3, 0, 6, 5, 6 }, // Arabic/Arabic/Bahrain
+ { 8, 1, 42, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {88,65,70}, 36,4 , 367,84 , 14,5 , 19,6 , 108,7 , 132,4 , 0, 0, 1, 6, 7 }, // Arabic/Arabic/Chad
+ { 8, 1, 48, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {75,77,70}, 40,7 , 451,105 , 14,5 , 19,6 , 108,7 , 136,9 , 0, 0, 1, 6, 7 }, // Arabic/Arabic/Comoros
+ { 8, 1, 59, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {68,74,70}, 5,3 , 556,84 , 14,5 , 19,6 , 108,7 , 145,6 , 0, 0, 6, 6, 7 }, // Arabic/Arabic/Djibouti
+ { 8, 1, 67, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {69,82,78}, 8,3 , 640,91 , 14,5 , 19,6 , 108,7 , 151,7 , 2, 1, 1, 6, 7 }, // Arabic/Arabic/Eritrea
+ { 8, 1, 103, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1376,92 , 1376,92 , 1468,24 , 1492,92 , 1376,92 , 1468,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {73,81,68}, 47,5 , 731,84 , 14,5 , 19,6 , 108,7 , 158,6 , 0, 0, 6, 5, 6 }, // Arabic/Arabic/Iraq
+ { 8, 1, 105, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {73,76,83}, 52,1 , 815,133 , 14,5 , 19,6 , 108,7 , 164,7 , 2, 1, 7, 5, 6 }, // Arabic/Arabic/Israel
+ { 8, 1, 109, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1376,92 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {74,79,68}, 53,5 , 948,84 , 14,5 , 19,6 , 108,7 , 171,6 , 3, 0, 6, 5, 6 }, // Arabic/Arabic/Jordan
+ { 8, 1, 115, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {75,87,68}, 58,5 , 1032,84 , 14,5 , 19,6 , 108,7 , 177,6 , 3, 0, 6, 5, 6 }, // Arabic/Arabic/Kuwait
+ { 8, 1, 119, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1376,92 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {76,66,80}, 63,5 , 1116,84 , 14,5 , 19,6 , 108,7 , 183,5 , 0, 0, 1, 6, 7 }, // Arabic/Arabic/Lebanon
+ { 8, 1, 122, 44, 46, 59, 37, 48, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {76,89,68}, 68,5 , 1200,77 , 14,5 , 19,6 , 108,7 , 188,5 , 3, 0, 6, 5, 6 }, // Arabic/Arabic/Libya
+ { 8, 1, 136, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {77,82,79}, 73,5 , 1277,112 , 14,5 , 19,6 , 108,7 , 193,9 , 0, 0, 1, 6, 7 }, // Arabic/Arabic/Mauritania
+ { 8, 1, 145, 44, 46, 59, 37, 48, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 179,8 , 161,18 , 18,7 , 25,12 , 1584,71 , 1655,71 , 1726,24 , 1655,71 , 1750,71 , 1821,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {77,65,68}, 78,5 , 1389,77 , 14,5 , 19,6 , 108,7 , 202,6 , 2, 1, 6, 5, 6 }, // Arabic/Arabic/Morocco
+ { 8, 1, 162, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {79,77,82}, 83,5 , 1466,77 , 14,5 , 19,6 , 108,7 , 208,5 , 3, 0, 6, 4, 5 }, // Arabic/Arabic/Oman
+ { 8, 1, 165, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {73,76,83}, 52,1 , 815,133 , 14,5 , 19,6 , 108,7 , 213,6 , 2, 1, 1, 6, 7 }, // Arabic/Arabic/PalestinianTerritories
+ { 8, 1, 175, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {81,65,82}, 88,5 , 1543,70 , 4,4 , 4,0 , 108,7 , 219,3 , 2, 1, 6, 5, 6 }, // Arabic/Arabic/Qatar
+ { 8, 1, 186, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {83,65,82}, 93,5 , 1613,77 , 4,4 , 4,0 , 108,7 , 222,24 , 2, 1, 6, 4, 5 }, // Arabic/Arabic/SaudiArabia
+ { 8, 1, 194, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {83,79,83}, 98,1 , 1690,77 , 14,5 , 19,6 , 108,7 , 246,7 , 0, 0, 1, 6, 7 }, // Arabic/Arabic/Somalia
{ 8, 1, 201, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {83,68,71}, 0,0 , 1767,84 , 14,5 , 19,6 , 108,7 , 253,7 , 2, 1, 6, 5, 6 }, // Arabic/Arabic/Sudan
- { 8, 1, 207, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1376,92 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {83,89,80}, 95,5 , 1851,77 , 4,4 , 4,0 , 108,7 , 260,5 , 0, 0, 6, 5, 6 }, // Arabic/Arabic/Syria
- { 8, 1, 216, 44, 46, 59, 37, 48, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 179,8 , 161,18 , 18,7 , 25,12 , 1281,71 , 1281,71 , 1352,24 , 1281,71 , 1281,71 , 1352,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {84,78,68}, 100,5 , 1928,77 , 4,4 , 4,0 , 108,7 , 265,4 , 3, 0, 7, 5, 6 }, // Arabic/Arabic/Tunisia
- { 8, 1, 223, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {65,69,68}, 105,5 , 2005,91 , 14,5 , 19,6 , 108,7 , 269,24 , 2, 1, 6, 5, 6 }, // Arabic/Arabic/UnitedArabEmirates
- { 8, 1, 236, 46, 44, 59, 37, 48, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {77,65,68}, 75,5 , 1389,77 , 14,5 , 19,6 , 108,7 , 293,15 , 2, 1, 1, 6, 7 }, // Arabic/Arabic/WesternSahara
- { 8, 1, 237, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {89,69,82}, 110,5 , 2096,70 , 4,4 , 4,0 , 108,7 , 308,5 , 0, 0, 6, 4, 5 }, // Arabic/Arabic/Yemen
- { 9, 10, 11, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 187,8 , 35,18 , 37,5 , 8,10 , 1845,48 , 1893,94 , 158,27 , 1845,48 , 1893,94 , 158,27 , 618,28 , 646,62 , 708,14 , 618,28 , 646,62 , 708,14 , 13,3 , 14,3 , {65,77,68}, 115,3 , 0,7 , 25,5 , 4,0 , 313,7 , 320,25 , 0, 0, 1, 6, 7 }, // Armenian/Armenian/Armenia
- { 10, 11, 100, 46, 44, 59, 37, 2534, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 195,8 , 203,18 , 61,8 , 69,12 , 1987,62 , 2049,88 , 158,27 , 1987,62 , 2049,88 , 158,27 , 722,37 , 759,58 , 708,14 , 722,37 , 759,58 , 708,14 , 16,9 , 17,7 , {73,78,82}, 118,1 , 0,7 , 14,5 , 4,0 , 345,7 , 352,4 , 2, 1, 7, 7, 7 }, // Assamese/Bengali/India
- { 12, 7, 15, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 0,6 , 0,6 , 221,8 , 229,19 , 37,5 , 8,10 , 2137,48 , 2185,77 , 158,27 , 2137,48 , 2185,77 , 158,27 , 817,26 , 843,67 , 99,14 , 817,26 , 843,67 , 99,14 , 0,2 , 0,2 , {65,90,78}, 119,4 , 2166,41 , 14,5 , 4,0 , 356,12 , 368,10 , 2, 1, 1, 6, 7 }, // Azerbaijani/Latin/Azerbaijan
- { 12, 2, 15, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 0,6 , 0,6 , 221,8 , 229,19 , 37,5 , 8,10 , 2262,77 , 2262,77 , 158,27 , 2262,77 , 2262,77 , 158,27 , 910,67 , 910,67 , 99,14 , 910,67 , 910,67 , 99,14 , 0,2 , 0,2 , {65,90,78}, 123,4 , 2207,12 , 14,5 , 4,0 , 378,10 , 378,10 , 2, 1, 1, 6, 7 }, // Azerbaijani/Cyrillic/Azerbaijan
- { 14, 7, 197, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 58,9 , 58,9 , 72,10 , 248,18 , 37,5 , 8,10 , 2339,48 , 2387,93 , 2480,24 , 2339,48 , 2387,93 , 2480,24 , 977,21 , 998,68 , 1066,14 , 977,21 , 998,68 , 1080,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2219,12 , 25,5 , 30,7 , 388,7 , 395,8 , 2, 1, 1, 6, 7 }, // Basque/Latin/Spain
- { 15, 11, 18, 46, 44, 59, 37, 2534, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 67,10 , 77,9 , 266,6 , 203,18 , 18,7 , 25,12 , 2504,90 , 2504,90 , 2594,33 , 2504,90 , 2504,90 , 2594,33 , 1094,37 , 1131,58 , 1189,18 , 1094,37 , 1131,58 , 1189,18 , 25,9 , 24,7 , {66,68,84}, 128,1 , 2231,21 , 0,4 , 37,6 , 403,5 , 408,8 , 2, 1, 5, 6, 7 }, // Bengali/Bengali/Bangladesh
- { 15, 11, 100, 46, 44, 59, 37, 2534, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 67,10 , 77,9 , 266,6 , 203,18 , 18,7 , 25,12 , 2504,90 , 2504,90 , 2594,33 , 2504,90 , 2504,90 , 2594,33 , 1094,37 , 1131,58 , 1189,18 , 1094,37 , 1131,58 , 1189,18 , 25,9 , 24,7 , {73,78,82}, 118,1 , 2252,19 , 0,4 , 37,6 , 403,5 , 416,4 , 2, 1, 7, 7, 7 }, // Bengali/Bengali/India
- { 16, 31, 25, 46, 44, 59, 37, 3872, 45, 43, 101, 8220, 8221, 8216, 8217, 86,9 , 86,9 , 86,9 , 86,9 , 72,10 , 272,30 , 81,22 , 103,27 , 2627,63 , 2690,191 , 2881,27 , 2908,27 , 2935,132 , 3067,27 , 1207,34 , 1241,79 , 1320,27 , 1207,34 , 1241,79 , 1320,27 , 34,5 , 31,6 , {66,84,78}, 129,3 , 2271,15 , 4,4 , 4,0 , 420,6 , 426,5 , 2, 1, 7, 6, 7 }, // Dzongkha/Tibetan/Bhutan
- { 19, 7, 74, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 3094,55 , 3149,78 , 158,27 , 3094,55 , 3149,78 , 158,27 , 1347,33 , 1380,43 , 1423,21 , 1347,33 , 1380,43 , 1423,21 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2286,11 , 14,5 , 4,0 , 431,9 , 440,5 , 2, 1, 1, 6, 7 }, // Breton/Latin/France
- { 20, 2, 33, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 95,7 , 95,7 , 302,8 , 310,18 , 37,5 , 8,10 , 3227,59 , 3286,82 , 3368,24 , 3227,59 , 3286,82 , 3368,24 , 1444,21 , 1465,55 , 1520,14 , 1444,21 , 1465,55 , 1520,14 , 39,7 , 37,7 , {66,71,78}, 132,3 , 2297,47 , 25,5 , 4,0 , 445,9 , 454,8 , 2, 1, 1, 6, 7 }, // Bulgarian/Cyrillic/Bulgaria
- { 21, 25, 147, 46, 44, 4170, 37, 4160, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 221,8 , 248,18 , 37,5 , 8,10 , 3392,43 , 3435,88 , 3523,24 , 3392,43 , 3435,88 , 3523,24 , 1534,25 , 1559,54 , 1613,14 , 1534,25 , 1559,54 , 1613,14 , 46,5 , 44,3 , {77,77,75}, 135,1 , 2344,18 , 14,5 , 4,0 , 462,3 , 465,6 , 0, 0, 7, 6, 7 }, // Burmese/Myanmar/Myanmar
- { 22, 2, 20, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 0,6 , 0,6 , 328,6 , 10,17 , 130,5 , 135,10 , 3547,48 , 3595,99 , 3694,24 , 3718,48 , 3766,95 , 3861,24 , 1627,21 , 1648,56 , 1704,14 , 1627,21 , 1648,56 , 1704,14 , 51,10 , 47,13 , {66,89,82}, 0,0 , 2362,23 , 4,4 , 4,0 , 471,10 , 481,8 , 0, 0, 7, 6, 7 }, // Belarusian/Cyrillic/Belarus
- { 23, 20, 36, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 102,9 , 334,8 , 10,17 , 18,7 , 25,12 , 3885,71 , 3885,71 , 158,27 , 3885,71 , 3885,71 , 158,27 , 1718,46 , 1718,46 , 708,14 , 1718,46 , 1718,46 , 708,14 , 61,5 , 60,5 , {75,72,82}, 136,1 , 2385,18 , 4,4 , 8,6 , 489,5 , 494,7 , 2, 1, 7, 6, 7 }, // Khmer/Khmer/Cambodia
- { 24, 7, 197, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 111,7 , 111,7 , 27,8 , 342,21 , 145,4 , 149,9 , 3956,60 , 4016,82 , 4098,24 , 4122,93 , 4215,115 , 4330,24 , 1764,21 , 1785,60 , 1764,21 , 1845,28 , 1873,60 , 1764,21 , 66,4 , 65,4 , {69,85,82}, 127,1 , 2403,20 , 4,4 , 8,6 , 501,6 , 507,7 , 2, 1, 1, 6, 7 }, // Catalan/Latin/Spain
- { 24, 7, 5, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 111,7 , 111,7 , 27,8 , 342,21 , 145,4 , 149,9 , 3956,60 , 4016,82 , 4098,24 , 4122,93 , 4215,115 , 4330,24 , 1764,21 , 1785,60 , 1764,21 , 1845,28 , 1873,60 , 1764,21 , 66,4 , 65,4 , {69,85,82}, 127,1 , 2403,20 , 4,4 , 8,6 , 501,6 , 514,7 , 2, 1, 1, 6, 7 }, // Catalan/Latin/Andorra
- { 25, 5, 44, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 118,5 , 118,5 , 123,5 , 123,5 , 363,6 , 369,13 , 158,6 , 164,10 , 4354,39 , 4393,38 , 158,27 , 4354,39 , 4393,38 , 158,27 , 1933,21 , 1954,28 , 1982,14 , 1933,21 , 1954,28 , 1982,14 , 70,2 , 69,2 , {67,78,89}, 137,1 , 2423,10 , 4,4 , 8,6 , 521,4 , 525,2 , 2, 1, 7, 6, 7 }, // Chinese/Simplified Han/China
- { 25, 5, 97, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 118,5 , 118,5 , 123,5 , 123,5 , 266,6 , 369,13 , 158,6 , 164,10 , 4354,39 , 4393,38 , 158,27 , 4354,39 , 4393,38 , 158,27 , 1933,21 , 1954,28 , 1982,14 , 1933,21 , 1954,28 , 1982,14 , 70,2 , 69,2 , {72,75,68}, 12,1 , 2433,9 , 4,4 , 4,0 , 521,4 , 527,9 , 2, 1, 7, 6, 7 }, // Chinese/Simplified Han/HongKong
- { 25, 5, 126, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 118,5 , 118,5 , 123,5 , 123,5 , 266,6 , 369,13 , 158,6 , 164,10 , 4354,39 , 4393,38 , 158,27 , 4354,39 , 4393,38 , 158,27 , 1933,21 , 1954,28 , 1982,14 , 1933,21 , 1954,28 , 1982,14 , 70,2 , 69,2 , {77,79,80}, 0,0 , 2442,10 , 4,4 , 4,0 , 521,4 , 536,9 , 2, 1, 7, 6, 7 }, // Chinese/Simplified Han/Macau
- { 25, 5, 190, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 118,5 , 118,5 , 123,5 , 123,5 , 27,8 , 369,13 , 174,7 , 164,10 , 4354,39 , 4393,38 , 158,27 , 4354,39 , 4393,38 , 158,27 , 1933,21 , 1954,28 , 1982,14 , 1933,21 , 1954,28 , 1982,14 , 70,2 , 69,2 , {83,71,68}, 0,0 , 2452,11 , 4,4 , 4,0 , 521,4 , 545,3 , 2, 1, 7, 6, 7 }, // Chinese/Simplified Han/Singapore
- { 25, 6, 97, 46, 44, 59, 37, 48, 45, 43, 101, 12300, 12301, 12302, 12303, 118,5 , 118,5 , 123,5 , 123,5 , 382,7 , 369,13 , 158,6 , 181,13 , 4354,39 , 4354,39 , 158,27 , 4354,39 , 4354,39 , 158,27 , 1996,21 , 1954,28 , 1982,14 , 1996,21 , 1954,28 , 1982,14 , 70,2 , 69,2 , {72,75,68}, 12,1 , 2433,9 , 4,4 , 8,6 , 548,4 , 552,14 , 2, 1, 7, 6, 7 }, // Chinese/Traditional Han/HongKong
- { 25, 6, 126, 46, 44, 59, 37, 48, 45, 43, 101, 12300, 12301, 12302, 12303, 118,5 , 118,5 , 123,5 , 123,5 , 382,7 , 389,15 , 158,6 , 181,13 , 4354,39 , 4354,39 , 158,27 , 4354,39 , 4354,39 , 158,27 , 1996,21 , 1954,28 , 1982,14 , 1996,21 , 1954,28 , 1982,14 , 70,2 , 69,2 , {77,79,80}, 0,0 , 2463,10 , 4,4 , 4,0 , 548,4 , 566,14 , 2, 1, 7, 6, 7 }, // Chinese/Traditional Han/Macau
- { 25, 6, 208, 46, 44, 59, 37, 48, 45, 43, 101, 12300, 12301, 12302, 12303, 118,5 , 118,5 , 123,5 , 123,5 , 179,8 , 369,13 , 158,6 , 194,11 , 4354,39 , 4354,39 , 158,27 , 4354,39 , 4354,39 , 158,27 , 1996,21 , 1954,28 , 1982,14 , 1996,21 , 1954,28 , 1982,14 , 70,2 , 69,2 , {84,87,68}, 138,3 , 2473,10 , 4,4 , 4,0 , 548,4 , 580,2 , 2, 1, 7, 6, 7 }, // Chinese/Traditional Han/Taiwan
- { 27, 7, 54, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 111,7 , 111,7 , 404,9 , 413,19 , 37,5 , 8,10 , 4431,49 , 4480,94 , 4574,39 , 4431,49 , 4613,98 , 4574,39 , 2017,28 , 2045,58 , 2103,14 , 2017,28 , 2045,58 , 2117,14 , 0,2 , 0,2 , {72,82,75}, 141,2 , 2483,74 , 25,5 , 4,0 , 582,8 , 590,8 , 2, 1, 1, 6, 7 }, // Croatian/Latin/Croatia
- { 27, 7, 27, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 111,7 , 111,7 , 404,9 , 413,19 , 37,5 , 8,10 , 4431,49 , 4480,94 , 4574,39 , 4431,49 , 4613,98 , 4574,39 , 2017,28 , 2045,58 , 2103,14 , 2017,28 , 2045,58 , 2117,14 , 0,2 , 0,2 , {66,65,77}, 0,0 , 2557,106 , 25,5 , 4,0 , 582,8 , 598,19 , 2, 1, 1, 6, 7 }, // Croatian/Latin/BosniaAndHerzegowina
- { 28, 7, 57, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 128,7 , 128,7 , 302,8 , 432,18 , 205,4 , 209,9 , 4711,48 , 4759,82 , 4841,24 , 4711,48 , 4865,84 , 158,27 , 2131,21 , 2152,49 , 2201,14 , 2131,21 , 2152,49 , 2201,14 , 0,2 , 0,2 , {67,90,75}, 143,2 , 2663,56 , 25,5 , 4,0 , 617,7 , 624,15 , 2, 1, 1, 6, 7 }, // Czech/Latin/CzechRepublic
- { 29, 7, 58, 44, 46, 44, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 135,8 , 135,8 , 27,8 , 450,23 , 130,5 , 135,10 , 4949,48 , 4997,84 , 134,24 , 5081,59 , 4997,84 , 134,24 , 2215,28 , 2243,51 , 2294,14 , 2308,35 , 2243,51 , 2294,14 , 0,2 , 0,2 , {68,75,75}, 145,2 , 2719,42 , 25,5 , 4,0 , 639,5 , 644,7 , 2, 1, 1, 6, 7 }, // Danish/Latin/Denmark
- { 30, 7, 151, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 473,8 , 99,16 , 37,5 , 8,10 , 5140,48 , 5188,88 , 134,24 , 5276,59 , 5188,88 , 134,24 , 2343,21 , 2364,59 , 2423,14 , 2343,21 , 2364,59 , 2423,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2761,19 , 14,5 , 19,6 , 651,10 , 661,9 , 2, 1, 1, 6, 7 }, // Dutch/Latin/Netherlands
- { 30, 7, 12, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 473,8 , 99,16 , 37,5 , 8,10 , 5140,48 , 5188,88 , 134,24 , 5276,59 , 5188,88 , 134,24 , 2343,21 , 2364,59 , 2423,14 , 2343,21 , 2364,59 , 2423,14 , 0,2 , 0,2 , {65,87,71}, 147,4 , 2780,55 , 14,5 , 19,6 , 651,10 , 670,5 , 2, 1, 1, 6, 7 }, // Dutch/Latin/Aruba
- { 30, 7, 21, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 481,7 , 99,16 , 37,5 , 8,10 , 5140,48 , 5188,88 , 134,24 , 5276,59 , 5188,88 , 134,24 , 2343,21 , 2364,59 , 2423,14 , 2343,21 , 2364,59 , 2423,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2761,19 , 25,5 , 4,0 , 675,6 , 681,6 , 2, 1, 1, 6, 7 }, // Dutch/Latin/Belgium
- { 30, 7, 152, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 473,8 , 99,16 , 37,5 , 8,10 , 5140,48 , 5188,88 , 134,24 , 5276,59 , 5188,88 , 134,24 , 2343,21 , 2364,59 , 2423,14 , 2343,21 , 2364,59 , 2423,14 , 0,2 , 0,2 , {0,0,0}, 0,0 , 2835,0 , 14,5 , 19,6 , 651,10 , 687,7 , 2, 1, 1, 6, 7 }, // Dutch/Latin/CuraSao
- { 30, 7, 202, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 473,8 , 99,16 , 37,5 , 8,10 , 5140,48 , 5188,88 , 134,24 , 5276,59 , 5188,88 , 134,24 , 2343,21 , 2364,59 , 2423,14 , 2343,21 , 2364,59 , 2423,14 , 0,2 , 0,2 , {83,82,68}, 0,0 , 2835,24 , 14,5 , 19,6 , 651,10 , 694,8 , 2, 1, 1, 6, 7 }, // Dutch/Latin/Suriname
- { 30, 7, 256, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 473,8 , 99,16 , 37,5 , 8,10 , 5140,48 , 5188,88 , 134,24 , 5276,59 , 5188,88 , 134,24 , 2343,21 , 2364,59 , 2423,14 , 2343,21 , 2364,59 , 2423,14 , 0,2 , 0,2 , {0,0,0}, 0,0 , 2835,0 , 14,5 , 19,6 , 651,10 , 702,12 , 2, 1, 1, 6, 7 }, // Dutch/Latin/SintMaarten
- { 31, 7, 225, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 8,6 , 714,12 , 726,13 , 2, 1, 7, 6, 7 }, // English/Latin/UnitedStates
- { 31, 3, 225, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 5335,80 , 5415,154 , 5569,36 , 5335,80 , 5415,154 , 5569,36 , 2437,49 , 2486,85 , 2571,21 , 2437,49 , 2486,85 , 2571,21 , 72,4 , 71,4 , {85,83,68}, 151,3 , 0,7 , 14,5 , 4,0 , 739,10 , 749,25 , 2, 1, 7, 6, 7 }, // English/Deseret/UnitedStates
- { 31, 7, 4, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 8,6 , 774,7 , 781,14 , 2, 1, 7, 6, 7 }, // English/Latin/AmericanSamoa
- { 31, 7, 9, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,67,68}, 154,3 , 2894,71 , 4,4 , 8,6 , 774,7 , 795,19 , 2, 1, 7, 6, 7 }, // English/Latin/AntiguaAndBarbuda
- { 31, 7, 13, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 481,7 , 10,17 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {65,85,68}, 12,1 , 2965,59 , 4,4 , 4,0 , 814,18 , 832,9 , 2, 1, 7, 6, 7 }, // English/Latin/Australia
- { 31, 7, 16, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {66,83,68}, 0,0 , 3024,53 , 4,4 , 8,6 , 774,7 , 841,7 , 2, 1, 7, 6, 7 }, // English/Latin/Bahamas
- { 31, 7, 19, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {66,66,68}, 12,1 , 3077,56 , 4,4 , 8,6 , 774,7 , 848,8 , 2, 1, 1, 6, 7 }, // English/Latin/Barbados
- { 31, 7, 21, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 27,8 , 99,16 , 37,5 , 218,24 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {69,85,82}, 127,1 , 2761,19 , 25,5 , 4,0 , 774,7 , 856,7 , 2, 1, 1, 6, 7 }, // English/Latin/Belgium
- { 31, 7, 22, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 27,8 , 494,12 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {66,90,68}, 12,1 , 3133,47 , 4,4 , 4,0 , 774,7 , 863,6 , 2, 1, 7, 6, 7 }, // English/Latin/Belize
- { 31, 7, 24, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {66,77,68}, 12,1 , 3180,53 , 4,4 , 8,6 , 774,7 , 869,7 , 2, 1, 1, 6, 7 }, // English/Latin/Bermuda
- { 31, 7, 28, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 27,8 , 82,17 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {66,87,80}, 157,1 , 3233,50 , 4,4 , 4,0 , 774,7 , 876,8 , 2, 1, 7, 6, 7 }, // English/Latin/Botswana
- { 31, 7, 37, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,65,70}, 33,4 , 3283,50 , 4,4 , 8,6 , 774,7 , 884,8 , 0, 0, 1, 6, 7 }, // English/Latin/Cameroon
- { 31, 7, 38, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {67,65,68}, 12,1 , 3333,53 , 4,4 , 8,6 , 892,16 , 908,6 , 2, 1, 7, 6, 7 }, // English/Latin/Canada
- { 31, 7, 40, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {75,89,68}, 0,0 , 3386,71 , 4,4 , 8,6 , 774,7 , 914,14 , 2, 1, 1, 6, 7 }, // English/Latin/CaymanIslands
- { 31, 7, 60, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,67,68}, 154,3 , 2894,71 , 4,4 , 8,6 , 774,7 , 928,8 , 2, 1, 7, 6, 7 }, // English/Latin/Dominica
- { 31, 7, 72, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {70,74,68}, 0,0 , 3457,47 , 4,4 , 8,6 , 774,7 , 936,4 , 2, 1, 1, 6, 7 }, // English/Latin/Fiji
- { 31, 7, 75, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 141,10 , 10,17 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {71,66,80}, 158,1 , 3504,47 , 4,4 , 4,0 , 774,7 , 940,8 , 2, 1, 1, 6, 7 }, // English/Latin/Guernsey
- { 31, 7, 80, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {71,77,68}, 0,0 , 3551,50 , 4,4 , 8,6 , 774,7 , 948,6 , 2, 1, 1, 6, 7 }, // English/Latin/Gambia
- { 31, 7, 83, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {71,72,83}, 0,0 , 3601,47 , 4,4 , 8,6 , 774,7 , 954,5 , 2, 1, 1, 6, 7 }, // English/Latin/Ghana
- { 31, 7, 84, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 141,10 , 10,17 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {71,73,80}, 0,0 , 3648,53 , 4,4 , 4,0 , 774,7 , 959,9 , 2, 1, 1, 6, 7 }, // English/Latin/Gibraltar
- { 31, 7, 87, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,67,68}, 154,3 , 2894,71 , 4,4 , 8,6 , 774,7 , 968,7 , 2, 1, 1, 6, 7 }, // English/Latin/Grenada
- { 31, 7, 89, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 8,6 , 774,7 , 975,4 , 2, 1, 7, 6, 7 }, // English/Latin/Guam
- { 31, 7, 93, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {71,89,68}, 0,0 , 3701,56 , 4,4 , 8,6 , 774,7 , 979,6 , 0, 0, 1, 6, 7 }, // English/Latin/Guyana
- { 31, 7, 97, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 266,6 , 203,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {72,75,68}, 12,1 , 3757,56 , 4,4 , 8,6 , 774,7 , 985,19 , 2, 1, 7, 6, 7 }, // English/Latin/HongKong
- { 31, 7, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 27,8 , 99,16 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {73,78,82}, 118,1 , 3813,44 , 14,5 , 4,0 , 774,7 , 1004,5 , 2, 1, 7, 7, 7 }, // English/Latin/India
- { 31, 7, 104, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 141,10 , 99,16 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 66,4 , 65,4 , {69,85,82}, 127,1 , 2761,19 , 4,4 , 4,0 , 774,7 , 1009,7 , 2, 1, 7, 6, 7 }, // English/Latin/Ireland
- { 31, 7, 107, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 266,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {74,77,68}, 12,1 , 3857,53 , 4,4 , 4,0 , 774,7 , 1016,7 , 2, 1, 7, 6, 7 }, // English/Latin/Jamaica
- { 31, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {75,69,83}, 0,0 , 3910,53 , 4,4 , 8,6 , 774,7 , 1023,5 , 2, 1, 7, 6, 7 }, // English/Latin/Kenya
- { 31, 7, 112, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {65,85,68}, 159,2 , 2965,59 , 4,4 , 8,6 , 774,7 , 1028,8 , 2, 1, 1, 6, 7 }, // English/Latin/Kiribati
- { 31, 7, 120, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {90,65,82}, 0,0 , 3963,61 , 4,4 , 8,6 , 774,7 , 1036,7 , 2, 1, 1, 6, 7 }, // English/Latin/Lesotho
- { 31, 7, 121, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {76,82,68}, 0,0 , 4024,53 , 4,4 , 8,6 , 774,7 , 1043,7 , 2, 1, 1, 6, 7 }, // English/Latin/Liberia
- { 31, 7, 128, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {77,71,65}, 0,0 , 4077,54 , 4,4 , 8,6 , 774,7 , 1050,10 , 0, 0, 1, 6, 7 }, // English/Latin/Madagascar
- { 31, 7, 129, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {77,87,75}, 0,0 , 4131,53 , 4,4 , 8,6 , 774,7 , 1060,6 , 2, 1, 1, 6, 7 }, // English/Latin/Malawi
- { 31, 7, 133, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 141,10 , 10,17 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {69,85,82}, 127,1 , 2761,19 , 4,4 , 4,0 , 774,7 , 1066,5 , 2, 1, 7, 6, 7 }, // English/Latin/Malta
- { 31, 7, 134, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 8,6 , 774,7 , 1071,16 , 2, 1, 7, 6, 7 }, // English/Latin/MarshallIslands
- { 31, 7, 137, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {77,85,82}, 0,0 , 4184,53 , 4,4 , 8,6 , 774,7 , 1087,9 , 0, 0, 1, 6, 7 }, // English/Latin/Mauritius
- { 31, 7, 140, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 8,6 , 774,7 , 1096,10 , 2, 1, 1, 6, 7 }, // English/Latin/Micronesia
- { 31, 7, 148, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {78,65,68}, 12,1 , 4237,53 , 4,4 , 4,0 , 774,7 , 1106,7 , 2, 1, 1, 6, 7 }, // English/Latin/Namibia
- { 31, 7, 154, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 481,7 , 10,17 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {78,90,68}, 12,1 , 4290,62 , 4,4 , 4,0 , 774,7 , 1113,11 , 2, 1, 7, 6, 7 }, // English/Latin/NewZealand
- { 31, 7, 157, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {78,71,78}, 0,0 , 4352,50 , 4,4 , 8,6 , 774,7 , 1124,7 , 2, 1, 1, 6, 7 }, // English/Latin/Nigeria
- { 31, 7, 160, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 8,6 , 774,7 , 1131,24 , 2, 1, 1, 6, 7 }, // English/Latin/NorthernMarianaIslands
- { 31, 7, 163, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 27,8 , 99,16 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {80,75,82}, 161,1 , 4402,53 , 14,5 , 4,0 , 774,7 , 1155,8 , 0, 0, 7, 6, 7 }, // English/Latin/Pakistan
- { 31, 7, 164, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 8,6 , 774,7 , 1163,5 , 2, 1, 1, 6, 7 }, // English/Latin/Palau
- { 31, 7, 167, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {80,71,75}, 0,0 , 4455,73 , 4,4 , 8,6 , 774,7 , 1168,16 , 2, 1, 1, 6, 7 }, // English/Latin/PapuaNewGuinea
- { 31, 7, 170, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {80,72,80}, 162,1 , 4528,42 , 4,4 , 8,6 , 774,7 , 1184,11 , 2, 1, 7, 6, 7 }, // English/Latin/Philippines
- { 31, 7, 174, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 8,6 , 774,7 , 1195,11 , 2, 1, 7, 6, 7 }, // English/Latin/PuertoRico
- { 31, 7, 180, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,67,68}, 154,3 , 2894,71 , 4,4 , 8,6 , 774,7 , 1206,21 , 2, 1, 1, 6, 7 }, // English/Latin/SaintKittsAndNevis
- { 31, 7, 181, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,67,68}, 154,3 , 2894,71 , 4,4 , 8,6 , 774,7 , 1227,11 , 2, 1, 1, 6, 7 }, // English/Latin/SaintLucia
- { 31, 7, 182, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,67,68}, 154,3 , 2894,71 , 4,4 , 8,6 , 774,7 , 1238,32 , 2, 1, 1, 6, 7 }, // English/Latin/SaintVincentAndTheGrenadines
- { 31, 7, 183, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {87,83,84}, 0,0 , 4570,40 , 4,4 , 8,6 , 774,7 , 1270,5 , 2, 1, 7, 6, 7 }, // English/Latin/Samoa
- { 31, 7, 188, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {83,67,82}, 0,0 , 4610,59 , 4,4 , 8,6 , 774,7 , 1275,10 , 2, 1, 1, 6, 7 }, // English/Latin/Seychelles
- { 31, 7, 189, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {83,76,76}, 0,0 , 4669,68 , 4,4 , 8,6 , 774,7 , 1285,12 , 0, 0, 1, 6, 7 }, // English/Latin/SierraLeone
- { 31, 7, 190, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 266,6 , 203,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {83,71,68}, 12,1 , 4737,56 , 4,4 , 8,6 , 774,7 , 1297,9 , 2, 1, 7, 6, 7 }, // English/Latin/Singapore
- { 31, 7, 193, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {83,66,68}, 0,0 , 4793,74 , 4,4 , 8,6 , 774,7 , 1306,15 , 2, 1, 1, 6, 7 }, // English/Latin/SolomonIslands
- { 31, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 506,10 , 82,17 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 3963,61 , 4,4 , 8,6 , 774,7 , 1321,12 , 2, 1, 7, 6, 7 }, // English/Latin/SouthAfrica
- { 31, 7, 204, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {83,90,76}, 0,0 , 4867,53 , 4,4 , 8,6 , 774,7 , 1333,9 , 2, 1, 1, 6, 7 }, // English/Latin/Swaziland
- { 31, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {84,90,83}, 0,0 , 4920,62 , 4,4 , 8,6 , 774,7 , 1342,8 , 0, 0, 1, 6, 7 }, // English/Latin/Tanzania
- { 31, 7, 214, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {84,79,80}, 0,0 , 4982,49 , 4,4 , 8,6 , 774,7 , 1350,5 , 2, 1, 1, 6, 7 }, // English/Latin/Tonga
- { 31, 7, 215, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {84,84,68}, 12,1 , 5031,86 , 4,4 , 4,0 , 774,7 , 1355,19 , 2, 1, 7, 6, 7 }, // English/Latin/TrinidadAndTobago
- { 31, 7, 219, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 8,6 , 774,7 , 1374,24 , 2, 1, 1, 6, 7 }, // English/Latin/TurksAndCaicosIslands
- { 31, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,71,88}, 0,0 , 5117,56 , 4,4 , 8,6 , 774,7 , 1398,6 , 0, 0, 1, 6, 7 }, // English/Latin/Uganda
- { 31, 7, 224, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 141,10 , 10,17 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {71,66,80}, 158,1 , 3504,47 , 4,4 , 4,0 , 1404,15 , 1419,14 , 2, 1, 1, 6, 7 }, // English/Latin/UnitedKingdom
- { 31, 7, 226, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 8,6 , 774,7 , 1433,21 , 2, 1, 7, 6, 7 }, // English/Latin/UnitedStatesMinorOutlyingIslands
- { 31, 7, 229, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {86,85,86}, 0,0 , 5173,44 , 4,4 , 8,6 , 774,7 , 1454,7 , 0, 0, 1, 6, 7 }, // English/Latin/Vanuatu
- { 31, 7, 233, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 8,6 , 774,7 , 1461,22 , 2, 1, 1, 6, 7 }, // English/Latin/BritishVirginIslands
- { 31, 7, 234, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 8,6 , 774,7 , 1483,19 , 2, 1, 7, 6, 7 }, // English/Latin/UnitedStatesVirginIslands
- { 31, 7, 239, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {90,77,75}, 0,0 , 5217,50 , 4,4 , 8,6 , 774,7 , 1502,6 , 0, 0, 1, 6, 7 }, // English/Latin/Zambia
- { 31, 7, 240, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 334,8 , 82,17 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 2859,35 , 4,4 , 4,0 , 774,7 , 1508,8 , 2, 1, 7, 6, 7 }, // English/Latin/Zimbabwe
- { 31, 7, 251, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 141,10 , 10,17 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {71,66,80}, 158,1 , 3504,47 , 4,4 , 4,0 , 774,7 , 1516,11 , 2, 1, 1, 6, 7 }, // English/Latin/IsleOfMan
- { 31, 7, 252, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 153,9 , 153,9 , 141,10 , 10,17 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 76,2 , 75,2 , {71,66,80}, 158,1 , 3504,47 , 4,4 , 4,0 , 774,7 , 1527,6 , 2, 1, 1, 6, 7 }, // English/Latin/Jersey
- { 31, 7, 254, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 143,10 , 153,9 , 488,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {83,83,80}, 0,0 , 5267,68 , 4,4 , 8,6 , 774,7 , 1533,11 , 2, 1, 1, 6, 7 }, // English/Latin/SouthSudan
- { 33, 7, 68, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 162,8 , 162,8 , 302,8 , 432,18 , 205,4 , 242,9 , 5605,59 , 5664,91 , 5755,24 , 5605,59 , 5664,91 , 5755,24 , 2592,14 , 2606,63 , 2592,14 , 2592,14 , 2606,63 , 2592,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 5335,20 , 0,4 , 37,6 , 1544,5 , 1549,5 , 2, 1, 1, 6, 7 }, // Estonian/Latin/Estonia
- { 34, 7, 71, 44, 46, 59, 37, 48, 8722, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 135,8 , 135,8 , 473,8 , 82,17 , 37,5 , 8,10 , 5779,48 , 5827,83 , 134,24 , 5779,48 , 5827,83 , 134,24 , 2669,28 , 2697,74 , 2771,14 , 2669,28 , 2697,74 , 2771,14 , 0,2 , 0,2 , {68,75,75}, 145,2 , 5355,42 , 4,4 , 43,5 , 1554,8 , 1562,7 , 2, 1, 1, 6, 7 }, // Faroese/Latin/FaroeIslands
- { 36, 7, 73, 44, 160, 59, 37, 48, 45, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 162,8 , 162,8 , 516,8 , 524,17 , 145,4 , 149,9 , 5910,69 , 5979,105 , 6084,24 , 6108,129 , 6108,129 , 6084,24 , 2785,21 , 2806,67 , 2873,14 , 2785,21 , 2887,81 , 2873,14 , 78,3 , 77,3 , {69,85,82}, 127,1 , 5397,20 , 25,5 , 4,0 , 1569,5 , 1574,5 , 2, 1, 1, 6, 7 }, // Finnish/Latin/Finland
- { 37, 7, 74, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 30,7 , 1579,8 , 1587,6 , 2, 1, 1, 6, 7 }, // French/Latin/France
- { 37, 7, 3, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {68,90,68}, 0,0 , 5417,51 , 25,5 , 30,7 , 1579,8 , 1593,7 , 2, 1, 6, 4, 5 }, // French/Latin/Algeria
- { 37, 7, 21, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 481,7 , 99,16 , 37,5 , 251,23 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 30,7 , 1579,8 , 1600,8 , 2, 1, 1, 6, 7 }, // French/Latin/Belgium
- { 37, 7, 23, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,79,70}, 163,3 , 5468,59 , 25,5 , 30,7 , 1579,8 , 1608,5 , 0, 0, 1, 6, 7 }, // French/Latin/Benin
- { 37, 7, 34, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,79,70}, 163,3 , 5468,59 , 25,5 , 30,7 , 1579,8 , 1613,12 , 0, 0, 1, 6, 7 }, // French/Latin/BurkinaFaso
- { 37, 7, 35, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {66,73,70}, 166,3 , 5527,53 , 25,5 , 30,7 , 1579,8 , 1625,7 , 0, 0, 1, 6, 7 }, // French/Latin/Burundi
- { 37, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,65,70}, 33,4 , 5580,56 , 25,5 , 30,7 , 1579,8 , 1632,8 , 0, 0, 1, 6, 7 }, // French/Latin/Cameroon
- { 37, 7, 38, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 170,8 , 170,8 , 115,8 , 99,16 , 37,5 , 218,24 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {67,65,68}, 12,1 , 5636,54 , 25,5 , 30,7 , 1640,17 , 908,6 , 2, 1, 7, 6, 7 }, // French/Latin/Canada
- { 37, 7, 41, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,65,70}, 33,4 , 5580,56 , 25,5 , 30,7 , 1579,8 , 1657,25 , 0, 0, 1, 6, 7 }, // French/Latin/CentralAfricanRepublic
- { 37, 7, 42, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,65,70}, 33,4 , 5580,56 , 25,5 , 30,7 , 1579,8 , 1682,5 , 0, 0, 1, 6, 7 }, // French/Latin/Chad
- { 37, 7, 48, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {75,77,70}, 169,2 , 5690,51 , 25,5 , 30,7 , 1579,8 , 1687,7 , 0, 0, 1, 6, 7 }, // French/Latin/Comoros
- { 37, 7, 49, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {67,68,70}, 0,0 , 5741,53 , 25,5 , 30,7 , 1579,8 , 1694,32 , 2, 1, 1, 6, 7 }, // French/Latin/CongoKinshasa
- { 37, 7, 50, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,65,70}, 33,4 , 5580,56 , 25,5 , 30,7 , 1579,8 , 1726,17 , 0, 0, 1, 6, 7 }, // French/Latin/CongoBrazzaville
- { 37, 7, 53, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,79,70}, 163,3 , 5468,59 , 25,5 , 30,7 , 1579,8 , 1743,13 , 0, 0, 1, 6, 7 }, // French/Latin/IvoryCoast
- { 37, 7, 59, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {68,74,70}, 5,3 , 5794,57 , 25,5 , 30,7 , 1579,8 , 1756,8 , 0, 0, 6, 6, 7 }, // French/Latin/Djibouti
- { 37, 7, 66, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,65,70}, 33,4 , 5580,56 , 25,5 , 30,7 , 1579,8 , 1764,18 , 0, 0, 1, 6, 7 }, // French/Latin/EquatorialGuinea
- { 37, 7, 76, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 30,7 , 1579,8 , 1782,16 , 2, 1, 1, 6, 7 }, // French/Latin/FrenchGuiana
- { 37, 7, 77, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,80,70}, 171,4 , 5851,35 , 25,5 , 30,7 , 1579,8 , 1798,19 , 0, 0, 1, 6, 7 }, // French/Latin/FrenchPolynesia
- { 37, 7, 79, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,65,70}, 33,4 , 5580,56 , 25,5 , 30,7 , 1579,8 , 1817,5 , 0, 0, 1, 6, 7 }, // French/Latin/Gabon
- { 37, 7, 88, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 30,7 , 1579,8 , 1822,10 , 2, 1, 1, 6, 7 }, // French/Latin/Guadeloupe
- { 37, 7, 91, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {71,78,70}, 175,2 , 5886,48 , 25,5 , 30,7 , 1579,8 , 1832,6 , 0, 0, 1, 6, 7 }, // French/Latin/Guinea
- { 37, 7, 94, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {72,84,71}, 0,0 , 5934,57 , 25,5 , 30,7 , 1579,8 , 1838,5 , 2, 1, 1, 6, 7 }, // French/Latin/Haiti
- { 37, 7, 125, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 30,7 , 1579,8 , 1843,10 , 2, 1, 1, 6, 7 }, // French/Latin/Luxembourg
- { 37, 7, 128, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {77,71,65}, 0,0 , 5991,54 , 25,5 , 30,7 , 1579,8 , 1050,10 , 0, 0, 1, 6, 7 }, // French/Latin/Madagascar
- { 37, 7, 132, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,79,70}, 163,3 , 5468,59 , 25,5 , 30,7 , 1579,8 , 1853,4 , 0, 0, 1, 6, 7 }, // French/Latin/Mali
- { 37, 7, 135, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 30,7 , 1579,8 , 1857,10 , 2, 1, 1, 6, 7 }, // French/Latin/Martinique
- { 37, 7, 136, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {77,82,79}, 0,0 , 6045,66 , 25,5 , 30,7 , 1579,8 , 1867,10 , 0, 0, 1, 6, 7 }, // French/Latin/Mauritania
- { 37, 7, 137, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {77,85,82}, 0,0 , 6111,63 , 25,5 , 30,7 , 1579,8 , 1877,7 , 0, 0, 1, 6, 7 }, // French/Latin/Mauritius
- { 37, 7, 138, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 30,7 , 1579,8 , 1884,7 , 2, 1, 1, 6, 7 }, // French/Latin/Mayotte
- { 37, 7, 142, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 30,7 , 1579,8 , 1891,6 , 2, 1, 1, 6, 7 }, // French/Latin/Monaco
- { 37, 7, 145, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {77,65,68}, 0,0 , 6174,54 , 25,5 , 30,7 , 1579,8 , 1897,5 , 2, 1, 6, 5, 6 }, // French/Latin/Morocco
- { 37, 7, 153, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,80,70}, 171,4 , 5851,35 , 25,5 , 30,7 , 1579,8 , 1902,18 , 0, 0, 1, 6, 7 }, // French/Latin/NewCaledonia
- { 37, 7, 156, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,79,70}, 163,3 , 5468,59 , 25,5 , 30,7 , 1579,8 , 1920,5 , 0, 0, 1, 6, 7 }, // French/Latin/Niger
- { 37, 7, 176, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 30,7 , 1579,8 , 1925,7 , 2, 1, 1, 6, 7 }, // French/Latin/Reunion
- { 37, 7, 179, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {82,87,70}, 0,0 , 6228,50 , 25,5 , 30,7 , 1579,8 , 1932,6 , 0, 0, 1, 6, 7 }, // French/Latin/Rwanda
- { 37, 7, 187, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,79,70}, 163,3 , 5468,59 , 25,5 , 30,7 , 1579,8 , 1938,7 , 0, 0, 1, 6, 7 }, // French/Latin/Senegal
- { 37, 7, 188, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {83,67,82}, 0,0 , 6278,71 , 25,5 , 30,7 , 1579,8 , 1275,10 , 2, 1, 1, 6, 7 }, // French/Latin/Seychelles
- { 37, 7, 206, 46, 39, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 170,8 , 170,8 , 302,8 , 10,17 , 37,5 , 274,14 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {67,72,70}, 177,3 , 6349,45 , 14,5 , 48,5 , 1945,15 , 1960,6 , 2, 5, 1, 6, 7 }, // French/Latin/Switzerland
- { 37, 7, 207, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {83,89,80}, 0,0 , 6394,51 , 25,5 , 30,7 , 1579,8 , 1966,5 , 0, 0, 6, 5, 6 }, // French/Latin/Syria
- { 37, 7, 212, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {88,79,70}, 163,3 , 5468,59 , 25,5 , 30,7 , 1579,8 , 1971,4 , 0, 0, 1, 6, 7 }, // French/Latin/Togo
- { 37, 7, 216, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {84,78,68}, 0,0 , 6445,51 , 25,5 , 30,7 , 1579,8 , 1975,7 , 3, 0, 7, 5, 6 }, // French/Latin/Tunisia
- { 37, 7, 229, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {86,85,86}, 180,2 , 6496,51 , 25,5 , 30,7 , 1579,8 , 1454,7 , 0, 0, 1, 6, 7 }, // French/Latin/Vanuatu
- { 37, 7, 244, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 30,7 , 1579,8 , 1982,16 , 2, 1, 1, 6, 7 }, // French/Latin/Saint Barthelemy
- { 37, 7, 245, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 170,8 , 170,8 , 27,8 , 99,16 , 37,5 , 8,10 , 6237,63 , 6300,85 , 134,24 , 6237,63 , 6300,85 , 134,24 , 2968,35 , 3003,52 , 3055,14 , 2968,35 , 3003,52 , 3055,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 30,7 , 1579,8 , 1998,31 , 2, 1, 1, 6, 7 }, // French/Latin/Saint Martin
- { 39, 7, 224, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 178,11 , 189,10 , 141,10 , 10,17 , 37,5 , 8,10 , 6385,61 , 6446,142 , 6588,36 , 6385,61 , 6446,142 , 6588,36 , 3069,28 , 3097,69 , 3166,14 , 3069,28 , 3097,69 , 3166,14 , 0,2 , 0,2 , {71,66,80}, 158,1 , 6547,22 , 4,4 , 8,6 , 2029,8 , 2037,22 , 2, 1, 1, 6, 7 }, // Gaelic/Latin/UnitedKingdom
- { 40, 7, 197, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 199,7 , 199,7 , 27,8 , 82,17 , 37,5 , 8,10 , 6624,48 , 6672,87 , 6759,24 , 6624,48 , 6672,87 , 6759,24 , 3180,28 , 3208,49 , 3257,14 , 3180,28 , 3208,49 , 3257,14 , 66,4 , 65,4 , {69,85,82}, 127,1 , 6569,20 , 4,4 , 8,6 , 2059,6 , 2065,6 , 2, 1, 1, 6, 7 }, // Galician/Latin/Spain
- { 41, 15, 81, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 206,8 , 206,8 , 221,8 , 248,18 , 37,5 , 8,10 , 6783,48 , 6831,98 , 6929,24 , 6783,48 , 6831,98 , 6929,24 , 3271,28 , 3299,62 , 3361,14 , 3271,28 , 3299,62 , 3361,14 , 0,2 , 0,2 , {71,69,76}, 0,0 , 6589,19 , 25,5 , 4,0 , 2071,7 , 2078,10 , 2, 1, 1, 6, 7 }, // Georgian/Georgian/Georgia
- { 42, 7, 82, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 214,9 , 214,9 , 302,8 , 432,18 , 37,5 , 8,10 , 6953,48 , 7001,83 , 134,24 , 7084,59 , 7001,83 , 134,24 , 3375,21 , 3396,60 , 3456,14 , 3470,28 , 3396,60 , 3456,14 , 81,5 , 80,6 , {69,85,82}, 127,1 , 6608,19 , 25,5 , 4,0 , 2088,7 , 2095,11 , 2, 1, 1, 6, 7 }, // German/Latin/Germany
- { 42, 7, 14, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 214,9 , 214,9 , 302,8 , 541,19 , 37,5 , 8,10 , 7143,48 , 7001,83 , 134,24 , 7191,58 , 7249,83 , 134,24 , 3375,21 , 3396,60 , 3456,14 , 3470,28 , 3396,60 , 3456,14 , 81,5 , 80,6 , {69,85,82}, 127,1 , 6608,19 , 14,5 , 4,0 , 2106,24 , 2130,10 , 2, 1, 1, 6, 7 }, // German/Latin/Austria
- { 42, 7, 21, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 214,9 , 214,9 , 302,8 , 432,18 , 37,5 , 8,10 , 6953,48 , 7001,83 , 134,24 , 7084,59 , 7001,83 , 134,24 , 3375,21 , 3396,60 , 3456,14 , 3470,28 , 3396,60 , 3456,14 , 81,5 , 80,6 , {69,85,82}, 127,1 , 6608,19 , 25,5 , 4,0 , 2088,7 , 2140,7 , 2, 1, 1, 6, 7 }, // German/Latin/Belgium
- { 42, 7, 123, 46, 39, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 214,9 , 214,9 , 302,8 , 432,18 , 37,5 , 8,10 , 6953,48 , 7001,83 , 134,24 , 7084,59 , 7001,83 , 134,24 , 3375,21 , 3396,60 , 3456,14 , 3470,28 , 3396,60 , 3456,14 , 81,5 , 80,6 , {67,72,70}, 0,0 , 6627,58 , 14,5 , 4,0 , 2088,7 , 2147,13 , 2, 5, 1, 6, 7 }, // German/Latin/Liechtenstein
- { 42, 7, 125, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 214,9 , 214,9 , 302,8 , 432,18 , 37,5 , 8,10 , 6953,48 , 7001,83 , 134,24 , 7084,59 , 7001,83 , 134,24 , 3375,21 , 3396,60 , 3456,14 , 3470,28 , 3396,60 , 3456,14 , 81,5 , 80,6 , {69,85,82}, 127,1 , 6608,19 , 25,5 , 4,0 , 2088,7 , 2160,9 , 2, 1, 1, 6, 7 }, // German/Latin/Luxembourg
- { 42, 7, 206, 46, 39, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 214,9 , 214,9 , 302,8 , 432,18 , 37,5 , 8,10 , 6953,48 , 7001,83 , 134,24 , 7084,59 , 7001,83 , 134,24 , 3375,21 , 3396,60 , 3456,14 , 3470,28 , 3396,60 , 3456,14 , 81,5 , 80,6 , {67,72,70}, 0,0 , 6627,58 , 14,5 , 48,5 , 2169,21 , 2190,7 , 2, 5, 1, 6, 7 }, // German/Latin/Switzerland
- { 43, 16, 85, 44, 46, 44, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 223,9 , 223,9 , 266,6 , 10,17 , 18,7 , 25,12 , 7332,50 , 7382,115 , 7497,24 , 7521,50 , 7571,115 , 7497,24 , 3498,28 , 3526,55 , 3581,14 , 3498,28 , 3526,55 , 3581,14 , 86,4 , 86,4 , {69,85,82}, 127,1 , 6685,19 , 25,5 , 4,0 , 2197,8 , 2205,6 , 2, 1, 1, 6, 7 }, // Greek/Greek/Greece
- { 43, 16, 56, 44, 46, 44, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 223,9 , 223,9 , 266,6 , 10,17 , 18,7 , 25,12 , 7332,50 , 7382,115 , 7497,24 , 7521,50 , 7571,115 , 7497,24 , 3498,28 , 3526,55 , 3581,14 , 3498,28 , 3526,55 , 3581,14 , 86,4 , 86,4 , {69,85,82}, 127,1 , 6685,19 , 4,4 , 4,0 , 2197,8 , 2211,6 , 2, 1, 1, 6, 7 }, // Greek/Greek/Cyprus
- { 44, 7, 86, 44, 46, 59, 37, 48, 8722, 43, 101, 187, 171, 8250, 8249, 0,6 , 0,6 , 232,11 , 232,11 , 72,10 , 82,17 , 18,7 , 25,12 , 4949,48 , 7686,96 , 134,24 , 4949,48 , 7686,96 , 134,24 , 3595,28 , 3623,98 , 3721,14 , 3595,28 , 3623,98 , 3721,14 , 0,2 , 0,2 , {68,75,75}, 145,2 , 6704,59 , 4,4 , 43,5 , 2217,11 , 2228,16 , 2, 1, 1, 6, 7 }, // Greenlandic/Latin/Greenland
- { 46, 17, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 243,9 , 243,9 , 560,7 , 203,18 , 288,8 , 296,13 , 7782,64 , 7846,87 , 7933,31 , 7964,67 , 8031,87 , 7933,31 , 3735,32 , 3767,53 , 3820,19 , 3735,32 , 3767,53 , 3820,19 , 0,2 , 0,2 , {73,78,82}, 118,1 , 6763,20 , 4,4 , 8,6 , 2244,7 , 2251,4 , 2, 1, 7, 7, 7 }, // Gujarati/Gujarati/India
- { 47, 7, 157, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 266,6 , 203,18 , 37,5 , 8,10 , 8118,48 , 8166,85 , 8251,24 , 8118,48 , 8166,85 , 8251,24 , 3839,21 , 3860,52 , 3912,14 , 3839,21 , 3860,52 , 3912,14 , 0,2 , 0,2 , {78,71,78}, 182,1 , 6783,12 , 14,5 , 4,0 , 2255,5 , 2260,8 , 2, 1, 1, 6, 7 }, // Hausa/Latin/Nigeria
- { 47, 7, 83, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 266,6 , 203,18 , 37,5 , 8,10 , 8118,48 , 8166,85 , 8251,24 , 8118,48 , 8166,85 , 8251,24 , 3839,21 , 3860,52 , 3912,14 , 3839,21 , 3860,52 , 3912,14 , 0,2 , 0,2 , {71,72,83}, 0,0 , 0,7 , 14,5 , 4,0 , 2255,5 , 2268,4 , 2, 1, 1, 6, 7 }, // Hausa/Latin/Ghana
- { 47, 7, 156, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 266,6 , 203,18 , 37,5 , 8,10 , 8118,48 , 8166,85 , 8251,24 , 8118,48 , 8166,85 , 8251,24 , 3839,21 , 3860,52 , 3912,14 , 3839,21 , 3860,52 , 3912,14 , 0,2 , 0,2 , {88,79,70}, 163,3 , 6795,36 , 14,5 , 4,0 , 2255,5 , 2272,5 , 0, 0, 1, 6, 7 }, // Hausa/Latin/Niger
- { 48, 18, 105, 46, 44, 59, 37, 48, 45, 43, 101, 34, 34, 39, 39, 0,6 , 0,6 , 252,6 , 252,6 , 27,8 , 567,18 , 37,5 , 8,10 , 8275,58 , 8333,72 , 158,27 , 8405,48 , 8333,72 , 158,27 , 3926,46 , 3972,65 , 4037,19 , 3926,46 , 3972,65 , 4056,21 , 90,6 , 90,5 , {73,76,83}, 49,1 , 6831,54 , 25,5 , 4,0 , 2277,5 , 2282,5 , 2, 1, 7, 5, 6 }, // Hebrew/Hebrew/Israel
- { 49, 13, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 258,9 , 267,8 , 585,6 , 10,17 , 18,7 , 25,12 , 8453,75 , 8453,75 , 8528,30 , 8453,75 , 8453,75 , 8528,30 , 4077,38 , 4115,57 , 4172,19 , 4077,38 , 4115,57 , 4172,19 , 96,9 , 95,7 , {73,78,82}, 118,1 , 6885,19 , 14,5 , 4,0 , 2287,6 , 2293,4 , 2, 1, 7, 7, 7 }, // Hindi/Devanagari/India
- { 50, 7, 98, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8221, 187, 171, 0,6 , 0,6 , 275,8 , 275,8 , 591,11 , 602,19 , 205,4 , 209,9 , 8558,64 , 8622,98 , 8720,25 , 8558,64 , 8622,98 , 8745,25 , 4191,19 , 4210,52 , 4262,17 , 4191,19 , 4210,52 , 4262,17 , 105,3 , 102,3 , {72,85,70}, 183,2 , 6904,20 , 25,5 , 4,0 , 2297,6 , 2303,12 , 0, 0, 1, 6, 7 }, // Hungarian/Latin/Hungary
- { 51, 7, 99, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 135,8 , 135,8 , 516,8 , 432,18 , 37,5 , 8,10 , 8770,48 , 8818,82 , 8900,24 , 8770,48 , 8818,82 , 8924,24 , 4279,28 , 4307,81 , 4388,14 , 4279,28 , 4307,81 , 4402,14 , 108,4 , 105,4 , {73,83,75}, 145,2 , 6924,49 , 4,4 , 8,6 , 2315,8 , 2323,6 , 0, 0, 1, 6, 7 }, // Icelandic/Latin/Iceland
- { 52, 7, 101, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 283,10 , 293,9 , 27,8 , 123,18 , 130,5 , 135,10 , 8948,48 , 8996,87 , 134,24 , 8948,48 , 8996,87 , 134,24 , 4416,28 , 4444,43 , 4487,14 , 4416,28 , 4444,43 , 4487,14 , 0,2 , 0,2 , {73,68,82}, 185,2 , 6973,23 , 4,4 , 4,0 , 2329,16 , 2345,9 , 0, 0, 7, 6, 7 }, // Indonesian/Latin/Indonesia
- { 57, 7, 104, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 99,16 , 37,5 , 8,10 , 9083,62 , 9145,107 , 9252,24 , 9083,62 , 9145,107 , 9252,24 , 4501,37 , 4538,75 , 4613,14 , 4501,37 , 4538,75 , 4613,14 , 66,4 , 65,4 , {69,85,82}, 127,1 , 6996,11 , 4,4 , 4,0 , 2354,7 , 2361,4 , 2, 1, 7, 6, 7 }, // Irish/Latin/Ireland
- { 58, 7, 106, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 302,8 , 199,7 , 27,8 , 99,16 , 37,5 , 8,10 , 9276,48 , 9324,94 , 9418,24 , 9276,48 , 9442,94 , 9418,24 , 4627,28 , 4655,57 , 4712,14 , 4627,28 , 4726,57 , 4712,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2761,19 , 14,5 , 4,0 , 2365,8 , 2373,6 , 2, 1, 1, 6, 7 }, // Italian/Latin/Italy
- { 58, 7, 184, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 302,8 , 199,7 , 27,8 , 99,16 , 37,5 , 8,10 , 9276,48 , 9324,94 , 9418,24 , 9276,48 , 9442,94 , 9418,24 , 4627,28 , 4655,57 , 4712,14 , 4627,28 , 4726,57 , 4712,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2761,19 , 14,5 , 4,0 , 2365,8 , 2379,10 , 2, 1, 1, 6, 7 }, // Italian/Latin/SanMarino
- { 58, 7, 206, 46, 39, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 302,8 , 199,7 , 302,8 , 10,17 , 37,5 , 274,14 , 9276,48 , 9324,94 , 9418,24 , 9276,48 , 9442,94 , 9418,24 , 4627,28 , 4655,57 , 4712,14 , 4627,28 , 4726,57 , 4712,14 , 0,2 , 0,2 , {67,72,70}, 0,0 , 7007,53 , 14,5 , 48,5 , 2365,8 , 2389,8 , 2, 5, 1, 6, 7 }, // Italian/Latin/Switzerland
- { 59, 19, 108, 46, 44, 59, 37, 48, 45, 43, 101, 12300, 12301, 12302, 12303, 118,5 , 118,5 , 118,5 , 118,5 , 506,10 , 369,13 , 205,4 , 309,10 , 4354,39 , 4354,39 , 158,27 , 4354,39 , 4354,39 , 158,27 , 4783,14 , 4797,28 , 4783,14 , 4783,14 , 4797,28 , 4783,14 , 112,2 , 109,2 , {74,80,89}, 137,1 , 7060,10 , 4,4 , 4,0 , 2397,3 , 2400,2 , 0, 0, 7, 6, 7 }, // Japanese/Japanese/Japan
- { 61, 21, 100, 46, 44, 59, 37, 48, 45, 43, 3208, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 310,12 , 322,11 , 585,6 , 99,16 , 288,8 , 296,13 , 9536,91 , 9627,86 , 9713,31 , 9536,91 , 9627,86 , 9744,31 , 4825,28 , 4853,53 , 4906,19 , 4825,28 , 4853,53 , 4906,19 , 0,2 , 0,2 , {73,78,82}, 118,1 , 7070,20 , 4,4 , 8,6 , 2402,5 , 2407,4 , 2, 1, 7, 7, 7 }, // Kannada/Kannada/India
- { 62, 1, 100, 1643, 1644, 1563, 1642, 1776, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 488,6 , 35,18 , 18,7 , 25,12 , 9775,72 , 9775,72 , 9847,24 , 9775,72 , 9775,72 , 9847,24 , 4925,54 , 4979,56 , 5035,14 , 4925,54 , 4979,56 , 5035,14 , 0,2 , 0,2 , {73,78,82}, 118,1 , 7090,23 , 14,5 , 4,0 , 2411,5 , 2416,10 , 2, 1, 7, 7, 7 }, // Kashmiri/Arabic/India
- { 63, 2, 110, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 302,8 , 621,22 , 37,5 , 8,10 , 9871,61 , 9932,83 , 158,27 , 9871,61 , 9932,83 , 158,27 , 5049,28 , 5077,54 , 708,14 , 5049,28 , 5077,54 , 708,14 , 0,2 , 0,2 , {75,90,84}, 187,1 , 7113,24 , 25,5 , 4,0 , 2426,10 , 2436,9 , 2, 1, 1, 6, 7 }, // Kazakh/Cyrillic/Kazakhstan
- { 64, 7, 179, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 221,8 , 248,18 , 37,5 , 8,10 , 10015,60 , 10075,101 , 158,27 , 10015,60 , 10075,101 , 158,27 , 5131,35 , 5166,84 , 708,14 , 5131,35 , 5166,84 , 708,14 , 0,2 , 0,2 , {82,87,70}, 188,2 , 0,7 , 14,5 , 4,0 , 2445,11 , 1932,6 , 0, 0, 1, 6, 7 }, // Kinyarwanda/Latin/Rwanda
- { 65, 2, 116, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 0,6 , 0,6 , 302,8 , 621,22 , 37,5 , 8,10 , 10176,60 , 10236,80 , 158,27 , 10316,59 , 10375,80 , 158,27 , 5250,28 , 5278,57 , 708,14 , 5335,28 , 5363,57 , 708,14 , 0,2 , 0,2 , {75,71,83}, 190,3 , 0,7 , 14,5 , 4,0 , 2456,6 , 2462,10 , 2, 1, 1, 6, 7 }, // Kirghiz/Cyrillic/Kyrgyzstan
- { 66, 22, 114, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 333,7 , 333,7 , 643,9 , 652,16 , 319,7 , 326,13 , 10455,39 , 10455,39 , 10455,39 , 10455,39 , 10455,39 , 10455,39 , 5420,14 , 5434,28 , 5420,14 , 5420,14 , 5434,28 , 5420,14 , 114,2 , 111,2 , {75,82,87}, 193,1 , 7137,13 , 4,4 , 8,6 , 2472,3 , 2475,4 , 0, 0, 7, 6, 7 }, // Korean/Korean/SouthKorea
- { 66, 22, 113, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 333,7 , 333,7 , 643,9 , 652,16 , 319,7 , 326,13 , 10455,39 , 10455,39 , 10455,39 , 10455,39 , 10455,39 , 10455,39 , 5420,14 , 5434,28 , 5420,14 , 5420,14 , 5434,28 , 5420,14 , 114,2 , 111,2 , {75,80,87}, 0,0 , 7150,23 , 4,4 , 8,6 , 2472,3 , 2479,14 , 0, 0, 1, 6, 7 }, // Korean/Korean/NorthKorea
- { 68, 7, 35, 44, 46, 59, 37, 48, 45, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 10494,60 , 10554,106 , 158,27 , 10494,60 , 10554,106 , 158,27 , 5462,34 , 5496,89 , 708,14 , 5462,34 , 5496,89 , 708,14 , 116,5 , 113,5 , {66,73,70}, 166,3 , 7173,27 , 0,4 , 4,0 , 2493,8 , 2501,8 , 0, 0, 1, 6, 7 }, // Rundi/Latin/Burundi
- { 69, 23, 117, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 668,18 , 205,4 , 339,24 , 10660,62 , 10722,75 , 158,27 , 10797,61 , 10722,75 , 158,27 , 5585,23 , 5608,57 , 5665,18 , 5683,24 , 5608,57 , 708,14 , 121,8 , 118,8 , {76,65,75}, 194,1 , 7200,14 , 4,4 , 48,5 , 2509,3 , 2512,9 , 0, 0, 7, 6, 7 }, // Lao/Lao/Laos
- { 71, 7, 118, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 340,8 , 340,8 , 302,8 , 686,26 , 37,5 , 8,10 , 10858,65 , 10923,101 , 134,24 , 11024,65 , 11089,101 , 134,24 , 5707,21 , 5728,72 , 5800,14 , 5707,21 , 5814,72 , 5800,14 , 129,14 , 126,11 , {76,86,76}, 195,2 , 7214,59 , 4,4 , 8,6 , 2521,8 , 2529,7 , 2, 1, 1, 6, 7 }, // Latvian/Latin/Latvia
- { 72, 7, 49, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 348,9 , 348,9 , 334,8 , 99,16 , 37,5 , 8,10 , 11190,48 , 11238,203 , 11441,24 , 11190,48 , 11238,203 , 11441,24 , 5886,28 , 5914,100 , 6014,14 , 5886,28 , 5914,100 , 6014,14 , 143,8 , 137,6 , {67,68,70}, 197,2 , 7273,23 , 25,5 , 4,0 , 2536,7 , 2543,29 , 2, 1, 1, 6, 7 }, // Lingala/Latin/CongoKinshasa
- { 72, 7, 6, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 348,9 , 348,9 , 334,8 , 99,16 , 37,5 , 8,10 , 11190,48 , 11238,203 , 11441,24 , 11190,48 , 11238,203 , 11441,24 , 5886,28 , 5914,100 , 6014,14 , 5886,28 , 5914,100 , 6014,14 , 143,8 , 137,6 , {65,79,65}, 0,0 , 7296,23 , 25,5 , 4,0 , 2536,7 , 2572,6 , 2, 1, 1, 6, 7 }, // Lingala/Latin/Angola
- { 72, 7, 41, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 348,9 , 348,9 , 334,8 , 99,16 , 37,5 , 8,10 , 11190,48 , 11238,203 , 11441,24 , 11190,48 , 11238,203 , 11441,24 , 5886,28 , 5914,100 , 6014,14 , 5886,28 , 5914,100 , 6014,14 , 143,8 , 137,6 , {88,65,70}, 199,5 , 7319,23 , 25,5 , 4,0 , 2536,7 , 2578,26 , 0, 0, 1, 6, 7 }, // Lingala/Latin/CentralAfricanRepublic
- { 72, 7, 50, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 348,9 , 348,9 , 334,8 , 99,16 , 37,5 , 8,10 , 11190,48 , 11238,203 , 11441,24 , 11190,48 , 11238,203 , 11441,24 , 5886,28 , 5914,100 , 6014,14 , 5886,28 , 5914,100 , 6014,14 , 143,8 , 137,6 , {88,65,70}, 199,5 , 7319,23 , 25,5 , 4,0 , 2536,7 , 2604,5 , 0, 0, 1, 6, 7 }, // Lingala/Latin/CongoBrazzaville
- { 73, 7, 124, 44, 160, 59, 37, 48, 8211, 43, 101, 8222, 8220, 8222, 8220, 0,6 , 0,6 , 357,8 , 357,8 , 72,10 , 712,27 , 37,5 , 8,10 , 11465,70 , 11535,96 , 11631,24 , 11465,70 , 11535,96 , 11631,24 , 6028,21 , 6049,89 , 6138,14 , 6028,21 , 6049,89 , 6138,14 , 151,9 , 143,6 , {76,84,76}, 204,2 , 7342,62 , 25,5 , 4,0 , 2609,8 , 2617,7 , 2, 1, 1, 6, 7 }, // Lithuanian/Latin/Lithuania
- { 74, 2, 127, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 0,6 , 0,6 , 739,7 , 123,18 , 37,5 , 8,10 , 11655,63 , 11718,85 , 11803,24 , 11655,63 , 11718,85 , 11803,24 , 6152,34 , 6186,54 , 1520,14 , 6152,34 , 6186,54 , 1520,14 , 160,10 , 149,8 , {77,75,68}, 0,0 , 7404,23 , 14,5 , 4,0 , 2624,10 , 2634,10 , 2, 1, 1, 6, 7 }, // Macedonian/Cyrillic/Macedonia
- { 75, 7, 128, 46, 44, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 11827,48 , 11875,92 , 134,24 , 11827,48 , 11875,92 , 134,24 , 6240,34 , 6274,60 , 6334,14 , 6240,34 , 6274,60 , 6334,14 , 0,2 , 0,2 , {77,71,65}, 0,0 , 7427,13 , 4,4 , 4,0 , 2644,8 , 2652,12 , 0, 0, 1, 6, 7 }, // Malagasy/Latin/Madagascar
- { 76, 7, 130, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 283,10 , 293,9 , 481,7 , 10,17 , 18,7 , 25,12 , 11967,49 , 12016,82 , 12098,24 , 11967,49 , 12016,82 , 12098,24 , 6348,28 , 6376,43 , 6419,14 , 6348,28 , 6376,43 , 6419,14 , 170,2 , 157,3 , {77,89,82}, 206,2 , 7440,23 , 4,4 , 8,6 , 2664,13 , 2677,8 , 2, 1, 1, 6, 7 }, // Malay/Latin/Malaysia
- { 76, 7, 32, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 283,10 , 293,9 , 481,7 , 494,12 , 18,7 , 25,12 , 11967,49 , 12016,82 , 12098,24 , 11967,49 , 12016,82 , 12098,24 , 6348,28 , 6376,43 , 6419,14 , 6348,28 , 6376,43 , 6419,14 , 170,2 , 157,3 , {66,78,68}, 12,1 , 7463,19 , 14,5 , 4,0 , 2664,13 , 2685,6 , 2, 1, 1, 6, 7 }, // Malay/Latin/Brunei
- { 76, 7, 190, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 283,10 , 293,9 , 481,7 , 10,17 , 18,7 , 25,12 , 11967,49 , 12016,82 , 12098,24 , 11967,49 , 12016,82 , 12098,24 , 6348,28 , 6376,43 , 6419,14 , 6348,28 , 6376,43 , 6419,14 , 170,2 , 157,3 , {83,71,68}, 0,0 , 7482,22 , 4,4 , 8,6 , 2664,13 , 2691,9 , 2, 1, 7, 6, 7 }, // Malay/Latin/Singapore
- { 77, 24, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 365,13 , 378,12 , 27,8 , 746,18 , 18,7 , 25,12 , 12122,62 , 12184,87 , 12271,31 , 12122,62 , 12184,87 , 12271,31 , 6433,41 , 6474,70 , 6544,22 , 6433,41 , 6474,70 , 6544,22 , 0,2 , 0,2 , {73,78,82}, 118,1 , 7504,40 , 0,4 , 4,0 , 2700,6 , 2706,6 , 2, 1, 7, 7, 7 }, // Malayalam/Malayalam/India
- { 78, 7, 133, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 390,8 , 398,7 , 141,10 , 764,23 , 37,5 , 8,10 , 12302,48 , 12350,86 , 12436,24 , 12302,48 , 12350,86 , 12436,24 , 6566,28 , 6594,63 , 6657,14 , 6566,28 , 6594,63 , 6657,14 , 172,2 , 160,2 , {69,85,82}, 127,1 , 7544,11 , 4,4 , 4,0 , 2712,5 , 1066,5 , 2, 1, 7, 6, 7 }, // Maltese/Latin/Malta
- { 80, 13, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 405,9 , 405,9 , 585,6 , 99,16 , 363,7 , 370,12 , 12460,66 , 12526,86 , 12612,32 , 12460,66 , 12526,86 , 12612,32 , 6671,32 , 6703,53 , 4172,19 , 6671,32 , 6703,53 , 4172,19 , 0,2 , 0,2 , {73,78,82}, 118,1 , 7555,19 , 4,4 , 8,6 , 2717,5 , 2293,4 , 2, 1, 7, 7, 7 }, // Marathi/Devanagari/India
- { 84, 13, 150, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 12644,56 , 12700,85 , 12785,27 , 12644,56 , 12700,85 , 12785,27 , 6756,33 , 6789,54 , 6843,14 , 6756,33 , 6789,54 , 6843,14 , 174,14 , 162,14 , {78,80,82}, 208,4 , 7574,52 , 14,5 , 4,0 , 2722,6 , 2728,5 , 2, 1, 7, 6, 7 }, // Nepali/Devanagari/Nepal
- { 84, 13, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 12644,56 , 12700,85 , 12785,27 , 12644,56 , 12812,80 , 12785,27 , 6756,33 , 6789,54 , 6843,14 , 6756,33 , 6857,54 , 6843,14 , 96,9 , 95,7 , {73,78,82}, 118,1 , 7626,49 , 14,5 , 4,0 , 2722,6 , 2293,4 , 2, 1, 7, 7, 7 }, // Nepali/Devanagari/India
- { 85, 7, 161, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8216, 8217, 0,6 , 0,6 , 135,8 , 135,8 , 302,8 , 524,17 , 37,5 , 382,16 , 5779,48 , 12892,83 , 134,24 , 12975,59 , 12892,83 , 134,24 , 6911,28 , 2243,51 , 2294,14 , 2308,35 , 2243,51 , 2294,14 , 0,2 , 0,2 , {78,79,75}, 145,2 , 7675,44 , 14,5 , 4,0 , 2733,12 , 2745,5 , 2, 1, 1, 6, 7 }, // NorwegianBokmal/Latin/Norway
- { 87, 26, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 585,6 , 10,17 , 18,7 , 25,12 , 13034,89 , 13034,89 , 13123,32 , 13034,89 , 13034,89 , 13123,32 , 6939,33 , 6972,54 , 7026,18 , 6939,33 , 6972,54 , 7026,18 , 76,2 , 75,2 , {73,78,82}, 118,1 , 7719,11 , 14,5 , 4,0 , 2750,5 , 2755,4 , 2, 1, 7, 7, 7 }, // Oriya/Oriya/India
- { 88, 1, 1, 1643, 1644, 1563, 1642, 1776, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 179,8 , 787,20 , 205,4 , 398,11 , 13155,68 , 13155,68 , 158,27 , 13155,68 , 13155,68 , 158,27 , 7044,49 , 7044,49 , 708,14 , 7044,49 , 7044,49 , 708,14 , 188,4 , 176,4 , {65,70,78}, 212,1 , 7730,13 , 25,5 , 4,0 , 2759,4 , 2763,9 , 0, 0, 6, 4, 5 }, // Pashto/Arabic/Afghanistan
- { 89, 1, 102, 1643, 1644, 1563, 1642, 1776, 8722, 43, 101, 171, 187, 8249, 8250, 414,7 , 414,7 , 43,8 , 51,7 , 179,8 , 99,16 , 205,4 , 398,11 , 13223,70 , 13223,70 , 13293,24 , 13317,74 , 13317,74 , 13293,24 , 7044,49 , 7044,49 , 7093,14 , 7044,49 , 7044,49 , 7093,14 , 192,9 , 180,8 , {73,82,82}, 213,1 , 7743,17 , 53,5 , 58,7 , 2772,5 , 2777,5 , 0, 0, 6, 4, 5 }, // Persian/Arabic/Iran
- { 89, 1, 1, 1643, 1644, 1563, 1642, 1776, 8722, 43, 101, 171, 187, 8249, 8250, 414,7 , 414,7 , 43,8 , 51,7 , 179,8 , 99,16 , 205,4 , 398,11 , 13223,70 , 13223,70 , 13391,24 , 13415,64 , 13479,68 , 13293,24 , 7044,49 , 7044,49 , 7093,14 , 7044,49 , 7044,49 , 7093,14 , 192,9 , 180,8 , {65,70,78}, 212,1 , 7760,23 , 53,5 , 58,7 , 2782,3 , 2763,9 , 0, 0, 6, 4, 5 }, // Persian/Arabic/Afghanistan
- { 90, 7, 172, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8221, 171, 187, 0,6 , 0,6 , 111,7 , 111,7 , 807,10 , 10,17 , 37,5 , 8,10 , 13547,48 , 13595,97 , 13692,24 , 13547,48 , 13716,99 , 13692,24 , 7107,34 , 7141,59 , 7200,14 , 7107,34 , 7141,59 , 7200,14 , 0,2 , 0,2 , {80,76,78}, 214,2 , 7783,77 , 25,5 , 30,7 , 2785,6 , 2791,6 , 2, 1, 1, 6, 7 }, // Polish/Latin/Poland
- { 91, 7, 30, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 199,7 , 199,7 , 27,8 , 817,27 , 37,5 , 8,10 , 13815,48 , 13863,89 , 134,24 , 13815,48 , 13863,89 , 134,24 , 7214,28 , 7242,79 , 7321,14 , 7214,28 , 7242,79 , 7321,14 , 0,2 , 0,2 , {66,82,76}, 216,2 , 7860,54 , 4,4 , 8,6 , 2797,19 , 2816,6 , 2, 1, 7, 6, 7 }, // Portuguese/Latin/Brazil
- { 91, 7, 6, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 199,7 , 199,7 , 27,8 , 817,27 , 37,5 , 8,10 , 13952,48 , 14000,89 , 134,24 , 13952,48 , 14000,89 , 134,24 , 7214,28 , 7335,79 , 7321,14 , 7214,28 , 7335,79 , 7321,14 , 0,2 , 0,2 , {65,79,65}, 218,2 , 7914,54 , 25,5 , 4,0 , 2822,9 , 2831,6 , 2, 1, 1, 6, 7 }, // Portuguese/Latin/Angola
- { 91, 7, 39, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 199,7 , 199,7 , 27,8 , 817,27 , 37,5 , 8,10 , 13952,48 , 14000,89 , 134,24 , 13952,48 , 14000,89 , 134,24 , 7214,28 , 7335,79 , 7321,14 , 7214,28 , 7335,79 , 7321,14 , 0,2 , 0,2 , {67,86,69}, 0,0 , 7968,69 , 25,5 , 4,0 , 2822,9 , 2837,10 , 2, 1, 1, 6, 7 }, // Portuguese/Latin/CapeVerde
- { 91, 7, 62, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 199,7 , 199,7 , 27,8 , 817,27 , 37,5 , 8,10 , 13952,48 , 14000,89 , 134,24 , 13952,48 , 14000,89 , 134,24 , 7214,28 , 7335,79 , 7321,14 , 7214,28 , 7335,79 , 7321,14 , 0,2 , 0,2 , {85,83,68}, 151,3 , 8037,81 , 25,5 , 4,0 , 2822,9 , 2847,11 , 2, 1, 1, 6, 7 }, // Portuguese/Latin/EastTimor
- { 91, 7, 92, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 199,7 , 199,7 , 27,8 , 817,27 , 37,5 , 8,10 , 13952,48 , 14000,89 , 134,24 , 13952,48 , 14000,89 , 134,24 , 7214,28 , 7335,79 , 7321,14 , 7214,28 , 7335,79 , 7321,14 , 0,2 , 0,2 , {88,79,70}, 163,3 , 8118,62 , 25,5 , 4,0 , 2822,9 , 2858,12 , 0, 0, 1, 6, 7 }, // Portuguese/Latin/GuineaBissau
- { 91, 7, 126, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 199,7 , 199,7 , 27,8 , 817,27 , 37,5 , 8,10 , 13952,48 , 14000,89 , 134,24 , 13952,48 , 14000,89 , 134,24 , 7214,28 , 7335,79 , 7321,14 , 7214,28 , 7335,79 , 7321,14 , 0,2 , 0,2 , {77,79,80}, 0,0 , 8180,53 , 25,5 , 4,0 , 2822,9 , 2870,39 , 2, 1, 7, 6, 7 }, // Portuguese/Latin/Macau
- { 91, 7, 146, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 199,7 , 199,7 , 27,8 , 817,27 , 37,5 , 8,10 , 13952,48 , 14000,89 , 134,24 , 13952,48 , 14000,89 , 134,24 , 7214,28 , 7335,79 , 7321,14 , 7214,28 , 7335,79 , 7321,14 , 0,2 , 0,2 , {77,90,78}, 220,3 , 8233,72 , 25,5 , 4,0 , 2822,9 , 2909,10 , 2, 1, 7, 6, 7 }, // Portuguese/Latin/Mozambique
- { 91, 7, 173, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 199,7 , 199,7 , 27,8 , 817,27 , 37,5 , 8,10 , 13952,48 , 14000,89 , 134,24 , 13952,48 , 14000,89 , 134,24 , 7214,28 , 7335,79 , 7321,14 , 7214,28 , 7335,79 , 7321,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 8305,20 , 25,5 , 4,0 , 2919,17 , 2936,8 , 2, 1, 1, 6, 7 }, // Portuguese/Latin/Portugal
- { 91, 7, 185, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 199,7 , 199,7 , 27,8 , 817,27 , 37,5 , 8,10 , 13952,48 , 14000,89 , 134,24 , 13952,48 , 14000,89 , 134,24 , 7214,28 , 7335,79 , 7321,14 , 7214,28 , 7335,79 , 7321,14 , 0,2 , 0,2 , {83,84,68}, 223,2 , 8325,92 , 25,5 , 4,0 , 2822,9 , 2944,19 , 0, 0, 1, 6, 7 }, // Portuguese/Latin/SaoTomeAndPrincipe
- { 92, 4, 100, 46, 44, 59, 37, 48, 45, 43, 101, 39, 39, 34, 34, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 123,18 , 18,7 , 25,12 , 14089,68 , 14089,68 , 14157,27 , 14089,68 , 14089,68 , 14157,27 , 7414,38 , 7452,55 , 7507,23 , 7414,38 , 7452,55 , 7507,23 , 201,11 , 188,11 , {73,78,82}, 118,1 , 8417,12 , 14,5 , 4,0 , 2963,6 , 2969,4 , 2, 1, 7, 7, 7 }, // Punjabi/Gurmukhi/India
- { 92, 1, 163, 1643, 1644, 1563, 1642, 1776, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 123,18 , 18,7 , 25,12 , 14184,67 , 14184,67 , 158,27 , 14184,67 , 14184,67 , 158,27 , 7530,37 , 7530,37 , 708,14 , 7530,37 , 7530,37 , 708,14 , 0,2 , 0,2 , {80,75,82}, 225,1 , 8429,13 , 14,5 , 4,0 , 2973,5 , 2978,6 , 0, 0, 7, 6, 7 }, // Punjabi/Arabic/Pakistan
- { 94, 7, 206, 46, 8217, 59, 37, 48, 8722, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 0,6 , 0,6 , 473,8 , 844,28 , 37,5 , 8,10 , 14251,67 , 14318,92 , 14410,24 , 14251,67 , 14318,92 , 14410,24 , 7567,23 , 7590,56 , 7646,14 , 7567,23 , 7590,56 , 7646,14 , 76,2 , 199,2 , {67,72,70}, 0,0 , 8442,20 , 25,5 , 4,0 , 2984,9 , 2993,6 , 2, 5, 1, 6, 7 }, // Romansh/Latin/Switzerland
- { 95, 7, 177, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8221, 171, 187, 0,6 , 0,6 , 421,8 , 421,8 , 807,10 , 10,17 , 37,5 , 8,10 , 14434,60 , 14494,98 , 14592,24 , 14434,60 , 14494,98 , 14592,24 , 7660,21 , 7681,48 , 3055,14 , 7660,21 , 7681,48 , 3055,14 , 0,2 , 0,2 , {82,79,78}, 0,0 , 8462,57 , 25,5 , 4,0 , 2999,6 , 3005,7 , 2, 1, 1, 6, 7 }, // Romanian/Latin/Romania
- { 95, 7, 141, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8221, 171, 187, 0,6 , 0,6 , 421,8 , 421,8 , 807,10 , 10,17 , 37,5 , 8,10 , 14434,60 , 14494,98 , 14592,24 , 14434,60 , 14494,98 , 14592,24 , 7660,21 , 7681,48 , 3055,14 , 7660,21 , 7681,48 , 3055,14 , 0,2 , 0,2 , {77,68,76}, 0,0 , 8519,69 , 25,5 , 4,0 , 2999,6 , 3012,17 , 2, 1, 1, 6, 7 }, // Romanian/Latin/Moldova
- { 96, 2, 178, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 95,7 , 95,7 , 302,8 , 872,22 , 205,4 , 209,9 , 14616,62 , 10236,80 , 14678,24 , 14702,63 , 14765,82 , 14678,24 , 7729,21 , 7750,62 , 7812,14 , 7826,21 , 7847,62 , 7826,21 , 212,10 , 201,13 , {82,85,66}, 226,4 , 8588,89 , 25,5 , 4,0 , 3029,7 , 3036,6 , 2, 1, 1, 6, 7 }, // Russian/Cyrillic/Russia
- { 96, 2, 20, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 95,7 , 95,7 , 302,8 , 872,22 , 205,4 , 209,9 , 14616,62 , 10236,80 , 14678,24 , 14702,63 , 14765,82 , 14678,24 , 7729,21 , 7750,62 , 7812,14 , 7826,21 , 7847,62 , 7826,21 , 212,10 , 201,13 , {66,89,82}, 0,0 , 8677,94 , 25,5 , 4,0 , 3029,7 , 481,8 , 0, 0, 7, 6, 7 }, // Russian/Cyrillic/Belarus
- { 96, 2, 110, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 95,7 , 95,7 , 302,8 , 872,22 , 205,4 , 209,9 , 14616,62 , 10236,80 , 14678,24 , 14702,63 , 14765,82 , 14678,24 , 7729,21 , 7750,62 , 7812,14 , 7826,21 , 7847,62 , 7826,21 , 212,10 , 201,13 , {75,90,84}, 0,0 , 8771,83 , 25,5 , 4,0 , 3029,7 , 3042,9 , 2, 1, 1, 6, 7 }, // Russian/Cyrillic/Kazakhstan
- { 96, 2, 116, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 95,7 , 95,7 , 302,8 , 872,22 , 205,4 , 209,9 , 14616,62 , 10236,80 , 14678,24 , 14702,63 , 14765,82 , 14678,24 , 7729,21 , 7750,62 , 7812,14 , 7826,21 , 7847,62 , 7826,21 , 212,10 , 201,13 , {75,71,83}, 0,0 , 8854,81 , 25,5 , 4,0 , 3029,7 , 3051,8 , 2, 1, 1, 6, 7 }, // Russian/Cyrillic/Kyrgyzstan
- { 96, 2, 141, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 95,7 , 95,7 , 302,8 , 872,22 , 205,4 , 209,9 , 14616,62 , 10236,80 , 14678,24 , 14702,63 , 14765,82 , 14678,24 , 7729,21 , 7750,62 , 7812,14 , 7826,21 , 7847,62 , 7826,21 , 212,10 , 201,13 , {77,68,76}, 0,0 , 8935,79 , 25,5 , 4,0 , 3029,7 , 3059,7 , 2, 1, 1, 6, 7 }, // Russian/Cyrillic/Moldova
- { 96, 2, 222, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 95,7 , 95,7 , 302,8 , 872,22 , 37,5 , 8,10 , 14616,62 , 10236,80 , 14678,24 , 14702,63 , 14765,82 , 14678,24 , 7729,21 , 7750,62 , 7812,14 , 7826,21 , 7847,62 , 7826,21 , 212,10 , 201,13 , {85,65,72}, 230,1 , 9014,92 , 25,5 , 4,0 , 3029,7 , 3066,7 , 2, 1, 1, 6, 7 }, // Russian/Cyrillic/Ukraine
- { 98, 7, 41, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 14847,48 , 14895,91 , 14986,24 , 14847,48 , 14895,91 , 14986,24 , 7909,28 , 7937,66 , 8003,14 , 7909,28 , 7937,66 , 8003,14 , 222,2 , 214,2 , {88,65,70}, 33,4 , 9106,25 , 4,4 , 48,5 , 3073,5 , 3078,22 , 0, 0, 1, 6, 7 }, // Sango/Latin/CentralAfricanRepublic
- { 100, 2, 243, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 95,7 , 95,7 , 894,7 , 901,20 , 130,5 , 135,10 , 15010,48 , 15058,81 , 11803,24 , 15010,48 , 15058,81 , 11803,24 , 8017,28 , 8045,52 , 8097,14 , 8017,28 , 8045,52 , 8097,14 , 224,9 , 216,7 , {82,83,68}, 231,4 , 9131,72 , 25,5 , 4,0 , 3100,6 , 3106,6 , 0, 0, 1, 6, 7 }, // Serbian/Cyrillic/Serbia
- { 100, 2, 27, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 95,7 , 95,7 , 115,8 , 901,20 , 37,5 , 409,40 , 15010,48 , 15058,81 , 11803,24 , 15010,48 , 15139,83 , 11803,24 , 8017,28 , 8045,52 , 8097,14 , 8111,28 , 8139,54 , 8097,14 , 224,9 , 216,7 , {66,65,77}, 235,3 , 9203,196 , 25,5 , 4,0 , 3112,6 , 3118,19 , 2, 1, 1, 6, 7 }, // Serbian/Cyrillic/BosniaAndHerzegowina
- { 100, 2, 242, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 95,7 , 95,7 , 894,7 , 901,20 , 130,5 , 135,10 , 15010,48 , 15058,81 , 11803,24 , 15010,48 , 15058,81 , 11803,24 , 8017,28 , 8045,52 , 8097,14 , 8017,28 , 8045,52 , 8097,14 , 224,9 , 216,7 , {69,85,82}, 127,1 , 9399,27 , 25,5 , 4,0 , 3100,6 , 3137,9 , 2, 1, 1, 6, 7 }, // Serbian/Cyrillic/Montenegro
- { 100, 7, 27, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 111,7 , 111,7 , 894,7 , 901,20 , 130,5 , 135,10 , 15222,48 , 15270,81 , 15351,24 , 15222,48 , 15270,81 , 15351,24 , 8193,28 , 8221,54 , 2103,14 , 8193,28 , 8221,54 , 2103,14 , 233,9 , 223,7 , {66,65,77}, 238,2 , 9426,218 , 14,5 , 4,0 , 3146,6 , 598,19 , 2, 1, 1, 6, 7 }, // Serbian/Latin/BosniaAndHerzegowina
- { 100, 7, 242, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 111,7 , 111,7 , 894,7 , 901,20 , 130,5 , 135,10 , 15222,48 , 15270,81 , 15351,24 , 15222,48 , 15270,81 , 15351,24 , 8193,28 , 8221,54 , 2103,14 , 8193,28 , 8221,54 , 2103,14 , 233,9 , 223,7 , {69,85,82}, 127,1 , 9644,27 , 14,5 , 4,0 , 3146,6 , 3152,9 , 2, 1, 1, 6, 7 }, // Serbian/Latin/Montenegro
- { 100, 7, 243, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 111,7 , 111,7 , 894,7 , 901,20 , 130,5 , 135,10 , 15222,48 , 15270,81 , 15351,24 , 15222,48 , 15270,81 , 15351,24 , 8193,28 , 8221,54 , 2103,14 , 8193,28 , 8221,54 , 2103,14 , 233,9 , 223,7 , {82,83,68}, 240,4 , 9671,71 , 14,5 , 4,0 , 3146,6 , 3161,6 , 0, 0, 1, 6, 7 }, // Serbian/Latin/Serbia
- { 101, 2, 81, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 429,9 , 429,9 , 302,8 , 921,23 , 37,5 , 8,10 , 14616,62 , 15375,82 , 14678,24 , 15457,59 , 15516,86 , 14678,24 , 8275,28 , 8303,61 , 8364,14 , 8378,28 , 8406,61 , 8364,14 , 0,2 , 0,2 , {71,69,76}, 0,0 , 9742,17 , 14,5 , 4,0 , 3167,4 , 3171,11 , 2, 1, 1, 6, 7 }, // Ossetic/Cyrillic/Georgia
- { 101, 2, 178, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 429,9 , 429,9 , 302,8 , 921,23 , 37,5 , 8,10 , 14616,62 , 15375,82 , 14678,24 , 15457,59 , 15516,86 , 14678,24 , 8275,28 , 8303,61 , 8364,14 , 8378,28 , 8406,61 , 8364,14 , 0,2 , 0,2 , {82,85,66}, 0,0 , 9759,17 , 14,5 , 4,0 , 3167,4 , 3182,6 , 2, 1, 1, 6, 7 }, // Ossetic/Cyrillic/Russia
- { 102, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 15602,48 , 15650,105 , 158,27 , 15602,48 , 15650,105 , 158,27 , 8467,27 , 8494,61 , 708,14 , 8467,27 , 8494,61 , 708,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 3188,7 , 0,0 , 2, 1, 7, 6, 7 }, // Southern Sotho/Latin/SouthAfrica
- { 102, 7, 120, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 15602,48 , 15650,105 , 158,27 , 15602,48 , 15650,105 , 158,27 , 8467,27 , 8494,61 , 708,14 , 8467,27 , 8494,61 , 708,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 3188,7 , 0,0 , 2, 1, 1, 6, 7 }, // Southern Sotho/Latin/Lesotho
- { 103, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 15755,48 , 15803,117 , 158,27 , 15755,48 , 15803,117 , 158,27 , 8555,27 , 8582,64 , 708,14 , 8555,27 , 8582,64 , 708,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 3195,8 , 0,0 , 2, 1, 7, 6, 7 }, // Tswana/Latin/SouthAfrica
- { 103, 7, 28, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 15755,48 , 15803,117 , 158,27 , 15755,48 , 15803,117 , 158,27 , 8555,27 , 8582,64 , 708,14 , 8555,27 , 8582,64 , 708,14 , 0,2 , 0,2 , {66,87,80}, 0,0 , 0,7 , 4,4 , 4,0 , 3195,8 , 0,0 , 2, 1, 7, 6, 7 }, // Tswana/Latin/Botswana
- { 104, 7, 240, 46, 44, 59, 37, 48, 45, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 15920,47 , 15967,100 , 16067,24 , 15920,47 , 15967,100 , 16067,24 , 8646,32 , 8678,55 , 8733,14 , 8646,32 , 8678,55 , 8733,14 , 0,2 , 0,2 , {85,83,68}, 151,3 , 9776,22 , 4,4 , 8,6 , 3203,8 , 1508,8 , 2, 1, 7, 6, 7 }, // Shona/Latin/Zimbabwe
- { 106, 32, 198, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 506,10 , 944,17 , 449,7 , 456,13 , 16091,59 , 16150,96 , 16246,32 , 16278,61 , 16150,96 , 16246,32 , 8747,30 , 8777,62 , 8839,19 , 8747,30 , 8777,62 , 8839,19 , 242,5 , 230,4 , {76,75,82}, 244,3 , 9798,19 , 14,5 , 4,0 , 3211,5 , 3216,11 , 2, 1, 1, 6, 7 }, // Sinhala/Sinhala/SriLanka
- { 107, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 16339,48 , 16387,114 , 158,27 , 16339,48 , 16387,114 , 158,27 , 8858,27 , 8885,68 , 708,14 , 8858,27 , 8885,68 , 708,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 3227,7 , 0,0 , 2, 1, 7, 6, 7 }, // Swati/Latin/SouthAfrica
- { 107, 7, 204, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 16339,48 , 16387,114 , 158,27 , 16339,48 , 16387,114 , 158,27 , 8858,27 , 8885,68 , 708,14 , 8858,27 , 8885,68 , 708,14 , 0,2 , 0,2 , {83,90,76}, 247,1 , 0,7 , 4,4 , 4,0 , 3227,7 , 0,0 , 2, 1, 1, 6, 7 }, // Swati/Latin/Swaziland
- { 108, 7, 191, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 128,7 , 128,7 , 516,8 , 432,18 , 205,4 , 209,9 , 16501,48 , 16549,82 , 15351,24 , 16501,48 , 16549,82 , 15351,24 , 8953,21 , 8974,52 , 9026,14 , 8953,21 , 8974,52 , 9026,14 , 247,10 , 234,9 , {69,85,82}, 248,3 , 9817,28 , 25,5 , 4,0 , 3234,10 , 3244,9 , 2, 1, 1, 6, 7 }, // Slovak/Latin/Slovakia
- { 109, 7, 192, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 438,8 , 438,8 , 961,9 , 541,19 , 37,5 , 8,10 , 15222,48 , 16631,86 , 15351,24 , 16717,59 , 16631,86 , 15351,24 , 9040,28 , 9068,52 , 9120,14 , 9134,35 , 9068,52 , 9120,14 , 257,4 , 243,4 , {69,85,82}, 127,1 , 9845,28 , 4,4 , 8,6 , 3253,11 , 3264,9 , 2, 1, 1, 6, 7 }, // Slovenian/Latin/Slovenia
- { 110, 7, 194, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 53,19 , 18,7 , 25,12 , 16776,48 , 16824,189 , 17013,24 , 16776,48 , 16824,189 , 17013,24 , 9169,28 , 9197,47 , 9244,14 , 9169,28 , 9197,47 , 9244,14 , 261,3 , 247,3 , {83,79,83}, 0,0 , 9873,22 , 4,4 , 4,0 , 3273,8 , 3281,10 , 0, 0, 1, 6, 7 }, // Somali/Latin/Somalia
- { 110, 7, 59, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 53,19 , 18,7 , 25,12 , 16776,48 , 16824,189 , 17013,24 , 16776,48 , 16824,189 , 17013,24 , 9169,28 , 9197,47 , 9244,14 , 9169,28 , 9197,47 , 9244,14 , 261,3 , 247,3 , {68,74,70}, 5,3 , 9895,21 , 4,4 , 4,0 , 3273,8 , 3291,7 , 0, 0, 6, 6, 7 }, // Somali/Latin/Djibouti
- { 110, 7, 69, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 53,19 , 18,7 , 25,12 , 16776,48 , 16824,189 , 17013,24 , 16776,48 , 16824,189 , 17013,24 , 9169,28 , 9197,47 , 9244,14 , 9169,28 , 9197,47 , 9244,14 , 261,3 , 247,3 , {69,84,66}, 0,2 , 9916,22 , 4,4 , 4,0 , 3273,8 , 3298,8 , 2, 1, 7, 6, 7 }, // Somali/Latin/Ethiopia
- { 110, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 53,19 , 18,7 , 25,12 , 16776,48 , 16824,189 , 17013,24 , 16776,48 , 16824,189 , 17013,24 , 9169,28 , 9197,47 , 9244,14 , 9169,28 , 9197,47 , 9244,14 , 261,3 , 247,3 , {75,69,83}, 2,3 , 0,7 , 4,4 , 4,0 , 3273,8 , 3306,7 , 2, 1, 7, 6, 7 }, // Somali/Latin/Kenya
- { 111, 7, 197, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 9339,14 , 9258,28 , 9286,53 , 9339,14 , 66,4 , 65,4 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 4,0 , 3313,17 , 2065,6 , 2, 1, 1, 6, 7 }, // Spanish/Latin/Spain
- { 111, 7, 10, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 469,14 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {65,82,83}, 12,1 , 9938,51 , 4,4 , 4,0 , 3330,7 , 3337,9 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Argentina
- { 111, 7, 26, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {66,79,66}, 251,2 , 9989,35 , 4,4 , 4,0 , 3330,7 , 3346,7 , 2, 1, 1, 6, 7 }, // Spanish/Latin/Bolivia
- { 111, 7, 43, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 473,8 , 817,27 , 205,4 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {67,76,80}, 12,1 , 10024,45 , 4,4 , 48,5 , 3330,7 , 3353,5 , 0, 0, 1, 6, 7 }, // Spanish/Latin/Chile
- { 111, 7, 47, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 481,7 , 817,27 , 205,4 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {67,79,80}, 12,1 , 10069,54 , 4,4 , 4,0 , 3330,7 , 3358,8 , 0, 0, 7, 6, 7 }, // Spanish/Latin/Colombia
- { 111, 7, 52, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {67,82,67}, 253,1 , 10123,67 , 4,4 , 4,0 , 3330,7 , 3366,10 , 0, 0, 1, 6, 7 }, // Spanish/Latin/CostaRica
- { 111, 7, 55, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {67,85,67}, 0,0 , 10190,79 , 4,4 , 4,0 , 3330,7 , 3376,4 , 2, 1, 1, 6, 7 }, // Spanish/Latin/Cuba
- { 111, 7, 61, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {68,79,80}, 12,1 , 10269,54 , 4,4 , 4,0 , 3330,7 , 3380,20 , 2, 1, 7, 6, 7 }, // Spanish/Latin/DominicanRepublic
- { 111, 7, 63, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 205,4 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {85,83,68}, 12,1 , 10323,70 , 4,4 , 48,5 , 3330,7 , 3400,7 , 2, 1, 1, 6, 7 }, // Spanish/Latin/Ecuador
- { 111, 7, 65, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {85,83,68}, 151,3 , 10323,70 , 4,4 , 4,0 , 3330,7 , 3407,11 , 2, 1, 7, 6, 7 }, // Spanish/Latin/ElSalvador
- { 111, 7, 66, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 9339,14 , 9258,28 , 9286,53 , 9339,14 , 66,4 , 65,4 , {88,65,70}, 33,4 , 10393,53 , 4,4 , 4,0 , 3330,7 , 3418,17 , 0, 0, 1, 6, 7 }, // Spanish/Latin/EquatorialGuinea
- { 111, 7, 90, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 481,7 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {71,84,81}, 254,1 , 10446,70 , 4,4 , 4,0 , 3330,7 , 3435,9 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Guatemala
- { 111, 7, 96, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 970,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {72,78,76}, 255,1 , 10516,60 , 4,4 , 4,0 , 3330,7 , 3444,8 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Honduras
- { 111, 7, 139, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {77,88,78}, 12,1 , 10576,48 , 4,4 , 4,0 , 3330,7 , 3452,6 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Mexico
- { 111, 7, 155, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {78,73,79}, 256,2 , 10624,69 , 4,4 , 4,0 , 3330,7 , 3458,9 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Nicaragua
- { 111, 7, 166, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 187,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {80,65,66}, 258,3 , 10693,54 , 4,4 , 4,0 , 3330,7 , 3467,6 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Panama
- { 111, 7, 168, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {80,89,71}, 261,1 , 10747,61 , 14,5 , 65,6 , 3330,7 , 3473,8 , 0, 0, 7, 6, 7 }, // Spanish/Latin/Paraguay
- { 111, 7, 169, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 481,7 , 817,27 , 37,5 , 483,15 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {80,69,78}, 262,3 , 10808,62 , 4,4 , 4,0 , 3330,7 , 3481,4 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Peru
- { 111, 7, 170, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 9339,14 , 9258,28 , 9286,53 , 9339,14 , 66,4 , 65,4 , {80,72,80}, 0,0 , 10870,48 , 25,5 , 4,0 , 3330,7 , 3485,9 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Philippines
- { 111, 7, 174, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 187,8 , 817,27 , 18,7 , 25,12 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {85,83,68}, 12,1 , 10323,70 , 4,4 , 4,0 , 3330,7 , 1195,11 , 2, 1, 7, 6, 7 }, // Spanish/Latin/PuertoRico
- { 111, 7, 225, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 488,6 , 817,27 , 18,7 , 25,12 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {85,83,68}, 12,1 , 10323,70 , 4,4 , 4,0 , 3330,7 , 3494,14 , 2, 1, 7, 6, 7 }, // Spanish/Latin/UnitedStates
- { 111, 7, 227, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {85,89,85}, 12,1 , 10918,48 , 14,5 , 71,7 , 3330,7 , 3508,7 , 2, 1, 1, 6, 7 }, // Spanish/Latin/Uruguay
- { 111, 7, 231, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {86,69,70}, 265,3 , 10966,64 , 4,4 , 48,5 , 3330,7 , 3515,9 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Venezuela
- { 111, 7, 238, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 9339,14 , 9258,28 , 9286,53 , 9339,14 , 66,4 , 65,4 , {0,0,0}, 0,0 , 2835,0 , 25,5 , 4,0 , 3330,7 , 3524,14 , 2, 1, 1, 6, 7 }, // Spanish/Latin/CanaryIslands
- { 111, 7, 246, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 3055,14 , 9258,28 , 9286,53 , 3055,14 , 66,4 , 65,4 , {0,0,0}, 0,0 , 2835,0 , 4,4 , 4,0 , 3538,23 , 3561,13 , 2, 1, 1, 6, 7 }, // Spanish/Latin/LatinAmericaAndTheCaribbean
- { 111, 7, 250, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 446,7 , 446,7 , 27,8 , 817,27 , 37,5 , 8,10 , 17037,49 , 17086,89 , 17175,24 , 17199,48 , 17086,89 , 17175,24 , 9258,28 , 9286,53 , 9339,14 , 9258,28 , 9286,53 , 9339,14 , 66,4 , 65,4 , {0,0,0}, 0,0 , 2835,0 , 25,5 , 4,0 , 3330,7 , 3574,15 , 2, 1, 1, 6, 7 }, // Spanish/Latin/CeutaAndMelilla
- { 113, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 453,9 , 462,8 , 141,10 , 10,17 , 18,7 , 25,12 , 17247,48 , 17295,84 , 134,24 , 17247,48 , 17295,84 , 134,24 , 9353,22 , 9375,60 , 9435,14 , 9353,22 , 9375,60 , 9435,14 , 264,7 , 250,7 , {84,90,83}, 268,3 , 11030,27 , 4,4 , 8,6 , 3589,9 , 1342,8 , 0, 0, 1, 6, 7 }, // Swahili/Latin/Tanzania
- { 113, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 453,9 , 462,8 , 141,10 , 10,17 , 18,7 , 25,12 , 17247,48 , 17295,84 , 134,24 , 17247,48 , 17295,84 , 134,24 , 9353,22 , 9375,60 , 9435,14 , 9353,22 , 9375,60 , 9435,14 , 264,7 , 250,7 , {75,69,83}, 2,3 , 11057,24 , 4,4 , 4,0 , 3589,9 , 1023,5 , 2, 1, 7, 6, 7 }, // Swahili/Latin/Kenya
- { 113, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 453,9 , 462,8 , 141,10 , 10,17 , 18,7 , 25,12 , 17247,48 , 17295,84 , 134,24 , 17247,48 , 17295,84 , 134,24 , 9353,22 , 9375,60 , 9435,14 , 9353,22 , 9375,60 , 9435,14 , 264,7 , 250,7 , {85,71,88}, 0,0 , 11081,25 , 4,4 , 8,6 , 3589,9 , 1398,6 , 0, 0, 1, 6, 7 }, // Swahili/Latin/Uganda
- { 114, 7, 205, 44, 160, 59, 37, 48, 8722, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 470,9 , 470,9 , 72,10 , 997,30 , 37,5 , 382,16 , 4949,48 , 17379,86 , 134,24 , 4949,48 , 17379,86 , 134,24 , 9449,28 , 9477,50 , 2294,14 , 9527,29 , 9477,50 , 2294,14 , 271,2 , 257,2 , {83,69,75}, 145,2 , 11106,45 , 25,5 , 4,0 , 3598,7 , 3605,7 , 2, 1, 1, 6, 7 }, // Swedish/Latin/Sweden
- { 114, 7, 73, 44, 160, 59, 37, 48, 8722, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 470,9 , 470,9 , 72,10 , 997,30 , 37,5 , 382,16 , 4949,48 , 17379,86 , 134,24 , 4949,48 , 17379,86 , 134,24 , 9449,28 , 9477,50 , 2294,14 , 9527,29 , 9477,50 , 2294,14 , 271,2 , 257,2 , {69,85,82}, 127,1 , 11151,19 , 25,5 , 4,0 , 3598,7 , 3612,7 , 2, 1, 1, 6, 7 }, // Swedish/Latin/Finland
- { 114, 7, 248, 44, 160, 59, 37, 48, 8722, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 470,9 , 470,9 , 72,10 , 997,30 , 37,5 , 382,16 , 4949,48 , 17379,86 , 134,24 , 4949,48 , 17379,86 , 134,24 , 9449,28 , 9477,50 , 2294,14 , 9527,29 , 9477,50 , 2294,14 , 271,2 , 257,2 , {69,85,82}, 127,1 , 11151,19 , 25,5 , 4,0 , 3598,7 , 3619,5 , 2, 1, 1, 6, 7 }, // Swedish/Latin/AlandIslands
- { 116, 2, 209, 46, 44, 59, 37, 48, 45, 43, 101, 171, 187, 171, 8222, 0,6 , 0,6 , 0,6 , 0,6 , 221,8 , 248,18 , 37,5 , 8,10 , 17465,48 , 17513,71 , 158,27 , 17465,48 , 17513,71 , 158,27 , 9556,28 , 9584,55 , 708,14 , 9556,28 , 9584,55 , 708,14 , 0,2 , 0,2 , {84,74,83}, 190,3 , 11170,13 , 14,5 , 4,0 , 3624,6 , 3630,10 , 2, 1, 1, 6, 7 }, // Tajik/Cyrillic/Tajikistan
- { 117, 27, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 479,13 , 479,13 , 585,6 , 203,18 , 18,7 , 25,12 , 17584,58 , 17642,86 , 17728,31 , 17584,58 , 17759,86 , 17728,31 , 9639,20 , 9659,49 , 9639,20 , 9639,20 , 9659,49 , 9639,20 , 0,2 , 0,2 , {73,78,82}, 118,1 , 11183,13 , 14,5 , 4,0 , 3640,5 , 3645,7 , 2, 1, 7, 7, 7 }, // Tamil/Tamil/India
- { 117, 27, 130, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 479,13 , 479,13 , 585,6 , 203,18 , 18,7 , 25,12 , 17584,58 , 17642,86 , 17728,31 , 17584,58 , 17759,86 , 17728,31 , 9639,20 , 9659,49 , 9639,20 , 9639,20 , 9659,49 , 9639,20 , 0,2 , 0,2 , {77,89,82}, 206,2 , 11196,22 , 14,5 , 4,0 , 3640,5 , 3652,7 , 2, 1, 1, 6, 7 }, // Tamil/Tamil/Malaysia
- { 117, 27, 190, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 479,13 , 479,13 , 585,6 , 203,18 , 18,7 , 25,12 , 17584,58 , 17642,86 , 17728,31 , 17584,58 , 17759,86 , 17728,31 , 9639,20 , 9659,49 , 9639,20 , 9639,20 , 9659,49 , 9639,20 , 0,2 , 0,2 , {83,71,68}, 271,2 , 11218,24 , 14,5 , 4,0 , 3640,5 , 3659,11 , 2, 1, 7, 6, 7 }, // Tamil/Tamil/Singapore
- { 117, 27, 198, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 479,13 , 479,13 , 585,6 , 203,18 , 18,7 , 25,12 , 17584,58 , 17642,86 , 17728,31 , 17584,58 , 17759,86 , 17728,31 , 9639,20 , 9659,49 , 9639,20 , 9639,20 , 9659,49 , 9639,20 , 0,2 , 0,2 , {76,75,82}, 273,3 , 11242,20 , 14,5 , 4,0 , 3640,5 , 3670,6 , 2, 1, 1, 6, 7 }, // Tamil/Tamil/SriLanka
- { 119, 28, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 492,11 , 492,11 , 473,8 , 99,16 , 18,7 , 25,12 , 17845,66 , 17911,86 , 17997,31 , 18028,78 , 17911,86 , 18106,31 , 9708,32 , 9740,60 , 9800,18 , 9708,32 , 9740,60 , 9800,18 , 0,2 , 0,2 , {73,78,82}, 118,1 , 11262,26 , 4,4 , 8,6 , 3676,6 , 3682,9 , 2, 1, 7, 7, 7 }, // Telugu/Telugu/India
- { 120, 30, 211, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 503,5 , 503,5 , 508,8 , 516,7 , 266,6 , 1027,19 , 37,5 , 498,28 , 18137,63 , 18200,98 , 18137,63 , 18137,63 , 18200,98 , 18298,62 , 9818,23 , 9841,68 , 9818,23 , 9818,23 , 9841,68 , 9818,23 , 273,10 , 259,10 , {84,72,66}, 276,1 , 11288,13 , 4,4 , 8,6 , 3691,3 , 3691,3 , 2, 1, 7, 6, 7 }, // Thai/Thai/Thailand
- { 121, 31, 44, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 2627,63 , 18360,158 , 158,27 , 2627,63 , 18360,158 , 158,27 , 9909,49 , 9958,77 , 10035,21 , 9909,49 , 9958,77 , 10056,22 , 283,7 , 269,8 , {67,78,89}, 277,3 , 11301,13 , 14,5 , 4,0 , 3694,8 , 3702,6 , 2, 1, 7, 6, 7 }, // Tibetan/Tibetan/China
- { 121, 31, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 2627,63 , 18360,158 , 158,27 , 2627,63 , 18360,158 , 158,27 , 9909,49 , 9958,77 , 10035,21 , 9909,49 , 9958,77 , 10056,22 , 283,7 , 269,8 , {73,78,82}, 118,1 , 11314,22 , 14,5 , 4,0 , 3694,8 , 3708,7 , 2, 1, 7, 7, 7 }, // Tibetan/Tibetan/India
- { 122, 14, 69, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 1046,23 , 18,7 , 25,12 , 18518,46 , 18564,62 , 1050,24 , 18518,46 , 18564,62 , 1050,24 , 10078,29 , 10078,29 , 10107,14 , 10078,29 , 10078,29 , 10107,14 , 290,7 , 277,7 , {69,84,66}, 0,2 , 11336,16 , 4,4 , 4,0 , 3715,4 , 103,5 , 2, 1, 7, 6, 7 }, // Tigrinya/Ethiopic/Ethiopia
- { 122, 14, 67, 46, 44, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 1069,23 , 18,7 , 25,12 , 18626,46 , 18672,54 , 1050,24 , 18626,46 , 18672,54 , 1050,24 , 10121,29 , 10121,29 , 10107,14 , 10121,29 , 10121,29 , 10107,14 , 290,7 , 277,7 , {69,82,78}, 8,3 , 0,7 , 4,4 , 4,0 , 3715,4 , 3719,4 , 2, 1, 1, 6, 7 }, // Tigrinya/Ethiopic/Eritrea
- { 123, 7, 214, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 523,8 , 523,8 , 523,8 , 523,8 , 266,6 , 99,16 , 37,5 , 8,10 , 18726,51 , 18777,87 , 18864,24 , 18726,51 , 18777,87 , 18864,24 , 10150,29 , 10179,60 , 10239,14 , 10150,29 , 10179,60 , 10239,14 , 0,2 , 0,2 , {84,79,80}, 280,2 , 0,7 , 14,5 , 4,0 , 3723,13 , 1350,5 , 2, 1, 1, 6, 7 }, // Tongan/Latin/Tonga
- { 124, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 18888,48 , 18936,122 , 158,27 , 18888,48 , 18936,122 , 158,27 , 10253,27 , 10280,72 , 708,14 , 10253,27 , 10280,72 , 708,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 3736,8 , 0,0 , 2, 1, 7, 6, 7 }, // Tsonga/Latin/SouthAfrica
- { 125, 7, 217, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 531,8 , 531,8 , 1092,9 , 1101,16 , 37,5 , 8,10 , 19058,48 , 19106,75 , 19181,24 , 19058,48 , 19106,75 , 19181,24 , 10352,28 , 10380,54 , 10434,14 , 10352,28 , 10380,54 , 10434,14 , 297,2 , 284,2 , {84,82,89}, 282,2 , 11352,18 , 25,5 , 30,7 , 3744,6 , 3750,7 , 2, 1, 1, 6, 7 }, // Turkish/Latin/Turkey
- { 125, 7, 56, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 531,8 , 531,8 , 1092,9 , 1101,16 , 37,5 , 8,10 , 19058,48 , 19106,75 , 19181,24 , 19058,48 , 19106,75 , 19181,24 , 10352,28 , 10380,54 , 10434,14 , 10352,28 , 10380,54 , 10434,14 , 297,2 , 284,2 , {69,85,82}, 127,1 , 6996,11 , 25,5 , 30,7 , 3744,6 , 3757,23 , 2, 1, 1, 6, 7 }, // Turkish/Latin/Cyprus
- { 129, 2, 222, 44, 160, 59, 37, 48, 45, 43, 1077, 171, 187, 8222, 8220, 0,6 , 0,6 , 539,8 , 539,8 , 302,8 , 1117,22 , 37,5 , 8,10 , 19205,48 , 19253,95 , 19348,24 , 19372,67 , 19439,87 , 19348,24 , 10448,21 , 10469,56 , 10525,14 , 10448,21 , 10469,56 , 10525,14 , 299,2 , 286,2 , {85,65,72}, 230,1 , 11370,49 , 25,5 , 4,0 , 3780,10 , 3790,7 , 2, 1, 1, 6, 7 }, // Ukrainian/Cyrillic/Ukraine
- { 130, 1, 163, 46, 44, 59, 37, 48, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 547,10 , 557,9 , 266,6 , 161,18 , 18,7 , 25,12 , 19526,66 , 19526,66 , 134,24 , 19526,66 , 19526,66 , 134,24 , 10539,36 , 10539,36 , 85,14 , 10539,36 , 10539,36 , 85,14 , 301,2 , 288,3 , {80,75,82}, 284,4 , 11419,21 , 4,4 , 4,0 , 3797,4 , 3801,7 , 0, 0, 7, 6, 7 }, // Urdu/Arabic/Pakistan
- { 130, 1, 100, 1643, 1644, 1563, 1642, 1776, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 547,10 , 557,9 , 266,6 , 161,18 , 18,7 , 25,12 , 19526,66 , 19526,66 , 134,24 , 19526,66 , 19526,66 , 134,24 , 10539,36 , 10539,36 , 85,14 , 10539,36 , 10539,36 , 85,14 , 301,2 , 288,3 , {73,78,82}, 118,1 , 11440,18 , 14,5 , 4,0 , 3797,4 , 3808,5 , 2, 1, 7, 7, 7 }, // Urdu/Arabic/India
- { 131, 2, 228, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 221,8 , 248,18 , 37,5 , 8,10 , 17465,48 , 17513,71 , 14678,24 , 17465,48 , 17513,71 , 14678,24 , 10575,28 , 10603,53 , 10656,14 , 10575,28 , 10603,53 , 10656,14 , 0,2 , 0,2 , {85,90,83}, 288,3 , 11458,21 , 14,5 , 4,0 , 3813,5 , 3818,10 , 0, 0, 1, 6, 7 }, // Uzbek/Cyrillic/Uzbekistan
- { 131, 1, 1, 1643, 1644, 1563, 1642, 1776, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 179,8 , 1139,33 , 205,4 , 398,11 , 19592,48 , 13479,68 , 158,27 , 19592,48 , 13479,68 , 158,27 , 10670,21 , 7044,49 , 708,14 , 10670,21 , 7044,49 , 708,14 , 0,2 , 0,2 , {65,70,78}, 212,1 , 11479,13 , 25,5 , 4,0 , 3828,6 , 2763,9 , 0, 0, 6, 4, 5 }, // Uzbek/Arabic/Afghanistan
- { 131, 7, 228, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 221,8 , 248,18 , 37,5 , 8,10 , 19640,52 , 19692,77 , 19769,24 , 19640,52 , 19692,77 , 19769,24 , 10691,34 , 10725,61 , 10786,14 , 10691,34 , 10725,61 , 10786,14 , 0,2 , 0,2 , {85,90,83}, 291,4 , 11492,23 , 14,5 , 4,0 , 3834,9 , 3843,11 , 0, 0, 1, 6, 7 }, // Uzbek/Latin/Uzbekistan
- { 132, 7, 232, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 566,8 , 566,8 , 141,10 , 1172,31 , 37,5 , 8,10 , 19793,75 , 19868,130 , 158,27 , 19793,75 , 19868,130 , 158,27 , 10800,33 , 10833,55 , 10888,21 , 10800,33 , 10833,55 , 10888,21 , 303,2 , 291,2 , {86,78,68}, 295,1 , 11515,20 , 25,5 , 4,0 , 3854,10 , 3864,8 , 0, 0, 1, 6, 7 }, // Vietnamese/Latin/Vietnam
- { 134, 7, 224, 46, 44, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 574,8 , 128,7 , 141,10 , 10,17 , 37,5 , 8,10 , 19998,53 , 20051,87 , 20138,24 , 20162,62 , 20051,87 , 20138,24 , 10909,29 , 10938,77 , 11015,14 , 11029,30 , 10938,77 , 11015,14 , 0,2 , 0,2 , {71,66,80}, 158,1 , 11535,28 , 4,4 , 4,0 , 3872,7 , 3879,12 , 2, 1, 1, 6, 7 }, // Welsh/Latin/UnitedKingdom
- { 136, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 20224,48 , 20272,91 , 158,27 , 20224,48 , 20272,91 , 158,27 , 11059,28 , 11087,61 , 708,14 , 11059,28 , 11087,61 , 708,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 3891,8 , 0,0 , 2, 1, 7, 6, 7 }, // Xhosa/Latin/SouthAfrica
- { 138, 7, 157, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 20363,73 , 20436,121 , 158,27 , 20363,73 , 20436,121 , 158,27 , 11148,44 , 11192,69 , 708,14 , 11148,44 , 11192,69 , 708,14 , 305,5 , 293,5 , {78,71,78}, 182,1 , 11563,34 , 4,4 , 8,6 , 3899,10 , 3909,18 , 2, 1, 1, 6, 7 }, // Yoruba/Latin/Nigeria
- { 140, 7, 195, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 582,9 , 591,10 , 72,10 , 82,17 , 18,7 , 25,12 , 20557,48 , 20605,104 , 134,24 , 20557,48 , 20709,90 , 134,24 , 11261,28 , 11289,68 , 11357,14 , 11261,28 , 11289,68 , 11357,14 , 310,7 , 298,8 , {90,65,82}, 11,1 , 11597,27 , 4,4 , 8,6 , 3927,7 , 3934,17 , 2, 1, 7, 6, 7 }, // Zulu/Latin/SouthAfrica
- { 141, 7, 161, 44, 160, 59, 37, 48, 8722, 43, 101, 171, 187, 8216, 8217, 0,6 , 0,6 , 135,8 , 135,8 , 302,8 , 524,17 , 37,5 , 382,16 , 5779,48 , 12892,83 , 134,24 , 12975,59 , 12892,83 , 134,24 , 11371,28 , 11399,51 , 2294,14 , 11450,28 , 11399,51 , 2294,14 , 317,9 , 306,11 , {78,79,75}, 145,2 , 11624,42 , 25,5 , 4,0 , 3951,7 , 3958,5 , 2, 1, 1, 6, 7 }, // NorwegianNynorsk/Latin/Norway
- { 142, 7, 27, 44, 46, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 111,7 , 111,7 , 1203,9 , 901,20 , 37,5 , 8,10 , 15222,48 , 20799,83 , 15351,24 , 15222,48 , 20799,83 , 15351,24 , 2017,28 , 2045,58 , 708,14 , 2017,28 , 2045,58 , 708,14 , 233,9 , 223,7 , {66,65,77}, 238,2 , 9426,218 , 14,5 , 4,0 , 3963,8 , 598,19 , 2, 1, 1, 6, 7 }, // Bosnian/Latin/BosniaAndHerzegowina
- { 142, 2, 27, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 95,7 , 95,7 , 894,7 , 901,20 , 37,5 , 8,10 , 15010,48 , 15139,83 , 11803,24 , 15010,48 , 15139,83 , 11803,24 , 8111,28 , 8139,54 , 8097,14 , 8111,28 , 8139,54 , 8097,14 , 224,9 , 216,7 , {66,65,77}, 296,2 , 11666,195 , 25,5 , 4,0 , 3971,8 , 3118,19 , 2, 1, 1, 6, 7 }, // Bosnian/Cyrillic/BosniaAndHerzegowina
- { 144, 7, 224, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 82,17 , 37,5 , 8,10 , 20882,102 , 20984,140 , 158,27 , 20882,102 , 20984,140 , 158,27 , 11478,30 , 11508,57 , 708,14 , 11478,30 , 11508,57 , 708,14 , 66,4 , 65,4 , {71,66,80}, 158,1 , 0,7 , 4,4 , 4,0 , 3979,5 , 3984,14 , 2, 1, 1, 6, 7 }, // Manx/Latin/UnitedKingdom
- { 145, 7, 224, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 99,16 , 37,5 , 8,10 , 21124,46 , 21170,124 , 158,27 , 21124,46 , 21170,124 , 158,27 , 11565,28 , 11593,60 , 708,14 , 11565,28 , 11593,60 , 708,14 , 66,4 , 65,4 , {71,66,80}, 158,1 , 0,7 , 4,4 , 4,0 , 3998,8 , 3984,14 , 2, 1, 1, 6, 7 }, // Cornish/Latin/UnitedKingdom
- { 146, 7, 83, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 221,8 , 248,18 , 37,5 , 8,10 , 21294,48 , 21342,192 , 158,27 , 21294,48 , 21342,192 , 158,27 , 11653,28 , 11681,49 , 11730,14 , 11653,28 , 11681,49 , 11730,14 , 326,2 , 317,2 , {71,72,83}, 0,0 , 0,7 , 4,4 , 4,0 , 4006,4 , 4010,5 , 2, 1, 1, 6, 7 }, // Akan/Latin/Ghana
- { 147, 13, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 585,6 , 99,16 , 18,7 , 25,12 , 21534,87 , 21534,87 , 158,27 , 21534,87 , 21534,87 , 158,27 , 6671,32 , 11744,55 , 708,14 , 6671,32 , 11744,55 , 708,14 , 328,5 , 319,5 , {73,78,82}, 118,1 , 0,7 , 14,5 , 4,0 , 4015,6 , 2293,4 , 2, 1, 7, 7, 7 }, // Konkani/Devanagari/India
- { 149, 7, 157, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 21621,48 , 21669,86 , 158,27 , 21621,48 , 21669,86 , 158,27 , 11799,29 , 11828,57 , 708,14 , 11799,29 , 11828,57 , 708,14 , 333,4 , 324,4 , {78,71,78}, 182,1 , 11861,12 , 4,4 , 8,6 , 4021,4 , 1124,7 , 2, 1, 1, 6, 7 }, // Igbo/Latin/Nigeria
- { 150, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 21755,48 , 21803,189 , 21992,24 , 21755,48 , 21803,189 , 21992,24 , 11885,28 , 11913,74 , 11987,14 , 11885,28 , 11913,74 , 11987,14 , 337,9 , 328,7 , {75,69,83}, 2,3 , 11873,23 , 4,4 , 8,6 , 4025,7 , 1023,5 , 2, 1, 7, 6, 7 }, // Kamba/Latin/Kenya
- { 152, 14, 67, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 1212,22 , 18,7 , 25,12 , 22016,47 , 22063,77 , 22140,24 , 22016,47 , 22063,77 , 22140,24 , 12001,26 , 12027,43 , 12070,14 , 12001,26 , 12027,43 , 12070,14 , 0,2 , 0,2 , {69,82,78}, 8,3 , 0,7 , 4,4 , 4,0 , 4032,3 , 3719,4 , 2, 1, 1, 6, 7 }, // Blin/Ethiopic/Eritrea
- { 157, 14, 67, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 1234,21 , 18,7 , 25,12 , 18518,46 , 18564,62 , 1050,24 , 18518,46 , 18564,62 , 1050,24 , 12084,27 , 12111,41 , 12152,14 , 12084,27 , 12111,41 , 12152,14 , 0,2 , 0,2 , {69,82,78}, 8,3 , 0,7 , 4,4 , 4,0 , 4035,3 , 3719,4 , 2, 1, 1, 6, 7 }, // Tigre/Ethiopic/Eritrea
- { 159, 7, 106, 44, 46, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 199,7 , 199,7 , 27,8 , 1255,27 , 37,5 , 8,10 , 22164,48 , 22212,77 , 22289,24 , 22164,48 , 22212,77 , 22289,24 , 12166,28 , 12194,50 , 3055,14 , 12166,28 , 12194,50 , 3055,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 14,5 , 4,0 , 4038,6 , 4044,6 , 2, 1, 1, 6, 7 }, // Friulian/Latin/Italy
- { 160, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 22313,48 , 22361,111 , 158,27 , 22313,48 , 22361,111 , 158,27 , 12244,27 , 12271,70 , 708,14 , 12244,27 , 12271,70 , 708,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 4050,9 , 0,0 , 2, 1, 7, 6, 7 }, // Venda/Latin/SouthAfrica
- { 161, 7, 83, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 601,11 , 612,10 , 488,6 , 1282,23 , 526,12 , 538,12 , 22472,48 , 22520,87 , 22607,24 , 22472,48 , 22520,87 , 22607,24 , 12341,28 , 12369,44 , 12413,14 , 12341,28 , 12369,44 , 12413,14 , 346,3 , 335,5 , {71,72,83}, 298,3 , 11896,37 , 4,4 , 8,6 , 4059,6 , 4065,12 , 2, 1, 1, 6, 7 }, // Ewe/Latin/Ghana
- { 161, 7, 212, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 601,11 , 612,10 , 488,6 , 1282,23 , 526,12 , 538,12 , 22472,48 , 22520,87 , 22607,24 , 22472,48 , 22520,87 , 22607,24 , 12341,28 , 12369,44 , 12413,14 , 12341,28 , 12369,44 , 12413,14 , 346,3 , 335,5 , {88,79,70}, 163,3 , 11933,106 , 4,4 , 8,6 , 4059,6 , 4077,11 , 0, 0, 1, 6, 7 }, // Ewe/Latin/Togo
- { 162, 14, 69, 46, 8217, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 1305,22 , 18,7 , 25,12 , 18518,46 , 18564,62 , 1050,24 , 18518,46 , 18564,62 , 1050,24 , 12427,27 , 12427,27 , 12454,14 , 12427,27 , 12427,27 , 12454,14 , 0,2 , 0,2 , {69,84,66}, 0,2 , 11336,16 , 4,4 , 4,0 , 4088,5 , 103,5 , 2, 1, 7, 6, 7 }, // Walamo/Ethiopic/Ethiopia
- { 163, 7, 225, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 266,6 , 10,17 , 18,7 , 25,12 , 22631,59 , 22690,95 , 158,27 , 22631,59 , 22690,95 , 158,27 , 12468,21 , 12489,57 , 708,14 , 12468,21 , 12489,57 , 708,14 , 0,2 , 0,2 , {85,83,68}, 151,3 , 0,7 , 4,4 , 8,6 , 4093,14 , 4107,19 , 2, 1, 7, 6, 7 }, // Hawaiian/Latin/UnitedStates
- { 166, 7, 170, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 622,8 , 622,8 , 488,6 , 1327,18 , 37,5 , 8,10 , 22785,48 , 22833,88 , 22921,24 , 22785,48 , 22833,88 , 22921,24 , 12546,28 , 12574,55 , 12629,14 , 12643,28 , 12574,55 , 12629,14 , 0,2 , 0,2 , {80,72,80}, 162,1 , 12039,22 , 4,4 , 8,6 , 4126,8 , 4134,9 , 2, 1, 7, 6, 7 }, // Filipino/Latin/Philippines
- { 167, 7, 206, 46, 8217, 59, 37, 48, 8722, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 214,9 , 214,9 , 302,8 , 432,18 , 37,5 , 8,10 , 6953,48 , 22945,86 , 134,24 , 6953,48 , 22945,86 , 134,24 , 12671,28 , 12699,63 , 3456,14 , 12671,28 , 12699,63 , 3456,14 , 81,5 , 340,4 , {67,72,70}, 0,0 , 12061,55 , 25,5 , 4,0 , 4143,16 , 4159,7 , 2, 5, 1, 6, 7 }, // Swiss German/Latin/Switzerland
- { 168, 34, 44, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 158,27 , 23031,38 , 158,27 , 158,27 , 23031,38 , 158,27 , 12762,21 , 12783,28 , 12811,14 , 12762,21 , 12783,28 , 12811,14 , 349,2 , 344,2 , {67,78,89}, 277,3 , 0,7 , 14,5 , 4,0 , 4166,3 , 4169,2 , 2, 1, 7, 6, 7 }, // Sichuan Yi/Yi/China
- { 171, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 23069,48 , 23117,100 , 158,27 , 23069,48 , 23117,100 , 158,27 , 12825,27 , 12852,66 , 708,14 , 12825,27 , 12852,66 , 708,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 4171,10 , 0,0 , 2, 1, 7, 6, 7 }, // South Ndebele/Latin/SouthAfrica
- { 172, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 23217,48 , 23265,94 , 158,27 , 23217,48 , 23265,94 , 158,27 , 12918,27 , 12945,63 , 708,14 , 12918,27 , 12945,63 , 708,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 4181,16 , 0,0 , 2, 1, 7, 6, 7 }, // Northern Sotho/Latin/SouthAfrica
- { 173, 7, 161, 44, 160, 59, 37, 48, 8722, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 162,8 , 162,8 , 72,10 , 248,18 , 37,5 , 8,10 , 23359,59 , 23418,145 , 23563,24 , 23359,59 , 23418,145 , 23563,24 , 13008,33 , 13041,75 , 13116,14 , 13008,33 , 13041,75 , 13116,14 , 0,2 , 0,2 , {78,79,75}, 301,3 , 12116,63 , 25,5 , 4,0 , 4197,15 , 4212,5 , 2, 1, 1, 6, 7 }, // Northern Sami/Latin/Norway
- { 173, 7, 73, 44, 160, 59, 37, 48, 8722, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 162,8 , 162,8 , 72,10 , 248,18 , 37,5 , 8,10 , 23587,85 , 23418,145 , 23563,24 , 23587,85 , 23418,145 , 23563,24 , 13008,33 , 13130,65 , 13195,14 , 13008,33 , 13130,65 , 13195,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 12179,23 , 25,5 , 4,0 , 4197,15 , 4217,6 , 2, 1, 1, 6, 7 }, // Northern Sami/Latin/Finland
- { 175, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 23672,48 , 23720,88 , 23808,24 , 23672,48 , 23720,88 , 23808,24 , 13209,28 , 13237,62 , 13299,14 , 13209,28 , 13237,62 , 13299,14 , 351,5 , 346,10 , {75,69,83}, 2,3 , 12202,24 , 4,4 , 8,6 , 4223,8 , 1023,5 , 2, 1, 7, 6, 7 }, // Gusii/Latin/Kenya
- { 176, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 23832,48 , 23880,221 , 24101,24 , 23832,48 , 23880,221 , 24101,24 , 13313,28 , 13341,105 , 13446,14 , 13313,28 , 13341,105 , 13446,14 , 356,10 , 356,10 , {75,69,83}, 2,3 , 12202,24 , 4,4 , 8,6 , 4231,7 , 1023,5 , 2, 1, 7, 6, 7 }, // Taita/Latin/Kenya
- { 177, 7, 187, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8221, 8218, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 24125,48 , 24173,77 , 24250,24 , 24125,48 , 24173,77 , 24250,24 , 13460,28 , 13488,59 , 13547,14 , 13460,28 , 13488,59 , 13547,14 , 366,6 , 366,7 , {88,79,70}, 163,3 , 12226,26 , 25,5 , 4,0 , 4238,6 , 4244,8 , 0, 0, 1, 6, 7 }, // Fulah/Latin/Senegal
- { 178, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 24274,48 , 24322,185 , 24507,24 , 24274,48 , 24322,185 , 24507,24 , 13561,28 , 13589,63 , 13652,14 , 13561,28 , 13589,63 , 13652,14 , 372,6 , 373,8 , {75,69,83}, 2,3 , 12252,23 , 4,4 , 8,6 , 4252,6 , 1023,5 , 2, 1, 7, 6, 7 }, // Kikuyu/Latin/Kenya
- { 179, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 24531,48 , 24579,173 , 24752,24 , 24531,48 , 24579,173 , 24752,24 , 13666,28 , 13694,105 , 13799,14 , 13666,28 , 13694,105 , 13799,14 , 378,7 , 381,5 , {75,69,83}, 2,3 , 12275,25 , 4,4 , 8,6 , 4258,8 , 1023,5 , 2, 1, 7, 6, 7 }, // Samburu/Latin/Kenya
- { 180, 7, 146, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 817,27 , 37,5 , 8,10 , 24776,48 , 24824,88 , 134,24 , 24776,48 , 24824,88 , 134,24 , 13813,28 , 13841,55 , 13896,14 , 13813,28 , 13841,55 , 13896,14 , 0,2 , 0,2 , {77,90,78}, 220,3 , 12300,28 , 0,4 , 4,0 , 4266,4 , 2909,10 , 2, 1, 7, 6, 7 }, // Sena/Latin/Mozambique
- { 181, 7, 240, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 24912,52 , 24964,112 , 25076,24 , 24912,52 , 24964,112 , 25076,24 , 13910,28 , 13938,50 , 13988,14 , 13910,28 , 13938,50 , 13988,14 , 0,2 , 0,2 , {85,83,68}, 151,3 , 12328,24 , 4,4 , 8,6 , 4171,10 , 1508,8 , 2, 1, 7, 6, 7 }, // North Ndebele/Latin/Zimbabwe
- { 182, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 25100,39 , 25139,194 , 25333,24 , 25100,39 , 25139,194 , 25333,24 , 14002,29 , 14031,65 , 14096,14 , 14002,29 , 14031,65 , 14096,14 , 385,8 , 386,7 , {84,90,83}, 268,3 , 12352,25 , 4,4 , 4,0 , 4270,9 , 1342,8 , 0, 0, 1, 6, 7 }, // Rombo/Latin/Tanzania
- { 183, 9, 145, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 25357,48 , 25405,81 , 25486,24 , 25357,48 , 25405,81 , 25486,24 , 14110,30 , 14140,47 , 708,14 , 14110,30 , 14140,47 , 708,14 , 393,6 , 393,8 , {77,65,68}, 0,0 , 12377,21 , 0,4 , 4,0 , 4279,8 , 4287,6 , 2, 1, 6, 5, 6 }, // Tachelhit/Tifinagh/Morocco
- { 183, 7, 145, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 25510,48 , 25558,81 , 25639,24 , 25510,48 , 25558,81 , 25639,24 , 14187,30 , 14217,48 , 708,14 , 14187,30 , 14217,48 , 708,14 , 399,6 , 401,8 , {77,65,68}, 0,0 , 12398,21 , 0,4 , 4,0 , 4293,9 , 4302,6 , 2, 1, 6, 5, 6 }, // Tachelhit/Latin/Morocco
- { 184, 7, 3, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 25663,48 , 25711,84 , 25795,24 , 25663,48 , 25711,84 , 25795,24 , 14265,30 , 14295,51 , 14346,14 , 14265,30 , 14295,51 , 14346,14 , 405,7 , 409,9 , {68,90,68}, 304,2 , 12419,21 , 0,4 , 4,0 , 4308,9 , 4317,8 , 2, 1, 6, 4, 5 }, // Kabyle/Latin/Algeria
- { 185, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 25819,48 , 25867,152 , 134,24 , 25819,48 , 25867,152 , 134,24 , 14360,28 , 14388,74 , 14462,14 , 14360,28 , 14388,74 , 14462,14 , 0,2 , 0,2 , {85,71,88}, 306,3 , 12440,26 , 4,4 , 78,5 , 4325,10 , 1398,6 , 0, 0, 1, 6, 7 }, // Nyankole/Latin/Uganda
- { 186, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 26019,48 , 26067,254 , 26321,24 , 26019,48 , 26067,254 , 26321,24 , 14476,28 , 14504,82 , 14586,14 , 14476,28 , 14504,82 , 14586,14 , 412,7 , 418,7 , {84,90,83}, 268,3 , 12466,29 , 0,4 , 4,0 , 4335,6 , 4341,10 , 0, 0, 1, 6, 7 }, // Bena/Latin/Tanzania
- { 187, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 17247,48 , 26345,87 , 134,24 , 17247,48 , 26345,87 , 134,24 , 14600,28 , 14628,62 , 14690,14 , 14600,28 , 14628,62 , 14690,14 , 419,5 , 425,9 , {84,90,83}, 268,3 , 12495,27 , 4,4 , 4,0 , 4351,8 , 1342,8 , 0, 0, 1, 6, 7 }, // Vunjo/Latin/Tanzania
- { 188, 7, 132, 46, 44, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 26432,47 , 26479,92 , 26571,24 , 26432,47 , 26479,92 , 26571,24 , 14704,28 , 14732,44 , 14776,14 , 14704,28 , 14732,44 , 14776,14 , 0,2 , 0,2 , {88,79,70}, 163,3 , 12522,24 , 4,4 , 8,6 , 4359,9 , 1853,4 , 0, 0, 1, 6, 7 }, // Bambara/Latin/Mali
- { 189, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 26595,48 , 26643,207 , 26850,24 , 26595,48 , 26643,207 , 26850,24 , 14790,28 , 14818,64 , 14882,14 , 14790,28 , 14818,64 , 14882,14 , 424,2 , 434,2 , {75,69,83}, 2,3 , 12202,24 , 4,4 , 8,6 , 4368,6 , 1023,5 , 2, 1, 7, 6, 7 }, // Embu/Latin/Kenya
- { 190, 12, 225, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 488,6 , 35,18 , 18,7 , 25,12 , 26874,36 , 26910,58 , 26968,24 , 26874,36 , 26910,58 , 26968,24 , 14896,28 , 14924,49 , 14973,14 , 14896,28 , 14924,49 , 14973,14 , 426,3 , 436,6 , {85,83,68}, 12,1 , 12546,19 , 4,4 , 8,6 , 4374,3 , 4377,4 , 2, 1, 7, 6, 7 }, // Cherokee/Cherokee/UnitedStates
- { 191, 7, 137, 46, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 26992,47 , 27039,68 , 27107,24 , 26992,47 , 27039,68 , 27107,24 , 14987,27 , 15014,48 , 15062,14 , 14987,27 , 15014,48 , 15062,14 , 0,2 , 0,2 , {77,85,82}, 0,0 , 12565,21 , 14,5 , 4,0 , 4381,14 , 4395,5 , 0, 0, 1, 6, 7 }, // Morisyen/Latin/Mauritius
- { 192, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 17247,48 , 27131,264 , 134,24 , 17247,48 , 27131,264 , 134,24 , 15076,28 , 15104,133 , 14096,14 , 15076,28 , 15104,133 , 14096,14 , 429,4 , 442,5 , {84,90,83}, 268,3 , 12495,27 , 4,4 , 8,6 , 4400,10 , 1342,8 , 0, 0, 1, 6, 7 }, // Makonde/Latin/Tanzania
- { 193, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 27395,83 , 27478,111 , 27589,24 , 27395,83 , 27478,111 , 27589,24 , 15237,36 , 15273,63 , 15336,14 , 15237,36 , 15273,63 , 15336,14 , 433,3 , 447,3 , {84,90,83}, 268,3 , 12586,29 , 14,5 , 4,0 , 4410,8 , 4418,9 , 0, 0, 1, 6, 7 }, // Langi/Latin/Tanzania
- { 194, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 27613,48 , 27661,97 , 134,24 , 27613,48 , 27661,97 , 134,24 , 15350,28 , 15378,66 , 15444,14 , 15350,28 , 15378,66 , 15444,14 , 0,2 , 0,2 , {85,71,88}, 306,3 , 12615,26 , 0,4 , 4,0 , 4427,7 , 4434,7 , 0, 0, 1, 6, 7 }, // Ganda/Latin/Uganda
- { 195, 7, 239, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 27758,48 , 27806,83 , 27889,24 , 27758,48 , 27806,83 , 27889,24 , 15458,80 , 15458,80 , 708,14 , 15458,80 , 15458,80 , 708,14 , 436,8 , 450,7 , {90,77,75}, 309,2 , 0,7 , 4,4 , 8,6 , 4441,9 , 1502,6 , 0, 0, 1, 6, 7 }, // Bemba/Latin/Zambia
- { 196, 7, 39, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 446,7 , 446,7 , 334,8 , 1345,27 , 37,5 , 8,10 , 27913,48 , 27961,86 , 134,24 , 27913,48 , 27961,86 , 134,24 , 15538,28 , 15566,73 , 15639,14 , 15538,28 , 15566,73 , 15639,14 , 76,2 , 75,2 , {67,86,69}, 0,0 , 12641,25 , 0,4 , 4,0 , 4450,12 , 4462,10 , 2, 1, 1, 6, 7 }, // Kabuverdianu/Latin/CapeVerde
- { 197, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28047,48 , 28095,86 , 28181,24 , 28047,48 , 28095,86 , 28181,24 , 15653,28 , 15681,51 , 15732,14 , 15653,28 , 15681,51 , 15732,14 , 444,2 , 457,2 , {75,69,83}, 2,3 , 12202,24 , 4,4 , 8,6 , 4472,6 , 1023,5 , 2, 1, 7, 6, 7 }, // Meru/Latin/Kenya
- { 198, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28205,48 , 28253,111 , 28364,24 , 28205,48 , 28253,111 , 28364,24 , 15746,28 , 15774,93 , 15867,14 , 15746,28 , 15774,93 , 15867,14 , 446,4 , 459,4 , {75,69,83}, 2,3 , 12666,26 , 4,4 , 8,6 , 4478,8 , 4486,12 , 2, 1, 7, 6, 7 }, // Kalenjin/Latin/Kenya
- { 199, 7, 148, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 0,48 , 28388,136 , 134,24 , 0,48 , 28388,136 , 134,24 , 15881,23 , 15904,92 , 15996,14 , 15881,23 , 15904,92 , 15996,14 , 450,7 , 463,5 , {78,65,68}, 12,1 , 12692,22 , 4,4 , 4,0 , 4498,13 , 4511,8 , 2, 1, 1, 6, 7 }, // Nama/Latin/Namibia
- { 200, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 17247,48 , 26345,87 , 134,24 , 17247,48 , 26345,87 , 134,24 , 14600,28 , 14628,62 , 14690,14 , 14600,28 , 14628,62 , 14690,14 , 419,5 , 425,9 , {84,90,83}, 268,3 , 12495,27 , 4,4 , 4,0 , 4519,9 , 1342,8 , 0, 0, 1, 6, 7 }, // Machame/Latin/Tanzania
- { 201, 7, 82, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 340,8 , 340,8 , 1372,10 , 1382,23 , 37,5 , 8,10 , 28524,59 , 28583,87 , 134,24 , 28670,48 , 28583,87 , 134,24 , 16010,28 , 16038,72 , 3456,14 , 16010,28 , 16038,72 , 3456,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 6996,11 , 25,5 , 4,0 , 4528,6 , 4534,11 , 2, 1, 1, 6, 7 }, // Colognian/Latin/Germany
- { 202, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28718,51 , 28769,132 , 158,27 , 28718,51 , 28769,132 , 158,27 , 14600,28 , 16110,58 , 14096,14 , 14600,28 , 16110,58 , 14096,14 , 457,9 , 468,6 , {75,69,83}, 2,3 , 12714,25 , 4,4 , 8,6 , 4545,3 , 1023,5 , 2, 1, 7, 6, 7 }, // Masai/Latin/Kenya
- { 202, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28718,51 , 28769,132 , 158,27 , 28718,51 , 28769,132 , 158,27 , 14600,28 , 16110,58 , 14096,14 , 14600,28 , 16110,58 , 14096,14 , 457,9 , 468,6 , {84,90,83}, 268,3 , 12739,28 , 4,4 , 8,6 , 4545,3 , 4548,8 , 0, 0, 1, 6, 7 }, // Masai/Latin/Tanzania
- { 203, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 27613,48 , 27661,97 , 134,24 , 27613,48 , 27661,97 , 134,24 , 16168,35 , 16203,65 , 16268,14 , 16168,35 , 16203,65 , 16268,14 , 466,6 , 474,6 , {85,71,88}, 306,3 , 12615,26 , 25,5 , 4,0 , 4556,7 , 4434,7 , 0, 0, 1, 6, 7 }, // Soga/Latin/Uganda
- { 204, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28901,48 , 17295,84 , 134,24 , 28901,48 , 17295,84 , 134,24 , 16282,21 , 16303,75 , 85,14 , 16282,21 , 16303,75 , 85,14 , 66,4 , 65,4 , {75,69,83}, 0,0 , 12767,23 , 4,4 , 83,6 , 4563,7 , 1023,5 , 2, 1, 7, 6, 7 }, // Luyia/Latin/Kenya
- { 205, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28949,48 , 17295,84 , 134,24 , 28949,48 , 17295,84 , 134,24 , 16378,28 , 9375,60 , 14690,14 , 16378,28 , 9375,60 , 14690,14 , 472,9 , 480,8 , {84,90,83}, 268,3 , 12790,28 , 25,5 , 4,0 , 4570,6 , 4576,8 , 0, 0, 1, 6, 7 }, // Asu/Latin/Tanzania
- { 206, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28997,48 , 29045,94 , 29139,24 , 28997,48 , 29045,94 , 29139,24 , 16406,28 , 16434,69 , 16503,14 , 16406,28 , 16434,69 , 16503,14 , 481,9 , 488,6 , {85,71,88}, 306,3 , 12818,28 , 4,4 , 8,6 , 4584,6 , 1398,6 , 0, 0, 1, 6, 7 }, // Teso/Latin/Uganda
- { 206, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28997,48 , 29045,94 , 29139,24 , 28997,48 , 29045,94 , 29139,24 , 16406,28 , 16434,69 , 16503,14 , 16406,28 , 16434,69 , 16503,14 , 481,9 , 488,6 , {75,69,83}, 2,3 , 12846,27 , 4,4 , 8,6 , 4584,6 , 4590,5 , 2, 1, 7, 6, 7 }, // Teso/Latin/Kenya
- { 207, 7, 67, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 53,19 , 18,7 , 25,12 , 344,48 , 392,118 , 510,24 , 344,48 , 392,118 , 510,24 , 16517,28 , 16545,56 , 16601,14 , 16517,28 , 16545,56 , 16601,14 , 0,2 , 0,2 , {69,82,78}, 8,3 , 0,7 , 4,4 , 4,0 , 0,0 , 43,7 , 2, 1, 1, 6, 7 }, // Saho/Latin/Eritrea
- { 208, 7, 132, 46, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 29163,46 , 29209,88 , 29297,24 , 29163,46 , 29209,88 , 29297,24 , 16615,28 , 16643,53 , 16696,14 , 16615,28 , 16643,53 , 16696,14 , 490,6 , 494,6 , {88,79,70}, 163,3 , 12873,23 , 0,4 , 4,0 , 4595,11 , 4606,5 , 0, 0, 1, 6, 7 }, // Koyra Chiini/Latin/Mali
- { 209, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 17247,48 , 26345,87 , 134,24 , 17247,48 , 26345,87 , 134,24 , 14600,28 , 14628,62 , 14690,14 , 14600,28 , 14628,62 , 14690,14 , 419,5 , 425,9 , {84,90,83}, 268,3 , 12495,27 , 0,4 , 4,0 , 4611,6 , 1342,8 , 0, 0, 1, 6, 7 }, // Rwa/Latin/Tanzania
- { 210, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 29321,48 , 29369,186 , 29555,24 , 29321,48 , 29369,186 , 29555,24 , 16710,28 , 16738,69 , 16807,14 , 16710,28 , 16738,69 , 16807,14 , 496,2 , 500,2 , {75,69,83}, 0,0 , 12896,23 , 0,4 , 4,0 , 4617,6 , 1023,5 , 2, 1, 7, 6, 7 }, // Luo/Latin/Kenya
- { 211, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 25819,48 , 25867,152 , 134,24 , 25819,48 , 25867,152 , 134,24 , 14360,28 , 14388,74 , 14462,14 , 14360,28 , 14388,74 , 14462,14 , 0,2 , 0,2 , {85,71,88}, 306,3 , 12440,26 , 4,4 , 78,5 , 4623,6 , 1398,6 , 0, 0, 1, 6, 7 }, // Chiga/Latin/Uganda
- { 212, 7, 145, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 29579,48 , 29627,86 , 29713,24 , 29579,48 , 29627,86 , 29713,24 , 16821,28 , 16849,48 , 16897,14 , 16821,28 , 16849,48 , 16897,14 , 498,9 , 502,10 , {77,65,68}, 0,0 , 12919,22 , 25,5 , 4,0 , 4629,8 , 4637,6 , 2, 1, 6, 5, 6 }, // Central Morocco Tamazight/Latin/Morocco
- { 213, 7, 132, 46, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 29163,46 , 29209,88 , 29297,24 , 29163,46 , 29209,88 , 29297,24 , 16911,28 , 16939,54 , 16696,14 , 16911,28 , 16939,54 , 16696,14 , 490,6 , 494,6 , {88,79,70}, 163,3 , 12873,23 , 0,4 , 4,0 , 4643,15 , 4606,5 , 0, 0, 1, 6, 7 }, // Koyraboro Senni/Latin/Mali
- { 214, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 17247,48 , 29737,84 , 134,24 , 17247,48 , 29737,84 , 134,24 , 16993,28 , 17021,63 , 9435,14 , 16993,28 , 17021,63 , 9435,14 , 507,5 , 512,8 , {84,90,83}, 268,3 , 11030,27 , 0,4 , 4,0 , 4658,9 , 1342,8 , 0, 0, 1, 6, 7 }, // Shambala/Latin/Tanzania
- { 215, 13, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 488,6 , 35,18 , 18,7 , 25,12 , 29821,88 , 29821,88 , 29909,31 , 29821,88 , 29821,88 , 29909,31 , 17084,33 , 17117,54 , 17171,19 , 17084,33 , 17117,54 , 17171,19 , 512,3 , 520,6 , {73,78,82}, 118,1 , 12941,10 , 14,5 , 4,0 , 4667,4 , 2293,4 , 2, 1, 7, 7, 7 }, // Bodo/Devanagari/India
- { 230, 7, 49, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 29940,49 , 29989,99 , 30088,24 , 29940,49 , 29989,99 , 30088,24 , 17190,28 , 17218,50 , 17268,14 , 17190,28 , 17218,50 , 17268,14 , 515,5 , 526,6 , {67,68,70}, 0,0 , 12951,24 , 0,4 , 4,0 , 4671,8 , 4679,16 , 2, 1, 1, 6, 7 }, // LubaKatanga/Latin/CongoKinshasa
- { 237, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8221, 8218, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 30112,48 , 30160,195 , 30355,24 , 30112,48 , 30160,195 , 30355,24 , 17282,28 , 17310,72 , 17382,14 , 17282,28 , 17310,72 , 17382,14 , 520,3 , 532,3 , {88,65,70}, 33,4 , 12975,21 , 0,4 , 4,0 , 4695,5 , 4700,7 , 0, 0, 1, 6, 7 }, // Aghem/Latin/Cameroon
- { 238, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 30379,48 , 30427,90 , 30517,24 , 30379,48 , 30427,90 , 30517,24 , 17396,28 , 17424,70 , 17494,14 , 17396,28 , 17424,70 , 17494,14 , 523,10 , 535,9 , {88,65,70}, 33,4 , 12996,22 , 25,5 , 4,0 , 4707,5 , 4712,8 , 0, 0, 1, 6, 7 }, // Basaa/Latin/Cameroon
- { 239, 7, 156, 46, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 29163,46 , 29209,88 , 29297,24 , 29163,46 , 29209,88 , 29297,24 , 16911,28 , 17508,53 , 17561,14 , 16911,28 , 17508,53 , 17561,14 , 533,8 , 544,10 , {88,79,70}, 163,3 , 12873,23 , 0,4 , 4,0 , 4720,10 , 4730,5 , 0, 0, 1, 6, 7 }, // Zarma/Latin/Niger
- { 240, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 30541,49 , 30590,99 , 30689,24 , 30541,49 , 30590,99 , 30689,24 , 17575,28 , 17603,45 , 17648,14 , 17575,28 , 17603,45 , 17648,14 , 541,5 , 554,6 , {88,65,70}, 33,4 , 0,7 , 25,5 , 4,0 , 4735,5 , 1632,8 , 0, 0, 1, 6, 7 }, // Duala/Latin/Cameroon
- { 241, 7, 187, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 30713,36 , 30749,82 , 30831,24 , 30713,36 , 30749,82 , 30831,24 , 17662,28 , 17690,50 , 17740,14 , 17662,28 , 17690,50 , 17740,14 , 0,2 , 0,2 , {88,79,70}, 163,3 , 13018,23 , 25,5 , 4,0 , 4740,5 , 4745,7 , 0, 0, 1, 6, 7 }, // JolaFonyi/Latin/Senegal
- { 242, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 30855,50 , 30905,141 , 31046,24 , 30855,50 , 30905,141 , 31046,24 , 17754,30 , 17784,85 , 17869,14 , 17754,30 , 17784,85 , 17869,14 , 546,7 , 560,9 , {88,65,70}, 33,4 , 13041,23 , 25,5 , 4,0 , 4752,6 , 4758,7 , 0, 0, 1, 6, 7 }, // Ewondo/Latin/Cameroon
- { 243, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 31070,39 , 31109,191 , 158,27 , 31070,39 , 31109,191 , 158,27 , 17883,29 , 17912,45 , 17957,14 , 17883,29 , 17912,45 , 17957,14 , 553,6 , 569,7 , {88,65,70}, 33,4 , 13064,11 , 25,5 , 4,0 , 4765,5 , 4770,7 , 0, 0, 1, 6, 7 }, // Bafia/Latin/Cameroon
- { 244, 7, 146, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 31300,48 , 31348,213 , 31561,24 , 31300,48 , 31348,213 , 31561,24 , 17971,28 , 17999,59 , 18058,14 , 17971,28 , 17999,59 , 18058,14 , 559,8 , 576,10 , {77,90,78}, 220,3 , 0,7 , 14,5 , 4,0 , 4777,5 , 4782,10 , 2, 1, 7, 6, 7 }, // MakhuwaMeetto/Latin/Mozambique
- { 245, 7, 37, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 31585,48 , 31633,139 , 31772,24 , 31585,48 , 31633,139 , 31772,24 , 18072,28 , 18100,74 , 18174,14 , 18072,28 , 18100,74 , 18174,14 , 567,5 , 586,5 , {88,65,70}, 33,4 , 13075,17 , 4,4 , 8,6 , 4792,6 , 4798,7 , 0, 0, 1, 6, 7 }, // Mundang/Latin/Cameroon
- { 246, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8221, 171, 187, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 31796,51 , 31847,143 , 158,27 , 31796,51 , 31847,143 , 158,27 , 18188,30 , 18218,89 , 18307,14 , 18188,30 , 18218,89 , 18307,14 , 572,4 , 591,4 , {88,65,70}, 33,4 , 13092,20 , 25,5 , 4,0 , 4805,6 , 4811,7 , 0, 0, 1, 6, 7 }, // Kwasio/Latin/Cameroon
- { 247, 7, 201, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 1405,9 , 99,16 , 18,7 , 550,12 , 31990,54 , 32044,96 , 32140,24 , 31990,54 , 32044,96 , 32140,24 , 18321,38 , 18359,79 , 18438,14 , 18321,38 , 18359,79 , 18438,14 , 576,2 , 595,2 , {83,68,71}, 0,0 , 0,7 , 4,4 , 8,6 , 4818,9 , 4827,5 , 2, 1, 6, 5, 6 }, // Nuer/Latin/Sudan
- { 248, 2, 178, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 1414,6 , 1420,30 , 37,5 , 8,10 , 32164,75 , 32239,121 , 32360,24 , 32164,75 , 32239,121 , 32360,24 , 18452,21 , 18473,73 , 18546,14 , 18452,21 , 18473,73 , 18546,14 , 0,2 , 0,2 , {82,85,66}, 0,0 , 0,7 , 14,5 , 4,0 , 4832,9 , 0,0 , 2, 1, 1, 6, 7 }, // Sakha/Cyrillic/Russia
- { 249, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 32384,48 , 32432,117 , 158,27 , 32384,48 , 32432,117 , 158,27 , 18560,28 , 18588,60 , 18648,14 , 18560,28 , 18588,60 , 18648,14 , 578,9 , 597,9 , {84,90,83}, 268,3 , 13112,25 , 0,4 , 4,0 , 4841,9 , 4850,9 , 0, 0, 1, 6, 7 }, // Sangu/Latin/Tanzania
- { 250, 7, 49, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 32549,48 , 32597,188 , 32785,24 , 32549,48 , 32597,188 , 32785,24 , 18662,28 , 18690,93 , 18783,14 , 18662,28 , 18690,93 , 18783,14 , 587,10 , 606,10 , {67,68,70}, 0,0 , 13137,23 , 4,4 , 4,0 , 4859,18 , 4877,32 , 2, 1, 1, 6, 7 }, // Congo Swahili/Latin/CongoKinshasa
- { 251, 7, 156, 46, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 29163,46 , 29209,88 , 29297,24 , 29163,46 , 29209,88 , 29297,24 , 16911,28 , 16939,54 , 16696,14 , 16911,28 , 16939,54 , 16696,14 , 533,8 , 544,10 , {88,79,70}, 163,3 , 12873,23 , 0,4 , 4,0 , 4909,13 , 4730,5 , 0, 0, 1, 6, 7 }, // Tasawaq/Latin/Niger
- { 252, 35, 121, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 32809,50 , 32809,50 , 158,27 , 32809,50 , 32809,50 , 158,27 , 18797,30 , 18797,30 , 708,14 , 18797,30 , 18797,30 , 708,14 , 0,2 , 0,2 , {76,82,68}, 12,1 , 13160,15 , 4,4 , 8,6 , 4922,2 , 4924,4 , 2, 1, 1, 6, 7 }, // Vai/Vai/Liberia
- { 252, 7, 121, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 32859,81 , 32859,81 , 158,27 , 32859,81 , 32859,81 , 158,27 , 18827,48 , 18827,48 , 708,14 , 18827,48 , 18827,48 , 708,14 , 0,2 , 0,2 , {76,82,68}, 12,1 , 13175,20 , 4,4 , 8,6 , 4928,3 , 4931,8 , 2, 1, 1, 6, 7 }, // Vai/Latin/Liberia
- { 253, 7, 206, 44, 8217, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 214,9 , 214,9 , 72,10 , 432,18 , 37,5 , 8,10 , 32940,48 , 32988,99 , 33087,24 , 32940,48 , 32988,99 , 33087,24 , 18875,28 , 18903,53 , 18956,14 , 18875,28 , 18903,53 , 18956,14 , 0,2 , 0,2 , {67,72,70}, 0,0 , 0,7 , 14,5 , 4,0 , 4939,6 , 4945,6 , 2, 5, 1, 6, 7 }, // Walser/Latin/Switzerland
- { 254, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 0,6 , 0,6 , 334,8 , 99,16 , 37,5 , 8,10 , 33111,51 , 33162,191 , 158,27 , 33111,51 , 33162,191 , 158,27 , 18970,21 , 18991,71 , 19062,14 , 18970,21 , 18991,71 , 19062,14 , 597,8 , 616,8 , {88,65,70}, 33,4 , 0,7 , 25,5 , 30,7 , 4951,6 , 4957,7 , 0, 0, 1, 6, 7 }, // Yangben/Latin/Cameroon
- { 256, 7, 197, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 446,7 , 446,7 , 266,6 , 1450,23 , 37,5 , 8,10 , 33353,48 , 33401,85 , 33486,24 , 33510,48 , 33558,117 , 33486,24 , 19076,28 , 19104,54 , 3257,14 , 19076,28 , 19104,54 , 3257,14 , 0,2 , 0,2 , {69,85,82}, 127,1 , 2403,20 , 25,5 , 4,0 , 4964,9 , 2065,6 , 2, 1, 1, 6, 7 }, // Asturian/Latin/Spain
- { 257, 7, 37, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 630,11 , 630,11 , 641,16 , 657,9 , 72,10 , 248,18 , 37,5 , 8,10 , 33675,174 , 33675,174 , 158,27 , 33675,174 , 33675,174 , 158,27 , 19158,60 , 19158,60 , 19218,25 , 19158,60 , 19158,60 , 19218,25 , 605,8 , 624,13 , {88,65,70}, 33,4 , 13195,12 , 14,5 , 4,0 , 4973,5 , 4978,7 , 0, 0, 1, 6, 7 }, // Ngomba/Latin/Cameroon
- { 258, 7, 37, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 0,6 , 0,6 , 1473,10 , 82,17 , 37,5 , 8,10 , 33849,102 , 33849,102 , 158,27 , 33849,102 , 33849,102 , 158,27 , 19243,54 , 19243,54 , 19297,21 , 19243,54 , 19243,54 , 19297,21 , 0,2 , 0,2 , {88,65,70}, 33,4 , 13207,16 , 14,5 , 4,0 , 4985,4 , 4989,7 , 0, 0, 1, 6, 7 }, // Kako/Latin/Cameroon
- { 259, 7, 37, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 248,18 , 37,5 , 8,10 , 33951,137 , 34088,142 , 34230,36 , 33951,137 , 34088,142 , 34230,36 , 19318,49 , 19318,49 , 19367,21 , 19318,49 , 19318,49 , 19367,21 , 0,2 , 0,2 , {88,65,70}, 33,4 , 13223,12 , 14,5 , 4,0 , 4996,5 , 5001,7 , 0, 0, 1, 6, 7 }, // Meta/Latin/Cameroon
- { 260, 7, 37, 44, 46, 44, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 1483,32 , 37,5 , 8,10 , 34266,164 , 34266,164 , 158,27 , 34266,164 , 34266,164 , 158,27 , 19388,111 , 19388,111 , 708,14 , 19388,111 , 19388,111 , 708,14 , 613,9 , 637,8 , {88,65,70}, 33,4 , 13235,16 , 14,5 , 4,0 , 5008,16 , 5024,7 , 0, 0, 1, 6, 7 }, // Ngiemboon/Latin/Cameroon
+ { 8, 1, 207, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1376,92 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {83,89,80}, 99,5 , 1851,77 , 4,4 , 4,0 , 108,7 , 260,5 , 0, 0, 6, 5, 6 }, // Arabic/Arabic/Syria
+ { 8, 1, 216, 44, 46, 59, 37, 48, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 179,8 , 161,18 , 18,7 , 25,12 , 1281,71 , 1281,71 , 1352,24 , 1281,71 , 1281,71 , 1352,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {84,78,68}, 104,5 , 1928,77 , 4,4 , 4,0 , 108,7 , 265,4 , 3, 0, 7, 5, 6 }, // Arabic/Arabic/Tunisia
+ { 8, 1, 223, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {65,69,68}, 109,5 , 2005,91 , 14,5 , 19,6 , 108,7 , 269,24 , 2, 1, 6, 5, 6 }, // Arabic/Arabic/UnitedArabEmirates
+ { 8, 1, 236, 46, 44, 59, 37, 48, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {77,65,68}, 78,5 , 1389,77 , 14,5 , 19,6 , 108,7 , 293,15 , 2, 1, 1, 6, 7 }, // Arabic/Arabic/WesternSahara
+ { 8, 1, 237, 1643, 1644, 1563, 1642, 1632, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 43,8 , 51,7 , 151,10 , 161,18 , 18,7 , 25,12 , 1182,75 , 1182,75 , 1257,24 , 1182,75 , 1182,75 , 1257,24 , 552,52 , 552,52 , 604,14 , 552,52 , 552,52 , 604,14 , 12,1 , 13,1 , {89,69,82}, 114,5 , 2096,70 , 4,4 , 4,0 , 108,7 , 308,5 , 0, 0, 6, 4, 5 }, // Arabic/Arabic/Yemen
+ { 9, 10, 11, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 58,7 , 58,7 , 187,8 , 195,21 , 61,4 , 65,10 , 1845,48 , 1893,106 , 1999,24 , 1845,48 , 1893,106 , 1999,24 , 618,28 , 646,62 , 708,15 , 618,28 , 646,62 , 708,15 , 13,12 , 14,12 , {65,77,68}, 119,3 , 2166,46 , 25,5 , 4,0 , 313,7 , 320,8 , 0, 0, 1, 6, 7 }, // Armenian/Armenian/Armenia
+ { 10, 11, 100, 46, 44, 59, 37, 2534, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 216,8 , 224,18 , 75,8 , 83,12 , 2023,62 , 2085,88 , 158,27 , 2023,62 , 2085,88 , 158,27 , 723,37 , 760,58 , 85,14 , 723,37 , 760,58 , 85,14 , 25,9 , 26,7 , {73,78,82}, 122,1 , 0,7 , 14,5 , 4,0 , 328,7 , 335,4 , 2, 1, 7, 7, 7 }, // Assamese/Bengali/India
+ { 12, 7, 15, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 0,6 , 0,6 , 242,8 , 250,19 , 37,5 , 8,10 , 2173,48 , 2221,77 , 158,27 , 2173,48 , 2221,77 , 158,27 , 818,26 , 844,67 , 99,14 , 818,26 , 844,67 , 99,14 , 0,2 , 0,2 , {65,90,78}, 123,4 , 2212,41 , 14,5 , 4,0 , 339,12 , 351,10 , 2, 1, 1, 6, 7 }, // Azerbaijani/Latin/Azerbaijan
+ { 12, 2, 15, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 0,6 , 0,6 , 242,8 , 250,19 , 37,5 , 8,10 , 2298,77 , 2298,77 , 158,27 , 2298,77 , 2298,77 , 158,27 , 911,67 , 911,67 , 99,14 , 911,67 , 911,67 , 99,14 , 0,2 , 0,2 , {65,90,78}, 127,4 , 2253,12 , 14,5 , 4,0 , 361,10 , 361,10 , 2, 1, 1, 6, 7 }, // Azerbaijani/Cyrillic/Azerbaijan
+ { 14, 7, 197, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 65,9 , 65,9 , 72,10 , 269,18 , 37,5 , 8,10 , 2375,48 , 2423,93 , 2516,24 , 2375,48 , 2423,93 , 2516,24 , 978,21 , 999,68 , 1067,14 , 978,21 , 999,68 , 1081,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2265,12 , 25,5 , 30,7 , 371,7 , 378,8 , 2, 1, 1, 6, 7 }, // Basque/Latin/Spain
+ { 15, 11, 18, 46, 44, 59, 37, 2534, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 74,10 , 84,9 , 287,6 , 224,18 , 18,7 , 25,12 , 2540,90 , 2540,90 , 2630,33 , 2540,90 , 2540,90 , 2630,33 , 1095,37 , 1132,58 , 1190,18 , 1095,37 , 1132,58 , 1190,18 , 34,9 , 33,7 , {66,68,84}, 132,1 , 2277,21 , 0,4 , 37,6 , 386,5 , 391,8 , 2, 1, 5, 6, 7 }, // Bengali/Bengali/Bangladesh
+ { 15, 11, 100, 46, 44, 59, 37, 2534, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 74,10 , 84,9 , 287,6 , 224,18 , 18,7 , 25,12 , 2540,90 , 2540,90 , 2630,33 , 2540,90 , 2540,90 , 2630,33 , 1095,37 , 1132,58 , 1190,18 , 1095,37 , 1132,58 , 1190,18 , 34,9 , 33,7 , {73,78,82}, 122,1 , 2298,19 , 0,4 , 37,6 , 386,5 , 399,4 , 2, 1, 7, 7, 7 }, // Bengali/Bengali/India
+ { 16, 31, 25, 46, 44, 59, 37, 3872, 45, 43, 101, 8220, 8221, 8216, 8217, 93,9 , 93,9 , 93,9 , 93,9 , 72,10 , 293,30 , 95,22 , 117,27 , 2663,63 , 2726,191 , 2917,27 , 2944,27 , 2971,132 , 3103,27 , 1208,34 , 1242,79 , 1321,27 , 1208,34 , 1242,79 , 1321,27 , 43,5 , 40,6 , {66,84,78}, 133,3 , 2317,15 , 4,4 , 4,0 , 403,6 , 409,5 , 2, 1, 7, 6, 7 }, // Dzongkha/Tibetan/Bhutan
+ { 19, 7, 74, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 3130,55 , 3185,78 , 158,27 , 3130,55 , 3185,78 , 158,27 , 1348,33 , 1381,43 , 1424,21 , 1348,33 , 1381,43 , 1424,21 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2332,11 , 14,5 , 4,0 , 414,9 , 423,5 , 2, 1, 1, 6, 7 }, // Breton/Latin/France
+ { 20, 2, 33, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 102,7 , 102,7 , 187,8 , 340,18 , 37,5 , 8,10 , 3263,59 , 3322,82 , 3404,24 , 3263,59 , 3322,82 , 3404,24 , 1445,21 , 1466,55 , 1521,14 , 1445,21 , 1466,55 , 1521,14 , 48,7 , 46,7 , {66,71,78}, 136,3 , 2343,47 , 25,5 , 4,0 , 428,9 , 437,8 , 2, 1, 1, 6, 7 }, // Bulgarian/Cyrillic/Bulgaria
+ { 21, 25, 147, 46, 44, 4170, 37, 4160, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 242,8 , 269,18 , 37,5 , 8,10 , 3428,43 , 3471,88 , 3559,24 , 3428,43 , 3471,88 , 3559,24 , 1535,25 , 1560,54 , 1614,14 , 1535,25 , 1560,54 , 1614,14 , 55,5 , 53,3 , {77,77,75}, 139,1 , 2390,18 , 14,5 , 4,0 , 445,3 , 448,6 , 0, 0, 7, 6, 7 }, // Burmese/Myanmar/Myanmar
+ { 22, 2, 20, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 0,6 , 0,6 , 358,6 , 10,17 , 144,5 , 149,10 , 3583,48 , 3631,99 , 3730,24 , 3754,48 , 3802,95 , 3897,24 , 1628,21 , 1649,56 , 1705,14 , 1628,21 , 1649,56 , 1705,14 , 60,10 , 56,13 , {66,89,82}, 140,2 , 2408,23 , 4,4 , 4,0 , 454,10 , 464,8 , 0, 0, 7, 6, 7 }, // Belarusian/Cyrillic/Belarus
+ { 23, 20, 36, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 109,9 , 364,8 , 10,17 , 18,7 , 25,12 , 3921,71 , 3921,71 , 158,27 , 3921,71 , 3921,71 , 158,27 , 1719,46 , 1719,46 , 1765,14 , 1719,46 , 1719,46 , 1765,14 , 70,5 , 69,5 , {75,72,82}, 142,1 , 2431,18 , 4,4 , 8,6 , 472,5 , 477,7 , 2, 1, 7, 6, 7 }, // Khmer/Khmer/Cambodia
+ { 24, 7, 197, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 118,7 , 118,7 , 27,8 , 372,21 , 159,4 , 163,9 , 3992,60 , 4052,82 , 4134,24 , 4158,93 , 4251,115 , 4366,24 , 1779,21 , 1800,60 , 1779,21 , 1860,28 , 1888,60 , 1779,21 , 75,4 , 74,4 , {69,85,82}, 131,1 , 2449,20 , 4,4 , 8,6 , 484,6 , 490,7 , 2, 1, 1, 6, 7 }, // Catalan/Latin/Spain
+ { 24, 7, 5, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 118,7 , 118,7 , 27,8 , 372,21 , 159,4 , 163,9 , 3992,60 , 4052,82 , 4134,24 , 4158,93 , 4251,115 , 4366,24 , 1779,21 , 1800,60 , 1779,21 , 1860,28 , 1888,60 , 1779,21 , 75,4 , 74,4 , {69,85,82}, 131,1 , 2449,20 , 4,4 , 8,6 , 484,6 , 497,7 , 2, 1, 1, 6, 7 }, // Catalan/Latin/Andorra
+ { 25, 5, 44, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 125,5 , 125,5 , 130,5 , 130,5 , 393,6 , 399,13 , 172,6 , 178,10 , 4390,39 , 4429,38 , 158,27 , 4390,39 , 4429,38 , 158,27 , 1948,21 , 1969,28 , 1997,14 , 1948,21 , 1969,28 , 1997,14 , 79,2 , 78,2 , {67,78,89}, 143,1 , 2469,10 , 4,4 , 8,6 , 504,4 , 508,2 , 2, 1, 7, 6, 7 }, // Chinese/Simplified Han/China
+ { 25, 5, 97, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 125,5 , 125,5 , 130,5 , 130,5 , 287,6 , 399,13 , 172,6 , 178,10 , 4390,39 , 4429,38 , 158,27 , 4390,39 , 4429,38 , 158,27 , 1948,21 , 1969,28 , 1997,14 , 1948,21 , 1969,28 , 1997,14 , 79,2 , 78,2 , {72,75,68}, 12,1 , 2479,9 , 4,4 , 4,0 , 504,4 , 510,9 , 2, 1, 7, 6, 7 }, // Chinese/Simplified Han/HongKong
+ { 25, 5, 126, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 125,5 , 125,5 , 130,5 , 130,5 , 287,6 , 399,13 , 172,6 , 178,10 , 4390,39 , 4429,38 , 158,27 , 4390,39 , 4429,38 , 158,27 , 1948,21 , 1969,28 , 1997,14 , 1948,21 , 1969,28 , 1997,14 , 79,2 , 78,2 , {77,79,80}, 144,4 , 2488,10 , 4,4 , 4,0 , 504,4 , 519,9 , 2, 1, 7, 6, 7 }, // Chinese/Simplified Han/Macau
+ { 25, 5, 190, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 125,5 , 125,5 , 130,5 , 130,5 , 27,8 , 399,13 , 188,7 , 178,10 , 4390,39 , 4429,38 , 158,27 , 4390,39 , 4429,38 , 158,27 , 1948,21 , 1969,28 , 1997,14 , 1948,21 , 1969,28 , 1997,14 , 79,2 , 78,2 , {83,71,68}, 12,1 , 2498,11 , 4,4 , 4,0 , 504,4 , 528,3 , 2, 1, 7, 6, 7 }, // Chinese/Simplified Han/Singapore
+ { 25, 6, 97, 46, 44, 59, 37, 48, 45, 43, 101, 12300, 12301, 12302, 12303, 125,5 , 125,5 , 130,5 , 130,5 , 287,6 , 399,13 , 172,6 , 195,13 , 4390,39 , 4390,39 , 158,27 , 4390,39 , 4390,39 , 158,27 , 2011,21 , 1969,28 , 1997,14 , 2011,21 , 1969,28 , 1997,14 , 79,2 , 78,2 , {72,75,68}, 12,1 , 2479,9 , 4,4 , 8,6 , 531,4 , 535,14 , 2, 1, 7, 6, 7 }, // Chinese/Traditional Han/HongKong
+ { 25, 6, 126, 46, 44, 59, 37, 48, 45, 43, 101, 12300, 12301, 12302, 12303, 125,5 , 125,5 , 130,5 , 130,5 , 412,7 , 419,15 , 172,6 , 195,13 , 4390,39 , 4390,39 , 158,27 , 4390,39 , 4390,39 , 158,27 , 2011,21 , 1969,28 , 1997,14 , 2011,21 , 1969,28 , 1997,14 , 79,2 , 78,2 , {77,79,80}, 144,4 , 2509,10 , 4,4 , 4,0 , 531,4 , 549,14 , 2, 1, 7, 6, 7 }, // Chinese/Traditional Han/Macau
+ { 25, 6, 208, 46, 44, 59, 37, 48, 45, 43, 101, 12300, 12301, 12302, 12303, 125,5 , 125,5 , 130,5 , 130,5 , 179,8 , 399,13 , 172,6 , 208,11 , 4390,39 , 4390,39 , 158,27 , 4390,39 , 4390,39 , 158,27 , 2011,21 , 1969,28 , 1997,14 , 2011,21 , 1969,28 , 1997,14 , 79,2 , 78,2 , {84,87,68}, 148,3 , 2519,10 , 4,4 , 4,0 , 531,4 , 563,2 , 2, 1, 7, 6, 7 }, // Chinese/Traditional Han/Taiwan
+ { 27, 7, 54, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 118,7 , 118,7 , 434,9 , 443,19 , 37,5 , 8,10 , 4467,49 , 4516,94 , 4610,39 , 4467,49 , 4649,98 , 4610,39 , 2032,28 , 2060,58 , 2118,14 , 2032,28 , 2060,58 , 2132,14 , 0,2 , 0,2 , {72,82,75}, 151,2 , 2529,74 , 25,5 , 4,0 , 565,8 , 573,8 , 2, 1, 1, 6, 7 }, // Croatian/Latin/Croatia
+ { 27, 7, 27, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 118,7 , 118,7 , 434,9 , 443,19 , 37,5 , 8,10 , 4467,49 , 4516,94 , 4610,39 , 4467,49 , 4649,98 , 4610,39 , 2032,28 , 2060,58 , 2118,14 , 2032,28 , 2060,58 , 2132,14 , 0,2 , 0,2 , {66,65,77}, 153,2 , 2603,106 , 25,5 , 4,0 , 565,8 , 581,19 , 2, 1, 1, 6, 7 }, // Croatian/Latin/BosniaAndHerzegowina
+ { 28, 7, 57, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 135,7 , 135,7 , 187,8 , 462,18 , 61,4 , 219,9 , 4747,48 , 4795,82 , 4877,24 , 4747,48 , 4901,84 , 158,27 , 2146,21 , 2167,49 , 2216,14 , 2146,21 , 2167,49 , 2216,14 , 81,4 , 80,4 , {67,90,75}, 155,2 , 2709,56 , 25,5 , 4,0 , 600,7 , 607,15 , 2, 1, 1, 6, 7 }, // Czech/Latin/CzechRepublic
+ { 29, 7, 58, 44, 46, 44, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 142,8 , 142,8 , 27,8 , 480,23 , 144,5 , 149,10 , 4985,48 , 5033,84 , 134,24 , 5117,59 , 5033,84 , 134,24 , 2230,28 , 2258,51 , 2309,14 , 2323,35 , 2258,51 , 2309,14 , 0,2 , 0,2 , {68,75,75}, 157,2 , 2765,42 , 25,5 , 4,0 , 622,5 , 627,7 , 2, 1, 1, 6, 7 }, // Danish/Latin/Denmark
+ { 30, 7, 151, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 503,8 , 99,16 , 37,5 , 8,10 , 5176,48 , 5224,88 , 134,24 , 5312,59 , 5224,88 , 134,24 , 2358,21 , 2379,59 , 2438,14 , 2358,21 , 2379,59 , 2438,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2807,19 , 14,5 , 19,6 , 634,10 , 644,9 , 2, 1, 1, 6, 7 }, // Dutch/Latin/Netherlands
+ { 30, 7, 12, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 503,8 , 99,16 , 37,5 , 8,10 , 5176,48 , 5224,88 , 134,24 , 5312,59 , 5224,88 , 134,24 , 2358,21 , 2379,59 , 2438,14 , 2358,21 , 2379,59 , 2438,14 , 0,2 , 0,2 , {65,87,71}, 159,4 , 2826,55 , 14,5 , 19,6 , 634,10 , 653,5 , 2, 1, 1, 6, 7 }, // Dutch/Latin/Aruba
+ { 30, 7, 21, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 511,7 , 99,16 , 37,5 , 8,10 , 5176,48 , 5224,88 , 134,24 , 5312,59 , 5224,88 , 134,24 , 2358,21 , 2379,59 , 2438,14 , 2358,21 , 2379,59 , 2438,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2807,19 , 25,5 , 4,0 , 658,6 , 664,6 , 2, 1, 1, 6, 7 }, // Dutch/Latin/Belgium
+ { 30, 7, 152, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 503,8 , 99,16 , 37,5 , 8,10 , 5176,48 , 5224,88 , 134,24 , 5312,59 , 5224,88 , 134,24 , 2358,21 , 2379,59 , 2438,14 , 2358,21 , 2379,59 , 2438,14 , 0,2 , 0,2 , {65,78,71}, 163,4 , 2881,97 , 14,5 , 19,6 , 634,10 , 670,7 , 2, 1, 1, 6, 7 }, // Dutch/Latin/CuraSao
+ { 30, 7, 202, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 503,8 , 99,16 , 37,5 , 8,10 , 5176,48 , 5224,88 , 134,24 , 5312,59 , 5224,88 , 134,24 , 2358,21 , 2379,59 , 2438,14 , 2358,21 , 2379,59 , 2438,14 , 0,2 , 0,2 , {83,82,68}, 12,1 , 2978,24 , 14,5 , 19,6 , 634,10 , 677,8 , 2, 1, 1, 6, 7 }, // Dutch/Latin/Suriname
+ { 30, 7, 256, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 6,8 , 6,8 , 503,8 , 99,16 , 37,5 , 8,10 , 5176,48 , 5224,88 , 134,24 , 5312,59 , 5224,88 , 134,24 , 2358,21 , 2379,59 , 2438,14 , 2358,21 , 2379,59 , 2438,14 , 0,2 , 0,2 , {65,78,71}, 163,4 , 2881,97 , 14,5 , 19,6 , 634,10 , 685,12 , 2, 1, 1, 6, 7 }, // Dutch/Latin/SintMaarten
+ { 31, 7, 225, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 3002,35 , 4,4 , 8,6 , 697,12 , 709,13 , 2, 1, 7, 6, 7 }, // English/Latin/UnitedStates
+ { 31, 3, 225, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 5371,80 , 5451,154 , 5605,36 , 5371,80 , 5451,154 , 5605,36 , 2452,49 , 2501,85 , 2586,21 , 2452,49 , 2501,85 , 2586,21 , 85,4 , 84,4 , {85,83,68}, 12,1 , 0,7 , 14,5 , 4,0 , 722,10 , 732,25 , 2, 1, 7, 6, 7 }, // English/Deseret/UnitedStates
+ { 31, 7, 4, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 3002,35 , 4,4 , 8,6 , 757,7 , 764,14 , 2, 1, 7, 6, 7 }, // English/Latin/AmericanSamoa
+ { 31, 7, 9, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,67,68}, 167,3 , 3037,71 , 4,4 , 8,6 , 757,7 , 778,19 , 2, 1, 7, 6, 7 }, // English/Latin/AntiguaAndBarbuda
+ { 31, 7, 13, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 511,7 , 10,17 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {65,85,68}, 12,1 , 3108,59 , 4,4 , 4,0 , 797,18 , 815,9 , 2, 1, 7, 6, 7 }, // English/Latin/Australia
+ { 31, 7, 16, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {66,83,68}, 12,1 , 3167,53 , 4,4 , 8,6 , 757,7 , 824,7 , 2, 1, 7, 6, 7 }, // English/Latin/Bahamas
+ { 31, 7, 19, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {66,66,68}, 12,1 , 3220,56 , 4,4 , 8,6 , 757,7 , 831,8 , 2, 1, 1, 6, 7 }, // English/Latin/Barbados
+ { 31, 7, 21, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 27,8 , 99,16 , 37,5 , 228,24 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {69,85,82}, 131,1 , 2807,19 , 25,5 , 4,0 , 757,7 , 839,7 , 2, 1, 1, 6, 7 }, // English/Latin/Belgium
+ { 31, 7, 22, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 27,8 , 524,12 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {66,90,68}, 12,1 , 3276,47 , 4,4 , 4,0 , 757,7 , 846,6 , 2, 1, 7, 6, 7 }, // English/Latin/Belize
+ { 31, 7, 24, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {66,77,68}, 12,1 , 3323,53 , 4,4 , 8,6 , 757,7 , 852,7 , 2, 1, 1, 6, 7 }, // English/Latin/Bermuda
+ { 31, 7, 28, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 27,8 , 82,17 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {66,87,80}, 170,1 , 3376,50 , 4,4 , 4,0 , 757,7 , 859,8 , 2, 1, 7, 6, 7 }, // English/Latin/Botswana
+ { 31, 7, 37, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,65,70}, 36,4 , 3426,50 , 4,4 , 8,6 , 757,7 , 867,8 , 0, 0, 1, 6, 7 }, // English/Latin/Cameroon
+ { 31, 7, 38, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {67,65,68}, 12,1 , 3476,53 , 4,4 , 8,6 , 875,16 , 891,6 , 2, 0, 7, 6, 7 }, // English/Latin/Canada
+ { 31, 7, 40, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {75,89,68}, 12,1 , 3529,71 , 4,4 , 8,6 , 757,7 , 897,14 , 2, 1, 1, 6, 7 }, // English/Latin/CaymanIslands
+ { 31, 7, 60, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,67,68}, 167,3 , 3037,71 , 4,4 , 8,6 , 757,7 , 911,8 , 2, 1, 7, 6, 7 }, // English/Latin/Dominica
+ { 31, 7, 72, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {70,74,68}, 12,1 , 3600,47 , 4,4 , 8,6 , 757,7 , 919,4 , 2, 1, 1, 6, 7 }, // English/Latin/Fiji
+ { 31, 7, 75, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 141,10 , 10,17 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {71,66,80}, 171,1 , 3647,47 , 4,4 , 4,0 , 757,7 , 923,8 , 2, 1, 1, 6, 7 }, // English/Latin/Guernsey
+ { 31, 7, 80, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {71,77,68}, 172,1 , 3694,50 , 4,4 , 8,6 , 757,7 , 931,6 , 2, 1, 1, 6, 7 }, // English/Latin/Gambia
+ { 31, 7, 83, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {71,72,83}, 173,3 , 3744,47 , 4,4 , 8,6 , 757,7 , 937,5 , 2, 1, 1, 6, 7 }, // English/Latin/Ghana
+ { 31, 7, 84, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 141,10 , 10,17 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {71,73,80}, 171,1 , 3791,53 , 4,4 , 4,0 , 757,7 , 942,9 , 2, 1, 1, 6, 7 }, // English/Latin/Gibraltar
+ { 31, 7, 87, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,67,68}, 167,3 , 3037,71 , 4,4 , 8,6 , 757,7 , 951,7 , 2, 1, 1, 6, 7 }, // English/Latin/Grenada
+ { 31, 7, 89, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 3002,35 , 4,4 , 8,6 , 757,7 , 958,4 , 2, 1, 7, 6, 7 }, // English/Latin/Guam
+ { 31, 7, 93, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {71,89,68}, 12,1 , 3844,56 , 4,4 , 8,6 , 757,7 , 962,6 , 0, 0, 1, 6, 7 }, // English/Latin/Guyana
+ { 31, 7, 97, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 287,6 , 224,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {72,75,68}, 12,1 , 3900,56 , 4,4 , 8,6 , 757,7 , 968,19 , 2, 1, 7, 6, 7 }, // English/Latin/HongKong
+ { 31, 7, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 27,8 , 99,16 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {73,78,82}, 122,1 , 3956,44 , 14,5 , 4,0 , 757,7 , 987,5 , 2, 1, 7, 7, 7 }, // English/Latin/India
+ { 31, 7, 104, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 141,10 , 99,16 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 75,4 , 74,4 , {69,85,82}, 131,1 , 2807,19 , 4,4 , 4,0 , 757,7 , 992,7 , 2, 1, 7, 6, 7 }, // English/Latin/Ireland
+ { 31, 7, 107, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 287,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {74,77,68}, 12,1 , 4000,53 , 4,4 , 4,0 , 757,7 , 999,7 , 2, 1, 7, 6, 7 }, // English/Latin/Jamaica
+ { 31, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {75,69,83}, 2,3 , 4053,53 , 4,4 , 8,6 , 757,7 , 1006,5 , 2, 1, 7, 6, 7 }, // English/Latin/Kenya
+ { 31, 7, 112, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {65,85,68}, 12,1 , 3108,59 , 4,4 , 8,6 , 757,7 , 1011,8 , 2, 1, 1, 6, 7 }, // English/Latin/Kiribati
+ { 31, 7, 120, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 4106,61 , 4,4 , 8,6 , 757,7 , 1019,7 , 2, 1, 1, 6, 7 }, // English/Latin/Lesotho
+ { 31, 7, 121, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {76,82,68}, 12,1 , 4167,53 , 4,4 , 8,6 , 757,7 , 1026,7 , 2, 1, 1, 6, 7 }, // English/Latin/Liberia
+ { 31, 7, 128, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {77,71,65}, 176,2 , 4220,54 , 4,4 , 8,6 , 757,7 , 1033,10 , 0, 0, 1, 6, 7 }, // English/Latin/Madagascar
+ { 31, 7, 129, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {77,87,75}, 178,2 , 4274,53 , 4,4 , 8,6 , 757,7 , 1043,6 , 2, 1, 1, 6, 7 }, // English/Latin/Malawi
+ { 31, 7, 133, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 141,10 , 10,17 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {69,85,82}, 131,1 , 2807,19 , 4,4 , 4,0 , 757,7 , 1049,5 , 2, 1, 7, 6, 7 }, // English/Latin/Malta
+ { 31, 7, 134, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 3002,35 , 4,4 , 8,6 , 757,7 , 1054,16 , 2, 1, 7, 6, 7 }, // English/Latin/MarshallIslands
+ { 31, 7, 137, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {77,85,82}, 180,2 , 4327,53 , 4,4 , 8,6 , 757,7 , 1070,9 , 0, 0, 1, 6, 7 }, // English/Latin/Mauritius
+ { 31, 7, 140, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 3002,35 , 4,4 , 8,6 , 757,7 , 1079,10 , 2, 1, 1, 6, 7 }, // English/Latin/Micronesia
+ { 31, 7, 148, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {78,65,68}, 12,1 , 4380,53 , 4,4 , 4,0 , 757,7 , 1089,7 , 2, 1, 1, 6, 7 }, // English/Latin/Namibia
+ { 31, 7, 154, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 511,7 , 10,17 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {78,90,68}, 12,1 , 4433,62 , 4,4 , 4,0 , 757,7 , 1096,11 , 2, 1, 7, 6, 7 }, // English/Latin/NewZealand
+ { 31, 7, 157, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {78,71,78}, 182,1 , 4495,50 , 4,4 , 8,6 , 757,7 , 1107,7 , 2, 1, 1, 6, 7 }, // English/Latin/Nigeria
+ { 31, 7, 160, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 3002,35 , 4,4 , 8,6 , 757,7 , 1114,24 , 2, 1, 1, 6, 7 }, // English/Latin/NorthernMarianaIslands
+ { 31, 7, 163, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 27,8 , 99,16 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {80,75,82}, 180,2 , 4545,53 , 14,5 , 4,0 , 757,7 , 1138,8 , 0, 0, 7, 6, 7 }, // English/Latin/Pakistan
+ { 31, 7, 164, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 3002,35 , 4,4 , 8,6 , 757,7 , 1146,5 , 2, 1, 1, 6, 7 }, // English/Latin/Palau
+ { 31, 7, 167, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {80,71,75}, 139,1 , 4598,73 , 4,4 , 8,6 , 757,7 , 1151,16 , 2, 1, 1, 6, 7 }, // English/Latin/PapuaNewGuinea
+ { 31, 7, 170, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {80,72,80}, 183,1 , 4671,42 , 4,4 , 8,6 , 757,7 , 1167,11 , 2, 1, 7, 6, 7 }, // English/Latin/Philippines
+ { 31, 7, 174, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 3002,35 , 4,4 , 8,6 , 757,7 , 1178,11 , 2, 1, 7, 6, 7 }, // English/Latin/PuertoRico
+ { 31, 7, 180, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,67,68}, 167,3 , 3037,71 , 4,4 , 8,6 , 757,7 , 1189,21 , 2, 1, 1, 6, 7 }, // English/Latin/SaintKittsAndNevis
+ { 31, 7, 181, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,67,68}, 167,3 , 3037,71 , 4,4 , 8,6 , 757,7 , 1210,11 , 2, 1, 1, 6, 7 }, // English/Latin/SaintLucia
+ { 31, 7, 182, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {88,67,68}, 167,3 , 3037,71 , 4,4 , 8,6 , 757,7 , 1221,32 , 2, 1, 1, 6, 7 }, // English/Latin/SaintVincentAndTheGrenadines
+ { 31, 7, 183, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {87,83,84}, 184,3 , 4713,40 , 4,4 , 8,6 , 757,7 , 1253,5 , 2, 1, 7, 6, 7 }, // English/Latin/Samoa
+ { 31, 7, 188, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {83,67,82}, 187,2 , 4753,59 , 4,4 , 8,6 , 757,7 , 1258,10 , 2, 1, 1, 6, 7 }, // English/Latin/Seychelles
+ { 31, 7, 189, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {83,76,76}, 189,2 , 4812,68 , 4,4 , 8,6 , 757,7 , 1268,12 , 0, 0, 1, 6, 7 }, // English/Latin/SierraLeone
+ { 31, 7, 190, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 287,6 , 224,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {83,71,68}, 12,1 , 4880,56 , 4,4 , 8,6 , 757,7 , 1280,9 , 2, 1, 7, 6, 7 }, // English/Latin/Singapore
+ { 31, 7, 193, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {83,66,68}, 12,1 , 4936,74 , 4,4 , 8,6 , 757,7 , 1289,15 , 2, 1, 1, 6, 7 }, // English/Latin/SolomonIslands
+ { 31, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 536,10 , 82,17 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 4106,61 , 4,4 , 8,6 , 757,7 , 1304,12 , 2, 1, 7, 6, 7 }, // English/Latin/SouthAfrica
+ { 31, 7, 204, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {83,90,76}, 191,1 , 5010,53 , 4,4 , 8,6 , 757,7 , 1316,9 , 2, 1, 1, 6, 7 }, // English/Latin/Swaziland
+ { 31, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {84,90,83}, 192,3 , 5063,62 , 4,4 , 8,6 , 757,7 , 1325,8 , 0, 0, 1, 6, 7 }, // English/Latin/Tanzania
+ { 31, 7, 214, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {84,79,80}, 195,2 , 5125,49 , 4,4 , 8,6 , 757,7 , 1333,5 , 2, 1, 1, 6, 7 }, // English/Latin/Tonga
+ { 31, 7, 215, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {84,84,68}, 12,1 , 5174,86 , 4,4 , 4,0 , 757,7 , 1338,19 , 2, 1, 7, 6, 7 }, // English/Latin/TrinidadAndTobago
+ { 31, 7, 219, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 3002,35 , 4,4 , 8,6 , 757,7 , 1357,24 , 2, 1, 1, 6, 7 }, // English/Latin/TurksAndCaicosIslands
+ { 31, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,71,88}, 197,3 , 5260,56 , 4,4 , 8,6 , 757,7 , 1381,6 , 0, 0, 1, 6, 7 }, // English/Latin/Uganda
+ { 31, 7, 224, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 141,10 , 10,17 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {71,66,80}, 171,1 , 3647,47 , 4,4 , 4,0 , 1387,15 , 1402,14 , 2, 1, 1, 6, 7 }, // English/Latin/UnitedKingdom
+ { 31, 7, 226, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 3002,35 , 4,4 , 8,6 , 757,7 , 1416,21 , 2, 1, 7, 6, 7 }, // English/Latin/UnitedStatesMinorOutlyingIslands
+ { 31, 7, 229, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {86,85,86}, 200,2 , 5316,44 , 4,4 , 8,6 , 757,7 , 1437,7 , 0, 0, 1, 6, 7 }, // English/Latin/Vanuatu
+ { 31, 7, 233, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 3002,35 , 4,4 , 8,6 , 757,7 , 1444,22 , 2, 1, 1, 6, 7 }, // English/Latin/BritishVirginIslands
+ { 31, 7, 234, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 3002,35 , 4,4 , 8,6 , 757,7 , 1466,19 , 2, 1, 7, 6, 7 }, // English/Latin/UnitedStatesVirginIslands
+ { 31, 7, 239, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {90,77,87}, 202,2 , 5360,50 , 4,4 , 8,6 , 757,7 , 1485,6 , 2, 1, 1, 6, 7 }, // English/Latin/Zambia
+ { 31, 7, 240, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 364,8 , 82,17 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 204,3 , 3002,35 , 4,4 , 4,0 , 757,7 , 1491,8 , 2, 1, 7, 6, 7 }, // English/Latin/Zimbabwe
+ { 31, 7, 251, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 141,10 , 10,17 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {71,66,80}, 171,1 , 3647,47 , 4,4 , 4,0 , 757,7 , 1499,11 , 2, 1, 1, 6, 7 }, // English/Latin/IsleOfMan
+ { 31, 7, 252, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 160,9 , 160,9 , 141,10 , 10,17 , 37,5 , 8,10 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 89,2 , 88,2 , {71,66,80}, 171,1 , 3647,47 , 4,4 , 4,0 , 757,7 , 1510,6 , 2, 1, 1, 6, 7 }, // English/Latin/Jersey
+ { 31, 7, 254, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 150,10 , 160,9 , 518,6 , 35,18 , 18,7 , 25,12 , 0,48 , 48,86 , 134,24 , 0,48 , 48,86 , 134,24 , 0,28 , 28,57 , 85,14 , 0,28 , 28,57 , 85,14 , 0,2 , 0,2 , {83,83,80}, 171,1 , 5410,68 , 4,4 , 8,6 , 757,7 , 1516,11 , 2, 1, 1, 6, 7 }, // English/Latin/SouthSudan
+ { 33, 7, 68, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 169,8 , 169,8 , 187,8 , 462,18 , 61,4 , 252,9 , 5641,59 , 5700,91 , 5791,24 , 5641,59 , 5700,91 , 5791,24 , 2607,14 , 2621,63 , 2607,14 , 2607,14 , 2621,63 , 2607,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 5478,20 , 25,5 , 30,7 , 1527,5 , 1532,5 , 2, 1, 1, 6, 7 }, // Estonian/Latin/Estonia
+ { 34, 7, 71, 44, 46, 59, 37, 48, 8722, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 142,8 , 142,8 , 503,8 , 82,17 , 37,5 , 8,10 , 5815,48 , 5863,83 , 134,24 , 5815,48 , 5863,83 , 134,24 , 2684,28 , 2712,74 , 2786,14 , 2684,28 , 2712,74 , 2786,14 , 0,2 , 0,2 , {68,75,75}, 157,2 , 5498,42 , 4,4 , 43,5 , 1537,8 , 1545,7 , 2, 1, 1, 6, 7 }, // Faroese/Latin/FaroeIslands
+ { 36, 7, 73, 44, 160, 59, 37, 48, 45, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 169,8 , 169,8 , 546,8 , 554,17 , 159,4 , 163,9 , 5946,69 , 6015,105 , 6120,24 , 6144,129 , 6144,129 , 6120,24 , 2800,21 , 2821,67 , 2888,14 , 2800,21 , 2902,81 , 2888,14 , 91,3 , 90,3 , {69,85,82}, 131,1 , 5540,20 , 25,5 , 4,0 , 1552,5 , 1557,5 , 2, 1, 1, 6, 7 }, // Finnish/Latin/Finland
+ { 37, 7, 74, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 30,7 , 1562,8 , 1570,6 , 2, 1, 1, 6, 7 }, // French/Latin/France
+ { 37, 7, 3, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {68,90,68}, 207,2 , 5560,51 , 25,5 , 30,7 , 1562,8 , 1576,7 , 2, 1, 6, 4, 5 }, // French/Latin/Algeria
+ { 37, 7, 21, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 511,7 , 99,16 , 37,5 , 261,23 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 30,7 , 1562,8 , 1583,8 , 2, 1, 1, 6, 7 }, // French/Latin/Belgium
+ { 37, 7, 23, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,79,70}, 209,3 , 5611,59 , 25,5 , 30,7 , 1562,8 , 1591,5 , 0, 0, 1, 6, 7 }, // French/Latin/Benin
+ { 37, 7, 34, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,79,70}, 209,3 , 5611,59 , 25,5 , 30,7 , 1562,8 , 1596,12 , 0, 0, 1, 6, 7 }, // French/Latin/BurkinaFaso
+ { 37, 7, 35, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {66,73,70}, 212,3 , 5670,53 , 25,5 , 30,7 , 1562,8 , 1608,7 , 0, 0, 1, 6, 7 }, // French/Latin/Burundi
+ { 37, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,65,70}, 36,4 , 5723,56 , 25,5 , 30,7 , 1562,8 , 1615,8 , 0, 0, 1, 6, 7 }, // French/Latin/Cameroon
+ { 37, 7, 38, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 177,8 , 177,8 , 115,8 , 99,16 , 37,5 , 228,24 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {67,65,68}, 12,1 , 5779,54 , 25,5 , 30,7 , 1623,17 , 891,6 , 2, 0, 7, 6, 7 }, // French/Latin/Canada
+ { 37, 7, 41, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,65,70}, 36,4 , 5723,56 , 25,5 , 30,7 , 1562,8 , 1640,25 , 0, 0, 1, 6, 7 }, // French/Latin/CentralAfricanRepublic
+ { 37, 7, 42, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,65,70}, 36,4 , 5723,56 , 25,5 , 30,7 , 1562,8 , 1665,5 , 0, 0, 1, 6, 7 }, // French/Latin/Chad
+ { 37, 7, 48, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {75,77,70}, 215,2 , 5833,51 , 25,5 , 30,7 , 1562,8 , 1670,7 , 0, 0, 1, 6, 7 }, // French/Latin/Comoros
+ { 37, 7, 49, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {67,68,70}, 217,2 , 5884,53 , 25,5 , 30,7 , 1562,8 , 1677,32 , 2, 1, 1, 6, 7 }, // French/Latin/CongoKinshasa
+ { 37, 7, 50, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,65,70}, 36,4 , 5723,56 , 25,5 , 30,7 , 1562,8 , 1709,17 , 0, 0, 1, 6, 7 }, // French/Latin/CongoBrazzaville
+ { 37, 7, 53, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,79,70}, 209,3 , 5611,59 , 25,5 , 30,7 , 1562,8 , 1726,13 , 0, 0, 1, 6, 7 }, // French/Latin/IvoryCoast
+ { 37, 7, 59, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {68,74,70}, 5,3 , 5937,57 , 25,5 , 30,7 , 1562,8 , 1739,8 , 0, 0, 6, 6, 7 }, // French/Latin/Djibouti
+ { 37, 7, 66, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,65,70}, 36,4 , 5723,56 , 25,5 , 30,7 , 1562,8 , 1747,18 , 0, 0, 1, 6, 7 }, // French/Latin/EquatorialGuinea
+ { 37, 7, 76, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 30,7 , 1562,8 , 1765,16 , 2, 1, 1, 6, 7 }, // French/Latin/FrenchGuiana
+ { 37, 7, 77, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,80,70}, 219,4 , 5994,35 , 25,5 , 30,7 , 1562,8 , 1781,19 , 0, 0, 1, 6, 7 }, // French/Latin/FrenchPolynesia
+ { 37, 7, 79, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,65,70}, 36,4 , 5723,56 , 25,5 , 30,7 , 1562,8 , 1800,5 , 0, 0, 1, 6, 7 }, // French/Latin/Gabon
+ { 37, 7, 88, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 30,7 , 1562,8 , 1805,10 , 2, 1, 1, 6, 7 }, // French/Latin/Guadeloupe
+ { 37, 7, 91, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {71,78,70}, 223,2 , 6029,48 , 25,5 , 30,7 , 1562,8 , 1815,6 , 0, 0, 1, 6, 7 }, // French/Latin/Guinea
+ { 37, 7, 94, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {72,84,71}, 225,1 , 6077,57 , 25,5 , 30,7 , 1562,8 , 1821,5 , 2, 1, 1, 6, 7 }, // French/Latin/Haiti
+ { 37, 7, 125, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 30,7 , 1562,8 , 1826,10 , 2, 1, 1, 6, 7 }, // French/Latin/Luxembourg
+ { 37, 7, 128, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {77,71,65}, 176,2 , 6134,54 , 25,5 , 30,7 , 1562,8 , 1033,10 , 0, 0, 1, 6, 7 }, // French/Latin/Madagascar
+ { 37, 7, 132, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,79,70}, 209,3 , 5611,59 , 25,5 , 30,7 , 1562,8 , 1836,4 , 0, 0, 1, 6, 7 }, // French/Latin/Mali
+ { 37, 7, 135, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 30,7 , 1562,8 , 1840,10 , 2, 1, 1, 6, 7 }, // French/Latin/Martinique
+ { 37, 7, 136, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {77,82,79}, 226,2 , 6188,66 , 25,5 , 30,7 , 1562,8 , 1850,10 , 0, 0, 1, 6, 7 }, // French/Latin/Mauritania
+ { 37, 7, 137, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {77,85,82}, 180,2 , 6254,63 , 25,5 , 30,7 , 1562,8 , 1860,7 , 0, 0, 1, 6, 7 }, // French/Latin/Mauritius
+ { 37, 7, 138, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 30,7 , 1562,8 , 1867,7 , 2, 1, 1, 6, 7 }, // French/Latin/Mayotte
+ { 37, 7, 142, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 30,7 , 1562,8 , 1874,6 , 2, 1, 1, 6, 7 }, // French/Latin/Monaco
+ { 37, 7, 145, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {77,65,68}, 0,0 , 6317,54 , 25,5 , 30,7 , 1562,8 , 1880,5 , 2, 1, 6, 5, 6 }, // French/Latin/Morocco
+ { 37, 7, 153, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,80,70}, 219,4 , 5994,35 , 25,5 , 30,7 , 1562,8 , 1885,18 , 0, 0, 1, 6, 7 }, // French/Latin/NewCaledonia
+ { 37, 7, 156, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,79,70}, 209,3 , 5611,59 , 25,5 , 30,7 , 1562,8 , 1903,5 , 0, 0, 1, 6, 7 }, // French/Latin/Niger
+ { 37, 7, 176, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 30,7 , 1562,8 , 1908,7 , 2, 1, 1, 6, 7 }, // French/Latin/Reunion
+ { 37, 7, 179, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {82,87,70}, 228,2 , 6371,50 , 25,5 , 30,7 , 1562,8 , 1915,6 , 0, 0, 1, 6, 7 }, // French/Latin/Rwanda
+ { 37, 7, 187, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,79,70}, 209,3 , 5611,59 , 25,5 , 30,7 , 1562,8 , 1921,7 , 0, 0, 1, 6, 7 }, // French/Latin/Senegal
+ { 37, 7, 188, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {83,67,82}, 187,2 , 6421,71 , 25,5 , 30,7 , 1562,8 , 1258,10 , 2, 1, 1, 6, 7 }, // French/Latin/Seychelles
+ { 37, 7, 206, 46, 39, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 177,8 , 177,8 , 187,8 , 10,17 , 37,5 , 284,14 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {67,72,70}, 230,3 , 6492,45 , 14,5 , 48,5 , 1928,15 , 1943,6 , 2, 0, 1, 6, 7 }, // French/Latin/Switzerland
+ { 37, 7, 207, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {83,89,80}, 233,2 , 6537,51 , 25,5 , 30,7 , 1562,8 , 1949,5 , 0, 0, 6, 5, 6 }, // French/Latin/Syria
+ { 37, 7, 212, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {88,79,70}, 209,3 , 5611,59 , 25,5 , 30,7 , 1562,8 , 1954,4 , 0, 0, 1, 6, 7 }, // French/Latin/Togo
+ { 37, 7, 216, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {84,78,68}, 235,2 , 6588,51 , 25,5 , 30,7 , 1562,8 , 1958,7 , 3, 0, 7, 5, 6 }, // French/Latin/Tunisia
+ { 37, 7, 229, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {86,85,86}, 200,2 , 6639,51 , 25,5 , 30,7 , 1562,8 , 1437,7 , 0, 0, 1, 6, 7 }, // French/Latin/Vanuatu
+ { 37, 7, 244, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 30,7 , 1562,8 , 1965,16 , 2, 1, 1, 6, 7 }, // French/Latin/Saint Barthelemy
+ { 37, 7, 245, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 177,8 , 177,8 , 141,10 , 99,16 , 37,5 , 8,10 , 6273,63 , 6336,85 , 134,24 , 6273,63 , 6336,85 , 134,24 , 2983,35 , 3018,52 , 3070,14 , 2983,35 , 3018,52 , 3070,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 30,7 , 1562,8 , 1981,31 , 2, 1, 1, 6, 7 }, // French/Latin/Saint Martin
+ { 39, 7, 224, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 185,11 , 196,10 , 141,10 , 10,17 , 37,5 , 8,10 , 6421,61 , 6482,142 , 6624,36 , 6421,61 , 6482,142 , 6624,36 , 3084,28 , 3112,69 , 3181,14 , 3084,28 , 3112,69 , 3181,14 , 0,2 , 0,2 , {71,66,80}, 171,1 , 6690,22 , 4,4 , 8,6 , 2012,8 , 2020,22 , 2, 1, 1, 6, 7 }, // Gaelic/Latin/UnitedKingdom
+ { 40, 7, 197, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 206,7 , 206,7 , 27,8 , 82,17 , 37,5 , 8,10 , 6660,48 , 6708,87 , 6795,24 , 6660,48 , 6708,87 , 6795,24 , 3195,28 , 3223,49 , 3272,14 , 3195,28 , 3223,49 , 3272,14 , 75,4 , 74,4 , {69,85,82}, 131,1 , 6712,20 , 4,4 , 8,6 , 2042,6 , 2048,6 , 2, 1, 1, 6, 7 }, // Galician/Latin/Spain
+ { 41, 15, 81, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8222, 8220, 0,6 , 0,6 , 213,8 , 213,8 , 187,8 , 571,19 , 37,5 , 8,10 , 6819,48 , 6867,99 , 6966,24 , 6819,48 , 6867,99 , 6966,24 , 3286,28 , 3314,62 , 3376,14 , 3286,28 , 3314,62 , 3376,14 , 0,2 , 0,2 , {71,69,76}, 0,0 , 6732,19 , 25,5 , 4,0 , 2054,7 , 2061,10 , 2, 1, 1, 6, 7 }, // Georgian/Georgian/Georgia
+ { 42, 7, 82, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 221,9 , 221,9 , 187,8 , 462,18 , 37,5 , 8,10 , 6990,48 , 7038,83 , 134,24 , 7121,59 , 7038,83 , 134,24 , 3390,21 , 3411,60 , 3471,14 , 3485,28 , 3411,60 , 3471,14 , 94,5 , 93,6 , {69,85,82}, 131,1 , 6751,19 , 25,5 , 4,0 , 2071,7 , 2078,11 , 2, 1, 1, 6, 7 }, // German/Latin/Germany
+ { 42, 7, 14, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 221,9 , 221,9 , 187,8 , 590,19 , 37,5 , 8,10 , 7180,48 , 7038,83 , 134,24 , 7228,58 , 7286,83 , 134,24 , 3390,21 , 3411,60 , 3471,14 , 3485,28 , 3411,60 , 3471,14 , 94,5 , 93,6 , {69,85,82}, 131,1 , 6751,19 , 14,5 , 4,0 , 2089,24 , 2113,10 , 2, 1, 1, 6, 7 }, // German/Latin/Austria
+ { 42, 7, 21, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 221,9 , 221,9 , 187,8 , 462,18 , 37,5 , 8,10 , 6990,48 , 7038,83 , 134,24 , 7121,59 , 7038,83 , 134,24 , 3390,21 , 3411,60 , 3471,14 , 3485,28 , 3411,60 , 3471,14 , 94,5 , 93,6 , {69,85,82}, 131,1 , 6751,19 , 25,5 , 4,0 , 2071,7 , 2123,7 , 2, 1, 1, 6, 7 }, // German/Latin/Belgium
+ { 42, 7, 123, 46, 39, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 221,9 , 221,9 , 187,8 , 462,18 , 37,5 , 8,10 , 6990,48 , 7038,83 , 134,24 , 7121,59 , 7038,83 , 134,24 , 3390,21 , 3411,60 , 3471,14 , 3485,28 , 3411,60 , 3471,14 , 94,5 , 93,6 , {67,72,70}, 0,0 , 6770,58 , 14,5 , 4,0 , 2071,7 , 2130,13 , 2, 0, 1, 6, 7 }, // German/Latin/Liechtenstein
+ { 42, 7, 125, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 221,9 , 221,9 , 187,8 , 462,18 , 37,5 , 8,10 , 6990,48 , 7038,83 , 134,24 , 7121,59 , 7038,83 , 134,24 , 3390,21 , 3411,60 , 3471,14 , 3485,28 , 3411,60 , 3471,14 , 94,5 , 93,6 , {69,85,82}, 131,1 , 6751,19 , 25,5 , 4,0 , 2071,7 , 2143,9 , 2, 1, 1, 6, 7 }, // German/Latin/Luxembourg
+ { 42, 7, 206, 46, 39, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 221,9 , 221,9 , 187,8 , 462,18 , 37,5 , 8,10 , 6990,48 , 7038,83 , 134,24 , 7121,59 , 7038,83 , 134,24 , 3390,21 , 3411,60 , 3471,14 , 3485,28 , 3411,60 , 3471,14 , 94,5 , 93,6 , {67,72,70}, 230,3 , 6770,58 , 14,5 , 48,5 , 2152,21 , 2173,7 , 2, 0, 1, 6, 7 }, // German/Latin/Switzerland
+ { 43, 16, 85, 44, 46, 44, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 230,9 , 230,9 , 287,6 , 10,17 , 18,7 , 25,12 , 7369,50 , 7419,115 , 7534,24 , 7558,50 , 7608,115 , 7534,24 , 3513,28 , 3541,55 , 3596,14 , 3513,28 , 3541,55 , 3596,14 , 99,4 , 99,4 , {69,85,82}, 131,1 , 6828,19 , 25,5 , 4,0 , 2180,8 , 2188,6 , 2, 1, 1, 6, 7 }, // Greek/Greek/Greece
+ { 43, 16, 56, 44, 46, 44, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 230,9 , 230,9 , 287,6 , 10,17 , 18,7 , 25,12 , 7369,50 , 7419,115 , 7534,24 , 7558,50 , 7608,115 , 7534,24 , 3513,28 , 3541,55 , 3596,14 , 3513,28 , 3541,55 , 3596,14 , 99,4 , 99,4 , {69,85,82}, 131,1 , 6828,19 , 4,4 , 4,0 , 2180,8 , 2194,6 , 2, 1, 1, 6, 7 }, // Greek/Greek/Cyprus
+ { 44, 7, 86, 44, 46, 59, 37, 48, 8722, 43, 101, 187, 171, 8250, 8249, 0,6 , 0,6 , 239,11 , 239,11 , 72,10 , 82,17 , 18,7 , 25,12 , 4985,48 , 7723,96 , 134,24 , 4985,48 , 7723,96 , 134,24 , 3610,28 , 3638,98 , 3736,14 , 3610,28 , 3638,98 , 3736,14 , 0,2 , 0,2 , {68,75,75}, 157,2 , 6847,59 , 4,4 , 43,5 , 2200,11 , 2211,16 , 2, 1, 1, 6, 7 }, // Greenlandic/Latin/Greenland
+ { 46, 17, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 250,9 , 250,9 , 609,7 , 224,18 , 298,8 , 306,13 , 7819,64 , 7883,87 , 7970,31 , 8001,67 , 8068,87 , 7970,31 , 3750,32 , 3782,53 , 3835,19 , 3750,32 , 3782,53 , 3835,19 , 0,2 , 0,2 , {73,78,82}, 122,1 , 6906,20 , 4,4 , 8,6 , 2227,7 , 2234,4 , 2, 1, 7, 7, 7 }, // Gujarati/Gujarati/India
+ { 47, 7, 157, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 287,6 , 224,18 , 37,5 , 8,10 , 8155,48 , 8203,85 , 8288,24 , 8155,48 , 8203,85 , 8288,24 , 3854,21 , 3875,52 , 3927,14 , 3854,21 , 3875,52 , 3927,14 , 0,2 , 0,2 , {78,71,78}, 182,1 , 6926,12 , 14,5 , 4,0 , 2238,5 , 2243,8 , 2, 1, 1, 6, 7 }, // Hausa/Latin/Nigeria
+ { 47, 7, 83, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 287,6 , 224,18 , 37,5 , 8,10 , 8155,48 , 8203,85 , 8288,24 , 8155,48 , 8203,85 , 8288,24 , 3854,21 , 3875,52 , 3927,14 , 3854,21 , 3875,52 , 3927,14 , 0,2 , 0,2 , {71,72,83}, 173,3 , 0,7 , 14,5 , 4,0 , 2238,5 , 2251,4 , 2, 1, 1, 6, 7 }, // Hausa/Latin/Ghana
+ { 47, 7, 156, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 287,6 , 224,18 , 37,5 , 8,10 , 8155,48 , 8203,85 , 8288,24 , 8155,48 , 8203,85 , 8288,24 , 3854,21 , 3875,52 , 3927,14 , 3854,21 , 3875,52 , 3927,14 , 0,2 , 0,2 , {88,79,70}, 209,3 , 6938,36 , 14,5 , 4,0 , 2238,5 , 2255,5 , 0, 0, 1, 6, 7 }, // Hausa/Latin/Niger
+ { 48, 18, 105, 46, 44, 59, 37, 48, 45, 43, 101, 34, 34, 39, 39, 0,6 , 0,6 , 259,6 , 259,6 , 27,8 , 616,18 , 37,5 , 8,10 , 8312,58 , 8370,72 , 158,27 , 8442,48 , 8370,72 , 158,27 , 3941,46 , 3987,65 , 4052,19 , 3941,46 , 3987,65 , 4071,21 , 103,6 , 103,5 , {73,76,83}, 52,1 , 6974,54 , 25,5 , 4,0 , 2260,5 , 2265,5 , 2, 1, 7, 5, 6 }, // Hebrew/Hebrew/Israel
+ { 49, 13, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 265,9 , 274,8 , 634,6 , 10,17 , 18,7 , 25,12 , 8490,75 , 8490,75 , 8565,30 , 8490,75 , 8490,75 , 8565,30 , 4092,38 , 4130,57 , 4187,19 , 4092,38 , 4130,57 , 4187,19 , 109,9 , 108,7 , {73,78,82}, 122,1 , 7028,19 , 14,5 , 4,0 , 2270,6 , 2276,4 , 2, 1, 7, 7, 7 }, // Hindi/Devanagari/India
+ { 50, 7, 98, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8221, 187, 171, 0,6 , 0,6 , 282,8 , 282,8 , 640,11 , 651,19 , 61,4 , 219,9 , 8595,64 , 8659,98 , 8757,25 , 8595,64 , 8659,98 , 8782,25 , 4206,19 , 4225,52 , 4277,17 , 4206,19 , 4225,52 , 4277,17 , 118,3 , 115,3 , {72,85,70}, 237,2 , 7047,20 , 25,5 , 4,0 , 2280,6 , 2286,12 , 0, 0, 1, 6, 7 }, // Hungarian/Latin/Hungary
+ { 51, 7, 99, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 142,8 , 142,8 , 546,8 , 462,18 , 37,5 , 8,10 , 8807,48 , 8855,82 , 8937,24 , 8807,48 , 8855,82 , 8961,24 , 4294,28 , 4322,81 , 4403,14 , 4294,28 , 4322,81 , 4417,14 , 121,4 , 118,4 , {73,83,75}, 157,2 , 7067,49 , 4,4 , 8,6 , 2298,8 , 2306,6 , 0, 0, 1, 6, 7 }, // Icelandic/Latin/Iceland
+ { 52, 7, 101, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 290,10 , 300,9 , 27,8 , 123,18 , 144,5 , 149,10 , 8985,48 , 9033,87 , 134,24 , 8985,48 , 9033,87 , 134,24 , 4431,28 , 4459,43 , 4502,14 , 4431,28 , 4459,43 , 4502,14 , 0,2 , 0,2 , {73,68,82}, 239,2 , 7116,23 , 4,4 , 4,0 , 2312,16 , 2328,9 , 0, 0, 7, 6, 7 }, // Indonesian/Latin/Indonesia
+ { 53, 7, 74, 44, 46, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 242,8 , 269,18 , 37,5 , 8,10 , 9120,48 , 9168,93 , 158,27 , 9120,48 , 9168,93 , 158,27 , 4516,28 , 4544,57 , 85,14 , 4516,28 , 4544,57 , 85,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 7139,12 , 14,5 , 4,0 , 2337,11 , 2348,7 , 2, 1, 1, 6, 7 }, // Interlingua/Latin/France
+ { 57, 7, 104, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 99,16 , 37,5 , 8,10 , 9261,62 , 9323,107 , 9430,24 , 9261,62 , 9323,107 , 9430,24 , 4601,37 , 4638,75 , 4713,14 , 4601,37 , 4638,75 , 4713,14 , 75,4 , 74,4 , {69,85,82}, 131,1 , 7151,11 , 4,4 , 4,0 , 2355,7 , 2362,4 , 2, 1, 7, 6, 7 }, // Irish/Latin/Ireland
+ { 58, 7, 106, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 309,8 , 206,7 , 27,8 , 99,16 , 37,5 , 8,10 , 9454,48 , 9502,94 , 9596,24 , 9454,48 , 9620,94 , 9596,24 , 4727,28 , 4755,57 , 4812,14 , 4727,28 , 4826,57 , 4812,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2807,19 , 14,5 , 4,0 , 2366,8 , 2374,6 , 2, 1, 1, 6, 7 }, // Italian/Latin/Italy
+ { 58, 7, 184, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 309,8 , 206,7 , 27,8 , 99,16 , 37,5 , 8,10 , 9454,48 , 9502,94 , 9596,24 , 9454,48 , 9620,94 , 9596,24 , 4727,28 , 4755,57 , 4812,14 , 4727,28 , 4826,57 , 4812,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2807,19 , 14,5 , 4,0 , 2366,8 , 2380,10 , 2, 1, 1, 6, 7 }, // Italian/Latin/SanMarino
+ { 58, 7, 206, 46, 39, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 309,8 , 206,7 , 187,8 , 10,17 , 37,5 , 284,14 , 9454,48 , 9502,94 , 9596,24 , 9454,48 , 9620,94 , 9596,24 , 4727,28 , 4755,57 , 4812,14 , 4727,28 , 4826,57 , 4812,14 , 0,2 , 0,2 , {67,72,70}, 230,3 , 7162,53 , 14,5 , 48,5 , 2366,8 , 2390,8 , 2, 0, 1, 6, 7 }, // Italian/Latin/Switzerland
+ { 59, 19, 108, 46, 44, 59, 37, 48, 45, 43, 101, 12300, 12301, 12302, 12303, 125,5 , 125,5 , 125,5 , 125,5 , 536,10 , 399,13 , 61,4 , 319,10 , 4390,39 , 4390,39 , 158,27 , 4390,39 , 4390,39 , 158,27 , 4883,14 , 4897,28 , 4883,14 , 4883,14 , 4897,28 , 4883,14 , 125,2 , 122,2 , {74,80,89}, 143,1 , 7215,10 , 4,4 , 4,0 , 2398,3 , 2401,2 , 0, 0, 7, 6, 7 }, // Japanese/Japanese/Japan
+ { 61, 21, 100, 46, 44, 59, 37, 48, 45, 43, 3208, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 317,12 , 329,11 , 634,6 , 99,16 , 298,8 , 306,13 , 9714,91 , 9805,86 , 9891,31 , 9714,91 , 9805,86 , 9922,31 , 4925,28 , 4953,53 , 5006,19 , 4925,28 , 4953,53 , 5006,19 , 0,2 , 0,2 , {73,78,82}, 122,1 , 7225,20 , 4,4 , 8,6 , 2403,5 , 2408,4 , 2, 1, 7, 7, 7 }, // Kannada/Kannada/India
+ { 62, 1, 100, 1643, 1644, 1563, 1642, 1776, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 518,6 , 35,18 , 18,7 , 25,12 , 9953,72 , 9953,72 , 10025,24 , 9953,72 , 9953,72 , 10025,24 , 5025,54 , 5079,56 , 5135,14 , 5025,54 , 5079,56 , 5135,14 , 0,2 , 0,2 , {73,78,82}, 122,1 , 7245,23 , 14,5 , 4,0 , 2412,5 , 2417,10 , 2, 1, 7, 7, 7 }, // Kashmiri/Arabic/India
+ { 63, 2, 110, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 187,8 , 670,22 , 37,5 , 8,10 , 10049,61 , 10110,83 , 158,27 , 10049,61 , 10110,83 , 158,27 , 5149,28 , 5177,54 , 85,14 , 5149,28 , 5177,54 , 85,14 , 0,2 , 0,2 , {75,90,84}, 241,1 , 7268,24 , 25,5 , 4,0 , 2427,10 , 2437,9 , 2, 1, 1, 6, 7 }, // Kazakh/Cyrillic/Kazakhstan
+ { 64, 7, 179, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 242,8 , 269,18 , 37,5 , 8,10 , 10193,60 , 10253,101 , 158,27 , 10193,60 , 10253,101 , 158,27 , 5231,35 , 5266,84 , 85,14 , 5231,35 , 5266,84 , 85,14 , 0,2 , 0,2 , {82,87,70}, 228,2 , 0,7 , 14,5 , 4,0 , 2446,11 , 1915,6 , 0, 0, 1, 6, 7 }, // Kinyarwanda/Latin/Rwanda
+ { 65, 2, 116, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 0,6 , 0,6 , 187,8 , 670,22 , 37,5 , 8,10 , 10354,60 , 10414,80 , 158,27 , 10494,59 , 10553,80 , 158,27 , 5350,28 , 5378,57 , 85,14 , 5435,28 , 5463,57 , 85,14 , 0,2 , 0,2 , {75,71,83}, 242,3 , 0,7 , 14,5 , 4,0 , 2457,6 , 2463,10 , 2, 1, 1, 6, 7 }, // Kirghiz/Cyrillic/Kyrgyzstan
+ { 66, 22, 114, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 340,7 , 340,7 , 692,9 , 701,16 , 329,7 , 336,13 , 10633,39 , 10633,39 , 10633,39 , 10633,39 , 10633,39 , 10633,39 , 5520,14 , 5534,28 , 5520,14 , 5520,14 , 5534,28 , 5520,14 , 127,2 , 124,2 , {75,82,87}, 245,1 , 7292,13 , 4,4 , 8,6 , 2473,3 , 2476,4 , 0, 0, 7, 6, 7 }, // Korean/Korean/SouthKorea
+ { 66, 22, 113, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 340,7 , 340,7 , 692,9 , 701,16 , 329,7 , 336,13 , 10633,39 , 10633,39 , 10633,39 , 10633,39 , 10633,39 , 10633,39 , 5520,14 , 5534,28 , 5520,14 , 5520,14 , 5534,28 , 5520,14 , 127,2 , 124,2 , {75,80,87}, 0,0 , 7305,23 , 4,4 , 8,6 , 2473,3 , 2480,14 , 0, 0, 1, 6, 7 }, // Korean/Korean/NorthKorea
+ { 68, 7, 35, 44, 46, 59, 37, 48, 45, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 10672,60 , 10732,106 , 158,27 , 10672,60 , 10732,106 , 158,27 , 5562,34 , 5596,89 , 85,14 , 5562,34 , 5596,89 , 85,14 , 129,5 , 126,5 , {66,73,70}, 212,3 , 7328,27 , 0,4 , 4,0 , 2494,8 , 2502,8 , 0, 0, 1, 6, 7 }, // Rundi/Latin/Burundi
+ { 69, 23, 117, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 717,18 , 61,4 , 349,24 , 10838,62 , 10900,75 , 158,27 , 10975,61 , 10900,75 , 158,27 , 5685,23 , 5708,57 , 5765,18 , 5783,24 , 5708,57 , 1765,14 , 134,8 , 131,8 , {76,65,75}, 246,1 , 7355,14 , 4,4 , 48,5 , 2510,3 , 2513,9 , 0, 0, 7, 6, 7 }, // Lao/Lao/Laos
+ { 71, 7, 118, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 347,8 , 347,8 , 187,8 , 735,26 , 37,5 , 8,10 , 11036,65 , 11101,101 , 134,24 , 11202,65 , 11267,101 , 134,24 , 5807,21 , 5828,72 , 5900,14 , 5807,21 , 5914,72 , 5900,14 , 142,14 , 139,11 , {76,86,76}, 247,2 , 7369,59 , 4,4 , 8,6 , 2522,8 , 2530,7 , 2, 1, 1, 6, 7 }, // Latvian/Latin/Latvia
+ { 72, 7, 49, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 355,9 , 355,9 , 364,8 , 99,16 , 37,5 , 8,10 , 11368,48 , 11416,203 , 11619,24 , 11368,48 , 11416,203 , 11619,24 , 5986,28 , 6014,100 , 6114,14 , 5986,28 , 6014,100 , 6114,14 , 156,8 , 150,6 , {67,68,70}, 217,2 , 7428,23 , 25,5 , 4,0 , 2537,7 , 2544,29 , 2, 1, 1, 6, 7 }, // Lingala/Latin/CongoKinshasa
+ { 72, 7, 6, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 355,9 , 355,9 , 364,8 , 99,16 , 37,5 , 8,10 , 11368,48 , 11416,203 , 11619,24 , 11368,48 , 11416,203 , 11619,24 , 5986,28 , 6014,100 , 6114,14 , 5986,28 , 6014,100 , 6114,14 , 156,8 , 150,6 , {65,79,65}, 249,2 , 7451,23 , 25,5 , 4,0 , 2537,7 , 2573,6 , 2, 1, 1, 6, 7 }, // Lingala/Latin/Angola
+ { 72, 7, 41, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 355,9 , 355,9 , 364,8 , 99,16 , 37,5 , 8,10 , 11368,48 , 11416,203 , 11619,24 , 11368,48 , 11416,203 , 11619,24 , 5986,28 , 6014,100 , 6114,14 , 5986,28 , 6014,100 , 6114,14 , 156,8 , 150,6 , {88,65,70}, 36,4 , 7474,23 , 25,5 , 4,0 , 2537,7 , 2579,26 , 0, 0, 1, 6, 7 }, // Lingala/Latin/CentralAfricanRepublic
+ { 72, 7, 50, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 355,9 , 355,9 , 364,8 , 99,16 , 37,5 , 8,10 , 11368,48 , 11416,203 , 11619,24 , 11368,48 , 11416,203 , 11619,24 , 5986,28 , 6014,100 , 6114,14 , 5986,28 , 6014,100 , 6114,14 , 156,8 , 150,6 , {88,65,70}, 36,4 , 7474,23 , 25,5 , 4,0 , 2537,7 , 2605,5 , 0, 0, 1, 6, 7 }, // Lingala/Latin/CongoBrazzaville
+ { 73, 7, 124, 44, 160, 59, 37, 48, 8211, 43, 101, 8222, 8220, 8222, 8220, 0,6 , 0,6 , 364,8 , 364,8 , 72,10 , 761,27 , 37,5 , 8,10 , 11643,70 , 11713,96 , 11809,24 , 11643,70 , 11713,96 , 11809,24 , 6128,21 , 6149,89 , 6238,14 , 6128,21 , 6149,89 , 6238,14 , 164,9 , 156,6 , {76,84,76}, 251,2 , 7497,62 , 25,5 , 4,0 , 2610,8 , 2618,7 , 2, 1, 1, 6, 7 }, // Lithuanian/Latin/Lithuania
+ { 74, 2, 127, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 0,6 , 0,6 , 788,7 , 123,18 , 37,5 , 8,10 , 11833,63 , 11896,85 , 11981,24 , 11833,63 , 11896,85 , 11981,24 , 6252,34 , 6286,54 , 1521,14 , 6252,34 , 6286,54 , 1521,14 , 173,10 , 162,8 , {77,75,68}, 253,3 , 7559,23 , 14,5 , 4,0 , 2625,10 , 2635,10 , 2, 1, 1, 6, 7 }, // Macedonian/Cyrillic/Macedonia
+ { 75, 7, 128, 46, 44, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 12005,48 , 12053,92 , 134,24 , 12005,48 , 12053,92 , 134,24 , 6340,34 , 6374,60 , 6434,14 , 6340,34 , 6374,60 , 6434,14 , 0,2 , 0,2 , {77,71,65}, 176,2 , 7582,13 , 4,4 , 4,0 , 2645,8 , 2653,12 , 0, 0, 1, 6, 7 }, // Malagasy/Latin/Madagascar
+ { 76, 7, 130, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 290,10 , 300,9 , 511,7 , 10,17 , 18,7 , 25,12 , 12145,49 , 12194,82 , 12276,24 , 12145,49 , 12194,82 , 12276,24 , 6448,28 , 6476,43 , 6519,14 , 6448,28 , 6476,43 , 6519,14 , 183,2 , 170,3 , {77,89,82}, 256,2 , 7595,23 , 4,4 , 8,6 , 2665,13 , 2678,8 , 2, 1, 1, 6, 7 }, // Malay/Latin/Malaysia
+ { 76, 7, 32, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 290,10 , 300,9 , 511,7 , 524,12 , 18,7 , 25,12 , 12145,49 , 12194,82 , 12276,24 , 12145,49 , 12194,82 , 12276,24 , 6448,28 , 6476,43 , 6519,14 , 6448,28 , 6476,43 , 6519,14 , 183,2 , 170,3 , {66,78,68}, 12,1 , 7618,19 , 14,5 , 4,0 , 2665,13 , 2686,6 , 2, 1, 1, 6, 7 }, // Malay/Latin/Brunei
+ { 76, 7, 190, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 290,10 , 300,9 , 511,7 , 10,17 , 18,7 , 25,12 , 12145,49 , 12194,82 , 12276,24 , 12145,49 , 12194,82 , 12276,24 , 6448,28 , 6476,43 , 6519,14 , 6448,28 , 6476,43 , 6519,14 , 183,2 , 170,3 , {83,71,68}, 12,1 , 7637,22 , 4,4 , 8,6 , 2665,13 , 2692,9 , 2, 1, 7, 6, 7 }, // Malay/Latin/Singapore
+ { 77, 24, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 372,13 , 385,12 , 27,8 , 795,18 , 18,7 , 25,12 , 12300,62 , 12362,87 , 12449,31 , 12300,62 , 12362,87 , 12449,31 , 6533,41 , 6574,70 , 6644,22 , 6533,41 , 6574,70 , 6644,22 , 0,2 , 0,2 , {73,78,82}, 122,1 , 7659,40 , 0,4 , 4,0 , 2701,6 , 2707,6 , 2, 1, 7, 7, 7 }, // Malayalam/Malayalam/India
+ { 78, 7, 133, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 397,8 , 405,7 , 141,10 , 813,23 , 37,5 , 8,10 , 12480,48 , 12528,86 , 12614,24 , 12480,48 , 12528,86 , 12614,24 , 6666,28 , 6694,63 , 6757,14 , 6666,28 , 6694,63 , 6757,14 , 185,2 , 173,2 , {69,85,82}, 131,1 , 7699,11 , 4,4 , 4,0 , 2713,5 , 1049,5 , 2, 1, 7, 6, 7 }, // Maltese/Latin/Malta
+ { 80, 13, 100, 46, 44, 59, 37, 2406, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 412,9 , 412,9 , 634,6 , 99,16 , 373,7 , 380,12 , 12638,66 , 12704,86 , 12790,32 , 12638,66 , 12704,86 , 12790,32 , 6771,32 , 6803,53 , 4187,19 , 6771,32 , 6803,53 , 4187,19 , 0,2 , 0,2 , {73,78,82}, 122,1 , 7710,19 , 4,4 , 8,6 , 2718,5 , 2276,4 , 2, 1, 7, 7, 7 }, // Marathi/Devanagari/India
+ { 82, 2, 143, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 836,31 , 37,5 , 8,10 , 12822,48 , 12870,66 , 158,27 , 12822,48 , 12870,66 , 158,27 , 6856,21 , 6877,43 , 1765,14 , 6856,21 , 6877,43 , 1765,14 , 187,2 , 175,2 , {77,78,84}, 258,1 , 7729,25 , 14,5 , 4,0 , 2723,6 , 2729,6 , 0, 0, 1, 6, 7 }, // Mongolian/Cyrillic/Mongolia
+ { 84, 13, 150, 46, 44, 59, 37, 2406, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 12936,56 , 12992,85 , 13077,27 , 12936,56 , 12992,85 , 13077,27 , 6920,33 , 6953,54 , 7007,14 , 6920,33 , 6953,54 , 7007,14 , 189,14 , 177,14 , {78,80,82}, 259,4 , 7754,52 , 14,5 , 4,0 , 2735,6 , 2741,5 , 2, 1, 7, 6, 7 }, // Nepali/Devanagari/Nepal
+ { 84, 13, 100, 46, 44, 59, 37, 2406, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 12936,56 , 12992,85 , 13077,27 , 12936,56 , 13104,80 , 13077,27 , 6920,33 , 6953,54 , 7007,14 , 6920,33 , 7021,54 , 7007,14 , 109,9 , 108,7 , {73,78,82}, 122,1 , 7806,49 , 14,5 , 4,0 , 2735,6 , 2276,4 , 2, 1, 7, 7, 7 }, // Nepali/Devanagari/India
+ { 85, 7, 161, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8216, 8217, 0,6 , 0,6 , 142,8 , 142,8 , 187,8 , 554,17 , 37,5 , 392,16 , 5815,48 , 13184,83 , 134,24 , 13267,59 , 13184,83 , 134,24 , 7075,28 , 2258,51 , 2309,14 , 2323,35 , 2258,51 , 2309,14 , 0,2 , 0,2 , {78,79,75}, 157,2 , 7855,44 , 14,5 , 4,0 , 2746,12 , 2758,5 , 2, 1, 1, 6, 7 }, // NorwegianBokmal/Latin/Norway
+ { 87, 26, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 634,6 , 10,17 , 18,7 , 25,12 , 13326,89 , 13326,89 , 13415,32 , 13326,89 , 13326,89 , 13415,32 , 7103,33 , 7136,54 , 7190,18 , 7103,33 , 7136,54 , 7190,18 , 89,2 , 88,2 , {73,78,82}, 122,1 , 7899,11 , 14,5 , 4,0 , 2763,5 , 2768,4 , 2, 1, 7, 7, 7 }, // Oriya/Oriya/India
+ { 88, 1, 1, 1643, 1644, 1563, 1642, 1776, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 179,8 , 867,20 , 61,4 , 408,11 , 13447,68 , 13447,68 , 158,27 , 13447,68 , 13447,68 , 158,27 , 7208,49 , 7208,49 , 85,14 , 7208,49 , 7208,49 , 85,14 , 203,4 , 191,4 , {65,70,78}, 263,1 , 7910,13 , 25,5 , 4,0 , 2772,4 , 2776,9 , 0, 0, 6, 4, 5 }, // Pashto/Arabic/Afghanistan
+ { 89, 1, 102, 1643, 1644, 1563, 1642, 1776, 8722, 43, 101, 171, 187, 8249, 8250, 421,7 , 421,7 , 43,8 , 51,7 , 179,8 , 99,16 , 61,4 , 408,11 , 13515,70 , 13515,70 , 13585,24 , 13609,74 , 13609,74 , 13585,24 , 7208,49 , 7208,49 , 7257,14 , 7208,49 , 7208,49 , 7257,14 , 207,9 , 195,8 , {73,82,82}, 264,1 , 7923,17 , 53,5 , 58,7 , 2785,5 , 2790,5 , 0, 0, 6, 4, 5 }, // Persian/Arabic/Iran
+ { 89, 1, 1, 1643, 1644, 1563, 1642, 1776, 8722, 43, 101, 171, 187, 8249, 8250, 421,7 , 421,7 , 43,8 , 51,7 , 179,8 , 99,16 , 61,4 , 408,11 , 13515,70 , 13515,70 , 13683,24 , 13707,64 , 13771,68 , 13585,24 , 7208,49 , 7208,49 , 7257,14 , 7208,49 , 7208,49 , 7257,14 , 207,9 , 195,8 , {65,70,78}, 263,1 , 7940,23 , 53,5 , 58,7 , 2795,3 , 2776,9 , 0, 0, 6, 4, 5 }, // Persian/Arabic/Afghanistan
+ { 90, 7, 172, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8221, 171, 187, 0,6 , 0,6 , 118,7 , 118,7 , 887,10 , 10,17 , 37,5 , 8,10 , 13839,48 , 13887,97 , 13984,24 , 13839,48 , 14008,99 , 13984,24 , 7271,34 , 7305,59 , 7364,14 , 7271,34 , 7305,59 , 7364,14 , 0,2 , 0,2 , {80,76,78}, 265,2 , 7963,77 , 25,5 , 30,7 , 2798,6 , 2804,6 , 2, 1, 1, 6, 7 }, // Polish/Latin/Poland
+ { 91, 7, 30, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 206,7 , 206,7 , 27,8 , 897,27 , 37,5 , 8,10 , 14107,48 , 14155,89 , 134,24 , 14107,48 , 14155,89 , 134,24 , 7378,28 , 7406,79 , 7485,14 , 7378,28 , 7406,79 , 7485,14 , 0,2 , 0,2 , {66,82,76}, 267,2 , 8040,54 , 4,4 , 8,6 , 2810,19 , 2829,6 , 2, 1, 7, 6, 7 }, // Portuguese/Latin/Brazil
+ { 91, 7, 6, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 206,7 , 206,7 , 27,8 , 897,27 , 37,5 , 8,10 , 14244,48 , 14292,89 , 134,24 , 14244,48 , 14292,89 , 134,24 , 7378,28 , 7499,79 , 7485,14 , 7378,28 , 7499,79 , 7485,14 , 0,2 , 0,2 , {65,79,65}, 249,2 , 8094,54 , 25,5 , 4,0 , 2835,9 , 2844,6 , 2, 1, 1, 6, 7 }, // Portuguese/Latin/Angola
+ { 91, 7, 39, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 206,7 , 206,7 , 27,8 , 897,27 , 37,5 , 8,10 , 14244,48 , 14292,89 , 134,24 , 14244,48 , 14292,89 , 134,24 , 7378,28 , 7499,79 , 7485,14 , 7378,28 , 7499,79 , 7485,14 , 0,2 , 0,2 , {67,86,69}, 0,0 , 8148,69 , 25,5 , 4,0 , 2835,9 , 2850,10 , 2, 1, 1, 6, 7 }, // Portuguese/Latin/CapeVerde
+ { 91, 7, 62, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 206,7 , 206,7 , 27,8 , 897,27 , 37,5 , 8,10 , 14244,48 , 14292,89 , 134,24 , 14244,48 , 14292,89 , 134,24 , 7378,28 , 7499,79 , 7485,14 , 7378,28 , 7499,79 , 7485,14 , 0,2 , 0,2 , {85,83,68}, 204,3 , 8217,81 , 25,5 , 4,0 , 2835,9 , 2860,11 , 2, 1, 1, 6, 7 }, // Portuguese/Latin/EastTimor
+ { 91, 7, 92, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 206,7 , 206,7 , 27,8 , 897,27 , 37,5 , 8,10 , 14244,48 , 14292,89 , 134,24 , 14244,48 , 14292,89 , 134,24 , 7378,28 , 7499,79 , 7485,14 , 7378,28 , 7499,79 , 7485,14 , 0,2 , 0,2 , {88,79,70}, 209,3 , 8298,62 , 25,5 , 4,0 , 2835,9 , 2871,12 , 0, 0, 1, 6, 7 }, // Portuguese/Latin/GuineaBissau
+ { 91, 7, 126, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 206,7 , 206,7 , 27,8 , 897,27 , 37,5 , 8,10 , 14244,48 , 14292,89 , 134,24 , 14244,48 , 14292,89 , 134,24 , 7378,28 , 7499,79 , 7485,14 , 7378,28 , 7499,79 , 7485,14 , 0,2 , 0,2 , {77,79,80}, 144,4 , 8360,53 , 25,5 , 4,0 , 2835,9 , 2883,19 , 2, 1, 7, 6, 7 }, // Portuguese/Latin/Macau
+ { 91, 7, 146, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 206,7 , 206,7 , 27,8 , 897,27 , 37,5 , 8,10 , 14244,48 , 14292,89 , 134,24 , 14244,48 , 14292,89 , 134,24 , 7378,28 , 7499,79 , 7485,14 , 7378,28 , 7499,79 , 7485,14 , 0,2 , 0,2 , {77,90,78}, 269,3 , 8413,72 , 25,5 , 4,0 , 2835,9 , 2902,10 , 2, 1, 7, 6, 7 }, // Portuguese/Latin/Mozambique
+ { 91, 7, 173, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 206,7 , 206,7 , 27,8 , 897,27 , 37,5 , 8,10 , 14244,48 , 14292,89 , 134,24 , 14244,48 , 14292,89 , 134,24 , 7378,28 , 7499,79 , 7485,14 , 7378,28 , 7499,79 , 7485,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 8485,20 , 25,5 , 4,0 , 2912,17 , 2929,8 , 2, 1, 1, 6, 7 }, // Portuguese/Latin/Portugal
+ { 91, 7, 185, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 206,7 , 206,7 , 27,8 , 897,27 , 37,5 , 8,10 , 14244,48 , 14292,89 , 134,24 , 14244,48 , 14292,89 , 134,24 , 7378,28 , 7499,79 , 7485,14 , 7378,28 , 7499,79 , 7485,14 , 0,2 , 0,2 , {83,84,68}, 272,2 , 8505,92 , 25,5 , 4,0 , 2835,9 , 2937,19 , 0, 0, 1, 6, 7 }, // Portuguese/Latin/SaoTomeAndPrincipe
+ { 92, 4, 100, 46, 44, 59, 37, 48, 45, 43, 101, 39, 39, 34, 34, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 123,18 , 18,7 , 25,12 , 14381,68 , 14381,68 , 14449,27 , 14381,68 , 14381,68 , 14449,27 , 7578,38 , 7616,55 , 7671,23 , 7578,38 , 7616,55 , 7671,23 , 216,11 , 203,11 , {73,78,82}, 122,1 , 8597,12 , 14,5 , 4,0 , 2956,6 , 2962,4 , 2, 1, 7, 7, 7 }, // Punjabi/Gurmukhi/India
+ { 92, 1, 163, 1643, 1644, 1563, 1642, 1776, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 123,18 , 18,7 , 25,12 , 14476,67 , 14476,67 , 158,27 , 14476,67 , 14476,67 , 158,27 , 7694,37 , 7694,37 , 85,14 , 7694,37 , 7694,37 , 85,14 , 0,2 , 0,2 , {80,75,82}, 274,1 , 8609,13 , 14,5 , 4,0 , 2966,5 , 2971,6 , 0, 0, 7, 6, 7 }, // Punjabi/Arabic/Pakistan
+ { 94, 7, 206, 46, 8217, 59, 37, 48, 8722, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 0,6 , 0,6 , 503,8 , 924,28 , 37,5 , 8,10 , 14543,67 , 14610,92 , 14702,24 , 14543,67 , 14610,92 , 14702,24 , 7731,23 , 7754,56 , 7810,14 , 7731,23 , 7754,56 , 7810,14 , 89,2 , 214,2 , {67,72,70}, 230,3 , 8622,20 , 25,5 , 4,0 , 2977,9 , 2986,6 , 2, 0, 1, 6, 7 }, // Romansh/Latin/Switzerland
+ { 95, 7, 177, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8221, 171, 187, 0,6 , 0,6 , 428,8 , 428,8 , 887,10 , 10,17 , 37,5 , 8,10 , 14726,60 , 14786,98 , 14884,24 , 14726,60 , 14786,98 , 14884,24 , 7824,21 , 7845,48 , 3070,14 , 7824,21 , 7845,48 , 3070,14 , 0,2 , 0,2 , {82,79,78}, 0,0 , 8642,57 , 25,5 , 4,0 , 2992,6 , 2998,7 , 2, 1, 1, 6, 7 }, // Romanian/Latin/Romania
+ { 95, 7, 141, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8221, 171, 187, 0,6 , 0,6 , 428,8 , 428,8 , 887,10 , 10,17 , 37,5 , 8,10 , 14726,60 , 14786,98 , 14884,24 , 14726,60 , 14786,98 , 14884,24 , 7824,21 , 7845,48 , 3070,14 , 7824,21 , 7845,48 , 3070,14 , 0,2 , 0,2 , {77,68,76}, 0,0 , 8699,69 , 25,5 , 4,0 , 2992,6 , 3005,17 , 2, 1, 1, 6, 7 }, // Romanian/Latin/Moldova
+ { 96, 2, 178, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 102,7 , 102,7 , 187,8 , 952,22 , 61,4 , 219,9 , 14908,62 , 10414,80 , 14970,24 , 14994,63 , 15057,82 , 14970,24 , 7893,21 , 7914,62 , 7976,14 , 7990,21 , 8011,62 , 7990,21 , 227,10 , 216,13 , {82,85,66}, 275,4 , 8768,89 , 25,5 , 4,0 , 3022,7 , 3029,6 , 2, 1, 1, 6, 7 }, // Russian/Cyrillic/Russia
+ { 96, 2, 20, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 102,7 , 102,7 , 187,8 , 952,22 , 61,4 , 219,9 , 14908,62 , 10414,80 , 14970,24 , 14994,63 , 15057,82 , 14970,24 , 7893,21 , 7914,62 , 7976,14 , 7990,21 , 8011,62 , 7990,21 , 227,10 , 216,13 , {66,89,82}, 140,2 , 8857,94 , 25,5 , 4,0 , 3022,7 , 464,8 , 0, 0, 7, 6, 7 }, // Russian/Cyrillic/Belarus
+ { 96, 2, 110, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 102,7 , 102,7 , 187,8 , 952,22 , 61,4 , 219,9 , 14908,62 , 10414,80 , 14970,24 , 14994,63 , 15057,82 , 14970,24 , 7893,21 , 7914,62 , 7976,14 , 7990,21 , 8011,62 , 7990,21 , 227,10 , 216,13 , {75,90,84}, 241,1 , 8951,83 , 25,5 , 4,0 , 3022,7 , 3035,9 , 2, 1, 1, 6, 7 }, // Russian/Cyrillic/Kazakhstan
+ { 96, 2, 116, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 102,7 , 102,7 , 187,8 , 952,22 , 61,4 , 219,9 , 14908,62 , 10414,80 , 14970,24 , 14994,63 , 15057,82 , 14970,24 , 7893,21 , 7914,62 , 7976,14 , 7990,21 , 8011,62 , 7990,21 , 227,10 , 216,13 , {75,71,83}, 242,3 , 9034,81 , 25,5 , 4,0 , 3022,7 , 3044,8 , 2, 1, 1, 6, 7 }, // Russian/Cyrillic/Kyrgyzstan
+ { 96, 2, 141, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 102,7 , 102,7 , 187,8 , 952,22 , 61,4 , 219,9 , 14908,62 , 10414,80 , 14970,24 , 14994,63 , 15057,82 , 14970,24 , 7893,21 , 7914,62 , 7976,14 , 7990,21 , 8011,62 , 7990,21 , 227,10 , 216,13 , {77,68,76}, 0,0 , 9115,79 , 25,5 , 4,0 , 3022,7 , 3052,7 , 2, 1, 1, 6, 7 }, // Russian/Cyrillic/Moldova
+ { 96, 2, 222, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 102,7 , 102,7 , 187,8 , 952,22 , 37,5 , 8,10 , 14908,62 , 10414,80 , 14970,24 , 14994,63 , 15057,82 , 14970,24 , 7893,21 , 7914,62 , 7976,14 , 7990,21 , 8011,62 , 7990,21 , 227,10 , 216,13 , {85,65,72}, 279,1 , 9194,92 , 25,5 , 4,0 , 3022,7 , 3059,7 , 2, 1, 1, 6, 7 }, // Russian/Cyrillic/Ukraine
+ { 98, 7, 41, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 15139,48 , 15187,91 , 15278,24 , 15139,48 , 15187,91 , 15278,24 , 8073,28 , 8101,66 , 8167,14 , 8073,28 , 8101,66 , 8167,14 , 237,2 , 229,2 , {88,65,70}, 36,4 , 9286,25 , 4,4 , 48,5 , 3066,5 , 3071,22 , 0, 0, 1, 6, 7 }, // Sango/Latin/CentralAfricanRepublic
+ { 100, 2, 243, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 102,7 , 102,7 , 974,7 , 981,20 , 144,5 , 149,10 , 15302,48 , 15350,81 , 11981,24 , 15302,48 , 15350,81 , 11981,24 , 8181,28 , 8209,52 , 8261,14 , 8181,28 , 8209,52 , 8261,14 , 239,9 , 231,7 , {82,83,68}, 280,4 , 9311,72 , 25,5 , 4,0 , 3093,6 , 3099,6 , 0, 0, 1, 6, 7 }, // Serbian/Cyrillic/Serbia
+ { 100, 2, 27, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 102,7 , 102,7 , 115,8 , 981,20 , 37,5 , 419,40 , 15302,48 , 15350,81 , 11981,24 , 15302,48 , 15431,83 , 11981,24 , 8181,28 , 8209,52 , 8261,14 , 8275,28 , 8303,54 , 8261,14 , 239,9 , 231,7 , {66,65,77}, 284,2 , 9383,196 , 25,5 , 4,0 , 3105,6 , 3111,19 , 2, 1, 1, 6, 7 }, // Serbian/Cyrillic/BosniaAndHerzegowina
+ { 100, 2, 242, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 102,7 , 102,7 , 974,7 , 981,20 , 144,5 , 149,10 , 15302,48 , 15350,81 , 11981,24 , 15302,48 , 15350,81 , 11981,24 , 8181,28 , 8209,52 , 8261,14 , 8181,28 , 8209,52 , 8261,14 , 239,9 , 231,7 , {69,85,82}, 131,1 , 9579,27 , 25,5 , 4,0 , 3093,6 , 3130,9 , 2, 1, 1, 6, 7 }, // Serbian/Cyrillic/Montenegro
+ { 100, 7, 27, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 118,7 , 118,7 , 974,7 , 981,20 , 144,5 , 149,10 , 15514,48 , 15562,81 , 15643,24 , 15514,48 , 15562,81 , 15643,24 , 8357,28 , 8385,54 , 2118,14 , 8357,28 , 8385,54 , 2118,14 , 248,9 , 238,7 , {66,65,77}, 153,2 , 9606,196 , 25,5 , 4,0 , 3139,6 , 581,19 , 2, 1, 1, 6, 7 }, // Serbian/Latin/BosniaAndHerzegowina
+ { 100, 7, 242, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 118,7 , 118,7 , 974,7 , 981,20 , 144,5 , 149,10 , 15514,48 , 15562,81 , 15643,24 , 15514,48 , 15562,81 , 15643,24 , 8357,28 , 8385,54 , 2118,14 , 8357,28 , 8385,54 , 2118,14 , 248,9 , 238,7 , {69,85,82}, 131,1 , 9802,27 , 25,5 , 4,0 , 3139,6 , 3145,9 , 2, 1, 1, 6, 7 }, // Serbian/Latin/Montenegro
+ { 100, 7, 243, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 118,7 , 118,7 , 974,7 , 981,20 , 144,5 , 149,10 , 15514,48 , 15562,81 , 15643,24 , 15514,48 , 15562,81 , 15643,24 , 8357,28 , 8385,54 , 2118,14 , 8357,28 , 8385,54 , 2118,14 , 248,9 , 238,7 , {82,83,68}, 286,4 , 9829,72 , 25,5 , 4,0 , 3139,6 , 3154,6 , 0, 0, 1, 6, 7 }, // Serbian/Latin/Serbia
+ { 101, 2, 81, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 436,9 , 436,9 , 187,8 , 1001,23 , 37,5 , 8,10 , 14908,62 , 15667,82 , 14970,24 , 15749,59 , 15808,86 , 14970,24 , 8439,28 , 8467,61 , 8528,14 , 8542,28 , 8570,61 , 8528,14 , 0,2 , 0,2 , {71,69,76}, 0,0 , 9901,17 , 14,5 , 4,0 , 3160,4 , 3164,11 , 2, 1, 1, 6, 7 }, // Ossetic/Cyrillic/Georgia
+ { 101, 2, 178, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 436,9 , 436,9 , 187,8 , 1001,23 , 37,5 , 8,10 , 14908,62 , 15667,82 , 14970,24 , 15749,59 , 15808,86 , 14970,24 , 8439,28 , 8467,61 , 8528,14 , 8542,28 , 8570,61 , 8528,14 , 0,2 , 0,2 , {82,85,66}, 275,4 , 9918,17 , 14,5 , 4,0 , 3160,4 , 3175,6 , 2, 1, 1, 6, 7 }, // Ossetic/Cyrillic/Russia
+ { 102, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 15894,48 , 15942,105 , 158,27 , 15894,48 , 15942,105 , 158,27 , 8631,27 , 8658,61 , 85,14 , 8631,27 , 8658,61 , 85,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 3181,7 , 0,0 , 2, 1, 7, 6, 7 }, // Southern Sotho/Latin/SouthAfrica
+ { 102, 7, 120, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 15894,48 , 15942,105 , 158,27 , 15894,48 , 15942,105 , 158,27 , 8631,27 , 8658,61 , 85,14 , 8631,27 , 8658,61 , 85,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 3181,7 , 0,0 , 2, 1, 1, 6, 7 }, // Southern Sotho/Latin/Lesotho
+ { 103, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 16047,48 , 16095,117 , 158,27 , 16047,48 , 16095,117 , 158,27 , 8719,27 , 8746,64 , 85,14 , 8719,27 , 8746,64 , 85,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 3188,8 , 0,0 , 2, 1, 7, 6, 7 }, // Tswana/Latin/SouthAfrica
+ { 103, 7, 28, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 16047,48 , 16095,117 , 158,27 , 16047,48 , 16095,117 , 158,27 , 8719,27 , 8746,64 , 85,14 , 8719,27 , 8746,64 , 85,14 , 0,2 , 0,2 , {66,87,80}, 170,1 , 0,7 , 4,4 , 4,0 , 3188,8 , 0,0 , 2, 1, 7, 6, 7 }, // Tswana/Latin/Botswana
+ { 104, 7, 240, 46, 44, 59, 37, 48, 45, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 16212,47 , 16259,100 , 16359,24 , 16212,47 , 16259,100 , 16359,24 , 8810,32 , 8842,55 , 8897,14 , 8810,32 , 8842,55 , 8897,14 , 0,2 , 0,2 , {85,83,68}, 204,3 , 9935,22 , 4,4 , 8,6 , 3196,8 , 1491,8 , 2, 1, 7, 6, 7 }, // Shona/Latin/Zimbabwe
+ { 106, 32, 198, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 536,10 , 323,17 , 459,7 , 466,13 , 16383,59 , 16442,96 , 16538,32 , 16570,61 , 16442,96 , 16538,32 , 8911,30 , 8941,62 , 9003,19 , 8911,30 , 8941,62 , 9003,19 , 257,5 , 245,4 , {76,75,82}, 290,3 , 9957,19 , 14,5 , 4,0 , 3204,5 , 3209,11 , 2, 1, 1, 6, 7 }, // Sinhala/Sinhala/SriLanka
+ { 107, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 16631,48 , 16679,114 , 158,27 , 16631,48 , 16679,114 , 158,27 , 9022,27 , 9049,68 , 85,14 , 9022,27 , 9049,68 , 85,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 3220,7 , 0,0 , 2, 1, 7, 6, 7 }, // Swati/Latin/SouthAfrica
+ { 107, 7, 204, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 16631,48 , 16679,114 , 158,27 , 16631,48 , 16679,114 , 158,27 , 9022,27 , 9049,68 , 85,14 , 9022,27 , 9049,68 , 85,14 , 0,2 , 0,2 , {83,90,76}, 191,1 , 0,7 , 4,4 , 4,0 , 3220,7 , 0,0 , 2, 1, 1, 6, 7 }, // Swati/Latin/Swaziland
+ { 108, 7, 191, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 135,7 , 135,7 , 546,8 , 462,18 , 61,4 , 219,9 , 16793,48 , 16841,82 , 15643,24 , 16793,48 , 16923,89 , 15643,24 , 9117,21 , 9138,52 , 9190,14 , 9117,21 , 9138,52 , 9190,14 , 262,10 , 249,9 , {69,85,82}, 131,1 , 9976,28 , 25,5 , 4,0 , 3227,10 , 3237,9 , 2, 1, 1, 6, 7 }, // Slovak/Latin/Slovakia
+ { 109, 7, 192, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 445,8 , 445,8 , 1024,9 , 590,19 , 37,5 , 8,10 , 15514,48 , 17012,86 , 15643,24 , 17098,59 , 17012,86 , 15643,24 , 9204,28 , 9232,52 , 9284,14 , 9298,35 , 9232,52 , 9284,14 , 81,4 , 258,4 , {69,85,82}, 131,1 , 10004,28 , 4,4 , 8,6 , 3246,11 , 3257,9 , 2, 1, 1, 6, 7 }, // Slovenian/Latin/Slovenia
+ { 110, 7, 194, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 53,19 , 18,7 , 25,12 , 17157,48 , 17205,189 , 17394,24 , 17157,48 , 17205,189 , 17394,24 , 9333,28 , 9361,47 , 9408,14 , 9333,28 , 9361,47 , 9408,14 , 272,3 , 262,3 , {83,79,83}, 98,1 , 10032,22 , 4,4 , 4,0 , 3266,8 , 3274,10 , 0, 0, 1, 6, 7 }, // Somali/Latin/Somalia
+ { 110, 7, 59, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 53,19 , 18,7 , 25,12 , 17157,48 , 17205,189 , 17394,24 , 17157,48 , 17205,189 , 17394,24 , 9333,28 , 9361,47 , 9408,14 , 9333,28 , 9361,47 , 9408,14 , 272,3 , 262,3 , {68,74,70}, 5,3 , 10054,21 , 4,4 , 4,0 , 3266,8 , 3284,7 , 0, 0, 6, 6, 7 }, // Somali/Latin/Djibouti
+ { 110, 7, 69, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 53,19 , 18,7 , 25,12 , 17157,48 , 17205,189 , 17394,24 , 17157,48 , 17205,189 , 17394,24 , 9333,28 , 9361,47 , 9408,14 , 9333,28 , 9361,47 , 9408,14 , 272,3 , 262,3 , {69,84,66}, 0,2 , 10075,22 , 4,4 , 4,0 , 3266,8 , 3291,8 , 2, 1, 7, 6, 7 }, // Somali/Latin/Ethiopia
+ { 110, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 53,19 , 18,7 , 25,12 , 17157,48 , 17205,189 , 17394,24 , 17157,48 , 17205,189 , 17394,24 , 9333,28 , 9361,47 , 9408,14 , 9333,28 , 9361,47 , 9408,14 , 272,3 , 262,3 , {75,69,83}, 2,3 , 0,7 , 4,4 , 4,0 , 3266,8 , 3299,7 , 2, 1, 7, 6, 7 }, // Somali/Latin/Kenya
+ { 111, 7, 197, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 9503,14 , 9422,28 , 9450,53 , 9503,14 , 75,4 , 74,4 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 4,0 , 3306,17 , 2048,6 , 2, 1, 1, 6, 7 }, // Spanish/Latin/Spain
+ { 111, 7, 10, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 479,14 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {65,82,83}, 12,1 , 10097,51 , 4,4 , 4,0 , 3323,7 , 3330,9 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Argentina
+ { 111, 7, 26, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {66,79,66}, 293,2 , 10148,35 , 4,4 , 4,0 , 3323,7 , 3339,7 , 2, 1, 1, 6, 7 }, // Spanish/Latin/Bolivia
+ { 111, 7, 43, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 503,8 , 897,27 , 61,4 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {67,76,80}, 12,1 , 10183,45 , 4,4 , 48,5 , 3323,7 , 3346,5 , 0, 0, 1, 6, 7 }, // Spanish/Latin/Chile
+ { 111, 7, 47, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 511,7 , 897,27 , 61,4 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {67,79,80}, 12,1 , 10228,54 , 4,4 , 4,0 , 3323,7 , 3351,8 , 0, 0, 7, 6, 7 }, // Spanish/Latin/Colombia
+ { 111, 7, 52, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {67,82,67}, 295,1 , 10282,67 , 4,4 , 4,0 , 3323,7 , 3359,10 , 0, 0, 1, 6, 7 }, // Spanish/Latin/CostaRica
+ { 111, 7, 55, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {67,85,80}, 12,1 , 10349,42 , 4,4 , 4,0 , 3323,7 , 3369,4 , 2, 1, 1, 6, 7 }, // Spanish/Latin/Cuba
+ { 111, 7, 61, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {68,79,80}, 12,1 , 10391,54 , 4,4 , 4,0 , 3323,7 , 3373,20 , 2, 1, 7, 6, 7 }, // Spanish/Latin/DominicanRepublic
+ { 111, 7, 63, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 61,4 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {85,83,68}, 12,1 , 10445,70 , 4,4 , 48,5 , 3323,7 , 3393,7 , 2, 1, 1, 6, 7 }, // Spanish/Latin/Ecuador
+ { 111, 7, 65, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {85,83,68}, 204,3 , 10445,70 , 4,4 , 4,0 , 3323,7 , 3400,11 , 2, 1, 7, 6, 7 }, // Spanish/Latin/ElSalvador
+ { 111, 7, 66, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 9503,14 , 9422,28 , 9450,53 , 9503,14 , 75,4 , 74,4 , {88,65,70}, 36,4 , 10515,53 , 4,4 , 4,0 , 3323,7 , 3411,17 , 0, 0, 1, 6, 7 }, // Spanish/Latin/EquatorialGuinea
+ { 111, 7, 90, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 511,7 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {71,84,81}, 296,1 , 10568,70 , 4,4 , 4,0 , 3323,7 , 3428,9 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Guatemala
+ { 111, 7, 96, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 1033,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {72,78,76}, 297,1 , 10638,60 , 4,4 , 4,0 , 3323,7 , 3437,8 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Honduras
+ { 111, 7, 139, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {77,88,78}, 12,1 , 10698,48 , 4,4 , 4,0 , 3323,7 , 3445,6 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Mexico
+ { 111, 7, 155, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {78,73,79}, 298,2 , 10746,69 , 4,4 , 4,0 , 3323,7 , 3451,9 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Nicaragua
+ { 111, 7, 166, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 1060,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {80,65,66}, 300,3 , 10815,54 , 4,4 , 4,0 , 3323,7 , 3460,6 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Panama
+ { 111, 7, 168, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {80,89,71}, 303,1 , 10869,61 , 14,5 , 65,6 , 3323,7 , 3466,8 , 0, 0, 7, 6, 7 }, // Spanish/Latin/Paraguay
+ { 111, 7, 169, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 511,7 , 897,27 , 37,5 , 493,15 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {80,69,78}, 304,3 , 10930,62 , 4,4 , 4,0 , 3323,7 , 3474,4 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Peru
+ { 111, 7, 170, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 9503,14 , 9422,28 , 9450,53 , 9503,14 , 75,4 , 74,4 , {80,72,80}, 183,1 , 10992,48 , 25,5 , 4,0 , 3323,7 , 3478,9 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Philippines
+ { 111, 7, 174, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 1060,8 , 897,27 , 18,7 , 25,12 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {85,83,68}, 12,1 , 10445,70 , 4,4 , 4,0 , 3323,7 , 1178,11 , 2, 1, 7, 6, 7 }, // Spanish/Latin/PuertoRico
+ { 111, 7, 225, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 518,6 , 897,27 , 18,7 , 25,12 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 10445,70 , 4,4 , 4,0 , 3323,7 , 3487,14 , 2, 1, 7, 6, 7 }, // Spanish/Latin/UnitedStates
+ { 111, 7, 227, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {85,89,85}, 12,1 , 11040,48 , 14,5 , 71,7 , 3323,7 , 3501,7 , 2, 1, 1, 6, 7 }, // Spanish/Latin/Uruguay
+ { 111, 7, 231, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {86,69,70}, 307,3 , 11088,64 , 4,4 , 48,5 , 3323,7 , 3508,9 , 2, 1, 7, 6, 7 }, // Spanish/Latin/Venezuela
+ { 111, 7, 238, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 9503,14 , 9422,28 , 9450,53 , 9503,14 , 75,4 , 74,4 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 4,0 , 3323,7 , 3517,14 , 2, 1, 1, 6, 7 }, // Spanish/Latin/CanaryIslands
+ { 111, 7, 246, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 3070,14 , 9422,28 , 9450,53 , 3070,14 , 75,4 , 74,4 , {0,0,0}, 0,0 , 11152,0 , 4,4 , 4,0 , 3531,23 , 3554,13 , 2, 1, 1, 6, 7 }, // Spanish/Latin/LatinAmericaAndTheCaribbean
+ { 111, 7, 250, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 171, 187, 0,6 , 0,6 , 453,7 , 453,7 , 27,8 , 897,27 , 37,5 , 8,10 , 17418,49 , 17467,89 , 17556,24 , 17580,48 , 17467,89 , 17556,24 , 9422,28 , 9450,53 , 9503,14 , 9422,28 , 9450,53 , 9503,14 , 75,4 , 74,4 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 4,0 , 3323,7 , 3567,15 , 2, 1, 1, 6, 7 }, // Spanish/Latin/CeutaAndMelilla
+ { 113, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 460,9 , 469,8 , 141,10 , 10,17 , 18,7 , 25,12 , 17628,48 , 17676,84 , 134,24 , 17628,48 , 17676,84 , 134,24 , 9517,22 , 9539,60 , 9599,14 , 9517,22 , 9539,60 , 9599,14 , 275,7 , 265,7 , {84,90,83}, 192,3 , 11152,27 , 4,4 , 8,6 , 3582,9 , 1325,8 , 0, 0, 1, 6, 7 }, // Swahili/Latin/Tanzania
+ { 113, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 460,9 , 469,8 , 141,10 , 10,17 , 18,7 , 25,12 , 17628,48 , 17676,84 , 134,24 , 17628,48 , 17676,84 , 134,24 , 9517,22 , 9539,60 , 9599,14 , 9517,22 , 9539,60 , 9599,14 , 275,7 , 265,7 , {75,69,83}, 2,3 , 11179,24 , 4,4 , 4,0 , 3582,9 , 1006,5 , 2, 1, 7, 6, 7 }, // Swahili/Latin/Kenya
+ { 113, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 460,9 , 469,8 , 141,10 , 10,17 , 18,7 , 25,12 , 17628,48 , 17676,84 , 134,24 , 17628,48 , 17676,84 , 134,24 , 9517,22 , 9539,60 , 9599,14 , 9517,22 , 9539,60 , 9599,14 , 275,7 , 265,7 , {85,71,88}, 197,3 , 11203,25 , 4,4 , 8,6 , 3582,9 , 1381,6 , 0, 0, 1, 6, 7 }, // Swahili/Latin/Uganda
+ { 114, 7, 205, 44, 160, 59, 37, 48, 8722, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 477,9 , 477,9 , 72,10 , 1068,30 , 37,5 , 392,16 , 17760,48 , 17808,86 , 134,24 , 4985,48 , 17894,86 , 134,24 , 9613,28 , 9641,50 , 2309,14 , 9691,29 , 9720,50 , 2309,14 , 282,2 , 272,2 , {83,69,75}, 157,2 , 11228,45 , 25,5 , 4,0 , 3591,7 , 3598,7 , 2, 1, 1, 6, 7 }, // Swedish/Latin/Sweden
+ { 114, 7, 73, 44, 160, 59, 37, 48, 8722, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 477,9 , 477,9 , 72,10 , 1068,30 , 37,5 , 392,16 , 17760,48 , 17808,86 , 134,24 , 4985,48 , 17894,86 , 134,24 , 9613,28 , 9641,50 , 2309,14 , 9691,29 , 9720,50 , 2309,14 , 282,2 , 272,2 , {69,85,82}, 131,1 , 11273,19 , 25,5 , 4,0 , 3591,7 , 3605,7 , 2, 1, 1, 6, 7 }, // Swedish/Latin/Finland
+ { 114, 7, 248, 44, 160, 59, 37, 48, 8722, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 477,9 , 477,9 , 72,10 , 1068,30 , 37,5 , 392,16 , 17760,48 , 17808,86 , 134,24 , 4985,48 , 17894,86 , 134,24 , 9613,28 , 9641,50 , 2309,14 , 9691,29 , 9720,50 , 2309,14 , 282,2 , 272,2 , {69,85,82}, 131,1 , 11273,19 , 25,5 , 4,0 , 3591,7 , 3612,5 , 2, 1, 1, 6, 7 }, // Swedish/Latin/AlandIslands
+ { 116, 2, 209, 46, 44, 59, 37, 48, 45, 43, 101, 171, 187, 171, 8222, 0,6 , 0,6 , 0,6 , 0,6 , 242,8 , 269,18 , 37,5 , 8,10 , 17980,48 , 18028,71 , 158,27 , 17980,48 , 18028,71 , 158,27 , 9770,28 , 9798,55 , 85,14 , 9770,28 , 9798,55 , 85,14 , 0,2 , 0,2 , {84,74,83}, 242,3 , 11292,13 , 14,5 , 4,0 , 3617,6 , 3623,10 , 2, 1, 1, 6, 7 }, // Tajik/Cyrillic/Tajikistan
+ { 117, 27, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 486,13 , 486,13 , 634,6 , 224,18 , 18,7 , 25,12 , 18099,58 , 18157,86 , 18243,31 , 18099,58 , 18274,86 , 18243,31 , 9853,20 , 9873,49 , 9853,20 , 9853,20 , 9873,49 , 9853,20 , 0,2 , 0,2 , {73,78,82}, 122,1 , 11305,13 , 14,5 , 4,0 , 3633,5 , 3638,7 , 2, 1, 7, 7, 7 }, // Tamil/Tamil/India
+ { 117, 27, 130, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 486,13 , 486,13 , 634,6 , 224,18 , 18,7 , 25,12 , 18099,58 , 18157,86 , 18243,31 , 18099,58 , 18274,86 , 18243,31 , 9853,20 , 9873,49 , 9853,20 , 9853,20 , 9873,49 , 9853,20 , 0,2 , 0,2 , {77,89,82}, 256,2 , 11318,22 , 14,5 , 4,0 , 3633,5 , 3645,7 , 2, 1, 1, 6, 7 }, // Tamil/Tamil/Malaysia
+ { 117, 27, 190, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 486,13 , 486,13 , 634,6 , 224,18 , 18,7 , 25,12 , 18099,58 , 18157,86 , 18243,31 , 18099,58 , 18274,86 , 18243,31 , 9853,20 , 9873,49 , 9853,20 , 9853,20 , 9873,49 , 9853,20 , 0,2 , 0,2 , {83,71,68}, 12,1 , 11340,24 , 14,5 , 4,0 , 3633,5 , 3652,11 , 2, 1, 7, 6, 7 }, // Tamil/Tamil/Singapore
+ { 117, 27, 198, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 486,13 , 486,13 , 634,6 , 224,18 , 18,7 , 25,12 , 18099,58 , 18157,86 , 18243,31 , 18099,58 , 18274,86 , 18243,31 , 9853,20 , 9873,49 , 9853,20 , 9853,20 , 9873,49 , 9853,20 , 0,2 , 0,2 , {76,75,82}, 310,3 , 11364,20 , 14,5 , 4,0 , 3633,5 , 3663,6 , 2, 1, 1, 6, 7 }, // Tamil/Tamil/SriLanka
+ { 119, 28, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 499,11 , 499,11 , 503,8 , 99,16 , 18,7 , 25,12 , 18360,66 , 18426,86 , 18512,31 , 18543,78 , 18426,86 , 18621,31 , 9922,32 , 9954,60 , 10014,18 , 9922,32 , 9954,60 , 10014,18 , 0,2 , 0,2 , {73,78,82}, 122,1 , 11384,26 , 4,4 , 8,6 , 3669,6 , 3675,9 , 2, 1, 7, 7, 7 }, // Telugu/Telugu/India
+ { 120, 30, 211, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 510,5 , 510,5 , 515,8 , 523,7 , 287,6 , 1098,19 , 37,5 , 508,28 , 18652,63 , 18715,98 , 18652,63 , 18652,63 , 18715,98 , 18813,62 , 10032,23 , 10055,68 , 10032,23 , 10032,23 , 10055,68 , 10032,23 , 284,10 , 274,10 , {84,72,66}, 313,1 , 11410,13 , 4,4 , 8,6 , 3684,3 , 3684,3 , 2, 1, 7, 6, 7 }, // Thai/Thai/Thailand
+ { 121, 31, 44, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 2663,63 , 18875,158 , 158,27 , 2663,63 , 18875,158 , 158,27 , 10123,49 , 10172,77 , 10249,21 , 10123,49 , 10172,77 , 10270,22 , 294,7 , 284,8 , {67,78,89}, 314,1 , 11423,13 , 14,5 , 4,0 , 3687,8 , 3695,6 , 2, 1, 7, 6, 7 }, // Tibetan/Tibetan/China
+ { 121, 31, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 2663,63 , 18875,158 , 158,27 , 2663,63 , 18875,158 , 158,27 , 10123,49 , 10172,77 , 10249,21 , 10123,49 , 10172,77 , 10270,22 , 294,7 , 284,8 , {73,78,82}, 122,1 , 11436,22 , 14,5 , 4,0 , 3687,8 , 3701,7 , 2, 1, 7, 7, 7 }, // Tibetan/Tibetan/India
+ { 122, 14, 69, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 1117,23 , 18,7 , 25,12 , 19033,46 , 19079,62 , 1050,24 , 19033,46 , 19079,62 , 1050,24 , 10292,29 , 10292,29 , 10321,14 , 10292,29 , 10292,29 , 10321,14 , 301,7 , 292,7 , {69,84,66}, 0,2 , 11458,16 , 4,4 , 4,0 , 3708,4 , 103,5 , 2, 1, 7, 6, 7 }, // Tigrinya/Ethiopic/Ethiopia
+ { 122, 14, 67, 46, 44, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 1140,23 , 18,7 , 25,12 , 19141,46 , 19187,54 , 1050,24 , 19141,46 , 19187,54 , 1050,24 , 10335,29 , 10335,29 , 10321,14 , 10335,29 , 10335,29 , 10321,14 , 301,7 , 292,7 , {69,82,78}, 8,3 , 0,7 , 4,4 , 4,0 , 3708,4 , 3712,4 , 2, 1, 1, 6, 7 }, // Tigrinya/Ethiopic/Eritrea
+ { 123, 7, 214, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 530,8 , 530,8 , 530,8 , 530,8 , 287,6 , 99,16 , 37,5 , 8,10 , 19241,51 , 19292,87 , 19379,24 , 19241,51 , 19292,87 , 19379,24 , 10364,29 , 10393,60 , 10453,14 , 10364,29 , 10393,60 , 10453,14 , 0,2 , 0,2 , {84,79,80}, 195,2 , 0,7 , 14,5 , 4,0 , 3716,13 , 1333,5 , 2, 1, 1, 6, 7 }, // Tongan/Latin/Tonga
+ { 124, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 19403,48 , 19451,122 , 158,27 , 19403,48 , 19451,122 , 158,27 , 10467,27 , 10494,72 , 85,14 , 10467,27 , 10494,72 , 85,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 3729,8 , 0,0 , 2, 1, 7, 6, 7 }, // Tsonga/Latin/SouthAfrica
+ { 125, 7, 217, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 538,8 , 538,8 , 1163,9 , 1172,16 , 37,5 , 8,10 , 19573,48 , 19621,75 , 19696,24 , 19573,48 , 19621,75 , 19696,24 , 10566,28 , 10594,54 , 10648,14 , 10566,28 , 10594,54 , 10648,14 , 308,2 , 299,2 , {84,82,89}, 315,1 , 11474,18 , 25,5 , 30,7 , 3737,6 , 3743,7 , 2, 1, 1, 6, 7 }, // Turkish/Latin/Turkey
+ { 125, 7, 56, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 538,8 , 538,8 , 1163,9 , 1172,16 , 37,5 , 8,10 , 19573,48 , 19621,75 , 19696,24 , 19573,48 , 19621,75 , 19696,24 , 10566,28 , 10594,54 , 10648,14 , 10566,28 , 10594,54 , 10648,14 , 308,2 , 299,2 , {69,85,82}, 131,1 , 7151,11 , 25,5 , 30,7 , 3737,6 , 3750,23 , 2, 1, 1, 6, 7 }, // Turkish/Latin/Cyprus
+ { 129, 2, 222, 44, 160, 59, 37, 48, 45, 43, 1077, 171, 187, 8222, 8220, 0,6 , 0,6 , 546,8 , 546,8 , 187,8 , 1188,22 , 37,5 , 8,10 , 19720,48 , 19768,95 , 19863,24 , 19887,67 , 19954,87 , 19863,24 , 10662,21 , 10683,56 , 10739,14 , 10662,21 , 10683,56 , 10739,14 , 310,2 , 301,2 , {85,65,72}, 279,1 , 11492,49 , 25,5 , 4,0 , 3773,10 , 3783,7 , 2, 1, 1, 6, 7 }, // Ukrainian/Cyrillic/Ukraine
+ { 130, 1, 163, 46, 44, 59, 37, 48, 45, 43, 101, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 554,10 , 564,9 , 287,6 , 161,18 , 18,7 , 25,12 , 20041,66 , 20041,66 , 134,24 , 20041,66 , 20041,66 , 134,24 , 10753,36 , 10753,36 , 85,14 , 10753,36 , 10753,36 , 85,14 , 312,9 , 303,9 , {80,75,82}, 180,2 , 11541,21 , 4,4 , 4,0 , 3790,4 , 3794,7 , 0, 0, 7, 6, 7 }, // Urdu/Arabic/Pakistan
+ { 130, 1, 100, 46, 44, 59, 37, 1776, 45, 43, 1602, 8221, 8220, 8217, 8216, 37,6 , 37,6 , 554,10 , 564,9 , 287,6 , 161,18 , 18,7 , 25,12 , 20041,66 , 20041,66 , 134,24 , 20041,66 , 20041,66 , 134,24 , 10753,36 , 10753,36 , 85,14 , 10753,36 , 10753,36 , 85,14 , 312,9 , 303,9 , {73,78,82}, 122,1 , 11562,18 , 14,5 , 4,0 , 3790,4 , 3801,5 , 2, 1, 7, 7, 7 }, // Urdu/Arabic/India
+ { 131, 2, 228, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 242,8 , 269,18 , 37,5 , 8,10 , 17980,48 , 18028,71 , 14970,24 , 17980,48 , 18028,71 , 14970,24 , 10789,28 , 10817,53 , 10870,14 , 10789,28 , 10817,53 , 10870,14 , 0,2 , 0,2 , {85,90,83}, 316,3 , 11580,21 , 14,5 , 4,0 , 3806,5 , 3811,10 , 0, 0, 1, 6, 7 }, // Uzbek/Cyrillic/Uzbekistan
+ { 131, 1, 1, 1643, 1644, 1563, 1642, 1776, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 179,8 , 1210,33 , 61,4 , 408,11 , 20107,48 , 13771,68 , 158,27 , 20107,48 , 13771,68 , 158,27 , 10884,21 , 7208,49 , 85,14 , 10884,21 , 7208,49 , 85,14 , 0,2 , 0,2 , {65,70,78}, 263,1 , 11601,13 , 25,5 , 4,0 , 3821,6 , 2776,9 , 0, 0, 6, 4, 5 }, // Uzbek/Arabic/Afghanistan
+ { 131, 7, 228, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 242,8 , 269,18 , 37,5 , 8,10 , 20155,52 , 20207,77 , 20284,24 , 20155,52 , 20207,77 , 20284,24 , 10905,34 , 10939,61 , 11000,14 , 10905,34 , 10939,61 , 11000,14 , 0,2 , 0,2 , {85,90,83}, 319,4 , 11614,23 , 14,5 , 4,0 , 3827,9 , 3836,11 , 0, 0, 1, 6, 7 }, // Uzbek/Latin/Uzbekistan
+ { 132, 7, 232, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 573,8 , 573,8 , 141,10 , 1243,31 , 37,5 , 8,10 , 20308,75 , 20383,130 , 158,27 , 20308,75 , 20383,130 , 158,27 , 11014,33 , 11047,55 , 11102,21 , 11014,33 , 11047,55 , 11102,21 , 321,2 , 312,2 , {86,78,68}, 323,1 , 11637,20 , 25,5 , 4,0 , 3847,10 , 3857,8 , 0, 0, 1, 6, 7 }, // Vietnamese/Latin/Vietnam
+ { 134, 7, 224, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 135,7 , 135,7 , 141,10 , 10,17 , 37,5 , 8,10 , 20513,52 , 20565,87 , 20652,26 , 20678,62 , 20565,87 , 20652,26 , 11123,29 , 11152,77 , 11229,15 , 11244,30 , 11152,77 , 11229,15 , 0,2 , 0,2 , {71,66,80}, 171,1 , 11657,154 , 4,4 , 4,0 , 3865,7 , 3872,16 , 2, 1, 1, 6, 7 }, // Welsh/Latin/UnitedKingdom
+ { 136, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 20740,48 , 20788,91 , 158,27 , 20740,48 , 20788,91 , 158,27 , 11274,28 , 11302,61 , 85,14 , 11274,28 , 11302,61 , 85,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 3888,8 , 0,0 , 2, 1, 7, 6, 7 }, // Xhosa/Latin/SouthAfrica
+ { 138, 7, 157, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 20879,73 , 20952,121 , 158,27 , 20879,73 , 20952,121 , 158,27 , 11363,44 , 11407,69 , 85,14 , 11363,44 , 11407,69 , 85,14 , 323,5 , 314,5 , {78,71,78}, 182,1 , 11811,34 , 4,4 , 8,6 , 3896,10 , 3906,18 , 2, 1, 1, 6, 7 }, // Yoruba/Latin/Nigeria
+ { 140, 7, 195, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 581,9 , 590,10 , 72,10 , 82,17 , 18,7 , 25,12 , 21073,48 , 21121,104 , 134,24 , 21073,48 , 21225,90 , 134,24 , 11476,28 , 11504,68 , 11572,14 , 11476,28 , 11504,68 , 11572,14 , 328,7 , 319,8 , {90,65,82}, 11,1 , 11845,27 , 4,4 , 8,6 , 3924,7 , 3931,17 , 2, 1, 7, 6, 7 }, // Zulu/Latin/SouthAfrica
+ { 141, 7, 161, 44, 160, 59, 37, 48, 8722, 43, 101, 171, 187, 8216, 8217, 0,6 , 0,6 , 142,8 , 142,8 , 187,8 , 554,17 , 37,5 , 392,16 , 5815,48 , 13184,83 , 134,24 , 13267,59 , 13184,83 , 134,24 , 11586,28 , 11614,51 , 2309,14 , 11665,28 , 11614,51 , 2309,14 , 335,9 , 327,11 , {78,79,75}, 157,2 , 11872,42 , 25,5 , 4,0 , 3948,7 , 3955,5 , 2, 1, 1, 6, 7 }, // NorwegianNynorsk/Latin/Norway
+ { 142, 7, 27, 44, 46, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 118,7 , 118,7 , 1274,9 , 981,20 , 37,5 , 8,10 , 15514,48 , 21315,83 , 15643,24 , 15514,48 , 21315,83 , 15643,24 , 2032,28 , 2060,58 , 85,14 , 2032,28 , 2060,58 , 85,14 , 248,9 , 238,7 , {66,65,77}, 153,2 , 11914,218 , 14,5 , 4,0 , 3960,8 , 581,19 , 2, 1, 1, 6, 7 }, // Bosnian/Latin/BosniaAndHerzegowina
+ { 142, 2, 27, 44, 46, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 102,7 , 102,7 , 974,7 , 981,20 , 37,5 , 8,10 , 15302,48 , 15431,83 , 11981,24 , 15302,48 , 15431,83 , 11981,24 , 8275,28 , 8303,54 , 8261,14 , 8275,28 , 8303,54 , 8261,14 , 239,9 , 231,7 , {66,65,77}, 284,2 , 12132,195 , 25,5 , 4,0 , 3968,8 , 3111,19 , 2, 1, 1, 6, 7 }, // Bosnian/Cyrillic/BosniaAndHerzegowina
+ { 144, 7, 224, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 82,17 , 37,5 , 8,10 , 21398,102 , 21500,140 , 158,27 , 21398,102 , 21500,140 , 158,27 , 11693,30 , 11723,57 , 85,14 , 11693,30 , 11723,57 , 85,14 , 75,4 , 74,4 , {71,66,80}, 171,1 , 0,7 , 4,4 , 4,0 , 3976,5 , 3981,14 , 2, 1, 1, 6, 7 }, // Manx/Latin/UnitedKingdom
+ { 145, 7, 224, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 99,16 , 37,5 , 8,10 , 21640,46 , 21686,124 , 158,27 , 21640,46 , 21686,124 , 158,27 , 11780,28 , 11808,60 , 85,14 , 11780,28 , 11808,60 , 85,14 , 75,4 , 74,4 , {71,66,80}, 171,1 , 0,7 , 4,4 , 4,0 , 3995,8 , 3981,14 , 2, 1, 1, 6, 7 }, // Cornish/Latin/UnitedKingdom
+ { 146, 7, 83, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 242,8 , 269,18 , 37,5 , 8,10 , 21810,48 , 21858,192 , 158,27 , 21810,48 , 21858,192 , 158,27 , 11868,28 , 11896,49 , 11945,14 , 11868,28 , 11896,49 , 11945,14 , 344,2 , 338,2 , {71,72,83}, 173,3 , 12327,17 , 4,4 , 4,0 , 4003,4 , 4007,5 , 2, 1, 1, 6, 7 }, // Akan/Latin/Ghana
+ { 147, 13, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 634,6 , 99,16 , 18,7 , 25,12 , 22050,87 , 22050,87 , 158,27 , 22050,87 , 22050,87 , 158,27 , 6771,32 , 11959,55 , 85,14 , 6771,32 , 11959,55 , 85,14 , 346,5 , 340,5 , {73,78,82}, 122,1 , 0,7 , 14,5 , 4,0 , 4012,6 , 2276,4 , 2, 1, 7, 7, 7 }, // Konkani/Devanagari/India
+ { 149, 7, 157, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 22137,48 , 22185,86 , 158,27 , 22137,48 , 22185,86 , 158,27 , 12014,29 , 12043,57 , 85,14 , 12014,29 , 12043,57 , 85,14 , 351,4 , 345,4 , {78,71,78}, 182,1 , 12344,12 , 4,4 , 8,6 , 4018,4 , 1107,7 , 2, 1, 1, 6, 7 }, // Igbo/Latin/Nigeria
+ { 150, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 22271,48 , 22319,189 , 22508,24 , 22271,48 , 22319,189 , 22508,24 , 12100,28 , 12128,74 , 12202,14 , 12100,28 , 12128,74 , 12202,14 , 355,9 , 349,7 , {75,69,83}, 2,3 , 12356,23 , 4,4 , 8,6 , 4022,7 , 1006,5 , 2, 1, 7, 6, 7 }, // Kamba/Latin/Kenya
+ { 152, 14, 67, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 1283,22 , 18,7 , 25,12 , 22532,47 , 22579,77 , 22656,24 , 22532,47 , 22579,77 , 22656,24 , 12216,26 , 12242,43 , 12285,14 , 12216,26 , 12242,43 , 12285,14 , 0,2 , 0,2 , {69,82,78}, 8,3 , 0,7 , 4,4 , 4,0 , 4029,3 , 3712,4 , 2, 1, 1, 6, 7 }, // Blin/Ethiopic/Eritrea
+ { 157, 14, 67, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 1305,21 , 18,7 , 25,12 , 19033,46 , 19079,62 , 1050,24 , 19033,46 , 19079,62 , 1050,24 , 12299,27 , 12326,41 , 12367,14 , 12299,27 , 12326,41 , 12367,14 , 0,2 , 0,2 , {69,82,78}, 8,3 , 0,7 , 4,4 , 4,0 , 4032,3 , 3712,4 , 2, 1, 1, 6, 7 }, // Tigre/Ethiopic/Eritrea
+ { 159, 7, 106, 44, 46, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 206,7 , 206,7 , 27,8 , 1326,27 , 37,5 , 8,10 , 22680,48 , 22728,77 , 22805,24 , 22680,48 , 22728,77 , 22805,24 , 12381,28 , 12409,50 , 3070,14 , 12381,28 , 12409,50 , 3070,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 14,5 , 4,0 , 4035,6 , 4041,6 , 2, 1, 1, 6, 7 }, // Friulian/Latin/Italy
+ { 160, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 22829,48 , 22877,111 , 158,27 , 22829,48 , 22877,111 , 158,27 , 12459,27 , 12486,70 , 85,14 , 12459,27 , 12486,70 , 85,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 4047,9 , 0,0 , 2, 1, 7, 6, 7 }, // Venda/Latin/SouthAfrica
+ { 161, 7, 83, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 600,11 , 611,10 , 518,6 , 1353,23 , 536,12 , 548,12 , 22988,48 , 23036,87 , 23123,24 , 22988,48 , 23036,87 , 23123,24 , 12556,28 , 12584,44 , 12628,14 , 12556,28 , 12584,44 , 12628,14 , 364,3 , 356,5 , {71,72,83}, 173,3 , 12379,37 , 4,4 , 8,6 , 4056,6 , 4062,12 , 2, 1, 1, 6, 7 }, // Ewe/Latin/Ghana
+ { 161, 7, 212, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 600,11 , 611,10 , 518,6 , 1353,23 , 536,12 , 548,12 , 22988,48 , 23036,87 , 23123,24 , 22988,48 , 23036,87 , 23123,24 , 12556,28 , 12584,44 , 12628,14 , 12556,28 , 12584,44 , 12628,14 , 364,3 , 356,5 , {88,79,70}, 209,3 , 12416,106 , 4,4 , 8,6 , 4056,6 , 4074,11 , 0, 0, 1, 6, 7 }, // Ewe/Latin/Togo
+ { 162, 14, 69, 46, 8217, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 1376,22 , 18,7 , 25,12 , 19033,46 , 19079,62 , 1050,24 , 19033,46 , 19079,62 , 1050,24 , 12642,27 , 12642,27 , 12669,14 , 12642,27 , 12642,27 , 12669,14 , 0,2 , 0,2 , {69,84,66}, 0,2 , 11458,16 , 4,4 , 4,0 , 4085,5 , 103,5 , 2, 1, 7, 6, 7 }, // Walamo/Ethiopic/Ethiopia
+ { 163, 7, 225, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 287,6 , 10,17 , 18,7 , 25,12 , 23147,59 , 23206,95 , 158,27 , 23147,59 , 23206,95 , 158,27 , 12683,21 , 12704,57 , 85,14 , 12683,21 , 12704,57 , 85,14 , 0,2 , 0,2 , {85,83,68}, 12,1 , 0,7 , 4,4 , 8,6 , 4090,14 , 4104,19 , 2, 1, 7, 6, 7 }, // Hawaiian/Latin/UnitedStates
+ { 166, 7, 170, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 621,8 , 621,8 , 518,6 , 1398,18 , 37,5 , 8,10 , 23301,48 , 23349,88 , 23437,24 , 23301,48 , 23349,88 , 23437,24 , 12761,28 , 12789,55 , 12844,14 , 12858,28 , 12789,55 , 12844,14 , 0,2 , 0,2 , {80,72,80}, 183,1 , 12522,22 , 4,4 , 8,6 , 4123,8 , 4131,9 , 2, 1, 7, 6, 7 }, // Filipino/Latin/Philippines
+ { 167, 7, 206, 46, 8217, 59, 37, 48, 8722, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 221,9 , 221,9 , 187,8 , 462,18 , 37,5 , 8,10 , 6990,48 , 23461,86 , 134,24 , 6990,48 , 23461,86 , 134,24 , 12886,28 , 12914,63 , 3471,14 , 12886,28 , 12914,63 , 3471,14 , 94,5 , 361,4 , {67,72,70}, 230,3 , 12544,55 , 25,5 , 4,0 , 4140,16 , 4156,7 , 2, 0, 1, 6, 7 }, // Swiss German/Latin/Switzerland
+ { 168, 34, 44, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 158,27 , 23547,38 , 158,27 , 158,27 , 23547,38 , 158,27 , 12977,21 , 12998,28 , 13026,14 , 12977,21 , 12998,28 , 13026,14 , 367,2 , 365,2 , {67,78,89}, 314,1 , 0,7 , 14,5 , 4,0 , 4163,3 , 4166,2 , 2, 1, 7, 6, 7 }, // Sichuan Yi/Yi/China
+ { 171, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 23585,48 , 23633,100 , 158,27 , 23585,48 , 23633,100 , 158,27 , 13040,27 , 13067,66 , 85,14 , 13040,27 , 13067,66 , 85,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 4168,10 , 0,0 , 2, 1, 7, 6, 7 }, // South Ndebele/Latin/SouthAfrica
+ { 172, 7, 195, 44, 160, 59, 37, 48, 45, 43, 101, 8216, 8217, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 323,17 , 37,5 , 8,10 , 23733,48 , 23781,94 , 158,27 , 23733,48 , 23781,94 , 158,27 , 13133,27 , 13160,63 , 85,14 , 13133,27 , 13160,63 , 85,14 , 0,2 , 0,2 , {90,65,82}, 11,1 , 0,7 , 4,4 , 4,0 , 4178,16 , 0,0 , 2, 1, 7, 6, 7 }, // Northern Sotho/Latin/SouthAfrica
+ { 173, 7, 161, 44, 160, 59, 37, 48, 8722, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 169,8 , 169,8 , 72,10 , 323,17 , 37,5 , 8,10 , 23875,59 , 23934,145 , 24079,24 , 23875,59 , 23934,145 , 24079,24 , 13223,33 , 13256,75 , 13331,14 , 13223,33 , 13256,75 , 13331,14 , 0,2 , 0,2 , {78,79,75}, 157,2 , 12599,63 , 25,5 , 4,0 , 4194,15 , 4209,5 , 2, 1, 1, 6, 7 }, // Northern Sami/Latin/Norway
+ { 173, 7, 73, 44, 160, 59, 37, 48, 8722, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 169,8 , 169,8 , 72,10 , 323,17 , 37,5 , 8,10 , 24103,85 , 23934,145 , 24079,24 , 24103,85 , 23934,145 , 24079,24 , 13223,33 , 13345,65 , 13410,14 , 13223,33 , 13345,65 , 13410,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 12662,23 , 25,5 , 4,0 , 4194,15 , 4214,6 , 2, 1, 1, 6, 7 }, // Northern Sami/Latin/Finland
+ { 175, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 24188,48 , 24236,88 , 24324,24 , 24188,48 , 24236,88 , 24324,24 , 13424,28 , 13452,62 , 13514,14 , 13424,28 , 13452,62 , 13514,14 , 369,5 , 367,10 , {75,69,83}, 2,3 , 12685,24 , 4,4 , 8,6 , 4220,8 , 1006,5 , 2, 1, 7, 6, 7 }, // Gusii/Latin/Kenya
+ { 176, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 24348,48 , 24396,221 , 24617,24 , 24348,48 , 24396,221 , 24617,24 , 13528,28 , 13556,105 , 13661,14 , 13528,28 , 13556,105 , 13661,14 , 374,10 , 377,10 , {75,69,83}, 2,3 , 12685,24 , 4,4 , 8,6 , 4228,7 , 1006,5 , 2, 1, 7, 6, 7 }, // Taita/Latin/Kenya
+ { 177, 7, 187, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8221, 8218, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 24641,48 , 24689,77 , 24766,24 , 24641,48 , 24689,77 , 24766,24 , 13675,28 , 13703,59 , 13762,14 , 13675,28 , 13703,59 , 13762,14 , 384,6 , 387,7 , {88,79,70}, 209,3 , 12709,26 , 25,5 , 4,0 , 4235,6 , 4241,8 , 0, 0, 1, 6, 7 }, // Fulah/Latin/Senegal
+ { 178, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 24790,48 , 24838,185 , 25023,24 , 24790,48 , 24838,185 , 25023,24 , 13776,28 , 13804,63 , 13867,14 , 13776,28 , 13804,63 , 13867,14 , 390,6 , 394,8 , {75,69,83}, 2,3 , 12735,23 , 4,4 , 8,6 , 4249,6 , 1006,5 , 2, 1, 7, 6, 7 }, // Kikuyu/Latin/Kenya
+ { 179, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 25047,48 , 25095,173 , 25268,24 , 25047,48 , 25095,173 , 25268,24 , 13881,28 , 13909,105 , 14014,14 , 13881,28 , 13909,105 , 14014,14 , 396,7 , 402,5 , {75,69,83}, 2,3 , 12758,25 , 4,4 , 8,6 , 4255,8 , 1006,5 , 2, 1, 7, 6, 7 }, // Samburu/Latin/Kenya
+ { 180, 7, 146, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 897,27 , 37,5 , 8,10 , 25292,48 , 25340,88 , 134,24 , 25292,48 , 25340,88 , 134,24 , 14028,28 , 14056,55 , 14111,14 , 14028,28 , 14056,55 , 14111,14 , 0,2 , 0,2 , {77,90,78}, 269,3 , 12783,28 , 0,4 , 4,0 , 4263,4 , 2902,10 , 2, 1, 7, 6, 7 }, // Sena/Latin/Mozambique
+ { 181, 7, 240, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 25428,52 , 25480,112 , 25592,24 , 25428,52 , 25480,112 , 25592,24 , 14125,28 , 14153,50 , 14203,14 , 14125,28 , 14153,50 , 14203,14 , 0,2 , 0,2 , {85,83,68}, 204,3 , 12811,24 , 4,4 , 8,6 , 4168,10 , 1491,8 , 2, 1, 7, 6, 7 }, // North Ndebele/Latin/Zimbabwe
+ { 182, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 25616,39 , 25655,194 , 25849,24 , 25616,39 , 25655,194 , 25849,24 , 14217,29 , 14246,65 , 14311,14 , 14217,29 , 14246,65 , 14311,14 , 403,8 , 407,7 , {84,90,83}, 192,3 , 12835,25 , 4,4 , 4,0 , 4267,9 , 1325,8 , 0, 0, 1, 6, 7 }, // Rombo/Latin/Tanzania
+ { 183, 9, 145, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 25873,48 , 25921,81 , 26002,24 , 25873,48 , 25921,81 , 26002,24 , 14325,30 , 14355,47 , 85,14 , 14325,30 , 14355,47 , 85,14 , 411,6 , 414,8 , {77,65,68}, 0,0 , 12860,21 , 0,4 , 4,0 , 4276,8 , 4284,6 , 2, 1, 6, 5, 6 }, // Tachelhit/Tifinagh/Morocco
+ { 183, 7, 145, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 26026,48 , 26074,81 , 26155,24 , 26026,48 , 26074,81 , 26155,24 , 14402,30 , 14432,48 , 85,14 , 14402,30 , 14432,48 , 85,14 , 417,6 , 422,8 , {77,65,68}, 0,0 , 12881,21 , 0,4 , 4,0 , 4290,9 , 4299,6 , 2, 1, 6, 5, 6 }, // Tachelhit/Latin/Morocco
+ { 184, 7, 3, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 26179,48 , 26227,84 , 26311,24 , 26179,48 , 26227,84 , 26311,24 , 14480,30 , 14510,51 , 14561,14 , 14480,30 , 14510,51 , 14561,14 , 423,7 , 430,9 , {68,90,68}, 207,2 , 12902,21 , 0,4 , 4,0 , 4305,9 , 4314,8 , 2, 1, 6, 4, 5 }, // Kabyle/Latin/Algeria
+ { 185, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 26335,48 , 26383,152 , 134,24 , 26335,48 , 26383,152 , 134,24 , 14575,28 , 14603,74 , 14677,14 , 14575,28 , 14603,74 , 14677,14 , 0,2 , 0,2 , {85,71,88}, 197,3 , 12923,26 , 4,4 , 78,5 , 4322,10 , 1381,6 , 0, 0, 1, 6, 7 }, // Nyankole/Latin/Uganda
+ { 186, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 26535,48 , 26583,254 , 26837,24 , 26535,48 , 26583,254 , 26837,24 , 14691,28 , 14719,82 , 14801,14 , 14691,28 , 14719,82 , 14801,14 , 430,7 , 439,7 , {84,90,83}, 192,3 , 12949,29 , 0,4 , 4,0 , 4332,6 , 4338,10 , 0, 0, 1, 6, 7 }, // Bena/Latin/Tanzania
+ { 187, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 17628,48 , 26861,87 , 134,24 , 17628,48 , 26861,87 , 134,24 , 14815,28 , 14843,62 , 14905,14 , 14815,28 , 14843,62 , 14905,14 , 437,5 , 446,9 , {84,90,83}, 192,3 , 12978,27 , 4,4 , 4,0 , 4348,8 , 1325,8 , 0, 0, 1, 6, 7 }, // Vunjo/Latin/Tanzania
+ { 188, 7, 132, 46, 44, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 26948,47 , 26995,92 , 27087,24 , 26948,47 , 26995,92 , 27087,24 , 14919,28 , 14947,44 , 14991,14 , 14919,28 , 14947,44 , 14991,14 , 0,2 , 0,2 , {88,79,70}, 209,3 , 13005,24 , 4,4 , 8,6 , 4356,9 , 1836,4 , 0, 0, 1, 6, 7 }, // Bambara/Latin/Mali
+ { 189, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 27111,48 , 27159,207 , 27366,24 , 27111,48 , 27159,207 , 27366,24 , 15005,28 , 15033,64 , 15097,14 , 15005,28 , 15033,64 , 15097,14 , 442,2 , 455,2 , {75,69,83}, 2,3 , 12685,24 , 4,4 , 8,6 , 4365,6 , 1006,5 , 2, 1, 7, 6, 7 }, // Embu/Latin/Kenya
+ { 190, 12, 225, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 518,6 , 35,18 , 18,7 , 25,12 , 27390,36 , 27426,58 , 27484,24 , 27390,36 , 27426,58 , 27484,24 , 15111,28 , 15139,49 , 15188,14 , 15111,28 , 15139,49 , 15188,14 , 444,3 , 457,6 , {85,83,68}, 12,1 , 13029,19 , 4,4 , 8,6 , 4371,3 , 4374,4 , 2, 1, 7, 6, 7 }, // Cherokee/Cherokee/UnitedStates
+ { 191, 7, 137, 46, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 27508,47 , 27555,68 , 27623,24 , 27508,47 , 27555,68 , 27623,24 , 15202,27 , 15229,48 , 15277,14 , 15202,27 , 15229,48 , 15277,14 , 0,2 , 0,2 , {77,85,82}, 180,2 , 13048,21 , 14,5 , 4,0 , 4378,14 , 4392,5 , 0, 0, 1, 6, 7 }, // Morisyen/Latin/Mauritius
+ { 192, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 17628,48 , 27647,264 , 134,24 , 17628,48 , 27647,264 , 134,24 , 15291,28 , 15319,133 , 14311,14 , 15291,28 , 15319,133 , 14311,14 , 447,4 , 463,5 , {84,90,83}, 192,3 , 12978,27 , 4,4 , 8,6 , 4397,10 , 1325,8 , 0, 0, 1, 6, 7 }, // Makonde/Latin/Tanzania
+ { 193, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8221, 8221, 8217, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 27911,83 , 27994,111 , 28105,24 , 27911,83 , 27994,111 , 28105,24 , 15452,36 , 15488,63 , 15551,14 , 15452,36 , 15488,63 , 15551,14 , 451,3 , 468,3 , {84,90,83}, 192,3 , 13069,29 , 14,5 , 4,0 , 4407,8 , 4415,9 , 0, 0, 1, 6, 7 }, // Langi/Latin/Tanzania
+ { 194, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28129,48 , 28177,97 , 134,24 , 28129,48 , 28177,97 , 134,24 , 15565,28 , 15593,66 , 15659,14 , 15565,28 , 15593,66 , 15659,14 , 0,2 , 0,2 , {85,71,88}, 197,3 , 13098,26 , 0,4 , 4,0 , 4424,7 , 4431,7 , 0, 0, 1, 6, 7 }, // Ganda/Latin/Uganda
+ { 195, 7, 239, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28274,48 , 28322,83 , 28405,24 , 28274,48 , 28322,83 , 28405,24 , 15673,80 , 15673,80 , 85,14 , 15673,80 , 15673,80 , 85,14 , 454,8 , 471,7 , {90,77,87}, 202,2 , 0,7 , 4,4 , 8,6 , 4438,9 , 1485,6 , 2, 1, 1, 6, 7 }, // Bemba/Latin/Zambia
+ { 196, 7, 39, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 453,7 , 453,7 , 364,8 , 1416,27 , 37,5 , 8,10 , 28429,48 , 28477,86 , 134,24 , 28429,48 , 28477,86 , 134,24 , 15753,28 , 15781,73 , 15854,14 , 15753,28 , 15781,73 , 15854,14 , 89,2 , 88,2 , {67,86,69}, 0,0 , 13124,25 , 0,4 , 4,0 , 4447,12 , 4459,10 , 2, 1, 1, 6, 7 }, // Kabuverdianu/Latin/CapeVerde
+ { 197, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28563,48 , 28611,86 , 28697,24 , 28563,48 , 28611,86 , 28697,24 , 15868,28 , 15896,51 , 15947,14 , 15868,28 , 15896,51 , 15947,14 , 462,2 , 478,2 , {75,69,83}, 2,3 , 12685,24 , 4,4 , 8,6 , 4469,6 , 1006,5 , 2, 1, 7, 6, 7 }, // Meru/Latin/Kenya
+ { 198, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28721,48 , 28769,111 , 28880,24 , 28721,48 , 28769,111 , 28880,24 , 15961,28 , 15989,93 , 16082,14 , 15961,28 , 15989,93 , 16082,14 , 464,4 , 480,4 , {75,69,83}, 2,3 , 13149,26 , 4,4 , 8,6 , 4475,8 , 4483,12 , 2, 1, 7, 6, 7 }, // Kalenjin/Latin/Kenya
+ { 199, 7, 148, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 0,48 , 28904,136 , 134,24 , 0,48 , 28904,136 , 134,24 , 16096,23 , 16119,92 , 16211,14 , 16096,23 , 16119,92 , 16211,14 , 468,7 , 484,5 , {78,65,68}, 12,1 , 13175,22 , 4,4 , 4,0 , 4495,13 , 4508,8 , 2, 1, 1, 6, 7 }, // Nama/Latin/Namibia
+ { 200, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 17628,48 , 26861,87 , 134,24 , 17628,48 , 26861,87 , 134,24 , 14815,28 , 14843,62 , 14905,14 , 14815,28 , 14843,62 , 14905,14 , 437,5 , 446,9 , {84,90,83}, 192,3 , 12978,27 , 4,4 , 4,0 , 4516,9 , 1325,8 , 0, 0, 1, 6, 7 }, // Machame/Latin/Tanzania
+ { 201, 7, 82, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 347,8 , 347,8 , 1443,10 , 1453,23 , 37,5 , 8,10 , 29040,59 , 29099,87 , 134,24 , 29186,48 , 29099,87 , 134,24 , 16225,28 , 16253,72 , 3471,14 , 16225,28 , 16253,72 , 3471,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 7151,11 , 25,5 , 4,0 , 4525,6 , 4531,11 , 2, 1, 1, 6, 7 }, // Colognian/Latin/Germany
+ { 202, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 29234,51 , 29285,132 , 158,27 , 29234,51 , 29285,132 , 158,27 , 14815,28 , 16325,58 , 14311,14 , 14815,28 , 16325,58 , 14311,14 , 475,9 , 489,6 , {75,69,83}, 2,3 , 13197,25 , 4,4 , 8,6 , 4542,3 , 1006,5 , 2, 1, 7, 6, 7 }, // Masai/Latin/Kenya
+ { 202, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 29234,51 , 29285,132 , 158,27 , 29234,51 , 29285,132 , 158,27 , 14815,28 , 16325,58 , 14311,14 , 14815,28 , 16325,58 , 14311,14 , 475,9 , 489,6 , {84,90,83}, 192,3 , 13222,28 , 4,4 , 8,6 , 4542,3 , 4545,8 , 0, 0, 1, 6, 7 }, // Masai/Latin/Tanzania
+ { 203, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 28129,48 , 28177,97 , 134,24 , 28129,48 , 28177,97 , 134,24 , 16383,35 , 16418,65 , 16483,14 , 16383,35 , 16418,65 , 16483,14 , 484,6 , 495,6 , {85,71,88}, 197,3 , 13098,26 , 25,5 , 4,0 , 4553,7 , 4431,7 , 0, 0, 1, 6, 7 }, // Soga/Latin/Uganda
+ { 204, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8222, 8220, 8218, 8216, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 29417,48 , 17676,84 , 134,24 , 29417,48 , 17676,84 , 134,24 , 16497,21 , 16518,75 , 85,14 , 16497,21 , 16518,75 , 85,14 , 75,4 , 74,4 , {75,69,83}, 2,3 , 13250,23 , 4,4 , 83,6 , 4560,7 , 1006,5 , 2, 1, 7, 6, 7 }, // Luyia/Latin/Kenya
+ { 205, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 29465,48 , 17676,84 , 134,24 , 29465,48 , 17676,84 , 134,24 , 16593,28 , 9539,60 , 14905,14 , 16593,28 , 9539,60 , 14905,14 , 490,9 , 501,8 , {84,90,83}, 192,3 , 13273,28 , 25,5 , 4,0 , 4567,6 , 4573,8 , 0, 0, 1, 6, 7 }, // Asu/Latin/Tanzania
+ { 206, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 29513,48 , 29561,94 , 29655,24 , 29513,48 , 29561,94 , 29655,24 , 16621,28 , 16649,69 , 16718,14 , 16621,28 , 16649,69 , 16718,14 , 499,9 , 509,6 , {85,71,88}, 197,3 , 13301,28 , 4,4 , 8,6 , 4581,6 , 1381,6 , 0, 0, 1, 6, 7 }, // Teso/Latin/Uganda
+ { 206, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 29513,48 , 29561,94 , 29655,24 , 29513,48 , 29561,94 , 29655,24 , 16621,28 , 16649,69 , 16718,14 , 16621,28 , 16649,69 , 16718,14 , 499,9 , 509,6 , {75,69,83}, 2,3 , 13329,27 , 4,4 , 8,6 , 4581,6 , 4587,5 , 2, 1, 7, 6, 7 }, // Teso/Latin/Kenya
+ { 207, 7, 67, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 53,19 , 18,7 , 25,12 , 344,48 , 392,118 , 510,24 , 344,48 , 392,118 , 510,24 , 16732,28 , 16760,56 , 16816,14 , 16732,28 , 16760,56 , 16816,14 , 0,2 , 0,2 , {69,82,78}, 8,3 , 0,7 , 4,4 , 4,0 , 0,0 , 43,7 , 2, 1, 1, 6, 7 }, // Saho/Latin/Eritrea
+ { 208, 7, 132, 46, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 29679,46 , 29725,88 , 29813,24 , 29679,46 , 29725,88 , 29813,24 , 16830,28 , 16858,53 , 16911,14 , 16830,28 , 16858,53 , 16911,14 , 508,6 , 515,6 , {88,79,70}, 209,3 , 13356,23 , 0,4 , 4,0 , 4592,11 , 4603,5 , 0, 0, 1, 6, 7 }, // Koyra Chiini/Latin/Mali
+ { 209, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 17628,48 , 26861,87 , 134,24 , 17628,48 , 26861,87 , 134,24 , 14815,28 , 14843,62 , 14905,14 , 14815,28 , 14843,62 , 14905,14 , 437,5 , 446,9 , {84,90,83}, 192,3 , 12978,27 , 0,4 , 4,0 , 4608,6 , 1325,8 , 0, 0, 1, 6, 7 }, // Rwa/Latin/Tanzania
+ { 210, 7, 111, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 29837,48 , 29885,186 , 30071,24 , 29837,48 , 29885,186 , 30071,24 , 16925,28 , 16953,69 , 17022,14 , 16925,28 , 16953,69 , 17022,14 , 514,2 , 521,2 , {75,69,83}, 2,3 , 13379,23 , 0,4 , 4,0 , 4614,6 , 1006,5 , 2, 1, 7, 6, 7 }, // Luo/Latin/Kenya
+ { 211, 7, 221, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 26335,48 , 26383,152 , 134,24 , 26335,48 , 26383,152 , 134,24 , 14575,28 , 14603,74 , 14677,14 , 14575,28 , 14603,74 , 14677,14 , 0,2 , 0,2 , {85,71,88}, 197,3 , 12923,26 , 4,4 , 78,5 , 4620,6 , 1381,6 , 0, 0, 1, 6, 7 }, // Chiga/Latin/Uganda
+ { 212, 7, 145, 44, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 30095,48 , 30143,86 , 30229,24 , 30095,48 , 30143,86 , 30229,24 , 17036,28 , 17064,48 , 17112,14 , 17036,28 , 17064,48 , 17112,14 , 516,9 , 523,10 , {77,65,68}, 0,0 , 13402,22 , 25,5 , 4,0 , 4626,8 , 4634,6 , 2, 1, 6, 5, 6 }, // Central Morocco Tamazight/Latin/Morocco
+ { 213, 7, 132, 46, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 29679,46 , 29725,88 , 29813,24 , 29679,46 , 29725,88 , 29813,24 , 17126,28 , 17154,54 , 16911,14 , 17126,28 , 17154,54 , 16911,14 , 508,6 , 515,6 , {88,79,70}, 209,3 , 13356,23 , 0,4 , 4,0 , 4640,15 , 4603,5 , 0, 0, 1, 6, 7 }, // Koyraboro Senni/Latin/Mali
+ { 214, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 17628,48 , 30253,84 , 134,24 , 17628,48 , 30253,84 , 134,24 , 17208,28 , 17236,63 , 9599,14 , 17208,28 , 17236,63 , 9599,14 , 525,5 , 533,8 , {84,90,83}, 192,3 , 11152,27 , 0,4 , 4,0 , 4655,9 , 1325,8 , 0, 0, 1, 6, 7 }, // Shambala/Latin/Tanzania
+ { 215, 13, 100, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 518,6 , 35,18 , 18,7 , 25,12 , 30337,88 , 30337,88 , 30425,31 , 30337,88 , 30337,88 , 30425,31 , 17299,33 , 17332,54 , 17386,19 , 17299,33 , 17332,54 , 17386,19 , 530,3 , 541,6 , {73,78,82}, 122,1 , 13424,10 , 14,5 , 4,0 , 4664,4 , 2276,4 , 2, 1, 7, 7, 7 }, // Bodo/Devanagari/India
+ { 230, 7, 49, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 30456,49 , 30505,99 , 30604,24 , 30456,49 , 30505,99 , 30604,24 , 17405,28 , 17433,50 , 17483,14 , 17405,28 , 17433,50 , 17483,14 , 533,5 , 547,6 , {67,68,70}, 217,2 , 13434,24 , 0,4 , 4,0 , 4668,8 , 4676,16 , 2, 1, 1, 6, 7 }, // LubaKatanga/Latin/CongoKinshasa
+ { 237, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8221, 8218, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 30628,48 , 30676,195 , 30871,24 , 30628,48 , 30676,195 , 30871,24 , 17497,28 , 17525,72 , 17597,14 , 17497,28 , 17525,72 , 17597,14 , 538,3 , 553,3 , {88,65,70}, 36,4 , 13458,21 , 0,4 , 4,0 , 4692,5 , 4697,7 , 0, 0, 1, 6, 7 }, // Aghem/Latin/Cameroon
+ { 238, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8222, 8220, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 30895,48 , 30943,90 , 31033,24 , 30895,48 , 30943,90 , 31033,24 , 17611,28 , 17639,70 , 17709,14 , 17611,28 , 17639,70 , 17709,14 , 541,10 , 556,9 , {88,65,70}, 36,4 , 13479,22 , 25,5 , 4,0 , 4704,5 , 4709,8 , 0, 0, 1, 6, 7 }, // Basaa/Latin/Cameroon
+ { 239, 7, 156, 46, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 29679,46 , 29725,88 , 29813,24 , 29679,46 , 29725,88 , 29813,24 , 17126,28 , 17723,53 , 17776,14 , 17126,28 , 17723,53 , 17776,14 , 551,8 , 565,10 , {88,79,70}, 209,3 , 13356,23 , 0,4 , 4,0 , 4717,10 , 4727,5 , 0, 0, 1, 6, 7 }, // Zarma/Latin/Niger
+ { 240, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 31057,49 , 31106,99 , 31205,24 , 31057,49 , 31106,99 , 31205,24 , 17790,28 , 17818,45 , 17863,14 , 17790,28 , 17818,45 , 17863,14 , 559,5 , 575,6 , {88,65,70}, 36,4 , 0,7 , 25,5 , 4,0 , 4732,5 , 1615,8 , 0, 0, 1, 6, 7 }, // Duala/Latin/Cameroon
+ { 241, 7, 187, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 31229,36 , 31265,82 , 31347,24 , 31229,36 , 31265,82 , 31347,24 , 17877,28 , 17905,50 , 17955,14 , 17877,28 , 17905,50 , 17955,14 , 0,2 , 0,2 , {88,79,70}, 209,3 , 13501,23 , 25,5 , 4,0 , 4737,5 , 4742,7 , 0, 0, 1, 6, 7 }, // JolaFonyi/Latin/Senegal
+ { 242, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 31371,50 , 31421,141 , 31562,24 , 31371,50 , 31421,141 , 31562,24 , 17969,30 , 17999,85 , 18084,14 , 17969,30 , 17999,85 , 18084,14 , 564,7 , 581,9 , {88,65,70}, 36,4 , 13524,23 , 25,5 , 4,0 , 4749,6 , 4755,7 , 0, 0, 1, 6, 7 }, // Ewondo/Latin/Cameroon
+ { 243, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 31586,39 , 31625,191 , 158,27 , 31586,39 , 31625,191 , 158,27 , 18098,29 , 18127,45 , 18172,14 , 18098,29 , 18127,45 , 18172,14 , 571,6 , 590,7 , {88,65,70}, 36,4 , 13547,11 , 25,5 , 4,0 , 4762,5 , 4767,7 , 0, 0, 1, 6, 7 }, // Bafia/Latin/Cameroon
+ { 244, 7, 146, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 31816,48 , 31864,213 , 32077,24 , 31816,48 , 31864,213 , 32077,24 , 18186,28 , 18214,59 , 18273,14 , 18186,28 , 18214,59 , 18273,14 , 577,8 , 597,10 , {77,90,78}, 269,3 , 0,7 , 14,5 , 4,0 , 4774,5 , 4779,10 , 2, 1, 7, 6, 7 }, // MakhuwaMeetto/Latin/Mozambique
+ { 245, 7, 37, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 32101,48 , 32149,139 , 32288,24 , 32101,48 , 32149,139 , 32288,24 , 18287,28 , 18315,74 , 18389,14 , 18287,28 , 18315,74 , 18389,14 , 585,5 , 607,5 , {88,65,70}, 36,4 , 13558,17 , 4,4 , 8,6 , 4789,6 , 4795,7 , 0, 0, 1, 6, 7 }, // Mundang/Latin/Cameroon
+ { 246, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 8222, 8221, 171, 187, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 32312,51 , 32363,143 , 158,27 , 32312,51 , 32363,143 , 158,27 , 18403,30 , 18433,89 , 18522,14 , 18403,30 , 18433,89 , 18522,14 , 590,4 , 612,4 , {88,65,70}, 36,4 , 13575,20 , 25,5 , 4,0 , 4802,6 , 4808,7 , 0, 0, 1, 6, 7 }, // Kwasio/Latin/Cameroon
+ { 247, 7, 201, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 1476,9 , 99,16 , 18,7 , 560,12 , 32506,54 , 32560,96 , 32656,24 , 32506,54 , 32560,96 , 32656,24 , 18536,38 , 18574,79 , 18653,14 , 18536,38 , 18574,79 , 18653,14 , 594,2 , 616,2 , {83,68,71}, 0,0 , 0,7 , 4,4 , 8,6 , 4815,9 , 4824,5 , 2, 1, 6, 5, 6 }, // Nuer/Latin/Sudan
+ { 248, 2, 178, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 1485,6 , 1491,30 , 37,5 , 8,10 , 32680,75 , 32755,121 , 32876,24 , 32680,75 , 32755,121 , 32876,24 , 18667,21 , 18688,73 , 18761,14 , 18667,21 , 18688,73 , 18761,14 , 0,2 , 0,2 , {82,85,66}, 275,4 , 0,7 , 14,5 , 4,0 , 4829,9 , 0,0 , 2, 1, 1, 6, 7 }, // Sakha/Cyrillic/Russia
+ { 249, 7, 210, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 32900,48 , 32948,117 , 158,27 , 32900,48 , 32948,117 , 158,27 , 18775,28 , 18803,60 , 18863,14 , 18775,28 , 18803,60 , 18863,14 , 596,9 , 618,9 , {84,90,83}, 192,3 , 13595,25 , 0,4 , 4,0 , 4838,9 , 4847,9 , 0, 0, 1, 6, 7 }, // Sangu/Latin/Tanzania
+ { 250, 7, 49, 44, 46, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 33065,48 , 33113,188 , 33301,24 , 33065,48 , 33113,188 , 33301,24 , 18877,28 , 18905,93 , 18998,14 , 18877,28 , 18905,93 , 18998,14 , 605,10 , 627,10 , {67,68,70}, 217,2 , 13620,23 , 4,4 , 4,0 , 4856,18 , 4874,32 , 2, 1, 1, 6, 7 }, // Congo Swahili/Latin/CongoKinshasa
+ { 251, 7, 156, 46, 160, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 29679,46 , 29725,88 , 29813,24 , 29679,46 , 29725,88 , 29813,24 , 17126,28 , 17154,54 , 16911,14 , 17126,28 , 17154,54 , 16911,14 , 551,8 , 565,10 , {88,79,70}, 209,3 , 13356,23 , 0,4 , 4,0 , 4906,13 , 4727,5 , 0, 0, 1, 6, 7 }, // Tasawaq/Latin/Niger
+ { 252, 35, 121, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 33325,50 , 33325,50 , 158,27 , 33325,50 , 33325,50 , 158,27 , 19012,30 , 19012,30 , 85,14 , 19012,30 , 19012,30 , 85,14 , 0,2 , 0,2 , {76,82,68}, 12,1 , 13643,15 , 4,4 , 8,6 , 4919,2 , 4921,4 , 2, 1, 1, 6, 7 }, // Vai/Vai/Liberia
+ { 252, 7, 121, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 141,10 , 10,17 , 18,7 , 25,12 , 33375,81 , 33375,81 , 158,27 , 33375,81 , 33375,81 , 158,27 , 19042,48 , 19042,48 , 85,14 , 19042,48 , 19042,48 , 85,14 , 0,2 , 0,2 , {76,82,68}, 12,1 , 13658,20 , 4,4 , 8,6 , 4925,3 , 4928,8 , 2, 1, 1, 6, 7 }, // Vai/Latin/Liberia
+ { 253, 7, 206, 44, 8217, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 221,9 , 221,9 , 72,10 , 462,18 , 37,5 , 8,10 , 33456,48 , 33504,99 , 33603,24 , 33456,48 , 33504,99 , 33603,24 , 19090,28 , 19118,53 , 19171,14 , 19090,28 , 19118,53 , 19171,14 , 0,2 , 0,2 , {67,72,70}, 0,0 , 0,7 , 14,5 , 4,0 , 4936,6 , 4942,6 , 2, 0, 1, 6, 7 }, // Walser/Latin/Switzerland
+ { 254, 7, 37, 44, 160, 59, 37, 48, 45, 43, 101, 171, 187, 171, 187, 0,6 , 0,6 , 0,6 , 0,6 , 364,8 , 99,16 , 37,5 , 8,10 , 33627,51 , 33678,191 , 158,27 , 33627,51 , 33678,191 , 158,27 , 19185,21 , 19206,71 , 19277,14 , 19185,21 , 19206,71 , 19277,14 , 615,8 , 637,8 , {88,65,70}, 36,4 , 0,7 , 25,5 , 30,7 , 4948,6 , 4954,7 , 0, 0, 1, 6, 7 }, // Yangben/Latin/Cameroon
+ { 256, 7, 197, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 453,7 , 453,7 , 287,6 , 1521,23 , 37,5 , 8,10 , 33869,48 , 33917,85 , 34002,24 , 34026,48 , 34074,117 , 34002,24 , 19291,28 , 19319,54 , 3272,14 , 19291,28 , 19319,54 , 3272,14 , 0,2 , 0,2 , {69,85,82}, 131,1 , 2449,20 , 25,5 , 4,0 , 4961,9 , 2048,6 , 2, 1, 1, 6, 7 }, // Asturian/Latin/Spain
+ { 257, 7, 37, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 629,11 , 629,11 , 640,16 , 656,9 , 72,10 , 269,18 , 37,5 , 8,10 , 34191,174 , 34191,174 , 158,27 , 34191,174 , 34191,174 , 158,27 , 19373,60 , 19373,60 , 19433,25 , 19373,60 , 19373,60 , 19433,25 , 623,8 , 645,13 , {88,65,70}, 36,4 , 13678,12 , 14,5 , 4,0 , 4970,5 , 4975,7 , 0, 0, 1, 6, 7 }, // Ngomba/Latin/Cameroon
+ { 258, 7, 37, 44, 46, 59, 37, 48, 45, 43, 101, 171, 187, 8249, 8250, 0,6 , 0,6 , 0,6 , 0,6 , 1544,10 , 82,17 , 37,5 , 8,10 , 34365,102 , 34365,102 , 158,27 , 34365,102 , 34365,102 , 158,27 , 19458,54 , 19458,54 , 19512,21 , 19458,54 , 19458,54 , 19512,21 , 0,2 , 0,2 , {88,65,70}, 36,4 , 13690,16 , 14,5 , 4,0 , 4982,4 , 4986,7 , 0, 0, 1, 6, 7 }, // Kako/Latin/Cameroon
+ { 259, 7, 37, 46, 44, 59, 37, 48, 45, 43, 101, 8220, 8221, 8216, 8217, 0,6 , 0,6 , 0,6 , 0,6 , 72,10 , 269,18 , 37,5 , 8,10 , 34467,137 , 34604,142 , 34746,36 , 34467,137 , 34604,142 , 34746,36 , 19533,49 , 19533,49 , 19582,21 , 19533,49 , 19533,49 , 19582,21 , 0,2 , 0,2 , {88,65,70}, 36,4 , 13706,12 , 14,5 , 4,0 , 4993,5 , 4998,7 , 0, 0, 1, 6, 7 }, // Meta/Latin/Cameroon
+ { 260, 7, 37, 44, 46, 44, 37, 48, 45, 43, 101, 171, 187, 8220, 8221, 0,6 , 0,6 , 0,6 , 0,6 , 27,8 , 1554,32 , 37,5 , 8,10 , 34782,164 , 34782,164 , 158,27 , 34782,164 , 34782,164 , 158,27 , 19603,111 , 19603,111 , 85,14 , 19603,111 , 19603,111 , 85,14 , 631,9 , 658,8 , {88,65,70}, 36,4 , 13718,16 , 14,5 , 4,0 , 5005,16 , 5021,7 , 0, 0, 1, 6, 7 }, // Ngiemboon/Latin/Cameroon
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, 0,0, {0,0,0}, 0,0, 0,0, 0,0, 0,0, 0, 0, 0, 0, 0, 0,0, 0,0 } // trailing 0s
};
@@ -1281,37 +1528,37 @@ static const ushort list_pattern_part_data[] = {
0x25, 0x31, 0x2c, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x65, 0x6e, 0x20, 0x25, 0x32, 0x25, 0x31, 0x1363, 0x20, 0x25, 0x32,
0x25, 0x31, 0x2c, 0x20, 0x12a5, 0x1293, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x12a5, 0x1293, 0x20, 0x25, 0x32, 0x25, 0x31, 0x60c,
0x20, 0x25, 0x32, 0x25, 0x31, 0x60c, 0x20, 0x648, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x648, 0x20, 0x25, 0x32, 0x25, 0x31,
-0x20, 0x65, 0x74, 0x61, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x98f, 0x9ac, 0x982, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20,
-0x98f, 0x9ac, 0x982, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0xf51, 0xf44, 0xf0b, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x438, 0x20,
-0x25, 0x32, 0x25, 0x31, 0x20, 0x1793, 0x17b7, 0x1784, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x69, 0x20, 0x25, 0x32, 0x25, 0x31,
-0x3001, 0x25, 0x32, 0x25, 0x31, 0x548c, 0x25, 0x32, 0x25, 0x31, 0x20, 0x61, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x6f, 0x67,
-0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x61, 0x6e, 0x64, 0x20,
-0x25, 0x32, 0x25, 0x31, 0x20, 0x6a, 0x61, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x65, 0x74, 0x20, 0x25, 0x32, 0x25, 0x31,
-0x2c, 0x20, 0x61, 0x67, 0x75, 0x73, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x61, 0x67, 0x75, 0x73, 0x20, 0x25, 0x32, 0x25,
-0x31, 0x20, 0x65, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x10d3, 0x10d0, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x75, 0x6e, 0x64,
-0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x3ba, 0x3b1, 0x3b9, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x61, 0x61, 0x6d, 0x6d, 0x61,
-0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0xa85, 0xaa8, 0xac7, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x5d5, 0x25, 0x32, 0x25, 0x31,
-0x2c, 0x20, 0x914, 0x930, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x914, 0x930, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0xe9, 0x73,
-0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x64, 0x61, 0x6e, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x64, 0x61, 0x6e, 0x20,
-0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x65, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0xcae, 0xca4, 0xccd, 0xca4, 0xcc1, 0x20,
-0x25, 0x32, 0x25, 0x31, 0x20, 0xcae, 0xca4, 0xccd, 0xca4, 0xcc1, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0xbc0f, 0x20, 0x25, 0x32,
-0x25, 0x31, 0x20, 0x75, 0x6e, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x6d, 0x70, 0xe9, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20,
-0x69, 0x72, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x25, 0x32, 0x20, 0xd0e, 0xd28, 0xd4d, 0xd28, 0xd3f, 0xd35, 0x25, 0x31,
-0x20, 0xd15, 0xd42, 0xd1f, 0xd3e, 0xd24, 0xd46, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x75, 0x20, 0x25, 0x32, 0x25, 0x31,
-0x20, 0x75, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x906, 0x923, 0x93f, 0x20, 0x25, 0x32, 0x25, 0x31, 0x60c, 0x200f, 0x20, 0x25,
-0x32, 0x25, 0x31, 0x20, 0x15f, 0x69, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x4d5, 0x43c, 0x4d5, 0x20, 0x25, 0x32, 0x25, 0x31,
-0x20, 0x69, 0x6e, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x79, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x6e, 0x61, 0x20,
-0x25, 0x32, 0x25, 0x31, 0x20, 0x6e, 0x61, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x6f, 0x63, 0x68, 0x20, 0x25, 0x32, 0x25,
-0x31, 0x20, 0xbae, 0xbb1, 0xbcd, 0xbb1, 0xbc1, 0xbae, 0xbcd, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0xc2e, 0xc30, 0xc3f, 0xc2f, 0xc41,
-0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0xe41, 0xe25, 0xe30, 0x25, 0x32, 0x25, 0x31, 0xe41, 0xe25,
-0xe30, 0x25, 0x32, 0x25, 0x31, 0x20, 0x6d, 0x6f, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x76, 0x65, 0x20, 0x25, 0x32, 0x25,
-0x31, 0x20, 0x442, 0x430, 0x20, 0x25, 0x32, 0x25, 0x31, 0x60c, 0x20, 0x627, 0x648, 0x631, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20,
-0x627, 0x648, 0x631, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x76, 0xe0, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x61, 0x20,
-0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x6e, 0x6f, 0x2d, 0x25, 0x32, 0x49, 0x2d, 0x25, 0x31, 0x20, 0x6e, 0x65, 0x2d, 0x25,
-0x32, 0x25, 0x31, 0x2c, 0x20, 0x6b, 0x70, 0x6c, 0x65, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x6b, 0x70, 0x6c, 0x65, 0x20,
-0x25, 0x32, 0x25, 0x31, 0x20, 0x61, 0x74, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x14b, 0x301, 0x261, 0x25b, 0x20, 0x25,
-0x32, 0x25, 0x31, 0x2c, 0x20, 0x1e3f, 0x62, 0x25b, 0x6e, 0x20, 0x14b, 0x301, 0x261, 0x25b, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20,
-0x70, 0x254, 0x70, 0x20, 0x25, 0x32
+0x20, 0x587, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x65, 0x74, 0x61, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x98f, 0x9ac,
+0x982, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x98f, 0x9ac, 0x982, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0xf51, 0xf44, 0xf0b, 0x20,
+0x25, 0x32, 0x25, 0x31, 0x20, 0x438, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x1793, 0x17b7, 0x1784, 0x20, 0x25, 0x32, 0x25, 0x31,
+0x20, 0x69, 0x20, 0x25, 0x32, 0x25, 0x31, 0x3001, 0x25, 0x32, 0x25, 0x31, 0x548c, 0x25, 0x32, 0x25, 0x31, 0x20, 0x61, 0x20,
+0x25, 0x32, 0x25, 0x31, 0x20, 0x6f, 0x67, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x25, 0x32,
+0x25, 0x31, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x6a, 0x61, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20,
+0x65, 0x74, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x61, 0x67, 0x75, 0x73, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x61,
+0x67, 0x75, 0x73, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x65, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x10d3, 0x10d0, 0x20, 0x25,
+0x32, 0x25, 0x31, 0x20, 0x75, 0x6e, 0x64, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x3ba, 0x3b1, 0x3b9, 0x20, 0x25, 0x32, 0x25,
+0x31, 0x20, 0x61, 0x61, 0x6d, 0x6d, 0x61, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0xa85, 0xaa8, 0xac7, 0x20, 0x25, 0x32, 0x25,
+0x31, 0x20, 0x5d5, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x914, 0x930, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x914, 0x930, 0x20,
+0x25, 0x32, 0x25, 0x31, 0x20, 0xe9, 0x73, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x64, 0x61, 0x6e, 0x20, 0x25, 0x32,
+0x25, 0x31, 0x20, 0x64, 0x61, 0x6e, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x65, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c,
+0x20, 0xcae, 0xca4, 0xccd, 0xca4, 0xcc1, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0xcae, 0xca4, 0xccd, 0xca4, 0xcc1, 0x20, 0x25, 0x32,
+0x25, 0x31, 0x20, 0xbc0f, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x75, 0x6e, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x6d, 0x70,
+0xe9, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x69, 0x72, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x25, 0x32, 0x20, 0xd0e,
+0xd28, 0xd4d, 0xd28, 0xd3f, 0xd35, 0x25, 0x31, 0x20, 0xd15, 0xd42, 0xd1f, 0xd3e, 0xd24, 0xd46, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c,
+0x20, 0x75, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x75, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x906, 0x923, 0x93f, 0x20, 0x25,
+0x32, 0x25, 0x31, 0x60c, 0x200f, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x15f, 0x69, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x4d5,
+0x43c, 0x4d5, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x69, 0x6e, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x79, 0x20, 0x25, 0x32,
+0x25, 0x31, 0x2c, 0x20, 0x6e, 0x61, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x6e, 0x61, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20,
+0x6f, 0x63, 0x68, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0xbae, 0xbb1, 0xbcd, 0xbb1, 0xbc1, 0xbae, 0xbcd, 0x20, 0x25, 0x32, 0x25,
+0x31, 0x20, 0xc2e, 0xc30, 0xc3f, 0xc2f, 0xc41, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0xe41, 0xe25,
+0xe30, 0x25, 0x32, 0x25, 0x31, 0xe41, 0xe25, 0xe30, 0x25, 0x32, 0x25, 0x31, 0x20, 0x6d, 0x6f, 0x20, 0x25, 0x32, 0x25, 0x31,
+0x20, 0x76, 0x65, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x442, 0x430, 0x20, 0x25, 0x32, 0x25, 0x31, 0x60c, 0x20, 0x627, 0x648,
+0x631, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x627, 0x648, 0x631, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x76, 0xe0, 0x20, 0x25,
+0x32, 0x25, 0x31, 0x2c, 0x20, 0x6e, 0x6f, 0x2d, 0x25, 0x32, 0x49, 0x2d, 0x25, 0x31, 0x20, 0x6e, 0x65, 0x2d, 0x25, 0x32,
+0x25, 0x31, 0x2c, 0x20, 0x6b, 0x70, 0x6c, 0x65, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x6b, 0x70, 0x6c, 0x65, 0x20, 0x25,
+0x32, 0x25, 0x31, 0x20, 0x61, 0x74, 0x20, 0x25, 0x32, 0x25, 0x31, 0x2c, 0x20, 0x14b, 0x301, 0x261, 0x25b, 0x20, 0x25, 0x32,
+0x25, 0x31, 0x2c, 0x20, 0x1e3f, 0x62, 0x25b, 0x6e, 0x20, 0x14b, 0x301, 0x261, 0x25b, 0x20, 0x25, 0x32, 0x25, 0x31, 0x20, 0x70,
+0x254, 0x70, 0x20, 0x25, 0x32
};
static const ushort date_format_data[] = {
@@ -1324,37 +1571,41 @@ static const ushort date_format_data[] = {
0x2d, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79,
0x79, 0x64, 0x64, 0x2f, 0x4d, 0x4d, 0x2f, 0x79, 0x79, 0x79, 0x79, 0x64, 0x200f, 0x2f, 0x4d, 0x200f, 0x2f, 0x79, 0x79, 0x79,
0x79, 0x64, 0x64, 0x64, 0x64, 0x60c, 0x20, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x60c, 0x20, 0x79, 0x79, 0x79, 0x79, 0x79,
-0x79, 0x79, 0x79, 0x2f, 0x4d, 0x2f, 0x64, 0x4d, 0x4d, 0x2f, 0x64, 0x64, 0x2f, 0x79, 0x79, 0x64, 0x2d, 0x4d, 0x2d, 0x79,
-0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x2c, 0x20, 0x79, 0x79, 0x79,
-0x79, 0x79, 0x79, 0x2f, 0x4d, 0x4d, 0x2f, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x2c, 0x20, 0x4d, 0x4d,
-0x4d, 0x4d, 0x2c, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x79, 0x79, 0x79, 0x79, 0x20, 0x4d,
-0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x64, 0x64, 0x2f, 0x4d, 0x2f, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0xf66, 0xfa4,
-0xfb1, 0xf72, 0xf0b, 0xf63, 0xf7c, 0xf0b, 0x79, 0x79, 0x79, 0x79, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0xf5a, 0xf7a, 0xf66, 0xf0b,
-0x64, 0x64, 0x64, 0x64, 0x2e, 0x4d, 0x4d, 0x2e, 0x79, 0x79, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79,
-0x79, 0x79, 0x2c, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2e, 0x4d, 0x2e, 0x79, 0x79, 0x64, 0x2f, 0x4d, 0x2f, 0x79, 0x79,
-0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x20, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x27, 0x64, 0x65, 0x27, 0x20, 0x79,
-0x79, 0x79, 0x79, 0x79, 0x79, 0x2d, 0x4d, 0x2d, 0x64, 0x79, 0x79, 0x79, 0x79, 0x5e74, 0x4d, 0x6708, 0x64, 0x65e5, 0x64, 0x64,
-0x64, 0x64, 0x79, 0x79, 0x5e74, 0x4d, 0x6708, 0x64, 0x65e5, 0x79, 0x79, 0x79, 0x79, 0x5e74, 0x4d, 0x4d, 0x6708, 0x64, 0x64, 0x65e5,
-0x64, 0x64, 0x64, 0x64, 0x64, 0x2e, 0x4d, 0x2e, 0x79, 0x79, 0x79, 0x79, 0x2e, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64,
-0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x2e, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x2e,
-0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x20, 0x27, 0x64, 0x65, 0x6e, 0x27,
-0x20, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x2d, 0x4d, 0x4d, 0x2d, 0x79,
-0x79, 0x64, 0x2f, 0x4d, 0x4d, 0x2f, 0x79, 0x79, 0x4d, 0x2f, 0x64, 0x2f, 0x79, 0x79, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d,
-0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x79, 0x79, 0x79, 0x79, 0x2f, 0x4d, 0x4d, 0x2f, 0x64, 0x64, 0x64, 0x2e, 0x4d, 0x2e,
-0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x20, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79,
-0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79,
-0x64, 0x2d, 0x4d, 0x4d, 0x2d, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x20, 0x5d1, 0x4d, 0x4d, 0x4d, 0x4d,
-0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x2d, 0x4d, 0x2d, 0x79, 0x79, 0x79, 0x79, 0x79, 0x79, 0x2e, 0x4d, 0x4d, 0x2e, 0x64,
-0x64, 0x2e, 0x79, 0x79, 0x79, 0x79, 0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x2e, 0x2c, 0x20, 0x64, 0x64, 0x64,
-0x64, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x20, 0x27,
-0x436, 0x27, 0x2e, 0x79, 0x79, 0x2e, 0x20, 0x4d, 0x2e, 0x20, 0x64, 0x2e, 0x79, 0x79, 0x79, 0x79, 0xb144, 0x20, 0x4d, 0xc6d4,
-0x20, 0x64, 0xc77c, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0xe97, 0xeb5, 0x20, 0x64, 0x20, 0x4d, 0x4d, 0x4d,
-0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x79, 0x79, 0x79, 0x79, 0x2e, 0x20, 0x27, 0x67,
-0x61, 0x64, 0x61, 0x27, 0x20, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x79, 0x79, 0x79, 0x79, 0x20, 0x27, 0x6d, 0x27,
-0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x20, 0x27, 0x64, 0x27, 0x2e, 0x2c, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64,
-0x64, 0x2e, 0x4d, 0x2e, 0x79, 0x79, 0x79, 0x79, 0x79, 0x79, 0x2c, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x2c, 0x20,
-0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x20, 0x27, 0x74, 0x61, 0x27, 0x2019, 0x20, 0x4d, 0x4d,
-0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x20, 0x62f, 0x20, 0x79, 0x79, 0x79, 0x79, 0x20, 0x62f,
+0x79, 0x79, 0x79, 0x2f, 0x4d, 0x2f, 0x64, 0x64, 0x64, 0x2e, 0x4d, 0x4d, 0x2e, 0x79, 0x79, 0x64, 0x20, 0x4d, 0x4d, 0x4d,
+0x4d, 0x2c, 0x20, 0x79, 0x79, 0x79, 0x79, 0x20, 0x569, 0x2e, 0x2c, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2d, 0x4d, 0x2d,
+0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x2c, 0x20, 0x79, 0x79,
+0x79, 0x79, 0x79, 0x79, 0x2f, 0x4d, 0x4d, 0x2f, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x2c, 0x20, 0x4d,
+0x4d, 0x4d, 0x4d, 0x2c, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x79, 0x79, 0x79, 0x79, 0x20,
+0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x64, 0x64, 0x2f, 0x4d, 0x2f, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0xf66,
+0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf63, 0xf7c, 0xf0b, 0x79, 0x79, 0x79, 0x79, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0xf5a, 0xf7a, 0xf66,
+0xf0b, 0x64, 0x64, 0x79, 0x79, 0x79, 0x79, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x2c, 0x20, 0x64, 0x64, 0x64, 0x64,
+0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x2c, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2e,
+0x4d, 0x2e, 0x79, 0x79, 0x64, 0x2f, 0x4d, 0x2f, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x20, 0x64, 0x20, 0x4d,
+0x4d, 0x4d, 0x4d, 0x20, 0x27, 0x64, 0x65, 0x27, 0x20, 0x79, 0x79, 0x79, 0x79, 0x79, 0x79, 0x2d, 0x4d, 0x2d, 0x64, 0x79,
+0x79, 0x79, 0x79, 0x5e74, 0x4d, 0x6708, 0x64, 0x65e5, 0x64, 0x64, 0x64, 0x64, 0x79, 0x79, 0x5e74, 0x4d, 0x6708, 0x64, 0x65e5, 0x79,
+0x79, 0x79, 0x79, 0x5e74, 0x4d, 0x4d, 0x6708, 0x64, 0x64, 0x65e5, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2e, 0x4d, 0x2e, 0x79, 0x79,
+0x79, 0x79, 0x2e, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79,
+0x79, 0x2e, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79,
+0x64, 0x64, 0x64, 0x64, 0x20, 0x27, 0x64, 0x65, 0x6e, 0x27, 0x20, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79,
+0x79, 0x79, 0x79, 0x64, 0x64, 0x2d, 0x4d, 0x4d, 0x2d, 0x79, 0x79, 0x64, 0x2f, 0x4d, 0x4d, 0x2f, 0x79, 0x79, 0x4d, 0x2f,
+0x64, 0x2f, 0x79, 0x79, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x79, 0x79, 0x79, 0x79,
+0x2f, 0x4d, 0x4d, 0x2f, 0x64, 0x64, 0x64, 0x2e, 0x4d, 0x2e, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x20, 0x64,
+0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x64, 0x20,
+0x4d, 0x4d, 0x4d, 0x4d, 0x2c, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x64, 0x2e, 0x20,
+0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x2d, 0x4d, 0x4d, 0x2d, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64,
+0x2c, 0x20, 0x64, 0x20, 0x5d1, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x2d, 0x4d, 0x2d, 0x79, 0x79,
+0x79, 0x79, 0x79, 0x79, 0x2e, 0x4d, 0x4d, 0x2e, 0x64, 0x64, 0x2e, 0x79, 0x79, 0x79, 0x79, 0x2e, 0x20, 0x4d, 0x4d, 0x4d,
+0x4d, 0x20, 0x64, 0x2e, 0x2c, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x20, 0x4d, 0x4d,
+0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x20, 0x27, 0x436, 0x27, 0x2e, 0x79, 0x79, 0x2e, 0x20, 0x4d, 0x2e, 0x20, 0x64,
+0x2e, 0x79, 0x79, 0x79, 0x79, 0xb144, 0x20, 0x4d, 0xc6d4, 0x20, 0x64, 0xc77c, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64,
+0x64, 0xe97, 0xeb5, 0x20, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c,
+0x20, 0x79, 0x79, 0x79, 0x79, 0x2e, 0x20, 0x27, 0x67, 0x61, 0x64, 0x61, 0x27, 0x20, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x4d,
+0x4d, 0x79, 0x79, 0x79, 0x79, 0x20, 0x27, 0x6d, 0x27, 0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x20, 0x27, 0x64,
+0x27, 0x2e, 0x2c, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2e, 0x4d, 0x2e, 0x79, 0x79, 0x79, 0x79, 0x79, 0x79, 0x2c,
+0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x2c, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64,
+0x20, 0x27, 0x74, 0x61, 0x27, 0x2019, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64,
+0x2c, 0x20, 0x79, 0x79, 0x79, 0x79, 0x20, 0x27, 0x43e, 0x43d, 0x44b, 0x27, 0x20, 0x4d, 0x4d, 0x4d, 0x20, 0x27, 0x441, 0x430,
+0x440, 0x44b, 0x43d, 0x27, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x20, 0x62f, 0x20, 0x79, 0x79, 0x79, 0x79, 0x20, 0x62f,
0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x64, 0x64, 0x2e, 0x4d, 0x4d, 0x2e, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64,
0x64, 0x2c, 0x20, 0x64, 0x20, 0x27, 0x64, 0x65, 0x27, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x27, 0x64, 0x65, 0x27, 0x20,
0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x27, 0x69, 0x6c, 0x73, 0x27, 0x20, 0x64, 0x20, 0x27, 0x64,
@@ -1362,67 +1613,67 @@ static const ushort date_format_data[] = {
0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x20, 0x27, 0x433, 0x27, 0x2e, 0x64, 0x2e, 0x4d, 0x2e, 0x79, 0x79,
0x2e, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79,
0x2e, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x2c, 0x20, 0x79, 0x79, 0x79, 0x79, 0x20,
-0x27, 0x430, 0x437, 0x27, 0x79, 0x79, 0x79, 0x79, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x2c, 0x20, 0x64, 0x64, 0x64,
-0x64, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x2e, 0x20, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x20, 0x64, 0x64, 0x20, 0x27, 0x64,
-0x65, 0x27, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x27, 0x64, 0x65, 0x27, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64,
-0x64, 0x27, 0x65, 0x6e, 0x27, 0x20, 0x27, 0x64, 0x65, 0x6e, 0x27, 0x20, 0x64, 0x3a, 0x27, 0x65, 0x27, 0x20, 0x4d, 0x4d,
-0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0xe17, 0xe35, 0xe48, 0x20, 0x64, 0x20, 0x4d, 0x4d, 0x4d,
-0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x1363, 0x20, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20,
-0x1218, 0x12d3, 0x120d, 0x1272, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x1361, 0x20, 0x64, 0x64, 0x20, 0x4d, 0x4d,
-0x4d, 0x4d, 0x20, 0x1218, 0x12d3, 0x120d, 0x1272, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x2e, 0x4d, 0x4d, 0x2e, 0x79, 0x79, 0x79,
-0x79, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64,
-0x64, 0x2c, 0x20, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x20, 0x27, 0x440, 0x27, 0x2e, 0x79,
-0x79, 0x79, 0x79, 0x20, 0x646, 0x686, 0x6cc, 0x20, 0x6cc, 0x6cc, 0x644, 0x20, 0x64, 0x20, 0x646, 0x686, 0x6cc, 0x20, 0x4d, 0x4d,
-0x4d, 0x4d, 0x20, 0x64, 0x64, 0x64, 0x64, 0x20, 0x6a9, 0x648, 0x646, 0x6cc, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x27, 0x6e,
-0x67, 0xe0, 0x79, 0x27, 0x20, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x27, 0x6e, 0x103, 0x6d, 0x27, 0x20, 0x79,
-0x79, 0x79, 0x79, 0x64, 0x64, 0x2e, 0x4d, 0x4d, 0x2e, 0x79, 0x79, 0x2e, 0x64, 0x64, 0x64, 0x64, 0x1361, 0x20, 0x64, 0x64,
-0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x130d, 0x122d, 0x130b, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x1361, 0x20,
-0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x12ee, 0x121d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x20,
-0x64, 0x20, 0x27, 0x64, 0x69, 0x27, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x27, 0x64, 0x61, 0x6c, 0x27, 0x20, 0x79, 0x79,
-0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x20, 0x27, 0x6c, 0x69, 0x61, 0x27,
-0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x1365, 0x20, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x130b,
-0x120b, 0x1233, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x64,
-0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x20, 0x27, 0x64, 0x69, 0x27, 0x20, 0x4d, 0x4d,
-0x4d, 0x4d, 0x20, 0x27, 0x64, 0x69, 0x27, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x2e, 0x20, 0x4d, 0x2e, 0x20, 0x79, 0x79,
-0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x27, 0x64, 0xe4, 0x27, 0x20, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d,
-0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x2f, 0x4d, 0x4d, 0x2f, 0x79, 0x79, 0x79, 0x79, 0x79, 0x79, 0x2f, 0x4d, 0x2f, 0x64,
-0x79, 0x79, 0x79, 0x79, 0x20, 0x27, 0x441, 0x44b, 0x43b, 0x27, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x20, 0x27, 0x43a,
-0x4af, 0x43d, 0x44d, 0x27, 0x2c, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x64, 0x20, 0x4d,
-0x4d, 0x4d, 0x4d, 0x20, 0x27, 0x64, 0x65, 0x27, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x2f, 0x4d, 0x4d, 0x20, 0x79,
-0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x20, 0x2c, 0x20, 0x27, 0x6c, 0x79, 0x25b, 0x27, 0x30c, 0x2bc, 0x20, 0x64, 0x20,
-0x27, 0x6e, 0x61, 0x27, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x2c, 0x20, 0x79, 0x79, 0x79, 0x79
+0x27, 0x430, 0x437, 0x27, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x2e, 0x20, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x20, 0x64, 0x64,
+0x20, 0x27, 0x64, 0x65, 0x27, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x27, 0x64, 0x65, 0x27, 0x20, 0x79, 0x79, 0x79, 0x79,
+0x4d, 0x4d, 0x2f, 0x64, 0x64, 0x2f, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x27, 0x65, 0x6e, 0x27, 0x20, 0x27, 0x64, 0x65,
+0x6e, 0x27, 0x20, 0x64, 0x3a, 0x27, 0x65, 0x27, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64,
+0x64, 0x64, 0xe17, 0xe35, 0xe48, 0x20, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64,
+0x64, 0x1363, 0x20, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x1218, 0x12d3, 0x120d, 0x1272, 0x20, 0x79, 0x79, 0x79, 0x79,
+0x64, 0x64, 0x64, 0x64, 0x1361, 0x20, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x1218, 0x12d3, 0x120d, 0x1272, 0x20, 0x79,
+0x79, 0x79, 0x79, 0x64, 0x2e, 0x4d, 0x4d, 0x2e, 0x79, 0x79, 0x79, 0x79, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79,
+0x79, 0x79, 0x79, 0x20, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d,
+0x20, 0x79, 0x79, 0x79, 0x79, 0x20, 0x27, 0x440, 0x27, 0x2e, 0x79, 0x79, 0x79, 0x79, 0x20, 0x646, 0x686, 0x6cc, 0x20, 0x6cc,
+0x6cc, 0x644, 0x20, 0x64, 0x20, 0x646, 0x686, 0x6cc, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x64, 0x64, 0x64, 0x20, 0x6a9,
+0x648, 0x646, 0x6cc, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x27, 0x6e, 0x67, 0xe0, 0x79, 0x27, 0x20, 0x64, 0x64, 0x20, 0x4d,
+0x4d, 0x4d, 0x4d, 0x20, 0x27, 0x6e, 0x103, 0x6d, 0x27, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x2e, 0x4d, 0x4d, 0x2e,
+0x79, 0x79, 0x2e, 0x64, 0x64, 0x64, 0x64, 0x1361, 0x20, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x130d, 0x122d, 0x130b,
+0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x1361, 0x20, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x12ee,
+0x121d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x20, 0x64, 0x20, 0x27, 0x64, 0x69, 0x27, 0x20, 0x4d, 0x4d,
+0x4d, 0x4d, 0x20, 0x27, 0x64, 0x61, 0x6c, 0x27, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x4d,
+0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x20, 0x27, 0x6c, 0x69, 0x61, 0x27, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64,
+0x1365, 0x20, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x130b, 0x120b, 0x1233, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64,
+0x64, 0x64, 0x2c, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x64, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64,
+0x2c, 0x20, 0x64, 0x20, 0x27, 0x64, 0x69, 0x27, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x27, 0x64, 0x69, 0x27, 0x20, 0x79,
+0x79, 0x79, 0x79, 0x64, 0x2e, 0x20, 0x4d, 0x2e, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x27,
+0x64, 0xe4, 0x27, 0x20, 0x64, 0x2e, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x2f, 0x4d, 0x4d,
+0x2f, 0x79, 0x79, 0x79, 0x79, 0x79, 0x79, 0x2f, 0x4d, 0x2f, 0x64, 0x79, 0x79, 0x79, 0x79, 0x20, 0x27, 0x441, 0x44b, 0x43b,
+0x27, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x64, 0x20, 0x27, 0x43a, 0x4af, 0x43d, 0x44d, 0x27, 0x2c, 0x20, 0x64, 0x64, 0x64,
+0x64, 0x64, 0x64, 0x64, 0x64, 0x2c, 0x20, 0x64, 0x64, 0x20, 0x4d, 0x4d, 0x4d, 0x4d, 0x20, 0x27, 0x64, 0x65, 0x27, 0x20,
+0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x2f, 0x4d, 0x4d, 0x20, 0x79, 0x79, 0x79, 0x79, 0x64, 0x64, 0x64, 0x64, 0x20, 0x2c,
+0x20, 0x27, 0x6c, 0x79, 0x25b, 0x27, 0x30c, 0x2bc, 0x20, 0x64, 0x20, 0x27, 0x6e, 0x61, 0x27, 0x20, 0x4d, 0x4d, 0x4d, 0x4d,
+0x2c, 0x20, 0x79, 0x79, 0x79, 0x79
};
static const ushort time_format_data[] = {
0x48, 0x48, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x48, 0x48, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x74, 0x68, 0x3a,
0x6d, 0x6d, 0x20, 0x41, 0x50, 0x68, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x41, 0x50, 0x20, 0x74, 0x48, 0x48, 0x3a,
0x6d, 0x6d, 0x68, 0x2e, 0x6d, 0x6d, 0x2e, 0x41, 0x50, 0x68, 0x2e, 0x6d, 0x6d, 0x2e, 0x73, 0x73, 0x2e, 0x41, 0x50, 0x20,
-0x74, 0x68, 0x2e, 0x6d, 0x6d, 0x2e, 0x20, 0x41, 0x50, 0x68, 0x2e, 0x6d, 0x6d, 0x2e, 0x73, 0x73, 0x20, 0x41, 0x50, 0x20,
-0x74, 0xf46, 0xf74, 0xf0b, 0xf5a, 0xf7c, 0xf51, 0xf0b, 0x20, 0x68, 0x20, 0xf66, 0xf90, 0xf62, 0xf0b, 0xf58, 0xf0b, 0x20, 0x6d, 0x6d,
-0x20, 0x41, 0x50, 0xf46, 0xf74, 0xf0b, 0xf5a, 0xf7c, 0xf51, 0xf0b, 0x20, 0x68, 0x20, 0xf66, 0xf90, 0xf62, 0xf0b, 0xf58, 0xf0b, 0x20,
-0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x41, 0x50, 0x20, 0x74, 0x48, 0x48, 0x2e, 0x6d, 0x6d, 0x48, 0x48, 0x2e, 0x6d, 0x6d,
-0x2e, 0x73, 0x73, 0x20, 0x74, 0x48, 0x2e, 0x6d, 0x6d, 0x48, 0x2e, 0x6d, 0x6d, 0x2e, 0x73, 0x73, 0x20, 0x74, 0x41, 0x50,
-0x68, 0x3a, 0x6d, 0x6d, 0x74, 0x41, 0x50, 0x68, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x41, 0x50, 0x68, 0x68, 0x3a, 0x6d,
-0x6d, 0x41, 0x50, 0x68, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x5b, 0x74, 0x5d, 0x74, 0x41, 0x50, 0x68, 0x6642, 0x6d,
-0x6d, 0x5206, 0x73, 0x73, 0x79d2, 0x48, 0x3a, 0x6d, 0x6d, 0x48, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x74, 0x48, 0x48,
-0x20, 0x27, 0x68, 0x27, 0x20, 0x6d, 0x6d, 0x20, 0x27, 0x6d, 0x69, 0x6e, 0x27, 0x20, 0x73, 0x73, 0x20, 0x27, 0x73, 0x27,
-0x20, 0x74, 0x48, 0x3a, 0x6d, 0x6d, 0x2e, 0x73, 0x73, 0x20, 0x74, 0x48, 0x20, 0x27, 0x68, 0x27, 0x20, 0x6d, 0x6d, 0x20,
-0x27, 0x6d, 0x69, 0x6e, 0x27, 0x20, 0x73, 0x73, 0x20, 0x27, 0x73, 0x27, 0x20, 0x74, 0x48, 0x48, 0x2e, 0x6d, 0x6d, 0x3a,
-0x73, 0x73, 0x20, 0x27, 0x68, 0x27, 0x20, 0x74, 0x68, 0x68, 0x3a, 0x6d, 0x6d, 0x20, 0x41, 0x50, 0x68, 0x68, 0x3a, 0x6d,
-0x6d, 0x3a, 0x73, 0x73, 0x20, 0x41, 0x50, 0x20, 0x74, 0x48, 0x6642, 0x6d, 0x6d, 0x5206, 0x73, 0x73, 0x79d2, 0x20, 0x74, 0x41,
-0x50, 0x20, 0x68, 0x3a, 0x6d, 0x6d, 0x41, 0x50, 0x20, 0x68, 0xc2dc, 0x20, 0x6d, 0xbd84, 0x20, 0x73, 0xcd08, 0x20, 0x74, 0x48,
-0x20, 0xec2, 0xea1, 0xe87, 0x20, 0x6d, 0x20, 0xe99, 0xeb2, 0xe97, 0xeb5, 0x20, 0x73, 0x73, 0x20, 0xea7, 0xeb4, 0xe99, 0xeb2, 0xe97,
-0xeb5, 0x20, 0x74, 0x68, 0x2d, 0x6d, 0x6d, 0x20, 0x41, 0x50, 0x68, 0x2d, 0x6d, 0x6d, 0x2d, 0x73, 0x73, 0x20, 0x41, 0x50,
-0x20, 0x74, 0x27, 0x6b, 0x6c, 0x27, 0x2e, 0x20, 0x48, 0x48, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x74, 0x48, 0x3a,
-0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x28, 0x74, 0x29, 0x48, 0x48, 0x20, 0x27, 0x447, 0x430, 0x441, 0x43e, 0x432, 0x430, 0x27,
-0x2c, 0x20, 0x6d, 0x6d, 0x20, 0x27, 0x43c, 0x438, 0x43d, 0x443, 0x442, 0x430, 0x27, 0x2c, 0x20, 0x73, 0x73, 0x20, 0x27, 0x441,
-0x435, 0x43a, 0x443, 0x43d, 0x434, 0x438, 0x27, 0x20, 0x74, 0x41, 0x50, 0x20, 0x68, 0x2e, 0x6d, 0x6d, 0x41, 0x50, 0x20, 0x48,
-0x48, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x74, 0x48, 0x48, 0x27, 0x68, 0x27, 0x27, 0x27, 0x6d, 0x6d, 0x3a, 0x73,
-0x73, 0x20, 0x74, 0x48, 0x48, 0x27, 0x48, 0x27, 0x6d, 0x6d, 0x27, 0x27, 0x73, 0x73, 0x27, 0x27, 0x20, 0x74, 0x48, 0x20,
-0xe19, 0xe32, 0xe2c, 0xe34, 0xe01, 0xe32, 0x20, 0x6d, 0x6d, 0x20, 0xe19, 0xe32, 0xe17, 0xe35, 0x20, 0x73, 0x73, 0x20, 0xe27, 0xe34,
-0xe19, 0xe32, 0xe17, 0xe35, 0x20, 0x74, 0x41, 0x50, 0x20, 0x27, 0x67, 0x61, 0x27, 0x20, 0x68, 0x3a, 0x6d, 0x6d, 0x41, 0x50,
-0x20, 0x68, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x74, 0x74, 0x20, 0x68, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20,
-0x41, 0x50
+0x74, 0x48, 0x3a, 0x6d, 0x6d, 0x48, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x2c, 0x20, 0x74, 0x68, 0x2e, 0x6d, 0x6d, 0x2e,
+0x20, 0x41, 0x50, 0x68, 0x2e, 0x6d, 0x6d, 0x2e, 0x73, 0x73, 0x20, 0x41, 0x50, 0x20, 0x74, 0xf46, 0xf74, 0xf0b, 0xf5a, 0xf7c,
+0xf51, 0xf0b, 0x20, 0x68, 0x20, 0xf66, 0xf90, 0xf62, 0xf0b, 0xf58, 0xf0b, 0x20, 0x6d, 0x6d, 0x20, 0x41, 0x50, 0xf46, 0xf74, 0xf0b,
+0xf5a, 0xf7c, 0xf51, 0xf0b, 0x20, 0x68, 0x20, 0xf66, 0xf90, 0xf62, 0xf0b, 0xf58, 0xf0b, 0x20, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20,
+0x41, 0x50, 0x20, 0x74, 0x48, 0x48, 0x2e, 0x6d, 0x6d, 0x48, 0x48, 0x2e, 0x6d, 0x6d, 0x2e, 0x73, 0x73, 0x20, 0x74, 0x48,
+0x2e, 0x6d, 0x6d, 0x48, 0x2e, 0x6d, 0x6d, 0x2e, 0x73, 0x73, 0x20, 0x74, 0x41, 0x50, 0x68, 0x3a, 0x6d, 0x6d, 0x74, 0x41,
+0x50, 0x68, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x41, 0x50, 0x68, 0x68, 0x3a, 0x6d, 0x6d, 0x41, 0x50, 0x68, 0x3a, 0x6d,
+0x6d, 0x3a, 0x73, 0x73, 0x20, 0x5b, 0x74, 0x5d, 0x74, 0x41, 0x50, 0x68, 0x6642, 0x6d, 0x6d, 0x5206, 0x73, 0x73, 0x79d2, 0x48,
+0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x74, 0x48, 0x48, 0x20, 0x27, 0x68, 0x27, 0x20, 0x6d, 0x6d, 0x20, 0x27, 0x6d,
+0x69, 0x6e, 0x27, 0x20, 0x73, 0x73, 0x20, 0x27, 0x73, 0x27, 0x20, 0x74, 0x48, 0x3a, 0x6d, 0x6d, 0x2e, 0x73, 0x73, 0x20,
+0x74, 0x48, 0x20, 0x27, 0x68, 0x27, 0x20, 0x6d, 0x6d, 0x20, 0x27, 0x6d, 0x69, 0x6e, 0x27, 0x20, 0x73, 0x73, 0x20, 0x27,
+0x73, 0x27, 0x20, 0x74, 0x48, 0x48, 0x2e, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x27, 0x68, 0x27, 0x20, 0x74, 0x68, 0x68,
+0x3a, 0x6d, 0x6d, 0x20, 0x41, 0x50, 0x68, 0x68, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x41, 0x50, 0x20, 0x74, 0x48,
+0x6642, 0x6d, 0x6d, 0x5206, 0x73, 0x73, 0x79d2, 0x20, 0x74, 0x41, 0x50, 0x20, 0x68, 0x3a, 0x6d, 0x6d, 0x41, 0x50, 0x20, 0x68,
+0xc2dc, 0x20, 0x6d, 0xbd84, 0x20, 0x73, 0xcd08, 0x20, 0x74, 0x48, 0x20, 0xec2, 0xea1, 0xe87, 0x20, 0x6d, 0x20, 0xe99, 0xeb2, 0xe97,
+0xeb5, 0x20, 0x73, 0x73, 0x20, 0xea7, 0xeb4, 0xe99, 0xeb2, 0xe97, 0xeb5, 0x20, 0x74, 0x68, 0x2d, 0x6d, 0x6d, 0x20, 0x41, 0x50,
+0x68, 0x2d, 0x6d, 0x6d, 0x2d, 0x73, 0x73, 0x20, 0x41, 0x50, 0x20, 0x74, 0x27, 0x6b, 0x6c, 0x27, 0x2e, 0x20, 0x48, 0x48,
+0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x74, 0x48, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x28, 0x74, 0x29, 0x48,
+0x48, 0x20, 0x27, 0x447, 0x430, 0x441, 0x43e, 0x432, 0x430, 0x27, 0x2c, 0x20, 0x6d, 0x6d, 0x20, 0x27, 0x43c, 0x438, 0x43d, 0x443,
+0x442, 0x430, 0x27, 0x2c, 0x20, 0x73, 0x73, 0x20, 0x27, 0x441, 0x435, 0x43a, 0x443, 0x43d, 0x434, 0x438, 0x27, 0x20, 0x74, 0x41,
+0x50, 0x20, 0x68, 0x2e, 0x6d, 0x6d, 0x41, 0x50, 0x20, 0x48, 0x48, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x74, 0x48,
+0x48, 0x27, 0x68, 0x27, 0x27, 0x27, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x74, 0x48, 0x48, 0x27, 0x48, 0x27, 0x6d, 0x6d,
+0x27, 0x27, 0x73, 0x73, 0x27, 0x27, 0x20, 0x74, 0x48, 0x20, 0xe19, 0xe32, 0xe2c, 0xe34, 0xe01, 0xe32, 0x20, 0x6d, 0x6d, 0x20,
+0xe19, 0xe32, 0xe17, 0xe35, 0x20, 0x73, 0x73, 0x20, 0xe27, 0xe34, 0xe19, 0xe32, 0xe17, 0xe35, 0x20, 0x74, 0x41, 0x50, 0x20, 0x27,
+0x67, 0x61, 0x27, 0x20, 0x68, 0x3a, 0x6d, 0x6d, 0x41, 0x50, 0x20, 0x68, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x74,
+0x74, 0x20, 0x68, 0x3a, 0x6d, 0x6d, 0x3a, 0x73, 0x73, 0x20, 0x41, 0x50
};
static const ushort months_data[] = {
@@ -1518,1636 +1769,1662 @@ static const ushort months_data[] = {
0x646, 0x64a, 0x648, 0x3b, 0x64a, 0x648, 0x644, 0x64a, 0x648, 0x3b, 0x63a, 0x634, 0x62a, 0x3b, 0x633, 0x628, 0x62a, 0x645, 0x628, 0x631,
0x3b, 0x623, 0x643, 0x62a, 0x648, 0x628, 0x631, 0x3b, 0x646, 0x648, 0x646, 0x628, 0x631, 0x3b, 0x62f, 0x64a, 0x633, 0x645, 0x628, 0x631,
0x3b, 0x64a, 0x3b, 0x641, 0x3b, 0x645, 0x3b, 0xfe83, 0x3b, 0x645, 0x3b, 0xfee5, 0x3b, 0xfedd, 0x3b, 0x63a, 0x3b, 0x634, 0x3b, 0xfed9,
-0x3b, 0xfe8f, 0x3b, 0xfea9, 0x3b, 0x540, 0x576, 0x57e, 0x3b, 0x553, 0x57f, 0x57e, 0x3b, 0x544, 0x580, 0x57f, 0x3b, 0x531, 0x57a, 0x580,
-0x3b, 0x544, 0x575, 0x57d, 0x3b, 0x540, 0x576, 0x57d, 0x3b, 0x540, 0x56c, 0x57d, 0x3b, 0x555, 0x563, 0x57d, 0x3b, 0x54d, 0x565, 0x57a,
-0x3b, 0x540, 0x578, 0x56f, 0x3b, 0x546, 0x578, 0x575, 0x3b, 0x534, 0x565, 0x56f, 0x3b, 0x540, 0x578, 0x582, 0x576, 0x57e, 0x561, 0x580,
-0x3b, 0x553, 0x565, 0x57f, 0x580, 0x57e, 0x561, 0x580, 0x3b, 0x544, 0x561, 0x580, 0x57f, 0x3b, 0x531, 0x57a, 0x580, 0x56b, 0x56c, 0x3b,
-0x544, 0x561, 0x575, 0x56b, 0x57d, 0x3b, 0x540, 0x578, 0x582, 0x576, 0x56b, 0x57d, 0x3b, 0x540, 0x578, 0x582, 0x56c, 0x56b, 0x57d, 0x3b,
-0x555, 0x563, 0x578, 0x57d, 0x57f, 0x578, 0x57d, 0x3b, 0x54d, 0x565, 0x57a, 0x57f, 0x565, 0x574, 0x562, 0x565, 0x580, 0x3b, 0x540, 0x578,
-0x56f, 0x57f, 0x565, 0x574, 0x562, 0x565, 0x580, 0x3b, 0x546, 0x578, 0x575, 0x565, 0x574, 0x562, 0x565, 0x580, 0x3b, 0x534, 0x565, 0x56f,
-0x57f, 0x565, 0x574, 0x562, 0x565, 0x580, 0x3b, 0x99c, 0x9be, 0x9a8, 0x9c1, 0x3b, 0x9ab, 0x9c7, 0x9ac, 0x9cd, 0x9f0, 0x9c1, 0x3b, 0x9ae,
-0x9be, 0x9f0, 0x9cd, 0x99a, 0x3b, 0x98f, 0x9aa, 0x9cd, 0x9f0, 0x9bf, 0x9b2, 0x3b, 0x9ae, 0x9c7, 0x3b, 0x99c, 0x9c1, 0x9a8, 0x3b, 0x99c,
-0x9c1, 0x9b2, 0x9be, 0x987, 0x3b, 0x986, 0x997, 0x3b, 0x9b8, 0x9c7, 0x9aa, 0x9cd, 0x99f, 0x3b, 0x985, 0x995, 0x9cd, 0x99f, 0x9cb, 0x3b,
-0x9a8, 0x9ad, 0x9c7, 0x3b, 0x9a1, 0x9bf, 0x9b8, 0x9c7, 0x3b, 0x99c, 0x9be, 0x9a8, 0x9c1, 0x9f1, 0x9be, 0x9f0, 0x9c0, 0x3b, 0x9ab, 0x9c7,
-0x9ac, 0x9cd, 0x9f0, 0x9c1, 0x9f1, 0x9be, 0x9f0, 0x9c0, 0x3b, 0x9ae, 0x9be, 0x9f0, 0x9cd, 0x99a, 0x3b, 0x98f, 0x9aa, 0x9cd, 0x9f0, 0x9bf,
-0x9b2, 0x3b, 0x9ae, 0x9c7, 0x3b, 0x99c, 0x9c1, 0x9a8, 0x3b, 0x99c, 0x9c1, 0x9b2, 0x9be, 0x987, 0x3b, 0x986, 0x997, 0x9b7, 0x9cd, 0x99f,
-0x3b, 0x99b, 0x9c7, 0x9aa, 0x9cd, 0x9a4, 0x9c7, 0x9ae, 0x9cd, 0x9ac, 0x9f0, 0x3b, 0x985, 0x995, 0x9cd, 0x99f, 0x9cb, 0x9ac, 0x9f0, 0x3b,
-0x9a8, 0x9f1, 0x9c7, 0x9ae, 0x9cd, 0x9ac, 0x9f0, 0x3b, 0x9a1, 0x9bf, 0x99a, 0x9c7, 0x9ae, 0x9cd, 0x9ac, 0x9f0, 0x3b, 0x79, 0x61, 0x6e,
-0x3b, 0x66, 0x65, 0x76, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x61, 0x79, 0x3b, 0x69, 0x79, 0x6e,
-0x3b, 0x69, 0x79, 0x6c, 0x3b, 0x61, 0x76, 0x71, 0x3b, 0x73, 0x65, 0x6e, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0x6f, 0x79,
-0x3b, 0x64, 0x65, 0x6b, 0x3b, 0x59, 0x61, 0x6e, 0x76, 0x61, 0x72, 0x3b, 0x46, 0x65, 0x76, 0x72, 0x61, 0x6c, 0x3b, 0x4d,
-0x61, 0x72, 0x74, 0x3b, 0x41, 0x70, 0x72, 0x65, 0x6c, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x130, 0x79, 0x75, 0x6e, 0x3b, 0x130,
-0x79, 0x75, 0x6c, 0x3b, 0x41, 0x76, 0x71, 0x75, 0x73, 0x74, 0x3b, 0x53, 0x65, 0x6e, 0x74, 0x79, 0x61, 0x62, 0x72, 0x3b,
-0x4f, 0x6b, 0x74, 0x79, 0x61, 0x62, 0x72, 0x3b, 0x4e, 0x6f, 0x79, 0x61, 0x62, 0x72, 0x3b, 0x44, 0x65, 0x6b, 0x61, 0x62,
-0x72, 0x3b, 0x458, 0x430, 0x43d, 0x432, 0x430, 0x440, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x430, 0x43b, 0x3b, 0x43c, 0x430, 0x440, 0x442,
-0x3b, 0x430, 0x43f, 0x440, 0x435, 0x43b, 0x3b, 0x43c, 0x430, 0x439, 0x3b, 0x438, 0x458, 0x443, 0x43d, 0x3b, 0x438, 0x458, 0x443, 0x43b,
-0x3b, 0x430, 0x432, 0x433, 0x443, 0x441, 0x442, 0x3b, 0x441, 0x435, 0x43d, 0x442, 0x458, 0x430, 0x431, 0x440, 0x3b, 0x43e, 0x43a, 0x442,
-0x458, 0x430, 0x431, 0x440, 0x3b, 0x43d, 0x43e, 0x458, 0x430, 0x431, 0x440, 0x3b, 0x434, 0x435, 0x43a, 0x430, 0x431, 0x440, 0x3b, 0x75,
-0x72, 0x74, 0x3b, 0x6f, 0x74, 0x73, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x69, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x65,
-0x6b, 0x61, 0x3b, 0x75, 0x7a, 0x74, 0x3b, 0x61, 0x62, 0x75, 0x3b, 0x69, 0x72, 0x61, 0x3b, 0x75, 0x72, 0x72, 0x3b, 0x61,
-0x7a, 0x61, 0x3b, 0x61, 0x62, 0x65, 0x3b, 0x75, 0x72, 0x74, 0x61, 0x72, 0x72, 0x69, 0x6c, 0x61, 0x3b, 0x6f, 0x74, 0x73,
-0x61, 0x69, 0x6c, 0x61, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x78, 0x6f, 0x61, 0x3b, 0x61, 0x70, 0x69, 0x72, 0x69, 0x6c, 0x61,
-0x3b, 0x6d, 0x61, 0x69, 0x61, 0x74, 0x7a, 0x61, 0x3b, 0x65, 0x6b, 0x61, 0x69, 0x6e, 0x61, 0x3b, 0x75, 0x7a, 0x74, 0x61,
-0x69, 0x6c, 0x61, 0x3b, 0x61, 0x62, 0x75, 0x7a, 0x74, 0x75, 0x61, 0x3b, 0x69, 0x72, 0x61, 0x69, 0x6c, 0x61, 0x3b, 0x75,
-0x72, 0x72, 0x69, 0x61, 0x3b, 0x61, 0x7a, 0x61, 0x72, 0x6f, 0x61, 0x3b, 0x61, 0x62, 0x65, 0x6e, 0x64, 0x75, 0x61, 0x3b,
-0x55, 0x3b, 0x4f, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x45, 0x3b, 0x55, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x55, 0x3b,
-0x41, 0x3b, 0x41, 0x3b, 0x99c, 0x9be, 0x9a8, 0x9c1, 0x9af, 0x9bc, 0x9be, 0x9b0, 0x9c0, 0x3b, 0x9ab, 0x9c7, 0x9ac, 0x9cd, 0x9b0, 0x9c1,
-0x9af, 0x9bc, 0x9be, 0x9b0, 0x9c0, 0x3b, 0x9ae, 0x9be, 0x9b0, 0x9cd, 0x99a, 0x3b, 0x98f, 0x9aa, 0x9cd, 0x9b0, 0x9bf, 0x9b2, 0x3b, 0x9ae,
-0x9c7, 0x3b, 0x99c, 0x9c1, 0x9a8, 0x3b, 0x99c, 0x9c1, 0x9b2, 0x9be, 0x987, 0x3b, 0x986, 0x997, 0x9b8, 0x9cd, 0x99f, 0x3b, 0x9b8, 0x9c7,
-0x9aa, 0x9cd, 0x99f, 0x9c7, 0x9ae, 0x9cd, 0x9ac, 0x9b0, 0x3b, 0x985, 0x995, 0x9cd, 0x99f, 0x9cb, 0x9ac, 0x9b0, 0x3b, 0x9a8, 0x9ad, 0x9c7,
-0x9ae, 0x9cd, 0x9ac, 0x9b0, 0x3b, 0x9a1, 0x9bf, 0x9b8, 0x9c7, 0x9ae, 0x9cd, 0x9ac, 0x9b0, 0x3b, 0x99c, 0x9be, 0x3b, 0x9ab, 0x9c7, 0x3b,
-0x9ae, 0x9be, 0x3b, 0x98f, 0x3b, 0x9ae, 0x9c7, 0x3b, 0x99c, 0x9c1, 0x9a8, 0x3b, 0x99c, 0x9c1, 0x3b, 0x986, 0x3b, 0x9b8, 0x9c7, 0x3b,
-0x985, 0x3b, 0x9a8, 0x3b, 0x9a1, 0x9bf, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf21, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf22, 0x3b, 0xf5f, 0xfb3, 0xf0b,
-0xf23, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf24, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf25, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf26, 0x3b, 0xf5f, 0xfb3, 0xf0b,
-0xf27, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf28, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf29, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf21, 0xf20, 0x3b, 0xf5f, 0xfb3,
-0xf0b, 0xf21, 0xf21, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf21, 0xf22, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf51, 0xf44,
-0xf54, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf42, 0xf49, 0xf72, 0xf66, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf66,
-0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf42, 0xf66, 0xf74, 0xf58, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b,
-0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf5e, 0xf72, 0xf0b, 0xf54, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf63, 0xf94, 0xf0b,
-0xf54, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf51, 0xfb2, 0xf74, 0xf42, 0xf0b, 0xf54, 0x3b, 0xf66, 0xfa4,
-0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf51, 0xf74, 0xf53, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f,
-0xfb3, 0xf0b, 0xf56, 0xf62, 0xf92, 0xfb1, 0xf51, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf51,
-0xf42, 0xf74, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf54, 0xf0b,
-0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf42, 0xf45, 0xf72, 0xf42, 0xf0b, 0xf54, 0xf0b,
-0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf42, 0xf49, 0xf72, 0xf66, 0xf0b, 0xf54, 0xf0b,
-0x3b, 0xf21, 0x3b, 0xf22, 0x3b, 0xf23, 0x3b, 0xf24, 0x3b, 0xf25, 0x3b, 0xf26, 0x3b, 0xf27, 0x3b, 0xf28, 0x3b, 0xf29, 0x3b, 0xf21,
-0xf20, 0x3b, 0xf21, 0xf21, 0x3b, 0xf21, 0xf22, 0x3b, 0xf21, 0x3b, 0xf22, 0x3b, 0xf23, 0x3b, 0xf24, 0x3b, 0xf25, 0x3b, 0xf26, 0x3b,
-0xf27, 0x3b, 0xf28, 0x3b, 0xf29, 0x3b, 0xf21, 0xf20, 0x3b, 0xf21, 0xf21, 0x3b, 0x31, 0x32, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf51, 0xf44,
-0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf42, 0xf49, 0xf72, 0xf66, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf42, 0xf66, 0xf74,
-0xf58, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf5e, 0xf72, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf63, 0xf94,
-0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf51, 0xfb2, 0xf74, 0xf42, 0xf0b, 0xf54, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf51, 0xf74,
-0xf53, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf62, 0xf92, 0xfb1, 0xf51, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b,
-0xf51, 0xf42, 0xf74, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b,
-0xf56, 0xf45, 0xf74, 0xf0b, 0xf42, 0xf45, 0xf72, 0xf42, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf42,
-0xf49, 0xf72, 0xf66, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf21, 0x3b, 0xf22, 0x3b, 0xf23, 0x3b, 0x34, 0x3b, 0xf25, 0x3b, 0xf26, 0x3b, 0xf27,
-0x3b, 0xf28, 0x3b, 0x39, 0x3b, 0xf21, 0xf20, 0x3b, 0xf21, 0xf21, 0x3b, 0xf21, 0xf22, 0x3b, 0x47, 0x65, 0x6e, 0x3b, 0x43, 0x2bc,
-0x68, 0x77, 0x65, 0x3b, 0x4d, 0x65, 0x75, 0x72, 0x3b, 0x45, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x65, 0x3b, 0x4d, 0x65, 0x7a,
-0x68, 0x3b, 0x47, 0x6f, 0x75, 0x65, 0x3b, 0x45, 0x6f, 0x73, 0x74, 0x3b, 0x47, 0x77, 0x65, 0x6e, 0x3b, 0x48, 0x65, 0x72,
-0x65, 0x3b, 0x44, 0x75, 0x3b, 0x4b, 0x65, 0x72, 0x3b, 0x47, 0x65, 0x6e, 0x76, 0x65, 0x72, 0x3b, 0x43, 0x2bc, 0x68, 0x77,
-0x65, 0x76, 0x72, 0x65, 0x72, 0x3b, 0x4d, 0x65, 0x75, 0x72, 0x7a, 0x68, 0x3b, 0x45, 0x62, 0x72, 0x65, 0x6c, 0x3b, 0x4d,
-0x61, 0x65, 0x3b, 0x4d, 0x65, 0x7a, 0x68, 0x65, 0x76, 0x65, 0x6e, 0x3b, 0x47, 0x6f, 0x75, 0x65, 0x72, 0x65, 0x3b, 0x45,
-0x6f, 0x73, 0x74, 0x3b, 0x47, 0x77, 0x65, 0x6e, 0x67, 0x6f, 0x6c, 0x6f, 0x3b, 0x48, 0x65, 0x72, 0x65, 0x3b, 0x44, 0x75,
-0x3b, 0x4b, 0x65, 0x72, 0x7a, 0x75, 0x3b, 0x44f, 0x43d, 0x2e, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x440,
-0x442, 0x3b, 0x430, 0x43f, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x439, 0x3b, 0x44e, 0x43d, 0x438, 0x3b, 0x44e, 0x43b, 0x438, 0x3b, 0x430,
-0x432, 0x433, 0x2e, 0x3b, 0x441, 0x435, 0x43f, 0x442, 0x2e, 0x3b, 0x43e, 0x43a, 0x442, 0x2e, 0x3b, 0x43d, 0x43e, 0x435, 0x43c, 0x2e,
-0x3b, 0x434, 0x435, 0x43a, 0x2e, 0x3b, 0x44f, 0x43d, 0x443, 0x430, 0x440, 0x438, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x443, 0x430, 0x440,
-0x438, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x3b, 0x430, 0x43f, 0x440, 0x438, 0x43b, 0x3b, 0x43c, 0x430, 0x439, 0x3b, 0x44e, 0x43d, 0x438,
-0x3b, 0x44e, 0x43b, 0x438, 0x3b, 0x430, 0x432, 0x433, 0x443, 0x441, 0x442, 0x3b, 0x441, 0x435, 0x43f, 0x442, 0x435, 0x43c, 0x432, 0x440,
-0x438, 0x3b, 0x43e, 0x43a, 0x442, 0x43e, 0x43c, 0x432, 0x440, 0x438, 0x3b, 0x43d, 0x43e, 0x435, 0x43c, 0x432, 0x440, 0x438, 0x3b, 0x434,
-0x435, 0x43a, 0x435, 0x43c, 0x432, 0x440, 0x438, 0x3b, 0x44f, 0x3b, 0x444, 0x3b, 0x43c, 0x3b, 0x430, 0x3b, 0x43c, 0x3b, 0x44e, 0x3b,
-0x44e, 0x3b, 0x430, 0x3b, 0x441, 0x3b, 0x43e, 0x3b, 0x43d, 0x3b, 0x434, 0x3b, 0x1007, 0x1014, 0x103a, 0x3b, 0x1016, 0x1031, 0x3b, 0x1019,
-0x1010, 0x103a, 0x3b, 0x1027, 0x3b, 0x1019, 0x1031, 0x3b, 0x1007, 0x103d, 0x1014, 0x103a, 0x3b, 0x1007, 0x1030, 0x3b, 0x1029, 0x3b, 0x1005, 0x1000,
-0x103a, 0x3b, 0x1021, 0x1031, 0x102c, 0x1000, 0x103a, 0x3b, 0x1014, 0x102d, 0x102f, 0x3b, 0x1012, 0x102e, 0x3b, 0x1007, 0x1014, 0x103a, 0x1014, 0x101d,
-0x102b, 0x101b, 0x102e, 0x3b, 0x1016, 0x1031, 0x1016, 0x1031, 0x102c, 0x103a, 0x101d, 0x102b, 0x101b, 0x102e, 0x3b, 0x1019, 0x1010, 0x103a, 0x3b, 0x1027,
-0x1015, 0x103c, 0x102e, 0x3b, 0x1019, 0x1031, 0x3b, 0x1007, 0x103d, 0x1014, 0x103a, 0x3b, 0x1007, 0x1030, 0x101c, 0x102d, 0x102f, 0x1004, 0x103a, 0x3b,
-0x1029, 0x1002, 0x102f, 0x1010, 0x103a, 0x3b, 0x1005, 0x1000, 0x103a, 0x1010, 0x1004, 0x103a, 0x1018, 0x102c, 0x3b, 0x1021, 0x1031, 0x102c, 0x1000, 0x103a,
-0x1010, 0x102d, 0x102f, 0x1018, 0x102c, 0x3b, 0x1014, 0x102d, 0x102f, 0x101d, 0x1004, 0x103a, 0x1018, 0x102c, 0x3b, 0x1012, 0x102e, 0x1007, 0x1004, 0x103a,
-0x1018, 0x102c, 0x3b, 0x1007, 0x3b, 0x1016, 0x3b, 0x1019, 0x3b, 0x1027, 0x3b, 0x1019, 0x3b, 0x1007, 0x3b, 0x1007, 0x3b, 0x1029, 0x3b, 0x1005,
-0x3b, 0x1021, 0x3b, 0x1014, 0x3b, 0x1012, 0x3b, 0x441, 0x442, 0x443, 0x3b, 0x43b, 0x44e, 0x442, 0x3b, 0x441, 0x430, 0x43a, 0x3b, 0x43a,
-0x440, 0x430, 0x3b, 0x442, 0x440, 0x430, 0x3b, 0x447, 0x44d, 0x440, 0x3b, 0x43b, 0x456, 0x43f, 0x3b, 0x436, 0x43d, 0x456, 0x3b, 0x432,
-0x435, 0x440, 0x3b, 0x43a, 0x430, 0x441, 0x3b, 0x43b, 0x456, 0x441, 0x3b, 0x441, 0x43d, 0x435, 0x3b, 0x441, 0x442, 0x443, 0x434, 0x437,
-0x435, 0x43d, 0x44c, 0x3b, 0x43b, 0x44e, 0x442, 0x44b, 0x3b, 0x441, 0x430, 0x43a, 0x430, 0x432, 0x456, 0x43a, 0x3b, 0x43a, 0x440, 0x430,
-0x441, 0x430, 0x432, 0x456, 0x43a, 0x3b, 0x442, 0x440, 0x430, 0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x447, 0x44d, 0x440, 0x432, 0x435, 0x43d,
-0x44c, 0x3b, 0x43b, 0x456, 0x43f, 0x435, 0x43d, 0x44c, 0x3b, 0x436, 0x43d, 0x456, 0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x432, 0x435, 0x440,
-0x430, 0x441, 0x435, 0x43d, 0x44c, 0x3b, 0x43a, 0x430, 0x441, 0x442, 0x440, 0x44b, 0x447, 0x43d, 0x456, 0x43a, 0x3b, 0x43b, 0x456, 0x441,
-0x442, 0x430, 0x43f, 0x430, 0x434, 0x3b, 0x441, 0x43d, 0x435, 0x436, 0x430, 0x43d, 0x44c, 0x3b, 0x441, 0x3b, 0x43b, 0x3b, 0x441, 0x3b,
-0x43a, 0x3b, 0x43c, 0x3b, 0x447, 0x3b, 0x43b, 0x3b, 0x436, 0x3b, 0x432, 0x3b, 0x43a, 0x3b, 0x43b, 0x3b, 0x441, 0x3b, 0x441, 0x442,
-0x443, 0x3b, 0x43b, 0x44e, 0x442, 0x3b, 0x441, 0x430, 0x43a, 0x3b, 0x43a, 0x440, 0x430, 0x3b, 0x43c, 0x430, 0x439, 0x3b, 0x447, 0x44d,
-0x440, 0x3b, 0x43b, 0x456, 0x43f, 0x3b, 0x436, 0x43d, 0x456, 0x3b, 0x432, 0x435, 0x440, 0x3b, 0x43a, 0x430, 0x441, 0x3b, 0x43b, 0x456,
-0x441, 0x3b, 0x441, 0x43d, 0x435, 0x3b, 0x441, 0x442, 0x443, 0x434, 0x437, 0x435, 0x43d, 0x44c, 0x3b, 0x43b, 0x44e, 0x442, 0x44b, 0x3b,
-0x441, 0x430, 0x43a, 0x430, 0x432, 0x456, 0x43a, 0x3b, 0x43a, 0x440, 0x430, 0x441, 0x430, 0x432, 0x456, 0x43a, 0x3b, 0x43c, 0x430, 0x439,
-0x3b, 0x447, 0x44d, 0x440, 0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x43b, 0x456, 0x43f, 0x435, 0x43d, 0x44c, 0x3b, 0x436, 0x43d, 0x456, 0x432,
-0x435, 0x43d, 0x44c, 0x3b, 0x432, 0x435, 0x440, 0x430, 0x441, 0x435, 0x43d, 0x44c, 0x3b, 0x43a, 0x430, 0x441, 0x442, 0x440, 0x44b, 0x447,
-0x43d, 0x456, 0x43a, 0x3b, 0x43b, 0x456, 0x441, 0x442, 0x430, 0x43f, 0x430, 0x434, 0x3b, 0x441, 0x43d, 0x435, 0x436, 0x430, 0x43d, 0x44c,
-0x3b, 0x441, 0x3b, 0x43b, 0x3b, 0x441, 0x3b, 0x43a, 0x3b, 0x442, 0x3b, 0x447, 0x3b, 0x43b, 0x3b, 0x436, 0x3b, 0x432, 0x3b, 0x43a,
-0x3b, 0x43b, 0x3b, 0x441, 0x3b, 0x1798, 0x1780, 0x179a, 0x17b6, 0x3b, 0x1780, 0x17bb, 0x1798, 0x17d2, 0x1797, 0x17c8, 0x3b, 0x1798, 0x17b8, 0x1793,
-0x17b6, 0x3b, 0x1798, 0x17c1, 0x179f, 0x17b6, 0x3b, 0x17a7, 0x179f, 0x1797, 0x17b6, 0x3b, 0x1798, 0x17b7, 0x1790, 0x17bb, 0x1793, 0x17b6, 0x3b, 0x1780,
-0x1780, 0x17d2, 0x1780, 0x178a, 0x17b6, 0x3b, 0x179f, 0x17b8, 0x17a0, 0x17b6, 0x3b, 0x1780, 0x1789, 0x17d2, 0x1789, 0x17b6, 0x3b, 0x178f, 0x17bb, 0x179b,
-0x17b6, 0x3b, 0x179c, 0x17b7, 0x1785, 0x17d2, 0x1786, 0x17b7, 0x1780, 0x17b6, 0x3b, 0x1792, 0x17d2, 0x1793, 0x17bc, 0x3b, 0x67, 0x65, 0x6e, 0x2e,
-0x3b, 0x66, 0x65, 0x62, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0xe7, 0x3b, 0x61, 0x62, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x69,
-0x67, 0x3b, 0x6a, 0x75, 0x6e, 0x79, 0x3b, 0x6a, 0x75, 0x6c, 0x2e, 0x3b, 0x61, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x74, 0x2e,
-0x3b, 0x6f, 0x63, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x73, 0x2e, 0x3b, 0x67, 0x65, 0x6e, 0x65,
-0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x65, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0xe7, 0x3b, 0x61, 0x62, 0x72, 0x69, 0x6c, 0x3b,
-0x6d, 0x61, 0x69, 0x67, 0x3b, 0x6a, 0x75, 0x6e, 0x79, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x6f, 0x6c, 0x3b, 0x61, 0x67, 0x6f,
-0x73, 0x74, 0x3b, 0x73, 0x65, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x6f, 0x63, 0x74, 0x75, 0x62, 0x72, 0x65, 0x3b,
-0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x67, 0x3b,
-0x66, 0x3b, 0x6d, 0x3b, 0x61, 0x3b, 0x6d, 0x3b, 0x6a, 0x3b, 0x6a, 0x3b, 0x61, 0x3b, 0x73, 0x3b, 0x6f, 0x3b, 0x6e, 0x3b,
-0x64, 0x3b, 0x64, 0x65, 0x20, 0x67, 0x65, 0x6e, 0x2e, 0x3b, 0x64, 0x65, 0x20, 0x66, 0x65, 0x62, 0x72, 0x2e, 0x3b, 0x64,
-0x65, 0x20, 0x6d, 0x61, 0x72, 0xe7, 0x3b, 0x64, 0x2019, 0x61, 0x62, 0x72, 0x2e, 0x3b, 0x64, 0x65, 0x20, 0x6d, 0x61, 0x69,
-0x67, 0x3b, 0x64, 0x65, 0x20, 0x6a, 0x75, 0x6e, 0x79, 0x3b, 0x64, 0x65, 0x20, 0x6a, 0x75, 0x6c, 0x2e, 0x3b, 0x64, 0x2019,
-0x61, 0x67, 0x2e, 0x3b, 0x64, 0x65, 0x20, 0x73, 0x65, 0x74, 0x2e, 0x3b, 0x64, 0x2019, 0x6f, 0x63, 0x74, 0x2e, 0x3b, 0x64,
-0x65, 0x20, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x20, 0x64, 0x65, 0x73, 0x2e, 0x3b, 0x64, 0x65, 0x20, 0x67, 0x65,
-0x6e, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x20, 0x66, 0x65, 0x62, 0x72, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x20, 0x6d, 0x61, 0x72,
-0xe7, 0x3b, 0x64, 0x2019, 0x61, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x64, 0x65, 0x20, 0x6d, 0x61, 0x69, 0x67, 0x3b, 0x64, 0x65,
-0x20, 0x6a, 0x75, 0x6e, 0x79, 0x3b, 0x64, 0x65, 0x20, 0x6a, 0x75, 0x6c, 0x69, 0x6f, 0x6c, 0x3b, 0x64, 0x2019, 0x61, 0x67,
-0x6f, 0x73, 0x74, 0x3b, 0x64, 0x65, 0x20, 0x73, 0x65, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x2019, 0x6f, 0x63,
-0x74, 0x75, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x65, 0x20, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x65,
-0x20, 0x64, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x47, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b,
-0x4a, 0x3b, 0x4a, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x31, 0x6708, 0x3b, 0x32, 0x6708, 0x3b,
-0x33, 0x6708, 0x3b, 0x34, 0x6708, 0x3b, 0x35, 0x6708, 0x3b, 0x36, 0x6708, 0x3b, 0x37, 0x6708, 0x3b, 0x38, 0x6708, 0x3b, 0x39, 0x6708,
-0x3b, 0x31, 0x30, 0x6708, 0x3b, 0x31, 0x31, 0x6708, 0x3b, 0x31, 0x32, 0x6708, 0x3b, 0x4e00, 0x6708, 0x3b, 0x4e8c, 0x6708, 0x3b, 0x4e09,
-0x6708, 0x3b, 0x56db, 0x6708, 0x3b, 0x4e94, 0x6708, 0x3b, 0x516d, 0x6708, 0x3b, 0x4e03, 0x6708, 0x3b, 0x516b, 0x6708, 0x3b, 0x4e5d, 0x6708, 0x3b,
-0x5341, 0x6708, 0x3b, 0x5341, 0x4e00, 0x6708, 0x3b, 0x5341, 0x4e8c, 0x6708, 0x3b, 0x73, 0x69, 0x6a, 0x3b, 0x76, 0x65, 0x6c, 0x6a, 0x3b,
-0x6f, 0x17e, 0x75, 0x3b, 0x74, 0x72, 0x61, 0x3b, 0x73, 0x76, 0x69, 0x3b, 0x6c, 0x69, 0x70, 0x3b, 0x73, 0x72, 0x70, 0x3b,
-0x6b, 0x6f, 0x6c, 0x3b, 0x72, 0x75, 0x6a, 0x3b, 0x6c, 0x69, 0x73, 0x3b, 0x73, 0x74, 0x75, 0x3b, 0x70, 0x72, 0x6f, 0x3b,
-0x73, 0x69, 0x6a, 0x65, 0x10d, 0x61, 0x6e, 0x6a, 0x3b, 0x76, 0x65, 0x6c, 0x6a, 0x61, 0x10d, 0x61, 0x3b, 0x6f, 0x17e, 0x75,
-0x6a, 0x61, 0x6b, 0x3b, 0x74, 0x72, 0x61, 0x76, 0x61, 0x6e, 0x6a, 0x3b, 0x73, 0x76, 0x69, 0x62, 0x61, 0x6e, 0x6a, 0x3b,
-0x6c, 0x69, 0x70, 0x61, 0x6e, 0x6a, 0x3b, 0x73, 0x72, 0x70, 0x61, 0x6e, 0x6a, 0x3b, 0x6b, 0x6f, 0x6c, 0x6f, 0x76, 0x6f,
-0x7a, 0x3b, 0x72, 0x75, 0x6a, 0x61, 0x6e, 0x3b, 0x6c, 0x69, 0x73, 0x74, 0x6f, 0x70, 0x61, 0x64, 0x3b, 0x73, 0x74, 0x75,
-0x64, 0x65, 0x6e, 0x69, 0x3b, 0x70, 0x72, 0x6f, 0x73, 0x69, 0x6e, 0x61, 0x63, 0x3b, 0x31, 0x2e, 0x3b, 0x32, 0x2e, 0x3b,
-0x33, 0x2e, 0x3b, 0x34, 0x2e, 0x3b, 0x35, 0x2e, 0x3b, 0x36, 0x2e, 0x3b, 0x37, 0x2e, 0x3b, 0x38, 0x2e, 0x3b, 0x39, 0x2e,
-0x3b, 0x31, 0x30, 0x2e, 0x3b, 0x31, 0x31, 0x2e, 0x3b, 0x31, 0x32, 0x2e, 0x3b, 0x73, 0x69, 0x6a, 0x65, 0x10d, 0x6e, 0x6a,
-0x61, 0x3b, 0x76, 0x65, 0x6c, 0x6a, 0x61, 0x10d, 0x65, 0x3b, 0x6f, 0x17e, 0x75, 0x6a, 0x6b, 0x61, 0x3b, 0x74, 0x72, 0x61,
-0x76, 0x6e, 0x6a, 0x61, 0x3b, 0x73, 0x76, 0x69, 0x62, 0x6e, 0x6a, 0x61, 0x3b, 0x6c, 0x69, 0x70, 0x6e, 0x6a, 0x61, 0x3b,
-0x73, 0x72, 0x70, 0x6e, 0x6a, 0x61, 0x3b, 0x6b, 0x6f, 0x6c, 0x6f, 0x76, 0x6f, 0x7a, 0x61, 0x3b, 0x72, 0x75, 0x6a, 0x6e,
-0x61, 0x3b, 0x6c, 0x69, 0x73, 0x74, 0x6f, 0x70, 0x61, 0x64, 0x61, 0x3b, 0x73, 0x74, 0x75, 0x64, 0x65, 0x6e, 0x6f, 0x67,
-0x61, 0x3b, 0x70, 0x72, 0x6f, 0x73, 0x69, 0x6e, 0x63, 0x61, 0x3b, 0x6c, 0x65, 0x64, 0x3b, 0xfa, 0x6e, 0x6f, 0x3b, 0x62,
-0x159, 0x65, 0x3b, 0x64, 0x75, 0x62, 0x3b, 0x6b, 0x76, 0x11b, 0x3b, 0x10d, 0x76, 0x6e, 0x3b, 0x10d, 0x76, 0x63, 0x3b, 0x73,
-0x72, 0x70, 0x3b, 0x7a, 0xe1, 0x159, 0x3b, 0x159, 0xed, 0x6a, 0x3b, 0x6c, 0x69, 0x73, 0x3b, 0x70, 0x72, 0x6f, 0x3b, 0x6c,
-0x65, 0x64, 0x65, 0x6e, 0x3b, 0xfa, 0x6e, 0x6f, 0x72, 0x3b, 0x62, 0x159, 0x65, 0x7a, 0x65, 0x6e, 0x3b, 0x64, 0x75, 0x62,
-0x65, 0x6e, 0x3b, 0x6b, 0x76, 0x11b, 0x74, 0x65, 0x6e, 0x3b, 0x10d, 0x65, 0x72, 0x76, 0x65, 0x6e, 0x3b, 0x10d, 0x65, 0x72,
-0x76, 0x65, 0x6e, 0x65, 0x63, 0x3b, 0x73, 0x72, 0x70, 0x65, 0x6e, 0x3b, 0x7a, 0xe1, 0x159, 0xed, 0x3b, 0x159, 0xed, 0x6a,
-0x65, 0x6e, 0x3b, 0x6c, 0x69, 0x73, 0x74, 0x6f, 0x70, 0x61, 0x64, 0x3b, 0x70, 0x72, 0x6f, 0x73, 0x69, 0x6e, 0x65, 0x63,
-0x3b, 0x6c, 0x3b, 0xfa, 0x3b, 0x62, 0x3b, 0x64, 0x3b, 0x6b, 0x3b, 0x10d, 0x3b, 0x10d, 0x3b, 0x73, 0x3b, 0x7a, 0x3b, 0x159,
-0x3b, 0x6c, 0x3b, 0x70, 0x3b, 0x6c, 0x65, 0x64, 0x6e, 0x61, 0x3b, 0xfa, 0x6e, 0x6f, 0x72, 0x61, 0x3b, 0x62, 0x159, 0x65,
-0x7a, 0x6e, 0x61, 0x3b, 0x64, 0x75, 0x62, 0x6e, 0x61, 0x3b, 0x6b, 0x76, 0x11b, 0x74, 0x6e, 0x61, 0x3b, 0x10d, 0x65, 0x72,
-0x76, 0x6e, 0x61, 0x3b, 0x10d, 0x65, 0x72, 0x76, 0x65, 0x6e, 0x63, 0x65, 0x3b, 0x73, 0x72, 0x70, 0x6e, 0x61, 0x3b, 0x7a,
-0xe1, 0x159, 0xed, 0x3b, 0x159, 0xed, 0x6a, 0x6e, 0x61, 0x3b, 0x6c, 0x69, 0x73, 0x74, 0x6f, 0x70, 0x61, 0x64, 0x75, 0x3b,
-0x70, 0x72, 0x6f, 0x73, 0x69, 0x6e, 0x63, 0x65, 0x3b, 0x6a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72,
-0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x3b, 0x6a, 0x75, 0x6c, 0x3b, 0x61, 0x75, 0x67,
-0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x65, 0x63, 0x3b, 0x6a, 0x61, 0x6e,
-0x75, 0x61, 0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x73, 0x3b, 0x61, 0x70,
-0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75,
-0x67, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62,
-0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72,
-0x3b, 0x6a, 0x61, 0x6e, 0x2e, 0x3b, 0x66, 0x65, 0x62, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x2e, 0x3b, 0x61, 0x70, 0x72, 0x2e,
-0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x2e, 0x3b, 0x6a, 0x75, 0x6c, 0x2e, 0x3b, 0x61, 0x75, 0x67, 0x2e, 0x3b,
-0x73, 0x65, 0x70, 0x2e, 0x3b, 0x6f, 0x6b, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b,
-0x6a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x72, 0x74, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x65, 0x69, 0x3b,
-0x6a, 0x75, 0x6e, 0x3b, 0x6a, 0x75, 0x6c, 0x3b, 0x61, 0x75, 0x67, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x6b, 0x74, 0x3b,
-0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x65, 0x63, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x66, 0x65, 0x62, 0x72,
-0x75, 0x61, 0x72, 0x69, 0x3b, 0x6d, 0x61, 0x61, 0x72, 0x74, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x65, 0x69,
-0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x75, 0x73, 0x3b,
-0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f,
-0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6a, 0x61, 0x6e, 0x2e,
-0x3b, 0x66, 0x65, 0x62, 0x2e, 0x3b, 0x6d, 0x72, 0x74, 0x2e, 0x3b, 0x61, 0x70, 0x72, 0x2e, 0x3b, 0x6d, 0x65, 0x69, 0x3b,
-0x6a, 0x75, 0x6e, 0x2e, 0x3b, 0x6a, 0x75, 0x6c, 0x2e, 0x3b, 0x61, 0x75, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x70, 0x2e, 0x3b,
-0x6f, 0x6b, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b, 0xd801, 0xdc16, 0xd801, 0xdc30, 0xd801,
-0xdc4c, 0x3b, 0xd801, 0xdc19, 0xd801, 0xdc2f, 0xd801, 0xdc3a, 0x3b, 0xd801, 0xdc23, 0xd801, 0xdc2a, 0xd801, 0xdc49, 0x3b, 0xd801, 0xdc01, 0xd801, 0xdc39,
-0xd801, 0xdc49, 0x3b, 0xd801, 0xdc23, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc16, 0xd801, 0xdc2d, 0xd801, 0xdc4c, 0x3b, 0xd801, 0xdc16, 0xd801, 0xdc2d, 0xd801,
-0xdc4a, 0x3b, 0xd801, 0xdc02, 0xd801, 0xdc40, 0x3b, 0xd801, 0xdc1d, 0xd801, 0xdc2f, 0xd801, 0xdc39, 0x3b, 0xd801, 0xdc09, 0xd801, 0xdc3f, 0xd801, 0xdc3b,
-0x3b, 0xd801, 0xdc24, 0xd801, 0xdc2c, 0xd801, 0xdc42, 0x3b, 0xd801, 0xdc14, 0xd801, 0xdc28, 0xd801, 0xdc45, 0x3b, 0xd801, 0xdc16, 0xd801, 0xdc30, 0xd801,
-0xdc4c, 0xd801, 0xdc37, 0xd801, 0xdc2d, 0xd801, 0xdc2f, 0xd801, 0xdc49, 0xd801, 0xdc28, 0x3b, 0xd801, 0xdc19, 0xd801, 0xdc2f, 0xd801, 0xdc3a, 0xd801, 0xdc49,
-0xd801, 0xdc2d, 0xd801, 0xdc2f, 0xd801, 0xdc49, 0xd801, 0xdc28, 0x3b, 0xd801, 0xdc23, 0xd801, 0xdc2a, 0xd801, 0xdc49, 0xd801, 0xdc3d, 0x3b, 0xd801, 0xdc01,
-0xd801, 0xdc39, 0xd801, 0xdc49, 0xd801, 0xdc2e, 0xd801, 0xdc4a, 0x3b, 0xd801, 0xdc23, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc16, 0xd801, 0xdc2d, 0xd801, 0xdc4c,
-0x3b, 0xd801, 0xdc16, 0xd801, 0xdc2d, 0xd801, 0xdc4a, 0xd801, 0xdc34, 0x3b, 0xd801, 0xdc02, 0xd801, 0xdc40, 0xd801, 0xdc32, 0xd801, 0xdc45, 0xd801, 0xdc3b,
-0x3b, 0xd801, 0xdc1d, 0xd801, 0xdc2f, 0xd801, 0xdc39, 0xd801, 0xdc3b, 0xd801, 0xdc2f, 0xd801, 0xdc4b, 0xd801, 0xdc3a, 0xd801, 0xdc32, 0xd801, 0xdc49, 0x3b,
-0xd801, 0xdc09, 0xd801, 0xdc3f, 0xd801, 0xdc3b, 0xd801, 0xdc2c, 0xd801, 0xdc3a, 0xd801, 0xdc32, 0xd801, 0xdc49, 0x3b, 0xd801, 0xdc24, 0xd801, 0xdc2c, 0xd801,
-0xdc42, 0xd801, 0xdc2f, 0xd801, 0xdc4b, 0xd801, 0xdc3a, 0xd801, 0xdc32, 0xd801, 0xdc49, 0x3b, 0xd801, 0xdc14, 0xd801, 0xdc28, 0xd801, 0xdc45, 0xd801, 0xdc2f,
-0xd801, 0xdc4b, 0xd801, 0xdc3a, 0xd801, 0xdc32, 0xd801, 0xdc49, 0x3b, 0xd801, 0xdc16, 0x3b, 0xd801, 0xdc19, 0x3b, 0xd801, 0xdc23, 0x3b, 0xd801, 0xdc01,
-0x3b, 0xd801, 0xdc23, 0x3b, 0xd801, 0xdc16, 0x3b, 0xd801, 0xdc16, 0x3b, 0xd801, 0xdc02, 0x3b, 0xd801, 0xdc1d, 0x3b, 0xd801, 0xdc09, 0x3b, 0xd801,
-0xdc24, 0x3b, 0xd801, 0xdc14, 0x3b, 0x6a, 0x61, 0x61, 0x6e, 0x3b, 0x76, 0x65, 0x65, 0x62, 0x72, 0x3b, 0x6d, 0xe4, 0x72, 0x74,
-0x73, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x75, 0x6c,
-0x69, 0x3b, 0x61, 0x75, 0x67, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64,
-0x65, 0x74, 0x73, 0x3b, 0x6a, 0x61, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x76, 0x65, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72,
-0x3b, 0x6d, 0xe4, 0x72, 0x74, 0x73, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x6c, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75,
-0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70,
-0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65,
-0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x74, 0x73, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4a, 0x3b, 0x56, 0x3b, 0x4d,
-0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x6a,
-0x61, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a,
-0x75, 0x6e, 0x3b, 0x6a, 0x75, 0x6c, 0x3b, 0x61, 0x75, 0x67, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e,
-0x6f, 0x76, 0x3b, 0x64, 0x65, 0x73, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61,
-0x72, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x70, 0x72, 0xed, 0x6c, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75, 0x6e,
-0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d,
-0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72,
-0x3b, 0x64, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x74, 0x61, 0x6d, 0x6d, 0x69, 0x3b, 0x68, 0x65, 0x6c, 0x6d,
-0x69, 0x3b, 0x6d, 0x61, 0x61, 0x6c, 0x69, 0x73, 0x3b, 0x68, 0x75, 0x68, 0x74, 0x69, 0x3b, 0x74, 0x6f, 0x75, 0x6b, 0x6f,
-0x3b, 0x6b, 0x65, 0x73, 0xe4, 0x3b, 0x68, 0x65, 0x69, 0x6e, 0xe4, 0x3b, 0x65, 0x6c, 0x6f, 0x3b, 0x73, 0x79, 0x79, 0x73,
-0x3b, 0x6c, 0x6f, 0x6b, 0x61, 0x3b, 0x6d, 0x61, 0x72, 0x72, 0x61, 0x73, 0x3b, 0x6a, 0x6f, 0x75, 0x6c, 0x75, 0x3b, 0x74,
-0x61, 0x6d, 0x6d, 0x69, 0x6b, 0x75, 0x75, 0x3b, 0x68, 0x65, 0x6c, 0x6d, 0x69, 0x6b, 0x75, 0x75, 0x3b, 0x6d, 0x61, 0x61,
-0x6c, 0x69, 0x73, 0x6b, 0x75, 0x75, 0x3b, 0x68, 0x75, 0x68, 0x74, 0x69, 0x6b, 0x75, 0x75, 0x3b, 0x74, 0x6f, 0x75, 0x6b,
-0x6f, 0x6b, 0x75, 0x75, 0x3b, 0x6b, 0x65, 0x73, 0xe4, 0x6b, 0x75, 0x75, 0x3b, 0x68, 0x65, 0x69, 0x6e, 0xe4, 0x6b, 0x75,
-0x75, 0x3b, 0x65, 0x6c, 0x6f, 0x6b, 0x75, 0x75, 0x3b, 0x73, 0x79, 0x79, 0x73, 0x6b, 0x75, 0x75, 0x3b, 0x6c, 0x6f, 0x6b,
-0x61, 0x6b, 0x75, 0x75, 0x3b, 0x6d, 0x61, 0x72, 0x72, 0x61, 0x73, 0x6b, 0x75, 0x75, 0x3b, 0x6a, 0x6f, 0x75, 0x6c, 0x75,
-0x6b, 0x75, 0x75, 0x3b, 0x54, 0x3b, 0x48, 0x3b, 0x4d, 0x3b, 0x48, 0x3b, 0x54, 0x3b, 0x4b, 0x3b, 0x48, 0x3b, 0x45, 0x3b,
-0x53, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x74, 0x61, 0x6d, 0x6d, 0x69, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x68,
-0x65, 0x6c, 0x6d, 0x69, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x6d, 0x61, 0x61, 0x6c, 0x69, 0x73, 0x6b, 0x75, 0x75, 0x74,
-0x61, 0x3b, 0x68, 0x75, 0x68, 0x74, 0x69, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x74, 0x6f, 0x75, 0x6b, 0x6f, 0x6b, 0x75,
-0x75, 0x74, 0x61, 0x3b, 0x6b, 0x65, 0x73, 0xe4, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x68, 0x65, 0x69, 0x6e, 0xe4, 0x6b,
-0x75, 0x75, 0x74, 0x61, 0x3b, 0x65, 0x6c, 0x6f, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x73, 0x79, 0x79, 0x73, 0x6b, 0x75,
-0x75, 0x74, 0x61, 0x3b, 0x6c, 0x6f, 0x6b, 0x61, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x6d, 0x61, 0x72, 0x72, 0x61, 0x73,
-0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x6a, 0x6f, 0x75, 0x6c, 0x75, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x6a, 0x61, 0x6e,
-0x76, 0x2e, 0x3b, 0x66, 0xe9, 0x76, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x76, 0x72, 0x2e, 0x3b, 0x6d,
-0x61, 0x69, 0x3b, 0x6a, 0x75, 0x69, 0x6e, 0x3b, 0x6a, 0x75, 0x69, 0x6c, 0x2e, 0x3b, 0x61, 0x6f, 0xfb, 0x74, 0x3b, 0x73,
-0x65, 0x70, 0x74, 0x2e, 0x3b, 0x6f, 0x63, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0xe9, 0x63, 0x2e, 0x3b,
-0x6a, 0x61, 0x6e, 0x76, 0x69, 0x65, 0x72, 0x3b, 0x66, 0xe9, 0x76, 0x72, 0x69, 0x65, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x73,
-0x3b, 0x61, 0x76, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75, 0x69, 0x6e, 0x3b, 0x6a, 0x75, 0x69, 0x6c,
-0x6c, 0x65, 0x74, 0x3b, 0x61, 0x6f, 0xfb, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x6f,
-0x63, 0x74, 0x6f, 0x62, 0x72, 0x65, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0xe9, 0x63, 0x65,
-0x6d, 0x62, 0x72, 0x65, 0x3b, 0x46, 0x61, 0x6f, 0x69, 0x3b, 0x47, 0x65, 0x61, 0x72, 0x72, 0x3b, 0x4d, 0xe0, 0x72, 0x74,
-0x3b, 0x47, 0x69, 0x62, 0x6c, 0x3b, 0x43, 0xe8, 0x69, 0x74, 0x3b, 0xd2, 0x67, 0x6d, 0x68, 0x3b, 0x49, 0x75, 0x63, 0x68,
-0x3b, 0x4c, 0xf9, 0x6e, 0x61, 0x3b, 0x53, 0x75, 0x6c, 0x74, 0x3b, 0x44, 0xe0, 0x6d, 0x68, 0x3b, 0x53, 0x61, 0x6d, 0x68,
-0x3b, 0x44, 0xf9, 0x62, 0x68, 0x3b, 0x41, 0x6d, 0x20, 0x46, 0x61, 0x6f, 0x69, 0x6c, 0x6c, 0x65, 0x61, 0x63, 0x68, 0x3b,
-0x41, 0x6e, 0x20, 0x47, 0x65, 0x61, 0x72, 0x72, 0x61, 0x6e, 0x3b, 0x41, 0x6d, 0x20, 0x4d, 0xe0, 0x72, 0x74, 0x3b, 0x41,
-0x6e, 0x20, 0x47, 0x69, 0x62, 0x6c, 0x65, 0x61, 0x6e, 0x3b, 0x41, 0x6e, 0x20, 0x43, 0xe8, 0x69, 0x74, 0x65, 0x61, 0x6e,
-0x3b, 0x41, 0x6e, 0x20, 0x74, 0x2d, 0xd2, 0x67, 0x6d, 0x68, 0x69, 0x6f, 0x73, 0x3b, 0x41, 0x6e, 0x20, 0x74, 0x2d, 0x49,
-0x75, 0x63, 0x68, 0x61, 0x72, 0x3b, 0x41, 0x6e, 0x20, 0x4c, 0xf9, 0x6e, 0x61, 0x73, 0x74, 0x61, 0x6c, 0x3b, 0x41, 0x6e,
-0x20, 0x74, 0x2d, 0x53, 0x75, 0x6c, 0x74, 0x61, 0x69, 0x6e, 0x3b, 0x41, 0x6e, 0x20, 0x44, 0xe0, 0x6d, 0x68, 0x61, 0x69,
-0x72, 0x3b, 0x41, 0x6e, 0x20, 0x74, 0x2d, 0x53, 0x61, 0x6d, 0x68, 0x61, 0x69, 0x6e, 0x3b, 0x41, 0x6e, 0x20, 0x44, 0xf9,
-0x62, 0x68, 0x6c, 0x61, 0x63, 0x68, 0x64, 0x3b, 0x46, 0x41, 0x3b, 0x47, 0x45, 0x3b, 0x4d, 0xc0, 0x3b, 0x47, 0x49, 0x3b,
-0x43, 0xc8, 0x3b, 0xd2, 0x47, 0x3b, 0x49, 0x55, 0x3b, 0x4c, 0xd9, 0x3b, 0x53, 0x55, 0x3b, 0x44, 0xc0, 0x3b, 0x53, 0x41,
-0x3b, 0x44, 0xd9, 0x3b, 0x58, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x62, 0x72, 0x3b,
-0x4d, 0x61, 0x69, 0x3b, 0x58, 0x75, 0xf1, 0x3b, 0x58, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x3b,
-0x4f, 0x75, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x63, 0x3b, 0x58, 0x61, 0x6e, 0x65, 0x69, 0x72, 0x6f, 0x3b,
-0x46, 0x65, 0x62, 0x72, 0x65, 0x69, 0x72, 0x6f, 0x3b, 0x4d, 0x61, 0x72, 0x7a, 0x6f, 0x3b, 0x41, 0x62, 0x72, 0x69, 0x6c,
-0x3b, 0x4d, 0x61, 0x69, 0x6f, 0x3b, 0x58, 0x75, 0xf1, 0x6f, 0x3b, 0x58, 0x75, 0x6c, 0x6c, 0x6f, 0x3b, 0x41, 0x67, 0x6f,
-0x73, 0x74, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x4f, 0x75, 0x74, 0x75, 0x62, 0x72, 0x6f,
-0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x44, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x58,
-0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x58, 0x3b, 0x58, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e,
-0x3b, 0x44, 0x3b, 0x10d8, 0x10d0, 0x10dc, 0x3b, 0x10d7, 0x10d4, 0x10d1, 0x3b, 0x10db, 0x10d0, 0x10e0, 0x3b, 0x10d0, 0x10de, 0x10e0, 0x3b, 0x10db,
-0x10d0, 0x10d8, 0x3b, 0x10d8, 0x10d5, 0x10dc, 0x3b, 0x10d8, 0x10d5, 0x10da, 0x3b, 0x10d0, 0x10d2, 0x10d5, 0x3b, 0x10e1, 0x10d4, 0x10e5, 0x3b, 0x10dd,
-0x10e5, 0x10e2, 0x3b, 0x10dc, 0x10dd, 0x10d4, 0x3b, 0x10d3, 0x10d4, 0x10d9, 0x3b, 0x10d8, 0x10d0, 0x10dc, 0x10d5, 0x10d0, 0x10e0, 0x10d8, 0x3b, 0x10d7,
-0x10d4, 0x10d1, 0x10d4, 0x10e0, 0x10d5, 0x10d0, 0x10da, 0x10d8, 0x3b, 0x10db, 0x10d0, 0x10e0, 0x10e2, 0x10d8, 0x3b, 0x10d0, 0x10de, 0x10e0, 0x10d8, 0x10da,
-0x10d8, 0x3b, 0x10db, 0x10d0, 0x10d8, 0x10e1, 0x10d8, 0x3b, 0x10d8, 0x10d5, 0x10dc, 0x10d8, 0x10e1, 0x10d8, 0x3b, 0x10d8, 0x10d5, 0x10da, 0x10d8, 0x10e1,
-0x3b, 0x10d0, 0x10d2, 0x10d5, 0x10d8, 0x10e1, 0x10e2, 0x10dd, 0x3b, 0x10e1, 0x10d4, 0x10e5, 0x10e2, 0x10d4, 0x10db, 0x10d1, 0x10d4, 0x10e0, 0x10d8, 0x3b,
-0x10dd, 0x10e5, 0x10e2, 0x10dd, 0x10db, 0x10d1, 0x10d4, 0x10e0, 0x10d8, 0x3b, 0x10dc, 0x10dd, 0x10d4, 0x10db, 0x10d1, 0x10d4, 0x10e0, 0x10d8, 0x3b, 0x10d3,
-0x10d4, 0x10d9, 0x10d4, 0x10db, 0x10d1, 0x10d4, 0x10e0, 0x10d8, 0x3b, 0x10d8, 0x3b, 0x10d7, 0x3b, 0x10db, 0x3b, 0x10d0, 0x3b, 0x10db, 0x3b, 0x10d8,
-0x3b, 0x10d8, 0x3b, 0x10d0, 0x3b, 0x10e1, 0x3b, 0x10dd, 0x3b, 0x10dc, 0x3b, 0x10d3, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62,
-0x3b, 0x4d, 0xe4, 0x72, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c,
-0x3b, 0x41, 0x75, 0x67, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x7a,
-0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x4d, 0xe4, 0x72, 0x7a,
-0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x69,
-0x3b, 0x41, 0x75, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4f, 0x6b,
-0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x44, 0x65, 0x7a, 0x65, 0x6d,
-0x62, 0x65, 0x72, 0x3b, 0x4a, 0x61, 0x6e, 0x2e, 0x3b, 0x46, 0x65, 0x62, 0x2e, 0x3b, 0x4d, 0xe4, 0x72, 0x2e, 0x3b, 0x41,
-0x70, 0x72, 0x2e, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x69, 0x3b, 0x41, 0x75,
-0x67, 0x2e, 0x3b, 0x53, 0x65, 0x70, 0x2e, 0x3b, 0x4f, 0x6b, 0x74, 0x2e, 0x3b, 0x4e, 0x6f, 0x76, 0x2e, 0x3b, 0x44, 0x65,
-0x7a, 0x2e, 0x3b, 0x4a, 0xe4, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0xe4, 0x72, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d,
-0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x75, 0x67, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f,
-0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x7a, 0x3b, 0x4a, 0xe4, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x2e, 0x3b,
-0x4d, 0xe4, 0x72, 0x2e, 0x3b, 0x41, 0x70, 0x72, 0x2e, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a,
-0x75, 0x6c, 0x69, 0x3b, 0x41, 0x75, 0x67, 0x2e, 0x3b, 0x53, 0x65, 0x70, 0x2e, 0x3b, 0x4f, 0x6b, 0x74, 0x2e, 0x3b, 0x4e,
-0x6f, 0x76, 0x2e, 0x3b, 0x44, 0x65, 0x7a, 0x2e, 0x3b, 0x4a, 0xe4, 0x6e, 0x6e, 0x65, 0x72, 0x3b, 0x46, 0x65, 0x62, 0x72,
-0x75, 0x61, 0x72, 0x3b, 0x4d, 0xe4, 0x72, 0x7a, 0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a,
-0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x69, 0x3b, 0x41, 0x75, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x53, 0x65, 0x70, 0x74,
-0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62,
-0x65, 0x72, 0x3b, 0x44, 0x65, 0x7a, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x399, 0x3b1, 0x3bd, 0x3b, 0x3a6, 0x3b5, 0x3b2, 0x3b,
-0x39c, 0x3ac, 0x3c1, 0x3b, 0x391, 0x3c0, 0x3c1, 0x3b, 0x39c, 0x3ac, 0x3b9, 0x3b, 0x399, 0x3bf, 0x3cd, 0x3bd, 0x3b, 0x399, 0x3bf, 0x3cd,
-0x3bb, 0x3b, 0x391, 0x3cd, 0x3b3, 0x3b, 0x3a3, 0x3b5, 0x3c0, 0x3b, 0x39f, 0x3ba, 0x3c4, 0x3b, 0x39d, 0x3bf, 0x3ad, 0x3b, 0x394, 0x3b5,
-0x3ba, 0x3b, 0x399, 0x3b1, 0x3bd, 0x3bf, 0x3c5, 0x3ac, 0x3c1, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x3a6, 0x3b5, 0x3b2, 0x3c1, 0x3bf, 0x3c5, 0x3ac,
-0x3c1, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x39c, 0x3ac, 0x3c1, 0x3c4, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x391, 0x3c0, 0x3c1, 0x3af, 0x3bb, 0x3b9, 0x3bf,
-0x3c2, 0x3b, 0x39c, 0x3ac, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x399, 0x3bf, 0x3cd, 0x3bd, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x399, 0x3bf, 0x3cd, 0x3bb,
-0x3b9, 0x3bf, 0x3c2, 0x3b, 0x391, 0x3cd, 0x3b3, 0x3bf, 0x3c5, 0x3c3, 0x3c4, 0x3bf, 0x3c2, 0x3b, 0x3a3, 0x3b5, 0x3c0, 0x3c4, 0x3ad, 0x3bc,
-0x3b2, 0x3c1, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x39f, 0x3ba, 0x3c4, 0x3ce, 0x3b2, 0x3c1, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x39d, 0x3bf, 0x3ad, 0x3bc,
-0x3b2, 0x3c1, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x394, 0x3b5, 0x3ba, 0x3ad, 0x3bc, 0x3b2, 0x3c1, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x399, 0x3b, 0x3a6,
-0x3b, 0x39c, 0x3b, 0x391, 0x3b, 0x39c, 0x3b, 0x399, 0x3b, 0x399, 0x3b, 0x391, 0x3b, 0x3a3, 0x3b, 0x39f, 0x3b, 0x39d, 0x3b, 0x394,
-0x3b, 0x399, 0x3b1, 0x3bd, 0x3b, 0x3a6, 0x3b5, 0x3b2, 0x3b, 0x39c, 0x3b1, 0x3c1, 0x3b, 0x391, 0x3c0, 0x3c1, 0x3b, 0x39c, 0x3b1, 0x3ca,
-0x3b, 0x399, 0x3bf, 0x3c5, 0x3bd, 0x3b, 0x399, 0x3bf, 0x3c5, 0x3bb, 0x3b, 0x391, 0x3c5, 0x3b3, 0x3b, 0x3a3, 0x3b5, 0x3c0, 0x3b, 0x39f,
-0x3ba, 0x3c4, 0x3b, 0x39d, 0x3bf, 0x3b5, 0x3b, 0x394, 0x3b5, 0x3ba, 0x3b, 0x399, 0x3b1, 0x3bd, 0x3bf, 0x3c5, 0x3b1, 0x3c1, 0x3af, 0x3bf,
-0x3c5, 0x3b, 0x3a6, 0x3b5, 0x3b2, 0x3c1, 0x3bf, 0x3c5, 0x3b1, 0x3c1, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x39c, 0x3b1, 0x3c1, 0x3c4, 0x3af, 0x3bf,
-0x3c5, 0x3b, 0x391, 0x3c0, 0x3c1, 0x3b9, 0x3bb, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x39c, 0x3b1, 0x390, 0x3bf, 0x3c5, 0x3b, 0x399, 0x3bf, 0x3c5,
-0x3bd, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x399, 0x3bf, 0x3c5, 0x3bb, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x391, 0x3c5, 0x3b3, 0x3bf, 0x3cd, 0x3c3, 0x3c4,
-0x3bf, 0x3c5, 0x3b, 0x3a3, 0x3b5, 0x3c0, 0x3c4, 0x3b5, 0x3bc, 0x3b2, 0x3c1, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x39f, 0x3ba, 0x3c4, 0x3c9, 0x3b2,
-0x3c1, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x39d, 0x3bf, 0x3b5, 0x3bc, 0x3b2, 0x3c1, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x394, 0x3b5, 0x3ba, 0x3b5, 0x3bc,
-0x3b2, 0x3c1, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61,
-0x72, 0x69, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x73, 0x69, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x69, 0x3b, 0x6d, 0x61, 0x6a,
-0x69, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x75, 0x73,
-0x69, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x69, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72,
-0x69, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x69, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72,
-0x69, 0x3b, 0xa9c, 0xabe, 0xaa8, 0xacd, 0xaaf, 0xac1, 0x3b, 0xaab, 0xac7, 0xaac, 0xacd, 0xab0, 0xac1, 0x3b, 0xaae, 0xabe, 0xab0, 0xacd,
-0xa9a, 0x3b, 0xa8f, 0xaaa, 0xacd, 0xab0, 0xabf, 0xab2, 0x3b, 0xaae, 0xac7, 0x3b, 0xa9c, 0xac2, 0xaa8, 0x3b, 0xa9c, 0xac1, 0xab2, 0xabe,
-0xa88, 0x3b, 0xa91, 0xa97, 0x3b, 0xab8, 0xaaa, 0xacd, 0xa9f, 0xac7, 0x3b, 0xa91, 0xa95, 0xacd, 0xa9f, 0xacb, 0x3b, 0xaa8, 0xab5, 0xac7,
-0x3b, 0xaa1, 0xabf, 0xab8, 0xac7, 0x3b, 0xa9c, 0xabe, 0xaa8, 0xacd, 0xaaf, 0xac1, 0xa86, 0xab0, 0xac0, 0x3b, 0xaab, 0xac7, 0xaac, 0xacd,
-0xab0, 0xac1, 0xa86, 0xab0, 0xac0, 0x3b, 0xaae, 0xabe, 0xab0, 0xacd, 0xa9a, 0x3b, 0xa8f, 0xaaa, 0xacd, 0xab0, 0xabf, 0xab2, 0x3b, 0xaae,
-0xac7, 0x3b, 0xa9c, 0xac2, 0xaa8, 0x3b, 0xa9c, 0xac1, 0xab2, 0xabe, 0xa88, 0x3b, 0xa91, 0xa97, 0xab8, 0xacd, 0xa9f, 0x3b, 0xab8, 0xaaa,
-0xacd, 0xa9f, 0xac7, 0xaae, 0xacd, 0xaac, 0xab0, 0x3b, 0xa91, 0xa95, 0xacd, 0xa9f, 0xacd, 0xaac, 0xab0, 0x3b, 0xaa8, 0xab5, 0xac7, 0xaae,
-0xacd, 0xaac, 0xab0, 0x3b, 0xaa1, 0xabf, 0xab8, 0xac7, 0xaae, 0xacd, 0xaac, 0xab0, 0x3b, 0xa9c, 0xabe, 0x3b, 0xaab, 0xac7, 0x3b, 0xaae,
-0xabe, 0x3b, 0xa8f, 0x3b, 0xaae, 0xac7, 0x3b, 0xa9c, 0xac2, 0x3b, 0xa9c, 0xac1, 0x3b, 0xa91, 0x3b, 0xab8, 0x3b, 0xa91, 0x3b, 0xaa8,
-0x3b, 0xaa1, 0xabf, 0x3b, 0xa9c, 0xabe, 0xaa8, 0xacd, 0xaaf, 0xac1, 0x3b, 0xaab, 0xac7, 0xaac, 0xacd, 0xab0, 0xac1, 0x3b, 0xaae, 0xabe,
-0xab0, 0xacd, 0xa9a, 0x3b, 0xa8f, 0xaaa, 0xacd, 0xab0, 0xabf, 0xab2, 0x3b, 0xaae, 0xac7, 0x3b, 0xa9c, 0xac2, 0xaa8, 0x3b, 0xa9c, 0xac1,
-0xab2, 0xabe, 0xa88, 0x3b, 0xa91, 0xa97, 0xab8, 0xacd, 0xa9f, 0x3b, 0xab8, 0xaaa, 0xacd, 0xa9f, 0xac7, 0x3b, 0xa91, 0xa95, 0xacd, 0xa9f,
-0xacb, 0x3b, 0xaa8, 0xab5, 0xac7, 0x3b, 0xaa1, 0xabf, 0xab8, 0xac7, 0x3b, 0xa9c, 0xabe, 0xaa8, 0xacd, 0xaaf, 0xac1, 0xa86, 0xab0, 0xac0,
-0x3b, 0xaab, 0xac7, 0xaac, 0xacd, 0xab0, 0xac1, 0xa86, 0xab0, 0xac0, 0x3b, 0xaae, 0xabe, 0xab0, 0xacd, 0xa9a, 0x3b, 0xa8f, 0xaaa, 0xacd,
-0xab0, 0xabf, 0xab2, 0x3b, 0xaae, 0xac7, 0x3b, 0xa9c, 0xac2, 0xaa8, 0x3b, 0xa9c, 0xac1, 0xab2, 0xabe, 0xa88, 0x3b, 0xa91, 0xa97, 0xab8,
-0xacd, 0xa9f, 0x3b, 0xab8, 0xaaa, 0xacd, 0xa9f, 0xac7, 0xaae, 0xacd, 0xaac, 0xab0, 0x3b, 0xa91, 0xa95, 0xacd, 0xa9f, 0xacb, 0xaac, 0xab0,
-0x3b, 0xaa8, 0xab5, 0xac7, 0xaae, 0xacd, 0xaac, 0xab0, 0x3b, 0xaa1, 0xabf, 0xab8, 0xac7, 0xaae, 0xacd, 0xaac, 0xab0, 0x3b, 0x4a, 0x61,
-0x6e, 0x3b, 0x46, 0x61, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x66, 0x69, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x59, 0x75,
-0x6e, 0x3b, 0x59, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x75, 0x3b, 0x53, 0x61, 0x74, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x75,
-0x77, 0x3b, 0x44, 0x69, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x61, 0x69, 0x72, 0x75, 0x3b, 0x46, 0x61, 0x62, 0x75, 0x72, 0x61,
-0x69, 0x72, 0x75, 0x3b, 0x4d, 0x61, 0x72, 0x69, 0x73, 0x3b, 0x41, 0x66, 0x69, 0x72, 0x69, 0x6c, 0x75, 0x3b, 0x4d, 0x61,
-0x79, 0x75, 0x3b, 0x59, 0x75, 0x6e, 0x69, 0x3b, 0x59, 0x75, 0x6c, 0x69, 0x3b, 0x41, 0x67, 0x75, 0x73, 0x74, 0x61, 0x3b,
-0x53, 0x61, 0x74, 0x75, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x3b, 0x4e, 0x75, 0x77, 0x61, 0x6d,
-0x62, 0x61, 0x3b, 0x44, 0x69, 0x73, 0x61, 0x6d, 0x62, 0x61, 0x3b, 0x4a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d,
-0x3b, 0x59, 0x3b, 0x59, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x5d9, 0x5e0, 0x5d5, 0x5f3, 0x3b,
-0x5e4, 0x5d1, 0x5e8, 0x5f3, 0x3b, 0x5de, 0x5e8, 0x5e5, 0x3b, 0x5d0, 0x5e4, 0x5e8, 0x5f3, 0x3b, 0x5de, 0x5d0, 0x5d9, 0x3b, 0x5d9, 0x5d5,
-0x5e0, 0x5f3, 0x3b, 0x5d9, 0x5d5, 0x5dc, 0x5f3, 0x3b, 0x5d0, 0x5d5, 0x5d2, 0x5f3, 0x3b, 0x5e1, 0x5e4, 0x5d8, 0x5f3, 0x3b, 0x5d0, 0x5d5,
-0x5e7, 0x5f3, 0x3b, 0x5e0, 0x5d5, 0x5d1, 0x5f3, 0x3b, 0x5d3, 0x5e6, 0x5de, 0x5f3, 0x3b, 0x5d9, 0x5e0, 0x5d5, 0x5d0, 0x5e8, 0x3b, 0x5e4,
-0x5d1, 0x5e8, 0x5d5, 0x5d0, 0x5e8, 0x3b, 0x5de, 0x5e8, 0x5e5, 0x3b, 0x5d0, 0x5e4, 0x5e8, 0x5d9, 0x5dc, 0x3b, 0x5de, 0x5d0, 0x5d9, 0x3b,
-0x5d9, 0x5d5, 0x5e0, 0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5dc, 0x5d9, 0x3b, 0x5d0, 0x5d5, 0x5d2, 0x5d5, 0x5e1, 0x5d8, 0x3b, 0x5e1, 0x5e4, 0x5d8,
-0x5de, 0x5d1, 0x5e8, 0x3b, 0x5d0, 0x5d5, 0x5e7, 0x5d8, 0x5d5, 0x5d1, 0x5e8, 0x3b, 0x5e0, 0x5d5, 0x5d1, 0x5de, 0x5d1, 0x5e8, 0x3b, 0x5d3,
-0x5e6, 0x5de, 0x5d1, 0x5e8, 0x3b, 0x5d9, 0x5e0, 0x5d5, 0x3b, 0x5e4, 0x5d1, 0x5e8, 0x3b, 0x5de, 0x5e8, 0x5e5, 0x3b, 0x5d0, 0x5e4, 0x5e8,
-0x3b, 0x5de, 0x5d0, 0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5e0, 0x3b, 0x5d9, 0x5d5, 0x5dc, 0x3b, 0x5d0, 0x5d5, 0x5d2, 0x3b, 0x5e1, 0x5e4, 0x5d8,
-0x3b, 0x5d0, 0x5d5, 0x5e7, 0x3b, 0x5e0, 0x5d5, 0x5d1, 0x3b, 0x5d3, 0x5e6, 0x5de, 0x3b, 0x91c, 0x928, 0x935, 0x930, 0x940, 0x3b, 0x92b,
-0x930, 0x935, 0x930, 0x940, 0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x91a, 0x3b, 0x905, 0x92a, 0x94d, 0x930, 0x948, 0x932, 0x3b, 0x92e, 0x908,
-0x3b, 0x91c, 0x942, 0x928, 0x3b, 0x91c, 0x941, 0x932, 0x93e, 0x908, 0x3b, 0x905, 0x917, 0x938, 0x94d, 0x924, 0x3b, 0x938, 0x93f, 0x924,
-0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x905, 0x915, 0x94d, 0x924, 0x942, 0x92c, 0x930, 0x3b, 0x928, 0x935, 0x92e, 0x94d, 0x92c, 0x930, 0x3b,
-0x926, 0x93f, 0x938, 0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x91c, 0x3b, 0x92b, 0x93c, 0x3b, 0x92e, 0x93e, 0x3b, 0x905, 0x3b, 0x92e, 0x3b,
-0x91c, 0x942, 0x3b, 0x91c, 0x941, 0x3b, 0x905, 0x3b, 0x938, 0x93f, 0x3b, 0x905, 0x3b, 0x928, 0x3b, 0x926, 0x93f, 0x3b, 0x6a, 0x61,
-0x6e, 0x2e, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x2e, 0x3b, 0x6d, 0xe1, 0x72, 0x63, 0x2e, 0x3b, 0xe1, 0x70, 0x72, 0x2e, 0x3b,
-0x6d, 0xe1, 0x6a, 0x2e, 0x3b, 0x6a, 0xfa, 0x6e, 0x2e, 0x3b, 0x6a, 0xfa, 0x6c, 0x2e, 0x3b, 0x61, 0x75, 0x67, 0x2e, 0x3b,
-0x73, 0x7a, 0x65, 0x70, 0x74, 0x2e, 0x3b, 0x6f, 0x6b, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x63,
-0x2e, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0xe1, 0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0xe1, 0x72, 0x3b, 0x6d, 0xe1, 0x72,
-0x63, 0x69, 0x75, 0x73, 0x3b, 0xe1, 0x70, 0x72, 0x69, 0x6c, 0x69, 0x73, 0x3b, 0x6d, 0xe1, 0x6a, 0x75, 0x73, 0x3b, 0x6a,
-0xfa, 0x6e, 0x69, 0x75, 0x73, 0x3b, 0x6a, 0xfa, 0x6c, 0x69, 0x75, 0x73, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x7a, 0x74,
-0x75, 0x73, 0x3b, 0x73, 0x7a, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0xf3, 0x62, 0x65,
-0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b,
-0x4a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0xc1, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x41, 0x3b, 0x53, 0x7a, 0x3b, 0x4f,
-0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0xc1, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0xc1,
-0x3b, 0x53, 0x7a, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x6a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61,
-0x72, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x61, 0xed, 0x3b, 0x6a, 0xfa, 0x6e, 0x3b, 0x6a, 0xfa, 0x6c, 0x3b, 0xe1, 0x67,
-0xfa, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0xf3, 0x76, 0x3b, 0x64, 0x65, 0x73, 0x3b, 0x6a, 0x61,
-0x6e, 0xfa, 0x61, 0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0xfa, 0x61, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x70,
-0x72, 0xed, 0x6c, 0x3b, 0x6d, 0x61, 0xed, 0x3b, 0x6a, 0xfa, 0x6e, 0xed, 0x3b, 0x6a, 0xfa, 0x6c, 0xed, 0x3b, 0xe1, 0x67,
-0xfa, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0xf3, 0x62, 0x65,
-0x72, 0x3b, 0x6e, 0xf3, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b,
-0x4a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0xc1, 0x3b, 0x53, 0x3b, 0x4f, 0x3b,
-0x4e, 0x3b, 0x44, 0x3b, 0x4a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0xc1, 0x3b,
-0x4c, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b,
-0x41, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x74, 0x3b,
-0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x75,
-0x61, 0x72, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61, 0x72, 0x65, 0x74, 0x3b, 0x41,
-0x70, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x69, 0x3b, 0x41,
-0x67, 0x75, 0x73, 0x74, 0x75, 0x73, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4f, 0x6b, 0x74,
-0x6f, 0x62, 0x65, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x44, 0x65, 0x73, 0x65, 0x6d, 0x62,
-0x65, 0x72, 0x3b, 0x45, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x61, 0x62, 0x68, 0x3b, 0x4d, 0xe1, 0x72, 0x74, 0x61, 0x3b, 0x41,
-0x69, 0x62, 0x3b, 0x42, 0x65, 0x61, 0x6c, 0x3b, 0x4d, 0x65, 0x69, 0x74, 0x68, 0x3b, 0x49, 0xfa, 0x69, 0x6c, 0x3b, 0x4c,
-0xfa, 0x6e, 0x3b, 0x4d, 0x46, 0xf3, 0x6d, 0x68, 0x3b, 0x44, 0x46, 0xf3, 0x6d, 0x68, 0x3b, 0x53, 0x61, 0x6d, 0x68, 0x3b,
-0x4e, 0x6f, 0x6c, 0x6c, 0x3b, 0x45, 0x61, 0x6e, 0xe1, 0x69, 0x72, 0x3b, 0x46, 0x65, 0x61, 0x62, 0x68, 0x72, 0x61, 0x3b,
-0x4d, 0xe1, 0x72, 0x74, 0x61, 0x3b, 0x41, 0x69, 0x62, 0x72, 0x65, 0xe1, 0x6e, 0x3b, 0x42, 0x65, 0x61, 0x6c, 0x74, 0x61,
-0x69, 0x6e, 0x65, 0x3b, 0x4d, 0x65, 0x69, 0x74, 0x68, 0x65, 0x61, 0x6d, 0x68, 0x3b, 0x49, 0xfa, 0x69, 0x6c, 0x3b, 0x4c,
-0xfa, 0x6e, 0x61, 0x73, 0x61, 0x3b, 0x4d, 0x65, 0xe1, 0x6e, 0x20, 0x46, 0xf3, 0x6d, 0x68, 0x61, 0x69, 0x72, 0x3b, 0x44,
-0x65, 0x69, 0x72, 0x65, 0x61, 0x64, 0x68, 0x20, 0x46, 0xf3, 0x6d, 0x68, 0x61, 0x69, 0x72, 0x3b, 0x53, 0x61, 0x6d, 0x68,
-0x61, 0x69, 0x6e, 0x3b, 0x4e, 0x6f, 0x6c, 0x6c, 0x61, 0x69, 0x67, 0x3b, 0x45, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b,
-0x42, 0x3b, 0x4d, 0x3b, 0x49, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x44, 0x3b, 0x53, 0x3b, 0x4e, 0x3b, 0x67, 0x65, 0x6e, 0x3b,
-0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x61, 0x67, 0x3b, 0x67, 0x69, 0x75, 0x3b,
-0x6c, 0x75, 0x67, 0x3b, 0x61, 0x67, 0x6f, 0x3b, 0x73, 0x65, 0x74, 0x3b, 0x6f, 0x74, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b,
-0x64, 0x69, 0x63, 0x3b, 0x47, 0x65, 0x6e, 0x6e, 0x61, 0x69, 0x6f, 0x3b, 0x46, 0x65, 0x62, 0x62, 0x72, 0x61, 0x69, 0x6f,
-0x3b, 0x4d, 0x61, 0x72, 0x7a, 0x6f, 0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c, 0x65, 0x3b, 0x4d, 0x61, 0x67, 0x67, 0x69, 0x6f,
-0x3b, 0x47, 0x69, 0x75, 0x67, 0x6e, 0x6f, 0x3b, 0x4c, 0x75, 0x67, 0x6c, 0x69, 0x6f, 0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74,
-0x6f, 0x3b, 0x53, 0x65, 0x74, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x4f, 0x74, 0x74, 0x6f, 0x62, 0x72, 0x65, 0x3b,
-0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x44, 0x69, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x47, 0x3b,
-0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x47, 0x3b, 0x4c, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b,
-0x44, 0x3b, 0x67, 0x65, 0x6e, 0x6e, 0x61, 0x69, 0x6f, 0x3b, 0x66, 0x65, 0x62, 0x62, 0x72, 0x61, 0x69, 0x6f, 0x3b, 0x6d,
-0x61, 0x72, 0x7a, 0x6f, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x65, 0x3b, 0x6d, 0x61, 0x67, 0x67, 0x69, 0x6f, 0x3b, 0x67,
-0x69, 0x75, 0x67, 0x6e, 0x6f, 0x3b, 0x6c, 0x75, 0x67, 0x6c, 0x69, 0x6f, 0x3b, 0x61, 0x67, 0x6f, 0x73, 0x74, 0x6f, 0x3b,
-0x73, 0x65, 0x74, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x6f, 0x74, 0x74, 0x6f, 0x62, 0x72, 0x65, 0x3b, 0x6e, 0x6f,
-0x76, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x69, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0xc9c, 0xca8, 0xcb5, 0xcb0,
-0xcbf, 0x3b, 0xcab, 0xcc6, 0xcac, 0xccd, 0xcb0, 0xcc1, 0xcb5, 0xcb0, 0xcbf, 0x3b, 0xcae, 0xcbe, 0xcb0, 0xccd, 0xc9a, 0xccd, 0x3b, 0xc8f,
-0xcaa, 0xccd, 0xcb0, 0xcbf, 0xcb2, 0xccd, 0x200c, 0x200c, 0x3b, 0xcae, 0xcc7, 0x3b, 0xc9c, 0xcc2, 0xca8, 0xccd, 0x3b, 0xc9c, 0xcc1, 0xcb2,
-0xcc8, 0x3b, 0xc86, 0xc97, 0xcb8, 0xccd, 0xc9f, 0xccd, 0x3b, 0xcb8, 0xcc6, 0xcaa, 0xccd, 0xc9f, 0xcc6, 0xc82, 0xcac, 0xcb0, 0xccd, 0x200c,
-0x3b, 0xc85, 0xc95, 0xccd, 0xc9f, 0xccb, 0xcac, 0xcb0, 0xccd, 0x3b, 0xca8, 0xcb5, 0xcc6, 0xc82, 0xcac, 0xcb0, 0xccd, 0x3b, 0xca1, 0xcbf,
-0xcb8, 0xcc6, 0xc82, 0xcac, 0xcb0, 0xccd, 0x3b, 0xc9c, 0xca8, 0xcb5, 0xcb0, 0xcc0, 0x3b, 0xcab, 0xcc6, 0xcac, 0xccd, 0xcb0, 0xcb5, 0xcb0,
-0xcc0, 0x3b, 0xcae, 0xcbe, 0xcb0, 0xccd, 0xc9a, 0xccd, 0x3b, 0xc8e, 0xcaa, 0xccd, 0xcb0, 0xcbf, 0xcb2, 0xccd, 0x3b, 0xcae, 0xcc6, 0x3b,
-0xc9c, 0xcc2, 0xca8, 0xccd, 0x3b, 0xc9c, 0xcc1, 0xcb2, 0xcc8, 0x3b, 0xc86, 0xc97, 0xcb8, 0xccd, 0xc9f, 0xccd, 0x3b, 0xcb8, 0xcaa, 0xccd,
-0xc9f, 0xcc6, 0xc82, 0xcac, 0xcb0, 0xccd, 0x3b, 0xc85, 0xc95, 0xccd, 0xc9f, 0xccb, 0xcac, 0xcb0, 0xccd, 0x3b, 0xca8, 0xcb5, 0xcc6, 0xc82,
-0xcac, 0xcb0, 0xccd, 0x3b, 0xca1, 0xcbf, 0xcb8, 0xcc6, 0xc82, 0xcac, 0xcb0, 0xccd, 0x3b, 0xc9c, 0x3b, 0xcab, 0xcc6, 0x3b, 0xcae, 0xcbe,
-0x3b, 0xc8e, 0x3b, 0xcae, 0xcc7, 0x3b, 0xc9c, 0xcc2, 0x3b, 0xc9c, 0xcc1, 0x3b, 0xc86, 0x3b, 0xcb8, 0xcc6, 0x3b, 0xc85, 0x3b, 0xca8,
-0x3b, 0xca1, 0xcbf, 0x3b, 0xc9c, 0x3b, 0xcab, 0xcc6, 0x3b, 0xcae, 0xcbe, 0x3b, 0xc8f, 0x3b, 0xcae, 0xcc7, 0x3b, 0xc9c, 0xcc2, 0x3b,
-0xc9c, 0xcc1, 0x3b, 0xc86, 0x3b, 0xcb8, 0xcc6, 0x3b, 0xc85, 0x3b, 0xca8, 0x3b, 0xca1, 0xcbf, 0x3b, 0x62c, 0x646, 0x624, 0x631, 0x6cc,
-0x3b, 0x641, 0x631, 0x624, 0x631, 0x6cc, 0x3b, 0x645, 0x627, 0x631, 0x655, 0x686, 0x3b, 0x627, 0x67e, 0x631, 0x6cc, 0x644, 0x3b, 0x645,
-0x6cc, 0x654, 0x3b, 0x62c, 0x648, 0x657, 0x646, 0x3b, 0x62c, 0x648, 0x657, 0x644, 0x627, 0x6cc, 0x6cc, 0x3b, 0x627, 0x6af, 0x633, 0x62a,
-0x3b, 0x633, 0x62a, 0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x648, 0x657, 0x628, 0x631, 0x3b, 0x646, 0x648, 0x645, 0x628, 0x631,
-0x3b, 0x62f, 0x633, 0x645, 0x628, 0x631, 0x3b, 0x62c, 0x3b, 0x641, 0x3b, 0x645, 0x3b, 0x627, 0x3b, 0x645, 0x3b, 0x62c, 0x3b, 0x62c,
-0x3b, 0x627, 0x3b, 0x633, 0x3b, 0x633, 0x3b, 0x627, 0x3b, 0x646, 0x3b, 0x49b, 0x430, 0x4a3, 0x2e, 0x3b, 0x430, 0x49b, 0x43f, 0x2e,
-0x3b, 0x43d, 0x430, 0x443, 0x2e, 0x3b, 0x441, 0x4d9, 0x443, 0x2e, 0x3b, 0x43c, 0x430, 0x43c, 0x2e, 0x3b, 0x43c, 0x430, 0x443, 0x2e,
-0x3b, 0x448, 0x456, 0x43b, 0x2e, 0x3b, 0x442, 0x430, 0x43c, 0x2e, 0x3b, 0x49b, 0x44b, 0x440, 0x2e, 0x3b, 0x49b, 0x430, 0x437, 0x2e,
-0x3b, 0x49b, 0x430, 0x440, 0x2e, 0x3b, 0x436, 0x435, 0x43b, 0x442, 0x2e, 0x3b, 0x49b, 0x430, 0x4a3, 0x442, 0x430, 0x440, 0x3b, 0x430,
-0x49b, 0x43f, 0x430, 0x43d, 0x3b, 0x43d, 0x430, 0x443, 0x440, 0x44b, 0x437, 0x3b, 0x441, 0x4d9, 0x443, 0x456, 0x440, 0x3b, 0x43c, 0x430,
-0x43c, 0x44b, 0x440, 0x3b, 0x43c, 0x430, 0x443, 0x441, 0x44b, 0x43c, 0x3b, 0x448, 0x456, 0x43b, 0x434, 0x435, 0x3b, 0x442, 0x430, 0x43c,
-0x44b, 0x437, 0x3b, 0x49b, 0x44b, 0x440, 0x43a, 0x4af, 0x439, 0x435, 0x43a, 0x3b, 0x49b, 0x430, 0x437, 0x430, 0x43d, 0x3b, 0x49b, 0x430,
-0x440, 0x430, 0x448, 0x430, 0x3b, 0x436, 0x435, 0x43b, 0x442, 0x43e, 0x49b, 0x441, 0x430, 0x43d, 0x3b, 0x6d, 0x75, 0x74, 0x2e, 0x3b,
-0x67, 0x61, 0x73, 0x2e, 0x3b, 0x77, 0x65, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x74, 0x2e, 0x3b, 0x67, 0x69, 0x63, 0x2e, 0x3b,
-0x6b, 0x61, 0x6d, 0x2e, 0x3b, 0x6e, 0x79, 0x61, 0x2e, 0x3b, 0x6b, 0x61, 0x6e, 0x2e, 0x3b, 0x6e, 0x7a, 0x65, 0x2e, 0x3b,
-0x75, 0x6b, 0x77, 0x2e, 0x3b, 0x75, 0x67, 0x75, 0x2e, 0x3b, 0x75, 0x6b, 0x75, 0x2e, 0x3b, 0x4d, 0x75, 0x74, 0x61, 0x72,
-0x61, 0x6d, 0x61, 0x3b, 0x47, 0x61, 0x73, 0x68, 0x79, 0x61, 0x6e, 0x74, 0x61, 0x72, 0x65, 0x3b, 0x57, 0x65, 0x72, 0x75,
-0x72, 0x77, 0x65, 0x3b, 0x4d, 0x61, 0x74, 0x61, 0x3b, 0x47, 0x69, 0x63, 0x75, 0x72, 0x61, 0x6e, 0x73, 0x69, 0x3b, 0x4b,
-0x61, 0x6d, 0x65, 0x6e, 0x61, 0x3b, 0x4e, 0x79, 0x61, 0x6b, 0x61, 0x6e, 0x67, 0x61, 0x3b, 0x4b, 0x61, 0x6e, 0x61, 0x6d,
-0x61, 0x3b, 0x4e, 0x7a, 0x65, 0x6c, 0x69, 0x3b, 0x55, 0x6b, 0x77, 0x61, 0x6b, 0x69, 0x72, 0x61, 0x3b, 0x55, 0x67, 0x75,
-0x73, 0x68, 0x79, 0x69, 0x6e, 0x67, 0x6f, 0x3b, 0x55, 0x6b, 0x75, 0x62, 0x6f, 0x7a, 0x61, 0x3b, 0x42f, 0x43d, 0x432, 0x2e,
-0x3b, 0x424, 0x435, 0x432, 0x440, 0x2e, 0x3b, 0x41c, 0x430, 0x440, 0x2e, 0x3b, 0x410, 0x43f, 0x440, 0x2e, 0x3b, 0x41c, 0x430, 0x439,
-0x3b, 0x418, 0x44e, 0x43d, 0x2e, 0x3b, 0x418, 0x44e, 0x43b, 0x2e, 0x3b, 0x410, 0x432, 0x433, 0x2e, 0x3b, 0x421, 0x435, 0x43d, 0x2e,
-0x3b, 0x41e, 0x43a, 0x442, 0x2e, 0x3b, 0x41d, 0x43e, 0x44f, 0x2e, 0x3b, 0x414, 0x435, 0x43a, 0x2e, 0x3b, 0x42f, 0x43d, 0x432, 0x430,
-0x440, 0x44c, 0x3b, 0x424, 0x435, 0x432, 0x440, 0x430, 0x43b, 0x44c, 0x3b, 0x41c, 0x430, 0x440, 0x442, 0x3b, 0x410, 0x43f, 0x440, 0x435,
-0x43b, 0x44c, 0x3b, 0x41c, 0x430, 0x439, 0x3b, 0x418, 0x44e, 0x43d, 0x44c, 0x3b, 0x418, 0x44e, 0x43b, 0x44c, 0x3b, 0x410, 0x432, 0x433,
-0x443, 0x441, 0x442, 0x3b, 0x421, 0x435, 0x43d, 0x442, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x41e, 0x43a, 0x442, 0x44f, 0x431, 0x440, 0x44c,
-0x3b, 0x41d, 0x43e, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x414, 0x435, 0x43a, 0x430, 0x431, 0x440, 0x44c, 0x3b, 0x44f, 0x43d, 0x432, 0x2e,
-0x3b, 0x444, 0x435, 0x432, 0x2e, 0x3b, 0x43c, 0x430, 0x440, 0x2e, 0x3b, 0x430, 0x43f, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x439, 0x3b,
-0x438, 0x44e, 0x43d, 0x2e, 0x3b, 0x438, 0x44e, 0x43b, 0x2e, 0x3b, 0x430, 0x432, 0x433, 0x2e, 0x3b, 0x441, 0x435, 0x43d, 0x2e, 0x3b,
-0x43e, 0x43a, 0x442, 0x2e, 0x3b, 0x43d, 0x43e, 0x44f, 0x2e, 0x3b, 0x434, 0x435, 0x43a, 0x2e, 0x3b, 0x44f, 0x43d, 0x432, 0x430, 0x440,
-0x44c, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x430, 0x43b, 0x44c, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x3b, 0x430, 0x43f, 0x440, 0x435, 0x43b,
-0x44c, 0x3b, 0x43c, 0x430, 0x439, 0x3b, 0x438, 0x44e, 0x43d, 0x44c, 0x3b, 0x438, 0x44e, 0x43b, 0x44c, 0x3b, 0x430, 0x432, 0x433, 0x443,
-0x441, 0x442, 0x3b, 0x441, 0x435, 0x43d, 0x442, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x43e, 0x43a, 0x442, 0x44f, 0x431, 0x440, 0x44c, 0x3b,
-0x43d, 0x43e, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x434, 0x435, 0x43a, 0x430, 0x431, 0x440, 0x44c, 0x3b, 0x31, 0xc6d4, 0x3b, 0x32, 0xc6d4,
-0x3b, 0x33, 0xc6d4, 0x3b, 0x34, 0xc6d4, 0x3b, 0x35, 0xc6d4, 0x3b, 0x36, 0xc6d4, 0x3b, 0x37, 0xc6d4, 0x3b, 0x38, 0xc6d4, 0x3b, 0x39,
-0xc6d4, 0x3b, 0x31, 0x30, 0xc6d4, 0x3b, 0x31, 0x31, 0xc6d4, 0x3b, 0x31, 0x32, 0xc6d4, 0x3b, 0x4d, 0x75, 0x74, 0x2e, 0x3b, 0x47,
-0x61, 0x73, 0x2e, 0x3b, 0x57, 0x65, 0x72, 0x2e, 0x3b, 0x4d, 0x61, 0x74, 0x2e, 0x3b, 0x47, 0x69, 0x63, 0x2e, 0x3b, 0x4b,
-0x61, 0x6d, 0x2e, 0x3b, 0x4e, 0x79, 0x61, 0x2e, 0x3b, 0x4b, 0x61, 0x6e, 0x2e, 0x3b, 0x4e, 0x7a, 0x65, 0x2e, 0x3b, 0x55,
-0x6b, 0x77, 0x2e, 0x3b, 0x55, 0x67, 0x75, 0x2e, 0x3b, 0x55, 0x6b, 0x75, 0x2e, 0x3b, 0x4e, 0x7a, 0x65, 0x72, 0x6f, 0x3b,
-0x52, 0x75, 0x68, 0x75, 0x68, 0x75, 0x6d, 0x61, 0x3b, 0x4e, 0x74, 0x77, 0x61, 0x72, 0x61, 0x6e, 0x74, 0x65, 0x3b, 0x4e,
-0x64, 0x61, 0x6d, 0x75, 0x6b, 0x69, 0x7a, 0x61, 0x3b, 0x52, 0x75, 0x73, 0x61, 0x6d, 0x61, 0x3b, 0x52, 0x75, 0x68, 0x65,
-0x73, 0x68, 0x69, 0x3b, 0x4d, 0x75, 0x6b, 0x61, 0x6b, 0x61, 0x72, 0x6f, 0x3b, 0x4e, 0x79, 0x61, 0x6e, 0x64, 0x61, 0x67,
-0x61, 0x72, 0x6f, 0x3b, 0x4e, 0x79, 0x61, 0x6b, 0x61, 0x6e, 0x67, 0x61, 0x3b, 0x47, 0x69, 0x74, 0x75, 0x67, 0x75, 0x74,
-0x75, 0x3b, 0x4d, 0x75, 0x6e, 0x79, 0x6f, 0x6e, 0x79, 0x6f, 0x3b, 0x4b, 0x69, 0x67, 0x61, 0x72, 0x61, 0x6d, 0x61, 0x3b,
-0xea1, 0x2e, 0xe81, 0x2e, 0x3b, 0xe81, 0x2e, 0xe9e, 0x2e, 0x3b, 0xea1, 0xeb5, 0x2e, 0xe99, 0x2e, 0x3b, 0xea1, 0x2e, 0xeaa, 0x2e,
-0x3b, 0xe9e, 0x2e, 0xe9e, 0x2e, 0x3b, 0xea1, 0xeb4, 0x2e, 0xe96, 0x2e, 0x3b, 0xe81, 0x2e, 0xea5, 0x2e, 0x3b, 0xeaa, 0x2e, 0xeab,
-0x2e, 0x3b, 0xe81, 0x2e, 0xe8d, 0x2e, 0x3b, 0xe95, 0x2e, 0xea5, 0x2e, 0x3b, 0xe9e, 0x2e, 0xe88, 0x2e, 0x3b, 0xe97, 0x2e, 0xea7,
-0x2e, 0x3b, 0xea1, 0xeb1, 0xe87, 0xe81, 0xead, 0xe99, 0x3b, 0xe81, 0xeb8, 0xea1, 0xe9e, 0xeb2, 0x3b, 0xea1, 0xeb5, 0xe99, 0xeb2, 0x3b,
-0xec0, 0xea1, 0xeaa, 0xeb2, 0x3b, 0xe9e, 0xeb6, 0xe94, 0xeaa, 0xeb0, 0xe9e, 0xeb2, 0x3b, 0xea1, 0xeb4, 0xe96, 0xeb8, 0xe99, 0xeb2, 0x3b,
-0xe81, 0xecd, 0xea5, 0xeb0, 0xe81, 0xebb, 0xe94, 0x3b, 0xeaa, 0xeb4, 0xe87, 0xeab, 0xeb2, 0x3b, 0xe81, 0xeb1, 0xe99, 0xe8d, 0xeb2, 0x3b,
-0xe95, 0xeb8, 0xea5, 0xeb2, 0x3b, 0xe9e, 0xeb0, 0xe88, 0xeb4, 0xe81, 0x3b, 0xe97, 0xeb1, 0xe99, 0xea7, 0xeb2, 0x3b, 0xea1, 0x2e, 0xe81,
-0x2e, 0x3b, 0xe81, 0x2e, 0xe9e, 0x2e, 0x3b, 0xea1, 0x2e, 0xe99, 0x2e, 0x3b, 0xea1, 0x2e, 0xeaa, 0x2e, 0x3b, 0xe9e, 0x2e, 0xe9e,
-0x2e, 0x3b, 0xea1, 0xeb4, 0x2e, 0xe96, 0x2e, 0x3b, 0xe81, 0x2e, 0xea5, 0x2e, 0x3b, 0xeaa, 0x2e, 0xeab, 0x2e, 0x3b, 0xe81, 0x2e,
-0xe8d, 0x2e, 0x3b, 0xe95, 0x2e, 0xea5, 0x2e, 0x3b, 0xe9e, 0x2e, 0xe88, 0x2e, 0x3b, 0xe97, 0x2e, 0xea7, 0x2e, 0x3b, 0x4a, 0x61,
-0x6e, 0x76, 0x2e, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x2e, 0x3b, 0x4d, 0x61, 0x72, 0x74, 0x73, 0x3b, 0x41, 0x70, 0x72, 0x2e,
-0x3b, 0x4d, 0x61, 0x69, 0x6a, 0x73, 0x3b, 0x4a, 0x16b, 0x6e, 0x2e, 0x3b, 0x4a, 0x16b, 0x6c, 0x2e, 0x3b, 0x41, 0x75, 0x67,
-0x2e, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x2e, 0x3b, 0x4f, 0x6b, 0x74, 0x2e, 0x3b, 0x4e, 0x6f, 0x76, 0x2e, 0x3b, 0x44, 0x65,
-0x63, 0x2e, 0x3b, 0x4a, 0x61, 0x6e, 0x76, 0x101, 0x72, 0x69, 0x73, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x101, 0x72, 0x69,
-0x73, 0x3b, 0x4d, 0x61, 0x72, 0x74, 0x73, 0x3b, 0x41, 0x70, 0x72, 0x12b, 0x6c, 0x69, 0x73, 0x3b, 0x4d, 0x61, 0x69, 0x6a,
-0x73, 0x3b, 0x4a, 0x16b, 0x6e, 0x69, 0x6a, 0x73, 0x3b, 0x4a, 0x16b, 0x6c, 0x69, 0x6a, 0x73, 0x3b, 0x41, 0x75, 0x67, 0x75,
-0x73, 0x74, 0x73, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x73, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62,
-0x72, 0x69, 0x73, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x73, 0x3b, 0x44, 0x65, 0x63, 0x65, 0x6d, 0x62,
-0x72, 0x69, 0x73, 0x3b, 0x6a, 0x61, 0x6e, 0x76, 0x2e, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x74,
-0x73, 0x3b, 0x61, 0x70, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x69, 0x6a, 0x73, 0x3b, 0x6a, 0x16b, 0x6e, 0x2e, 0x3b, 0x6a, 0x16b,
-0x6c, 0x2e, 0x3b, 0x61, 0x75, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x2e, 0x3b, 0x6f, 0x6b, 0x74, 0x2e, 0x3b, 0x6e,
-0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b, 0x6a, 0x61, 0x6e, 0x76, 0x101, 0x72, 0x69, 0x73, 0x3b, 0x66, 0x65,
-0x62, 0x72, 0x75, 0x101, 0x72, 0x69, 0x73, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x73, 0x3b, 0x61, 0x70, 0x72, 0x12b, 0x6c, 0x69,
-0x73, 0x3b, 0x6d, 0x61, 0x69, 0x6a, 0x73, 0x3b, 0x6a, 0x16b, 0x6e, 0x69, 0x6a, 0x73, 0x3b, 0x6a, 0x16b, 0x6c, 0x69, 0x6a,
-0x73, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x73, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x73,
-0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x72, 0x69, 0x73, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x73, 0x3b,
-0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x73, 0x3b, 0x79, 0x61, 0x6e, 0x3b, 0x66, 0x62, 0x6c, 0x3b, 0x6d, 0x73,
-0x69, 0x3b, 0x61, 0x70, 0x6c, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x79, 0x75, 0x6e, 0x3b, 0x79, 0x75, 0x6c, 0x3b, 0x61, 0x67,
-0x74, 0x3b, 0x73, 0x74, 0x62, 0x3b, 0x254, 0x74, 0x62, 0x3b, 0x6e, 0x76, 0x62, 0x3b, 0x64, 0x73, 0x62, 0x3b, 0x73, 0xe1,
-0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x79, 0x61, 0x6d, 0x62, 0x6f, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79,
-0x61, 0x20, 0x6d, 0xed, 0x62, 0x61, 0x6c, 0xe9, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x6d, 0xed,
-0x73, 0xe1, 0x74, 0x6f, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x6d, 0xed, 0x6e, 0x65, 0x69, 0x3b,
-0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x6d, 0xed, 0x74, 0xe1, 0x6e, 0x6f, 0x3b, 0x73, 0xe1, 0x6e, 0x7a,
-0xe1, 0x20, 0x79, 0x61, 0x20, 0x6d, 0x6f, 0x74, 0xf3, 0x62, 0xe1, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61,
-0x20, 0x6e, 0x73, 0x61, 0x6d, 0x62, 0x6f, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x6d, 0x77, 0x61,
-0x6d, 0x62, 0x65, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x6c, 0x69, 0x62, 0x77, 0x61, 0x3b, 0x73,
-0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x7a, 0xf3, 0x6d, 0x69, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79,
-0x61, 0x20, 0x7a, 0xf3, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x254, 0x30c, 0x6b, 0x254, 0x301, 0x3b, 0x73, 0xe1, 0x6e,
-0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x7a, 0xf3, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0xed, 0x62, 0x61, 0x6c, 0xe9,
-0x3b, 0x79, 0x3b, 0x66, 0x3b, 0x6d, 0x3b, 0x61, 0x3b, 0x6d, 0x3b, 0x79, 0x3b, 0x79, 0x3b, 0x61, 0x3b, 0x73, 0x3b, 0x254,
-0x3b, 0x6e, 0x3b, 0x64, 0x3b, 0x73, 0x61, 0x75, 0x73, 0x2e, 0x3b, 0x76, 0x61, 0x73, 0x2e, 0x3b, 0x6b, 0x6f, 0x76, 0x2e,
-0x3b, 0x62, 0x61, 0x6c, 0x2e, 0x3b, 0x67, 0x65, 0x67, 0x2e, 0x3b, 0x62, 0x69, 0x72, 0x17e, 0x2e, 0x3b, 0x6c, 0x69, 0x65,
-0x70, 0x2e, 0x3b, 0x72, 0x75, 0x67, 0x70, 0x2e, 0x3b, 0x72, 0x75, 0x67, 0x73, 0x2e, 0x3b, 0x73, 0x70, 0x61, 0x6c, 0x2e,
-0x3b, 0x6c, 0x61, 0x70, 0x6b, 0x72, 0x2e, 0x3b, 0x67, 0x72, 0x75, 0x6f, 0x64, 0x2e, 0x3b, 0x73, 0x61, 0x75, 0x73, 0x69,
-0x73, 0x3b, 0x76, 0x61, 0x73, 0x61, 0x72, 0x69, 0x73, 0x3b, 0x6b, 0x6f, 0x76, 0x61, 0x73, 0x3b, 0x62, 0x61, 0x6c, 0x61,
-0x6e, 0x64, 0x69, 0x73, 0x3b, 0x67, 0x65, 0x67, 0x75, 0x17e, 0x117, 0x3b, 0x62, 0x69, 0x72, 0x17e, 0x65, 0x6c, 0x69, 0x73,
-0x3b, 0x6c, 0x69, 0x65, 0x70, 0x61, 0x3b, 0x72, 0x75, 0x67, 0x70, 0x6a, 0x16b, 0x74, 0x69, 0x73, 0x3b, 0x72, 0x75, 0x67,
-0x73, 0x117, 0x6a, 0x69, 0x73, 0x3b, 0x73, 0x70, 0x61, 0x6c, 0x69, 0x73, 0x3b, 0x6c, 0x61, 0x70, 0x6b, 0x72, 0x69, 0x74,
-0x69, 0x73, 0x3b, 0x67, 0x72, 0x75, 0x6f, 0x64, 0x69, 0x73, 0x3b, 0x53, 0x3b, 0x56, 0x3b, 0x4b, 0x3b, 0x42, 0x3b, 0x47,
-0x3b, 0x42, 0x3b, 0x4c, 0x3b, 0x52, 0x3b, 0x52, 0x3b, 0x53, 0x3b, 0x4c, 0x3b, 0x47, 0x3b, 0x458, 0x430, 0x43d, 0x2e, 0x3b,
-0x444, 0x435, 0x432, 0x2e, 0x3b, 0x43c, 0x430, 0x440, 0x2e, 0x3b, 0x430, 0x43f, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x458, 0x3b, 0x458,
-0x443, 0x43d, 0x2e, 0x3b, 0x458, 0x443, 0x43b, 0x2e, 0x3b, 0x430, 0x432, 0x433, 0x2e, 0x3b, 0x441, 0x435, 0x43f, 0x442, 0x2e, 0x3b,
-0x43e, 0x43a, 0x442, 0x2e, 0x3b, 0x43d, 0x43e, 0x435, 0x43c, 0x2e, 0x3b, 0x434, 0x435, 0x43a, 0x435, 0x43c, 0x2e, 0x3b, 0x458, 0x430,
-0x43d, 0x443, 0x430, 0x440, 0x438, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x443, 0x430, 0x440, 0x438, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x3b,
-0x430, 0x43f, 0x440, 0x438, 0x43b, 0x3b, 0x43c, 0x430, 0x458, 0x3b, 0x458, 0x443, 0x43d, 0x438, 0x3b, 0x458, 0x443, 0x43b, 0x438, 0x3b,
-0x430, 0x432, 0x433, 0x443, 0x441, 0x442, 0x3b, 0x441, 0x435, 0x43f, 0x442, 0x435, 0x43c, 0x432, 0x440, 0x438, 0x3b, 0x43e, 0x43a, 0x442,
-0x43e, 0x43c, 0x432, 0x440, 0x438, 0x3b, 0x43d, 0x43e, 0x435, 0x43c, 0x432, 0x440, 0x438, 0x3b, 0x434, 0x435, 0x43a, 0x435, 0x43c, 0x432,
-0x440, 0x438, 0x3b, 0x458, 0x3b, 0x444, 0x3b, 0x43c, 0x3b, 0x430, 0x3b, 0x43c, 0x3b, 0x458, 0x3b, 0x458, 0x3b, 0x430, 0x3b, 0x441,
-0x3b, 0x43e, 0x3b, 0x43d, 0x3b, 0x434, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41,
-0x70, 0x72, 0x3b, 0x4d, 0x65, 0x79, 0x3b, 0x4a, 0x6f, 0x6e, 0x3b, 0x4a, 0x6f, 0x6c, 0x3b, 0x41, 0x6f, 0x67, 0x3b, 0x53,
-0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x6f, 0x61,
-0x72, 0x79, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x6f, 0x61, 0x72, 0x79, 0x3b, 0x4d, 0x61, 0x72, 0x74, 0x73, 0x61, 0x3b, 0x41,
-0x70, 0x72, 0x69, 0x6c, 0x79, 0x3b, 0x4d, 0x65, 0x79, 0x3b, 0x4a, 0x6f, 0x6e, 0x61, 0x3b, 0x4a, 0x6f, 0x6c, 0x61, 0x79,
-0x3b, 0x41, 0x6f, 0x67, 0x6f, 0x73, 0x69, 0x74, 0x72, 0x61, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x61, 0x6d, 0x62, 0x72, 0x61,
-0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x72, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x61, 0x6d, 0x62, 0x72, 0x61, 0x3b, 0x44, 0x65,
-0x73, 0x61, 0x6d, 0x62, 0x72, 0x61, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x63, 0x3b, 0x41,
-0x70, 0x72, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x4f, 0x67, 0x6f, 0x73, 0x3b,
-0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x69, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x75,
-0x61, 0x72, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61, 0x63, 0x3b, 0x41, 0x70, 0x72,
-0x69, 0x6c, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x69, 0x3b, 0x4f, 0x67, 0x6f,
-0x73, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b,
-0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4a, 0x3b,
-0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x4f, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b,
-0x44, 0x3b, 0xd1c, 0xd28, 0xd41, 0x3b, 0xd2b, 0xd46, 0xd2c, 0xd4d, 0xd30, 0xd41, 0x3b, 0xd2e, 0xd3e, 0xd7c, 0x3b, 0xd0f, 0xd2a, 0xd4d,
-0xd30, 0xd3f, 0x3b, 0xd2e, 0xd47, 0xd2f, 0xd4d, 0x3b, 0xd1c, 0xd42, 0xd7a, 0x3b, 0xd1c, 0xd42, 0xd32, 0xd48, 0x3b, 0xd13, 0xd17, 0x3b,
-0xd38, 0xd46, 0xd2a, 0xd4d, 0xd31, 0xd4d, 0xd31, 0xd02, 0x3b, 0xd12, 0xd15, 0xd4d, 0xd1f, 0xd4b, 0x3b, 0xd28, 0xd35, 0xd02, 0x3b, 0xd21,
-0xd3f, 0xd38, 0xd02, 0x3b, 0xd1c, 0xd28, 0xd41, 0xd35, 0xd30, 0xd3f, 0x3b, 0xd2b, 0xd46, 0xd2c, 0xd4d, 0xd30, 0xd41, 0xd35, 0xd30, 0xd3f,
-0x3b, 0xd2e, 0xd3e, 0xd7c, 0xd1a, 0xd4d, 0xd1a, 0xd4d, 0x3b, 0xd0f, 0xd2a, 0xd4d, 0xd30, 0xd3f, 0xd7d, 0x3b, 0xd2e, 0xd47, 0xd2f, 0xd4d,
-0x3b, 0xd1c, 0xd42, 0xd7a, 0x3b, 0xd1c, 0xd42, 0xd32, 0xd48, 0x3b, 0xd06, 0xd17, 0xd38, 0xd4d, 0xd31, 0xd4d, 0xd31, 0xd4d, 0x3b, 0xd38,
-0xd46, 0xd2a, 0xd4d, 0xd31, 0xd4d, 0xd31, 0xd02, 0xd2c, 0xd7c, 0x3b, 0xd12, 0xd15, 0xd4d, 0xd1f, 0xd4b, 0xd2c, 0xd7c, 0x3b, 0xd28, 0xd35,
-0xd02, 0xd2c, 0xd7c, 0x3b, 0xd21, 0xd3f, 0xd38, 0xd02, 0xd2c, 0xd7c, 0x3b, 0xd1c, 0x3b, 0xd2b, 0xd46, 0x3b, 0xd2e, 0xd3e, 0x3b, 0xd0f,
-0x3b, 0xd2e, 0xd47, 0x3b, 0xd1c, 0xd42, 0x3b, 0xd1c, 0xd42, 0x3b, 0xd13, 0x3b, 0xd38, 0xd46, 0x3b, 0xd12, 0x3b, 0xd28, 0x3b, 0xd21,
-0xd3f, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x72, 0x61, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x65,
-0x6a, 0x3b, 0x120, 0x75, 0x6e, 0x3b, 0x4c, 0x75, 0x6c, 0x3b, 0x41, 0x77, 0x77, 0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x74,
-0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x69, 0x10b, 0x3b, 0x4a, 0x61, 0x6e, 0x6e, 0x61, 0x72, 0x3b, 0x46, 0x72, 0x61,
-0x72, 0x3b, 0x4d, 0x61, 0x72, 0x7a, 0x75, 0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x65, 0x6a, 0x6a, 0x75, 0x3b,
-0x120, 0x75, 0x6e, 0x6a, 0x75, 0x3b, 0x4c, 0x75, 0x6c, 0x6a, 0x75, 0x3b, 0x41, 0x77, 0x77, 0x69, 0x73, 0x73, 0x75, 0x3b,
-0x53, 0x65, 0x74, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x75, 0x3b, 0x4f, 0x74, 0x74, 0x75, 0x62, 0x72, 0x75, 0x3b, 0x4e, 0x6f,
-0x76, 0x65, 0x6d, 0x62, 0x72, 0x75, 0x3b, 0x44, 0x69, 0x10b, 0x65, 0x6d, 0x62, 0x72, 0x75, 0x3b, 0x4a, 0x3b, 0x46, 0x3b,
-0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x120, 0x3b, 0x4c, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b,
-0x91c, 0x93e, 0x928, 0x947, 0x3b, 0x92b, 0x947, 0x92c, 0x94d, 0x930, 0x941, 0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x91a, 0x3b, 0x90f, 0x92a,
-0x94d, 0x930, 0x93f, 0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x942, 0x928, 0x3b, 0x91c, 0x941, 0x932, 0x948, 0x3b, 0x911, 0x917, 0x3b, 0x938,
-0x947, 0x92a, 0x94d, 0x91f, 0x947, 0x902, 0x3b, 0x911, 0x915, 0x94d, 0x91f, 0x3b, 0x928, 0x94b, 0x935, 0x94d, 0x939, 0x947, 0x902, 0x3b,
-0x921, 0x93f, 0x938, 0x947, 0x902, 0x3b, 0x91c, 0x93e, 0x928, 0x947, 0x935, 0x93e, 0x930, 0x940, 0x3b, 0x92b, 0x947, 0x92c, 0x94d, 0x930,
-0x941, 0x935, 0x93e, 0x930, 0x940, 0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x91a, 0x3b, 0x90f, 0x92a, 0x94d, 0x930, 0x93f, 0x932, 0x3b, 0x92e,
-0x947, 0x3b, 0x91c, 0x942, 0x928, 0x3b, 0x91c, 0x941, 0x932, 0x948, 0x3b, 0x911, 0x917, 0x938, 0x94d, 0x91f, 0x3b, 0x938, 0x92a, 0x94d,
-0x91f, 0x947, 0x902, 0x92c, 0x930, 0x3b, 0x911, 0x915, 0x94d, 0x91f, 0x94b, 0x92c, 0x930, 0x3b, 0x928, 0x94b, 0x935, 0x94d, 0x939, 0x947,
-0x902, 0x92c, 0x930, 0x3b, 0x921, 0x93f, 0x938, 0x947, 0x902, 0x92c, 0x930, 0x3b, 0x91c, 0x93e, 0x3b, 0x92b, 0x947, 0x3b, 0x92e, 0x93e,
-0x3b, 0x90f, 0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x942, 0x3b, 0x91c, 0x941, 0x3b, 0x911, 0x3b, 0x938, 0x3b, 0x911, 0x3b, 0x928, 0x94b,
-0x3b, 0x921, 0x93f, 0x3b, 0x91c, 0x928, 0x3b, 0x92b, 0x947, 0x92c, 0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x91a, 0x3b, 0x905, 0x92a, 0x94d,
-0x930, 0x93f, 0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x941, 0x928, 0x3b, 0x91c, 0x941, 0x932, 0x93e, 0x3b, 0x905, 0x917, 0x3b, 0x938, 0x947,
-0x92a, 0x94d, 0x91f, 0x3b, 0x905, 0x915, 0x94d, 0x91f, 0x94b, 0x3b, 0x928, 0x94b, 0x92d, 0x947, 0x3b, 0x921, 0x93f, 0x938, 0x947, 0x3b,
-0x91c, 0x928, 0x935, 0x930, 0x940, 0x3b, 0x92b, 0x947, 0x92c, 0x94d, 0x930, 0x941, 0x905, 0x930, 0x940, 0x3b, 0x92e, 0x93e, 0x930, 0x94d,
-0x91a, 0x3b, 0x905, 0x92a, 0x94d, 0x930, 0x93f, 0x932, 0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x941, 0x928, 0x3b, 0x91c, 0x941, 0x932, 0x93e,
-0x908, 0x3b, 0x905, 0x917, 0x938, 0x94d, 0x91f, 0x3b, 0x938, 0x947, 0x92a, 0x94d, 0x91f, 0x947, 0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x905,
-0x915, 0x94d, 0x91f, 0x94b, 0x92c, 0x930, 0x3b, 0x928, 0x94b, 0x92d, 0x947, 0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x921, 0x93f, 0x938, 0x947,
-0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x967, 0x3b, 0x968, 0x3b, 0x969, 0x3b, 0x96a, 0x3b, 0x96b, 0x3b, 0x96c, 0x3b, 0x96d, 0x3b, 0x96e,
-0x3b, 0x96f, 0x3b, 0x967, 0x966, 0x3b, 0x967, 0x967, 0x3b, 0x967, 0x968, 0x3b, 0x91c, 0x928, 0x935, 0x930, 0x940, 0x3b, 0x92b, 0x930,
-0x935, 0x930, 0x940, 0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x91a, 0x3b, 0x905, 0x92a, 0x94d, 0x930, 0x947, 0x932, 0x3b, 0x92e, 0x908, 0x3b,
-0x91c, 0x941, 0x928, 0x3b, 0x91c, 0x941, 0x932, 0x93e, 0x908, 0x3b, 0x905, 0x917, 0x938, 0x94d, 0x924, 0x3b, 0x938, 0x947, 0x92a, 0x94d,
-0x91f, 0x947, 0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x905, 0x915, 0x94d, 0x91f, 0x94b, 0x92c, 0x930, 0x3b, 0x928, 0x94b, 0x92d, 0x947, 0x92e,
-0x94d, 0x92c, 0x930, 0x3b, 0x926, 0x93f, 0x938, 0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x66,
-0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61,
-0x69, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x73,
-0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76,
-0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6a, 0x61, 0x6e, 0x2e, 0x3b,
-0x66, 0x65, 0x62, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x70, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a,
-0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x70, 0x2e, 0x3b, 0x6f,
-0x6b, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x73, 0x2e, 0x3b, 0xb1c, 0xb3e, 0xb28, 0xb41, 0xb06, 0xb30,
-0xb40, 0x3b, 0xb2b, 0xb47, 0xb2c, 0xb4d, 0xb30, 0xb41, 0xb5f, 0xb3e, 0xb30, 0xb40, 0x3b, 0xb2e, 0xb3e, 0xb30, 0xb4d, 0xb1a, 0xb4d, 0xb1a,
-0x3b, 0xb05, 0xb2a, 0xb4d, 0xb30, 0xb47, 0xb32, 0x3b, 0xb2e, 0xb47, 0x3b, 0xb1c, 0xb41, 0xb28, 0x3b, 0xb1c, 0xb41, 0xb32, 0xb3e, 0xb07,
-0x3b, 0xb05, 0xb17, 0xb37, 0xb4d, 0xb1f, 0x3b, 0xb38, 0xb47, 0xb2a, 0xb4d, 0xb1f, 0xb47, 0xb2e, 0xb4d, 0xb2c, 0xb30, 0x3b, 0xb05, 0xb15,
-0xb4d, 0xb1f, 0xb4b, 0xb2c, 0xb30, 0x3b, 0xb28, 0xb2d, 0xb47, 0xb2e, 0xb4d, 0xb2c, 0xb30, 0x3b, 0xb21, 0xb3f, 0xb38, 0xb47, 0xb2e, 0xb4d,
-0xb2c, 0xb30, 0x3b, 0xb1c, 0xb3e, 0x3b, 0xb2b, 0xb47, 0x3b, 0xb2e, 0xb3e, 0x3b, 0xb05, 0x3b, 0xb2e, 0xb47, 0x3b, 0xb1c, 0xb41, 0x3b,
-0xb1c, 0xb41, 0x3b, 0xb05, 0x3b, 0xb38, 0xb47, 0x3b, 0xb05, 0x3b, 0xb28, 0x3b, 0xb21, 0xb3f, 0x3b, 0x62c, 0x646, 0x648, 0x631, 0x64a,
-0x3b, 0x641, 0x628, 0x631, 0x648, 0x631, 0x64a, 0x3b, 0x645, 0x627, 0x631, 0x686, 0x3b, 0x627, 0x67e, 0x631, 0x6cc, 0x644, 0x3b, 0x645,
-0x6cc, 0x3b, 0x62c, 0x648, 0x646, 0x3b, 0x62c, 0x648, 0x644, 0x627, 0x6cc, 0x3b, 0x627, 0x6ab, 0x633, 0x62a, 0x3b, 0x633, 0x67e, 0x62a,
-0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x648, 0x628, 0x631, 0x3b, 0x646, 0x648, 0x645, 0x628, 0x631, 0x3b, 0x62f, 0x633, 0x645,
-0x628, 0x631, 0x3b, 0x698, 0x627, 0x646, 0x648, 0x6cc, 0x647, 0x3b, 0x641, 0x648, 0x631, 0x6cc, 0x647, 0x3b, 0x645, 0x627, 0x631, 0x633,
-0x3b, 0x622, 0x648, 0x631, 0x6cc, 0x644, 0x3b, 0x645, 0x647, 0x3b, 0x698, 0x648, 0x626, 0x646, 0x3b, 0x698, 0x648, 0x626, 0x6cc, 0x647,
-0x3b, 0x627, 0x648, 0x62a, 0x3b, 0x633, 0x67e, 0x62a, 0x627, 0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x628, 0x631, 0x3b, 0x646,
-0x648, 0x627, 0x645, 0x628, 0x631, 0x3b, 0x62f, 0x633, 0x627, 0x645, 0x628, 0x631, 0x3b, 0x698, 0x3b, 0x641, 0x3b, 0x645, 0x3b, 0x622,
-0x3b, 0x645, 0x3b, 0x698, 0x3b, 0x698, 0x3b, 0x627, 0x3b, 0x633, 0x3b, 0x627, 0x3b, 0x646, 0x3b, 0x62f, 0x3b, 0x698, 0x627, 0x646,
-0x648, 0x6cc, 0x647, 0x654, 0x3b, 0x641, 0x648, 0x631, 0x6cc, 0x647, 0x654, 0x3b, 0x645, 0x627, 0x631, 0x633, 0x3b, 0x622, 0x648, 0x631,
-0x6cc, 0x644, 0x3b, 0x645, 0x647, 0x654, 0x3b, 0x698, 0x648, 0x626, 0x646, 0x3b, 0x698, 0x648, 0x626, 0x6cc, 0x647, 0x654, 0x3b, 0x627,
-0x648, 0x62a, 0x3b, 0x633, 0x67e, 0x62a, 0x627, 0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x628, 0x631, 0x3b, 0x646, 0x648, 0x627,
-0x645, 0x628, 0x631, 0x3b, 0x62f, 0x633, 0x627, 0x645, 0x628, 0x631, 0x3b, 0x62c, 0x3b, 0x641, 0x3b, 0x645, 0x3b, 0x627, 0x3b, 0x645,
-0x3b, 0x62c, 0x3b, 0x62c, 0x3b, 0x627, 0x3b, 0x633, 0x3b, 0x627, 0x3b, 0x646, 0x3b, 0x62f, 0x3b, 0x62c, 0x646, 0x648, 0x3b, 0x641,
-0x648, 0x631, 0x6cc, 0x647, 0x654, 0x3b, 0x645, 0x627, 0x631, 0x633, 0x3b, 0x622, 0x648, 0x631, 0x6cc, 0x644, 0x3b, 0x645, 0x640, 0x6cc,
-0x3b, 0x698, 0x648, 0x626, 0x646, 0x3b, 0x62c, 0x648, 0x644, 0x3b, 0x627, 0x648, 0x62a, 0x3b, 0x633, 0x67e, 0x62a, 0x627, 0x645, 0x628,
-0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x628, 0x631, 0x3b, 0x646, 0x648, 0x627, 0x645, 0x628, 0x631, 0x3b, 0x62f, 0x633, 0x645, 0x3b, 0x62c,
-0x646, 0x648, 0x631, 0x6cc, 0x3b, 0x641, 0x628, 0x631, 0x648, 0x631, 0x6cc, 0x3b, 0x645, 0x627, 0x631, 0x686, 0x3b, 0x627, 0x67e, 0x631,
-0x6cc, 0x644, 0x3b, 0x645, 0x6cc, 0x3b, 0x62c, 0x648, 0x646, 0x3b, 0x62c, 0x648, 0x644, 0x627, 0x6cc, 0x3b, 0x627, 0x6af, 0x633, 0x62a,
-0x3b, 0x633, 0x67e, 0x62a, 0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x648, 0x628, 0x631, 0x3b, 0x646, 0x648, 0x645, 0x628, 0x631,
-0x3b, 0x62f, 0x633, 0x645, 0x628, 0x631, 0x3b, 0x73, 0x74, 0x79, 0x3b, 0x6c, 0x75, 0x74, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x6b,
-0x77, 0x69, 0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x63, 0x7a, 0x65, 0x3b, 0x6c, 0x69, 0x70, 0x3b, 0x73, 0x69, 0x65, 0x3b, 0x77,
-0x72, 0x7a, 0x3b, 0x70, 0x61, 0x17a, 0x3b, 0x6c, 0x69, 0x73, 0x3b, 0x67, 0x72, 0x75, 0x3b, 0x73, 0x74, 0x79, 0x63, 0x7a,
-0x65, 0x144, 0x3b, 0x6c, 0x75, 0x74, 0x79, 0x3b, 0x6d, 0x61, 0x72, 0x7a, 0x65, 0x63, 0x3b, 0x6b, 0x77, 0x69, 0x65, 0x63,
-0x69, 0x65, 0x144, 0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x63, 0x7a, 0x65, 0x72, 0x77, 0x69, 0x65, 0x63, 0x3b, 0x6c, 0x69, 0x70,
-0x69, 0x65, 0x63, 0x3b, 0x73, 0x69, 0x65, 0x72, 0x70, 0x69, 0x65, 0x144, 0x3b, 0x77, 0x72, 0x7a, 0x65, 0x73, 0x69, 0x65,
-0x144, 0x3b, 0x70, 0x61, 0x17a, 0x64, 0x7a, 0x69, 0x65, 0x72, 0x6e, 0x69, 0x6b, 0x3b, 0x6c, 0x69, 0x73, 0x74, 0x6f, 0x70,
-0x61, 0x64, 0x3b, 0x67, 0x72, 0x75, 0x64, 0x7a, 0x69, 0x65, 0x144, 0x3b, 0x73, 0x3b, 0x6c, 0x3b, 0x6d, 0x3b, 0x6b, 0x3b,
-0x6d, 0x3b, 0x63, 0x3b, 0x6c, 0x3b, 0x73, 0x3b, 0x77, 0x3b, 0x70, 0x3b, 0x6c, 0x3b, 0x67, 0x3b, 0x73, 0x74, 0x79, 0x63,
-0x7a, 0x6e, 0x69, 0x61, 0x3b, 0x6c, 0x75, 0x74, 0x65, 0x67, 0x6f, 0x3b, 0x6d, 0x61, 0x72, 0x63, 0x61, 0x3b, 0x6b, 0x77,
-0x69, 0x65, 0x74, 0x6e, 0x69, 0x61, 0x3b, 0x6d, 0x61, 0x6a, 0x61, 0x3b, 0x63, 0x7a, 0x65, 0x72, 0x77, 0x63, 0x61, 0x3b,
-0x6c, 0x69, 0x70, 0x63, 0x61, 0x3b, 0x73, 0x69, 0x65, 0x72, 0x70, 0x6e, 0x69, 0x61, 0x3b, 0x77, 0x72, 0x7a, 0x65, 0x15b,
-0x6e, 0x69, 0x61, 0x3b, 0x70, 0x61, 0x17a, 0x64, 0x7a, 0x69, 0x65, 0x72, 0x6e, 0x69, 0x6b, 0x61, 0x3b, 0x6c, 0x69, 0x73,
-0x74, 0x6f, 0x70, 0x61, 0x64, 0x61, 0x3b, 0x67, 0x72, 0x75, 0x64, 0x6e, 0x69, 0x61, 0x3b, 0x6a, 0x61, 0x6e, 0x3b, 0x66,
-0x65, 0x76, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x62, 0x72, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75, 0x6e, 0x3b, 0x6a,
-0x75, 0x6c, 0x3b, 0x61, 0x67, 0x6f, 0x3b, 0x73, 0x65, 0x74, 0x3b, 0x6f, 0x75, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64,
-0x65, 0x7a, 0x3b, 0x6a, 0x61, 0x6e, 0x65, 0x69, 0x72, 0x6f, 0x3b, 0x66, 0x65, 0x76, 0x65, 0x72, 0x65, 0x69, 0x72, 0x6f,
-0x3b, 0x6d, 0x61, 0x72, 0xe7, 0x6f, 0x3b, 0x61, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x69, 0x6f, 0x3b, 0x6a, 0x75,
-0x6e, 0x68, 0x6f, 0x3b, 0x6a, 0x75, 0x6c, 0x68, 0x6f, 0x3b, 0x61, 0x67, 0x6f, 0x73, 0x74, 0x6f, 0x3b, 0x73, 0x65, 0x74,
-0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x6f, 0x75, 0x74, 0x75, 0x62, 0x72, 0x6f, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62,
-0x72, 0x6f, 0x3b, 0x64, 0x65, 0x7a, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x76, 0x3b,
-0x4d, 0x61, 0x72, 0x3b, 0x41, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b,
-0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x75, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x7a, 0x3b,
-0x4a, 0x61, 0x6e, 0x65, 0x69, 0x72, 0x6f, 0x3b, 0x46, 0x65, 0x76, 0x65, 0x72, 0x65, 0x69, 0x72, 0x6f, 0x3b, 0x4d, 0x61,
-0x72, 0xe7, 0x6f, 0x3b, 0x41, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x6f, 0x3b, 0x4a, 0x75, 0x6e, 0x68, 0x6f,
-0x3b, 0x4a, 0x75, 0x6c, 0x68, 0x6f, 0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x65, 0x6d, 0x62,
-0x72, 0x6f, 0x3b, 0x4f, 0x75, 0x74, 0x75, 0x62, 0x72, 0x6f, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b,
-0x44, 0x65, 0x7a, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0xa1c, 0xa28, 0xa35, 0xa30, 0xa40, 0x3b, 0xa2b, 0xa3c, 0xa30, 0xa35, 0xa30,
-0xa40, 0x3b, 0xa2e, 0xa3e, 0xa30, 0xa1a, 0x3b, 0xa05, 0xa2a, 0xa4d, 0xa30, 0xa48, 0xa32, 0x3b, 0xa2e, 0xa08, 0x3b, 0xa1c, 0xa42, 0xa28,
-0x3b, 0xa1c, 0xa41, 0xa32, 0xa3e, 0xa08, 0x3b, 0xa05, 0xa17, 0xa38, 0xa24, 0x3b, 0xa38, 0xa24, 0xa70, 0xa2c, 0xa30, 0x3b, 0xa05, 0xa15,
-0xa24, 0xa42, 0xa2c, 0xa30, 0x3b, 0xa28, 0xa35, 0xa70, 0xa2c, 0xa30, 0x3b, 0xa26, 0xa38, 0xa70, 0xa2c, 0xa30, 0x3b, 0xa1c, 0x3b, 0xa2b,
-0x3b, 0xa2e, 0xa3e, 0x3b, 0xa05, 0x3b, 0xa2e, 0x3b, 0xa1c, 0xa42, 0x3b, 0xa1c, 0xa41, 0x3b, 0xa05, 0x3b, 0xa38, 0x3b, 0xa05, 0x3b,
-0xa28, 0x3b, 0xa26, 0x3b, 0x62c, 0x646, 0x648, 0x631, 0x6cc, 0x3b, 0x641, 0x631, 0x648, 0x631, 0x6cc, 0x3b, 0x645, 0x627, 0x631, 0x686,
-0x3b, 0x627, 0x67e, 0x631, 0x6cc, 0x644, 0x3b, 0x645, 0x626, 0x3b, 0x62c, 0x648, 0x646, 0x3b, 0x62c, 0x648, 0x644, 0x627, 0x626, 0x6cc,
-0x3b, 0x627, 0x6af, 0x633, 0x62a, 0x3b, 0x633, 0x62a, 0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x648, 0x628, 0x631, 0x3b, 0x646,
-0x648, 0x645, 0x628, 0x631, 0x3b, 0x62f, 0x633, 0x645, 0x628, 0x631, 0x3b, 0x73, 0x63, 0x68, 0x61, 0x6e, 0x2e, 0x3b, 0x66, 0x61,
-0x76, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x76, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x74, 0x67, 0x3b, 0x7a,
-0x65, 0x72, 0x63, 0x6c, 0x2e, 0x3b, 0x66, 0x61, 0x6e, 0x2e, 0x3b, 0x61, 0x76, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x74,
-0x74, 0x2e, 0x3b, 0x6f, 0x63, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b, 0x73, 0x63,
-0x68, 0x61, 0x6e, 0x65, 0x72, 0x3b, 0x66, 0x61, 0x76, 0x72, 0x65, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x76,
-0x72, 0x69, 0x67, 0x6c, 0x3b, 0x6d, 0x61, 0x74, 0x67, 0x3b, 0x7a, 0x65, 0x72, 0x63, 0x6c, 0x61, 0x64, 0x75, 0x72, 0x3b,
-0x66, 0x61, 0x6e, 0x61, 0x64, 0x75, 0x72, 0x3b, 0x61, 0x76, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x74, 0x74, 0x65, 0x6d,
-0x62, 0x65, 0x72, 0x3b, 0x6f, 0x63, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72,
-0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x53, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b,
-0x5a, 0x3b, 0x46, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x69, 0x61, 0x6e, 0x2e, 0x3b, 0x66,
-0x65, 0x62, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x2e, 0x3b, 0x61, 0x70, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x69, 0x75,
-0x6e, 0x2e, 0x3b, 0x69, 0x75, 0x6c, 0x2e, 0x3b, 0x61, 0x75, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x2e, 0x3b, 0x6f,
-0x63, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b, 0x69, 0x61, 0x6e, 0x75, 0x61, 0x72,
-0x69, 0x65, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69, 0x65, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x69, 0x65, 0x3b,
-0x61, 0x70, 0x72, 0x69, 0x6c, 0x69, 0x65, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x69, 0x75, 0x6e, 0x69, 0x65, 0x3b, 0x69, 0x75,
-0x6c, 0x69, 0x65, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x69,
-0x65, 0x3b, 0x6f, 0x63, 0x74, 0x6f, 0x6d, 0x62, 0x72, 0x69, 0x65, 0x3b, 0x6e, 0x6f, 0x69, 0x65, 0x6d, 0x62, 0x72, 0x69,
-0x65, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x65, 0x3b, 0x49, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b,
-0x4d, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x42f, 0x43d, 0x432, 0x2e,
-0x3b, 0x424, 0x435, 0x432, 0x440, 0x2e, 0x3b, 0x41c, 0x430, 0x440, 0x442, 0x3b, 0x410, 0x43f, 0x440, 0x2e, 0x3b, 0x41c, 0x430, 0x439,
-0x3b, 0x418, 0x44e, 0x43d, 0x44c, 0x3b, 0x418, 0x44e, 0x43b, 0x44c, 0x3b, 0x410, 0x432, 0x433, 0x2e, 0x3b, 0x421, 0x435, 0x43d, 0x442,
-0x2e, 0x3b, 0x41e, 0x43a, 0x442, 0x2e, 0x3b, 0x41d, 0x43e, 0x44f, 0x431, 0x2e, 0x3b, 0x414, 0x435, 0x43a, 0x2e, 0x3b, 0x42f, 0x3b,
-0x424, 0x3b, 0x41c, 0x3b, 0x410, 0x3b, 0x41c, 0x3b, 0x418, 0x3b, 0x418, 0x3b, 0x410, 0x3b, 0x421, 0x3b, 0x41e, 0x3b, 0x41d, 0x3b,
-0x414, 0x3b, 0x44f, 0x43d, 0x432, 0x2e, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x430, 0x3b, 0x430,
-0x43f, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x44f, 0x3b, 0x438, 0x44e, 0x43d, 0x44f, 0x3b, 0x438, 0x44e, 0x43b, 0x44f, 0x3b, 0x430, 0x432,
-0x433, 0x2e, 0x3b, 0x441, 0x435, 0x43d, 0x442, 0x2e, 0x3b, 0x43e, 0x43a, 0x442, 0x2e, 0x3b, 0x43d, 0x43e, 0x44f, 0x431, 0x2e, 0x3b,
-0x434, 0x435, 0x43a, 0x2e, 0x3b, 0x44f, 0x43d, 0x432, 0x430, 0x440, 0x44f, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x430, 0x43b, 0x44f, 0x3b,
-0x43c, 0x430, 0x440, 0x442, 0x430, 0x3b, 0x430, 0x43f, 0x440, 0x435, 0x43b, 0x44f, 0x3b, 0x43c, 0x430, 0x44f, 0x3b, 0x438, 0x44e, 0x43d,
-0x44f, 0x3b, 0x438, 0x44e, 0x43b, 0x44f, 0x3b, 0x430, 0x432, 0x433, 0x443, 0x441, 0x442, 0x430, 0x3b, 0x441, 0x435, 0x43d, 0x442, 0x44f,
-0x431, 0x440, 0x44f, 0x3b, 0x43e, 0x43a, 0x442, 0x44f, 0x431, 0x440, 0x44f, 0x3b, 0x43d, 0x43e, 0x44f, 0x431, 0x440, 0x44f, 0x3b, 0x434,
-0x435, 0x43a, 0x430, 0x431, 0x440, 0x44f, 0x3b, 0x4e, 0x79, 0x65, 0x3b, 0x46, 0x75, 0x6c, 0x3b, 0x4d, 0x62, 0xe4, 0x3b, 0x4e,
-0x67, 0x75, 0x3b, 0x42, 0xea, 0x6c, 0x3b, 0x46, 0xf6, 0x6e, 0x3b, 0x4c, 0x65, 0x6e, 0x3b, 0x4b, 0xfc, 0x6b, 0x3b, 0x4d,
-0x76, 0x75, 0x3b, 0x4e, 0x67, 0x62, 0x3b, 0x4e, 0x61, 0x62, 0x3b, 0x4b, 0x61, 0x6b, 0x3b, 0x4e, 0x79, 0x65, 0x6e, 0x79,
-0x65, 0x3b, 0x46, 0x75, 0x6c, 0x75, 0x6e, 0x64, 0xef, 0x67, 0x69, 0x3b, 0x4d, 0x62, 0xe4, 0x6e, 0x67, 0xfc, 0x3b, 0x4e,
-0x67, 0x75, 0x62, 0xf9, 0x65, 0x3b, 0x42, 0xea, 0x6c, 0xe4, 0x77, 0xfc, 0x3b, 0x46, 0xf6, 0x6e, 0x64, 0x6f, 0x3b, 0x4c,
-0x65, 0x6e, 0x67, 0x75, 0x61, 0x3b, 0x4b, 0xfc, 0x6b, 0xfc, 0x72, 0xfc, 0x3b, 0x4d, 0x76, 0x75, 0x6b, 0x61, 0x3b, 0x4e,
-0x67, 0x62, 0x65, 0x72, 0x65, 0x72, 0x65, 0x3b, 0x4e, 0x61, 0x62, 0xe4, 0x6e, 0x64, 0xfc, 0x72, 0x75, 0x3b, 0x4b, 0x61,
-0x6b, 0x61, 0x75, 0x6b, 0x61, 0x3b, 0x4e, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x4e, 0x3b, 0x42, 0x3b, 0x46, 0x3b, 0x4c, 0x3b,
-0x4b, 0x3b, 0x4d, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4b, 0x3b, 0x458, 0x430, 0x43d, 0x3b, 0x444, 0x435, 0x431, 0x3b, 0x43c, 0x430,
-0x440, 0x3b, 0x430, 0x43f, 0x440, 0x3b, 0x43c, 0x430, 0x458, 0x3b, 0x458, 0x443, 0x43d, 0x3b, 0x458, 0x443, 0x43b, 0x3b, 0x430, 0x432,
-0x433, 0x3b, 0x441, 0x435, 0x43f, 0x3b, 0x43e, 0x43a, 0x442, 0x3b, 0x43d, 0x43e, 0x432, 0x3b, 0x434, 0x435, 0x446, 0x3b, 0x458, 0x430,
-0x43d, 0x443, 0x430, 0x440, 0x3b, 0x444, 0x435, 0x431, 0x440, 0x443, 0x430, 0x440, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x3b, 0x430, 0x43f,
-0x440, 0x438, 0x43b, 0x3b, 0x43c, 0x430, 0x458, 0x3b, 0x458, 0x443, 0x43d, 0x3b, 0x458, 0x443, 0x43b, 0x3b, 0x430, 0x432, 0x433, 0x443,
-0x441, 0x442, 0x3b, 0x441, 0x435, 0x43f, 0x442, 0x435, 0x43c, 0x431, 0x430, 0x440, 0x3b, 0x43e, 0x43a, 0x442, 0x43e, 0x431, 0x430, 0x440,
-0x3b, 0x43d, 0x43e, 0x432, 0x435, 0x43c, 0x431, 0x430, 0x440, 0x3b, 0x434, 0x435, 0x446, 0x435, 0x43c, 0x431, 0x430, 0x440, 0x3b, 0x458,
-0x430, 0x43d, 0x443, 0x430, 0x440, 0x3b, 0x444, 0x435, 0x431, 0x440, 0x443, 0x430, 0x440, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x3b, 0x430,
-0x43f, 0x440, 0x438, 0x43b, 0x3b, 0x43c, 0x430, 0x458, 0x3b, 0x458, 0x443, 0x43d, 0x438, 0x3b, 0x458, 0x443, 0x43b, 0x438, 0x3b, 0x430,
-0x432, 0x433, 0x443, 0x441, 0x442, 0x3b, 0x441, 0x435, 0x43f, 0x442, 0x435, 0x43c, 0x431, 0x430, 0x440, 0x3b, 0x43e, 0x43a, 0x442, 0x43e,
-0x431, 0x430, 0x440, 0x3b, 0x43d, 0x43e, 0x432, 0x435, 0x43c, 0x431, 0x430, 0x440, 0x3b, 0x434, 0x435, 0x446, 0x435, 0x43c, 0x431, 0x430,
-0x440, 0x3b, 0x6a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x61,
-0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x3b, 0x6a, 0x75, 0x6c, 0x3b, 0x61, 0x76, 0x67, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x6b,
-0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x65, 0x63, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x66, 0x65, 0x62,
-0x72, 0x75, 0x61, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x6a, 0x3b,
-0x6a, 0x75, 0x6e, 0x3b, 0x6a, 0x75, 0x6c, 0x3b, 0x61, 0x76, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65,
-0x6d, 0x62, 0x61, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61,
-0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x6a, 0x3b, 0x66, 0x3b, 0x6d, 0x3b, 0x61, 0x3b, 0x6d,
-0x3b, 0x6a, 0x3b, 0x6a, 0x3b, 0x61, 0x3b, 0x73, 0x3b, 0x6f, 0x3b, 0x6e, 0x3b, 0x64, 0x3b, 0x42f, 0x43d, 0x432, 0x430, 0x440,
-0x44c, 0x3b, 0x424, 0x435, 0x432, 0x440, 0x430, 0x43b, 0x44c, 0x3b, 0x41c, 0x430, 0x440, 0x442, 0x44a, 0x438, 0x3b, 0x410, 0x43f, 0x440,
-0x435, 0x43b, 0x44c, 0x3b, 0x41c, 0x430, 0x439, 0x3b, 0x418, 0x44e, 0x43d, 0x44c, 0x3b, 0x418, 0x44e, 0x43b, 0x44c, 0x3b, 0x410, 0x432,
-0x433, 0x443, 0x441, 0x442, 0x3b, 0x421, 0x435, 0x43d, 0x442, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x41e, 0x43a, 0x442, 0x44f, 0x431, 0x440,
-0x44c, 0x3b, 0x41d, 0x43e, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x414, 0x435, 0x43a, 0x430, 0x431, 0x440, 0x44c, 0x3b, 0x44f, 0x43d, 0x432,
-0x2e, 0x3b, 0x444, 0x435, 0x432, 0x2e, 0x3b, 0x43c, 0x430, 0x440, 0x2e, 0x3b, 0x430, 0x43f, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x44f,
-0x3b, 0x438, 0x44e, 0x43d, 0x44b, 0x3b, 0x438, 0x44e, 0x43b, 0x44b, 0x3b, 0x430, 0x432, 0x433, 0x2e, 0x3b, 0x441, 0x435, 0x43d, 0x2e,
-0x3b, 0x43e, 0x43a, 0x442, 0x2e, 0x3b, 0x43d, 0x43e, 0x44f, 0x2e, 0x3b, 0x434, 0x435, 0x43a, 0x2e, 0x3b, 0x44f, 0x43d, 0x432, 0x430,
-0x440, 0x44b, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x430, 0x43b, 0x44b, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x44a, 0x438, 0x439, 0x44b, 0x3b,
-0x430, 0x43f, 0x440, 0x435, 0x43b, 0x44b, 0x3b, 0x43c, 0x430, 0x439, 0x44b, 0x3b, 0x438, 0x44e, 0x43d, 0x44b, 0x3b, 0x438, 0x44e, 0x43b,
-0x44b, 0x3b, 0x430, 0x432, 0x433, 0x443, 0x441, 0x442, 0x44b, 0x3b, 0x441, 0x435, 0x43d, 0x442, 0x44f, 0x431, 0x440, 0x44b, 0x3b, 0x43e,
-0x43a, 0x442, 0x44f, 0x431, 0x440, 0x44b, 0x3b, 0x43d, 0x43e, 0x44f, 0x431, 0x440, 0x44b, 0x3b, 0x434, 0x435, 0x43a, 0x430, 0x431, 0x440,
-0x44b, 0x3b, 0x50, 0x68, 0x65, 0x3b, 0x4b, 0x6f, 0x6c, 0x3b, 0x55, 0x62, 0x65, 0x3b, 0x4d, 0x6d, 0x65, 0x3b, 0x4d, 0x6f,
-0x74, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x55, 0x70, 0x75, 0x3b, 0x50, 0x68, 0x61, 0x3b, 0x4c, 0x65, 0x6f, 0x3b, 0x4d, 0x70,
-0x68, 0x3b, 0x50, 0x75, 0x6e, 0x3b, 0x54, 0x73, 0x68, 0x3b, 0x50, 0x68, 0x65, 0x73, 0x65, 0x6b, 0x67, 0x6f, 0x6e, 0x67,
-0x3b, 0x48, 0x6c, 0x61, 0x6b, 0x6f, 0x6c, 0x61, 0x3b, 0x48, 0x6c, 0x61, 0x6b, 0x75, 0x62, 0x65, 0x6c, 0x65, 0x3b, 0x4d,
-0x6d, 0x65, 0x73, 0x65, 0x3b, 0x4d, 0x6f, 0x74, 0x73, 0x68, 0x65, 0x61, 0x6e, 0x6f, 0x6e, 0x67, 0x3b, 0x50, 0x68, 0x75,
-0x70, 0x6a, 0x61, 0x6e, 0x65, 0x3b, 0x50, 0x68, 0x75, 0x70, 0x75, 0x3b, 0x50, 0x68, 0x61, 0x74, 0x61, 0x3b, 0x4c, 0x65,
-0x6f, 0x74, 0x73, 0x68, 0x65, 0x3b, 0x4d, 0x70, 0x68, 0x61, 0x6c, 0x61, 0x6e, 0x65, 0x3b, 0x50, 0x75, 0x6e, 0x64, 0x75,
-0x6e, 0x67, 0x77, 0x61, 0x6e, 0x65, 0x3b, 0x54, 0x73, 0x68, 0x69, 0x74, 0x77, 0x65, 0x3b, 0x46, 0x65, 0x72, 0x3b, 0x54,
-0x6c, 0x68, 0x3b, 0x4d, 0x6f, 0x70, 0x3b, 0x4d, 0x6f, 0x72, 0x3b, 0x4d, 0x6f, 0x74, 0x3b, 0x53, 0x65, 0x65, 0x3b, 0x50,
-0x68, 0x75, 0x3b, 0x50, 0x68, 0x61, 0x3b, 0x4c, 0x77, 0x65, 0x3b, 0x44, 0x69, 0x70, 0x3b, 0x4e, 0x67, 0x77, 0x3b, 0x53,
-0x65, 0x64, 0x3b, 0x46, 0x65, 0x72, 0x69, 0x6b, 0x67, 0x6f, 0x6e, 0x67, 0x3b, 0x54, 0x6c, 0x68, 0x61, 0x6b, 0x6f, 0x6c,
-0x65, 0x3b, 0x4d, 0x6f, 0x70, 0x69, 0x74, 0x6c, 0x6f, 0x3b, 0x4d, 0x6f, 0x72, 0x61, 0x6e, 0x61, 0x6e, 0x67, 0x3b, 0x4d,
-0x6f, 0x74, 0x73, 0x68, 0x65, 0x67, 0x61, 0x6e, 0x61, 0x6e, 0x67, 0x3b, 0x53, 0x65, 0x65, 0x74, 0x65, 0x62, 0x6f, 0x73,
-0x69, 0x67, 0x6f, 0x3b, 0x50, 0x68, 0x75, 0x6b, 0x77, 0x69, 0x3b, 0x50, 0x68, 0x61, 0x74, 0x77, 0x65, 0x3b, 0x4c, 0x77,
-0x65, 0x74, 0x73, 0x65, 0x3b, 0x44, 0x69, 0x70, 0x68, 0x61, 0x6c, 0x61, 0x6e, 0x65, 0x3b, 0x4e, 0x67, 0x77, 0x61, 0x6e,
-0x61, 0x74, 0x73, 0x65, 0x6c, 0x65, 0x3b, 0x53, 0x65, 0x64, 0x69, 0x6d, 0x6f, 0x6e, 0x74, 0x68, 0x6f, 0x6c, 0x65, 0x3b,
-0x4e, 0x64, 0x69, 0x3b, 0x4b, 0x75, 0x6b, 0x3b, 0x4b, 0x75, 0x72, 0x3b, 0x4b, 0x75, 0x62, 0x3b, 0x43, 0x68, 0x76, 0x3b,
-0x43, 0x68, 0x6b, 0x3b, 0x43, 0x68, 0x67, 0x3b, 0x4e, 0x79, 0x61, 0x3b, 0x47, 0x75, 0x6e, 0x3b, 0x47, 0x75, 0x6d, 0x3b,
-0x4d, 0x62, 0x3b, 0x5a, 0x76, 0x69, 0x3b, 0x4e, 0x64, 0x69, 0x72, 0x61, 0x3b, 0x4b, 0x75, 0x6b, 0x61, 0x64, 0x7a, 0x69,
-0x3b, 0x4b, 0x75, 0x72, 0x75, 0x6d, 0x65, 0x3b, 0x4b, 0x75, 0x62, 0x76, 0x75, 0x6d, 0x62, 0x69, 0x3b, 0x43, 0x68, 0x69,
-0x76, 0x61, 0x62, 0x76, 0x75, 0x3b, 0x43, 0x68, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x43, 0x68, 0x69, 0x6b, 0x75, 0x6e,
-0x67, 0x75, 0x72, 0x75, 0x3b, 0x4e, 0x79, 0x61, 0x6d, 0x61, 0x76, 0x68, 0x75, 0x76, 0x68, 0x75, 0x3b, 0x47, 0x75, 0x6e,
-0x79, 0x61, 0x6e, 0x61, 0x3b, 0x47, 0x75, 0x6d, 0x69, 0x67, 0x75, 0x72, 0x75, 0x3b, 0x4d, 0x62, 0x75, 0x64, 0x7a, 0x69,
-0x3b, 0x5a, 0x76, 0x69, 0x74, 0x61, 0x3b, 0x4e, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x43, 0x3b, 0x43, 0x3b, 0x43,
-0x3b, 0x4e, 0x3b, 0x47, 0x3b, 0x47, 0x3b, 0x4d, 0x3b, 0x5a, 0x3b, 0xda2, 0xdb1, 0x3b, 0xdb4, 0xdd9, 0xdb6, 0x3b, 0xdb8, 0xdcf,
-0xdbb, 0xdca, 0x3b, 0xd85, 0xdb4, 0xdca, 0x200d, 0xdbb, 0xdda, 0xdbd, 0xdca, 0x3b, 0xdb8, 0xdd0, 0xdba, 0xdd2, 0x3b, 0xda2, 0xdd6, 0xdb1,
-0xdd2, 0x3b, 0xda2, 0xdd6, 0xdbd, 0xdd2, 0x3b, 0xd85, 0xd9c, 0xddd, 0x3b, 0xdc3, 0xdd0, 0xdb4, 0xdca, 0x3b, 0xd94, 0xd9a, 0xdca, 0x3b,
-0xdb1, 0xddc, 0xdc0, 0xdd0, 0x3b, 0xdaf, 0xdd9, 0xdc3, 0xdd0, 0x3b, 0xda2, 0xdb1, 0xdc0, 0xdcf, 0xdbb, 0xdd2, 0x3b, 0xdb4, 0xdd9, 0xdb6,
-0xdbb, 0xdc0, 0xdcf, 0xdbb, 0xdd2, 0x3b, 0xdb8, 0xdcf, 0xdbb, 0xdca, 0xdad, 0xdd4, 0x3b, 0xd85, 0xdb4, 0xdca, 0x200d, 0xdbb, 0xdda, 0xdbd,
-0xdca, 0x3b, 0xdb8, 0xdd0, 0xdba, 0xdd2, 0x3b, 0xda2, 0xdd6, 0xdb1, 0xdd2, 0x3b, 0xda2, 0xdd6, 0xdbd, 0xdd2, 0x3b, 0xd85, 0xd9c, 0xddd,
-0xdc3, 0xdca, 0xdad, 0xdd4, 0x3b, 0xdc3, 0xdd0, 0xdb4, 0xdca, 0xdad, 0xdd0, 0xdb8, 0xdca, 0xdb6, 0xdbb, 0xdca, 0x3b, 0xd94, 0xd9a, 0xdca,
-0xdad, 0xddd, 0xdb6, 0xdbb, 0xdca, 0x3b, 0xdb1, 0xddc, 0xdc0, 0xdd0, 0xdb8, 0xdca, 0xdb6, 0xdbb, 0xdca, 0x3b, 0xdaf, 0xdd9, 0xdc3, 0xdd0,
-0xdb8, 0xdca, 0xdb6, 0xdbb, 0xdca, 0x3b, 0xda2, 0x3b, 0xdb4, 0xdd9, 0x3b, 0xdb8, 0xdcf, 0x3b, 0xd85, 0x3b, 0xdb8, 0xdd0, 0x3b, 0xda2,
-0xdd6, 0x3b, 0xda2, 0xdd6, 0x3b, 0xd85, 0x3b, 0xdc3, 0xdd0, 0x3b, 0xd94, 0x3b, 0xdb1, 0xdd9, 0x3b, 0xdaf, 0xdd9, 0x3b, 0xda2, 0xdb1,
-0x3b, 0xdb4, 0xdd9, 0xdb6, 0x3b, 0xdb8, 0xdcf, 0xdbb, 0xdca, 0xdad, 0xdd4, 0x3b, 0xd85, 0xdb4, 0xdca, 0x200d, 0xdbb, 0xdda, 0xdbd, 0xdca,
-0x3b, 0xdb8, 0xdd0, 0xdba, 0xdd2, 0x3b, 0xda2, 0xdd6, 0xdb1, 0xdd2, 0x3b, 0xda2, 0xdd6, 0xdbd, 0xdd2, 0x3b, 0xd85, 0xd9c, 0xddd, 0x3b,
-0xdc3, 0xdd0, 0xdb4, 0xdca, 0x3b, 0xd94, 0xd9a, 0xdca, 0x3b, 0xdb1, 0xddc, 0xdc0, 0xdd0, 0x3b, 0xdaf, 0xdd9, 0xdc3, 0xdd0, 0x3b, 0x42,
-0x68, 0x69, 0x3b, 0x56, 0x61, 0x6e, 0x3b, 0x56, 0x6f, 0x6c, 0x3b, 0x4d, 0x61, 0x62, 0x3b, 0x4e, 0x6b, 0x68, 0x3b, 0x4e,
-0x68, 0x6c, 0x3b, 0x4b, 0x68, 0x6f, 0x3b, 0x4e, 0x67, 0x63, 0x3b, 0x4e, 0x79, 0x6f, 0x3b, 0x4d, 0x70, 0x68, 0x3b, 0x4c,
-0x77, 0x65, 0x3b, 0x4e, 0x67, 0x6f, 0x3b, 0x42, 0x68, 0x69, 0x6d, 0x62, 0x69, 0x64, 0x76, 0x77, 0x61, 0x6e, 0x65, 0x3b,
-0x69, 0x4e, 0x64, 0x6c, 0x6f, 0x76, 0x61, 0x6e, 0x61, 0x3b, 0x69, 0x4e, 0x64, 0x6c, 0x6f, 0x76, 0x75, 0x2d, 0x6c, 0x65,
-0x6e, 0x6b, 0x68, 0x75, 0x6c, 0x75, 0x3b, 0x4d, 0x61, 0x62, 0x61, 0x73, 0x61, 0x3b, 0x69, 0x4e, 0x6b, 0x68, 0x77, 0x65,
-0x6b, 0x68, 0x77, 0x65, 0x74, 0x69, 0x3b, 0x69, 0x4e, 0x68, 0x6c, 0x61, 0x62, 0x61, 0x3b, 0x4b, 0x68, 0x6f, 0x6c, 0x77,
-0x61, 0x6e, 0x65, 0x3b, 0x69, 0x4e, 0x67, 0x63, 0x69, 0x3b, 0x69, 0x4e, 0x79, 0x6f, 0x6e, 0x69, 0x3b, 0x69, 0x4d, 0x70,
-0x68, 0x61, 0x6c, 0x61, 0x3b, 0x4c, 0x77, 0x65, 0x74, 0x69, 0x3b, 0x69, 0x4e, 0x67, 0x6f, 0x6e, 0x67, 0x6f, 0x6e, 0x69,
-0x3b, 0x6a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0xe1, 0x6a,
-0x3b, 0x6a, 0xfa, 0x6e, 0x3b, 0x6a, 0xfa, 0x6c, 0x3b, 0x61, 0x75, 0x67, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x6b, 0x74,
-0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x65, 0x63, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0xe1, 0x72, 0x3b, 0x66, 0x65, 0x62, 0x72,
-0x75, 0xe1, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x65, 0x63, 0x3b, 0x61, 0x70, 0x72, 0xed, 0x6c, 0x3b, 0x6d, 0xe1, 0x6a, 0x3b,
-0x6a, 0xfa, 0x6e, 0x3b, 0x6a, 0xfa, 0x6c, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65,
-0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0xf3, 0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65,
-0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x66, 0x65,
-0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x65, 0x63, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61,
-0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x6a, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x6a, 0x3b, 0x61, 0x76, 0x67, 0x75, 0x73, 0x74,
+0x3b, 0xfe8f, 0x3b, 0xfea9, 0x3b, 0x570, 0x576, 0x57e, 0x3b, 0x583, 0x57f, 0x57e, 0x3b, 0x574, 0x580, 0x57f, 0x3b, 0x561, 0x57a, 0x580,
+0x3b, 0x574, 0x575, 0x57d, 0x3b, 0x570, 0x576, 0x57d, 0x3b, 0x570, 0x56c, 0x57d, 0x3b, 0x585, 0x563, 0x57d, 0x3b, 0x57d, 0x565, 0x57a,
+0x3b, 0x570, 0x578, 0x56f, 0x3b, 0x576, 0x578, 0x575, 0x3b, 0x564, 0x565, 0x56f, 0x3b, 0x570, 0x578, 0x582, 0x576, 0x57e, 0x561, 0x580,
+0x56b, 0x3b, 0x583, 0x565, 0x57f, 0x580, 0x57e, 0x561, 0x580, 0x56b, 0x3b, 0x574, 0x561, 0x580, 0x57f, 0x56b, 0x3b, 0x561, 0x57a, 0x580,
+0x56b, 0x56c, 0x56b, 0x3b, 0x574, 0x561, 0x575, 0x56b, 0x57d, 0x56b, 0x3b, 0x570, 0x578, 0x582, 0x576, 0x56b, 0x57d, 0x56b, 0x3b, 0x570,
+0x578, 0x582, 0x56c, 0x56b, 0x57d, 0x56b, 0x3b, 0x585, 0x563, 0x578, 0x57d, 0x57f, 0x578, 0x57d, 0x56b, 0x3b, 0x57d, 0x565, 0x57a, 0x57f,
+0x565, 0x574, 0x562, 0x565, 0x580, 0x56b, 0x3b, 0x570, 0x578, 0x56f, 0x57f, 0x565, 0x574, 0x562, 0x565, 0x580, 0x56b, 0x3b, 0x576, 0x578,
+0x575, 0x565, 0x574, 0x562, 0x565, 0x580, 0x56b, 0x3b, 0x564, 0x565, 0x56f, 0x57f, 0x565, 0x574, 0x562, 0x565, 0x580, 0x56b, 0x3b, 0x540,
+0x3b, 0x553, 0x3b, 0x544, 0x3b, 0x531, 0x3b, 0x544, 0x3b, 0x540, 0x3b, 0x540, 0x3b, 0x555, 0x3b, 0x54d, 0x3b, 0x540, 0x3b, 0x546,
+0x3b, 0x534, 0x3b, 0x99c, 0x9be, 0x9a8, 0x9c1, 0x3b, 0x9ab, 0x9c7, 0x9ac, 0x9cd, 0x9f0, 0x9c1, 0x3b, 0x9ae, 0x9be, 0x9f0, 0x9cd, 0x99a,
+0x3b, 0x98f, 0x9aa, 0x9cd, 0x9f0, 0x9bf, 0x9b2, 0x3b, 0x9ae, 0x9c7, 0x3b, 0x99c, 0x9c1, 0x9a8, 0x3b, 0x99c, 0x9c1, 0x9b2, 0x9be, 0x987,
+0x3b, 0x986, 0x997, 0x3b, 0x9b8, 0x9c7, 0x9aa, 0x9cd, 0x99f, 0x3b, 0x985, 0x995, 0x9cd, 0x99f, 0x9cb, 0x3b, 0x9a8, 0x9ad, 0x9c7, 0x3b,
+0x9a1, 0x9bf, 0x9b8, 0x9c7, 0x3b, 0x99c, 0x9be, 0x9a8, 0x9c1, 0x9f1, 0x9be, 0x9f0, 0x9c0, 0x3b, 0x9ab, 0x9c7, 0x9ac, 0x9cd, 0x9f0, 0x9c1,
+0x9f1, 0x9be, 0x9f0, 0x9c0, 0x3b, 0x9ae, 0x9be, 0x9f0, 0x9cd, 0x99a, 0x3b, 0x98f, 0x9aa, 0x9cd, 0x9f0, 0x9bf, 0x9b2, 0x3b, 0x9ae, 0x9c7,
+0x3b, 0x99c, 0x9c1, 0x9a8, 0x3b, 0x99c, 0x9c1, 0x9b2, 0x9be, 0x987, 0x3b, 0x986, 0x997, 0x9b7, 0x9cd, 0x99f, 0x3b, 0x99b, 0x9c7, 0x9aa,
+0x9cd, 0x9a4, 0x9c7, 0x9ae, 0x9cd, 0x9ac, 0x9f0, 0x3b, 0x985, 0x995, 0x9cd, 0x99f, 0x9cb, 0x9ac, 0x9f0, 0x3b, 0x9a8, 0x9f1, 0x9c7, 0x9ae,
+0x9cd, 0x9ac, 0x9f0, 0x3b, 0x9a1, 0x9bf, 0x99a, 0x9c7, 0x9ae, 0x9cd, 0x9ac, 0x9f0, 0x3b, 0x79, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x76,
+0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x61, 0x79, 0x3b, 0x69, 0x79, 0x6e, 0x3b, 0x69, 0x79, 0x6c,
+0x3b, 0x61, 0x76, 0x71, 0x3b, 0x73, 0x65, 0x6e, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0x6f, 0x79, 0x3b, 0x64, 0x65, 0x6b,
+0x3b, 0x59, 0x61, 0x6e, 0x76, 0x61, 0x72, 0x3b, 0x46, 0x65, 0x76, 0x72, 0x61, 0x6c, 0x3b, 0x4d, 0x61, 0x72, 0x74, 0x3b,
+0x41, 0x70, 0x72, 0x65, 0x6c, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x130, 0x79, 0x75, 0x6e, 0x3b, 0x130, 0x79, 0x75, 0x6c, 0x3b,
+0x41, 0x76, 0x71, 0x75, 0x73, 0x74, 0x3b, 0x53, 0x65, 0x6e, 0x74, 0x79, 0x61, 0x62, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x79,
+0x61, 0x62, 0x72, 0x3b, 0x4e, 0x6f, 0x79, 0x61, 0x62, 0x72, 0x3b, 0x44, 0x65, 0x6b, 0x61, 0x62, 0x72, 0x3b, 0x458, 0x430,
+0x43d, 0x432, 0x430, 0x440, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x430, 0x43b, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x3b, 0x430, 0x43f, 0x440,
+0x435, 0x43b, 0x3b, 0x43c, 0x430, 0x439, 0x3b, 0x438, 0x458, 0x443, 0x43d, 0x3b, 0x438, 0x458, 0x443, 0x43b, 0x3b, 0x430, 0x432, 0x433,
+0x443, 0x441, 0x442, 0x3b, 0x441, 0x435, 0x43d, 0x442, 0x458, 0x430, 0x431, 0x440, 0x3b, 0x43e, 0x43a, 0x442, 0x458, 0x430, 0x431, 0x440,
+0x3b, 0x43d, 0x43e, 0x458, 0x430, 0x431, 0x440, 0x3b, 0x434, 0x435, 0x43a, 0x430, 0x431, 0x440, 0x3b, 0x75, 0x72, 0x74, 0x3b, 0x6f,
+0x74, 0x73, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x69, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x65, 0x6b, 0x61, 0x3b, 0x75,
+0x7a, 0x74, 0x3b, 0x61, 0x62, 0x75, 0x3b, 0x69, 0x72, 0x61, 0x3b, 0x75, 0x72, 0x72, 0x3b, 0x61, 0x7a, 0x61, 0x3b, 0x61,
+0x62, 0x65, 0x3b, 0x75, 0x72, 0x74, 0x61, 0x72, 0x72, 0x69, 0x6c, 0x61, 0x3b, 0x6f, 0x74, 0x73, 0x61, 0x69, 0x6c, 0x61,
+0x3b, 0x6d, 0x61, 0x72, 0x74, 0x78, 0x6f, 0x61, 0x3b, 0x61, 0x70, 0x69, 0x72, 0x69, 0x6c, 0x61, 0x3b, 0x6d, 0x61, 0x69,
+0x61, 0x74, 0x7a, 0x61, 0x3b, 0x65, 0x6b, 0x61, 0x69, 0x6e, 0x61, 0x3b, 0x75, 0x7a, 0x74, 0x61, 0x69, 0x6c, 0x61, 0x3b,
+0x61, 0x62, 0x75, 0x7a, 0x74, 0x75, 0x61, 0x3b, 0x69, 0x72, 0x61, 0x69, 0x6c, 0x61, 0x3b, 0x75, 0x72, 0x72, 0x69, 0x61,
+0x3b, 0x61, 0x7a, 0x61, 0x72, 0x6f, 0x61, 0x3b, 0x61, 0x62, 0x65, 0x6e, 0x64, 0x75, 0x61, 0x3b, 0x55, 0x3b, 0x4f, 0x3b,
+0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x45, 0x3b, 0x55, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x55, 0x3b, 0x41, 0x3b, 0x41, 0x3b,
+0x99c, 0x9be, 0x9a8, 0x9c1, 0x9af, 0x9bc, 0x9be, 0x9b0, 0x9c0, 0x3b, 0x9ab, 0x9c7, 0x9ac, 0x9cd, 0x9b0, 0x9c1, 0x9af, 0x9bc, 0x9be, 0x9b0,
+0x9c0, 0x3b, 0x9ae, 0x9be, 0x9b0, 0x9cd, 0x99a, 0x3b, 0x98f, 0x9aa, 0x9cd, 0x9b0, 0x9bf, 0x9b2, 0x3b, 0x9ae, 0x9c7, 0x3b, 0x99c, 0x9c1,
+0x9a8, 0x3b, 0x99c, 0x9c1, 0x9b2, 0x9be, 0x987, 0x3b, 0x986, 0x997, 0x9b8, 0x9cd, 0x99f, 0x3b, 0x9b8, 0x9c7, 0x9aa, 0x9cd, 0x99f, 0x9c7,
+0x9ae, 0x9cd, 0x9ac, 0x9b0, 0x3b, 0x985, 0x995, 0x9cd, 0x99f, 0x9cb, 0x9ac, 0x9b0, 0x3b, 0x9a8, 0x9ad, 0x9c7, 0x9ae, 0x9cd, 0x9ac, 0x9b0,
+0x3b, 0x9a1, 0x9bf, 0x9b8, 0x9c7, 0x9ae, 0x9cd, 0x9ac, 0x9b0, 0x3b, 0x99c, 0x9be, 0x3b, 0x9ab, 0x9c7, 0x3b, 0x9ae, 0x9be, 0x3b, 0x98f,
+0x3b, 0x9ae, 0x9c7, 0x3b, 0x99c, 0x9c1, 0x9a8, 0x3b, 0x99c, 0x9c1, 0x3b, 0x986, 0x3b, 0x9b8, 0x9c7, 0x3b, 0x985, 0x3b, 0x9a8, 0x3b,
+0x9a1, 0x9bf, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf21, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf22, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf23, 0x3b, 0xf5f, 0xfb3,
+0xf0b, 0xf24, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf25, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf26, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf27, 0x3b, 0xf5f, 0xfb3,
+0xf0b, 0xf28, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf29, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf21, 0xf20, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf21, 0xf21, 0x3b,
+0xf5f, 0xfb3, 0xf0b, 0xf21, 0xf22, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf51, 0xf44, 0xf54, 0xf0b, 0x3b, 0xf66,
+0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf42, 0xf49, 0xf72, 0xf66, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b,
+0xf5f, 0xfb3, 0xf0b, 0xf42, 0xf66, 0xf74, 0xf58, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56,
+0xf5e, 0xf72, 0xf0b, 0xf54, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf63, 0xf94, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf66,
+0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf51, 0xfb2, 0xf74, 0xf42, 0xf0b, 0xf54, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f,
+0xfb3, 0xf0b, 0xf56, 0xf51, 0xf74, 0xf53, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf62,
+0xf92, 0xfb1, 0xf51, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf51, 0xf42, 0xf74, 0xf0b, 0xf54,
+0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1, 0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1,
+0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf42, 0xf45, 0xf72, 0xf42, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xfb1,
+0xf72, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf42, 0xf49, 0xf72, 0xf66, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf21, 0x3b, 0xf22,
+0x3b, 0xf23, 0x3b, 0xf24, 0x3b, 0xf25, 0x3b, 0xf26, 0x3b, 0xf27, 0x3b, 0xf28, 0x3b, 0xf29, 0x3b, 0xf21, 0xf20, 0x3b, 0xf21, 0xf21,
+0x3b, 0xf21, 0xf22, 0x3b, 0xf21, 0x3b, 0xf22, 0x3b, 0xf23, 0x3b, 0xf24, 0x3b, 0xf25, 0x3b, 0xf26, 0x3b, 0xf27, 0x3b, 0xf28, 0x3b,
+0xf29, 0x3b, 0xf21, 0xf20, 0x3b, 0xf21, 0xf21, 0x3b, 0x31, 0x32, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf51, 0xf44, 0xf54, 0xf0b, 0x3b, 0xf5f,
+0xfb3, 0xf0b, 0xf42, 0xf49, 0xf72, 0xf66, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf42, 0xf66, 0xf74, 0xf58, 0xf0b, 0xf54, 0xf0b,
+0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf5e, 0xf72, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf63, 0xf94, 0xf0b, 0xf54, 0xf0b, 0x3b,
+0xf5f, 0xfb3, 0xf0b, 0xf51, 0xfb2, 0xf74, 0xf42, 0xf0b, 0xf54, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf51, 0xf74, 0xf53, 0xf0b, 0xf54, 0xf0b,
+0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf62, 0xf92, 0xfb1, 0xf51, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf51, 0xf42, 0xf74, 0xf0b,
+0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b,
+0xf42, 0xf45, 0xf72, 0xf42, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf42, 0xf49, 0xf72, 0xf66, 0xf0b,
+0xf54, 0xf0b, 0x3b, 0xf21, 0x3b, 0xf22, 0x3b, 0xf23, 0x3b, 0x34, 0x3b, 0xf25, 0x3b, 0xf26, 0x3b, 0xf27, 0x3b, 0xf28, 0x3b, 0x39,
+0x3b, 0xf21, 0xf20, 0x3b, 0xf21, 0xf21, 0x3b, 0xf21, 0xf22, 0x3b, 0x47, 0x65, 0x6e, 0x3b, 0x43, 0x2bc, 0x68, 0x77, 0x65, 0x3b,
+0x4d, 0x65, 0x75, 0x72, 0x3b, 0x45, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x65, 0x3b, 0x4d, 0x65, 0x7a, 0x68, 0x3b, 0x47, 0x6f,
+0x75, 0x65, 0x3b, 0x45, 0x6f, 0x73, 0x74, 0x3b, 0x47, 0x77, 0x65, 0x6e, 0x3b, 0x48, 0x65, 0x72, 0x65, 0x3b, 0x44, 0x75,
+0x3b, 0x4b, 0x65, 0x72, 0x3b, 0x47, 0x65, 0x6e, 0x76, 0x65, 0x72, 0x3b, 0x43, 0x2bc, 0x68, 0x77, 0x65, 0x76, 0x72, 0x65,
+0x72, 0x3b, 0x4d, 0x65, 0x75, 0x72, 0x7a, 0x68, 0x3b, 0x45, 0x62, 0x72, 0x65, 0x6c, 0x3b, 0x4d, 0x61, 0x65, 0x3b, 0x4d,
+0x65, 0x7a, 0x68, 0x65, 0x76, 0x65, 0x6e, 0x3b, 0x47, 0x6f, 0x75, 0x65, 0x72, 0x65, 0x3b, 0x45, 0x6f, 0x73, 0x74, 0x3b,
+0x47, 0x77, 0x65, 0x6e, 0x67, 0x6f, 0x6c, 0x6f, 0x3b, 0x48, 0x65, 0x72, 0x65, 0x3b, 0x44, 0x75, 0x3b, 0x4b, 0x65, 0x72,
+0x7a, 0x75, 0x3b, 0x44f, 0x43d, 0x2e, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x3b, 0x430, 0x43f,
+0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x439, 0x3b, 0x44e, 0x43d, 0x438, 0x3b, 0x44e, 0x43b, 0x438, 0x3b, 0x430, 0x432, 0x433, 0x2e, 0x3b,
+0x441, 0x435, 0x43f, 0x442, 0x2e, 0x3b, 0x43e, 0x43a, 0x442, 0x2e, 0x3b, 0x43d, 0x43e, 0x435, 0x43c, 0x2e, 0x3b, 0x434, 0x435, 0x43a,
+0x2e, 0x3b, 0x44f, 0x43d, 0x443, 0x430, 0x440, 0x438, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x443, 0x430, 0x440, 0x438, 0x3b, 0x43c, 0x430,
+0x440, 0x442, 0x3b, 0x430, 0x43f, 0x440, 0x438, 0x43b, 0x3b, 0x43c, 0x430, 0x439, 0x3b, 0x44e, 0x43d, 0x438, 0x3b, 0x44e, 0x43b, 0x438,
+0x3b, 0x430, 0x432, 0x433, 0x443, 0x441, 0x442, 0x3b, 0x441, 0x435, 0x43f, 0x442, 0x435, 0x43c, 0x432, 0x440, 0x438, 0x3b, 0x43e, 0x43a,
+0x442, 0x43e, 0x43c, 0x432, 0x440, 0x438, 0x3b, 0x43d, 0x43e, 0x435, 0x43c, 0x432, 0x440, 0x438, 0x3b, 0x434, 0x435, 0x43a, 0x435, 0x43c,
+0x432, 0x440, 0x438, 0x3b, 0x44f, 0x3b, 0x444, 0x3b, 0x43c, 0x3b, 0x430, 0x3b, 0x43c, 0x3b, 0x44e, 0x3b, 0x44e, 0x3b, 0x430, 0x3b,
+0x441, 0x3b, 0x43e, 0x3b, 0x43d, 0x3b, 0x434, 0x3b, 0x1007, 0x1014, 0x103a, 0x3b, 0x1016, 0x1031, 0x3b, 0x1019, 0x1010, 0x103a, 0x3b, 0x1027,
+0x3b, 0x1019, 0x1031, 0x3b, 0x1007, 0x103d, 0x1014, 0x103a, 0x3b, 0x1007, 0x1030, 0x3b, 0x1029, 0x3b, 0x1005, 0x1000, 0x103a, 0x3b, 0x1021, 0x1031,
+0x102c, 0x1000, 0x103a, 0x3b, 0x1014, 0x102d, 0x102f, 0x3b, 0x1012, 0x102e, 0x3b, 0x1007, 0x1014, 0x103a, 0x1014, 0x101d, 0x102b, 0x101b, 0x102e, 0x3b,
+0x1016, 0x1031, 0x1016, 0x1031, 0x102c, 0x103a, 0x101d, 0x102b, 0x101b, 0x102e, 0x3b, 0x1019, 0x1010, 0x103a, 0x3b, 0x1027, 0x1015, 0x103c, 0x102e, 0x3b,
+0x1019, 0x1031, 0x3b, 0x1007, 0x103d, 0x1014, 0x103a, 0x3b, 0x1007, 0x1030, 0x101c, 0x102d, 0x102f, 0x1004, 0x103a, 0x3b, 0x1029, 0x1002, 0x102f, 0x1010,
+0x103a, 0x3b, 0x1005, 0x1000, 0x103a, 0x1010, 0x1004, 0x103a, 0x1018, 0x102c, 0x3b, 0x1021, 0x1031, 0x102c, 0x1000, 0x103a, 0x1010, 0x102d, 0x102f, 0x1018,
+0x102c, 0x3b, 0x1014, 0x102d, 0x102f, 0x101d, 0x1004, 0x103a, 0x1018, 0x102c, 0x3b, 0x1012, 0x102e, 0x1007, 0x1004, 0x103a, 0x1018, 0x102c, 0x3b, 0x1007,
+0x3b, 0x1016, 0x3b, 0x1019, 0x3b, 0x1027, 0x3b, 0x1019, 0x3b, 0x1007, 0x3b, 0x1007, 0x3b, 0x1029, 0x3b, 0x1005, 0x3b, 0x1021, 0x3b, 0x1014,
+0x3b, 0x1012, 0x3b, 0x441, 0x442, 0x443, 0x3b, 0x43b, 0x44e, 0x442, 0x3b, 0x441, 0x430, 0x43a, 0x3b, 0x43a, 0x440, 0x430, 0x3b, 0x442,
+0x440, 0x430, 0x3b, 0x447, 0x44d, 0x440, 0x3b, 0x43b, 0x456, 0x43f, 0x3b, 0x436, 0x43d, 0x456, 0x3b, 0x432, 0x435, 0x440, 0x3b, 0x43a,
+0x430, 0x441, 0x3b, 0x43b, 0x456, 0x441, 0x3b, 0x441, 0x43d, 0x435, 0x3b, 0x441, 0x442, 0x443, 0x434, 0x437, 0x435, 0x43d, 0x44c, 0x3b,
+0x43b, 0x44e, 0x442, 0x44b, 0x3b, 0x441, 0x430, 0x43a, 0x430, 0x432, 0x456, 0x43a, 0x3b, 0x43a, 0x440, 0x430, 0x441, 0x430, 0x432, 0x456,
+0x43a, 0x3b, 0x442, 0x440, 0x430, 0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x447, 0x44d, 0x440, 0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x43b, 0x456,
+0x43f, 0x435, 0x43d, 0x44c, 0x3b, 0x436, 0x43d, 0x456, 0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x432, 0x435, 0x440, 0x430, 0x441, 0x435, 0x43d,
+0x44c, 0x3b, 0x43a, 0x430, 0x441, 0x442, 0x440, 0x44b, 0x447, 0x43d, 0x456, 0x43a, 0x3b, 0x43b, 0x456, 0x441, 0x442, 0x430, 0x43f, 0x430,
+0x434, 0x3b, 0x441, 0x43d, 0x435, 0x436, 0x430, 0x43d, 0x44c, 0x3b, 0x441, 0x3b, 0x43b, 0x3b, 0x441, 0x3b, 0x43a, 0x3b, 0x43c, 0x3b,
+0x447, 0x3b, 0x43b, 0x3b, 0x436, 0x3b, 0x432, 0x3b, 0x43a, 0x3b, 0x43b, 0x3b, 0x441, 0x3b, 0x441, 0x442, 0x443, 0x3b, 0x43b, 0x44e,
+0x442, 0x3b, 0x441, 0x430, 0x43a, 0x3b, 0x43a, 0x440, 0x430, 0x3b, 0x43c, 0x430, 0x439, 0x3b, 0x447, 0x44d, 0x440, 0x3b, 0x43b, 0x456,
+0x43f, 0x3b, 0x436, 0x43d, 0x456, 0x3b, 0x432, 0x435, 0x440, 0x3b, 0x43a, 0x430, 0x441, 0x3b, 0x43b, 0x456, 0x441, 0x3b, 0x441, 0x43d,
+0x435, 0x3b, 0x441, 0x442, 0x443, 0x434, 0x437, 0x435, 0x43d, 0x44c, 0x3b, 0x43b, 0x44e, 0x442, 0x44b, 0x3b, 0x441, 0x430, 0x43a, 0x430,
+0x432, 0x456, 0x43a, 0x3b, 0x43a, 0x440, 0x430, 0x441, 0x430, 0x432, 0x456, 0x43a, 0x3b, 0x43c, 0x430, 0x439, 0x3b, 0x447, 0x44d, 0x440,
+0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x43b, 0x456, 0x43f, 0x435, 0x43d, 0x44c, 0x3b, 0x436, 0x43d, 0x456, 0x432, 0x435, 0x43d, 0x44c, 0x3b,
+0x432, 0x435, 0x440, 0x430, 0x441, 0x435, 0x43d, 0x44c, 0x3b, 0x43a, 0x430, 0x441, 0x442, 0x440, 0x44b, 0x447, 0x43d, 0x456, 0x43a, 0x3b,
+0x43b, 0x456, 0x441, 0x442, 0x430, 0x43f, 0x430, 0x434, 0x3b, 0x441, 0x43d, 0x435, 0x436, 0x430, 0x43d, 0x44c, 0x3b, 0x441, 0x3b, 0x43b,
+0x3b, 0x441, 0x3b, 0x43a, 0x3b, 0x442, 0x3b, 0x447, 0x3b, 0x43b, 0x3b, 0x436, 0x3b, 0x432, 0x3b, 0x43a, 0x3b, 0x43b, 0x3b, 0x441,
+0x3b, 0x1798, 0x1780, 0x179a, 0x17b6, 0x3b, 0x1780, 0x17bb, 0x1798, 0x17d2, 0x1797, 0x17c8, 0x3b, 0x1798, 0x17b8, 0x1793, 0x17b6, 0x3b, 0x1798, 0x17c1,
+0x179f, 0x17b6, 0x3b, 0x17a7, 0x179f, 0x1797, 0x17b6, 0x3b, 0x1798, 0x17b7, 0x1790, 0x17bb, 0x1793, 0x17b6, 0x3b, 0x1780, 0x1780, 0x17d2, 0x1780, 0x178a,
+0x17b6, 0x3b, 0x179f, 0x17b8, 0x17a0, 0x17b6, 0x3b, 0x1780, 0x1789, 0x17d2, 0x1789, 0x17b6, 0x3b, 0x178f, 0x17bb, 0x179b, 0x17b6, 0x3b, 0x179c, 0x17b7,
+0x1785, 0x17d2, 0x1786, 0x17b7, 0x1780, 0x17b6, 0x3b, 0x1792, 0x17d2, 0x1793, 0x17bc, 0x3b, 0x67, 0x65, 0x6e, 0x2e, 0x3b, 0x66, 0x65, 0x62,
+0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0xe7, 0x3b, 0x61, 0x62, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x69, 0x67, 0x3b, 0x6a, 0x75,
+0x6e, 0x79, 0x3b, 0x6a, 0x75, 0x6c, 0x2e, 0x3b, 0x61, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x74, 0x2e, 0x3b, 0x6f, 0x63, 0x74,
+0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x73, 0x2e, 0x3b, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x3b, 0x66, 0x65,
+0x62, 0x72, 0x65, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0xe7, 0x3b, 0x61, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x69, 0x67,
+0x3b, 0x6a, 0x75, 0x6e, 0x79, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x6f, 0x6c, 0x3b, 0x61, 0x67, 0x6f, 0x73, 0x74, 0x3b, 0x73,
+0x65, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x6f, 0x63, 0x74, 0x75, 0x62, 0x72, 0x65, 0x3b, 0x6e, 0x6f, 0x76, 0x65,
+0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x67, 0x3b, 0x66, 0x3b, 0x6d, 0x3b,
+0x61, 0x3b, 0x6d, 0x3b, 0x6a, 0x3b, 0x6a, 0x3b, 0x61, 0x3b, 0x73, 0x3b, 0x6f, 0x3b, 0x6e, 0x3b, 0x64, 0x3b, 0x64, 0x65,
+0x20, 0x67, 0x65, 0x6e, 0x2e, 0x3b, 0x64, 0x65, 0x20, 0x66, 0x65, 0x62, 0x72, 0x2e, 0x3b, 0x64, 0x65, 0x20, 0x6d, 0x61,
+0x72, 0xe7, 0x3b, 0x64, 0x2019, 0x61, 0x62, 0x72, 0x2e, 0x3b, 0x64, 0x65, 0x20, 0x6d, 0x61, 0x69, 0x67, 0x3b, 0x64, 0x65,
+0x20, 0x6a, 0x75, 0x6e, 0x79, 0x3b, 0x64, 0x65, 0x20, 0x6a, 0x75, 0x6c, 0x2e, 0x3b, 0x64, 0x2019, 0x61, 0x67, 0x2e, 0x3b,
+0x64, 0x65, 0x20, 0x73, 0x65, 0x74, 0x2e, 0x3b, 0x64, 0x2019, 0x6f, 0x63, 0x74, 0x2e, 0x3b, 0x64, 0x65, 0x20, 0x6e, 0x6f,
+0x76, 0x2e, 0x3b, 0x64, 0x65, 0x20, 0x64, 0x65, 0x73, 0x2e, 0x3b, 0x64, 0x65, 0x20, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x3b,
+0x64, 0x65, 0x20, 0x66, 0x65, 0x62, 0x72, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x20, 0x6d, 0x61, 0x72, 0xe7, 0x3b, 0x64, 0x2019,
+0x61, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x64, 0x65, 0x20, 0x6d, 0x61, 0x69, 0x67, 0x3b, 0x64, 0x65, 0x20, 0x6a, 0x75, 0x6e,
+0x79, 0x3b, 0x64, 0x65, 0x20, 0x6a, 0x75, 0x6c, 0x69, 0x6f, 0x6c, 0x3b, 0x64, 0x2019, 0x61, 0x67, 0x6f, 0x73, 0x74, 0x3b,
+0x64, 0x65, 0x20, 0x73, 0x65, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x2019, 0x6f, 0x63, 0x74, 0x75, 0x62, 0x72,
+0x65, 0x3b, 0x64, 0x65, 0x20, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x65, 0x20, 0x64, 0x65, 0x73,
+0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x47, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b,
+0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x31, 0x6708, 0x3b, 0x32, 0x6708, 0x3b, 0x33, 0x6708, 0x3b, 0x34,
+0x6708, 0x3b, 0x35, 0x6708, 0x3b, 0x36, 0x6708, 0x3b, 0x37, 0x6708, 0x3b, 0x38, 0x6708, 0x3b, 0x39, 0x6708, 0x3b, 0x31, 0x30, 0x6708,
+0x3b, 0x31, 0x31, 0x6708, 0x3b, 0x31, 0x32, 0x6708, 0x3b, 0x4e00, 0x6708, 0x3b, 0x4e8c, 0x6708, 0x3b, 0x4e09, 0x6708, 0x3b, 0x56db, 0x6708,
+0x3b, 0x4e94, 0x6708, 0x3b, 0x516d, 0x6708, 0x3b, 0x4e03, 0x6708, 0x3b, 0x516b, 0x6708, 0x3b, 0x4e5d, 0x6708, 0x3b, 0x5341, 0x6708, 0x3b, 0x5341,
+0x4e00, 0x6708, 0x3b, 0x5341, 0x4e8c, 0x6708, 0x3b, 0x73, 0x69, 0x6a, 0x3b, 0x76, 0x65, 0x6c, 0x6a, 0x3b, 0x6f, 0x17e, 0x75, 0x3b,
+0x74, 0x72, 0x61, 0x3b, 0x73, 0x76, 0x69, 0x3b, 0x6c, 0x69, 0x70, 0x3b, 0x73, 0x72, 0x70, 0x3b, 0x6b, 0x6f, 0x6c, 0x3b,
+0x72, 0x75, 0x6a, 0x3b, 0x6c, 0x69, 0x73, 0x3b, 0x73, 0x74, 0x75, 0x3b, 0x70, 0x72, 0x6f, 0x3b, 0x73, 0x69, 0x6a, 0x65,
+0x10d, 0x61, 0x6e, 0x6a, 0x3b, 0x76, 0x65, 0x6c, 0x6a, 0x61, 0x10d, 0x61, 0x3b, 0x6f, 0x17e, 0x75, 0x6a, 0x61, 0x6b, 0x3b,
+0x74, 0x72, 0x61, 0x76, 0x61, 0x6e, 0x6a, 0x3b, 0x73, 0x76, 0x69, 0x62, 0x61, 0x6e, 0x6a, 0x3b, 0x6c, 0x69, 0x70, 0x61,
+0x6e, 0x6a, 0x3b, 0x73, 0x72, 0x70, 0x61, 0x6e, 0x6a, 0x3b, 0x6b, 0x6f, 0x6c, 0x6f, 0x76, 0x6f, 0x7a, 0x3b, 0x72, 0x75,
+0x6a, 0x61, 0x6e, 0x3b, 0x6c, 0x69, 0x73, 0x74, 0x6f, 0x70, 0x61, 0x64, 0x3b, 0x73, 0x74, 0x75, 0x64, 0x65, 0x6e, 0x69,
+0x3b, 0x70, 0x72, 0x6f, 0x73, 0x69, 0x6e, 0x61, 0x63, 0x3b, 0x31, 0x2e, 0x3b, 0x32, 0x2e, 0x3b, 0x33, 0x2e, 0x3b, 0x34,
+0x2e, 0x3b, 0x35, 0x2e, 0x3b, 0x36, 0x2e, 0x3b, 0x37, 0x2e, 0x3b, 0x38, 0x2e, 0x3b, 0x39, 0x2e, 0x3b, 0x31, 0x30, 0x2e,
+0x3b, 0x31, 0x31, 0x2e, 0x3b, 0x31, 0x32, 0x2e, 0x3b, 0x73, 0x69, 0x6a, 0x65, 0x10d, 0x6e, 0x6a, 0x61, 0x3b, 0x76, 0x65,
+0x6c, 0x6a, 0x61, 0x10d, 0x65, 0x3b, 0x6f, 0x17e, 0x75, 0x6a, 0x6b, 0x61, 0x3b, 0x74, 0x72, 0x61, 0x76, 0x6e, 0x6a, 0x61,
+0x3b, 0x73, 0x76, 0x69, 0x62, 0x6e, 0x6a, 0x61, 0x3b, 0x6c, 0x69, 0x70, 0x6e, 0x6a, 0x61, 0x3b, 0x73, 0x72, 0x70, 0x6e,
+0x6a, 0x61, 0x3b, 0x6b, 0x6f, 0x6c, 0x6f, 0x76, 0x6f, 0x7a, 0x61, 0x3b, 0x72, 0x75, 0x6a, 0x6e, 0x61, 0x3b, 0x6c, 0x69,
+0x73, 0x74, 0x6f, 0x70, 0x61, 0x64, 0x61, 0x3b, 0x73, 0x74, 0x75, 0x64, 0x65, 0x6e, 0x6f, 0x67, 0x61, 0x3b, 0x70, 0x72,
+0x6f, 0x73, 0x69, 0x6e, 0x63, 0x61, 0x3b, 0x6c, 0x65, 0x64, 0x3b, 0xfa, 0x6e, 0x6f, 0x3b, 0x62, 0x159, 0x65, 0x3b, 0x64,
+0x75, 0x62, 0x3b, 0x6b, 0x76, 0x11b, 0x3b, 0x10d, 0x76, 0x6e, 0x3b, 0x10d, 0x76, 0x63, 0x3b, 0x73, 0x72, 0x70, 0x3b, 0x7a,
+0xe1, 0x159, 0x3b, 0x159, 0xed, 0x6a, 0x3b, 0x6c, 0x69, 0x73, 0x3b, 0x70, 0x72, 0x6f, 0x3b, 0x6c, 0x65, 0x64, 0x65, 0x6e,
+0x3b, 0xfa, 0x6e, 0x6f, 0x72, 0x3b, 0x62, 0x159, 0x65, 0x7a, 0x65, 0x6e, 0x3b, 0x64, 0x75, 0x62, 0x65, 0x6e, 0x3b, 0x6b,
+0x76, 0x11b, 0x74, 0x65, 0x6e, 0x3b, 0x10d, 0x65, 0x72, 0x76, 0x65, 0x6e, 0x3b, 0x10d, 0x65, 0x72, 0x76, 0x65, 0x6e, 0x65,
+0x63, 0x3b, 0x73, 0x72, 0x70, 0x65, 0x6e, 0x3b, 0x7a, 0xe1, 0x159, 0xed, 0x3b, 0x159, 0xed, 0x6a, 0x65, 0x6e, 0x3b, 0x6c,
+0x69, 0x73, 0x74, 0x6f, 0x70, 0x61, 0x64, 0x3b, 0x70, 0x72, 0x6f, 0x73, 0x69, 0x6e, 0x65, 0x63, 0x3b, 0x6c, 0x3b, 0xfa,
+0x3b, 0x62, 0x3b, 0x64, 0x3b, 0x6b, 0x3b, 0x10d, 0x3b, 0x10d, 0x3b, 0x73, 0x3b, 0x7a, 0x3b, 0x159, 0x3b, 0x6c, 0x3b, 0x70,
+0x3b, 0x6c, 0x65, 0x64, 0x6e, 0x61, 0x3b, 0xfa, 0x6e, 0x6f, 0x72, 0x61, 0x3b, 0x62, 0x159, 0x65, 0x7a, 0x6e, 0x61, 0x3b,
+0x64, 0x75, 0x62, 0x6e, 0x61, 0x3b, 0x6b, 0x76, 0x11b, 0x74, 0x6e, 0x61, 0x3b, 0x10d, 0x65, 0x72, 0x76, 0x6e, 0x61, 0x3b,
+0x10d, 0x65, 0x72, 0x76, 0x65, 0x6e, 0x63, 0x65, 0x3b, 0x73, 0x72, 0x70, 0x6e, 0x61, 0x3b, 0x7a, 0xe1, 0x159, 0xed, 0x3b,
+0x159, 0xed, 0x6a, 0x6e, 0x61, 0x3b, 0x6c, 0x69, 0x73, 0x74, 0x6f, 0x70, 0x61, 0x64, 0x75, 0x3b, 0x70, 0x72, 0x6f, 0x73,
+0x69, 0x6e, 0x63, 0x65, 0x3b, 0x6a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x72,
+0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x3b, 0x6a, 0x75, 0x6c, 0x3b, 0x61, 0x75, 0x67, 0x3b, 0x73, 0x65, 0x70,
+0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x65, 0x63, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b,
+0x66, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x73, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x3b,
+0x6d, 0x61, 0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74,
0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x6e,
0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6a, 0x61, 0x6e,
0x2e, 0x3b, 0x66, 0x65, 0x62, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x2e, 0x3b, 0x61, 0x70, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x6a,
-0x3b, 0x6a, 0x75, 0x6e, 0x2e, 0x3b, 0x6a, 0x75, 0x6c, 0x2e, 0x3b, 0x61, 0x76, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x70, 0x2e,
-0x3b, 0x6f, 0x6b, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b, 0x4b, 0x6f, 0x62, 0x3b,
-0x4c, 0x61, 0x62, 0x3b, 0x53, 0x61, 0x64, 0x3b, 0x41, 0x66, 0x72, 0x3b, 0x53, 0x68, 0x61, 0x3b, 0x4c, 0x69, 0x78, 0x3b,
-0x54, 0x6f, 0x64, 0x3b, 0x53, 0x69, 0x64, 0x3b, 0x53, 0x61, 0x67, 0x3b, 0x54, 0x6f, 0x62, 0x3b, 0x4b, 0x49, 0x54, 0x3b,
-0x4c, 0x49, 0x54, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x4b, 0x6f, 0x6f, 0x62, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69,
-0x73, 0x68, 0x61, 0x20, 0x4c, 0x61, 0x62, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x53, 0x61, 0x64,
-0x64, 0x65, 0x78, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x41, 0x66, 0x72, 0x61, 0x61, 0x64, 0x3b,
-0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x53, 0x68, 0x61, 0x6e, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20,
-0x4c, 0x69, 0x78, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x54, 0x6f, 0x64, 0x6f, 0x62, 0x61, 0x61,
-0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x53, 0x69, 0x64, 0x65, 0x65, 0x64, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69,
-0x73, 0x68, 0x61, 0x20, 0x53, 0x61, 0x67, 0x61, 0x61, 0x6c, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20,
-0x54, 0x6f, 0x62, 0x6e, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x4b, 0x6f, 0x77, 0x20, 0x69, 0x79,
-0x6f, 0x20, 0x54, 0x6f, 0x62, 0x6e, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x4c, 0x61, 0x62, 0x61,
-0x20, 0x69, 0x79, 0x6f, 0x20, 0x54, 0x6f, 0x62, 0x6e, 0x61, 0x61, 0x64, 0x3b, 0x4b, 0x3b, 0x4c, 0x3b, 0x53, 0x3b, 0x41,
-0x3b, 0x53, 0x3b, 0x4c, 0x3b, 0x54, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x54, 0x3b, 0x4b, 0x3b, 0x4c, 0x3b, 0x65, 0x6e, 0x65,
-0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x62, 0x72, 0x3b, 0x6d, 0x61, 0x79, 0x6f, 0x3b, 0x6a, 0x75,
-0x6e, 0x3b, 0x6a, 0x75, 0x6c, 0x3b, 0x61, 0x67, 0x6f, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x63, 0x74, 0x3b, 0x6e, 0x6f,
-0x76, 0x3b, 0x64, 0x69, 0x63, 0x3b, 0x65, 0x6e, 0x65, 0x72, 0x6f, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x65, 0x72, 0x6f, 0x3b,
-0x6d, 0x61, 0x72, 0x7a, 0x6f, 0x3b, 0x61, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x79, 0x6f, 0x3b, 0x6a, 0x75, 0x6e,
-0x69, 0x6f, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x6f, 0x3b, 0x61, 0x67, 0x6f, 0x73, 0x74, 0x6f, 0x3b, 0x73, 0x65, 0x70, 0x74,
-0x69, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x6f, 0x63, 0x74, 0x75, 0x62, 0x72, 0x65, 0x3b, 0x6e, 0x6f, 0x76, 0x69, 0x65,
-0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x69, 0x63, 0x69, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x45, 0x3b, 0x46, 0x3b, 0x4d,
-0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x65,
-0x6e, 0x65, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x62, 0x72, 0x3b, 0x6d, 0x61, 0x79, 0x3b, 0x6a,
+0x3b, 0x6a, 0x75, 0x6e, 0x2e, 0x3b, 0x6a, 0x75, 0x6c, 0x2e, 0x3b, 0x61, 0x75, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x70, 0x2e,
+0x3b, 0x6f, 0x6b, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b, 0x6a, 0x61, 0x6e, 0x3b,
+0x66, 0x65, 0x62, 0x3b, 0x6d, 0x72, 0x74, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x65, 0x69, 0x3b, 0x6a, 0x75, 0x6e, 0x3b,
+0x6a, 0x75, 0x6c, 0x3b, 0x61, 0x75, 0x67, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b,
+0x64, 0x65, 0x63, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69,
+0x3b, 0x6d, 0x61, 0x61, 0x72, 0x74, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x65, 0x69, 0x3b, 0x6a, 0x75, 0x6e,
+0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x75, 0x73, 0x3b, 0x73, 0x65, 0x70, 0x74,
+0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62,
+0x65, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6a, 0x61, 0x6e, 0x2e, 0x3b, 0x66, 0x65, 0x62,
+0x2e, 0x3b, 0x6d, 0x72, 0x74, 0x2e, 0x3b, 0x61, 0x70, 0x72, 0x2e, 0x3b, 0x6d, 0x65, 0x69, 0x3b, 0x6a, 0x75, 0x6e, 0x2e,
+0x3b, 0x6a, 0x75, 0x6c, 0x2e, 0x3b, 0x61, 0x75, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x70, 0x2e, 0x3b, 0x6f, 0x6b, 0x74, 0x2e,
+0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b, 0xd801, 0xdc16, 0xd801, 0xdc30, 0xd801, 0xdc4c, 0x3b, 0xd801, 0xdc19,
+0xd801, 0xdc2f, 0xd801, 0xdc3a, 0x3b, 0xd801, 0xdc23, 0xd801, 0xdc2a, 0xd801, 0xdc49, 0x3b, 0xd801, 0xdc01, 0xd801, 0xdc39, 0xd801, 0xdc49, 0x3b, 0xd801,
+0xdc23, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc16, 0xd801, 0xdc2d, 0xd801, 0xdc4c, 0x3b, 0xd801, 0xdc16, 0xd801, 0xdc2d, 0xd801, 0xdc4a, 0x3b, 0xd801, 0xdc02,
+0xd801, 0xdc40, 0x3b, 0xd801, 0xdc1d, 0xd801, 0xdc2f, 0xd801, 0xdc39, 0x3b, 0xd801, 0xdc09, 0xd801, 0xdc3f, 0xd801, 0xdc3b, 0x3b, 0xd801, 0xdc24, 0xd801,
+0xdc2c, 0xd801, 0xdc42, 0x3b, 0xd801, 0xdc14, 0xd801, 0xdc28, 0xd801, 0xdc45, 0x3b, 0xd801, 0xdc16, 0xd801, 0xdc30, 0xd801, 0xdc4c, 0xd801, 0xdc37, 0xd801,
+0xdc2d, 0xd801, 0xdc2f, 0xd801, 0xdc49, 0xd801, 0xdc28, 0x3b, 0xd801, 0xdc19, 0xd801, 0xdc2f, 0xd801, 0xdc3a, 0xd801, 0xdc49, 0xd801, 0xdc2d, 0xd801, 0xdc2f,
+0xd801, 0xdc49, 0xd801, 0xdc28, 0x3b, 0xd801, 0xdc23, 0xd801, 0xdc2a, 0xd801, 0xdc49, 0xd801, 0xdc3d, 0x3b, 0xd801, 0xdc01, 0xd801, 0xdc39, 0xd801, 0xdc49,
+0xd801, 0xdc2e, 0xd801, 0xdc4a, 0x3b, 0xd801, 0xdc23, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc16, 0xd801, 0xdc2d, 0xd801, 0xdc4c, 0x3b, 0xd801, 0xdc16, 0xd801,
+0xdc2d, 0xd801, 0xdc4a, 0xd801, 0xdc34, 0x3b, 0xd801, 0xdc02, 0xd801, 0xdc40, 0xd801, 0xdc32, 0xd801, 0xdc45, 0xd801, 0xdc3b, 0x3b, 0xd801, 0xdc1d, 0xd801,
+0xdc2f, 0xd801, 0xdc39, 0xd801, 0xdc3b, 0xd801, 0xdc2f, 0xd801, 0xdc4b, 0xd801, 0xdc3a, 0xd801, 0xdc32, 0xd801, 0xdc49, 0x3b, 0xd801, 0xdc09, 0xd801, 0xdc3f,
+0xd801, 0xdc3b, 0xd801, 0xdc2c, 0xd801, 0xdc3a, 0xd801, 0xdc32, 0xd801, 0xdc49, 0x3b, 0xd801, 0xdc24, 0xd801, 0xdc2c, 0xd801, 0xdc42, 0xd801, 0xdc2f, 0xd801,
+0xdc4b, 0xd801, 0xdc3a, 0xd801, 0xdc32, 0xd801, 0xdc49, 0x3b, 0xd801, 0xdc14, 0xd801, 0xdc28, 0xd801, 0xdc45, 0xd801, 0xdc2f, 0xd801, 0xdc4b, 0xd801, 0xdc3a,
+0xd801, 0xdc32, 0xd801, 0xdc49, 0x3b, 0xd801, 0xdc16, 0x3b, 0xd801, 0xdc19, 0x3b, 0xd801, 0xdc23, 0x3b, 0xd801, 0xdc01, 0x3b, 0xd801, 0xdc23, 0x3b,
+0xd801, 0xdc16, 0x3b, 0xd801, 0xdc16, 0x3b, 0xd801, 0xdc02, 0x3b, 0xd801, 0xdc1d, 0x3b, 0xd801, 0xdc09, 0x3b, 0xd801, 0xdc24, 0x3b, 0xd801, 0xdc14,
+0x3b, 0x6a, 0x61, 0x61, 0x6e, 0x3b, 0x76, 0x65, 0x65, 0x62, 0x72, 0x3b, 0x6d, 0xe4, 0x72, 0x74, 0x73, 0x3b, 0x61, 0x70,
+0x72, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75,
+0x67, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x65, 0x74, 0x73, 0x3b,
+0x6a, 0x61, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x76, 0x65, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x6d, 0xe4, 0x72,
+0x74, 0x73, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x6c, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75, 0x75, 0x6e, 0x69, 0x3b,
+0x6a, 0x75, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62,
+0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72,
+0x3b, 0x64, 0x65, 0x74, 0x73, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4a, 0x3b, 0x56, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d,
+0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x6a, 0x61, 0x6e, 0x3b, 0x66,
+0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75, 0x6e, 0x3b, 0x6a,
+0x75, 0x6c, 0x3b, 0x61, 0x75, 0x67, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64,
+0x65, 0x73, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x6d, 0x61,
+0x72, 0x73, 0x3b, 0x61, 0x70, 0x72, 0xed, 0x6c, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75,
+0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b,
+0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x73,
+0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x74, 0x61, 0x6d, 0x6d, 0x69, 0x3b, 0x68, 0x65, 0x6c, 0x6d, 0x69, 0x3b, 0x6d, 0x61,
+0x61, 0x6c, 0x69, 0x73, 0x3b, 0x68, 0x75, 0x68, 0x74, 0x69, 0x3b, 0x74, 0x6f, 0x75, 0x6b, 0x6f, 0x3b, 0x6b, 0x65, 0x73,
+0xe4, 0x3b, 0x68, 0x65, 0x69, 0x6e, 0xe4, 0x3b, 0x65, 0x6c, 0x6f, 0x3b, 0x73, 0x79, 0x79, 0x73, 0x3b, 0x6c, 0x6f, 0x6b,
+0x61, 0x3b, 0x6d, 0x61, 0x72, 0x72, 0x61, 0x73, 0x3b, 0x6a, 0x6f, 0x75, 0x6c, 0x75, 0x3b, 0x74, 0x61, 0x6d, 0x6d, 0x69,
+0x6b, 0x75, 0x75, 0x3b, 0x68, 0x65, 0x6c, 0x6d, 0x69, 0x6b, 0x75, 0x75, 0x3b, 0x6d, 0x61, 0x61, 0x6c, 0x69, 0x73, 0x6b,
+0x75, 0x75, 0x3b, 0x68, 0x75, 0x68, 0x74, 0x69, 0x6b, 0x75, 0x75, 0x3b, 0x74, 0x6f, 0x75, 0x6b, 0x6f, 0x6b, 0x75, 0x75,
+0x3b, 0x6b, 0x65, 0x73, 0xe4, 0x6b, 0x75, 0x75, 0x3b, 0x68, 0x65, 0x69, 0x6e, 0xe4, 0x6b, 0x75, 0x75, 0x3b, 0x65, 0x6c,
+0x6f, 0x6b, 0x75, 0x75, 0x3b, 0x73, 0x79, 0x79, 0x73, 0x6b, 0x75, 0x75, 0x3b, 0x6c, 0x6f, 0x6b, 0x61, 0x6b, 0x75, 0x75,
+0x3b, 0x6d, 0x61, 0x72, 0x72, 0x61, 0x73, 0x6b, 0x75, 0x75, 0x3b, 0x6a, 0x6f, 0x75, 0x6c, 0x75, 0x6b, 0x75, 0x75, 0x3b,
+0x54, 0x3b, 0x48, 0x3b, 0x4d, 0x3b, 0x48, 0x3b, 0x54, 0x3b, 0x4b, 0x3b, 0x48, 0x3b, 0x45, 0x3b, 0x53, 0x3b, 0x4c, 0x3b,
+0x4d, 0x3b, 0x4a, 0x3b, 0x74, 0x61, 0x6d, 0x6d, 0x69, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x68, 0x65, 0x6c, 0x6d, 0x69,
+0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x6d, 0x61, 0x61, 0x6c, 0x69, 0x73, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x68, 0x75,
+0x68, 0x74, 0x69, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x74, 0x6f, 0x75, 0x6b, 0x6f, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b,
+0x6b, 0x65, 0x73, 0xe4, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x68, 0x65, 0x69, 0x6e, 0xe4, 0x6b, 0x75, 0x75, 0x74, 0x61,
+0x3b, 0x65, 0x6c, 0x6f, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x73, 0x79, 0x79, 0x73, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b,
+0x6c, 0x6f, 0x6b, 0x61, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x6d, 0x61, 0x72, 0x72, 0x61, 0x73, 0x6b, 0x75, 0x75, 0x74,
+0x61, 0x3b, 0x6a, 0x6f, 0x75, 0x6c, 0x75, 0x6b, 0x75, 0x75, 0x74, 0x61, 0x3b, 0x6a, 0x61, 0x6e, 0x76, 0x2e, 0x3b, 0x66,
+0xe9, 0x76, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x76, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a,
+0x75, 0x69, 0x6e, 0x3b, 0x6a, 0x75, 0x69, 0x6c, 0x2e, 0x3b, 0x61, 0x6f, 0xfb, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x2e,
+0x3b, 0x6f, 0x63, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0xe9, 0x63, 0x2e, 0x3b, 0x6a, 0x61, 0x6e, 0x76,
+0x69, 0x65, 0x72, 0x3b, 0x66, 0xe9, 0x76, 0x72, 0x69, 0x65, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x76, 0x72,
+0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75, 0x69, 0x6e, 0x3b, 0x6a, 0x75, 0x69, 0x6c, 0x6c, 0x65, 0x74, 0x3b,
+0x61, 0x6f, 0xfb, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x6f, 0x63, 0x74, 0x6f, 0x62,
+0x72, 0x65, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0xe9, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x65,
+0x3b, 0x46, 0x61, 0x6f, 0x69, 0x3b, 0x47, 0x65, 0x61, 0x72, 0x72, 0x3b, 0x4d, 0xe0, 0x72, 0x74, 0x3b, 0x47, 0x69, 0x62,
+0x6c, 0x3b, 0x43, 0xe8, 0x69, 0x74, 0x3b, 0xd2, 0x67, 0x6d, 0x68, 0x3b, 0x49, 0x75, 0x63, 0x68, 0x3b, 0x4c, 0xf9, 0x6e,
+0x61, 0x3b, 0x53, 0x75, 0x6c, 0x74, 0x3b, 0x44, 0xe0, 0x6d, 0x68, 0x3b, 0x53, 0x61, 0x6d, 0x68, 0x3b, 0x44, 0xf9, 0x62,
+0x68, 0x3b, 0x41, 0x6d, 0x20, 0x46, 0x61, 0x6f, 0x69, 0x6c, 0x6c, 0x65, 0x61, 0x63, 0x68, 0x3b, 0x41, 0x6e, 0x20, 0x47,
+0x65, 0x61, 0x72, 0x72, 0x61, 0x6e, 0x3b, 0x41, 0x6d, 0x20, 0x4d, 0xe0, 0x72, 0x74, 0x3b, 0x41, 0x6e, 0x20, 0x47, 0x69,
+0x62, 0x6c, 0x65, 0x61, 0x6e, 0x3b, 0x41, 0x6e, 0x20, 0x43, 0xe8, 0x69, 0x74, 0x65, 0x61, 0x6e, 0x3b, 0x41, 0x6e, 0x20,
+0x74, 0x2d, 0xd2, 0x67, 0x6d, 0x68, 0x69, 0x6f, 0x73, 0x3b, 0x41, 0x6e, 0x20, 0x74, 0x2d, 0x49, 0x75, 0x63, 0x68, 0x61,
+0x72, 0x3b, 0x41, 0x6e, 0x20, 0x4c, 0xf9, 0x6e, 0x61, 0x73, 0x74, 0x61, 0x6c, 0x3b, 0x41, 0x6e, 0x20, 0x74, 0x2d, 0x53,
+0x75, 0x6c, 0x74, 0x61, 0x69, 0x6e, 0x3b, 0x41, 0x6e, 0x20, 0x44, 0xe0, 0x6d, 0x68, 0x61, 0x69, 0x72, 0x3b, 0x41, 0x6e,
+0x20, 0x74, 0x2d, 0x53, 0x61, 0x6d, 0x68, 0x61, 0x69, 0x6e, 0x3b, 0x41, 0x6e, 0x20, 0x44, 0xf9, 0x62, 0x68, 0x6c, 0x61,
+0x63, 0x68, 0x64, 0x3b, 0x46, 0x41, 0x3b, 0x47, 0x45, 0x3b, 0x4d, 0xc0, 0x3b, 0x47, 0x49, 0x3b, 0x43, 0xc8, 0x3b, 0xd2,
+0x47, 0x3b, 0x49, 0x55, 0x3b, 0x4c, 0xd9, 0x3b, 0x53, 0x55, 0x3b, 0x44, 0xc0, 0x3b, 0x53, 0x41, 0x3b, 0x44, 0xd9, 0x3b,
+0x58, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x69, 0x3b,
+0x58, 0x75, 0xf1, 0x3b, 0x58, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x75, 0x74, 0x3b,
+0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x63, 0x3b, 0x58, 0x61, 0x6e, 0x65, 0x69, 0x72, 0x6f, 0x3b, 0x46, 0x65, 0x62, 0x72,
+0x65, 0x69, 0x72, 0x6f, 0x3b, 0x4d, 0x61, 0x72, 0x7a, 0x6f, 0x3b, 0x41, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x69,
+0x6f, 0x3b, 0x58, 0x75, 0xf1, 0x6f, 0x3b, 0x58, 0x75, 0x6c, 0x6c, 0x6f, 0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74, 0x6f, 0x3b,
+0x53, 0x65, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x4f, 0x75, 0x74, 0x75, 0x62, 0x72, 0x6f, 0x3b, 0x4e, 0x6f, 0x76,
+0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x44, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x58, 0x3b, 0x46, 0x3b, 0x4d,
+0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x58, 0x3b, 0x58, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x10d8,
+0x10d0, 0x10dc, 0x3b, 0x10d7, 0x10d4, 0x10d1, 0x3b, 0x10db, 0x10d0, 0x10e0, 0x3b, 0x10d0, 0x10de, 0x10e0, 0x3b, 0x10db, 0x10d0, 0x10d8, 0x3b, 0x10d8,
+0x10d5, 0x10dc, 0x3b, 0x10d8, 0x10d5, 0x10da, 0x3b, 0x10d0, 0x10d2, 0x10d5, 0x3b, 0x10e1, 0x10d4, 0x10e5, 0x3b, 0x10dd, 0x10e5, 0x10e2, 0x3b, 0x10dc,
+0x10dd, 0x10d4, 0x3b, 0x10d3, 0x10d4, 0x10d9, 0x3b, 0x10d8, 0x10d0, 0x10dc, 0x10d5, 0x10d0, 0x10e0, 0x10d8, 0x3b, 0x10d7, 0x10d4, 0x10d1, 0x10d4, 0x10e0,
+0x10d5, 0x10d0, 0x10da, 0x10d8, 0x3b, 0x10db, 0x10d0, 0x10e0, 0x10e2, 0x10d8, 0x3b, 0x10d0, 0x10de, 0x10e0, 0x10d8, 0x10da, 0x10d8, 0x3b, 0x10db, 0x10d0,
+0x10d8, 0x10e1, 0x10d8, 0x3b, 0x10d8, 0x10d5, 0x10dc, 0x10d8, 0x10e1, 0x10d8, 0x3b, 0x10d8, 0x10d5, 0x10da, 0x10d8, 0x10e1, 0x10d8, 0x3b, 0x10d0, 0x10d2,
+0x10d5, 0x10d8, 0x10e1, 0x10e2, 0x10dd, 0x3b, 0x10e1, 0x10d4, 0x10e5, 0x10e2, 0x10d4, 0x10db, 0x10d1, 0x10d4, 0x10e0, 0x10d8, 0x3b, 0x10dd, 0x10e5, 0x10e2,
+0x10dd, 0x10db, 0x10d1, 0x10d4, 0x10e0, 0x10d8, 0x3b, 0x10dc, 0x10dd, 0x10d4, 0x10db, 0x10d1, 0x10d4, 0x10e0, 0x10d8, 0x3b, 0x10d3, 0x10d4, 0x10d9, 0x10d4,
+0x10db, 0x10d1, 0x10d4, 0x10e0, 0x10d8, 0x3b, 0x10d8, 0x3b, 0x10d7, 0x3b, 0x10db, 0x3b, 0x10d0, 0x3b, 0x10db, 0x3b, 0x10d8, 0x3b, 0x10d8, 0x3b,
+0x10d0, 0x3b, 0x10e1, 0x3b, 0x10dd, 0x3b, 0x10dc, 0x3b, 0x10d3, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0xe4,
+0x72, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x75,
+0x67, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x7a, 0x3b, 0x4a, 0x61,
+0x6e, 0x75, 0x61, 0x72, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x4d, 0xe4, 0x72, 0x7a, 0x3b, 0x41, 0x70,
+0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x69, 0x3b, 0x41, 0x75,
+0x67, 0x75, 0x73, 0x74, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62,
+0x65, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x44, 0x65, 0x7a, 0x65, 0x6d, 0x62, 0x65, 0x72,
+0x3b, 0x4a, 0x61, 0x6e, 0x2e, 0x3b, 0x46, 0x65, 0x62, 0x2e, 0x3b, 0x4d, 0xe4, 0x72, 0x2e, 0x3b, 0x41, 0x70, 0x72, 0x2e,
+0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x69, 0x3b, 0x41, 0x75, 0x67, 0x2e, 0x3b,
+0x53, 0x65, 0x70, 0x2e, 0x3b, 0x4f, 0x6b, 0x74, 0x2e, 0x3b, 0x4e, 0x6f, 0x76, 0x2e, 0x3b, 0x44, 0x65, 0x7a, 0x2e, 0x3b,
+0x4a, 0xe4, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0xe4, 0x72, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x61, 0x69, 0x3b,
+0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x75, 0x67, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b,
+0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x7a, 0x3b, 0x4a, 0xe4, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x2e, 0x3b, 0x4d, 0xe4, 0x72,
+0x2e, 0x3b, 0x41, 0x70, 0x72, 0x2e, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x69,
+0x3b, 0x41, 0x75, 0x67, 0x2e, 0x3b, 0x53, 0x65, 0x70, 0x2e, 0x3b, 0x4f, 0x6b, 0x74, 0x2e, 0x3b, 0x4e, 0x6f, 0x76, 0x2e,
+0x3b, 0x44, 0x65, 0x7a, 0x2e, 0x3b, 0x4a, 0xe4, 0x6e, 0x6e, 0x65, 0x72, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72,
+0x3b, 0x4d, 0xe4, 0x72, 0x7a, 0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69,
+0x3b, 0x4a, 0x75, 0x6c, 0x69, 0x3b, 0x41, 0x75, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62,
+0x65, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b,
+0x44, 0x65, 0x7a, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x399, 0x3b1, 0x3bd, 0x3b, 0x3a6, 0x3b5, 0x3b2, 0x3b, 0x39c, 0x3ac, 0x3c1,
+0x3b, 0x391, 0x3c0, 0x3c1, 0x3b, 0x39c, 0x3ac, 0x3b9, 0x3b, 0x399, 0x3bf, 0x3cd, 0x3bd, 0x3b, 0x399, 0x3bf, 0x3cd, 0x3bb, 0x3b, 0x391,
+0x3cd, 0x3b3, 0x3b, 0x3a3, 0x3b5, 0x3c0, 0x3b, 0x39f, 0x3ba, 0x3c4, 0x3b, 0x39d, 0x3bf, 0x3ad, 0x3b, 0x394, 0x3b5, 0x3ba, 0x3b, 0x399,
+0x3b1, 0x3bd, 0x3bf, 0x3c5, 0x3ac, 0x3c1, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x3a6, 0x3b5, 0x3b2, 0x3c1, 0x3bf, 0x3c5, 0x3ac, 0x3c1, 0x3b9, 0x3bf,
+0x3c2, 0x3b, 0x39c, 0x3ac, 0x3c1, 0x3c4, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x391, 0x3c0, 0x3c1, 0x3af, 0x3bb, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x39c,
+0x3ac, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x399, 0x3bf, 0x3cd, 0x3bd, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x399, 0x3bf, 0x3cd, 0x3bb, 0x3b9, 0x3bf, 0x3c2,
+0x3b, 0x391, 0x3cd, 0x3b3, 0x3bf, 0x3c5, 0x3c3, 0x3c4, 0x3bf, 0x3c2, 0x3b, 0x3a3, 0x3b5, 0x3c0, 0x3c4, 0x3ad, 0x3bc, 0x3b2, 0x3c1, 0x3b9,
+0x3bf, 0x3c2, 0x3b, 0x39f, 0x3ba, 0x3c4, 0x3ce, 0x3b2, 0x3c1, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x39d, 0x3bf, 0x3ad, 0x3bc, 0x3b2, 0x3c1, 0x3b9,
+0x3bf, 0x3c2, 0x3b, 0x394, 0x3b5, 0x3ba, 0x3ad, 0x3bc, 0x3b2, 0x3c1, 0x3b9, 0x3bf, 0x3c2, 0x3b, 0x399, 0x3b, 0x3a6, 0x3b, 0x39c, 0x3b,
+0x391, 0x3b, 0x39c, 0x3b, 0x399, 0x3b, 0x399, 0x3b, 0x391, 0x3b, 0x3a3, 0x3b, 0x39f, 0x3b, 0x39d, 0x3b, 0x394, 0x3b, 0x399, 0x3b1,
+0x3bd, 0x3b, 0x3a6, 0x3b5, 0x3b2, 0x3b, 0x39c, 0x3b1, 0x3c1, 0x3b, 0x391, 0x3c0, 0x3c1, 0x3b, 0x39c, 0x3b1, 0x3ca, 0x3b, 0x399, 0x3bf,
+0x3c5, 0x3bd, 0x3b, 0x399, 0x3bf, 0x3c5, 0x3bb, 0x3b, 0x391, 0x3c5, 0x3b3, 0x3b, 0x3a3, 0x3b5, 0x3c0, 0x3b, 0x39f, 0x3ba, 0x3c4, 0x3b,
+0x39d, 0x3bf, 0x3b5, 0x3b, 0x394, 0x3b5, 0x3ba, 0x3b, 0x399, 0x3b1, 0x3bd, 0x3bf, 0x3c5, 0x3b1, 0x3c1, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x3a6,
+0x3b5, 0x3b2, 0x3c1, 0x3bf, 0x3c5, 0x3b1, 0x3c1, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x39c, 0x3b1, 0x3c1, 0x3c4, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x391,
+0x3c0, 0x3c1, 0x3b9, 0x3bb, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x39c, 0x3b1, 0x390, 0x3bf, 0x3c5, 0x3b, 0x399, 0x3bf, 0x3c5, 0x3bd, 0x3af, 0x3bf,
+0x3c5, 0x3b, 0x399, 0x3bf, 0x3c5, 0x3bb, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x391, 0x3c5, 0x3b3, 0x3bf, 0x3cd, 0x3c3, 0x3c4, 0x3bf, 0x3c5, 0x3b,
+0x3a3, 0x3b5, 0x3c0, 0x3c4, 0x3b5, 0x3bc, 0x3b2, 0x3c1, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x39f, 0x3ba, 0x3c4, 0x3c9, 0x3b2, 0x3c1, 0x3af, 0x3bf,
+0x3c5, 0x3b, 0x39d, 0x3bf, 0x3b5, 0x3bc, 0x3b2, 0x3c1, 0x3af, 0x3bf, 0x3c5, 0x3b, 0x394, 0x3b5, 0x3ba, 0x3b5, 0x3bc, 0x3b2, 0x3c1, 0x3af,
+0x3bf, 0x3c5, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69, 0x3b,
+0x6d, 0x61, 0x72, 0x74, 0x73, 0x69, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x69, 0x3b, 0x6d, 0x61, 0x6a, 0x69, 0x3b, 0x6a,
+0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x75, 0x73, 0x69, 0x3b, 0x73,
+0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x69, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x69, 0x3b, 0x6e,
+0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x69, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x69, 0x3b, 0xa9c,
+0xabe, 0xaa8, 0xacd, 0xaaf, 0xac1, 0x3b, 0xaab, 0xac7, 0xaac, 0xacd, 0xab0, 0xac1, 0x3b, 0xaae, 0xabe, 0xab0, 0xacd, 0xa9a, 0x3b, 0xa8f,
+0xaaa, 0xacd, 0xab0, 0xabf, 0xab2, 0x3b, 0xaae, 0xac7, 0x3b, 0xa9c, 0xac2, 0xaa8, 0x3b, 0xa9c, 0xac1, 0xab2, 0xabe, 0xa88, 0x3b, 0xa91,
+0xa97, 0x3b, 0xab8, 0xaaa, 0xacd, 0xa9f, 0xac7, 0x3b, 0xa91, 0xa95, 0xacd, 0xa9f, 0xacb, 0x3b, 0xaa8, 0xab5, 0xac7, 0x3b, 0xaa1, 0xabf,
+0xab8, 0xac7, 0x3b, 0xa9c, 0xabe, 0xaa8, 0xacd, 0xaaf, 0xac1, 0xa86, 0xab0, 0xac0, 0x3b, 0xaab, 0xac7, 0xaac, 0xacd, 0xab0, 0xac1, 0xa86,
+0xab0, 0xac0, 0x3b, 0xaae, 0xabe, 0xab0, 0xacd, 0xa9a, 0x3b, 0xa8f, 0xaaa, 0xacd, 0xab0, 0xabf, 0xab2, 0x3b, 0xaae, 0xac7, 0x3b, 0xa9c,
+0xac2, 0xaa8, 0x3b, 0xa9c, 0xac1, 0xab2, 0xabe, 0xa88, 0x3b, 0xa91, 0xa97, 0xab8, 0xacd, 0xa9f, 0x3b, 0xab8, 0xaaa, 0xacd, 0xa9f, 0xac7,
+0xaae, 0xacd, 0xaac, 0xab0, 0x3b, 0xa91, 0xa95, 0xacd, 0xa9f, 0xacd, 0xaac, 0xab0, 0x3b, 0xaa8, 0xab5, 0xac7, 0xaae, 0xacd, 0xaac, 0xab0,
+0x3b, 0xaa1, 0xabf, 0xab8, 0xac7, 0xaae, 0xacd, 0xaac, 0xab0, 0x3b, 0xa9c, 0xabe, 0x3b, 0xaab, 0xac7, 0x3b, 0xaae, 0xabe, 0x3b, 0xa8f,
+0x3b, 0xaae, 0xac7, 0x3b, 0xa9c, 0xac2, 0x3b, 0xa9c, 0xac1, 0x3b, 0xa91, 0x3b, 0xab8, 0x3b, 0xa91, 0x3b, 0xaa8, 0x3b, 0xaa1, 0xabf,
+0x3b, 0xa9c, 0xabe, 0xaa8, 0xacd, 0xaaf, 0xac1, 0x3b, 0xaab, 0xac7, 0xaac, 0xacd, 0xab0, 0xac1, 0x3b, 0xaae, 0xabe, 0xab0, 0xacd, 0xa9a,
+0x3b, 0xa8f, 0xaaa, 0xacd, 0xab0, 0xabf, 0xab2, 0x3b, 0xaae, 0xac7, 0x3b, 0xa9c, 0xac2, 0xaa8, 0x3b, 0xa9c, 0xac1, 0xab2, 0xabe, 0xa88,
+0x3b, 0xa91, 0xa97, 0xab8, 0xacd, 0xa9f, 0x3b, 0xab8, 0xaaa, 0xacd, 0xa9f, 0xac7, 0x3b, 0xa91, 0xa95, 0xacd, 0xa9f, 0xacb, 0x3b, 0xaa8,
+0xab5, 0xac7, 0x3b, 0xaa1, 0xabf, 0xab8, 0xac7, 0x3b, 0xa9c, 0xabe, 0xaa8, 0xacd, 0xaaf, 0xac1, 0xa86, 0xab0, 0xac0, 0x3b, 0xaab, 0xac7,
+0xaac, 0xacd, 0xab0, 0xac1, 0xa86, 0xab0, 0xac0, 0x3b, 0xaae, 0xabe, 0xab0, 0xacd, 0xa9a, 0x3b, 0xa8f, 0xaaa, 0xacd, 0xab0, 0xabf, 0xab2,
+0x3b, 0xaae, 0xac7, 0x3b, 0xa9c, 0xac2, 0xaa8, 0x3b, 0xa9c, 0xac1, 0xab2, 0xabe, 0xa88, 0x3b, 0xa91, 0xa97, 0xab8, 0xacd, 0xa9f, 0x3b,
+0xab8, 0xaaa, 0xacd, 0xa9f, 0xac7, 0xaae, 0xacd, 0xaac, 0xab0, 0x3b, 0xa91, 0xa95, 0xacd, 0xa9f, 0xacb, 0xaac, 0xab0, 0x3b, 0xaa8, 0xab5,
+0xac7, 0xaae, 0xacd, 0xaac, 0xab0, 0x3b, 0xaa1, 0xabf, 0xab8, 0xac7, 0xaae, 0xacd, 0xaac, 0xab0, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46,
+0x61, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x66, 0x69, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x59, 0x75, 0x6e, 0x3b, 0x59,
+0x75, 0x6c, 0x3b, 0x41, 0x67, 0x75, 0x3b, 0x53, 0x61, 0x74, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x75, 0x77, 0x3b, 0x44,
+0x69, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x61, 0x69, 0x72, 0x75, 0x3b, 0x46, 0x61, 0x62, 0x75, 0x72, 0x61, 0x69, 0x72, 0x75,
+0x3b, 0x4d, 0x61, 0x72, 0x69, 0x73, 0x3b, 0x41, 0x66, 0x69, 0x72, 0x69, 0x6c, 0x75, 0x3b, 0x4d, 0x61, 0x79, 0x75, 0x3b,
+0x59, 0x75, 0x6e, 0x69, 0x3b, 0x59, 0x75, 0x6c, 0x69, 0x3b, 0x41, 0x67, 0x75, 0x73, 0x74, 0x61, 0x3b, 0x53, 0x61, 0x74,
+0x75, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x3b, 0x4e, 0x75, 0x77, 0x61, 0x6d, 0x62, 0x61, 0x3b,
+0x44, 0x69, 0x73, 0x61, 0x6d, 0x62, 0x61, 0x3b, 0x4a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x59, 0x3b,
+0x59, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x5d9, 0x5e0, 0x5d5, 0x5f3, 0x3b, 0x5e4, 0x5d1, 0x5e8,
+0x5f3, 0x3b, 0x5de, 0x5e8, 0x5e5, 0x3b, 0x5d0, 0x5e4, 0x5e8, 0x5f3, 0x3b, 0x5de, 0x5d0, 0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5e0, 0x5f3, 0x3b,
+0x5d9, 0x5d5, 0x5dc, 0x5f3, 0x3b, 0x5d0, 0x5d5, 0x5d2, 0x5f3, 0x3b, 0x5e1, 0x5e4, 0x5d8, 0x5f3, 0x3b, 0x5d0, 0x5d5, 0x5e7, 0x5f3, 0x3b,
+0x5e0, 0x5d5, 0x5d1, 0x5f3, 0x3b, 0x5d3, 0x5e6, 0x5de, 0x5f3, 0x3b, 0x5d9, 0x5e0, 0x5d5, 0x5d0, 0x5e8, 0x3b, 0x5e4, 0x5d1, 0x5e8, 0x5d5,
+0x5d0, 0x5e8, 0x3b, 0x5de, 0x5e8, 0x5e5, 0x3b, 0x5d0, 0x5e4, 0x5e8, 0x5d9, 0x5dc, 0x3b, 0x5de, 0x5d0, 0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5e0,
+0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5dc, 0x5d9, 0x3b, 0x5d0, 0x5d5, 0x5d2, 0x5d5, 0x5e1, 0x5d8, 0x3b, 0x5e1, 0x5e4, 0x5d8, 0x5de, 0x5d1, 0x5e8,
+0x3b, 0x5d0, 0x5d5, 0x5e7, 0x5d8, 0x5d5, 0x5d1, 0x5e8, 0x3b, 0x5e0, 0x5d5, 0x5d1, 0x5de, 0x5d1, 0x5e8, 0x3b, 0x5d3, 0x5e6, 0x5de, 0x5d1,
+0x5e8, 0x3b, 0x5d9, 0x5e0, 0x5d5, 0x3b, 0x5e4, 0x5d1, 0x5e8, 0x3b, 0x5de, 0x5e8, 0x5e5, 0x3b, 0x5d0, 0x5e4, 0x5e8, 0x3b, 0x5de, 0x5d0,
+0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5e0, 0x3b, 0x5d9, 0x5d5, 0x5dc, 0x3b, 0x5d0, 0x5d5, 0x5d2, 0x3b, 0x5e1, 0x5e4, 0x5d8, 0x3b, 0x5d0, 0x5d5,
+0x5e7, 0x3b, 0x5e0, 0x5d5, 0x5d1, 0x3b, 0x5d3, 0x5e6, 0x5de, 0x3b, 0x91c, 0x928, 0x935, 0x930, 0x940, 0x3b, 0x92b, 0x930, 0x935, 0x930,
+0x940, 0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x91a, 0x3b, 0x905, 0x92a, 0x94d, 0x930, 0x948, 0x932, 0x3b, 0x92e, 0x908, 0x3b, 0x91c, 0x942,
+0x928, 0x3b, 0x91c, 0x941, 0x932, 0x93e, 0x908, 0x3b, 0x905, 0x917, 0x938, 0x94d, 0x924, 0x3b, 0x938, 0x93f, 0x924, 0x92e, 0x94d, 0x92c,
+0x930, 0x3b, 0x905, 0x915, 0x94d, 0x924, 0x942, 0x92c, 0x930, 0x3b, 0x928, 0x935, 0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x926, 0x93f, 0x938,
+0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x91c, 0x3b, 0x92b, 0x93c, 0x3b, 0x92e, 0x93e, 0x3b, 0x905, 0x3b, 0x92e, 0x3b, 0x91c, 0x942, 0x3b,
+0x91c, 0x941, 0x3b, 0x905, 0x3b, 0x938, 0x93f, 0x3b, 0x905, 0x3b, 0x928, 0x3b, 0x926, 0x93f, 0x3b, 0x6a, 0x61, 0x6e, 0x2e, 0x3b,
+0x66, 0x65, 0x62, 0x72, 0x2e, 0x3b, 0x6d, 0xe1, 0x72, 0x63, 0x2e, 0x3b, 0xe1, 0x70, 0x72, 0x2e, 0x3b, 0x6d, 0xe1, 0x6a,
+0x2e, 0x3b, 0x6a, 0xfa, 0x6e, 0x2e, 0x3b, 0x6a, 0xfa, 0x6c, 0x2e, 0x3b, 0x61, 0x75, 0x67, 0x2e, 0x3b, 0x73, 0x7a, 0x65,
+0x70, 0x74, 0x2e, 0x3b, 0x6f, 0x6b, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b, 0x6a,
+0x61, 0x6e, 0x75, 0xe1, 0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0xe1, 0x72, 0x3b, 0x6d, 0xe1, 0x72, 0x63, 0x69, 0x75,
+0x73, 0x3b, 0xe1, 0x70, 0x72, 0x69, 0x6c, 0x69, 0x73, 0x3b, 0x6d, 0xe1, 0x6a, 0x75, 0x73, 0x3b, 0x6a, 0xfa, 0x6e, 0x69,
+0x75, 0x73, 0x3b, 0x6a, 0xfa, 0x6c, 0x69, 0x75, 0x73, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x7a, 0x74, 0x75, 0x73, 0x3b,
+0x73, 0x7a, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0xf3, 0x62, 0x65, 0x72, 0x3b, 0x6e,
+0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4a, 0x3b, 0x46,
+0x3b, 0x4d, 0x3b, 0xc1, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x41, 0x3b, 0x53, 0x7a, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b,
+0x44, 0x3b, 0x4a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0xc1, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0xc1, 0x3b, 0x53, 0x7a,
+0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x6a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61,
+0x70, 0x72, 0x3b, 0x6d, 0x61, 0xed, 0x3b, 0x6a, 0xfa, 0x6e, 0x3b, 0x6a, 0xfa, 0x6c, 0x3b, 0xe1, 0x67, 0xfa, 0x3b, 0x73,
+0x65, 0x70, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0xf3, 0x76, 0x3b, 0x64, 0x65, 0x73, 0x3b, 0x6a, 0x61, 0x6e, 0xfa, 0x61,
+0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0xfa, 0x61, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x70, 0x72, 0xed, 0x6c,
+0x3b, 0x6d, 0x61, 0xed, 0x3b, 0x6a, 0xfa, 0x6e, 0xed, 0x3b, 0x6a, 0xfa, 0x6c, 0xed, 0x3b, 0xe1, 0x67, 0xfa, 0x73, 0x74,
+0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0xf3, 0x62, 0x65, 0x72, 0x3b, 0x6e,
+0xf3, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4a, 0x3b, 0x46,
+0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0xc1, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44,
+0x3b, 0x4a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0xc1, 0x3b, 0x4c, 0x3b, 0x4f,
+0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x70, 0x72,
+0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x74, 0x3b, 0x53, 0x65, 0x70,
+0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69,
+0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61, 0x72, 0x65, 0x74, 0x3b, 0x41, 0x70, 0x72, 0x69,
+0x6c, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x69, 0x3b, 0x41, 0x67, 0x75, 0x73,
+0x74, 0x75, 0x73, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x65,
+0x72, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x44, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b,
+0x6a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x61, 0x69, 0x3b,
+0x6a, 0x75, 0x6e, 0x3b, 0x6a, 0x75, 0x6c, 0x3b, 0x61, 0x75, 0x67, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x63, 0x74, 0x3b,
+0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x65, 0x63, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x6f, 0x3b, 0x66, 0x65, 0x62,
+0x72, 0x75, 0x61, 0x72, 0x69, 0x6f, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x69, 0x6f, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x3b,
+0x6d, 0x61, 0x69, 0x6f, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x6f, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x6f, 0x3b, 0x61, 0x75, 0x67,
+0x75, 0x73, 0x74, 0x6f, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x6f, 0x63, 0x74, 0x6f, 0x62,
+0x72, 0x65, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x65,
+0x3b, 0x45, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x61, 0x62, 0x68, 0x3b, 0x4d, 0xe1, 0x72, 0x74, 0x61, 0x3b, 0x41, 0x69, 0x62,
+0x3b, 0x42, 0x65, 0x61, 0x6c, 0x3b, 0x4d, 0x65, 0x69, 0x74, 0x68, 0x3b, 0x49, 0xfa, 0x69, 0x6c, 0x3b, 0x4c, 0xfa, 0x6e,
+0x3b, 0x4d, 0x46, 0xf3, 0x6d, 0x68, 0x3b, 0x44, 0x46, 0xf3, 0x6d, 0x68, 0x3b, 0x53, 0x61, 0x6d, 0x68, 0x3b, 0x4e, 0x6f,
+0x6c, 0x6c, 0x3b, 0x45, 0x61, 0x6e, 0xe1, 0x69, 0x72, 0x3b, 0x46, 0x65, 0x61, 0x62, 0x68, 0x72, 0x61, 0x3b, 0x4d, 0xe1,
+0x72, 0x74, 0x61, 0x3b, 0x41, 0x69, 0x62, 0x72, 0x65, 0xe1, 0x6e, 0x3b, 0x42, 0x65, 0x61, 0x6c, 0x74, 0x61, 0x69, 0x6e,
+0x65, 0x3b, 0x4d, 0x65, 0x69, 0x74, 0x68, 0x65, 0x61, 0x6d, 0x68, 0x3b, 0x49, 0xfa, 0x69, 0x6c, 0x3b, 0x4c, 0xfa, 0x6e,
+0x61, 0x73, 0x61, 0x3b, 0x4d, 0x65, 0xe1, 0x6e, 0x20, 0x46, 0xf3, 0x6d, 0x68, 0x61, 0x69, 0x72, 0x3b, 0x44, 0x65, 0x69,
+0x72, 0x65, 0x61, 0x64, 0x68, 0x20, 0x46, 0xf3, 0x6d, 0x68, 0x61, 0x69, 0x72, 0x3b, 0x53, 0x61, 0x6d, 0x68, 0x61, 0x69,
+0x6e, 0x3b, 0x4e, 0x6f, 0x6c, 0x6c, 0x61, 0x69, 0x67, 0x3b, 0x45, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x42, 0x3b,
+0x4d, 0x3b, 0x49, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x44, 0x3b, 0x53, 0x3b, 0x4e, 0x3b, 0x67, 0x65, 0x6e, 0x3b, 0x66, 0x65,
+0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x61, 0x67, 0x3b, 0x67, 0x69, 0x75, 0x3b, 0x6c, 0x75,
+0x67, 0x3b, 0x61, 0x67, 0x6f, 0x3b, 0x73, 0x65, 0x74, 0x3b, 0x6f, 0x74, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x69,
+0x63, 0x3b, 0x47, 0x65, 0x6e, 0x6e, 0x61, 0x69, 0x6f, 0x3b, 0x46, 0x65, 0x62, 0x62, 0x72, 0x61, 0x69, 0x6f, 0x3b, 0x4d,
+0x61, 0x72, 0x7a, 0x6f, 0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c, 0x65, 0x3b, 0x4d, 0x61, 0x67, 0x67, 0x69, 0x6f, 0x3b, 0x47,
+0x69, 0x75, 0x67, 0x6e, 0x6f, 0x3b, 0x4c, 0x75, 0x67, 0x6c, 0x69, 0x6f, 0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74, 0x6f, 0x3b,
+0x53, 0x65, 0x74, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x4f, 0x74, 0x74, 0x6f, 0x62, 0x72, 0x65, 0x3b, 0x4e, 0x6f,
+0x76, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x44, 0x69, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x47, 0x3b, 0x46, 0x3b,
+0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x47, 0x3b, 0x4c, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b,
+0x67, 0x65, 0x6e, 0x6e, 0x61, 0x69, 0x6f, 0x3b, 0x66, 0x65, 0x62, 0x62, 0x72, 0x61, 0x69, 0x6f, 0x3b, 0x6d, 0x61, 0x72,
+0x7a, 0x6f, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x65, 0x3b, 0x6d, 0x61, 0x67, 0x67, 0x69, 0x6f, 0x3b, 0x67, 0x69, 0x75,
+0x67, 0x6e, 0x6f, 0x3b, 0x6c, 0x75, 0x67, 0x6c, 0x69, 0x6f, 0x3b, 0x61, 0x67, 0x6f, 0x73, 0x74, 0x6f, 0x3b, 0x73, 0x65,
+0x74, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x6f, 0x74, 0x74, 0x6f, 0x62, 0x72, 0x65, 0x3b, 0x6e, 0x6f, 0x76, 0x65,
+0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x69, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0xc9c, 0xca8, 0xcb5, 0xcb0, 0xcbf, 0x3b,
+0xcab, 0xcc6, 0xcac, 0xccd, 0xcb0, 0xcc1, 0xcb5, 0xcb0, 0xcbf, 0x3b, 0xcae, 0xcbe, 0xcb0, 0xccd, 0xc9a, 0xccd, 0x3b, 0xc8f, 0xcaa, 0xccd,
+0xcb0, 0xcbf, 0xcb2, 0xccd, 0x200c, 0x200c, 0x3b, 0xcae, 0xcc7, 0x3b, 0xc9c, 0xcc2, 0xca8, 0xccd, 0x3b, 0xc9c, 0xcc1, 0xcb2, 0xcc8, 0x3b,
+0xc86, 0xc97, 0xcb8, 0xccd, 0xc9f, 0xccd, 0x3b, 0xcb8, 0xcc6, 0xcaa, 0xccd, 0xc9f, 0xcc6, 0xc82, 0xcac, 0xcb0, 0xccd, 0x200c, 0x3b, 0xc85,
+0xc95, 0xccd, 0xc9f, 0xccb, 0xcac, 0xcb0, 0xccd, 0x3b, 0xca8, 0xcb5, 0xcc6, 0xc82, 0xcac, 0xcb0, 0xccd, 0x3b, 0xca1, 0xcbf, 0xcb8, 0xcc6,
+0xc82, 0xcac, 0xcb0, 0xccd, 0x3b, 0xc9c, 0xca8, 0xcb5, 0xcb0, 0xcc0, 0x3b, 0xcab, 0xcc6, 0xcac, 0xccd, 0xcb0, 0xcb5, 0xcb0, 0xcc0, 0x3b,
+0xcae, 0xcbe, 0xcb0, 0xccd, 0xc9a, 0xccd, 0x3b, 0xc8e, 0xcaa, 0xccd, 0xcb0, 0xcbf, 0xcb2, 0xccd, 0x3b, 0xcae, 0xcc6, 0x3b, 0xc9c, 0xcc2,
+0xca8, 0xccd, 0x3b, 0xc9c, 0xcc1, 0xcb2, 0xcc8, 0x3b, 0xc86, 0xc97, 0xcb8, 0xccd, 0xc9f, 0xccd, 0x3b, 0xcb8, 0xcaa, 0xccd, 0xc9f, 0xcc6,
+0xc82, 0xcac, 0xcb0, 0xccd, 0x3b, 0xc85, 0xc95, 0xccd, 0xc9f, 0xccb, 0xcac, 0xcb0, 0xccd, 0x3b, 0xca8, 0xcb5, 0xcc6, 0xc82, 0xcac, 0xcb0,
+0xccd, 0x3b, 0xca1, 0xcbf, 0xcb8, 0xcc6, 0xc82, 0xcac, 0xcb0, 0xccd, 0x3b, 0xc9c, 0x3b, 0xcab, 0xcc6, 0x3b, 0xcae, 0xcbe, 0x3b, 0xc8e,
+0x3b, 0xcae, 0xcc7, 0x3b, 0xc9c, 0xcc2, 0x3b, 0xc9c, 0xcc1, 0x3b, 0xc86, 0x3b, 0xcb8, 0xcc6, 0x3b, 0xc85, 0x3b, 0xca8, 0x3b, 0xca1,
+0xcbf, 0x3b, 0xc9c, 0x3b, 0xcab, 0xcc6, 0x3b, 0xcae, 0xcbe, 0x3b, 0xc8f, 0x3b, 0xcae, 0xcc7, 0x3b, 0xc9c, 0xcc2, 0x3b, 0xc9c, 0xcc1,
+0x3b, 0xc86, 0x3b, 0xcb8, 0xcc6, 0x3b, 0xc85, 0x3b, 0xca8, 0x3b, 0xca1, 0xcbf, 0x3b, 0x62c, 0x646, 0x624, 0x631, 0x6cc, 0x3b, 0x641,
+0x631, 0x624, 0x631, 0x6cc, 0x3b, 0x645, 0x627, 0x631, 0x655, 0x686, 0x3b, 0x627, 0x67e, 0x631, 0x6cc, 0x644, 0x3b, 0x645, 0x6cc, 0x654,
+0x3b, 0x62c, 0x648, 0x657, 0x646, 0x3b, 0x62c, 0x648, 0x657, 0x644, 0x627, 0x6cc, 0x6cc, 0x3b, 0x627, 0x6af, 0x633, 0x62a, 0x3b, 0x633,
+0x62a, 0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x648, 0x657, 0x628, 0x631, 0x3b, 0x646, 0x648, 0x645, 0x628, 0x631, 0x3b, 0x62f,
+0x633, 0x645, 0x628, 0x631, 0x3b, 0x62c, 0x3b, 0x641, 0x3b, 0x645, 0x3b, 0x627, 0x3b, 0x645, 0x3b, 0x62c, 0x3b, 0x62c, 0x3b, 0x627,
+0x3b, 0x633, 0x3b, 0x633, 0x3b, 0x627, 0x3b, 0x646, 0x3b, 0x49b, 0x430, 0x4a3, 0x2e, 0x3b, 0x430, 0x49b, 0x43f, 0x2e, 0x3b, 0x43d,
+0x430, 0x443, 0x2e, 0x3b, 0x441, 0x4d9, 0x443, 0x2e, 0x3b, 0x43c, 0x430, 0x43c, 0x2e, 0x3b, 0x43c, 0x430, 0x443, 0x2e, 0x3b, 0x448,
+0x456, 0x43b, 0x2e, 0x3b, 0x442, 0x430, 0x43c, 0x2e, 0x3b, 0x49b, 0x44b, 0x440, 0x2e, 0x3b, 0x49b, 0x430, 0x437, 0x2e, 0x3b, 0x49b,
+0x430, 0x440, 0x2e, 0x3b, 0x436, 0x435, 0x43b, 0x442, 0x2e, 0x3b, 0x49b, 0x430, 0x4a3, 0x442, 0x430, 0x440, 0x3b, 0x430, 0x49b, 0x43f,
+0x430, 0x43d, 0x3b, 0x43d, 0x430, 0x443, 0x440, 0x44b, 0x437, 0x3b, 0x441, 0x4d9, 0x443, 0x456, 0x440, 0x3b, 0x43c, 0x430, 0x43c, 0x44b,
+0x440, 0x3b, 0x43c, 0x430, 0x443, 0x441, 0x44b, 0x43c, 0x3b, 0x448, 0x456, 0x43b, 0x434, 0x435, 0x3b, 0x442, 0x430, 0x43c, 0x44b, 0x437,
+0x3b, 0x49b, 0x44b, 0x440, 0x43a, 0x4af, 0x439, 0x435, 0x43a, 0x3b, 0x49b, 0x430, 0x437, 0x430, 0x43d, 0x3b, 0x49b, 0x430, 0x440, 0x430,
+0x448, 0x430, 0x3b, 0x436, 0x435, 0x43b, 0x442, 0x43e, 0x49b, 0x441, 0x430, 0x43d, 0x3b, 0x6d, 0x75, 0x74, 0x2e, 0x3b, 0x67, 0x61,
+0x73, 0x2e, 0x3b, 0x77, 0x65, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x74, 0x2e, 0x3b, 0x67, 0x69, 0x63, 0x2e, 0x3b, 0x6b, 0x61,
+0x6d, 0x2e, 0x3b, 0x6e, 0x79, 0x61, 0x2e, 0x3b, 0x6b, 0x61, 0x6e, 0x2e, 0x3b, 0x6e, 0x7a, 0x65, 0x2e, 0x3b, 0x75, 0x6b,
+0x77, 0x2e, 0x3b, 0x75, 0x67, 0x75, 0x2e, 0x3b, 0x75, 0x6b, 0x75, 0x2e, 0x3b, 0x4d, 0x75, 0x74, 0x61, 0x72, 0x61, 0x6d,
+0x61, 0x3b, 0x47, 0x61, 0x73, 0x68, 0x79, 0x61, 0x6e, 0x74, 0x61, 0x72, 0x65, 0x3b, 0x57, 0x65, 0x72, 0x75, 0x72, 0x77,
+0x65, 0x3b, 0x4d, 0x61, 0x74, 0x61, 0x3b, 0x47, 0x69, 0x63, 0x75, 0x72, 0x61, 0x6e, 0x73, 0x69, 0x3b, 0x4b, 0x61, 0x6d,
+0x65, 0x6e, 0x61, 0x3b, 0x4e, 0x79, 0x61, 0x6b, 0x61, 0x6e, 0x67, 0x61, 0x3b, 0x4b, 0x61, 0x6e, 0x61, 0x6d, 0x61, 0x3b,
+0x4e, 0x7a, 0x65, 0x6c, 0x69, 0x3b, 0x55, 0x6b, 0x77, 0x61, 0x6b, 0x69, 0x72, 0x61, 0x3b, 0x55, 0x67, 0x75, 0x73, 0x68,
+0x79, 0x69, 0x6e, 0x67, 0x6f, 0x3b, 0x55, 0x6b, 0x75, 0x62, 0x6f, 0x7a, 0x61, 0x3b, 0x42f, 0x43d, 0x432, 0x2e, 0x3b, 0x424,
+0x435, 0x432, 0x440, 0x2e, 0x3b, 0x41c, 0x430, 0x440, 0x2e, 0x3b, 0x410, 0x43f, 0x440, 0x2e, 0x3b, 0x41c, 0x430, 0x439, 0x3b, 0x418,
+0x44e, 0x43d, 0x2e, 0x3b, 0x418, 0x44e, 0x43b, 0x2e, 0x3b, 0x410, 0x432, 0x433, 0x2e, 0x3b, 0x421, 0x435, 0x43d, 0x2e, 0x3b, 0x41e,
+0x43a, 0x442, 0x2e, 0x3b, 0x41d, 0x43e, 0x44f, 0x2e, 0x3b, 0x414, 0x435, 0x43a, 0x2e, 0x3b, 0x42f, 0x43d, 0x432, 0x430, 0x440, 0x44c,
+0x3b, 0x424, 0x435, 0x432, 0x440, 0x430, 0x43b, 0x44c, 0x3b, 0x41c, 0x430, 0x440, 0x442, 0x3b, 0x410, 0x43f, 0x440, 0x435, 0x43b, 0x44c,
+0x3b, 0x41c, 0x430, 0x439, 0x3b, 0x418, 0x44e, 0x43d, 0x44c, 0x3b, 0x418, 0x44e, 0x43b, 0x44c, 0x3b, 0x410, 0x432, 0x433, 0x443, 0x441,
+0x442, 0x3b, 0x421, 0x435, 0x43d, 0x442, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x41e, 0x43a, 0x442, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x41d,
+0x43e, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x414, 0x435, 0x43a, 0x430, 0x431, 0x440, 0x44c, 0x3b, 0x44f, 0x43d, 0x432, 0x2e, 0x3b, 0x444,
+0x435, 0x432, 0x2e, 0x3b, 0x43c, 0x430, 0x440, 0x2e, 0x3b, 0x430, 0x43f, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x439, 0x3b, 0x438, 0x44e,
+0x43d, 0x2e, 0x3b, 0x438, 0x44e, 0x43b, 0x2e, 0x3b, 0x430, 0x432, 0x433, 0x2e, 0x3b, 0x441, 0x435, 0x43d, 0x2e, 0x3b, 0x43e, 0x43a,
+0x442, 0x2e, 0x3b, 0x43d, 0x43e, 0x44f, 0x2e, 0x3b, 0x434, 0x435, 0x43a, 0x2e, 0x3b, 0x44f, 0x43d, 0x432, 0x430, 0x440, 0x44c, 0x3b,
+0x444, 0x435, 0x432, 0x440, 0x430, 0x43b, 0x44c, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x3b, 0x430, 0x43f, 0x440, 0x435, 0x43b, 0x44c, 0x3b,
+0x43c, 0x430, 0x439, 0x3b, 0x438, 0x44e, 0x43d, 0x44c, 0x3b, 0x438, 0x44e, 0x43b, 0x44c, 0x3b, 0x430, 0x432, 0x433, 0x443, 0x441, 0x442,
+0x3b, 0x441, 0x435, 0x43d, 0x442, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x43e, 0x43a, 0x442, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x43d, 0x43e,
+0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x434, 0x435, 0x43a, 0x430, 0x431, 0x440, 0x44c, 0x3b, 0x31, 0xc6d4, 0x3b, 0x32, 0xc6d4, 0x3b, 0x33,
+0xc6d4, 0x3b, 0x34, 0xc6d4, 0x3b, 0x35, 0xc6d4, 0x3b, 0x36, 0xc6d4, 0x3b, 0x37, 0xc6d4, 0x3b, 0x38, 0xc6d4, 0x3b, 0x39, 0xc6d4, 0x3b,
+0x31, 0x30, 0xc6d4, 0x3b, 0x31, 0x31, 0xc6d4, 0x3b, 0x31, 0x32, 0xc6d4, 0x3b, 0x4d, 0x75, 0x74, 0x2e, 0x3b, 0x47, 0x61, 0x73,
+0x2e, 0x3b, 0x57, 0x65, 0x72, 0x2e, 0x3b, 0x4d, 0x61, 0x74, 0x2e, 0x3b, 0x47, 0x69, 0x63, 0x2e, 0x3b, 0x4b, 0x61, 0x6d,
+0x2e, 0x3b, 0x4e, 0x79, 0x61, 0x2e, 0x3b, 0x4b, 0x61, 0x6e, 0x2e, 0x3b, 0x4e, 0x7a, 0x65, 0x2e, 0x3b, 0x55, 0x6b, 0x77,
+0x2e, 0x3b, 0x55, 0x67, 0x75, 0x2e, 0x3b, 0x55, 0x6b, 0x75, 0x2e, 0x3b, 0x4e, 0x7a, 0x65, 0x72, 0x6f, 0x3b, 0x52, 0x75,
+0x68, 0x75, 0x68, 0x75, 0x6d, 0x61, 0x3b, 0x4e, 0x74, 0x77, 0x61, 0x72, 0x61, 0x6e, 0x74, 0x65, 0x3b, 0x4e, 0x64, 0x61,
+0x6d, 0x75, 0x6b, 0x69, 0x7a, 0x61, 0x3b, 0x52, 0x75, 0x73, 0x61, 0x6d, 0x61, 0x3b, 0x52, 0x75, 0x68, 0x65, 0x73, 0x68,
+0x69, 0x3b, 0x4d, 0x75, 0x6b, 0x61, 0x6b, 0x61, 0x72, 0x6f, 0x3b, 0x4e, 0x79, 0x61, 0x6e, 0x64, 0x61, 0x67, 0x61, 0x72,
+0x6f, 0x3b, 0x4e, 0x79, 0x61, 0x6b, 0x61, 0x6e, 0x67, 0x61, 0x3b, 0x47, 0x69, 0x74, 0x75, 0x67, 0x75, 0x74, 0x75, 0x3b,
+0x4d, 0x75, 0x6e, 0x79, 0x6f, 0x6e, 0x79, 0x6f, 0x3b, 0x4b, 0x69, 0x67, 0x61, 0x72, 0x61, 0x6d, 0x61, 0x3b, 0xea1, 0x2e,
+0xe81, 0x2e, 0x3b, 0xe81, 0x2e, 0xe9e, 0x2e, 0x3b, 0xea1, 0xeb5, 0x2e, 0xe99, 0x2e, 0x3b, 0xea1, 0x2e, 0xeaa, 0x2e, 0x3b, 0xe9e,
+0x2e, 0xe9e, 0x2e, 0x3b, 0xea1, 0xeb4, 0x2e, 0xe96, 0x2e, 0x3b, 0xe81, 0x2e, 0xea5, 0x2e, 0x3b, 0xeaa, 0x2e, 0xeab, 0x2e, 0x3b,
+0xe81, 0x2e, 0xe8d, 0x2e, 0x3b, 0xe95, 0x2e, 0xea5, 0x2e, 0x3b, 0xe9e, 0x2e, 0xe88, 0x2e, 0x3b, 0xe97, 0x2e, 0xea7, 0x2e, 0x3b,
+0xea1, 0xeb1, 0xe87, 0xe81, 0xead, 0xe99, 0x3b, 0xe81, 0xeb8, 0xea1, 0xe9e, 0xeb2, 0x3b, 0xea1, 0xeb5, 0xe99, 0xeb2, 0x3b, 0xec0, 0xea1,
+0xeaa, 0xeb2, 0x3b, 0xe9e, 0xeb6, 0xe94, 0xeaa, 0xeb0, 0xe9e, 0xeb2, 0x3b, 0xea1, 0xeb4, 0xe96, 0xeb8, 0xe99, 0xeb2, 0x3b, 0xe81, 0xecd,
+0xea5, 0xeb0, 0xe81, 0xebb, 0xe94, 0x3b, 0xeaa, 0xeb4, 0xe87, 0xeab, 0xeb2, 0x3b, 0xe81, 0xeb1, 0xe99, 0xe8d, 0xeb2, 0x3b, 0xe95, 0xeb8,
+0xea5, 0xeb2, 0x3b, 0xe9e, 0xeb0, 0xe88, 0xeb4, 0xe81, 0x3b, 0xe97, 0xeb1, 0xe99, 0xea7, 0xeb2, 0x3b, 0xea1, 0x2e, 0xe81, 0x2e, 0x3b,
+0xe81, 0x2e, 0xe9e, 0x2e, 0x3b, 0xea1, 0x2e, 0xe99, 0x2e, 0x3b, 0xea1, 0x2e, 0xeaa, 0x2e, 0x3b, 0xe9e, 0x2e, 0xe9e, 0x2e, 0x3b,
+0xea1, 0xeb4, 0x2e, 0xe96, 0x2e, 0x3b, 0xe81, 0x2e, 0xea5, 0x2e, 0x3b, 0xeaa, 0x2e, 0xeab, 0x2e, 0x3b, 0xe81, 0x2e, 0xe8d, 0x2e,
+0x3b, 0xe95, 0x2e, 0xea5, 0x2e, 0x3b, 0xe9e, 0x2e, 0xe88, 0x2e, 0x3b, 0xe97, 0x2e, 0xea7, 0x2e, 0x3b, 0x4a, 0x61, 0x6e, 0x76,
+0x2e, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x2e, 0x3b, 0x4d, 0x61, 0x72, 0x74, 0x73, 0x3b, 0x41, 0x70, 0x72, 0x2e, 0x3b, 0x4d,
+0x61, 0x69, 0x6a, 0x73, 0x3b, 0x4a, 0x16b, 0x6e, 0x2e, 0x3b, 0x4a, 0x16b, 0x6c, 0x2e, 0x3b, 0x41, 0x75, 0x67, 0x2e, 0x3b,
+0x53, 0x65, 0x70, 0x74, 0x2e, 0x3b, 0x4f, 0x6b, 0x74, 0x2e, 0x3b, 0x4e, 0x6f, 0x76, 0x2e, 0x3b, 0x44, 0x65, 0x63, 0x2e,
+0x3b, 0x4a, 0x61, 0x6e, 0x76, 0x101, 0x72, 0x69, 0x73, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x101, 0x72, 0x69, 0x73, 0x3b,
+0x4d, 0x61, 0x72, 0x74, 0x73, 0x3b, 0x41, 0x70, 0x72, 0x12b, 0x6c, 0x69, 0x73, 0x3b, 0x4d, 0x61, 0x69, 0x6a, 0x73, 0x3b,
+0x4a, 0x16b, 0x6e, 0x69, 0x6a, 0x73, 0x3b, 0x4a, 0x16b, 0x6c, 0x69, 0x6a, 0x73, 0x3b, 0x41, 0x75, 0x67, 0x75, 0x73, 0x74,
+0x73, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x73, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x72, 0x69,
+0x73, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x73, 0x3b, 0x44, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x69,
+0x73, 0x3b, 0x6a, 0x61, 0x6e, 0x76, 0x2e, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x73, 0x3b,
+0x61, 0x70, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x69, 0x6a, 0x73, 0x3b, 0x6a, 0x16b, 0x6e, 0x2e, 0x3b, 0x6a, 0x16b, 0x6c, 0x2e,
+0x3b, 0x61, 0x75, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x2e, 0x3b, 0x6f, 0x6b, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76,
+0x2e, 0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b, 0x6a, 0x61, 0x6e, 0x76, 0x101, 0x72, 0x69, 0x73, 0x3b, 0x66, 0x65, 0x62, 0x72,
+0x75, 0x101, 0x72, 0x69, 0x73, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x73, 0x3b, 0x61, 0x70, 0x72, 0x12b, 0x6c, 0x69, 0x73, 0x3b,
+0x6d, 0x61, 0x69, 0x6a, 0x73, 0x3b, 0x6a, 0x16b, 0x6e, 0x69, 0x6a, 0x73, 0x3b, 0x6a, 0x16b, 0x6c, 0x69, 0x6a, 0x73, 0x3b,
+0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x73, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x73, 0x3b, 0x6f,
+0x6b, 0x74, 0x6f, 0x62, 0x72, 0x69, 0x73, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x73, 0x3b, 0x64, 0x65,
+0x63, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x73, 0x3b, 0x79, 0x61, 0x6e, 0x3b, 0x66, 0x62, 0x6c, 0x3b, 0x6d, 0x73, 0x69, 0x3b,
+0x61, 0x70, 0x6c, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x79, 0x75, 0x6e, 0x3b, 0x79, 0x75, 0x6c, 0x3b, 0x61, 0x67, 0x74, 0x3b,
+0x73, 0x74, 0x62, 0x3b, 0x254, 0x74, 0x62, 0x3b, 0x6e, 0x76, 0x62, 0x3b, 0x64, 0x73, 0x62, 0x3b, 0x73, 0xe1, 0x6e, 0x7a,
+0xe1, 0x20, 0x79, 0x61, 0x20, 0x79, 0x61, 0x6d, 0x62, 0x6f, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20,
+0x6d, 0xed, 0x62, 0x61, 0x6c, 0xe9, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x6d, 0xed, 0x73, 0xe1,
+0x74, 0x6f, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x6d, 0xed, 0x6e, 0x65, 0x69, 0x3b, 0x73, 0xe1,
+0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x6d, 0xed, 0x74, 0xe1, 0x6e, 0x6f, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20,
+0x79, 0x61, 0x20, 0x6d, 0x6f, 0x74, 0xf3, 0x62, 0xe1, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x6e,
+0x73, 0x61, 0x6d, 0x62, 0x6f, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x6d, 0x77, 0x61, 0x6d, 0x62,
+0x65, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x6c, 0x69, 0x62, 0x77, 0x61, 0x3b, 0x73, 0xe1, 0x6e,
+0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20, 0x7a, 0xf3, 0x6d, 0x69, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1, 0x20, 0x79, 0x61, 0x20,
+0x7a, 0xf3, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x254, 0x30c, 0x6b, 0x254, 0x301, 0x3b, 0x73, 0xe1, 0x6e, 0x7a, 0xe1,
+0x20, 0x79, 0x61, 0x20, 0x7a, 0xf3, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0xed, 0x62, 0x61, 0x6c, 0xe9, 0x3b, 0x79,
+0x3b, 0x66, 0x3b, 0x6d, 0x3b, 0x61, 0x3b, 0x6d, 0x3b, 0x79, 0x3b, 0x79, 0x3b, 0x61, 0x3b, 0x73, 0x3b, 0x254, 0x3b, 0x6e,
+0x3b, 0x64, 0x3b, 0x73, 0x61, 0x75, 0x73, 0x2e, 0x3b, 0x76, 0x61, 0x73, 0x2e, 0x3b, 0x6b, 0x6f, 0x76, 0x2e, 0x3b, 0x62,
+0x61, 0x6c, 0x2e, 0x3b, 0x67, 0x65, 0x67, 0x2e, 0x3b, 0x62, 0x69, 0x72, 0x17e, 0x2e, 0x3b, 0x6c, 0x69, 0x65, 0x70, 0x2e,
+0x3b, 0x72, 0x75, 0x67, 0x70, 0x2e, 0x3b, 0x72, 0x75, 0x67, 0x73, 0x2e, 0x3b, 0x73, 0x70, 0x61, 0x6c, 0x2e, 0x3b, 0x6c,
+0x61, 0x70, 0x6b, 0x72, 0x2e, 0x3b, 0x67, 0x72, 0x75, 0x6f, 0x64, 0x2e, 0x3b, 0x73, 0x61, 0x75, 0x73, 0x69, 0x73, 0x3b,
+0x76, 0x61, 0x73, 0x61, 0x72, 0x69, 0x73, 0x3b, 0x6b, 0x6f, 0x76, 0x61, 0x73, 0x3b, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x64,
+0x69, 0x73, 0x3b, 0x67, 0x65, 0x67, 0x75, 0x17e, 0x117, 0x3b, 0x62, 0x69, 0x72, 0x17e, 0x65, 0x6c, 0x69, 0x73, 0x3b, 0x6c,
+0x69, 0x65, 0x70, 0x61, 0x3b, 0x72, 0x75, 0x67, 0x70, 0x6a, 0x16b, 0x74, 0x69, 0x73, 0x3b, 0x72, 0x75, 0x67, 0x73, 0x117,
+0x6a, 0x69, 0x73, 0x3b, 0x73, 0x70, 0x61, 0x6c, 0x69, 0x73, 0x3b, 0x6c, 0x61, 0x70, 0x6b, 0x72, 0x69, 0x74, 0x69, 0x73,
+0x3b, 0x67, 0x72, 0x75, 0x6f, 0x64, 0x69, 0x73, 0x3b, 0x53, 0x3b, 0x56, 0x3b, 0x4b, 0x3b, 0x42, 0x3b, 0x47, 0x3b, 0x42,
+0x3b, 0x4c, 0x3b, 0x52, 0x3b, 0x52, 0x3b, 0x53, 0x3b, 0x4c, 0x3b, 0x47, 0x3b, 0x458, 0x430, 0x43d, 0x2e, 0x3b, 0x444, 0x435,
+0x432, 0x2e, 0x3b, 0x43c, 0x430, 0x440, 0x2e, 0x3b, 0x430, 0x43f, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x458, 0x3b, 0x458, 0x443, 0x43d,
+0x2e, 0x3b, 0x458, 0x443, 0x43b, 0x2e, 0x3b, 0x430, 0x432, 0x433, 0x2e, 0x3b, 0x441, 0x435, 0x43f, 0x442, 0x2e, 0x3b, 0x43e, 0x43a,
+0x442, 0x2e, 0x3b, 0x43d, 0x43e, 0x435, 0x43c, 0x2e, 0x3b, 0x434, 0x435, 0x43a, 0x435, 0x43c, 0x2e, 0x3b, 0x458, 0x430, 0x43d, 0x443,
+0x430, 0x440, 0x438, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x443, 0x430, 0x440, 0x438, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x3b, 0x430, 0x43f,
+0x440, 0x438, 0x43b, 0x3b, 0x43c, 0x430, 0x458, 0x3b, 0x458, 0x443, 0x43d, 0x438, 0x3b, 0x458, 0x443, 0x43b, 0x438, 0x3b, 0x430, 0x432,
+0x433, 0x443, 0x441, 0x442, 0x3b, 0x441, 0x435, 0x43f, 0x442, 0x435, 0x43c, 0x432, 0x440, 0x438, 0x3b, 0x43e, 0x43a, 0x442, 0x43e, 0x43c,
+0x432, 0x440, 0x438, 0x3b, 0x43d, 0x43e, 0x435, 0x43c, 0x432, 0x440, 0x438, 0x3b, 0x434, 0x435, 0x43a, 0x435, 0x43c, 0x432, 0x440, 0x438,
+0x3b, 0x458, 0x3b, 0x444, 0x3b, 0x43c, 0x3b, 0x430, 0x3b, 0x43c, 0x3b, 0x458, 0x3b, 0x458, 0x3b, 0x430, 0x3b, 0x441, 0x3b, 0x43e,
+0x3b, 0x43d, 0x3b, 0x434, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x70, 0x72,
+0x3b, 0x4d, 0x65, 0x79, 0x3b, 0x4a, 0x6f, 0x6e, 0x3b, 0x4a, 0x6f, 0x6c, 0x3b, 0x41, 0x6f, 0x67, 0x3b, 0x53, 0x65, 0x70,
+0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x6f, 0x61, 0x72, 0x79,
+0x3b, 0x46, 0x65, 0x62, 0x72, 0x6f, 0x61, 0x72, 0x79, 0x3b, 0x4d, 0x61, 0x72, 0x74, 0x73, 0x61, 0x3b, 0x41, 0x70, 0x72,
+0x69, 0x6c, 0x79, 0x3b, 0x4d, 0x65, 0x79, 0x3b, 0x4a, 0x6f, 0x6e, 0x61, 0x3b, 0x4a, 0x6f, 0x6c, 0x61, 0x79, 0x3b, 0x41,
+0x6f, 0x67, 0x6f, 0x73, 0x69, 0x74, 0x72, 0x61, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x61, 0x6d, 0x62, 0x72, 0x61, 0x3b, 0x4f,
+0x6b, 0x74, 0x6f, 0x62, 0x72, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x61, 0x6d, 0x62, 0x72, 0x61, 0x3b, 0x44, 0x65, 0x73, 0x61,
+0x6d, 0x62, 0x72, 0x61, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x63, 0x3b, 0x41, 0x70, 0x72,
+0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x4f, 0x67, 0x6f, 0x73, 0x3b, 0x53, 0x65,
+0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x69, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61, 0x72,
+0x69, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61, 0x63, 0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c,
+0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x69, 0x3b, 0x4f, 0x67, 0x6f, 0x73, 0x3b,
+0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x4e, 0x6f,
+0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4a, 0x3b, 0x46, 0x3b,
+0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x4f, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b,
+0xd1c, 0xd28, 0xd41, 0x3b, 0xd2b, 0xd46, 0xd2c, 0xd4d, 0xd30, 0xd41, 0x3b, 0xd2e, 0xd3e, 0xd7c, 0x3b, 0xd0f, 0xd2a, 0xd4d, 0xd30, 0xd3f,
+0x3b, 0xd2e, 0xd47, 0xd2f, 0xd4d, 0x3b, 0xd1c, 0xd42, 0xd7a, 0x3b, 0xd1c, 0xd42, 0xd32, 0xd48, 0x3b, 0xd13, 0xd17, 0x3b, 0xd38, 0xd46,
+0xd2a, 0xd4d, 0xd31, 0xd4d, 0xd31, 0xd02, 0x3b, 0xd12, 0xd15, 0xd4d, 0xd1f, 0xd4b, 0x3b, 0xd28, 0xd35, 0xd02, 0x3b, 0xd21, 0xd3f, 0xd38,
+0xd02, 0x3b, 0xd1c, 0xd28, 0xd41, 0xd35, 0xd30, 0xd3f, 0x3b, 0xd2b, 0xd46, 0xd2c, 0xd4d, 0xd30, 0xd41, 0xd35, 0xd30, 0xd3f, 0x3b, 0xd2e,
+0xd3e, 0xd7c, 0xd1a, 0xd4d, 0xd1a, 0xd4d, 0x3b, 0xd0f, 0xd2a, 0xd4d, 0xd30, 0xd3f, 0xd7d, 0x3b, 0xd2e, 0xd47, 0xd2f, 0xd4d, 0x3b, 0xd1c,
+0xd42, 0xd7a, 0x3b, 0xd1c, 0xd42, 0xd32, 0xd48, 0x3b, 0xd06, 0xd17, 0xd38, 0xd4d, 0xd31, 0xd4d, 0xd31, 0xd4d, 0x3b, 0xd38, 0xd46, 0xd2a,
+0xd4d, 0xd31, 0xd4d, 0xd31, 0xd02, 0xd2c, 0xd7c, 0x3b, 0xd12, 0xd15, 0xd4d, 0xd1f, 0xd4b, 0xd2c, 0xd7c, 0x3b, 0xd28, 0xd35, 0xd02, 0xd2c,
+0xd7c, 0x3b, 0xd21, 0xd3f, 0xd38, 0xd02, 0xd2c, 0xd7c, 0x3b, 0xd1c, 0x3b, 0xd2b, 0xd46, 0x3b, 0xd2e, 0xd3e, 0x3b, 0xd0f, 0x3b, 0xd2e,
+0xd47, 0x3b, 0xd1c, 0xd42, 0x3b, 0xd1c, 0xd42, 0x3b, 0xd13, 0x3b, 0xd38, 0xd46, 0x3b, 0xd12, 0x3b, 0xd28, 0x3b, 0xd21, 0xd3f, 0x3b,
+0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x72, 0x61, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x6a, 0x3b,
+0x120, 0x75, 0x6e, 0x3b, 0x4c, 0x75, 0x6c, 0x3b, 0x41, 0x77, 0x77, 0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x74, 0x74, 0x3b,
+0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x69, 0x10b, 0x3b, 0x4a, 0x61, 0x6e, 0x6e, 0x61, 0x72, 0x3b, 0x46, 0x72, 0x61, 0x72, 0x3b,
+0x4d, 0x61, 0x72, 0x7a, 0x75, 0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x65, 0x6a, 0x6a, 0x75, 0x3b, 0x120, 0x75,
+0x6e, 0x6a, 0x75, 0x3b, 0x4c, 0x75, 0x6c, 0x6a, 0x75, 0x3b, 0x41, 0x77, 0x77, 0x69, 0x73, 0x73, 0x75, 0x3b, 0x53, 0x65,
+0x74, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x75, 0x3b, 0x4f, 0x74, 0x74, 0x75, 0x62, 0x72, 0x75, 0x3b, 0x4e, 0x6f, 0x76, 0x65,
+0x6d, 0x62, 0x72, 0x75, 0x3b, 0x44, 0x69, 0x10b, 0x65, 0x6d, 0x62, 0x72, 0x75, 0x3b, 0x4a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b,
+0x41, 0x3b, 0x4d, 0x3b, 0x120, 0x3b, 0x4c, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x91c, 0x93e,
+0x928, 0x947, 0x3b, 0x92b, 0x947, 0x92c, 0x94d, 0x930, 0x941, 0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x91a, 0x3b, 0x90f, 0x92a, 0x94d, 0x930,
+0x93f, 0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x942, 0x928, 0x3b, 0x91c, 0x941, 0x932, 0x948, 0x3b, 0x911, 0x917, 0x3b, 0x938, 0x947, 0x92a,
+0x94d, 0x91f, 0x947, 0x902, 0x3b, 0x911, 0x915, 0x94d, 0x91f, 0x3b, 0x928, 0x94b, 0x935, 0x94d, 0x939, 0x947, 0x902, 0x3b, 0x921, 0x93f,
+0x938, 0x947, 0x902, 0x3b, 0x91c, 0x93e, 0x928, 0x947, 0x935, 0x93e, 0x930, 0x940, 0x3b, 0x92b, 0x947, 0x92c, 0x94d, 0x930, 0x941, 0x935,
+0x93e, 0x930, 0x940, 0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x91a, 0x3b, 0x90f, 0x92a, 0x94d, 0x930, 0x93f, 0x932, 0x3b, 0x92e, 0x947, 0x3b,
+0x91c, 0x942, 0x928, 0x3b, 0x91c, 0x941, 0x932, 0x948, 0x3b, 0x911, 0x917, 0x938, 0x94d, 0x91f, 0x3b, 0x938, 0x92a, 0x94d, 0x91f, 0x947,
+0x902, 0x92c, 0x930, 0x3b, 0x911, 0x915, 0x94d, 0x91f, 0x94b, 0x92c, 0x930, 0x3b, 0x928, 0x94b, 0x935, 0x94d, 0x939, 0x947, 0x902, 0x92c,
+0x930, 0x3b, 0x921, 0x93f, 0x938, 0x947, 0x902, 0x92c, 0x930, 0x3b, 0x91c, 0x93e, 0x3b, 0x92b, 0x947, 0x3b, 0x92e, 0x93e, 0x3b, 0x90f,
+0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x942, 0x3b, 0x91c, 0x941, 0x3b, 0x911, 0x3b, 0x938, 0x3b, 0x911, 0x3b, 0x928, 0x94b, 0x3b, 0x921,
+0x93f, 0x3b, 0x445, 0x443, 0x43b, 0x3b, 0x4af, 0x445, 0x44d, 0x3b, 0x431, 0x430, 0x440, 0x3b, 0x442, 0x443, 0x443, 0x3b, 0x43b, 0x443,
+0x443, 0x3b, 0x43c, 0x43e, 0x433, 0x3b, 0x43c, 0x43e, 0x440, 0x3b, 0x445, 0x43e, 0x43d, 0x3b, 0x431, 0x438, 0x447, 0x3b, 0x442, 0x430,
+0x445, 0x3b, 0x43d, 0x43e, 0x445, 0x3b, 0x433, 0x430, 0x445, 0x3b, 0x425, 0x443, 0x43b, 0x433, 0x430, 0x43d, 0x430, 0x3b, 0x4ae, 0x445,
+0x44d, 0x440, 0x3b, 0x411, 0x430, 0x440, 0x3b, 0x422, 0x443, 0x443, 0x43b, 0x430, 0x439, 0x3b, 0x41b, 0x443, 0x443, 0x3b, 0x41c, 0x43e,
+0x433, 0x43e, 0x439, 0x3b, 0x41c, 0x43e, 0x440, 0x44c, 0x3b, 0x425, 0x43e, 0x43d, 0x44c, 0x3b, 0x411, 0x438, 0x447, 0x3b, 0x422, 0x430,
+0x445, 0x438, 0x430, 0x3b, 0x41d, 0x43e, 0x445, 0x43e, 0x439, 0x3b, 0x413, 0x430, 0x445, 0x430, 0x439, 0x3b, 0x91c, 0x928, 0x3b, 0x92b,
+0x947, 0x92c, 0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x91a, 0x3b, 0x905, 0x92a, 0x94d, 0x930, 0x93f, 0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x941,
+0x928, 0x3b, 0x91c, 0x941, 0x932, 0x93e, 0x3b, 0x905, 0x917, 0x3b, 0x938, 0x947, 0x92a, 0x94d, 0x91f, 0x3b, 0x905, 0x915, 0x94d, 0x91f,
+0x94b, 0x3b, 0x928, 0x94b, 0x92d, 0x947, 0x3b, 0x921, 0x93f, 0x938, 0x947, 0x3b, 0x91c, 0x928, 0x935, 0x930, 0x940, 0x3b, 0x92b, 0x947,
+0x92c, 0x94d, 0x930, 0x941, 0x905, 0x930, 0x940, 0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x91a, 0x3b, 0x905, 0x92a, 0x94d, 0x930, 0x93f, 0x932,
+0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x941, 0x928, 0x3b, 0x91c, 0x941, 0x932, 0x93e, 0x908, 0x3b, 0x905, 0x917, 0x938, 0x94d, 0x91f, 0x3b,
+0x938, 0x947, 0x92a, 0x94d, 0x91f, 0x947, 0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x905, 0x915, 0x94d, 0x91f, 0x94b, 0x92c, 0x930, 0x3b, 0x928,
+0x94b, 0x92d, 0x947, 0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x921, 0x93f, 0x938, 0x947, 0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x967, 0x3b, 0x968,
+0x3b, 0x969, 0x3b, 0x96a, 0x3b, 0x96b, 0x3b, 0x96c, 0x3b, 0x96d, 0x3b, 0x96e, 0x3b, 0x96f, 0x3b, 0x967, 0x966, 0x3b, 0x967, 0x967,
+0x3b, 0x967, 0x968, 0x3b, 0x91c, 0x928, 0x935, 0x930, 0x940, 0x3b, 0x92b, 0x930, 0x935, 0x930, 0x940, 0x3b, 0x92e, 0x93e, 0x930, 0x94d,
+0x91a, 0x3b, 0x905, 0x92a, 0x94d, 0x930, 0x947, 0x932, 0x3b, 0x92e, 0x908, 0x3b, 0x91c, 0x941, 0x928, 0x3b, 0x91c, 0x941, 0x932, 0x93e,
+0x908, 0x3b, 0x905, 0x917, 0x938, 0x94d, 0x924, 0x3b, 0x938, 0x947, 0x92a, 0x94d, 0x91f, 0x947, 0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x905,
+0x915, 0x94d, 0x91f, 0x94b, 0x92c, 0x930, 0x3b, 0x928, 0x94b, 0x92d, 0x947, 0x92e, 0x94d, 0x92c, 0x930, 0x3b, 0x926, 0x93f, 0x938, 0x92e,
+0x94d, 0x92c, 0x930, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x6d,
+0x61, 0x72, 0x73, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x6a,
+0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72,
+0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65,
+0x73, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6a, 0x61, 0x6e, 0x2e, 0x3b, 0x66, 0x65, 0x62, 0x2e, 0x3b, 0x6d, 0x61, 0x72,
+0x73, 0x3b, 0x61, 0x70, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69,
+0x3b, 0x61, 0x75, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x70, 0x2e, 0x3b, 0x6f, 0x6b, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e,
+0x3b, 0x64, 0x65, 0x73, 0x2e, 0x3b, 0xb1c, 0xb3e, 0xb28, 0xb41, 0xb06, 0xb30, 0xb40, 0x3b, 0xb2b, 0xb47, 0xb2c, 0xb4d, 0xb30, 0xb41,
+0xb5f, 0xb3e, 0xb30, 0xb40, 0x3b, 0xb2e, 0xb3e, 0xb30, 0xb4d, 0xb1a, 0xb4d, 0xb1a, 0x3b, 0xb05, 0xb2a, 0xb4d, 0xb30, 0xb47, 0xb32, 0x3b,
+0xb2e, 0xb47, 0x3b, 0xb1c, 0xb41, 0xb28, 0x3b, 0xb1c, 0xb41, 0xb32, 0xb3e, 0xb07, 0x3b, 0xb05, 0xb17, 0xb37, 0xb4d, 0xb1f, 0x3b, 0xb38,
+0xb47, 0xb2a, 0xb4d, 0xb1f, 0xb47, 0xb2e, 0xb4d, 0xb2c, 0xb30, 0x3b, 0xb05, 0xb15, 0xb4d, 0xb1f, 0xb4b, 0xb2c, 0xb30, 0x3b, 0xb28, 0xb2d,
+0xb47, 0xb2e, 0xb4d, 0xb2c, 0xb30, 0x3b, 0xb21, 0xb3f, 0xb38, 0xb47, 0xb2e, 0xb4d, 0xb2c, 0xb30, 0x3b, 0xb1c, 0xb3e, 0x3b, 0xb2b, 0xb47,
+0x3b, 0xb2e, 0xb3e, 0x3b, 0xb05, 0x3b, 0xb2e, 0xb47, 0x3b, 0xb1c, 0xb41, 0x3b, 0xb1c, 0xb41, 0x3b, 0xb05, 0x3b, 0xb38, 0xb47, 0x3b,
+0xb05, 0x3b, 0xb28, 0x3b, 0xb21, 0xb3f, 0x3b, 0x62c, 0x646, 0x648, 0x631, 0x64a, 0x3b, 0x641, 0x628, 0x631, 0x648, 0x631, 0x64a, 0x3b,
+0x645, 0x627, 0x631, 0x686, 0x3b, 0x627, 0x67e, 0x631, 0x6cc, 0x644, 0x3b, 0x645, 0x6cc, 0x3b, 0x62c, 0x648, 0x646, 0x3b, 0x62c, 0x648,
+0x644, 0x627, 0x6cc, 0x3b, 0x627, 0x6ab, 0x633, 0x62a, 0x3b, 0x633, 0x67e, 0x62a, 0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x648,
+0x628, 0x631, 0x3b, 0x646, 0x648, 0x645, 0x628, 0x631, 0x3b, 0x62f, 0x633, 0x645, 0x628, 0x631, 0x3b, 0x698, 0x627, 0x646, 0x648, 0x6cc,
+0x647, 0x3b, 0x641, 0x648, 0x631, 0x6cc, 0x647, 0x3b, 0x645, 0x627, 0x631, 0x633, 0x3b, 0x622, 0x648, 0x631, 0x6cc, 0x644, 0x3b, 0x645,
+0x647, 0x3b, 0x698, 0x648, 0x626, 0x646, 0x3b, 0x698, 0x648, 0x626, 0x6cc, 0x647, 0x3b, 0x627, 0x648, 0x62a, 0x3b, 0x633, 0x67e, 0x62a,
+0x627, 0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x628, 0x631, 0x3b, 0x646, 0x648, 0x627, 0x645, 0x628, 0x631, 0x3b, 0x62f, 0x633,
+0x627, 0x645, 0x628, 0x631, 0x3b, 0x698, 0x3b, 0x641, 0x3b, 0x645, 0x3b, 0x622, 0x3b, 0x645, 0x3b, 0x698, 0x3b, 0x698, 0x3b, 0x627,
+0x3b, 0x633, 0x3b, 0x627, 0x3b, 0x646, 0x3b, 0x62f, 0x3b, 0x698, 0x627, 0x646, 0x648, 0x6cc, 0x647, 0x654, 0x3b, 0x641, 0x648, 0x631,
+0x6cc, 0x647, 0x654, 0x3b, 0x645, 0x627, 0x631, 0x633, 0x3b, 0x622, 0x648, 0x631, 0x6cc, 0x644, 0x3b, 0x645, 0x647, 0x654, 0x3b, 0x698,
+0x648, 0x626, 0x646, 0x3b, 0x698, 0x648, 0x626, 0x6cc, 0x647, 0x654, 0x3b, 0x627, 0x648, 0x62a, 0x3b, 0x633, 0x67e, 0x62a, 0x627, 0x645,
+0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x628, 0x631, 0x3b, 0x646, 0x648, 0x627, 0x645, 0x628, 0x631, 0x3b, 0x62f, 0x633, 0x627, 0x645,
+0x628, 0x631, 0x3b, 0x62c, 0x3b, 0x641, 0x3b, 0x645, 0x3b, 0x627, 0x3b, 0x645, 0x3b, 0x62c, 0x3b, 0x62c, 0x3b, 0x627, 0x3b, 0x633,
+0x3b, 0x627, 0x3b, 0x646, 0x3b, 0x62f, 0x3b, 0x62c, 0x646, 0x648, 0x3b, 0x641, 0x648, 0x631, 0x6cc, 0x647, 0x654, 0x3b, 0x645, 0x627,
+0x631, 0x633, 0x3b, 0x622, 0x648, 0x631, 0x6cc, 0x644, 0x3b, 0x645, 0x640, 0x6cc, 0x3b, 0x698, 0x648, 0x626, 0x646, 0x3b, 0x62c, 0x648,
+0x644, 0x3b, 0x627, 0x648, 0x62a, 0x3b, 0x633, 0x67e, 0x62a, 0x627, 0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x628, 0x631, 0x3b,
+0x646, 0x648, 0x627, 0x645, 0x628, 0x631, 0x3b, 0x62f, 0x633, 0x645, 0x3b, 0x62c, 0x646, 0x648, 0x631, 0x6cc, 0x3b, 0x641, 0x628, 0x631,
+0x648, 0x631, 0x6cc, 0x3b, 0x645, 0x627, 0x631, 0x686, 0x3b, 0x627, 0x67e, 0x631, 0x6cc, 0x644, 0x3b, 0x645, 0x6cc, 0x3b, 0x62c, 0x648,
+0x646, 0x3b, 0x62c, 0x648, 0x644, 0x627, 0x6cc, 0x3b, 0x627, 0x6af, 0x633, 0x62a, 0x3b, 0x633, 0x67e, 0x62a, 0x645, 0x628, 0x631, 0x3b,
+0x627, 0x6a9, 0x62a, 0x648, 0x628, 0x631, 0x3b, 0x646, 0x648, 0x645, 0x628, 0x631, 0x3b, 0x62f, 0x633, 0x645, 0x628, 0x631, 0x3b, 0x73,
+0x74, 0x79, 0x3b, 0x6c, 0x75, 0x74, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x6b, 0x77, 0x69, 0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x63,
+0x7a, 0x65, 0x3b, 0x6c, 0x69, 0x70, 0x3b, 0x73, 0x69, 0x65, 0x3b, 0x77, 0x72, 0x7a, 0x3b, 0x70, 0x61, 0x17a, 0x3b, 0x6c,
+0x69, 0x73, 0x3b, 0x67, 0x72, 0x75, 0x3b, 0x73, 0x74, 0x79, 0x63, 0x7a, 0x65, 0x144, 0x3b, 0x6c, 0x75, 0x74, 0x79, 0x3b,
+0x6d, 0x61, 0x72, 0x7a, 0x65, 0x63, 0x3b, 0x6b, 0x77, 0x69, 0x65, 0x63, 0x69, 0x65, 0x144, 0x3b, 0x6d, 0x61, 0x6a, 0x3b,
+0x63, 0x7a, 0x65, 0x72, 0x77, 0x69, 0x65, 0x63, 0x3b, 0x6c, 0x69, 0x70, 0x69, 0x65, 0x63, 0x3b, 0x73, 0x69, 0x65, 0x72,
+0x70, 0x69, 0x65, 0x144, 0x3b, 0x77, 0x72, 0x7a, 0x65, 0x73, 0x69, 0x65, 0x144, 0x3b, 0x70, 0x61, 0x17a, 0x64, 0x7a, 0x69,
+0x65, 0x72, 0x6e, 0x69, 0x6b, 0x3b, 0x6c, 0x69, 0x73, 0x74, 0x6f, 0x70, 0x61, 0x64, 0x3b, 0x67, 0x72, 0x75, 0x64, 0x7a,
+0x69, 0x65, 0x144, 0x3b, 0x73, 0x3b, 0x6c, 0x3b, 0x6d, 0x3b, 0x6b, 0x3b, 0x6d, 0x3b, 0x63, 0x3b, 0x6c, 0x3b, 0x73, 0x3b,
+0x77, 0x3b, 0x70, 0x3b, 0x6c, 0x3b, 0x67, 0x3b, 0x73, 0x74, 0x79, 0x63, 0x7a, 0x6e, 0x69, 0x61, 0x3b, 0x6c, 0x75, 0x74,
+0x65, 0x67, 0x6f, 0x3b, 0x6d, 0x61, 0x72, 0x63, 0x61, 0x3b, 0x6b, 0x77, 0x69, 0x65, 0x74, 0x6e, 0x69, 0x61, 0x3b, 0x6d,
+0x61, 0x6a, 0x61, 0x3b, 0x63, 0x7a, 0x65, 0x72, 0x77, 0x63, 0x61, 0x3b, 0x6c, 0x69, 0x70, 0x63, 0x61, 0x3b, 0x73, 0x69,
+0x65, 0x72, 0x70, 0x6e, 0x69, 0x61, 0x3b, 0x77, 0x72, 0x7a, 0x65, 0x15b, 0x6e, 0x69, 0x61, 0x3b, 0x70, 0x61, 0x17a, 0x64,
+0x7a, 0x69, 0x65, 0x72, 0x6e, 0x69, 0x6b, 0x61, 0x3b, 0x6c, 0x69, 0x73, 0x74, 0x6f, 0x70, 0x61, 0x64, 0x61, 0x3b, 0x67,
+0x72, 0x75, 0x64, 0x6e, 0x69, 0x61, 0x3b, 0x6a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x76, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61,
+0x62, 0x72, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x6a, 0x75, 0x6e, 0x3b, 0x6a, 0x75, 0x6c, 0x3b, 0x61, 0x67, 0x6f, 0x3b, 0x73,
+0x65, 0x74, 0x3b, 0x6f, 0x75, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x65, 0x7a, 0x3b, 0x6a, 0x61, 0x6e, 0x65, 0x69,
+0x72, 0x6f, 0x3b, 0x66, 0x65, 0x76, 0x65, 0x72, 0x65, 0x69, 0x72, 0x6f, 0x3b, 0x6d, 0x61, 0x72, 0xe7, 0x6f, 0x3b, 0x61,
+0x62, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x69, 0x6f, 0x3b, 0x6a, 0x75, 0x6e, 0x68, 0x6f, 0x3b, 0x6a, 0x75, 0x6c, 0x68,
+0x6f, 0x3b, 0x61, 0x67, 0x6f, 0x73, 0x74, 0x6f, 0x3b, 0x73, 0x65, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x6f, 0x75,
+0x74, 0x75, 0x62, 0x72, 0x6f, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x64, 0x65, 0x7a, 0x65, 0x6d,
+0x62, 0x72, 0x6f, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x76, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x62, 0x72, 0x3b,
+0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x3b,
+0x4f, 0x75, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x7a, 0x3b, 0x4a, 0x61, 0x6e, 0x65, 0x69, 0x72, 0x6f, 0x3b,
+0x46, 0x65, 0x76, 0x65, 0x72, 0x65, 0x69, 0x72, 0x6f, 0x3b, 0x4d, 0x61, 0x72, 0xe7, 0x6f, 0x3b, 0x41, 0x62, 0x72, 0x69,
+0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x6f, 0x3b, 0x4a, 0x75, 0x6e, 0x68, 0x6f, 0x3b, 0x4a, 0x75, 0x6c, 0x68, 0x6f, 0x3b, 0x41,
+0x67, 0x6f, 0x73, 0x74, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x4f, 0x75, 0x74, 0x75, 0x62,
+0x72, 0x6f, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x44, 0x65, 0x7a, 0x65, 0x6d, 0x62, 0x72, 0x6f,
+0x3b, 0xa1c, 0xa28, 0xa35, 0xa30, 0xa40, 0x3b, 0xa2b, 0xa3c, 0xa30, 0xa35, 0xa30, 0xa40, 0x3b, 0xa2e, 0xa3e, 0xa30, 0xa1a, 0x3b, 0xa05,
+0xa2a, 0xa4d, 0xa30, 0xa48, 0xa32, 0x3b, 0xa2e, 0xa08, 0x3b, 0xa1c, 0xa42, 0xa28, 0x3b, 0xa1c, 0xa41, 0xa32, 0xa3e, 0xa08, 0x3b, 0xa05,
+0xa17, 0xa38, 0xa24, 0x3b, 0xa38, 0xa24, 0xa70, 0xa2c, 0xa30, 0x3b, 0xa05, 0xa15, 0xa24, 0xa42, 0xa2c, 0xa30, 0x3b, 0xa28, 0xa35, 0xa70,
+0xa2c, 0xa30, 0x3b, 0xa26, 0xa38, 0xa70, 0xa2c, 0xa30, 0x3b, 0xa1c, 0x3b, 0xa2b, 0x3b, 0xa2e, 0xa3e, 0x3b, 0xa05, 0x3b, 0xa2e, 0x3b,
+0xa1c, 0xa42, 0x3b, 0xa1c, 0xa41, 0x3b, 0xa05, 0x3b, 0xa38, 0x3b, 0xa05, 0x3b, 0xa28, 0x3b, 0xa26, 0x3b, 0x62c, 0x646, 0x648, 0x631,
+0x6cc, 0x3b, 0x641, 0x631, 0x648, 0x631, 0x6cc, 0x3b, 0x645, 0x627, 0x631, 0x686, 0x3b, 0x627, 0x67e, 0x631, 0x6cc, 0x644, 0x3b, 0x645,
+0x626, 0x3b, 0x62c, 0x648, 0x646, 0x3b, 0x62c, 0x648, 0x644, 0x627, 0x626, 0x6cc, 0x3b, 0x627, 0x6af, 0x633, 0x62a, 0x3b, 0x633, 0x62a,
+0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x648, 0x628, 0x631, 0x3b, 0x646, 0x648, 0x645, 0x628, 0x631, 0x3b, 0x62f, 0x633, 0x645,
+0x628, 0x631, 0x3b, 0x73, 0x63, 0x68, 0x61, 0x6e, 0x2e, 0x3b, 0x66, 0x61, 0x76, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x73,
+0x3b, 0x61, 0x76, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x74, 0x67, 0x3b, 0x7a, 0x65, 0x72, 0x63, 0x6c, 0x2e, 0x3b, 0x66, 0x61,
+0x6e, 0x2e, 0x3b, 0x61, 0x76, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x74, 0x74, 0x2e, 0x3b, 0x6f, 0x63, 0x74, 0x2e, 0x3b,
+0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b, 0x73, 0x63, 0x68, 0x61, 0x6e, 0x65, 0x72, 0x3b, 0x66, 0x61,
+0x76, 0x72, 0x65, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x76, 0x72, 0x69, 0x67, 0x6c, 0x3b, 0x6d, 0x61, 0x74,
+0x67, 0x3b, 0x7a, 0x65, 0x72, 0x63, 0x6c, 0x61, 0x64, 0x75, 0x72, 0x3b, 0x66, 0x61, 0x6e, 0x61, 0x64, 0x75, 0x72, 0x3b,
+0x61, 0x76, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x74, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x63, 0x74, 0x6f,
+0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65,
+0x72, 0x3b, 0x53, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x5a, 0x3b, 0x46, 0x3b, 0x41, 0x3b, 0x53, 0x3b,
+0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x69, 0x61, 0x6e, 0x2e, 0x3b, 0x66, 0x65, 0x62, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x2e,
+0x3b, 0x61, 0x70, 0x72, 0x2e, 0x3b, 0x6d, 0x61, 0x69, 0x3b, 0x69, 0x75, 0x6e, 0x2e, 0x3b, 0x69, 0x75, 0x6c, 0x2e, 0x3b,
+0x61, 0x75, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x2e, 0x3b, 0x6f, 0x63, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e,
+0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b, 0x69, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x65, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75,
+0x61, 0x72, 0x69, 0x65, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x69, 0x65, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x69, 0x65, 0x3b,
+0x6d, 0x61, 0x69, 0x3b, 0x69, 0x75, 0x6e, 0x69, 0x65, 0x3b, 0x69, 0x75, 0x6c, 0x69, 0x65, 0x3b, 0x61, 0x75, 0x67, 0x75,
+0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x65, 0x3b, 0x6f, 0x63, 0x74, 0x6f, 0x6d, 0x62,
+0x72, 0x69, 0x65, 0x3b, 0x6e, 0x6f, 0x69, 0x65, 0x6d, 0x62, 0x72, 0x69, 0x65, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62,
+0x72, 0x69, 0x65, 0x3b, 0x49, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x41, 0x3b,
+0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x42f, 0x43d, 0x432, 0x2e, 0x3b, 0x424, 0x435, 0x432, 0x440, 0x2e, 0x3b, 0x41c,
+0x430, 0x440, 0x442, 0x3b, 0x410, 0x43f, 0x440, 0x2e, 0x3b, 0x41c, 0x430, 0x439, 0x3b, 0x418, 0x44e, 0x43d, 0x44c, 0x3b, 0x418, 0x44e,
+0x43b, 0x44c, 0x3b, 0x410, 0x432, 0x433, 0x2e, 0x3b, 0x421, 0x435, 0x43d, 0x442, 0x2e, 0x3b, 0x41e, 0x43a, 0x442, 0x2e, 0x3b, 0x41d,
+0x43e, 0x44f, 0x431, 0x2e, 0x3b, 0x414, 0x435, 0x43a, 0x2e, 0x3b, 0x42f, 0x3b, 0x424, 0x3b, 0x41c, 0x3b, 0x410, 0x3b, 0x41c, 0x3b,
+0x418, 0x3b, 0x418, 0x3b, 0x410, 0x3b, 0x421, 0x3b, 0x41e, 0x3b, 0x41d, 0x3b, 0x414, 0x3b, 0x44f, 0x43d, 0x432, 0x2e, 0x3b, 0x444,
+0x435, 0x432, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x430, 0x3b, 0x430, 0x43f, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x44f, 0x3b,
+0x438, 0x44e, 0x43d, 0x44f, 0x3b, 0x438, 0x44e, 0x43b, 0x44f, 0x3b, 0x430, 0x432, 0x433, 0x2e, 0x3b, 0x441, 0x435, 0x43d, 0x442, 0x2e,
+0x3b, 0x43e, 0x43a, 0x442, 0x2e, 0x3b, 0x43d, 0x43e, 0x44f, 0x431, 0x2e, 0x3b, 0x434, 0x435, 0x43a, 0x2e, 0x3b, 0x44f, 0x43d, 0x432,
+0x430, 0x440, 0x44f, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x430, 0x43b, 0x44f, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x430, 0x3b, 0x430, 0x43f,
+0x440, 0x435, 0x43b, 0x44f, 0x3b, 0x43c, 0x430, 0x44f, 0x3b, 0x438, 0x44e, 0x43d, 0x44f, 0x3b, 0x438, 0x44e, 0x43b, 0x44f, 0x3b, 0x430,
+0x432, 0x433, 0x443, 0x441, 0x442, 0x430, 0x3b, 0x441, 0x435, 0x43d, 0x442, 0x44f, 0x431, 0x440, 0x44f, 0x3b, 0x43e, 0x43a, 0x442, 0x44f,
+0x431, 0x440, 0x44f, 0x3b, 0x43d, 0x43e, 0x44f, 0x431, 0x440, 0x44f, 0x3b, 0x434, 0x435, 0x43a, 0x430, 0x431, 0x440, 0x44f, 0x3b, 0x4e,
+0x79, 0x65, 0x3b, 0x46, 0x75, 0x6c, 0x3b, 0x4d, 0x62, 0xe4, 0x3b, 0x4e, 0x67, 0x75, 0x3b, 0x42, 0xea, 0x6c, 0x3b, 0x46,
+0xf6, 0x6e, 0x3b, 0x4c, 0x65, 0x6e, 0x3b, 0x4b, 0xfc, 0x6b, 0x3b, 0x4d, 0x76, 0x75, 0x3b, 0x4e, 0x67, 0x62, 0x3b, 0x4e,
+0x61, 0x62, 0x3b, 0x4b, 0x61, 0x6b, 0x3b, 0x4e, 0x79, 0x65, 0x6e, 0x79, 0x65, 0x3b, 0x46, 0x75, 0x6c, 0x75, 0x6e, 0x64,
+0xef, 0x67, 0x69, 0x3b, 0x4d, 0x62, 0xe4, 0x6e, 0x67, 0xfc, 0x3b, 0x4e, 0x67, 0x75, 0x62, 0xf9, 0x65, 0x3b, 0x42, 0xea,
+0x6c, 0xe4, 0x77, 0xfc, 0x3b, 0x46, 0xf6, 0x6e, 0x64, 0x6f, 0x3b, 0x4c, 0x65, 0x6e, 0x67, 0x75, 0x61, 0x3b, 0x4b, 0xfc,
+0x6b, 0xfc, 0x72, 0xfc, 0x3b, 0x4d, 0x76, 0x75, 0x6b, 0x61, 0x3b, 0x4e, 0x67, 0x62, 0x65, 0x72, 0x65, 0x72, 0x65, 0x3b,
+0x4e, 0x61, 0x62, 0xe4, 0x6e, 0x64, 0xfc, 0x72, 0x75, 0x3b, 0x4b, 0x61, 0x6b, 0x61, 0x75, 0x6b, 0x61, 0x3b, 0x4e, 0x3b,
+0x46, 0x3b, 0x4d, 0x3b, 0x4e, 0x3b, 0x42, 0x3b, 0x46, 0x3b, 0x4c, 0x3b, 0x4b, 0x3b, 0x4d, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b,
+0x4b, 0x3b, 0x458, 0x430, 0x43d, 0x3b, 0x444, 0x435, 0x431, 0x3b, 0x43c, 0x430, 0x440, 0x3b, 0x430, 0x43f, 0x440, 0x3b, 0x43c, 0x430,
+0x458, 0x3b, 0x458, 0x443, 0x43d, 0x3b, 0x458, 0x443, 0x43b, 0x3b, 0x430, 0x432, 0x433, 0x3b, 0x441, 0x435, 0x43f, 0x3b, 0x43e, 0x43a,
+0x442, 0x3b, 0x43d, 0x43e, 0x432, 0x3b, 0x434, 0x435, 0x446, 0x3b, 0x458, 0x430, 0x43d, 0x443, 0x430, 0x440, 0x3b, 0x444, 0x435, 0x431,
+0x440, 0x443, 0x430, 0x440, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x3b, 0x430, 0x43f, 0x440, 0x438, 0x43b, 0x3b, 0x43c, 0x430, 0x458, 0x3b,
+0x458, 0x443, 0x43d, 0x3b, 0x458, 0x443, 0x43b, 0x3b, 0x430, 0x432, 0x433, 0x443, 0x441, 0x442, 0x3b, 0x441, 0x435, 0x43f, 0x442, 0x435,
+0x43c, 0x431, 0x430, 0x440, 0x3b, 0x43e, 0x43a, 0x442, 0x43e, 0x431, 0x430, 0x440, 0x3b, 0x43d, 0x43e, 0x432, 0x435, 0x43c, 0x431, 0x430,
+0x440, 0x3b, 0x434, 0x435, 0x446, 0x435, 0x43c, 0x431, 0x430, 0x440, 0x3b, 0x458, 0x430, 0x43d, 0x443, 0x430, 0x440, 0x3b, 0x444, 0x435,
+0x431, 0x440, 0x443, 0x430, 0x440, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x3b, 0x430, 0x43f, 0x440, 0x438, 0x43b, 0x3b, 0x43c, 0x430, 0x458,
+0x3b, 0x458, 0x443, 0x43d, 0x438, 0x3b, 0x458, 0x443, 0x43b, 0x438, 0x3b, 0x430, 0x432, 0x433, 0x443, 0x441, 0x442, 0x3b, 0x441, 0x435,
+0x43f, 0x442, 0x435, 0x43c, 0x431, 0x430, 0x440, 0x3b, 0x43e, 0x43a, 0x442, 0x43e, 0x431, 0x430, 0x440, 0x3b, 0x43d, 0x43e, 0x432, 0x435,
+0x43c, 0x431, 0x430, 0x440, 0x3b, 0x434, 0x435, 0x446, 0x435, 0x43c, 0x431, 0x430, 0x440, 0x3b, 0x6a, 0x61, 0x6e, 0x3b, 0x66, 0x65,
+0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x3b, 0x6a, 0x75,
+0x6c, 0x3b, 0x61, 0x76, 0x67, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x65,
+0x63, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x6d, 0x61, 0x72,
+0x74, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x3b, 0x6a, 0x75, 0x6c, 0x3b,
+0x61, 0x76, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x6f, 0x6b, 0x74,
+0x6f, 0x62, 0x61, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62,
+0x61, 0x72, 0x3b, 0x6a, 0x3b, 0x66, 0x3b, 0x6d, 0x3b, 0x61, 0x3b, 0x6d, 0x3b, 0x6a, 0x3b, 0x6a, 0x3b, 0x61, 0x3b, 0x73,
+0x3b, 0x6f, 0x3b, 0x6e, 0x3b, 0x64, 0x3b, 0x42f, 0x43d, 0x432, 0x430, 0x440, 0x44c, 0x3b, 0x424, 0x435, 0x432, 0x440, 0x430, 0x43b,
+0x44c, 0x3b, 0x41c, 0x430, 0x440, 0x442, 0x44a, 0x438, 0x3b, 0x410, 0x43f, 0x440, 0x435, 0x43b, 0x44c, 0x3b, 0x41c, 0x430, 0x439, 0x3b,
+0x418, 0x44e, 0x43d, 0x44c, 0x3b, 0x418, 0x44e, 0x43b, 0x44c, 0x3b, 0x410, 0x432, 0x433, 0x443, 0x441, 0x442, 0x3b, 0x421, 0x435, 0x43d,
+0x442, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x41e, 0x43a, 0x442, 0x44f, 0x431, 0x440, 0x44c, 0x3b, 0x41d, 0x43e, 0x44f, 0x431, 0x440, 0x44c,
+0x3b, 0x414, 0x435, 0x43a, 0x430, 0x431, 0x440, 0x44c, 0x3b, 0x44f, 0x43d, 0x432, 0x2e, 0x3b, 0x444, 0x435, 0x432, 0x2e, 0x3b, 0x43c,
+0x430, 0x440, 0x2e, 0x3b, 0x430, 0x43f, 0x440, 0x2e, 0x3b, 0x43c, 0x430, 0x44f, 0x3b, 0x438, 0x44e, 0x43d, 0x44b, 0x3b, 0x438, 0x44e,
+0x43b, 0x44b, 0x3b, 0x430, 0x432, 0x433, 0x2e, 0x3b, 0x441, 0x435, 0x43d, 0x2e, 0x3b, 0x43e, 0x43a, 0x442, 0x2e, 0x3b, 0x43d, 0x43e,
+0x44f, 0x2e, 0x3b, 0x434, 0x435, 0x43a, 0x2e, 0x3b, 0x44f, 0x43d, 0x432, 0x430, 0x440, 0x44b, 0x3b, 0x444, 0x435, 0x432, 0x440, 0x430,
+0x43b, 0x44b, 0x3b, 0x43c, 0x430, 0x440, 0x442, 0x44a, 0x438, 0x439, 0x44b, 0x3b, 0x430, 0x43f, 0x440, 0x435, 0x43b, 0x44b, 0x3b, 0x43c,
+0x430, 0x439, 0x44b, 0x3b, 0x438, 0x44e, 0x43d, 0x44b, 0x3b, 0x438, 0x44e, 0x43b, 0x44b, 0x3b, 0x430, 0x432, 0x433, 0x443, 0x441, 0x442,
+0x44b, 0x3b, 0x441, 0x435, 0x43d, 0x442, 0x44f, 0x431, 0x440, 0x44b, 0x3b, 0x43e, 0x43a, 0x442, 0x44f, 0x431, 0x440, 0x44b, 0x3b, 0x43d,
+0x43e, 0x44f, 0x431, 0x440, 0x44b, 0x3b, 0x434, 0x435, 0x43a, 0x430, 0x431, 0x440, 0x44b, 0x3b, 0x50, 0x68, 0x65, 0x3b, 0x4b, 0x6f,
+0x6c, 0x3b, 0x55, 0x62, 0x65, 0x3b, 0x4d, 0x6d, 0x65, 0x3b, 0x4d, 0x6f, 0x74, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x55, 0x70,
+0x75, 0x3b, 0x50, 0x68, 0x61, 0x3b, 0x4c, 0x65, 0x6f, 0x3b, 0x4d, 0x70, 0x68, 0x3b, 0x50, 0x75, 0x6e, 0x3b, 0x54, 0x73,
+0x68, 0x3b, 0x50, 0x68, 0x65, 0x73, 0x65, 0x6b, 0x67, 0x6f, 0x6e, 0x67, 0x3b, 0x48, 0x6c, 0x61, 0x6b, 0x6f, 0x6c, 0x61,
+0x3b, 0x48, 0x6c, 0x61, 0x6b, 0x75, 0x62, 0x65, 0x6c, 0x65, 0x3b, 0x4d, 0x6d, 0x65, 0x73, 0x65, 0x3b, 0x4d, 0x6f, 0x74,
+0x73, 0x68, 0x65, 0x61, 0x6e, 0x6f, 0x6e, 0x67, 0x3b, 0x50, 0x68, 0x75, 0x70, 0x6a, 0x61, 0x6e, 0x65, 0x3b, 0x50, 0x68,
+0x75, 0x70, 0x75, 0x3b, 0x50, 0x68, 0x61, 0x74, 0x61, 0x3b, 0x4c, 0x65, 0x6f, 0x74, 0x73, 0x68, 0x65, 0x3b, 0x4d, 0x70,
+0x68, 0x61, 0x6c, 0x61, 0x6e, 0x65, 0x3b, 0x50, 0x75, 0x6e, 0x64, 0x75, 0x6e, 0x67, 0x77, 0x61, 0x6e, 0x65, 0x3b, 0x54,
+0x73, 0x68, 0x69, 0x74, 0x77, 0x65, 0x3b, 0x46, 0x65, 0x72, 0x3b, 0x54, 0x6c, 0x68, 0x3b, 0x4d, 0x6f, 0x70, 0x3b, 0x4d,
+0x6f, 0x72, 0x3b, 0x4d, 0x6f, 0x74, 0x3b, 0x53, 0x65, 0x65, 0x3b, 0x50, 0x68, 0x75, 0x3b, 0x50, 0x68, 0x61, 0x3b, 0x4c,
+0x77, 0x65, 0x3b, 0x44, 0x69, 0x70, 0x3b, 0x4e, 0x67, 0x77, 0x3b, 0x53, 0x65, 0x64, 0x3b, 0x46, 0x65, 0x72, 0x69, 0x6b,
+0x67, 0x6f, 0x6e, 0x67, 0x3b, 0x54, 0x6c, 0x68, 0x61, 0x6b, 0x6f, 0x6c, 0x65, 0x3b, 0x4d, 0x6f, 0x70, 0x69, 0x74, 0x6c,
+0x6f, 0x3b, 0x4d, 0x6f, 0x72, 0x61, 0x6e, 0x61, 0x6e, 0x67, 0x3b, 0x4d, 0x6f, 0x74, 0x73, 0x68, 0x65, 0x67, 0x61, 0x6e,
+0x61, 0x6e, 0x67, 0x3b, 0x53, 0x65, 0x65, 0x74, 0x65, 0x62, 0x6f, 0x73, 0x69, 0x67, 0x6f, 0x3b, 0x50, 0x68, 0x75, 0x6b,
+0x77, 0x69, 0x3b, 0x50, 0x68, 0x61, 0x74, 0x77, 0x65, 0x3b, 0x4c, 0x77, 0x65, 0x74, 0x73, 0x65, 0x3b, 0x44, 0x69, 0x70,
+0x68, 0x61, 0x6c, 0x61, 0x6e, 0x65, 0x3b, 0x4e, 0x67, 0x77, 0x61, 0x6e, 0x61, 0x74, 0x73, 0x65, 0x6c, 0x65, 0x3b, 0x53,
+0x65, 0x64, 0x69, 0x6d, 0x6f, 0x6e, 0x74, 0x68, 0x6f, 0x6c, 0x65, 0x3b, 0x4e, 0x64, 0x69, 0x3b, 0x4b, 0x75, 0x6b, 0x3b,
+0x4b, 0x75, 0x72, 0x3b, 0x4b, 0x75, 0x62, 0x3b, 0x43, 0x68, 0x76, 0x3b, 0x43, 0x68, 0x6b, 0x3b, 0x43, 0x68, 0x67, 0x3b,
+0x4e, 0x79, 0x61, 0x3b, 0x47, 0x75, 0x6e, 0x3b, 0x47, 0x75, 0x6d, 0x3b, 0x4d, 0x62, 0x3b, 0x5a, 0x76, 0x69, 0x3b, 0x4e,
+0x64, 0x69, 0x72, 0x61, 0x3b, 0x4b, 0x75, 0x6b, 0x61, 0x64, 0x7a, 0x69, 0x3b, 0x4b, 0x75, 0x72, 0x75, 0x6d, 0x65, 0x3b,
+0x4b, 0x75, 0x62, 0x76, 0x75, 0x6d, 0x62, 0x69, 0x3b, 0x43, 0x68, 0x69, 0x76, 0x61, 0x62, 0x76, 0x75, 0x3b, 0x43, 0x68,
+0x69, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x43, 0x68, 0x69, 0x6b, 0x75, 0x6e, 0x67, 0x75, 0x72, 0x75, 0x3b, 0x4e, 0x79, 0x61,
+0x6d, 0x61, 0x76, 0x68, 0x75, 0x76, 0x68, 0x75, 0x3b, 0x47, 0x75, 0x6e, 0x79, 0x61, 0x6e, 0x61, 0x3b, 0x47, 0x75, 0x6d,
+0x69, 0x67, 0x75, 0x72, 0x75, 0x3b, 0x4d, 0x62, 0x75, 0x64, 0x7a, 0x69, 0x3b, 0x5a, 0x76, 0x69, 0x74, 0x61, 0x3b, 0x4e,
+0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x43, 0x3b, 0x43, 0x3b, 0x43, 0x3b, 0x4e, 0x3b, 0x47, 0x3b, 0x47, 0x3b, 0x4d,
+0x3b, 0x5a, 0x3b, 0xda2, 0xdb1, 0x3b, 0xdb4, 0xdd9, 0xdb6, 0x3b, 0xdb8, 0xdcf, 0xdbb, 0xdca, 0x3b, 0xd85, 0xdb4, 0xdca, 0x200d, 0xdbb,
+0xdda, 0xdbd, 0xdca, 0x3b, 0xdb8, 0xdd0, 0xdba, 0xdd2, 0x3b, 0xda2, 0xdd6, 0xdb1, 0xdd2, 0x3b, 0xda2, 0xdd6, 0xdbd, 0xdd2, 0x3b, 0xd85,
+0xd9c, 0xddd, 0x3b, 0xdc3, 0xdd0, 0xdb4, 0xdca, 0x3b, 0xd94, 0xd9a, 0xdca, 0x3b, 0xdb1, 0xddc, 0xdc0, 0xdd0, 0x3b, 0xdaf, 0xdd9, 0xdc3,
+0xdd0, 0x3b, 0xda2, 0xdb1, 0xdc0, 0xdcf, 0xdbb, 0xdd2, 0x3b, 0xdb4, 0xdd9, 0xdb6, 0xdbb, 0xdc0, 0xdcf, 0xdbb, 0xdd2, 0x3b, 0xdb8, 0xdcf,
+0xdbb, 0xdca, 0xdad, 0xdd4, 0x3b, 0xd85, 0xdb4, 0xdca, 0x200d, 0xdbb, 0xdda, 0xdbd, 0xdca, 0x3b, 0xdb8, 0xdd0, 0xdba, 0xdd2, 0x3b, 0xda2,
+0xdd6, 0xdb1, 0xdd2, 0x3b, 0xda2, 0xdd6, 0xdbd, 0xdd2, 0x3b, 0xd85, 0xd9c, 0xddd, 0xdc3, 0xdca, 0xdad, 0xdd4, 0x3b, 0xdc3, 0xdd0, 0xdb4,
+0xdca, 0xdad, 0xdd0, 0xdb8, 0xdca, 0xdb6, 0xdbb, 0xdca, 0x3b, 0xd94, 0xd9a, 0xdca, 0xdad, 0xddd, 0xdb6, 0xdbb, 0xdca, 0x3b, 0xdb1, 0xddc,
+0xdc0, 0xdd0, 0xdb8, 0xdca, 0xdb6, 0xdbb, 0xdca, 0x3b, 0xdaf, 0xdd9, 0xdc3, 0xdd0, 0xdb8, 0xdca, 0xdb6, 0xdbb, 0xdca, 0x3b, 0xda2, 0x3b,
+0xdb4, 0xdd9, 0x3b, 0xdb8, 0xdcf, 0x3b, 0xd85, 0x3b, 0xdb8, 0xdd0, 0x3b, 0xda2, 0xdd6, 0x3b, 0xda2, 0xdd6, 0x3b, 0xd85, 0x3b, 0xdc3,
+0xdd0, 0x3b, 0xd94, 0x3b, 0xdb1, 0xdd9, 0x3b, 0xdaf, 0xdd9, 0x3b, 0xda2, 0xdb1, 0x3b, 0xdb4, 0xdd9, 0xdb6, 0x3b, 0xdb8, 0xdcf, 0xdbb,
+0xdca, 0xdad, 0xdd4, 0x3b, 0xd85, 0xdb4, 0xdca, 0x200d, 0xdbb, 0xdda, 0xdbd, 0xdca, 0x3b, 0xdb8, 0xdd0, 0xdba, 0xdd2, 0x3b, 0xda2, 0xdd6,
+0xdb1, 0xdd2, 0x3b, 0xda2, 0xdd6, 0xdbd, 0xdd2, 0x3b, 0xd85, 0xd9c, 0xddd, 0x3b, 0xdc3, 0xdd0, 0xdb4, 0xdca, 0x3b, 0xd94, 0xd9a, 0xdca,
+0x3b, 0xdb1, 0xddc, 0xdc0, 0xdd0, 0x3b, 0xdaf, 0xdd9, 0xdc3, 0xdd0, 0x3b, 0x42, 0x68, 0x69, 0x3b, 0x56, 0x61, 0x6e, 0x3b, 0x56,
+0x6f, 0x6c, 0x3b, 0x4d, 0x61, 0x62, 0x3b, 0x4e, 0x6b, 0x68, 0x3b, 0x4e, 0x68, 0x6c, 0x3b, 0x4b, 0x68, 0x6f, 0x3b, 0x4e,
+0x67, 0x63, 0x3b, 0x4e, 0x79, 0x6f, 0x3b, 0x4d, 0x70, 0x68, 0x3b, 0x4c, 0x77, 0x65, 0x3b, 0x4e, 0x67, 0x6f, 0x3b, 0x42,
+0x68, 0x69, 0x6d, 0x62, 0x69, 0x64, 0x76, 0x77, 0x61, 0x6e, 0x65, 0x3b, 0x69, 0x4e, 0x64, 0x6c, 0x6f, 0x76, 0x61, 0x6e,
+0x61, 0x3b, 0x69, 0x4e, 0x64, 0x6c, 0x6f, 0x76, 0x75, 0x2d, 0x6c, 0x65, 0x6e, 0x6b, 0x68, 0x75, 0x6c, 0x75, 0x3b, 0x4d,
+0x61, 0x62, 0x61, 0x73, 0x61, 0x3b, 0x69, 0x4e, 0x6b, 0x68, 0x77, 0x65, 0x6b, 0x68, 0x77, 0x65, 0x74, 0x69, 0x3b, 0x69,
+0x4e, 0x68, 0x6c, 0x61, 0x62, 0x61, 0x3b, 0x4b, 0x68, 0x6f, 0x6c, 0x77, 0x61, 0x6e, 0x65, 0x3b, 0x69, 0x4e, 0x67, 0x63,
+0x69, 0x3b, 0x69, 0x4e, 0x79, 0x6f, 0x6e, 0x69, 0x3b, 0x69, 0x4d, 0x70, 0x68, 0x61, 0x6c, 0x61, 0x3b, 0x4c, 0x77, 0x65,
+0x74, 0x69, 0x3b, 0x69, 0x4e, 0x67, 0x6f, 0x6e, 0x67, 0x6f, 0x6e, 0x69, 0x3b, 0x6a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x62,
+0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x70, 0x72, 0x3b, 0x6d, 0xe1, 0x6a, 0x3b, 0x6a, 0xfa, 0x6e, 0x3b, 0x6a, 0xfa, 0x6c,
+0x3b, 0x61, 0x75, 0x67, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x65, 0x63,
+0x3b, 0x6a, 0x61, 0x6e, 0x75, 0xe1, 0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0xe1, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x65,
+0x63, 0x3b, 0x61, 0x70, 0x72, 0xed, 0x6c, 0x3b, 0x6d, 0xe1, 0x6a, 0x3b, 0x6a, 0xfa, 0x6e, 0x3b, 0x6a, 0xfa, 0x6c, 0x3b,
+0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74,
+0xf3, 0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62,
+0x65, 0x72, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0xe1, 0x72, 0x61, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0xe1, 0x72, 0x61, 0x3b,
+0x6d, 0x61, 0x72, 0x63, 0x61, 0x3b, 0x61, 0x70, 0x72, 0xed, 0x6c, 0x61, 0x3b, 0x6d, 0xe1, 0x6a, 0x61, 0x3b, 0x6a, 0xfa,
+0x6e, 0x61, 0x3b, 0x6a, 0xfa, 0x6c, 0x61, 0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x61, 0x3b, 0x73, 0x65, 0x70, 0x74,
+0x65, 0x6d, 0x62, 0x72, 0x61, 0x3b, 0x6f, 0x6b, 0x74, 0xf3, 0x62, 0x72, 0x61, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62,
+0x72, 0x61, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x61, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x66,
+0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x65, 0x63, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x6d,
+0x61, 0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x6a, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x6a, 0x3b, 0x61, 0x76, 0x67, 0x75, 0x73,
+0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b,
+0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6a, 0x61,
+0x6e, 0x2e, 0x3b, 0x66, 0x65, 0x62, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x2e, 0x3b, 0x61, 0x70, 0x72, 0x2e, 0x3b, 0x6d, 0x61,
+0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x2e, 0x3b, 0x6a, 0x75, 0x6c, 0x2e, 0x3b, 0x61, 0x76, 0x67, 0x2e, 0x3b, 0x73, 0x65, 0x70,
+0x2e, 0x3b, 0x6f, 0x6b, 0x74, 0x2e, 0x3b, 0x6e, 0x6f, 0x76, 0x2e, 0x3b, 0x64, 0x65, 0x63, 0x2e, 0x3b, 0x4b, 0x6f, 0x62,
+0x3b, 0x4c, 0x61, 0x62, 0x3b, 0x53, 0x61, 0x64, 0x3b, 0x41, 0x66, 0x72, 0x3b, 0x53, 0x68, 0x61, 0x3b, 0x4c, 0x69, 0x78,
+0x3b, 0x54, 0x6f, 0x64, 0x3b, 0x53, 0x69, 0x64, 0x3b, 0x53, 0x61, 0x67, 0x3b, 0x54, 0x6f, 0x62, 0x3b, 0x4b, 0x49, 0x54,
+0x3b, 0x4c, 0x49, 0x54, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x4b, 0x6f, 0x6f, 0x62, 0x61, 0x61, 0x64, 0x3b, 0x42,
+0x69, 0x73, 0x68, 0x61, 0x20, 0x4c, 0x61, 0x62, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x53, 0x61,
+0x64, 0x64, 0x65, 0x78, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x41, 0x66, 0x72, 0x61, 0x61, 0x64,
+0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x53, 0x68, 0x61, 0x6e, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61,
+0x20, 0x4c, 0x69, 0x78, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x54, 0x6f, 0x64, 0x6f, 0x62, 0x61,
+0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x53, 0x69, 0x64, 0x65, 0x65, 0x64, 0x61, 0x61, 0x64, 0x3b, 0x42,
+0x69, 0x73, 0x68, 0x61, 0x20, 0x53, 0x61, 0x67, 0x61, 0x61, 0x6c, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61,
+0x20, 0x54, 0x6f, 0x62, 0x6e, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x4b, 0x6f, 0x77, 0x20, 0x69,
+0x79, 0x6f, 0x20, 0x54, 0x6f, 0x62, 0x6e, 0x61, 0x61, 0x64, 0x3b, 0x42, 0x69, 0x73, 0x68, 0x61, 0x20, 0x4c, 0x61, 0x62,
+0x61, 0x20, 0x69, 0x79, 0x6f, 0x20, 0x54, 0x6f, 0x62, 0x6e, 0x61, 0x61, 0x64, 0x3b, 0x4b, 0x3b, 0x4c, 0x3b, 0x53, 0x3b,
+0x41, 0x3b, 0x53, 0x3b, 0x4c, 0x3b, 0x54, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x54, 0x3b, 0x4b, 0x3b, 0x4c, 0x3b, 0x65, 0x6e,
+0x65, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x62, 0x72, 0x3b, 0x6d, 0x61, 0x79, 0x6f, 0x3b, 0x6a,
0x75, 0x6e, 0x3b, 0x6a, 0x75, 0x6c, 0x3b, 0x61, 0x67, 0x6f, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x63, 0x74, 0x3b, 0x6e,
-0x6f, 0x76, 0x3b, 0x64, 0x69, 0x63, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x63, 0x3b, 0x41,
-0x70, 0x72, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53,
-0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61,
-0x72, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61, 0x63, 0x68, 0x69, 0x3b, 0x41, 0x70,
-0x72, 0x69, 0x6c, 0x69, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x69, 0x3b,
-0x41, 0x67, 0x6f, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x6f,
-0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x6a,
-0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x6d, 0x61, 0x72, 0x73,
-0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69,
-0x3b, 0x61, 0x75, 0x67, 0x75, 0x73, 0x74, 0x69, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f,
-0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65,
-0x6d, 0x62, 0x65, 0x72, 0x3b, 0x42f, 0x43d, 0x432, 0x3b, 0x424, 0x435, 0x432, 0x3b, 0x41c, 0x430, 0x440, 0x3b, 0x410, 0x43f, 0x440,
-0x3b, 0x41c, 0x430, 0x439, 0x3b, 0x418, 0x44e, 0x43d, 0x3b, 0x418, 0x44e, 0x43b, 0x3b, 0x410, 0x432, 0x433, 0x3b, 0x421, 0x435, 0x43d,
-0x3b, 0x41e, 0x43a, 0x442, 0x3b, 0x41d, 0x43e, 0x44f, 0x3b, 0x414, 0x435, 0x43a, 0x3b, 0x42f, 0x43d, 0x432, 0x430, 0x440, 0x3b, 0x424,
-0x435, 0x432, 0x440, 0x430, 0x43b, 0x3b, 0x41c, 0x430, 0x440, 0x442, 0x3b, 0x410, 0x43f, 0x440, 0x435, 0x43b, 0x3b, 0x41c, 0x430, 0x439,
-0x3b, 0x418, 0x44e, 0x43d, 0x3b, 0x418, 0x44e, 0x43b, 0x3b, 0x410, 0x432, 0x433, 0x443, 0x441, 0x442, 0x3b, 0x421, 0x435, 0x43d, 0x442,
-0x44f, 0x431, 0x440, 0x3b, 0x41e, 0x43a, 0x442, 0x44f, 0x431, 0x440, 0x3b, 0x41d, 0x43e, 0x44f, 0x431, 0x440, 0x3b, 0x414, 0x435, 0x43a,
-0x430, 0x431, 0x440, 0x3b, 0xb9c, 0xba9, 0x2e, 0x3b, 0xbaa, 0xbbf, 0xbaa, 0xbcd, 0x2e, 0x3b, 0xbae, 0xbbe, 0xbb0, 0xbcd, 0x2e, 0x3b,
-0xb8f, 0xbaa, 0xbcd, 0x2e, 0x3b, 0xbae, 0xbc7, 0x3b, 0xb9c, 0xbc2, 0xba9, 0xbcd, 0x3b, 0xb9c, 0xbc2, 0xbb2, 0xbc8, 0x3b, 0xb86, 0xb95,
-0x2e, 0x3b, 0xb9a, 0xbc6, 0xbaa, 0xbcd, 0x2e, 0x3b, 0xb85, 0xb95, 0xbcd, 0x2e, 0x3b, 0xba8, 0xbb5, 0x2e, 0x3b, 0xb9f, 0xbbf, 0xb9a,
-0x2e, 0x3b, 0xb9c, 0xba9, 0xbb5, 0xbb0, 0xbbf, 0x3b, 0xbaa, 0xbbf, 0xbaa, 0xbcd, 0xbb0, 0xbb5, 0xbb0, 0xbbf, 0x3b, 0xbae, 0xbbe, 0xbb0,
-0xbcd, 0xb9a, 0xbcd, 0x3b, 0xb8f, 0xbaa, 0xbcd, 0xbb0, 0xbb2, 0xbcd, 0x3b, 0xbae, 0xbc7, 0x3b, 0xb9c, 0xbc2, 0xba9, 0xbcd, 0x3b, 0xb9c,
-0xbc2, 0xbb2, 0xbc8, 0x3b, 0xb86, 0xb95, 0xbb8, 0xbcd, 0xb9f, 0xbc1, 0x3b, 0xb9a, 0xbc6, 0xbaa, 0xbcd, 0xb9f, 0xbae, 0xbcd, 0xbaa, 0xbb0,
-0xbcd, 0x3b, 0xb85, 0xb95, 0xbcd, 0xb9f, 0xbcb, 0xbaa, 0xbb0, 0xbcd, 0x3b, 0xba8, 0xbb5, 0xbae, 0xbcd, 0xbaa, 0xbb0, 0xbcd, 0x3b, 0xb9f,
-0xbbf, 0xb9a, 0xbae, 0xbcd, 0xbaa, 0xbb0, 0xbcd, 0x3b, 0xb9c, 0x3b, 0xbaa, 0xbbf, 0x3b, 0xbae, 0xbbe, 0x3b, 0xb8f, 0x3b, 0xbae, 0xbc7,
-0x3b, 0xb9c, 0xbc2, 0x3b, 0xb9c, 0xbc2, 0x3b, 0xb86, 0x3b, 0xb9a, 0xbc6, 0x3b, 0xb85, 0x3b, 0xba8, 0x3b, 0xb9f, 0xbbf, 0x3b, 0xb9c,
-0xba9, 0xbb5, 0xbb0, 0xbbf, 0x3b, 0xbaa, 0xbbf, 0xbaa, 0xbcd, 0xbb0, 0xbb5, 0xbb0, 0xbbf, 0x3b, 0xbae, 0xbbe, 0xbb0, 0xbcd, 0xb9a, 0xbcd,
-0x3b, 0xb8f, 0xbaa, 0xbcd, 0xbb0, 0xbb2, 0xbcd, 0x3b, 0xbae, 0xbc7, 0x3b, 0xb9c, 0xbc2, 0xba9, 0xbcd, 0x3b, 0xb9c, 0xbc2, 0xbb2, 0xbc8,
-0x3b, 0xb86, 0xb95, 0xbb8, 0xbcd, 0xb9f, 0xbcd, 0x3b, 0xb9a, 0xbc6, 0xbaa, 0xbcd, 0xb9f, 0xbae, 0xbcd, 0xbaa, 0xbb0, 0xbcd, 0x3b, 0xb85,
-0xb95, 0xbcd, 0xb9f, 0xbcb, 0xbaa, 0xbb0, 0xbcd, 0x3b, 0xba8, 0xbb5, 0xbae, 0xbcd, 0xbaa, 0xbb0, 0xbcd, 0x3b, 0xb9f, 0xbbf, 0xb9a, 0xbae,
-0xbcd, 0xbaa, 0xbb0, 0xbcd, 0x3b, 0xc1c, 0xc28, 0x3b, 0xc2b, 0xc3f, 0xc2c, 0xc4d, 0xc30, 0x3b, 0xc2e, 0xc3e, 0xc30, 0xc4d, 0xc1a, 0xc3f,
-0x3b, 0xc0f, 0xc2a, 0xc4d, 0xc30, 0xc3f, 0x3b, 0xc2e, 0xc47, 0x3b, 0xc1c, 0xc42, 0xc28, 0xc4d, 0x3b, 0xc1c, 0xc42, 0xc32, 0xc48, 0x3b,
-0xc06, 0xc17, 0xc38, 0xc4d, 0xc1f, 0xc41, 0x3b, 0xc38, 0xc46, 0xc2a, 0xc4d, 0xc1f, 0xc46, 0xc02, 0x3b, 0xc05, 0xc15, 0xc4d, 0xc1f, 0xc4b,
-0x3b, 0xc28, 0xc35, 0xc02, 0x3b, 0xc21, 0xc3f, 0xc38, 0xc46, 0xc02, 0x3b, 0xc1c, 0xc28, 0xc35, 0xc30, 0xc3f, 0x3b, 0xc2b, 0xc3f, 0xc2c,
-0xc4d, 0xc30, 0xc35, 0xc30, 0xc3f, 0x3b, 0xc2e, 0xc3e, 0xc30, 0xc4d, 0xc1a, 0xc3f, 0x3b, 0xc0e, 0xc2a, 0xc4d, 0xc30, 0xc3f, 0xc32, 0xc4d,
-0x3b, 0xc2e, 0xc47, 0x3b, 0xc1c, 0xc42, 0xc28, 0xc4d, 0x3b, 0xc1c, 0xc42, 0xc32, 0xc48, 0x3b, 0xc06, 0xc17, 0xc38, 0xc4d, 0xc1f, 0xc41,
-0x3b, 0xc38, 0xc46, 0xc2a, 0xc4d, 0xc1f, 0xc46, 0xc02, 0xc2c, 0xc30, 0xc4d, 0x3b, 0xc05, 0xc15, 0xc4d, 0xc1f, 0xc4b, 0xc2c, 0xc30, 0xc4d,
-0x3b, 0xc28, 0xc35, 0xc02, 0xc2c, 0xc30, 0xc4d, 0x3b, 0xc21, 0xc3f, 0xc38, 0xc46, 0xc02, 0xc2c, 0xc30, 0xc4d, 0x3b, 0xc1c, 0x3b, 0xc2b,
-0xc3f, 0x3b, 0xc2e, 0xc3e, 0x3b, 0xc0f, 0x3b, 0xc2e, 0xc47, 0x3b, 0xc1c, 0xc41, 0x3b, 0xc1c, 0xc41, 0x3b, 0xc06, 0x3b, 0xc38, 0xc46,
-0x3b, 0xc05, 0x3b, 0xc28, 0x3b, 0xc21, 0xc3f, 0x3b, 0xc1c, 0xc28, 0x3b, 0xc2b, 0xc3f, 0xc2c, 0xc4d, 0xc30, 0x3b, 0xc2e, 0xc3e, 0xc30,
-0xc4d, 0xc1a, 0xc3f, 0x3b, 0xc0f, 0xc2a, 0xc4d, 0xc30, 0xc3f, 0x3b, 0xc2e, 0xc47, 0x3b, 0xc1c, 0xc42, 0xc28, 0xc4d, 0x3b, 0xc1c, 0xc42,
-0xc32, 0xc48, 0x3b, 0xc06, 0xc17, 0xc38, 0xc4d, 0xc1f, 0xc41, 0x3b, 0xc38, 0xc46, 0xc2a, 0xc4d, 0xc1f, 0xc46, 0xc02, 0xc2c, 0xc30, 0xc4d,
-0x3b, 0xc05, 0xc15, 0xc4d, 0xc1f, 0xc4b, 0xc2c, 0xc30, 0xc4d, 0x3b, 0xc28, 0xc35, 0xc02, 0xc2c, 0xc30, 0xc4d, 0x3b, 0xc21, 0xc3f, 0xc38,
-0xc46, 0xc02, 0xc2c, 0xc30, 0xc4d, 0x3b, 0xc1c, 0x3b, 0xc2b, 0xc3f, 0x3b, 0xc2e, 0xc3e, 0x3b, 0xc0f, 0x3b, 0xc2e, 0xc47, 0x3b, 0xc1c,
-0xc42, 0x3b, 0xc1c, 0xc41, 0x3b, 0xc06, 0x3b, 0xc38, 0xc46, 0x3b, 0xc05, 0x3b, 0xc28, 0x3b, 0xc21, 0xc3f, 0x3b, 0xe21, 0x2e, 0xe04,
-0x2e, 0x3b, 0xe01, 0x2e, 0xe1e, 0x2e, 0x3b, 0xe21, 0xe35, 0x2e, 0xe04, 0x2e, 0x3b, 0xe40, 0xe21, 0x2e, 0xe22, 0x2e, 0x3b, 0xe1e,
-0x2e, 0xe04, 0x2e, 0x3b, 0xe21, 0xe34, 0x2e, 0xe22, 0x2e, 0x3b, 0xe01, 0x2e, 0xe04, 0x2e, 0x3b, 0xe2a, 0x2e, 0xe04, 0x2e, 0x3b,
-0xe01, 0x2e, 0xe22, 0x2e, 0x3b, 0xe15, 0x2e, 0xe04, 0x2e, 0x3b, 0xe1e, 0x2e, 0xe22, 0x2e, 0x3b, 0xe18, 0x2e, 0xe04, 0x2e, 0x3b,
-0xe21, 0xe01, 0xe23, 0xe32, 0xe04, 0xe21, 0x3b, 0xe01, 0xe38, 0xe21, 0xe20, 0xe32, 0xe1e, 0xe31, 0xe19, 0xe18, 0xe4c, 0x3b, 0xe21, 0xe35,
-0xe19, 0xe32, 0xe04, 0xe21, 0x3b, 0xe40, 0xe21, 0xe29, 0xe32, 0xe22, 0xe19, 0x3b, 0xe1e, 0xe24, 0xe29, 0xe20, 0xe32, 0xe04, 0xe21, 0x3b,
-0xe21, 0xe34, 0xe16, 0xe38, 0xe19, 0xe32, 0xe22, 0xe19, 0x3b, 0xe01, 0xe23, 0xe01, 0xe0e, 0xe32, 0xe04, 0xe21, 0x3b, 0xe2a, 0xe34, 0xe07,
-0xe2b, 0xe32, 0xe04, 0xe21, 0x3b, 0xe01, 0xe31, 0xe19, 0xe22, 0xe32, 0xe22, 0xe19, 0x3b, 0xe15, 0xe38, 0xe25, 0xe32, 0xe04, 0xe21, 0x3b,
-0xe1e, 0xe24, 0xe28, 0xe08, 0xe34, 0xe01, 0xe32, 0xe22, 0xe19, 0x3b, 0xe18, 0xe31, 0xe19, 0xe27, 0xe32, 0xe04, 0xe21, 0x3b, 0xe21, 0x2e,
-0xe04, 0x2e, 0x3b, 0xe01, 0x2e, 0xe1e, 0x2e, 0x3b, 0xe21, 0xe35, 0x2e, 0xe04, 0x2e, 0x3b, 0xe40, 0xe21, 0x2e, 0xe22, 0x2e, 0x3b,
-0xe1e, 0x2e, 0xe04, 0x2e, 0x3b, 0xe21, 0xe34, 0x2e, 0xe22, 0x3b, 0xe01, 0x2e, 0xe04, 0x2e, 0x3b, 0xe2a, 0x2e, 0xe04, 0x2e, 0x3b,
-0xe01, 0x2e, 0xe22, 0x2e, 0x3b, 0xe15, 0x2e, 0xe04, 0x2e, 0x3b, 0xe1e, 0x2e, 0xe22, 0x2e, 0x3b, 0xe18, 0x2e, 0xe04, 0x2e, 0x3b,
-0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf51, 0xf44, 0xf0b, 0xf54, 0xf7c, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf42, 0xf49, 0xf72,
-0xf66, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf66, 0xf74, 0xf58, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b,
-0xf56, 0xf0b, 0xf56, 0xf5e, 0xf72, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf63, 0xf94, 0xf0b, 0xf54, 0xf0b, 0x3b,
-0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf51, 0xfb2, 0xf74, 0xf42, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf56, 0xf51,
-0xf74, 0xf53, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf56, 0xf62, 0xf92, 0xfb1, 0xf51, 0xf0b, 0xf54, 0xf0b, 0x3b,
-0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf51, 0xf42, 0xf74, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf56, 0xf45, 0xf74,
-0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf42, 0xf45, 0xf72, 0xf42, 0xf0b, 0xf54, 0xf0b,
-0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf42, 0xf49, 0xf72, 0xf66, 0xf0b, 0xf54, 0xf0b, 0x3b, 0x1303, 0x1295,
-0x12e9, 0x3b, 0x134c, 0x1265, 0x1229, 0x3b, 0x121b, 0x122d, 0x127d, 0x3b, 0x12a4, 0x1355, 0x1228, 0x3b, 0x121c, 0x12ed, 0x3b, 0x1301, 0x1295, 0x3b,
-0x1301, 0x120b, 0x12ed, 0x3b, 0x12a6, 0x1308, 0x1235, 0x3b, 0x1234, 0x1355, 0x1274, 0x3b, 0x12a6, 0x12ad, 0x1270, 0x3b, 0x1296, 0x126c, 0x121d, 0x3b,
-0x12f2, 0x1234, 0x121d, 0x3b, 0x1303, 0x1295, 0x12e9, 0x12c8, 0x122a, 0x3b, 0x134c, 0x1265, 0x1229, 0x12c8, 0x122a, 0x3b, 0x121b, 0x122d, 0x127d, 0x3b,
-0x12a4, 0x1355, 0x1228, 0x120d, 0x3b, 0x121c, 0x12ed, 0x3b, 0x1301, 0x1295, 0x3b, 0x1301, 0x120b, 0x12ed, 0x3b, 0x12a6, 0x1308, 0x1235, 0x1275, 0x3b,
-0x1234, 0x1355, 0x1274, 0x121d, 0x1260, 0x122d, 0x3b, 0x12a6, 0x12ad, 0x1270, 0x12cd, 0x1260, 0x122d, 0x3b, 0x1296, 0x126c, 0x121d, 0x1260, 0x122d, 0x3b,
-0x12f2, 0x1234, 0x121d, 0x1260, 0x122d, 0x3b, 0x1325, 0x122a, 0x3b, 0x1208, 0x12ab, 0x1272, 0x3b, 0x1218, 0x130b, 0x1262, 0x3b, 0x121a, 0x12eb, 0x12dd,
-0x3b, 0x130d, 0x1295, 0x1266, 0x3b, 0x1230, 0x1290, 0x3b, 0x1213, 0x121d, 0x1208, 0x3b, 0x1290, 0x1213, 0x1230, 0x3b, 0x1218, 0x1235, 0x12a8, 0x3b,
-0x1325, 0x1245, 0x121d, 0x3b, 0x1215, 0x12f3, 0x122d, 0x3b, 0x1273, 0x1215, 0x1233, 0x3b, 0x1325, 0x122a, 0x3b, 0x1208, 0x12ab, 0x1272, 0x1275, 0x3b,
-0x1218, 0x130b, 0x1262, 0x1275, 0x3b, 0x121a, 0x12eb, 0x12dd, 0x12eb, 0x3b, 0x130d, 0x1295, 0x1266, 0x1275, 0x3b, 0x1230, 0x1290, 0x3b, 0x1213, 0x121d,
-0x1208, 0x3b, 0x1290, 0x1213, 0x1230, 0x3b, 0x1218, 0x1235, 0x12a8, 0x1228, 0x121d, 0x3b, 0x1325, 0x1245, 0x121d, 0x1272, 0x3b, 0x1215, 0x12f3, 0x122d,
-0x3b, 0x1273, 0x1215, 0x1233, 0x1235, 0x3b, 0x53, 0x101, 0x6e, 0x3b, 0x46, 0x113, 0x70, 0x3b, 0x4d, 0x61, 0x2bb, 0x61, 0x3b, 0x2bb,
-0x45, 0x70, 0x65, 0x3b, 0x4d, 0x113, 0x3b, 0x53, 0x75, 0x6e, 0x3b, 0x53, 0x69, 0x75, 0x3b, 0x2bb, 0x41, 0x6f, 0x6b, 0x3b,
-0x53, 0x65, 0x70, 0x3b, 0x2bb, 0x4f, 0x6b, 0x61, 0x3b, 0x4e, 0x14d, 0x76, 0x3b, 0x54, 0x12b, 0x73, 0x3b, 0x53, 0x101, 0x6e,
-0x75, 0x61, 0x6c, 0x69, 0x3b, 0x46, 0x113, 0x70, 0x75, 0x65, 0x6c, 0x69, 0x3b, 0x4d, 0x61, 0x2bb, 0x61, 0x73, 0x69, 0x3b,
-0x2bb, 0x45, 0x70, 0x65, 0x6c, 0x65, 0x6c, 0x69, 0x3b, 0x4d, 0x113, 0x3b, 0x53, 0x75, 0x6e, 0x65, 0x3b, 0x53, 0x69, 0x75,
-0x6c, 0x61, 0x69, 0x3b, 0x2bb, 0x41, 0x6f, 0x6b, 0x6f, 0x73, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x69, 0x74, 0x65, 0x6d, 0x61,
-0x3b, 0x2bb, 0x4f, 0x6b, 0x61, 0x74, 0x6f, 0x70, 0x61, 0x3b, 0x4e, 0x14d, 0x76, 0x65, 0x6d, 0x61, 0x3b, 0x54, 0x12b, 0x73,
-0x65, 0x6d, 0x61, 0x3b, 0x53, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x45, 0x3b, 0x4d, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x41, 0x3b,
-0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x54, 0x3b, 0x53, 0x75, 0x6e, 0x3b, 0x59, 0x61, 0x6e, 0x3b, 0x4b, 0x75, 0x6c, 0x3b,
-0x44, 0x7a, 0x69, 0x3b, 0x4d, 0x75, 0x64, 0x3b, 0x4b, 0x68, 0x6f, 0x3b, 0x4d, 0x61, 0x77, 0x3b, 0x4d, 0x68, 0x61, 0x3b,
-0x4e, 0x64, 0x7a, 0x3b, 0x4e, 0x68, 0x6c, 0x3b, 0x48, 0x75, 0x6b, 0x3b, 0x4e, 0x27, 0x77, 0x3b, 0x53, 0x75, 0x6e, 0x67,
-0x75, 0x74, 0x69, 0x3b, 0x4e, 0x79, 0x65, 0x6e, 0x79, 0x65, 0x6e, 0x79, 0x61, 0x6e, 0x69, 0x3b, 0x4e, 0x79, 0x65, 0x6e,
-0x79, 0x61, 0x6e, 0x6b, 0x75, 0x6c, 0x75, 0x3b, 0x44, 0x7a, 0x69, 0x76, 0x61, 0x6d, 0x69, 0x73, 0x6f, 0x6b, 0x6f, 0x3b,
-0x4d, 0x75, 0x64, 0x79, 0x61, 0x78, 0x69, 0x68, 0x69, 0x3b, 0x4b, 0x68, 0x6f, 0x74, 0x61, 0x76, 0x75, 0x78, 0x69, 0x6b,
-0x61, 0x3b, 0x4d, 0x61, 0x77, 0x75, 0x77, 0x61, 0x6e, 0x69, 0x3b, 0x4d, 0x68, 0x61, 0x77, 0x75, 0x72, 0x69, 0x3b, 0x4e,
-0x64, 0x7a, 0x68, 0x61, 0x74, 0x69, 0x3b, 0x4e, 0x68, 0x6c, 0x61, 0x6e, 0x67, 0x75, 0x6c, 0x61, 0x3b, 0x48, 0x75, 0x6b,
-0x75, 0x72, 0x69, 0x3b, 0x4e, 0x27, 0x77, 0x65, 0x6e, 0x64, 0x7a, 0x61, 0x6d, 0x68, 0x61, 0x6c, 0x61, 0x3b, 0x4f, 0x63,
-0x61, 0x3b, 0x15e, 0x75, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x4e, 0x69, 0x73, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x48, 0x61,
-0x7a, 0x3b, 0x54, 0x65, 0x6d, 0x3b, 0x41, 0x11f, 0x75, 0x3b, 0x45, 0x79, 0x6c, 0x3b, 0x45, 0x6b, 0x69, 0x3b, 0x4b, 0x61,
-0x73, 0x3b, 0x41, 0x72, 0x61, 0x3b, 0x4f, 0x63, 0x61, 0x6b, 0x3b, 0x15e, 0x75, 0x62, 0x61, 0x74, 0x3b, 0x4d, 0x61, 0x72,
-0x74, 0x3b, 0x4e, 0x69, 0x73, 0x61, 0x6e, 0x3b, 0x4d, 0x61, 0x79, 0x131, 0x73, 0x3b, 0x48, 0x61, 0x7a, 0x69, 0x72, 0x61,
-0x6e, 0x3b, 0x54, 0x65, 0x6d, 0x6d, 0x75, 0x7a, 0x3b, 0x41, 0x11f, 0x75, 0x73, 0x74, 0x6f, 0x73, 0x3b, 0x45, 0x79, 0x6c,
-0xfc, 0x6c, 0x3b, 0x45, 0x6b, 0x69, 0x6d, 0x3b, 0x4b, 0x61, 0x73, 0x131, 0x6d, 0x3b, 0x41, 0x72, 0x61, 0x6c, 0x131, 0x6b,
-0x3b, 0x4f, 0x3b, 0x15e, 0x3b, 0x4d, 0x3b, 0x4e, 0x3b, 0x4d, 0x3b, 0x48, 0x3b, 0x54, 0x3b, 0x41, 0x3b, 0x45, 0x3b, 0x45,
-0x3b, 0x4b, 0x3b, 0x41, 0x3b, 0x421, 0x456, 0x447, 0x3b, 0x41b, 0x44e, 0x442, 0x3b, 0x411, 0x435, 0x440, 0x3b, 0x41a, 0x432, 0x456,
-0x3b, 0x422, 0x440, 0x430, 0x3b, 0x427, 0x435, 0x440, 0x3b, 0x41b, 0x438, 0x43f, 0x3b, 0x421, 0x435, 0x440, 0x3b, 0x412, 0x435, 0x440,
-0x3b, 0x416, 0x43e, 0x432, 0x3b, 0x41b, 0x438, 0x441, 0x3b, 0x413, 0x440, 0x443, 0x3b, 0x421, 0x456, 0x447, 0x435, 0x43d, 0x44c, 0x3b,
-0x41b, 0x44e, 0x442, 0x438, 0x439, 0x3b, 0x411, 0x435, 0x440, 0x435, 0x437, 0x435, 0x43d, 0x44c, 0x3b, 0x41a, 0x432, 0x456, 0x442, 0x435,
-0x43d, 0x44c, 0x3b, 0x422, 0x440, 0x430, 0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x427, 0x435, 0x440, 0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x41b,
-0x438, 0x43f, 0x435, 0x43d, 0x44c, 0x3b, 0x421, 0x435, 0x440, 0x43f, 0x435, 0x43d, 0x44c, 0x3b, 0x412, 0x435, 0x440, 0x435, 0x441, 0x435,
-0x43d, 0x44c, 0x3b, 0x416, 0x43e, 0x432, 0x442, 0x435, 0x43d, 0x44c, 0x3b, 0x41b, 0x438, 0x441, 0x442, 0x43e, 0x43f, 0x430, 0x434, 0x3b,
-0x413, 0x440, 0x443, 0x434, 0x435, 0x43d, 0x44c, 0x3b, 0x421, 0x3b, 0x41b, 0x3b, 0x411, 0x3b, 0x41a, 0x3b, 0x422, 0x3b, 0x427, 0x3b,
-0x41b, 0x3b, 0x421, 0x3b, 0x412, 0x3b, 0x416, 0x3b, 0x41b, 0x3b, 0x413, 0x3b, 0x441, 0x456, 0x447, 0x2e, 0x3b, 0x43b, 0x44e, 0x442,
-0x2e, 0x3b, 0x431, 0x435, 0x440, 0x2e, 0x3b, 0x43a, 0x432, 0x456, 0x442, 0x2e, 0x3b, 0x442, 0x440, 0x430, 0x432, 0x2e, 0x3b, 0x447,
-0x435, 0x440, 0x432, 0x2e, 0x3b, 0x43b, 0x438, 0x43f, 0x2e, 0x3b, 0x441, 0x435, 0x440, 0x43f, 0x2e, 0x3b, 0x432, 0x435, 0x440, 0x2e,
-0x3b, 0x436, 0x43e, 0x432, 0x442, 0x2e, 0x3b, 0x43b, 0x438, 0x441, 0x442, 0x2e, 0x3b, 0x433, 0x440, 0x443, 0x434, 0x2e, 0x3b, 0x441,
-0x456, 0x447, 0x43d, 0x44f, 0x3b, 0x43b, 0x44e, 0x442, 0x43e, 0x433, 0x43e, 0x3b, 0x431, 0x435, 0x440, 0x435, 0x437, 0x43d, 0x44f, 0x3b,
-0x43a, 0x432, 0x456, 0x442, 0x43d, 0x44f, 0x3b, 0x442, 0x440, 0x430, 0x432, 0x43d, 0x44f, 0x3b, 0x447, 0x435, 0x440, 0x432, 0x43d, 0x44f,
-0x3b, 0x43b, 0x438, 0x43f, 0x43d, 0x44f, 0x3b, 0x441, 0x435, 0x440, 0x43f, 0x43d, 0x44f, 0x3b, 0x432, 0x435, 0x440, 0x435, 0x441, 0x43d,
-0x44f, 0x3b, 0x436, 0x43e, 0x432, 0x442, 0x43d, 0x44f, 0x3b, 0x43b, 0x438, 0x441, 0x442, 0x43e, 0x43f, 0x430, 0x434, 0x430, 0x3b, 0x433,
-0x440, 0x443, 0x434, 0x43d, 0x44f, 0x3b, 0x62c, 0x646, 0x648, 0x631, 0x6cc, 0x3b, 0x641, 0x631, 0x648, 0x631, 0x6cc, 0x3b, 0x645, 0x627,
-0x631, 0x686, 0x3b, 0x627, 0x67e, 0x631, 0x6cc, 0x644, 0x3b, 0x645, 0x626, 0x3b, 0x62c, 0x648, 0x646, 0x3b, 0x62c, 0x648, 0x644, 0x627,
-0x626, 0x3b, 0x627, 0x6af, 0x633, 0x62a, 0x3b, 0x633, 0x62a, 0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x648, 0x628, 0x631, 0x3b,
-0x646, 0x648, 0x645, 0x628, 0x631, 0x3b, 0x62f, 0x633, 0x645, 0x628, 0x631, 0x3b, 0x62c, 0x646, 0x648, 0x3b, 0x641, 0x628, 0x631, 0x3b,
-0x645, 0x627, 0x631, 0x3b, 0x627, 0x67e, 0x631, 0x3b, 0x645, 0x640, 0x6cc, 0x3b, 0x62c, 0x648, 0x646, 0x3b, 0x62c, 0x648, 0x644, 0x3b,
-0x627, 0x6af, 0x633, 0x3b, 0x633, 0x67e, 0x62a, 0x3b, 0x627, 0x6a9, 0x62a, 0x3b, 0x646, 0x648, 0x645, 0x3b, 0x62f, 0x633, 0x645, 0x3b,
-0x59, 0x61, 0x6e, 0x76, 0x3b, 0x46, 0x65, 0x76, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x61, 0x79,
-0x3b, 0x49, 0x79, 0x75, 0x6e, 0x3b, 0x49, 0x79, 0x75, 0x6c, 0x3b, 0x41, 0x76, 0x67, 0x3b, 0x53, 0x65, 0x6e, 0x3b, 0x4f,
-0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x79, 0x61, 0x3b, 0x44, 0x65, 0x6b, 0x3b, 0x59, 0x61, 0x6e, 0x76, 0x61, 0x72, 0x3b, 0x46,
-0x65, 0x76, 0x72, 0x61, 0x6c, 0x3b, 0x4d, 0x61, 0x72, 0x74, 0x3b, 0x41, 0x70, 0x72, 0x65, 0x6c, 0x3b, 0x4d, 0x61, 0x79,
-0x3b, 0x49, 0x79, 0x75, 0x6e, 0x3b, 0x49, 0x79, 0x75, 0x6c, 0x3b, 0x41, 0x76, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x53, 0x65,
-0x6e, 0x74, 0x79, 0x61, 0x62, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x79, 0x61, 0x62, 0x72, 0x3b, 0x4e, 0x6f, 0x79, 0x61, 0x62,
-0x72, 0x3b, 0x44, 0x65, 0x6b, 0x61, 0x62, 0x72, 0x3b, 0x59, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x49,
-0x3b, 0x49, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x31, 0x3b, 0x74,
-0x68, 0x67, 0x20, 0x32, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x33, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x34, 0x3b, 0x74, 0x68, 0x67,
-0x20, 0x35, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x36, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x37, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x38,
-0x3b, 0x74, 0x68, 0x67, 0x20, 0x39, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x31, 0x30, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x31, 0x31,
-0x3b, 0x74, 0x68, 0x67, 0x20, 0x31, 0x32, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x6d, 0x1ed9, 0x74, 0x3b, 0x74, 0x68,
-0xe1, 0x6e, 0x67, 0x20, 0x68, 0x61, 0x69, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x62, 0x61, 0x3b, 0x74, 0x68, 0xe1,
-0x6e, 0x67, 0x20, 0x74, 0x1b0, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x6e, 0x103, 0x6d, 0x3b, 0x74, 0x68, 0xe1, 0x6e,
-0x67, 0x20, 0x73, 0xe1, 0x75, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x62, 0x1ea3, 0x79, 0x3b, 0x74, 0x68, 0xe1, 0x6e,
-0x67, 0x20, 0x74, 0xe1, 0x6d, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x63, 0x68, 0xed, 0x6e, 0x3b, 0x74, 0x68, 0xe1,
-0x6e, 0x67, 0x20, 0x6d, 0x1b0, 0x1edd, 0x69, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x6d, 0x1b0, 0x1edd, 0x69, 0x20, 0x6d,
-0x1ed9, 0x74, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x6d, 0x1b0, 0x1edd, 0x69, 0x20, 0x68, 0x61, 0x69, 0x3b, 0x49, 0x6f,
-0x6e, 0x3b, 0x43, 0x68, 0x77, 0x65, 0x3b, 0x4d, 0x61, 0x77, 0x3b, 0x45, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4d,
-0x65, 0x68, 0x3b, 0x47, 0x6f, 0x72, 0x3b, 0x41, 0x77, 0x73, 0x74, 0x3b, 0x4d, 0x65, 0x64, 0x69, 0x3b, 0x48, 0x79, 0x64,
-0x3b, 0x54, 0x61, 0x63, 0x68, 0x3b, 0x52, 0x68, 0x61, 0x67, 0x3b, 0x49, 0x6f, 0x6e, 0x61, 0x77, 0x72, 0x3b, 0x43, 0x68,
-0x77, 0x65, 0x66, 0x72, 0x6f, 0x72, 0x3b, 0x4d, 0x61, 0x77, 0x72, 0x74, 0x68, 0x3b, 0x45, 0x62, 0x72, 0x69, 0x6c, 0x6c,
-0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4d, 0x65, 0x68, 0x65, 0x66, 0x69, 0x6e, 0x3b, 0x47, 0x6f, 0x72, 0x66, 0x66, 0x65, 0x6e,
-0x6e, 0x61, 0x66, 0x3b, 0x41, 0x77, 0x73, 0x74, 0x3b, 0x4d, 0x65, 0x64, 0x69, 0x3b, 0x48, 0x79, 0x64, 0x72, 0x65, 0x66,
-0x3b, 0x54, 0x61, 0x63, 0x68, 0x77, 0x65, 0x64, 0x64, 0x3b, 0x52, 0x68, 0x61, 0x67, 0x66, 0x79, 0x72, 0x3b, 0x49, 0x3b,
-0x43, 0x3b, 0x4d, 0x3b, 0x45, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x47, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x48, 0x3b, 0x54, 0x3b,
-0x52, 0x3b, 0x49, 0x6f, 0x6e, 0x3b, 0x43, 0x68, 0x77, 0x65, 0x66, 0x3b, 0x4d, 0x61, 0x77, 0x72, 0x74, 0x68, 0x3b, 0x45,
-0x62, 0x72, 0x69, 0x6c, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4d, 0x65, 0x68, 0x3b, 0x47, 0x6f, 0x72, 0x66, 0x66, 0x3b,
-0x41, 0x77, 0x73, 0x74, 0x3b, 0x4d, 0x65, 0x64, 0x69, 0x3b, 0x48, 0x79, 0x64, 0x3b, 0x54, 0x61, 0x63, 0x68, 0x3b, 0x52,
-0x68, 0x61, 0x67, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x74, 0x3b, 0x45, 0x70, 0x72, 0x3b,
-0x4d, 0x65, 0x79, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x61, 0x3b, 0x53, 0x65, 0x70, 0x3b,
-0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x69, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x79, 0x75, 0x77, 0x61, 0x72,
-0x69, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x77, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61, 0x74, 0x73, 0x68, 0x69, 0x3b, 0x45,
-0x70, 0x72, 0x65, 0x6c, 0x69, 0x3b, 0x4d, 0x65, 0x79, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x61,
-0x79, 0x69, 0x3b, 0x41, 0x67, 0x61, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f,
-0x6b, 0x74, 0x68, 0x6f, 0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d,
-0x62, 0x61, 0x3b, 0x1e62, 0x1eb9, 0x301, 0x72, 0x1eb9, 0x301, 0x3b, 0xc8, 0x72, 0xe8, 0x6c, 0xe8, 0x3b, 0x1eb8, 0x72, 0x1eb9, 0x300,
-0x6e, 0xe0, 0x3b, 0xcc, 0x67, 0x62, 0xe9, 0x3b, 0x1eb8, 0x300, 0x62, 0x69, 0x62, 0x69, 0x3b, 0xd2, 0x6b, 0xfa, 0x64, 0x75,
-0x3b, 0x41, 0x67, 0x1eb9, 0x6d, 0x1ecd, 0x3b, 0xd2, 0x67, 0xfa, 0x6e, 0x3b, 0x4f, 0x77, 0x65, 0x77, 0x65, 0x3b, 0x1ecc, 0x300,
-0x77, 0xe0, 0x72, 0xe0, 0x3b, 0x42, 0xe9, 0x6c, 0xfa, 0x3b, 0x1ecc, 0x300, 0x70, 0x1eb9, 0x300, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20,
-0x1e62, 0x1eb9, 0x301, 0x72, 0x1eb9, 0x301, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0xc8, 0x72, 0xe8, 0x6c, 0xe8, 0x3b, 0x4f, 0x1e63, 0xf9,
-0x20, 0x1eb8, 0x72, 0x1eb9, 0x300, 0x6e, 0xe0, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0xcc, 0x67, 0x62, 0xe9, 0x3b, 0x4f, 0x1e63, 0xf9,
-0x20, 0x1eb8, 0x300, 0x62, 0x69, 0x62, 0x69, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0xd2, 0x6b, 0xfa, 0x64, 0x75, 0x3b, 0x4f, 0x1e63,
-0xf9, 0x20, 0x41, 0x67, 0x1eb9, 0x6d, 0x1ecd, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0xd2, 0x67, 0xfa, 0x6e, 0x3b, 0x4f, 0x1e63, 0xf9,
-0x20, 0x4f, 0x77, 0x65, 0x77, 0x65, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0x1ecc, 0x300, 0x77, 0xe0, 0x72, 0xe0, 0x3b, 0x4f, 0x1e63,
-0xf9, 0x20, 0x42, 0xe9, 0x6c, 0xfa, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0x1ecc, 0x300, 0x70, 0x1eb9, 0x300, 0x3b, 0x4a, 0x61, 0x6e,
-0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x73, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x79, 0x3b, 0x4a, 0x75, 0x6e,
-0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x61, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76,
-0x3b, 0x44, 0x69, 0x73, 0x3b, 0x75, 0x4a, 0x61, 0x6e, 0x75, 0x77, 0x61, 0x72, 0x69, 0x3b, 0x75, 0x46, 0x65, 0x62, 0x72,
-0x75, 0x77, 0x61, 0x72, 0x69, 0x3b, 0x75, 0x4d, 0x61, 0x73, 0x68, 0x69, 0x3b, 0x75, 0x2d, 0x41, 0x70, 0x72, 0x65, 0x6c,
-0x69, 0x3b, 0x75, 0x4d, 0x65, 0x79, 0x69, 0x3b, 0x75, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x75, 0x4a, 0x75, 0x6c, 0x61, 0x79,
-0x69, 0x3b, 0x75, 0x41, 0x67, 0x61, 0x73, 0x74, 0x69, 0x3b, 0x75, 0x53, 0x65, 0x70, 0x74, 0x68, 0x65, 0x6d, 0x62, 0x61,
-0x3b, 0x75, 0x2d, 0x4f, 0x6b, 0x74, 0x68, 0x6f, 0x62, 0x61, 0x3b, 0x75, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b,
-0x75, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x77, 0x61, 0x72, 0x69, 0x3b, 0x46, 0x65,
-0x62, 0x72, 0x75, 0x77, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61, 0x73, 0x68, 0x69, 0x3b, 0x41, 0x70, 0x72, 0x65, 0x6c, 0x69,
-0x3b, 0x4d, 0x65, 0x79, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x79, 0x69, 0x3b, 0x41, 0x67,
-0x61, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x68, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x68, 0x6f,
-0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x6a,
-0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x3b, 0x61,
-0x70, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x3b, 0x61,
-0x76, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f,
-0x62, 0x61, 0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x61,
-0x72, 0x3b, 0x4a, 0x2d, 0x67, 0x75, 0x65, 0x72, 0x3b, 0x54, 0x2d, 0x61, 0x72, 0x72, 0x65, 0x65, 0x3b, 0x4d, 0x61, 0x79,
-0x72, 0x6e, 0x74, 0x3b, 0x41, 0x76, 0x72, 0x72, 0x69, 0x6c, 0x3b, 0x42, 0x6f, 0x61, 0x6c, 0x64, 0x79, 0x6e, 0x3b, 0x4d,
-0x2d, 0x73, 0x6f, 0x75, 0x72, 0x65, 0x65, 0x3b, 0x4a, 0x2d, 0x73, 0x6f, 0x75, 0x72, 0x65, 0x65, 0x3b, 0x4c, 0x75, 0x61,
-0x6e, 0x69, 0x73, 0x74, 0x79, 0x6e, 0x3b, 0x4d, 0x2d, 0x66, 0x6f, 0x75, 0x79, 0x69, 0x72, 0x3b, 0x4a, 0x2d, 0x66, 0x6f,
-0x75, 0x79, 0x69, 0x72, 0x3b, 0x4d, 0x2e, 0x48, 0x6f, 0x75, 0x6e, 0x65, 0x79, 0x3b, 0x4d, 0x2e, 0x4e, 0x6f, 0x6c, 0x6c,
-0x69, 0x63, 0x6b, 0x3b, 0x4a, 0x65, 0x72, 0x72, 0x65, 0x79, 0x2d, 0x67, 0x65, 0x75, 0x72, 0x65, 0x65, 0x3b, 0x54, 0x6f,
-0x73, 0x68, 0x69, 0x61, 0x67, 0x68, 0x74, 0x2d, 0x61, 0x72, 0x72, 0x65, 0x65, 0x3b, 0x4d, 0x61, 0x79, 0x72, 0x6e, 0x74,
-0x3b, 0x41, 0x76, 0x65, 0x72, 0x69, 0x6c, 0x3b, 0x42, 0x6f, 0x61, 0x6c, 0x64, 0x79, 0x6e, 0x3b, 0x4d, 0x65, 0x61, 0x6e,
-0x2d, 0x73, 0x6f, 0x75, 0x72, 0x65, 0x65, 0x3b, 0x4a, 0x65, 0x72, 0x72, 0x65, 0x79, 0x2d, 0x73, 0x6f, 0x75, 0x72, 0x65,
-0x65, 0x3b, 0x4c, 0x75, 0x61, 0x6e, 0x69, 0x73, 0x74, 0x79, 0x6e, 0x3b, 0x4d, 0x65, 0x61, 0x6e, 0x2d, 0x66, 0x6f, 0x75,
-0x79, 0x69, 0x72, 0x3b, 0x4a, 0x65, 0x72, 0x72, 0x65, 0x79, 0x2d, 0x66, 0x6f, 0x75, 0x79, 0x69, 0x72, 0x3b, 0x4d, 0x65,
-0x65, 0x20, 0x48, 0x6f, 0x75, 0x6e, 0x65, 0x79, 0x3b, 0x4d, 0x65, 0x65, 0x20, 0x6e, 0x79, 0x20, 0x4e, 0x6f, 0x6c, 0x6c,
-0x69, 0x63, 0x6b, 0x3b, 0x47, 0x65, 0x6e, 0x3b, 0x57, 0x68, 0x65, 0x3b, 0x4d, 0x65, 0x72, 0x3b, 0x45, 0x62, 0x72, 0x3b,
-0x4d, 0x65, 0x3b, 0x45, 0x66, 0x6e, 0x3b, 0x47, 0x6f, 0x72, 0x3b, 0x45, 0x73, 0x74, 0x3b, 0x47, 0x77, 0x6e, 0x3b, 0x48,
-0x65, 0x64, 0x3b, 0x44, 0x75, 0x3b, 0x4b, 0x65, 0x76, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x47, 0x65, 0x6e, 0x76, 0x65, 0x72,
-0x3b, 0x4d, 0x79, 0x73, 0x20, 0x57, 0x68, 0x65, 0x76, 0x72, 0x65, 0x6c, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x4d, 0x65, 0x72,
-0x74, 0x68, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x45, 0x62, 0x72, 0x65, 0x6c, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x4d, 0x65, 0x3b,
-0x4d, 0x79, 0x73, 0x20, 0x45, 0x66, 0x61, 0x6e, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x47, 0x6f, 0x72, 0x74, 0x68, 0x65, 0x72,
-0x65, 0x6e, 0x3b, 0x4d, 0x79, 0x65, 0x20, 0x45, 0x73, 0x74, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x47, 0x77, 0x79, 0x6e, 0x67,
-0x61, 0x6c, 0x61, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x48, 0x65, 0x64, 0x72, 0x61, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x44, 0x75,
-0x3b, 0x4d, 0x79, 0x73, 0x20, 0x4b, 0x65, 0x76, 0x61, 0x72, 0x64, 0x68, 0x75, 0x3b, 0x53, 0x2d, 0x186, 0x3b, 0x4b, 0x2d,
-0x186, 0x3b, 0x45, 0x2d, 0x186, 0x3b, 0x45, 0x2d, 0x4f, 0x3b, 0x45, 0x2d, 0x4b, 0x3b, 0x4f, 0x2d, 0x41, 0x3b, 0x41, 0x2d,
-0x4b, 0x3b, 0x44, 0x2d, 0x186, 0x3b, 0x46, 0x2d, 0x190, 0x3b, 0x186, 0x2d, 0x41, 0x3b, 0x186, 0x2d, 0x4f, 0x3b, 0x4d, 0x2d,
-0x186, 0x3b, 0x53, 0x61, 0x6e, 0x64, 0x61, 0x2d, 0x186, 0x70, 0x25b, 0x70, 0x254, 0x6e, 0x3b, 0x4b, 0x77, 0x61, 0x6b, 0x77,
-0x61, 0x72, 0x2d, 0x186, 0x67, 0x79, 0x65, 0x66, 0x75, 0x6f, 0x3b, 0x45, 0x62, 0x254, 0x77, 0x2d, 0x186, 0x62, 0x65, 0x6e,
-0x65, 0x6d, 0x3b, 0x45, 0x62, 0x254, 0x62, 0x69, 0x72, 0x61, 0x2d, 0x4f, 0x66, 0x6f, 0x72, 0x69, 0x73, 0x75, 0x6f, 0x3b,
-0x45, 0x73, 0x75, 0x73, 0x6f, 0x77, 0x20, 0x41, 0x6b, 0x65, 0x74, 0x73, 0x65, 0x61, 0x62, 0x61, 0x2d, 0x4b, 0x254, 0x74,
-0x254, 0x6e, 0x69, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x62, 0x69, 0x72, 0x61, 0x64, 0x65, 0x2d, 0x41, 0x79, 0x25b, 0x77, 0x6f,
-0x68, 0x6f, 0x6d, 0x75, 0x6d, 0x75, 0x3b, 0x41, 0x79, 0x25b, 0x77, 0x6f, 0x68, 0x6f, 0x2d, 0x4b, 0x69, 0x74, 0x61, 0x77,
-0x6f, 0x6e, 0x73, 0x61, 0x3b, 0x44, 0x69, 0x66, 0x75, 0x75, 0x2d, 0x186, 0x73, 0x61, 0x6e, 0x64, 0x61, 0x61, 0x3b, 0x46,
-0x61, 0x6e, 0x6b, 0x77, 0x61, 0x2d, 0x190, 0x62, 0x254, 0x3b, 0x186, 0x62, 0x25b, 0x73, 0x25b, 0x2d, 0x41, 0x68, 0x69, 0x6e,
-0x69, 0x6d, 0x65, 0x3b, 0x186, 0x62, 0x65, 0x72, 0x25b, 0x66, 0x25b, 0x77, 0x2d, 0x4f, 0x62, 0x75, 0x62, 0x75, 0x6f, 0x3b,
-0x4d, 0x75, 0x6d, 0x75, 0x2d, 0x186, 0x70, 0x25b, 0x6e, 0x69, 0x6d, 0x62, 0x61, 0x3b, 0x91c, 0x93e, 0x928, 0x947, 0x935, 0x93e,
-0x930, 0x940, 0x3b, 0x92b, 0x947, 0x92c, 0x94d, 0x930, 0x941, 0x935, 0x93e, 0x930, 0x940, 0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x91a, 0x3b,
-0x90f, 0x92a, 0x94d, 0x930, 0x93f, 0x932, 0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x942, 0x928, 0x3b, 0x91c, 0x941, 0x932, 0x948, 0x3b, 0x913,
-0x917, 0x938, 0x94d, 0x91f, 0x3b, 0x938, 0x947, 0x92a, 0x94d, 0x91f, 0x947, 0x902, 0x92c, 0x930, 0x3b, 0x913, 0x915, 0x94d, 0x91f, 0x94b,
-0x92c, 0x930, 0x3b, 0x928, 0x94b, 0x935, 0x94d, 0x939, 0x947, 0x902, 0x92c, 0x930, 0x3b, 0x921, 0x93f, 0x938, 0x947, 0x902, 0x92c, 0x930,
-0x3b, 0x4a, 0x65, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x61, 0x3b, 0x45, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x65,
-0x3b, 0x4a, 0x75, 0x75, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x1ecc, 0x67, 0x1ecd, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x1ecc, 0x6b, 0x74,
-0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x69, 0x73, 0x3b, 0x4a, 0x65, 0x6e, 0x1ee5, 0x77, 0x61, 0x72, 0x1ecb, 0x3b, 0x46, 0x65,
-0x62, 0x72, 0x1ee5, 0x77, 0x61, 0x72, 0x1ecb, 0x3b, 0x4d, 0x61, 0x61, 0x63, 0x68, 0x1ecb, 0x3b, 0x45, 0x70, 0x72, 0x65, 0x6c,
-0x3b, 0x4d, 0x65, 0x65, 0x3b, 0x4a, 0x75, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x1ecb, 0x3b, 0x1ecc, 0x67, 0x1ecd, 0x1ecd,
-0x73, 0x74, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x1ecc, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x3b, 0x4e,
-0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4d, 0x62, 0x65, 0x3b, 0x4b,
-0x65, 0x6c, 0x3b, 0x4b, 0x74, 0x169, 0x3b, 0x4b, 0x61, 0x6e, 0x3b, 0x4b, 0x74, 0x6e, 0x3b, 0x54, 0x68, 0x61, 0x3b, 0x4d,
-0x6f, 0x6f, 0x3b, 0x4e, 0x79, 0x61, 0x3b, 0x4b, 0x6e, 0x64, 0x3b, 0x128, 0x6b, 0x75, 0x3b, 0x128, 0x6b, 0x6d, 0x3b, 0x128,
-0x6b, 0x6c, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6d, 0x62, 0x65, 0x65, 0x3b, 0x4d, 0x77, 0x61, 0x69,
-0x20, 0x77, 0x61, 0x20, 0x6b, 0x65, 0x6c, 0x129, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x74,
-0x61, 0x74, 0x169, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x6e, 0x61, 0x3b, 0x4d, 0x77, 0x61,
-0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20,
-0x74, 0x68, 0x61, 0x6e, 0x74, 0x68, 0x61, 0x74, 0x169, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6d, 0x75,
-0x6f, 0x6e, 0x7a, 0x61, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6e, 0x79, 0x61, 0x61, 0x6e, 0x79, 0x61,
-0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x65, 0x6e, 0x64, 0x61, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20,
-0x77, 0x61, 0x20, 0x129, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x129, 0x6b, 0x75,
-0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x129, 0x6d, 0x77, 0x65, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x129,
-0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x69, 0x6c, 0x129, 0x3b, 0x4d, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b,
-0x4b, 0x3b, 0x54, 0x3b, 0x4d, 0x3b, 0x4e, 0x3b, 0x4b, 0x3b, 0x128, 0x3b, 0x128, 0x3b, 0x128, 0x3b, 0x120d, 0x12f0, 0x1275, 0x3b,
-0x12ab, 0x1265, 0x12bd, 0x3b, 0x12ad, 0x1265, 0x120b, 0x3b, 0x134b, 0x1305, 0x12ba, 0x3b, 0x12ad, 0x1262, 0x1245, 0x3b, 0x121d, 0x2f, 0x1275, 0x3b,
-0x12b0, 0x122d, 0x3b, 0x121b, 0x122d, 0x12eb, 0x3b, 0x12eb, 0x12b8, 0x1292, 0x3b, 0x1218, 0x1270, 0x1209, 0x3b, 0x121d, 0x2f, 0x121d, 0x3b, 0x1270,
-0x1215, 0x1233, 0x3b, 0x120d, 0x12f0, 0x1275, 0x122a, 0x3b, 0x12ab, 0x1265, 0x12bd, 0x1265, 0x1272, 0x3b, 0x12ad, 0x1265, 0x120b, 0x3b, 0x134b, 0x1305,
-0x12ba, 0x122a, 0x3b, 0x12ad, 0x1262, 0x1245, 0x122a, 0x3b, 0x121d, 0x12aa, 0x12a4, 0x120d, 0x20, 0x1275, 0x131f, 0x1292, 0x122a, 0x3b, 0x12b0, 0x122d,
-0x12a9, 0x3b, 0x121b, 0x122d, 0x12eb, 0x121d, 0x20, 0x1275, 0x122a, 0x3b, 0x12eb, 0x12b8, 0x1292, 0x20, 0x1218, 0x1233, 0x1245, 0x1208, 0x122a, 0x3b,
-0x1218, 0x1270, 0x1209, 0x3b, 0x121d, 0x12aa, 0x12a4, 0x120d, 0x20, 0x1218, 0x123d, 0x12c8, 0x122a, 0x3b, 0x1270, 0x1215, 0x1233, 0x1235, 0x122a, 0x3b,
-0x120d, 0x3b, 0x12ab, 0x3b, 0x12ad, 0x3b, 0x134b, 0x3b, 0x12ad, 0x3b, 0x121d, 0x3b, 0x12b0, 0x3b, 0x121b, 0x3b, 0x12eb, 0x3b, 0x1218, 0x3b,
-0x121d, 0x3b, 0x1270, 0x3b, 0x5a, 0x65, 0x6e, 0x3b, 0x46, 0x65, 0x76, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x76, 0x72, 0x3b,
-0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x67, 0x3b, 0x4c, 0x75, 0x69, 0x3b, 0x41, 0x76, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x3b,
-0x4f, 0x74, 0x75, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x69, 0x63, 0x3b, 0x5a, 0x65, 0x6e, 0xe2, 0x72, 0x3b, 0x46, 0x65,
-0x76, 0x72, 0xe2, 0x72, 0x3b, 0x4d, 0x61, 0x72, 0xe7, 0x3b, 0x41, 0x76, 0x72, 0xee, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x3b,
-0x4a, 0x75, 0x67, 0x6e, 0x3b, 0x4c, 0x75, 0x69, 0x3b, 0x41, 0x76, 0x6f, 0x73, 0x74, 0x3b, 0x53, 0x65, 0x74, 0x65, 0x6d,
-0x62, 0x61, 0x72, 0x3b, 0x4f, 0x74, 0x75, 0x62, 0x61, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b,
-0x44, 0x69, 0x63, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x5a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a,
-0x3b, 0x4c, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x50, 0x68, 0x61, 0x3b, 0x4c, 0x75, 0x68,
-0x3b, 0x1e70, 0x68, 0x66, 0x3b, 0x4c, 0x61, 0x6d, 0x3b, 0x53, 0x68, 0x75, 0x3b, 0x4c, 0x77, 0x69, 0x3b, 0x4c, 0x77, 0x61,
-0x3b, 0x1e70, 0x68, 0x61, 0x3b, 0x4b, 0x68, 0x75, 0x3b, 0x54, 0x73, 0x68, 0x3b, 0x1e3c, 0x61, 0x72, 0x3b, 0x4e, 0x79, 0x65,
-0x3b, 0x50, 0x68, 0x61, 0x6e, 0x64, 0x6f, 0x3b, 0x4c, 0x75, 0x68, 0x75, 0x68, 0x69, 0x3b, 0x1e70, 0x68, 0x61, 0x66, 0x61,
-0x6d, 0x75, 0x68, 0x77, 0x65, 0x3b, 0x4c, 0x61, 0x6d, 0x62, 0x61, 0x6d, 0x61, 0x69, 0x3b, 0x53, 0x68, 0x75, 0x6e, 0x64,
-0x75, 0x6e, 0x74, 0x68, 0x75, 0x6c, 0x65, 0x3b, 0x46, 0x75, 0x6c, 0x77, 0x69, 0x3b, 0x46, 0x75, 0x6c, 0x77, 0x61, 0x6e,
-0x61, 0x3b, 0x1e70, 0x68, 0x61, 0x6e, 0x67, 0x75, 0x6c, 0x65, 0x3b, 0x4b, 0x68, 0x75, 0x62, 0x76, 0x75, 0x6d, 0x65, 0x64,
-0x7a, 0x69, 0x3b, 0x54, 0x73, 0x68, 0x69, 0x6d, 0x65, 0x64, 0x7a, 0x69, 0x3b, 0x1e3c, 0x61, 0x72, 0x61, 0x3b, 0x4e, 0x79,
-0x65, 0x6e, 0x64, 0x61, 0x76, 0x68, 0x75, 0x73, 0x69, 0x6b, 0x75, 0x3b, 0x64, 0x7a, 0x76, 0x3b, 0x64, 0x7a, 0x64, 0x3b,
-0x74, 0x65, 0x64, 0x3b, 0x61, 0x66, 0x254, 0x3b, 0x64, 0x61, 0x6d, 0x3b, 0x6d, 0x61, 0x73, 0x3b, 0x73, 0x69, 0x61, 0x3b,
-0x64, 0x65, 0x61, 0x3b, 0x61, 0x6e, 0x79, 0x3b, 0x6b, 0x65, 0x6c, 0x3b, 0x61, 0x64, 0x65, 0x3b, 0x64, 0x7a, 0x6d, 0x3b,
-0x64, 0x7a, 0x6f, 0x76, 0x65, 0x3b, 0x64, 0x7a, 0x6f, 0x64, 0x7a, 0x65, 0x3b, 0x74, 0x65, 0x64, 0x6f, 0x78, 0x65, 0x3b,
-0x61, 0x66, 0x254, 0x66, 0x129, 0x65, 0x3b, 0x64, 0x61, 0x6d, 0x61, 0x3b, 0x6d, 0x61, 0x73, 0x61, 0x3b, 0x73, 0x69, 0x61,
-0x6d, 0x6c, 0x254, 0x6d, 0x3b, 0x64, 0x65, 0x61, 0x73, 0x69, 0x61, 0x6d, 0x69, 0x6d, 0x65, 0x3b, 0x61, 0x6e, 0x79, 0x254,
-0x6e, 0x79, 0x254, 0x3b, 0x6b, 0x65, 0x6c, 0x65, 0x3b, 0x61, 0x64, 0x65, 0x25b, 0x6d, 0x65, 0x6b, 0x70, 0x254, 0x78, 0x65,
-0x3b, 0x64, 0x7a, 0x6f, 0x6d, 0x65, 0x3b, 0x64, 0x3b, 0x64, 0x3b, 0x74, 0x3b, 0x61, 0x3b, 0x64, 0x3b, 0x6d, 0x3b, 0x73,
-0x3b, 0x64, 0x3b, 0x61, 0x3b, 0x6b, 0x3b, 0x61, 0x3b, 0x64, 0x3b, 0x49, 0x61, 0x6e, 0x2e, 0x3b, 0x50, 0x65, 0x70, 0x2e,
-0x3b, 0x4d, 0x61, 0x6c, 0x2e, 0x3b, 0x2bb, 0x41, 0x70, 0x2e, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x49, 0x75, 0x6e, 0x2e, 0x3b,
-0x49, 0x75, 0x6c, 0x2e, 0x3b, 0x2bb, 0x41, 0x75, 0x2e, 0x3b, 0x4b, 0x65, 0x70, 0x2e, 0x3b, 0x2bb, 0x4f, 0x6b, 0x2e, 0x3b,
-0x4e, 0x6f, 0x77, 0x2e, 0x3b, 0x4b, 0x65, 0x6b, 0x2e, 0x3b, 0x49, 0x61, 0x6e, 0x75, 0x61, 0x6c, 0x69, 0x3b, 0x50, 0x65,
-0x70, 0x65, 0x6c, 0x75, 0x61, 0x6c, 0x69, 0x3b, 0x4d, 0x61, 0x6c, 0x61, 0x6b, 0x69, 0x3b, 0x2bb, 0x41, 0x70, 0x65, 0x6c,
-0x69, 0x6c, 0x61, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x49, 0x75, 0x6e, 0x65, 0x3b, 0x49, 0x75, 0x6c, 0x61, 0x69, 0x3b, 0x2bb,
-0x41, 0x75, 0x6b, 0x61, 0x6b, 0x65, 0x3b, 0x4b, 0x65, 0x70, 0x61, 0x6b, 0x65, 0x6d, 0x61, 0x70, 0x61, 0x3b, 0x2bb, 0x4f,
-0x6b, 0x61, 0x6b, 0x6f, 0x70, 0x61, 0x3b, 0x4e, 0x6f, 0x77, 0x65, 0x6d, 0x61, 0x70, 0x61, 0x3b, 0x4b, 0x65, 0x6b, 0x65,
-0x6d, 0x61, 0x70, 0x61, 0x3b, 0x45, 0x6e, 0x65, 0x3b, 0x50, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x62, 0x72,
-0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x48, 0x75, 0x6e, 0x3b, 0x48, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x74,
-0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x62, 0x3b, 0x44, 0x69, 0x73, 0x3b, 0x45, 0x6e, 0x65, 0x72, 0x6f, 0x3b, 0x50,
-0x65, 0x62, 0x72, 0x65, 0x72, 0x6f, 0x3b, 0x4d, 0x61, 0x72, 0x73, 0x6f, 0x3b, 0x41, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x4d,
-0x61, 0x79, 0x6f, 0x3b, 0x48, 0x75, 0x6e, 0x79, 0x6f, 0x3b, 0x48, 0x75, 0x6c, 0x79, 0x6f, 0x3b, 0x41, 0x67, 0x6f, 0x73,
-0x74, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x79, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x4f, 0x6b, 0x74, 0x75, 0x62, 0x72, 0x65,
-0x3b, 0x4e, 0x6f, 0x62, 0x79, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x44, 0x69, 0x73, 0x79, 0x65, 0x6d, 0x62, 0x72, 0x65,
-0x3b, 0x45, 0x3b, 0x50, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x48, 0x3b, 0x48, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f,
-0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b,
-0x4d, 0xe4, 0x72, 0x7a, 0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b,
-0x4a, 0x75, 0x6c, 0x69, 0x3b, 0x41, 0x75, 0x67, 0x75, 0x73, 0x63, 0x68, 0x74, 0x3b, 0x53, 0x65, 0x70, 0x74, 0xe4, 0x6d,
-0x62, 0x65, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0xe4, 0x6d, 0x62, 0x65,
-0x72, 0x3b, 0x44, 0x65, 0x7a, 0xe4, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0xa2cd, 0xa1aa, 0x3b, 0xa44d, 0xa1aa, 0x3b, 0xa315, 0xa1aa, 0x3b,
-0xa1d6, 0xa1aa, 0x3b, 0xa26c, 0xa1aa, 0x3b, 0xa0d8, 0xa1aa, 0x3b, 0xa3c3, 0xa1aa, 0x3b, 0xa246, 0xa1aa, 0x3b, 0xa22c, 0xa1aa, 0x3b, 0xa2b0, 0xa1aa,
-0x3b, 0xa2b0, 0xa2aa, 0xa1aa, 0x3b, 0xa2b0, 0xa44b, 0xa1aa, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x74,
-0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x79, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x72, 0x68,
-0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x55, 0x73, 0x69, 0x3b, 0x44, 0x69, 0x73, 0x3b, 0x4a, 0x61, 0x6e,
-0x61, 0x62, 0x61, 0x72, 0x69, 0x3b, 0x75, 0x46, 0x65, 0x62, 0x65, 0x72, 0x62, 0x61, 0x72, 0x69, 0x3b, 0x75, 0x4d, 0x61,
-0x74, 0x6a, 0x68, 0x69, 0x3b, 0x75, 0x2d, 0x41, 0x70, 0x72, 0x65, 0x6c, 0x69, 0x3b, 0x4d, 0x65, 0x79, 0x69, 0x3b, 0x4a,
-0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x79, 0x69, 0x3b, 0x41, 0x72, 0x68, 0x6f, 0x73, 0x74, 0x6f, 0x73, 0x69,
-0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x3b, 0x55, 0x73, 0x69,
-0x6e, 0x79, 0x69, 0x6b, 0x68, 0x61, 0x62, 0x61, 0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4a, 0x61, 0x6e,
-0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x74, 0x3b, 0x41, 0x70, 0x6f, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e,
-0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x66,
-0x3b, 0x44, 0x69, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x61, 0x77, 0x61, 0x72, 0x65, 0x3b, 0x46, 0x65, 0x62, 0x65, 0x72, 0x77,
-0x61, 0x72, 0x65, 0x3b, 0x4d, 0x61, 0x74, 0x161, 0x68, 0x65, 0x3b, 0x41, 0x70, 0x6f, 0x72, 0x65, 0x6c, 0x65, 0x3b, 0x4d,
-0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x65, 0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74, 0x6f,
-0x73, 0x65, 0x3b, 0x53, 0x65, 0x74, 0x65, 0x6d, 0x65, 0x72, 0x65, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x6f, 0x72, 0x65,
-0x3b, 0x4e, 0x6f, 0x66, 0x65, 0x6d, 0x65, 0x72, 0x65, 0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x65, 0x72, 0x65, 0x3b, 0x6f,
-0x111, 0x111, 0x6a, 0x3b, 0x67, 0x75, 0x6f, 0x76, 0x3b, 0x6e, 0x6a, 0x75, 0x6b, 0x3b, 0x63, 0x75, 0x6f, 0x3b, 0x6d, 0x69,
-0x65, 0x73, 0x3b, 0x67, 0x65, 0x61, 0x73, 0x3b, 0x73, 0x75, 0x6f, 0x69, 0x3b, 0x62, 0x6f, 0x72, 0x67, 0x3b, 0x10d, 0x61,
-0x6b, 0x10d, 0x3b, 0x67, 0x6f, 0x6c, 0x67, 0x3b, 0x73, 0x6b, 0xe1, 0x62, 0x3b, 0x6a, 0x75, 0x6f, 0x76, 0x3b, 0x6f, 0x111,
-0x111, 0x61, 0x6a, 0x61, 0x67, 0x65, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x67, 0x75, 0x6f, 0x76, 0x76, 0x61, 0x6d, 0xe1,
-0x6e, 0x6e, 0x75, 0x3b, 0x6e, 0x6a, 0x75, 0x6b, 0x10d, 0x61, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x63, 0x75, 0x6f, 0x14b,
-0x6f, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x6d, 0x69, 0x65, 0x73, 0x73, 0x65, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x67,
-0x65, 0x61, 0x73, 0x73, 0x65, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x73, 0x75, 0x6f, 0x69, 0x64, 0x6e, 0x65, 0x6d, 0xe1,
-0x6e, 0x6e, 0x75, 0x3b, 0x62, 0x6f, 0x72, 0x67, 0x65, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x10d, 0x61, 0x6b, 0x10d, 0x61,
-0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x67, 0x6f, 0x6c, 0x67, 0x67, 0x6f, 0x74, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x73,
-0x6b, 0xe1, 0x62, 0x6d, 0x61, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x6a, 0x75, 0x6f, 0x76, 0x6c, 0x61, 0x6d, 0xe1, 0x6e,
-0x6e, 0x75, 0x3b, 0x4f, 0x3b, 0x47, 0x3b, 0x4e, 0x3b, 0x43, 0x3b, 0x4d, 0x3b, 0x47, 0x3b, 0x53, 0x3b, 0x42, 0x3b, 0x10c,
-0x3b, 0x47, 0x3b, 0x53, 0x3b, 0x4a, 0x3b, 0x6f, 0x111, 0x111, 0x61, 0x6a, 0x61, 0x67, 0x65, 0x3b, 0x67, 0x75, 0x6f, 0x76,
-0x76, 0x61, 0x3b, 0x6e, 0x6a, 0x75, 0x6b, 0x10d, 0x61, 0x3b, 0x63, 0x75, 0x6f, 0x14b, 0x6f, 0x3b, 0x6d, 0x69, 0x65, 0x73,
-0x73, 0x65, 0x3b, 0x67, 0x65, 0x61, 0x73, 0x73, 0x65, 0x3b, 0x73, 0x75, 0x6f, 0x69, 0x64, 0x6e, 0x65, 0x3b, 0x62, 0x6f,
-0x72, 0x67, 0x65, 0x3b, 0x10d, 0x61, 0x6b, 0x10d, 0x61, 0x3b, 0x67, 0x6f, 0x6c, 0x67, 0x67, 0x6f, 0x74, 0x3b, 0x73, 0x6b,
-0xe1, 0x62, 0x6d, 0x61, 0x3b, 0x6a, 0x75, 0x6f, 0x76, 0x6c, 0x61, 0x3b, 0x43, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b,
-0x4d, 0x61, 0x63, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x43, 0x75, 0x6c, 0x3b,
-0x41, 0x67, 0x74, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x62, 0x3b, 0x44, 0x69, 0x73, 0x3b,
-0x43, 0x68, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x75, 0x72, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61,
-0x63, 0x68, 0x69, 0x3b, 0x41, 0x70, 0x69, 0x72, 0x69, 0x72, 0x69, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69,
-0x3b, 0x43, 0x68, 0x75, 0x6c, 0x61, 0x69, 0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65,
-0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x69, 0x74, 0x6f, 0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x62, 0x65, 0x6d, 0x62, 0x61, 0x3b,
-0x44, 0x69, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x43, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b,
-0x43, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x49, 0x6d, 0x62, 0x3b, 0x4b, 0x61, 0x77, 0x3b,
-0x4b, 0x61, 0x64, 0x3b, 0x4b, 0x61, 0x6e, 0x3b, 0x4b, 0x61, 0x73, 0x3b, 0x4b, 0x61, 0x72, 0x3b, 0x4d, 0x66, 0x75, 0x3b,
-0x57, 0x75, 0x6e, 0x3b, 0x49, 0x6b, 0x65, 0x3b, 0x49, 0x6b, 0x75, 0x3b, 0x49, 0x6d, 0x77, 0x3b, 0x49, 0x77, 0x69, 0x3b,
-0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x69, 0x6d, 0x62, 0x69, 0x72, 0x69, 0x3b, 0x4d, 0x6f, 0x72,
-0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x77, 0x69, 0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77,
-0x61, 0x20, 0x6b, 0x61, 0x64, 0x61, 0x64, 0x75, 0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x6b,
-0x61, 0x6e, 0x61, 0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x73, 0x61, 0x6e, 0x75,
-0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x72, 0x61, 0x6e, 0x64, 0x61, 0x64, 0x75,
-0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x6d, 0x66, 0x75, 0x6e, 0x67, 0x61, 0x64, 0x65, 0x3b,
-0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x77, 0x75, 0x6e, 0x79, 0x61, 0x6e, 0x79, 0x61, 0x3b, 0x4d,
-0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x65, 0x6e, 0x64, 0x61, 0x3b, 0x4d, 0x6f, 0x72, 0x69,
-0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77,
-0x61, 0x20, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x69, 0x6d, 0x77, 0x65, 0x72, 0x69, 0x3b, 0x4d, 0x6f,
-0x72, 0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x69, 0x77, 0x69,
-0x3b, 0x49, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4d, 0x3b, 0x57, 0x3b, 0x49, 0x3b, 0x49,
-0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x73, 0x69, 0x69, 0x3b, 0x63, 0x6f, 0x6c, 0x3b, 0x6d, 0x62, 0x6f, 0x3b, 0x73, 0x65, 0x65,
-0x3b, 0x64, 0x75, 0x75, 0x3b, 0x6b, 0x6f, 0x72, 0x3b, 0x6d, 0x6f, 0x72, 0x3b, 0x6a, 0x75, 0x6b, 0x3b, 0x73, 0x6c, 0x74,
-0x3b, 0x79, 0x61, 0x72, 0x3b, 0x6a, 0x6f, 0x6c, 0x3b, 0x62, 0x6f, 0x77, 0x3b, 0x73, 0x69, 0x69, 0x6c, 0x6f, 0x3b, 0x63,
-0x6f, 0x6c, 0x74, 0x65, 0x3b, 0x6d, 0x62, 0x6f, 0x6f, 0x79, 0x3b, 0x73, 0x65, 0x65, 0x257, 0x74, 0x6f, 0x3b, 0x64, 0x75,
-0x75, 0x6a, 0x61, 0x6c, 0x3b, 0x6b, 0x6f, 0x72, 0x73, 0x65, 0x3b, 0x6d, 0x6f, 0x72, 0x73, 0x6f, 0x3b, 0x6a, 0x75, 0x6b,
-0x6f, 0x3b, 0x73, 0x69, 0x69, 0x6c, 0x74, 0x6f, 0x3b, 0x79, 0x61, 0x72, 0x6b, 0x6f, 0x6d, 0x61, 0x61, 0x3b, 0x6a, 0x6f,
-0x6c, 0x61, 0x6c, 0x3b, 0x62, 0x6f, 0x77, 0x74, 0x65, 0x3b, 0x73, 0x3b, 0x63, 0x3b, 0x6d, 0x3b, 0x73, 0x3b, 0x64, 0x3b,
-0x6b, 0x3b, 0x6d, 0x3b, 0x6a, 0x3b, 0x73, 0x3b, 0x79, 0x3b, 0x6a, 0x3b, 0x62, 0x3b, 0x4a, 0x45, 0x4e, 0x3b, 0x57, 0x4b,
-0x52, 0x3b, 0x57, 0x47, 0x54, 0x3b, 0x57, 0x4b, 0x4e, 0x3b, 0x57, 0x54, 0x4e, 0x3b, 0x57, 0x54, 0x44, 0x3b, 0x57, 0x4d,
-0x4a, 0x3b, 0x57, 0x4e, 0x4e, 0x3b, 0x57, 0x4b, 0x44, 0x3b, 0x57, 0x49, 0x4b, 0x3b, 0x57, 0x4d, 0x57, 0x3b, 0x44, 0x49,
-0x54, 0x3b, 0x4e, 0x6a, 0x65, 0x6e, 0x75, 0x61, 0x72, 0x129, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20,
-0x6b, 0x65, 0x72, 0x129, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x67, 0x61, 0x74, 0x61, 0x74, 0x169,
-0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x6e, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65,
-0x20, 0x77, 0x61, 0x20, 0x67, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20,
-0x67, 0x61, 0x74, 0x61, 0x6e, 0x64, 0x61, 0x74, 0x169, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x6d,
-0x169, 0x67, 0x77, 0x61, 0x6e, 0x6a, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x6e,
-0x61, 0x6e, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x65, 0x6e, 0x64, 0x61, 0x3b, 0x4d,
-0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x169, 0x6d, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20,
-0x77, 0x61, 0x20, 0x69, 0x6b, 0x169, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x169, 0x6d, 0x77, 0x65, 0x3b, 0x4e, 0x64, 0x69,
-0x74, 0x68, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4a, 0x3b, 0x4b, 0x3b, 0x47, 0x3b, 0x4b, 0x3b, 0x47, 0x3b, 0x47, 0x3b, 0x4d,
-0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x44, 0x3b, 0x4f, 0x62, 0x6f, 0x3b, 0x57, 0x61, 0x61, 0x3b, 0x4f,
-0x6b, 0x75, 0x3b, 0x4f, 0x6e, 0x67, 0x3b, 0x49, 0x6d, 0x65, 0x3b, 0x49, 0x6c, 0x65, 0x3b, 0x53, 0x61, 0x70, 0x3b, 0x49,
-0x73, 0x69, 0x3b, 0x53, 0x61, 0x61, 0x3b, 0x54, 0x6f, 0x6d, 0x3b, 0x54, 0x6f, 0x62, 0x3b, 0x54, 0x6f, 0x77, 0x3b, 0x4c,
-0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x6f, 0x62, 0x6f, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x77,
-0x61, 0x61, 0x72, 0x65, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x6f, 0x6b, 0x75, 0x6e, 0x69, 0x3b, 0x4c,
-0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x6f, 0x6e, 0x67, 0x27, 0x77, 0x61, 0x6e, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20,
-0x6c, 0x65, 0x20, 0x69, 0x6d, 0x65, 0x74, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x69, 0x6c, 0x65, 0x3b,
-0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x73, 0x61, 0x70, 0x61, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65,
-0x20, 0x69, 0x73, 0x69, 0x65, 0x74, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x73, 0x61, 0x61, 0x6c, 0x3b,
-0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x74, 0x6f, 0x6d, 0x6f, 0x6e, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c,
-0x65, 0x20, 0x74, 0x6f, 0x6d, 0x6f, 0x6e, 0x20, 0x6f, 0x62, 0x6f, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20,
-0x74, 0x6f, 0x6d, 0x6f, 0x6e, 0x20, 0x77, 0x61, 0x61, 0x72, 0x65, 0x3b, 0x4f, 0x3b, 0x57, 0x3b, 0x4f, 0x3b, 0x4f, 0x3b,
-0x49, 0x3b, 0x49, 0x3b, 0x53, 0x3b, 0x49, 0x3b, 0x53, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x4a, 0x61, 0x6e, 0x3b,
-0x46, 0x65, 0x76, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b,
-0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x75, 0x67, 0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x74, 0x75, 0x3b, 0x4e, 0x6f, 0x76, 0x3b,
-0x44, 0x65, 0x63, 0x3b, 0x4a, 0x61, 0x6e, 0x65, 0x69, 0x72, 0x6f, 0x3b, 0x46, 0x65, 0x76, 0x72, 0x65, 0x69, 0x72, 0x6f,
-0x3b, 0x4d, 0x61, 0x72, 0x63, 0x6f, 0x3b, 0x41, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x6f, 0x3b, 0x4a, 0x75,
-0x6e, 0x68, 0x6f, 0x3b, 0x4a, 0x75, 0x6c, 0x68, 0x6f, 0x3b, 0x41, 0x75, 0x67, 0x75, 0x73, 0x74, 0x6f, 0x3b, 0x53, 0x65,
-0x74, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x4f, 0x74, 0x75, 0x62, 0x72, 0x6f, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62,
-0x72, 0x6f, 0x3b, 0x44, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x5a, 0x69, 0x62, 0x3b, 0x4e, 0x68, 0x6c, 0x6f,
-0x3b, 0x4d, 0x62, 0x69, 0x3b, 0x4d, 0x61, 0x62, 0x3b, 0x4e, 0x6b, 0x77, 0x3b, 0x4e, 0x68, 0x6c, 0x61, 0x3b, 0x4e, 0x74,
-0x75, 0x3b, 0x4e, 0x63, 0x77, 0x3b, 0x4d, 0x70, 0x61, 0x6e, 0x3b, 0x4d, 0x66, 0x75, 0x3b, 0x4c, 0x77, 0x65, 0x3b, 0x4d,
-0x70, 0x61, 0x6c, 0x3b, 0x5a, 0x69, 0x62, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x6c, 0x61, 0x3b, 0x4e, 0x68, 0x6c, 0x6f, 0x6c,
-0x61, 0x6e, 0x6a, 0x61, 0x3b, 0x4d, 0x62, 0x69, 0x6d, 0x62, 0x69, 0x74, 0x68, 0x6f, 0x3b, 0x4d, 0x61, 0x62, 0x61, 0x73,
-0x61, 0x3b, 0x4e, 0x6b, 0x77, 0x65, 0x6e, 0x6b, 0x77, 0x65, 0x7a, 0x69, 0x3b, 0x4e, 0x68, 0x6c, 0x61, 0x6e, 0x67, 0x75,
-0x6c, 0x61, 0x3b, 0x4e, 0x74, 0x75, 0x6c, 0x69, 0x6b, 0x61, 0x7a, 0x69, 0x3b, 0x4e, 0x63, 0x77, 0x61, 0x62, 0x61, 0x6b,
-0x61, 0x7a, 0x69, 0x3b, 0x4d, 0x70, 0x61, 0x6e, 0x64, 0x75, 0x6c, 0x61, 0x3b, 0x4d, 0x66, 0x75, 0x6d, 0x66, 0x75, 0x3b,
-0x4c, 0x77, 0x65, 0x7a, 0x69, 0x3b, 0x4d, 0x70, 0x61, 0x6c, 0x61, 0x6b, 0x61, 0x7a, 0x69, 0x3b, 0x5a, 0x3b, 0x4e, 0x3b,
-0x4d, 0x3b, 0x4d, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b,
-0x4d, 0x31, 0x3b, 0x4d, 0x32, 0x3b, 0x4d, 0x33, 0x3b, 0x4d, 0x34, 0x3b, 0x4d, 0x35, 0x3b, 0x4d, 0x36, 0x3b, 0x4d, 0x37,
-0x3b, 0x4d, 0x38, 0x3b, 0x4d, 0x39, 0x3b, 0x4d, 0x31, 0x30, 0x3b, 0x4d, 0x31, 0x31, 0x3b, 0x4d, 0x31, 0x32, 0x3b, 0x4d,
-0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x77, 0x61, 0x6e, 0x7a, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69,
-0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x69, 0x6c, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b,
-0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x61, 0x6e, 0x61,
-0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x74, 0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69,
-0x20, 0x77, 0x61, 0x20, 0x73, 0x69, 0x74, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x73, 0x61,
-0x62, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6e, 0x61, 0x6e, 0x65, 0x3b, 0x4d, 0x77, 0x65,
-0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x74, 0x69, 0x73, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20,
-0x69, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x75, 0x6d, 0x69,
-0x20, 0x6e, 0x61, 0x20, 0x6d, 0x6f, 0x6a, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x69, 0x6b,
-0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x62, 0x69, 0x6c, 0x69, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b,
-0x3b, 0x54, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x4e, 0x3b, 0x54, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x2d49, 0x2d4f, 0x2d4f,
-0x3b, 0x2d31, 0x2d55, 0x2d30, 0x3b, 0x2d4e, 0x2d30, 0x2d55, 0x3b, 0x2d49, 0x2d31, 0x2d54, 0x3b, 0x2d4e, 0x2d30, 0x2d62, 0x3b, 0x2d62, 0x2d53, 0x2d4f,
-0x3b, 0x2d62, 0x2d53, 0x2d4d, 0x3b, 0x2d56, 0x2d53, 0x2d5b, 0x3b, 0x2d5b, 0x2d53, 0x2d5c, 0x3b, 0x2d3d, 0x2d5c, 0x2d53, 0x3b, 0x2d4f, 0x2d53, 0x2d61,
-0x3b, 0x2d37, 0x2d53, 0x2d4a, 0x3b, 0x2d49, 0x2d4f, 0x2d4f, 0x2d30, 0x2d62, 0x2d54, 0x3b, 0x2d31, 0x2d55, 0x2d30, 0x2d62, 0x2d55, 0x3b, 0x2d4e, 0x2d30,
-0x2d55, 0x2d5a, 0x3b, 0x2d49, 0x2d31, 0x2d54, 0x2d49, 0x2d54, 0x3b, 0x2d4e, 0x2d30, 0x2d62, 0x2d62, 0x2d53, 0x3b, 0x2d62, 0x2d53, 0x2d4f, 0x2d62, 0x2d53,
-0x3b, 0x2d62, 0x2d53, 0x2d4d, 0x2d62, 0x2d53, 0x2d63, 0x3b, 0x2d56, 0x2d53, 0x2d5b, 0x2d5c, 0x3b, 0x2d5b, 0x2d53, 0x2d5c, 0x2d30, 0x2d4f, 0x2d31, 0x2d49,
-0x2d54, 0x3b, 0x2d3d, 0x2d5c, 0x2d53, 0x2d31, 0x2d54, 0x3b, 0x2d4f, 0x2d53, 0x2d61, 0x2d30, 0x2d4f, 0x2d31, 0x2d49, 0x2d54, 0x3b, 0x2d37, 0x2d53, 0x2d4a,
-0x2d30, 0x2d4f, 0x2d31, 0x2d49, 0x2d54, 0x3b, 0x2d49, 0x3b, 0x2d31, 0x3b, 0x2d4e, 0x3b, 0x2d49, 0x3b, 0x2d4e, 0x3b, 0x2d62, 0x3b, 0x2d62, 0x3b,
-0x2d56, 0x3b, 0x2d5b, 0x3b, 0x2d3d, 0x3b, 0x2d4f, 0x3b, 0x2d37, 0x3b, 0x69, 0x6e, 0x6e, 0x3b, 0x62, 0x1e5b, 0x61, 0x3b, 0x6d, 0x61,
-0x1e5b, 0x3b, 0x69, 0x62, 0x72, 0x3b, 0x6d, 0x61, 0x79, 0x3b, 0x79, 0x75, 0x6e, 0x3b, 0x79, 0x75, 0x6c, 0x3b, 0x263, 0x75,
-0x63, 0x3b, 0x63, 0x75, 0x74, 0x3b, 0x6b, 0x74, 0x75, 0x3b, 0x6e, 0x75, 0x77, 0x3b, 0x64, 0x75, 0x6a, 0x3b, 0x69, 0x6e,
-0x6e, 0x61, 0x79, 0x72, 0x3b, 0x62, 0x1e5b, 0x61, 0x79, 0x1e5b, 0x3b, 0x6d, 0x61, 0x1e5b, 0x1e63, 0x3b, 0x69, 0x62, 0x72, 0x69,
-0x72, 0x3b, 0x6d, 0x61, 0x79, 0x79, 0x75, 0x3b, 0x79, 0x75, 0x6e, 0x79, 0x75, 0x3b, 0x79, 0x75, 0x6c, 0x79, 0x75, 0x7a,
-0x3b, 0x263, 0x75, 0x63, 0x74, 0x3b, 0x63, 0x75, 0x74, 0x61, 0x6e, 0x62, 0x69, 0x72, 0x3b, 0x6b, 0x74, 0x75, 0x62, 0x72,
-0x3b, 0x6e, 0x75, 0x77, 0x61, 0x6e, 0x62, 0x69, 0x72, 0x3b, 0x64, 0x75, 0x6a, 0x61, 0x6e, 0x62, 0x69, 0x72, 0x3b, 0x69,
-0x3b, 0x62, 0x3b, 0x6d, 0x3b, 0x69, 0x3b, 0x6d, 0x3b, 0x79, 0x3b, 0x79, 0x3b, 0x263, 0x3b, 0x63, 0x3b, 0x6b, 0x3b, 0x6e,
-0x3b, 0x64, 0x3b, 0x59, 0x65, 0x6e, 0x3b, 0x46, 0x75, 0x72, 0x3b, 0x4d, 0x65, 0x263, 0x3b, 0x59, 0x65, 0x62, 0x3b, 0x4d,
-0x61, 0x79, 0x3b, 0x59, 0x75, 0x6e, 0x3b, 0x59, 0x75, 0x6c, 0x3b, 0x194, 0x75, 0x63, 0x3b, 0x43, 0x74, 0x65, 0x3b, 0x54,
-0x75, 0x62, 0x3b, 0x4e, 0x75, 0x6e, 0x3b, 0x44, 0x75, 0x1e7, 0x3b, 0x59, 0x65, 0x6e, 0x6e, 0x61, 0x79, 0x65, 0x72, 0x3b,
-0x46, 0x75, 0x1e5b, 0x61, 0x72, 0x3b, 0x4d, 0x65, 0x263, 0x72, 0x65, 0x73, 0x3b, 0x59, 0x65, 0x62, 0x72, 0x69, 0x72, 0x3b,
-0x4d, 0x61, 0x79, 0x79, 0x75, 0x3b, 0x59, 0x75, 0x6e, 0x79, 0x75, 0x3b, 0x59, 0x75, 0x6c, 0x79, 0x75, 0x3b, 0x194, 0x75,
-0x63, 0x74, 0x3b, 0x43, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x1e5b, 0x3b, 0x54, 0x75, 0x62, 0x65, 0x1e5b, 0x3b, 0x4e, 0x75, 0x6e,
-0x65, 0x6d, 0x62, 0x65, 0x1e5b, 0x3b, 0x44, 0x75, 0x1e7, 0x65, 0x6d, 0x62, 0x65, 0x1e5b, 0x3b, 0x59, 0x3b, 0x46, 0x3b, 0x4d,
-0x3b, 0x59, 0x3b, 0x4d, 0x3b, 0x59, 0x3b, 0x59, 0x3b, 0x194, 0x3b, 0x43, 0x3b, 0x54, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4b,
-0x42, 0x5a, 0x3b, 0x4b, 0x42, 0x52, 0x3b, 0x4b, 0x53, 0x54, 0x3b, 0x4b, 0x4b, 0x4e, 0x3b, 0x4b, 0x54, 0x4e, 0x3b, 0x4b,
-0x4d, 0x4b, 0x3b, 0x4b, 0x4d, 0x53, 0x3b, 0x4b, 0x4d, 0x4e, 0x3b, 0x4b, 0x4d, 0x57, 0x3b, 0x4b, 0x4b, 0x4d, 0x3b, 0x4b,
-0x4e, 0x4b, 0x3b, 0x4b, 0x4e, 0x42, 0x3b, 0x4f, 0x6b, 0x77, 0x6f, 0x6b, 0x75, 0x62, 0x61, 0x6e, 0x7a, 0x61, 0x3b, 0x4f,
-0x6b, 0x77, 0x61, 0x6b, 0x61, 0x62, 0x69, 0x72, 0x69, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x6b, 0x61, 0x73, 0x68, 0x61, 0x74,
-0x75, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x6b, 0x61, 0x6e, 0x61, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x6b, 0x61, 0x74, 0x61, 0x61,
-0x6e, 0x61, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x6d, 0x75, 0x6b, 0x61, 0x61, 0x67, 0x61, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x6d,
-0x75, 0x73, 0x68, 0x61, 0x6e, 0x6a, 0x75, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x6d, 0x75, 0x6e, 0x61, 0x61, 0x6e, 0x61, 0x3b,
-0x4f, 0x6b, 0x77, 0x61, 0x6d, 0x77, 0x65, 0x6e, 0x64, 0x61, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x69, 0x6b, 0x75, 0x6d, 0x69,
-0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6b, 0x75, 0x6d, 0x77, 0x65, 0x3b,
-0x4f, 0x6b, 0x77, 0x61, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x69, 0x62, 0x69, 0x72, 0x69, 0x3b, 0x48,
-0x75, 0x74, 0x3b, 0x56, 0x69, 0x6c, 0x3b, 0x44, 0x61, 0x74, 0x3b, 0x54, 0x61, 0x69, 0x3b, 0x48, 0x61, 0x6e, 0x3b, 0x53,
-0x69, 0x74, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x4e, 0x61, 0x6e, 0x3b, 0x54, 0x69, 0x73, 0x3b, 0x4b, 0x75, 0x6d, 0x3b, 0x4b,
-0x6d, 0x6a, 0x3b, 0x4b, 0x6d, 0x62, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61,
-0x20, 0x68, 0x75, 0x74, 0x61, 0x6c, 0x61, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77,
-0x61, 0x20, 0x77, 0x75, 0x76, 0x69, 0x6c, 0x69, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67,
-0x77, 0x61, 0x20, 0x77, 0x75, 0x64, 0x61, 0x74, 0x75, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20,
-0x67, 0x77, 0x61, 0x20, 0x77, 0x75, 0x74, 0x61, 0x69, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20,
-0x67, 0x77, 0x61, 0x20, 0x77, 0x75, 0x68, 0x61, 0x6e, 0x75, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69,
-0x20, 0x67, 0x77, 0x61, 0x20, 0x73, 0x69, 0x74, 0x61, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20,
-0x67, 0x77, 0x61, 0x20, 0x73, 0x61, 0x62, 0x61, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67,
-0x77, 0x61, 0x20, 0x6e, 0x61, 0x6e, 0x65, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77,
-0x61, 0x20, 0x74, 0x69, 0x73, 0x61, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61,
-0x20, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61, 0x20,
-0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x6f, 0x6a, 0x61, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64,
-0x7a, 0x69, 0x20, 0x67, 0x77, 0x61, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x62, 0x69, 0x6c, 0x69,
-0x3b, 0x48, 0x3b, 0x56, 0x3b, 0x44, 0x3b, 0x54, 0x3b, 0x48, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x4e, 0x3b, 0x54, 0x3b, 0x4b,
-0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72,
-0x69, 0x3b, 0x4d, 0x61, 0x63, 0x68, 0x69, 0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c, 0x79, 0x69, 0x3b, 0x4d, 0x65, 0x69, 0x3b,
-0x4a, 0x75, 0x6e, 0x79, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x79, 0x61, 0x69, 0x3b, 0x41, 0x67, 0x75, 0x73, 0x74, 0x69, 0x3b,
-0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65,
-0x6d, 0x62, 0x61, 0x3b, 0x44, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x7a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b,
-0x6d, 0x61, 0x72, 0x3b, 0x61, 0x77, 0x69, 0x3b, 0x6d, 0x25b, 0x3b, 0x7a, 0x75, 0x77, 0x3b, 0x7a, 0x75, 0x6c, 0x3b, 0x75,
-0x74, 0x69, 0x3b, 0x73, 0x25b, 0x74, 0x3b, 0x254, 0x6b, 0x75, 0x3b, 0x6e, 0x6f, 0x77, 0x3b, 0x64, 0x65, 0x73, 0x3b, 0x7a,
-0x61, 0x6e, 0x77, 0x75, 0x79, 0x65, 0x3b, 0x66, 0x65, 0x62, 0x75, 0x72, 0x75, 0x79, 0x65, 0x3b, 0x6d, 0x61, 0x72, 0x69,
-0x73, 0x69, 0x3b, 0x61, 0x77, 0x69, 0x72, 0x69, 0x6c, 0x69, 0x3b, 0x6d, 0x25b, 0x3b, 0x7a, 0x75, 0x77, 0x25b, 0x6e, 0x3b,
-0x7a, 0x75, 0x6c, 0x75, 0x79, 0x65, 0x3b, 0x75, 0x74, 0x69, 0x3b, 0x73, 0x25b, 0x74, 0x61, 0x6e, 0x62, 0x75, 0x72, 0x75,
-0x3b, 0x254, 0x6b, 0x75, 0x74, 0x254, 0x62, 0x75, 0x72, 0x75, 0x3b, 0x6e, 0x6f, 0x77, 0x61, 0x6e, 0x62, 0x75, 0x72, 0x75,
-0x3b, 0x64, 0x65, 0x73, 0x61, 0x6e, 0x62, 0x75, 0x72, 0x75, 0x3b, 0x5a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d,
-0x3b, 0x5a, 0x3b, 0x5a, 0x3b, 0x55, 0x3b, 0x53, 0x3b, 0x186, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4d, 0x62, 0x65, 0x3b, 0x4b,
-0x61, 0x69, 0x3b, 0x4b, 0x61, 0x74, 0x3b, 0x4b, 0x61, 0x6e, 0x3b, 0x47, 0x61, 0x74, 0x3b, 0x47, 0x61, 0x6e, 0x3b, 0x4d,
-0x75, 0x67, 0x3b, 0x4b, 0x6e, 0x6e, 0x3b, 0x4b, 0x65, 0x6e, 0x3b, 0x49, 0x6b, 0x75, 0x3b, 0x49, 0x6d, 0x77, 0x3b, 0x49,
-0x67, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6d, 0x62, 0x65, 0x72, 0x65, 0x3b, 0x4d, 0x77,
-0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x129, 0x72, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77,
-0x61, 0x20, 0x6b, 0x61, 0x74, 0x68, 0x61, 0x74, 0x169, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b,
-0x61, 0x6e, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x67, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b,
-0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x67, 0x61, 0x74, 0x61, 0x6e, 0x74, 0x61, 0x74, 0x169, 0x3b, 0x4d,
-0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6d, 0x169, 0x67, 0x77, 0x61, 0x6e, 0x6a, 0x61, 0x3b, 0x4d, 0x77, 0x65,
-0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x6e, 0x61, 0x6e, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77,
-0x61, 0x20, 0x6b, 0x65, 0x6e, 0x64, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x169,
-0x6d, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x169, 0x6d, 0x69, 0x20, 0x6e, 0x61,
-0x20, 0x169, 0x6d, 0x77, 0x65, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x169, 0x6d, 0x69,
-0x20, 0x6e, 0x61, 0x20, 0x4b, 0x61, 0x129, 0x72, 0x129, 0x3b, 0x4d, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x47, 0x3b,
-0x47, 0x3b, 0x4d, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x13a4, 0x13c3, 0x3b, 0x13a7, 0x13a6, 0x3b,
-0x13a0, 0x13c5, 0x3b, 0x13a7, 0x13ec, 0x3b, 0x13a0, 0x13c2, 0x3b, 0x13d5, 0x13ad, 0x3b, 0x13ab, 0x13f0, 0x3b, 0x13a6, 0x13b6, 0x3b, 0x13da, 0x13b5,
-0x3b, 0x13da, 0x13c2, 0x3b, 0x13c5, 0x13d3, 0x3b, 0x13a4, 0x13cd, 0x3b, 0x13a4, 0x13c3, 0x13b8, 0x13d4, 0x13c5, 0x3b, 0x13a7, 0x13a6, 0x13b5, 0x3b,
-0x13a0, 0x13c5, 0x13f1, 0x3b, 0x13a7, 0x13ec, 0x13c2, 0x3b, 0x13a0, 0x13c2, 0x13cd, 0x13ac, 0x13d8, 0x3b, 0x13d5, 0x13ad, 0x13b7, 0x13f1, 0x3b, 0x13ab,
-0x13f0, 0x13c9, 0x13c2, 0x3b, 0x13a6, 0x13b6, 0x13c2, 0x3b, 0x13da, 0x13b5, 0x13cd, 0x13d7, 0x3b, 0x13da, 0x13c2, 0x13c5, 0x13d7, 0x3b, 0x13c5, 0x13d3,
-0x13d5, 0x13c6, 0x3b, 0x13a4, 0x13cd, 0x13a9, 0x13f1, 0x3b, 0x13a4, 0x3b, 0x13a7, 0x3b, 0x13a0, 0x3b, 0x13a7, 0x3b, 0x13a0, 0x3b, 0x13d5, 0x3b,
-0x13ab, 0x3b, 0x13a6, 0x3b, 0x13da, 0x3b, 0x13da, 0x3b, 0x13c5, 0x3b, 0x13a4, 0x3b, 0x7a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x76, 0x3b,
-0x6d, 0x61, 0x72, 0x3b, 0x61, 0x76, 0x72, 0x3b, 0x6d, 0x65, 0x3b, 0x7a, 0x69, 0x6e, 0x3b, 0x7a, 0x69, 0x6c, 0x3b, 0x6f,
-0x75, 0x74, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x65, 0x73, 0x3b, 0x7a,
-0x61, 0x6e, 0x76, 0x69, 0x65, 0x3b, 0x66, 0x65, 0x76, 0x72, 0x69, 0x79, 0x65, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61,
-0x76, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x65, 0x3b, 0x7a, 0x69, 0x6e, 0x3b, 0x7a, 0x69, 0x6c, 0x79, 0x65, 0x3b, 0x6f, 0x75,
-0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x61, 0x6d, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x3b, 0x6e, 0x6f, 0x76, 0x61, 0x6d,
-0x3b, 0x64, 0x65, 0x73, 0x61, 0x6d, 0x3b, 0x7a, 0x3b, 0x66, 0x3b, 0x6d, 0x3b, 0x61, 0x3b, 0x6d, 0x3b, 0x7a, 0x3b, 0x7a,
-0x3b, 0x6f, 0x3b, 0x73, 0x3b, 0x6f, 0x3b, 0x6e, 0x3b, 0x64, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x4e, 0x74, 0x61,
-0x6e, 0x64, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x50, 0x69, 0x6c, 0x69, 0x3b, 0x4d, 0x77,
-0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x54, 0x61, 0x74, 0x75, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61,
-0x20, 0x4e, 0x63, 0x68, 0x65, 0x63, 0x68, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x6e,
-0x79, 0x61, 0x6e, 0x6f, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f,
-0x20, 0x6e, 0x61, 0x20, 0x55, 0x6d, 0x6f, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x6e, 0x79,
-0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x4d, 0x69, 0x76, 0x69, 0x6c, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20,
-0x77, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x4d, 0x69, 0x74, 0x61, 0x74, 0x75, 0x3b,
+0x6f, 0x76, 0x3b, 0x64, 0x69, 0x63, 0x3b, 0x65, 0x6e, 0x65, 0x72, 0x6f, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x65, 0x72, 0x6f,
+0x3b, 0x6d, 0x61, 0x72, 0x7a, 0x6f, 0x3b, 0x61, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x79, 0x6f, 0x3b, 0x6a, 0x75,
+0x6e, 0x69, 0x6f, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x6f, 0x3b, 0x61, 0x67, 0x6f, 0x73, 0x74, 0x6f, 0x3b, 0x73, 0x65, 0x70,
+0x74, 0x69, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x6f, 0x63, 0x74, 0x75, 0x62, 0x72, 0x65, 0x3b, 0x6e, 0x6f, 0x76, 0x69,
+0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x69, 0x63, 0x69, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x45, 0x3b, 0x46, 0x3b,
+0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b,
+0x65, 0x6e, 0x65, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x62, 0x72, 0x3b, 0x6d, 0x61, 0x79, 0x3b,
+0x6a, 0x75, 0x6e, 0x3b, 0x6a, 0x75, 0x6c, 0x3b, 0x61, 0x67, 0x6f, 0x3b, 0x73, 0x65, 0x70, 0x3b, 0x6f, 0x63, 0x74, 0x3b,
+0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x69, 0x63, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x63, 0x3b,
+0x41, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f, 0x3b,
+0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x75,
+0x61, 0x72, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61, 0x63, 0x68, 0x69, 0x3b, 0x41,
+0x70, 0x72, 0x69, 0x6c, 0x69, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x69,
+0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74,
+0x6f, 0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b,
+0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x61, 0x6a, 0x3b,
+0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x75, 0x67, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b,
+0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x63, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x72,
+0x75, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61, 0x72, 0x73, 0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x6a, 0x3b,
+0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x69, 0x3b, 0x41, 0x75, 0x67, 0x75, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65,
+0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0x65,
+0x6d, 0x62, 0x65, 0x72, 0x3b, 0x44, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61, 0x72,
+0x69, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x70, 0x72, 0x69,
+0x6c, 0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x75, 0x67, 0x75,
+0x73, 0x74, 0x69, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x65,
+0x72, 0x3b, 0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x3b,
+0x42f, 0x43d, 0x432, 0x3b, 0x424, 0x435, 0x432, 0x3b, 0x41c, 0x430, 0x440, 0x3b, 0x410, 0x43f, 0x440, 0x3b, 0x41c, 0x430, 0x439, 0x3b,
+0x418, 0x44e, 0x43d, 0x3b, 0x418, 0x44e, 0x43b, 0x3b, 0x410, 0x432, 0x433, 0x3b, 0x421, 0x435, 0x43d, 0x3b, 0x41e, 0x43a, 0x442, 0x3b,
+0x41d, 0x43e, 0x44f, 0x3b, 0x414, 0x435, 0x43a, 0x3b, 0x42f, 0x43d, 0x432, 0x430, 0x440, 0x3b, 0x424, 0x435, 0x432, 0x440, 0x430, 0x43b,
+0x3b, 0x41c, 0x430, 0x440, 0x442, 0x3b, 0x410, 0x43f, 0x440, 0x435, 0x43b, 0x3b, 0x41c, 0x430, 0x439, 0x3b, 0x418, 0x44e, 0x43d, 0x3b,
+0x418, 0x44e, 0x43b, 0x3b, 0x410, 0x432, 0x433, 0x443, 0x441, 0x442, 0x3b, 0x421, 0x435, 0x43d, 0x442, 0x44f, 0x431, 0x440, 0x3b, 0x41e,
+0x43a, 0x442, 0x44f, 0x431, 0x440, 0x3b, 0x41d, 0x43e, 0x44f, 0x431, 0x440, 0x3b, 0x414, 0x435, 0x43a, 0x430, 0x431, 0x440, 0x3b, 0xb9c,
+0xba9, 0x2e, 0x3b, 0xbaa, 0xbbf, 0xbaa, 0xbcd, 0x2e, 0x3b, 0xbae, 0xbbe, 0xbb0, 0xbcd, 0x2e, 0x3b, 0xb8f, 0xbaa, 0xbcd, 0x2e, 0x3b,
+0xbae, 0xbc7, 0x3b, 0xb9c, 0xbc2, 0xba9, 0xbcd, 0x3b, 0xb9c, 0xbc2, 0xbb2, 0xbc8, 0x3b, 0xb86, 0xb95, 0x2e, 0x3b, 0xb9a, 0xbc6, 0xbaa,
+0xbcd, 0x2e, 0x3b, 0xb85, 0xb95, 0xbcd, 0x2e, 0x3b, 0xba8, 0xbb5, 0x2e, 0x3b, 0xb9f, 0xbbf, 0xb9a, 0x2e, 0x3b, 0xb9c, 0xba9, 0xbb5,
+0xbb0, 0xbbf, 0x3b, 0xbaa, 0xbbf, 0xbaa, 0xbcd, 0xbb0, 0xbb5, 0xbb0, 0xbbf, 0x3b, 0xbae, 0xbbe, 0xbb0, 0xbcd, 0xb9a, 0xbcd, 0x3b, 0xb8f,
+0xbaa, 0xbcd, 0xbb0, 0xbb2, 0xbcd, 0x3b, 0xbae, 0xbc7, 0x3b, 0xb9c, 0xbc2, 0xba9, 0xbcd, 0x3b, 0xb9c, 0xbc2, 0xbb2, 0xbc8, 0x3b, 0xb86,
+0xb95, 0xbb8, 0xbcd, 0xb9f, 0xbc1, 0x3b, 0xb9a, 0xbc6, 0xbaa, 0xbcd, 0xb9f, 0xbae, 0xbcd, 0xbaa, 0xbb0, 0xbcd, 0x3b, 0xb85, 0xb95, 0xbcd,
+0xb9f, 0xbcb, 0xbaa, 0xbb0, 0xbcd, 0x3b, 0xba8, 0xbb5, 0xbae, 0xbcd, 0xbaa, 0xbb0, 0xbcd, 0x3b, 0xb9f, 0xbbf, 0xb9a, 0xbae, 0xbcd, 0xbaa,
+0xbb0, 0xbcd, 0x3b, 0xb9c, 0x3b, 0xbaa, 0xbbf, 0x3b, 0xbae, 0xbbe, 0x3b, 0xb8f, 0x3b, 0xbae, 0xbc7, 0x3b, 0xb9c, 0xbc2, 0x3b, 0xb9c,
+0xbc2, 0x3b, 0xb86, 0x3b, 0xb9a, 0xbc6, 0x3b, 0xb85, 0x3b, 0xba8, 0x3b, 0xb9f, 0xbbf, 0x3b, 0xb9c, 0xba9, 0xbb5, 0xbb0, 0xbbf, 0x3b,
+0xbaa, 0xbbf, 0xbaa, 0xbcd, 0xbb0, 0xbb5, 0xbb0, 0xbbf, 0x3b, 0xbae, 0xbbe, 0xbb0, 0xbcd, 0xb9a, 0xbcd, 0x3b, 0xb8f, 0xbaa, 0xbcd, 0xbb0,
+0xbb2, 0xbcd, 0x3b, 0xbae, 0xbc7, 0x3b, 0xb9c, 0xbc2, 0xba9, 0xbcd, 0x3b, 0xb9c, 0xbc2, 0xbb2, 0xbc8, 0x3b, 0xb86, 0xb95, 0xbb8, 0xbcd,
+0xb9f, 0xbcd, 0x3b, 0xb9a, 0xbc6, 0xbaa, 0xbcd, 0xb9f, 0xbae, 0xbcd, 0xbaa, 0xbb0, 0xbcd, 0x3b, 0xb85, 0xb95, 0xbcd, 0xb9f, 0xbcb, 0xbaa,
+0xbb0, 0xbcd, 0x3b, 0xba8, 0xbb5, 0xbae, 0xbcd, 0xbaa, 0xbb0, 0xbcd, 0x3b, 0xb9f, 0xbbf, 0xb9a, 0xbae, 0xbcd, 0xbaa, 0xbb0, 0xbcd, 0x3b,
+0xc1c, 0xc28, 0x3b, 0xc2b, 0xc3f, 0xc2c, 0xc4d, 0xc30, 0x3b, 0xc2e, 0xc3e, 0xc30, 0xc4d, 0xc1a, 0xc3f, 0x3b, 0xc0f, 0xc2a, 0xc4d, 0xc30,
+0xc3f, 0x3b, 0xc2e, 0xc47, 0x3b, 0xc1c, 0xc42, 0xc28, 0xc4d, 0x3b, 0xc1c, 0xc42, 0xc32, 0xc48, 0x3b, 0xc06, 0xc17, 0xc38, 0xc4d, 0xc1f,
+0xc41, 0x3b, 0xc38, 0xc46, 0xc2a, 0xc4d, 0xc1f, 0xc46, 0xc02, 0x3b, 0xc05, 0xc15, 0xc4d, 0xc1f, 0xc4b, 0x3b, 0xc28, 0xc35, 0xc02, 0x3b,
+0xc21, 0xc3f, 0xc38, 0xc46, 0xc02, 0x3b, 0xc1c, 0xc28, 0xc35, 0xc30, 0xc3f, 0x3b, 0xc2b, 0xc3f, 0xc2c, 0xc4d, 0xc30, 0xc35, 0xc30, 0xc3f,
+0x3b, 0xc2e, 0xc3e, 0xc30, 0xc4d, 0xc1a, 0xc3f, 0x3b, 0xc0e, 0xc2a, 0xc4d, 0xc30, 0xc3f, 0xc32, 0xc4d, 0x3b, 0xc2e, 0xc47, 0x3b, 0xc1c,
+0xc42, 0xc28, 0xc4d, 0x3b, 0xc1c, 0xc42, 0xc32, 0xc48, 0x3b, 0xc06, 0xc17, 0xc38, 0xc4d, 0xc1f, 0xc41, 0x3b, 0xc38, 0xc46, 0xc2a, 0xc4d,
+0xc1f, 0xc46, 0xc02, 0xc2c, 0xc30, 0xc4d, 0x3b, 0xc05, 0xc15, 0xc4d, 0xc1f, 0xc4b, 0xc2c, 0xc30, 0xc4d, 0x3b, 0xc28, 0xc35, 0xc02, 0xc2c,
+0xc30, 0xc4d, 0x3b, 0xc21, 0xc3f, 0xc38, 0xc46, 0xc02, 0xc2c, 0xc30, 0xc4d, 0x3b, 0xc1c, 0x3b, 0xc2b, 0xc3f, 0x3b, 0xc2e, 0xc3e, 0x3b,
+0xc0f, 0x3b, 0xc2e, 0xc47, 0x3b, 0xc1c, 0xc41, 0x3b, 0xc1c, 0xc41, 0x3b, 0xc06, 0x3b, 0xc38, 0xc46, 0x3b, 0xc05, 0x3b, 0xc28, 0x3b,
+0xc21, 0xc3f, 0x3b, 0xc1c, 0xc28, 0x3b, 0xc2b, 0xc3f, 0xc2c, 0xc4d, 0xc30, 0x3b, 0xc2e, 0xc3e, 0xc30, 0xc4d, 0xc1a, 0xc3f, 0x3b, 0xc0f,
+0xc2a, 0xc4d, 0xc30, 0xc3f, 0x3b, 0xc2e, 0xc47, 0x3b, 0xc1c, 0xc42, 0xc28, 0xc4d, 0x3b, 0xc1c, 0xc42, 0xc32, 0xc48, 0x3b, 0xc06, 0xc17,
+0xc38, 0xc4d, 0xc1f, 0xc41, 0x3b, 0xc38, 0xc46, 0xc2a, 0xc4d, 0xc1f, 0xc46, 0xc02, 0xc2c, 0xc30, 0xc4d, 0x3b, 0xc05, 0xc15, 0xc4d, 0xc1f,
+0xc4b, 0xc2c, 0xc30, 0xc4d, 0x3b, 0xc28, 0xc35, 0xc02, 0xc2c, 0xc30, 0xc4d, 0x3b, 0xc21, 0xc3f, 0xc38, 0xc46, 0xc02, 0xc2c, 0xc30, 0xc4d,
+0x3b, 0xc1c, 0x3b, 0xc2b, 0xc3f, 0x3b, 0xc2e, 0xc3e, 0x3b, 0xc0f, 0x3b, 0xc2e, 0xc47, 0x3b, 0xc1c, 0xc42, 0x3b, 0xc1c, 0xc41, 0x3b,
+0xc06, 0x3b, 0xc38, 0xc46, 0x3b, 0xc05, 0x3b, 0xc28, 0x3b, 0xc21, 0xc3f, 0x3b, 0xe21, 0x2e, 0xe04, 0x2e, 0x3b, 0xe01, 0x2e, 0xe1e,
+0x2e, 0x3b, 0xe21, 0xe35, 0x2e, 0xe04, 0x2e, 0x3b, 0xe40, 0xe21, 0x2e, 0xe22, 0x2e, 0x3b, 0xe1e, 0x2e, 0xe04, 0x2e, 0x3b, 0xe21,
+0xe34, 0x2e, 0xe22, 0x2e, 0x3b, 0xe01, 0x2e, 0xe04, 0x2e, 0x3b, 0xe2a, 0x2e, 0xe04, 0x2e, 0x3b, 0xe01, 0x2e, 0xe22, 0x2e, 0x3b,
+0xe15, 0x2e, 0xe04, 0x2e, 0x3b, 0xe1e, 0x2e, 0xe22, 0x2e, 0x3b, 0xe18, 0x2e, 0xe04, 0x2e, 0x3b, 0xe21, 0xe01, 0xe23, 0xe32, 0xe04,
+0xe21, 0x3b, 0xe01, 0xe38, 0xe21, 0xe20, 0xe32, 0xe1e, 0xe31, 0xe19, 0xe18, 0xe4c, 0x3b, 0xe21, 0xe35, 0xe19, 0xe32, 0xe04, 0xe21, 0x3b,
+0xe40, 0xe21, 0xe29, 0xe32, 0xe22, 0xe19, 0x3b, 0xe1e, 0xe24, 0xe29, 0xe20, 0xe32, 0xe04, 0xe21, 0x3b, 0xe21, 0xe34, 0xe16, 0xe38, 0xe19,
+0xe32, 0xe22, 0xe19, 0x3b, 0xe01, 0xe23, 0xe01, 0xe0e, 0xe32, 0xe04, 0xe21, 0x3b, 0xe2a, 0xe34, 0xe07, 0xe2b, 0xe32, 0xe04, 0xe21, 0x3b,
+0xe01, 0xe31, 0xe19, 0xe22, 0xe32, 0xe22, 0xe19, 0x3b, 0xe15, 0xe38, 0xe25, 0xe32, 0xe04, 0xe21, 0x3b, 0xe1e, 0xe24, 0xe28, 0xe08, 0xe34,
+0xe01, 0xe32, 0xe22, 0xe19, 0x3b, 0xe18, 0xe31, 0xe19, 0xe27, 0xe32, 0xe04, 0xe21, 0x3b, 0xe21, 0x2e, 0xe04, 0x2e, 0x3b, 0xe01, 0x2e,
+0xe1e, 0x2e, 0x3b, 0xe21, 0xe35, 0x2e, 0xe04, 0x2e, 0x3b, 0xe40, 0xe21, 0x2e, 0xe22, 0x2e, 0x3b, 0xe1e, 0x2e, 0xe04, 0x2e, 0x3b,
+0xe21, 0xe34, 0x2e, 0xe22, 0x3b, 0xe01, 0x2e, 0xe04, 0x2e, 0x3b, 0xe2a, 0x2e, 0xe04, 0x2e, 0x3b, 0xe01, 0x2e, 0xe22, 0x2e, 0x3b,
+0xe15, 0x2e, 0xe04, 0x2e, 0x3b, 0xe1e, 0x2e, 0xe22, 0x2e, 0x3b, 0xe18, 0x2e, 0xe04, 0x2e, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b,
+0xf51, 0xf44, 0xf0b, 0xf54, 0xf7c, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf42, 0xf49, 0xf72, 0xf66, 0xf0b, 0xf54, 0xf0b, 0x3b,
+0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf66, 0xf74, 0xf58, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf56, 0xf5e, 0xf72,
+0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf63, 0xf94, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b,
+0xf51, 0xfb2, 0xf74, 0xf42, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf56, 0xf51, 0xf74, 0xf53, 0xf0b, 0xf54, 0xf0b,
+0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf56, 0xf62, 0xf92, 0xfb1, 0xf51, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b,
+0xf51, 0xf42, 0xf74, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f,
+0xfb3, 0xf0b, 0xf56, 0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf42, 0xf45, 0xf72, 0xf42, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56,
+0xf0b, 0xf56, 0xf45, 0xf74, 0xf0b, 0xf42, 0xf49, 0xf72, 0xf66, 0xf0b, 0xf54, 0xf0b, 0x3b, 0x1303, 0x1295, 0x12e9, 0x3b, 0x134c, 0x1265, 0x1229,
+0x3b, 0x121b, 0x122d, 0x127d, 0x3b, 0x12a4, 0x1355, 0x1228, 0x3b, 0x121c, 0x12ed, 0x3b, 0x1301, 0x1295, 0x3b, 0x1301, 0x120b, 0x12ed, 0x3b, 0x12a6,
+0x1308, 0x1235, 0x3b, 0x1234, 0x1355, 0x1274, 0x3b, 0x12a6, 0x12ad, 0x1270, 0x3b, 0x1296, 0x126c, 0x121d, 0x3b, 0x12f2, 0x1234, 0x121d, 0x3b, 0x1303,
+0x1295, 0x12e9, 0x12c8, 0x122a, 0x3b, 0x134c, 0x1265, 0x1229, 0x12c8, 0x122a, 0x3b, 0x121b, 0x122d, 0x127d, 0x3b, 0x12a4, 0x1355, 0x1228, 0x120d, 0x3b,
+0x121c, 0x12ed, 0x3b, 0x1301, 0x1295, 0x3b, 0x1301, 0x120b, 0x12ed, 0x3b, 0x12a6, 0x1308, 0x1235, 0x1275, 0x3b, 0x1234, 0x1355, 0x1274, 0x121d, 0x1260,
+0x122d, 0x3b, 0x12a6, 0x12ad, 0x1270, 0x12cd, 0x1260, 0x122d, 0x3b, 0x1296, 0x126c, 0x121d, 0x1260, 0x122d, 0x3b, 0x12f2, 0x1234, 0x121d, 0x1260, 0x122d,
+0x3b, 0x1325, 0x122a, 0x3b, 0x1208, 0x12ab, 0x1272, 0x3b, 0x1218, 0x130b, 0x1262, 0x3b, 0x121a, 0x12eb, 0x12dd, 0x3b, 0x130d, 0x1295, 0x1266, 0x3b,
+0x1230, 0x1290, 0x3b, 0x1213, 0x121d, 0x1208, 0x3b, 0x1290, 0x1213, 0x1230, 0x3b, 0x1218, 0x1235, 0x12a8, 0x3b, 0x1325, 0x1245, 0x121d, 0x3b, 0x1215,
+0x12f3, 0x122d, 0x3b, 0x1273, 0x1215, 0x1233, 0x3b, 0x1325, 0x122a, 0x3b, 0x1208, 0x12ab, 0x1272, 0x1275, 0x3b, 0x1218, 0x130b, 0x1262, 0x1275, 0x3b,
+0x121a, 0x12eb, 0x12dd, 0x12eb, 0x3b, 0x130d, 0x1295, 0x1266, 0x1275, 0x3b, 0x1230, 0x1290, 0x3b, 0x1213, 0x121d, 0x1208, 0x3b, 0x1290, 0x1213, 0x1230,
+0x3b, 0x1218, 0x1235, 0x12a8, 0x1228, 0x121d, 0x3b, 0x1325, 0x1245, 0x121d, 0x1272, 0x3b, 0x1215, 0x12f3, 0x122d, 0x3b, 0x1273, 0x1215, 0x1233, 0x1235,
+0x3b, 0x53, 0x101, 0x6e, 0x3b, 0x46, 0x113, 0x70, 0x3b, 0x4d, 0x61, 0x2bb, 0x61, 0x3b, 0x2bb, 0x45, 0x70, 0x65, 0x3b, 0x4d,
+0x113, 0x3b, 0x53, 0x75, 0x6e, 0x3b, 0x53, 0x69, 0x75, 0x3b, 0x2bb, 0x41, 0x6f, 0x6b, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x2bb,
+0x4f, 0x6b, 0x61, 0x3b, 0x4e, 0x14d, 0x76, 0x3b, 0x54, 0x12b, 0x73, 0x3b, 0x53, 0x101, 0x6e, 0x75, 0x61, 0x6c, 0x69, 0x3b,
+0x46, 0x113, 0x70, 0x75, 0x65, 0x6c, 0x69, 0x3b, 0x4d, 0x61, 0x2bb, 0x61, 0x73, 0x69, 0x3b, 0x2bb, 0x45, 0x70, 0x65, 0x6c,
+0x65, 0x6c, 0x69, 0x3b, 0x4d, 0x113, 0x3b, 0x53, 0x75, 0x6e, 0x65, 0x3b, 0x53, 0x69, 0x75, 0x6c, 0x61, 0x69, 0x3b, 0x2bb,
+0x41, 0x6f, 0x6b, 0x6f, 0x73, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x69, 0x74, 0x65, 0x6d, 0x61, 0x3b, 0x2bb, 0x4f, 0x6b, 0x61,
+0x74, 0x6f, 0x70, 0x61, 0x3b, 0x4e, 0x14d, 0x76, 0x65, 0x6d, 0x61, 0x3b, 0x54, 0x12b, 0x73, 0x65, 0x6d, 0x61, 0x3b, 0x53,
+0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x45, 0x3b, 0x4d, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e,
+0x3b, 0x54, 0x3b, 0x53, 0x75, 0x6e, 0x3b, 0x59, 0x61, 0x6e, 0x3b, 0x4b, 0x75, 0x6c, 0x3b, 0x44, 0x7a, 0x69, 0x3b, 0x4d,
+0x75, 0x64, 0x3b, 0x4b, 0x68, 0x6f, 0x3b, 0x4d, 0x61, 0x77, 0x3b, 0x4d, 0x68, 0x61, 0x3b, 0x4e, 0x64, 0x7a, 0x3b, 0x4e,
+0x68, 0x6c, 0x3b, 0x48, 0x75, 0x6b, 0x3b, 0x4e, 0x27, 0x77, 0x3b, 0x53, 0x75, 0x6e, 0x67, 0x75, 0x74, 0x69, 0x3b, 0x4e,
+0x79, 0x65, 0x6e, 0x79, 0x65, 0x6e, 0x79, 0x61, 0x6e, 0x69, 0x3b, 0x4e, 0x79, 0x65, 0x6e, 0x79, 0x61, 0x6e, 0x6b, 0x75,
+0x6c, 0x75, 0x3b, 0x44, 0x7a, 0x69, 0x76, 0x61, 0x6d, 0x69, 0x73, 0x6f, 0x6b, 0x6f, 0x3b, 0x4d, 0x75, 0x64, 0x79, 0x61,
+0x78, 0x69, 0x68, 0x69, 0x3b, 0x4b, 0x68, 0x6f, 0x74, 0x61, 0x76, 0x75, 0x78, 0x69, 0x6b, 0x61, 0x3b, 0x4d, 0x61, 0x77,
+0x75, 0x77, 0x61, 0x6e, 0x69, 0x3b, 0x4d, 0x68, 0x61, 0x77, 0x75, 0x72, 0x69, 0x3b, 0x4e, 0x64, 0x7a, 0x68, 0x61, 0x74,
+0x69, 0x3b, 0x4e, 0x68, 0x6c, 0x61, 0x6e, 0x67, 0x75, 0x6c, 0x61, 0x3b, 0x48, 0x75, 0x6b, 0x75, 0x72, 0x69, 0x3b, 0x4e,
+0x27, 0x77, 0x65, 0x6e, 0x64, 0x7a, 0x61, 0x6d, 0x68, 0x61, 0x6c, 0x61, 0x3b, 0x4f, 0x63, 0x61, 0x3b, 0x15e, 0x75, 0x62,
+0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x4e, 0x69, 0x73, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x48, 0x61, 0x7a, 0x3b, 0x54, 0x65, 0x6d,
+0x3b, 0x41, 0x11f, 0x75, 0x3b, 0x45, 0x79, 0x6c, 0x3b, 0x45, 0x6b, 0x69, 0x3b, 0x4b, 0x61, 0x73, 0x3b, 0x41, 0x72, 0x61,
+0x3b, 0x4f, 0x63, 0x61, 0x6b, 0x3b, 0x15e, 0x75, 0x62, 0x61, 0x74, 0x3b, 0x4d, 0x61, 0x72, 0x74, 0x3b, 0x4e, 0x69, 0x73,
+0x61, 0x6e, 0x3b, 0x4d, 0x61, 0x79, 0x131, 0x73, 0x3b, 0x48, 0x61, 0x7a, 0x69, 0x72, 0x61, 0x6e, 0x3b, 0x54, 0x65, 0x6d,
+0x6d, 0x75, 0x7a, 0x3b, 0x41, 0x11f, 0x75, 0x73, 0x74, 0x6f, 0x73, 0x3b, 0x45, 0x79, 0x6c, 0xfc, 0x6c, 0x3b, 0x45, 0x6b,
+0x69, 0x6d, 0x3b, 0x4b, 0x61, 0x73, 0x131, 0x6d, 0x3b, 0x41, 0x72, 0x61, 0x6c, 0x131, 0x6b, 0x3b, 0x4f, 0x3b, 0x15e, 0x3b,
+0x4d, 0x3b, 0x4e, 0x3b, 0x4d, 0x3b, 0x48, 0x3b, 0x54, 0x3b, 0x41, 0x3b, 0x45, 0x3b, 0x45, 0x3b, 0x4b, 0x3b, 0x41, 0x3b,
+0x421, 0x456, 0x447, 0x3b, 0x41b, 0x44e, 0x442, 0x3b, 0x411, 0x435, 0x440, 0x3b, 0x41a, 0x432, 0x456, 0x3b, 0x422, 0x440, 0x430, 0x3b,
+0x427, 0x435, 0x440, 0x3b, 0x41b, 0x438, 0x43f, 0x3b, 0x421, 0x435, 0x440, 0x3b, 0x412, 0x435, 0x440, 0x3b, 0x416, 0x43e, 0x432, 0x3b,
+0x41b, 0x438, 0x441, 0x3b, 0x413, 0x440, 0x443, 0x3b, 0x421, 0x456, 0x447, 0x435, 0x43d, 0x44c, 0x3b, 0x41b, 0x44e, 0x442, 0x438, 0x439,
+0x3b, 0x411, 0x435, 0x440, 0x435, 0x437, 0x435, 0x43d, 0x44c, 0x3b, 0x41a, 0x432, 0x456, 0x442, 0x435, 0x43d, 0x44c, 0x3b, 0x422, 0x440,
+0x430, 0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x427, 0x435, 0x440, 0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x41b, 0x438, 0x43f, 0x435, 0x43d, 0x44c,
+0x3b, 0x421, 0x435, 0x440, 0x43f, 0x435, 0x43d, 0x44c, 0x3b, 0x412, 0x435, 0x440, 0x435, 0x441, 0x435, 0x43d, 0x44c, 0x3b, 0x416, 0x43e,
+0x432, 0x442, 0x435, 0x43d, 0x44c, 0x3b, 0x41b, 0x438, 0x441, 0x442, 0x43e, 0x43f, 0x430, 0x434, 0x3b, 0x413, 0x440, 0x443, 0x434, 0x435,
+0x43d, 0x44c, 0x3b, 0x421, 0x3b, 0x41b, 0x3b, 0x411, 0x3b, 0x41a, 0x3b, 0x422, 0x3b, 0x427, 0x3b, 0x41b, 0x3b, 0x421, 0x3b, 0x412,
+0x3b, 0x416, 0x3b, 0x41b, 0x3b, 0x413, 0x3b, 0x441, 0x456, 0x447, 0x2e, 0x3b, 0x43b, 0x44e, 0x442, 0x2e, 0x3b, 0x431, 0x435, 0x440,
+0x2e, 0x3b, 0x43a, 0x432, 0x456, 0x442, 0x2e, 0x3b, 0x442, 0x440, 0x430, 0x432, 0x2e, 0x3b, 0x447, 0x435, 0x440, 0x432, 0x2e, 0x3b,
+0x43b, 0x438, 0x43f, 0x2e, 0x3b, 0x441, 0x435, 0x440, 0x43f, 0x2e, 0x3b, 0x432, 0x435, 0x440, 0x2e, 0x3b, 0x436, 0x43e, 0x432, 0x442,
+0x2e, 0x3b, 0x43b, 0x438, 0x441, 0x442, 0x2e, 0x3b, 0x433, 0x440, 0x443, 0x434, 0x2e, 0x3b, 0x441, 0x456, 0x447, 0x43d, 0x44f, 0x3b,
+0x43b, 0x44e, 0x442, 0x43e, 0x433, 0x43e, 0x3b, 0x431, 0x435, 0x440, 0x435, 0x437, 0x43d, 0x44f, 0x3b, 0x43a, 0x432, 0x456, 0x442, 0x43d,
+0x44f, 0x3b, 0x442, 0x440, 0x430, 0x432, 0x43d, 0x44f, 0x3b, 0x447, 0x435, 0x440, 0x432, 0x43d, 0x44f, 0x3b, 0x43b, 0x438, 0x43f, 0x43d,
+0x44f, 0x3b, 0x441, 0x435, 0x440, 0x43f, 0x43d, 0x44f, 0x3b, 0x432, 0x435, 0x440, 0x435, 0x441, 0x43d, 0x44f, 0x3b, 0x436, 0x43e, 0x432,
+0x442, 0x43d, 0x44f, 0x3b, 0x43b, 0x438, 0x441, 0x442, 0x43e, 0x43f, 0x430, 0x434, 0x430, 0x3b, 0x433, 0x440, 0x443, 0x434, 0x43d, 0x44f,
+0x3b, 0x62c, 0x646, 0x648, 0x631, 0x6cc, 0x3b, 0x641, 0x631, 0x648, 0x631, 0x6cc, 0x3b, 0x645, 0x627, 0x631, 0x686, 0x3b, 0x627, 0x67e,
+0x631, 0x6cc, 0x644, 0x3b, 0x645, 0x626, 0x3b, 0x62c, 0x648, 0x646, 0x3b, 0x62c, 0x648, 0x644, 0x627, 0x626, 0x3b, 0x627, 0x6af, 0x633,
+0x62a, 0x3b, 0x633, 0x62a, 0x645, 0x628, 0x631, 0x3b, 0x627, 0x6a9, 0x62a, 0x648, 0x628, 0x631, 0x3b, 0x646, 0x648, 0x645, 0x628, 0x631,
+0x3b, 0x62f, 0x633, 0x645, 0x628, 0x631, 0x3b, 0x62c, 0x646, 0x648, 0x3b, 0x641, 0x628, 0x631, 0x3b, 0x645, 0x627, 0x631, 0x3b, 0x627,
+0x67e, 0x631, 0x3b, 0x645, 0x640, 0x6cc, 0x3b, 0x62c, 0x648, 0x646, 0x3b, 0x62c, 0x648, 0x644, 0x3b, 0x627, 0x6af, 0x633, 0x3b, 0x633,
+0x67e, 0x62a, 0x3b, 0x627, 0x6a9, 0x62a, 0x3b, 0x646, 0x648, 0x645, 0x3b, 0x62f, 0x633, 0x645, 0x3b, 0x59, 0x61, 0x6e, 0x76, 0x3b,
+0x46, 0x65, 0x76, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x49, 0x79, 0x75, 0x6e,
+0x3b, 0x49, 0x79, 0x75, 0x6c, 0x3b, 0x41, 0x76, 0x67, 0x3b, 0x53, 0x65, 0x6e, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f,
+0x79, 0x61, 0x3b, 0x44, 0x65, 0x6b, 0x3b, 0x59, 0x61, 0x6e, 0x76, 0x61, 0x72, 0x3b, 0x46, 0x65, 0x76, 0x72, 0x61, 0x6c,
+0x3b, 0x4d, 0x61, 0x72, 0x74, 0x3b, 0x41, 0x70, 0x72, 0x65, 0x6c, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x49, 0x79, 0x75, 0x6e,
+0x3b, 0x49, 0x79, 0x75, 0x6c, 0x3b, 0x41, 0x76, 0x67, 0x75, 0x73, 0x74, 0x3b, 0x53, 0x65, 0x6e, 0x74, 0x79, 0x61, 0x62,
+0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x79, 0x61, 0x62, 0x72, 0x3b, 0x4e, 0x6f, 0x79, 0x61, 0x62, 0x72, 0x3b, 0x44, 0x65, 0x6b,
+0x61, 0x62, 0x72, 0x3b, 0x59, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x41, 0x3b,
+0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x31, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x32, 0x3b,
+0x74, 0x68, 0x67, 0x20, 0x33, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x34, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x35, 0x3b, 0x74, 0x68,
+0x67, 0x20, 0x36, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x37, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x38, 0x3b, 0x74, 0x68, 0x67, 0x20,
+0x39, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x31, 0x30, 0x3b, 0x74, 0x68, 0x67, 0x20, 0x31, 0x31, 0x3b, 0x74, 0x68, 0x67, 0x20,
+0x31, 0x32, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x6d, 0x1ed9, 0x74, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x68,
+0x61, 0x69, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x62, 0x61, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x74, 0x1b0,
+0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x6e, 0x103, 0x6d, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x73, 0xe1, 0x75,
+0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x62, 0x1ea3, 0x79, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x74, 0xe1, 0x6d,
+0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x63, 0x68, 0xed, 0x6e, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x6d, 0x1b0,
+0x1edd, 0x69, 0x3b, 0x74, 0x68, 0xe1, 0x6e, 0x67, 0x20, 0x6d, 0x1b0, 0x1edd, 0x69, 0x20, 0x6d, 0x1ed9, 0x74, 0x3b, 0x74, 0x68,
+0xe1, 0x6e, 0x67, 0x20, 0x6d, 0x1b0, 0x1edd, 0x69, 0x20, 0x68, 0x61, 0x69, 0x3b, 0x49, 0x6f, 0x6e, 0x3b, 0x43, 0x68, 0x77,
+0x3b, 0x4d, 0x61, 0x77, 0x3b, 0x45, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4d, 0x65, 0x68, 0x3b, 0x47, 0x6f, 0x72,
+0x3b, 0x41, 0x77, 0x73, 0x74, 0x3b, 0x4d, 0x65, 0x64, 0x69, 0x3b, 0x48, 0x79, 0x64, 0x3b, 0x54, 0x61, 0x63, 0x68, 0x3b,
+0x52, 0x68, 0x61, 0x67, 0x3b, 0x49, 0x6f, 0x6e, 0x61, 0x77, 0x72, 0x3b, 0x43, 0x68, 0x77, 0x65, 0x66, 0x72, 0x6f, 0x72,
+0x3b, 0x4d, 0x61, 0x77, 0x72, 0x74, 0x68, 0x3b, 0x45, 0x62, 0x72, 0x69, 0x6c, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4d,
+0x65, 0x68, 0x65, 0x66, 0x69, 0x6e, 0x3b, 0x47, 0x6f, 0x72, 0x66, 0x66, 0x65, 0x6e, 0x6e, 0x61, 0x66, 0x3b, 0x41, 0x77,
+0x73, 0x74, 0x3b, 0x4d, 0x65, 0x64, 0x69, 0x3b, 0x48, 0x79, 0x64, 0x72, 0x65, 0x66, 0x3b, 0x54, 0x61, 0x63, 0x68, 0x77,
+0x65, 0x64, 0x64, 0x3b, 0x52, 0x68, 0x61, 0x67, 0x66, 0x79, 0x72, 0x3b, 0x49, 0x3b, 0x43, 0x68, 0x3b, 0x4d, 0x3b, 0x45,
+0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x47, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x48, 0x3b, 0x54, 0x3b, 0x52, 0x68, 0x3b, 0x49, 0x6f,
+0x6e, 0x3b, 0x43, 0x68, 0x77, 0x65, 0x66, 0x3b, 0x4d, 0x61, 0x77, 0x72, 0x74, 0x68, 0x3b, 0x45, 0x62, 0x72, 0x69, 0x6c,
+0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4d, 0x65, 0x68, 0x3b, 0x47, 0x6f, 0x72, 0x66, 0x66, 0x3b, 0x41, 0x77, 0x73, 0x74,
+0x3b, 0x4d, 0x65, 0x64, 0x69, 0x3b, 0x48, 0x79, 0x64, 0x3b, 0x54, 0x61, 0x63, 0x68, 0x3b, 0x52, 0x68, 0x61, 0x67, 0x3b,
+0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x74, 0x3b, 0x45, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x79, 0x3b,
+0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x61, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b,
+0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x69, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x79, 0x75, 0x77, 0x61, 0x72, 0x69, 0x3b, 0x46, 0x65,
+0x62, 0x72, 0x75, 0x77, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61, 0x74, 0x73, 0x68, 0x69, 0x3b, 0x45, 0x70, 0x72, 0x65, 0x6c,
+0x69, 0x3b, 0x4d, 0x65, 0x79, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x79, 0x69, 0x3b, 0x41,
+0x67, 0x61, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x68, 0x6f,
+0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x1e62,
+0x1eb9, 0x301, 0x72, 0x1eb9, 0x301, 0x3b, 0xc8, 0x72, 0xe8, 0x6c, 0xe8, 0x3b, 0x1eb8, 0x72, 0x1eb9, 0x300, 0x6e, 0xe0, 0x3b, 0xcc,
+0x67, 0x62, 0xe9, 0x3b, 0x1eb8, 0x300, 0x62, 0x69, 0x62, 0x69, 0x3b, 0xd2, 0x6b, 0xfa, 0x64, 0x75, 0x3b, 0x41, 0x67, 0x1eb9,
+0x6d, 0x1ecd, 0x3b, 0xd2, 0x67, 0xfa, 0x6e, 0x3b, 0x4f, 0x77, 0x65, 0x77, 0x65, 0x3b, 0x1ecc, 0x300, 0x77, 0xe0, 0x72, 0xe0,
+0x3b, 0x42, 0xe9, 0x6c, 0xfa, 0x3b, 0x1ecc, 0x300, 0x70, 0x1eb9, 0x300, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0x1e62, 0x1eb9, 0x301, 0x72,
+0x1eb9, 0x301, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0xc8, 0x72, 0xe8, 0x6c, 0xe8, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0x1eb8, 0x72, 0x1eb9,
+0x300, 0x6e, 0xe0, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0xcc, 0x67, 0x62, 0xe9, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0x1eb8, 0x300, 0x62,
+0x69, 0x62, 0x69, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0xd2, 0x6b, 0xfa, 0x64, 0x75, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0x41, 0x67,
+0x1eb9, 0x6d, 0x1ecd, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0xd2, 0x67, 0xfa, 0x6e, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0x4f, 0x77, 0x65,
+0x77, 0x65, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0x1ecc, 0x300, 0x77, 0xe0, 0x72, 0xe0, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0x42, 0xe9,
+0x6c, 0xfa, 0x3b, 0x4f, 0x1e63, 0xf9, 0x20, 0x1ecc, 0x300, 0x70, 0x1eb9, 0x300, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62,
+0x3b, 0x4d, 0x61, 0x73, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x79, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c,
+0x3b, 0x41, 0x67, 0x61, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x69, 0x73,
+0x3b, 0x75, 0x4a, 0x61, 0x6e, 0x75, 0x77, 0x61, 0x72, 0x69, 0x3b, 0x75, 0x46, 0x65, 0x62, 0x72, 0x75, 0x77, 0x61, 0x72,
+0x69, 0x3b, 0x75, 0x4d, 0x61, 0x73, 0x68, 0x69, 0x3b, 0x75, 0x2d, 0x41, 0x70, 0x72, 0x65, 0x6c, 0x69, 0x3b, 0x75, 0x4d,
+0x65, 0x79, 0x69, 0x3b, 0x75, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x75, 0x4a, 0x75, 0x6c, 0x61, 0x79, 0x69, 0x3b, 0x75, 0x41,
+0x67, 0x61, 0x73, 0x74, 0x69, 0x3b, 0x75, 0x53, 0x65, 0x70, 0x74, 0x68, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x75, 0x2d, 0x4f,
+0x6b, 0x74, 0x68, 0x6f, 0x62, 0x61, 0x3b, 0x75, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x75, 0x44, 0x69, 0x73,
+0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x77, 0x61, 0x72, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x77,
+0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61, 0x73, 0x68, 0x69, 0x3b, 0x41, 0x70, 0x72, 0x65, 0x6c, 0x69, 0x3b, 0x4d, 0x65, 0x79,
+0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x79, 0x69, 0x3b, 0x41, 0x67, 0x61, 0x73, 0x74, 0x69,
+0x3b, 0x53, 0x65, 0x70, 0x74, 0x68, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x68, 0x6f, 0x62, 0x61, 0x3b, 0x4e,
+0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x6a, 0x61, 0x6e, 0x75, 0x61,
+0x72, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x3b, 0x61, 0x70, 0x72, 0x69, 0x6c,
+0x3b, 0x6d, 0x61, 0x6a, 0x3b, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x6a, 0x75, 0x6c, 0x69, 0x3b, 0x61, 0x76, 0x67, 0x75, 0x73,
+0x74, 0x3b, 0x73, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x72, 0x3b,
+0x6e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x64, 0x65, 0x63, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x4a, 0x2d,
+0x67, 0x75, 0x65, 0x72, 0x3b, 0x54, 0x2d, 0x61, 0x72, 0x72, 0x65, 0x65, 0x3b, 0x4d, 0x61, 0x79, 0x72, 0x6e, 0x74, 0x3b,
+0x41, 0x76, 0x72, 0x72, 0x69, 0x6c, 0x3b, 0x42, 0x6f, 0x61, 0x6c, 0x64, 0x79, 0x6e, 0x3b, 0x4d, 0x2d, 0x73, 0x6f, 0x75,
+0x72, 0x65, 0x65, 0x3b, 0x4a, 0x2d, 0x73, 0x6f, 0x75, 0x72, 0x65, 0x65, 0x3b, 0x4c, 0x75, 0x61, 0x6e, 0x69, 0x73, 0x74,
+0x79, 0x6e, 0x3b, 0x4d, 0x2d, 0x66, 0x6f, 0x75, 0x79, 0x69, 0x72, 0x3b, 0x4a, 0x2d, 0x66, 0x6f, 0x75, 0x79, 0x69, 0x72,
+0x3b, 0x4d, 0x2e, 0x48, 0x6f, 0x75, 0x6e, 0x65, 0x79, 0x3b, 0x4d, 0x2e, 0x4e, 0x6f, 0x6c, 0x6c, 0x69, 0x63, 0x6b, 0x3b,
+0x4a, 0x65, 0x72, 0x72, 0x65, 0x79, 0x2d, 0x67, 0x65, 0x75, 0x72, 0x65, 0x65, 0x3b, 0x54, 0x6f, 0x73, 0x68, 0x69, 0x61,
+0x67, 0x68, 0x74, 0x2d, 0x61, 0x72, 0x72, 0x65, 0x65, 0x3b, 0x4d, 0x61, 0x79, 0x72, 0x6e, 0x74, 0x3b, 0x41, 0x76, 0x65,
+0x72, 0x69, 0x6c, 0x3b, 0x42, 0x6f, 0x61, 0x6c, 0x64, 0x79, 0x6e, 0x3b, 0x4d, 0x65, 0x61, 0x6e, 0x2d, 0x73, 0x6f, 0x75,
+0x72, 0x65, 0x65, 0x3b, 0x4a, 0x65, 0x72, 0x72, 0x65, 0x79, 0x2d, 0x73, 0x6f, 0x75, 0x72, 0x65, 0x65, 0x3b, 0x4c, 0x75,
+0x61, 0x6e, 0x69, 0x73, 0x74, 0x79, 0x6e, 0x3b, 0x4d, 0x65, 0x61, 0x6e, 0x2d, 0x66, 0x6f, 0x75, 0x79, 0x69, 0x72, 0x3b,
+0x4a, 0x65, 0x72, 0x72, 0x65, 0x79, 0x2d, 0x66, 0x6f, 0x75, 0x79, 0x69, 0x72, 0x3b, 0x4d, 0x65, 0x65, 0x20, 0x48, 0x6f,
+0x75, 0x6e, 0x65, 0x79, 0x3b, 0x4d, 0x65, 0x65, 0x20, 0x6e, 0x79, 0x20, 0x4e, 0x6f, 0x6c, 0x6c, 0x69, 0x63, 0x6b, 0x3b,
+0x47, 0x65, 0x6e, 0x3b, 0x57, 0x68, 0x65, 0x3b, 0x4d, 0x65, 0x72, 0x3b, 0x45, 0x62, 0x72, 0x3b, 0x4d, 0x65, 0x3b, 0x45,
+0x66, 0x6e, 0x3b, 0x47, 0x6f, 0x72, 0x3b, 0x45, 0x73, 0x74, 0x3b, 0x47, 0x77, 0x6e, 0x3b, 0x48, 0x65, 0x64, 0x3b, 0x44,
+0x75, 0x3b, 0x4b, 0x65, 0x76, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x47, 0x65, 0x6e, 0x76, 0x65, 0x72, 0x3b, 0x4d, 0x79, 0x73,
+0x20, 0x57, 0x68, 0x65, 0x76, 0x72, 0x65, 0x6c, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x4d, 0x65, 0x72, 0x74, 0x68, 0x3b, 0x4d,
+0x79, 0x73, 0x20, 0x45, 0x62, 0x72, 0x65, 0x6c, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x4d, 0x65, 0x3b, 0x4d, 0x79, 0x73, 0x20,
+0x45, 0x66, 0x61, 0x6e, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x47, 0x6f, 0x72, 0x74, 0x68, 0x65, 0x72, 0x65, 0x6e, 0x3b, 0x4d,
+0x79, 0x65, 0x20, 0x45, 0x73, 0x74, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x47, 0x77, 0x79, 0x6e, 0x67, 0x61, 0x6c, 0x61, 0x3b,
+0x4d, 0x79, 0x73, 0x20, 0x48, 0x65, 0x64, 0x72, 0x61, 0x3b, 0x4d, 0x79, 0x73, 0x20, 0x44, 0x75, 0x3b, 0x4d, 0x79, 0x73,
+0x20, 0x4b, 0x65, 0x76, 0x61, 0x72, 0x64, 0x68, 0x75, 0x3b, 0x53, 0x2d, 0x186, 0x3b, 0x4b, 0x2d, 0x186, 0x3b, 0x45, 0x2d,
+0x186, 0x3b, 0x45, 0x2d, 0x4f, 0x3b, 0x45, 0x2d, 0x4b, 0x3b, 0x4f, 0x2d, 0x41, 0x3b, 0x41, 0x2d, 0x4b, 0x3b, 0x44, 0x2d,
+0x186, 0x3b, 0x46, 0x2d, 0x190, 0x3b, 0x186, 0x2d, 0x41, 0x3b, 0x186, 0x2d, 0x4f, 0x3b, 0x4d, 0x2d, 0x186, 0x3b, 0x53, 0x61,
+0x6e, 0x64, 0x61, 0x2d, 0x186, 0x70, 0x25b, 0x70, 0x254, 0x6e, 0x3b, 0x4b, 0x77, 0x61, 0x6b, 0x77, 0x61, 0x72, 0x2d, 0x186,
+0x67, 0x79, 0x65, 0x66, 0x75, 0x6f, 0x3b, 0x45, 0x62, 0x254, 0x77, 0x2d, 0x186, 0x62, 0x65, 0x6e, 0x65, 0x6d, 0x3b, 0x45,
+0x62, 0x254, 0x62, 0x69, 0x72, 0x61, 0x2d, 0x4f, 0x66, 0x6f, 0x72, 0x69, 0x73, 0x75, 0x6f, 0x3b, 0x45, 0x73, 0x75, 0x73,
+0x6f, 0x77, 0x20, 0x41, 0x6b, 0x65, 0x74, 0x73, 0x65, 0x61, 0x62, 0x61, 0x2d, 0x4b, 0x254, 0x74, 0x254, 0x6e, 0x69, 0x6d,
+0x62, 0x61, 0x3b, 0x4f, 0x62, 0x69, 0x72, 0x61, 0x64, 0x65, 0x2d, 0x41, 0x79, 0x25b, 0x77, 0x6f, 0x68, 0x6f, 0x6d, 0x75,
+0x6d, 0x75, 0x3b, 0x41, 0x79, 0x25b, 0x77, 0x6f, 0x68, 0x6f, 0x2d, 0x4b, 0x69, 0x74, 0x61, 0x77, 0x6f, 0x6e, 0x73, 0x61,
+0x3b, 0x44, 0x69, 0x66, 0x75, 0x75, 0x2d, 0x186, 0x73, 0x61, 0x6e, 0x64, 0x61, 0x61, 0x3b, 0x46, 0x61, 0x6e, 0x6b, 0x77,
+0x61, 0x2d, 0x190, 0x62, 0x254, 0x3b, 0x186, 0x62, 0x25b, 0x73, 0x25b, 0x2d, 0x41, 0x68, 0x69, 0x6e, 0x69, 0x6d, 0x65, 0x3b,
+0x186, 0x62, 0x65, 0x72, 0x25b, 0x66, 0x25b, 0x77, 0x2d, 0x4f, 0x62, 0x75, 0x62, 0x75, 0x6f, 0x3b, 0x4d, 0x75, 0x6d, 0x75,
+0x2d, 0x186, 0x70, 0x25b, 0x6e, 0x69, 0x6d, 0x62, 0x61, 0x3b, 0x91c, 0x93e, 0x928, 0x947, 0x935, 0x93e, 0x930, 0x940, 0x3b, 0x92b,
+0x947, 0x92c, 0x94d, 0x930, 0x941, 0x935, 0x93e, 0x930, 0x940, 0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x91a, 0x3b, 0x90f, 0x92a, 0x94d, 0x930,
+0x93f, 0x932, 0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x942, 0x928, 0x3b, 0x91c, 0x941, 0x932, 0x948, 0x3b, 0x913, 0x917, 0x938, 0x94d, 0x91f,
+0x3b, 0x938, 0x947, 0x92a, 0x94d, 0x91f, 0x947, 0x902, 0x92c, 0x930, 0x3b, 0x913, 0x915, 0x94d, 0x91f, 0x94b, 0x92c, 0x930, 0x3b, 0x928,
+0x94b, 0x935, 0x94d, 0x939, 0x947, 0x902, 0x92c, 0x930, 0x3b, 0x921, 0x93f, 0x938, 0x947, 0x902, 0x92c, 0x930, 0x3b, 0x4a, 0x65, 0x6e,
+0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x61, 0x3b, 0x45, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x65, 0x3b, 0x4a, 0x75, 0x75,
+0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x1ecc, 0x67, 0x1ecd, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x1ecc, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76,
+0x3b, 0x44, 0x69, 0x73, 0x3b, 0x4a, 0x65, 0x6e, 0x1ee5, 0x77, 0x61, 0x72, 0x1ecb, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x1ee5, 0x77,
+0x61, 0x72, 0x1ecb, 0x3b, 0x4d, 0x61, 0x61, 0x63, 0x68, 0x1ecb, 0x3b, 0x45, 0x70, 0x72, 0x65, 0x6c, 0x3b, 0x4d, 0x65, 0x65,
+0x3b, 0x4a, 0x75, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x1ecb, 0x3b, 0x1ecc, 0x67, 0x1ecd, 0x1ecd, 0x73, 0x74, 0x3b, 0x53,
+0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x1ecc, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d,
+0x62, 0x61, 0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4d, 0x62, 0x65, 0x3b, 0x4b, 0x65, 0x6c, 0x3b, 0x4b,
+0x74, 0x169, 0x3b, 0x4b, 0x61, 0x6e, 0x3b, 0x4b, 0x74, 0x6e, 0x3b, 0x54, 0x68, 0x61, 0x3b, 0x4d, 0x6f, 0x6f, 0x3b, 0x4e,
+0x79, 0x61, 0x3b, 0x4b, 0x6e, 0x64, 0x3b, 0x128, 0x6b, 0x75, 0x3b, 0x128, 0x6b, 0x6d, 0x3b, 0x128, 0x6b, 0x6c, 0x3b, 0x4d,
+0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6d, 0x62, 0x65, 0x65, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20,
+0x6b, 0x65, 0x6c, 0x129, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x74, 0x61, 0x74, 0x169, 0x3b,
+0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x6e, 0x61, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61,
+0x20, 0x6b, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x74, 0x68, 0x61, 0x6e,
+0x74, 0x68, 0x61, 0x74, 0x169, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6d, 0x75, 0x6f, 0x6e, 0x7a, 0x61,
+0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6e, 0x79, 0x61, 0x61, 0x6e, 0x79, 0x61, 0x3b, 0x4d, 0x77, 0x61,
+0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x65, 0x6e, 0x64, 0x61, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x129,
+0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x129, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e,
+0x61, 0x20, 0x129, 0x6d, 0x77, 0x65, 0x3b, 0x4d, 0x77, 0x61, 0x69, 0x20, 0x77, 0x61, 0x20, 0x129, 0x6b, 0x75, 0x6d, 0x69,
+0x20, 0x6e, 0x61, 0x20, 0x69, 0x6c, 0x129, 0x3b, 0x4d, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x54, 0x3b,
+0x4d, 0x3b, 0x4e, 0x3b, 0x4b, 0x3b, 0x128, 0x3b, 0x128, 0x3b, 0x128, 0x3b, 0x120d, 0x12f0, 0x1275, 0x3b, 0x12ab, 0x1265, 0x12bd, 0x3b,
+0x12ad, 0x1265, 0x120b, 0x3b, 0x134b, 0x1305, 0x12ba, 0x3b, 0x12ad, 0x1262, 0x1245, 0x3b, 0x121d, 0x2f, 0x1275, 0x3b, 0x12b0, 0x122d, 0x3b, 0x121b,
+0x122d, 0x12eb, 0x3b, 0x12eb, 0x12b8, 0x1292, 0x3b, 0x1218, 0x1270, 0x1209, 0x3b, 0x121d, 0x2f, 0x121d, 0x3b, 0x1270, 0x1215, 0x1233, 0x3b, 0x120d,
+0x12f0, 0x1275, 0x122a, 0x3b, 0x12ab, 0x1265, 0x12bd, 0x1265, 0x1272, 0x3b, 0x12ad, 0x1265, 0x120b, 0x3b, 0x134b, 0x1305, 0x12ba, 0x122a, 0x3b, 0x12ad,
+0x1262, 0x1245, 0x122a, 0x3b, 0x121d, 0x12aa, 0x12a4, 0x120d, 0x20, 0x1275, 0x131f, 0x1292, 0x122a, 0x3b, 0x12b0, 0x122d, 0x12a9, 0x3b, 0x121b, 0x122d,
+0x12eb, 0x121d, 0x20, 0x1275, 0x122a, 0x3b, 0x12eb, 0x12b8, 0x1292, 0x20, 0x1218, 0x1233, 0x1245, 0x1208, 0x122a, 0x3b, 0x1218, 0x1270, 0x1209, 0x3b,
+0x121d, 0x12aa, 0x12a4, 0x120d, 0x20, 0x1218, 0x123d, 0x12c8, 0x122a, 0x3b, 0x1270, 0x1215, 0x1233, 0x1235, 0x122a, 0x3b, 0x120d, 0x3b, 0x12ab, 0x3b,
+0x12ad, 0x3b, 0x134b, 0x3b, 0x12ad, 0x3b, 0x121d, 0x3b, 0x12b0, 0x3b, 0x121b, 0x3b, 0x12eb, 0x3b, 0x1218, 0x3b, 0x121d, 0x3b, 0x1270, 0x3b,
+0x5a, 0x65, 0x6e, 0x3b, 0x46, 0x65, 0x76, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x76, 0x72, 0x3b, 0x4d, 0x61, 0x69, 0x3b,
+0x4a, 0x75, 0x67, 0x3b, 0x4c, 0x75, 0x69, 0x3b, 0x41, 0x76, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x74, 0x75, 0x3b,
+0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x69, 0x63, 0x3b, 0x5a, 0x65, 0x6e, 0xe2, 0x72, 0x3b, 0x46, 0x65, 0x76, 0x72, 0xe2, 0x72,
+0x3b, 0x4d, 0x61, 0x72, 0xe7, 0x3b, 0x41, 0x76, 0x72, 0xee, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x67, 0x6e,
+0x3b, 0x4c, 0x75, 0x69, 0x3b, 0x41, 0x76, 0x6f, 0x73, 0x74, 0x3b, 0x53, 0x65, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b,
+0x4f, 0x74, 0x75, 0x62, 0x61, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x44, 0x69, 0x63, 0x65,
+0x6d, 0x62, 0x61, 0x72, 0x3b, 0x5a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4c, 0x3b, 0x41,
+0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x50, 0x68, 0x61, 0x3b, 0x4c, 0x75, 0x68, 0x3b, 0x1e70, 0x68, 0x66,
+0x3b, 0x4c, 0x61, 0x6d, 0x3b, 0x53, 0x68, 0x75, 0x3b, 0x4c, 0x77, 0x69, 0x3b, 0x4c, 0x77, 0x61, 0x3b, 0x1e70, 0x68, 0x61,
+0x3b, 0x4b, 0x68, 0x75, 0x3b, 0x54, 0x73, 0x68, 0x3b, 0x1e3c, 0x61, 0x72, 0x3b, 0x4e, 0x79, 0x65, 0x3b, 0x50, 0x68, 0x61,
+0x6e, 0x64, 0x6f, 0x3b, 0x4c, 0x75, 0x68, 0x75, 0x68, 0x69, 0x3b, 0x1e70, 0x68, 0x61, 0x66, 0x61, 0x6d, 0x75, 0x68, 0x77,
+0x65, 0x3b, 0x4c, 0x61, 0x6d, 0x62, 0x61, 0x6d, 0x61, 0x69, 0x3b, 0x53, 0x68, 0x75, 0x6e, 0x64, 0x75, 0x6e, 0x74, 0x68,
+0x75, 0x6c, 0x65, 0x3b, 0x46, 0x75, 0x6c, 0x77, 0x69, 0x3b, 0x46, 0x75, 0x6c, 0x77, 0x61, 0x6e, 0x61, 0x3b, 0x1e70, 0x68,
+0x61, 0x6e, 0x67, 0x75, 0x6c, 0x65, 0x3b, 0x4b, 0x68, 0x75, 0x62, 0x76, 0x75, 0x6d, 0x65, 0x64, 0x7a, 0x69, 0x3b, 0x54,
+0x73, 0x68, 0x69, 0x6d, 0x65, 0x64, 0x7a, 0x69, 0x3b, 0x1e3c, 0x61, 0x72, 0x61, 0x3b, 0x4e, 0x79, 0x65, 0x6e, 0x64, 0x61,
+0x76, 0x68, 0x75, 0x73, 0x69, 0x6b, 0x75, 0x3b, 0x64, 0x7a, 0x76, 0x3b, 0x64, 0x7a, 0x64, 0x3b, 0x74, 0x65, 0x64, 0x3b,
+0x61, 0x66, 0x254, 0x3b, 0x64, 0x61, 0x6d, 0x3b, 0x6d, 0x61, 0x73, 0x3b, 0x73, 0x69, 0x61, 0x3b, 0x64, 0x65, 0x61, 0x3b,
+0x61, 0x6e, 0x79, 0x3b, 0x6b, 0x65, 0x6c, 0x3b, 0x61, 0x64, 0x65, 0x3b, 0x64, 0x7a, 0x6d, 0x3b, 0x64, 0x7a, 0x6f, 0x76,
+0x65, 0x3b, 0x64, 0x7a, 0x6f, 0x64, 0x7a, 0x65, 0x3b, 0x74, 0x65, 0x64, 0x6f, 0x78, 0x65, 0x3b, 0x61, 0x66, 0x254, 0x66,
+0x129, 0x65, 0x3b, 0x64, 0x61, 0x6d, 0x61, 0x3b, 0x6d, 0x61, 0x73, 0x61, 0x3b, 0x73, 0x69, 0x61, 0x6d, 0x6c, 0x254, 0x6d,
+0x3b, 0x64, 0x65, 0x61, 0x73, 0x69, 0x61, 0x6d, 0x69, 0x6d, 0x65, 0x3b, 0x61, 0x6e, 0x79, 0x254, 0x6e, 0x79, 0x254, 0x3b,
+0x6b, 0x65, 0x6c, 0x65, 0x3b, 0x61, 0x64, 0x65, 0x25b, 0x6d, 0x65, 0x6b, 0x70, 0x254, 0x78, 0x65, 0x3b, 0x64, 0x7a, 0x6f,
+0x6d, 0x65, 0x3b, 0x64, 0x3b, 0x64, 0x3b, 0x74, 0x3b, 0x61, 0x3b, 0x64, 0x3b, 0x6d, 0x3b, 0x73, 0x3b, 0x64, 0x3b, 0x61,
+0x3b, 0x6b, 0x3b, 0x61, 0x3b, 0x64, 0x3b, 0x49, 0x61, 0x6e, 0x2e, 0x3b, 0x50, 0x65, 0x70, 0x2e, 0x3b, 0x4d, 0x61, 0x6c,
+0x2e, 0x3b, 0x2bb, 0x41, 0x70, 0x2e, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x49, 0x75, 0x6e, 0x2e, 0x3b, 0x49, 0x75, 0x6c, 0x2e,
+0x3b, 0x2bb, 0x41, 0x75, 0x2e, 0x3b, 0x4b, 0x65, 0x70, 0x2e, 0x3b, 0x2bb, 0x4f, 0x6b, 0x2e, 0x3b, 0x4e, 0x6f, 0x77, 0x2e,
+0x3b, 0x4b, 0x65, 0x6b, 0x2e, 0x3b, 0x49, 0x61, 0x6e, 0x75, 0x61, 0x6c, 0x69, 0x3b, 0x50, 0x65, 0x70, 0x65, 0x6c, 0x75,
+0x61, 0x6c, 0x69, 0x3b, 0x4d, 0x61, 0x6c, 0x61, 0x6b, 0x69, 0x3b, 0x2bb, 0x41, 0x70, 0x65, 0x6c, 0x69, 0x6c, 0x61, 0x3b,
+0x4d, 0x65, 0x69, 0x3b, 0x49, 0x75, 0x6e, 0x65, 0x3b, 0x49, 0x75, 0x6c, 0x61, 0x69, 0x3b, 0x2bb, 0x41, 0x75, 0x6b, 0x61,
+0x6b, 0x65, 0x3b, 0x4b, 0x65, 0x70, 0x61, 0x6b, 0x65, 0x6d, 0x61, 0x70, 0x61, 0x3b, 0x2bb, 0x4f, 0x6b, 0x61, 0x6b, 0x6f,
+0x70, 0x61, 0x3b, 0x4e, 0x6f, 0x77, 0x65, 0x6d, 0x61, 0x70, 0x61, 0x3b, 0x4b, 0x65, 0x6b, 0x65, 0x6d, 0x61, 0x70, 0x61,
+0x3b, 0x45, 0x6e, 0x65, 0x3b, 0x50, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x79,
+0x3b, 0x48, 0x75, 0x6e, 0x3b, 0x48, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x6b, 0x74,
+0x3b, 0x4e, 0x6f, 0x62, 0x3b, 0x44, 0x69, 0x73, 0x3b, 0x45, 0x6e, 0x65, 0x72, 0x6f, 0x3b, 0x50, 0x65, 0x62, 0x72, 0x65,
+0x72, 0x6f, 0x3b, 0x4d, 0x61, 0x72, 0x73, 0x6f, 0x3b, 0x41, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x79, 0x6f, 0x3b,
+0x48, 0x75, 0x6e, 0x79, 0x6f, 0x3b, 0x48, 0x75, 0x6c, 0x79, 0x6f, 0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74, 0x6f, 0x3b, 0x53,
+0x65, 0x74, 0x79, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x4f, 0x6b, 0x74, 0x75, 0x62, 0x72, 0x65, 0x3b, 0x4e, 0x6f, 0x62,
+0x79, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x44, 0x69, 0x73, 0x79, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x45, 0x3b, 0x50,
+0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x48, 0x3b, 0x48, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44,
+0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x3b, 0x4d, 0xe4, 0x72, 0x7a,
+0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x69,
+0x3b, 0x41, 0x75, 0x67, 0x75, 0x73, 0x63, 0x68, 0x74, 0x3b, 0x53, 0x65, 0x70, 0x74, 0xe4, 0x6d, 0x62, 0x65, 0x72, 0x3b,
+0x4f, 0x6b, 0x74, 0x6f, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0xe4, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x44, 0x65,
+0x7a, 0xe4, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0xa2cd, 0xa1aa, 0x3b, 0xa44d, 0xa1aa, 0x3b, 0xa315, 0xa1aa, 0x3b, 0xa1d6, 0xa1aa, 0x3b, 0xa26c,
+0xa1aa, 0x3b, 0xa0d8, 0xa1aa, 0x3b, 0xa3c3, 0xa1aa, 0x3b, 0xa246, 0xa1aa, 0x3b, 0xa22c, 0xa1aa, 0x3b, 0xa2b0, 0xa1aa, 0x3b, 0xa2b0, 0xa2aa, 0xa1aa,
+0x3b, 0xa2b0, 0xa44b, 0xa1aa, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x74, 0x3b, 0x41, 0x70, 0x72,
+0x3b, 0x4d, 0x65, 0x79, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x72, 0x68, 0x3b, 0x53, 0x65, 0x70,
+0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x55, 0x73, 0x69, 0x3b, 0x44, 0x69, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x61, 0x62, 0x61, 0x72,
+0x69, 0x3b, 0x75, 0x46, 0x65, 0x62, 0x65, 0x72, 0x62, 0x61, 0x72, 0x69, 0x3b, 0x75, 0x4d, 0x61, 0x74, 0x6a, 0x68, 0x69,
+0x3b, 0x75, 0x2d, 0x41, 0x70, 0x72, 0x65, 0x6c, 0x69, 0x3b, 0x4d, 0x65, 0x79, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b,
+0x4a, 0x75, 0x6c, 0x61, 0x79, 0x69, 0x3b, 0x41, 0x72, 0x68, 0x6f, 0x73, 0x74, 0x6f, 0x73, 0x69, 0x3b, 0x53, 0x65, 0x70,
+0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x3b, 0x55, 0x73, 0x69, 0x6e, 0x79, 0x69, 0x6b,
+0x68, 0x61, 0x62, 0x61, 0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62,
+0x3b, 0x4d, 0x61, 0x74, 0x3b, 0x41, 0x70, 0x6f, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c,
+0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x66, 0x3b, 0x44, 0x69, 0x73,
+0x3b, 0x4a, 0x61, 0x6e, 0x61, 0x77, 0x61, 0x72, 0x65, 0x3b, 0x46, 0x65, 0x62, 0x65, 0x72, 0x77, 0x61, 0x72, 0x65, 0x3b,
+0x4d, 0x61, 0x74, 0x161, 0x68, 0x65, 0x3b, 0x41, 0x70, 0x6f, 0x72, 0x65, 0x6c, 0x65, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a,
+0x75, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x65, 0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74, 0x6f, 0x73, 0x65, 0x3b, 0x53,
+0x65, 0x74, 0x65, 0x6d, 0x65, 0x72, 0x65, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x6f, 0x72, 0x65, 0x3b, 0x4e, 0x6f, 0x66,
+0x65, 0x6d, 0x65, 0x72, 0x65, 0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x65, 0x72, 0x65, 0x3b, 0x6f, 0x111, 0x111, 0x6a, 0x3b,
+0x67, 0x75, 0x6f, 0x76, 0x3b, 0x6e, 0x6a, 0x75, 0x6b, 0x3b, 0x63, 0x75, 0x6f, 0x3b, 0x6d, 0x69, 0x65, 0x73, 0x3b, 0x67,
+0x65, 0x61, 0x73, 0x3b, 0x73, 0x75, 0x6f, 0x69, 0x3b, 0x62, 0x6f, 0x72, 0x67, 0x3b, 0x10d, 0x61, 0x6b, 0x10d, 0x3b, 0x67,
+0x6f, 0x6c, 0x67, 0x3b, 0x73, 0x6b, 0xe1, 0x62, 0x3b, 0x6a, 0x75, 0x6f, 0x76, 0x3b, 0x6f, 0x111, 0x111, 0x61, 0x6a, 0x61,
+0x67, 0x65, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x67, 0x75, 0x6f, 0x76, 0x76, 0x61, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b,
+0x6e, 0x6a, 0x75, 0x6b, 0x10d, 0x61, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x63, 0x75, 0x6f, 0x14b, 0x6f, 0x6d, 0xe1, 0x6e,
+0x6e, 0x75, 0x3b, 0x6d, 0x69, 0x65, 0x73, 0x73, 0x65, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x67, 0x65, 0x61, 0x73, 0x73,
+0x65, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x73, 0x75, 0x6f, 0x69, 0x64, 0x6e, 0x65, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b,
+0x62, 0x6f, 0x72, 0x67, 0x65, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x10d, 0x61, 0x6b, 0x10d, 0x61, 0x6d, 0xe1, 0x6e, 0x6e,
+0x75, 0x3b, 0x67, 0x6f, 0x6c, 0x67, 0x67, 0x6f, 0x74, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x73, 0x6b, 0xe1, 0x62, 0x6d,
+0x61, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x6a, 0x75, 0x6f, 0x76, 0x6c, 0x61, 0x6d, 0xe1, 0x6e, 0x6e, 0x75, 0x3b, 0x4f,
+0x3b, 0x47, 0x3b, 0x4e, 0x3b, 0x43, 0x3b, 0x4d, 0x3b, 0x47, 0x3b, 0x53, 0x3b, 0x42, 0x3b, 0x10c, 0x3b, 0x47, 0x3b, 0x53,
+0x3b, 0x4a, 0x3b, 0x6f, 0x111, 0x111, 0x61, 0x6a, 0x61, 0x67, 0x65, 0x3b, 0x67, 0x75, 0x6f, 0x76, 0x76, 0x61, 0x3b, 0x6e,
+0x6a, 0x75, 0x6b, 0x10d, 0x61, 0x3b, 0x63, 0x75, 0x6f, 0x14b, 0x6f, 0x3b, 0x6d, 0x69, 0x65, 0x73, 0x73, 0x65, 0x3b, 0x67,
+0x65, 0x61, 0x73, 0x73, 0x65, 0x3b, 0x73, 0x75, 0x6f, 0x69, 0x64, 0x6e, 0x65, 0x3b, 0x62, 0x6f, 0x72, 0x67, 0x65, 0x3b,
+0x10d, 0x61, 0x6b, 0x10d, 0x61, 0x3b, 0x67, 0x6f, 0x6c, 0x67, 0x67, 0x6f, 0x74, 0x3b, 0x73, 0x6b, 0xe1, 0x62, 0x6d, 0x61,
+0x3b, 0x6a, 0x75, 0x6f, 0x76, 0x6c, 0x61, 0x3b, 0x43, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x63, 0x3b,
+0x41, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x43, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x74, 0x3b,
+0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x62, 0x3b, 0x44, 0x69, 0x73, 0x3b, 0x43, 0x68, 0x61, 0x6e,
+0x75, 0x61, 0x72, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x75, 0x72, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61, 0x63, 0x68, 0x69, 0x3b,
+0x41, 0x70, 0x69, 0x72, 0x69, 0x72, 0x69, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x43, 0x68, 0x75,
+0x6c, 0x61, 0x69, 0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b,
+0x4f, 0x6b, 0x69, 0x74, 0x6f, 0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x62, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x69, 0x73, 0x65,
+0x6d, 0x62, 0x61, 0x3b, 0x43, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x43, 0x3b, 0x41, 0x3b,
+0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x49, 0x6d, 0x62, 0x3b, 0x4b, 0x61, 0x77, 0x3b, 0x4b, 0x61, 0x64, 0x3b,
+0x4b, 0x61, 0x6e, 0x3b, 0x4b, 0x61, 0x73, 0x3b, 0x4b, 0x61, 0x72, 0x3b, 0x4d, 0x66, 0x75, 0x3b, 0x57, 0x75, 0x6e, 0x3b,
+0x49, 0x6b, 0x65, 0x3b, 0x49, 0x6b, 0x75, 0x3b, 0x49, 0x6d, 0x77, 0x3b, 0x49, 0x77, 0x69, 0x3b, 0x4d, 0x6f, 0x72, 0x69,
+0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x69, 0x6d, 0x62, 0x69, 0x72, 0x69, 0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68,
+0x77, 0x61, 0x20, 0x6b, 0x61, 0x77, 0x69, 0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x6b, 0x61,
+0x64, 0x61, 0x64, 0x75, 0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x6e, 0x61, 0x3b,
+0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x73, 0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x6f, 0x72,
+0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x72, 0x61, 0x6e, 0x64, 0x61, 0x64, 0x75, 0x3b, 0x4d, 0x6f, 0x72,
+0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x6d, 0x66, 0x75, 0x6e, 0x67, 0x61, 0x64, 0x65, 0x3b, 0x4d, 0x6f, 0x72, 0x69,
+0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x77, 0x75, 0x6e, 0x79, 0x61, 0x6e, 0x79, 0x61, 0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20,
+0x67, 0x68, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x65, 0x6e, 0x64, 0x61, 0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77,
+0x61, 0x20, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67, 0x68, 0x77, 0x61, 0x20, 0x69, 0x6b,
+0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x69, 0x6d, 0x77, 0x65, 0x72, 0x69, 0x3b, 0x4d, 0x6f, 0x72, 0x69, 0x20, 0x67,
+0x68, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x69, 0x77, 0x69, 0x3b, 0x49, 0x3b, 0x4b,
+0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4d, 0x3b, 0x57, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x49,
+0x3b, 0x73, 0x69, 0x69, 0x3b, 0x63, 0x6f, 0x6c, 0x3b, 0x6d, 0x62, 0x6f, 0x3b, 0x73, 0x65, 0x65, 0x3b, 0x64, 0x75, 0x75,
+0x3b, 0x6b, 0x6f, 0x72, 0x3b, 0x6d, 0x6f, 0x72, 0x3b, 0x6a, 0x75, 0x6b, 0x3b, 0x73, 0x6c, 0x74, 0x3b, 0x79, 0x61, 0x72,
+0x3b, 0x6a, 0x6f, 0x6c, 0x3b, 0x62, 0x6f, 0x77, 0x3b, 0x73, 0x69, 0x69, 0x6c, 0x6f, 0x3b, 0x63, 0x6f, 0x6c, 0x74, 0x65,
+0x3b, 0x6d, 0x62, 0x6f, 0x6f, 0x79, 0x3b, 0x73, 0x65, 0x65, 0x257, 0x74, 0x6f, 0x3b, 0x64, 0x75, 0x75, 0x6a, 0x61, 0x6c,
+0x3b, 0x6b, 0x6f, 0x72, 0x73, 0x65, 0x3b, 0x6d, 0x6f, 0x72, 0x73, 0x6f, 0x3b, 0x6a, 0x75, 0x6b, 0x6f, 0x3b, 0x73, 0x69,
+0x69, 0x6c, 0x74, 0x6f, 0x3b, 0x79, 0x61, 0x72, 0x6b, 0x6f, 0x6d, 0x61, 0x61, 0x3b, 0x6a, 0x6f, 0x6c, 0x61, 0x6c, 0x3b,
+0x62, 0x6f, 0x77, 0x74, 0x65, 0x3b, 0x73, 0x3b, 0x63, 0x3b, 0x6d, 0x3b, 0x73, 0x3b, 0x64, 0x3b, 0x6b, 0x3b, 0x6d, 0x3b,
+0x6a, 0x3b, 0x73, 0x3b, 0x79, 0x3b, 0x6a, 0x3b, 0x62, 0x3b, 0x4a, 0x45, 0x4e, 0x3b, 0x57, 0x4b, 0x52, 0x3b, 0x57, 0x47,
+0x54, 0x3b, 0x57, 0x4b, 0x4e, 0x3b, 0x57, 0x54, 0x4e, 0x3b, 0x57, 0x54, 0x44, 0x3b, 0x57, 0x4d, 0x4a, 0x3b, 0x57, 0x4e,
+0x4e, 0x3b, 0x57, 0x4b, 0x44, 0x3b, 0x57, 0x49, 0x4b, 0x3b, 0x57, 0x4d, 0x57, 0x3b, 0x44, 0x49, 0x54, 0x3b, 0x4e, 0x6a,
+0x65, 0x6e, 0x75, 0x61, 0x72, 0x129, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x65, 0x72, 0x129,
+0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x67, 0x61, 0x74, 0x61, 0x74, 0x169, 0x3b, 0x4d, 0x77, 0x65,
+0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x6e, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20,
+0x67, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x67, 0x61, 0x74, 0x61,
+0x6e, 0x64, 0x61, 0x74, 0x169, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x6d, 0x169, 0x67, 0x77, 0x61,
+0x6e, 0x6a, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x6e, 0x61, 0x6e, 0x61, 0x3b,
+0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x65, 0x6e, 0x64, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65,
+0x20, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x169, 0x6d, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x65, 0x20, 0x77, 0x61, 0x20, 0x69,
+0x6b, 0x169, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x169, 0x6d, 0x77, 0x65, 0x3b, 0x4e, 0x64, 0x69, 0x74, 0x68, 0x65, 0x6d,
+0x62, 0x61, 0x3b, 0x4a, 0x3b, 0x4b, 0x3b, 0x47, 0x3b, 0x4b, 0x3b, 0x47, 0x3b, 0x47, 0x3b, 0x4d, 0x3b, 0x4b, 0x3b, 0x4b,
+0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x44, 0x3b, 0x4f, 0x62, 0x6f, 0x3b, 0x57, 0x61, 0x61, 0x3b, 0x4f, 0x6b, 0x75, 0x3b, 0x4f,
+0x6e, 0x67, 0x3b, 0x49, 0x6d, 0x65, 0x3b, 0x49, 0x6c, 0x65, 0x3b, 0x53, 0x61, 0x70, 0x3b, 0x49, 0x73, 0x69, 0x3b, 0x53,
+0x61, 0x61, 0x3b, 0x54, 0x6f, 0x6d, 0x3b, 0x54, 0x6f, 0x62, 0x3b, 0x54, 0x6f, 0x77, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20,
+0x6c, 0x65, 0x20, 0x6f, 0x62, 0x6f, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x77, 0x61, 0x61, 0x72, 0x65,
+0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x6f, 0x6b, 0x75, 0x6e, 0x69, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20,
+0x6c, 0x65, 0x20, 0x6f, 0x6e, 0x67, 0x27, 0x77, 0x61, 0x6e, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x69,
+0x6d, 0x65, 0x74, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x69, 0x6c, 0x65, 0x3b, 0x4c, 0x61, 0x70, 0x61,
+0x20, 0x6c, 0x65, 0x20, 0x73, 0x61, 0x70, 0x61, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x69, 0x73, 0x69,
+0x65, 0x74, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x73, 0x61, 0x61, 0x6c, 0x3b, 0x4c, 0x61, 0x70, 0x61,
+0x20, 0x6c, 0x65, 0x20, 0x74, 0x6f, 0x6d, 0x6f, 0x6e, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x74, 0x6f,
+0x6d, 0x6f, 0x6e, 0x20, 0x6f, 0x62, 0x6f, 0x3b, 0x4c, 0x61, 0x70, 0x61, 0x20, 0x6c, 0x65, 0x20, 0x74, 0x6f, 0x6d, 0x6f,
+0x6e, 0x20, 0x77, 0x61, 0x61, 0x72, 0x65, 0x3b, 0x4f, 0x3b, 0x57, 0x3b, 0x4f, 0x3b, 0x4f, 0x3b, 0x49, 0x3b, 0x49, 0x3b,
+0x53, 0x3b, 0x49, 0x3b, 0x53, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x76, 0x3b,
+0x4d, 0x61, 0x72, 0x3b, 0x41, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b,
+0x41, 0x75, 0x67, 0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x74, 0x75, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x63, 0x3b,
+0x4a, 0x61, 0x6e, 0x65, 0x69, 0x72, 0x6f, 0x3b, 0x46, 0x65, 0x76, 0x72, 0x65, 0x69, 0x72, 0x6f, 0x3b, 0x4d, 0x61, 0x72,
+0x63, 0x6f, 0x3b, 0x41, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x6f, 0x3b, 0x4a, 0x75, 0x6e, 0x68, 0x6f, 0x3b,
+0x4a, 0x75, 0x6c, 0x68, 0x6f, 0x3b, 0x41, 0x75, 0x67, 0x75, 0x73, 0x74, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x65, 0x6d, 0x62,
+0x72, 0x6f, 0x3b, 0x4f, 0x74, 0x75, 0x62, 0x72, 0x6f, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x44,
+0x65, 0x63, 0x65, 0x6d, 0x62, 0x72, 0x6f, 0x3b, 0x5a, 0x69, 0x62, 0x3b, 0x4e, 0x68, 0x6c, 0x6f, 0x3b, 0x4d, 0x62, 0x69,
+0x3b, 0x4d, 0x61, 0x62, 0x3b, 0x4e, 0x6b, 0x77, 0x3b, 0x4e, 0x68, 0x6c, 0x61, 0x3b, 0x4e, 0x74, 0x75, 0x3b, 0x4e, 0x63,
+0x77, 0x3b, 0x4d, 0x70, 0x61, 0x6e, 0x3b, 0x4d, 0x66, 0x75, 0x3b, 0x4c, 0x77, 0x65, 0x3b, 0x4d, 0x70, 0x61, 0x6c, 0x3b,
+0x5a, 0x69, 0x62, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x6c, 0x61, 0x3b, 0x4e, 0x68, 0x6c, 0x6f, 0x6c, 0x61, 0x6e, 0x6a, 0x61,
+0x3b, 0x4d, 0x62, 0x69, 0x6d, 0x62, 0x69, 0x74, 0x68, 0x6f, 0x3b, 0x4d, 0x61, 0x62, 0x61, 0x73, 0x61, 0x3b, 0x4e, 0x6b,
+0x77, 0x65, 0x6e, 0x6b, 0x77, 0x65, 0x7a, 0x69, 0x3b, 0x4e, 0x68, 0x6c, 0x61, 0x6e, 0x67, 0x75, 0x6c, 0x61, 0x3b, 0x4e,
+0x74, 0x75, 0x6c, 0x69, 0x6b, 0x61, 0x7a, 0x69, 0x3b, 0x4e, 0x63, 0x77, 0x61, 0x62, 0x61, 0x6b, 0x61, 0x7a, 0x69, 0x3b,
+0x4d, 0x70, 0x61, 0x6e, 0x64, 0x75, 0x6c, 0x61, 0x3b, 0x4d, 0x66, 0x75, 0x6d, 0x66, 0x75, 0x3b, 0x4c, 0x77, 0x65, 0x7a,
+0x69, 0x3b, 0x4d, 0x70, 0x61, 0x6c, 0x61, 0x6b, 0x61, 0x7a, 0x69, 0x3b, 0x5a, 0x3b, 0x4e, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b,
+0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x4d, 0x31, 0x3b, 0x4d,
+0x32, 0x3b, 0x4d, 0x33, 0x3b, 0x4d, 0x34, 0x3b, 0x4d, 0x35, 0x3b, 0x4d, 0x36, 0x3b, 0x4d, 0x37, 0x3b, 0x4d, 0x38, 0x3b,
+0x4d, 0x39, 0x3b, 0x4d, 0x31, 0x30, 0x3b, 0x4d, 0x31, 0x31, 0x3b, 0x4d, 0x31, 0x32, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69,
+0x20, 0x77, 0x61, 0x20, 0x6b, 0x77, 0x61, 0x6e, 0x7a, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20,
+0x6b, 0x61, 0x69, 0x6c, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x74, 0x61, 0x74,
+0x75, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x61, 0x6e, 0x61, 0x3b, 0x4d, 0x77, 0x65,
+0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x74, 0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20,
+0x73, 0x69, 0x74, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x73, 0x61, 0x62, 0x61, 0x3b, 0x4d,
+0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6e, 0x61, 0x6e, 0x65, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77,
+0x61, 0x20, 0x74, 0x69, 0x73, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x75, 0x6d,
+0x69, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20,
+0x6d, 0x6f, 0x6a, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x20,
+0x6e, 0x61, 0x20, 0x6d, 0x62, 0x69, 0x6c, 0x69, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x54, 0x3b, 0x53,
+0x3b, 0x53, 0x3b, 0x4e, 0x3b, 0x54, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x2d49, 0x2d4f, 0x2d4f, 0x3b, 0x2d31, 0x2d55, 0x2d30,
+0x3b, 0x2d4e, 0x2d30, 0x2d55, 0x3b, 0x2d49, 0x2d31, 0x2d54, 0x3b, 0x2d4e, 0x2d30, 0x2d62, 0x3b, 0x2d62, 0x2d53, 0x2d4f, 0x3b, 0x2d62, 0x2d53, 0x2d4d,
+0x3b, 0x2d56, 0x2d53, 0x2d5b, 0x3b, 0x2d5b, 0x2d53, 0x2d5c, 0x3b, 0x2d3d, 0x2d5c, 0x2d53, 0x3b, 0x2d4f, 0x2d53, 0x2d61, 0x3b, 0x2d37, 0x2d53, 0x2d4a,
+0x3b, 0x2d49, 0x2d4f, 0x2d4f, 0x2d30, 0x2d62, 0x2d54, 0x3b, 0x2d31, 0x2d55, 0x2d30, 0x2d62, 0x2d55, 0x3b, 0x2d4e, 0x2d30, 0x2d55, 0x2d5a, 0x3b, 0x2d49,
+0x2d31, 0x2d54, 0x2d49, 0x2d54, 0x3b, 0x2d4e, 0x2d30, 0x2d62, 0x2d62, 0x2d53, 0x3b, 0x2d62, 0x2d53, 0x2d4f, 0x2d62, 0x2d53, 0x3b, 0x2d62, 0x2d53, 0x2d4d,
+0x2d62, 0x2d53, 0x2d63, 0x3b, 0x2d56, 0x2d53, 0x2d5b, 0x2d5c, 0x3b, 0x2d5b, 0x2d53, 0x2d5c, 0x2d30, 0x2d4f, 0x2d31, 0x2d49, 0x2d54, 0x3b, 0x2d3d, 0x2d5c,
+0x2d53, 0x2d31, 0x2d54, 0x3b, 0x2d4f, 0x2d53, 0x2d61, 0x2d30, 0x2d4f, 0x2d31, 0x2d49, 0x2d54, 0x3b, 0x2d37, 0x2d53, 0x2d4a, 0x2d30, 0x2d4f, 0x2d31, 0x2d49,
+0x2d54, 0x3b, 0x2d49, 0x3b, 0x2d31, 0x3b, 0x2d4e, 0x3b, 0x2d49, 0x3b, 0x2d4e, 0x3b, 0x2d62, 0x3b, 0x2d62, 0x3b, 0x2d56, 0x3b, 0x2d5b, 0x3b,
+0x2d3d, 0x3b, 0x2d4f, 0x3b, 0x2d37, 0x3b, 0x69, 0x6e, 0x6e, 0x3b, 0x62, 0x1e5b, 0x61, 0x3b, 0x6d, 0x61, 0x1e5b, 0x3b, 0x69, 0x62,
+0x72, 0x3b, 0x6d, 0x61, 0x79, 0x3b, 0x79, 0x75, 0x6e, 0x3b, 0x79, 0x75, 0x6c, 0x3b, 0x263, 0x75, 0x63, 0x3b, 0x63, 0x75,
+0x74, 0x3b, 0x6b, 0x74, 0x75, 0x3b, 0x6e, 0x75, 0x77, 0x3b, 0x64, 0x75, 0x6a, 0x3b, 0x69, 0x6e, 0x6e, 0x61, 0x79, 0x72,
+0x3b, 0x62, 0x1e5b, 0x61, 0x79, 0x1e5b, 0x3b, 0x6d, 0x61, 0x1e5b, 0x1e63, 0x3b, 0x69, 0x62, 0x72, 0x69, 0x72, 0x3b, 0x6d, 0x61,
+0x79, 0x79, 0x75, 0x3b, 0x79, 0x75, 0x6e, 0x79, 0x75, 0x3b, 0x79, 0x75, 0x6c, 0x79, 0x75, 0x7a, 0x3b, 0x263, 0x75, 0x63,
+0x74, 0x3b, 0x63, 0x75, 0x74, 0x61, 0x6e, 0x62, 0x69, 0x72, 0x3b, 0x6b, 0x74, 0x75, 0x62, 0x72, 0x3b, 0x6e, 0x75, 0x77,
+0x61, 0x6e, 0x62, 0x69, 0x72, 0x3b, 0x64, 0x75, 0x6a, 0x61, 0x6e, 0x62, 0x69, 0x72, 0x3b, 0x69, 0x3b, 0x62, 0x3b, 0x6d,
+0x3b, 0x69, 0x3b, 0x6d, 0x3b, 0x79, 0x3b, 0x79, 0x3b, 0x263, 0x3b, 0x63, 0x3b, 0x6b, 0x3b, 0x6e, 0x3b, 0x64, 0x3b, 0x59,
+0x65, 0x6e, 0x3b, 0x46, 0x75, 0x72, 0x3b, 0x4d, 0x65, 0x263, 0x3b, 0x59, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x59,
+0x75, 0x6e, 0x3b, 0x59, 0x75, 0x6c, 0x3b, 0x194, 0x75, 0x63, 0x3b, 0x43, 0x74, 0x65, 0x3b, 0x54, 0x75, 0x62, 0x3b, 0x4e,
+0x75, 0x6e, 0x3b, 0x44, 0x75, 0x1e7, 0x3b, 0x59, 0x65, 0x6e, 0x6e, 0x61, 0x79, 0x65, 0x72, 0x3b, 0x46, 0x75, 0x1e5b, 0x61,
+0x72, 0x3b, 0x4d, 0x65, 0x263, 0x72, 0x65, 0x73, 0x3b, 0x59, 0x65, 0x62, 0x72, 0x69, 0x72, 0x3b, 0x4d, 0x61, 0x79, 0x79,
+0x75, 0x3b, 0x59, 0x75, 0x6e, 0x79, 0x75, 0x3b, 0x59, 0x75, 0x6c, 0x79, 0x75, 0x3b, 0x194, 0x75, 0x63, 0x74, 0x3b, 0x43,
+0x74, 0x65, 0x6d, 0x62, 0x65, 0x1e5b, 0x3b, 0x54, 0x75, 0x62, 0x65, 0x1e5b, 0x3b, 0x4e, 0x75, 0x6e, 0x65, 0x6d, 0x62, 0x65,
+0x1e5b, 0x3b, 0x44, 0x75, 0x1e7, 0x65, 0x6d, 0x62, 0x65, 0x1e5b, 0x3b, 0x59, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x59, 0x3b, 0x4d,
+0x3b, 0x59, 0x3b, 0x59, 0x3b, 0x194, 0x3b, 0x43, 0x3b, 0x54, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4b, 0x42, 0x5a, 0x3b, 0x4b,
+0x42, 0x52, 0x3b, 0x4b, 0x53, 0x54, 0x3b, 0x4b, 0x4b, 0x4e, 0x3b, 0x4b, 0x54, 0x4e, 0x3b, 0x4b, 0x4d, 0x4b, 0x3b, 0x4b,
+0x4d, 0x53, 0x3b, 0x4b, 0x4d, 0x4e, 0x3b, 0x4b, 0x4d, 0x57, 0x3b, 0x4b, 0x4b, 0x4d, 0x3b, 0x4b, 0x4e, 0x4b, 0x3b, 0x4b,
+0x4e, 0x42, 0x3b, 0x4f, 0x6b, 0x77, 0x6f, 0x6b, 0x75, 0x62, 0x61, 0x6e, 0x7a, 0x61, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x6b,
+0x61, 0x62, 0x69, 0x72, 0x69, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x6b, 0x61, 0x73, 0x68, 0x61, 0x74, 0x75, 0x3b, 0x4f, 0x6b,
+0x77, 0x61, 0x6b, 0x61, 0x6e, 0x61, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x6b, 0x61, 0x74, 0x61, 0x61, 0x6e, 0x61, 0x3b, 0x4f,
+0x6b, 0x77, 0x61, 0x6d, 0x75, 0x6b, 0x61, 0x61, 0x67, 0x61, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x6d, 0x75, 0x73, 0x68, 0x61,
+0x6e, 0x6a, 0x75, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x6d, 0x75, 0x6e, 0x61, 0x61, 0x6e, 0x61, 0x3b, 0x4f, 0x6b, 0x77, 0x61,
+0x6d, 0x77, 0x65, 0x6e, 0x64, 0x61, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x4f, 0x6b, 0x77,
+0x61, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6b, 0x75, 0x6d, 0x77, 0x65, 0x3b, 0x4f, 0x6b, 0x77, 0x61,
+0x69, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x69, 0x62, 0x69, 0x72, 0x69, 0x3b, 0x48, 0x75, 0x74, 0x3b, 0x56,
+0x69, 0x6c, 0x3b, 0x44, 0x61, 0x74, 0x3b, 0x54, 0x61, 0x69, 0x3b, 0x48, 0x61, 0x6e, 0x3b, 0x53, 0x69, 0x74, 0x3b, 0x53,
+0x61, 0x62, 0x3b, 0x4e, 0x61, 0x6e, 0x3b, 0x54, 0x69, 0x73, 0x3b, 0x4b, 0x75, 0x6d, 0x3b, 0x4b, 0x6d, 0x6a, 0x3b, 0x4b,
+0x6d, 0x62, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61, 0x20, 0x68, 0x75, 0x74,
+0x61, 0x6c, 0x61, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61, 0x20, 0x77, 0x75,
+0x76, 0x69, 0x6c, 0x69, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61, 0x20, 0x77,
+0x75, 0x64, 0x61, 0x74, 0x75, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61, 0x20,
+0x77, 0x75, 0x74, 0x61, 0x69, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61, 0x20,
+0x77, 0x75, 0x68, 0x61, 0x6e, 0x75, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61,
+0x20, 0x73, 0x69, 0x74, 0x61, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61, 0x20,
+0x73, 0x61, 0x62, 0x61, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61, 0x20, 0x6e,
+0x61, 0x6e, 0x65, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61, 0x20, 0x74, 0x69,
+0x73, 0x61, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61, 0x20, 0x6b, 0x75, 0x6d,
+0x69, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67, 0x77, 0x61, 0x20, 0x6b, 0x75, 0x6d, 0x69,
+0x20, 0x6e, 0x61, 0x20, 0x6d, 0x6f, 0x6a, 0x61, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x77, 0x65, 0x64, 0x7a, 0x69, 0x20, 0x67,
+0x77, 0x61, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x62, 0x69, 0x6c, 0x69, 0x3b, 0x48, 0x3b, 0x56,
+0x3b, 0x44, 0x3b, 0x54, 0x3b, 0x48, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x4e, 0x3b, 0x54, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b,
+0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x4d, 0x61,
+0x63, 0x68, 0x69, 0x3b, 0x41, 0x70, 0x72, 0x69, 0x6c, 0x79, 0x69, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x79,
+0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x79, 0x61, 0x69, 0x3b, 0x41, 0x67, 0x75, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74,
+0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b,
+0x44, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x7a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b,
+0x61, 0x77, 0x69, 0x3b, 0x6d, 0x25b, 0x3b, 0x7a, 0x75, 0x77, 0x3b, 0x7a, 0x75, 0x6c, 0x3b, 0x75, 0x74, 0x69, 0x3b, 0x73,
+0x25b, 0x74, 0x3b, 0x254, 0x6b, 0x75, 0x3b, 0x6e, 0x6f, 0x77, 0x3b, 0x64, 0x65, 0x73, 0x3b, 0x7a, 0x61, 0x6e, 0x77, 0x75,
+0x79, 0x65, 0x3b, 0x66, 0x65, 0x62, 0x75, 0x72, 0x75, 0x79, 0x65, 0x3b, 0x6d, 0x61, 0x72, 0x69, 0x73, 0x69, 0x3b, 0x61,
+0x77, 0x69, 0x72, 0x69, 0x6c, 0x69, 0x3b, 0x6d, 0x25b, 0x3b, 0x7a, 0x75, 0x77, 0x25b, 0x6e, 0x3b, 0x7a, 0x75, 0x6c, 0x75,
+0x79, 0x65, 0x3b, 0x75, 0x74, 0x69, 0x3b, 0x73, 0x25b, 0x74, 0x61, 0x6e, 0x62, 0x75, 0x72, 0x75, 0x3b, 0x254, 0x6b, 0x75,
+0x74, 0x254, 0x62, 0x75, 0x72, 0x75, 0x3b, 0x6e, 0x6f, 0x77, 0x61, 0x6e, 0x62, 0x75, 0x72, 0x75, 0x3b, 0x64, 0x65, 0x73,
+0x61, 0x6e, 0x62, 0x75, 0x72, 0x75, 0x3b, 0x5a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x5a, 0x3b, 0x5a,
+0x3b, 0x55, 0x3b, 0x53, 0x3b, 0x186, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4d, 0x62, 0x65, 0x3b, 0x4b, 0x61, 0x69, 0x3b, 0x4b,
+0x61, 0x74, 0x3b, 0x4b, 0x61, 0x6e, 0x3b, 0x47, 0x61, 0x74, 0x3b, 0x47, 0x61, 0x6e, 0x3b, 0x4d, 0x75, 0x67, 0x3b, 0x4b,
+0x6e, 0x6e, 0x3b, 0x4b, 0x65, 0x6e, 0x3b, 0x49, 0x6b, 0x75, 0x3b, 0x49, 0x6d, 0x77, 0x3b, 0x49, 0x67, 0x69, 0x3b, 0x4d,
+0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6d, 0x62, 0x65, 0x72, 0x65, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20,
+0x77, 0x61, 0x20, 0x6b, 0x61, 0x129, 0x72, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61,
+0x74, 0x68, 0x61, 0x74, 0x169, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x61, 0x6e, 0x61, 0x3b,
+0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x67, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x4d, 0x77, 0x65, 0x72,
+0x69, 0x20, 0x77, 0x61, 0x20, 0x67, 0x61, 0x74, 0x61, 0x6e, 0x74, 0x61, 0x74, 0x169, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69,
+0x20, 0x77, 0x61, 0x20, 0x6d, 0x169, 0x67, 0x77, 0x61, 0x6e, 0x6a, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77,
+0x61, 0x20, 0x6b, 0x61, 0x6e, 0x61, 0x6e, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x6b, 0x65,
+0x6e, 0x64, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x169, 0x6d, 0x69, 0x3b, 0x4d,
+0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x169, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x169, 0x6d, 0x77,
+0x65, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x61, 0x20, 0x69, 0x6b, 0x169, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20,
+0x4b, 0x61, 0x129, 0x72, 0x129, 0x3b, 0x4d, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x47, 0x3b, 0x47, 0x3b, 0x4d, 0x3b,
+0x4b, 0x3b, 0x4b, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x13a4, 0x13c3, 0x3b, 0x13a7, 0x13a6, 0x3b, 0x13a0, 0x13c5, 0x3b, 0x13a7,
+0x13ec, 0x3b, 0x13a0, 0x13c2, 0x3b, 0x13d5, 0x13ad, 0x3b, 0x13ab, 0x13f0, 0x3b, 0x13a6, 0x13b6, 0x3b, 0x13da, 0x13b5, 0x3b, 0x13da, 0x13c2, 0x3b,
+0x13c5, 0x13d3, 0x3b, 0x13a4, 0x13cd, 0x3b, 0x13a4, 0x13c3, 0x13b8, 0x13d4, 0x13c5, 0x3b, 0x13a7, 0x13a6, 0x13b5, 0x3b, 0x13a0, 0x13c5, 0x13f1, 0x3b,
+0x13a7, 0x13ec, 0x13c2, 0x3b, 0x13a0, 0x13c2, 0x13cd, 0x13ac, 0x13d8, 0x3b, 0x13d5, 0x13ad, 0x13b7, 0x13f1, 0x3b, 0x13ab, 0x13f0, 0x13c9, 0x13c2, 0x3b,
+0x13a6, 0x13b6, 0x13c2, 0x3b, 0x13da, 0x13b5, 0x13cd, 0x13d7, 0x3b, 0x13da, 0x13c2, 0x13c5, 0x13d7, 0x3b, 0x13c5, 0x13d3, 0x13d5, 0x13c6, 0x3b, 0x13a4,
+0x13cd, 0x13a9, 0x13f1, 0x3b, 0x13a4, 0x3b, 0x13a7, 0x3b, 0x13a0, 0x3b, 0x13a7, 0x3b, 0x13a0, 0x3b, 0x13d5, 0x3b, 0x13ab, 0x3b, 0x13a6, 0x3b,
+0x13da, 0x3b, 0x13da, 0x3b, 0x13c5, 0x3b, 0x13a4, 0x3b, 0x7a, 0x61, 0x6e, 0x3b, 0x66, 0x65, 0x76, 0x3b, 0x6d, 0x61, 0x72, 0x3b,
+0x61, 0x76, 0x72, 0x3b, 0x6d, 0x65, 0x3b, 0x7a, 0x69, 0x6e, 0x3b, 0x7a, 0x69, 0x6c, 0x3b, 0x6f, 0x75, 0x74, 0x3b, 0x73,
+0x65, 0x70, 0x3b, 0x6f, 0x6b, 0x74, 0x3b, 0x6e, 0x6f, 0x76, 0x3b, 0x64, 0x65, 0x73, 0x3b, 0x7a, 0x61, 0x6e, 0x76, 0x69,
+0x65, 0x3b, 0x66, 0x65, 0x76, 0x72, 0x69, 0x79, 0x65, 0x3b, 0x6d, 0x61, 0x72, 0x73, 0x3b, 0x61, 0x76, 0x72, 0x69, 0x6c,
+0x3b, 0x6d, 0x65, 0x3b, 0x7a, 0x69, 0x6e, 0x3b, 0x7a, 0x69, 0x6c, 0x79, 0x65, 0x3b, 0x6f, 0x75, 0x74, 0x3b, 0x73, 0x65,
+0x70, 0x74, 0x61, 0x6d, 0x3b, 0x6f, 0x6b, 0x74, 0x6f, 0x62, 0x3b, 0x6e, 0x6f, 0x76, 0x61, 0x6d, 0x3b, 0x64, 0x65, 0x73,
+0x61, 0x6d, 0x3b, 0x7a, 0x3b, 0x66, 0x3b, 0x6d, 0x3b, 0x61, 0x3b, 0x6d, 0x3b, 0x7a, 0x3b, 0x7a, 0x3b, 0x6f, 0x3b, 0x73,
+0x3b, 0x6f, 0x3b, 0x6e, 0x3b, 0x64, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x4e, 0x74, 0x61, 0x6e, 0x64, 0x69, 0x3b,
+0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x50, 0x69, 0x6c, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20,
+0x77, 0x61, 0x20, 0x54, 0x61, 0x74, 0x75, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x63, 0x68,
+0x65, 0x63, 0x68, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f,
+0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20,
+0x55, 0x6d, 0x6f, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20,
+0x6e, 0x61, 0x20, 0x4d, 0x69, 0x76, 0x69, 0x6c, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e,
+0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x4d, 0x69, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x4d, 0x77, 0x65, 0x64,
+0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x4e, 0x63, 0x68, 0x65, 0x63,
+0x68, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e,
+0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x6e,
+0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x55, 0x3b,
0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x4e,
-0x63, 0x68, 0x65, 0x63, 0x68, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61,
-0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77,
-0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e,
-0x61, 0x20, 0x55, 0x3b, 0x4d, 0x77, 0x65, 0x64, 0x69, 0x20, 0x77, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20,
-0x6e, 0x61, 0x20, 0x4e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x4d, 0x3b, 0x46, 0xfa, 0x6e, 0x67, 0x61,
-0x74, 0x268, 0x3b, 0x4e, 0x61, 0x61, 0x6e, 0x268, 0x3b, 0x4b, 0x65, 0x65, 0x6e, 0x64, 0x61, 0x3b, 0x49, 0x6b, 0xfa, 0x6d,
-0x69, 0x3b, 0x49, 0x6e, 0x79, 0x61, 0x6d, 0x62, 0x61, 0x6c, 0x61, 0x3b, 0x49, 0x64, 0x77, 0x61, 0x61, 0x74, 0x61, 0x3b,
-0x4d, 0x289, 0x289, 0x6e, 0x63, 0x68, 0x268, 0x3b, 0x56, 0x268, 0x268, 0x72, 0x268, 0x3b, 0x53, 0x61, 0x61, 0x74, 0x289, 0x3b,
-0x49, 0x6e, 0x79, 0x69, 0x3b, 0x53, 0x61, 0x61, 0x6e, 0x6f, 0x3b, 0x53, 0x61, 0x73, 0x61, 0x74, 0x289, 0x3b, 0x4b, 0x289,
-0x66, 0xfa, 0x6e, 0x67, 0x61, 0x74, 0x268, 0x3b, 0x4b, 0x289, 0x6e, 0x61, 0x61, 0x6e, 0x268, 0x3b, 0x4b, 0x289, 0x6b, 0x65,
-0x65, 0x6e, 0x64, 0x61, 0x3b, 0x4b, 0x77, 0x69, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x4b, 0x77, 0x69, 0x69, 0x6e, 0x79,
-0x61, 0x6d, 0x62, 0xe1, 0x6c, 0x61, 0x3b, 0x4b, 0x77, 0x69, 0x69, 0x64, 0x77, 0x61, 0x61, 0x74, 0x61, 0x3b, 0x4b, 0x289,
-0x6d, 0x289, 0x289, 0x6e, 0x63, 0x68, 0x268, 0x3b, 0x4b, 0x289, 0x76, 0x268, 0x268, 0x72, 0x268, 0x3b, 0x4b, 0x289, 0x73, 0x61,
-0x61, 0x74, 0x289, 0x3b, 0x4b, 0x77, 0x69, 0x69, 0x6e, 0x79, 0x69, 0x3b, 0x4b, 0x289, 0x73, 0x61, 0x61, 0x6e, 0x6f, 0x3b,
-0x4b, 0x289, 0x73, 0x61, 0x73, 0x61, 0x74, 0x289, 0x3b, 0x46, 0x3b, 0x4e, 0x3b, 0x4b, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x49,
-0x3b, 0x4d, 0x3b, 0x56, 0x3b, 0x53, 0x3b, 0x49, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62,
-0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x70, 0x75, 0x3b, 0x4d, 0x61, 0x61, 0x3b, 0x4a, 0x75, 0x75, 0x3b, 0x4a, 0x75, 0x6c,
-0x3b, 0x41, 0x67, 0x75, 0x3b, 0x53, 0x65, 0x62, 0x3b, 0x4f, 0x6b, 0x69, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x73,
-0x3b, 0x4a, 0x61, 0x6e, 0x77, 0x61, 0x6c, 0x69, 0x79, 0x6f, 0x3b, 0x46, 0x65, 0x62, 0x77, 0x61, 0x6c, 0x69, 0x79, 0x6f,
-0x3b, 0x4d, 0x61, 0x72, 0x69, 0x73, 0x69, 0x3b, 0x41, 0x70, 0x75, 0x6c, 0x69, 0x3b, 0x4d, 0x61, 0x61, 0x79, 0x69, 0x3b,
-0x4a, 0x75, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x61, 0x79, 0x69, 0x3b, 0x41, 0x67, 0x75, 0x73, 0x69, 0x74,
-0x6f, 0x3b, 0x53, 0x65, 0x62, 0x75, 0x74, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x69, 0x74, 0x6f, 0x62, 0x62,
-0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4a, 0x61,
-0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x63, 0x3b, 0x45, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75,
-0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x4f, 0x67, 0x61, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f,
-0x76, 0x3b, 0x44, 0x69, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61,
-0x72, 0x69, 0x3b, 0x4d, 0x61, 0x63, 0x68, 0x69, 0x3b, 0x45, 0x70, 0x72, 0x65, 0x6f, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a,
-0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x69, 0x3b, 0x4f, 0x67, 0x61, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70,
-0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61,
-0x3b, 0x44, 0x69, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x45, 0x3b, 0x4d, 0x3b, 0x4a,
-0x3b, 0x4a, 0x3b, 0x4f, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x76,
-0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c,
-0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x74, 0x75, 0x3b, 0x4e, 0x75, 0x76, 0x3b, 0x44, 0x69, 0x7a,
-0x3b, 0x4a, 0x61, 0x6e, 0x65, 0x72, 0x75, 0x3b, 0x46, 0x65, 0x76, 0x65, 0x72, 0x65, 0x72, 0x75, 0x3b, 0x4d, 0x61, 0x72,
-0x73, 0x75, 0x3b, 0x41, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x75, 0x3b, 0x4a, 0x75, 0x6e, 0x68, 0x75, 0x3b,
-0x4a, 0x75, 0x6c, 0x68, 0x75, 0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74, 0x75, 0x3b, 0x53, 0x65, 0x74, 0x65, 0x6e, 0x62, 0x72,
-0x75, 0x3b, 0x4f, 0x74, 0x75, 0x62, 0x72, 0x75, 0x3b, 0x4e, 0x75, 0x76, 0x65, 0x6e, 0x62, 0x72, 0x75, 0x3b, 0x44, 0x69,
-0x7a, 0x65, 0x6e, 0x62, 0x72, 0x75, 0x3b, 0x4a, 0x41, 0x4e, 0x3b, 0x46, 0x45, 0x42, 0x3b, 0x4d, 0x41, 0x43, 0x3b, 0x128,
-0x50, 0x55, 0x3b, 0x4d, 0x128, 0x128, 0x3b, 0x4e, 0x4a, 0x55, 0x3b, 0x4e, 0x4a, 0x52, 0x3b, 0x41, 0x47, 0x41, 0x3b, 0x53,
-0x50, 0x54, 0x3b, 0x4f, 0x4b, 0x54, 0x3b, 0x4e, 0x4f, 0x56, 0x3b, 0x44, 0x45, 0x43, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61,
-0x72, 0x129, 0x3b, 0x46, 0x65, 0x62, 0x75, 0x72, 0x75, 0x61, 0x72, 0x129, 0x3b, 0x4d, 0x61, 0x63, 0x68, 0x69, 0x3b, 0x128,
-0x70, 0x75, 0x72, 0x169, 0x3b, 0x4d, 0x129, 0x129, 0x3b, 0x4e, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x4e, 0x6a, 0x75, 0x72, 0x61,
-0x129, 0x3b, 0x41, 0x67, 0x61, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b,
-0x74, 0x169, 0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x69, 0x63, 0x65, 0x6d, 0x62, 0x61,
-0x3b, 0x4a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x128, 0x3b, 0x4d, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f,
-0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4d, 0x75, 0x6c, 0x3b, 0x4e, 0x67, 0x61, 0x3b, 0x4b, 0x69, 0x70, 0x3b, 0x49, 0x77, 0x61,
-0x3b, 0x4e, 0x67, 0x65, 0x3b, 0x57, 0x61, 0x6b, 0x3b, 0x52, 0x6f, 0x70, 0x3b, 0x4b, 0x6f, 0x67, 0x3b, 0x42, 0x75, 0x72,
-0x3b, 0x45, 0x70, 0x65, 0x3b, 0x54, 0x61, 0x69, 0x3b, 0x41, 0x65, 0x6e, 0x3b, 0x4d, 0x75, 0x6c, 0x67, 0x75, 0x6c, 0x3b,
-0x4e, 0x67, 0x27, 0x61, 0x74, 0x79, 0x61, 0x74, 0x6f, 0x3b, 0x4b, 0x69, 0x70, 0x74, 0x61, 0x6d, 0x6f, 0x3b, 0x49, 0x77,
-0x61, 0x74, 0x20, 0x6b, 0x75, 0x74, 0x3b, 0x4e, 0x67, 0x27, 0x65, 0x69, 0x79, 0x65, 0x74, 0x3b, 0x57, 0x61, 0x6b, 0x69,
-0x3b, 0x52, 0x6f, 0x70, 0x74, 0x75, 0x69, 0x3b, 0x4b, 0x69, 0x70, 0x6b, 0x6f, 0x67, 0x61, 0x67, 0x61, 0x3b, 0x42, 0x75,
-0x72, 0x65, 0x74, 0x3b, 0x45, 0x70, 0x65, 0x73, 0x6f, 0x3b, 0x4b, 0x69, 0x70, 0x73, 0x75, 0x6e, 0x64, 0x65, 0x20, 0x6e,
-0x65, 0x74, 0x61, 0x69, 0x3b, 0x4b, 0x69, 0x70, 0x73, 0x75, 0x6e, 0x64, 0x65, 0x20, 0x6e, 0x65, 0x62, 0x6f, 0x20, 0x61,
-0x65, 0x6e, 0x67, 0x3b, 0x4d, 0x3b, 0x4e, 0x3b, 0x4b, 0x3b, 0x49, 0x3b, 0x4e, 0x3b, 0x57, 0x3b, 0x52, 0x3b, 0x4b, 0x3b,
-0x42, 0x3b, 0x45, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x1c3, 0x4b, 0x68, 0x61, 0x6e, 0x6e, 0x69, 0x3b, 0x1c3, 0x4b, 0x68, 0x61,
-0x6e, 0x1c0, 0x67, 0xf4, 0x61, 0x62, 0x3b, 0x1c0, 0x4b, 0x68, 0x75, 0x75, 0x1c1, 0x6b, 0x68, 0xe2, 0x62, 0x3b, 0x1c3, 0x48,
-0xf4, 0x61, 0x1c2, 0x6b, 0x68, 0x61, 0x69, 0x62, 0x3b, 0x1c3, 0x4b, 0x68, 0x61, 0x69, 0x74, 0x73, 0xe2, 0x62, 0x3b, 0x47,
-0x61, 0x6d, 0x61, 0x1c0, 0x61, 0x65, 0x62, 0x3b, 0x1c2, 0x4b, 0x68, 0x6f, 0x65, 0x73, 0x61, 0x6f, 0x62, 0x3b, 0x41, 0x6f,
-0x1c1, 0x6b, 0x68, 0x75, 0x75, 0x6d, 0xfb, 0x1c1, 0x6b, 0x68, 0xe2, 0x62, 0x3b, 0x54, 0x61, 0x72, 0x61, 0x1c0, 0x6b, 0x68,
-0x75, 0x75, 0x6d, 0xfb, 0x1c1, 0x6b, 0x68, 0xe2, 0x62, 0x3b, 0x1c2, 0x4e, 0xfb, 0x1c1, 0x6e, 0xe2, 0x69, 0x73, 0x65, 0x62,
-0x3b, 0x1c0, 0x48, 0x6f, 0x6f, 0x1c2, 0x67, 0x61, 0x65, 0x62, 0x3b, 0x48, 0xf4, 0x61, 0x73, 0x6f, 0x72, 0x65, 0x1c1, 0x6b,
-0x68, 0xe2, 0x62, 0x3b, 0x4a, 0x61, 0x6e, 0x2e, 0x3b, 0x46, 0xe4, 0x62, 0x2e, 0x3b, 0x4d, 0xe4, 0x7a, 0x2e, 0x3b, 0x41,
-0x70, 0x72, 0x2e, 0x3b, 0x4d, 0xe4, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x2e, 0x3b, 0x4a, 0x75, 0x6c, 0x2e, 0x3b, 0x4f, 0x75,
-0x6a, 0x2e, 0x3b, 0x53, 0xe4, 0x70, 0x2e, 0x3b, 0x4f, 0x6b, 0x74, 0x2e, 0x3b, 0x4e, 0x6f, 0x76, 0x2e, 0x3b, 0x44, 0x65,
-0x7a, 0x2e, 0x3b, 0x4a, 0x61, 0x6e, 0x6e, 0x65, 0x77, 0x61, 0x3b, 0x46, 0xe4, 0x62, 0x72, 0x6f, 0x77, 0x61, 0x3b, 0x4d,
-0xe4, 0xe4, 0x7a, 0x3b, 0x41, 0x70, 0x72, 0x65, 0x6c, 0x6c, 0x3b, 0x4d, 0xe4, 0x69, 0x3b, 0x4a, 0x75, 0x75, 0x6e, 0x69,
-0x3b, 0x4a, 0x75, 0x75, 0x6c, 0x69, 0x3b, 0x4f, 0x75, 0x6a, 0x6f, 0xdf, 0x3b, 0x53, 0x65, 0x70, 0x74, 0xe4, 0x6d, 0x62,
-0x65, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0xe4, 0x6d, 0x62, 0x65, 0x72,
-0x3b, 0x44, 0x65, 0x7a, 0xe4, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0xe4, 0x62, 0x3b, 0x4d, 0xe4,
-0x7a, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0xe4, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x4f, 0x75,
-0x6a, 0x3b, 0x53, 0xe4, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x7a, 0x3b, 0x44, 0x61,
-0x6c, 0x3b, 0x41, 0x72, 0xe1, 0x3b, 0x186, 0x25b, 0x6e, 0x3b, 0x44, 0x6f, 0x79, 0x3b, 0x4c, 0xe9, 0x70, 0x3b, 0x52, 0x6f,
-0x6b, 0x3b, 0x53, 0xe1, 0x73, 0x3b, 0x42, 0x254, 0x301, 0x72, 0x3b, 0x4b, 0xfa, 0x73, 0x3b, 0x47, 0xed, 0x73, 0x3b, 0x53,
-0x68, 0x289, 0x301, 0x3b, 0x4e, 0x74, 0x289, 0x301, 0x3b, 0x4f, 0x6c, 0x61, 0x64, 0x61, 0x6c, 0x289, 0x301, 0x3b, 0x41, 0x72,
-0xe1, 0x74, 0x3b, 0x186, 0x25b, 0x6e, 0x268, 0x301, 0x254, 0x268, 0x14b, 0x254, 0x6b, 0x3b, 0x4f, 0x6c, 0x6f, 0x64, 0x6f, 0x79,
-0xed, 0xf3, 0x72, 0xed, 0xea, 0x20, 0x69, 0x6e, 0x6b, 0xf3, 0x6b, 0xfa, 0xe2, 0x3b, 0x4f, 0x6c, 0x6f, 0x69, 0x6c, 0xe9,
-0x70, 0x16b, 0x6e, 0x79, 0x12b, 0x113, 0x20, 0x69, 0x6e, 0x6b, 0xf3, 0x6b, 0xfa, 0xe2, 0x3b, 0x4b, 0xfa, 0x6a, 0xfa, 0x254,
-0x72, 0x254, 0x6b, 0x3b, 0x4d, 0xf3, 0x72, 0x75, 0x73, 0xe1, 0x73, 0x69, 0x6e, 0x3b, 0x186, 0x6c, 0x254, 0x301, 0x268, 0x301,
-0x62, 0x254, 0x301, 0x72, 0xe1, 0x72, 0x25b, 0x3b, 0x4b, 0xfa, 0x73, 0x68, 0xee, 0x6e, 0x3b, 0x4f, 0x6c, 0x67, 0xed, 0x73,
-0x61, 0x6e, 0x3b, 0x50, 0x289, 0x73, 0x68, 0x289, 0x301, 0x6b, 0x61, 0x3b, 0x4e, 0x74, 0x289, 0x301, 0x14b, 0x289, 0x301, 0x73,
-0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x69,
-0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74,
-0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x63,
-0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f,
-0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x63, 0x3b, 0x52, 0x61, 0x72,
-0x3b, 0x4d, 0x75, 0x6b, 0x3b, 0x4b, 0x77, 0x61, 0x3b, 0x44, 0x75, 0x6e, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x4d, 0x6f, 0x64,
-0x3b, 0x4a, 0x6f, 0x6c, 0x3b, 0x50, 0x65, 0x64, 0x3b, 0x53, 0x6f, 0x6b, 0x3b, 0x54, 0x69, 0x62, 0x3b, 0x4c, 0x61, 0x62,
-0x3b, 0x50, 0x6f, 0x6f, 0x3b, 0x4f, 0x72, 0x61, 0x72, 0x61, 0x3b, 0x4f, 0x6d, 0x75, 0x6b, 0x3b, 0x4f, 0x6b, 0x77, 0x61,
-0x6d, 0x67, 0x27, 0x3b, 0x4f, 0x64, 0x75, 0x6e, 0x67, 0x27, 0x65, 0x6c, 0x3b, 0x4f, 0x6d, 0x61, 0x72, 0x75, 0x6b, 0x3b,
-0x4f, 0x6d, 0x6f, 0x64, 0x6f, 0x6b, 0x27, 0x6b, 0x69, 0x6e, 0x67, 0x27, 0x6f, 0x6c, 0x3b, 0x4f, 0x6a, 0x6f, 0x6c, 0x61,
-0x3b, 0x4f, 0x70, 0x65, 0x64, 0x65, 0x6c, 0x3b, 0x4f, 0x73, 0x6f, 0x6b, 0x6f, 0x73, 0x6f, 0x6b, 0x6f, 0x6d, 0x61, 0x3b,
-0x4f, 0x74, 0x69, 0x62, 0x61, 0x72, 0x3b, 0x4f, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x3b, 0x4f, 0x70, 0x6f, 0x6f, 0x3b, 0x52,
-0x3b, 0x4d, 0x3b, 0x4b, 0x3b, 0x44, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x50, 0x3b, 0x53, 0x3b, 0x54, 0x3b, 0x4c,
-0x3b, 0x50, 0x3b, 0x17d, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x65, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x77, 0x69, 0x3b, 0x4d,
-0x65, 0x3b, 0x17d, 0x75, 0x77, 0x3b, 0x17d, 0x75, 0x79, 0x3b, 0x55, 0x74, 0x3b, 0x53, 0x65, 0x6b, 0x3b, 0x4f, 0x6b, 0x74,
-0x3b, 0x4e, 0x6f, 0x6f, 0x3b, 0x44, 0x65, 0x65, 0x3b, 0x17d, 0x61, 0x6e, 0x77, 0x69, 0x79, 0x65, 0x3b, 0x46, 0x65, 0x65,
-0x77, 0x69, 0x72, 0x69, 0x79, 0x65, 0x3b, 0x4d, 0x61, 0x72, 0x73, 0x69, 0x3b, 0x41, 0x77, 0x69, 0x72, 0x69, 0x6c, 0x3b,
-0x4d, 0x65, 0x3b, 0x17d, 0x75, 0x77, 0x65, 0x14b, 0x3b, 0x17d, 0x75, 0x79, 0x79, 0x65, 0x3b, 0x55, 0x74, 0x3b, 0x53, 0x65,
-0x6b, 0x74, 0x61, 0x6e, 0x62, 0x75, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x6f, 0x62, 0x75, 0x72, 0x3b, 0x4e, 0x6f, 0x6f,
-0x77, 0x61, 0x6e, 0x62, 0x75, 0x72, 0x3b, 0x44, 0x65, 0x65, 0x73, 0x61, 0x6e, 0x62, 0x75, 0x72, 0x3b, 0x17d, 0x3b, 0x46,
-0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x17d, 0x3b, 0x17d, 0x3b, 0x55, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44,
-0x3b, 0x44, 0x41, 0x43, 0x3b, 0x44, 0x41, 0x52, 0x3b, 0x44, 0x41, 0x44, 0x3b, 0x44, 0x41, 0x4e, 0x3b, 0x44, 0x41, 0x48,
-0x3b, 0x44, 0x41, 0x55, 0x3b, 0x44, 0x41, 0x4f, 0x3b, 0x44, 0x41, 0x42, 0x3b, 0x44, 0x4f, 0x43, 0x3b, 0x44, 0x41, 0x50,
-0x3b, 0x44, 0x47, 0x49, 0x3b, 0x44, 0x41, 0x47, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x63, 0x68,
-0x69, 0x65, 0x6c, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x72, 0x69, 0x79, 0x6f, 0x3b, 0x44, 0x77,
-0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x64, 0x65, 0x6b, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41,
-0x6e, 0x67, 0x27, 0x77, 0x65, 0x6e, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x62, 0x69, 0x63, 0x68,
-0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x75, 0x63, 0x68, 0x69, 0x65, 0x6c, 0x3b, 0x44, 0x77, 0x65,
-0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x62, 0x69, 0x72, 0x69, 0x79, 0x6f, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72,
-0x20, 0x41, 0x62, 0x6f, 0x72, 0x6f, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x4f, 0x63, 0x68, 0x69, 0x6b,
-0x6f, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x70, 0x61, 0x72, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d,
-0x61, 0x72, 0x20, 0x67, 0x69, 0x20, 0x61, 0x63, 0x68, 0x69, 0x65, 0x6c, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72,
-0x20, 0x41, 0x70, 0x61, 0x72, 0x20, 0x67, 0x69, 0x20, 0x61, 0x72, 0x69, 0x79, 0x6f, 0x3b, 0x43, 0x3b, 0x52, 0x3b, 0x44,
-0x3b, 0x4e, 0x3b, 0x42, 0x3b, 0x55, 0x3b, 0x42, 0x3b, 0x42, 0x3b, 0x43, 0x3b, 0x50, 0x3b, 0x43, 0x3b, 0x50, 0x3b, 0x59,
-0x65, 0x6e, 0x3b, 0x59, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x49, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x59,
-0x75, 0x6e, 0x3b, 0x59, 0x75, 0x6c, 0x3b, 0x194, 0x75, 0x63, 0x3b, 0x43, 0x75, 0x74, 0x3b, 0x4b, 0x1e6d, 0x75, 0x3b, 0x4e,
-0x77, 0x61, 0x3b, 0x44, 0x75, 0x6a, 0x3b, 0x59, 0x65, 0x6e, 0x6e, 0x61, 0x79, 0x65, 0x72, 0x3b, 0x59, 0x65, 0x62, 0x72,
-0x61, 0x79, 0x65, 0x72, 0x3b, 0x4d, 0x61, 0x72, 0x73, 0x3b, 0x49, 0x62, 0x72, 0x69, 0x72, 0x3b, 0x4d, 0x61, 0x79, 0x79,
-0x75, 0x3b, 0x59, 0x75, 0x6e, 0x79, 0x75, 0x3b, 0x59, 0x75, 0x6c, 0x79, 0x75, 0x7a, 0x3b, 0x194, 0x75, 0x63, 0x74, 0x3b,
-0x43, 0x75, 0x74, 0x61, 0x6e, 0x62, 0x69, 0x72, 0x3b, 0x4b, 0x1e6d, 0x75, 0x62, 0x65, 0x72, 0x3b, 0x4e, 0x77, 0x61, 0x6e,
-0x62, 0x69, 0x72, 0x3b, 0x44, 0x75, 0x6a, 0x61, 0x6e, 0x62, 0x69, 0x72, 0x3b, 0x59, 0x3b, 0x59, 0x3b, 0x4d, 0x3b, 0x49,
-0x3b, 0x4d, 0x3b, 0x59, 0x3b, 0x59, 0x3b, 0x194, 0x3b, 0x43, 0x3b, 0x4b, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4a, 0x61, 0x6e,
-0x75, 0x61, 0x6c, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x6c, 0x75, 0x61, 0x6c, 0x69, 0x3b, 0x4d, 0x61, 0x63, 0x68, 0x69, 0x3b,
-0x41, 0x70, 0x6c, 0x69, 0x6c, 0x69, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x61,
-0x69, 0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b,
-0x74, 0x6f, 0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x61,
-0x3b, 0x91c, 0x93e, 0x928, 0x941, 0x935, 0x93e, 0x930, 0x940, 0x3b, 0x92b, 0x947, 0x92c, 0x94d, 0x930, 0x941, 0x935, 0x93e, 0x930, 0x940,
-0x3b, 0x92e, 0x93e, 0x930, 0x94d, 0x938, 0x3b, 0x90f, 0x92b, 0x94d, 0x930, 0x93f, 0x932, 0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x941, 0x928,
-0x3b, 0x91c, 0x941, 0x932, 0x93e, 0x907, 0x3b, 0x906, 0x917, 0x938, 0x94d, 0x925, 0x3b, 0x938, 0x947, 0x92c, 0x925, 0x947, 0x91c, 0x94d,
-0x92c, 0x93c, 0x930, 0x3b, 0x905, 0x916, 0x925, 0x92c, 0x930, 0x3b, 0x928, 0x92c, 0x947, 0x91c, 0x94d, 0x92c, 0x93c, 0x930, 0x3b, 0x926,
-0x93f, 0x938, 0x947, 0x91c, 0x94d, 0x92c, 0x93c, 0x930, 0x3b, 0x91c, 0x3b, 0x92b, 0x947, 0x3b, 0x92e, 0x93e, 0x3b, 0x90f, 0x3b, 0x92e,
-0x947, 0x3b, 0x91c, 0x941, 0x3b, 0x91c, 0x941, 0x3b, 0x906, 0x3b, 0x938, 0x947, 0x3b, 0x905, 0x3b, 0x928, 0x3b, 0x926, 0x93f, 0x3b,
-0x43, 0x69, 0x6f, 0x3b, 0x4c, 0x75, 0x69, 0x3b, 0x4c, 0x75, 0x73, 0x3b, 0x4d, 0x75, 0x75, 0x3b, 0x4c, 0x75, 0x6d, 0x3b,
-0x4c, 0x75, 0x66, 0x3b, 0x4b, 0x61, 0x62, 0x3b, 0x4c, 0x75, 0x73, 0x68, 0x3b, 0x4c, 0x75, 0x74, 0x3b, 0x4c, 0x75, 0x6e,
-0x3b, 0x4b, 0x61, 0x73, 0x3b, 0x43, 0x69, 0x73, 0x3b, 0x43, 0x69, 0x6f, 0x6e, 0x67, 0x6f, 0x3b, 0x4c, 0xf9, 0x69, 0x73,
-0x68, 0x69, 0x3b, 0x4c, 0x75, 0x73, 0xf2, 0x6c, 0x6f, 0x3b, 0x4d, 0xf9, 0x75, 0x79, 0xe0, 0x3b, 0x4c, 0x75, 0x6d, 0xf9,
-0x6e, 0x67, 0xf9, 0x6c, 0xf9, 0x3b, 0x4c, 0x75, 0x66, 0x75, 0x69, 0x6d, 0x69, 0x3b, 0x4b, 0x61, 0x62, 0xe0, 0x6c, 0xe0,
-0x73, 0x68, 0xec, 0x70, 0xf9, 0x3b, 0x4c, 0xf9, 0x73, 0x68, 0xec, 0x6b, 0xe0, 0x3b, 0x4c, 0x75, 0x74, 0x6f, 0x6e, 0x67,
-0x6f, 0x6c, 0x6f, 0x3b, 0x4c, 0x75, 0x6e, 0x67, 0xf9, 0x64, 0x69, 0x3b, 0x4b, 0x61, 0x73, 0x77, 0xe8, 0x6b, 0xe8, 0x73,
-0xe8, 0x3b, 0x43, 0x69, 0x73, 0x77, 0xe0, 0x3b, 0x43, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b,
-0x4b, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4b, 0x3b, 0x43, 0x3b, 0x6e, 0xf9, 0x6d, 0x3b, 0x6b, 0x268, 0x7a, 0x3b,
-0x74, 0x268, 0x64, 0x3b, 0x74, 0x61, 0x61, 0x3b, 0x73, 0x65, 0x65, 0x3b, 0x6e, 0x7a, 0x75, 0x3b, 0x64, 0x75, 0x6d, 0x3b,
-0x66, 0x254, 0x65, 0x3b, 0x64, 0x7a, 0x75, 0x3b, 0x6c, 0x254, 0x6d, 0x3b, 0x6b, 0x61, 0x61, 0x3b, 0x66, 0x77, 0x6f, 0x3b,
-0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x6e, 0xf9, 0x6d, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300,
-0x6b, 0x197, 0x300, 0x7a, 0xf9, 0x294, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x74, 0x197, 0x300, 0x64, 0x289,
-0x300, 0x67, 0x68, 0xe0, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x74, 0x1ce, 0x61, 0x66, 0x289, 0x304, 0x67,
-0x68, 0x101, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0xe8, 0x73, 0xe8, 0x65, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b,
-0x254, 0x300, 0x6e, 0x7a, 0xf9, 0x67, 0x68, 0xf2, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x64, 0xf9, 0x6d,
-0x6c, 0x6f, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x6b, 0x77, 0xee, 0x66, 0x254, 0x300, 0x65, 0x3b, 0x6e,
-0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x74, 0x197, 0x300, 0x66, 0x289, 0x300, 0x67, 0x68, 0xe0, 0x64, 0x7a, 0x75, 0x67,
-0x68, 0xf9, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x67, 0x68, 0x1d4, 0x75, 0x77, 0x65, 0x6c, 0x254, 0x300,
-0x6d, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x63, 0x68, 0x77, 0x61, 0x294, 0xe0, 0x6b, 0x61, 0x61, 0x20,
-0x77, 0x6f, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0xe8, 0x66, 0x77, 0xf2, 0x6f, 0x3b, 0x6e, 0x3b, 0x6b, 0x3b, 0x74,
-0x3b, 0x74, 0x3b, 0x73, 0x3b, 0x7a, 0x3b, 0x6b, 0x3b, 0x66, 0x3b, 0x64, 0x3b, 0x6c, 0x3b, 0x63, 0x3b, 0x66, 0x3b, 0x6b,
-0x254, 0x6e, 0x3b, 0x6d, 0x61, 0x63, 0x3b, 0x6d, 0x61, 0x74, 0x3b, 0x6d, 0x74, 0x6f, 0x3b, 0x6d, 0x70, 0x75, 0x3b, 0x68,
-0x69, 0x6c, 0x3b, 0x6e, 0x6a, 0x65, 0x3b, 0x68, 0x69, 0x6b, 0x3b, 0x64, 0x69, 0x70, 0x3b, 0x62, 0x69, 0x6f, 0x3b, 0x6d,
-0x61, 0x79, 0x3b, 0x6c, 0x69, 0x253, 0x3b, 0x4b, 0x254, 0x6e, 0x64, 0x254, 0x14b, 0x3b, 0x4d, 0xe0, 0x63, 0x25b, 0x302, 0x6c,
-0x3b, 0x4d, 0xe0, 0x74, 0xf9, 0x6d, 0x62, 0x3b, 0x4d, 0xe0, 0x74, 0x6f, 0x70, 0x3b, 0x4d, 0x300, 0x70, 0x75, 0x79, 0x25b,
-0x3b, 0x48, 0xec, 0x6c, 0xf2, 0x6e, 0x64, 0x25b, 0x300, 0x3b, 0x4e, 0x6a, 0xe8, 0x62, 0xe0, 0x3b, 0x48, 0xec, 0x6b, 0x61,
-0x14b, 0x3b, 0x44, 0xec, 0x70, 0x254, 0x300, 0x73, 0x3b, 0x42, 0xec, 0xf2, 0xf4, 0x6d, 0x3b, 0x4d, 0xe0, 0x79, 0x25b, 0x73,
-0xe8, 0x70, 0x3b, 0x4c, 0xec, 0x62, 0x75, 0x79, 0x20, 0x6c, 0x69, 0x20, 0x144, 0x79, 0xe8, 0x65, 0x3b, 0x6b, 0x3b, 0x6d,
-0x3b, 0x6d, 0x3b, 0x6d, 0x3b, 0x6d, 0x3b, 0x68, 0x3b, 0x6e, 0x3b, 0x68, 0x3b, 0x64, 0x3b, 0x62, 0x3b, 0x6d, 0x3b, 0x6c,
-0x3b, 0x64, 0x69, 0x3b, 0x14b, 0x67, 0x254, 0x6e, 0x3b, 0x73, 0x254, 0x14b, 0x3b, 0x64, 0x69, 0x253, 0x3b, 0x65, 0x6d, 0x69,
-0x3b, 0x65, 0x73, 0x254, 0x3b, 0x6d, 0x61, 0x64, 0x3b, 0x64, 0x69, 0x14b, 0x3b, 0x6e, 0x79, 0x25b, 0x74, 0x3b, 0x6d, 0x61,
-0x79, 0x3b, 0x74, 0x69, 0x6e, 0x3b, 0x65, 0x6c, 0xe1, 0x3b, 0x64, 0x69, 0x6d, 0x254, 0x301, 0x64, 0x69, 0x3b, 0x14b, 0x67,
-0x254, 0x6e, 0x64, 0x25b, 0x3b, 0x73, 0x254, 0x14b, 0x25b, 0x3b, 0x64, 0x69, 0x253, 0xe1, 0x253, 0xe1, 0x3b, 0x65, 0x6d, 0x69,
-0x61, 0x73, 0x65, 0x6c, 0x65, 0x3b, 0x65, 0x73, 0x254, 0x70, 0x25b, 0x73, 0x254, 0x70, 0x25b, 0x3b, 0x6d, 0x61, 0x64, 0x69,
-0x253, 0x25b, 0x301, 0x64, 0xed, 0x253, 0x25b, 0x301, 0x3b, 0x64, 0x69, 0x14b, 0x67, 0x69, 0x6e, 0x64, 0x69, 0x3b, 0x6e, 0x79,
-0x25b, 0x74, 0x25b, 0x6b, 0x69, 0x3b, 0x6d, 0x61, 0x79, 0xe9, 0x73, 0x25b, 0x301, 0x3b, 0x74, 0x69, 0x6e, 0xed, 0x6e, 0xed,
-0x3b, 0x65, 0x6c, 0xe1, 0x14b, 0x67, 0x25b, 0x301, 0x3b, 0x64, 0x3b, 0x14b, 0x3b, 0x73, 0x3b, 0x64, 0x3b, 0x65, 0x3b, 0x65,
-0x3b, 0x6d, 0x3b, 0x64, 0x3b, 0x6e, 0x3b, 0x6d, 0x3b, 0x74, 0x3b, 0x65, 0x3b, 0x53, 0x61, 0x3b, 0x46, 0x65, 0x3b, 0x4d,
-0x61, 0x3b, 0x41, 0x62, 0x3b, 0x4d, 0x65, 0x3b, 0x53, 0x75, 0x3b, 0x53, 0xfa, 0x3b, 0x55, 0x74, 0x3b, 0x53, 0x65, 0x3b,
-0x4f, 0x6b, 0x3b, 0x4e, 0x6f, 0x3b, 0x44, 0x65, 0x3b, 0x53, 0x61, 0x6e, 0x76, 0x69, 0x65, 0x3b, 0x46, 0xe9, 0x62, 0x69,
-0x72, 0x69, 0x65, 0x3b, 0x4d, 0x61, 0x72, 0x73, 0x3b, 0x41, 0x62, 0x75, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x65, 0x65, 0x3b,
-0x53, 0x75, 0x65, 0x14b, 0x3b, 0x53, 0xfa, 0x75, 0x79, 0x65, 0x65, 0x3b, 0x55, 0x74, 0x3b, 0x53, 0x65, 0x74, 0x74, 0x65,
-0x6d, 0x62, 0x61, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61,
-0x72, 0x3b, 0x44, 0x69, 0x73, 0x61, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x53, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d,
-0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x55, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x6e, 0x67, 0x6f, 0x3b, 0x6e,
-0x67, 0x62, 0x3b, 0x6e, 0x67, 0x6c, 0x3b, 0x6e, 0x67, 0x6e, 0x3b, 0x6e, 0x67, 0x74, 0x3b, 0x6e, 0x67, 0x73, 0x3b, 0x6e,
-0x67, 0x7a, 0x3b, 0x6e, 0x67, 0x6d, 0x3b, 0x6e, 0x67, 0x65, 0x3b, 0x6e, 0x67, 0x61, 0x3b, 0x6e, 0x67, 0x61, 0x64, 0x3b,
-0x6e, 0x67, 0x61, 0x62, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x6f, 0x73, 0xfa, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x62,
-0x25b, 0x30c, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x6c, 0xe1, 0x6c, 0x61, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x6e, 0x79,
-0x69, 0x6e, 0x61, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x74, 0xe1, 0x6e, 0x61, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x73,
-0x61, 0x6d, 0x259, 0x6e, 0x61, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x7a, 0x61, 0x6d, 0x67, 0x62, 0xe1, 0x6c, 0x61, 0x3b,
-0x6e, 0x67, 0x254, 0x6e, 0x20, 0x6d, 0x77, 0x6f, 0x6d, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x65, 0x62, 0x75, 0x6c, 0xfa,
-0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x61, 0x77, 0xf3, 0x6d, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x61, 0x77, 0xf3, 0x6d,
-0x20, 0x61, 0x69, 0x20, 0x64, 0x7a, 0x69, 0xe1, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x61, 0x77, 0xf3, 0x6d, 0x20, 0x61,
-0x69, 0x20, 0x62, 0x25b, 0x30c, 0x3b, 0x6f, 0x3b, 0x62, 0x3b, 0x6c, 0x3b, 0x6e, 0x3b, 0x74, 0x3b, 0x73, 0x3b, 0x7a, 0x3b,
-0x6d, 0x3b, 0x65, 0x3b, 0x61, 0x3b, 0x64, 0x3b, 0x62, 0x3b, 0x14b, 0x31, 0x3b, 0x14b, 0x32, 0x3b, 0x14b, 0x33, 0x3b, 0x14b,
-0x34, 0x3b, 0x14b, 0x35, 0x3b, 0x14b, 0x36, 0x3b, 0x14b, 0x37, 0x3b, 0x14b, 0x38, 0x3b, 0x14b, 0x39, 0x3b, 0x14b, 0x31, 0x30,
-0x3b, 0x14b, 0x31, 0x31, 0x3b, 0x14b, 0x31, 0x32, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x20, 0x6e, 0x74, 0x254, 0x301,
-0x6e, 0x74, 0x254, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x62, 0x25b, 0x301, 0x25b, 0x3b, 0x14b, 0x77,
-0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x72, 0xe1, 0xe1, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20,
-0x6e, 0x69, 0x6e, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x74, 0xe1, 0x61, 0x6e, 0x3b, 0x14b, 0x77,
-0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x74, 0xe1, 0x61, 0x66, 0x254, 0x6b, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61,
-0x6b, 0x1dd, 0x20, 0x74, 0xe1, 0x61, 0x62, 0x25b, 0x25b, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x74,
-0xe1, 0x61, 0x72, 0x61, 0x61, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x74, 0xe1, 0x61, 0x6e, 0x69,
-0x6e, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x6e, 0x74, 0x25b, 0x6b, 0x3b, 0x14b, 0x77, 0xed, 0xed,
-0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x6e, 0x74, 0x25b, 0x6b, 0x20, 0x64, 0x69, 0x20, 0x62, 0x254, 0x301, 0x6b, 0x3b, 0x14b, 0x77,
-0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x6e, 0x74, 0x25b, 0x6b, 0x20, 0x64, 0x69, 0x20, 0x62, 0x25b, 0x301, 0x25b, 0x3b,
-0x4b, 0x77, 0x61, 0x3b, 0x55, 0x6e, 0x61, 0x3b, 0x52, 0x61, 0x72, 0x3b, 0x43, 0x68, 0x65, 0x3b, 0x54, 0x68, 0x61, 0x3b,
-0x4d, 0x6f, 0x63, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x4e, 0x61, 0x6e, 0x3b, 0x54, 0x69, 0x73, 0x3b, 0x4b, 0x75, 0x6d, 0x3b,
-0x4d, 0x6f, 0x6a, 0x3b, 0x59, 0x65, 0x6c, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x6b, 0x77, 0x61,
-0x6e, 0x7a, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x75, 0x6e, 0x61, 0x79, 0x65, 0x6c, 0x69,
-0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x75, 0x6e, 0x65, 0x72, 0x61, 0x72, 0x75, 0x3b, 0x4d, 0x77,
-0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x75, 0x6e, 0x65, 0x63, 0x68, 0x65, 0x73, 0x68, 0x65, 0x3b, 0x4d, 0x77, 0x65,
-0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x75, 0x6e, 0x65, 0x74, 0x68, 0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69,
-0x20, 0x77, 0x6f, 0x20, 0x74, 0x68, 0x61, 0x6e, 0x75, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x6f, 0x63, 0x68, 0x61, 0x3b, 0x4d,
-0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x73, 0x61, 0x62, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77,
-0x6f, 0x20, 0x6e, 0x61, 0x6e, 0x65, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x74, 0x69, 0x73, 0x61,
-0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69,
-0x20, 0x77, 0x6f, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x6f, 0x6a, 0x61, 0x3b, 0x4d, 0x77, 0x65,
-0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x79, 0x65, 0x6c, 0x27, 0x6c, 0x69,
-0x3b, 0x4b, 0x3b, 0x55, 0x3b, 0x52, 0x3b, 0x43, 0x3b, 0x54, 0x3b, 0x4d, 0x3b, 0x53, 0x3b, 0x4e, 0x3b, 0x54, 0x3b, 0x4b,
-0x3b, 0x4d, 0x3b, 0x59, 0x3b, 0x46, 0x4c, 0x4f, 0x3b, 0x43, 0x4c, 0x41, 0x3b, 0x43, 0x4b, 0x49, 0x3b, 0x46, 0x4d, 0x46,
-0x3b, 0x4d, 0x41, 0x44, 0x3b, 0x4d, 0x42, 0x49, 0x3b, 0x4d, 0x4c, 0x49, 0x3b, 0x4d, 0x41, 0x4d, 0x3b, 0x46, 0x44, 0x45,
-0x3b, 0x46, 0x4d, 0x55, 0x3b, 0x46, 0x47, 0x57, 0x3b, 0x46, 0x59, 0x55, 0x3b, 0x46, 0x129, 0x69, 0x20, 0x4c, 0x6f, 0x6f,
-0x3b, 0x43, 0x6f, 0x6b, 0x63, 0x77, 0x61, 0x6b, 0x6c, 0x61, 0x14b, 0x6e, 0x65, 0x3b, 0x43, 0x6f, 0x6b, 0x63, 0x77, 0x61,
-0x6b, 0x6c, 0x69, 0x69, 0x3b, 0x46, 0x129, 0x69, 0x20, 0x4d, 0x61, 0x72, 0x66, 0x6f, 0x6f, 0x3b, 0x4d, 0x61, 0x64, 0x1dd,
-0x1dd, 0x75, 0x75, 0x74, 0x1dd, 0x62, 0x69, 0x6a, 0x61, 0x14b, 0x3b, 0x4d, 0x61, 0x6d, 0x1dd, 0x14b, 0x67, 0x77, 0xe3, 0x61,
-0x66, 0x61, 0x68, 0x62, 0x69, 0x69, 0x3b, 0x4d, 0x61, 0x6d, 0x1dd, 0x14b, 0x67, 0x77, 0xe3, 0x61, 0x6c, 0x69, 0x69, 0x3b,
-0x4d, 0x61, 0x64, 0x1dd, 0x6d, 0x62, 0x69, 0x69, 0x3b, 0x46, 0x129, 0x69, 0x20, 0x44, 0x1dd, 0x253, 0x6c, 0x69, 0x69, 0x3b,
-0x46, 0x129, 0x69, 0x20, 0x4d, 0x75, 0x6e, 0x64, 0x61, 0x14b, 0x3b, 0x46, 0x129, 0x69, 0x20, 0x47, 0x77, 0x61, 0x68, 0x6c,
-0x6c, 0x65, 0x3b, 0x46, 0x129, 0x69, 0x20, 0x59, 0x75, 0x72, 0x75, 0x3b, 0x4f, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x46, 0x3b,
-0x44, 0x3b, 0x42, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x45, 0x3b, 0x55, 0x3b, 0x57, 0x3b, 0x59, 0x3b, 0x6e, 0x67, 0x31, 0x3b,
-0x6e, 0x67, 0x32, 0x3b, 0x6e, 0x67, 0x33, 0x3b, 0x6e, 0x67, 0x34, 0x3b, 0x6e, 0x67, 0x35, 0x3b, 0x6e, 0x67, 0x36, 0x3b,
-0x6e, 0x67, 0x37, 0x3b, 0x6e, 0x67, 0x38, 0x3b, 0x6e, 0x67, 0x39, 0x3b, 0x6e, 0x67, 0x31, 0x30, 0x3b, 0x6e, 0x67, 0x31,
-0x31, 0x3b, 0x6b, 0x72, 0x69, 0x73, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x6d, 0x61, 0x74, 0xe1, 0x68, 0x72, 0x61,
-0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x144, 0x6d, 0x62, 0x61, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x144, 0x6c,
-0x61, 0x6c, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x144, 0x6e, 0x61, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x144,
-0x74, 0x61, 0x6e, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x144, 0x74, 0x75, 0xf3, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e,
-0x20, 0x68, 0x25b, 0x6d, 0x62, 0x75, 0x25b, 0x72, 0xed, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x6c, 0x254, 0x6d, 0x62,
-0x69, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x72, 0x25b, 0x62, 0x76, 0x75, 0xe2, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e,
-0x20, 0x77, 0x75, 0x6d, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x77, 0x75, 0x6d, 0x20, 0x6e, 0x61, 0x76, 0x16d, 0x72,
-0x3b, 0x6b, 0x72, 0xed, 0x73, 0x69, 0x6d, 0x69, 0x6e, 0x3b, 0x54, 0x69, 0x6f, 0x70, 0x3b, 0x50, 0x25b, 0x74, 0x3b, 0x44,
-0x75, 0x254, 0x331, 0x254, 0x331, 0x3b, 0x47, 0x75, 0x61, 0x6b, 0x3b, 0x44, 0x75, 0xe4, 0x3b, 0x4b, 0x6f, 0x72, 0x3b, 0x50,
-0x61, 0x79, 0x3b, 0x54, 0x68, 0x6f, 0x6f, 0x3b, 0x54, 0x25b, 0x25b, 0x3b, 0x4c, 0x61, 0x61, 0x3b, 0x4b, 0x75, 0x72, 0x3b,
-0x54, 0x69, 0x64, 0x3b, 0x54, 0x69, 0x6f, 0x70, 0x20, 0x74, 0x68, 0x61, 0x72, 0x20, 0x70, 0x25b, 0x74, 0x3b, 0x50, 0x25b,
-0x74, 0x3b, 0x44, 0x75, 0x254, 0x331, 0x254, 0x331, 0x14b, 0x3b, 0x47, 0x75, 0x61, 0x6b, 0x3b, 0x44, 0x75, 0xe4, 0x74, 0x3b,
-0x4b, 0x6f, 0x72, 0x6e, 0x79, 0x6f, 0x6f, 0x74, 0x3b, 0x50, 0x61, 0x79, 0x20, 0x79, 0x69, 0x65, 0x331, 0x74, 0x6e, 0x69,
-0x3b, 0x54, 0x68, 0x6f, 0x331, 0x6f, 0x331, 0x72, 0x3b, 0x54, 0x25b, 0x25b, 0x72, 0x3b, 0x4c, 0x61, 0x61, 0x74, 0x68, 0x3b,
-0x4b, 0x75, 0x72, 0x3b, 0x54, 0x69, 0x6f, 0x331, 0x70, 0x20, 0x69, 0x6e, 0x20, 0x64, 0x69, 0x331, 0x69, 0x331, 0x74, 0x3b,
-0x54, 0x3b, 0x50, 0x3b, 0x44, 0x3b, 0x47, 0x3b, 0x44, 0x3b, 0x4b, 0x3b, 0x50, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x4c, 0x3b,
-0x4b, 0x3b, 0x54, 0x3b, 0x422, 0x43e, 0x445, 0x441, 0x3b, 0x41e, 0x43b, 0x443, 0x43d, 0x3b, 0x41a, 0x43b, 0x43d, 0x5f, 0x442, 0x442,
-0x440, 0x3b, 0x41c, 0x443, 0x441, 0x5f, 0x443, 0x441, 0x442, 0x3b, 0x42b, 0x430, 0x43c, 0x5f, 0x439, 0x43d, 0x3b, 0x411, 0x44d, 0x441,
-0x5f, 0x439, 0x43d, 0x3b, 0x41e, 0x442, 0x5f, 0x439, 0x43d, 0x3b, 0x410, 0x442, 0x440, 0x434, 0x44c, 0x5f, 0x439, 0x43d, 0x3b, 0x411,
-0x43b, 0x495, 0x43d, 0x5f, 0x439, 0x43d, 0x3b, 0x410, 0x43b, 0x442, 0x3b, 0x421, 0x44d, 0x442, 0x3b, 0x410, 0x445, 0x441, 0x3b, 0x422,
-0x43e, 0x445, 0x441, 0x443, 0x43d, 0x43d, 0x44c, 0x443, 0x3b, 0x41e, 0x43b, 0x443, 0x43d, 0x43d, 0x44c, 0x443, 0x3b, 0x41a, 0x443, 0x43b,
-0x443, 0x43d, 0x20, 0x442, 0x443, 0x442, 0x430, 0x440, 0x3b, 0x41c, 0x443, 0x443, 0x441, 0x20, 0x443, 0x441, 0x442, 0x430, 0x440, 0x3b,
-0x42b, 0x430, 0x43c, 0x20, 0x44b, 0x439, 0x44b, 0x43d, 0x3b, 0x411, 0x44d, 0x441, 0x20, 0x44b, 0x439, 0x44b, 0x43d, 0x3b, 0x41e, 0x442,
-0x20, 0x44b, 0x439, 0x44b, 0x43d, 0x3b, 0x410, 0x442, 0x44b, 0x440, 0x434, 0x44c, 0x44b, 0x445, 0x20, 0x44b, 0x439, 0x44b, 0x43d, 0x3b,
-0x411, 0x430, 0x43b, 0x430, 0x495, 0x430, 0x43d, 0x20, 0x44b, 0x439, 0x44b, 0x43d, 0x3b, 0x410, 0x43b, 0x442, 0x44b, 0x43d, 0x43d, 0x44c,
-0x44b, 0x3b, 0x421, 0x44d, 0x442, 0x438, 0x43d, 0x43d, 0x44c, 0x438, 0x3b, 0x410, 0x445, 0x441, 0x44b, 0x43d, 0x43d, 0x44c, 0x44b, 0x3b,
-0x422, 0x3b, 0x41e, 0x3b, 0x41a, 0x3b, 0x41c, 0x3b, 0x42b, 0x3b, 0x411, 0x3b, 0x41e, 0x3b, 0x410, 0x3b, 0x411, 0x3b, 0x410, 0x3b,
-0x421, 0x3b, 0x410, 0x3b, 0x4d, 0x75, 0x70, 0x3b, 0x4d, 0x77, 0x69, 0x3b, 0x4d, 0x73, 0x68, 0x3b, 0x4d, 0x75, 0x6e, 0x3b,
-0x4d, 0x61, 0x67, 0x3b, 0x4d, 0x75, 0x6a, 0x3b, 0x4d, 0x73, 0x70, 0x3b, 0x4d, 0x70, 0x67, 0x3b, 0x4d, 0x79, 0x65, 0x3b,
-0x4d, 0x6f, 0x6b, 0x3b, 0x4d, 0x75, 0x73, 0x3b, 0x4d, 0x75, 0x68, 0x3b, 0x4d, 0x75, 0x70, 0x61, 0x6c, 0x61, 0x6e, 0x67,
-0x75, 0x6c, 0x77, 0x61, 0x3b, 0x4d, 0x77, 0x69, 0x74, 0x6f, 0x70, 0x65, 0x3b, 0x4d, 0x75, 0x73, 0x68, 0x65, 0x6e, 0x64,
-0x65, 0x3b, 0x4d, 0x75, 0x6e, 0x79, 0x69, 0x3b, 0x4d, 0x75, 0x73, 0x68, 0x65, 0x6e, 0x64, 0x65, 0x20, 0x4d, 0x61, 0x67,
-0x61, 0x6c, 0x69, 0x3b, 0x4d, 0x75, 0x6a, 0x69, 0x6d, 0x62, 0x69, 0x3b, 0x4d, 0x75, 0x73, 0x68, 0x69, 0x70, 0x65, 0x70,
-0x6f, 0x3b, 0x4d, 0x75, 0x70, 0x75, 0x67, 0x75, 0x74, 0x6f, 0x3b, 0x4d, 0x75, 0x6e, 0x79, 0x65, 0x6e, 0x73, 0x65, 0x3b,
-0x4d, 0x6f, 0x6b, 0x68, 0x75, 0x3b, 0x4d, 0x75, 0x73, 0x6f, 0x6e, 0x67, 0x61, 0x6e, 0x64, 0x65, 0x6d, 0x62, 0x77, 0x65,
-0x3b, 0x4d, 0x75, 0x68, 0x61, 0x61, 0x6e, 0x6f, 0x3b, 0x6d, 0x6b, 0x77, 0x3b, 0x6d, 0x70, 0x69, 0x3b, 0x6d, 0x74, 0x75,
-0x3b, 0x6d, 0x69, 0x6e, 0x3b, 0x6d, 0x74, 0x6e, 0x3b, 0x6d, 0x73, 0x74, 0x3b, 0x6d, 0x73, 0x62, 0x3b, 0x6d, 0x75, 0x6e,
-0x3b, 0x6d, 0x74, 0x73, 0x3b, 0x6d, 0x6b, 0x75, 0x3b, 0x6d, 0x6b, 0x6d, 0x3b, 0x6d, 0x6b, 0x62, 0x3b, 0x6d, 0x77, 0x65,
-0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x6b, 0x77, 0x61, 0x6e, 0x6a, 0x61, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79,
-0x61, 0x20, 0x70, 0x69, 0x6c, 0x69, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x74, 0x61, 0x74, 0x75,
-0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x69, 0x6e, 0x65, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20,
-0x79, 0x61, 0x20, 0x74, 0x61, 0x6e, 0x75, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x73, 0x69, 0x74,
-0x61, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x73, 0x61, 0x62, 0x61, 0x3b, 0x6d, 0x77, 0x65, 0x7a,
-0x69, 0x20, 0x79, 0x61, 0x20, 0x6d, 0x75, 0x6e, 0x61, 0x6e, 0x65, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61,
-0x20, 0x74, 0x69, 0x73, 0x61, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x3b,
-0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x6f, 0x79,
-0x61, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x79, 0x61, 0x20, 0x6d,
-0x62, 0x69, 0x6c, 0x69, 0x3b, 0x6b, 0x3b, 0x70, 0x3b, 0x74, 0x3b, 0x69, 0x3b, 0x74, 0x3b, 0x73, 0x3b, 0x73, 0x3b, 0x6d,
-0x3b, 0x74, 0x3b, 0x6b, 0x3b, 0x6d, 0x3b, 0x6d, 0x3b, 0xa5a8, 0xa56a, 0xa583, 0x20, 0xa51e, 0xa56e, 0x3b, 0xa552, 0xa561, 0xa59d, 0xa595,
-0x3b, 0xa57e, 0xa5ba, 0x3b, 0xa5a2, 0xa595, 0x3b, 0xa591, 0xa571, 0x3b, 0x36, 0x3b, 0x37, 0x3b, 0xa5db, 0xa515, 0x3b, 0xa562, 0xa54c, 0x3b,
-0xa56d, 0xa583, 0x3b, 0xa51e, 0xa60b, 0xa554, 0xa57f, 0x20, 0xa578, 0xa583, 0xa5cf, 0x3b, 0xa5a8, 0xa56a, 0xa571, 0x20, 0xa5cf, 0xa56e, 0x3b, 0x6c,
-0x75, 0x75, 0x6b, 0x61, 0x6f, 0x20, 0x6b, 0x65, 0x6d, 0xe3, 0x3b, 0x253, 0x61, 0x6e, 0x64, 0x61, 0x253, 0x75, 0x3b, 0x76,
-0x254, 0x254, 0x3b, 0x66, 0x75, 0x6c, 0x75, 0x3b, 0x67, 0x6f, 0x6f, 0x3b, 0x36, 0x3b, 0x37, 0x3b, 0x6b, 0x254, 0x6e, 0x64,
-0x65, 0x3b, 0x73, 0x61, 0x61, 0x68, 0x3b, 0x67, 0x61, 0x6c, 0x6f, 0x3b, 0x6b, 0x65, 0x6e, 0x70, 0x6b, 0x61, 0x74, 0x6f,
-0x20, 0x253, 0x6f, 0x6c, 0x6f, 0x6c, 0x254, 0x3b, 0x6c, 0x75, 0x75, 0x6b, 0x61, 0x6f, 0x20, 0x6c, 0x254, 0x6d, 0x61, 0x3b,
-0x4a, 0x65, 0x6e, 0x3b, 0x48, 0x6f, 0x72, 0x3b, 0x4d, 0xe4, 0x72, 0x3b, 0x41, 0x62, 0x72, 0x3b, 0x4d, 0x65, 0x69, 0x3b,
-0x42, 0x72, 0xe1, 0x3b, 0x48, 0x65, 0x69, 0x3b, 0xd6, 0x69, 0x67, 0x3b, 0x48, 0x65, 0x72, 0x3b, 0x57, 0xed, 0x6d, 0x3b,
-0x57, 0x69, 0x6e, 0x3b, 0x43, 0x68, 0x72, 0x3b, 0x4a, 0x65, 0x6e, 0x6e, 0x65, 0x72, 0x3b, 0x48, 0x6f, 0x72, 0x6e, 0x69,
-0x67, 0x3b, 0x4d, 0xe4, 0x72, 0x7a, 0x65, 0x3b, 0x41, 0x62, 0x72, 0x69, 0x6c, 0x6c, 0x65, 0x3b, 0x4d, 0x65, 0x69, 0x6a,
-0x65, 0x3b, 0x42, 0x72, 0xe1, 0x10d, 0x65, 0x74, 0x3b, 0x48, 0x65, 0x69, 0x77, 0x65, 0x74, 0x3b, 0xd6, 0x69, 0x67, 0x161,
-0x74, 0x65, 0x3b, 0x48, 0x65, 0x72, 0x62, 0x161, 0x74, 0x6d, 0xe1, 0x6e, 0x65, 0x74, 0x3b, 0x57, 0xed, 0x6d, 0xe1, 0x6e,
-0x65, 0x74, 0x3b, 0x57, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6d, 0xe1, 0x6e, 0x65, 0x74, 0x3b, 0x43, 0x68, 0x72, 0x69, 0x161,
-0x74, 0x6d, 0xe1, 0x6e, 0x65, 0x74, 0x3b, 0x4a, 0x3b, 0x48, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x42, 0x3b, 0x48,
-0x3b, 0xd6, 0x3b, 0x48, 0x3b, 0x57, 0x3b, 0x57, 0x3b, 0x43, 0x3b, 0x6f, 0x2e, 0x31, 0x3b, 0x6f, 0x2e, 0x32, 0x3b, 0x6f,
-0x2e, 0x33, 0x3b, 0x6f, 0x2e, 0x34, 0x3b, 0x6f, 0x2e, 0x35, 0x3b, 0x6f, 0x2e, 0x36, 0x3b, 0x6f, 0x2e, 0x37, 0x3b, 0x6f,
-0x2e, 0x38, 0x3b, 0x6f, 0x2e, 0x39, 0x3b, 0x6f, 0x2e, 0x31, 0x30, 0x3b, 0x6f, 0x2e, 0x31, 0x31, 0x3b, 0x6f, 0x2e, 0x31,
-0x32, 0x3b, 0x70, 0x69, 0x6b, 0xed, 0x74, 0xed, 0x6b, 0xed, 0x74, 0x69, 0x65, 0x2c, 0x20, 0x6f, 0xf3, 0x6c, 0xed, 0x20,
-0xfa, 0x20, 0x6b, 0x75, 0x74, 0xfa, 0x61, 0x6e, 0x3b, 0x73, 0x69, 0x25b, 0x79, 0x25b, 0x301, 0x2c, 0x20, 0x6f, 0xf3, 0x6c,
-0x69, 0x20, 0xfa, 0x20, 0x6b, 0xe1, 0x6e, 0x64, 0xed, 0x25b, 0x3b, 0x254, 0x6e, 0x73, 0xfa, 0x6d, 0x62, 0x254, 0x6c, 0x2c,
-0x20, 0x6f, 0xf3, 0x6c, 0x69, 0x20, 0xfa, 0x20, 0x6b, 0xe1, 0x74, 0xe1, 0x74, 0xfa, 0x25b, 0x3b, 0x6d, 0x65, 0x73, 0x69,
-0x14b, 0x2c, 0x20, 0x6f, 0xf3, 0x6c, 0x69, 0x20, 0xfa, 0x20, 0x6b, 0xe9, 0x6e, 0x69, 0x65, 0x3b, 0x65, 0x6e, 0x73, 0x69,
-0x6c, 0x2c, 0x20, 0x6f, 0xf3, 0x6c, 0x69, 0x20, 0xfa, 0x20, 0x6b, 0xe1, 0x74, 0xe1, 0x6e, 0x75, 0x25b, 0x3b, 0x254, 0x73,
-0x254, 0x6e, 0x3b, 0x65, 0x66, 0x75, 0x74, 0x65, 0x3b, 0x70, 0x69, 0x73, 0x75, 0x79, 0xfa, 0x3b, 0x69, 0x6d, 0x25b, 0x14b,
-0x20, 0x69, 0x20, 0x70, 0x75, 0x254, 0x73, 0x3b, 0x69, 0x6d, 0x25b, 0x14b, 0x20, 0x69, 0x20, 0x70, 0x75, 0x74, 0xfa, 0x6b,
-0x2c, 0x6f, 0xf3, 0x6c, 0x69, 0x20, 0xfa, 0x20, 0x6b, 0xe1, 0x74, 0xed, 0x25b, 0x3b, 0x6d, 0x61, 0x6b, 0x61, 0x6e, 0x64,
-0x69, 0x6b, 0x25b, 0x3b, 0x70, 0x69, 0x6c, 0x254, 0x6e, 0x64, 0x254, 0x301, 0x3b, 0x58, 0x69, 0x6e, 0x3b, 0x46, 0x65, 0x62,
-0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x58, 0x75, 0x6e, 0x3b, 0x58, 0x6e, 0x74,
-0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x63, 0x68, 0x3b, 0x50, 0x61, 0x79, 0x3b, 0x41, 0x76, 0x69,
-0x3b, 0x78, 0x69, 0x6e, 0x65, 0x72, 0x75, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x65, 0x72, 0x75, 0x3b, 0x6d, 0x61, 0x72, 0x7a,
-0x75, 0x3b, 0x61, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x79, 0x75, 0x3b, 0x78, 0x75, 0x6e, 0x75, 0x3b, 0x78, 0x75,
-0x6e, 0x65, 0x74, 0x75, 0x3b, 0x61, 0x67, 0x6f, 0x73, 0x74, 0x75, 0x3b, 0x73, 0x65, 0x74, 0x69, 0x65, 0x6d, 0x62, 0x72,
-0x65, 0x3b, 0x6f, 0x63, 0x68, 0x6f, 0x62, 0x72, 0x65, 0x3b, 0x70, 0x61, 0x79, 0x61, 0x72, 0x65, 0x73, 0x3b, 0x61, 0x76,
-0x69, 0x65, 0x6e, 0x74, 0x75, 0x3b, 0x58, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x58, 0x3b, 0x58, 0x3b,
-0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x50, 0x3b, 0x41, 0x3b, 0x78, 0x69, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61,
-0x72, 0x3b, 0x61, 0x62, 0x72, 0x3b, 0x6d, 0x61, 0x79, 0x3b, 0x78, 0x75, 0x6e, 0x3b, 0x78, 0x6e, 0x74, 0x3b, 0x61, 0x67,
-0x6f, 0x3b, 0x73, 0x65, 0x74, 0x3b, 0x6f, 0x63, 0x68, 0x3b, 0x70, 0x61, 0x79, 0x3b, 0x61, 0x76, 0x69, 0x3b, 0x64, 0x65,
-0x20, 0x78, 0x69, 0x6e, 0x65, 0x72, 0x75, 0x3b, 0x64, 0x65, 0x20, 0x66, 0x65, 0x62, 0x72, 0x65, 0x72, 0x75, 0x3b, 0x64,
-0x65, 0x20, 0x6d, 0x61, 0x72, 0x7a, 0x75, 0x3b, 0x64, 0x27, 0x61, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x64, 0x65, 0x20, 0x6d,
-0x61, 0x79, 0x75, 0x3b, 0x64, 0x65, 0x20, 0x78, 0x75, 0x6e, 0x75, 0x3b, 0x64, 0x65, 0x20, 0x78, 0x75, 0x6e, 0x65, 0x74,
-0x75, 0x3b, 0x64, 0x27, 0x61, 0x67, 0x6f, 0x73, 0x74, 0x75, 0x3b, 0x64, 0x65, 0x20, 0x73, 0x65, 0x74, 0x69, 0x65, 0x6d,
-0x62, 0x72, 0x65, 0x3b, 0x64, 0x27, 0x6f, 0x63, 0x68, 0x6f, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x65, 0x20, 0x70, 0x61, 0x79,
-0x61, 0x72, 0x65, 0x73, 0x3b, 0x64, 0x27, 0x61, 0x76, 0x69, 0x65, 0x6e, 0x74, 0x75, 0x3b, 0x4e, 0x64, 0x75, 0x14b, 0x6d,
-0x62, 0x69, 0x20, 0x53, 0x61, 0x14b, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x50, 0x25b, 0x301, 0x70, 0xe1, 0x3b, 0x50,
-0x25b, 0x73, 0x61, 0x14b, 0x20, 0x50, 0x25b, 0x301, 0x74, 0xe1, 0x74, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x50, 0x25b,
-0x301, 0x6e, 0x25b, 0x301, 0x6b, 0x77, 0x61, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x50, 0x61, 0x74, 0x61, 0x61, 0x3b,
-0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x50, 0x25b, 0x301, 0x6e, 0x25b, 0x301, 0x6e, 0x74, 0xfa, 0x6b, 0xfa, 0x3b, 0x50, 0x25b,
-0x73, 0x61, 0x14b, 0x20, 0x53, 0x61, 0x61, 0x6d, 0x62, 0xe1, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x50, 0x25b, 0x301,
-0x6e, 0x25b, 0x301, 0x66, 0x254, 0x6d, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x50, 0x25b, 0x301, 0x6e, 0x25b, 0x301, 0x70,
-0x66, 0xfa, 0xa78b, 0xfa, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x4e, 0x25b, 0x67, 0x25b, 0x301, 0x6d, 0x3b, 0x50, 0x25b,
-0x73, 0x61, 0x14b, 0x20, 0x4e, 0x74, 0x73, 0x254, 0x30c, 0x70, 0x6d, 0x254, 0x301, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20,
-0x4e, 0x74, 0x73, 0x254, 0x30c, 0x70, 0x70, 0xe1, 0x3b, 0x70, 0x61, 0x6d, 0x62, 0x61, 0x3b, 0x77, 0x61, 0x6e, 0x6a, 0x61,
-0x3b, 0x6d, 0x62, 0x69, 0x79, 0x254, 0x20, 0x6d, 0x25b, 0x6e, 0x64, 0x6f, 0x14b, 0x67, 0x254, 0x3b, 0x4e, 0x79, 0x254, 0x6c,
-0x254, 0x6d, 0x62, 0x254, 0x14b, 0x67, 0x254, 0x3b, 0x4d, 0x254, 0x6e, 0x254, 0x20, 0x14b, 0x67, 0x62, 0x61, 0x6e, 0x6a, 0x61,
-0x3b, 0x4e, 0x79, 0x61, 0x14b, 0x67, 0x77, 0x25b, 0x20, 0x14b, 0x67, 0x62, 0x61, 0x6e, 0x6a, 0x61, 0x3b, 0x6b, 0x75, 0x14b,
-0x67, 0x77, 0x25b, 0x3b, 0x66, 0x25b, 0x3b, 0x6e, 0x6a, 0x61, 0x70, 0x69, 0x3b, 0x6e, 0x79, 0x75, 0x6b, 0x75, 0x6c, 0x3b,
-0x31, 0x31, 0x3b, 0x253, 0x75, 0x6c, 0x253, 0x75, 0x73, 0x25b, 0x3b, 0x6d, 0x62, 0x65, 0x67, 0x74, 0x75, 0x67, 0x3b, 0x69,
-0x6d, 0x65, 0x67, 0x20, 0xe0, 0x62, 0xf9, 0x62, 0xec, 0x3b, 0x69, 0x6d, 0x65, 0x67, 0x20, 0x6d, 0x62, 0x259, 0x14b, 0x63,
-0x68, 0x75, 0x62, 0x69, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x6e, 0x67, 0x77, 0x259, 0x300, 0x74, 0x3b, 0x69, 0x6d, 0x259,
-0x67, 0x20, 0x66, 0x6f, 0x67, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x69, 0x63, 0x68, 0x69, 0x69, 0x62, 0x254, 0x64, 0x3b,
-0x69, 0x6d, 0x259, 0x67, 0x20, 0xe0, 0x64, 0xf9, 0x6d, 0x62, 0x259, 0x300, 0x14b, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x69,
-0x63, 0x68, 0x69, 0x6b, 0x61, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x6b, 0x75, 0x64, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20,
-0x74, 0xe8, 0x73, 0x69, 0x2bc, 0x65, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x7a, 0xf2, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20,
-0x6b, 0x72, 0x69, 0x7a, 0x6d, 0x65, 0x64, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x6d, 0x62, 0x65, 0x67, 0x74, 0x75, 0x67,
-0x3b, 0x69, 0x6d, 0x65, 0x67, 0x20, 0xe0, 0x62, 0xf9, 0x62, 0xec, 0x3b, 0x69, 0x6d, 0x65, 0x67, 0x20, 0x6d, 0x62, 0x259,
-0x14b, 0x63, 0x68, 0x75, 0x62, 0x69, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x6e, 0x67, 0x77, 0x259, 0x300, 0x74, 0x3b, 0x69,
-0x6d, 0x259, 0x67, 0x20, 0x66, 0x6f, 0x67, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x69, 0x63, 0x68, 0x69, 0x69, 0x62, 0x254,
-0x64, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0xe0, 0x64, 0xf9, 0x6d, 0x62, 0x259, 0x300, 0x14b, 0x3b, 0x69, 0x6d, 0x259, 0x67,
-0x20, 0x69, 0x63, 0x68, 0x69, 0x6b, 0x61, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x6b, 0x75, 0x64, 0x3b, 0x69, 0x6d, 0x259,
-0x67, 0x20, 0x74, 0xe8, 0x73, 0x69, 0x2bc, 0x65, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x7a, 0xf2, 0x3b, 0x69, 0x6d, 0x259,
-0x67, 0x20, 0x6b, 0x72, 0x69, 0x7a, 0x6d, 0x65, 0x64, 0x3b, 0x4d, 0x31, 0x3b, 0x41, 0x32, 0x3b, 0x4d, 0x33, 0x3b, 0x4e,
-0x34, 0x3b, 0x46, 0x35, 0x3b, 0x49, 0x36, 0x3b, 0x41, 0x37, 0x3b, 0x49, 0x38, 0x3b, 0x4b, 0x39, 0x3b, 0x31, 0x30, 0x3b,
-0x31, 0x31, 0x3b, 0x31, 0x32, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x74, 0x73, 0x65, 0x74, 0x73, 0x25b, 0x300, 0x25b, 0x20, 0x6c,
-0xf9, 0x6d, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x6b, 0xe0, 0x67, 0x20, 0x6e, 0x67, 0x77, 0xf3, 0x14b, 0x3b, 0x73, 0x61, 0x14b,
-0x20, 0x6c, 0x65, 0x70, 0x79, 0xe8, 0x20, 0x73, 0x68, 0xfa, 0x6d, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x63, 0xff, 0xf3, 0x3b,
-0x73, 0x61, 0x14b, 0x20, 0x74, 0x73, 0x25b, 0x300, 0x25b, 0x20, 0x63, 0xff, 0xf3, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x6e, 0x6a,
-0xff, 0x6f, 0x6c, 0xe1, 0x2bc, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x74, 0x79, 0x25b, 0x300, 0x62, 0x20, 0x74, 0x79, 0x25b, 0x300,
-0x62, 0x20, 0x6d, 0x62, 0x289, 0x300, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x6d, 0x62, 0x289, 0x300, 0x14b, 0x3b, 0x73, 0x61, 0x14b,
-0x20, 0x6e, 0x67, 0x77, 0x254, 0x300, 0x2bc, 0x20, 0x6d, 0x62, 0xff, 0x25b, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x74, 0xe0, 0x14b,
-0x61, 0x20, 0x74, 0x73, 0x65, 0x74, 0x73, 0xe1, 0x2bc, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x6d, 0x65, 0x6a, 0x77, 0x6f, 0x14b,
-0xf3, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x6c, 0xf9, 0x6d, 0x3b
+0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x4d, 0x3b, 0x46, 0xfa, 0x6e, 0x67, 0x61, 0x74, 0x268, 0x3b, 0x4e,
+0x61, 0x61, 0x6e, 0x268, 0x3b, 0x4b, 0x65, 0x65, 0x6e, 0x64, 0x61, 0x3b, 0x49, 0x6b, 0xfa, 0x6d, 0x69, 0x3b, 0x49, 0x6e,
+0x79, 0x61, 0x6d, 0x62, 0x61, 0x6c, 0x61, 0x3b, 0x49, 0x64, 0x77, 0x61, 0x61, 0x74, 0x61, 0x3b, 0x4d, 0x289, 0x289, 0x6e,
+0x63, 0x68, 0x268, 0x3b, 0x56, 0x268, 0x268, 0x72, 0x268, 0x3b, 0x53, 0x61, 0x61, 0x74, 0x289, 0x3b, 0x49, 0x6e, 0x79, 0x69,
+0x3b, 0x53, 0x61, 0x61, 0x6e, 0x6f, 0x3b, 0x53, 0x61, 0x73, 0x61, 0x74, 0x289, 0x3b, 0x4b, 0x289, 0x66, 0xfa, 0x6e, 0x67,
+0x61, 0x74, 0x268, 0x3b, 0x4b, 0x289, 0x6e, 0x61, 0x61, 0x6e, 0x268, 0x3b, 0x4b, 0x289, 0x6b, 0x65, 0x65, 0x6e, 0x64, 0x61,
+0x3b, 0x4b, 0x77, 0x69, 0x69, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x4b, 0x77, 0x69, 0x69, 0x6e, 0x79, 0x61, 0x6d, 0x62, 0xe1,
+0x6c, 0x61, 0x3b, 0x4b, 0x77, 0x69, 0x69, 0x64, 0x77, 0x61, 0x61, 0x74, 0x61, 0x3b, 0x4b, 0x289, 0x6d, 0x289, 0x289, 0x6e,
+0x63, 0x68, 0x268, 0x3b, 0x4b, 0x289, 0x76, 0x268, 0x268, 0x72, 0x268, 0x3b, 0x4b, 0x289, 0x73, 0x61, 0x61, 0x74, 0x289, 0x3b,
+0x4b, 0x77, 0x69, 0x69, 0x6e, 0x79, 0x69, 0x3b, 0x4b, 0x289, 0x73, 0x61, 0x61, 0x6e, 0x6f, 0x3b, 0x4b, 0x289, 0x73, 0x61,
+0x73, 0x61, 0x74, 0x289, 0x3b, 0x46, 0x3b, 0x4e, 0x3b, 0x4b, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x4d, 0x3b, 0x56,
+0x3b, 0x53, 0x3b, 0x49, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72,
+0x3b, 0x41, 0x70, 0x75, 0x3b, 0x4d, 0x61, 0x61, 0x3b, 0x4a, 0x75, 0x75, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x75,
+0x3b, 0x53, 0x65, 0x62, 0x3b, 0x4f, 0x6b, 0x69, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x73, 0x3b, 0x4a, 0x61, 0x6e,
+0x77, 0x61, 0x6c, 0x69, 0x79, 0x6f, 0x3b, 0x46, 0x65, 0x62, 0x77, 0x61, 0x6c, 0x69, 0x79, 0x6f, 0x3b, 0x4d, 0x61, 0x72,
+0x69, 0x73, 0x69, 0x3b, 0x41, 0x70, 0x75, 0x6c, 0x69, 0x3b, 0x4d, 0x61, 0x61, 0x79, 0x69, 0x3b, 0x4a, 0x75, 0x75, 0x6e,
+0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x61, 0x79, 0x69, 0x3b, 0x41, 0x67, 0x75, 0x73, 0x69, 0x74, 0x6f, 0x3b, 0x53, 0x65,
+0x62, 0x75, 0x74, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x69, 0x74, 0x6f, 0x62, 0x62, 0x61, 0x3b, 0x4e, 0x6f,
+0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65,
+0x62, 0x3b, 0x4d, 0x61, 0x63, 0x3b, 0x45, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75,
+0x6c, 0x3b, 0x4f, 0x67, 0x61, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x69,
+0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x46, 0x65, 0x62, 0x72, 0x75, 0x61, 0x72, 0x69, 0x3b, 0x4d,
+0x61, 0x63, 0x68, 0x69, 0x3b, 0x45, 0x70, 0x72, 0x65, 0x6f, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b,
+0x4a, 0x75, 0x6c, 0x61, 0x69, 0x3b, 0x4f, 0x67, 0x61, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62,
+0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x69, 0x73,
+0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4a, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x45, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x4f,
+0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x76, 0x3b, 0x4d, 0x61, 0x72,
+0x3b, 0x41, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f,
+0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x74, 0x75, 0x3b, 0x4e, 0x75, 0x76, 0x3b, 0x44, 0x69, 0x7a, 0x3b, 0x4a, 0x61, 0x6e,
+0x65, 0x72, 0x75, 0x3b, 0x46, 0x65, 0x76, 0x65, 0x72, 0x65, 0x72, 0x75, 0x3b, 0x4d, 0x61, 0x72, 0x73, 0x75, 0x3b, 0x41,
+0x62, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x61, 0x69, 0x75, 0x3b, 0x4a, 0x75, 0x6e, 0x68, 0x75, 0x3b, 0x4a, 0x75, 0x6c, 0x68,
+0x75, 0x3b, 0x41, 0x67, 0x6f, 0x73, 0x74, 0x75, 0x3b, 0x53, 0x65, 0x74, 0x65, 0x6e, 0x62, 0x72, 0x75, 0x3b, 0x4f, 0x74,
+0x75, 0x62, 0x72, 0x75, 0x3b, 0x4e, 0x75, 0x76, 0x65, 0x6e, 0x62, 0x72, 0x75, 0x3b, 0x44, 0x69, 0x7a, 0x65, 0x6e, 0x62,
+0x72, 0x75, 0x3b, 0x4a, 0x41, 0x4e, 0x3b, 0x46, 0x45, 0x42, 0x3b, 0x4d, 0x41, 0x43, 0x3b, 0x128, 0x50, 0x55, 0x3b, 0x4d,
+0x128, 0x128, 0x3b, 0x4e, 0x4a, 0x55, 0x3b, 0x4e, 0x4a, 0x52, 0x3b, 0x41, 0x47, 0x41, 0x3b, 0x53, 0x50, 0x54, 0x3b, 0x4f,
+0x4b, 0x54, 0x3b, 0x4e, 0x4f, 0x56, 0x3b, 0x44, 0x45, 0x43, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61, 0x72, 0x129, 0x3b, 0x46,
+0x65, 0x62, 0x75, 0x72, 0x75, 0x61, 0x72, 0x129, 0x3b, 0x4d, 0x61, 0x63, 0x68, 0x69, 0x3b, 0x128, 0x70, 0x75, 0x72, 0x169,
+0x3b, 0x4d, 0x129, 0x129, 0x3b, 0x4e, 0x6a, 0x75, 0x6e, 0x69, 0x3b, 0x4e, 0x6a, 0x75, 0x72, 0x61, 0x129, 0x3b, 0x41, 0x67,
+0x61, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x169, 0x62, 0x61,
+0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x69, 0x63, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4a, 0x3b, 0x46,
+0x3b, 0x4d, 0x3b, 0x128, 0x3b, 0x4d, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44,
+0x3b, 0x4d, 0x75, 0x6c, 0x3b, 0x4e, 0x67, 0x61, 0x3b, 0x4b, 0x69, 0x70, 0x3b, 0x49, 0x77, 0x61, 0x3b, 0x4e, 0x67, 0x65,
+0x3b, 0x57, 0x61, 0x6b, 0x3b, 0x52, 0x6f, 0x70, 0x3b, 0x4b, 0x6f, 0x67, 0x3b, 0x42, 0x75, 0x72, 0x3b, 0x45, 0x70, 0x65,
+0x3b, 0x54, 0x61, 0x69, 0x3b, 0x41, 0x65, 0x6e, 0x3b, 0x4d, 0x75, 0x6c, 0x67, 0x75, 0x6c, 0x3b, 0x4e, 0x67, 0x27, 0x61,
+0x74, 0x79, 0x61, 0x74, 0x6f, 0x3b, 0x4b, 0x69, 0x70, 0x74, 0x61, 0x6d, 0x6f, 0x3b, 0x49, 0x77, 0x61, 0x74, 0x20, 0x6b,
+0x75, 0x74, 0x3b, 0x4e, 0x67, 0x27, 0x65, 0x69, 0x79, 0x65, 0x74, 0x3b, 0x57, 0x61, 0x6b, 0x69, 0x3b, 0x52, 0x6f, 0x70,
+0x74, 0x75, 0x69, 0x3b, 0x4b, 0x69, 0x70, 0x6b, 0x6f, 0x67, 0x61, 0x67, 0x61, 0x3b, 0x42, 0x75, 0x72, 0x65, 0x74, 0x3b,
+0x45, 0x70, 0x65, 0x73, 0x6f, 0x3b, 0x4b, 0x69, 0x70, 0x73, 0x75, 0x6e, 0x64, 0x65, 0x20, 0x6e, 0x65, 0x74, 0x61, 0x69,
+0x3b, 0x4b, 0x69, 0x70, 0x73, 0x75, 0x6e, 0x64, 0x65, 0x20, 0x6e, 0x65, 0x62, 0x6f, 0x20, 0x61, 0x65, 0x6e, 0x67, 0x3b,
+0x4d, 0x3b, 0x4e, 0x3b, 0x4b, 0x3b, 0x49, 0x3b, 0x4e, 0x3b, 0x57, 0x3b, 0x52, 0x3b, 0x4b, 0x3b, 0x42, 0x3b, 0x45, 0x3b,
+0x4b, 0x3b, 0x4b, 0x3b, 0x1c3, 0x4b, 0x68, 0x61, 0x6e, 0x6e, 0x69, 0x3b, 0x1c3, 0x4b, 0x68, 0x61, 0x6e, 0x1c0, 0x67, 0xf4,
+0x61, 0x62, 0x3b, 0x1c0, 0x4b, 0x68, 0x75, 0x75, 0x1c1, 0x6b, 0x68, 0xe2, 0x62, 0x3b, 0x1c3, 0x48, 0xf4, 0x61, 0x1c2, 0x6b,
+0x68, 0x61, 0x69, 0x62, 0x3b, 0x1c3, 0x4b, 0x68, 0x61, 0x69, 0x74, 0x73, 0xe2, 0x62, 0x3b, 0x47, 0x61, 0x6d, 0x61, 0x1c0,
+0x61, 0x65, 0x62, 0x3b, 0x1c2, 0x4b, 0x68, 0x6f, 0x65, 0x73, 0x61, 0x6f, 0x62, 0x3b, 0x41, 0x6f, 0x1c1, 0x6b, 0x68, 0x75,
+0x75, 0x6d, 0xfb, 0x1c1, 0x6b, 0x68, 0xe2, 0x62, 0x3b, 0x54, 0x61, 0x72, 0x61, 0x1c0, 0x6b, 0x68, 0x75, 0x75, 0x6d, 0xfb,
+0x1c1, 0x6b, 0x68, 0xe2, 0x62, 0x3b, 0x1c2, 0x4e, 0xfb, 0x1c1, 0x6e, 0xe2, 0x69, 0x73, 0x65, 0x62, 0x3b, 0x1c0, 0x48, 0x6f,
+0x6f, 0x1c2, 0x67, 0x61, 0x65, 0x62, 0x3b, 0x48, 0xf4, 0x61, 0x73, 0x6f, 0x72, 0x65, 0x1c1, 0x6b, 0x68, 0xe2, 0x62, 0x3b,
+0x4a, 0x61, 0x6e, 0x2e, 0x3b, 0x46, 0xe4, 0x62, 0x2e, 0x3b, 0x4d, 0xe4, 0x7a, 0x2e, 0x3b, 0x41, 0x70, 0x72, 0x2e, 0x3b,
+0x4d, 0xe4, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x2e, 0x3b, 0x4a, 0x75, 0x6c, 0x2e, 0x3b, 0x4f, 0x75, 0x6a, 0x2e, 0x3b, 0x53,
+0xe4, 0x70, 0x2e, 0x3b, 0x4f, 0x6b, 0x74, 0x2e, 0x3b, 0x4e, 0x6f, 0x76, 0x2e, 0x3b, 0x44, 0x65, 0x7a, 0x2e, 0x3b, 0x4a,
+0x61, 0x6e, 0x6e, 0x65, 0x77, 0x61, 0x3b, 0x46, 0xe4, 0x62, 0x72, 0x6f, 0x77, 0x61, 0x3b, 0x4d, 0xe4, 0xe4, 0x7a, 0x3b,
+0x41, 0x70, 0x72, 0x65, 0x6c, 0x6c, 0x3b, 0x4d, 0xe4, 0x69, 0x3b, 0x4a, 0x75, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x75,
+0x6c, 0x69, 0x3b, 0x4f, 0x75, 0x6a, 0x6f, 0xdf, 0x3b, 0x53, 0x65, 0x70, 0x74, 0xe4, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4f,
+0x6b, 0x74, 0x6f, 0x6f, 0x62, 0x65, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0xe4, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x44, 0x65, 0x7a,
+0xe4, 0x6d, 0x62, 0x65, 0x72, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0xe4, 0x62, 0x3b, 0x4d, 0xe4, 0x7a, 0x3b, 0x41, 0x70,
+0x72, 0x3b, 0x4d, 0xe4, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x4f, 0x75, 0x6a, 0x3b, 0x53, 0xe4,
+0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x7a, 0x3b, 0x44, 0x61, 0x6c, 0x3b, 0x41, 0x72,
+0xe1, 0x3b, 0x186, 0x25b, 0x6e, 0x3b, 0x44, 0x6f, 0x79, 0x3b, 0x4c, 0xe9, 0x70, 0x3b, 0x52, 0x6f, 0x6b, 0x3b, 0x53, 0xe1,
+0x73, 0x3b, 0x42, 0x254, 0x301, 0x72, 0x3b, 0x4b, 0xfa, 0x73, 0x3b, 0x47, 0xed, 0x73, 0x3b, 0x53, 0x68, 0x289, 0x301, 0x3b,
+0x4e, 0x74, 0x289, 0x301, 0x3b, 0x4f, 0x6c, 0x61, 0x64, 0x61, 0x6c, 0x289, 0x301, 0x3b, 0x41, 0x72, 0xe1, 0x74, 0x3b, 0x186,
+0x25b, 0x6e, 0x268, 0x301, 0x254, 0x268, 0x14b, 0x254, 0x6b, 0x3b, 0x4f, 0x6c, 0x6f, 0x64, 0x6f, 0x79, 0xed, 0xf3, 0x72, 0xed,
+0xea, 0x20, 0x69, 0x6e, 0x6b, 0xf3, 0x6b, 0xfa, 0xe2, 0x3b, 0x4f, 0x6c, 0x6f, 0x69, 0x6c, 0xe9, 0x70, 0x16b, 0x6e, 0x79,
+0x12b, 0x113, 0x20, 0x69, 0x6e, 0x6b, 0xf3, 0x6b, 0xfa, 0xe2, 0x3b, 0x4b, 0xfa, 0x6a, 0xfa, 0x254, 0x72, 0x254, 0x6b, 0x3b,
+0x4d, 0xf3, 0x72, 0x75, 0x73, 0xe1, 0x73, 0x69, 0x6e, 0x3b, 0x186, 0x6c, 0x254, 0x301, 0x268, 0x301, 0x62, 0x254, 0x301, 0x72,
+0xe1, 0x72, 0x25b, 0x3b, 0x4b, 0xfa, 0x73, 0x68, 0xee, 0x6e, 0x3b, 0x4f, 0x6c, 0x67, 0xed, 0x73, 0x61, 0x6e, 0x3b, 0x50,
+0x289, 0x73, 0x68, 0x289, 0x301, 0x6b, 0x61, 0x3b, 0x4e, 0x74, 0x289, 0x301, 0x14b, 0x289, 0x301, 0x73, 0x3b, 0x4a, 0x61, 0x6e,
+0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x70, 0x72, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e,
+0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x70, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76,
+0x3b, 0x44, 0x65, 0x73, 0x3b, 0x4a, 0x61, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x63, 0x3b, 0x41, 0x70, 0x72,
+0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x3b, 0x4a, 0x75, 0x6c, 0x3b, 0x41, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x70,
+0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x76, 0x3b, 0x44, 0x65, 0x63, 0x3b, 0x52, 0x61, 0x72, 0x3b, 0x4d, 0x75, 0x6b,
+0x3b, 0x4b, 0x77, 0x61, 0x3b, 0x44, 0x75, 0x6e, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x4d, 0x6f, 0x64, 0x3b, 0x4a, 0x6f, 0x6c,
+0x3b, 0x50, 0x65, 0x64, 0x3b, 0x53, 0x6f, 0x6b, 0x3b, 0x54, 0x69, 0x62, 0x3b, 0x4c, 0x61, 0x62, 0x3b, 0x50, 0x6f, 0x6f,
+0x3b, 0x4f, 0x72, 0x61, 0x72, 0x61, 0x3b, 0x4f, 0x6d, 0x75, 0x6b, 0x3b, 0x4f, 0x6b, 0x77, 0x61, 0x6d, 0x67, 0x27, 0x3b,
+0x4f, 0x64, 0x75, 0x6e, 0x67, 0x27, 0x65, 0x6c, 0x3b, 0x4f, 0x6d, 0x61, 0x72, 0x75, 0x6b, 0x3b, 0x4f, 0x6d, 0x6f, 0x64,
+0x6f, 0x6b, 0x27, 0x6b, 0x69, 0x6e, 0x67, 0x27, 0x6f, 0x6c, 0x3b, 0x4f, 0x6a, 0x6f, 0x6c, 0x61, 0x3b, 0x4f, 0x70, 0x65,
+0x64, 0x65, 0x6c, 0x3b, 0x4f, 0x73, 0x6f, 0x6b, 0x6f, 0x73, 0x6f, 0x6b, 0x6f, 0x6d, 0x61, 0x3b, 0x4f, 0x74, 0x69, 0x62,
+0x61, 0x72, 0x3b, 0x4f, 0x6c, 0x61, 0x62, 0x6f, 0x72, 0x3b, 0x4f, 0x70, 0x6f, 0x6f, 0x3b, 0x52, 0x3b, 0x4d, 0x3b, 0x4b,
+0x3b, 0x44, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x50, 0x3b, 0x53, 0x3b, 0x54, 0x3b, 0x4c, 0x3b, 0x50, 0x3b, 0x17d,
+0x61, 0x6e, 0x3b, 0x46, 0x65, 0x65, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x41, 0x77, 0x69, 0x3b, 0x4d, 0x65, 0x3b, 0x17d, 0x75,
+0x77, 0x3b, 0x17d, 0x75, 0x79, 0x3b, 0x55, 0x74, 0x3b, 0x53, 0x65, 0x6b, 0x3b, 0x4f, 0x6b, 0x74, 0x3b, 0x4e, 0x6f, 0x6f,
+0x3b, 0x44, 0x65, 0x65, 0x3b, 0x17d, 0x61, 0x6e, 0x77, 0x69, 0x79, 0x65, 0x3b, 0x46, 0x65, 0x65, 0x77, 0x69, 0x72, 0x69,
+0x79, 0x65, 0x3b, 0x4d, 0x61, 0x72, 0x73, 0x69, 0x3b, 0x41, 0x77, 0x69, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x65, 0x3b, 0x17d,
+0x75, 0x77, 0x65, 0x14b, 0x3b, 0x17d, 0x75, 0x79, 0x79, 0x65, 0x3b, 0x55, 0x74, 0x3b, 0x53, 0x65, 0x6b, 0x74, 0x61, 0x6e,
+0x62, 0x75, 0x72, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x6f, 0x62, 0x75, 0x72, 0x3b, 0x4e, 0x6f, 0x6f, 0x77, 0x61, 0x6e, 0x62,
+0x75, 0x72, 0x3b, 0x44, 0x65, 0x65, 0x73, 0x61, 0x6e, 0x62, 0x75, 0x72, 0x3b, 0x17d, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41,
+0x3b, 0x4d, 0x3b, 0x17d, 0x3b, 0x17d, 0x3b, 0x55, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x44, 0x41, 0x43,
+0x3b, 0x44, 0x41, 0x52, 0x3b, 0x44, 0x41, 0x44, 0x3b, 0x44, 0x41, 0x4e, 0x3b, 0x44, 0x41, 0x48, 0x3b, 0x44, 0x41, 0x55,
+0x3b, 0x44, 0x41, 0x4f, 0x3b, 0x44, 0x41, 0x42, 0x3b, 0x44, 0x4f, 0x43, 0x3b, 0x44, 0x41, 0x50, 0x3b, 0x44, 0x47, 0x49,
+0x3b, 0x44, 0x41, 0x47, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x63, 0x68, 0x69, 0x65, 0x6c, 0x3b,
+0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x72, 0x69, 0x79, 0x6f, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61,
+0x72, 0x20, 0x41, 0x64, 0x65, 0x6b, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x6e, 0x67, 0x27, 0x77,
+0x65, 0x6e, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x62, 0x69, 0x63, 0x68, 0x3b, 0x44, 0x77, 0x65,
+0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x75, 0x63, 0x68, 0x69, 0x65, 0x6c, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72,
+0x20, 0x41, 0x62, 0x69, 0x72, 0x69, 0x79, 0x6f, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x62, 0x6f,
+0x72, 0x6f, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x4f, 0x63, 0x68, 0x69, 0x6b, 0x6f, 0x3b, 0x44, 0x77,
+0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x70, 0x61, 0x72, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x67,
+0x69, 0x20, 0x61, 0x63, 0x68, 0x69, 0x65, 0x6c, 0x3b, 0x44, 0x77, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x41, 0x70, 0x61,
+0x72, 0x20, 0x67, 0x69, 0x20, 0x61, 0x72, 0x69, 0x79, 0x6f, 0x3b, 0x43, 0x3b, 0x52, 0x3b, 0x44, 0x3b, 0x4e, 0x3b, 0x42,
+0x3b, 0x55, 0x3b, 0x42, 0x3b, 0x42, 0x3b, 0x43, 0x3b, 0x50, 0x3b, 0x43, 0x3b, 0x50, 0x3b, 0x59, 0x65, 0x6e, 0x3b, 0x59,
+0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x49, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x59, 0x75, 0x6e, 0x3b, 0x59,
+0x75, 0x6c, 0x3b, 0x194, 0x75, 0x63, 0x3b, 0x43, 0x75, 0x74, 0x3b, 0x4b, 0x1e6d, 0x75, 0x3b, 0x4e, 0x77, 0x61, 0x3b, 0x44,
+0x75, 0x6a, 0x3b, 0x59, 0x65, 0x6e, 0x6e, 0x61, 0x79, 0x65, 0x72, 0x3b, 0x59, 0x65, 0x62, 0x72, 0x61, 0x79, 0x65, 0x72,
+0x3b, 0x4d, 0x61, 0x72, 0x73, 0x3b, 0x49, 0x62, 0x72, 0x69, 0x72, 0x3b, 0x4d, 0x61, 0x79, 0x79, 0x75, 0x3b, 0x59, 0x75,
+0x6e, 0x79, 0x75, 0x3b, 0x59, 0x75, 0x6c, 0x79, 0x75, 0x7a, 0x3b, 0x194, 0x75, 0x63, 0x74, 0x3b, 0x43, 0x75, 0x74, 0x61,
+0x6e, 0x62, 0x69, 0x72, 0x3b, 0x4b, 0x1e6d, 0x75, 0x62, 0x65, 0x72, 0x3b, 0x4e, 0x77, 0x61, 0x6e, 0x62, 0x69, 0x72, 0x3b,
+0x44, 0x75, 0x6a, 0x61, 0x6e, 0x62, 0x69, 0x72, 0x3b, 0x59, 0x3b, 0x59, 0x3b, 0x4d, 0x3b, 0x49, 0x3b, 0x4d, 0x3b, 0x59,
+0x3b, 0x59, 0x3b, 0x194, 0x3b, 0x43, 0x3b, 0x4b, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x4a, 0x61, 0x6e, 0x75, 0x61, 0x6c, 0x69,
+0x3b, 0x46, 0x65, 0x62, 0x6c, 0x75, 0x61, 0x6c, 0x69, 0x3b, 0x4d, 0x61, 0x63, 0x68, 0x69, 0x3b, 0x41, 0x70, 0x6c, 0x69,
+0x6c, 0x69, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x4a, 0x75, 0x6e, 0x69, 0x3b, 0x4a, 0x75, 0x6c, 0x61, 0x69, 0x3b, 0x41, 0x67,
+0x6f, 0x73, 0x74, 0x69, 0x3b, 0x53, 0x65, 0x70, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x61,
+0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x44, 0x65, 0x73, 0x65, 0x6d, 0x62, 0x61, 0x3b, 0x91c, 0x93e, 0x928,
+0x941, 0x935, 0x93e, 0x930, 0x940, 0x3b, 0x92b, 0x947, 0x92c, 0x94d, 0x930, 0x941, 0x935, 0x93e, 0x930, 0x940, 0x3b, 0x92e, 0x93e, 0x930,
+0x94d, 0x938, 0x3b, 0x90f, 0x92b, 0x94d, 0x930, 0x93f, 0x932, 0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x941, 0x928, 0x3b, 0x91c, 0x941, 0x932,
+0x93e, 0x907, 0x3b, 0x906, 0x917, 0x938, 0x94d, 0x925, 0x3b, 0x938, 0x947, 0x92c, 0x925, 0x947, 0x91c, 0x94d, 0x92c, 0x93c, 0x930, 0x3b,
+0x905, 0x916, 0x925, 0x92c, 0x930, 0x3b, 0x928, 0x92c, 0x947, 0x91c, 0x94d, 0x92c, 0x93c, 0x930, 0x3b, 0x926, 0x93f, 0x938, 0x947, 0x91c,
+0x94d, 0x92c, 0x93c, 0x930, 0x3b, 0x91c, 0x3b, 0x92b, 0x947, 0x3b, 0x92e, 0x93e, 0x3b, 0x90f, 0x3b, 0x92e, 0x947, 0x3b, 0x91c, 0x941,
+0x3b, 0x91c, 0x941, 0x3b, 0x906, 0x3b, 0x938, 0x947, 0x3b, 0x905, 0x3b, 0x928, 0x3b, 0x926, 0x93f, 0x3b, 0x43, 0x69, 0x6f, 0x3b,
+0x4c, 0x75, 0x69, 0x3b, 0x4c, 0x75, 0x73, 0x3b, 0x4d, 0x75, 0x75, 0x3b, 0x4c, 0x75, 0x6d, 0x3b, 0x4c, 0x75, 0x66, 0x3b,
+0x4b, 0x61, 0x62, 0x3b, 0x4c, 0x75, 0x73, 0x68, 0x3b, 0x4c, 0x75, 0x74, 0x3b, 0x4c, 0x75, 0x6e, 0x3b, 0x4b, 0x61, 0x73,
+0x3b, 0x43, 0x69, 0x73, 0x3b, 0x43, 0x69, 0x6f, 0x6e, 0x67, 0x6f, 0x3b, 0x4c, 0xf9, 0x69, 0x73, 0x68, 0x69, 0x3b, 0x4c,
+0x75, 0x73, 0xf2, 0x6c, 0x6f, 0x3b, 0x4d, 0xf9, 0x75, 0x79, 0xe0, 0x3b, 0x4c, 0x75, 0x6d, 0xf9, 0x6e, 0x67, 0xf9, 0x6c,
+0xf9, 0x3b, 0x4c, 0x75, 0x66, 0x75, 0x69, 0x6d, 0x69, 0x3b, 0x4b, 0x61, 0x62, 0xe0, 0x6c, 0xe0, 0x73, 0x68, 0xec, 0x70,
+0xf9, 0x3b, 0x4c, 0xf9, 0x73, 0x68, 0xec, 0x6b, 0xe0, 0x3b, 0x4c, 0x75, 0x74, 0x6f, 0x6e, 0x67, 0x6f, 0x6c, 0x6f, 0x3b,
+0x4c, 0x75, 0x6e, 0x67, 0xf9, 0x64, 0x69, 0x3b, 0x4b, 0x61, 0x73, 0x77, 0xe8, 0x6b, 0xe8, 0x73, 0xe8, 0x3b, 0x43, 0x69,
+0x73, 0x77, 0xe0, 0x3b, 0x43, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4b, 0x3b, 0x4c, 0x3b,
+0x4c, 0x3b, 0x4c, 0x3b, 0x4b, 0x3b, 0x43, 0x3b, 0x6e, 0xf9, 0x6d, 0x3b, 0x6b, 0x268, 0x7a, 0x3b, 0x74, 0x268, 0x64, 0x3b,
+0x74, 0x61, 0x61, 0x3b, 0x73, 0x65, 0x65, 0x3b, 0x6e, 0x7a, 0x75, 0x3b, 0x64, 0x75, 0x6d, 0x3b, 0x66, 0x254, 0x65, 0x3b,
+0x64, 0x7a, 0x75, 0x3b, 0x6c, 0x254, 0x6d, 0x3b, 0x6b, 0x61, 0x61, 0x3b, 0x66, 0x77, 0x6f, 0x3b, 0x6e, 0x64, 0x7a, 0x254,
+0x300, 0x14b, 0x254, 0x300, 0x6e, 0xf9, 0x6d, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x6b, 0x197, 0x300, 0x7a,
+0xf9, 0x294, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x74, 0x197, 0x300, 0x64, 0x289, 0x300, 0x67, 0x68, 0xe0,
+0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x74, 0x1ce, 0x61, 0x66, 0x289, 0x304, 0x67, 0x68, 0x101, 0x3b, 0x6e,
+0x64, 0x7a, 0x254, 0x300, 0x14b, 0xe8, 0x73, 0xe8, 0x65, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x6e, 0x7a,
+0xf9, 0x67, 0x68, 0xf2, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x64, 0xf9, 0x6d, 0x6c, 0x6f, 0x3b, 0x6e,
+0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x6b, 0x77, 0xee, 0x66, 0x254, 0x300, 0x65, 0x3b, 0x6e, 0x64, 0x7a, 0x254, 0x300,
+0x14b, 0x254, 0x300, 0x74, 0x197, 0x300, 0x66, 0x289, 0x300, 0x67, 0x68, 0xe0, 0x64, 0x7a, 0x75, 0x67, 0x68, 0xf9, 0x3b, 0x6e,
+0x64, 0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x67, 0x68, 0x1d4, 0x75, 0x77, 0x65, 0x6c, 0x254, 0x300, 0x6d, 0x3b, 0x6e, 0x64,
+0x7a, 0x254, 0x300, 0x14b, 0x254, 0x300, 0x63, 0x68, 0x77, 0x61, 0x294, 0xe0, 0x6b, 0x61, 0x61, 0x20, 0x77, 0x6f, 0x3b, 0x6e,
+0x64, 0x7a, 0x254, 0x300, 0x14b, 0xe8, 0x66, 0x77, 0xf2, 0x6f, 0x3b, 0x6e, 0x3b, 0x6b, 0x3b, 0x74, 0x3b, 0x74, 0x3b, 0x73,
+0x3b, 0x7a, 0x3b, 0x6b, 0x3b, 0x66, 0x3b, 0x64, 0x3b, 0x6c, 0x3b, 0x63, 0x3b, 0x66, 0x3b, 0x6b, 0x254, 0x6e, 0x3b, 0x6d,
+0x61, 0x63, 0x3b, 0x6d, 0x61, 0x74, 0x3b, 0x6d, 0x74, 0x6f, 0x3b, 0x6d, 0x70, 0x75, 0x3b, 0x68, 0x69, 0x6c, 0x3b, 0x6e,
+0x6a, 0x65, 0x3b, 0x68, 0x69, 0x6b, 0x3b, 0x64, 0x69, 0x70, 0x3b, 0x62, 0x69, 0x6f, 0x3b, 0x6d, 0x61, 0x79, 0x3b, 0x6c,
+0x69, 0x253, 0x3b, 0x4b, 0x254, 0x6e, 0x64, 0x254, 0x14b, 0x3b, 0x4d, 0xe0, 0x63, 0x25b, 0x302, 0x6c, 0x3b, 0x4d, 0xe0, 0x74,
+0xf9, 0x6d, 0x62, 0x3b, 0x4d, 0xe0, 0x74, 0x6f, 0x70, 0x3b, 0x4d, 0x300, 0x70, 0x75, 0x79, 0x25b, 0x3b, 0x48, 0xec, 0x6c,
+0xf2, 0x6e, 0x64, 0x25b, 0x300, 0x3b, 0x4e, 0x6a, 0xe8, 0x62, 0xe0, 0x3b, 0x48, 0xec, 0x6b, 0x61, 0x14b, 0x3b, 0x44, 0xec,
+0x70, 0x254, 0x300, 0x73, 0x3b, 0x42, 0xec, 0xf2, 0xf4, 0x6d, 0x3b, 0x4d, 0xe0, 0x79, 0x25b, 0x73, 0xe8, 0x70, 0x3b, 0x4c,
+0xec, 0x62, 0x75, 0x79, 0x20, 0x6c, 0x69, 0x20, 0x144, 0x79, 0xe8, 0x65, 0x3b, 0x6b, 0x3b, 0x6d, 0x3b, 0x6d, 0x3b, 0x6d,
+0x3b, 0x6d, 0x3b, 0x68, 0x3b, 0x6e, 0x3b, 0x68, 0x3b, 0x64, 0x3b, 0x62, 0x3b, 0x6d, 0x3b, 0x6c, 0x3b, 0x64, 0x69, 0x3b,
+0x14b, 0x67, 0x254, 0x6e, 0x3b, 0x73, 0x254, 0x14b, 0x3b, 0x64, 0x69, 0x253, 0x3b, 0x65, 0x6d, 0x69, 0x3b, 0x65, 0x73, 0x254,
+0x3b, 0x6d, 0x61, 0x64, 0x3b, 0x64, 0x69, 0x14b, 0x3b, 0x6e, 0x79, 0x25b, 0x74, 0x3b, 0x6d, 0x61, 0x79, 0x3b, 0x74, 0x69,
+0x6e, 0x3b, 0x65, 0x6c, 0xe1, 0x3b, 0x64, 0x69, 0x6d, 0x254, 0x301, 0x64, 0x69, 0x3b, 0x14b, 0x67, 0x254, 0x6e, 0x64, 0x25b,
+0x3b, 0x73, 0x254, 0x14b, 0x25b, 0x3b, 0x64, 0x69, 0x253, 0xe1, 0x253, 0xe1, 0x3b, 0x65, 0x6d, 0x69, 0x61, 0x73, 0x65, 0x6c,
+0x65, 0x3b, 0x65, 0x73, 0x254, 0x70, 0x25b, 0x73, 0x254, 0x70, 0x25b, 0x3b, 0x6d, 0x61, 0x64, 0x69, 0x253, 0x25b, 0x301, 0x64,
+0xed, 0x253, 0x25b, 0x301, 0x3b, 0x64, 0x69, 0x14b, 0x67, 0x69, 0x6e, 0x64, 0x69, 0x3b, 0x6e, 0x79, 0x25b, 0x74, 0x25b, 0x6b,
+0x69, 0x3b, 0x6d, 0x61, 0x79, 0xe9, 0x73, 0x25b, 0x301, 0x3b, 0x74, 0x69, 0x6e, 0xed, 0x6e, 0xed, 0x3b, 0x65, 0x6c, 0xe1,
+0x14b, 0x67, 0x25b, 0x301, 0x3b, 0x64, 0x3b, 0x14b, 0x3b, 0x73, 0x3b, 0x64, 0x3b, 0x65, 0x3b, 0x65, 0x3b, 0x6d, 0x3b, 0x64,
+0x3b, 0x6e, 0x3b, 0x6d, 0x3b, 0x74, 0x3b, 0x65, 0x3b, 0x53, 0x61, 0x3b, 0x46, 0x65, 0x3b, 0x4d, 0x61, 0x3b, 0x41, 0x62,
+0x3b, 0x4d, 0x65, 0x3b, 0x53, 0x75, 0x3b, 0x53, 0xfa, 0x3b, 0x55, 0x74, 0x3b, 0x53, 0x65, 0x3b, 0x4f, 0x6b, 0x3b, 0x4e,
+0x6f, 0x3b, 0x44, 0x65, 0x3b, 0x53, 0x61, 0x6e, 0x76, 0x69, 0x65, 0x3b, 0x46, 0xe9, 0x62, 0x69, 0x72, 0x69, 0x65, 0x3b,
+0x4d, 0x61, 0x72, 0x73, 0x3b, 0x41, 0x62, 0x75, 0x72, 0x69, 0x6c, 0x3b, 0x4d, 0x65, 0x65, 0x3b, 0x53, 0x75, 0x65, 0x14b,
+0x3b, 0x53, 0xfa, 0x75, 0x79, 0x65, 0x65, 0x3b, 0x55, 0x74, 0x3b, 0x53, 0x65, 0x74, 0x74, 0x65, 0x6d, 0x62, 0x61, 0x72,
+0x3b, 0x4f, 0x6b, 0x74, 0x6f, 0x62, 0x61, 0x72, 0x3b, 0x4e, 0x6f, 0x76, 0x65, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x44, 0x69,
+0x73, 0x61, 0x6d, 0x62, 0x61, 0x72, 0x3b, 0x53, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x53, 0x3b, 0x53,
+0x3b, 0x55, 0x3b, 0x53, 0x3b, 0x4f, 0x3b, 0x4e, 0x3b, 0x44, 0x3b, 0x6e, 0x67, 0x6f, 0x3b, 0x6e, 0x67, 0x62, 0x3b, 0x6e,
+0x67, 0x6c, 0x3b, 0x6e, 0x67, 0x6e, 0x3b, 0x6e, 0x67, 0x74, 0x3b, 0x6e, 0x67, 0x73, 0x3b, 0x6e, 0x67, 0x7a, 0x3b, 0x6e,
+0x67, 0x6d, 0x3b, 0x6e, 0x67, 0x65, 0x3b, 0x6e, 0x67, 0x61, 0x3b, 0x6e, 0x67, 0x61, 0x64, 0x3b, 0x6e, 0x67, 0x61, 0x62,
+0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x6f, 0x73, 0xfa, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x62, 0x25b, 0x30c, 0x3b, 0x6e,
+0x67, 0x254, 0x6e, 0x20, 0x6c, 0xe1, 0x6c, 0x61, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x6e, 0x79, 0x69, 0x6e, 0x61, 0x3b,
+0x6e, 0x67, 0x254, 0x6e, 0x20, 0x74, 0xe1, 0x6e, 0x61, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x73, 0x61, 0x6d, 0x259, 0x6e,
+0x61, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x7a, 0x61, 0x6d, 0x67, 0x62, 0xe1, 0x6c, 0x61, 0x3b, 0x6e, 0x67, 0x254, 0x6e,
+0x20, 0x6d, 0x77, 0x6f, 0x6d, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x65, 0x62, 0x75, 0x6c, 0xfa, 0x3b, 0x6e, 0x67, 0x254,
+0x6e, 0x20, 0x61, 0x77, 0xf3, 0x6d, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x61, 0x77, 0xf3, 0x6d, 0x20, 0x61, 0x69, 0x20,
+0x64, 0x7a, 0x69, 0xe1, 0x3b, 0x6e, 0x67, 0x254, 0x6e, 0x20, 0x61, 0x77, 0xf3, 0x6d, 0x20, 0x61, 0x69, 0x20, 0x62, 0x25b,
+0x30c, 0x3b, 0x6f, 0x3b, 0x62, 0x3b, 0x6c, 0x3b, 0x6e, 0x3b, 0x74, 0x3b, 0x73, 0x3b, 0x7a, 0x3b, 0x6d, 0x3b, 0x65, 0x3b,
+0x61, 0x3b, 0x64, 0x3b, 0x62, 0x3b, 0x14b, 0x31, 0x3b, 0x14b, 0x32, 0x3b, 0x14b, 0x33, 0x3b, 0x14b, 0x34, 0x3b, 0x14b, 0x35,
+0x3b, 0x14b, 0x36, 0x3b, 0x14b, 0x37, 0x3b, 0x14b, 0x38, 0x3b, 0x14b, 0x39, 0x3b, 0x14b, 0x31, 0x30, 0x3b, 0x14b, 0x31, 0x31,
+0x3b, 0x14b, 0x31, 0x32, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x20, 0x6e, 0x74, 0x254, 0x301, 0x6e, 0x74, 0x254, 0x3b,
+0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x62, 0x25b, 0x301, 0x25b, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61,
+0x6b, 0x1dd, 0x20, 0x72, 0xe1, 0xe1, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x6e, 0x69, 0x6e, 0x3b,
+0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x74, 0xe1, 0x61, 0x6e, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61,
+0x6b, 0x1dd, 0x20, 0x74, 0xe1, 0x61, 0x66, 0x254, 0x6b, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x74,
+0xe1, 0x61, 0x62, 0x25b, 0x25b, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x74, 0xe1, 0x61, 0x72, 0x61,
+0x61, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x74, 0xe1, 0x61, 0x6e, 0x69, 0x6e, 0x3b, 0x14b, 0x77,
+0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd, 0x20, 0x6e, 0x74, 0x25b, 0x6b, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61, 0x6b, 0x1dd,
+0x20, 0x6e, 0x74, 0x25b, 0x6b, 0x20, 0x64, 0x69, 0x20, 0x62, 0x254, 0x301, 0x6b, 0x3b, 0x14b, 0x77, 0xed, 0xed, 0x20, 0x61,
+0x6b, 0x1dd, 0x20, 0x6e, 0x74, 0x25b, 0x6b, 0x20, 0x64, 0x69, 0x20, 0x62, 0x25b, 0x301, 0x25b, 0x3b, 0x4b, 0x77, 0x61, 0x3b,
+0x55, 0x6e, 0x61, 0x3b, 0x52, 0x61, 0x72, 0x3b, 0x43, 0x68, 0x65, 0x3b, 0x54, 0x68, 0x61, 0x3b, 0x4d, 0x6f, 0x63, 0x3b,
+0x53, 0x61, 0x62, 0x3b, 0x4e, 0x61, 0x6e, 0x3b, 0x54, 0x69, 0x73, 0x3b, 0x4b, 0x75, 0x6d, 0x3b, 0x4d, 0x6f, 0x6a, 0x3b,
+0x59, 0x65, 0x6c, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x6b, 0x77, 0x61, 0x6e, 0x7a, 0x61, 0x3b,
+0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x75, 0x6e, 0x61, 0x79, 0x65, 0x6c, 0x69, 0x3b, 0x4d, 0x77, 0x65,
+0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x75, 0x6e, 0x65, 0x72, 0x61, 0x72, 0x75, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20,
+0x77, 0x6f, 0x20, 0x75, 0x6e, 0x65, 0x63, 0x68, 0x65, 0x73, 0x68, 0x65, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77,
+0x6f, 0x20, 0x75, 0x6e, 0x65, 0x74, 0x68, 0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20,
+0x74, 0x68, 0x61, 0x6e, 0x75, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x6f, 0x63, 0x68, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69,
+0x20, 0x77, 0x6f, 0x20, 0x73, 0x61, 0x62, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x6e, 0x61,
+0x6e, 0x65, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x74, 0x69, 0x73, 0x61, 0x3b, 0x4d, 0x77, 0x65,
+0x72, 0x69, 0x20, 0x77, 0x6f, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77, 0x6f, 0x20,
+0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x6f, 0x6a, 0x61, 0x3b, 0x4d, 0x77, 0x65, 0x72, 0x69, 0x20, 0x77,
+0x6f, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x79, 0x65, 0x6c, 0x27, 0x6c, 0x69, 0x3b, 0x4b, 0x3b, 0x55,
+0x3b, 0x52, 0x3b, 0x43, 0x3b, 0x54, 0x3b, 0x4d, 0x3b, 0x53, 0x3b, 0x4e, 0x3b, 0x54, 0x3b, 0x4b, 0x3b, 0x4d, 0x3b, 0x59,
+0x3b, 0x46, 0x4c, 0x4f, 0x3b, 0x43, 0x4c, 0x41, 0x3b, 0x43, 0x4b, 0x49, 0x3b, 0x46, 0x4d, 0x46, 0x3b, 0x4d, 0x41, 0x44,
+0x3b, 0x4d, 0x42, 0x49, 0x3b, 0x4d, 0x4c, 0x49, 0x3b, 0x4d, 0x41, 0x4d, 0x3b, 0x46, 0x44, 0x45, 0x3b, 0x46, 0x4d, 0x55,
+0x3b, 0x46, 0x47, 0x57, 0x3b, 0x46, 0x59, 0x55, 0x3b, 0x46, 0x129, 0x69, 0x20, 0x4c, 0x6f, 0x6f, 0x3b, 0x43, 0x6f, 0x6b,
+0x63, 0x77, 0x61, 0x6b, 0x6c, 0x61, 0x14b, 0x6e, 0x65, 0x3b, 0x43, 0x6f, 0x6b, 0x63, 0x77, 0x61, 0x6b, 0x6c, 0x69, 0x69,
+0x3b, 0x46, 0x129, 0x69, 0x20, 0x4d, 0x61, 0x72, 0x66, 0x6f, 0x6f, 0x3b, 0x4d, 0x61, 0x64, 0x1dd, 0x1dd, 0x75, 0x75, 0x74,
+0x1dd, 0x62, 0x69, 0x6a, 0x61, 0x14b, 0x3b, 0x4d, 0x61, 0x6d, 0x1dd, 0x14b, 0x67, 0x77, 0xe3, 0x61, 0x66, 0x61, 0x68, 0x62,
+0x69, 0x69, 0x3b, 0x4d, 0x61, 0x6d, 0x1dd, 0x14b, 0x67, 0x77, 0xe3, 0x61, 0x6c, 0x69, 0x69, 0x3b, 0x4d, 0x61, 0x64, 0x1dd,
+0x6d, 0x62, 0x69, 0x69, 0x3b, 0x46, 0x129, 0x69, 0x20, 0x44, 0x1dd, 0x253, 0x6c, 0x69, 0x69, 0x3b, 0x46, 0x129, 0x69, 0x20,
+0x4d, 0x75, 0x6e, 0x64, 0x61, 0x14b, 0x3b, 0x46, 0x129, 0x69, 0x20, 0x47, 0x77, 0x61, 0x68, 0x6c, 0x6c, 0x65, 0x3b, 0x46,
+0x129, 0x69, 0x20, 0x59, 0x75, 0x72, 0x75, 0x3b, 0x4f, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x46, 0x3b, 0x44, 0x3b, 0x42, 0x3b,
+0x4c, 0x3b, 0x4d, 0x3b, 0x45, 0x3b, 0x55, 0x3b, 0x57, 0x3b, 0x59, 0x3b, 0x6e, 0x67, 0x31, 0x3b, 0x6e, 0x67, 0x32, 0x3b,
+0x6e, 0x67, 0x33, 0x3b, 0x6e, 0x67, 0x34, 0x3b, 0x6e, 0x67, 0x35, 0x3b, 0x6e, 0x67, 0x36, 0x3b, 0x6e, 0x67, 0x37, 0x3b,
+0x6e, 0x67, 0x38, 0x3b, 0x6e, 0x67, 0x39, 0x3b, 0x6e, 0x67, 0x31, 0x30, 0x3b, 0x6e, 0x67, 0x31, 0x31, 0x3b, 0x6b, 0x72,
+0x69, 0x73, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x6d, 0x61, 0x74, 0xe1, 0x68, 0x72, 0x61, 0x3b, 0x6e, 0x67, 0x77,
+0x25b, 0x6e, 0x20, 0x144, 0x6d, 0x62, 0x61, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x144, 0x6c, 0x61, 0x6c, 0x3b, 0x6e,
+0x67, 0x77, 0x25b, 0x6e, 0x20, 0x144, 0x6e, 0x61, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x144, 0x74, 0x61, 0x6e, 0x3b,
+0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x144, 0x74, 0x75, 0xf3, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x68, 0x25b, 0x6d,
+0x62, 0x75, 0x25b, 0x72, 0xed, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x6c, 0x254, 0x6d, 0x62, 0x69, 0x3b, 0x6e, 0x67,
+0x77, 0x25b, 0x6e, 0x20, 0x72, 0x25b, 0x62, 0x76, 0x75, 0xe2, 0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x77, 0x75, 0x6d,
+0x3b, 0x6e, 0x67, 0x77, 0x25b, 0x6e, 0x20, 0x77, 0x75, 0x6d, 0x20, 0x6e, 0x61, 0x76, 0x16d, 0x72, 0x3b, 0x6b, 0x72, 0xed,
+0x73, 0x69, 0x6d, 0x69, 0x6e, 0x3b, 0x54, 0x69, 0x6f, 0x70, 0x3b, 0x50, 0x25b, 0x74, 0x3b, 0x44, 0x75, 0x254, 0x331, 0x254,
+0x331, 0x3b, 0x47, 0x75, 0x61, 0x6b, 0x3b, 0x44, 0x75, 0xe4, 0x3b, 0x4b, 0x6f, 0x72, 0x3b, 0x50, 0x61, 0x79, 0x3b, 0x54,
+0x68, 0x6f, 0x6f, 0x3b, 0x54, 0x25b, 0x25b, 0x3b, 0x4c, 0x61, 0x61, 0x3b, 0x4b, 0x75, 0x72, 0x3b, 0x54, 0x69, 0x64, 0x3b,
+0x54, 0x69, 0x6f, 0x70, 0x20, 0x74, 0x68, 0x61, 0x72, 0x20, 0x70, 0x25b, 0x74, 0x3b, 0x50, 0x25b, 0x74, 0x3b, 0x44, 0x75,
+0x254, 0x331, 0x254, 0x331, 0x14b, 0x3b, 0x47, 0x75, 0x61, 0x6b, 0x3b, 0x44, 0x75, 0xe4, 0x74, 0x3b, 0x4b, 0x6f, 0x72, 0x6e,
+0x79, 0x6f, 0x6f, 0x74, 0x3b, 0x50, 0x61, 0x79, 0x20, 0x79, 0x69, 0x65, 0x331, 0x74, 0x6e, 0x69, 0x3b, 0x54, 0x68, 0x6f,
+0x331, 0x6f, 0x331, 0x72, 0x3b, 0x54, 0x25b, 0x25b, 0x72, 0x3b, 0x4c, 0x61, 0x61, 0x74, 0x68, 0x3b, 0x4b, 0x75, 0x72, 0x3b,
+0x54, 0x69, 0x6f, 0x331, 0x70, 0x20, 0x69, 0x6e, 0x20, 0x64, 0x69, 0x331, 0x69, 0x331, 0x74, 0x3b, 0x54, 0x3b, 0x50, 0x3b,
+0x44, 0x3b, 0x47, 0x3b, 0x44, 0x3b, 0x4b, 0x3b, 0x50, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x4c, 0x3b, 0x4b, 0x3b, 0x54, 0x3b,
+0x422, 0x43e, 0x445, 0x441, 0x3b, 0x41e, 0x43b, 0x443, 0x43d, 0x3b, 0x41a, 0x43b, 0x43d, 0x5f, 0x442, 0x442, 0x440, 0x3b, 0x41c, 0x443,
+0x441, 0x5f, 0x443, 0x441, 0x442, 0x3b, 0x42b, 0x430, 0x43c, 0x5f, 0x439, 0x43d, 0x3b, 0x411, 0x44d, 0x441, 0x5f, 0x439, 0x43d, 0x3b,
+0x41e, 0x442, 0x5f, 0x439, 0x43d, 0x3b, 0x410, 0x442, 0x440, 0x434, 0x44c, 0x5f, 0x439, 0x43d, 0x3b, 0x411, 0x43b, 0x495, 0x43d, 0x5f,
+0x439, 0x43d, 0x3b, 0x410, 0x43b, 0x442, 0x3b, 0x421, 0x44d, 0x442, 0x3b, 0x410, 0x445, 0x441, 0x3b, 0x422, 0x43e, 0x445, 0x441, 0x443,
+0x43d, 0x43d, 0x44c, 0x443, 0x3b, 0x41e, 0x43b, 0x443, 0x43d, 0x43d, 0x44c, 0x443, 0x3b, 0x41a, 0x443, 0x43b, 0x443, 0x43d, 0x20, 0x442,
+0x443, 0x442, 0x430, 0x440, 0x3b, 0x41c, 0x443, 0x443, 0x441, 0x20, 0x443, 0x441, 0x442, 0x430, 0x440, 0x3b, 0x42b, 0x430, 0x43c, 0x20,
+0x44b, 0x439, 0x44b, 0x43d, 0x3b, 0x411, 0x44d, 0x441, 0x20, 0x44b, 0x439, 0x44b, 0x43d, 0x3b, 0x41e, 0x442, 0x20, 0x44b, 0x439, 0x44b,
+0x43d, 0x3b, 0x410, 0x442, 0x44b, 0x440, 0x434, 0x44c, 0x44b, 0x445, 0x20, 0x44b, 0x439, 0x44b, 0x43d, 0x3b, 0x411, 0x430, 0x43b, 0x430,
+0x495, 0x430, 0x43d, 0x20, 0x44b, 0x439, 0x44b, 0x43d, 0x3b, 0x410, 0x43b, 0x442, 0x44b, 0x43d, 0x43d, 0x44c, 0x44b, 0x3b, 0x421, 0x44d,
+0x442, 0x438, 0x43d, 0x43d, 0x44c, 0x438, 0x3b, 0x410, 0x445, 0x441, 0x44b, 0x43d, 0x43d, 0x44c, 0x44b, 0x3b, 0x422, 0x3b, 0x41e, 0x3b,
+0x41a, 0x3b, 0x41c, 0x3b, 0x42b, 0x3b, 0x411, 0x3b, 0x41e, 0x3b, 0x410, 0x3b, 0x411, 0x3b, 0x410, 0x3b, 0x421, 0x3b, 0x410, 0x3b,
+0x4d, 0x75, 0x70, 0x3b, 0x4d, 0x77, 0x69, 0x3b, 0x4d, 0x73, 0x68, 0x3b, 0x4d, 0x75, 0x6e, 0x3b, 0x4d, 0x61, 0x67, 0x3b,
+0x4d, 0x75, 0x6a, 0x3b, 0x4d, 0x73, 0x70, 0x3b, 0x4d, 0x70, 0x67, 0x3b, 0x4d, 0x79, 0x65, 0x3b, 0x4d, 0x6f, 0x6b, 0x3b,
+0x4d, 0x75, 0x73, 0x3b, 0x4d, 0x75, 0x68, 0x3b, 0x4d, 0x75, 0x70, 0x61, 0x6c, 0x61, 0x6e, 0x67, 0x75, 0x6c, 0x77, 0x61,
+0x3b, 0x4d, 0x77, 0x69, 0x74, 0x6f, 0x70, 0x65, 0x3b, 0x4d, 0x75, 0x73, 0x68, 0x65, 0x6e, 0x64, 0x65, 0x3b, 0x4d, 0x75,
+0x6e, 0x79, 0x69, 0x3b, 0x4d, 0x75, 0x73, 0x68, 0x65, 0x6e, 0x64, 0x65, 0x20, 0x4d, 0x61, 0x67, 0x61, 0x6c, 0x69, 0x3b,
+0x4d, 0x75, 0x6a, 0x69, 0x6d, 0x62, 0x69, 0x3b, 0x4d, 0x75, 0x73, 0x68, 0x69, 0x70, 0x65, 0x70, 0x6f, 0x3b, 0x4d, 0x75,
+0x70, 0x75, 0x67, 0x75, 0x74, 0x6f, 0x3b, 0x4d, 0x75, 0x6e, 0x79, 0x65, 0x6e, 0x73, 0x65, 0x3b, 0x4d, 0x6f, 0x6b, 0x68,
+0x75, 0x3b, 0x4d, 0x75, 0x73, 0x6f, 0x6e, 0x67, 0x61, 0x6e, 0x64, 0x65, 0x6d, 0x62, 0x77, 0x65, 0x3b, 0x4d, 0x75, 0x68,
+0x61, 0x61, 0x6e, 0x6f, 0x3b, 0x6d, 0x6b, 0x77, 0x3b, 0x6d, 0x70, 0x69, 0x3b, 0x6d, 0x74, 0x75, 0x3b, 0x6d, 0x69, 0x6e,
+0x3b, 0x6d, 0x74, 0x6e, 0x3b, 0x6d, 0x73, 0x74, 0x3b, 0x6d, 0x73, 0x62, 0x3b, 0x6d, 0x75, 0x6e, 0x3b, 0x6d, 0x74, 0x73,
+0x3b, 0x6d, 0x6b, 0x75, 0x3b, 0x6d, 0x6b, 0x6d, 0x3b, 0x6d, 0x6b, 0x62, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79,
+0x61, 0x20, 0x6b, 0x77, 0x61, 0x6e, 0x6a, 0x61, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x70, 0x69,
+0x6c, 0x69, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x6d, 0x77, 0x65,
+0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x69, 0x6e, 0x65, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x74,
+0x61, 0x6e, 0x75, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x73, 0x69, 0x74, 0x61, 0x3b, 0x6d, 0x77,
+0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x73, 0x61, 0x62, 0x61, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61,
+0x20, 0x6d, 0x75, 0x6e, 0x61, 0x6e, 0x65, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x74, 0x69, 0x73,
+0x61, 0x3b, 0x6d, 0x77, 0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x3b, 0x6d, 0x77, 0x65, 0x7a,
+0x69, 0x20, 0x79, 0x61, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x6f, 0x79, 0x61, 0x3b, 0x6d, 0x77,
+0x65, 0x7a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x6b, 0x75, 0x6d, 0x69, 0x20, 0x79, 0x61, 0x20, 0x6d, 0x62, 0x69, 0x6c, 0x69,
+0x3b, 0x6b, 0x3b, 0x70, 0x3b, 0x74, 0x3b, 0x69, 0x3b, 0x74, 0x3b, 0x73, 0x3b, 0x73, 0x3b, 0x6d, 0x3b, 0x74, 0x3b, 0x6b,
+0x3b, 0x6d, 0x3b, 0x6d, 0x3b, 0xa5a8, 0xa56a, 0xa583, 0x20, 0xa51e, 0xa56e, 0x3b, 0xa552, 0xa561, 0xa59d, 0xa595, 0x3b, 0xa57e, 0xa5ba, 0x3b,
+0xa5a2, 0xa595, 0x3b, 0xa591, 0xa571, 0x3b, 0x36, 0x3b, 0x37, 0x3b, 0xa5db, 0xa515, 0x3b, 0xa562, 0xa54c, 0x3b, 0xa56d, 0xa583, 0x3b, 0xa51e,
+0xa60b, 0xa554, 0xa57f, 0x20, 0xa578, 0xa583, 0xa5cf, 0x3b, 0xa5a8, 0xa56a, 0xa571, 0x20, 0xa5cf, 0xa56e, 0x3b, 0x6c, 0x75, 0x75, 0x6b, 0x61,
+0x6f, 0x20, 0x6b, 0x65, 0x6d, 0xe3, 0x3b, 0x253, 0x61, 0x6e, 0x64, 0x61, 0x253, 0x75, 0x3b, 0x76, 0x254, 0x254, 0x3b, 0x66,
+0x75, 0x6c, 0x75, 0x3b, 0x67, 0x6f, 0x6f, 0x3b, 0x36, 0x3b, 0x37, 0x3b, 0x6b, 0x254, 0x6e, 0x64, 0x65, 0x3b, 0x73, 0x61,
+0x61, 0x68, 0x3b, 0x67, 0x61, 0x6c, 0x6f, 0x3b, 0x6b, 0x65, 0x6e, 0x70, 0x6b, 0x61, 0x74, 0x6f, 0x20, 0x253, 0x6f, 0x6c,
+0x6f, 0x6c, 0x254, 0x3b, 0x6c, 0x75, 0x75, 0x6b, 0x61, 0x6f, 0x20, 0x6c, 0x254, 0x6d, 0x61, 0x3b, 0x4a, 0x65, 0x6e, 0x3b,
+0x48, 0x6f, 0x72, 0x3b, 0x4d, 0xe4, 0x72, 0x3b, 0x41, 0x62, 0x72, 0x3b, 0x4d, 0x65, 0x69, 0x3b, 0x42, 0x72, 0xe1, 0x3b,
+0x48, 0x65, 0x69, 0x3b, 0xd6, 0x69, 0x67, 0x3b, 0x48, 0x65, 0x72, 0x3b, 0x57, 0xed, 0x6d, 0x3b, 0x57, 0x69, 0x6e, 0x3b,
+0x43, 0x68, 0x72, 0x3b, 0x4a, 0x65, 0x6e, 0x6e, 0x65, 0x72, 0x3b, 0x48, 0x6f, 0x72, 0x6e, 0x69, 0x67, 0x3b, 0x4d, 0xe4,
+0x72, 0x7a, 0x65, 0x3b, 0x41, 0x62, 0x72, 0x69, 0x6c, 0x6c, 0x65, 0x3b, 0x4d, 0x65, 0x69, 0x6a, 0x65, 0x3b, 0x42, 0x72,
+0xe1, 0x10d, 0x65, 0x74, 0x3b, 0x48, 0x65, 0x69, 0x77, 0x65, 0x74, 0x3b, 0xd6, 0x69, 0x67, 0x161, 0x74, 0x65, 0x3b, 0x48,
+0x65, 0x72, 0x62, 0x161, 0x74, 0x6d, 0xe1, 0x6e, 0x65, 0x74, 0x3b, 0x57, 0xed, 0x6d, 0xe1, 0x6e, 0x65, 0x74, 0x3b, 0x57,
+0x69, 0x6e, 0x74, 0x65, 0x72, 0x6d, 0xe1, 0x6e, 0x65, 0x74, 0x3b, 0x43, 0x68, 0x72, 0x69, 0x161, 0x74, 0x6d, 0xe1, 0x6e,
+0x65, 0x74, 0x3b, 0x4a, 0x3b, 0x48, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x42, 0x3b, 0x48, 0x3b, 0xd6, 0x3b, 0x48,
+0x3b, 0x57, 0x3b, 0x57, 0x3b, 0x43, 0x3b, 0x6f, 0x2e, 0x31, 0x3b, 0x6f, 0x2e, 0x32, 0x3b, 0x6f, 0x2e, 0x33, 0x3b, 0x6f,
+0x2e, 0x34, 0x3b, 0x6f, 0x2e, 0x35, 0x3b, 0x6f, 0x2e, 0x36, 0x3b, 0x6f, 0x2e, 0x37, 0x3b, 0x6f, 0x2e, 0x38, 0x3b, 0x6f,
+0x2e, 0x39, 0x3b, 0x6f, 0x2e, 0x31, 0x30, 0x3b, 0x6f, 0x2e, 0x31, 0x31, 0x3b, 0x6f, 0x2e, 0x31, 0x32, 0x3b, 0x70, 0x69,
+0x6b, 0xed, 0x74, 0xed, 0x6b, 0xed, 0x74, 0x69, 0x65, 0x2c, 0x20, 0x6f, 0xf3, 0x6c, 0xed, 0x20, 0xfa, 0x20, 0x6b, 0x75,
+0x74, 0xfa, 0x61, 0x6e, 0x3b, 0x73, 0x69, 0x25b, 0x79, 0x25b, 0x301, 0x2c, 0x20, 0x6f, 0xf3, 0x6c, 0x69, 0x20, 0xfa, 0x20,
+0x6b, 0xe1, 0x6e, 0x64, 0xed, 0x25b, 0x3b, 0x254, 0x6e, 0x73, 0xfa, 0x6d, 0x62, 0x254, 0x6c, 0x2c, 0x20, 0x6f, 0xf3, 0x6c,
+0x69, 0x20, 0xfa, 0x20, 0x6b, 0xe1, 0x74, 0xe1, 0x74, 0xfa, 0x25b, 0x3b, 0x6d, 0x65, 0x73, 0x69, 0x14b, 0x2c, 0x20, 0x6f,
+0xf3, 0x6c, 0x69, 0x20, 0xfa, 0x20, 0x6b, 0xe9, 0x6e, 0x69, 0x65, 0x3b, 0x65, 0x6e, 0x73, 0x69, 0x6c, 0x2c, 0x20, 0x6f,
+0xf3, 0x6c, 0x69, 0x20, 0xfa, 0x20, 0x6b, 0xe1, 0x74, 0xe1, 0x6e, 0x75, 0x25b, 0x3b, 0x254, 0x73, 0x254, 0x6e, 0x3b, 0x65,
+0x66, 0x75, 0x74, 0x65, 0x3b, 0x70, 0x69, 0x73, 0x75, 0x79, 0xfa, 0x3b, 0x69, 0x6d, 0x25b, 0x14b, 0x20, 0x69, 0x20, 0x70,
+0x75, 0x254, 0x73, 0x3b, 0x69, 0x6d, 0x25b, 0x14b, 0x20, 0x69, 0x20, 0x70, 0x75, 0x74, 0xfa, 0x6b, 0x2c, 0x6f, 0xf3, 0x6c,
+0x69, 0x20, 0xfa, 0x20, 0x6b, 0xe1, 0x74, 0xed, 0x25b, 0x3b, 0x6d, 0x61, 0x6b, 0x61, 0x6e, 0x64, 0x69, 0x6b, 0x25b, 0x3b,
+0x70, 0x69, 0x6c, 0x254, 0x6e, 0x64, 0x254, 0x301, 0x3b, 0x58, 0x69, 0x6e, 0x3b, 0x46, 0x65, 0x62, 0x3b, 0x4d, 0x61, 0x72,
+0x3b, 0x41, 0x62, 0x72, 0x3b, 0x4d, 0x61, 0x79, 0x3b, 0x58, 0x75, 0x6e, 0x3b, 0x58, 0x6e, 0x74, 0x3b, 0x41, 0x67, 0x6f,
+0x3b, 0x53, 0x65, 0x74, 0x3b, 0x4f, 0x63, 0x68, 0x3b, 0x50, 0x61, 0x79, 0x3b, 0x41, 0x76, 0x69, 0x3b, 0x78, 0x69, 0x6e,
+0x65, 0x72, 0x75, 0x3b, 0x66, 0x65, 0x62, 0x72, 0x65, 0x72, 0x75, 0x3b, 0x6d, 0x61, 0x72, 0x7a, 0x75, 0x3b, 0x61, 0x62,
+0x72, 0x69, 0x6c, 0x3b, 0x6d, 0x61, 0x79, 0x75, 0x3b, 0x78, 0x75, 0x6e, 0x75, 0x3b, 0x78, 0x75, 0x6e, 0x65, 0x74, 0x75,
+0x3b, 0x61, 0x67, 0x6f, 0x73, 0x74, 0x75, 0x3b, 0x73, 0x65, 0x74, 0x69, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b, 0x6f, 0x63,
+0x68, 0x6f, 0x62, 0x72, 0x65, 0x3b, 0x70, 0x61, 0x79, 0x61, 0x72, 0x65, 0x73, 0x3b, 0x61, 0x76, 0x69, 0x65, 0x6e, 0x74,
+0x75, 0x3b, 0x58, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x58, 0x3b, 0x58, 0x3b, 0x41, 0x3b, 0x53, 0x3b,
+0x4f, 0x3b, 0x50, 0x3b, 0x41, 0x3b, 0x78, 0x69, 0x6e, 0x3b, 0x66, 0x65, 0x62, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x61, 0x62,
+0x72, 0x3b, 0x6d, 0x61, 0x79, 0x3b, 0x78, 0x75, 0x6e, 0x3b, 0x78, 0x6e, 0x74, 0x3b, 0x61, 0x67, 0x6f, 0x3b, 0x73, 0x65,
+0x74, 0x3b, 0x6f, 0x63, 0x68, 0x3b, 0x70, 0x61, 0x79, 0x3b, 0x61, 0x76, 0x69, 0x3b, 0x64, 0x65, 0x20, 0x78, 0x69, 0x6e,
+0x65, 0x72, 0x75, 0x3b, 0x64, 0x65, 0x20, 0x66, 0x65, 0x62, 0x72, 0x65, 0x72, 0x75, 0x3b, 0x64, 0x65, 0x20, 0x6d, 0x61,
+0x72, 0x7a, 0x75, 0x3b, 0x64, 0x27, 0x61, 0x62, 0x72, 0x69, 0x6c, 0x3b, 0x64, 0x65, 0x20, 0x6d, 0x61, 0x79, 0x75, 0x3b,
+0x64, 0x65, 0x20, 0x78, 0x75, 0x6e, 0x75, 0x3b, 0x64, 0x65, 0x20, 0x78, 0x75, 0x6e, 0x65, 0x74, 0x75, 0x3b, 0x64, 0x27,
+0x61, 0x67, 0x6f, 0x73, 0x74, 0x75, 0x3b, 0x64, 0x65, 0x20, 0x73, 0x65, 0x74, 0x69, 0x65, 0x6d, 0x62, 0x72, 0x65, 0x3b,
+0x64, 0x27, 0x6f, 0x63, 0x68, 0x6f, 0x62, 0x72, 0x65, 0x3b, 0x64, 0x65, 0x20, 0x70, 0x61, 0x79, 0x61, 0x72, 0x65, 0x73,
+0x3b, 0x64, 0x27, 0x61, 0x76, 0x69, 0x65, 0x6e, 0x74, 0x75, 0x3b, 0x4e, 0x64, 0x75, 0x14b, 0x6d, 0x62, 0x69, 0x20, 0x53,
+0x61, 0x14b, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x50, 0x25b, 0x301, 0x70, 0xe1, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b,
+0x20, 0x50, 0x25b, 0x301, 0x74, 0xe1, 0x74, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x50, 0x25b, 0x301, 0x6e, 0x25b, 0x301,
+0x6b, 0x77, 0x61, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x50, 0x61, 0x74, 0x61, 0x61, 0x3b, 0x50, 0x25b, 0x73, 0x61,
+0x14b, 0x20, 0x50, 0x25b, 0x301, 0x6e, 0x25b, 0x301, 0x6e, 0x74, 0xfa, 0x6b, 0xfa, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20,
+0x53, 0x61, 0x61, 0x6d, 0x62, 0xe1, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x50, 0x25b, 0x301, 0x6e, 0x25b, 0x301, 0x66,
+0x254, 0x6d, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x50, 0x25b, 0x301, 0x6e, 0x25b, 0x301, 0x70, 0x66, 0xfa, 0xa78b, 0xfa,
+0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x4e, 0x25b, 0x67, 0x25b, 0x301, 0x6d, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20,
+0x4e, 0x74, 0x73, 0x254, 0x30c, 0x70, 0x6d, 0x254, 0x301, 0x3b, 0x50, 0x25b, 0x73, 0x61, 0x14b, 0x20, 0x4e, 0x74, 0x73, 0x254,
+0x30c, 0x70, 0x70, 0xe1, 0x3b, 0x70, 0x61, 0x6d, 0x62, 0x61, 0x3b, 0x77, 0x61, 0x6e, 0x6a, 0x61, 0x3b, 0x6d, 0x62, 0x69,
+0x79, 0x254, 0x20, 0x6d, 0x25b, 0x6e, 0x64, 0x6f, 0x14b, 0x67, 0x254, 0x3b, 0x4e, 0x79, 0x254, 0x6c, 0x254, 0x6d, 0x62, 0x254,
+0x14b, 0x67, 0x254, 0x3b, 0x4d, 0x254, 0x6e, 0x254, 0x20, 0x14b, 0x67, 0x62, 0x61, 0x6e, 0x6a, 0x61, 0x3b, 0x4e, 0x79, 0x61,
+0x14b, 0x67, 0x77, 0x25b, 0x20, 0x14b, 0x67, 0x62, 0x61, 0x6e, 0x6a, 0x61, 0x3b, 0x6b, 0x75, 0x14b, 0x67, 0x77, 0x25b, 0x3b,
+0x66, 0x25b, 0x3b, 0x6e, 0x6a, 0x61, 0x70, 0x69, 0x3b, 0x6e, 0x79, 0x75, 0x6b, 0x75, 0x6c, 0x3b, 0x31, 0x31, 0x3b, 0x253,
+0x75, 0x6c, 0x253, 0x75, 0x73, 0x25b, 0x3b, 0x6d, 0x62, 0x65, 0x67, 0x74, 0x75, 0x67, 0x3b, 0x69, 0x6d, 0x65, 0x67, 0x20,
+0xe0, 0x62, 0xf9, 0x62, 0xec, 0x3b, 0x69, 0x6d, 0x65, 0x67, 0x20, 0x6d, 0x62, 0x259, 0x14b, 0x63, 0x68, 0x75, 0x62, 0x69,
+0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x6e, 0x67, 0x77, 0x259, 0x300, 0x74, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x66, 0x6f,
+0x67, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x69, 0x63, 0x68, 0x69, 0x69, 0x62, 0x254, 0x64, 0x3b, 0x69, 0x6d, 0x259, 0x67,
+0x20, 0xe0, 0x64, 0xf9, 0x6d, 0x62, 0x259, 0x300, 0x14b, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x69, 0x63, 0x68, 0x69, 0x6b,
+0x61, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x6b, 0x75, 0x64, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x74, 0xe8, 0x73, 0x69,
+0x2bc, 0x65, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x7a, 0xf2, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x6b, 0x72, 0x69, 0x7a,
+0x6d, 0x65, 0x64, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x6d, 0x62, 0x65, 0x67, 0x74, 0x75, 0x67, 0x3b, 0x69, 0x6d, 0x65,
+0x67, 0x20, 0xe0, 0x62, 0xf9, 0x62, 0xec, 0x3b, 0x69, 0x6d, 0x65, 0x67, 0x20, 0x6d, 0x62, 0x259, 0x14b, 0x63, 0x68, 0x75,
+0x62, 0x69, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x6e, 0x67, 0x77, 0x259, 0x300, 0x74, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20,
+0x66, 0x6f, 0x67, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x69, 0x63, 0x68, 0x69, 0x69, 0x62, 0x254, 0x64, 0x3b, 0x69, 0x6d,
+0x259, 0x67, 0x20, 0xe0, 0x64, 0xf9, 0x6d, 0x62, 0x259, 0x300, 0x14b, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x69, 0x63, 0x68,
+0x69, 0x6b, 0x61, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x6b, 0x75, 0x64, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x74, 0xe8,
+0x73, 0x69, 0x2bc, 0x65, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x7a, 0xf2, 0x3b, 0x69, 0x6d, 0x259, 0x67, 0x20, 0x6b, 0x72,
+0x69, 0x7a, 0x6d, 0x65, 0x64, 0x3b, 0x4d, 0x31, 0x3b, 0x41, 0x32, 0x3b, 0x4d, 0x33, 0x3b, 0x4e, 0x34, 0x3b, 0x46, 0x35,
+0x3b, 0x49, 0x36, 0x3b, 0x41, 0x37, 0x3b, 0x49, 0x38, 0x3b, 0x4b, 0x39, 0x3b, 0x31, 0x30, 0x3b, 0x31, 0x31, 0x3b, 0x31,
+0x32, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x74, 0x73, 0x65, 0x74, 0x73, 0x25b, 0x300, 0x25b, 0x20, 0x6c, 0xf9, 0x6d, 0x3b, 0x73,
+0x61, 0x14b, 0x20, 0x6b, 0xe0, 0x67, 0x20, 0x6e, 0x67, 0x77, 0xf3, 0x14b, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x6c, 0x65, 0x70,
+0x79, 0xe8, 0x20, 0x73, 0x68, 0xfa, 0x6d, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x63, 0xff, 0xf3, 0x3b, 0x73, 0x61, 0x14b, 0x20,
+0x74, 0x73, 0x25b, 0x300, 0x25b, 0x20, 0x63, 0xff, 0xf3, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x6e, 0x6a, 0xff, 0x6f, 0x6c, 0xe1,
+0x2bc, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x74, 0x79, 0x25b, 0x300, 0x62, 0x20, 0x74, 0x79, 0x25b, 0x300, 0x62, 0x20, 0x6d, 0x62,
+0x289, 0x300, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x6d, 0x62, 0x289, 0x300, 0x14b, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x6e, 0x67, 0x77,
+0x254, 0x300, 0x2bc, 0x20, 0x6d, 0x62, 0xff, 0x25b, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x74, 0xe0, 0x14b, 0x61, 0x20, 0x74, 0x73,
+0x65, 0x74, 0x73, 0xe1, 0x2bc, 0x3b, 0x73, 0x61, 0x14b, 0x20, 0x6d, 0x65, 0x6a, 0x77, 0x6f, 0x14b, 0xf3, 0x3b, 0x73, 0x61,
+0x14b, 0x20, 0x6c, 0xf9, 0x6d, 0x3b
};
static const ushort days_data[] = {
@@ -3181,201 +3458,206 @@ static const ushort days_data[] = {
0x1230, 0x3b, 0x121b, 0x3b, 0x1228, 0x3b, 0x1210, 0x3b, 0x12d3, 0x3b, 0x1245, 0x3b, 0x627, 0x644, 0x623, 0x62d, 0x62f, 0x3b, 0x627, 0x644,
0x627, 0x62b, 0x646, 0x64a, 0x646, 0x3b, 0x627, 0x644, 0x62b, 0x644, 0x627, 0x62b, 0x627, 0x621, 0x3b, 0x627, 0x644, 0x623, 0x631, 0x628,
0x639, 0x627, 0x621, 0x3b, 0x627, 0x644, 0x62e, 0x645, 0x64a, 0x633, 0x3b, 0x627, 0x644, 0x62c, 0x645, 0x639, 0x629, 0x3b, 0x627, 0x644,
-0x633, 0x628, 0x62a, 0x3b, 0x62d, 0x3b, 0x646, 0x3b, 0x62b, 0x3b, 0x631, 0x3b, 0x62e, 0x3b, 0x62c, 0x3b, 0x633, 0x3b, 0x53f, 0x56b,
-0x580, 0x3b, 0x535, 0x580, 0x56f, 0x3b, 0x535, 0x580, 0x584, 0x3b, 0x549, 0x578, 0x580, 0x3b, 0x540, 0x576, 0x563, 0x3b, 0x548, 0x582,
-0x580, 0x3b, 0x547, 0x561, 0x562, 0x3b, 0x53f, 0x56b, 0x580, 0x561, 0x56f, 0x56b, 0x3b, 0x535, 0x580, 0x56f, 0x578, 0x582, 0x577, 0x561,
-0x562, 0x569, 0x56b, 0x3b, 0x535, 0x580, 0x565, 0x584, 0x577, 0x561, 0x562, 0x569, 0x56b, 0x3b, 0x549, 0x578, 0x580, 0x565, 0x584, 0x577,
-0x561, 0x562, 0x569, 0x56b, 0x3b, 0x540, 0x56b, 0x576, 0x563, 0x577, 0x561, 0x562, 0x569, 0x56b, 0x3b, 0x548, 0x582, 0x580, 0x562, 0x561,
-0x569, 0x3b, 0x547, 0x561, 0x562, 0x561, 0x569, 0x3b, 0x31, 0x3b, 0x32, 0x3b, 0x33, 0x3b, 0x34, 0x3b, 0x35, 0x3b, 0x36, 0x3b,
-0x37, 0x3b, 0x9f0, 0x9ac, 0x9bf, 0x3b, 0x9b8, 0x9cb, 0x9ae, 0x3b, 0x9ae, 0x999, 0x9cd, 0x997, 0x9b2, 0x3b, 0x9ac, 0x9c1, 0x9a7, 0x3b,
-0x9ac, 0x9c3, 0x9b9, 0x9b7, 0x9cd, 0x9aa, 0x9a4, 0x9bf, 0x3b, 0x9b6, 0x9c1, 0x995, 0x9cd, 0x9f0, 0x3b, 0x9b6, 0x9a8, 0x9bf, 0x3b, 0x9a6,
-0x9c7, 0x993, 0x9ac, 0x9be, 0x9f0, 0x3b, 0x9b8, 0x9cb, 0x9ae, 0x9ac, 0x9be, 0x9f0, 0x3b, 0x9ae, 0x999, 0x9cd, 0x997, 0x9b2, 0x9ac, 0x9be,
-0x9f0, 0x3b, 0x9ac, 0x9c1, 0x9a7, 0x9ac, 0x9be, 0x9f0, 0x3b, 0x9ac, 0x9c3, 0x9b9, 0x9b7, 0x9cd, 0x9aa, 0x9a4, 0x9bf, 0x9ac, 0x9be, 0x9f0,
-0x3b, 0x9b6, 0x9c1, 0x995, 0x9cd, 0x9f0, 0x9ac, 0x9be, 0x9f0, 0x3b, 0x9b6, 0x9a8, 0x9bf, 0x9ac, 0x9be, 0x9f0, 0x3b, 0x42, 0x2e, 0x3b,
-0x42, 0x2e, 0x45, 0x2e, 0x3b, 0xc7, 0x2e, 0x41, 0x2e, 0x3b, 0xc7, 0x2e, 0x3b, 0x43, 0x2e, 0x41, 0x2e, 0x3b, 0x43, 0x3b,
-0x15e, 0x2e, 0x3b, 0x62, 0x61, 0x7a, 0x61, 0x72, 0x3b, 0x62, 0x61, 0x7a, 0x61, 0x72, 0x20, 0x65, 0x72, 0x74, 0x259, 0x73,
-0x69, 0x3b, 0xe7, 0x259, 0x72, 0x15f, 0x259, 0x6e, 0x62, 0x259, 0x20, 0x61, 0x78, 0x15f, 0x61, 0x6d, 0x131, 0x3b, 0xe7, 0x259,
-0x72, 0x15f, 0x259, 0x6e, 0x62, 0x259, 0x3b, 0x63, 0xfc, 0x6d, 0x259, 0x20, 0x61, 0x78, 0x15f, 0x61, 0x6d, 0x131, 0x3b, 0x63,
-0xfc, 0x6d, 0x259, 0x3b, 0x15f, 0x259, 0x6e, 0x62, 0x259, 0x3b, 0x431, 0x430, 0x437, 0x430, 0x440, 0x3b, 0x431, 0x430, 0x437, 0x430,
-0x440, 0x20, 0x435, 0x440, 0x442, 0x4d9, 0x441, 0x438, 0x3b, 0x447, 0x4d9, 0x440, 0x448, 0x4d9, 0x43d, 0x431, 0x4d9, 0x20, 0x430, 0x445,
-0x448, 0x430, 0x43c, 0x44b, 0x3b, 0x447, 0x4d9, 0x440, 0x448, 0x4d9, 0x43d, 0x431, 0x4d9, 0x3b, 0x4b9, 0x4af, 0x43c, 0x4d9, 0x20, 0x430,
-0x445, 0x448, 0x430, 0x43c, 0x44b, 0x3b, 0x4b9, 0x4af, 0x43c, 0x4d9, 0x3b, 0x448, 0x4d9, 0x43d, 0x431, 0x4d9, 0x3b, 0x69, 0x67, 0x3b,
-0x61, 0x6c, 0x3b, 0x61, 0x73, 0x3b, 0x61, 0x7a, 0x3b, 0x6f, 0x67, 0x3b, 0x6f, 0x72, 0x3b, 0x6c, 0x72, 0x3b, 0x69, 0x67,
-0x61, 0x6e, 0x64, 0x65, 0x61, 0x3b, 0x61, 0x73, 0x74, 0x65, 0x6c, 0x65, 0x68, 0x65, 0x6e, 0x61, 0x3b, 0x61, 0x73, 0x74,
-0x65, 0x61, 0x72, 0x74, 0x65, 0x61, 0x3b, 0x61, 0x73, 0x74, 0x65, 0x61, 0x7a, 0x6b, 0x65, 0x6e, 0x61, 0x3b, 0x6f, 0x73,
-0x74, 0x65, 0x67, 0x75, 0x6e, 0x61, 0x3b, 0x6f, 0x73, 0x74, 0x69, 0x72, 0x61, 0x6c, 0x61, 0x3b, 0x6c, 0x61, 0x72, 0x75,
-0x6e, 0x62, 0x61, 0x74, 0x61, 0x3b, 0x49, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4c, 0x3b, 0x41, 0x3b, 0x4f, 0x3b, 0x49, 0x3b,
-0x49, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x4f, 0x3b, 0x49, 0x3b, 0x9b0, 0x9ac, 0x9bf, 0x3b, 0x9b8, 0x9cb,
-0x9ae, 0x3b, 0x9ae, 0x999, 0x9cd, 0x997, 0x9b2, 0x3b, 0x9ac, 0x9c1, 0x9a7, 0x3b, 0x9ac, 0x9c3, 0x9b9, 0x9b8, 0x9cd, 0x9aa, 0x9a4, 0x9bf,
-0x3b, 0x9b6, 0x9c1, 0x995, 0x9cd, 0x9b0, 0x3b, 0x9b6, 0x9a8, 0x9bf, 0x3b, 0x9b0, 0x9ac, 0x9bf, 0x9ac, 0x9be, 0x9b0, 0x3b, 0x9b8, 0x9cb,
-0x9ae, 0x9ac, 0x9be, 0x9b0, 0x3b, 0x9ae, 0x999, 0x9cd, 0x997, 0x9b2, 0x9ac, 0x9be, 0x9b0, 0x3b, 0x9ac, 0x9c1, 0x9a7, 0x9ac, 0x9be, 0x9b0,
-0x3b, 0x9ac, 0x9c3, 0x9b9, 0x9b7, 0x9cd, 0x9aa, 0x9a4, 0x9bf, 0x9ac, 0x9be, 0x9b0, 0x3b, 0x9b6, 0x9c1, 0x995, 0x9cd, 0x9b0, 0x9ac, 0x9be,
-0x9b0, 0x3b, 0x9b6, 0x9a8, 0x9bf, 0x9ac, 0x9be, 0x9b0, 0x3b, 0x9b0, 0x3b, 0x9b8, 0x9cb, 0x3b, 0x9ae, 0x3b, 0x9ac, 0x9c1, 0x3b, 0x9ac,
-0x9c3, 0x3b, 0x9b6, 0x9c1, 0x3b, 0x9b6, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0x3b, 0xf58, 0xf72, 0xf62, 0xf0b, 0x3b, 0xf63, 0xfb7, 0xf42, 0xf0b,
-0x3b, 0xf55, 0xf74, 0xf62, 0xf0b, 0x3b, 0xf66, 0xf44, 0xf66, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xf7a, 0xf53, 0xf0b, 0x3b, 0xf49, 0xf72, 0xf0b,
-0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf58, 0xf72, 0xf42, 0xf0b, 0xf51,
-0xf58, 0xf62, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf63, 0xfb7, 0xf42, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf55,
-0xf74, 0xf62, 0xf0b, 0xf56, 0xf74, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf54, 0xf0b, 0xf66, 0xf44, 0xf66, 0xf0b, 0x3b, 0xf42, 0xf5f,
-0xf60, 0xf0b, 0xf66, 0xfa4, 0xf7a, 0xf53, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf49, 0xf72, 0xf0b, 0xf58, 0xf0b, 0x3b,
-0xf5f, 0xfb3, 0x3b, 0xf58, 0xf72, 0xf62, 0x3b, 0xf63, 0xfb7, 0xf42, 0x3b, 0xf55, 0xf74, 0xf62, 0x3b, 0xf66, 0xf44, 0xfb6, 0x3b, 0xf66,
-0xfa4, 0xf7a, 0xf53, 0x3b, 0xf49, 0xf72, 0x3b, 0x73, 0x75, 0x6c, 0x3b, 0x6c, 0x75, 0x6e, 0x3b, 0x6d, 0x65, 0x75, 0x2e, 0x3b,
-0x6d, 0x65, 0x72, 0x2e, 0x3b, 0x79, 0x61, 0x6f, 0x75, 0x3b, 0x67, 0x77, 0x65, 0x2e, 0x3b, 0x73, 0x61, 0x64, 0x2e, 0x3b,
-0x53, 0x75, 0x6c, 0x3b, 0x4c, 0x75, 0x6e, 0x3b, 0x4d, 0x65, 0x75, 0x72, 0x7a, 0x68, 0x3b, 0x4d, 0x65, 0x72, 0x63, 0x2bc,
-0x68, 0x65, 0x72, 0x3b, 0x59, 0x61, 0x6f, 0x75, 0x3b, 0x47, 0x77, 0x65, 0x6e, 0x65, 0x72, 0x3b, 0x53, 0x61, 0x64, 0x6f,
-0x72, 0x6e, 0x3b, 0x73, 0x75, 0x3b, 0x6c, 0x75, 0x3b, 0x6d, 0x7a, 0x3b, 0x6d, 0x63, 0x3b, 0x79, 0x61, 0x3b, 0x67, 0x77,
-0x3b, 0x73, 0x61, 0x3b, 0x43d, 0x434, 0x3b, 0x43f, 0x43d, 0x3b, 0x432, 0x442, 0x3b, 0x441, 0x440, 0x3b, 0x447, 0x442, 0x3b, 0x43f,
-0x442, 0x3b, 0x441, 0x431, 0x3b, 0x43d, 0x435, 0x434, 0x435, 0x43b, 0x44f, 0x3b, 0x43f, 0x43e, 0x43d, 0x435, 0x434, 0x435, 0x43b, 0x43d,
-0x438, 0x43a, 0x3b, 0x432, 0x442, 0x43e, 0x440, 0x43d, 0x438, 0x43a, 0x3b, 0x441, 0x440, 0x44f, 0x434, 0x430, 0x3b, 0x447, 0x435, 0x442,
-0x432, 0x44a, 0x440, 0x442, 0x44a, 0x43a, 0x3b, 0x43f, 0x435, 0x442, 0x44a, 0x43a, 0x3b, 0x441, 0x44a, 0x431, 0x43e, 0x442, 0x430, 0x3b,
-0x43d, 0x3b, 0x43f, 0x3b, 0x432, 0x3b, 0x441, 0x3b, 0x447, 0x3b, 0x43f, 0x3b, 0x441, 0x3b, 0x1014, 0x103d, 0x1031, 0x3b, 0x101c, 0x102c,
-0x3b, 0x1002, 0x102b, 0x3b, 0x101f, 0x1030, 0x1038, 0x3b, 0x1010, 0x1031, 0x1038, 0x3b, 0x1000, 0x103c, 0x102c, 0x3b, 0x1014, 0x1031, 0x3b, 0x1010,
-0x1014, 0x1004, 0x103a, 0x1039, 0x1002, 0x1014, 0x103d, 0x1031, 0x3b, 0x1010, 0x1014, 0x1004, 0x103a, 0x1039, 0x101c, 0x102c, 0x3b, 0x1021, 0x1004, 0x103a,
-0x1039, 0x1002, 0x102b, 0x3b, 0x1017, 0x102f, 0x1012, 0x1039, 0x1013, 0x101f, 0x1030, 0x1038, 0x3b, 0x1000, 0x103c, 0x102c, 0x101e, 0x1015, 0x1010, 0x1031,
-0x1038, 0x3b, 0x101e, 0x1031, 0x102c, 0x1000, 0x103c, 0x102c, 0x3b, 0x1005, 0x1014, 0x1031, 0x3b, 0x1010, 0x3b, 0x1010, 0x3b, 0x1021, 0x3b, 0x1017,
-0x3b, 0x1000, 0x3b, 0x101e, 0x3b, 0x1005, 0x3b, 0x43d, 0x434, 0x3b, 0x43f, 0x43d, 0x3b, 0x430, 0x45e, 0x3b, 0x441, 0x440, 0x3b, 0x447,
-0x446, 0x3b, 0x43f, 0x442, 0x3b, 0x441, 0x431, 0x3b, 0x43d, 0x44f, 0x434, 0x437, 0x435, 0x43b, 0x44f, 0x3b, 0x43f, 0x430, 0x43d, 0x44f,
-0x434, 0x437, 0x435, 0x43b, 0x430, 0x43a, 0x3b, 0x430, 0x45e, 0x442, 0x43e, 0x440, 0x430, 0x43a, 0x3b, 0x441, 0x435, 0x440, 0x430, 0x434,
-0x430, 0x3b, 0x447, 0x430, 0x446, 0x432, 0x435, 0x440, 0x3b, 0x43f, 0x44f, 0x442, 0x43d, 0x456, 0x446, 0x430, 0x3b, 0x441, 0x443, 0x431,
-0x43e, 0x442, 0x430, 0x3b, 0x43d, 0x3b, 0x43f, 0x3b, 0x430, 0x3b, 0x441, 0x3b, 0x447, 0x3b, 0x43f, 0x3b, 0x441, 0x3b, 0x17a2, 0x17b6,
-0x1791, 0x17b7, 0x178f, 0x17d2, 0x1799, 0x3b, 0x1785, 0x1793, 0x17d2, 0x1791, 0x3b, 0x17a2, 0x1784, 0x17d2, 0x1782, 0x17b6, 0x179a, 0x3b, 0x1796, 0x17bb,
-0x1792, 0x3b, 0x1796, 0x17d2, 0x179a, 0x17a0, 0x179f, 0x17d2, 0x1794, 0x178f, 0x17b7, 0x17cd, 0x3b, 0x179f, 0x17bb, 0x1780, 0x17d2, 0x179a, 0x3b, 0x179f,
-0x17c5, 0x179a, 0x17cd, 0x3b, 0x64, 0x67, 0x3b, 0x64, 0x6c, 0x3b, 0x64, 0x74, 0x3b, 0x64, 0x63, 0x3b, 0x64, 0x6a, 0x3b, 0x64,
-0x76, 0x3b, 0x64, 0x73, 0x3b, 0x44, 0x69, 0x75, 0x6d, 0x65, 0x6e, 0x67, 0x65, 0x3b, 0x44, 0x69, 0x6c, 0x6c, 0x75, 0x6e,
-0x73, 0x3b, 0x44, 0x69, 0x6d, 0x61, 0x72, 0x74, 0x73, 0x3b, 0x44, 0x69, 0x6d, 0x65, 0x63, 0x72, 0x65, 0x73, 0x3b, 0x44,
-0x69, 0x6a, 0x6f, 0x75, 0x73, 0x3b, 0x44, 0x69, 0x76, 0x65, 0x6e, 0x64, 0x72, 0x65, 0x73, 0x3b, 0x44, 0x69, 0x73, 0x73,
-0x61, 0x62, 0x74, 0x65, 0x3b, 0x64, 0x67, 0x2e, 0x3b, 0x64, 0x6c, 0x2e, 0x3b, 0x64, 0x74, 0x2e, 0x3b, 0x64, 0x63, 0x2e,
-0x3b, 0x64, 0x6a, 0x2e, 0x3b, 0x64, 0x76, 0x2e, 0x3b, 0x64, 0x73, 0x2e, 0x3b, 0x64, 0x69, 0x75, 0x6d, 0x65, 0x6e, 0x67,
-0x65, 0x3b, 0x64, 0x69, 0x6c, 0x6c, 0x75, 0x6e, 0x73, 0x3b, 0x64, 0x69, 0x6d, 0x61, 0x72, 0x74, 0x73, 0x3b, 0x64, 0x69,
-0x6d, 0x65, 0x63, 0x72, 0x65, 0x73, 0x3b, 0x64, 0x69, 0x6a, 0x6f, 0x75, 0x73, 0x3b, 0x64, 0x69, 0x76, 0x65, 0x6e, 0x64,
-0x72, 0x65, 0x73, 0x3b, 0x64, 0x69, 0x73, 0x73, 0x61, 0x62, 0x74, 0x65, 0x3b, 0x5468, 0x65e5, 0x3b, 0x5468, 0x4e00, 0x3b, 0x5468,
-0x4e8c, 0x3b, 0x5468, 0x4e09, 0x3b, 0x5468, 0x56db, 0x3b, 0x5468, 0x4e94, 0x3b, 0x5468, 0x516d, 0x3b, 0x661f, 0x671f, 0x65e5, 0x3b, 0x661f, 0x671f,
-0x4e00, 0x3b, 0x661f, 0x671f, 0x4e8c, 0x3b, 0x661f, 0x671f, 0x4e09, 0x3b, 0x661f, 0x671f, 0x56db, 0x3b, 0x661f, 0x671f, 0x4e94, 0x3b, 0x661f, 0x671f,
-0x516d, 0x3b, 0x65e5, 0x3b, 0x4e00, 0x3b, 0x4e8c, 0x3b, 0x4e09, 0x3b, 0x56db, 0x3b, 0x4e94, 0x3b, 0x516d, 0x3b, 0x9031, 0x65e5, 0x3b, 0x9031,
-0x4e00, 0x3b, 0x9031, 0x4e8c, 0x3b, 0x9031, 0x4e09, 0x3b, 0x9031, 0x56db, 0x3b, 0x9031, 0x4e94, 0x3b, 0x9031, 0x516d, 0x3b, 0x6e, 0x65, 0x64,
-0x3b, 0x70, 0x6f, 0x6e, 0x3b, 0x75, 0x74, 0x6f, 0x3b, 0x73, 0x72, 0x69, 0x3b, 0x10d, 0x65, 0x74, 0x3b, 0x70, 0x65, 0x74,
-0x3b, 0x73, 0x75, 0x62, 0x3b, 0x6e, 0x65, 0x64, 0x6a, 0x65, 0x6c, 0x6a, 0x61, 0x3b, 0x70, 0x6f, 0x6e, 0x65, 0x64, 0x6a,
-0x65, 0x6c, 0x6a, 0x61, 0x6b, 0x3b, 0x75, 0x74, 0x6f, 0x72, 0x61, 0x6b, 0x3b, 0x73, 0x72, 0x69, 0x6a, 0x65, 0x64, 0x61,
-0x3b, 0x10d, 0x65, 0x74, 0x76, 0x72, 0x74, 0x61, 0x6b, 0x3b, 0x70, 0x65, 0x74, 0x61, 0x6b, 0x3b, 0x73, 0x75, 0x62, 0x6f,
-0x74, 0x61, 0x3b, 0x6e, 0x3b, 0x70, 0x3b, 0x75, 0x3b, 0x73, 0x3b, 0x10d, 0x3b, 0x70, 0x3b, 0x73, 0x3b, 0x4e, 0x3b, 0x50,
-0x3b, 0x55, 0x3b, 0x53, 0x3b, 0x10c, 0x3b, 0x50, 0x3b, 0x53, 0x3b, 0x6e, 0x65, 0x3b, 0x70, 0x6f, 0x3b, 0xfa, 0x74, 0x3b,
-0x73, 0x74, 0x3b, 0x10d, 0x74, 0x3b, 0x70, 0xe1, 0x3b, 0x73, 0x6f, 0x3b, 0x6e, 0x65, 0x64, 0x11b, 0x6c, 0x65, 0x3b, 0x70,
-0x6f, 0x6e, 0x64, 0x11b, 0x6c, 0xed, 0x3b, 0xfa, 0x74, 0x65, 0x72, 0xfd, 0x3b, 0x73, 0x74, 0x159, 0x65, 0x64, 0x61, 0x3b,
-0x10d, 0x74, 0x76, 0x72, 0x74, 0x65, 0x6b, 0x3b, 0x70, 0xe1, 0x74, 0x65, 0x6b, 0x3b, 0x73, 0x6f, 0x62, 0x6f, 0x74, 0x61,
-0x3b, 0x4e, 0x3b, 0x50, 0x3b, 0xda, 0x3b, 0x53, 0x3b, 0x10c, 0x3b, 0x50, 0x3b, 0x53, 0x3b, 0x73, 0xf8, 0x6e, 0x3b, 0x6d,
-0x61, 0x6e, 0x3b, 0x74, 0x69, 0x72, 0x3b, 0x6f, 0x6e, 0x73, 0x3b, 0x74, 0x6f, 0x72, 0x3b, 0x66, 0x72, 0x65, 0x3b, 0x6c,
-0xf8, 0x72, 0x3b, 0x73, 0xf8, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x6d, 0x61, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x74, 0x69, 0x72,
-0x73, 0x64, 0x61, 0x67, 0x3b, 0x6f, 0x6e, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x74, 0x6f, 0x72, 0x73, 0x64, 0x61, 0x67, 0x3b,
-0x66, 0x72, 0x65, 0x64, 0x61, 0x67, 0x3b, 0x6c, 0xf8, 0x72, 0x64, 0x61, 0x67, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x54, 0x3b,
-0x4f, 0x3b, 0x54, 0x3b, 0x46, 0x3b, 0x4c, 0x3b, 0x73, 0xf8, 0x6e, 0x2e, 0x3b, 0x6d, 0x61, 0x6e, 0x2e, 0x3b, 0x74, 0x69,
-0x72, 0x2e, 0x3b, 0x6f, 0x6e, 0x73, 0x2e, 0x3b, 0x74, 0x6f, 0x72, 0x2e, 0x3b, 0x66, 0x72, 0x65, 0x2e, 0x3b, 0x6c, 0xf8,
-0x72, 0x2e, 0x3b, 0x7a, 0x6f, 0x3b, 0x6d, 0x61, 0x3b, 0x64, 0x69, 0x3b, 0x77, 0x6f, 0x3b, 0x64, 0x6f, 0x3b, 0x76, 0x72,
-0x3b, 0x7a, 0x61, 0x3b, 0x7a, 0x6f, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x6d, 0x61, 0x61, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x64,
-0x69, 0x6e, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x77, 0x6f, 0x65, 0x6e, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x64, 0x6f, 0x6e, 0x64,
-0x65, 0x72, 0x64, 0x61, 0x67, 0x3b, 0x76, 0x72, 0x69, 0x6a, 0x64, 0x61, 0x67, 0x3b, 0x7a, 0x61, 0x74, 0x65, 0x72, 0x64,
-0x61, 0x67, 0x3b, 0x5a, 0x3b, 0x4d, 0x3b, 0x44, 0x3b, 0x57, 0x3b, 0x44, 0x3b, 0x56, 0x3b, 0x5a, 0x3b, 0xd801, 0xdc1d, 0xd801,
-0xdc32, 0xd801, 0xdc4c, 0x3b, 0xd801, 0xdc23, 0xd801, 0xdc32, 0xd801, 0xdc4c, 0x3b, 0xd801, 0xdc13, 0xd801, 0xdc2d, 0xd801, 0xdc46, 0x3b, 0xd801, 0xdc0e,
-0xd801, 0xdc2f, 0xd801, 0xdc4c, 0x3b, 0xd801, 0xdc1b, 0xd801, 0xdc32, 0xd801, 0xdc49, 0x3b, 0xd801, 0xdc19, 0xd801, 0xdc49, 0xd801, 0xdc34, 0x3b, 0xd801,
-0xdc1d, 0xd801, 0xdc30, 0xd801, 0xdc3b, 0x3b, 0xd801, 0xdc1d, 0xd801, 0xdc32, 0xd801, 0xdc4c, 0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc23, 0xd801,
-0xdc32, 0xd801, 0xdc4c, 0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc13, 0xd801, 0xdc2d, 0xd801, 0xdc46, 0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b, 0xd801,
-0xdc0e, 0xd801, 0xdc2f, 0xd801, 0xdc4c, 0xd801, 0xdc46, 0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc1b, 0xd801, 0xdc32, 0xd801, 0xdc49, 0xd801, 0xdc46,
-0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc19, 0xd801, 0xdc49, 0xd801, 0xdc34, 0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc1d, 0xd801, 0xdc30,
-0xd801, 0xdc3b, 0xd801, 0xdc32, 0xd801, 0xdc49, 0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc1d, 0x3b, 0xd801, 0xdc23, 0x3b, 0xd801, 0xdc13, 0x3b,
-0xd801, 0xdc0e, 0x3b, 0xd801, 0xdc1b, 0x3b, 0xd801, 0xdc19, 0x3b, 0xd801, 0xdc1d, 0x3b, 0x50, 0x3b, 0x45, 0x3b, 0x54, 0x3b, 0x4b, 0x3b,
-0x4e, 0x3b, 0x52, 0x3b, 0x4c, 0x3b, 0x70, 0xfc, 0x68, 0x61, 0x70, 0xe4, 0x65, 0x76, 0x3b, 0x65, 0x73, 0x6d, 0x61, 0x73,
-0x70, 0xe4, 0x65, 0x76, 0x3b, 0x74, 0x65, 0x69, 0x73, 0x69, 0x70, 0xe4, 0x65, 0x76, 0x3b, 0x6b, 0x6f, 0x6c, 0x6d, 0x61,
-0x70, 0xe4, 0x65, 0x76, 0x3b, 0x6e, 0x65, 0x6c, 0x6a, 0x61, 0x70, 0xe4, 0x65, 0x76, 0x3b, 0x72, 0x65, 0x65, 0x64, 0x65,
-0x3b, 0x6c, 0x61, 0x75, 0x70, 0xe4, 0x65, 0x76, 0x3b, 0x73, 0x75, 0x6e, 0x3b, 0x6d, 0xe1, 0x6e, 0x3b, 0x74, 0xfd, 0x73,
-0x3b, 0x6d, 0x69, 0x6b, 0x3b, 0x68, 0xf3, 0x73, 0x3b, 0x66, 0x72, 0xed, 0x3b, 0x6c, 0x65, 0x79, 0x3b, 0x73, 0x75, 0x6e,
-0x6e, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x6d, 0xe1, 0x6e, 0x61, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x74, 0xfd,
-0x73, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x6d, 0x69, 0x6b, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x68, 0xf3, 0x73,
-0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x66, 0x72, 0xed, 0x67, 0x67, 0x6a, 0x61, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x6c,
-0x65, 0x79, 0x67, 0x61, 0x72, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x54, 0x3b, 0x4d, 0x3b, 0x48,
-0x3b, 0x46, 0x3b, 0x4c, 0x3b, 0x73, 0x75, 0x3b, 0x6d, 0x61, 0x3b, 0x74, 0x69, 0x3b, 0x6b, 0x65, 0x3b, 0x74, 0x6f, 0x3b,
-0x70, 0x65, 0x3b, 0x6c, 0x61, 0x3b, 0x73, 0x75, 0x6e, 0x6e, 0x75, 0x6e, 0x74, 0x61, 0x69, 0x3b, 0x6d, 0x61, 0x61, 0x6e,
-0x61, 0x6e, 0x74, 0x61, 0x69, 0x3b, 0x74, 0x69, 0x69, 0x73, 0x74, 0x61, 0x69, 0x3b, 0x6b, 0x65, 0x73, 0x6b, 0x69, 0x76,
-0x69, 0x69, 0x6b, 0x6b, 0x6f, 0x3b, 0x74, 0x6f, 0x72, 0x73, 0x74, 0x61, 0x69, 0x3b, 0x70, 0x65, 0x72, 0x6a, 0x61, 0x6e,
-0x74, 0x61, 0x69, 0x3b, 0x6c, 0x61, 0x75, 0x61, 0x6e, 0x74, 0x61, 0x69, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x54, 0x3b, 0x4b,
-0x3b, 0x54, 0x3b, 0x50, 0x3b, 0x4c, 0x3b, 0x73, 0x75, 0x6e, 0x6e, 0x75, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x61, 0x3b, 0x6d,
-0x61, 0x61, 0x6e, 0x61, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x61, 0x3b, 0x74, 0x69, 0x69, 0x73, 0x74, 0x61, 0x69, 0x6e, 0x61,
-0x3b, 0x6b, 0x65, 0x73, 0x6b, 0x69, 0x76, 0x69, 0x69, 0x6b, 0x6b, 0x6f, 0x6e, 0x61, 0x3b, 0x74, 0x6f, 0x72, 0x73, 0x74,
-0x61, 0x69, 0x6e, 0x61, 0x3b, 0x70, 0x65, 0x72, 0x6a, 0x61, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x61, 0x3b, 0x6c, 0x61, 0x75,
-0x61, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x61, 0x3b, 0x64, 0x69, 0x6d, 0x2e, 0x3b, 0x6c, 0x75, 0x6e, 0x2e, 0x3b, 0x6d, 0x61,
-0x72, 0x2e, 0x3b, 0x6d, 0x65, 0x72, 0x2e, 0x3b, 0x6a, 0x65, 0x75, 0x2e, 0x3b, 0x76, 0x65, 0x6e, 0x2e, 0x3b, 0x73, 0x61,
-0x6d, 0x2e, 0x3b, 0x64, 0x69, 0x6d, 0x61, 0x6e, 0x63, 0x68, 0x65, 0x3b, 0x6c, 0x75, 0x6e, 0x64, 0x69, 0x3b, 0x6d, 0x61,
-0x72, 0x64, 0x69, 0x3b, 0x6d, 0x65, 0x72, 0x63, 0x72, 0x65, 0x64, 0x69, 0x3b, 0x6a, 0x65, 0x75, 0x64, 0x69, 0x3b, 0x76,
-0x65, 0x6e, 0x64, 0x72, 0x65, 0x64, 0x69, 0x3b, 0x73, 0x61, 0x6d, 0x65, 0x64, 0x69, 0x3b, 0x44, 0x3b, 0x4c, 0x3b, 0x4d,
-0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x56, 0x3b, 0x53, 0x3b, 0x44, 0x69, 0x44, 0x3b, 0x44, 0x69, 0x4c, 0x3b, 0x44, 0x69, 0x4d,
-0x3b, 0x44, 0x69, 0x43, 0x3b, 0x44, 0x69, 0x61, 0x3b, 0x44, 0x69, 0x68, 0x3b, 0x44, 0x69, 0x53, 0x3b, 0x44, 0x69, 0x44,
-0xf2, 0x6d, 0x68, 0x6e, 0x61, 0x69, 0x63, 0x68, 0x3b, 0x44, 0x69, 0x4c, 0x75, 0x61, 0x69, 0x6e, 0x3b, 0x44, 0x69, 0x4d,
-0xe0, 0x69, 0x72, 0x74, 0x3b, 0x44, 0x69, 0x43, 0x69, 0x61, 0x64, 0x61, 0x69, 0x6e, 0x3b, 0x44, 0x69, 0x61, 0x72, 0x64,
-0x61, 0x6f, 0x69, 0x6e, 0x3b, 0x44, 0x69, 0x68, 0x41, 0x6f, 0x69, 0x6e, 0x65, 0x3b, 0x44, 0x69, 0x53, 0x61, 0x74, 0x68,
-0x61, 0x69, 0x72, 0x6e, 0x65, 0x3b, 0x44, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x43, 0x3b, 0x41, 0x3b, 0x48, 0x3b, 0x53, 0x3b,
-0x44, 0x6f, 0x6d, 0x3b, 0x4c, 0x75, 0x6e, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x4d, 0xe9, 0x72, 0x3b, 0x58, 0x6f, 0x76, 0x3b,
-0x56, 0x65, 0x6e, 0x3b, 0x53, 0xe1, 0x62, 0x3b, 0x44, 0x6f, 0x6d, 0x69, 0x6e, 0x67, 0x6f, 0x3b, 0x4c, 0x75, 0x6e, 0x73,
-0x3b, 0x4d, 0x61, 0x72, 0x74, 0x65, 0x73, 0x3b, 0x4d, 0xe9, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x73, 0x3b, 0x58, 0x6f, 0x76,
-0x65, 0x73, 0x3b, 0x56, 0x65, 0x6e, 0x72, 0x65, 0x73, 0x3b, 0x53, 0xe1, 0x62, 0x61, 0x64, 0x6f, 0x3b, 0x44, 0x3b, 0x4c,
-0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x58, 0x3b, 0x56, 0x3b, 0x53, 0x3b, 0x10d9, 0x10d5, 0x10d8, 0x3b, 0x10dd, 0x10e0, 0x10e8, 0x3b, 0x10e1,
-0x10d0, 0x10db, 0x3b, 0x10dd, 0x10d7, 0x10ee, 0x3b, 0x10ee, 0x10e3, 0x10d7, 0x3b, 0x10de, 0x10d0, 0x10e0, 0x3b, 0x10e8, 0x10d0, 0x10d1, 0x3b, 0x10d9,
-0x10d5, 0x10d8, 0x10e0, 0x10d0, 0x3b, 0x10dd, 0x10e0, 0x10e8, 0x10d0, 0x10d1, 0x10d0, 0x10d7, 0x10d8, 0x3b, 0x10e1, 0x10d0, 0x10db, 0x10e8, 0x10d0, 0x10d1,
-0x10d0, 0x10d7, 0x10d8, 0x3b, 0x10dd, 0x10d7, 0x10ee, 0x10e8, 0x10d0, 0x10d1, 0x10d0, 0x10d7, 0x10d8, 0x3b, 0x10ee, 0x10e3, 0x10d7, 0x10e8, 0x10d0, 0x10d1,
-0x10d0, 0x10d7, 0x10d8, 0x3b, 0x10de, 0x10d0, 0x10e0, 0x10d0, 0x10e1, 0x10d9, 0x10d4, 0x10d5, 0x10d8, 0x3b, 0x10e8, 0x10d0, 0x10d1, 0x10d0, 0x10d7, 0x10d8,
-0x3b, 0x10d9, 0x3b, 0x10dd, 0x3b, 0x10e1, 0x3b, 0x10dd, 0x3b, 0x10ee, 0x3b, 0x10de, 0x3b, 0x10e8, 0x3b, 0x53, 0x6f, 0x3b, 0x4d, 0x6f,
-0x3b, 0x44, 0x69, 0x3b, 0x4d, 0x69, 0x3b, 0x44, 0x6f, 0x3b, 0x46, 0x72, 0x3b, 0x53, 0x61, 0x3b, 0x53, 0x6f, 0x6e, 0x6e,
-0x74, 0x61, 0x67, 0x3b, 0x4d, 0x6f, 0x6e, 0x74, 0x61, 0x67, 0x3b, 0x44, 0x69, 0x65, 0x6e, 0x73, 0x74, 0x61, 0x67, 0x3b,
-0x4d, 0x69, 0x74, 0x74, 0x77, 0x6f, 0x63, 0x68, 0x3b, 0x44, 0x6f, 0x6e, 0x6e, 0x65, 0x72, 0x73, 0x74, 0x61, 0x67, 0x3b,
-0x46, 0x72, 0x65, 0x69, 0x74, 0x61, 0x67, 0x3b, 0x53, 0x61, 0x6d, 0x73, 0x74, 0x61, 0x67, 0x3b, 0x53, 0x3b, 0x4d, 0x3b,
-0x44, 0x3b, 0x4d, 0x3b, 0x44, 0x3b, 0x46, 0x3b, 0x53, 0x3b, 0x53, 0x6f, 0x2e, 0x3b, 0x4d, 0x6f, 0x2e, 0x3b, 0x44, 0x69,
-0x2e, 0x3b, 0x4d, 0x69, 0x2e, 0x3b, 0x44, 0x6f, 0x2e, 0x3b, 0x46, 0x72, 0x2e, 0x3b, 0x53, 0x61, 0x2e, 0x3b, 0x39a, 0x3c5,
-0x3c1, 0x3b, 0x394, 0x3b5, 0x3c5, 0x3b, 0x3a4, 0x3c1, 0x3af, 0x3b, 0x3a4, 0x3b5, 0x3c4, 0x3b, 0x3a0, 0x3ad, 0x3bc, 0x3b, 0x3a0, 0x3b1,
-0x3c1, 0x3b, 0x3a3, 0x3ac, 0x3b2, 0x3b, 0x39a, 0x3c5, 0x3c1, 0x3b9, 0x3b1, 0x3ba, 0x3ae, 0x3b, 0x394, 0x3b5, 0x3c5, 0x3c4, 0x3ad, 0x3c1,
-0x3b1, 0x3b, 0x3a4, 0x3c1, 0x3af, 0x3c4, 0x3b7, 0x3b, 0x3a4, 0x3b5, 0x3c4, 0x3ac, 0x3c1, 0x3c4, 0x3b7, 0x3b, 0x3a0, 0x3ad, 0x3bc, 0x3c0,
-0x3c4, 0x3b7, 0x3b, 0x3a0, 0x3b1, 0x3c1, 0x3b1, 0x3c3, 0x3ba, 0x3b5, 0x3c5, 0x3ae, 0x3b, 0x3a3, 0x3ac, 0x3b2, 0x3b2, 0x3b1, 0x3c4, 0x3bf,
-0x3b, 0x39a, 0x3b, 0x394, 0x3b, 0x3a4, 0x3b, 0x3a4, 0x3b, 0x3a0, 0x3b, 0x3a0, 0x3b, 0x3a3, 0x3b, 0x73, 0x61, 0x62, 0x3b, 0x61,
-0x74, 0x61, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x70, 0x69, 0x6e, 0x3b, 0x73, 0x69, 0x73, 0x3b, 0x74, 0x61, 0x6c, 0x3b, 0x61,
-0x72, 0x66, 0x3b, 0x73, 0x61, 0x62, 0x61, 0x61, 0x74, 0x3b, 0x61, 0x74, 0x61, 0x61, 0x73, 0x69, 0x6e, 0x6e, 0x67, 0x6f,
-0x72, 0x6e, 0x65, 0x71, 0x3b, 0x6d, 0x61, 0x72, 0x6c, 0x75, 0x6e, 0x6e, 0x67, 0x6f, 0x72, 0x6e, 0x65, 0x71, 0x3b, 0x70,
-0x69, 0x6e, 0x67, 0x61, 0x73, 0x75, 0x6e, 0x6e, 0x67, 0x6f, 0x72, 0x6e, 0x65, 0x71, 0x3b, 0x73, 0x69, 0x73, 0x61, 0x6d,
-0x61, 0x6e, 0x6e, 0x67, 0x6f, 0x72, 0x6e, 0x65, 0x71, 0x3b, 0x74, 0x61, 0x6c, 0x6c, 0x69, 0x6d, 0x61, 0x6e, 0x6e, 0x67,
-0x6f, 0x72, 0x6e, 0x65, 0x71, 0x3b, 0x61, 0x72, 0x66, 0x69, 0x6e, 0x69, 0x6e, 0x6e, 0x67, 0x6f, 0x72, 0x6e, 0x65, 0x71,
-0x3b, 0x53, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x50, 0x3b, 0x53, 0x3b, 0x54, 0x3b, 0x41, 0x3b, 0xab0, 0xab5, 0xabf, 0x3b, 0xab8,
-0xacb, 0xaae, 0x3b, 0xaae, 0xa82, 0xa97, 0xab3, 0x3b, 0xaac, 0xac1, 0xaa7, 0x3b, 0xa97, 0xac1, 0xab0, 0xac1, 0x3b, 0xab6, 0xac1, 0xa95,
-0xacd, 0xab0, 0x3b, 0xab6, 0xaa8, 0xabf, 0x3b, 0xab0, 0xab5, 0xabf, 0xab5, 0xabe, 0xab0, 0x3b, 0xab8, 0xacb, 0xaae, 0xab5, 0xabe, 0xab0,
-0x3b, 0xaae, 0xa82, 0xa97, 0xab3, 0xab5, 0xabe, 0xab0, 0x3b, 0xaac, 0xac1, 0xaa7, 0xab5, 0xabe, 0xab0, 0x3b, 0xa97, 0xac1, 0xab0, 0xac1,
-0xab5, 0xabe, 0xab0, 0x3b, 0xab6, 0xac1, 0xa95, 0xacd, 0xab0, 0xab5, 0xabe, 0xab0, 0x3b, 0xab6, 0xaa8, 0xabf, 0xab5, 0xabe, 0xab0, 0x3b,
-0xab0, 0x3b, 0xab8, 0xacb, 0x3b, 0xaae, 0xa82, 0x3b, 0xaac, 0xac1, 0x3b, 0xa97, 0xac1, 0x3b, 0xab6, 0xac1, 0x3b, 0xab6, 0x3b, 0x4c,
-0x68, 0x3b, 0x4c, 0x69, 0x3b, 0x54, 0x61, 0x3b, 0x4c, 0x72, 0x3b, 0x41, 0x6c, 0x3b, 0x4a, 0x75, 0x3b, 0x41, 0x73, 0x3b,
-0x4c, 0x61, 0x68, 0x61, 0x64, 0x69, 0x3b, 0x4c, 0x69, 0x74, 0x69, 0x6e, 0x69, 0x6e, 0x3b, 0x54, 0x61, 0x6c, 0x61, 0x74,
-0x61, 0x3b, 0x4c, 0x61, 0x72, 0x61, 0x62, 0x61, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x73, 0x3b, 0x4a, 0x75, 0x6d,
-0x6d, 0x61, 0x27, 0x61, 0x3b, 0x41, 0x73, 0x61, 0x62, 0x61, 0x72, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x54, 0x3b, 0x4c, 0x3b,
-0x41, 0x3b, 0x4a, 0x3b, 0x41, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d0, 0x5f3, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d1, 0x5f3, 0x3b,
-0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d2, 0x5f3, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d3, 0x5f3, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d4, 0x5f3,
-0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d5, 0x5f3, 0x3b, 0x5e9, 0x5d1, 0x5ea, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5e8, 0x5d0, 0x5e9, 0x5d5,
-0x5df, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5e9, 0x5e0, 0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5e9, 0x5dc, 0x5d9, 0x5e9, 0x5d9, 0x3b,
-0x5d9, 0x5d5, 0x5dd, 0x20, 0x5e8, 0x5d1, 0x5d9, 0x5e2, 0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d7, 0x5de, 0x5d9, 0x5e9, 0x5d9, 0x3b,
-0x5d9, 0x5d5, 0x5dd, 0x20, 0x5e9, 0x5d9, 0x5e9, 0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5e9, 0x5d1, 0x5ea, 0x3b, 0x5d0, 0x5f3, 0x3b,
-0x5d1, 0x5f3, 0x3b, 0x5d2, 0x5f3, 0x3b, 0x5d3, 0x5f3, 0x3b, 0x5d4, 0x5f3, 0x3b, 0x5d5, 0x3b, 0x5e9, 0x3b, 0x5d0, 0x27, 0x3b, 0x5d1,
-0x27, 0x3b, 0x5d2, 0x27, 0x3b, 0x5d3, 0x27, 0x3b, 0x5d4, 0x27, 0x3b, 0x5d5, 0x5f3, 0x3b, 0x5e9, 0x5f3, 0x3b, 0x930, 0x935, 0x93f,
-0x2e, 0x3b, 0x938, 0x94b, 0x92e, 0x2e, 0x3b, 0x92e, 0x902, 0x917, 0x932, 0x2e, 0x3b, 0x92c, 0x941, 0x927, 0x2e, 0x3b, 0x92c, 0x943,
-0x939, 0x2e, 0x3b, 0x936, 0x941, 0x915, 0x94d, 0x930, 0x2e, 0x3b, 0x936, 0x928, 0x93f, 0x2e, 0x3b, 0x930, 0x935, 0x93f, 0x935, 0x93e,
-0x930, 0x3b, 0x938, 0x94b, 0x92e, 0x935, 0x93e, 0x930, 0x3b, 0x92e, 0x902, 0x917, 0x932, 0x935, 0x93e, 0x930, 0x3b, 0x92c, 0x941, 0x927,
-0x935, 0x93e, 0x930, 0x3b, 0x92c, 0x943, 0x939, 0x938, 0x94d, 0x92a, 0x924, 0x93f, 0x935, 0x93e, 0x930, 0x3b, 0x936, 0x941, 0x915, 0x94d,
-0x930, 0x935, 0x93e, 0x930, 0x3b, 0x936, 0x928, 0x93f, 0x935, 0x93e, 0x930, 0x3b, 0x930, 0x3b, 0x938, 0x94b, 0x3b, 0x92e, 0x902, 0x3b,
-0x92c, 0x941, 0x3b, 0x917, 0x941, 0x3b, 0x936, 0x941, 0x3b, 0x936, 0x3b, 0x56, 0x3b, 0x48, 0x3b, 0x4b, 0x3b, 0x53, 0x7a, 0x65,
-0x3b, 0x43, 0x73, 0x3b, 0x50, 0x3b, 0x53, 0x7a, 0x6f, 0x3b, 0x76, 0x61, 0x73, 0xe1, 0x72, 0x6e, 0x61, 0x70, 0x3b, 0x68,
-0xe9, 0x74, 0x66, 0x151, 0x3b, 0x6b, 0x65, 0x64, 0x64, 0x3b, 0x73, 0x7a, 0x65, 0x72, 0x64, 0x61, 0x3b, 0x63, 0x73, 0xfc,
-0x74, 0xf6, 0x72, 0x74, 0xf6, 0x6b, 0x3b, 0x70, 0xe9, 0x6e, 0x74, 0x65, 0x6b, 0x3b, 0x73, 0x7a, 0x6f, 0x6d, 0x62, 0x61,
-0x74, 0x3b, 0x56, 0x3b, 0x48, 0x3b, 0x4b, 0x3b, 0x53, 0x7a, 0x3b, 0x43, 0x73, 0x3b, 0x50, 0x3b, 0x53, 0x7a, 0x3b, 0x73,
-0x75, 0x6e, 0x3b, 0x6d, 0xe1, 0x6e, 0x3b, 0xfe, 0x72, 0x69, 0x3b, 0x6d, 0x69, 0xf0, 0x3b, 0x66, 0x69, 0x6d, 0x3b, 0x66,
-0xf6, 0x73, 0x3b, 0x6c, 0x61, 0x75, 0x3b, 0x73, 0x75, 0x6e, 0x6e, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x6d, 0xe1,
-0x6e, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0xfe, 0x72, 0x69, 0xf0, 0x6a, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b,
-0x6d, 0x69, 0xf0, 0x76, 0x69, 0x6b, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x66, 0x69, 0x6d, 0x6d, 0x74, 0x75, 0x64,
-0x61, 0x67, 0x75, 0x72, 0x3b, 0x66, 0xf6, 0x73, 0x74, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x6c, 0x61, 0x75, 0x67,
-0x61, 0x72, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0xfe, 0x3b, 0x4d, 0x3b, 0x46, 0x3b, 0x46, 0x3b,
-0x4c, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0xde, 0x3b, 0x4d, 0x3b, 0x46, 0x3b, 0x46, 0x3b, 0x4c, 0x3b, 0x4d, 0x69, 0x6e, 0x3b,
-0x53, 0x65, 0x6e, 0x3b, 0x53, 0x65, 0x6c, 0x3b, 0x52, 0x61, 0x62, 0x3b, 0x4b, 0x61, 0x6d, 0x3b, 0x4a, 0x75, 0x6d, 0x3b,
-0x53, 0x61, 0x62, 0x3b, 0x4d, 0x69, 0x6e, 0x67, 0x67, 0x75, 0x3b, 0x53, 0x65, 0x6e, 0x69, 0x6e, 0x3b, 0x53, 0x65, 0x6c,
-0x61, 0x73, 0x61, 0x3b, 0x52, 0x61, 0x62, 0x75, 0x3b, 0x4b, 0x61, 0x6d, 0x69, 0x73, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74,
-0x3b, 0x53, 0x61, 0x62, 0x74, 0x75, 0x3b, 0x4d, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x52, 0x3b, 0x4b, 0x3b, 0x4a, 0x3b, 0x53,
+0x633, 0x628, 0x62a, 0x3b, 0x62d, 0x3b, 0x646, 0x3b, 0x62b, 0x3b, 0x631, 0x3b, 0x62e, 0x3b, 0x62c, 0x3b, 0x633, 0x3b, 0x56f, 0x56b,
+0x580, 0x3b, 0x565, 0x580, 0x56f, 0x3b, 0x565, 0x580, 0x584, 0x3b, 0x579, 0x578, 0x580, 0x3b, 0x570, 0x576, 0x563, 0x3b, 0x578, 0x582,
+0x580, 0x3b, 0x577, 0x561, 0x562, 0x3b, 0x56f, 0x56b, 0x580, 0x561, 0x56f, 0x56b, 0x3b, 0x565, 0x580, 0x56f, 0x578, 0x582, 0x577, 0x561,
+0x562, 0x569, 0x56b, 0x3b, 0x565, 0x580, 0x565, 0x584, 0x577, 0x561, 0x562, 0x569, 0x56b, 0x3b, 0x579, 0x578, 0x580, 0x565, 0x584, 0x577,
+0x561, 0x562, 0x569, 0x56b, 0x3b, 0x570, 0x56b, 0x576, 0x563, 0x577, 0x561, 0x562, 0x569, 0x56b, 0x3b, 0x578, 0x582, 0x580, 0x562, 0x561,
+0x569, 0x3b, 0x577, 0x561, 0x562, 0x561, 0x569, 0x3b, 0x53f, 0x3b, 0x535, 0x3b, 0x535, 0x3b, 0x549, 0x3b, 0x540, 0x3b, 0x548, 0x582,
+0x3b, 0x547, 0x3b, 0x9f0, 0x9ac, 0x9bf, 0x3b, 0x9b8, 0x9cb, 0x9ae, 0x3b, 0x9ae, 0x999, 0x9cd, 0x997, 0x9b2, 0x3b, 0x9ac, 0x9c1, 0x9a7,
+0x3b, 0x9ac, 0x9c3, 0x9b9, 0x9b7, 0x9cd, 0x9aa, 0x9a4, 0x9bf, 0x3b, 0x9b6, 0x9c1, 0x995, 0x9cd, 0x9f0, 0x3b, 0x9b6, 0x9a8, 0x9bf, 0x3b,
+0x9a6, 0x9c7, 0x993, 0x9ac, 0x9be, 0x9f0, 0x3b, 0x9b8, 0x9cb, 0x9ae, 0x9ac, 0x9be, 0x9f0, 0x3b, 0x9ae, 0x999, 0x9cd, 0x997, 0x9b2, 0x9ac,
+0x9be, 0x9f0, 0x3b, 0x9ac, 0x9c1, 0x9a7, 0x9ac, 0x9be, 0x9f0, 0x3b, 0x9ac, 0x9c3, 0x9b9, 0x9b7, 0x9cd, 0x9aa, 0x9a4, 0x9bf, 0x9ac, 0x9be,
+0x9f0, 0x3b, 0x9b6, 0x9c1, 0x995, 0x9cd, 0x9f0, 0x9ac, 0x9be, 0x9f0, 0x3b, 0x9b6, 0x9a8, 0x9bf, 0x9ac, 0x9be, 0x9f0, 0x3b, 0x42, 0x2e,
+0x3b, 0x42, 0x2e, 0x45, 0x2e, 0x3b, 0xc7, 0x2e, 0x41, 0x2e, 0x3b, 0xc7, 0x2e, 0x3b, 0x43, 0x2e, 0x41, 0x2e, 0x3b, 0x43,
+0x3b, 0x15e, 0x2e, 0x3b, 0x62, 0x61, 0x7a, 0x61, 0x72, 0x3b, 0x62, 0x61, 0x7a, 0x61, 0x72, 0x20, 0x65, 0x72, 0x74, 0x259,
+0x73, 0x69, 0x3b, 0xe7, 0x259, 0x72, 0x15f, 0x259, 0x6e, 0x62, 0x259, 0x20, 0x61, 0x78, 0x15f, 0x61, 0x6d, 0x131, 0x3b, 0xe7,
+0x259, 0x72, 0x15f, 0x259, 0x6e, 0x62, 0x259, 0x3b, 0x63, 0xfc, 0x6d, 0x259, 0x20, 0x61, 0x78, 0x15f, 0x61, 0x6d, 0x131, 0x3b,
+0x63, 0xfc, 0x6d, 0x259, 0x3b, 0x15f, 0x259, 0x6e, 0x62, 0x259, 0x3b, 0x431, 0x430, 0x437, 0x430, 0x440, 0x3b, 0x431, 0x430, 0x437,
+0x430, 0x440, 0x20, 0x435, 0x440, 0x442, 0x4d9, 0x441, 0x438, 0x3b, 0x447, 0x4d9, 0x440, 0x448, 0x4d9, 0x43d, 0x431, 0x4d9, 0x20, 0x430,
+0x445, 0x448, 0x430, 0x43c, 0x44b, 0x3b, 0x447, 0x4d9, 0x440, 0x448, 0x4d9, 0x43d, 0x431, 0x4d9, 0x3b, 0x4b9, 0x4af, 0x43c, 0x4d9, 0x20,
+0x430, 0x445, 0x448, 0x430, 0x43c, 0x44b, 0x3b, 0x4b9, 0x4af, 0x43c, 0x4d9, 0x3b, 0x448, 0x4d9, 0x43d, 0x431, 0x4d9, 0x3b, 0x69, 0x67,
+0x3b, 0x61, 0x6c, 0x3b, 0x61, 0x73, 0x3b, 0x61, 0x7a, 0x3b, 0x6f, 0x67, 0x3b, 0x6f, 0x72, 0x3b, 0x6c, 0x72, 0x3b, 0x69,
+0x67, 0x61, 0x6e, 0x64, 0x65, 0x61, 0x3b, 0x61, 0x73, 0x74, 0x65, 0x6c, 0x65, 0x68, 0x65, 0x6e, 0x61, 0x3b, 0x61, 0x73,
+0x74, 0x65, 0x61, 0x72, 0x74, 0x65, 0x61, 0x3b, 0x61, 0x73, 0x74, 0x65, 0x61, 0x7a, 0x6b, 0x65, 0x6e, 0x61, 0x3b, 0x6f,
+0x73, 0x74, 0x65, 0x67, 0x75, 0x6e, 0x61, 0x3b, 0x6f, 0x73, 0x74, 0x69, 0x72, 0x61, 0x6c, 0x61, 0x3b, 0x6c, 0x61, 0x72,
+0x75, 0x6e, 0x62, 0x61, 0x74, 0x61, 0x3b, 0x49, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x4c, 0x3b, 0x41, 0x3b, 0x4f, 0x3b, 0x49,
+0x3b, 0x49, 0x3b, 0x4d, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x4f, 0x3b, 0x49, 0x3b, 0x9b0, 0x9ac, 0x9bf, 0x3b, 0x9b8,
+0x9cb, 0x9ae, 0x3b, 0x9ae, 0x999, 0x9cd, 0x997, 0x9b2, 0x3b, 0x9ac, 0x9c1, 0x9a7, 0x3b, 0x9ac, 0x9c3, 0x9b9, 0x9b8, 0x9cd, 0x9aa, 0x9a4,
+0x9bf, 0x3b, 0x9b6, 0x9c1, 0x995, 0x9cd, 0x9b0, 0x3b, 0x9b6, 0x9a8, 0x9bf, 0x3b, 0x9b0, 0x9ac, 0x9bf, 0x9ac, 0x9be, 0x9b0, 0x3b, 0x9b8,
+0x9cb, 0x9ae, 0x9ac, 0x9be, 0x9b0, 0x3b, 0x9ae, 0x999, 0x9cd, 0x997, 0x9b2, 0x9ac, 0x9be, 0x9b0, 0x3b, 0x9ac, 0x9c1, 0x9a7, 0x9ac, 0x9be,
+0x9b0, 0x3b, 0x9ac, 0x9c3, 0x9b9, 0x9b7, 0x9cd, 0x9aa, 0x9a4, 0x9bf, 0x9ac, 0x9be, 0x9b0, 0x3b, 0x9b6, 0x9c1, 0x995, 0x9cd, 0x9b0, 0x9ac,
+0x9be, 0x9b0, 0x3b, 0x9b6, 0x9a8, 0x9bf, 0x9ac, 0x9be, 0x9b0, 0x3b, 0x9b0, 0x3b, 0x9b8, 0x9cb, 0x3b, 0x9ae, 0x3b, 0x9ac, 0x9c1, 0x3b,
+0x9ac, 0x9c3, 0x3b, 0x9b6, 0x9c1, 0x3b, 0x9b6, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0x3b, 0xf58, 0xf72, 0xf62, 0xf0b, 0x3b, 0xf63, 0xfb7, 0xf42,
+0xf0b, 0x3b, 0xf55, 0xf74, 0xf62, 0xf0b, 0x3b, 0xf66, 0xf44, 0xf66, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xf7a, 0xf53, 0xf0b, 0x3b, 0xf49, 0xf72,
+0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf58, 0xf72, 0xf42, 0xf0b,
+0xf51, 0xf58, 0xf62, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf63, 0xfb7, 0xf42, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b,
+0xf55, 0xf74, 0xf62, 0xf0b, 0xf56, 0xf74, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf54, 0xf0b, 0xf66, 0xf44, 0xf66, 0xf0b, 0x3b, 0xf42,
+0xf5f, 0xf60, 0xf0b, 0xf66, 0xfa4, 0xf7a, 0xf53, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf49, 0xf72, 0xf0b, 0xf58, 0xf0b,
+0x3b, 0xf5f, 0xfb3, 0x3b, 0xf58, 0xf72, 0xf62, 0x3b, 0xf63, 0xfb7, 0xf42, 0x3b, 0xf55, 0xf74, 0xf62, 0x3b, 0xf66, 0xf44, 0xfb6, 0x3b,
+0xf66, 0xfa4, 0xf7a, 0xf53, 0x3b, 0xf49, 0xf72, 0x3b, 0x73, 0x75, 0x6c, 0x3b, 0x6c, 0x75, 0x6e, 0x3b, 0x6d, 0x65, 0x75, 0x2e,
+0x3b, 0x6d, 0x65, 0x72, 0x2e, 0x3b, 0x79, 0x61, 0x6f, 0x75, 0x3b, 0x67, 0x77, 0x65, 0x2e, 0x3b, 0x73, 0x61, 0x64, 0x2e,
+0x3b, 0x53, 0x75, 0x6c, 0x3b, 0x4c, 0x75, 0x6e, 0x3b, 0x4d, 0x65, 0x75, 0x72, 0x7a, 0x68, 0x3b, 0x4d, 0x65, 0x72, 0x63,
+0x2bc, 0x68, 0x65, 0x72, 0x3b, 0x59, 0x61, 0x6f, 0x75, 0x3b, 0x47, 0x77, 0x65, 0x6e, 0x65, 0x72, 0x3b, 0x53, 0x61, 0x64,
+0x6f, 0x72, 0x6e, 0x3b, 0x73, 0x75, 0x3b, 0x6c, 0x75, 0x3b, 0x6d, 0x7a, 0x3b, 0x6d, 0x63, 0x3b, 0x79, 0x61, 0x3b, 0x67,
+0x77, 0x3b, 0x73, 0x61, 0x3b, 0x43d, 0x434, 0x3b, 0x43f, 0x43d, 0x3b, 0x432, 0x442, 0x3b, 0x441, 0x440, 0x3b, 0x447, 0x442, 0x3b,
+0x43f, 0x442, 0x3b, 0x441, 0x431, 0x3b, 0x43d, 0x435, 0x434, 0x435, 0x43b, 0x44f, 0x3b, 0x43f, 0x43e, 0x43d, 0x435, 0x434, 0x435, 0x43b,
+0x43d, 0x438, 0x43a, 0x3b, 0x432, 0x442, 0x43e, 0x440, 0x43d, 0x438, 0x43a, 0x3b, 0x441, 0x440, 0x44f, 0x434, 0x430, 0x3b, 0x447, 0x435,
+0x442, 0x432, 0x44a, 0x440, 0x442, 0x44a, 0x43a, 0x3b, 0x43f, 0x435, 0x442, 0x44a, 0x43a, 0x3b, 0x441, 0x44a, 0x431, 0x43e, 0x442, 0x430,
+0x3b, 0x43d, 0x3b, 0x43f, 0x3b, 0x432, 0x3b, 0x441, 0x3b, 0x447, 0x3b, 0x43f, 0x3b, 0x441, 0x3b, 0x1014, 0x103d, 0x1031, 0x3b, 0x101c,
+0x102c, 0x3b, 0x1002, 0x102b, 0x3b, 0x101f, 0x1030, 0x1038, 0x3b, 0x1010, 0x1031, 0x1038, 0x3b, 0x1000, 0x103c, 0x102c, 0x3b, 0x1014, 0x1031, 0x3b,
+0x1010, 0x1014, 0x1004, 0x103a, 0x1039, 0x1002, 0x1014, 0x103d, 0x1031, 0x3b, 0x1010, 0x1014, 0x1004, 0x103a, 0x1039, 0x101c, 0x102c, 0x3b, 0x1021, 0x1004,
+0x103a, 0x1039, 0x1002, 0x102b, 0x3b, 0x1017, 0x102f, 0x1012, 0x1039, 0x1013, 0x101f, 0x1030, 0x1038, 0x3b, 0x1000, 0x103c, 0x102c, 0x101e, 0x1015, 0x1010,
+0x1031, 0x1038, 0x3b, 0x101e, 0x1031, 0x102c, 0x1000, 0x103c, 0x102c, 0x3b, 0x1005, 0x1014, 0x1031, 0x3b, 0x1010, 0x3b, 0x1010, 0x3b, 0x1021, 0x3b,
+0x1017, 0x3b, 0x1000, 0x3b, 0x101e, 0x3b, 0x1005, 0x3b, 0x43d, 0x434, 0x3b, 0x43f, 0x43d, 0x3b, 0x430, 0x45e, 0x3b, 0x441, 0x440, 0x3b,
+0x447, 0x446, 0x3b, 0x43f, 0x442, 0x3b, 0x441, 0x431, 0x3b, 0x43d, 0x44f, 0x434, 0x437, 0x435, 0x43b, 0x44f, 0x3b, 0x43f, 0x430, 0x43d,
+0x44f, 0x434, 0x437, 0x435, 0x43b, 0x430, 0x43a, 0x3b, 0x430, 0x45e, 0x442, 0x43e, 0x440, 0x430, 0x43a, 0x3b, 0x441, 0x435, 0x440, 0x430,
+0x434, 0x430, 0x3b, 0x447, 0x430, 0x446, 0x432, 0x435, 0x440, 0x3b, 0x43f, 0x44f, 0x442, 0x43d, 0x456, 0x446, 0x430, 0x3b, 0x441, 0x443,
+0x431, 0x43e, 0x442, 0x430, 0x3b, 0x43d, 0x3b, 0x43f, 0x3b, 0x430, 0x3b, 0x441, 0x3b, 0x447, 0x3b, 0x43f, 0x3b, 0x441, 0x3b, 0x17a2,
+0x17b6, 0x1791, 0x17b7, 0x178f, 0x17d2, 0x1799, 0x3b, 0x1785, 0x1793, 0x17d2, 0x1791, 0x3b, 0x17a2, 0x1784, 0x17d2, 0x1782, 0x17b6, 0x179a, 0x3b, 0x1796,
+0x17bb, 0x1792, 0x3b, 0x1796, 0x17d2, 0x179a, 0x17a0, 0x179f, 0x17d2, 0x1794, 0x178f, 0x17b7, 0x17cd, 0x3b, 0x179f, 0x17bb, 0x1780, 0x17d2, 0x179a, 0x3b,
+0x179f, 0x17c5, 0x179a, 0x17cd, 0x3b, 0x31, 0x3b, 0x32, 0x3b, 0x33, 0x3b, 0x34, 0x3b, 0x35, 0x3b, 0x36, 0x3b, 0x37, 0x3b, 0x64,
+0x67, 0x3b, 0x64, 0x6c, 0x3b, 0x64, 0x74, 0x3b, 0x64, 0x63, 0x3b, 0x64, 0x6a, 0x3b, 0x64, 0x76, 0x3b, 0x64, 0x73, 0x3b,
+0x44, 0x69, 0x75, 0x6d, 0x65, 0x6e, 0x67, 0x65, 0x3b, 0x44, 0x69, 0x6c, 0x6c, 0x75, 0x6e, 0x73, 0x3b, 0x44, 0x69, 0x6d,
+0x61, 0x72, 0x74, 0x73, 0x3b, 0x44, 0x69, 0x6d, 0x65, 0x63, 0x72, 0x65, 0x73, 0x3b, 0x44, 0x69, 0x6a, 0x6f, 0x75, 0x73,
+0x3b, 0x44, 0x69, 0x76, 0x65, 0x6e, 0x64, 0x72, 0x65, 0x73, 0x3b, 0x44, 0x69, 0x73, 0x73, 0x61, 0x62, 0x74, 0x65, 0x3b,
+0x64, 0x67, 0x2e, 0x3b, 0x64, 0x6c, 0x2e, 0x3b, 0x64, 0x74, 0x2e, 0x3b, 0x64, 0x63, 0x2e, 0x3b, 0x64, 0x6a, 0x2e, 0x3b,
+0x64, 0x76, 0x2e, 0x3b, 0x64, 0x73, 0x2e, 0x3b, 0x64, 0x69, 0x75, 0x6d, 0x65, 0x6e, 0x67, 0x65, 0x3b, 0x64, 0x69, 0x6c,
+0x6c, 0x75, 0x6e, 0x73, 0x3b, 0x64, 0x69, 0x6d, 0x61, 0x72, 0x74, 0x73, 0x3b, 0x64, 0x69, 0x6d, 0x65, 0x63, 0x72, 0x65,
+0x73, 0x3b, 0x64, 0x69, 0x6a, 0x6f, 0x75, 0x73, 0x3b, 0x64, 0x69, 0x76, 0x65, 0x6e, 0x64, 0x72, 0x65, 0x73, 0x3b, 0x64,
+0x69, 0x73, 0x73, 0x61, 0x62, 0x74, 0x65, 0x3b, 0x5468, 0x65e5, 0x3b, 0x5468, 0x4e00, 0x3b, 0x5468, 0x4e8c, 0x3b, 0x5468, 0x4e09, 0x3b,
+0x5468, 0x56db, 0x3b, 0x5468, 0x4e94, 0x3b, 0x5468, 0x516d, 0x3b, 0x661f, 0x671f, 0x65e5, 0x3b, 0x661f, 0x671f, 0x4e00, 0x3b, 0x661f, 0x671f, 0x4e8c,
+0x3b, 0x661f, 0x671f, 0x4e09, 0x3b, 0x661f, 0x671f, 0x56db, 0x3b, 0x661f, 0x671f, 0x4e94, 0x3b, 0x661f, 0x671f, 0x516d, 0x3b, 0x65e5, 0x3b, 0x4e00,
+0x3b, 0x4e8c, 0x3b, 0x4e09, 0x3b, 0x56db, 0x3b, 0x4e94, 0x3b, 0x516d, 0x3b, 0x9031, 0x65e5, 0x3b, 0x9031, 0x4e00, 0x3b, 0x9031, 0x4e8c, 0x3b,
+0x9031, 0x4e09, 0x3b, 0x9031, 0x56db, 0x3b, 0x9031, 0x4e94, 0x3b, 0x9031, 0x516d, 0x3b, 0x6e, 0x65, 0x64, 0x3b, 0x70, 0x6f, 0x6e, 0x3b,
+0x75, 0x74, 0x6f, 0x3b, 0x73, 0x72, 0x69, 0x3b, 0x10d, 0x65, 0x74, 0x3b, 0x70, 0x65, 0x74, 0x3b, 0x73, 0x75, 0x62, 0x3b,
+0x6e, 0x65, 0x64, 0x6a, 0x65, 0x6c, 0x6a, 0x61, 0x3b, 0x70, 0x6f, 0x6e, 0x65, 0x64, 0x6a, 0x65, 0x6c, 0x6a, 0x61, 0x6b,
+0x3b, 0x75, 0x74, 0x6f, 0x72, 0x61, 0x6b, 0x3b, 0x73, 0x72, 0x69, 0x6a, 0x65, 0x64, 0x61, 0x3b, 0x10d, 0x65, 0x74, 0x76,
+0x72, 0x74, 0x61, 0x6b, 0x3b, 0x70, 0x65, 0x74, 0x61, 0x6b, 0x3b, 0x73, 0x75, 0x62, 0x6f, 0x74, 0x61, 0x3b, 0x6e, 0x3b,
+0x70, 0x3b, 0x75, 0x3b, 0x73, 0x3b, 0x10d, 0x3b, 0x70, 0x3b, 0x73, 0x3b, 0x4e, 0x3b, 0x50, 0x3b, 0x55, 0x3b, 0x53, 0x3b,
+0x10c, 0x3b, 0x50, 0x3b, 0x53, 0x3b, 0x6e, 0x65, 0x3b, 0x70, 0x6f, 0x3b, 0xfa, 0x74, 0x3b, 0x73, 0x74, 0x3b, 0x10d, 0x74,
+0x3b, 0x70, 0xe1, 0x3b, 0x73, 0x6f, 0x3b, 0x6e, 0x65, 0x64, 0x11b, 0x6c, 0x65, 0x3b, 0x70, 0x6f, 0x6e, 0x64, 0x11b, 0x6c,
+0xed, 0x3b, 0xfa, 0x74, 0x65, 0x72, 0xfd, 0x3b, 0x73, 0x74, 0x159, 0x65, 0x64, 0x61, 0x3b, 0x10d, 0x74, 0x76, 0x72, 0x74,
+0x65, 0x6b, 0x3b, 0x70, 0xe1, 0x74, 0x65, 0x6b, 0x3b, 0x73, 0x6f, 0x62, 0x6f, 0x74, 0x61, 0x3b, 0x4e, 0x3b, 0x50, 0x3b,
+0xda, 0x3b, 0x53, 0x3b, 0x10c, 0x3b, 0x50, 0x3b, 0x53, 0x3b, 0x73, 0xf8, 0x6e, 0x3b, 0x6d, 0x61, 0x6e, 0x3b, 0x74, 0x69,
+0x72, 0x3b, 0x6f, 0x6e, 0x73, 0x3b, 0x74, 0x6f, 0x72, 0x3b, 0x66, 0x72, 0x65, 0x3b, 0x6c, 0xf8, 0x72, 0x3b, 0x73, 0xf8,
+0x6e, 0x64, 0x61, 0x67, 0x3b, 0x6d, 0x61, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x74, 0x69, 0x72, 0x73, 0x64, 0x61, 0x67, 0x3b,
+0x6f, 0x6e, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x74, 0x6f, 0x72, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x66, 0x72, 0x65, 0x64, 0x61,
+0x67, 0x3b, 0x6c, 0xf8, 0x72, 0x64, 0x61, 0x67, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x54, 0x3b, 0x4f, 0x3b, 0x54, 0x3b, 0x46,
+0x3b, 0x4c, 0x3b, 0x73, 0xf8, 0x6e, 0x2e, 0x3b, 0x6d, 0x61, 0x6e, 0x2e, 0x3b, 0x74, 0x69, 0x72, 0x2e, 0x3b, 0x6f, 0x6e,
+0x73, 0x2e, 0x3b, 0x74, 0x6f, 0x72, 0x2e, 0x3b, 0x66, 0x72, 0x65, 0x2e, 0x3b, 0x6c, 0xf8, 0x72, 0x2e, 0x3b, 0x7a, 0x6f,
+0x3b, 0x6d, 0x61, 0x3b, 0x64, 0x69, 0x3b, 0x77, 0x6f, 0x3b, 0x64, 0x6f, 0x3b, 0x76, 0x72, 0x3b, 0x7a, 0x61, 0x3b, 0x7a,
+0x6f, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x6d, 0x61, 0x61, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x64, 0x69, 0x6e, 0x73, 0x64, 0x61,
+0x67, 0x3b, 0x77, 0x6f, 0x65, 0x6e, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x64, 0x6f, 0x6e, 0x64, 0x65, 0x72, 0x64, 0x61, 0x67,
+0x3b, 0x76, 0x72, 0x69, 0x6a, 0x64, 0x61, 0x67, 0x3b, 0x7a, 0x61, 0x74, 0x65, 0x72, 0x64, 0x61, 0x67, 0x3b, 0x5a, 0x3b,
+0x4d, 0x3b, 0x44, 0x3b, 0x57, 0x3b, 0x44, 0x3b, 0x56, 0x3b, 0x5a, 0x3b, 0xd801, 0xdc1d, 0xd801, 0xdc32, 0xd801, 0xdc4c, 0x3b, 0xd801,
+0xdc23, 0xd801, 0xdc32, 0xd801, 0xdc4c, 0x3b, 0xd801, 0xdc13, 0xd801, 0xdc2d, 0xd801, 0xdc46, 0x3b, 0xd801, 0xdc0e, 0xd801, 0xdc2f, 0xd801, 0xdc4c, 0x3b,
+0xd801, 0xdc1b, 0xd801, 0xdc32, 0xd801, 0xdc49, 0x3b, 0xd801, 0xdc19, 0xd801, 0xdc49, 0xd801, 0xdc34, 0x3b, 0xd801, 0xdc1d, 0xd801, 0xdc30, 0xd801, 0xdc3b,
+0x3b, 0xd801, 0xdc1d, 0xd801, 0xdc32, 0xd801, 0xdc4c, 0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc23, 0xd801, 0xdc32, 0xd801, 0xdc4c, 0xd801, 0xdc3c,
+0xd801, 0xdc29, 0x3b, 0xd801, 0xdc13, 0xd801, 0xdc2d, 0xd801, 0xdc46, 0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc0e, 0xd801, 0xdc2f, 0xd801, 0xdc4c,
+0xd801, 0xdc46, 0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc1b, 0xd801, 0xdc32, 0xd801, 0xdc49, 0xd801, 0xdc46, 0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b,
+0xd801, 0xdc19, 0xd801, 0xdc49, 0xd801, 0xdc34, 0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc1d, 0xd801, 0xdc30, 0xd801, 0xdc3b, 0xd801, 0xdc32, 0xd801,
+0xdc49, 0xd801, 0xdc3c, 0xd801, 0xdc29, 0x3b, 0xd801, 0xdc1d, 0x3b, 0xd801, 0xdc23, 0x3b, 0xd801, 0xdc13, 0x3b, 0xd801, 0xdc0e, 0x3b, 0xd801, 0xdc1b,
+0x3b, 0xd801, 0xdc19, 0x3b, 0xd801, 0xdc1d, 0x3b, 0x50, 0x3b, 0x45, 0x3b, 0x54, 0x3b, 0x4b, 0x3b, 0x4e, 0x3b, 0x52, 0x3b, 0x4c,
+0x3b, 0x70, 0xfc, 0x68, 0x61, 0x70, 0xe4, 0x65, 0x76, 0x3b, 0x65, 0x73, 0x6d, 0x61, 0x73, 0x70, 0xe4, 0x65, 0x76, 0x3b,
+0x74, 0x65, 0x69, 0x73, 0x69, 0x70, 0xe4, 0x65, 0x76, 0x3b, 0x6b, 0x6f, 0x6c, 0x6d, 0x61, 0x70, 0xe4, 0x65, 0x76, 0x3b,
+0x6e, 0x65, 0x6c, 0x6a, 0x61, 0x70, 0xe4, 0x65, 0x76, 0x3b, 0x72, 0x65, 0x65, 0x64, 0x65, 0x3b, 0x6c, 0x61, 0x75, 0x70,
+0xe4, 0x65, 0x76, 0x3b, 0x73, 0x75, 0x6e, 0x3b, 0x6d, 0xe1, 0x6e, 0x3b, 0x74, 0xfd, 0x73, 0x3b, 0x6d, 0x69, 0x6b, 0x3b,
+0x68, 0xf3, 0x73, 0x3b, 0x66, 0x72, 0xed, 0x3b, 0x6c, 0x65, 0x79, 0x3b, 0x73, 0x75, 0x6e, 0x6e, 0x75, 0x64, 0x61, 0x67,
+0x75, 0x72, 0x3b, 0x6d, 0xe1, 0x6e, 0x61, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x74, 0xfd, 0x73, 0x64, 0x61, 0x67, 0x75,
+0x72, 0x3b, 0x6d, 0x69, 0x6b, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x68, 0xf3, 0x73, 0x64, 0x61, 0x67, 0x75, 0x72,
+0x3b, 0x66, 0x72, 0xed, 0x67, 0x67, 0x6a, 0x61, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x6c, 0x65, 0x79, 0x67, 0x61, 0x72,
+0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x54, 0x3b, 0x4d, 0x3b, 0x48, 0x3b, 0x46, 0x3b, 0x4c, 0x3b,
+0x73, 0x75, 0x3b, 0x6d, 0x61, 0x3b, 0x74, 0x69, 0x3b, 0x6b, 0x65, 0x3b, 0x74, 0x6f, 0x3b, 0x70, 0x65, 0x3b, 0x6c, 0x61,
+0x3b, 0x73, 0x75, 0x6e, 0x6e, 0x75, 0x6e, 0x74, 0x61, 0x69, 0x3b, 0x6d, 0x61, 0x61, 0x6e, 0x61, 0x6e, 0x74, 0x61, 0x69,
+0x3b, 0x74, 0x69, 0x69, 0x73, 0x74, 0x61, 0x69, 0x3b, 0x6b, 0x65, 0x73, 0x6b, 0x69, 0x76, 0x69, 0x69, 0x6b, 0x6b, 0x6f,
+0x3b, 0x74, 0x6f, 0x72, 0x73, 0x74, 0x61, 0x69, 0x3b, 0x70, 0x65, 0x72, 0x6a, 0x61, 0x6e, 0x74, 0x61, 0x69, 0x3b, 0x6c,
+0x61, 0x75, 0x61, 0x6e, 0x74, 0x61, 0x69, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x54, 0x3b, 0x4b, 0x3b, 0x54, 0x3b, 0x50, 0x3b,
+0x4c, 0x3b, 0x73, 0x75, 0x6e, 0x6e, 0x75, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x61, 0x3b, 0x6d, 0x61, 0x61, 0x6e, 0x61, 0x6e,
+0x74, 0x61, 0x69, 0x6e, 0x61, 0x3b, 0x74, 0x69, 0x69, 0x73, 0x74, 0x61, 0x69, 0x6e, 0x61, 0x3b, 0x6b, 0x65, 0x73, 0x6b,
+0x69, 0x76, 0x69, 0x69, 0x6b, 0x6b, 0x6f, 0x6e, 0x61, 0x3b, 0x74, 0x6f, 0x72, 0x73, 0x74, 0x61, 0x69, 0x6e, 0x61, 0x3b,
+0x70, 0x65, 0x72, 0x6a, 0x61, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x61, 0x3b, 0x6c, 0x61, 0x75, 0x61, 0x6e, 0x74, 0x61, 0x69,
+0x6e, 0x61, 0x3b, 0x64, 0x69, 0x6d, 0x2e, 0x3b, 0x6c, 0x75, 0x6e, 0x2e, 0x3b, 0x6d, 0x61, 0x72, 0x2e, 0x3b, 0x6d, 0x65,
+0x72, 0x2e, 0x3b, 0x6a, 0x65, 0x75, 0x2e, 0x3b, 0x76, 0x65, 0x6e, 0x2e, 0x3b, 0x73, 0x61, 0x6d, 0x2e, 0x3b, 0x64, 0x69,
+0x6d, 0x61, 0x6e, 0x63, 0x68, 0x65, 0x3b, 0x6c, 0x75, 0x6e, 0x64, 0x69, 0x3b, 0x6d, 0x61, 0x72, 0x64, 0x69, 0x3b, 0x6d,
+0x65, 0x72, 0x63, 0x72, 0x65, 0x64, 0x69, 0x3b, 0x6a, 0x65, 0x75, 0x64, 0x69, 0x3b, 0x76, 0x65, 0x6e, 0x64, 0x72, 0x65,
+0x64, 0x69, 0x3b, 0x73, 0x61, 0x6d, 0x65, 0x64, 0x69, 0x3b, 0x44, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b,
+0x56, 0x3b, 0x53, 0x3b, 0x44, 0x69, 0x44, 0x3b, 0x44, 0x69, 0x4c, 0x3b, 0x44, 0x69, 0x4d, 0x3b, 0x44, 0x69, 0x43, 0x3b,
+0x44, 0x69, 0x61, 0x3b, 0x44, 0x69, 0x68, 0x3b, 0x44, 0x69, 0x53, 0x3b, 0x44, 0x69, 0x44, 0xf2, 0x6d, 0x68, 0x6e, 0x61,
+0x69, 0x63, 0x68, 0x3b, 0x44, 0x69, 0x4c, 0x75, 0x61, 0x69, 0x6e, 0x3b, 0x44, 0x69, 0x4d, 0xe0, 0x69, 0x72, 0x74, 0x3b,
+0x44, 0x69, 0x43, 0x69, 0x61, 0x64, 0x61, 0x69, 0x6e, 0x3b, 0x44, 0x69, 0x61, 0x72, 0x64, 0x61, 0x6f, 0x69, 0x6e, 0x3b,
+0x44, 0x69, 0x68, 0x41, 0x6f, 0x69, 0x6e, 0x65, 0x3b, 0x44, 0x69, 0x53, 0x61, 0x74, 0x68, 0x61, 0x69, 0x72, 0x6e, 0x65,
+0x3b, 0x44, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x43, 0x3b, 0x41, 0x3b, 0x48, 0x3b, 0x53, 0x3b, 0x44, 0x6f, 0x6d, 0x3b, 0x4c,
+0x75, 0x6e, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x4d, 0xe9, 0x72, 0x3b, 0x58, 0x6f, 0x76, 0x3b, 0x56, 0x65, 0x6e, 0x3b, 0x53,
+0xe1, 0x62, 0x3b, 0x44, 0x6f, 0x6d, 0x69, 0x6e, 0x67, 0x6f, 0x3b, 0x4c, 0x75, 0x6e, 0x73, 0x3b, 0x4d, 0x61, 0x72, 0x74,
+0x65, 0x73, 0x3b, 0x4d, 0xe9, 0x72, 0x63, 0x6f, 0x72, 0x65, 0x73, 0x3b, 0x58, 0x6f, 0x76, 0x65, 0x73, 0x3b, 0x56, 0x65,
+0x6e, 0x72, 0x65, 0x73, 0x3b, 0x53, 0xe1, 0x62, 0x61, 0x64, 0x6f, 0x3b, 0x44, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b,
+0x58, 0x3b, 0x56, 0x3b, 0x53, 0x3b, 0x10d9, 0x10d5, 0x10d8, 0x3b, 0x10dd, 0x10e0, 0x10e8, 0x3b, 0x10e1, 0x10d0, 0x10db, 0x3b, 0x10dd, 0x10d7,
+0x10ee, 0x3b, 0x10ee, 0x10e3, 0x10d7, 0x3b, 0x10de, 0x10d0, 0x10e0, 0x3b, 0x10e8, 0x10d0, 0x10d1, 0x3b, 0x10d9, 0x10d5, 0x10d8, 0x10e0, 0x10d0, 0x3b,
+0x10dd, 0x10e0, 0x10e8, 0x10d0, 0x10d1, 0x10d0, 0x10d7, 0x10d8, 0x3b, 0x10e1, 0x10d0, 0x10db, 0x10e8, 0x10d0, 0x10d1, 0x10d0, 0x10d7, 0x10d8, 0x3b, 0x10dd,
+0x10d7, 0x10ee, 0x10e8, 0x10d0, 0x10d1, 0x10d0, 0x10d7, 0x10d8, 0x3b, 0x10ee, 0x10e3, 0x10d7, 0x10e8, 0x10d0, 0x10d1, 0x10d0, 0x10d7, 0x10d8, 0x3b, 0x10de,
+0x10d0, 0x10e0, 0x10d0, 0x10e1, 0x10d9, 0x10d4, 0x10d5, 0x10d8, 0x3b, 0x10e8, 0x10d0, 0x10d1, 0x10d0, 0x10d7, 0x10d8, 0x3b, 0x10d9, 0x3b, 0x10dd, 0x3b,
+0x10e1, 0x3b, 0x10dd, 0x3b, 0x10ee, 0x3b, 0x10de, 0x3b, 0x10e8, 0x3b, 0x53, 0x6f, 0x3b, 0x4d, 0x6f, 0x3b, 0x44, 0x69, 0x3b, 0x4d,
+0x69, 0x3b, 0x44, 0x6f, 0x3b, 0x46, 0x72, 0x3b, 0x53, 0x61, 0x3b, 0x53, 0x6f, 0x6e, 0x6e, 0x74, 0x61, 0x67, 0x3b, 0x4d,
+0x6f, 0x6e, 0x74, 0x61, 0x67, 0x3b, 0x44, 0x69, 0x65, 0x6e, 0x73, 0x74, 0x61, 0x67, 0x3b, 0x4d, 0x69, 0x74, 0x74, 0x77,
+0x6f, 0x63, 0x68, 0x3b, 0x44, 0x6f, 0x6e, 0x6e, 0x65, 0x72, 0x73, 0x74, 0x61, 0x67, 0x3b, 0x46, 0x72, 0x65, 0x69, 0x74,
+0x61, 0x67, 0x3b, 0x53, 0x61, 0x6d, 0x73, 0x74, 0x61, 0x67, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x44, 0x3b, 0x4d, 0x3b, 0x44,
+0x3b, 0x46, 0x3b, 0x53, 0x3b, 0x53, 0x6f, 0x2e, 0x3b, 0x4d, 0x6f, 0x2e, 0x3b, 0x44, 0x69, 0x2e, 0x3b, 0x4d, 0x69, 0x2e,
+0x3b, 0x44, 0x6f, 0x2e, 0x3b, 0x46, 0x72, 0x2e, 0x3b, 0x53, 0x61, 0x2e, 0x3b, 0x39a, 0x3c5, 0x3c1, 0x3b, 0x394, 0x3b5, 0x3c5,
+0x3b, 0x3a4, 0x3c1, 0x3af, 0x3b, 0x3a4, 0x3b5, 0x3c4, 0x3b, 0x3a0, 0x3ad, 0x3bc, 0x3b, 0x3a0, 0x3b1, 0x3c1, 0x3b, 0x3a3, 0x3ac, 0x3b2,
+0x3b, 0x39a, 0x3c5, 0x3c1, 0x3b9, 0x3b1, 0x3ba, 0x3ae, 0x3b, 0x394, 0x3b5, 0x3c5, 0x3c4, 0x3ad, 0x3c1, 0x3b1, 0x3b, 0x3a4, 0x3c1, 0x3af,
+0x3c4, 0x3b7, 0x3b, 0x3a4, 0x3b5, 0x3c4, 0x3ac, 0x3c1, 0x3c4, 0x3b7, 0x3b, 0x3a0, 0x3ad, 0x3bc, 0x3c0, 0x3c4, 0x3b7, 0x3b, 0x3a0, 0x3b1,
+0x3c1, 0x3b1, 0x3c3, 0x3ba, 0x3b5, 0x3c5, 0x3ae, 0x3b, 0x3a3, 0x3ac, 0x3b2, 0x3b2, 0x3b1, 0x3c4, 0x3bf, 0x3b, 0x39a, 0x3b, 0x394, 0x3b,
+0x3a4, 0x3b, 0x3a4, 0x3b, 0x3a0, 0x3b, 0x3a0, 0x3b, 0x3a3, 0x3b, 0x73, 0x61, 0x62, 0x3b, 0x61, 0x74, 0x61, 0x3b, 0x6d, 0x61,
+0x72, 0x3b, 0x70, 0x69, 0x6e, 0x3b, 0x73, 0x69, 0x73, 0x3b, 0x74, 0x61, 0x6c, 0x3b, 0x61, 0x72, 0x66, 0x3b, 0x73, 0x61,
+0x62, 0x61, 0x61, 0x74, 0x3b, 0x61, 0x74, 0x61, 0x61, 0x73, 0x69, 0x6e, 0x6e, 0x67, 0x6f, 0x72, 0x6e, 0x65, 0x71, 0x3b,
+0x6d, 0x61, 0x72, 0x6c, 0x75, 0x6e, 0x6e, 0x67, 0x6f, 0x72, 0x6e, 0x65, 0x71, 0x3b, 0x70, 0x69, 0x6e, 0x67, 0x61, 0x73,
+0x75, 0x6e, 0x6e, 0x67, 0x6f, 0x72, 0x6e, 0x65, 0x71, 0x3b, 0x73, 0x69, 0x73, 0x61, 0x6d, 0x61, 0x6e, 0x6e, 0x67, 0x6f,
+0x72, 0x6e, 0x65, 0x71, 0x3b, 0x74, 0x61, 0x6c, 0x6c, 0x69, 0x6d, 0x61, 0x6e, 0x6e, 0x67, 0x6f, 0x72, 0x6e, 0x65, 0x71,
+0x3b, 0x61, 0x72, 0x66, 0x69, 0x6e, 0x69, 0x6e, 0x6e, 0x67, 0x6f, 0x72, 0x6e, 0x65, 0x71, 0x3b, 0x53, 0x3b, 0x41, 0x3b,
+0x4d, 0x3b, 0x50, 0x3b, 0x53, 0x3b, 0x54, 0x3b, 0x41, 0x3b, 0xab0, 0xab5, 0xabf, 0x3b, 0xab8, 0xacb, 0xaae, 0x3b, 0xaae, 0xa82,
+0xa97, 0xab3, 0x3b, 0xaac, 0xac1, 0xaa7, 0x3b, 0xa97, 0xac1, 0xab0, 0xac1, 0x3b, 0xab6, 0xac1, 0xa95, 0xacd, 0xab0, 0x3b, 0xab6, 0xaa8,
+0xabf, 0x3b, 0xab0, 0xab5, 0xabf, 0xab5, 0xabe, 0xab0, 0x3b, 0xab8, 0xacb, 0xaae, 0xab5, 0xabe, 0xab0, 0x3b, 0xaae, 0xa82, 0xa97, 0xab3,
+0xab5, 0xabe, 0xab0, 0x3b, 0xaac, 0xac1, 0xaa7, 0xab5, 0xabe, 0xab0, 0x3b, 0xa97, 0xac1, 0xab0, 0xac1, 0xab5, 0xabe, 0xab0, 0x3b, 0xab6,
+0xac1, 0xa95, 0xacd, 0xab0, 0xab5, 0xabe, 0xab0, 0x3b, 0xab6, 0xaa8, 0xabf, 0xab5, 0xabe, 0xab0, 0x3b, 0xab0, 0x3b, 0xab8, 0xacb, 0x3b,
+0xaae, 0xa82, 0x3b, 0xaac, 0xac1, 0x3b, 0xa97, 0xac1, 0x3b, 0xab6, 0xac1, 0x3b, 0xab6, 0x3b, 0x4c, 0x68, 0x3b, 0x4c, 0x69, 0x3b,
+0x54, 0x61, 0x3b, 0x4c, 0x72, 0x3b, 0x41, 0x6c, 0x3b, 0x4a, 0x75, 0x3b, 0x41, 0x73, 0x3b, 0x4c, 0x61, 0x68, 0x61, 0x64,
+0x69, 0x3b, 0x4c, 0x69, 0x74, 0x69, 0x6e, 0x69, 0x6e, 0x3b, 0x54, 0x61, 0x6c, 0x61, 0x74, 0x61, 0x3b, 0x4c, 0x61, 0x72,
+0x61, 0x62, 0x61, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x73, 0x3b, 0x4a, 0x75, 0x6d, 0x6d, 0x61, 0x27, 0x61, 0x3b,
+0x41, 0x73, 0x61, 0x62, 0x61, 0x72, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x54, 0x3b, 0x4c, 0x3b, 0x41, 0x3b, 0x4a, 0x3b, 0x41,
+0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d0, 0x5f3, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d1, 0x5f3, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d2,
+0x5f3, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d3, 0x5f3, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d4, 0x5f3, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20,
+0x5d5, 0x5f3, 0x3b, 0x5e9, 0x5d1, 0x5ea, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5e8, 0x5d0, 0x5e9, 0x5d5, 0x5df, 0x3b, 0x5d9, 0x5d5, 0x5dd,
+0x20, 0x5e9, 0x5e0, 0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5e9, 0x5dc, 0x5d9, 0x5e9, 0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5e8,
+0x5d1, 0x5d9, 0x5e2, 0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5d7, 0x5de, 0x5d9, 0x5e9, 0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5e9,
+0x5d9, 0x5e9, 0x5d9, 0x3b, 0x5d9, 0x5d5, 0x5dd, 0x20, 0x5e9, 0x5d1, 0x5ea, 0x3b, 0x5d0, 0x5f3, 0x3b, 0x5d1, 0x5f3, 0x3b, 0x5d2, 0x5f3,
+0x3b, 0x5d3, 0x5f3, 0x3b, 0x5d4, 0x5f3, 0x3b, 0x5d5, 0x3b, 0x5e9, 0x3b, 0x5d0, 0x27, 0x3b, 0x5d1, 0x27, 0x3b, 0x5d2, 0x27, 0x3b,
+0x5d3, 0x27, 0x3b, 0x5d4, 0x27, 0x3b, 0x5d5, 0x5f3, 0x3b, 0x5e9, 0x5f3, 0x3b, 0x930, 0x935, 0x93f, 0x2e, 0x3b, 0x938, 0x94b, 0x92e,
+0x2e, 0x3b, 0x92e, 0x902, 0x917, 0x932, 0x2e, 0x3b, 0x92c, 0x941, 0x927, 0x2e, 0x3b, 0x92c, 0x943, 0x939, 0x2e, 0x3b, 0x936, 0x941,
+0x915, 0x94d, 0x930, 0x2e, 0x3b, 0x936, 0x928, 0x93f, 0x2e, 0x3b, 0x930, 0x935, 0x93f, 0x935, 0x93e, 0x930, 0x3b, 0x938, 0x94b, 0x92e,
+0x935, 0x93e, 0x930, 0x3b, 0x92e, 0x902, 0x917, 0x932, 0x935, 0x93e, 0x930, 0x3b, 0x92c, 0x941, 0x927, 0x935, 0x93e, 0x930, 0x3b, 0x92c,
+0x943, 0x939, 0x938, 0x94d, 0x92a, 0x924, 0x93f, 0x935, 0x93e, 0x930, 0x3b, 0x936, 0x941, 0x915, 0x94d, 0x930, 0x935, 0x93e, 0x930, 0x3b,
+0x936, 0x928, 0x93f, 0x935, 0x93e, 0x930, 0x3b, 0x930, 0x3b, 0x938, 0x94b, 0x3b, 0x92e, 0x902, 0x3b, 0x92c, 0x941, 0x3b, 0x917, 0x941,
+0x3b, 0x936, 0x941, 0x3b, 0x936, 0x3b, 0x56, 0x3b, 0x48, 0x3b, 0x4b, 0x3b, 0x53, 0x7a, 0x65, 0x3b, 0x43, 0x73, 0x3b, 0x50,
+0x3b, 0x53, 0x7a, 0x6f, 0x3b, 0x76, 0x61, 0x73, 0xe1, 0x72, 0x6e, 0x61, 0x70, 0x3b, 0x68, 0xe9, 0x74, 0x66, 0x151, 0x3b,
+0x6b, 0x65, 0x64, 0x64, 0x3b, 0x73, 0x7a, 0x65, 0x72, 0x64, 0x61, 0x3b, 0x63, 0x73, 0xfc, 0x74, 0xf6, 0x72, 0x74, 0xf6,
+0x6b, 0x3b, 0x70, 0xe9, 0x6e, 0x74, 0x65, 0x6b, 0x3b, 0x73, 0x7a, 0x6f, 0x6d, 0x62, 0x61, 0x74, 0x3b, 0x56, 0x3b, 0x48,
+0x3b, 0x4b, 0x3b, 0x53, 0x7a, 0x3b, 0x43, 0x73, 0x3b, 0x50, 0x3b, 0x53, 0x7a, 0x3b, 0x73, 0x75, 0x6e, 0x3b, 0x6d, 0xe1,
+0x6e, 0x3b, 0xfe, 0x72, 0x69, 0x3b, 0x6d, 0x69, 0xf0, 0x3b, 0x66, 0x69, 0x6d, 0x3b, 0x66, 0xf6, 0x73, 0x3b, 0x6c, 0x61,
+0x75, 0x3b, 0x73, 0x75, 0x6e, 0x6e, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x6d, 0xe1, 0x6e, 0x75, 0x64, 0x61, 0x67,
+0x75, 0x72, 0x3b, 0xfe, 0x72, 0x69, 0xf0, 0x6a, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x6d, 0x69, 0xf0, 0x76, 0x69,
+0x6b, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x66, 0x69, 0x6d, 0x6d, 0x74, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b,
+0x66, 0xf6, 0x73, 0x74, 0x75, 0x64, 0x61, 0x67, 0x75, 0x72, 0x3b, 0x6c, 0x61, 0x75, 0x67, 0x61, 0x72, 0x64, 0x61, 0x67,
+0x75, 0x72, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0xfe, 0x3b, 0x4d, 0x3b, 0x46, 0x3b, 0x46, 0x3b, 0x4c, 0x3b, 0x53, 0x3b, 0x4d,
+0x3b, 0xde, 0x3b, 0x4d, 0x3b, 0x46, 0x3b, 0x46, 0x3b, 0x4c, 0x3b, 0x4d, 0x69, 0x6e, 0x3b, 0x53, 0x65, 0x6e, 0x3b, 0x53,
+0x65, 0x6c, 0x3b, 0x52, 0x61, 0x62, 0x3b, 0x4b, 0x61, 0x6d, 0x3b, 0x4a, 0x75, 0x6d, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x4d,
+0x69, 0x6e, 0x67, 0x67, 0x75, 0x3b, 0x53, 0x65, 0x6e, 0x69, 0x6e, 0x3b, 0x53, 0x65, 0x6c, 0x61, 0x73, 0x61, 0x3b, 0x52,
+0x61, 0x62, 0x75, 0x3b, 0x4b, 0x61, 0x6d, 0x69, 0x73, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x3b, 0x53, 0x61, 0x62, 0x74,
+0x75, 0x3b, 0x4d, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x52, 0x3b, 0x4b, 0x3b, 0x4a, 0x3b, 0x53, 0x3b, 0x64, 0x6f, 0x6d, 0x3b,
+0x6c, 0x75, 0x6e, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x6d, 0x65, 0x72, 0x3b, 0x6a, 0x6f, 0x76, 0x3b, 0x76, 0x65, 0x6e, 0x3b,
+0x73, 0x61, 0x62, 0x3b, 0x64, 0x6f, 0x6d, 0x69, 0x6e, 0x69, 0x63, 0x61, 0x3b, 0x6c, 0x75, 0x6e, 0x65, 0x64, 0x69, 0x3b,
+0x6d, 0x61, 0x72, 0x74, 0x65, 0x64, 0x69, 0x3b, 0x6d, 0x65, 0x72, 0x63, 0x75, 0x72, 0x69, 0x64, 0x69, 0x3b, 0x6a, 0x6f,
+0x76, 0x65, 0x64, 0x69, 0x3b, 0x76, 0x65, 0x6e, 0x65, 0x72, 0x64, 0x69, 0x3b, 0x73, 0x61, 0x62, 0x62, 0x61, 0x74, 0x6f,
0x3b, 0x44, 0x6f, 0x6d, 0x68, 0x3b, 0x4c, 0x75, 0x61, 0x6e, 0x3b, 0x4d, 0xe1, 0x69, 0x72, 0x74, 0x3b, 0x43, 0xe9, 0x61,
0x64, 0x3b, 0x44, 0xe9, 0x61, 0x72, 0x3b, 0x41, 0x6f, 0x69, 0x6e, 0x65, 0x3b, 0x53, 0x61, 0x74, 0x68, 0x3b, 0x44, 0xe9,
0x20, 0x44, 0x6f, 0x6d, 0x68, 0x6e, 0x61, 0x69, 0x67, 0x68, 0x3b, 0x44, 0xe9, 0x20, 0x4c, 0x75, 0x61, 0x69, 0x6e, 0x3b,
@@ -3488,734 +3770,743 @@ static const ushort days_data[] = {
0x902, 0x917, 0x933, 0x3b, 0x92c, 0x941, 0x927, 0x3b, 0x917, 0x941, 0x930, 0x941, 0x3b, 0x936, 0x941, 0x915, 0x94d, 0x930, 0x3b, 0x936,
0x928, 0x93f, 0x3b, 0x930, 0x935, 0x93f, 0x935, 0x93e, 0x930, 0x3b, 0x938, 0x94b, 0x92e, 0x935, 0x93e, 0x930, 0x3b, 0x92e, 0x902, 0x917,
0x933, 0x935, 0x93e, 0x930, 0x3b, 0x92c, 0x941, 0x927, 0x935, 0x93e, 0x930, 0x3b, 0x917, 0x941, 0x930, 0x941, 0x935, 0x93e, 0x930, 0x3b,
-0x936, 0x941, 0x915, 0x94d, 0x930, 0x935, 0x93e, 0x930, 0x3b, 0x936, 0x928, 0x93f, 0x935, 0x93e, 0x930, 0x3b, 0x906, 0x907, 0x924, 0x3b,
-0x938, 0x94b, 0x92e, 0x3b, 0x92e, 0x919, 0x94d, 0x917, 0x932, 0x3b, 0x92c, 0x941, 0x927, 0x3b, 0x92c, 0x93f, 0x939, 0x940, 0x3b, 0x936,
-0x941, 0x915, 0x94d, 0x930, 0x3b, 0x936, 0x928, 0x93f, 0x3b, 0x906, 0x907, 0x924, 0x92c, 0x93e, 0x930, 0x3b, 0x938, 0x94b, 0x92e, 0x92c,
-0x93e, 0x930, 0x3b, 0x92e, 0x919, 0x94d, 0x917, 0x932, 0x92c, 0x93e, 0x930, 0x3b, 0x92c, 0x941, 0x927, 0x92c, 0x93e, 0x930, 0x3b, 0x92c,
-0x93f, 0x939, 0x940, 0x92c, 0x93e, 0x930, 0x3b, 0x936, 0x941, 0x915, 0x94d, 0x930, 0x92c, 0x93e, 0x930, 0x3b, 0x936, 0x928, 0x93f, 0x92c,
-0x93e, 0x930, 0x3b, 0x967, 0x3b, 0x968, 0x3b, 0x969, 0x3b, 0x96a, 0x3b, 0x96b, 0x3b, 0x96c, 0x3b, 0x96d, 0x3b, 0x906, 0x907, 0x924,
-0x935, 0x93e, 0x930, 0x3b, 0x938, 0x94b, 0x92e, 0x935, 0x93e, 0x930, 0x3b, 0x92e, 0x919, 0x94d, 0x917, 0x932, 0x935, 0x93e, 0x930, 0x3b,
-0x92c, 0x941, 0x927, 0x935, 0x93e, 0x930, 0x3b, 0x92c, 0x93f, 0x939, 0x940, 0x935, 0x93e, 0x930, 0x3b, 0x936, 0x941, 0x915, 0x94d, 0x930,
-0x935, 0x93e, 0x930, 0x3b, 0x936, 0x928, 0x93f, 0x935, 0x93e, 0x930, 0x3b, 0x73, 0xf8, 0x2e, 0x3b, 0x6d, 0x61, 0x2e, 0x3b, 0x74,
-0x69, 0x2e, 0x3b, 0x6f, 0x6e, 0x2e, 0x3b, 0x74, 0x6f, 0x2e, 0x3b, 0x66, 0x72, 0x2e, 0x3b, 0x6c, 0xf8, 0x2e, 0x3b, 0xb30,
-0xb2c, 0xb3f, 0x3b, 0xb38, 0xb4b, 0xb2e, 0x3b, 0xb2e, 0xb19, 0xb4d, 0xb17, 0xb33, 0x3b, 0xb2c, 0xb41, 0xb27, 0x3b, 0xb17, 0xb41, 0xb30,
-0xb41, 0x3b, 0xb36, 0xb41, 0xb15, 0xb4d, 0xb30, 0x3b, 0xb36, 0xb28, 0xb3f, 0x3b, 0xb30, 0xb2c, 0xb3f, 0xb2c, 0xb3e, 0xb30, 0x3b, 0xb38,
-0xb4b, 0xb2e, 0xb2c, 0xb3e, 0xb30, 0x3b, 0xb2e, 0xb19, 0xb4d, 0xb17, 0xb33, 0xb2c, 0xb3e, 0xb30, 0x3b, 0xb2c, 0xb41, 0xb27, 0xb2c, 0xb3e,
-0xb30, 0x3b, 0xb17, 0xb41, 0xb30, 0xb41, 0xb2c, 0xb3e, 0xb30, 0x3b, 0xb36, 0xb41, 0xb15, 0xb4d, 0xb30, 0xb2c, 0xb3e, 0xb30, 0x3b, 0xb36,
-0xb28, 0xb3f, 0xb2c, 0xb3e, 0xb30, 0x3b, 0xb30, 0x3b, 0xb38, 0xb4b, 0x3b, 0xb2e, 0x3b, 0xb2c, 0xb41, 0x3b, 0xb17, 0xb41, 0x3b, 0xb36,
-0xb41, 0x3b, 0xb36, 0x3b, 0x6cc, 0x6a9, 0x634, 0x646, 0x628, 0x647, 0x3b, 0x62f, 0x648, 0x634, 0x646, 0x628, 0x647, 0x3b, 0x633, 0x647,
-0x200c, 0x634, 0x646, 0x628, 0x647, 0x3b, 0x686, 0x647, 0x627, 0x631, 0x634, 0x646, 0x628, 0x647, 0x3b, 0x67e, 0x646, 0x62c, 0x634, 0x646,
-0x628, 0x647, 0x3b, 0x62c, 0x645, 0x639, 0x647, 0x3b, 0x634, 0x646, 0x628, 0x647, 0x3b, 0x6cc, 0x3b, 0x62f, 0x3b, 0x633, 0x3b, 0x686,
-0x3b, 0x67e, 0x3b, 0x62c, 0x3b, 0x634, 0x3b, 0x6e, 0x69, 0x65, 0x64, 0x7a, 0x2e, 0x3b, 0x70, 0x6f, 0x6e, 0x2e, 0x3b, 0x77,
-0x74, 0x2e, 0x3b, 0x15b, 0x72, 0x2e, 0x3b, 0x63, 0x7a, 0x77, 0x2e, 0x3b, 0x70, 0x74, 0x2e, 0x3b, 0x73, 0x6f, 0x62, 0x2e,
-0x3b, 0x6e, 0x69, 0x65, 0x64, 0x7a, 0x69, 0x65, 0x6c, 0x61, 0x3b, 0x70, 0x6f, 0x6e, 0x69, 0x65, 0x64, 0x7a, 0x69, 0x61,
-0x142, 0x65, 0x6b, 0x3b, 0x77, 0x74, 0x6f, 0x72, 0x65, 0x6b, 0x3b, 0x15b, 0x72, 0x6f, 0x64, 0x61, 0x3b, 0x63, 0x7a, 0x77,
-0x61, 0x72, 0x74, 0x65, 0x6b, 0x3b, 0x70, 0x69, 0x105, 0x74, 0x65, 0x6b, 0x3b, 0x73, 0x6f, 0x62, 0x6f, 0x74, 0x61, 0x3b,
-0x4e, 0x3b, 0x50, 0x3b, 0x57, 0x3b, 0x15a, 0x3b, 0x43, 0x3b, 0x50, 0x3b, 0x53, 0x3b, 0x64, 0x6f, 0x6d, 0x3b, 0x73, 0x65,
-0x67, 0x3b, 0x74, 0x65, 0x72, 0x3b, 0x71, 0x75, 0x61, 0x3b, 0x71, 0x75, 0x69, 0x3b, 0x73, 0x65, 0x78, 0x3b, 0x73, 0xe1,
-0x62, 0x3b, 0x64, 0x6f, 0x6d, 0x69, 0x6e, 0x67, 0x6f, 0x3b, 0x73, 0x65, 0x67, 0x75, 0x6e, 0x64, 0x61, 0x2d, 0x66, 0x65,
-0x69, 0x72, 0x61, 0x3b, 0x74, 0x65, 0x72, 0xe7, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x71, 0x75, 0x61, 0x72,
-0x74, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x71, 0x75, 0x69, 0x6e, 0x74, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72,
-0x61, 0x3b, 0x73, 0x65, 0x78, 0x74, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x73, 0xe1, 0x62, 0x61, 0x64, 0x6f,
-0x3b, 0x44, 0x3b, 0x53, 0x3b, 0x54, 0x3b, 0x51, 0x3b, 0x51, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x44, 0x6f, 0x6d, 0x69, 0x6e,
-0x67, 0x6f, 0x3b, 0x53, 0x65, 0x67, 0x75, 0x6e, 0x64, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x54, 0x65, 0x72,
-0xe7, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x51, 0x75, 0x61, 0x72, 0x74, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72,
-0x61, 0x3b, 0x51, 0x75, 0x69, 0x6e, 0x74, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x53, 0x65, 0x78, 0x74, 0x61,
-0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x53, 0xe1, 0x62, 0x61, 0x64, 0x6f, 0x3b, 0xa10, 0xa24, 0x2e, 0x3b, 0xa38, 0xa4b,
-0xa2e, 0x2e, 0x3b, 0xa2e, 0xa70, 0xa17, 0xa32, 0x2e, 0x3b, 0xa2c, 0xa41, 0xa27, 0x2e, 0x3b, 0xa35, 0xa40, 0xa30, 0x2e, 0x3b, 0xa38,
-0xa3c, 0xa41, 0xa15, 0xa30, 0x2e, 0x3b, 0xa38, 0xa3c, 0xa28, 0xa40, 0x2e, 0x3b, 0xa10, 0xa24, 0xa35, 0xa3e, 0xa30, 0x3b, 0xa38, 0xa4b,
-0xa2e, 0xa35, 0xa3e, 0xa30, 0x3b, 0xa2e, 0xa70, 0xa17, 0xa32, 0xa35, 0xa3e, 0xa30, 0x3b, 0xa2c, 0xa41, 0xa27, 0xa35, 0xa3e, 0xa30, 0x3b,
-0xa35, 0xa40, 0xa30, 0xa35, 0xa3e, 0xa30, 0x3b, 0xa38, 0xa3c, 0xa41, 0xa71, 0xa15, 0xa30, 0xa35, 0xa3e, 0xa30, 0x3b, 0xa38, 0xa3c, 0xa28,
-0xa40, 0xa1a, 0xa30, 0xa35, 0xa3e, 0xa30, 0x3b, 0xa10, 0x3b, 0xa38, 0xa4b, 0x3b, 0xa2e, 0xa70, 0x3b, 0xa2c, 0xa41, 0xa71, 0x3b, 0xa35,
-0xa40, 0x3b, 0xa38, 0xa3c, 0xa41, 0xa71, 0x3b, 0xa38, 0xa3c, 0x3b, 0x627, 0x62a, 0x648, 0x627, 0x631, 0x3b, 0x67e, 0x6cc, 0x631, 0x3b,
-0x645, 0x646, 0x6af, 0x644, 0x3b, 0x628, 0x64f, 0x62f, 0x6be, 0x3b, 0x62c, 0x645, 0x639, 0x631, 0x627, 0x62a, 0x3b, 0x62c, 0x645, 0x639,
-0x6c1, 0x3b, 0x6c1, 0x641, 0x62a, 0x6c1, 0x3b, 0x64, 0x75, 0x3b, 0x67, 0x6c, 0x69, 0x3b, 0x6d, 0x61, 0x3b, 0x6d, 0x65, 0x3b,
-0x67, 0x69, 0x65, 0x3b, 0x76, 0x65, 0x3b, 0x73, 0x6f, 0x3b, 0x64, 0x75, 0x6d, 0x65, 0x6e, 0x67, 0x69, 0x61, 0x3b, 0x67,
-0x6c, 0x69, 0x6e, 0x64, 0x65, 0x73, 0x64, 0x69, 0x3b, 0x6d, 0x61, 0x72, 0x64, 0x69, 0x3b, 0x6d, 0x65, 0x73, 0x65, 0x6d,
-0x6e, 0x61, 0x3b, 0x67, 0x69, 0x65, 0x76, 0x67, 0x69, 0x61, 0x3b, 0x76, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x64, 0x69, 0x3b,
-0x73, 0x6f, 0x6e, 0x64, 0x61, 0x3b, 0x44, 0x3b, 0x47, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x47, 0x3b, 0x56, 0x3b, 0x53, 0x3b,
-0x44, 0x75, 0x3b, 0x4c, 0x75, 0x3b, 0x4d, 0x61, 0x3b, 0x4d, 0x69, 0x3b, 0x4a, 0x6f, 0x3b, 0x56, 0x69, 0x3b, 0x53, 0xe2,
-0x3b, 0x64, 0x75, 0x6d, 0x69, 0x6e, 0x69, 0x63, 0x103, 0x3b, 0x6c, 0x75, 0x6e, 0x69, 0x3b, 0x6d, 0x61, 0x72, 0x21b, 0x69,
-0x3b, 0x6d, 0x69, 0x65, 0x72, 0x63, 0x75, 0x72, 0x69, 0x3b, 0x6a, 0x6f, 0x69, 0x3b, 0x76, 0x69, 0x6e, 0x65, 0x72, 0x69,
-0x3b, 0x73, 0xe2, 0x6d, 0x62, 0x103, 0x74, 0x103, 0x3b, 0x412, 0x441, 0x3b, 0x41f, 0x43d, 0x3b, 0x412, 0x442, 0x3b, 0x421, 0x440,
-0x3b, 0x427, 0x442, 0x3b, 0x41f, 0x442, 0x3b, 0x421, 0x431, 0x3b, 0x412, 0x43e, 0x441, 0x43a, 0x440, 0x435, 0x441, 0x435, 0x43d, 0x44c,
-0x435, 0x3b, 0x41f, 0x43e, 0x43d, 0x435, 0x434, 0x435, 0x43b, 0x44c, 0x43d, 0x438, 0x43a, 0x3b, 0x412, 0x442, 0x43e, 0x440, 0x43d, 0x438,
-0x43a, 0x3b, 0x421, 0x440, 0x435, 0x434, 0x430, 0x3b, 0x427, 0x435, 0x442, 0x432, 0x435, 0x440, 0x433, 0x3b, 0x41f, 0x44f, 0x442, 0x43d,
-0x438, 0x446, 0x430, 0x3b, 0x421, 0x443, 0x431, 0x431, 0x43e, 0x442, 0x430, 0x3b, 0x412, 0x3b, 0x41f, 0x3b, 0x412, 0x3b, 0x421, 0x3b,
-0x427, 0x3b, 0x41f, 0x3b, 0x421, 0x3b, 0x432, 0x441, 0x3b, 0x43f, 0x43d, 0x3b, 0x432, 0x442, 0x3b, 0x441, 0x440, 0x3b, 0x447, 0x442,
-0x3b, 0x43f, 0x442, 0x3b, 0x441, 0x431, 0x3b, 0x432, 0x43e, 0x441, 0x43a, 0x440, 0x435, 0x441, 0x435, 0x43d, 0x44c, 0x435, 0x3b, 0x43f,
-0x43e, 0x43d, 0x435, 0x434, 0x435, 0x43b, 0x44c, 0x43d, 0x438, 0x43a, 0x3b, 0x432, 0x442, 0x43e, 0x440, 0x43d, 0x438, 0x43a, 0x3b, 0x441,
-0x440, 0x435, 0x434, 0x430, 0x3b, 0x447, 0x435, 0x442, 0x432, 0x435, 0x440, 0x433, 0x3b, 0x43f, 0x44f, 0x442, 0x43d, 0x438, 0x446, 0x430,
-0x3b, 0x441, 0x443, 0x431, 0x431, 0x43e, 0x442, 0x430, 0x3b, 0x42, 0x6b, 0x31, 0x3b, 0x42, 0x6b, 0x32, 0x3b, 0x42, 0x6b, 0x33,
-0x3b, 0x42, 0x6b, 0x34, 0x3b, 0x42, 0x6b, 0x35, 0x3b, 0x4c, 0xe2, 0x70, 0x3b, 0x4c, 0xe2, 0x79, 0x3b, 0x42, 0x69, 0x6b,
-0x75, 0x61, 0x2d, 0xf4, 0x6b, 0x6f, 0x3b, 0x42, 0xef, 0x6b, 0x75, 0x61, 0x2d, 0xfb, 0x73, 0x65, 0x3b, 0x42, 0xef, 0x6b,
-0x75, 0x61, 0x2d, 0x70, 0x74, 0xe2, 0x3b, 0x42, 0xef, 0x6b, 0x75, 0x61, 0x2d, 0x75, 0x73, 0xef, 0xf6, 0x3b, 0x42, 0xef,
-0x6b, 0x75, 0x61, 0x2d, 0x6f, 0x6b, 0xfc, 0x3b, 0x4c, 0xe2, 0x70, 0xf4, 0x73, 0xf6, 0x3b, 0x4c, 0xe2, 0x79, 0x65, 0x6e,
-0x67, 0x61, 0x3b, 0x4b, 0x3b, 0x53, 0x3b, 0x54, 0x3b, 0x53, 0x3b, 0x4b, 0x3b, 0x50, 0x3b, 0x59, 0x3b, 0x43d, 0x435, 0x434,
-0x3b, 0x43f, 0x43e, 0x43d, 0x3b, 0x443, 0x442, 0x43e, 0x3b, 0x441, 0x440, 0x435, 0x3b, 0x447, 0x435, 0x442, 0x3b, 0x43f, 0x435, 0x442,
-0x3b, 0x441, 0x443, 0x431, 0x3b, 0x43d, 0x435, 0x434, 0x435, 0x459, 0x430, 0x3b, 0x43f, 0x43e, 0x43d, 0x435, 0x434, 0x435, 0x459, 0x430,
-0x43a, 0x3b, 0x443, 0x442, 0x43e, 0x440, 0x430, 0x43a, 0x3b, 0x441, 0x440, 0x435, 0x434, 0x430, 0x3b, 0x447, 0x435, 0x442, 0x432, 0x440,
-0x442, 0x430, 0x43a, 0x3b, 0x43f, 0x435, 0x442, 0x430, 0x43a, 0x3b, 0x441, 0x443, 0x431, 0x43e, 0x442, 0x430, 0x3b, 0x43d, 0x3b, 0x43f,
-0x3b, 0x443, 0x3b, 0x441, 0x3b, 0x447, 0x3b, 0x43f, 0x3b, 0x441, 0x3b, 0x43d, 0x435, 0x434, 0x3b, 0x43f, 0x43e, 0x43d, 0x3b, 0x443,
-0x442, 0x43e, 0x3b, 0x441, 0x440, 0x438, 0x3b, 0x447, 0x435, 0x442, 0x3b, 0x43f, 0x435, 0x442, 0x3b, 0x441, 0x443, 0x431, 0x3b, 0x43d,
-0x435, 0x434, 0x435, 0x459, 0x430, 0x3b, 0x43f, 0x43e, 0x43d, 0x435, 0x434, 0x435, 0x459, 0x430, 0x43a, 0x3b, 0x443, 0x442, 0x43e, 0x440,
-0x430, 0x43a, 0x3b, 0x441, 0x440, 0x438, 0x458, 0x435, 0x434, 0x430, 0x3b, 0x447, 0x435, 0x442, 0x432, 0x440, 0x442, 0x430, 0x43a, 0x3b,
-0x43f, 0x435, 0x442, 0x430, 0x43a, 0x3b, 0x441, 0x443, 0x431, 0x43e, 0x442, 0x430, 0x3b, 0x6e, 0x65, 0x64, 0x3b, 0x70, 0x6f, 0x6e,
-0x3b, 0x75, 0x74, 0x6f, 0x3b, 0x73, 0x72, 0x65, 0x3b, 0x10d, 0x65, 0x74, 0x3b, 0x70, 0x65, 0x74, 0x3b, 0x73, 0x75, 0x62,
-0x3b, 0x6e, 0x65, 0x64, 0x65, 0x6c, 0x6a, 0x61, 0x3b, 0x70, 0x6f, 0x6e, 0x65, 0x64, 0x65, 0x6c, 0x6a, 0x61, 0x6b, 0x3b,
-0x75, 0x74, 0x6f, 0x72, 0x61, 0x6b, 0x3b, 0x73, 0x72, 0x65, 0x64, 0x61, 0x3b, 0x10d, 0x65, 0x74, 0x76, 0x72, 0x74, 0x61,
-0x6b, 0x3b, 0x70, 0x65, 0x74, 0x61, 0x6b, 0x3b, 0x73, 0x75, 0x62, 0x6f, 0x74, 0x61, 0x3b, 0x425, 0x446, 0x431, 0x3b, 0x41a,
-0x440, 0x441, 0x3b, 0x414, 0x446, 0x433, 0x3b, 0x4d4, 0x440, 0x442, 0x3b, 0x426, 0x43f, 0x440, 0x3b, 0x41c, 0x440, 0x431, 0x3b, 0x421,
-0x431, 0x442, 0x3b, 0x425, 0x443, 0x44b, 0x446, 0x430, 0x443, 0x431, 0x43e, 0x43d, 0x3b, 0x41a, 0x44a, 0x443, 0x44b, 0x440, 0x438, 0x441,
-0x4d5, 0x440, 0x3b, 0x414, 0x44b, 0x446, 0x446, 0x4d5, 0x433, 0x3b, 0x4d4, 0x440, 0x442, 0x44b, 0x446, 0x446, 0x4d5, 0x433, 0x3b, 0x426,
-0x44b, 0x43f, 0x43f, 0x4d5, 0x440, 0x4d5, 0x43c, 0x3b, 0x41c, 0x430, 0x439, 0x440, 0x4d5, 0x43c, 0x431, 0x43e, 0x43d, 0x3b, 0x421, 0x430,
-0x431, 0x430, 0x442, 0x3b, 0x425, 0x3b, 0x41a, 0x3b, 0x414, 0x3b, 0x4d4, 0x3b, 0x426, 0x3b, 0x41c, 0x3b, 0x421, 0x3b, 0x445, 0x446,
-0x431, 0x3b, 0x43a, 0x440, 0x441, 0x3b, 0x434, 0x446, 0x433, 0x3b, 0x4d5, 0x440, 0x442, 0x3b, 0x446, 0x43f, 0x440, 0x3b, 0x43c, 0x440,
-0x431, 0x3b, 0x441, 0x431, 0x442, 0x3b, 0x445, 0x443, 0x44b, 0x446, 0x430, 0x443, 0x431, 0x43e, 0x43d, 0x3b, 0x43a, 0x44a, 0x443, 0x44b,
-0x440, 0x438, 0x441, 0x4d5, 0x440, 0x3b, 0x434, 0x44b, 0x446, 0x446, 0x4d5, 0x433, 0x3b, 0x4d5, 0x440, 0x442, 0x44b, 0x446, 0x446, 0x4d5,
-0x433, 0x3b, 0x446, 0x44b, 0x43f, 0x43f, 0x4d5, 0x440, 0x4d5, 0x43c, 0x3b, 0x43c, 0x430, 0x439, 0x440, 0x4d5, 0x43c, 0x431, 0x43e, 0x43d,
-0x3b, 0x441, 0x430, 0x431, 0x430, 0x442, 0x3b, 0x53, 0x6f, 0x6e, 0x3b, 0x4d, 0x6d, 0x61, 0x3b, 0x42, 0x65, 0x64, 0x3b, 0x52,
-0x61, 0x72, 0x3b, 0x4e, 0x65, 0x3b, 0x48, 0x6c, 0x61, 0x3b, 0x4d, 0x6f, 0x71, 0x3b, 0x53, 0x6f, 0x6e, 0x74, 0x61, 0x68,
-0x61, 0x3b, 0x4d, 0x6d, 0x61, 0x6e, 0x74, 0x61, 0x68, 0x61, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x62, 0x65, 0x64, 0x69, 0x3b,
-0x4c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x72, 0x75, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x6e, 0x65, 0x3b, 0x4c, 0x61, 0x62, 0x6f,
-0x68, 0x6c, 0x61, 0x6e, 0x65, 0x3b, 0x4d, 0x6f, 0x71, 0x65, 0x62, 0x65, 0x6c, 0x6f, 0x3b, 0x54, 0x73, 0x68, 0x3b, 0x4d,
-0x6f, 0x73, 0x3b, 0x42, 0x65, 0x64, 0x3b, 0x52, 0x61, 0x72, 0x3b, 0x4e, 0x65, 0x3b, 0x54, 0x6c, 0x61, 0x3b, 0x4d, 0x61,
-0x74, 0x3b, 0x54, 0x73, 0x68, 0x69, 0x70, 0x69, 0x3b, 0x4d, 0x6f, 0x73, 0x6f, 0x70, 0x75, 0x6c, 0x6f, 0x67, 0x6f, 0x3b,
-0x4c, 0x61, 0x62, 0x6f, 0x62, 0x65, 0x64, 0x69, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x72, 0x6f, 0x3b, 0x4c, 0x61,
-0x62, 0x6f, 0x6e, 0x65, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x74, 0x6c, 0x68, 0x61, 0x6e, 0x6f, 0x3b, 0x4d, 0x61, 0x74, 0x6c,
-0x68, 0x61, 0x74, 0x73, 0x6f, 0x3b, 0x53, 0x76, 0x6f, 0x3b, 0x4d, 0x75, 0x76, 0x3b, 0x43, 0x68, 0x69, 0x70, 0x3b, 0x43,
-0x68, 0x69, 0x74, 0x3b, 0x43, 0x68, 0x69, 0x6e, 0x3b, 0x43, 0x68, 0x69, 0x73, 0x3b, 0x4d, 0x75, 0x67, 0x3b, 0x53, 0x76,
-0x6f, 0x6e, 0x64, 0x6f, 0x3b, 0x4d, 0x75, 0x76, 0x68, 0x75, 0x72, 0x6f, 0x3b, 0x43, 0x68, 0x69, 0x70, 0x69, 0x72, 0x69,
-0x3b, 0x43, 0x68, 0x69, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x43, 0x68, 0x69, 0x6e, 0x61, 0x3b, 0x43, 0x68, 0x69, 0x73, 0x68,
-0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x75, 0x67, 0x6f, 0x76, 0x65, 0x72, 0x61, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x43, 0x3b, 0x43,
-0x3b, 0x43, 0x3b, 0x43, 0x3b, 0x4d, 0x3b, 0xd89, 0xdbb, 0xdd2, 0x3b, 0xdc3, 0xdb3, 0xdd4, 0x3b, 0xd85, 0xd9f, 0x3b, 0xdb6, 0xdaf,
-0xdcf, 0x3b, 0xdb6, 0xdca, 0x200d, 0xdbb, 0xdc4, 0x3b, 0xdc3, 0xdd2, 0xd9a, 0xdd4, 0x3b, 0xdc3, 0xdd9, 0xdb1, 0x3b, 0xd89, 0xdbb, 0xdd2,
-0xdaf, 0xdcf, 0x3b, 0xdc3, 0xdb3, 0xdd4, 0xdaf, 0xdcf, 0x3b, 0xd85, 0xd9f, 0xdc4, 0xdbb, 0xdd4, 0xdc0, 0xdcf, 0xdaf, 0xdcf, 0x3b, 0xdb6,
-0xdaf, 0xdcf, 0xdaf, 0xdcf, 0x3b, 0xdb6, 0xdca, 0x200d, 0xdbb, 0xdc4, 0xdc3, 0xdca, 0xdb4, 0xdad, 0xdd2, 0xdb1, 0xdca, 0xdaf, 0xdcf, 0x3b,
-0xdc3, 0xdd2, 0xd9a, 0xdd4, 0xdbb, 0xdcf, 0xdaf, 0xdcf, 0x3b, 0xdc3, 0xdd9, 0xdb1, 0xdc3, 0xdd4, 0xdbb, 0xdcf, 0xdaf, 0xdcf, 0x3b, 0xd89,
-0x3b, 0xdc3, 0x3b, 0xd85, 0x3b, 0xdb6, 0x3b, 0xdb6, 0xdca, 0x200d, 0xdbb, 0x3b, 0xdc3, 0xdd2, 0x3b, 0xdc3, 0xdd9, 0x3b, 0x53, 0x6f,
-0x6e, 0x3b, 0x4d, 0x73, 0x6f, 0x3b, 0x42, 0x69, 0x6c, 0x3b, 0x54, 0x73, 0x61, 0x3b, 0x4e, 0x65, 0x3b, 0x48, 0x6c, 0x61,
-0x3b, 0x4d, 0x67, 0x63, 0x3b, 0x4c, 0x69, 0x73, 0x6f, 0x6e, 0x74, 0x66, 0x6f, 0x3b, 0x75, 0x4d, 0x73, 0x6f, 0x6d, 0x62,
-0x75, 0x6c, 0x75, 0x6b, 0x6f, 0x3b, 0x4c, 0x65, 0x73, 0x69, 0x62, 0x69, 0x6c, 0x69, 0x3b, 0x4c, 0x65, 0x73, 0x69, 0x74,
-0x73, 0x61, 0x74, 0x66, 0x75, 0x3b, 0x4c, 0x65, 0x73, 0x69, 0x6e, 0x65, 0x3b, 0x4c, 0x65, 0x73, 0x69, 0x68, 0x6c, 0x61,
-0x6e, 0x75, 0x3b, 0x75, 0x4d, 0x67, 0x63, 0x69, 0x62, 0x65, 0x6c, 0x6f, 0x3b, 0x6e, 0x65, 0x3b, 0x70, 0x6f, 0x3b, 0x75,
-0x74, 0x3b, 0x73, 0x74, 0x3b, 0x161, 0x74, 0x3b, 0x70, 0x69, 0x3b, 0x73, 0x6f, 0x3b, 0x6e, 0x65, 0x64, 0x65, 0x13e, 0x61,
-0x3b, 0x70, 0x6f, 0x6e, 0x64, 0x65, 0x6c, 0x6f, 0x6b, 0x3b, 0x75, 0x74, 0x6f, 0x72, 0x6f, 0x6b, 0x3b, 0x73, 0x74, 0x72,
-0x65, 0x64, 0x61, 0x3b, 0x161, 0x74, 0x76, 0x72, 0x74, 0x6f, 0x6b, 0x3b, 0x70, 0x69, 0x61, 0x74, 0x6f, 0x6b, 0x3b, 0x73,
-0x6f, 0x62, 0x6f, 0x74, 0x61, 0x3b, 0x4e, 0x3b, 0x50, 0x3b, 0x55, 0x3b, 0x53, 0x3b, 0x160, 0x3b, 0x50, 0x3b, 0x53, 0x3b,
-0x6e, 0x65, 0x64, 0x3b, 0x70, 0x6f, 0x6e, 0x3b, 0x74, 0x6f, 0x72, 0x3b, 0x73, 0x72, 0x65, 0x3b, 0x10d, 0x65, 0x74, 0x3b,
-0x70, 0x65, 0x74, 0x3b, 0x73, 0x6f, 0x62, 0x3b, 0x6e, 0x65, 0x64, 0x65, 0x6c, 0x6a, 0x61, 0x3b, 0x70, 0x6f, 0x6e, 0x65,
-0x64, 0x65, 0x6c, 0x6a, 0x65, 0x6b, 0x3b, 0x74, 0x6f, 0x72, 0x65, 0x6b, 0x3b, 0x73, 0x72, 0x65, 0x64, 0x61, 0x3b, 0x10d,
-0x65, 0x74, 0x72, 0x74, 0x65, 0x6b, 0x3b, 0x70, 0x65, 0x74, 0x65, 0x6b, 0x3b, 0x73, 0x6f, 0x62, 0x6f, 0x74, 0x61, 0x3b,
-0x6e, 0x3b, 0x70, 0x3b, 0x74, 0x3b, 0x73, 0x3b, 0x10d, 0x3b, 0x70, 0x3b, 0x73, 0x3b, 0x6e, 0x65, 0x64, 0x2e, 0x3b, 0x70,
-0x6f, 0x6e, 0x2e, 0x3b, 0x74, 0x6f, 0x72, 0x2e, 0x3b, 0x73, 0x72, 0x65, 0x2e, 0x3b, 0x10d, 0x65, 0x74, 0x2e, 0x3b, 0x70,
-0x65, 0x74, 0x2e, 0x3b, 0x73, 0x6f, 0x62, 0x2e, 0x3b, 0x41, 0x78, 0x64, 0x3b, 0x49, 0x73, 0x6e, 0x3b, 0x54, 0x61, 0x6c,
-0x3b, 0x41, 0x72, 0x62, 0x3b, 0x4b, 0x68, 0x61, 0x3b, 0x4a, 0x69, 0x6d, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x41, 0x78, 0x61,
-0x64, 0x3b, 0x49, 0x73, 0x6e, 0x69, 0x69, 0x6e, 0x3b, 0x54, 0x61, 0x6c, 0x61, 0x61, 0x64, 0x6f, 0x3b, 0x41, 0x72, 0x62,
-0x61, 0x63, 0x6f, 0x3b, 0x4b, 0x68, 0x61, 0x6d, 0x69, 0x69, 0x73, 0x3b, 0x4a, 0x69, 0x6d, 0x63, 0x6f, 0x3b, 0x53, 0x61,
-0x62, 0x74, 0x69, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x54, 0x3b, 0x41, 0x3b, 0x4b, 0x3b, 0x4a, 0x3b, 0x53, 0x3b, 0x64, 0x6f,
-0x6d, 0x3b, 0x6c, 0x75, 0x6e, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x6d, 0x69, 0xe9, 0x3b, 0x6a, 0x75, 0x65, 0x3b, 0x76, 0x69,
-0x65, 0x3b, 0x73, 0xe1, 0x62, 0x3b, 0x64, 0x6f, 0x6d, 0x69, 0x6e, 0x67, 0x6f, 0x3b, 0x6c, 0x75, 0x6e, 0x65, 0x73, 0x3b,
-0x6d, 0x61, 0x72, 0x74, 0x65, 0x73, 0x3b, 0x6d, 0x69, 0xe9, 0x72, 0x63, 0x6f, 0x6c, 0x65, 0x73, 0x3b, 0x6a, 0x75, 0x65,
-0x76, 0x65, 0x73, 0x3b, 0x76, 0x69, 0x65, 0x72, 0x6e, 0x65, 0x73, 0x3b, 0x73, 0xe1, 0x62, 0x61, 0x64, 0x6f, 0x3b, 0x44,
-0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x58, 0x3b, 0x4a, 0x3b, 0x56, 0x3b, 0x53, 0x3b, 0x4a, 0x32, 0x3b, 0x4a, 0x33, 0x3b, 0x4a,
-0x34, 0x3b, 0x4a, 0x35, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x49, 0x6a, 0x3b, 0x4a, 0x31, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x70,
-0x69, 0x6c, 0x69, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6e, 0x6e, 0x65,
-0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x49,
-0x6a, 0x75, 0x6d, 0x61, 0x61, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x32, 0x3b, 0x33, 0x3b, 0x34,
-0x3b, 0x35, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x31, 0x3b, 0x73, 0xf6, 0x6e, 0x3b, 0x6d, 0xe5, 0x6e, 0x3b, 0x74, 0x69, 0x73,
-0x3b, 0x6f, 0x6e, 0x73, 0x3b, 0x74, 0x6f, 0x72, 0x3b, 0x66, 0x72, 0x65, 0x3b, 0x6c, 0xf6, 0x72, 0x3b, 0x73, 0xf6, 0x6e,
-0x64, 0x61, 0x67, 0x3b, 0x6d, 0xe5, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x74, 0x69, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x6f, 0x6e,
-0x73, 0x64, 0x61, 0x67, 0x3b, 0x74, 0x6f, 0x72, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x66, 0x72, 0x65, 0x64, 0x61, 0x67, 0x3b,
-0x6c, 0xf6, 0x72, 0x64, 0x61, 0x67, 0x3b, 0x73, 0xf6, 0x6e, 0x3b, 0x6d, 0xe5, 0x6e, 0x3b, 0x74, 0x69, 0x73, 0x3b, 0x6f,
-0x6e, 0x73, 0x3b, 0x74, 0x6f, 0x72, 0x73, 0x3b, 0x66, 0x72, 0x65, 0x3b, 0x6c, 0xf6, 0x72, 0x3b, 0x42f, 0x448, 0x431, 0x3b,
-0x414, 0x448, 0x431, 0x3b, 0x421, 0x448, 0x431, 0x3b, 0x427, 0x448, 0x431, 0x3b, 0x41f, 0x448, 0x431, 0x3b, 0x4b6, 0x43c, 0x44a, 0x3b,
-0x428, 0x43d, 0x431, 0x3b, 0x42f, 0x43a, 0x448, 0x430, 0x43d, 0x431, 0x435, 0x3b, 0x414, 0x443, 0x448, 0x430, 0x43d, 0x431, 0x435, 0x3b,
-0x421, 0x435, 0x448, 0x430, 0x43d, 0x431, 0x435, 0x3b, 0x427, 0x43e, 0x440, 0x448, 0x430, 0x43d, 0x431, 0x435, 0x3b, 0x41f, 0x430, 0x43d,
-0x4b7, 0x448, 0x430, 0x43d, 0x431, 0x435, 0x3b, 0x4b6, 0x443, 0x43c, 0x44a, 0x430, 0x3b, 0x428, 0x430, 0x43d, 0x431, 0x435, 0x3b, 0xb9e,
-0xbbe, 0x3b, 0xba4, 0xbbf, 0x3b, 0xb9a, 0xbc6, 0x3b, 0xbaa, 0xbc1, 0x3b, 0xbb5, 0xbbf, 0x3b, 0xbb5, 0xbc6, 0x3b, 0xb9a, 0x3b, 0xb9e,
-0xbbe, 0xbaf, 0xbbf, 0xbb1, 0xbc1, 0x3b, 0xba4, 0xbbf, 0xb99, 0xbcd, 0xb95, 0xbb3, 0xbcd, 0x3b, 0xb9a, 0xbc6, 0xbb5, 0xbcd, 0xbb5, 0xbbe,
-0xbaf, 0xbcd, 0x3b, 0xbaa, 0xbc1, 0xba4, 0xba9, 0xbcd, 0x3b, 0xbb5, 0xbbf, 0xbaf, 0xbbe, 0xbb4, 0xba9, 0xbcd, 0x3b, 0xbb5, 0xbc6, 0xbb3,
-0xbcd, 0xbb3, 0xbbf, 0x3b, 0xb9a, 0xba9, 0xbbf, 0x3b, 0xc06, 0xc26, 0xc3f, 0x3b, 0xc38, 0xc4b, 0xc2e, 0x3b, 0xc2e, 0xc02, 0xc17, 0xc33,
-0x3b, 0xc2c, 0xc41, 0xc27, 0x3b, 0xc17, 0xc41, 0xc30, 0xc41, 0x3b, 0xc36, 0xc41, 0xc15, 0xc4d, 0xc30, 0x3b, 0xc36, 0xc28, 0xc3f, 0x3b,
-0xc06, 0xc26, 0xc3f, 0xc35, 0xc3e, 0xc30, 0xc02, 0x3b, 0xc38, 0xc4b, 0xc2e, 0xc35, 0xc3e, 0xc30, 0xc02, 0x3b, 0xc2e, 0xc02, 0xc17, 0xc33,
-0xc35, 0xc3e, 0xc30, 0xc02, 0x3b, 0xc2c, 0xc41, 0xc27, 0xc35, 0xc3e, 0xc30, 0xc02, 0x3b, 0xc17, 0xc41, 0xc30, 0xc41, 0xc35, 0xc3e, 0xc30,
-0xc02, 0x3b, 0xc36, 0xc41, 0xc15, 0xc4d, 0xc30, 0xc35, 0xc3e, 0xc30, 0xc02, 0x3b, 0xc36, 0xc28, 0xc3f, 0xc35, 0xc3e, 0xc30, 0xc02, 0x3b,
-0xc06, 0x3b, 0xc38, 0xc4b, 0x3b, 0xc2e, 0x3b, 0xc2c, 0xc41, 0x3b, 0xc17, 0xc41, 0x3b, 0xc36, 0xc41, 0x3b, 0xc36, 0x3b, 0xe2d, 0xe32,
-0x2e, 0x3b, 0xe08, 0x2e, 0x3b, 0xe2d, 0x2e, 0x3b, 0xe1e, 0x2e, 0x3b, 0xe1e, 0xe24, 0x2e, 0x3b, 0xe28, 0x2e, 0x3b, 0xe2a, 0x2e,
-0x3b, 0xe27, 0xe31, 0xe19, 0xe2d, 0xe32, 0xe17, 0xe34, 0xe15, 0xe22, 0xe4c, 0x3b, 0xe27, 0xe31, 0xe19, 0xe08, 0xe31, 0xe19, 0xe17, 0xe23,
-0xe4c, 0x3b, 0xe27, 0xe31, 0xe19, 0xe2d, 0xe31, 0xe07, 0xe04, 0xe32, 0xe23, 0x3b, 0xe27, 0xe31, 0xe19, 0xe1e, 0xe38, 0xe18, 0x3b, 0xe27,
-0xe31, 0xe19, 0xe1e, 0xe24, 0xe2b, 0xe31, 0xe2a, 0xe1a, 0xe14, 0xe35, 0x3b, 0xe27, 0xe31, 0xe19, 0xe28, 0xe38, 0xe01, 0xe23, 0xe4c, 0x3b,
-0xe27, 0xe31, 0xe19, 0xe40, 0xe2a, 0xe32, 0xe23, 0xe4c, 0x3b, 0xf49, 0xf72, 0xf0b, 0xf58, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b,
-0x3b, 0xf58, 0xf72, 0xf42, 0xf0b, 0xf51, 0xf58, 0xf62, 0xf0b, 0x3b, 0xf67, 0xfb3, 0xf42, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf55, 0xf74, 0xf62,
-0xf0b, 0xf56, 0xf74, 0xf0b, 0x3b, 0xf66, 0xf44, 0xf66, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xf7a, 0xf53, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf42, 0xf5f,
-0xf60, 0xf0b, 0xf49, 0xf72, 0xf0b, 0xf58, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0x3b, 0xf42, 0xf5f,
-0xf60, 0xf0b, 0xf58, 0xf72, 0xf42, 0xf0b, 0xf51, 0xf58, 0xf62, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf67, 0xfb3, 0xf42, 0xf0b, 0xf54,
-0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf55, 0xf74, 0xf62, 0xf0b, 0xf56, 0xf74, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf66, 0xf44,
-0xf66, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf66, 0xfa4, 0xf7a, 0xf53, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf49, 0xf72, 0x3b, 0xf5f, 0xfb3,
-0x3b, 0xf58, 0xf72, 0x3b, 0xf67, 0xfb3, 0x3b, 0xf55, 0xf74, 0x3b, 0xf66, 0x3b, 0xf66, 0xfa4, 0xf7a, 0x3b, 0xf49, 0xf72, 0x3b, 0xf5f,
-0xfb3, 0x3b, 0xf58, 0xf72, 0x3b, 0xf67, 0xfb3, 0xf42, 0x3b, 0xf55, 0xf74, 0x3b, 0xf66, 0x3b, 0xf66, 0xfa4, 0xf7a, 0x3b, 0x1230, 0x1295,
-0x1260, 0x1275, 0x3b, 0x1230, 0x1291, 0x12ed, 0x3b, 0x1220, 0x1209, 0x1235, 0x3b, 0x1228, 0x1261, 0x12d5, 0x3b, 0x1283, 0x1219, 0x1235, 0x3b, 0x12d3,
-0x122d, 0x1262, 0x3b, 0x1240, 0x12f3, 0x121d, 0x3b, 0x1230, 0x3b, 0x1230, 0x3b, 0x1220, 0x3b, 0x1228, 0x3b, 0x1283, 0x3b, 0x12d3, 0x3b, 0x1240,
-0x3b, 0x1230, 0x1295, 0x1260, 0x1275, 0x3b, 0x1230, 0x1291, 0x12ed, 0x3b, 0x1230, 0x1209, 0x1235, 0x3b, 0x1228, 0x1261, 0x12d5, 0x3b, 0x1213, 0x1219,
-0x1235, 0x3b, 0x12d3, 0x122d, 0x1262, 0x3b, 0x1240, 0x12f3, 0x121d, 0x3b, 0x53, 0x101, 0x70, 0x3b, 0x4d, 0x14d, 0x6e, 0x3b, 0x54, 0x16b,
-0x73, 0x3b, 0x50, 0x75, 0x6c, 0x3b, 0x54, 0x75, 0x2bb, 0x61, 0x3b, 0x46, 0x61, 0x6c, 0x3b, 0x54, 0x6f, 0x6b, 0x3b, 0x53,
-0x101, 0x70, 0x61, 0x74, 0x65, 0x3b, 0x4d, 0x14d, 0x6e, 0x69, 0x74, 0x65, 0x3b, 0x54, 0x16b, 0x73, 0x69, 0x74, 0x65, 0x3b,
-0x50, 0x75, 0x6c, 0x65, 0x6c, 0x75, 0x6c, 0x75, 0x3b, 0x54, 0x75, 0x2bb, 0x61, 0x70, 0x75, 0x6c, 0x65, 0x6c, 0x75, 0x6c,
-0x75, 0x3b, 0x46, 0x61, 0x6c, 0x61, 0x69, 0x74, 0x65, 0x3b, 0x54, 0x6f, 0x6b, 0x6f, 0x6e, 0x61, 0x6b, 0x69, 0x3b, 0x53,
-0x3b, 0x4d, 0x3b, 0x54, 0x3b, 0x50, 0x3b, 0x54, 0x3b, 0x46, 0x3b, 0x54, 0x3b, 0x53, 0x6f, 0x6e, 0x3b, 0x4d, 0x75, 0x73,
-0x3b, 0x42, 0x69, 0x72, 0x3b, 0x48, 0x61, 0x72, 0x3b, 0x4e, 0x65, 0x3b, 0x54, 0x6c, 0x68, 0x3b, 0x4d, 0x75, 0x67, 0x3b,
-0x53, 0x6f, 0x6e, 0x74, 0x6f, 0x3b, 0x4d, 0x75, 0x73, 0x75, 0x6d, 0x62, 0x68, 0x75, 0x6e, 0x75, 0x6b, 0x75, 0x3b, 0x52,
-0x61, 0x76, 0x75, 0x6d, 0x62, 0x69, 0x72, 0x68, 0x69, 0x3b, 0x52, 0x61, 0x76, 0x75, 0x6e, 0x68, 0x61, 0x72, 0x68, 0x75,
-0x3b, 0x52, 0x61, 0x76, 0x75, 0x6d, 0x75, 0x6e, 0x65, 0x3b, 0x52, 0x61, 0x76, 0x75, 0x6e, 0x74, 0x6c, 0x68, 0x61, 0x6e,
-0x75, 0x3b, 0x4d, 0x75, 0x67, 0x71, 0x69, 0x76, 0x65, 0x6c, 0x61, 0x3b, 0x50, 0x61, 0x7a, 0x3b, 0x50, 0x7a, 0x74, 0x3b,
-0x53, 0x61, 0x6c, 0x3b, 0xc7, 0x61, 0x72, 0x3b, 0x50, 0x65, 0x72, 0x3b, 0x43, 0x75, 0x6d, 0x3b, 0x43, 0x6d, 0x74, 0x3b,
-0x50, 0x61, 0x7a, 0x61, 0x72, 0x3b, 0x50, 0x61, 0x7a, 0x61, 0x72, 0x74, 0x65, 0x73, 0x69, 0x3b, 0x53, 0x61, 0x6c, 0x131,
-0x3b, 0xc7, 0x61, 0x72, 0x15f, 0x61, 0x6d, 0x62, 0x61, 0x3b, 0x50, 0x65, 0x72, 0x15f, 0x65, 0x6d, 0x62, 0x65, 0x3b, 0x43,
-0x75, 0x6d, 0x61, 0x3b, 0x43, 0x75, 0x6d, 0x61, 0x72, 0x74, 0x65, 0x73, 0x69, 0x3b, 0x50, 0x3b, 0x50, 0x3b, 0x53, 0x3b,
-0xc7, 0x3b, 0x50, 0x3b, 0x43, 0x3b, 0x43, 0x3b, 0x41d, 0x434, 0x3b, 0x41f, 0x43d, 0x3b, 0x412, 0x442, 0x3b, 0x421, 0x440, 0x3b,
-0x427, 0x442, 0x3b, 0x41f, 0x442, 0x3b, 0x421, 0x431, 0x3b, 0x41d, 0x435, 0x434, 0x456, 0x43b, 0x44f, 0x3b, 0x41f, 0x43e, 0x43d, 0x435,
-0x434, 0x456, 0x43b, 0x43e, 0x43a, 0x3b, 0x412, 0x456, 0x432, 0x442, 0x43e, 0x440, 0x43e, 0x43a, 0x3b, 0x421, 0x435, 0x440, 0x435, 0x434,
-0x430, 0x3b, 0x427, 0x435, 0x442, 0x432, 0x435, 0x440, 0x3b, 0x41f, 0x2bc, 0x44f, 0x442, 0x43d, 0x438, 0x446, 0x44f, 0x3b, 0x421, 0x443,
-0x431, 0x43e, 0x442, 0x430, 0x3b, 0x41d, 0x3b, 0x41f, 0x3b, 0x412, 0x3b, 0x421, 0x3b, 0x427, 0x3b, 0x41f, 0x3b, 0x421, 0x3b, 0x627,
-0x62a, 0x648, 0x627, 0x631, 0x3b, 0x67e, 0x6cc, 0x631, 0x3b, 0x645, 0x646, 0x6af, 0x644, 0x3b, 0x628, 0x62f, 0x647, 0x3b, 0x62c, 0x645,
-0x639, 0x631, 0x627, 0x62a, 0x3b, 0x62c, 0x645, 0x639, 0x6c1, 0x3b, 0x6c1, 0x641, 0x62a, 0x6c1, 0x3b, 0x42f, 0x43a, 0x448, 0x3b, 0x414,
-0x443, 0x448, 0x3b, 0x421, 0x435, 0x448, 0x3b, 0x427, 0x43e, 0x440, 0x3b, 0x41f, 0x430, 0x439, 0x3b, 0x416, 0x443, 0x43c, 0x3b, 0x428,
-0x430, 0x43d, 0x3b, 0x44f, 0x43a, 0x448, 0x430, 0x43d, 0x431, 0x430, 0x3b, 0x434, 0x443, 0x448, 0x430, 0x43d, 0x431, 0x430, 0x3b, 0x441,
-0x435, 0x448, 0x430, 0x43d, 0x431, 0x430, 0x3b, 0x447, 0x43e, 0x440, 0x448, 0x430, 0x43d, 0x431, 0x430, 0x3b, 0x43f, 0x430, 0x439, 0x448,
-0x430, 0x43d, 0x431, 0x430, 0x3b, 0x436, 0x443, 0x43c, 0x430, 0x3b, 0x448, 0x430, 0x43d, 0x431, 0x430, 0x3b, 0x42f, 0x3b, 0x414, 0x3b,
-0x421, 0x3b, 0x427, 0x3b, 0x41f, 0x3b, 0x416, 0x3b, 0x428, 0x3b, 0x6cc, 0x2e, 0x3b, 0x62f, 0x2e, 0x3b, 0x633, 0x2e, 0x3b, 0x686,
-0x2e, 0x3b, 0x67e, 0x2e, 0x3b, 0x62c, 0x2e, 0x3b, 0x634, 0x2e, 0x3b, 0x59, 0x61, 0x6b, 0x73, 0x68, 0x3b, 0x44, 0x75, 0x73,
-0x68, 0x3b, 0x53, 0x65, 0x73, 0x68, 0x3b, 0x43, 0x68, 0x6f, 0x72, 0x3b, 0x50, 0x61, 0x79, 0x3b, 0x43, 0x75, 0x6d, 0x3b,
-0x53, 0x68, 0x61, 0x6e, 0x3b, 0x79, 0x61, 0x6b, 0x73, 0x68, 0x61, 0x6e, 0x62, 0x61, 0x3b, 0x64, 0x75, 0x73, 0x68, 0x61,
-0x6e, 0x62, 0x61, 0x3b, 0x73, 0x65, 0x73, 0x68, 0x61, 0x6e, 0x62, 0x61, 0x3b, 0x63, 0x68, 0x6f, 0x72, 0x73, 0x68, 0x61,
-0x6e, 0x62, 0x61, 0x3b, 0x70, 0x61, 0x79, 0x73, 0x68, 0x61, 0x6e, 0x62, 0x61, 0x3b, 0x63, 0x75, 0x6d, 0x61, 0x3b, 0x73,
-0x68, 0x61, 0x6e, 0x62, 0x61, 0x3b, 0x59, 0x3b, 0x44, 0x3b, 0x53, 0x3b, 0x43, 0x3b, 0x50, 0x3b, 0x43, 0x3b, 0x53, 0x3b,
-0x43, 0x4e, 0x3b, 0x54, 0x68, 0x20, 0x32, 0x3b, 0x54, 0x68, 0x20, 0x33, 0x3b, 0x54, 0x68, 0x20, 0x34, 0x3b, 0x54, 0x68,
-0x20, 0x35, 0x3b, 0x54, 0x68, 0x20, 0x36, 0x3b, 0x54, 0x68, 0x20, 0x37, 0x3b, 0x43, 0x68, 0x1ee7, 0x20, 0x6e, 0x68, 0x1ead,
-0x74, 0x3b, 0x54, 0x68, 0x1ee9, 0x20, 0x68, 0x61, 0x69, 0x3b, 0x54, 0x68, 0x1ee9, 0x20, 0x62, 0x61, 0x3b, 0x54, 0x68, 0x1ee9,
-0x20, 0x74, 0x1b0, 0x3b, 0x54, 0x68, 0x1ee9, 0x20, 0x6e, 0x103, 0x6d, 0x3b, 0x54, 0x68, 0x1ee9, 0x20, 0x73, 0xe1, 0x75, 0x3b,
-0x54, 0x68, 0x1ee9, 0x20, 0x62, 0x1ea3, 0x79, 0x3b, 0x43, 0x4e, 0x3b, 0x54, 0x32, 0x3b, 0x54, 0x33, 0x3b, 0x54, 0x34, 0x3b,
-0x54, 0x35, 0x3b, 0x54, 0x36, 0x3b, 0x54, 0x37, 0x3b, 0x53, 0x75, 0x6c, 0x3b, 0x4c, 0x6c, 0x75, 0x6e, 0x3b, 0x4d, 0x61,
-0x77, 0x3b, 0x4d, 0x65, 0x72, 0x3b, 0x49, 0x61, 0x75, 0x3b, 0x47, 0x77, 0x65, 0x3b, 0x53, 0x61, 0x64, 0x3b, 0x44, 0x79,
-0x64, 0x64, 0x20, 0x53, 0x75, 0x6c, 0x3b, 0x44, 0x79, 0x64, 0x64, 0x20, 0x4c, 0x6c, 0x75, 0x6e, 0x3b, 0x44, 0x79, 0x64,
-0x64, 0x20, 0x4d, 0x61, 0x77, 0x72, 0x74, 0x68, 0x3b, 0x44, 0x79, 0x64, 0x64, 0x20, 0x4d, 0x65, 0x72, 0x63, 0x68, 0x65,
-0x72, 0x3b, 0x44, 0x79, 0x64, 0x64, 0x20, 0x49, 0x61, 0x75, 0x3b, 0x44, 0x79, 0x64, 0x64, 0x20, 0x47, 0x77, 0x65, 0x6e,
-0x65, 0x72, 0x3b, 0x44, 0x79, 0x64, 0x64, 0x20, 0x53, 0x61, 0x64, 0x77, 0x72, 0x6e, 0x3b, 0x53, 0x3b, 0x4c, 0x3b, 0x4d,
-0x3b, 0x4d, 0x3b, 0x49, 0x3b, 0x47, 0x3b, 0x53, 0x3b, 0x53, 0x75, 0x6c, 0x3b, 0x4c, 0x6c, 0x75, 0x6e, 0x3b, 0x4d, 0x61,
-0x77, 0x3b, 0x4d, 0x65, 0x72, 0x3b, 0x49, 0x61, 0x75, 0x3b, 0x47, 0x77, 0x65, 0x6e, 0x3b, 0x53, 0x61, 0x64, 0x3b, 0x43,
-0x61, 0x77, 0x3b, 0x4d, 0x76, 0x75, 0x3b, 0x42, 0x69, 0x6e, 0x3b, 0x54, 0x68, 0x61, 0x3b, 0x53, 0x69, 0x6e, 0x3b, 0x48,
-0x6c, 0x61, 0x3b, 0x4d, 0x67, 0x71, 0x3b, 0x43, 0x61, 0x77, 0x65, 0x3b, 0x4d, 0x76, 0x75, 0x6c, 0x6f, 0x3b, 0x4c, 0x77,
-0x65, 0x73, 0x69, 0x62, 0x69, 0x6e, 0x69, 0x3b, 0x4c, 0x77, 0x65, 0x73, 0x69, 0x74, 0x68, 0x61, 0x74, 0x68, 0x75, 0x3b,
-0x4c, 0x77, 0x65, 0x73, 0x69, 0x6e, 0x65, 0x3b, 0x4c, 0x77, 0x65, 0x73, 0x69, 0x68, 0x6c, 0x61, 0x6e, 0x75, 0x3b, 0x4d,
-0x67, 0x71, 0x69, 0x62, 0x65, 0x6c, 0x6f, 0x3b, 0xc0, 0xec, 0x6b, 0xfa, 0x3b, 0x41, 0x6a, 0xe9, 0x3b, 0xcc, 0x73, 0x1eb9,
-0x301, 0x67, 0x75, 0x6e, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x72, 0xfa, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x62, 0x1ecd, 0x3b, 0x1eb8,
-0x74, 0xec, 0x3b, 0xc0, 0x62, 0xe1, 0x6d, 0x1eb9, 0x301, 0x74, 0x61, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x20, 0xc0, 0xec, 0x6b,
-0xfa, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x20, 0x41, 0x6a, 0xe9, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x20, 0xcc, 0x73, 0x1eb9, 0x301,
-0x67, 0x75, 0x6e, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x72, 0xfa, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x62, 0x1ecd, 0x3b, 0x1ecc, 0x6a,
-0x1ecd, 0x301, 0x20, 0x1eb8, 0x74, 0xec, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x20, 0xc0, 0x62, 0xe1, 0x6d, 0x1eb9, 0x301, 0x74, 0x61,
-0x3b, 0x53, 0x6f, 0x6e, 0x3b, 0x4d, 0x73, 0x6f, 0x3b, 0x42, 0x69, 0x6c, 0x3b, 0x54, 0x68, 0x61, 0x3b, 0x53, 0x69, 0x6e,
-0x3b, 0x48, 0x6c, 0x61, 0x3b, 0x4d, 0x67, 0x71, 0x3b, 0x53, 0x6f, 0x6e, 0x74, 0x6f, 0x3b, 0x4d, 0x73, 0x6f, 0x6d, 0x62,
-0x75, 0x6c, 0x75, 0x6b, 0x6f, 0x3b, 0x4c, 0x77, 0x65, 0x73, 0x69, 0x62, 0x69, 0x6c, 0x69, 0x3b, 0x4c, 0x77, 0x65, 0x73,
-0x69, 0x74, 0x68, 0x61, 0x74, 0x68, 0x75, 0x3b, 0x75, 0x4c, 0x77, 0x65, 0x73, 0x69, 0x6e, 0x65, 0x3b, 0x4c, 0x77, 0x65,
-0x73, 0x69, 0x68, 0x6c, 0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x67, 0x71, 0x69, 0x62, 0x65, 0x6c, 0x6f, 0x3b, 0x53, 0x3b, 0x4d,
-0x3b, 0x42, 0x3b, 0x54, 0x3b, 0x53, 0x3b, 0x48, 0x3b, 0x4d, 0x3b, 0x73, 0xf8, 0x6e, 0x3b, 0x6d, 0xe5, 0x6e, 0x3b, 0x74,
-0x79, 0x73, 0x3b, 0x6f, 0x6e, 0x73, 0x3b, 0x74, 0x6f, 0x72, 0x3b, 0x66, 0x72, 0x65, 0x3b, 0x6c, 0x61, 0x75, 0x3b, 0x73,
-0xf8, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x6d, 0xe5, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x74, 0x79, 0x73, 0x64, 0x61, 0x67, 0x3b,
-0x6f, 0x6e, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x74, 0x6f, 0x72, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x66, 0x72, 0x65, 0x64, 0x61,
-0x67, 0x3b, 0x6c, 0x61, 0x75, 0x72, 0x64, 0x61, 0x67, 0x3b, 0x73, 0xf8, 0x2e, 0x3b, 0x6d, 0xe5, 0x2e, 0x3b, 0x74, 0x79,
-0x2e, 0x3b, 0x6f, 0x6e, 0x2e, 0x3b, 0x74, 0x6f, 0x2e, 0x3b, 0x66, 0x72, 0x2e, 0x3b, 0x6c, 0x61, 0x2e, 0x3b, 0x4a, 0x65,
-0x64, 0x3b, 0x4a, 0x65, 0x6c, 0x3b, 0x4a, 0x65, 0x6d, 0x3b, 0x4a, 0x65, 0x72, 0x63, 0x3b, 0x4a, 0x65, 0x72, 0x64, 0x3b,
-0x4a, 0x65, 0x68, 0x3b, 0x4a, 0x65, 0x73, 0x3b, 0x4a, 0x65, 0x64, 0x6f, 0x6f, 0x6e, 0x65, 0x65, 0x3b, 0x4a, 0x65, 0x6c,
-0x68, 0x65, 0x69, 0x6e, 0x3b, 0x4a, 0x65, 0x6d, 0x61, 0x79, 0x72, 0x74, 0x3b, 0x4a, 0x65, 0x72, 0x63, 0x65, 0x61, 0x6e,
-0x3b, 0x4a, 0x65, 0x72, 0x64, 0x65, 0x69, 0x6e, 0x3b, 0x4a, 0x65, 0x68, 0x65, 0x69, 0x6e, 0x65, 0x79, 0x3b, 0x4a, 0x65,
-0x73, 0x61, 0x72, 0x6e, 0x3b, 0x53, 0x75, 0x6c, 0x3b, 0x4c, 0x75, 0x6e, 0x3b, 0x4d, 0x74, 0x68, 0x3b, 0x4d, 0x68, 0x72,
-0x3b, 0x59, 0x6f, 0x77, 0x3b, 0x47, 0x77, 0x65, 0x3b, 0x53, 0x61, 0x64, 0x3b, 0x44, 0x65, 0x20, 0x53, 0x75, 0x6c, 0x3b,
-0x44, 0x65, 0x20, 0x4c, 0x75, 0x6e, 0x3b, 0x44, 0x65, 0x20, 0x4d, 0x65, 0x72, 0x74, 0x68, 0x3b, 0x44, 0x65, 0x20, 0x4d,
-0x65, 0x72, 0x68, 0x65, 0x72, 0x3b, 0x44, 0x65, 0x20, 0x59, 0x6f, 0x77, 0x3b, 0x44, 0x65, 0x20, 0x47, 0x77, 0x65, 0x6e,
-0x65, 0x72, 0x3b, 0x44, 0x65, 0x20, 0x53, 0x61, 0x64, 0x6f, 0x72, 0x6e, 0x3b, 0x4b, 0x77, 0x65, 0x3b, 0x44, 0x77, 0x6f,
-0x3b, 0x42, 0x65, 0x6e, 0x3b, 0x57, 0x75, 0x6b, 0x3b, 0x59, 0x61, 0x77, 0x3b, 0x46, 0x69, 0x61, 0x3b, 0x4d, 0x65, 0x6d,
-0x3b, 0x4b, 0x77, 0x65, 0x73, 0x69, 0x64, 0x61, 0x3b, 0x44, 0x77, 0x6f, 0x77, 0x64, 0x61, 0x3b, 0x42, 0x65, 0x6e, 0x61,
-0x64, 0x61, 0x3b, 0x57, 0x75, 0x6b, 0x75, 0x64, 0x61, 0x3b, 0x59, 0x61, 0x77, 0x64, 0x61, 0x3b, 0x46, 0x69, 0x64, 0x61,
-0x3b, 0x4d, 0x65, 0x6d, 0x65, 0x6e, 0x65, 0x64, 0x61, 0x3b, 0x4b, 0x3b, 0x44, 0x3b, 0x42, 0x3b, 0x57, 0x3b, 0x59, 0x3b,
-0x46, 0x3b, 0x4d, 0x3b, 0x906, 0x926, 0x93f, 0x924, 0x94d, 0x92f, 0x935, 0x93e, 0x930, 0x3b, 0x938, 0x94b, 0x92e, 0x935, 0x93e, 0x930,
-0x3b, 0x92e, 0x902, 0x917, 0x933, 0x93e, 0x930, 0x3b, 0x92c, 0x941, 0x927, 0x935, 0x93e, 0x930, 0x3b, 0x917, 0x941, 0x930, 0x941, 0x935,
-0x93e, 0x930, 0x3b, 0x936, 0x941, 0x915, 0x94d, 0x930, 0x935, 0x93e, 0x930, 0x3b, 0x936, 0x928, 0x93f, 0x935, 0x93e, 0x930, 0x3b, 0x1ee4,
-0x6b, 0x61, 0x3b, 0x4d, 0x1ecd, 0x6e, 0x3b, 0x54, 0x69, 0x75, 0x3b, 0x57, 0x65, 0x6e, 0x3b, 0x54, 0x1ecd, 0x1ecd, 0x3b, 0x46,
-0x72, 0x61, 0x1ecb, 0x3b, 0x53, 0x61, 0x74, 0x3b, 0x4d, 0x62, 0x1ecd, 0x73, 0x1ecb, 0x20, 0x1ee4, 0x6b, 0x61, 0x3b, 0x4d, 0x1ecd,
-0x6e, 0x64, 0x65, 0x3b, 0x54, 0x69, 0x75, 0x7a, 0x64, 0x65, 0x65, 0x3b, 0x57, 0x65, 0x6e, 0x65, 0x7a, 0x64, 0x65, 0x65,
-0x3b, 0x54, 0x1ecd, 0x1ecd, 0x7a, 0x64, 0x65, 0x65, 0x3b, 0x46, 0x72, 0x61, 0x1ecb, 0x64, 0x65, 0x65, 0x3b, 0x53, 0x61, 0x74,
-0x1ecd, 0x64, 0x65, 0x65, 0x3b, 0x57, 0x6b, 0x79, 0x3b, 0x57, 0x6b, 0x77, 0x3b, 0x57, 0x6b, 0x6c, 0x3b, 0x57, 0x74, 0x169,
-0x3b, 0x57, 0x6b, 0x6e, 0x3b, 0x57, 0x74, 0x6e, 0x3b, 0x57, 0x74, 0x68, 0x3b, 0x57, 0x61, 0x20, 0x6b, 0x79, 0x75, 0x6d,
-0x77, 0x61, 0x3b, 0x57, 0x61, 0x20, 0x6b, 0x77, 0x61, 0x6d, 0x62, 0x129, 0x6c, 0x129, 0x6c, 0x79, 0x61, 0x3b, 0x57, 0x61,
-0x20, 0x6b, 0x65, 0x6c, 0x129, 0x3b, 0x57, 0x61, 0x20, 0x6b, 0x61, 0x74, 0x61, 0x74, 0x169, 0x3b, 0x57, 0x61, 0x20, 0x6b,
-0x61, 0x6e, 0x61, 0x3b, 0x57, 0x61, 0x20, 0x6b, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x57, 0x61, 0x20, 0x74, 0x68, 0x61,
-0x6e, 0x74, 0x68, 0x61, 0x74, 0x169, 0x3b, 0x59, 0x3b, 0x57, 0x3b, 0x45, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41,
-0x3b, 0x1230, 0x2f, 0x1245, 0x3b, 0x1230, 0x1291, 0x3b, 0x1230, 0x120a, 0x131d, 0x3b, 0x1208, 0x1313, 0x3b, 0x12a3, 0x121d, 0x12f5, 0x3b, 0x12a3,
-0x122d, 0x1265, 0x3b, 0x1230, 0x2f, 0x123d, 0x3b, 0x1230, 0x1295, 0x1260, 0x122d, 0x20, 0x1245, 0x12f3, 0x12c5, 0x3b, 0x1230, 0x1291, 0x3b, 0x1230,
-0x120a, 0x131d, 0x3b, 0x1208, 0x1313, 0x20, 0x12c8, 0x122a, 0x20, 0x1208, 0x1265, 0x12cb, 0x3b, 0x12a3, 0x121d, 0x12f5, 0x3b, 0x12a3, 0x122d, 0x1265,
-0x3b, 0x1230, 0x1295, 0x1260, 0x122d, 0x20, 0x123d, 0x1313, 0x12c5, 0x3b, 0x1230, 0x3b, 0x1230, 0x3b, 0x1230, 0x3b, 0x1208, 0x3b, 0x12a3, 0x3b,
-0x12a3, 0x3b, 0x1230, 0x3b, 0x1230, 0x2f, 0x12d3, 0x3b, 0x1230, 0x1296, 0x3b, 0x1273, 0x120b, 0x1238, 0x3b, 0x12a3, 0x1228, 0x122d, 0x3b, 0x12a8,
-0x121a, 0x123d, 0x3b, 0x1305, 0x121d, 0x12d3, 0x3b, 0x1230, 0x2f, 0x1295, 0x3b, 0x1230, 0x1295, 0x1260, 0x1275, 0x20, 0x12d3, 0x1263, 0x12ed, 0x3b,
-0x1230, 0x1296, 0x3b, 0x1273, 0x120b, 0x1238, 0x1296, 0x3b, 0x12a3, 0x1228, 0x122d, 0x1263, 0x12d3, 0x3b, 0x12a8, 0x121a, 0x123d, 0x3b, 0x1305, 0x121d,
-0x12d3, 0x1275, 0x3b, 0x1230, 0x1295, 0x1260, 0x1275, 0x20, 0x1295, 0x12a2, 0x123d, 0x3b, 0x1230, 0x3b, 0x1230, 0x3b, 0x1273, 0x3b, 0x12a3, 0x3b,
-0x12a8, 0x3b, 0x1305, 0x3b, 0x1230, 0x3b, 0x64, 0x6f, 0x6d, 0x3b, 0x6c, 0x75, 0x6e, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x6d, 0x69,
-0x65, 0x3b, 0x6a, 0x6f, 0x69, 0x3b, 0x76, 0x69, 0x6e, 0x3b, 0x73, 0x61, 0x62, 0x3b, 0x64, 0x6f, 0x6d, 0x65, 0x6e, 0x69,
-0x65, 0x3b, 0x6c, 0x75, 0x6e, 0x69, 0x73, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x61, 0x72, 0x73, 0x3b, 0x6d, 0x69, 0x65, 0x72,
-0x63, 0x75, 0x73, 0x3b, 0x6a, 0x6f, 0x69, 0x62, 0x65, 0x3b, 0x76, 0x69, 0x6e, 0x61, 0x72, 0x73, 0x3b, 0x73, 0x61, 0x62,
-0x69, 0x64, 0x65, 0x3b, 0x53, 0x77, 0x6f, 0x3b, 0x4d, 0x75, 0x73, 0x3b, 0x56, 0x68, 0x69, 0x3b, 0x52, 0x61, 0x72, 0x3b,
-0x1e4a, 0x61, 0x3b, 0x1e70, 0x61, 0x6e, 0x3b, 0x4d, 0x75, 0x67, 0x3b, 0x53, 0x77, 0x6f, 0x6e, 0x64, 0x61, 0x68, 0x61, 0x3b,
-0x4d, 0x75, 0x73, 0x75, 0x6d, 0x62, 0x75, 0x6c, 0x75, 0x77, 0x6f, 0x3b, 0x1e3c, 0x61, 0x76, 0x68, 0x75, 0x76, 0x68, 0x69,
-0x6c, 0x69, 0x3b, 0x1e3c, 0x61, 0x76, 0x68, 0x75, 0x72, 0x61, 0x72, 0x75, 0x3b, 0x1e3c, 0x61, 0x76, 0x68, 0x75, 0x1e4b, 0x61,
-0x3b, 0x1e3c, 0x61, 0x76, 0x68, 0x75, 0x1e71, 0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x75, 0x67, 0x69, 0x76, 0x68, 0x65, 0x6c, 0x61,
-0x3b, 0x6b, 0x254, 0x73, 0x3b, 0x64, 0x7a, 0x6f, 0x3b, 0x62, 0x6c, 0x61, 0x3b, 0x6b, 0x75, 0x256, 0x3b, 0x79, 0x61, 0x77,
-0x3b, 0x66, 0x69, 0x256, 0x3b, 0x6d, 0x65, 0x6d, 0x3b, 0x6b, 0x254, 0x73, 0x69, 0x256, 0x61, 0x3b, 0x64, 0x7a, 0x6f, 0x256,
-0x61, 0x3b, 0x62, 0x6c, 0x61, 0x256, 0x61, 0x3b, 0x6b, 0x75, 0x256, 0x61, 0x3b, 0x79, 0x61, 0x77, 0x6f, 0x256, 0x61, 0x3b,
-0x66, 0x69, 0x256, 0x61, 0x3b, 0x6d, 0x65, 0x6d, 0x6c, 0x65, 0x256, 0x61, 0x3b, 0x6b, 0x3b, 0x64, 0x3b, 0x62, 0x3b, 0x6b,
-0x3b, 0x79, 0x3b, 0x66, 0x3b, 0x6d, 0x3b, 0x12c8, 0x130b, 0x3b, 0x1233, 0x12ed, 0x1296, 0x3b, 0x121b, 0x1246, 0x1233, 0x129b, 0x3b, 0x12a0,
-0x1229, 0x12cb, 0x3b, 0x1203, 0x1219, 0x1233, 0x3b, 0x12a0, 0x122d, 0x1263, 0x3b, 0x1244, 0x122b, 0x3b, 0x12c8, 0x3b, 0x1233, 0x3b, 0x121b, 0x3b,
-0x12a0, 0x3b, 0x1203, 0x3b, 0x12a0, 0x3b, 0x1244, 0x3b, 0x4c, 0x50, 0x3b, 0x50, 0x31, 0x3b, 0x50, 0x32, 0x3b, 0x50, 0x33, 0x3b,
-0x50, 0x34, 0x3b, 0x50, 0x35, 0x3b, 0x50, 0x36, 0x3b, 0x4c, 0x101, 0x70, 0x75, 0x6c, 0x65, 0x3b, 0x50, 0x6f, 0x2bb, 0x61,
-0x6b, 0x61, 0x68, 0x69, 0x3b, 0x50, 0x6f, 0x2bb, 0x61, 0x6c, 0x75, 0x61, 0x3b, 0x50, 0x6f, 0x2bb, 0x61, 0x6b, 0x6f, 0x6c,
-0x75, 0x3b, 0x50, 0x6f, 0x2bb, 0x61, 0x68, 0x101, 0x3b, 0x50, 0x6f, 0x2bb, 0x61, 0x6c, 0x69, 0x6d, 0x61, 0x3b, 0x50, 0x6f,
-0x2bb, 0x61, 0x6f, 0x6e, 0x6f, 0x3b, 0x4c, 0x69, 0x6e, 0x3b, 0x4c, 0x75, 0x6e, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x4d, 0x69,
-0x79, 0x3b, 0x48, 0x75, 0x77, 0x3b, 0x42, 0x69, 0x79, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x4c, 0x69, 0x6e, 0x67, 0x67, 0x6f,
-0x3b, 0x4c, 0x75, 0x6e, 0x65, 0x73, 0x3b, 0x4d, 0x61, 0x72, 0x74, 0x65, 0x73, 0x3b, 0x4d, 0x69, 0x79, 0x65, 0x72, 0x6b,
-0x75, 0x6c, 0x65, 0x73, 0x3b, 0x48, 0x75, 0x77, 0x65, 0x62, 0x65, 0x73, 0x3b, 0x42, 0x69, 0x79, 0x65, 0x72, 0x6e, 0x65,
-0x73, 0x3b, 0x53, 0x61, 0x62, 0x61, 0x64, 0x6f, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x48, 0x3b, 0x42,
-0x3b, 0x53, 0x3b, 0x4c, 0x69, 0x6e, 0x3b, 0x4c, 0x75, 0x6e, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x4d, 0x79, 0x65, 0x3b, 0x48,
-0x75, 0x77, 0x3b, 0x42, 0x79, 0x65, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x53, 0x75, 0x2e, 0x3b, 0x4d, 0xe4, 0x2e, 0x3b, 0x5a,
-0x69, 0x2e, 0x3b, 0x4d, 0x69, 0x2e, 0x3b, 0x44, 0x75, 0x2e, 0x3b, 0x46, 0x72, 0x2e, 0x3b, 0x53, 0x61, 0x2e, 0x3b, 0x53,
-0x75, 0x6e, 0x6e, 0x74, 0x69, 0x67, 0x3b, 0x4d, 0xe4, 0xe4, 0x6e, 0x74, 0x69, 0x67, 0x3b, 0x5a, 0x69, 0x69, 0x73, 0x63,
-0x68, 0x74, 0x69, 0x67, 0x3b, 0x4d, 0x69, 0x74, 0x74, 0x77, 0x75, 0x63, 0x68, 0x3b, 0x44, 0x75, 0x6e, 0x73, 0x63, 0x68,
-0x74, 0x69, 0x67, 0x3b, 0x46, 0x72, 0x69, 0x69, 0x74, 0x69, 0x67, 0x3b, 0x53, 0x61, 0x6d, 0x73, 0x63, 0x68, 0x74, 0x69,
-0x67, 0x3b, 0xa46d, 0xa18f, 0x3b, 0xa18f, 0xa2cd, 0x3b, 0xa18f, 0xa44d, 0x3b, 0xa18f, 0xa315, 0x3b, 0xa18f, 0xa1d6, 0x3b, 0xa18f, 0xa26c, 0x3b,
-0xa18f, 0xa0d8, 0x3b, 0xa46d, 0xa18f, 0xa44d, 0x3b, 0xa18f, 0xa282, 0xa2cd, 0x3b, 0xa18f, 0xa282, 0xa44d, 0x3b, 0xa18f, 0xa282, 0xa315, 0x3b, 0xa18f,
-0xa282, 0xa1d6, 0x3b, 0xa18f, 0xa282, 0xa26c, 0x3b, 0xa18f, 0xa282, 0xa0d8, 0x3b, 0xa18f, 0x3b, 0xa2cd, 0x3b, 0xa44d, 0x3b, 0xa315, 0x3b, 0xa1d6,
-0x3b, 0xa26c, 0x3b, 0xa0d8, 0x3b, 0x53, 0x6f, 0x6e, 0x3b, 0x4d, 0x76, 0x75, 0x3b, 0x42, 0x69, 0x6c, 0x3b, 0x54, 0x68, 0x61,
-0x3b, 0x4e, 0x65, 0x3b, 0x48, 0x6c, 0x61, 0x3b, 0x47, 0x71, 0x69, 0x3b, 0x75, 0x53, 0x6f, 0x6e, 0x74, 0x6f, 0x3b, 0x75,
-0x4d, 0x76, 0x75, 0x6c, 0x6f, 0x3b, 0x75, 0x4c, 0x65, 0x73, 0x69, 0x62, 0x69, 0x6c, 0x69, 0x3b, 0x4c, 0x65, 0x73, 0x69,
-0x74, 0x68, 0x61, 0x74, 0x68, 0x75, 0x3b, 0x75, 0x4c, 0x65, 0x73, 0x69, 0x6e, 0x65, 0x3b, 0x6e, 0x67, 0x6f, 0x4c, 0x65,
-0x73, 0x69, 0x68, 0x6c, 0x61, 0x6e, 0x75, 0x3b, 0x75, 0x6d, 0x47, 0x71, 0x69, 0x62, 0x65, 0x6c, 0x6f, 0x3b, 0x53, 0x6f,
-0x6e, 0x3b, 0x4d, 0x6f, 0x73, 0x3b, 0x42, 0x65, 0x64, 0x3b, 0x52, 0x61, 0x72, 0x3b, 0x4e, 0x65, 0x3b, 0x48, 0x6c, 0x61,
-0x3b, 0x4d, 0x6f, 0x6b, 0x3b, 0x53, 0x6f, 0x6e, 0x74, 0x61, 0x67, 0x61, 0x3b, 0x4d, 0x6f, 0x73, 0x75, 0x70, 0x61, 0x6c,
+0x936, 0x941, 0x915, 0x94d, 0x930, 0x935, 0x93e, 0x930, 0x3b, 0x936, 0x928, 0x93f, 0x935, 0x93e, 0x930, 0x3b, 0x41d, 0x44f, 0x3b, 0x414,
+0x430, 0x3b, 0x41c, 0x44f, 0x3b, 0x41b, 0x445, 0x3b, 0x41f, 0x4af, 0x3b, 0x411, 0x430, 0x3b, 0x411, 0x44f, 0x3b, 0x43d, 0x44f, 0x43c,
+0x3b, 0x434, 0x430, 0x432, 0x430, 0x430, 0x3b, 0x43c, 0x44f, 0x433, 0x43c, 0x430, 0x440, 0x3b, 0x43b, 0x445, 0x430, 0x433, 0x432, 0x430,
+0x3b, 0x43f, 0x4af, 0x440, 0x44d, 0x432, 0x3b, 0x431, 0x430, 0x430, 0x441, 0x430, 0x43d, 0x3b, 0x431, 0x44f, 0x43c, 0x431, 0x430, 0x3b,
+0x906, 0x907, 0x924, 0x3b, 0x938, 0x94b, 0x92e, 0x3b, 0x92e, 0x919, 0x94d, 0x917, 0x932, 0x3b, 0x92c, 0x941, 0x927, 0x3b, 0x92c, 0x93f,
+0x939, 0x940, 0x3b, 0x936, 0x941, 0x915, 0x94d, 0x930, 0x3b, 0x936, 0x928, 0x93f, 0x3b, 0x906, 0x907, 0x924, 0x92c, 0x93e, 0x930, 0x3b,
+0x938, 0x94b, 0x92e, 0x92c, 0x93e, 0x930, 0x3b, 0x92e, 0x919, 0x94d, 0x917, 0x932, 0x92c, 0x93e, 0x930, 0x3b, 0x92c, 0x941, 0x927, 0x92c,
+0x93e, 0x930, 0x3b, 0x92c, 0x93f, 0x939, 0x940, 0x92c, 0x93e, 0x930, 0x3b, 0x936, 0x941, 0x915, 0x94d, 0x930, 0x92c, 0x93e, 0x930, 0x3b,
+0x936, 0x928, 0x93f, 0x92c, 0x93e, 0x930, 0x3b, 0x967, 0x3b, 0x968, 0x3b, 0x969, 0x3b, 0x96a, 0x3b, 0x96b, 0x3b, 0x96c, 0x3b, 0x96d,
+0x3b, 0x906, 0x907, 0x924, 0x935, 0x93e, 0x930, 0x3b, 0x938, 0x94b, 0x92e, 0x935, 0x93e, 0x930, 0x3b, 0x92e, 0x919, 0x94d, 0x917, 0x932,
+0x935, 0x93e, 0x930, 0x3b, 0x92c, 0x941, 0x927, 0x935, 0x93e, 0x930, 0x3b, 0x92c, 0x93f, 0x939, 0x940, 0x935, 0x93e, 0x930, 0x3b, 0x936,
+0x941, 0x915, 0x94d, 0x930, 0x935, 0x93e, 0x930, 0x3b, 0x936, 0x928, 0x93f, 0x935, 0x93e, 0x930, 0x3b, 0x73, 0xf8, 0x2e, 0x3b, 0x6d,
+0x61, 0x2e, 0x3b, 0x74, 0x69, 0x2e, 0x3b, 0x6f, 0x6e, 0x2e, 0x3b, 0x74, 0x6f, 0x2e, 0x3b, 0x66, 0x72, 0x2e, 0x3b, 0x6c,
+0xf8, 0x2e, 0x3b, 0xb30, 0xb2c, 0xb3f, 0x3b, 0xb38, 0xb4b, 0xb2e, 0x3b, 0xb2e, 0xb19, 0xb4d, 0xb17, 0xb33, 0x3b, 0xb2c, 0xb41, 0xb27,
+0x3b, 0xb17, 0xb41, 0xb30, 0xb41, 0x3b, 0xb36, 0xb41, 0xb15, 0xb4d, 0xb30, 0x3b, 0xb36, 0xb28, 0xb3f, 0x3b, 0xb30, 0xb2c, 0xb3f, 0xb2c,
+0xb3e, 0xb30, 0x3b, 0xb38, 0xb4b, 0xb2e, 0xb2c, 0xb3e, 0xb30, 0x3b, 0xb2e, 0xb19, 0xb4d, 0xb17, 0xb33, 0xb2c, 0xb3e, 0xb30, 0x3b, 0xb2c,
+0xb41, 0xb27, 0xb2c, 0xb3e, 0xb30, 0x3b, 0xb17, 0xb41, 0xb30, 0xb41, 0xb2c, 0xb3e, 0xb30, 0x3b, 0xb36, 0xb41, 0xb15, 0xb4d, 0xb30, 0xb2c,
+0xb3e, 0xb30, 0x3b, 0xb36, 0xb28, 0xb3f, 0xb2c, 0xb3e, 0xb30, 0x3b, 0xb30, 0x3b, 0xb38, 0xb4b, 0x3b, 0xb2e, 0x3b, 0xb2c, 0xb41, 0x3b,
+0xb17, 0xb41, 0x3b, 0xb36, 0xb41, 0x3b, 0xb36, 0x3b, 0x6cc, 0x6a9, 0x634, 0x646, 0x628, 0x647, 0x3b, 0x62f, 0x648, 0x634, 0x646, 0x628,
+0x647, 0x3b, 0x633, 0x647, 0x200c, 0x634, 0x646, 0x628, 0x647, 0x3b, 0x686, 0x647, 0x627, 0x631, 0x634, 0x646, 0x628, 0x647, 0x3b, 0x67e,
+0x646, 0x62c, 0x634, 0x646, 0x628, 0x647, 0x3b, 0x62c, 0x645, 0x639, 0x647, 0x3b, 0x634, 0x646, 0x628, 0x647, 0x3b, 0x6cc, 0x3b, 0x62f,
+0x3b, 0x633, 0x3b, 0x686, 0x3b, 0x67e, 0x3b, 0x62c, 0x3b, 0x634, 0x3b, 0x6e, 0x69, 0x65, 0x64, 0x7a, 0x2e, 0x3b, 0x70, 0x6f,
+0x6e, 0x2e, 0x3b, 0x77, 0x74, 0x2e, 0x3b, 0x15b, 0x72, 0x2e, 0x3b, 0x63, 0x7a, 0x77, 0x2e, 0x3b, 0x70, 0x74, 0x2e, 0x3b,
+0x73, 0x6f, 0x62, 0x2e, 0x3b, 0x6e, 0x69, 0x65, 0x64, 0x7a, 0x69, 0x65, 0x6c, 0x61, 0x3b, 0x70, 0x6f, 0x6e, 0x69, 0x65,
+0x64, 0x7a, 0x69, 0x61, 0x142, 0x65, 0x6b, 0x3b, 0x77, 0x74, 0x6f, 0x72, 0x65, 0x6b, 0x3b, 0x15b, 0x72, 0x6f, 0x64, 0x61,
+0x3b, 0x63, 0x7a, 0x77, 0x61, 0x72, 0x74, 0x65, 0x6b, 0x3b, 0x70, 0x69, 0x105, 0x74, 0x65, 0x6b, 0x3b, 0x73, 0x6f, 0x62,
+0x6f, 0x74, 0x61, 0x3b, 0x4e, 0x3b, 0x50, 0x3b, 0x57, 0x3b, 0x15a, 0x3b, 0x43, 0x3b, 0x50, 0x3b, 0x53, 0x3b, 0x64, 0x6f,
+0x6d, 0x3b, 0x73, 0x65, 0x67, 0x3b, 0x74, 0x65, 0x72, 0x3b, 0x71, 0x75, 0x61, 0x3b, 0x71, 0x75, 0x69, 0x3b, 0x73, 0x65,
+0x78, 0x3b, 0x73, 0xe1, 0x62, 0x3b, 0x64, 0x6f, 0x6d, 0x69, 0x6e, 0x67, 0x6f, 0x3b, 0x73, 0x65, 0x67, 0x75, 0x6e, 0x64,
+0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x74, 0x65, 0x72, 0xe7, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b,
+0x71, 0x75, 0x61, 0x72, 0x74, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x71, 0x75, 0x69, 0x6e, 0x74, 0x61, 0x2d,
+0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x73, 0x65, 0x78, 0x74, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x73, 0xe1,
+0x62, 0x61, 0x64, 0x6f, 0x3b, 0x44, 0x3b, 0x53, 0x3b, 0x54, 0x3b, 0x51, 0x3b, 0x51, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x44,
+0x6f, 0x6d, 0x69, 0x6e, 0x67, 0x6f, 0x3b, 0x53, 0x65, 0x67, 0x75, 0x6e, 0x64, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61,
+0x3b, 0x54, 0x65, 0x72, 0xe7, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x51, 0x75, 0x61, 0x72, 0x74, 0x61, 0x2d,
+0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x51, 0x75, 0x69, 0x6e, 0x74, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x53,
+0x65, 0x78, 0x74, 0x61, 0x2d, 0x66, 0x65, 0x69, 0x72, 0x61, 0x3b, 0x53, 0xe1, 0x62, 0x61, 0x64, 0x6f, 0x3b, 0xa10, 0xa24,
+0x2e, 0x3b, 0xa38, 0xa4b, 0xa2e, 0x2e, 0x3b, 0xa2e, 0xa70, 0xa17, 0xa32, 0x2e, 0x3b, 0xa2c, 0xa41, 0xa27, 0x2e, 0x3b, 0xa35, 0xa40,
+0xa30, 0x2e, 0x3b, 0xa38, 0xa3c, 0xa41, 0xa15, 0xa30, 0x2e, 0x3b, 0xa38, 0xa3c, 0xa28, 0xa40, 0x2e, 0x3b, 0xa10, 0xa24, 0xa35, 0xa3e,
+0xa30, 0x3b, 0xa38, 0xa4b, 0xa2e, 0xa35, 0xa3e, 0xa30, 0x3b, 0xa2e, 0xa70, 0xa17, 0xa32, 0xa35, 0xa3e, 0xa30, 0x3b, 0xa2c, 0xa41, 0xa27,
+0xa35, 0xa3e, 0xa30, 0x3b, 0xa35, 0xa40, 0xa30, 0xa35, 0xa3e, 0xa30, 0x3b, 0xa38, 0xa3c, 0xa41, 0xa71, 0xa15, 0xa30, 0xa35, 0xa3e, 0xa30,
+0x3b, 0xa38, 0xa3c, 0xa28, 0xa40, 0xa1a, 0xa30, 0xa35, 0xa3e, 0xa30, 0x3b, 0xa10, 0x3b, 0xa38, 0xa4b, 0x3b, 0xa2e, 0xa70, 0x3b, 0xa2c,
+0xa41, 0xa71, 0x3b, 0xa35, 0xa40, 0x3b, 0xa38, 0xa3c, 0xa41, 0xa71, 0x3b, 0xa38, 0xa3c, 0x3b, 0x627, 0x62a, 0x648, 0x627, 0x631, 0x3b,
+0x67e, 0x6cc, 0x631, 0x3b, 0x645, 0x646, 0x6af, 0x644, 0x3b, 0x628, 0x64f, 0x62f, 0x6be, 0x3b, 0x62c, 0x645, 0x639, 0x631, 0x627, 0x62a,
+0x3b, 0x62c, 0x645, 0x639, 0x6c1, 0x3b, 0x6c1, 0x641, 0x62a, 0x6c1, 0x3b, 0x64, 0x75, 0x3b, 0x67, 0x6c, 0x69, 0x3b, 0x6d, 0x61,
+0x3b, 0x6d, 0x65, 0x3b, 0x67, 0x69, 0x65, 0x3b, 0x76, 0x65, 0x3b, 0x73, 0x6f, 0x3b, 0x64, 0x75, 0x6d, 0x65, 0x6e, 0x67,
+0x69, 0x61, 0x3b, 0x67, 0x6c, 0x69, 0x6e, 0x64, 0x65, 0x73, 0x64, 0x69, 0x3b, 0x6d, 0x61, 0x72, 0x64, 0x69, 0x3b, 0x6d,
+0x65, 0x73, 0x65, 0x6d, 0x6e, 0x61, 0x3b, 0x67, 0x69, 0x65, 0x76, 0x67, 0x69, 0x61, 0x3b, 0x76, 0x65, 0x6e, 0x64, 0x65,
+0x72, 0x64, 0x69, 0x3b, 0x73, 0x6f, 0x6e, 0x64, 0x61, 0x3b, 0x44, 0x3b, 0x47, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x47, 0x3b,
+0x56, 0x3b, 0x53, 0x3b, 0x44, 0x75, 0x3b, 0x4c, 0x75, 0x3b, 0x4d, 0x61, 0x3b, 0x4d, 0x69, 0x3b, 0x4a, 0x6f, 0x3b, 0x56,
+0x69, 0x3b, 0x53, 0xe2, 0x3b, 0x64, 0x75, 0x6d, 0x69, 0x6e, 0x69, 0x63, 0x103, 0x3b, 0x6c, 0x75, 0x6e, 0x69, 0x3b, 0x6d,
+0x61, 0x72, 0x21b, 0x69, 0x3b, 0x6d, 0x69, 0x65, 0x72, 0x63, 0x75, 0x72, 0x69, 0x3b, 0x6a, 0x6f, 0x69, 0x3b, 0x76, 0x69,
+0x6e, 0x65, 0x72, 0x69, 0x3b, 0x73, 0xe2, 0x6d, 0x62, 0x103, 0x74, 0x103, 0x3b, 0x412, 0x441, 0x3b, 0x41f, 0x43d, 0x3b, 0x412,
+0x442, 0x3b, 0x421, 0x440, 0x3b, 0x427, 0x442, 0x3b, 0x41f, 0x442, 0x3b, 0x421, 0x431, 0x3b, 0x412, 0x43e, 0x441, 0x43a, 0x440, 0x435,
+0x441, 0x435, 0x43d, 0x44c, 0x435, 0x3b, 0x41f, 0x43e, 0x43d, 0x435, 0x434, 0x435, 0x43b, 0x44c, 0x43d, 0x438, 0x43a, 0x3b, 0x412, 0x442,
+0x43e, 0x440, 0x43d, 0x438, 0x43a, 0x3b, 0x421, 0x440, 0x435, 0x434, 0x430, 0x3b, 0x427, 0x435, 0x442, 0x432, 0x435, 0x440, 0x433, 0x3b,
+0x41f, 0x44f, 0x442, 0x43d, 0x438, 0x446, 0x430, 0x3b, 0x421, 0x443, 0x431, 0x431, 0x43e, 0x442, 0x430, 0x3b, 0x412, 0x3b, 0x41f, 0x3b,
+0x412, 0x3b, 0x421, 0x3b, 0x427, 0x3b, 0x41f, 0x3b, 0x421, 0x3b, 0x432, 0x441, 0x3b, 0x43f, 0x43d, 0x3b, 0x432, 0x442, 0x3b, 0x441,
+0x440, 0x3b, 0x447, 0x442, 0x3b, 0x43f, 0x442, 0x3b, 0x441, 0x431, 0x3b, 0x432, 0x43e, 0x441, 0x43a, 0x440, 0x435, 0x441, 0x435, 0x43d,
+0x44c, 0x435, 0x3b, 0x43f, 0x43e, 0x43d, 0x435, 0x434, 0x435, 0x43b, 0x44c, 0x43d, 0x438, 0x43a, 0x3b, 0x432, 0x442, 0x43e, 0x440, 0x43d,
+0x438, 0x43a, 0x3b, 0x441, 0x440, 0x435, 0x434, 0x430, 0x3b, 0x447, 0x435, 0x442, 0x432, 0x435, 0x440, 0x433, 0x3b, 0x43f, 0x44f, 0x442,
+0x43d, 0x438, 0x446, 0x430, 0x3b, 0x441, 0x443, 0x431, 0x431, 0x43e, 0x442, 0x430, 0x3b, 0x42, 0x6b, 0x31, 0x3b, 0x42, 0x6b, 0x32,
+0x3b, 0x42, 0x6b, 0x33, 0x3b, 0x42, 0x6b, 0x34, 0x3b, 0x42, 0x6b, 0x35, 0x3b, 0x4c, 0xe2, 0x70, 0x3b, 0x4c, 0xe2, 0x79,
+0x3b, 0x42, 0x69, 0x6b, 0x75, 0x61, 0x2d, 0xf4, 0x6b, 0x6f, 0x3b, 0x42, 0xef, 0x6b, 0x75, 0x61, 0x2d, 0xfb, 0x73, 0x65,
+0x3b, 0x42, 0xef, 0x6b, 0x75, 0x61, 0x2d, 0x70, 0x74, 0xe2, 0x3b, 0x42, 0xef, 0x6b, 0x75, 0x61, 0x2d, 0x75, 0x73, 0xef,
+0xf6, 0x3b, 0x42, 0xef, 0x6b, 0x75, 0x61, 0x2d, 0x6f, 0x6b, 0xfc, 0x3b, 0x4c, 0xe2, 0x70, 0xf4, 0x73, 0xf6, 0x3b, 0x4c,
+0xe2, 0x79, 0x65, 0x6e, 0x67, 0x61, 0x3b, 0x4b, 0x3b, 0x53, 0x3b, 0x54, 0x3b, 0x53, 0x3b, 0x4b, 0x3b, 0x50, 0x3b, 0x59,
+0x3b, 0x43d, 0x435, 0x434, 0x3b, 0x43f, 0x43e, 0x43d, 0x3b, 0x443, 0x442, 0x43e, 0x3b, 0x441, 0x440, 0x435, 0x3b, 0x447, 0x435, 0x442,
+0x3b, 0x43f, 0x435, 0x442, 0x3b, 0x441, 0x443, 0x431, 0x3b, 0x43d, 0x435, 0x434, 0x435, 0x459, 0x430, 0x3b, 0x43f, 0x43e, 0x43d, 0x435,
+0x434, 0x435, 0x459, 0x430, 0x43a, 0x3b, 0x443, 0x442, 0x43e, 0x440, 0x430, 0x43a, 0x3b, 0x441, 0x440, 0x435, 0x434, 0x430, 0x3b, 0x447,
+0x435, 0x442, 0x432, 0x440, 0x442, 0x430, 0x43a, 0x3b, 0x43f, 0x435, 0x442, 0x430, 0x43a, 0x3b, 0x441, 0x443, 0x431, 0x43e, 0x442, 0x430,
+0x3b, 0x43d, 0x3b, 0x43f, 0x3b, 0x443, 0x3b, 0x441, 0x3b, 0x447, 0x3b, 0x43f, 0x3b, 0x441, 0x3b, 0x43d, 0x435, 0x434, 0x3b, 0x43f,
+0x43e, 0x43d, 0x3b, 0x443, 0x442, 0x43e, 0x3b, 0x441, 0x440, 0x438, 0x3b, 0x447, 0x435, 0x442, 0x3b, 0x43f, 0x435, 0x442, 0x3b, 0x441,
+0x443, 0x431, 0x3b, 0x43d, 0x435, 0x434, 0x435, 0x459, 0x430, 0x3b, 0x43f, 0x43e, 0x43d, 0x435, 0x434, 0x435, 0x459, 0x430, 0x43a, 0x3b,
+0x443, 0x442, 0x43e, 0x440, 0x430, 0x43a, 0x3b, 0x441, 0x440, 0x438, 0x458, 0x435, 0x434, 0x430, 0x3b, 0x447, 0x435, 0x442, 0x432, 0x440,
+0x442, 0x430, 0x43a, 0x3b, 0x43f, 0x435, 0x442, 0x430, 0x43a, 0x3b, 0x441, 0x443, 0x431, 0x43e, 0x442, 0x430, 0x3b, 0x6e, 0x65, 0x64,
+0x3b, 0x70, 0x6f, 0x6e, 0x3b, 0x75, 0x74, 0x6f, 0x3b, 0x73, 0x72, 0x65, 0x3b, 0x10d, 0x65, 0x74, 0x3b, 0x70, 0x65, 0x74,
+0x3b, 0x73, 0x75, 0x62, 0x3b, 0x6e, 0x65, 0x64, 0x65, 0x6c, 0x6a, 0x61, 0x3b, 0x70, 0x6f, 0x6e, 0x65, 0x64, 0x65, 0x6c,
+0x6a, 0x61, 0x6b, 0x3b, 0x75, 0x74, 0x6f, 0x72, 0x61, 0x6b, 0x3b, 0x73, 0x72, 0x65, 0x64, 0x61, 0x3b, 0x10d, 0x65, 0x74,
+0x76, 0x72, 0x74, 0x61, 0x6b, 0x3b, 0x70, 0x65, 0x74, 0x61, 0x6b, 0x3b, 0x73, 0x75, 0x62, 0x6f, 0x74, 0x61, 0x3b, 0x425,
+0x446, 0x431, 0x3b, 0x41a, 0x440, 0x441, 0x3b, 0x414, 0x446, 0x433, 0x3b, 0x4d4, 0x440, 0x442, 0x3b, 0x426, 0x43f, 0x440, 0x3b, 0x41c,
+0x440, 0x431, 0x3b, 0x421, 0x431, 0x442, 0x3b, 0x425, 0x443, 0x44b, 0x446, 0x430, 0x443, 0x431, 0x43e, 0x43d, 0x3b, 0x41a, 0x44a, 0x443,
+0x44b, 0x440, 0x438, 0x441, 0x4d5, 0x440, 0x3b, 0x414, 0x44b, 0x446, 0x446, 0x4d5, 0x433, 0x3b, 0x4d4, 0x440, 0x442, 0x44b, 0x446, 0x446,
+0x4d5, 0x433, 0x3b, 0x426, 0x44b, 0x43f, 0x43f, 0x4d5, 0x440, 0x4d5, 0x43c, 0x3b, 0x41c, 0x430, 0x439, 0x440, 0x4d5, 0x43c, 0x431, 0x43e,
+0x43d, 0x3b, 0x421, 0x430, 0x431, 0x430, 0x442, 0x3b, 0x425, 0x3b, 0x41a, 0x3b, 0x414, 0x3b, 0x4d4, 0x3b, 0x426, 0x3b, 0x41c, 0x3b,
+0x421, 0x3b, 0x445, 0x446, 0x431, 0x3b, 0x43a, 0x440, 0x441, 0x3b, 0x434, 0x446, 0x433, 0x3b, 0x4d5, 0x440, 0x442, 0x3b, 0x446, 0x43f,
+0x440, 0x3b, 0x43c, 0x440, 0x431, 0x3b, 0x441, 0x431, 0x442, 0x3b, 0x445, 0x443, 0x44b, 0x446, 0x430, 0x443, 0x431, 0x43e, 0x43d, 0x3b,
+0x43a, 0x44a, 0x443, 0x44b, 0x440, 0x438, 0x441, 0x4d5, 0x440, 0x3b, 0x434, 0x44b, 0x446, 0x446, 0x4d5, 0x433, 0x3b, 0x4d5, 0x440, 0x442,
+0x44b, 0x446, 0x446, 0x4d5, 0x433, 0x3b, 0x446, 0x44b, 0x43f, 0x43f, 0x4d5, 0x440, 0x4d5, 0x43c, 0x3b, 0x43c, 0x430, 0x439, 0x440, 0x4d5,
+0x43c, 0x431, 0x43e, 0x43d, 0x3b, 0x441, 0x430, 0x431, 0x430, 0x442, 0x3b, 0x53, 0x6f, 0x6e, 0x3b, 0x4d, 0x6d, 0x61, 0x3b, 0x42,
+0x65, 0x64, 0x3b, 0x52, 0x61, 0x72, 0x3b, 0x4e, 0x65, 0x3b, 0x48, 0x6c, 0x61, 0x3b, 0x4d, 0x6f, 0x71, 0x3b, 0x53, 0x6f,
+0x6e, 0x74, 0x61, 0x68, 0x61, 0x3b, 0x4d, 0x6d, 0x61, 0x6e, 0x74, 0x61, 0x68, 0x61, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x62,
+0x65, 0x64, 0x69, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x72, 0x75, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x6e, 0x65, 0x3b,
+0x4c, 0x61, 0x62, 0x6f, 0x68, 0x6c, 0x61, 0x6e, 0x65, 0x3b, 0x4d, 0x6f, 0x71, 0x65, 0x62, 0x65, 0x6c, 0x6f, 0x3b, 0x54,
+0x73, 0x68, 0x3b, 0x4d, 0x6f, 0x73, 0x3b, 0x42, 0x65, 0x64, 0x3b, 0x52, 0x61, 0x72, 0x3b, 0x4e, 0x65, 0x3b, 0x54, 0x6c,
+0x61, 0x3b, 0x4d, 0x61, 0x74, 0x3b, 0x54, 0x73, 0x68, 0x69, 0x70, 0x69, 0x3b, 0x4d, 0x6f, 0x73, 0x6f, 0x70, 0x75, 0x6c,
0x6f, 0x67, 0x6f, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x62, 0x65, 0x64, 0x69, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x72,
-0x6f, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x6e, 0x65, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x68, 0x6c, 0x61, 0x6e, 0x6f, 0x3b, 0x4d,
-0x6f, 0x6b, 0x69, 0x62, 0x65, 0x6c, 0x6f, 0x3b, 0x73, 0x6f, 0x74, 0x6e, 0x3b, 0x76, 0x75, 0x6f, 0x73, 0x3b, 0x6d, 0x61,
-0x14b, 0x3b, 0x67, 0x61, 0x73, 0x6b, 0x3b, 0x64, 0x75, 0x6f, 0x72, 0x3b, 0x62, 0x65, 0x61, 0x72, 0x3b, 0x6c, 0xe1, 0x76,
-0x3b, 0x73, 0x6f, 0x74, 0x6e, 0x61, 0x62, 0x65, 0x61, 0x69, 0x76, 0x69, 0x3b, 0x76, 0x75, 0x6f, 0x73, 0x73, 0xe1, 0x72,
-0x67, 0x61, 0x3b, 0x6d, 0x61, 0x14b, 0x14b, 0x65, 0x62, 0xe1, 0x72, 0x67, 0x61, 0x3b, 0x67, 0x61, 0x73, 0x6b, 0x61, 0x76,
-0x61, 0x68, 0x6b, 0x6b, 0x75, 0x3b, 0x64, 0x75, 0x6f, 0x72, 0x61, 0x73, 0x64, 0x61, 0x74, 0x3b, 0x62, 0x65, 0x61, 0x72,
-0x6a, 0x61, 0x64, 0x61, 0x74, 0x3b, 0x6c, 0xe1, 0x76, 0x76, 0x61, 0x72, 0x64, 0x61, 0x74, 0x3b, 0x53, 0x3b, 0x56, 0x3b,
-0x4d, 0x3b, 0x47, 0x3b, 0x44, 0x3b, 0x42, 0x3b, 0x4c, 0x3b, 0x61, 0x65, 0x6a, 0x6c, 0x65, 0x67, 0x65, 0x3b, 0x6d, 0xe5,
-0x61, 0x6e, 0x74, 0x61, 0x3b, 0x64, 0xe4, 0x6a, 0x73, 0x74, 0x61, 0x3b, 0x67, 0x61, 0x73, 0x6b, 0x65, 0x76, 0x61, 0x68,
-0x6b, 0x6f, 0x65, 0x3b, 0x64, 0xe5, 0x61, 0x72, 0x73, 0x74, 0x61, 0x3b, 0x62, 0x65, 0x61, 0x72, 0x6a, 0x61, 0x64, 0x61,
-0x68, 0x6b, 0x65, 0x3b, 0x6c, 0x61, 0x61, 0x76, 0x61, 0x64, 0x61, 0x68, 0x6b, 0x65, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x44,
-0x3b, 0x47, 0x3b, 0x44, 0x3b, 0x42, 0x3b, 0x4c, 0x3b, 0x43, 0x70, 0x72, 0x3b, 0x43, 0x74, 0x74, 0x3b, 0x43, 0x6d, 0x6e,
-0x3b, 0x43, 0x6d, 0x74, 0x3b, 0x41, 0x72, 0x73, 0x3b, 0x49, 0x63, 0x6d, 0x3b, 0x45, 0x73, 0x74, 0x3b, 0x43, 0x68, 0x75,
-0x6d, 0x61, 0x70, 0x69, 0x72, 0x69, 0x3b, 0x43, 0x68, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x6f, 0x3b, 0x43, 0x68, 0x75,
-0x6d, 0x61, 0x69, 0x6e, 0x65, 0x3b, 0x43, 0x68, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x72, 0x61, 0x6d,
-0x69, 0x73, 0x69, 0x3b, 0x49, 0x63, 0x68, 0x75, 0x6d, 0x61, 0x3b, 0x45, 0x73, 0x61, 0x62, 0x61, 0x74, 0x6f, 0x3b, 0x43,
-0x3b, 0x43, 0x3b, 0x43, 0x3b, 0x43, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x45, 0x3b, 0x4a, 0x75, 0x6d, 0x3b, 0x4a, 0x69, 0x6d,
-0x3b, 0x4b, 0x61, 0x77, 0x3b, 0x4b, 0x61, 0x64, 0x3b, 0x4b, 0x61, 0x6e, 0x3b, 0x4b, 0x61, 0x73, 0x3b, 0x4e, 0x67, 0x75,
-0x3b, 0x49, 0x74, 0x75, 0x6b, 0x75, 0x20, 0x6a, 0x61, 0x20, 0x6a, 0x75, 0x6d, 0x77, 0x61, 0x3b, 0x4b, 0x75, 0x72, 0x61,
-0x6d, 0x75, 0x6b, 0x61, 0x20, 0x6a, 0x69, 0x6d, 0x77, 0x65, 0x72, 0x69, 0x3b, 0x4b, 0x75, 0x72, 0x61, 0x6d, 0x75, 0x6b,
-0x61, 0x20, 0x6b, 0x61, 0x77, 0x69, 0x3b, 0x4b, 0x75, 0x72, 0x61, 0x6d, 0x75, 0x6b, 0x61, 0x20, 0x6b, 0x61, 0x64, 0x61,
-0x64, 0x75, 0x3b, 0x4b, 0x75, 0x72, 0x61, 0x6d, 0x75, 0x6b, 0x61, 0x20, 0x6b, 0x61, 0x6e, 0x61, 0x3b, 0x4b, 0x75, 0x72,
-0x61, 0x6d, 0x75, 0x6b, 0x61, 0x20, 0x6b, 0x61, 0x73, 0x61, 0x6e, 0x75, 0x3b, 0x4b, 0x69, 0x66, 0x75, 0x6c, 0x61, 0x20,
-0x6e, 0x67, 0x75, 0x77, 0x6f, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4e, 0x3b,
-0x64, 0x65, 0x77, 0x3b, 0x61, 0x61, 0x253, 0x3b, 0x6d, 0x61, 0x77, 0x3b, 0x6e, 0x6a, 0x65, 0x3b, 0x6e, 0x61, 0x61, 0x3b,
-0x6d, 0x77, 0x64, 0x3b, 0x68, 0x62, 0x69, 0x3b, 0x64, 0x65, 0x77, 0x6f, 0x3b, 0x61, 0x61, 0x253, 0x6e, 0x64, 0x65, 0x3b,
-0x6d, 0x61, 0x77, 0x62, 0x61, 0x61, 0x72, 0x65, 0x3b, 0x6e, 0x6a, 0x65, 0x73, 0x6c, 0x61, 0x61, 0x72, 0x65, 0x3b, 0x6e,
-0x61, 0x61, 0x73, 0x61, 0x61, 0x6e, 0x64, 0x65, 0x3b, 0x6d, 0x61, 0x77, 0x6e, 0x64, 0x65, 0x3b, 0x68, 0x6f, 0x6f, 0x72,
-0x65, 0x2d, 0x62, 0x69, 0x69, 0x72, 0x3b, 0x64, 0x3b, 0x61, 0x3b, 0x6d, 0x3b, 0x6e, 0x3b, 0x6e, 0x3b, 0x6d, 0x3b, 0x68,
-0x3b, 0x4b, 0x4d, 0x41, 0x3b, 0x4e, 0x54, 0x54, 0x3b, 0x4e, 0x4d, 0x4e, 0x3b, 0x4e, 0x4d, 0x54, 0x3b, 0x41, 0x52, 0x54,
-0x3b, 0x4e, 0x4d, 0x41, 0x3b, 0x4e, 0x4d, 0x4d, 0x3b, 0x4b, 0x69, 0x75, 0x6d, 0x69, 0x61, 0x3b, 0x4e, 0x6a, 0x75, 0x6d,
-0x61, 0x74, 0x61, 0x74, 0x169, 0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61, 0x69, 0x6e, 0x65, 0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61,
-0x74, 0x61, 0x6e, 0x61, 0x3b, 0x41, 0x72, 0x61, 0x6d, 0x69, 0x74, 0x68, 0x69, 0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61, 0x61,
-0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x74, 0x68, 0x69, 0x3b, 0x4b, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b,
-0x41, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x41, 0x72, 0x65, 0x3b, 0x4b, 0x75, 0x6e, 0x3b, 0x4f, 0x6e, 0x67, 0x3b, 0x49, 0x6e,
-0x65, 0x3b, 0x49, 0x6c, 0x65, 0x3b, 0x53, 0x61, 0x70, 0x3b, 0x4b, 0x77, 0x65, 0x3b, 0x4d, 0x64, 0x65, 0x72, 0x6f, 0x74,
-0x20, 0x65, 0x65, 0x20, 0x61, 0x72, 0x65, 0x3b, 0x4d, 0x64, 0x65, 0x72, 0x6f, 0x74, 0x20, 0x65, 0x65, 0x20, 0x6b, 0x75,
-0x6e, 0x69, 0x3b, 0x4d, 0x64, 0x65, 0x72, 0x6f, 0x74, 0x20, 0x65, 0x65, 0x20, 0x6f, 0x6e, 0x67, 0x27, 0x77, 0x61, 0x6e,
-0x3b, 0x4d, 0x64, 0x65, 0x72, 0x6f, 0x74, 0x20, 0x65, 0x65, 0x20, 0x69, 0x6e, 0x65, 0x74, 0x3b, 0x4d, 0x64, 0x65, 0x72,
-0x6f, 0x74, 0x20, 0x65, 0x65, 0x20, 0x69, 0x6c, 0x65, 0x3b, 0x4d, 0x64, 0x65, 0x72, 0x6f, 0x74, 0x20, 0x65, 0x65, 0x20,
-0x73, 0x61, 0x70, 0x61, 0x3b, 0x4d, 0x64, 0x65, 0x72, 0x6f, 0x74, 0x20, 0x65, 0x65, 0x20, 0x6b, 0x77, 0x65, 0x3b, 0x41,
-0x3b, 0x4b, 0x3b, 0x4f, 0x3b, 0x49, 0x3b, 0x49, 0x3b, 0x53, 0x3b, 0x4b, 0x3b, 0x44, 0x69, 0x6d, 0x3b, 0x50, 0x6f, 0x73,
-0x3b, 0x50, 0x69, 0x72, 0x3b, 0x54, 0x61, 0x74, 0x3b, 0x4e, 0x61, 0x69, 0x3b, 0x53, 0x68, 0x61, 0x3b, 0x53, 0x61, 0x62,
-0x3b, 0x44, 0x69, 0x6d, 0x69, 0x6e, 0x67, 0x75, 0x3b, 0x43, 0x68, 0x69, 0x70, 0x6f, 0x73, 0x69, 0x3b, 0x43, 0x68, 0x69,
-0x70, 0x69, 0x72, 0x69, 0x3b, 0x43, 0x68, 0x69, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x43, 0x68, 0x69, 0x6e, 0x61, 0x69, 0x3b,
-0x43, 0x68, 0x69, 0x73, 0x68, 0x61, 0x6e, 0x75, 0x3b, 0x53, 0x61, 0x62, 0x75, 0x64, 0x75, 0x3b, 0x44, 0x3b, 0x50, 0x3b,
-0x43, 0x3b, 0x54, 0x3b, 0x4e, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x53, 0x6f, 0x6e, 0x3b, 0x4d, 0x76, 0x75, 0x3b, 0x53, 0x69,
-0x62, 0x3b, 0x53, 0x69, 0x74, 0x3b, 0x53, 0x69, 0x6e, 0x3b, 0x53, 0x69, 0x68, 0x3b, 0x4d, 0x67, 0x71, 0x3b, 0x53, 0x6f,
-0x6e, 0x74, 0x6f, 0x3b, 0x4d, 0x76, 0x75, 0x6c, 0x6f, 0x3b, 0x53, 0x69, 0x62, 0x69, 0x6c, 0x69, 0x3b, 0x53, 0x69, 0x74,
-0x68, 0x61, 0x74, 0x68, 0x75, 0x3b, 0x53, 0x69, 0x6e, 0x65, 0x3b, 0x53, 0x69, 0x68, 0x6c, 0x61, 0x6e, 0x75, 0x3b, 0x4d,
-0x67, 0x71, 0x69, 0x62, 0x65, 0x6c, 0x6f, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x53, 0x3b,
-0x4d, 0x3b, 0x49, 0x6a, 0x70, 0x3b, 0x49, 0x6a, 0x74, 0x3b, 0x49, 0x6a, 0x6e, 0x3b, 0x49, 0x6a, 0x74, 0x6e, 0x3b, 0x41,
-0x6c, 0x68, 0x3b, 0x49, 0x6a, 0x75, 0x3b, 0x49, 0x6a, 0x6d, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x70, 0x69, 0x6c, 0x69,
-0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x6e, 0x6e, 0x65, 0x3b,
-0x49, 0x6a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x49,
-0x6a, 0x75, 0x6d, 0x61, 0x61, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x32, 0x3b, 0x33, 0x3b,
-0x34, 0x3b, 0x35, 0x3b, 0x36, 0x3b, 0x37, 0x3b, 0x31, 0x3b, 0x2d30, 0x2d59, 0x2d30, 0x3b, 0x2d30, 0x2d62, 0x2d4f, 0x3b, 0x2d30, 0x2d59,
-0x2d49, 0x3b, 0x2d30, 0x2d3d, 0x2d55, 0x3b, 0x2d30, 0x2d3d, 0x2d61, 0x3b, 0x2d30, 0x2d59, 0x2d49, 0x2d4e, 0x3b, 0x2d30, 0x2d59, 0x2d49, 0x2d39, 0x3b,
-0x2d30, 0x2d59, 0x2d30, 0x2d4e, 0x2d30, 0x2d59, 0x3b, 0x2d30, 0x2d62, 0x2d4f, 0x2d30, 0x2d59, 0x3b, 0x2d30, 0x2d59, 0x2d49, 0x2d4f, 0x2d30, 0x2d59, 0x3b,
-0x2d30, 0x2d3d, 0x2d55, 0x2d30, 0x2d59, 0x3b, 0x2d30, 0x2d3d, 0x2d61, 0x2d30, 0x2d59, 0x3b, 0x2d59, 0x2d49, 0x2d4e, 0x2d61, 0x2d30, 0x2d59, 0x3b, 0x2d30,
-0x2d59, 0x2d49, 0x2d39, 0x2d62, 0x2d30, 0x2d59, 0x3b, 0x61, 0x73, 0x61, 0x3b, 0x61, 0x79, 0x6e, 0x3b, 0x61, 0x73, 0x69, 0x3b, 0x61,
-0x6b, 0x1e5b, 0x3b, 0x61, 0x6b, 0x77, 0x3b, 0x61, 0x73, 0x69, 0x6d, 0x3b, 0x61, 0x73, 0x69, 0x1e0d, 0x3b, 0x61, 0x73, 0x61,
-0x6d, 0x61, 0x73, 0x3b, 0x61, 0x79, 0x6e, 0x61, 0x73, 0x3b, 0x61, 0x73, 0x69, 0x6e, 0x61, 0x73, 0x3b, 0x61, 0x6b, 0x1e5b,
-0x61, 0x73, 0x3b, 0x61, 0x6b, 0x77, 0x61, 0x73, 0x3b, 0x61, 0x73, 0x69, 0x6d, 0x77, 0x61, 0x73, 0x3b, 0x61, 0x73, 0x69,
-0x1e0d, 0x79, 0x61, 0x73, 0x3b, 0x59, 0x61, 0x6e, 0x3b, 0x53, 0x61, 0x6e, 0x3b, 0x4b, 0x72, 0x61, 0x1e0d, 0x3b, 0x4b, 0x75,
-0x1e93, 0x3b, 0x53, 0x61, 0x6d, 0x3b, 0x53, 0x1e0d, 0x69, 0x73, 0x3b, 0x53, 0x61, 0x79, 0x3b, 0x59, 0x61, 0x6e, 0x61, 0x73,
-0x73, 0x3b, 0x53, 0x61, 0x6e, 0x61, 0x73, 0x73, 0x3b, 0x4b, 0x72, 0x61, 0x1e0d, 0x61, 0x73, 0x73, 0x3b, 0x4b, 0x75, 0x1e93,
-0x61, 0x73, 0x73, 0x3b, 0x53, 0x61, 0x6d, 0x61, 0x73, 0x73, 0x3b, 0x53, 0x1e0d, 0x69, 0x73, 0x61, 0x73, 0x73, 0x3b, 0x53,
-0x61, 0x79, 0x61, 0x73, 0x73, 0x3b, 0x59, 0x3b, 0x53, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x53, 0x3b,
-0x53, 0x41, 0x4e, 0x3b, 0x4f, 0x52, 0x4b, 0x3b, 0x4f, 0x4b, 0x42, 0x3b, 0x4f, 0x4b, 0x53, 0x3b, 0x4f, 0x4b, 0x4e, 0x3b,
-0x4f, 0x4b, 0x54, 0x3b, 0x4f, 0x4d, 0x4b, 0x3b, 0x53, 0x61, 0x6e, 0x64, 0x65, 0x3b, 0x4f, 0x72, 0x77, 0x6f, 0x6b, 0x75,
-0x62, 0x61, 0x6e, 0x7a, 0x61, 0x3b, 0x4f, 0x72, 0x77, 0x61, 0x6b, 0x61, 0x62, 0x69, 0x72, 0x69, 0x3b, 0x4f, 0x72, 0x77,
-0x61, 0x6b, 0x61, 0x73, 0x68, 0x61, 0x74, 0x75, 0x3b, 0x4f, 0x72, 0x77, 0x61, 0x6b, 0x61, 0x6e, 0x61, 0x3b, 0x4f, 0x72,
-0x77, 0x61, 0x6b, 0x61, 0x74, 0x61, 0x61, 0x6e, 0x6f, 0x3b, 0x4f, 0x72, 0x77, 0x61, 0x6d, 0x75, 0x6b, 0x61, 0x61, 0x67,
-0x61, 0x3b, 0x53, 0x3b, 0x4b, 0x3b, 0x52, 0x3b, 0x53, 0x3b, 0x4e, 0x3b, 0x54, 0x3b, 0x4d, 0x3b, 0x4d, 0x75, 0x6c, 0x3b,
-0x56, 0x69, 0x6c, 0x3b, 0x48, 0x69, 0x76, 0x3b, 0x48, 0x69, 0x64, 0x3b, 0x48, 0x69, 0x74, 0x3b, 0x48, 0x69, 0x68, 0x3b,
-0x4c, 0x65, 0x6d, 0x3b, 0x70, 0x61, 0x20, 0x6d, 0x75, 0x6c, 0x75, 0x6e, 0x67, 0x75, 0x3b, 0x70, 0x61, 0x20, 0x73, 0x68,
-0x61, 0x68, 0x75, 0x76, 0x69, 0x6c, 0x75, 0x68, 0x61, 0x3b, 0x70, 0x61, 0x20, 0x68, 0x69, 0x76, 0x69, 0x6c, 0x69, 0x3b,
-0x70, 0x61, 0x20, 0x68, 0x69, 0x64, 0x61, 0x74, 0x75, 0x3b, 0x70, 0x61, 0x20, 0x68, 0x69, 0x74, 0x61, 0x79, 0x69, 0x3b,
-0x70, 0x61, 0x20, 0x68, 0x69, 0x68, 0x61, 0x6e, 0x75, 0x3b, 0x70, 0x61, 0x20, 0x73, 0x68, 0x61, 0x68, 0x75, 0x6c, 0x65,
-0x6d, 0x62, 0x65, 0x6c, 0x61, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x48, 0x3b, 0x48, 0x3b, 0x48, 0x3b, 0x57, 0x3b, 0x4a, 0x3b,
-0x4a, 0x70, 0x69, 0x3b, 0x4a, 0x74, 0x74, 0x3b, 0x4a, 0x6e, 0x6e, 0x3b, 0x4a, 0x74, 0x6e, 0x3b, 0x41, 0x6c, 0x68, 0x3b,
-0x49, 0x6a, 0x75, 0x3b, 0x4a, 0x6d, 0x6f, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x70, 0x69, 0x6c, 0x79, 0x69, 0x3b, 0x4a, 0x75,
-0x6d, 0x61, 0x74, 0x61, 0x74, 0x75, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6e, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61,
-0x74, 0x61, 0x6e, 0x75, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x61,
-0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x41, 0x3b,
-0x49, 0x3b, 0x4a, 0x3b, 0x6b, 0x61, 0x72, 0x3b, 0x6e, 0x74, 0x25b, 0x3b, 0x74, 0x61, 0x72, 0x3b, 0x61, 0x72, 0x61, 0x3b,
-0x61, 0x6c, 0x61, 0x3b, 0x6a, 0x75, 0x6d, 0x3b, 0x73, 0x69, 0x62, 0x3b, 0x6b, 0x61, 0x72, 0x69, 0x3b, 0x6e, 0x74, 0x25b,
-0x6e, 0x25b, 0x3b, 0x74, 0x61, 0x72, 0x61, 0x74, 0x61, 0x3b, 0x61, 0x72, 0x61, 0x62, 0x61, 0x3b, 0x61, 0x6c, 0x61, 0x6d,
-0x69, 0x73, 0x61, 0x3b, 0x6a, 0x75, 0x6d, 0x61, 0x3b, 0x73, 0x69, 0x62, 0x69, 0x72, 0x69, 0x3b, 0x4b, 0x3b, 0x4e, 0x3b,
-0x54, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x4a, 0x3b, 0x53, 0x3b, 0x4b, 0x6d, 0x61, 0x3b, 0x54, 0x61, 0x74, 0x3b, 0x49, 0x6e,
-0x65, 0x3b, 0x54, 0x61, 0x6e, 0x3b, 0x41, 0x72, 0x6d, 0x3b, 0x4d, 0x61, 0x61, 0x3b, 0x4e, 0x4d, 0x4d, 0x3b, 0x4b, 0x69,
-0x75, 0x6d, 0x69, 0x61, 0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61,
-0x69, 0x6e, 0x65, 0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x72, 0x61, 0x6d, 0x69, 0x74,
-0x68, 0x69, 0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61, 0x61, 0x3b, 0x4e, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x74, 0x68, 0x69,
-0x69, 0x3b, 0x4b, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4e, 0x3b, 0x13c6, 0x13cd, 0x13ac, 0x3b,
-0x13c9, 0x13c5, 0x13af, 0x3b, 0x13d4, 0x13b5, 0x13c1, 0x3b, 0x13e6, 0x13a2, 0x13c1, 0x3b, 0x13c5, 0x13a9, 0x13c1, 0x3b, 0x13e7, 0x13be, 0x13a9, 0x3b,
-0x13c8, 0x13d5, 0x13be, 0x3b, 0x13a4, 0x13be, 0x13d9, 0x13d3, 0x13c6, 0x13cd, 0x13ac, 0x3b, 0x13a4, 0x13be, 0x13d9, 0x13d3, 0x13c9, 0x13c5, 0x13af, 0x3b,
-0x13d4, 0x13b5, 0x13c1, 0x13a2, 0x13a6, 0x3b, 0x13e6, 0x13a2, 0x13c1, 0x13a2, 0x13a6, 0x3b, 0x13c5, 0x13a9, 0x13c1, 0x13a2, 0x13a6, 0x3b, 0x13e7, 0x13be,
-0x13a9, 0x13b6, 0x13cd, 0x13d7, 0x3b, 0x13a4, 0x13be, 0x13d9, 0x13d3, 0x13c8, 0x13d5, 0x13be, 0x3b, 0x13c6, 0x3b, 0x13c9, 0x3b, 0x13d4, 0x3b, 0x13e6,
-0x3b, 0x13c5, 0x3b, 0x13e7, 0x3b, 0x13a4, 0x3b, 0x64, 0x69, 0x6d, 0x3b, 0x6c, 0x69, 0x6e, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x6d,
-0x65, 0x72, 0x3b, 0x7a, 0x65, 0x3b, 0x76, 0x61, 0x6e, 0x3b, 0x73, 0x61, 0x6d, 0x3b, 0x64, 0x69, 0x6d, 0x61, 0x6e, 0x73,
-0x3b, 0x6c, 0x69, 0x6e, 0x64, 0x69, 0x3b, 0x6d, 0x61, 0x72, 0x64, 0x69, 0x3b, 0x6d, 0x65, 0x72, 0x6b, 0x72, 0x65, 0x64,
-0x69, 0x3b, 0x7a, 0x65, 0x64, 0x69, 0x3b, 0x76, 0x61, 0x6e, 0x64, 0x72, 0x65, 0x64, 0x69, 0x3b, 0x73, 0x61, 0x6d, 0x64,
-0x69, 0x3b, 0x64, 0x3b, 0x6c, 0x3b, 0x6d, 0x3b, 0x6d, 0x3b, 0x7a, 0x3b, 0x76, 0x3b, 0x73, 0x3b, 0x4c, 0x6c, 0x32, 0x3b,
-0x4c, 0x6c, 0x33, 0x3b, 0x4c, 0x6c, 0x34, 0x3b, 0x4c, 0x6c, 0x35, 0x3b, 0x4c, 0x6c, 0x36, 0x3b, 0x4c, 0x6c, 0x37, 0x3b,
-0x4c, 0x6c, 0x31, 0x3b, 0x4c, 0x69, 0x64, 0x75, 0x76, 0x61, 0x20, 0x6c, 0x79, 0x61, 0x70, 0x69, 0x6c, 0x69, 0x3b, 0x4c,
-0x69, 0x64, 0x75, 0x76, 0x61, 0x20, 0x6c, 0x79, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x4c, 0x69, 0x64, 0x75, 0x76, 0x61,
-0x20, 0x6c, 0x79, 0x61, 0x6e, 0x63, 0x68, 0x65, 0x63, 0x68, 0x69, 0x3b, 0x4c, 0x69, 0x64, 0x75, 0x76, 0x61, 0x20, 0x6c,
-0x79, 0x61, 0x6e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x3b, 0x4c, 0x69, 0x64, 0x75, 0x76, 0x61, 0x20, 0x6c, 0x79, 0x61, 0x6e,
-0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x6c, 0x69, 0x6e, 0x6a, 0x69, 0x3b, 0x4c, 0x69, 0x64, 0x75, 0x76,
-0x61, 0x20, 0x6c, 0x79, 0x61, 0x6e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x61, 0x76, 0x69, 0x6c,
-0x69, 0x3b, 0x4c, 0x69, 0x64, 0x75, 0x76, 0x61, 0x20, 0x6c, 0x69, 0x74, 0x61, 0x6e, 0x64, 0x69, 0x3b, 0x50, 0xed, 0x69,
-0x6c, 0x69, 0x3b, 0x54, 0xe1, 0x61, 0x74, 0x75, 0x3b, 0xcd, 0x6e, 0x65, 0x3b, 0x54, 0xe1, 0x61, 0x6e, 0x6f, 0x3b, 0x41,
-0x6c, 0x68, 0x3b, 0x49, 0x6a, 0x6d, 0x3b, 0x4d, 0xf3, 0x6f, 0x73, 0x69, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x70, 0xed, 0x69,
-0x72, 0x69, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0xe1, 0x74, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0xed, 0x6e, 0x65, 0x3b,
-0x4a, 0x75, 0x6d, 0x61, 0x74, 0xe1, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x6c, 0x61, 0x6d, 0xed, 0x69, 0x73, 0x69, 0x3b, 0x49,
-0x6a, 0x75, 0x6d, 0xe1, 0x61, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0xf3, 0x6f, 0x73, 0x69, 0x3b, 0x50, 0x3b, 0x54, 0x3b,
-0x45, 0x3b, 0x4f, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x4d, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x42, 0x61, 0x6c, 0x3b, 0x4c, 0x77,
-0x32, 0x3b, 0x4c, 0x77, 0x33, 0x3b, 0x4c, 0x77, 0x34, 0x3b, 0x4c, 0x77, 0x35, 0x3b, 0x4c, 0x77, 0x36, 0x3b, 0x53, 0x61,
-0x62, 0x62, 0x69, 0x69, 0x74, 0x69, 0x3b, 0x42, 0x61, 0x6c, 0x61, 0x7a, 0x61, 0x3b, 0x4c, 0x77, 0x61, 0x6b, 0x75, 0x62,
-0x69, 0x72, 0x69, 0x3b, 0x4c, 0x77, 0x61, 0x6b, 0x75, 0x73, 0x61, 0x74, 0x75, 0x3b, 0x4c, 0x77, 0x61, 0x6b, 0x75, 0x6e,
-0x61, 0x3b, 0x4c, 0x77, 0x61, 0x6b, 0x75, 0x74, 0x61, 0x61, 0x6e, 0x6f, 0x3b, 0x4c, 0x77, 0x61, 0x6d, 0x75, 0x6b, 0x61,
-0x61, 0x67, 0x61, 0x3b, 0x53, 0x3b, 0x42, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x50, 0x61,
-0x20, 0x4d, 0x75, 0x6c, 0x75, 0x6e, 0x67, 0x75, 0x3b, 0x50, 0x61, 0x6c, 0x69, 0x63, 0x68, 0x69, 0x6d, 0x6f, 0x3b, 0x50,
-0x61, 0x6c, 0x69, 0x63, 0x68, 0x69, 0x62, 0x75, 0x6c, 0x69, 0x3b, 0x50, 0x61, 0x6c, 0x69, 0x63, 0x68, 0x69, 0x74, 0x61,
-0x74, 0x75, 0x3b, 0x50, 0x61, 0x6c, 0x69, 0x63, 0x68, 0x69, 0x6e, 0x65, 0x3b, 0x50, 0x61, 0x6c, 0x69, 0x63, 0x68, 0x69,
-0x73, 0x61, 0x6e, 0x6f, 0x3b, 0x50, 0x61, 0x63, 0x68, 0x69, 0x62, 0x65, 0x6c, 0x75, 0x73, 0x68, 0x69, 0x3b, 0x64, 0x75,
-0x6d, 0x3b, 0x73, 0x69, 0x67, 0x3b, 0x74, 0x65, 0x72, 0x3b, 0x6b, 0x75, 0x61, 0x3b, 0x6b, 0x69, 0x6e, 0x3b, 0x73, 0x65,
-0x73, 0x3b, 0x73, 0x61, 0x62, 0x3b, 0x64, 0x75, 0x6d, 0x69, 0x6e, 0x67, 0x75, 0x3b, 0x73, 0x69, 0x67, 0x75, 0x6e, 0x64,
-0x61, 0x2d, 0x66, 0x65, 0x72, 0x61, 0x3b, 0x74, 0x65, 0x72, 0x73, 0x61, 0x2d, 0x66, 0x65, 0x72, 0x61, 0x3b, 0x6b, 0x75,
-0x61, 0x72, 0x74, 0x61, 0x2d, 0x66, 0x65, 0x72, 0x61, 0x3b, 0x6b, 0x69, 0x6e, 0x74, 0x61, 0x2d, 0x66, 0x65, 0x72, 0x61,
-0x3b, 0x73, 0x65, 0x73, 0x74, 0x61, 0x2d, 0x66, 0x65, 0x72, 0x61, 0x3b, 0x73, 0x61, 0x62, 0x61, 0x64, 0x75, 0x3b, 0x64,
-0x3b, 0x73, 0x3b, 0x74, 0x3b, 0x6b, 0x3b, 0x6b, 0x3b, 0x73, 0x3b, 0x73, 0x3b, 0x4b, 0x49, 0x55, 0x3b, 0x4d, 0x52, 0x41,
-0x3b, 0x57, 0x41, 0x49, 0x3b, 0x57, 0x45, 0x54, 0x3b, 0x57, 0x45, 0x4e, 0x3b, 0x57, 0x54, 0x4e, 0x3b, 0x4a, 0x55, 0x4d,
-0x3b, 0x4b, 0x69, 0x75, 0x6d, 0x69, 0x61, 0x3b, 0x4d, 0x75, 0x72, 0x61, 0x6d, 0x75, 0x6b, 0x6f, 0x3b, 0x57, 0x61, 0x69,
-0x72, 0x69, 0x3b, 0x57, 0x65, 0x74, 0x68, 0x61, 0x74, 0x75, 0x3b, 0x57, 0x65, 0x6e, 0x61, 0x3b, 0x57, 0x65, 0x74, 0x61,
-0x6e, 0x6f, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x4b, 0x3b, 0x4d, 0x3b, 0x57, 0x3b, 0x57, 0x3b,
-0x57, 0x3b, 0x57, 0x3b, 0x4a, 0x3b, 0x54, 0x69, 0x73, 0x3b, 0x54, 0x61, 0x69, 0x3b, 0x41, 0x65, 0x6e, 0x3b, 0x53, 0x6f,
-0x6d, 0x3b, 0x41, 0x6e, 0x67, 0x3b, 0x4d, 0x75, 0x74, 0x3b, 0x4c, 0x6f, 0x68, 0x3b, 0x42, 0x65, 0x74, 0x75, 0x74, 0x61,
-0x62, 0x20, 0x74, 0x69, 0x73, 0x61, 0x70, 0x3b, 0x42, 0x65, 0x74, 0x75, 0x74, 0x20, 0x6e, 0x65, 0x74, 0x61, 0x69, 0x3b,
-0x42, 0x65, 0x74, 0x75, 0x74, 0x61, 0x62, 0x20, 0x61, 0x65, 0x6e, 0x67, 0x27, 0x3b, 0x42, 0x65, 0x74, 0x75, 0x74, 0x61,
-0x62, 0x20, 0x73, 0x6f, 0x6d, 0x6f, 0x6b, 0x3b, 0x42, 0x65, 0x74, 0x75, 0x74, 0x61, 0x62, 0x20, 0x61, 0x6e, 0x67, 0x27,
-0x77, 0x61, 0x6e, 0x3b, 0x42, 0x65, 0x74, 0x75, 0x74, 0x61, 0x62, 0x20, 0x6d, 0x75, 0x74, 0x3b, 0x42, 0x65, 0x74, 0x75,
-0x74, 0x61, 0x62, 0x20, 0x6c, 0x6f, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4c,
-0x3b, 0x53, 0x6f, 0x6e, 0x3b, 0x4d, 0x61, 0x3b, 0x44, 0x65, 0x3b, 0x57, 0x75, 0x3b, 0x44, 0x6f, 0x3b, 0x46, 0x72, 0x3b,
-0x53, 0x61, 0x74, 0x3b, 0x53, 0x6f, 0x6e, 0x74, 0x61, 0x78, 0x74, 0x73, 0x65, 0x65, 0x73, 0x3b, 0x4d, 0x61, 0x6e, 0x74,
-0x61, 0x78, 0x74, 0x73, 0x65, 0x65, 0x73, 0x3b, 0x44, 0x65, 0x6e, 0x73, 0x74, 0x61, 0x78, 0x74, 0x73, 0x65, 0x65, 0x73,
-0x3b, 0x57, 0x75, 0x6e, 0x73, 0x74, 0x61, 0x78, 0x74, 0x73, 0x65, 0x65, 0x73, 0x3b, 0x44, 0x6f, 0x6e, 0x64, 0x65, 0x72,
-0x74, 0x61, 0x78, 0x74, 0x73, 0x65, 0x65, 0x73, 0x3b, 0x46, 0x72, 0x61, 0x69, 0x74, 0x61, 0x78, 0x74, 0x73, 0x65, 0x65,
-0x73, 0x3b, 0x53, 0x61, 0x74, 0x65, 0x72, 0x74, 0x61, 0x78, 0x74, 0x73, 0x65, 0x65, 0x73, 0x3b, 0x53, 0x3b, 0x4d, 0x3b,
-0x45, 0x3b, 0x57, 0x3b, 0x44, 0x3b, 0x46, 0x3b, 0x41, 0x3b, 0x53, 0x75, 0x2e, 0x3b, 0x4d, 0x6f, 0x2e, 0x3b, 0x44, 0x69,
-0x2e, 0x3b, 0x4d, 0x65, 0x2e, 0x3b, 0x44, 0x75, 0x2e, 0x3b, 0x46, 0x72, 0x2e, 0x3b, 0x53, 0x61, 0x2e, 0x3b, 0x53, 0x75,
-0x6e, 0x6e, 0x64, 0x61, 0x61, 0x63, 0x68, 0x3b, 0x4d, 0x6f, 0x6f, 0x6e, 0x64, 0x61, 0x61, 0x63, 0x68, 0x3b, 0x44, 0x69,
-0x6e, 0x6e, 0x73, 0x64, 0x61, 0x61, 0x63, 0x68, 0x3b, 0x4d, 0x65, 0x74, 0x77, 0x6f, 0x63, 0x68, 0x3b, 0x44, 0x75, 0x6e,
-0x6e, 0x65, 0x72, 0x73, 0x64, 0x61, 0x61, 0x63, 0x68, 0x3b, 0x46, 0x72, 0x69, 0x69, 0x64, 0x61, 0x61, 0x63, 0x68, 0x3b,
-0x53, 0x61, 0x6d, 0x73, 0x64, 0x61, 0x61, 0x63, 0x68, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x70, 0xed, 0x6c, 0xed, 0x3b, 0x4a,
-0x75, 0x6d, 0x61, 0x74, 0xe1, 0x74, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74,
-0xe1, 0x6e, 0x254, 0x3b, 0x41, 0x6c, 0x61, 0xe1, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x4a, 0x75, 0x6d, 0xe1, 0x61, 0x3b, 0x4a,
-0x75, 0x6d, 0x61, 0x6d, 0xf3, 0x73, 0x69, 0x3b, 0x53, 0x61, 0x62, 0x69, 0x3b, 0x42, 0x61, 0x6c, 0x61, 0x3b, 0x4b, 0x75,
-0x62, 0x69, 0x3b, 0x4b, 0x75, 0x73, 0x61, 0x3b, 0x4b, 0x75, 0x6e, 0x61, 0x3b, 0x4b, 0x75, 0x74, 0x61, 0x3b, 0x4d, 0x75,
-0x6b, 0x61, 0x3b, 0x53, 0x61, 0x62, 0x69, 0x69, 0x74, 0x69, 0x3b, 0x42, 0x61, 0x6c, 0x61, 0x7a, 0x61, 0x3b, 0x4f, 0x77,
-0x6f, 0x6b, 0x75, 0x62, 0x69, 0x6c, 0x69, 0x3b, 0x4f, 0x77, 0x6f, 0x6b, 0x75, 0x73, 0x61, 0x74, 0x75, 0x3b, 0x4f, 0x6c,
-0x6f, 0x6b, 0x75, 0x6e, 0x61, 0x3b, 0x4f, 0x6c, 0x6f, 0x6b, 0x75, 0x74, 0x61, 0x61, 0x6e, 0x75, 0x3b, 0x4f, 0x6c, 0x6f,
-0x6d, 0x75, 0x6b, 0x61, 0x61, 0x67, 0x61, 0x3b, 0x53, 0x3b, 0x42, 0x3b, 0x42, 0x3b, 0x53, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b,
-0x4d, 0x3b, 0x4a, 0x32, 0x3b, 0x4a, 0x33, 0x3b, 0x4a, 0x34, 0x3b, 0x4a, 0x35, 0x3b, 0x41, 0x6c, 0x3b, 0x49, 0x6a, 0x3b,
-0x4a, 0x31, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x70, 0x69, 0x72, 0x69, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x75,
-0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6e, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x4d, 0x75,
-0x72, 0x77, 0x61, 0x20, 0x77, 0x61, 0x20, 0x4b, 0x61, 0x6e, 0x6e, 0x65, 0x3b, 0x4d, 0x75, 0x72, 0x77, 0x61, 0x20, 0x77,
-0x61, 0x20, 0x4b, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x4a, 0x70,
-0x69, 0x3b, 0x4a, 0x74, 0x74, 0x3b, 0x4a, 0x6e, 0x6e, 0x3b, 0x4a, 0x74, 0x6e, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x49, 0x6a,
-0x6d, 0x3b, 0x4a, 0x6d, 0x6f, 0x3b, 0x4a, 0x75, 0x6d, 0x3b, 0x42, 0x61, 0x72, 0x3b, 0x41, 0x61, 0x72, 0x3b, 0x55, 0x6e,
-0x69, 0x3b, 0x55, 0x6e, 0x67, 0x3b, 0x4b, 0x61, 0x6e, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x4e, 0x61, 0x6b, 0x61, 0x65, 0x6a,
-0x75, 0x6d, 0x61, 0x3b, 0x4e, 0x61, 0x6b, 0x61, 0x65, 0x62, 0x61, 0x72, 0x61, 0x73, 0x61, 0x3b, 0x4e, 0x61, 0x6b, 0x61,
-0x61, 0x72, 0x65, 0x3b, 0x4e, 0x61, 0x6b, 0x61, 0x75, 0x6e, 0x69, 0x3b, 0x4e, 0x61, 0x6b, 0x61, 0x75, 0x6e, 0x67, 0x27,
-0x6f, 0x6e, 0x3b, 0x4e, 0x61, 0x6b, 0x61, 0x6b, 0x61, 0x6e, 0x79, 0x3b, 0x4e, 0x61, 0x6b, 0x61, 0x73, 0x61, 0x62, 0x69,
-0x74, 0x69, 0x3b, 0x4a, 0x3b, 0x42, 0x3b, 0x41, 0x3b, 0x55, 0x3b, 0x55, 0x3b, 0x4b, 0x3b, 0x53, 0x3b, 0x4e, 0x61, 0x62,
-0x3b, 0x53, 0x61, 0x6e, 0x3b, 0x53, 0x61, 0x6c, 0x3b, 0x52, 0x61, 0x62, 0x3b, 0x43, 0x61, 0x6d, 0x3b, 0x4a, 0x75, 0x6d,
-0x3b, 0x51, 0x75, 0x6e, 0x3b, 0x4e, 0x61, 0x62, 0x61, 0x20, 0x53, 0x61, 0x6d, 0x62, 0x61, 0x74, 0x3b, 0x53, 0x61, 0x6e,
-0x69, 0x3b, 0x53, 0x61, 0x6c, 0x75, 0x73, 0x3b, 0x52, 0x61, 0x62, 0x75, 0x71, 0x3b, 0x43, 0x61, 0x6d, 0x75, 0x73, 0x3b,
-0x4a, 0x75, 0x6d, 0x71, 0x61, 0x74, 0x61, 0x3b, 0x51, 0x75, 0x6e, 0x78, 0x61, 0x20, 0x53, 0x61, 0x6d, 0x62, 0x61, 0x74,
-0x3b, 0x4e, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x52, 0x3b, 0x43, 0x3b, 0x4a, 0x3b, 0x51, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x41,
-0x74, 0x69, 0x3b, 0x41, 0x74, 0x61, 0x3b, 0x41, 0x6c, 0x61, 0x3b, 0x41, 0x6c, 0x6d, 0x3b, 0x41, 0x6c, 0x6a, 0x3b, 0x41,
-0x73, 0x73, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x64, 0x69, 0x3b, 0x41, 0x74, 0x69, 0x6e, 0x69, 0x3b, 0x41, 0x74, 0x61, 0x6c,
-0x61, 0x74, 0x61, 0x3b, 0x41, 0x6c, 0x61, 0x72, 0x62, 0x61, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x69, 0x73, 0x61,
-0x3b, 0x41, 0x6c, 0x6a, 0x75, 0x6d, 0x61, 0x3b, 0x41, 0x73, 0x73, 0x61, 0x62, 0x64, 0x75, 0x3b, 0x48, 0x3b, 0x54, 0x3b,
-0x54, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x53, 0x3b, 0x4a, 0x4d, 0x50, 0x3b, 0x57, 0x55, 0x54, 0x3b, 0x54, 0x41,
-0x52, 0x3b, 0x54, 0x41, 0x44, 0x3b, 0x54, 0x41, 0x4e, 0x3b, 0x54, 0x41, 0x42, 0x3b, 0x4e, 0x47, 0x53, 0x3b, 0x4a, 0x75,
-0x6d, 0x61, 0x70, 0x69, 0x6c, 0x3b, 0x57, 0x75, 0x6f, 0x6b, 0x20, 0x54, 0x69, 0x63, 0x68, 0x3b, 0x54, 0x69, 0x63, 0x68,
-0x20, 0x41, 0x72, 0x69, 0x79, 0x6f, 0x3b, 0x54, 0x69, 0x63, 0x68, 0x20, 0x41, 0x64, 0x65, 0x6b, 0x3b, 0x54, 0x69, 0x63,
-0x68, 0x20, 0x41, 0x6e, 0x67, 0x27, 0x77, 0x65, 0x6e, 0x3b, 0x54, 0x69, 0x63, 0x68, 0x20, 0x41, 0x62, 0x69, 0x63, 0x68,
-0x3b, 0x4e, 0x67, 0x65, 0x73, 0x6f, 0x3b, 0x4a, 0x3b, 0x57, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x4e,
-0x3b, 0x41, 0x73, 0x61, 0x3b, 0x41, 0x79, 0x6e, 0x3b, 0x41, 0x73, 0x6e, 0x3b, 0x41, 0x6b, 0x72, 0x3b, 0x41, 0x6b, 0x77,
-0x3b, 0x41, 0x73, 0x6d, 0x3b, 0x41, 0x73, 0x1e0d, 0x3b, 0x41, 0x73, 0x61, 0x6d, 0x61, 0x73, 0x3b, 0x41, 0x79, 0x6e, 0x61,
-0x73, 0x3b, 0x41, 0x73, 0x69, 0x6e, 0x61, 0x73, 0x3b, 0x41, 0x6b, 0x72, 0x61, 0x73, 0x3b, 0x41, 0x6b, 0x77, 0x61, 0x73,
-0x3b, 0x41, 0x73, 0x69, 0x6d, 0x77, 0x61, 0x73, 0x3b, 0x41, 0x73, 0x69, 0x1e0d, 0x79, 0x61, 0x73, 0x3b, 0x41, 0x3b, 0x41,
-0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x41, 0x74, 0x69, 0x3b, 0x41,
-0x74, 0x61, 0x3b, 0x41, 0x6c, 0x61, 0x3b, 0x41, 0x6c, 0x6d, 0x3b, 0x41, 0x6c, 0x7a, 0x3b, 0x41, 0x73, 0x69, 0x3b, 0x41,
-0x6c, 0x68, 0x61, 0x64, 0x69, 0x3b, 0x41, 0x74, 0x69, 0x6e, 0x6e, 0x69, 0x3b, 0x41, 0x74, 0x61, 0x6c, 0x61, 0x61, 0x74,
-0x61, 0x3b, 0x41, 0x6c, 0x61, 0x72, 0x62, 0x61, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x69, 0x73, 0x61, 0x3b, 0x41,
-0x6c, 0x7a, 0x75, 0x6d, 0x61, 0x3b, 0x41, 0x73, 0x69, 0x62, 0x74, 0x69, 0x3b, 0x4a, 0x70, 0x69, 0x3b, 0x4a, 0x74, 0x74,
-0x3b, 0x4a, 0x6d, 0x6e, 0x3b, 0x4a, 0x74, 0x6e, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x49, 0x6a, 0x75, 0x3b, 0x4a, 0x6d, 0x6f,
-0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x61, 0x70, 0x69, 0x69, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b,
-0x4a, 0x75, 0x6d, 0x61, 0x61, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x6c,
-0x68, 0x61, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x61, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x61, 0x6d,
-0x6f, 0x73, 0x69, 0x3b, 0x930, 0x92c, 0x93f, 0x3b, 0x938, 0x92e, 0x3b, 0x92e, 0x902, 0x917, 0x932, 0x3b, 0x92c, 0x941, 0x926, 0x3b,
-0x92c, 0x93f, 0x938, 0x925, 0x93f, 0x3b, 0x938, 0x941, 0x916, 0x941, 0x930, 0x3b, 0x938, 0x941, 0x928, 0x93f, 0x3b, 0x930, 0x92c, 0x93f,
-0x92c, 0x93e, 0x930, 0x3b, 0x938, 0x92e, 0x92c, 0x93e, 0x930, 0x3b, 0x92e, 0x902, 0x917, 0x932, 0x92c, 0x93e, 0x930, 0x3b, 0x92c, 0x941,
-0x926, 0x92c, 0x93e, 0x930, 0x3b, 0x92c, 0x93f, 0x938, 0x925, 0x93f, 0x92c, 0x93e, 0x930, 0x3b, 0x938, 0x941, 0x916, 0x941, 0x930, 0x92c,
-0x93e, 0x930, 0x3b, 0x938, 0x941, 0x928, 0x93f, 0x92c, 0x93e, 0x930, 0x3b, 0x930, 0x3b, 0x938, 0x3b, 0x92e, 0x902, 0x3b, 0x92c, 0x941,
-0x3b, 0x92c, 0x93f, 0x3b, 0x938, 0x941, 0x3b, 0x938, 0x941, 0x3b, 0x4c, 0x75, 0x6d, 0x3b, 0x4e, 0x6b, 0x6f, 0x3b, 0x4e, 0x64,
-0x79, 0x3b, 0x4e, 0x64, 0x67, 0x3b, 0x4e, 0x6a, 0x77, 0x3b, 0x4e, 0x67, 0x76, 0x3b, 0x4c, 0x75, 0x62, 0x3b, 0x4c, 0x75,
-0x6d, 0x69, 0x6e, 0x67, 0x75, 0x3b, 0x4e, 0x6b, 0x6f, 0x64, 0x79, 0x61, 0x3b, 0x4e, 0x64, 0xe0, 0x61, 0x79, 0xe0, 0x3b,
-0x4e, 0x64, 0x61, 0x6e, 0x67, 0xf9, 0x3b, 0x4e, 0x6a, 0xf2, 0x77, 0x61, 0x3b, 0x4e, 0x67, 0xf2, 0x76, 0x79, 0x61, 0x3b,
-0x4c, 0x75, 0x62, 0x69, 0x6e, 0x67, 0x75, 0x3b, 0x4c, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b,
-0x4c, 0x3b, 0x6e, 0x74, 0x73, 0x3b, 0x6b, 0x70, 0x61, 0x3b, 0x67, 0x68, 0x254, 0x3b, 0x74, 0x254, 0x6d, 0x3b, 0x75, 0x6d,
-0x65, 0x3b, 0x67, 0x68, 0x268, 0x3b, 0x64, 0x7a, 0x6b, 0x3b, 0x74, 0x73, 0x75, 0x294, 0x6e, 0x74, 0x73, 0x268, 0x3b, 0x74,
-0x73, 0x75, 0x294, 0x75, 0x6b, 0x70, 0xe0, 0x3b, 0x74, 0x73, 0x75, 0x294, 0x75, 0x67, 0x68, 0x254, 0x65, 0x3b, 0x74, 0x73,
-0x75, 0x294, 0x75, 0x74, 0x254, 0x300, 0x6d, 0x6c, 0xf2, 0x3b, 0x74, 0x73, 0x75, 0x294, 0x75, 0x6d, 0xe8, 0x3b, 0x74, 0x73,
-0x75, 0x294, 0x75, 0x67, 0x68, 0x268, 0x302, 0x6d, 0x3b, 0x74, 0x73, 0x75, 0x294, 0x6e, 0x64, 0x7a, 0x268, 0x6b, 0x254, 0x294,
-0x254, 0x3b, 0x6e, 0x3b, 0x6b, 0x3b, 0x67, 0x3b, 0x74, 0x3b, 0x75, 0x3b, 0x67, 0x3b, 0x64, 0x3b, 0x6e, 0x254, 0x79, 0x3b,
-0x6e, 0x6a, 0x61, 0x3b, 0x75, 0x75, 0x6d, 0x3b, 0x14b, 0x67, 0x65, 0x3b, 0x6d, 0x62, 0x254, 0x3b, 0x6b, 0x254, 0x254, 0x3b,
-0x6a, 0x6f, 0x6e, 0x3b, 0x14b, 0x67, 0x77, 0xe0, 0x20, 0x6e, 0x254, 0x302, 0x79, 0x3b, 0x14b, 0x67, 0x77, 0xe0, 0x20, 0x6e,
-0x6a, 0x61, 0x14b, 0x67, 0x75, 0x6d, 0x62, 0x61, 0x3b, 0x14b, 0x67, 0x77, 0xe0, 0x20, 0xfb, 0x6d, 0x3b, 0x14b, 0x67, 0x77,
-0xe0, 0x20, 0x14b, 0x67, 0xea, 0x3b, 0x14b, 0x67, 0x77, 0xe0, 0x20, 0x6d, 0x62, 0x254, 0x6b, 0x3b, 0x14b, 0x67, 0x77, 0xe0,
-0x20, 0x6b, 0x254, 0x254, 0x3b, 0x14b, 0x67, 0x77, 0xe0, 0x20, 0x6a, 0xf4, 0x6e, 0x3b, 0x6e, 0x3b, 0x6e, 0x3b, 0x75, 0x3b,
-0x14b, 0x3b, 0x6d, 0x3b, 0x6b, 0x3b, 0x6a, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x64, 0x69, 0x3b, 0x41, 0x74, 0x69, 0x6e, 0x6e,
-0x69, 0x3b, 0x41, 0x74, 0x61, 0x6c, 0x61, 0x61, 0x74, 0x61, 0x3b, 0x41, 0x6c, 0x61, 0x72, 0x62, 0x61, 0x3b, 0x41, 0x6c,
-0x68, 0x61, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x41, 0x6c, 0x7a, 0x75, 0x6d, 0x61, 0x3b, 0x41, 0x73, 0x69, 0x62, 0x74, 0x69,
-0x3b, 0x48, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x5a, 0x3b, 0x53, 0x3b, 0xe9, 0x74, 0x3b, 0x6d, 0x254,
-0x301, 0x73, 0x3b, 0x6b, 0x77, 0x61, 0x3b, 0x6d, 0x75, 0x6b, 0x3b, 0x14b, 0x67, 0x69, 0x3b, 0x257, 0xf3, 0x6e, 0x3b, 0x65,
-0x73, 0x61, 0x3b, 0xe9, 0x74, 0x69, 0x3b, 0x6d, 0x254, 0x301, 0x73, 0xfa, 0x3b, 0x6b, 0x77, 0x61, 0x73, 0xfa, 0x3b, 0x6d,
-0x75, 0x6b, 0x254, 0x301, 0x73, 0xfa, 0x3b, 0x14b, 0x67, 0x69, 0x73, 0xfa, 0x3b, 0x257, 0xf3, 0x6e, 0x25b, 0x73, 0xfa, 0x3b,
-0x65, 0x73, 0x61, 0x253, 0x61, 0x73, 0xfa, 0x3b, 0x65, 0x3b, 0x6d, 0x3b, 0x6b, 0x3b, 0x6d, 0x3b, 0x14b, 0x3b, 0x257, 0x3b,
-0x65, 0x3b, 0x44, 0x69, 0x6d, 0x3b, 0x54, 0x65, 0x6e, 0x3b, 0x54, 0x61, 0x6c, 0x3b, 0x41, 0x6c, 0x61, 0x3b, 0x41, 0x72,
-0x61, 0x3b, 0x41, 0x72, 0x6a, 0x3b, 0x53, 0x69, 0x62, 0x3b, 0x44, 0x69, 0x6d, 0x61, 0x73, 0x3b, 0x54, 0x65, 0x6e, 0x65,
-0x14b, 0x3b, 0x54, 0x61, 0x6c, 0x61, 0x74, 0x61, 0x3b, 0x41, 0x6c, 0x61, 0x72, 0x62, 0x61, 0x79, 0x3b, 0x41, 0x72, 0x61,
-0x6d, 0x69, 0x73, 0x61, 0x79, 0x3b, 0x41, 0x72, 0x6a, 0x75, 0x6d, 0x61, 0x3b, 0x53, 0x69, 0x62, 0x69, 0x74, 0x69, 0x3b,
-0x44, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x3b, 0x6d,
-0x254, 0x301, 0x6e, 0x3b, 0x73, 0x6d, 0x62, 0x3b, 0x73, 0x6d, 0x6c, 0x3b, 0x73, 0x6d, 0x6e, 0x3b, 0x66, 0xfa, 0x6c, 0x3b,
-0x73, 0xe9, 0x72, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x3b, 0x6d, 0x254, 0x301, 0x6e, 0x64, 0x69, 0x3b, 0x73, 0x254,
-0x301, 0x6e, 0x64, 0x254, 0x20, 0x6d, 0x259, 0x6c, 0xfa, 0x20, 0x6d, 0x259, 0x301, 0x62, 0x25b, 0x30c, 0x3b, 0x73, 0x254, 0x301,
-0x6e, 0x64, 0x254, 0x20, 0x6d, 0x259, 0x6c, 0xfa, 0x20, 0x6d, 0x259, 0x301, 0x6c, 0x25b, 0x301, 0x3b, 0x73, 0x254, 0x301, 0x6e,
-0x64, 0x254, 0x20, 0x6d, 0x259, 0x6c, 0xfa, 0x20, 0x6d, 0x259, 0x301, 0x6e, 0x79, 0x69, 0x3b, 0x66, 0xfa, 0x6c, 0x61, 0x64,
-0xe9, 0x3b, 0x73, 0xe9, 0x72, 0x61, 0x64, 0xe9, 0x3b, 0x73, 0x3b, 0x6d, 0x3b, 0x73, 0x3b, 0x73, 0x3b, 0x73, 0x3b, 0x66,
-0x3b, 0x73, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x3b, 0x6c, 0x1dd, 0x6e, 0x3b, 0x6d, 0x61, 0x61, 0x3b, 0x6d, 0x25b, 0x6b, 0x3b,
-0x6a, 0x1dd, 0x1dd, 0x3b, 0x6a, 0xfa, 0x6d, 0x3b, 0x73, 0x61, 0x6d, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x1dd, 0x3b, 0x6c,
-0x1dd, 0x6e, 0x64, 0xed, 0x3b, 0x6d, 0x61, 0x61, 0x64, 0xed, 0x3b, 0x6d, 0x25b, 0x6b, 0x72, 0x25b, 0x64, 0xed, 0x3b, 0x6a,
-0x1dd, 0x1dd, 0x64, 0xed, 0x3b, 0x6a, 0xfa, 0x6d, 0x62, 0xe1, 0x3b, 0x73, 0x61, 0x6d, 0x64, 0xed, 0x3b, 0x73, 0x3b, 0x6c,
-0x3b, 0x6d, 0x3b, 0x6d, 0x3b, 0x6a, 0x3b, 0x6a, 0x3b, 0x73, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x4a, 0x74, 0x74, 0x3b, 0x4a,
-0x6e, 0x6e, 0x3b, 0x4a, 0x74, 0x6e, 0x3b, 0x41, 0x72, 0x61, 0x3b, 0x49, 0x6a, 0x75, 0x3b, 0x4a, 0x6d, 0x6f, 0x3b, 0x53,
-0x61, 0x62, 0x61, 0x74, 0x6f, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6e,
-0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x72, 0x61, 0x68, 0x61, 0x6d, 0x69, 0x73,
-0x69, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x61, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x53, 0x3b,
-0x4a, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x4a, 0x3b, 0x43, 0x79, 0x61, 0x3b, 0x43, 0x6c, 0x61, 0x3b,
-0x43, 0x7a, 0x69, 0x3b, 0x43, 0x6b, 0x6f, 0x3b, 0x43, 0x6b, 0x61, 0x3b, 0x43, 0x67, 0x61, 0x3b, 0x43, 0x7a, 0x65, 0x3b,
-0x43, 0x6f, 0x6d, 0x27, 0x79, 0x61, 0x6b, 0x6b, 0x65, 0x3b, 0x43, 0x6f, 0x6d, 0x6c, 0x61, 0x61, 0x257, 0x69, 0x69, 0x3b,
-0x43, 0x6f, 0x6d, 0x7a, 0x79, 0x69, 0x69, 0x257, 0x69, 0x69, 0x3b, 0x43, 0x6f, 0x6d, 0x6b, 0x6f, 0x6c, 0x6c, 0x65, 0x3b,
-0x43, 0x6f, 0x6d, 0x6b, 0x61, 0x6c, 0x64, 0x1dd, 0x253, 0x6c, 0x69, 0x69, 0x3b, 0x43, 0x6f, 0x6d, 0x67, 0x61, 0x69, 0x73,
-0x75, 0x75, 0x3b, 0x43, 0x6f, 0x6d, 0x7a, 0x79, 0x65, 0x253, 0x73, 0x75, 0x75, 0x3b, 0x59, 0x3b, 0x4c, 0x3b, 0x5a, 0x3b,
-0x4f, 0x3b, 0x41, 0x3b, 0x47, 0x3b, 0x45, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x3b, 0x6d, 0x254, 0x301, 0x6e, 0x3b, 0x73, 0x6d,
-0x62, 0x3b, 0x73, 0x6d, 0x6c, 0x3b, 0x73, 0x6d, 0x6e, 0x3b, 0x6d, 0x62, 0x73, 0x3b, 0x73, 0x61, 0x73, 0x3b, 0x73, 0x254,
-0x301, 0x6e, 0x64, 0x254, 0x3b, 0x6d, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x20, 0x6d,
-0x61, 0x66, 0xfa, 0x20, 0x6d, 0xe1, 0x62, 0x61, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x20, 0x6d, 0x61, 0x66, 0xfa,
-0x20, 0x6d, 0xe1, 0x6c, 0x61, 0x6c, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x20, 0x6d, 0x61, 0x66, 0xfa, 0x20, 0x6d,
-0xe1, 0x6e, 0x61, 0x3b, 0x6d, 0x61, 0x62, 0xe1, 0x67, 0xe1, 0x20, 0x6d, 0xe1, 0x20, 0x73, 0x75, 0x6b, 0x75, 0x6c, 0x3b,
-0x73, 0xe1, 0x73, 0x61, 0x64, 0x69, 0x3b, 0x73, 0x3b, 0x6d, 0x3b, 0x73, 0x3b, 0x73, 0x3b, 0x73, 0x3b, 0x6d, 0x3b, 0x73,
-0x3b, 0x43, 0xe4, 0x14b, 0x3b, 0x4a, 0x69, 0x65, 0x63, 0x3b, 0x52, 0x25b, 0x77, 0x3b, 0x44, 0x69, 0x254, 0x331, 0x6b, 0x3b,
-0x14a, 0x75, 0x61, 0x61, 0x6e, 0x3b, 0x44, 0x68, 0x69, 0x65, 0x65, 0x63, 0x3b, 0x42, 0xe4, 0x6b, 0x25b, 0x6c, 0x3b, 0x43,
-0xe4, 0x14b, 0x20, 0x6b, 0x75, 0x254, 0x74, 0x68, 0x3b, 0x4a, 0x69, 0x65, 0x63, 0x20, 0x6c, 0x61, 0x331, 0x74, 0x3b, 0x52,
-0x25b, 0x77, 0x20, 0x6c, 0xe4, 0x74, 0x6e, 0x69, 0x3b, 0x44, 0x69, 0x254, 0x331, 0x6b, 0x20, 0x6c, 0xe4, 0x74, 0x6e, 0x69,
-0x3b, 0x14a, 0x75, 0x61, 0x61, 0x6e, 0x20, 0x6c, 0xe4, 0x74, 0x6e, 0x69, 0x3b, 0x44, 0x68, 0x69, 0x65, 0x65, 0x63, 0x20,
-0x6c, 0xe4, 0x74, 0x6e, 0x69, 0x3b, 0x42, 0xe4, 0x6b, 0x25b, 0x6c, 0x20, 0x6c, 0xe4, 0x74, 0x6e, 0x69, 0x3b, 0x43, 0x3b,
-0x4a, 0x3b, 0x52, 0x3b, 0x44, 0x3b, 0x14a, 0x3b, 0x44, 0x3b, 0x42, 0x3b, 0x411, 0x441, 0x3b, 0x411, 0x43d, 0x3b, 0x41e, 0x43f,
-0x3b, 0x421, 0x44d, 0x3b, 0x427, 0x43f, 0x3b, 0x411, 0x44d, 0x3b, 0x421, 0x431, 0x3b, 0x411, 0x430, 0x441, 0x43a, 0x44b, 0x4bb, 0x44b,
-0x430, 0x43d, 0x43d, 0x44c, 0x430, 0x3b, 0x411, 0x44d, 0x43d, 0x438, 0x434, 0x438, 0x44d, 0x43b, 0x438, 0x43d, 0x43d, 0x44c, 0x438, 0x43a,
-0x3b, 0x41e, 0x43f, 0x442, 0x443, 0x43e, 0x440, 0x443, 0x43d, 0x43d, 0x44c, 0x443, 0x43a, 0x3b, 0x421, 0x44d, 0x440, 0x44d, 0x434, 0x44d,
-0x3b, 0x427, 0x44d, 0x43f, 0x43f, 0x438, 0x44d, 0x440, 0x3b, 0x411, 0x44d, 0x44d, 0x442, 0x438, 0x4a5, 0x441, 0x44d, 0x3b, 0x421, 0x443,
-0x431, 0x443, 0x43e, 0x442, 0x430, 0x3b, 0x411, 0x3b, 0x411, 0x3b, 0x41e, 0x3b, 0x421, 0x3b, 0x427, 0x3b, 0x411, 0x3b, 0x421, 0x3b,
-0x4d, 0x75, 0x6c, 0x3b, 0x4a, 0x74, 0x74, 0x3b, 0x4a, 0x6e, 0x6e, 0x3b, 0x4a, 0x74, 0x6e, 0x3b, 0x41, 0x6c, 0x68, 0x3b,
-0x49, 0x6a, 0x75, 0x3b, 0x4a, 0x6d, 0x6f, 0x3b, 0x4d, 0x75, 0x6c, 0x75, 0x6e, 0x67, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61,
-0x74, 0x61, 0x74, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6e, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e,
-0x6f, 0x3b, 0x41, 0x6c, 0x61, 0x68, 0x61, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x61, 0x3b, 0x4a,
-0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x41, 0x3b, 0x49, 0x3b,
-0x4a, 0x3b, 0x79, 0x65, 0x6e, 0x3b, 0x6b, 0x77, 0x61, 0x3b, 0x70, 0x69, 0x6c, 0x3b, 0x74, 0x61, 0x74, 0x3b, 0x69, 0x6e,
-0x65, 0x3b, 0x74, 0x61, 0x6e, 0x3b, 0x73, 0x69, 0x74, 0x3b, 0x73, 0x69, 0x6b, 0x75, 0x20, 0x79, 0x61, 0x20, 0x79, 0x65,
-0x6e, 0x67, 0x61, 0x3b, 0x73, 0x69, 0x6b, 0x75, 0x20, 0x79, 0x61, 0x20, 0x6b, 0x77, 0x61, 0x6e, 0x7a, 0x61, 0x3b, 0x73,
-0x69, 0x6b, 0x75, 0x20, 0x79, 0x61, 0x20, 0x70, 0x69, 0x6c, 0x69, 0x3b, 0x73, 0x69, 0x6b, 0x75, 0x20, 0x79, 0x61, 0x20,
-0x74, 0x61, 0x74, 0x75, 0x3b, 0x73, 0x69, 0x6b, 0x75, 0x20, 0x79, 0x61, 0x20, 0x69, 0x6e, 0x65, 0x3b, 0x73, 0x69, 0x6b,
-0x75, 0x20, 0x79, 0x61, 0x20, 0x74, 0x61, 0x6e, 0x75, 0x3b, 0x73, 0x69, 0x6b, 0x75, 0x20, 0x79, 0x61, 0x20, 0x73, 0x69,
-0x74, 0x61, 0x3b, 0x79, 0x3b, 0x6b, 0x3b, 0x70, 0x3b, 0x74, 0x3b, 0x69, 0x3b, 0x74, 0x3b, 0x73, 0x3b, 0xa55e, 0xa54c, 0xa535,
-0x3b, 0xa5f3, 0xa5e1, 0xa609, 0x3b, 0xa55a, 0xa55e, 0xa55a, 0x3b, 0xa549, 0xa55e, 0xa552, 0x3b, 0xa549, 0xa524, 0xa546, 0xa562, 0x3b, 0xa549, 0xa524,
-0xa540, 0xa56e, 0x3b, 0xa53b, 0xa52c, 0xa533, 0x3b, 0x6c, 0x61, 0x68, 0x61, 0x64, 0x69, 0x3b, 0x74, 0x25b, 0x25b, 0x6e, 0x25b, 0x25b,
-0x3b, 0x74, 0x61, 0x6c, 0x61, 0x74, 0x61, 0x3b, 0x61, 0x6c, 0x61, 0x62, 0x61, 0x3b, 0x61, 0x69, 0x6d, 0x69, 0x73, 0x61,
-0x3b, 0x61, 0x69, 0x6a, 0x69, 0x6d, 0x61, 0x3b, 0x73, 0x69, 0x253, 0x69, 0x74, 0x69, 0x3b, 0x53, 0x75, 0x6e, 0x3b, 0x4d,
-0xe4, 0x6e, 0x3b, 0x5a, 0x69, 0x161, 0x3b, 0x4d, 0x69, 0x74, 0x3b, 0x46, 0x72, 0xf3, 0x3b, 0x46, 0x72, 0x69, 0x3b, 0x53,
-0x61, 0x6d, 0x3b, 0x53, 0x75, 0x6e, 0x6e, 0x74, 0x61, 0x67, 0x3b, 0x4d, 0xe4, 0x6e, 0x74, 0x61, 0x67, 0x3b, 0x5a, 0x69,
-0x161, 0x74, 0x61, 0x67, 0x3b, 0x4d, 0x69, 0x74, 0x74, 0x77, 0x75, 0x10d, 0x3b, 0x46, 0x72, 0xf3, 0x6e, 0x74, 0x61, 0x67,
-0x3b, 0x46, 0x72, 0x69, 0x74, 0x61, 0x67, 0x3b, 0x53, 0x61, 0x6d, 0x161, 0x74, 0x61, 0x67, 0x3b, 0x53, 0x3b, 0x4d, 0x3b,
-0x5a, 0x3b, 0x4d, 0x3b, 0x46, 0x3b, 0x46, 0x3b, 0x53, 0x3b, 0x73, 0x64, 0x3b, 0x6d, 0x64, 0x3b, 0x6d, 0x77, 0x3b, 0x65,
-0x74, 0x3b, 0x6b, 0x6c, 0x3b, 0x66, 0x6c, 0x3b, 0x73, 0x73, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x69, 0x25b, 0x3b, 0x6d,
-0xf3, 0x6e, 0x64, 0x69, 0x65, 0x3b, 0x6d, 0x75, 0xe1, 0x6e, 0x79, 0xe1, 0x14b, 0x6d, 0xf3, 0x6e, 0x64, 0x69, 0x65, 0x3b,
-0x6d, 0x65, 0x74, 0xfa, 0x6b, 0x70, 0xed, 0xe1, 0x70, 0x25b, 0x3b, 0x6b, 0xfa, 0x70, 0xe9, 0x6c, 0x69, 0x6d, 0x65, 0x74,
-0xfa, 0x6b, 0x70, 0x69, 0x61, 0x70, 0x25b, 0x3b, 0x66, 0x65, 0x6c, 0xe9, 0x74, 0x65, 0x3b, 0x73, 0xe9, 0x73, 0x65, 0x6c,
-0xe9, 0x3b, 0x73, 0x3b, 0x6d, 0x3b, 0x6d, 0x3b, 0x65, 0x3b, 0x6b, 0x3b, 0x66, 0x3b, 0x73, 0x3b, 0x64, 0x6f, 0x6d, 0x3b,
-0x6c, 0x6c, 0x75, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x6d, 0x69, 0x65, 0x3b, 0x78, 0x75, 0x65, 0x3b, 0x76, 0x69, 0x65, 0x3b,
-0x73, 0x61, 0x62, 0x3b, 0x64, 0x6f, 0x6d, 0x69, 0x6e, 0x67, 0x75, 0x3b, 0x6c, 0x6c, 0x75, 0x6e, 0x65, 0x73, 0x3b, 0x6d,
-0x61, 0x72, 0x74, 0x65, 0x73, 0x3b, 0x6d, 0x69, 0xe9, 0x72, 0x63, 0x6f, 0x6c, 0x65, 0x73, 0x3b, 0x78, 0x75, 0x65, 0x76,
-0x65, 0x73, 0x3b, 0x76, 0x69, 0x65, 0x6e, 0x72, 0x65, 0x73, 0x3b, 0x73, 0xe1, 0x62, 0x61, 0x64, 0x75, 0x3b, 0x53, 0x254,
-0x301, 0x6e, 0x64, 0x69, 0x3b, 0x4d, 0x254, 0x301, 0x6e, 0x64, 0x69, 0x3b, 0xc1, 0x70, 0x74, 0x61, 0x20, 0x4d, 0x254, 0x301,
-0x6e, 0x64, 0x69, 0x3b, 0x57, 0x25b, 0x301, 0x6e, 0x25b, 0x73, 0x25b, 0x64, 0x25b, 0x3b, 0x54, 0x254, 0x301, 0x73, 0x25b, 0x64,
-0x25b, 0x3b, 0x46, 0x25b, 0x6c, 0xe2, 0x79, 0x25b, 0x64, 0x25b, 0x3b, 0x53, 0xe1, 0x73, 0x69, 0x64, 0x25b, 0x3b, 0x53, 0x254,
-0x301, 0x3b, 0x4d, 0x254, 0x301, 0x3b, 0xc1, 0x4d, 0x3b, 0x57, 0x25b, 0x301, 0x3b, 0x54, 0x254, 0x301, 0x3b, 0x46, 0x25b, 0x3b,
-0x53, 0xe1, 0x3b, 0x73, 0x254, 0x6e, 0x64, 0x69, 0x3b, 0x6c, 0x75, 0x6e, 0x64, 0x69, 0x3b, 0x6d, 0x61, 0x72, 0x64, 0x69,
-0x3b, 0x6d, 0x25b, 0x72, 0x6b, 0x25b, 0x72, 0x25b, 0x64, 0x69, 0x3b, 0x79, 0x65, 0x64, 0x69, 0x3b, 0x76, 0x61, 0x14b, 0x64,
-0x25b, 0x72, 0x25b, 0x64, 0x69, 0x3b, 0x6d, 0x254, 0x6e, 0x254, 0x20, 0x73, 0x254, 0x6e, 0x64, 0x69, 0x3b, 0x73, 0x6f, 0x3b,
-0x6c, 0x75, 0x3b, 0x6d, 0x61, 0x3b, 0x6d, 0x25b, 0x3b, 0x79, 0x65, 0x3b, 0x76, 0x61, 0x3b, 0x6d, 0x73, 0x3b, 0x41, 0x6e,
-0x65, 0x67, 0x20, 0x31, 0x3b, 0x41, 0x6e, 0x65, 0x67, 0x20, 0x32, 0x3b, 0x41, 0x6e, 0x65, 0x67, 0x20, 0x33, 0x3b, 0x41,
-0x6e, 0x65, 0x67, 0x20, 0x34, 0x3b, 0x41, 0x6e, 0x65, 0x67, 0x20, 0x35, 0x3b, 0x41, 0x6e, 0x65, 0x67, 0x20, 0x36, 0x3b,
-0x41, 0x6e, 0x65, 0x67, 0x20, 0x37, 0x3b, 0x41, 0x31, 0x3b, 0x41, 0x32, 0x3b, 0x41, 0x33, 0x3b, 0x41, 0x34, 0x3b, 0x41,
-0x35, 0x3b, 0x41, 0x36, 0x3b, 0x41, 0x37, 0x3b, 0x6c, 0x79, 0x25b, 0x2bc, 0x25b, 0x301, 0x20, 0x73, 0x1e85, 0xed, 0x14b, 0x74,
-0xe8, 0x3b, 0x6d, 0x76, 0x66, 0xf2, 0x20, 0x6c, 0x79, 0x25b, 0x30c, 0x2bc, 0x3b, 0x6d, 0x62, 0x254, 0x301, 0x254, 0x6e, 0x74,
-0xe8, 0x20, 0x6d, 0x76, 0x66, 0xf2, 0x20, 0x6c, 0x79, 0x25b, 0x30c, 0x2bc, 0x3b, 0x74, 0x73, 0xe8, 0x74, 0x73, 0x25b, 0x300,
-0x25b, 0x20, 0x6c, 0x79, 0x25b, 0x30c, 0x2bc, 0x3b, 0x6d, 0x62, 0x254, 0x301, 0x254, 0x6e, 0x74, 0xe8, 0x20, 0x74, 0x73, 0x65,
-0x74, 0x73, 0x25b, 0x300, 0x25b, 0x20, 0x6c, 0x79, 0x25b, 0x30c, 0x2bc, 0x3b, 0x6d, 0x76, 0x66, 0xf2, 0x20, 0x6d, 0xe0, 0x67,
-0x61, 0x20, 0x6c, 0x79, 0x25b, 0x30c, 0x2bc, 0x3b, 0x6d, 0xe0, 0x67, 0x61, 0x20, 0x6c, 0x79, 0x25b, 0x30c, 0x2bc, 0x3b
+0x6f, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x6e, 0x65, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x74, 0x6c, 0x68, 0x61, 0x6e, 0x6f, 0x3b,
+0x4d, 0x61, 0x74, 0x6c, 0x68, 0x61, 0x74, 0x73, 0x6f, 0x3b, 0x53, 0x76, 0x6f, 0x3b, 0x4d, 0x75, 0x76, 0x3b, 0x43, 0x68,
+0x69, 0x70, 0x3b, 0x43, 0x68, 0x69, 0x74, 0x3b, 0x43, 0x68, 0x69, 0x6e, 0x3b, 0x43, 0x68, 0x69, 0x73, 0x3b, 0x4d, 0x75,
+0x67, 0x3b, 0x53, 0x76, 0x6f, 0x6e, 0x64, 0x6f, 0x3b, 0x4d, 0x75, 0x76, 0x68, 0x75, 0x72, 0x6f, 0x3b, 0x43, 0x68, 0x69,
+0x70, 0x69, 0x72, 0x69, 0x3b, 0x43, 0x68, 0x69, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x43, 0x68, 0x69, 0x6e, 0x61, 0x3b, 0x43,
+0x68, 0x69, 0x73, 0x68, 0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x75, 0x67, 0x6f, 0x76, 0x65, 0x72, 0x61, 0x3b, 0x53, 0x3b, 0x4d,
+0x3b, 0x43, 0x3b, 0x43, 0x3b, 0x43, 0x3b, 0x43, 0x3b, 0x4d, 0x3b, 0xd89, 0xdbb, 0xdd2, 0x3b, 0xdc3, 0xdb3, 0xdd4, 0x3b, 0xd85,
+0xd9f, 0x3b, 0xdb6, 0xdaf, 0xdcf, 0x3b, 0xdb6, 0xdca, 0x200d, 0xdbb, 0xdc4, 0x3b, 0xdc3, 0xdd2, 0xd9a, 0xdd4, 0x3b, 0xdc3, 0xdd9, 0xdb1,
+0x3b, 0xd89, 0xdbb, 0xdd2, 0xdaf, 0xdcf, 0x3b, 0xdc3, 0xdb3, 0xdd4, 0xdaf, 0xdcf, 0x3b, 0xd85, 0xd9f, 0xdc4, 0xdbb, 0xdd4, 0xdc0, 0xdcf,
+0xdaf, 0xdcf, 0x3b, 0xdb6, 0xdaf, 0xdcf, 0xdaf, 0xdcf, 0x3b, 0xdb6, 0xdca, 0x200d, 0xdbb, 0xdc4, 0xdc3, 0xdca, 0xdb4, 0xdad, 0xdd2, 0xdb1,
+0xdca, 0xdaf, 0xdcf, 0x3b, 0xdc3, 0xdd2, 0xd9a, 0xdd4, 0xdbb, 0xdcf, 0xdaf, 0xdcf, 0x3b, 0xdc3, 0xdd9, 0xdb1, 0xdc3, 0xdd4, 0xdbb, 0xdcf,
+0xdaf, 0xdcf, 0x3b, 0xd89, 0x3b, 0xdc3, 0x3b, 0xd85, 0x3b, 0xdb6, 0x3b, 0xdb6, 0xdca, 0x200d, 0xdbb, 0x3b, 0xdc3, 0xdd2, 0x3b, 0xdc3,
+0xdd9, 0x3b, 0x53, 0x6f, 0x6e, 0x3b, 0x4d, 0x73, 0x6f, 0x3b, 0x42, 0x69, 0x6c, 0x3b, 0x54, 0x73, 0x61, 0x3b, 0x4e, 0x65,
+0x3b, 0x48, 0x6c, 0x61, 0x3b, 0x4d, 0x67, 0x63, 0x3b, 0x4c, 0x69, 0x73, 0x6f, 0x6e, 0x74, 0x66, 0x6f, 0x3b, 0x75, 0x4d,
+0x73, 0x6f, 0x6d, 0x62, 0x75, 0x6c, 0x75, 0x6b, 0x6f, 0x3b, 0x4c, 0x65, 0x73, 0x69, 0x62, 0x69, 0x6c, 0x69, 0x3b, 0x4c,
+0x65, 0x73, 0x69, 0x74, 0x73, 0x61, 0x74, 0x66, 0x75, 0x3b, 0x4c, 0x65, 0x73, 0x69, 0x6e, 0x65, 0x3b, 0x4c, 0x65, 0x73,
+0x69, 0x68, 0x6c, 0x61, 0x6e, 0x75, 0x3b, 0x75, 0x4d, 0x67, 0x63, 0x69, 0x62, 0x65, 0x6c, 0x6f, 0x3b, 0x6e, 0x65, 0x3b,
+0x70, 0x6f, 0x3b, 0x75, 0x74, 0x3b, 0x73, 0x74, 0x3b, 0x161, 0x74, 0x3b, 0x70, 0x69, 0x3b, 0x73, 0x6f, 0x3b, 0x6e, 0x65,
+0x64, 0x65, 0x13e, 0x61, 0x3b, 0x70, 0x6f, 0x6e, 0x64, 0x65, 0x6c, 0x6f, 0x6b, 0x3b, 0x75, 0x74, 0x6f, 0x72, 0x6f, 0x6b,
+0x3b, 0x73, 0x74, 0x72, 0x65, 0x64, 0x61, 0x3b, 0x161, 0x74, 0x76, 0x72, 0x74, 0x6f, 0x6b, 0x3b, 0x70, 0x69, 0x61, 0x74,
+0x6f, 0x6b, 0x3b, 0x73, 0x6f, 0x62, 0x6f, 0x74, 0x61, 0x3b, 0x4e, 0x3b, 0x50, 0x3b, 0x55, 0x3b, 0x53, 0x3b, 0x160, 0x3b,
+0x50, 0x3b, 0x53, 0x3b, 0x6e, 0x65, 0x64, 0x3b, 0x70, 0x6f, 0x6e, 0x3b, 0x74, 0x6f, 0x72, 0x3b, 0x73, 0x72, 0x65, 0x3b,
+0x10d, 0x65, 0x74, 0x3b, 0x70, 0x65, 0x74, 0x3b, 0x73, 0x6f, 0x62, 0x3b, 0x6e, 0x65, 0x64, 0x65, 0x6c, 0x6a, 0x61, 0x3b,
+0x70, 0x6f, 0x6e, 0x65, 0x64, 0x65, 0x6c, 0x6a, 0x65, 0x6b, 0x3b, 0x74, 0x6f, 0x72, 0x65, 0x6b, 0x3b, 0x73, 0x72, 0x65,
+0x64, 0x61, 0x3b, 0x10d, 0x65, 0x74, 0x72, 0x74, 0x65, 0x6b, 0x3b, 0x70, 0x65, 0x74, 0x65, 0x6b, 0x3b, 0x73, 0x6f, 0x62,
+0x6f, 0x74, 0x61, 0x3b, 0x6e, 0x3b, 0x70, 0x3b, 0x74, 0x3b, 0x73, 0x3b, 0x10d, 0x3b, 0x70, 0x3b, 0x73, 0x3b, 0x6e, 0x65,
+0x64, 0x2e, 0x3b, 0x70, 0x6f, 0x6e, 0x2e, 0x3b, 0x74, 0x6f, 0x72, 0x2e, 0x3b, 0x73, 0x72, 0x65, 0x2e, 0x3b, 0x10d, 0x65,
+0x74, 0x2e, 0x3b, 0x70, 0x65, 0x74, 0x2e, 0x3b, 0x73, 0x6f, 0x62, 0x2e, 0x3b, 0x41, 0x78, 0x64, 0x3b, 0x49, 0x73, 0x6e,
+0x3b, 0x54, 0x61, 0x6c, 0x3b, 0x41, 0x72, 0x62, 0x3b, 0x4b, 0x68, 0x61, 0x3b, 0x4a, 0x69, 0x6d, 0x3b, 0x53, 0x61, 0x62,
+0x3b, 0x41, 0x78, 0x61, 0x64, 0x3b, 0x49, 0x73, 0x6e, 0x69, 0x69, 0x6e, 0x3b, 0x54, 0x61, 0x6c, 0x61, 0x61, 0x64, 0x6f,
+0x3b, 0x41, 0x72, 0x62, 0x61, 0x63, 0x6f, 0x3b, 0x4b, 0x68, 0x61, 0x6d, 0x69, 0x69, 0x73, 0x3b, 0x4a, 0x69, 0x6d, 0x63,
+0x6f, 0x3b, 0x53, 0x61, 0x62, 0x74, 0x69, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x54, 0x3b, 0x41, 0x3b, 0x4b, 0x3b, 0x4a, 0x3b,
+0x53, 0x3b, 0x64, 0x6f, 0x6d, 0x3b, 0x6c, 0x75, 0x6e, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x6d, 0x69, 0xe9, 0x3b, 0x6a, 0x75,
+0x65, 0x3b, 0x76, 0x69, 0x65, 0x3b, 0x73, 0xe1, 0x62, 0x3b, 0x64, 0x6f, 0x6d, 0x69, 0x6e, 0x67, 0x6f, 0x3b, 0x6c, 0x75,
+0x6e, 0x65, 0x73, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x65, 0x73, 0x3b, 0x6d, 0x69, 0xe9, 0x72, 0x63, 0x6f, 0x6c, 0x65, 0x73,
+0x3b, 0x6a, 0x75, 0x65, 0x76, 0x65, 0x73, 0x3b, 0x76, 0x69, 0x65, 0x72, 0x6e, 0x65, 0x73, 0x3b, 0x73, 0xe1, 0x62, 0x61,
+0x64, 0x6f, 0x3b, 0x44, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x58, 0x3b, 0x4a, 0x3b, 0x56, 0x3b, 0x53, 0x3b, 0x4a, 0x32, 0x3b,
+0x4a, 0x33, 0x3b, 0x4a, 0x34, 0x3b, 0x4a, 0x35, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x49, 0x6a, 0x3b, 0x4a, 0x31, 0x3b, 0x4a,
+0x75, 0x6d, 0x61, 0x70, 0x69, 0x6c, 0x69, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x4a, 0x75, 0x6d,
+0x61, 0x6e, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69,
+0x73, 0x69, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x61, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x32,
+0x3b, 0x33, 0x3b, 0x34, 0x3b, 0x35, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x31, 0x3b, 0x53, 0xf6, 0x6e, 0x3b, 0x4d, 0xe5, 0x6e,
+0x3b, 0x54, 0x69, 0x73, 0x3b, 0x4f, 0x6e, 0x73, 0x3b, 0x54, 0x6f, 0x72, 0x3b, 0x46, 0x72, 0x65, 0x3b, 0x4c, 0xf6, 0x72,
+0x3b, 0x53, 0xf6, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x4d, 0xe5, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x54, 0x69, 0x73, 0x64, 0x61,
+0x67, 0x3b, 0x4f, 0x6e, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x54, 0x6f, 0x72, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x46, 0x72, 0x65,
+0x64, 0x61, 0x67, 0x3b, 0x4c, 0xf6, 0x72, 0x64, 0x61, 0x67, 0x3b, 0x73, 0xf6, 0x6e, 0x3b, 0x6d, 0xe5, 0x6e, 0x3b, 0x74,
+0x69, 0x73, 0x3b, 0x6f, 0x6e, 0x73, 0x3b, 0x74, 0x6f, 0x72, 0x73, 0x3b, 0x66, 0x72, 0x65, 0x3b, 0x6c, 0xf6, 0x72, 0x3b,
+0x73, 0xf6, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x6d, 0xe5, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x74, 0x69, 0x73, 0x64, 0x61, 0x67,
+0x3b, 0x6f, 0x6e, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x74, 0x6f, 0x72, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x66, 0x72, 0x65, 0x64,
+0x61, 0x67, 0x3b, 0x6c, 0xf6, 0x72, 0x64, 0x61, 0x67, 0x3b, 0x42f, 0x448, 0x431, 0x3b, 0x414, 0x448, 0x431, 0x3b, 0x421, 0x448,
+0x431, 0x3b, 0x427, 0x448, 0x431, 0x3b, 0x41f, 0x448, 0x431, 0x3b, 0x4b6, 0x43c, 0x44a, 0x3b, 0x428, 0x43d, 0x431, 0x3b, 0x42f, 0x43a,
+0x448, 0x430, 0x43d, 0x431, 0x435, 0x3b, 0x414, 0x443, 0x448, 0x430, 0x43d, 0x431, 0x435, 0x3b, 0x421, 0x435, 0x448, 0x430, 0x43d, 0x431,
+0x435, 0x3b, 0x427, 0x43e, 0x440, 0x448, 0x430, 0x43d, 0x431, 0x435, 0x3b, 0x41f, 0x430, 0x43d, 0x4b7, 0x448, 0x430, 0x43d, 0x431, 0x435,
+0x3b, 0x4b6, 0x443, 0x43c, 0x44a, 0x430, 0x3b, 0x428, 0x430, 0x43d, 0x431, 0x435, 0x3b, 0xb9e, 0xbbe, 0x3b, 0xba4, 0xbbf, 0x3b, 0xb9a,
+0xbc6, 0x3b, 0xbaa, 0xbc1, 0x3b, 0xbb5, 0xbbf, 0x3b, 0xbb5, 0xbc6, 0x3b, 0xb9a, 0x3b, 0xb9e, 0xbbe, 0xbaf, 0xbbf, 0xbb1, 0xbc1, 0x3b,
+0xba4, 0xbbf, 0xb99, 0xbcd, 0xb95, 0xbb3, 0xbcd, 0x3b, 0xb9a, 0xbc6, 0xbb5, 0xbcd, 0xbb5, 0xbbe, 0xbaf, 0xbcd, 0x3b, 0xbaa, 0xbc1, 0xba4,
+0xba9, 0xbcd, 0x3b, 0xbb5, 0xbbf, 0xbaf, 0xbbe, 0xbb4, 0xba9, 0xbcd, 0x3b, 0xbb5, 0xbc6, 0xbb3, 0xbcd, 0xbb3, 0xbbf, 0x3b, 0xb9a, 0xba9,
+0xbbf, 0x3b, 0xc06, 0xc26, 0xc3f, 0x3b, 0xc38, 0xc4b, 0xc2e, 0x3b, 0xc2e, 0xc02, 0xc17, 0xc33, 0x3b, 0xc2c, 0xc41, 0xc27, 0x3b, 0xc17,
+0xc41, 0xc30, 0xc41, 0x3b, 0xc36, 0xc41, 0xc15, 0xc4d, 0xc30, 0x3b, 0xc36, 0xc28, 0xc3f, 0x3b, 0xc06, 0xc26, 0xc3f, 0xc35, 0xc3e, 0xc30,
+0xc02, 0x3b, 0xc38, 0xc4b, 0xc2e, 0xc35, 0xc3e, 0xc30, 0xc02, 0x3b, 0xc2e, 0xc02, 0xc17, 0xc33, 0xc35, 0xc3e, 0xc30, 0xc02, 0x3b, 0xc2c,
+0xc41, 0xc27, 0xc35, 0xc3e, 0xc30, 0xc02, 0x3b, 0xc17, 0xc41, 0xc30, 0xc41, 0xc35, 0xc3e, 0xc30, 0xc02, 0x3b, 0xc36, 0xc41, 0xc15, 0xc4d,
+0xc30, 0xc35, 0xc3e, 0xc30, 0xc02, 0x3b, 0xc36, 0xc28, 0xc3f, 0xc35, 0xc3e, 0xc30, 0xc02, 0x3b, 0xc06, 0x3b, 0xc38, 0xc4b, 0x3b, 0xc2e,
+0x3b, 0xc2c, 0xc41, 0x3b, 0xc17, 0xc41, 0x3b, 0xc36, 0xc41, 0x3b, 0xc36, 0x3b, 0xe2d, 0xe32, 0x2e, 0x3b, 0xe08, 0x2e, 0x3b, 0xe2d,
+0x2e, 0x3b, 0xe1e, 0x2e, 0x3b, 0xe1e, 0xe24, 0x2e, 0x3b, 0xe28, 0x2e, 0x3b, 0xe2a, 0x2e, 0x3b, 0xe27, 0xe31, 0xe19, 0xe2d, 0xe32,
+0xe17, 0xe34, 0xe15, 0xe22, 0xe4c, 0x3b, 0xe27, 0xe31, 0xe19, 0xe08, 0xe31, 0xe19, 0xe17, 0xe23, 0xe4c, 0x3b, 0xe27, 0xe31, 0xe19, 0xe2d,
+0xe31, 0xe07, 0xe04, 0xe32, 0xe23, 0x3b, 0xe27, 0xe31, 0xe19, 0xe1e, 0xe38, 0xe18, 0x3b, 0xe27, 0xe31, 0xe19, 0xe1e, 0xe24, 0xe2b, 0xe31,
+0xe2a, 0xe1a, 0xe14, 0xe35, 0x3b, 0xe27, 0xe31, 0xe19, 0xe28, 0xe38, 0xe01, 0xe23, 0xe4c, 0x3b, 0xe27, 0xe31, 0xe19, 0xe40, 0xe2a, 0xe32,
+0xe23, 0xe4c, 0x3b, 0xf49, 0xf72, 0xf0b, 0xf58, 0xf0b, 0x3b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0x3b, 0xf58, 0xf72, 0xf42, 0xf0b, 0xf51,
+0xf58, 0xf62, 0xf0b, 0x3b, 0xf67, 0xfb3, 0xf42, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf55, 0xf74, 0xf62, 0xf0b, 0xf56, 0xf74, 0xf0b, 0x3b, 0xf66,
+0xf44, 0xf66, 0xf0b, 0x3b, 0xf66, 0xfa4, 0xf7a, 0xf53, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf49, 0xf72, 0xf0b, 0xf58,
+0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf5f, 0xfb3, 0xf0b, 0xf56, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf58, 0xf72, 0xf42, 0xf0b,
+0xf51, 0xf58, 0xf62, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf67, 0xfb3, 0xf42, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b,
+0xf55, 0xf74, 0xf62, 0xf0b, 0xf56, 0xf74, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60, 0xf0b, 0xf66, 0xf44, 0xf66, 0xf0b, 0x3b, 0xf42, 0xf5f, 0xf60,
+0xf0b, 0xf66, 0xfa4, 0xf7a, 0xf53, 0xf0b, 0xf54, 0xf0b, 0x3b, 0xf49, 0xf72, 0x3b, 0xf5f, 0xfb3, 0x3b, 0xf58, 0xf72, 0x3b, 0xf67, 0xfb3,
+0x3b, 0xf55, 0xf74, 0x3b, 0xf66, 0x3b, 0xf66, 0xfa4, 0xf7a, 0x3b, 0xf49, 0xf72, 0x3b, 0xf5f, 0xfb3, 0x3b, 0xf58, 0xf72, 0x3b, 0xf67,
+0xfb3, 0xf42, 0x3b, 0xf55, 0xf74, 0x3b, 0xf66, 0x3b, 0xf66, 0xfa4, 0xf7a, 0x3b, 0x1230, 0x1295, 0x1260, 0x1275, 0x3b, 0x1230, 0x1291, 0x12ed,
+0x3b, 0x1220, 0x1209, 0x1235, 0x3b, 0x1228, 0x1261, 0x12d5, 0x3b, 0x1283, 0x1219, 0x1235, 0x3b, 0x12d3, 0x122d, 0x1262, 0x3b, 0x1240, 0x12f3, 0x121d,
+0x3b, 0x1230, 0x3b, 0x1230, 0x3b, 0x1220, 0x3b, 0x1228, 0x3b, 0x1283, 0x3b, 0x12d3, 0x3b, 0x1240, 0x3b, 0x1230, 0x1295, 0x1260, 0x1275, 0x3b,
+0x1230, 0x1291, 0x12ed, 0x3b, 0x1230, 0x1209, 0x1235, 0x3b, 0x1228, 0x1261, 0x12d5, 0x3b, 0x1213, 0x1219, 0x1235, 0x3b, 0x12d3, 0x122d, 0x1262, 0x3b,
+0x1240, 0x12f3, 0x121d, 0x3b, 0x53, 0x101, 0x70, 0x3b, 0x4d, 0x14d, 0x6e, 0x3b, 0x54, 0x16b, 0x73, 0x3b, 0x50, 0x75, 0x6c, 0x3b,
+0x54, 0x75, 0x2bb, 0x61, 0x3b, 0x46, 0x61, 0x6c, 0x3b, 0x54, 0x6f, 0x6b, 0x3b, 0x53, 0x101, 0x70, 0x61, 0x74, 0x65, 0x3b,
+0x4d, 0x14d, 0x6e, 0x69, 0x74, 0x65, 0x3b, 0x54, 0x16b, 0x73, 0x69, 0x74, 0x65, 0x3b, 0x50, 0x75, 0x6c, 0x65, 0x6c, 0x75,
+0x6c, 0x75, 0x3b, 0x54, 0x75, 0x2bb, 0x61, 0x70, 0x75, 0x6c, 0x65, 0x6c, 0x75, 0x6c, 0x75, 0x3b, 0x46, 0x61, 0x6c, 0x61,
+0x69, 0x74, 0x65, 0x3b, 0x54, 0x6f, 0x6b, 0x6f, 0x6e, 0x61, 0x6b, 0x69, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x54, 0x3b, 0x50,
+0x3b, 0x54, 0x3b, 0x46, 0x3b, 0x54, 0x3b, 0x53, 0x6f, 0x6e, 0x3b, 0x4d, 0x75, 0x73, 0x3b, 0x42, 0x69, 0x72, 0x3b, 0x48,
+0x61, 0x72, 0x3b, 0x4e, 0x65, 0x3b, 0x54, 0x6c, 0x68, 0x3b, 0x4d, 0x75, 0x67, 0x3b, 0x53, 0x6f, 0x6e, 0x74, 0x6f, 0x3b,
+0x4d, 0x75, 0x73, 0x75, 0x6d, 0x62, 0x68, 0x75, 0x6e, 0x75, 0x6b, 0x75, 0x3b, 0x52, 0x61, 0x76, 0x75, 0x6d, 0x62, 0x69,
+0x72, 0x68, 0x69, 0x3b, 0x52, 0x61, 0x76, 0x75, 0x6e, 0x68, 0x61, 0x72, 0x68, 0x75, 0x3b, 0x52, 0x61, 0x76, 0x75, 0x6d,
+0x75, 0x6e, 0x65, 0x3b, 0x52, 0x61, 0x76, 0x75, 0x6e, 0x74, 0x6c, 0x68, 0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x75, 0x67, 0x71,
+0x69, 0x76, 0x65, 0x6c, 0x61, 0x3b, 0x50, 0x61, 0x7a, 0x3b, 0x50, 0x7a, 0x74, 0x3b, 0x53, 0x61, 0x6c, 0x3b, 0xc7, 0x61,
+0x72, 0x3b, 0x50, 0x65, 0x72, 0x3b, 0x43, 0x75, 0x6d, 0x3b, 0x43, 0x6d, 0x74, 0x3b, 0x50, 0x61, 0x7a, 0x61, 0x72, 0x3b,
+0x50, 0x61, 0x7a, 0x61, 0x72, 0x74, 0x65, 0x73, 0x69, 0x3b, 0x53, 0x61, 0x6c, 0x131, 0x3b, 0xc7, 0x61, 0x72, 0x15f, 0x61,
+0x6d, 0x62, 0x61, 0x3b, 0x50, 0x65, 0x72, 0x15f, 0x65, 0x6d, 0x62, 0x65, 0x3b, 0x43, 0x75, 0x6d, 0x61, 0x3b, 0x43, 0x75,
+0x6d, 0x61, 0x72, 0x74, 0x65, 0x73, 0x69, 0x3b, 0x50, 0x3b, 0x50, 0x3b, 0x53, 0x3b, 0xc7, 0x3b, 0x50, 0x3b, 0x43, 0x3b,
+0x43, 0x3b, 0x41d, 0x434, 0x3b, 0x41f, 0x43d, 0x3b, 0x412, 0x442, 0x3b, 0x421, 0x440, 0x3b, 0x427, 0x442, 0x3b, 0x41f, 0x442, 0x3b,
+0x421, 0x431, 0x3b, 0x41d, 0x435, 0x434, 0x456, 0x43b, 0x44f, 0x3b, 0x41f, 0x43e, 0x43d, 0x435, 0x434, 0x456, 0x43b, 0x43e, 0x43a, 0x3b,
+0x412, 0x456, 0x432, 0x442, 0x43e, 0x440, 0x43e, 0x43a, 0x3b, 0x421, 0x435, 0x440, 0x435, 0x434, 0x430, 0x3b, 0x427, 0x435, 0x442, 0x432,
+0x435, 0x440, 0x3b, 0x41f, 0x2bc, 0x44f, 0x442, 0x43d, 0x438, 0x446, 0x44f, 0x3b, 0x421, 0x443, 0x431, 0x43e, 0x442, 0x430, 0x3b, 0x41d,
+0x3b, 0x41f, 0x3b, 0x412, 0x3b, 0x421, 0x3b, 0x427, 0x3b, 0x41f, 0x3b, 0x421, 0x3b, 0x627, 0x62a, 0x648, 0x627, 0x631, 0x3b, 0x67e,
+0x6cc, 0x631, 0x3b, 0x645, 0x646, 0x6af, 0x644, 0x3b, 0x628, 0x62f, 0x647, 0x3b, 0x62c, 0x645, 0x639, 0x631, 0x627, 0x62a, 0x3b, 0x62c,
+0x645, 0x639, 0x6c1, 0x3b, 0x6c1, 0x641, 0x62a, 0x6c1, 0x3b, 0x42f, 0x43a, 0x448, 0x3b, 0x414, 0x443, 0x448, 0x3b, 0x421, 0x435, 0x448,
+0x3b, 0x427, 0x43e, 0x440, 0x3b, 0x41f, 0x430, 0x439, 0x3b, 0x416, 0x443, 0x43c, 0x3b, 0x428, 0x430, 0x43d, 0x3b, 0x44f, 0x43a, 0x448,
+0x430, 0x43d, 0x431, 0x430, 0x3b, 0x434, 0x443, 0x448, 0x430, 0x43d, 0x431, 0x430, 0x3b, 0x441, 0x435, 0x448, 0x430, 0x43d, 0x431, 0x430,
+0x3b, 0x447, 0x43e, 0x440, 0x448, 0x430, 0x43d, 0x431, 0x430, 0x3b, 0x43f, 0x430, 0x439, 0x448, 0x430, 0x43d, 0x431, 0x430, 0x3b, 0x436,
+0x443, 0x43c, 0x430, 0x3b, 0x448, 0x430, 0x43d, 0x431, 0x430, 0x3b, 0x42f, 0x3b, 0x414, 0x3b, 0x421, 0x3b, 0x427, 0x3b, 0x41f, 0x3b,
+0x416, 0x3b, 0x428, 0x3b, 0x6cc, 0x2e, 0x3b, 0x62f, 0x2e, 0x3b, 0x633, 0x2e, 0x3b, 0x686, 0x2e, 0x3b, 0x67e, 0x2e, 0x3b, 0x62c,
+0x2e, 0x3b, 0x634, 0x2e, 0x3b, 0x59, 0x61, 0x6b, 0x73, 0x68, 0x3b, 0x44, 0x75, 0x73, 0x68, 0x3b, 0x53, 0x65, 0x73, 0x68,
+0x3b, 0x43, 0x68, 0x6f, 0x72, 0x3b, 0x50, 0x61, 0x79, 0x3b, 0x43, 0x75, 0x6d, 0x3b, 0x53, 0x68, 0x61, 0x6e, 0x3b, 0x79,
+0x61, 0x6b, 0x73, 0x68, 0x61, 0x6e, 0x62, 0x61, 0x3b, 0x64, 0x75, 0x73, 0x68, 0x61, 0x6e, 0x62, 0x61, 0x3b, 0x73, 0x65,
+0x73, 0x68, 0x61, 0x6e, 0x62, 0x61, 0x3b, 0x63, 0x68, 0x6f, 0x72, 0x73, 0x68, 0x61, 0x6e, 0x62, 0x61, 0x3b, 0x70, 0x61,
+0x79, 0x73, 0x68, 0x61, 0x6e, 0x62, 0x61, 0x3b, 0x63, 0x75, 0x6d, 0x61, 0x3b, 0x73, 0x68, 0x61, 0x6e, 0x62, 0x61, 0x3b,
+0x59, 0x3b, 0x44, 0x3b, 0x53, 0x3b, 0x43, 0x3b, 0x50, 0x3b, 0x43, 0x3b, 0x53, 0x3b, 0x43, 0x4e, 0x3b, 0x54, 0x68, 0x20,
+0x32, 0x3b, 0x54, 0x68, 0x20, 0x33, 0x3b, 0x54, 0x68, 0x20, 0x34, 0x3b, 0x54, 0x68, 0x20, 0x35, 0x3b, 0x54, 0x68, 0x20,
+0x36, 0x3b, 0x54, 0x68, 0x20, 0x37, 0x3b, 0x43, 0x68, 0x1ee7, 0x20, 0x6e, 0x68, 0x1ead, 0x74, 0x3b, 0x54, 0x68, 0x1ee9, 0x20,
+0x68, 0x61, 0x69, 0x3b, 0x54, 0x68, 0x1ee9, 0x20, 0x62, 0x61, 0x3b, 0x54, 0x68, 0x1ee9, 0x20, 0x74, 0x1b0, 0x3b, 0x54, 0x68,
+0x1ee9, 0x20, 0x6e, 0x103, 0x6d, 0x3b, 0x54, 0x68, 0x1ee9, 0x20, 0x73, 0xe1, 0x75, 0x3b, 0x54, 0x68, 0x1ee9, 0x20, 0x62, 0x1ea3,
+0x79, 0x3b, 0x43, 0x4e, 0x3b, 0x54, 0x32, 0x3b, 0x54, 0x33, 0x3b, 0x54, 0x34, 0x3b, 0x54, 0x35, 0x3b, 0x54, 0x36, 0x3b,
+0x54, 0x37, 0x3b, 0x53, 0x75, 0x6c, 0x3b, 0x4c, 0x6c, 0x75, 0x6e, 0x3b, 0x4d, 0x61, 0x77, 0x3b, 0x4d, 0x65, 0x72, 0x3b,
+0x49, 0x61, 0x75, 0x3b, 0x47, 0x77, 0x65, 0x3b, 0x53, 0x61, 0x64, 0x3b, 0x44, 0x79, 0x64, 0x64, 0x20, 0x53, 0x75, 0x6c,
+0x3b, 0x44, 0x79, 0x64, 0x64, 0x20, 0x4c, 0x6c, 0x75, 0x6e, 0x3b, 0x44, 0x79, 0x64, 0x64, 0x20, 0x4d, 0x61, 0x77, 0x72,
+0x74, 0x68, 0x3b, 0x44, 0x79, 0x64, 0x64, 0x20, 0x4d, 0x65, 0x72, 0x63, 0x68, 0x65, 0x72, 0x3b, 0x44, 0x79, 0x64, 0x64,
+0x20, 0x49, 0x61, 0x75, 0x3b, 0x44, 0x79, 0x64, 0x64, 0x20, 0x47, 0x77, 0x65, 0x6e, 0x65, 0x72, 0x3b, 0x44, 0x79, 0x64,
+0x64, 0x20, 0x53, 0x61, 0x64, 0x77, 0x72, 0x6e, 0x3b, 0x53, 0x3b, 0x4c, 0x6c, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x49, 0x3b,
+0x47, 0x3b, 0x53, 0x3b, 0x53, 0x75, 0x6c, 0x3b, 0x4c, 0x6c, 0x75, 0x6e, 0x3b, 0x4d, 0x61, 0x77, 0x3b, 0x4d, 0x65, 0x72,
+0x3b, 0x49, 0x61, 0x75, 0x3b, 0x47, 0x77, 0x65, 0x6e, 0x3b, 0x53, 0x61, 0x64, 0x3b, 0x43, 0x61, 0x77, 0x3b, 0x4d, 0x76,
+0x75, 0x3b, 0x42, 0x69, 0x6e, 0x3b, 0x54, 0x68, 0x61, 0x3b, 0x53, 0x69, 0x6e, 0x3b, 0x48, 0x6c, 0x61, 0x3b, 0x4d, 0x67,
+0x71, 0x3b, 0x43, 0x61, 0x77, 0x65, 0x3b, 0x4d, 0x76, 0x75, 0x6c, 0x6f, 0x3b, 0x4c, 0x77, 0x65, 0x73, 0x69, 0x62, 0x69,
+0x6e, 0x69, 0x3b, 0x4c, 0x77, 0x65, 0x73, 0x69, 0x74, 0x68, 0x61, 0x74, 0x68, 0x75, 0x3b, 0x4c, 0x77, 0x65, 0x73, 0x69,
+0x6e, 0x65, 0x3b, 0x4c, 0x77, 0x65, 0x73, 0x69, 0x68, 0x6c, 0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x67, 0x71, 0x69, 0x62, 0x65,
+0x6c, 0x6f, 0x3b, 0xc0, 0xec, 0x6b, 0xfa, 0x3b, 0x41, 0x6a, 0xe9, 0x3b, 0xcc, 0x73, 0x1eb9, 0x301, 0x67, 0x75, 0x6e, 0x3b,
+0x1ecc, 0x6a, 0x1ecd, 0x301, 0x72, 0xfa, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x62, 0x1ecd, 0x3b, 0x1eb8, 0x74, 0xec, 0x3b, 0xc0, 0x62,
+0xe1, 0x6d, 0x1eb9, 0x301, 0x74, 0x61, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x20, 0xc0, 0xec, 0x6b, 0xfa, 0x3b, 0x1ecc, 0x6a, 0x1ecd,
+0x301, 0x20, 0x41, 0x6a, 0xe9, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x20, 0xcc, 0x73, 0x1eb9, 0x301, 0x67, 0x75, 0x6e, 0x3b, 0x1ecc,
+0x6a, 0x1ecd, 0x301, 0x72, 0xfa, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x62, 0x1ecd, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x20, 0x1eb8, 0x74,
+0xec, 0x3b, 0x1ecc, 0x6a, 0x1ecd, 0x301, 0x20, 0xc0, 0x62, 0xe1, 0x6d, 0x1eb9, 0x301, 0x74, 0x61, 0x3b, 0x53, 0x6f, 0x6e, 0x3b,
+0x4d, 0x73, 0x6f, 0x3b, 0x42, 0x69, 0x6c, 0x3b, 0x54, 0x68, 0x61, 0x3b, 0x53, 0x69, 0x6e, 0x3b, 0x48, 0x6c, 0x61, 0x3b,
+0x4d, 0x67, 0x71, 0x3b, 0x53, 0x6f, 0x6e, 0x74, 0x6f, 0x3b, 0x4d, 0x73, 0x6f, 0x6d, 0x62, 0x75, 0x6c, 0x75, 0x6b, 0x6f,
+0x3b, 0x4c, 0x77, 0x65, 0x73, 0x69, 0x62, 0x69, 0x6c, 0x69, 0x3b, 0x4c, 0x77, 0x65, 0x73, 0x69, 0x74, 0x68, 0x61, 0x74,
+0x68, 0x75, 0x3b, 0x75, 0x4c, 0x77, 0x65, 0x73, 0x69, 0x6e, 0x65, 0x3b, 0x4c, 0x77, 0x65, 0x73, 0x69, 0x68, 0x6c, 0x61,
+0x6e, 0x75, 0x3b, 0x4d, 0x67, 0x71, 0x69, 0x62, 0x65, 0x6c, 0x6f, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x42, 0x3b, 0x54, 0x3b,
+0x53, 0x3b, 0x48, 0x3b, 0x4d, 0x3b, 0x73, 0xf8, 0x6e, 0x3b, 0x6d, 0xe5, 0x6e, 0x3b, 0x74, 0x79, 0x73, 0x3b, 0x6f, 0x6e,
+0x73, 0x3b, 0x74, 0x6f, 0x72, 0x3b, 0x66, 0x72, 0x65, 0x3b, 0x6c, 0x61, 0x75, 0x3b, 0x73, 0xf8, 0x6e, 0x64, 0x61, 0x67,
+0x3b, 0x6d, 0xe5, 0x6e, 0x64, 0x61, 0x67, 0x3b, 0x74, 0x79, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x6f, 0x6e, 0x73, 0x64, 0x61,
+0x67, 0x3b, 0x74, 0x6f, 0x72, 0x73, 0x64, 0x61, 0x67, 0x3b, 0x66, 0x72, 0x65, 0x64, 0x61, 0x67, 0x3b, 0x6c, 0x61, 0x75,
+0x72, 0x64, 0x61, 0x67, 0x3b, 0x73, 0xf8, 0x2e, 0x3b, 0x6d, 0xe5, 0x2e, 0x3b, 0x74, 0x79, 0x2e, 0x3b, 0x6f, 0x6e, 0x2e,
+0x3b, 0x74, 0x6f, 0x2e, 0x3b, 0x66, 0x72, 0x2e, 0x3b, 0x6c, 0x61, 0x2e, 0x3b, 0x4a, 0x65, 0x64, 0x3b, 0x4a, 0x65, 0x6c,
+0x3b, 0x4a, 0x65, 0x6d, 0x3b, 0x4a, 0x65, 0x72, 0x63, 0x3b, 0x4a, 0x65, 0x72, 0x64, 0x3b, 0x4a, 0x65, 0x68, 0x3b, 0x4a,
+0x65, 0x73, 0x3b, 0x4a, 0x65, 0x64, 0x6f, 0x6f, 0x6e, 0x65, 0x65, 0x3b, 0x4a, 0x65, 0x6c, 0x68, 0x65, 0x69, 0x6e, 0x3b,
+0x4a, 0x65, 0x6d, 0x61, 0x79, 0x72, 0x74, 0x3b, 0x4a, 0x65, 0x72, 0x63, 0x65, 0x61, 0x6e, 0x3b, 0x4a, 0x65, 0x72, 0x64,
+0x65, 0x69, 0x6e, 0x3b, 0x4a, 0x65, 0x68, 0x65, 0x69, 0x6e, 0x65, 0x79, 0x3b, 0x4a, 0x65, 0x73, 0x61, 0x72, 0x6e, 0x3b,
+0x53, 0x75, 0x6c, 0x3b, 0x4c, 0x75, 0x6e, 0x3b, 0x4d, 0x74, 0x68, 0x3b, 0x4d, 0x68, 0x72, 0x3b, 0x59, 0x6f, 0x77, 0x3b,
+0x47, 0x77, 0x65, 0x3b, 0x53, 0x61, 0x64, 0x3b, 0x44, 0x65, 0x20, 0x53, 0x75, 0x6c, 0x3b, 0x44, 0x65, 0x20, 0x4c, 0x75,
+0x6e, 0x3b, 0x44, 0x65, 0x20, 0x4d, 0x65, 0x72, 0x74, 0x68, 0x3b, 0x44, 0x65, 0x20, 0x4d, 0x65, 0x72, 0x68, 0x65, 0x72,
+0x3b, 0x44, 0x65, 0x20, 0x59, 0x6f, 0x77, 0x3b, 0x44, 0x65, 0x20, 0x47, 0x77, 0x65, 0x6e, 0x65, 0x72, 0x3b, 0x44, 0x65,
+0x20, 0x53, 0x61, 0x64, 0x6f, 0x72, 0x6e, 0x3b, 0x4b, 0x77, 0x65, 0x3b, 0x44, 0x77, 0x6f, 0x3b, 0x42, 0x65, 0x6e, 0x3b,
+0x57, 0x75, 0x6b, 0x3b, 0x59, 0x61, 0x77, 0x3b, 0x46, 0x69, 0x61, 0x3b, 0x4d, 0x65, 0x6d, 0x3b, 0x4b, 0x77, 0x65, 0x73,
+0x69, 0x64, 0x61, 0x3b, 0x44, 0x77, 0x6f, 0x77, 0x64, 0x61, 0x3b, 0x42, 0x65, 0x6e, 0x61, 0x64, 0x61, 0x3b, 0x57, 0x75,
+0x6b, 0x75, 0x64, 0x61, 0x3b, 0x59, 0x61, 0x77, 0x64, 0x61, 0x3b, 0x46, 0x69, 0x64, 0x61, 0x3b, 0x4d, 0x65, 0x6d, 0x65,
+0x6e, 0x65, 0x64, 0x61, 0x3b, 0x4b, 0x3b, 0x44, 0x3b, 0x42, 0x3b, 0x57, 0x3b, 0x59, 0x3b, 0x46, 0x3b, 0x4d, 0x3b, 0x906,
+0x926, 0x93f, 0x924, 0x94d, 0x92f, 0x935, 0x93e, 0x930, 0x3b, 0x938, 0x94b, 0x92e, 0x935, 0x93e, 0x930, 0x3b, 0x92e, 0x902, 0x917, 0x933,
+0x93e, 0x930, 0x3b, 0x92c, 0x941, 0x927, 0x935, 0x93e, 0x930, 0x3b, 0x917, 0x941, 0x930, 0x941, 0x935, 0x93e, 0x930, 0x3b, 0x936, 0x941,
+0x915, 0x94d, 0x930, 0x935, 0x93e, 0x930, 0x3b, 0x936, 0x928, 0x93f, 0x935, 0x93e, 0x930, 0x3b, 0x1ee4, 0x6b, 0x61, 0x3b, 0x4d, 0x1ecd,
+0x6e, 0x3b, 0x54, 0x69, 0x75, 0x3b, 0x57, 0x65, 0x6e, 0x3b, 0x54, 0x1ecd, 0x1ecd, 0x3b, 0x46, 0x72, 0x61, 0x1ecb, 0x3b, 0x53,
+0x61, 0x74, 0x3b, 0x4d, 0x62, 0x1ecd, 0x73, 0x1ecb, 0x20, 0x1ee4, 0x6b, 0x61, 0x3b, 0x4d, 0x1ecd, 0x6e, 0x64, 0x65, 0x3b, 0x54,
+0x69, 0x75, 0x7a, 0x64, 0x65, 0x65, 0x3b, 0x57, 0x65, 0x6e, 0x65, 0x7a, 0x64, 0x65, 0x65, 0x3b, 0x54, 0x1ecd, 0x1ecd, 0x7a,
+0x64, 0x65, 0x65, 0x3b, 0x46, 0x72, 0x61, 0x1ecb, 0x64, 0x65, 0x65, 0x3b, 0x53, 0x61, 0x74, 0x1ecd, 0x64, 0x65, 0x65, 0x3b,
+0x57, 0x6b, 0x79, 0x3b, 0x57, 0x6b, 0x77, 0x3b, 0x57, 0x6b, 0x6c, 0x3b, 0x57, 0x74, 0x169, 0x3b, 0x57, 0x6b, 0x6e, 0x3b,
+0x57, 0x74, 0x6e, 0x3b, 0x57, 0x74, 0x68, 0x3b, 0x57, 0x61, 0x20, 0x6b, 0x79, 0x75, 0x6d, 0x77, 0x61, 0x3b, 0x57, 0x61,
+0x20, 0x6b, 0x77, 0x61, 0x6d, 0x62, 0x129, 0x6c, 0x129, 0x6c, 0x79, 0x61, 0x3b, 0x57, 0x61, 0x20, 0x6b, 0x65, 0x6c, 0x129,
+0x3b, 0x57, 0x61, 0x20, 0x6b, 0x61, 0x74, 0x61, 0x74, 0x169, 0x3b, 0x57, 0x61, 0x20, 0x6b, 0x61, 0x6e, 0x61, 0x3b, 0x57,
+0x61, 0x20, 0x6b, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x57, 0x61, 0x20, 0x74, 0x68, 0x61, 0x6e, 0x74, 0x68, 0x61, 0x74,
+0x169, 0x3b, 0x59, 0x3b, 0x57, 0x3b, 0x45, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x1230, 0x2f, 0x1245, 0x3b,
+0x1230, 0x1291, 0x3b, 0x1230, 0x120a, 0x131d, 0x3b, 0x1208, 0x1313, 0x3b, 0x12a3, 0x121d, 0x12f5, 0x3b, 0x12a3, 0x122d, 0x1265, 0x3b, 0x1230, 0x2f,
+0x123d, 0x3b, 0x1230, 0x1295, 0x1260, 0x122d, 0x20, 0x1245, 0x12f3, 0x12c5, 0x3b, 0x1230, 0x1291, 0x3b, 0x1230, 0x120a, 0x131d, 0x3b, 0x1208, 0x1313,
+0x20, 0x12c8, 0x122a, 0x20, 0x1208, 0x1265, 0x12cb, 0x3b, 0x12a3, 0x121d, 0x12f5, 0x3b, 0x12a3, 0x122d, 0x1265, 0x3b, 0x1230, 0x1295, 0x1260, 0x122d,
+0x20, 0x123d, 0x1313, 0x12c5, 0x3b, 0x1230, 0x3b, 0x1230, 0x3b, 0x1230, 0x3b, 0x1208, 0x3b, 0x12a3, 0x3b, 0x12a3, 0x3b, 0x1230, 0x3b, 0x1230,
+0x2f, 0x12d3, 0x3b, 0x1230, 0x1296, 0x3b, 0x1273, 0x120b, 0x1238, 0x3b, 0x12a3, 0x1228, 0x122d, 0x3b, 0x12a8, 0x121a, 0x123d, 0x3b, 0x1305, 0x121d,
+0x12d3, 0x3b, 0x1230, 0x2f, 0x1295, 0x3b, 0x1230, 0x1295, 0x1260, 0x1275, 0x20, 0x12d3, 0x1263, 0x12ed, 0x3b, 0x1230, 0x1296, 0x3b, 0x1273, 0x120b,
+0x1238, 0x1296, 0x3b, 0x12a3, 0x1228, 0x122d, 0x1263, 0x12d3, 0x3b, 0x12a8, 0x121a, 0x123d, 0x3b, 0x1305, 0x121d, 0x12d3, 0x1275, 0x3b, 0x1230, 0x1295,
+0x1260, 0x1275, 0x20, 0x1295, 0x12a2, 0x123d, 0x3b, 0x1230, 0x3b, 0x1230, 0x3b, 0x1273, 0x3b, 0x12a3, 0x3b, 0x12a8, 0x3b, 0x1305, 0x3b, 0x1230,
+0x3b, 0x64, 0x6f, 0x6d, 0x3b, 0x6c, 0x75, 0x6e, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x6d, 0x69, 0x65, 0x3b, 0x6a, 0x6f, 0x69,
+0x3b, 0x76, 0x69, 0x6e, 0x3b, 0x73, 0x61, 0x62, 0x3b, 0x64, 0x6f, 0x6d, 0x65, 0x6e, 0x69, 0x65, 0x3b, 0x6c, 0x75, 0x6e,
+0x69, 0x73, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x61, 0x72, 0x73, 0x3b, 0x6d, 0x69, 0x65, 0x72, 0x63, 0x75, 0x73, 0x3b, 0x6a,
+0x6f, 0x69, 0x62, 0x65, 0x3b, 0x76, 0x69, 0x6e, 0x61, 0x72, 0x73, 0x3b, 0x73, 0x61, 0x62, 0x69, 0x64, 0x65, 0x3b, 0x53,
+0x77, 0x6f, 0x3b, 0x4d, 0x75, 0x73, 0x3b, 0x56, 0x68, 0x69, 0x3b, 0x52, 0x61, 0x72, 0x3b, 0x1e4a, 0x61, 0x3b, 0x1e70, 0x61,
+0x6e, 0x3b, 0x4d, 0x75, 0x67, 0x3b, 0x53, 0x77, 0x6f, 0x6e, 0x64, 0x61, 0x68, 0x61, 0x3b, 0x4d, 0x75, 0x73, 0x75, 0x6d,
+0x62, 0x75, 0x6c, 0x75, 0x77, 0x6f, 0x3b, 0x1e3c, 0x61, 0x76, 0x68, 0x75, 0x76, 0x68, 0x69, 0x6c, 0x69, 0x3b, 0x1e3c, 0x61,
+0x76, 0x68, 0x75, 0x72, 0x61, 0x72, 0x75, 0x3b, 0x1e3c, 0x61, 0x76, 0x68, 0x75, 0x1e4b, 0x61, 0x3b, 0x1e3c, 0x61, 0x76, 0x68,
+0x75, 0x1e71, 0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x75, 0x67, 0x69, 0x76, 0x68, 0x65, 0x6c, 0x61, 0x3b, 0x6b, 0x254, 0x73, 0x3b,
+0x64, 0x7a, 0x6f, 0x3b, 0x62, 0x6c, 0x61, 0x3b, 0x6b, 0x75, 0x256, 0x3b, 0x79, 0x61, 0x77, 0x3b, 0x66, 0x69, 0x256, 0x3b,
+0x6d, 0x65, 0x6d, 0x3b, 0x6b, 0x254, 0x73, 0x69, 0x256, 0x61, 0x3b, 0x64, 0x7a, 0x6f, 0x256, 0x61, 0x3b, 0x62, 0x6c, 0x61,
+0x256, 0x61, 0x3b, 0x6b, 0x75, 0x256, 0x61, 0x3b, 0x79, 0x61, 0x77, 0x6f, 0x256, 0x61, 0x3b, 0x66, 0x69, 0x256, 0x61, 0x3b,
+0x6d, 0x65, 0x6d, 0x6c, 0x65, 0x256, 0x61, 0x3b, 0x6b, 0x3b, 0x64, 0x3b, 0x62, 0x3b, 0x6b, 0x3b, 0x79, 0x3b, 0x66, 0x3b,
+0x6d, 0x3b, 0x12c8, 0x130b, 0x3b, 0x1233, 0x12ed, 0x1296, 0x3b, 0x121b, 0x1246, 0x1233, 0x129b, 0x3b, 0x12a0, 0x1229, 0x12cb, 0x3b, 0x1203, 0x1219,
+0x1233, 0x3b, 0x12a0, 0x122d, 0x1263, 0x3b, 0x1244, 0x122b, 0x3b, 0x12c8, 0x3b, 0x1233, 0x3b, 0x121b, 0x3b, 0x12a0, 0x3b, 0x1203, 0x3b, 0x12a0,
+0x3b, 0x1244, 0x3b, 0x4c, 0x50, 0x3b, 0x50, 0x31, 0x3b, 0x50, 0x32, 0x3b, 0x50, 0x33, 0x3b, 0x50, 0x34, 0x3b, 0x50, 0x35,
+0x3b, 0x50, 0x36, 0x3b, 0x4c, 0x101, 0x70, 0x75, 0x6c, 0x65, 0x3b, 0x50, 0x6f, 0x2bb, 0x61, 0x6b, 0x61, 0x68, 0x69, 0x3b,
+0x50, 0x6f, 0x2bb, 0x61, 0x6c, 0x75, 0x61, 0x3b, 0x50, 0x6f, 0x2bb, 0x61, 0x6b, 0x6f, 0x6c, 0x75, 0x3b, 0x50, 0x6f, 0x2bb,
+0x61, 0x68, 0x101, 0x3b, 0x50, 0x6f, 0x2bb, 0x61, 0x6c, 0x69, 0x6d, 0x61, 0x3b, 0x50, 0x6f, 0x2bb, 0x61, 0x6f, 0x6e, 0x6f,
+0x3b, 0x4c, 0x69, 0x6e, 0x3b, 0x4c, 0x75, 0x6e, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x4d, 0x69, 0x79, 0x3b, 0x48, 0x75, 0x77,
+0x3b, 0x42, 0x69, 0x79, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x4c, 0x69, 0x6e, 0x67, 0x67, 0x6f, 0x3b, 0x4c, 0x75, 0x6e, 0x65,
+0x73, 0x3b, 0x4d, 0x61, 0x72, 0x74, 0x65, 0x73, 0x3b, 0x4d, 0x69, 0x79, 0x65, 0x72, 0x6b, 0x75, 0x6c, 0x65, 0x73, 0x3b,
+0x48, 0x75, 0x77, 0x65, 0x62, 0x65, 0x73, 0x3b, 0x42, 0x69, 0x79, 0x65, 0x72, 0x6e, 0x65, 0x73, 0x3b, 0x53, 0x61, 0x62,
+0x61, 0x64, 0x6f, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x4d, 0x3b, 0x48, 0x3b, 0x42, 0x3b, 0x53, 0x3b, 0x4c, 0x69,
+0x6e, 0x3b, 0x4c, 0x75, 0x6e, 0x3b, 0x4d, 0x61, 0x72, 0x3b, 0x4d, 0x79, 0x65, 0x3b, 0x48, 0x75, 0x77, 0x3b, 0x42, 0x79,
+0x65, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x53, 0x75, 0x2e, 0x3b, 0x4d, 0xe4, 0x2e, 0x3b, 0x5a, 0x69, 0x2e, 0x3b, 0x4d, 0x69,
+0x2e, 0x3b, 0x44, 0x75, 0x2e, 0x3b, 0x46, 0x72, 0x2e, 0x3b, 0x53, 0x61, 0x2e, 0x3b, 0x53, 0x75, 0x6e, 0x6e, 0x74, 0x69,
+0x67, 0x3b, 0x4d, 0xe4, 0xe4, 0x6e, 0x74, 0x69, 0x67, 0x3b, 0x5a, 0x69, 0x69, 0x73, 0x63, 0x68, 0x74, 0x69, 0x67, 0x3b,
+0x4d, 0x69, 0x74, 0x74, 0x77, 0x75, 0x63, 0x68, 0x3b, 0x44, 0x75, 0x6e, 0x73, 0x63, 0x68, 0x74, 0x69, 0x67, 0x3b, 0x46,
+0x72, 0x69, 0x69, 0x74, 0x69, 0x67, 0x3b, 0x53, 0x61, 0x6d, 0x73, 0x63, 0x68, 0x74, 0x69, 0x67, 0x3b, 0xa46d, 0xa18f, 0x3b,
+0xa18f, 0xa2cd, 0x3b, 0xa18f, 0xa44d, 0x3b, 0xa18f, 0xa315, 0x3b, 0xa18f, 0xa1d6, 0x3b, 0xa18f, 0xa26c, 0x3b, 0xa18f, 0xa0d8, 0x3b, 0xa46d, 0xa18f,
+0xa44d, 0x3b, 0xa18f, 0xa282, 0xa2cd, 0x3b, 0xa18f, 0xa282, 0xa44d, 0x3b, 0xa18f, 0xa282, 0xa315, 0x3b, 0xa18f, 0xa282, 0xa1d6, 0x3b, 0xa18f, 0xa282,
+0xa26c, 0x3b, 0xa18f, 0xa282, 0xa0d8, 0x3b, 0xa18f, 0x3b, 0xa2cd, 0x3b, 0xa44d, 0x3b, 0xa315, 0x3b, 0xa1d6, 0x3b, 0xa26c, 0x3b, 0xa0d8, 0x3b,
+0x53, 0x6f, 0x6e, 0x3b, 0x4d, 0x76, 0x75, 0x3b, 0x42, 0x69, 0x6c, 0x3b, 0x54, 0x68, 0x61, 0x3b, 0x4e, 0x65, 0x3b, 0x48,
+0x6c, 0x61, 0x3b, 0x47, 0x71, 0x69, 0x3b, 0x75, 0x53, 0x6f, 0x6e, 0x74, 0x6f, 0x3b, 0x75, 0x4d, 0x76, 0x75, 0x6c, 0x6f,
+0x3b, 0x75, 0x4c, 0x65, 0x73, 0x69, 0x62, 0x69, 0x6c, 0x69, 0x3b, 0x4c, 0x65, 0x73, 0x69, 0x74, 0x68, 0x61, 0x74, 0x68,
+0x75, 0x3b, 0x75, 0x4c, 0x65, 0x73, 0x69, 0x6e, 0x65, 0x3b, 0x6e, 0x67, 0x6f, 0x4c, 0x65, 0x73, 0x69, 0x68, 0x6c, 0x61,
+0x6e, 0x75, 0x3b, 0x75, 0x6d, 0x47, 0x71, 0x69, 0x62, 0x65, 0x6c, 0x6f, 0x3b, 0x53, 0x6f, 0x6e, 0x3b, 0x4d, 0x6f, 0x73,
+0x3b, 0x42, 0x65, 0x64, 0x3b, 0x52, 0x61, 0x72, 0x3b, 0x4e, 0x65, 0x3b, 0x48, 0x6c, 0x61, 0x3b, 0x4d, 0x6f, 0x6b, 0x3b,
+0x53, 0x6f, 0x6e, 0x74, 0x61, 0x67, 0x61, 0x3b, 0x4d, 0x6f, 0x73, 0x75, 0x70, 0x61, 0x6c, 0x6f, 0x67, 0x6f, 0x3b, 0x4c,
+0x61, 0x62, 0x6f, 0x62, 0x65, 0x64, 0x69, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x72, 0x61, 0x72, 0x6f, 0x3b, 0x4c, 0x61, 0x62,
+0x6f, 0x6e, 0x65, 0x3b, 0x4c, 0x61, 0x62, 0x6f, 0x68, 0x6c, 0x61, 0x6e, 0x6f, 0x3b, 0x4d, 0x6f, 0x6b, 0x69, 0x62, 0x65,
+0x6c, 0x6f, 0x3b, 0x73, 0x6f, 0x74, 0x6e, 0x3b, 0x76, 0x75, 0x6f, 0x73, 0x3b, 0x6d, 0x61, 0x14b, 0x3b, 0x67, 0x61, 0x73,
+0x6b, 0x3b, 0x64, 0x75, 0x6f, 0x72, 0x3b, 0x62, 0x65, 0x61, 0x72, 0x3b, 0x6c, 0xe1, 0x76, 0x3b, 0x73, 0x6f, 0x74, 0x6e,
+0x61, 0x62, 0x65, 0x61, 0x69, 0x76, 0x69, 0x3b, 0x76, 0x75, 0x6f, 0x73, 0x73, 0xe1, 0x72, 0x67, 0x61, 0x3b, 0x6d, 0x61,
+0x14b, 0x14b, 0x65, 0x62, 0xe1, 0x72, 0x67, 0x61, 0x3b, 0x67, 0x61, 0x73, 0x6b, 0x61, 0x76, 0x61, 0x68, 0x6b, 0x6b, 0x75,
+0x3b, 0x64, 0x75, 0x6f, 0x72, 0x61, 0x73, 0x64, 0x61, 0x74, 0x3b, 0x62, 0x65, 0x61, 0x72, 0x6a, 0x61, 0x64, 0x61, 0x74,
+0x3b, 0x6c, 0xe1, 0x76, 0x76, 0x61, 0x72, 0x64, 0x61, 0x74, 0x3b, 0x53, 0x3b, 0x56, 0x3b, 0x4d, 0x3b, 0x47, 0x3b, 0x44,
+0x3b, 0x42, 0x3b, 0x4c, 0x3b, 0x61, 0x65, 0x6a, 0x6c, 0x65, 0x67, 0x65, 0x3b, 0x6d, 0xe5, 0x61, 0x6e, 0x74, 0x61, 0x3b,
+0x64, 0xe4, 0x6a, 0x73, 0x74, 0x61, 0x3b, 0x67, 0x61, 0x73, 0x6b, 0x65, 0x76, 0x61, 0x68, 0x6b, 0x6f, 0x65, 0x3b, 0x64,
+0xe5, 0x61, 0x72, 0x73, 0x74, 0x61, 0x3b, 0x62, 0x65, 0x61, 0x72, 0x6a, 0x61, 0x64, 0x61, 0x68, 0x6b, 0x65, 0x3b, 0x6c,
+0x61, 0x61, 0x76, 0x61, 0x64, 0x61, 0x68, 0x6b, 0x65, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x44, 0x3b, 0x47, 0x3b, 0x44, 0x3b,
+0x42, 0x3b, 0x4c, 0x3b, 0x43, 0x70, 0x72, 0x3b, 0x43, 0x74, 0x74, 0x3b, 0x43, 0x6d, 0x6e, 0x3b, 0x43, 0x6d, 0x74, 0x3b,
+0x41, 0x72, 0x73, 0x3b, 0x49, 0x63, 0x6d, 0x3b, 0x45, 0x73, 0x74, 0x3b, 0x43, 0x68, 0x75, 0x6d, 0x61, 0x70, 0x69, 0x72,
+0x69, 0x3b, 0x43, 0x68, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x6f, 0x3b, 0x43, 0x68, 0x75, 0x6d, 0x61, 0x69, 0x6e, 0x65,
+0x3b, 0x43, 0x68, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x72, 0x61, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x49,
+0x63, 0x68, 0x75, 0x6d, 0x61, 0x3b, 0x45, 0x73, 0x61, 0x62, 0x61, 0x74, 0x6f, 0x3b, 0x43, 0x3b, 0x43, 0x3b, 0x43, 0x3b,
+0x43, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x45, 0x3b, 0x4a, 0x75, 0x6d, 0x3b, 0x4a, 0x69, 0x6d, 0x3b, 0x4b, 0x61, 0x77, 0x3b,
+0x4b, 0x61, 0x64, 0x3b, 0x4b, 0x61, 0x6e, 0x3b, 0x4b, 0x61, 0x73, 0x3b, 0x4e, 0x67, 0x75, 0x3b, 0x49, 0x74, 0x75, 0x6b,
+0x75, 0x20, 0x6a, 0x61, 0x20, 0x6a, 0x75, 0x6d, 0x77, 0x61, 0x3b, 0x4b, 0x75, 0x72, 0x61, 0x6d, 0x75, 0x6b, 0x61, 0x20,
+0x6a, 0x69, 0x6d, 0x77, 0x65, 0x72, 0x69, 0x3b, 0x4b, 0x75, 0x72, 0x61, 0x6d, 0x75, 0x6b, 0x61, 0x20, 0x6b, 0x61, 0x77,
+0x69, 0x3b, 0x4b, 0x75, 0x72, 0x61, 0x6d, 0x75, 0x6b, 0x61, 0x20, 0x6b, 0x61, 0x64, 0x61, 0x64, 0x75, 0x3b, 0x4b, 0x75,
+0x72, 0x61, 0x6d, 0x75, 0x6b, 0x61, 0x20, 0x6b, 0x61, 0x6e, 0x61, 0x3b, 0x4b, 0x75, 0x72, 0x61, 0x6d, 0x75, 0x6b, 0x61,
+0x20, 0x6b, 0x61, 0x73, 0x61, 0x6e, 0x75, 0x3b, 0x4b, 0x69, 0x66, 0x75, 0x6c, 0x61, 0x20, 0x6e, 0x67, 0x75, 0x77, 0x6f,
+0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4e, 0x3b, 0x64, 0x65, 0x77, 0x3b, 0x61,
+0x61, 0x253, 0x3b, 0x6d, 0x61, 0x77, 0x3b, 0x6e, 0x6a, 0x65, 0x3b, 0x6e, 0x61, 0x61, 0x3b, 0x6d, 0x77, 0x64, 0x3b, 0x68,
+0x62, 0x69, 0x3b, 0x64, 0x65, 0x77, 0x6f, 0x3b, 0x61, 0x61, 0x253, 0x6e, 0x64, 0x65, 0x3b, 0x6d, 0x61, 0x77, 0x62, 0x61,
+0x61, 0x72, 0x65, 0x3b, 0x6e, 0x6a, 0x65, 0x73, 0x6c, 0x61, 0x61, 0x72, 0x65, 0x3b, 0x6e, 0x61, 0x61, 0x73, 0x61, 0x61,
+0x6e, 0x64, 0x65, 0x3b, 0x6d, 0x61, 0x77, 0x6e, 0x64, 0x65, 0x3b, 0x68, 0x6f, 0x6f, 0x72, 0x65, 0x2d, 0x62, 0x69, 0x69,
+0x72, 0x3b, 0x64, 0x3b, 0x61, 0x3b, 0x6d, 0x3b, 0x6e, 0x3b, 0x6e, 0x3b, 0x6d, 0x3b, 0x68, 0x3b, 0x4b, 0x4d, 0x41, 0x3b,
+0x4e, 0x54, 0x54, 0x3b, 0x4e, 0x4d, 0x4e, 0x3b, 0x4e, 0x4d, 0x54, 0x3b, 0x41, 0x52, 0x54, 0x3b, 0x4e, 0x4d, 0x41, 0x3b,
+0x4e, 0x4d, 0x4d, 0x3b, 0x4b, 0x69, 0x75, 0x6d, 0x69, 0x61, 0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x169,
+0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61, 0x69, 0x6e, 0x65, 0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x61, 0x3b,
+0x41, 0x72, 0x61, 0x6d, 0x69, 0x74, 0x68, 0x69, 0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61, 0x61, 0x3b, 0x4e, 0x6a, 0x75, 0x6d,
+0x61, 0x6d, 0x6f, 0x74, 0x68, 0x69, 0x3b, 0x4b, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x41, 0x3b, 0x4e, 0x3b, 0x4e,
+0x3b, 0x41, 0x72, 0x65, 0x3b, 0x4b, 0x75, 0x6e, 0x3b, 0x4f, 0x6e, 0x67, 0x3b, 0x49, 0x6e, 0x65, 0x3b, 0x49, 0x6c, 0x65,
+0x3b, 0x53, 0x61, 0x70, 0x3b, 0x4b, 0x77, 0x65, 0x3b, 0x4d, 0x64, 0x65, 0x72, 0x6f, 0x74, 0x20, 0x65, 0x65, 0x20, 0x61,
+0x72, 0x65, 0x3b, 0x4d, 0x64, 0x65, 0x72, 0x6f, 0x74, 0x20, 0x65, 0x65, 0x20, 0x6b, 0x75, 0x6e, 0x69, 0x3b, 0x4d, 0x64,
+0x65, 0x72, 0x6f, 0x74, 0x20, 0x65, 0x65, 0x20, 0x6f, 0x6e, 0x67, 0x27, 0x77, 0x61, 0x6e, 0x3b, 0x4d, 0x64, 0x65, 0x72,
+0x6f, 0x74, 0x20, 0x65, 0x65, 0x20, 0x69, 0x6e, 0x65, 0x74, 0x3b, 0x4d, 0x64, 0x65, 0x72, 0x6f, 0x74, 0x20, 0x65, 0x65,
+0x20, 0x69, 0x6c, 0x65, 0x3b, 0x4d, 0x64, 0x65, 0x72, 0x6f, 0x74, 0x20, 0x65, 0x65, 0x20, 0x73, 0x61, 0x70, 0x61, 0x3b,
+0x4d, 0x64, 0x65, 0x72, 0x6f, 0x74, 0x20, 0x65, 0x65, 0x20, 0x6b, 0x77, 0x65, 0x3b, 0x41, 0x3b, 0x4b, 0x3b, 0x4f, 0x3b,
+0x49, 0x3b, 0x49, 0x3b, 0x53, 0x3b, 0x4b, 0x3b, 0x44, 0x69, 0x6d, 0x3b, 0x50, 0x6f, 0x73, 0x3b, 0x50, 0x69, 0x72, 0x3b,
+0x54, 0x61, 0x74, 0x3b, 0x4e, 0x61, 0x69, 0x3b, 0x53, 0x68, 0x61, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x44, 0x69, 0x6d, 0x69,
+0x6e, 0x67, 0x75, 0x3b, 0x43, 0x68, 0x69, 0x70, 0x6f, 0x73, 0x69, 0x3b, 0x43, 0x68, 0x69, 0x70, 0x69, 0x72, 0x69, 0x3b,
+0x43, 0x68, 0x69, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x43, 0x68, 0x69, 0x6e, 0x61, 0x69, 0x3b, 0x43, 0x68, 0x69, 0x73, 0x68,
+0x61, 0x6e, 0x75, 0x3b, 0x53, 0x61, 0x62, 0x75, 0x64, 0x75, 0x3b, 0x44, 0x3b, 0x50, 0x3b, 0x43, 0x3b, 0x54, 0x3b, 0x4e,
+0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x53, 0x6f, 0x6e, 0x3b, 0x4d, 0x76, 0x75, 0x3b, 0x53, 0x69, 0x62, 0x3b, 0x53, 0x69, 0x74,
+0x3b, 0x53, 0x69, 0x6e, 0x3b, 0x53, 0x69, 0x68, 0x3b, 0x4d, 0x67, 0x71, 0x3b, 0x53, 0x6f, 0x6e, 0x74, 0x6f, 0x3b, 0x4d,
+0x76, 0x75, 0x6c, 0x6f, 0x3b, 0x53, 0x69, 0x62, 0x69, 0x6c, 0x69, 0x3b, 0x53, 0x69, 0x74, 0x68, 0x61, 0x74, 0x68, 0x75,
+0x3b, 0x53, 0x69, 0x6e, 0x65, 0x3b, 0x53, 0x69, 0x68, 0x6c, 0x61, 0x6e, 0x75, 0x3b, 0x4d, 0x67, 0x71, 0x69, 0x62, 0x65,
+0x6c, 0x6f, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x49, 0x6a, 0x70,
+0x3b, 0x49, 0x6a, 0x74, 0x3b, 0x49, 0x6a, 0x6e, 0x3b, 0x49, 0x6a, 0x74, 0x6e, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x49, 0x6a,
+0x75, 0x3b, 0x49, 0x6a, 0x6d, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x70, 0x69, 0x6c, 0x69, 0x3b, 0x49, 0x6a, 0x75, 0x6d,
+0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x6e, 0x6e, 0x65, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61,
+0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x61,
+0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x32, 0x3b, 0x33, 0x3b, 0x34, 0x3b, 0x35, 0x3b, 0x36,
+0x3b, 0x37, 0x3b, 0x31, 0x3b, 0x2d30, 0x2d59, 0x2d30, 0x3b, 0x2d30, 0x2d62, 0x2d4f, 0x3b, 0x2d30, 0x2d59, 0x2d49, 0x3b, 0x2d30, 0x2d3d, 0x2d55,
+0x3b, 0x2d30, 0x2d3d, 0x2d61, 0x3b, 0x2d30, 0x2d59, 0x2d49, 0x2d4e, 0x3b, 0x2d30, 0x2d59, 0x2d49, 0x2d39, 0x3b, 0x2d30, 0x2d59, 0x2d30, 0x2d4e, 0x2d30,
+0x2d59, 0x3b, 0x2d30, 0x2d62, 0x2d4f, 0x2d30, 0x2d59, 0x3b, 0x2d30, 0x2d59, 0x2d49, 0x2d4f, 0x2d30, 0x2d59, 0x3b, 0x2d30, 0x2d3d, 0x2d55, 0x2d30, 0x2d59,
+0x3b, 0x2d30, 0x2d3d, 0x2d61, 0x2d30, 0x2d59, 0x3b, 0x2d59, 0x2d49, 0x2d4e, 0x2d61, 0x2d30, 0x2d59, 0x3b, 0x2d30, 0x2d59, 0x2d49, 0x2d39, 0x2d62, 0x2d30,
+0x2d59, 0x3b, 0x61, 0x73, 0x61, 0x3b, 0x61, 0x79, 0x6e, 0x3b, 0x61, 0x73, 0x69, 0x3b, 0x61, 0x6b, 0x1e5b, 0x3b, 0x61, 0x6b,
+0x77, 0x3b, 0x61, 0x73, 0x69, 0x6d, 0x3b, 0x61, 0x73, 0x69, 0x1e0d, 0x3b, 0x61, 0x73, 0x61, 0x6d, 0x61, 0x73, 0x3b, 0x61,
+0x79, 0x6e, 0x61, 0x73, 0x3b, 0x61, 0x73, 0x69, 0x6e, 0x61, 0x73, 0x3b, 0x61, 0x6b, 0x1e5b, 0x61, 0x73, 0x3b, 0x61, 0x6b,
+0x77, 0x61, 0x73, 0x3b, 0x61, 0x73, 0x69, 0x6d, 0x77, 0x61, 0x73, 0x3b, 0x61, 0x73, 0x69, 0x1e0d, 0x79, 0x61, 0x73, 0x3b,
+0x59, 0x61, 0x6e, 0x3b, 0x53, 0x61, 0x6e, 0x3b, 0x4b, 0x72, 0x61, 0x1e0d, 0x3b, 0x4b, 0x75, 0x1e93, 0x3b, 0x53, 0x61, 0x6d,
+0x3b, 0x53, 0x1e0d, 0x69, 0x73, 0x3b, 0x53, 0x61, 0x79, 0x3b, 0x59, 0x61, 0x6e, 0x61, 0x73, 0x73, 0x3b, 0x53, 0x61, 0x6e,
+0x61, 0x73, 0x73, 0x3b, 0x4b, 0x72, 0x61, 0x1e0d, 0x61, 0x73, 0x73, 0x3b, 0x4b, 0x75, 0x1e93, 0x61, 0x73, 0x73, 0x3b, 0x53,
+0x61, 0x6d, 0x61, 0x73, 0x73, 0x3b, 0x53, 0x1e0d, 0x69, 0x73, 0x61, 0x73, 0x73, 0x3b, 0x53, 0x61, 0x79, 0x61, 0x73, 0x73,
+0x3b, 0x59, 0x3b, 0x53, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x53, 0x3b, 0x53, 0x41, 0x4e, 0x3b, 0x4f,
+0x52, 0x4b, 0x3b, 0x4f, 0x4b, 0x42, 0x3b, 0x4f, 0x4b, 0x53, 0x3b, 0x4f, 0x4b, 0x4e, 0x3b, 0x4f, 0x4b, 0x54, 0x3b, 0x4f,
+0x4d, 0x4b, 0x3b, 0x53, 0x61, 0x6e, 0x64, 0x65, 0x3b, 0x4f, 0x72, 0x77, 0x6f, 0x6b, 0x75, 0x62, 0x61, 0x6e, 0x7a, 0x61,
+0x3b, 0x4f, 0x72, 0x77, 0x61, 0x6b, 0x61, 0x62, 0x69, 0x72, 0x69, 0x3b, 0x4f, 0x72, 0x77, 0x61, 0x6b, 0x61, 0x73, 0x68,
+0x61, 0x74, 0x75, 0x3b, 0x4f, 0x72, 0x77, 0x61, 0x6b, 0x61, 0x6e, 0x61, 0x3b, 0x4f, 0x72, 0x77, 0x61, 0x6b, 0x61, 0x74,
+0x61, 0x61, 0x6e, 0x6f, 0x3b, 0x4f, 0x72, 0x77, 0x61, 0x6d, 0x75, 0x6b, 0x61, 0x61, 0x67, 0x61, 0x3b, 0x53, 0x3b, 0x4b,
+0x3b, 0x52, 0x3b, 0x53, 0x3b, 0x4e, 0x3b, 0x54, 0x3b, 0x4d, 0x3b, 0x4d, 0x75, 0x6c, 0x3b, 0x56, 0x69, 0x6c, 0x3b, 0x48,
+0x69, 0x76, 0x3b, 0x48, 0x69, 0x64, 0x3b, 0x48, 0x69, 0x74, 0x3b, 0x48, 0x69, 0x68, 0x3b, 0x4c, 0x65, 0x6d, 0x3b, 0x70,
+0x61, 0x20, 0x6d, 0x75, 0x6c, 0x75, 0x6e, 0x67, 0x75, 0x3b, 0x70, 0x61, 0x20, 0x73, 0x68, 0x61, 0x68, 0x75, 0x76, 0x69,
+0x6c, 0x75, 0x68, 0x61, 0x3b, 0x70, 0x61, 0x20, 0x68, 0x69, 0x76, 0x69, 0x6c, 0x69, 0x3b, 0x70, 0x61, 0x20, 0x68, 0x69,
+0x64, 0x61, 0x74, 0x75, 0x3b, 0x70, 0x61, 0x20, 0x68, 0x69, 0x74, 0x61, 0x79, 0x69, 0x3b, 0x70, 0x61, 0x20, 0x68, 0x69,
+0x68, 0x61, 0x6e, 0x75, 0x3b, 0x70, 0x61, 0x20, 0x73, 0x68, 0x61, 0x68, 0x75, 0x6c, 0x65, 0x6d, 0x62, 0x65, 0x6c, 0x61,
+0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x48, 0x3b, 0x48, 0x3b, 0x48, 0x3b, 0x57, 0x3b, 0x4a, 0x3b, 0x4a, 0x70, 0x69, 0x3b, 0x4a,
+0x74, 0x74, 0x3b, 0x4a, 0x6e, 0x6e, 0x3b, 0x4a, 0x74, 0x6e, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x49, 0x6a, 0x75, 0x3b, 0x4a,
+0x6d, 0x6f, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x70, 0x69, 0x6c, 0x79, 0x69, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74,
+0x75, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6e, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x75, 0x3b,
+0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x61, 0x3b, 0x4a, 0x75, 0x6d, 0x61,
+0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x4a, 0x3b, 0x6b,
+0x61, 0x72, 0x3b, 0x6e, 0x74, 0x25b, 0x3b, 0x74, 0x61, 0x72, 0x3b, 0x61, 0x72, 0x61, 0x3b, 0x61, 0x6c, 0x61, 0x3b, 0x6a,
+0x75, 0x6d, 0x3b, 0x73, 0x69, 0x62, 0x3b, 0x6b, 0x61, 0x72, 0x69, 0x3b, 0x6e, 0x74, 0x25b, 0x6e, 0x25b, 0x3b, 0x74, 0x61,
+0x72, 0x61, 0x74, 0x61, 0x3b, 0x61, 0x72, 0x61, 0x62, 0x61, 0x3b, 0x61, 0x6c, 0x61, 0x6d, 0x69, 0x73, 0x61, 0x3b, 0x6a,
+0x75, 0x6d, 0x61, 0x3b, 0x73, 0x69, 0x62, 0x69, 0x72, 0x69, 0x3b, 0x4b, 0x3b, 0x4e, 0x3b, 0x54, 0x3b, 0x41, 0x3b, 0x41,
+0x3b, 0x4a, 0x3b, 0x53, 0x3b, 0x4b, 0x6d, 0x61, 0x3b, 0x54, 0x61, 0x74, 0x3b, 0x49, 0x6e, 0x65, 0x3b, 0x54, 0x61, 0x6e,
+0x3b, 0x41, 0x72, 0x6d, 0x3b, 0x4d, 0x61, 0x61, 0x3b, 0x4e, 0x4d, 0x4d, 0x3b, 0x4b, 0x69, 0x75, 0x6d, 0x69, 0x61, 0x3b,
+0x4e, 0x6a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x4e, 0x6a, 0x75, 0x6d, 0x61, 0x69, 0x6e, 0x65, 0x3b, 0x4e,
+0x6a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x72, 0x61, 0x6d, 0x69, 0x74, 0x68, 0x69, 0x3b, 0x4e, 0x6a,
+0x75, 0x6d, 0x61, 0x61, 0x3b, 0x4e, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x74, 0x68, 0x69, 0x69, 0x3b, 0x4b, 0x3b, 0x4e,
+0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4e, 0x3b, 0x13c6, 0x13cd, 0x13ac, 0x3b, 0x13c9, 0x13c5, 0x13af, 0x3b, 0x13d4,
+0x13b5, 0x13c1, 0x3b, 0x13e6, 0x13a2, 0x13c1, 0x3b, 0x13c5, 0x13a9, 0x13c1, 0x3b, 0x13e7, 0x13be, 0x13a9, 0x3b, 0x13c8, 0x13d5, 0x13be, 0x3b, 0x13a4,
+0x13be, 0x13d9, 0x13d3, 0x13c6, 0x13cd, 0x13ac, 0x3b, 0x13a4, 0x13be, 0x13d9, 0x13d3, 0x13c9, 0x13c5, 0x13af, 0x3b, 0x13d4, 0x13b5, 0x13c1, 0x13a2, 0x13a6,
+0x3b, 0x13e6, 0x13a2, 0x13c1, 0x13a2, 0x13a6, 0x3b, 0x13c5, 0x13a9, 0x13c1, 0x13a2, 0x13a6, 0x3b, 0x13e7, 0x13be, 0x13a9, 0x13b6, 0x13cd, 0x13d7, 0x3b,
+0x13a4, 0x13be, 0x13d9, 0x13d3, 0x13c8, 0x13d5, 0x13be, 0x3b, 0x13c6, 0x3b, 0x13c9, 0x3b, 0x13d4, 0x3b, 0x13e6, 0x3b, 0x13c5, 0x3b, 0x13e7, 0x3b,
+0x13a4, 0x3b, 0x64, 0x69, 0x6d, 0x3b, 0x6c, 0x69, 0x6e, 0x3b, 0x6d, 0x61, 0x72, 0x3b, 0x6d, 0x65, 0x72, 0x3b, 0x7a, 0x65,
+0x3b, 0x76, 0x61, 0x6e, 0x3b, 0x73, 0x61, 0x6d, 0x3b, 0x64, 0x69, 0x6d, 0x61, 0x6e, 0x73, 0x3b, 0x6c, 0x69, 0x6e, 0x64,
+0x69, 0x3b, 0x6d, 0x61, 0x72, 0x64, 0x69, 0x3b, 0x6d, 0x65, 0x72, 0x6b, 0x72, 0x65, 0x64, 0x69, 0x3b, 0x7a, 0x65, 0x64,
+0x69, 0x3b, 0x76, 0x61, 0x6e, 0x64, 0x72, 0x65, 0x64, 0x69, 0x3b, 0x73, 0x61, 0x6d, 0x64, 0x69, 0x3b, 0x64, 0x3b, 0x6c,
+0x3b, 0x6d, 0x3b, 0x6d, 0x3b, 0x7a, 0x3b, 0x76, 0x3b, 0x73, 0x3b, 0x4c, 0x6c, 0x32, 0x3b, 0x4c, 0x6c, 0x33, 0x3b, 0x4c,
+0x6c, 0x34, 0x3b, 0x4c, 0x6c, 0x35, 0x3b, 0x4c, 0x6c, 0x36, 0x3b, 0x4c, 0x6c, 0x37, 0x3b, 0x4c, 0x6c, 0x31, 0x3b, 0x4c,
+0x69, 0x64, 0x75, 0x76, 0x61, 0x20, 0x6c, 0x79, 0x61, 0x70, 0x69, 0x6c, 0x69, 0x3b, 0x4c, 0x69, 0x64, 0x75, 0x76, 0x61,
+0x20, 0x6c, 0x79, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x4c, 0x69, 0x64, 0x75, 0x76, 0x61, 0x20, 0x6c, 0x79, 0x61, 0x6e,
+0x63, 0x68, 0x65, 0x63, 0x68, 0x69, 0x3b, 0x4c, 0x69, 0x64, 0x75, 0x76, 0x61, 0x20, 0x6c, 0x79, 0x61, 0x6e, 0x6e, 0x79,
+0x61, 0x6e, 0x6f, 0x3b, 0x4c, 0x69, 0x64, 0x75, 0x76, 0x61, 0x20, 0x6c, 0x79, 0x61, 0x6e, 0x6e, 0x79, 0x61, 0x6e, 0x6f,
+0x20, 0x6e, 0x61, 0x20, 0x6c, 0x69, 0x6e, 0x6a, 0x69, 0x3b, 0x4c, 0x69, 0x64, 0x75, 0x76, 0x61, 0x20, 0x6c, 0x79, 0x61,
+0x6e, 0x6e, 0x79, 0x61, 0x6e, 0x6f, 0x20, 0x6e, 0x61, 0x20, 0x6d, 0x61, 0x76, 0x69, 0x6c, 0x69, 0x3b, 0x4c, 0x69, 0x64,
+0x75, 0x76, 0x61, 0x20, 0x6c, 0x69, 0x74, 0x61, 0x6e, 0x64, 0x69, 0x3b, 0x50, 0xed, 0x69, 0x6c, 0x69, 0x3b, 0x54, 0xe1,
+0x61, 0x74, 0x75, 0x3b, 0xcd, 0x6e, 0x65, 0x3b, 0x54, 0xe1, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x49, 0x6a,
+0x6d, 0x3b, 0x4d, 0xf3, 0x6f, 0x73, 0x69, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x70, 0xed, 0x69, 0x72, 0x69, 0x3b, 0x4a, 0x75,
+0x6d, 0x61, 0x74, 0xe1, 0x74, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0xed, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74,
+0xe1, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x6c, 0x61, 0x6d, 0xed, 0x69, 0x73, 0x69, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0xe1, 0x61,
+0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0xf3, 0x6f, 0x73, 0x69, 0x3b, 0x50, 0x3b, 0x54, 0x3b, 0x45, 0x3b, 0x4f, 0x3b, 0x41,
+0x3b, 0x49, 0x3b, 0x4d, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x42, 0x61, 0x6c, 0x3b, 0x4c, 0x77, 0x32, 0x3b, 0x4c, 0x77, 0x33,
+0x3b, 0x4c, 0x77, 0x34, 0x3b, 0x4c, 0x77, 0x35, 0x3b, 0x4c, 0x77, 0x36, 0x3b, 0x53, 0x61, 0x62, 0x62, 0x69, 0x69, 0x74,
+0x69, 0x3b, 0x42, 0x61, 0x6c, 0x61, 0x7a, 0x61, 0x3b, 0x4c, 0x77, 0x61, 0x6b, 0x75, 0x62, 0x69, 0x72, 0x69, 0x3b, 0x4c,
+0x77, 0x61, 0x6b, 0x75, 0x73, 0x61, 0x74, 0x75, 0x3b, 0x4c, 0x77, 0x61, 0x6b, 0x75, 0x6e, 0x61, 0x3b, 0x4c, 0x77, 0x61,
+0x6b, 0x75, 0x74, 0x61, 0x61, 0x6e, 0x6f, 0x3b, 0x4c, 0x77, 0x61, 0x6d, 0x75, 0x6b, 0x61, 0x61, 0x67, 0x61, 0x3b, 0x53,
+0x3b, 0x42, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x4c, 0x3b, 0x50, 0x61, 0x20, 0x4d, 0x75, 0x6c, 0x75,
+0x6e, 0x67, 0x75, 0x3b, 0x50, 0x61, 0x6c, 0x69, 0x63, 0x68, 0x69, 0x6d, 0x6f, 0x3b, 0x50, 0x61, 0x6c, 0x69, 0x63, 0x68,
+0x69, 0x62, 0x75, 0x6c, 0x69, 0x3b, 0x50, 0x61, 0x6c, 0x69, 0x63, 0x68, 0x69, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x50, 0x61,
+0x6c, 0x69, 0x63, 0x68, 0x69, 0x6e, 0x65, 0x3b, 0x50, 0x61, 0x6c, 0x69, 0x63, 0x68, 0x69, 0x73, 0x61, 0x6e, 0x6f, 0x3b,
+0x50, 0x61, 0x63, 0x68, 0x69, 0x62, 0x65, 0x6c, 0x75, 0x73, 0x68, 0x69, 0x3b, 0x64, 0x75, 0x6d, 0x3b, 0x73, 0x69, 0x67,
+0x3b, 0x74, 0x65, 0x72, 0x3b, 0x6b, 0x75, 0x61, 0x3b, 0x6b, 0x69, 0x6e, 0x3b, 0x73, 0x65, 0x73, 0x3b, 0x73, 0x61, 0x62,
+0x3b, 0x64, 0x75, 0x6d, 0x69, 0x6e, 0x67, 0x75, 0x3b, 0x73, 0x69, 0x67, 0x75, 0x6e, 0x64, 0x61, 0x2d, 0x66, 0x65, 0x72,
+0x61, 0x3b, 0x74, 0x65, 0x72, 0x73, 0x61, 0x2d, 0x66, 0x65, 0x72, 0x61, 0x3b, 0x6b, 0x75, 0x61, 0x72, 0x74, 0x61, 0x2d,
+0x66, 0x65, 0x72, 0x61, 0x3b, 0x6b, 0x69, 0x6e, 0x74, 0x61, 0x2d, 0x66, 0x65, 0x72, 0x61, 0x3b, 0x73, 0x65, 0x73, 0x74,
+0x61, 0x2d, 0x66, 0x65, 0x72, 0x61, 0x3b, 0x73, 0x61, 0x62, 0x61, 0x64, 0x75, 0x3b, 0x64, 0x3b, 0x73, 0x3b, 0x74, 0x3b,
+0x6b, 0x3b, 0x6b, 0x3b, 0x73, 0x3b, 0x73, 0x3b, 0x4b, 0x49, 0x55, 0x3b, 0x4d, 0x52, 0x41, 0x3b, 0x57, 0x41, 0x49, 0x3b,
+0x57, 0x45, 0x54, 0x3b, 0x57, 0x45, 0x4e, 0x3b, 0x57, 0x54, 0x4e, 0x3b, 0x4a, 0x55, 0x4d, 0x3b, 0x4b, 0x69, 0x75, 0x6d,
+0x69, 0x61, 0x3b, 0x4d, 0x75, 0x72, 0x61, 0x6d, 0x75, 0x6b, 0x6f, 0x3b, 0x57, 0x61, 0x69, 0x72, 0x69, 0x3b, 0x57, 0x65,
+0x74, 0x68, 0x61, 0x74, 0x75, 0x3b, 0x57, 0x65, 0x6e, 0x61, 0x3b, 0x57, 0x65, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x4a, 0x75,
+0x6d, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x4b, 0x3b, 0x4d, 0x3b, 0x57, 0x3b, 0x57, 0x3b, 0x57, 0x3b, 0x57, 0x3b, 0x4a,
+0x3b, 0x54, 0x69, 0x73, 0x3b, 0x54, 0x61, 0x69, 0x3b, 0x41, 0x65, 0x6e, 0x3b, 0x53, 0x6f, 0x6d, 0x3b, 0x41, 0x6e, 0x67,
+0x3b, 0x4d, 0x75, 0x74, 0x3b, 0x4c, 0x6f, 0x68, 0x3b, 0x42, 0x65, 0x74, 0x75, 0x74, 0x61, 0x62, 0x20, 0x74, 0x69, 0x73,
+0x61, 0x70, 0x3b, 0x42, 0x65, 0x74, 0x75, 0x74, 0x20, 0x6e, 0x65, 0x74, 0x61, 0x69, 0x3b, 0x42, 0x65, 0x74, 0x75, 0x74,
+0x61, 0x62, 0x20, 0x61, 0x65, 0x6e, 0x67, 0x27, 0x3b, 0x42, 0x65, 0x74, 0x75, 0x74, 0x61, 0x62, 0x20, 0x73, 0x6f, 0x6d,
+0x6f, 0x6b, 0x3b, 0x42, 0x65, 0x74, 0x75, 0x74, 0x61, 0x62, 0x20, 0x61, 0x6e, 0x67, 0x27, 0x77, 0x61, 0x6e, 0x3b, 0x42,
+0x65, 0x74, 0x75, 0x74, 0x61, 0x62, 0x20, 0x6d, 0x75, 0x74, 0x3b, 0x42, 0x65, 0x74, 0x75, 0x74, 0x61, 0x62, 0x20, 0x6c,
+0x6f, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x41, 0x3b, 0x4d, 0x3b, 0x4c, 0x3b, 0x53, 0x6f, 0x6e, 0x3b,
+0x4d, 0x61, 0x3b, 0x44, 0x65, 0x3b, 0x57, 0x75, 0x3b, 0x44, 0x6f, 0x3b, 0x46, 0x72, 0x3b, 0x53, 0x61, 0x74, 0x3b, 0x53,
+0x6f, 0x6e, 0x74, 0x61, 0x78, 0x74, 0x73, 0x65, 0x65, 0x73, 0x3b, 0x4d, 0x61, 0x6e, 0x74, 0x61, 0x78, 0x74, 0x73, 0x65,
+0x65, 0x73, 0x3b, 0x44, 0x65, 0x6e, 0x73, 0x74, 0x61, 0x78, 0x74, 0x73, 0x65, 0x65, 0x73, 0x3b, 0x57, 0x75, 0x6e, 0x73,
+0x74, 0x61, 0x78, 0x74, 0x73, 0x65, 0x65, 0x73, 0x3b, 0x44, 0x6f, 0x6e, 0x64, 0x65, 0x72, 0x74, 0x61, 0x78, 0x74, 0x73,
+0x65, 0x65, 0x73, 0x3b, 0x46, 0x72, 0x61, 0x69, 0x74, 0x61, 0x78, 0x74, 0x73, 0x65, 0x65, 0x73, 0x3b, 0x53, 0x61, 0x74,
+0x65, 0x72, 0x74, 0x61, 0x78, 0x74, 0x73, 0x65, 0x65, 0x73, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x45, 0x3b, 0x57, 0x3b, 0x44,
+0x3b, 0x46, 0x3b, 0x41, 0x3b, 0x53, 0x75, 0x2e, 0x3b, 0x4d, 0x6f, 0x2e, 0x3b, 0x44, 0x69, 0x2e, 0x3b, 0x4d, 0x65, 0x2e,
+0x3b, 0x44, 0x75, 0x2e, 0x3b, 0x46, 0x72, 0x2e, 0x3b, 0x53, 0x61, 0x2e, 0x3b, 0x53, 0x75, 0x6e, 0x6e, 0x64, 0x61, 0x61,
+0x63, 0x68, 0x3b, 0x4d, 0x6f, 0x6f, 0x6e, 0x64, 0x61, 0x61, 0x63, 0x68, 0x3b, 0x44, 0x69, 0x6e, 0x6e, 0x73, 0x64, 0x61,
+0x61, 0x63, 0x68, 0x3b, 0x4d, 0x65, 0x74, 0x77, 0x6f, 0x63, 0x68, 0x3b, 0x44, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x73, 0x64,
+0x61, 0x61, 0x63, 0x68, 0x3b, 0x46, 0x72, 0x69, 0x69, 0x64, 0x61, 0x61, 0x63, 0x68, 0x3b, 0x53, 0x61, 0x6d, 0x73, 0x64,
+0x61, 0x61, 0x63, 0x68, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x70, 0xed, 0x6c, 0xed, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0xe1,
+0x74, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0xe1, 0x6e, 0x254, 0x3b, 0x41,
+0x6c, 0x61, 0xe1, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x4a, 0x75, 0x6d, 0xe1, 0x61, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0xf3,
+0x73, 0x69, 0x3b, 0x53, 0x61, 0x62, 0x69, 0x3b, 0x42, 0x61, 0x6c, 0x61, 0x3b, 0x4b, 0x75, 0x62, 0x69, 0x3b, 0x4b, 0x75,
+0x73, 0x61, 0x3b, 0x4b, 0x75, 0x6e, 0x61, 0x3b, 0x4b, 0x75, 0x74, 0x61, 0x3b, 0x4d, 0x75, 0x6b, 0x61, 0x3b, 0x53, 0x61,
+0x62, 0x69, 0x69, 0x74, 0x69, 0x3b, 0x42, 0x61, 0x6c, 0x61, 0x7a, 0x61, 0x3b, 0x4f, 0x77, 0x6f, 0x6b, 0x75, 0x62, 0x69,
+0x6c, 0x69, 0x3b, 0x4f, 0x77, 0x6f, 0x6b, 0x75, 0x73, 0x61, 0x74, 0x75, 0x3b, 0x4f, 0x6c, 0x6f, 0x6b, 0x75, 0x6e, 0x61,
+0x3b, 0x4f, 0x6c, 0x6f, 0x6b, 0x75, 0x74, 0x61, 0x61, 0x6e, 0x75, 0x3b, 0x4f, 0x6c, 0x6f, 0x6d, 0x75, 0x6b, 0x61, 0x61,
+0x67, 0x61, 0x3b, 0x53, 0x3b, 0x42, 0x3b, 0x42, 0x3b, 0x53, 0x3b, 0x4b, 0x3b, 0x4b, 0x3b, 0x4d, 0x3b, 0x4a, 0x32, 0x3b,
+0x4a, 0x33, 0x3b, 0x4a, 0x34, 0x3b, 0x4a, 0x35, 0x3b, 0x41, 0x6c, 0x3b, 0x49, 0x6a, 0x3b, 0x4a, 0x31, 0x3b, 0x4a, 0x75,
+0x6d, 0x61, 0x70, 0x69, 0x72, 0x69, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61,
+0x6e, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x4d, 0x75, 0x72, 0x77, 0x61, 0x20, 0x77,
+0x61, 0x20, 0x4b, 0x61, 0x6e, 0x6e, 0x65, 0x3b, 0x4d, 0x75, 0x72, 0x77, 0x61, 0x20, 0x77, 0x61, 0x20, 0x4b, 0x61, 0x74,
+0x61, 0x6e, 0x6f, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x4a, 0x70, 0x69, 0x3b, 0x4a, 0x74, 0x74,
+0x3b, 0x4a, 0x6e, 0x6e, 0x3b, 0x4a, 0x74, 0x6e, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x49, 0x6a, 0x6d, 0x3b, 0x4a, 0x6d, 0x6f,
+0x3b, 0x4a, 0x75, 0x6d, 0x3b, 0x42, 0x61, 0x72, 0x3b, 0x41, 0x61, 0x72, 0x3b, 0x55, 0x6e, 0x69, 0x3b, 0x55, 0x6e, 0x67,
+0x3b, 0x4b, 0x61, 0x6e, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x4e, 0x61, 0x6b, 0x61, 0x65, 0x6a, 0x75, 0x6d, 0x61, 0x3b, 0x4e,
+0x61, 0x6b, 0x61, 0x65, 0x62, 0x61, 0x72, 0x61, 0x73, 0x61, 0x3b, 0x4e, 0x61, 0x6b, 0x61, 0x61, 0x72, 0x65, 0x3b, 0x4e,
+0x61, 0x6b, 0x61, 0x75, 0x6e, 0x69, 0x3b, 0x4e, 0x61, 0x6b, 0x61, 0x75, 0x6e, 0x67, 0x27, 0x6f, 0x6e, 0x3b, 0x4e, 0x61,
+0x6b, 0x61, 0x6b, 0x61, 0x6e, 0x79, 0x3b, 0x4e, 0x61, 0x6b, 0x61, 0x73, 0x61, 0x62, 0x69, 0x74, 0x69, 0x3b, 0x4a, 0x3b,
+0x42, 0x3b, 0x41, 0x3b, 0x55, 0x3b, 0x55, 0x3b, 0x4b, 0x3b, 0x53, 0x3b, 0x4e, 0x61, 0x62, 0x3b, 0x53, 0x61, 0x6e, 0x3b,
+0x53, 0x61, 0x6c, 0x3b, 0x52, 0x61, 0x62, 0x3b, 0x43, 0x61, 0x6d, 0x3b, 0x4a, 0x75, 0x6d, 0x3b, 0x51, 0x75, 0x6e, 0x3b,
+0x4e, 0x61, 0x62, 0x61, 0x20, 0x53, 0x61, 0x6d, 0x62, 0x61, 0x74, 0x3b, 0x53, 0x61, 0x6e, 0x69, 0x3b, 0x53, 0x61, 0x6c,
+0x75, 0x73, 0x3b, 0x52, 0x61, 0x62, 0x75, 0x71, 0x3b, 0x43, 0x61, 0x6d, 0x75, 0x73, 0x3b, 0x4a, 0x75, 0x6d, 0x71, 0x61,
+0x74, 0x61, 0x3b, 0x51, 0x75, 0x6e, 0x78, 0x61, 0x20, 0x53, 0x61, 0x6d, 0x62, 0x61, 0x74, 0x3b, 0x4e, 0x3b, 0x53, 0x3b,
+0x53, 0x3b, 0x52, 0x3b, 0x43, 0x3b, 0x4a, 0x3b, 0x51, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x41, 0x74, 0x69, 0x3b, 0x41, 0x74,
+0x61, 0x3b, 0x41, 0x6c, 0x61, 0x3b, 0x41, 0x6c, 0x6d, 0x3b, 0x41, 0x6c, 0x6a, 0x3b, 0x41, 0x73, 0x73, 0x3b, 0x41, 0x6c,
+0x68, 0x61, 0x64, 0x69, 0x3b, 0x41, 0x74, 0x69, 0x6e, 0x69, 0x3b, 0x41, 0x74, 0x61, 0x6c, 0x61, 0x74, 0x61, 0x3b, 0x41,
+0x6c, 0x61, 0x72, 0x62, 0x61, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x69, 0x73, 0x61, 0x3b, 0x41, 0x6c, 0x6a, 0x75,
+0x6d, 0x61, 0x3b, 0x41, 0x73, 0x73, 0x61, 0x62, 0x64, 0x75, 0x3b, 0x48, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x4c, 0x3b, 0x4c,
+0x3b, 0x4c, 0x3b, 0x53, 0x3b, 0x4a, 0x4d, 0x50, 0x3b, 0x57, 0x55, 0x54, 0x3b, 0x54, 0x41, 0x52, 0x3b, 0x54, 0x41, 0x44,
+0x3b, 0x54, 0x41, 0x4e, 0x3b, 0x54, 0x41, 0x42, 0x3b, 0x4e, 0x47, 0x53, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x70, 0x69, 0x6c,
+0x3b, 0x57, 0x75, 0x6f, 0x6b, 0x20, 0x54, 0x69, 0x63, 0x68, 0x3b, 0x54, 0x69, 0x63, 0x68, 0x20, 0x41, 0x72, 0x69, 0x79,
+0x6f, 0x3b, 0x54, 0x69, 0x63, 0x68, 0x20, 0x41, 0x64, 0x65, 0x6b, 0x3b, 0x54, 0x69, 0x63, 0x68, 0x20, 0x41, 0x6e, 0x67,
+0x27, 0x77, 0x65, 0x6e, 0x3b, 0x54, 0x69, 0x63, 0x68, 0x20, 0x41, 0x62, 0x69, 0x63, 0x68, 0x3b, 0x4e, 0x67, 0x65, 0x73,
+0x6f, 0x3b, 0x4a, 0x3b, 0x57, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x54, 0x3b, 0x4e, 0x3b, 0x41, 0x73, 0x61, 0x3b,
+0x41, 0x79, 0x6e, 0x3b, 0x41, 0x73, 0x6e, 0x3b, 0x41, 0x6b, 0x72, 0x3b, 0x41, 0x6b, 0x77, 0x3b, 0x41, 0x73, 0x6d, 0x3b,
+0x41, 0x73, 0x1e0d, 0x3b, 0x41, 0x73, 0x61, 0x6d, 0x61, 0x73, 0x3b, 0x41, 0x79, 0x6e, 0x61, 0x73, 0x3b, 0x41, 0x73, 0x69,
+0x6e, 0x61, 0x73, 0x3b, 0x41, 0x6b, 0x72, 0x61, 0x73, 0x3b, 0x41, 0x6b, 0x77, 0x61, 0x73, 0x3b, 0x41, 0x73, 0x69, 0x6d,
+0x77, 0x61, 0x73, 0x3b, 0x41, 0x73, 0x69, 0x1e0d, 0x79, 0x61, 0x73, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b,
+0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x41, 0x74, 0x69, 0x3b, 0x41, 0x74, 0x61, 0x3b, 0x41, 0x6c,
+0x61, 0x3b, 0x41, 0x6c, 0x6d, 0x3b, 0x41, 0x6c, 0x7a, 0x3b, 0x41, 0x73, 0x69, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x64, 0x69,
+0x3b, 0x41, 0x74, 0x69, 0x6e, 0x6e, 0x69, 0x3b, 0x41, 0x74, 0x61, 0x6c, 0x61, 0x61, 0x74, 0x61, 0x3b, 0x41, 0x6c, 0x61,
+0x72, 0x62, 0x61, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x69, 0x73, 0x61, 0x3b, 0x41, 0x6c, 0x7a, 0x75, 0x6d, 0x61,
+0x3b, 0x41, 0x73, 0x69, 0x62, 0x74, 0x69, 0x3b, 0x4a, 0x70, 0x69, 0x3b, 0x4a, 0x74, 0x74, 0x3b, 0x4a, 0x6d, 0x6e, 0x3b,
+0x4a, 0x74, 0x6e, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x49, 0x6a, 0x75, 0x3b, 0x4a, 0x6d, 0x6f, 0x3b, 0x4a, 0x75, 0x6d, 0x61,
+0x61, 0x70, 0x69, 0x69, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x61,
+0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x73,
+0x69, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x61, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x930,
+0x92c, 0x93f, 0x3b, 0x938, 0x92e, 0x3b, 0x92e, 0x902, 0x917, 0x932, 0x3b, 0x92c, 0x941, 0x926, 0x3b, 0x92c, 0x93f, 0x938, 0x925, 0x93f,
+0x3b, 0x938, 0x941, 0x916, 0x941, 0x930, 0x3b, 0x938, 0x941, 0x928, 0x93f, 0x3b, 0x930, 0x92c, 0x93f, 0x92c, 0x93e, 0x930, 0x3b, 0x938,
+0x92e, 0x92c, 0x93e, 0x930, 0x3b, 0x92e, 0x902, 0x917, 0x932, 0x92c, 0x93e, 0x930, 0x3b, 0x92c, 0x941, 0x926, 0x92c, 0x93e, 0x930, 0x3b,
+0x92c, 0x93f, 0x938, 0x925, 0x93f, 0x92c, 0x93e, 0x930, 0x3b, 0x938, 0x941, 0x916, 0x941, 0x930, 0x92c, 0x93e, 0x930, 0x3b, 0x938, 0x941,
+0x928, 0x93f, 0x92c, 0x93e, 0x930, 0x3b, 0x930, 0x3b, 0x938, 0x3b, 0x92e, 0x902, 0x3b, 0x92c, 0x941, 0x3b, 0x92c, 0x93f, 0x3b, 0x938,
+0x941, 0x3b, 0x938, 0x941, 0x3b, 0x4c, 0x75, 0x6d, 0x3b, 0x4e, 0x6b, 0x6f, 0x3b, 0x4e, 0x64, 0x79, 0x3b, 0x4e, 0x64, 0x67,
+0x3b, 0x4e, 0x6a, 0x77, 0x3b, 0x4e, 0x67, 0x76, 0x3b, 0x4c, 0x75, 0x62, 0x3b, 0x4c, 0x75, 0x6d, 0x69, 0x6e, 0x67, 0x75,
+0x3b, 0x4e, 0x6b, 0x6f, 0x64, 0x79, 0x61, 0x3b, 0x4e, 0x64, 0xe0, 0x61, 0x79, 0xe0, 0x3b, 0x4e, 0x64, 0x61, 0x6e, 0x67,
+0xf9, 0x3b, 0x4e, 0x6a, 0xf2, 0x77, 0x61, 0x3b, 0x4e, 0x67, 0xf2, 0x76, 0x79, 0x61, 0x3b, 0x4c, 0x75, 0x62, 0x69, 0x6e,
+0x67, 0x75, 0x3b, 0x4c, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4e, 0x3b, 0x4c, 0x3b, 0x6e, 0x74, 0x73,
+0x3b, 0x6b, 0x70, 0x61, 0x3b, 0x67, 0x68, 0x254, 0x3b, 0x74, 0x254, 0x6d, 0x3b, 0x75, 0x6d, 0x65, 0x3b, 0x67, 0x68, 0x268,
+0x3b, 0x64, 0x7a, 0x6b, 0x3b, 0x74, 0x73, 0x75, 0x294, 0x6e, 0x74, 0x73, 0x268, 0x3b, 0x74, 0x73, 0x75, 0x294, 0x75, 0x6b,
+0x70, 0xe0, 0x3b, 0x74, 0x73, 0x75, 0x294, 0x75, 0x67, 0x68, 0x254, 0x65, 0x3b, 0x74, 0x73, 0x75, 0x294, 0x75, 0x74, 0x254,
+0x300, 0x6d, 0x6c, 0xf2, 0x3b, 0x74, 0x73, 0x75, 0x294, 0x75, 0x6d, 0xe8, 0x3b, 0x74, 0x73, 0x75, 0x294, 0x75, 0x67, 0x68,
+0x268, 0x302, 0x6d, 0x3b, 0x74, 0x73, 0x75, 0x294, 0x6e, 0x64, 0x7a, 0x268, 0x6b, 0x254, 0x294, 0x254, 0x3b, 0x6e, 0x3b, 0x6b,
+0x3b, 0x67, 0x3b, 0x74, 0x3b, 0x75, 0x3b, 0x67, 0x3b, 0x64, 0x3b, 0x6e, 0x254, 0x79, 0x3b, 0x6e, 0x6a, 0x61, 0x3b, 0x75,
+0x75, 0x6d, 0x3b, 0x14b, 0x67, 0x65, 0x3b, 0x6d, 0x62, 0x254, 0x3b, 0x6b, 0x254, 0x254, 0x3b, 0x6a, 0x6f, 0x6e, 0x3b, 0x14b,
+0x67, 0x77, 0xe0, 0x20, 0x6e, 0x254, 0x302, 0x79, 0x3b, 0x14b, 0x67, 0x77, 0xe0, 0x20, 0x6e, 0x6a, 0x61, 0x14b, 0x67, 0x75,
+0x6d, 0x62, 0x61, 0x3b, 0x14b, 0x67, 0x77, 0xe0, 0x20, 0xfb, 0x6d, 0x3b, 0x14b, 0x67, 0x77, 0xe0, 0x20, 0x14b, 0x67, 0xea,
+0x3b, 0x14b, 0x67, 0x77, 0xe0, 0x20, 0x6d, 0x62, 0x254, 0x6b, 0x3b, 0x14b, 0x67, 0x77, 0xe0, 0x20, 0x6b, 0x254, 0x254, 0x3b,
+0x14b, 0x67, 0x77, 0xe0, 0x20, 0x6a, 0xf4, 0x6e, 0x3b, 0x6e, 0x3b, 0x6e, 0x3b, 0x75, 0x3b, 0x14b, 0x3b, 0x6d, 0x3b, 0x6b,
+0x3b, 0x6a, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x64, 0x69, 0x3b, 0x41, 0x74, 0x69, 0x6e, 0x6e, 0x69, 0x3b, 0x41, 0x74, 0x61,
+0x6c, 0x61, 0x61, 0x74, 0x61, 0x3b, 0x41, 0x6c, 0x61, 0x72, 0x62, 0x61, 0x3b, 0x41, 0x6c, 0x68, 0x61, 0x6d, 0x69, 0x73,
+0x69, 0x3b, 0x41, 0x6c, 0x7a, 0x75, 0x6d, 0x61, 0x3b, 0x41, 0x73, 0x69, 0x62, 0x74, 0x69, 0x3b, 0x48, 0x3b, 0x54, 0x3b,
+0x54, 0x3b, 0x4c, 0x3b, 0x4d, 0x3b, 0x5a, 0x3b, 0x53, 0x3b, 0xe9, 0x74, 0x3b, 0x6d, 0x254, 0x301, 0x73, 0x3b, 0x6b, 0x77,
+0x61, 0x3b, 0x6d, 0x75, 0x6b, 0x3b, 0x14b, 0x67, 0x69, 0x3b, 0x257, 0xf3, 0x6e, 0x3b, 0x65, 0x73, 0x61, 0x3b, 0xe9, 0x74,
+0x69, 0x3b, 0x6d, 0x254, 0x301, 0x73, 0xfa, 0x3b, 0x6b, 0x77, 0x61, 0x73, 0xfa, 0x3b, 0x6d, 0x75, 0x6b, 0x254, 0x301, 0x73,
+0xfa, 0x3b, 0x14b, 0x67, 0x69, 0x73, 0xfa, 0x3b, 0x257, 0xf3, 0x6e, 0x25b, 0x73, 0xfa, 0x3b, 0x65, 0x73, 0x61, 0x253, 0x61,
+0x73, 0xfa, 0x3b, 0x65, 0x3b, 0x6d, 0x3b, 0x6b, 0x3b, 0x6d, 0x3b, 0x14b, 0x3b, 0x257, 0x3b, 0x65, 0x3b, 0x44, 0x69, 0x6d,
+0x3b, 0x54, 0x65, 0x6e, 0x3b, 0x54, 0x61, 0x6c, 0x3b, 0x41, 0x6c, 0x61, 0x3b, 0x41, 0x72, 0x61, 0x3b, 0x41, 0x72, 0x6a,
+0x3b, 0x53, 0x69, 0x62, 0x3b, 0x44, 0x69, 0x6d, 0x61, 0x73, 0x3b, 0x54, 0x65, 0x6e, 0x65, 0x14b, 0x3b, 0x54, 0x61, 0x6c,
+0x61, 0x74, 0x61, 0x3b, 0x41, 0x6c, 0x61, 0x72, 0x62, 0x61, 0x79, 0x3b, 0x41, 0x72, 0x61, 0x6d, 0x69, 0x73, 0x61, 0x79,
+0x3b, 0x41, 0x72, 0x6a, 0x75, 0x6d, 0x61, 0x3b, 0x53, 0x69, 0x62, 0x69, 0x74, 0x69, 0x3b, 0x44, 0x3b, 0x54, 0x3b, 0x54,
+0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x41, 0x3b, 0x53, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x3b, 0x6d, 0x254, 0x301, 0x6e, 0x3b, 0x73,
+0x6d, 0x62, 0x3b, 0x73, 0x6d, 0x6c, 0x3b, 0x73, 0x6d, 0x6e, 0x3b, 0x66, 0xfa, 0x6c, 0x3b, 0x73, 0xe9, 0x72, 0x3b, 0x73,
+0x254, 0x301, 0x6e, 0x64, 0x254, 0x3b, 0x6d, 0x254, 0x301, 0x6e, 0x64, 0x69, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x20,
+0x6d, 0x259, 0x6c, 0xfa, 0x20, 0x6d, 0x259, 0x301, 0x62, 0x25b, 0x30c, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x20, 0x6d,
+0x259, 0x6c, 0xfa, 0x20, 0x6d, 0x259, 0x301, 0x6c, 0x25b, 0x301, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x20, 0x6d, 0x259,
+0x6c, 0xfa, 0x20, 0x6d, 0x259, 0x301, 0x6e, 0x79, 0x69, 0x3b, 0x66, 0xfa, 0x6c, 0x61, 0x64, 0xe9, 0x3b, 0x73, 0xe9, 0x72,
+0x61, 0x64, 0xe9, 0x3b, 0x73, 0x3b, 0x6d, 0x3b, 0x73, 0x3b, 0x73, 0x3b, 0x73, 0x3b, 0x66, 0x3b, 0x73, 0x3b, 0x73, 0x254,
+0x301, 0x6e, 0x3b, 0x6c, 0x1dd, 0x6e, 0x3b, 0x6d, 0x61, 0x61, 0x3b, 0x6d, 0x25b, 0x6b, 0x3b, 0x6a, 0x1dd, 0x1dd, 0x3b, 0x6a,
+0xfa, 0x6d, 0x3b, 0x73, 0x61, 0x6d, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x1dd, 0x3b, 0x6c, 0x1dd, 0x6e, 0x64, 0xed, 0x3b,
+0x6d, 0x61, 0x61, 0x64, 0xed, 0x3b, 0x6d, 0x25b, 0x6b, 0x72, 0x25b, 0x64, 0xed, 0x3b, 0x6a, 0x1dd, 0x1dd, 0x64, 0xed, 0x3b,
+0x6a, 0xfa, 0x6d, 0x62, 0xe1, 0x3b, 0x73, 0x61, 0x6d, 0x64, 0xed, 0x3b, 0x73, 0x3b, 0x6c, 0x3b, 0x6d, 0x3b, 0x6d, 0x3b,
+0x6a, 0x3b, 0x6a, 0x3b, 0x73, 0x3b, 0x53, 0x61, 0x62, 0x3b, 0x4a, 0x74, 0x74, 0x3b, 0x4a, 0x6e, 0x6e, 0x3b, 0x4a, 0x74,
+0x6e, 0x3b, 0x41, 0x72, 0x61, 0x3b, 0x49, 0x6a, 0x75, 0x3b, 0x4a, 0x6d, 0x6f, 0x3b, 0x53, 0x61, 0x62, 0x61, 0x74, 0x6f,
+0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6e, 0x6e, 0x65, 0x3b, 0x4a, 0x75,
+0x6d, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x72, 0x61, 0x68, 0x61, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x49, 0x6a, 0x75,
+0x6d, 0x61, 0x61, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0x6f, 0x73, 0x69, 0x3b, 0x53, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x4a,
+0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x4a, 0x3b, 0x43, 0x79, 0x61, 0x3b, 0x43, 0x6c, 0x61, 0x3b, 0x43, 0x7a, 0x69, 0x3b, 0x43,
+0x6b, 0x6f, 0x3b, 0x43, 0x6b, 0x61, 0x3b, 0x43, 0x67, 0x61, 0x3b, 0x43, 0x7a, 0x65, 0x3b, 0x43, 0x6f, 0x6d, 0x27, 0x79,
+0x61, 0x6b, 0x6b, 0x65, 0x3b, 0x43, 0x6f, 0x6d, 0x6c, 0x61, 0x61, 0x257, 0x69, 0x69, 0x3b, 0x43, 0x6f, 0x6d, 0x7a, 0x79,
+0x69, 0x69, 0x257, 0x69, 0x69, 0x3b, 0x43, 0x6f, 0x6d, 0x6b, 0x6f, 0x6c, 0x6c, 0x65, 0x3b, 0x43, 0x6f, 0x6d, 0x6b, 0x61,
+0x6c, 0x64, 0x1dd, 0x253, 0x6c, 0x69, 0x69, 0x3b, 0x43, 0x6f, 0x6d, 0x67, 0x61, 0x69, 0x73, 0x75, 0x75, 0x3b, 0x43, 0x6f,
+0x6d, 0x7a, 0x79, 0x65, 0x253, 0x73, 0x75, 0x75, 0x3b, 0x59, 0x3b, 0x4c, 0x3b, 0x5a, 0x3b, 0x4f, 0x3b, 0x41, 0x3b, 0x47,
+0x3b, 0x45, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x3b, 0x6d, 0x254, 0x301, 0x6e, 0x3b, 0x73, 0x6d, 0x62, 0x3b, 0x73, 0x6d, 0x6c,
+0x3b, 0x73, 0x6d, 0x6e, 0x3b, 0x6d, 0x62, 0x73, 0x3b, 0x73, 0x61, 0x73, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x3b,
+0x6d, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x20, 0x6d, 0x61, 0x66, 0xfa, 0x20, 0x6d,
+0xe1, 0x62, 0x61, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x20, 0x6d, 0x61, 0x66, 0xfa, 0x20, 0x6d, 0xe1, 0x6c, 0x61,
+0x6c, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x254, 0x20, 0x6d, 0x61, 0x66, 0xfa, 0x20, 0x6d, 0xe1, 0x6e, 0x61, 0x3b, 0x6d,
+0x61, 0x62, 0xe1, 0x67, 0xe1, 0x20, 0x6d, 0xe1, 0x20, 0x73, 0x75, 0x6b, 0x75, 0x6c, 0x3b, 0x73, 0xe1, 0x73, 0x61, 0x64,
+0x69, 0x3b, 0x73, 0x3b, 0x6d, 0x3b, 0x73, 0x3b, 0x73, 0x3b, 0x73, 0x3b, 0x6d, 0x3b, 0x73, 0x3b, 0x43, 0xe4, 0x14b, 0x3b,
+0x4a, 0x69, 0x65, 0x63, 0x3b, 0x52, 0x25b, 0x77, 0x3b, 0x44, 0x69, 0x254, 0x331, 0x6b, 0x3b, 0x14a, 0x75, 0x61, 0x61, 0x6e,
+0x3b, 0x44, 0x68, 0x69, 0x65, 0x65, 0x63, 0x3b, 0x42, 0xe4, 0x6b, 0x25b, 0x6c, 0x3b, 0x43, 0xe4, 0x14b, 0x20, 0x6b, 0x75,
+0x254, 0x74, 0x68, 0x3b, 0x4a, 0x69, 0x65, 0x63, 0x20, 0x6c, 0x61, 0x331, 0x74, 0x3b, 0x52, 0x25b, 0x77, 0x20, 0x6c, 0xe4,
+0x74, 0x6e, 0x69, 0x3b, 0x44, 0x69, 0x254, 0x331, 0x6b, 0x20, 0x6c, 0xe4, 0x74, 0x6e, 0x69, 0x3b, 0x14a, 0x75, 0x61, 0x61,
+0x6e, 0x20, 0x6c, 0xe4, 0x74, 0x6e, 0x69, 0x3b, 0x44, 0x68, 0x69, 0x65, 0x65, 0x63, 0x20, 0x6c, 0xe4, 0x74, 0x6e, 0x69,
+0x3b, 0x42, 0xe4, 0x6b, 0x25b, 0x6c, 0x20, 0x6c, 0xe4, 0x74, 0x6e, 0x69, 0x3b, 0x43, 0x3b, 0x4a, 0x3b, 0x52, 0x3b, 0x44,
+0x3b, 0x14a, 0x3b, 0x44, 0x3b, 0x42, 0x3b, 0x411, 0x441, 0x3b, 0x411, 0x43d, 0x3b, 0x41e, 0x43f, 0x3b, 0x421, 0x44d, 0x3b, 0x427,
+0x43f, 0x3b, 0x411, 0x44d, 0x3b, 0x421, 0x431, 0x3b, 0x411, 0x430, 0x441, 0x43a, 0x44b, 0x4bb, 0x44b, 0x430, 0x43d, 0x43d, 0x44c, 0x430,
+0x3b, 0x411, 0x44d, 0x43d, 0x438, 0x434, 0x438, 0x44d, 0x43b, 0x438, 0x43d, 0x43d, 0x44c, 0x438, 0x43a, 0x3b, 0x41e, 0x43f, 0x442, 0x443,
+0x43e, 0x440, 0x443, 0x43d, 0x43d, 0x44c, 0x443, 0x43a, 0x3b, 0x421, 0x44d, 0x440, 0x44d, 0x434, 0x44d, 0x3b, 0x427, 0x44d, 0x43f, 0x43f,
+0x438, 0x44d, 0x440, 0x3b, 0x411, 0x44d, 0x44d, 0x442, 0x438, 0x4a5, 0x441, 0x44d, 0x3b, 0x421, 0x443, 0x431, 0x443, 0x43e, 0x442, 0x430,
+0x3b, 0x411, 0x3b, 0x411, 0x3b, 0x41e, 0x3b, 0x421, 0x3b, 0x427, 0x3b, 0x411, 0x3b, 0x421, 0x3b, 0x4d, 0x75, 0x6c, 0x3b, 0x4a,
+0x74, 0x74, 0x3b, 0x4a, 0x6e, 0x6e, 0x3b, 0x4a, 0x74, 0x6e, 0x3b, 0x41, 0x6c, 0x68, 0x3b, 0x49, 0x6a, 0x75, 0x3b, 0x4a,
+0x6d, 0x6f, 0x3b, 0x4d, 0x75, 0x6c, 0x75, 0x6e, 0x67, 0x75, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x74, 0x75, 0x3b,
+0x4a, 0x75, 0x6d, 0x61, 0x6e, 0x6e, 0x65, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x74, 0x61, 0x6e, 0x6f, 0x3b, 0x41, 0x6c, 0x61,
+0x68, 0x61, 0x6d, 0x69, 0x73, 0x69, 0x3b, 0x49, 0x6a, 0x75, 0x6d, 0x61, 0x61, 0x3b, 0x4a, 0x75, 0x6d, 0x61, 0x6d, 0x6f,
+0x73, 0x69, 0x3b, 0x4d, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x4a, 0x3b, 0x41, 0x3b, 0x49, 0x3b, 0x4a, 0x3b, 0x79, 0x65, 0x6e,
+0x3b, 0x6b, 0x77, 0x61, 0x3b, 0x70, 0x69, 0x6c, 0x3b, 0x74, 0x61, 0x74, 0x3b, 0x69, 0x6e, 0x65, 0x3b, 0x74, 0x61, 0x6e,
+0x3b, 0x73, 0x69, 0x74, 0x3b, 0x73, 0x69, 0x6b, 0x75, 0x20, 0x79, 0x61, 0x20, 0x79, 0x65, 0x6e, 0x67, 0x61, 0x3b, 0x73,
+0x69, 0x6b, 0x75, 0x20, 0x79, 0x61, 0x20, 0x6b, 0x77, 0x61, 0x6e, 0x7a, 0x61, 0x3b, 0x73, 0x69, 0x6b, 0x75, 0x20, 0x79,
+0x61, 0x20, 0x70, 0x69, 0x6c, 0x69, 0x3b, 0x73, 0x69, 0x6b, 0x75, 0x20, 0x79, 0x61, 0x20, 0x74, 0x61, 0x74, 0x75, 0x3b,
+0x73, 0x69, 0x6b, 0x75, 0x20, 0x79, 0x61, 0x20, 0x69, 0x6e, 0x65, 0x3b, 0x73, 0x69, 0x6b, 0x75, 0x20, 0x79, 0x61, 0x20,
+0x74, 0x61, 0x6e, 0x75, 0x3b, 0x73, 0x69, 0x6b, 0x75, 0x20, 0x79, 0x61, 0x20, 0x73, 0x69, 0x74, 0x61, 0x3b, 0x79, 0x3b,
+0x6b, 0x3b, 0x70, 0x3b, 0x74, 0x3b, 0x69, 0x3b, 0x74, 0x3b, 0x73, 0x3b, 0xa55e, 0xa54c, 0xa535, 0x3b, 0xa5f3, 0xa5e1, 0xa609, 0x3b,
+0xa55a, 0xa55e, 0xa55a, 0x3b, 0xa549, 0xa55e, 0xa552, 0x3b, 0xa549, 0xa524, 0xa546, 0xa562, 0x3b, 0xa549, 0xa524, 0xa540, 0xa56e, 0x3b, 0xa53b, 0xa52c,
+0xa533, 0x3b, 0x6c, 0x61, 0x68, 0x61, 0x64, 0x69, 0x3b, 0x74, 0x25b, 0x25b, 0x6e, 0x25b, 0x25b, 0x3b, 0x74, 0x61, 0x6c, 0x61,
+0x74, 0x61, 0x3b, 0x61, 0x6c, 0x61, 0x62, 0x61, 0x3b, 0x61, 0x69, 0x6d, 0x69, 0x73, 0x61, 0x3b, 0x61, 0x69, 0x6a, 0x69,
+0x6d, 0x61, 0x3b, 0x73, 0x69, 0x253, 0x69, 0x74, 0x69, 0x3b, 0x53, 0x75, 0x6e, 0x3b, 0x4d, 0xe4, 0x6e, 0x3b, 0x5a, 0x69,
+0x161, 0x3b, 0x4d, 0x69, 0x74, 0x3b, 0x46, 0x72, 0xf3, 0x3b, 0x46, 0x72, 0x69, 0x3b, 0x53, 0x61, 0x6d, 0x3b, 0x53, 0x75,
+0x6e, 0x6e, 0x74, 0x61, 0x67, 0x3b, 0x4d, 0xe4, 0x6e, 0x74, 0x61, 0x67, 0x3b, 0x5a, 0x69, 0x161, 0x74, 0x61, 0x67, 0x3b,
+0x4d, 0x69, 0x74, 0x74, 0x77, 0x75, 0x10d, 0x3b, 0x46, 0x72, 0xf3, 0x6e, 0x74, 0x61, 0x67, 0x3b, 0x46, 0x72, 0x69, 0x74,
+0x61, 0x67, 0x3b, 0x53, 0x61, 0x6d, 0x161, 0x74, 0x61, 0x67, 0x3b, 0x53, 0x3b, 0x4d, 0x3b, 0x5a, 0x3b, 0x4d, 0x3b, 0x46,
+0x3b, 0x46, 0x3b, 0x53, 0x3b, 0x73, 0x64, 0x3b, 0x6d, 0x64, 0x3b, 0x6d, 0x77, 0x3b, 0x65, 0x74, 0x3b, 0x6b, 0x6c, 0x3b,
+0x66, 0x6c, 0x3b, 0x73, 0x73, 0x3b, 0x73, 0x254, 0x301, 0x6e, 0x64, 0x69, 0x25b, 0x3b, 0x6d, 0xf3, 0x6e, 0x64, 0x69, 0x65,
+0x3b, 0x6d, 0x75, 0xe1, 0x6e, 0x79, 0xe1, 0x14b, 0x6d, 0xf3, 0x6e, 0x64, 0x69, 0x65, 0x3b, 0x6d, 0x65, 0x74, 0xfa, 0x6b,
+0x70, 0xed, 0xe1, 0x70, 0x25b, 0x3b, 0x6b, 0xfa, 0x70, 0xe9, 0x6c, 0x69, 0x6d, 0x65, 0x74, 0xfa, 0x6b, 0x70, 0x69, 0x61,
+0x70, 0x25b, 0x3b, 0x66, 0x65, 0x6c, 0xe9, 0x74, 0x65, 0x3b, 0x73, 0xe9, 0x73, 0x65, 0x6c, 0xe9, 0x3b, 0x73, 0x3b, 0x6d,
+0x3b, 0x6d, 0x3b, 0x65, 0x3b, 0x6b, 0x3b, 0x66, 0x3b, 0x73, 0x3b, 0x64, 0x6f, 0x6d, 0x3b, 0x6c, 0x6c, 0x75, 0x3b, 0x6d,
+0x61, 0x72, 0x3b, 0x6d, 0x69, 0x65, 0x3b, 0x78, 0x75, 0x65, 0x3b, 0x76, 0x69, 0x65, 0x3b, 0x73, 0x61, 0x62, 0x3b, 0x64,
+0x6f, 0x6d, 0x69, 0x6e, 0x67, 0x75, 0x3b, 0x6c, 0x6c, 0x75, 0x6e, 0x65, 0x73, 0x3b, 0x6d, 0x61, 0x72, 0x74, 0x65, 0x73,
+0x3b, 0x6d, 0x69, 0xe9, 0x72, 0x63, 0x6f, 0x6c, 0x65, 0x73, 0x3b, 0x78, 0x75, 0x65, 0x76, 0x65, 0x73, 0x3b, 0x76, 0x69,
+0x65, 0x6e, 0x72, 0x65, 0x73, 0x3b, 0x73, 0xe1, 0x62, 0x61, 0x64, 0x75, 0x3b, 0x53, 0x254, 0x301, 0x6e, 0x64, 0x69, 0x3b,
+0x4d, 0x254, 0x301, 0x6e, 0x64, 0x69, 0x3b, 0xc1, 0x70, 0x74, 0x61, 0x20, 0x4d, 0x254, 0x301, 0x6e, 0x64, 0x69, 0x3b, 0x57,
+0x25b, 0x301, 0x6e, 0x25b, 0x73, 0x25b, 0x64, 0x25b, 0x3b, 0x54, 0x254, 0x301, 0x73, 0x25b, 0x64, 0x25b, 0x3b, 0x46, 0x25b, 0x6c,
+0xe2, 0x79, 0x25b, 0x64, 0x25b, 0x3b, 0x53, 0xe1, 0x73, 0x69, 0x64, 0x25b, 0x3b, 0x53, 0x254, 0x301, 0x3b, 0x4d, 0x254, 0x301,
+0x3b, 0xc1, 0x4d, 0x3b, 0x57, 0x25b, 0x301, 0x3b, 0x54, 0x254, 0x301, 0x3b, 0x46, 0x25b, 0x3b, 0x53, 0xe1, 0x3b, 0x73, 0x254,
+0x6e, 0x64, 0x69, 0x3b, 0x6c, 0x75, 0x6e, 0x64, 0x69, 0x3b, 0x6d, 0x61, 0x72, 0x64, 0x69, 0x3b, 0x6d, 0x25b, 0x72, 0x6b,
+0x25b, 0x72, 0x25b, 0x64, 0x69, 0x3b, 0x79, 0x65, 0x64, 0x69, 0x3b, 0x76, 0x61, 0x14b, 0x64, 0x25b, 0x72, 0x25b, 0x64, 0x69,
+0x3b, 0x6d, 0x254, 0x6e, 0x254, 0x20, 0x73, 0x254, 0x6e, 0x64, 0x69, 0x3b, 0x73, 0x6f, 0x3b, 0x6c, 0x75, 0x3b, 0x6d, 0x61,
+0x3b, 0x6d, 0x25b, 0x3b, 0x79, 0x65, 0x3b, 0x76, 0x61, 0x3b, 0x6d, 0x73, 0x3b, 0x41, 0x6e, 0x65, 0x67, 0x20, 0x31, 0x3b,
+0x41, 0x6e, 0x65, 0x67, 0x20, 0x32, 0x3b, 0x41, 0x6e, 0x65, 0x67, 0x20, 0x33, 0x3b, 0x41, 0x6e, 0x65, 0x67, 0x20, 0x34,
+0x3b, 0x41, 0x6e, 0x65, 0x67, 0x20, 0x35, 0x3b, 0x41, 0x6e, 0x65, 0x67, 0x20, 0x36, 0x3b, 0x41, 0x6e, 0x65, 0x67, 0x20,
+0x37, 0x3b, 0x41, 0x31, 0x3b, 0x41, 0x32, 0x3b, 0x41, 0x33, 0x3b, 0x41, 0x34, 0x3b, 0x41, 0x35, 0x3b, 0x41, 0x36, 0x3b,
+0x41, 0x37, 0x3b, 0x6c, 0x79, 0x25b, 0x2bc, 0x25b, 0x301, 0x20, 0x73, 0x1e85, 0xed, 0x14b, 0x74, 0xe8, 0x3b, 0x6d, 0x76, 0x66,
+0xf2, 0x20, 0x6c, 0x79, 0x25b, 0x30c, 0x2bc, 0x3b, 0x6d, 0x62, 0x254, 0x301, 0x254, 0x6e, 0x74, 0xe8, 0x20, 0x6d, 0x76, 0x66,
+0xf2, 0x20, 0x6c, 0x79, 0x25b, 0x30c, 0x2bc, 0x3b, 0x74, 0x73, 0xe8, 0x74, 0x73, 0x25b, 0x300, 0x25b, 0x20, 0x6c, 0x79, 0x25b,
+0x30c, 0x2bc, 0x3b, 0x6d, 0x62, 0x254, 0x301, 0x254, 0x6e, 0x74, 0xe8, 0x20, 0x74, 0x73, 0x65, 0x74, 0x73, 0x25b, 0x300, 0x25b,
+0x20, 0x6c, 0x79, 0x25b, 0x30c, 0x2bc, 0x3b, 0x6d, 0x76, 0x66, 0xf2, 0x20, 0x6d, 0xe0, 0x67, 0x61, 0x20, 0x6c, 0x79, 0x25b,
+0x30c, 0x2bc, 0x3b, 0x6d, 0xe0, 0x67, 0x61, 0x20, 0x6c, 0x79, 0x25b, 0x30c, 0x2bc, 0x3b
};
static const ushort am_data[] = {
-0x41, 0x4d, 0x57, 0x44, 0x76, 0x6d, 0x2e, 0x50, 0x44, 0x1325, 0x12cb, 0x1275, 0x635, 0x531, 0x57c, 0x2024, 0x9aa, 0x9c2, 0x9f0, 0x9cd,
-0x9ac, 0x9be, 0x9b9, 0x9cd, 0x9a3, 0x9aa, 0x9c2, 0x9b0, 0x9cd, 0x9ac, 0x9be, 0x9b9, 0x9cd, 0x9a3, 0xf66, 0xf94, 0xf0b, 0xf46, 0xf0b, 0x43f,
-0x440, 0x2e, 0x20, 0x43e, 0x431, 0x2e, 0x1014, 0x1036, 0x1014, 0x1000, 0x103a, 0x434, 0x430, 0x20, 0x43f, 0x430, 0x43b, 0x443, 0x434, 0x43d,
-0x44f, 0x1796, 0x17d2, 0x179a, 0x17b9, 0x1780, 0x61, 0x2e, 0x6d, 0x2e, 0x4e0a, 0x5348, 0xd801, 0xdc08, 0xd801, 0xdc23, 0x61, 0x6d, 0x61, 0x70,
-0x2e, 0x76, 0x6f, 0x72, 0x6d, 0x2e, 0x3c0, 0x2e, 0x3bc, 0x2e, 0x5dc, 0x5e4, 0x5e0, 0x5d4, 0x5f4, 0x5e6, 0x92a, 0x942, 0x930, 0x94d,
-0x935, 0x93e, 0x939, 0x94d, 0x928, 0x64, 0x65, 0x2e, 0x66, 0x2e, 0x68, 0x2e, 0x5348, 0x524d, 0xc624, 0xc804, 0x5a, 0x2e, 0x4d, 0x55,
-0x2e, 0xe81, 0xec8, 0xead, 0xe99, 0xe97, 0xec8, 0xebd, 0xe87, 0x70, 0x72, 0x69, 0x65, 0x6b, 0x161, 0x70, 0x75, 0x73, 0x64, 0x69,
-0x65, 0x6e, 0x101, 0x6e, 0x74, 0x254, 0x301, 0x6e, 0x67, 0x254, 0x301, 0x70, 0x72, 0x69, 0x65, 0x161, 0x70, 0x69, 0x65, 0x74,
-0x43f, 0x440, 0x435, 0x442, 0x43f, 0x43b, 0x430, 0x434, 0x43d, 0x435, 0x50, 0x47, 0x51, 0x4e, 0x92a, 0x942, 0x930, 0x94d, 0x935, 0x20,
-0x92e, 0x927, 0x94d, 0x92f, 0x93e, 0x928, 0x94d, 0x939, 0x63a, 0x2e, 0x645, 0x2e, 0x642, 0x628, 0x644, 0x200c, 0x627, 0x632, 0x638, 0x647,
-0x631, 0xa2a, 0xa42, 0xa30, 0xa35, 0x20, 0xa26, 0xa41, 0xa2a, 0xa39, 0xa3f, 0xa30, 0x434, 0x43e, 0x20, 0x43f, 0x43e, 0x43b, 0x443, 0x434,
-0x43d, 0x44f, 0x4e, 0x44, 0x43f, 0x440, 0x435, 0x20, 0x43f, 0x43e, 0x434, 0x43d, 0x435, 0x70, 0x72, 0x65, 0x20, 0x70, 0x6f, 0x64,
-0x6e, 0x65, 0xdb4, 0xdd9, 0x2e, 0xdc0, 0x2e, 0x64, 0x6f, 0x70, 0x6f, 0x6c, 0x75, 0x64, 0x6e, 0x69, 0x61, 0x64, 0x6f, 0x70,
-0x2e, 0x73, 0x6e, 0x2e, 0x61, 0x73, 0x75, 0x62, 0x75, 0x68, 0x69, 0x66, 0x6d, 0xe01, 0xe48, 0xe2d, 0xe19, 0xe40, 0xe17, 0xe35,
-0xe48, 0xe22, 0xe07, 0xf66, 0xf94, 0xf0b, 0xf51, 0xfb2, 0xf7c, 0xf0b, 0x1295, 0x1309, 0x1206, 0x20, 0x1230, 0x12d3, 0x1270, 0xd6, 0xd6, 0x434,
-0x43f, 0x62f, 0x646, 0x53, 0x41, 0xc0, 0xe1, 0x72, 0x1ecd, 0x300, 0x45, 0x6b, 0x75, 0x73, 0x65, 0x6e, 0x69, 0x66, 0x6f, 0x72,
-0x6d, 0x69, 0x64, 0x64, 0x61, 0x67, 0x41, 0x4e, 0x92e, 0x2e, 0x92a, 0x942, 0x2e, 0x41, 0x2e, 0x4d, 0x2e, 0x128, 0x79, 0x61,
-0x6b, 0x77, 0x61, 0x6b, 0x79, 0x61, 0x14b, 0x64, 0x69, 0xa3b8, 0xa111, 0x4d, 0x61, 0x2f, 0x4d, 0x6f, 0x4c, 0x75, 0x6d, 0x61,
-0x20, 0x6c, 0x77, 0x61, 0x20, 0x4b, 0x73, 0x75, 0x62, 0x61, 0x6b, 0x61, 0x4b, 0x69, 0x72, 0x6f, 0x6b, 0x6f, 0x54, 0x65,
-0x73, 0x69, 0x72, 0x61, 0x6e, 0x6b, 0x61, 0x6e, 0x67, 0x27, 0x61, 0x6d, 0x61, 0x2d5c, 0x2d49, 0x2d3c, 0x2d30, 0x2d61, 0x2d5c, 0x74,
-0x69, 0x66, 0x61, 0x77, 0x74, 0x6e, 0x20, 0x74, 0x75, 0x66, 0x61, 0x74, 0x70, 0x61, 0x6d, 0x69, 0x6c, 0x61, 0x75, 0x75,
-0x74, 0x75, 0x6b, 0x6f, 0x4b, 0x49, 0x13cc, 0x13be, 0x13b4, 0x4d, 0x75, 0x68, 0x69, 0x54, 0x4f, 0x4f, 0x75, 0x6c, 0x75, 0x63,
-0x68, 0x65, 0x6c, 0x6f, 0x52, 0x168, 0x42, 0x65, 0x65, 0x74, 0x1c1, 0x67, 0x6f, 0x61, 0x67, 0x61, 0x73, 0x190, 0x6e, 0x6b,
-0x61, 0x6b, 0x25b, 0x6e, 0x79, 0xe1, 0x4d, 0x75, 0x6e, 0x6b, 0x79, 0x6f, 0x69, 0x63, 0x68, 0x65, 0x68, 0x65, 0x61, 0x76,
-0x6f, 0x54, 0x61, 0x70, 0x61, 0x72, 0x61, 0x63, 0x68, 0x75, 0x41, 0x64, 0x64, 0x75, 0x68, 0x61, 0x4f, 0x44, 0x5a, 0x64,
-0x61, 0x74, 0x20, 0x61, 0x7a, 0x61, 0x6c, 0x6d, 0x61, 0x6b, 0x65, 0x6f, 0x92b, 0x941, 0x902, 0x44, 0x69, 0x6e, 0x64, 0x61,
-0x61, 0x2e, 0x67, 0x49, 0x20, 0x62, 0x69, 0x6b, 0x25b, 0x302, 0x67, 0x6c, 0xe0, 0x53, 0x75, 0x62, 0x62, 0x61, 0x61, 0x68,
-0x69, 0x69, 0x64, 0x69, 0x253, 0x61, 0x6b, 0xed, 0x6b, 0xed, 0x72, 0xed, 0x67, 0x73, 0xe1, 0x72, 0xfa, 0x77, 0xe1, 0x77,
-0x69, 0x63, 0x68, 0x69, 0x73, 0x68, 0x75, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6d, 0x61, 0x6e, 0xe1, 0x52, 0x57, 0x4c, 0x77,
-0x61, 0x6d, 0x69, 0x6c, 0x61, 0x77, 0x75, 0x79, 0x61, 0x20, 0x61, 0x73, 0x75, 0x62, 0x75, 0x79, 0x69, 0x6b, 0x69, 0x25b,
-0x6d, 0x25b, 0x301, 0x25b, 0x6d, 0x6d, 0x62, 0x61, 0x2019, 0x6d, 0x62, 0x61, 0x2019, 0x6d, 0x62, 0x61, 0x2bc, 0xe1, 0x6d, 0x62,
-0x61, 0x2bc
+0x41, 0x4d, 0x57, 0x44, 0x76, 0x6d, 0x2e, 0x50, 0x44, 0x1325, 0x12cb, 0x1275, 0x635, 0x56f, 0x565, 0x57d, 0x585, 0x580, 0x56b, 0x581,
+0x20, 0x561, 0x57c, 0x561, 0x57b, 0x9aa, 0x9c2, 0x9f0, 0x9cd, 0x9ac, 0x9be, 0x9b9, 0x9cd, 0x9a3, 0x9aa, 0x9c2, 0x9b0, 0x9cd, 0x9ac, 0x9be,
+0x9b9, 0x9cd, 0x9a3, 0xf66, 0xf94, 0xf0b, 0xf46, 0xf0b, 0x43f, 0x440, 0x2e, 0x20, 0x43e, 0x431, 0x2e, 0x1014, 0x1036, 0x1014, 0x1000, 0x103a,
+0x434, 0x430, 0x20, 0x43f, 0x430, 0x43b, 0x443, 0x434, 0x43d, 0x44f, 0x1796, 0x17d2, 0x179a, 0x17b9, 0x1780, 0x61, 0x2e, 0x6d, 0x2e, 0x4e0a,
+0x5348, 0x64, 0x6f, 0x70, 0x2e, 0xd801, 0xdc08, 0xd801, 0xdc23, 0x61, 0x6d, 0x61, 0x70, 0x2e, 0x76, 0x6f, 0x72, 0x6d, 0x2e, 0x3c0,
+0x2e, 0x3bc, 0x2e, 0x5dc, 0x5e4, 0x5e0, 0x5d4, 0x5f4, 0x5e6, 0x92a, 0x942, 0x930, 0x94d, 0x935, 0x93e, 0x939, 0x94d, 0x928, 0x64, 0x65,
+0x2e, 0x66, 0x2e, 0x68, 0x2e, 0x5348, 0x524d, 0xc624, 0xc804, 0x5a, 0x2e, 0x4d, 0x55, 0x2e, 0xe81, 0xec8, 0xead, 0xe99, 0xe97, 0xec8,
+0xebd, 0xe87, 0x70, 0x72, 0x69, 0x65, 0x6b, 0x161, 0x70, 0x75, 0x73, 0x64, 0x69, 0x65, 0x6e, 0x101, 0x6e, 0x74, 0x254, 0x301,
+0x6e, 0x67, 0x254, 0x301, 0x70, 0x72, 0x69, 0x65, 0x161, 0x70, 0x69, 0x65, 0x74, 0x43f, 0x440, 0x435, 0x442, 0x43f, 0x43b, 0x430,
+0x434, 0x43d, 0x435, 0x50, 0x47, 0x51, 0x4e, 0x4ae, 0x4e8, 0x92a, 0x942, 0x930, 0x94d, 0x935, 0x20, 0x92e, 0x927, 0x94d, 0x92f, 0x93e,
+0x928, 0x94d, 0x939, 0x63a, 0x2e, 0x645, 0x2e, 0x642, 0x628, 0x644, 0x200c, 0x627, 0x632, 0x638, 0x647, 0x631, 0xa2a, 0xa42, 0xa30, 0xa35,
+0x20, 0xa26, 0xa41, 0xa2a, 0xa39, 0xa3f, 0xa30, 0x434, 0x43e, 0x20, 0x43f, 0x43e, 0x43b, 0x443, 0x434, 0x43d, 0x44f, 0x4e, 0x44, 0x43f,
+0x440, 0x435, 0x20, 0x43f, 0x43e, 0x434, 0x43d, 0x435, 0x70, 0x72, 0x65, 0x20, 0x70, 0x6f, 0x64, 0x6e, 0x65, 0xdb4, 0xdd9, 0x2e,
+0xdc0, 0x2e, 0x64, 0x6f, 0x70, 0x6f, 0x6c, 0x75, 0x64, 0x6e, 0x69, 0x61, 0x73, 0x6e, 0x2e, 0x61, 0x73, 0x75, 0x62, 0x75,
+0x68, 0x69, 0x66, 0x6d, 0xe01, 0xe48, 0xe2d, 0xe19, 0xe40, 0xe17, 0xe35, 0xe48, 0xe22, 0xe07, 0xf66, 0xf94, 0xf0b, 0xf51, 0xfb2, 0xf7c,
+0xf0b, 0x1295, 0x1309, 0x1206, 0x20, 0x1230, 0x12d3, 0x1270, 0xd6, 0xd6, 0x434, 0x43f, 0x642, 0x628, 0x644, 0x20, 0x62f, 0x648, 0x67e, 0x6c1,
+0x631, 0x53, 0x41, 0xc0, 0xe1, 0x72, 0x1ecd, 0x300, 0x45, 0x6b, 0x75, 0x73, 0x65, 0x6e, 0x69, 0x66, 0x6f, 0x72, 0x6d, 0x69,
+0x64, 0x64, 0x61, 0x67, 0x41, 0x4e, 0x92e, 0x2e, 0x92a, 0x942, 0x2e, 0x41, 0x2e, 0x4d, 0x2e, 0x128, 0x79, 0x61, 0x6b, 0x77,
+0x61, 0x6b, 0x79, 0x61, 0x14b, 0x64, 0x69, 0xa3b8, 0xa111, 0x4d, 0x61, 0x2f, 0x4d, 0x6f, 0x4c, 0x75, 0x6d, 0x61, 0x20, 0x6c,
+0x77, 0x61, 0x20, 0x4b, 0x73, 0x75, 0x62, 0x61, 0x6b, 0x61, 0x4b, 0x69, 0x72, 0x6f, 0x6b, 0x6f, 0x54, 0x65, 0x73, 0x69,
+0x72, 0x61, 0x6e, 0x6b, 0x61, 0x6e, 0x67, 0x27, 0x61, 0x6d, 0x61, 0x2d5c, 0x2d49, 0x2d3c, 0x2d30, 0x2d61, 0x2d5c, 0x74, 0x69, 0x66,
+0x61, 0x77, 0x74, 0x6e, 0x20, 0x74, 0x75, 0x66, 0x61, 0x74, 0x70, 0x61, 0x6d, 0x69, 0x6c, 0x61, 0x75, 0x75, 0x74, 0x75,
+0x6b, 0x6f, 0x4b, 0x49, 0x13cc, 0x13be, 0x13b4, 0x4d, 0x75, 0x68, 0x69, 0x54, 0x4f, 0x4f, 0x75, 0x6c, 0x75, 0x63, 0x68, 0x65,
+0x6c, 0x6f, 0x52, 0x168, 0x42, 0x65, 0x65, 0x74, 0x1c1, 0x67, 0x6f, 0x61, 0x67, 0x61, 0x73, 0x190, 0x6e, 0x6b, 0x61, 0x6b,
+0x25b, 0x6e, 0x79, 0xe1, 0x4d, 0x75, 0x6e, 0x6b, 0x79, 0x6f, 0x69, 0x63, 0x68, 0x65, 0x68, 0x65, 0x61, 0x76, 0x6f, 0x54,
+0x61, 0x70, 0x61, 0x72, 0x61, 0x63, 0x68, 0x75, 0x41, 0x64, 0x64, 0x75, 0x68, 0x61, 0x4f, 0x44, 0x5a, 0x64, 0x61, 0x74,
+0x20, 0x61, 0x7a, 0x61, 0x6c, 0x6d, 0x61, 0x6b, 0x65, 0x6f, 0x92b, 0x941, 0x902, 0x44, 0x69, 0x6e, 0x64, 0x61, 0x61, 0x2e,
+0x67, 0x49, 0x20, 0x62, 0x69, 0x6b, 0x25b, 0x302, 0x67, 0x6c, 0xe0, 0x53, 0x75, 0x62, 0x62, 0x61, 0x61, 0x68, 0x69, 0x69,
+0x64, 0x69, 0x253, 0x61, 0x6b, 0xed, 0x6b, 0xed, 0x72, 0xed, 0x67, 0x73, 0xe1, 0x72, 0xfa, 0x77, 0xe1, 0x77, 0x69, 0x63,
+0x68, 0x69, 0x73, 0x68, 0x75, 0x63, 0x6f, 0x6d, 0x6d, 0x65, 0x6d, 0x61, 0x6e, 0xe1, 0x52, 0x57, 0x4c, 0x77, 0x61, 0x6d,
+0x69, 0x6c, 0x61, 0x77, 0x75, 0x79, 0x61, 0x20, 0x61, 0x73, 0x75, 0x62, 0x75, 0x79, 0x69, 0x6b, 0x69, 0x25b, 0x6d, 0x25b,
+0x301, 0x25b, 0x6d, 0x6d, 0x62, 0x61, 0x2019, 0x6d, 0x62, 0x61, 0x2019, 0x6d, 0x62, 0x61, 0x2bc, 0xe1, 0x6d, 0x62, 0x61, 0x2bc,
+
};
static const ushort pm_data[] = {
-0x50, 0x4d, 0x57, 0x42, 0x6e, 0x6d, 0x2e, 0x4d, 0x44, 0x12a8, 0x1230, 0x12d3, 0x1275, 0x645, 0x53f, 0x565, 0x2024, 0x985, 0x9aa, 0x9f0,
-0x9be, 0x9b9, 0x9cd, 0x9a3, 0x985, 0x9aa, 0x9b0, 0x9be, 0x9b9, 0x9cd, 0x9a3, 0xf55, 0xfb1, 0xf72, 0xf0b, 0xf46, 0xf0b, 0x441, 0x43b, 0x2e,
-0x20, 0x43e, 0x431, 0x2e, 0x100a, 0x1014, 0x1031, 0x43f, 0x430, 0x441, 0x43b, 0x44f, 0x20, 0x43f, 0x430, 0x43b, 0x443, 0x434, 0x43d, 0x44f,
-0x179b, 0x17d2, 0x1784, 0x17b6, 0x1785, 0x70, 0x2e, 0x6d, 0x2e, 0x4e0b, 0x5348, 0xd801, 0xdc11, 0xd801, 0xdc23, 0x70, 0x6d, 0x69, 0x70, 0x2e,
-0x6e, 0x61, 0x63, 0x68, 0x6d, 0x2e, 0x3bc, 0x2e, 0x3bc, 0x2e, 0x5d0, 0x5d7, 0x5d4, 0x5f4, 0x5e6, 0x905, 0x92a, 0x930, 0x93e, 0x939,
-0x94d, 0x928, 0x64, 0x75, 0x2e, 0x65, 0x2e, 0x68, 0x2e, 0x5348, 0x5f8c, 0xc624, 0xd6c4, 0x5a, 0x2e, 0x4d, 0x57, 0x2e, 0xeab, 0xebc,
-0xeb1, 0xe87, 0xe97, 0xec8, 0xebd, 0xe87, 0x70, 0x113, 0x63, 0x70, 0x75, 0x73, 0x64, 0x69, 0x65, 0x6e, 0x101, 0x6d, 0x70, 0xf3,
-0x6b, 0x77, 0x61, 0x70, 0x6f, 0x70, 0x69, 0x65, 0x74, 0x43f, 0x43e, 0x43f, 0x43b, 0x430, 0x434, 0x43d, 0x435, 0x50, 0x54, 0x47,
-0x57, 0x4e, 0x909, 0x924, 0x94d, 0x924, 0x930, 0x20, 0x92e, 0x927, 0x94d, 0x92f, 0x93e, 0x928, 0x94d, 0x939, 0x63a, 0x2e, 0x648, 0x2e,
-0x628, 0x639, 0x62f, 0x627, 0x632, 0x638, 0x647, 0x631, 0xa2c, 0xa3e, 0xa05, 0xa26, 0x20, 0xa26, 0xa41, 0xa2a, 0xa39, 0xa3f, 0xa30, 0x73,
-0x6d, 0x43f, 0x43e, 0x441, 0x43b, 0x435, 0x20, 0x43f, 0x43e, 0x43b, 0x443, 0x434, 0x43d, 0x44f, 0x4c, 0x4b, 0x43f, 0x43e, 0x43f, 0x43e,
-0x434, 0x43d, 0x435, 0x70, 0x6f, 0x70, 0x6f, 0x64, 0x6e, 0x65, 0xdb4, 0x2e, 0xdc0, 0x2e, 0x70, 0x6f, 0x70, 0x6f, 0x6c, 0x75,
-0x64, 0x6e, 0xed, 0x70, 0x6f, 0x70, 0x2e, 0x67, 0x6e, 0x2e, 0x61, 0x6c, 0x61, 0x73, 0x69, 0x72, 0x69, 0x65, 0x6d, 0xe2b,
-0xe25, 0xe31, 0xe07, 0xe40, 0xe17, 0xe35, 0xe48, 0xe22, 0xe07, 0xf55, 0xfb1, 0xf72, 0xf0b, 0xf51, 0xfb2, 0xf7c, 0xf0b, 0x12f5, 0x1215, 0x122d,
-0x20, 0x1230, 0x12d3, 0x1275, 0xd6, 0x53, 0x43f, 0x43f, 0x631, 0x627, 0x62a, 0x43, 0x48, 0x1ecc, 0x300, 0x73, 0xe1, 0x6e, 0x4e, 0x74,
-0x61, 0x6d, 0x62, 0x61, 0x6d, 0x61, 0x65, 0x74, 0x74, 0x65, 0x72, 0x6d, 0x69, 0x64, 0x64, 0x61, 0x67, 0x45, 0x57, 0x92e,
-0x2e, 0x928, 0x902, 0x2e, 0x50, 0x2e, 0x4d, 0x2e, 0x128, 0x79, 0x61, 0x77, 0x129, 0x6f, 0x6f, 0x263, 0x65, 0x74, 0x72, 0x254,
-0x6e, 0x61, 0x6d, 0x2e, 0xa06f, 0xa2d2, 0x4d, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x2f, 0x4d, 0x6f, 0x67, 0x6c, 0x75, 0x6d, 0x61,
-0x20, 0x6c, 0x77, 0x61, 0x20, 0x70, 0x6b, 0x69, 0x6b, 0x69, 0x69, 0x257, 0x65, 0x48, 0x77, 0x61, 0x129, 0x2d, 0x69, 0x6e,
-0x129, 0x54, 0x65, 0x69, 0x70, 0x61, 0x6b, 0x69, 0x6e, 0x67, 0x6f, 0x74, 0x6f, 0x2d5c, 0x2d30, 0x2d37, 0x2d33, 0x2d33, 0x2d6f, 0x2d30,
-0x2d5c, 0x74, 0x61, 0x64, 0x67, 0x67, 0x2b7, 0x61, 0x74, 0x6e, 0x20, 0x74, 0x6d, 0x65, 0x64, 0x64, 0x69, 0x74, 0x70, 0x61,
-0x6d, 0x75, 0x6e, 0x79, 0x69, 0x6b, 0x79, 0x69, 0x75, 0x6b, 0x6f, 0x6e, 0x79, 0x69, 0x55, 0x54, 0x13d2, 0x13af, 0x13f1, 0x13a2,
-0x13d7, 0x13e2, 0x43, 0x68, 0x69, 0x6c, 0x6f, 0x4d, 0x55, 0x55, 0x61, 0x6b, 0x61, 0x73, 0x75, 0x62, 0x61, 0x168, 0x47, 0x4b,
-0x65, 0x6d, 0x6f, 0x1c3, 0x75, 0x69, 0x61, 0x73, 0x190, 0x6e, 0x64, 0xe1, 0x6d, 0xe2, 0x45, 0x69, 0x67, 0x75, 0x6c, 0x6f,
-0x69, 0x63, 0x68, 0x61, 0x6d, 0x74, 0x68, 0x69, 0x45, 0x62, 0x6f, 0x6e, 0x67, 0x69, 0x41, 0x6c, 0x75, 0x75, 0x6c, 0x61,
-0x4f, 0x54, 0x1e0c, 0x65, 0x66, 0x66, 0x69, 0x72, 0x20, 0x61, 0x7a, 0x61, 0x6e, 0x79, 0x69, 0x61, 0x67, 0x68, 0x75, 0x6f,
-0x92c, 0x947, 0x932, 0x93e, 0x938, 0x947, 0x44, 0x69, 0x6c, 0x6f, 0x6c, 0x6f, 0x61, 0x2e, 0x6b, 0x49, 0x20, 0x253, 0x75, 0x67,
-0x61, 0x6a, 0x254, 0x70, 0x5a, 0x61, 0x61, 0x72, 0x69, 0x6b, 0x61, 0x79, 0x20, 0x62, 0x65, 0x62, 0x79, 0xe1, 0x6d, 0x75,
-0x6e, 0x67, 0x259, 0x67, 0xf3, 0x67, 0x259, 0x6c, 0x65, 0x63, 0x25b, 0x25b, 0x301, 0x6e, 0x6b, 0x6f, 0x6d, 0x63, 0x68, 0x6f,
-0x63, 0x68, 0x69, 0x6c, 0x27, 0x6c, 0x6c, 0x69, 0x6c, 0x6c, 0x69, 0x6b, 0x75, 0x67, 0xfa, 0x54, 0x14a, 0x50, 0x61, 0x73,
-0x68, 0x61, 0x6d, 0x69, 0x68, 0x65, 0x79, 0x61, 0x20, 0x6d, 0x75, 0x63, 0x68, 0x61, 0x6e, 0x61, 0x6b, 0x69, 0x73, 0x25b,
-0x301, 0x6e, 0x64, 0x25b, 0x14b, 0x6b, 0x61, 0x20, 0x6d, 0x62, 0x254, 0x301, 0x74, 0x20, 0x6e, 0x6a, 0x69, 0x6e, 0x63, 0x77,
-0xf2, 0x6e, 0x7a, 0xe9, 0x6d
+0x50, 0x4d, 0x57, 0x42, 0x6e, 0x6d, 0x2e, 0x4d, 0x44, 0x12a8, 0x1230, 0x12d3, 0x1275, 0x645, 0x56f, 0x565, 0x57d, 0x585, 0x580, 0x56b,
+0x581, 0x20, 0x570, 0x565, 0x57f, 0x578, 0x985, 0x9aa, 0x9f0, 0x9be, 0x9b9, 0x9cd, 0x9a3, 0x985, 0x9aa, 0x9b0, 0x9be, 0x9b9, 0x9cd, 0x9a3,
+0xf55, 0xfb1, 0xf72, 0xf0b, 0xf46, 0xf0b, 0x441, 0x43b, 0x2e, 0x20, 0x43e, 0x431, 0x2e, 0x100a, 0x1014, 0x1031, 0x43f, 0x430, 0x441, 0x43b,
+0x44f, 0x20, 0x43f, 0x430, 0x43b, 0x443, 0x434, 0x43d, 0x44f, 0x179b, 0x17d2, 0x1784, 0x17b6, 0x1785, 0x70, 0x2e, 0x6d, 0x2e, 0x4e0b, 0x5348,
+0x6f, 0x64, 0x70, 0x2e, 0xd801, 0xdc11, 0xd801, 0xdc23, 0x70, 0x6d, 0x69, 0x70, 0x2e, 0x6e, 0x61, 0x63, 0x68, 0x6d, 0x2e, 0x3bc,
+0x2e, 0x3bc, 0x2e, 0x5d0, 0x5d7, 0x5d4, 0x5f4, 0x5e6, 0x905, 0x92a, 0x930, 0x93e, 0x939, 0x94d, 0x928, 0x64, 0x75, 0x2e, 0x65, 0x2e,
+0x68, 0x2e, 0x5348, 0x5f8c, 0xc624, 0xd6c4, 0x5a, 0x2e, 0x4d, 0x57, 0x2e, 0xeab, 0xebc, 0xeb1, 0xe87, 0xe97, 0xec8, 0xebd, 0xe87, 0x70,
+0x113, 0x63, 0x70, 0x75, 0x73, 0x64, 0x69, 0x65, 0x6e, 0x101, 0x6d, 0x70, 0xf3, 0x6b, 0x77, 0x61, 0x70, 0x6f, 0x70, 0x69,
+0x65, 0x74, 0x43f, 0x43e, 0x43f, 0x43b, 0x430, 0x434, 0x43d, 0x435, 0x50, 0x54, 0x47, 0x57, 0x4e, 0x4ae, 0x425, 0x909, 0x924, 0x94d,
+0x924, 0x930, 0x20, 0x92e, 0x927, 0x94d, 0x92f, 0x93e, 0x928, 0x94d, 0x939, 0x63a, 0x2e, 0x648, 0x2e, 0x628, 0x639, 0x62f, 0x627, 0x632,
+0x638, 0x647, 0x631, 0xa2c, 0xa3e, 0xa05, 0xa26, 0x20, 0xa26, 0xa41, 0xa2a, 0xa39, 0xa3f, 0xa30, 0x73, 0x6d, 0x43f, 0x43e, 0x441, 0x43b,
+0x435, 0x20, 0x43f, 0x43e, 0x43b, 0x443, 0x434, 0x43d, 0x44f, 0x4c, 0x4b, 0x43f, 0x43e, 0x43f, 0x43e, 0x434, 0x43d, 0x435, 0x70, 0x6f,
+0x70, 0x6f, 0x64, 0x6e, 0x65, 0xdb4, 0x2e, 0xdc0, 0x2e, 0x70, 0x6f, 0x70, 0x6f, 0x6c, 0x75, 0x64, 0x6e, 0xed, 0x70, 0x6f,
+0x70, 0x2e, 0x67, 0x6e, 0x2e, 0x61, 0x6c, 0x61, 0x73, 0x69, 0x72, 0x69, 0x65, 0x6d, 0xe2b, 0xe25, 0xe31, 0xe07, 0xe40, 0xe17,
+0xe35, 0xe48, 0xe22, 0xe07, 0xf55, 0xfb1, 0xf72, 0xf0b, 0xf51, 0xfb2, 0xf7c, 0xf0b, 0x12f5, 0x1215, 0x122d, 0x20, 0x1230, 0x12d3, 0x1275, 0xd6,
+0x53, 0x43f, 0x43f, 0x628, 0x639, 0x62f, 0x20, 0x62f, 0x648, 0x67e, 0x6c1, 0x631, 0x43, 0x48, 0x1ecc, 0x300, 0x73, 0xe1, 0x6e, 0x4e,
+0x74, 0x61, 0x6d, 0x62, 0x61, 0x6d, 0x61, 0x65, 0x74, 0x74, 0x65, 0x72, 0x6d, 0x69, 0x64, 0x64, 0x61, 0x67, 0x45, 0x57,
+0x92e, 0x2e, 0x928, 0x902, 0x2e, 0x50, 0x2e, 0x4d, 0x2e, 0x128, 0x79, 0x61, 0x77, 0x129, 0x6f, 0x6f, 0x263, 0x65, 0x74, 0x72,
+0x254, 0x6e, 0x61, 0x6d, 0x2e, 0xa06f, 0xa2d2, 0x4d, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x2f, 0x4d, 0x6f, 0x67, 0x6c, 0x75, 0x6d,
+0x61, 0x20, 0x6c, 0x77, 0x61, 0x20, 0x70, 0x6b, 0x69, 0x6b, 0x69, 0x69, 0x257, 0x65, 0x48, 0x77, 0x61, 0x129, 0x2d, 0x69,
+0x6e, 0x129, 0x54, 0x65, 0x69, 0x70, 0x61, 0x6b, 0x69, 0x6e, 0x67, 0x6f, 0x74, 0x6f, 0x2d5c, 0x2d30, 0x2d37, 0x2d33, 0x2d33, 0x2d6f,
+0x2d30, 0x2d5c, 0x74, 0x61, 0x64, 0x67, 0x67, 0x2b7, 0x61, 0x74, 0x6e, 0x20, 0x74, 0x6d, 0x65, 0x64, 0x64, 0x69, 0x74, 0x70,
+0x61, 0x6d, 0x75, 0x6e, 0x79, 0x69, 0x6b, 0x79, 0x69, 0x75, 0x6b, 0x6f, 0x6e, 0x79, 0x69, 0x55, 0x54, 0x13d2, 0x13af, 0x13f1,
+0x13a2, 0x13d7, 0x13e2, 0x43, 0x68, 0x69, 0x6c, 0x6f, 0x4d, 0x55, 0x55, 0x61, 0x6b, 0x61, 0x73, 0x75, 0x62, 0x61, 0x168, 0x47,
+0x4b, 0x65, 0x6d, 0x6f, 0x1c3, 0x75, 0x69, 0x61, 0x73, 0x190, 0x6e, 0x64, 0xe1, 0x6d, 0xe2, 0x45, 0x69, 0x67, 0x75, 0x6c,
+0x6f, 0x69, 0x63, 0x68, 0x61, 0x6d, 0x74, 0x68, 0x69, 0x45, 0x62, 0x6f, 0x6e, 0x67, 0x69, 0x41, 0x6c, 0x75, 0x75, 0x6c,
+0x61, 0x4f, 0x54, 0x1e0c, 0x65, 0x66, 0x66, 0x69, 0x72, 0x20, 0x61, 0x7a, 0x61, 0x6e, 0x79, 0x69, 0x61, 0x67, 0x68, 0x75,
+0x6f, 0x92c, 0x947, 0x932, 0x93e, 0x938, 0x947, 0x44, 0x69, 0x6c, 0x6f, 0x6c, 0x6f, 0x61, 0x2e, 0x6b, 0x49, 0x20, 0x253, 0x75,
+0x67, 0x61, 0x6a, 0x254, 0x70, 0x5a, 0x61, 0x61, 0x72, 0x69, 0x6b, 0x61, 0x79, 0x20, 0x62, 0x65, 0x62, 0x79, 0xe1, 0x6d,
+0x75, 0x6e, 0x67, 0x259, 0x67, 0xf3, 0x67, 0x259, 0x6c, 0x65, 0x63, 0x25b, 0x25b, 0x301, 0x6e, 0x6b, 0x6f, 0x6d, 0x63, 0x68,
+0x6f, 0x63, 0x68, 0x69, 0x6c, 0x27, 0x6c, 0x6c, 0x69, 0x6c, 0x6c, 0x69, 0x6b, 0x75, 0x67, 0xfa, 0x54, 0x14a, 0x50, 0x61,
+0x73, 0x68, 0x61, 0x6d, 0x69, 0x68, 0x65, 0x79, 0x61, 0x20, 0x6d, 0x75, 0x63, 0x68, 0x61, 0x6e, 0x61, 0x6b, 0x69, 0x73,
+0x25b, 0x301, 0x6e, 0x64, 0x25b, 0x14b, 0x6b, 0x61, 0x20, 0x6d, 0x62, 0x254, 0x301, 0x74, 0x20, 0x6e, 0x6a, 0x69, 0x6e, 0x63,
+0x77, 0xf2, 0x6e, 0x7a, 0xe9, 0x6d
};
static const ushort currency_symbol_data[] = {
-0x42, 0x72, 0x4b, 0x73, 0x68, 0x46, 0x64, 0x6a, 0x4e, 0x66, 0x6b, 0x52, 0x24, 0x4c, 0x65, 0x6b, 0x1265, 0x122d, 0x62c, 0x2e,
-0x645, 0x2e, 0x200f, 0x62f, 0x2e, 0x62c, 0x2e, 0x200f, 0x62f, 0x2e, 0x628, 0x2e, 0x200f, 0x46, 0x43, 0x46, 0x41, 0x641, 0x2e, 0x62c,
-0x2e, 0x642, 0x2e, 0x200f, 0x62f, 0x2e, 0x639, 0x2e, 0x200f, 0x20aa, 0x62f, 0x2e, 0x623, 0x2e, 0x200f, 0x62f, 0x2e, 0x643, 0x2e, 0x200f,
-0x644, 0x2e, 0x644, 0x2e, 0x200f, 0x62f, 0x2e, 0x644, 0x2e, 0x200f, 0x623, 0x2e, 0x645, 0x2e, 0x200f, 0x62f, 0x2e, 0x645, 0x2e, 0x200f,
-0x631, 0x2e, 0x639, 0x2e, 0x200f, 0x631, 0x2e, 0x642, 0x2e, 0x200f, 0x631, 0x2e, 0x633, 0x2e, 0x200f, 0x644, 0x2e, 0x633, 0x2e, 0x200f,
-0x62f, 0x2e, 0x62a, 0x2e, 0x200f, 0x62f, 0x2e, 0x625, 0x2e, 0x200f, 0x631, 0x2e, 0x64a, 0x2e, 0x200f, 0x564, 0x580, 0x2e, 0x20b9, 0x6d,
-0x61, 0x6e, 0x2e, 0x43c, 0x430, 0x43d, 0x2e, 0x20ac, 0x9f3, 0x4e, 0x75, 0x2e, 0x43b, 0x432, 0x2e, 0x4b, 0x17db, 0xffe5, 0x4e, 0x54,
-0x24, 0x6b, 0x6e, 0x4b, 0x10d, 0x6b, 0x72, 0x41, 0x66, 0x6c, 0x2e, 0x55, 0x53, 0x24, 0x45, 0x43, 0x24, 0x50, 0xa3, 0x41,
-0x24, 0x20a8, 0x20b1, 0x43, 0x46, 0x41, 0x46, 0x42, 0x75, 0x43, 0x46, 0x46, 0x43, 0x46, 0x50, 0x46, 0x47, 0x46, 0x72, 0x2e,
-0x56, 0x54, 0x20a6, 0x46, 0x74, 0x52, 0x70, 0x20b8, 0x52, 0x46, 0x441, 0x43e, 0x43c, 0x20a9, 0x20ad, 0x4c, 0x73, 0x46, 0x63, 0x46,
-0x20, 0x43, 0x46, 0x41, 0x4c, 0x74, 0x52, 0x4d, 0x928, 0x947, 0x930, 0x942, 0x60b, 0xfdfc, 0x7a, 0x142, 0x52, 0x24, 0x4b, 0x7a,
-0x4d, 0x54, 0x6e, 0x44, 0x62, 0x631, 0x440, 0x443, 0x431, 0x2e, 0x20b4, 0x434, 0x438, 0x43d, 0x2e, 0x41a, 0x41c, 0x2e, 0x4b, 0x4d,
-0x64, 0x69, 0x6e, 0x2e, 0xdbb, 0xdd4, 0x2e, 0x45, 0x45, 0x55, 0x52, 0x42, 0x73, 0x20a1, 0x51, 0x4c, 0x43, 0x24, 0x42, 0x2f,
-0x2e, 0x20b2, 0x53, 0x2f, 0x2e, 0x42, 0x73, 0x2e, 0x54, 0x53, 0x68, 0x53, 0x24, 0x52, 0x73, 0x2e, 0xe3f, 0x43, 0x4e, 0xa5,
-0x54, 0x24, 0x54, 0x4c, 0x50, 0x4b, 0x52, 0x73, 0x441, 0x45e, 0x43c, 0x73, 0x6f, 0x2bb, 0x6d, 0x20ab, 0x41a, 0x41c, 0x47, 0x48,
-0x20b5, 0x4e, 0x6b, 0x72, 0x44, 0x41, 0x55, 0x53, 0x68, 0x5a, 0x4b
+0x42, 0x72, 0x4b, 0x73, 0x68, 0x46, 0x64, 0x6a, 0x4e, 0x66, 0x6b, 0x52, 0x24, 0x4c, 0x65, 0x6b, 0x64, 0x65, 0x6e, 0x1265,
+0x122d, 0x62c, 0x2e, 0x645, 0x2e, 0x200f, 0x62f, 0x2e, 0x62c, 0x2e, 0x200f, 0x62f, 0x2e, 0x628, 0x2e, 0x200f, 0x46, 0x43, 0x46, 0x41,
+0x641, 0x2e, 0x62c, 0x2e, 0x642, 0x2e, 0x200f, 0x62f, 0x2e, 0x639, 0x2e, 0x200f, 0x20aa, 0x62f, 0x2e, 0x623, 0x2e, 0x200f, 0x62f, 0x2e,
+0x643, 0x2e, 0x200f, 0x644, 0x2e, 0x644, 0x2e, 0x200f, 0x62f, 0x2e, 0x644, 0x2e, 0x200f, 0x623, 0x2e, 0x645, 0x2e, 0x200f, 0x62f, 0x2e,
+0x645, 0x2e, 0x200f, 0x631, 0x2e, 0x639, 0x2e, 0x200f, 0x631, 0x2e, 0x642, 0x2e, 0x200f, 0x631, 0x2e, 0x633, 0x2e, 0x200f, 0x53, 0x644,
+0x2e, 0x633, 0x2e, 0x200f, 0x62f, 0x2e, 0x62a, 0x2e, 0x200f, 0x62f, 0x2e, 0x625, 0x2e, 0x200f, 0x631, 0x2e, 0x64a, 0x2e, 0x200f, 0x564,
+0x580, 0x2e, 0x20b9, 0x6d, 0x61, 0x6e, 0x2e, 0x43c, 0x430, 0x43d, 0x2e, 0x20ac, 0x9f3, 0x4e, 0x75, 0x2e, 0x43b, 0x432, 0x2e, 0x4b,
+0x440, 0x2e, 0x17db, 0xffe5, 0x4d, 0x4f, 0x50, 0x24, 0x4e, 0x54, 0x24, 0x6b, 0x6e, 0x4b, 0x4d, 0x4b, 0x10d, 0x6b, 0x72, 0x41,
+0x66, 0x6c, 0x2e, 0x4e, 0x41, 0x66, 0x2e, 0x45, 0x43, 0x24, 0x50, 0xa3, 0x44, 0x47, 0x48, 0x20b5, 0x41, 0x72, 0x4d, 0x4b,
+0x52, 0x73, 0x20a6, 0x20b1, 0x57, 0x53, 0x24, 0x53, 0x52, 0x4c, 0x65, 0x45, 0x54, 0x53, 0x68, 0x54, 0x24, 0x55, 0x53, 0x68,
+0x56, 0x54, 0x4b, 0x52, 0x55, 0x53, 0x24, 0x44, 0x41, 0x43, 0x46, 0x41, 0x46, 0x42, 0x75, 0x43, 0x46, 0x46, 0x43, 0x46,
+0x43, 0x46, 0x50, 0x46, 0x47, 0x47, 0x55, 0x4d, 0x52, 0x46, 0x43, 0x48, 0x46, 0x4c, 0x53, 0x44, 0x54, 0x46, 0x74, 0x52,
+0x70, 0x20b8, 0x441, 0x43e, 0x43c, 0x20a9, 0x20ad, 0x4c, 0x73, 0x4b, 0x7a, 0x4c, 0x74, 0x434, 0x435, 0x43d, 0x52, 0x4d, 0x20ae, 0x928,
+0x947, 0x930, 0x942, 0x60b, 0xfdfc, 0x7a, 0x142, 0x52, 0x24, 0x4d, 0x54, 0x6e, 0x44, 0x62, 0x631, 0x440, 0x443, 0x431, 0x2e, 0x20b4,
+0x434, 0x438, 0x43d, 0x2e, 0x41a, 0x41c, 0x64, 0x69, 0x6e, 0x2e, 0xdbb, 0xdd4, 0x2e, 0x42, 0x73, 0x20a1, 0x51, 0x4c, 0x43, 0x24,
+0x42, 0x2f, 0x2e, 0x20b2, 0x53, 0x2f, 0x2e, 0x42, 0x73, 0x2e, 0x52, 0x73, 0x2e, 0xe3f, 0xa5, 0x20ba, 0x441, 0x45e, 0x43c, 0x73,
+0x6f, 0x2bb, 0x6d, 0x20ab
};
static const ushort currency_display_name_data[] = {
@@ -4327,277 +4618,286 @@ static const ushort currency_display_name_data[] = {
0x20, 0x64a, 0x645, 0x646, 0x64a, 0x3b, 0x631, 0x64a, 0x627, 0x644, 0x20, 0x64a, 0x645, 0x646, 0x64a, 0x3b, 0x631, 0x64a, 0x627, 0x644,
0x20, 0x64a, 0x645, 0x646, 0x64a, 0x3b, 0x631, 0x64a, 0x627, 0x644, 0x20, 0x64a, 0x645, 0x646, 0x64a, 0x3b, 0x631, 0x64a, 0x627, 0x644,
0x20, 0x64a, 0x645, 0x646, 0x64a, 0x3b, 0x631, 0x64a, 0x627, 0x644, 0x20, 0x64a, 0x645, 0x646, 0x64a, 0x3b, 0x631, 0x64a, 0x627, 0x644,
-0x20, 0x64a, 0x645, 0x646, 0x64a, 0x3b, 0x41, 0x7a, 0x259, 0x72, 0x62, 0x61, 0x79, 0x63, 0x61, 0x6e, 0x20, 0x6d, 0x61, 0x6e,
-0x61, 0x74, 0x131, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x41, 0x7a, 0x259, 0x72, 0x62, 0x61, 0x79, 0x63, 0x61, 0x6e, 0x20,
-0x6d, 0x61, 0x6e, 0x61, 0x74, 0x131, 0x3b, 0x43c, 0x430, 0x43d, 0x430, 0x442, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x45,
-0x75, 0x72, 0x6f, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x9ac, 0x9be, 0x982, 0x9b2, 0x9be, 0x9a6, 0x9c7, 0x9b6, 0x9c0,
-0x20, 0x99f, 0x9be, 0x995, 0x9be, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x9ad, 0x9be, 0x9b0, 0x9a4, 0x9c0, 0x9af, 0x9bc, 0x20,
-0x9b0, 0x9c1, 0x9aa, 0x9bf, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xf51, 0xf44, 0xf74, 0xf63, 0xf0b, 0xf40, 0xfb2, 0xf58, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x411, 0x44a, 0x43b,
-0x433, 0x430, 0x440, 0x441, 0x43a, 0x438, 0x20, 0x43b, 0x435, 0x432, 0x3b, 0x3b, 0x431, 0x44a, 0x43b, 0x433, 0x430, 0x440, 0x441, 0x43a,
-0x438, 0x20, 0x43b, 0x435, 0x432, 0x3b, 0x3b, 0x3b, 0x3b, 0x431, 0x44a, 0x43b, 0x433, 0x430, 0x440, 0x441, 0x43a, 0x438, 0x20, 0x43b,
-0x435, 0x432, 0x430, 0x3b, 0x1019, 0x103c, 0x1014, 0x103a, 0x1019, 0x102c, 0x20, 0x1000, 0x103b, 0x1015, 0x103a, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x431, 0x435, 0x43b, 0x430, 0x440, 0x443, 0x441, 0x43a, 0x456, 0x20, 0x440, 0x443, 0x431, 0x435, 0x43b, 0x44c, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x179a, 0x17c0, 0x179b, 0x20, 0x1780, 0x1798, 0x17d2, 0x1796, 0x17bb, 0x1787, 0x17b6, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72,
-0x6f, 0x73, 0x3b, 0x4eba, 0x6c11, 0x5e01, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x6e2f, 0x5143, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x6fb3, 0x95e8, 0x5143, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x65b0, 0x52a0, 0x5761, 0x5143, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x6fb3, 0x9580, 0x5143, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x65b0, 0x81fa, 0x5e63, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x68, 0x72, 0x76, 0x61, 0x74, 0x73, 0x6b, 0x61, 0x20, 0x6b, 0x75, 0x6e, 0x61, 0x3b, 0x3b, 0x68, 0x72,
-0x76, 0x61, 0x74, 0x73, 0x6b, 0x61, 0x20, 0x6b, 0x75, 0x6e, 0x61, 0x3b, 0x3b, 0x68, 0x72, 0x76, 0x61, 0x74, 0x73, 0x6b,
-0x65, 0x20, 0x6b, 0x75, 0x6e, 0x65, 0x3b, 0x68, 0x72, 0x76, 0x61, 0x74, 0x73, 0x6b, 0x69, 0x68, 0x20, 0x6b, 0x75, 0x6e,
-0x61, 0x3b, 0x68, 0x72, 0x76, 0x61, 0x74, 0x73, 0x6b, 0x69, 0x68, 0x20, 0x6b, 0x75, 0x6e, 0x61, 0x3b, 0x6b, 0x6f, 0x6e,
-0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x61, 0x20, 0x6d, 0x61, 0x72, 0x6b, 0x61, 0x3b, 0x3b, 0x6b, 0x6f,
-0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x61, 0x20, 0x6d, 0x61, 0x72, 0x6b, 0x61, 0x3b, 0x3b, 0x6b,
-0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x3b, 0x6b,
-0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x69, 0x68, 0x20, 0x6d, 0x61, 0x72, 0x61, 0x6b, 0x61,
-0x3b, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x69, 0x68, 0x20, 0x6d, 0x61, 0x72, 0x61,
-0x6b, 0x61, 0x3b, 0x10d, 0x65, 0x73, 0x6b, 0xe1, 0x20, 0x6b, 0x6f, 0x72, 0x75, 0x6e, 0x61, 0x3b, 0x3b, 0x10d, 0x65, 0x73,
-0x6b, 0xe1, 0x20, 0x6b, 0x6f, 0x72, 0x75, 0x6e, 0x61, 0x3b, 0x3b, 0x10d, 0x65, 0x73, 0x6b, 0xe9, 0x20, 0x6b, 0x6f, 0x72,
-0x75, 0x6e, 0x79, 0x3b, 0x3b, 0x10d, 0x65, 0x73, 0x6b, 0xfd, 0x63, 0x68, 0x20, 0x6b, 0x6f, 0x72, 0x75, 0x6e, 0x3b, 0x44,
-0x61, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x65, 0x3b, 0x3b, 0x44, 0x61, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72,
-0x6f, 0x6e, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x44, 0x61, 0x6e, 0x73, 0x6b, 0x65, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x65, 0x72,
-0x3b, 0x45, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b,
-0x41, 0x72, 0x75, 0x62, 0x61, 0x61, 0x6e, 0x73, 0x65, 0x20, 0x66, 0x6c, 0x6f, 0x72, 0x69, 0x6e, 0x3b, 0x3b, 0x41, 0x72,
-0x75, 0x62, 0x61, 0x61, 0x6e, 0x73, 0x65, 0x20, 0x66, 0x6c, 0x6f, 0x72, 0x69, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x41, 0x72,
-0x75, 0x62, 0x61, 0x61, 0x6e, 0x73, 0x65, 0x20, 0x66, 0x6c, 0x6f, 0x72, 0x69, 0x6e, 0x3b, 0x53, 0x75, 0x72, 0x69, 0x6e,
-0x61, 0x61, 0x6d, 0x73, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x55,
-0x53, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x55, 0x53, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b,
-0x3b, 0x3b, 0x3b, 0x55, 0x53, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x45, 0x61, 0x73, 0x74, 0x20, 0x43,
-0x61, 0x72, 0x69, 0x62, 0x62, 0x65, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x45, 0x61, 0x73,
-0x74, 0x20, 0x43, 0x61, 0x72, 0x69, 0x62, 0x62, 0x65, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b,
-0x3b, 0x3b, 0x45, 0x61, 0x73, 0x74, 0x20, 0x43, 0x61, 0x72, 0x69, 0x62, 0x62, 0x65, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c,
-0x6c, 0x61, 0x72, 0x73, 0x3b, 0x41, 0x75, 0x73, 0x74, 0x72, 0x61, 0x6c, 0x69, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c,
-0x61, 0x72, 0x3b, 0x3b, 0x41, 0x75, 0x73, 0x74, 0x72, 0x61, 0x6c, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61,
-0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x41, 0x75, 0x73, 0x74, 0x72, 0x61, 0x6c, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c,
-0x61, 0x72, 0x73, 0x3b, 0x42, 0x61, 0x68, 0x61, 0x6d, 0x69, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b,
-0x3b, 0x42, 0x61, 0x68, 0x61, 0x6d, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b,
-0x42, 0x61, 0x68, 0x61, 0x6d, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x42, 0x61, 0x72,
-0x62, 0x61, 0x64, 0x69, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x42, 0x61, 0x72, 0x62, 0x61,
-0x64, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x42, 0x61, 0x72, 0x62, 0x61,
-0x64, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x42, 0x65, 0x6c, 0x69, 0x7a, 0x65, 0x20,
-0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x42, 0x65, 0x6c, 0x69, 0x7a, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61,
-0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x42, 0x65, 0x6c, 0x69, 0x7a, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b,
-0x42, 0x65, 0x72, 0x6d, 0x75, 0x64, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x42, 0x65, 0x72,
-0x6d, 0x75, 0x64, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x42, 0x65, 0x72, 0x6d,
-0x75, 0x64, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x42, 0x6f, 0x74, 0x73, 0x77, 0x61, 0x6e,
-0x61, 0x6e, 0x20, 0x50, 0x75, 0x6c, 0x61, 0x3b, 0x3b, 0x42, 0x6f, 0x74, 0x73, 0x77, 0x61, 0x6e, 0x61, 0x6e, 0x20, 0x70,
-0x75, 0x6c, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x42, 0x6f, 0x74, 0x73, 0x77, 0x61, 0x6e, 0x61, 0x6e, 0x20, 0x70, 0x75, 0x6c,
-0x61, 0x73, 0x3b, 0x43, 0x46, 0x41, 0x20, 0x46, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x43,
-0x46, 0x41, 0x20, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x3b, 0x3b, 0x43, 0x46, 0x41,
-0x20, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x43, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x61,
-0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x43, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x61, 0x6e, 0x20, 0x64,
-0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x43, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f,
-0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x43, 0x61, 0x79, 0x6d, 0x61, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73,
-0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x43, 0x61, 0x79, 0x6d, 0x61, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61,
-0x6e, 0x64, 0x73, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x43, 0x61, 0x79, 0x6d, 0x61, 0x6e,
-0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x46, 0x69, 0x6a,
-0x69, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x46, 0x69, 0x6a, 0x69, 0x61, 0x6e, 0x20, 0x64,
-0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x69, 0x6a, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c,
-0x61, 0x72, 0x73, 0x3b, 0x42, 0x72, 0x69, 0x74, 0x69, 0x73, 0x68, 0x20, 0x50, 0x6f, 0x75, 0x6e, 0x64, 0x3b, 0x3b, 0x42,
-0x72, 0x69, 0x74, 0x69, 0x73, 0x68, 0x20, 0x70, 0x6f, 0x75, 0x6e, 0x64, 0x3b, 0x3b, 0x3b, 0x3b, 0x42, 0x72, 0x69, 0x74,
-0x69, 0x73, 0x68, 0x20, 0x70, 0x6f, 0x75, 0x6e, 0x64, 0x73, 0x3b, 0x47, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x6e, 0x20, 0x44,
-0x61, 0x6c, 0x61, 0x73, 0x69, 0x3b, 0x3b, 0x47, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x61, 0x6c, 0x61, 0x73,
-0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x47, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x61, 0x6c, 0x61, 0x73, 0x69, 0x73,
-0x3b, 0x47, 0x68, 0x61, 0x6e, 0x61, 0x69, 0x61, 0x6e, 0x20, 0x43, 0x65, 0x64, 0x69, 0x3b, 0x3b, 0x47, 0x68, 0x61, 0x6e,
-0x61, 0x69, 0x61, 0x6e, 0x20, 0x63, 0x65, 0x64, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x47, 0x68, 0x61, 0x6e, 0x61, 0x69, 0x61,
-0x6e, 0x20, 0x63, 0x65, 0x64, 0x69, 0x73, 0x3b, 0x47, 0x69, 0x62, 0x72, 0x61, 0x6c, 0x74, 0x61, 0x72, 0x20, 0x50, 0x6f,
-0x75, 0x6e, 0x64, 0x3b, 0x3b, 0x47, 0x69, 0x62, 0x72, 0x61, 0x6c, 0x74, 0x61, 0x72, 0x20, 0x70, 0x6f, 0x75, 0x6e, 0x64,
-0x3b, 0x3b, 0x3b, 0x3b, 0x47, 0x69, 0x62, 0x72, 0x61, 0x6c, 0x74, 0x61, 0x72, 0x20, 0x70, 0x6f, 0x75, 0x6e, 0x64, 0x73,
-0x3b, 0x47, 0x75, 0x79, 0x61, 0x6e, 0x61, 0x65, 0x73, 0x65, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x47,
-0x75, 0x79, 0x61, 0x6e, 0x61, 0x65, 0x73, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x47,
-0x75, 0x79, 0x61, 0x6e, 0x61, 0x65, 0x73, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x48, 0x6f, 0x6e,
-0x67, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x48, 0x6f, 0x6e, 0x67, 0x20,
-0x4b, 0x6f, 0x6e, 0x67, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x48, 0x6f, 0x6e, 0x67, 0x20,
-0x4b, 0x6f, 0x6e, 0x67, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x49, 0x6e, 0x64, 0x69, 0x61, 0x6e, 0x20,
-0x52, 0x75, 0x70, 0x65, 0x65, 0x3b, 0x3b, 0x49, 0x6e, 0x64, 0x69, 0x61, 0x6e, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x3b,
-0x3b, 0x3b, 0x3b, 0x49, 0x6e, 0x64, 0x69, 0x61, 0x6e, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x73, 0x3b, 0x4a, 0x61, 0x6d,
-0x61, 0x69, 0x63, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x4a, 0x61, 0x6d, 0x61, 0x69, 0x63,
-0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x4a, 0x61, 0x6d, 0x61, 0x69, 0x63, 0x61,
-0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x6e, 0x20, 0x53, 0x68, 0x69,
-0x6c, 0x6c, 0x69, 0x6e, 0x67, 0x3b, 0x3b, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x6e, 0x20, 0x73, 0x68, 0x69, 0x6c, 0x6c, 0x69,
-0x6e, 0x67, 0x3b, 0x3b, 0x3b, 0x3b, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x6e, 0x20, 0x73, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e,
-0x67, 0x73, 0x3b, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x41, 0x66, 0x72, 0x69, 0x63, 0x61, 0x6e, 0x20, 0x52, 0x61, 0x6e,
-0x64, 0x3b, 0x3b, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x41, 0x66, 0x72, 0x69, 0x63, 0x61, 0x6e, 0x20, 0x72, 0x61, 0x6e,
-0x64, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x41, 0x66, 0x72, 0x69, 0x63, 0x61, 0x6e, 0x20, 0x72,
-0x61, 0x6e, 0x64, 0x3b, 0x4c, 0x69, 0x62, 0x65, 0x72, 0x69, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b,
-0x3b, 0x4c, 0x69, 0x62, 0x65, 0x72, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b,
-0x4c, 0x69, 0x62, 0x65, 0x72, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x4d, 0x61, 0x6c,
-0x61, 0x67, 0x61, 0x73, 0x79, 0x20, 0x41, 0x72, 0x69, 0x61, 0x72, 0x79, 0x3b, 0x3b, 0x4d, 0x61, 0x6c, 0x61, 0x67, 0x61,
-0x73, 0x79, 0x20, 0x41, 0x72, 0x69, 0x61, 0x72, 0x79, 0x3b, 0x3b, 0x3b, 0x3b, 0x4d, 0x61, 0x6c, 0x61, 0x67, 0x61, 0x73,
-0x79, 0x20, 0x41, 0x72, 0x69, 0x61, 0x72, 0x69, 0x65, 0x73, 0x3b, 0x4d, 0x61, 0x6c, 0x61, 0x77, 0x69, 0x61, 0x6e, 0x20,
-0x4b, 0x77, 0x61, 0x63, 0x68, 0x61, 0x3b, 0x3b, 0x4d, 0x61, 0x6c, 0x61, 0x77, 0x69, 0x61, 0x6e, 0x20, 0x4b, 0x77, 0x61,
-0x63, 0x68, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x4d, 0x61, 0x6c, 0x61, 0x77, 0x69, 0x61, 0x6e, 0x20, 0x4b, 0x77, 0x61, 0x63,
-0x68, 0x61, 0x73, 0x3b, 0x4d, 0x61, 0x75, 0x72, 0x69, 0x74, 0x69, 0x61, 0x6e, 0x20, 0x52, 0x75, 0x70, 0x65, 0x65, 0x3b,
-0x3b, 0x4d, 0x61, 0x75, 0x72, 0x69, 0x74, 0x69, 0x61, 0x6e, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x3b, 0x3b, 0x3b, 0x3b,
-0x4d, 0x61, 0x75, 0x72, 0x69, 0x74, 0x69, 0x61, 0x6e, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x73, 0x3b, 0x4e, 0x61, 0x6d,
-0x69, 0x62, 0x69, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x4e, 0x61, 0x6d, 0x69, 0x62, 0x69,
-0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x61, 0x6d, 0x69, 0x62, 0x69, 0x61,
-0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x4e, 0x65, 0x77, 0x20, 0x5a, 0x65, 0x61, 0x6c, 0x61, 0x6e,
-0x64, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x4e, 0x65, 0x77, 0x20, 0x5a, 0x65, 0x61, 0x6c, 0x61, 0x6e,
-0x64, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x65, 0x77, 0x20, 0x5a, 0x65, 0x61, 0x6c,
-0x61, 0x6e, 0x64, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x4e, 0x69, 0x67, 0x65, 0x72, 0x69, 0x61, 0x6e,
-0x20, 0x4e, 0x61, 0x69, 0x72, 0x61, 0x3b, 0x3b, 0x4e, 0x69, 0x67, 0x65, 0x72, 0x69, 0x61, 0x6e, 0x20, 0x6e, 0x61, 0x69,
-0x72, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x69, 0x67, 0x65, 0x72, 0x69, 0x61, 0x6e, 0x20, 0x6e, 0x61, 0x69, 0x72, 0x61,
-0x73, 0x3b, 0x50, 0x61, 0x6b, 0x69, 0x73, 0x74, 0x61, 0x6e, 0x69, 0x20, 0x52, 0x75, 0x70, 0x65, 0x65, 0x3b, 0x3b, 0x50,
-0x61, 0x6b, 0x69, 0x73, 0x74, 0x61, 0x6e, 0x69, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x50, 0x61,
-0x6b, 0x69, 0x73, 0x74, 0x61, 0x6e, 0x69, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x73, 0x3b, 0x50, 0x61, 0x70, 0x75, 0x61,
-0x20, 0x4e, 0x65, 0x77, 0x20, 0x47, 0x75, 0x69, 0x6e, 0x65, 0x61, 0x6e, 0x20, 0x4b, 0x69, 0x6e, 0x61, 0x3b, 0x3b, 0x50,
-0x61, 0x70, 0x75, 0x61, 0x20, 0x4e, 0x65, 0x77, 0x20, 0x47, 0x75, 0x69, 0x6e, 0x65, 0x61, 0x6e, 0x20, 0x6b, 0x69, 0x6e,
-0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x50, 0x61, 0x70, 0x75, 0x61, 0x20, 0x4e, 0x65, 0x77, 0x20, 0x47, 0x75, 0x69, 0x6e, 0x65,
-0x61, 0x6e, 0x20, 0x6b, 0x69, 0x6e, 0x61, 0x3b, 0x50, 0x65, 0x73, 0x6f, 0x3b, 0x3b, 0x50, 0x68, 0x69, 0x6c, 0x69, 0x70,
-0x70, 0x69, 0x6e, 0x65, 0x20, 0x70, 0x65, 0x73, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x50, 0x68, 0x69, 0x6c, 0x69, 0x70, 0x70,
-0x69, 0x6e, 0x65, 0x20, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x3b, 0x53, 0x61, 0x6d, 0x6f, 0x61, 0x6e, 0x20, 0x54, 0x61, 0x6c,
-0x61, 0x3b, 0x3b, 0x53, 0x61, 0x6d, 0x6f, 0x61, 0x6e, 0x20, 0x74, 0x61, 0x6c, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x61,
-0x6d, 0x6f, 0x61, 0x6e, 0x20, 0x74, 0x61, 0x6c, 0x61, 0x3b, 0x53, 0x65, 0x79, 0x63, 0x68, 0x65, 0x6c, 0x6c, 0x6f, 0x69,
-0x73, 0x20, 0x52, 0x75, 0x70, 0x65, 0x65, 0x3b, 0x3b, 0x53, 0x65, 0x79, 0x63, 0x68, 0x65, 0x6c, 0x6c, 0x6f, 0x69, 0x73,
-0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x65, 0x79, 0x63, 0x68, 0x65, 0x6c, 0x6c, 0x6f, 0x69,
-0x73, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x73, 0x3b, 0x53, 0x69, 0x65, 0x72, 0x72, 0x61, 0x20, 0x4c, 0x65, 0x6f, 0x6e,
-0x65, 0x61, 0x6e, 0x20, 0x4c, 0x65, 0x6f, 0x6e, 0x65, 0x3b, 0x3b, 0x53, 0x69, 0x65, 0x72, 0x72, 0x61, 0x20, 0x4c, 0x65,
-0x6f, 0x6e, 0x65, 0x61, 0x6e, 0x20, 0x6c, 0x65, 0x6f, 0x6e, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69, 0x65, 0x72, 0x72,
-0x61, 0x20, 0x4c, 0x65, 0x6f, 0x6e, 0x65, 0x61, 0x6e, 0x20, 0x6c, 0x65, 0x6f, 0x6e, 0x65, 0x73, 0x3b, 0x53, 0x69, 0x6e,
-0x67, 0x61, 0x70, 0x6f, 0x72, 0x65, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x53, 0x69, 0x6e, 0x67, 0x61,
-0x70, 0x6f, 0x72, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69, 0x6e, 0x67, 0x61,
-0x70, 0x6f, 0x72, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x53, 0x6f, 0x6c, 0x6f, 0x6d, 0x6f, 0x6e,
-0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x53, 0x6f, 0x6c,
-0x6f, 0x6d, 0x6f, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b,
-0x3b, 0x3b, 0x3b, 0x53, 0x6f, 0x6c, 0x6f, 0x6d, 0x6f, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x20, 0x64,
-0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x53, 0x77, 0x61, 0x7a, 0x69, 0x20, 0x4c, 0x69, 0x6c, 0x61, 0x6e, 0x67, 0x65,
-0x6e, 0x69, 0x3b, 0x3b, 0x53, 0x77, 0x61, 0x7a, 0x69, 0x20, 0x6c, 0x69, 0x6c, 0x61, 0x6e, 0x67, 0x65, 0x6e, 0x69, 0x3b,
-0x3b, 0x3b, 0x3b, 0x53, 0x77, 0x61, 0x7a, 0x69, 0x20, 0x65, 0x6d, 0x61, 0x6c, 0x61, 0x6e, 0x67, 0x65, 0x6e, 0x69, 0x3b,
-0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x6e, 0x20, 0x53, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e, 0x67, 0x3b, 0x3b,
-0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x6e, 0x20, 0x73, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e, 0x67, 0x3b, 0x3b,
-0x3b, 0x3b, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x6e, 0x20, 0x73, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e, 0x67,
-0x73, 0x3b, 0x54, 0x6f, 0x6e, 0x67, 0x61, 0x6e, 0x20, 0x50, 0x61, 0x2bb, 0x61, 0x6e, 0x67, 0x61, 0x3b, 0x3b, 0x54, 0x6f,
-0x6e, 0x67, 0x61, 0x6e, 0x20, 0x70, 0x61, 0x2bb, 0x61, 0x6e, 0x67, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x54, 0x6f, 0x6e, 0x67,
-0x61, 0x6e, 0x20, 0x70, 0x61, 0x2bb, 0x61, 0x6e, 0x67, 0x61, 0x3b, 0x54, 0x72, 0x69, 0x6e, 0x69, 0x64, 0x61, 0x64, 0x20,
-0x61, 0x6e, 0x64, 0x20, 0x54, 0x6f, 0x62, 0x61, 0x67, 0x6f, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x54,
-0x72, 0x69, 0x6e, 0x69, 0x64, 0x61, 0x64, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x54, 0x6f, 0x62, 0x61, 0x67, 0x6f, 0x20, 0x64,
-0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x54, 0x72, 0x69, 0x6e, 0x69, 0x64, 0x61, 0x64, 0x20, 0x61, 0x6e,
-0x64, 0x20, 0x54, 0x6f, 0x62, 0x61, 0x67, 0x6f, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x55, 0x67, 0x61,
-0x6e, 0x64, 0x61, 0x6e, 0x20, 0x53, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e, 0x67, 0x3b, 0x3b, 0x55, 0x67, 0x61, 0x6e, 0x64,
-0x61, 0x6e, 0x20, 0x73, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e, 0x67, 0x3b, 0x3b, 0x3b, 0x3b, 0x55, 0x67, 0x61, 0x6e, 0x64,
-0x61, 0x6e, 0x20, 0x73, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e, 0x67, 0x73, 0x3b, 0x56, 0x61, 0x6e, 0x75, 0x61, 0x74, 0x75,
-0x20, 0x56, 0x61, 0x74, 0x75, 0x3b, 0x3b, 0x56, 0x61, 0x6e, 0x75, 0x61, 0x74, 0x75, 0x20, 0x76, 0x61, 0x74, 0x75, 0x3b,
-0x3b, 0x3b, 0x3b, 0x56, 0x61, 0x6e, 0x75, 0x61, 0x74, 0x75, 0x20, 0x76, 0x61, 0x74, 0x75, 0x73, 0x3b, 0x5a, 0x61, 0x6d,
-0x62, 0x69, 0x61, 0x6e, 0x20, 0x4b, 0x77, 0x61, 0x63, 0x68, 0x61, 0x3b, 0x3b, 0x5a, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x6e,
-0x20, 0x6b, 0x77, 0x61, 0x63, 0x68, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x5a, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x6e, 0x20, 0x6b,
-0x77, 0x61, 0x63, 0x68, 0x61, 0x73, 0x3b, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x53, 0x75, 0x64, 0x61, 0x6e, 0x65, 0x73,
-0x65, 0x20, 0x50, 0x6f, 0x75, 0x6e, 0x64, 0x3b, 0x3b, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x53, 0x75, 0x64, 0x61, 0x6e,
-0x65, 0x73, 0x65, 0x20, 0x70, 0x6f, 0x75, 0x6e, 0x64, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x53,
-0x75, 0x64, 0x61, 0x6e, 0x65, 0x73, 0x65, 0x20, 0x70, 0x6f, 0x75, 0x6e, 0x64, 0x73, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b,
-0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x74, 0x3b, 0x64, 0x6f, 0x6e, 0x73, 0x6b,
-0x20, 0x6b, 0x72, 0xf3, 0x6e, 0x61, 0x3b, 0x3b, 0x64, 0x6f, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0xf3, 0x6e, 0x61, 0x3b,
-0x3b, 0x3b, 0x3b, 0x64, 0x6f, 0x6e, 0x73, 0x6b, 0x61, 0x20, 0x6b, 0x72, 0xf3, 0x6e, 0x75, 0x72, 0x3b, 0x65, 0x75, 0x72,
-0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x61, 0x3b, 0x64, 0x69, 0x6e,
-0x61, 0x72, 0x20, 0x61, 0x6c, 0x67, 0xe9, 0x72, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x20, 0x61,
-0x6c, 0x67, 0xe9, 0x72, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x73, 0x20, 0x61, 0x6c,
-0x67, 0xe9, 0x72, 0x69, 0x65, 0x6e, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x41, 0x20, 0x28, 0x42,
-0x43, 0x45, 0x41, 0x4f, 0x29, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x41, 0x20, 0x28, 0x42, 0x43,
-0x45, 0x41, 0x4f, 0x29, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x43, 0x46, 0x41, 0x20, 0x28,
-0x42, 0x43, 0x45, 0x41, 0x4f, 0x29, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x62, 0x75, 0x72, 0x75, 0x6e, 0x64, 0x61,
-0x69, 0x73, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x62, 0x75, 0x72, 0x75, 0x6e, 0x64, 0x61, 0x69, 0x73, 0x3b,
-0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x62, 0x75, 0x72, 0x75, 0x6e, 0x64, 0x61, 0x69, 0x73, 0x3b,
-0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x41, 0x20, 0x28, 0x42, 0x45, 0x41, 0x43, 0x29, 0x3b, 0x3b, 0x66, 0x72,
-0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x41, 0x20, 0x28, 0x42, 0x45, 0x41, 0x43, 0x29, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72,
-0x61, 0x6e, 0x63, 0x73, 0x20, 0x43, 0x46, 0x41, 0x20, 0x28, 0x42, 0x45, 0x41, 0x43, 0x29, 0x3b, 0x64, 0x6f, 0x6c, 0x6c,
-0x61, 0x72, 0x20, 0x63, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x20,
-0x63, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x20,
-0x63, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x65, 0x6e, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x63, 0x6f, 0x6d, 0x6f,
-0x72, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x63, 0x6f, 0x6d, 0x6f, 0x72, 0x69, 0x65, 0x6e,
-0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x63, 0x6f, 0x6d, 0x6f, 0x72, 0x69, 0x65, 0x6e, 0x73,
-0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x63, 0x6f, 0x6e, 0x67, 0x6f, 0x6c, 0x61, 0x69, 0x73, 0x3b, 0x3b, 0x66, 0x72,
-0x61, 0x6e, 0x63, 0x20, 0x63, 0x6f, 0x6e, 0x67, 0x6f, 0x6c, 0x61, 0x69, 0x73, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61,
-0x6e, 0x63, 0x73, 0x20, 0x63, 0x6f, 0x6e, 0x67, 0x6f, 0x6c, 0x61, 0x69, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20,
-0x64, 0x6a, 0x69, 0x62, 0x6f, 0x75, 0x74, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x64, 0x6a,
-0x69, 0x62, 0x6f, 0x75, 0x74, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x64,
-0x6a, 0x69, 0x62, 0x6f, 0x75, 0x74, 0x69, 0x65, 0x6e, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x50,
-0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x50, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63,
-0x73, 0x20, 0x43, 0x46, 0x50, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x67, 0x75, 0x69, 0x6e, 0xe9, 0x65, 0x6e, 0x3b,
-0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x67, 0x75, 0x69, 0x6e, 0xe9, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72,
-0x61, 0x6e, 0x63, 0x73, 0x20, 0x67, 0x75, 0x69, 0x6e, 0xe9, 0x65, 0x6e, 0x73, 0x3b, 0x67, 0x6f, 0x75, 0x72, 0x64, 0x65,
-0x20, 0x68, 0x61, 0xef, 0x74, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x3b, 0x3b, 0x67, 0x6f, 0x75, 0x72, 0x64, 0x65, 0x20, 0x68,
-0x61, 0xef, 0x74, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x67, 0x6f, 0x75, 0x72, 0x64, 0x65, 0x73, 0x20,
-0x68, 0x61, 0xef, 0x74, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x73, 0x3b, 0x61, 0x72, 0x69, 0x61, 0x72, 0x79, 0x20, 0x6d, 0x61,
-0x6c, 0x67, 0x61, 0x63, 0x68, 0x65, 0x3b, 0x3b, 0x61, 0x72, 0x69, 0x61, 0x72, 0x79, 0x20, 0x6d, 0x61, 0x6c, 0x67, 0x61,
-0x63, 0x68, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x61, 0x72, 0x69, 0x61, 0x72, 0x79, 0x73, 0x20, 0x6d, 0x61, 0x6c, 0x67, 0x61,
-0x63, 0x68, 0x65, 0x73, 0x3b, 0x6f, 0x75, 0x67, 0x75, 0x69, 0x79, 0x61, 0x20, 0x6d, 0x61, 0x75, 0x72, 0x69, 0x74, 0x61,
-0x6e, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x6f, 0x75, 0x67, 0x75, 0x69, 0x79, 0x61, 0x20, 0x6d, 0x61, 0x75, 0x72, 0x69, 0x74,
-0x61, 0x6e, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x6f, 0x75, 0x67, 0x75, 0x69, 0x79, 0x61, 0x73, 0x20, 0x6d, 0x61,
-0x75, 0x72, 0x69, 0x74, 0x61, 0x6e, 0x69, 0x65, 0x6e, 0x73, 0x3b, 0x72, 0x6f, 0x75, 0x70, 0x69, 0x65, 0x20, 0x6d, 0x61,
-0x75, 0x72, 0x69, 0x63, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x3b, 0x3b, 0x72, 0x6f, 0x75, 0x70, 0x69, 0x65, 0x20, 0x6d, 0x61,
-0x75, 0x72, 0x69, 0x63, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x72, 0x6f, 0x75, 0x70, 0x69, 0x65, 0x73,
-0x20, 0x6d, 0x61, 0x75, 0x72, 0x69, 0x63, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x73, 0x3b, 0x64, 0x69, 0x72, 0x68, 0x61, 0x6d,
-0x20, 0x6d, 0x61, 0x72, 0x6f, 0x63, 0x61, 0x69, 0x6e, 0x3b, 0x3b, 0x64, 0x69, 0x72, 0x68, 0x61, 0x6d, 0x20, 0x6d, 0x61,
-0x72, 0x6f, 0x63, 0x61, 0x69, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x64, 0x69, 0x72, 0x68, 0x61, 0x6d, 0x73, 0x20, 0x6d, 0x61,
-0x72, 0x6f, 0x63, 0x61, 0x69, 0x6e, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x72, 0x77, 0x61, 0x6e, 0x64, 0x61,
-0x69, 0x73, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x72, 0x77, 0x61, 0x6e, 0x64, 0x61, 0x69, 0x73, 0x3b, 0x3b,
-0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x72, 0x77, 0x61, 0x6e, 0x64, 0x61, 0x69, 0x73, 0x3b, 0x72, 0x6f,
-0x75, 0x70, 0x69, 0x65, 0x20, 0x64, 0x65, 0x73, 0x20, 0x53, 0x65, 0x79, 0x63, 0x68, 0x65, 0x6c, 0x6c, 0x65, 0x73, 0x3b,
+0x20, 0x64a, 0x645, 0x646, 0x64a, 0x3b, 0x540, 0x561, 0x575, 0x56f, 0x561, 0x56f, 0x561, 0x576, 0x20, 0x564, 0x580, 0x561, 0x574, 0x3b,
+0x3b, 0x540, 0x561, 0x575, 0x56f, 0x561, 0x56f, 0x561, 0x576, 0x20, 0x564, 0x580, 0x561, 0x574, 0x3b, 0x3b, 0x3b, 0x3b, 0x540, 0x561,
+0x575, 0x56f, 0x561, 0x56f, 0x561, 0x576, 0x20, 0x564, 0x580, 0x561, 0x574, 0x3b, 0x41, 0x7a, 0x259, 0x72, 0x62, 0x61, 0x79, 0x63,
+0x61, 0x6e, 0x20, 0x6d, 0x61, 0x6e, 0x61, 0x74, 0x131, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x41, 0x7a, 0x259, 0x72, 0x62,
+0x61, 0x79, 0x63, 0x61, 0x6e, 0x20, 0x6d, 0x61, 0x6e, 0x61, 0x74, 0x131, 0x3b, 0x43c, 0x430, 0x43d, 0x430, 0x442, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x45, 0x75, 0x72, 0x6f, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x9ac, 0x9be, 0x982,
+0x9b2, 0x9be, 0x9a6, 0x9c7, 0x9b6, 0x9c0, 0x20, 0x99f, 0x9be, 0x995, 0x9be, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x9ad, 0x9be,
+0x9b0, 0x9a4, 0x9c0, 0x9af, 0x9bc, 0x20, 0x9b0, 0x9c1, 0x9aa, 0x9bf, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xf51, 0xf44, 0xf74,
+0xf63, 0xf0b, 0xf40, 0xfb2, 0xf58, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x411, 0x44a, 0x43b, 0x433, 0x430, 0x440, 0x441, 0x43a, 0x438, 0x20, 0x43b, 0x435, 0x432, 0x3b, 0x3b, 0x431, 0x44a,
+0x43b, 0x433, 0x430, 0x440, 0x441, 0x43a, 0x438, 0x20, 0x43b, 0x435, 0x432, 0x3b, 0x3b, 0x3b, 0x3b, 0x431, 0x44a, 0x43b, 0x433, 0x430,
+0x440, 0x441, 0x43a, 0x438, 0x20, 0x43b, 0x435, 0x432, 0x430, 0x3b, 0x1019, 0x103c, 0x1014, 0x103a, 0x1019, 0x102c, 0x20, 0x1000, 0x103b, 0x1015,
+0x103a, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x431, 0x435, 0x43b, 0x430, 0x440, 0x443, 0x441, 0x43a, 0x456, 0x20, 0x440, 0x443,
+0x431, 0x435, 0x43b, 0x44c, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x179a, 0x17c0, 0x179b, 0x20, 0x1780, 0x1798, 0x17d2, 0x1796, 0x17bb,
+0x1787, 0x17b6, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b,
+0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x73, 0x3b, 0x4eba, 0x6c11, 0x5e01, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x6e2f,
+0x5143, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x6fb3, 0x95e8, 0x5143, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x65b0, 0x52a0,
+0x5761, 0x5143, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x6fb3, 0x9580, 0x5143, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x65b0,
+0x81fa, 0x5e63, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x68, 0x72, 0x76, 0x61, 0x74, 0x73, 0x6b, 0x61, 0x20, 0x6b, 0x75,
+0x6e, 0x61, 0x3b, 0x3b, 0x68, 0x72, 0x76, 0x61, 0x74, 0x73, 0x6b, 0x61, 0x20, 0x6b, 0x75, 0x6e, 0x61, 0x3b, 0x3b, 0x68,
+0x72, 0x76, 0x61, 0x74, 0x73, 0x6b, 0x65, 0x20, 0x6b, 0x75, 0x6e, 0x65, 0x3b, 0x68, 0x72, 0x76, 0x61, 0x74, 0x73, 0x6b,
+0x69, 0x68, 0x20, 0x6b, 0x75, 0x6e, 0x61, 0x3b, 0x68, 0x72, 0x76, 0x61, 0x74, 0x73, 0x6b, 0x69, 0x68, 0x20, 0x6b, 0x75,
+0x6e, 0x61, 0x3b, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x61, 0x20, 0x6d, 0x61, 0x72,
+0x6b, 0x61, 0x3b, 0x3b, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x61, 0x20, 0x6d, 0x61,
+0x72, 0x6b, 0x61, 0x3b, 0x3b, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x65, 0x20, 0x6d,
+0x61, 0x72, 0x6b, 0x65, 0x3b, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x69, 0x68, 0x20,
+0x6d, 0x61, 0x72, 0x61, 0x6b, 0x61, 0x3b, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x69,
+0x68, 0x20, 0x6d, 0x61, 0x72, 0x61, 0x6b, 0x61, 0x3b, 0x10d, 0x65, 0x73, 0x6b, 0xe1, 0x20, 0x6b, 0x6f, 0x72, 0x75, 0x6e,
+0x61, 0x3b, 0x3b, 0x10d, 0x65, 0x73, 0x6b, 0xe1, 0x20, 0x6b, 0x6f, 0x72, 0x75, 0x6e, 0x61, 0x3b, 0x3b, 0x10d, 0x65, 0x73,
+0x6b, 0xe9, 0x20, 0x6b, 0x6f, 0x72, 0x75, 0x6e, 0x79, 0x3b, 0x3b, 0x10d, 0x65, 0x73, 0x6b, 0xfd, 0x63, 0x68, 0x20, 0x6b,
+0x6f, 0x72, 0x75, 0x6e, 0x3b, 0x44, 0x61, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x65, 0x3b, 0x3b, 0x44, 0x61,
+0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x44, 0x61, 0x6e, 0x73, 0x6b, 0x65, 0x20,
+0x6b, 0x72, 0x6f, 0x6e, 0x65, 0x72, 0x3b, 0x45, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b,
+0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x41, 0x72, 0x75, 0x62, 0x61, 0x61, 0x6e, 0x73, 0x65, 0x20, 0x66, 0x6c, 0x6f, 0x72,
+0x69, 0x6e, 0x3b, 0x3b, 0x41, 0x72, 0x75, 0x62, 0x61, 0x61, 0x6e, 0x73, 0x65, 0x20, 0x66, 0x6c, 0x6f, 0x72, 0x69, 0x6e,
+0x3b, 0x3b, 0x3b, 0x3b, 0x41, 0x72, 0x75, 0x62, 0x61, 0x61, 0x6e, 0x73, 0x65, 0x20, 0x66, 0x6c, 0x6f, 0x72, 0x69, 0x6e,
+0x3b, 0x4e, 0x65, 0x64, 0x65, 0x72, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x2d, 0x41, 0x6e, 0x74, 0x69, 0x6c, 0x6c, 0x69, 0x61,
+0x61, 0x6e, 0x73, 0x65, 0x20, 0x67, 0x75, 0x6c, 0x64, 0x65, 0x6e, 0x3b, 0x3b, 0x4e, 0x65, 0x64, 0x65, 0x72, 0x6c, 0x61,
+0x6e, 0x64, 0x73, 0x2d, 0x41, 0x6e, 0x74, 0x69, 0x6c, 0x6c, 0x69, 0x61, 0x61, 0x6e, 0x73, 0x65, 0x20, 0x67, 0x75, 0x6c,
+0x64, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x65, 0x64, 0x65, 0x72, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x2d, 0x41, 0x6e,
+0x74, 0x69, 0x6c, 0x6c, 0x69, 0x61, 0x61, 0x6e, 0x73, 0x65, 0x20, 0x67, 0x75, 0x6c, 0x64, 0x65, 0x6e, 0x3b, 0x53, 0x75,
+0x72, 0x69, 0x6e, 0x61, 0x61, 0x6d, 0x73, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x55, 0x53, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x55, 0x53, 0x20, 0x64, 0x6f, 0x6c, 0x6c,
+0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x55, 0x53, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x45, 0x61, 0x73,
+0x74, 0x20, 0x43, 0x61, 0x72, 0x69, 0x62, 0x62, 0x65, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b,
+0x45, 0x61, 0x73, 0x74, 0x20, 0x43, 0x61, 0x72, 0x69, 0x62, 0x62, 0x65, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61,
+0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x45, 0x61, 0x73, 0x74, 0x20, 0x43, 0x61, 0x72, 0x69, 0x62, 0x62, 0x65, 0x61, 0x6e, 0x20,
+0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x41, 0x75, 0x73, 0x74, 0x72, 0x61, 0x6c, 0x69, 0x61, 0x6e, 0x20, 0x44,
+0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x41, 0x75, 0x73, 0x74, 0x72, 0x61, 0x6c, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f,
+0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x41, 0x75, 0x73, 0x74, 0x72, 0x61, 0x6c, 0x69, 0x61, 0x6e, 0x20, 0x64,
+0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x42, 0x61, 0x68, 0x61, 0x6d, 0x69, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c,
+0x61, 0x72, 0x3b, 0x3b, 0x42, 0x61, 0x68, 0x61, 0x6d, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b,
+0x3b, 0x3b, 0x3b, 0x42, 0x61, 0x68, 0x61, 0x6d, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b,
+0x42, 0x61, 0x72, 0x62, 0x61, 0x64, 0x69, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x42, 0x61,
+0x72, 0x62, 0x61, 0x64, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x42, 0x61,
+0x72, 0x62, 0x61, 0x64, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x42, 0x65, 0x6c, 0x69,
+0x7a, 0x65, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x42, 0x65, 0x6c, 0x69, 0x7a, 0x65, 0x20, 0x64, 0x6f,
+0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x42, 0x65, 0x6c, 0x69, 0x7a, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61,
+0x72, 0x73, 0x3b, 0x42, 0x65, 0x72, 0x6d, 0x75, 0x64, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b,
+0x42, 0x65, 0x72, 0x6d, 0x75, 0x64, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x42,
+0x65, 0x72, 0x6d, 0x75, 0x64, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x42, 0x6f, 0x74, 0x73,
+0x77, 0x61, 0x6e, 0x61, 0x6e, 0x20, 0x50, 0x75, 0x6c, 0x61, 0x3b, 0x3b, 0x42, 0x6f, 0x74, 0x73, 0x77, 0x61, 0x6e, 0x61,
+0x6e, 0x20, 0x70, 0x75, 0x6c, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x42, 0x6f, 0x74, 0x73, 0x77, 0x61, 0x6e, 0x61, 0x6e, 0x20,
+0x70, 0x75, 0x6c, 0x61, 0x73, 0x3b, 0x43, 0x46, 0x41, 0x20, 0x46, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x42, 0x45, 0x41, 0x43,
+0x3b, 0x3b, 0x43, 0x46, 0x41, 0x20, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x3b, 0x3b,
+0x43, 0x46, 0x41, 0x20, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x43, 0x61, 0x6e, 0x61,
+0x64, 0x69, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x43, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x61,
+0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x43, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x61, 0x6e,
+0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x43, 0x61, 0x79, 0x6d, 0x61, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61,
+0x6e, 0x64, 0x73, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x43, 0x61, 0x79, 0x6d, 0x61, 0x6e, 0x20, 0x49,
+0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x43, 0x61, 0x79,
+0x6d, 0x61, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b,
+0x46, 0x69, 0x6a, 0x69, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x46, 0x69, 0x6a, 0x69, 0x61,
+0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x69, 0x6a, 0x69, 0x61, 0x6e, 0x20, 0x64,
+0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x42, 0x72, 0x69, 0x74, 0x69, 0x73, 0x68, 0x20, 0x50, 0x6f, 0x75, 0x6e, 0x64,
+0x3b, 0x3b, 0x42, 0x72, 0x69, 0x74, 0x69, 0x73, 0x68, 0x20, 0x70, 0x6f, 0x75, 0x6e, 0x64, 0x3b, 0x3b, 0x3b, 0x3b, 0x42,
+0x72, 0x69, 0x74, 0x69, 0x73, 0x68, 0x20, 0x70, 0x6f, 0x75, 0x6e, 0x64, 0x73, 0x3b, 0x47, 0x61, 0x6d, 0x62, 0x69, 0x61,
+0x6e, 0x20, 0x44, 0x61, 0x6c, 0x61, 0x73, 0x69, 0x3b, 0x3b, 0x47, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x61,
+0x6c, 0x61, 0x73, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x47, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x61, 0x6c, 0x61,
+0x73, 0x69, 0x73, 0x3b, 0x47, 0x68, 0x61, 0x6e, 0x61, 0x69, 0x61, 0x6e, 0x20, 0x43, 0x65, 0x64, 0x69, 0x3b, 0x3b, 0x47,
+0x68, 0x61, 0x6e, 0x61, 0x69, 0x61, 0x6e, 0x20, 0x63, 0x65, 0x64, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x47, 0x68, 0x61, 0x6e,
+0x61, 0x69, 0x61, 0x6e, 0x20, 0x63, 0x65, 0x64, 0x69, 0x73, 0x3b, 0x47, 0x69, 0x62, 0x72, 0x61, 0x6c, 0x74, 0x61, 0x72,
+0x20, 0x50, 0x6f, 0x75, 0x6e, 0x64, 0x3b, 0x3b, 0x47, 0x69, 0x62, 0x72, 0x61, 0x6c, 0x74, 0x61, 0x72, 0x20, 0x70, 0x6f,
+0x75, 0x6e, 0x64, 0x3b, 0x3b, 0x3b, 0x3b, 0x47, 0x69, 0x62, 0x72, 0x61, 0x6c, 0x74, 0x61, 0x72, 0x20, 0x70, 0x6f, 0x75,
+0x6e, 0x64, 0x73, 0x3b, 0x47, 0x75, 0x79, 0x61, 0x6e, 0x61, 0x65, 0x73, 0x65, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72,
+0x3b, 0x3b, 0x47, 0x75, 0x79, 0x61, 0x6e, 0x61, 0x65, 0x73, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b,
+0x3b, 0x3b, 0x47, 0x75, 0x79, 0x61, 0x6e, 0x61, 0x65, 0x73, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b,
+0x48, 0x6f, 0x6e, 0x67, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x48, 0x6f,
+0x6e, 0x67, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x48, 0x6f,
+0x6e, 0x67, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x49, 0x6e, 0x64, 0x69,
+0x61, 0x6e, 0x20, 0x52, 0x75, 0x70, 0x65, 0x65, 0x3b, 0x3b, 0x49, 0x6e, 0x64, 0x69, 0x61, 0x6e, 0x20, 0x72, 0x75, 0x70,
+0x65, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x49, 0x6e, 0x64, 0x69, 0x61, 0x6e, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x73, 0x3b,
+0x4a, 0x61, 0x6d, 0x61, 0x69, 0x63, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x4a, 0x61, 0x6d,
+0x61, 0x69, 0x63, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x4a, 0x61, 0x6d, 0x61,
+0x69, 0x63, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x6e, 0x20,
+0x53, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e, 0x67, 0x3b, 0x3b, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x6e, 0x20, 0x73, 0x68, 0x69,
+0x6c, 0x6c, 0x69, 0x6e, 0x67, 0x3b, 0x3b, 0x3b, 0x3b, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x6e, 0x20, 0x73, 0x68, 0x69, 0x6c,
+0x6c, 0x69, 0x6e, 0x67, 0x73, 0x3b, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x41, 0x66, 0x72, 0x69, 0x63, 0x61, 0x6e, 0x20,
+0x52, 0x61, 0x6e, 0x64, 0x3b, 0x3b, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x41, 0x66, 0x72, 0x69, 0x63, 0x61, 0x6e, 0x20,
+0x72, 0x61, 0x6e, 0x64, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x41, 0x66, 0x72, 0x69, 0x63, 0x61,
+0x6e, 0x20, 0x72, 0x61, 0x6e, 0x64, 0x3b, 0x4c, 0x69, 0x62, 0x65, 0x72, 0x69, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c,
+0x61, 0x72, 0x3b, 0x3b, 0x4c, 0x69, 0x62, 0x65, 0x72, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b,
+0x3b, 0x3b, 0x3b, 0x4c, 0x69, 0x62, 0x65, 0x72, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b,
+0x4d, 0x61, 0x6c, 0x61, 0x67, 0x61, 0x73, 0x79, 0x20, 0x41, 0x72, 0x69, 0x61, 0x72, 0x79, 0x3b, 0x3b, 0x4d, 0x61, 0x6c,
+0x61, 0x67, 0x61, 0x73, 0x79, 0x20, 0x41, 0x72, 0x69, 0x61, 0x72, 0x79, 0x3b, 0x3b, 0x3b, 0x3b, 0x4d, 0x61, 0x6c, 0x61,
+0x67, 0x61, 0x73, 0x79, 0x20, 0x41, 0x72, 0x69, 0x61, 0x72, 0x69, 0x65, 0x73, 0x3b, 0x4d, 0x61, 0x6c, 0x61, 0x77, 0x69,
+0x61, 0x6e, 0x20, 0x4b, 0x77, 0x61, 0x63, 0x68, 0x61, 0x3b, 0x3b, 0x4d, 0x61, 0x6c, 0x61, 0x77, 0x69, 0x61, 0x6e, 0x20,
+0x4b, 0x77, 0x61, 0x63, 0x68, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x4d, 0x61, 0x6c, 0x61, 0x77, 0x69, 0x61, 0x6e, 0x20, 0x4b,
+0x77, 0x61, 0x63, 0x68, 0x61, 0x73, 0x3b, 0x4d, 0x61, 0x75, 0x72, 0x69, 0x74, 0x69, 0x61, 0x6e, 0x20, 0x52, 0x75, 0x70,
+0x65, 0x65, 0x3b, 0x3b, 0x4d, 0x61, 0x75, 0x72, 0x69, 0x74, 0x69, 0x61, 0x6e, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x3b,
+0x3b, 0x3b, 0x3b, 0x4d, 0x61, 0x75, 0x72, 0x69, 0x74, 0x69, 0x61, 0x6e, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x73, 0x3b,
+0x4e, 0x61, 0x6d, 0x69, 0x62, 0x69, 0x61, 0x6e, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x4e, 0x61, 0x6d,
+0x69, 0x62, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x61, 0x6d, 0x69,
+0x62, 0x69, 0x61, 0x6e, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x4e, 0x65, 0x77, 0x20, 0x5a, 0x65, 0x61,
+0x6c, 0x61, 0x6e, 0x64, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x4e, 0x65, 0x77, 0x20, 0x5a, 0x65, 0x61,
+0x6c, 0x61, 0x6e, 0x64, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x65, 0x77, 0x20, 0x5a,
+0x65, 0x61, 0x6c, 0x61, 0x6e, 0x64, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x4e, 0x69, 0x67, 0x65, 0x72,
+0x69, 0x61, 0x6e, 0x20, 0x4e, 0x61, 0x69, 0x72, 0x61, 0x3b, 0x3b, 0x4e, 0x69, 0x67, 0x65, 0x72, 0x69, 0x61, 0x6e, 0x20,
+0x6e, 0x61, 0x69, 0x72, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x69, 0x67, 0x65, 0x72, 0x69, 0x61, 0x6e, 0x20, 0x6e, 0x61,
+0x69, 0x72, 0x61, 0x73, 0x3b, 0x50, 0x61, 0x6b, 0x69, 0x73, 0x74, 0x61, 0x6e, 0x69, 0x20, 0x52, 0x75, 0x70, 0x65, 0x65,
+0x3b, 0x3b, 0x50, 0x61, 0x6b, 0x69, 0x73, 0x74, 0x61, 0x6e, 0x69, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x3b, 0x3b, 0x3b,
+0x3b, 0x50, 0x61, 0x6b, 0x69, 0x73, 0x74, 0x61, 0x6e, 0x69, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x73, 0x3b, 0x50, 0x61,
+0x70, 0x75, 0x61, 0x20, 0x4e, 0x65, 0x77, 0x20, 0x47, 0x75, 0x69, 0x6e, 0x65, 0x61, 0x6e, 0x20, 0x4b, 0x69, 0x6e, 0x61,
+0x3b, 0x3b, 0x50, 0x61, 0x70, 0x75, 0x61, 0x20, 0x4e, 0x65, 0x77, 0x20, 0x47, 0x75, 0x69, 0x6e, 0x65, 0x61, 0x6e, 0x20,
+0x6b, 0x69, 0x6e, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x50, 0x61, 0x70, 0x75, 0x61, 0x20, 0x4e, 0x65, 0x77, 0x20, 0x47, 0x75,
+0x69, 0x6e, 0x65, 0x61, 0x6e, 0x20, 0x6b, 0x69, 0x6e, 0x61, 0x3b, 0x50, 0x65, 0x73, 0x6f, 0x3b, 0x3b, 0x50, 0x68, 0x69,
+0x6c, 0x69, 0x70, 0x70, 0x69, 0x6e, 0x65, 0x20, 0x70, 0x65, 0x73, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x50, 0x68, 0x69, 0x6c,
+0x69, 0x70, 0x70, 0x69, 0x6e, 0x65, 0x20, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x3b, 0x53, 0x61, 0x6d, 0x6f, 0x61, 0x6e, 0x20,
+0x54, 0x61, 0x6c, 0x61, 0x3b, 0x3b, 0x53, 0x61, 0x6d, 0x6f, 0x61, 0x6e, 0x20, 0x74, 0x61, 0x6c, 0x61, 0x3b, 0x3b, 0x3b,
+0x3b, 0x53, 0x61, 0x6d, 0x6f, 0x61, 0x6e, 0x20, 0x74, 0x61, 0x6c, 0x61, 0x3b, 0x53, 0x65, 0x79, 0x63, 0x68, 0x65, 0x6c,
+0x6c, 0x6f, 0x69, 0x73, 0x20, 0x52, 0x75, 0x70, 0x65, 0x65, 0x3b, 0x3b, 0x53, 0x65, 0x79, 0x63, 0x68, 0x65, 0x6c, 0x6c,
+0x6f, 0x69, 0x73, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x65, 0x79, 0x63, 0x68, 0x65, 0x6c,
+0x6c, 0x6f, 0x69, 0x73, 0x20, 0x72, 0x75, 0x70, 0x65, 0x65, 0x73, 0x3b, 0x53, 0x69, 0x65, 0x72, 0x72, 0x61, 0x20, 0x4c,
+0x65, 0x6f, 0x6e, 0x65, 0x61, 0x6e, 0x20, 0x4c, 0x65, 0x6f, 0x6e, 0x65, 0x3b, 0x3b, 0x53, 0x69, 0x65, 0x72, 0x72, 0x61,
+0x20, 0x4c, 0x65, 0x6f, 0x6e, 0x65, 0x61, 0x6e, 0x20, 0x6c, 0x65, 0x6f, 0x6e, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69,
+0x65, 0x72, 0x72, 0x61, 0x20, 0x4c, 0x65, 0x6f, 0x6e, 0x65, 0x61, 0x6e, 0x20, 0x6c, 0x65, 0x6f, 0x6e, 0x65, 0x73, 0x3b,
+0x53, 0x69, 0x6e, 0x67, 0x61, 0x70, 0x6f, 0x72, 0x65, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x53, 0x69,
+0x6e, 0x67, 0x61, 0x70, 0x6f, 0x72, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69,
+0x6e, 0x67, 0x61, 0x70, 0x6f, 0x72, 0x65, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x53, 0x6f, 0x6c, 0x6f,
+0x6d, 0x6f, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b,
+0x53, 0x6f, 0x6c, 0x6f, 0x6d, 0x6f, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x20, 0x64, 0x6f, 0x6c, 0x6c,
+0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x6f, 0x6c, 0x6f, 0x6d, 0x6f, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64,
+0x73, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b, 0x53, 0x77, 0x61, 0x7a, 0x69, 0x20, 0x4c, 0x69, 0x6c, 0x61,
+0x6e, 0x67, 0x65, 0x6e, 0x69, 0x3b, 0x3b, 0x53, 0x77, 0x61, 0x7a, 0x69, 0x20, 0x6c, 0x69, 0x6c, 0x61, 0x6e, 0x67, 0x65,
+0x6e, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x77, 0x61, 0x7a, 0x69, 0x20, 0x65, 0x6d, 0x61, 0x6c, 0x61, 0x6e, 0x67, 0x65,
+0x6e, 0x69, 0x3b, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x6e, 0x20, 0x53, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e,
+0x67, 0x3b, 0x3b, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x6e, 0x20, 0x73, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e,
+0x67, 0x3b, 0x3b, 0x3b, 0x3b, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x6e, 0x20, 0x73, 0x68, 0x69, 0x6c, 0x6c,
+0x69, 0x6e, 0x67, 0x73, 0x3b, 0x54, 0x6f, 0x6e, 0x67, 0x61, 0x6e, 0x20, 0x50, 0x61, 0x2bb, 0x61, 0x6e, 0x67, 0x61, 0x3b,
+0x3b, 0x54, 0x6f, 0x6e, 0x67, 0x61, 0x6e, 0x20, 0x70, 0x61, 0x2bb, 0x61, 0x6e, 0x67, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x54,
+0x6f, 0x6e, 0x67, 0x61, 0x6e, 0x20, 0x70, 0x61, 0x2bb, 0x61, 0x6e, 0x67, 0x61, 0x3b, 0x54, 0x72, 0x69, 0x6e, 0x69, 0x64,
+0x61, 0x64, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x54, 0x6f, 0x62, 0x61, 0x67, 0x6f, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72,
+0x3b, 0x3b, 0x54, 0x72, 0x69, 0x6e, 0x69, 0x64, 0x61, 0x64, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x54, 0x6f, 0x62, 0x61, 0x67,
+0x6f, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x3b, 0x3b, 0x3b, 0x3b, 0x54, 0x72, 0x69, 0x6e, 0x69, 0x64, 0x61, 0x64,
+0x20, 0x61, 0x6e, 0x64, 0x20, 0x54, 0x6f, 0x62, 0x61, 0x67, 0x6f, 0x20, 0x64, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x73, 0x3b,
+0x55, 0x67, 0x61, 0x6e, 0x64, 0x61, 0x6e, 0x20, 0x53, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e, 0x67, 0x3b, 0x3b, 0x55, 0x67,
+0x61, 0x6e, 0x64, 0x61, 0x6e, 0x20, 0x73, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e, 0x67, 0x3b, 0x3b, 0x3b, 0x3b, 0x55, 0x67,
+0x61, 0x6e, 0x64, 0x61, 0x6e, 0x20, 0x73, 0x68, 0x69, 0x6c, 0x6c, 0x69, 0x6e, 0x67, 0x73, 0x3b, 0x56, 0x61, 0x6e, 0x75,
+0x61, 0x74, 0x75, 0x20, 0x56, 0x61, 0x74, 0x75, 0x3b, 0x3b, 0x56, 0x61, 0x6e, 0x75, 0x61, 0x74, 0x75, 0x20, 0x76, 0x61,
+0x74, 0x75, 0x3b, 0x3b, 0x3b, 0x3b, 0x56, 0x61, 0x6e, 0x75, 0x61, 0x74, 0x75, 0x20, 0x76, 0x61, 0x74, 0x75, 0x73, 0x3b,
+0x5a, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x6e, 0x20, 0x4b, 0x77, 0x61, 0x63, 0x68, 0x61, 0x3b, 0x3b, 0x5a, 0x61, 0x6d, 0x62,
+0x69, 0x61, 0x6e, 0x20, 0x6b, 0x77, 0x61, 0x63, 0x68, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x5a, 0x61, 0x6d, 0x62, 0x69, 0x61,
+0x6e, 0x20, 0x6b, 0x77, 0x61, 0x63, 0x68, 0x61, 0x73, 0x3b, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x53, 0x75, 0x64, 0x61,
+0x6e, 0x65, 0x73, 0x65, 0x20, 0x50, 0x6f, 0x75, 0x6e, 0x64, 0x3b, 0x3b, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x53, 0x75,
+0x64, 0x61, 0x6e, 0x65, 0x73, 0x65, 0x20, 0x70, 0x6f, 0x75, 0x6e, 0x64, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x6f, 0x75, 0x74,
+0x68, 0x20, 0x53, 0x75, 0x64, 0x61, 0x6e, 0x65, 0x73, 0x65, 0x20, 0x70, 0x6f, 0x75, 0x6e, 0x64, 0x73, 0x3b, 0x65, 0x75,
+0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x74, 0x3b, 0x64, 0x6f,
+0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0xf3, 0x6e, 0x61, 0x3b, 0x3b, 0x64, 0x6f, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0xf3,
+0x6e, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x64, 0x6f, 0x6e, 0x73, 0x6b, 0x61, 0x20, 0x6b, 0x72, 0xf3, 0x6e, 0x75, 0x72, 0x3b,
+0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x61, 0x3b,
+0x64, 0x69, 0x6e, 0x61, 0x72, 0x20, 0x61, 0x6c, 0x67, 0xe9, 0x72, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x64, 0x69, 0x6e, 0x61,
+0x72, 0x20, 0x61, 0x6c, 0x67, 0xe9, 0x72, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x73,
+0x20, 0x61, 0x6c, 0x67, 0xe9, 0x72, 0x69, 0x65, 0x6e, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x41,
+0x20, 0x28, 0x42, 0x43, 0x45, 0x41, 0x4f, 0x29, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x41, 0x20,
+0x28, 0x42, 0x43, 0x45, 0x41, 0x4f, 0x29, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x43, 0x46,
+0x41, 0x20, 0x28, 0x42, 0x43, 0x45, 0x41, 0x4f, 0x29, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x62, 0x75, 0x72, 0x75,
+0x6e, 0x64, 0x61, 0x69, 0x73, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x62, 0x75, 0x72, 0x75, 0x6e, 0x64, 0x61,
+0x69, 0x73, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x62, 0x75, 0x72, 0x75, 0x6e, 0x64, 0x61,
+0x69, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x41, 0x20, 0x28, 0x42, 0x45, 0x41, 0x43, 0x29, 0x3b,
+0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x41, 0x20, 0x28, 0x42, 0x45, 0x41, 0x43, 0x29, 0x3b, 0x3b, 0x3b,
+0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x43, 0x46, 0x41, 0x20, 0x28, 0x42, 0x45, 0x41, 0x43, 0x29, 0x3b, 0x64,
+0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x20, 0x63, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x64, 0x6f, 0x6c, 0x6c,
+0x61, 0x72, 0x20, 0x63, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x64, 0x6f, 0x6c, 0x6c, 0x61,
+0x72, 0x73, 0x20, 0x63, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x65, 0x6e, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x63,
+0x6f, 0x6d, 0x6f, 0x72, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x63, 0x6f, 0x6d, 0x6f, 0x72,
+0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x63, 0x6f, 0x6d, 0x6f, 0x72, 0x69,
+0x65, 0x6e, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x63, 0x6f, 0x6e, 0x67, 0x6f, 0x6c, 0x61, 0x69, 0x73, 0x3b,
+0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x63, 0x6f, 0x6e, 0x67, 0x6f, 0x6c, 0x61, 0x69, 0x73, 0x3b, 0x3b, 0x3b, 0x3b,
+0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x63, 0x6f, 0x6e, 0x67, 0x6f, 0x6c, 0x61, 0x69, 0x73, 0x3b, 0x66, 0x72, 0x61,
+0x6e, 0x63, 0x20, 0x64, 0x6a, 0x69, 0x62, 0x6f, 0x75, 0x74, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63,
+0x20, 0x64, 0x6a, 0x69, 0x62, 0x6f, 0x75, 0x74, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63,
+0x73, 0x20, 0x64, 0x6a, 0x69, 0x62, 0x6f, 0x75, 0x74, 0x69, 0x65, 0x6e, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20,
+0x43, 0x46, 0x50, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x50, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72,
+0x61, 0x6e, 0x63, 0x73, 0x20, 0x43, 0x46, 0x50, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x67, 0x75, 0x69, 0x6e, 0xe9,
+0x65, 0x6e, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x67, 0x75, 0x69, 0x6e, 0xe9, 0x65, 0x6e, 0x3b, 0x3b, 0x3b,
+0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x67, 0x75, 0x69, 0x6e, 0xe9, 0x65, 0x6e, 0x73, 0x3b, 0x67, 0x6f, 0x75,
+0x72, 0x64, 0x65, 0x20, 0x68, 0x61, 0xef, 0x74, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x3b, 0x3b, 0x67, 0x6f, 0x75, 0x72, 0x64,
+0x65, 0x20, 0x68, 0x61, 0xef, 0x74, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x67, 0x6f, 0x75, 0x72, 0x64,
+0x65, 0x73, 0x20, 0x68, 0x61, 0xef, 0x74, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x73, 0x3b, 0x61, 0x72, 0x69, 0x61, 0x72, 0x79,
+0x20, 0x6d, 0x61, 0x6c, 0x67, 0x61, 0x63, 0x68, 0x65, 0x3b, 0x3b, 0x61, 0x72, 0x69, 0x61, 0x72, 0x79, 0x20, 0x6d, 0x61,
+0x6c, 0x67, 0x61, 0x63, 0x68, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x61, 0x72, 0x69, 0x61, 0x72, 0x79, 0x73, 0x20, 0x6d, 0x61,
+0x6c, 0x67, 0x61, 0x63, 0x68, 0x65, 0x73, 0x3b, 0x6f, 0x75, 0x67, 0x75, 0x69, 0x79, 0x61, 0x20, 0x6d, 0x61, 0x75, 0x72,
+0x69, 0x74, 0x61, 0x6e, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x6f, 0x75, 0x67, 0x75, 0x69, 0x79, 0x61, 0x20, 0x6d, 0x61, 0x75,
+0x72, 0x69, 0x74, 0x61, 0x6e, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x6f, 0x75, 0x67, 0x75, 0x69, 0x79, 0x61, 0x73,
+0x20, 0x6d, 0x61, 0x75, 0x72, 0x69, 0x74, 0x61, 0x6e, 0x69, 0x65, 0x6e, 0x73, 0x3b, 0x72, 0x6f, 0x75, 0x70, 0x69, 0x65,
+0x20, 0x6d, 0x61, 0x75, 0x72, 0x69, 0x63, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x3b, 0x3b, 0x72, 0x6f, 0x75, 0x70, 0x69, 0x65,
+0x20, 0x6d, 0x61, 0x75, 0x72, 0x69, 0x63, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x72, 0x6f, 0x75, 0x70,
+0x69, 0x65, 0x73, 0x20, 0x6d, 0x61, 0x75, 0x72, 0x69, 0x63, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x73, 0x3b, 0x64, 0x69, 0x72,
+0x68, 0x61, 0x6d, 0x20, 0x6d, 0x61, 0x72, 0x6f, 0x63, 0x61, 0x69, 0x6e, 0x3b, 0x3b, 0x64, 0x69, 0x72, 0x68, 0x61, 0x6d,
+0x20, 0x6d, 0x61, 0x72, 0x6f, 0x63, 0x61, 0x69, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x64, 0x69, 0x72, 0x68, 0x61, 0x6d, 0x73,
+0x20, 0x6d, 0x61, 0x72, 0x6f, 0x63, 0x61, 0x69, 0x6e, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x72, 0x77, 0x61,
+0x6e, 0x64, 0x61, 0x69, 0x73, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x72, 0x77, 0x61, 0x6e, 0x64, 0x61, 0x69,
+0x73, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x72, 0x77, 0x61, 0x6e, 0x64, 0x61, 0x69, 0x73,
0x3b, 0x72, 0x6f, 0x75, 0x70, 0x69, 0x65, 0x20, 0x64, 0x65, 0x73, 0x20, 0x53, 0x65, 0x79, 0x63, 0x68, 0x65, 0x6c, 0x6c,
-0x65, 0x73, 0x3b, 0x3b, 0x3b, 0x3b, 0x72, 0x6f, 0x75, 0x70, 0x69, 0x65, 0x73, 0x20, 0x64, 0x65, 0x73, 0x20, 0x53, 0x65,
-0x79, 0x63, 0x68, 0x65, 0x6c, 0x6c, 0x65, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x73, 0x75, 0x69, 0x73, 0x73,
-0x65, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x73, 0x75, 0x69, 0x73, 0x73, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x66,
-0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x73, 0x75, 0x69, 0x73, 0x73, 0x65, 0x73, 0x3b, 0x6c, 0x69, 0x76, 0x72, 0x65, 0x20,
-0x73, 0x79, 0x72, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x3b, 0x3b, 0x6c, 0x69, 0x76, 0x72, 0x65, 0x20, 0x73, 0x79, 0x72, 0x69,
-0x65, 0x6e, 0x6e, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x6c, 0x69, 0x76, 0x72, 0x65, 0x73, 0x20, 0x73, 0x79, 0x72, 0x69, 0x65,
-0x6e, 0x6e, 0x65, 0x73, 0x3b, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x20, 0x74, 0x75, 0x6e, 0x69, 0x73, 0x69, 0x65, 0x6e, 0x3b,
-0x3b, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x20, 0x74, 0x75, 0x6e, 0x69, 0x73, 0x69, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x64,
-0x69, 0x6e, 0x61, 0x72, 0x73, 0x20, 0x74, 0x75, 0x6e, 0x69, 0x73, 0x69, 0x65, 0x6e, 0x73, 0x3b, 0x76, 0x61, 0x74, 0x75,
-0x20, 0x76, 0x61, 0x6e, 0x75, 0x61, 0x74, 0x75, 0x61, 0x6e, 0x3b, 0x3b, 0x76, 0x61, 0x74, 0x75, 0x20, 0x76, 0x61, 0x6e,
-0x75, 0x61, 0x74, 0x75, 0x61, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x76, 0x61, 0x74, 0x75, 0x73, 0x20, 0x76, 0x61, 0x6e, 0x75,
-0x61, 0x74, 0x75, 0x61, 0x6e, 0x73, 0x3b, 0x50, 0x75, 0x6e, 0x6e, 0x64, 0x20, 0x53, 0x61, 0x73, 0x61, 0x6e, 0x6e, 0x61,
-0x63, 0x68, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x45, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b,
-0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x73, 0x3b, 0x10e5, 0x10d0, 0x10e0, 0x10d7, 0x10e3, 0x10da, 0x10d8, 0x20, 0x10da, 0x10d0, 0x10e0,
-0x10d8, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x45, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x45, 0x75, 0x72, 0x6f, 0x3b, 0x3b,
-0x3b, 0x3b, 0x45, 0x75, 0x72, 0x6f, 0x3b, 0x53, 0x63, 0x68, 0x77, 0x65, 0x69, 0x7a, 0x65, 0x72, 0x20, 0x46, 0x72, 0x61,
-0x6e, 0x6b, 0x65, 0x6e, 0x3b, 0x3b, 0x53, 0x63, 0x68, 0x77, 0x65, 0x69, 0x7a, 0x65, 0x72, 0x20, 0x46, 0x72, 0x61, 0x6e,
-0x6b, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x63, 0x68, 0x77, 0x65, 0x69, 0x7a, 0x65, 0x72, 0x20, 0x46, 0x72, 0x61,
-0x6e, 0x6b, 0x65, 0x6e, 0x3b, 0x395, 0x3c5, 0x3c1, 0x3ce, 0x3b, 0x3b, 0x3b5, 0x3c5, 0x3c1, 0x3ce, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b5,
-0x3c5, 0x3c1, 0x3ce, 0x3b, 0x64, 0x61, 0x6e, 0x6e, 0x73, 0x6b, 0x69, 0x6e, 0x75, 0x74, 0x20, 0x6b, 0x6f, 0x72, 0x75, 0x75,
-0x6e, 0x69, 0x3b, 0x3b, 0x64, 0x61, 0x6e, 0x73, 0x6b, 0x69, 0x6e, 0x75, 0x74, 0x20, 0x6b, 0x6f, 0x72, 0x75, 0x75, 0x6e,
-0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x64, 0x61, 0x6e, 0x73, 0x6b, 0x69, 0x6e, 0x75, 0x74, 0x20, 0x6b, 0x6f, 0x72, 0x75, 0x75,
-0x6e, 0x69, 0x3b, 0xaad, 0xabe, 0xab0, 0xaa4, 0xac0, 0xaaf, 0x20, 0xab0, 0xac2, 0xaaa, 0xac0, 0xaaf, 0xabe, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x4e, 0x61, 0x69, 0x72, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4b, 0x75, 0x257, 0x69, 0x6e,
-0x20, 0x53, 0x65, 0x66, 0x61, 0x20, 0x6e, 0x61, 0x20, 0x41, 0x66, 0x69, 0x72, 0x6b, 0x61, 0x20, 0x54, 0x61, 0x20, 0x59,
-0x61, 0x6d, 0x6d, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x5e9, 0x5f4, 0x5d7, 0x3b, 0x3b, 0x5e9, 0x5e7, 0x5dc, 0x5d9,
-0x5dd, 0x20, 0x5d7, 0x5d3, 0x5e9, 0x5d9, 0x5dd, 0x3b, 0x5e9, 0x5e7, 0x5dc, 0x5d9, 0x5dd, 0x20, 0x5d7, 0x5d3, 0x5e9, 0x5d9, 0x5dd, 0x3b,
-0x3b, 0x5e9, 0x5e7, 0x5dc, 0x5d9, 0x5dd, 0x20, 0x5d7, 0x5d3, 0x5e9, 0x5d9, 0x5dd, 0x3b, 0x5e9, 0x5e7, 0x5dc, 0x5d9, 0x5dd, 0x20, 0x5d7,
-0x5d3, 0x5e9, 0x5d9, 0x5dd, 0x3b, 0x92d, 0x93e, 0x930, 0x924, 0x940, 0x92f, 0x20, 0x930, 0x942, 0x92a, 0x92f, 0x93e, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x4d, 0x61, 0x67, 0x79, 0x61, 0x72, 0x20, 0x66, 0x6f, 0x72, 0x69, 0x6e, 0x74, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0xcd, 0x73, 0x6c, 0x65, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0xf3, 0x6e, 0x61, 0x3b, 0x3b, 0xed,
-0x73, 0x6c, 0x65, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0xf3, 0x6e, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0xed, 0x73, 0x6c, 0x65,
-0x6e, 0x73, 0x6b, 0x61, 0x72, 0x20, 0x6b, 0x72, 0xf3, 0x6e, 0x75, 0x72, 0x3b, 0x52, 0x75, 0x70, 0x69, 0x61, 0x68, 0x20,
-0x49, 0x6e, 0x64, 0x6f, 0x6e, 0x65, 0x73, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x45, 0x75, 0x72, 0x6f,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x72, 0x61, 0x6e, 0x63, 0x6f, 0x20, 0x53, 0x76, 0x69, 0x7a, 0x7a, 0x65,
-0x72, 0x6f, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x6f, 0x20, 0x73, 0x76, 0x69, 0x7a, 0x7a, 0x65, 0x72, 0x6f, 0x3b,
-0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x68, 0x69, 0x20, 0x73, 0x76, 0x69, 0x7a, 0x7a, 0x65, 0x72, 0x69, 0x3b,
-0x65e5, 0x672c, 0x5186, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xcad, 0xcbe, 0xcb0, 0xca4, 0xcc0, 0xcaf, 0x20, 0xcb0, 0xcc1, 0xcaa,
-0xcbe, 0xcaf, 0xcbf, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x6c1, 0x650, 0x646, 0x62f, 0x64f, 0x633, 0x62a, 0x672, 0x646, 0x6cd,
-0x20, 0x631, 0x6c4, 0x67e, 0x64e, 0x6d2, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x49a, 0x430, 0x437, 0x430, 0x49b, 0x441, 0x442,
-0x430, 0x43d, 0x20, 0x442, 0x435, 0x4a3, 0x433, 0x435, 0x441, 0x456, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xb300, 0xd55c, 0xbbfc,
-0xad6d, 0x20, 0xc6d0, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xc870, 0xc120, 0x20, 0xbbfc, 0xc8fc, 0xc8fc, 0xc758, 0x20, 0xc778, 0xbbfc,
-0x20, 0xacf5, 0xd654, 0xad6d, 0x20, 0xc6d0, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x49, 0x66, 0x61, 0x72, 0x61, 0x6e, 0x67,
-0x61, 0x20, 0x72, 0x79, 0x27, 0x55, 0x62, 0x75, 0x72, 0x75, 0x6e, 0x64, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0xe81, 0xeb5, 0xe9a, 0x20, 0xea5, 0xeb2, 0xea7, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4c, 0x61, 0x74, 0x76, 0x69, 0x6a,
-0x61, 0x73, 0x20, 0x6c, 0x61, 0x74, 0x73, 0x3b, 0x4c, 0x61, 0x74, 0x76, 0x69, 0x6a, 0x61, 0x73, 0x20, 0x6c, 0x61, 0x74,
-0x69, 0x3b, 0x4c, 0x61, 0x74, 0x76, 0x69, 0x6a, 0x61, 0x73, 0x20, 0x6c, 0x61, 0x74, 0x73, 0x3b, 0x3b, 0x3b, 0x3b, 0x4c,
-0x61, 0x74, 0x76, 0x69, 0x6a, 0x61, 0x73, 0x20, 0x6c, 0x61, 0x74, 0x69, 0x3b, 0x46, 0x61, 0x6c, 0xe1, 0x6e, 0x67, 0x61,
-0x20, 0x79, 0x61, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0xf3, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4b, 0x77, 0x61, 0x6e,
-0x7a, 0x61, 0x20, 0x79, 0x61, 0x20, 0x41, 0x6e, 0x67, 0xf3, 0x6c, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46,
-0x61, 0x6c, 0xe1, 0x6e, 0x67, 0x61, 0x20, 0x43, 0x46, 0x41, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x4c, 0x69, 0x65, 0x74, 0x75, 0x76, 0x6f, 0x73, 0x20, 0x6c, 0x69, 0x74, 0x61, 0x73, 0x3b, 0x3b, 0x4c, 0x69,
-0x65, 0x74, 0x75, 0x76, 0x6f, 0x73, 0x20, 0x6c, 0x69, 0x74, 0x61, 0x73, 0x3b, 0x3b, 0x4c, 0x69, 0x65, 0x74, 0x75, 0x76,
-0x6f, 0x73, 0x20, 0x6c, 0x69, 0x74, 0x61, 0x69, 0x3b, 0x3b, 0x4c, 0x69, 0x65, 0x74, 0x75, 0x76, 0x6f, 0x73, 0x20, 0x6c,
-0x69, 0x74, 0x173, 0x3b, 0x41c, 0x430, 0x43a, 0x435, 0x434, 0x43e, 0x43d, 0x441, 0x43a, 0x438, 0x20, 0x434, 0x435, 0x43d, 0x430, 0x440,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x41, 0x72, 0x69, 0x61, 0x72, 0x79, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x52, 0x69, 0x6e, 0x67, 0x67, 0x69, 0x74, 0x20, 0x4d, 0x61, 0x6c, 0x61, 0x79, 0x73, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x44, 0x6f, 0x6c, 0x61, 0x72, 0x20, 0x42, 0x72, 0x75, 0x6e, 0x65, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x44, 0x6f, 0x6c, 0x61, 0x72, 0x20, 0x53, 0x69, 0x6e, 0x67, 0x61, 0x70, 0x75, 0x72, 0x61, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0xd07, 0xd28, 0xd4d, 0xd24, 0xd4d, 0xd2f, 0xd7b, 0x20, 0xd30, 0xd42, 0xd2a, 0x3b, 0x3b, 0xd07, 0xd28, 0xd4d,
-0xd24, 0xd4d, 0xd2f, 0xd7b, 0x20, 0xd30, 0xd42, 0xd2a, 0x3b, 0x3b, 0x3b, 0x3b, 0xd07, 0xd28, 0xd4d, 0xd24, 0xd4d, 0xd2f, 0xd7b, 0x20,
-0xd30, 0xd42, 0xd2a, 0x3b, 0x45, 0x77, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x92d, 0x93e, 0x930, 0x924, 0x940,
-0x92f, 0x20, 0x930, 0x941, 0x92a, 0x92f, 0x93e, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x928, 0x947, 0x92a, 0x93e, 0x932, 0x940,
+0x65, 0x73, 0x3b, 0x3b, 0x72, 0x6f, 0x75, 0x70, 0x69, 0x65, 0x20, 0x64, 0x65, 0x73, 0x20, 0x53, 0x65, 0x79, 0x63, 0x68,
+0x65, 0x6c, 0x6c, 0x65, 0x73, 0x3b, 0x3b, 0x3b, 0x3b, 0x72, 0x6f, 0x75, 0x70, 0x69, 0x65, 0x73, 0x20, 0x64, 0x65, 0x73,
+0x20, 0x53, 0x65, 0x79, 0x63, 0x68, 0x65, 0x6c, 0x6c, 0x65, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x73, 0x75,
+0x69, 0x73, 0x73, 0x65, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x73, 0x75, 0x69, 0x73, 0x73, 0x65, 0x3b, 0x3b,
+0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x73, 0x20, 0x73, 0x75, 0x69, 0x73, 0x73, 0x65, 0x73, 0x3b, 0x6c, 0x69, 0x76,
+0x72, 0x65, 0x20, 0x73, 0x79, 0x72, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x3b, 0x3b, 0x6c, 0x69, 0x76, 0x72, 0x65, 0x20, 0x73,
+0x79, 0x72, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x6c, 0x69, 0x76, 0x72, 0x65, 0x73, 0x20, 0x73, 0x79,
+0x72, 0x69, 0x65, 0x6e, 0x6e, 0x65, 0x73, 0x3b, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x20, 0x74, 0x75, 0x6e, 0x69, 0x73, 0x69,
+0x65, 0x6e, 0x3b, 0x3b, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x20, 0x74, 0x75, 0x6e, 0x69, 0x73, 0x69, 0x65, 0x6e, 0x3b, 0x3b,
+0x3b, 0x3b, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x73, 0x20, 0x74, 0x75, 0x6e, 0x69, 0x73, 0x69, 0x65, 0x6e, 0x73, 0x3b, 0x76,
+0x61, 0x74, 0x75, 0x20, 0x76, 0x61, 0x6e, 0x75, 0x61, 0x74, 0x75, 0x61, 0x6e, 0x3b, 0x3b, 0x76, 0x61, 0x74, 0x75, 0x20,
+0x76, 0x61, 0x6e, 0x75, 0x61, 0x74, 0x75, 0x61, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x76, 0x61, 0x74, 0x75, 0x73, 0x20, 0x76,
+0x61, 0x6e, 0x75, 0x61, 0x74, 0x75, 0x61, 0x6e, 0x73, 0x3b, 0x50, 0x75, 0x6e, 0x6e, 0x64, 0x20, 0x53, 0x61, 0x73, 0x61,
+0x6e, 0x6e, 0x61, 0x63, 0x68, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x45, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75,
+0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x73, 0x3b, 0x10e5, 0x10d0, 0x10e0, 0x10d7, 0x10e3, 0x10da, 0x10d8, 0x20,
+0x10da, 0x10d0, 0x10e0, 0x10d8, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x45, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x45, 0x75, 0x72,
+0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x45, 0x75, 0x72, 0x6f, 0x3b, 0x53, 0x63, 0x68, 0x77, 0x65, 0x69, 0x7a, 0x65, 0x72, 0x20,
+0x46, 0x72, 0x61, 0x6e, 0x6b, 0x65, 0x6e, 0x3b, 0x3b, 0x53, 0x63, 0x68, 0x77, 0x65, 0x69, 0x7a, 0x65, 0x72, 0x20, 0x46,
+0x72, 0x61, 0x6e, 0x6b, 0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x63, 0x68, 0x77, 0x65, 0x69, 0x7a, 0x65, 0x72, 0x20,
+0x46, 0x72, 0x61, 0x6e, 0x6b, 0x65, 0x6e, 0x3b, 0x395, 0x3c5, 0x3c1, 0x3ce, 0x3b, 0x3b, 0x3b5, 0x3c5, 0x3c1, 0x3ce, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b5, 0x3c5, 0x3c1, 0x3ce, 0x3b, 0x64, 0x61, 0x6e, 0x6e, 0x73, 0x6b, 0x69, 0x6e, 0x75, 0x74, 0x20, 0x6b, 0x6f,
+0x72, 0x75, 0x75, 0x6e, 0x69, 0x3b, 0x3b, 0x64, 0x61, 0x6e, 0x73, 0x6b, 0x69, 0x6e, 0x75, 0x74, 0x20, 0x6b, 0x6f, 0x72,
+0x75, 0x75, 0x6e, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x64, 0x61, 0x6e, 0x73, 0x6b, 0x69, 0x6e, 0x75, 0x74, 0x20, 0x6b, 0x6f,
+0x72, 0x75, 0x75, 0x6e, 0x69, 0x3b, 0xaad, 0xabe, 0xab0, 0xaa4, 0xac0, 0xaaf, 0x20, 0xab0, 0xac2, 0xaaa, 0xac0, 0xaaf, 0xabe, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x61, 0x69, 0x72, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4b, 0x75,
+0x257, 0x69, 0x6e, 0x20, 0x53, 0x65, 0x66, 0x61, 0x20, 0x6e, 0x61, 0x20, 0x41, 0x66, 0x69, 0x72, 0x6b, 0x61, 0x20, 0x54,
+0x61, 0x20, 0x59, 0x61, 0x6d, 0x6d, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x5e9, 0x5f4, 0x5d7, 0x3b, 0x3b, 0x5e9,
+0x5e7, 0x5dc, 0x5d9, 0x5dd, 0x20, 0x5d7, 0x5d3, 0x5e9, 0x5d9, 0x5dd, 0x3b, 0x5e9, 0x5e7, 0x5dc, 0x5d9, 0x5dd, 0x20, 0x5d7, 0x5d3, 0x5e9,
+0x5d9, 0x5dd, 0x3b, 0x3b, 0x5e9, 0x5e7, 0x5dc, 0x5d9, 0x5dd, 0x20, 0x5d7, 0x5d3, 0x5e9, 0x5d9, 0x5dd, 0x3b, 0x5e9, 0x5e7, 0x5dc, 0x5d9,
+0x5dd, 0x20, 0x5d7, 0x5d3, 0x5e9, 0x5d9, 0x5dd, 0x3b, 0x92d, 0x93e, 0x930, 0x924, 0x940, 0x92f, 0x20, 0x930, 0x942, 0x92a, 0x92f, 0x93e,
+0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4d, 0x61, 0x67, 0x79, 0x61, 0x72, 0x20, 0x66, 0x6f, 0x72, 0x69, 0x6e, 0x74,
+0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xcd, 0x73, 0x6c, 0x65, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0xf3, 0x6e, 0x61,
+0x3b, 0x3b, 0xed, 0x73, 0x6c, 0x65, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0xf3, 0x6e, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0xed,
+0x73, 0x6c, 0x65, 0x6e, 0x73, 0x6b, 0x61, 0x72, 0x20, 0x6b, 0x72, 0xf3, 0x6e, 0x75, 0x72, 0x3b, 0x52, 0x75, 0x70, 0x69,
+0x61, 0x68, 0x20, 0x49, 0x6e, 0x64, 0x6f, 0x6e, 0x65, 0x73, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x45,
+0x75, 0x72, 0x6f, 0x73, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x45, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x46, 0x72, 0x61, 0x6e, 0x63, 0x6f, 0x20, 0x53, 0x76, 0x69, 0x7a, 0x7a, 0x65, 0x72, 0x6f, 0x3b, 0x3b, 0x66,
+0x72, 0x61, 0x6e, 0x63, 0x6f, 0x20, 0x73, 0x76, 0x69, 0x7a, 0x7a, 0x65, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72,
+0x61, 0x6e, 0x63, 0x68, 0x69, 0x20, 0x73, 0x76, 0x69, 0x7a, 0x7a, 0x65, 0x72, 0x69, 0x3b, 0x65e5, 0x672c, 0x5186, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xcad, 0xcbe, 0xcb0, 0xca4, 0xcc0, 0xcaf, 0x20, 0xcb0, 0xcc1, 0xcaa, 0xcbe, 0xcaf, 0xcbf, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x6c1, 0x650, 0x646, 0x62f, 0x64f, 0x633, 0x62a, 0x672, 0x646, 0x6cd, 0x20, 0x631, 0x6c4, 0x67e, 0x64e,
+0x6d2, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x49a, 0x430, 0x437, 0x430, 0x49b, 0x441, 0x442, 0x430, 0x43d, 0x20, 0x442, 0x435,
+0x4a3, 0x433, 0x435, 0x441, 0x456, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xb300, 0xd55c, 0xbbfc, 0xad6d, 0x20, 0xc6d0, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xc870, 0xc120, 0x20, 0xbbfc, 0xc8fc, 0xc8fc, 0xc758, 0x20, 0xc778, 0xbbfc, 0x20, 0xacf5, 0xd654, 0xad6d, 0x20,
+0xc6d0, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x49, 0x66, 0x61, 0x72, 0x61, 0x6e, 0x67, 0x61, 0x20, 0x72, 0x79, 0x27,
+0x55, 0x62, 0x75, 0x72, 0x75, 0x6e, 0x64, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xe81, 0xeb5, 0xe9a, 0x20, 0xea5,
+0xeb2, 0xea7, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4c, 0x61, 0x74, 0x76, 0x69, 0x6a, 0x61, 0x73, 0x20, 0x6c, 0x61,
+0x74, 0x73, 0x3b, 0x4c, 0x61, 0x74, 0x76, 0x69, 0x6a, 0x61, 0x73, 0x20, 0x6c, 0x61, 0x74, 0x69, 0x3b, 0x4c, 0x61, 0x74,
+0x76, 0x69, 0x6a, 0x61, 0x73, 0x20, 0x6c, 0x61, 0x74, 0x73, 0x3b, 0x3b, 0x3b, 0x3b, 0x4c, 0x61, 0x74, 0x76, 0x69, 0x6a,
+0x61, 0x73, 0x20, 0x6c, 0x61, 0x74, 0x69, 0x3b, 0x46, 0x61, 0x6c, 0xe1, 0x6e, 0x67, 0x61, 0x20, 0x79, 0x61, 0x20, 0x4b,
+0x6f, 0x6e, 0x67, 0xf3, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4b, 0x77, 0x61, 0x6e, 0x7a, 0x61, 0x20, 0x79, 0x61,
+0x20, 0x41, 0x6e, 0x67, 0xf3, 0x6c, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x61, 0x6c, 0xe1, 0x6e, 0x67,
+0x61, 0x20, 0x43, 0x46, 0x41, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4c, 0x69, 0x65,
+0x74, 0x75, 0x76, 0x6f, 0x73, 0x20, 0x6c, 0x69, 0x74, 0x61, 0x73, 0x3b, 0x3b, 0x4c, 0x69, 0x65, 0x74, 0x75, 0x76, 0x6f,
+0x73, 0x20, 0x6c, 0x69, 0x74, 0x61, 0x73, 0x3b, 0x3b, 0x4c, 0x69, 0x65, 0x74, 0x75, 0x76, 0x6f, 0x73, 0x20, 0x6c, 0x69,
+0x74, 0x61, 0x69, 0x3b, 0x3b, 0x4c, 0x69, 0x65, 0x74, 0x75, 0x76, 0x6f, 0x73, 0x20, 0x6c, 0x69, 0x74, 0x173, 0x3b, 0x41c,
+0x430, 0x43a, 0x435, 0x434, 0x43e, 0x43d, 0x441, 0x43a, 0x438, 0x20, 0x434, 0x435, 0x43d, 0x430, 0x440, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x41, 0x72, 0x69, 0x61, 0x72, 0x79, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x52, 0x69, 0x6e, 0x67, 0x67,
+0x69, 0x74, 0x20, 0x4d, 0x61, 0x6c, 0x61, 0x79, 0x73, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x44, 0x6f,
+0x6c, 0x61, 0x72, 0x20, 0x42, 0x72, 0x75, 0x6e, 0x65, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x44, 0x6f, 0x6c,
+0x61, 0x72, 0x20, 0x53, 0x69, 0x6e, 0x67, 0x61, 0x70, 0x75, 0x72, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xd07,
+0xd28, 0xd4d, 0xd24, 0xd4d, 0xd2f, 0xd7b, 0x20, 0xd30, 0xd42, 0xd2a, 0x3b, 0x3b, 0xd07, 0xd28, 0xd4d, 0xd24, 0xd4d, 0xd2f, 0xd7b, 0x20,
+0xd30, 0xd42, 0xd2a, 0x3b, 0x3b, 0x3b, 0x3b, 0xd07, 0xd28, 0xd4d, 0xd24, 0xd4d, 0xd2f, 0xd7b, 0x20, 0xd30, 0xd42, 0xd2a, 0x3b, 0x45,
+0x77, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x92d, 0x93e, 0x930, 0x924, 0x940, 0x92f, 0x20, 0x930, 0x941, 0x92a,
+0x92f, 0x93e, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x422, 0x4e9, 0x433, 0x440, 0x4e9, 0x433, 0x3b, 0x3b, 0x442, 0x4e9, 0x433,
+0x440, 0x4e9, 0x433, 0x3b, 0x3b, 0x3b, 0x3b, 0x442, 0x4e9, 0x433, 0x440, 0x4e9, 0x433, 0x3b, 0x928, 0x947, 0x92a, 0x93e, 0x932, 0x940,
0x20, 0x930, 0x942, 0x92a, 0x948, 0x92f, 0x93e, 0x901, 0x3b, 0x3b, 0x928, 0x947, 0x92a, 0x93e, 0x932, 0x940, 0x20, 0x930, 0x942, 0x92a,
0x948, 0x92f, 0x93e, 0x901, 0x3b, 0x3b, 0x3b, 0x3b, 0x928, 0x947, 0x92a, 0x93e, 0x932, 0x940, 0x20, 0x930, 0x942, 0x92a, 0x948, 0x92f,
0x93e, 0x901, 0x939, 0x930, 0x942, 0x3b, 0x92d, 0x93e, 0x930, 0x924, 0x940, 0x92f, 0x20, 0x930, 0x942, 0x92a, 0x93f, 0x901, 0x92f, 0x93e,
@@ -4690,198 +4990,213 @@ static const ushort currency_display_name_data[] = {
0x43a, 0x43e, 0x2d, 0x445, 0x435, 0x440, 0x446, 0x435, 0x433, 0x43e, 0x432, 0x430, 0x447, 0x43a, 0x438, 0x445, 0x20, 0x43a, 0x43e, 0x43d,
0x432, 0x435, 0x440, 0x442, 0x438, 0x431, 0x438, 0x43b, 0x43d, 0x438, 0x445, 0x20, 0x43c, 0x430, 0x440, 0x430, 0x43a, 0x430, 0x3b, 0x415,
0x432, 0x440, 0x43e, 0x3b, 0x3b, 0x435, 0x432, 0x440, 0x43e, 0x3b, 0x3b, 0x435, 0x432, 0x440, 0x430, 0x3b, 0x435, 0x432, 0x440, 0x430,
-0x3b, 0x435, 0x432, 0x440, 0x430, 0x3b, 0x42, 0x6f, 0x73, 0x61, 0x6e, 0x73, 0x6b, 0x6f, 0x2d, 0x48, 0x65, 0x72, 0x63, 0x65,
-0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b, 0x61, 0x20, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e,
-0x61, 0x20, 0x6d, 0x61, 0x72, 0x6b, 0x61, 0x3b, 0x3b, 0x62, 0x6f, 0x73, 0x61, 0x6e, 0x73, 0x6b, 0x6f, 0x2d, 0x68, 0x65,
-0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b, 0x61, 0x20, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62,
-0x69, 0x6c, 0x6e, 0x61, 0x20, 0x6d, 0x61, 0x72, 0x6b, 0x61, 0x3b, 0x3b, 0x42, 0x6f, 0x73, 0x61, 0x6e, 0x73, 0x6b, 0x6f,
-0x2d, 0x48, 0x65, 0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b, 0x65, 0x20, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72,
-0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x3b, 0x42, 0x6f, 0x73, 0x61, 0x6e, 0x73,
-0x6b, 0x6f, 0x2d, 0x48, 0x65, 0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b, 0x69, 0x68, 0x20, 0x6b, 0x6f, 0x6e,
-0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x69, 0x68, 0x20, 0x6d, 0x61, 0x72, 0x61, 0x6b, 0x61, 0x3b, 0x62,
-0x6f, 0x73, 0x61, 0x6e, 0x73, 0x6b, 0x6f, 0x2d, 0x68, 0x65, 0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b, 0x69,
-0x68, 0x20, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x69, 0x68, 0x20, 0x6d, 0x61, 0x72,
-0x61, 0x6b, 0x61, 0x3b, 0x45, 0x76, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x76, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x76, 0x72, 0x61,
-0x3b, 0x65, 0x76, 0x72, 0x61, 0x3b, 0x65, 0x76, 0x72, 0x61, 0x3b, 0x53, 0x72, 0x70, 0x73, 0x6b, 0x69, 0x20, 0x64, 0x69,
-0x6e, 0x61, 0x72, 0x3b, 0x3b, 0x73, 0x72, 0x70, 0x73, 0x6b, 0x69, 0x20, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x3b, 0x3b, 0x73,
-0x72, 0x70, 0x73, 0x6b, 0x61, 0x20, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x61, 0x3b, 0x73, 0x72, 0x70, 0x73, 0x6b, 0x69, 0x68,
-0x20, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x61, 0x3b, 0x73, 0x72, 0x70, 0x73, 0x6b, 0x69, 0x20, 0x64, 0x69, 0x6e, 0x61, 0x72,
-0x69, 0x3b, 0x41b, 0x430, 0x440, 0x3b, 0x3b, 0x43b, 0x430, 0x440, 0x3b, 0x3b, 0x3b, 0x3b, 0x43b, 0x430, 0x440, 0x44b, 0x3b, 0x421,
-0x43e, 0x43c, 0x3b, 0x3b, 0x441, 0x43e, 0x43c, 0x3b, 0x3b, 0x3b, 0x3b, 0x441, 0x43e, 0x43c, 0x44b, 0x3b, 0x44, 0x6f, 0x72, 0x61,
-0x20, 0x72, 0x65, 0x20, 0x41, 0x6d, 0x65, 0x72, 0x69, 0x6b, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xdbd, 0xd82,
-0xd9a, 0xdcf, 0x20, 0xdbb, 0xdd4, 0xdb4, 0xdd2, 0xdba, 0xdbd, 0xdca, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x45, 0x75, 0x72,
-0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0xe1, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x2c, 0x20,
-0x65, 0x75, 0x72, 0x61, 0x3b, 0x65, 0x76, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x76, 0x72, 0x6f, 0x3b, 0x65, 0x76, 0x72, 0x61,
-0x3b, 0x65, 0x76, 0x72, 0x69, 0x3b, 0x3b, 0x65, 0x76, 0x72, 0x6f, 0x76, 0x3b, 0x53, 0x68, 0x69, 0x6c, 0x69, 0x6e, 0x20,
-0x73, 0x6f, 0x6f, 0x6d, 0x61, 0x61, 0x6c, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x61, 0x72, 0x61, 0x6e,
-0x20, 0x4a, 0x61, 0x62, 0x62, 0x75, 0x75, 0x74, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x42, 0x69, 0x72, 0x74,
-0x61, 0x20, 0x49, 0x74, 0x6f, 0x6f, 0x62, 0x62, 0x69, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65,
-0x73, 0x6f, 0x20, 0x61, 0x72, 0x67, 0x65, 0x6e, 0x74, 0x69, 0x6e, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x61,
-0x72, 0x67, 0x65, 0x6e, 0x74, 0x69, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x61, 0x72,
-0x67, 0x65, 0x6e, 0x74, 0x69, 0x6e, 0x6f, 0x73, 0x3b, 0x62, 0x6f, 0x6c, 0x69, 0x76, 0x69, 0x61, 0x6e, 0x6f, 0x3b, 0x3b,
-0x62, 0x6f, 0x6c, 0x69, 0x76, 0x69, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x62, 0x6f, 0x6c, 0x69, 0x76, 0x69, 0x61,
-0x6e, 0x6f, 0x73, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x63, 0x68, 0x69, 0x6c, 0x65, 0x6e, 0x6f, 0x3b, 0x3b, 0x70, 0x65,
-0x73, 0x6f, 0x20, 0x63, 0x68, 0x69, 0x6c, 0x65, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20,
-0x63, 0x68, 0x69, 0x6c, 0x65, 0x6e, 0x6f, 0x73, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x63, 0x6f, 0x6c, 0x6f, 0x6d, 0x62,
-0x69, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x63, 0x6f, 0x6c, 0x6f, 0x6d, 0x62, 0x69, 0x61, 0x6e,
-0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x63, 0x6f, 0x6c, 0x6f, 0x6d, 0x62, 0x69, 0x61, 0x6e,
-0x6f, 0x73, 0x3b, 0x63, 0x6f, 0x6c, 0xf3, 0x6e, 0x20, 0x63, 0x6f, 0x73, 0x74, 0x61, 0x72, 0x72, 0x69, 0x63, 0x65, 0x6e,
-0x73, 0x65, 0x3b, 0x3b, 0x63, 0x6f, 0x6c, 0xf3, 0x6e, 0x20, 0x63, 0x6f, 0x73, 0x74, 0x61, 0x72, 0x72, 0x69, 0x63, 0x65,
-0x6e, 0x73, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x63, 0x6f, 0x6c, 0x6f, 0x6e, 0x65, 0x73, 0x20, 0x63, 0x6f, 0x73, 0x74, 0x61,
-0x72, 0x72, 0x69, 0x63, 0x65, 0x6e, 0x73, 0x65, 0x73, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x63, 0x75, 0x62, 0x61, 0x6e,
-0x6f, 0x20, 0x63, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x6c, 0x65, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20,
-0x63, 0x75, 0x62, 0x61, 0x6e, 0x6f, 0x20, 0x63, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x6c, 0x65, 0x3b, 0x3b,
-0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x63, 0x75, 0x62, 0x61, 0x6e, 0x6f, 0x73, 0x20, 0x63, 0x6f, 0x6e, 0x76,
-0x65, 0x72, 0x74, 0x69, 0x62, 0x6c, 0x65, 0x73, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x64, 0x6f, 0x6d, 0x69, 0x6e, 0x69,
-0x63, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x64, 0x6f, 0x6d, 0x69, 0x6e, 0x69, 0x63, 0x61, 0x6e,
-0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x64, 0x6f, 0x6d, 0x69, 0x6e, 0x69, 0x63, 0x61, 0x6e,
-0x6f, 0x73, 0x3b, 0x64, 0xf3, 0x6c, 0x61, 0x72, 0x20, 0x65, 0x73, 0x74, 0x61, 0x64, 0x6f, 0x75, 0x6e, 0x69, 0x64, 0x65,
-0x6e, 0x73, 0x65, 0x3b, 0x3b, 0x64, 0xf3, 0x6c, 0x61, 0x72, 0x20, 0x65, 0x73, 0x74, 0x61, 0x64, 0x6f, 0x75, 0x6e, 0x69,
-0x64, 0x65, 0x6e, 0x73, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x64, 0xf3, 0x6c, 0x61, 0x72, 0x65, 0x73, 0x20, 0x65, 0x73, 0x74,
-0x61, 0x64, 0x6f, 0x75, 0x6e, 0x69, 0x64, 0x65, 0x6e, 0x73, 0x65, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x6f, 0x20,
-0x43, 0x46, 0x41, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x6f, 0x20, 0x43, 0x46, 0x41,
-0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x6f, 0x73, 0x20, 0x43, 0x46, 0x41,
-0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x71, 0x75, 0x65, 0x74, 0x7a, 0x61, 0x6c, 0x20, 0x67, 0x75, 0x61, 0x74, 0x65, 0x6d,
-0x61, 0x6c, 0x74, 0x65, 0x63, 0x6f, 0x3b, 0x3b, 0x71, 0x75, 0x65, 0x74, 0x7a, 0x61, 0x6c, 0x20, 0x67, 0x75, 0x61, 0x74,
-0x65, 0x6d, 0x61, 0x6c, 0x74, 0x65, 0x63, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x71, 0x75, 0x65, 0x74, 0x7a, 0x61, 0x6c, 0x65,
-0x73, 0x20, 0x67, 0x75, 0x61, 0x74, 0x65, 0x6d, 0x61, 0x6c, 0x74, 0x65, 0x63, 0x6f, 0x73, 0x3b, 0x6c, 0x65, 0x6d, 0x70,
-0x69, 0x72, 0x61, 0x20, 0x68, 0x6f, 0x6e, 0x64, 0x75, 0x72, 0x65, 0xf1, 0x6f, 0x3b, 0x3b, 0x6c, 0x65, 0x6d, 0x70, 0x69,
-0x72, 0x61, 0x20, 0x68, 0x6f, 0x6e, 0x64, 0x75, 0x72, 0x65, 0xf1, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x6c, 0x65, 0x6d, 0x70,
-0x69, 0x72, 0x61, 0x73, 0x20, 0x68, 0x6f, 0x6e, 0x64, 0x75, 0x72, 0x65, 0xf1, 0x6f, 0x73, 0x3b, 0x70, 0x65, 0x73, 0x6f,
-0x20, 0x6d, 0x65, 0x78, 0x69, 0x63, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x6d, 0x65, 0x78, 0x69,
-0x63, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x6d, 0x65, 0x78, 0x69, 0x63, 0x61,
-0x6e, 0x6f, 0x73, 0x3b, 0x63, 0xf3, 0x72, 0x64, 0x6f, 0x62, 0x61, 0x20, 0x6e, 0x69, 0x63, 0x61, 0x72, 0x61, 0x67, 0xfc,
-0x65, 0x6e, 0x73, 0x65, 0x3b, 0x3b, 0x63, 0xf3, 0x72, 0x64, 0x6f, 0x62, 0x61, 0x20, 0x6e, 0x69, 0x63, 0x61, 0x72, 0x61,
-0x67, 0xfc, 0x65, 0x6e, 0x73, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x63, 0xf3, 0x72, 0x64, 0x6f, 0x62, 0x61, 0x73, 0x20, 0x6e,
-0x69, 0x63, 0x61, 0x72, 0x61, 0x67, 0xfc, 0x65, 0x6e, 0x73, 0x65, 0x73, 0x3b, 0x62, 0x61, 0x6c, 0x62, 0x6f, 0x61, 0x20,
-0x70, 0x61, 0x6e, 0x61, 0x6d, 0x65, 0xf1, 0x6f, 0x3b, 0x3b, 0x62, 0x61, 0x6c, 0x62, 0x6f, 0x61, 0x20, 0x70, 0x61, 0x6e,
-0x61, 0x6d, 0x65, 0xf1, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x62, 0x61, 0x6c, 0x62, 0x6f, 0x61, 0x73, 0x20, 0x70, 0x61, 0x6e,
-0x61, 0x6d, 0x65, 0xf1, 0x6f, 0x73, 0x3b, 0x67, 0x75, 0x61, 0x72, 0x61, 0x6e, 0xed, 0x20, 0x70, 0x61, 0x72, 0x61, 0x67,
-0x75, 0x61, 0x79, 0x6f, 0x3b, 0x3b, 0x67, 0x75, 0x61, 0x72, 0x61, 0x6e, 0xed, 0x20, 0x70, 0x61, 0x72, 0x61, 0x67, 0x75,
-0x61, 0x79, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x67, 0x75, 0x61, 0x72, 0x61, 0x6e, 0xed, 0x65, 0x73, 0x20, 0x70, 0x61, 0x72,
-0x61, 0x67, 0x75, 0x61, 0x79, 0x6f, 0x73, 0x3b, 0x6e, 0x75, 0x65, 0x76, 0x6f, 0x20, 0x73, 0x6f, 0x6c, 0x20, 0x70, 0x65,
-0x72, 0x75, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x6e, 0x75, 0x65, 0x76, 0x6f, 0x20, 0x73, 0x6f, 0x6c, 0x20, 0x70, 0x65, 0x72,
-0x75, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x6e, 0x75, 0x65, 0x76, 0x6f, 0x73, 0x20, 0x73, 0x6f, 0x6c, 0x65, 0x73,
-0x20, 0x70, 0x65, 0x72, 0x75, 0x61, 0x6e, 0x6f, 0x73, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x66, 0x69, 0x6c, 0x69, 0x70,
-0x69, 0x6e, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x66, 0x69, 0x6c, 0x69, 0x70, 0x69, 0x6e, 0x6f, 0x3b, 0x3b,
-0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x66, 0x69, 0x6c, 0x69, 0x70, 0x69, 0x6e, 0x6f, 0x73, 0x3b, 0x70, 0x65,
-0x73, 0x6f, 0x20, 0x75, 0x72, 0x75, 0x67, 0x75, 0x61, 0x79, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x75, 0x72,
-0x75, 0x67, 0x75, 0x61, 0x79, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x75, 0x72, 0x75, 0x67,
-0x75, 0x61, 0x79, 0x6f, 0x73, 0x3b, 0x62, 0x6f, 0x6c, 0xed, 0x76, 0x61, 0x72, 0x20, 0x76, 0x65, 0x6e, 0x65, 0x7a, 0x6f,
-0x6c, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x62, 0x6f, 0x6c, 0xed, 0x76, 0x61, 0x72, 0x20, 0x76, 0x65, 0x6e, 0x65, 0x7a, 0x6f,
-0x6c, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x62, 0x6f, 0x6c, 0xed, 0x76, 0x61, 0x72, 0x65, 0x73, 0x20, 0x76, 0x65,
-0x6e, 0x65, 0x7a, 0x6f, 0x6c, 0x61, 0x6e, 0x6f, 0x73, 0x3b, 0x73, 0x68, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79,
-0x61, 0x20, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x73, 0x68, 0x69,
-0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x73, 0x68, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x55, 0x67, 0x61, 0x6e, 0x64, 0x61, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x73, 0x76, 0x65, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x61, 0x3b, 0x3b,
-0x73, 0x76, 0x65, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x73, 0x76, 0x65, 0x6e,
-0x73, 0x6b, 0x61, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x6f, 0x72, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72,
-0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x421, 0x43e, 0x43c, 0x43e, 0x43d, 0x4e3, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0xbb0, 0xbc2, 0xbaa, 0xbbe, 0xbaf, 0xbcd, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xbae, 0xbb2, 0xbc7, 0xb9a,
-0xbbf, 0xbaf, 0x20, 0xbb0, 0xbbf, 0xb99, 0xbcd, 0xb95, 0xbbf, 0xb9f, 0xbcd, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xb9a, 0xbbf,
-0xb99, 0xbcd, 0xb95, 0xbaa, 0xbcd, 0xbaa, 0xbc2, 0xbb0, 0xbcd, 0x20, 0xb9f, 0xbbe, 0xbb2, 0xbb0, 0xbcd, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0xb87, 0xbb2, 0xb99, 0xbcd, 0xb95, 0xbc8, 0x20, 0xbb0, 0xbc2, 0xbaa, 0xbbe, 0xbaf, 0xbcd, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0xc30, 0xc42, 0xc2a, 0xc3e, 0xc2f, 0xc3f, 0x3b, 0x3b, 0xc30, 0xc42, 0xc2a, 0xc3e, 0xc2f, 0xc3f, 0x3b, 0x3b, 0x3b, 0x3b,
-0xc30, 0xc42, 0xc2a, 0xc3e, 0xc2f, 0xc32, 0xc41, 0x3b, 0xe1a, 0xe32, 0xe17, 0xe44, 0xe17, 0xe22, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0xf61, 0xf74, 0xf0b, 0xf68, 0xf53, 0xf0b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xf62, 0xf92, 0xfb1, 0xf0b, 0xf42, 0xf62,
-0xf0b, 0xf66, 0xf92, 0xf7c, 0xf62, 0xf0b, 0xf58, 0xf7c, 0xf0b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x12e8, 0x12a2, 0x1275, 0x12ee,
-0x1335, 0x12eb, 0x20, 0x1265, 0x122d, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x54, 0xfc, 0x72, 0x6b, 0x20, 0x4c, 0x69, 0x72,
-0x61, 0x73, 0x131, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x423, 0x43a, 0x440, 0x430, 0x457, 0x43d, 0x441, 0x44c, 0x43a, 0x430,
-0x20, 0x433, 0x440, 0x438, 0x432, 0x43d, 0x44f, 0x3b, 0x3b, 0x433, 0x440, 0x438, 0x432, 0x43d, 0x44f, 0x3b, 0x3b, 0x433, 0x440, 0x438,
-0x432, 0x43d, 0x456, 0x3b, 0x433, 0x440, 0x438, 0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x433, 0x440, 0x438, 0x432, 0x43d, 0x456, 0x3b, 0x67e,
-0x627, 0x6a9, 0x633, 0x62a, 0x627, 0x646, 0x6cc, 0x20, 0x631, 0x648, 0x67e, 0x6cc, 0x6c1, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x627, 0x646, 0x688, 0x6cc, 0x646, 0x20, 0x631, 0x648, 0x67e, 0x6cc, 0x6c1, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x40e, 0x437,
-0x431, 0x435, 0x43a, 0x438, 0x441, 0x442, 0x43e, 0x43d, 0x20, 0x441, 0x45e, 0x43c, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x627,
-0x641, 0x63a, 0x627, 0x646, 0x6cc, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4f, 0x2bb, 0x7a, 0x62, 0x65, 0x6b, 0x69, 0x73,
-0x74, 0x6f, 0x6e, 0x20, 0x73, 0x6f, 0x2bb, 0x6d, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x110, 0x1ed3, 0x6e, 0x67, 0x20,
-0x56, 0x69, 0x1ec7, 0x74, 0x20, 0x4e, 0x61, 0x6d, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x50, 0x75, 0x6e, 0x74, 0x20,
-0x53, 0x74, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x67, 0x20, 0x50, 0x72, 0x79, 0x64, 0x61, 0x69, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x4e, 0x61, 0x69, 0x72, 0x61, 0x20, 0x74, 0x69, 0x20, 0x4f, 0x72, 0xed, 0x6c, 0x1eb9, 0x301, 0xe8, 0x64,
-0x65, 0x20, 0x4e, 0xe0, 0xec, 0x6a, 0xed, 0x72, 0xed, 0xe0, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x69, 0x2d, 0x53,
-0x6f, 0x75, 0x74, 0x68, 0x20, 0x41, 0x66, 0x72, 0x69, 0x63, 0x61, 0x6e, 0x20, 0x52, 0x61, 0x6e, 0x64, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x6e, 0x6f, 0x72, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x65, 0x3b, 0x3b, 0x6e, 0x6f, 0x72,
-0x73, 0x6b, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x6e, 0x6f, 0x72, 0x73, 0x6b, 0x65, 0x20, 0x6b,
-0x72, 0x6f, 0x6e, 0x65, 0x72, 0x3b, 0x41a, 0x43e, 0x43d, 0x432, 0x435, 0x440, 0x442, 0x438, 0x431, 0x438, 0x43b, 0x43d, 0x430, 0x20,
-0x43c, 0x430, 0x440, 0x43a, 0x430, 0x3b, 0x3b, 0x431, 0x43e, 0x441, 0x430, 0x43d, 0x441, 0x43a, 0x43e, 0x2d, 0x445, 0x435, 0x440, 0x446,
-0x435, 0x433, 0x43e, 0x432, 0x430, 0x447, 0x43a, 0x430, 0x20, 0x43a, 0x43e, 0x43d, 0x432, 0x435, 0x440, 0x442, 0x438, 0x431, 0x438, 0x43b,
-0x43d, 0x430, 0x20, 0x43c, 0x430, 0x440, 0x43a, 0x430, 0x3b, 0x3b, 0x431, 0x43e, 0x441, 0x430, 0x43d, 0x441, 0x43a, 0x43e, 0x2d, 0x445,
-0x435, 0x440, 0x446, 0x435, 0x433, 0x43e, 0x432, 0x430, 0x447, 0x43a, 0x435, 0x20, 0x43a, 0x43e, 0x43d, 0x432, 0x435, 0x440, 0x442, 0x438,
-0x431, 0x438, 0x43b, 0x43d, 0x435, 0x20, 0x43c, 0x430, 0x440, 0x43a, 0x3b, 0x431, 0x43e, 0x441, 0x430, 0x43d, 0x441, 0x43a, 0x43e, 0x2d,
-0x445, 0x435, 0x440, 0x446, 0x435, 0x433, 0x43e, 0x432, 0x430, 0x447, 0x43a, 0x438, 0x445, 0x20, 0x43a, 0x43e, 0x43d, 0x432, 0x435, 0x440,
-0x442, 0x430, 0x431, 0x438, 0x43b, 0x43d, 0x438, 0x445, 0x20, 0x43c, 0x430, 0x440, 0x430, 0x43a, 0x430, 0x3b, 0x431, 0x43e, 0x441, 0x430,
-0x43d, 0x441, 0x43a, 0x43e, 0x2d, 0x445, 0x435, 0x440, 0x446, 0x435, 0x433, 0x43e, 0x432, 0x430, 0x447, 0x43a, 0x438, 0x445, 0x20, 0x43a,
-0x43e, 0x43d, 0x432, 0x435, 0x440, 0x442, 0x438, 0x431, 0x438, 0x43b, 0x43d, 0x438, 0x445, 0x20, 0x43c, 0x430, 0x440, 0x430, 0x43a, 0x430,
-0x3b, 0x4e, 0x61, 0x1ecb, 0x72, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69,
-0x20, 0x79, 0x61, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x67, 0x68, 0x61, 0x6e,
-0x61, 0x20, 0x73, 0x69, 0x256, 0x69, 0x3b, 0x3b, 0x67, 0x68, 0x61, 0x6e, 0x61, 0x20, 0x73, 0x69, 0x256, 0x69, 0x3b, 0x3b,
-0x3b, 0x3b, 0x67, 0x68, 0x61, 0x6e, 0x61, 0x20, 0x73, 0x69, 0x256, 0x69, 0x3b, 0x263, 0x65, 0x74, 0x6f, 0x256, 0x6f, 0x66,
-0x65, 0x20, 0x61, 0x66, 0x72, 0x69, 0x6b, 0x61, 0x67, 0x61, 0x20, 0x43, 0x46, 0x41, 0x20, 0x66, 0x72, 0x61, 0x6e, 0x63,
-0x20, 0x42, 0x43, 0x45, 0x41, 0x4f, 0x3b, 0x3b, 0x263, 0x65, 0x74, 0x6f, 0x256, 0x6f, 0x66, 0x65, 0x20, 0x61, 0x66, 0x72,
+0x3b, 0x435, 0x432, 0x440, 0x430, 0x3b, 0x4b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x61, 0x20,
+0x6d, 0x61, 0x72, 0x6b, 0x61, 0x3b, 0x3b, 0x62, 0x6f, 0x73, 0x61, 0x6e, 0x73, 0x6b, 0x6f, 0x2d, 0x68, 0x65, 0x72, 0x63,
+0x65, 0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b, 0x61, 0x20, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c,
+0x6e, 0x61, 0x20, 0x6d, 0x61, 0x72, 0x6b, 0x61, 0x3b, 0x3b, 0x62, 0x6f, 0x73, 0x61, 0x6e, 0x73, 0x6b, 0x6f, 0x2d, 0x68,
+0x65, 0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b, 0x65, 0x20, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69,
+0x62, 0x69, 0x6c, 0x6e, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x6b, 0x65, 0x3b, 0x62, 0x6f, 0x73, 0x61, 0x6e, 0x73, 0x6b, 0x6f,
+0x2d, 0x68, 0x65, 0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b, 0x69, 0x68, 0x20, 0x6b, 0x6f, 0x6e, 0x76, 0x65,
+0x72, 0x74, 0x61, 0x62, 0x69, 0x6c, 0x6e, 0x69, 0x68, 0x20, 0x6d, 0x61, 0x72, 0x61, 0x6b, 0x61, 0x3b, 0x62, 0x6f, 0x73,
+0x61, 0x6e, 0x73, 0x6b, 0x6f, 0x2d, 0x68, 0x65, 0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b, 0x69, 0x68, 0x20,
+0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x69, 0x68, 0x20, 0x6d, 0x61, 0x72, 0x61, 0x6b,
+0x61, 0x3b, 0x45, 0x76, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x76, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x76, 0x72, 0x61, 0x3b, 0x65,
+0x76, 0x72, 0x61, 0x3b, 0x65, 0x76, 0x72, 0x61, 0x3b, 0x53, 0x72, 0x70, 0x73, 0x6b, 0x69, 0x20, 0x64, 0x69, 0x6e, 0x61,
+0x72, 0x3b, 0x3b, 0x73, 0x72, 0x70, 0x73, 0x6b, 0x69, 0x20, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x3b, 0x3b, 0x73, 0x72, 0x70,
+0x73, 0x6b, 0x61, 0x20, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x61, 0x3b, 0x73, 0x72, 0x70, 0x73, 0x6b, 0x69, 0x68, 0x20, 0x64,
+0x69, 0x6e, 0x61, 0x72, 0x61, 0x3b, 0x73, 0x72, 0x70, 0x73, 0x6b, 0x69, 0x68, 0x20, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x61,
+0x3b, 0x41b, 0x430, 0x440, 0x3b, 0x3b, 0x43b, 0x430, 0x440, 0x3b, 0x3b, 0x3b, 0x3b, 0x43b, 0x430, 0x440, 0x44b, 0x3b, 0x421, 0x43e,
+0x43c, 0x3b, 0x3b, 0x441, 0x43e, 0x43c, 0x3b, 0x3b, 0x3b, 0x3b, 0x441, 0x43e, 0x43c, 0x44b, 0x3b, 0x44, 0x6f, 0x72, 0x61, 0x20,
+0x72, 0x65, 0x20, 0x41, 0x6d, 0x65, 0x72, 0x69, 0x6b, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xdbd, 0xd82, 0xd9a,
+0xdcf, 0x20, 0xdbb, 0xdd4, 0xdb4, 0xdd2, 0xdba, 0xdbd, 0xdca, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x45, 0x75, 0x72, 0x6f,
+0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0xe1, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x2c, 0x20, 0x65,
+0x75, 0x72, 0x61, 0x3b, 0x65, 0x76, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x76, 0x72, 0x6f, 0x3b, 0x65, 0x76, 0x72, 0x61, 0x3b,
+0x65, 0x76, 0x72, 0x69, 0x3b, 0x3b, 0x65, 0x76, 0x72, 0x6f, 0x76, 0x3b, 0x53, 0x68, 0x69, 0x6c, 0x69, 0x6e, 0x20, 0x73,
+0x6f, 0x6f, 0x6d, 0x61, 0x61, 0x6c, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x61, 0x72, 0x61, 0x6e, 0x20,
+0x4a, 0x61, 0x62, 0x62, 0x75, 0x75, 0x74, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x42, 0x69, 0x72, 0x74, 0x61,
+0x20, 0x49, 0x74, 0x6f, 0x6f, 0x62, 0x62, 0x69, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73,
+0x6f, 0x20, 0x61, 0x72, 0x67, 0x65, 0x6e, 0x74, 0x69, 0x6e, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x61, 0x72,
+0x67, 0x65, 0x6e, 0x74, 0x69, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x61, 0x72, 0x67,
+0x65, 0x6e, 0x74, 0x69, 0x6e, 0x6f, 0x73, 0x3b, 0x62, 0x6f, 0x6c, 0x69, 0x76, 0x69, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x62,
+0x6f, 0x6c, 0x69, 0x76, 0x69, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x62, 0x6f, 0x6c, 0x69, 0x76, 0x69, 0x61, 0x6e,
+0x6f, 0x73, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x63, 0x68, 0x69, 0x6c, 0x65, 0x6e, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73,
+0x6f, 0x20, 0x63, 0x68, 0x69, 0x6c, 0x65, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x63,
+0x68, 0x69, 0x6c, 0x65, 0x6e, 0x6f, 0x73, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x63, 0x6f, 0x6c, 0x6f, 0x6d, 0x62, 0x69,
+0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x63, 0x6f, 0x6c, 0x6f, 0x6d, 0x62, 0x69, 0x61, 0x6e, 0x6f,
+0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x63, 0x6f, 0x6c, 0x6f, 0x6d, 0x62, 0x69, 0x61, 0x6e, 0x6f,
+0x73, 0x3b, 0x63, 0x6f, 0x6c, 0xf3, 0x6e, 0x20, 0x63, 0x6f, 0x73, 0x74, 0x61, 0x72, 0x72, 0x69, 0x63, 0x65, 0x6e, 0x73,
+0x65, 0x3b, 0x3b, 0x63, 0x6f, 0x6c, 0xf3, 0x6e, 0x20, 0x63, 0x6f, 0x73, 0x74, 0x61, 0x72, 0x72, 0x69, 0x63, 0x65, 0x6e,
+0x73, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x63, 0x6f, 0x6c, 0x6f, 0x6e, 0x65, 0x73, 0x20, 0x63, 0x6f, 0x73, 0x74, 0x61, 0x72,
+0x72, 0x69, 0x63, 0x65, 0x6e, 0x73, 0x65, 0x73, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x63, 0x75, 0x62, 0x61, 0x6e, 0x6f,
+0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x63, 0x75, 0x62, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73,
+0x6f, 0x73, 0x20, 0x63, 0x75, 0x62, 0x61, 0x6e, 0x6f, 0x73, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x64, 0x6f, 0x6d, 0x69,
+0x6e, 0x69, 0x63, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x64, 0x6f, 0x6d, 0x69, 0x6e, 0x69, 0x63,
+0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x64, 0x6f, 0x6d, 0x69, 0x6e, 0x69, 0x63,
+0x61, 0x6e, 0x6f, 0x73, 0x3b, 0x64, 0xf3, 0x6c, 0x61, 0x72, 0x20, 0x65, 0x73, 0x74, 0x61, 0x64, 0x6f, 0x75, 0x6e, 0x69,
+0x64, 0x65, 0x6e, 0x73, 0x65, 0x3b, 0x3b, 0x64, 0xf3, 0x6c, 0x61, 0x72, 0x20, 0x65, 0x73, 0x74, 0x61, 0x64, 0x6f, 0x75,
+0x6e, 0x69, 0x64, 0x65, 0x6e, 0x73, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x64, 0xf3, 0x6c, 0x61, 0x72, 0x65, 0x73, 0x20, 0x65,
+0x73, 0x74, 0x61, 0x64, 0x6f, 0x75, 0x6e, 0x69, 0x64, 0x65, 0x6e, 0x73, 0x65, 0x73, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63,
+0x6f, 0x20, 0x43, 0x46, 0x41, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x6f, 0x20, 0x43,
+0x46, 0x41, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x6f, 0x73, 0x20, 0x43,
+0x46, 0x41, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x71, 0x75, 0x65, 0x74, 0x7a, 0x61, 0x6c, 0x20, 0x67, 0x75, 0x61, 0x74,
+0x65, 0x6d, 0x61, 0x6c, 0x74, 0x65, 0x63, 0x6f, 0x3b, 0x3b, 0x71, 0x75, 0x65, 0x74, 0x7a, 0x61, 0x6c, 0x20, 0x67, 0x75,
+0x61, 0x74, 0x65, 0x6d, 0x61, 0x6c, 0x74, 0x65, 0x63, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x71, 0x75, 0x65, 0x74, 0x7a, 0x61,
+0x6c, 0x65, 0x73, 0x20, 0x67, 0x75, 0x61, 0x74, 0x65, 0x6d, 0x61, 0x6c, 0x74, 0x65, 0x63, 0x6f, 0x73, 0x3b, 0x6c, 0x65,
+0x6d, 0x70, 0x69, 0x72, 0x61, 0x20, 0x68, 0x6f, 0x6e, 0x64, 0x75, 0x72, 0x65, 0xf1, 0x6f, 0x3b, 0x3b, 0x6c, 0x65, 0x6d,
+0x70, 0x69, 0x72, 0x61, 0x20, 0x68, 0x6f, 0x6e, 0x64, 0x75, 0x72, 0x65, 0xf1, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x6c, 0x65,
+0x6d, 0x70, 0x69, 0x72, 0x61, 0x73, 0x20, 0x68, 0x6f, 0x6e, 0x64, 0x75, 0x72, 0x65, 0xf1, 0x6f, 0x73, 0x3b, 0x70, 0x65,
+0x73, 0x6f, 0x20, 0x6d, 0x65, 0x78, 0x69, 0x63, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x6d, 0x65,
+0x78, 0x69, 0x63, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x6d, 0x65, 0x78, 0x69,
+0x63, 0x61, 0x6e, 0x6f, 0x73, 0x3b, 0x63, 0xf3, 0x72, 0x64, 0x6f, 0x62, 0x61, 0x20, 0x6e, 0x69, 0x63, 0x61, 0x72, 0x61,
+0x67, 0xfc, 0x65, 0x6e, 0x73, 0x65, 0x3b, 0x3b, 0x63, 0xf3, 0x72, 0x64, 0x6f, 0x62, 0x61, 0x20, 0x6e, 0x69, 0x63, 0x61,
+0x72, 0x61, 0x67, 0xfc, 0x65, 0x6e, 0x73, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x63, 0xf3, 0x72, 0x64, 0x6f, 0x62, 0x61, 0x73,
+0x20, 0x6e, 0x69, 0x63, 0x61, 0x72, 0x61, 0x67, 0xfc, 0x65, 0x6e, 0x73, 0x65, 0x73, 0x3b, 0x62, 0x61, 0x6c, 0x62, 0x6f,
+0x61, 0x20, 0x70, 0x61, 0x6e, 0x61, 0x6d, 0x65, 0xf1, 0x6f, 0x3b, 0x3b, 0x62, 0x61, 0x6c, 0x62, 0x6f, 0x61, 0x20, 0x70,
+0x61, 0x6e, 0x61, 0x6d, 0x65, 0xf1, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x62, 0x61, 0x6c, 0x62, 0x6f, 0x61, 0x73, 0x20, 0x70,
+0x61, 0x6e, 0x61, 0x6d, 0x65, 0xf1, 0x6f, 0x73, 0x3b, 0x67, 0x75, 0x61, 0x72, 0x61, 0x6e, 0xed, 0x20, 0x70, 0x61, 0x72,
+0x61, 0x67, 0x75, 0x61, 0x79, 0x6f, 0x3b, 0x3b, 0x67, 0x75, 0x61, 0x72, 0x61, 0x6e, 0xed, 0x20, 0x70, 0x61, 0x72, 0x61,
+0x67, 0x75, 0x61, 0x79, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x67, 0x75, 0x61, 0x72, 0x61, 0x6e, 0xed, 0x65, 0x73, 0x20, 0x70,
+0x61, 0x72, 0x61, 0x67, 0x75, 0x61, 0x79, 0x6f, 0x73, 0x3b, 0x6e, 0x75, 0x65, 0x76, 0x6f, 0x20, 0x73, 0x6f, 0x6c, 0x20,
+0x70, 0x65, 0x72, 0x75, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x6e, 0x75, 0x65, 0x76, 0x6f, 0x20, 0x73, 0x6f, 0x6c, 0x20, 0x70,
+0x65, 0x72, 0x75, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x6e, 0x75, 0x65, 0x76, 0x6f, 0x73, 0x20, 0x73, 0x6f, 0x6c,
+0x65, 0x73, 0x20, 0x70, 0x65, 0x72, 0x75, 0x61, 0x6e, 0x6f, 0x73, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x66, 0x69, 0x6c,
+0x69, 0x70, 0x69, 0x6e, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20, 0x66, 0x69, 0x6c, 0x69, 0x70, 0x69, 0x6e, 0x6f,
+0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x66, 0x69, 0x6c, 0x69, 0x70, 0x69, 0x6e, 0x6f, 0x73, 0x3b,
+0x70, 0x65, 0x73, 0x6f, 0x20, 0x75, 0x72, 0x75, 0x67, 0x75, 0x61, 0x79, 0x6f, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x20,
+0x75, 0x72, 0x75, 0x67, 0x75, 0x61, 0x79, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x70, 0x65, 0x73, 0x6f, 0x73, 0x20, 0x75, 0x72,
+0x75, 0x67, 0x75, 0x61, 0x79, 0x6f, 0x73, 0x3b, 0x62, 0x6f, 0x6c, 0xed, 0x76, 0x61, 0x72, 0x20, 0x76, 0x65, 0x6e, 0x65,
+0x7a, 0x6f, 0x6c, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x62, 0x6f, 0x6c, 0xed, 0x76, 0x61, 0x72, 0x20, 0x76, 0x65, 0x6e, 0x65,
+0x7a, 0x6f, 0x6c, 0x61, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x62, 0x6f, 0x6c, 0xed, 0x76, 0x61, 0x72, 0x65, 0x73, 0x20,
+0x76, 0x65, 0x6e, 0x65, 0x7a, 0x6f, 0x6c, 0x61, 0x6e, 0x6f, 0x73, 0x3b, 0x73, 0x68, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69,
+0x20, 0x79, 0x61, 0x20, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x73,
+0x68, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x73, 0x68, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x55, 0x67, 0x61, 0x6e, 0x64,
+0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x73, 0x76, 0x65, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x61,
+0x3b, 0x3b, 0x73, 0x76, 0x65, 0x6e, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x73, 0x76,
+0x65, 0x6e, 0x73, 0x6b, 0x61, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x6f, 0x72, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65,
+0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x421, 0x43e, 0x43c, 0x43e, 0x43d, 0x4e3, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xbb0, 0xbc2, 0xbaa, 0xbbe, 0xbaf, 0xbcd, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xbae, 0xbb2,
+0xbc7, 0xb9a, 0xbbf, 0xbaf, 0x20, 0xbb0, 0xbbf, 0xb99, 0xbcd, 0xb95, 0xbbf, 0xb9f, 0xbcd, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0xb9a, 0xbbf, 0xb99, 0xbcd, 0xb95, 0xbaa, 0xbcd, 0xbaa, 0xbc2, 0xbb0, 0xbcd, 0x20, 0xb9f, 0xbbe, 0xbb2, 0xbb0, 0xbcd, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0xb87, 0xbb2, 0xb99, 0xbcd, 0xb95, 0xbc8, 0x20, 0xbb0, 0xbc2, 0xbaa, 0xbbe, 0xbaf, 0xbcd, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0xc30, 0xc42, 0xc2a, 0xc3e, 0xc2f, 0xc3f, 0x3b, 0x3b, 0xc30, 0xc42, 0xc2a, 0xc3e, 0xc2f, 0xc3f, 0x3b, 0x3b,
+0x3b, 0x3b, 0xc30, 0xc42, 0xc2a, 0xc3e, 0xc2f, 0xc32, 0xc41, 0x3b, 0xe1a, 0xe32, 0xe17, 0xe44, 0xe17, 0xe22, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0xf61, 0xf74, 0xf0b, 0xf68, 0xf53, 0xf0b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0xf62, 0xf92, 0xfb1, 0xf0b,
+0xf42, 0xf62, 0xf0b, 0xf66, 0xf92, 0xf7c, 0xf62, 0xf0b, 0xf58, 0xf7c, 0xf0b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x12e8, 0x12a2,
+0x1275, 0x12ee, 0x1335, 0x12eb, 0x20, 0x1265, 0x122d, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x54, 0xfc, 0x72, 0x6b, 0x20, 0x4c,
+0x69, 0x72, 0x61, 0x73, 0x131, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x423, 0x43a, 0x440, 0x430, 0x457, 0x43d, 0x441, 0x44c,
+0x43a, 0x430, 0x20, 0x433, 0x440, 0x438, 0x432, 0x43d, 0x44f, 0x3b, 0x3b, 0x433, 0x440, 0x438, 0x432, 0x43d, 0x44f, 0x3b, 0x3b, 0x433,
+0x440, 0x438, 0x432, 0x43d, 0x456, 0x3b, 0x433, 0x440, 0x438, 0x432, 0x435, 0x43d, 0x44c, 0x3b, 0x433, 0x440, 0x438, 0x432, 0x43d, 0x456,
+0x3b, 0x67e, 0x627, 0x6a9, 0x633, 0x62a, 0x627, 0x646, 0x6cc, 0x20, 0x631, 0x648, 0x67e, 0x6cc, 0x6c1, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x627, 0x646, 0x688, 0x6cc, 0x646, 0x20, 0x631, 0x648, 0x67e, 0x6cc, 0x6c1, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x40e, 0x437, 0x431, 0x435, 0x43a, 0x438, 0x441, 0x442, 0x43e, 0x43d, 0x20, 0x441, 0x45e, 0x43c, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x627, 0x641, 0x63a, 0x627, 0x646, 0x6cc, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4f, 0x2bb, 0x7a, 0x62, 0x65, 0x6b,
+0x69, 0x73, 0x74, 0x6f, 0x6e, 0x20, 0x73, 0x6f, 0x2bb, 0x6d, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x110, 0x1ed3, 0x6e,
+0x67, 0x20, 0x56, 0x69, 0x1ec7, 0x74, 0x20, 0x4e, 0x61, 0x6d, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x50, 0x75, 0x6e,
+0x74, 0x20, 0x53, 0x74, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x67, 0x20, 0x50, 0x72, 0x79, 0x64, 0x61, 0x69, 0x6e, 0x3b, 0x50,
+0x75, 0x6e, 0x74, 0x20, 0x53, 0x74, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x67, 0x20, 0x50, 0x72, 0x79, 0x64, 0x61, 0x69, 0x6e,
+0x3b, 0x50, 0x75, 0x6e, 0x74, 0x20, 0x53, 0x74, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x67, 0x20, 0x50, 0x72, 0x79, 0x64, 0x61,
+0x69, 0x6e, 0x3b, 0x50, 0x75, 0x6e, 0x74, 0x20, 0x53, 0x74, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x67, 0x20, 0x50, 0x72, 0x79,
+0x64, 0x61, 0x69, 0x6e, 0x3b, 0x50, 0x75, 0x6e, 0x74, 0x20, 0x53, 0x74, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x67, 0x20, 0x50,
+0x72, 0x79, 0x64, 0x61, 0x69, 0x6e, 0x3b, 0x50, 0x75, 0x6e, 0x74, 0x20, 0x53, 0x74, 0x65, 0x72, 0x6c, 0x69, 0x6e, 0x67,
+0x20, 0x50, 0x72, 0x79, 0x64, 0x61, 0x69, 0x6e, 0x3b, 0x50, 0x75, 0x6e, 0x74, 0x20, 0x53, 0x74, 0x65, 0x72, 0x6c, 0x69,
+0x6e, 0x67, 0x20, 0x50, 0x72, 0x79, 0x64, 0x61, 0x69, 0x6e, 0x3b, 0x4e, 0x61, 0x69, 0x72, 0x61, 0x20, 0x74, 0x69, 0x20,
+0x4f, 0x72, 0xed, 0x6c, 0x1eb9, 0x301, 0xe8, 0x64, 0x65, 0x20, 0x4e, 0xe0, 0xec, 0x6a, 0xed, 0x72, 0xed, 0xe0, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x69, 0x2d, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x41, 0x66, 0x72, 0x69, 0x63, 0x61, 0x6e,
+0x20, 0x52, 0x61, 0x6e, 0x64, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x6e, 0x6f, 0x72, 0x73, 0x6b, 0x20, 0x6b, 0x72,
+0x6f, 0x6e, 0x65, 0x3b, 0x3b, 0x6e, 0x6f, 0x72, 0x73, 0x6b, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x65, 0x3b, 0x3b, 0x3b, 0x3b,
+0x6e, 0x6f, 0x72, 0x73, 0x6b, 0x65, 0x20, 0x6b, 0x72, 0x6f, 0x6e, 0x65, 0x72, 0x3b, 0x42, 0x6f, 0x73, 0x61, 0x6e, 0x73,
+0x6b, 0x6f, 0x2d, 0x48, 0x65, 0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b, 0x61, 0x20, 0x6b, 0x6f, 0x6e, 0x76,
+0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x61, 0x20, 0x6d, 0x61, 0x72, 0x6b, 0x61, 0x3b, 0x3b, 0x62, 0x6f, 0x73,
+0x61, 0x6e, 0x73, 0x6b, 0x6f, 0x2d, 0x68, 0x65, 0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b, 0x61, 0x20, 0x6b,
+0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x61, 0x20, 0x6d, 0x61, 0x72, 0x6b, 0x61, 0x3b, 0x3b,
+0x42, 0x6f, 0x73, 0x61, 0x6e, 0x73, 0x6b, 0x6f, 0x2d, 0x48, 0x65, 0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b,
+0x65, 0x20, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x65, 0x20, 0x6d, 0x61, 0x72, 0x6b,
+0x65, 0x3b, 0x42, 0x6f, 0x73, 0x61, 0x6e, 0x73, 0x6b, 0x6f, 0x2d, 0x48, 0x65, 0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x61,
+0x10d, 0x6b, 0x69, 0x68, 0x20, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69, 0x6c, 0x6e, 0x69, 0x68, 0x20,
+0x6d, 0x61, 0x72, 0x61, 0x6b, 0x61, 0x3b, 0x62, 0x6f, 0x73, 0x61, 0x6e, 0x73, 0x6b, 0x6f, 0x2d, 0x68, 0x65, 0x72, 0x63,
+0x65, 0x67, 0x6f, 0x76, 0x61, 0x10d, 0x6b, 0x69, 0x68, 0x20, 0x6b, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x69, 0x62, 0x69,
+0x6c, 0x6e, 0x69, 0x68, 0x20, 0x6d, 0x61, 0x72, 0x61, 0x6b, 0x61, 0x3b, 0x41a, 0x43e, 0x43d, 0x432, 0x435, 0x440, 0x442, 0x438,
+0x431, 0x438, 0x43b, 0x43d, 0x430, 0x20, 0x43c, 0x430, 0x440, 0x43a, 0x430, 0x3b, 0x3b, 0x431, 0x43e, 0x441, 0x430, 0x43d, 0x441, 0x43a,
+0x43e, 0x2d, 0x445, 0x435, 0x440, 0x446, 0x435, 0x433, 0x43e, 0x432, 0x430, 0x447, 0x43a, 0x430, 0x20, 0x43a, 0x43e, 0x43d, 0x432, 0x435,
+0x440, 0x442, 0x438, 0x431, 0x438, 0x43b, 0x43d, 0x430, 0x20, 0x43c, 0x430, 0x440, 0x43a, 0x430, 0x3b, 0x3b, 0x431, 0x43e, 0x441, 0x430,
+0x43d, 0x441, 0x43a, 0x43e, 0x2d, 0x445, 0x435, 0x440, 0x446, 0x435, 0x433, 0x43e, 0x432, 0x430, 0x447, 0x43a, 0x435, 0x20, 0x43a, 0x43e,
+0x43d, 0x432, 0x435, 0x440, 0x442, 0x438, 0x431, 0x438, 0x43b, 0x43d, 0x435, 0x20, 0x43c, 0x430, 0x440, 0x43a, 0x3b, 0x431, 0x43e, 0x441,
+0x430, 0x43d, 0x441, 0x43a, 0x43e, 0x2d, 0x445, 0x435, 0x440, 0x446, 0x435, 0x433, 0x43e, 0x432, 0x430, 0x447, 0x43a, 0x438, 0x445, 0x20,
+0x43a, 0x43e, 0x43d, 0x432, 0x435, 0x440, 0x442, 0x430, 0x431, 0x438, 0x43b, 0x43d, 0x438, 0x445, 0x20, 0x43c, 0x430, 0x440, 0x430, 0x43a,
+0x430, 0x3b, 0x431, 0x43e, 0x441, 0x430, 0x43d, 0x441, 0x43a, 0x43e, 0x2d, 0x445, 0x435, 0x440, 0x446, 0x435, 0x433, 0x43e, 0x432, 0x430,
+0x447, 0x43a, 0x438, 0x445, 0x20, 0x43a, 0x43e, 0x43d, 0x432, 0x435, 0x440, 0x442, 0x438, 0x431, 0x438, 0x43b, 0x43d, 0x438, 0x445, 0x20,
+0x43c, 0x430, 0x440, 0x430, 0x43a, 0x430, 0x3b, 0x47, 0x68, 0x61, 0x6e, 0x61, 0x20, 0x53, 0x69, 0x64, 0x69, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x61, 0x1ecb, 0x72, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69, 0x6c, 0x69,
+0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x67,
+0x68, 0x61, 0x6e, 0x61, 0x20, 0x73, 0x69, 0x256, 0x69, 0x3b, 0x3b, 0x67, 0x68, 0x61, 0x6e, 0x61, 0x20, 0x73, 0x69, 0x256,
+0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x67, 0x68, 0x61, 0x6e, 0x61, 0x20, 0x73, 0x69, 0x256, 0x69, 0x3b, 0x263, 0x65, 0x74, 0x6f,
+0x256, 0x6f, 0x66, 0x65, 0x20, 0x61, 0x66, 0x72, 0x69, 0x6b, 0x61, 0x67, 0x61, 0x20, 0x43, 0x46, 0x41, 0x20, 0x66, 0x72,
+0x61, 0x6e, 0x63, 0x20, 0x42, 0x43, 0x45, 0x41, 0x4f, 0x3b, 0x3b, 0x263, 0x65, 0x74, 0x6f, 0x256, 0x6f, 0x66, 0x65, 0x20,
+0x61, 0x66, 0x72, 0x69, 0x6b, 0x61, 0x67, 0x61, 0x20, 0x43, 0x46, 0x41, 0x20, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x42,
+0x43, 0x45, 0x41, 0x4f, 0x3b, 0x3b, 0x3b, 0x3b, 0x263, 0x65, 0x74, 0x6f, 0x256, 0x6f, 0x66, 0x65, 0x20, 0x61, 0x66, 0x72,
0x69, 0x6b, 0x61, 0x67, 0x61, 0x20, 0x43, 0x46, 0x41, 0x20, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x42, 0x43, 0x45, 0x41,
-0x4f, 0x3b, 0x3b, 0x3b, 0x3b, 0x263, 0x65, 0x74, 0x6f, 0x256, 0x6f, 0x66, 0x65, 0x20, 0x61, 0x66, 0x72, 0x69, 0x6b, 0x61,
-0x67, 0x61, 0x20, 0x43, 0x46, 0x41, 0x20, 0x66, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x42, 0x43, 0x45, 0x41, 0x4f, 0x3b, 0x50,
-0x68, 0x69, 0x6c, 0x69, 0x70, 0x70, 0x69, 0x6e, 0x65, 0x20, 0x50, 0x65, 0x73, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x53, 0x63, 0x68, 0x77, 0x69, 0x69, 0x7a, 0x65, 0x72, 0x20, 0x46, 0x72, 0x61, 0x6e, 0x6b, 0x65, 0x3b, 0x3b, 0x53,
-0x63, 0x68, 0x77, 0x69, 0x69, 0x7a, 0x65, 0x72, 0x20, 0x46, 0x72, 0x61, 0x6e, 0x6b, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x53,
-0x63, 0x68, 0x77, 0x69, 0x69, 0x7a, 0x65, 0x72, 0x20, 0x46, 0x72, 0x61, 0x6e, 0x6b, 0x65, 0x3b, 0x6e, 0x6f, 0x72, 0x67,
-0x67, 0x61, 0x20, 0x6b, 0x72, 0x75, 0x76, 0x64, 0x6e, 0x6f, 0x3b, 0x3b, 0x6e, 0x6f, 0x72, 0x67, 0x67, 0x61, 0x20, 0x6b,
-0x72, 0x75, 0x76, 0x64, 0x6e, 0x6f, 0x3b, 0x6e, 0x6f, 0x72, 0x67, 0x67, 0x61, 0x20, 0x6b, 0x72, 0x75, 0x76, 0x64, 0x6e,
-0x6f, 0x3b, 0x3b, 0x3b, 0x6e, 0x6f, 0x72, 0x67, 0x67, 0x61, 0x20, 0x6b, 0x72, 0x75, 0x76, 0x64, 0x6e, 0x6f, 0x3b, 0x65,
-0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b, 0x65, 0x75, 0x72,
-0x6f, 0x3b, 0x53, 0x68, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4d, 0x62, 0x75, 0x75, 0x257, 0x75, 0x20, 0x53, 0x65, 0x65, 0x66, 0x61, 0x61, 0x20,
-0x42, 0x43, 0x45, 0x41, 0x4f, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x43, 0x69, 0x72, 0x69, 0x6e, 0x67, 0x69, 0x20,
-0x79, 0x61, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x6a, 0x69, 0x6c, 0x69,
-0x6e, 0x67, 0x69, 0x20, 0x65, 0x65, 0x6c, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x4d, 0x65, 0x74, 0x69, 0x63, 0x61, 0x6c, 0x20, 0x64, 0x65, 0x20, 0x4d, 0x6f, 0xe7, 0x61, 0x6d, 0x62, 0x69, 0x71, 0x75,
-0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x44, 0x6f, 0x6c, 0x61, 0x20, 0x79, 0x61, 0x73, 0x65, 0x20, 0x41, 0x6d,
-0x65, 0x6c, 0x69, 0x6b, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x68, 0x65, 0x6c, 0x65, 0x72, 0x69, 0x20, 0x73,
-0x61, 0x20, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x2d30, 0x2d37, 0x2d54,
-0x2d49, 0x2d4e, 0x20, 0x2d4f, 0x20, 0x2d4d, 0x2d4e, 0x2d56, 0x2d54, 0x2d49, 0x2d31, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x61, 0x64,
-0x72, 0x69, 0x6d, 0x20, 0x6e, 0x20, 0x6c, 0x6d, 0x263, 0x72, 0x69, 0x62, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x41,
-0x64, 0x69, 0x6e, 0x61, 0x72, 0x20, 0x41, 0x7a, 0x7a, 0x61, 0x79, 0x72, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x45, 0x73, 0x68, 0x69, 0x72, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x55, 0x67, 0x61, 0x6e, 0x64, 0x61, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x68, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x48, 0x75,
-0x74, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x68, 0x69, 0x6c, 0x69,
-0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x73, 0x65, 0x66, 0x61, 0x20, 0x46, 0x72, 0x61, 0x14b, 0x20, 0x28, 0x42, 0x43, 0x45, 0x41, 0x4f, 0x29, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x13a4, 0x13c3, 0x13cd, 0x13d7, 0x3b, 0x3b, 0x13a4, 0x13c3, 0x13cd, 0x13d7, 0x3b, 0x3b, 0x3b, 0x3b,
-0x13e7, 0x13c3, 0x13cd, 0x13d7, 0x3b, 0x72, 0x6f, 0x75, 0x70, 0x69, 0x20, 0x6d, 0x6f, 0x72, 0x69, 0x73, 0x69, 0x65, 0x6e, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x68, 0x69, 0x6c, 0xed, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x54,
-0x61, 0x61, 0x6e, 0x73, 0x61, 0x6e, 0xed, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69, 0x6c, 0x69, 0x6e,
-0x67, 0x69, 0x20, 0x65, 0x79, 0x61, 0x20, 0x59, 0x75, 0x67, 0x61, 0x6e, 0x64, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x53, 0x6b, 0x75, 0x64, 0x75, 0x20, 0x4b, 0x61, 0x62, 0x75, 0x76, 0x65, 0x72, 0x64, 0x69, 0x61, 0x6e, 0x75, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x74, 0x61, 0x62, 0x20, 0x79, 0x61, 0x20,
-0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x61, 0x6d, 0x69, 0x62, 0x69, 0x61, 0x20,
-0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x49, 0x72, 0x6f, 0x70, 0x69, 0x79,
-0x69, 0x61, 0x6e, 0xed, 0x20, 0x65, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x49,
-0x72, 0x6f, 0x70, 0x69, 0x79, 0x69, 0x61, 0x6e, 0xed, 0x20, 0x65, 0x20, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69, 0x72, 0x69, 0x6e, 0x6a, 0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x65,
-0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x73, 0x68, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79,
-0x61, 0x20, 0x54, 0x61, 0x6e, 0x64, 0x68, 0x61, 0x6e, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x41, 0x6e,
-0x67, 0x6f, 0x27, 0x6f, 0x74, 0x6f, 0x6c, 0x20, 0x6c, 0x6f, 0x6b, 0x27, 0x20, 0x55, 0x67, 0x61, 0x6e, 0x64, 0x61, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x41, 0x6e, 0x67, 0x6f, 0x27, 0x6f, 0x74, 0x6f, 0x6c, 0x20, 0x6c, 0x6f, 0x6b, 0x27,
-0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x43, 0x46, 0x41, 0x20, 0x46, 0x72, 0x61,
-0x14b, 0x20, 0x28, 0x42, 0x43, 0x45, 0x41, 0x4f, 0x29, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69, 0x6c, 0x69,
-0x6e, 0x67, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x44,
-0x65, 0x72, 0x68, 0x65, 0x6d, 0x20, 0x55, 0x6d, 0x65, 0x1e5b, 0x1e5b, 0x75, 0x6b, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x930, 0x93e, 0x902, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x66, 0x61, 0x6c, 0x61, 0x6e, 0x67, 0x61, 0x20,
-0x77, 0x61, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x75, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x43, 0x46, 0x41, 0x20, 0x46,
-0xe0, 0x6c, 0xe2, 0x14b, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x72, 0x1ce, 0x14b,
-0x20, 0x43, 0x46, 0x41, 0x20, 0x28, 0x42, 0x45, 0x41, 0x43, 0x29, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x73, 0x65,
-0x65, 0x66, 0x61, 0x20, 0x79, 0x61, 0x74, 0x69, 0x20, 0x42, 0x43, 0x45, 0x41, 0x4f, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x46, 0x259, 0x6c, 0xe1, 0x14b, 0x20, 0x43, 0x46, 0x41, 0x20, 0x28, 0x42, 0x45, 0x41, 0x43, 0x29, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0xe1, 0x14b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x73, 0x6f, 0x6c, 0x61, 0x69,
-0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x72, 0x61, 0x14b, 0x20, 0x43, 0x46, 0x41,
-0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x49, 0x68, 0x65, 0x6c, 0x61, 0x20, 0x79, 0x61,
-0x20, 0x54, 0x61, 0x6e, 0x73, 0x61, 0x6e, 0x69, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x61, 0x72,
-0x61, 0x6e, 0x67, 0x61, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
-0xa55e, 0xa524, 0xa52b, 0xa569, 0x20, 0xa55c, 0xa55e, 0xa54c, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4c, 0x61, 0x69, 0x62, 0x68,
-0x69, 0x79, 0x61, 0x20, 0x44, 0x61, 0x6c, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x25b, 0x6c, 0xe2, 0x14b,
-0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x41, 0x3b, 0x3b, 0x3b, 0x3b,
-0x3b, 0x3b, 0x3b, 0x73, 0x68, 0x69, 0x72, 0xe8, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x65, 0x6c, 0xe1, 0x14b,
-0x20, 0x43, 0x46, 0x41, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b
+0x4f, 0x3b, 0x50, 0x68, 0x69, 0x6c, 0x69, 0x70, 0x70, 0x69, 0x6e, 0x65, 0x20, 0x50, 0x65, 0x73, 0x6f, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x63, 0x68, 0x77, 0x69, 0x69, 0x7a, 0x65, 0x72, 0x20, 0x46, 0x72, 0x61, 0x6e, 0x6b, 0x65,
+0x3b, 0x3b, 0x53, 0x63, 0x68, 0x77, 0x69, 0x69, 0x7a, 0x65, 0x72, 0x20, 0x46, 0x72, 0x61, 0x6e, 0x6b, 0x65, 0x3b, 0x3b,
+0x3b, 0x3b, 0x53, 0x63, 0x68, 0x77, 0x69, 0x69, 0x7a, 0x65, 0x72, 0x20, 0x46, 0x72, 0x61, 0x6e, 0x6b, 0x65, 0x3b, 0x6e,
+0x6f, 0x72, 0x67, 0x67, 0x61, 0x20, 0x6b, 0x72, 0x75, 0x76, 0x64, 0x6e, 0x6f, 0x3b, 0x3b, 0x6e, 0x6f, 0x72, 0x67, 0x67,
+0x61, 0x20, 0x6b, 0x72, 0x75, 0x76, 0x64, 0x6e, 0x6f, 0x3b, 0x6e, 0x6f, 0x72, 0x67, 0x67, 0x61, 0x20, 0x6b, 0x72, 0x75,
+0x76, 0x64, 0x6e, 0x6f, 0x3b, 0x3b, 0x3b, 0x6e, 0x6f, 0x72, 0x67, 0x67, 0x61, 0x20, 0x6b, 0x72, 0x75, 0x76, 0x64, 0x6e,
+0x6f, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x65, 0x75, 0x72, 0x6f, 0x3b, 0x3b, 0x3b,
+0x65, 0x75, 0x72, 0x6f, 0x3b, 0x53, 0x68, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x65, 0x6e,
+0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4d, 0x62, 0x75, 0x75, 0x257, 0x75, 0x20, 0x53, 0x65, 0x65, 0x66,
+0x61, 0x61, 0x20, 0x42, 0x43, 0x45, 0x41, 0x4f, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x43, 0x69, 0x72, 0x69, 0x6e,
+0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x6a,
+0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x65, 0x65, 0x6c, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x4d, 0x65, 0x74, 0x69, 0x63, 0x61, 0x6c, 0x20, 0x64, 0x65, 0x20, 0x4d, 0x6f, 0xe7, 0x61, 0x6d, 0x62,
+0x69, 0x71, 0x75, 0x65, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x44, 0x6f, 0x6c, 0x61, 0x20, 0x79, 0x61, 0x73, 0x65,
+0x20, 0x41, 0x6d, 0x65, 0x6c, 0x69, 0x6b, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x68, 0x65, 0x6c, 0x65, 0x72,
+0x69, 0x20, 0x73, 0x61, 0x20, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x2d30, 0x2d37, 0x2d54, 0x2d49, 0x2d4e, 0x20, 0x2d4f, 0x20, 0x2d4d, 0x2d4e, 0x2d56, 0x2d54, 0x2d49, 0x2d31, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x61, 0x64, 0x72, 0x69, 0x6d, 0x20, 0x6e, 0x20, 0x6c, 0x6d, 0x263, 0x72, 0x69, 0x62, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x41, 0x64, 0x69, 0x6e, 0x61, 0x72, 0x20, 0x41, 0x7a, 0x7a, 0x61, 0x79, 0x72, 0x69, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x45, 0x73, 0x68, 0x69, 0x72, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x55, 0x67, 0x61, 0x6e,
+0x64, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x68, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79, 0x61,
+0x20, 0x48, 0x75, 0x74, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x68,
+0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79, 0x61, 0x20, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x73, 0x65, 0x66, 0x61, 0x20, 0x46, 0x72, 0x61, 0x14b, 0x20, 0x28, 0x42, 0x43, 0x45, 0x41,
+0x4f, 0x29, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x13a4, 0x13c3, 0x13cd, 0x13d7, 0x3b, 0x3b, 0x13a4, 0x13c3, 0x13cd, 0x13d7, 0x3b,
+0x3b, 0x3b, 0x3b, 0x13e7, 0x13c3, 0x13cd, 0x13d7, 0x3b, 0x72, 0x6f, 0x75, 0x70, 0x69, 0x20, 0x6d, 0x6f, 0x72, 0x69, 0x73, 0x69,
+0x65, 0x6e, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x68, 0x69, 0x6c, 0xed, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x79,
+0x61, 0x20, 0x54, 0x61, 0x61, 0x6e, 0x73, 0x61, 0x6e, 0xed, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69,
+0x6c, 0x69, 0x6e, 0x67, 0x69, 0x20, 0x65, 0x79, 0x61, 0x20, 0x59, 0x75, 0x67, 0x61, 0x6e, 0x64, 0x61, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x6b, 0x75, 0x64, 0x75, 0x20, 0x4b, 0x61, 0x62, 0x75, 0x76, 0x65, 0x72, 0x64, 0x69, 0x61,
+0x6e, 0x75, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x69, 0x74, 0x61, 0x62, 0x20,
+0x79, 0x61, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x61, 0x6d, 0x69, 0x62,
+0x69, 0x61, 0x20, 0x44, 0x6f, 0x6c, 0x6c, 0x61, 0x72, 0x69, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x49, 0x72, 0x6f,
+0x70, 0x69, 0x79, 0x69, 0x61, 0x6e, 0xed, 0x20, 0x65, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x49, 0x72, 0x6f, 0x70, 0x69, 0x79, 0x69, 0x61, 0x6e, 0xed, 0x20, 0x65, 0x20, 0x54, 0x61, 0x6e, 0x7a, 0x61,
+0x6e, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53, 0x69, 0x72, 0x69, 0x6e, 0x6a, 0x69, 0x20, 0x79, 0x61,
+0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x73, 0x68, 0x69, 0x6c, 0x69, 0x6e, 0x67,
+0x69, 0x20, 0x79, 0x61, 0x20, 0x54, 0x61, 0x6e, 0x64, 0x68, 0x61, 0x6e, 0x69, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x41, 0x6e, 0x67, 0x6f, 0x27, 0x6f, 0x74, 0x6f, 0x6c, 0x20, 0x6c, 0x6f, 0x6b, 0x27, 0x20, 0x55, 0x67, 0x61, 0x6e,
+0x64, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x41, 0x6e, 0x67, 0x6f, 0x27, 0x6f, 0x74, 0x6f, 0x6c, 0x20, 0x6c,
+0x6f, 0x6b, 0x27, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x43, 0x46, 0x41, 0x20,
+0x46, 0x72, 0x61, 0x14b, 0x20, 0x28, 0x42, 0x43, 0x45, 0x41, 0x4f, 0x29, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x53,
+0x69, 0x6c, 0x69, 0x6e, 0x67, 0x20, 0x6d, 0x61, 0x72, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x44, 0x65, 0x72, 0x68, 0x65, 0x6d, 0x20, 0x55, 0x6d, 0x65, 0x1e5b, 0x1e5b, 0x75, 0x6b, 0x69, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x930, 0x93e, 0x902, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4e, 0x66, 0x61, 0x6c, 0x61, 0x6e,
+0x67, 0x61, 0x20, 0x77, 0x61, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x75, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x43, 0x46,
+0x41, 0x20, 0x46, 0xe0, 0x6c, 0xe2, 0x14b, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46,
+0x72, 0x1ce, 0x14b, 0x20, 0x43, 0x46, 0x41, 0x20, 0x28, 0x42, 0x45, 0x41, 0x43, 0x29, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x73, 0x65, 0x65, 0x66, 0x61, 0x20, 0x79, 0x61, 0x74, 0x69, 0x20, 0x42, 0x43, 0x45, 0x41, 0x4f, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x259, 0x6c, 0xe1, 0x14b, 0x20, 0x43, 0x46, 0x41, 0x20, 0x28, 0x42, 0x45, 0x41, 0x43, 0x29,
+0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x72, 0xe1, 0x14b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x73, 0x6f,
+0x6c, 0x61, 0x69, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x72, 0x61, 0x14b, 0x20,
+0x43, 0x46, 0x41, 0x20, 0x42, 0x45, 0x41, 0x43, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x49, 0x68, 0x65, 0x6c, 0x61,
+0x20, 0x79, 0x61, 0x20, 0x54, 0x61, 0x6e, 0x73, 0x61, 0x6e, 0x69, 0x79, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b,
+0x46, 0x61, 0x72, 0x61, 0x6e, 0x67, 0x61, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x6f, 0x3b, 0x3b, 0x3b, 0x3b,
+0x3b, 0x3b, 0x3b, 0xa55e, 0xa524, 0xa52b, 0xa569, 0x20, 0xa55c, 0xa55e, 0xa54c, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x4c, 0x61,
+0x69, 0x62, 0x68, 0x69, 0x79, 0x61, 0x20, 0x44, 0x61, 0x6c, 0x61, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x25b,
+0x6c, 0xe2, 0x14b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x46, 0x72, 0x61, 0x6e, 0x63, 0x20, 0x43, 0x46, 0x41, 0x3b,
+0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x73, 0x68, 0x69, 0x72, 0xe8, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x66, 0x65,
+0x6c, 0xe1, 0x14b, 0x20, 0x43, 0x46, 0x41, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b, 0x3b
};
static const ushort currency_format_data[] = {
@@ -4907,243 +5222,243 @@ static const ushort endonyms_data[] = {
0x633, 0x639, 0x648, 0x62f, 0x64a, 0x629, 0x627, 0x644, 0x635, 0x648, 0x645, 0x627, 0x644, 0x627, 0x644, 0x633, 0x648, 0x62f, 0x627, 0x646,
0x633, 0x648, 0x631, 0x64a, 0x627, 0x62a, 0x648, 0x646, 0x633, 0x627, 0x644, 0x625, 0x645, 0x627, 0x631, 0x627, 0x62a, 0x20, 0x627, 0x644,
0x639, 0x631, 0x628, 0x64a, 0x629, 0x20, 0x627, 0x644, 0x645, 0x62a, 0x62d, 0x62f, 0x629, 0x627, 0x644, 0x635, 0x62d, 0x631, 0x627, 0x621,
-0x20, 0x627, 0x644, 0x63a, 0x631, 0x628, 0x64a, 0x629, 0x627, 0x644, 0x64a, 0x645, 0x646, 0x540, 0x561, 0x575, 0x565, 0x580, 0x567, 0x576,
-0x540, 0x561, 0x575, 0x561, 0x57d, 0x57f, 0x561, 0x576, 0x56b, 0x20, 0x540, 0x561, 0x576, 0x580, 0x561, 0x57a, 0x565, 0x57f, 0x578, 0x582,
-0x569, 0x575, 0x578, 0x582, 0x576, 0x985, 0x9b8, 0x9ae, 0x9c0, 0x9af, 0x9bc, 0x9be, 0x9ad, 0x9be, 0x9f0, 0x9a4, 0x61, 0x7a, 0x259, 0x72,
-0x62, 0x61, 0x79, 0x63, 0x61, 0x6e, 0x63, 0x61, 0x41, 0x7a, 0x259, 0x72, 0x62, 0x61, 0x79, 0x63, 0x61, 0x6e, 0x410, 0x437,
-0x4d9, 0x440, 0x431, 0x430, 0x458, 0x4b9, 0x430, 0x43d, 0x65, 0x75, 0x73, 0x6b, 0x61, 0x72, 0x61, 0x45, 0x73, 0x70, 0x61, 0x69,
-0x6e, 0x69, 0x61, 0x9ac, 0x9be, 0x982, 0x9b2, 0x9be, 0x9ac, 0x9be, 0x982, 0x9b2, 0x9be, 0x9a6, 0x9c7, 0x9b6, 0x9ad, 0x9be, 0x9b0, 0x9a4,
-0xf62, 0xfab, 0xf7c, 0xf44, 0xf0b, 0xf41, 0xf60, 0xf56, 0xfb2, 0xf74, 0xf42, 0x62, 0x72, 0x65, 0x7a, 0x68, 0x6f, 0x6e, 0x65, 0x67,
-0x46, 0x72, 0x61, 0xf1, 0x73, 0x431, 0x44a, 0x43b, 0x433, 0x430, 0x440, 0x441, 0x43a, 0x438, 0x411, 0x44a, 0x43b, 0x433, 0x430, 0x440,
-0x438, 0x44f, 0x1017, 0x1019, 0x102c, 0x1019, 0x103c, 0x1014, 0x103a, 0x1019, 0x102c, 0x431, 0x435, 0x43b, 0x430, 0x440, 0x443, 0x441, 0x43a, 0x430,
-0x44f, 0x411, 0x435, 0x43b, 0x430, 0x440, 0x443, 0x441, 0x44c, 0x1781, 0x17d2, 0x1798, 0x17c2, 0x179a, 0x1780, 0x1798, 0x17d2, 0x1796, 0x17bb, 0x1787,
-0x17b6, 0x63, 0x61, 0x74, 0x61, 0x6c, 0xe0, 0x45, 0x73, 0x70, 0x61, 0x6e, 0x79, 0x61, 0x41, 0x6e, 0x64, 0x6f, 0x72, 0x72,
-0x61, 0x7b80, 0x4f53, 0x4e2d, 0x6587, 0x4e2d, 0x56fd, 0x4e2d, 0x56fd, 0x9999, 0x6e2f, 0x7279, 0x522b, 0x884c, 0x653f, 0x533a, 0x4e2d, 0x56fd, 0x6fb3, 0x95e8,
-0x7279, 0x522b, 0x884c, 0x653f, 0x533a, 0x65b0, 0x52a0, 0x5761, 0x7e41, 0x9ad4, 0x4e2d, 0x6587, 0x4e2d, 0x83ef, 0x4eba, 0x6c11, 0x5171, 0x548c, 0x570b, 0x9999,
-0x6e2f, 0x7279, 0x5225, 0x884c, 0x653f, 0x5340, 0x4e2d, 0x83ef, 0x4eba, 0x6c11, 0x5171, 0x548c, 0x570b, 0x6fb3, 0x9580, 0x7279, 0x5225, 0x884c, 0x653f, 0x5340,
-0x53f0, 0x7063, 0x68, 0x72, 0x76, 0x61, 0x74, 0x73, 0x6b, 0x69, 0x48, 0x72, 0x76, 0x61, 0x74, 0x73, 0x6b, 0x61, 0x42, 0x6f,
-0x73, 0x6e, 0x61, 0x20, 0x69, 0x20, 0x48, 0x65, 0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x69, 0x6e, 0x61, 0x10d, 0x65, 0x161,
-0x74, 0x69, 0x6e, 0x61, 0x10c, 0x65, 0x73, 0x6b, 0xe1, 0x20, 0x72, 0x65, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x6b, 0x61, 0x64,
-0x61, 0x6e, 0x73, 0x6b, 0x44, 0x61, 0x6e, 0x6d, 0x61, 0x72, 0x6b, 0x4e, 0x65, 0x64, 0x65, 0x72, 0x6c, 0x61, 0x6e, 0x64,
-0x73, 0x4e, 0x65, 0x64, 0x65, 0x72, 0x6c, 0x61, 0x6e, 0x64, 0x41, 0x72, 0x75, 0x62, 0x61, 0x56, 0x6c, 0x61, 0x61, 0x6d,
-0x73, 0x42, 0x65, 0x6c, 0x67, 0x69, 0xeb, 0x43, 0x75, 0x72, 0x61, 0xe7, 0x61, 0x6f, 0x53, 0x75, 0x72, 0x69, 0x6e, 0x61,
-0x6d, 0x65, 0x53, 0x69, 0x6e, 0x74, 0x2d, 0x4d, 0x61, 0x61, 0x72, 0x74, 0x65, 0x6e, 0x55, 0x2e, 0x53, 0x2e, 0x20, 0x45,
-0x6e, 0x67, 0x6c, 0x69, 0x73, 0x68, 0x55, 0x6e, 0x69, 0x74, 0x65, 0x64, 0x20, 0x53, 0x74, 0x61, 0x74, 0x65, 0x73, 0xd801,
-0xdc00, 0xd801, 0xdc4d, 0xd801, 0xdc4a, 0xd801, 0xdc2e, 0xd801, 0xdc47, 0xd801, 0xdc0f, 0xd801, 0xdc2d, 0xd801, 0xdc4c, 0xd801, 0xdc34, 0xd801, 0xdc3b, 0xd801,
-0xdc32, 0xd801, 0xdc3c, 0x20, 0xd801, 0xdc1d, 0xd801, 0xdc3b, 0xd801, 0xdc29, 0xd801, 0xdc3b, 0xd801, 0xdc45, 0x45, 0x6e, 0x67, 0x6c, 0x69, 0x73,
-0x68, 0x41, 0x6d, 0x65, 0x72, 0x69, 0x63, 0x61, 0x6e, 0x20, 0x53, 0x61, 0x6d, 0x6f, 0x61, 0x41, 0x6e, 0x74, 0x69, 0x67,
-0x75, 0x61, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x42, 0x61, 0x72, 0x62, 0x75, 0x64, 0x61, 0x41, 0x75, 0x73, 0x74, 0x72, 0x61,
-0x6c, 0x69, 0x61, 0x6e, 0x20, 0x45, 0x6e, 0x67, 0x6c, 0x69, 0x73, 0x68, 0x41, 0x75, 0x73, 0x74, 0x72, 0x61, 0x6c, 0x69,
-0x61, 0x42, 0x61, 0x68, 0x61, 0x6d, 0x61, 0x73, 0x42, 0x61, 0x72, 0x62, 0x61, 0x64, 0x6f, 0x73, 0x42, 0x65, 0x6c, 0x67,
-0x69, 0x75, 0x6d, 0x42, 0x65, 0x6c, 0x69, 0x7a, 0x65, 0x42, 0x65, 0x72, 0x6d, 0x75, 0x64, 0x61, 0x42, 0x6f, 0x74, 0x73,
-0x77, 0x61, 0x6e, 0x61, 0x43, 0x61, 0x6d, 0x65, 0x72, 0x6f, 0x6f, 0x6e, 0x43, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x61, 0x6e,
-0x20, 0x45, 0x6e, 0x67, 0x6c, 0x69, 0x73, 0x68, 0x43, 0x61, 0x6e, 0x61, 0x64, 0x61, 0x43, 0x61, 0x79, 0x6d, 0x61, 0x6e,
-0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x44, 0x6f, 0x6d, 0x69, 0x6e, 0x69, 0x63, 0x61, 0x46, 0x69, 0x6a, 0x69,
-0x47, 0x75, 0x65, 0x72, 0x6e, 0x73, 0x65, 0x79, 0x47, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x47, 0x68, 0x61, 0x6e, 0x61, 0x47,
-0x69, 0x62, 0x72, 0x61, 0x6c, 0x74, 0x61, 0x72, 0x47, 0x72, 0x65, 0x6e, 0x61, 0x64, 0x61, 0x47, 0x75, 0x61, 0x6d, 0x47,
-0x75, 0x79, 0x61, 0x6e, 0x61, 0x48, 0x6f, 0x6e, 0x67, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x20, 0x53, 0x41, 0x52, 0x20, 0x43,
-0x68, 0x69, 0x6e, 0x61, 0x49, 0x6e, 0x64, 0x69, 0x61, 0x49, 0x72, 0x65, 0x6c, 0x61, 0x6e, 0x64, 0x4a, 0x61, 0x6d, 0x61,
-0x69, 0x63, 0x61, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x4b, 0x69, 0x72, 0x69, 0x62, 0x61, 0x74, 0x69, 0x4c, 0x65, 0x73, 0x6f,
-0x74, 0x68, 0x6f, 0x4c, 0x69, 0x62, 0x65, 0x72, 0x69, 0x61, 0x4d, 0x61, 0x64, 0x61, 0x67, 0x61, 0x73, 0x63, 0x61, 0x72,
-0x4d, 0x61, 0x6c, 0x61, 0x77, 0x69, 0x4d, 0x61, 0x6c, 0x74, 0x61, 0x4d, 0x61, 0x72, 0x73, 0x68, 0x61, 0x6c, 0x6c, 0x20,
-0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x4d, 0x61, 0x75, 0x72, 0x69, 0x74, 0x69, 0x75, 0x73, 0x4d, 0x69, 0x63, 0x72,
-0x6f, 0x6e, 0x65, 0x73, 0x69, 0x61, 0x4e, 0x61, 0x6d, 0x69, 0x62, 0x69, 0x61, 0x4e, 0x65, 0x77, 0x20, 0x5a, 0x65, 0x61,
-0x6c, 0x61, 0x6e, 0x64, 0x4e, 0x69, 0x67, 0x65, 0x72, 0x69, 0x61, 0x4e, 0x6f, 0x72, 0x74, 0x68, 0x65, 0x72, 0x6e, 0x20,
-0x4d, 0x61, 0x72, 0x69, 0x61, 0x6e, 0x61, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x50, 0x61, 0x6b, 0x69, 0x73,
-0x74, 0x61, 0x6e, 0x50, 0x61, 0x6c, 0x61, 0x75, 0x50, 0x61, 0x70, 0x75, 0x61, 0x20, 0x4e, 0x65, 0x77, 0x20, 0x47, 0x75,
-0x69, 0x6e, 0x65, 0x61, 0x50, 0x68, 0x69, 0x6c, 0x69, 0x70, 0x70, 0x69, 0x6e, 0x65, 0x73, 0x50, 0x75, 0x65, 0x72, 0x74,
-0x6f, 0x20, 0x52, 0x69, 0x63, 0x6f, 0x53, 0x61, 0x69, 0x6e, 0x74, 0x20, 0x4b, 0x69, 0x74, 0x74, 0x73, 0x20, 0x61, 0x6e,
-0x64, 0x20, 0x4e, 0x65, 0x76, 0x69, 0x73, 0x53, 0x61, 0x69, 0x6e, 0x74, 0x20, 0x4c, 0x75, 0x63, 0x69, 0x61, 0x53, 0x61,
-0x69, 0x6e, 0x74, 0x20, 0x56, 0x69, 0x6e, 0x63, 0x65, 0x6e, 0x74, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x74, 0x68, 0x65, 0x20,
-0x47, 0x72, 0x65, 0x6e, 0x61, 0x64, 0x69, 0x6e, 0x65, 0x73, 0x53, 0x61, 0x6d, 0x6f, 0x61, 0x53, 0x65, 0x79, 0x63, 0x68,
-0x65, 0x6c, 0x6c, 0x65, 0x73, 0x53, 0x69, 0x65, 0x72, 0x72, 0x61, 0x20, 0x4c, 0x65, 0x6f, 0x6e, 0x65, 0x53, 0x69, 0x6e,
-0x67, 0x61, 0x70, 0x6f, 0x72, 0x65, 0x53, 0x6f, 0x6c, 0x6f, 0x6d, 0x6f, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64,
-0x73, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x41, 0x66, 0x72, 0x69, 0x63, 0x61, 0x53, 0x77, 0x61, 0x7a, 0x69, 0x6c, 0x61,
-0x6e, 0x64, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x54, 0x6f, 0x6e, 0x67, 0x61, 0x54, 0x72, 0x69, 0x6e, 0x69,
-0x64, 0x61, 0x64, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x54, 0x6f, 0x62, 0x61, 0x67, 0x6f, 0x54, 0x75, 0x72, 0x6b, 0x73, 0x20,
-0x61, 0x6e, 0x64, 0x20, 0x43, 0x61, 0x69, 0x63, 0x6f, 0x73, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x55, 0x67,
-0x61, 0x6e, 0x64, 0x61, 0x42, 0x72, 0x69, 0x74, 0x69, 0x73, 0x68, 0x20, 0x45, 0x6e, 0x67, 0x6c, 0x69, 0x73, 0x68, 0x55,
-0x6e, 0x69, 0x74, 0x65, 0x64, 0x20, 0x4b, 0x69, 0x6e, 0x67, 0x64, 0x6f, 0x6d, 0x55, 0x2e, 0x53, 0x2e, 0x20, 0x4f, 0x75,
-0x74, 0x6c, 0x79, 0x69, 0x6e, 0x67, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x56, 0x61, 0x6e, 0x75, 0x61, 0x74,
-0x75, 0x42, 0x72, 0x69, 0x74, 0x69, 0x73, 0x68, 0x20, 0x56, 0x69, 0x72, 0x67, 0x69, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61,
-0x6e, 0x64, 0x73, 0x55, 0x2e, 0x53, 0x2e, 0x20, 0x56, 0x69, 0x72, 0x67, 0x69, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e,
-0x64, 0x73, 0x5a, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x5a, 0x69, 0x6d, 0x62, 0x61, 0x62, 0x77, 0x65, 0x49, 0x73, 0x6c, 0x65,
-0x20, 0x6f, 0x66, 0x20, 0x4d, 0x61, 0x6e, 0x4a, 0x65, 0x72, 0x73, 0x65, 0x79, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x53,
-0x75, 0x64, 0x61, 0x6e, 0x65, 0x65, 0x73, 0x74, 0x69, 0x45, 0x65, 0x73, 0x74, 0x69, 0x66, 0xf8, 0x72, 0x6f, 0x79, 0x73,
-0x6b, 0x74, 0x46, 0xf8, 0x72, 0x6f, 0x79, 0x61, 0x72, 0x73, 0x75, 0x6f, 0x6d, 0x69, 0x53, 0x75, 0x6f, 0x6d, 0x69, 0x66,
-0x72, 0x61, 0x6e, 0xe7, 0x61, 0x69, 0x73, 0x46, 0x72, 0x61, 0x6e, 0x63, 0x65, 0x41, 0x6c, 0x67, 0xe9, 0x72, 0x69, 0x65,
-0x42, 0x65, 0x6c, 0x67, 0x69, 0x71, 0x75, 0x65, 0x42, 0xe9, 0x6e, 0x69, 0x6e, 0x42, 0x75, 0x72, 0x6b, 0x69, 0x6e, 0x61,
-0x20, 0x46, 0x61, 0x73, 0x6f, 0x42, 0x75, 0x72, 0x75, 0x6e, 0x64, 0x69, 0x43, 0x61, 0x6d, 0x65, 0x72, 0x6f, 0x75, 0x6e,
-0x66, 0x72, 0x61, 0x6e, 0xe7, 0x61, 0x69, 0x73, 0x20, 0x63, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x65, 0x6e, 0x52, 0xe9, 0x70,
-0x75, 0x62, 0x6c, 0x69, 0x71, 0x75, 0x65, 0x20, 0x63, 0x65, 0x6e, 0x74, 0x72, 0x61, 0x66, 0x72, 0x69, 0x63, 0x61, 0x69,
-0x6e, 0x65, 0x54, 0x63, 0x68, 0x61, 0x64, 0x43, 0x6f, 0x6d, 0x6f, 0x72, 0x65, 0x73, 0x52, 0xe9, 0x70, 0x75, 0x62, 0x6c,
-0x69, 0x71, 0x75, 0x65, 0x20, 0x64, 0xe9, 0x6d, 0x6f, 0x63, 0x72, 0x61, 0x74, 0x69, 0x71, 0x75, 0x65, 0x20, 0x64, 0x75,
-0x20, 0x43, 0x6f, 0x6e, 0x67, 0x6f, 0x43, 0x6f, 0x6e, 0x67, 0x6f, 0x2d, 0x42, 0x72, 0x61, 0x7a, 0x7a, 0x61, 0x76, 0x69,
-0x6c, 0x6c, 0x65, 0x43, 0xf4, 0x74, 0x65, 0x20, 0x64, 0x2019, 0x49, 0x76, 0x6f, 0x69, 0x72, 0x65, 0x44, 0x6a, 0x69, 0x62,
-0x6f, 0x75, 0x74, 0x69, 0x47, 0x75, 0x69, 0x6e, 0xe9, 0x65, 0x20, 0xe9, 0x71, 0x75, 0x61, 0x74, 0x6f, 0x72, 0x69, 0x61,
-0x6c, 0x65, 0x47, 0x75, 0x79, 0x61, 0x6e, 0x65, 0x20, 0x66, 0x72, 0x61, 0x6e, 0xe7, 0x61, 0x69, 0x73, 0x65, 0x50, 0x6f,
-0x6c, 0x79, 0x6e, 0xe9, 0x73, 0x69, 0x65, 0x20, 0x66, 0x72, 0x61, 0x6e, 0xe7, 0x61, 0x69, 0x73, 0x65, 0x47, 0x61, 0x62,
-0x6f, 0x6e, 0x47, 0x75, 0x61, 0x64, 0x65, 0x6c, 0x6f, 0x75, 0x70, 0x65, 0x47, 0x75, 0x69, 0x6e, 0xe9, 0x65, 0x48, 0x61,
-0xef, 0x74, 0x69, 0x4c, 0x75, 0x78, 0x65, 0x6d, 0x62, 0x6f, 0x75, 0x72, 0x67, 0x4d, 0x61, 0x6c, 0x69, 0x4d, 0x61, 0x72,
-0x74, 0x69, 0x6e, 0x69, 0x71, 0x75, 0x65, 0x4d, 0x61, 0x75, 0x72, 0x69, 0x74, 0x61, 0x6e, 0x69, 0x65, 0x4d, 0x61, 0x75,
-0x72, 0x69, 0x63, 0x65, 0x4d, 0x61, 0x79, 0x6f, 0x74, 0x74, 0x65, 0x4d, 0x6f, 0x6e, 0x61, 0x63, 0x6f, 0x4d, 0x61, 0x72,
-0x6f, 0x63, 0x4e, 0x6f, 0x75, 0x76, 0x65, 0x6c, 0x6c, 0x65, 0x2d, 0x43, 0x61, 0x6c, 0xe9, 0x64, 0x6f, 0x6e, 0x69, 0x65,
-0x4e, 0x69, 0x67, 0x65, 0x72, 0x52, 0xe9, 0x75, 0x6e, 0x69, 0x6f, 0x6e, 0x52, 0x77, 0x61, 0x6e, 0x64, 0x61, 0x53, 0xe9,
-0x6e, 0xe9, 0x67, 0x61, 0x6c, 0x66, 0x72, 0x61, 0x6e, 0xe7, 0x61, 0x69, 0x73, 0x20, 0x73, 0x75, 0x69, 0x73, 0x73, 0x65,
-0x53, 0x75, 0x69, 0x73, 0x73, 0x65, 0x53, 0x79, 0x72, 0x69, 0x65, 0x54, 0x6f, 0x67, 0x6f, 0x54, 0x75, 0x6e, 0x69, 0x73,
-0x69, 0x65, 0x53, 0x61, 0x69, 0x6e, 0x74, 0x2d, 0x42, 0x61, 0x72, 0x74, 0x68, 0xe9, 0x6c, 0xe9, 0x6d, 0x79, 0x53, 0x61,
-0x69, 0x6e, 0x74, 0x2d, 0x4d, 0x61, 0x72, 0x74, 0x69, 0x6e, 0x20, 0x5b, 0x70, 0x61, 0x72, 0x74, 0x69, 0x65, 0x20, 0x66,
-0x72, 0x61, 0x6e, 0xe7, 0x61, 0x69, 0x73, 0x65, 0x5d, 0x47, 0xe0, 0x69, 0x64, 0x68, 0x6c, 0x69, 0x67, 0x41, 0x6e, 0x20,
-0x52, 0xec, 0x6f, 0x67, 0x68, 0x61, 0x63, 0x68, 0x64, 0x20, 0x41, 0x6f, 0x6e, 0x61, 0x69, 0x63, 0x68, 0x74, 0x65, 0x67,
-0x61, 0x6c, 0x65, 0x67, 0x6f, 0x45, 0x73, 0x70, 0x61, 0xf1, 0x61, 0x10e5, 0x10d0, 0x10e0, 0x10d7, 0x10e3, 0x10da, 0x10d8, 0x10e1, 0x10d0,
-0x10e5, 0x10d0, 0x10e0, 0x10d7, 0x10d5, 0x10d4, 0x10da, 0x10dd, 0x44, 0x65, 0x75, 0x74, 0x73, 0x63, 0x68, 0x44, 0x65, 0x75, 0x74, 0x73,
-0x63, 0x68, 0x6c, 0x61, 0x6e, 0x64, 0xd6, 0x73, 0x74, 0x65, 0x72, 0x72, 0x65, 0x69, 0x63, 0x68, 0x69, 0x73, 0x63, 0x68,
-0x65, 0x73, 0x20, 0x44, 0x65, 0x75, 0x74, 0x73, 0x63, 0x68, 0xd6, 0x73, 0x74, 0x65, 0x72, 0x72, 0x65, 0x69, 0x63, 0x68,
-0x42, 0x65, 0x6c, 0x67, 0x69, 0x65, 0x6e, 0x4c, 0x69, 0x65, 0x63, 0x68, 0x74, 0x65, 0x6e, 0x73, 0x74, 0x65, 0x69, 0x6e,
-0x4c, 0x75, 0x78, 0x65, 0x6d, 0x62, 0x75, 0x72, 0x67, 0x53, 0x63, 0x68, 0x77, 0x65, 0x69, 0x7a, 0x65, 0x72, 0x20, 0x48,
-0x6f, 0x63, 0x68, 0x64, 0x65, 0x75, 0x74, 0x73, 0x63, 0x68, 0x53, 0x63, 0x68, 0x77, 0x65, 0x69, 0x7a, 0x395, 0x3bb, 0x3bb,
-0x3b7, 0x3bd, 0x3b9, 0x3ba, 0x3ac, 0x395, 0x3bb, 0x3bb, 0x3ac, 0x3b4, 0x3b1, 0x39a, 0x3cd, 0x3c0, 0x3c1, 0x3bf, 0x3c2, 0x6b, 0x61, 0x6c,
-0x61, 0x61, 0x6c, 0x6c, 0x69, 0x73, 0x75, 0x74, 0x4b, 0x61, 0x6c, 0x61, 0x61, 0x6c, 0x6c, 0x69, 0x74, 0x20, 0x4e, 0x75,
-0x6e, 0x61, 0x61, 0x74, 0xa97, 0xac1, 0xa9c, 0xab0, 0xabe, 0xaa4, 0xac0, 0xaad, 0xabe, 0xab0, 0xaa4, 0x48, 0x61, 0x75, 0x73, 0x61,
-0x4e, 0x61, 0x6a, 0x65, 0x72, 0x69, 0x79, 0x61, 0x47, 0x61, 0x6e, 0x61, 0x4e, 0x69, 0x6a, 0x61, 0x72, 0x5e2, 0x5d1, 0x5e8,
-0x5d9, 0x5ea, 0x5d9, 0x5e9, 0x5e8, 0x5d0, 0x5dc, 0x939, 0x93f, 0x928, 0x94d, 0x926, 0x940, 0x92d, 0x93e, 0x930, 0x924, 0x6d, 0x61, 0x67,
-0x79, 0x61, 0x72, 0x4d, 0x61, 0x67, 0x79, 0x61, 0x72, 0x6f, 0x72, 0x73, 0x7a, 0xe1, 0x67, 0xed, 0x73, 0x6c, 0x65, 0x6e,
-0x73, 0x6b, 0x61, 0xcd, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x42, 0x61, 0x68, 0x61, 0x73, 0x61, 0x20, 0x49, 0x6e, 0x64, 0x6f,
-0x6e, 0x65, 0x73, 0x69, 0x61, 0x49, 0x6e, 0x64, 0x6f, 0x6e, 0x65, 0x73, 0x69, 0x61, 0x47, 0x61, 0x65, 0x69, 0x6c, 0x67,
-0x65, 0xc9, 0x69, 0x72, 0x65, 0x69, 0x74, 0x61, 0x6c, 0x69, 0x61, 0x6e, 0x6f, 0x49, 0x74, 0x61, 0x6c, 0x69, 0x61, 0x53,
-0x61, 0x6e, 0x20, 0x4d, 0x61, 0x72, 0x69, 0x6e, 0x6f, 0x53, 0x76, 0x69, 0x7a, 0x7a, 0x65, 0x72, 0x61, 0x65e5, 0x672c, 0x8a9e,
-0x65e5, 0x672c, 0xc95, 0xca8, 0xccd, 0xca8, 0xca1, 0xcad, 0xcbe, 0xcb0, 0xca4, 0x6a9, 0x672, 0x634, 0x64f, 0x631, 0x6c1, 0x650, 0x646, 0x65b,
-0x62f, 0x648, 0x633, 0x62a, 0x627, 0x646, 0x49b, 0x430, 0x437, 0x430, 0x49b, 0x20, 0x442, 0x456, 0x43b, 0x456, 0x49a, 0x430, 0x437, 0x430,
-0x49b, 0x441, 0x442, 0x430, 0x43d, 0x4b, 0x69, 0x6e, 0x79, 0x61, 0x72, 0x77, 0x61, 0x6e, 0x64, 0x61, 0x41a, 0x44b, 0x440, 0x433,
-0x44b, 0x437, 0x41a, 0x44b, 0x440, 0x433, 0x44b, 0x437, 0x441, 0x442, 0x430, 0x43d, 0xd55c, 0xad6d, 0xc5b4, 0xb300, 0xd55c, 0xbbfc, 0xad6d, 0xc870,
-0xc120, 0x20, 0xbbfc, 0xc8fc, 0xc8fc, 0xc758, 0x20, 0xc778, 0xbbfc, 0x20, 0xacf5, 0xd654, 0xad6d, 0x49, 0x6b, 0x69, 0x72, 0x75, 0x6e, 0x64,
-0x69, 0x55, 0x62, 0x75, 0x72, 0x75, 0x6e, 0x64, 0x69, 0xea5, 0xeb2, 0xea7, 0xeaa, 0x2e, 0xe9b, 0x2e, 0xe9b, 0x20, 0xea5, 0xeb2,
-0xea7, 0x6c, 0x61, 0x74, 0x76, 0x69, 0x65, 0x161, 0x75, 0x4c, 0x61, 0x74, 0x76, 0x69, 0x6a, 0x61, 0x6c, 0x69, 0x6e, 0x67,
-0xe1, 0x6c, 0x61, 0x52, 0x65, 0x70, 0x69, 0x62, 0x69, 0x6b, 0x69, 0x20, 0x64, 0x65, 0x6d, 0x6f, 0x6b, 0x72, 0x61, 0x74,
-0x69, 0x6b, 0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0xf3, 0x41, 0x6e, 0x67, 0xf3, 0x6c, 0x61, 0x52, 0x65,
-0x70, 0x69, 0x62, 0x69, 0x6b, 0x69, 0x20, 0x79, 0x61, 0x20, 0x41, 0x66, 0x72, 0xed, 0x6b, 0x61, 0x20, 0x79, 0x61, 0x20,
-0x4b, 0xe1, 0x74, 0x69, 0x4b, 0x6f, 0x6e, 0x67, 0x6f, 0x6c, 0x69, 0x65, 0x74, 0x75, 0x76, 0x69, 0x173, 0x4c, 0x69, 0x65,
-0x74, 0x75, 0x76, 0x61, 0x43c, 0x430, 0x43a, 0x435, 0x434, 0x43e, 0x43d, 0x441, 0x43a, 0x438, 0x41c, 0x430, 0x43a, 0x435, 0x434, 0x43e,
-0x43d, 0x438, 0x458, 0x430, 0x4d, 0x61, 0x6c, 0x61, 0x67, 0x61, 0x73, 0x79, 0x4d, 0x61, 0x64, 0x61, 0x67, 0x61, 0x73, 0x69,
-0x6b, 0x61, 0x72, 0x61, 0x42, 0x61, 0x68, 0x61, 0x73, 0x61, 0x20, 0x4d, 0x65, 0x6c, 0x61, 0x79, 0x75, 0x4d, 0x61, 0x6c,
-0x61, 0x79, 0x73, 0x69, 0x61, 0x42, 0x72, 0x75, 0x6e, 0x65, 0x69, 0x53, 0x69, 0x6e, 0x67, 0x61, 0x70, 0x75, 0x72, 0x61,
-0xd2e, 0xd32, 0xd2f, 0xd3e, 0xd33, 0xd02, 0xd07, 0xd28, 0xd4d, 0xd24, 0xd4d, 0xd2f, 0x4d, 0x61, 0x6c, 0x74, 0x69, 0x92e, 0x930, 0x93e,
-0x920, 0x940, 0x928, 0x947, 0x92a, 0x93e, 0x932, 0x940, 0x928, 0x947, 0x92a, 0x93e, 0x932, 0x6e, 0x6f, 0x72, 0x73, 0x6b, 0x20, 0x62,
-0x6f, 0x6b, 0x6d, 0xe5, 0x6c, 0x4e, 0x6f, 0x72, 0x67, 0x65, 0xb13, 0xb21, 0xb3c, 0xb3f, 0xb06, 0xb2d, 0xb3e, 0xb30, 0xb24, 0x67e,
-0x69a, 0x62a, 0x648, 0x627, 0x641, 0x63a, 0x627, 0x646, 0x633, 0x62a, 0x627, 0x646, 0x641, 0x627, 0x631, 0x633, 0x6cc, 0x627, 0x6cc, 0x631,
-0x627, 0x646, 0x62f, 0x631, 0x6cc, 0x70, 0x6f, 0x6c, 0x73, 0x6b, 0x69, 0x50, 0x6f, 0x6c, 0x73, 0x6b, 0x61, 0x70, 0x6f, 0x72,
-0x74, 0x75, 0x67, 0x75, 0xea, 0x73, 0x20, 0x64, 0x6f, 0x20, 0x42, 0x72, 0x61, 0x73, 0x69, 0x6c, 0x42, 0x72, 0x61, 0x73,
-0x69, 0x6c, 0x70, 0x6f, 0x72, 0x74, 0x75, 0x67, 0x75, 0xea, 0x73, 0x41, 0x6e, 0x67, 0x6f, 0x6c, 0x61, 0x43, 0x61, 0x62,
-0x6f, 0x20, 0x56, 0x65, 0x72, 0x64, 0x65, 0x54, 0x69, 0x6d, 0x6f, 0x72, 0x2d, 0x4c, 0x65, 0x73, 0x74, 0x65, 0x47, 0x75,
-0x69, 0x6e, 0xe9, 0x2d, 0x42, 0x69, 0x73, 0x73, 0x61, 0x75, 0x52, 0x65, 0x67, 0x69, 0xe3, 0x6f, 0x20, 0x41, 0x64, 0x6d,
-0x69, 0x6e, 0x69, 0x73, 0x74, 0x72, 0x61, 0x74, 0x69, 0x76, 0x61, 0x20, 0x45, 0x73, 0x70, 0x65, 0x63, 0x69, 0x61, 0x6c,
-0x20, 0x64, 0x65, 0x20, 0x4d, 0x61, 0x63, 0x61, 0x75, 0x4d, 0x6f, 0xe7, 0x61, 0x6d, 0x62, 0x69, 0x71, 0x75, 0x65, 0x70,
-0x6f, 0x72, 0x74, 0x75, 0x67, 0x75, 0xea, 0x73, 0x20, 0x65, 0x75, 0x72, 0x6f, 0x70, 0x65, 0x75, 0x50, 0x6f, 0x72, 0x74,
-0x75, 0x67, 0x61, 0x6c, 0x53, 0xe3, 0x6f, 0x20, 0x54, 0x6f, 0x6d, 0xe9, 0x20, 0x65, 0x20, 0x50, 0x72, 0xed, 0x6e, 0x63,
-0x69, 0x70, 0x65, 0xa2a, 0xa70, 0xa1c, 0xa3e, 0xa2c, 0xa40, 0xa2d, 0xa3e, 0xa30, 0xa24, 0x67e, 0x646, 0x62c, 0x627, 0x628, 0x67e, 0x6a9,
-0x633, 0x62a, 0x627, 0x646, 0x72, 0x75, 0x6d, 0x61, 0x6e, 0x74, 0x73, 0x63, 0x68, 0x53, 0x76, 0x69, 0x7a, 0x72, 0x61, 0x72,
-0x6f, 0x6d, 0xe2, 0x6e, 0x103, 0x52, 0x6f, 0x6d, 0xe2, 0x6e, 0x69, 0x61, 0x52, 0x65, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63,
-0x61, 0x20, 0x4d, 0x6f, 0x6c, 0x64, 0x6f, 0x76, 0x61, 0x440, 0x443, 0x441, 0x441, 0x43a, 0x438, 0x439, 0x420, 0x43e, 0x441, 0x441,
-0x438, 0x44f, 0x41a, 0x430, 0x437, 0x430, 0x445, 0x441, 0x442, 0x430, 0x43d, 0x41a, 0x438, 0x440, 0x433, 0x438, 0x437, 0x438, 0x44f, 0x41c,
-0x43e, 0x43b, 0x434, 0x43e, 0x432, 0x430, 0x423, 0x43a, 0x440, 0x430, 0x438, 0x43d, 0x430, 0x53, 0xe4, 0x6e, 0x67, 0xf6, 0x4b, 0xf6,
-0x64, 0xf6, 0x72, 0xf6, 0x73, 0xea, 0x73, 0x65, 0x20, 0x74, 0xee, 0x20, 0x42, 0xea, 0x61, 0x66, 0x72, 0xee, 0x6b, 0x61,
-0x421, 0x440, 0x43f, 0x441, 0x43a, 0x438, 0x421, 0x440, 0x431, 0x438, 0x458, 0x430, 0x441, 0x440, 0x43f, 0x441, 0x43a, 0x438, 0x411, 0x43e,
-0x441, 0x43d, 0x430, 0x20, 0x438, 0x20, 0x425, 0x435, 0x440, 0x446, 0x435, 0x433, 0x43e, 0x432, 0x438, 0x43d, 0x430, 0x426, 0x440, 0x43d,
-0x430, 0x20, 0x413, 0x43e, 0x440, 0x430, 0x53, 0x72, 0x70, 0x73, 0x6b, 0x69, 0x43, 0x72, 0x6e, 0x61, 0x20, 0x47, 0x6f, 0x72,
-0x61, 0x53, 0x72, 0x62, 0x69, 0x6a, 0x61, 0x438, 0x440, 0x43e, 0x43d, 0x413, 0x443, 0x44b, 0x440, 0x434, 0x437, 0x44b, 0x441, 0x442,
-0x43e, 0x43d, 0x423, 0x4d5, 0x440, 0x4d5, 0x441, 0x435, 0x53, 0x65, 0x73, 0x6f, 0x74, 0x68, 0x6f, 0x53, 0x65, 0x74, 0x73, 0x77,
-0x61, 0x6e, 0x61, 0x63, 0x68, 0x69, 0x53, 0x68, 0x6f, 0x6e, 0x61, 0xdc3, 0xdd2, 0xd82, 0xdc4, 0xdbd, 0xdc1, 0xdca, 0x200d, 0xdbb,
-0xdd3, 0x20, 0xdbd, 0xd82, 0xd9a, 0xdcf, 0xdc0, 0x53, 0x69, 0x73, 0x77, 0x61, 0x74, 0x69, 0x73, 0x6c, 0x6f, 0x76, 0x65, 0x6e,
-0x10d, 0x69, 0x6e, 0x61, 0x53, 0x6c, 0x6f, 0x76, 0x65, 0x6e, 0x73, 0x6b, 0x6f, 0x73, 0x6c, 0x6f, 0x76, 0x65, 0x6e, 0x161,
-0x10d, 0x69, 0x6e, 0x61, 0x53, 0x6c, 0x6f, 0x76, 0x65, 0x6e, 0x69, 0x6a, 0x61, 0x53, 0x6f, 0x6f, 0x6d, 0x61, 0x61, 0x6c,
-0x69, 0x53, 0x6f, 0x6f, 0x6d, 0x61, 0x61, 0x6c, 0x69, 0x79, 0x61, 0x4a, 0x61, 0x62, 0x75, 0x75, 0x74, 0x69, 0x49, 0x74,
-0x6f, 0x6f, 0x62, 0x69, 0x79, 0x61, 0x4b, 0x69, 0x69, 0x6e, 0x69, 0x79, 0x61, 0x65, 0x73, 0x70, 0x61, 0xf1, 0x6f, 0x6c,
-0x20, 0x64, 0x65, 0x20, 0x45, 0x73, 0x70, 0x61, 0xf1, 0x61, 0x65, 0x73, 0x70, 0x61, 0xf1, 0x6f, 0x6c, 0x41, 0x72, 0x67,
-0x65, 0x6e, 0x74, 0x69, 0x6e, 0x61, 0x42, 0x6f, 0x6c, 0x69, 0x76, 0x69, 0x61, 0x43, 0x68, 0x69, 0x6c, 0x65, 0x43, 0x6f,
-0x6c, 0x6f, 0x6d, 0x62, 0x69, 0x61, 0x43, 0x6f, 0x73, 0x74, 0x61, 0x20, 0x52, 0x69, 0x63, 0x61, 0x43, 0x75, 0x62, 0x61,
-0x52, 0x65, 0x70, 0xfa, 0x62, 0x6c, 0x69, 0x63, 0x61, 0x20, 0x44, 0x6f, 0x6d, 0x69, 0x6e, 0x69, 0x63, 0x61, 0x6e, 0x61,
-0x45, 0x63, 0x75, 0x61, 0x64, 0x6f, 0x72, 0x45, 0x6c, 0x20, 0x53, 0x61, 0x6c, 0x76, 0x61, 0x64, 0x6f, 0x72, 0x47, 0x75,
-0x69, 0x6e, 0x65, 0x61, 0x20, 0x45, 0x63, 0x75, 0x61, 0x74, 0x6f, 0x72, 0x69, 0x61, 0x6c, 0x47, 0x75, 0x61, 0x74, 0x65,
-0x6d, 0x61, 0x6c, 0x61, 0x48, 0x6f, 0x6e, 0x64, 0x75, 0x72, 0x61, 0x73, 0x4d, 0xe9, 0x78, 0x69, 0x63, 0x6f, 0x4e, 0x69,
-0x63, 0x61, 0x72, 0x61, 0x67, 0x75, 0x61, 0x50, 0x61, 0x6e, 0x61, 0x6d, 0xe1, 0x50, 0x61, 0x72, 0x61, 0x67, 0x75, 0x61,
-0x79, 0x50, 0x65, 0x72, 0xfa, 0x46, 0x69, 0x6c, 0x69, 0x70, 0x69, 0x6e, 0x61, 0x73, 0x45, 0x73, 0x74, 0x61, 0x64, 0x6f,
-0x73, 0x20, 0x55, 0x6e, 0x69, 0x64, 0x6f, 0x73, 0x55, 0x72, 0x75, 0x67, 0x75, 0x61, 0x79, 0x56, 0x65, 0x6e, 0x65, 0x7a,
-0x75, 0x65, 0x6c, 0x61, 0x49, 0x73, 0x6c, 0x61, 0x73, 0x20, 0x43, 0x61, 0x6e, 0x61, 0x72, 0x69, 0x61, 0x73, 0x65, 0x73,
-0x70, 0x61, 0xf1, 0x6f, 0x6c, 0x20, 0x6c, 0x61, 0x74, 0x69, 0x6e, 0x6f, 0x61, 0x6d, 0x65, 0x72, 0x69, 0x63, 0x61, 0x6e,
-0x6f, 0x4c, 0x61, 0x74, 0x69, 0x6e, 0x6f, 0x61, 0x6d, 0xe9, 0x72, 0x69, 0x63, 0x61, 0x43, 0x65, 0x75, 0x74, 0x61, 0x20,
-0x79, 0x20, 0x4d, 0x65, 0x6c, 0x69, 0x6c, 0x6c, 0x61, 0x4b, 0x69, 0x73, 0x77, 0x61, 0x68, 0x69, 0x6c, 0x69, 0x73, 0x76,
-0x65, 0x6e, 0x73, 0x6b, 0x61, 0x53, 0x76, 0x65, 0x72, 0x69, 0x67, 0x65, 0x46, 0x69, 0x6e, 0x6c, 0x61, 0x6e, 0x64, 0xc5,
-0x6c, 0x61, 0x6e, 0x64, 0x422, 0x43e, 0x4b7, 0x438, 0x43a, 0x4e3, 0x422, 0x43e, 0x4b7, 0x438, 0x43a, 0x438, 0x441, 0x442, 0x43e, 0x43d,
-0xba4, 0xbae, 0xbbf, 0xbb4, 0xbcd, 0xb87, 0xba8, 0xbcd, 0xba4, 0xbbf, 0xbaf, 0xbbe, 0xbae, 0xbb2, 0xbc7, 0xbb7, 0xbbf, 0xbaf, 0xbbe, 0xb9a,
-0xbbf, 0xb99, 0xbcd, 0xb95, 0xbaa, 0xbcd, 0xbaa, 0xbc2, 0xbb0, 0xbcd, 0xb87, 0xbb2, 0xb99, 0xbcd, 0xb95, 0xbc8, 0xc24, 0xc46, 0xc32, 0xc41,
-0xc17, 0xc41, 0xc2d, 0xc3e, 0xc30, 0xc24, 0x20, 0xc26, 0xc47, 0xc36, 0xc02, 0xe44, 0xe17, 0xe22, 0xf54, 0xf7c, 0xf51, 0xf0b, 0xf66, 0xf90,
-0xf51, 0xf0b, 0xf62, 0xf92, 0xfb1, 0xf0b, 0xf53, 0xf42, 0xf62, 0xf92, 0xfb1, 0xf0b, 0xf42, 0xf62, 0xf0b, 0x1275, 0x130d, 0x122d, 0x129b, 0x12a4,
-0x122d, 0x1275, 0x122b, 0x6c, 0x65, 0x61, 0x20, 0x66, 0x61, 0x6b, 0x61, 0x74, 0x6f, 0x6e, 0x67, 0x61, 0x58, 0x69, 0x74, 0x73,
-0x6f, 0x6e, 0x67, 0x61, 0x54, 0xfc, 0x72, 0x6b, 0xe7, 0x65, 0x54, 0xfc, 0x72, 0x6b, 0x69, 0x79, 0x65, 0x47, 0xfc, 0x6e,
-0x65, 0x79, 0x20, 0x4b, 0x131, 0x62, 0x72, 0x131, 0x73, 0x20, 0x52, 0x75, 0x6d, 0x20, 0x4b, 0x65, 0x73, 0x69, 0x6d, 0x69,
-0x443, 0x43a, 0x440, 0x430, 0x457, 0x43d, 0x441, 0x44c, 0x43a, 0x430, 0x423, 0x43a, 0x440, 0x430, 0x457, 0x43d, 0x430, 0x627, 0x631, 0x62f,
-0x648, 0x67e, 0x627, 0x6a9, 0x633, 0x62a, 0x627, 0x646, 0x628, 0x6be, 0x627, 0x631, 0x62a, 0x40e, 0x437, 0x431, 0x435, 0x43a, 0x40e, 0x437,
-0x431, 0x435, 0x43a, 0x438, 0x441, 0x442, 0x43e, 0x43d, 0x627, 0x648, 0x632, 0x628, 0x6cc, 0x6a9, 0x6f, 0x2bb, 0x7a, 0x62, 0x65, 0x6b,
-0x63, 0x68, 0x61, 0x4f, 0x2bb, 0x7a, 0x62, 0x65, 0x6b, 0x69, 0x73, 0x74, 0x6f, 0x6e, 0x54, 0x69, 0x1ebf, 0x6e, 0x67, 0x20,
-0x56, 0x69, 0x1ec7, 0x74, 0x56, 0x69, 0x1ec7, 0x74, 0x20, 0x4e, 0x61, 0x6d, 0x43, 0x79, 0x6d, 0x72, 0x61, 0x65, 0x67, 0x50,
-0x72, 0x79, 0x64, 0x61, 0x69, 0x6e, 0x20, 0x46, 0x61, 0x77, 0x72, 0x69, 0x73, 0x69, 0x58, 0x68, 0x6f, 0x73, 0x61, 0xc8,
-0x64, 0xe8, 0x20, 0x59, 0x6f, 0x72, 0xf9, 0x62, 0xe1, 0x4f, 0x72, 0xed, 0x6c, 0x1eb9, 0x301, 0xe8, 0x64, 0x65, 0x20, 0x4e,
-0xe0, 0xec, 0x6a, 0xed, 0x72, 0xed, 0xe0, 0x69, 0x73, 0x69, 0x5a, 0x75, 0x6c, 0x75, 0x69, 0x4e, 0x69, 0x6e, 0x67, 0x69,
-0x7a, 0x69, 0x6d, 0x75, 0x20, 0x41, 0x66, 0x72, 0x69, 0x6b, 0x61, 0x6e, 0x79, 0x6e, 0x6f, 0x72, 0x73, 0x6b, 0x4e, 0x6f,
-0x72, 0x65, 0x67, 0x62, 0x6f, 0x73, 0x61, 0x6e, 0x73, 0x6b, 0x69, 0x431, 0x43e, 0x441, 0x430, 0x43d, 0x441, 0x43a, 0x438, 0x47,
-0x61, 0x65, 0x6c, 0x67, 0x52, 0x79, 0x77, 0x76, 0x61, 0x6e, 0x65, 0x74, 0x68, 0x20, 0x55, 0x6e, 0x79, 0x73, 0x6b, 0x65,
-0x72, 0x6e, 0x65, 0x77, 0x65, 0x6b, 0x41, 0x6b, 0x61, 0x6e, 0x47, 0x61, 0x61, 0x6e, 0x61, 0x915, 0x94b, 0x902, 0x915, 0x923,
-0x940, 0x49, 0x67, 0x62, 0x6f, 0x4b, 0x69, 0x6b, 0x61, 0x6d, 0x62, 0x61, 0x1265, 0x120a, 0x1295, 0x1275, 0x130d, 0x1228, 0x66, 0x75,
-0x72, 0x6c, 0x61, 0x6e, 0x49, 0x74, 0x61, 0x6c, 0x69, 0x65, 0x54, 0x73, 0x68, 0x69, 0x76, 0x65, 0x6e, 0x1e13, 0x61, 0x65,
-0x28b, 0x65, 0x67, 0x62, 0x65, 0x47, 0x68, 0x61, 0x6e, 0x61, 0x20, 0x6e, 0x75, 0x74, 0x6f, 0x6d, 0x65, 0x54, 0x6f, 0x67,
-0x6f, 0x20, 0x6e, 0x75, 0x74, 0x6f, 0x6d, 0x65, 0x12c8, 0x120b, 0x12ed, 0x1273, 0x1271, 0x2bb, 0x14c, 0x6c, 0x65, 0x6c, 0x6f, 0x20,
-0x48, 0x61, 0x77, 0x61, 0x69, 0x2bb, 0x69, 0x2bb, 0x41, 0x6d, 0x65, 0x6c, 0x69, 0x6b, 0x61, 0x20, 0x48, 0x75, 0x69, 0x20,
-0x50, 0x16b, 0x20, 0x2bb, 0x49, 0x61, 0x46, 0x69, 0x6c, 0x69, 0x70, 0x69, 0x6e, 0x6f, 0x50, 0x69, 0x6c, 0x69, 0x70, 0x69,
-0x6e, 0x61, 0x73, 0x53, 0x63, 0x68, 0x77, 0x69, 0x69, 0x7a, 0x65, 0x72, 0x74, 0xfc, 0xfc, 0x74, 0x73, 0x63, 0x68, 0x53,
-0x63, 0x68, 0x77, 0x69, 0x69, 0x7a, 0xa188, 0xa320, 0xa259, 0xa34f, 0xa1e9, 0x69, 0x73, 0x69, 0x4e, 0x64, 0x65, 0x62, 0x65, 0x6c,
-0x65, 0x53, 0x65, 0x73, 0x6f, 0x74, 0x68, 0x6f, 0x20, 0x73, 0x61, 0x20, 0x4c, 0x65, 0x62, 0x6f, 0x61, 0x64, 0x61, 0x76,
-0x76, 0x69, 0x73, 0xe1, 0x6d, 0x65, 0x67, 0x69, 0x65, 0x6c, 0x6c, 0x61, 0x4e, 0x6f, 0x72, 0x67, 0x61, 0x53, 0x75, 0x6f,
-0x70, 0x6d, 0x61, 0x45, 0x6b, 0x65, 0x67, 0x75, 0x73, 0x69, 0x69, 0x4b, 0x69, 0x74, 0x61, 0x69, 0x74, 0x61, 0x50, 0x75,
-0x6c, 0x61, 0x61, 0x72, 0x53, 0x65, 0x6e, 0x65, 0x67, 0x61, 0x61, 0x6c, 0x47, 0x69, 0x6b, 0x75, 0x79, 0x75, 0x4b, 0x69,
-0x73, 0x61, 0x6d, 0x70, 0x75, 0x72, 0x73, 0x65, 0x6e, 0x61, 0x4b, 0x69, 0x68, 0x6f, 0x72, 0x6f, 0x6d, 0x62, 0x6f, 0x2d5c,
-0x2d30, 0x2d4e, 0x2d30, 0x2d63, 0x2d49, 0x2d56, 0x2d5c, 0x2d4d, 0x2d4e, 0x2d56, 0x2d54, 0x2d49, 0x2d31, 0x74, 0x61, 0x6d, 0x61, 0x7a, 0x69, 0x67,
-0x68, 0x74, 0x6c, 0x6d, 0x263, 0x72, 0x69, 0x62, 0x54, 0x61, 0x71, 0x62, 0x61, 0x79, 0x6c, 0x69, 0x74, 0x4c, 0x65, 0x7a,
-0x7a, 0x61, 0x79, 0x65, 0x72, 0x52, 0x75, 0x6e, 0x79, 0x61, 0x6e, 0x6b, 0x6f, 0x72, 0x65, 0x48, 0x69, 0x62, 0x65, 0x6e,
-0x61, 0x48, 0x75, 0x74, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x4b, 0x79, 0x69, 0x76, 0x75, 0x6e, 0x6a, 0x6f, 0x62,
-0x61, 0x6d, 0x61, 0x6e, 0x61, 0x6b, 0x61, 0x6e, 0x4b, 0x129, 0x65, 0x6d, 0x62, 0x75, 0x13e3, 0x13b3, 0x13a9, 0x13a0, 0x13b9, 0x13f0,
-0x13df, 0x6b, 0x72, 0x65, 0x6f, 0x6c, 0x20, 0x6d, 0x6f, 0x72, 0x69, 0x73, 0x69, 0x65, 0x6e, 0x4d, 0x6f, 0x72, 0x69, 0x73,
-0x43, 0x68, 0x69, 0x6d, 0x61, 0x6b, 0x6f, 0x6e, 0x64, 0x65, 0x4b, 0x268, 0x6c, 0x61, 0x61, 0x6e, 0x67, 0x69, 0x54, 0x61,
-0x61, 0x6e, 0x73, 0x61, 0x6e, 0xed, 0x61, 0x4c, 0x75, 0x67, 0x61, 0x6e, 0x64, 0x61, 0x59, 0x75, 0x67, 0x61, 0x6e, 0x64,
-0x61, 0x49, 0x63, 0x68, 0x69, 0x62, 0x65, 0x6d, 0x62, 0x61, 0x6b, 0x61, 0x62, 0x75, 0x76, 0x65, 0x72, 0x64, 0x69, 0x61,
-0x6e, 0x75, 0x4b, 0x61, 0x62, 0x75, 0x20, 0x56, 0x65, 0x72, 0x64, 0x69, 0x4b, 0x129, 0x6d, 0x129, 0x72, 0x169, 0x4b, 0x61,
-0x6c, 0x65, 0x6e, 0x6a, 0x69, 0x6e, 0x45, 0x6d, 0x65, 0x74, 0x61, 0x62, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x4b, 0x68,
-0x6f, 0x65, 0x6b, 0x68, 0x6f, 0x65, 0x67, 0x6f, 0x77, 0x61, 0x62, 0x4e, 0x61, 0x6d, 0x69, 0x62, 0x69, 0x61, 0x62, 0x4b,
-0x69, 0x6d, 0x61, 0x63, 0x68, 0x61, 0x6d, 0x65, 0x4b, 0xf6, 0x6c, 0x73, 0x63, 0x68, 0x44, 0x6f, 0xfc, 0x74, 0x73, 0x63,
-0x68, 0x6c, 0x61, 0x6e, 0x64, 0x4d, 0x61, 0x61, 0x54, 0x61, 0x6e, 0x73, 0x61, 0x6e, 0x69, 0x61, 0x4f, 0x6c, 0x75, 0x73,
-0x6f, 0x67, 0x61, 0x4c, 0x75, 0x6c, 0x75, 0x68, 0x69, 0x61, 0x4b, 0x69, 0x70, 0x61, 0x72, 0x65, 0x54, 0x61, 0x64, 0x68,
-0x61, 0x6e, 0x69, 0x61, 0x4b, 0x69, 0x74, 0x65, 0x73, 0x6f, 0x4b, 0x65, 0x6e, 0x69, 0x61, 0x4b, 0x6f, 0x79, 0x72, 0x61,
-0x20, 0x63, 0x69, 0x69, 0x6e, 0x69, 0x4d, 0x61, 0x61, 0x6c, 0x69, 0x4b, 0x69, 0x72, 0x75, 0x77, 0x61, 0x44, 0x68, 0x6f,
-0x6c, 0x75, 0x6f, 0x52, 0x75, 0x6b, 0x69, 0x67, 0x61, 0x54, 0x61, 0x6d, 0x61, 0x7a, 0x69, 0x263, 0x74, 0x4d, 0x65, 0x1e5b,
-0x1e5b, 0x75, 0x6b, 0x4b, 0x6f, 0x79, 0x72, 0x61, 0x62, 0x6f, 0x72, 0x6f, 0x20, 0x73, 0x65, 0x6e, 0x6e, 0x69, 0x4b, 0x69,
-0x73, 0x68, 0x61, 0x6d, 0x62, 0x61, 0x61, 0x92c, 0x921, 0x93c, 0x94b, 0x54, 0x73, 0x68, 0x69, 0x6c, 0x75, 0x62, 0x61, 0x44,
-0x69, 0x74, 0x75, 0x6e, 0x67, 0x61, 0x20, 0x77, 0x61, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x75, 0x41, 0x67, 0x68, 0x65, 0x6d,
-0x4b, 0xe0, 0x6d, 0xe0, 0x6c, 0xfb, 0x14b, 0x181, 0xe0, 0x73, 0xe0, 0x61, 0x4b, 0xe0, 0x6d, 0x25b, 0x300, 0x72, 0xfb, 0x6e,
-0x5a, 0x61, 0x72, 0x6d, 0x61, 0x63, 0x69, 0x69, 0x6e, 0x65, 0x4e, 0x69, 0x17e, 0x65, 0x72, 0x64, 0x75, 0xe1, 0x6c, 0xe1,
-0x6a, 0x6f, 0x6f, 0x6c, 0x61, 0x53, 0x65, 0x6e, 0x65, 0x67, 0x61, 0x6c, 0x65, 0x77, 0x6f, 0x6e, 0x64, 0x6f, 0x4b, 0x61,
-0x6d, 0x259, 0x72, 0xfa, 0x6e, 0x72, 0x69, 0x6b, 0x70, 0x61, 0x6b, 0x61, 0x6d, 0x25b, 0x72, 0xfa, 0x6e, 0x4d, 0x61, 0x6b,
-0x75, 0x61, 0x55, 0x6d, 0x6f, 0x7a, 0x61, 0x6d, 0x62, 0x69, 0x6b, 0x69, 0x4d, 0x55, 0x4e, 0x44, 0x41, 0x14a, 0x6b, 0x61,
-0x6d, 0x65, 0x72, 0x75, 0x14b, 0x4b, 0x77, 0x61, 0x73, 0x69, 0x6f, 0x4b, 0x61, 0x6d, 0x65, 0x72, 0x75, 0x6e, 0x54, 0x68,
-0x6f, 0x6b, 0x20, 0x4e, 0x61, 0x74, 0x68, 0x53, 0x75, 0x64, 0x61, 0x6e, 0x441, 0x430, 0x445, 0x430, 0x20, 0x442, 0x44b, 0x43b,
-0x430, 0x49, 0x73, 0x68, 0x69, 0x73, 0x61, 0x6e, 0x67, 0x75, 0x54, 0x61, 0x6e, 0x73, 0x61, 0x6e, 0x69, 0x79, 0x61, 0x4b,
-0x69, 0x73, 0x77, 0x61, 0x68, 0x69, 0x6c, 0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x6f, 0x4a, 0x61, 0x6d,
-0x68, 0x75, 0x72, 0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x69, 0x64, 0x65, 0x6d, 0x6f, 0x6b, 0x72, 0x61, 0x73, 0x69, 0x61,
-0x20, 0x79, 0x61, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x6f, 0x54, 0x61, 0x73, 0x61, 0x77, 0x61, 0x71, 0x20, 0x73, 0x65, 0x6e,
-0x6e, 0x69, 0xa559, 0xa524, 0xa55e, 0xa524, 0xa52b, 0xa569, 0x56, 0x61, 0x69, 0x4c, 0x61, 0x69, 0x62, 0x68, 0x69, 0x79, 0x61, 0x57,
-0x61, 0x6c, 0x73, 0x65, 0x72, 0x53, 0x63, 0x68, 0x77, 0x69, 0x7a, 0x6e, 0x75, 0x61, 0x73, 0x75, 0x65, 0x4b, 0x65, 0x6d,
-0x65, 0x6c, 0xfa, 0x6e, 0x61, 0x73, 0x74, 0x75, 0x72, 0x69, 0x61, 0x6e, 0x75, 0x4e, 0x64, 0x61, 0xa78c, 0x61, 0x4b, 0x61,
-0x6d, 0x25b, 0x6c, 0xfb, 0x6e, 0x6b, 0x61, 0x6b, 0x254, 0x4b, 0x61, 0x6d, 0x25b, 0x72, 0x75, 0x6e, 0x6d, 0x65, 0x74, 0x61,
-0x2bc, 0x4b, 0x61, 0x6d, 0x61, 0x6c, 0x75, 0x6e, 0x53, 0x68, 0x77, 0xf3, 0x14b, 0xf2, 0x20, 0x6e, 0x67, 0x69, 0x65, 0x6d,
-0x62, 0x254, 0x254, 0x6e, 0x4b, 0xe0, 0x6d, 0x61, 0x6c, 0xfb, 0x6d
+0x20, 0x627, 0x644, 0x63a, 0x631, 0x628, 0x64a, 0x629, 0x627, 0x644, 0x64a, 0x645, 0x646, 0x570, 0x561, 0x575, 0x565, 0x580, 0x565, 0x576,
+0x540, 0x561, 0x575, 0x561, 0x57d, 0x57f, 0x561, 0x576, 0x985, 0x9b8, 0x9ae, 0x9c0, 0x9af, 0x9bc, 0x9be, 0x9ad, 0x9be, 0x9f0, 0x9a4, 0x61,
+0x7a, 0x259, 0x72, 0x62, 0x61, 0x79, 0x63, 0x61, 0x6e, 0x63, 0x61, 0x41, 0x7a, 0x259, 0x72, 0x62, 0x61, 0x79, 0x63, 0x61,
+0x6e, 0x410, 0x437, 0x4d9, 0x440, 0x431, 0x430, 0x458, 0x4b9, 0x430, 0x43d, 0x65, 0x75, 0x73, 0x6b, 0x61, 0x72, 0x61, 0x45, 0x73,
+0x70, 0x61, 0x69, 0x6e, 0x69, 0x61, 0x9ac, 0x9be, 0x982, 0x9b2, 0x9be, 0x9ac, 0x9be, 0x982, 0x9b2, 0x9be, 0x9a6, 0x9c7, 0x9b6, 0x9ad,
+0x9be, 0x9b0, 0x9a4, 0xf62, 0xfab, 0xf7c, 0xf44, 0xf0b, 0xf41, 0xf60, 0xf56, 0xfb2, 0xf74, 0xf42, 0x62, 0x72, 0x65, 0x7a, 0x68, 0x6f,
+0x6e, 0x65, 0x67, 0x46, 0x72, 0x61, 0xf1, 0x73, 0x431, 0x44a, 0x43b, 0x433, 0x430, 0x440, 0x441, 0x43a, 0x438, 0x411, 0x44a, 0x43b,
+0x433, 0x430, 0x440, 0x438, 0x44f, 0x1017, 0x1019, 0x102c, 0x1019, 0x103c, 0x1014, 0x103a, 0x1019, 0x102c, 0x431, 0x435, 0x43b, 0x430, 0x440, 0x443,
+0x441, 0x43a, 0x430, 0x44f, 0x411, 0x435, 0x43b, 0x430, 0x440, 0x443, 0x441, 0x44c, 0x1781, 0x17d2, 0x1798, 0x17c2, 0x179a, 0x1780, 0x1798, 0x17d2,
+0x1796, 0x17bb, 0x1787, 0x17b6, 0x63, 0x61, 0x74, 0x61, 0x6c, 0xe0, 0x45, 0x73, 0x70, 0x61, 0x6e, 0x79, 0x61, 0x41, 0x6e, 0x64,
+0x6f, 0x72, 0x72, 0x61, 0x7b80, 0x4f53, 0x4e2d, 0x6587, 0x4e2d, 0x56fd, 0x4e2d, 0x56fd, 0x9999, 0x6e2f, 0x7279, 0x522b, 0x884c, 0x653f, 0x533a, 0x4e2d,
+0x56fd, 0x6fb3, 0x95e8, 0x7279, 0x522b, 0x884c, 0x653f, 0x533a, 0x65b0, 0x52a0, 0x5761, 0x7e41, 0x9ad4, 0x4e2d, 0x6587, 0x4e2d, 0x83ef, 0x4eba, 0x6c11, 0x5171,
+0x548c, 0x570b, 0x9999, 0x6e2f, 0x7279, 0x5225, 0x884c, 0x653f, 0x5340, 0x4e2d, 0x83ef, 0x4eba, 0x6c11, 0x5171, 0x548c, 0x570b, 0x6fb3, 0x9580, 0x7279, 0x5225,
+0x884c, 0x653f, 0x5340, 0x53f0, 0x7063, 0x68, 0x72, 0x76, 0x61, 0x74, 0x73, 0x6b, 0x69, 0x48, 0x72, 0x76, 0x61, 0x74, 0x73, 0x6b,
+0x61, 0x42, 0x6f, 0x73, 0x6e, 0x61, 0x20, 0x69, 0x20, 0x48, 0x65, 0x72, 0x63, 0x65, 0x67, 0x6f, 0x76, 0x69, 0x6e, 0x61,
+0x10d, 0x65, 0x161, 0x74, 0x69, 0x6e, 0x61, 0x10c, 0x65, 0x73, 0x6b, 0xe1, 0x20, 0x72, 0x65, 0x70, 0x75, 0x62, 0x6c, 0x69,
+0x6b, 0x61, 0x64, 0x61, 0x6e, 0x73, 0x6b, 0x44, 0x61, 0x6e, 0x6d, 0x61, 0x72, 0x6b, 0x4e, 0x65, 0x64, 0x65, 0x72, 0x6c,
+0x61, 0x6e, 0x64, 0x73, 0x4e, 0x65, 0x64, 0x65, 0x72, 0x6c, 0x61, 0x6e, 0x64, 0x41, 0x72, 0x75, 0x62, 0x61, 0x56, 0x6c,
+0x61, 0x61, 0x6d, 0x73, 0x42, 0x65, 0x6c, 0x67, 0x69, 0xeb, 0x43, 0x75, 0x72, 0x61, 0xe7, 0x61, 0x6f, 0x53, 0x75, 0x72,
+0x69, 0x6e, 0x61, 0x6d, 0x65, 0x53, 0x69, 0x6e, 0x74, 0x2d, 0x4d, 0x61, 0x61, 0x72, 0x74, 0x65, 0x6e, 0x55, 0x2e, 0x53,
+0x2e, 0x20, 0x45, 0x6e, 0x67, 0x6c, 0x69, 0x73, 0x68, 0x55, 0x6e, 0x69, 0x74, 0x65, 0x64, 0x20, 0x53, 0x74, 0x61, 0x74,
+0x65, 0x73, 0xd801, 0xdc00, 0xd801, 0xdc4d, 0xd801, 0xdc4a, 0xd801, 0xdc2e, 0xd801, 0xdc47, 0xd801, 0xdc0f, 0xd801, 0xdc2d, 0xd801, 0xdc4c, 0xd801, 0xdc34,
+0xd801, 0xdc3b, 0xd801, 0xdc32, 0xd801, 0xdc3c, 0x20, 0xd801, 0xdc1d, 0xd801, 0xdc3b, 0xd801, 0xdc29, 0xd801, 0xdc3b, 0xd801, 0xdc45, 0x45, 0x6e, 0x67,
+0x6c, 0x69, 0x73, 0x68, 0x41, 0x6d, 0x65, 0x72, 0x69, 0x63, 0x61, 0x6e, 0x20, 0x53, 0x61, 0x6d, 0x6f, 0x61, 0x41, 0x6e,
+0x74, 0x69, 0x67, 0x75, 0x61, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x42, 0x61, 0x72, 0x62, 0x75, 0x64, 0x61, 0x41, 0x75, 0x73,
+0x74, 0x72, 0x61, 0x6c, 0x69, 0x61, 0x6e, 0x20, 0x45, 0x6e, 0x67, 0x6c, 0x69, 0x73, 0x68, 0x41, 0x75, 0x73, 0x74, 0x72,
+0x61, 0x6c, 0x69, 0x61, 0x42, 0x61, 0x68, 0x61, 0x6d, 0x61, 0x73, 0x42, 0x61, 0x72, 0x62, 0x61, 0x64, 0x6f, 0x73, 0x42,
+0x65, 0x6c, 0x67, 0x69, 0x75, 0x6d, 0x42, 0x65, 0x6c, 0x69, 0x7a, 0x65, 0x42, 0x65, 0x72, 0x6d, 0x75, 0x64, 0x61, 0x42,
+0x6f, 0x74, 0x73, 0x77, 0x61, 0x6e, 0x61, 0x43, 0x61, 0x6d, 0x65, 0x72, 0x6f, 0x6f, 0x6e, 0x43, 0x61, 0x6e, 0x61, 0x64,
+0x69, 0x61, 0x6e, 0x20, 0x45, 0x6e, 0x67, 0x6c, 0x69, 0x73, 0x68, 0x43, 0x61, 0x6e, 0x61, 0x64, 0x61, 0x43, 0x61, 0x79,
+0x6d, 0x61, 0x6e, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x44, 0x6f, 0x6d, 0x69, 0x6e, 0x69, 0x63, 0x61, 0x46,
+0x69, 0x6a, 0x69, 0x47, 0x75, 0x65, 0x72, 0x6e, 0x73, 0x65, 0x79, 0x47, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x47, 0x68, 0x61,
+0x6e, 0x61, 0x47, 0x69, 0x62, 0x72, 0x61, 0x6c, 0x74, 0x61, 0x72, 0x47, 0x72, 0x65, 0x6e, 0x61, 0x64, 0x61, 0x47, 0x75,
+0x61, 0x6d, 0x47, 0x75, 0x79, 0x61, 0x6e, 0x61, 0x48, 0x6f, 0x6e, 0x67, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x20, 0x53, 0x41,
+0x52, 0x20, 0x43, 0x68, 0x69, 0x6e, 0x61, 0x49, 0x6e, 0x64, 0x69, 0x61, 0x49, 0x72, 0x65, 0x6c, 0x61, 0x6e, 0x64, 0x4a,
+0x61, 0x6d, 0x61, 0x69, 0x63, 0x61, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x4b, 0x69, 0x72, 0x69, 0x62, 0x61, 0x74, 0x69, 0x4c,
+0x65, 0x73, 0x6f, 0x74, 0x68, 0x6f, 0x4c, 0x69, 0x62, 0x65, 0x72, 0x69, 0x61, 0x4d, 0x61, 0x64, 0x61, 0x67, 0x61, 0x73,
+0x63, 0x61, 0x72, 0x4d, 0x61, 0x6c, 0x61, 0x77, 0x69, 0x4d, 0x61, 0x6c, 0x74, 0x61, 0x4d, 0x61, 0x72, 0x73, 0x68, 0x61,
+0x6c, 0x6c, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x4d, 0x61, 0x75, 0x72, 0x69, 0x74, 0x69, 0x75, 0x73, 0x4d,
+0x69, 0x63, 0x72, 0x6f, 0x6e, 0x65, 0x73, 0x69, 0x61, 0x4e, 0x61, 0x6d, 0x69, 0x62, 0x69, 0x61, 0x4e, 0x65, 0x77, 0x20,
+0x5a, 0x65, 0x61, 0x6c, 0x61, 0x6e, 0x64, 0x4e, 0x69, 0x67, 0x65, 0x72, 0x69, 0x61, 0x4e, 0x6f, 0x72, 0x74, 0x68, 0x65,
+0x72, 0x6e, 0x20, 0x4d, 0x61, 0x72, 0x69, 0x61, 0x6e, 0x61, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x50, 0x61,
+0x6b, 0x69, 0x73, 0x74, 0x61, 0x6e, 0x50, 0x61, 0x6c, 0x61, 0x75, 0x50, 0x61, 0x70, 0x75, 0x61, 0x20, 0x4e, 0x65, 0x77,
+0x20, 0x47, 0x75, 0x69, 0x6e, 0x65, 0x61, 0x50, 0x68, 0x69, 0x6c, 0x69, 0x70, 0x70, 0x69, 0x6e, 0x65, 0x73, 0x50, 0x75,
+0x65, 0x72, 0x74, 0x6f, 0x20, 0x52, 0x69, 0x63, 0x6f, 0x53, 0x61, 0x69, 0x6e, 0x74, 0x20, 0x4b, 0x69, 0x74, 0x74, 0x73,
+0x20, 0x61, 0x6e, 0x64, 0x20, 0x4e, 0x65, 0x76, 0x69, 0x73, 0x53, 0x61, 0x69, 0x6e, 0x74, 0x20, 0x4c, 0x75, 0x63, 0x69,
+0x61, 0x53, 0x61, 0x69, 0x6e, 0x74, 0x20, 0x56, 0x69, 0x6e, 0x63, 0x65, 0x6e, 0x74, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x74,
+0x68, 0x65, 0x20, 0x47, 0x72, 0x65, 0x6e, 0x61, 0x64, 0x69, 0x6e, 0x65, 0x73, 0x53, 0x61, 0x6d, 0x6f, 0x61, 0x53, 0x65,
+0x79, 0x63, 0x68, 0x65, 0x6c, 0x6c, 0x65, 0x73, 0x53, 0x69, 0x65, 0x72, 0x72, 0x61, 0x20, 0x4c, 0x65, 0x6f, 0x6e, 0x65,
+0x53, 0x69, 0x6e, 0x67, 0x61, 0x70, 0x6f, 0x72, 0x65, 0x53, 0x6f, 0x6c, 0x6f, 0x6d, 0x6f, 0x6e, 0x20, 0x49, 0x73, 0x6c,
+0x61, 0x6e, 0x64, 0x73, 0x53, 0x6f, 0x75, 0x74, 0x68, 0x20, 0x41, 0x66, 0x72, 0x69, 0x63, 0x61, 0x53, 0x77, 0x61, 0x7a,
+0x69, 0x6c, 0x61, 0x6e, 0x64, 0x54, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x54, 0x6f, 0x6e, 0x67, 0x61, 0x54, 0x72,
+0x69, 0x6e, 0x69, 0x64, 0x61, 0x64, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x54, 0x6f, 0x62, 0x61, 0x67, 0x6f, 0x54, 0x75, 0x72,
+0x6b, 0x73, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x43, 0x61, 0x69, 0x63, 0x6f, 0x73, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64,
+0x73, 0x55, 0x67, 0x61, 0x6e, 0x64, 0x61, 0x42, 0x72, 0x69, 0x74, 0x69, 0x73, 0x68, 0x20, 0x45, 0x6e, 0x67, 0x6c, 0x69,
+0x73, 0x68, 0x55, 0x6e, 0x69, 0x74, 0x65, 0x64, 0x20, 0x4b, 0x69, 0x6e, 0x67, 0x64, 0x6f, 0x6d, 0x55, 0x2e, 0x53, 0x2e,
+0x20, 0x4f, 0x75, 0x74, 0x6c, 0x79, 0x69, 0x6e, 0x67, 0x20, 0x49, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x56, 0x61, 0x6e,
+0x75, 0x61, 0x74, 0x75, 0x42, 0x72, 0x69, 0x74, 0x69, 0x73, 0x68, 0x20, 0x56, 0x69, 0x72, 0x67, 0x69, 0x6e, 0x20, 0x49,
+0x73, 0x6c, 0x61, 0x6e, 0x64, 0x73, 0x55, 0x2e, 0x53, 0x2e, 0x20, 0x56, 0x69, 0x72, 0x67, 0x69, 0x6e, 0x20, 0x49, 0x73,
+0x6c, 0x61, 0x6e, 0x64, 0x73, 0x5a, 0x61, 0x6d, 0x62, 0x69, 0x61, 0x5a, 0x69, 0x6d, 0x62, 0x61, 0x62, 0x77, 0x65, 0x49,
+0x73, 0x6c, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x4d, 0x61, 0x6e, 0x4a, 0x65, 0x72, 0x73, 0x65, 0x79, 0x53, 0x6f, 0x75, 0x74,
+0x68, 0x20, 0x53, 0x75, 0x64, 0x61, 0x6e, 0x65, 0x65, 0x73, 0x74, 0x69, 0x45, 0x65, 0x73, 0x74, 0x69, 0x66, 0xf8, 0x72,
+0x6f, 0x79, 0x73, 0x6b, 0x74, 0x46, 0xf8, 0x72, 0x6f, 0x79, 0x61, 0x72, 0x73, 0x75, 0x6f, 0x6d, 0x69, 0x53, 0x75, 0x6f,
+0x6d, 0x69, 0x66, 0x72, 0x61, 0x6e, 0xe7, 0x61, 0x69, 0x73, 0x46, 0x72, 0x61, 0x6e, 0x63, 0x65, 0x41, 0x6c, 0x67, 0xe9,
+0x72, 0x69, 0x65, 0x42, 0x65, 0x6c, 0x67, 0x69, 0x71, 0x75, 0x65, 0x42, 0xe9, 0x6e, 0x69, 0x6e, 0x42, 0x75, 0x72, 0x6b,
+0x69, 0x6e, 0x61, 0x20, 0x46, 0x61, 0x73, 0x6f, 0x42, 0x75, 0x72, 0x75, 0x6e, 0x64, 0x69, 0x43, 0x61, 0x6d, 0x65, 0x72,
+0x6f, 0x75, 0x6e, 0x66, 0x72, 0x61, 0x6e, 0xe7, 0x61, 0x69, 0x73, 0x20, 0x63, 0x61, 0x6e, 0x61, 0x64, 0x69, 0x65, 0x6e,
+0x52, 0xe9, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x71, 0x75, 0x65, 0x20, 0x63, 0x65, 0x6e, 0x74, 0x72, 0x61, 0x66, 0x72, 0x69,
+0x63, 0x61, 0x69, 0x6e, 0x65, 0x54, 0x63, 0x68, 0x61, 0x64, 0x43, 0x6f, 0x6d, 0x6f, 0x72, 0x65, 0x73, 0x52, 0xe9, 0x70,
+0x75, 0x62, 0x6c, 0x69, 0x71, 0x75, 0x65, 0x20, 0x64, 0xe9, 0x6d, 0x6f, 0x63, 0x72, 0x61, 0x74, 0x69, 0x71, 0x75, 0x65,
+0x20, 0x64, 0x75, 0x20, 0x43, 0x6f, 0x6e, 0x67, 0x6f, 0x43, 0x6f, 0x6e, 0x67, 0x6f, 0x2d, 0x42, 0x72, 0x61, 0x7a, 0x7a,
+0x61, 0x76, 0x69, 0x6c, 0x6c, 0x65, 0x43, 0xf4, 0x74, 0x65, 0x20, 0x64, 0x2019, 0x49, 0x76, 0x6f, 0x69, 0x72, 0x65, 0x44,
+0x6a, 0x69, 0x62, 0x6f, 0x75, 0x74, 0x69, 0x47, 0x75, 0x69, 0x6e, 0xe9, 0x65, 0x20, 0xe9, 0x71, 0x75, 0x61, 0x74, 0x6f,
+0x72, 0x69, 0x61, 0x6c, 0x65, 0x47, 0x75, 0x79, 0x61, 0x6e, 0x65, 0x20, 0x66, 0x72, 0x61, 0x6e, 0xe7, 0x61, 0x69, 0x73,
+0x65, 0x50, 0x6f, 0x6c, 0x79, 0x6e, 0xe9, 0x73, 0x69, 0x65, 0x20, 0x66, 0x72, 0x61, 0x6e, 0xe7, 0x61, 0x69, 0x73, 0x65,
+0x47, 0x61, 0x62, 0x6f, 0x6e, 0x47, 0x75, 0x61, 0x64, 0x65, 0x6c, 0x6f, 0x75, 0x70, 0x65, 0x47, 0x75, 0x69, 0x6e, 0xe9,
+0x65, 0x48, 0x61, 0xef, 0x74, 0x69, 0x4c, 0x75, 0x78, 0x65, 0x6d, 0x62, 0x6f, 0x75, 0x72, 0x67, 0x4d, 0x61, 0x6c, 0x69,
+0x4d, 0x61, 0x72, 0x74, 0x69, 0x6e, 0x69, 0x71, 0x75, 0x65, 0x4d, 0x61, 0x75, 0x72, 0x69, 0x74, 0x61, 0x6e, 0x69, 0x65,
+0x4d, 0x61, 0x75, 0x72, 0x69, 0x63, 0x65, 0x4d, 0x61, 0x79, 0x6f, 0x74, 0x74, 0x65, 0x4d, 0x6f, 0x6e, 0x61, 0x63, 0x6f,
+0x4d, 0x61, 0x72, 0x6f, 0x63, 0x4e, 0x6f, 0x75, 0x76, 0x65, 0x6c, 0x6c, 0x65, 0x2d, 0x43, 0x61, 0x6c, 0xe9, 0x64, 0x6f,
+0x6e, 0x69, 0x65, 0x4e, 0x69, 0x67, 0x65, 0x72, 0x52, 0xe9, 0x75, 0x6e, 0x69, 0x6f, 0x6e, 0x52, 0x77, 0x61, 0x6e, 0x64,
+0x61, 0x53, 0xe9, 0x6e, 0xe9, 0x67, 0x61, 0x6c, 0x66, 0x72, 0x61, 0x6e, 0xe7, 0x61, 0x69, 0x73, 0x20, 0x73, 0x75, 0x69,
+0x73, 0x73, 0x65, 0x53, 0x75, 0x69, 0x73, 0x73, 0x65, 0x53, 0x79, 0x72, 0x69, 0x65, 0x54, 0x6f, 0x67, 0x6f, 0x54, 0x75,
+0x6e, 0x69, 0x73, 0x69, 0x65, 0x53, 0x61, 0x69, 0x6e, 0x74, 0x2d, 0x42, 0x61, 0x72, 0x74, 0x68, 0xe9, 0x6c, 0xe9, 0x6d,
+0x79, 0x53, 0x61, 0x69, 0x6e, 0x74, 0x2d, 0x4d, 0x61, 0x72, 0x74, 0x69, 0x6e, 0x20, 0x5b, 0x70, 0x61, 0x72, 0x74, 0x69,
+0x65, 0x20, 0x66, 0x72, 0x61, 0x6e, 0xe7, 0x61, 0x69, 0x73, 0x65, 0x5d, 0x47, 0xe0, 0x69, 0x64, 0x68, 0x6c, 0x69, 0x67,
+0x41, 0x6e, 0x20, 0x52, 0xec, 0x6f, 0x67, 0x68, 0x61, 0x63, 0x68, 0x64, 0x20, 0x41, 0x6f, 0x6e, 0x61, 0x69, 0x63, 0x68,
+0x74, 0x65, 0x67, 0x61, 0x6c, 0x65, 0x67, 0x6f, 0x45, 0x73, 0x70, 0x61, 0xf1, 0x61, 0x10e5, 0x10d0, 0x10e0, 0x10d7, 0x10e3, 0x10da,
+0x10d8, 0x10e1, 0x10d0, 0x10e5, 0x10d0, 0x10e0, 0x10d7, 0x10d5, 0x10d4, 0x10da, 0x10dd, 0x44, 0x65, 0x75, 0x74, 0x73, 0x63, 0x68, 0x44, 0x65,
+0x75, 0x74, 0x73, 0x63, 0x68, 0x6c, 0x61, 0x6e, 0x64, 0xd6, 0x73, 0x74, 0x65, 0x72, 0x72, 0x65, 0x69, 0x63, 0x68, 0x69,
+0x73, 0x63, 0x68, 0x65, 0x73, 0x20, 0x44, 0x65, 0x75, 0x74, 0x73, 0x63, 0x68, 0xd6, 0x73, 0x74, 0x65, 0x72, 0x72, 0x65,
+0x69, 0x63, 0x68, 0x42, 0x65, 0x6c, 0x67, 0x69, 0x65, 0x6e, 0x4c, 0x69, 0x65, 0x63, 0x68, 0x74, 0x65, 0x6e, 0x73, 0x74,
+0x65, 0x69, 0x6e, 0x4c, 0x75, 0x78, 0x65, 0x6d, 0x62, 0x75, 0x72, 0x67, 0x53, 0x63, 0x68, 0x77, 0x65, 0x69, 0x7a, 0x65,
+0x72, 0x20, 0x48, 0x6f, 0x63, 0x68, 0x64, 0x65, 0x75, 0x74, 0x73, 0x63, 0x68, 0x53, 0x63, 0x68, 0x77, 0x65, 0x69, 0x7a,
+0x395, 0x3bb, 0x3bb, 0x3b7, 0x3bd, 0x3b9, 0x3ba, 0x3ac, 0x395, 0x3bb, 0x3bb, 0x3ac, 0x3b4, 0x3b1, 0x39a, 0x3cd, 0x3c0, 0x3c1, 0x3bf, 0x3c2,
+0x6b, 0x61, 0x6c, 0x61, 0x61, 0x6c, 0x6c, 0x69, 0x73, 0x75, 0x74, 0x4b, 0x61, 0x6c, 0x61, 0x61, 0x6c, 0x6c, 0x69, 0x74,
+0x20, 0x4e, 0x75, 0x6e, 0x61, 0x61, 0x74, 0xa97, 0xac1, 0xa9c, 0xab0, 0xabe, 0xaa4, 0xac0, 0xaad, 0xabe, 0xab0, 0xaa4, 0x48, 0x61,
+0x75, 0x73, 0x61, 0x4e, 0x61, 0x6a, 0x65, 0x72, 0x69, 0x79, 0x61, 0x47, 0x61, 0x6e, 0x61, 0x4e, 0x69, 0x6a, 0x61, 0x72,
+0x5e2, 0x5d1, 0x5e8, 0x5d9, 0x5ea, 0x5d9, 0x5e9, 0x5e8, 0x5d0, 0x5dc, 0x939, 0x93f, 0x928, 0x94d, 0x926, 0x940, 0x92d, 0x93e, 0x930, 0x924,
+0x6d, 0x61, 0x67, 0x79, 0x61, 0x72, 0x4d, 0x61, 0x67, 0x79, 0x61, 0x72, 0x6f, 0x72, 0x73, 0x7a, 0xe1, 0x67, 0xed, 0x73,
+0x6c, 0x65, 0x6e, 0x73, 0x6b, 0x61, 0xcd, 0x73, 0x6c, 0x61, 0x6e, 0x64, 0x42, 0x61, 0x68, 0x61, 0x73, 0x61, 0x20, 0x49,
+0x6e, 0x64, 0x6f, 0x6e, 0x65, 0x73, 0x69, 0x61, 0x49, 0x6e, 0x64, 0x6f, 0x6e, 0x65, 0x73, 0x69, 0x61, 0x69, 0x6e, 0x74,
+0x65, 0x72, 0x6c, 0x69, 0x6e, 0x67, 0x75, 0x61, 0x46, 0x72, 0x61, 0x6e, 0x63, 0x69, 0x61, 0x47, 0x61, 0x65, 0x69, 0x6c,
+0x67, 0x65, 0xc9, 0x69, 0x72, 0x65, 0x69, 0x74, 0x61, 0x6c, 0x69, 0x61, 0x6e, 0x6f, 0x49, 0x74, 0x61, 0x6c, 0x69, 0x61,
+0x53, 0x61, 0x6e, 0x20, 0x4d, 0x61, 0x72, 0x69, 0x6e, 0x6f, 0x53, 0x76, 0x69, 0x7a, 0x7a, 0x65, 0x72, 0x61, 0x65e5, 0x672c,
+0x8a9e, 0x65e5, 0x672c, 0xc95, 0xca8, 0xccd, 0xca8, 0xca1, 0xcad, 0xcbe, 0xcb0, 0xca4, 0x6a9, 0x672, 0x634, 0x64f, 0x631, 0x6c1, 0x650, 0x646,
+0x65b, 0x62f, 0x648, 0x633, 0x62a, 0x627, 0x646, 0x49b, 0x430, 0x437, 0x430, 0x49b, 0x20, 0x442, 0x456, 0x43b, 0x456, 0x49a, 0x430, 0x437,
+0x430, 0x49b, 0x441, 0x442, 0x430, 0x43d, 0x4b, 0x69, 0x6e, 0x79, 0x61, 0x72, 0x77, 0x61, 0x6e, 0x64, 0x61, 0x41a, 0x44b, 0x440,
+0x433, 0x44b, 0x437, 0x41a, 0x44b, 0x440, 0x433, 0x44b, 0x437, 0x441, 0x442, 0x430, 0x43d, 0xd55c, 0xad6d, 0xc5b4, 0xb300, 0xd55c, 0xbbfc, 0xad6d,
+0xc870, 0xc120, 0x20, 0xbbfc, 0xc8fc, 0xc8fc, 0xc758, 0x20, 0xc778, 0xbbfc, 0x20, 0xacf5, 0xd654, 0xad6d, 0x49, 0x6b, 0x69, 0x72, 0x75, 0x6e,
+0x64, 0x69, 0x55, 0x62, 0x75, 0x72, 0x75, 0x6e, 0x64, 0x69, 0xea5, 0xeb2, 0xea7, 0xeaa, 0x2e, 0xe9b, 0x2e, 0xe9b, 0x20, 0xea5,
+0xeb2, 0xea7, 0x6c, 0x61, 0x74, 0x76, 0x69, 0x65, 0x161, 0x75, 0x4c, 0x61, 0x74, 0x76, 0x69, 0x6a, 0x61, 0x6c, 0x69, 0x6e,
+0x67, 0xe1, 0x6c, 0x61, 0x52, 0x65, 0x70, 0x69, 0x62, 0x69, 0x6b, 0x69, 0x20, 0x64, 0x65, 0x6d, 0x6f, 0x6b, 0x72, 0x61,
+0x74, 0x69, 0x6b, 0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0xf3, 0x41, 0x6e, 0x67, 0xf3, 0x6c, 0x61, 0x52,
+0x65, 0x70, 0x69, 0x62, 0x69, 0x6b, 0x69, 0x20, 0x79, 0x61, 0x20, 0x41, 0x66, 0x72, 0xed, 0x6b, 0x61, 0x20, 0x79, 0x61,
+0x20, 0x4b, 0xe1, 0x74, 0x69, 0x4b, 0x6f, 0x6e, 0x67, 0x6f, 0x6c, 0x69, 0x65, 0x74, 0x75, 0x76, 0x69, 0x173, 0x4c, 0x69,
+0x65, 0x74, 0x75, 0x76, 0x61, 0x43c, 0x430, 0x43a, 0x435, 0x434, 0x43e, 0x43d, 0x441, 0x43a, 0x438, 0x41c, 0x430, 0x43a, 0x435, 0x434,
+0x43e, 0x43d, 0x438, 0x458, 0x430, 0x4d, 0x61, 0x6c, 0x61, 0x67, 0x61, 0x73, 0x79, 0x4d, 0x61, 0x64, 0x61, 0x67, 0x61, 0x73,
+0x69, 0x6b, 0x61, 0x72, 0x61, 0x42, 0x61, 0x68, 0x61, 0x73, 0x61, 0x20, 0x4d, 0x65, 0x6c, 0x61, 0x79, 0x75, 0x4d, 0x61,
+0x6c, 0x61, 0x79, 0x73, 0x69, 0x61, 0x42, 0x72, 0x75, 0x6e, 0x65, 0x69, 0x53, 0x69, 0x6e, 0x67, 0x61, 0x70, 0x75, 0x72,
+0x61, 0xd2e, 0xd32, 0xd2f, 0xd3e, 0xd33, 0xd02, 0xd07, 0xd28, 0xd4d, 0xd24, 0xd4d, 0xd2f, 0x4d, 0x61, 0x6c, 0x74, 0x69, 0x92e, 0x930,
+0x93e, 0x920, 0x940, 0x43c, 0x43e, 0x43d, 0x433, 0x43e, 0x43b, 0x41c, 0x43e, 0x43d, 0x433, 0x43e, 0x43b, 0x928, 0x947, 0x92a, 0x93e, 0x932,
+0x940, 0x928, 0x947, 0x92a, 0x93e, 0x932, 0x6e, 0x6f, 0x72, 0x73, 0x6b, 0x20, 0x62, 0x6f, 0x6b, 0x6d, 0xe5, 0x6c, 0x4e, 0x6f,
+0x72, 0x67, 0x65, 0xb13, 0xb21, 0xb3c, 0xb3f, 0xb06, 0xb2d, 0xb3e, 0xb30, 0xb24, 0x67e, 0x69a, 0x62a, 0x648, 0x627, 0x641, 0x63a, 0x627,
+0x646, 0x633, 0x62a, 0x627, 0x646, 0x641, 0x627, 0x631, 0x633, 0x6cc, 0x627, 0x6cc, 0x631, 0x627, 0x646, 0x62f, 0x631, 0x6cc, 0x70, 0x6f,
+0x6c, 0x73, 0x6b, 0x69, 0x50, 0x6f, 0x6c, 0x73, 0x6b, 0x61, 0x70, 0x6f, 0x72, 0x74, 0x75, 0x67, 0x75, 0xea, 0x73, 0x20,
+0x64, 0x6f, 0x20, 0x42, 0x72, 0x61, 0x73, 0x69, 0x6c, 0x42, 0x72, 0x61, 0x73, 0x69, 0x6c, 0x70, 0x6f, 0x72, 0x74, 0x75,
+0x67, 0x75, 0xea, 0x73, 0x41, 0x6e, 0x67, 0x6f, 0x6c, 0x61, 0x43, 0x61, 0x62, 0x6f, 0x20, 0x56, 0x65, 0x72, 0x64, 0x65,
+0x54, 0x69, 0x6d, 0x6f, 0x72, 0x2d, 0x4c, 0x65, 0x73, 0x74, 0x65, 0x47, 0x75, 0x69, 0x6e, 0xe9, 0x2d, 0x42, 0x69, 0x73,
+0x73, 0x61, 0x75, 0x4d, 0x61, 0x63, 0x61, 0x75, 0x2c, 0x20, 0x52, 0x41, 0x45, 0x20, 0x64, 0x61, 0x20, 0x43, 0x68, 0x69,
+0x6e, 0x61, 0x4d, 0x6f, 0xe7, 0x61, 0x6d, 0x62, 0x69, 0x71, 0x75, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x75, 0x67, 0x75, 0xea,
+0x73, 0x20, 0x65, 0x75, 0x72, 0x6f, 0x70, 0x65, 0x75, 0x50, 0x6f, 0x72, 0x74, 0x75, 0x67, 0x61, 0x6c, 0x53, 0xe3, 0x6f,
+0x20, 0x54, 0x6f, 0x6d, 0xe9, 0x20, 0x65, 0x20, 0x50, 0x72, 0xed, 0x6e, 0x63, 0x69, 0x70, 0x65, 0xa2a, 0xa70, 0xa1c, 0xa3e,
+0xa2c, 0xa40, 0xa2d, 0xa3e, 0xa30, 0xa24, 0x67e, 0x646, 0x62c, 0x627, 0x628, 0x67e, 0x6a9, 0x633, 0x62a, 0x627, 0x646, 0x72, 0x75, 0x6d,
+0x61, 0x6e, 0x74, 0x73, 0x63, 0x68, 0x53, 0x76, 0x69, 0x7a, 0x72, 0x61, 0x72, 0x6f, 0x6d, 0xe2, 0x6e, 0x103, 0x52, 0x6f,
+0x6d, 0xe2, 0x6e, 0x69, 0x61, 0x52, 0x65, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x61, 0x20, 0x4d, 0x6f, 0x6c, 0x64, 0x6f,
+0x76, 0x61, 0x440, 0x443, 0x441, 0x441, 0x43a, 0x438, 0x439, 0x420, 0x43e, 0x441, 0x441, 0x438, 0x44f, 0x41a, 0x430, 0x437, 0x430, 0x445,
+0x441, 0x442, 0x430, 0x43d, 0x41a, 0x438, 0x440, 0x433, 0x438, 0x437, 0x438, 0x44f, 0x41c, 0x43e, 0x43b, 0x434, 0x43e, 0x432, 0x430, 0x423,
+0x43a, 0x440, 0x430, 0x438, 0x43d, 0x430, 0x53, 0xe4, 0x6e, 0x67, 0xf6, 0x4b, 0xf6, 0x64, 0xf6, 0x72, 0xf6, 0x73, 0xea, 0x73,
+0x65, 0x20, 0x74, 0xee, 0x20, 0x42, 0xea, 0x61, 0x66, 0x72, 0xee, 0x6b, 0x61, 0x421, 0x440, 0x43f, 0x441, 0x43a, 0x438, 0x421,
+0x440, 0x431, 0x438, 0x458, 0x430, 0x441, 0x440, 0x43f, 0x441, 0x43a, 0x438, 0x411, 0x43e, 0x441, 0x43d, 0x430, 0x20, 0x438, 0x20, 0x425,
+0x435, 0x440, 0x446, 0x435, 0x433, 0x43e, 0x432, 0x438, 0x43d, 0x430, 0x426, 0x440, 0x43d, 0x430, 0x20, 0x413, 0x43e, 0x440, 0x430, 0x53,
+0x72, 0x70, 0x73, 0x6b, 0x69, 0x43, 0x72, 0x6e, 0x61, 0x20, 0x47, 0x6f, 0x72, 0x61, 0x53, 0x72, 0x62, 0x69, 0x6a, 0x61,
+0x438, 0x440, 0x43e, 0x43d, 0x413, 0x443, 0x44b, 0x440, 0x434, 0x437, 0x44b, 0x441, 0x442, 0x43e, 0x43d, 0x423, 0x4d5, 0x440, 0x4d5, 0x441,
+0x435, 0x53, 0x65, 0x73, 0x6f, 0x74, 0x68, 0x6f, 0x53, 0x65, 0x74, 0x73, 0x77, 0x61, 0x6e, 0x61, 0x63, 0x68, 0x69, 0x53,
+0x68, 0x6f, 0x6e, 0x61, 0xdc3, 0xdd2, 0xd82, 0xdc4, 0xdbd, 0xdc1, 0xdca, 0x200d, 0xdbb, 0xdd3, 0x20, 0xdbd, 0xd82, 0xd9a, 0xdcf, 0xdc0,
+0x53, 0x69, 0x73, 0x77, 0x61, 0x74, 0x69, 0x73, 0x6c, 0x6f, 0x76, 0x65, 0x6e, 0x10d, 0x69, 0x6e, 0x61, 0x53, 0x6c, 0x6f,
+0x76, 0x65, 0x6e, 0x73, 0x6b, 0x6f, 0x73, 0x6c, 0x6f, 0x76, 0x65, 0x6e, 0x161, 0x10d, 0x69, 0x6e, 0x61, 0x53, 0x6c, 0x6f,
+0x76, 0x65, 0x6e, 0x69, 0x6a, 0x61, 0x53, 0x6f, 0x6f, 0x6d, 0x61, 0x61, 0x6c, 0x69, 0x53, 0x6f, 0x6f, 0x6d, 0x61, 0x61,
+0x6c, 0x69, 0x79, 0x61, 0x4a, 0x61, 0x62, 0x75, 0x75, 0x74, 0x69, 0x49, 0x74, 0x6f, 0x6f, 0x62, 0x69, 0x79, 0x61, 0x4b,
+0x69, 0x69, 0x6e, 0x69, 0x79, 0x61, 0x65, 0x73, 0x70, 0x61, 0xf1, 0x6f, 0x6c, 0x20, 0x64, 0x65, 0x20, 0x45, 0x73, 0x70,
+0x61, 0xf1, 0x61, 0x65, 0x73, 0x70, 0x61, 0xf1, 0x6f, 0x6c, 0x41, 0x72, 0x67, 0x65, 0x6e, 0x74, 0x69, 0x6e, 0x61, 0x42,
+0x6f, 0x6c, 0x69, 0x76, 0x69, 0x61, 0x43, 0x68, 0x69, 0x6c, 0x65, 0x43, 0x6f, 0x6c, 0x6f, 0x6d, 0x62, 0x69, 0x61, 0x43,
+0x6f, 0x73, 0x74, 0x61, 0x20, 0x52, 0x69, 0x63, 0x61, 0x43, 0x75, 0x62, 0x61, 0x52, 0x65, 0x70, 0xfa, 0x62, 0x6c, 0x69,
+0x63, 0x61, 0x20, 0x44, 0x6f, 0x6d, 0x69, 0x6e, 0x69, 0x63, 0x61, 0x6e, 0x61, 0x45, 0x63, 0x75, 0x61, 0x64, 0x6f, 0x72,
+0x45, 0x6c, 0x20, 0x53, 0x61, 0x6c, 0x76, 0x61, 0x64, 0x6f, 0x72, 0x47, 0x75, 0x69, 0x6e, 0x65, 0x61, 0x20, 0x45, 0x63,
+0x75, 0x61, 0x74, 0x6f, 0x72, 0x69, 0x61, 0x6c, 0x47, 0x75, 0x61, 0x74, 0x65, 0x6d, 0x61, 0x6c, 0x61, 0x48, 0x6f, 0x6e,
+0x64, 0x75, 0x72, 0x61, 0x73, 0x4d, 0xe9, 0x78, 0x69, 0x63, 0x6f, 0x4e, 0x69, 0x63, 0x61, 0x72, 0x61, 0x67, 0x75, 0x61,
+0x50, 0x61, 0x6e, 0x61, 0x6d, 0xe1, 0x50, 0x61, 0x72, 0x61, 0x67, 0x75, 0x61, 0x79, 0x50, 0x65, 0x72, 0xfa, 0x46, 0x69,
+0x6c, 0x69, 0x70, 0x69, 0x6e, 0x61, 0x73, 0x45, 0x73, 0x74, 0x61, 0x64, 0x6f, 0x73, 0x20, 0x55, 0x6e, 0x69, 0x64, 0x6f,
+0x73, 0x55, 0x72, 0x75, 0x67, 0x75, 0x61, 0x79, 0x56, 0x65, 0x6e, 0x65, 0x7a, 0x75, 0x65, 0x6c, 0x61, 0x49, 0x73, 0x6c,
+0x61, 0x73, 0x20, 0x43, 0x61, 0x6e, 0x61, 0x72, 0x69, 0x61, 0x73, 0x65, 0x73, 0x70, 0x61, 0xf1, 0x6f, 0x6c, 0x20, 0x6c,
+0x61, 0x74, 0x69, 0x6e, 0x6f, 0x61, 0x6d, 0x65, 0x72, 0x69, 0x63, 0x61, 0x6e, 0x6f, 0x4c, 0x61, 0x74, 0x69, 0x6e, 0x6f,
+0x61, 0x6d, 0xe9, 0x72, 0x69, 0x63, 0x61, 0x43, 0x65, 0x75, 0x74, 0x61, 0x20, 0x79, 0x20, 0x4d, 0x65, 0x6c, 0x69, 0x6c,
+0x6c, 0x61, 0x4b, 0x69, 0x73, 0x77, 0x61, 0x68, 0x69, 0x6c, 0x69, 0x73, 0x76, 0x65, 0x6e, 0x73, 0x6b, 0x61, 0x53, 0x76,
+0x65, 0x72, 0x69, 0x67, 0x65, 0x46, 0x69, 0x6e, 0x6c, 0x61, 0x6e, 0x64, 0xc5, 0x6c, 0x61, 0x6e, 0x64, 0x422, 0x43e, 0x4b7,
+0x438, 0x43a, 0x4e3, 0x422, 0x43e, 0x4b7, 0x438, 0x43a, 0x438, 0x441, 0x442, 0x43e, 0x43d, 0xba4, 0xbae, 0xbbf, 0xbb4, 0xbcd, 0xb87, 0xba8,
+0xbcd, 0xba4, 0xbbf, 0xbaf, 0xbbe, 0xbae, 0xbb2, 0xbc7, 0xbb7, 0xbbf, 0xbaf, 0xbbe, 0xb9a, 0xbbf, 0xb99, 0xbcd, 0xb95, 0xbaa, 0xbcd, 0xbaa,
+0xbc2, 0xbb0, 0xbcd, 0xb87, 0xbb2, 0xb99, 0xbcd, 0xb95, 0xbc8, 0xc24, 0xc46, 0xc32, 0xc41, 0xc17, 0xc41, 0xc2d, 0xc3e, 0xc30, 0xc24, 0x20,
+0xc26, 0xc47, 0xc36, 0xc02, 0xe44, 0xe17, 0xe22, 0xf54, 0xf7c, 0xf51, 0xf0b, 0xf66, 0xf90, 0xf51, 0xf0b, 0xf62, 0xf92, 0xfb1, 0xf0b, 0xf53,
+0xf42, 0xf62, 0xf92, 0xfb1, 0xf0b, 0xf42, 0xf62, 0xf0b, 0x1275, 0x130d, 0x122d, 0x129b, 0x12a4, 0x122d, 0x1275, 0x122b, 0x6c, 0x65, 0x61, 0x20,
+0x66, 0x61, 0x6b, 0x61, 0x74, 0x6f, 0x6e, 0x67, 0x61, 0x58, 0x69, 0x74, 0x73, 0x6f, 0x6e, 0x67, 0x61, 0x54, 0xfc, 0x72,
+0x6b, 0xe7, 0x65, 0x54, 0xfc, 0x72, 0x6b, 0x69, 0x79, 0x65, 0x47, 0xfc, 0x6e, 0x65, 0x79, 0x20, 0x4b, 0x131, 0x62, 0x72,
+0x131, 0x73, 0x20, 0x52, 0x75, 0x6d, 0x20, 0x4b, 0x65, 0x73, 0x69, 0x6d, 0x69, 0x443, 0x43a, 0x440, 0x430, 0x457, 0x43d, 0x441,
+0x44c, 0x43a, 0x430, 0x423, 0x43a, 0x440, 0x430, 0x457, 0x43d, 0x430, 0x627, 0x631, 0x62f, 0x648, 0x67e, 0x627, 0x6a9, 0x633, 0x62a, 0x627,
+0x646, 0x628, 0x6be, 0x627, 0x631, 0x62a, 0x40e, 0x437, 0x431, 0x435, 0x43a, 0x40e, 0x437, 0x431, 0x435, 0x43a, 0x438, 0x441, 0x442, 0x43e,
+0x43d, 0x627, 0x648, 0x632, 0x628, 0x6cc, 0x6a9, 0x6f, 0x2bb, 0x7a, 0x62, 0x65, 0x6b, 0x63, 0x68, 0x61, 0x4f, 0x2bb, 0x7a, 0x62,
+0x65, 0x6b, 0x69, 0x73, 0x74, 0x6f, 0x6e, 0x54, 0x69, 0x1ebf, 0x6e, 0x67, 0x20, 0x56, 0x69, 0x1ec7, 0x74, 0x56, 0x69, 0x1ec7,
+0x74, 0x20, 0x4e, 0x61, 0x6d, 0x43, 0x79, 0x6d, 0x72, 0x61, 0x65, 0x67, 0x79, 0x20, 0x44, 0x65, 0x79, 0x72, 0x6e, 0x61,
+0x73, 0x20, 0x55, 0x6e, 0x65, 0x64, 0x69, 0x67, 0x69, 0x73, 0x69, 0x58, 0x68, 0x6f, 0x73, 0x61, 0xc8, 0x64, 0xe8, 0x20,
+0x59, 0x6f, 0x72, 0xf9, 0x62, 0xe1, 0x4f, 0x72, 0xed, 0x6c, 0x1eb9, 0x301, 0xe8, 0x64, 0x65, 0x20, 0x4e, 0xe0, 0xec, 0x6a,
+0xed, 0x72, 0xed, 0xe0, 0x69, 0x73, 0x69, 0x5a, 0x75, 0x6c, 0x75, 0x69, 0x4e, 0x69, 0x6e, 0x67, 0x69, 0x7a, 0x69, 0x6d,
+0x75, 0x20, 0x41, 0x66, 0x72, 0x69, 0x6b, 0x61, 0x6e, 0x79, 0x6e, 0x6f, 0x72, 0x73, 0x6b, 0x4e, 0x6f, 0x72, 0x65, 0x67,
+0x62, 0x6f, 0x73, 0x61, 0x6e, 0x73, 0x6b, 0x69, 0x431, 0x43e, 0x441, 0x430, 0x43d, 0x441, 0x43a, 0x438, 0x47, 0x61, 0x65, 0x6c,
+0x67, 0x52, 0x79, 0x77, 0x76, 0x61, 0x6e, 0x65, 0x74, 0x68, 0x20, 0x55, 0x6e, 0x79, 0x73, 0x6b, 0x65, 0x72, 0x6e, 0x65,
+0x77, 0x65, 0x6b, 0x41, 0x6b, 0x61, 0x6e, 0x47, 0x61, 0x61, 0x6e, 0x61, 0x915, 0x94b, 0x902, 0x915, 0x923, 0x940, 0x49, 0x67,
+0x62, 0x6f, 0x4b, 0x69, 0x6b, 0x61, 0x6d, 0x62, 0x61, 0x1265, 0x120a, 0x1295, 0x1275, 0x130d, 0x1228, 0x66, 0x75, 0x72, 0x6c, 0x61,
+0x6e, 0x49, 0x74, 0x61, 0x6c, 0x69, 0x65, 0x54, 0x73, 0x68, 0x69, 0x76, 0x65, 0x6e, 0x1e13, 0x61, 0x65, 0x28b, 0x65, 0x67,
+0x62, 0x65, 0x47, 0x68, 0x61, 0x6e, 0x61, 0x20, 0x6e, 0x75, 0x74, 0x6f, 0x6d, 0x65, 0x54, 0x6f, 0x67, 0x6f, 0x20, 0x6e,
+0x75, 0x74, 0x6f, 0x6d, 0x65, 0x12c8, 0x120b, 0x12ed, 0x1273, 0x1271, 0x2bb, 0x14c, 0x6c, 0x65, 0x6c, 0x6f, 0x20, 0x48, 0x61, 0x77,
+0x61, 0x69, 0x2bb, 0x69, 0x2bb, 0x41, 0x6d, 0x65, 0x6c, 0x69, 0x6b, 0x61, 0x20, 0x48, 0x75, 0x69, 0x20, 0x50, 0x16b, 0x20,
+0x2bb, 0x49, 0x61, 0x46, 0x69, 0x6c, 0x69, 0x70, 0x69, 0x6e, 0x6f, 0x50, 0x69, 0x6c, 0x69, 0x70, 0x69, 0x6e, 0x61, 0x73,
+0x53, 0x63, 0x68, 0x77, 0x69, 0x69, 0x7a, 0x65, 0x72, 0x74, 0xfc, 0xfc, 0x74, 0x73, 0x63, 0x68, 0x53, 0x63, 0x68, 0x77,
+0x69, 0x69, 0x7a, 0xa188, 0xa320, 0xa259, 0xa34f, 0xa1e9, 0x69, 0x73, 0x69, 0x4e, 0x64, 0x65, 0x62, 0x65, 0x6c, 0x65, 0x53, 0x65,
+0x73, 0x6f, 0x74, 0x68, 0x6f, 0x20, 0x73, 0x61, 0x20, 0x4c, 0x65, 0x62, 0x6f, 0x61, 0x64, 0x61, 0x76, 0x76, 0x69, 0x73,
+0xe1, 0x6d, 0x65, 0x67, 0x69, 0x65, 0x6c, 0x6c, 0x61, 0x4e, 0x6f, 0x72, 0x67, 0x61, 0x53, 0x75, 0x6f, 0x70, 0x6d, 0x61,
+0x45, 0x6b, 0x65, 0x67, 0x75, 0x73, 0x69, 0x69, 0x4b, 0x69, 0x74, 0x61, 0x69, 0x74, 0x61, 0x50, 0x75, 0x6c, 0x61, 0x61,
+0x72, 0x53, 0x65, 0x6e, 0x65, 0x67, 0x61, 0x61, 0x6c, 0x47, 0x69, 0x6b, 0x75, 0x79, 0x75, 0x4b, 0x69, 0x73, 0x61, 0x6d,
+0x70, 0x75, 0x72, 0x73, 0x65, 0x6e, 0x61, 0x4b, 0x69, 0x68, 0x6f, 0x72, 0x6f, 0x6d, 0x62, 0x6f, 0x2d5c, 0x2d30, 0x2d4e, 0x2d30,
+0x2d63, 0x2d49, 0x2d56, 0x2d5c, 0x2d4d, 0x2d4e, 0x2d56, 0x2d54, 0x2d49, 0x2d31, 0x74, 0x61, 0x6d, 0x61, 0x7a, 0x69, 0x67, 0x68, 0x74, 0x6c,
+0x6d, 0x263, 0x72, 0x69, 0x62, 0x54, 0x61, 0x71, 0x62, 0x61, 0x79, 0x6c, 0x69, 0x74, 0x4c, 0x65, 0x7a, 0x7a, 0x61, 0x79,
+0x65, 0x72, 0x52, 0x75, 0x6e, 0x79, 0x61, 0x6e, 0x6b, 0x6f, 0x72, 0x65, 0x48, 0x69, 0x62, 0x65, 0x6e, 0x61, 0x48, 0x75,
+0x74, 0x61, 0x6e, 0x7a, 0x61, 0x6e, 0x69, 0x61, 0x4b, 0x79, 0x69, 0x76, 0x75, 0x6e, 0x6a, 0x6f, 0x62, 0x61, 0x6d, 0x61,
+0x6e, 0x61, 0x6b, 0x61, 0x6e, 0x4b, 0x129, 0x65, 0x6d, 0x62, 0x75, 0x13e3, 0x13b3, 0x13a9, 0x13a0, 0x13b9, 0x13f0, 0x13df, 0x6b, 0x72,
+0x65, 0x6f, 0x6c, 0x20, 0x6d, 0x6f, 0x72, 0x69, 0x73, 0x69, 0x65, 0x6e, 0x4d, 0x6f, 0x72, 0x69, 0x73, 0x43, 0x68, 0x69,
+0x6d, 0x61, 0x6b, 0x6f, 0x6e, 0x64, 0x65, 0x4b, 0x268, 0x6c, 0x61, 0x61, 0x6e, 0x67, 0x69, 0x54, 0x61, 0x61, 0x6e, 0x73,
+0x61, 0x6e, 0xed, 0x61, 0x4c, 0x75, 0x67, 0x61, 0x6e, 0x64, 0x61, 0x59, 0x75, 0x67, 0x61, 0x6e, 0x64, 0x61, 0x49, 0x63,
+0x68, 0x69, 0x62, 0x65, 0x6d, 0x62, 0x61, 0x6b, 0x61, 0x62, 0x75, 0x76, 0x65, 0x72, 0x64, 0x69, 0x61, 0x6e, 0x75, 0x4b,
+0x61, 0x62, 0x75, 0x20, 0x56, 0x65, 0x72, 0x64, 0x69, 0x4b, 0x129, 0x6d, 0x129, 0x72, 0x169, 0x4b, 0x61, 0x6c, 0x65, 0x6e,
+0x6a, 0x69, 0x6e, 0x45, 0x6d, 0x65, 0x74, 0x61, 0x62, 0x20, 0x4b, 0x65, 0x6e, 0x79, 0x61, 0x4b, 0x68, 0x6f, 0x65, 0x6b,
+0x68, 0x6f, 0x65, 0x67, 0x6f, 0x77, 0x61, 0x62, 0x4e, 0x61, 0x6d, 0x69, 0x62, 0x69, 0x61, 0x62, 0x4b, 0x69, 0x6d, 0x61,
+0x63, 0x68, 0x61, 0x6d, 0x65, 0x4b, 0xf6, 0x6c, 0x73, 0x63, 0x68, 0x44, 0x6f, 0xfc, 0x74, 0x73, 0x63, 0x68, 0x6c, 0x61,
+0x6e, 0x64, 0x4d, 0x61, 0x61, 0x54, 0x61, 0x6e, 0x73, 0x61, 0x6e, 0x69, 0x61, 0x4f, 0x6c, 0x75, 0x73, 0x6f, 0x67, 0x61,
+0x4c, 0x75, 0x6c, 0x75, 0x68, 0x69, 0x61, 0x4b, 0x69, 0x70, 0x61, 0x72, 0x65, 0x54, 0x61, 0x64, 0x68, 0x61, 0x6e, 0x69,
+0x61, 0x4b, 0x69, 0x74, 0x65, 0x73, 0x6f, 0x4b, 0x65, 0x6e, 0x69, 0x61, 0x4b, 0x6f, 0x79, 0x72, 0x61, 0x20, 0x63, 0x69,
+0x69, 0x6e, 0x69, 0x4d, 0x61, 0x61, 0x6c, 0x69, 0x4b, 0x69, 0x72, 0x75, 0x77, 0x61, 0x44, 0x68, 0x6f, 0x6c, 0x75, 0x6f,
+0x52, 0x75, 0x6b, 0x69, 0x67, 0x61, 0x54, 0x61, 0x6d, 0x61, 0x7a, 0x69, 0x263, 0x74, 0x4d, 0x65, 0x1e5b, 0x1e5b, 0x75, 0x6b,
+0x4b, 0x6f, 0x79, 0x72, 0x61, 0x62, 0x6f, 0x72, 0x6f, 0x20, 0x73, 0x65, 0x6e, 0x6e, 0x69, 0x4b, 0x69, 0x73, 0x68, 0x61,
+0x6d, 0x62, 0x61, 0x61, 0x92c, 0x921, 0x93c, 0x94b, 0x54, 0x73, 0x68, 0x69, 0x6c, 0x75, 0x62, 0x61, 0x44, 0x69, 0x74, 0x75,
+0x6e, 0x67, 0x61, 0x20, 0x77, 0x61, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x75, 0x41, 0x67, 0x68, 0x65, 0x6d, 0x4b, 0xe0, 0x6d,
+0xe0, 0x6c, 0xfb, 0x14b, 0x181, 0xe0, 0x73, 0xe0, 0x61, 0x4b, 0xe0, 0x6d, 0x25b, 0x300, 0x72, 0xfb, 0x6e, 0x5a, 0x61, 0x72,
+0x6d, 0x61, 0x63, 0x69, 0x69, 0x6e, 0x65, 0x4e, 0x69, 0x17e, 0x65, 0x72, 0x64, 0x75, 0xe1, 0x6c, 0xe1, 0x6a, 0x6f, 0x6f,
+0x6c, 0x61, 0x53, 0x65, 0x6e, 0x65, 0x67, 0x61, 0x6c, 0x65, 0x77, 0x6f, 0x6e, 0x64, 0x6f, 0x4b, 0x61, 0x6d, 0x259, 0x72,
+0xfa, 0x6e, 0x72, 0x69, 0x6b, 0x70, 0x61, 0x6b, 0x61, 0x6d, 0x25b, 0x72, 0xfa, 0x6e, 0x4d, 0x61, 0x6b, 0x75, 0x61, 0x55,
+0x6d, 0x6f, 0x7a, 0x61, 0x6d, 0x62, 0x69, 0x6b, 0x69, 0x4d, 0x55, 0x4e, 0x44, 0x41, 0x14a, 0x6b, 0x61, 0x6d, 0x65, 0x72,
+0x75, 0x14b, 0x4b, 0x77, 0x61, 0x73, 0x69, 0x6f, 0x4b, 0x61, 0x6d, 0x65, 0x72, 0x75, 0x6e, 0x54, 0x68, 0x6f, 0x6b, 0x20,
+0x4e, 0x61, 0x74, 0x68, 0x53, 0x75, 0x64, 0x61, 0x6e, 0x441, 0x430, 0x445, 0x430, 0x20, 0x442, 0x44b, 0x43b, 0x430, 0x49, 0x73,
+0x68, 0x69, 0x73, 0x61, 0x6e, 0x67, 0x75, 0x54, 0x61, 0x6e, 0x73, 0x61, 0x6e, 0x69, 0x79, 0x61, 0x4b, 0x69, 0x73, 0x77,
+0x61, 0x68, 0x69, 0x6c, 0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x6f, 0x4a, 0x61, 0x6d, 0x68, 0x75, 0x72,
+0x69, 0x20, 0x79, 0x61, 0x20, 0x4b, 0x69, 0x64, 0x65, 0x6d, 0x6f, 0x6b, 0x72, 0x61, 0x73, 0x69, 0x61, 0x20, 0x79, 0x61,
+0x20, 0x4b, 0x6f, 0x6e, 0x67, 0x6f, 0x54, 0x61, 0x73, 0x61, 0x77, 0x61, 0x71, 0x20, 0x73, 0x65, 0x6e, 0x6e, 0x69, 0xa559,
+0xa524, 0xa55e, 0xa524, 0xa52b, 0xa569, 0x56, 0x61, 0x69, 0x4c, 0x61, 0x69, 0x62, 0x68, 0x69, 0x79, 0x61, 0x57, 0x61, 0x6c, 0x73,
+0x65, 0x72, 0x53, 0x63, 0x68, 0x77, 0x69, 0x7a, 0x6e, 0x75, 0x61, 0x73, 0x75, 0x65, 0x4b, 0x65, 0x6d, 0x65, 0x6c, 0xfa,
+0x6e, 0x61, 0x73, 0x74, 0x75, 0x72, 0x69, 0x61, 0x6e, 0x75, 0x4e, 0x64, 0x61, 0xa78c, 0x61, 0x4b, 0x61, 0x6d, 0x25b, 0x6c,
+0xfb, 0x6e, 0x6b, 0x61, 0x6b, 0x254, 0x4b, 0x61, 0x6d, 0x25b, 0x72, 0x75, 0x6e, 0x6d, 0x65, 0x74, 0x61, 0x2bc, 0x4b, 0x61,
+0x6d, 0x61, 0x6c, 0x75, 0x6e, 0x53, 0x68, 0x77, 0xf3, 0x14b, 0xf2, 0x20, 0x6e, 0x67, 0x69, 0x65, 0x6d, 0x62, 0x254, 0x254,
+0x6e, 0x4b, 0xe0, 0x6d, 0x61, 0x6c, 0xfb, 0x6d
};
static const char language_name_list[] =
@@ -5275,7 +5590,7 @@ static const char language_name_list[] =
"Turkish\0"
"Turkmen\0"
"Tahitian\0"
-"Uigur\0"
+"Uighur\0"
"Ukrainian\0"
"Urdu\0"
"Uzbek\0"
@@ -5408,6 +5723,57 @@ static const char language_name_list[] =
"Kako\0"
"Meta\0"
"Ngiemboon\0"
+"Aragonese\0"
+"Akkadian\0"
+"AncientEgyptian\0"
+"AncientGreek\0"
+"Aramaic\0"
+"Balinese\0"
+"Bamun\0"
+"BatakToba\0"
+"Buginese\0"
+"Buhid\0"
+"Carian\0"
+"Chakma\0"
+"ClassicalMandaic\0"
+"Coptic\0"
+"Dogri\0"
+"EasternCham\0"
+"EasternKayah\0"
+"Etruscan\0"
+"Gothic\0"
+"Hanunoo\0"
+"Ingush\0"
+"LargeFloweryMiao\0"
+"Lepcha\0"
+"Limbu\0"
+"Lisu\0"
+"Lu\0"
+"Lycian\0"
+"Lydian\0"
+"Mandingo\0"
+"Manipuri\0"
+"Meroitic\0"
+"NorthernThai\0"
+"OldIrish\0"
+"OldNorse\0"
+"OldPersian\0"
+"OldTurkish\0"
+"Pahlavi\0"
+"Parthian\0"
+"Phoenician\0"
+"PrakritLanguage\0"
+"Rejang\0"
+"Sabaean\0"
+"Samaritan\0"
+"Santali\0"
+"Saurashtra\0"
+"Sora\0"
+"Sylheti\0"
+"Tagbanwa\0"
+"TaiDam\0"
+"TaiNua\0"
+"Ugaritic\0"
;
static const quint16 language_name_index[] = {
@@ -5539,139 +5905,190 @@ static const quint16 language_name_index[] = {
1023, // Turkish
1031, // Turkmen
1039, // Tahitian
- 1048, // Uigur
- 1054, // Ukrainian
- 1064, // Urdu
- 1069, // Uzbek
- 1075, // Vietnamese
- 1086, // Volapuk
- 1094, // Welsh
- 1100, // Wolof
- 1106, // Xhosa
- 1112, // Yiddish
- 1120, // Yoruba
- 1127, // Zhuang
- 1134, // Zulu
- 1139, // NorwegianNynorsk
- 1156, // Bosnian
- 1164, // Divehi
- 1171, // Manx
- 1176, // Cornish
- 1184, // Akan
- 1189, // Konkani
- 1197, // Ga
- 1200, // Igbo
- 1205, // Kamba
- 1211, // Syriac
- 1218, // Blin
- 1223, // Geez
- 1228, // Koro
- 1233, // Sidamo
- 1240, // Atsam
- 1246, // Tigre
- 1252, // Jju
- 1256, // Friulian
- 1265, // Venda
- 1271, // Ewe
- 1275, // Walamo
- 1282, // Hawaiian
- 1291, // Tyap
- 1296, // Nyanja
- 1303, // Filipino
- 1312, // Swiss German
- 1325, // Sichuan Yi
- 1336, // Kpelle
- 1343, // Low German
- 1354, // South Ndebele
- 1368, // Northern Sotho
- 1383, // Northern Sami
- 1397, // Taroko
- 1404, // Gusii
- 1410, // Taita
- 1416, // Fulah
- 1422, // Kikuyu
- 1429, // Samburu
- 1437, // Sena
- 1442, // North Ndebele
- 1456, // Rombo
- 1462, // Tachelhit
- 1472, // Kabyle
- 1479, // Nyankole
- 1488, // Bena
- 1493, // Vunjo
- 1499, // Bambara
- 1507, // Embu
- 1512, // Cherokee
- 1521, // Morisyen
- 1530, // Makonde
- 1538, // Langi
- 1544, // Ganda
- 1550, // Bemba
- 1556, // Kabuverdianu
- 1569, // Meru
- 1574, // Kalenjin
- 1583, // Nama
- 1588, // Machame
- 1596, // Colognian
- 1606, // Masai
- 1612, // Soga
- 1617, // Luyia
- 1623, // Asu
- 1627, // Teso
- 1632, // Saho
- 1637, // Koyra Chiini
- 1650, // Rwa
- 1654, // Luo
- 1658, // Chiga
- 1664, // Central Morocco Tamazight
- 1690, // Koyraboro Senni
- 1706, // Shambala
- 1715, // Bodo
- 1720, // Avaric
- 1727, // Chamorro
- 1736, // Chechen
- 1744, // Church
- 1751, // Chuvash
- 1759, // Cree
- 1764, // Haitian
- 1772, // Herero
- 1779, // Hiri Motu
- 1789, // Kanuri
- 1796, // Komi
- 1801, // Kongo
- 1807, // Kwanyama
- 1816, // Limburgish
- 1827, // LubaKatanga
- 1839, // Luxembourgish
- 1853, // Navaho
- 1860, // Ndonga
- 1867, // Ojibwa
- 1874, // Pali
- 1879, // Walloon
- 1887, // Aghem
- 1893, // Basaa
- 1899, // Zarma
- 1905, // Duala
- 1911, // JolaFonyi
- 1921, // Ewondo
- 1928, // Bafia
- 1934, // MakhuwaMeetto
- 1948, // Mundang
- 1956, // Kwasio
- 1963, // Nuer
- 1968, // Sakha
- 1974, // Sangu
- 1980, // Congo Swahili
- 1994, // Tasawaq
- 2002, // Vai
- 2006, // Walser
- 2013, // Yangben
- 2021, // Avestan
- 2029, // Asturian
- 2038, // Ngomba
- 2045, // Kako
- 2050, // Meta
- 2055, // Ngiemboon
+ 1048, // Uighur
+ 1055, // Ukrainian
+ 1065, // Urdu
+ 1070, // Uzbek
+ 1076, // Vietnamese
+ 1087, // Volapuk
+ 1095, // Welsh
+ 1101, // Wolof
+ 1107, // Xhosa
+ 1113, // Yiddish
+ 1121, // Yoruba
+ 1128, // Zhuang
+ 1135, // Zulu
+ 1140, // NorwegianNynorsk
+ 1157, // Bosnian
+ 1165, // Divehi
+ 1172, // Manx
+ 1177, // Cornish
+ 1185, // Akan
+ 1190, // Konkani
+ 1198, // Ga
+ 1201, // Igbo
+ 1206, // Kamba
+ 1212, // Syriac
+ 1219, // Blin
+ 1224, // Geez
+ 1229, // Koro
+ 1234, // Sidamo
+ 1241, // Atsam
+ 1247, // Tigre
+ 1253, // Jju
+ 1257, // Friulian
+ 1266, // Venda
+ 1272, // Ewe
+ 1276, // Walamo
+ 1283, // Hawaiian
+ 1292, // Tyap
+ 1297, // Nyanja
+ 1304, // Filipino
+ 1313, // Swiss German
+ 1326, // Sichuan Yi
+ 1337, // Kpelle
+ 1344, // Low German
+ 1355, // South Ndebele
+ 1369, // Northern Sotho
+ 1384, // Northern Sami
+ 1398, // Taroko
+ 1405, // Gusii
+ 1411, // Taita
+ 1417, // Fulah
+ 1423, // Kikuyu
+ 1430, // Samburu
+ 1438, // Sena
+ 1443, // North Ndebele
+ 1457, // Rombo
+ 1463, // Tachelhit
+ 1473, // Kabyle
+ 1480, // Nyankole
+ 1489, // Bena
+ 1494, // Vunjo
+ 1500, // Bambara
+ 1508, // Embu
+ 1513, // Cherokee
+ 1522, // Morisyen
+ 1531, // Makonde
+ 1539, // Langi
+ 1545, // Ganda
+ 1551, // Bemba
+ 1557, // Kabuverdianu
+ 1570, // Meru
+ 1575, // Kalenjin
+ 1584, // Nama
+ 1589, // Machame
+ 1597, // Colognian
+ 1607, // Masai
+ 1613, // Soga
+ 1618, // Luyia
+ 1624, // Asu
+ 1628, // Teso
+ 1633, // Saho
+ 1638, // Koyra Chiini
+ 1651, // Rwa
+ 1655, // Luo
+ 1659, // Chiga
+ 1665, // Central Morocco Tamazight
+ 1691, // Koyraboro Senni
+ 1707, // Shambala
+ 1716, // Bodo
+ 1721, // Avaric
+ 1728, // Chamorro
+ 1737, // Chechen
+ 1745, // Church
+ 1752, // Chuvash
+ 1760, // Cree
+ 1765, // Haitian
+ 1773, // Herero
+ 1780, // Hiri Motu
+ 1790, // Kanuri
+ 1797, // Komi
+ 1802, // Kongo
+ 1808, // Kwanyama
+ 1817, // Limburgish
+ 1828, // LubaKatanga
+ 1840, // Luxembourgish
+ 1854, // Navaho
+ 1861, // Ndonga
+ 1868, // Ojibwa
+ 1875, // Pali
+ 1880, // Walloon
+ 1888, // Aghem
+ 1894, // Basaa
+ 1900, // Zarma
+ 1906, // Duala
+ 1912, // JolaFonyi
+ 1922, // Ewondo
+ 1929, // Bafia
+ 1935, // MakhuwaMeetto
+ 1949, // Mundang
+ 1957, // Kwasio
+ 1964, // Nuer
+ 1969, // Sakha
+ 1975, // Sangu
+ 1981, // Congo Swahili
+ 1995, // Tasawaq
+ 2003, // Vai
+ 2007, // Walser
+ 2014, // Yangben
+ 2022, // Avestan
+ 2030, // Asturian
+ 2039, // Ngomba
+ 2046, // Kako
+ 2051, // Meta
+ 2056, // Ngiemboon
+ 2066, // Aragonese
+ 2076, // Akkadian
+ 2085, // AncientEgyptian
+ 2101, // AncientGreek
+ 2114, // Aramaic
+ 2122, // Balinese
+ 2131, // Bamun
+ 2137, // BatakToba
+ 2147, // Buginese
+ 2156, // Buhid
+ 2162, // Carian
+ 2169, // Chakma
+ 2176, // ClassicalMandaic
+ 2193, // Coptic
+ 2200, // Dogri
+ 2206, // EasternCham
+ 2218, // EasternKayah
+ 2231, // Etruscan
+ 2240, // Gothic
+ 2247, // Hanunoo
+ 2255, // Ingush
+ 2262, // LargeFloweryMiao
+ 2279, // Lepcha
+ 2286, // Limbu
+ 2292, // Lisu
+ 2297, // Lu
+ 2300, // Lycian
+ 2307, // Lydian
+ 2314, // Mandingo
+ 2323, // Manipuri
+ 2332, // Meroitic
+ 2341, // NorthernThai
+ 2354, // OldIrish
+ 2363, // OldNorse
+ 2372, // OldPersian
+ 2383, // OldTurkish
+ 2394, // Pahlavi
+ 2402, // Parthian
+ 2411, // Phoenician
+ 2422, // PrakritLanguage
+ 2438, // Rejang
+ 2445, // Sabaean
+ 2453, // Samaritan
+ 2463, // Santali
+ 2471, // Saurashtra
+ 2482, // Sora
+ 2487, // Sylheti
+ 2495, // Tagbanwa
+ 2504, // TaiDam
+ 2511, // TaiNua
+ 2518, // Ugaritic
};
static const char script_name_list[] =
@@ -5711,6 +6128,75 @@ static const char script_name_list[] =
"Syriac\0"
"Yi\0"
"Vai\0"
+"Avestan\0"
+"Balinese\0"
+"Bamum\0"
+"Batak\0"
+"Bopomofo\0"
+"Brahmi\0"
+"Buginese\0"
+"Buhid\0"
+"CanadianAboriginal\0"
+"Carian\0"
+"Chakma\0"
+"Cham\0"
+"Coptic\0"
+"Cypriot\0"
+"Egyptian Hieroglyphs\0"
+"Fraser\0"
+"Glagolitic\0"
+"Gothic\0"
+"Han\0"
+"Hangul\0"
+"Hanunoo\0"
+"Imperial Aramaic\0"
+"Inscriptional Pahlavi\0"
+"Inscriptional Parthian\0"
+"Javanese\0"
+"Kaithi\0"
+"Katakana\0"
+"Kayah Li\0"
+"Kharoshthi\0"
+"Lanna\0"
+"Lepcha\0"
+"Limbu\0"
+"Linear B\0"
+"Lycian\0"
+"Lydian\0"
+"Mandaean\0"
+"Meitei Mayek\0"
+"Meroitic\0"
+"Meroitic Cursive\0"
+"Nko\0"
+"New Tai Lue\0"
+"Ogham\0"
+"Ol Chiki\0"
+"Old Italic\0"
+"Old Persian\0"
+"Old South Arabian\0"
+"Orkhon\0"
+"Osmanya\0"
+"Phags Pa\0"
+"Phoenician\0"
+"Pollard Phonetic\0"
+"Rejang\0"
+"Runic\0"
+"Samaritan\0"
+"Saurashtra\0"
+"Sharada\0"
+"Shavian\0"
+"Sora Sompeng\0"
+"Cuneiform\0"
+"Sundanese\0"
+"Syloti Nagri\0"
+"Tagalog\0"
+"Tagbanwa\0"
+"Tai Le\0"
+"Tai Viet\0"
+"Takri\0"
+"Ugaritic\0"
+"Braille\0"
+"Hiragana\0"
;
static const quint16 script_name_index[] = {
@@ -5750,6 +6236,75 @@ static const quint16 script_name_index[] = {
273, // Syriac
280, // Yi
283, // Vai
+ 287, // Avestan
+ 295, // Balinese
+ 304, // Bamum
+ 310, // Batak
+ 316, // Bopomofo
+ 325, // Brahmi
+ 332, // Buginese
+ 341, // Buhid
+ 347, // CanadianAboriginal
+ 366, // Carian
+ 373, // Chakma
+ 380, // Cham
+ 385, // Coptic
+ 392, // Cypriot
+ 400, // Egyptian Hieroglyphs
+ 421, // Fraser
+ 428, // Glagolitic
+ 439, // Gothic
+ 446, // Han
+ 450, // Hangul
+ 457, // Hanunoo
+ 465, // Imperial Aramaic
+ 482, // Inscriptional Pahlavi
+ 504, // Inscriptional Parthian
+ 527, // Javanese
+ 536, // Kaithi
+ 543, // Katakana
+ 552, // Kayah Li
+ 561, // Kharoshthi
+ 572, // Lanna
+ 578, // Lepcha
+ 585, // Limbu
+ 591, // Linear B
+ 600, // Lycian
+ 607, // Lydian
+ 614, // Mandaean
+ 623, // Meitei Mayek
+ 636, // Meroitic
+ 645, // Meroitic Cursive
+ 662, // Nko
+ 666, // New Tai Lue
+ 678, // Ogham
+ 684, // Ol Chiki
+ 693, // Old Italic
+ 704, // Old Persian
+ 716, // Old South Arabian
+ 734, // Orkhon
+ 741, // Osmanya
+ 749, // Phags Pa
+ 758, // Phoenician
+ 769, // Pollard Phonetic
+ 786, // Rejang
+ 793, // Runic
+ 799, // Samaritan
+ 809, // Saurashtra
+ 820, // Sharada
+ 828, // Shavian
+ 836, // Sora Sompeng
+ 849, // Cuneiform
+ 859, // Sundanese
+ 869, // Syloti Nagri
+ 882, // Tagalog
+ 890, // Tagbanwa
+ 899, // Tai Le
+ 906, // Tai Viet
+ 915, // Takri
+ 921, // Ugaritic
+ 930, // Braille
+ 938, // Hiragana
};
static const char country_name_list[] =
@@ -6401,7 +6956,7 @@ static const unsigned char language_code_list[] =
"tr\0" // Turkish
"tk\0" // Turkmen
"ty\0" // Tahitian
-"ug\0" // Uigur
+"ug\0" // Uighur
"uk\0" // Ukrainian
"ur\0" // Urdu
"uz\0" // Uzbek
@@ -6534,6 +7089,57 @@ static const unsigned char language_code_list[] =
"kkj" // Kako
"mgo" // Meta
"nnh" // Ngiemboon
+"an\0" // Aragonese
+"akk" // Akkadian
+"egy" // AncientEgyptian
+"grc" // AncientGreek
+"arc" // Aramaic
+"ban" // Balinese
+"bax" // Bamun
+"bbc" // BatakToba
+"bug" // Buginese
+"bku" // Buhid
+"xcr" // Carian
+"ccp" // Chakma
+"myz" // ClassicalMandaic
+"cop" // Coptic
+"doi" // Dogri
+"cjm" // EasternCham
+"eky" // EasternKayah
+"ett" // Etruscan
+"got" // Gothic
+"hnn" // Hanunoo
+"inh" // Ingush
+"hmd" // LargeFloweryMiao
+"lep" // Lepcha
+"lif" // Limbu
+"lis" // Lisu
+"khb" // Lu
+"xlc" // Lycian
+"xld" // Lydian
+"man" // Mandingo
+"mni" // Manipuri
+"xmr" // Meroitic
+"nod" // NorthernThai
+"sga" // OldIrish
+"non" // OldNorse
+"peo" // OldPersian
+"otk" // OldTurkish
+"pal" // Pahlavi
+"xpr" // Parthian
+"phn" // Phoenician
+"pra" // PrakritLanguage
+"rej" // Rejang
+"xsa" // Sabaean
+"smp" // Samaritan
+"sat" // Santali
+"saz" // Saurashtra
+"srb" // Sora
+"syl" // Sylheti
+"tbw" // Tagbanwa
+"blt" // TaiDam
+"tdd" // TaiNua
+"uga" // Ugaritic
;
static const unsigned char script_code_list[] =
@@ -6570,9 +7176,78 @@ static const unsigned char script_code_list[] =
"Thai" // Thai
"Tibt" // Tibetan
"Sinh" // Sinhala
-"Syri" // Syriac
+"Syrc" // Syriac
"Yiii" // Yi
"Vaii" // Vai
+"Avst" // Avestan
+"Bali" // Balinese
+"Bamu" // Bamum
+"Batk" // Batak
+"Bopo" // Bopomofo
+"Brah" // Brahmi
+"Bugi" // Buginese
+"Buhd" // Buhid
+"Cans" // CanadianAboriginal
+"Cari" // Carian
+"Cakm" // Chakma
+"Cham" // Cham
+"Copt" // Coptic
+"Cprt" // Cypriot
+"Egyp" // Egyptian Hieroglyphs
+"Lisu" // Fraser
+"Glag" // Glagolitic
+"Goth" // Gothic
+"Hani" // Han
+"Hang" // Hangul
+"Hano" // Hanunoo
+"Armi" // Imperial Aramaic
+"Phli" // Inscriptional Pahlavi
+"Prti" // Inscriptional Parthian
+"Java" // Javanese
+"Kthi" // Kaithi
+"Kana" // Katakana
+"Kali" // Kayah Li
+"Khar" // Kharoshthi
+"Lana" // Lanna
+"Lepc" // Lepcha
+"Limb" // Limbu
+"Linb" // Linear B
+"Lyci" // Lycian
+"Lydi" // Lydian
+"Mand" // Mandaean
+"Mtei" // Meitei Mayek
+"Mero" // Meroitic
+"Merc" // Meroitic Cursive
+"Nkoo" // Nko
+"Talu" // New Tai Lue
+"Ogam" // Ogham
+"Olck" // Ol Chiki
+"Ital" // Old Italic
+"Xpeo" // Old Persian
+"Sarb" // Old South Arabian
+"Orkh" // Orkhon
+"Osma" // Osmanya
+"Phag" // Phags Pa
+"Phnx" // Phoenician
+"Plrd" // Pollard Phonetic
+"Rjng" // Rejang
+"Runr" // Runic
+"Samr" // Samaritan
+"Saur" // Saurashtra
+"Shrd" // Sharada
+"Shaw" // Shavian
+"Sora" // Sora Sompeng
+"Xsux" // Cuneiform
+"Sund" // Sundanese
+"Sylo" // Syloti Nagri
+"Tglg" // Tagalog
+"Tagb" // Tagbanwa
+"Tale" // Tai Le
+"Tavt" // Tai Viet
+"Takr" // Takri
+"Ugar" // Ugaritic
+"Brai" // Braille
+"Hira" // Hiragana
;
static const unsigned char country_code_list[] =
"ZZ\0" // AnyCountry
diff --git a/src/corelib/tools/qlocale_mac.mm b/src/corelib/tools/qlocale_mac.mm
index 0dc6f389b3..8594cfd40d 100644
--- a/src/corelib/tools/qlocale_mac.mm
+++ b/src/corelib/tools/qlocale_mac.mm
@@ -345,7 +345,6 @@ static QString macFormatCurrency(const QSystemLocale::CurrencyToStringArgument &
static QVariant macQuoteString(QSystemLocale::QueryType type, const QStringRef &str)
{
-#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
if (QSysInfo::MacintoshVersion < QSysInfo::MV_10_6)
return QVariant();
@@ -363,7 +362,6 @@ static QVariant macQuoteString(QSystemLocale::QueryType type, const QStringRef &
default:
break;
}
-#endif
return QVariant();
}
#endif //QT_NO_SYSTEMLOCALE
@@ -434,18 +432,26 @@ QVariant QSystemLocale::query(QueryType type, QVariant in = QVariant()) const
case CurrencyToString:
return macFormatCurrency(in.value<QSystemLocale::CurrencyToStringArgument>());
case UILanguages: {
- QCFType<CFArrayRef> languages = (CFArrayRef)CFPreferencesCopyValue(
+ QCFType<CFPropertyListRef> languages = (CFArrayRef)CFPreferencesCopyValue(
CFSTR("AppleLanguages"),
kCFPreferencesAnyApplication,
kCFPreferencesCurrentUser,
kCFPreferencesAnyHost);
- const int cnt = languages == NULL ? 0 : CFArrayGetCount(languages);
QStringList result;
- result.reserve(cnt);
- for (int i = 0; i < cnt; ++i) {
- const QString lang = QCFString::toQString(
- static_cast<CFStringRef>(CFArrayGetValueAtIndex(languages, i)));
- result.append(lang);
+ CFTypeID typeId = CFGetTypeID(languages);
+ if (typeId == CFArrayGetTypeID()) {
+ const int cnt = CFArrayGetCount(languages.as<CFArrayRef>());
+ result.reserve(cnt);
+ for (int i = 0; i < cnt; ++i) {
+ const QString lang = QCFString::toQString(
+ static_cast<CFStringRef>(CFArrayGetValueAtIndex(languages.as<CFArrayRef>(), i)));
+ result.append(lang);
+ }
+ } else if (typeId == CFStringGetTypeID()) {
+ result = QStringList(QCFString::toQString(languages.as<CFStringRef>()));
+ } else {
+ qWarning("QLocale::uiLanguages(): CFPreferencesCopyValue returned unhandled type \"%s\"; please report to http://bugreports.qt-project.org",
+ qPrintable(QCFString::toQString(CFCopyTypeIDDescription(typeId))));
}
return QVariant(result);
}
diff --git a/src/corelib/tools/qlocale_p.h b/src/corelib/tools/qlocale_p.h
index 3746cd56e6..4c0432bba7 100644
--- a/src/corelib/tools/qlocale_p.h
+++ b/src/corelib/tools/qlocale_p.h
@@ -59,10 +59,6 @@
#include "qlocale.h"
-#if defined(Q_OS_BLACKBERRY)
-#include "qsocketnotifier.h"
-#endif
-
QT_BEGIN_NAMESPACE
#ifndef QT_NO_SYSTEMLOCALE
@@ -238,10 +234,14 @@ public:
QString bcp47Name() const;
- QString languageCode() const; // ### QByteArray::fromRawData would be more optimal
- QString scriptCode() const;
- QString countryCode() const;
+ // ### QByteArray::fromRawData would be more optimal
+ inline QString languageCode() const { return QLocalePrivate::languageToCode(QLocale::Language(m_data->m_language_id)); }
+ inline QString scriptCode() const { return QLocalePrivate::scriptToCode(QLocale::Script(m_data->m_script_id)); }
+ inline QString countryCode() const { return QLocalePrivate::countryToCode(QLocale::Country(m_data->m_country_id)); }
+ static QString languageToCode(QLocale::Language language);
+ static QString scriptToCode(QLocale::Script script);
+ static QString countryToCode(QLocale::Country country);
static QLocale::Language codeToLanguage(const QString &code);
static QLocale::Script codeToScript(const QString &code);
static QLocale::Country codeToCountry(const QString &code);
@@ -311,13 +311,17 @@ public:
qint64 stringToLongLong(const QString &num, int base, bool *ok, GroupSeparatorMode group_sep_mode) const;
quint64 stringToUnsLongLong(const QString &num, int base, bool *ok, GroupSeparatorMode group_sep_mode) const;
+ double stringToDouble(const QStringRef &num, bool *ok, GroupSeparatorMode group_sep_mode) const;
+ qint64 stringToLongLong(const QStringRef &num, int base, bool *ok, GroupSeparatorMode group_sep_mode) const;
+ quint64 stringToUnsLongLong(const QStringRef &num, int base, bool *ok, GroupSeparatorMode group_sep_mode) const;
+
static double bytearrayToDouble(const char *num, bool *ok, bool *overflow = 0);
static qint64 bytearrayToLongLong(const char *num, int base, bool *ok, bool *overflow = 0);
static quint64 bytearrayToUnsLongLong(const char *num, int base, bool *ok);
typedef QVarLengthArray<char, 256> CharBuff;
- bool numberToCLocale(const QString &num,
+ bool numberToCLocale(const QChar *str, int len,
GroupSeparatorMode group_sep_mode,
CharBuff *result) const;
inline char digitToCLocale(QChar c) const;
@@ -373,28 +377,6 @@ inline char QLocalePrivate::digitToCLocale(QChar in) const
return 0;
}
-#if defined(Q_OS_BLACKBERRY)
-class QQNXLocaleData: public QObject
-{
- Q_OBJECT
-public:
- QQNXLocaleData();
- virtual ~QQNXLocaleData();
-
-public Q_SLOTS:
- void updateMeasurementSystem();
- void installSocketNotifier();
-
-private:
- void initialize();
-
-public:
- uint ppsMeasurement;
- QSocketNotifier *ppsNotifier;
- int ppsFd;
-};
-#endif
-
QString qt_readEscapedFormatString(const QString &format, int *idx);
bool qt_splitLocaleName(const QString &name, QString &lang, QString &script, QString &cntry);
int qt_repeatCount(const QString &s, int i);
diff --git a/src/corelib/tools/qlocale_unix.cpp b/src/corelib/tools/qlocale_unix.cpp
index fb9e3f1a8b..4e443cd79b 100644
--- a/src/corelib/tools/qlocale_unix.cpp
+++ b/src/corelib/tools/qlocale_unix.cpp
@@ -47,99 +47,8 @@
#include "qvariant.h"
#include "qreadwritelock.h"
-#if defined(Q_OS_BLACKBERRY)
-#include <QtCore/private/qcore_unix_p.h>
-#include <QCoreApplication>
-
-#include <unistd.h>
-#include <errno.h>
-#include <sys/pps.h>
-#endif
-
QT_BEGIN_NAMESPACE
-#if defined(Q_OS_BLACKBERRY)
-static const char ppsServicePath[] = "/pps/services/locale/uom";
-static const size_t ppsBufferSize = 256;
-
-QQNXLocaleData::QQNXLocaleData()
- :ppsNotifier(0)
- ,ppsFd(-1)
-{
- initialize();
-
- // we cannot call this directly, because by the time this constructor is
- // called, the event dispatcher has not yet been created, causing the
- // subsequent call to QSocketNotifier constructor to fail.
- QMetaObject::invokeMethod(this, "installSocketNotifier", Qt::QueuedConnection);
-}
-
-QQNXLocaleData::~QQNXLocaleData()
-{
- if (ppsFd != -1)
- qt_safe_close(ppsFd);
-}
-
-void QQNXLocaleData::updateMeasurementSystem()
-{
- char buffer[ppsBufferSize];
-
- errno = 0;
- int bytes = qt_safe_read(ppsFd, buffer, ppsBufferSize - 1);
- if (bytes == -1) {
- qWarning("Failed to read Locale pps, errno=%d", errno);
- return;
- }
- // ensure data is null terminated
- buffer[bytes] = '\0';
-
- pps_decoder_t ppsDecoder;
- pps_decoder_initialize(&ppsDecoder, 0);
- if (pps_decoder_parse_pps_str(&ppsDecoder, buffer) == PPS_DECODER_OK) {
- pps_decoder_push(&ppsDecoder, 0);
- const char *measurementBuff;
- if (pps_decoder_get_string(&ppsDecoder, "uom", &measurementBuff) == PPS_DECODER_OK) {
- if (qstrcmp(measurementBuff, "imperial") == 0) {
- pps_decoder_cleanup(&ppsDecoder);
- ppsMeasurement = QLocale::ImperialSystem;
- return;
- }
- }
- }
-
- pps_decoder_cleanup(&ppsDecoder);
- ppsMeasurement = QLocale::MetricSystem;
-}
-
-void QQNXLocaleData::initialize()
-{
- errno = 0;
- ppsFd = qt_safe_open(ppsServicePath, O_RDONLY);
- if (ppsFd == -1) {
- qWarning("Failed to open Locale pps, errno=%d", errno);
- return;
- }
-
- updateMeasurementSystem();
-}
-
-void QQNXLocaleData::installSocketNotifier()
-{
- if (!QCoreApplication::instance() || ppsFd == -1) {
- qWarning("QQNXLocaleData: Failed to create socket notifier, locale updates may not work.");
- return;
- }
-
- if (ppsNotifier) {
- qWarning("QQNXLocaleData: socket notifier already created.");
- return;
- }
-
- ppsNotifier = new QSocketNotifier(ppsFd, QSocketNotifier::Read, this);
- QObject::connect(ppsNotifier, SIGNAL(activated(int)), this, SLOT(updateMeasurementSystem()));
-}
-#endif
-
#ifndef QT_NO_SYSTEMLOCALE
struct QSystemLocaleData
{
@@ -194,11 +103,7 @@ void QSystemLocaleData::readEnvironment()
lc_messages = QLocale(QString::fromLatin1(lc_messages_var));
}
-
Q_GLOBAL_STATIC(QSystemLocaleData, qSystemLocaleData)
-#if defined(Q_OS_BLACKBERRY)
- Q_GLOBAL_STATIC(QQNXLocaleData, qqnxLocaleData)
-#endif
#endif
@@ -230,9 +135,6 @@ QLocale QSystemLocale::fallbackUiLocale() const
QVariant QSystemLocale::query(QueryType type, QVariant in) const
{
QSystemLocaleData *d = qSystemLocaleData();
-#if defined(Q_OS_BLACKBERRY)
- QQNXLocaleData *qnxd = qqnxLocaleData();
-#endif
if (type == LocaleChanged) {
d->readEnvironment();
@@ -320,9 +222,6 @@ QVariant QSystemLocale::query(QueryType type, QVariant in) const
return QLocale::MetricSystem;
if (meas_locale.compare(QLatin1String("Other"), Qt::CaseInsensitive) == 0)
return QLocale::MetricSystem;
-#if defined(Q_OS_BLACKBERRY)
- return qnxd->ppsMeasurement;
-#endif
return QVariant((int)QLocale(meas_locale).measurementSystem());
}
case UILanguages: {
diff --git a/src/corelib/tools/qmap.cpp b/src/corelib/tools/qmap.cpp
index 75104e4825..e5de4a1bfd 100644
--- a/src/corelib/tools/qmap.cpp
+++ b/src/corelib/tools/qmap.cpp
@@ -538,6 +538,16 @@ void QMapDataBase::freeData(QMapDataBase *d)
\sa toStdMap()
*/
+/*! \fn QMap::QMap(std::initializer_list<std::pair<Key,T> > list)
+ \since 5.1
+
+ Constructs a map with a copy of each of the elements in the
+ initializer list \a list.
+
+ This function is only available if the program is being
+ compiled in C++11 mode.
+*/
+
/*! \fn std::map<Key, T> QMap::toStdMap() const
Returns an STL map equivalent to this QMap.
@@ -971,6 +981,32 @@ void QMapDataBase::freeData(QMapDataBase *d)
\sa insertMulti()
*/
+/*! \fn QMap::iterator QMap::insert(const_iterator pos, const Key &key, const T &value)
+ \overload
+ \since 5.1
+ Inserts a new item with the key \a key and value \a value and with hint \a pos
+ suggesting where to do the insert.
+
+ If constBegin() is used as hint it indicates that the \a key is less than any key in the map
+ while constEnd() suggests that the \a key is (strictly) larger than any key in the map.
+ Otherwise the hint should meet the condition (\a pos - 1).key() < \a key <= pos.key().
+ If the hint \a pos is wrong it is ignored and a regular insert is done.
+
+ If there is already an item with the key \a key, that item's value
+ is replaced with \a value.
+
+ If there are multiple items with the key \a key, then exactly one of them
+ is replaced with \a value.
+
+ When creating a map from sorted data inserting the largest key first with constBegin()
+ is faster than inserting in sorted order with constEnd()
+
+ \b {Note:} Be careful with the hint. Providing an iterator from an older shared instance might
+ crash but there is also a risk that it will silently corrupt both the map and the \a pos map.
+
+ \sa insertMulti()
+*/
+
/*! \fn QMap::iterator QMap::insertMulti(const Key &key, const T &value)
Inserts a new item with the key \a key and a value of \a value.
@@ -983,6 +1019,26 @@ void QMapDataBase::freeData(QMapDataBase *d)
\sa insert(), values()
*/
+/*! \fn QMap::iterator QMap::insertMulti(const_iterator pos, const Key &key, const T &value)
+ \overload
+ \since 5.1
+ Inserts a new item with the key \a key and value \a value and with hint \a pos
+ suggesting where to do the insert.
+
+ If constBegin() is used as hint it indicates that the \a key is less than any key in the map
+ while constEnd() suggests that the \a key is larger than any key in the map.
+ Otherwise the hint should meet the condition (\a pos - 1).key() < \a key <= pos.key().
+ If the hint \a pos is wrong it is ignored and a regular insertMulti is done.
+
+ If there is already an item with the same key in the map, this function will simply create a new one.
+
+ \b {Note:} Be careful with the hint. Providing an iterator from an older shared instance might
+ crash but there is also a risk that it will silently corrupt both the map and the \a pos map.
+
+ \sa insert()
+*/
+
+
/*! \fn QMap<Key, T> &QMap::unite(const QMap<Key, T> &other)
Inserts all the items in the \a other map into this map. If a
@@ -1576,6 +1632,16 @@ void QMapDataBase::freeData(QMapDataBase *d)
Constructs an empty map.
*/
+/*! \fn QMultiMap::QMultiMap(std::initializer_list<std::pair<Key,T> > list)
+ \since 5.1
+
+ Constructs a multi map with a copy of each of the elements in the
+ initializer list \a list.
+
+ This function is only available if the program is being
+ compiled in C++11 mode.
+*/
+
/*! \fn QMultiMap::QMultiMap(const QMap<Key, T> &other)
Constructs a copy of \a other (which can be a QMap or a
@@ -1609,6 +1675,23 @@ void QMapDataBase::freeData(QMapDataBase *d)
\sa replace()
*/
+/*! \fn QMultiMap::iterator QMultiMap::insert(QMap<Key, T>::const_iterator pos, const Key &key, const T &value)
+
+ \since 5.1
+ Inserts a new item with the key \a key and value \a value and with hint \a pos
+ suggesting where to do the insert.
+
+ If constBegin() is used as hint it indicates that the \a key is less than any key in the map
+ while constEnd() suggests that the \a key is larger than any key in the map.
+ Otherwise the hint should meet the condition (\a pos - 1).key() < \a key <= pos.key().
+ If the hint \a pos is wrong it is ignored and a regular insert is done.
+
+ If there is already an item with the same key in the map, this function will simply create a new one.
+
+ \b {Note:} Be careful with the hint. Providing an iterator from an older shared instance might
+ crash but there is also a risk that it will silently corrupt both the map and the \a pos map.
+*/
+
/*! \fn QMultiMap &QMultiMap::operator+=(const QMultiMap &other)
Inserts all the items in the \a other map into this map and
diff --git a/src/corelib/tools/qmap.h b/src/corelib/tools/qmap.h
index b0ec6fb3c6..449fcbca0a 100644
--- a/src/corelib/tools/qmap.h
+++ b/src/corelib/tools/qmap.h
@@ -54,7 +54,9 @@
#include <map>
#include <new>
-QT_BEGIN_HEADER
+#ifdef Q_COMPILER_INITIALIZER_LISTS
+#include <initializer_list>
+#endif
QT_BEGIN_NAMESPACE
@@ -327,6 +329,14 @@ class QMap
public:
inline QMap() : d(static_cast<QMapData<Key, T> *>(const_cast<QMapDataBase *>(&QMapDataBase::shared_null))) { }
+#ifdef Q_COMPILER_INITIALIZER_LISTS
+ inline QMap(std::initializer_list<std::pair<Key,T> > list)
+ : d(static_cast<QMapData<Key, T> *>(const_cast<QMapDataBase *>(&QMapDataBase::shared_null)))
+ {
+ for (typename std::initializer_list<std::pair<Key,T> >::const_iterator it = list.begin(); it != list.end(); ++it)
+ insert(it->first, it->second);
+ }
+#endif
QMap(const QMap<Key, T> &other);
inline ~QMap() { if (!d->ref.deref()) d->destroy(); }
@@ -528,7 +538,9 @@ public:
iterator upperBound(const Key &key);
const_iterator upperBound(const Key &key) const;
iterator insert(const Key &key, const T &value);
+ iterator insert(const_iterator pos, const Key &key, const T &value);
iterator insertMulti(const Key &key, const T &value);
+ iterator insertMulti(const_iterator pos, const Key &akey, const T &avalue);
QMap<Key, T> &unite(const QMap<Key, T> &other);
// STL compatibility
@@ -653,6 +665,72 @@ Q_INLINE_TEMPLATE typename QMap<Key, T>::iterator QMap<Key, T>::insert(const Key
}
template <class Key, class T>
+typename QMap<Key, T>::iterator QMap<Key, T>::insert(const_iterator pos, const Key &akey, const T &avalue)
+{
+ if (d->ref.isShared())
+ return this->insert(akey, avalue);
+
+ if (pos == constEnd()) {
+ // Hint is that the Node is larger than (or equal to) the largest value.
+ Node *n = static_cast<Node *>(pos.i->left);
+ if (n) {
+ while (n->right)
+ n = static_cast<Node *>(n->right);
+
+ if (!qMapLessThanKey(n->key, akey))
+ return this->insert(akey, avalue); // ignore hint
+ // This can be optimized by checking equal too.
+ // we can overwrite if previous node key is strictly smaller
+ // (or there is no previous node)
+
+ Node *z = d->createNode(akey, avalue, n, false); // insert right most
+ return iterator(z);
+ }
+ return this->insert(akey, avalue);
+ } else {
+ // Hint indicates that the node should be less (or equal to) the hint given
+ // but larger than the previous value.
+ Node *next = const_cast<Node*>(pos.i);
+ if (qMapLessThanKey(next->key, akey))
+ return this->insert(akey, avalue); // ignore hint
+
+ if (pos == constBegin()) {
+ // There is no previous value
+ // Maybe overwrite left most value
+ if (!qMapLessThanKey(akey, next->key)) {
+ next->value = avalue; // overwrite current iterator
+ return iterator(next);
+ }
+ // insert left most.
+ Node *z = d->createNode(akey, avalue, begin().i, true);
+ return iterator(z);
+ } else {
+ Node *prev = const_cast<Node*>(pos.i->previousNode());
+ if (!qMapLessThanKey(prev->key, akey)) {
+ return this->insert(akey, avalue); // ignore hint
+ }
+ // Hint is ok
+ if (!qMapLessThanKey(akey, next->key)) {
+ next->value = avalue; // overwrite current iterator
+ return iterator(next);
+ }
+
+ // we need to insert (not overwrite)
+ if (prev->right == 0) {
+ Node *z = d->createNode(akey, avalue, prev, false);
+ return iterator(z);
+ }
+ if (next->left == 0) {
+ Node *z = d->createNode(akey, avalue, next, true);
+ return iterator(z);
+ }
+ Q_ASSERT(false); // We should have prev->right == 0 or next->left == 0.
+ return this->insert(akey, avalue);
+ }
+ }
+}
+
+template <class Key, class T>
Q_INLINE_TEMPLATE typename QMap<Key, T>::iterator QMap<Key, T>::insertMulti(const Key &akey,
const T &avalue)
{
@@ -670,6 +748,57 @@ Q_INLINE_TEMPLATE typename QMap<Key, T>::iterator QMap<Key, T>::insertMulti(cons
}
template <class Key, class T>
+typename QMap<Key, T>::iterator QMap<Key, T>::insertMulti(const_iterator pos, const Key &akey, const T &avalue)
+{
+ if (d->ref.isShared())
+ return this->insertMulti(akey, avalue);
+
+ if (pos == constEnd()) {
+ // Hint is that the Node is larger than (or equal to) the largest value.
+ Node *n = static_cast<Node *>(pos.i->left);
+ if (n) {
+ while (n->right)
+ n = static_cast<Node *>(n->right);
+
+ if (!qMapLessThanKey(n->key, akey))
+ return this->insertMulti(akey, avalue); // ignore hint
+ Node *z = d->createNode(akey, avalue, n, false); // insert right most
+ return iterator(z);
+ }
+ return this->insertMulti(akey, avalue);
+ } else {
+ // Hint indicates that the node should be less (or equal to) the hint given
+ // but larger than the previous value.
+ Node *next = const_cast<Node*>(pos.i);
+ if (qMapLessThanKey(next->key, akey))
+ return this->insertMulti(akey, avalue); // ignore hint
+
+ if (pos == constBegin()) {
+ // There is no previous value (insert left most)
+ Node *z = d->createNode(akey, avalue, begin().i, true);
+ return iterator(z);
+ } else {
+ Node *prev = const_cast<Node*>(pos.i->previousNode());
+ if (!qMapLessThanKey(prev->key, akey))
+ return this->insertMulti(akey, avalue); // ignore hint
+
+ // Hint is ok - do insert
+ if (prev->right == 0) {
+ Node *z = d->createNode(akey, avalue, prev, false);
+ return iterator(z);
+ }
+ if (next->left == 0) {
+ Node *z = d->createNode(akey, avalue, next, true);
+ return iterator(z);
+ }
+ Q_ASSERT(false); // We should have prev->right == 0 or next->left == 0.
+ return this->insertMulti(akey, avalue);
+ }
+ }
+}
+
+
+template <class Key, class T>
Q_INLINE_TEMPLATE typename QMap<Key, T>::const_iterator QMap<Key, T>::constFind(const Key &akey) const
{
Node *n = d->findNode(akey);
@@ -960,6 +1089,13 @@ class QMultiMap : public QMap<Key, T>
{
public:
QMultiMap() {}
+#ifdef Q_COMPILER_INITIALIZER_LISTS
+ inline QMultiMap(std::initializer_list<std::pair<Key,T> > list)
+ {
+ for (typename std::initializer_list<std::pair<Key,T> >::const_iterator it = list.begin(); it != list.end(); ++it)
+ insert(it->first, it->second);
+ }
+#endif
QMultiMap(const QMap<Key, T> &other) : QMap<Key, T>(other) {}
inline void swap(QMultiMap<Key, T> &other) { QMap<Key, T>::swap(other); }
@@ -967,6 +1103,8 @@ public:
{ return QMap<Key, T>::insert(key, value); }
inline typename QMap<Key, T>::iterator insert(const Key &key, const T &value)
{ return QMap<Key, T>::insertMulti(key, value); }
+ inline typename QMap<Key, T>::iterator insert(typename QMap<Key, T>::const_iterator pos, const Key &key, const T &value)
+ { return QMap<Key, T>::insertMulti(pos, key, value); }
inline QMultiMap &operator+=(const QMultiMap &other)
{ this->unite(other); return *this; }
@@ -1072,6 +1210,4 @@ Q_DECLARE_MUTABLE_ASSOCIATIVE_ITERATOR(Map)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMAP_H
diff --git a/src/corelib/tools/qmargins.cpp b/src/corelib/tools/qmargins.cpp
index 7b9d68707e..2cdc3f3f03 100644
--- a/src/corelib/tools/qmargins.cpp
+++ b/src/corelib/tools/qmargins.cpp
@@ -51,7 +51,7 @@ QT_BEGIN_NAMESPACE
\ingroup painting
\since 4.6
- \brief The QMargins class defines the four margins of a rectangle.
+ \brief The QMargins class defines the four margins of a rectangle.
QMargin defines a set of four margins; left, top, right and bottom,
that describe the size of the borders surrounding a rectangle.
@@ -157,6 +157,240 @@ QT_BEGIN_NAMESPACE
Returns true if \a m1 and \a m2 are different; otherwise returns false.
*/
+/*!
+ \fn QRect operator+(const QRect &rectangle, const QMargins &margins)
+ \relates QRect
+
+ Returns the \a rectangle grown by the \a margins.
+
+ \since 5.1
+*/
+
+/*!
+ \fn QRect operator+(const QMargins &margins, const QRect &rectangle)
+ \relates QRect
+ \overload
+
+ Returns the \a rectangle grown by the \a margins.
+
+ \since 5.1
+*/
+
+/*!
+ \fn QRect QRect::marginsAdded(const QMargins &margins) const
+
+ Returns a rectangle grown by the \a margins.
+
+ \sa operator+=(), marginsRemoved(), operator-=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn QRect QRect::operator+=(const QMargins &margins) const
+
+ Adds the \a margins to the rectangle, growing it.
+
+ \sa marginsAdded(), marginsRemoved(), operator-=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn QRect QRect::marginsRemoved(const QMargins &margins) const
+
+ Removes the \a margins from the rectangle, shrinking it.
+
+ \sa marginsAdded(), operator+=(), operator-=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn QRect QRect::operator -=(const QMargins &margins) const
+
+ Returns a rectangle shrunk by the \a margins.
+
+ \sa marginsRemoved(), operator+=(), marginsAdded()
+
+ \since 5.1
+*/
+
+/*!
+ \fn const QMargins operator+(const QMargins &m1, const QMargins &m2)
+ \relates QMargins
+
+ Returns a QMargins object that is the sum of the given margins, \a m1
+ and \a m2; each component is added separately.
+
+ \sa QMargins::operator+=(), QMargins::operator-=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn const QMargins operator-(const QMargins &m1, const QMargins &m2)
+ \relates QMargins
+
+ Returns a QMargins object that is formed by subtracting \a m2 from
+ \a m1; each component is subtracted separately.
+
+ \sa QMargins::operator+=(), QMargins::operator-=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn const QMargins operator*(const QMargins &margins, int factor)
+ \relates QMargins
+
+ Returns a QMargins object that is formed by multiplying each component
+ of the given \a margins by \a factor.
+
+ \sa QMargins::operator*=(), QMargins::operator/=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn const QMargins operator*(int factor, const QMargins &margins)
+ \relates QMargins
+ \overload
+
+ Returns a QMargins object that is formed by multiplying each component
+ of the given \a margins by \a factor.
+
+ \sa QMargins::operator*=(), QMargins::operator/=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn const QMargins operator*(const QMargins &margins, qreal factor)
+ \relates QMargins
+ \overload
+
+ Returns a QMargins object that is formed by multiplying each component
+ of the given \a margins by \a factor.
+
+ \sa QMargins::operator*=(), QMargins::operator/=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn const QMargins operator*(qreal factor, const QMargins &margins)
+ \relates QMargins
+ \overload
+
+ Returns a QMargins object that is formed by multiplying each component
+ of the given \a margins by \a factor.
+
+ \sa QMargins::operator*=(), QMargins::operator/=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn const QMargins operator/(const QMargins &margins, int divisor)
+ \relates QMargins
+
+ Returns a QMargins object that is formed by dividing the components of
+ the given \a margins by the given \a divisor.
+
+ \sa QMargins::operator*=(), QMargins::operator/=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn const QMargins operator/(const QMargins &, qreal)
+ \relates QMargins
+ \overload
+
+ Returns a QMargins object that is formed by dividing the components of
+ the given \a margins by the given \a divisor.
+
+ \sa QMargins::operator*=(), QMargins::operator/=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn QMargins operator-(const QMargins &margins)
+ \relates QMargins
+
+ Returns a QMargin object that is formed by negating all components of \a margins.
+
+ \since 5.1
+*/
+
+/*!
+ \fn QMargins &operator+=(const QMargins &margins)
+
+ Add each component of \a margins to the respective component of this object
+ and returns a reference to it.
+
+ \sa operator-=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn QMargins &operator-=(const QMargins &margins)
+
+ Subtract each component of \a margins from the respective component of this object
+ and returns a reference to it.
+
+ \sa operator+=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn QMargins &operator*=(int factor)
+
+ Multiplies each component of this object by \a factor
+ and returns a reference to it.
+
+ \sa operator/=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn QMargins &operator*=(qreal factor)
+ \overload
+
+ Multiplies each component of this object by \a factor
+ and returns a reference to it.
+
+ \sa operator/=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn QMargins &operator/=(int divisor)
+
+ Divides each component of this object by \a divisor
+ and returns a reference to it.
+
+ \sa operator*=()
+
+ \since 5.1
+*/
+
+/*!
+ \fn QMargins &operator/=(qreal divisor)
+
+ \overload
+
+ \sa operator*=()
+
+ \since 5.1
+*/
+
/*****************************************************************************
QMargins stream functions
*****************************************************************************/
diff --git a/src/corelib/tools/qmargins.h b/src/corelib/tools/qmargins.h
index d927cb5aa1..0d68be961e 100644
--- a/src/corelib/tools/qmargins.h
+++ b/src/corelib/tools/qmargins.h
@@ -42,9 +42,7 @@
#ifndef QMARGINS_H
#define QMARGINS_H
-#include <QtCore/qnamespace.h>
-
-QT_BEGIN_HEADER
+#include <QtCore/qrect.h>
QT_BEGIN_NAMESPACE
@@ -67,6 +65,15 @@ public:
void setRight(int right);
void setBottom(int bottom);
+ QMargins &operator+=(const QMargins &margins);
+ QMargins &operator-=(const QMargins &margins);
+ QMargins &operator+=(int);
+ QMargins &operator-=(int);
+ QMargins &operator*=(int);
+ QMargins &operator/=(int);
+ QMargins &operator*=(qreal);
+ QMargins &operator/=(qreal);
+
private:
int m_left;
int m_top;
@@ -142,12 +149,128 @@ Q_DECL_CONSTEXPR inline bool operator!=(const QMargins &m1, const QMargins &m2)
m1.m_bottom != m2.m_bottom;
}
+Q_DECL_CONSTEXPR inline QRect operator+(const QRect &rectangle, const QMargins &margins)
+{
+ return QRect(QPoint(rectangle.left() - margins.left(), rectangle.top() - margins.top()),
+ QPoint(rectangle.right() + margins.right(), rectangle.bottom() + margins.bottom()));
+}
+
+Q_DECL_CONSTEXPR inline QRect operator+(const QMargins &margins, const QRect &rectangle)
+{
+ return QRect(QPoint(rectangle.left() - margins.left(), rectangle.top() - margins.top()),
+ QPoint(rectangle.right() + margins.right(), rectangle.bottom() + margins.bottom()));
+}
+
+inline QRect QRect::marginsAdded(const QMargins &margins) const
+{
+ return *this + margins;
+}
+
+inline QRect QRect::marginsRemoved(const QMargins &margins) const
+{
+ return QRect(QPoint(x1 + margins.left(), y1 + margins.top()),
+ QPoint(x2 - margins.right(), y2 - margins.bottom()));
+}
+
+inline QRect &QRect::operator+=(const QMargins &margins)
+{
+ *this = marginsAdded(margins);
+ return *this;
+}
+
+inline QRect &QRect::operator-=(const QMargins &margins)
+{
+ *this = marginsRemoved(margins);
+ return *this;
+}
+
+Q_DECL_CONSTEXPR inline QMargins operator+(const QMargins &m1, const QMargins &m2)
+{
+ return QMargins(m1.left() + m2.left(), m1.top() + m2.top(),
+ m1.right() + m2.right(), m1.bottom() + m2.bottom());
+}
+
+Q_DECL_CONSTEXPR inline QMargins operator-(const QMargins &m1, const QMargins &m2)
+{
+ return QMargins(m1.left() - m2.left(), m1.top() - m2.top(),
+ m1.right() - m2.right(), m1.bottom() - m2.bottom());
+}
+
+Q_DECL_CONSTEXPR inline QMargins operator*(const QMargins &margins, int factor)
+{
+ return QMargins(margins.left() * factor, margins.top() * factor,
+ margins.right() * factor, margins.bottom() * factor);
+}
+
+Q_DECL_CONSTEXPR inline QMargins operator*(int factor, const QMargins &margins)
+{
+ return QMargins(margins.left() * factor, margins.top() * factor,
+ margins.right() * factor, margins.bottom() * factor);
+}
+
+Q_DECL_CONSTEXPR inline QMargins operator*(const QMargins &margins, qreal factor)
+{
+ return QMargins(qRound(margins.left() * factor), qRound(margins.top() * factor),
+ qRound(margins.right() * factor), qRound(margins.bottom() * factor));
+}
+
+Q_DECL_CONSTEXPR inline QMargins operator*(qreal factor, const QMargins &margins)
+{
+ return QMargins(qRound(margins.left() * factor), qRound(margins.top() * factor),
+ qRound(margins.right() * factor), qRound(margins.bottom() * factor));
+}
+
+Q_DECL_CONSTEXPR inline QMargins operator/(const QMargins &margins, int divisor)
+{
+ return QMargins(margins.left() / divisor, margins.top() / divisor,
+ margins.right() / divisor, margins.bottom() / divisor);
+}
+
+Q_DECL_CONSTEXPR inline QMargins operator/(const QMargins &margins, qreal divisor)
+{
+ return QMargins(qRound(margins.left() / divisor), qRound(margins.top() / divisor),
+ qRound(margins.right() / divisor), qRound(margins.bottom() / divisor));
+}
+
+inline QMargins &QMargins::operator+=(const QMargins &margins)
+{
+ return *this = *this + margins;
+}
+
+inline QMargins &QMargins::operator-=(const QMargins &margins)
+{
+ return *this = *this - margins;
+}
+
+inline QMargins &QMargins::operator*=(int factor)
+{
+ return *this = *this * factor;
+}
+
+inline QMargins &QMargins::operator/=(int divisor)
+{
+ return *this = *this / divisor;
+}
+
+inline QMargins &QMargins::operator*=(qreal factor)
+{
+ return *this = *this * factor;
+}
+
+inline QMargins &QMargins::operator/=(qreal divisor)
+{
+ return *this = *this / divisor;
+}
+
+Q_DECL_CONSTEXPR inline QMargins operator-(const QMargins &margins)
+{
+ return QMargins(-margins.left(), -margins.top(), -margins.right(), -margins.bottom());
+}
+
#ifndef QT_NO_DEBUG_STREAM
Q_CORE_EXPORT QDebug operator<<(QDebug, const QMargins &);
#endif
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMARGINS_H
diff --git a/src/corelib/tools/qmessageauthenticationcode.cpp b/src/corelib/tools/qmessageauthenticationcode.cpp
new file mode 100644
index 0000000000..becaaaa704
--- /dev/null
+++ b/src/corelib/tools/qmessageauthenticationcode.cpp
@@ -0,0 +1,283 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Ruslan Nigmatullin <euroelessar@yandex.ru>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qmessageauthenticationcode.h"
+#include "qvarlengtharray.h"
+
+/*
+ These #defines replace the typedefs needed by the RFC6234 code. Normally
+ the typedefs would come from from stdint.h, but since this header is not
+ available on all platforms (MSVC 2008, for example), we #define them to the
+ Qt equivalents.
+*/
+#define uint64_t QT_PREPEND_NAMESPACE(quint64)
+#define uint32_t QT_PREPEND_NAMESPACE(quint32)
+#define uint8_t QT_PREPEND_NAMESPACE(quint8)
+#define int_least16_t QT_PREPEND_NAMESPACE(qint16)
+
+// Header from rfc6234 with 1 modification:
+// sha1.h - commented out '#include <stdint.h>' on line 74
+#include "../../3rdparty/rfc6234/sha.h"
+
+#undef uint64_t
+#undef uint32_t
+#undef uint68_t
+#undef int_least16_t
+
+QT_BEGIN_NAMESPACE
+
+static int qt_hash_block_size(QCryptographicHash::Algorithm method)
+{
+ switch (method) {
+ case QCryptographicHash::Md4:
+ return 64;
+ case QCryptographicHash::Md5:
+ return 64;
+ case QCryptographicHash::Sha1:
+ return SHA1_Message_Block_Size;
+ case QCryptographicHash::Sha224:
+ return SHA224_Message_Block_Size;
+ case QCryptographicHash::Sha256:
+ return SHA256_Message_Block_Size;
+ case QCryptographicHash::Sha384:
+ return SHA384_Message_Block_Size;
+ case QCryptographicHash::Sha512:
+ return SHA512_Message_Block_Size;
+ case QCryptographicHash::Sha3_224:
+ return 144;
+ case QCryptographicHash::Sha3_256:
+ return 136;
+ case QCryptographicHash::Sha3_384:
+ return 104;
+ case QCryptographicHash::Sha3_512:
+ return 72;
+ }
+ return 0;
+}
+
+class QMessageAuthenticationCodePrivate
+{
+public:
+ QMessageAuthenticationCodePrivate(QCryptographicHash::Algorithm m)
+ : messageHash(m), method(m), messageHashInited(false)
+ {
+ }
+
+ QByteArray key;
+ QByteArray result;
+ QCryptographicHash messageHash;
+ QCryptographicHash::Algorithm method;
+ bool messageHashInited;
+
+ void initMessageHash();
+};
+
+void QMessageAuthenticationCodePrivate::initMessageHash()
+{
+ if (messageHashInited)
+ return;
+ messageHashInited = true;
+
+ const int blockSize = qt_hash_block_size(method);
+
+ if (key.size() > blockSize) {
+ QCryptographicHash hash(method);
+ hash.addData(key);
+ key = hash.result();
+ hash.reset();
+ }
+
+ if (key.size() < blockSize) {
+ const int size = key.size();
+ key.resize(blockSize);
+ memset(key.data() + size, 0, blockSize - size);
+ }
+
+ QVarLengthArray<char> iKeyPad(blockSize);
+ const char * const keyData = key.constData();
+
+ for (int i = 0; i < blockSize; ++i)
+ iKeyPad[i] = keyData[i] ^ 0x36;
+
+ messageHash.addData(iKeyPad.data(), iKeyPad.size());
+}
+
+/*!
+ \class QMessageAuthenticationCode
+ \inmodule QtCore
+
+ \brief The QMessageAuthenticationCode class provides a way to generate
+ hash-based message authentication codes.
+
+ \since 5.1
+
+ \ingroup tools
+ \reentrant
+
+ QMessageAuthenticationCode supports all cryptographic hashes which are supported by
+ QCryptographicHash.
+
+ To generate message authentication code, pass hash algorithm QCryptographicHash::Algorithm
+ to constructor, then set key and message by setKey() and addData() functions. Result
+ can be acquired by result() function.
+ \snippet qmessageauthenticationcode/main.cpp 0
+ \dots
+ \snippet qmessageauthenticationcode/main.cpp 1
+
+ Alternatively, this effect can be achieved by providing message,
+ key and method to hash() method.
+ \snippet qmessageauthenticationcode/main.cpp 2
+
+ \sa QCryptographicHash
+*/
+
+/*!
+ Constructs an object that can be used to create a cryptographic hash from data
+ using method \a method and key \a key.
+*/
+QMessageAuthenticationCode::QMessageAuthenticationCode(QCryptographicHash::Algorithm method,
+ const QByteArray &key)
+ : d(new QMessageAuthenticationCodePrivate(method))
+{
+ d->key = key;
+}
+
+/*!
+ Destroys the object.
+*/
+QMessageAuthenticationCode::~QMessageAuthenticationCode()
+{
+ delete d;
+}
+
+/*!
+ Resets message data. Calling this method doesn't affect the key.
+*/
+void QMessageAuthenticationCode::reset()
+{
+ d->result.clear();
+ d->messageHash.reset();
+ d->messageHashInited = false;
+}
+
+/*!
+ Sets secret \a key. Calling this method automatically resets the object state.
+*/
+void QMessageAuthenticationCode::setKey(const QByteArray &key)
+{
+ reset();
+ d->key = key;
+}
+
+/*!
+ Adds the first \a length chars of \a data to the message.
+*/
+void QMessageAuthenticationCode::addData(const char *data, int length)
+{
+ d->initMessageHash();
+ d->messageHash.addData(data, length);
+}
+
+/*!
+ \overload addData()
+*/
+void QMessageAuthenticationCode::addData(const QByteArray &data)
+{
+ d->initMessageHash();
+ d->messageHash.addData(data);
+}
+
+/*!
+ Reads the data from the open QIODevice \a device until it ends
+ and adds it to message. Returns true if reading was successful.
+
+ \note \a device must be already opened.
+ */
+bool QMessageAuthenticationCode::addData(QIODevice *device)
+{
+ d->initMessageHash();
+ return d->messageHash.addData(device);
+}
+
+/*!
+ Returns the final authentication code.
+
+ \sa QByteArray::toHex()
+*/
+QByteArray QMessageAuthenticationCode::result() const
+{
+ if (!d->result.isEmpty())
+ return d->result;
+
+ d->initMessageHash();
+
+ const int blockSize = qt_hash_block_size(d->method);
+
+ QByteArray hashedMessage = d->messageHash.result();
+
+ QVarLengthArray<char> oKeyPad(blockSize);
+ const char * const keyData = d->key.constData();
+
+ for (int i = 0; i < blockSize; ++i)
+ oKeyPad[i] = keyData[i] ^ 0x5c;
+
+ QCryptographicHash hash(d->method);
+ hash.addData(oKeyPad.data(), oKeyPad.size());
+ hash.addData(hashedMessage);
+
+ d->result = hash.result();
+ return d->result;
+}
+
+/*!
+ Returns the authentication code for the message \a message using
+ the key \a key and the method \a method.
+*/
+QByteArray QMessageAuthenticationCode::hash(const QByteArray &message, const QByteArray &key,
+ QCryptographicHash::Algorithm method)
+{
+ QMessageAuthenticationCode mac(method);
+ mac.setKey(key);
+ mac.addData(message);
+ return mac.result();
+}
+
+QT_END_NAMESPACE
diff --git a/src/corelib/tools/qmessageauthenticationcode.h b/src/corelib/tools/qmessageauthenticationcode.h
new file mode 100644
index 0000000000..77c22152e4
--- /dev/null
+++ b/src/corelib/tools/qmessageauthenticationcode.h
@@ -0,0 +1,80 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Ruslan Nigmatullin <euroelessar@yandex.ru>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QMESSAGEAUTHENTICATIONCODE_H
+#define QMESSAGEAUTHENTICATIONCODE_H
+
+#include <QtCore/qcryptographichash.h>
+
+QT_BEGIN_NAMESPACE
+
+
+class QMessageAuthenticationCodePrivate;
+class QIODevice;
+
+class Q_CORE_EXPORT QMessageAuthenticationCode
+{
+public:
+ explicit QMessageAuthenticationCode(QCryptographicHash::Algorithm method,
+ const QByteArray &key = QByteArray());
+ ~QMessageAuthenticationCode();
+
+ void reset();
+
+ void setKey(const QByteArray &key);
+
+ void addData(const char *data, int length);
+ void addData(const QByteArray &data);
+ bool addData(QIODevice *device);
+
+ QByteArray result() const;
+
+ static QByteArray hash(const QByteArray &message, const QByteArray &key,
+ QCryptographicHash::Algorithm method);
+
+private:
+ Q_DISABLE_COPY(QMessageAuthenticationCode)
+ QMessageAuthenticationCodePrivate *d;
+};
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/corelib/tools/qpair.h b/src/corelib/tools/qpair.h
index 65622f78cb..96b1b65e33 100644
--- a/src/corelib/tools/qpair.h
+++ b/src/corelib/tools/qpair.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -108,6 +106,4 @@ Q_OUTOFLINE_TEMPLATE QPair<T1, T2> qMakePair(const T1 &x, const T2 &y)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPAIR_H
diff --git a/src/corelib/tools/qpair.qdoc b/src/corelib/tools/qpair.qdoc
index 55353dc258..b0caf1aaf0 100644
--- a/src/corelib/tools/qpair.qdoc
+++ b/src/corelib/tools/qpair.qdoc
@@ -31,7 +31,7 @@
\brief The QPair class is a template class that stores a pair of items.
\ingroup tools
-
+
QPair\<T1, T2\> can be used in your application if the STL \c
pair type is not available. It stores one value of type T1 and
one value of type T2. It can be used as a return value for a
diff --git a/src/corelib/tools/qpodlist_p.h b/src/corelib/tools/qpodlist_p.h
index f307e279e8..cfe4cab9ae 100644
--- a/src/corelib/tools/qpodlist_p.h
+++ b/src/corelib/tools/qpodlist_p.h
@@ -55,8 +55,6 @@
#include <QtCore/qvarlengtharray.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -109,6 +107,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPODLIST_P_H
diff --git a/src/corelib/tools/qpoint.cpp b/src/corelib/tools/qpoint.cpp
index b3dd918a35..784d96bf1c 100644
--- a/src/corelib/tools/qpoint.cpp
+++ b/src/corelib/tools/qpoint.cpp
@@ -223,6 +223,15 @@ QT_BEGIN_NAMESPACE
*/
/*!
+ \fn static int QPoint::dotProduct(const QPoint &p1, const QPoint &p2)
+ \since 5.1
+
+ \snippet code/src_corelib_tools_qpoint.cpp 16
+
+ Returns the dot product of \a p1 and \a p2.
+*/
+
+/*!
\fn bool operator==(const QPoint &p1, const QPoint &p2)
\relates QPoint
@@ -712,6 +721,15 @@ QDebug operator<<(QDebug d, const QPointF &p)
*/
/*!
+ \fn static qreal QPointF::dotProduct(const QPointF &p1, const QPointF &p2)
+ \since 5.1
+
+ \snippet code/src_corelib_tools_qpoint.cpp 17
+
+ Returns the dot product of \a p1 and \a p2.
+*/
+
+/*!
\fn bool operator==(const QPointF &p1, const QPointF &p2)
\relates QPointF
diff --git a/src/corelib/tools/qpoint.h b/src/corelib/tools/qpoint.h
index b6446e8c9f..69403ebc53 100644
--- a/src/corelib/tools/qpoint.h
+++ b/src/corelib/tools/qpoint.h
@@ -44,8 +44,6 @@
#include <QtCore/qnamespace.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -76,6 +74,9 @@ public:
inline QPoint &operator/=(qreal divisor);
+ Q_DECL_CONSTEXPR static inline int dotProduct(const QPoint &p1, const QPoint &p2)
+ { return p1.xp * p2.xp + p1.yp * p2.yp; }
+
friend Q_DECL_CONSTEXPR inline bool operator==(const QPoint &, const QPoint &);
friend Q_DECL_CONSTEXPR inline bool operator!=(const QPoint &, const QPoint &);
friend Q_DECL_CONSTEXPR inline const QPoint operator+(const QPoint &, const QPoint &);
@@ -233,6 +234,9 @@ public:
inline QPointF &operator*=(qreal c);
inline QPointF &operator/=(qreal c);
+ Q_DECL_CONSTEXPR static inline qreal dotProduct(const QPointF &p1, const QPointF &p2)
+ { return p1.xp * p2.xp + p1.yp * p2.yp; }
+
friend Q_DECL_CONSTEXPR inline bool operator==(const QPointF &, const QPointF &);
friend Q_DECL_CONSTEXPR inline bool operator!=(const QPointF &, const QPointF &);
friend Q_DECL_CONSTEXPR inline const QPointF operator+(const QPointF &, const QPointF &);
@@ -393,6 +397,4 @@ Q_CORE_EXPORT QDebug operator<<(QDebug d, const QPointF &p);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPOINT_H
diff --git a/src/corelib/tools/qqueue.h b/src/corelib/tools/qqueue.h
index ed275a121a..b83021434e 100644
--- a/src/corelib/tools/qqueue.h
+++ b/src/corelib/tools/qqueue.h
@@ -44,8 +44,6 @@
#include <QtCore/qlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -64,6 +62,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QQUEUE_H
diff --git a/src/corelib/tools/qrect.h b/src/corelib/tools/qrect.h
index 2ad049652f..62ebdd10cd 100644
--- a/src/corelib/tools/qrect.h
+++ b/src/corelib/tools/qrect.h
@@ -49,10 +49,9 @@
#error qrect.h must be included before any header file that defines topLeft
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
+class QMargins;
class Q_CORE_EXPORT QRect
{
@@ -139,6 +138,11 @@ public:
inline QRect intersected(const QRect &other) const;
bool intersects(const QRect &r) const;
+ inline QRect marginsAdded(const QMargins &margins) const;
+ inline QRect marginsRemoved(const QMargins &margins) const;
+ inline QRect &operator+=(const QMargins &margins);
+ inline QRect &operator-=(const QMargins &margins);
+
#if QT_DEPRECATED_SINCE(5, 0)
QT_DEPRECATED QRect unite(const QRect &r) const { return united(r); }
QT_DEPRECATED QRect intersect(const QRect &r) const { return intersected(r); }
@@ -786,6 +790,4 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QRectF &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QRECT_H
diff --git a/src/corelib/tools/qrefcount.h b/src/corelib/tools/qrefcount.h
index 4036bc6508..84314b1fcc 100644
--- a/src/corelib/tools/qrefcount.h
+++ b/src/corelib/tools/qrefcount.h
@@ -44,8 +44,6 @@
#include <QtCore/qatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -112,6 +110,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/tools/qregexp.cpp b/src/corelib/tools/qregexp.cpp
index cbb3580024..83e87ff637 100644
--- a/src/corelib/tools/qregexp.cpp
+++ b/src/corelib/tools/qregexp.cpp
@@ -298,7 +298,7 @@ int qFindString(const QChar *haystack, int haystackLen, int from,
Square brackets mean match any character contained in the square
brackets. The character set abbreviations described above can
appear in a character set in square brackets. Except for the
- character set abbreviations and the following two exceptions,
+ character set abbreviations and the following two exceptions,
characters do not have special meanings in square brackets.
\table
diff --git a/src/corelib/tools/qregexp.h b/src/corelib/tools/qregexp.h
index f5003fed0a..26b0b78317 100644
--- a/src/corelib/tools/qregexp.h
+++ b/src/corelib/tools/qregexp.h
@@ -42,12 +42,12 @@
#ifndef QREGEXP_H
#define QREGEXP_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_REGEXP
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -129,8 +129,6 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QRegExp &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_REGEXP
#endif // QREGEXP_H
diff --git a/src/corelib/tools/qregularexpression.cpp b/src/corelib/tools/qregularexpression.cpp
index a18d8af898..a50c7da6cc 100644
--- a/src/corelib/tools/qregularexpression.cpp
+++ b/src/corelib/tools/qregularexpression.cpp
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2012 Giuseppe D'Angelo <dangelog@gmail.com>.
+** Copyright (C) 2012 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
@@ -49,6 +50,7 @@
#include <QtCore/qdebug.h>
#include <QtCore/qthreadstorage.h>
#include <QtCore/qglobal.h>
+#include <QtCore/qatomic.h>
#include <pcre.h>
@@ -725,6 +727,13 @@ QT_BEGIN_NAMESPACE
that (in this text) there are other characters beyond the end of the
subject string. This can lead to surprising results; see the discussion
in the \l{partial matching} section for more details.
+
+ \value NoMatch
+ No matching is done. This value is returned as the match type by a
+ default constructed QRegularExpressionMatch or
+ QRegularExpressionMatchIterator. Using this match type is not very
+ useful for the user, as no matching ever happens. This enum value
+ has been introduced in Qt 5.1.
*/
/*!
@@ -793,7 +802,7 @@ struct QRegularExpressionPrivate : QSharedData
void cleanCompiledPattern();
void compilePattern();
void getPatternInfo();
- pcre16_extra *optimizePattern();
+ void optimizePattern();
QRegularExpressionMatchPrivate *doMatch(const QString &subject,
int offset,
@@ -819,7 +828,7 @@ struct QRegularExpressionPrivate : QSharedData
// objects themselves; when the private is copied (i.e. a detach happened)
// they are set to 0
pcre16 *compiledPattern;
- pcre16_extra *studyData;
+ QAtomicPointer<pcre16_extra> studyData;
const char *errorString;
int errorOffset;
int capturingCount;
@@ -834,7 +843,7 @@ struct QRegularExpressionMatchPrivate : QSharedData
const QString &subject,
QRegularExpression::MatchType matchType,
QRegularExpression::MatchOptions matchOptions,
- int capturingCount);
+ int capturingCount = 0);
QRegularExpressionMatch nextMatch() const;
@@ -926,10 +935,10 @@ QRegularExpressionPrivate::QRegularExpressionPrivate(const QRegularExpressionPri
void QRegularExpressionPrivate::cleanCompiledPattern()
{
pcre16_free(compiledPattern);
- pcre16_free_study(studyData);
+ pcre16_free_study(studyData.load());
usedCount = 0;
compiledPattern = 0;
- studyData = 0;
+ studyData.store(0);
usingCrLfNewlines = false;
errorOffset = -1;
capturingCount = 0;
@@ -959,7 +968,7 @@ void QRegularExpressionPrivate::compilePattern()
return;
Q_ASSERT(errorCode == 0);
- Q_ASSERT(studyData == 0); // studying (=>optimizing) is always done later
+ Q_ASSERT(studyData.load() == 0); // studying (=>optimizing) is always done later
errorOffset = -1;
getPatternInfo();
@@ -971,12 +980,13 @@ void QRegularExpressionPrivate::compilePattern()
void QRegularExpressionPrivate::getPatternInfo()
{
Q_ASSERT(compiledPattern);
+ Q_ASSERT(studyData.load() == 0);
pcre16_fullinfo(compiledPattern, 0, PCRE_INFO_CAPTURECOUNT, &capturingCount);
// detect the settings for the newline
unsigned long int patternNewlineSetting;
- pcre16_fullinfo(compiledPattern, studyData, PCRE_INFO_OPTIONS, &patternNewlineSetting);
+ pcre16_fullinfo(compiledPattern, 0, PCRE_INFO_OPTIONS, &patternNewlineSetting);
patternNewlineSetting &= PCRE_NEWLINE_CR | PCRE_NEWLINE_LF | PCRE_NEWLINE_CRLF
| PCRE_NEWLINE_ANY | PCRE_NEWLINE_ANYCRLF;
if (patternNewlineSetting == 0) {
@@ -1004,6 +1014,14 @@ void QRegularExpressionPrivate::getPatternInfo()
usingCrLfNewlines = (patternNewlineSetting == PCRE_NEWLINE_CRLF) ||
(patternNewlineSetting == PCRE_NEWLINE_ANY) ||
(patternNewlineSetting == PCRE_NEWLINE_ANYCRLF);
+
+ int hasJOptionChanged;
+ pcre16_fullinfo(compiledPattern, 0, PCRE_INFO_JCHANGED, &hasJOptionChanged);
+ if (hasJOptionChanged) {
+ qWarning("QRegularExpressionPrivate::getPatternInfo(): the pattern '%s'\n"
+ " is using the (?J) option; duplicate capturing group names are not supported by Qt",
+ qPrintable(pattern));
+ }
}
@@ -1084,17 +1102,18 @@ static bool isJitEnabled()
leaving studyData to NULL); but before calling pcre16_exec to perform the
match, another thread performs the studying and sets studyData to something
else. Although the assignment to studyData is itself atomic, the release of
- the memory pointed by studyData isn't. Therefore, the current studyData
- value is returned and used by doMatch.
+ the memory pointed by studyData isn't. Therefore, we work on a local copy
+ (localStudyData) before using storeRelease on studyData. In doMatch there's
+ the corresponding loadAcquire.
*/
-pcre16_extra *QRegularExpressionPrivate::optimizePattern()
+void QRegularExpressionPrivate::optimizePattern()
{
Q_ASSERT(compiledPattern);
QMutexLocker lock(&mutex);
- if (studyData || (++usedCount != qt_qregularexpression_optimize_after_use_count))
- return studyData;
+ if (studyData.load() || (++usedCount != qt_qregularexpression_optimize_after_use_count))
+ return;
static const bool enableJit = isJitEnabled();
@@ -1103,15 +1122,15 @@ pcre16_extra *QRegularExpressionPrivate::optimizePattern()
studyOptions |= PCRE_STUDY_JIT_COMPILE;
const char *err;
- studyData = pcre16_study(compiledPattern, studyOptions, &err);
+ pcre16_extra * const localStudyData = pcre16_study(compiledPattern, studyOptions, &err);
- if (studyData && studyData->flags & PCRE_EXTRA_EXECUTABLE_JIT)
- pcre16_assign_jit_stack(studyData, qtPcreCallback, 0);
+ if (localStudyData && localStudyData->flags & PCRE_EXTRA_EXECUTABLE_JIT)
+ pcre16_assign_jit_stack(localStudyData, qtPcreCallback, 0);
- if (!studyData && err)
+ if (!localStudyData && err)
qWarning("QRegularExpressionPrivate::optimizePattern(): pcre_study failed: %s", err);
- return studyData;
+ studyData.storeRelease(localStudyData);
}
/*!
@@ -1193,19 +1212,33 @@ QRegularExpressionMatchPrivate *QRegularExpressionPrivate::doMatch(const QString
QRegularExpression re(*const_cast<QRegularExpressionPrivate *>(this));
if (offset < 0 || offset > subject.length())
- return new QRegularExpressionMatchPrivate(re, subject, matchType, matchOptions, 0);
+ return new QRegularExpressionMatchPrivate(re, subject, matchType, matchOptions);
if (!compiledPattern) {
qWarning("QRegularExpressionPrivate::doMatch(): called on an invalid QRegularExpression object");
- return new QRegularExpressionMatchPrivate(re, subject, matchType, matchOptions, 0);
+ return new QRegularExpressionMatchPrivate(re, subject, matchType, matchOptions);
+ }
+
+ // skip optimizing and doing the actual matching if NoMatch type was requested
+ if (matchType == QRegularExpression::NoMatch) {
+ QRegularExpressionMatchPrivate *priv = new QRegularExpressionMatchPrivate(re, subject,
+ matchType, matchOptions);
+ priv->isValid = true;
+ return priv;
}
+ // capturingCount doesn't include the implicit "0" capturing group
QRegularExpressionMatchPrivate *priv = new QRegularExpressionMatchPrivate(re, subject,
matchType, matchOptions,
- capturingCount);
+ capturingCount + 1);
// this is mutex protected
- const pcre16_extra *currentStudyData = const_cast<QRegularExpressionPrivate *>(this)->optimizePattern();
+ const_cast<QRegularExpressionPrivate *>(this)->optimizePattern();
+
+ // work with a local copy of the study data, as we are running pcre_exec
+ // potentially more than once, and we don't want to run call it
+ // with different study data
+ const pcre16_extra * const currentStudyData = studyData.loadAcquire();
int pcreOptions = convertToPcreOptions(matchOptions);
@@ -1311,8 +1344,10 @@ QRegularExpressionMatchPrivate::QRegularExpressionMatchPrivate(const QRegularExp
hasMatch(false), hasPartialMatch(false), isValid(false)
{
Q_ASSERT(capturingCount >= 0);
- const int captureOffsetsCount = (capturingCount + 1) * 3;
- capturedOffsets.resize(captureOffsetsCount);
+ if (capturingCount > 0) {
+ const int captureOffsetsCount = capturingCount * 3;
+ capturedOffsets.resize(captureOffsetsCount);
+ }
}
@@ -1468,6 +1503,8 @@ void QRegularExpression::setPatternOptions(PatternOptions options)
Returns the number of capturing groups inside the pattern string,
or -1 if the regular expression is not valid.
+ \note The implicit capturing group 0 is \e{not} included in the returned number.
+
\sa isValid()
*/
int QRegularExpression::captureCount() const
@@ -1478,6 +1515,71 @@ int QRegularExpression::captureCount() const
}
/*!
+ \since 5.1
+
+ Returns a list of captureCount() + 1 elements, containing the names of the
+ named capturing groups in the pattern string. The list is sorted such that
+ the element of the list at position \c{i} is the name of the \c{i}-th
+ capturing group, if it has a name, or an empty string if that capturing
+ group is unnamed.
+
+ For instance, given the regular expression
+
+ \code
+ (?<day>\d\d)-(?<month>\d\d)-(?<year>\d\d\d\d) (\w+) (?<name>\w+)
+ \endcode
+
+ namedCaptureGroups() will return the following list:
+
+ \code
+ ("", "day", "month", "year", "", "name")
+ \endcode
+
+ which corresponds to the fact that the capturing group #0 (corresponding to
+ the whole match) has no name, the capturing group #1 has name "day", the
+ capturing group #2 has name "month", etc.
+
+ If the regular expression is not valid, returns an empty list.
+
+ \sa isValid(), QRegularExpressionMatch::captured(), QString::isEmpty()
+*/
+QStringList QRegularExpression::namedCaptureGroups() const
+{
+ if (!isValid()) // isValid() will compile the pattern
+ return QStringList();
+
+ // namedCapturingTable will point to a table of
+ // namedCapturingTableEntryCount entries, each one of which
+ // contains one ushort followed by the name, NUL terminated.
+ // The ushort is the numerical index of the name in the pattern.
+ // The length of each entry is namedCapturingTableEntrySize.
+ ushort *namedCapturingTable;
+ int namedCapturingTableEntryCount;
+ int namedCapturingTableEntrySize;
+
+ pcre16_fullinfo(d->compiledPattern, 0, PCRE_INFO_NAMETABLE, &namedCapturingTable);
+ pcre16_fullinfo(d->compiledPattern, 0, PCRE_INFO_NAMECOUNT, &namedCapturingTableEntryCount);
+ pcre16_fullinfo(d->compiledPattern, 0, PCRE_INFO_NAMEENTRYSIZE, &namedCapturingTableEntrySize);
+
+ QStringList result;
+
+ // no QList::resize nor fill is available. The +1 is for the implicit group #0
+ result.reserve(d->capturingCount + 1);
+ for (int i = 0; i < d->capturingCount + 1; ++i)
+ result.append(QString());
+
+ for (int i = 0; i < namedCapturingTableEntryCount; ++i) {
+ const ushort * const currentNamedCapturingTableRow = namedCapturingTable +
+ namedCapturingTableEntrySize * i;
+
+ const int index = *currentNamedCapturingTableRow;
+ result[index] = QString::fromUtf16(currentNamedCapturingTableRow + 1);
+ }
+
+ return result;
+}
+
+/*!
Returns true if the regular expression is a valid regular expression (that
is, it contains no syntax errors, etc.), or false otherwise. Use
errorString() to obtain a textual description of the error.
@@ -1639,6 +1741,26 @@ QString QRegularExpression::escape(const QString &str)
}
/*!
+ \since 5.1
+
+ Constructs a valid, empty QRegularExpressionMatch object. The regular
+ expression is set to a default-constructed one; the match type to
+ QRegularExpression::NoMatch and the match options to
+ QRegularExpression::NoMatchOption.
+
+ The object will report no match through the hasMatch() and the
+ hasPartialMatch() member functions.
+*/
+QRegularExpressionMatch::QRegularExpressionMatch()
+ : d(new QRegularExpressionMatchPrivate(QRegularExpression(),
+ QString(),
+ QRegularExpression::NoMatch,
+ QRegularExpression::NoMatchOption))
+{
+ d->isValid = true;
+}
+
+/*!
Destroys the match result.
*/
QRegularExpressionMatch::~QRegularExpressionMatch()
@@ -1982,6 +2104,26 @@ QRegularExpressionMatchIterator::QRegularExpressionMatchIterator(QRegularExpress
}
/*!
+ \since 5.1
+
+ Constructs an empty, valid QRegularExpressionMatchIterator object. The
+ regular expression is set to a default-constructed one; the match type to
+ QRegularExpression::NoMatch and the match options to
+ QRegularExpression::NoMatchOption.
+
+ Invoking the hasNext() member function on the constructed object will
+ return false, as the iterator is not iterating on a valid sequence of
+ matches.
+*/
+QRegularExpressionMatchIterator::QRegularExpressionMatchIterator()
+ : d(new QRegularExpressionMatchIteratorPrivate(QRegularExpression(),
+ QRegularExpression::NoMatch,
+ QRegularExpression::NoMatchOption,
+ QRegularExpressionMatch()))
+{
+}
+
+/*!
Destroys the QRegularExpressionMatchIterator object.
*/
QRegularExpressionMatchIterator::~QRegularExpressionMatchIterator()
diff --git a/src/corelib/tools/qregularexpression.h b/src/corelib/tools/qregularexpression.h
index 4c95a5b3a0..5059ea6431 100644
--- a/src/corelib/tools/qregularexpression.h
+++ b/src/corelib/tools/qregularexpression.h
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2012 Giuseppe D'Angelo <dangelog@gmail.com>.
+** Copyright (C) 2012 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
** Contact: http://www.qt-project.org/legal
**
** This file is part of the QtCore module of the Qt Toolkit.
@@ -42,14 +43,15 @@
#ifndef QREGULAREXPRESSION_H
#define QREGULAREXPRESSION_H
-#ifndef QT_NO_REGEXP
+#include <QtCore/qglobal.h>
+
+#ifndef QT_NO_REGULAREXPRESSION
#include <QtCore/qstring.h>
+#include <QtCore/qstringlist.h>
#include <QtCore/qshareddata.h>
#include <QtCore/qvariant.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QRegularExpressionMatch;
@@ -95,11 +97,13 @@ public:
QString errorString() const;
int captureCount() const;
+ QStringList namedCaptureGroups() const;
enum MatchType {
NormalMatch = 0,
PartialPreferCompleteMatch,
- PartialPreferFirstMatch
+ PartialPreferFirstMatch,
+ NoMatch
};
enum MatchOption {
@@ -152,6 +156,7 @@ struct QRegularExpressionMatchPrivate;
class Q_CORE_EXPORT QRegularExpressionMatch
{
public:
+ QRegularExpressionMatch();
~QRegularExpressionMatch();
QRegularExpressionMatch(const QRegularExpressionMatch &match);
QRegularExpressionMatch &operator=(const QRegularExpressionMatch &match);
@@ -209,6 +214,7 @@ struct QRegularExpressionMatchIteratorPrivate;
class Q_CORE_EXPORT QRegularExpressionMatchIterator
{
public:
+ QRegularExpressionMatchIterator();
~QRegularExpressionMatchIterator();
QRegularExpressionMatchIterator(const QRegularExpressionMatchIterator &iterator);
QRegularExpressionMatchIterator &operator=(const QRegularExpressionMatchIterator &iterator);
@@ -239,8 +245,6 @@ Q_DECLARE_SHARED(QRegularExpressionMatchIterator)
QT_END_NAMESPACE
-QT_END_HEADER
-
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
#endif // QREGULAREXPRESSION_H
diff --git a/src/corelib/tools/qringbuffer_p.h b/src/corelib/tools/qringbuffer_p.h
index 9c952fea21..b17c6d2f40 100644
--- a/src/corelib/tools/qringbuffer_p.h
+++ b/src/corelib/tools/qringbuffer_p.h
@@ -375,7 +375,7 @@ public:
--tailBuffer;
}
bufferSize -= qba.length();
- return qba;
+ return qba;
}
// append a new buffer to the end
diff --git a/src/corelib/tools/qscopedpointer.h b/src/corelib/tools/qscopedpointer.h
index 5d19bcea55..2155c56e27 100644
--- a/src/corelib/tools/qscopedpointer.h
+++ b/src/corelib/tools/qscopedpointer.h
@@ -46,7 +46,6 @@
#include <stdlib.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
template <typename T>
@@ -97,7 +96,6 @@ public:
{
T *oldD = this->d;
Cleanup::cleanup(oldD);
- this->d = 0;
}
inline T &operator*() const
@@ -239,6 +237,5 @@ private:
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QSCOPEDPOINTER_H
diff --git a/src/corelib/tools/qscopedpointer_p.h b/src/corelib/tools/qscopedpointer_p.h
index f92ce0a454..06ebac1853 100644
--- a/src/corelib/tools/qscopedpointer_p.h
+++ b/src/corelib/tools/qscopedpointer_p.h
@@ -55,7 +55,6 @@
#include "QtCore/qscopedpointer.h"
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -145,6 +144,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
#endif
diff --git a/src/corelib/tools/qscopedvaluerollback.h b/src/corelib/tools/qscopedvaluerollback.h
index 8d6293c514..dfaf1984be 100644
--- a/src/corelib/tools/qscopedvaluerollback.h
+++ b/src/corelib/tools/qscopedvaluerollback.h
@@ -44,7 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
template <typename T>
@@ -75,6 +74,5 @@ private:
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QSCOPEDVALUEROLLBACK_H
diff --git a/src/corelib/tools/qset.h b/src/corelib/tools/qset.h
index 6fdc8e6281..d5c3637293 100644
--- a/src/corelib/tools/qset.h
+++ b/src/corelib/tools/qset.h
@@ -43,8 +43,9 @@
#define QSET_H
#include <QtCore/qhash.h>
-
-QT_BEGIN_HEADER
+#ifdef Q_COMPILER_INITIALIZER_LISTS
+#include <initializer_list>
+#endif
QT_BEGIN_NAMESPACE
@@ -56,6 +57,14 @@ class QSet
public:
inline QSet() {}
+#ifdef Q_COMPILER_INITIALIZER_LISTS
+ inline QSet(std::initializer_list<T> list)
+ {
+ reserve(list.size());
+ for (typename std::initializer_list<T>::const_iterator it = list.begin(); it != list.end(); ++it)
+ insert(*it);
+ }
+#endif
inline QSet(const QSet<T> &other) : q_hash(other.q_hash) {}
inline QSet<T> &operator=(const QSet<T> &other)
@@ -355,6 +364,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSET_H
diff --git a/src/corelib/tools/qset.qdoc b/src/corelib/tools/qset.qdoc
index ef7a4c4f52..c1351943e1 100644
--- a/src/corelib/tools/qset.qdoc
+++ b/src/corelib/tools/qset.qdoc
@@ -103,6 +103,16 @@
\sa clear()
*/
+/*! \fn QSet::QSet(std::initializer_list<T> list)
+ \since 5.1
+
+ Constructs a set with a copy of each of the elements in the
+ initializer list \a list.
+
+ This function is only available if the program is being
+ compiled in C++11 mode.
+*/
+
/*!
\fn QSet::QSet(const QSet<T> &other)
@@ -120,7 +130,7 @@
\fn QSet<T> &QSet::operator=(const QSet<T> &other)
Assigns the \a other set to this set and returns a reference to
- this set.
+ this set.
*/
/*!
@@ -296,7 +306,7 @@
Returns a non-const iterator positioned at the item \a value in
the set. If the set contains no item \a value, the function
- returns end().
+ returns end().
*/
/*! \fn QSet::const_iterator QSet::constFind(const T &value) const
@@ -341,7 +351,7 @@
\overload
Returns a non-const \l{STL-style iterators}{STL-style iterator} positioned at the first
- item in the set.
+ item in the set.
*/
/*! \fn QSet::const_iterator QSet::cbegin() const
@@ -486,7 +496,7 @@
/*!
\fn QSet<T> &QSet::subtract(const QSet<T> &other)
- Removes all items from this set that are contained in the
+ Removes all items from this set that are contained in the
\a other set. Returns a reference to this set.
\sa operator-=(), unite(), intersect()
@@ -496,7 +506,7 @@
\fn bool QSet::empty() const
Returns true if the set is empty. This function is provided
- for STL compatibility. It is equivalent to isEmpty().
+ for STL compatibility. It is equivalent to isEmpty().
*/
/*!
@@ -519,7 +529,7 @@
/*!
\fn QSet<T> &QSet::operator-=(const T &value)
- Removes the occurrence of item \a value from the set, if
+ Removes the occurrence of item \a value from the set, if
it is found, and returns a reference to the set. If the
\a value is not contained the set, nothing is removed.
@@ -549,7 +559,7 @@
\overload
Same as intersect(\e{other}), if we consider \e{other} to be a set
- that contains the singleton \a value.
+ that contains the singleton \a value.
*/
@@ -565,7 +575,7 @@
\fn QSet<T> QSet::operator|(const QSet<T> &other) const
\fn QSet<T> QSet::operator+(const QSet<T> &other) const
- Returns a new QSet that is the union of this set and the
+ Returns a new QSet that is the union of this set and the
\a other set.
\sa unite(), operator|=(), operator&(), operator-()
@@ -612,7 +622,7 @@
iterators are slightly faster, and can improve code readability.
QSet\<T\>::iterator allows you to iterate over a QSet\<T\> and
- modify it as you go (using QSet::erase()). However,
+ modify it as you go (using QSet::erase()). However,
The default QSet::iterator constructor creates an uninitialized
iterator. You must initialize it using a function like
@@ -691,7 +701,7 @@
\sa QSet::begin(), QSet::end()
*/
-/*!
+/*!
\fn QSet::iterator::iterator(typename Hash::iterator i)
\fn QSet::const_iterator::const_iterator(typename Hash::const_iterator i)
diff --git a/src/corelib/tools/qshareddata.cpp b/src/corelib/tools/qshareddata.cpp
index 8205560781..cee0c1d450 100644
--- a/src/corelib/tools/qshareddata.cpp
+++ b/src/corelib/tools/qshareddata.cpp
@@ -43,7 +43,7 @@
QT_BEGIN_NAMESPACE
-/*!
+/*!
\class QSharedData
\inmodule QtCore
\brief The QSharedData class is a base class for shared data objects.
@@ -66,7 +66,7 @@ QT_BEGIN_NAMESPACE
\a other is ignored.
*/
-/*!
+/*!
\class QSharedDataPointer
\inmodule QtCore
\brief The QSharedDataPointer class represents a pointer to an implicitly shared object.
@@ -395,7 +395,7 @@ QT_BEGIN_NAMESPACE
return the proper polymorphic type.
*/
-/*!
+/*!
\class QExplicitlySharedDataPointer
\inmodule QtCore
\brief The QExplicitlySharedDataPointer class represents a pointer to an explicitly shared object.
diff --git a/src/corelib/tools/qshareddata.h b/src/corelib/tools/qshareddata.h
index 276fef4446..00bf4cba2a 100644
--- a/src/corelib/tools/qshareddata.h
+++ b/src/corelib/tools/qshareddata.h
@@ -45,8 +45,6 @@
#include <QtCore/qglobal.h>
#include <QtCore/qatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -281,6 +279,4 @@ template<typename T> Q_DECLARE_TYPEINFO_BODY(QExplicitlySharedDataPointer<T>, Q_
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSHAREDDATA_H
diff --git a/src/corelib/tools/qsharedpointer.cpp b/src/corelib/tools/qsharedpointer.cpp
index df7a911f8c..bced1f4ece 100644
--- a/src/corelib/tools/qsharedpointer.cpp
+++ b/src/corelib/tools/qsharedpointer.cpp
@@ -136,23 +136,11 @@
\omit
\secton1 QSharedPointer internals
- QSharedPointer is in reality implemented by two ancestor classes:
- QtSharedPointer::Basic and QtSharedPointer::ExternalRefCount. The reason
- for having that split is now mostly legacy: in the beginning,
- QSharedPointer was meant to support both internal reference counting and
- external reference counting.
-
- QtSharedPointer::Basic implements the basic functionality that is shared
- between internal- and external-reference counting. That is, it's mostly
- the accessor functions into QSharedPointer. Those are all inherited by
- QSharedPointer, which adds another level of shared functionality (the
- constructors and assignment operators). The Basic class has one member
- variable, which is the actual pointer being tracked.
-
- QtSharedPointer::ExternalRefCount implements the actual reference
- counting and introduces the d-pointer for QSharedPointer. That d-pointer
- itself is shared with other QSharedPointer objects as well as
- QWeakPointer.
+ QSharedPointer has two "private" members: the pointer itself being tracked
+ and a d-pointer. Those members are private to the class, but QSharedPointer
+ is friends with QWeakPointer and other QSharedPointer with different
+ template arguments. (On some compilers, template friends are not supported,
+ so the members are technically public)
The reason for keeping the pointer value itself outside the d-pointer is
because of multiple inheritance needs. If you have two QSharedPointer
@@ -178,17 +166,19 @@
QSharedObject instances that are attached to this Data.
When the strong reference count decreases to zero, the object is deleted
- (see below for information on custom deleters). The strong reference
- count can also exceptionally be -1, indicating that there are no
- QSharedPointers attached to an object, which is tracked too. The only
- case where this is possible is that of QWeakPointers tracking a QObject.
+ (see below for information on custom deleters). The strong reference count
+ can also exceptionally be -1, indicating that there are no QSharedPointers
+ attached to an object, which is tracked too. The only case where this is
+ possible is that of QWeakPointers and QPointers tracking a QObject. Note
+ that QWeakPointers tracking a QObject is a deprecated feature as of Qt 5.0,
+ kept only for compatibility with Qt 4.x.
The weak reference count controls the lifetime of the d-pointer itself.
It can be thought of as an internal/intrusive reference count for
ExternalRefCountData itself. This count is equal to the number of
- QSharedPointers and QWeakPointers that are tracking this object. (In case
- the object tracked derives from QObject, this number is increased by 1,
- since QObjectPrivate tracks it too).
+ QSharedPointers and QWeakPointers that are tracking this object. In case
+ the object is a QObject being tracked by QPointer, this number is increased
+ by 1, since QObjectPrivate tracks it too.
The third member is a pointer to the function that is used to delete the
pointer being tracked. That happens when the destroy() function is called.
@@ -199,18 +189,21 @@
\section3 QtSharedPointer::ExternalRefCountWithCustomDeleter
- This class derives from ExternalRefCountData and is a
- template class. As template parameters, it has the type of the pointer
- being tracked (\tt T) and a \tt Deleter, which is anything. It adds two
- fields to its parent class, matching those template parameters: a member
- of type \tt Deleter and a member of type \tt T*.
+ This class derives from ExternalRefCountData and is a template class. As
+ template parameters, it has the type of the pointer being tracked (\tt T)
+ and a \tt Deleter, which is anything. It adds two fields to its parent
+ class, matching those template parameters: a member of type \tt Deleter and
+ a member of type \tt T*. Those members are actually inside a template
+ struct of type CustomDeleter, which is partially-specialized for normal
+ deletion. See below for more details on that.
The purpose of this class is to store the pointer to be deleted and the
deleter code along with the d-pointer. This allows the last strong
reference to call any arbitrary function that disposes of the object. For
example, this allows calling QObject::deleteLater() on a given object.
- The pointer to the object is kept here to avoid the extra cost of keeping
- the deleter in the generic case.
+ The pointer to the object is kept here because it needs to match the actual
+ deleter function's parameters, regardless of what template argument the
+ last QSharedPointer instance had.
This class is never instantiated directly: the constructors and
destructor are private and, in C++11, deleted. Only the create() function
@@ -605,6 +598,37 @@
*/
/*!
+ \fn QSharedPointer<T> QSharedPointer::create()
+ \since 5.1
+
+ Creates a QSharedPointer object and allocates a new item of type \tt T. The
+ QSharedPointer internals and the object are allocated in one single memory
+ allocation, which could help reduce memory fragmentation in a long-running
+ application.
+
+ This function calls the default constructor for type \tt T.
+*/
+
+/*!
+ \fn QSharedPointer<T> QSharedPointer::create(...)
+ \overload
+ \since 5.1
+
+ Creates a QSharedPointer object and allocates a new item of type \tt T. The
+ QSharedPointer internals and the object are allocated in one single memory
+ allocation, which could help reduce memory fragmentation in a long-running
+ application.
+
+ This function will attempt to call a constructor for type \tt T that can
+ accept all the arguments passed. Arguments will be perfectly-forwarded.
+
+ \note This function is only available with a C++11 compiler that supports
+ perfect forwarding of an arbitrary number of arguments. If the compiler
+ does not support the necessary C++11 features, you must use the overload
+ that calls the default constructor.
+*/
+
+/*!
\fn QWeakPointer<T> QSharedPointer::toWeakRef() const
Returns a weak reference object that shares the pointer referenced
diff --git a/src/corelib/tools/qsharedpointer.h b/src/corelib/tools/qsharedpointer.h
index b4e70cebd2..7d1f00814d 100644
--- a/src/corelib/tools/qsharedpointer.h
+++ b/src/corelib/tools/qsharedpointer.h
@@ -50,8 +50,6 @@
# include <QtCore/qsharedpointer_impl.h>
#else
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -95,6 +93,9 @@ public:
template <class X> QSharedPointer<X> dynamicCast() const;
template <class X> QSharedPointer<X> constCast() const;
template <class X> QSharedPointer<X> objectCast() const;
+
+ static inline QSharedPointer<T> create();
+ static inline QSharedPointer<T> create(...);
};
template <class T>
@@ -149,8 +150,6 @@ template <class X, class T> QWeakPointer<X> qWeakPointerCast(const QWeakPointer<
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // Q_QDOC
#endif // QSHAREDPOINTER_H
diff --git a/src/corelib/tools/qsharedpointer_impl.h b/src/corelib/tools/qsharedpointer_impl.h
index 881c60b6fd..5e30cf3ecb 100644
--- a/src/corelib/tools/qsharedpointer_impl.h
+++ b/src/corelib/tools/qsharedpointer_impl.h
@@ -46,14 +46,17 @@
#endif
#if 0
+#pragma qt_sync_skip_header_check
+#pragma qt_sync_stop_processing
+#endif
+
+#if 0
// These macros are duplicated here to make syncqt not complain a about
// this header, as we have a "qt_sync_stop_processing" below, which in turn
// is here because this file contains a template mess and duplicates the
// classes found in qsharedpointer.h
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
#pragma qt_sync_stop_processing
#endif
@@ -62,7 +65,9 @@ QT_END_HEADER
#include <QtCore/qobject.h> // for qobject_cast
#include <QtCore/qhash.h> // for qHash
-QT_BEGIN_HEADER
+#if defined(Q_COMPILER_RVALUE_REFS) && defined(Q_COMPILER_VARIADIC_TEMPLATES)
+# include <utility> // for std::forward
+#endif
QT_BEGIN_NAMESPACE
@@ -389,6 +394,28 @@ public:
QWeakPointer<T> toWeakRef() const;
+#if defined(Q_COMPILER_RVALUE_REFS) && defined(Q_COMPILER_VARIADIC_TEMPLATES)
+ template <typename... Args>
+ static QSharedPointer<T> create(Args && ...arguments)
+ {
+ typedef QtSharedPointer::ExternalRefCountWithContiguousData<T> Private;
+# ifdef QT_SHAREDPOINTER_TRACK_POINTERS
+ typename Private::DestroyerFn destroy = &Private::safetyCheckDeleter;
+# else
+ typename Private::DestroyerFn destroy = &Private::deleter;
+# endif
+ QSharedPointer<T> result(Qt::Uninitialized);
+ result.d = Private::create(&result.value, destroy);
+
+ // now initialize the data
+ new (result.data()) T(std::forward<Args>(arguments)...);
+ result.d->setQObjectShared(result.value, true);
+# ifdef QT_SHAREDPOINTER_TRACK_POINTERS
+ internalSafetyCheckAdd(result.d, result.value);
+# endif
+ return result;
+ }
+#else
static inline QSharedPointer<T> create()
{
typedef QtSharedPointer::ExternalRefCountWithContiguousData<T> Private;
@@ -408,6 +435,7 @@ public:
result.d->setQObjectShared(result.value, true);
return result;
}
+#endif
private:
explicit QSharedPointer(Qt::Initialization) {}
@@ -616,7 +644,7 @@ private:
public:
#else
template <class X> friend class QSharedPointer;
- friend class QPointerBase;
+ template <class X> friend class QPointer;
#endif
template <class X>
@@ -862,6 +890,4 @@ template<typename T> Q_DECLARE_TYPEINFO_BODY(QSharedPointer<T>, Q_MOVABLE_TYPE);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/tools/qsimd.cpp b/src/corelib/tools/qsimd.cpp
index f2cb5e88ee..97a64eb5bb 100644
--- a/src/corelib/tools/qsimd.cpp
+++ b/src/corelib/tools/qsimd.cpp
@@ -54,7 +54,7 @@
# include <intrin.h>
# endif
# endif
-#elif defined(Q_OS_LINUX) && defined(__arm__)
+#elif defined(Q_OS_LINUX) && (defined(Q_PROCESSOR_ARM) || defined(QT_COMPILER_SUPPORTS_IWMMXT) || defined(QT_COMPILER_SUPPORTS_NEON))
#include "private/qcore_unix_p.h"
// the kernel header definitions for HWCAP_*
diff --git a/src/corelib/tools/qsimd_p.h b/src/corelib/tools/qsimd_p.h
index 2156c2235f..98eb473da0 100644
--- a/src/corelib/tools/qsimd_p.h
+++ b/src/corelib/tools/qsimd_p.h
@@ -45,8 +45,6 @@
#include <qglobal.h>
#include <qatomic.h>
-QT_BEGIN_HEADER
-
/*
* qt_module_config.prf defines the QT_COMPILER_SUPPORTS_XXX macros.
* They mean the compiler supports the necessary flags and the headers
@@ -230,7 +228,7 @@ static const uint qCompilerCpuFeatures = 0
extern Q_CORE_EXPORT QBasicAtomicInt qt_cpu_features;
Q_CORE_EXPORT void qDetectCpuFeatures();
-inline uint qCpuFeatures()
+static inline uint qCpuFeatures()
{
int features = qt_cpu_features.load();
if (Q_UNLIKELY(features == 0)) {
@@ -241,7 +239,7 @@ inline uint qCpuFeatures()
return uint(features);
}
-inline uint qCpuHasFeature(CPUFeatures feature)
+static inline uint qCpuHasFeature(CPUFeatures feature)
{
return qCompilerCpuFeatures & feature || qCpuFeatures() & feature;
}
@@ -252,6 +250,4 @@ inline uint qCpuHasFeature(CPUFeatures feature)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSIMD_P_H
diff --git a/src/corelib/tools/qsize.h b/src/corelib/tools/qsize.h
index bb2cfaff29..76f2ae05f1 100644
--- a/src/corelib/tools/qsize.h
+++ b/src/corelib/tools/qsize.h
@@ -44,8 +44,6 @@
#include <QtCore/qnamespace.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -379,6 +377,4 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QSizeF &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSIZE_H
diff --git a/src/corelib/tools/qstack.h b/src/corelib/tools/qstack.h
index 158e1af6b2..135c4dd527 100644
--- a/src/corelib/tools/qstack.h
+++ b/src/corelib/tools/qstack.h
@@ -44,8 +44,6 @@
#include <QtCore/qvector.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -77,6 +75,4 @@ inline const T &QStack<T>::top() const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTACK_H
diff --git a/src/corelib/tools/qstring.cpp b/src/corelib/tools/qstring.cpp
index 6c64ea9f6d..54b1a084b2 100644
--- a/src/corelib/tools/qstring.cpp
+++ b/src/corelib/tools/qstring.cpp
@@ -966,20 +966,21 @@ const QString::Null QString::null = { };
\sa utf16(), toLatin1(), toUtf8(), toLocal8Bit()
*/
-// ### replace with QCharIterator
int QString::toUcs4_helper(const ushort *uc, int length, uint *out)
{
int i = 0;
- for (; i < length; ++i) {
- uint u = uc[i];
- if (QChar::isHighSurrogate(u) && i + 1 < length) {
- ushort low = uc[i+1];
+ const ushort *const e = uc + length;
+ while (uc < e) {
+ uint u = *uc;
+ if (QChar::isHighSurrogate(u) && uc + 1 < e) {
+ ushort low = uc[1];
if (QChar::isLowSurrogate(low)) {
- ++i;
+ ++uc;
u = QChar::surrogateToUcs4(u, low);
}
}
- *out++ = u;
+ out[i++] = u;
+ ++uc;
}
return i;
}
@@ -2762,13 +2763,17 @@ int QString::lastIndexOf(const QStringRef &str, int from, Qt::CaseSensitivity cs
str.size(), cs);
}
-#ifndef QT_NO_REGEXP
+
+#if !(defined(QT_NO_REGEXP) && defined(QT_NO_REGULAREXPRESSION))
struct QStringCapture
{
int pos;
int len;
int no;
};
+#endif
+
+#ifndef QT_NO_REGEXP
/*!
\overload replace()
@@ -2925,7 +2930,7 @@ QString& QString::replace(const QRegExp &rx, const QString &after)
}
#endif
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
#ifndef QT_BOOTSTRAPPED
/*!
\overload replace()
@@ -3055,7 +3060,7 @@ QString &QString::replace(const QRegularExpression &re, const QString &after)
return *this;
}
#endif // QT_BOOTSTRAPPED
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
/*!
Returns the number of (potentially overlapping) occurrences of
@@ -3256,7 +3261,7 @@ int QString::count(const QRegExp& rx) const
}
#endif // QT_NO_REGEXP
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
#ifndef QT_BOOTSTRAPPED
/*!
\overload indexOf()
@@ -3336,6 +3341,33 @@ bool QString::contains(const QRegularExpression &re) const
}
/*!
+ \overload contains()
+ \since 5.1
+
+ Returns true if the regular expression \a re matches somewhere in this
+ string; otherwise returns false.
+
+ If the match is successful and \a match is not a null pointer, it also
+ writes the results of the match into the QRegularExpressionMatch object
+ pointed by \a match.
+
+ \sa QRegularExpression::match()
+*/
+
+bool QString::contains(const QRegularExpression &re, QRegularExpressionMatch *match) const
+{
+ if (!re.isValid()) {
+ qWarning("QString::contains: invalid QRegularExpresssion object");
+ return false;
+ }
+ QRegularExpressionMatch m = re.match(*this);
+ bool hasMatch = m.hasMatch();
+ if (hasMatch && match)
+ *match = m;
+ return hasMatch;
+}
+
+/*!
\overload count()
\since 5.0
@@ -3366,7 +3398,7 @@ int QString::count(const QRegularExpression &re) const
return count;
}
#endif // QT_BOOTSTRAPPED
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
/*! \fn int QString::count() const
@@ -3487,7 +3519,7 @@ QString QString::section(const QString &sep, int start, int end, SectionFlags fl
return ret;
}
-#ifndef QT_NO_REGEXP
+#if !(defined(QT_NO_REGEXP) && defined(QT_NO_REGULAREXPRESSION))
class qt_section_chunk {
public:
qt_section_chunk(int l, QString s) { length = l; string = s; }
@@ -3537,7 +3569,9 @@ static QString extractSections(const QList<qt_section_chunk> &sections,
return ret;
}
+#endif
+#ifndef QT_NO_REGEXP
/*!
\overload section()
@@ -3575,7 +3609,7 @@ QString QString::section(const QRegExp &reg, int start, int end, SectionFlags fl
}
#endif
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
#ifndef QT_BOOTSTRAPPED
/*!
\overload section()
@@ -3621,7 +3655,7 @@ QString QString::section(const QRegularExpression &re, int start, int end, Secti
return extractSections(sections, start, end, flags);
}
#endif // QT_BOOTSTRAPPED
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
/*!
Returns a substring that contains the \a n leftmost characters
@@ -4094,6 +4128,13 @@ QString::Data *QString::fromAscii_helper(const char *str, int size)
\sa toLatin1(), fromUtf8(), fromLocal8Bit()
*/
+/*!
+ \fn QString QString::fromLatin1(const QByteArray &str)
+ \overload
+ \since 5.0
+
+ Returns a QString initialized with the Latin-1 string \a str.
+*/
/*! \fn QString QString::fromLocal8Bit(const char *str, int size)
Returns a QString initialized with the first \a size characters
@@ -4106,6 +4147,14 @@ QString::Data *QString::fromAscii_helper(const char *str, int size)
\sa toLocal8Bit(), fromLatin1(), fromUtf8()
*/
+
+/*!
+ \fn QString QString::fromLocal8Bit(const QByteArray &str)
+ \overload
+ \since 5.0
+
+ Returns a QString initialized with the 8-bit string \a str.
+*/
QString QString::fromLocal8Bit_helper(const char *str, int size)
{
if (!str)
@@ -4138,6 +4187,15 @@ QString QString::fromLocal8Bit_helper(const char *str, int size)
\sa toAscii(), fromLatin1(), fromUtf8(), fromLocal8Bit()
*/
+/*!
+ \fn QString QString::fromAscii(const QByteArray &str)
+ \deprecated
+ \overload
+ \since 5.0
+
+ Returns a QString initialized with the string \a str.
+*/
+
/*! \fn QString QString::fromUtf8(const char *str, int size)
Returns a QString initialized with the first \a size bytes
of the UTF-8 string \a str.
@@ -4159,6 +4217,14 @@ QString QString::fromLocal8Bit_helper(const char *str, int size)
\sa toUtf8(), fromLatin1(), fromLocal8Bit()
*/
+
+/*!
+ \fn QString QString::fromUtf8(const QByteArray &str)
+ \overload
+ \since 5.0
+
+ Returns a QString initialized with the UTF-8 string \a str.
+*/
QString QString::fromUtf8_helper(const char *str, int size)
{
if (!str)
@@ -5427,8 +5493,10 @@ QString &QString::vsprintf(const char* cformat, va_list ap)
const char *c = cformat;
for (;;) {
// Copy non-escape chars to result
+ const char *cb = c;
while (*c != '\0' && *c != '%')
- result.append(QLatin1Char(*c++));
+ c++;
+ result.append(QString::fromUtf8(cb, (int)(c - cb)));
if (*c == '\0')
break;
@@ -6416,7 +6484,7 @@ QStringList QString::split(const QRegExp &rx, SplitBehavior behavior) const
}
#endif
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
#ifndef QT_BOOTSTRAPPED
/*!
\overload
@@ -6470,7 +6538,7 @@ QStringList QString::split(const QRegularExpression &re, SplitBehavior behavior)
return list;
}
#endif // QT_BOOTSTRAPPED
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
/*!
\enum QString::NormalizationForm
@@ -9160,6 +9228,356 @@ QVector<uint> QStringRef::toUcs4() const
return v;
}
+/*!
+ Returns a string that has whitespace removed from the start and
+ the end.
+
+ Whitespace means any character for which QChar::isSpace() returns
+ true. This includes the ASCII characters '\\t', '\\n', '\\v',
+ '\\f', '\\r', and ' '.
+
+ Unlike QString::simplified(), trimmed() leaves internal whitespace alone.
+
+ \since 5.1
+
+ \sa QString::trimmed()
+*/
+QStringRef QStringRef::trimmed() const
+{
+ if (m_size == 0 || m_string == 0)
+ return *this;
+ const QChar *s = m_string->constData() + m_position;
+ int start = 0;
+ int end = m_size - 1;
+ while (start <= end && s[start].isSpace()) // skip white space from start
+ start++;
+ if (start <= end) { // only white space
+ while (end && s[end].isSpace()) // skip white space from end
+ end--;
+ }
+ int l = end - start + 1;
+ Q_ASSERT(l >= 0);
+ return QStringRef(m_string, m_position + start, l);
+}
+
+/*!
+ Returns the string converted to a \c{long long} using base \a
+ base, which is 10 by default and must be between 2 and 36, or 0.
+ Returns 0 if the conversion fails.
+
+ If a conversion error occurs, *\a{ok} is set to false; otherwise
+ *\a{ok} is set to true.
+
+ If \a base is 0, the C language convention is used: If the string
+ begins with "0x", base 16 is used; if the string begins with "0",
+ base 8 is used; otherwise, base 10 is used.
+
+ The string conversion will always happen in the 'C' locale. For locale
+ dependent conversion use QLocale::toLongLong()
+
+ \sa QString::toLongLong()
+
+ \since 5.1
+*/
+
+qint64 QStringRef::toLongLong(bool *ok, int base) const
+{
+#if defined(QT_CHECK_RANGE)
+ if (base != 0 && (base < 2 || base > 36)) {
+ qWarning("QString::toLongLong: Invalid base (%d)", base);
+ base = 10;
+ }
+#endif
+
+ QLocale c_locale(QLocale::C);
+ return c_locale.d->stringToLongLong(*this, base, ok, QLocalePrivate::FailOnGroupSeparators);
+}
+
+/*!
+ Returns the string converted to an \c{unsigned long long} using base \a
+ base, which is 10 by default and must be between 2 and 36, or 0.
+ Returns 0 if the conversion fails.
+
+ If a conversion error occurs, *\a{ok} is set to false; otherwise
+ *\a{ok} is set to true.
+
+ If \a base is 0, the C language convention is used: If the string
+ begins with "0x", base 16 is used; if the string begins with "0",
+ base 8 is used; otherwise, base 10 is used.
+
+ The string conversion will always happen in the 'C' locale. For locale
+ dependent conversion use QLocale::toULongLong()
+
+ \sa QString::toULongLong()
+
+ \since 5.1
+*/
+
+quint64 QStringRef::toULongLong(bool *ok, int base) const
+{
+#if defined(QT_CHECK_RANGE)
+ if (base != 0 && (base < 2 || base > 36)) {
+ qWarning("QString::toULongLong: Invalid base (%d)", base);
+ base = 10;
+ }
+#endif
+
+ QLocale c_locale(QLocale::C);
+ return c_locale.d->stringToUnsLongLong(*this, base, ok, QLocalePrivate::FailOnGroupSeparators);
+}
+
+/*!
+ \fn long QStringRef::toLong(bool *ok, int base) const
+
+ Returns the string converted to a \c long using base \a
+ base, which is 10 by default and must be between 2 and 36, or 0.
+ Returns 0 if the conversion fails.
+
+ If a conversion error occurs, *\a{ok} is set to false; otherwise
+ *\a{ok} is set to true.
+
+ If \a base is 0, the C language convention is used: If the string
+ begins with "0x", base 16 is used; if the string begins with "0",
+ base 8 is used; otherwise, base 10 is used.
+
+ The string conversion will always happen in the 'C' locale. For locale
+ dependent conversion use QLocale::toLong()
+
+ \sa QString::toLong()
+
+ \since 5.1
+*/
+
+long QStringRef::toLong(bool *ok, int base) const
+{
+ qint64 v = toLongLong(ok, base);
+ if (v < LONG_MIN || v > LONG_MAX) {
+ if (ok)
+ *ok = false;
+ v = 0;
+ }
+ return long(v);
+}
+
+/*!
+ \fn ulong QStringRef::toULong(bool *ok, int base) const
+
+ Returns the string converted to an \c{unsigned long} using base \a
+ base, which is 10 by default and must be between 2 and 36, or 0.
+ Returns 0 if the conversion fails.
+
+ If a conversion error occurs, *\a{ok} is set to false; otherwise
+ *\a{ok} is set to true.
+
+ If \a base is 0, the C language convention is used: If the string
+ begins with "0x", base 16 is used; if the string begins with "0",
+ base 8 is used; otherwise, base 10 is used.
+
+ The string conversion will always happen in the 'C' locale. For locale
+ dependent conversion use QLocale::toULong()
+
+ \sa QString::toULong()
+
+ \since 5.1
+*/
+
+ulong QStringRef::toULong(bool *ok, int base) const
+{
+ quint64 v = toULongLong(ok, base);
+ if (v > ULONG_MAX) {
+ if (ok)
+ *ok = false;
+ v = 0;
+ }
+ return ulong(v);
+}
+
+
+/*!
+ Returns the string converted to an \c int using base \a
+ base, which is 10 by default and must be between 2 and 36, or 0.
+ Returns 0 if the conversion fails.
+
+ If a conversion error occurs, *\a{ok} is set to false; otherwise
+ *\a{ok} is set to true.
+
+ If \a base is 0, the C language convention is used: If the string
+ begins with "0x", base 16 is used; if the string begins with "0",
+ base 8 is used; otherwise, base 10 is used.
+
+ The string conversion will always happen in the 'C' locale. For locale
+ dependent conversion use QLocale::toInt()
+
+ \sa QString::toInt()
+
+ \since 5.1
+*/
+
+int QStringRef::toInt(bool *ok, int base) const
+{
+ qint64 v = toLongLong(ok, base);
+ if (v < INT_MIN || v > INT_MAX) {
+ if (ok)
+ *ok = false;
+ v = 0;
+ }
+ return int(v);
+}
+
+/*!
+ Returns the string converted to an \c{unsigned int} using base \a
+ base, which is 10 by default and must be between 2 and 36, or 0.
+ Returns 0 if the conversion fails.
+
+ If a conversion error occurs, *\a{ok} is set to false; otherwise
+ *\a{ok} is set to true.
+
+ If \a base is 0, the C language convention is used: If the string
+ begins with "0x", base 16 is used; if the string begins with "0",
+ base 8 is used; otherwise, base 10 is used.
+
+ The string conversion will always happen in the 'C' locale. For locale
+ dependent conversion use QLocale::toUInt()
+
+ \sa QString::toUInt()
+
+ \since 5.1
+*/
+
+uint QStringRef::toUInt(bool *ok, int base) const
+{
+ quint64 v = toULongLong(ok, base);
+ if (v > UINT_MAX) {
+ if (ok)
+ *ok = false;
+ v = 0;
+ }
+ return uint(v);
+}
+
+/*!
+ Returns the string converted to a \c short using base \a
+ base, which is 10 by default and must be between 2 and 36, or 0.
+ Returns 0 if the conversion fails.
+
+ If a conversion error occurs, *\a{ok} is set to false; otherwise
+ *\a{ok} is set to true.
+
+ If \a base is 0, the C language convention is used: If the string
+ begins with "0x", base 16 is used; if the string begins with "0",
+ base 8 is used; otherwise, base 10 is used.
+
+ The string conversion will always happen in the 'C' locale. For locale
+ dependent conversion use QLocale::toShort()
+
+ \sa QString::toShort()
+
+ \since 5.1
+*/
+
+short QStringRef::toShort(bool *ok, int base) const
+{
+ long v = toLongLong(ok, base);
+ if (v < SHRT_MIN || v > SHRT_MAX) {
+ if (ok)
+ *ok = false;
+ v = 0;
+ }
+ return short(v);
+}
+
+/*!
+ Returns the string converted to an \c{unsigned short} using base \a
+ base, which is 10 by default and must be between 2 and 36, or 0.
+ Returns 0 if the conversion fails.
+
+ If a conversion error occurs, *\a{ok} is set to false; otherwise
+ *\a{ok} is set to true.
+
+ If \a base is 0, the C language convention is used: If the string
+ begins with "0x", base 16 is used; if the string begins with "0",
+ base 8 is used; otherwise, base 10 is used.
+
+ The string conversion will always happen in the 'C' locale. For locale
+ dependent conversion use QLocale::toUShort()
+
+ \sa QString::toUShort()
+
+ \since 5.1
+*/
+
+ushort QStringRef::toUShort(bool *ok, int base) const
+{
+ ulong v = toULongLong(ok, base);
+ if (v > USHRT_MAX) {
+ if (ok)
+ *ok = false;
+ v = 0;
+ }
+ return ushort(v);
+}
+
+
+/*!
+ Returns the string converted to a \c double value.
+
+ Returns 0.0 if the conversion fails.
+
+ If a conversion error occurs, \c{*}\a{ok} is set to false;
+ otherwise \c{*}\a{ok} is set to true.
+
+ The string conversion will always happen in the 'C' locale. For locale
+ dependent conversion use QLocale::toDouble()
+
+ For historic reasons, this function does not handle
+ thousands group separators. If you need to convert such numbers,
+ use QLocale::toDouble().
+
+ \sa QString::toDouble()
+
+ \since 5.1
+*/
+
+double QStringRef::toDouble(bool *ok) const
+{
+ QLocale c_locale(QLocale::C);
+ return c_locale.d->stringToDouble(*this, ok, QLocalePrivate::FailOnGroupSeparators);
+}
+
+/*!
+ Returns the string converted to a \c float value.
+
+ If a conversion error occurs, *\a{ok} is set to false; otherwise
+ *\a{ok} is set to true. Returns 0.0 if the conversion fails.
+
+ The string conversion will always happen in the 'C' locale. For locale
+ dependent conversion use QLocale::toFloat()
+
+ \sa QString::toFloat()
+
+ \since 5.1
+*/
+
+float QStringRef::toFloat(bool *ok) const
+{
+ bool myOk;
+ double d = toDouble(&myOk);
+ if (!myOk) {
+ if (ok != 0)
+ *ok = false;
+ return 0.0;
+ }
+ if (qIsInf(d))
+ return float(d);
+ if (d > QT_MAX_FLOAT || d < -QT_MAX_FLOAT) {
+ if (ok != 0)
+ *ok = false;
+ return 0.0;
+ }
+ if (ok)
+ *ok = true;
+ return float(d);
+}
/*!
\obsolete
@@ -9169,6 +9587,8 @@ QVector<uint> QStringRef::toUcs4() const
*/
/*!
+ \since 5.0
+
Converts a plain text string to an HTML string with
HTML metacharacters \c{<}, \c{>}, \c{&}, and \c{"} replaced by HTML
entities.
@@ -9237,6 +9657,19 @@ QString QString::toHtmlEscaped() const
\code
if (attribute.name() == QLatin1String("http-contents-length")) //...
\endcode
+
+ \note There some restrictions when using the MSVC 2010 or 2012 compilers. The example snippets provided here
+ fail to compile with them.
+ \list
+ \li Concatenated string literals cannot be used with QStringLiteral.
+ \code
+ QString s = QStringLiteral("a" "b");
+ \endcode
+ \li QStringLiteral cannot be used to initialize lists or arrays of QString.
+ \code
+ QString a[] = { QStringLiteral("a"), QStringLiteral("b") };
+ \endcode
+ \endlist
*/
QT_END_NAMESPACE
diff --git a/src/corelib/tools/qstring.h b/src/corelib/tools/qstring.h
index a6f03b2ce0..ac49bdcdf6 100644
--- a/src/corelib/tools/qstring.h
+++ b/src/corelib/tools/qstring.h
@@ -49,7 +49,7 @@
#include <string>
-#if defined(Q_OS_LINUX_ANDROID)
+#if defined(Q_OS_ANDROID)
// std::wstring is disabled on android's glibc, as bionic lacks certain features
// that libstdc++ checks for (like mbcslen).
namespace std
@@ -64,14 +64,13 @@ namespace std
#error qstring.h must be included before any header file that defines truncate
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QCharRef;
class QRegExp;
class QRegularExpression;
+class QRegularExpressionMatch;
class QString;
class QStringList;
class QTextCodec;
@@ -335,10 +334,11 @@ public:
inline bool contains(QRegExp &rx) const { return indexOf(rx) != -1; }
#endif
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
int indexOf(const QRegularExpression &re, int from = 0) const;
int lastIndexOf(const QRegularExpression &re, int from = -1) const;
bool contains(const QRegularExpression &re) const;
+ bool contains(const QRegularExpression &re, QRegularExpressionMatch *match) const; // ### Qt 6: merge overloads
int count(const QRegularExpression &re) const;
#endif
@@ -356,7 +356,7 @@ public:
#ifndef QT_NO_REGEXP
QString section(const QRegExp &reg, int start, int end = -1, SectionFlags flags = SectionDefault) const;
#endif
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
QString section(const QRegularExpression &re, int start, int end = -1, SectionFlags flags = SectionDefault) const;
#endif
QString left(int n) const Q_REQUIRED_RESULT;
@@ -432,7 +432,7 @@ public:
inline QString &remove(const QRegExp &rx)
{ return replace(rx, QString()); }
#endif
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
QString &replace(const QRegularExpression &re, const QString &after);
inline QString &remove(const QRegularExpression &re)
{ return replace(re, QString()); }
@@ -447,7 +447,7 @@ public:
#ifndef QT_NO_REGEXP
QStringList split(const QRegExp &sep, SplitBehavior behavior = KeepEmptyParts) const Q_REQUIRED_RESULT;
#endif
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
QStringList split(const QRegularExpression &sep, SplitBehavior behavior = KeepEmptyParts) const Q_REQUIRED_RESULT;
#endif
enum NormalizationForm {
@@ -884,6 +884,8 @@ public:
QChar::Decomposition decompositionTag() const { return QChar(*this).decompositionTag(); }
uchar combiningClass() const { return QChar(*this).combiningClass(); }
+ inline QChar::Script script() const { return QChar(*this).script(); }
+
QChar::UnicodeVersion unicodeVersion() const { return QChar(*this).unicodeVersion(); }
inline uchar cell() const { return QChar(*this).cell(); }
@@ -1171,13 +1173,17 @@ class Q_CORE_EXPORT QStringRef {
int m_position;
int m_size;
public:
+ // ### Qt 6: make this constructor constexpr, after the destructor is made trivial
inline QStringRef():m_string(0), m_position(0), m_size(0){}
inline QStringRef(const QString *string, int position, int size);
inline QStringRef(const QString *string);
+
+ // ### Qt 6: remove this copy constructor, the implicit one is fine
inline QStringRef(const QStringRef &other)
:m_string(other.m_string), m_position(other.m_position), m_size(other.m_size)
{}
+ // ### Qt 6: remove this destructor, the implicit one is fine
inline ~QStringRef(){}
inline const QString *string() const { return m_string; }
inline int position() const { return m_position; }
@@ -1271,6 +1277,18 @@ public:
int localeAwareCompare(const QStringRef &s) const;
static int localeAwareCompare(const QStringRef &s1, const QString &s2);
static int localeAwareCompare(const QStringRef &s1, const QStringRef &s2);
+
+ QStringRef trimmed() const Q_REQUIRED_RESULT;
+ short toShort(bool *ok = 0, int base = 10) const;
+ ushort toUShort(bool *ok = 0, int base = 10) const;
+ int toInt(bool *ok = 0, int base = 10) const;
+ uint toUInt(bool *ok = 0, int base = 10) const;
+ long toLong(bool *ok = 0, int base = 10) const;
+ ulong toULong(bool *ok = 0, int base = 10) const;
+ qlonglong toLongLong(bool *ok = 0, int base = 10) const;
+ qulonglong toULongLong(bool *ok = 0, int base = 10) const;
+ float toFloat(bool *ok = 0) const;
+ double toDouble(bool *ok = 0) const;
};
Q_DECLARE_TYPEINFO(QStringRef, Q_PRIMITIVE_TYPE);
@@ -1386,8 +1404,6 @@ QT_DEPRECATED inline QString escape(const QString &plain) {
QT_END_NAMESPACE
-QT_END_HEADER
-
#if defined(QT_USE_FAST_OPERATOR_PLUS) || defined(QT_USE_QSTRINGBUILDER)
#include <QtCore/qstringbuilder.h>
#endif
diff --git a/src/corelib/tools/qstringbuilder.h b/src/corelib/tools/qstringbuilder.h
index 67d5bde2ce..e09b02b5a9 100644
--- a/src/corelib/tools/qstringbuilder.h
+++ b/src/corelib/tools/qstringbuilder.h
@@ -54,8 +54,6 @@
#include <string.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -429,6 +427,4 @@ QString &operator+=(QString &a, const QStringBuilder<A, B> &b)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTRINGBUILDER_H
diff --git a/src/corelib/tools/qstringlist.cpp b/src/corelib/tools/qstringlist.cpp
index f48db4a643..a5559a181b 100644
--- a/src/corelib/tools/qstringlist.cpp
+++ b/src/corelib/tools/qstringlist.cpp
@@ -320,7 +320,7 @@ QStringList QtPrivate::QStringList_filter(const QStringList *that, const QRegExp
#endif
#ifndef QT_BOOTSTRAPPED
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
/*!
\fn QStringList QStringList::filter(const QRegularExpression &re) const
\overload
@@ -338,7 +338,7 @@ QStringList QtPrivate::QStringList_filter(const QStringList *that, const QRegula
}
return res;
}
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
#endif // QT_BOOTSTRAPPED
/*!
@@ -395,7 +395,7 @@ void QtPrivate::QStringList_replaceInStrings(QStringList *that, const QRegExp &r
#endif
#ifndef QT_BOOTSTRAPPED
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
/*!
\fn QStringList &QStringList::replaceInStrings(const QRegularExpression &re, const QString &after)
\overload
@@ -424,7 +424,7 @@ void QtPrivate::QStringList_replaceInStrings(QStringList *that, const QRegularEx
for (int i = 0; i < that->size(); ++i)
(*that)[i].replace(re, after);
}
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
#endif // QT_BOOTSTRAPPED
/*!
@@ -619,7 +619,7 @@ int QtPrivate::QStringList_lastIndexOf(const QStringList *that, QRegExp &rx, int
#endif
#ifndef QT_BOOTSTRAPPED
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
/*!
\fn int QStringList::indexOf(const QRegularExpression &re, int from) const
\overload
@@ -676,7 +676,7 @@ int QtPrivate::QStringList_lastIndexOf(const QStringList *that, const QRegularEx
}
return -1;
}
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
#endif // QT_BOOTSTRAPPED
/*!
@@ -738,7 +738,8 @@ int QtPrivate::QStringList_removeDuplicates(QStringList *that)
Construct a list from a std::initializer_list given by \a args.
- This constructor is only enabled if the compiler supports C++0x
+ This constructor is only enabled if the compiler supports C++11 initializer
+ lists.
*/
diff --git a/src/corelib/tools/qstringlist.h b/src/corelib/tools/qstringlist.h
index 8ae6e3653a..a962b7c528 100644
--- a/src/corelib/tools/qstringlist.h
+++ b/src/corelib/tools/qstringlist.h
@@ -49,8 +49,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qstringmatcher.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -99,12 +97,12 @@ public:
#endif
#ifndef QT_BOOTSTRAPPED
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
inline QStringList filter(const QRegularExpression &re) const;
inline QStringList &replaceInStrings(const QRegularExpression &re, const QString &after);
inline int indexOf(const QRegularExpression &re, int from = 0) const;
inline int lastIndexOf(const QRegularExpression &re, int from = -1) const;
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
#endif // QT_BOOTSTRAPPED
#if !defined(Q_NO_USING_KEYWORD)
@@ -141,12 +139,12 @@ namespace QtPrivate {
#endif
#ifndef QT_BOOTSTRAPPED
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
void Q_CORE_EXPORT QStringList_replaceInStrings(QStringList *that, const QRegularExpression &rx, const QString &after);
QStringList Q_CORE_EXPORT QStringList_filter(const QStringList *that, const QRegularExpression &re);
int Q_CORE_EXPORT QStringList_indexOf(const QStringList *that, const QRegularExpression &re, int from);
int Q_CORE_EXPORT QStringList_lastIndexOf(const QStringList *that, const QRegularExpression &re, int from);
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
#endif // QT_BOOTSTRAPPED
}
@@ -220,7 +218,7 @@ inline int QStringList::lastIndexOf(QRegExp &rx, int from) const
#endif
#ifndef QT_BOOTSTRAPPED
-#ifndef QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
inline QStringList &QStringList::replaceInStrings(const QRegularExpression &rx, const QString &after)
{
QtPrivate::QStringList_replaceInStrings(this, rx, after);
@@ -241,7 +239,7 @@ inline int QStringList::lastIndexOf(const QRegularExpression &rx, int from) cons
{
return QtPrivate::QStringList_lastIndexOf(this, rx, from);
}
-#endif // QT_NO_REGEXP
+#endif // QT_NO_REGULAREXPRESSION
#endif // QT_BOOTSTRAPPED
#ifndef QT_NO_DATASTREAM
@@ -257,6 +255,4 @@ inline QDataStream &operator<<(QDataStream &out, const QStringList &list)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTRINGLIST_H
diff --git a/src/corelib/tools/qstringmatcher.cpp b/src/corelib/tools/qstringmatcher.cpp
index 0aacea4762..d54e9c7ba7 100644
--- a/src/corelib/tools/qstringmatcher.cpp
+++ b/src/corelib/tools/qstringmatcher.cpp
@@ -198,6 +198,7 @@ QStringMatcher::QStringMatcher(const QStringMatcher &other)
*/
QStringMatcher::~QStringMatcher()
{
+ Q_UNUSED(d_ptr);
}
/*!
diff --git a/src/corelib/tools/qstringmatcher.h b/src/corelib/tools/qstringmatcher.h
index 1634255f2e..792b97591a 100644
--- a/src/corelib/tools/qstringmatcher.h
+++ b/src/corelib/tools/qstringmatcher.h
@@ -44,8 +44,6 @@
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -97,6 +95,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTRINGMATCHER_H
diff --git a/src/corelib/tools/qtextboundaryfinder.cpp b/src/corelib/tools/qtextboundaryfinder.cpp
index 9ccfe95b1d..7b8fbebb22 100644
--- a/src/corelib/tools/qtextboundaryfinder.cpp
+++ b/src/corelib/tools/qtextboundaryfinder.cpp
@@ -41,7 +41,6 @@
#include <QtCore/qtextboundaryfinder.h>
#include <QtCore/qvarlengtharray.h>
-#include <private/qunicodetables_p.h>
#include <private/qunicodetools_p.h>
QT_BEGIN_NAMESPACE
@@ -54,39 +53,24 @@ public:
static void init(QTextBoundaryFinder::BoundaryType type, const QChar *chars, int length, QCharAttributes *attributes)
{
+ const ushort *string = reinterpret_cast<const ushort *>(chars);
+
QVarLengthArray<QUnicodeTools::ScriptItem> scriptItems;
+ {
+ QVarLengthArray<uchar> scripts(length);
- const ushort *string = reinterpret_cast<const ushort *>(chars);
- const ushort *unicode = string;
- // correctly assign script, isTab and isObject to the script analysis
- const ushort *uc = unicode;
- const ushort *e = uc + length;
- int script = QUnicodeTables::Common;
- int lastScript = QUnicodeTables::Common;
- const ushort *start = uc;
- while (uc < e) {
- int s = QUnicodeTables::script(*uc);
- if (s != QUnicodeTables::Inherited)
- script = s;
- if (*uc == QChar::ObjectReplacementCharacter || *uc == QChar::LineSeparator || *uc == 9)
- script = QUnicodeTables::Common;
- if (script != lastScript) {
- if (uc != start) {
+ QUnicodeTools::initScripts(string, length, scripts.data());
+
+ int start = 0;
+ for (int i = start + 1; i <= length; ++i) {
+ if (i == length || scripts[i] != scripts[start]) {
QUnicodeTools::ScriptItem item;
- item.position = start - string;
- item.script = lastScript;
+ item.position = start;
+ item.script = scripts[start];
scriptItems.append(item);
- start = uc;
+ start = i;
}
- lastScript = script;
}
- ++uc;
- }
- if (uc != start) {
- QUnicodeTools::ScriptItem item;
- item.position = start - string;
- item.script = lastScript;
- scriptItems.append(item);
}
QUnicodeTools::CharAttributeOptions options = 0;
@@ -100,7 +84,7 @@ static void init(QTextBoundaryFinder::BoundaryType type, const QChar *chars, int
QUnicodeTools::initCharAttributes(string, length, scriptItems.data(), scriptItems.count(), attributes, options);
}
-/*!
+/*!
\class QTextBoundaryFinder
\inmodule QtCore
@@ -245,6 +229,7 @@ QTextBoundaryFinder &QTextBoundaryFinder::operator=(const QTextBoundaryFinder &o
*/
QTextBoundaryFinder::~QTextBoundaryFinder()
{
+ Q_UNUSED(unused);
if (freePrivate)
free(d);
}
diff --git a/src/corelib/tools/qtextboundaryfinder.h b/src/corelib/tools/qtextboundaryfinder.h
index e05547359f..81cd0dddf0 100644
--- a/src/corelib/tools/qtextboundaryfinder.h
+++ b/src/corelib/tools/qtextboundaryfinder.h
@@ -45,8 +45,6 @@
#include <QtCore/qchar.h>
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -111,7 +109,5 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QTextBoundaryFinder::BoundaryReasons)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/tools/qtimeline.cpp b/src/corelib/tools/qtimeline.cpp
index 390effb6c2..976c03aef4 100644
--- a/src/corelib/tools/qtimeline.cpp
+++ b/src/corelib/tools/qtimeline.cpp
@@ -744,7 +744,10 @@ void QTimeLine::setPaused(bool paused)
d->timerId = 0;
d->setState(Paused);
} else if (!paused && d->state == Paused) {
+ // Same as resume()
d->timerId = startTimer(d->updateInterval);
+ d->startTime = d->currentTime;
+ d->timer.start();
d->setState(Running);
}
}
diff --git a/src/corelib/tools/qtimeline.h b/src/corelib/tools/qtimeline.h
index 6b5c479cb1..be2a4ae734 100644
--- a/src/corelib/tools/qtimeline.h
+++ b/src/corelib/tools/qtimeline.h
@@ -45,8 +45,6 @@
#include <QtCore/qeasingcurve.h>
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -156,7 +154,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/corelib/tools/qunicodetables.cpp b/src/corelib/tools/qunicodetables.cpp
index b9f91cdb74..764a4afa04 100644
--- a/src/corelib/tools/qunicodetables.cpp
+++ b/src/corelib/tools/qunicodetables.cpp
@@ -70,109 +70,41 @@ static const unsigned short uc_property_trie[] = {
10224, 10256, 10288, 10320, 10352, 10384, 10416, 10448,
10480, 10480, 10512, 10544, 10544, 10576, 10608, 10640,
10672, 10704, 10736, 10704, 10768, 10800, 10832, 10864,
- 10896, 10704, 10928, 10960, 10992, 10704, 10704, 11024,
- 11056, 10704, 10704, 10704, 10704, 10704, 10704, 10704,
- 10704, 10704, 10704, 10704, 10704, 10704, 10704, 10704,
- 10704, 10704, 10704, 11088, 11120, 11152, 11152, 11184,
- 11216, 11248, 11280, 11312, 11344, 11376, 11408, 11440,
- 11472, 10704, 11504, 11536, 10704, 11568, 11600, 11632,
- 11664, 11696, 11728, 11760, 11792, 11824, 11856, 11888,
- 11920, 11952, 11984, 12016, 12048, 12080, 9872, 9872,
- 12112, 12144, 12176, 12208, 12240, 12272, 12304, 12336,
- 12368, 12400, 12432, 12464, 9872, 9872, 12496, 12528,
- 12560, 12592, 12624, 12656, 12688, 12720, 12752, 12784,
- 6512, 6512, 6512, 6512, 12816, 6512, 6512, 12848,
- 12880, 12912, 12944, 12976, 13008, 13040, 13072, 13104,
-
- 13136, 13168, 13200, 13232, 13264, 13296, 13328, 13360,
- 13392, 13424, 13456, 13488, 13520, 13552, 13584, 13616,
- 13648, 13680, 13712, 13744, 13776, 13808, 13840, 13872,
- 13904, 13936, 13968, 14000, 14032, 14064, 14096, 14128,
- 14160, 14192, 14224, 14256, 14288, 14320, 14352, 14384,
- 14160, 14160, 14160, 14160, 14416, 14448, 14480, 14512,
- 14544, 14576, 14160, 14608, 14640, 14672, 14704, 14736,
- 14768, 14800, 14832, 14864, 14896, 14928, 14960, 14992,
- 15024, 15024, 15024, 15024, 15024, 15024, 15024, 15024,
- 15056, 15056, 15056, 15056, 15088, 15120, 15152, 15184,
- 15056, 15216, 15056, 15248, 15280, 15312, 15344, 15376,
- 15408, 15440, 15472, 9872, 9872, 9872, 9872, 9872,
- 15504, 15536, 15568, 15600, 15632, 15632, 15632, 15664,
- 15696, 15728, 15760, 15792, 15824, 15856, 15856, 15888,
- 15920, 15952, 9872, 9872, 15984, 16016, 16016, 16048,
- 16016, 16016, 16016, 16016, 16016, 16016, 16080, 16112,
-
- 16144, 16176, 16208, 16240, 16272, 16304, 16336, 16368,
- 16400, 16432, 16464, 16464, 16496, 16528, 16560, 16592,
- 16624, 16656, 16688, 16720, 16656, 16752, 16784, 16816,
- 16848, 16848, 16880, 16912, 16944, 16944, 16976, 17008,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
-
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17040, 17040, 17040,
- 17040, 17040, 17040, 17040, 17040, 17072, 17104, 17104,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
-
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
-
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
-
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
+ 10896, 10704, 10928, 10960, 10992, 11024, 11024, 11056,
+ 11088, 11120, 11120, 11120, 11120, 11120, 11120, 11120,
+ 11120, 11120, 11120, 11120, 11120, 11120, 11120, 11120,
+ 11120, 11120, 11120, 11152, 11184, 11216, 11216, 11248,
+ 11280, 11312, 11344, 11376, 11408, 11440, 11472, 11504,
+ 11536, 11568, 11600, 11632, 11568, 11664, 11696, 11728,
+ 11760, 11792, 11824, 11856, 11888, 11920, 11952, 11984,
+ 12016, 12048, 12080, 12112, 12144, 12176, 9872, 9872,
+ 12208, 12240, 12272, 12304, 12336, 12368, 12400, 12432,
+ 12464, 12496, 12528, 12560, 9872, 9872, 12592, 12624,
+ 12656, 12688, 12720, 12752, 12784, 12816, 12848, 12880,
+ 6512, 6512, 6512, 6512, 12912, 6512, 6512, 12944,
+ 12976, 13008, 13040, 13072, 13104, 13136, 13168, 13200,
+
+ 13232, 13264, 13296, 13328, 13360, 13392, 13424, 13456,
+ 13488, 13520, 13552, 13584, 13616, 13648, 13680, 13712,
+ 13744, 13776, 13808, 13840, 13872, 13904, 13936, 13968,
+ 14000, 14032, 14064, 14096, 14128, 14160, 14192, 14224,
+ 14256, 14288, 14320, 14352, 14384, 14416, 14448, 14480,
+ 14256, 14256, 14256, 14256, 14512, 14544, 14576, 14608,
+ 14640, 14672, 14256, 14704, 14736, 14768, 14800, 14832,
+ 14864, 14896, 14928, 14960, 14992, 15024, 15056, 15088,
+ 15120, 15120, 15120, 15120, 15120, 15120, 15120, 15120,
+ 15152, 15152, 15152, 15152, 15184, 15216, 15248, 15280,
+ 15152, 15312, 15152, 15344, 15376, 15408, 15440, 15472,
+ 15504, 15536, 15568, 9872, 9872, 9872, 9872, 9872,
+ 15600, 15632, 15664, 15696, 15728, 15728, 15728, 15760,
+ 15792, 15824, 15856, 15888, 15920, 15952, 15952, 15984,
+ 16016, 16048, 9872, 9872, 16080, 16112, 16112, 16144,
+ 16112, 16112, 16112, 16112, 16112, 16112, 16176, 16208,
+
+ 16240, 16272, 16304, 16336, 16368, 16400, 16432, 16464,
+ 16496, 16528, 16560, 16560, 16592, 16624, 16656, 16688,
+ 16720, 16752, 16784, 16816, 16752, 16848, 16880, 16912,
+ 16944, 16944, 16976, 17008, 17040, 17040, 17072, 17104,
17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
@@ -199,674 +131,742 @@ static const unsigned short uc_property_trie[] = {
17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
-
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 17136, 17136, 17136, 17136, 17168, 17200, 17232,
-
- 17264, 17296, 17296, 17296, 17296, 17296, 17296, 17296,
- 17296, 17296, 17296, 17296, 17296, 17296, 17296, 17296,
- 17296, 17296, 17296, 17296, 17296, 17296, 17296, 17296,
- 17296, 17296, 17296, 17296, 17296, 17296, 17296, 17296,
- 17296, 17296, 17296, 17296, 17328, 17360, 17392, 17424,
- 12368, 12368, 12368, 12368, 12368, 12368, 12368, 12368,
- 17456, 17488, 17520, 17552, 17584, 11600, 11600, 17616,
- 17648, 17680, 17712, 17744, 17776, 17808, 9872, 17840,
- 17872, 17904, 17936, 17968, 18000, 18032, 18064, 18096,
- 18128, 18160, 18192, 18224, 18256, 18288, 18320, 9872,
- 12368, 18352, 18384, 18416, 11952, 18448, 18480, 18512,
- 18544, 18576, 9872, 9872, 9872, 9872, 11600, 18608,
- 18640, 18672, 18704, 18736, 18768, 18800, 18832, 18640,
- 18672, 18704, 18736, 18768, 18800, 18832, 18640, 18672,
- 18704, 18736, 18768, 18800, 18832, 18640, 18672, 18704,
- 18736, 18768, 18800, 18832, 18640, 18672, 18704, 18736,
-
- 18768, 18800, 18832, 18640, 18672, 18704, 18736, 18768,
- 18800, 18832, 18640, 18672, 18704, 18736, 18768, 18800,
- 18832, 18640, 18672, 18704, 18736, 18768, 18800, 18832,
- 18640, 18672, 18704, 18736, 18768, 18800, 18832, 18640,
- 18672, 18704, 18736, 18768, 18800, 18832, 18640, 18672,
- 18704, 18736, 18768, 18800, 18832, 18640, 18672, 18704,
- 18736, 18768, 18800, 18832, 18640, 18672, 18704, 18736,
- 18768, 18800, 18832, 18640, 18672, 18704, 18736, 18768,
- 18800, 18832, 18640, 18672, 18704, 18736, 18768, 18800,
- 18832, 18640, 18672, 18704, 18736, 18768, 18800, 18832,
- 18640, 18672, 18704, 18736, 18768, 18800, 18832, 18640,
- 18672, 18704, 18736, 18768, 18800, 18832, 18640, 18672,
- 18704, 18736, 18768, 18800, 18832, 18640, 18672, 18704,
- 18736, 18768, 18800, 18832, 18640, 18672, 18704, 18736,
- 18768, 18800, 18832, 18640, 18672, 18704, 18736, 18768,
- 18800, 18832, 18640, 18672, 18704, 18736, 18768, 18800,
-
- 18832, 18640, 18672, 18704, 18736, 18768, 18800, 18832,
- 18640, 18672, 18704, 18736, 18768, 18800, 18832, 18640,
- 18672, 18704, 18736, 18768, 18800, 18832, 18640, 18672,
- 18704, 18736, 18768, 18800, 18832, 18640, 18672, 18704,
- 18736, 18768, 18800, 18832, 18640, 18672, 18704, 18736,
- 18768, 18800, 18832, 18640, 18672, 18704, 18736, 18768,
- 18800, 18832, 18640, 18672, 18704, 18736, 18768, 18800,
- 18832, 18640, 18672, 18704, 18736, 18768, 18800, 18832,
- 18640, 18672, 18704, 18736, 18768, 18800, 18832, 18640,
- 18672, 18704, 18736, 18768, 18800, 18832, 18640, 18672,
- 18704, 18736, 18768, 18800, 18832, 18640, 18672, 18704,
- 18736, 18768, 18800, 18832, 18640, 18672, 18704, 18736,
- 18768, 18800, 18832, 18640, 18672, 18704, 18736, 18768,
- 18800, 18832, 18640, 18672, 18704, 18736, 18768, 18800,
- 18832, 18640, 18672, 18704, 18736, 18768, 18800, 18832,
- 18640, 18672, 18704, 18736, 18768, 18800, 18832, 18640,
-
- 18672, 18704, 18736, 18768, 18800, 18832, 18640, 18672,
- 18704, 18736, 18768, 18800, 18832, 18640, 18672, 18704,
- 18736, 18768, 18800, 18832, 18640, 18672, 18704, 18736,
- 18768, 18800, 18832, 18640, 18672, 18704, 18736, 18768,
- 18800, 18832, 18640, 18672, 18704, 18736, 18768, 18800,
- 18832, 18640, 18672, 18704, 18736, 18768, 18800, 18832,
- 18640, 18672, 18704, 18736, 18768, 18800, 18832, 18640,
- 18672, 18704, 18736, 18768, 18800, 18864, 18896, 18928,
- 18960, 18960, 18960, 18960, 18960, 18960, 18960, 18960,
- 18960, 18960, 18960, 18960, 18960, 18960, 18960, 18960,
- 18960, 18960, 18960, 18960, 18960, 18960, 18960, 18960,
- 18960, 18960, 18960, 18960, 18960, 18960, 18960, 18960,
- 18960, 18960, 18960, 18960, 18960, 18960, 18960, 18960,
- 18960, 18960, 18960, 18960, 18960, 18960, 18960, 18960,
- 18960, 18960, 18960, 18960, 18960, 18960, 18960, 18960,
- 18960, 18960, 18960, 18960, 18960, 18960, 18960, 18960,
-
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
-
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 18992, 18992, 18992, 18992, 18992, 18992, 18992, 18992,
- 17136, 17136, 17136, 17136, 17136, 17136, 17136, 17136,
- 17136, 19024, 19056, 19088, 19120, 19120, 19152, 17232,
- 19184, 19216, 19248, 19280, 19280, 19312, 19344, 19280,
- 19280, 19280, 19280, 19280, 19280, 19280, 19280, 19280,
- 19280, 19376, 19408, 19280, 19440, 19280, 19472, 19504,
- 19536, 19568, 19600, 19632, 19280, 19280, 19280, 19664,
- 19696, 19728, 19760, 19792, 19824, 19856, 19888, 19920,
-
- 19952, 19984, 20016, 9872, 20048, 20048, 20048, 20080,
- 20112, 20144, 20176, 20208, 20240, 9872, 20272, 20304,
- 9872, 9872, 9872, 9872, 20336, 12368, 20368, 9872,
- 20400, 20432, 20464, 9872, 20496, 15760, 20528, 9872,
- 20560, 20592, 20624, 20048, 20656, 20688, 9872, 9872,
+ 17136, 17136, 17136, 17136, 17136, 17168, 17200, 17200,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 17232, 17232, 17232, 17232, 17264, 17296, 17328,
+
+ 17360, 17392, 17392, 17392, 17392, 17392, 17392, 17392,
+ 17392, 17392, 17392, 17392, 17392, 17392, 17392, 17392,
+ 17392, 17392, 17392, 17392, 17392, 17392, 17392, 17392,
+ 17392, 17392, 17392, 17392, 17392, 17392, 17392, 17392,
+ 17392, 17392, 17392, 17392, 17424, 17456, 17488, 17520,
+ 17552, 17552, 17552, 17552, 17552, 17552, 17552, 17552,
+ 17584, 17616, 17648, 17680, 17712, 17744, 17744, 17776,
+ 17808, 17840, 17872, 17904, 17936, 17968, 9872, 18000,
+ 18032, 18064, 18096, 18128, 18160, 18192, 18224, 18256,
+ 18288, 18320, 18352, 18384, 18416, 18448, 18480, 9872,
+ 18512, 18544, 18576, 18608, 18640, 18672, 18704, 18736,
+ 18768, 18800, 9872, 9872, 9872, 9872, 18832, 18864,
+ 18896, 18928, 18960, 18992, 19024, 19056, 19088, 18896,
+ 18928, 18960, 18992, 19024, 19056, 19088, 18896, 18928,
+ 18960, 18992, 19024, 19056, 19088, 18896, 18928, 18960,
+ 18992, 19024, 19056, 19088, 18896, 18928, 18960, 18992,
+
+ 19024, 19056, 19088, 18896, 18928, 18960, 18992, 19024,
+ 19056, 19088, 18896, 18928, 18960, 18992, 19024, 19056,
+ 19088, 18896, 18928, 18960, 18992, 19024, 19056, 19088,
+ 18896, 18928, 18960, 18992, 19024, 19056, 19088, 18896,
+ 18928, 18960, 18992, 19024, 19056, 19088, 18896, 18928,
+ 18960, 18992, 19024, 19056, 19088, 18896, 18928, 18960,
+ 18992, 19024, 19056, 19088, 18896, 18928, 18960, 18992,
+ 19024, 19056, 19088, 18896, 18928, 18960, 18992, 19024,
+ 19056, 19088, 18896, 18928, 18960, 18992, 19024, 19056,
+ 19088, 18896, 18928, 18960, 18992, 19024, 19056, 19088,
+ 18896, 18928, 18960, 18992, 19024, 19056, 19088, 18896,
+ 18928, 18960, 18992, 19024, 19056, 19088, 18896, 18928,
+ 18960, 18992, 19024, 19056, 19088, 18896, 18928, 18960,
+ 18992, 19024, 19056, 19088, 18896, 18928, 18960, 18992,
+ 19024, 19056, 19088, 18896, 18928, 18960, 18992, 19024,
+ 19056, 19088, 18896, 18928, 18960, 18992, 19024, 19056,
+
+ 19088, 18896, 18928, 18960, 18992, 19024, 19056, 19088,
+ 18896, 18928, 18960, 18992, 19024, 19056, 19088, 18896,
+ 18928, 18960, 18992, 19024, 19056, 19088, 18896, 18928,
+ 18960, 18992, 19024, 19056, 19088, 18896, 18928, 18960,
+ 18992, 19024, 19056, 19088, 18896, 18928, 18960, 18992,
+ 19024, 19056, 19088, 18896, 18928, 18960, 18992, 19024,
+ 19056, 19088, 18896, 18928, 18960, 18992, 19024, 19056,
+ 19088, 18896, 18928, 18960, 18992, 19024, 19056, 19088,
+ 18896, 18928, 18960, 18992, 19024, 19056, 19088, 18896,
+ 18928, 18960, 18992, 19024, 19056, 19088, 18896, 18928,
+ 18960, 18992, 19024, 19056, 19088, 18896, 18928, 18960,
+ 18992, 19024, 19056, 19088, 18896, 18928, 18960, 18992,
+ 19024, 19056, 19088, 18896, 18928, 18960, 18992, 19024,
+ 19056, 19088, 18896, 18928, 18960, 18992, 19024, 19056,
+ 19088, 18896, 18928, 18960, 18992, 19024, 19056, 19088,
+ 18896, 18928, 18960, 18992, 19024, 19056, 19088, 18896,
+
+ 18928, 18960, 18992, 19024, 19056, 19088, 18896, 18928,
+ 18960, 18992, 19024, 19056, 19088, 18896, 18928, 18960,
+ 18992, 19024, 19056, 19088, 18896, 18928, 18960, 18992,
+ 19024, 19056, 19088, 18896, 18928, 18960, 18992, 19024,
+ 19056, 19088, 18896, 18928, 18960, 18992, 19024, 19056,
+ 19088, 18896, 18928, 18960, 18992, 19024, 19056, 19088,
+ 18896, 18928, 18960, 18992, 19024, 19056, 19088, 18896,
+ 18928, 18960, 18992, 19024, 19056, 19120, 19152, 19184,
+ 19216, 19216, 19216, 19216, 19216, 19216, 19216, 19216,
+ 19216, 19216, 19216, 19216, 19216, 19216, 19216, 19216,
+ 19216, 19216, 19216, 19216, 19216, 19216, 19216, 19216,
+ 19216, 19216, 19216, 19216, 19216, 19216, 19216, 19216,
+ 19216, 19216, 19216, 19216, 19216, 19216, 19216, 19216,
+ 19216, 19216, 19216, 19216, 19216, 19216, 19216, 19216,
+ 19216, 19216, 19216, 19216, 19216, 19216, 19216, 19216,
+ 19216, 19216, 19216, 19216, 19216, 19216, 19216, 19216,
+
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 19248, 19248, 19248, 19248, 19248, 19248, 19248, 19248,
+ 17232, 17232, 17232, 17232, 17232, 17232, 17232, 17232,
+ 17232, 19280, 19312, 19344, 19376, 19376, 19408, 17328,
+ 19440, 19472, 19504, 19536, 19536, 19568, 19600, 19536,
+ 19536, 19536, 19536, 19536, 19536, 19536, 19536, 19536,
+ 19536, 19632, 19664, 19536, 19696, 19536, 19728, 19760,
+ 19792, 19824, 19856, 19888, 19536, 19536, 19536, 19920,
+ 19952, 19984, 20016, 20048, 20080, 20112, 20144, 20176,
+
+ 20208, 20240, 20272, 9872, 20304, 20304, 20304, 20336,
+ 20368, 20400, 20432, 20464, 20496, 9872, 20528, 20560,
+ 9872, 9872, 9872, 9872, 20592, 20624, 20656, 9872,
+ 20688, 20720, 20752, 9872, 20784, 20816, 20848, 9872,
+ 20880, 20912, 20944, 20976, 21008, 21040, 9872, 9872,
9872, 9872, 9872, 9872, 9872, 9872, 9872, 9872,
9872, 9872, 9872, 9872, 9872, 9872, 9872, 9872,
9872, 9872, 9872, 9872, 9872, 9872, 9872, 9872,
- 20720, 20752, 20784, 8368, 8368, 8368, 8368, 8368,
- 20816, 20848, 8368, 8368, 20880, 20912, 8368, 8368,
- 20944, 20976, 21008, 21040, 8368, 8368, 8368, 8368,
- 21072, 21104, 21136, 21168, 8368, 8368, 8368, 8368,
- 21072, 21072, 21200, 8368, 8368, 8368, 8368, 8368,
+ 21072, 21104, 21136, 8368, 8368, 8368, 8368, 8368,
+ 21168, 21200, 8368, 8368, 21232, 21264, 8368, 8368,
+ 21296, 21328, 21360, 21392, 8368, 8368, 8368, 8368,
+ 21424, 21456, 21488, 21520, 8368, 8368, 8368, 8368,
+ 21552, 21552, 21584, 8368, 8368, 8368, 8368, 8368,
8368, 8368, 8368, 8368, 8368, 8368, 8368, 8368,
- 8368, 8368, 8368, 21232, 8368, 8368, 8368, 8368,
+ 8368, 8368, 8368, 21616, 8368, 8368, 8368, 8368,
8368, 8368, 8368, 8368, 8368, 8368, 8368, 8368,
// 0x11000 - 0x110000
- 21264, 21520, 21776, 21776, 21776, 21776, 22032, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 22288, 22288, 22288, 22544, 22800, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 23056, 23056, 23312, 23568, 23824, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 24080, 24080, 24336, 21776, 21776, 21776, 21776, 24592,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
-
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 24848, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 25104, 25360, 25616, 25872, 26128, 26384, 26640, 26896,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 27152, 27152, 27152, 27152, 27152, 27152, 27408, 27152,
- 27664, 27920, 28176, 28432, 28688, 28944, 29200, 29456,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 29712,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
-
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 29968, 29968,
- 29968, 29968, 29968, 29968, 29968, 29968, 30224, 30480,
- 30480, 30480, 30480, 30480, 30480, 30480, 30480, 30480,
- 30480, 30480, 30480, 30480, 30480, 30480, 30480, 30736,
- 30992, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 29968, 29968, 31504, 31248, 31248, 31248, 31248, 31760,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
-
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31248,
- 31248, 31248, 31248, 31248, 31248, 31248, 31248, 31760,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
-
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 29712,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
-
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 29712,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
-
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 29712,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
-
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 29712,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
-
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 29712,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
-
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 29712,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
-
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 29712,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
-
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 29712,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
-
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 29712,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
-
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 29712,
- 32016, 32272, 32528, 32528, 32528, 32528, 32528, 32528,
- 32528, 32528, 32528, 32528, 32528, 32528, 32528, 32528,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
-
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 21776,
- 21776, 21776, 21776, 21776, 21776, 21776, 21776, 29712,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
-
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 33040,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
-
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 32784,
- 32784, 32784, 32784, 32784, 32784, 32784, 32784, 33040,
+ 21648, 21904, 22160, 22160, 22160, 22160, 22416, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22672, 22672, 22672, 22928, 23184, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 23440, 23440, 23696, 23952, 24208, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 24464, 24464, 24720, 22160, 22160, 22160, 22160, 24976,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 25232, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 25488, 25744, 26000, 26256, 26512, 26768, 27024, 27280,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 27536, 27536, 27536, 27536, 27536, 27536, 27792, 27536,
+ 28048, 28304, 28560, 28816, 29072, 29328, 29584, 29840,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 30096,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30352, 30352,
+ 30352, 30352, 30352, 30352, 30352, 30352, 30608, 30864,
+ 30864, 30864, 30864, 30864, 30864, 30864, 30864, 30864,
+ 30864, 30864, 30864, 30864, 30864, 30864, 30864, 31120,
+ 31376, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 30352, 30352, 31888, 31632, 31632, 31632, 31632, 32144,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 31632,
+ 31632, 31632, 31632, 31632, 31632, 31632, 31632, 32144,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 30096,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 30096,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 30096,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 30096,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 30096,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 30096,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 30096,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 30096,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 30096,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 30096,
+ 32400, 32656, 32912, 32912, 32912, 32912, 32912, 32912,
+ 32912, 32912, 32912, 32912, 32912, 32912, 32912, 32912,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 22160,
+ 22160, 22160, 22160, 22160, 22160, 22160, 22160, 30096,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33424,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33168,
+ 33168, 33168, 33168, 33168, 33168, 33168, 33168, 33424,
0, 0, 0, 0, 0, 0, 0, 0,
@@ -979,575 +979,555 @@ static const unsigned short uc_property_trie[] = {
142, 142, 142, 142, 142, 142, 142, 142,
142, 143, 143, 144, 144, 144, 144, 144,
- 142, 142, 42, 42, 42, 42, 143, 143,
- 145, 143, 143, 143, 145, 143, 143, 143,
+ 145, 145, 42, 42, 42, 42, 143, 143,
+ 146, 143, 143, 143, 146, 143, 143, 143,
144, 144, 42, 42, 42, 42, 42, 42,
- 42, 42, 42, 42, 42, 42, 42, 146,
+ 42, 42, 42, 42, 42, 42, 42, 147,
142, 142, 142, 142, 142, 42, 42, 42,
- 42, 42, 147, 147, 148, 147, 149, 150,
- 150, 150, 150, 150, 150, 150, 150, 150,
- 150, 150, 150, 150, 150, 150, 150, 150,
-
- 151, 151, 151, 151, 151, 151, 151, 151,
- 151, 151, 151, 151, 151, 151, 151, 151,
- 151, 151, 151, 151, 151, 152, 153, 153,
- 153, 153, 152, 154, 153, 153, 153, 153,
-
- 153, 155, 155, 153, 153, 153, 153, 155,
- 155, 153, 153, 153, 153, 153, 153, 153,
- 153, 153, 153, 153, 156, 156, 156, 156,
- 156, 153, 153, 153, 153, 151, 151, 151,
-
- 151, 151, 151, 151, 151, 157, 158, 159,
- 159, 159, 158, 158, 158, 159, 159, 160,
- 161, 161, 161, 162, 162, 162, 162, 161,
- 163, 164, 164, 165, 166, 167, 167, 168,
-
- 169, 169, 170, 171, 171, 171, 171, 171,
- 171, 171, 171, 171, 171, 171, 171, 171,
- 172, 173, 172, 173, 143, 174, 172, 173,
- 175, 175, 176, 177, 177, 177, 34, 175,
-
- 175, 175, 175, 175, 174, 42, 178, 61,
- 179, 179, 179, 175, 180, 175, 181, 181,
- 182, 183, 183, 183, 183, 183, 183, 183,
- 183, 183, 183, 183, 183, 183, 183, 183,
-
- 183, 183, 175, 183, 183, 183, 183, 183,
- 183, 183, 183, 183, 184, 185, 185, 185,
- 186, 187, 187, 187, 187, 187, 187, 187,
- 187, 187, 187, 187, 187, 187, 187, 187,
-
- 187, 187, 188, 187, 187, 187, 187, 187,
- 187, 187, 187, 187, 189, 190, 190, 191,
- 192, 193, 194, 194, 194, 195, 196, 197,
- 198, 199, 200, 201, 200, 201, 200, 201,
-
- 200, 201, 67, 68, 67, 68, 67, 68,
- 67, 68, 67, 68, 67, 68, 67, 68,
- 202, 203, 204, 205, 206, 207, 208, 209,
- 210, 211, 209, 210, 212, 213, 213, 213,
+ 42, 42, 148, 148, 149, 150, 151, 152,
+ 152, 152, 152, 152, 152, 152, 152, 152,
+ 152, 152, 152, 152, 152, 152, 152, 152,
+
+ 153, 153, 153, 153, 153, 153, 153, 153,
+ 153, 153, 153, 153, 153, 153, 153, 153,
+ 153, 153, 153, 153, 153, 154, 155, 155,
+ 155, 155, 154, 156, 155, 155, 155, 155,
+
+ 155, 157, 157, 155, 155, 155, 155, 157,
+ 157, 155, 155, 155, 155, 155, 155, 155,
+ 155, 155, 155, 155, 158, 158, 158, 158,
+ 158, 155, 155, 155, 155, 153, 153, 153,
+
+ 153, 153, 153, 153, 153, 159, 160, 161,
+ 161, 161, 160, 160, 160, 161, 161, 162,
+ 163, 163, 163, 164, 164, 164, 164, 163,
+ 165, 166, 166, 167, 168, 169, 169, 170,
+
+ 171, 171, 172, 173, 173, 173, 173, 173,
+ 173, 173, 173, 173, 173, 173, 173, 173,
+ 174, 175, 174, 175, 143, 176, 174, 175,
+ 177, 177, 178, 179, 179, 179, 34, 177,
+
+ 177, 177, 177, 177, 176, 42, 180, 61,
+ 181, 181, 181, 177, 182, 177, 183, 183,
+ 184, 185, 185, 185, 185, 185, 185, 185,
+ 185, 185, 185, 185, 185, 185, 185, 185,
+
+ 185, 185, 177, 185, 185, 185, 185, 185,
+ 185, 185, 185, 185, 186, 187, 187, 187,
+ 188, 189, 189, 189, 189, 189, 189, 189,
+ 189, 189, 189, 189, 189, 189, 189, 189,
+
+ 189, 189, 190, 189, 189, 189, 189, 189,
+ 189, 189, 189, 189, 191, 192, 192, 193,
+ 194, 195, 196, 196, 196, 197, 198, 199,
+ 200, 201, 202, 203, 202, 203, 202, 203,
+
+ 202, 203, 204, 205, 204, 205, 204, 205,
+ 204, 205, 204, 205, 204, 205, 204, 205,
+ 206, 207, 208, 209, 210, 211, 212, 213,
+ 214, 215, 213, 214, 216, 217, 217, 217,
- 214, 215, 215, 215, 215, 215, 215, 215,
- 215, 215, 215, 215, 215, 214, 215, 215,
- 216, 216, 216, 216, 216, 216, 216, 216,
- 216, 216, 216, 216, 216, 216, 216, 216,
-
- 216, 216, 216, 216, 216, 216, 216, 216,
- 216, 216, 216, 216, 216, 216, 216, 216,
- 217, 217, 217, 217, 217, 217, 217, 217,
- 217, 217, 217, 217, 217, 217, 217, 217,
-
- 217, 217, 217, 217, 217, 217, 217, 217,
- 217, 217, 217, 217, 217, 217, 217, 217,
218, 219, 219, 219, 219, 219, 219, 219,
219, 219, 219, 219, 219, 218, 219, 219,
+ 220, 220, 220, 220, 220, 220, 220, 220,
+ 220, 220, 220, 220, 220, 220, 220, 220,
+
+ 220, 220, 220, 220, 220, 220, 220, 220,
+ 220, 220, 220, 220, 220, 220, 220, 220,
+ 221, 221, 221, 221, 221, 221, 221, 221,
+ 221, 221, 221, 221, 221, 221, 221, 221,
+
+ 221, 221, 221, 221, 221, 221, 221, 221,
+ 221, 221, 221, 221, 221, 221, 221, 221,
+ 222, 223, 223, 223, 223, 223, 223, 223,
+ 223, 223, 223, 223, 223, 222, 223, 223,
+
+ 224, 225, 224, 225, 224, 225, 224, 225,
+ 224, 225, 224, 225, 224, 225, 224, 225,
+ 224, 225, 224, 225, 224, 225, 224, 225,
+ 224, 225, 224, 225, 224, 225, 224, 225,
+
+ 224, 225, 226, 227, 227, 153, 153, 228,
+ 229, 229, 230, 231, 232, 233, 232, 233,
+ 224, 225, 224, 225, 224, 225, 224, 225,
+ 224, 225, 224, 225, 224, 225, 224, 225,
+
+ 234, 224, 225, 224, 225, 230, 231, 224,
+ 225, 230, 231, 224, 225, 230, 231, 235,
+ 224, 225, 224, 225, 224, 225, 224, 225,
+ 224, 225, 224, 225, 224, 225, 224, 225,
+
+ 224, 225, 224, 225, 224, 225, 224, 225,
+ 224, 225, 224, 225, 232, 233, 224, 225,
+ 224, 225, 224, 225, 224, 225, 236, 237,
+ 224, 225, 238, 239, 238, 239, 238, 239,
+
+ 230, 231, 230, 231, 230, 231, 230, 231,
+ 230, 231, 230, 231, 230, 231, 230, 231,
+ 238, 239, 238, 239, 240, 241, 240, 241,
+ 240, 241, 240, 241, 240, 241, 240, 241,
+
+ 240, 241, 240, 241, 242, 243, 244, 245,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 246, 246, 246, 246, 246, 246, 246,
+ 246, 246, 246, 246, 246, 246, 246, 246,
+
+ 246, 246, 246, 246, 246, 246, 246, 246,
+ 246, 246, 246, 246, 246, 246, 246, 246,
+ 246, 246, 246, 246, 246, 246, 246, 177,
+ 177, 247, 248, 248, 249, 250, 249, 248,
+
+ 177, 251, 251, 251, 251, 251, 251, 251,
+ 251, 251, 251, 251, 251, 251, 251, 251,
+ 251, 251, 251, 251, 251, 251, 251, 251,
+ 251, 251, 251, 251, 251, 251, 251, 251,
+
+ 251, 251, 251, 251, 251, 251, 251, 252,
+ 177, 253, 254, 177, 177, 177, 177, 255,
+ 256, 257, 258, 258, 258, 258, 257, 258,
+ 258, 258, 259, 257, 258, 258, 258, 258,
+
+ 258, 258, 260, 257, 257, 257, 257, 257,
+ 258, 258, 257, 258, 258, 259, 261, 258,
+ 262, 263, 264, 265, 266, 267, 268, 269,
+ 270, 271, 272, 273, 274, 275, 276, 277,
+
+ 278, 279, 280, 278, 258, 260, 281, 282,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 283, 283, 283, 283, 283, 283, 283, 283,
+ 283, 283, 283, 283, 283, 283, 283, 283,
+
+ 283, 283, 283, 283, 283, 283, 283, 283,
+ 283, 283, 283, 256, 256, 256, 256, 256,
+ 283, 283, 283, 284, 285, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+
+ 286, 286, 286, 286, 287, 288, 289, 289,
+ 290, 291, 291, 292, 19, 293, 294, 294,
+ 295, 295, 295, 295, 295, 295, 296, 296,
+ 297, 298, 299, 300, 288, 288, 301, 302,
+
+ 303, 304, 305, 305, 305, 305, 306, 305,
+ 306, 305, 306, 306, 306, 306, 306, 305,
+ 305, 305, 305, 306, 306, 306, 306, 306,
+ 306, 306, 306, 307, 307, 307, 307, 307,
+
+ 308, 306, 306, 306, 306, 306, 306, 306,
+ 305, 306, 306, 309, 310, 311, 312, 313,
+ 314, 315, 316, 160, 160, 161, 317, 295,
+ 295, 318, 318, 318, 319, 318, 318, 320,
+
+ 321, 322, 323, 324, 325, 326, 327, 328,
+ 329, 330, 331, 332, 333, 334, 335, 335,
+ 336, 305, 305, 305, 304, 305, 305, 305,
+ 306, 306, 306, 306, 306, 306, 306, 306,
+
+ 306, 306, 306, 306, 306, 306, 306, 306,
+ 305, 305, 305, 305, 305, 305, 305, 305,
+ 305, 305, 305, 305, 305, 305, 305, 305,
+ 305, 305, 306, 306, 306, 306, 306, 306,
+
+ 306, 306, 306, 306, 306, 306, 306, 306,
+ 306, 306, 306, 306, 306, 306, 306, 306,
+ 306, 306, 306, 306, 306, 306, 306, 306,
+ 337, 337, 306, 306, 306, 306, 306, 337,
+
+ 305, 306, 306, 305, 305, 305, 305, 305,
+ 305, 305, 305, 305, 306, 305, 306, 338,
+ 306, 306, 305, 305, 339, 305, 340, 340,
+ 340, 340, 340, 340, 340, 341, 342, 340,
+
+ 340, 340, 340, 343, 340, 344, 344, 340,
+ 340, 342, 343, 340, 340, 343, 345, 345,
+ 346, 347, 348, 349, 350, 351, 352, 353,
+ 354, 355, 337, 337, 337, 356, 356, 357,
+
+ 358, 358, 358, 359, 359, 359, 359, 359,
+ 359, 359, 359, 359, 359, 359, 288, 360,
+ 361, 362, 363, 363, 363, 361, 361, 361,
+ 361, 361, 363, 363, 363, 363, 361, 363,
+
+ 363, 363, 363, 363, 363, 363, 363, 363,
+ 361, 363, 361, 363, 361, 364, 364, 365,
+ 366, 367, 366, 366, 367, 366, 366, 367,
+ 367, 367, 366, 367, 367, 366, 367, 366,
+
+ 366, 366, 367, 366, 367, 366, 367, 366,
+ 367, 366, 366, 288, 288, 365, 364, 364,
+ 368, 368, 368, 368, 368, 368, 368, 368,
+ 368, 369, 369, 369, 368, 368, 368, 368,
- 220, 221, 220, 221, 220, 221, 220, 221,
- 220, 221, 220, 221, 220, 221, 220, 221,
- 220, 221, 220, 221, 220, 221, 220, 221,
- 220, 221, 220, 221, 220, 221, 220, 221,
-
- 220, 221, 222, 223, 223, 151, 151, 224,
- 225, 225, 226, 227, 228, 229, 228, 229,
- 220, 221, 220, 221, 220, 221, 220, 221,
- 220, 221, 220, 221, 220, 221, 220, 221,
-
- 230, 220, 221, 220, 221, 226, 227, 220,
- 221, 226, 227, 220, 221, 226, 227, 231,
- 220, 221, 220, 221, 220, 221, 220, 221,
- 220, 221, 220, 221, 220, 221, 220, 221,
-
- 220, 221, 220, 221, 220, 221, 220, 221,
- 220, 221, 220, 221, 228, 229, 220, 221,
- 220, 221, 220, 221, 220, 221, 232, 233,
- 220, 221, 234, 235, 234, 235, 234, 235,
-
- 226, 227, 226, 227, 226, 227, 226, 227,
- 226, 227, 226, 227, 226, 227, 226, 227,
- 234, 235, 234, 235, 236, 237, 236, 237,
- 236, 237, 236, 237, 236, 237, 236, 237,
-
- 236, 237, 236, 237, 238, 239, 240, 241,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 242, 242, 242, 242, 242, 242, 242,
- 242, 242, 242, 242, 242, 242, 242, 242,
-
- 242, 242, 242, 242, 242, 242, 242, 242,
- 242, 242, 242, 242, 242, 242, 242, 242,
- 242, 242, 242, 242, 242, 242, 242, 175,
- 175, 243, 244, 244, 245, 246, 245, 244,
-
- 175, 247, 247, 247, 247, 247, 247, 247,
- 247, 247, 247, 247, 247, 247, 247, 247,
- 247, 247, 247, 247, 247, 247, 247, 247,
- 247, 247, 247, 247, 247, 247, 247, 247,
-
- 247, 247, 247, 247, 247, 247, 247, 248,
- 175, 249, 250, 175, 175, 175, 175, 251,
- 252, 253, 254, 254, 254, 254, 253, 254,
- 254, 254, 255, 253, 254, 254, 254, 254,
-
- 254, 254, 256, 253, 253, 253, 253, 253,
- 254, 254, 253, 254, 254, 255, 257, 254,
- 258, 259, 260, 261, 262, 263, 264, 265,
- 266, 267, 268, 269, 270, 271, 272, 273,
-
- 274, 275, 276, 274, 254, 256, 277, 278,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 279, 279, 279, 279, 279, 279, 279, 279,
- 279, 279, 279, 279, 279, 279, 279, 279,
-
- 279, 279, 279, 279, 279, 279, 279, 279,
- 279, 279, 279, 252, 252, 252, 252, 252,
- 279, 279, 279, 280, 281, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
-
- 282, 282, 282, 282, 283, 284, 285, 285,
- 286, 287, 287, 288, 19, 289, 290, 290,
- 291, 291, 291, 291, 291, 291, 292, 292,
- 293, 294, 295, 296, 284, 284, 297, 298,
-
- 299, 300, 301, 301, 301, 301, 302, 301,
- 302, 301, 302, 302, 302, 302, 302, 301,
- 301, 301, 301, 302, 302, 302, 302, 302,
- 302, 302, 302, 303, 303, 303, 303, 303,
-
- 304, 302, 302, 302, 302, 302, 302, 302,
- 301, 302, 302, 305, 306, 307, 308, 309,
- 310, 311, 312, 158, 158, 159, 313, 291,
- 291, 314, 314, 314, 315, 314, 314, 316,
-
- 317, 318, 319, 320, 321, 322, 323, 324,
- 325, 326, 327, 328, 329, 330, 331, 331,
- 332, 301, 301, 301, 300, 301, 301, 301,
- 302, 302, 302, 302, 302, 302, 302, 302,
-
- 302, 302, 302, 302, 302, 302, 302, 302,
- 301, 301, 301, 301, 301, 301, 301, 301,
- 301, 301, 301, 301, 301, 301, 301, 301,
- 301, 301, 302, 302, 302, 302, 302, 302,
-
- 302, 302, 302, 302, 302, 302, 302, 302,
- 302, 302, 302, 302, 302, 302, 302, 302,
- 302, 302, 302, 302, 302, 302, 302, 302,
- 333, 333, 302, 302, 302, 302, 302, 333,
-
- 301, 302, 302, 301, 301, 301, 301, 301,
- 301, 301, 301, 301, 302, 301, 302, 334,
- 302, 302, 301, 301, 335, 301, 336, 336,
- 336, 336, 336, 336, 336, 337, 338, 336,
-
- 336, 336, 336, 339, 336, 340, 340, 336,
- 336, 338, 339, 336, 336, 339, 341, 341,
- 342, 343, 344, 345, 346, 347, 348, 349,
- 350, 351, 333, 333, 333, 352, 352, 353,
-
- 354, 354, 354, 355, 355, 355, 355, 355,
- 355, 355, 355, 355, 355, 355, 284, 356,
- 357, 358, 359, 359, 359, 357, 357, 357,
- 357, 357, 359, 359, 359, 359, 357, 359,
-
- 359, 359, 359, 359, 359, 359, 359, 359,
- 357, 359, 357, 359, 357, 360, 360, 361,
- 362, 363, 362, 362, 363, 362, 362, 363,
- 363, 363, 362, 363, 363, 362, 363, 362,
-
- 362, 362, 363, 362, 363, 362, 363, 362,
- 363, 362, 362, 284, 284, 361, 360, 360,
- 364, 364, 364, 364, 364, 364, 364, 364,
- 364, 365, 365, 365, 364, 364, 364, 364,
-
- 364, 364, 364, 364, 364, 364, 364, 364,
- 364, 364, 364, 365, 365, 364, 303, 303,
- 303, 366, 303, 366, 366, 303, 303, 303,
- 366, 366, 303, 303, 303, 303, 303, 303,
-
- 367, 367, 367, 367, 367, 367, 367, 367,
- 367, 367, 367, 367, 367, 367, 367, 367,
- 367, 367, 367, 367, 367, 367, 367, 367,
- 367, 367, 367, 367, 367, 367, 367, 367,
-
- 367, 367, 367, 367, 367, 367, 368, 368,
368, 368, 368, 368, 368, 368, 368, 368,
- 368, 369, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
-
- 370, 371, 372, 373, 374, 375, 376, 377,
- 378, 379, 380, 380, 380, 380, 380, 380,
- 380, 380, 380, 380, 380, 380, 380, 380,
- 380, 380, 380, 380, 380, 380, 380, 380,
-
- 380, 380, 380, 380, 380, 380, 380, 380,
- 380, 380, 380, 381, 381, 381, 381, 381,
- 381, 381, 382, 381, 383, 383, 384, 385,
- 386, 387, 388, 252, 252, 252, 252, 252,
-
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 390, 390,
- 390, 390, 391, 390, 390, 390, 390, 390,
-
- 390, 390, 390, 390, 391, 390, 390, 390,
- 391, 390, 390, 390, 390, 390, 252, 252,
- 392, 392, 392, 392, 392, 392, 392, 392,
- 392, 392, 392, 392, 392, 392, 392, 252,
-
- 393, 394, 394, 394, 394, 394, 393, 394,
- 394, 393, 394, 394, 394, 394, 394, 393,
- 394, 394, 394, 394, 393, 394, 395, 395,
- 395, 396, 396, 396, 252, 252, 397, 252,
-
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
-
- 398, 284, 398, 398, 398, 398, 398, 398,
- 398, 398, 399, 399, 399, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
-
- 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
-
- 284, 284, 284, 284, 400, 400, 401, 400,
- 400, 401, 400, 400, 400, 401, 401, 401,
- 402, 403, 404, 400, 400, 400, 401, 400,
- 400, 401, 401, 400, 400, 400, 400, 284,
-
- 405, 406, 406, 407, 408, 409, 409, 409,
- 409, 409, 409, 409, 409, 409, 409, 409,
- 409, 409, 409, 409, 409, 409, 409, 409,
- 409, 409, 409, 409, 409, 409, 409, 409,
-
- 409, 409, 409, 409, 409, 409, 409, 409,
- 409, 409, 409, 409, 409, 409, 409, 409,
- 409, 409, 409, 409, 409, 409, 409, 409,
- 409, 409, 410, 411, 412, 409, 407, 407,
-
- 407, 406, 406, 406, 406, 406, 406, 406,
- 406, 407, 407, 407, 407, 413, 414, 411,
- 409, 151, 153, 415, 415, 405, 410, 410,
- 409, 409, 409, 409, 409, 409, 409, 409,
-
- 409, 409, 406, 406, 416, 416, 417, 418,
- 419, 420, 421, 422, 423, 424, 425, 426,
- 427, 428, 429, 430, 430, 430, 430, 430,
- 175, 431, 431, 432, 432, 433, 432, 432,
-
- 175, 434, 435, 435, 175, 436, 436, 436,
- 436, 436, 436, 436, 436, 175, 175, 436,
- 436, 175, 175, 436, 436, 436, 436, 436,
- 436, 436, 436, 436, 436, 436, 436, 436,
-
- 436, 436, 436, 436, 436, 436, 436, 436,
- 436, 175, 436, 436, 436, 436, 436, 436,
- 436, 175, 436, 175, 175, 175, 436, 436,
- 436, 436, 175, 175, 437, 438, 439, 435,
-
- 435, 434, 434, 434, 434, 175, 175, 435,
- 435, 175, 175, 435, 435, 440, 441, 175,
- 175, 175, 175, 175, 175, 175, 175, 439,
- 175, 175, 175, 175, 436, 436, 175, 436,
-
- 436, 436, 434, 434, 175, 175, 442, 443,
- 444, 445, 446, 447, 448, 449, 450, 451,
- 436, 436, 452, 452, 453, 453, 453, 453,
- 453, 454, 455, 456, 175, 175, 175, 175,
-
- 175, 457, 458, 459, 175, 460, 460, 460,
- 460, 460, 460, 175, 175, 175, 175, 460,
- 460, 175, 175, 460, 460, 460, 460, 460,
- 460, 460, 460, 460, 460, 460, 460, 460,
-
- 460, 460, 460, 460, 460, 460, 460, 460,
- 460, 175, 460, 460, 460, 460, 460, 460,
- 460, 175, 460, 460, 175, 460, 460, 175,
- 460, 460, 175, 175, 461, 175, 462, 462,
-
- 462, 458, 458, 175, 175, 175, 175, 458,
- 458, 175, 175, 458, 458, 463, 175, 175,
- 175, 464, 175, 175, 175, 175, 175, 175,
- 175, 460, 460, 460, 460, 175, 460, 175,
-
- 175, 175, 175, 175, 175, 175, 465, 466,
- 467, 468, 469, 470, 471, 472, 473, 474,
- 458, 458, 460, 460, 460, 464, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 475, 475, 476, 175, 477, 477, 477,
- 477, 477, 477, 477, 478, 477, 175, 477,
- 477, 477, 175, 477, 477, 477, 477, 477,
- 477, 477, 477, 477, 477, 477, 477, 477,
-
- 477, 477, 477, 477, 477, 477, 477, 477,
- 477, 175, 477, 477, 477, 477, 477, 477,
- 477, 175, 477, 477, 175, 477, 477, 477,
- 477, 477, 175, 175, 479, 477, 476, 476,
-
- 476, 475, 475, 475, 475, 475, 175, 475,
- 475, 476, 175, 476, 476, 480, 175, 175,
- 477, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 477, 478, 481, 481, 175, 175, 482, 483,
- 484, 485, 486, 487, 488, 489, 490, 491,
- 492, 493, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 494, 495, 495, 175, 496, 496, 496,
- 496, 496, 496, 496, 496, 175, 175, 496,
- 496, 175, 175, 496, 496, 496, 496, 496,
- 496, 496, 496, 496, 496, 496, 496, 496,
-
- 496, 496, 496, 496, 496, 496, 496, 496,
- 496, 175, 496, 496, 496, 496, 496, 496,
- 496, 175, 496, 496, 175, 497, 496, 496,
- 496, 496, 175, 175, 498, 496, 499, 494,
-
- 495, 494, 494, 494, 500, 175, 175, 495,
- 495, 175, 175, 495, 495, 501, 175, 175,
- 175, 175, 175, 175, 175, 175, 494, 499,
- 175, 175, 175, 175, 496, 496, 175, 496,
-
- 496, 496, 500, 500, 175, 175, 502, 503,
- 504, 505, 506, 507, 508, 509, 510, 511,
- 512, 497, 513, 513, 513, 513, 513, 513,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 175, 514, 515, 175, 515, 515, 515,
- 515, 515, 515, 175, 175, 175, 515, 515,
- 515, 175, 515, 515, 515, 515, 175, 175,
- 175, 515, 515, 175, 515, 175, 515, 515,
-
- 175, 175, 175, 515, 515, 175, 175, 175,
- 515, 515, 515, 175, 175, 175, 515, 515,
- 515, 515, 515, 515, 515, 515, 516, 515,
- 515, 515, 175, 175, 175, 175, 517, 518,
-
- 514, 518, 518, 175, 175, 175, 518, 518,
- 518, 175, 518, 518, 518, 519, 175, 175,
- 520, 175, 175, 175, 175, 175, 175, 517,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 175, 175, 175, 175, 175, 521, 522,
- 523, 524, 525, 526, 527, 528, 529, 530,
- 531, 531, 531, 532, 532, 532, 532, 532,
- 532, 533, 532, 175, 175, 175, 175, 175,
-
- 175, 534, 534, 534, 175, 535, 535, 535,
- 535, 535, 535, 535, 535, 175, 535, 535,
- 535, 175, 535, 535, 535, 535, 535, 535,
- 535, 535, 535, 535, 535, 535, 535, 535,
-
- 535, 535, 535, 535, 535, 535, 535, 535,
- 535, 175, 535, 535, 535, 535, 535, 535,
- 535, 535, 535, 535, 175, 535, 535, 535,
- 535, 535, 175, 175, 175, 536, 537, 537,
-
- 537, 534, 534, 534, 534, 175, 537, 537,
- 537, 175, 537, 537, 537, 538, 175, 175,
- 175, 175, 175, 175, 175, 539, 540, 175,
- 536, 536, 175, 175, 175, 175, 175, 175,
-
- 535, 535, 541, 541, 175, 175, 542, 543,
- 544, 545, 546, 547, 548, 549, 550, 551,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 552, 552, 552, 552, 552, 552, 552, 553,
-
- 175, 175, 554, 554, 175, 555, 555, 555,
- 555, 555, 555, 555, 555, 175, 555, 555,
- 555, 175, 555, 555, 555, 555, 555, 555,
- 555, 555, 555, 555, 555, 555, 555, 555,
-
- 555, 555, 555, 555, 555, 555, 555, 555,
- 555, 175, 555, 555, 555, 555, 555, 555,
- 555, 555, 555, 555, 175, 555, 555, 555,
- 555, 555, 175, 175, 556, 557, 554, 558,
-
- 554, 554, 559, 554, 554, 175, 558, 554,
- 554, 175, 554, 554, 560, 561, 175, 175,
- 175, 175, 175, 175, 175, 559, 559, 175,
- 175, 175, 175, 175, 175, 175, 555, 175,
-
- 555, 555, 562, 562, 175, 175, 563, 564,
- 565, 566, 567, 568, 569, 570, 571, 572,
- 175, 573, 573, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 175, 574, 574, 175, 575, 575, 575,
- 575, 575, 575, 575, 575, 175, 575, 575,
- 575, 175, 575, 575, 575, 575, 575, 575,
- 575, 575, 575, 575, 575, 575, 575, 575,
-
- 575, 575, 575, 575, 575, 575, 575, 575,
- 575, 576, 575, 575, 575, 575, 575, 575,
- 575, 575, 575, 575, 575, 575, 575, 575,
- 575, 575, 576, 175, 175, 577, 578, 574,
-
- 574, 579, 579, 579, 580, 175, 574, 574,
- 574, 175, 574, 574, 574, 581, 576, 175,
- 175, 175, 175, 175, 175, 175, 175, 578,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 575, 575, 580, 580, 175, 175, 582, 583,
- 584, 585, 586, 587, 588, 589, 590, 591,
- 592, 592, 592, 592, 592, 592, 175, 175,
- 175, 593, 577, 577, 577, 577, 577, 577,
-
- 175, 175, 594, 594, 175, 595, 595, 595,
- 595, 595, 595, 595, 595, 595, 595, 595,
- 595, 595, 595, 595, 595, 595, 595, 175,
- 175, 175, 595, 595, 595, 595, 595, 595,
-
- 595, 595, 595, 595, 595, 595, 595, 595,
- 595, 595, 595, 595, 595, 595, 595, 595,
- 595, 595, 175, 595, 595, 595, 595, 595,
- 595, 595, 595, 595, 175, 595, 175, 175,
-
- 595, 595, 595, 595, 595, 595, 595, 175,
- 175, 175, 596, 175, 175, 175, 175, 597,
- 594, 594, 598, 598, 598, 175, 598, 175,
- 594, 594, 594, 594, 594, 594, 594, 597,
-
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 594, 594, 599, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 600, 600, 600, 600, 600, 600, 600,
- 600, 600, 600, 600, 600, 600, 600, 600,
- 600, 600, 600, 600, 600, 600, 600, 600,
- 600, 600, 600, 600, 600, 600, 600, 600,
-
- 600, 600, 600, 600, 600, 600, 600, 600,
- 600, 600, 600, 600, 600, 600, 600, 600,
- 600, 601, 600, 602, 601, 601, 601, 601,
- 603, 603, 604, 175, 175, 175, 175, 12,
-
- 600, 600, 600, 600, 600, 600, 605, 601,
- 606, 606, 606, 606, 601, 601, 601, 607,
- 608, 609, 610, 611, 612, 613, 614, 615,
- 616, 617, 618, 618, 175, 175, 175, 175,
-
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 619, 619, 175, 619, 175, 175, 619,
- 619, 175, 619, 175, 175, 619, 175, 175,
- 175, 175, 175, 175, 619, 619, 619, 619,
- 175, 619, 619, 619, 619, 619, 619, 619,
-
- 175, 619, 619, 619, 175, 619, 175, 619,
- 175, 175, 619, 619, 175, 619, 619, 619,
- 619, 620, 619, 621, 620, 620, 620, 620,
- 622, 622, 175, 620, 620, 619, 175, 175,
-
- 619, 619, 619, 619, 619, 175, 623, 175,
- 624, 624, 624, 624, 620, 620, 175, 175,
- 625, 626, 627, 628, 629, 630, 631, 632,
- 633, 634, 175, 175, 619, 619, 635, 635,
-
- 636, 637, 637, 637, 638, 639, 638, 638,
- 640, 638, 638, 641, 640, 642, 642, 642,
- 642, 642, 640, 643, 642, 643, 643, 643,
- 644, 644, 643, 643, 643, 643, 643, 643,
-
- 645, 646, 647, 648, 649, 650, 651, 652,
- 653, 654, 655, 655, 655, 655, 655, 655,
- 655, 655, 655, 655, 656, 644, 643, 644,
- 643, 657, 658, 659, 658, 659, 660, 660,
-
- 636, 636, 636, 636, 636, 636, 636, 636,
- 175, 636, 636, 636, 636, 636, 636, 636,
- 636, 636, 636, 636, 636, 636, 636, 636,
- 636, 636, 636, 636, 636, 636, 636, 636,
-
- 636, 636, 636, 636, 636, 636, 636, 636,
- 636, 636, 661, 662, 662, 175, 175, 175,
- 175, 663, 664, 665, 666, 665, 665, 665,
- 665, 665, 664, 664, 664, 664, 665, 667,
-
- 664, 665, 668, 668, 669, 641, 668, 668,
- 636, 636, 636, 636, 670, 671, 671, 671,
- 665, 665, 665, 665, 665, 665, 672, 665,
- 175, 665, 665, 665, 665, 665, 665, 665,
-
- 665, 665, 665, 665, 665, 665, 665, 665,
- 665, 665, 665, 665, 665, 665, 672, 672,
- 672, 665, 665, 665, 665, 665, 665, 665,
- 672, 665, 672, 672, 672, 175, 673, 673,
-
- 674, 674, 674, 674, 674, 674, 675, 674,
- 674, 674, 674, 674, 674, 175, 676, 674,
- 677, 677, 678, 679, 680, 681, 681, 681,
- 681, 682, 682, 175, 175, 175, 175, 175,
-
- 683, 683, 683, 683, 683, 683, 683, 683,
- 683, 683, 683, 683, 683, 683, 683, 683,
- 683, 683, 683, 683, 683, 683, 683, 683,
- 683, 683, 683, 683, 683, 683, 683, 683,
-
- 683, 683, 684, 683, 683, 683, 683, 683,
- 684, 683, 683, 685, 686, 687, 687, 687,
- 687, 688, 687, 689, 689, 689, 687, 690,
- 686, 691, 692, 693, 693, 689, 689, 684,
-
- 694, 695, 696, 697, 698, 699, 700, 701,
- 702, 703, 704, 704, 705, 705, 705, 705,
- 683, 683, 683, 683, 683, 683, 688, 688,
- 687, 687, 684, 684, 684, 684, 689, 689,
-
- 689, 684, 685, 685, 685, 684, 684, 685,
- 685, 685, 685, 685, 685, 685, 684, 684,
- 684, 689, 689, 689, 689, 684, 684, 684,
- 684, 684, 684, 684, 684, 684, 684, 684,
-
- 684, 684, 689, 685, 693, 689, 689, 685,
- 685, 685, 685, 685, 685, 706, 684, 685,
- 707, 708, 709, 710, 711, 712, 713, 714,
- 715, 716, 717, 717, 717, 718, 719, 719,
-
- 720, 720, 720, 720, 720, 720, 720, 720,
- 720, 720, 720, 720, 720, 720, 720, 720,
- 720, 720, 720, 720, 720, 720, 720, 720,
- 720, 720, 720, 720, 720, 720, 720, 720,
-
- 720, 720, 720, 720, 720, 720, 175, 721,
- 175, 175, 175, 175, 175, 721, 175, 175,
- 722, 722, 722, 722, 722, 722, 722, 722,
- 722, 722, 722, 722, 722, 722, 722, 722,
-
- 722, 722, 722, 722, 722, 722, 722, 722,
- 722, 722, 722, 722, 722, 722, 722, 722,
- 722, 722, 722, 722, 722, 722, 722, 723,
- 723, 724, 724, 725, 726, 727, 727, 727,
-
- 728, 728, 728, 728, 728, 728, 728, 728,
- 728, 728, 728, 728, 728, 728, 728, 728,
- 728, 728, 728, 728, 728, 728, 728, 728,
- 728, 728, 728, 728, 728, 728, 728, 728,
-
- 728, 728, 728, 728, 728, 728, 728, 728,
- 728, 728, 728, 728, 728, 728, 728, 728,
- 728, 728, 728, 728, 728, 728, 728, 728,
- 728, 728, 729, 729, 729, 729, 729, 728,
-
- 730, 730, 730, 730, 730, 730, 730, 730,
- 730, 730, 730, 730, 730, 730, 730, 730,
- 730, 730, 730, 730, 730, 730, 730, 730,
- 730, 730, 730, 730, 730, 730, 730, 730,
-
- 730, 730, 730, 731, 731, 731, 731, 731,
- 732, 732, 732, 732, 732, 732, 732, 732,
- 732, 732, 732, 732, 732, 732, 732, 732,
- 732, 732, 732, 732, 732, 732, 732, 732,
+ 368, 368, 368, 369, 369, 368, 307, 307,
+ 307, 370, 307, 370, 370, 307, 307, 307,
+ 370, 370, 307, 307, 307, 307, 307, 307,
+
+ 371, 371, 371, 371, 371, 371, 371, 371,
+ 371, 371, 371, 371, 371, 371, 371, 371,
+ 371, 371, 371, 371, 371, 371, 371, 371,
+ 371, 371, 371, 371, 371, 371, 371, 371,
+
+ 371, 371, 371, 371, 371, 371, 372, 372,
+ 372, 372, 372, 372, 372, 372, 372, 372,
+ 372, 373, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+
+ 374, 375, 376, 377, 378, 379, 380, 381,
+ 382, 383, 384, 384, 384, 384, 384, 384,
+ 384, 384, 384, 384, 384, 384, 384, 384,
+ 384, 384, 384, 384, 384, 384, 384, 384,
+
+ 384, 384, 384, 384, 384, 384, 384, 384,
+ 384, 384, 384, 385, 385, 385, 385, 385,
+ 385, 385, 386, 385, 387, 387, 388, 389,
+ 390, 391, 392, 256, 256, 256, 256, 256,
+
+ 393, 393, 393, 393, 393, 393, 393, 393,
+ 393, 393, 393, 393, 393, 393, 393, 393,
+ 393, 393, 393, 393, 393, 393, 394, 394,
+ 394, 394, 395, 394, 394, 394, 394, 394,
+
+ 394, 394, 394, 394, 395, 394, 394, 394,
+ 395, 394, 394, 394, 394, 394, 256, 256,
+ 396, 396, 396, 396, 396, 396, 396, 396,
+ 396, 396, 396, 396, 396, 396, 396, 256,
+
+ 397, 398, 398, 398, 398, 398, 397, 398,
+ 398, 397, 398, 398, 398, 398, 398, 397,
+ 398, 398, 398, 398, 397, 398, 399, 399,
+ 399, 400, 400, 400, 256, 256, 401, 256,
+
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+
+ 402, 288, 402, 402, 402, 402, 402, 402,
+ 402, 402, 403, 403, 403, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+
+ 288, 288, 288, 288, 404, 404, 405, 404,
+ 404, 405, 404, 404, 404, 405, 405, 405,
+ 406, 407, 408, 404, 404, 404, 405, 404,
+ 404, 405, 405, 404, 404, 404, 404, 288,
+
+ 409, 410, 410, 411, 412, 413, 413, 413,
+ 413, 413, 413, 413, 413, 413, 413, 413,
+ 413, 413, 413, 413, 413, 413, 413, 413,
+ 413, 413, 413, 413, 413, 413, 413, 413,
+
+ 413, 413, 413, 413, 413, 413, 413, 413,
+ 413, 413, 413, 413, 413, 413, 413, 413,
+ 413, 413, 413, 413, 413, 413, 413, 413,
+ 413, 413, 414, 415, 416, 413, 411, 411,
+
+ 411, 410, 410, 410, 410, 410, 410, 410,
+ 410, 411, 411, 411, 411, 417, 418, 415,
+ 413, 153, 155, 419, 419, 409, 414, 414,
+ 413, 413, 413, 413, 413, 413, 413, 413,
+
+ 413, 413, 410, 410, 420, 420, 421, 422,
+ 423, 424, 425, 426, 427, 428, 429, 430,
+ 431, 432, 433, 434, 434, 434, 434, 434,
+ 177, 435, 435, 436, 436, 437, 436, 436,
+
+ 177, 438, 439, 439, 177, 440, 440, 440,
+ 440, 440, 440, 440, 440, 177, 177, 440,
+ 440, 177, 177, 440, 440, 440, 440, 440,
+ 440, 440, 440, 440, 440, 440, 440, 440,
+
+ 440, 440, 440, 440, 440, 440, 440, 440,
+ 440, 177, 440, 440, 440, 440, 440, 440,
+ 440, 177, 440, 177, 177, 177, 440, 440,
+ 440, 440, 177, 177, 441, 442, 443, 439,
+
+ 439, 438, 438, 438, 438, 177, 177, 439,
+ 439, 177, 177, 439, 439, 444, 445, 177,
+ 177, 177, 177, 177, 177, 177, 177, 443,
+ 177, 177, 177, 177, 440, 440, 177, 440,
+
+ 440, 440, 438, 438, 177, 177, 446, 447,
+ 448, 449, 450, 451, 452, 453, 454, 455,
+ 440, 440, 456, 456, 457, 457, 457, 457,
+ 457, 458, 459, 460, 177, 177, 177, 177,
+
+ 177, 461, 462, 463, 177, 464, 464, 464,
+ 464, 464, 464, 177, 177, 177, 177, 464,
+ 464, 177, 177, 464, 464, 464, 464, 464,
+ 464, 464, 464, 464, 464, 464, 464, 464,
+
+ 464, 464, 464, 464, 464, 464, 464, 464,
+ 464, 177, 464, 464, 464, 464, 464, 464,
+ 464, 177, 464, 464, 177, 464, 464, 177,
+ 464, 464, 177, 177, 465, 177, 466, 466,
+
+ 466, 462, 462, 177, 177, 177, 177, 462,
+ 462, 177, 177, 462, 462, 467, 177, 177,
+ 177, 468, 177, 177, 177, 177, 177, 177,
+ 177, 464, 464, 464, 464, 177, 464, 177,
+
+ 177, 177, 177, 177, 177, 177, 469, 470,
+ 471, 472, 473, 474, 475, 476, 477, 478,
+ 462, 462, 464, 464, 464, 468, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 479, 479, 480, 177, 481, 481, 481,
+ 481, 481, 481, 481, 482, 481, 177, 481,
+ 481, 481, 177, 481, 481, 481, 481, 481,
+ 481, 481, 481, 481, 481, 481, 481, 481,
+
+ 481, 481, 481, 481, 481, 481, 481, 481,
+ 481, 177, 481, 481, 481, 481, 481, 481,
+ 481, 177, 481, 481, 177, 481, 481, 481,
+ 481, 481, 177, 177, 483, 481, 480, 480,
+
+ 480, 479, 479, 479, 479, 479, 177, 479,
+ 479, 480, 177, 480, 480, 484, 177, 177,
+ 481, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 481, 482, 485, 485, 177, 177, 486, 487,
+ 488, 489, 490, 491, 492, 493, 494, 495,
+ 496, 497, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 498, 499, 499, 177, 500, 500, 500,
+ 500, 500, 500, 500, 500, 177, 177, 500,
+ 500, 177, 177, 500, 500, 500, 500, 500,
+ 500, 500, 500, 500, 500, 500, 500, 500,
+
+ 500, 500, 500, 500, 500, 500, 500, 500,
+ 500, 177, 500, 500, 500, 500, 500, 500,
+ 500, 177, 500, 500, 177, 501, 500, 500,
+ 500, 500, 177, 177, 502, 500, 503, 498,
+
+ 499, 498, 498, 498, 504, 177, 177, 499,
+ 499, 177, 177, 499, 499, 505, 177, 177,
+ 177, 177, 177, 177, 177, 177, 498, 503,
+ 177, 177, 177, 177, 500, 500, 177, 500,
+
+ 500, 500, 504, 504, 177, 177, 506, 507,
+ 508, 509, 510, 511, 512, 513, 514, 515,
+ 516, 501, 517, 517, 517, 517, 517, 517,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 177, 518, 519, 177, 519, 519, 519,
+ 519, 519, 519, 177, 177, 177, 519, 519,
+ 519, 177, 519, 519, 519, 519, 177, 177,
+ 177, 519, 519, 177, 519, 177, 519, 519,
+
+ 177, 177, 177, 519, 519, 177, 177, 177,
+ 519, 519, 519, 177, 177, 177, 519, 519,
+ 519, 519, 519, 519, 519, 519, 520, 519,
+ 519, 519, 177, 177, 177, 177, 521, 522,
+
+ 518, 522, 522, 177, 177, 177, 522, 522,
+ 522, 177, 522, 522, 522, 523, 177, 177,
+ 524, 177, 177, 177, 177, 177, 177, 521,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 177, 177, 177, 177, 177, 525, 526,
+ 527, 528, 529, 530, 531, 532, 533, 534,
+ 535, 535, 535, 536, 536, 536, 536, 536,
+ 536, 537, 536, 177, 177, 177, 177, 177,
+
+ 177, 538, 538, 538, 177, 539, 539, 539,
+ 539, 539, 539, 539, 539, 177, 539, 539,
+ 539, 177, 539, 539, 539, 539, 539, 539,
+ 539, 539, 539, 539, 539, 539, 539, 539,
+
+ 539, 539, 539, 539, 539, 539, 539, 539,
+ 539, 177, 539, 539, 539, 539, 539, 539,
+ 539, 539, 539, 539, 177, 539, 539, 539,
+ 539, 539, 177, 177, 177, 540, 541, 541,
+
+ 541, 538, 538, 538, 538, 177, 541, 541,
+ 541, 177, 541, 541, 541, 542, 177, 177,
+ 177, 177, 177, 177, 177, 543, 544, 177,
+ 540, 540, 177, 177, 177, 177, 177, 177,
+
+ 539, 539, 545, 545, 177, 177, 546, 547,
+ 548, 549, 550, 551, 552, 553, 554, 555,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 556, 556, 556, 556, 556, 556, 556, 557,
+
+ 177, 177, 558, 558, 177, 559, 559, 559,
+ 559, 559, 559, 559, 559, 177, 559, 559,
+ 559, 177, 559, 559, 559, 559, 559, 559,
+ 559, 559, 559, 559, 559, 559, 559, 559,
+
+ 559, 559, 559, 559, 559, 559, 559, 559,
+ 559, 177, 559, 559, 559, 559, 559, 559,
+ 559, 559, 559, 559, 177, 559, 559, 559,
+ 559, 559, 177, 177, 560, 561, 558, 562,
+
+ 558, 558, 563, 558, 558, 177, 562, 558,
+ 558, 177, 558, 558, 564, 565, 177, 177,
+ 177, 177, 177, 177, 177, 563, 563, 177,
+ 177, 177, 177, 177, 177, 177, 559, 177,
+
+ 559, 559, 566, 566, 177, 177, 567, 568,
+ 569, 570, 571, 572, 573, 574, 575, 576,
+ 177, 577, 577, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 177, 578, 578, 177, 579, 579, 579,
+ 579, 579, 579, 579, 579, 177, 579, 579,
+ 579, 177, 579, 579, 579, 579, 579, 579,
+ 579, 579, 579, 579, 579, 579, 579, 579,
+
+ 579, 579, 579, 579, 579, 579, 579, 579,
+ 579, 580, 579, 579, 579, 579, 579, 579,
+ 579, 579, 579, 579, 579, 579, 579, 579,
+ 579, 579, 580, 177, 177, 581, 582, 578,
+
+ 578, 583, 583, 583, 584, 177, 578, 578,
+ 578, 177, 578, 578, 578, 585, 580, 177,
+ 177, 177, 177, 177, 177, 177, 177, 582,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 579, 579, 584, 584, 177, 177, 586, 587,
+ 588, 589, 590, 591, 592, 593, 594, 595,
+ 596, 596, 596, 596, 596, 596, 177, 177,
+ 177, 597, 581, 581, 581, 581, 581, 581,
+
+ 177, 177, 598, 598, 177, 599, 599, 599,
+ 599, 599, 599, 599, 599, 599, 599, 599,
+ 599, 599, 599, 599, 599, 599, 599, 177,
+ 177, 177, 599, 599, 599, 599, 599, 599,
+
+ 599, 599, 599, 599, 599, 599, 599, 599,
+ 599, 599, 599, 599, 599, 599, 599, 599,
+ 599, 599, 177, 599, 599, 599, 599, 599,
+ 599, 599, 599, 599, 177, 599, 177, 177,
+
+ 599, 599, 599, 599, 599, 599, 599, 177,
+ 177, 177, 600, 177, 177, 177, 177, 601,
+ 598, 598, 602, 602, 602, 177, 602, 177,
+ 598, 598, 598, 598, 598, 598, 598, 601,
+
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 598, 598, 603, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 604, 604, 604, 604, 604, 604, 604,
+ 604, 604, 604, 604, 604, 604, 604, 604,
+ 604, 604, 604, 604, 604, 604, 604, 604,
+ 604, 604, 604, 604, 604, 604, 604, 604,
+
+ 604, 604, 604, 604, 604, 604, 604, 604,
+ 604, 604, 604, 604, 604, 604, 604, 604,
+ 604, 605, 604, 606, 605, 605, 605, 605,
+ 607, 607, 608, 177, 177, 177, 177, 12,
+
+ 604, 604, 604, 604, 604, 604, 609, 605,
+ 610, 610, 610, 610, 605, 605, 605, 611,
+ 612, 613, 614, 615, 616, 617, 618, 619,
+ 620, 621, 622, 622, 177, 177, 177, 177,
+
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 623, 623, 177, 623, 177, 177, 623,
+ 623, 177, 623, 177, 177, 623, 177, 177,
+ 177, 177, 177, 177, 623, 623, 623, 623,
+ 177, 623, 623, 623, 623, 623, 623, 623,
+
+ 177, 623, 623, 623, 177, 623, 177, 623,
+ 177, 177, 623, 623, 177, 623, 623, 623,
+ 623, 624, 623, 625, 624, 624, 624, 624,
+ 626, 626, 177, 624, 624, 623, 177, 177,
+
+ 623, 623, 623, 623, 623, 177, 627, 177,
+ 628, 628, 628, 628, 624, 624, 177, 177,
+ 629, 630, 631, 632, 633, 634, 635, 636,
+ 637, 638, 177, 177, 623, 623, 639, 639,
+
+ 640, 641, 641, 641, 642, 643, 642, 642,
+ 644, 642, 642, 645, 644, 646, 646, 646,
+ 646, 646, 644, 647, 646, 647, 647, 647,
+ 648, 648, 647, 647, 647, 647, 647, 647,
+
+ 649, 650, 651, 652, 653, 654, 655, 656,
+ 657, 658, 659, 659, 659, 659, 659, 659,
+ 659, 659, 659, 659, 660, 648, 647, 648,
+ 647, 661, 662, 663, 662, 663, 664, 664,
+
+ 640, 640, 640, 640, 640, 640, 640, 640,
+ 177, 640, 640, 640, 640, 640, 640, 640,
+ 640, 640, 640, 640, 640, 640, 640, 640,
+ 640, 640, 640, 640, 640, 640, 640, 640,
+
+ 640, 640, 640, 640, 640, 640, 640, 640,
+ 640, 640, 665, 666, 666, 177, 177, 177,
+ 177, 667, 668, 669, 670, 669, 669, 669,
+ 669, 669, 668, 668, 668, 668, 669, 671,
+
+ 668, 669, 672, 672, 673, 645, 672, 672,
+ 640, 640, 640, 640, 674, 675, 675, 675,
+ 669, 669, 669, 669, 669, 669, 676, 669,
+ 177, 669, 669, 669, 669, 669, 669, 669,
+
+ 669, 669, 669, 669, 669, 669, 669, 669,
+ 669, 669, 669, 669, 669, 669, 676, 676,
+ 676, 669, 669, 669, 669, 669, 669, 669,
+ 676, 669, 676, 676, 676, 177, 677, 677,
+
+ 678, 678, 678, 678, 678, 678, 679, 678,
+ 678, 678, 678, 678, 678, 177, 680, 678,
+ 681, 681, 682, 683, 684, 685, 685, 685,
+ 685, 686, 686, 177, 177, 177, 177, 177,
+
+ 687, 687, 687, 687, 687, 687, 687, 687,
+ 687, 687, 687, 687, 687, 687, 687, 687,
+ 687, 687, 687, 687, 687, 687, 687, 687,
+ 687, 687, 687, 687, 687, 687, 687, 687,
+
+ 687, 687, 688, 687, 687, 687, 687, 687,
+ 688, 687, 687, 689, 690, 691, 691, 691,
+ 691, 692, 691, 693, 693, 693, 691, 694,
+ 690, 695, 696, 697, 697, 693, 693, 688,
+
+ 698, 699, 700, 701, 702, 703, 704, 705,
+ 706, 707, 708, 708, 709, 709, 709, 709,
+ 687, 687, 687, 687, 687, 687, 692, 692,
+ 691, 691, 688, 688, 688, 688, 693, 693,
+
+ 693, 688, 689, 689, 689, 688, 688, 689,
+ 689, 689, 689, 689, 689, 689, 688, 688,
+ 688, 693, 693, 693, 693, 688, 688, 688,
+ 688, 688, 688, 688, 688, 688, 688, 688,
+
+ 688, 688, 693, 689, 697, 693, 693, 689,
+ 689, 689, 689, 689, 689, 710, 688, 689,
+ 711, 712, 713, 714, 715, 716, 717, 718,
+ 719, 720, 721, 721, 721, 722, 723, 723,
+
+ 724, 724, 724, 724, 724, 724, 724, 724,
+ 724, 724, 724, 724, 724, 724, 724, 724,
+ 724, 724, 724, 724, 724, 724, 724, 724,
+ 724, 724, 724, 724, 724, 724, 724, 724,
+
+ 724, 724, 724, 724, 724, 724, 177, 725,
+ 177, 177, 177, 177, 177, 725, 177, 177,
+ 726, 726, 726, 726, 726, 726, 726, 726,
+ 726, 726, 726, 726, 726, 726, 726, 726,
+
+ 726, 726, 726, 726, 726, 726, 726, 726,
+ 726, 726, 726, 726, 726, 726, 726, 726,
+ 726, 726, 726, 726, 726, 726, 726, 727,
+ 727, 728, 728, 729, 730, 731, 731, 731,
732, 732, 732, 732, 732, 732, 732, 732,
732, 732, 732, 732, 732, 732, 732, 732,
@@ -1557,82 +1537,97 @@ static const unsigned short uc_property_trie[] = {
732, 732, 732, 732, 732, 732, 732, 732,
732, 732, 732, 732, 732, 732, 732, 732,
732, 732, 732, 732, 732, 732, 732, 732,
- 732, 732, 733, 733, 733, 733, 733, 733,
-
- 734, 734, 734, 734, 734, 734, 734, 735,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
-
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
-
- 734, 734, 734, 734, 734, 734, 734, 735,
- 734, 175, 734, 734, 734, 734, 175, 175,
- 734, 734, 734, 734, 734, 734, 734, 175,
- 734, 175, 734, 734, 734, 734, 175, 175,
-
- 734, 734, 734, 734, 734, 734, 734, 735,
- 734, 175, 734, 734, 734, 734, 175, 175,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
-
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 735,
- 734, 175, 734, 734, 734, 734, 175, 175,
- 734, 734, 734, 734, 734, 734, 734, 175,
-
- 734, 175, 734, 734, 734, 734, 175, 175,
- 734, 734, 734, 734, 734, 734, 734, 735,
- 734, 734, 734, 734, 734, 734, 734, 175,
- 734, 734, 734, 734, 734, 734, 734, 734,
+ 732, 732, 733, 733, 733, 733, 733, 732,
734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 735,
734, 734, 734, 734, 734, 734, 734, 734,
734, 734, 734, 734, 734, 734, 734, 734,
-
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 735,
- 734, 175, 734, 734, 734, 734, 175, 175,
- 734, 734, 734, 734, 734, 734, 734, 735,
-
- 734, 734, 734, 734, 734, 734, 734, 735,
734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 175, 175, 736, 736, 737,
-
- 738, 739, 740, 741, 741, 741, 741, 740,
- 740, 742, 743, 744, 745, 746, 747, 748,
- 749, 750, 751, 751, 751, 751, 751, 751,
- 751, 751, 751, 751, 751, 175, 175, 175,
-
- 735, 735, 735, 735, 735, 735, 735, 735,
- 735, 735, 735, 735, 735, 735, 735, 735,
- 752, 752, 752, 752, 752, 752, 752, 752,
- 752, 752, 175, 175, 175, 175, 175, 175,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
+ 734, 734, 734, 735, 735, 735, 735, 735,
+ 736, 736, 736, 736, 736, 736, 736, 736,
+ 736, 736, 736, 736, 736, 736, 736, 736,
+ 736, 736, 736, 736, 736, 736, 736, 736,
+
+ 736, 736, 736, 736, 736, 736, 736, 736,
+ 736, 736, 736, 736, 736, 736, 736, 736,
+ 736, 736, 736, 736, 736, 736, 736, 736,
+ 736, 736, 736, 736, 736, 736, 736, 736,
+
+ 736, 736, 736, 736, 736, 736, 736, 736,
+ 736, 736, 736, 736, 736, 736, 736, 736,
+ 736, 736, 736, 736, 736, 736, 736, 736,
+ 736, 736, 737, 737, 737, 737, 737, 737,
+
+ 738, 738, 738, 738, 738, 738, 738, 739,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+
+ 738, 738, 738, 738, 738, 738, 738, 738,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+
+ 738, 738, 738, 738, 738, 738, 738, 739,
+ 738, 177, 738, 738, 738, 738, 177, 177,
+ 738, 738, 738, 738, 738, 738, 738, 177,
+ 738, 177, 738, 738, 738, 738, 177, 177,
+
+ 738, 738, 738, 738, 738, 738, 738, 739,
+ 738, 177, 738, 738, 738, 738, 177, 177,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+
+ 738, 738, 738, 738, 738, 738, 738, 738,
+ 738, 738, 738, 738, 738, 738, 738, 739,
+ 738, 177, 738, 738, 738, 738, 177, 177,
+ 738, 738, 738, 738, 738, 738, 738, 177,
+
+ 738, 177, 738, 738, 738, 738, 177, 177,
+ 738, 738, 738, 738, 738, 738, 738, 739,
+ 738, 738, 738, 738, 738, 738, 738, 177,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+
+ 738, 738, 738, 738, 738, 738, 738, 738,
+ 738, 738, 738, 738, 738, 738, 738, 739,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+
+ 738, 738, 738, 738, 738, 738, 738, 738,
+ 738, 738, 738, 738, 738, 738, 738, 739,
+ 738, 177, 738, 738, 738, 738, 177, 177,
+ 738, 738, 738, 738, 738, 738, 738, 739,
+
+ 738, 738, 738, 738, 738, 738, 738, 739,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+ 738, 738, 738, 738, 738, 738, 738, 738,
+ 738, 738, 738, 177, 177, 740, 740, 741,
+
+ 742, 743, 744, 745, 745, 745, 745, 744,
+ 744, 746, 747, 748, 749, 750, 751, 752,
+ 753, 754, 755, 755, 755, 755, 755, 755,
+ 755, 755, 755, 755, 755, 177, 177, 177,
+
+ 739, 739, 739, 739, 739, 739, 739, 739,
+ 739, 739, 739, 739, 739, 739, 739, 739,
+ 756, 756, 756, 756, 756, 756, 756, 756,
+ 756, 756, 177, 177, 177, 177, 177, 177,
- 753, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
+ 757, 757, 757, 757, 757, 757, 757, 757,
+ 757, 757, 757, 757, 757, 757, 757, 757,
+ 757, 757, 757, 757, 757, 757, 757, 757,
+ 757, 757, 757, 757, 757, 757, 757, 757,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 741, 740, 734,
- 734, 734, 734, 734, 734, 734, 734, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
+ 757, 757, 757, 757, 757, 757, 757, 757,
+ 757, 757, 757, 757, 757, 757, 757, 757,
+ 757, 757, 757, 757, 757, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
- 755, 756, 756, 756, 756, 756, 756, 756,
- 756, 756, 756, 756, 756, 756, 756, 756,
- 756, 756, 756, 756, 756, 756, 756, 756,
- 756, 756, 756, 757, 758, 175, 175, 175,
+ 758, 759, 759, 759, 759, 759, 759, 759,
+ 759, 759, 759, 759, 759, 759, 759, 759,
+ 759, 759, 759, 759, 759, 759, 759, 759,
+ 759, 759, 759, 759, 759, 759, 759, 759,
759, 759, 759, 759, 759, 759, 759, 759,
759, 759, 759, 759, 759, 759, 759, 759,
@@ -1640,372 +1635,392 @@ static const unsigned short uc_property_trie[] = {
759, 759, 759, 759, 759, 759, 759, 759,
759, 759, 759, 759, 759, 759, 759, 759,
- 759, 759, 759, 739, 739, 739, 760, 760,
- 760, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 761, 761, 761, 761, 761, 761, 761, 761,
- 761, 761, 761, 761, 761, 175, 761, 761,
- 761, 761, 762, 762, 763, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 761, 761, 761, 761, 761, 761, 761, 761,
- 761, 761, 761, 761, 761, 761, 761, 761,
- 761, 761, 762, 762, 763, 764, 764, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 761, 761, 761, 761, 761, 761, 761, 761,
- 761, 761, 761, 761, 761, 761, 761, 761,
- 761, 761, 762, 762, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 761, 761, 761, 761, 761, 761, 761, 761,
- 761, 761, 761, 761, 761, 175, 761, 761,
- 761, 175, 762, 762, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 765, 765, 765, 765, 765, 765, 765, 765,
- 765, 765, 765, 765, 765, 765, 765, 765,
- 765, 765, 765, 765, 765, 765, 765, 765,
- 765, 765, 765, 765, 765, 765, 765, 765,
-
- 765, 765, 765, 765, 765, 765, 765, 765,
- 765, 765, 765, 765, 765, 765, 765, 765,
- 765, 765, 765, 765, 766, 766, 767, 766,
- 766, 766, 766, 766, 766, 766, 767, 767,
-
- 767, 767, 767, 767, 767, 767, 766, 767,
- 767, 766, 766, 766, 766, 766, 766, 766,
- 766, 766, 768, 766, 769, 769, 770, 771,
- 769, 772, 769, 773, 765, 774, 175, 175,
-
- 775, 776, 777, 778, 779, 780, 781, 782,
- 783, 784, 175, 175, 175, 175, 175, 175,
- 785, 785, 785, 785, 785, 785, 785, 785,
- 785, 785, 175, 175, 175, 175, 175, 175,
-
- 786, 786, 787, 788, 789, 789, 790, 786,
- 787, 788, 786, 791, 791, 791, 792, 175,
- 793, 794, 795, 796, 797, 798, 799, 800,
- 801, 802, 175, 175, 175, 175, 175, 175,
-
- 734, 734, 734, 149, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
-
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 734, 734, 734, 734, 734, 734, 734,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 734, 734, 734, 734, 734, 734, 734, 734,
- 734, 803, 804, 175, 175, 175, 175, 175,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
-
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
-
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 175, 175, 175,
-
- 806, 806, 806, 807, 807, 807, 807, 806,
- 806, 807, 807, 807, 175, 175, 175, 175,
- 807, 807, 806, 807, 807, 807, 807, 807,
- 807, 808, 809, 810, 175, 175, 175, 175,
-
- 811, 175, 175, 175, 812, 812, 813, 814,
- 815, 816, 817, 818, 819, 820, 821, 822,
- 823, 823, 823, 823, 823, 823, 823, 823,
- 823, 823, 823, 823, 823, 823, 823, 823,
-
- 823, 823, 823, 823, 823, 823, 823, 823,
- 823, 823, 823, 823, 823, 823, 175, 175,
- 823, 823, 823, 823, 823, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 824, 824, 824, 824, 824, 824, 824, 824,
- 824, 824, 824, 824, 824, 824, 824, 824,
- 824, 824, 824, 824, 824, 824, 824, 824,
- 824, 824, 824, 824, 824, 824, 824, 824,
-
- 824, 824, 824, 824, 824, 824, 824, 824,
- 824, 824, 825, 825, 175, 175, 175, 175,
- 826, 826, 826, 826, 826, 827, 827, 827,
- 826, 826, 827, 826, 826, 826, 826, 826,
-
- 826, 824, 824, 824, 824, 824, 824, 824,
- 826, 826, 175, 175, 175, 175, 175, 175,
- 828, 829, 830, 831, 832, 833, 834, 835,
- 836, 837, 838, 175, 175, 175, 839, 839,
-
- 840, 840, 840, 840, 840, 840, 840, 840,
- 840, 840, 840, 840, 840, 840, 840, 840,
- 840, 840, 840, 840, 840, 840, 840, 840,
- 840, 840, 840, 840, 840, 840, 840, 840,
-
- 735, 735, 735, 735, 735, 735, 735, 735,
- 735, 735, 735, 735, 735, 735, 735, 735,
- 735, 735, 735, 735, 735, 735, 735, 737,
- 841, 842, 842, 842, 175, 175, 738, 738,
-
- 825, 825, 825, 825, 825, 825, 825, 825,
- 825, 825, 825, 825, 825, 825, 825, 825,
- 825, 825, 825, 825, 825, 825, 825, 825,
- 825, 825, 825, 825, 825, 825, 825, 825,
-
- 825, 825, 825, 825, 825, 825, 825, 825,
- 825, 825, 825, 825, 825, 825, 825, 825,
- 825, 825, 825, 825, 825, 843, 844, 843,
- 844, 844, 844, 844, 844, 844, 844, 175,
-
- 845, 846, 844, 846, 846, 844, 844, 844,
- 844, 844, 844, 844, 844, 843, 843, 843,
- 843, 843, 843, 844, 844, 847, 847, 847,
- 847, 847, 847, 847, 847, 175, 175, 848,
-
+ 759, 759, 759, 759, 759, 760, 761, 759,
+ 759, 759, 759, 759, 759, 759, 759, 762,
+ 762, 762, 762, 762, 762, 762, 762, 762,
+
+ 763, 764, 764, 764, 764, 764, 764, 764,
+ 764, 764, 764, 764, 764, 764, 764, 764,
+ 764, 764, 764, 764, 764, 764, 764, 764,
+ 764, 764, 764, 765, 766, 177, 177, 177,
+
+ 767, 767, 767, 767, 767, 767, 767, 767,
+ 767, 767, 767, 767, 767, 767, 767, 767,
+ 767, 767, 767, 767, 767, 767, 767, 767,
+ 767, 767, 767, 767, 767, 767, 767, 767,
+
+ 767, 767, 767, 767, 767, 767, 767, 767,
+ 767, 767, 767, 768, 768, 768, 769, 769,
+ 769, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 770, 770, 770, 770, 770, 770, 770, 770,
+ 770, 770, 770, 770, 770, 177, 770, 770,
+ 770, 770, 771, 771, 772, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 773, 773, 773, 773, 773, 773, 773, 773,
+ 773, 773, 773, 773, 773, 773, 773, 773,
+ 773, 773, 774, 774, 775, 776, 776, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 777, 777, 777, 777, 777, 777, 777, 777,
+ 777, 777, 777, 777, 777, 777, 777, 777,
+ 777, 777, 778, 778, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 779, 779, 779, 779, 779, 779, 779, 779,
+ 779, 779, 779, 779, 779, 177, 779, 779,
+ 779, 177, 780, 780, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 781, 781, 781, 781, 781, 781, 781, 781,
+ 781, 781, 781, 781, 781, 781, 781, 781,
+ 781, 781, 781, 781, 781, 781, 781, 781,
+ 781, 781, 781, 781, 781, 781, 781, 781,
+
+ 781, 781, 781, 781, 781, 781, 781, 781,
+ 781, 781, 781, 781, 781, 781, 781, 781,
+ 781, 781, 781, 781, 782, 782, 783, 782,
+ 782, 782, 782, 782, 782, 782, 783, 783,
+
+ 783, 783, 783, 783, 783, 783, 782, 783,
+ 783, 782, 782, 782, 782, 782, 782, 782,
+ 782, 782, 784, 782, 785, 785, 786, 787,
+ 785, 788, 785, 789, 781, 790, 177, 177,
+
+ 791, 792, 793, 794, 795, 796, 797, 798,
+ 799, 800, 177, 177, 177, 177, 177, 177,
+ 801, 801, 801, 801, 801, 801, 801, 801,
+ 801, 801, 177, 177, 177, 177, 177, 177,
+
+ 802, 802, 803, 804, 805, 806, 807, 802,
+ 808, 809, 802, 810, 810, 810, 811, 177,
+ 812, 813, 814, 815, 816, 817, 818, 819,
+ 820, 821, 177, 177, 177, 177, 177, 177,
+
+ 822, 822, 822, 822, 822, 822, 822, 822,
+ 822, 822, 822, 822, 822, 822, 822, 822,
+ 822, 822, 822, 822, 822, 822, 822, 822,
+ 822, 822, 822, 822, 822, 822, 822, 822,
+
+ 822, 822, 822, 823, 822, 822, 822, 822,
+ 822, 822, 822, 822, 822, 822, 822, 822,
+ 822, 822, 822, 822, 822, 822, 822, 822,
+ 822, 822, 822, 822, 822, 822, 822, 822,
+
+ 822, 822, 822, 822, 822, 822, 822, 822,
+ 822, 822, 822, 822, 822, 822, 822, 822,
+ 822, 822, 822, 822, 822, 822, 822, 822,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 822, 822, 822, 822, 822, 822, 822, 822,
+ 822, 824, 825, 177, 177, 177, 177, 177,
+ 762, 762, 762, 762, 762, 762, 762, 762,
+ 762, 762, 762, 762, 762, 762, 762, 762,
+
+ 762, 762, 762, 762, 762, 762, 762, 762,
+ 762, 762, 762, 762, 762, 762, 762, 762,
+ 762, 762, 762, 762, 762, 762, 762, 762,
+ 762, 762, 762, 762, 762, 762, 762, 762,
+
+ 762, 762, 762, 762, 762, 762, 762, 762,
+ 762, 762, 762, 762, 762, 762, 762, 762,
+ 762, 762, 762, 762, 762, 762, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 826, 826, 826, 826, 826, 826, 826, 826,
+ 826, 826, 826, 826, 826, 826, 826, 826,
+ 826, 826, 826, 826, 826, 826, 826, 826,
+ 826, 826, 826, 826, 826, 177, 177, 177,
+
+ 827, 827, 827, 828, 828, 828, 828, 827,
+ 827, 828, 828, 828, 177, 177, 177, 177,
+ 828, 828, 827, 828, 828, 828, 828, 828,
+ 828, 829, 830, 831, 177, 177, 177, 177,
+
+ 832, 177, 177, 177, 833, 833, 834, 835,
+ 836, 837, 838, 839, 840, 841, 842, 843,
+ 844, 844, 844, 844, 844, 844, 844, 844,
+ 844, 844, 844, 844, 844, 844, 844, 844,
+
+ 844, 844, 844, 844, 844, 844, 844, 844,
+ 844, 844, 844, 844, 844, 844, 177, 177,
+ 844, 844, 844, 844, 844, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 845, 845, 845, 845, 845, 845, 845, 845,
+ 845, 845, 845, 845, 845, 845, 845, 845,
+ 845, 845, 845, 845, 845, 845, 845, 845,
+ 845, 845, 845, 845, 845, 845, 845, 845,
+
+ 845, 845, 845, 845, 845, 845, 845, 845,
+ 845, 845, 846, 846, 177, 177, 177, 177,
+ 847, 847, 847, 847, 847, 848, 848, 848,
+ 847, 847, 848, 847, 847, 847, 847, 847,
+
+ 847, 845, 845, 845, 845, 845, 845, 845,
+ 847, 847, 177, 177, 177, 177, 177, 177,
849, 850, 851, 852, 853, 854, 855, 856,
- 857, 858, 175, 175, 175, 175, 175, 175,
- 849, 850, 851, 852, 853, 854, 855, 856,
- 857, 858, 175, 175, 175, 175, 175, 175,
-
- 859, 859, 859, 859, 859, 859, 859, 860,
- 861, 861, 861, 861, 859, 859, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 862, 862, 862, 862, 863, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
-
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 865, 863, 862, 862,
- 862, 862, 862, 863, 862, 863, 863, 863,
-
- 863, 863, 862, 863, 866, 864, 864, 864,
- 864, 864, 864, 864, 175, 175, 175, 175,
- 867, 868, 869, 870, 871, 872, 873, 874,
- 875, 876, 877, 877, 878, 879, 877, 877,
-
- 879, 880, 880, 880, 880, 880, 880, 880,
- 880, 880, 880, 881, 882, 881, 881, 881,
- 881, 881, 881, 881, 880, 880, 880, 880,
- 880, 880, 880, 880, 880, 175, 175, 175,
-
- 883, 883, 884, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
-
- 804, 884, 883, 883, 883, 883, 884, 884,
- 883, 883, 885, 886, 887, 887, 804, 804,
- 888, 889, 890, 891, 892, 893, 894, 895,
- 896, 897, 898, 898, 898, 898, 898, 898,
-
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
-
- 899, 899, 899, 899, 899, 899, 900, 901,
- 902, 902, 901, 901, 901, 902, 901, 902,
- 902, 902, 903, 903, 175, 175, 175, 175,
- 175, 175, 175, 175, 904, 904, 904, 904,
-
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
-
- 804, 804, 804, 804, 884, 884, 884, 884,
- 884, 884, 884, 884, 883, 883, 883, 883,
- 883, 883, 883, 883, 884, 884, 883, 905,
- 175, 175, 175, 906, 906, 907, 907, 907,
-
- 888, 889, 890, 891, 892, 893, 894, 895,
- 896, 897, 175, 175, 175, 804, 804, 804,
- 888, 889, 890, 891, 892, 893, 894, 895,
- 896, 897, 804, 804, 804, 804, 804, 804,
-
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 908, 908, 908, 908, 908, 908, 906, 906,
-
- 909, 909, 909, 909, 909, 909, 909, 909,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 910, 910, 910, 911, 912, 913, 913, 913,
- 913, 913, 910, 910, 913, 913, 913, 913,
-
- 910, 914, 912, 912, 912, 912, 912, 912,
- 912, 754, 754, 754, 754, 913, 754, 754,
- 754, 754, 914, 887, 915, 898, 898, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
+ 857, 858, 859, 177, 177, 177, 860, 860,
+
+ 861, 861, 861, 861, 861, 861, 861, 861,
+ 861, 861, 861, 861, 861, 861, 861, 861,
+ 861, 861, 861, 861, 861, 861, 861, 861,
+ 861, 861, 861, 861, 861, 861, 861, 861,
+
+ 862, 862, 862, 862, 862, 862, 862, 862,
+ 862, 862, 862, 862, 862, 862, 862, 862,
+ 862, 862, 862, 862, 862, 862, 862, 863,
+ 864, 865, 865, 865, 177, 177, 866, 866,
+
+ 867, 867, 867, 867, 867, 867, 867, 867,
+ 867, 867, 867, 867, 867, 867, 867, 867,
+ 867, 867, 867, 867, 867, 867, 867, 867,
+ 867, 867, 867, 867, 867, 867, 867, 867,
+
+ 867, 867, 867, 867, 867, 867, 867, 867,
+ 867, 867, 867, 867, 867, 867, 867, 867,
+ 867, 867, 867, 867, 867, 868, 869, 868,
+ 869, 869, 869, 869, 869, 869, 869, 177,
+
+ 870, 871, 869, 871, 871, 869, 869, 869,
+ 869, 869, 869, 869, 869, 868, 868, 868,
+ 868, 868, 868, 869, 869, 872, 872, 872,
+ 872, 872, 872, 872, 872, 177, 177, 873,
+
+ 874, 875, 876, 877, 878, 879, 880, 881,
+ 882, 883, 177, 177, 177, 177, 177, 177,
+ 874, 875, 876, 877, 878, 879, 880, 881,
+ 882, 883, 177, 177, 177, 177, 177, 177,
+
+ 884, 884, 884, 884, 884, 884, 884, 885,
+ 886, 886, 886, 886, 884, 884, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 887, 887, 887, 887, 888, 889, 889, 889,
+ 889, 889, 889, 889, 889, 889, 889, 889,
+ 889, 889, 889, 889, 889, 889, 889, 889,
+ 889, 889, 889, 889, 889, 889, 889, 889,
+
+ 889, 889, 889, 889, 889, 889, 889, 889,
+ 889, 889, 889, 889, 889, 889, 889, 889,
+ 889, 889, 889, 889, 890, 888, 887, 887,
+ 887, 887, 887, 888, 887, 888, 888, 888,
+
+ 888, 888, 887, 888, 891, 889, 889, 889,
+ 889, 889, 889, 889, 177, 177, 177, 177,
+ 892, 893, 894, 895, 896, 897, 898, 899,
+ 900, 901, 902, 902, 903, 904, 902, 902,
+
+ 904, 905, 905, 905, 905, 905, 905, 905,
+ 905, 905, 905, 906, 907, 906, 906, 906,
+ 906, 906, 906, 906, 905, 905, 905, 905,
+ 905, 905, 905, 905, 905, 177, 177, 177,
+
+ 908, 908, 909, 910, 910, 910, 910, 910,
+ 910, 910, 910, 910, 910, 910, 910, 910,
+ 910, 910, 910, 910, 910, 910, 910, 910,
+ 910, 910, 910, 910, 910, 910, 910, 910,
+
+ 910, 909, 908, 908, 908, 908, 909, 909,
+ 908, 908, 911, 912, 913, 913, 910, 910,
+ 914, 915, 916, 917, 918, 919, 920, 921,
+ 922, 923, 924, 924, 924, 924, 924, 924,
+
+ 925, 925, 925, 925, 925, 925, 925, 925,
+ 925, 925, 925, 925, 925, 925, 925, 925,
+ 925, 925, 925, 925, 925, 925, 925, 925,
+ 925, 925, 925, 925, 925, 925, 925, 925,
+
+ 925, 925, 925, 925, 925, 925, 926, 927,
+ 928, 928, 927, 927, 927, 928, 927, 928,
+ 928, 928, 929, 929, 177, 177, 177, 177,
+ 177, 177, 177, 177, 930, 930, 930, 930,
+
+ 931, 931, 931, 931, 931, 931, 931, 931,
+ 931, 931, 931, 931, 931, 931, 931, 931,
+ 931, 931, 931, 931, 931, 931, 931, 931,
+ 931, 931, 931, 931, 931, 931, 931, 931,
+
+ 931, 931, 931, 931, 932, 932, 932, 932,
+ 932, 932, 932, 932, 933, 933, 933, 933,
+ 933, 933, 933, 933, 932, 932, 933, 934,
+ 177, 177, 177, 935, 935, 936, 936, 936,
+
+ 937, 938, 939, 940, 941, 942, 943, 944,
+ 945, 946, 177, 177, 177, 931, 931, 931,
+ 947, 948, 949, 950, 951, 952, 953, 954,
+ 955, 956, 957, 957, 957, 957, 957, 957,
+
+ 957, 957, 957, 957, 957, 957, 957, 957,
+ 957, 957, 957, 957, 957, 957, 957, 957,
+ 957, 957, 957, 957, 957, 957, 957, 957,
+ 958, 958, 958, 958, 958, 958, 959, 959,
+
+ 960, 960, 960, 960, 960, 960, 960, 960,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 961, 961, 961, 962, 963, 964, 964, 964,
+ 964, 964, 961, 961, 964, 964, 964, 964,
+
+ 961, 965, 963, 963, 963, 963, 963, 963,
+ 963, 966, 966, 966, 966, 964, 966, 966,
+ 966, 966, 965, 967, 968, 969, 969, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
105, 105, 105, 105, 105, 105, 105, 105,
105, 105, 105, 105, 105, 105, 105, 105,
105, 105, 105, 105, 105, 105, 105, 105,
105, 105, 105, 105, 105, 105, 105, 105,
- 105, 105, 105, 105, 105, 105, 916, 916,
- 916, 916, 916, 917, 918, 918, 918, 918,
- 918, 918, 918, 918, 918, 918, 918, 918,
- 918, 918, 918, 918, 918, 918, 918, 918,
+ 105, 105, 105, 105, 105, 105, 970, 970,
+ 970, 970, 970, 971, 972, 972, 972, 972,
+ 972, 972, 972, 972, 972, 972, 972, 972,
+ 972, 972, 972, 972, 972, 972, 972, 972,
- 918, 918, 918, 918, 918, 918, 918, 918,
- 918, 918, 918, 918, 918, 918, 918, 918,
- 918, 918, 918, 918, 918, 918, 918, 918,
- 918, 918, 918, 918, 918, 919, 919, 919,
+ 972, 972, 972, 972, 972, 972, 972, 972,
+ 972, 972, 972, 972, 972, 972, 972, 972,
+ 972, 972, 972, 972, 972, 972, 972, 972,
+ 972, 972, 972, 972, 972, 973, 973, 973,
- 919, 919, 918, 918, 918, 918, 919, 919,
- 919, 919, 919, 105, 106, 106, 106, 106,
+ 973, 973, 972, 972, 972, 972, 973, 973,
+ 973, 973, 973, 105, 106, 106, 106, 106,
106, 106, 106, 106, 106, 106, 106, 106,
- 920, 921, 106, 106, 106, 922, 106, 106,
+ 974, 975, 106, 106, 106, 976, 106, 106,
106, 106, 106, 106, 106, 106, 106, 106,
106, 106, 106, 106, 106, 106, 106, 106,
106, 106, 106, 106, 106, 106, 106, 106,
- 106, 106, 106, 923, 923, 923, 923, 923,
+ 106, 106, 106, 977, 977, 977, 977, 977,
- 923, 923, 923, 923, 923, 923, 923, 923,
- 923, 923, 923, 923, 923, 923, 923, 923,
- 923, 923, 923, 923, 923, 923, 923, 923,
- 923, 923, 923, 923, 923, 923, 923, 924,
+ 977, 977, 977, 977, 977, 977, 977, 977,
+ 977, 977, 977, 977, 977, 977, 977, 977,
+ 977, 977, 977, 977, 977, 977, 977, 977,
+ 977, 977, 977, 977, 977, 977, 977, 978,
- 165, 165, 164, 165, 925, 925, 925, 925,
- 925, 925, 926, 927, 927, 928, 929, 930,
- 931, 927, 927, 927, 927, 927, 927, 927,
- 927, 927, 927, 927, 927, 927, 927, 927,
+ 167, 167, 166, 167, 979, 979, 979, 979,
+ 979, 979, 980, 981, 981, 982, 983, 984,
+ 985, 981, 981, 981, 981, 981, 981, 981,
+ 981, 981, 981, 981, 981, 981, 981, 981,
- 927, 927, 927, 927, 927, 927, 927, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 932, 913, 925, 926,
+ 981, 981, 981, 981, 981, 981, 981, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 986, 964, 979, 980,
67, 68, 67, 68, 67, 68, 67, 68,
67, 68, 67, 68, 67, 68, 67, 68,
- 67, 68, 67, 68, 67, 68, 933, 934,
- 935, 936, 937, 938, 939, 939, 940, 939,
+ 67, 68, 67, 68, 67, 68, 987, 988,
+ 989, 990, 991, 992, 993, 993, 994, 993,
67, 68, 67, 68, 67, 68, 67, 68,
67, 68, 67, 68, 67, 68, 67, 68,
67, 68, 67, 68, 67, 68, 67, 68,
- 67, 68, 941, 942, 941, 942, 941, 942,
-
- 943, 943, 943, 943, 943, 943, 943, 943,
- 944, 944, 944, 944, 944, 944, 944, 944,
- 943, 943, 943, 943, 943, 943, 175, 175,
- 944, 944, 944, 944, 944, 944, 175, 175,
-
- 943, 943, 943, 943, 943, 943, 943, 943,
- 944, 944, 944, 944, 944, 944, 944, 944,
- 943, 943, 943, 943, 943, 943, 943, 943,
- 944, 944, 944, 944, 944, 944, 944, 944,
-
- 943, 943, 943, 943, 943, 943, 175, 175,
- 944, 944, 944, 944, 944, 944, 175, 175,
- 945, 943, 946, 943, 947, 943, 948, 943,
- 175, 944, 175, 944, 175, 944, 175, 944,
-
- 943, 943, 943, 943, 943, 943, 943, 943,
- 944, 944, 944, 944, 944, 944, 944, 944,
- 949, 949, 950, 950, 950, 950, 951, 951,
- 952, 952, 953, 953, 954, 954, 175, 175,
-
- 955, 956, 957, 958, 959, 960, 961, 962,
- 963, 964, 965, 966, 967, 968, 969, 970,
- 971, 972, 973, 974, 975, 976, 977, 978,
- 979, 980, 981, 982, 983, 984, 985, 986,
-
- 987, 988, 989, 990, 991, 992, 993, 994,
- 995, 996, 997, 998, 999, 1000, 1001, 1002,
- 943, 943, 1003, 1004, 1005, 175, 1006, 1007,
- 944, 944, 1008, 1008, 1009, 174, 1010, 174,
-
- 174, 174, 1011, 1012, 1013, 175, 1014, 1015,
- 1016, 1016, 1016, 1016, 1017, 174, 174, 174,
- 943, 943, 1018, 182, 175, 175, 1019, 1020,
- 944, 944, 1021, 1021, 175, 174, 174, 174,
-
- 943, 943, 1022, 186, 1023, 204, 1024, 1025,
- 944, 944, 1026, 1026, 1027, 174, 174, 174,
- 175, 175, 1028, 1029, 1030, 175, 1031, 1032,
- 1033, 1033, 1034, 1034, 1035, 1036, 174, 175,
-
- 1037, 1037, 1037, 1037, 1037, 1037, 1037, 1038,
- 1037, 1037, 1037, 1039, 1040, 1041, 1042, 1043,
- 1044, 1045, 1044, 1046, 1047, 1048, 14, 14,
- 1049, 1050, 1051, 1052, 1052, 1053, 1051, 1052,
-
- 14, 14, 14, 14, 1054, 1055, 1055, 1056,
- 1057, 1058, 1059, 1060, 1061, 1062, 1063, 1064,
- 13, 13, 13, 13, 13, 1065, 1065, 1065,
- 14, 1066, 1067, 14, 1068, 1068, 14, 43,
-
- 43, 14, 14, 14, 1069, 16, 1070, 1071,
- 1072, 1072, 786, 786, 786, 786, 1073, 1073,
- 1073, 1073, 1074, 1075, 1076, 1077, 1078, 1073,
- 1078, 1078, 1078, 1078, 1077, 1078, 1078, 1079,
-
- 1080, 1081, 1081, 1081, 1082, 1083, 1083, 1083,
- 1083, 1083, 1084, 1084, 1084, 1084, 1084, 1084,
- 1085, 1086, 175, 175, 1087, 1088, 1089, 1090,
- 1091, 1092, 1093, 1093, 36, 16, 1070, 142,
-
- 1085, 62, 57, 58, 1087, 1088, 1089, 1090,
- 1091, 1092, 1093, 1093, 36, 16, 1070, 175,
- 923, 923, 923, 923, 923, 1094, 1094, 1094,
- 1094, 1094, 1094, 1094, 1094, 175, 175, 175,
+ 67, 68, 995, 996, 995, 996, 995, 996,
+
+ 997, 997, 997, 997, 997, 997, 997, 997,
+ 998, 998, 998, 998, 998, 998, 998, 998,
+ 997, 997, 997, 997, 997, 997, 177, 177,
+ 998, 998, 998, 998, 998, 998, 177, 177,
+
+ 997, 997, 997, 997, 997, 997, 997, 997,
+ 998, 998, 998, 998, 998, 998, 998, 998,
+ 997, 997, 997, 997, 997, 997, 997, 997,
+ 998, 998, 998, 998, 998, 998, 998, 998,
+
+ 997, 997, 997, 997, 997, 997, 177, 177,
+ 998, 998, 998, 998, 998, 998, 177, 177,
+ 999, 997, 1000, 997, 1001, 997, 1002, 997,
+ 177, 998, 177, 998, 177, 998, 177, 998,
+
+ 997, 997, 997, 997, 997, 997, 997, 997,
+ 998, 998, 998, 998, 998, 998, 998, 998,
+ 1003, 1003, 1004, 1004, 1004, 1004, 1005, 1005,
+ 1006, 1006, 1007, 1007, 1008, 1008, 177, 177,
+
+ 1009, 1010, 1011, 1012, 1013, 1014, 1015, 1016,
+ 1017, 1018, 1019, 1020, 1021, 1022, 1023, 1024,
+ 1025, 1026, 1027, 1028, 1029, 1030, 1031, 1032,
+ 1033, 1034, 1035, 1036, 1037, 1038, 1039, 1040,
+
+ 1041, 1042, 1043, 1044, 1045, 1046, 1047, 1048,
+ 1049, 1050, 1051, 1052, 1053, 1054, 1055, 1056,
+ 997, 997, 1057, 1058, 1059, 177, 1060, 1061,
+ 998, 998, 1062, 1062, 1063, 176, 1064, 176,
+
+ 176, 176, 1065, 1066, 1067, 177, 1068, 1069,
+ 1070, 1070, 1070, 1070, 1071, 176, 176, 176,
+ 997, 997, 1072, 184, 177, 177, 1073, 1074,
+ 998, 998, 1075, 1075, 177, 176, 176, 176,
+
+ 997, 997, 1076, 188, 1077, 208, 1078, 1079,
+ 998, 998, 1080, 1080, 1081, 176, 176, 176,
+ 177, 177, 1082, 1083, 1084, 177, 1085, 1086,
+ 1087, 1087, 1088, 1088, 1089, 1090, 176, 177,
+
+ 1091, 1091, 1091, 1091, 1091, 1091, 1091, 1092,
+ 1091, 1091, 1091, 1093, 1094, 1095, 1096, 1097,
+ 1098, 1099, 1098, 1100, 1101, 1102, 14, 14,
+ 1103, 1104, 1105, 1106, 1106, 1107, 1105, 1106,
+
+ 14, 14, 14, 14, 1108, 1109, 1109, 1110,
+ 1111, 1112, 1113, 1114, 1115, 1116, 1117, 1118,
+ 13, 13, 13, 13, 13, 1119, 1119, 1119,
+ 14, 1120, 1121, 14, 1122, 1122, 14, 43,
+
+ 43, 14, 14, 14, 1123, 16, 1124, 1125,
+ 1126, 1126, 1127, 1127, 1127, 1127, 1128, 1128,
+ 1128, 1128, 1129, 1130, 1131, 1132, 1133, 1128,
+ 1133, 1133, 1133, 1133, 1132, 1133, 1133, 1134,
+
+ 1135, 1136, 1136, 1136, 1137, 1138, 1138, 1138,
+ 1138, 1138, 1139, 1139, 1139, 1139, 1139, 1139,
+ 1140, 1141, 177, 177, 1142, 1143, 1144, 1145,
+ 1146, 1147, 1148, 1148, 36, 16, 1124, 142,
+
+ 1140, 62, 57, 58, 1142, 1143, 1144, 1145,
+ 1146, 1147, 1148, 1148, 36, 16, 1124, 177,
+ 977, 977, 977, 977, 977, 1149, 1149, 1149,
+ 1149, 1149, 1149, 1149, 1149, 177, 177, 177,
12, 12, 12, 12, 12, 12, 12, 50,
- 12, 12, 12, 1095, 1096, 1097, 1097, 1097,
- 1098, 1098, 1099, 1099, 1099, 1099, 1100, 1101,
- 1101, 1102, 1103, 175, 175, 175, 175, 175,
-
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 151, 151, 156, 156, 151, 151, 151, 151,
- 156, 156, 156, 151, 151, 1104, 1104, 1104,
-
- 1104, 151, 1105, 1105, 1106, 1107, 1107, 171,
- 1108, 171, 1107, 1109, 926, 926, 926, 926,
- 927, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 51, 51, 1110, 1111, 51, 51, 51, 1110,
- 51, 1111, 71, 1110, 1110, 1110, 71, 71,
- 1110, 1110, 1110, 71, 51, 1110, 1112, 51,
- 36, 1110, 1110, 1110, 1110, 1110, 51, 51,
-
- 51, 51, 51, 51, 1110, 51, 1113, 51,
- 1110, 51, 1114, 1115, 1110, 1110, 1116, 71,
- 1110, 1110, 1117, 1110, 71, 93, 93, 93,
- 93, 141, 1118, 811, 106, 1119, 1120, 1120,
-
- 1074, 1074, 1074, 1074, 1074, 1120, 1119, 1119,
- 1119, 1119, 1121, 1074, 752, 1122, 1123, 1124,
- 1125, 1125, 1125, 64, 64, 64, 64, 64,
+ 12, 12, 12, 1150, 1151, 1152, 1152, 1152,
+ 1153, 1153, 1154, 1154, 1154, 1154, 1155, 1156,
+ 1156, 1157, 1158, 177, 177, 177, 177, 177,
+
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 153, 153, 158, 158, 153, 153, 153, 153,
+ 158, 158, 158, 153, 153, 1159, 1159, 1159,
+
+ 1159, 153, 1160, 1160, 1161, 1162, 1162, 173,
+ 1163, 173, 1162, 1164, 980, 980, 980, 980,
+ 981, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 51, 51, 1165, 1166, 51, 51, 51, 1165,
+ 51, 1166, 1167, 1165, 1165, 1165, 1167, 1167,
+ 1165, 1165, 1165, 1167, 51, 1165, 1168, 51,
+ 36, 1165, 1165, 1165, 1165, 1165, 51, 51,
+
+ 51, 51, 51, 51, 1165, 51, 1169, 51,
+ 1165, 51, 1170, 1171, 1165, 1165, 1172, 1167,
+ 1165, 1165, 1173, 1165, 1167, 1174, 1174, 1174,
+ 1174, 1175, 1176, 1177, 1178, 1179, 1180, 1180,
+
+ 1129, 1129, 1129, 1129, 1129, 1180, 1179, 1179,
+ 1179, 1179, 1181, 1129, 1182, 1183, 1184, 1185,
+ 1186, 1186, 1186, 64, 64, 64, 64, 64,
64, 64, 64, 64, 64, 64, 64, 64,
- 1126, 1126, 1126, 1126, 1126, 1126, 1126, 1126,
- 1126, 1126, 1126, 1126, 1126, 1126, 1126, 1126,
- 1127, 1127, 1127, 1127, 1127, 1127, 1127, 1127,
- 1127, 1127, 1127, 1127, 1127, 1127, 1127, 1127,
+ 1187, 1187, 1187, 1187, 1187, 1187, 1187, 1187,
+ 1187, 1187, 1187, 1187, 1187, 1187, 1187, 1187,
+ 1188, 1188, 1188, 1188, 1188, 1188, 1188, 1188,
+ 1188, 1188, 1188, 1188, 1188, 1188, 1188, 1188,
- 1128, 1128, 1128, 102, 113, 1129, 1129, 1129,
- 1129, 1125, 175, 175, 175, 175, 175, 175,
+ 1189, 1189, 1189, 102, 113, 1190, 1190, 1190,
+ 1190, 1186, 177, 177, 177, 177, 177, 177,
36, 36, 36, 36, 36, 51, 51, 51,
51, 51, 36, 36, 51, 51, 51, 51,
@@ -2020,134 +2035,134 @@ static const unsigned short uc_property_trie[] = {
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
- 51, 51, 51, 1118, 1118, 1118, 1118, 1118,
- 1118, 1118, 1118, 1118, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
+ 51, 51, 51, 1176, 1176, 1176, 1176, 1176,
+ 1176, 1176, 1176, 1176, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
36, 36, 36, 36, 36, 36, 36, 36,
- 1130, 1130, 1130, 1131, 1131, 1131, 36, 36,
- 36, 36, 18, 56, 36, 1132, 36, 36,
+ 1191, 1191, 1191, 1192, 1192, 1192, 36, 36,
+ 36, 36, 18, 56, 36, 1193, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36,
- 36, 36, 36, 36, 1133, 1134, 36, 36,
+ 36, 36, 36, 36, 1194, 1195, 36, 36,
- 36, 36, 36, 1135, 36, 36, 36, 36,
+ 36, 36, 36, 1196, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36,
- 36, 36, 1133, 1134, 1133, 1134, 36, 36,
+ 36, 36, 1194, 1195, 1194, 1195, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36,
- 36, 36, 36, 36, 1133, 1134, 1133, 1134,
- 1133, 1134, 1133, 1134, 36, 36, 1133, 1134,
- 1133, 1134, 1133, 1134, 1133, 1134, 1133, 1134,
- 1133, 1134, 1133, 1134, 1133, 1134, 1133, 1134,
+ 36, 36, 36, 36, 1194, 1195, 1194, 1195,
+ 1194, 1195, 1194, 1195, 36, 36, 1194, 1195,
+ 1194, 1195, 1194, 1195, 1194, 1195, 1194, 1195,
+ 1194, 1195, 1194, 1195, 1194, 1195, 1194, 1195,
- 1133, 1134, 1133, 1134, 1133, 1134, 1133, 1134,
- 1133, 1134, 1133, 1134, 36, 36, 36, 1133,
- 1134, 1133, 1134, 36, 36, 36, 36, 36,
- 1136, 36, 36, 36, 36, 36, 36, 36,
+ 1194, 1195, 1194, 1195, 1194, 1195, 1194, 1195,
+ 1194, 1195, 1194, 1195, 36, 36, 36, 1194,
+ 1195, 1194, 1195, 36, 36, 36, 36, 36,
+ 1197, 36, 36, 36, 36, 36, 36, 36,
- 36, 36, 1133, 1134, 36, 36, 1137, 36,
- 1138, 1139, 36, 1139, 36, 36, 36, 36,
- 1133, 1134, 1133, 1134, 1133, 1134, 1133, 1134,
+ 36, 36, 1194, 1195, 36, 36, 1198, 36,
+ 1199, 1200, 36, 1200, 36, 36, 36, 36,
+ 1194, 1195, 1194, 1195, 1194, 1195, 1194, 1195,
36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36,
- 36, 1133, 1134, 1133, 1134, 1140, 36, 36,
- 1133, 1134, 36, 36, 36, 36, 1133, 1134,
- 1133, 1134, 1133, 1134, 1133, 1134, 1133, 1134,
+ 36, 1194, 1195, 1194, 1195, 1201, 36, 36,
+ 1194, 1195, 36, 36, 36, 36, 1194, 1195,
+ 1194, 1195, 1194, 1195, 1194, 1195, 1194, 1195,
- 1133, 1134, 1133, 1134, 1133, 1134, 1133, 1134,
- 1133, 1134, 1133, 1134, 1133, 1134, 36, 36,
- 1133, 1134, 1141, 1141, 1141, 1074, 1142, 1142,
- 1074, 1074, 1143, 1143, 1143, 1144, 1144, 1074,
+ 1194, 1195, 1194, 1195, 1194, 1195, 1194, 1195,
+ 1194, 1195, 1194, 1195, 1194, 1195, 36, 36,
+ 1194, 1195, 1202, 1202, 1202, 1129, 1203, 1203,
+ 1129, 1129, 1204, 1204, 1204, 1205, 1205, 1129,
- 51, 1118, 51, 51, 51, 51, 51, 51,
- 1133, 1134, 1133, 1134, 51, 51, 51, 51,
+ 51, 1176, 51, 51, 51, 51, 51, 51,
+ 1194, 1195, 1194, 1195, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
- 51, 51, 1145, 1145, 51, 51, 51, 51,
+ 51, 51, 1206, 1206, 51, 51, 51, 51,
36, 36, 51, 51, 51, 51, 51, 51,
- 51, 16, 1070, 51, 51, 51, 51, 51,
- 51, 51, 51, 51, 51, 51, 1146, 1146,
- 1146, 1146, 1146, 1146, 1146, 1146, 1146, 1146,
-
- 1146, 1146, 1146, 1146, 1146, 1146, 1146, 1146,
- 1146, 1146, 1146, 1146, 1146, 1146, 1146, 1146,
- 1146, 1146, 1146, 1146, 1146, 1146, 1146, 1146,
- 1146, 1146, 1146, 1146, 1146, 1146, 1146, 1146,
-
- 1146, 1146, 1146, 1146, 1146, 1146, 1146, 1146,
- 1146, 1146, 1146, 1146, 1146, 1146, 1146, 1146,
- 1146, 1146, 1146, 1146, 1146, 1146, 1146, 1146,
- 1146, 1146, 1146, 1118, 1074, 1118, 1118, 1118,
-
- 1118, 1118, 1118, 1118, 1118, 1118, 1118, 1118,
- 1118, 1118, 1118, 1118, 1118, 1118, 1118, 1118,
- 1118, 1118, 1118, 1118, 1118, 1147, 1118, 1118,
- 1118, 1118, 1118, 1074, 1074, 1074, 1074, 1074,
-
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1074, 1121, 1121, 1121, 1121,
- 1121, 1121, 1121, 1121, 1121, 1121, 1121, 1121,
-
- 1121, 1121, 1121, 1121, 1121, 1121, 1121, 1121,
- 1121, 1121, 1121, 1121, 1121, 1121, 1121, 811,
- 811, 752, 752, 752, 752, 752, 752, 752,
- 752, 752, 752, 752, 1148, 1148, 1148, 1148,
-
- 1148, 1148, 1122, 1122, 1122, 1122, 1122, 1122,
- 1149, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1151, 1151, 1151, 1151, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
+ 51, 16, 1124, 51, 51, 51, 51, 51,
+ 51, 51, 51, 51, 51, 51, 1207, 1207,
+ 1207, 1207, 1207, 1207, 1207, 1207, 1207, 1207,
+
+ 1207, 1207, 1207, 1207, 1207, 1207, 1207, 1207,
+ 1207, 1207, 1207, 1207, 1207, 1207, 1207, 1207,
+ 1207, 1207, 1207, 1207, 1207, 1207, 1207, 1207,
+ 1207, 1207, 1207, 1207, 1207, 1207, 1207, 1207,
+
+ 1207, 1207, 1207, 1207, 1207, 1207, 1207, 1207,
+ 1207, 1207, 1207, 1207, 1207, 1207, 1207, 1207,
+ 1207, 1207, 1207, 1207, 1207, 1207, 1207, 1207,
+ 1207, 1207, 1207, 1176, 1129, 1176, 1176, 1176,
+
+ 1176, 1176, 1176, 1176, 1176, 1176, 1176, 1176,
+ 1176, 1176, 1176, 1176, 1176, 1176, 1176, 1176,
+ 1176, 1176, 1176, 1176, 1176, 1208, 1176, 1176,
+ 1176, 1176, 1176, 1129, 1129, 1129, 1129, 1129,
+
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1181, 1181, 1181, 1181,
+ 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
+
+ 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
+ 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1177,
+ 1177, 1182, 1182, 1182, 1182, 1182, 1182, 1182,
+ 1182, 1182, 1182, 1182, 1209, 1209, 1209, 1209,
+
+ 1209, 1209, 1183, 1183, 1183, 1183, 1183, 1183,
+ 1210, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1212, 1212, 1212, 1212, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
- 51, 51, 51, 51, 51, 1118, 1118, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
+ 51, 51, 51, 51, 51, 1176, 1176, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
51, 51, 51, 51, 51, 51, 51, 51,
- 51, 51, 51, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
+ 51, 51, 51, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
- 1152, 1153, 1154, 1155, 1156, 1157, 1158, 1159,
- 1160, 64, 64, 64, 64, 64, 64, 64,
- 64, 64, 64, 64, 1152, 1153, 1154, 1155,
- 1156, 1157, 1158, 1159, 1160, 64, 64, 64,
+ 1213, 1214, 1215, 1216, 1217, 1218, 1219, 1220,
+ 1221, 64, 64, 64, 64, 64, 64, 64,
+ 64, 64, 64, 64, 1213, 1214, 1215, 1216,
+ 1217, 1218, 1219, 1220, 1221, 64, 64, 64,
64, 64, 64, 64, 64, 64, 64, 64,
- 62, 57, 58, 1087, 1088, 1089, 1090, 1091,
- 1092, 1161, 1161, 1161, 1161, 1161, 1161, 1161,
- 1161, 1161, 1161, 1161, 1146, 1146, 1146, 1146,
+ 62, 57, 58, 1142, 1143, 1144, 1145, 1146,
+ 1147, 1222, 1222, 1222, 1222, 1222, 1222, 1222,
+ 1222, 1222, 1222, 1222, 1207, 1207, 1207, 1207,
- 1146, 1146, 1146, 1146, 1146, 1146, 1146, 1146,
- 1146, 1146, 1146, 1146, 1146, 1146, 1146, 1146,
- 1146, 1146, 1146, 1146, 1146, 1146, 1162, 1162,
- 1162, 1162, 1162, 1162, 1162, 1162, 1162, 1162,
+ 1207, 1207, 1207, 1207, 1207, 1207, 1207, 1207,
+ 1207, 1207, 1207, 1207, 1207, 1207, 1207, 1207,
+ 1207, 1207, 1207, 1207, 1207, 1207, 1223, 1223,
+ 1223, 1223, 1223, 1223, 1223, 1223, 1223, 1223,
- 1162, 1162, 1162, 1162, 1162, 1162, 1162, 1162,
- 1162, 1162, 1162, 1162, 1162, 1162, 1162, 1162,
- 1163, 1163, 1163, 1163, 1163, 1163, 1163, 1163,
- 1163, 1163, 1163, 1163, 1163, 1163, 1163, 1163,
+ 1223, 1223, 1223, 1223, 1223, 1223, 1223, 1223,
+ 1223, 1223, 1223, 1223, 1223, 1223, 1223, 1223,
+ 1224, 1224, 1224, 1224, 1224, 1224, 1224, 1224,
+ 1224, 1224, 1224, 1224, 1224, 1224, 1224, 1224,
- 1163, 1163, 1163, 1163, 1163, 1163, 1163, 1163,
- 1163, 1163, 1164, 1165, 1165, 1165, 1165, 1165,
- 1165, 1165, 1165, 1165, 1165, 1166, 1167, 1168,
- 1169, 1170, 1171, 1172, 1173, 1174, 1165, 1175,
+ 1224, 1224, 1224, 1224, 1224, 1224, 1224, 1224,
+ 1224, 1224, 1225, 1226, 1226, 1226, 1226, 1226,
+ 1226, 1226, 1226, 1226, 1226, 1227, 1228, 1229,
+ 1230, 1231, 1232, 1233, 1234, 1235, 1226, 1236,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
- 51, 51, 51, 51, 51, 51, 1121, 1121,
- 1121, 1121, 1121, 1121, 1121, 1121, 1121, 1121,
+ 51, 51, 51, 51, 51, 51, 1181, 1181,
+ 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
@@ -2161,721 +2176,196 @@ static const unsigned short uc_property_trie[] = {
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
- 1118, 1118, 1118, 1118, 1118, 1118, 1118, 1118,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
+ 1176, 1176, 1176, 1176, 1176, 1176, 1176, 1176,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
- 1145, 1145, 1145, 1145, 51, 51, 51, 51,
+ 1206, 1206, 1206, 1206, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
- 51, 51, 51, 51, 1176, 1176, 1121, 1121,
- 1177, 1118, 1145, 1145, 1145, 1145, 1145, 1145,
+ 51, 51, 51, 51, 1237, 1237, 1181, 1181,
+ 1238, 1176, 1206, 1206, 1206, 1206, 1206, 1206,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
- 51, 1145, 1145, 1145, 51, 51, 51, 51,
+ 51, 1206, 1206, 1206, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
- 1145, 51, 51, 51, 51, 51, 51, 36,
- 1118, 1118, 1121, 1121, 1121, 1121, 1121, 1121,
- 1121, 1121, 1121, 1121, 1121, 1121, 752, 1177,
-
- 1121, 1121, 1121, 1121, 1121, 1121, 1121, 1121,
- 1121, 1121, 811, 811, 811, 811, 811, 811,
- 811, 811, 752, 752, 752, 752, 752, 752,
- 752, 752, 752, 752, 752, 1178, 1149, 1149,
-
- 811, 811, 752, 752, 752, 752, 752, 752,
- 752, 752, 752, 752, 1179, 752, 752, 752,
- 752, 752, 1122, 1178, 1178, 1178, 1178, 1178,
- 1178, 1178, 1178, 1178, 1178, 1180, 1180, 1180,
-
- 1181, 1181, 1181, 1181, 1180, 1180, 1180, 1180,
- 1180, 1149, 1149, 1149, 1149, 1180, 1150, 1180,
- 1180, 1180, 1149, 1180, 1180, 1149, 1149, 1149,
- 1180, 1180, 1149, 1149, 1180, 1149, 1149, 1180,
-
- 1180, 1180, 1150, 1149, 1150, 1150, 1150, 1150,
- 1149, 1149, 1180, 1149, 1149, 1149, 1149, 1149,
- 1149, 1180, 1180, 1180, 1180, 1180, 1149, 1180,
- 1180, 1180, 1180, 1149, 1149, 1180, 1180, 1180,
-
- 175, 1145, 1145, 1145, 1145, 1150, 51, 51,
- 1145, 1145, 1151, 1151, 1145, 1145, 51, 51,
+ 1206, 51, 51, 51, 51, 51, 51, 36,
+ 1176, 1176, 1181, 1181, 1181, 1181, 1181, 1181,
+ 1181, 1181, 1181, 1181, 1181, 1181, 1182, 1238,
+
+ 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
+ 1181, 1181, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1182, 1182, 1182, 1182, 1182, 1182,
+ 1182, 1182, 1182, 1182, 1182, 1239, 1210, 1210,
+
+ 1177, 1177, 1182, 1182, 1182, 1182, 1182, 1182,
+ 1182, 1182, 1182, 1182, 1240, 1182, 1182, 1182,
+ 1182, 1182, 1183, 1239, 1239, 1239, 1239, 1239,
+ 1239, 1239, 1239, 1239, 1239, 1241, 1241, 1241,
+
+ 1242, 1242, 1242, 1242, 1241, 1241, 1241, 1241,
+ 1241, 1210, 1210, 1210, 1210, 1241, 1211, 1241,
+ 1241, 1241, 1210, 1241, 1241, 1210, 1210, 1210,
+ 1241, 1241, 1210, 1210, 1241, 1210, 1210, 1241,
+
+ 1241, 1241, 1211, 1210, 1211, 1211, 1211, 1211,
+ 1210, 1210, 1241, 1210, 1210, 1210, 1210, 1210,
+ 1210, 1241, 1241, 1241, 1241, 1241, 1210, 1241,
+ 1241, 1241, 1241, 1210, 1210, 1241, 1241, 1241,
+
+ 177, 1206, 1206, 1206, 1206, 1211, 51, 51,
+ 1206, 1206, 1212, 1212, 1206, 1206, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
- 1150, 51, 51, 51, 51, 51, 51, 51,
+ 1211, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
- 51, 51, 51, 51, 1150, 51, 1150, 51,
- 51, 51, 51, 1150, 1150, 1150, 51, 1149,
- 51, 51, 51, 1182, 1182, 1182, 1182, 1150,
-
- 1150, 51, 1183, 1183, 51, 51, 51, 51,
- 1184, 1185, 1184, 1185, 1184, 1185, 1184, 1185,
- 1184, 1185, 1184, 1185, 1184, 1185, 1152, 1153,
- 1154, 1155, 1156, 1157, 1158, 1159, 1160, 64,
-
- 1152, 1153, 1154, 1155, 1156, 1157, 1158, 1159,
- 1160, 64, 1152, 1153, 1154, 1155, 1156, 1157,
- 1158, 1159, 1160, 64, 51, 1150, 1150, 1150,
+ 51, 51, 51, 51, 1211, 51, 1211, 51,
+ 51, 51, 51, 1211, 1211, 1211, 51, 1210,
+ 51, 51, 51, 1243, 1243, 1243, 1243, 1211,
+
+ 1211, 51, 1244, 1244, 51, 51, 51, 51,
+ 1245, 1246, 1245, 1246, 1245, 1246, 1245, 1246,
+ 1245, 1246, 1245, 1246, 1245, 1246, 1213, 1214,
+ 1215, 1216, 1217, 1218, 1219, 1220, 1221, 64,
+
+ 1213, 1214, 1215, 1216, 1217, 1218, 1219, 1220,
+ 1221, 64, 1213, 1214, 1215, 1216, 1217, 1218,
+ 1219, 1220, 1221, 64, 51, 1211, 1211, 1211,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
51, 51, 51, 51, 51, 51, 51, 51,
- 1150, 51, 51, 51, 51, 51, 51, 51,
- 51, 51, 51, 51, 51, 51, 51, 1150,
-
- 1186, 1186, 1186, 1187, 1188, 1189, 1190, 1148,
- 1191, 1192, 1148, 1193, 1194, 1195, 1196, 1196,
- 1074, 1074, 1074, 1074, 1074, 1197, 1198, 1074,
- 1074, 1074, 1074, 1074, 1074, 1197, 1198, 1074,
-
- 1074, 1074, 1197, 1198, 1197, 1198, 1184, 1185,
- 1184, 1185, 1184, 1185, 1199, 1200, 1199, 1200,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
-
- 1147, 1147, 1147, 1147, 1147, 1147, 1147, 1147,
- 1147, 1147, 1147, 1147, 1147, 1147, 1147, 1147,
- 1147, 1147, 1147, 1147, 1147, 1147, 1147, 1147,
- 1147, 1147, 1147, 1147, 1147, 1147, 1147, 1147,
-
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
-
- 1074, 1074, 1074, 1184, 1185, 1184, 1185, 1184,
- 1185, 1184, 1185, 1184, 1185, 1201, 1202, 1203,
- 1204, 1184, 1185, 1184, 1185, 1184, 1185, 1184,
- 1185, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
-
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1205, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
-
- 1197, 1198, 1074, 1074, 1197, 1198, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1197,
- 1198, 1197, 1198, 1074, 1197, 1198, 1074, 1074,
- 1184, 1185, 1184, 1185, 1074, 1074, 1074, 1074,
-
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1206, 1074, 1074,
- 1197, 1198, 1074, 1074, 1184, 1185, 1074, 1074,
-
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1197, 1198, 1197, 1198, 1074,
- 1074, 1074, 1074, 1074, 1197, 1198, 1074, 1074,
- 1074, 1074, 1074, 1074, 1197, 1198, 1074, 1074,
-
- 1074, 1074, 1074, 1074, 1197, 1198, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1074,
- 1074, 1197, 1198, 1074, 1074, 1197, 1198, 1197,
-
- 1198, 1197, 1198, 1197, 1198, 1074, 1074, 1074,
- 1074, 1074, 1074, 1197, 1198, 1074, 1074, 1074,
- 1074, 1197, 1198, 1197, 1198, 1197, 1198, 1197,
- 1198, 1197, 1198, 1197, 1198, 1074, 1074, 1074,
-
- 1074, 1197, 1198, 1074, 1074, 1074, 1197, 1198,
- 1197, 1198, 1197, 1198, 1197, 1198, 1074, 1197,
- 1198, 1074, 1074, 1197, 1198, 1074, 1074, 1074,
- 1074, 1074, 1074, 1197, 1198, 1197, 1198, 1197,
-
- 1198, 1197, 1198, 1197, 1198, 1197, 1198, 1074,
- 1074, 1074, 1074, 1074, 1074, 1197, 1198, 1197,
- 1198, 1197, 1198, 1197, 1198, 1197, 1198, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1207, 1074,
-
- 1074, 1074, 1074, 1208, 1209, 1208, 1074, 1074,
- 1074, 1074, 1074, 1074, 1197, 1198, 1074, 1074,
- 1074, 1074, 1074, 1074, 1074, 1074, 1074, 1197,
- 1198, 1197, 1198, 1074, 1074, 1074, 1074, 1074,
-
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 752, 752,
- 752, 752, 752, 752, 1122, 1122, 1122, 1122,
- 1122, 1122, 1122, 1178, 1178, 1178, 1178, 1178,
-
- 1122, 1122, 1122, 1122, 1178, 1178, 1178, 1178,
- 1178, 1178, 1178, 1178, 1178, 1178, 1178, 1178,
- 1194, 1194, 1194, 1194, 1194, 1194, 1194, 1194,
- 1194, 1194, 1194, 1194, 1194, 1194, 1194, 1194,
-
- 1194, 1194, 1194, 1194, 1194, 1178, 1178, 1194,
- 1194, 1194, 1194, 1194, 1194, 175, 175, 175,
- 1178, 1178, 1178, 1178, 1178, 1149, 1149, 1149,
- 1149, 1149, 175, 175, 175, 175, 175, 175,
-
- 1210, 1210, 1210, 1210, 1210, 1210, 1210, 1210,
- 1210, 1210, 1210, 1210, 1210, 1210, 1210, 1210,
- 1210, 1210, 1210, 1210, 1210, 1210, 1210, 1210,
- 1210, 1210, 1210, 1210, 1210, 1210, 1210, 1210,
-
- 1210, 1210, 1210, 1210, 1210, 1210, 1210, 1210,
- 1210, 1210, 1210, 1210, 1210, 1210, 1210, 175,
- 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
- 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 51, 51, 51, 51, 51, 51, 51,
+ 51, 51, 51, 51, 51, 51, 51, 1211,
+
+ 1247, 1247, 1247, 1248, 1249, 1250, 1251, 1209,
+ 1252, 1253, 1209, 1254, 1255, 1256, 1257, 1257,
+ 1129, 1129, 1129, 1129, 1129, 1258, 1259, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1258, 1259, 1129,
+
+ 1129, 1129, 1258, 1259, 1258, 1259, 1245, 1246,
+ 1245, 1246, 1245, 1246, 1260, 1261, 1260, 1261,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+
+ 1262, 1262, 1262, 1262, 1262, 1262, 1262, 1262,
+ 1262, 1262, 1262, 1262, 1262, 1262, 1262, 1262,
+ 1262, 1262, 1262, 1262, 1262, 1262, 1262, 1262,
+ 1262, 1262, 1262, 1262, 1262, 1262, 1262, 1262,
+
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+
+ 1129, 1129, 1129, 1245, 1246, 1245, 1246, 1245,
+ 1246, 1245, 1246, 1245, 1246, 1263, 1264, 1265,
+ 1266, 1245, 1246, 1245, 1246, 1245, 1246, 1245,
+ 1246, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1267, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+
+ 1258, 1259, 1129, 1129, 1258, 1259, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1258,
+ 1259, 1258, 1259, 1129, 1258, 1259, 1129, 1129,
+ 1245, 1246, 1245, 1246, 1129, 1129, 1129, 1129,
+
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1268, 1129, 1129,
+ 1258, 1259, 1129, 1129, 1245, 1246, 1129, 1129,
+
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1258, 1259, 1258, 1259, 1129,
+ 1129, 1129, 1129, 1129, 1258, 1259, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1258, 1259, 1129, 1129,
+
+ 1129, 1129, 1129, 1129, 1258, 1259, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1129,
+ 1129, 1258, 1259, 1129, 1129, 1258, 1259, 1258,
+
+ 1259, 1258, 1259, 1258, 1259, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1258, 1259, 1129, 1129, 1129,
+ 1129, 1258, 1259, 1258, 1259, 1258, 1259, 1258,
+ 1259, 1258, 1259, 1258, 1259, 1129, 1129, 1129,
+
+ 1129, 1258, 1259, 1129, 1129, 1129, 1258, 1259,
+ 1258, 1259, 1258, 1259, 1258, 1259, 1129, 1258,
+ 1259, 1129, 1129, 1258, 1259, 1129, 1129, 1129,
+ 1129, 1129, 1129, 1258, 1259, 1258, 1259, 1258,
+
+ 1259, 1258, 1259, 1258, 1259, 1258, 1259, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1258, 1259, 1258,
+ 1259, 1258, 1259, 1258, 1259, 1258, 1259, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1269, 1129,
+
+ 1129, 1129, 1129, 1270, 1271, 1270, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1258, 1259, 1129, 1129,
+ 1129, 1129, 1129, 1129, 1129, 1129, 1129, 1258,
+ 1259, 1258, 1259, 1129, 1129, 1129, 1129, 1129,
- 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
- 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
- 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
- 1211, 1211, 1211, 1211, 1211, 1211, 1211, 175,
-
- 117, 113, 1212, 1213, 1214, 1215, 1216, 117,
- 113, 117, 113, 117, 113, 1217, 1218, 1219,
- 1220, 939, 941, 942, 1221, 117, 113, 1221,
- 939, 939, 939, 939, 1222, 1222, 1223, 1223,
-
- 108, 109, 108, 109, 108, 109, 108, 109,
- 108, 109, 108, 109, 108, 109, 108, 109,
- 108, 109, 108, 109, 108, 109, 108, 109,
- 108, 109, 108, 109, 108, 109, 108, 109,
-
- 108, 109, 108, 109, 106, 752, 752, 752,
- 752, 752, 752, 1224, 1225, 1224, 1225, 390,
- 390, 390, 1226, 1227, 175, 175, 175, 175,
- 175, 1228, 1078, 1078, 1078, 1229, 1228, 1078,
-
- 1230, 1230, 1230, 1230, 1230, 1230, 1230, 1230,
- 1230, 1230, 1230, 1230, 1230, 1230, 1230, 1230,
- 1230, 1230, 1230, 1230, 1230, 1230, 1230, 1230,
- 1230, 1230, 1230, 1230, 1230, 1230, 1230, 1230,
-
- 1230, 1230, 1230, 1230, 1230, 1230, 175, 1231,
- 175, 175, 175, 175, 175, 1231, 175, 175,
- 735, 735, 735, 735, 735, 735, 735, 735,
- 735, 735, 735, 735, 735, 735, 735, 735,
-
- 735, 735, 735, 735, 735, 735, 735, 735,
- 735, 735, 735, 735, 735, 735, 735, 735,
- 735, 735, 735, 735, 735, 735, 735, 735,
- 735, 735, 735, 735, 735, 735, 735, 735,
-
- 735, 735, 735, 735, 735, 735, 898, 898,
- 175, 175, 175, 175, 175, 175, 175, 1232,
- 1233, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 1234,
-
- 735, 735, 735, 735, 735, 735, 735, 735,
- 735, 735, 735, 735, 735, 735, 735, 735,
- 735, 735, 735, 735, 735, 735, 735, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 735, 735, 735, 735, 735, 735, 735, 175,
- 735, 735, 735, 735, 735, 735, 735, 175,
- 735, 735, 735, 735, 735, 735, 735, 175,
- 735, 735, 735, 735, 735, 735, 735, 175,
-
- 224, 224, 224, 224, 224, 224, 224, 224,
- 224, 224, 224, 224, 224, 224, 224, 224,
- 224, 224, 224, 224, 224, 224, 224, 224,
- 224, 224, 224, 224, 224, 224, 224, 224,
-
- 1235, 1235, 1236, 1237, 1236, 1237, 1235, 1235,
- 1235, 1236, 1237, 1235, 1236, 1237, 1078, 1078,
- 1078, 1078, 1078, 1078, 1078, 1078, 1077, 1238,
- 1239, 1240, 1241, 1242, 1236, 1237, 1242, 1242,
-
- 1243, 1244, 1199, 1200, 1199, 1200, 1199, 1200,
- 1199, 1200, 1240, 1240, 1240, 1240, 1245, 1246,
- 1240, 1247, 1248, 1249, 1249, 1248, 1248, 1248,
- 1248, 1248, 1250, 1250, 175, 175, 175, 175,
-
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 175, 1251, 1251, 1251, 1251, 1251,
-
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
-
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 1251, 1251, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 175, 175, 175, 175,
-
- 1252, 1253, 1254, 1255, 1145, 1256, 1257, 1258,
- 16, 1070, 16, 1070, 16, 1070, 16, 1070,
- 16, 1070, 1145, 1145, 16, 1070, 16, 1070,
- 16, 1070, 16, 1070, 1259, 1051, 1260, 1260,
-
- 1145, 1258, 1258, 1258, 1258, 1258, 1258, 1258,
- 1258, 1258, 1261, 1262, 152, 1263, 1264, 1264,
- 1265, 1266, 1266, 1266, 1266, 1266, 1145, 1145,
- 1267, 1267, 1267, 1268, 1269, 1270, 1251, 1145,
-
- 175, 1271, 1257, 1271, 1257, 1271, 1257, 1271,
- 1257, 1271, 1257, 1257, 1257, 1257, 1257, 1257,
- 1257, 1257, 1257, 1257, 1257, 1257, 1257, 1257,
- 1257, 1257, 1257, 1257, 1257, 1257, 1257, 1257,
-
- 1257, 1257, 1257, 1271, 1257, 1257, 1257, 1257,
- 1257, 1257, 1257, 1257, 1257, 1257, 1257, 1257,
- 1257, 1257, 1257, 1257, 1257, 1257, 1257, 1257,
- 1257, 1257, 1257, 1257, 1257, 1257, 1257, 1257,
-
- 1257, 1257, 1257, 1271, 1257, 1271, 1257, 1271,
- 1257, 1257, 1257, 1257, 1257, 1257, 1271, 1257,
- 1257, 1257, 1257, 1257, 1257, 1272, 1272, 175,
- 175, 1273, 1273, 1274, 1274, 1275, 1275, 1276,
-
- 1277, 1278, 1279, 1278, 1279, 1278, 1279, 1278,
- 1279, 1278, 1279, 1279, 1279, 1279, 1279, 1279,
- 1279, 1279, 1279, 1279, 1279, 1279, 1279, 1279,
- 1279, 1279, 1279, 1279, 1279, 1279, 1279, 1279,
-
- 1279, 1279, 1279, 1278, 1279, 1279, 1279, 1279,
- 1279, 1279, 1279, 1279, 1279, 1279, 1279, 1279,
- 1279, 1279, 1279, 1279, 1279, 1279, 1279, 1279,
- 1279, 1279, 1279, 1279, 1279, 1279, 1279, 1279,
-
- 1279, 1279, 1279, 1278, 1279, 1278, 1279, 1278,
- 1279, 1279, 1279, 1279, 1279, 1279, 1278, 1279,
- 1279, 1279, 1279, 1279, 1279, 1278, 1278, 1279,
- 1279, 1279, 1279, 1280, 1281, 1281, 1281, 1282,
-
- 175, 175, 175, 175, 175, 1283, 1283, 1283,
- 1283, 1283, 1283, 1283, 1283, 1283, 1283, 1283,
- 1283, 1283, 1283, 1283, 1283, 1283, 1283, 1283,
- 1283, 1283, 1283, 1283, 1283, 1283, 1283, 1283,
-
- 1283, 1283, 1283, 1283, 1283, 1283, 1283, 1283,
- 1283, 1283, 1283, 1283, 1283, 1284, 175, 175,
- 175, 1285, 1285, 1285, 1285, 1285, 1285, 1285,
- 1285, 1285, 1285, 1285, 1285, 1285, 1285, 1285,
-
- 1285, 1285, 1285, 1285, 1285, 1285, 1285, 1285,
- 1285, 1285, 1285, 1285, 1285, 1285, 1285, 1285,
- 1285, 1285, 1285, 1285, 1285, 1285, 1285, 1285,
- 1285, 1285, 1285, 1285, 1285, 1285, 1285, 1285,
-
- 1285, 1285, 1285, 1285, 1285, 1285, 1285, 1285,
- 1285, 1285, 1285, 1285, 1285, 1285, 1285, 175,
- 1286, 1286, 1287, 1287, 1287, 1287, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
-
- 1288, 1288, 1288, 1288, 1288, 1288, 1288, 1288,
- 1288, 1288, 1288, 1288, 1288, 1288, 1288, 1288,
- 1288, 1288, 1288, 1288, 1288, 1288, 1288, 1288,
- 1289, 1289, 1289, 175, 175, 175, 175, 175,
-
- 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1182, 1182,
+ 1182, 1182, 1182, 1182, 1183, 1183, 1183, 1183,
+ 1183, 1183, 1183, 1239, 1239, 1239, 1239, 1239,
+
+ 1183, 1183, 1183, 1183, 1239, 1239, 1239, 1239,
+ 1239, 1239, 1239, 1239, 1239, 1239, 1239, 1239,
+ 1255, 1255, 1255, 1255, 1255, 1255, 1255, 1255,
+ 1255, 1255, 1255, 1255, 1255, 1255, 1255, 1255,
+
+ 1255, 1255, 1255, 1255, 1255, 1239, 1239, 1255,
+ 1255, 1255, 1255, 1255, 1255, 177, 177, 177,
+ 1239, 1239, 1239, 1239, 1239, 1210, 1210, 1210,
+ 1210, 1210, 177, 177, 177, 177, 177, 177,
+
+ 1272, 1272, 1272, 1272, 1272, 1272, 1272, 1272,
+ 1272, 1272, 1272, 1272, 1272, 1272, 1272, 1272,
+ 1272, 1272, 1272, 1272, 1272, 1272, 1272, 1272,
+ 1272, 1272, 1272, 1272, 1272, 1272, 1272, 1272,
+
+ 1272, 1272, 1272, 1272, 1272, 1272, 1272, 1272,
+ 1272, 1272, 1272, 1272, 1272, 1272, 1272, 177,
+ 1273, 1273, 1273, 1273, 1273, 1273, 1273, 1273,
+ 1273, 1273, 1273, 1273, 1273, 1273, 1273, 1273,
+
+ 1273, 1273, 1273, 1273, 1273, 1273, 1273, 1273,
+ 1273, 1273, 1273, 1273, 1273, 1273, 1273, 1273,
+ 1273, 1273, 1273, 1273, 1273, 1273, 1273, 1273,
+ 1273, 1273, 1273, 1273, 1273, 1273, 1273, 177,
+
+ 117, 113, 1274, 1275, 1276, 1277, 1278, 117,
+ 113, 117, 113, 117, 113, 1279, 1280, 1281,
+ 1282, 993, 995, 996, 1283, 117, 113, 1283,
+ 993, 993, 993, 993, 1284, 1284, 1285, 1285,
+
+ 1286, 1287, 1286, 1287, 1286, 1287, 1286, 1287,
+ 1286, 1287, 1286, 1287, 1286, 1287, 1286, 1287,
+ 1286, 1287, 1286, 1287, 1286, 1287, 1286, 1287,
+ 1286, 1287, 1286, 1287, 1286, 1287, 1286, 1287,
+
+ 1286, 1287, 1286, 1287, 1288, 1289, 1289, 1289,
+ 1289, 1289, 1289, 1290, 1291, 1290, 1291, 1292,
+ 1292, 1292, 1293, 1294, 177, 177, 177, 177,
+ 177, 1295, 1296, 1296, 1296, 1297, 1295, 1296,
- 1181, 1181, 1181, 1181, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1290, 1290, 1290, 1290, 1290, 1290, 1290, 1290,
- 1290, 1290, 1290, 1290, 1290, 1290, 1290, 1290,
-
- 1291, 1291, 1291, 1291, 1291, 1291, 1291, 1291,
- 1291, 1291, 1291, 1291, 1291, 1291, 1291, 1291,
- 1291, 1291, 1291, 1291, 1291, 1291, 1291, 1291,
- 1291, 1291, 1291, 1291, 1291, 1292, 1292, 175,
-
- 1287, 1287, 1287, 1287, 1287, 1287, 1287, 1287,
- 1287, 1287, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
-
- 1286, 1286, 1286, 1286, 1293, 1293, 1293, 1293,
- 1294, 1294, 1294, 1294, 1294, 1294, 1294, 1294,
- 1176, 1295, 1295, 1295, 1295, 1295, 1295, 1295,
- 1295, 1295, 1295, 1295, 1295, 1295, 1295, 1295,
-
- 1291, 1291, 1291, 1291, 1291, 1291, 1291, 1291,
- 1291, 1291, 1291, 1291, 1291, 1291, 1291, 1291,
- 1291, 1291, 1291, 1291, 1291, 1291, 1291, 1291,
- 1291, 1291, 1291, 1291, 1292, 1292, 1296, 1286,
-
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1295, 1295, 1295, 1295, 1295, 1295, 1295,
- 1295, 1295, 1295, 1295, 1295, 1295, 1295, 1295,
-
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1176, 1176, 1176, 1176,
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 1297,
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 1297,
-
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 1297,
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 1297,
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 1297,
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 175,
-
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 1297,
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 1297,
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 1297,
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 1297,
-
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 1297,
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 1297,
- 1297, 1297, 1297, 1297, 1297, 1297, 1297, 1297,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
-
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1176,
- 1176, 1176, 1176, 1286, 1286, 1286, 1286, 1286,
-
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
-
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1176, 1176,
-
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1286,
- 1286, 1286, 1286, 1286, 1286, 1286, 1286, 1176,
-
- 1298, 1298, 1298, 1298, 1298, 1298, 1298, 1298,
1298, 1298, 1298, 1298, 1298, 1298, 1298, 1298,
1298, 1298, 1298, 1298, 1298, 1298, 1298, 1298,
1298, 1298, 1298, 1298, 1298, 1298, 1298, 1298,
-
1298, 1298, 1298, 1298, 1298, 1298, 1298, 1298,
- 1298, 1298, 1298, 1298, 1298, 1298, 1298, 1298,
- 1298, 1298, 1298, 1298, 1298, 1298, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
-
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 811,
-
- 1257, 1257, 1257, 1257, 1257, 1257, 1257, 1257,
- 1257, 1257, 1257, 1257, 1257, 1257, 1257, 1257,
- 1257, 1257, 1257, 1257, 1257, 1257, 1257, 1257,
- 1257, 1257, 1257, 1257, 1257, 1257, 1257, 1257,
-
- 1257, 1257, 1257, 1257, 1257, 1257, 1300, 1300,
- 1300, 1300, 1300, 1300, 1300, 1300, 1300, 1300,
- 1300, 1300, 1300, 1300, 1300, 1300, 1300, 1300,
- 1300, 1300, 1300, 1300, 1301, 1301, 1301, 1301,
-
- 1301, 1301, 1301, 1301, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1303, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
-
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
-
- 1288, 1288, 1288, 1288, 1288, 1288, 1288, 1288,
- 1288, 1288, 1288, 1288, 1288, 1288, 1288, 1288,
- 1288, 1288, 1288, 1288, 1288, 1304, 1288, 1288,
- 1288, 1288, 1288, 1288, 1288, 1288, 1288, 1288,
-
- 1288, 1288, 1288, 1288, 1288, 1288, 1288, 1288,
- 1288, 1288, 1288, 1288, 1288, 1288, 1288, 1288,
- 1288, 1288, 1288, 1288, 1288, 1288, 1288, 1288,
- 1288, 1288, 1288, 1288, 1288, 1288, 1288, 1288,
-
- 1288, 1288, 1288, 1288, 1288, 1288, 1288, 1288,
- 1288, 1288, 1288, 1288, 1288, 175, 175, 175,
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
-
- 1251, 1251, 1305, 1305, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 1305, 1251, 1251, 1251,
- 1251, 1251, 1251, 1251, 1251, 1251, 1251, 1251,
-
- 1251, 1305, 1251, 1251, 1251, 1305, 1251, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
-
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 1306, 1306, 1306, 1306, 1306, 1306, 1307, 1308,
-
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 908, 1240, 1245, 1309,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
-
- 888, 889, 890, 891, 892, 893, 894, 895,
- 896, 897, 804, 804, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 236, 237, 236, 237, 236, 237, 236, 237,
- 236, 237, 236, 237, 236, 237, 236, 237,
- 236, 237, 236, 237, 236, 237, 236, 237,
- 236, 237, 236, 237, 236, 237, 236, 237,
-
- 240, 241, 236, 237, 236, 237, 236, 237,
- 236, 237, 236, 237, 236, 237, 1310, 224,
- 1311, 1311, 1311, 1312, 1313, 1313, 1313, 1313,
- 1313, 1313, 1313, 1313, 224, 224, 1312, 1314,
-
- 236, 237, 236, 237, 236, 237, 236, 237,
- 236, 237, 236, 237, 236, 237, 236, 237,
- 236, 237, 236, 237, 236, 237, 236, 237,
- 175, 175, 175, 175, 175, 175, 175, 1313,
-
- 754, 754, 754, 754, 754, 754, 1315, 1315,
- 1315, 1315, 1315, 1315, 1315, 1315, 1315, 1315,
- 390, 390, 911, 1308, 1307, 1307, 1307, 1308,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1316, 1316, 1316, 1316, 1316, 1316, 1316, 1316,
- 1316, 1316, 1316, 1316, 1316, 1316, 1316, 1316,
- 1316, 1316, 1316, 1316, 1316, 1316, 1316, 1317,
- 1317, 1317, 1317, 1246, 1246, 1246, 1246, 1246,
-
- 1318, 1318, 941, 942, 941, 942, 941, 942,
- 941, 942, 941, 942, 941, 942, 941, 942,
- 939, 939, 941, 942, 941, 942, 941, 942,
- 941, 942, 941, 942, 941, 942, 941, 942,
-
- 941, 942, 941, 942, 941, 942, 941, 942,
- 941, 942, 941, 942, 941, 942, 941, 942,
- 941, 942, 941, 942, 941, 942, 941, 942,
- 941, 942, 941, 942, 941, 942, 941, 942,
-
- 941, 942, 941, 942, 941, 942, 941, 942,
- 941, 942, 941, 942, 941, 942, 941, 942,
- 1222, 939, 939, 939, 939, 939, 939, 939,
- 939, 941, 942, 941, 942, 1319, 941, 942,
-
- 941, 942, 941, 942, 941, 942, 941, 942,
- 1246, 1320, 1320, 941, 942, 1321, 1322, 175,
- 1323, 1324, 1226, 1227, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1323, 1324, 1323, 1324, 1323, 1324, 1323, 1324,
- 1323, 1324, 1325, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1326, 1326, 1322, 804, 804, 804, 804, 804,
-
- 735, 735, 1327, 735, 735, 735, 1328, 735,
- 735, 735, 735, 1327, 735, 735, 735, 735,
- 735, 735, 735, 735, 735, 735, 735, 735,
- 735, 735, 735, 735, 735, 735, 735, 735,
-
- 735, 735, 735, 842, 842, 1327, 1327, 842,
- 752, 752, 752, 752, 175, 175, 175, 175,
- 1294, 1294, 1294, 1294, 1294, 1294, 681, 681,
- 1100, 1329, 175, 175, 175, 175, 175, 175,
-
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
-
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 1330, 1330, 1331, 1331,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 884, 884, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
-
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 884, 884, 884, 884,
- 884, 884, 884, 884, 884, 884, 884, 884,
-
- 884, 884, 884, 884, 1332, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 906, 906,
- 888, 889, 890, 891, 892, 893, 894, 895,
- 896, 897, 175, 175, 175, 175, 175, 175,
-
- 1333, 1333, 1333, 1333, 1333, 1333, 1333, 1333,
- 1333, 1333, 1333, 1333, 1333, 1333, 1333, 1333,
- 1333, 1333, 431, 431, 431, 431, 431, 431,
- 1334, 1334, 1334, 431, 175, 175, 175, 175,
-
- 888, 889, 890, 891, 892, 893, 894, 895,
- 896, 897, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
-
- 804, 804, 804, 804, 804, 804, 883, 883,
- 883, 883, 883, 1335, 1335, 1335, 907, 906,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
-
- 804, 804, 804, 804, 804, 804, 804, 883,
- 883, 883, 883, 883, 883, 883, 883, 883,
- 883, 883, 884, 885, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 1336,
-
- 729, 729, 729, 729, 729, 729, 729, 729,
- 729, 729, 729, 729, 729, 729, 729, 729,
- 729, 729, 729, 729, 729, 729, 729, 729,
- 729, 729, 729, 729, 729, 175, 175, 175,
-
- 1337, 1337, 1337, 914, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
-
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 1338, 914, 914, 1337, 1337,
- 1337, 1337, 914, 914, 1337, 914, 914, 914,
-
- 1339, 911, 911, 911, 911, 911, 911, 1307,
- 1308, 1308, 911, 911, 911, 911, 175, 1306,
- 849, 850, 851, 852, 853, 854, 855, 856,
- 857, 858, 175, 175, 175, 175, 911, 911,
-
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 883, 883, 883, 883, 883, 883, 884,
- 884, 883, 883, 884, 884, 883, 883, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 804, 804, 804, 883, 804, 804, 804, 804,
- 804, 804, 804, 804, 883, 884, 175, 175,
- 888, 889, 890, 891, 892, 893, 894, 895,
- 896, 897, 175, 175, 1336, 906, 906, 906,
-
- 1340, 1340, 1340, 1340, 1340, 1340, 1340, 1340,
- 1340, 1340, 1340, 1340, 1340, 1340, 1340, 1340,
- 1341, 1340, 1340, 1340, 1340, 1340, 1340, 1342,
- 1342, 1342, 1340, 717, 175, 175, 175, 175,
-
- 825, 825, 825, 825, 825, 825, 825, 825,
- 825, 825, 825, 825, 825, 825, 825, 825,
- 847, 825, 847, 847, 1343, 825, 825, 847,
- 847, 825, 825, 825, 825, 825, 847, 847,
-
- 825, 847, 825, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 825, 825, 860, 859, 859,
-
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 887, 1344, 1344, 887, 887,
- 1345, 1345, 898, 1346, 1346, 887, 886, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 899, 899, 899, 899, 899, 899, 175,
- 175, 899, 899, 899, 899, 899, 899, 175,
- 175, 899, 899, 899, 899, 899, 899, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 899, 899, 899, 899, 899, 899, 899, 175,
- 899, 899, 899, 899, 899, 899, 899, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 754, 754, 754, 914, 914, 1337, 914, 914,
- 1337, 914, 914, 1308, 914, 1347, 175, 175,
- 849, 850, 851, 852, 853, 854, 855, 856,
- 857, 858, 175, 175, 175, 175, 175, 175,
-
- 1348, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1348, 1349, 1349, 1349,
-
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1348, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
-
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1348, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
-
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1348, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
-
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1348, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
-
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1348, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
-
- 1349, 1349, 1349, 1349, 1348, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
- 1349, 1349, 1349, 1349, 1349, 1349, 1349, 1349,
-
- 1349, 1349, 1349, 1349, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 731, 731, 731, 731, 731, 731, 731, 731,
- 731, 731, 731, 731, 731, 731, 731, 731,
-
- 731, 731, 731, 731, 731, 731, 731, 175,
- 175, 175, 175, 733, 733, 733, 733, 733,
- 733, 733, 733, 733, 733, 733, 733, 733,
- 733, 733, 733, 733, 733, 733, 733, 733,
-
- 733, 733, 733, 733, 733, 733, 733, 733,
- 733, 733, 733, 733, 733, 733, 733, 733,
- 733, 733, 733, 733, 733, 733, 733, 733,
- 733, 733, 733, 733, 175, 175, 175, 175,
- 1350, 1350, 1350, 1350, 1350, 1350, 1350, 1350,
- 1350, 1350, 1350, 1350, 1350, 1350, 1350, 1350,
- 1350, 1350, 1350, 1350, 1350, 1350, 1350, 1350,
- 1350, 1350, 1350, 1350, 1350, 1350, 1350, 1350,
-
- 1351, 1351, 1351, 1351, 1351, 1351, 1351, 1351,
- 1351, 1351, 1351, 1351, 1351, 1351, 1351, 1351,
- 1351, 1351, 1351, 1351, 1351, 1351, 1351, 1351,
- 1351, 1351, 1351, 1351, 1351, 1351, 1351, 1351,
-
- 1257, 1257, 1257, 1257, 1257, 1257, 1257, 1257,
- 1257, 1257, 1257, 1257, 1257, 1257, 1303, 1303,
- 1276, 1276, 1276, 1276, 1276, 1276, 1276, 1276,
- 1276, 1276, 1276, 1276, 1276, 1276, 1276, 1276,
-
- 1276, 1276, 1276, 1276, 1276, 1276, 1276, 1276,
- 1276, 1276, 1276, 1276, 1276, 1276, 1276, 1276,
- 1276, 1276, 1276, 1276, 1276, 1276, 1276, 1276,
- 1276, 1276, 1276, 1276, 1276, 1276, 1276, 1276,
-
- 1276, 1276, 1276, 1276, 1276, 1276, 1276, 1276,
- 1276, 1276, 1276, 1302, 1302, 1302, 1299, 1299,
+ 1298, 1298, 1298, 1298, 1298, 1298, 177, 1299,
+ 177, 177, 177, 177, 177, 1299, 177, 177,
1300, 1300, 1300, 1300, 1300, 1300, 1300, 1300,
1300, 1300, 1300, 1300, 1300, 1300, 1300, 1300,
@@ -2884,1886 +2374,2456 @@ static const unsigned short uc_property_trie[] = {
1300, 1300, 1300, 1300, 1300, 1300, 1300, 1300,
1300, 1300, 1300, 1300, 1300, 1300, 1300, 1300,
- 1300, 1300, 1300, 1300, 1300, 1300, 1300, 1300,
- 1300, 1300, 1300, 1300, 1300, 1300, 1300, 1300,
- 1300, 1300, 1300, 1300, 1300, 1300, 1300, 1300,
- 1300, 1300, 1299, 1299, 1299, 1299, 1299, 1299,
-
- 1352, 1353, 1354, 1355, 1356, 1357, 1357, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 1358, 1359, 1360, 1361, 1362,
- 175, 175, 175, 175, 175, 1363, 1364, 279,
-
- 279, 279, 279, 279, 279, 279, 279, 279,
- 279, 1365, 279, 279, 279, 279, 279, 279,
- 279, 279, 279, 279, 279, 279, 279, 252,
- 279, 279, 279, 279, 279, 252, 279, 252,
-
- 279, 279, 252, 279, 279, 252, 279, 279,
- 279, 279, 279, 279, 279, 279, 279, 279,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
-
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
-
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 1366, 1366, 1366, 1366, 1366, 1366,
- 1366, 1366, 1366, 1366, 1366, 1366, 1366, 1366,
-
- 1366, 1366, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
-
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 1051, 1260,
-
- 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
+ 1300, 1300, 1300, 1300, 1300, 1300, 1301, 1301,
+ 177, 177, 177, 177, 177, 177, 177, 1302,
+ 1303, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 1304,
+
+ 739, 739, 739, 739, 739, 739, 739, 739,
+ 739, 739, 739, 739, 739, 739, 739, 739,
+ 739, 739, 739, 739, 739, 739, 739, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 739, 739, 739, 739, 739, 739, 739, 177,
+ 739, 739, 739, 739, 739, 739, 739, 177,
+ 739, 739, 739, 739, 739, 739, 739, 177,
+ 739, 739, 739, 739, 739, 739, 739, 177,
+
+ 228, 228, 228, 228, 228, 228, 228, 228,
+ 228, 228, 228, 228, 228, 228, 228, 228,
+ 228, 228, 228, 228, 228, 228, 228, 228,
+ 228, 228, 228, 228, 228, 228, 228, 228,
+
+ 1305, 1305, 1306, 1307, 1306, 1307, 1305, 1305,
+ 1305, 1306, 1307, 1305, 1306, 1307, 1133, 1133,
+ 1133, 1133, 1133, 1133, 1133, 1133, 1132, 1308,
+ 1309, 1310, 1311, 1312, 1306, 1307, 1312, 1312,
+
+ 1313, 1314, 1260, 1261, 1260, 1261, 1260, 1261,
+ 1260, 1261, 1310, 1310, 1310, 1310, 1315, 1316,
+ 1310, 1317, 1318, 1319, 1319, 1318, 1318, 1318,
+ 1318, 1318, 1320, 1320, 177, 177, 177, 177,
+
+ 1321, 1321, 1321, 1321, 1321, 1321, 1321, 1321,
+ 1321, 1321, 1321, 1321, 1321, 1321, 1321, 1321,
+ 1321, 1321, 1321, 1321, 1321, 1321, 1321, 1321,
+ 1321, 1321, 177, 1321, 1321, 1321, 1321, 1321,
+
+ 1321, 1321, 1321, 1321, 1321, 1321, 1321, 1321,
+ 1321, 1321, 1321, 1321, 1321, 1321, 1321, 1321,
+ 1321, 1321, 1321, 1321, 1321, 1321, 1321, 1321,
+ 1321, 1321, 1321, 1321, 1321, 1321, 1321, 1321,
+
+ 1321, 1321, 1321, 1321, 1321, 1321, 1321, 1321,
+ 1321, 1321, 1321, 1321, 1321, 1321, 1321, 1321,
+ 1321, 1321, 1321, 1321, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1321, 1321, 1321, 1321, 1321, 1321, 1321, 1321,
+ 1321, 1321, 1321, 1321, 1321, 1321, 1321, 1321,
+ 1321, 1321, 1321, 1321, 1321, 1321, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1322, 1322, 1322, 1322, 1322, 1322, 1322, 1322,
+ 1322, 1322, 1322, 1322, 177, 177, 177, 177,
+
+ 1323, 1324, 1325, 1326, 1206, 1327, 1328, 1329,
+ 16, 1124, 16, 1124, 16, 1124, 16, 1124,
+ 16, 1124, 1206, 1206, 16, 1124, 16, 1124,
+ 16, 1124, 16, 1124, 1330, 1105, 1331, 1331,
+
+ 1206, 1329, 1329, 1329, 1329, 1329, 1329, 1329,
+ 1329, 1329, 1332, 1333, 154, 1334, 1335, 1335,
+ 1336, 1337, 1337, 1337, 1337, 1337, 1206, 1206,
+ 1338, 1338, 1338, 1339, 1340, 1341, 1322, 1206,
+
+ 177, 1342, 1343, 1342, 1343, 1342, 1343, 1342,
+ 1343, 1342, 1343, 1343, 1343, 1343, 1343, 1343,
+ 1343, 1343, 1343, 1343, 1343, 1343, 1343, 1343,
+ 1343, 1343, 1343, 1343, 1343, 1343, 1343, 1343,
+
+ 1343, 1343, 1343, 1342, 1343, 1343, 1343, 1343,
+ 1343, 1343, 1343, 1343, 1343, 1343, 1343, 1343,
+ 1343, 1343, 1343, 1343, 1343, 1343, 1343, 1343,
+ 1343, 1343, 1343, 1343, 1343, 1343, 1343, 1343,
+
+ 1343, 1343, 1343, 1342, 1343, 1342, 1343, 1342,
+ 1343, 1343, 1343, 1343, 1343, 1343, 1342, 1343,
+ 1343, 1343, 1343, 1343, 1343, 1344, 1344, 177,
+ 177, 1345, 1345, 1346, 1346, 1347, 1347, 1348,
+
+ 1349, 1350, 1351, 1350, 1351, 1350, 1351, 1350,
+ 1351, 1350, 1351, 1351, 1351, 1351, 1351, 1351,
+ 1351, 1351, 1351, 1351, 1351, 1351, 1351, 1351,
+ 1351, 1351, 1351, 1351, 1351, 1351, 1351, 1351,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 284, 284, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
+ 1351, 1351, 1351, 1350, 1351, 1351, 1351, 1351,
+ 1351, 1351, 1351, 1351, 1351, 1351, 1351, 1351,
+ 1351, 1351, 1351, 1351, 1351, 1351, 1351, 1351,
+ 1351, 1351, 1351, 1351, 1351, 1351, 1351, 1351,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 284, 284, 284, 284, 284, 284, 284, 284,
- 1367, 1367, 1367, 1367, 1367, 1367, 1367, 1367,
+ 1351, 1351, 1351, 1350, 1351, 1350, 1351, 1350,
+ 1351, 1351, 1351, 1351, 1351, 1351, 1350, 1351,
+ 1351, 1351, 1351, 1351, 1351, 1350, 1350, 1351,
+ 1351, 1351, 1351, 1352, 1353, 1354, 1354, 1355,
+
+ 177, 177, 177, 177, 177, 1356, 1356, 1356,
+ 1356, 1356, 1356, 1356, 1356, 1356, 1356, 1356,
+ 1356, 1356, 1356, 1356, 1356, 1356, 1356, 1356,
+ 1356, 1356, 1356, 1356, 1356, 1356, 1356, 1356,
+
+ 1356, 1356, 1356, 1356, 1356, 1356, 1356, 1356,
+ 1356, 1356, 1356, 1356, 1356, 1357, 177, 177,
+ 177, 1358, 1358, 1358, 1358, 1358, 1358, 1358,
+ 1358, 1358, 1358, 1358, 1358, 1358, 1358, 1358,
+
+ 1358, 1358, 1358, 1358, 1358, 1358, 1358, 1358,
+ 1358, 1358, 1358, 1358, 1358, 1358, 1358, 1358,
+ 1358, 1358, 1358, 1358, 1358, 1358, 1358, 1358,
+ 1358, 1358, 1358, 1358, 1358, 1358, 1358, 1358,
+
+ 1358, 1358, 1358, 1358, 1358, 1358, 1358, 1358,
+ 1358, 1358, 1358, 1358, 1358, 1358, 1358, 177,
+ 1359, 1359, 1360, 1360, 1360, 1360, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+
+ 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
+ 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
+ 1361, 1361, 1361, 1361, 1361, 1361, 1361, 1361,
+ 1362, 1362, 1362, 177, 177, 177, 177, 177,
+
+ 1238, 1238, 1238, 1238, 1238, 1238, 1238, 1238,
+ 1238, 1238, 1238, 1238, 1238, 1238, 1238, 1238,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+
+ 1242, 1242, 1242, 1242, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1363, 1363, 1363, 1363, 1363, 1363, 1363, 1363,
+ 1363, 1363, 1363, 1363, 1363, 1363, 1363, 1363,
+
+ 1364, 1364, 1364, 1364, 1364, 1364, 1364, 1364,
+ 1364, 1364, 1364, 1364, 1364, 1364, 1364, 1364,
+ 1364, 1364, 1364, 1364, 1364, 1364, 1364, 1364,
+ 1364, 1364, 1364, 1364, 1364, 1365, 1365, 177,
+
+ 1360, 1360, 1360, 1360, 1360, 1360, 1360, 1360,
+ 1360, 1360, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+
+ 1359, 1359, 1359, 1359, 1366, 1366, 1366, 1366,
1367, 1367, 1367, 1367, 1367, 1367, 1367, 1367,
+ 1237, 1368, 1368, 1368, 1368, 1368, 1368, 1368,
+ 1368, 1368, 1368, 1368, 1368, 1368, 1368, 1368,
+
+ 1364, 1364, 1364, 1364, 1364, 1364, 1364, 1364,
+ 1364, 1364, 1364, 1364, 1364, 1364, 1364, 1364,
+ 1364, 1364, 1364, 1364, 1364, 1364, 1364, 1364,
+ 1364, 1364, 1364, 1364, 1365, 1365, 1369, 1359,
+
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1368, 1368, 1368, 1368, 1368, 1368, 1368,
+ 1368, 1368, 1368, 1368, 1368, 1368, 1368, 1368,
+
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1237, 1237, 1237, 1237,
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
+
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 177,
+
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
+
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
+ 1370, 1370, 1370, 1370, 1370, 1370, 1370, 1370,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1237,
+ 1237, 1237, 1237, 1359, 1359, 1359, 1359, 1359,
+
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1237, 1237,
+
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359,
+ 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1237,
+
+ 1371, 1371, 1371, 1371, 1371, 1371, 1371, 1371,
+ 1371, 1371, 1371, 1371, 1371, 1371, 1371, 1371,
+ 1371, 1371, 1371, 1371, 1371, 1371, 1371, 1371,
+ 1371, 1371, 1371, 1371, 1371, 1371, 1371, 1371,
+
+ 1371, 1371, 1371, 1371, 1371, 1371, 1371, 1371,
+ 1371, 1371, 1371, 1371, 1371, 1371, 1371, 1371,
+ 1371, 1371, 1371, 1371, 1371, 1371, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
- 1367, 1367, 1367, 1367, 1367, 1367, 1367, 1367,
- 1367, 1367, 1367, 1367, 1367, 1367, 1367, 1367,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 1368, 811, 284, 284,
-
- 1369, 1369, 1369, 1369, 1369, 1369, 1369, 1369,
- 1369, 1369, 1369, 1369, 1369, 1369, 1369, 1369,
- 1370, 1371, 1372, 1373, 1374, 1228, 1228, 1375,
- 1376, 1377, 175, 175, 175, 175, 175, 175,
-
- 151, 151, 151, 151, 927, 927, 927, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1255, 1378, 1378, 1379, 1379, 1051, 1260, 1051,
- 1260, 1051, 1260, 1051, 1260, 1051, 1260, 1051,
-
- 1260, 1051, 1260, 1051, 1260, 1270, 1270, 1380,
- 1381, 1255, 1255, 1255, 1255, 1379, 1379, 1379,
- 1382, 1383, 1384, 175, 1385, 1386, 9, 9,
- 1378, 16, 1070, 16, 1070, 16, 1070, 1387,
-
- 1255, 1255, 1388, 1389, 1390, 1391, 1392, 175,
- 1255, 12, 13, 1255, 175, 175, 175, 175,
- 300, 300, 300, 1393, 300, 284, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
-
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 300, 300, 300,
- 300, 300, 300, 300, 300, 284, 284, 1394,
-
- 175, 9, 1255, 1387, 12, 13, 1255, 1395,
- 16, 1070, 1255, 1388, 1382, 1389, 1384, 1396,
- 1397, 1398, 1399, 1400, 1401, 1402, 1403, 1404,
- 1405, 1406, 1386, 1385, 1407, 1392, 1408, 9,
-
- 1255, 1409, 1409, 1409, 1409, 1409, 1409, 1409,
- 1409, 1409, 1409, 1409, 1409, 1409, 1409, 1409,
- 1409, 1409, 1409, 1409, 1409, 1409, 1409, 1409,
- 1409, 1409, 1409, 39, 1255, 46, 1410, 1379,
-
- 1410, 1411, 1411, 1411, 1411, 1411, 1411, 1411,
- 1411, 1411, 1411, 1411, 1411, 1411, 1411, 1411,
- 1411, 1411, 1411, 1411, 1411, 1411, 1411, 1411,
- 1411, 1411, 1411, 39, 1392, 46, 1392, 1184,
-
- 1185, 1254, 16, 1070, 1253, 1280, 1412, 1278,
- 1278, 1278, 1278, 1278, 1278, 1278, 1278, 1278,
- 1281, 1412, 1412, 1412, 1412, 1412, 1412, 1412,
- 1412, 1412, 1412, 1412, 1412, 1412, 1412, 1412,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+
+ 1373, 1373, 1373, 1373, 1373, 1373, 1373, 1373,
+ 1373, 1373, 1373, 1373, 1373, 1373, 1373, 1373,
+ 1373, 1373, 1373, 1373, 1373, 1373, 1373, 1373,
+ 1373, 1373, 1373, 1373, 1373, 1373, 1373, 1373,
+
+ 1373, 1373, 1373, 1373, 1373, 1373, 1374, 1374,
+ 1374, 1374, 1374, 1374, 1374, 1374, 1374, 1374,
+ 1374, 1374, 1374, 1374, 1374, 1374, 1374, 1374,
+ 1374, 1374, 1374, 1374, 1375, 1375, 1375, 1375,
+
+ 1375, 1375, 1375, 1375, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1377, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+
+ 1378, 1378, 1378, 1378, 1378, 1378, 1378, 1378,
+ 1378, 1378, 1378, 1378, 1378, 1378, 1378, 1378,
+ 1378, 1378, 1378, 1378, 1378, 1379, 1378, 1378,
+ 1378, 1378, 1378, 1378, 1378, 1378, 1378, 1378,
+
+ 1378, 1378, 1378, 1378, 1378, 1378, 1378, 1378,
+ 1378, 1378, 1378, 1378, 1378, 1378, 1378, 1378,
+ 1378, 1378, 1378, 1378, 1378, 1378, 1378, 1378,
+ 1378, 1378, 1378, 1378, 1378, 1378, 1378, 1378,
+
+ 1378, 1378, 1378, 1378, 1378, 1378, 1378, 1378,
+ 1378, 1378, 1378, 1378, 1378, 177, 177, 177,
+ 1380, 1380, 1380, 1380, 1380, 1380, 1380, 1380,
+ 1380, 1380, 1380, 1380, 1380, 1380, 1380, 1380,
+
+ 1380, 1380, 1381, 1381, 1380, 1380, 1380, 1380,
+ 1380, 1380, 1380, 1380, 1380, 1380, 1380, 1380,
+ 1380, 1380, 1380, 1380, 1381, 1380, 1380, 1380,
+ 1380, 1380, 1380, 1380, 1380, 1380, 1380, 1380,
+
+ 1380, 1381, 1380, 1380, 1380, 1381, 1380, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1382, 1382, 1382, 1382, 1382, 1382, 1382, 1382,
+ 1382, 1382, 1382, 1382, 1382, 1382, 1382, 1382,
+
+ 1382, 1382, 1382, 1382, 1382, 1382, 1382, 1382,
+ 1382, 1382, 1382, 1382, 1382, 1382, 1382, 1382,
+ 1382, 1382, 1382, 1382, 1382, 1382, 1382, 1382,
+ 1383, 1383, 1383, 1383, 1383, 1383, 1384, 1385,
+
+ 1386, 1386, 1386, 1386, 1386, 1386, 1386, 1386,
+ 1386, 1386, 1386, 1386, 1386, 1386, 1386, 1386,
+ 1386, 1386, 1386, 1386, 1386, 1386, 1386, 1386,
+ 1386, 1386, 1386, 1386, 1386, 1386, 1386, 1386,
+
+ 1386, 1386, 1386, 1386, 1386, 1386, 1386, 1386,
+ 1386, 1386, 1386, 1386, 1387, 1388, 1389, 1390,
+ 1386, 1386, 1386, 1386, 1386, 1386, 1386, 1386,
+ 1386, 1386, 1386, 1386, 1386, 1386, 1386, 1386,
+
+ 1391, 1392, 1393, 1394, 1395, 1396, 1397, 1398,
+ 1399, 1400, 1386, 1386, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 240, 241, 240, 241, 240, 241, 240, 241,
+ 240, 241, 240, 241, 240, 241, 240, 241,
+ 240, 241, 240, 241, 240, 241, 240, 241,
+ 240, 241, 240, 241, 240, 241, 240, 241,
+
+ 244, 245, 240, 241, 240, 241, 240, 241,
+ 240, 241, 240, 241, 240, 241, 1401, 228,
+ 1402, 1402, 1402, 1403, 1404, 1404, 1404, 1404,
+ 1404, 1404, 1404, 1404, 228, 228, 1403, 1405,
+
+ 240, 241, 240, 241, 240, 241, 240, 241,
+ 240, 241, 240, 241, 240, 241, 240, 241,
+ 240, 241, 240, 241, 240, 241, 240, 241,
+ 177, 177, 177, 177, 177, 177, 177, 1404,
+
+ 1406, 1406, 1406, 1406, 1406, 1406, 1406, 1406,
+ 1406, 1406, 1406, 1406, 1406, 1406, 1406, 1406,
+ 1406, 1406, 1406, 1406, 1406, 1406, 1406, 1406,
+ 1406, 1406, 1406, 1406, 1406, 1406, 1406, 1406,
+
+ 1406, 1406, 1406, 1406, 1406, 1406, 1407, 1407,
+ 1407, 1407, 1407, 1407, 1407, 1407, 1407, 1407,
+ 1408, 1408, 1409, 1410, 1411, 1411, 1411, 1410,
+ 177, 177, 177, 177, 177, 177, 177, 177,
1412, 1412, 1412, 1412, 1412, 1412, 1412, 1412,
1412, 1412, 1412, 1412, 1412, 1412, 1412, 1412,
- 1412, 1412, 1412, 1412, 1412, 1412, 1412, 1412,
- 1412, 1412, 1412, 1412, 1412, 1412, 1413, 1413,
-
- 1414, 1414, 1414, 1414, 1414, 1414, 1414, 1414,
- 1414, 1414, 1414, 1414, 1414, 1414, 1414, 1414,
- 1414, 1414, 1414, 1414, 1414, 1414, 1414, 1414,
- 1414, 1414, 1414, 1414, 1414, 1414, 1414, 175,
-
- 175, 175, 1414, 1414, 1414, 1414, 1414, 1414,
- 175, 175, 1414, 1414, 1414, 1414, 1414, 1414,
- 175, 175, 1414, 1414, 1414, 1414, 1414, 1414,
- 175, 175, 1414, 1414, 1414, 175, 175, 175,
-
- 50, 12, 1392, 1410, 1145, 12, 12, 175,
- 51, 36, 36, 36, 36, 51, 51, 175,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1415, 1415, 1415, 1416, 51, 1417, 1417,
-
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 175, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
-
- 805, 805, 805, 805, 805, 805, 805, 175,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 175, 805, 805, 175, 805,
-
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 175, 175,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 175, 175,
-
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
-
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 175, 175, 175, 175, 175,
-
- 1418, 1419, 1418, 175, 175, 175, 175, 1420,
- 1420, 1420, 1420, 1420, 1420, 1420, 1420, 1420,
- 1420, 1420, 1420, 1420, 1420, 1420, 1420, 1420,
- 1420, 1420, 1420, 1420, 1420, 1420, 1420, 1420,
-
- 1420, 1420, 1420, 1420, 1420, 1420, 1420, 1420,
- 1420, 1420, 1420, 1420, 1420, 1420, 1420, 1420,
- 1420, 1420, 1420, 1420, 175, 175, 175, 1421,
- 1421, 1421, 1421, 1421, 1421, 1421, 1421, 1421,
-
- 1422, 1422, 1422, 1422, 1422, 1422, 1422, 1422,
- 1422, 1422, 1422, 1422, 1422, 1422, 1422, 1422,
- 1422, 1422, 1422, 1422, 1422, 1422, 1422, 1422,
- 1422, 1422, 1422, 1422, 1422, 1422, 1422, 1422,
-
- 1422, 1422, 1422, 1422, 1422, 1422, 1422, 1422,
- 1422, 1422, 1422, 1422, 1422, 1422, 1422, 1422,
- 1422, 1422, 1422, 1422, 1422, 1423, 1423, 1423,
- 1423, 1424, 1424, 1424, 1424, 1424, 1424, 1424,
-
- 1424, 1424, 1424, 1424, 1424, 1424, 1424, 1424,
- 1424, 1424, 1423, 175, 175, 175, 175, 175,
- 1178, 1178, 1178, 1178, 1178, 1178, 1178, 1178,
- 1178, 1178, 1178, 1178, 175, 175, 175, 175,
-
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1124, 1124, 1124, 1124, 1124, 1124, 1124, 1124,
- 1124, 1124, 1124, 1124, 1124, 1124, 1124, 1124,
-
- 1124, 1124, 1124, 1124, 1124, 1124, 1124, 1124,
- 1124, 1124, 1124, 1124, 1124, 1124, 1124, 1124,
- 1124, 1124, 1124, 1124, 1124, 1124, 1124, 1124,
- 1124, 1124, 1124, 1124, 1124, 930, 175, 175,
-
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 175, 175, 175,
-
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 804, 804, 804, 804, 804, 804, 804,
- 804, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1425, 1425, 1425, 1425, 1425, 1425, 1425, 1425,
- 1425, 1425, 1425, 1425, 1425, 1425, 1425, 1425,
- 1425, 1425, 1425, 1425, 1425, 1425, 1425, 1425,
- 1425, 1425, 1425, 1425, 1425, 1425, 1425, 175,
-
- 1426, 1426, 1426, 1426, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1425, 1425, 1425, 1425, 1425, 1425, 1425, 1425,
- 1425, 1425, 1425, 1425, 1425, 1425, 1425, 1425,
-
- 1425, 1427, 1425, 1425, 1425, 1425, 1425, 1425,
- 1425, 1425, 1427, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 175, 1418,
-
- 735, 735, 735, 735, 175, 175, 175, 175,
- 735, 735, 735, 735, 735, 735, 735, 735,
- 1428, 1429, 1429, 1429, 1429, 1429, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1430, 1430, 1430, 1430, 1430, 1430, 1430, 1430,
- 1430, 1430, 1430, 1430, 1430, 1430, 1430, 1430,
- 1430, 1430, 1430, 1430, 1430, 1430, 1430, 1430,
- 1430, 1430, 1430, 1430, 1430, 1430, 1430, 1430,
+ 1412, 1412, 1412, 1412, 1412, 1412, 1412, 1413,
+ 1413, 1413, 1413, 1316, 1316, 1316, 1316, 1316,
+
+ 1414, 1414, 995, 996, 995, 996, 995, 996,
+ 995, 996, 995, 996, 995, 996, 995, 996,
+ 993, 993, 995, 996, 995, 996, 995, 996,
+ 995, 996, 995, 996, 995, 996, 995, 996,
+
+ 995, 996, 995, 996, 995, 996, 995, 996,
+ 995, 996, 995, 996, 995, 996, 995, 996,
+ 995, 996, 995, 996, 995, 996, 995, 996,
+ 995, 996, 995, 996, 995, 996, 995, 996,
+
+ 995, 996, 995, 996, 995, 996, 995, 996,
+ 995, 996, 995, 996, 995, 996, 995, 996,
+ 1284, 993, 993, 993, 993, 993, 993, 993,
+ 993, 995, 996, 995, 996, 1415, 995, 996,
+
+ 995, 996, 995, 996, 995, 996, 995, 996,
+ 1316, 1416, 1416, 995, 996, 1417, 1418, 177,
+ 1419, 1420, 1421, 1422, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1419, 1420, 1419, 1420, 1419, 1420, 1419, 1420,
+ 1419, 1420, 1423, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1424, 1424, 1418, 1425, 1425, 1425, 1425, 1425,
+
+ 1426, 1426, 1427, 1426, 1426, 1426, 1428, 1426,
+ 1426, 1426, 1426, 1427, 1426, 1426, 1426, 1426,
+ 1426, 1426, 1426, 1426, 1426, 1426, 1426, 1426,
+ 1426, 1426, 1426, 1426, 1426, 1426, 1426, 1426,
+
+ 1426, 1426, 1426, 1429, 1429, 1427, 1427, 1429,
+ 1430, 1430, 1430, 1430, 177, 177, 177, 177,
+ 1367, 1367, 1367, 1367, 1367, 1367, 685, 685,
+ 1155, 1431, 177, 177, 177, 177, 177, 177,
- 1430, 1430, 1430, 1430, 1430, 1430, 1431, 1431,
+ 1432, 1432, 1432, 1432, 1432, 1432, 1432, 1432,
1432, 1432, 1432, 1432, 1432, 1432, 1432, 1432,
1432, 1432, 1432, 1432, 1432, 1432, 1432, 1432,
1432, 1432, 1432, 1432, 1432, 1432, 1432, 1432,
1432, 1432, 1432, 1432, 1432, 1432, 1432, 1432,
- 1432, 1432, 1432, 1432, 1432, 1432, 1433, 1433,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
-
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 805, 805,
- 805, 805, 805, 805, 805, 805, 175, 175,
-
- 813, 814, 815, 816, 817, 818, 819, 820,
- 821, 822, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1434, 1434, 1434, 1434, 1434, 1434, 252, 252,
- 1434, 252, 1434, 1434, 1434, 1434, 1434, 1434,
- 1434, 1434, 1434, 1434, 1434, 1434, 1434, 1434,
- 1434, 1434, 1434, 1434, 1434, 1434, 1434, 1434,
-
- 1434, 1434, 1434, 1434, 1434, 1434, 1434, 1434,
- 1434, 1434, 1434, 1434, 1434, 1434, 1434, 1434,
- 1434, 1434, 1434, 1434, 1434, 1434, 252, 1434,
- 1434, 252, 252, 252, 1434, 252, 252, 1434,
-
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 252, 1435,
- 1436, 1436, 1436, 1436, 1436, 1436, 1436, 1436,
+ 1432, 1432, 1432, 1432, 1432, 1432, 1432, 1432,
+ 1432, 1432, 1432, 1432, 1433, 1433, 1434, 1434,
+ 177, 177, 177, 177, 177, 177, 177, 177,
- 1437, 1437, 1437, 1437, 1437, 1437, 1437, 1437,
- 1437, 1437, 1437, 1437, 1437, 1437, 1437, 1437,
- 1437, 1437, 1437, 1437, 1437, 1437, 1438, 1438,
- 1438, 1438, 1436, 1436, 252, 252, 252, 1439,
-
- 1440, 1440, 1440, 1440, 1440, 1440, 1440, 1440,
- 1440, 1440, 1440, 1440, 1440, 1440, 1440, 1440,
- 1440, 1440, 1440, 1440, 1440, 1440, 1440, 1440,
- 1440, 1440, 252, 252, 252, 252, 252, 1441,
-
- 1442, 1442, 1442, 1442, 1442, 1442, 1442, 1442,
- 1442, 1442, 1442, 1442, 1442, 1442, 1442, 1442,
- 1442, 1442, 1442, 1442, 1442, 1442, 1442, 1442,
- 1442, 1442, 1442, 1442, 1442, 1442, 1442, 1442,
-
- 1442, 1442, 1442, 1442, 1442, 1442, 1442, 1442,
- 1442, 1442, 1442, 1442, 1442, 1442, 1442, 1442,
- 1442, 1442, 1442, 1442, 1442, 1442, 1442, 1442,
- 252, 252, 252, 252, 252, 252, 1442, 1442,
-
- 1443, 1327, 1327, 1327, 252, 1327, 1327, 252,
- 252, 252, 252, 252, 1327, 841, 1327, 737,
- 1443, 1443, 1443, 1443, 252, 1443, 1443, 1443,
- 252, 1443, 1443, 1443, 1443, 1443, 1443, 1443,
-
- 1443, 1443, 1443, 1443, 1443, 1443, 1443, 1443,
- 1443, 1443, 1443, 1443, 1443, 1443, 1443, 1443,
- 1443, 1443, 1443, 1443, 252, 252, 252, 252,
- 737, 1444, 841, 252, 252, 252, 252, 1328,
-
- 1445, 1446, 1447, 1448, 1449, 1449, 1449, 1449,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 1450, 1450, 1450, 1450, 1450, 1450, 1451, 1451,
- 1452, 252, 252, 252, 252, 252, 252, 252,
-
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 1436, 1436, 392,
-
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 389, 389,
-
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 252, 252,
- 252, 1247, 1247, 1247, 1247, 1247, 1247, 1247,
-
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 252, 252,
+ 1435, 1435, 1436, 1436, 1436, 1436, 1436, 1436,
+ 1436, 1436, 1436, 1436, 1436, 1436, 1436, 1436,
+ 1436, 1436, 1436, 1436, 1436, 1436, 1436, 1436,
1436, 1436, 1436, 1436, 1436, 1436, 1436, 1436,
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 389, 389, 252, 252, 252, 252, 252,
1436, 1436, 1436, 1436, 1436, 1436, 1436, 1436,
+ 1436, 1436, 1436, 1436, 1436, 1436, 1436, 1436,
+ 1436, 1436, 1436, 1436, 1435, 1435, 1435, 1435,
+ 1435, 1435, 1435, 1435, 1435, 1435, 1435, 1435,
+
+ 1435, 1435, 1435, 1435, 1437, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 1438, 1438,
+ 1439, 1440, 1441, 1442, 1443, 1444, 1445, 1446,
+ 1447, 1448, 177, 177, 177, 177, 177, 177,
+
+ 1449, 1449, 1449, 1449, 1449, 1449, 1449, 1449,
+ 1449, 1449, 1449, 1449, 1449, 1449, 1449, 1449,
+ 1449, 1449, 435, 435, 435, 435, 435, 435,
+ 1450, 1450, 1450, 435, 177, 177, 177, 177,
+
+ 1451, 1452, 1453, 1454, 1455, 1456, 1457, 1458,
+ 1459, 1460, 1461, 1461, 1461, 1461, 1461, 1461,
+ 1461, 1461, 1461, 1461, 1461, 1461, 1461, 1461,
+ 1461, 1461, 1461, 1461, 1461, 1461, 1461, 1461,
+
+ 1461, 1461, 1461, 1461, 1461, 1461, 1462, 1462,
+ 1462, 1462, 1462, 1463, 1463, 1463, 1464, 1465,
+ 1466, 1466, 1466, 1466, 1466, 1466, 1466, 1466,
+ 1466, 1466, 1466, 1466, 1466, 1466, 1466, 1466,
+
+ 1466, 1466, 1466, 1466, 1466, 1466, 1466, 1467,
+ 1467, 1467, 1467, 1467, 1467, 1467, 1467, 1467,
+ 1467, 1467, 1468, 1469, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 1470,
+
+ 733, 733, 733, 733, 733, 733, 733, 733,
+ 733, 733, 733, 733, 733, 733, 733, 733,
+ 733, 733, 733, 733, 733, 733, 733, 733,
+ 733, 733, 733, 733, 733, 177, 177, 177,
+
+ 1471, 1471, 1471, 1472, 1473, 1473, 1473, 1473,
+ 1473, 1473, 1473, 1473, 1473, 1473, 1473, 1473,
+ 1473, 1473, 1473, 1473, 1473, 1473, 1473, 1473,
+ 1473, 1473, 1473, 1473, 1473, 1473, 1473, 1473,
+
+ 1473, 1473, 1473, 1473, 1473, 1473, 1473, 1473,
+ 1473, 1473, 1473, 1473, 1473, 1473, 1473, 1473,
+ 1473, 1473, 1473, 1474, 1472, 1472, 1471, 1471,
+ 1471, 1471, 1472, 1472, 1471, 1472, 1472, 1472,
+
+ 1475, 1476, 1476, 1476, 1476, 1476, 1476, 1477,
+ 1478, 1478, 1476, 1476, 1476, 1476, 177, 1479,
+ 1480, 1481, 1482, 1483, 1484, 1485, 1486, 1487,
+ 1488, 1489, 177, 177, 177, 177, 1476, 1476,
+
+ 1490, 1490, 1490, 1490, 1490, 1490, 1490, 1490,
+ 1490, 1490, 1490, 1490, 1490, 1490, 1490, 1490,
+ 1490, 1490, 1490, 1490, 1490, 1490, 1490, 1490,
+ 1490, 1490, 1490, 1490, 1490, 1490, 1490, 1490,
+
+ 1490, 1490, 1490, 1490, 1490, 1490, 1490, 1490,
+ 1490, 1491, 1491, 1491, 1491, 1491, 1491, 1492,
+ 1492, 1491, 1491, 1492, 1492, 1491, 1491, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1490, 1490, 1490, 1491, 1490, 1490, 1490, 1490,
+ 1490, 1490, 1490, 1490, 1491, 1492, 177, 177,
+ 1493, 1494, 1495, 1496, 1497, 1498, 1499, 1500,
+ 1501, 1502, 177, 177, 1503, 1504, 1504, 1504,
+
+ 1505, 1505, 1505, 1505, 1505, 1505, 1505, 1505,
+ 1505, 1505, 1505, 1505, 1505, 1505, 1505, 1505,
+ 1506, 1505, 1505, 1505, 1505, 1505, 1505, 1507,
+ 1507, 1507, 1505, 721, 177, 177, 177, 177,
+
+ 1508, 1508, 1508, 1508, 1508, 1508, 1508, 1508,
+ 1508, 1508, 1508, 1508, 1508, 1508, 1508, 1508,
+ 1508, 1508, 1508, 1508, 1508, 1508, 1508, 1508,
+ 1508, 1508, 1508, 1508, 1508, 1508, 1508, 1508,
+
+ 1508, 1508, 1508, 1508, 1508, 1508, 1508, 1508,
+ 1508, 1508, 1508, 1508, 1508, 1508, 1508, 1508,
+ 1509, 1508, 1509, 1509, 1510, 1508, 1508, 1509,
+ 1509, 1508, 1508, 1508, 1508, 1508, 1509, 1509,
+
+ 1508, 1509, 1508, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 1508, 1508, 1511, 1512, 1512,
- 389, 389, 389, 389, 389, 389, 389, 389,
- 389, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
-
- 1453, 1454, 1455, 1456, 1457, 1458, 1459, 1460,
- 1461, 1462, 1462, 1462, 1462, 1462, 1462, 1462,
- 1462, 1462, 1462, 1462, 1462, 1462, 1462, 1462,
- 1462, 1462, 1462, 1462, 1462, 1462, 1462, 252,
-
- 901, 902, 901, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 902, 902, 902, 902, 902, 902, 902, 902,
- 902, 902, 902, 902, 902, 902, 1234, 1463,
- 1463, 904, 904, 904, 904, 904, 175, 175,
- 175, 175, 1464, 1465, 1466, 1467, 1468, 1469,
- 1470, 1471, 1472, 1473, 1473, 1473, 1473, 1473,
- 1473, 1473, 1473, 1473, 1473, 1473, 1474, 1475,
- 1476, 1477, 1478, 1479, 1480, 1481, 1482, 1483,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1337, 1337, 914, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 914, 914, 914, 1337, 1337, 1337, 1337, 914,
- 914, 1347, 1338, 911, 911, 1484, 1308, 1308,
- 1308, 1308, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 175, 175, 175, 175, 175, 175, 175,
- 1485, 1486, 1487, 1488, 1489, 1490, 1491, 1492,
- 1493, 1494, 175, 175, 175, 175, 175, 175,
-
- 1495, 1495, 1495, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 1344,
- 1344, 1344, 1344, 1344, 887, 1344, 1344, 1344,
- 1344, 1344, 1344, 886, 886, 175, 1485, 1486,
- 1487, 1488, 1489, 1490, 1491, 1492, 1493, 1494,
- 1496, 1345, 1345, 1345, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1344, 1344, 887, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 887, 887, 887, 1344, 1344,
- 1344, 1344, 1344, 1344, 1344, 1344, 1344, 887,
- 1497, 898, 898, 898, 898, 1345, 1345, 909,
- 1496, 175, 175, 175, 175, 175, 175, 175,
- 1485, 1486, 1487, 1488, 1489, 1490, 1491, 1492,
- 1493, 1494, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 1344, 887, 1344, 887, 887,
- 1344, 1344, 1344, 1344, 1344, 1344, 1497, 1498,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1485, 1486, 1487, 1488, 1489, 1490, 1491, 1492,
- 1493, 1494, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
-
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 864,
- 864, 864, 864, 864, 864, 864, 864, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1499, 1499, 1499, 1499, 1499, 1499, 1499, 1499,
- 1499, 1499, 1499, 1499, 1499, 1499, 1499, 1499,
- 1499, 1499, 1499, 1499, 1499, 1499, 1499, 1499,
- 1499, 1499, 1499, 1499, 1499, 1499, 1499, 1499,
- 1499, 1499, 1499, 1499, 1499, 1499, 1499, 1499,
- 1499, 1499, 1499, 1499, 1499, 1499, 1499, 1499,
- 1499, 1499, 1499, 1499, 1499, 1499, 1499, 1499,
- 1499, 1499, 1499, 1499, 1499, 1499, 1499, 1499,
- 1499, 1499, 1499, 1499, 1499, 1499, 1499, 1499,
- 1499, 1499, 1499, 1499, 1499, 1499, 1499, 1499,
- 1499, 1499, 1499, 1499, 1499, 1499, 1499, 1499,
- 1499, 1499, 1499, 1499, 1499, 1499, 1499, 1499,
- 1499, 1499, 1499, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 879, 879, 879, 879, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
-
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 1500, 1500, 1500, 1501, 1501, 1501, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 1501, 754, 754, 754, 1500, 1501,
- 1500, 1501, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
-
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 1500, 1501, 1501, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
-
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 754,
- 754, 754, 754, 754, 754, 754, 754, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
-
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 899, 899, 899, 899, 899, 899, 899,
- 899, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 898, 898, 898,
- 898, 898, 898, 898, 898, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 898, 887, 887, 887, 887, 887, 887, 887,
- 887, 887, 887, 887, 887, 887, 887, 887,
- 887, 887, 887, 887, 887, 887, 887, 887,
- 887, 887, 887, 887, 887, 887, 887, 887,
- 887, 887, 887, 887, 887, 887, 887, 887,
- 887, 887, 887, 887, 887, 887, 887, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 1344,
- 1344, 1344, 1344, 1346, 1346, 1346, 1346, 1346,
- 1346, 1346, 1346, 1346, 1346, 1346, 1346, 1346,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1502, 1503, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 175,
- 175, 1124, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1505, 1506, 1507,
- 1507, 1507, 1504, 1504, 1504, 1508, 1505, 1505,
- 1505, 1505, 1505, 1509, 1509, 1509, 1509, 1509,
- 1509, 1509, 1509, 1510, 1510, 1510, 1510, 1510,
- 1510, 1510, 1510, 1504, 1504, 1511, 1511, 1511,
- 1511, 1511, 1510, 1510, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1511, 1511, 1511, 1511, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 1504, 1504,
- 1504, 1504, 1504, 1504, 1504, 1504, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1424, 1424, 1424, 1424, 1424, 1424, 1424, 1424,
- 1424, 1424, 1424, 1424, 1424, 1424, 1424, 1424,
- 1424, 1424, 1424, 1424, 1424, 1424, 1424, 1424,
- 1424, 1424, 1424, 1424, 1424, 1424, 1424, 1424,
- 1424, 1424, 1424, 1424, 1424, 1424, 1424, 1424,
- 1424, 1424, 1424, 1424, 1424, 1424, 1424, 1424,
- 1424, 1424, 1424, 1424, 1424, 1424, 1424, 1424,
- 1424, 1424, 1424, 1424, 1424, 1424, 1424, 1424,
- 1424, 1424, 1512, 1512, 1512, 1424, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 811,
- 811, 811, 811, 811, 811, 811, 811, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1513, 1513, 1513, 1513, 1513, 1513, 1513, 1513,
1513, 1513, 1513, 1513, 1513, 1513, 1513, 1513,
- 1513, 1513, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 175, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1514, 175, 1514, 1514,
- 175, 175, 1514, 175, 175, 1514, 1514, 175,
- 175, 1514, 1514, 1514, 1514, 175, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1515, 1515,
- 1515, 1515, 175, 1515, 175, 1515, 1515, 1515,
- 1515, 105, 1515, 1515, 175, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
-
- 1515, 1515, 1515, 1515, 1514, 1514, 175, 1514,
- 1514, 1514, 1514, 175, 175, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 175, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 175, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1514, 1514, 175, 1514, 1514, 1514, 1514, 175,
- 1514, 1514, 1514, 1514, 1514, 175, 1514, 175,
- 175, 175, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 175, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
-
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 106, 106, 175, 175,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1516, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1517, 1515, 1515, 1515, 1515,
- 1515, 1515, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1516, 1515, 1515, 1515, 1515,
-
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1517, 1515, 1515,
- 1515, 1515, 1515, 1515, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1516, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1517,
- 1515, 1515, 1515, 1515, 1515, 1515, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1516,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1517, 1515, 1515, 1515, 1515, 1515, 1515,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1514, 1514, 1514, 1514, 1514, 1514, 1514,
- 1514, 1516, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1515, 1515, 1515, 1515, 1515,
- 1515, 1515, 1515, 1517, 1515, 1515, 1515, 1515,
- 1515, 1515, 1518, 1221, 175, 175, 1519, 1520,
- 1521, 1522, 1523, 1524, 1525, 1526, 1527, 1528,
- 1519, 1520, 1521, 1522, 1523, 1524, 1525, 1526,
- 1527, 1528, 1519, 1520, 1521, 1522, 1523, 1524,
- 1525, 1526, 1527, 1528, 1519, 1520, 1521, 1522,
- 1523, 1524, 1525, 1526, 1527, 1528, 1519, 1520,
- 1521, 1522, 1523, 1524, 1525, 1526, 1527, 1528,
-
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
- 252, 252, 252, 252, 252, 252, 252, 252,
-
- 1529, 1529, 1529, 1529, 284, 1529, 1529, 1529,
- 1529, 1529, 1529, 1529, 1529, 1529, 1529, 1529,
- 1529, 1529, 1529, 1529, 1529, 1529, 1529, 1529,
- 1529, 1529, 1529, 1529, 1529, 1529, 1529, 1529,
- 284, 1529, 1529, 284, 1529, 284, 284, 1529,
- 284, 1529, 1529, 1529, 1529, 1529, 1529, 1529,
- 1529, 1529, 1529, 284, 1529, 1529, 1529, 1529,
- 284, 1529, 284, 1529, 284, 284, 284, 284,
- 284, 284, 1529, 284, 284, 284, 284, 1529,
- 284, 1529, 284, 1529, 284, 1529, 1529, 1529,
- 284, 1529, 1529, 284, 1529, 284, 284, 1529,
- 284, 1529, 284, 1529, 284, 1529, 284, 1529,
- 284, 1529, 1529, 284, 1529, 284, 284, 1529,
- 1529, 1529, 1529, 284, 1529, 1529, 1529, 1529,
- 1529, 1529, 1529, 284, 1529, 1529, 1529, 1529,
- 284, 1529, 1529, 1529, 1529, 284, 1529, 284,
- 1529, 1529, 1529, 1529, 1529, 1529, 1529, 1529,
- 1529, 1529, 284, 1529, 1529, 1529, 1529, 1529,
- 1529, 1529, 1529, 1529, 1529, 1529, 1529, 1529,
- 1529, 1529, 1529, 1529, 284, 284, 284, 284,
- 284, 1529, 1529, 1529, 284, 1529, 1529, 1529,
- 1529, 1529, 284, 1529, 1529, 1529, 1529, 1529,
- 1529, 1529, 1529, 1529, 1529, 1529, 1529, 1529,
- 1529, 1529, 1529, 1529, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
- 1530, 1530, 284, 284, 284, 284, 284, 284,
- 284, 284, 284, 284, 284, 284, 284, 284,
+ 1513, 1513, 1513, 1514, 1515, 1515, 1514, 1514,
+ 1516, 1516, 1513, 1517, 1517, 1514, 1518, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 1519, 1519, 1519, 1519, 1519, 1519, 177,
+ 177, 1519, 1519, 1519, 1519, 1519, 1519, 177,
+ 177, 1519, 1519, 1519, 1519, 1519, 1519, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1519, 1519, 1519, 1519, 1519, 1519, 1519, 177,
+ 1519, 1519, 1519, 1519, 1519, 1519, 1519, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1520, 1520, 1520, 1520, 1520, 1520, 1520, 1520,
+ 1520, 1520, 1520, 1520, 1520, 1520, 1520, 1520,
+ 1520, 1520, 1520, 1520, 1520, 1520, 1520, 1520,
+ 1520, 1520, 1520, 1520, 1520, 1520, 1520, 1520,
+
+ 1520, 1520, 1520, 1521, 1521, 1522, 1521, 1521,
+ 1522, 1521, 1521, 1523, 1521, 1524, 177, 177,
+ 1525, 1526, 1527, 1528, 1529, 1530, 1531, 1532,
+ 1533, 1534, 177, 177, 177, 177, 177, 177,
+
+ 1535, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1535, 1536, 1536, 1536,
+
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1535, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1535, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1535, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1535, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1535, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+
+ 1536, 1536, 1536, 1536, 1535, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+ 1536, 1536, 1536, 1536, 1536, 1536, 1536, 1536,
+
+ 1536, 1536, 1536, 1536, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 735, 735, 735, 735, 735, 735, 735, 735,
+ 735, 735, 735, 735, 735, 735, 735, 735,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 175, 175, 175, 175,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 1181, 1181, 1181, 1181,
- 1181, 1181, 1181, 1181, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 175,
- 175, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 175,
- 175, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 175, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1531, 1531, 1532, 1533, 1534, 1535, 1536, 1537,
- 1538, 1539, 1540, 175, 175, 175, 175, 175,
- 681, 681, 681, 681, 681, 681, 681, 681,
- 681, 681, 681, 681, 681, 681, 681, 681,
- 681, 681, 681, 681, 681, 681, 681, 681,
- 681, 681, 681, 681, 681, 681, 681, 175,
- 1541, 681, 1541, 1541, 1541, 1541, 1541, 1541,
- 1541, 1541, 1541, 1541, 1541, 681, 1541, 681,
- 1541, 1541, 681, 1541, 1541, 1541, 681, 1541,
- 1541, 1541, 681, 681, 681, 681, 681, 1541,
- 1541, 1541, 1541, 1541, 1541, 1541, 1541, 681,
- 1541, 1541, 1541, 1541, 1541, 1541, 1541, 681,
- 1541, 1541, 1541, 1541, 1541, 1541, 1541, 1541,
- 1541, 1541, 1542, 1542, 175, 175, 175, 175,
- 1541, 1541, 1541, 1541, 1541, 1541, 1541, 1541,
- 1541, 681, 1541, 681, 681, 1541, 1541, 681,
- 1541, 1541, 1541, 1541, 1541, 1541, 1541, 1541,
- 1541, 1541, 681, 681, 681, 681, 1541, 1541,
- 681, 1541, 1541, 1541, 1541, 1541, 1541, 1541,
- 1541, 1541, 1541, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 1543, 1543,
- 1543, 1543, 1543, 1543, 1543, 1543, 1543, 1543,
- 1543, 1543, 1543, 1543, 1543, 1543, 1543, 1543,
- 1543, 1543, 1543, 1543, 1543, 1543, 1543, 1543,
-
- 1293, 1544, 1544, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1293, 1293, 1293, 1293, 1293, 1293, 1293, 1293,
- 1293, 1293, 1293, 1293, 1293, 1293, 1293, 1293,
- 1293, 1293, 1293, 1293, 1293, 1293, 1293, 1293,
- 1293, 1293, 1293, 1293, 1293, 1293, 1293, 1293,
- 1293, 1293, 1544, 1544, 1544, 1544, 1544, 1544,
- 1544, 1544, 1544, 175, 175, 175, 175, 175,
- 1293, 1293, 1293, 1293, 1293, 1293, 1293, 1293,
- 1293, 175, 175, 175, 175, 175, 175, 175,
- 1544, 1544, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1151, 1151, 1151, 1151, 1151, 1151, 175, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 175, 175, 175,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1150, 1150, 1151,
- 1151, 1151, 1151, 1151, 1150, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 175, 1151, 1151,
- 1151, 1151, 1151, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 175,
- 1151, 175, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1150, 1151, 1150, 1151, 1150, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1150,
- 1151, 1150, 1150, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 175, 1151, 1151, 1151, 1151, 175, 175, 175,
-
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 175, 175,
- 1542, 1542, 1542, 1542, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 1151, 1151, 1151, 1151, 1151,
-
- 1545, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1545, 1151, 1151, 1151, 1545, 1151, 1545,
- 1151, 1545, 1151, 1545, 1151, 1151, 1151, 1545,
- 1151, 1151, 1151, 1151, 1151, 1151, 1545, 1545,
- 1151, 1151, 1151, 1151, 1545, 1151, 1545, 1545,
- 1151, 1151, 1151, 1151, 1545, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 175, 175, 175, 175, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 1151, 1151,
- 1151, 1151, 1151, 1151, 1151, 1151, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 1150, 1150, 1150, 1150,
- 1150, 1150, 1150, 1150, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
-
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 175, 175,
- 175, 175, 175, 175, 175, 175, 1546, 1546,
-
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
-
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
-
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
-
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1302, 1302, 1302,
- 1302, 1302, 1302, 1302, 1302, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
-
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1503, 1503,
- 1503, 1503, 1503, 1503, 1503, 1503, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
-
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
-
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1547, 1547,
- 1547, 1547, 1547, 1547, 1547, 1547, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
-
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1299, 1299,
- 1299, 1299, 1299, 1299, 1299, 1299, 1546, 1546,
-
- 1083, 1509, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1509, 1509, 1509, 1509, 1509, 1509, 1509, 1509,
- 1509, 1509, 1509, 1509, 1509, 1509, 1509, 1509,
- 1509, 1509, 1509, 1509, 1509, 1509, 1509, 1509,
- 1509, 1509, 1509, 1509, 1509, 1509, 1509, 1509,
- 1509, 1509, 1509, 1509, 1509, 1509, 1509, 1509,
- 1509, 1509, 1509, 1509, 1509, 1509, 1509, 1509,
- 1509, 1509, 1509, 1509, 1509, 1509, 1509, 1509,
- 1509, 1509, 1509, 1509, 1509, 1509, 1509, 1509,
- 1509, 1509, 1509, 1509, 1509, 1509, 1509, 1509,
- 1509, 1509, 1509, 1509, 1509, 1509, 1509, 1509,
- 1509, 1509, 1509, 1509, 1509, 1509, 1509, 1509,
- 1509, 1509, 1509, 1509, 1509, 1509, 1509, 1509,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
+ 735, 735, 735, 735, 735, 735, 735, 177,
+ 177, 177, 177, 737, 737, 737, 737, 737,
+ 737, 737, 737, 737, 737, 737, 737, 737,
+ 737, 737, 737, 737, 737, 737, 737, 737,
+
+ 737, 737, 737, 737, 737, 737, 737, 737,
+ 737, 737, 737, 737, 737, 737, 737, 737,
+ 737, 737, 737, 737, 737, 737, 737, 737,
+ 737, 737, 737, 737, 177, 177, 177, 177,
+
+ 1537, 1537, 1537, 1537, 1537, 1537, 1537, 1537,
+ 1537, 1537, 1537, 1537, 1537, 1537, 1537, 1537,
+ 1537, 1537, 1537, 1537, 1537, 1537, 1537, 1537,
+ 1537, 1537, 1537, 1537, 1537, 1537, 1537, 1537,
+
+ 1538, 1538, 1538, 1538, 1538, 1538, 1538, 1538,
+ 1538, 1538, 1538, 1538, 1538, 1538, 1538, 1538,
+ 1538, 1538, 1538, 1538, 1538, 1538, 1538, 1538,
+ 1538, 1538, 1538, 1538, 1538, 1538, 1538, 1538,
+
+ 1373, 1373, 1373, 1373, 1373, 1373, 1373, 1373,
+ 1373, 1373, 1373, 1373, 1373, 1373, 1377, 1377,
+ 1539, 1539, 1539, 1539, 1539, 1539, 1539, 1539,
+ 1539, 1539, 1539, 1539, 1539, 1539, 1539, 1539,
+
+ 1539, 1539, 1539, 1539, 1539, 1539, 1539, 1539,
+ 1539, 1539, 1539, 1539, 1539, 1539, 1539, 1539,
+ 1539, 1539, 1539, 1539, 1539, 1539, 1539, 1539,
+ 1539, 1539, 1539, 1539, 1539, 1539, 1539, 1539,
+
+ 1539, 1539, 1539, 1539, 1539, 1539, 1539, 1539,
+ 1539, 1539, 1539, 1376, 1376, 1376, 1372, 1372,
+ 1374, 1374, 1374, 1374, 1374, 1374, 1374, 1374,
+ 1374, 1374, 1374, 1374, 1374, 1374, 1374, 1374,
+
+ 1374, 1374, 1374, 1374, 1374, 1374, 1374, 1374,
+ 1374, 1374, 1374, 1374, 1374, 1374, 1374, 1374,
+ 1374, 1374, 1374, 1374, 1374, 1374, 1374, 1374,
+ 1374, 1374, 1374, 1374, 1374, 1374, 1374, 1374,
+
+ 1374, 1374, 1374, 1374, 1374, 1374, 1374, 1374,
+ 1374, 1374, 1374, 1374, 1374, 1374, 1374, 1374,
+ 1374, 1374, 1374, 1374, 1374, 1374, 1374, 1374,
+ 1374, 1374, 1372, 1372, 1372, 1372, 1372, 1372,
+
+ 1540, 1541, 1542, 1543, 1544, 1545, 1545, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 1546, 1547, 1548, 1549, 1550,
+ 177, 177, 177, 177, 177, 1551, 1552, 283,
+
+ 283, 283, 283, 283, 283, 283, 283, 283,
+ 283, 1553, 283, 283, 283, 283, 283, 283,
+ 283, 283, 283, 283, 283, 283, 283, 256,
+ 283, 283, 283, 283, 283, 256, 283, 256,
+
+ 283, 283, 256, 283, 283, 256, 283, 283,
+ 283, 283, 283, 283, 283, 283, 283, 283,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 1554, 1554, 1554, 1554, 1554, 1554,
+ 1554, 1554, 1554, 1554, 1554, 1554, 1554, 1554,
+
+ 1554, 1554, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 1105, 1331,
+
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 288, 288, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 1555, 1555, 1555, 1555, 1555, 1555, 1555, 1555,
+ 1555, 1555, 1555, 1555, 1555, 1555, 1555, 1555,
+
+ 1555, 1555, 1555, 1555, 1555, 1555, 1555, 1555,
+ 1555, 1555, 1555, 1555, 1555, 1555, 1555, 1555,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 1556, 1177, 288, 288,
+
+ 1557, 1557, 1557, 1557, 1557, 1557, 1557, 1557,
+ 1557, 1557, 1557, 1557, 1557, 1557, 1557, 1557,
+ 1558, 1559, 1560, 1561, 1562, 1563, 1563, 1564,
+ 1565, 1566, 177, 177, 177, 177, 177, 177,
+
+ 153, 153, 153, 153, 981, 981, 981, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1326, 1567, 1567, 1568, 1568, 1105, 1331, 1105,
+ 1331, 1105, 1331, 1105, 1331, 1105, 1331, 1105,
+
+ 1331, 1105, 1331, 1105, 1331, 1341, 1341, 1569,
+ 1570, 1326, 1326, 1326, 1326, 1568, 1568, 1568,
+ 1571, 1572, 1573, 177, 1574, 1575, 9, 9,
+ 1567, 16, 1124, 16, 1124, 16, 1124, 1576,
+
+ 1326, 1326, 1577, 1578, 1579, 1580, 1581, 177,
+ 1326, 12, 13, 1326, 177, 177, 177, 177,
+ 304, 304, 304, 1582, 304, 288, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 304, 304, 304,
+ 304, 304, 304, 304, 304, 288, 288, 1583,
+
+ 177, 9, 1326, 1576, 12, 13, 1326, 1584,
+ 16, 1124, 1326, 1577, 1571, 1578, 1573, 1585,
+ 1586, 1587, 1588, 1589, 1590, 1591, 1592, 1593,
+ 1594, 1595, 1575, 1574, 1596, 1581, 1597, 9,
+
+ 1326, 1598, 1598, 1598, 1598, 1598, 1598, 1598,
+ 1598, 1598, 1598, 1598, 1598, 1598, 1598, 1598,
+ 1598, 1598, 1598, 1598, 1598, 1598, 1598, 1598,
+ 1598, 1598, 1598, 39, 1326, 46, 1599, 1568,
+
+ 1599, 1600, 1600, 1600, 1600, 1600, 1600, 1600,
+ 1600, 1600, 1600, 1600, 1600, 1600, 1600, 1600,
+ 1600, 1600, 1600, 1600, 1600, 1600, 1600, 1600,
+ 1600, 1600, 1600, 39, 1581, 46, 1581, 1245,
+
+ 1246, 1325, 16, 1124, 1324, 1352, 1601, 1350,
+ 1350, 1350, 1350, 1350, 1350, 1350, 1350, 1350,
+ 1353, 1601, 1601, 1601, 1601, 1601, 1601, 1601,
+ 1601, 1601, 1601, 1601, 1601, 1601, 1601, 1601,
+
+ 1601, 1601, 1601, 1601, 1601, 1601, 1601, 1601,
+ 1601, 1601, 1601, 1601, 1601, 1601, 1601, 1601,
+ 1601, 1601, 1601, 1601, 1601, 1601, 1601, 1601,
+ 1601, 1601, 1601, 1601, 1601, 1601, 1602, 1602,
+
+ 1603, 1603, 1603, 1603, 1603, 1603, 1603, 1603,
+ 1603, 1603, 1603, 1603, 1603, 1603, 1603, 1603,
+ 1603, 1603, 1603, 1603, 1603, 1603, 1603, 1603,
+ 1603, 1603, 1603, 1603, 1603, 1603, 1603, 177,
+
+ 177, 177, 1603, 1603, 1603, 1603, 1603, 1603,
+ 177, 177, 1603, 1603, 1603, 1603, 1603, 1603,
+ 177, 177, 1603, 1603, 1603, 1603, 1603, 1603,
+ 177, 177, 1603, 1603, 1603, 177, 177, 177,
+
+ 50, 12, 1581, 1599, 1206, 12, 12, 177,
+ 51, 36, 36, 36, 36, 51, 51, 177,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1604, 1604, 1604, 1605, 51, 1606, 1606,
+
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+ 1607, 1607, 1607, 1607, 177, 1607, 1607, 1607,
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 177,
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+ 1607, 1607, 1607, 177, 1607, 1607, 177, 1607,
+
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+ 1607, 1607, 1607, 1607, 1607, 1607, 177, 177,
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+ 1607, 1607, 1607, 1607, 1607, 1607, 177, 177,
+
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+ 1607, 1607, 1607, 1607, 1607, 1607, 1607, 1607,
+ 1607, 1607, 1607, 177, 177, 177, 177, 177,
+
+ 1608, 1609, 1608, 177, 177, 177, 177, 1610,
+ 1610, 1610, 1610, 1610, 1610, 1610, 1610, 1610,
+ 1610, 1610, 1610, 1610, 1610, 1610, 1610, 1610,
+ 1610, 1610, 1610, 1610, 1610, 1610, 1610, 1610,
+
+ 1610, 1610, 1610, 1610, 1610, 1610, 1610, 1610,
+ 1610, 1610, 1610, 1610, 1610, 1610, 1610, 1610,
+ 1610, 1610, 1610, 1610, 177, 177, 177, 1611,
+ 1611, 1611, 1611, 1611, 1611, 1611, 1611, 1611,
+
+ 1612, 1612, 1612, 1612, 1612, 1612, 1612, 1612,
+ 1612, 1612, 1612, 1612, 1612, 1612, 1612, 1612,
+ 1612, 1612, 1612, 1612, 1612, 1612, 1612, 1612,
+ 1612, 1612, 1612, 1612, 1612, 1612, 1612, 1612,
+
+ 1612, 1612, 1612, 1612, 1612, 1612, 1612, 1612,
+ 1612, 1612, 1612, 1612, 1612, 1612, 1612, 1612,
+ 1612, 1612, 1612, 1612, 1612, 1613, 1613, 1613,
+ 1613, 1614, 1614, 1614, 1614, 1614, 1614, 1614,
+
+ 1614, 1614, 1614, 1614, 1614, 1614, 1614, 1614,
+ 1614, 1614, 1613, 177, 177, 177, 177, 177,
+ 1239, 1239, 1239, 1239, 1239, 1239, 1239, 1239,
+ 1239, 1239, 1239, 1239, 177, 177, 177, 177,
+
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1185, 1185, 1185, 1185, 1185, 1185, 1185, 1185,
+ 1185, 1185, 1185, 1185, 1185, 1185, 1185, 1185,
+
+ 1185, 1185, 1185, 1185, 1185, 1185, 1185, 1185,
+ 1185, 1185, 1185, 1185, 1185, 1185, 1185, 1185,
+ 1185, 1185, 1185, 1185, 1185, 1185, 1185, 1185,
+ 1185, 1185, 1185, 1185, 1185, 984, 177, 177,
+
+ 1615, 1615, 1615, 1615, 1615, 1615, 1615, 1615,
+ 1615, 1615, 1615, 1615, 1615, 1615, 1615, 1615,
+ 1615, 1615, 1615, 1615, 1615, 1615, 1615, 1615,
+ 1615, 1615, 1615, 1615, 1615, 177, 177, 177,
+
+ 1616, 1616, 1616, 1616, 1616, 1616, 1616, 1616,
+ 1616, 1616, 1616, 1616, 1616, 1616, 1616, 1616,
+ 1616, 1616, 1616, 1616, 1616, 1616, 1616, 1616,
+ 1616, 1616, 1616, 1616, 1616, 1616, 1616, 1616,
+
+ 1616, 1616, 1616, 1616, 1616, 1616, 1616, 1616,
+ 1616, 1616, 1616, 1616, 1616, 1616, 1616, 1616,
+ 1616, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1617, 1617, 1617, 1617, 1617, 1617, 1617, 1617,
+ 1617, 1617, 1617, 1617, 1617, 1617, 1617, 1617,
+ 1617, 1617, 1617, 1617, 1617, 1617, 1617, 1617,
+ 1617, 1617, 1617, 1617, 1617, 1617, 1617, 177,
+
+ 1618, 1618, 1618, 1618, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1619, 1619, 1619, 1619, 1619, 1619, 1619, 1619,
+ 1619, 1619, 1619, 1619, 1619, 1619, 1619, 1619,
+
+ 1619, 1620, 1619, 1619, 1619, 1619, 1619, 1619,
+ 1619, 1619, 1620, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1621, 1621, 1621, 1621, 1621, 1621, 1621, 1621,
+ 1621, 1621, 1621, 1621, 1621, 1621, 1621, 1621,
+ 1621, 1621, 1621, 1621, 1621, 1621, 1621, 1621,
+ 1621, 1621, 1621, 1621, 1621, 1621, 177, 1622,
+
+ 1623, 1623, 1623, 1623, 1623, 1623, 1623, 1623,
+ 1623, 1623, 1623, 1623, 1623, 1623, 1623, 1623,
+ 1623, 1623, 1623, 1623, 1623, 1623, 1623, 1623,
+ 1623, 1623, 1623, 1623, 1623, 1623, 1623, 1623,
+
+ 1623, 1623, 1623, 1623, 177, 177, 177, 177,
+ 1623, 1623, 1623, 1623, 1623, 1623, 1623, 1623,
+ 1624, 1625, 1625, 1625, 1625, 1625, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1626, 1626, 1626, 1626, 1626, 1626, 1626, 1626,
+ 1626, 1626, 1626, 1626, 1626, 1626, 1626, 1626,
+ 1626, 1626, 1626, 1626, 1626, 1626, 1626, 1626,
+ 1626, 1626, 1626, 1626, 1626, 1626, 1626, 1626,
+
+ 1626, 1626, 1626, 1626, 1626, 1626, 1627, 1627,
+ 1628, 1628, 1628, 1628, 1628, 1628, 1628, 1628,
+ 1628, 1628, 1628, 1628, 1628, 1628, 1628, 1628,
+ 1628, 1628, 1628, 1628, 1628, 1628, 1628, 1628,
+
+ 1628, 1628, 1628, 1628, 1628, 1628, 1628, 1628,
+ 1628, 1628, 1628, 1628, 1628, 1628, 1629, 1629,
+ 1630, 1630, 1630, 1630, 1630, 1630, 1630, 1630,
+ 1630, 1630, 1630, 1630, 1630, 1630, 1630, 1630,
+
+ 1630, 1630, 1630, 1630, 1630, 1630, 1630, 1630,
+ 1630, 1630, 1630, 1630, 1630, 1630, 1630, 1630,
+ 1630, 1630, 1630, 1630, 1630, 1630, 1630, 1630,
+ 1630, 1630, 1630, 1630, 1630, 1630, 1630, 1630,
+
+ 1631, 1631, 1631, 1631, 1631, 1631, 1631, 1631,
+ 1631, 1631, 1631, 1631, 1631, 1631, 1631, 1631,
+ 1631, 1631, 1631, 1631, 1631, 1631, 1631, 1631,
+ 1631, 1631, 1631, 1631, 1631, 1631, 177, 177,
+
+ 1632, 1633, 1634, 1635, 1636, 1637, 1638, 1639,
+ 1640, 1641, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1642, 1642, 1642, 1642, 1642, 1642, 256, 256,
+ 1642, 256, 1642, 1642, 1642, 1642, 1642, 1642,
+ 1642, 1642, 1642, 1642, 1642, 1642, 1642, 1642,
+ 1642, 1642, 1642, 1642, 1642, 1642, 1642, 1642,
+
+ 1642, 1642, 1642, 1642, 1642, 1642, 1642, 1642,
+ 1642, 1642, 1642, 1642, 1642, 1642, 1642, 1642,
+ 1642, 1642, 1642, 1642, 1642, 1642, 256, 1642,
+ 1642, 256, 256, 256, 1642, 256, 256, 1642,
+
+ 1643, 1643, 1643, 1643, 1643, 1643, 1643, 1643,
+ 1643, 1643, 1643, 1643, 1643, 1643, 1643, 1643,
+ 1643, 1643, 1643, 1643, 1643, 1643, 256, 1644,
+ 1645, 1645, 1645, 1645, 1645, 1645, 1645, 1645,
+
+ 1646, 1646, 1646, 1646, 1646, 1646, 1646, 1646,
+ 1646, 1646, 1646, 1646, 1646, 1646, 1646, 1646,
+ 1646, 1646, 1646, 1646, 1646, 1646, 1647, 1647,
+ 1647, 1647, 1648, 1648, 256, 256, 256, 1649,
+
+ 1650, 1650, 1650, 1650, 1650, 1650, 1650, 1650,
+ 1650, 1650, 1650, 1650, 1650, 1650, 1650, 1650,
+ 1650, 1650, 1650, 1650, 1650, 1650, 1650, 1650,
+ 1650, 1650, 256, 256, 256, 256, 256, 1651,
+
+ 1652, 1652, 1652, 1652, 1652, 1652, 1652, 1652,
+ 1652, 1652, 1652, 1652, 1652, 1652, 1652, 1652,
+ 1652, 1652, 1652, 1652, 1652, 1652, 1652, 1652,
+ 1652, 1652, 1652, 1652, 1652, 1652, 1652, 1652,
+
+ 1653, 1653, 1653, 1653, 1653, 1653, 1653, 1653,
+ 1653, 1653, 1653, 1653, 1653, 1653, 1653, 1653,
+ 1653, 1653, 1653, 1653, 1653, 1653, 1653, 1653,
+ 256, 256, 256, 256, 256, 256, 1653, 1653,
+
+ 1654, 1655, 1655, 1655, 256, 1655, 1655, 256,
+ 256, 256, 256, 256, 1655, 1656, 1655, 1657,
+ 1654, 1654, 1654, 1654, 256, 1654, 1654, 1654,
+ 256, 1654, 1654, 1654, 1654, 1654, 1654, 1654,
+
+ 1654, 1654, 1654, 1654, 1654, 1654, 1654, 1654,
+ 1654, 1654, 1654, 1654, 1654, 1654, 1654, 1654,
+ 1654, 1654, 1654, 1654, 256, 256, 256, 256,
+ 1657, 1658, 1656, 256, 256, 256, 256, 1659,
+
+ 1660, 1661, 1662, 1663, 1664, 1664, 1664, 1664,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 1665, 1665, 1665, 1665, 1665, 1665, 1666, 1666,
+ 1667, 256, 256, 256, 256, 256, 256, 256,
+
+ 1668, 1668, 1668, 1668, 1668, 1668, 1668, 1668,
+ 1668, 1668, 1668, 1668, 1668, 1668, 1668, 1668,
+ 1668, 1668, 1668, 1668, 1668, 1668, 1668, 1668,
+ 1668, 1668, 1668, 1668, 1668, 1669, 1669, 1670,
+
+ 1671, 1671, 1671, 1671, 1671, 1671, 1671, 1671,
+ 1671, 1671, 1671, 1671, 1671, 1671, 1671, 1671,
+ 1671, 1671, 1671, 1671, 1671, 1671, 1671, 1671,
+ 1671, 1671, 1671, 1671, 1671, 1671, 1671, 1671,
+
+ 1671, 1671, 1671, 1671, 1671, 1671, 1671, 1671,
+ 1671, 1671, 1671, 1671, 1671, 1671, 1671, 1671,
+ 1671, 1671, 1671, 1671, 1671, 1671, 256, 256,
+ 256, 1672, 1672, 1672, 1672, 1672, 1672, 1672,
+
+ 1673, 1673, 1673, 1673, 1673, 1673, 1673, 1673,
+ 1673, 1673, 1673, 1673, 1673, 1673, 1673, 1673,
+ 1673, 1673, 1673, 1673, 1673, 1673, 256, 256,
+ 1674, 1674, 1674, 1674, 1674, 1674, 1674, 1674,
+
+ 1675, 1675, 1675, 1675, 1675, 1675, 1675, 1675,
+ 1675, 1675, 1675, 1675, 1675, 1675, 1675, 1675,
+ 1675, 1675, 1675, 256, 256, 256, 256, 256,
+ 1676, 1676, 1676, 1676, 1676, 1676, 1676, 1676,
+
+ 1677, 1677, 1677, 1677, 1677, 1677, 1677, 1677,
+ 1677, 1677, 1677, 1677, 1677, 1677, 1677, 1677,
+ 1677, 1677, 1677, 1677, 1677, 1677, 1677, 1677,
+ 1677, 1677, 1677, 1677, 1677, 1677, 1677, 1677,
+
+ 1677, 1677, 1677, 1677, 1677, 1677, 1677, 1677,
+ 1677, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+
+ 1678, 1679, 1680, 1681, 1682, 1683, 1684, 1685,
+ 1686, 1687, 1687, 1687, 1687, 1687, 1687, 1687,
+ 1687, 1687, 1687, 1687, 1687, 1687, 1687, 1687,
+ 1687, 1687, 1687, 1687, 1687, 1687, 1687, 256,
+
+ 1688, 1689, 1688, 1690, 1690, 1690, 1690, 1690,
+ 1690, 1690, 1690, 1690, 1690, 1690, 1690, 1690,
+ 1690, 1690, 1690, 1690, 1690, 1690, 1690, 1690,
+ 1690, 1690, 1690, 1690, 1690, 1690, 1690, 1690,
+ 1690, 1690, 1690, 1690, 1690, 1690, 1690, 1690,
+ 1690, 1690, 1690, 1690, 1690, 1690, 1690, 1690,
+ 1690, 1690, 1690, 1690, 1690, 1690, 1690, 1690,
+ 1689, 1689, 1689, 1689, 1689, 1689, 1689, 1689,
+ 1689, 1689, 1689, 1689, 1689, 1689, 1691, 1692,
+ 1692, 1693, 1693, 1693, 1693, 1693, 177, 177,
+ 177, 177, 1694, 1695, 1696, 1697, 1698, 1699,
+ 1700, 1701, 1702, 1703, 1703, 1703, 1703, 1703,
+ 1703, 1703, 1703, 1703, 1703, 1703, 1704, 1705,
+ 1706, 1707, 1708, 1709, 1710, 1711, 1712, 1713,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1714, 1714, 1715, 1716, 1716, 1716, 1716, 1716,
+ 1716, 1716, 1716, 1716, 1716, 1716, 1716, 1716,
+ 1716, 1716, 1716, 1716, 1716, 1716, 1716, 1716,
+ 1716, 1716, 1716, 1716, 1716, 1716, 1716, 1716,
+ 1716, 1716, 1716, 1716, 1716, 1716, 1716, 1716,
+ 1716, 1716, 1716, 1716, 1716, 1716, 1716, 1716,
+ 1715, 1715, 1715, 1714, 1714, 1714, 1714, 1715,
+ 1715, 1717, 1718, 1719, 1719, 1720, 1721, 1721,
+ 1721, 1721, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1722, 1722, 1722, 1722, 1722, 1722, 1722, 1722,
+ 1722, 1722, 1722, 1722, 1722, 1722, 1722, 1722,
+ 1722, 1722, 1722, 1722, 1722, 1722, 1722, 1722,
+ 1722, 177, 177, 177, 177, 177, 177, 177,
+ 1723, 1724, 1725, 1726, 1727, 1728, 1729, 1730,
+ 1731, 1732, 177, 177, 177, 177, 177, 177,
+
+ 1733, 1733, 1733, 1734, 1734, 1734, 1734, 1734,
+ 1734, 1734, 1734, 1734, 1734, 1734, 1734, 1734,
+ 1734, 1734, 1734, 1734, 1734, 1734, 1734, 1734,
+ 1734, 1734, 1734, 1734, 1734, 1734, 1734, 1734,
+ 1734, 1734, 1734, 1734, 1734, 1734, 1734, 1735,
+ 1735, 1735, 1735, 1735, 1736, 1735, 1735, 1735,
+ 1735, 1735, 1735, 1737, 1737, 177, 1738, 1739,
+ 1740, 1741, 1742, 1743, 1744, 1745, 1746, 1747,
+ 1748, 1749, 1749, 1749, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1750, 1750, 1751, 1752, 1752, 1752, 1752, 1752,
+ 1752, 1752, 1752, 1752, 1752, 1752, 1752, 1752,
+ 1752, 1752, 1752, 1752, 1752, 1752, 1752, 1752,
+ 1752, 1752, 1752, 1752, 1752, 1752, 1752, 1752,
+ 1752, 1752, 1752, 1752, 1752, 1752, 1752, 1752,
+ 1752, 1752, 1752, 1752, 1752, 1752, 1752, 1752,
+ 1752, 1752, 1752, 1751, 1751, 1751, 1750, 1750,
+ 1750, 1750, 1750, 1750, 1750, 1750, 1750, 1751,
+ 1753, 1752, 1752, 1752, 1752, 1754, 1754, 1755,
+ 1756, 177, 177, 177, 177, 177, 177, 177,
+ 1757, 1758, 1759, 1760, 1761, 1762, 1763, 1764,
+ 1765, 1766, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1767, 1767, 1767, 1767, 1767, 1767, 1767, 1767,
+ 1767, 1767, 1767, 1767, 1767, 1767, 1767, 1767,
+ 1767, 1767, 1767, 1767, 1767, 1767, 1767, 1767,
+ 1767, 1767, 1767, 1767, 1767, 1767, 1767, 1767,
+ 1767, 1767, 1767, 1767, 1767, 1767, 1767, 1767,
+ 1767, 1767, 1767, 1768, 1769, 1768, 1769, 1769,
+ 1768, 1768, 1768, 1768, 1768, 1768, 1770, 1771,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1772, 1773, 1774, 1775, 1776, 1777, 1778, 1779,
+ 1780, 1781, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 1782,
+ 1782, 1782, 1782, 1782, 1782, 1782, 1782, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1783, 1783, 1783, 1783, 1783, 1783, 1783, 1783,
+ 1783, 1783, 1783, 1783, 1783, 1783, 1783, 1783,
+ 1783, 1783, 1783, 1783, 1783, 1783, 1783, 1783,
+ 1783, 1783, 1783, 1783, 1783, 1783, 1783, 1783,
+ 1783, 1783, 1783, 1783, 1783, 1783, 1783, 1783,
+ 1783, 1783, 1783, 1783, 1783, 1783, 1783, 1783,
+ 1783, 1783, 1783, 1783, 1783, 1783, 1783, 1783,
+ 1783, 1783, 1783, 1783, 1783, 1783, 1783, 1783,
+ 1783, 1783, 1783, 1783, 1783, 1783, 1783, 1783,
+ 1783, 1783, 1783, 1783, 1783, 1783, 1783, 1783,
+ 1783, 1783, 1783, 1783, 1783, 1783, 1783, 1783,
+ 1783, 1783, 1783, 1783, 1783, 1783, 1783, 1783,
+ 1783, 1783, 1783, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1784, 1784, 1784, 1784, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1786, 1786, 1786, 1787, 1787, 1787, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1787, 1785, 1785, 1785, 1786, 1787,
+ 1786, 1787, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1786, 1787, 1787, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 1785,
+ 1785, 1785, 1785, 1785, 1785, 1785, 1785, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 1788, 1788, 1788, 1788, 1788, 1788, 1788,
+ 1788, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1789, 1789, 1789, 1789, 1789, 1789, 1789, 1789,
+ 1789, 1789, 1789, 1789, 1789, 1789, 1789, 1789,
+ 1789, 1789, 1789, 1789, 1789, 1789, 1789, 1789,
+ 1789, 1789, 1789, 1789, 1789, 1789, 1789, 1789,
+ 1789, 1789, 1789, 1789, 1789, 1789, 1789, 1789,
+ 1789, 1789, 1789, 1789, 1789, 1789, 1789, 1789,
+ 1789, 1789, 1789, 1789, 1789, 1789, 1789, 1789,
+ 1789, 1789, 1789, 1789, 1789, 1789, 1789, 1789,
+ 1789, 1789, 1789, 1789, 1789, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1789, 1790, 1790, 1790, 1790, 1790, 1790, 1790,
+ 1790, 1790, 1790, 1790, 1790, 1790, 1790, 1790,
+ 1790, 1790, 1790, 1790, 1790, 1790, 1790, 1790,
+ 1790, 1790, 1790, 1790, 1790, 1790, 1790, 1790,
+ 1790, 1790, 1790, 1790, 1790, 1790, 1790, 1790,
+ 1790, 1790, 1790, 1790, 1790, 1790, 1790, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 1791,
+ 1791, 1791, 1791, 1792, 1792, 1792, 1792, 1792,
+ 1792, 1792, 1792, 1792, 1792, 1792, 1792, 1792,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1793, 1794, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 177,
+ 177, 1185, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1796, 1797, 1798,
+ 1798, 1798, 1795, 1795, 1795, 1799, 1796, 1796,
+ 1796, 1796, 1796, 1800, 1800, 1800, 1800, 1800,
+ 1800, 1800, 1800, 1801, 1801, 1801, 1801, 1801,
+ 1801, 1801, 1801, 1795, 1795, 1802, 1802, 1802,
+ 1802, 1802, 1801, 1801, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1802, 1802, 1802, 1802, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 1795, 1795,
+ 1795, 1795, 1795, 1795, 1795, 1795, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1614, 1614, 1614, 1614, 1614, 1614, 1614, 1614,
+ 1614, 1614, 1614, 1614, 1614, 1614, 1614, 1614,
+ 1614, 1614, 1614, 1614, 1614, 1614, 1614, 1614,
+ 1614, 1614, 1614, 1614, 1614, 1614, 1614, 1614,
+ 1614, 1614, 1614, 1614, 1614, 1614, 1614, 1614,
+ 1614, 1614, 1614, 1614, 1614, 1614, 1614, 1614,
+ 1614, 1614, 1614, 1614, 1614, 1614, 1614, 1614,
+ 1614, 1614, 1614, 1614, 1614, 1614, 1614, 1614,
+ 1614, 1614, 1803, 1803, 1803, 1614, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1548, 1548, 1548, 1548, 1548, 1548, 1548, 1548,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
-
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
- 1083, 1083, 1083, 1083, 1083, 1083, 1083, 1083,
-
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
-
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1549, 1549,
- 1549, 1549, 1549, 1549, 1549, 1549, 1546, 1546,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 1177,
+ 1177, 1177, 1177, 1177, 1177, 1177, 1177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1804, 1804, 1804, 1804, 1804, 1804, 1804, 1804,
+ 1804, 1804, 1804, 1804, 1804, 1804, 1804, 1804,
+ 1804, 1804, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 177, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1805, 177, 1805, 1805,
+ 177, 177, 1805, 177, 177, 1805, 1805, 177,
+ 177, 1805, 1805, 1805, 1805, 177, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1806, 1806,
+ 1806, 1806, 177, 1806, 177, 1806, 1806, 1806,
+ 1806, 1807, 1806, 1806, 177, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+
+ 1806, 1806, 1806, 1806, 1805, 1805, 177, 1805,
+ 1805, 1805, 1805, 177, 177, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 177, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 177, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1805, 1805, 177, 1805, 1805, 1805, 1805, 177,
+ 1805, 1805, 1805, 1805, 1805, 177, 1805, 177,
+ 177, 177, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 177, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1178, 1178, 177, 177,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1808, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1809, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1808, 1806, 1806, 1806, 1806,
+
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1809, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1808, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1809,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1808,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1809, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1805, 1805, 1805, 1805, 1805, 1805, 1805,
+ 1805, 1808, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1806, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1806, 1809, 1806, 1806, 1806, 1806,
+ 1806, 1806, 1810, 1811, 177, 177, 1812, 1813,
+ 1814, 1815, 1816, 1817, 1818, 1819, 1820, 1821,
+ 1812, 1813, 1814, 1815, 1816, 1817, 1818, 1819,
+ 1820, 1821, 1812, 1813, 1814, 1815, 1816, 1817,
+ 1818, 1819, 1820, 1821, 1812, 1813, 1814, 1815,
+ 1816, 1817, 1818, 1819, 1820, 1821, 1812, 1813,
+ 1814, 1815, 1816, 1817, 1818, 1819, 1820, 1821,
+
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+ 256, 256, 256, 256, 256, 256, 256, 256,
+
+ 1822, 1822, 1822, 1822, 288, 1822, 1822, 1822,
+ 1822, 1822, 1822, 1822, 1822, 1822, 1822, 1822,
+ 1822, 1822, 1822, 1822, 1822, 1822, 1822, 1822,
+ 1822, 1822, 1822, 1822, 1822, 1822, 1822, 1822,
+ 288, 1822, 1822, 288, 1822, 288, 288, 1822,
+ 288, 1822, 1822, 1822, 1822, 1822, 1822, 1822,
+ 1822, 1822, 1822, 288, 1822, 1822, 1822, 1822,
+ 288, 1822, 288, 1822, 288, 288, 288, 288,
+ 288, 288, 1822, 288, 288, 288, 288, 1822,
+ 288, 1822, 288, 1822, 288, 1822, 1822, 1822,
+ 288, 1822, 1822, 288, 1822, 288, 288, 1822,
+ 288, 1822, 288, 1822, 288, 1822, 288, 1822,
+ 288, 1822, 1822, 288, 1822, 288, 288, 1822,
+ 1822, 1822, 1822, 288, 1822, 1822, 1822, 1822,
+ 1822, 1822, 1822, 288, 1822, 1822, 1822, 1822,
+ 288, 1822, 1822, 1822, 1822, 288, 1822, 288,
+ 1822, 1822, 1822, 1822, 1822, 1822, 1822, 1822,
+ 1822, 1822, 288, 1822, 1822, 1822, 1822, 1822,
+ 1822, 1822, 1822, 1822, 1822, 1822, 1822, 1822,
+ 1822, 1822, 1822, 1822, 288, 288, 288, 288,
+ 288, 1822, 1822, 1822, 288, 1822, 1822, 1822,
+ 1822, 1822, 288, 1822, 1822, 1822, 1822, 1822,
+ 1822, 1822, 1822, 1822, 1822, 1822, 1822, 1822,
+ 1822, 1822, 1822, 1822, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+ 1823, 1823, 288, 288, 288, 288, 288, 288,
+ 288, 288, 288, 288, 288, 288, 288, 288,
+
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 177, 177, 177, 177,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 1242, 1242, 1242, 1242,
+ 1242, 1242, 1242, 1242, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 177,
+ 177, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 177,
+ 177, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 177, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1824, 1824, 1825, 1826, 1827, 1828, 1829, 1830,
+ 1831, 1832, 1833, 177, 177, 177, 177, 177,
+ 685, 685, 685, 685, 685, 685, 685, 685,
+ 685, 685, 685, 685, 685, 685, 685, 685,
+ 685, 685, 685, 685, 685, 685, 685, 685,
+ 685, 685, 685, 685, 685, 685, 685, 177,
+ 1834, 685, 1834, 1834, 1834, 1834, 1834, 1834,
+ 1834, 1834, 1834, 1834, 1834, 685, 1834, 685,
+ 1834, 1834, 685, 1834, 1834, 1834, 685, 1834,
+ 1834, 1834, 685, 685, 685, 685, 685, 1834,
+ 1834, 1834, 1834, 1834, 1834, 1834, 1834, 685,
+ 1834, 1834, 1834, 1834, 1834, 1834, 1834, 685,
+ 1834, 1834, 1834, 1834, 1834, 1834, 1834, 1834,
+ 1834, 1834, 1835, 1835, 177, 177, 177, 177,
+ 1834, 1834, 1834, 1834, 1834, 1834, 1834, 1834,
+ 1834, 685, 1834, 685, 685, 1834, 1834, 685,
+ 1834, 1834, 1834, 1834, 1834, 1834, 1834, 1834,
+ 1834, 1834, 685, 685, 685, 685, 1834, 1834,
+ 685, 1834, 1834, 1834, 1834, 1834, 1834, 1834,
+ 1834, 1834, 1834, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 1836, 1836,
+ 1836, 1836, 1836, 1836, 1836, 1836, 1836, 1836,
+ 1836, 1836, 1836, 1836, 1836, 1836, 1836, 1836,
+ 1836, 1836, 1836, 1836, 1836, 1836, 1836, 1836,
+
+ 1837, 1838, 1838, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1366, 1366, 1366, 1366, 1366, 1366, 1366, 1366,
+ 1366, 1366, 1366, 1366, 1366, 1366, 1366, 1366,
+ 1366, 1366, 1366, 1366, 1366, 1366, 1366, 1366,
+ 1366, 1366, 1366, 1366, 1366, 1366, 1366, 1366,
+ 1366, 1366, 1838, 1838, 1838, 1838, 1838, 1838,
+ 1838, 1838, 1838, 177, 177, 177, 177, 177,
+ 1366, 1366, 1366, 1366, 1366, 1366, 1366, 1366,
+ 1366, 177, 177, 177, 177, 177, 177, 177,
+ 1838, 1838, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1212, 1212, 1212, 1212, 1212, 1212, 177, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 177, 177, 177,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1211, 1211, 1212,
+ 1212, 1212, 1212, 1212, 1211, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 177, 1212, 1212,
+ 1212, 1212, 1212, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 177,
+ 1212, 177, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1211, 1212, 1211, 1212, 1211, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1211,
+ 1212, 1211, 1211, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 177, 1212, 1212, 1212, 1212, 177, 177, 177,
+
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 177, 177,
+ 1835, 1835, 1835, 1835, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 1212, 1212, 1212, 1212, 1212,
+
+ 1839, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1839, 1212, 1212, 1212, 1839, 1212, 1839,
+ 1212, 1839, 1212, 1839, 1212, 1212, 1212, 1839,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1839, 1839,
+ 1212, 1212, 1212, 1212, 1839, 1212, 1839, 1839,
+ 1212, 1212, 1212, 1212, 1839, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 177, 177, 177, 177, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 1212, 1212,
+ 1212, 1212, 1212, 1212, 1212, 1212, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 1211, 1211, 1211, 1211,
+ 1211, 1211, 1211, 1211, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 177, 177,
+ 177, 177, 177, 177, 177, 177, 1840, 1840,
+
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1376, 1376, 1376,
+ 1376, 1376, 1376, 1376, 1376, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1842, 1842,
+ 1842, 1842, 1842, 1842, 1842, 1842, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1841, 1841,
+ 1841, 1841, 1841, 1841, 1841, 1841, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1372, 1372,
+ 1372, 1372, 1372, 1372, 1372, 1372, 1840, 1840,
+
+ 1138, 1800, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1800, 1800, 1800, 1800, 1800, 1800, 1800, 1800,
+ 1800, 1800, 1800, 1800, 1800, 1800, 1800, 1800,
+ 1800, 1800, 1800, 1800, 1800, 1800, 1800, 1800,
+ 1800, 1800, 1800, 1800, 1800, 1800, 1800, 1800,
+ 1800, 1800, 1800, 1800, 1800, 1800, 1800, 1800,
+ 1800, 1800, 1800, 1800, 1800, 1800, 1800, 1800,
+ 1800, 1800, 1800, 1800, 1800, 1800, 1800, 1800,
+ 1800, 1800, 1800, 1800, 1800, 1800, 1800, 1800,
+ 1800, 1800, 1800, 1800, 1800, 1800, 1800, 1800,
+ 1800, 1800, 1800, 1800, 1800, 1800, 1800, 1800,
+ 1800, 1800, 1800, 1800, 1800, 1800, 1800, 1800,
+ 1800, 1800, 1800, 1800, 1800, 1800, 1800, 1800,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1843, 1843, 1843, 1843, 1843, 1843, 1843, 1843,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+ 1138, 1138, 1138, 1138, 1138, 1138, 1138, 1138,
+
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1844, 1844,
+ 1844, 1844, 1844, 1844, 1844, 1844, 1840, 1840,
};
#define GET_PROP_INDEX(ucs4) \
@@ -4775,488 +4835,427 @@ static const unsigned short uc_property_trie[] = {
(uc_property_trie[uc_property_trie[ucs2>>5] + (ucs2 & 0x1f)])
static const Properties uc_properties[] = {
- { 9, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0, 0, 21, 0 },
- { 9, 8, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0, 5, 17, 0 },
- { 9, 7, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 2, 2, 34, 0 },
- { 9, 8, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 3, 5, 35, 0 },
- { 9, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 3, 5, 35, 0 },
- { 9, 7, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 33, 0 },
- { 9, 7, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0, 0, 21, 0 },
- { 9, 8, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0, 0, 21, 0 },
- { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 5, 32, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 6, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 0 },
- { 25, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 9, 0 },
- { 25, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 8, 13, 3, 0 },
- { 21, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 0, 0 },
- { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 2, 0 },
- { 26, 3, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 9, 0 },
- { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 11, 8, 0 },
- { 20, 3, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 16, 0 },
- { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 10, 8, 0 },
- { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 7, 0 },
- { 3, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 8, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 0, 8, 0 },
- { 26, 10, 0, 0, -1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 32, 0, 0, 32, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 21, 10, 0, 0, -1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 0, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 9, 0 },
- { 22, 10, 0, 0, -1, -2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 2, 0 },
- { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 19, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 12, 0, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -32, -32, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 17, 0 },
- { 22, 10, 0, 0, -1, -2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 1, 0 },
- { 9, 7, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 3, 3, 35, 0 },
- { 6, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 5, 4, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 23, 10, 0, 0, -1, 16, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 0 },
- { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 17, 0 },
- { 29, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 0 },
- { 26, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 9, 0 },
- { 5, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 18, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 743, 743, 775, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 9, 0, 12, 0 },
- { 5, 2, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 24, 10, 0, 0, -1, -16, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 0 },
- { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 16, 13, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 121, 121, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 19, 0, 0, 0, 1, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -232, -232, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 98, 98, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -121, 0, 0, -121, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -300, -300, -268, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 195, 195, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 210, 0, 0, 210, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 206, 0, 0, 206, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 205, 0, 0, 205, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 79, 0, 0, 79, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 202, 0, 0, 202, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 203, 0, 0, 203, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 207, 0, 0, 207, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 97, 97, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 211, 0, 0, 211, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 209, 0, 0, 209, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 163, 163, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 213, 0, 0, 213, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 130, 130, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 214, 0, 0, 214, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 218, 0, 0, 218, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 217, 0, 0, 217, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 219, 0, 0, 219, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 56, 56, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 2, 0, 1, 2, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 16, 0, 0, 0, -1, 0, 1, -1, 0, 1, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -2, -1, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -79, -79, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 109, 109, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -97, 0, 0, -97, 0, 0, 0, 0, 4, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -56, 0, 0, -56, 0, 0, 0, 0, 4, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 4, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -130, 0, 0, -130, 0, 0, 0, 0, 6, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 10795, 0, 0, 10795, 0, 0, 0, 0, 8, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 8, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -163, 0, 0, -163, 0, 0, 0, 0, 8, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 10792, 0, 0, 10792, 0, 0, 0, 0, 8, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 10815, 10815, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -195, 0, 0, -195, 0, 0, 0, 0, 9, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 69, 0, 0, 69, 0, 0, 0, 0, 9, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 71, 0, 0, 71, 0, 0, 0, 0, 9, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 9, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 10783, 10783, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 10780, 10780, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 10782, 10782, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -210, -210, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -206, -206, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -205, -205, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -202, -202, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -203, -203, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -207, -207, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 3, 3, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -209, -209, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -211, -211, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 10743, 10743, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 10749, 10749, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -213, -213, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -214, -214, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 10727, 10727, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -218, -218, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -69, -69, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -217, -217, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -71, -71, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -219, -219, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 17, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 0 },
- { 17, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 18, 0 },
- { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 18, 0 },
- { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 17, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 0 },
- { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 0 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 232, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 216, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 202, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 1, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 240, 0, -1, 0, 0, 84, 84, 116, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 28 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 28 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 4, 28 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 28 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 28 },
- { 0, 17, 232, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 28 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 28 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 28 },
- { 0, 17, 233, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 4, 28 },
- { 0, 17, 234, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 4, 28 },
- { 0, 17, 233, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 4, 28 },
- { 0, 17, 234, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 4, 28 },
- { 0, 17, 233, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 4, 28 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 28 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 10, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 10, 0, 7, 6, 12, 1 },
- { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 1 },
+ { 9, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0, 0, 21, 2 },
+ { 9, 8, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0, 5, 17, 2 },
+ { 9, 7, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 2, 2, 34, 2 },
+ { 9, 8, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 3, 5, 35, 2 },
+ { 9, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 3, 5, 35, 2 },
+ { 9, 7, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 33, 2 },
+ { 9, 7, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0, 0, 21, 2 },
+ { 9, 8, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0, 0, 21, 2 },
+ { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 5, 32, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 6, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 2 },
+ { 25, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 9, 2 },
+ { 25, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 8, 13, 3, 2 },
+ { 21, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 0, 2 },
+ { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 2, 2 },
+ { 26, 3, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 9, 2 },
+ { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 11, 8, 2 },
+ { 20, 3, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 16, 2 },
+ { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 10, 8, 2 },
+ { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 7, 2 },
+ { 3, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 8, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 0, 8, 2 },
+ { 26, 10, 0, 0, -1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 14, 0, 0, 0, -1, 0, 32, 0, 0, 32, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 21, 10, 0, 0, -1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 0, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 9, 2 },
+ { 22, 10, 0, 0, -1, -2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 2, 2 },
+ { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 19, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 12, 0, 12, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, -32, -32, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 17, 2 },
+ { 22, 10, 0, 0, -1, -2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 1, 2 },
+ { 9, 7, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 3, 3, 35, 2 },
+ { 6, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 5, 4, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 2 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 23, 10, 0, 0, -1, 16, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 2 },
+ { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 17, 2 },
+ { 29, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 2 },
+ { 26, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 9, 2 },
+ { 5, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 18, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, 743, 743, 775, 0, 0, 0, 0, 1, 0, 7, 6, 12, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 9, 0, 12, 2 },
+ { 5, 2, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 24, 10, 0, 0, -1, -16, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 2 },
+ { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, 16, 13, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 121, 121, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 19, 0, 0, 0, 1, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -232, -232, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 98, 98, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -121, 0, 0, -121, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -300, -300, -268, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 195, 195, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 210, 0, 0, 210, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 206, 0, 0, 206, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 205, 0, 0, 205, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 79, 0, 0, 79, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 202, 0, 0, 202, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 203, 0, 0, 203, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 207, 0, 0, 207, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 97, 97, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 211, 0, 0, 211, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 209, 0, 0, 209, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 163, 163, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 213, 0, 0, 213, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 130, 130, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 214, 0, 0, 214, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 218, 0, 0, 218, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 217, 0, 0, 217, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 219, 0, 0, 219, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 56, 56, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 2, 0, 1, 2, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 16, 0, 0, 0, -1, 0, 1, -1, 0, 1, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -2, -1, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -79, -79, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 109, 109, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -97, 0, 0, -97, 0, 0, 0, 0, 4, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -56, 0, 0, -56, 0, 0, 0, 0, 4, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 4, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -130, 0, 0, -130, 0, 0, 0, 0, 6, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 10795, 0, 0, 10795, 0, 0, 0, 0, 8, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 8, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -163, 0, 0, -163, 0, 0, 0, 0, 8, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 10792, 0, 0, 10792, 0, 0, 0, 0, 8, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 10815, 10815, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -195, 0, 0, -195, 0, 0, 0, 0, 9, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 69, 0, 0, 69, 0, 0, 0, 0, 9, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 71, 0, 0, 71, 0, 0, 0, 0, 9, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 9, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 10783, 10783, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 10780, 10780, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 10782, 10782, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -210, -210, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -206, -206, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -205, -205, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -202, -202, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -203, -203, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -207, -207, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 3, 3, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -209, -209, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -211, -211, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 10743, 10743, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 10749, 10749, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -213, -213, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -214, -214, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 10727, 10727, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -218, -218, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -69, -69, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -217, -217, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -71, -71, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -219, -219, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 3 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 17, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 2 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 2 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 2 },
+ { 17, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 18, 2 },
+ { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 18, 2 },
+ { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 36 },
+ { 17, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 2 },
+ { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 2 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 2 },
+ { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 2 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 232, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 216, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 202, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 1, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 240, 0, -1, 0, 0, 84, 84, 116, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 1 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 1 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 4, 1 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 1 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 1 },
+ { 0, 17, 232, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 1 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 1 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 1 },
+ { 0, 17, 233, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 4, 1 },
+ { 0, 17, 234, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 4, 1 },
+ { 0, 17, 233, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 4, 1 },
+ { 0, 17, 234, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 4, 1 },
+ { 0, 17, 233, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 4, 1 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 1 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 10, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 10, 0, 7, 6, 12, 4 },
+ { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 4 },
{ 13, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 130, 130, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, 38, 0, 0, 38, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 14, 0, 0, 0, -1, 0, 37, 0, 0, 37, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 14, 0, 0, 0, -1, 0, 64, 0, 0, 64, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 14, 0, 0, 0, -1, 0, 63, 0, 0, 63, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 101, 101, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, 32, 0, 0, 32, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -38, -38, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -37, -37, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 105, 105, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -32, -32, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -31, -31, 1, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -64, -64, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -63, -63, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, 8, 0, 0, 8, 0, 0, 0, 0, 10, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -62, -62, -30, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -57, -57, -25, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -47, -47, -15, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -54, -54, -22, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -8, -8, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 6, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 6, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -86, -86, -54, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -80, -80, -48, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 7, 7, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, -60, 0, 0, -60, 0, 0, 0, 0, 5, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -96, -96, -64, 0, 0, 0, 0, 5, 0, 7, 6, 12, 1 },
- { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 1 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 7, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, -7, 0, 0, -7, 0, 0, 0, 0, 7, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, -130, 0, 0, -130, 0, 0, 0, 0, 8, 0, 7, 7, 12, 1 },
- { 14, 0, 0, 0, -1, 0, 80, 0, 0, 80, 0, 0, 0, 0, 4, 0, 7, 7, 12, 2 },
- { 14, 0, 0, 0, -1, 0, 80, 0, 0, 80, 0, 0, 0, 0, 1, 0, 7, 7, 12, 2 },
- { 14, 0, 0, 0, -1, 0, 32, 0, 0, 32, 0, 0, 0, 0, 1, 0, 7, 7, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, -32, -32, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, -80, -80, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, -80, -80, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 2 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 7, 7, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 2 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 2 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 2 },
- { 2, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 2 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 6, 0, 7, 7, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 6, 0, 7, 6, 12, 2 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 4, 0, 7, 7, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 2 },
- { 14, 0, 0, 0, -1, 0, 15, 0, 0, 15, 0, 0, 0, 0, 1, 0, 7, 7, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, -15, -15, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 2 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 8, 0, 7, 7, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 2 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 9, 0, 7, 7, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 2 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 10, 0, 7, 7, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 10, 0, 7, 6, 12, 2 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 11, 0, 7, 7, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 11, 0, 7, 6, 12, 2 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 12, 0, 7, 7, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 12, 0, 7, 6, 12, 2 },
- { 14, 0, 0, 0, -1, 0, 48, 0, 0, 48, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 3 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 3 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 12, 3 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 12, 3 },
- { 15, 0, 0, 0, -1, 0, 0, -48, -48, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
- { 15, 0, 0, 0, -1, 0, 0, 65, 62, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 12, 8, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 17, 3 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 9, 3 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 130, 130, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, 38, 0, 0, 38, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, 37, 0, 0, 37, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, 64, 0, 0, 64, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, 63, 0, 0, 63, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 101, 101, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, 32, 0, 0, 32, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -38, -38, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -37, -37, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 105, 105, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -32, -32, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -31, -31, 1, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -64, -64, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -63, -63, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, 8, 0, 0, 8, 0, 0, 0, 0, 10, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -62, -62, -30, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -57, -57, -25, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -47, -47, -15, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -54, -54, -22, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -8, -8, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 6, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 6, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 7, 7, 12, 46 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 46 },
+ { 15, 0, 0, 0, -1, 0, 0, -86, -86, -54, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -80, -80, -48, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 7, 7, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, -60, 0, 0, -60, 0, 0, 0, 0, 5, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -96, -96, -64, 0, 0, 0, 0, 5, 0, 7, 6, 12, 4 },
+ { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 7, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, -7, 0, 0, -7, 0, 0, 0, 0, 7, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, -130, 0, 0, -130, 0, 0, 0, 0, 8, 0, 7, 7, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, 80, 0, 0, 80, 0, 0, 0, 0, 4, 0, 7, 7, 12, 5 },
+ { 14, 0, 0, 0, -1, 0, 80, 0, 0, 80, 0, 0, 0, 0, 1, 0, 7, 7, 12, 5 },
+ { 14, 0, 0, 0, -1, 0, 32, 0, 0, 32, 0, 0, 0, 0, 1, 0, 7, 7, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, -32, -32, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, -80, -80, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, -80, -80, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 5 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 7, 7, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 5 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 5 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 5 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 5 },
+ { 2, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 5 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 6, 0, 7, 7, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 6, 0, 7, 6, 12, 5 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 4, 0, 7, 7, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 5 },
+ { 14, 0, 0, 0, -1, 0, 15, 0, 0, 15, 0, 0, 0, 0, 1, 0, 7, 7, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, -15, -15, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 5 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 8, 0, 7, 7, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 5 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 9, 0, 7, 7, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 5 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 10, 0, 7, 7, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 10, 0, 7, 6, 12, 5 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 11, 0, 7, 7, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 11, 0, 7, 6, 12, 5 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 12, 0, 7, 7, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 12, 0, 7, 6, 12, 5 },
+ { 14, 0, 0, 0, -1, 0, 48, 0, 0, 48, 0, 0, 0, 0, 1, 0, 7, 7, 12, 6 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 6 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 6 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 12, 6 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 12, 6 },
+ { 15, 0, 0, 0, -1, 0, 0, -48, -48, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 6 },
+ { 15, 0, 0, 0, -1, 0, 0, 65, 62, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 6 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 12, 8, 2 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 17, 6 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 9, 6 },
{ 13, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 4 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 4 },
- { 0, 17, 222, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 4 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 4 },
- { 0, 17, 228, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 4 },
- { 0, 17, 10, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 11, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 12, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 13, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 14, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 15, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 16, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 17, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 18, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 19, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 19, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 4 },
- { 0, 17, 20, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 21, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 22, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 20, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 17, 4 },
- { 0, 17, 23, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 4 },
- { 0, 17, 24, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 0, 17, 25, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 6, 4 },
- { 0, 17, 18, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 4 },
- { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 13, 4 },
- { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 4 },
- { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 9, 0, 12, 4 },
- { 10, 5, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 4, 4, 12, 5 },
- { 10, 5, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 3, 4, 4, 12, 5 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 7 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 7 },
+ { 0, 17, 222, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 7 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 7 },
+ { 0, 17, 228, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 7 },
+ { 0, 17, 10, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 11, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 12, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 13, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 14, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 15, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 16, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 17, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 18, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 19, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 19, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 7 },
+ { 0, 17, 20, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 21, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 22, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 20, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 17, 7 },
+ { 0, 17, 23, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 7 },
+ { 0, 17, 24, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 0, 17, 25, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 6, 7 },
+ { 0, 17, 18, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 7 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 13, 7 },
+ { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 7 },
+ { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 9, 0, 12, 7 },
+ { 10, 5, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 3, 4, 4, 12, 8 },
+ { 10, 5, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 3, 4, 4, 12, 8 },
{ 13, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 5 },
- { 26, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 5 },
- { 25, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 10, 5 },
- { 27, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 10, 5 },
- { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 10, 11, 8, 5 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 5 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 5 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 5 },
- { 0, 17, 30, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 5 },
- { 0, 17, 31, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 5 },
- { 0, 17, 32, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 5 },
- { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 6, 0 },
- { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 6, 5 },
- { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 6, 0 },
- { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 5 },
- { 18, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 5 },
- { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 5 },
- { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 5 },
- { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 5 },
- { 17, 13, 0, 3, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 0 },
- { 0, 17, 27, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 28, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 29, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 30, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 31, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 32, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 33, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 34, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 5 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 5 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 5 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 5 },
- { 3, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 5, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 5, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 5, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 5, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 5, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 5, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 5, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 5, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 3, 5, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 0 },
- { 25, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 5 },
- { 25, 5, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 5 },
- { 25, 5, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 9, 11, 5 },
- { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 5 },
- { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 5 },
- { 0, 17, 35, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 5 },
- { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 5 },
- { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 6, 5 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 5 },
- { 10, 5, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 5 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 5 },
- { 17, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 5 },
- { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 5 },
- { 3, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 5 },
- { 3, 2, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 5 },
- { 3, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 5 },
- { 3, 2, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 5 },
- { 3, 2, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 5 },
- { 3, 2, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 5 },
- { 3, 2, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 5 },
- { 3, 2, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 5 },
- { 3, 2, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 5 },
- { 3, 2, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 5 },
- { 29, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 5 },
- { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 5 },
- { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 12, 12, 6 },
- { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 6 },
- { 10, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 3, 4, 4, 12, 6 },
- { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 6 },
- { 0, 17, 36, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 6 },
- { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 6 },
- { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 6 },
- { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 6 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 6 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 6 },
- { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 5 },
- { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 5 },
- { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 5 },
- { 18, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 7 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 7 },
- { 18, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 7 },
- { 3, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 27 },
- { 3, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 27 },
- { 3, 1, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 27 },
- { 3, 1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 27 },
- { 3, 1, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 27 },
- { 3, 1, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 27 },
- { 3, 1, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 27 },
- { 3, 1, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 27 },
- { 3, 1, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 27 },
- { 3, 1, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 27 },
- { 18, 1, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 27 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 27 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 27 },
- { 17, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 27 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 27 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 27 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 10, 11, 8, 27 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 12, 6, 27 },
- { 17, 1, 0, 3, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 27 },
- { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 0 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 0 },
- { 17, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 0 },
- { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 18, 1, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 0 },
- { 18, 1, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 0 },
- { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 0 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 0 },
- { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 5 },
- { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 5 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 5 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 5 },
- { 0, 17, 27, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 5 },
- { 0, 17, 28, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 5 },
- { 0, 17, 29, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 5 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 8 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 8 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 8 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 8 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 8 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 8 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 7, 4, 4, 21, 8 },
- { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 8 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 8 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 7, 4, 4, 21, 8 },
+ { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 8 },
+ { 26, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 8 },
+ { 25, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 10, 8 },
+ { 27, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 10, 8 },
+ { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 10, 11, 8, 8 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 8 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 8 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 8 },
+ { 0, 17, 30, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 8 },
+ { 0, 17, 31, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 8 },
+ { 0, 17, 32, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 8 },
+ { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 6, 2 },
+ { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 6, 8 },
+ { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 6, 2 },
+ { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 8 },
+ { 18, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 8 },
+ { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 8 },
+ { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 8 },
+ { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 8 },
+ { 17, 13, 0, 3, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 2 },
+ { 0, 17, 27, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 28, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 29, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 30, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 31, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 32, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 33, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 34, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 8 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 8 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 8 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 8 },
+ { 3, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 5, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 5, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 5, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 5, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 5, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 5, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 5, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 5, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 3, 5, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 2 },
+ { 25, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 8 },
+ { 25, 5, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
+ { 25, 5, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 9, 11, 8 },
+ { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 8 },
+ { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 8 },
+ { 0, 17, 35, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 8 },
+ { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 8 },
+ { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 6, 8 },
{ 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 8 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 17, 0 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 8 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 8 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 8 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 8 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 8 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 8 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 8 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 9 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 9 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 9 },
- { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 9 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 9 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 9 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 9 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 9 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 9 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 9 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 9 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 9 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 9 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 9 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 9 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 9 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 9 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 9 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 9 },
- { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 9 },
- { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 9 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 9 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 9, 9 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 10 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 10 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 7, 4, 4, 21, 10 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 10 },
- { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 10 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 10 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 10 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 10 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 10 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 10 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 10 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 10 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 10 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 10 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 10 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 10 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 10 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 10 },
+ { 10, 5, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 8 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 8 },
+ { 17, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 8 },
+ { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 8 },
+ { 3, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
+ { 3, 2, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
+ { 3, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
+ { 3, 2, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
+ { 3, 2, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
+ { 3, 2, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
+ { 3, 2, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
+ { 3, 2, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
+ { 3, 2, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
+ { 3, 2, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 8 },
+ { 29, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 8 },
+ { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 8 },
+ { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 12, 12, 9 },
+ { 25, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 9 },
+ { 10, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 3, 4, 4, 12, 9 },
+ { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 9 },
+ { 0, 17, 36, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 9 },
+ { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 9 },
+ { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 9 },
+ { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 9 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 9 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 9 },
+ { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 8 },
+ { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 8 },
+ { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 8 },
+ { 18, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 10 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 10 },
+ { 18, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 10 },
+ { 3, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 66 },
+ { 3, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 66 },
+ { 3, 1, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 66 },
+ { 3, 1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 66 },
+ { 3, 1, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 66 },
+ { 3, 1, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 66 },
+ { 3, 1, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 66 },
+ { 3, 1, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 66 },
+ { 3, 1, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 66 },
+ { 3, 1, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 66 },
+ { 18, 1, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 66 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 66 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 66 },
+ { 17, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 66 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 66 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 66 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 10, 11, 8, 66 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 12, 6, 66 },
+ { 17, 1, 0, 3, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 66 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 82 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 82 },
+ { 17, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 82 },
+ { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 82 },
+ { 18, 1, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 95 },
+ { 18, 1, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 95 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 95 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 95 },
+ { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 95 },
+ { 18, 13, 0, 1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 8 },
+ { 18, 13, 0, 2, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 8 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 8 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 8 },
+ { 0, 17, 27, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 8 },
+ { 0, 17, 28, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 8 },
+ { 0, 17, 29, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 8 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 11 },
{ 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 11 },
{ 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 11 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 11 },
{ 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 11 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 11 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 11 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 7, 4, 4, 21, 11 },
{ 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 11 },
{ 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 11 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 11 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 7, 4, 4, 21, 11 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 11 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 17, 2 },
{ 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 11 },
{ 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 11 },
{ 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 11 },
@@ -5267,16 +5266,21 @@ static const Properties uc_properties[] = {
{ 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 11 },
{ 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 11 },
{ 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 11 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 11 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 9, 11 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 11 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 11 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 11 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 11 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 11 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 11 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 11 },
{ 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 12 },
{ 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 12 },
{ 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 12 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 12 },
{ 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 12 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 12 },
{ 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 12 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 12 },
{ 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 12 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 12 },
{ 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 12 },
{ 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 12 },
{ 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 12 },
@@ -5287,16 +5291,20 @@ static const Properties uc_properties[] = {
{ 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 12 },
{ 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 12 },
{ 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 12 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 12 },
+ { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 12 },
+ { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 12 },
{ 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 12 },
- { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 12 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 9, 12 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 13 },
{ 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 13 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 7, 4, 4, 21, 13 },
{ 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 13 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 13 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 13 },
+ { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 13 },
{ 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 13 },
{ 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 13 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 13 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 13 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 13 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 13 },
{ 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 13 },
{ 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 13 },
{ 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 13 },
@@ -5306,17 +5314,13 @@ static const Properties uc_properties[] = {
{ 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 13 },
{ 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 13 },
{ 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 13 },
- { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 13 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 13 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 9, 13 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 14 },
{ 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 14 },
{ 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 14 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 14 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 14 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 14 },
+ { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 14 },
{ 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 14 },
- { 0, 17, 84, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 14 },
- { 0, 17, 91, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 14 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 14 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 14 },
{ 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 14 },
{ 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 14 },
{ 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 14 },
@@ -5327,17 +5331,16 @@ static const Properties uc_properties[] = {
{ 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 14 },
{ 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 14 },
{ 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 14 },
- { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 14 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 14 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 14 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 9, 14 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 15 },
{ 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 15 },
{ 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 15 },
- { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 15 },
{ 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 15 },
- { 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 15 },
+ { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 15 },
{ 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 15 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 15 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 15 },
{ 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 15 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 15 },
{ 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 15 },
{ 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 15 },
{ 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 15 },
@@ -5348,16 +5351,16 @@ static const Properties uc_properties[] = {
{ 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 15 },
{ 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 15 },
{ 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 15 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 15 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 16 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 15 },
+ { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 15 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 16 },
{ 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 16 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 16 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 16 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 16 },
{ 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 16 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 16 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 16 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 16 },
{ 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 16 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 16 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 16 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 16 },
{ 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 16 },
{ 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 16 },
{ 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 16 },
@@ -5367,22 +5370,38 @@ static const Properties uc_properties[] = {
{ 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 16 },
{ 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 16 },
{ 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 16 },
- { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 16 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 10, 16 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 7, 4, 4, 21, 17 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 17 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 17 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 17 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 17 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 17 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 30, 18 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 18 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 0, 8, 30, 18 },
- { 0, 17, 103, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 18 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 18 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 30, 18 },
- { 0, 17, 107, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 18 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 18 },
+ { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 16 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 16 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 9, 16 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 17 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 17 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 17 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 17 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 17 },
+ { 0, 17, 84, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 17 },
+ { 0, 17, 91, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 17 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 17 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 17 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 17 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 17 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 17 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 17 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 17 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 17 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 17 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 17 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 17 },
+ { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 17 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 17 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 18 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 18 },
+ { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 18 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 18 },
+ { 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 18 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 18 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 18 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 18 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 18 },
{ 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 18 },
{ 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 18 },
{ 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 18 },
@@ -5393,13 +5412,15 @@ static const Properties uc_properties[] = {
{ 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 18 },
{ 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 18 },
{ 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 18 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 17, 18 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 30, 19 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 19 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 0, 8, 30, 19 },
- { 0, 17, 118, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 19 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 30, 19 },
- { 0, 17, 122, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 19 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 18 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 4, 4, 21, 19 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 19 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 19 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 19 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 19 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 19 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 19 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 19 },
{ 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 19 },
{ 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 19 },
{ 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 19 },
@@ -5410,920 +5431,1254 @@ static const Properties uc_properties[] = {
{ 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 19 },
{ 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 19 },
{ 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 19 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 8, 30, 19 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 7, 8, 12, 20 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 18, 20 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 18, 20 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 12, 20 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 4, 20 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 17, 20 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 6, 20 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 12, 20 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 20 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 20 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 20 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 20 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 20 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 20 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 20 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 20 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 20 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 20 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 20 },
- { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 12, 20 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 17, 20 },
- { 0, 17, 216, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 20 },
- { 21, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 13, 0, 20 },
- { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 13, 1, 20 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 7, 4, 4, 21, 20 },
+ { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 19 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 10, 19 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 7, 4, 4, 21, 20 },
{ 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 20 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 20 },
- { 0, 17, 129, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 20 },
- { 0, 17, 130, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 20 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 20 },
- { 0, 17, 132, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 20 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 7, 4, 4, 17, 20 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 20 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 20 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 20 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 20 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 20 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 20 },
{ 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 20 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 17, 20 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 20 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 20 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 20 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 18, 20 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 17, 20 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 18, 20 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 20 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 4, 20 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 8, 30, 21 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 8, 30, 21 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 4, 4, 30, 21 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 4, 4, 30, 21 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 30, 21 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 7, 4, 4, 30, 21 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 30, 21 },
- { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 30, 21 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 30, 21 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 30, 21 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 4, 4, 30, 21 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 21 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 12, 17, 21 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 21 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 30, 21 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 21 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 21 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 4, 4, 30, 21 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 30, 21 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 30, 21 },
- { 14, 0, 0, 0, -1, 0, 7264, 0, 0, 7264, 0, 0, 0, 0, 1, 0, 7, 7, 12, 22 },
- { 14, 0, 0, 0, -1, 0, 7264, 0, 0, 7264, 0, 0, 0, 0, 13, 0, 7, 7, 12, 22 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 22 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 22 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 22 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 22 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 22 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 8, 7, 8, 25, 23 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 8, 7, 8, 25, 23 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 9, 7, 8, 26, 23 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 9, 7, 8, 26, 23 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 10, 7, 8, 27, 23 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 10, 7, 8, 27, 23 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 0 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 0 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 17, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 12, 12, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 5, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 5, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 5, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 5, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 5, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 5, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 5, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 5, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 5, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 17, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 0 },
- { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 5, 17, 24 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 24 },
- { 21, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 13, 0, 24 },
- { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 13, 1, 24 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 25 },
- { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 25 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 0 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 0 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 12, 17, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 8, 30, 26 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 30, 26 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 7, 4, 4, 30, 26 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 30, 26 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 17, 26 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 5, 26 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 8, 30, 26 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 26 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 9, 26 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 30, 26 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 26 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 26 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 26 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 26 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 26 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 26 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 26 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 26 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 26 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 26 },
- { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 26 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 11, 6, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 12, 6, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 17, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 18, 0 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 0 },
- { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 5, 4, 0 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 0 },
- { 0, 17, 228, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 0 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 0 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 7, 4, 4, 21, 0 },
- { 0, 17, 222, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 0 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 0 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 12, 6, 0 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 8, 30, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 8, 30, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 30, 0 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 4, 4, 30, 0 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 7, 4, 4, 30, 0 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 0 },
- { 5, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 30, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 30, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 26 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 0 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 7, 4, 4, 21, 0 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 7, 4, 4, 30, 0 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 30, 0 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 30, 0 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 4, 4, 30, 0 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 30, 0 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 0 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 30, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 30, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 12, 30, 0 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 0 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 7, 4, 4, 21, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 0 },
- { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 0 },
- { 1, 0, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 7, 4, 4, 21, 0 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 12, 17, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 17, 0 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 0 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 0 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 0 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 0 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 4, 4, 21, 0 },
- { 1, 0, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 4, 4, 21, 0 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 0 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 7, 4, 4, 21, 0 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 0 },
- { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 0 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 7, 4, 4, 21, 0 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 0 },
- { 1, 0, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 7, 4, 4, 21, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 12, 17, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 17, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 0 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 28 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 0, 17, 1, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 28 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 28 },
- { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 7, 4, 4, 21, 0 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 28 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 2 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 1 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 2 },
- { 15, 0, 0, 0, -1, 0, 0, 5, 5, 0, 0, 1, 1, 0, 8, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 3814, 3814, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 1 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 28 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 28 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 28 },
- { 0, 17, 234, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 28 },
- { 0, 17, 214, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 28 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 28 },
- { 0, 17, 202, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 28 },
- { 0, 17, 233, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 28 },
- { 15, 0, 0, 0, -1, 0, 0, 112, 112, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 115, 115, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 118, 118, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 121, 121, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 124, 124, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -59, -59, -58, 0, 0, 0, 0, 2, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -7615, 0, 0, -7615, 0, 0, 0, 0, 10, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 10, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 10, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 8, 8, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, -8, 0, 0, -8, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 127, 127, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 130, 130, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 134, 134, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 138, 138, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 74, 74, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 86, 86, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 100, 100, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 128, 128, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 112, 112, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 126, 126, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 176, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 179, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 182, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 185, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 188, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 191, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 194, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 197, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 176, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 179, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 182, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 185, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 188, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 191, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 194, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 197, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 200, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 203, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 206, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 209, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 212, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 215, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 218, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 221, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 200, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 203, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 206, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 209, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 212, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 215, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 218, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 221, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 224, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 227, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 230, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 233, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 236, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 239, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 242, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 245, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 224, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 227, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 230, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 233, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 236, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 239, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 242, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -8, 245, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 260, 257, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 248, 9, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 266, 263, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 142, 142, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 297, 293, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, -74, 0, 0, -74, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -9, 248, 0, -9, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, -7205, -7205, -7173, 0, 0, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 272, 269, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 251, 9, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 278, 275, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 145, 145, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 305, 301, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, -86, 0, 0, -86, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -9, 251, 0, -9, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 148, 148, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 152, 152, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 155, 155, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, -100, 0, 0, -100, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 159, 159, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 163, 163, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 166, 166, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 169, 169, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, -112, 0, 0, -112, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 14, 0, 0, 0, -1, 0, -7, 0, 0, -7, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 284, 281, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 254, 9, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 290, 287, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 173, 173, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 15, 0, 0, 0, -1, 0, 0, 313, 309, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 1 },
- { 14, 0, 0, 0, -1, 0, -128, 0, 0, -128, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 14, 0, 0, 0, -1, 0, -126, 0, 0, -126, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 16, 0, 0, 0, -1, 0, -9, 254, 0, -9, 0, 1, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 18, 1 },
- { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 5, 17, 0 },
- { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 5, 4, 0 },
- { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0, 4, 20, 0 },
- { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 10, 18, 0, 3, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 10, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 0 },
- { 10, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 17, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 4, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 17, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 19, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 23, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 8, 13, 3, 0 },
- { 24, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 8, 13, 3, 0 },
- { 21, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 0, 0 },
- { 23, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 0 },
- { 24, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 8, 10, 15, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 15, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 9, 0, 17, 0 },
- { 7, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 3, 3, 35, 0 },
- { 8, 7, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 3, 3, 35, 0 },
- { 10, 11, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 0 },
- { 10, 14, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 0 },
- { 10, 16, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 0 },
- { 10, 12, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 0 },
- { 10, 15, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 0 },
- { 6, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 5, 4, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 0 },
- { 23, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 0 },
- { 24, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 5, 0 },
- { 26, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 0, 8, 0 },
- { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 1, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 12, 5, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 12, 5, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 0 },
- { 19, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 12, 0, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 17, 0 },
- { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 5, 17, 0 },
- { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 3, 4, 4, 22, 0 },
- { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 3, 4, 4, 12, 0 },
- { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 3, 4, 4, 12, 0 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 20 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 30, 21 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 21 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 0, 8, 30, 21 },
+ { 0, 17, 103, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 21 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 21 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 30, 21 },
+ { 0, 17, 107, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 21 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 21 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 21 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 21 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 21 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 21 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 21 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 21 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 21 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 21 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 21 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 21 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 17, 21 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 30, 22 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 22 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 7, 0, 8, 30, 22 },
+ { 0, 17, 118, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 22 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 30, 22 },
+ { 0, 17, 122, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 30, 22 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 22 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 22 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 22 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 22 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 22 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 22 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 22 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 22 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 22 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 11, 9, 11, 22 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 8, 30, 22 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 7, 8, 12, 23 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 18, 23 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 18, 23 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 12, 23 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 4, 23 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 17, 23 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 6, 23 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 12, 23 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 23 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 23 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 23 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 23 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 23 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 23 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 23 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 23 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 23 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 23 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 11, 9, 11, 23 },
+ { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 12, 23 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 17, 23 },
+ { 0, 17, 216, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 23 },
+ { 21, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 13, 0, 23 },
+ { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 13, 1, 23 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 7, 4, 4, 21, 23 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 23 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 23 },
+ { 0, 17, 129, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 23 },
+ { 0, 17, 130, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 23 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 23 },
+ { 0, 17, 132, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 23 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 7, 4, 4, 17, 23 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 23 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 4, 4, 4, 21, 23 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 23 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 23 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 23 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 17, 23 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 23 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 23 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 23 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 18, 23 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 17, 23 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 18, 23 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 23 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 4, 23 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 8, 30, 24 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 8, 30, 24 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 4, 4, 30, 24 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 4, 4, 30, 24 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 30, 24 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 7, 4, 4, 30, 24 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 30, 24 },
+ { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 30, 24 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 30, 24 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 30, 24 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 4, 4, 30, 24 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 24 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 12, 17, 24 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 24 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 30, 24 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 24 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 24 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 4, 4, 30, 24 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 30, 24 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 30, 24 },
+ { 14, 0, 0, 0, -1, 0, 7264, 0, 0, 7264, 0, 0, 0, 0, 1, 0, 7, 7, 12, 25 },
+ { 14, 0, 0, 0, -1, 0, 7264, 0, 0, 7264, 0, 0, 0, 0, 13, 0, 7, 7, 12, 25 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 25 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 25 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 25 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 25 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 25 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 8, 7, 8, 25, 26 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 8, 7, 8, 25, 26 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 9, 7, 8, 26, 26 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 9, 7, 8, 26, 26 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 10, 7, 8, 27, 26 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 10, 7, 8, 27, 26 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 27 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 27 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 27 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 27 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 27 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 17, 27 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 12, 12, 27 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 27 },
+ { 5, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 27 },
+ { 5, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 27 },
+ { 5, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 27 },
+ { 5, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 27 },
+ { 5, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 27 },
+ { 5, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 27 },
+ { 5, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 27 },
+ { 5, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 27 },
+ { 5, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 27 },
+ { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 27 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 27 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 28 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 17, 29 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 29 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 29 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 12, 12, 29 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 29 },
+ { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 5, 17, 30 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 30 },
+ { 21, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 13, 0, 30 },
+ { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 13, 1, 30 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 31 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 17, 2 },
+ { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 31 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 42 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 42 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 42 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 43 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 43 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 43 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 12, 17, 2 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 44 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 44 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 45 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 45 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 8, 30, 32 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 30, 32 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 7, 4, 4, 30, 32 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 30, 32 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 17, 32 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 5, 32 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 8, 30, 32 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 32 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 9, 32 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 30, 32 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 32 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 32 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 32 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 32 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 32 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 32 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 32 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 32 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 32 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 32 },
+ { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 32 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 33 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 11, 6, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 12, 6, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 17, 33 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 17, 2 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 18, 33 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 11, 6, 33 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 12, 6, 33 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 33 },
+ { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 5, 4, 33 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 33 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 33 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 33 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 33 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 33 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 33 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 33 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 33 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 33 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 11, 9, 11, 33 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 33 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 12, 33 },
+ { 0, 17, 228, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 33 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 33 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 47 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 47 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 7, 4, 4, 21, 47 },
+ { 0, 17, 222, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 47 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 47 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 47 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 47 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 12, 6, 47 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 47 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 47 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 47 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 47 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 47 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 47 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 47 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 47 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 47 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 47 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 8, 30, 48 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 8, 30, 56 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 30, 56 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 4, 4, 30, 56 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 7, 4, 4, 30, 56 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 56 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 56 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 56 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 56 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 56 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 56 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 56 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 56 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 56 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 11, 9, 11, 56 },
+ { 5, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 30, 56 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 30, 56 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 32 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 55 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 55 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 55 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 7, 4, 4, 21, 55 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 55 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 30, 78 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 7, 4, 4, 30, 78 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 30, 78 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 30, 78 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 4, 4, 30, 78 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 30, 78 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 78 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 78 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 78 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 78 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 78 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 78 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 78 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 78 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 78 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 78 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 78 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 30, 78 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 30, 78 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 12, 30, 78 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 62 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 7, 4, 4, 21, 62 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 62 },
+ { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 62 },
+ { 1, 0, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 7, 4, 4, 21, 62 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 62 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 62 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 62 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 62 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 62 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 62 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 62 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 62 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 62 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 11, 9, 11, 62 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 12, 17, 62 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 62 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 17, 62 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 62 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 62 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 62 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 67 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 4, 4, 21, 67 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 67 },
+ { 1, 0, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 4, 4, 21, 67 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 67 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 7, 4, 4, 21, 67 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 67 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 67 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 67 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 67 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 67 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 67 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 67 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 67 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 67 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 67 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 67 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 93 },
+ { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 93 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 7, 4, 4, 21, 93 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 93 },
+ { 1, 0, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 7, 4, 4, 21, 93 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 93 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 68 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 4, 4, 21, 68 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 68 },
+ { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 68 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 12, 17, 68 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 17, 68 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 68 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 68 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 68 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 68 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 68 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 68 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 68 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 68 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 68 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 68 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 69 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 69 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 69 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 69 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 69 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 69 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 69 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 69 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 69 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 69 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 69 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 69 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 12, 17, 69 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 67 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 1 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 0, 17, 1, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 1 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 1 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 7, 4, 4, 21, 2 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 2 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 7, 4, 4, 21, 2 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 1 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 5 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 3 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 4 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 5 },
+ { 15, 0, 0, 0, -1, 0, 0, 5, 5, 0, 0, 1, 1, 0, 8, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 3814, 3814, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 3 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 3 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 4 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 1 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 4, 4, 4, 21, 1 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 1 },
+ { 0, 17, 234, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 1 },
+ { 0, 17, 214, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 1 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 1 },
+ { 0, 17, 202, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 1 },
+ { 0, 17, 233, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 1 },
+ { 15, 0, 0, 0, -1, 0, 0, 112, 112, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 115, 115, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 118, 118, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 121, 121, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 124, 124, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -59, -59, -58, 0, 0, 0, 0, 2, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -7615, 0, 0, -7615, 0, 0, 0, 0, 10, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 10, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 10, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 8, 8, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, -8, 0, 0, -8, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 127, 127, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 130, 130, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 134, 134, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 138, 138, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 74, 74, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 86, 86, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 100, 100, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 128, 128, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 112, 112, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 126, 126, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 176, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 179, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 182, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 185, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 188, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 191, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 194, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 197, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 176, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 179, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 182, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 185, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 188, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 191, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 194, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 197, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 200, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 203, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 206, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 209, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 212, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 215, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 218, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 221, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 200, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 203, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 206, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 209, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 212, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 215, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 218, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 221, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 224, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 227, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 230, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 233, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 236, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 239, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 242, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 245, 8, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 224, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 227, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 230, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 233, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 236, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 239, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 242, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -8, 245, 0, -8, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 260, 257, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 248, 9, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 266, 263, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 142, 142, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 297, 293, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, -74, 0, 0, -74, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -9, 248, 0, -9, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, -7205, -7205, -7173, 0, 0, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 272, 269, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 251, 9, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 278, 275, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 145, 145, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 305, 301, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, -86, 0, 0, -86, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -9, 251, 0, -9, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 148, 148, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 152, 152, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 155, 155, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, -100, 0, 0, -100, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 159, 159, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 163, 163, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 166, 166, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 169, 169, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, -112, 0, 0, -112, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, -7, 0, 0, -7, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 284, 281, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 254, 9, 0, 0, 1, 0, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 290, 287, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 173, 173, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 15, 0, 0, 0, -1, 0, 0, 313, 309, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, -128, 0, 0, -128, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, -126, 0, 0, -126, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 16, 0, 0, 0, -1, 0, -9, 254, 0, -9, 0, 1, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 18, 4 },
+ { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 5, 17, 2 },
+ { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 5, 4, 2 },
+ { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0, 4, 20, 2 },
+ { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 10, 18, 0, 3, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 10, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 2 },
+ { 10, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 2 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 17, 2 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 4, 2 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 17, 2 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 19, 2 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 23, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 8, 13, 3, 2 },
+ { 24, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 8, 13, 3, 2 },
+ { 21, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 0, 2 },
+ { 23, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 2 },
+ { 24, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 8, 10, 15, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 15, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 9, 0, 17, 2 },
+ { 7, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 3, 3, 35, 2 },
+ { 8, 7, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 3, 3, 35, 2 },
+ { 10, 11, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 2 },
+ { 10, 14, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 2 },
+ { 10, 16, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 2 },
+ { 10, 12, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 2 },
+ { 10, 15, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 2 },
+ { 6, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 5, 4, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 2 },
+ { 23, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 2 },
+ { 24, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 5, 2 },
+ { 26, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 0, 8, 2 },
+ { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 1, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 12, 5, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 12, 5, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 2 },
+ { 19, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 12, 0, 12, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 17, 2 },
+ { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 5, 17, 2 },
+ { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 3, 4, 4, 22, 2 },
+ { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 3, 4, 4, 12, 2 },
+ { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 3, 4, 4, 12, 2 },
{ 13, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 12, 0 },
- { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 0 },
- { 5, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 6, 12, 0 },
- { 5, 2, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 3, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 6, 12, 0 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 9, 0 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 9, 0 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 9, 0 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 9, 0 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 9, 0 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 10, 0 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 9, 0 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 9, 0 },
- { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 9, 0 },
- { 2, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 2, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 28 },
- { 2, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 28 },
- { 0, 17, 1, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 28 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 28 },
- { 0, 17, 1, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 28 },
- { 14, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 9, 0 },
- { 14, 0, 0, 0, -1, 0, -7517, 0, 0, -7517, 0, 0, 0, 0, 1, 0, 7, 7, 12, 1 },
- { 14, 0, 0, 0, -1, 0, -8383, 0, 0, -8383, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -8262, 0, 0, -8262, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 29, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 28, 0, 0, 28, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 7, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -28, -28, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 0 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 4, 0, 0, 0, -1, 0, 16, 0, 0, 16, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 4, 0, 0, 0, -1, 0, 0, -16, -16, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 0 },
- { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 0 },
- { 26, 10, 0, 0, -1, 3, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -3, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 2016, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 138, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 1824, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 2104, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 2108, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 2106, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -138, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 8, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 7, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -8, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -7, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 14, 0 },
- { 5, 10, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 29, 0, 0, 0, -1, 0, 26, 0, 0, 26, 0, 0, 0, 0, 1, 0, 7, 7, 12, 0 },
- { 29, 0, 0, 0, -1, 0, 0, -26, -26, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 0 },
- { 5, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 14, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 14, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 0 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 14, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 14, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 6, 0 },
- { 21, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 13, 0, 0 },
- { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 13, 1, 0 },
- { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 21, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 0, 0 },
- { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 1, 0 },
- { 26, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -2, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 21, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 13, 0, 0 },
- { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 13, 1, 0 },
- { 21, 10, 0, 0, -1, 3, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 13, 0, 0 },
- { 22, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 13, 1, 0 },
- { 21, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 13, 0, 0 },
- { 22, 10, 0, 0, -1, -3, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 13, 1, 0 },
- { 26, 10, 0, 0, -1, -1824, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -2016, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -2104, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -2106, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, -2108, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 48, 0, 0, 48, 0, 0, 0, 0, 8, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -48, -48, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -10743, 0, 0, -10743, 0, 0, 0, 0, 9, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -3814, 0, 0, -3814, 0, 0, 0, 0, 9, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -10727, 0, 0, -10727, 0, 0, 0, 0, 9, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -10795, -10795, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -10792, -10792, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -10780, 0, 0, -10780, 0, 0, 0, 0, 10, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -10749, 0, 0, -10749, 0, 0, 0, 0, 10, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -10783, 0, 0, -10783, 0, 0, 0, 0, 10, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -10782, 0, 0, -10782, 0, 0, 0, 0, 11, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, -10815, 0, 0, -10815, 0, 0, 0, 0, 11, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 11, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 11, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 13, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 13, 0, 7, 6, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 6, 0 },
- { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -7264, -7264, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 22 },
- { 15, 0, 0, 0, -1, 0, 0, -7264, -7264, 0, 0, 0, 0, 0, 13, 0, 7, 6, 12, 22 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 17, 0 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 3, 0 },
- { 23, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 3, 0 },
- { 24, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 3, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 17, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 17, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 0 },
- { 23, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 13, 3, 0 },
- { 24, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 13, 3, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 12, 6, 0 },
- { 17, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 17, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 17, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 19, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 14, 0 },
- { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 5, 14, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 1, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 1, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 5, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 14, 0 },
- { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 14, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 5, 0 },
- { 22, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 1, 0 },
- { 0, 17, 218, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 228, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 0, 17, 222, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 1, 0, 224, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 23 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 8, 14, 0 },
- { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 8, 14, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 5, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 5, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 5, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 8, 5, 0 },
- { 0, 17, 8, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 28 },
- { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 0, 5, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 5, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 8, 14, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 6, 0, 5, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 8, 5, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 8, 14, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 5, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 8, 5, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 6, 8, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 14, 23 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 6, 8, 5, 0 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 23 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 14, 23 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 14, 0 },
- { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 14, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 14, 23 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 0, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 8, 14, 0 },
- { 13, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 8, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 8, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 8, 14, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 5, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 14, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 17, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 12, 17, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 12, 17, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 2 },
- { 2, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 2 },
+ { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 21, 2 },
+ { 5, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 6, 12, 3 },
+ { 5, 2, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 3, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 6, 12, 3 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 9, 2 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 9, 2 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 9, 2 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 9, 2 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 9, 2 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 10, 2 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 9, 2 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 9, 2 },
+ { 27, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 9, 2 },
+ { 2, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 2, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 4, 4, 21, 1 },
+ { 2, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 1 },
+ { 0, 17, 1, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 1 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 1 },
+ { 0, 17, 1, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 1 },
+ { 14, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 7, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 10, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 9, 2 },
+ { 14, 0, 0, 0, -1, 0, -7517, 0, 0, -7517, 0, 0, 0, 0, 1, 0, 7, 7, 12, 4 },
+ { 14, 0, 0, 0, -1, 0, -8383, 0, 0, -8383, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -8262, 0, 0, -8262, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 29, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 14, 0, 0, 0, -1, 0, 28, 0, 0, 28, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 6, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 6, 12, 2 },
+ { 14, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 7, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, -28, -28, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 3 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 4, 0, 0, 0, -1, 0, 16, 0, 0, 16, 0, 0, 0, 0, 1, 0, 7, 7, 12, 3 },
+ { 4, 0, 0, 0, -1, 0, 0, -16, -16, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 3 },
+ { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 3 },
+ { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 3 },
+ { 26, 10, 0, 0, -1, 3, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -3, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 2016, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 138, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 1824, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 2104, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 2108, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 2106, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -138, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 8, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 7, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -8, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -7, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 14, 2 },
+ { 5, 10, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 29, 0, 0, 0, -1, 0, 26, 0, 0, 26, 0, 0, 0, 0, 1, 0, 7, 7, 12, 2 },
+ { 29, 0, 0, 0, -1, 0, 0, -26, -26, 0, 0, 0, 0, 0, 1, 0, 7, 6, 12, 2 },
+ { 5, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 14, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 14, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 2 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 14, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 14, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 3, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 6, 2 },
+ { 21, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 13, 0, 2 },
+ { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 13, 1, 2 },
+ { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 2 },
+ { 21, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 0, 2 },
+ { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 1, 2 },
+ { 26, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -2, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 21, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 13, 0, 2 },
+ { 22, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 13, 1, 2 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 12, 54 },
+ { 21, 10, 0, 0, -1, 3, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 13, 0, 2 },
+ { 22, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 13, 1, 2 },
+ { 21, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 13, 0, 2 },
+ { 22, 10, 0, 0, -1, -3, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 13, 1, 2 },
+ { 26, 10, 0, 0, -1, -1824, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -2016, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -2104, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -2106, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, -2108, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 12, 2 },
+ { 14, 0, 0, 0, -1, 0, 48, 0, 0, 48, 0, 0, 0, 0, 8, 0, 7, 7, 12, 57 },
+ { 15, 0, 0, 0, -1, 0, 0, -48, -48, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 57 },
+ { 14, 0, 0, 0, -1, 0, -10743, 0, 0, -10743, 0, 0, 0, 0, 9, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -3814, 0, 0, -3814, 0, 0, 0, 0, 9, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -10727, 0, 0, -10727, 0, 0, 0, 0, 9, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -10795, -10795, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -10792, -10792, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -10780, 0, 0, -10780, 0, 0, 0, 0, 10, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -10749, 0, 0, -10749, 0, 0, 0, 0, 10, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -10783, 0, 0, -10783, 0, 0, 0, 0, 10, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -10782, 0, 0, -10782, 0, 0, 0, 0, 11, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 3 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, -10815, 0, 0, -10815, 0, 0, 0, 0, 11, 0, 7, 7, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 8, 0, 7, 7, 12, 46 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 46 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 46 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 46 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 11, 0, 7, 7, 12, 46 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 11, 0, 7, 6, 12, 46 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 46 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 13, 0, 7, 7, 12, 46 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 13, 0, 7, 6, 12, 46 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 6, 46 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 17, 46 },
+ { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 46 },
+ { 15, 0, 0, 0, -1, 0, 0, -7264, -7264, 0, 0, 0, 0, 0, 8, 0, 7, 6, 12, 25 },
+ { 15, 0, 0, 0, -1, 0, 0, -7264, -7264, 0, 0, 0, 0, 0, 13, 0, 7, 6, 12, 25 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 58 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 58 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 58 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 17, 58 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 58 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 3, 2 },
+ { 23, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 3, 2 },
+ { 24, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 3, 2 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 17, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 17, 2 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 2 },
{ 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 2 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 2 },
+ { 23, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 13, 3, 2 },
+ { 24, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 13, 3, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 12, 6, 2 },
{ 17, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 2 },
- { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 0 },
- { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 17, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 0 },
- { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 7, 0, 0, 7, 1, 0, 0, 1, 10, 0, 7, 7, 12, 0 },
- { 28, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 9, 0, 0, 9, 1, 0, 0, 1, 12, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 12, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 12, 0, 7, 6, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 11, 0, 0, 11, 1, 0, 0, 1, 13, 0, 7, 7, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 6, 12, 0 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 0 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 0 },
- { 29, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 18, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 12, 6, 0 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 0 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 8 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 8 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 0 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 0 },
- { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 0 },
- { 1, 0, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 7, 4, 4, 21, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 30, 21 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 30, 21 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 30, 21 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 30, 0 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 12, 17, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 0 },
- { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 11, 7, 8, 23, 23 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 12, 7, 8, 24, 23 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 17, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 17, 2 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 19, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 14, 37 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 14, 2 },
+ { 6, 9, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 5, 14, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 1, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 12, 1, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 5, 37 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 14, 2 },
+ { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 14, 37 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 5, 2 },
+ { 22, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 13, 1, 2 },
+ { 0, 17, 218, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 228, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 0, 17, 222, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 1, 0, 224, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 26 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 8, 14, 2 },
+ { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 8, 14, 37 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 5, 37 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 5, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 14, 2 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 5, 34 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 14, 34 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 8, 5, 34 },
+ { 0, 17, 8, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 1 },
+ { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 0, 5, 2 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 5, 34 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 8, 14, 34 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 6, 0, 5, 2 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 8, 5, 35 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 8, 14, 35 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 5, 2 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 8, 5, 2 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 8, 5, 35 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 6, 8, 14, 35 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 14, 36 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 14, 36 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 14, 26 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 14, 36 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 14, 36 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 6, 8, 5, 35 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 26 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 14, 26 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 14, 2 },
+ { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 14, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 14, 26 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 0, 14, 35 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 8, 14, 37 },
+ { 13, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 8, 14, 37 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 8, 14, 37 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 8, 14, 37 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 14, 37 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 8, 14, 37 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 14, 38 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 5, 38 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 14, 38 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 14, 38 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 83 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 83 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 17, 83 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 12, 17, 83 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 70 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 70 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 17, 70 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 12, 6, 70 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 12, 17, 70 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 70 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 70 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 70 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 70 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 70 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 70 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 70 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 70 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 70 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 70 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 5 },
+ { 2, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 5 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 5 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 5 },
+ { 17, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 5 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 84 },
+ { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 84 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 84 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 84 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 12, 17, 84 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 17, 84 },
+ { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 2 },
+ { 17, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 2 },
+ { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 2 },
+ { 14, 0, 0, 0, -1, 0, 7, 0, 0, 7, 1, 0, 0, 1, 10, 0, 7, 7, 12, 3 },
+ { 28, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 2 },
+ { 14, 0, 0, 0, -1, 0, 9, 0, 0, 9, 1, 0, 0, 1, 12, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 12, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 12, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 13, 0, 7, 7, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, -1, -1, 0, 0, 0, 0, 0, 13, 0, 7, 6, 12, 3 },
+ { 14, 0, 0, 0, -1, 0, 11, 0, 0, 11, 1, 0, 0, 1, 13, 0, 7, 7, 12, 3 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 6, 12, 3 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 3 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 59 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 59 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 59 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 7, 4, 4, 21, 59 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 59 },
+ { 29, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 65 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 18, 65 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 12, 6, 65 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 4, 4, 21, 71 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 71 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 71 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 12, 17, 71 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 71 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 71 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 71 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 71 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 71 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 71 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 71 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 71 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 71 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 71 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 11 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 11 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 72 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 72 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 72 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 72 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 72 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 72 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 72 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 72 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 72 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 72 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 72 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 72 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 72 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 17, 72 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 12, 17, 72 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 73 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 73 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 4, 4, 21, 73 },
+ { 1, 0, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 4, 4, 21, 73 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 73 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 85 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 7, 4, 4, 21, 85 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 85 },
+ { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 85 },
+ { 1, 0, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 7, 4, 4, 21, 85 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 85 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 17, 85 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 12, 17, 85 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 85 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 85 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 85 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 85 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 85 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 85 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 85 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 85 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 85 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 85 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 85 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 77 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 4, 4, 4, 21, 77 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 7, 4, 4, 21, 77 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 77 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 77 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 77 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 77 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 77 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 77 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 77 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 77 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 77 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 11, 9, 11, 77 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 77 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 12, 17, 77 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 30, 24 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 30, 24 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 30, 24 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 30, 79 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 30, 79 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 30, 79 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 8, 30, 79 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 30, 79 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 86 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 7, 4, 4, 21, 86 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 86 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 12, 17, 86 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 86 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 86 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 27 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 86 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 7, 4, 4, 21, 86 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 86 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 12, 17, 86 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 86 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 86 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 86 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 86 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 86 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 86 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 86 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 86 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 86 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 86 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 11, 9, 11, 86 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 11, 7, 8, 23, 26 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 12, 7, 8, 24, 26 },
{ 11, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 0, 0, 31, 0 },
{ 12, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 25, 22, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 31, 28, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 37, 34, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 44, 40, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 52, 48, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 59, 56, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 71, 68, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
- { 15, 0, 0, 0, -1, 0, 0, 77, 74, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
- { 15, 0, 0, 0, -1, 0, 0, 83, 80, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
- { 15, 0, 0, 0, -1, 0, 0, 89, 86, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
- { 15, 0, 0, 0, -1, 0, 0, 95, 92, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
- { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 13, 4 },
- { 0, 17, 26, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 4 },
- { 26, 3, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 4 },
- { 28, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 5 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 8, 14, 37 },
+ { 15, 0, 0, 0, -1, 0, 0, 25, 22, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 31, 28, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 37, 34, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 44, 40, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 52, 48, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 59, 56, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 3 },
+ { 15, 0, 0, 0, -1, 0, 0, 71, 68, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 6 },
+ { 15, 0, 0, 0, -1, 0, 0, 77, 74, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 6 },
+ { 15, 0, 0, 0, -1, 0, 0, 83, 80, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 6 },
+ { 15, 0, 0, 0, -1, 0, 0, 89, 86, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 6 },
+ { 15, 0, 0, 0, -1, 0, 0, 95, 92, 0, 0, 1, 1, 0, 1, 0, 7, 6, 12, 6 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 7, 8, 13, 7 },
+ { 0, 17, 26, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 21, 7 },
+ { 26, 3, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 7 },
+ { 28, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 8 },
{ 13, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 12, 0 },
- { 27, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 10, 5 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 28 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 10, 11, 8, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 11, 1, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 1, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 9, 11, 8, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 10, 0, 8, 0 },
- { 21, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 0, 0 },
- { 22, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 1, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 15, 0 },
- { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 14, 0 },
- { 19, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 12, 0, 14, 0 },
- { 21, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 13, 0, 0 },
- { 22, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 13, 1, 0 },
- { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 11, 1, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 14, 0 },
- { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 8, 10, 1, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 0, 5, 0 },
- { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 9, 11, 5, 0 },
- { 25, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 26, 3, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 20, 3, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 14, 0 },
- { 26, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 26, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 18, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 5 },
- { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 22, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 8, 0, 14, 0 },
- { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 3, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 3, 2, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 3, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 3, 2, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 3, 2, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 3, 2, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 3, 2, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 3, 2, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 3, 2, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 3, 2, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 26, 10, 0, 0, -1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 26, 10, 0, 0, -1, -2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 14, 0, 0, 0, -1, 0, 32, 0, 0, 32, 0, 0, 0, 0, 1, 0, 7, 7, 14, 0 },
- { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -32, -32, 0, 0, 0, 0, 0, 1, 0, 7, 6, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 8, 12, 0 },
- { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 5, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 23 },
- { 10, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 3, 4, 4, 21, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 29, 0 },
+ { 27, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 10, 8 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 4, 21, 1 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 10, 11, 8, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 11, 1, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 1, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 9, 11, 8, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 10, 0, 8, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 6, 2 },
+ { 21, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 0, 2 },
+ { 22, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 13, 1, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 15, 2 },
+ { 20, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 14, 2 },
+ { 19, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 12, 0, 14, 2 },
+ { 21, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 13, 0, 2 },
+ { 22, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 13, 1, 2 },
+ { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 11, 1, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 14, 2 },
+ { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 8, 10, 1, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 10, 0, 5, 2 },
+ { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 9, 11, 5, 2 },
+ { 25, 4, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 26, 3, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 20, 3, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 11, 14, 2 },
+ { 26, 10, 0, 0, -1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 26, 10, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 18, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 7, 8, 12, 8 },
+ { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 4, 4, 22, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 8, 0, 14, 2 },
+ { 25, 6, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 3, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 3, 2, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 3, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 3, 2, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 3, 2, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 3, 2, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 3, 2, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 3, 2, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 3, 2, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 3, 2, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 26, 10, 0, 0, -1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 26, 10, 0, 0, -1, -2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 14, 0, 0, 0, -1, 0, 32, 0, 0, 32, 0, 0, 0, 0, 1, 0, 7, 7, 14, 3 },
+ { 28, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 14, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, -32, -32, 0, 0, 0, 0, 0, 1, 0, 7, 6, 14, 3 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 8, 12, 35 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 4, 4, 5, 2 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 7, 8, 12, 26 },
+ { 10, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 3, 4, 4, 21, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 29, 2 },
{ 13, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 12, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 17, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 17, 0 },
- { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 0 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 0 },
- { 4, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 1 },
- { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 1 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 1 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 7, 8, 12, 0 },
- { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 12, 0 },
- { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 7, 8, 12, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 17, 0 },
- { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 40, 0, 0, 40, 0, 0, 0, 0, 5, 0, 7, 7, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 40, 0, 0, 40, 0, 0, 0, 0, 7, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -40, -40, 0, 0, 0, 0, 0, 5, 0, 7, 6, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, -40, -40, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 0 },
- { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 0 },
- { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 17, 0 },
- { 5, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 0 },
- { 5, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 0 },
- { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 17, 0 },
- { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 0 },
- { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 0 },
- { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 0 },
- { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 0 },
- { 0, 17, 1, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 0 },
- { 5, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 5, 1, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 5, 1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 5, 1, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 5, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 17, 0 },
- { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 12, 17, 0 },
- { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 0 },
- { 5, 5, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 5 },
- { 5, 5, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 5 },
- { 5, 5, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 5 },
- { 5, 5, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 5 },
- { 5, 5, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 5 },
- { 5, 5, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 5 },
- { 5, 5, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 5 },
- { 5, 5, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 5 },
- { 5, 5, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 5 },
- { 5, 5, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 5 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 12, 17, 0 },
- { 5, 10, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 0 },
- { 10, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 3, 4, 4, 12, 0 },
- { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 0 },
- { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 0 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 0 },
- { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 17, 0 },
- { 1, 0, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 7, 4, 4, 21, 0 },
- { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 0 },
- { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 0, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 1, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 6, 8, 14, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 8, 14, 0 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 12, 0 },
- { 1, 0, 216, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4, 4, 21, 0 },
- { 1, 0, 216, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 7, 4, 4, 21, 0 },
- { 0, 17, 1, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4, 4, 21, 28 },
- { 1, 0, 226, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 7, 4, 4, 21, 0 },
- { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 3, 4, 4, 21, 0 },
- { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4, 4, 21, 28 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4, 4, 21, 28 },
- { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 1 },
- { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 7, 7, 12, 0 },
- { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 7, 6, 12, 0 },
- { 26, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 12, 0 },
- { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 12, 0 },
- { 14, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 7, 12, 0 },
- { 3, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 0 },
- { 3, 2, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 0 },
- { 18, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 5 },
- { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 5 },
- { 5, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 5, 2, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 0 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 0 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 5, 5, 0, 28, 0 },
- { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 14, 0 },
- { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 14, 0 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 49 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 17, 2 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 17, 2 },
+ { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 2 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 2 },
+ { 4, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 4 },
+ { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 4 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 4 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 74 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 75 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 7, 8, 12, 39 },
+ { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 12, 39 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 7, 8, 12, 40 },
+ { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 7, 8, 12, 40 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 50 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 17, 50 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 60 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 17, 60 },
+ { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 60 },
+ { 14, 0, 0, 0, -1, 0, 40, 0, 0, 40, 0, 0, 0, 0, 5, 0, 7, 7, 12, 41 },
+ { 14, 0, 0, 0, -1, 0, 40, 0, 0, 40, 0, 0, 0, 0, 7, 0, 7, 7, 12, 41 },
+ { 15, 0, 0, 0, -1, 0, 0, -40, -40, 0, 0, 0, 0, 0, 5, 0, 7, 6, 12, 41 },
+ { 15, 0, 0, 0, -1, 0, 0, -40, -40, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 41 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 51 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 52 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 52 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 52 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 52 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 52 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 52 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 52 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 52 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 52 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 52 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 11, 9, 11, 52 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 8, 12, 53 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 87 },
+ { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 17, 87 },
+ { 5, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 87 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 64 },
+ { 5, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 64 },
+ { 5, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 64 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 17, 64 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 7, 8, 12, 76 },
+ { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 12, 76 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 98 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 97 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 7, 8, 12, 61 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 61 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 61 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 61 },
+ { 0, 17, 1, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 61 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 61 },
+ { 5, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 61 },
+ { 5, 1, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 61 },
+ { 5, 1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 61 },
+ { 5, 1, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 61 },
+ { 5, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 61 },
+ { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 17, 61 },
+ { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 12, 17, 61 },
+ { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 12, 61 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 88 },
+ { 5, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 88 },
+ { 25, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 88 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 80 },
+ { 25, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 17, 80 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 89 },
+ { 5, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 89 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 90 },
+ { 5, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 90 },
+ { 18, 1, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 91 },
+ { 5, 5, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 8 },
+ { 5, 5, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 8 },
+ { 5, 5, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 8 },
+ { 5, 5, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 8 },
+ { 5, 5, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 8 },
+ { 5, 5, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 8 },
+ { 5, 5, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 8 },
+ { 5, 5, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 8 },
+ { 5, 5, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 8 },
+ { 5, 5, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 8 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 7, 4, 4, 21, 94 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 94 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 94 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 4, 4, 4, 21, 94 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 12, 17, 94 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 94 },
+ { 5, 10, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 94 },
+ { 5, 10, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 94 },
+ { 5, 10, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 94 },
+ { 5, 10, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 94 },
+ { 5, 10, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 94 },
+ { 5, 10, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 94 },
+ { 5, 10, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 94 },
+ { 5, 10, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 94 },
+ { 5, 10, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 94 },
+ { 5, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 94 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 94 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 94 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 94 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 94 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 94 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 94 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 94 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 94 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 94 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 11, 9, 11, 94 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 92 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 7, 4, 4, 21, 92 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 92 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 92 },
+ { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 4, 4, 4, 21, 92 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 92 },
+ { 10, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 3, 4, 4, 12, 92 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 12, 17, 92 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 101 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 101 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 101 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 101 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 101 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 101 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 101 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 101 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 101 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 101 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 101 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 96 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 96 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 96 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 7, 4, 4, 21, 96 },
+ { 0, 17, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 96 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 96 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 96 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 96 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 96 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 96 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 96 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 96 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 96 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 96 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 96 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 17, 96 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 12, 17, 96 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 100 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 7, 4, 4, 21, 100 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 100 },
+ { 1, 0, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 7, 4, 4, 21, 100 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 12, 17, 100 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 100 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 17, 100 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 100 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 100 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 100 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 100 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 100 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 100 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 100 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 100 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 100 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 100 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 102 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 102 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 7, 4, 4, 21, 102 },
+ { 1, 0, 9, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 7, 4, 4, 21, 102 },
+ { 0, 17, 7, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 102 },
+ { 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 102 },
+ { 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 102 },
+ { 3, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 102 },
+ { 3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 102 },
+ { 3, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 102 },
+ { 3, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 102 },
+ { 3, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 102 },
+ { 3, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 102 },
+ { 3, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 102 },
+ { 3, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 11, 9, 11, 102 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 63 },
+ { 4, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 8, 12, 63 },
+ { 25, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 17, 63 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 12, 81 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 0, 81 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 7, 8, 1, 81 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 7, 8, 12, 84 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 99 },
+ { 1, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 7, 4, 4, 21, 99 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 4, 4, 4, 21, 99 },
+ { 17, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 99 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 6, 8, 14, 35 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 8, 14, 34 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 12, 2 },
+ { 1, 0, 216, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4, 4, 21, 2 },
+ { 1, 0, 216, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 7, 4, 4, 21, 2 },
+ { 0, 17, 1, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4, 4, 21, 1 },
+ { 1, 0, 226, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 7, 4, 4, 21, 2 },
+ { 10, 18, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 3, 4, 4, 21, 2 },
+ { 0, 17, 220, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4, 4, 21, 1 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4, 4, 21, 1 },
+ { 0, 17, 230, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 4, 4, 4, 21, 4 },
+ { 5, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0, 0, 12, 2 },
+ { 14, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 7, 7, 12, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 7, 6, 12, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 7, 6, 12, 2 },
+ { 26, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 12, 2 },
+ { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 12, 2 },
+ { 14, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 7, 12, 2 },
+ { 15, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 7, 6, 12, 2 },
+ { 3, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 2 },
+ { 3, 2, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 11, 9, 11, 2 },
+ { 18, 13, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 7, 8, 12, 8 },
+ { 26, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 8 },
+ { 5, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 5, 2, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 12, 2 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 12, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 12, 2 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 5, 5, 0, 28, 2 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0, 0, 0, 14, 34 },
+ { 29, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 14, 2 },
+ { 29, 10, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 13, 0, 0, 0, 14, 2 },
{ 13, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 12, 0 },
- { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 8, 14, 0 },
- { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 28 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 8, 14, 37 },
+ { 18, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 8, 14, 37 },
+ { 0, 17, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 7, 4, 4, 4, 21, 1 },
{ 12, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 12, 0 }
};
@@ -6369,11 +6724,6 @@ Q_CORE_EXPORT LineBreakClass QT_FASTCALL lineBreakClass(uint ucs4)
return (LineBreakClass)qGetProp(ucs4)->lineBreakClass;
}
-Q_CORE_EXPORT Script QT_FASTCALL script(uint ucs4)
-{
- return (Script)qGetProp(ucs4)->script;
-}
-
static const ushort specialCaseMap[] = {
0x0, // placeholder
diff --git a/src/corelib/tools/qunicodetables_p.h b/src/corelib/tools/qunicodetables_p.h
index 74b022d8ef..8f0b7aabad 100644
--- a/src/corelib/tools/qunicodetables_p.h
+++ b/src/corelib/tools/qunicodetables_p.h
@@ -83,119 +83,12 @@ struct Properties {
ushort wordBreakClass : 8; /* 4 used */
ushort sentenceBreakClass : 8; /* 4 used */
ushort lineBreakClass : 8; /* 6 used */
- ushort script : 8; /* 5 used */
+ ushort script : 8; /* 7 used */
};
Q_CORE_EXPORT const Properties * QT_FASTCALL properties(uint ucs4);
Q_CORE_EXPORT const Properties * QT_FASTCALL properties(ushort ucs2);
-// See http://www.unicode.org/reports/tr24/tr24-5.html
-enum Script {
- Common,
- Greek,
- Cyrillic,
- Armenian,
- Hebrew,
- Arabic,
- Syriac,
- Thaana,
- Devanagari,
- Bengali,
- Gurmukhi,
- Gujarati,
- Oriya,
- Tamil,
- Telugu,
- Kannada,
- Malayalam,
- Sinhala,
- Thai,
- Lao,
- Tibetan,
- Myanmar,
- Georgian,
- Hangul,
- Ogham,
- Runic,
- Khmer,
- Nko,
- Inherited,
- ScriptCount = Inherited,
- Latin = Common,
- Ethiopic = Common,
- Cherokee = Common,
- CanadianAboriginal = Common,
- Mongolian = Common,
- Hiragana = Common,
- Katakana = Common,
- Bopomofo = Common,
- Han = Common,
- Yi = Common,
- OldItalic = Common,
- Gothic = Common,
- Deseret = Common,
- Tagalog = Common,
- Hanunoo = Common,
- Buhid = Common,
- Tagbanwa = Common,
- Limbu = Common,
- TaiLe = Common,
- LinearB = Common,
- Ugaritic = Common,
- Shavian = Common,
- Osmanya = Common,
- Cypriot = Common,
- Braille = Common,
- Buginese = Common,
- Coptic = Common,
- NewTaiLue = Common,
- Glagolitic = Common,
- Tifinagh = Common,
- SylotiNagri = Common,
- OldPersian = Common,
- Kharoshthi = Common,
- Balinese = Common,
- Cuneiform = Common,
- Phoenician = Common,
- PhagsPa = Common,
- Sundanese = Common,
- Lepcha = Common,
- OlChiki = Common,
- Vai = Common,
- Saurashtra = Common,
- KayahLi = Common,
- Rejang = Common,
- Lycian = Common,
- Carian = Common,
- Lydian = Common,
- Cham = Common,
- TaiTham = Common,
- TaiViet = Common,
- Avestan = Common,
- EgyptianHieroglyphs = Common,
- Samaritan = Common,
- Lisu = Common,
- Bamum = Common,
- Javanese = Common,
- MeeteiMayek = Common,
- ImperialAramaic = Common,
- OldSouthArabian = Common,
- InscriptionalParthian = Common,
- InscriptionalPahlavi = Common,
- OldTurkic = Common,
- Kaithi = Common,
- Batak = Common,
- Brahmi = Common,
- Mandaic = Common,
- Chakma = Common,
- MeroiticCursive = Common,
- MeroiticHieroglyphs = Common,
- Miao = Common,
- Sharada = Common,
- SoraSompeng = Common,
- Takri = Common
-};
-
enum GraphemeBreakClass {
GraphemeBreak_Other,
GraphemeBreak_CR,
@@ -274,10 +167,6 @@ Q_CORE_EXPORT LineBreakClass QT_FASTCALL lineBreakClass(uint ucs4);
inline LineBreakClass lineBreakClass(QChar ch)
{ return lineBreakClass(ch.unicode()); }
-Q_CORE_EXPORT Script QT_FASTCALL script(uint ucs4);
-inline Script script(QChar ch)
-{ return script(ch.unicode()); }
-
} // namespace QUnicodeTables
QT_END_NAMESPACE
diff --git a/src/corelib/tools/qunicodetools.cpp b/src/corelib/tools/qunicodetools.cpp
index 060c9adb05..4d5c978fd5 100644
--- a/src/corelib/tools/qunicodetools.cpp
+++ b/src/corelib/tools/qunicodetools.cpp
@@ -44,7 +44,7 @@
#include "qunicodetables_p.h"
#include "qvarlengtharray.h"
-#include <private/harfbuzz-shaper.h>
+#include "qharfbuzz_p.h"
#define FLAG(x) (1 << (x))
@@ -610,12 +610,12 @@ Q_CORE_EXPORT void initCharAttributes(const ushort *string, int length,
scriptItems.reserve(numItems);
int start = 0;
for (int i = start + 1; i < numItems; ++i) {
- if (items[i].script == items[start].script)
+ if (script_to_hbscript(items[i].script) == script_to_hbscript(items[start].script))
continue;
HB_ScriptItem item;
item.pos = items[start].position;
item.length = items[i].position - items[start].position;
- item.script = (HB_Script)items[start].script;
+ item.script = script_to_hbscript(items[start].script);
item.bidiLevel = 0; // unused
scriptItems.append(item);
start = i;
@@ -624,7 +624,7 @@ Q_CORE_EXPORT void initCharAttributes(const ushort *string, int length,
HB_ScriptItem item;
item.pos = items[start].position;
item.length = length - items[start].position;
- item.script = (HB_Script)items[start].script;
+ item.script = script_to_hbscript(items[start].script);
item.bidiLevel = 0; // unused
scriptItems.append(item);
}
@@ -635,6 +635,51 @@ Q_CORE_EXPORT void initCharAttributes(const ushort *string, int length,
}
}
+
+// ----------------------------------------------------------------------------
+//
+// The Unicode script property. See http://www.unicode.org/reports/tr24/ (some very old version)
+//
+// ----------------------------------------------------------------------------
+
+Q_CORE_EXPORT void initScripts(const ushort *string, int length, uchar *scripts)
+{
+ int sor = 0;
+ int eor = -1;
+ uchar script = QChar::Script_Common;
+ for (int i = 0; i < length; ++i) {
+ eor = i;
+ uint ucs4 = string[i];
+ if (QChar::isHighSurrogate(ucs4) && i + 1 < length) {
+ ushort low = string[i + 1];
+ if (QChar::isLowSurrogate(low)) {
+ ucs4 = QChar::surrogateToUcs4(ucs4, low);
+ ++i;
+ }
+ }
+
+ const QUnicodeTables::Properties *prop = QUnicodeTables::properties(ucs4);
+
+ if (Q_LIKELY(prop->script == script || prop->script == QChar::Script_Inherited))
+ continue;
+
+ // Never break between a combining mark (gc= Mc, Mn or Me) and its base character.
+ // Thus, a combining mark — whatever its script property value is — should inherit
+ // the script property value of its base character.
+ static const int test = (FLAG(QChar::Mark_NonSpacing) | FLAG(QChar::Mark_SpacingCombining) | FLAG(QChar::Mark_Enclosing));
+ if (Q_UNLIKELY(FLAG(prop->category) & test))
+ continue;
+
+ while (sor < eor)
+ scripts[sor++] = script;
+
+ script = prop->script;
+ }
+ eor = length;
+ while (sor < eor)
+ scripts[sor++] = script;
+}
+
} // namespace QUnicodeTools
QT_END_NAMESPACE
diff --git a/src/corelib/tools/qunicodetools_p.h b/src/corelib/tools/qunicodetools_p.h
index 5a4f1659c4..5db3126159 100644
--- a/src/corelib/tools/qunicodetools_p.h
+++ b/src/corelib/tools/qunicodetools_p.h
@@ -96,6 +96,9 @@ Q_CORE_EXPORT void initCharAttributes(const ushort *string, int length,
const ScriptItem *items, int numItems,
QCharAttributes *attributes, CharAttributeOptions options = DefaultOptionsCompat);
+
+Q_CORE_EXPORT void initScripts(const ushort *string, int length, uchar *scripts);
+
} // namespace QUnicodeTools
QT_END_NAMESPACE
diff --git a/src/corelib/tools/qvarlengtharray.h b/src/corelib/tools/qvarlengtharray.h
index 5e57de5767..3a2028057d 100644
--- a/src/corelib/tools/qvarlengtharray.h
+++ b/src/corelib/tools/qvarlengtharray.h
@@ -50,8 +50,6 @@
#include <string.h>
#include <stdlib.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -103,6 +101,7 @@ public:
inline bool isEmpty() const { return (s == 0); }
inline void resize(int size);
inline void clear() { resize(0); }
+ inline void squeeze();
inline int capacity() const { return a; }
inline void reserve(int size);
@@ -244,6 +243,10 @@ Q_OUTOFLINE_TEMPLATE void QVarLengthArray<T, Prealloc>::append(const T *abuf, in
}
template <class T, int Prealloc>
+Q_INLINE_TEMPLATE void QVarLengthArray<T, Prealloc>::squeeze()
+{ realloc(s, s); }
+
+template <class T, int Prealloc>
Q_OUTOFLINE_TEMPLATE void QVarLengthArray<T, Prealloc>::realloc(int asize, int aalloc)
{
Q_ASSERT(aalloc >= asize);
@@ -415,6 +418,4 @@ bool operator!=(const QVarLengthArray<T, Prealloc1> &l, const QVarLengthArray<T,
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QVARLENGTHARRAY_H
diff --git a/src/corelib/tools/qvarlengtharray.qdoc b/src/corelib/tools/qvarlengtharray.qdoc
index 5e78946892..93aa5e993e 100644
--- a/src/corelib/tools/qvarlengtharray.qdoc
+++ b/src/corelib/tools/qvarlengtharray.qdoc
@@ -210,7 +210,7 @@
initialized. For other types, the elements are initialized with a
\l{default-constructed value}.
- \sa size()
+ \sa size(), squeeze()
*/
/*! \fn int QVarLengthArray::capacity() const
@@ -223,7 +223,7 @@
need to call this function. If you want to know how many items are
in the array, call size().
- \sa reserve()
+ \sa reserve(), squeeze()
*/
/*! \fn void QVarLengthArray::reserve(int size)
@@ -240,7 +240,21 @@
rarely ever need to call this function. If you want to change the
size of the array, call resize().
- \sa capacity()
+ \sa capacity(), squeeze()
+*/
+
+/*! \fn void QVarLengthArray::squeeze()
+ \since 5.1
+
+ Releases any memory not required to store the items.
+ If the container can fit its storage on the stack allocation,
+ it will free the heap allocation and copy the elements back to the stack.
+
+ The sole purpose of this function is to provide a means of fine
+ tuning QVarLengthArray's memory usage. In general, you will rarely ever
+ need to call this function.
+
+ \sa reserve(), capacity(), resize()
*/
/*! \fn T &QVarLengthArray::operator[](int i)
diff --git a/src/corelib/tools/qvector.cpp b/src/corelib/tools/qvector.cpp
index efc4b6a446..a443a6b4e8 100644
--- a/src/corelib/tools/qvector.cpp
+++ b/src/corelib/tools/qvector.cpp
@@ -230,7 +230,8 @@
Construct a vector from the std::initilizer_list given by \a args.
- This constructor is only enabled if the compiler supports C++0x
+ This constructor is only enabled if the compiler supports C++11 initializer
+ lists.
*/
@@ -435,7 +436,7 @@
Same as at(\a i).
*/
-/*!
+/*!
\fn void QVector::append(const T &value)
Inserts \a value at the end of the vector.
@@ -544,6 +545,48 @@
\sa insert(), replace(), fill()
*/
+/*! \fn void QVector::removeFirst()
+ \since 5.1
+ Removes the first item in the vector. Calling this function is
+ equivalent to calling remove(0). The vector must not be empty. If
+ the vector can be empty, call isEmpty() before calling this
+ function.
+
+ \sa remove(), takeFirst(), isEmpty()
+*/
+
+/*! \fn void QVector::removeLast()
+ \since 5.1
+ Removes the last item in the vector. Calling this function is
+ equivalent to calling remove(size() - 1). The vector must not be
+ empty. If the vector can be empty, call isEmpty() before calling
+ this function.
+
+ \sa remove(), takeLast(), removeFirst(), isEmpty()
+*/
+
+/*! \fn T QVector::takeFirst()
+
+ Removes the first item in the vector and returns it. This function
+ assumes the vector is not empty. To avoid failure, call isEmpty()
+ before calling this function.
+
+ \sa takeLast(), removeFirst()
+*/
+
+/*! \fn T QVector::takeLast()
+
+ Removes the last item in the list and returns it. This function
+ assumes the vector is not empty. To avoid failure, call isEmpty()
+ before calling this function.
+
+ If you don't use the return value, removeLast() is more
+ efficient.
+
+ \sa takeFirst(), removeLast()
+*/
+
+
/*! \fn QVector &QVector::fill(const T &value, int size = -1)
Assigns \a value to all items in the vector. If \a size is
@@ -773,13 +816,13 @@
/*! \fn void QVector::pop_front()
This function is provided for STL compatibility. It is equivalent
- to erase(begin()).
+ to removeFirst().
*/
/*! \fn void QVector::pop_back()
This function is provided for STL compatibility. It is equivalent
- to erase(end() - 1).
+ to removeLast().
*/
/*! \fn T& QVector::front()
diff --git a/src/corelib/tools/qvector.h b/src/corelib/tools/qvector.h
index 94f3008274..a06fb7b4eb 100644
--- a/src/corelib/tools/qvector.h
+++ b/src/corelib/tools/qvector.h
@@ -56,8 +56,6 @@
#include <initializer_list>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QRegion;
@@ -140,6 +138,10 @@ public:
void replace(int i, const T &t);
void remove(int i);
void remove(int i, int n);
+ inline void removeFirst() { Q_ASSERT(!isEmpty()); erase(d->begin()); }
+ inline void removeLast();
+ inline T takeFirst() { Q_ASSERT(!isEmpty()); T r = first(); removeFirst(); return r; }
+ inline T takeLast() { Q_ASSERT(!isEmpty()); T r = last(); removeLast(); return r; }
QVector<T> &fill(const T &t, int size = -1);
@@ -200,8 +202,8 @@ public:
typedef int size_type;
inline void push_back(const T &t) { append(t); }
inline void push_front(const T &t) { prepend(t); }
- void pop_back() { Q_ASSERT(!isEmpty()); erase(d->end() - 1); }
- void pop_front() { Q_ASSERT(!isEmpty()); erase(d->begin()); }
+ void pop_back() { removeLast(); }
+ void pop_front() { removeFirst(); }
inline bool empty() const
{ return d->size == 0; }
inline T& front() { return first(); }
@@ -556,6 +558,22 @@ void QVector<T>::append(const T &t)
}
template <typename T>
+inline void QVector<T>::removeLast()
+{
+ Q_ASSERT(!isEmpty());
+
+ if (d->alloc) {
+ if (d->ref.isShared()) {
+ reallocData(d->size - 1, int(d->alloc));
+ return;
+ }
+ if (QTypeInfo<T>::isComplex)
+ (d->data() + d->size - 1)->~T();
+ --d->size;
+ }
+}
+
+template <typename T>
typename QVector<T>::iterator QVector<T>::insert(iterator before, size_type n, const T &t)
{
int offset = std::distance(d->begin(), before);
@@ -604,6 +622,7 @@ typename QVector<T>::iterator QVector<T>::erase(iterator abegin, iterator aend)
// FIXME we could do a proper realloc, which copy constructs only needed data.
// FIXME we ara about to delete data maybe it is good time to shrink?
+ // FIXME the shrink is also an issue in removeLast, that is just a copy + reduce of this.
if (d->alloc) {
detach();
abegin = d->begin() + itemsUntouched;
@@ -813,6 +832,4 @@ Q_TEMPLATE_EXTERN template class Q_CORE_EXPORT QVector<QPoint>;
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QVECTOR_H
diff --git a/src/corelib/tools/tools.pri b/src/corelib/tools/tools.pri
index 72a873235a..40858e5336 100644
--- a/src/corelib/tools/tools.pri
+++ b/src/corelib/tools/tools.pri
@@ -29,6 +29,7 @@ HEADERS += \
tools/qlocale_data_p.h \
tools/qmap.h \
tools/qmargins.h \
+ tools/qmessageauthenticationcode.h \
tools/qcontiguouscache.h \
tools/qpodlist_p.h \
tools/qpair.h \
@@ -82,6 +83,7 @@ SOURCES += \
tools/qpoint.cpp \
tools/qmap.cpp \
tools/qmargins.cpp \
+ tools/qmessageauthenticationcode.cpp \
tools/qcontiguouscache.cpp \
tools/qrect.cpp \
tools/qregexp.cpp \
@@ -104,6 +106,10 @@ SOURCES += \
SOURCES += tools/qelapsedtimer_mac.cpp
OBJECTIVE_SOURCES += tools/qlocale_mac.mm
}
+else:blackberry {
+ SOURCES += tools/qelapsedtimer_unix.cpp tools/qlocale_blackberry.cpp
+ HEADERS += tools/qlocale_blackberry.h
+}
else:unix:SOURCES += tools/qelapsedtimer_unix.cpp tools/qlocale_unix.cpp
else:win32:SOURCES += tools/qelapsedtimer_win.cpp tools/qlocale_win.cpp
else:integrity:SOURCES += tools/qelapsedtimer_unix.cpp tools/qlocale_unix.cpp
@@ -143,7 +149,7 @@ pcre {
LIBS_PRIVATE += -lpcre16
}
-DEFINES += HB_EXPORT=Q_CORE_EXPORT
+INCLUDEPATH += ../3rdparty/harfbuzz/src
HEADERS += ../3rdparty/harfbuzz/src/harfbuzz.h
SOURCES += ../3rdparty/harfbuzz/src/harfbuzz-buffer.c \
../3rdparty/harfbuzz/src/harfbuzz-gdef.c \
@@ -157,7 +163,8 @@ SOURCES += ../3rdparty/harfbuzz/src/harfbuzz-buffer.c \
HEADERS += tools/qharfbuzz_p.h
INCLUDEPATH += ../3rdparty/md5 \
- ../3rdparty/md4
+ ../3rdparty/md4 \
+ ../3rdparty/sha3
# Note: libm should be present by default becaue this is C++
!macx-icc:!vxworks:unix:LIBS_PRIVATE += -lm
diff --git a/src/corelib/xml/qxmlstream.cpp b/src/corelib/xml/qxmlstream.cpp
index 4be4593e95..372b1d91fe 100644
--- a/src/corelib/xml/qxmlstream.cpp
+++ b/src/corelib/xml/qxmlstream.cpp
@@ -784,6 +784,7 @@ QXmlStreamPrivateTagStack::QXmlStreamPrivateTagStack()
NamespaceDeclaration &namespaceDeclaration = namespaceDeclarations.push();
namespaceDeclaration.prefix = addToStringStorage(QLatin1String("xml"));
namespaceDeclaration.namespaceUri = addToStringStorage(QLatin1String("http://www.w3.org/XML/1998/namespace"));
+ initialTagStackStringStorageSize = tagStackStringStorageSize;
}
#ifndef QT_NO_XMLSTREAMREADER
@@ -854,6 +855,7 @@ void QXmlStreamReaderPrivate::init()
rawReadBuffer.clear();
dataBuffer.clear();
readBuffer.clear();
+ tagStackStringStorageSize = initialTagStackStringStorageSize;
type = QXmlStreamReader::NoToken;
error = QXmlStreamReader::NoError;
diff --git a/src/corelib/xml/qxmlstream.h b/src/corelib/xml/qxmlstream.h
index e3336122f9..8a9c2fcb76 100644
--- a/src/corelib/xml/qxmlstream.h
+++ b/src/corelib/xml/qxmlstream.h
@@ -50,8 +50,6 @@
#include <QtCore/qvector.h>
#include <QtCore/qscopedpointer.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -426,7 +424,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_XMLSTREAM
#endif // QXMLSTREAM_H
diff --git a/src/corelib/xml/qxmlstream_p.h b/src/corelib/xml/qxmlstream_p.h
index 68b7ff7af3..448764ab58 100644
--- a/src/corelib/xml/qxmlstream_p.h
+++ b/src/corelib/xml/qxmlstream_p.h
@@ -697,6 +697,7 @@ public:
QXmlStreamSimpleStack<NamespaceDeclaration> namespaceDeclarations;
QString tagStackStringStorage;
int tagStackStringStorageSize;
+ int initialTagStackStringStorageSize;
bool tagsDone;
inline QStringRef addToStringStorage(const QStringRef &s) {
diff --git a/src/corelib/xml/qxmlutils.cpp b/src/corelib/xml/qxmlutils.cpp
index 52921919eb..d175d554cc 100644
--- a/src/corelib/xml/qxmlutils.cpp
+++ b/src/corelib/xml/qxmlutils.cpp
@@ -70,7 +70,7 @@ bool QXmlUtils::rangeContains(RangeIter begin, RangeIter end, const QChar c)
// check the first two ranges "manually" as characters in that
// range are checked very often and we avoid the binary search below.
-
+
if (cp <= begin->max)
return cp >= begin->min;
diff --git a/src/dbus/dbus.pro b/src/dbus/dbus.pro
index 5ad77ddf95..2e4119ba93 100644
--- a/src/dbus/dbus.pro
+++ b/src/dbus/dbus.pro
@@ -6,6 +6,8 @@ MODULE_CONFIG = dbusadaptors dbusinterfaces
!isEmpty(DBUS_PATH) {
INCLUDEPATH += $$DBUS_PATH/include
QMAKE_LIBDIR += $$DBUS_PATH/lib
+ win32:CONFIG(debug, debug|release):QT_LIBS_DBUS += -ldbus-1d
+ else:QT_LIBS_DBUS += -ldbus-1
}
DEFINES += DBUS_API_SUBJECT_TO_CHANGE
@@ -21,8 +23,6 @@ win32 {
-ladvapi32 \
-lnetapi32 \
-luser32
- CONFIG(debug, debug|release):LIBS_PRIVATE += -ldbus-1d
- else:LIBS_PRIVATE += -ldbus-1
}
QMAKE_DOCS = $$PWD/doc/qtdbus.qdocconf
diff --git a/src/dbus/doc/snippets/code/doc_src_qdbusadaptors.cpp b/src/dbus/doc/snippets/code/doc_src_qdbusadaptors.cpp
index 35fe0a5a3f..4511dcb346 100644
--- a/src/dbus/doc/snippets/code/doc_src_qdbusadaptors.cpp
+++ b/src/dbus/doc/snippets/code/doc_src_qdbusadaptors.cpp
@@ -146,7 +146,7 @@ int main(int argc, char **argv)
new MainApplicationAdaptor(app);
// connect to D-Bus and register as an object:
- QDBusConnection::sessionBus().registerObject("/MainApplication", app);
+ QDBusConnection::sessionBus().registerObject("/MainApplication", &app);
// add main window, etc.
[...]
diff --git a/src/dbus/qdbus_symbols_p.h b/src/dbus/qdbus_symbols_p.h
index c1e36b0175..9e81bac30e 100644
--- a/src/dbus/qdbus_symbols_p.h
+++ b/src/dbus/qdbus_symbols_p.h
@@ -176,7 +176,7 @@ DEFINEFUNC(dbus_bool_t , dbus_timeout_handle, (DBusTimeout *timeout),
DEFINEFUNC(dbus_bool_t , dbus_watch_get_enabled, (DBusWatch *watch),
(watch), return)
-DEFINEFUNC(int , dbus_watch_get_fd, (DBusWatch *watch),
+DEFINEFUNC(int , dbus_watch_get_unix_fd, (DBusWatch *watch),
(watch), return)
DEFINEFUNC(unsigned int , dbus_watch_get_flags, (DBusWatch *watch),
(watch), return)
diff --git a/src/dbus/qdbusabstractadaptor.h b/src/dbus/qdbusabstractadaptor.h
index 1f414b0d92..2a32344de5 100644
--- a/src/dbus/qdbusabstractadaptor.h
+++ b/src/dbus/qdbusabstractadaptor.h
@@ -47,8 +47,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -72,8 +70,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbusabstractinterface.cpp b/src/dbus/qdbusabstractinterface.cpp
index 2a8681d1d7..53def1beb6 100644
--- a/src/dbus/qdbusabstractinterface.cpp
+++ b/src/dbus/qdbusabstractinterface.cpp
@@ -513,7 +513,7 @@ QDBusPendingCall QDBusAbstractInterface::asyncCallWithArgumentList(const QString
not indicate that the executed call succeeded. If it fails,
the \a errorMethod is called. If the queueing failed, this
function returns false and no slot will be called.
-
+
The \a returnMethod must have as its parameters the types returned
by the function call. Optionally, it may have a QDBusMessage
parameter as its last or only parameter. The \a errorMethod must
@@ -609,9 +609,22 @@ void QDBusAbstractInterface::disconnectNotify(const QMetaMethod &signal)
return;
QDBusConnectionPrivate *conn = d->connectionPrivate();
- if (conn)
- conn->disconnectRelay(d->service, d->path, d->interface,
- this, signal);
+ if (conn && signal.isValid() && !isSignalConnected(signal))
+ return conn->disconnectRelay(d->service, d->path, d->interface,
+ this, signal);
+ if (!conn)
+ return;
+
+ // wildcard disconnecting, we need to figure out which of our signals are
+ // no longer connected to anything
+ const QMetaObject *mo = metaObject();
+ int midx = QObject::staticMetaObject.methodCount();
+ const int end = mo->methodCount();
+ for ( ; midx < end; ++midx) {
+ QMetaMethod mm = mo->method(midx);
+ if (mm.methodType() == QMetaMethod::Signal && !isSignalConnected(mm))
+ conn->disconnectRelay(d->service, d->path, d->interface, this, mm);
+ }
}
/*!
diff --git a/src/dbus/qdbusabstractinterface.h b/src/dbus/qdbusabstractinterface.h
index ae094c000b..8f014ce151 100644
--- a/src/dbus/qdbusabstractinterface.h
+++ b/src/dbus/qdbusabstractinterface.h
@@ -53,8 +53,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -161,7 +159,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbusargument.h b/src/dbus/qdbusargument.h
index c0bce586ac..a3a6f990fc 100644
--- a/src/dbus/qdbusargument.h
+++ b/src/dbus/qdbusargument.h
@@ -55,8 +55,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -397,10 +395,25 @@ inline QDBusArgument &operator<<(QDBusArgument &arg, const QVariantHash &map)
return arg;
}
+template <typename T1, typename T2>
+inline QDBusArgument &operator<<(QDBusArgument &arg, const QPair<T1, T2> &pair)
+{
+ arg.beginStructure();
+ arg << pair.first << pair.second;
+ arg.endStructure();
+ return arg;
+}
-QT_END_NAMESPACE
+template <typename T1, typename T2>
+inline const QDBusArgument &operator>>(const QDBusArgument &arg, QPair<T1, T2> &pair)
+{
+ arg.beginStructure();
+ arg >> pair.first >> pair.second;
+ arg.endStructure();
+ return arg;
+}
-QT_END_HEADER
+QT_END_NAMESPACE
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbusconnection.cpp b/src/dbus/qdbusconnection.cpp
index d576112f8d..74a3a752a5 100644
--- a/src/dbus/qdbusconnection.cpp
+++ b/src/dbus/qdbusconnection.cpp
@@ -803,13 +803,8 @@ bool QDBusConnection::registerObject(const QString &path, QObject *object, Regis
return false;
if (options & QDBusConnectionPrivate::VirtualObject) {
- // technically the check for children needs to go even deeper
- if (options & SubPath) {
- foreach (const QDBusConnectionPrivate::ObjectTreeNode &child, node->children) {
- if (child.obj)
- return false;
- }
- }
+ if (options & SubPath && node->activeChildren)
+ return false;
} else {
if ((options & ExportChildObjects && !node->children.isEmpty()))
return false;
@@ -825,8 +820,8 @@ bool QDBusConnection::registerObject(const QString &path, QObject *object, Regis
// if a virtual object occupies this path, return false
if (node->obj && (node->flags & QDBusConnectionPrivate::VirtualObject) && (node->flags & QDBusConnection::SubPath)) {
- qDebug("Cannot register object at %s because QDBusVirtualObject handles all sub-paths.",
- qPrintable(path));
+ //qDebug("Cannot register object at %s because QDBusVirtualObject handles all sub-paths.",
+ // qPrintable(path));
return false;
}
@@ -840,12 +835,13 @@ bool QDBusConnection::registerObject(const QString &path, QObject *object, Regis
// are we allowed to go deeper?
if (node->flags & ExportChildObjects) {
// we're not
- qDebug("Cannot register object at %s because %s exports its own child objects",
- qPrintable(path), qPrintable(pathComponents.at(i)));
+ //qDebug("Cannot register object at %s because %s exports its own child objects",
+ // qPrintable(path), qPrintable(pathComponents.at(i)));
return false;
}
} else {
// add entry
+ ++node->activeChildren;
node = node->children.insert(it, pathComponents.at(i));
}
@@ -883,35 +879,8 @@ void QDBusConnection::unregisterObject(const QString &path, UnregisterMode mode)
if (!d || !d->connection || !QDBusUtil::isValidObjectPath(path))
return;
- QStringList pathComponents = path.split(QLatin1Char('/'));
QDBusWriteLocker locker(UnregisterObjectAction, d);
- QDBusConnectionPrivate::ObjectTreeNode *node = &d->rootNode;
- int i = 1;
-
- // find the object
- while (node) {
- if (pathComponents.count() == i || !path.compare(QLatin1String("/"))) {
- // found it
- node->obj = 0;
- node->flags = 0;
-
- if (mode == UnregisterTree) {
- // clear the sub-tree as well
- node->children.clear(); // can't disconnect the objects because we really don't know if they can
- // be found somewhere else in the path too
- }
-
- return;
- }
-
- QDBusConnectionPrivate::ObjectTreeNode::DataList::Iterator it =
- std::lower_bound(node->children.begin(), node->children.end(), pathComponents.at(i));
- if (it == node->children.end() || it->name != pathComponents.at(i))
- break; // node not found
-
- node = it;
- ++i;
- }
+ d->unregisterObject(path, mode);
}
/*!
diff --git a/src/dbus/qdbusconnection.h b/src/dbus/qdbusconnection.h
index 35559ba37a..20a579f8d6 100644
--- a/src/dbus/qdbusconnection.h
+++ b/src/dbus/qdbusconnection.h
@@ -47,8 +47,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -208,7 +206,5 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QDBusConnection::VirtualObjectRegisterOptions)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbusconnection_p.h b/src/dbus/qdbusconnection_p.h
index 2c3ddefc50..73c8dcf411 100644
--- a/src/dbus/qdbusconnection_p.h
+++ b/src/dbus/qdbusconnection_p.h
@@ -140,14 +140,16 @@ public:
{
typedef QVector<ObjectTreeNode> DataList;
- inline ObjectTreeNode() : obj(0), flags(0) { }
+ inline ObjectTreeNode() : obj(0), flags(0), activeChildren(0) { }
inline ObjectTreeNode(const QString &n) // intentionally implicit
- : name(n), obj(0), flags(0) { }
+ : name(n), obj(0), flags(0), activeChildren(0) { }
inline ~ObjectTreeNode() { }
inline bool operator<(const QString &other) const
{ return name < other; }
inline bool operator<(const QStringRef &other) const
{ return QStringRef(&name) < other; }
+ inline bool isActive() const
+ { return obj || activeChildren; }
QString name;
union {
@@ -155,6 +157,7 @@ public:
QDBusVirtualObject *treeNode;
};
int flags;
+ int activeChildren;
DataList children;
};
@@ -208,6 +211,7 @@ public:
const QString &name, const QStringList &argumentMatch, const QString &signature,
QObject *receiver, const char *slot);
void registerObject(const ObjectTreeNode *node);
+ void unregisterObject(const QString &path, QDBusConnection::UnregisterMode mode);
void connectRelay(const QString &service,
const QString &path, const QString &interface,
QDBusAbstractInterface *receiver, const QMetaMethod &signal);
@@ -340,8 +344,8 @@ public:
// in qdbusmisc.cpp
extern int qDBusParametersForMethod(const QMetaMethod &mm, QVector<int> &metaTypes);
#endif // QT_BOOTSTRAPPED
-extern int qDBusParametersForMethod(const QList<QByteArray> &parameters, QVector<int>& metaTypes);
-extern bool qDBusCheckAsyncTag(const char *tag);
+extern Q_DBUS_EXPORT int qDBusParametersForMethod(const QList<QByteArray> &parameters, QVector<int>& metaTypes);
+extern Q_DBUS_EXPORT bool qDBusCheckAsyncTag(const char *tag);
#ifndef QT_BOOTSTRAPPED
extern bool qDBusInterfaceInObject(QObject *obj, const QString &interface_name);
extern QString qDBusInterfaceFromMetaObject(const QMetaObject *mo);
diff --git a/src/dbus/qdbusconnectioninterface.h b/src/dbus/qdbusconnectioninterface.h
index 6c45201445..b900d2a64c 100644
--- a/src/dbus/qdbusconnectioninterface.h
+++ b/src/dbus/qdbusconnectioninterface.h
@@ -49,8 +49,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -125,7 +123,5 @@ QT_END_NAMESPACE
Q_DECLARE_BUILTIN_METATYPE(UInt, QMetaType::UInt, QDBusConnectionInterface::RegisterServiceReply)
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbuscontext.h b/src/dbus/qdbuscontext.h
index 4578c30626..82dc7783bf 100644
--- a/src/dbus/qdbuscontext.h
+++ b/src/dbus/qdbuscontext.h
@@ -47,8 +47,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -80,7 +78,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbuserror.cpp b/src/dbus/qdbuserror.cpp
index d578bf7d76..f486c19fdc 100644
--- a/src/dbus/qdbuserror.cpp
+++ b/src/dbus/qdbuserror.cpp
@@ -72,7 +72,7 @@ for ($j = 0; $j < $i; ++$j) {
}
print "0\n};\n";
===== PERL SCRIPT ====
-
+
* The input data is as follows:
other
org.freedesktop.DBus.Error.Failed
diff --git a/src/dbus/qdbuserror.h b/src/dbus/qdbuserror.h
index ae738d0860..2c4ec6ce71 100644
--- a/src/dbus/qdbuserror.h
+++ b/src/dbus/qdbuserror.h
@@ -47,8 +47,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
struct DBusError;
QT_BEGIN_NAMESPACE
@@ -129,7 +127,5 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QDBusError)
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbusextratypes.h b/src/dbus/qdbusextratypes.h
index 0c68c79ac1..ba99d45c0d 100644
--- a/src/dbus/qdbusextratypes.h
+++ b/src/dbus/qdbusextratypes.h
@@ -51,8 +51,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -177,7 +175,5 @@ Q_DECLARE_METATYPE(QDBusVariant)
Q_DECLARE_METATYPE(QDBusObjectPath)
Q_DECLARE_METATYPE(QDBusSignature)
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbusintegrator.cpp b/src/dbus/qdbusintegrator.cpp
index 1cf9de5610..afb8506b28 100644
--- a/src/dbus/qdbusintegrator.cpp
+++ b/src/dbus/qdbusintegrator.cpp
@@ -244,7 +244,7 @@ static dbus_bool_t qDBusAddWatch(DBusWatch *watch, void *data)
QDBusConnectionPrivate *d = static_cast<QDBusConnectionPrivate *>(data);
int flags = q_dbus_watch_get_flags(watch);
- int fd = q_dbus_watch_get_fd(watch);
+ int fd = q_dbus_watch_get_unix_fd(watch);
if (QCoreApplication::instance() && QThread::currentThread() == d->thread()) {
return qDBusRealAddWatch(d, watch, flags, fd);
@@ -295,7 +295,7 @@ static void qDBusRemoveWatch(DBusWatch *watch, void *data)
//qDebug("remove watch");
QDBusConnectionPrivate *d = static_cast<QDBusConnectionPrivate *>(data);
- int fd = q_dbus_watch_get_fd(watch);
+ int fd = q_dbus_watch_get_unix_fd(watch);
QDBusWatchAndTimeoutLocker locker(RemoveWatchAction, d);
QDBusConnectionPrivate::WatcherHash::iterator i = d->watchers.find(fd);
@@ -326,7 +326,7 @@ static void qDBusToggleWatch(DBusWatch *watch, void *data)
Q_ASSERT(data);
QDBusConnectionPrivate *d = static_cast<QDBusConnectionPrivate *>(data);
- int fd = q_dbus_watch_get_fd(watch);
+ int fd = q_dbus_watch_get_unix_fd(watch);
if (QCoreApplication::instance() && QThread::currentThread() == d->thread()) {
qDBusRealToggleWatch(d, watch, fd);
@@ -587,17 +587,76 @@ bool QDBusConnectionPrivate::handleMessage(const QDBusMessage &amsg)
return false;
}
+static void garbageCollectChildren(QDBusConnectionPrivate::ObjectTreeNode &node)
+{
+ int size = node.children.count();
+ if (node.activeChildren == 0) {
+ // easy case
+ node.children.clear();
+ } else if (size > node.activeChildren * 3 || (size > 20 && size * 2 > node.activeChildren * 3)) {
+ // rewrite the vector, keeping only the active children
+ // if the vector is large (> 20 items) and has one third of inactives
+ // or if the vector is small and has two thirds of inactives.
+ QDBusConnectionPrivate::ObjectTreeNode::DataList::Iterator end = node.children.end();
+ QDBusConnectionPrivate::ObjectTreeNode::DataList::Iterator it = node.children.begin();
+ QDBusConnectionPrivate::ObjectTreeNode::DataList::Iterator tgt = it;
+ for ( ; it != end; ++it) {
+ if (it->isActive())
+ *tgt++ = qMove(*it);
+ }
+ ++tgt;
+ node.children.erase(tgt, end);
+ }
+}
+
static void huntAndDestroy(QObject *needle, QDBusConnectionPrivate::ObjectTreeNode &haystack)
{
QDBusConnectionPrivate::ObjectTreeNode::DataList::Iterator it = haystack.children.begin();
QDBusConnectionPrivate::ObjectTreeNode::DataList::Iterator end = haystack.children.end();
- for ( ; it != end; ++it)
+ for ( ; it != end; ++it) {
+ if (!it->isActive())
+ continue;
huntAndDestroy(needle, *it);
+ if (!it->isActive())
+ --haystack.activeChildren;
+ }
if (needle == haystack.obj) {
haystack.obj = 0;
haystack.flags = 0;
}
+
+ garbageCollectChildren(haystack);
+}
+
+static void huntAndUnregister(const QStringList &pathComponents, int i, QDBusConnection::UnregisterMode mode,
+ QDBusConnectionPrivate::ObjectTreeNode *node)
+{
+ if (pathComponents.count() == i) {
+ // found it
+ node->obj = 0;
+ node->flags = 0;
+
+ if (mode == QDBusConnection::UnregisterTree) {
+ // clear the sub-tree as well
+ node->activeChildren = 0;
+ node->children.clear(); // can't disconnect the objects because we really don't know if they can
+ // be found somewhere else in the path too
+ }
+ } else {
+ // keep going
+ QDBusConnectionPrivate::ObjectTreeNode::DataList::Iterator end = node->children.end();
+ QDBusConnectionPrivate::ObjectTreeNode::DataList::Iterator it =
+ std::lower_bound(node->children.begin(), end, pathComponents.at(i));
+ if (it == end || it->name != pathComponents.at(i) || !it->isActive())
+ return; // node not found
+
+ huntAndUnregister(pathComponents, i + 1, mode, it);
+ if (!it->isActive())
+ --node->activeChildren;
+
+ garbageCollectChildren(*node);
+ }
}
static void huntAndEmit(DBusConnection *connection, DBusMessage *msg,
@@ -606,8 +665,10 @@ static void huntAndEmit(DBusConnection *connection, DBusMessage *msg,
{
QDBusConnectionPrivate::ObjectTreeNode::DataList::ConstIterator it = haystack.children.constBegin();
QDBusConnectionPrivate::ObjectTreeNode::DataList::ConstIterator end = haystack.children.constEnd();
- for ( ; it != end; ++it)
- huntAndEmit(connection, msg, needle, *it, isScriptable, isAdaptor, path + QLatin1Char('/') + it->name);
+ for ( ; it != end; ++it) {
+ if (it->isActive())
+ huntAndEmit(connection, msg, needle, *it, isScriptable, isAdaptor, path + QLatin1Char('/') + it->name);
+ }
if (needle == haystack.obj) {
// is this a signal we should relay?
@@ -1787,7 +1848,8 @@ void QDBusConnectionPrivate::waitForFinished(QDBusPendingCallPrivate *pcall)
}
}
-static inline bool waitingForFinishedIsSet(QDBusPendingCallPrivate *call)
+// this function is called only in a Q_ASSERT
+static inline Q_DECL_UNUSED bool waitingForFinishedIsSet(QDBusPendingCallPrivate *call)
{
const QMutexLocker locker(&call->mutex);
return call->waitingForFinished;
@@ -2249,6 +2311,21 @@ void QDBusConnectionPrivate::registerObject(const ObjectTreeNode *node)
}
}
+void QDBusConnectionPrivate::unregisterObject(const QString &path, QDBusConnection::UnregisterMode mode)
+{
+ QDBusConnectionPrivate::ObjectTreeNode *node = &rootNode;
+ QStringList pathComponents;
+ int i;
+ if (path == QLatin1String("/")) {
+ i = 0;
+ } else {
+ pathComponents = path.split(QLatin1Char('/'));
+ i = 1;
+ }
+
+ huntAndUnregister(pathComponents, i, mode, node);
+}
+
void QDBusConnectionPrivate::connectRelay(const QString &service,
const QString &path, const QString &interface,
QDBusAbstractInterface *receiver,
@@ -2316,8 +2393,6 @@ void QDBusConnectionPrivate::disconnectRelay(const QString &service,
return;
}
}
-
- qWarning("QDBusConnectionPrivate::disconnectRelay called for a signal that was not found");
}
QString QDBusConnectionPrivate::getNameOwner(const QString& serviceName)
diff --git a/src/dbus/qdbusintegrator_p.h b/src/dbus/qdbusintegrator_p.h
index fbaf04fff3..b44db0098f 100644
--- a/src/dbus/qdbusintegrator_p.h
+++ b/src/dbus/qdbusintegrator_p.h
@@ -116,7 +116,7 @@ public:
QDBusActivateObjectEvent(const QDBusConnection &c, QObject *sender,
const QDBusConnectionPrivate::ObjectTreeNode &n,
int p, const QDBusMessage &m, QSemaphore *s = 0)
- : QMetaCallEvent(0, -1, 0, sender, -1, 0, 0, 0, s), connection(c), node(n),
+ : QMetaCallEvent(0, ushort(-1), 0, sender, -1, 0, 0, 0, s), connection(c), node(n),
pathStartPos(p), message(m), handled(false)
{ }
~QDBusActivateObjectEvent();
diff --git a/src/dbus/qdbusinterface.h b/src/dbus/qdbusinterface.h
index 5750feb027..d2bb1da369 100644
--- a/src/dbus/qdbusinterface.h
+++ b/src/dbus/qdbusinterface.h
@@ -47,8 +47,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -75,7 +73,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbusintrospection_p.h b/src/dbus/qdbusintrospection_p.h
index a9f3773acc..b892ed95f1 100644
--- a/src/dbus/qdbusintrospection_p.h
+++ b/src/dbus/qdbusintrospection_p.h
@@ -97,7 +97,7 @@ public:
inline bool operator==(const Argument& other) const
{ return name == other.name && type == other.type; }
};
-
+
struct Method
{
QString name;
diff --git a/src/dbus/qdbusmacros.h b/src/dbus/qdbusmacros.h
index f2c0fafa8f..5a95f53261 100644
--- a/src/dbus/qdbusmacros.h
+++ b/src/dbus/qdbusmacros.h
@@ -57,7 +57,6 @@
#include <QtCore/qvector.h>
#endif
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
#ifndef QT_NO_DBUS
@@ -75,6 +74,5 @@ QT_BEGIN_NAMESPACE
#endif // QT_NO_DBUS
QT_END_NAMESPACE
-QT_END_HEADER
#endif
diff --git a/src/dbus/qdbusmessage.h b/src/dbus/qdbusmessage.h
index 72caf312ec..8f8954c1ce 100644
--- a/src/dbus/qdbusmessage.h
+++ b/src/dbus/qdbusmessage.h
@@ -53,8 +53,6 @@
# undef interface
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -130,8 +128,6 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QDBusMessage)
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbusmetaobject.cpp b/src/dbus/qdbusmetaobject.cpp
index f3bd7c28ba..799c66f6f9 100644
--- a/src/dbus/qdbusmetaobject.cpp
+++ b/src/dbus/qdbusmetaobject.cpp
@@ -77,7 +77,7 @@ private:
QVarLengthArray<int, 4> outputTypes;
int flags;
};
-
+
struct Property {
QByteArray typeName;
QByteArray signature;
@@ -92,14 +92,14 @@ private:
QMap<QByteArray, Method> signals_;
QMap<QByteArray, Method> methods;
QMap<QByteArray, Property> properties;
-
+
const QDBusIntrospection::Interface *data;
QString interface;
Type findType(const QByteArray &signature,
const QDBusIntrospection::Annotations &annotations,
const char *direction = "Out", int id = -1);
-
+
void parseMethods();
void parseSignals();
void parseProperties();
@@ -258,7 +258,7 @@ void QDBusMetaObjectGenerator::parseMethods()
mm.inputTypes.append(type.id);
mm.parameterNames.append(arg.name.toLatin1());
-
+
prototype.append(type.name);
prototype.append(',');
}
@@ -331,7 +331,7 @@ void QDBusMetaObjectGenerator::parseSignals()
mm.inputTypes.append(type.id);
mm.parameterNames.append(arg.name.toLatin1());
-
+
prototype.append(type.name);
prototype.append(',');
}
@@ -361,7 +361,7 @@ void QDBusMetaObjectGenerator::parseProperties()
Type type = findType(p.type.toLatin1(), p.annotations);
if (type.id == QVariant::Invalid)
continue;
-
+
QByteArray name = p.name.toLatin1();
mp.signature = p.type.toLatin1();
mp.type = type.id;
@@ -564,7 +564,7 @@ void QDBusMetaObjectGenerator::writeWithoutXml(const QString &interface)
char *stringdata = new char[name.length() + 1];
stringdata[name.length()] = '\0';
-
+
d.data = reinterpret_cast<uint*>(header);
d.relatedMetaObjects = 0;
d.static_metacall = 0;
@@ -615,7 +615,7 @@ QDBusMetaObject *QDBusMetaObject::createMetaObject(const QString &interface, con
if (we)
return we;
// still nothing?
-
+
if (parsed.isEmpty()) {
// object didn't return introspection
we = new QDBusMetaObject;
@@ -627,7 +627,7 @@ QDBusMetaObject *QDBusMetaObject::createMetaObject(const QString &interface, con
// merge all interfaces
it = parsed.constBegin();
QDBusIntrospection::Interface merged = *it.value().constData();
-
+
for (++it; it != end; ++it) {
merged.annotations.unite(it.value()->annotations);
merged.methods.unite(it.value()->methods);
diff --git a/src/dbus/qdbusmetatype.cpp b/src/dbus/qdbusmetatype.cpp
index ff5818d684..804e80699a 100644
--- a/src/dbus/qdbusmetatype.cpp
+++ b/src/dbus/qdbusmetatype.cpp
@@ -318,10 +318,10 @@ int QDBusMetaType::signatureToType(const char *signature)
case DBUS_TYPE_UINT16:
return QMetaType::UShort;
-
+
case DBUS_TYPE_INT32:
return QVariant::Int;
-
+
case DBUS_TYPE_UINT32:
return QVariant::UInt;
@@ -375,7 +375,7 @@ int QDBusMetaType::signatureToType(const char *signature)
/*!
\fn QDBusMetaType::typeToSignature(int type)
- \internal
+ \internal
Returns the D-Bus signature equivalent to the supplied meta type id \a type.
diff --git a/src/dbus/qdbusmetatype.h b/src/dbus/qdbusmetatype.h
index af73902ee5..bc556a0157 100644
--- a/src/dbus/qdbusmetatype.h
+++ b/src/dbus/qdbusmetatype.h
@@ -47,8 +47,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -93,7 +91,5 @@ int qDBusRegisterMetaType(
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbuspendingcall.h b/src/dbus/qdbuspendingcall.h
index 9fa78f3702..19bc34c26b 100644
--- a/src/dbus/qdbuspendingcall.h
+++ b/src/dbus/qdbuspendingcall.h
@@ -51,8 +51,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -122,7 +120,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbuspendingreply.cpp b/src/dbus/qdbuspendingreply.cpp
index cf99bb692c..c0e24bee06 100644
--- a/src/dbus/qdbuspendingreply.cpp
+++ b/src/dbus/qdbuspendingreply.cpp
@@ -185,6 +185,11 @@
function's return value is undefined (will probably cause an
assertion failure), so it is important to verify that the
processing is finished and the reply is valid.
+
+ If the reply does not contain an argument at position \a index or if the
+ reply was an error, this function returns an invalid QVariant. Since D-Bus
+ messages can never contain invalid QVariants, this return can be used to
+ detect an error condition.
*/
/*!
@@ -197,6 +202,11 @@
Note that, if the reply hasn't arrived, this function causes the
calling thread to block until the reply is processed.
+
+ If the reply does not contain an argument at position \c Index or if the
+ reply was an error, this function returns a \c Type object that is default
+ constructed, which may be indistinguishable from a valid value. To reliably
+ determine whether the message was an error, use isError().
*/
/*!
@@ -211,6 +221,10 @@
Note that, if the reply hasn't arrived, this function causes the
calling thread to block until the reply is processed.
+
+ If the reply is an error reply, this function returns a default-constructed
+ \c T1 object, which may be indistinguishable from a valid value. To
+ reliably determine whether the message was an error, use isError().
*/
/*!
@@ -225,6 +239,10 @@
Note that, if the reply hasn't arrived, this function causes the
calling thread to block until the reply is processed.
+
+ If the reply is an error reply, this function returns a default-constructed
+ \c T1 object, which may be indistinguishable from a valid value. To
+ reliably determine whether the message was an error, use isError().
*/
/*!
@@ -260,14 +278,12 @@ void QDBusPendingReplyData::assign(const QDBusMessage &message)
QVariant QDBusPendingReplyData::argumentAt(int index) const
{
- if (d)
- d->waitForFinished(); // bypasses "const"
+ if (!d)
+ return QVariant();
- Q_ASSERT_X(d && index >= 0 && index < d->replyMessage.arguments().count(),
- "QDBusPendingReply::argumentAt",
- "Index out of bounds");
+ d->waitForFinished(); // bypasses "const"
- return d->replyMessage.arguments().at(index);
+ return d->replyMessage.arguments().value(index);
}
void QDBusPendingReplyData::setMetaTypes(int count, const int *types)
diff --git a/src/dbus/qdbuspendingreply.h b/src/dbus/qdbuspendingreply.h
index 89cd846bf8..b7e459f7a7 100644
--- a/src/dbus/qdbuspendingreply.h
+++ b/src/dbus/qdbuspendingreply.h
@@ -49,8 +49,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -107,6 +105,10 @@ namespace QDBusPendingReplyTypes {
static inline void fillMetaTypes(int *)
{ }
};
+
+ struct TypeIsVoid {};
+ template <typename T> struct NotVoid { typedef T Type; };
+ template <> struct NotVoid<void> { typedef TypeIsVoid Type; };
} // namespace QDBusPendingReplyTypes
template<typename T1 = void, typename T2 = void, typename T3 = void, typename T4 = void,
@@ -168,9 +170,7 @@ public:
template<int Index> inline
const typename Select<Index>::Type argumentAt() const
{
- // static assert?
- Q_ASSERT_X(Index < count() && Index >= 0, "QDBusPendingReply::argumentAt",
- "Index out of bounds");
+ Q_STATIC_ASSERT_X(Index >= 0 && Index < Count, "Index out of bounds");
typedef typename Select<Index>::Type ResultType;
return qdbus_cast<ResultType>(argumentAt(Index), 0);
}
@@ -180,7 +180,7 @@ public:
return argumentAt<0>();
}
- inline operator typename Select<0>::Type() const
+ inline operator typename QDBusPendingReplyTypes::NotVoid<T1>::Type() const
{
return argumentAt<0>();
}
@@ -210,7 +210,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbusreply.h b/src/dbus/qdbusreply.h
index 22242bc97d..4567c80131 100644
--- a/src/dbus/qdbusreply.h
+++ b/src/dbus/qdbusreply.h
@@ -53,8 +53,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -71,7 +69,7 @@ public:
}
inline QDBusReply& operator=(const QDBusMessage &reply)
{
- QVariant data(qMetaTypeId(&m_data), reinterpret_cast<void*>(0));
+ QVariant data(qMetaTypeId<Type>(), reinterpret_cast<void*>(0));
qDBusReplyFill(reply, m_error, data);
m_data = qvariant_cast<Type>(data);
return *this;
@@ -113,6 +111,7 @@ public:
inline bool isValid() const { return !m_error.isValid(); }
inline const QDBusError& error() { return m_error; }
+ inline const QDBusError& error() const { return m_error; }
inline Type value() const
{
@@ -184,6 +183,7 @@ public:
inline bool isValid() const { return !m_error.isValid(); }
inline const QDBusError& error() { return m_error; }
+ inline const QDBusError& error() const { return m_error; }
private:
QDBusError m_error;
@@ -192,7 +192,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbusserver.h b/src/dbus/qdbusserver.h
index 0fbb96d206..d455f8e0ec 100644
--- a/src/dbus/qdbusserver.h
+++ b/src/dbus/qdbusserver.h
@@ -47,8 +47,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -78,7 +76,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbusservicewatcher.h b/src/dbus/qdbusservicewatcher.h
index 5f14b5e64c..0988d82550 100644
--- a/src/dbus/qdbusservicewatcher.h
+++ b/src/dbus/qdbusservicewatcher.h
@@ -47,8 +47,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -99,7 +97,5 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QDBusServiceWatcher::WatchMode)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif // QDBUSSERVICEWATCHER_H
diff --git a/src/dbus/qdbusunixfiledescriptor.h b/src/dbus/qdbusunixfiledescriptor.h
index 74c2ba307e..5e8f60817f 100644
--- a/src/dbus/qdbusunixfiledescriptor.h
+++ b/src/dbus/qdbusunixfiledescriptor.h
@@ -52,8 +52,6 @@
# include <utility>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -97,7 +95,5 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QDBusUnixFileDescriptor)
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif // QDBUSUNIXFILEDESCRIPTOR_H
diff --git a/src/dbus/qdbusutil_p.h b/src/dbus/qdbusutil_p.h
index c77d8791df..5d8b3a1293 100644
--- a/src/dbus/qdbusutil_p.h
+++ b/src/dbus/qdbusutil_p.h
@@ -61,8 +61,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
namespace QDBusUtil
@@ -161,7 +159,5 @@ namespace QDBusUtil
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/dbus/qdbusvirtualobject.cpp b/src/dbus/qdbusvirtualobject.cpp
index 8f64d22643..d6d4f01a33 100644
--- a/src/dbus/qdbusvirtualobject.cpp
+++ b/src/dbus/qdbusvirtualobject.cpp
@@ -58,16 +58,14 @@ QT_END_NAMESPACE
/*!
- \internal
\class QDBusVirtualObject
\inmodule QtDBus
- \since 4.8
+ \since 5.1
\brief The QDBusVirtualObject class is used to handle several DBus paths with one class.
*/
/*!
- \internal
\fn bool QDBusVirtualObject::handleMessage(const QDBusMessage &message, const QDBusConnection &connection) = 0
This function needs to handle all messages to the path of the
@@ -78,7 +76,6 @@ QT_END_NAMESPACE
/*!
- \internal
\fn QString QDBusVirtualObject::introspect(const QString &path) const
This function needs to handle the introspection of the
diff --git a/src/dbus/qdbusvirtualobject.h b/src/dbus/qdbusvirtualobject.h
index ada800940d..da63082c70 100644
--- a/src/dbus/qdbusvirtualobject.h
+++ b/src/dbus/qdbusvirtualobject.h
@@ -48,8 +48,6 @@
#ifndef QT_NO_DBUS
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -74,7 +72,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DBUS
#endif
diff --git a/src/gui/QtGui.dynlist b/src/gui/QtGui.dynlist
new file mode 100644
index 0000000000..7e15e37845
--- /dev/null
+++ b/src/gui/QtGui.dynlist
@@ -0,0 +1,5 @@
+{
+ extern "C++" {
+ "QGuiApplication::notify(QObject*, QEvent*)";
+ };
+};
diff --git a/src/gui/accessible/accessible.pri b/src/gui/accessible/accessible.pri
index 7c8e81812a..6fdb2d35b2 100644
--- a/src/gui/accessible/accessible.pri
+++ b/src/gui/accessible/accessible.pri
@@ -3,13 +3,15 @@
contains(QT_CONFIG, accessibility) {
HEADERS += \
accessible/qaccessible.h \
- accessible/qaccessible2.h \
+ accessible/qaccessiblecache_p.h \
+ accessible/qaccessible2_p.h \
accessible/qaccessibleobject.h \
accessible/qaccessibleplugin.h \
accessible/qplatformaccessibility.h
SOURCES += accessible/qaccessible.cpp \
accessible/qaccessible2.cpp \
+ accessible/qaccessiblecache.cpp \
accessible/qaccessibleobject.cpp \
accessible/qaccessibleplugin.cpp \
accessible/qplatformaccessibility.cpp
diff --git a/src/gui/accessible/qaccessible.cpp b/src/gui/accessible/qaccessible.cpp
index 9b8e44f003..7487aabde5 100644
--- a/src/gui/accessible/qaccessible.cpp
+++ b/src/gui/accessible/qaccessible.cpp
@@ -41,9 +41,13 @@
#include "qaccessible.h"
+#include "qaccessible2_p.h"
+#include "qaccessiblecache_p.h"
#include "qaccessibleplugin.h"
#include "qaccessibleobject.h"
#include "qaccessiblebridge.h"
+#include <QtCore/qtextboundaryfinder.h>
+#include <QtGui/qtextcursor.h>
#include <QtGui/QGuiApplication>
#include <private/qguiapplication_p.h>
#include <qpa/qplatformaccessibility.h>
@@ -51,6 +55,7 @@
#include <QtCore/qdebug.h>
#include <QtCore/qmetaobject.h>
+#include <QtCore/qhash.h>
#include <private/qfactoryloader_p.h>
QT_BEGIN_NAMESPACE
@@ -430,6 +435,8 @@ Q_GLOBAL_STATIC_WITH_ARGS(QFactoryLoader, loader,
#endif
Q_GLOBAL_STATIC(QList<QAccessible::InterfaceFactory>, qAccessibleFactories)
+typedef QHash<QString, QAccessiblePlugin*> QAccessiblePluginsHash;
+Q_GLOBAL_STATIC(QAccessiblePluginsHash, qAccessiblePlugins);
QAccessible::UpdateHandler QAccessible::updateHandler = 0;
QAccessible::RootObjectHandler QAccessible::rootObjectHandler = 0;
@@ -555,6 +562,8 @@ QAccessible::RootObjectHandler QAccessible::installRootObjectHandler(RootObjectH
return old;
}
+Q_GLOBAL_STATIC(QAccessibleCache, qAccessibleCache)
+
/*!
If a QAccessibleInterface implementation exists for the given \a object,
this function returns a pointer to the implementation; otherwise it
@@ -571,8 +580,7 @@ QAccessible::RootObjectHandler QAccessible::installRootObjectHandler(RootObjectH
function tries to find an implementation for the object's parent
class, using the above strategy.
- \warning The caller is responsible for deleting the returned
- interface after use.
+ All interfaces are managed by an internal cache and should not be deleted.
*/
QAccessibleInterface *QAccessible::queryAccessibleInterface(QObject *object)
{
@@ -580,32 +588,117 @@ QAccessibleInterface *QAccessible::queryAccessibleInterface(QObject *object)
if (!object)
return 0;
+ if (Id id = qAccessibleCache->objectToId.value(object))
+ return qAccessibleCache->interfaceForId(id);
+
+ // Create a QAccessibleInterface for the object class. Start by the most
+ // derived class and walk up the class hierarchy.
const QMetaObject *mo = object->metaObject();
while (mo) {
const QString cn = QLatin1String(mo->className());
+
+ // Check if the class has a InterfaceFactory installed.
for (int i = qAccessibleFactories()->count(); i > 0; --i) {
InterfaceFactory factory = qAccessibleFactories()->at(i - 1);
- if (QAccessibleInterface *iface = factory(cn, object))
+ if (QAccessibleInterface *iface = factory(cn, object)) {
+ qAccessibleCache->insert(object, iface);
+ Q_ASSERT(qAccessibleCache->objectToId.contains(object));
return iface;
+ }
}
#ifndef QT_NO_ACCESSIBILITY
#ifndef QT_NO_LIBRARY
- if (QAccessibleInterface * iface = qLoadPlugin1<QAccessibleInterface, QAccessiblePlugin>(loader(), cn, object))
- return iface;
+ // Find a QAccessiblePlugin (factory) for the class name. If there's
+ // no entry in the cache try to create it using the plugin loader.
+ if (!qAccessiblePlugins()->contains(cn)) {
+ QAccessiblePlugin *factory = 0; // 0 means "no plugin found". This is cached as well.
+ const int index = loader()->indexOf(cn);
+ if (index != -1)
+ factory = qobject_cast<QAccessiblePlugin *>(loader()->instance(index));
+ qAccessiblePlugins()->insert(cn, factory);
+ }
+
+ // At this point the cache should contain a valid factory pointer or 0:
+ Q_ASSERT(qAccessiblePlugins()->contains(cn));
+ QAccessiblePlugin *factory = qAccessiblePlugins()->value(cn);
+ if (factory) {
+ QAccessibleInterface *result = factory->create(cn, object);
+ if (result) { // Need this condition because of QDesktopScreenWidget
+ qAccessibleCache->insert(object, result);
+ Q_ASSERT(qAccessibleCache->objectToId.contains(object));
+ }
+ return result;
+ }
#endif
#endif
mo = mo->superClass();
}
#ifndef QT_NO_ACCESSIBILITY
- if (object == qApp)
- return new QAccessibleApplication;
+ if (object == qApp) {
+ QAccessibleInterface *appInterface = new QAccessibleApplication;
+ qAccessibleCache->insert(object, appInterface);
+ Q_ASSERT(qAccessibleCache->objectToId.contains(qApp));
+ return appInterface;
+ }
#endif
return 0;
}
/*!
+ \internal
+ Required to ensure that manually created interfaces
+ are properly memory managed.
+
+ Must only be called exactly once per interface.
+ This is implicitly called when calling queryAccessibleInterface,
+ so it's only required when re-implementing for example
+ the child function and returning the child after new-ing
+ a QAccessibleInterface subclass.
+ */
+QAccessible::Id QAccessible::registerAccessibleInterface(QAccessibleInterface *iface)
+{
+ Q_ASSERT(iface);
+ return qAccessibleCache->insert(iface->object(), iface);
+}
+
+/*!
+ \internal
+ Removes the interface belonging to this id from the cache and
+ deletes it. The id becomes invalid an may be re-used by the
+ cache.
+*/
+void QAccessible::deleteAccessibleInterface(Id id)
+{
+ qAccessibleCache->deleteInterface(id);
+}
+
+/*!
+ \internal
+ Returns the unique ID for the accessibleInterface.
+*/
+QAccessible::Id QAccessible::uniqueId(QAccessibleInterface *iface)
+{
+ Id id = qAccessibleCache->idToInterface.key(iface);
+ if (!id)
+ id = registerAccessibleInterface(iface);
+ return id;
+}
+
+/*!
+ \internal
+ Returns the QAccessibleInterface belonging to the id.
+
+ Returns 0 if the id is invalid.
+*/
+QAccessibleInterface *QAccessible::accessibleInterface(Id id)
+{
+ return qAccessibleCache->idToInterface.value(id);
+}
+
+
+/*!
Returns true if an accessibility implementation has been requested
during the runtime of the application; otherwise returns false.
@@ -667,15 +760,23 @@ void QAccessible::setRootObject(QObject *object)
*/
void QAccessible::updateAccessibility(QAccessibleEvent *event)
{
- if (updateHandler) {
- updateHandler(event);
+ if (!isActive())
return;
+
+#ifndef QT_NO_ACCESSIBILITY
+ if (event->type() == QAccessible::TableModelChanged) {
+ Q_ASSERT(event->object());
+ if (QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(event->object())) {
+ if (iface->tableInterface())
+ iface->tableInterface()->modelChange(static_cast<QAccessibleTableModelChangeEvent*>(event));
+ }
}
- if (!isActive())
+ if (updateHandler) {
+ updateHandler(event);
return;
+ }
-#ifndef QT_NO_ACCESSIBILITY
if (QPlatformAccessibility *pfAccessibility = platformAccessibility())
pfAccessibility->notifyAccessibilityUpdate(event);
#endif
@@ -691,6 +792,77 @@ void QAccessible::updateAccessibility(QAccessibleEvent *event)
#endif
/*!
+ \internal
+ \brief getBoundaries is a helper function to find the accessible text boundaries for QTextCursor based documents.
+ \param documentCursor a valid cursor bound to the document (not null). It needs to ba at the position to look for the boundary
+ \param boundaryType the type of boundary to find
+ \return the boundaries as pair
+*/
+QPair< int, int > QAccessible::qAccessibleTextBoundaryHelper(const QTextCursor &offsetCursor, TextBoundaryType boundaryType)
+{
+ Q_ASSERT(!offsetCursor.isNull());
+
+ QTextCursor endCursor = offsetCursor;
+ endCursor.movePosition(QTextCursor::End);
+ int characterCount = endCursor.position();
+
+ QPair<int, int> result;
+ QTextCursor cursor = offsetCursor;
+ switch (boundaryType) {
+ case CharBoundary:
+ result.first = cursor.position();
+ cursor.movePosition(QTextCursor::NextCharacter, QTextCursor::KeepAnchor);
+ result.second = cursor.position();
+ break;
+ case WordBoundary:
+ cursor.movePosition(QTextCursor::StartOfWord, QTextCursor::MoveAnchor);
+ result.first = cursor.position();
+ cursor.movePosition(QTextCursor::EndOfWord, QTextCursor::KeepAnchor);
+ result.second = cursor.position();
+ break;
+ case SentenceBoundary: {
+ // QCursor does not provide functionality to move to next sentence.
+ // We therefore find the current block, then go through the block using
+ // QTextBoundaryFinder and find the sentence the \offset represents
+ cursor.movePosition(QTextCursor::StartOfBlock, QTextCursor::MoveAnchor);
+ result.first = cursor.position();
+ cursor.movePosition(QTextCursor::EndOfBlock, QTextCursor::KeepAnchor);
+ result.second = cursor.position();
+ QString blockText = cursor.selectedText();
+ const int offsetWithinBlockText = offsetCursor.position() - result.first;
+ QTextBoundaryFinder sentenceFinder(QTextBoundaryFinder::Sentence, blockText);
+ sentenceFinder.setPosition(offsetWithinBlockText);
+ int prevBoundary = offsetWithinBlockText;
+ int nextBoundary = offsetWithinBlockText;
+ if (!(sentenceFinder.boundaryReasons() & QTextBoundaryFinder::StartOfItem))
+ prevBoundary = sentenceFinder.toPreviousBoundary();
+ nextBoundary = sentenceFinder.toNextBoundary();
+ if (nextBoundary != -1)
+ result.second = result.first + nextBoundary;
+ if (prevBoundary != -1)
+ result.first += prevBoundary;
+ break; }
+ case LineBoundary:
+ cursor.movePosition(QTextCursor::StartOfLine, QTextCursor::MoveAnchor);
+ result.first = cursor.position();
+ cursor.movePosition(QTextCursor::EndOfLine, QTextCursor::KeepAnchor);
+ result.second = cursor.position();
+ break;
+ case ParagraphBoundary:
+ cursor.movePosition(QTextCursor::StartOfBlock, QTextCursor::MoveAnchor);
+ result.first = cursor.position();
+ cursor.movePosition(QTextCursor::EndOfBlock, QTextCursor::KeepAnchor);
+ result.second = cursor.position();
+ break;
+ case NoBoundary:
+ result.first = 0;
+ result.second = characterCount;
+ break;
+ }
+ return result;
+}
+
+/*!
\class QAccessibleInterface
\brief The QAccessibleInterface class defines an interface that exposes information
about accessible objects.
@@ -1008,6 +1180,10 @@ QColor QAccessibleInterface::backgroundColor() const
return QColor();
}
+QAccessibleInterface::~QAccessibleInterface()
+{
+}
+
/*!
\fn QAccessibleTextInterface *QAccessibleInterface::textInterface()
\internal
@@ -1329,15 +1505,19 @@ QColor QAccessibleInterface::backgroundColor() const
QAccessibleInterface *QAccessibleEvent::accessibleInterface() const
{
QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(m_object);
- if (!iface) {
- qWarning() << "Cannot create accessible interface for object: " << m_object;
+ if (!iface || !iface->isValid()) {
+ static bool hasWarned = false;
+ if (!hasWarned) {
+ qWarning() << "Problem creating accessible interface for: " << m_object << endl
+ << "Make sure to deploy Qt with accessibility plugins.";
+ hasWarned = true;
+ }
return 0;
}
if (m_child >= 0) {
QAccessibleInterface *child = iface->child(m_child);
if (child) {
- delete iface;
iface = child;
} else {
qWarning() << "Cannot creat accessible child interface for object: " << m_object << " index: " << m_child;
diff --git a/src/gui/accessible/qaccessible.h b/src/gui/accessible/qaccessible.h
index 5988e6c346..339e3fbcd6 100644
--- a/src/gui/accessible/qaccessible.h
+++ b/src/gui/accessible/qaccessible.h
@@ -39,10 +39,13 @@
**
****************************************************************************/
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_ACCESSIBILITY
#ifndef QACCESSIBLE_H
#define QACCESSIBLE_H
+#include <QtCore/qdebug.h>
#include <QtCore/qglobal.h>
#include <QtCore/qobject.h>
#include <QtCore/qrect.h>
@@ -54,14 +57,12 @@
#include <stdlib.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
-
class QAccessibleInterface;
class QAccessibleEvent;
class QWindow;
+class QTextCursor;
// We need to inherit QObject to expose the enums to QML.
class Q_GUI_EXPORT QAccessible
@@ -331,16 +332,33 @@ public:
TableCellInterface
};
+ enum TextBoundaryType {
+ CharBoundary,
+ WordBoundary,
+ SentenceBoundary,
+ ParagraphBoundary,
+ LineBoundary,
+ NoBoundary
+ };
+
typedef QAccessibleInterface*(*InterfaceFactory)(const QString &key, QObject*);
typedef void(*UpdateHandler)(QAccessibleEvent *event);
typedef void(*RootObjectHandler)(QObject*);
+ typedef unsigned Id;
+
static void installFactory(InterfaceFactory);
static void removeFactory(InterfaceFactory);
static UpdateHandler installUpdateHandler(UpdateHandler);
static RootObjectHandler installRootObjectHandler(RootObjectHandler);
static QAccessibleInterface *queryAccessibleInterface(QObject *);
+ static Id uniqueId(QAccessibleInterface *iface);
+ static QAccessibleInterface *accessibleInterface(Id uniqueId);
+ static Id registerAccessibleInterface(QAccessibleInterface *iface);
+ static void deleteAccessibleInterface(Id uniqueId);
+
+
#if QT_DEPRECATED_SINCE(5, 0)
QT_DEPRECATED static inline void updateAccessibility(QObject *object, int child, Event reason);
#endif
@@ -351,6 +369,8 @@ public:
static void cleanup();
+ static QPair< int, int > qAccessibleTextBoundaryHelper(const QTextCursor &cursor, TextBoundaryType boundaryType);
+
private:
static UpdateHandler updateHandler;
static RootObjectHandler rootObjectHandler;
@@ -360,6 +380,8 @@ private:
it is not supposed to be instantiated.
*/
QAccessible() {}
+
+ friend class QAccessibleCache;
};
Q_GUI_EXPORT bool operator==(const QAccessible::State &first, const QAccessible::State &second);
@@ -377,8 +399,10 @@ class QAccessibleTableCellInterface;
class Q_GUI_EXPORT QAccessibleInterface
{
+protected:
+ virtual ~QAccessibleInterface();
+
public:
- virtual ~QAccessibleInterface() {}
// check for valid pointers
virtual bool isValid() const = 0;
virtual QObject *object() const = 0;
@@ -431,7 +455,9 @@ public:
virtual void *interface_cast(QAccessible::InterfaceType)
{ return 0; }
-private:
+
+protected:
+ friend class QAccessibleCache;
};
class Q_GUI_EXPORT QAccessibleEvent
@@ -679,7 +705,5 @@ inline void QAccessible::updateAccessibility(QObject *object, int child, Event r
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QACCESSIBLE_H
#endif //!QT_NO_ACCESSIBILITY
diff --git a/src/gui/accessible/qaccessible2.cpp b/src/gui/accessible/qaccessible2.cpp
index 3d7b8d5a76..d790fac071 100644
--- a/src/gui/accessible/qaccessible2.cpp
+++ b/src/gui/accessible/qaccessible2.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include "qaccessible2.h"
+#include "qaccessible2_p.h"
#include <QtGui/QGuiApplication>
#include "qclipboard.h"
#include "qtextboundaryfinder.h"
@@ -49,17 +49,6 @@
QT_BEGIN_NAMESPACE
/*!
- \namespace QAccessible2
- \ingroup accessibility
- \internal
-
- \brief The QAccessible2 namespace defines constants relating to
- IAccessible2-based interfaces
-
- \l{IAccessible2 Specification}
-*/
-
-/*!
\class QAccessibleTextInterface
\internal
\inmodule QtGui
@@ -139,7 +128,7 @@ QT_BEGIN_NAMESPACE
of that item; returns an empty string if there is no such an item.
Sets \a startOffset and \a endOffset values to -1 on error.
*/
-QString QAccessibleTextInterface::textBeforeOffset(int offset, QAccessible2::BoundaryType boundaryType,
+QString QAccessibleTextInterface::textBeforeOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const
{
const QString txt = text(0, characterCount());
@@ -155,13 +144,13 @@ QString QAccessibleTextInterface::textBeforeOffset(int offset, QAccessible2::Bou
QTextBoundaryFinder::BoundaryType type;
switch (boundaryType) {
- case QAccessible2::CharBoundary:
+ case QAccessible::CharBoundary:
type = QTextBoundaryFinder::Grapheme;
break;
- case QAccessible2::WordBoundary:
+ case QAccessible::WordBoundary:
type = QTextBoundaryFinder::Word;
break;
- case QAccessible2::SentenceBoundary:
+ case QAccessible::SentenceBoundary:
type = QTextBoundaryFinder::Sentence;
break;
default:
@@ -199,7 +188,7 @@ QString QAccessibleTextInterface::textBeforeOffset(int offset, QAccessible2::Bou
of that item; returns an empty string if there is no such an item.
Sets \a startOffset and \a endOffset values to -1 on error.
*/
-QString QAccessibleTextInterface::textAfterOffset(int offset, QAccessible2::BoundaryType boundaryType,
+QString QAccessibleTextInterface::textAfterOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const
{
const QString txt = text(0, characterCount());
@@ -215,13 +204,13 @@ QString QAccessibleTextInterface::textAfterOffset(int offset, QAccessible2::Boun
QTextBoundaryFinder::BoundaryType type;
switch (boundaryType) {
- case QAccessible2::CharBoundary:
+ case QAccessible::CharBoundary:
type = QTextBoundaryFinder::Grapheme;
break;
- case QAccessible2::WordBoundary:
+ case QAccessible::WordBoundary:
type = QTextBoundaryFinder::Word;
break;
- case QAccessible2::SentenceBoundary:
+ case QAccessible::SentenceBoundary:
type = QTextBoundaryFinder::Sentence;
break;
default:
@@ -259,7 +248,7 @@ QString QAccessibleTextInterface::textAfterOffset(int offset, QAccessible2::Boun
of that item; returns an empty string if there is no such an item.
Sets \a startOffset and \a endOffset values to -1 on error.
*/
-QString QAccessibleTextInterface::textAtOffset(int offset, QAccessible2::BoundaryType boundaryType,
+QString QAccessibleTextInterface::textAtOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const
{
const QString txt = text(0, characterCount());
@@ -275,13 +264,13 @@ QString QAccessibleTextInterface::textAtOffset(int offset, QAccessible2::Boundar
QTextBoundaryFinder::BoundaryType type;
switch (boundaryType) {
- case QAccessible2::CharBoundary:
+ case QAccessible::CharBoundary:
type = QTextBoundaryFinder::Grapheme;
break;
- case QAccessible2::WordBoundary:
+ case QAccessible::WordBoundary:
type = QTextBoundaryFinder::Word;
break;
- case QAccessible2::SentenceBoundary:
+ case QAccessible::SentenceBoundary:
type = QTextBoundaryFinder::Sentence;
break;
default:
diff --git a/src/gui/accessible/qaccessible2.h b/src/gui/accessible/qaccessible2_p.h
index 2f95094584..95f93e2431 100644
--- a/src/gui/accessible/qaccessible2.h
+++ b/src/gui/accessible/qaccessible2_p.h
@@ -45,25 +45,11 @@
#include <QtGui/qaccessible.h>
#include <QtCore/qcoreapplication.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#ifndef QT_NO_ACCESSIBILITY
-namespace QAccessible2
-{
- enum BoundaryType {
- CharBoundary,
- WordBoundary,
- SentenceBoundary,
- ParagraphBoundary,
- LineBoundary,
- NoBoundary
- };
-}
-
class Q_GUI_EXPORT QAccessibleTextInterface
{
public:
@@ -81,11 +67,11 @@ public:
// text
virtual QString text(int startOffset, int endOffset) const = 0;
- virtual QString textBeforeOffset(int offset, QAccessible2::BoundaryType boundaryType,
+ virtual QString textBeforeOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const;
- virtual QString textAfterOffset(int offset, QAccessible2::BoundaryType boundaryType,
+ virtual QString textAfterOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const;
- virtual QString textAtOffset(int offset, QAccessible2::BoundaryType boundaryType,
+ virtual QString textAtOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const;
virtual int characterCount() const = 0;
@@ -186,15 +172,17 @@ public:
virtual bool isColumnSelected(int column) const = 0;
// Returns a boolean value indicating whether the specified row is completely selected.
virtual bool isRowSelected(int row) const = 0;
- // Selects a row and unselects all previously selected rows.
+ // Selects a row and it might unselect all previously selected rows.
virtual bool selectRow(int row) = 0;
- // Selects a column and unselects all previously selected columns.
+ // Selects a column it might unselect all previously selected columns.
virtual bool selectColumn(int column) = 0;
// Unselects one row, leaving other selected rows selected (if any).
virtual bool unselectRow(int row) = 0;
// Unselects one column, leaving other selected columns selected (if any).
virtual bool unselectColumn(int column) = 0;
+ virtual void modelChange(QAccessibleTableModelChangeEvent *event) = 0;
+
protected:
friend class QAbstractItemView;
friend class QAbstractItemViewPrivate;
@@ -234,6 +222,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/accessible/qaccessiblebridge.h b/src/gui/accessible/qaccessiblebridge.h
index 077996900b..0a0002af2c 100644
--- a/src/gui/accessible/qaccessiblebridge.h
+++ b/src/gui/accessible/qaccessiblebridge.h
@@ -45,8 +45,6 @@
#include <QtCore/qplugin.h>
#include <QtCore/qfactoryinterface.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -79,6 +77,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QACCESSIBLEBRIDGE_H
diff --git a/src/gui/text/qrawfont_ft.cpp b/src/gui/accessible/qaccessiblecache.cpp
index 5cac45b216..1b79c30b6c 100644
--- a/src/gui/text/qrawfont_ft.cpp
+++ b/src/gui/accessible/qaccessiblecache.cpp
@@ -39,91 +39,78 @@
**
****************************************************************************/
-#include <QtCore/qglobal.h>
-
-#if !defined(QT_NO_RAWFONT)
-
-#include "qrawfont_p.h"
-#include "qfontengine_ft_p.h"
-#include "quuid.h"
-
+#include "qaccessiblecache_p.h"
QT_BEGIN_NAMESPACE
-class QFontEngineFTRawFont
-
- : public QFontEngineFT
-
+/*!
+ \class QAccessibleCache
+ \internal
+ \brief Maintains a cache of accessible interfaces.
+*/
+
+/*
+ The ID is always in the range [INT_MAX+1, UINT_MAX].
+ This makes it easy on windows to reserve the positive integer range
+ for the index of a child and not clash with the unique ids.
+*/
+QAccessible::Id QAccessibleCache::acquireId() const
{
-public:
- QFontEngineFTRawFont(const QFontDef &fontDef)
- : QFontEngineFT(fontDef)
- {
+ static const QAccessible::Id FirstId = QAccessible::Id(INT_MAX) + 1;
+ static QAccessible::Id lastUsedId = FirstId;
+
+ while (idToInterface.contains(lastUsedId)) {
+ if (lastUsedId == UINT_MAX) // (wrap back when when we reach UINT_MAX)
+ lastUsedId = FirstId;
+ else
+ ++lastUsedId;
}
- void updateFamilyNameAndStyle()
- {
- fontDef.family = QString::fromUtf8(freetype->face->family_name);
-
- if (freetype->face->style_flags & FT_STYLE_FLAG_ITALIC)
- fontDef.style = QFont::StyleItalic;
-
- if (freetype->face->style_flags & FT_STYLE_FLAG_BOLD)
- fontDef.weight = QFont::Bold;
- }
-
- bool initFromData(const QByteArray &fontData)
- {
- FaceId faceId;
- faceId.filename = "";
- faceId.index = 0;
- faceId.uuid = QUuid::createUuid().toByteArray();
-
- return init(faceId, true, Format_None, fontData);
- }
-};
-
+ return lastUsedId;
+}
-void QRawFontPrivate::platformCleanUp()
+QAccessibleInterface *QAccessibleCache::interfaceForId(QAccessible::Id id) const
{
- // Font engine handles all resources
+ return idToInterface.value(id);
}
-void QRawFontPrivate::platformLoadFromData(const QByteArray &fontData, qreal pixelSize,
- QFont::HintingPreference hintingPreference)
+QAccessible::Id QAccessibleCache::insert(QObject *object, QAccessibleInterface *iface) const
{
- Q_ASSERT(fontEngine == 0);
-
- QFontDef fontDef;
- fontDef.pixelSize = pixelSize;
-
- QFontEngineFTRawFont *fe = new QFontEngineFTRawFont(fontDef);
- if (!fe->initFromData(fontData)) {
- delete fe;
- return;
+ Q_ASSERT(iface);
+ Q_UNUSED(object)
+
+ // object might be 0
+ Q_ASSERT(!objectToId.contains(object));
+ Q_ASSERT_X(!idToInterface.values().contains(iface), "", "Accessible interface inserted into cache twice!");
+
+ QAccessible::Id id = acquireId();
+ QObject *obj = iface->object();
+ Q_ASSERT(object == obj);
+ if (obj) {
+ objectToId.insert(obj, id);
+ connect(obj, SIGNAL(destroyed(QObject *)), this, SLOT(objectDestroyed(QObject *)));
}
+ idToInterface.insert(id, iface);
+ return id;
+}
- fe->updateFamilyNameAndStyle();
-
- switch (hintingPreference) {
- case QFont::PreferNoHinting:
- fe->setDefaultHintStyle(QFontEngineFT::HintNone);
- break;
- case QFont::PreferFullHinting:
- fe->setDefaultHintStyle(QFontEngineFT::HintFull);
- break;
- case QFont::PreferVerticalHinting:
- fe->setDefaultHintStyle(QFontEngineFT::HintLight);
- break;
- default:
- // Leave it as it is
- break;
+void QAccessibleCache::objectDestroyed(QObject* obj)
+{
+ QAccessible::Id id = objectToId.value(obj);
+ if (id) {
+ Q_ASSERT_X(idToInterface.contains(id), "", "QObject with accessible interface deleted, where interface not in cache!");
+ deleteInterface(id, obj);
}
+}
- fontEngine = fe;
- fontEngine->ref.ref();
+void QAccessibleCache::deleteInterface(QAccessible::Id id, QObject *obj)
+{
+ QAccessibleInterface *iface = idToInterface.take(id);
+ if (!obj)
+ obj = iface->object();
+ if (obj)
+ objectToId.remove(obj);
+ delete iface;
}
QT_END_NAMESPACE
-
-#endif // QT_NO_RAWFONT
diff --git a/src/gui/accessible/qaccessiblecache_p.h b/src/gui/accessible/qaccessiblecache_p.h
new file mode 100644
index 0000000000..32f9c443ba
--- /dev/null
+++ b/src/gui/accessible/qaccessiblecache_p.h
@@ -0,0 +1,78 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QACCESSIBLECACHE_P
+#define QACCESSIBLECACHE_P
+
+#include <QtCore/qglobal.h>
+#include <QtCore/qobject.h>
+#include <QtCore/qhash.h>
+
+#include "qaccessible.h"
+
+QT_BEGIN_NAMESPACE
+
+
+class QAccessibleCache :public QObject
+{
+ Q_OBJECT
+
+public:
+ QAccessibleInterface *interfaceForId(QAccessible::Id id) const;
+ QAccessible::Id insert(QObject *object, QAccessibleInterface *iface) const;
+ void deleteInterface(QAccessible::Id id, QObject *obj = 0);
+
+private Q_SLOTS:
+ void objectDestroyed(QObject *obj);
+
+private:
+ QAccessible::Id acquireId() const;
+
+ mutable QHash<QAccessible::Id, QAccessibleInterface *> idToInterface;
+ mutable QHash<QObject *, QAccessible::Id> objectToId;
+
+ friend class QAccessible;
+ friend class QAccessibleInterface;
+};
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/gui/accessible/qaccessibleobject.cpp b/src/gui/accessible/qaccessibleobject.cpp
index af8787ae80..ccbfd36b70 100644
--- a/src/gui/accessible/qaccessibleobject.cpp
+++ b/src/gui/accessible/qaccessibleobject.cpp
@@ -55,39 +55,8 @@ class QAccessibleObjectPrivate
{
public:
QPointer<QObject> object;
-
- QList<QByteArray> actionList() const;
};
-QList<QByteArray> QAccessibleObjectPrivate::actionList() const
-{
- QList<QByteArray> actionList;
-
- if (!object)
- return actionList;
-
- const QMetaObject *mo = object->metaObject();
- Q_ASSERT(mo);
-
- QByteArray defaultAction = QMetaObject::normalizedSignature(
- mo->classInfo(mo->indexOfClassInfo("DefaultSlot")).value());
-
- for (int i = 0; i < mo->methodCount(); ++i) {
- const QMetaMethod member = mo->method(i);
- if (member.methodType() != QMetaMethod::Slot && member.access() != QMetaMethod::Public)
- continue;
-
- if (!qstrcmp(member.tag(), "QACCESSIBLE_SLOT")) {
- if (member.methodSignature() == defaultAction)
- actionList.prepend(defaultAction);
- else
- actionList << member.methodSignature();
- }
- }
-
- return actionList;
-}
-
/*!
\class QAccessibleObject
\brief The QAccessibleObject class implements parts of the
@@ -163,11 +132,8 @@ QAccessibleInterface *QAccessibleObject::childAt(int x, int y) const
for (int i = 0; i < childCount(); ++i) {
QAccessibleInterface *childIface = child(i);
Q_ASSERT(childIface);
- if (childIface->rect().contains(x,y)) {
+ if (childIface->rect().contains(x,y))
return childIface;
- } else {
- delete childIface;
- }
}
return 0;
}
@@ -207,7 +173,6 @@ static QObjectList topLevelObjects()
if (QAccessibleInterface *root = w->accessibleRoot()) {
if (root->object())
list.append(root->object());
- delete root;
}
}
}
@@ -224,6 +189,8 @@ int QAccessibleApplication::childCount() const
/*! \reimp */
int QAccessibleApplication::indexOfChild(const QAccessibleInterface *child) const
{
+ if (!child)
+ return -1;
const QObjectList tlw(topLevelObjects());
return tlw.indexOf(child->object());
}
diff --git a/src/gui/accessible/qaccessibleobject.h b/src/gui/accessible/qaccessibleobject.h
index abe55f38c6..4861af3557 100644
--- a/src/gui/accessible/qaccessibleobject.h
+++ b/src/gui/accessible/qaccessibleobject.h
@@ -43,9 +43,6 @@
#define QACCESSIBLEOBJECT_H
#include <QtGui/qaccessible.h>
-#include <QtGui/qaccessible2.h>
-
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -101,6 +98,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QACCESSIBLEOBJECT_H
diff --git a/src/gui/accessible/qaccessibleplugin.h b/src/gui/accessible/qaccessibleplugin.h
index 6f7915d025..ac56c83f98 100644
--- a/src/gui/accessible/qaccessibleplugin.h
+++ b/src/gui/accessible/qaccessibleplugin.h
@@ -45,8 +45,6 @@
#include <QtGui/qaccessible.h>
#include <QtCore/qfactoryinterface.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -73,6 +71,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QACCESSIBLEPLUGIN_H
diff --git a/src/gui/accessible/qplatformaccessibility.h b/src/gui/accessible/qplatformaccessibility.h
index f10e8a7f12..26a22e492d 100644
--- a/src/gui/accessible/qplatformaccessibility.h
+++ b/src/gui/accessible/qplatformaccessibility.h
@@ -55,8 +55,6 @@
#include <QtGui/qaccessible.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -75,8 +73,6 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_ACCESSIBILITY
#endif // QPLATFORMACCESSIBILITY_H
diff --git a/src/gui/doc/qtgui.qdocconf b/src/gui/doc/qtgui.qdocconf
index fcf6cdf57c..74596d8a50 100644
--- a/src/gui/doc/qtgui.qdocconf
+++ b/src/gui/doc/qtgui.qdocconf
@@ -21,7 +21,7 @@ qhp.QtGui.customFilters.Qt.filterAttributes = qtgui $QT_VERSION
qhp.QtGui.subprojects = classes
qhp.QtGui.subprojects.classes.title = C++ Classes
-qhp.QtGui.subprojects.classes.indexTitle = Qt GUI C++ API
+qhp.QtGui.subprojects.classes.indexTitle = Qt GUI C++ Classes
qhp.QtGui.subprojects.classes.selectors = class fake:headerfile
qhp.QtGui.subprojects.classes.sortPages = true
diff --git a/src/gui/doc/snippets/code/src_gui_util_qvalidator.cpp b/src/gui/doc/snippets/code/src_gui_util_qvalidator.cpp
index fbf58a8c09..f9a4ee4ad1 100644
--- a/src/gui/doc/snippets/code/src_gui_util_qvalidator.cpp
+++ b/src/gui/doc/snippets/code/src_gui_util_qvalidator.cpp
@@ -133,3 +133,46 @@ s = "README.1ST"; v.validate(s, pos); // Returns Acceptable
s = "read me.txt"; v.validate(s, pos); // Returns Invalid
s = "readm"; v.validate(s, pos); // Returns Intermediate
//! [4]
+
+//! [5]
+// regexp: optional '-' followed by between 1 and 3 digits
+QRegularExpression rx("-?\\d{1,3}");
+QValidator *validator = new QRegularExpressionValidator(rx, this);
+
+QLineEdit *edit = new QLineEdit(this);
+edit->setValidator(validator);
+//! [5]
+
+//! [6]
+// integers 1 to 9999
+QRegularExpression re("[1-9]\\d{0,3}");
+// the validator treats the regexp as "^[1-9]\\d{0,3}$"
+QRegularExpressionValidator v(re, 0);
+QString s;
+int pos = 0;
+
+s = "0"; v.validate(s, pos); // returns Invalid
+s = "12345"; v.validate(s, pos); // returns Invalid
+s = "1"; v.validate(s, pos); // returns Acceptable
+
+re.setPattern("\\S+"); // one or more non-whitespace characters
+v.setRegularExpression(re);
+s = "myfile.txt"; v.validate(s, pos); // Returns Acceptable
+s = "my file.txt"; v.validate(s, pos); // Returns Invalid
+
+// A, B or C followed by exactly five digits followed by W, X, Y or Z
+re.setPattern("[A-C]\\d{5}[W-Z]");
+v.setRegularExpression(re);
+s = "a12345Z"; v.validate(s, pos); // Returns Invalid
+s = "A12345Z"; v.validate(s, pos); // Returns Acceptable
+s = "B12"; v.validate(s, pos); // Returns Intermediate
+
+// match most 'readme' files
+re.setPattern("read\\S?me(\.(txt|asc|1st))?");
+re.setPatternOptions(QRegularExpression::CaseInsensitiveOption);
+v.setRegularExpression(re);
+s = "readme"; v.validate(s, pos); // Returns Acceptable
+s = "README.1ST"; v.validate(s, pos); // Returns Acceptable
+s = "read me.txt"; v.validate(s, pos); // Returns Invalid
+s = "readm"; v.validate(s, pos); // Returns Intermediate
+//! [6]
diff --git a/src/gui/doc/snippets/textdocument-tables/mainwindow.cpp b/src/gui/doc/snippets/textdocument-tables/mainwindow.cpp
index 443f5407e0..1169254253 100644
--- a/src/gui/doc/snippets/textdocument-tables/mainwindow.cpp
+++ b/src/gui/doc/snippets/textdocument-tables/mainwindow.cpp
@@ -87,7 +87,7 @@ MainWindow::MainWindow()
int row;
QTextTableCell cell;
QTextCursor cellCursor;
-
+
QTextCharFormat charFormat;
charFormat.setForeground(Qt::black);
diff --git a/src/gui/doc/snippets/textdocument-texttable/main.cpp b/src/gui/doc/snippets/textdocument-texttable/main.cpp
index 0024d8592b..f82b5235cf 100644
--- a/src/gui/doc/snippets/textdocument-texttable/main.cpp
+++ b/src/gui/doc/snippets/textdocument-texttable/main.cpp
@@ -56,7 +56,7 @@ int main(int argc, char * argv[])
tableFormat.setCellSpacing(2);
QTextTable *table = cursor.insertTable(rows, columns);
table->setFormat(tableFormat);
-
+
QTextCharFormat boldFormat;
boldFormat.setFontWeight(QFont::Bold);
diff --git a/src/gui/doc/src/external-resources.qdoc b/src/gui/doc/src/external-resources.qdoc
index 858dd76bbf..0e955b11f6 100644
--- a/src/gui/doc/src/external-resources.qdoc
+++ b/src/gui/doc/src/external-resources.qdoc
@@ -45,3 +45,8 @@
\externalpage http://www.xfree86.org/4.3.0/Xcursor.3.html
\title Xcursor
*/
+
+/*!
+ \externalpage http://www.opengl.org/wiki/Tessellation_Shader
+ \title OpenGL Tessellation Shaders
+*/ \ No newline at end of file
diff --git a/src/gui/doc/src/paintsystem.qdoc b/src/gui/doc/src/paintsystem.qdoc
index 7857a160ac..cd208e9e18 100644
--- a/src/gui/doc/src/paintsystem.qdoc
+++ b/src/gui/doc/src/paintsystem.qdoc
@@ -50,7 +50,7 @@
\ingroup qt-graphics
\ingroup frameworks-technologies
\ingroup qt-basic-concepts
-
+
Qt's paint system enables painting on screen and print devices
using the same API, and is primarily based on the QPainter,
@@ -70,7 +70,7 @@
same painting pipeline making it easy to add support for new
features and providing default implementations for unsupported
ones.
-
+
\section1 Topics
\list
\li \l{Classes for Painting}
@@ -126,7 +126,7 @@
in a platform-independent way. Another benefit is that the
painting can be performed in another thread than the current GUI
thread.
-
+
\row \li \b Pixmap
The QPixmap class is an off-screen image representation which is
@@ -175,7 +175,7 @@
actually be able to draw on the device, this paint engine must be
a custom paint engine created by deriving from the QPaintEngine
class.
-
+
\endtable
*/
@@ -183,7 +183,7 @@
/*!
\page paintsystem-drawing.html
\title Drawing and Filling
-
+
\previouspage Paint Devices and Backends
\contentspage The Paint System
\nextpage Coordinate System
diff --git a/src/gui/doc/src/qtgui.qdoc b/src/gui/doc/src/qtgui.qdoc
index aa44dcfad5..6c3e9a4938 100644
--- a/src/gui/doc/src/qtgui.qdoc
+++ b/src/gui/doc/src/qtgui.qdoc
@@ -27,7 +27,7 @@
/*!
\module QtGui
- \title Qt GUI C++ API
+ \title Qt GUI C++ Classes
\ingroup modules
\brief The Qt GUI module provides the basic enablers for graphical
@@ -62,7 +62,7 @@
For application developers writing user interfaces, Qt provides
higher level API's, like Qt Quick, that are much more suitable
- than the enablers found in the Qt GUI module.
+ than the enablers found in the Qt GUI module.
\section1 Getting started
@@ -164,7 +164,7 @@
\section1 Reference
\list
- \li \l{Qt GUI C++ API}
+ \li \l{Qt GUI C++ Classes}
\list
\li \l{Event Classes}
\li \l{Painting Classes}
diff --git a/src/gui/gui.pro b/src/gui/gui.pro
index 058cfe92ec..14c267df70 100644
--- a/src/gui/gui.pro
+++ b/src/gui/gui.pro
@@ -18,9 +18,7 @@ testcocoon {
load(testcocoon)
}
-mac {
- LIBS_PRIVATE += -framework Cocoa
-}
+mac:!ios: LIBS_PRIVATE += -framework Cocoa
CONFIG += simd
@@ -37,3 +35,4 @@ include(itemmodels/itemmodels.pri)
QMAKE_LIBS += $$QMAKE_LIBS_GUI
+QMAKE_DYNAMIC_LIST_FILE = $$PWD/QtGui.dynlist
diff --git a/src/gui/image/qbitmap.h b/src/gui/image/qbitmap.h
index 1f062a0758..f8bd2feed7 100644
--- a/src/gui/image/qbitmap.h
+++ b/src/gui/image/qbitmap.h
@@ -44,8 +44,6 @@
#include <QtGui/qpixmap.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -80,6 +78,4 @@ Q_DECLARE_SHARED(QBitmap)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QBITMAP_H
diff --git a/src/gui/image/qicon.cpp b/src/gui/image/qicon.cpp
index dce902301c..d73cd0aa57 100644
--- a/src/gui/image/qicon.cpp
+++ b/src/gui/image/qicon.cpp
@@ -60,6 +60,7 @@
#include "private/qhexstring_p.h"
#include "private/qguiapplication_p.h"
+#include "qpa/qplatformtheme.h"
#ifndef QT_NO_ICON
QT_BEGIN_NAMESPACE
@@ -118,6 +119,25 @@ static void qt_cleanup_icon_cache()
qtIconCache()->clear();
}
+/*! \internal
+
+ Returns the effective device pixel ratio, using
+ the provided window pointer if possible.
+
+ if Qt::AA_UseHighDpiPixmaps is not set this function
+ returns 1.0 to keep non-hihdpi aware code working.
+*/
+static qreal qt_effective_device_pixel_ratio(QWindow *window = 0)
+{
+ if (!qApp->testAttribute(Qt::AA_UseHighDpiPixmaps))
+ return qreal(1.0);
+
+ if (window)
+ return window->devicePixelRatio();
+
+ return qApp->devicePixelRatio(); // Don't know which window to target.
+}
+
QIconPrivate::QIconPrivate()
: engine(0), ref(1),
serialNum(serialNumCounter.fetchAndAddRelaxed(1)),
@@ -125,6 +145,25 @@ QIconPrivate::QIconPrivate()
{
}
+/*! \internal
+ Computes the displayDevicePixelRatio for a pixmap.
+
+ If displayDevicePixelRatio is 1.0 the reurned value is 1.0, always.
+
+ For a displayDevicePixelRatio of 2.0 the returned value will be between
+ 1.0 and 2.0, depending on requestedSize and actualsize:
+ * If actualsize < requestedSize : 1.0 (not enough pixels for a normal-dpi pixmap)
+ * If actualsize == requestedSize * 2.0 : 2.0 (enough pixels for a high-dpi pixmap)
+ * else : a scaled value between 1.0 and 2.0. (pixel count is between normal-dpi and high-dpi)
+*/
+qreal QIconPrivate::pixmapDevicePixelRatio(qreal displayDevicePixelRatio, const QSize &requestedSize, const QSize &actualSize)
+{
+ QSize targetSize = requestedSize * displayDevicePixelRatio;
+ qreal scale = 0.5 * (qreal(actualSize.width()) / qreal(targetSize.width()) +
+ qreal(actualSize.height() / qreal(targetSize.height())));
+ return qMax(qreal(1.0), displayDevicePixelRatio *scale);
+}
+
QPixmapIconEngine::QPixmapIconEngine()
{
}
@@ -140,10 +179,8 @@ QPixmapIconEngine::~QPixmapIconEngine()
void QPixmapIconEngine::paint(QPainter *painter, const QRect &rect, QIcon::Mode mode, QIcon::State state)
{
- QSize pixmapSize = rect.size();
-#if defined(Q_WS_MAC)
- pixmapSize *= qt_mac_get_scalefactor();
-#endif
+ QSize pixmapSize = rect.size() * qt_effective_device_pixel_ratio(0);
+ QPixmap px = pixmap(pixmapSize, mode, state);
painter->drawPixmap(rect, pixmap(pixmapSize, mode, state));
}
@@ -344,6 +381,9 @@ void QPixmapIconEngine::addFile(const QString &fileName, const QSize &_size, QIc
}
if (pe->size == QSize() && pe->pixmap.isNull()) {
pe->pixmap = QPixmap(pe->fileName);
+ // Reset the devicePixelRatio. The pixmap may be loaded from a @2x file,
+ // but be used as a 1x pixmap by QIcon.
+ pe->pixmap.setDevicePixelRatio(1.0);
pe->size = pe->pixmap.size();
}
if(pe->size == size) {
@@ -657,13 +697,17 @@ qint64 QIcon::cacheKey() const
state, generating one if necessary. The pixmap might be smaller than
requested, but never larger.
+ Setting the Qt::AA_UseHighDpiPixmaps application attribute enables this
+ function to return pixmaps that are larger than the requested size. Such
+ images will have a devicePixelRatio larger than 1.
+
\sa actualSize(), paint()
*/
QPixmap QIcon::pixmap(const QSize &size, Mode mode, State state) const
{
if (!d)
return QPixmap();
- return d->engine->pixmap(size, mode, state);
+ return pixmap(0, size, mode, state);
}
/*!
@@ -673,6 +717,10 @@ QPixmap QIcon::pixmap(const QSize &size, Mode mode, State state) const
Returns a pixmap of size QSize(\a w, \a h). The pixmap might be smaller than
requested, but never larger.
+
+ Setting the Qt::AA_UseHighDpiPixmaps application attribute enables this
+ function to return pixmaps that are larger than the requested size. Such
+ images will have a devicePixelRatio larger than 1.
*/
/*!
@@ -682,11 +730,16 @@ QPixmap QIcon::pixmap(const QSize &size, Mode mode, State state) const
Returns a pixmap of size QSize(\a extent, \a extent). The pixmap might be smaller
than requested, but never larger.
+
+ Setting the Qt::AA_UseHighDpiPixmaps application attribute enables this
+ function to return pixmaps that are larger than the requested size. Such
+ images will have a devicePixelRatio larger than 1.
*/
/*! Returns the actual size of the icon for the requested \a size, \a
mode, and \a state. The result might be smaller than requested, but
- never larger.
+ never larger. The returned size is in device-independent pixels (This
+ is relevant for high-dpi pixmaps.)
\sa pixmap(), paint()
*/
@@ -694,9 +747,63 @@ QSize QIcon::actualSize(const QSize &size, Mode mode, State state) const
{
if (!d)
return QSize();
- return d->engine->actualSize(size, mode, state);
+ return actualSize(0, size, mode, state);
+}
+
+/*!
+ \since 5.1
+
+ Returns a pixmap with the requested \a window \a size, \a mode, and \a
+ state, generating one if necessary.
+
+ The pixmap can be smaller than the requested size. If \a window is on
+ a high-dpi display the pixmap can be larger. In that case it will have
+ a devicePixelRatio larger than 1.
+
+ \sa actualSize(), paint()
+*/
+QPixmap QIcon::pixmap(QWindow *window, const QSize &size, Mode mode, State state) const
+{
+ if (!d)
+ return QPixmap();
+
+ qreal devicePixelRatio = qt_effective_device_pixel_ratio(window);
+
+ // Handle the simple normal-dpi case:
+ if (!(devicePixelRatio > 1.0))
+ return d->engine->pixmap(size, mode, state);
+
+ // Try get a pixmap that is big enough to be displayed at device pixel resolution.
+ QPixmap pixmap = d->engine->pixmap(size * devicePixelRatio, mode, state);
+ pixmap.setDevicePixelRatio(d->pixmapDevicePixelRatio(devicePixelRatio, size, pixmap.size()));
+ return pixmap;
}
+/*!
+ \since 5.1
+
+ Returns the actual size of the icon for the requested \a window \a size, \a
+ mode, and \a state.
+
+ The pixmap can be smaller than the requested size. The returned size
+ is in device-independent pixels (This is relevant for high-dpi pixmaps.)
+
+ \sa actualSize(), pixmap(), paint()
+*/
+QSize QIcon::actualSize(QWindow *window, const QSize &size, Mode mode, State state) const
+{
+ if (!d)
+ return QSize();
+
+ qreal devicePixelRatio = qt_effective_device_pixel_ratio(window);
+
+ // Handle the simple normal-dpi case:
+ if (!(devicePixelRatio > 1.0))
+ return d->engine->actualSize(size, mode, state);
+
+ QSize actualSize = d->engine->actualSize(size * devicePixelRatio, mode, state);
+ return actualSize / d->pixmapDevicePixelRatio(devicePixelRatio, size, actualSize);
+}
/*!
Uses the \a painter to paint the icon with specified \a alignment,
@@ -851,6 +958,17 @@ void QIcon::addFile(const QString &fileName, const QSize &size, Mode mode, State
detach();
}
d->engine->addFile(fileName, size, mode, state);
+
+ // Check if a "@2x" file exists and add it.
+ if (qApp->devicePixelRatio() > 1.0) {
+ int dotIndex = fileName.lastIndexOf(QLatin1Char('.'));
+ if (dotIndex != -1) {
+ QString at2xfileName = fileName;
+ at2xfileName.insert(dotIndex, QStringLiteral("@2x"));
+ if (QFile::exists(at2xfileName))
+ d->engine->addFile(at2xfileName, size, mode, state);
+ }
+ }
}
/*!
@@ -945,6 +1063,7 @@ void QIcon::setThemeName(const QString &name)
*/
QString QIcon::themeName()
{
+ QIconLoader::instance()->ensureInitialized();
return QIconLoader::instance()->themeName();
}
@@ -986,7 +1105,10 @@ QIcon QIcon::fromTheme(const QString &name, const QIcon &fallback)
if (qtIconCache()->contains(name)) {
icon = *qtIconCache()->object(name);
} else {
- QIcon *cachedIcon = new QIcon(new QIconLoaderEngine(name));
+ QPlatformTheme * const platformTheme = QGuiApplicationPrivate::platformTheme();
+ QIconEngine * const engine = platformTheme ? platformTheme->createIconEngine(name)
+ : new QIconLoaderEngine(name);
+ QIcon *cachedIcon = new QIcon(engine);
qtIconCache()->insert(name, cachedIcon);
icon = *cachedIcon;
}
diff --git a/src/gui/image/qicon.h b/src/gui/image/qicon.h
index ad459005f5..e81bea69d6 100644
--- a/src/gui/image/qicon.h
+++ b/src/gui/image/qicon.h
@@ -47,8 +47,6 @@
#include <QtCore/qlist.h>
#include <QtGui/qpixmap.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -81,8 +79,10 @@ public:
{ return pixmap(QSize(w, h), mode, state); }
inline QPixmap pixmap(int extent, Mode mode = Normal, State state = Off) const
{ return pixmap(QSize(extent, extent), mode, state); }
+ QPixmap pixmap(QWindow *window, const QSize &size, Mode mode = Normal, State state = Off) const;
QSize actualSize(const QSize &size, Mode mode = Normal, State state = Off) const;
+ QSize actualSize(QWindow *window, const QSize &size, Mode mode = Normal, State state = Off) const;
QString name() const;
@@ -140,6 +140,4 @@ Q_GUI_EXPORT QDebug operator<<(QDebug dbg, const QIcon &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QICON_H
diff --git a/src/gui/image/qicon_p.h b/src/gui/image/qicon_p.h
index 2ddb5872e1..a46cc310ad 100644
--- a/src/gui/image/qicon_p.h
+++ b/src/gui/image/qicon_p.h
@@ -72,6 +72,8 @@ public:
delete engine;
}
+ qreal pixmapDevicePixelRatio(qreal displayDevicePixelRatio, const QSize &requestedSize, const QSize &actualSize);
+
QIconEngine *engine;
QAtomicInt ref;
diff --git a/src/gui/image/qiconengine.h b/src/gui/image/qiconengine.h
index 1d296b9f66..9fb21adf97 100644
--- a/src/gui/image/qiconengine.h
+++ b/src/gui/image/qiconengine.h
@@ -46,8 +46,6 @@
#include <QtCore/qlist.h>
#include <QtGui/qicon.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -90,6 +88,4 @@ typedef QIconEngine QIconEngineV2;
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QICONENGINE_H
diff --git a/src/gui/image/qiconengineplugin.h b/src/gui/image/qiconengineplugin.h
index 58bade1d09..a62659f8cb 100644
--- a/src/gui/image/qiconengineplugin.h
+++ b/src/gui/image/qiconengineplugin.h
@@ -45,8 +45,6 @@
#include <QtCore/qplugin.h>
#include <QtCore/qfactoryinterface.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -66,6 +64,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QICONENGINEPLUGIN_H
diff --git a/src/gui/image/qiconloader_p.h b/src/gui/image/qiconloader_p.h
index ea144ec299..419d93d576 100644
--- a/src/gui/image/qiconloader_p.h
+++ b/src/gui/image/qiconloader_p.h
@@ -42,6 +42,8 @@
#ifndef QICONLOADER_P_H
#define QICONLOADER_P_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_ICON
//
// W A R N I N G
diff --git a/src/gui/image/qimage.cpp b/src/gui/image/qimage.cpp
index 481cb37c8c..7287f54e74 100644
--- a/src/gui/image/qimage.cpp
+++ b/src/gui/image/qimage.cpp
@@ -1126,6 +1126,7 @@ QImage QImage::copy(const QRect& r) const
image.d->colortable = d->colortable;
image.d->dpmx = d->dpmx;
image.d->dpmy = d->dpmy;
+ image.d->devicePixelRatio = d->devicePixelRatio;
image.d->offset = d->offset;
image.d->has_alpha_clut = d->has_alpha_clut;
image.d->text = d->text;
diff --git a/src/gui/image/qimage.h b/src/gui/image/qimage.h
index bce25c49ea..50d4bc7666 100644
--- a/src/gui/image/qimage.h
+++ b/src/gui/image/qimage.h
@@ -53,8 +53,6 @@
#include <QtCore/qstringlist.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -430,6 +428,4 @@ Q_GUI_EXPORT QDebug operator<<(QDebug, const QImage &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QIMAGE_H
diff --git a/src/gui/image/qimageiohandler.cpp b/src/gui/image/qimageiohandler.cpp
index f770458127..055ace9985 100644
--- a/src/gui/image/qimageiohandler.cpp
+++ b/src/gui/image/qimageiohandler.cpp
@@ -433,7 +433,7 @@ bool QImageIOHandler::supportsOption(ImageOption option) const
the sequence number of the current image in the animation. If
this function is called before any image is read(), -1 is
returned. The number of the first image in the sequence is 0.
-
+
If the image format does not support animation, 0 is returned.
\sa read()
diff --git a/src/gui/image/qimageiohandler.h b/src/gui/image/qimageiohandler.h
index f6d905bc6b..2ba99beab3 100644
--- a/src/gui/image/qimageiohandler.h
+++ b/src/gui/image/qimageiohandler.h
@@ -46,8 +46,6 @@
#include <QtCore/qfactoryinterface.h>
#include <QtCore/qscopedpointer.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -142,6 +140,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QImageIOPlugin::Capabilities)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QIMAGEIOHANDLER_H
diff --git a/src/gui/image/qimagereader.cpp b/src/gui/image/qimagereader.cpp
index 684778694e..e612a2c374 100644
--- a/src/gui/image/qimagereader.cpp
+++ b/src/gui/image/qimagereader.cpp
@@ -190,34 +190,35 @@ struct _qt_BuiltInFormatStruct
{
_qt_BuiltInFormatType type;
const char *extension;
+ const char *mimeType;
};
static const _qt_BuiltInFormatStruct _qt_BuiltInFormats[] = {
#ifndef QT_NO_IMAGEFORMAT_PNG
- {_qt_PngFormat, "png"},
+ {_qt_PngFormat, "png", "image/png"},
#endif
#ifndef QT_NO_IMAGEFORMAT_JPEG
- {_qt_JpgFormat, "jpg"},
+ {_qt_JpgFormat, "jpg", "image/jpeg"},
{_qt_JpegFormat, "jpeg"},
#endif
#ifdef QT_BUILTIN_GIF_READER
- {_qt_GifFormat, "gif"},
+ {_qt_GifFormat, "gif", "image/gif"},
#endif
#ifndef QT_NO_IMAGEFORMAT_BMP
- {_qt_BmpFormat, "bmp"},
+ {_qt_BmpFormat, "bmp", "image/bmp"},
#endif
#ifndef QT_NO_IMAGEFORMAT_PPM
- {_qt_PpmFormat, "ppm"},
- {_qt_PgmFormat, "pgm"},
- {_qt_PbmFormat, "pbm"},
+ {_qt_PpmFormat, "ppm", "image/x-portable-pixmap"},
+ {_qt_PgmFormat, "pgm", "image/x-portable-graymap"},
+ {_qt_PbmFormat, "pbm", "image/x-portable-bitmap"},
#endif
#ifndef QT_NO_IMAGEFORMAT_XBM
- {_qt_XbmFormat, "xbm"},
+ {_qt_XbmFormat, "xbm", "image/x-xbitmap"},
#endif
#ifndef QT_NO_IMAGEFORMAT_XPM
- {_qt_XpmFormat, "xpm"},
+ {_qt_XpmFormat, "xpm", "image/x-xpixmap"},
#endif
- {_qt_NoFormat, ""}
+ {_qt_NoFormat, "", ""}
};
static QImageIOHandler *createReadHandlerHelper(QIODevice *device,
@@ -1445,6 +1446,10 @@ QByteArray QImageReader::imageFormat(QIODevice *device)
void supportedImageHandlerFormats(QFactoryLoader *loader,
QImageIOPlugin::Capability cap,
QSet<QByteArray> *result);
+
+void supportedImageHandlerMimeTypes(QFactoryLoader *loader,
+ QImageIOPlugin::Capability cap,
+ QSet<QByteArray> *result);
#endif
/*!
@@ -1453,18 +1458,17 @@ void supportedImageHandlerFormats(QFactoryLoader *loader,
By default, Qt can read the following formats:
\table
- \header \li Format \li Description
- \row \li BMP \li Windows Bitmap
- \row \li GIF \li Graphic Interchange Format (optional)
- \row \li JPG \li Joint Photographic Experts Group
- \row \li JPEG \li Joint Photographic Experts Group
- \row \li PNG \li Portable Network Graphics
- \row \li PBM \li Portable Bitmap
- \row \li PGM \li Portable Graymap
- \row \li PPM \li Portable Pixmap
- \row \li XBM \li X11 Bitmap
- \row \li XPM \li X11 Pixmap
- \row \li SVG \li Scalable Vector Graphics
+ \header \li Format \li MIME type \li Description
+ \row \li BMP \li image/bmp \li Windows Bitmap
+ \row \li GIF \li image/gif \li Graphic Interchange Format (optional)
+ \row \li JPG \li image/jpeg \li Joint Photographic Experts Group
+ \row \li PNG \li image/png \li Portable Network Graphics
+ \row \li PBM \li image/x-portable-bitmap \li Portable Bitmap
+ \row \li PGM \li image/x-portable-graymap \li Portable Graymap
+ \row \li PPM \li image/x-portable-pixmap \li Portable Pixmap
+ \row \li XBM \li image/x-xbitmap \li X11 Bitmap
+ \row \li XPM \li image/x-xpixmap \li X11 Pixmap
+ \row \li SVG \li image/svg+xml \li Scalable Vector Graphics
\endtable
Reading and writing SVG files is supported through the \l{Qt SVG} module.
@@ -1494,4 +1498,31 @@ QList<QByteArray> QImageReader::supportedImageFormats()
return sortedFormats;
}
+/*!
+ Returns the list of MIME types supported by QImageReader.
+
+ Note that the QApplication instance must be created before this function is
+ called.
+
+ \sa supportedImageFormats(), QImageWriter::supportedMimeTypes()
+*/
+
+QList<QByteArray> QImageReader::supportedMimeTypes()
+{
+ QSet<QByteArray> mimeTypes;
+ for (int i = 0; i < _qt_NumFormats; ++i)
+ mimeTypes << _qt_BuiltInFormats[i].mimeType;
+
+#ifndef QT_NO_LIBRARY
+ supportedImageHandlerMimeTypes(loader(), QImageIOPlugin::CanRead, &mimeTypes);
+#endif // QT_NO_LIBRARY
+
+ QList<QByteArray> sortedMimeTypes;
+ for (QSet<QByteArray>::ConstIterator it = mimeTypes.constBegin(); it != mimeTypes.constEnd(); ++it)
+ sortedMimeTypes << *it;
+
+ qSort(sortedMimeTypes);
+ return sortedMimeTypes;
+}
+
QT_END_NAMESPACE
diff --git a/src/gui/image/qimagereader.h b/src/gui/image/qimagereader.h
index 11c925b142..4f3c93af7d 100644
--- a/src/gui/image/qimagereader.h
+++ b/src/gui/image/qimagereader.h
@@ -46,8 +46,6 @@
#include <QtGui/qimage.h>
#include <QtGui/qimageiohandler.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -133,6 +131,7 @@ public:
static QByteArray imageFormat(const QString &fileName);
static QByteArray imageFormat(QIODevice *device);
static QList<QByteArray> supportedImageFormats();
+ static QList<QByteArray> supportedMimeTypes();
private:
Q_DISABLE_COPY(QImageReader)
@@ -141,6 +140,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QIMAGEREADER_H
diff --git a/src/gui/image/qimagewriter.cpp b/src/gui/image/qimagewriter.cpp
index 20e601be03..8823f9293d 100644
--- a/src/gui/image/qimagewriter.cpp
+++ b/src/gui/image/qimagewriter.cpp
@@ -100,6 +100,7 @@
#include <qfile.h>
#include <qfileinfo.h>
#include <qimageiohandler.h>
+#include <qjsonarray.h>
#include <qset.h>
#include <qvariant.h>
@@ -677,6 +678,26 @@ void supportedImageHandlerFormats(QFactoryLoader *loader,
result->insert(key);
}
}
+
+void supportedImageHandlerMimeTypes(QFactoryLoader *loader,
+ QImageIOPlugin::Capability cap,
+ QSet<QByteArray> *result)
+{
+ QList<QJsonObject> metaDataList = loader->metaData();
+
+ const int pluginCount = metaDataList.size();
+ for (int i = 0; i < pluginCount; ++i) {
+ const QJsonObject metaData = metaDataList.at(i).value(QStringLiteral("MetaData")).toObject();
+ const QJsonArray keys = metaData.value(QStringLiteral("Keys")).toArray();
+ const QJsonArray mimeTypes = metaData.value(QStringLiteral("MimeTypes")).toArray();
+ QImageIOPlugin *plugin = qobject_cast<QImageIOPlugin *>(loader->instance(i));
+ const int keyCount = keys.size();
+ for (int k = 0; k < keyCount; ++k) {
+ if (plugin && (plugin->capabilities(0, keys.at(k).toString().toLatin1()) & cap) != 0)
+ result->insert(mimeTypes.at(k).toString().toLatin1());
+ }
+ }
+}
#endif // QT_NO_IMAGEFORMATPLUGIN
/*!
@@ -685,16 +706,15 @@ void supportedImageHandlerFormats(QFactoryLoader *loader,
By default, Qt can write the following formats:
\table
- \header \li Format \li Description
- \row \li BMP \li Windows Bitmap
- \row \li JPG \li Joint Photographic Experts Group
- \row \li JPEG \li Joint Photographic Experts Group
- \row \li PNG \li Portable Network Graphics
- \row \li PBM \li Portable Bitmap
- \row \li PGM \li Portable Graymap
- \row \li PPM \li Portable Pixmap
- \row \li XBM \li X11 Bitmap
- \row \li XPM \li X11 Pixmap
+ \header \li Format \li MIME type \li Description
+ \row \li BMP \li image/bmp \li Windows Bitmap
+ \row \li JPG \li image/jpeg \li Joint Photographic Experts Group
+ \row \li PNG \li image/png \li Portable Network Graphics
+ \row \li PBM \li image/x-portable-bitmap \li Portable Bitmap
+ \row \li PGM \li image/x-portable-graymap \li Portable Graymap
+ \row \li PPM \li image/x-portable-pixmap \li Portable Pixmap
+ \row \li XBM \li image/x-xbitmap \li X11 Bitmap
+ \row \li XPM \li image/x-xpixmap \li X11 Pixmap
\endtable
Reading and writing SVG files is supported through the \l{Qt SVG} module.
@@ -726,9 +746,6 @@ QList<QByteArray> QImageWriter::supportedImageFormats()
#ifndef QT_NO_IMAGEFORMAT_JPEG
formats << "jpg" << "jpeg";
#endif
-#ifdef QT_BUILTIN_GIF_READER
- formats << "gif";
-#endif
#ifndef QT_NO_IMAGEFORMATPLUGIN
supportedImageHandlerFormats(loader(), QImageIOPlugin::CanWrite, &formats);
@@ -742,4 +759,46 @@ QList<QByteArray> QImageWriter::supportedImageFormats()
return sortedFormats;
}
+/*!
+ Returns the list of MIME types supported by QImageWriter.
+
+ Note that the QApplication instance must be created before this function is
+ called.
+
+ \sa supportedImageFormats(), QImageReader::supportedMimeTypes()
+*/
+QList<QByteArray> QImageWriter::supportedMimeTypes()
+{
+ QSet<QByteArray> mimeTypes;
+ mimeTypes << "image/bmp";
+#ifndef QT_NO_IMAGEFORMAT_PPM
+ mimeTypes << "image/x-portable-bitmap";
+ mimeTypes << "image/x-portable-graymap";
+ mimeTypes << "image/x-portable-pixmap";
+#endif
+#ifndef QT_NO_IMAGEFORMAT_XBM
+ mimeTypes << "image/x-xbitmap";
+#endif
+#ifndef QT_NO_IMAGEFORMAT_XPM
+ mimeTypes << "image/x-xpixmap";
+#endif
+#ifndef QT_NO_IMAGEFORMAT_PNG
+ mimeTypes << "image/png";
+#endif
+#ifndef QT_NO_IMAGEFORMAT_JPEG
+ mimeTypes << "image/jpeg";
+#endif
+
+#ifndef QT_NO_LIBRARY
+ supportedImageHandlerMimeTypes(loader(), QImageIOPlugin::CanWrite, &mimeTypes);
+#endif // QT_NO_LIBRARY
+
+ QList<QByteArray> sortedMimeTypes;
+ for (QSet<QByteArray>::ConstIterator it = mimeTypes.constBegin(); it != mimeTypes.constEnd(); ++it)
+ sortedMimeTypes << *it;
+
+ qSort(sortedMimeTypes);
+ return sortedMimeTypes;
+}
+
QT_END_NAMESPACE
diff --git a/src/gui/image/qimagewriter.h b/src/gui/image/qimagewriter.h
index 7d05cd5236..3f5cf9c454 100644
--- a/src/gui/image/qimagewriter.h
+++ b/src/gui/image/qimagewriter.h
@@ -46,8 +46,6 @@
#include <QtCore/qlist.h>
#include <QtGui/qimageiohandler.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -102,6 +100,7 @@ public:
bool supportsOption(QImageIOHandler::ImageOption option) const;
static QList<QByteArray> supportedImageFormats();
+ static QList<QByteArray> supportedMimeTypes();
private:
Q_DISABLE_COPY(QImageWriter)
@@ -110,6 +109,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QIMAGEWRITER_H
diff --git a/src/gui/image/qmovie.cpp b/src/gui/image/qmovie.cpp
index e137af2231..ae526f5ba7 100644
--- a/src/gui/image/qmovie.cpp
+++ b/src/gui/image/qmovie.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-/*!
+/*!
\class QMovie
\inmodule QtGui
@@ -150,7 +150,7 @@
copy of the frame.
*/
-/*!
+/*!
\fn void QMovie::stateChanged(QMovie::MovieState state)
This signal is emitted every time the state of the movie changes. The new
@@ -203,23 +203,23 @@ public:
inline QFrameInfo(bool endMark)
: pixmap(QPixmap()), delay(QMOVIE_INVALID_DELAY), endMark(endMark)
{ }
-
+
inline QFrameInfo()
: pixmap(QPixmap()), delay(QMOVIE_INVALID_DELAY), endMark(false)
{ }
-
+
inline QFrameInfo(const QPixmap &pixmap, int delay)
: pixmap(pixmap), delay(delay), endMark(false)
{ }
-
+
inline bool isValid()
{
return endMark || !(pixmap.isNull() && (delay == QMOVIE_INVALID_DELAY));
}
-
+
inline bool isEndMarker()
{ return endMark; }
-
+
static inline QFrameInfo endMarker()
{ return QFrameInfo(true); }
};
diff --git a/src/gui/image/qmovie.h b/src/gui/image/qmovie.h
index 60df9199c4..94d7c79e7b 100644
--- a/src/gui/image/qmovie.h
+++ b/src/gui/image/qmovie.h
@@ -50,8 +50,6 @@
#include <QtCore/qlist.h>
#include <QtGui/qimagereader.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -146,8 +144,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_MOVIE
#endif // QMOVIE_H
diff --git a/src/gui/image/qpicture.h b/src/gui/image/qpicture.h
index f0abb50764..08445a3143 100644
--- a/src/gui/image/qpicture.h
+++ b/src/gui/image/qpicture.h
@@ -46,8 +46,6 @@
#include <QtCore/qsharedpointer.h>
#include <QtGui/qpaintdevice.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -193,6 +191,4 @@ Q_GUI_EXPORT QDataStream &operator>>(QDataStream &, QPicture &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPICTURE_H
diff --git a/src/gui/image/qpictureformatplugin.h b/src/gui/image/qpictureformatplugin.h
index 16e7feaffe..30989c084c 100644
--- a/src/gui/image/qpictureformatplugin.h
+++ b/src/gui/image/qpictureformatplugin.h
@@ -45,8 +45,6 @@
#include <QtCore/qplugin.h>
#include <QtCore/qfactoryinterface.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -76,6 +74,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPICTUREFORMATPLUGIN_H
diff --git a/src/gui/image/qpixmap.cpp b/src/gui/image/qpixmap.cpp
index b6a21f588e..85f0dc2d92 100644
--- a/src/gui/image/qpixmap.cpp
+++ b/src/gui/image/qpixmap.cpp
@@ -678,6 +678,9 @@ qreal QPixmap::devicePixelRatio() const
*/
void QPixmap::setDevicePixelRatio(qreal scaleFactor)
{
+ if (isNull())
+ return;
+
detach();
data->setDevicePixelRatio(scaleFactor);
}
diff --git a/src/gui/image/qpixmap.h b/src/gui/image/qpixmap.h
index a25ecb21e4..f1fce03c80 100644
--- a/src/gui/image/qpixmap.h
+++ b/src/gui/image/qpixmap.h
@@ -50,8 +50,6 @@
#include <QtGui/qimage.h>
#include <QtGui/qtransform.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -245,6 +243,4 @@ Q_GUI_EXPORT QDebug operator<<(QDebug, const QPixmap &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPIXMAP_H
diff --git a/src/gui/image/qpixmap_raster.cpp b/src/gui/image/qpixmap_raster.cpp
index f8fef9cada..302945dbf8 100644
--- a/src/gui/image/qpixmap_raster.cpp
+++ b/src/gui/image/qpixmap_raster.cpp
@@ -240,12 +240,14 @@ QImage QRasterPlatformPixmap::toImage(const QRect &rect) const
QRect clipped = rect.intersected(QRect(0, 0, w, h));
const uint du = uint(d);
- if ((du % 8 == 0) && (((uint(clipped.x()) * du)) % 32 == 0))
- return QImage(image.scanLine(clipped.y()) + clipped.x() * (du / 8),
+ if ((du % 8 == 0) && (((uint(clipped.x()) * du)) % 32 == 0)) {
+ QImage newImage(image.scanLine(clipped.y()) + clipped.x() * (du / 8),
clipped.width(), clipped.height(),
image.bytesPerLine(), image.format());
- else
+ return newImage;
+ } else {
return image.copy(clipped);
+ }
}
QPaintEngine* QRasterPlatformPixmap::paintEngine() const
@@ -354,7 +356,9 @@ void QRasterPlatformPixmap::createPixmapForImage(QImage &sourceImage, Qt::ImageC
is_null = (w <= 0 || h <= 0);
image.d->devicePixelRatio = sourceImage.devicePixelRatio();
+ //ensure the pixmap and the image resulting from toImage() have the same cacheKey();
setSerialNumber(image.cacheKey() >> 32);
+ setDetachNumber(image.d->detach_no);
}
QImage* QRasterPlatformPixmap::buffer()
diff --git a/src/gui/image/qpixmapcache.h b/src/gui/image/qpixmapcache.h
index 7f7db7dc35..83e6610f2a 100644
--- a/src/gui/image/qpixmapcache.h
+++ b/src/gui/image/qpixmapcache.h
@@ -48,8 +48,6 @@
#include <QtCore/qpair.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -96,6 +94,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPIXMAPCACHE_H
diff --git a/src/gui/image/qplatformpixmap.cpp b/src/gui/image/qplatformpixmap.cpp
index ce66972dc3..54f0087bc2 100644
--- a/src/gui/image/qplatformpixmap.cpp
+++ b/src/gui/image/qplatformpixmap.cpp
@@ -173,6 +173,11 @@ void QPlatformPixmap::setSerialNumber(int serNo)
ser_no = serNo;
}
+void QPlatformPixmap::setDetachNumber(int detNo)
+{
+ detach_no = detNo;
+}
+
QImage QPlatformPixmap::toImage(const QRect &rect) const
{
if (rect.contains(QRect(0, 0, w, h)))
diff --git a/src/gui/image/qplatformpixmap.h b/src/gui/image/qplatformpixmap.h
index ded4bd30a9..08e03f10bd 100644
--- a/src/gui/image/qplatformpixmap.h
+++ b/src/gui/image/qplatformpixmap.h
@@ -54,8 +54,6 @@
#include <QtGui/qpixmap.h>
#include <QtCore/qatomic.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -132,6 +130,7 @@ public:
protected:
void setSerialNumber(int serNo);
+ void setDetachNumber(int detNo);
int w;
int h;
int d;
@@ -158,6 +157,4 @@ extern bool qt_xForm_helper(const QTransform&, int, int, int, uchar*, int, int,
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMPIXMAP_H
diff --git a/src/gui/image/qxbmhandler.cpp b/src/gui/image/qxbmhandler.cpp
index 0e1ecfa299..498f6ce767 100644
--- a/src/gui/image/qxbmhandler.cpp
+++ b/src/gui/image/qxbmhandler.cpp
@@ -302,7 +302,7 @@ bool QXbmHandler::read(QImage *image)
{
if (state == Error)
return false;
-
+
if (state == Ready && !readHeader()) {
state = Error;
return false;
diff --git a/src/gui/itemmodels/qstandarditemmodel.cpp b/src/gui/itemmodels/qstandarditemmodel.cpp
index d6161671b1..d5d742c9b3 100644
--- a/src/gui/itemmodels/qstandarditemmodel.cpp
+++ b/src/gui/itemmodels/qstandarditemmodel.cpp
@@ -2714,7 +2714,7 @@ bool QStandardItemModel::hasChildren(const QModelIndex &parent) const
*/
QModelIndex QStandardItemModel::sibling(int row, int column, const QModelIndex &idx) const
{
- return createIndex(row, column, idx.internalPointer());
+ return QAbstractItemModel::sibling(row, column, idx);
}
/*!
diff --git a/src/gui/itemmodels/qstandarditemmodel.h b/src/gui/itemmodels/qstandarditemmodel.h
index b4f03008fd..f1820e1c80 100644
--- a/src/gui/itemmodels/qstandarditemmodel.h
+++ b/src/gui/itemmodels/qstandarditemmodel.h
@@ -50,8 +50,6 @@
#include <QtCore/qdatastream.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -332,6 +330,7 @@ public:
int rowCount(const QModelIndex &parent = QModelIndex()) const;
int columnCount(const QModelIndex &parent = QModelIndex()) const;
bool hasChildren(const QModelIndex &parent = QModelIndex()) const;
+ // Qt 6: Remove
QModelIndex sibling(int row, int column, const QModelIndex &idx) const;
QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const;
@@ -453,6 +452,4 @@ Q_GUI_EXPORT QDataStream &operator<<(QDataStream &out, const QStandardItem &item
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QSTANDARDITEMMODEL_H
diff --git a/src/gui/kernel/kernel.pri b/src/gui/kernel/kernel.pri
index f766b5fbaf..eb87a8c31b 100644
--- a/src/gui/kernel/kernel.pri
+++ b/src/gui/kernel/kernel.pri
@@ -24,6 +24,7 @@ HEADERS += \
kernel/qplatformthemefactory_p.h \
kernel/qplatformthemeplugin.h \
kernel/qplatformwindow.h \
+ kernel/qplatformoffscreensurface.h \
kernel/qplatformwindow_p.h \
kernel/qplatformcursor.h \
kernel/qplatformclipboard.h \
@@ -34,6 +35,7 @@ HEADERS += \
kernel/qguiapplication_p.h \
kernel/qwindow_p.h \
kernel/qwindow.h \
+ kernel/qoffscreensurface.h \
kernel/qplatformsurface.h \
kernel/qsurface.h \
kernel/qclipboard.h \
@@ -81,6 +83,7 @@ SOURCES += \
kernel/qplatformthemefactory.cpp \
kernel/qplatformthemeplugin.cpp \
kernel/qplatformwindow.cpp \
+ kernel/qplatformoffscreensurface.cpp \
kernel/qplatformcursor.cpp \
kernel/qplatformclipboard.cpp \
kernel/qplatformnativeinterface.cpp \
@@ -88,6 +91,7 @@ SOURCES += \
kernel/qsurfaceformat.cpp \
kernel/qguiapplication.cpp \
kernel/qwindow.cpp \
+ kernel/qoffscreensurface.cpp \
kernel/qplatformsurface.cpp \
kernel/qsurface.cpp \
kernel/qclipboard.cpp \
diff --git a/src/gui/kernel/qclipboard.cpp b/src/gui/kernel/qclipboard.cpp
index 79da6471b8..f0b1f16ba2 100644
--- a/src/gui/kernel/qclipboard.cpp
+++ b/src/gui/kernel/qclipboard.cpp
@@ -226,7 +226,7 @@ QClipboard::~QClipboard()
the global clipboard.
\value Selection indicates that data should be stored and retrieved from
- the global mouse selection. Support for \c Selection is provided only on
+ the global mouse selection. Support for \c Selection is provided only on
systems with a global mouse selection (e.g. X11).
\value FindBuffer indicates that data should be stored and retrieved from
@@ -344,7 +344,7 @@ void QClipboard::setText(const QString &text, Mode mode)
clipboard is used. If \a mode is QClipboard::Clipboard, the
image is retrieved from the global clipboard. If \a mode is
QClipboard::Selection, the image is retrieved from the global
- mouse selection.
+ mouse selection.
\sa setImage(), pixmap(), mimeData(), QImage::isNull()
*/
@@ -459,7 +459,7 @@ void QClipboard::setPixmap(const QPixmap &pixmap, Mode mode)
\sa mimeData()
*/
-/*!
+/*!
\fn void QClipboard::clear(Mode mode)
Clear the clipboard contents.
@@ -467,7 +467,7 @@ void QClipboard::setPixmap(const QPixmap &pixmap, Mode mode)
clipboard is used. If \a mode is QClipboard::Clipboard, this
function clears the global clipboard contents. If \a mode is
QClipboard::Selection, this function clears the global mouse
- selection contents. If \a mode is QClipboard::FindBuffer, this
+ selection contents. If \a mode is QClipboard::FindBuffer, this
function clears the search string buffer.
\sa QClipboard::Mode, supportsSelection()
@@ -521,21 +521,21 @@ bool QClipboard::ownsFindBuffer() const
return ownsMode(FindBuffer);
}
-/*!
+/*!
\internal
\fn bool QClipboard::supportsMode(Mode mode) const;
Returns true if the clipboard supports the clipboard mode speacified by \a mode;
otherwise returns false.
*/
-/*!
+/*!
\internal
\fn bool QClipboard::ownsMode(Mode mode) const;
Returns true if the clipboard supports the clipboard data speacified by \a mode;
otherwise returns false.
*/
-/*!
+/*!
\internal
Emits the appropriate changed signal for \a mode.
*/
diff --git a/src/gui/kernel/qclipboard.h b/src/gui/kernel/qclipboard.h
index 520d731717..7235a03b6b 100644
--- a/src/gui/kernel/qclipboard.h
+++ b/src/gui/kernel/qclipboard.h
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -112,6 +110,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCLIPBOARD_H
diff --git a/src/gui/kernel/qcursor.h b/src/gui/kernel/qcursor.h
index d4ca15ff93..0bf4cc7bf9 100644
--- a/src/gui/kernel/qcursor.h
+++ b/src/gui/kernel/qcursor.h
@@ -45,8 +45,6 @@
#include <QtCore/qpoint.h>
#include <QtGui/qwindowdefs.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -109,7 +107,7 @@ public:
static void setPos(QScreen *screen, int x, int y);
inline static void setPos(const QPoint &p) { setPos(p.x(), p.y()); }
inline static void setPos(QScreen *screen, const QPoint &p) { setPos(screen, p.x(), p.y()); }
-
+
private:
QCursorData *d;
};
@@ -130,6 +128,4 @@ Q_GUI_EXPORT QDebug operator<<(QDebug, const QCursor &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCURSOR_H
diff --git a/src/gui/kernel/qdrag.h b/src/gui/kernel/qdrag.h
index abbb382400..553b0e1922 100644
--- a/src/gui/kernel/qdrag.h
+++ b/src/gui/kernel/qdrag.h
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -100,6 +98,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDRAG_H
diff --git a/src/gui/kernel/qevent.cpp b/src/gui/kernel/qevent.cpp
index e9527bdc48..4f1f7d838f 100644
--- a/src/gui/kernel/qevent.cpp
+++ b/src/gui/kernel/qevent.cpp
@@ -3071,6 +3071,35 @@ QShortcutEvent::~QShortcutEvent()
#endif // QT_NO_SHORTCUT
#ifndef QT_NO_DEBUG_STREAM
+
+static inline void formatTouchEvent(QDebug d, const char *name, const QTouchEvent &t)
+{
+ d << "QTouchEvent(" << name << " states: " << t.touchPointStates();
+ const QList<QTouchEvent::TouchPoint> points = t.touchPoints();
+ const int size = points.size();
+ d << ", " << size << " points: ";
+ for (int i = 0; i < size; ++i) {
+ if (i)
+ d << ", ";
+ d << points.at(i).pos() << ' ' << points.at(i).rect();
+ switch (points.at(i).state()) {
+ case Qt::TouchPointPressed:
+ d << " pressed";
+ break;
+ case Qt::TouchPointReleased:
+ d << " released";
+ break;
+ case Qt::TouchPointMoved:
+ d << " moved";
+ break;
+ case Qt::TouchPointStationary:
+ d << " stationary";
+ break;
+ }
+ }
+ d << ')';
+}
+
QDebug operator<<(QDebug dbg, const QEvent *e) {
// More useful event output could be added here
if (!e)
@@ -3337,6 +3366,14 @@ QDebug operator<<(QDebug dbg, const QEvent *e) {
case QEvent::UngrabKeyboard:
n = "UngrabKeyboard";
break;
+ case QEvent::TouchBegin:
+ n = "TouchBegin";
+ case QEvent::TouchUpdate:
+ n = n ? n : "TouchUpdate";
+ case QEvent::TouchEnd:
+ n = n ? n : "TouchEnd";
+ formatTouchEvent(dbg.nospace(), n, *static_cast<const QTouchEvent*>(e));
+ return dbg.nospace();
case QEvent::ChildAdded: n = n ? n : "ChildAdded";
case QEvent::ChildPolished: n = n ? n : "ChildPolished";
case QEvent::ChildRemoved: n = n ? n : "ChildRemoved";
@@ -4363,4 +4400,21 @@ Qt::ScreenOrientation QScreenOrientationChangeEvent::orientation() const
return m_orientation;
}
+/*!
+ Creates a new QApplicationStateChangeEvent.
+ \a applicationState is the new state.
+*/
+QApplicationStateChangeEvent::QApplicationStateChangeEvent(Qt::ApplicationState applicationState)
+ : QEvent(QEvent::ApplicationStateChange), m_applicationState(applicationState)
+{
+}
+
+/*!
+ Returns the state of the application.
+*/
+Qt::ApplicationState QApplicationStateChangeEvent::applicationState() const
+{
+ return m_applicationState;
+}
+
QT_END_NAMESPACE
diff --git a/src/gui/kernel/qevent.h b/src/gui/kernel/qevent.h
index e84765cae6..79dcc6d250 100644
--- a/src/gui/kernel/qevent.h
+++ b/src/gui/kernel/qevent.h
@@ -58,8 +58,6 @@
#include <QtGui/qvector2d.h>
#include <QtGui/qtouchdevice.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -907,8 +905,16 @@ private:
Qt::ScreenOrientation m_orientation;
};
-QT_END_NAMESPACE
+class Q_GUI_EXPORT QApplicationStateChangeEvent : public QEvent
+{
+public:
+ explicit QApplicationStateChangeEvent(Qt::ApplicationState state);
+ Qt::ApplicationState applicationState() const;
-QT_END_HEADER
+private:
+ Qt::ApplicationState m_applicationState;
+};
+
+QT_END_NAMESPACE
#endif // QEVENT_H
diff --git a/src/gui/kernel/qgenericplugin.h b/src/gui/kernel/qgenericplugin.h
index 10bde146bd..f00a532283 100644
--- a/src/gui/kernel/qgenericplugin.h
+++ b/src/gui/kernel/qgenericplugin.h
@@ -45,8 +45,6 @@
#include <QtCore/qplugin.h>
#include <QtCore/qfactoryinterface.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -68,6 +66,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGENERICPLUGIN_H
diff --git a/src/gui/kernel/qgenericpluginfactory.h b/src/gui/kernel/qgenericpluginfactory.h
index 03d688a5c5..2443e670cc 100644
--- a/src/gui/kernel/qgenericpluginfactory.h
+++ b/src/gui/kernel/qgenericpluginfactory.h
@@ -44,8 +44,6 @@
#include <QtCore/qstringlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -61,6 +59,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGENERICPLUGINFACTORY_H
diff --git a/src/gui/kernel/qguiapplication.cpp b/src/gui/kernel/qguiapplication.cpp
index c155ecfe0c..c2e19ca2a8 100644
--- a/src/gui/kernel/qguiapplication.cpp
+++ b/src/gui/kernel/qguiapplication.cpp
@@ -111,6 +111,8 @@ bool QGuiApplicationPrivate::tabletState = false;
QWindow *QGuiApplicationPrivate::tabletPressTarget = 0;
QWindow *QGuiApplicationPrivate::currentMouseWindow = 0;
+Qt::ApplicationState QGuiApplicationPrivate::applicationState = Qt::ApplicationInactive;
+
QPlatformIntegration *QGuiApplicationPrivate::platform_integration = 0;
QPlatformTheme *QGuiApplicationPrivate::platform_theme = 0;
@@ -664,7 +666,7 @@ QWindowList QGuiApplication::topLevelWindows()
const QWindowList &list = QGuiApplicationPrivate::window_list;
QWindowList topLevelWindows;
for (int i = 0; i < list.size(); i++) {
- if (!list.at(i)->parent()) {
+ if (!list.at(i)->parent() && list.at(i)->type() != Qt::Desktop) {
// Top windows of embedded QAxServers do not have QWindow parents,
// but they are not true top level windows, so do not include them.
const bool embedded = list.at(i)->handle() && list.at(i)->handle()->isEmbedded(0);
@@ -926,6 +928,8 @@ static bool runningUnderDebugger()
void QGuiApplicationPrivate::init()
{
+ QCoreApplicationPrivate::is_app_running = false; // Starting up.
+
bool doGrabUnderDebugger = false;
QList<QByteArray> pluginList;
// Get command line params
@@ -1063,6 +1067,8 @@ QGuiApplicationPrivate::~QGuiApplicationPrivate()
delete platform_integration;
platform_integration = 0;
delete m_gammaTables.load();
+
+ window_list.clear();
}
#if 0
@@ -1272,6 +1278,12 @@ void QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePriv
case QWindowSystemInterfacePrivate::WindowStateChanged:
QGuiApplicationPrivate::processWindowStateChangedEvent(static_cast<QWindowSystemInterfacePrivate::WindowStateChangedEvent *>(e));
break;
+ case QWindowSystemInterfacePrivate::ApplicationStateChanged:
+ QGuiApplicationPrivate::processApplicationStateChangedEvent(static_cast<QWindowSystemInterfacePrivate::ApplicationStateChangedEvent *>(e));
+ break;
+ case QWindowSystemInterfacePrivate::FlushEvents:
+ QWindowSystemInterface::deferredFlushWindowSystemEvents();
+ break;
case QWindowSystemInterfacePrivate::Close:
QGuiApplicationPrivate::processCloseEvent(
static_cast<QWindowSystemInterfacePrivate::CloseEvent *>(e));
@@ -1497,10 +1509,20 @@ void QGuiApplicationPrivate::processKeyEvent(QWindowSystemInterfacePrivate::KeyE
{
QWindow *window = e->window.data();
modifier_buttons = e->modifiers;
- if (e->nullWindow)
+ if (e->nullWindow
+#ifdef Q_OS_ANDROID
+ || (e->keyType == QEvent::KeyRelease && e->key == Qt::Key_Back) || e->key == Qt::Key_Menu
+#endif
+ ) {
window = QGuiApplication::focusWindow();
- if (!window)
+ }
+ if (!window
+#ifdef Q_OS_ANDROID
+ && e->keyType != QEvent::KeyRelease && e->key != Qt::Key_Back
+#endif
+ ) {
return;
+ }
if (window->d_func()->blockedByModalWindow) {
// a modal window is blocking this window, don't allow key events through
return;
@@ -1510,7 +1532,19 @@ void QGuiApplicationPrivate::processKeyEvent(QWindowSystemInterfacePrivate::KeyE
e->nativeScanCode, e->nativeVirtualKey, e->nativeModifiers,
e->unicode, e->repeat, e->repeatCount);
ev.setTimestamp(e->timestamp);
- QGuiApplication::sendSpontaneousEvent(window, &ev);
+
+#ifdef Q_OS_ANDROID
+ if (e->keyType == QEvent::KeyRelease && e->key == Qt::Key_Back) {
+ if (!window) {
+ qApp->quit();
+ } else {
+ QGuiApplication::sendEvent(window, &ev);
+ if (!ev.isAccepted() && e->key == Qt::Key_Back)
+ QWindowSystemInterface::handleCloseEvent(window);
+ }
+ } else
+#endif
+ QGuiApplication::sendSpontaneousEvent(window, &ev);
}
void QGuiApplicationPrivate::processEnterEvent(QWindowSystemInterfacePrivate::EnterEvent *e)
@@ -1559,25 +1593,31 @@ void QGuiApplicationPrivate::processActivatedEvent(QWindowSystemInterfacePrivate
}
QGuiApplicationPrivate::focus_window = newFocus;
+ if (!qApp)
+ return;
if (previous) {
- QFocusEvent focusOut(QEvent::FocusOut);
+ QFocusEvent focusOut(QEvent::FocusOut, e->reason);
QCoreApplication::sendSpontaneousEvent(previous, &focusOut);
QObject::disconnect(previous, SIGNAL(focusObjectChanged(QObject*)),
qApp, SLOT(_q_updateFocusObject(QObject*)));
- } else {
+ } else if (!platformIntegration()->hasCapability(QPlatformIntegration::ApplicationState)) {
QEvent appActivate(QEvent::ApplicationActivate);
qApp->sendSpontaneousEvent(qApp, &appActivate);
+ QApplicationStateChangeEvent appState(Qt::ApplicationActive);
+ qApp->sendSpontaneousEvent(qApp, &appState);
}
if (QGuiApplicationPrivate::focus_window) {
- QFocusEvent focusIn(QEvent::FocusIn);
+ QFocusEvent focusIn(QEvent::FocusIn, e->reason);
QCoreApplication::sendSpontaneousEvent(QGuiApplicationPrivate::focus_window, &focusIn);
QObject::connect(QGuiApplicationPrivate::focus_window, SIGNAL(focusObjectChanged(QObject*)),
qApp, SLOT(_q_updateFocusObject(QObject*)));
- } else {
+ } else if (!platformIntegration()->hasCapability(QPlatformIntegration::ApplicationState)) {
QEvent appActivate(QEvent::ApplicationDeactivate);
qApp->sendSpontaneousEvent(qApp, &appActivate);
+ QApplicationStateChangeEvent appState(Qt::ApplicationInactive);
+ qApp->sendSpontaneousEvent(qApp, &appState);
}
if (self) {
@@ -1599,6 +1639,29 @@ void QGuiApplicationPrivate::processWindowStateChangedEvent(QWindowSystemInterfa
}
}
+void QGuiApplicationPrivate::processApplicationStateChangedEvent(QWindowSystemInterfacePrivate::ApplicationStateChangedEvent *e)
+{
+ if (e->newState == applicationState)
+ return;
+ applicationState = e->newState;
+
+ switch (e->newState) {
+ case Qt::ApplicationActive: {
+ QEvent appActivate(QEvent::ApplicationActivate);
+ qApp->sendSpontaneousEvent(qApp, &appActivate);
+ break; }
+ case Qt::ApplicationInactive: {
+ QEvent appDeactivate(QEvent::ApplicationDeactivate);
+ qApp->sendSpontaneousEvent(qApp, &appDeactivate);
+ break; }
+ default:
+ break;
+ }
+
+ QApplicationStateChangeEvent event(applicationState);
+ qApp->sendSpontaneousEvent(qApp, &event);
+}
+
void QGuiApplicationPrivate::processThemeChanged(QWindowSystemInterfacePrivate::ThemeChangeEvent *tce)
{
if (self)
@@ -1665,10 +1728,10 @@ void QGuiApplicationPrivate::processCloseEvent(QWindowSystemInterfacePrivate::Cl
void QGuiApplicationPrivate::processFileOpenEvent(QWindowSystemInterfacePrivate::FileOpenEvent *e)
{
- if (e->fileName.isEmpty())
+ if (e->url.isEmpty())
return;
- QFileOpenEvent event(e->fileName);
+ QFileOpenEvent event(e->url);
QGuiApplication::sendSpontaneousEvent(qApp, &event);
}
@@ -2622,6 +2685,13 @@ static inline void applyCursor(QWindow *w, QCursor c)
cursor->changeCursor(&c, w);
}
+static inline void unsetCursor(QWindow *w)
+{
+ if (const QScreen *screen = w->screen())
+ if (QPlatformCursor *cursor = screen->handle()->cursor())
+ cursor->changeCursor(0, w);
+}
+
static inline void applyCursor(const QList<QWindow *> &l, const QCursor &c)
{
for (int i = 0; i < l.size(); ++i) {
@@ -2635,8 +2705,13 @@ static inline void applyWindowCursor(const QList<QWindow *> &l)
{
for (int i = 0; i < l.size(); ++i) {
QWindow *w = l.at(i);
- if (w->handle() && w->type() != Qt::Desktop)
- applyCursor(w, w->cursor());
+ if (w->handle() && w->type() != Qt::Desktop) {
+ if (qt_window_private(w)->hasCursor) {
+ applyCursor(w, w->cursor());
+ } else {
+ unsetCursor(w);
+ }
+ }
}
}
@@ -2768,111 +2843,6 @@ QInputMethod *QGuiApplication::inputMethod()
QFontDatabase::removeApplicationFont()
*/
-// These pixmaps approximate the images in the Windows User Interface Guidelines.
-
-// XPM
-
-static const char * const move_xpm[] = {
-"11 20 3 1",
-". c None",
-"a c #FFFFFF",
-"X c #000000", // X11 cursor is traditionally black
-"aa.........",
-"aXa........",
-"aXXa.......",
-"aXXXa......",
-"aXXXXa.....",
-"aXXXXXa....",
-"aXXXXXXa...",
-"aXXXXXXXa..",
-"aXXXXXXXXa.",
-"aXXXXXXXXXa",
-"aXXXXXXaaaa",
-"aXXXaXXa...",
-"aXXaaXXa...",
-"aXa..aXXa..",
-"aa...aXXa..",
-"a.....aXXa.",
-"......aXXa.",
-".......aXXa",
-".......aXXa",
-"........aa."};
-
-
-/* XPM */
-static const char * const copy_xpm[] = {
-"24 30 3 1",
-". c None",
-"a c #000000",
-"X c #FFFFFF",
-"XX......................",
-"XaX.....................",
-"XaaX....................",
-"XaaaX...................",
-"XaaaaX..................",
-"XaaaaaX.................",
-"XaaaaaaX................",
-"XaaaaaaaX...............",
-"XaaaaaaaaX..............",
-"XaaaaaaaaaX.............",
-"XaaaaaaXXXX.............",
-"XaaaXaaX................",
-"XaaXXaaX................",
-"XaX..XaaX...............",
-"XX...XaaX...............",
-"X.....XaaX..............",
-"......XaaX..............",
-".......XaaX.............",
-".......XaaX.............",
-"........XX...aaaaaaaaaaa",
-".............aXXXXXXXXXa",
-".............aXXXXXXXXXa",
-".............aXXXXaXXXXa",
-".............aXXXXaXXXXa",
-".............aXXaaaaaXXa",
-".............aXXXXaXXXXa",
-".............aXXXXaXXXXa",
-".............aXXXXXXXXXa",
-".............aXXXXXXXXXa",
-".............aaaaaaaaaaa"};
-
-/* XPM */
-static const char * const link_xpm[] = {
-"24 30 3 1",
-". c None",
-"a c #000000",
-"X c #FFFFFF",
-"XX......................",
-"XaX.....................",
-"XaaX....................",
-"XaaaX...................",
-"XaaaaX..................",
-"XaaaaaX.................",
-"XaaaaaaX................",
-"XaaaaaaaX...............",
-"XaaaaaaaaX..............",
-"XaaaaaaaaaX.............",
-"XaaaaaaXXXX.............",
-"XaaaXaaX................",
-"XaaXXaaX................",
-"XaX..XaaX...............",
-"XX...XaaX...............",
-"X.....XaaX..............",
-"......XaaX..............",
-".......XaaX.............",
-".......XaaX.............",
-"........XX...aaaaaaaaaaa",
-".............aXXXXXXXXXa",
-".............aXXXaaaaXXa",
-".............aXXXXaaaXXa",
-".............aXXXaaaaXXa",
-".............aXXaaaXaXXa",
-".............aXXaaXXXXXa",
-".............aXXaXXXXXXa",
-".............aXXXaXXXXXa",
-".............aXXXXXXXXXa",
-".............aaaaaaaaaaa"};
-
QPixmap QGuiApplicationPrivate::getPixmapCursor(Qt::CursorShape cshape)
{
Q_UNUSED(cshape);
diff --git a/src/gui/kernel/qguiapplication.h b/src/gui/kernel/qguiapplication.h
index f90321f396..0e9d6f2336 100644
--- a/src/gui/kernel/qguiapplication.h
+++ b/src/gui/kernel/qguiapplication.h
@@ -49,8 +49,6 @@
#include <QtCore/qpoint.h>
#include <QtCore/qsize.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -187,6 +185,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGUIAPPLICATION_H
diff --git a/src/gui/kernel/qguiapplication_p.h b/src/gui/kernel/qguiapplication_p.h
index 0946591887..22d95b2121 100644
--- a/src/gui/kernel/qguiapplication_p.h
+++ b/src/gui/kernel/qguiapplication_p.h
@@ -65,8 +65,6 @@
#include "private/qshortcutmap_p.h"
#include <qicon.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QPlatformIntegration;
@@ -109,7 +107,7 @@ public:
static QAbstractEventDispatcher *qt_qpa_core_dispatcher()
{
if (QCoreApplication::instance())
- return QCoreApplication::instance()->d_func()->threadData->eventDispatcher;
+ return QCoreApplication::instance()->d_func()->threadData->eventDispatcher.load();
else
return 0;
}
@@ -129,6 +127,8 @@ public:
static void processActivatedEvent(QWindowSystemInterfacePrivate::ActivatedWindowEvent *e);
static void processWindowStateChangedEvent(QWindowSystemInterfacePrivate::WindowStateChangedEvent *e);
+ static void processApplicationStateChangedEvent(QWindowSystemInterfacePrivate::ApplicationStateChangedEvent *e);
+
static void processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent *e);
static void updateFilteredScreenOrientation(QScreen *screen);
@@ -201,6 +201,7 @@ public:
static bool tabletState;
static QWindow *tabletPressTarget;
static QWindow *currentMouseWindow;
+ static Qt::ApplicationState applicationState;
#ifndef QT_NO_CLIPBOARD
static QClipboard *qt_clipboard;
@@ -293,6 +294,4 @@ Q_GUI_EXPORT bool operator==(const QGuiApplicationPrivate::ActiveTouchPointsKey
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGUIAPPLICATION_P_H
diff --git a/src/gui/kernel/qinputmethod.cpp b/src/gui/kernel/qinputmethod.cpp
index 436b0aed1e..438c169f71 100644
--- a/src/gui/kernel/qinputmethod.cpp
+++ b/src/gui/kernel/qinputmethod.cpp
@@ -99,6 +99,33 @@ void QInputMethod::setInputItemTransform(const QTransform &transform)
emit cursorRectangleChanged();
}
+
+/*!
+ \since 5.1
+
+ Returns the input item's geometry in input item coordinates.
+
+ \sa setInputItemRectangle()
+*/
+QRectF QInputMethod::inputItemRectangle() const
+{
+ Q_D(const QInputMethod);
+ return d->inputRectangle;
+}
+
+/*!
+ \since 5.1
+
+ Sets the input item's geometry to be \a rect, in input item coordinates.
+ This needs to be updated by the focused window like QQuickCanvas whenever
+ item is moved inside the scene, or focus is changed.
+*/
+void QInputMethod::setInputItemRectangle(const QRectF &rect)
+{
+ Q_D(QInputMethod);
+ d->inputRectangle = rect;
+}
+
/*!
\property QInputMethod::cursorRectangle
\brief Input item's cursor rectangle in window coordinates.
diff --git a/src/gui/kernel/qinputmethod.h b/src/gui/kernel/qinputmethod.h
index 35e29e9cb5..fe6cc3f331 100644
--- a/src/gui/kernel/qinputmethod.h
+++ b/src/gui/kernel/qinputmethod.h
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QInputMethodPrivate;
@@ -69,6 +67,9 @@ public:
QTransform inputItemTransform() const;
void setInputItemTransform(const QTransform &transform);
+ QRectF inputItemRectangle() const;
+ void setInputItemRectangle(const QRectF &rect);
+
// in window coordinates
QRectF cursorRectangle() const; // ### what if we have rotations for the item?
@@ -116,6 +117,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/kernel/qinputmethod_p.h b/src/gui/kernel/qinputmethod_p.h
index ab91660e3f..79b1299722 100644
--- a/src/gui/kernel/qinputmethod_p.h
+++ b/src/gui/kernel/qinputmethod_p.h
@@ -61,8 +61,6 @@
#include <qpa/qplatformintegration.h>
#include <private/qguiapplication_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QInputMethodPrivate : public QObjectPrivate
@@ -86,11 +84,10 @@ public:
bool objectAcceptsInputMethod(QObject *object);
QTransform inputItemTransform;
+ QRectF inputRectangle;
QPlatformInputContext *testContext;
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/kernel/qkeysequence.cpp b/src/gui/kernel/qkeysequence.cpp
index 07ec658818..44de8c5847 100644
--- a/src/gui/kernel/qkeysequence.cpp
+++ b/src/gui/kernel/qkeysequence.cpp
@@ -257,6 +257,7 @@ void Q_GUI_EXPORT qt_set_sequence_auto_mnemonic(bool b) { qt_sequence_no_mnemoni
\row \li FindPrevious \li Shift+F3, Ctrl+Shift+G \li Ctrl+Shift+G \li Shift+F3 \li Ctrl+Shift+G, Shift+F3
\row \li Replace \li Ctrl+H \li (none) \li Ctrl+R \li Ctrl+H
\row \li SelectAll \li Ctrl+A \li Ctrl+A \li Ctrl+A \li Ctrl+A
+ \row \li Deselect \li \li \li Ctrl+Shift+A \li Ctrl+Shift+A
\row \li Bold \li Ctrl+B \li Ctrl+B \li Ctrl+B \li Ctrl+B
\row \li Italic \li Ctrl+I \li Ctrl+I \li Ctrl+I \li Ctrl+I
\row \li Underline \li Ctrl+U \li Ctrl+U \li Ctrl+U \li Ctrl+U
@@ -753,6 +754,7 @@ const QKeyBinding QKeySequencePrivate::keyBindings[] = {
{QKeySequence::Close, 0, Qt::CTRL | Qt::Key_F4, KB_Mac},
{QKeySequence::NextChild, 0, Qt::CTRL | Qt::Key_F6, KB_Win},
{QKeySequence::FullScreen, 1, Qt::CTRL | Qt::Key_F11, KB_Gnome},
+ {QKeySequence::Deselect, 0, Qt::CTRL | Qt::SHIFT | Qt::Key_A, KB_X11},
{QKeySequence::FullScreen, 0, Qt::CTRL | Qt::SHIFT | Qt::Key_F, KB_KDE},
{QKeySequence::FindPrevious, 1, Qt::CTRL | Qt::SHIFT | Qt::Key_G, KB_Gnome | KB_Mac},
{QKeySequence::FindPrevious, 0, Qt::CTRL | Qt::SHIFT | Qt::Key_G, KB_Win},
@@ -866,6 +868,7 @@ const uint QKeySequencePrivate::numberOfKeyBindings = sizeof(QKeySequencePrivate
\value SaveAs Save document after prompting the user for a file name.
\value Save Save document.
\value SelectAll Select all text.
+ \value Deselect Deselect text. Since 5.1
\value SelectEndOfBlock Extend selection to the end of a text block. This shortcut is only used on OS X.
\value SelectEndOfDocument Extend selection to end of document.
\value SelectEndOfLine Extend selection to end of line.
@@ -878,7 +881,7 @@ const uint QKeySequencePrivate::numberOfKeyBindings = sizeof(QKeySequencePrivate
\value SelectPreviousPage Extend selection to previous page.
\value SelectPreviousWord Extend selection to previous word.
\value SelectStartOfBlock Extend selection to the start of a text block. This shortcut is only used on OS X.
- \value SelectStartOfDocument Extend selection to start of document.
+ \value SelectStartOfDocument Extend selection to start of document.
\value SelectStartOfLine Extend selection to start of line.
\value Underline Underline text.
\value Undo Undo.
@@ -892,10 +895,10 @@ const uint QKeySequencePrivate::numberOfKeyBindings = sizeof(QKeySequencePrivate
/*!
\since 4.2
- Constructs a QKeySequence object for the given \a key.
- The result will depend on the currently running platform.
+ Constructs a QKeySequence object for the given \a key.
+ The result will depend on the currently running platform.
- The resulting object will be based on the first element in the
+ The resulting object will be based on the first element in the
list of key bindings for the \a key.
*/
QKeySequence::QKeySequence(StandardKey key)
@@ -903,7 +906,7 @@ QKeySequence::QKeySequence(StandardKey key)
const QList <QKeySequence> bindings = keyBindings(key);
//pick only the first/primary shortcut from current bindings
if (bindings.size() > 0) {
- d = bindings.first().d;
+ d = bindings.first().d;
d->ref.ref();
}
else
@@ -991,8 +994,8 @@ static inline int maybeSwapShortcut(int shortcut)
\since 4.2
Returns a list of key bindings for the given \a key.
- The result of calling this function will vary based on the target platform.
- The first element of the list indicates the primary shortcut for the given platform.
+ The result of calling this function will vary based on the target platform.
+ The first element of the list indicates the primary shortcut for the given platform.
If the result contains more than one result, these can
be considered alternative shortcuts on the same platform for the given \a key.
*/
@@ -1509,9 +1512,9 @@ QKeySequence::SequenceMatch QKeySequence::matches(const QKeySequence &seq) const
\obsolete
- Use toString() instead.
-
- Returns the key sequence as a QString. This is equivalent to
+ Use toString() instead.
+
+ Returns the key sequence as a QString. This is equivalent to
calling toString(QKeySequence::NativeText). Note that the
result is not platform independent.
*/
@@ -1681,6 +1684,47 @@ QKeySequence QKeySequence::fromString(const QString &str, SequenceFormat format)
return QKeySequence(str, format);
}
+/*!
+ \since 5.1
+
+ Return a list of QKeySequence from the string \a str based on \a format.
+
+ \sa fromString()
+ \sa listToString()
+*/
+QList<QKeySequence> QKeySequence::listFromString(const QString &str, SequenceFormat format)
+{
+ QList<QKeySequence> result;
+
+ QStringList strings = str.split(QLatin1String("; "));
+ foreach (const QString &string, strings) {
+ result << fromString(string, format);
+ }
+
+ return result;
+}
+
+/*!
+ \since 5.1
+
+ Return a string representation of \a list based on \a format.
+
+ \sa toString()
+ \sa listFromString()
+*/
+QString QKeySequence::listToString(const QList<QKeySequence> &list, SequenceFormat format)
+{
+ QString result;
+
+ foreach (const QKeySequence &sequence, list) {
+ result += sequence.toString(format);
+ result += QLatin1String("; ");
+ }
+ result.truncate(result.length() - 2);
+
+ return result;
+}
+
/*****************************************************************************
QKeySequence stream functions
*****************************************************************************/
diff --git a/src/gui/kernel/qkeysequence.h b/src/gui/kernel/qkeysequence.h
index dd26efda8e..05460c6651 100644
--- a/src/gui/kernel/qkeysequence.h
+++ b/src/gui/kernel/qkeysequence.h
@@ -45,8 +45,6 @@
#include <QtCore/qnamespace.h>
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -138,7 +136,8 @@ public:
SaveAs,
Preferences,
Quit,
- FullScreen
+ FullScreen,
+ Deselect
};
enum SequenceFormat {
@@ -165,6 +164,9 @@ public:
QString toString(SequenceFormat format = PortableText) const;
static QKeySequence fromString(const QString &str, SequenceFormat format = PortableText);
+ static QList<QKeySequence> listFromString(const QString &str, SequenceFormat format = PortableText);
+ static QString listToString(const QList<QKeySequence> &list, SequenceFormat format = PortableText);
+
SequenceMatch matches(const QKeySequence &seq) const;
static QKeySequence mnemonic(const QString &text);
static QList<QKeySequence> keyBindings(StandardKey key);
@@ -231,6 +233,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QKEYSEQUENCE_H
diff --git a/src/gui/kernel/qoffscreensurface.cpp b/src/gui/kernel/qoffscreensurface.cpp
new file mode 100644
index 0000000000..e2306050dd
--- /dev/null
+++ b/src/gui/kernel/qoffscreensurface.cpp
@@ -0,0 +1,345 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qoffscreensurface.h"
+
+#include "qguiapplication_p.h"
+#include "qscreen.h"
+#include "qplatformintegration.h"
+#include "qplatformoffscreensurface.h"
+#include "qwindow.h"
+#include "qplatformwindow.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOffscreenSurface
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOffscreenSurface class represents an offscreen surface in the underlying platform.
+
+ QOffscreenSurface is intended to be used with QOpenGLContext to allow rendering with OpenGL in
+ an arbitrary thread without the need to create a QWindow.
+
+ Even though the surface is renderable, the surface's pixels are not accessible.
+ QOffscreenSurface should only be used to create OpenGL resources such as textures
+ or framebuffer objects.
+
+ An application will typically use QOffscreenSurface to perform some time-consuming tasks in a
+ separate thread in order to avoid stalling the main rendering thread. Resources created in the
+ QOffscreenSurface's context can be shared with the main OpenGL context. Some common use cases
+ are asynchronous texture uploads or rendering into a QOpenGLFramebufferObject.
+
+ How the offscreen surface is implemented depends on the underlying platform, but it will
+ typically use a pixel buffer (pbuffer). If the platform doesn't implement or support
+ offscreen surfaces, QOffscreenSurface will use an invisible QWindow internally.
+*/
+class Q_GUI_EXPORT QOffscreenSurfacePrivate : public QObjectPrivate
+{
+ Q_DECLARE_PUBLIC(QOffscreenSurface)
+
+public:
+ QOffscreenSurfacePrivate()
+ : QObjectPrivate()
+ , surfaceType(QSurface::OpenGLSurface)
+ , platformOffscreenSurface(0)
+ , offscreenWindow(0)
+ , screen(0)
+ , size(1, 1)
+ {
+ }
+
+ ~QOffscreenSurfacePrivate()
+ {
+ }
+
+ QSurface::SurfaceType surfaceType;
+ QPlatformOffscreenSurface *platformOffscreenSurface;
+ QWindow *offscreenWindow;
+ QSurfaceFormat requestedFormat;
+ QScreen *screen;
+ QSize size;
+};
+
+
+/*!
+ Creates an offscreen surface for the \a targetScreen.
+
+ The underlying platform surface is not created until create() is called.
+
+ \sa setScreen(), create()
+*/
+QOffscreenSurface::QOffscreenSurface(QScreen *targetScreen)
+ : QObject(*new QOffscreenSurfacePrivate(), 0)
+ , QSurface(Offscreen)
+{
+ Q_D(QOffscreenSurface);
+ d->screen = targetScreen;
+ if (!d->screen)
+ d->screen = QGuiApplication::primaryScreen();
+
+ //if your applications aborts here, then chances are your creating a QOffscreenSurface before
+ //the screen list is populated.
+ Q_ASSERT(d->screen);
+
+ connect(d->screen, SIGNAL(destroyed(QObject*)), this, SLOT(screenDestroyed(QObject*)));
+}
+
+
+/*!
+ Destroys the offscreen surface.
+*/
+QOffscreenSurface::~QOffscreenSurface()
+{
+ destroy();
+}
+
+/*!
+ Returns the surface type of the offscreen surface.
+
+ The surface type of an offscreen surface is always QSurface::OpenGLSurface.
+*/
+QOffscreenSurface::SurfaceType QOffscreenSurface::surfaceType() const
+{
+ Q_D(const QOffscreenSurface);
+ return d->surfaceType;
+}
+
+/*!
+ Allocates the platform resources associated with the offscreen surface.
+
+ It is at this point that the surface format set using setFormat() gets resolved
+ into an actual native surface.
+
+ Call destroy() to free the platform resources if necessary.
+
+ \sa destroy()
+*/
+void QOffscreenSurface::create()
+{
+ Q_D(QOffscreenSurface);
+ if (!d->platformOffscreenSurface && !d->offscreenWindow) {
+ d->platformOffscreenSurface = QGuiApplicationPrivate::platformIntegration()->createPlatformOffscreenSurface(this);
+ // No platform offscreen surface, fallback to an invisible window
+ if (!d->platformOffscreenSurface) {
+ d->offscreenWindow = new QWindow(d->screen);
+ d->offscreenWindow->setSurfaceType(QWindow::OpenGLSurface);
+ d->offscreenWindow->setFormat(d->requestedFormat);
+ d->offscreenWindow->setGeometry(0, 0, d->size.width(), d->size.height());
+ d->offscreenWindow->create();
+ }
+ }
+}
+
+/*!
+ Releases the native platform resources associated with this offscreen surface.
+
+ \sa create()
+*/
+void QOffscreenSurface::destroy()
+{
+ Q_D(QOffscreenSurface);
+ delete d->platformOffscreenSurface;
+ d->platformOffscreenSurface = 0;
+ if (d->offscreenWindow) {
+ d->offscreenWindow->destroy();
+ delete d->offscreenWindow;
+ d->offscreenWindow = 0;
+ }
+}
+
+/*!
+ Returns \c true if this offscreen surface is valid; otherwise returns \c false.
+
+ The offscreen surface is valid if the platform resources have been successfuly allocated.
+
+ \sa create()
+*/
+bool QOffscreenSurface::isValid() const
+{
+ Q_D(const QOffscreenSurface);
+ return (d->platformOffscreenSurface && d->platformOffscreenSurface->isValid())
+ || (d->offscreenWindow && d->offscreenWindow->handle());
+}
+
+/*!
+ Sets the offscreen surface \a format.
+
+ The surface format will be resolved in the create() function. Calling
+ this function after create() will not re-resolve the surface format of the native surface.
+
+ \sa create(), destroy()
+*/
+void QOffscreenSurface::setFormat(const QSurfaceFormat &format)
+{
+ Q_D(QOffscreenSurface);
+ d->requestedFormat = format;
+}
+
+/*!
+ Returns the requested surfaceformat of this offscreen surface.
+
+ If the requested format was not supported by the platform implementation,
+ the requestedFormat will differ from the actual offscreen surface format.
+
+ This is the value set with setFormat().
+
+ \sa setFormat(), format()
+ */
+QSurfaceFormat QOffscreenSurface::requestedFormat() const
+{
+ Q_D(const QOffscreenSurface);
+ return d->requestedFormat;
+}
+
+/*!
+ Returns the actual format of this offscreen surface.
+
+ After the offscreen surface has been created, this function will return the actual
+ surface format of the surface. It might differ from the requested format if the requested
+ format could not be fulfilled by the platform.
+
+ \sa create(), requestedFormat()
+*/
+QSurfaceFormat QOffscreenSurface::format() const
+{
+ Q_D(const QOffscreenSurface);
+ if (d->platformOffscreenSurface)
+ return d->platformOffscreenSurface->format();
+ if (d->offscreenWindow)
+ return d->offscreenWindow->format();
+ return d->requestedFormat;
+}
+
+/*!
+ Returns the size of the offscreen surface.
+*/
+QSize QOffscreenSurface::size() const
+{
+ Q_D(const QOffscreenSurface);
+ return d->size;
+}
+
+/*!
+ Returns the screen to which the offscreen surface is connected.
+
+ \sa setScreen()
+*/
+QScreen *QOffscreenSurface::screen() const
+{
+ Q_D(const QOffscreenSurface);
+ return d->screen;
+}
+
+/*!
+ Sets the screen to which the offscreen surface is connected.
+
+ If the offscreen surface has been created, it will be recreated on the \a newScreen.
+
+ \sa screen()
+*/
+void QOffscreenSurface::setScreen(QScreen *newScreen)
+{
+ Q_D(QOffscreenSurface);
+ if (!newScreen)
+ newScreen = QGuiApplication::primaryScreen();
+ if (newScreen != d->screen) {
+ const bool wasCreated = d->platformOffscreenSurface != 0 || d->offscreenWindow != 0;
+ if (wasCreated)
+ destroy();
+ if (d->screen)
+ disconnect(d->screen, SIGNAL(destroyed(QObject*)), this, SLOT(screenDestroyed(QObject*)));
+ d->screen = newScreen;
+ if (newScreen) {
+ connect(d->screen, SIGNAL(destroyed(QObject*)), this, SLOT(screenDestroyed(QObject*)));
+ if (wasCreated)
+ create();
+ }
+ emit screenChanged(newScreen);
+ }
+}
+
+/*!
+ Called when the offscreen surface's screen is destroyed.
+
+ \internal
+*/
+void QOffscreenSurface::screenDestroyed(QObject *object)
+{
+ Q_D(QOffscreenSurface);
+ if (object == static_cast<QObject *>(d->screen))
+ setScreen(0);
+}
+
+/*!
+ \fn QOffscreenSurface::screenChanged(QScreen *screen)
+
+ This signal is emitted when an offscreen surface's \a screen changes, either
+ by being set explicitly with setScreen(), or automatically when
+ the window's screen is removed.
+*/
+
+/*!
+ Returns the platform offscreen surface corresponding to the offscreen surface.
+
+ \internal
+*/
+QPlatformOffscreenSurface *QOffscreenSurface::handle() const
+{
+ Q_D(const QOffscreenSurface);
+ return d->platformOffscreenSurface;
+}
+
+/*!
+ Returns the platform surface corresponding to the offscreen surface.
+
+ \internal
+*/
+QPlatformSurface *QOffscreenSurface::surfaceHandle() const
+{
+ Q_D(const QOffscreenSurface);
+ if (d->offscreenWindow)
+ return d->offscreenWindow->handle();
+
+ return d->platformOffscreenSurface;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/kernel/qoffscreensurface.h b/src/gui/kernel/qoffscreensurface.h
new file mode 100644
index 0000000000..a1b46f9b88
--- /dev/null
+++ b/src/gui/kernel/qoffscreensurface.h
@@ -0,0 +1,98 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QOFFSCREENSURFACE_H
+#define QOFFSCREENSURFACE_H
+
+#include <QtCore/QObject>
+#include <QtGui/qsurface.h>
+
+QT_BEGIN_NAMESPACE
+
+class QOffscreenSurfacePrivate;
+
+class QScreen;
+class QPlatformOffscreenSurface;
+
+class Q_GUI_EXPORT QOffscreenSurface : public QObject, public QSurface
+{
+ Q_OBJECT
+ Q_DECLARE_PRIVATE(QOffscreenSurface)
+
+public:
+
+ explicit QOffscreenSurface(QScreen *screen = 0);
+ virtual ~QOffscreenSurface();
+
+ SurfaceType surfaceType() const;
+
+ void create();
+ void destroy();
+
+ bool isValid() const;
+
+ void setFormat(const QSurfaceFormat &format);
+ QSurfaceFormat format() const;
+ QSurfaceFormat requestedFormat() const;
+
+ QSize size() const;
+
+ QScreen *screen() const;
+ void setScreen(QScreen *screen);
+
+ QPlatformOffscreenSurface *handle() const;
+
+Q_SIGNALS:
+ void screenChanged(QScreen *screen);
+
+private Q_SLOTS:
+ void screenDestroyed(QObject *screen);
+
+private:
+
+ QPlatformSurface *surfaceHandle() const;
+
+ Q_DISABLE_COPY(QOffscreenSurface)
+};
+
+QT_END_NAMESPACE
+
+#endif // QOFFSCREENSURFACE_H
diff --git a/src/gui/kernel/qopenglcontext.cpp b/src/gui/kernel/qopenglcontext.cpp
index 645c13a2ea..483baf0f09 100644
--- a/src/gui/kernel/qopenglcontext.cpp
+++ b/src/gui/kernel/qopenglcontext.cpp
@@ -54,11 +54,163 @@
#include <QtGui/QScreen>
#include <private/qopenglextensions_p.h>
+#include <private/qopenglversionfunctionsfactory_p.h>
#include <QDebug>
QT_BEGIN_NAMESPACE
+class QOpenGLVersionProfilePrivate
+{
+public:
+ QOpenGLVersionProfilePrivate()
+ : majorVersion(0),
+ minorVersion(0),
+ profile(QSurfaceFormat::NoProfile)
+ {}
+
+ int majorVersion;
+ int minorVersion;
+ QSurfaceFormat::OpenGLContextProfile profile;
+};
+
+
+/*!
+ \class QOpenGLVersionProfile
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLVersionProfile class represents the version and if applicable
+ the profile of an OpenGL context.
+
+ An object of this class can be passed to QOpenGLContext::versionFunctions() to
+ request a functions object for a specific version and profile of OpenGL.
+
+ It also contains some helper functions to check if a version supports profiles
+ or is a legacy version.
+*/
+
+/*!
+ Creates a default invalid QOpenGLVersionProfile object.
+*/
+QOpenGLVersionProfile::QOpenGLVersionProfile()
+ : d(new QOpenGLVersionProfilePrivate)
+{
+}
+
+/*!
+ Creates a QOpenGLVersionProfile object initialised with the version and profile
+ from \a format.
+*/
+QOpenGLVersionProfile::QOpenGLVersionProfile(const QSurfaceFormat &format)
+ : d(new QOpenGLVersionProfilePrivate)
+{
+ d->majorVersion = format.majorVersion();
+ d->minorVersion = format.minorVersion();
+ d->profile = format.profile();
+}
+
+/*!
+ Constructs a copy of \a other.
+*/
+QOpenGLVersionProfile::QOpenGLVersionProfile(const QOpenGLVersionProfile &other)
+ : d(new QOpenGLVersionProfilePrivate)
+{
+ *d = *(other.d);
+}
+
+/*!
+ Destroys the QOpenGLVersionProfile object.
+*/
+QOpenGLVersionProfile::~QOpenGLVersionProfile()
+{
+ delete d;
+}
+
+/*!
+ Assigns the version and profile of \a rhs to this QOpenGLVersionProfile object.
+*/
+QOpenGLVersionProfile &QOpenGLVersionProfile::operator=(const QOpenGLVersionProfile &rhs)
+{
+ if (this == &rhs)
+ return *this;
+ *d = *(rhs.d);
+ return *this;
+}
+
+/*!
+ Returns a QPair<int,int> where the components represent the major and minor OpenGL
+ version numbers respectively.
+
+ \sa setVersion()
+*/
+QPair<int, int> QOpenGLVersionProfile::version() const
+{
+ return qMakePair( d->majorVersion, d->minorVersion);
+}
+
+/*!
+ Sets the major and minor version numbers to \a majorVersion and \a minorVersion respectively.
+
+ \sa version()
+*/
+void QOpenGLVersionProfile::setVersion(int majorVersion, int minorVersion)
+{
+ d->majorVersion = majorVersion;
+ d->minorVersion = minorVersion;
+}
+
+/*!
+ Returns the OpenGL profile. Only make sense if profiles are supported by this version.
+
+ \sa setProfile(), supportsProfiles()
+*/
+QSurfaceFormat::OpenGLContextProfile QOpenGLVersionProfile::profile() const
+{
+ return d->profile;
+}
+
+/*!
+ Sets the profile. Only make sense if profiles are supported by this version.
+
+ \sa profile(), supportsProfiles()
+*/
+void QOpenGLVersionProfile::setProfile(QSurfaceFormat::OpenGLContextProfile profile)
+{
+ d->profile = profile;
+}
+
+/*!
+ Returns true if profiles are supported by the OpenGL version returned by version(). Only
+ OpenGL versions >= 3.2 support profiles.
+
+ \sa profile(), version()
+*/
+bool QOpenGLVersionProfile::hasProfiles() const
+{
+ return ( d->majorVersion > 3
+ || (d->majorVersion == 3 && d->minorVersion > 1));
+}
+
+/*!
+ Returns true is the OpenGL version returned by version() contains deprecated functions
+ and does not support profiles i.e. if the OpenGL version is <= 3.1.
+*/
+bool QOpenGLVersionProfile::isLegacyVersion() const
+{
+ return (d->majorVersion < 3 || (d->majorVersion == 3 && d->minorVersion == 0));
+}
+
+/*!
+ Returns true if the version number is valid. Note that for a default constructed
+ QOpenGLVersionProfile object this function will return false.
+
+ \sa setVersion(), version()
+*/
+bool QOpenGLVersionProfile::isValid() const
+{
+ return d->majorVersion > 0 && d->minorVersion >= 0;
+}
+
class QGuiGLThreadContext
{
public:
@@ -367,6 +519,10 @@ void QOpenGLContext::destroy()
d->platformGLContext = 0;
delete d->functions;
d->functions = 0;
+ qDeleteAll(d->versionFunctions);
+ d->versionFunctions.clear();
+ qDeleteAll(d->versionFunctionsBackend);
+ d->versionFunctionsBackend.clear();
}
/*!
@@ -425,6 +581,97 @@ QOpenGLFunctions *QOpenGLContext::functions() const
}
/*!
+ \fn T *QOpenGLContext::versionFunctions() const
+
+ Returns a pointer to an object that provides access to all functions for
+ the version and profile of this context. Before using any of the functions
+ they must be initialized by calling QAbstractOpenGLFunctions::initializeOpenGLFunctions().
+
+ Usually one would use the template version of this function to automatically
+ have the result cast to the correct type.
+
+ \code
+ QOpenGLFunctions_3_3_Core* funcs = 0;
+ funcs = context->versionFunctions<QOpenGLFunctions_3_3_Core>();
+ if (!funcs) {
+ qWarning() << "Could not obtain required OpenGL context version";
+ exit(1);
+ }
+ funcs->initializeOpenGLFunctions(context);
+ \endcode
+
+ It is possible to request a functions object for a different version and profile
+ than that for which the context was created. To do this either use the template
+ version of this function specifying the desired functions object type as the
+ template parameter or by passing in a QOpenGLVersionProfile object as an argument
+ to the non-template function.
+
+ Note that requests for function objects of other versions or profiles can fail and
+ in doing so will return a null pointer. Situations in which creation of the functions
+ object can fail are if the request cannot be satisfied due to asking for functions
+ that are not in the version or profile of this context. For example:
+
+ \list
+ \li Requesting a 3.3 core profile functions object would succeed.
+ \li Requesting a 3.3 compatibility profile functions object would fail. We would fail
+ to resolve the deprecated functions.
+ \li Requesting a 4.3 core profile functions object would fail. We would fail to resolve
+ the new core functions introduced in versions 4.0-4.3.
+ \li Requesting a 3.1 functions object would succeed. There is nothing in 3.1 that is not
+ also in 3.3 core.
+ \endlist
+
+ Note that if creating a functions object via this method that the QOpenGLContext
+ retains ownership of the object. This is to allow the object to be cached and shared.
+*/
+
+/*!
+ Returns a pointer to an object that provides access to all functions for
+ the version of the current context. Before using any of the functions
+ they must be initialized by calling QAbstractOpenGLFunctions::initializeOpenGLFunctions().
+
+ Usually one would use the template version of this function to automatically
+ have the result cast to the correct type.
+
+ \sa T *QOpenGLContext::versionFunctions()
+*/
+QAbstractOpenGLFunctions *QOpenGLContext::versionFunctions(const QOpenGLVersionProfile &versionProfile) const
+{
+ Q_D(const QOpenGLContext);
+ const QSurfaceFormat f = format();
+
+ // Ensure we have a valid version and profile. Default to context's if none specified
+ QOpenGLVersionProfile vp = versionProfile;
+ if (!vp.isValid())
+ vp = QOpenGLVersionProfile(f);
+
+ // Check that context is compatible with requested version
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < vp.version())
+ return 0;
+
+ // If this context only offers core profile functions then we can't create
+ // function objects for legacy or compatibility profile requests
+ if (((vp.hasProfiles() && vp.profile() != QSurfaceFormat::CoreProfile) || vp.isLegacyVersion())
+ && f.profile() == QSurfaceFormat::CoreProfile)
+ return 0;
+
+ // Create object if suitable one not cached
+ QAbstractOpenGLFunctions* funcs = 0;
+ if (!d->versionFunctions.contains(vp)) {
+ funcs = QOpenGLVersionFunctionsFactory::create(vp);
+ if (funcs) {
+ funcs->setOwningContext(this);
+ d->versionFunctions.insert(vp, funcs);
+ }
+ } else {
+ funcs = d->versionFunctions.value(vp);
+ }
+
+ return funcs;
+}
+
+/*!
Returns the set of OpenGL extensions supported by this context.
The context or a sharing context must be current.
@@ -702,6 +949,34 @@ void QOpenGLContext::deleteQGLContext()
}
/*!
+ \internal
+*/
+QOpenGLVersionFunctionsBackend *QOpenGLContext::functionsBackend(const QOpenGLVersionStatus &v) const
+{
+ Q_D(const QOpenGLContext);
+ return d->versionFunctionsBackend.value(v, 0);
+}
+
+/*!
+ \internal
+*/
+void QOpenGLContext::insertFunctionsBackend(const QOpenGLVersionStatus &v,
+ QOpenGLVersionFunctionsBackend *backend)
+{
+ Q_D(QOpenGLContext);
+ d->versionFunctionsBackend.insert(v, backend);
+}
+
+/*!
+ \internal
+*/
+void QOpenGLContext::removeFunctionsBackend(const QOpenGLVersionStatus &v)
+{
+ Q_D(QOpenGLContext);
+ d->versionFunctionsBackend.remove(v);
+}
+
+/*!
\class QOpenGLContextGroup
\since 5.0
\brief The QOpenGLContextGroup class represents a group of contexts sharing
diff --git a/src/gui/kernel/qopenglcontext.h b/src/gui/kernel/qopenglcontext.h
index d6d812a98d..419fd541eb 100644
--- a/src/gui/kernel/qopenglcontext.h
+++ b/src/gui/kernel/qopenglcontext.h
@@ -42,6 +42,8 @@
#ifndef QOPENGLCONTEXT_H
#define QOPENGLCONTEXT_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_OPENGL
#include <QtCore/qnamespace.h>
@@ -58,8 +60,10 @@
#endif
#include <QtGui/qopengl.h>
+#include <QtGui/qopenglversionfunctions.h>
-QT_BEGIN_HEADER
+#include <QtCore/qhash.h>
+#include <QtCore/qpair.h>
QT_BEGIN_NAMESPACE
@@ -71,6 +75,50 @@ class QPlatformOpenGLContext;
class QScreen;
class QSurface;
+class QOpenGLVersionProfilePrivate;
+
+class Q_GUI_EXPORT QOpenGLVersionProfile
+{
+public:
+ QOpenGLVersionProfile();
+ explicit QOpenGLVersionProfile(const QSurfaceFormat &format);
+ QOpenGLVersionProfile(const QOpenGLVersionProfile &other);
+ ~QOpenGLVersionProfile();
+
+ QOpenGLVersionProfile &operator=(const QOpenGLVersionProfile &rhs);
+
+ QPair<int, int> version() const;
+ void setVersion(int majorVersion, int minorVersion);
+
+ QSurfaceFormat::OpenGLContextProfile profile() const;
+ void setProfile(QSurfaceFormat::OpenGLContextProfile profile);
+
+ bool hasProfiles() const;
+ bool isLegacyVersion() const;
+ bool isValid() const;
+
+private:
+ QOpenGLVersionProfilePrivate* d;
+};
+
+inline uint qHash(const QOpenGLVersionProfile &v, uint seed)
+{
+ return qHash(static_cast<int>(v.profile() * 1000)
+ + v.version().first * 100 + v.version().second * 10, seed);
+}
+
+inline bool operator==(const QOpenGLVersionProfile &lhs, const QOpenGLVersionProfile &rhs)
+{
+ if (lhs.profile() != rhs.profile())
+ return false;
+ return lhs.version() == rhs.version();
+}
+
+inline bool operator!=(const QOpenGLVersionProfile &lhs, const QOpenGLVersionProfile &rhs)
+{
+ return !operator==(lhs, rhs);
+}
+
class Q_GUI_EXPORT QOpenGLContextGroup : public QObject
{
Q_OBJECT
@@ -129,6 +177,15 @@ public:
QOpenGLFunctions *functions() const;
+ QAbstractOpenGLFunctions *versionFunctions(const QOpenGLVersionProfile &versionProfile = QOpenGLVersionProfile()) const;
+
+ template<class TYPE>
+ TYPE *versionFunctions() const
+ {
+ QOpenGLVersionProfile v = TYPE::versionProfile();
+ return static_cast<TYPE*>(versionFunctions(v));
+ }
+
QSet<QByteArray> extensions() const;
bool hasExtension(const QByteArray &extension) const;
@@ -149,18 +206,22 @@ private:
friend class QOpenGL2PaintEngineExPrivate;
friend class QSGDistanceFieldGlyphCache;
friend class QWidgetPrivate;
+ friend class QAbstractOpenGLFunctionsPrivate;
void *qGLContextHandle() const;
void setQGLContextHandle(void *handle,void (*qGLContextDeleteFunction)(void *));
void deleteQGLContext();
+ QOpenGLVersionFunctionsBackend* functionsBackend(const QOpenGLVersionStatus &v) const;
+ void insertFunctionsBackend(const QOpenGLVersionStatus &v,
+ QOpenGLVersionFunctionsBackend *backend);
+ void removeFunctionsBackend(const QOpenGLVersionStatus &v);
+
void destroy();
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_OPENGL
#endif // QGUIGLCONTEXT_H
diff --git a/src/gui/kernel/qopenglcontext_p.h b/src/gui/kernel/qopenglcontext_p.h
index fb81412b2b..8a36df3e7c 100644
--- a/src/gui/kernel/qopenglcontext_p.h
+++ b/src/gui/kernel/qopenglcontext_p.h
@@ -64,8 +64,6 @@
#include <QtCore/QHash>
#include <QtCore/QSet>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -215,6 +213,9 @@ public:
//QWidgetPrivate::deleteTLSysExtra()
}
+ mutable QHash<QOpenGLVersionProfile, QAbstractOpenGLFunctions *> versionFunctions;
+ mutable QHash<QOpenGLVersionStatus, QOpenGLVersionFunctionsBackend *> versionFunctionsBackend;
+
void *qGLContextHandle;
void (*qGLContextDeleteFunction)(void *handle);
@@ -259,7 +260,5 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_OPENGL
#endif // QOPENGLCONTEXT_P_H
diff --git a/src/gui/kernel/qpalette.h b/src/gui/kernel/qpalette.h
index 9ea0830442..2248f6727e 100644
--- a/src/gui/kernel/qpalette.h
+++ b/src/gui/kernel/qpalette.h
@@ -46,8 +46,6 @@
#include <QtGui/qcolor.h>
#include <QtGui/qbrush.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -210,6 +208,4 @@ Q_GUI_EXPORT QDebug operator<<(QDebug, const QPalette &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPALETTE_H
diff --git a/src/gui/kernel/qplatformclipboard.h b/src/gui/kernel/qplatformclipboard.h
index a925b16e9e..3ffc020e8d 100644
--- a/src/gui/kernel/qplatformclipboard.h
+++ b/src/gui/kernel/qplatformclipboard.h
@@ -57,8 +57,6 @@
#include <QtGui/QClipboard>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -76,8 +74,6 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_CLIPBOARD
#endif //QPLATFORMCLIPBOARD_H
diff --git a/src/gui/kernel/qplatformcursor.cpp b/src/gui/kernel/qplatformcursor.cpp
index 16a59f5d07..c2f510b496 100644
--- a/src/gui/kernel/qplatformcursor.cpp
+++ b/src/gui/kernel/qplatformcursor.cpp
@@ -95,6 +95,10 @@ QList<QPlatformCursor *> QPlatformCursorPrivate::getInstances()
\a windowCursor is a pointer to the QCursor that should be displayed.
+ To unset the cursor of \a window, 0 is passed. This means \a window does not have
+ a cursor set and the cursor of a the first parent window which has a cursor explicitly
+ set or the system default cursor should take effect.
+
\a window is a pointer to the window currently displayed at QCursor::pos(). Note
that this may be 0 if the current position is not occupied by a displayed widget.
diff --git a/src/gui/kernel/qplatformcursor.h b/src/gui/kernel/qplatformcursor.h
index d624a068f1..011209aa3a 100644
--- a/src/gui/kernel/qplatformcursor.h
+++ b/src/gui/kernel/qplatformcursor.h
@@ -58,8 +58,6 @@
#include <qpa/qplatformscreen.h>
#include <QtGui/QCursor>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -106,6 +104,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMCURSOR_H
diff --git a/src/gui/kernel/qplatformdialoghelper.h b/src/gui/kernel/qplatformdialoghelper.h
index fe3c5d2b99..ecc00ed8c6 100644
--- a/src/gui/kernel/qplatformdialoghelper.h
+++ b/src/gui/kernel/qplatformdialoghelper.h
@@ -59,8 +59,6 @@
#include <QtCore/QDir>
#include <QtGui/QRgb>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -319,6 +317,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMDIALOGHELPER_H
diff --git a/src/gui/kernel/qplatformdrag.h b/src/gui/kernel/qplatformdrag.h
index 61ff2dddf6..59f9899f23 100644
--- a/src/gui/kernel/qplatformdrag.h
+++ b/src/gui/kernel/qplatformdrag.h
@@ -54,8 +54,6 @@
#include <QtCore/qglobal.h>
#include <QtGui/QPixmap>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#ifndef QT_NO_DRAGANDDROP
@@ -118,6 +116,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/kernel/qplatforminputcontext.h b/src/gui/kernel/qplatforminputcontext.h
index 2efe9486ca..0e4121eed4 100644
--- a/src/gui/kernel/qplatforminputcontext.h
+++ b/src/gui/kernel/qplatforminputcontext.h
@@ -53,8 +53,6 @@
#include <QtGui/qinputmethod.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QPlatformInputContextPrivate;
@@ -102,6 +100,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMINPUTCONTEXT_H
diff --git a/src/gui/kernel/qplatforminputcontext_p.h b/src/gui/kernel/qplatforminputcontext_p.h
index f55acbd79f..29d6e45269 100644
--- a/src/gui/kernel/qplatforminputcontext_p.h
+++ b/src/gui/kernel/qplatforminputcontext_p.h
@@ -55,8 +55,6 @@
#include <private/qobject_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QPlatformInputContextPrivate: public QObjectPrivate
@@ -73,6 +71,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/kernel/qplatforminputcontextfactory.cpp b/src/gui/kernel/qplatforminputcontextfactory.cpp
index 81368a0f25..ee80a70939 100644
--- a/src/gui/kernel/qplatforminputcontextfactory.cpp
+++ b/src/gui/kernel/qplatforminputcontextfactory.cpp
@@ -82,8 +82,8 @@ QPlatformInputContext *QPlatformInputContextFactory::create()
QString icString = QString::fromLatin1(qgetenv("QT_IM_MODULE"));
- if (icString == QStringLiteral("none"))
- return 0;
+ if (icString == QLatin1String("none"))
+ icString = QStringLiteral("compose");
ic = create(icString);
if (ic && ic->isValid())
diff --git a/src/gui/kernel/qplatforminputcontextfactory_p.h b/src/gui/kernel/qplatforminputcontextfactory_p.h
index 2e82f7c4d5..2177d7965d 100644
--- a/src/gui/kernel/qplatforminputcontextfactory_p.h
+++ b/src/gui/kernel/qplatforminputcontextfactory_p.h
@@ -55,8 +55,6 @@
#include <QtCore/qstringlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -72,7 +70,5 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMINPUTCONTEXTFACTORY_H
diff --git a/src/gui/kernel/qplatforminputcontextplugin_p.h b/src/gui/kernel/qplatforminputcontextplugin_p.h
index ac97df15a3..ff79bb94b9 100644
--- a/src/gui/kernel/qplatforminputcontextplugin_p.h
+++ b/src/gui/kernel/qplatforminputcontextplugin_p.h
@@ -56,8 +56,6 @@
#include <QtCore/qplugin.h>
#include <QtCore/qfactoryinterface.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -77,6 +75,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMINPUTCONTEXTPLUGIN_H
diff --git a/src/gui/kernel/qplatformintegration.cpp b/src/gui/kernel/qplatformintegration.cpp
index 980e45742e..70de75072c 100644
--- a/src/gui/kernel/qplatformintegration.cpp
+++ b/src/gui/kernel/qplatformintegration.cpp
@@ -199,6 +199,17 @@ QPlatformServices *QPlatformIntegration::services() const
\value MultipleWindows The platform supports multiple QWindows, i.e. does some kind
of compositing either client or server side. Some platforms might only support a
single fullscreen window.
+
+ \value ApplicationState The platform handles the application state explicitly.
+ This means that QEvent::ApplicationActivate and QEvent::ApplicationDeativate
+ will not be posted automatically. Instead, the platform must handle application
+ state explicitly by using QWindowSystemInterface::handleApplicationStateChanged().
+ If not set, application state will follow window activation, which is the normal
+ behavior for desktop platforms.
+
+ \value ForeignWindows The platform allows creating QWindows which represent
+ native windows created by other processes or anyway created by using native
+ libraries.
*/
@@ -360,4 +371,15 @@ class QPlatformTheme *QPlatformIntegration::createPlatformTheme(const QString &n
return new QPlatformTheme;
}
+/*!
+ Factory function for QOffscreenSurface. An offscreen surface will typically be implemented with a
+ pixel buffer (pbuffer). If the platform doesn't support offscreen surfaces, an invisible window
+ will be used by QOffscreenSurface instead.
+*/
+QPlatformOffscreenSurface *QPlatformIntegration::createPlatformOffscreenSurface(QOffscreenSurface *surface) const
+{
+ Q_UNUSED(surface)
+ return 0;
+}
+
QT_END_NAMESPACE
diff --git a/src/gui/kernel/qplatformintegration.h b/src/gui/kernel/qplatformintegration.h
index ee796bf323..ddee6f05c8 100644
--- a/src/gui/kernel/qplatformintegration.h
+++ b/src/gui/kernel/qplatformintegration.h
@@ -55,8 +55,6 @@
#include <qpa/qplatformscreen.h>
#include <QtGui/qsurfaceformat.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -77,6 +75,8 @@ class QPlatformDialogHelper;
class QPlatformSharedGraphicsCache;
class QPlatformServices;
class QKeyEvent;
+class QPlatformOffscreenSurface;
+class QOffscreenSurface;
class Q_GUI_EXPORT QPlatformIntegration
{
@@ -88,7 +88,9 @@ public:
SharedGraphicsCache,
BufferQueueingOpenGL,
WindowMasks,
- MultipleWindows
+ MultipleWindows,
+ ApplicationState,
+ ForeignWindows
};
virtual ~QPlatformIntegration() { }
@@ -148,12 +150,12 @@ public:
virtual QStringList themeNames() const;
virtual QPlatformTheme *createPlatformTheme(const QString &name) const;
+ virtual QPlatformOffscreenSurface *createPlatformOffscreenSurface(QOffscreenSurface *surface) const;
+
protected:
void screenAdded(QPlatformScreen *screen);
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMINTEGRATION_H
diff --git a/src/gui/kernel/qplatformintegrationfactory_p.h b/src/gui/kernel/qplatformintegrationfactory_p.h
index 859e6f9c4d..fb3ba55316 100644
--- a/src/gui/kernel/qplatformintegrationfactory_p.h
+++ b/src/gui/kernel/qplatformintegrationfactory_p.h
@@ -55,8 +55,6 @@
#include <QtCore/qstringlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -71,7 +69,5 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMINTEGRATIONFACTORY_H
diff --git a/src/gui/kernel/qplatformintegrationplugin.h b/src/gui/kernel/qplatformintegrationplugin.h
index 4de0d3edc0..434366f0b0 100644
--- a/src/gui/kernel/qplatformintegrationplugin.h
+++ b/src/gui/kernel/qplatformintegrationplugin.h
@@ -54,8 +54,6 @@
#include <QtCore/qplugin.h>
#include <QtCore/qfactoryinterface.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -75,6 +73,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMINTEGRATIONPLUGIN_H
diff --git a/src/gui/kernel/qplatformmenu.h b/src/gui/kernel/qplatformmenu.h
index b02998940b..3485cc58dd 100644
--- a/src/gui/kernel/qplatformmenu.h
+++ b/src/gui/kernel/qplatformmenu.h
@@ -57,8 +57,6 @@
#include <QtGui/QKeySequence>
#include <QtGui/QIcon>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QPlatformMenu;
@@ -80,6 +78,7 @@ public:
virtual void setIsSeparator(bool isSeparator) = 0;
virtual void setFont(const QFont &font) = 0;
virtual void setRole(MenuRole role) = 0;
+ virtual void setCheckable(bool checkable) = 0;
virtual void setChecked(bool isChecked) = 0;
virtual void setShortcut(const QKeySequence& shortcut) = 0;
virtual void setEnabled(bool enabled) = 0;
@@ -101,8 +100,19 @@ public:
virtual quintptr tag()const = 0;
virtual void setText(const QString &text) = 0;
+ virtual void setIcon(const QIcon &icon) = 0;
virtual void setEnabled(bool enabled) = 0;
virtual void setVisible(bool visible) = 0;
+ virtual void setMinimumWidth(int width) { Q_UNUSED(width); }
+ virtual void setFont(const QFont &font) { Q_UNUSED(font); }
+
+ virtual void showPopup(const QWindow *parentWindow, QPoint pos, const QPlatformMenuItem *item)
+ {
+ Q_UNUSED(parentWindow);
+ Q_UNUSED(pos);
+ Q_UNUSED(item);
+ setVisible(true);
+ }
virtual QPlatformMenuItem *menuItemAt(int position) const = 0;
virtual QPlatformMenuItem *menuItemForTag(quintptr tag) const = 0;
@@ -125,7 +135,5 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/kernel/qplatformnativeinterface.h b/src/gui/kernel/qplatformnativeinterface.h
index fd892c1e75..eaa24a9e55 100644
--- a/src/gui/kernel/qplatformnativeinterface.h
+++ b/src/gui/kernel/qplatformnativeinterface.h
@@ -55,8 +55,6 @@
#include <QtCore/QObject>
#include <QtCore/QVariant>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -98,6 +96,4 @@ Q_SIGNALS:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMNATIVEINTERFACE_H
diff --git a/src/gui/kernel/qplatformoffscreensurface.cpp b/src/gui/kernel/qplatformoffscreensurface.cpp
new file mode 100644
index 0000000000..dd354f465e
--- /dev/null
+++ b/src/gui/kernel/qplatformoffscreensurface.cpp
@@ -0,0 +1,93 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qplatformoffscreensurface.h"
+
+#include "qoffscreensurface.h"
+#include "qscreen.h"
+
+QT_BEGIN_NAMESPACE
+
+class QPlatformOffscreenSurfacePrivate
+{
+public:
+};
+
+QPlatformOffscreenSurface::QPlatformOffscreenSurface(QOffscreenSurface *offscreenSurface)
+ : QPlatformSurface(offscreenSurface)
+ , d_ptr(new QPlatformOffscreenSurfacePrivate)
+{
+}
+
+QPlatformOffscreenSurface::~QPlatformOffscreenSurface()
+{
+}
+
+QOffscreenSurface *QPlatformOffscreenSurface::offscreenSurface() const
+{
+ return static_cast<QOffscreenSurface*>(m_surface);
+}
+
+/*!
+ Returns the platform screen handle corresponding to this QPlatformOffscreenSurface.
+*/
+QPlatformScreen *QPlatformOffscreenSurface::screen() const
+{
+ return offscreenSurface()->screen()->handle();
+}
+
+/*!
+ Returns the actual surface format of the offscreen surface.
+*/
+QSurfaceFormat QPlatformOffscreenSurface::format() const
+{
+ return QSurfaceFormat();
+}
+
+/*!
+ Returns \c true if the platform offscreen surface has been allocated.
+*/
+bool QPlatformOffscreenSurface::isValid() const
+{
+ return false;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/kernel/qplatformoffscreensurface.h b/src/gui/kernel/qplatformoffscreensurface.h
new file mode 100644
index 0000000000..099d8ee94a
--- /dev/null
+++ b/src/gui/kernel/qplatformoffscreensurface.h
@@ -0,0 +1,85 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QPLATFORMOFFSCREENSURFACE_H
+#define QPLATFORMOFFSCREENSURFACE_H
+
+//
+// W A R N I N G
+// -------------
+//
+// This file is part of the QPA API and is not meant to be used
+// in applications. Usage of this API may make your code
+// source and binary incompatible with future versions of Qt.
+//
+
+#include "qplatformsurface.h"
+#include <QtCore/qscopedpointer.h>
+
+QT_BEGIN_NAMESPACE
+
+class QOffscreenSurface;
+class QPlatformScreen;
+class QPlatformOffscreenSurfacePrivate;
+
+class Q_GUI_EXPORT QPlatformOffscreenSurface : public QPlatformSurface
+{
+ Q_DECLARE_PRIVATE(QPlatformOffscreenSurface)
+public:
+ explicit QPlatformOffscreenSurface(QOffscreenSurface *offscreenSurface);
+ virtual ~QPlatformOffscreenSurface();
+
+ QOffscreenSurface *offscreenSurface() const;
+
+ QPlatformScreen *screen() const;
+
+ virtual QSurfaceFormat format() const;
+ virtual bool isValid() const;
+
+protected:
+ QScopedPointer<QPlatformOffscreenSurfacePrivate> d_ptr;
+private:
+ Q_DISABLE_COPY(QPlatformOffscreenSurface)
+};
+
+QT_END_NAMESPACE
+
+#endif // QPLATFORMOFFSCREENSURFACE_H
diff --git a/src/gui/kernel/qplatformopenglcontext.h b/src/gui/kernel/qplatformopenglcontext.h
index 6a0c819752..42e4db2f9d 100644
--- a/src/gui/kernel/qplatformopenglcontext.h
+++ b/src/gui/kernel/qplatformopenglcontext.h
@@ -51,15 +51,14 @@
// source and binary incompatible with future versions of Qt.
//
+#include <QtCore/qnamespace.h>
+
#ifndef QT_NO_OPENGL
-#include <QtCore/qnamespace.h>
#include <QtGui/qsurfaceformat.h>
#include <QtGui/qwindow.h>
#include <QtGui/qopengl.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -102,8 +101,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_OPENGL
#endif // QPLATFORMOPENGLCONTEXT_H
diff --git a/src/gui/kernel/qplatformscreen.h b/src/gui/kernel/qplatformscreen.h
index eae9c5a739..085a147e8d 100644
--- a/src/gui/kernel/qplatformscreen.h
+++ b/src/gui/kernel/qplatformscreen.h
@@ -63,8 +63,6 @@
#include <QtGui/qwindowdefs.h>
#include <qpa/qplatformpixmap.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -133,6 +131,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMSCREEN_H
diff --git a/src/gui/kernel/qplatformscreen_p.h b/src/gui/kernel/qplatformscreen_p.h
index 6914a82a06..588496b494 100644
--- a/src/gui/kernel/qplatformscreen_p.h
+++ b/src/gui/kernel/qplatformscreen_p.h
@@ -53,8 +53,6 @@
// We mean it.
//
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QScreen;
@@ -67,6 +65,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMSCREEN_P_H
diff --git a/src/gui/kernel/qplatformscreenpageflipper.h b/src/gui/kernel/qplatformscreenpageflipper.h
index c6eac28564..232e37d24a 100644
--- a/src/gui/kernel/qplatformscreenpageflipper.h
+++ b/src/gui/kernel/qplatformscreenpageflipper.h
@@ -53,8 +53,6 @@
#include <QtCore/QObject>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class Q_GUI_EXPORT QPlatformScreenBuffer {
@@ -91,6 +89,4 @@ Q_SIGNALS:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMSCREENPAGEFLIPPER_H
diff --git a/src/gui/kernel/qplatformservices.h b/src/gui/kernel/qplatformservices.h
index 200298f2ba..609a4a04be 100644
--- a/src/gui/kernel/qplatformservices.h
+++ b/src/gui/kernel/qplatformservices.h
@@ -53,8 +53,6 @@
#include <QtCore/QtGlobal>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QUrl;
@@ -71,6 +69,5 @@ public:
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QPLATFORMSERVICES_H
diff --git a/src/gui/kernel/qplatformsharedgraphicscache.h b/src/gui/kernel/qplatformsharedgraphicscache.h
index 20a551688f..bb2dfe00e5 100644
--- a/src/gui/kernel/qplatformsharedgraphicscache.h
+++ b/src/gui/kernel/qplatformsharedgraphicscache.h
@@ -54,8 +54,6 @@
#include <QtCore/qobject.h>
#include <QtGui/qimage.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class Q_GUI_EXPORT QPlatformSharedGraphicsCache: public QObject
@@ -103,6 +101,4 @@ Q_SIGNALS:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMSHAREDGRAPHICSCACHE_H
diff --git a/src/gui/kernel/qplatformsurface.h b/src/gui/kernel/qplatformsurface.h
index bffb3c5848..b96e494f74 100644
--- a/src/gui/kernel/qplatformsurface.h
+++ b/src/gui/kernel/qplatformsurface.h
@@ -55,8 +55,6 @@
#include <QtGui/qsurface.h>
#include <QtGui/qsurfaceformat.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -74,10 +72,9 @@ private:
QSurface *m_surface;
friend class QPlatformWindow;
+ friend class QPlatformOffscreenSurface;
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QPLATFORMSURFACE_H
diff --git a/src/gui/kernel/qplatformtheme.cpp b/src/gui/kernel/qplatformtheme.cpp
index ceb95c51e8..9f5c789a6e 100644
--- a/src/gui/kernel/qplatformtheme.cpp
+++ b/src/gui/kernel/qplatformtheme.cpp
@@ -46,6 +46,7 @@
#include <QtCore/qfileinfo.h>
#include <qpalette.h>
#include <qtextformat.h>
+#include <qiconloader_p.h>
QT_BEGIN_NAMESPACE
@@ -272,4 +273,19 @@ QPlatformSystemTrayIcon *QPlatformTheme::createPlatformSystemTrayIcon() const
}
#endif
+/*!
+ Factory function for the QIconEngine used by QIcon::fromTheme(). By default this
+ function returns a QIconLoaderEngine, but subclasses can reimplement it to
+ provide their own.
+
+ It is especially useful to benefit from some platform specific facilities or
+ optimizations like an inter-process cache in systems mostly built with Qt.
+
+ \since 5.1
+*/
+QIconEngine *QPlatformTheme::createIconEngine(const QString &iconName) const
+{
+ return new QIconLoaderEngine(iconName);
+}
+
QT_END_NAMESPACE
diff --git a/src/gui/kernel/qplatformtheme.h b/src/gui/kernel/qplatformtheme.h
index 3ac2b904d2..0e95321102 100644
--- a/src/gui/kernel/qplatformtheme.h
+++ b/src/gui/kernel/qplatformtheme.h
@@ -53,10 +53,9 @@
#include <QtCore/QtGlobal>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
+class QIconEngine;
class QMenu;
class QMenuBar;
class QPlatformMenuItem;
@@ -272,11 +271,11 @@ public:
virtual QPixmap standardPixmap(StandardPixmap sp, const QSizeF &size) const;
virtual QPixmap fileIconPixmap(const QFileInfo &fileInfo, const QSizeF &size) const;
+ virtual QIconEngine *createIconEngine(const QString &iconName) const;
+
static QVariant defaultThemeHint(ThemeHint hint);
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMTHEME_H
diff --git a/src/gui/kernel/qplatformthemefactory_p.h b/src/gui/kernel/qplatformthemefactory_p.h
index 632aae86ee..ad954f39b6 100644
--- a/src/gui/kernel/qplatformthemefactory_p.h
+++ b/src/gui/kernel/qplatformthemefactory_p.h
@@ -55,8 +55,6 @@
#include <QtCore/qstringlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -71,6 +69,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMTHEMEFACTORY_H
diff --git a/src/gui/kernel/qplatformthemeplugin.h b/src/gui/kernel/qplatformthemeplugin.h
index e3f106753a..cef5fb77b4 100644
--- a/src/gui/kernel/qplatformthemeplugin.h
+++ b/src/gui/kernel/qplatformthemeplugin.h
@@ -54,8 +54,6 @@
#include <QtCore/qplugin.h>
#include <QtCore/qfactoryinterface.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QPlatformTheme;
@@ -74,6 +72,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMTHEMEPLUGIN_H
diff --git a/src/gui/kernel/qplatformwindow.cpp b/src/gui/kernel/qplatformwindow.cpp
index b710701e7f..bfb6ab5a68 100644
--- a/src/gui/kernel/qplatformwindow.cpp
+++ b/src/gui/kernel/qplatformwindow.cpp
@@ -41,11 +41,13 @@
#include "qplatformwindow.h"
#include "qplatformwindow_p.h"
+#include "qplatformscreen.h"
#include <private/qguiapplication_p.h>
#include <qpa/qwindowsysteminterface.h>
#include <QtGui/qwindow.h>
#include <QtGui/qscreen.h>
+#include <private/qwindow_p.h>
QT_BEGIN_NAMESPACE
@@ -197,7 +199,13 @@ bool QPlatformWindow::isEmbedded(const QPlatformWindow *parentWindow) const
*/
QPoint QPlatformWindow::mapToGlobal(const QPoint &pos) const
{
- return pos;
+ const QPlatformWindow *p = this;
+ QPoint result = pos;
+ while (p) {
+ result += p->geometry().topLeft();
+ p = p->parent();
+ }
+ return result;
}
/*!
@@ -209,7 +217,13 @@ QPoint QPlatformWindow::mapToGlobal(const QPoint &pos) const
*/
QPoint QPlatformWindow::mapFromGlobal(const QPoint &pos) const
{
- return pos;
+ const QPlatformWindow *p = this;
+ QPoint result = pos;
+ while (p) {
+ result -= p->geometry().topLeft();
+ p = p->parent();
+ }
+ return result;
}
/*!
@@ -449,6 +463,43 @@ QString QPlatformWindow::formatWindowTitle(const QString &title, const QString &
}
/*!
+ Helper function to get initial geometry on windowing systems which do not
+ do smart positioning and also do not provide a means of centering a
+ transient window w.r.t. its parent. For example this is useful on Windows
+ and MacOS but not X11, because an X11 window manager typically tries to
+ layout new windows to optimize usage of the available desktop space.
+ However if the given window already has geometry which the application has
+ initialized, it takes priority.
+*/
+QRect QPlatformWindow::initialGeometry(const QWindow *w,
+ const QRect &initialGeometry, int defaultWidth, int defaultHeight)
+{
+ QRect rect(initialGeometry);
+ if (rect.isNull()) {
+ QSize minimumSize = w->minimumSize();
+ if (minimumSize.width() > 0 || minimumSize.height() > 0) {
+ rect.setSize(minimumSize);
+ } else {
+ rect.setWidth(defaultWidth);
+ rect.setHeight(defaultHeight);
+ }
+ }
+ if (w->isTopLevel() && qt_window_private(const_cast<QWindow*>(w))->positionAutomatic) {
+ const QWindow *tp = w->transientParent();
+ if (tp) {
+ // A transient window should be centered w.r.t. its transient parent.
+ rect.moveCenter(tp->geometry().center());
+ } else {
+ // Center the window on the screen. (Only applicable on platforms
+ // which do not provide a better way.)
+ QPlatformScreen *scr = QPlatformScreen::platformScreenForWindow(w);
+ rect.moveCenter(scr->availableGeometry().center());
+ }
+ }
+ return rect;
+}
+
+/*!
\class QPlatformWindow
\since 4.8
\internal
diff --git a/src/gui/kernel/qplatformwindow.h b/src/gui/kernel/qplatformwindow.h
index fe62d7b67b..7ade461890 100644
--- a/src/gui/kernel/qplatformwindow.h
+++ b/src/gui/kernel/qplatformwindow.h
@@ -59,8 +59,6 @@
#include <qpa/qplatformopenglcontext.h>
#include <qpa/qplatformsurface.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -130,6 +128,9 @@ public:
virtual void setFrameStrutEventsEnabled(bool enabled);
virtual bool frameStrutEventsEnabled() const;
+ static QRect initialGeometry(const QWindow *w,
+ const QRect &initialGeometry, int defaultWidth, int defaultHeight);
+
protected:
static QString formatWindowTitle(const QString &title, const QString &separator);
@@ -140,5 +141,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
#endif //QPLATFORMWINDOW_H
diff --git a/src/gui/kernel/qplatformwindow_p.h b/src/gui/kernel/qplatformwindow_p.h
index 24e18ca379..ac47afb6f1 100644
--- a/src/gui/kernel/qplatformwindow_p.h
+++ b/src/gui/kernel/qplatformwindow_p.h
@@ -55,8 +55,6 @@
#include <QtCore/qrect.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QPlatformWindowPrivate
@@ -67,6 +65,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMWINDOW_P_H
diff --git a/src/gui/kernel/qscreen.h b/src/gui/kernel/qscreen.h
index 557cd019a3..9fe4379646 100644
--- a/src/gui/kernel/qscreen.h
+++ b/src/gui/kernel/qscreen.h
@@ -52,8 +52,6 @@
#include <QtCore/qnamespace.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -160,7 +158,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSCREEN_H
diff --git a/src/gui/kernel/qscreen_p.h b/src/gui/kernel/qscreen_p.h
index 7b26159c20..3e5feb2932 100644
--- a/src/gui/kernel/qscreen_p.h
+++ b/src/gui/kernel/qscreen_p.h
@@ -58,8 +58,6 @@
#include <QtCore/private/qobject_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QScreenPrivate : public QObjectPrivate
@@ -98,6 +96,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSCREEN_P_H
diff --git a/src/gui/kernel/qsessionmanager.h b/src/gui/kernel/qsessionmanager.h
index 4eac11e403..a1cd8741d2 100644
--- a/src/gui/kernel/qsessionmanager.h
+++ b/src/gui/kernel/qsessionmanager.h
@@ -49,8 +49,6 @@
#ifndef QT_NO_SESSIONMANAGER
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -101,8 +99,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_SESSIONMANAGER
#endif // QSESSIONMANAGER_H
diff --git a/src/gui/kernel/qshortcutmap.cpp b/src/gui/kernel/qshortcutmap.cpp
index 489242464b..cd822090e2 100644
--- a/src/gui/kernel/qshortcutmap.cpp
+++ b/src/gui/kernel/qshortcutmap.cpp
@@ -317,7 +317,7 @@ QKeySequence::SequenceMatch QShortcutMap::state()
/*! \internal
Uses ShortcutOverride event to see if any widgets want to override
the event. If not, uses nextState(QKeyEvent) to check for a grabbed
- Shortcut, and dispatchEvent() is found an identical.
+ Shortcut, and dispatchEvent() is found and identical.
\sa nextState, dispatchEvent
*/
bool QShortcutMap::tryShortcutEvent(QObject *o, QKeyEvent *e)
diff --git a/src/gui/kernel/qstylehints.h b/src/gui/kernel/qstylehints.h
index c9c8185b9a..7a447aae67 100644
--- a/src/gui/kernel/qstylehints.h
+++ b/src/gui/kernel/qstylehints.h
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -74,6 +72,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/kernel/qsurface.cpp b/src/gui/kernel/qsurface.cpp
index 97b8220124..a943639d5f 100644
--- a/src/gui/kernel/qsurface.cpp
+++ b/src/gui/kernel/qsurface.cpp
@@ -61,6 +61,7 @@ QT_BEGIN_NAMESPACE
The SurfaceClass enum describes the actual subclass of the surface.
\value Window The surface is an instance of QWindow.
+ \value Offscreen The surface is an instance of QOffscreenSurface.
*/
diff --git a/src/gui/kernel/qsurface.h b/src/gui/kernel/qsurface.h
index 36d85342c5..8dbc230c10 100644
--- a/src/gui/kernel/qsurface.h
+++ b/src/gui/kernel/qsurface.h
@@ -47,8 +47,6 @@
#include <QtCore/qsize.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -60,7 +58,8 @@ class Q_GUI_EXPORT QSurface
{
public:
enum SurfaceClass {
- Window
+ Window,
+ Offscreen
};
enum SurfaceType {
@@ -89,6 +88,4 @@ protected:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QSURFACE_H
diff --git a/src/gui/kernel/qsurfaceformat.cpp b/src/gui/kernel/qsurfaceformat.cpp
index 2c26a172a4..25b603bb9c 100644
--- a/src/gui/kernel/qsurfaceformat.cpp
+++ b/src/gui/kernel/qsurfaceformat.cpp
@@ -583,6 +583,30 @@ int QSurfaceFormat::minorVersion() const
}
/*!
+ Returns a QPair<int, int> representing the OpenGL version.
+
+ Useful for version checks, for example format.version() >= qMakePair(3, 2)
+*/
+QPair<int, int> QSurfaceFormat::version() const
+{
+ return qMakePair(d->major, d->minor);
+}
+
+/*!
+ Sets the desired \a major and \a minor OpenGL versions.
+
+ The default version is 2.0.
+*/
+void QSurfaceFormat::setVersion(int major, int minor)
+{
+ if (d->minor != minor || d->major != major) {
+ detach();
+ d->minor = minor;
+ d->major = major;
+ }
+}
+
+/*!
Returns true if all the options of the two QSurfaceFormat objects
\a a and \a b are equal.
diff --git a/src/gui/kernel/qsurfaceformat.h b/src/gui/kernel/qsurfaceformat.h
index 8ab89225de..7c3c846df3 100644
--- a/src/gui/kernel/qsurfaceformat.h
+++ b/src/gui/kernel/qsurfaceformat.h
@@ -42,8 +42,7 @@
#define QSURFACEFORMAT_H
#include <QtCore/qglobal.h>
-
-QT_BEGIN_HEADER
+#include <QtCore/qpair.h>
QT_BEGIN_NAMESPACE
@@ -122,6 +121,9 @@ public:
void setMinorVersion(int minorVersion);
int minorVersion() const;
+ QPair<int, int> version() const;
+ void setVersion(int major, int minor);
+
bool stereo() const;
void setStereo(bool enable);
@@ -156,6 +158,4 @@ inline bool QSurfaceFormat::stereo() const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QSURFACEFORMAT_H
diff --git a/src/gui/kernel/qtouchdevice.h b/src/gui/kernel/qtouchdevice.h
index d9892bfbd3..312bdce3e6 100644
--- a/src/gui/kernel/qtouchdevice.h
+++ b/src/gui/kernel/qtouchdevice.h
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -90,6 +88,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QTouchDevice::Capabilities)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTOUCHDEVICE_H
diff --git a/src/gui/kernel/qtouchdevice_p.h b/src/gui/kernel/qtouchdevice_p.h
index a358d77e92..435f8a5c37 100644
--- a/src/gui/kernel/qtouchdevice_p.h
+++ b/src/gui/kernel/qtouchdevice_p.h
@@ -56,8 +56,6 @@
#include <QtCore/qobject.h>
#include <QtGui/qtouchdevice.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -79,6 +77,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTOUCHDEVICE_P_H
diff --git a/src/gui/kernel/qwindow.cpp b/src/gui/kernel/qwindow.cpp
index 2fcad5706f..2307df37ac 100644
--- a/src/gui/kernel/qwindow.cpp
+++ b/src/gui/kernel/qwindow.cpp
@@ -115,6 +115,9 @@ QT_BEGIN_NAMESPACE
windowing systems that do not make this information visible to the
application, isExposed() will simply return the same value as isVisible().
+ QWindow::Visibility queried through visibility() is a convenience API
+ combining the functions of visible() and windowState().
+
\section1 Rendering
There are two Qt APIs that can be used to render content into a window,
@@ -126,6 +129,18 @@ QT_BEGIN_NAMESPACE
and can keep rendering until it isExposed() returns false. To find out when
isExposed() changes, reimplement exposeEvent(). The window will always get
a resize event before the first expose event.
+
+ \section1 Initial geometry
+
+ If the window's width and height are left uninitialized, the window will
+ get a reasonable default geometry from the platform window. If the position
+ is left uninitialized, then the platform window will allow the windowing
+ system to position the window. For example on X11, the window manager
+ usually does some kind of smart positioning to try to avoid having new
+ windows completely obscure existing windows. However setGeometry()
+ initializes both the position and the size, so if you want a fixed size but
+ an automatic position, you should call resize() or setWidth() and
+ setHeight() instead.
*/
/*!
@@ -216,6 +231,120 @@ QWindow::~QWindow()
}
/*!
+ \enum QWindow::Visibility
+ \since 5.1
+
+ This enum describes what part of the screen the window occupies or should
+ occupy.
+
+ \value Windowed The window occupies part of the screen, but not necessarily
+ the entire screen. This state will occur only on windowing systems which
+ support showing multiple windows simultaneously. In this state it is
+ possible for the user to move and resize the window manually, if
+ WindowFlags permit it and if it is supported by the windowing system.
+
+ \value Minimized The window is reduced to an entry or icon on the task bar,
+ dock, task list or desktop, depending on how the windowing system handles
+ minimized windows.
+
+ \value Maximized The window occupies one entire screen, and the titlebar is
+ still visible. On most windowing systems this is the state achieved by
+ clicking the maximize button on the toolbar.
+
+ \value FullScreen The window occupies one entire screen, is not resizable,
+ and there is no titlebar. On some platforms which do not support showing
+ multiple simultaneous windows, this can be the usual visibility when the
+ window is not hidden.
+
+ \value AutomaticVisibility This means to give the window a default visible
+ state, which might be fullscreen or windowed depending on the platform.
+ It can be given as a parameter to setVisibility but will never be
+ read back from the visibility accessor.
+
+ \value Hidden The window is not visible in any way, however it may remember
+ a latent visibility which can be restored by setting AutomaticVisibility.
+*/
+
+/*!
+ \property QWindow::visibility
+ \brief the screen-occupation state of the window
+ \since 5.1
+
+ Visibility is whether the window should appear in the windowing system as
+ normal, minimized, maximized, fullscreen or hidden.
+
+ To set the visibility to AutomaticVisibility means to give the window
+ a default visible state, which might be fullscreen or windowed depending on
+ the platform.
+ When reading the visibility property you will always get the actual state,
+ never AutomaticVisibility.
+*/
+QWindow::Visibility QWindow::visibility() const
+{
+ Q_D(const QWindow);
+ return d->visibility;
+}
+
+void QWindow::setVisibility(Visibility v)
+{
+ switch (v) {
+ case Hidden:
+ hide();
+ break;
+ case AutomaticVisibility:
+ show();
+ break;
+ case Windowed:
+ showNormal();
+ break;
+ case Minimized:
+ showMinimized();
+ break;
+ case Maximized:
+ showMaximized();
+ break;
+ case FullScreen:
+ showFullScreen();
+ break;
+ default:
+ Q_ASSERT(false);
+ break;
+ }
+}
+
+void QWindowPrivate::updateVisibility()
+{
+ Q_Q(QWindow);
+
+ QWindow::Visibility old = visibility;
+
+ if (visible) {
+ switch (windowState) {
+ case Qt::WindowMinimized:
+ visibility = QWindow::Minimized;
+ break;
+ case Qt::WindowMaximized:
+ visibility = QWindow::Maximized;
+ break;
+ case Qt::WindowFullScreen:
+ visibility = QWindow::FullScreen;
+ break;
+ case Qt::WindowNoState:
+ visibility = QWindow::Windowed;
+ break;
+ default:
+ Q_ASSERT(false);
+ break;
+ }
+ } else {
+ visibility = QWindow::Hidden;
+ }
+
+ if (visibility != old)
+ emit q->visibilityChanged(visibility);
+}
+
+/*!
Sets the \a surfaceType of the window.
Specifies whether the window is meant for raster rendering with
@@ -264,6 +393,7 @@ void QWindow::setVisible(bool visible)
return;
d->visible = visible;
emit visibleChanged(visible);
+ d->updateVisibility();
if (!d->platformWindow)
create();
@@ -284,7 +414,7 @@ void QWindow::setVisible(bool visible)
}
#ifndef QT_NO_CURSOR
- if (visible)
+ if (visible && d->hasCursor)
d->applyCursor();
#endif
d->platformWindow->setVisible(visible);
@@ -344,6 +474,10 @@ void QWindow::create()
WId QWindow::winId() const
{
Q_D(const QWindow);
+
+ if (type() == Qt::ForeignWindow)
+ return WId(property("_q_foreignWinId").value<WId>());
+
if(!d->platformWindow)
const_cast<QWindow *>(this)->create();
@@ -369,8 +503,11 @@ QWindow *QWindow::parent() const
the clip of the window, so it will be clipped to the \a parent window.
Setting \a parent to be 0 will make the window become a top level window.
-*/
+ If \a parent is a window created by fromWinId(), then the current window
+ will be embedded inside \a parent, if the platform supports it. Window
+ embedding is currently supported only by the X11 platform plugin.
+*/
void QWindow::setParent(QWindow *parent)
{
Q_D(QWindow);
@@ -642,7 +779,9 @@ void QWindow::lower()
}
/*!
- Sets the window's opacity in the windowing system to \a level.
+ \property QWindow::opacity
+ \brief The opacity of the window in the windowing system.
+ \since 5.1
If the windowing system supports window opacity, this can be used to fade the
window in and out, or to make it semitransparent.
@@ -650,15 +789,58 @@ void QWindow::lower()
A value of 1.0 or above is treated as fully opaque, whereas a value of 0.0 or below
is treated as fully transparent. Values inbetween represent varying levels of
translucency between the two extremes.
+
+ The default value is 1.0.
*/
void QWindow::setOpacity(qreal level)
{
Q_D(QWindow);
- if (level == d->opacity) // #fixme: Add property for 5.1
+ if (level == d->opacity)
return;
d->opacity = level;
- if (d->platformWindow)
+ if (d->platformWindow) {
d->platformWindow->setOpacity(level);
+ emit opacityChanged(level);
+ }
+}
+
+qreal QWindow::opacity() const
+{
+ Q_D(const QWindow);
+ return d->opacity;
+}
+
+/*!
+ Sets the mask of the window.
+
+ The mask is a hint to the windowing system that the application does not
+ want to receive mouse or touch input outside the given \a region.
+
+ The window manager may or may not choose to display any areas of the window
+ not included in the mask, thus it is the application's responsibility to
+ clear to transparent the areas that are not part of the mask.
+
+ Setting the mask before the window has been created has no effect.
+*/
+void QWindow::setMask(const QRegion &region)
+{
+ Q_D(QWindow);
+ if (!d->platformWindow)
+ return;
+ d->platformWindow->setMask(region);
+ d->mask = region;
+}
+
+/*!
+ Returns the mask set on the window.
+
+ The mask is a hint to the windowing system that the application does not
+ want to receive mouse or touch input outside the given region.
+*/
+QRegion QWindow::mask() const
+{
+ Q_D(const QWindow);
+ return d->mask;
}
/*!
@@ -723,6 +905,7 @@ bool QWindow::isActive() const
/*!
\property QWindow::contentOrientation
\brief the orientation of the window's contents
+ \since 5.1
This is a hint to the window manager in case it needs to display
additional content like popups, dialogs, status bars, or similar
@@ -797,6 +980,7 @@ void QWindow::setWindowState(Qt::WindowState state)
d->platformWindow->setWindowState(state);
d->windowState = state;
emit windowStateChanged(d->windowState);
+ d->updateVisibility();
}
/*!
@@ -962,7 +1146,7 @@ void QWindow::setY(int arg)
void QWindow::setWidth(int arg)
{
if (width() != arg)
- setGeometry(QRect(x(), y(), arg, height()));
+ resize(arg, height());
}
/*!
@@ -972,12 +1156,13 @@ void QWindow::setWidth(int arg)
void QWindow::setHeight(int arg)
{
if (height() != arg)
- setGeometry(QRect(x(), y(), width(), arg));
+ resize(width(), arg);
}
/*!
\property QWindow::minimumWidth
\brief the minimum width of the window's geometry
+ \since 5.1
*/
void QWindow::setMinimumWidth(int w)
{
@@ -987,6 +1172,7 @@ void QWindow::setMinimumWidth(int w)
/*!
\property QWindow::minimumHeight
\brief the minimum height of the window's geometry
+ \since 5.1
*/
void QWindow::setMinimumHeight(int h)
{
@@ -1019,6 +1205,7 @@ void QWindow::setMaximumSize(const QSize &size)
/*!
\property QWindow::maximumWidth
\brief the maximum width of the window's geometry
+ \since 5.1
*/
void QWindow::setMaximumWidth(int w)
{
@@ -1028,6 +1215,7 @@ void QWindow::setMaximumWidth(int w)
/*!
\property QWindow::maximumHeight
\brief the maximum height of the window's geometry
+ \since 5.1
*/
void QWindow::setMaximumHeight(int h)
{
@@ -1095,6 +1283,7 @@ void QWindow::setGeometry(int posx, int posy, int w, int h)
void QWindow::setGeometry(const QRect &rect)
{
Q_D(QWindow);
+ d->positionAutomatic = false;
if (rect == geometry())
return;
QRect oldRect = geometry();
@@ -1246,7 +1435,12 @@ void QWindow::resize(const QSize &newSize)
if (d->platformWindow) {
d->platformWindow->setGeometry(QRect(position(), newSize));
} else {
+ const QSize oldSize = d->geometry.size();
d->geometry.setSize(newSize);
+ if (newSize.width() != oldSize.width())
+ emit widthChanged(newSize.width());
+ if (newSize.height() != oldSize.height())
+ emit heightChanged(newSize.height());
}
}
@@ -1415,10 +1609,10 @@ QAccessibleInterface *QWindow::accessibleRoot() const
}
/*!
- \fn QWindow::focusObjectChanged(QObject *focusObject)
+ \fn QWindow::focusObjectChanged(QObject *object)
- This signal is emitted when final receiver of events tied to focus is
- changed to \a focusObject.
+ This signal is emitted when the final receiver of events tied to focus
+ is changed to \a object.
\sa focusObject()
*/
@@ -1436,13 +1630,15 @@ QObject *QWindow::focusObject() const
Shows the window.
This equivalent to calling showFullScreen() or showNormal(), depending
- on whether the platform defaults to windows being fullscreen or not.
+ on whether the platform defaults to windows being fullscreen or not, and
+ whether the window is a popup.
- \sa showFullScreen(), showNormal(), hide(), QStyleHints::showIsFullScreen()
+ \sa showFullScreen(), showNormal(), hide(), QStyleHints::showIsFullScreen(), flags()
*/
void QWindow::show()
{
- if (qApp->styleHints()->showIsFullScreen())
+ bool isPopup = d_func()->windowFlags & Qt::Popup & ~Qt::Window;
+ if (!isPopup && qApp->styleHints()->showIsFullScreen())
showFullScreen();
else
showNormal();
@@ -1711,6 +1907,7 @@ bool QWindow::event(QEvent *ev)
case QEvent::WindowStateChange: {
Q_D(QWindow);
emit windowStateChanged(d->windowState);
+ d->updateVisibility();
break;
}
@@ -1925,6 +2122,34 @@ void QWindowPrivate::maybeQuitOnLastWindowClosed()
}
+/*!
+ Creates a local representation of a window created by another process or by
+ using native libraries below Qt.
+
+ Given the handle \a id to a native window, this method creates a QWindow
+ object which can be used to represent the window when invoking methods like
+ setParent() and setTransientParent().
+ This can be used, on platforms which support it, to embed a window inside a
+ container or to make a window stick on top of a window created by another
+ process.
+
+ \sa setParent()
+ \sa setTransientParent()
+*/
+QWindow *QWindow::fromWinId(WId id)
+{
+ if (!QGuiApplicationPrivate::platformIntegration()->hasCapability(QPlatformIntegration::ForeignWindows)) {
+ qWarning() << "QWindow::fromWinId(): platform plugin does not support foreign windows.";
+ return 0;
+ }
+
+ QWindow *window = new QWindow;
+ window->setFlags(Qt::ForeignWindow);
+ window->setProperty("_q_foreignWinId", QVariant::fromValue(id));
+ window->create();
+ return window;
+}
+
#ifndef QT_NO_CURSOR
/*!
\brief set the cursor shape for this window
@@ -1946,13 +2171,7 @@ void QWindowPrivate::maybeQuitOnLastWindowClosed()
void QWindow::setCursor(const QCursor &cursor)
{
Q_D(QWindow);
- d->cursor = cursor;
- // Only attempt to set cursor and emit signal if there is an actual platform cursor
- if (d->screen->handle()->cursor()) {
- d->applyCursor();
- QEvent event(QEvent::CursorChange);
- QGuiApplication::sendEvent(this, &event);
- }
+ d->setCursor(&cursor);
}
/*!
@@ -1960,7 +2179,8 @@ void QWindow::setCursor(const QCursor &cursor)
*/
void QWindow::unsetCursor()
{
- setCursor(Qt::ArrowCursor);
+ Q_D(QWindow);
+ d->setCursor(0);
}
/*!
@@ -1974,14 +2194,39 @@ QCursor QWindow::cursor() const
return d->cursor;
}
+void QWindowPrivate::setCursor(const QCursor *newCursor)
+{
+
+ Q_Q(QWindow);
+ if (newCursor) {
+ const Qt::CursorShape newShape = newCursor->shape();
+ if (newShape <= Qt::LastCursor && hasCursor && newShape == cursor.shape())
+ return; // Unchanged and no bitmap/custom cursor.
+ cursor = *newCursor;
+ hasCursor = true;
+ } else {
+ if (!hasCursor)
+ return;
+ cursor = QCursor(Qt::ArrowCursor);
+ hasCursor = false;
+ }
+ // Only attempt to set cursor and emit signal if there is an actual platform cursor
+ if (screen->handle()->cursor()) {
+ applyCursor();
+ QEvent event(QEvent::CursorChange);
+ QGuiApplication::sendEvent(q, &event);
+ }
+}
+
void QWindowPrivate::applyCursor()
{
Q_Q(QWindow);
if (platformWindow) {
if (QPlatformCursor *platformCursor = screen->handle()->cursor()) {
- QCursor *oc = QGuiApplication::overrideCursor();
- QCursor c = oc ? *oc : cursor;
- platformCursor->changeCursor(&c, q);
+ QCursor *c = QGuiApplication::overrideCursor();
+ if (!c && hasCursor)
+ c = &cursor;
+ platformCursor->changeCursor(c, q);
}
}
}
diff --git a/src/gui/kernel/qwindow.h b/src/gui/kernel/qwindow.h
index 2e2f12a8ab..1b63e185f8 100644
--- a/src/gui/kernel/qwindow.h
+++ b/src/gui/kernel/qwindow.h
@@ -59,8 +59,6 @@
#include <QtGui/qcursor.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -93,12 +91,18 @@ class Q_GUI_EXPORT QWindow : public QObject, public QSurface
Q_OBJECT
Q_DECLARE_PRIVATE(QWindow)
+ Q_ENUMS(Visibility)
+
// All properties which are declared here are inherited by QQuickWindow and therefore available in QML.
// So please think carefully about what it does to the QML namespace if you add any new ones,
// particularly the possible meanings these names might have in any specializations of Window.
// For example "state" (meaning windowState) is not a good property to declare, because it has
// a different meaning in QQuickItem, and users will tend to assume it is the same for Window.
+ // Any new properties which you add here MUST be versioned and MUST be documented both as
+ // C++ properties in qwindow.cpp AND as QML properties in qquickwindow.cpp.
+ // http://qt-project.org/doc/qt-5.0/qtqml/qtqml-cppintegration-definetypes.html#type-revisions-and-versions
+
Q_PROPERTY(QString title READ title WRITE setTitle)
Q_PROPERTY(Qt::WindowModality modality READ modality WRITE setModality NOTIFY modalityChanged)
Q_PROPERTY(Qt::WindowFlags flags READ flags WRITE setFlags)
@@ -106,14 +110,24 @@ class Q_GUI_EXPORT QWindow : public QObject, public QSurface
Q_PROPERTY(int y READ y WRITE setY NOTIFY yChanged)
Q_PROPERTY(int width READ width WRITE setWidth NOTIFY widthChanged)
Q_PROPERTY(int height READ height WRITE setHeight NOTIFY heightChanged)
- Q_PROPERTY(int minimumWidth READ minimumWidth WRITE setMinimumWidth NOTIFY minimumWidthChanged)
- Q_PROPERTY(int minimumHeight READ minimumHeight WRITE setMinimumHeight NOTIFY minimumHeightChanged)
- Q_PROPERTY(int maximumWidth READ maximumWidth WRITE setMaximumWidth NOTIFY maximumWidthChanged)
- Q_PROPERTY(int maximumHeight READ maximumHeight WRITE setMaximumHeight NOTIFY maximumHeightChanged)
+ Q_PROPERTY(int minimumWidth READ minimumWidth WRITE setMinimumWidth NOTIFY minimumWidthChanged REVISION 1)
+ Q_PROPERTY(int minimumHeight READ minimumHeight WRITE setMinimumHeight NOTIFY minimumHeightChanged REVISION 1)
+ Q_PROPERTY(int maximumWidth READ maximumWidth WRITE setMaximumWidth NOTIFY maximumWidthChanged REVISION 1)
+ Q_PROPERTY(int maximumHeight READ maximumHeight WRITE setMaximumHeight NOTIFY maximumHeightChanged REVISION 1)
Q_PROPERTY(bool visible READ isVisible WRITE setVisible NOTIFY visibleChanged)
- Q_PROPERTY(Qt::ScreenOrientation contentOrientation READ contentOrientation WRITE reportContentOrientationChange NOTIFY contentOrientationChanged)
+ Q_PROPERTY(Visibility visibility READ visibility WRITE setVisibility NOTIFY visibilityChanged REVISION 1)
+ Q_PROPERTY(Qt::ScreenOrientation contentOrientation READ contentOrientation WRITE reportContentOrientationChange NOTIFY contentOrientationChanged REVISION 1)
+ Q_PROPERTY(qreal opacity READ opacity WRITE setOpacity NOTIFY opacityChanged REVISION 1)
public:
+ enum Visibility {
+ Hidden = 0,
+ AutomaticVisibility,
+ Windowed,
+ Minimized,
+ Maximized,
+ FullScreen
+ };
explicit QWindow(QScreen *screen = 0);
explicit QWindow(QWindow *parent);
@@ -124,6 +138,9 @@ public:
bool isVisible() const;
+ Visibility visibility() const;
+ void setVisibility(Visibility v);
+
void create();
WId winId() const;
@@ -148,6 +165,11 @@ public:
QString title() const;
void setOpacity(qreal level);
+ qreal opacity() const;
+
+ void setMask(const QRegion &region);
+ QRegion mask() const;
+
void requestActivate();
bool isActive() const;
@@ -239,6 +261,8 @@ public:
void unsetCursor();
#endif
+ static QWindow *fromWinId(WId id);
+
public Q_SLOTS:
void setVisible(bool visible);
@@ -261,10 +285,10 @@ public Q_SLOTS:
void setWidth(int arg);
void setHeight(int arg);
- void setMinimumWidth(int w);
- void setMinimumHeight(int h);
- void setMaximumWidth(int w);
- void setMaximumHeight(int h);
+ Q_REVISION(1) void setMinimumWidth(int w);
+ Q_REVISION(1) void setMinimumHeight(int h);
+ Q_REVISION(1) void setMaximumWidth(int w);
+ Q_REVISION(1) void setMaximumHeight(int h);
Q_SIGNALS:
void screenChanged(QScreen *screen);
@@ -277,16 +301,19 @@ Q_SIGNALS:
void widthChanged(int arg);
void heightChanged(int arg);
- void minimumWidthChanged(int arg);
- void minimumHeightChanged(int arg);
- void maximumWidthChanged(int arg);
- void maximumHeightChanged(int arg);
+ Q_REVISION(1) void minimumWidthChanged(int arg);
+ Q_REVISION(1) void minimumHeightChanged(int arg);
+ Q_REVISION(1) void maximumWidthChanged(int arg);
+ Q_REVISION(1) void maximumHeightChanged(int arg);
void visibleChanged(bool arg);
- void contentOrientationChanged(Qt::ScreenOrientation orientation);
+ Q_REVISION(1) void visibilityChanged(QWindow::Visibility visibility);
+ Q_REVISION(1) void contentOrientationChanged(Qt::ScreenOrientation orientation);
void focusObjectChanged(QObject *object);
+ Q_REVISION(1) void opacityChanged(qreal opacity);
+
private Q_SLOTS:
void screenDestroyed(QObject *screen);
@@ -330,6 +357,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWINDOW_H
diff --git a/src/gui/kernel/qwindow_p.h b/src/gui/kernel/qwindow_p.h
index 6933c892a0..e32d45acca 100644
--- a/src/gui/kernel/qwindow_p.h
+++ b/src/gui/kernel/qwindow_p.h
@@ -59,8 +59,6 @@
#include <QtCore/private/qobject_p.h>
#include <QtGui/QIcon>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#define QWINDOWSIZE_MAX ((1<<24)-1)
@@ -85,9 +83,11 @@ public:
, visible(false)
, exposed(false)
, windowState(Qt::WindowNoState)
+ , visibility(QWindow::Hidden)
, resizeEventPending(true)
, receivedExpose(false)
, positionPolicy(WindowFrameExclusive)
+ , positionAutomatic(true)
, contentOrientation(Qt::PrimaryOrientation)
, opacity(qreal(1.0))
, minimumSize(0, 0)
@@ -98,6 +98,7 @@ public:
, screen(0)
#ifndef QT_NO_CURSOR
, cursor(Qt::ArrowCursor)
+ , hasCursor(false)
#endif
{
isWindow = true;
@@ -109,6 +110,7 @@ public:
void maybeQuitOnLastWindowClosed();
#ifndef QT_NO_CURSOR
+ void setCursor(const QCursor *c = 0);
void applyCursor();
#endif
@@ -122,6 +124,8 @@ public:
virtual QWindow *eventReceiver() { Q_Q(QWindow); return q; }
+ void updateVisibility();
+
QWindow::SurfaceType surfaceType;
Qt::WindowFlags windowFlags;
QWindow *parentWindow;
@@ -134,11 +138,14 @@ public:
QIcon windowIcon;
QRect geometry;
Qt::WindowState windowState;
+ QWindow::Visibility visibility;
bool resizeEventPending;
bool receivedExpose;
PositionPolicy positionPolicy;
+ bool positionAutomatic;
Qt::ScreenOrientation contentOrientation;
qreal opacity;
+ QRegion mask;
QSize minimumSize;
QSize maximumSize;
@@ -153,12 +160,11 @@ public:
#ifndef QT_NO_CURSOR
QCursor cursor;
+ bool hasCursor;
#endif
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWINDOW_P_H
diff --git a/src/gui/kernel/qwindowdefs.h b/src/gui/kernel/qwindowdefs.h
index 9aaca3ff60..42f4bc7c9b 100644
--- a/src/gui/kernel/qwindowdefs.h
+++ b/src/gui/kernel/qwindowdefs.h
@@ -46,7 +46,6 @@
#include <QtCore/qobjectdefs.h>
#include <QtCore/qnamespace.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -88,7 +87,6 @@ typedef QList<QWidget *> QWidgetList;
typedef QList<QWindow *> QWindowList;
QT_END_NAMESPACE
-QT_END_HEADER
// Window system dependent definitions
@@ -104,7 +102,6 @@ typedef QT_PREPEND_NAMESPACE(quintptr) WId;
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
template<class K, class V> class QHash;
@@ -114,7 +111,6 @@ template<class V> class QSet;
typedef QSet<QWidget *> QWidgetSet;
QT_END_NAMESPACE
-QT_END_HEADER
#if defined(QT_NEEDS_QMAIN)
#define main qMain
diff --git a/src/gui/kernel/qwindowdefs_win.h b/src/gui/kernel/qwindowdefs_win.h
index 8f551900ae..fea995a0f5 100644
--- a/src/gui/kernel/qwindowdefs_win.h
+++ b/src/gui/kernel/qwindowdefs_win.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -124,6 +122,4 @@ Q_WIDGETS_EXPORT HDC qt_win_display_dc();
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWINDOWDEFS_WIN_H
diff --git a/src/gui/kernel/qwindowsysteminterface.cpp b/src/gui/kernel/qwindowsysteminterface.cpp
index 27bb4bae00..d2add91d66 100644
--- a/src/gui/kernel/qwindowsysteminterface.cpp
+++ b/src/gui/kernel/qwindowsysteminterface.cpp
@@ -46,6 +46,7 @@
#include "private/qtouchdevice_p.h"
#include <QAbstractEventDispatcher>
#include <qpa/qplatformdrag.h>
+#include <qpa/qplatformintegration.h>
#include <qdebug.h>
QT_BEGIN_NAMESPACE
@@ -53,6 +54,8 @@ QT_BEGIN_NAMESPACE
QElapsedTimer QWindowSystemInterfacePrivate::eventTime;
bool QWindowSystemInterfacePrivate::synchronousWindowsSystemEvents = false;
+QWaitCondition QWindowSystemInterfacePrivate::eventsFlushed;
+QMutex QWindowSystemInterfacePrivate::flushEventMutex;
//------------------------------------------------------------
//
@@ -109,9 +112,10 @@ void QWindowSystemInterface::handleEnterLeaveEvent(QWindow *enter, QWindow *leav
}
}
-void QWindowSystemInterface::handleWindowActivated(QWindow *tlw)
+void QWindowSystemInterface::handleWindowActivated(QWindow *tlw, Qt::FocusReason r)
{
- QWindowSystemInterfacePrivate::ActivatedWindowEvent *e = new QWindowSystemInterfacePrivate::ActivatedWindowEvent(tlw);
+ QWindowSystemInterfacePrivate::ActivatedWindowEvent *e =
+ new QWindowSystemInterfacePrivate::ActivatedWindowEvent(tlw, r);
QWindowSystemInterfacePrivate::handleWindowSystemEvent(e);
}
@@ -122,6 +126,14 @@ void QWindowSystemInterface::handleWindowStateChanged(QWindow *tlw, Qt::WindowSt
QWindowSystemInterfacePrivate::handleWindowSystemEvent(e);
}
+void QWindowSystemInterface::handleApplicationStateChanged(Qt::ApplicationState newState)
+{
+ Q_ASSERT(QGuiApplicationPrivate::platformIntegration()->hasCapability(QPlatformIntegration::ApplicationState));
+ QWindowSystemInterfacePrivate::ApplicationStateChangedEvent *e =
+ new QWindowSystemInterfacePrivate::ApplicationStateChangedEvent(newState);
+ QWindowSystemInterfacePrivate::handleWindowSystemEvent(e);
+}
+
void QWindowSystemInterface::handleGeometryChange(QWindow *tlw, const QRect &newRect)
{
QWindowSystemInterfacePrivate::GeometryChangeEvent *e = new QWindowSystemInterfacePrivate::GeometryChangeEvent(tlw,newRect);
@@ -505,9 +517,35 @@ void QWindowSystemInterface::handleExposeEvent(QWindow *tlw, const QRegion &regi
QWindowSystemInterfacePrivate::handleWindowSystemEvent(e);
}
+void QWindowSystemInterface::deferredFlushWindowSystemEvents()
+{
+ Q_ASSERT(QThread::currentThread() == QGuiApplication::instance()->thread());
+
+ QMutexLocker locker(&QWindowSystemInterfacePrivate::flushEventMutex);
+ flushWindowSystemEvents();
+ QWindowSystemInterfacePrivate::eventsFlushed.wakeOne();
+}
+
void QWindowSystemInterface::flushWindowSystemEvents()
{
- sendWindowSystemEventsImplementation(QEventLoop::AllEvents);
+ const int count = QWindowSystemInterfacePrivate::windowSystemEventQueue.count();
+ if (!count)
+ return;
+ if (!QGuiApplication::instance()) {
+ qWarning().nospace()
+ << "QWindowSystemInterface::flushWindowSystemEvents() invoked after "
+ "QGuiApplication destruction, discarding " << count << " events.";
+ QWindowSystemInterfacePrivate::windowSystemEventQueue.clear();
+ return;
+ }
+ if (QThread::currentThread() != QGuiApplication::instance()->thread()) {
+ QMutexLocker locker(&QWindowSystemInterfacePrivate::flushEventMutex);
+ QWindowSystemInterfacePrivate::FlushEventsEvent *e = new QWindowSystemInterfacePrivate::FlushEventsEvent();
+ QWindowSystemInterfacePrivate::handleWindowSystemEvent(e);
+ QWindowSystemInterfacePrivate::eventsFlushed.wait(&QWindowSystemInterfacePrivate::flushEventMutex);
+ } else {
+ sendWindowSystemEventsImplementation(QEventLoop::AllEvents);
+ }
}
bool QWindowSystemInterface::sendWindowSystemEvents(QEventLoop::ProcessEventsFlags flags)
@@ -575,6 +613,12 @@ void QWindowSystemInterface::handleFileOpenEvent(const QString& fileName)
QGuiApplicationPrivate::processWindowSystemEvent(&e);
}
+void QWindowSystemInterface::handleFileOpenEvent(const QUrl &url)
+{
+ QWindowSystemInterfacePrivate::FileOpenEvent e(url);
+ QGuiApplicationPrivate::processWindowSystemEvent(&e);
+}
+
void QWindowSystemInterface::handleTabletEvent(QWindow *w, ulong timestamp, bool down, const QPointF &local, const QPointF &global,
int device, int pointerType, qreal pressure, int xTilt, int yTilt,
qreal tangentialPressure, qreal rotation, int z, qint64 uid,
@@ -641,6 +685,13 @@ void QWindowSystemInterface::handleContextMenuEvent(QWindow *w, bool mouseTrigge
}
#endif
+#ifndef QT_NO_DEBUG_STREAM
+Q_GUI_EXPORT QDebug operator<<(QDebug dbg, const QWindowSystemInterface::TouchPoint &p) {
+ dbg.nospace() << "TouchPoint(" << p.id << " @" << p.normalPosition << " press " << p.pressure << " vel " << p.velocity << " state " << (int)p.state;
+ return dbg.space();
+}
+#endif
+
Q_GUI_EXPORT void qt_handleMouseEvent(QWindow *w, const QPointF & local, const QPointF & global, Qt::MouseButtons b, Qt::KeyboardModifiers mods = Qt::NoModifier) {
QWindowSystemInterface::handleMouseEvent(w, local, global, b, mods);
}
diff --git a/src/gui/kernel/qwindowsysteminterface.h b/src/gui/kernel/qwindowsysteminterface.h
index 5715b69ee5..212259c113 100644
--- a/src/gui/kernel/qwindowsysteminterface.h
+++ b/src/gui/kernel/qwindowsysteminterface.h
@@ -62,8 +62,6 @@
#include <QtCore/QEventLoop>
#include <QtGui/QVector2D>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QMimeData;
@@ -137,9 +135,12 @@ public:
static void handleEnterEvent(QWindow *w, const QPointF &local = QPointF(), const QPointF& global = QPointF());
static void handleLeaveEvent(QWindow *w);
static void handleEnterLeaveEvent(QWindow *enter, QWindow *leave, const QPointF &local = QPointF(), const QPointF& global = QPointF());
- static void handleWindowActivated(QWindow *w);
+ static void handleWindowActivated(QWindow *w, Qt::FocusReason r = Qt::OtherFocusReason);
+
static void handleWindowStateChanged(QWindow *w, Qt::WindowState newState);
+ static void handleApplicationStateChanged(Qt::ApplicationState newState);
+
static void handleExposeEvent(QWindow *tlw, const QRegion &region);
#ifndef QT_NO_DRAGANDDROP
@@ -160,6 +161,7 @@ public:
static void handleThemeChange(QWindow *tlw);
static void handleFileOpenEvent(const QString& fileName);
+ static void handleFileOpenEvent(const QUrl &url);
static void handleTabletEvent(QWindow *w, ulong timestamp, bool down, const QPointF &local, const QPointF &global,
int device, int pointerType, qreal pressure, int xTilt, int yTilt,
@@ -185,12 +187,17 @@ public:
static bool sendWindowSystemEvents(QEventLoop::ProcessEventsFlags flags);
static void setSynchronousWindowsSystemEvents(bool enable);
static void flushWindowSystemEvents();
+ static void deferredFlushWindowSystemEvents();
static int windowSystemEventsQueued();
private:
static bool sendWindowSystemEventsImplementation(QEventLoop::ProcessEventsFlags flags);
};
+#ifndef QT_NO_DEBUG_STREAM
+Q_GUI_EXPORT QDebug operator<<(QDebug dbg, const QWindowSystemInterface::TouchPoint &p);
+#endif
+
QT_END_NAMESPACE
-QT_END_HEADER
+
#endif // QWINDOWSYSTEMINTERFACE_H
diff --git a/src/gui/kernel/qwindowsysteminterface_p.h b/src/gui/kernel/qwindowsysteminterface_p.h
index 4131568461..f1bc4667f7 100644
--- a/src/gui/kernel/qwindowsysteminterface_p.h
+++ b/src/gui/kernel/qwindowsysteminterface_p.h
@@ -58,8 +58,7 @@
#include <QPointer>
#include <QMutex>
#include <QList>
-
-QT_BEGIN_HEADER
+#include <QWaitCondition>
QT_BEGIN_NAMESPACE
@@ -90,7 +89,9 @@ public:
TabletEnterProximity = UserInputEvent | 0x15,
TabletLeaveProximity = UserInputEvent | 0x16,
PlatformPanel = UserInputEvent | 0x17,
- ContextMenu = UserInputEvent | 0x18
+ ContextMenu = UserInputEvent | 0x18,
+ ApplicationStateChanged = 0x19,
+ FlushEvents = 0x20
};
class WindowSystemEvent {
@@ -138,10 +139,11 @@ public:
class ActivatedWindowEvent : public WindowSystemEvent {
public:
- explicit ActivatedWindowEvent(QWindow *activatedWindow)
- : WindowSystemEvent(ActivatedWindow), activated(activatedWindow)
+ explicit ActivatedWindowEvent(QWindow *activatedWindow, Qt::FocusReason r)
+ : WindowSystemEvent(ActivatedWindow), activated(activatedWindow), reason(r)
{ }
QPointer<QWindow> activated;
+ Qt::FocusReason reason;
};
class WindowStateChangedEvent : public WindowSystemEvent {
@@ -154,6 +156,22 @@ public:
Qt::WindowState newState;
};
+ class ApplicationStateChangedEvent : public WindowSystemEvent {
+ public:
+ ApplicationStateChangedEvent(Qt::ApplicationState newState)
+ : WindowSystemEvent(ApplicationStateChanged), newState(newState)
+ { }
+
+ Qt::ApplicationState newState;
+ };
+
+ class FlushEventsEvent : public WindowSystemEvent {
+ public:
+ FlushEventsEvent()
+ : WindowSystemEvent(FlushEvents)
+ { }
+ };
+
class UserEvent : public WindowSystemEvent {
public:
UserEvent(QWindow * w, ulong time, EventType t)
@@ -287,9 +305,12 @@ public:
class FileOpenEvent : public WindowSystemEvent {
public:
FileOpenEvent(const QString& fileName)
- : WindowSystemEvent(FileOpen), fileName(fileName)
+ : WindowSystemEvent(FileOpen), url(QUrl::fromLocalFile(fileName))
+ { }
+ FileOpenEvent(const QUrl &url)
+ : WindowSystemEvent(FileOpen), url(url)
{ }
- QString fileName;
+ QUrl url;
};
class TabletEvent : public InputEvent {
@@ -367,9 +388,10 @@ public:
mutable QMutex mutex;
public:
WindowSystemEventList() : impl(), mutex() {}
- ~WindowSystemEventList()
- { const QMutexLocker locker(&mutex); qDeleteAll(impl); impl.clear(); }
+ ~WindowSystemEventList() { clear(); }
+ void clear()
+ { const QMutexLocker locker(&mutex); qDeleteAll(impl); impl.clear(); }
void prepend(WindowSystemEvent *e)
{ const QMutexLocker locker(&mutex); impl.prepend(e); }
WindowSystemEvent *takeFirstOrReturnNull()
@@ -400,7 +422,7 @@ public:
const QMutexLocker locker(&mutex);
for (int i = 0; i < impl.size(); ++i) {
if (impl.at(i) == e) {
- impl.removeAt(i);
+ delete impl.takeAt(i);
break;
}
}
@@ -421,10 +443,12 @@ public:
static QElapsedTimer eventTime;
static bool synchronousWindowsSystemEvents;
+ static QWaitCondition eventsFlushed;
+ static QMutex flushEventMutex;
+
static QList<QTouchEvent::TouchPoint> convertTouchPoints(const QList<QWindowSystemInterface::TouchPoint> &points, QEvent::Type *type);
};
-QT_END_HEADER
QT_END_NAMESPACE
#endif // QWINDOWSYSTEMINTERFACE_P_H
diff --git a/src/gui/math3d/qgenericmatrix.h b/src/gui/math3d/qgenericmatrix.h
index 911e7f036c..c243647d33 100644
--- a/src/gui/math3d/qgenericmatrix.h
+++ b/src/gui/math3d/qgenericmatrix.h
@@ -46,8 +46,6 @@
#include <QtCore/qdebug.h>
#include <QtCore/qdatastream.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -401,6 +399,4 @@ Q_DECLARE_METATYPE(QMatrix3x4)
Q_DECLARE_METATYPE(QMatrix4x2)
Q_DECLARE_METATYPE(QMatrix4x3)
-QT_END_HEADER
-
#endif
diff --git a/src/gui/math3d/qmatrix4x4.h b/src/gui/math3d/qmatrix4x4.h
index d41602f0cb..d4ba7d64d8 100644
--- a/src/gui/math3d/qmatrix4x4.h
+++ b/src/gui/math3d/qmatrix4x4.h
@@ -48,8 +48,6 @@
#include <QtGui/qgenericmatrix.h>
#include <QtCore/qrect.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -1119,6 +1117,4 @@ QT_DEPRECATED QGenericMatrix<N, M, float> qGenericMatrixFromMatrix4x4(const QMat
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/math3d/qquaternion.cpp b/src/gui/math3d/qquaternion.cpp
index b02715e390..d042d9812a 100644
--- a/src/gui/math3d/qquaternion.cpp
+++ b/src/gui/math3d/qquaternion.cpp
@@ -66,7 +66,8 @@ QT_BEGIN_NAMESPACE
/*!
\fn QQuaternion::QQuaternion()
- Constructs an identity quaternion, i.e. with coordinates (1, 0, 0, 0).
+ Constructs an identity quaternion (1, 0, 0, 0), i.e. with the vector (0, 0, 0)
+ and scalar 1.
*/
/*!
@@ -257,7 +258,7 @@ QQuaternion QQuaternion::normalized() const
}
/*!
- Normalizes the currect quaternion in place. Nothing happens if this
+ Normalizes the current quaternion in place. Nothing happens if this
is a null quaternion or the length of the quaternion is very close to 1.
\sa length(), normalized()
diff --git a/src/gui/math3d/qquaternion.h b/src/gui/math3d/qquaternion.h
index 13fbac8f4a..c12b0f4fec 100644
--- a/src/gui/math3d/qquaternion.h
+++ b/src/gui/math3d/qquaternion.h
@@ -45,8 +45,6 @@
#include <QtGui/qvector3d.h>
#include <QtGui/qvector4d.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -324,6 +322,4 @@ Q_GUI_EXPORT QDataStream &operator>>(QDataStream &, QQuaternion &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/math3d/qvector2d.cpp b/src/gui/math3d/qvector2d.cpp
index 6aa360fc6b..784297ca70 100644
--- a/src/gui/math3d/qvector2d.cpp
+++ b/src/gui/math3d/qvector2d.cpp
@@ -68,7 +68,7 @@ QT_BEGIN_NAMESPACE
/*!
\fn QVector2D::QVector2D()
- Constructs a null vector, i.e. with coordinates (0, 0, 0).
+ Constructs a null vector, i.e. with coordinates (0, 0).
*/
/*!
@@ -229,6 +229,39 @@ void QVector2D::normalize()
}
/*!
+ \since 5.1
+
+ Returns the distance from this vertex to a point defined by
+ the vertex \a point.
+
+ \sa distanceToLine()
+*/
+float QVector2D::distanceToPoint(const QVector2D& point) const
+{
+ return (*this - point).length();
+}
+
+/*!
+ \since 5.1
+
+ Returns the distance that this vertex is from a line defined
+ by \a point and the unit vector \a direction.
+
+ If \a direction is a null vector, then it does not define a line.
+ In that case, the distance from \a point to this vertex is returned.
+
+ \sa distanceToPoint()
+*/
+float QVector2D::distanceToLine
+ (const QVector2D& point, const QVector2D& direction) const
+{
+ if (direction.isNull())
+ return (*this - point).length();
+ QVector2D p = point + dotProduct(*this - point, direction) * direction;
+ return (*this - p).length();
+}
+
+/*!
\fn QVector2D &QVector2D::operator+=(const QVector2D &vector)
Adds the given \a vector to this vector and returns a reference to
diff --git a/src/gui/math3d/qvector2d.h b/src/gui/math3d/qvector2d.h
index 9ac738fa2d..b3c2272287 100644
--- a/src/gui/math3d/qvector2d.h
+++ b/src/gui/math3d/qvector2d.h
@@ -45,8 +45,6 @@
#include <QtCore/qpoint.h>
#include <QtCore/qmetatype.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -84,6 +82,9 @@ public:
QVector2D normalized() const;
void normalize();
+ float distanceToPoint(const QVector2D &point) const;
+ float distanceToLine(const QVector2D& point, const QVector2D& direction) const;
+
QVector2D &operator+=(const QVector2D &vector);
QVector2D &operator-=(const QVector2D &vector);
QVector2D &operator*=(float factor);
@@ -252,6 +253,4 @@ Q_GUI_EXPORT QDataStream &operator>>(QDataStream &, QVector2D &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/math3d/qvector3d.cpp b/src/gui/math3d/qvector3d.cpp
index b3bf292f9b..5537562b61 100644
--- a/src/gui/math3d/qvector3d.cpp
+++ b/src/gui/math3d/qvector3d.cpp
@@ -348,6 +348,19 @@ QVector3D QVector3D::normal
}
/*!
+ \since 5.1
+
+ Returns the distance from this vertex to a point defined by
+ the vertex \a point.
+
+ \sa distanceToPlane(), distanceToLine()
+*/
+float QVector3D::distanceToPoint(const QVector3D& point) const
+{
+ return (*this - point).length();
+}
+
+/*!
Returns the distance from this vertex to a plane defined by
the vertex \a plane and a \a normal unit vector. The \a normal
parameter is assumed to have been normalized to a unit vector.
diff --git a/src/gui/math3d/qvector3d.h b/src/gui/math3d/qvector3d.h
index 28700d7d97..49d9ca6bf8 100644
--- a/src/gui/math3d/qvector3d.h
+++ b/src/gui/math3d/qvector3d.h
@@ -45,8 +45,6 @@
#include <QtCore/qpoint.h>
#include <QtCore/qmetatype.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -99,6 +97,7 @@ public:
static QVector3D normal
(const QVector3D& v1, const QVector3D& v2, const QVector3D& v3);
+ float distanceToPoint(const QVector3D& point) const;
float distanceToPlane(const QVector3D& plane, const QVector3D& normal) const;
float distanceToPlane(const QVector3D& plane1, const QVector3D& plane2, const QVector3D& plane3) const;
float distanceToLine(const QVector3D& point, const QVector3D& direction) const;
@@ -276,6 +275,4 @@ Q_GUI_EXPORT QDataStream &operator>>(QDataStream &, QVector3D &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/math3d/qvector4d.h b/src/gui/math3d/qvector4d.h
index 5acd1d3f48..4bd3822133 100644
--- a/src/gui/math3d/qvector4d.h
+++ b/src/gui/math3d/qvector4d.h
@@ -45,8 +45,6 @@
#include <QtCore/qpoint.h>
#include <QtCore/qmetatype.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -281,6 +279,4 @@ Q_GUI_EXPORT QDataStream &operator>>(QDataStream &, QVector4D &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/opengl/opengl.pri b/src/gui/opengl/opengl.pri
index 2256f201d2..1eea007e16 100644
--- a/src/gui/opengl/opengl.pri
+++ b/src/gui/opengl/opengl.pri
@@ -27,7 +27,11 @@ contains(QT_CONFIG, opengl)|contains(QT_CONFIG, opengles2) {
opengl/qopenglshadercache_p.h \
opengl/qopenglshadercache_meego_p.h \
opengl/qtriangulator_p.h \
- opengl/qrbtree_p.h
+ opengl/qrbtree_p.h \
+ opengl/qopenglversionfunctions.h \
+ opengl/qopenglversionfunctionsfactory_p.h \
+ opengl/qopenglvertexarrayobject.h \
+ opengl/qopengldebug.h
SOURCES += opengl/qopengl.cpp \
opengl/qopenglfunctions.cpp \
@@ -43,6 +47,66 @@ contains(QT_CONFIG, opengl)|contains(QT_CONFIG, opengles2) {
opengl/qopenglcustomshaderstage.cpp \
opengl/qtriangulatingstroker.cpp \
opengl/qopengltextureglyphcache.cpp \
- opengl/qtriangulator.cpp
+ opengl/qtriangulator.cpp \
+ opengl/qopenglversionfunctions.cpp \
+ opengl/qopenglversionfunctionsfactory.cpp \
+ opengl/qopenglvertexarrayobject.cpp \
+ opengl/qopengldebug.cpp
+ !contains(QT_CONFIG, opengles2) {
+ HEADERS += opengl/qopenglfunctions_1_0.h \
+ opengl/qopenglfunctions_1_1.h \
+ opengl/qopenglfunctions_1_2.h \
+ opengl/qopenglfunctions_1_3.h \
+ opengl/qopenglfunctions_1_4.h \
+ opengl/qopenglfunctions_1_5.h \
+ opengl/qopenglfunctions_2_0.h \
+ opengl/qopenglfunctions_2_1.h \
+ opengl/qopenglfunctions_3_0.h \
+ opengl/qopenglfunctions_3_1.h \
+ opengl/qopenglfunctions_3_2_core.h \
+ opengl/qopenglfunctions_3_3_core.h \
+ opengl/qopenglfunctions_4_0_core.h \
+ opengl/qopenglfunctions_4_1_core.h \
+ opengl/qopenglfunctions_4_2_core.h \
+ opengl/qopenglfunctions_4_3_core.h \
+ opengl/qopenglfunctions_3_2_compatibility.h \
+ opengl/qopenglfunctions_3_3_compatibility.h \
+ opengl/qopenglfunctions_4_0_compatibility.h \
+ opengl/qopenglfunctions_4_1_compatibility.h \
+ opengl/qopenglfunctions_4_2_compatibility.h \
+ opengl/qopenglfunctions_4_3_compatibility.h \
+ opengl/qopenglqueryhelper_p.h \
+ opengl/qopengltimerquery.h
+
+ SOURCES += opengl/qopenglfunctions_1_0.cpp \
+ opengl/qopenglfunctions_1_1.cpp \
+ opengl/qopenglfunctions_1_2.cpp \
+ opengl/qopenglfunctions_1_3.cpp \
+ opengl/qopenglfunctions_1_4.cpp \
+ opengl/qopenglfunctions_1_5.cpp \
+ opengl/qopenglfunctions_2_0.cpp \
+ opengl/qopenglfunctions_2_1.cpp \
+ opengl/qopenglfunctions_3_0.cpp \
+ opengl/qopenglfunctions_3_1.cpp \
+ opengl/qopenglfunctions_3_2_core.cpp \
+ opengl/qopenglfunctions_3_3_core.cpp \
+ opengl/qopenglfunctions_4_0_core.cpp \
+ opengl/qopenglfunctions_4_1_core.cpp \
+ opengl/qopenglfunctions_4_2_core.cpp \
+ opengl/qopenglfunctions_4_3_core.cpp \
+ opengl/qopenglfunctions_3_2_compatibility.cpp \
+ opengl/qopenglfunctions_3_3_compatibility.cpp \
+ opengl/qopenglfunctions_4_0_compatibility.cpp \
+ opengl/qopenglfunctions_4_1_compatibility.cpp \
+ opengl/qopenglfunctions_4_2_compatibility.cpp \
+ opengl/qopenglfunctions_4_3_compatibility.cpp \
+ opengl/qopengltimerquery.cpp
+ }
+
+ contains(QT_CONFIG, opengles2) {
+ HEADERS += opengl/qopenglfunctions_es2.h
+
+ SOURCES += opengl/qopenglfunctions_es2.cpp
+ }
}
diff --git a/src/gui/opengl/qopengl.h b/src/gui/opengl/qopengl.h
index 9d29e07319..6e8be66806 100644
--- a/src/gui/opengl/qopengl.h
+++ b/src/gui/opengl/qopengl.h
@@ -42,18 +42,44 @@
#ifndef QOPENGL_H
#define QOPENGL_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_OPENGL
-#include <QtCore/qglobal.h>
+// Windows always needs this to ensure that APIENTRY gets defined
+#if defined(Q_OS_WIN)
+# include <QtCore/qt_windows.h>
+#endif
-QT_BEGIN_HEADER
+// Note: Mac OSX is a "controlled platform" for OpenGL ABI so we
+// use the system provided headers there. Controlled means that the
+// headers always match the actual driver implementation so there
+// is no possibility of drivers exposing additional functionality
+// from the system headers. Also it means that the vendor can
+// (and does) make different choices about some OpenGL types. For
+// e.g. Apple uses void* for GLhandleARB whereas other platforms
+// use unsigned int.
+//
+// For the "uncontrolled" Windows and Linux platforms we use the
+// official Khronos headers. On these platforms this gives
+// access to additional functionality the drivers may expose but
+// which the system headers do not.
#if defined(QT_OPENGL_ES_2)
# if defined(Q_OS_MAC)
# include <OpenGLES/ES2/gl.h>
-# else
+# include <OpenGLES/ES2/glext.h>
+
+/*
+ OES_EGL_image_external is not included in the Apple provided
+ system headers yet, but we define the missing typedef so that
+ the qopenglextensions.cpp code will magically work once Apple
+ include the extension in their drivers.
+*/
+typedef void* GLeglImageOES;
+
+# else // "uncontrolled" platforms
# include <GLES2/gl2.h>
-# endif
/*
Some GLES2 implementations (like the one on Harmattan) are missing the
@@ -63,27 +89,15 @@ QT_BEGIN_HEADER
*/
typedef char GLchar;
-# include <QtGui/qopengles2ext.h>
-# ifndef GL_DOUBLE
-# define GL_DOUBLE GL_FLOAT
-# endif
-# ifndef GLdouble
+# include <QtGui/qopengles2ext.h>
+# ifndef GL_DOUBLE
+# define GL_DOUBLE GL_FLOAT
+# endif
+# ifndef GLdouble
typedef GLfloat GLdouble;
-# endif
+# endif
+# endif // Q_OS_MAC
#else
-// Mac OSX is a "controlled platform" for OpenGL ABI so we use
-// the system provided headers there. Controlled means that the
-// headers always match the actual driver implementation so there
-// is no possibility of drivers exposing additional functionality
-// from the system headers. Also it means that the vendor can
-// (and does) make different choices about some OpenGL types. For
-// e.g. Apple uses void* for GLhandleARB whereas other platforms
-// use unsigned int.
-//
-// For the "uncontrolled" Windows and Linux platforms we use the
-// official Khronos glext.h header. On these platforms this gives
-// access to additional functionality the drivers may expose but
-// which the system headers do not.
# if defined(Q_OS_MAC)
# include <OpenGL/gl.h>
# if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_7
@@ -92,9 +106,6 @@ typedef GLfloat GLdouble;
# endif
# include <OpenGL/glext.h>
# else
-# if defined(Q_OS_WIN)
-# include <QtCore/qt_windows.h>
-# endif
# define GL_GLEXT_LEGACY // Prevents GL/gl.h form #including system glext.h
# include <GL/gl.h>
# include <QtGui/qopenglext.h>
@@ -102,18 +113,168 @@ typedef GLfloat GLdouble;
#endif
// Desktops, apart from Mac OS X prior to 10.7 can support OpenGL 3
+// and desktops apart from Mac can support OpenGL 4
#if !defined(QT_OPENGL_ES_2)
# if !defined(Q_OS_MAC) || (defined(Q_OS_MAC) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_7)
# define QT_OPENGL_3
+# define QT_OPENGL_3_2
# endif
+#if !defined(Q_OS_MAC)
+# define QT_OPENGL_4
+# define QT_OPENGL_4_3
+#endif
#endif
QT_BEGIN_NAMESPACE
-QT_END_NAMESPACE
+// When all else fails we provide sensible fallbacks - this is needed to
+// allow compilation on OS X 10.6
+#if !defined(QT_OPENGL_ES_2)
+
+// OS X 10.6 doesn't define these which are needed below
+// OS X 10.7 and later defien them in gl3.h
+#ifndef APIENTRY
+#define APIENTRY
+#endif
+#ifndef APIENTRYP
+#define APIENTRYP APIENTRY *
+#endif
+#ifndef GLAPI
+#define GLAPI extern
+#endif
+
-QT_END_HEADER
+// This block is copied from glext.h and defines the types needed by
+// a few extension classes.
+
+#include <stddef.h>
+#ifndef GL_VERSION_2_0
+/* GL type for program/shader text */
+typedef char GLchar;
+#endif
+
+#ifndef GL_VERSION_1_5
+/* GL types for handling large vertex buffer objects */
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+#endif
+
+#ifndef GL_ARB_vertex_buffer_object
+/* GL types for handling large vertex buffer objects */
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+#endif
+
+#ifndef GL_ARB_shader_objects
+/* GL types for program/shader text and shader object handles */
+typedef char GLcharARB;
+typedef unsigned int GLhandleARB;
+#endif
+
+/* GL type for "half" precision (s10e5) float data in host memory */
+#ifndef GL_ARB_half_float_pixel
+typedef unsigned short GLhalfARB;
+#endif
+
+#ifndef GL_NV_half_float
+typedef unsigned short GLhalfNV;
+#endif
+
+#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__) && __STDC_VERSION__ >= 199901L
+#include <inttypes.h>
+#elif defined(__sun__) || defined(__digital__)
+#include <inttypes.h>
+#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 <inttypes.h>
+#elif defined(__SCO__) || defined(__USLC__)
+#include <stdint.h>
+#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) && defined(__GNUC__)
+#include <stdint.h>
+#elif defined(_WIN32)
+typedef __int32 int32_t;
+typedef __int64 int64_t;
+typedef unsigned __int64 uint64_t;
+#else
+/* Fallback if nothing above works */
+#include <inttypes.h>
+#endif
+#endif
+
+#ifndef GL_EXT_timer_query
+typedef int64_t GLint64EXT;
+typedef uint64_t GLuint64EXT;
+#endif
+
+#ifndef GL_ARB_sync
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifndef GL_ARB_cl_event
+/* These incomplete types let us declare types compatible with OpenCL's cl_context and cl_event */
+struct _cl_context;
+struct _cl_event;
+#endif
+
+#ifndef GL_ARB_debug_output
+typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,GLvoid *userParam);
+#endif
+
+#ifndef GL_AMD_debug_output
+typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,GLvoid *userParam);
+#endif
+
+#ifndef GL_KHR_debug
+typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,GLvoid *userParam);
+#endif
+
+#ifndef GL_NV_vdpau_interop
+typedef GLintptr GLvdpauSurfaceNV;
+#endif
+
+// End of block copied from glext.h
+#endif
+
+
+// Types that aren't defined in all system's gl.h files.
+typedef ptrdiff_t qopengl_GLintptr;
+typedef ptrdiff_t qopengl_GLsizeiptr;
+
+
+#if defined(APIENTRY) && !defined(QOPENGLF_APIENTRY)
+# define QOPENGLF_APIENTRY APIENTRY
+#endif
+
+# ifndef QOPENGLF_APIENTRYP
+# ifdef QOPENGLF_APIENTRY
+# define QOPENGLF_APIENTRYP QOPENGLF_APIENTRY *
+# else
+# define QOPENGLF_APIENTRY
+# define QOPENGLF_APIENTRYP *
+# endif
+# endif
+
+QT_END_NAMESPACE
#endif // QT_NO_OPENGL
diff --git a/src/gui/opengl/qopengl2pexvertexarray_p.h b/src/gui/opengl/qopengl2pexvertexarray_p.h
index fa0ad47e7f..03a3ba5d24 100644
--- a/src/gui/opengl/qopengl2pexvertexarray_p.h
+++ b/src/gui/opengl/qopengl2pexvertexarray_p.h
@@ -104,20 +104,20 @@ public:
maxX(-2e10), maxY(-2e10), minX(2e10), minY(2e10),
boundingRectDirty(true)
{ }
-
+
inline void addRect(const QRectF &rect)
{
qreal top = rect.top();
qreal left = rect.left();
qreal bottom = rect.bottom();
qreal right = rect.right();
-
+
vertexArray << QOpenGLPoint(left, top)
<< QOpenGLPoint(right, top)
<< QOpenGLPoint(right, bottom)
<< QOpenGLPoint(right, bottom)
<< QOpenGLPoint(left, bottom)
- << QOpenGLPoint(left, top);
+ << QOpenGLPoint(left, top);
}
inline void addQuad(const QRectF &rect)
diff --git a/src/gui/opengl/qopengl_p.h b/src/gui/opengl/qopengl_p.h
index 84245fb670..3cf636751a 100644
--- a/src/gui/opengl/qopengl_p.h
+++ b/src/gui/opengl/qopengl_p.h
@@ -46,11 +46,9 @@
#include <private/qopenglcontext_p.h>
#include <QtCore/qset.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
-class QOpenGLExtensionMatcher
+class Q_GUI_EXPORT QOpenGLExtensionMatcher
{
public:
QOpenGLExtensionMatcher();
@@ -68,6 +66,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QOPENGL_H
diff --git a/src/gui/opengl/qopenglbuffer.h b/src/gui/opengl/qopenglbuffer.h
index 5ce8c3db49..ab564e9001 100644
--- a/src/gui/opengl/qopenglbuffer.h
+++ b/src/gui/opengl/qopenglbuffer.h
@@ -42,13 +42,13 @@
#ifndef QOPENGLBUFFER_H
#define QOPENGLBUFFER_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_OPENGL
#include <QtCore/qscopedpointer.h>
#include <QtGui/qopengl.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -128,8 +128,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_OPENGL
#endif
diff --git a/src/gui/opengl/qopenglcustomshaderstage_p.h b/src/gui/opengl/qopenglcustomshaderstage_p.h
index 2accb03fa3..bb671b0d3b 100644
--- a/src/gui/opengl/qopenglcustomshaderstage_p.h
+++ b/src/gui/opengl/qopenglcustomshaderstage_p.h
@@ -55,8 +55,6 @@
#include <QOpenGLShaderProgram>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -87,7 +85,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/opengl/qopengldebug.cpp b/src/gui/opengl/qopengldebug.cpp
new file mode 100644
index 0000000000..3920b75a05
--- /dev/null
+++ b/src/gui/opengl/qopengldebug.cpp
@@ -0,0 +1,1806 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtCore/private/qobject_p.h>
+#include <QtCore/qglobal.h>
+#include <QtCore/qvarlengtharray.h>
+#include <QtGui/qopengl.h>
+
+#include "qopengldebug.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLDebugMessage
+ \brief The QOpenGLDebugMessage class wraps an OpenGL debug message.
+ \inmodule QtGui
+ \reentrant
+ \since 5.1
+ \ingroup shared
+ \ingroup painting-3D
+
+ Debug messages are usually created by the OpenGL server and then read by
+ OpenGL clients (either from the OpenGL internal debug log, or logged in real-time).
+ A debug message has a textual representation, a vendor-specific numeric id,
+ a source, a type and a severity.
+
+ It's also possible for applications or third-party libraries and toolkits
+ to create and insert messages in the debug log. In order to do so, you can use
+ the createApplicationMessage() or the createThirdPartyMessage() static functions.
+
+ \sa QOpenGLDebugLogger
+*/
+
+/*!
+ \class QOpenGLDebugLogger
+ \brief The QOpenGLDebugLogger enables logging of OpenGL debugging messages.
+ \inmodule QtGui
+ \since 5.1
+ \ingroup painting-3D
+
+ \tableofcontents
+
+ \section1 Introduction
+
+ OpenGL programming can be very error prone. Most of the time, a single
+ failing call to OpenGL can cause an entire portion of an application to
+ stop working, with nothing being drawn on the screen.
+
+ The only way to be sure that no errors are being returned from the OpenGL
+ implementation is checking with \c{glGetError} after each and every API
+ call. Moreover, OpenGL errors stack up, therefore glGetError should always
+ be used in a loop like this:
+
+ \code
+
+ GLenum error = GL_NO_ERROR;
+ do {
+ error = glGetError();
+ if (error != GL_NO_ERROR)
+ // handle the error
+ } while (error != GL_NO_ERROR);
+
+ \endcode
+
+ There are also many other information we are interested in (as application
+ developers), for instance performance issues, or warnings about using
+ deprecated APIs. Those kind of messages are not reported through the
+ ordinary OpenGL error reporting mechanisms.
+
+ QOpenGLDebugLogger aims at addressing these issues by providing access to
+ the \e{OpenGL debug log}. If your OpenGL implementation supports it (by
+ exposing the \c{GL_KHR_debug} extension), messages from the OpenGL server
+ will be either logged in an internal OpenGL log, or passed in "real-time"
+ to listeners as they're generated from OpenGL.
+
+ QOpenGLDebugLogger supports both these modes of operation. Refer to the
+ following sections to find out the differences between them.
+
+ \section1 Creating an OpenGL debug context
+
+ For efficiency reasons, OpenGL implementations are allowed not to create
+ any debug output at all, unless the OpenGL context is a debug context. In order
+ to create a debug context from Qt, you must set the QSurfaceFormat::DebugContext
+ format option on the QSurfaceFormat used to create the QOpenGLContext object:
+
+ \code
+
+ QSurfaceFormat format;
+ // asks for a OpenGL 3.2 debug context using the Core profile
+ format.setMajorVersion(3);
+ format.setMinorVersion(2);
+ format.setProfile(QSurfaceFormat::CoreProfile);
+ format.setOption(QSurfaceFormat::DebugContext);
+
+ QOpenGLContext *context = new QOpenGLContext;
+ context->setFormat(format);
+ context->create();
+
+ \endcode
+
+ Note that requesting a 3.2 OpenGL Core Profile is just for the example's
+ purposes; this class is not tied to any specific OpenGL or OpenGL ES
+ version, as it relies on the availability of the \c{GL_KHR_debug} extension
+ (see below).
+
+ \section1 Creating and initializing a QOpenGLDebugLogger
+
+ QOpenGLDebugLogger is a simple QObject-derived class. Just like all QObject
+ subclasses, you create an instance (and optionally specify a parent
+ object), and like the other OpenGL functions in Qt you \e{must} initialize
+ it before usage by calling initialize() whilst there is a current OpenGL context:
+
+ \code
+
+ QOpenGLContext *ctx = QOpenGLContext::currentContext();
+ QOpenGLDebugLogger *logger = new QOpenGLDebugLogger(this);
+
+ logger->initialize(); // initializes in the current context, i.e. ctx
+
+ \endcode
+
+ Note that the \c{GL_KHR_debug} extension \e{must} be available in the context
+ in order to access the messages logged by OpenGL. You can check the
+ presence of this extension by calling:
+
+ \code
+
+ ctx->hasExtension(QByteArrayLiteral("GL_KHR_debug"))
+
+ \endcode
+
+ where \c{ctx} is a valid QOpenGLContext. If the extension is not available,
+ initialize() will return false.
+
+ \section1 Reading the internal OpenGL debug log
+
+ OpenGL implementations keep an internal log of debug messages. Messages
+ stored in this log can be retrieved by using the loggedMessages() function:
+
+ \code
+
+ QList<QOpenGLDebugMessage> messages = logger->loggedMessages();
+ foreach (const QOpenGLDebugMessage &message, messages)
+ qDebug() << message;
+
+ \endcode
+
+ The internal log has a limited size; when it fills up, older messages will
+ get discarded to make room for the new incoming messages. When you call
+ loggedMessages(), the internal log will be emptied as well.
+
+ If you want to be sure not to lose any debug message, you must use real-time
+ logging instead of calling this function. However, debug messages might
+ still be generated in the timespan between context creation and activation
+ of real-time logging (or, in general, when the real-time logging is disabled).
+
+ \section1 Real-time logging of messages
+
+ It is also possible to receive a stream of debug messages from the OpenGL
+ server \e{as they are generated} by the implementation. In order to do so,
+ you need to connect a suitable slot to the messageLogged() signal, and
+ start logging by calling startLogging():
+
+ \code
+
+ connect(logger, &QOpenGLDebugLogger::messageLogged, receiver, &LogHandler::handleLoggedMessage);
+ logger->startLogging();
+
+ \endcode
+
+ Similarly, logging can be disabled at any time by calling the stopLogging()
+ function.
+
+ Real-time logging can be either asynchronous or synchronous, depending on
+ the parameter passed to startLogging(). When logging in asynchronous mode
+ (the default, as it has a very small overhead), the OpenGL implementation
+ can generate messages at any time, and/or in an order which is different from the
+ order of the OpenGL commands which caused those messages to be logged.
+ The messages could also be generated from a thread that it's different from
+ the thread the context is currently bound to. This is because OpenGL
+ implementations are usually highly threaded and asynchronous, and therefore
+ no warranties are made about the relative order and the timings of the
+ debug messages.
+
+ On the other hand, logging in synchronous mode has a high overhead, but
+ the OpenGL implementation guarantees that all the messages caused by a
+ certain command are received in order, before the command returns,
+ and from the same thread the OpenGL context is bound to.
+
+ This means that when logging in synchronous mode you will be able to run
+ your OpenGL application in a debugger, put a breakpoint on a slot connected
+ to the messageLogged() signal, and see in the backtrace the exact call
+ that caused the logged message. This can be extremely useful to debug
+ an OpenGL problem. Note that if OpenGL rendering is happening in another
+ thread, you must force the signal/slot connection type to Qt::DirectConnection
+ in order to be able to see the actual backtrace.
+
+ Refer to the LoggingMode enum documentation for more information about
+ logging modes.
+
+ \note When real-time logging is enabled, debug messages will \e{not} be
+ inserted in the internal OpenGL debug log any more; messages already
+ present in the internal log will not be deleted, nor they will be emitted
+ through the messageLogged() signal. Since some messages might be generated
+ before real-time logging is started (and therefore be kept in the internal
+ OpenGL log), it is important to always check if it contains any message
+ after calling startLogging().
+
+ \section1 Inserting messages in the debug log
+
+ It is possible for applications and libraries to insert custom messages in
+ the debug log, for instance for marking a group of related OpenGL commands
+ and therefore being then able to identify eventual messages coming from them.
+
+ In order to do so, you can create a QOpenGLDebugMessage object by calling
+ \l{QOpenGLDebugMessage::}{createApplicationMessage()} or
+ \l{QOpenGLDebugMessage::}{createThirdPartyMessage()}, and then inserting it
+ into the log by calling logMessage():
+
+ \code
+
+ QOpenGLDebugMessage message =
+ QOpenGLDebugMessage::createApplicationMessage(QStringLiteral("Custom message"));
+
+ logger->logMessage(message);
+
+ \endcode
+
+ Note that OpenGL implementations have a vendor-specific limit to the length
+ of the messages that can be inserted in the debug log. You can retrieve
+ this length by calling the maximumMessageLength() method; messages longer
+ than the limit will automatically get truncated.
+
+ \section1 Controlling the debug output
+
+ QOpenGLDebugMessage is also able to apply filters to the debug messages, and
+ therefore limit the amount of messages logged. You can enable or disable
+ logging of messages by calling enableMessages() and disableMessages()
+ respectively. By default, all messages are logged.
+
+ It is possible to enable or disable messages by selecting them by:
+
+ \list
+ \li source, type and severity (and including all ids in the selection);
+ \li id, source and type (and including all severities in the selection).
+ \endlist
+
+ Note that the "enabled" status for a given message is a property of the
+ (id, source, type, severity) tuple; the message attributes \e{do not} form
+ a hierarchy of any kind. You should be careful about the order of the calls
+ to enableMessages() and disableMessages(), as it will change which
+ messages will are enabled / disabled.
+
+ It's not possible to filter by the message text itself; applications
+ have to do that on their own (in slots connected to the messageLogged()
+ signal, or after fetching the messages in the internal debug log
+ through loggedMessages()).
+
+ In order to simplify the management of the enabled / disabled statuses,
+ QOpenGLDebugMessage also supports the concept of \c{debug groups}. A debug
+ group contains the group of enabled / disabled configurations of debug
+ messages. Moreover, debug groups are organized in a stack: it is possible
+ to push and pop groups by calling pushGroup() and popGroup() respectively.
+ (When an OpenGL context is created, there is already a group in the stack).
+
+ The enableMessages() and disableMessages() functions will modify the
+ configuration in the current debug group, that is, the one at the top of
+ the debug groups stack.
+
+ When a new group is pushed onto the debug groups stack, it will inherit
+ the configuration of the group that was previously on the top of the stack.
+ Vice versa, popping a debug group will restore the configuration of
+ the debug group that becomes the new top.
+
+ Pushing (respectively popping) debug groups will also automatically generate
+ a debug message of type QOpenGLDebugMessage::GroupPushType (respectively
+ \l{QOpenGLDebugMessage::}{GroupPopType}).
+
+ \sa QOpenGLDebugMessage
+*/
+
+/*!
+ \enum QOpenGLDebugMessage::Source
+
+ The Source enum defines the source of the debug message.
+
+ \value InvalidSource
+ The source of the message is invalid; this is the source of a
+ default-constructed QOpenGLDebugMessage object.
+
+ \value APISource
+ The message was generated in response to OpenGL API calls.
+
+ \value WindowSystemSource
+ The message was generated by the window system.
+
+ \value ShaderCompilerSource
+ The message was generated by the shader compiler.
+
+ \value ThirdPartySource
+ The message was generated by a third party, for instance an OpenGL
+ framework a or debugging toolkit.
+
+ \value ApplicationSource
+ The message was generated by the application itself.
+
+ \value OtherSource
+ The message was generated by a source not included in this
+ enumeration.
+
+ \omitvalue LastSource
+
+ \value AnySource
+ This value corresponds to a mask of all possible message sources.
+*/
+
+/*!
+ \enum QOpenGLDebugMessage::Type
+
+ The Type enum defines the type of the debug message.
+
+ \value InvalidType
+ The type of the message is invalid; this is the type of a
+ default-constructed QOpenGLDebugMessage object.
+
+ \value ErrorType
+ The message represents an error.
+
+ \value DeprecatedBehaviorType
+ The message represents an usage of deprecated behavior.
+
+ \value UndefinedBehaviorType
+ The message represents an usage of undefined behavior.
+
+ \value PortabilityType
+ The message represents an usage of vendor-specific behavior,
+ that might pose portability concerns.
+
+ \value PerformanceType
+ The message represents a performance issue.
+
+ \value OtherType
+ The message represents a type not included in this
+ enumeration.
+
+ \value MarkerType
+ The message represents a marker in the debug log.
+
+ \value GroupPushType
+ The message represents a debug group push operation.
+
+ \value GroupPopType
+ The message represents a debug group pop operation.
+
+ \omitvalue LastType
+
+ \value AnyType
+ This value corresponds to a mask of all possible message types.
+*/
+
+/*!
+ \enum QOpenGLDebugMessage::Severity
+
+ The Severity enum defines the severity of the debug message.
+
+ \value InvalidSeverity
+ The severity of the message is invalid; this is the severity of a
+ default-constructed QOpenGLDebugMessage object.
+
+ \value HighSeverity
+ The message has a high severity.
+
+ \value MediumSeverity
+ The message has a medium severity.
+
+ \value LowSeverity
+ The message has a low severity.
+
+ \value NotificationSeverity
+ The message is a notification.
+
+ \omitvalue LastSeverity
+
+ \value AnySeverity
+ This value corresponds to a mask of all possible message severities.
+*/
+
+/*!
+ \property QOpenGLDebugLogger::loggingMode
+
+ \brief the logging mode passed to startLogging().
+
+ Note that logging must have been started or the value of this property
+ will be meaningless.
+
+ \sa startLogging(), isLogging()
+*/
+/*!
+ \enum QOpenGLDebugLogger::LoggingMode
+
+ The LoggingMode enum defines the logging mode of the logger object.
+
+ \value AsynchronousLogging
+ Messages from the OpenGL server are logged asynchronously. This means
+ that messages can be logged some time after the corresponding OpenGL
+ actions that caused them, and even be received in an out-of-order
+ fashion, depending on the OpenGL implementation. This mode has a very low
+ performance penalty, as OpenGL implementations are heavily threaded
+ and asynchronous by nature.
+
+ \value SynchronousLogging
+ Messages from the OpenGL server are logged synchronously and
+ sequentially. This has a severe performance hit, as OpenGL
+ implementations are very asynchronous by nature; but it's very useful
+ to debug OpenGL problems, as OpenGL guarantees that the messages
+ generated by a OpenGL command will be logged before the corresponding
+ command execution has returned. Therefore, you can install a breakpoint
+ on the messageLogged() signal and see in the backtrace which OpenGL
+ command caused it; the only caveat is that if you are using OpenGL from
+ multiple threads you may need to force direct connection when
+ connecting to the messageLogged() signal.
+*/
+
+// Under OSX (at least up to 10.8) we cannot include our copy of glext.h,
+// but we use the system-wide one, which unfortunately lacks all the needed
+// defines/typedefs. In order to make the code compile, we just add here
+// the GL_KHR_debug defines.
+
+#ifndef GL_KHR_debug
+#define GL_KHR_debug 1
+
+#ifndef GL_DEBUG_OUTPUT_SYNCHRONOUS
+#define GL_DEBUG_OUTPUT_SYNCHRONOUS 0x8242
+#endif
+#ifndef GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH
+#define GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH 0x8243
+#endif
+#ifndef GL_DEBUG_CALLBACK_FUNCTION
+#define GL_DEBUG_CALLBACK_FUNCTION 0x8244
+#endif
+#ifndef GL_DEBUG_CALLBACK_USER_PARAM
+#define GL_DEBUG_CALLBACK_USER_PARAM 0x8245
+#endif
+#ifndef GL_DEBUG_SOURCE_API
+#define GL_DEBUG_SOURCE_API 0x8246
+#endif
+#ifndef GL_DEBUG_SOURCE_WINDOW_SYSTEM
+#define GL_DEBUG_SOURCE_WINDOW_SYSTEM 0x8247
+#endif
+#ifndef GL_DEBUG_SOURCE_SHADER_COMPILER
+#define GL_DEBUG_SOURCE_SHADER_COMPILER 0x8248
+#endif
+#ifndef GL_DEBUG_SOURCE_THIRD_PARTY
+#define GL_DEBUG_SOURCE_THIRD_PARTY 0x8249
+#endif
+#ifndef GL_DEBUG_SOURCE_APPLICATION
+#define GL_DEBUG_SOURCE_APPLICATION 0x824A
+#endif
+#ifndef GL_DEBUG_SOURCE_OTHER
+#define GL_DEBUG_SOURCE_OTHER 0x824B
+#endif
+#ifndef GL_DEBUG_TYPE_ERROR
+#define GL_DEBUG_TYPE_ERROR 0x824C
+#endif
+#ifndef GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR
+#define GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR 0x824D
+#endif
+#ifndef GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR
+#define GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR 0x824E
+#endif
+#ifndef GL_DEBUG_TYPE_PORTABILITY
+#define GL_DEBUG_TYPE_PORTABILITY 0x824F
+#endif
+#ifndef GL_DEBUG_TYPE_PERFORMANCE
+#define GL_DEBUG_TYPE_PERFORMANCE 0x8250
+#endif
+#ifndef GL_DEBUG_TYPE_OTHER
+#define GL_DEBUG_TYPE_OTHER 0x8251
+#endif
+#ifndef GL_DEBUG_TYPE_MARKER
+#define GL_DEBUG_TYPE_MARKER 0x8268
+#endif
+#ifndef GL_DEBUG_TYPE_PUSH_GROUP
+#define GL_DEBUG_TYPE_PUSH_GROUP 0x8269
+#endif
+#ifndef GL_DEBUG_TYPE_POP_GROUP
+#define GL_DEBUG_TYPE_POP_GROUP 0x826A
+#endif
+#ifndef GL_DEBUG_SEVERITY_NOTIFICATION
+#define GL_DEBUG_SEVERITY_NOTIFICATION 0x826B
+#endif
+#ifndef GL_MAX_DEBUG_GROUP_STACK_DEPTH
+#define GL_MAX_DEBUG_GROUP_STACK_DEPTH 0x826C
+#endif
+#ifndef GL_DEBUG_GROUP_STACK_DEPTH
+#define GL_DEBUG_GROUP_STACK_DEPTH 0x826D
+#endif
+#ifndef GL_BUFFER
+#define GL_BUFFER 0x82E0
+#endif
+#ifndef GL_SHADER
+#define GL_SHADER 0x82E1
+#endif
+#ifndef GL_PROGRAM
+#define GL_PROGRAM 0x82E2
+#endif
+#ifndef GL_QUERY
+#define GL_QUERY 0x82E3
+#endif
+#ifndef GL_PROGRAM_PIPELINE
+#define GL_PROGRAM_PIPELINE 0x82E4
+#endif
+#ifndef GL_SAMPLER
+#define GL_SAMPLER 0x82E6
+#endif
+#ifndef GL_DISPLAY_LIST
+#define GL_DISPLAY_LIST 0x82E7
+#endif
+#ifndef GL_MAX_LABEL_LENGTH
+#define GL_MAX_LABEL_LENGTH 0x82E8
+#endif
+#ifndef GL_MAX_DEBUG_MESSAGE_LENGTH
+#define GL_MAX_DEBUG_MESSAGE_LENGTH 0x9143
+#endif
+#ifndef GL_MAX_DEBUG_LOGGED_MESSAGES
+#define GL_MAX_DEBUG_LOGGED_MESSAGES 0x9144
+#endif
+#ifndef GL_DEBUG_LOGGED_MESSAGES
+#define GL_DEBUG_LOGGED_MESSAGES 0x9145
+#endif
+#ifndef GL_DEBUG_SEVERITY_HIGH
+#define GL_DEBUG_SEVERITY_HIGH 0x9146
+#endif
+#ifndef GL_DEBUG_SEVERITY_MEDIUM
+#define GL_DEBUG_SEVERITY_MEDIUM 0x9147
+#endif
+#ifndef GL_DEBUG_SEVERITY_LOW
+#define GL_DEBUG_SEVERITY_LOW 0x9148
+#endif
+#ifndef GL_DEBUG_OUTPUT
+#define GL_DEBUG_OUTPUT 0x92E0
+#endif
+#ifndef GL_CONTEXT_FLAG_DEBUG_BIT
+#define GL_CONTEXT_FLAG_DEBUG_BIT 0x00000002
+#endif
+#ifndef GL_STACK_OVERFLOW
+#define GL_STACK_OVERFLOW 0x0503
+#endif
+#ifndef GL_STACK_UNDERFLOW
+#define GL_STACK_UNDERFLOW 0x0504
+#endif
+
+typedef void (QOPENGLF_APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,GLvoid *userParam);
+
+#endif /* GL_KHR_debug */
+
+
+/*!
+ \internal
+*/
+static QOpenGLDebugMessage::Source qt_messageSourceFromGL(GLenum source)
+{
+ switch (source) {
+ case GL_DEBUG_SOURCE_API:
+ return QOpenGLDebugMessage::APISource;
+ case GL_DEBUG_SOURCE_WINDOW_SYSTEM:
+ return QOpenGLDebugMessage::WindowSystemSource;
+ case GL_DEBUG_SOURCE_SHADER_COMPILER:
+ return QOpenGLDebugMessage::ShaderCompilerSource;
+ case GL_DEBUG_SOURCE_THIRD_PARTY:
+ return QOpenGLDebugMessage::ThirdPartySource;
+ case GL_DEBUG_SOURCE_APPLICATION:
+ return QOpenGLDebugMessage::ApplicationSource;
+ case GL_DEBUG_SOURCE_OTHER:
+ return QOpenGLDebugMessage::OtherSource;
+ }
+
+ Q_ASSERT_X(false, Q_FUNC_INFO, "Unknown message source from GL");
+ return QOpenGLDebugMessage::OtherSource;
+}
+
+/*!
+ \internal
+*/
+static GLenum qt_messageSourceToGL(QOpenGLDebugMessage::Source source)
+{
+ switch (source) {
+ case QOpenGLDebugMessage::InvalidSource:
+ break;
+ case QOpenGLDebugMessage::APISource:
+ return GL_DEBUG_SOURCE_API;
+ case QOpenGLDebugMessage::WindowSystemSource:
+ return GL_DEBUG_SOURCE_WINDOW_SYSTEM;
+ case QOpenGLDebugMessage::ShaderCompilerSource:
+ return GL_DEBUG_SOURCE_SHADER_COMPILER;
+ case QOpenGLDebugMessage::ThirdPartySource:
+ return GL_DEBUG_SOURCE_THIRD_PARTY;
+ case QOpenGLDebugMessage::ApplicationSource:
+ return GL_DEBUG_SOURCE_APPLICATION;
+ case QOpenGLDebugMessage::OtherSource:
+ return GL_DEBUG_SOURCE_OTHER;
+ case QOpenGLDebugMessage::AnySource:
+ break;
+ }
+
+ Q_ASSERT_X(false, Q_FUNC_INFO, "Invalid message source");
+ return GL_DEBUG_SOURCE_OTHER;
+}
+
+/*!
+ \internal
+*/
+static QString qt_messageSourceToString(QOpenGLDebugMessage::Source source)
+{
+ switch (source) {
+ case QOpenGLDebugMessage::InvalidSource:
+ return QStringLiteral("InvalidSource");
+ case QOpenGLDebugMessage::APISource:
+ return QStringLiteral("APISource");
+ case QOpenGLDebugMessage::WindowSystemSource:
+ return QStringLiteral("WindowSystemSource");
+ case QOpenGLDebugMessage::ShaderCompilerSource:
+ return QStringLiteral("ShaderCompilerSource");
+ case QOpenGLDebugMessage::ThirdPartySource:
+ return QStringLiteral("ThirdPartySource");
+ case QOpenGLDebugMessage::ApplicationSource:
+ return QStringLiteral("ApplicationSource");
+ case QOpenGLDebugMessage::OtherSource:
+ return QStringLiteral("OtherSource");
+ case QOpenGLDebugMessage::AnySource:
+ return QStringLiteral("AnySource");
+ }
+
+ Q_ASSERT_X(false, Q_FUNC_INFO, "Unknown message source");
+ return QString();
+}
+
+/*!
+ \internal
+*/
+static QOpenGLDebugMessage::Type qt_messageTypeFromGL(GLenum type)
+{
+ switch (type) {
+ case GL_DEBUG_TYPE_ERROR:
+ return QOpenGLDebugMessage::ErrorType;
+ case GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR:
+ return QOpenGLDebugMessage::DeprecatedBehaviorType;
+ case GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR:
+ return QOpenGLDebugMessage::UndefinedBehaviorType;
+ case GL_DEBUG_TYPE_PORTABILITY:
+ return QOpenGLDebugMessage::PortabilityType;
+ case GL_DEBUG_TYPE_PERFORMANCE:
+ return QOpenGLDebugMessage::PerformanceType;
+ case GL_DEBUG_TYPE_OTHER:
+ return QOpenGLDebugMessage::OtherType;
+ case GL_DEBUG_TYPE_MARKER:
+ return QOpenGLDebugMessage::MarkerType;
+ case GL_DEBUG_TYPE_PUSH_GROUP:
+ return QOpenGLDebugMessage::GroupPushType;
+ case GL_DEBUG_TYPE_POP_GROUP:
+ return QOpenGLDebugMessage::GroupPopType;
+ }
+
+ Q_ASSERT_X(false, Q_FUNC_INFO, "Unknown message type from GL");
+ return QOpenGLDebugMessage::OtherType;
+}
+
+/*!
+ \internal
+*/
+static GLenum qt_messageTypeToGL(QOpenGLDebugMessage::Type type)
+{
+ switch (type) {
+ case QOpenGLDebugMessage::InvalidType:
+ break;
+ case QOpenGLDebugMessage::ErrorType:
+ return GL_DEBUG_TYPE_ERROR;
+ case QOpenGLDebugMessage::DeprecatedBehaviorType:
+ return GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR;
+ case QOpenGLDebugMessage::UndefinedBehaviorType:
+ return GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR;
+ case QOpenGLDebugMessage::PortabilityType:
+ return GL_DEBUG_TYPE_PORTABILITY;
+ case QOpenGLDebugMessage::PerformanceType:
+ return GL_DEBUG_TYPE_PERFORMANCE;
+ case QOpenGLDebugMessage::OtherType:
+ return GL_DEBUG_TYPE_OTHER;
+ case QOpenGLDebugMessage::MarkerType:
+ return GL_DEBUG_TYPE_MARKER;
+ case QOpenGLDebugMessage::GroupPushType:
+ return GL_DEBUG_TYPE_PUSH_GROUP;
+ case QOpenGLDebugMessage::GroupPopType:
+ return GL_DEBUG_TYPE_POP_GROUP;
+ case QOpenGLDebugMessage::AnyType:
+ break;
+ }
+
+ Q_ASSERT_X(false, Q_FUNC_INFO, "Invalid message type");
+ return GL_DEBUG_TYPE_OTHER;
+}
+
+/*!
+ \internal
+*/
+static QString qt_messageTypeToString(QOpenGLDebugMessage::Type type)
+{
+ switch (type) {
+ case QOpenGLDebugMessage::InvalidType:
+ return QStringLiteral("InvalidType");
+ case QOpenGLDebugMessage::ErrorType:
+ return QStringLiteral("ErrorType");
+ case QOpenGLDebugMessage::DeprecatedBehaviorType:
+ return QStringLiteral("DeprecatedBehaviorType");
+ case QOpenGLDebugMessage::UndefinedBehaviorType:
+ return QStringLiteral("UndefinedBehaviorType");
+ case QOpenGLDebugMessage::PortabilityType:
+ return QStringLiteral("PortabilityType");
+ case QOpenGLDebugMessage::PerformanceType:
+ return QStringLiteral("PerformanceType");
+ case QOpenGLDebugMessage::OtherType:
+ return QStringLiteral("OtherType");
+ case QOpenGLDebugMessage::MarkerType:
+ return QStringLiteral("MarkerType");
+ case QOpenGLDebugMessage::GroupPushType:
+ return QStringLiteral("GroupPushType");
+ case QOpenGLDebugMessage::GroupPopType:
+ return QStringLiteral("GroupPopType");
+ case QOpenGLDebugMessage::AnyType:
+ return QStringLiteral("AnyType");
+ }
+
+ Q_ASSERT_X(false, Q_FUNC_INFO, "Unknown message type");
+ return QString();
+}
+
+/*!
+ \internal
+*/
+static QOpenGLDebugMessage::Severity qt_messageSeverityFromGL(GLenum severity)
+{
+ switch (severity) {
+ case GL_DEBUG_SEVERITY_HIGH:
+ return QOpenGLDebugMessage::HighSeverity;
+ case GL_DEBUG_SEVERITY_MEDIUM:
+ return QOpenGLDebugMessage::MediumSeverity;
+ case GL_DEBUG_SEVERITY_LOW:
+ return QOpenGLDebugMessage::LowSeverity;
+ case GL_DEBUG_SEVERITY_NOTIFICATION:
+ return QOpenGLDebugMessage::NotificationSeverity;
+ }
+
+ Q_ASSERT_X(false, Q_FUNC_INFO, "Unknown message severity from GL");
+ return QOpenGLDebugMessage::NotificationSeverity;
+}
+
+/*!
+ \internal
+*/
+static GLenum qt_messageSeverityToGL(QOpenGLDebugMessage::Severity severity)
+{
+ switch (severity) {
+ case QOpenGLDebugMessage::InvalidSeverity:
+ break;
+ case QOpenGLDebugMessage::HighSeverity:
+ return GL_DEBUG_SEVERITY_HIGH;
+ case QOpenGLDebugMessage::MediumSeverity:
+ return GL_DEBUG_SEVERITY_MEDIUM;
+ case QOpenGLDebugMessage::LowSeverity:
+ return GL_DEBUG_SEVERITY_LOW;
+ case QOpenGLDebugMessage::NotificationSeverity:
+ return GL_DEBUG_SEVERITY_NOTIFICATION;
+ case QOpenGLDebugMessage::AnySeverity:
+ break;
+ }
+
+ Q_ASSERT_X(false, Q_FUNC_INFO, "Invalid message severity");
+ return GL_DEBUG_SEVERITY_NOTIFICATION;
+}
+
+/*!
+ \internal
+*/
+static QString qt_messageSeverityToString(QOpenGLDebugMessage::Severity severity)
+{
+ switch (severity) {
+ case QOpenGLDebugMessage::InvalidSeverity:
+ return QStringLiteral("InvalidSeverity");
+ case QOpenGLDebugMessage::HighSeverity:
+ return QStringLiteral("HighSeverity");
+ case QOpenGLDebugMessage::MediumSeverity:
+ return QStringLiteral("MediumSeverity");
+ case QOpenGLDebugMessage::LowSeverity:
+ return QStringLiteral("LowSeverity");
+ case QOpenGLDebugMessage::NotificationSeverity:
+ return QStringLiteral("NotificationSeverity");
+ case QOpenGLDebugMessage::AnySeverity:
+ return QStringLiteral("AnySeverity");
+ }
+
+ Q_ASSERT_X(false, Q_FUNC_INFO, "Unknown message severity");
+ return QString();
+}
+
+class QOpenGLDebugMessagePrivate : public QSharedData
+{
+public:
+ QOpenGLDebugMessagePrivate();
+
+ QString message;
+ GLuint id;
+ QOpenGLDebugMessage::Source source;
+ QOpenGLDebugMessage::Type type;
+ QOpenGLDebugMessage::Severity severity;
+};
+
+/*!
+ \internal
+*/
+QOpenGLDebugMessagePrivate::QOpenGLDebugMessagePrivate()
+ : message(),
+ id(0),
+ source(QOpenGLDebugMessage::InvalidSource),
+ type(QOpenGLDebugMessage::InvalidType),
+ severity(QOpenGLDebugMessage::InvalidSeverity)
+{
+}
+
+
+/*!
+ Constructs a debug message with an empty message string, id set to 0,
+ source set to InvalidSource, type set to InvalidType, and severity set to
+ InvalidSeverity.
+
+ \note This constructor should not be used to create a debug message;
+ instead, use the createApplicationMessage() or the createThirdPartyMessage()
+ static functions.
+
+ \sa createApplicationMessage(), createThirdPartyMessage()
+*/
+QOpenGLDebugMessage::QOpenGLDebugMessage()
+ : d(new QOpenGLDebugMessagePrivate)
+{
+}
+
+/*!
+ Constructs a debug message as a copy of \a debugMessage.
+
+ \sa operator=()
+*/
+QOpenGLDebugMessage::QOpenGLDebugMessage(const QOpenGLDebugMessage &debugMessage)
+ : d(debugMessage.d)
+{
+}
+
+/*!
+ Destroys this debug message.
+*/
+QOpenGLDebugMessage::~QOpenGLDebugMessage()
+{
+}
+
+/*!
+ Assigns the message \a debugMessage to this object, and returns a reference
+ to the copy.
+*/
+QOpenGLDebugMessage &QOpenGLDebugMessage::operator=(const QOpenGLDebugMessage &debugMessage)
+{
+ d = debugMessage.d;
+ return *this;
+}
+
+/*!
+ \fn void QOpenGLDebugMessage::swap(QOpenGLDebugMessage &debugMessage)
+
+ Swaps the message \a debugMessage with this message. This operation is very
+ fast and never fails.
+*/
+
+/*!
+ Returns the source of the debug message.
+*/
+QOpenGLDebugMessage::Source QOpenGLDebugMessage::source() const
+{
+ return d->source;
+}
+
+/*!
+ Returns the type of the debug message.
+*/
+QOpenGLDebugMessage::Type QOpenGLDebugMessage::type() const
+{
+ return d->type;
+}
+
+/*!
+ Returns the severity of the debug message.
+*/
+QOpenGLDebugMessage::Severity QOpenGLDebugMessage::severity() const
+{
+ return d->severity;
+}
+
+/*!
+ Returns the id of the debug message. Ids are generally vendor-specific.
+*/
+GLuint QOpenGLDebugMessage::id() const
+{
+ return d->id;
+}
+
+/*!
+ Returns the textual message contained by this debug message.
+*/
+QString QOpenGLDebugMessage::message() const
+{
+ return d->message;
+}
+
+/*!
+ Constructs and returns a debug message with \a text as its text, \a id
+ as id, \a severity as severity, and \a type as type. The message source
+ will be set to ApplicationSource.
+
+ \sa QOpenGLDebugLogger::logMessage(), createThirdPartyMessage()
+*/
+QOpenGLDebugMessage QOpenGLDebugMessage::createApplicationMessage(const QString &text,
+ GLuint id,
+ QOpenGLDebugMessage::Severity severity,
+ QOpenGLDebugMessage::Type type)
+{
+ QOpenGLDebugMessage m;
+ m.d->message = text;
+ m.d->id = id;
+ m.d->severity = severity;
+ m.d->type = type;
+ m.d->source = ApplicationSource;
+ return m;
+}
+
+/*!
+ Constructs and returns a debug message with \a text as its text, \a id
+ as id, \a severity as severity, and \a type as type. The message source
+ will be set to ThirdPartySource.
+
+ \sa QOpenGLDebugLogger::logMessage(), createApplicationMessage()
+*/
+QOpenGLDebugMessage QOpenGLDebugMessage::createThirdPartyMessage(const QString &text,
+ GLuint id,
+ QOpenGLDebugMessage::Severity severity,
+ QOpenGLDebugMessage::Type type)
+{
+ QOpenGLDebugMessage m;
+ m.d->message = text;
+ m.d->id = id;
+ m.d->severity = severity;
+ m.d->type = type;
+ m.d->source = ThirdPartySource;
+ return m;
+}
+
+/*!
+ Returns true if this debug message is equal to \a debugMessage, or false
+ otherwise. Two debugging messages are equal if they have the same textual
+ message, the same id, the same source, the same type and the same severity.
+
+ \sa operator!=()
+*/
+bool QOpenGLDebugMessage::operator==(const QOpenGLDebugMessage &debugMessage) const
+{
+ return (d == debugMessage.d)
+ || (d->id == debugMessage.d->id
+ && d->source == debugMessage.d->source
+ && d->type == debugMessage.d->type
+ && d->severity == debugMessage.d->severity
+ && d->message == debugMessage.d->message);
+}
+
+/*!
+ \fn bool QOpenGLDebugMessage::operator!=(const QOpenGLDebugMessage &debugMessage) const
+
+ Returns true if this message is different from \a debugMessage, or false
+ otherwise.
+
+ \sa operator==()
+*/
+
+#ifndef QT_NO_DEBUG_STREAM
+/*!
+ \relates QOpenGLDebugMessage
+
+ Writes the source \a source into the debug object \a debug for debugging
+ purposes.
+*/
+QDebug operator<<(QDebug debug, QOpenGLDebugMessage::Source source)
+{
+ debug.nospace() << "QOpenGLDebugMessage::Source("
+ << qt_messageSourceToString(source)
+ << ")";
+ return debug.space();
+}
+
+/*!
+ \relates QOpenGLDebugMessage
+
+ Writes the type \a type into the debug object \a debug for debugging
+ purposes.
+*/
+QDebug operator<<(QDebug debug, QOpenGLDebugMessage::Type type)
+{
+ debug.nospace() << "QOpenGLDebugMessage::Type("
+ << qt_messageTypeToString(type)
+ << ")";
+ return debug.space();
+}
+
+/*!
+ \relates QOpenGLDebugMessage
+
+ Writes the severity \a severity into the debug object \a debug for debugging
+ purposes.
+*/
+QDebug operator<<(QDebug debug, QOpenGLDebugMessage::Severity severity)
+{
+ debug.nospace() << "QOpenGLDebugMessage::Severity("
+ << qt_messageSeverityToString(severity)
+ << ")";
+ return debug.space();
+}
+
+/*!
+ \relates QOpenGLDebugMessage
+
+ Writes the message \a message into the debug object \a debug for debugging
+ purposes.
+*/
+QDebug operator<<(QDebug debug, const QOpenGLDebugMessage &message)
+{
+ debug.nospace() << "QOpenGLDebugMessage("
+ << qt_messageSourceToString(message.source()) << ", "
+ << message.id() << ", "
+ << message.message() << ", "
+ << qt_messageSeverityToString(message.severity()) << ", "
+ << qt_messageTypeToString(message.type()) << ")";
+ return debug.space();
+
+}
+#endif // QT_NO_DEBUG_STREAM
+
+typedef void (QOPENGLF_APIENTRYP qt_glDebugMessageControl_t)(GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
+typedef void (QOPENGLF_APIENTRYP qt_glDebugMessageInsert_t)(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf);
+typedef void (QOPENGLF_APIENTRYP qt_glDebugMessageCallback_t)(GLDEBUGPROC callback, const void *userParam);
+typedef GLuint (QOPENGLF_APIENTRYP qt_glGetDebugMessageLog_t)(GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog);
+typedef void (QOPENGLF_APIENTRYP qt_glPushDebugGroup_t)(GLenum source, GLuint id, GLsizei length, const GLchar *message);
+typedef void (QOPENGLF_APIENTRYP qt_glPopDebugGroup_t)();
+typedef void (QOPENGLF_APIENTRYP qt_glGetPointerv_t)(GLenum pname, GLvoid **params);
+
+class QOpenGLDebugLoggerPrivate : public QObjectPrivate
+{
+ Q_DECLARE_PUBLIC(QOpenGLDebugLogger)
+public:
+ QOpenGLDebugLoggerPrivate();
+
+ void handleMessage(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *rawMessage);
+ void controlDebugMessages(QOpenGLDebugMessage::Sources sources,
+ QOpenGLDebugMessage::Types types,
+ QOpenGLDebugMessage::Severities severities,
+ const QVector<GLuint> &ids,
+ const QByteArray &callerName,
+ bool enable);
+ void _q_contextAboutToBeDestroyed();
+
+ qt_glDebugMessageControl_t glDebugMessageControl;
+ qt_glDebugMessageInsert_t glDebugMessageInsert;
+ qt_glDebugMessageCallback_t glDebugMessageCallback;
+ qt_glGetDebugMessageLog_t glGetDebugMessageLog;
+ qt_glPushDebugGroup_t glPushDebugGroup;
+ qt_glPopDebugGroup_t glPopDebugGroup;
+ qt_glGetPointerv_t glGetPointerv;
+
+ GLDEBUGPROC oldDebugCallbackFunction;
+ void *oldDebugCallbackParameter;
+ QOpenGLContext *context;
+ GLint maxMessageLength;
+ QOpenGLDebugLogger::LoggingMode loggingMode;
+ bool initialized : 1;
+ bool isLogging : 1;
+ bool debugWasEnabled : 1;
+ bool syncDebugWasEnabled : 1;
+};
+
+/*!
+ \internal
+*/
+QOpenGLDebugLoggerPrivate::QOpenGLDebugLoggerPrivate()
+ : glDebugMessageControl(0),
+ glDebugMessageInsert(0),
+ glDebugMessageCallback(0),
+ glGetDebugMessageLog(0),
+ glPushDebugGroup(0),
+ glPopDebugGroup(0),
+ oldDebugCallbackFunction(0),
+ context(0),
+ maxMessageLength(0),
+ loggingMode(QOpenGLDebugLogger::AsynchronousLogging),
+ initialized(false),
+ isLogging(false),
+ debugWasEnabled(false),
+ syncDebugWasEnabled(false)
+{
+}
+
+/*!
+ \internal
+*/
+void QOpenGLDebugLoggerPrivate::handleMessage(GLenum source,
+ GLenum type,
+ GLuint id,
+ GLenum severity,
+ GLsizei length,
+ const GLchar *rawMessage)
+{
+ if (oldDebugCallbackFunction)
+ oldDebugCallbackFunction(source, type, id, severity, length, rawMessage, oldDebugCallbackParameter);
+
+ QOpenGLDebugMessage message;
+
+ QOpenGLDebugMessagePrivate *messagePrivate = message.d.data();
+ messagePrivate->source = qt_messageSourceFromGL(source);
+ messagePrivate->type = qt_messageTypeFromGL(type);
+ messagePrivate->id = id;
+ messagePrivate->severity = qt_messageSeverityFromGL(severity);
+ // not passing the length to fromUtf8, as some bugged OpenGL drivers
+ // do not handle the length correctly. Just rely on the message to be NUL terminated.
+ messagePrivate->message = QString::fromUtf8(rawMessage);
+
+ Q_Q(QOpenGLDebugLogger);
+ emit q->messageLogged(message);
+}
+
+/*!
+ \internal
+*/
+void QOpenGLDebugLoggerPrivate::controlDebugMessages(QOpenGLDebugMessage::Sources sources,
+ QOpenGLDebugMessage::Types types,
+ QOpenGLDebugMessage::Severities severities,
+ const QVector<GLuint> &ids,
+ const QByteArray &callerName,
+ bool enable)
+{
+ if (!initialized) {
+ qWarning("QOpenGLDebugLogger::%s(): object must be initialized before enabling/disabling messages", callerName.constData());
+ return;
+ }
+ if (sources == QOpenGLDebugMessage::InvalidSource) {
+ qWarning("QOpenGLDebugLogger::%s(): invalid source specified", callerName.constData());
+ return;
+ }
+ if (types == QOpenGLDebugMessage::InvalidType) {
+ qWarning("QOpenGLDebugLogger::%s(): invalid type specified", callerName.constData());
+ return;
+ }
+ if (severities == QOpenGLDebugMessage::InvalidSeverity) {
+ qWarning("QOpenGLDebugLogger::%s(): invalid severity specified", callerName.constData());
+ return;
+ }
+
+ QVarLengthArray<GLenum, 8> glSources;
+ QVarLengthArray<GLenum, 8> glTypes;
+ QVarLengthArray<GLenum, 8> glSeverities;
+
+ if (ids.count() > 0) {
+ Q_ASSERT(severities == QOpenGLDebugMessage::AnySeverity);
+
+ // The GL_KHR_debug extension says:
+ //
+ // - If <count> is greater than zero, then <ids> is an array of <count>
+ // message IDs for the specified combination of <source> and <type>. In
+ // this case, if <source> or <type> is DONT_CARE, or <severity> is not
+ // DONT_CARE, the error INVALID_OPERATION is generated. If <count> is
+ // zero, the value if <ids> is ignored.
+ //
+ // This means we can't convert AnySource or AnyType into DONT_CARE, but we have to roll
+ // them into individual sources/types.
+
+ if (sources == QOpenGLDebugMessage::AnySource) {
+ sources = QOpenGLDebugMessage::InvalidSource;
+ for (uint i = 1; i <= QOpenGLDebugMessage::LastSource; i = i << 1)
+ sources |= QOpenGLDebugMessage::Source(i);
+ }
+
+ if (types == QOpenGLDebugMessage::AnyType) {
+ types = QOpenGLDebugMessage::InvalidType;
+ for (uint i = 1; i <= QOpenGLDebugMessage::LastType; i = i << 1)
+ types |= QOpenGLDebugMessage::Type(i);
+ }
+ }
+
+#define CONVERT_TO_GL_DEBUG_MESSAGE_CONTROL_PARAMETERS(type, source, target) \
+ if (source == QOpenGLDebugMessage::Any ## type) { \
+ target << GL_DONT_CARE; \
+ } else { \
+ for (uint i = 1; i <= QOpenGLDebugMessage::Last ## type; i = i << 1) \
+ if (source.testFlag(QOpenGLDebugMessage:: type (i))) \
+ target << qt_message ## type ## ToGL (QOpenGLDebugMessage:: type (i)); \
+ }
+
+ CONVERT_TO_GL_DEBUG_MESSAGE_CONTROL_PARAMETERS(Source, sources, glSources)
+ CONVERT_TO_GL_DEBUG_MESSAGE_CONTROL_PARAMETERS(Type, types, glTypes)
+ CONVERT_TO_GL_DEBUG_MESSAGE_CONTROL_PARAMETERS(Severity, severities, glSeverities)
+#undef CONVERT_TO_GL_DEBUG_MESSAGE_CONTROL_PARAMETERS
+
+ const GLsizei idCount = ids.count();
+ // The GL_KHR_debug extension says that if idCount is 0, idPtr must be ignored.
+ // Unfortunately, some bugged drivers do NOT ignore it, so pass NULL in case.
+ const GLuint * const idPtr = idCount ? ids.constData() : 0;
+
+ foreach (GLenum source, glSources)
+ foreach (GLenum type, glTypes)
+ foreach (GLenum severity, glSeverities)
+ glDebugMessageControl(source, type, severity, idCount, idPtr, GLboolean(enable));
+}
+
+/*!
+ \internal
+*/
+void QOpenGLDebugLoggerPrivate::_q_contextAboutToBeDestroyed()
+{
+ Q_Q(QOpenGLDebugLogger);
+ q->stopLogging();
+ initialized = false;
+}
+
+extern "C" {
+static void QOPENGLF_APIENTRY qt_opengl_debug_callback(GLenum source,
+ GLenum type,
+ GLuint id,
+ GLenum severity,
+ GLsizei length,
+ const GLchar *rawMessage,
+ GLvoid *userParam)
+{
+ QOpenGLDebugLoggerPrivate *loggerPrivate = static_cast<QOpenGLDebugLoggerPrivate *>(userParam);
+ loggerPrivate->handleMessage(source, type, id, severity, length, rawMessage);
+}
+}
+
+/*!
+ Constructs a new logger object with the given \a parent.
+
+ \note The object must be initialized before logging can happen.
+
+ \sa initialize()
+*/
+QOpenGLDebugLogger::QOpenGLDebugLogger(QObject *parent)
+ : QObject(*new QOpenGLDebugLoggerPrivate, parent)
+{
+ // QOpenGLDebugMessage is going to be mostly used as an argument
+ // of a cross thread connection, therefore let's ease the life for the users
+ // and register the type for them.
+ qRegisterMetaType<QOpenGLDebugMessage>();
+}
+
+/*!
+ Destroys the logger object.
+*/
+QOpenGLDebugLogger::~QOpenGLDebugLogger()
+{
+ stopLogging();
+}
+
+/*!
+ Initializes the object in the current OpenGL context. The context must
+ support the \c{GL_KHR_debug} extension for the initialization to succeed.
+ The object must be initialized before any logging can happen.
+
+ It is safe to call this function multiple times from the same context.
+
+ This function can also be used to change the context of a previously
+ initialized object; note that in this case the object must not be logging
+ when you call this function.
+
+ Returns true if the logger is successfully initialized; false otherwise.
+
+ \sa QOpenGLContext
+*/
+bool QOpenGLDebugLogger::initialize()
+{
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("QOpenGLDebugLogger::initialize(): no current OpenGL context found.");
+ return false;
+ }
+
+ Q_D(QOpenGLDebugLogger);
+ if (d->context == context) {
+ // context is non-NULL, d->context is non NULL only on successful initialization.
+ Q_ASSERT(d->initialized);
+ return true;
+ }
+
+ if (d->isLogging) {
+ qWarning("QOpenGLDebugLogger::initialize(): cannot initialize the object while logging. Please stop the logging first.");
+ return false;
+ }
+
+ if (d->context)
+ disconnect(d->context, SIGNAL(aboutToBeDestroyed()), this, SLOT(_q_contextAboutToBeDestroyed()));
+
+ d->initialized = false;
+ d->context = 0;
+
+ if (!context->hasExtension(QByteArrayLiteral("GL_KHR_debug")))
+ return false;
+
+ d->context = context;
+ connect(d->context, SIGNAL(aboutToBeDestroyed()), this, SLOT(_q_contextAboutToBeDestroyed()));
+
+#define GET_DEBUG_PROC_ADDRESS(procName) \
+ d->procName = reinterpret_cast< qt_ ## procName ## _t >( \
+ d->context->getProcAddress(QByteArrayLiteral( #procName )) \
+ );
+
+ GET_DEBUG_PROC_ADDRESS(glDebugMessageControl);
+ GET_DEBUG_PROC_ADDRESS(glDebugMessageInsert);
+ GET_DEBUG_PROC_ADDRESS(glDebugMessageCallback);
+ GET_DEBUG_PROC_ADDRESS(glGetDebugMessageLog);
+ GET_DEBUG_PROC_ADDRESS(glPushDebugGroup);
+ GET_DEBUG_PROC_ADDRESS(glPopDebugGroup);
+ GET_DEBUG_PROC_ADDRESS(glGetPointerv)
+#undef GET_DEBUG_PROC_ADDRESS
+
+ glGetIntegerv(GL_MAX_DEBUG_MESSAGE_LENGTH, &d->maxMessageLength);
+
+#ifndef QT_NO_DEBUG
+ if (!d->context->format().testOption(QSurfaceFormat::DebugContext)) {
+ qWarning("QOpenGLDebugLogger::initialize(): the current context is not a debug context:\n"
+ " this means that the GL may not generate any debug output at all.\n"
+ " To avoid this warning, try creating the context with the\n"
+ " QSurfaceFormat::DebugContext surface format option.");
+ }
+#endif // QT_NO_DEBUG
+
+ d->initialized = true;
+ return true;
+}
+
+/*!
+ Returns true if this object is currently logging, false otherwise.
+
+ \sa startLogging()
+*/
+bool QOpenGLDebugLogger::isLogging() const
+{
+ Q_D(const QOpenGLDebugLogger);
+ return d->isLogging;
+}
+
+/*!
+ Starts logging messages coming from the OpenGL server. When a new message
+ is received, the signal messageLogged() is emitted, carrying the logged
+ message as argument.
+
+ \a loggingMode specifies whether the logging must be asynchronous (the default)
+ or synchronous.
+
+ QOpenGLDebugLogger will record the values of \c{GL_DEBUG_OUTPUT} and
+ \c{GL_DEBUG_OUTPUT_SYNCHRONOUS} when logging is started, and set them back
+ when logging is stopped. Moreover, any user-defined OpenGL debug callback
+ installed when this function is invoked will be restored when logging is
+ stopped; QOpenGLDebugLogger will ensure that the pre-existing callback will
+ still be invoked when logging.
+
+ \note It's not possible to change the logging mode without stopping and
+ starting logging again. This might change in a future version of Qt.
+
+ \note The object must be initialized before logging can happen.
+
+ \sa stopLogging(), initialize()
+*/
+void QOpenGLDebugLogger::startLogging(QOpenGLDebugLogger::LoggingMode loggingMode)
+{
+ Q_D(QOpenGLDebugLogger);
+ if (!d->initialized) {
+ qWarning("QOpenGLDebugLogger::startLogging(): object must be initialized before logging can start");
+ return;
+ }
+ if (d->isLogging) {
+ qWarning("QOpenGLDebugLogger::startLogging(): this object is already logging");
+ return;
+ }
+
+ d->isLogging = true;
+ d->loggingMode = loggingMode;
+
+ d->glGetPointerv(GL_DEBUG_CALLBACK_FUNCTION, reinterpret_cast<void **>(&d->oldDebugCallbackFunction));
+ d->glGetPointerv(GL_DEBUG_CALLBACK_USER_PARAM, &d->oldDebugCallbackParameter);
+
+ d->glDebugMessageCallback(&qt_opengl_debug_callback, d);
+
+ d->debugWasEnabled = glIsEnabled(GL_DEBUG_OUTPUT);
+ d->syncDebugWasEnabled = glIsEnabled(GL_DEBUG_OUTPUT_SYNCHRONOUS);
+
+ if (d->loggingMode == SynchronousLogging)
+ glEnable(GL_DEBUG_OUTPUT_SYNCHRONOUS);
+ else
+ glDisable(GL_DEBUG_OUTPUT_SYNCHRONOUS);
+
+ glEnable(GL_DEBUG_OUTPUT);
+}
+
+/*!
+ Returns the logging mode of the object.
+
+ \sa startLogging()
+*/
+QOpenGLDebugLogger::LoggingMode QOpenGLDebugLogger::loggingMode() const
+{
+ Q_D(const QOpenGLDebugLogger);
+ return d->loggingMode;
+}
+
+/*!
+ Stops logging messages from the OpenGL server.
+
+ \sa startLogging()
+*/
+void QOpenGLDebugLogger::stopLogging()
+{
+ Q_D(QOpenGLDebugLogger);
+ if (!d->isLogging)
+ return;
+
+ d->isLogging = false;
+
+ d->glDebugMessageCallback(d->oldDebugCallbackFunction, d->oldDebugCallbackParameter);
+
+ if (!d->debugWasEnabled)
+ glDisable(GL_DEBUG_OUTPUT);
+
+ if (d->syncDebugWasEnabled)
+ glEnable(GL_DEBUG_OUTPUT_SYNCHRONOUS);
+ else
+ glDisable(GL_DEBUG_OUTPUT_SYNCHRONOUS);
+}
+
+/*!
+ Inserts the message \a debugMessage into the OpenGL debug log. This provides
+ a way for applications or libraries to insert custom messages that can
+ ease the debugging of OpenGL applications.
+
+ \note \a debugMessage must have QOpenGLDebugMessage::ApplicationSource or
+ QOpenGLDebugMessage::ThirdPartySource as its source, and a valid
+ type and severity, otherwise it will not be inserted into the log.
+
+ \note The object must be initialized before logging can happen.
+
+ \sa initialize()
+*/
+void QOpenGLDebugLogger::logMessage(const QOpenGLDebugMessage &debugMessage)
+{
+ Q_D(QOpenGLDebugLogger);
+ if (!d->initialized) {
+ qWarning("QOpenGLDebugLogger::logMessage(): object must be initialized before logging messages");
+ return;
+ }
+ if (debugMessage.source() != QOpenGLDebugMessage::ApplicationSource
+ && debugMessage.source() != QOpenGLDebugMessage::ThirdPartySource) {
+ qWarning("QOpenGLDebugLogger::logMessage(): using a message source different from ApplicationSource\n"
+ " or ThirdPartySource is not supported by GL_KHR_debug. The message will not be logged.");
+ return;
+ }
+ if (debugMessage.type() == QOpenGLDebugMessage::InvalidType
+ || debugMessage.type() == QOpenGLDebugMessage::AnyType
+ || debugMessage.severity() == QOpenGLDebugMessage::InvalidSeverity
+ || debugMessage.severity() == QOpenGLDebugMessage::AnySeverity) {
+ qWarning("QOpenGLDebugLogger::logMessage(): the message has a non-valid type and/or severity. The message will not be logged.");
+ return;
+ }
+
+ const GLenum source = qt_messageSourceToGL(debugMessage.source());
+ const GLenum type = qt_messageTypeToGL(debugMessage.type());
+ const GLenum severity = qt_messageSeverityToGL(debugMessage.severity());
+ QByteArray rawMessage = debugMessage.message().toUtf8();
+ rawMessage.append('\0');
+
+ if (rawMessage.length() > d->maxMessageLength) {
+ qWarning("QOpenGLDebugLogger::logMessage(): message too long, truncating it\n"
+ " (%d bytes long, but the GL accepts up to %d bytes)", rawMessage.length(), d->maxMessageLength);
+ rawMessage.resize(d->maxMessageLength - 1);
+ rawMessage.append('\0');
+ }
+
+ // Don't pass rawMessage.length(), as unfortunately bugged
+ // OpenGL drivers will eat the trailing NUL in the message. Just rely
+ // on the message being NUL terminated.
+ d->glDebugMessageInsert(source,
+ type,
+ debugMessage.id(),
+ severity,
+ -1,
+ rawMessage.constData());
+}
+
+/*!
+ Pushes a debug group with name \a name, id \a id, and source \a source onto
+ the debug groups stack. If the group is successfully pushed, OpenGL will
+ automatically log a message with message \a name, id \a id, source \a
+ source, type QOpenGLDebugMessage::GroupPushType and severity
+ QOpenGLDebugMessage::NotificationSeverity.
+
+ The newly pushed group will inherit the same filtering settings of the
+ group that was on the top of the stack; that is, the filtering will not be
+ changed by pushing a new group.
+
+ \note The \a source must either be QOpenGLDebugMessage::ApplicationSource or
+ QOpenGLDebugMessage::ThirdPartySource, otherwise the group will not be pushed.
+
+ \note The object must be initialized before managing debug groups.
+
+ \sa popGroup(), enableMessages(), disableMessages()
+*/
+void QOpenGLDebugLogger::pushGroup(const QString &name, GLuint id, QOpenGLDebugMessage::Source source)
+{
+ Q_D(QOpenGLDebugLogger);
+ if (!d->initialized) {
+ qWarning("QOpenGLDebugLogger::pushGroup(): object must be initialized before pushing a debug group");
+ return;
+ }
+ if (source != QOpenGLDebugMessage::ApplicationSource
+ && source != QOpenGLDebugMessage::ThirdPartySource) {
+ qWarning("QOpenGLDebugLogger::pushGroup(): using a source different from ApplicationSource\n"
+ " or ThirdPartySource is not supported by GL_KHR_debug. The group will not be pushed.");
+ return;
+ }
+
+ QByteArray rawName = name.toUtf8();
+ rawName.append('\0');
+ if (rawName.length() > d->maxMessageLength) {
+ qWarning("QOpenGLDebugLogger::pushGroup(): group name too long, truncating it\n"
+ " (%d bytes long, but the GL accepts up to %d bytes)", rawName.length(), d->maxMessageLength);
+ rawName.resize(d->maxMessageLength - 1);
+ rawName.append('\0');
+ }
+
+ // Don't pass rawMessage.length(), as unfortunately bugged
+ // OpenGL drivers will eat the trailing NUL in the name. Just rely
+ // on the name being NUL terminated.
+ d->glPushDebugGroup(qt_messageSourceToGL(source), id, -1, rawName.constData());
+}
+
+/*!
+ Pops the topmost debug group from the debug groups stack. If the group is
+ successfully popped, OpenGL will automatically log a message with message,
+ id and source matching those of the popped group, type
+ QOpenGLDebugMessage::GroupPopType and severity
+ QOpenGLDebugMessage::NotificationSeverity.
+
+ Popping a debug group will restore the message filtering settings of the
+ group that becomes the top of the debug groups stack.
+
+ \note The object must be initialized before managing debug groups.
+
+ \sa pushGroup()
+*/
+void QOpenGLDebugLogger::popGroup()
+{
+ Q_D(QOpenGLDebugLogger);
+ if (!d->initialized) {
+ qWarning("QOpenGLDebugLogger::pushGroup(): object must be initialized before popping a debug group");
+ return;
+ }
+
+ d->glPopDebugGroup();
+}
+
+/*!
+ Enables the logging of messages from the given \a sources, of the given \a
+ types and with the given \a severities and any message id.
+
+ The logging will be enabled in the current control group.
+
+ \sa disableMessages(), pushGroup(), popGroup()
+*/
+void QOpenGLDebugLogger::enableMessages(QOpenGLDebugMessage::Sources sources,
+ QOpenGLDebugMessage::Types types,
+ QOpenGLDebugMessage::Severities severities)
+{
+ Q_D(QOpenGLDebugLogger);
+ d->controlDebugMessages(sources,
+ types,
+ severities,
+ QVector<GLuint>(),
+ QByteArrayLiteral("enableMessages"),
+ true);
+}
+
+/*!
+ Enables the logging of messages with the given \a ids, from the given \a
+ sources and of the given \a types and any severity.
+
+ The logging will be enabled in the current control group.
+
+ \sa disableMessages(), pushGroup(), popGroup()
+*/
+void QOpenGLDebugLogger::enableMessages(const QVector<GLuint> &ids,
+ QOpenGLDebugMessage::Sources sources,
+ QOpenGLDebugMessage::Types types)
+{
+ Q_D(QOpenGLDebugLogger);
+ d->controlDebugMessages(sources,
+ types,
+ QOpenGLDebugMessage::AnySeverity,
+ ids,
+ QByteArrayLiteral("enableMessages"),
+ true);
+}
+
+/*!
+ Disables the logging of messages with the given \a sources, of the given \a
+ types and with the given \a severities and any message id.
+
+ The logging will be disabled in the current control group.
+
+ \sa enableMessages(), pushGroup(), popGroup()
+*/
+void QOpenGLDebugLogger::disableMessages(QOpenGLDebugMessage::Sources sources,
+ QOpenGLDebugMessage::Types types,
+ QOpenGLDebugMessage::Severities severities)
+{
+ Q_D(QOpenGLDebugLogger);
+ d->controlDebugMessages(sources,
+ types,
+ severities,
+ QVector<GLuint>(),
+ QByteArrayLiteral("disableMessages"),
+ false);
+}
+
+/*!
+ Disables the logging of messages with the given \a ids, from the given \a
+ sources and of the given \a types and any severity.
+
+ The logging will be disabled in the current control group.
+
+ \sa enableMessages(), pushGroup(), popGroup()
+*/
+void QOpenGLDebugLogger::disableMessages(const QVector<GLuint> &ids,
+ QOpenGLDebugMessage::Sources sources,
+ QOpenGLDebugMessage::Types types)
+{
+ Q_D(QOpenGLDebugLogger);
+ d->controlDebugMessages(sources,
+ types,
+ QOpenGLDebugMessage::AnySeverity,
+ ids,
+ QByteArrayLiteral("disableMessages"),
+ false);
+}
+
+/*!
+ Reads all the available messages in the OpenGL internal debug log and
+ returns them. Moreover, this function will clear the internal debug log,
+ so that subsequent invocations will not return messages that were
+ already returned.
+
+ \sa startLogging()
+*/
+QList<QOpenGLDebugMessage> QOpenGLDebugLogger::loggedMessages() const
+{
+ Q_D(const QOpenGLDebugLogger);
+ if (!d->initialized) {
+ qWarning("QOpenGLDebugLogger::loggedMessages(): object must be initialized before reading logged messages");
+ return QList<QOpenGLDebugMessage>();
+ }
+
+ static const GLuint maxMessageCount = 128;
+ GLuint messagesRead;
+ GLenum messageSources[maxMessageCount];
+ GLenum messageTypes[maxMessageCount];
+ GLuint messageIds[maxMessageCount];
+ GLenum messageSeverities[maxMessageCount];
+ GLsizei messageLengths[maxMessageCount];
+
+ QByteArray messagesBuffer;
+ messagesBuffer.resize(maxMessageCount * d->maxMessageLength);
+
+ QList<QOpenGLDebugMessage> messages;
+ do {
+ messagesRead = d->glGetDebugMessageLog(maxMessageCount,
+ GLsizei(messagesBuffer.size()),
+ messageSources,
+ messageTypes,
+ messageIds,
+ messageSeverities,
+ messageLengths,
+ messagesBuffer.data());
+
+ const char *messagesBufferPtr = messagesBuffer.constData();
+ for (GLuint i = 0; i < messagesRead; ++i) {
+ QOpenGLDebugMessage message;
+
+ QOpenGLDebugMessagePrivate *messagePrivate = message.d.data();
+ messagePrivate->source = qt_messageSourceFromGL(messageSources[i]);
+ messagePrivate->type = qt_messageTypeFromGL(messageTypes[i]);
+ messagePrivate->id = messageIds[i];
+ messagePrivate->severity = qt_messageSeverityFromGL(messageSeverities[i]);
+ messagePrivate->message = QString::fromUtf8(messagesBufferPtr, messageLengths[i] - 1);
+
+ messagesBufferPtr += messageLengths[i];
+ messages << message;
+ }
+ } while (messagesRead == maxMessageCount);
+
+ return messages;
+}
+
+/*!
+ \fn void QOpenGLDebugLogger::messageLogged(const QOpenGLDebugMessage &debugMessage)
+
+ This signal is emitted when a debug message (wrapped by the \a debugMessage
+ argument) is logged from the OpenGL server.
+
+ Depending on the OpenGL implementation, this signal can be emitted
+ from other threads than the one(s) the receiver(s) lives in, and even
+ different from the thread the QOpenGLContext in which this object has
+ been initialized lives in. Moreover, the signal could be emitted from
+ multiple threads at the same time. This is normally not a problem,
+ as Qt will utilize a queued connection for cross-thread signal emissions,
+ but if you force the connection type to Direct then you must be aware of
+ the potential races in the slots connected to this signal.
+
+ If logging have been started in SynchronousLogging mode, OpenGL guarantees
+ that this signal will be emitted from the same thread the QOpenGLContext
+ has been bound to, and no concurrent invocations will ever happen.
+
+ \note Logging must have been started, or this signal will not be emitted.
+
+ \sa startLogging()
+*/
+
+/*!
+ Returns the maximum supported length, in bytes, for the text of the messages
+ passed to logMessage(). This is also the maximum length of a debug group
+ name, as pushing or popping groups will automatically log a message with
+ the debug group name as the message text.
+
+ If a message text is too long, it will be automatically truncated by
+ QOpenGLDebugLogger.
+
+ \note Message texts are encoded in UTF-8 when they get passed to OpenGL, so
+ their size in bytes does not usually match the amount of UTF-16 code units,
+ as returned f.i. by QString::length(). (It does if the message contains
+ 7-bit ASCII only data, which is typical for debug messages.)
+*/
+qint64 QOpenGLDebugLogger::maximumMessageLength() const
+{
+ Q_D(const QOpenGLDebugLogger);
+ if (!d->initialized) {
+ qWarning("QOpenGLDebugLogger::maximumMessageLength(): object must be initialized before reading the maximum message length");
+ return -1;
+ }
+ return d->maxMessageLength;
+}
+
+
+QT_END_NAMESPACE
+
+#include "moc_qopengldebug.cpp"
diff --git a/src/gui/opengl/qopengldebug.h b/src/gui/opengl/qopengldebug.h
new file mode 100644
index 0000000000..5f0c1a52db
--- /dev/null
+++ b/src/gui/opengl/qopengldebug.h
@@ -0,0 +1,220 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QOPENGLDEBUG_H
+#define QOPENGLDEBUG_H
+
+#include <QtCore/qglobal.h>
+
+#ifndef QT_NO_OPENGL
+
+#include <QtCore/qshareddata.h>
+#include <QtCore/qflags.h>
+#include <QtCore/qlist.h>
+#include <QtCore/qvector.h>
+#include <QtCore/qmetatype.h>
+#include <QtCore/qdebug.h>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class QOpenGLDebugLogger;
+class QOpenGLDebugLoggerPrivate;
+class QOpenGLDebugMessagePrivate;
+
+class Q_GUI_EXPORT QOpenGLDebugMessage
+{
+public:
+ enum Source {
+ InvalidSource = 0x00000000,
+ APISource = 0x00000001,
+ WindowSystemSource = 0x00000002,
+ ShaderCompilerSource = 0x00000004,
+ ThirdPartySource = 0x00000008,
+ ApplicationSource = 0x00000010,
+ OtherSource = 0x00000020,
+ LastSource = OtherSource, // private API
+ AnySource = 0xffffffff
+ };
+ Q_DECLARE_FLAGS(Sources, Source)
+
+ enum Type {
+ InvalidType = 0x00000000,
+ ErrorType = 0x00000001,
+ DeprecatedBehaviorType = 0x00000002,
+ UndefinedBehaviorType = 0x00000004,
+ PortabilityType = 0x00000008,
+ PerformanceType = 0x00000010,
+ OtherType = 0x00000020,
+ MarkerType = 0x00000040,
+ GroupPushType = 0x00000080,
+ GroupPopType = 0x00000100,
+ LastType = GroupPopType, // private API
+ AnyType = 0xffffffff
+ };
+ Q_DECLARE_FLAGS(Types, Type)
+
+ enum Severity {
+ InvalidSeverity = 0x00000000,
+ HighSeverity = 0x00000001,
+ MediumSeverity = 0x00000002,
+ LowSeverity = 0x00000004,
+ NotificationSeverity = 0x00000008,
+ LastSeverity = NotificationSeverity, // private API
+ AnySeverity = 0xffffffff
+ };
+ Q_DECLARE_FLAGS(Severities, Severity)
+
+ QOpenGLDebugMessage();
+ QOpenGLDebugMessage(const QOpenGLDebugMessage &debugMessage);
+ ~QOpenGLDebugMessage();
+
+ QOpenGLDebugMessage &operator=(const QOpenGLDebugMessage &debugMessage);
+#ifdef Q_COMPILER_RVALUE_REFS
+ inline QOpenGLDebugMessage &operator=(QOpenGLDebugMessage &&debugMessage)
+ { d.swap(debugMessage.d); return *this; }
+#endif
+ inline void swap(QOpenGLDebugMessage &debugMessage) { d.swap(debugMessage.d); }
+
+ Source source() const;
+ Type type() const;
+ Severity severity() const;
+ GLuint id() const;
+ QString message() const;
+
+ static QOpenGLDebugMessage createApplicationMessage(const QString &text,
+ GLuint id = 0,
+ Severity severity = NotificationSeverity,
+ Type type = OtherType);
+ static QOpenGLDebugMessage createThirdPartyMessage(const QString &text,
+ GLuint id = 0,
+ Severity severity = NotificationSeverity,
+ Type type = OtherType);
+
+ bool operator==(const QOpenGLDebugMessage &debugMessage) const;
+ inline bool operator!=(const QOpenGLDebugMessage &debugMessage) const { return !operator==(debugMessage); }
+
+private:
+ friend class QOpenGLDebugLogger;
+ friend class QOpenGLDebugLoggerPrivate;
+ QSharedDataPointer<QOpenGLDebugMessagePrivate> d;
+};
+
+Q_DECLARE_SHARED(QOpenGLDebugMessage)
+Q_DECLARE_OPERATORS_FOR_FLAGS(QOpenGLDebugMessage::Sources)
+Q_DECLARE_OPERATORS_FOR_FLAGS(QOpenGLDebugMessage::Types)
+Q_DECLARE_OPERATORS_FOR_FLAGS(QOpenGLDebugMessage::Severities)
+
+#ifndef QT_NO_DEBUG_STREAM
+Q_GUI_EXPORT QDebug operator<<(QDebug debug, const QOpenGLDebugMessage &message);
+Q_GUI_EXPORT QDebug operator<<(QDebug debug, QOpenGLDebugMessage::Source source);
+Q_GUI_EXPORT QDebug operator<<(QDebug debug, QOpenGLDebugMessage::Type type);
+Q_GUI_EXPORT QDebug operator<<(QDebug debug, QOpenGLDebugMessage::Severity severity);
+#endif
+
+class QOpenGLDebugLoggerPrivate;
+
+class Q_GUI_EXPORT QOpenGLDebugLogger : public QObject
+{
+ Q_OBJECT
+ Q_ENUMS(LoggingMode)
+ Q_PROPERTY(LoggingMode loggingMode READ loggingMode)
+
+public:
+ enum LoggingMode {
+ AsynchronousLogging,
+ SynchronousLogging
+ };
+
+ explicit QOpenGLDebugLogger(QObject *parent = 0);
+ ~QOpenGLDebugLogger();
+
+ bool initialize();
+
+ bool isLogging() const;
+ LoggingMode loggingMode() const;
+
+ qint64 maximumMessageLength() const;
+
+ void pushGroup(const QString &name,
+ GLuint id = 0,
+ QOpenGLDebugMessage::Source source = QOpenGLDebugMessage::ApplicationSource);
+ void popGroup();
+
+ void enableMessages(QOpenGLDebugMessage::Sources sources = QOpenGLDebugMessage::AnySource,
+ QOpenGLDebugMessage::Types types = QOpenGLDebugMessage::AnyType,
+ QOpenGLDebugMessage::Severities severities = QOpenGLDebugMessage::AnySeverity);
+
+ void enableMessages(const QVector<GLuint> &ids,
+ QOpenGLDebugMessage::Sources sources = QOpenGLDebugMessage::AnySource,
+ QOpenGLDebugMessage::Types types = QOpenGLDebugMessage::AnyType);
+
+ void disableMessages(QOpenGLDebugMessage::Sources sources = QOpenGLDebugMessage::AnySource,
+ QOpenGLDebugMessage::Types types = QOpenGLDebugMessage::AnyType,
+ QOpenGLDebugMessage::Severities severities = QOpenGLDebugMessage::AnySeverity);
+
+ void disableMessages(const QVector<GLuint> &ids,
+ QOpenGLDebugMessage::Sources sources = QOpenGLDebugMessage::AnySource,
+ QOpenGLDebugMessage::Types types = QOpenGLDebugMessage::AnyType);
+
+ QList<QOpenGLDebugMessage> loggedMessages() const;
+
+public Q_SLOTS:
+ void logMessage(const QOpenGLDebugMessage &debugMessage);
+ void startLogging(LoggingMode loggingMode = AsynchronousLogging);
+ void stopLogging();
+
+Q_SIGNALS:
+ void messageLogged(const QOpenGLDebugMessage &debugMessage);
+
+private:
+ Q_DISABLE_COPY(QOpenGLDebugLogger)
+ Q_DECLARE_PRIVATE(QOpenGLDebugLogger)
+ Q_PRIVATE_SLOT(d_func(), void _q_contextAboutToBeDestroyed())
+};
+
+QT_END_NAMESPACE
+
+Q_DECLARE_METATYPE(QOpenGLDebugMessage)
+
+#endif // QT_NO_OPENGL
+
+#endif // QOPENGLDEBUG_H
diff --git a/src/gui/opengl/qopenglengineshadermanager_p.h b/src/gui/opengl/qopenglengineshadermanager_p.h
index 462ffbf703..49c03a7fee 100644
--- a/src/gui/opengl/qopenglengineshadermanager_p.h
+++ b/src/gui/opengl/qopenglengineshadermanager_p.h
@@ -228,8 +228,6 @@
#include <private/qopenglcontext_p.h>
#include <private/qopenglcustomshaderstage_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -508,6 +506,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QOPENGLENGINE_SHADER_MANAGER_H
diff --git a/src/gui/opengl/qopenglengineshadersource_p.h b/src/gui/opengl/qopenglengineshadersource_p.h
index f1b1dbe5a6..869bd057f2 100644
--- a/src/gui/opengl/qopenglengineshadersource_p.h
+++ b/src/gui/opengl/qopenglengineshadersource_p.h
@@ -56,8 +56,6 @@
#include "qopenglengineshadermanager_p.h"
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -523,6 +521,4 @@ static const char* const qopenglslRgbMaskFragmentShaderPass2 = "\n\
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // GLGC_SHADER_SOURCE_H
diff --git a/src/gui/opengl/qopengles2ext.h b/src/gui/opengl/qopengles2ext.h
index 61bfb595cc..5926d5bbd5 100644
--- a/src/gui/opengl/qopengles2ext.h
+++ b/src/gui/opengl/qopengles2ext.h
@@ -3,10 +3,11 @@
#if 0
#pragma qt_no_master_include
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
-/* $Revision: 18481 $ on $Date:: 2012-07-11 18:07:26 -0700 #$ */
+/* $Revision: 20771 $ on $Date:: 2013-03-05 18:53:24 -0800 #$ */
#ifdef __cplusplus
extern "C" {
@@ -99,7 +100,23 @@ typedef void* GLeglImageOES;
#endif
/* GL_OES_required_internalformat */
-/* No new tokens introduced by this extension. */
+#ifndef GL_OES_required_internalformat
+#define GL_ALPHA8_OES 0x803C
+#define GL_DEPTH_COMPONENT16_OES 0x81A5
+/* reuse GL_DEPTH_COMPONENT24_OES */
+/* reuse GL_DEPTH24_STENCIL8_OES */
+/* reuse GL_DEPTH_COMPONENT32_OES */
+#define GL_LUMINANCE4_ALPHA4_OES 0x8043
+#define GL_LUMINANCE8_ALPHA8_OES 0x8045
+#define GL_LUMINANCE8_OES 0x8040
+#define GL_RGBA4_OES 0x8056
+#define GL_RGB5_A1_OES 0x8057
+#define GL_RGB565_OES 0x8D62
+/* reuse GL_RGB8_OES */
+/* reuse GL_RGBA8_OES */
+/* reuse GL_RGB10_EXT */
+/* reuse GL_RGB10_A2_EXT */
+#endif
/* GL_OES_rgb8_rgba8 */
#ifndef GL_OES_rgb8_rgba8
@@ -122,6 +139,10 @@ typedef void* GLeglImageOES;
#define GL_STENCIL_INDEX4_OES 0x8D47
#endif
+#ifndef GL_OES_surfaceless_context
+#define GL_FRAMEBUFFER_UNDEFINED_OES 0x8219
+#endif
+
/* GL_OES_texture_3D */
#ifndef GL_OES_texture_3D
#define GL_TEXTURE_WRAP_R_OES 0x8072
@@ -164,6 +185,85 @@ typedef void* GLeglImageOES;
#endif
/*------------------------------------------------------------------------*
+ * KHR extension tokens
+ *------------------------------------------------------------------------*/
+
+#ifndef GL_KHR_debug
+typedef void (GL_APIENTRYP GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,GLvoid *userParam);
+#define GL_DEBUG_OUTPUT_SYNCHRONOUS 0x8242
+#define GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH 0x8243
+#define GL_DEBUG_CALLBACK_FUNCTION 0x8244
+#define GL_DEBUG_CALLBACK_USER_PARAM 0x8245
+#define GL_DEBUG_SOURCE_API 0x8246
+#define GL_DEBUG_SOURCE_WINDOW_SYSTEM 0x8247
+#define GL_DEBUG_SOURCE_SHADER_COMPILER 0x8248
+#define GL_DEBUG_SOURCE_THIRD_PARTY 0x8249
+#define GL_DEBUG_SOURCE_APPLICATION 0x824A
+#define GL_DEBUG_SOURCE_OTHER 0x824B
+#define GL_DEBUG_TYPE_ERROR 0x824C
+#define GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR 0x824D
+#define GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR 0x824E
+#define GL_DEBUG_TYPE_PORTABILITY 0x824F
+#define GL_DEBUG_TYPE_PERFORMANCE 0x8250
+#define GL_DEBUG_TYPE_OTHER 0x8251
+#define GL_DEBUG_TYPE_MARKER 0x8268
+#define GL_DEBUG_TYPE_PUSH_GROUP 0x8269
+#define GL_DEBUG_TYPE_POP_GROUP 0x826A
+#define GL_DEBUG_SEVERITY_NOTIFICATION 0x826B
+#define GL_MAX_DEBUG_GROUP_STACK_DEPTH 0x826C
+#define GL_DEBUG_GROUP_STACK_DEPTH 0x826D
+#define GL_BUFFER 0x82E0
+#define GL_SHADER 0x82E1
+#define GL_PROGRAM 0x82E2
+#define GL_QUERY 0x82E3
+/* PROGRAM_PIPELINE only in GL */
+#define GL_SAMPLER 0x82E6
+/* DISPLAY_LIST only in GL */
+#define GL_MAX_LABEL_LENGTH 0x82E8
+#define GL_MAX_DEBUG_MESSAGE_LENGTH 0x9143
+#define GL_MAX_DEBUG_LOGGED_MESSAGES 0x9144
+#define GL_DEBUG_LOGGED_MESSAGES 0x9145
+#define GL_DEBUG_SEVERITY_HIGH 0x9146
+#define GL_DEBUG_SEVERITY_MEDIUM 0x9147
+#define GL_DEBUG_SEVERITY_LOW 0x9148
+#define GL_DEBUG_OUTPUT 0x92E0
+#define GL_CONTEXT_FLAG_DEBUG_BIT 0x00000002
+#define GL_STACK_OVERFLOW 0x0503
+#define GL_STACK_UNDERFLOW 0x0504
+#endif
+
+#ifndef GL_KHR_texture_compression_astc_ldr
+#define GL_COMPRESSED_RGBA_ASTC_4x4_KHR 0x93B0
+#define GL_COMPRESSED_RGBA_ASTC_5x4_KHR 0x93B1
+#define GL_COMPRESSED_RGBA_ASTC_5x5_KHR 0x93B2
+#define GL_COMPRESSED_RGBA_ASTC_6x5_KHR 0x93B3
+#define GL_COMPRESSED_RGBA_ASTC_6x6_KHR 0x93B4
+#define GL_COMPRESSED_RGBA_ASTC_8x5_KHR 0x93B5
+#define GL_COMPRESSED_RGBA_ASTC_8x6_KHR 0x93B6
+#define GL_COMPRESSED_RGBA_ASTC_8x8_KHR 0x93B7
+#define GL_COMPRESSED_RGBA_ASTC_10x5_KHR 0x93B8
+#define GL_COMPRESSED_RGBA_ASTC_10x6_KHR 0x93B9
+#define GL_COMPRESSED_RGBA_ASTC_10x8_KHR 0x93BA
+#define GL_COMPRESSED_RGBA_ASTC_10x10_KHR 0x93BB
+#define GL_COMPRESSED_RGBA_ASTC_12x10_KHR 0x93BC
+#define GL_COMPRESSED_RGBA_ASTC_12x12_KHR 0x93BD
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR 0x93D0
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR 0x93D1
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR 0x93D2
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR 0x93D3
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR 0x93D4
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR 0x93D5
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR 0x93D6
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR 0x93D7
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR 0x93D8
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x6_KHR 0x93D9
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x8_KHR 0x93DA
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR 0x93DB
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x10_KHR 0x93DC
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR 0x93DD
+#endif
+
+/*------------------------------------------------------------------------*
* AMD extension tokens
*------------------------------------------------------------------------*/
@@ -200,6 +300,18 @@ typedef void* GLeglImageOES;
* ANGLE extension tokens
*------------------------------------------------------------------------*/
+/* GL_ANGLE_depth_texture */
+#ifndef GL_ANGLE_depth_texture
+#define GL_DEPTH_COMPONENT 0x1902
+#define GL_DEPTH_STENCIL_OES 0x84F9
+#define GL_UNSIGNED_SHORT 0x1403
+#define GL_UNSIGNED_INT 0x1405
+#define GL_UNSIGNED_INT_24_8_OES 0x84FA
+#define GL_DEPTH_COMPONENT16 0x81A5
+#define GL_DEPTH_COMPONENT32_OES 0x81A7
+#define GL_DEPTH24_STENCIL8_OES 0x88F0
+#endif
+
/* GL_ANGLE_framebuffer_blit */
#ifndef GL_ANGLE_framebuffer_blit
#define GL_READ_FRAMEBUFFER_ANGLE 0x8CA8
@@ -216,33 +328,38 @@ typedef void* GLeglImageOES;
#endif
/* GL_ANGLE_instanced_arrays */
-#ifndef GL_ANGLE_instanced_arrays
+#ifndef GL_ANGLE_instanced_arrays
#define GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE 0x88FE
#endif
/* GL_ANGLE_pack_reverse_row_order */
-#ifndef GL_ANGLE_pack_reverse_row_order
+#ifndef GL_ANGLE_pack_reverse_row_order
#define GL_PACK_REVERSE_ROW_ORDER_ANGLE 0x93A4
#endif
+/* GL_ANGLE_program_binary */
+#ifndef GL_ANGLE_program_binary
+#define GL_PROGRAM_BINARY_ANGLE 0x93A6
+#endif
+
/* GL_ANGLE_texture_compression_dxt3 */
-#ifndef GL_ANGLE_texture_compression_dxt3
+#ifndef GL_ANGLE_texture_compression_dxt3
#define GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE 0x83F2
#endif
/* GL_ANGLE_texture_compression_dxt5 */
-#ifndef GL_ANGLE_texture_compression_dxt5
+#ifndef GL_ANGLE_texture_compression_dxt5
#define GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE 0x83F3
#endif
/* GL_ANGLE_texture_usage */
-#ifndef GL_ANGLE_texture_usage
+#ifndef GL_ANGLE_texture_usage
#define GL_TEXTURE_USAGE_ANGLE 0x93A2
#define GL_FRAMEBUFFER_ATTACHMENT_ANGLE 0x93A3
#endif
/* GL_ANGLE_translated_shader_source */
-#ifndef GL_ANGLE_translated_shader_source
+#ifndef GL_ANGLE_translated_shader_source
#define GL_TRANSLATED_SHADER_SOURCE_LENGTH_ANGLE 0x93A0
#endif
@@ -250,12 +367,8 @@ typedef void* GLeglImageOES;
* APPLE extension tokens
*------------------------------------------------------------------------*/
-/* GL_APPLE_rgb_422 */
-#ifndef GL_APPLE_rgb_422
-#define GL_RGB_422_APPLE 0x8A1F
-#define GL_UNSIGNED_SHORT_8_8_APPLE 0x85BA
-#define GL_UNSIGNED_SHORT_8_8_REV_APPLE 0x85BB
-#endif
+/* GL_APPLE_copy_texture_levels */
+/* No new tokens introduced by this extension. */
/* GL_APPLE_framebuffer_multisample */
#ifndef GL_APPLE_framebuffer_multisample
@@ -268,6 +381,47 @@ typedef void* GLeglImageOES;
#define GL_READ_FRAMEBUFFER_BINDING_APPLE 0x8CAA
#endif
+/* GL_APPLE_rgb_422 */
+#ifndef GL_APPLE_rgb_422
+#define GL_RGB_422_APPLE 0x8A1F
+#define GL_UNSIGNED_SHORT_8_8_APPLE 0x85BA
+#define GL_UNSIGNED_SHORT_8_8_REV_APPLE 0x85BB
+#endif
+
+/* GL_APPLE_sync */
+#ifndef GL_APPLE_sync
+
+#ifndef __gl3_h_
+/* These types are defined with reference to <inttypes.h>
+ * in the Apple extension spec, but here we use the Khronos
+ * portable types in khrplatform.h, and assume those types
+ * are always defined.
+ * If any other extensions using these types are defined,
+ * the typedefs must move out of this block and be shared.
+ */
+typedef khronos_int64_t GLint64;
+typedef khronos_uint64_t GLuint64;
+typedef struct __GLsync *GLsync;
+#endif
+
+#define GL_SYNC_OBJECT_APPLE 0x8A53
+#define GL_MAX_SERVER_WAIT_TIMEOUT_APPLE 0x9111
+#define GL_OBJECT_TYPE_APPLE 0x9112
+#define GL_SYNC_CONDITION_APPLE 0x9113
+#define GL_SYNC_STATUS_APPLE 0x9114
+#define GL_SYNC_FLAGS_APPLE 0x9115
+#define GL_SYNC_FENCE_APPLE 0x9116
+#define GL_SYNC_GPU_COMMANDS_COMPLETE_APPLE 0x9117
+#define GL_UNSIGNALED_APPLE 0x9118
+#define GL_SIGNALED_APPLE 0x9119
+#define GL_ALREADY_SIGNALED_APPLE 0x911A
+#define GL_TIMEOUT_EXPIRED_APPLE 0x911B
+#define GL_CONDITION_SATISFIED_APPLE 0x911C
+#define GL_WAIT_FAILED_APPLE 0x911D
+#define GL_SYNC_FLUSH_COMMANDS_BIT_APPLE 0x00000001
+#define GL_TIMEOUT_IGNORED_APPLE 0xFFFFFFFFFFFFFFFFull
+#endif
+
/* GL_APPLE_texture_format_BGRA8888 */
#ifndef GL_APPLE_texture_format_BGRA8888
#define GL_BGRA_EXT 0x80E1
@@ -282,6 +436,11 @@ typedef void* GLeglImageOES;
* ARM extension tokens
*------------------------------------------------------------------------*/
+/* GL_ARM_mali_program_binary */
+#ifndef GL_ARM_mali_program_binary
+#define GL_MALI_PROGRAM_BINARY_ARM 0x8F61
+#endif
+
/* GL_ARM_mali_shader_binary */
#ifndef GL_ARM_mali_shader_binary
#define GL_MALI_SHADER_BINARY_ARM 0x8F60
@@ -330,15 +489,34 @@ typedef void* GLeglImageOES;
#define GL_STENCIL_EXT 0x1802
#endif
+/* GL_EXT_map_buffer_range */
+#ifndef GL_EXT_map_buffer_range
+#define GL_MAP_READ_BIT_EXT 0x0001
+#define GL_MAP_WRITE_BIT_EXT 0x0002
+#define GL_MAP_INVALIDATE_RANGE_BIT_EXT 0x0004
+#define GL_MAP_INVALIDATE_BUFFER_BIT_EXT 0x0008
+#define GL_MAP_FLUSH_EXPLICIT_BIT_EXT 0x0010
+#define GL_MAP_UNSYNCHRONIZED_BIT_EXT 0x0020
+#endif
+
/* GL_EXT_multisampled_render_to_texture */
#ifndef GL_EXT_multisampled_render_to_texture
#define GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_SAMPLES_EXT 0x8D6C
-/* reuse values from GL_EXT_framebuffer_multisample (desktop extension) */
+/* reuse values from GL_EXT_framebuffer_multisample (desktop extension) */
#define GL_RENDERBUFFER_SAMPLES_EXT 0x8CAB
#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT 0x8D56
#define GL_MAX_SAMPLES_EXT 0x8D57
#endif
+/* GL_EXT_multiview_draw_buffers */
+#ifndef GL_EXT_multiview_draw_buffers
+#define GL_COLOR_ATTACHMENT_EXT 0x90F0
+#define GL_MULTIVIEW_EXT 0x90F1
+#define GL_DRAW_BUFFER_EXT 0x0C01
+#define GL_READ_BUFFER_EXT 0x0C02
+#define GL_MAX_MULTIVIEW_BUFFERS_EXT 0x90F2
+#endif
+
/* GL_EXT_multi_draw_arrays */
/* No new tokens introduced by this extension. */
@@ -380,6 +558,11 @@ typedef void* GLeglImageOES;
#define GL_PROGRAM_PIPELINE_BINDING_EXT 0x825A
#endif
+/* GL_EXT_shader_framebuffer_fetch */
+#ifndef GL_EXT_shader_framebuffer_fetch
+#define GL_FRAGMENT_SHADER_DISCARDS_SAMPLES_EXT 0x8A52
+#endif
+
/* GL_EXT_shader_texture_lod */
/* No new tokens introduced by this extension. */
@@ -427,10 +610,10 @@ typedef void* GLeglImageOES;
/* GL_EXT_texture_storage */
#ifndef GL_EXT_texture_storage
#define GL_TEXTURE_IMMUTABLE_FORMAT_EXT 0x912F
-#define GL_ALPHA8_EXT 0x803C
+#define GL_ALPHA8_EXT 0x803C
#define GL_LUMINANCE8_EXT 0x8040
#define GL_LUMINANCE8_ALPHA8_EXT 0x8045
-#define GL_RGBA32F_EXT 0x8814
+#define GL_RGBA32F_EXT 0x8814
#define GL_RGB32F_EXT 0x8815
#define GL_ALPHA32F_EXT 0x8816
#define GL_LUMINANCE32F_EXT 0x8818
@@ -440,12 +623,12 @@ typedef void* GLeglImageOES;
#define GL_ALPHA16F_EXT 0x881C
#define GL_LUMINANCE16F_EXT 0x881E
#define GL_LUMINANCE_ALPHA16F_EXT 0x881F
-#define GL_RGB10_A2_EXT 0x8059
+#define GL_RGB10_A2_EXT 0x8059
#define GL_RGB10_EXT 0x8052
#define GL_BGRA8_EXT 0x93A1
#define GL_R8_EXT 0x8229
#define GL_RG8_EXT 0x822B
-#define GL_R32F_EXT 0x822E
+#define GL_R32F_EXT 0x822E
#define GL_RG32F_EXT 0x8230
#define GL_R16F_EXT 0x822D
#define GL_RG16F_EXT 0x822F
@@ -458,9 +641,9 @@ typedef void* GLeglImageOES;
/* GL_EXT_unpack_subimage */
#ifndef GL_EXT_unpack_subimage
-#define GL_UNPACK_ROW_LENGTH 0x0CF2
-#define GL_UNPACK_SKIP_ROWS 0x0CF3
-#define GL_UNPACK_SKIP_PIXELS 0x0CF4
+#define GL_UNPACK_ROW_LENGTH_EXT 0x0CF2
+#define GL_UNPACK_SKIP_ROWS_EXT 0x0CF3
+#define GL_UNPACK_SKIP_PIXELS_EXT 0x0CF4
#endif
/*------------------------------------------------------------------------*
@@ -478,7 +661,7 @@ typedef void* GLeglImageOES;
/* GL_FJ_shader_binary_GCCSO */
#ifndef GL_FJ_shader_binary_GCCSO
-#define GCCSO_SHADER_BINARY_FJ 0x9260
+#define GL_GCCSO_SHADER_BINARY_F 0x9260
#endif
/*------------------------------------------------------------------------*
@@ -509,6 +692,12 @@ typedef void* GLeglImageOES;
#define GL_COMPRESSED_RGBA_PVRTC_2BPPV1_IMG 0x8C03
#endif
+/* GL_IMG_texture_compression_pvrtc2 */
+#ifndef GL_IMG_texture_compression_pvrtc2
+#define GL_COMPRESSED_RGBA_PVRTC_2BPPV2_IMG 0x9137
+#define GL_COMPRESSED_RGBA_PVRTC_4BPPV2_IMG 0x9138
+#endif
+
/* GL_IMG_multisampled_render_to_texture */
#ifndef GL_IMG_multisampled_render_to_texture
#define GL_RENDERBUFFER_SAMPLES_IMG 0x9133
@@ -576,6 +765,9 @@ typedef void* GLeglImageOES;
#define GL_COLOR_ATTACHMENT15_NV 0x8CEF
#endif
+/* GL_NV_draw_instanced */
+/* No new tokens introduced by this extension. */
+
/* GL_NV_fbo_color_attachments */
#ifndef GL_NV_fbo_color_attachments
#define GL_MAX_COLOR_ATTACHMENTS_NV 0x8CDF
@@ -589,6 +781,29 @@ typedef void* GLeglImageOES;
#define GL_FENCE_CONDITION_NV 0x84F4
#endif
+/* GL_NV_framebuffer_blit */
+#ifndef GL_NV_framebuffer_blit
+#define GL_READ_FRAMEBUFFER_NV 0x8CA8
+#define GL_DRAW_FRAMEBUFFER_NV 0x8CA9
+#define GL_DRAW_FRAMEBUFFER_BINDING_NV 0x8CA6
+#define GL_READ_FRAMEBUFFER_BINDING_NV 0x8CAA
+#endif
+
+/* GL_NV_framebuffer_multisample */
+#ifndef GL_NV_framebuffer_multisample
+#define GL_RENDERBUFFER_SAMPLES_NV 0x8CAB
+#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_NV 0x8D56
+#define GL_MAX_SAMPLES_NV 0x8D57
+#endif
+
+/* GL_NV_generate_mipmap_sRGB */
+/* No new tokens introduced by this extension. */
+
+/* GL_NV_instanced_arrays */
+#ifndef GL_NV_instanced_arrays
+#define GL_VERTEX_ATTRIB_ARRAY_DIVISOR_NV 0x88FE
+#endif
+
/* GL_NV_read_buffer */
#ifndef GL_NV_read_buffer
#define GL_READ_BUFFER_NV 0x0C02
@@ -606,6 +821,36 @@ typedef void* GLeglImageOES;
/* GL_NV_read_stencil */
/* No new tokens introduced by this extension. */
+/* GL_NV_shadow_samplers_array */
+#ifndef GL_NV_shadow_samplers_array
+#define GL_SAMPLER_2D_ARRAY_SHADOW_NV 0x8DC4
+#endif
+
+/* GL_NV_shadow_samplers_cube */
+#ifndef GL_NV_shadow_samplers_cube
+#define GL_SAMPLER_CUBE_SHADOW_NV 0x8DC5
+#endif
+
+/* GL_NV_sRGB_formats */
+#ifndef GL_NV_sRGB_formats
+#define GL_SLUMINANCE_NV 0x8C46
+#define GL_SLUMINANCE_ALPHA_NV 0x8C44
+#define GL_SRGB8_NV 0x8C41
+#define GL_SLUMINANCE8_NV 0x8C47
+#define GL_SLUMINANCE8_ALPHA8_NV 0x8C45
+#define GL_COMPRESSED_SRGB_S3TC_DXT1_NV 0x8C4C
+#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_NV 0x8C4D
+#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_NV 0x8C4E
+#define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_NV 0x8C4F
+#define GL_ETC1_SRGB8_NV 0x88EE
+#endif
+
+/* GL_NV_texture_border_clamp */
+#ifndef GL_NV_texture_border_clamp
+#define GL_TEXTURE_BORDER_COLOR_NV 0x1004
+#define GL_CLAMP_TO_BORDER_NV 0x812D
+#endif
+
/* GL_NV_texture_compression_s3tc_update */
/* No new tokens introduced by this extension. */
@@ -623,6 +868,14 @@ typedef void* GLeglImageOES;
#define GL_ALPHA_TEST_REF_QCOM 0x0BC2
#endif
+/* GL_QCOM_binning_control */
+#ifndef GL_QCOM_binning_control
+#define GL_BINNING_CONTROL_HINT_QCOM 0x8FB0
+#define GL_CPU_OPTIMIZED_QCOM 0x8FB1
+#define GL_GPU_OPTIMIZED_QCOM 0x8FB2
+#define GL_RENDER_DIRECT_TO_FRAMEBUFFER_QCOM 0x8FB3
+#endif
+
/* GL_QCOM_driver_control */
/* No new tokens introduced by this extension. */
@@ -818,6 +1071,10 @@ typedef void (GL_APIENTRYP PFNGLGETBUFFERPOINTERVOESPROC) (GLenum target, GLenum
#define GL_OES_stencil4 1
#endif
+#ifndef GL_OES_surfaceless_context
+#define GL_OES_surfaceless_context 1
+#endif
+
/* GL_OES_texture_3D */
#ifndef GL_OES_texture_3D
#define GL_OES_texture_3D 1
@@ -888,6 +1145,43 @@ typedef GLboolean (GL_APIENTRYP PFNGLISVERTEXARRAYOESPROC) (GLuint array);
#endif
/*------------------------------------------------------------------------*
+ * KHR extension functions
+ *------------------------------------------------------------------------*/
+
+#ifndef GL_KHR_debug
+#define GL_KHR_debug 1
+#ifdef GL_GLEXT_PROTOTYPES
+GL_APICALL void GL_APIENTRY glDebugMessageControl (GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
+GL_APICALL void GL_APIENTRY glDebugMessageInsert (GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf);
+GL_APICALL void GL_APIENTRY glDebugMessageCallback (GLDEBUGPROC callback, const void *userParam);
+GL_APICALL GLuint GL_APIENTRY glGetDebugMessageLog (GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog);
+GL_APICALL void GL_APIENTRY glPushDebugGroup (GLenum source, GLuint id, GLsizei length, const GLchar *message);
+GL_APICALL void GL_APIENTRY glPopDebugGroup (void);
+GL_APICALL void GL_APIENTRY glObjectLabel (GLenum identifier, GLuint name, GLsizei length, const GLchar *label);
+GL_APICALL void GL_APIENTRY glGetObjectLabel (GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label);
+GL_APICALL void GL_APIENTRY glObjectPtrLabel (const void *ptr, GLsizei length, const GLchar *label);
+GL_APICALL void GL_APIENTRY glGetObjectPtrLabel (const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label);
+GL_APICALL void GL_APIENTRY glGetPointerv (GLenum pname, void **params);
+#endif
+typedef void (GL_APIENTRYP PFNGLDEBUGMESSAGECONTROLPROC) (GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
+typedef void (GL_APIENTRYP PFNGLDEBUGMESSAGEINSERTPROC) (GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf);
+typedef void (GL_APIENTRYP PFNGLDEBUGMESSAGECALLBACKPROC) (GLDEBUGPROC callback, const void *userParam);
+typedef GLuint (GL_APIENTRYP PFNGLGETDEBUGMESSAGELOGPROC) (GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog);
+typedef void (GL_APIENTRYP PFNGLPUSHDEBUGGROUPPROC) (GLenum source, GLuint id, GLsizei length, const GLchar *message);
+typedef void (GL_APIENTRYP PFNGLPOPDEBUGGROUPPROC) (void);
+typedef void (GL_APIENTRYP PFNGLOBJECTLABELPROC) (GLenum identifier, GLuint name, GLsizei length, const GLchar *label);
+typedef void (GL_APIENTRYP PFNGLGETOBJECTLABELPROC) (GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label);
+typedef void (GL_APIENTRYP PFNGLOBJECTPTRLABELPROC) (const void *ptr, GLsizei length, const GLchar *label);
+typedef void (GL_APIENTRYP PFNGLGETOBJECTPTRLABELPROC) (const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label);
+typedef void (GL_APIENTRYP PFNGLGETPOINTERVPROC) (GLenum pname, void **params);
+#endif
+
+#ifndef GL_KHR_texture_compression_astc_ldr
+#define GL_KHR_texture_compression_astc_ldr 1
+#endif
+
+
+/*------------------------------------------------------------------------*
* AMD extension functions
*------------------------------------------------------------------------*/
@@ -939,6 +1233,11 @@ typedef void (GL_APIENTRYP PFNGLGETPERFMONITORCOUNTERDATAAMDPROC) (GLuint monito
* ANGLE extension functions
*------------------------------------------------------------------------*/
+/* GL_ANGLE_depth_texture */
+#ifndef GL_ANGLE_depth_texture
+#define GL_ANGLE_depth_texture 1
+#endif
+
/* GL_ANGLE_framebuffer_blit */
#ifndef GL_ANGLE_framebuffer_blit
#define GL_ANGLE_framebuffer_blit 1
@@ -957,52 +1256,62 @@ GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisampleANGLE (GLenum target
typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEANGLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
#endif
-#ifndef GL_ANGLE_instanced_arrays
+#ifndef GL_ANGLE_instanced_arrays
+#define GL_ANGLE_instanced_arrays 1
#ifdef GL_GLEXT_PROTOTYPES
GL_APICALL void GL_APIENTRY glDrawArraysInstancedANGLE (GLenum mode, GLint first, GLsizei count, GLsizei primcount);
GL_APICALL void GL_APIENTRY glDrawElementsInstancedANGLE (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount);
GL_APICALL void GL_APIENTRY glVertexAttribDivisorANGLE (GLuint index, GLuint divisor);
#endif
-typedef void (GL_APIENTRYP PFLGLDRAWARRAYSINSTANCEDANGLEPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount);
-typedef void (GL_APIENTRYP PFLGLDRAWELEMENTSINSTANCEDANGLEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount);
-typedef void (GL_APIENTRYP PFLGLVERTEXATTRIBDIVISORANGLEPROC) (GLuint index, GLuint divisor);
+typedef void (GL_APIENTRYP PFNGLDRAWARRAYSINSTANCEDANGLEPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount);
+typedef void (GL_APIENTRYP PFNGLDRAWELEMENTSINSTANCEDANGLEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount);
+typedef void (GL_APIENTRYP PFNGLVERTEXATTRIBDIVISORANGLEPROC) (GLuint index, GLuint divisor);
#endif
/* GL_ANGLE_pack_reverse_row_order */
-#ifndef GL_ANGLE_pack_reverse_row_order
+#ifndef GL_ANGLE_pack_reverse_row_order
#define GL_ANGLE_pack_reverse_row_order 1
#endif
+/* GL_ANGLE_program_binary */
+#ifndef GL_ANGLE_program_binary
+#define GL_ANGLE_program_binary 1
+#endif
+
/* GL_ANGLE_texture_compression_dxt3 */
-#ifndef GL_ANGLE_texture_compression_dxt3
+#ifndef GL_ANGLE_texture_compression_dxt3
#define GL_ANGLE_texture_compression_dxt3 1
#endif
/* GL_ANGLE_texture_compression_dxt5 */
-#ifndef GL_ANGLE_texture_compression_dxt5
+#ifndef GL_ANGLE_texture_compression_dxt5
#define GL_ANGLE_texture_compression_dxt5 1
#endif
/* GL_ANGLE_texture_usage */
-#ifndef GL_ANGLE_texture_usage
+#ifndef GL_ANGLE_texture_usage
#define GL_ANGLE_texture_usage 1
#endif
-#ifndef GL_ANGLE_translated_shader_source
+#ifndef GL_ANGLE_translated_shader_source
#define GL_ANGLE_translated_shader_source 1
#ifdef GL_GLEXT_PROTOTYPES
GL_APICALL void GL_APIENTRY glGetTranslatedShaderSourceANGLE (GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source);
#endif
-typedef void (GL_APIENTRYP PFLGLGETTRANSLATEDSHADERSOURCEANGLEPROC) (GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source);
+typedef void (GL_APIENTRYP PFNGLGETTRANSLATEDSHADERSOURCEANGLEPROC) (GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source);
#endif
/*------------------------------------------------------------------------*
* APPLE extension functions
*------------------------------------------------------------------------*/
-/* GL_APPLE_rgb_422 */
-#ifndef GL_APPLE_rgb_422
-#define GL_APPLE_rgb_422 1
+/* GL_APPLE_copy_texture_levels */
+#ifndef GL_APPLE_copy_texture_levels
+#define GL_APPLE_copy_texture_levels 1
+#ifdef GL_GLEXT_PROTOTYPES
+GL_APICALL void GL_APIENTRY glCopyTextureLevelsAPPLE (GLuint destinationTexture, GLuint sourceTexture, GLint sourceBaseLevel, GLsizei sourceLevelCount);
+#endif
+typedef void (GL_APIENTRYP PFNGLCOPYTEXTURELEVELSAPPLEPROC) (GLuint destinationTexture, GLuint sourceTexture, GLint sourceBaseLevel, GLsizei sourceLevelCount);
#endif
/* GL_APPLE_framebuffer_multisample */
@@ -1016,6 +1325,32 @@ typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEAPPLEPROC) (GLenum
typedef void (GL_APIENTRYP PFNGLRESOLVEMULTISAMPLEFRAMEBUFFERAPPLEPROC) (void);
#endif
+/* GL_APPLE_rgb_422 */
+#ifndef GL_APPLE_rgb_422
+#define GL_APPLE_rgb_422 1
+#endif
+
+/* GL_APPLE_sync */
+#ifndef GL_APPLE_sync
+#define GL_APPLE_sync 1
+#ifdef GL_GLEXT_PROTOTYPES
+GL_APICALL GLsync GL_APIENTRY glFenceSyncAPPLE (GLenum condition, GLbitfield flags);
+GL_APICALL GLboolean GL_APIENTRY glIsSyncAPPLE (GLsync sync);
+GL_APICALL void GL_APIENTRY glDeleteSyncAPPLE (GLsync sync);
+GL_APICALL GLenum GL_APIENTRY glClientWaitSyncAPPLE (GLsync sync, GLbitfield flags, GLuint64 timeout);
+GL_APICALL void GL_APIENTRY glWaitSyncAPPLE (GLsync sync, GLbitfield flags, GLuint64 timeout);
+GL_APICALL void GL_APIENTRY glGetInteger64vAPPLE (GLenum pname, GLint64 *params);
+GL_APICALL void GL_APIENTRY glGetSyncivAPPLE (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+#endif
+typedef GLsync (GL_APIENTRYP PFNGLFENCESYNCAPPLEPROC) (GLenum condition, GLbitfield flags);
+typedef GLboolean (GL_APIENTRYP PFNGLISSYNCAPPLEPROC) (GLsync sync);
+typedef void (GL_APIENTRYP PFNGLDELETESYNCAPPLEPROC) (GLsync sync);
+typedef GLenum (GL_APIENTRYP PFNGLCLIENTWAITSYNCAPPLEPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout);
+typedef void (GL_APIENTRYP PFNGLWAITSYNCAPPLEPROC) (GLsync sync, GLbitfield flags, GLuint64 timeout);
+typedef void (GL_APIENTRYP PFNGLGETINTEGER64VAPPLEPROC) (GLenum pname, GLint64 *params);
+typedef void (GL_APIENTRYP PFNGLGETSYNCIVAPPLEPROC) (GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+#endif
+
/* GL_APPLE_texture_format_BGRA8888 */
#ifndef GL_APPLE_texture_format_BGRA8888
#define GL_APPLE_texture_format_BGRA8888 1
@@ -1030,6 +1365,11 @@ typedef void (GL_APIENTRYP PFNGLRESOLVEMULTISAMPLEFRAMEBUFFERAPPLEPROC) (void);
* ARM extension functions
*------------------------------------------------------------------------*/
+/* GL_ARM_mali_program_binary */
+#ifndef GL_ARM_mali_program_binary
+#define GL_ARM_mali_program_binary 1
+#endif
+
/* GL_ARM_mali_shader_binary */
#ifndef GL_ARM_mali_shader_binary
#define GL_ARM_mali_shader_binary 1
@@ -1087,6 +1427,17 @@ GL_APICALL void GL_APIENTRY glDiscardFramebufferEXT (GLenum target, GLsizei numA
typedef void (GL_APIENTRYP PFNGLDISCARDFRAMEBUFFEREXTPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments);
#endif
+/* GL_EXT_map_buffer_range */
+#ifndef GL_EXT_map_buffer_range
+#define GL_EXT_map_buffer_range 1
+#ifdef GL_GLEXT_PROTOTYPES
+GL_APICALL void* GL_APIENTRY glMapBufferRangeEXT (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+GL_APICALL void GL_APIENTRY glFlushMappedBufferRangeEXT (GLenum target, GLintptr offset, GLsizeiptr length);
+#endif
+typedef void* (GL_APIENTRYP PFNGLMAPBUFFERRANGEEXTPROC) (GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+typedef void (GL_APIENTRYP PFNGLFLUSHMAPPEDBUFFERRANGEEXTPROC) (GLenum target, GLintptr offset, GLsizeiptr length);
+#endif
+
/* GL_EXT_multisampled_render_to_texture */
#ifndef GL_EXT_multisampled_render_to_texture
#define GL_EXT_multisampled_render_to_texture 1
@@ -1098,6 +1449,19 @@ typedef void (GL_APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLEEXTPROC) (GLenum t
typedef void (GL_APIENTRYP PFNGLFRAMEBUFFERTEXTURE2DMULTISAMPLEEXTPROC) (GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples);
#endif
+/* GL_EXT_multiview_draw_buffers */
+#ifndef GL_EXT_multiview_draw_buffers
+#define GL_EXT_multiview_draw_buffers 1
+#ifdef GL_GLEXT_PROTOTYPES
+GL_APICALL void GL_APIENTRY glReadBufferIndexedEXT (GLenum src, GLint index);
+GL_APICALL void GL_APIENTRY glDrawBuffersIndexedEXT (GLint n, const GLenum *location, const GLint *indices);
+GL_APICALL void GL_APIENTRY glGetIntegeri_vEXT (GLenum target, GLuint index, GLint *data);
+#endif
+typedef void (GL_APIENTRYP PFNGLREADBUFFERINDEXEDEXTPROC) (GLenum src, GLint index);
+typedef void (GL_APIENTRYP PFNGLDRAWBUFFERSINDEXEDEXTPROC) (GLint n, const GLenum *location, const GLint *indices);
+typedef void (GL_APIENTRYP PFNGLGETINTEGERI_VEXTPROC) (GLenum target, GLuint index, GLint *data);
+#endif
+
#ifndef GL_EXT_multi_draw_arrays
#define GL_EXT_multi_draw_arrays 1
#ifdef GL_GLEXT_PROTOTYPES
@@ -1216,6 +1580,11 @@ typedef void (GL_APIENTRYP PFNGLVALIDATEPROGRAMPIPELINEEXTPROC) (GLuint pipeline
typedef void (GL_APIENTRYP PFNGLGETPROGRAMPIPELINEINFOLOGEXTPROC) (GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
#endif
+/* GL_EXT_shader_framebuffer_fetch */
+#ifndef GL_EXT_shader_framebuffer_fetch
+#define GL_EXT_shader_framebuffer_fetch 1
+#endif
+
/* GL_EXT_shader_texture_lod */
#ifndef GL_EXT_shader_texture_lod
#define GL_EXT_shader_texture_lod 1
@@ -1322,6 +1691,11 @@ typedef void (GL_APIENTRYP PFNGLTEXTURESTORAGE3DEXTPROC) (GLuint texture, GLenum
#define GL_IMG_texture_compression_pvrtc 1
#endif
+/* GL_IMG_texture_compression_pvrtc2 */
+#ifndef GL_IMG_texture_compression_pvrtc2
+#define GL_IMG_texture_compression_pvrtc2 1
+#endif
+
/* GL_IMG_multisampled_render_to_texture */
#ifndef GL_IMG_multisampled_render_to_texture
#define GL_IMG_multisampled_render_to_texture 1
@@ -1362,6 +1736,17 @@ GL_APICALL void GL_APIENTRY glDrawBuffersNV (GLsizei n, const GLenum *bufs);
typedef void (GL_APIENTRYP PFNGLDRAWBUFFERSNVPROC) (GLsizei n, const GLenum *bufs);
#endif
+/* GL_NV_draw_instanced */
+#ifndef GL_NV_draw_instanced
+#define GL_NV_draw_instanced 1
+#ifdef GL_GLEXT_PROTOTYPES
+GL_APICALL void GL_APIENTRY glDrawArraysInstancedNV (GLenum mode, GLint first, GLsizei count, GLsizei primcount);
+GL_APICALL void GL_APIENTRY glDrawElementsInstancedNV (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount);
+#endif
+typedef void (GL_APIENTRYP PFNDRAWARRAYSINSTANCEDNVPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount);
+typedef void (GL_APIENTRYP PFNDRAWELEMENTSINSTANCEDNVPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount);
+#endif
+
/* GL_NV_fbo_color_attachments */
#ifndef GL_NV_fbo_color_attachments
#define GL_NV_fbo_color_attachments 1
@@ -1388,6 +1773,38 @@ typedef void (GL_APIENTRYP PFNGLFINISHFENCENVPROC) (GLuint fence);
typedef void (GL_APIENTRYP PFNGLSETFENCENVPROC) (GLuint fence, GLenum condition);
#endif
+/* GL_NV_framebuffer_blit */
+#ifndef GL_NV_framebuffer_blit
+#define GL_NV_framebuffer_blit 1
+#ifdef GL_GLEXT_PROTOTYPES
+GL_APICALL void GL_APIENTRY glBlitFramebufferNV (int srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+#endif
+typedef void (GL_APIENTRYP PFNBLITFRAMEBUFFERNVPROC) (GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+#endif
+
+/* GL_NV_framebuffer_multisample */
+#ifndef GL_NV_framebuffer_multisample
+#define GL_NV_framebuffer_multisample 1
+#ifdef GL_GLEXT_PROTOTYPES
+GL_APICALL void GL_APIENTRY glRenderbufferStorageMultisampleNV ( GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+#endif
+typedef void (GL_APIENTRYP PFNRENDERBUFFERSTORAGEMULTISAMPLENVPROC) ( GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+#endif
+
+/* GL_NV_generate_mipmap_sRGB */
+#ifndef GL_NV_generate_mipmap_sRGB
+#define GL_NV_generate_mipmap_sRGB 1
+#endif
+
+/* GL_NV_instanced_arrays */
+#ifndef GL_NV_instanced_arrays
+#define GL_NV_instanced_arrays 1
+#ifdef GL_GLEXT_PROTOTYPES
+GL_APICALL void GL_APIENTRY glVertexAttribDivisorNV (GLuint index, GLuint divisor);
+#endif
+typedef void (GL_APIENTRYP PFNVERTEXATTRIBDIVISORNVPROC) (GLuint index, GLuint divisor);
+#endif
+
/* GL_NV_read_buffer */
#ifndef GL_NV_read_buffer
#define GL_NV_read_buffer 1
@@ -1417,6 +1834,26 @@ typedef void (GL_APIENTRYP PFNGLREADBUFFERNVPROC) (GLenum mode);
#define GL_NV_read_stencil 1
#endif
+/* GL_NV_shadow_samplers_array */
+#ifndef GL_NV_shadow_samplers_array
+#define GL_NV_shadow_samplers_array 1
+#endif
+
+/* GL_NV_shadow_samplers_cube */
+#ifndef GL_NV_shadow_samplers_cube
+#define GL_NV_shadow_samplers_cube 1
+#endif
+
+/* GL_NV_sRGB_formats */
+#ifndef GL_NV_sRGB_formats
+#define GL_NV_sRGB_formats 1
+#endif
+
+/* GL_NV_texture_border_clamp */
+#ifndef GL_NV_texture_border_clamp
+#define GL_NV_texture_border_clamp 1
+#endif
+
/* GL_NV_texture_compression_s3tc_update */
#ifndef GL_NV_texture_compression_s3tc_update
#define GL_NV_texture_compression_s3tc_update 1
@@ -1440,6 +1877,11 @@ GL_APICALL void GL_APIENTRY glAlphaFuncQCOM (GLenum func, GLclampf ref);
typedef void (GL_APIENTRYP PFNGLALPHAFUNCQCOMPROC) (GLenum func, GLclampf ref);
#endif
+/* GL_QCOM_binning_control */
+#ifndef GL_QCOM_binning_control
+#define GL_QCOM_binning_control 1
+#endif
+
/* GL_QCOM_driver_control */
#ifndef GL_QCOM_driver_control
#define GL_QCOM_driver_control 1
diff --git a/src/gui/opengl/qopenglext.h b/src/gui/opengl/qopenglext.h
index 5d21cb6eea..dfdb8249d9 100644
--- a/src/gui/opengl/qopenglext.h
+++ b/src/gui/opengl/qopenglext.h
@@ -3,6 +3,7 @@
#if 0
#pragma qt_no_master_include
+#pragma qt_sync_skip_header_check
#pragma qt_sync_stop_processing
#endif
@@ -12,7 +13,7 @@ extern "C" {
/*
** Copyright (c) 2007-2012 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
@@ -20,10 +21,10 @@ extern "C" {
** 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.
@@ -34,9 +35,9 @@ extern "C" {
*/
/* Header file version number, required by OpenGL ABI for Linux */
-/* glext.h last updated $Date: 2012-06-18 11:26:35 -0700 (Mon, 18 Jun 2012) $ */
+/* glext.h last updated $Date: 2013-02-07 01:42:49 -0800 (Thu, 07 Feb 2013) $ */
/* Current version at http://www.opengl.org/registry/ */
-#define GL_GLEXT_VERSION 82
+#define GL_GLEXT_VERSION 86
/* Function declaration macros - to move into glplatform.h */
#if defined(_WIN32) && !defined(APIENTRY) && !defined(__CYGWIN__) && !defined(__SCITECH_SNAP__)
@@ -93,9 +94,6 @@ extern "C" {
#define GL_SMOOTH_LINE_WIDTH_RANGE 0x0B22
#define GL_SMOOTH_LINE_WIDTH_GRANULARITY 0x0B23
#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E
-#endif
-
-#ifndef GL_VERSION_1_2_DEPRECATED
#define GL_RESCALE_NORMAL 0x803A
#define GL_LIGHT_MODEL_COLOR_CONTROL 0x81F8
#define GL_SINGLE_COLOR 0x81F9
@@ -115,9 +113,6 @@ extern "C" {
#define GL_BLEND_EQUATION 0x8009
#define GL_FUNC_SUBTRACT 0x800A
#define GL_FUNC_REVERSE_SUBTRACT 0x800B
-#endif
-
-#ifndef GL_ARB_imaging_DEPRECATED
#define GL_CONVOLUTION_1D 0x8010
#define GL_CONVOLUTION_2D 0x8011
#define GL_SEPARABLE_2D 0x8012
@@ -244,9 +239,6 @@ extern "C" {
#define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2
#define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3
#define GL_CLAMP_TO_BORDER 0x812D
-#endif
-
-#ifndef GL_VERSION_1_3_DEPRECATED
#define GL_CLIENT_ACTIVE_TEXTURE 0x84E1
#define GL_MAX_TEXTURE_UNITS 0x84E2
#define GL_TRANSPOSE_MODELVIEW_MATRIX 0x84E3
@@ -303,9 +295,6 @@ extern "C" {
#define GL_TEXTURE_DEPTH_SIZE 0x884A
#define GL_TEXTURE_COMPARE_MODE 0x884C
#define GL_TEXTURE_COMPARE_FUNC 0x884D
-#endif
-
-#ifndef GL_VERSION_1_4_DEPRECATED
#define GL_POINT_SIZE_MIN 0x8126
#define GL_POINT_SIZE_MAX 0x8127
#define GL_POINT_DISTANCE_ATTENUATION 0x8129
@@ -359,9 +348,7 @@ extern "C" {
#define GL_DYNAMIC_READ 0x88E9
#define GL_DYNAMIC_COPY 0x88EA
#define GL_SAMPLES_PASSED 0x8914
-#endif
-
-#ifndef GL_VERSION_1_5_DEPRECATED
+#define GL_SRC1_ALPHA 0x8589
#define GL_VERTEX_ARRAY_BUFFER_BINDING 0x8896
#define GL_NORMAL_ARRAY_BUFFER_BINDING 0x8897
#define GL_COLOR_ARRAY_BUFFER_BINDING 0x8898
@@ -383,7 +370,6 @@ extern "C" {
#define GL_SRC1_RGB 0x8581
#define GL_SRC2_RGB 0x8582
#define GL_SRC0_ALPHA 0x8588
-#define GL_SRC1_ALPHA 0x8589
#define GL_SRC2_ALPHA 0x858A
#endif
@@ -468,9 +454,6 @@ extern "C" {
#define GL_STENCIL_BACK_REF 0x8CA3
#define GL_STENCIL_BACK_VALUE_MASK 0x8CA4
#define GL_STENCIL_BACK_WRITEMASK 0x8CA5
-#endif
-
-#ifndef GL_VERSION_2_0_DEPRECATED
#define GL_VERTEX_PROGRAM_TWO_SIDE 0x8643
#define GL_POINT_SPRITE 0x8861
#define GL_COORD_REPLACE 0x8862
@@ -494,9 +477,6 @@ extern "C" {
#define GL_SRGB8_ALPHA8 0x8C43
#define GL_COMPRESSED_SRGB 0x8C48
#define GL_COMPRESSED_SRGB_ALPHA 0x8C49
-#endif
-
-#ifndef GL_VERSION_2_1_DEPRECATED
#define GL_CURRENT_RASTER_SECONDARY_COLOR 0x845F
#define GL_SLUMINANCE_ALPHA 0x8C44
#define GL_SLUMINANCE8_ALPHA8 0x8C45
@@ -731,9 +711,6 @@ extern "C" {
/* reuse GL_RG32UI */
/* Reuse tokens from ARB_vertex_array_object */
/* reuse GL_VERTEX_ARRAY_BINDING */
-#endif
-
-#ifndef GL_VERSION_3_0_DEPRECATED
#define GL_CLAMP_VERTEX_COLOR 0x891A
#define GL_CLAMP_FRAGMENT_COLOR 0x891B
#define GL_ALPHA_INTEGER 0x8D97
@@ -754,7 +731,6 @@ extern "C" {
#define GL_MAX_TEXTURE_BUFFER_SIZE 0x8C2B
#define GL_TEXTURE_BINDING_BUFFER 0x8C2C
#define GL_TEXTURE_BUFFER_DATA_STORE_BINDING 0x8C2D
-#define GL_TEXTURE_BUFFER_FORMAT 0x8C2E
#define GL_TEXTURE_RECTANGLE 0x84F5
#define GL_TEXTURE_BINDING_RECTANGLE 0x84F6
#define GL_PROXY_TEXTURE_RECTANGLE 0x84F7
@@ -1020,6 +996,7 @@ extern "C" {
/* reuse GL_MEDIUM_INT */
/* reuse GL_HIGH_INT */
/* reuse GL_SHADER_COMPILER */
+/* reuse GL_SHADER_BINARY_FORMATS */
/* reuse GL_NUM_SHADER_BINARY_FORMATS */
/* reuse GL_MAX_VERTEX_UNIFORM_VECTORS */
/* reuse GL_MAX_VARYING_VECTORS */
@@ -1169,6 +1146,290 @@ extern "C" {
/* reuse GL_TEXTURE_IMMUTABLE_FORMAT */
#endif
+#ifndef GL_VERSION_4_3
+#define GL_NUM_SHADING_LANGUAGE_VERSIONS 0x82E9
+#define GL_VERTEX_ATTRIB_ARRAY_LONG 0x874E
+/* Reuse tokens from ARB_arrays_of_arrays (none, GLSL only) */
+/* Reuse tokens from ARB_fragment_layer_viewport (none, GLSL only) */
+/* Reuse tokens from ARB_shader_image_size (none, GLSL only) */
+/* Reuse tokens from ARB_ES3_compatibility */
+/* reuse GL_COMPRESSED_RGB8_ETC2 */
+/* reuse GL_COMPRESSED_SRGB8_ETC2 */
+/* reuse GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2 */
+/* reuse GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2 */
+/* reuse GL_COMPRESSED_RGBA8_ETC2_EAC */
+/* reuse GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC */
+/* reuse GL_COMPRESSED_R11_EAC */
+/* reuse GL_COMPRESSED_SIGNED_R11_EAC */
+/* reuse GL_COMPRESSED_RG11_EAC */
+/* reuse GL_COMPRESSED_SIGNED_RG11_EAC */
+/* reuse GL_PRIMITIVE_RESTART_FIXED_INDEX */
+/* reuse GL_ANY_SAMPLES_PASSED_CONSERVATIVE */
+/* reuse GL_MAX_ELEMENT_INDEX */
+/* Reuse tokens from ARB_clear_buffer_object (none) */
+/* Reuse tokens from ARB_compute_shader */
+/* reuse GL_COMPUTE_SHADER */
+/* reuse GL_MAX_COMPUTE_UNIFORM_BLOCKS */
+/* reuse GL_MAX_COMPUTE_TEXTURE_IMAGE_UNITS */
+/* reuse GL_MAX_COMPUTE_IMAGE_UNIFORMS */
+/* reuse GL_MAX_COMPUTE_SHARED_MEMORY_SIZE */
+/* reuse GL_MAX_COMPUTE_UNIFORM_COMPONENTS */
+/* reuse GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS */
+/* reuse GL_MAX_COMPUTE_ATOMIC_COUNTERS */
+/* reuse GL_MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS */
+/* reuse GL_MAX_COMPUTE_LOCAL_INVOCATIONS */
+/* reuse GL_MAX_COMPUTE_WORK_GROUP_COUNT */
+/* reuse GL_MAX_COMPUTE_WORK_GROUP_SIZE */
+/* reuse GL_COMPUTE_LOCAL_WORK_SIZE */
+/* reuse GL_UNIFORM_BLOCK_REFERENCED_BY_COMPUTE_SHADER */
+/* reuse GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_COMPUTE_SHADER */
+/* reuse GL_DISPATCH_INDIRECT_BUFFER */
+/* reuse GL_DISPATCH_INDIRECT_BUFFER_BINDING */
+/* Reuse tokens from ARB_copy_image (none) */
+/* Reuse tokens from KHR_debug */
+/* reuse GL_DEBUG_OUTPUT_SYNCHRONOUS */
+/* reuse GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH */
+/* reuse GL_DEBUG_CALLBACK_FUNCTION */
+/* reuse GL_DEBUG_CALLBACK_USER_PARAM */
+/* reuse GL_DEBUG_SOURCE_API */
+/* reuse GL_DEBUG_SOURCE_WINDOW_SYSTEM */
+/* reuse GL_DEBUG_SOURCE_SHADER_COMPILER */
+/* reuse GL_DEBUG_SOURCE_THIRD_PARTY */
+/* reuse GL_DEBUG_SOURCE_APPLICATION */
+/* reuse GL_DEBUG_SOURCE_OTHER */
+/* reuse GL_DEBUG_TYPE_ERROR */
+/* reuse GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR */
+/* reuse GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR */
+/* reuse GL_DEBUG_TYPE_PORTABILITY */
+/* reuse GL_DEBUG_TYPE_PERFORMANCE */
+/* reuse GL_DEBUG_TYPE_OTHER */
+/* reuse GL_MAX_DEBUG_MESSAGE_LENGTH */
+/* reuse GL_MAX_DEBUG_LOGGED_MESSAGES */
+/* reuse GL_DEBUG_LOGGED_MESSAGES */
+/* reuse GL_DEBUG_SEVERITY_HIGH */
+/* reuse GL_DEBUG_SEVERITY_MEDIUM */
+/* reuse GL_DEBUG_SEVERITY_LOW */
+/* reuse GL_DEBUG_TYPE_MARKER */
+/* reuse GL_DEBUG_TYPE_PUSH_GROUP */
+/* reuse GL_DEBUG_TYPE_POP_GROUP */
+/* reuse GL_DEBUG_SEVERITY_NOTIFICATION */
+/* reuse GL_MAX_DEBUG_GROUP_STACK_DEPTH */
+/* reuse GL_DEBUG_GROUP_STACK_DEPTH */
+/* reuse GL_BUFFER */
+/* reuse GL_SHADER */
+/* reuse GL_PROGRAM */
+/* reuse GL_QUERY */
+/* reuse GL_PROGRAM_PIPELINE */
+/* reuse GL_SAMPLER */
+/* reuse GL_DISPLAY_LIST */
+/* reuse GL_MAX_LABEL_LENGTH */
+/* reuse GL_DEBUG_OUTPUT */
+/* reuse GL_CONTEXT_FLAG_DEBUG_BIT */
+/* reuse GL_STACK_UNDERFLOW */
+/* reuse GL_STACK_OVERFLOW */
+/* Reuse tokens from ARB_explicit_uniform_location */
+/* reuse GL_MAX_UNIFORM_LOCATIONS */
+/* Reuse tokens from ARB_framebuffer_no_attachments */
+/* reuse GL_FRAMEBUFFER_DEFAULT_WIDTH */
+/* reuse GL_FRAMEBUFFER_DEFAULT_HEIGHT */
+/* reuse GL_FRAMEBUFFER_DEFAULT_LAYERS */
+/* reuse GL_FRAMEBUFFER_DEFAULT_SAMPLES */
+/* reuse GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS */
+/* reuse GL_MAX_FRAMEBUFFER_WIDTH */
+/* reuse GL_MAX_FRAMEBUFFER_HEIGHT */
+/* reuse GL_MAX_FRAMEBUFFER_LAYERS */
+/* reuse GL_MAX_FRAMEBUFFER_SAMPLES */
+/* Reuse tokens from ARB_internalformat_query2 */
+/* reuse GL_INTERNALFORMAT_SUPPORTED */
+/* reuse GL_INTERNALFORMAT_PREFERRED */
+/* reuse GL_INTERNALFORMAT_RED_SIZE */
+/* reuse GL_INTERNALFORMAT_GREEN_SIZE */
+/* reuse GL_INTERNALFORMAT_BLUE_SIZE */
+/* reuse GL_INTERNALFORMAT_ALPHA_SIZE */
+/* reuse GL_INTERNALFORMAT_DEPTH_SIZE */
+/* reuse GL_INTERNALFORMAT_STENCIL_SIZE */
+/* reuse GL_INTERNALFORMAT_SHARED_SIZE */
+/* reuse GL_INTERNALFORMAT_RED_TYPE */
+/* reuse GL_INTERNALFORMAT_GREEN_TYPE */
+/* reuse GL_INTERNALFORMAT_BLUE_TYPE */
+/* reuse GL_INTERNALFORMAT_ALPHA_TYPE */
+/* reuse GL_INTERNALFORMAT_DEPTH_TYPE */
+/* reuse GL_INTERNALFORMAT_STENCIL_TYPE */
+/* reuse GL_MAX_WIDTH */
+/* reuse GL_MAX_HEIGHT */
+/* reuse GL_MAX_DEPTH */
+/* reuse GL_MAX_LAYERS */
+/* reuse GL_MAX_COMBINED_DIMENSIONS */
+/* reuse GL_COLOR_COMPONENTS */
+/* reuse GL_DEPTH_COMPONENTS */
+/* reuse GL_STENCIL_COMPONENTS */
+/* reuse GL_COLOR_RENDERABLE */
+/* reuse GL_DEPTH_RENDERABLE */
+/* reuse GL_STENCIL_RENDERABLE */
+/* reuse GL_FRAMEBUFFER_RENDERABLE */
+/* reuse GL_FRAMEBUFFER_RENDERABLE_LAYERED */
+/* reuse GL_FRAMEBUFFER_BLEND */
+/* reuse GL_READ_PIXELS */
+/* reuse GL_READ_PIXELS_FORMAT */
+/* reuse GL_READ_PIXELS_TYPE */
+/* reuse GL_TEXTURE_IMAGE_FORMAT */
+/* reuse GL_TEXTURE_IMAGE_TYPE */
+/* reuse GL_GET_TEXTURE_IMAGE_FORMAT */
+/* reuse GL_GET_TEXTURE_IMAGE_TYPE */
+/* reuse GL_MIPMAP */
+/* reuse GL_MANUAL_GENERATE_MIPMAP */
+/* reuse GL_AUTO_GENERATE_MIPMAP */
+/* reuse GL_COLOR_ENCODING */
+/* reuse GL_SRGB_READ */
+/* reuse GL_SRGB_WRITE */
+/* reuse GL_FILTER */
+/* reuse GL_VERTEX_TEXTURE */
+/* reuse GL_TESS_CONTROL_TEXTURE */
+/* reuse GL_TESS_EVALUATION_TEXTURE */
+/* reuse GL_GEOMETRY_TEXTURE */
+/* reuse GL_FRAGMENT_TEXTURE */
+/* reuse GL_COMPUTE_TEXTURE */
+/* reuse GL_TEXTURE_SHADOW */
+/* reuse GL_TEXTURE_GATHER */
+/* reuse GL_TEXTURE_GATHER_SHADOW */
+/* reuse GL_SHADER_IMAGE_LOAD */
+/* reuse GL_SHADER_IMAGE_STORE */
+/* reuse GL_SHADER_IMAGE_ATOMIC */
+/* reuse GL_IMAGE_TEXEL_SIZE */
+/* reuse GL_IMAGE_COMPATIBILITY_CLASS */
+/* reuse GL_IMAGE_PIXEL_FORMAT */
+/* reuse GL_IMAGE_PIXEL_TYPE */
+/* reuse GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_TEST */
+/* reuse GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_TEST */
+/* reuse GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_WRITE */
+/* reuse GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_WRITE */
+/* reuse GL_TEXTURE_COMPRESSED_BLOCK_WIDTH */
+/* reuse GL_TEXTURE_COMPRESSED_BLOCK_HEIGHT */
+/* reuse GL_TEXTURE_COMPRESSED_BLOCK_SIZE */
+/* reuse GL_CLEAR_BUFFER */
+/* reuse GL_TEXTURE_VIEW */
+/* reuse GL_VIEW_COMPATIBILITY_CLASS */
+/* reuse GL_FULL_SUPPORT */
+/* reuse GL_CAVEAT_SUPPORT */
+/* reuse GL_IMAGE_CLASS_4_X_32 */
+/* reuse GL_IMAGE_CLASS_2_X_32 */
+/* reuse GL_IMAGE_CLASS_1_X_32 */
+/* reuse GL_IMAGE_CLASS_4_X_16 */
+/* reuse GL_IMAGE_CLASS_2_X_16 */
+/* reuse GL_IMAGE_CLASS_1_X_16 */
+/* reuse GL_IMAGE_CLASS_4_X_8 */
+/* reuse GL_IMAGE_CLASS_2_X_8 */
+/* reuse GL_IMAGE_CLASS_1_X_8 */
+/* reuse GL_IMAGE_CLASS_11_11_10 */
+/* reuse GL_IMAGE_CLASS_10_10_10_2 */
+/* reuse GL_VIEW_CLASS_128_BITS */
+/* reuse GL_VIEW_CLASS_96_BITS */
+/* reuse GL_VIEW_CLASS_64_BITS */
+/* reuse GL_VIEW_CLASS_48_BITS */
+/* reuse GL_VIEW_CLASS_32_BITS */
+/* reuse GL_VIEW_CLASS_24_BITS */
+/* reuse GL_VIEW_CLASS_16_BITS */
+/* reuse GL_VIEW_CLASS_8_BITS */
+/* reuse GL_VIEW_CLASS_S3TC_DXT1_RGB */
+/* reuse GL_VIEW_CLASS_S3TC_DXT1_RGBA */
+/* reuse GL_VIEW_CLASS_S3TC_DXT3_RGBA */
+/* reuse GL_VIEW_CLASS_S3TC_DXT5_RGBA */
+/* reuse GL_VIEW_CLASS_RGTC1_RED */
+/* reuse GL_VIEW_CLASS_RGTC2_RG */
+/* reuse GL_VIEW_CLASS_BPTC_UNORM */
+/* reuse GL_VIEW_CLASS_BPTC_FLOAT */
+/* Reuse tokens from ARB_invalidate_subdata (none) */
+/* Reuse tokens from ARB_multi_draw_indirect (none) */
+/* Reuse tokens from ARB_program_interface_query */
+/* reuse GL_UNIFORM */
+/* reuse GL_UNIFORM_BLOCK */
+/* reuse GL_PROGRAM_INPUT */
+/* reuse GL_PROGRAM_OUTPUT */
+/* reuse GL_BUFFER_VARIABLE */
+/* reuse GL_SHADER_STORAGE_BLOCK */
+/* reuse GL_VERTEX_SUBROUTINE */
+/* reuse GL_TESS_CONTROL_SUBROUTINE */
+/* reuse GL_TESS_EVALUATION_SUBROUTINE */
+/* reuse GL_GEOMETRY_SUBROUTINE */
+/* reuse GL_FRAGMENT_SUBROUTINE */
+/* reuse GL_COMPUTE_SUBROUTINE */
+/* reuse GL_VERTEX_SUBROUTINE_UNIFORM */
+/* reuse GL_TESS_CONTROL_SUBROUTINE_UNIFORM */
+/* reuse GL_TESS_EVALUATION_SUBROUTINE_UNIFORM */
+/* reuse GL_GEOMETRY_SUBROUTINE_UNIFORM */
+/* reuse GL_FRAGMENT_SUBROUTINE_UNIFORM */
+/* reuse GL_COMPUTE_SUBROUTINE_UNIFORM */
+/* reuse GL_TRANSFORM_FEEDBACK_VARYING */
+/* reuse GL_ACTIVE_RESOURCES */
+/* reuse GL_MAX_NAME_LENGTH */
+/* reuse GL_MAX_NUM_ACTIVE_VARIABLES */
+/* reuse GL_MAX_NUM_COMPATIBLE_SUBROUTINES */
+/* reuse GL_NAME_LENGTH */
+/* reuse GL_TYPE */
+/* reuse GL_ARRAY_SIZE */
+/* reuse GL_OFFSET */
+/* reuse GL_BLOCK_INDEX */
+/* reuse GL_ARRAY_STRIDE */
+/* reuse GL_MATRIX_STRIDE */
+/* reuse GL_IS_ROW_MAJOR */
+/* reuse GL_ATOMIC_COUNTER_BUFFER_INDEX */
+/* reuse GL_BUFFER_BINDING */
+/* reuse GL_BUFFER_DATA_SIZE */
+/* reuse GL_NUM_ACTIVE_VARIABLES */
+/* reuse GL_ACTIVE_VARIABLES */
+/* reuse GL_REFERENCED_BY_VERTEX_SHADER */
+/* reuse GL_REFERENCED_BY_TESS_CONTROL_SHADER */
+/* reuse GL_REFERENCED_BY_TESS_EVALUATION_SHADER */
+/* reuse GL_REFERENCED_BY_GEOMETRY_SHADER */
+/* reuse GL_REFERENCED_BY_FRAGMENT_SHADER */
+/* reuse GL_REFERENCED_BY_COMPUTE_SHADER */
+/* reuse GL_TOP_LEVEL_ARRAY_SIZE */
+/* reuse GL_TOP_LEVEL_ARRAY_STRIDE */
+/* reuse GL_LOCATION */
+/* reuse GL_LOCATION_INDEX */
+/* reuse GL_IS_PER_PATCH */
+/* Reuse tokens from ARB_robust_buffer_access_behavior (none) */
+/* Reuse tokens from ARB_shader_storage_buffer_object */
+/* reuse GL_SHADER_STORAGE_BUFFER */
+/* reuse GL_SHADER_STORAGE_BUFFER_BINDING */
+/* reuse GL_SHADER_STORAGE_BUFFER_START */
+/* reuse GL_SHADER_STORAGE_BUFFER_SIZE */
+/* reuse GL_MAX_VERTEX_SHADER_STORAGE_BLOCKS */
+/* reuse GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS */
+/* reuse GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS */
+/* reuse GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS */
+/* reuse GL_MAX_FRAGMENT_SHADER_STORAGE_BLOCKS */
+/* reuse GL_MAX_COMPUTE_SHADER_STORAGE_BLOCKS */
+/* reuse GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS */
+/* reuse GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS */
+/* reuse GL_MAX_SHADER_STORAGE_BLOCK_SIZE */
+/* reuse GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT */
+/* reuse GL_SHADER_STORAGE_BARRIER_BIT */
+/* reuse GL_MAX_COMBINED_SHADER_OUTPUT_RESOURCES */
+/* Reuse tokens from ARB_stencil_texturing */
+/* reuse GL_DEPTH_STENCIL_TEXTURE_MODE */
+/* Reuse tokens from ARB_texture_buffer_range */
+/* reuse GL_TEXTURE_BUFFER_OFFSET */
+/* reuse GL_TEXTURE_BUFFER_SIZE */
+/* reuse GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT */
+/* Reuse tokens from ARB_texture_query_levels (none) */
+/* Reuse tokens from ARB_texture_storage_multisample (none) */
+/* Reuse tokens from ARB_texture_view */
+/* reuse GL_TEXTURE_VIEW_MIN_LEVEL */
+/* reuse GL_TEXTURE_VIEW_NUM_LEVELS */
+/* reuse GL_TEXTURE_VIEW_MIN_LAYER */
+/* reuse GL_TEXTURE_VIEW_NUM_LAYERS */
+/* reuse GL_TEXTURE_IMMUTABLE_LEVELS */
+/* Reuse tokens from ARB_vertex_attrib_binding */
+/* reuse GL_VERTEX_ATTRIB_BINDING */
+/* reuse GL_VERTEX_ATTRIB_RELATIVE_OFFSET */
+/* reuse GL_VERTEX_BINDING_DIVISOR */
+/* reuse GL_VERTEX_BINDING_OFFSET */
+/* reuse GL_VERTEX_BINDING_STRIDE */
+/* reuse GL_MAX_VERTEX_ATTRIB_RELATIVE_OFFSET */
+/* reuse GL_MAX_VERTEX_ATTRIB_BINDINGS */
+#endif
+
#ifndef GL_ARB_multitexture
#define GL_TEXTURE0_ARB 0x84C0
#define GL_TEXTURE1_ARB 0x84C1
@@ -1751,9 +2012,6 @@ extern "C" {
#define GL_RENDERBUFFER_STENCIL_SIZE 0x8D55
#define GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE 0x8D56
#define GL_MAX_SAMPLES 0x8D57
-#endif
-
-#ifndef GL_ARB_framebuffer_object_DEPRECATED
#define GL_INDEX 0x8222
#define GL_TEXTURE_LUMINANCE_TYPE 0x8C14
#define GL_TEXTURE_INTENSITY_TYPE 0x8C15
@@ -1985,6 +2243,7 @@ extern "C" {
#ifndef GL_ARB_texture_gather
#define GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET_ARB 0x8E5E
#define GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET_ARB 0x8E5F
+#define GL_MAX_PROGRAM_TEXTURE_GATHER_COMPONENTS_ARB 0x8F9F
#endif
#ifndef GL_ARB_texture_query_lod
@@ -2162,6 +2421,7 @@ extern "C" {
#define GL_MEDIUM_INT 0x8DF4
#define GL_HIGH_INT 0x8DF5
#define GL_SHADER_COMPILER 0x8DFA
+#define GL_SHADER_BINARY_FORMATS 0x8DF8
#define GL_NUM_SHADER_BINARY_FORMATS 0x8DF9
#define GL_MAX_VERTEX_UNIFORM_VECTORS 0x8DFB
#define GL_MAX_VARYING_VECTORS 0x8DFC
@@ -2404,6 +2664,386 @@ extern "C" {
#define GL_TEXTURE_IMMUTABLE_FORMAT 0x912F
#endif
+#ifndef GL_KHR_texture_compression_astc_ldr
+#define GL_COMPRESSED_RGBA_ASTC_4x4_KHR 0x93B0
+#define GL_COMPRESSED_RGBA_ASTC_5x4_KHR 0x93B1
+#define GL_COMPRESSED_RGBA_ASTC_5x5_KHR 0x93B2
+#define GL_COMPRESSED_RGBA_ASTC_6x5_KHR 0x93B3
+#define GL_COMPRESSED_RGBA_ASTC_6x6_KHR 0x93B4
+#define GL_COMPRESSED_RGBA_ASTC_8x5_KHR 0x93B5
+#define GL_COMPRESSED_RGBA_ASTC_8x6_KHR 0x93B6
+#define GL_COMPRESSED_RGBA_ASTC_8x8_KHR 0x93B7
+#define GL_COMPRESSED_RGBA_ASTC_10x5_KHR 0x93B8
+#define GL_COMPRESSED_RGBA_ASTC_10x6_KHR 0x93B9
+#define GL_COMPRESSED_RGBA_ASTC_10x8_KHR 0x93BA
+#define GL_COMPRESSED_RGBA_ASTC_10x10_KHR 0x93BB
+#define GL_COMPRESSED_RGBA_ASTC_12x10_KHR 0x93BC
+#define GL_COMPRESSED_RGBA_ASTC_12x12_KHR 0x93BD
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR 0x93D0
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR 0x93D1
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR 0x93D2
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR 0x93D3
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR 0x93D4
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR 0x93D5
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR 0x93D6
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR 0x93D7
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR 0x93D8
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x6_KHR 0x93D9
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x8_KHR 0x93DA
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR 0x93DB
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x10_KHR 0x93DC
+#define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR 0x93DD
+#endif
+
+#ifndef GL_KHR_debug
+#define GL_DEBUG_OUTPUT_SYNCHRONOUS 0x8242
+#define GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH 0x8243
+#define GL_DEBUG_CALLBACK_FUNCTION 0x8244
+#define GL_DEBUG_CALLBACK_USER_PARAM 0x8245
+#define GL_DEBUG_SOURCE_API 0x8246
+#define GL_DEBUG_SOURCE_WINDOW_SYSTEM 0x8247
+#define GL_DEBUG_SOURCE_SHADER_COMPILER 0x8248
+#define GL_DEBUG_SOURCE_THIRD_PARTY 0x8249
+#define GL_DEBUG_SOURCE_APPLICATION 0x824A
+#define GL_DEBUG_SOURCE_OTHER 0x824B
+#define GL_DEBUG_TYPE_ERROR 0x824C
+#define GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR 0x824D
+#define GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR 0x824E
+#define GL_DEBUG_TYPE_PORTABILITY 0x824F
+#define GL_DEBUG_TYPE_PERFORMANCE 0x8250
+#define GL_DEBUG_TYPE_OTHER 0x8251
+#define GL_DEBUG_TYPE_MARKER 0x8268
+#define GL_DEBUG_TYPE_PUSH_GROUP 0x8269
+#define GL_DEBUG_TYPE_POP_GROUP 0x826A
+#define GL_DEBUG_SEVERITY_NOTIFICATION 0x826B
+#define GL_MAX_DEBUG_GROUP_STACK_DEPTH 0x826C
+#define GL_DEBUG_GROUP_STACK_DEPTH 0x826D
+#define GL_BUFFER 0x82E0
+#define GL_SHADER 0x82E1
+#define GL_PROGRAM 0x82E2
+#define GL_QUERY 0x82E3
+#define GL_PROGRAM_PIPELINE 0x82E4
+#define GL_SAMPLER 0x82E6
+#define GL_DISPLAY_LIST 0x82E7
+/* DISPLAY_LIST used in compatibility profile only */
+#define GL_MAX_LABEL_LENGTH 0x82E8
+#define GL_MAX_DEBUG_MESSAGE_LENGTH 0x9143
+#define GL_MAX_DEBUG_LOGGED_MESSAGES 0x9144
+#define GL_DEBUG_LOGGED_MESSAGES 0x9145
+#define GL_DEBUG_SEVERITY_HIGH 0x9146
+#define GL_DEBUG_SEVERITY_MEDIUM 0x9147
+#define GL_DEBUG_SEVERITY_LOW 0x9148
+#define GL_DEBUG_OUTPUT 0x92E0
+#define GL_CONTEXT_FLAG_DEBUG_BIT 0x00000002
+/* reuse GL_STACK_UNDERFLOW */
+/* reuse GL_STACK_OVERFLOW */
+#endif
+
+#ifndef GL_ARB_arrays_of_arrays
+#endif
+
+#ifndef GL_ARB_clear_buffer_object
+#endif
+
+#ifndef GL_ARB_compute_shader
+#define GL_COMPUTE_SHADER 0x91B9
+#define GL_MAX_COMPUTE_UNIFORM_BLOCKS 0x91BB
+#define GL_MAX_COMPUTE_TEXTURE_IMAGE_UNITS 0x91BC
+#define GL_MAX_COMPUTE_IMAGE_UNIFORMS 0x91BD
+#define GL_MAX_COMPUTE_SHARED_MEMORY_SIZE 0x8262
+#define GL_MAX_COMPUTE_UNIFORM_COMPONENTS 0x8263
+#define GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS 0x8264
+#define GL_MAX_COMPUTE_ATOMIC_COUNTERS 0x8265
+#define GL_MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS 0x8266
+#define GL_MAX_COMPUTE_LOCAL_INVOCATIONS 0x90EB
+#define GL_MAX_COMPUTE_WORK_GROUP_COUNT 0x91BE
+#define GL_MAX_COMPUTE_WORK_GROUP_SIZE 0x91BF
+#define GL_COMPUTE_LOCAL_WORK_SIZE 0x8267
+#define GL_UNIFORM_BLOCK_REFERENCED_BY_COMPUTE_SHADER 0x90EC
+#define GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_COMPUTE_SHADER 0x90ED
+#define GL_DISPATCH_INDIRECT_BUFFER 0x90EE
+#define GL_DISPATCH_INDIRECT_BUFFER_BINDING 0x90EF
+#define GL_COMPUTE_SHADER_BIT 0x00000020
+#endif
+
+#ifndef GL_ARB_copy_image
+#endif
+
+#ifndef GL_ARB_texture_view
+#define GL_TEXTURE_VIEW_MIN_LEVEL 0x82DB
+#define GL_TEXTURE_VIEW_NUM_LEVELS 0x82DC
+#define GL_TEXTURE_VIEW_MIN_LAYER 0x82DD
+#define GL_TEXTURE_VIEW_NUM_LAYERS 0x82DE
+#define GL_TEXTURE_IMMUTABLE_LEVELS 0x82DF
+#endif
+
+#ifndef GL_ARB_vertex_attrib_binding
+#define GL_VERTEX_ATTRIB_BINDING 0x82D4
+#define GL_VERTEX_ATTRIB_RELATIVE_OFFSET 0x82D5
+#define GL_VERTEX_BINDING_DIVISOR 0x82D6
+#define GL_VERTEX_BINDING_OFFSET 0x82D7
+#define GL_VERTEX_BINDING_STRIDE 0x82D8
+#define GL_MAX_VERTEX_ATTRIB_RELATIVE_OFFSET 0x82D9
+#define GL_MAX_VERTEX_ATTRIB_BINDINGS 0x82DA
+#endif
+
+#ifndef GL_ARB_robustness_isolation
+#endif
+
+#ifndef GL_ARB_ES3_compatibility
+#define GL_COMPRESSED_RGB8_ETC2 0x9274
+#define GL_COMPRESSED_SRGB8_ETC2 0x9275
+#define GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2 0x9276
+#define GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2 0x9277
+#define GL_COMPRESSED_RGBA8_ETC2_EAC 0x9278
+#define GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC 0x9279
+#define GL_COMPRESSED_R11_EAC 0x9270
+#define GL_COMPRESSED_SIGNED_R11_EAC 0x9271
+#define GL_COMPRESSED_RG11_EAC 0x9272
+#define GL_COMPRESSED_SIGNED_RG11_EAC 0x9273
+#define GL_PRIMITIVE_RESTART_FIXED_INDEX 0x8D69
+#define GL_ANY_SAMPLES_PASSED_CONSERVATIVE 0x8D6A
+#define GL_MAX_ELEMENT_INDEX 0x8D6B
+#endif
+
+#ifndef GL_ARB_explicit_uniform_location
+#define GL_MAX_UNIFORM_LOCATIONS 0x826E
+#endif
+
+#ifndef GL_ARB_fragment_layer_viewport
+#endif
+
+#ifndef GL_ARB_framebuffer_no_attachments
+#define GL_FRAMEBUFFER_DEFAULT_WIDTH 0x9310
+#define GL_FRAMEBUFFER_DEFAULT_HEIGHT 0x9311
+#define GL_FRAMEBUFFER_DEFAULT_LAYERS 0x9312
+#define GL_FRAMEBUFFER_DEFAULT_SAMPLES 0x9313
+#define GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS 0x9314
+#define GL_MAX_FRAMEBUFFER_WIDTH 0x9315
+#define GL_MAX_FRAMEBUFFER_HEIGHT 0x9316
+#define GL_MAX_FRAMEBUFFER_LAYERS 0x9317
+#define GL_MAX_FRAMEBUFFER_SAMPLES 0x9318
+#endif
+
+#ifndef GL_ARB_internalformat_query2
+/* reuse GL_IMAGE_FORMAT_COMPATIBILITY_TYPE */
+/* reuse GL_NUM_SAMPLE_COUNTS */
+/* reuse GL_RENDERBUFFER */
+/* reuse GL_SAMPLES */
+/* reuse GL_TEXTURE_1D */
+/* reuse GL_TEXTURE_1D_ARRAY */
+/* reuse GL_TEXTURE_2D */
+/* reuse GL_TEXTURE_2D_ARRAY */
+/* reuse GL_TEXTURE_3D */
+/* reuse GL_TEXTURE_CUBE_MAP */
+/* reuse GL_TEXTURE_CUBE_MAP_ARRAY */
+/* reuse GL_TEXTURE_RECTANGLE */
+/* reuse GL_TEXTURE_BUFFER */
+/* reuse GL_TEXTURE_2D_MULTISAMPLE */
+/* reuse GL_TEXTURE_2D_MULTISAMPLE_ARRAY */
+/* reuse GL_TEXTURE_COMPRESSED */
+#define GL_INTERNALFORMAT_SUPPORTED 0x826F
+#define GL_INTERNALFORMAT_PREFERRED 0x8270
+#define GL_INTERNALFORMAT_RED_SIZE 0x8271
+#define GL_INTERNALFORMAT_GREEN_SIZE 0x8272
+#define GL_INTERNALFORMAT_BLUE_SIZE 0x8273
+#define GL_INTERNALFORMAT_ALPHA_SIZE 0x8274
+#define GL_INTERNALFORMAT_DEPTH_SIZE 0x8275
+#define GL_INTERNALFORMAT_STENCIL_SIZE 0x8276
+#define GL_INTERNALFORMAT_SHARED_SIZE 0x8277
+#define GL_INTERNALFORMAT_RED_TYPE 0x8278
+#define GL_INTERNALFORMAT_GREEN_TYPE 0x8279
+#define GL_INTERNALFORMAT_BLUE_TYPE 0x827A
+#define GL_INTERNALFORMAT_ALPHA_TYPE 0x827B
+#define GL_INTERNALFORMAT_DEPTH_TYPE 0x827C
+#define GL_INTERNALFORMAT_STENCIL_TYPE 0x827D
+#define GL_MAX_WIDTH 0x827E
+#define GL_MAX_HEIGHT 0x827F
+#define GL_MAX_DEPTH 0x8280
+#define GL_MAX_LAYERS 0x8281
+#define GL_MAX_COMBINED_DIMENSIONS 0x8282
+#define GL_COLOR_COMPONENTS 0x8283
+#define GL_DEPTH_COMPONENTS 0x8284
+#define GL_STENCIL_COMPONENTS 0x8285
+#define GL_COLOR_RENDERABLE 0x8286
+#define GL_DEPTH_RENDERABLE 0x8287
+#define GL_STENCIL_RENDERABLE 0x8288
+#define GL_FRAMEBUFFER_RENDERABLE 0x8289
+#define GL_FRAMEBUFFER_RENDERABLE_LAYERED 0x828A
+#define GL_FRAMEBUFFER_BLEND 0x828B
+#define GL_READ_PIXELS 0x828C
+#define GL_READ_PIXELS_FORMAT 0x828D
+#define GL_READ_PIXELS_TYPE 0x828E
+#define GL_TEXTURE_IMAGE_FORMAT 0x828F
+#define GL_TEXTURE_IMAGE_TYPE 0x8290
+#define GL_GET_TEXTURE_IMAGE_FORMAT 0x8291
+#define GL_GET_TEXTURE_IMAGE_TYPE 0x8292
+#define GL_MIPMAP 0x8293
+#define GL_MANUAL_GENERATE_MIPMAP 0x8294
+#define GL_AUTO_GENERATE_MIPMAP 0x8295
+#define GL_COLOR_ENCODING 0x8296
+#define GL_SRGB_READ 0x8297
+#define GL_SRGB_WRITE 0x8298
+#define GL_SRGB_DECODE_ARB 0x8299
+#define GL_FILTER 0x829A
+#define GL_VERTEX_TEXTURE 0x829B
+#define GL_TESS_CONTROL_TEXTURE 0x829C
+#define GL_TESS_EVALUATION_TEXTURE 0x829D
+#define GL_GEOMETRY_TEXTURE 0x829E
+#define GL_FRAGMENT_TEXTURE 0x829F
+#define GL_COMPUTE_TEXTURE 0x82A0
+#define GL_TEXTURE_SHADOW 0x82A1
+#define GL_TEXTURE_GATHER 0x82A2
+#define GL_TEXTURE_GATHER_SHADOW 0x82A3
+#define GL_SHADER_IMAGE_LOAD 0x82A4
+#define GL_SHADER_IMAGE_STORE 0x82A5
+#define GL_SHADER_IMAGE_ATOMIC 0x82A6
+#define GL_IMAGE_TEXEL_SIZE 0x82A7
+#define GL_IMAGE_COMPATIBILITY_CLASS 0x82A8
+#define GL_IMAGE_PIXEL_FORMAT 0x82A9
+#define GL_IMAGE_PIXEL_TYPE 0x82AA
+#define GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_TEST 0x82AC
+#define GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_TEST 0x82AD
+#define GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_WRITE 0x82AE
+#define GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_WRITE 0x82AF
+#define GL_TEXTURE_COMPRESSED_BLOCK_WIDTH 0x82B1
+#define GL_TEXTURE_COMPRESSED_BLOCK_HEIGHT 0x82B2
+#define GL_TEXTURE_COMPRESSED_BLOCK_SIZE 0x82B3
+#define GL_CLEAR_BUFFER 0x82B4
+#define GL_TEXTURE_VIEW 0x82B5
+#define GL_VIEW_COMPATIBILITY_CLASS 0x82B6
+#define GL_FULL_SUPPORT 0x82B7
+#define GL_CAVEAT_SUPPORT 0x82B8
+#define GL_IMAGE_CLASS_4_X_32 0x82B9
+#define GL_IMAGE_CLASS_2_X_32 0x82BA
+#define GL_IMAGE_CLASS_1_X_32 0x82BB
+#define GL_IMAGE_CLASS_4_X_16 0x82BC
+#define GL_IMAGE_CLASS_2_X_16 0x82BD
+#define GL_IMAGE_CLASS_1_X_16 0x82BE
+#define GL_IMAGE_CLASS_4_X_8 0x82BF
+#define GL_IMAGE_CLASS_2_X_8 0x82C0
+#define GL_IMAGE_CLASS_1_X_8 0x82C1
+#define GL_IMAGE_CLASS_11_11_10 0x82C2
+#define GL_IMAGE_CLASS_10_10_10_2 0x82C3
+#define GL_VIEW_CLASS_128_BITS 0x82C4
+#define GL_VIEW_CLASS_96_BITS 0x82C5
+#define GL_VIEW_CLASS_64_BITS 0x82C6
+#define GL_VIEW_CLASS_48_BITS 0x82C7
+#define GL_VIEW_CLASS_32_BITS 0x82C8
+#define GL_VIEW_CLASS_24_BITS 0x82C9
+#define GL_VIEW_CLASS_16_BITS 0x82CA
+#define GL_VIEW_CLASS_8_BITS 0x82CB
+#define GL_VIEW_CLASS_S3TC_DXT1_RGB 0x82CC
+#define GL_VIEW_CLASS_S3TC_DXT1_RGBA 0x82CD
+#define GL_VIEW_CLASS_S3TC_DXT3_RGBA 0x82CE
+#define GL_VIEW_CLASS_S3TC_DXT5_RGBA 0x82CF
+#define GL_VIEW_CLASS_RGTC1_RED 0x82D0
+#define GL_VIEW_CLASS_RGTC2_RG 0x82D1
+#define GL_VIEW_CLASS_BPTC_UNORM 0x82D2
+#define GL_VIEW_CLASS_BPTC_FLOAT 0x82D3
+#endif
+
+#ifndef GL_ARB_invalidate_subdata
+#endif
+
+#ifndef GL_ARB_multi_draw_indirect
+#endif
+
+#ifndef GL_ARB_program_interface_query
+#define GL_UNIFORM 0x92E1
+#define GL_UNIFORM_BLOCK 0x92E2
+#define GL_PROGRAM_INPUT 0x92E3
+#define GL_PROGRAM_OUTPUT 0x92E4
+#define GL_BUFFER_VARIABLE 0x92E5
+#define GL_SHADER_STORAGE_BLOCK 0x92E6
+/* reuse GL_ATOMIC_COUNTER_BUFFER */
+#define GL_VERTEX_SUBROUTINE 0x92E8
+#define GL_TESS_CONTROL_SUBROUTINE 0x92E9
+#define GL_TESS_EVALUATION_SUBROUTINE 0x92EA
+#define GL_GEOMETRY_SUBROUTINE 0x92EB
+#define GL_FRAGMENT_SUBROUTINE 0x92EC
+#define GL_COMPUTE_SUBROUTINE 0x92ED
+#define GL_VERTEX_SUBROUTINE_UNIFORM 0x92EE
+#define GL_TESS_CONTROL_SUBROUTINE_UNIFORM 0x92EF
+#define GL_TESS_EVALUATION_SUBROUTINE_UNIFORM 0x92F0
+#define GL_GEOMETRY_SUBROUTINE_UNIFORM 0x92F1
+#define GL_FRAGMENT_SUBROUTINE_UNIFORM 0x92F2
+#define GL_COMPUTE_SUBROUTINE_UNIFORM 0x92F3
+#define GL_TRANSFORM_FEEDBACK_VARYING 0x92F4
+#define GL_ACTIVE_RESOURCES 0x92F5
+#define GL_MAX_NAME_LENGTH 0x92F6
+#define GL_MAX_NUM_ACTIVE_VARIABLES 0x92F7
+#define GL_MAX_NUM_COMPATIBLE_SUBROUTINES 0x92F8
+#define GL_NAME_LENGTH 0x92F9
+#define GL_TYPE 0x92FA
+#define GL_ARRAY_SIZE 0x92FB
+#define GL_OFFSET 0x92FC
+#define GL_BLOCK_INDEX 0x92FD
+#define GL_ARRAY_STRIDE 0x92FE
+#define GL_MATRIX_STRIDE 0x92FF
+#define GL_IS_ROW_MAJOR 0x9300
+#define GL_ATOMIC_COUNTER_BUFFER_INDEX 0x9301
+#define GL_BUFFER_BINDING 0x9302
+#define GL_BUFFER_DATA_SIZE 0x9303
+#define GL_NUM_ACTIVE_VARIABLES 0x9304
+#define GL_ACTIVE_VARIABLES 0x9305
+#define GL_REFERENCED_BY_VERTEX_SHADER 0x9306
+#define GL_REFERENCED_BY_TESS_CONTROL_SHADER 0x9307
+#define GL_REFERENCED_BY_TESS_EVALUATION_SHADER 0x9308
+#define GL_REFERENCED_BY_GEOMETRY_SHADER 0x9309
+#define GL_REFERENCED_BY_FRAGMENT_SHADER 0x930A
+#define GL_REFERENCED_BY_COMPUTE_SHADER 0x930B
+#define GL_TOP_LEVEL_ARRAY_SIZE 0x930C
+#define GL_TOP_LEVEL_ARRAY_STRIDE 0x930D
+#define GL_LOCATION 0x930E
+#define GL_LOCATION_INDEX 0x930F
+#define GL_IS_PER_PATCH 0x92E7
+/* reuse GL_NUM_COMPATIBLE_SUBROUTINES */
+/* reuse GL_COMPATIBLE_SUBROUTINES */
+#endif
+
+#ifndef GL_ARB_robust_buffer_access_behavior
+#endif
+
+#ifndef GL_ARB_shader_image_size
+#endif
+
+#ifndef GL_ARB_shader_storage_buffer_object
+#define GL_SHADER_STORAGE_BUFFER 0x90D2
+#define GL_SHADER_STORAGE_BUFFER_BINDING 0x90D3
+#define GL_SHADER_STORAGE_BUFFER_START 0x90D4
+#define GL_SHADER_STORAGE_BUFFER_SIZE 0x90D5
+#define GL_MAX_VERTEX_SHADER_STORAGE_BLOCKS 0x90D6
+#define GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS 0x90D7
+#define GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS 0x90D8
+#define GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS 0x90D9
+#define GL_MAX_FRAGMENT_SHADER_STORAGE_BLOCKS 0x90DA
+#define GL_MAX_COMPUTE_SHADER_STORAGE_BLOCKS 0x90DB
+#define GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS 0x90DC
+#define GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS 0x90DD
+#define GL_MAX_SHADER_STORAGE_BLOCK_SIZE 0x90DE
+#define GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT 0x90DF
+#define GL_SHADER_STORAGE_BARRIER_BIT 0x2000
+#define GL_MAX_COMBINED_SHADER_OUTPUT_RESOURCES GL_MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS
+/* reuse GL_MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS */
+#endif
+
+#ifndef GL_ARB_stencil_texturing
+#define GL_DEPTH_STENCIL_TEXTURE_MODE 0x90EA
+#endif
+
+#ifndef GL_ARB_texture_buffer_range
+#define GL_TEXTURE_BUFFER_OFFSET 0x919D
+#define GL_TEXTURE_BUFFER_SIZE 0x919E
+#define GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT 0x919F
+#endif
+
+#ifndef GL_ARB_texture_query_levels
+#endif
+
+#ifndef GL_ARB_texture_storage_multisample
+#endif
+
#ifndef GL_EXT_abgr
#define GL_ABGR_EXT 0x8000
#endif
@@ -4260,6 +4900,8 @@ extern "C" {
#define GL_RGB4_S3TC 0x83A1
#define GL_RGBA_S3TC 0x83A2
#define GL_RGBA4_S3TC 0x83A3
+#define GL_RGBA_DXT5_S3TC 0x83A4
+#define GL_RGBA4_DXT5_S3TC 0x83A5
#endif
#ifndef GL_ATI_draw_buffers
@@ -4283,7 +4925,7 @@ extern "C" {
#endif
#ifndef GL_ATI_pixel_format_float
-#define GL_TYPE_RGBA_FLOAT_ATI 0x8820
+#define GL_RGBA_FLOAT_MODE_ATI 0x8820
#define GL_COLOR_CLEAR_UNCLAMPED_VALUE_ATI 0x8835
#endif
@@ -4373,11 +5015,37 @@ extern "C" {
#ifndef GL_ATI_vertex_attrib_array_object
#endif
+#ifndef GL_OES_byte_coordinates
+#endif
+
+#ifndef GL_OES_fixed_point
+#define GL_FIXED_OES 0x140C
+#endif
+
+#ifndef GL_OES_single_precision
+#endif
+
+#ifndef GL_OES_compressed_paletted_texture
+#define GL_PALETTE4_RGB8_OES 0x8B90
+#define GL_PALETTE4_RGBA8_OES 0x8B91
+#define GL_PALETTE4_R5_G6_B5_OES 0x8B92
+#define GL_PALETTE4_RGBA4_OES 0x8B93
+#define GL_PALETTE4_RGB5_A1_OES 0x8B94
+#define GL_PALETTE8_RGB8_OES 0x8B95
+#define GL_PALETTE8_RGBA8_OES 0x8B96
+#define GL_PALETTE8_R5_G6_B5_OES 0x8B97
+#define GL_PALETTE8_RGBA4_OES 0x8B98
+#define GL_PALETTE8_RGB5_A1_OES 0x8B99
+#endif
+
#ifndef GL_OES_read_format
#define GL_IMPLEMENTATION_COLOR_READ_TYPE_OES 0x8B9A
#define GL_IMPLEMENTATION_COLOR_READ_FORMAT_OES 0x8B9B
#endif
+#ifndef GL_OES_query_matrix
+#endif
+
#ifndef GL_EXT_depth_bounds_test
#define GL_DEPTH_BOUNDS_TEST_EXT 0x8890
#define GL_DEPTH_BOUNDS_EXT 0x8891
@@ -4743,7 +5411,7 @@ extern "C" {
#define GL_PRIMITIVES_GENERATED_NV 0x8C87
#define GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_NV 0x8C88
#define GL_RASTERIZER_DISCARD_NV 0x8C89
-#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_ATTRIBS_NV 0x8C8A
+#define GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_NV 0x8C8A
#define GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_NV 0x8C8B
#define GL_INTERLEAVED_ATTRIBS_NV 0x8C8C
#define GL_SEPARATE_ATTRIBS_NV 0x8C8D
@@ -5260,6 +5928,7 @@ extern "C" {
#endif
#ifndef GL_AMD_debug_output
+#define GL_MAX_DEBUG_MESSAGE_LENGTH_AMD 0x9143
#define GL_MAX_DEBUG_LOGGED_MESSAGES_AMD 0x9144
#define GL_DEBUG_LOGGED_MESSAGES_AMD 0x9145
#define GL_DEBUG_SEVERITY_HIGH_AMD 0x9146
@@ -5344,27 +6013,19 @@ extern "C" {
#define GL_PATH_FILL_COVER_MODE_NV 0x9082
#define GL_PATH_STROKE_COVER_MODE_NV 0x9083
#define GL_PATH_STROKE_MASK_NV 0x9084
-#define GL_PATH_SAMPLE_QUALITY_NV 0x9085
-#define GL_PATH_STROKE_BOUND_NV 0x9086
-#define GL_PATH_STROKE_OVERSAMPLE_COUNT_NV 0x9087
#define GL_COUNT_UP_NV 0x9088
#define GL_COUNT_DOWN_NV 0x9089
#define GL_PATH_OBJECT_BOUNDING_BOX_NV 0x908A
#define GL_CONVEX_HULL_NV 0x908B
-#define GL_MULTI_HULLS_NV 0x908C
#define GL_BOUNDING_BOX_NV 0x908D
#define GL_TRANSLATE_X_NV 0x908E
#define GL_TRANSLATE_Y_NV 0x908F
#define GL_TRANSLATE_2D_NV 0x9090
#define GL_TRANSLATE_3D_NV 0x9091
#define GL_AFFINE_2D_NV 0x9092
-#define GL_PROJECTIVE_2D_NV 0x9093
#define GL_AFFINE_3D_NV 0x9094
-#define GL_PROJECTIVE_3D_NV 0x9095
#define GL_TRANSPOSE_AFFINE_2D_NV 0x9096
-#define GL_TRANSPOSE_PROJECTIVE_2D_NV 0x9097
#define GL_TRANSPOSE_AFFINE_3D_NV 0x9098
-#define GL_TRANSPOSE_PROJECTIVE_3D_NV 0x9099
#define GL_UTF8_NV 0x909A
#define GL_UTF16_NV 0x909B
#define GL_BOUNDING_BOX_OF_BOUNDING_BOXES_NV 0x909C
@@ -5444,20 +6105,23 @@ extern "C" {
#define GL_GLYPH_VERTICAL_BEARING_X_BIT_NV 0x20
#define GL_GLYPH_VERTICAL_BEARING_Y_BIT_NV 0x40
#define GL_GLYPH_VERTICAL_BEARING_ADVANCE_BIT_NV 0x80
-#define GL_GLYPH_HAS_KERNING_NV 0x100
-#define GL_FONT_X_MIN_BOUNDS_NV 0x00010000
-#define GL_FONT_Y_MIN_BOUNDS_NV 0x00020000
-#define GL_FONT_X_MAX_BOUNDS_NV 0x00040000
-#define GL_FONT_Y_MAX_BOUNDS_NV 0x00080000
-#define GL_FONT_UNITS_PER_EM_NV 0x00100000
-#define GL_FONT_ASCENDER_NV 0x00200000
-#define GL_FONT_DESCENDER_NV 0x00400000
-#define GL_FONT_HEIGHT_NV 0x00800000
-#define GL_FONT_MAX_ADVANCE_WIDTH_NV 0x01000000
-#define GL_FONT_MAX_ADVANCE_HEIGHT_NV 0x02000000
-#define GL_FONT_UNDERLINE_POSITION_NV 0x04000000
-#define GL_FONT_UNDERLINE_THICKNESS_NV 0x08000000
-#define GL_FONT_HAS_KERNING_NV 0x10000000
+#define GL_GLYPH_HAS_KERNING_BIT_NV 0x100
+#define GL_FONT_X_MIN_BOUNDS_BIT_NV 0x00010000
+#define GL_FONT_Y_MIN_BOUNDS_BIT_NV 0x00020000
+#define GL_FONT_X_MAX_BOUNDS_BIT_NV 0x00040000
+#define GL_FONT_Y_MAX_BOUNDS_BIT_NV 0x00080000
+#define GL_FONT_UNITS_PER_EM_BIT_NV 0x00100000
+#define GL_FONT_ASCENDER_BIT_NV 0x00200000
+#define GL_FONT_DESCENDER_BIT_NV 0x00400000
+#define GL_FONT_HEIGHT_BIT_NV 0x00800000
+#define GL_FONT_MAX_ADVANCE_WIDTH_BIT_NV 0x01000000
+#define GL_FONT_MAX_ADVANCE_HEIGHT_BIT_NV 0x02000000
+#define GL_FONT_UNDERLINE_POSITION_BIT_NV 0x04000000
+#define GL_FONT_UNDERLINE_THICKNESS_BIT_NV 0x08000000
+#define GL_FONT_HAS_KERNING_BIT_NV 0x10000000
+/* reuse GL_PRIMARY_COLOR */
+/* reuse GL_PRIMARY_COLOR_NV */
+/* reuse GL_SECONDARY_COLOR_NV */
#endif
#ifndef GL_AMD_pinned_memory
@@ -5489,6 +6153,50 @@ extern "C" {
#define GL_QUERY_RESULT_NO_WAIT_AMD 0x9194
#endif
+#ifndef GL_NV_compute_program5
+#define GL_COMPUTE_PROGRAM_NV 0x90FB
+#define GL_COMPUTE_PROGRAM_PARAMETER_BUFFER_NV 0x90FC
+#endif
+
+#ifndef GL_NV_shader_storage_buffer_object
+#endif
+
+#ifndef GL_NV_shader_atomic_counters
+#endif
+
+#ifndef GL_NV_deep_texture3D
+#define GL_MAX_DEEP_3D_TEXTURE_WIDTH_HEIGHT_NV 0x90D0
+#define GL_MAX_DEEP_3D_TEXTURE_DEPTH_NV 0x90D1
+#endif
+
+#ifndef GL_NVX_conditional_render
+#endif
+
+#ifndef GL_AMD_sparse_texture
+#define GL_VIRTUAL_PAGE_SIZE_X_AMD 0x9195
+#define GL_VIRTUAL_PAGE_SIZE_Y_AMD 0x9196
+#define GL_VIRTUAL_PAGE_SIZE_Z_AMD 0x9197
+#define GL_MAX_SPARSE_TEXTURE_SIZE_AMD 0x9198
+#define GL_MAX_SPARSE_3D_TEXTURE_SIZE_AMD 0x9199
+#define GL_MAX_SPARSE_ARRAY_TEXTURE_LAYERS 0x919A
+#define GL_MIN_SPARSE_LEVEL_AMD 0x919B
+#define GL_MIN_LOD_WARNING_AMD 0x919C
+#define GL_TEXTURE_STORAGE_SPARSE_BIT_AMD 0x00000001
+#endif
+
+#ifndef GL_AMD_shader_trinary_minmax
+#endif
+
+#ifndef GL_INTEL_map_texture
+#define GL_TEXTURE_MEMORY_LAYOUT_INTEL 0x83FF
+#define GL_LAYOUT_DEFAULT_INTEL 0
+#define GL_LAYOUT_LINEAR_INTEL 1
+#define GL_LAYOUT_LINEAR_CPU_CACHED_INTEL 2
+#endif
+
+#ifndef GL_NV_draw_texture
+#endif
+
/*************************************************************/
@@ -5588,10 +6296,19 @@ typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLen
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,GLvoid *userParam);
#endif
+#ifndef GL_KHR_debug
+typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,GLvoid *userParam);
+#endif
+
#ifndef GL_NV_vdpau_interop
typedef GLintptr GLvdpauSurfaceNV;
#endif
+#ifndef GL_OES_fixed_point
+/* GLint must be 32 bits, a relatively safe assumption on modern CPUs */
+typedef GLint GLfixed;
+#endif
+
#ifndef GL_VERSION_1_2
#define GL_VERSION_1_2 1
#ifdef GL_GLEXT_PROTOTYPES
@@ -5601,18 +6318,6 @@ GLAPI void APIENTRY glDrawRangeElements (GLenum mode, GLuint start, GLuint end,
GLAPI void APIENTRY glTexImage3D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
GLAPI void APIENTRY glTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
GLAPI void APIENTRY glCopyTexSubImage3D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRYP PFNGLBLENDCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
-typedef void (APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode);
-typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTSPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
-typedef void (APIENTRYP PFNGLTEXIMAGE3DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
-typedef void (APIENTRYP PFNGLTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
-typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
-#endif
-
-#ifndef GL_VERSION_1_2_DEPRECATED
-#define GL_VERSION_1_2_DEPRECATED 1
-#ifdef GL_GLEXT_PROTOTYPES
GLAPI void APIENTRY glColorTable (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
GLAPI void APIENTRY glColorTableParameterfv (GLenum target, GLenum pname, const GLfloat *params);
GLAPI void APIENTRY glColorTableParameteriv (GLenum target, GLenum pname, const GLint *params);
@@ -5646,6 +6351,12 @@ GLAPI void APIENTRY glMinmax (GLenum target, GLenum internalformat, GLboolean si
GLAPI void APIENTRY glResetHistogram (GLenum target);
GLAPI void APIENTRY glResetMinmax (GLenum target);
#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLBLENDCOLORPROC) (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+typedef void (APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode);
+typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTSPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+typedef void (APIENTRYP PFNGLTEXIMAGE3DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+typedef void (APIENTRYP PFNGLTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+typedef void (APIENTRYP PFNGLCOPYTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
typedef void (APIENTRYP PFNGLCOLORTABLEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params);
typedef void (APIENTRYP PFNGLCOLORTABLEPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params);
@@ -5692,21 +6403,6 @@ GLAPI void APIENTRY glCompressedTexSubImage3D (GLenum target, GLint level, GLint
GLAPI void APIENTRY glCompressedTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
GLAPI void APIENTRY glCompressedTexSubImage1D (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
GLAPI void APIENTRY glGetCompressedTexImage (GLenum target, GLint level, GLvoid *img);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRYP PFNGLACTIVETEXTUREPROC) (GLenum texture);
-typedef void (APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLfloat value, GLboolean invert);
-typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE1DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE1DPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRYP PFNGLGETCOMPRESSEDTEXIMAGEPROC) (GLenum target, GLint level, GLvoid *img);
-#endif
-
-#ifndef GL_VERSION_1_3_DEPRECATED
-#define GL_VERSION_1_3_DEPRECATED 1
-#ifdef GL_GLEXT_PROTOTYPES
GLAPI void APIENTRY glClientActiveTexture (GLenum texture);
GLAPI void APIENTRY glMultiTexCoord1d (GLenum target, GLdouble s);
GLAPI void APIENTRY glMultiTexCoord1dv (GLenum target, const GLdouble *v);
@@ -5745,6 +6441,15 @@ GLAPI void APIENTRY glLoadTransposeMatrixd (const GLdouble *m);
GLAPI void APIENTRY glMultTransposeMatrixf (const GLfloat *m);
GLAPI void APIENTRY glMultTransposeMatrixd (const GLdouble *m);
#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLACTIVETEXTUREPROC) (GLenum texture);
+typedef void (APIENTRYP PFNGLSAMPLECOVERAGEPROC) (GLfloat value, GLboolean invert);
+typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE3DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+typedef void (APIENTRYP PFNGLCOMPRESSEDTEXIMAGE1DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+typedef void (APIENTRYP PFNGLCOMPRESSEDTEXSUBIMAGE1DPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+typedef void (APIENTRYP PFNGLGETCOMPRESSEDTEXIMAGEPROC) (GLenum target, GLint level, GLvoid *img);
typedef void (APIENTRYP PFNGLCLIENTACTIVETEXTUREPROC) (GLenum texture);
typedef void (APIENTRYP PFNGLMULTITEXCOORD1DPROC) (GLenum target, GLdouble s);
typedef void (APIENTRYP PFNGLMULTITEXCOORD1DVPROC) (GLenum target, const GLdouble *v);
@@ -5788,25 +6493,12 @@ typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXDPROC) (const GLdouble *m);
#define GL_VERSION_1_4 1
#ifdef GL_GLEXT_PROTOTYPES
GLAPI void APIENTRY glBlendFuncSeparate (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
-GLAPI void APIENTRY glMultiDrawArrays (GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount);
-GLAPI void APIENTRY glMultiDrawElements (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount);
+GLAPI void APIENTRY glMultiDrawArrays (GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+GLAPI void APIENTRY glMultiDrawElements (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
GLAPI void APIENTRY glPointParameterf (GLenum pname, GLfloat param);
GLAPI void APIENTRY glPointParameterfv (GLenum pname, const GLfloat *params);
GLAPI void APIENTRY glPointParameteri (GLenum pname, GLint param);
GLAPI void APIENTRY glPointParameteriv (GLenum pname, const GLint *params);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
-typedef void (APIENTRYP PFNGLMULTIDRAWARRAYSPROC) (GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount);
-typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount);
-typedef void (APIENTRYP PFNGLPOINTPARAMETERFPROC) (GLenum pname, GLfloat param);
-typedef void (APIENTRYP PFNGLPOINTPARAMETERFVPROC) (GLenum pname, const GLfloat *params);
-typedef void (APIENTRYP PFNGLPOINTPARAMETERIPROC) (GLenum pname, GLint param);
-typedef void (APIENTRYP PFNGLPOINTPARAMETERIVPROC) (GLenum pname, const GLint *params);
-#endif
-
-#ifndef GL_VERSION_1_4_DEPRECATED
-#define GL_VERSION_1_4_DEPRECATED 1
-#ifdef GL_GLEXT_PROTOTYPES
GLAPI void APIENTRY glFogCoordf (GLfloat coord);
GLAPI void APIENTRY glFogCoordfv (const GLfloat *coord);
GLAPI void APIENTRY glFogCoordd (GLdouble coord);
@@ -5846,6 +6538,13 @@ GLAPI void APIENTRY glWindowPos3iv (const GLint *v);
GLAPI void APIENTRY glWindowPos3s (GLshort x, GLshort y, GLshort z);
GLAPI void APIENTRY glWindowPos3sv (const GLshort *v);
#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+typedef void (APIENTRYP PFNGLMULTIDRAWARRAYSPROC) (GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+typedef void (APIENTRYP PFNGLPOINTPARAMETERFPROC) (GLenum pname, GLfloat param);
+typedef void (APIENTRYP PFNGLPOINTPARAMETERFVPROC) (GLenum pname, const GLfloat *params);
+typedef void (APIENTRYP PFNGLPOINTPARAMETERIPROC) (GLenum pname, GLint param);
+typedef void (APIENTRYP PFNGLPOINTPARAMETERIVPROC) (GLenum pname, const GLint *params);
typedef void (APIENTRYP PFNGLFOGCOORDFPROC) (GLfloat coord);
typedef void (APIENTRYP PFNGLFOGCOORDFVPROC) (const GLfloat *coord);
typedef void (APIENTRYP PFNGLFOGCOORDDPROC) (GLdouble coord);
@@ -6272,13 +6971,13 @@ typedef const GLubyte * (APIENTRYP PFNGLGETSTRINGIPROC) (GLenum name, GLuint ind
/* ARB_copy_buffer */
/* ARB_uniform_buffer_object */
#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glDrawArraysInstanced (GLenum mode, GLint first, GLsizei count, GLsizei primcount);
-GLAPI void APIENTRY glDrawElementsInstanced (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount);
+GLAPI void APIENTRY glDrawArraysInstanced (GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+GLAPI void APIENTRY glDrawElementsInstanced (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
GLAPI void APIENTRY glTexBuffer (GLenum target, GLenum internalformat, GLuint buffer);
GLAPI void APIENTRY glPrimitiveRestartIndex (GLuint index);
#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount);
-typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount);
+typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDPROC) (GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
typedef void (APIENTRYP PFNGLTEXBUFFERPROC) (GLenum target, GLenum internalformat, GLuint buffer);
typedef void (APIENTRYP PFNGLPRIMITIVERESTARTINDEXPROC) (GLuint index);
#endif
@@ -6373,6 +7072,33 @@ typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEIPROC) (GLuint buf, GLenum srcRGB,
/* ARB_texture_storage */
#endif
+#ifndef GL_VERSION_4_3
+#define GL_VERSION_4_3 1
+/* OpenGL 4.3 reuses entry points from these extensions: */
+/* ARB_arrays_of_arrays (no entry points, GLSL only) */
+/* ARB_fragment_layer_viewport (no entry points, GLSL only) */
+/* ARB_shader_image_size (no entry points, GLSL only) */
+/* ARB_ES3_compatibility (no entry points) */
+/* ARB_clear_buffer_object */
+/* ARB_compute_shader */
+/* ARB_copy_image */
+/* KHR_debug (includes ARB_debug_output commands promoted to KHR without suffixes) */
+/* ARB_explicit_uniform_location (no entry points) */
+/* ARB_framebuffer_no_attachments */
+/* ARB_internalformat_query2 */
+/* ARB_invalidate_subdata */
+/* ARB_multi_draw_indirect */
+/* ARB_program_interface_query */
+/* ARB_robust_buffer_access_behavior (no entry points) */
+/* ARB_shader_storage_buffer_object */
+/* ARB_stencil_texturing (no entry points) */
+/* ARB_texture_buffer_range */
+/* ARB_texture_query_levels (no entry points) */
+/* ARB_texture_storage_multisample */
+/* ARB_texture_view */
+/* ARB_vertex_attrib_binding */
+#endif
+
#ifndef GL_ARB_multitexture
#define GL_ARB_multitexture 1
#ifdef GL_GLEXT_PROTOTYPES
@@ -7127,13 +7853,13 @@ typedef void (APIENTRYP PFNGLCOPYBUFFERSUBDATAPROC) (GLenum readTarget, GLenum w
#ifdef GL_GLEXT_PROTOTYPES
GLAPI void APIENTRY glDrawElementsBaseVertex (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
GLAPI void APIENTRY glDrawRangeElementsBaseVertex (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
-GLAPI void APIENTRY glDrawElementsInstancedBaseVertex (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount, GLint basevertex);
-GLAPI void APIENTRY glMultiDrawElementsBaseVertex (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount, const GLint *basevertex);
+GLAPI void APIENTRY glDrawElementsInstancedBaseVertex (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+GLAPI void APIENTRY glMultiDrawElementsBaseVertex (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
#endif /* GL_GLEXT_PROTOTYPES */
typedef void (APIENTRYP PFNGLDRAWELEMENTSBASEVERTEXPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
typedef void (APIENTRYP PFNGLDRAWRANGEELEMENTSBASEVERTEXPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
-typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount, GLint basevertex);
-typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSBASEVERTEXPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount, const GLint *basevertex);
+typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXPROC) (GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSBASEVERTEXPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
#endif
#ifndef GL_ARB_fragment_coord_conventions
@@ -7811,13 +8537,13 @@ typedef void (APIENTRYP PFNGLGETNUNIFORMDVARBPROC) (GLuint program, GLint locati
#ifndef GL_ARB_base_instance
#define GL_ARB_base_instance 1
#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glDrawArraysInstancedBaseInstance (GLenum mode, GLint first, GLsizei count, GLsizei primcount, GLuint baseinstance);
-GLAPI void APIENTRY glDrawElementsInstancedBaseInstance (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount, GLuint baseinstance);
-GLAPI void APIENTRY glDrawElementsInstancedBaseVertexBaseInstance (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount, GLint basevertex, GLuint baseinstance);
+GLAPI void APIENTRY glDrawArraysInstancedBaseInstance (GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+GLAPI void APIENTRY glDrawElementsInstancedBaseInstance (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance);
+GLAPI void APIENTRY glDrawElementsInstancedBaseVertexBaseInstance (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDBASEINSTANCEPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount, GLuint baseinstance);
-typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEINSTANCEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount, GLuint baseinstance);
-typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount, GLint basevertex, GLuint baseinstance);
+typedef void (APIENTRYP PFNGLDRAWARRAYSINSTANCEDBASEINSTANCEPROC) (GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEINSTANCEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance);
+typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCEPROC) (GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
#endif
#ifndef GL_ARB_shading_language_420pack
@@ -7827,11 +8553,11 @@ typedef void (APIENTRYP PFNGLDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCEPROC) (G
#ifndef GL_ARB_transform_feedback_instanced
#define GL_ARB_transform_feedback_instanced 1
#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glDrawTransformFeedbackInstanced (GLenum mode, GLuint id, GLsizei primcount);
-GLAPI void APIENTRY glDrawTransformFeedbackStreamInstanced (GLenum mode, GLuint id, GLuint stream, GLsizei primcount);
+GLAPI void APIENTRY glDrawTransformFeedbackInstanced (GLenum mode, GLuint id, GLsizei instancecount);
+GLAPI void APIENTRY glDrawTransformFeedbackStreamInstanced (GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKINSTANCEDPROC) (GLenum mode, GLuint id, GLsizei primcount);
-typedef void (APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKSTREAMINSTANCEDPROC) (GLenum mode, GLuint id, GLuint stream, GLsizei primcount);
+typedef void (APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKINSTANCEDPROC) (GLenum mode, GLuint id, GLsizei instancecount);
+typedef void (APIENTRYP PFNGLDRAWTRANSFORMFEEDBACKSTREAMINSTANCEDPROC) (GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
#endif
#ifndef GL_ARB_compressed_texture_pixel_storage
@@ -7894,6 +8620,242 @@ typedef void (APIENTRYP PFNGLTEXTURESTORAGE2DEXTPROC) (GLuint texture, GLenum ta
typedef void (APIENTRYP PFNGLTEXTURESTORAGE3DEXTPROC) (GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
#endif
+#ifndef GL_KHR_texture_compression_astc_ldr
+#define GL_KHR_texture_compression_astc_ldr 1
+#endif
+
+#ifndef GL_KHR_debug
+#define GL_KHR_debug 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glDebugMessageControl (GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
+GLAPI void APIENTRY glDebugMessageInsert (GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf);
+GLAPI void APIENTRY glDebugMessageCallback (GLDEBUGPROC callback, const void *userParam);
+GLAPI GLuint APIENTRY glGetDebugMessageLog (GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog);
+GLAPI void APIENTRY glPushDebugGroup (GLenum source, GLuint id, GLsizei length, const GLchar *message);
+GLAPI void APIENTRY glPopDebugGroup (void);
+GLAPI void APIENTRY glObjectLabel (GLenum identifier, GLuint name, GLsizei length, const GLchar *label);
+GLAPI void APIENTRY glGetObjectLabel (GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label);
+GLAPI void APIENTRY glObjectPtrLabel (const void *ptr, GLsizei length, const GLchar *label);
+GLAPI void APIENTRY glGetObjectPtrLabel (const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLDEBUGMESSAGECONTROLPROC) (GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
+typedef void (APIENTRYP PFNGLDEBUGMESSAGEINSERTPROC) (GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf);
+typedef void (APIENTRYP PFNGLDEBUGMESSAGECALLBACKPROC) (GLDEBUGPROC callback, const void *userParam);
+typedef GLuint (APIENTRYP PFNGLGETDEBUGMESSAGELOGPROC) (GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog);
+typedef void (APIENTRYP PFNGLPUSHDEBUGGROUPPROC) (GLenum source, GLuint id, GLsizei length, const GLchar *message);
+typedef void (APIENTRYP PFNGLPOPDEBUGGROUPPROC) (void);
+typedef void (APIENTRYP PFNGLOBJECTLABELPROC) (GLenum identifier, GLuint name, GLsizei length, const GLchar *label);
+typedef void (APIENTRYP PFNGLGETOBJECTLABELPROC) (GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label);
+typedef void (APIENTRYP PFNGLOBJECTPTRLABELPROC) (const void *ptr, GLsizei length, const GLchar *label);
+typedef void (APIENTRYP PFNGLGETOBJECTPTRLABELPROC) (const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label);
+#endif
+
+#ifndef GL_ARB_arrays_of_arrays
+#define GL_ARB_arrays_of_arrays 1
+#endif
+
+#ifndef GL_ARB_clear_buffer_object
+#define GL_ARB_clear_buffer_object 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glClearBufferData (GLenum target, GLenum internalformat, GLenum format, GLenum type, const void *data);
+GLAPI void APIENTRY glClearBufferSubData (GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data);
+GLAPI void APIENTRY glClearNamedBufferDataEXT (GLuint buffer, GLenum internalformat, GLenum format, GLenum type, const void *data);
+GLAPI void APIENTRY glClearNamedBufferSubDataEXT (GLuint buffer, GLenum internalformat, GLenum format, GLenum type, GLsizeiptr offset, GLsizeiptr size, const void *data);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLCLEARBUFFERDATAPROC) (GLenum target, GLenum internalformat, GLenum format, GLenum type, const void *data);
+typedef void (APIENTRYP PFNGLCLEARBUFFERSUBDATAPROC) (GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data);
+typedef void (APIENTRYP PFNGLCLEARNAMEDBUFFERDATAEXTPROC) (GLuint buffer, GLenum internalformat, GLenum format, GLenum type, const void *data);
+typedef void (APIENTRYP PFNGLCLEARNAMEDBUFFERSUBDATAEXTPROC) (GLuint buffer, GLenum internalformat, GLenum format, GLenum type, GLsizeiptr offset, GLsizeiptr size, const void *data);
+#endif
+
+#ifndef GL_ARB_compute_shader
+#define GL_ARB_compute_shader 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glDispatchCompute (GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z);
+GLAPI void APIENTRY glDispatchComputeIndirect (GLintptr indirect);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLDISPATCHCOMPUTEPROC) (GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z);
+typedef void (APIENTRYP PFNGLDISPATCHCOMPUTEINDIRECTPROC) (GLintptr indirect);
+#endif
+
+#ifndef GL_ARB_copy_image
+#define GL_ARB_copy_image 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glCopyImageSubData (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);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLCOPYIMAGESUBDATAPROC) (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);
+#endif
+
+#ifndef GL_ARB_texture_view
+#define GL_ARB_texture_view 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glTextureView (GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLTEXTUREVIEWPROC) (GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers);
+#endif
+
+#ifndef GL_ARB_vertex_attrib_binding
+#define GL_ARB_vertex_attrib_binding 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glBindVertexBuffer (GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+GLAPI void APIENTRY glVertexAttribFormat (GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset);
+GLAPI void APIENTRY glVertexAttribIFormat (GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+GLAPI void APIENTRY glVertexAttribLFormat (GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+GLAPI void APIENTRY glVertexAttribBinding (GLuint attribindex, GLuint bindingindex);
+GLAPI void APIENTRY glVertexBindingDivisor (GLuint bindingindex, GLuint divisor);
+GLAPI void APIENTRY glVertexArrayBindVertexBufferEXT (GLuint vaobj, GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+GLAPI void APIENTRY glVertexArrayVertexAttribFormatEXT (GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset);
+GLAPI void APIENTRY glVertexArrayVertexAttribIFormatEXT (GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+GLAPI void APIENTRY glVertexArrayVertexAttribLFormatEXT (GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+GLAPI void APIENTRY glVertexArrayVertexAttribBindingEXT (GLuint vaobj, GLuint attribindex, GLuint bindingindex);
+GLAPI void APIENTRY glVertexArrayVertexBindingDivisorEXT (GLuint vaobj, GLuint bindingindex, GLuint divisor);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLBINDVERTEXBUFFERPROC) (GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+typedef void (APIENTRYP PFNGLVERTEXATTRIBFORMATPROC) (GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset);
+typedef void (APIENTRYP PFNGLVERTEXATTRIBIFORMATPROC) (GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+typedef void (APIENTRYP PFNGLVERTEXATTRIBLFORMATPROC) (GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+typedef void (APIENTRYP PFNGLVERTEXATTRIBBINDINGPROC) (GLuint attribindex, GLuint bindingindex);
+typedef void (APIENTRYP PFNGLVERTEXBINDINGDIVISORPROC) (GLuint bindingindex, GLuint divisor);
+typedef void (APIENTRYP PFNGLVERTEXARRAYBINDVERTEXBUFFEREXTPROC) (GLuint vaobj, GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+typedef void (APIENTRYP PFNGLVERTEXARRAYVERTEXATTRIBFORMATEXTPROC) (GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset);
+typedef void (APIENTRYP PFNGLVERTEXARRAYVERTEXATTRIBIFORMATEXTPROC) (GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+typedef void (APIENTRYP PFNGLVERTEXARRAYVERTEXATTRIBLFORMATEXTPROC) (GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+typedef void (APIENTRYP PFNGLVERTEXARRAYVERTEXATTRIBBINDINGEXTPROC) (GLuint vaobj, GLuint attribindex, GLuint bindingindex);
+typedef void (APIENTRYP PFNGLVERTEXARRAYVERTEXBINDINGDIVISOREXTPROC) (GLuint vaobj, GLuint bindingindex, GLuint divisor);
+#endif
+
+#ifndef GL_ARB_robustness_isolation
+#define GL_ARB_robustness_isolation 1
+#endif
+
+#ifndef GL_ARB_ES3_compatibility
+#define GL_ARB_ES3_compatibility 1
+#endif
+
+#ifndef GL_ARB_explicit_uniform_location
+#define GL_ARB_explicit_uniform_location 1
+#endif
+
+#ifndef GL_ARB_fragment_layer_viewport
+#define GL_ARB_fragment_layer_viewport 1
+#endif
+
+#ifndef GL_ARB_framebuffer_no_attachments
+#define GL_ARB_framebuffer_no_attachments 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glFramebufferParameteri (GLenum target, GLenum pname, GLint param);
+GLAPI void APIENTRY glGetFramebufferParameteriv (GLenum target, GLenum pname, GLint *params);
+GLAPI void APIENTRY glNamedFramebufferParameteriEXT (GLuint framebuffer, GLenum pname, GLint param);
+GLAPI void APIENTRY glGetNamedFramebufferParameterivEXT (GLuint framebuffer, GLenum pname, GLint *params);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLFRAMEBUFFERPARAMETERIPROC) (GLenum target, GLenum pname, GLint param);
+typedef void (APIENTRYP PFNGLGETFRAMEBUFFERPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params);
+typedef void (APIENTRYP PFNGLNAMEDFRAMEBUFFERPARAMETERIEXTPROC) (GLuint framebuffer, GLenum pname, GLint param);
+typedef void (APIENTRYP PFNGLGETNAMEDFRAMEBUFFERPARAMETERIVEXTPROC) (GLuint framebuffer, GLenum pname, GLint *params);
+#endif
+
+#ifndef GL_ARB_internalformat_query2
+#define GL_ARB_internalformat_query2 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glGetInternalformati64v (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLGETINTERNALFORMATI64VPROC) (GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params);
+#endif
+
+#ifndef GL_ARB_invalidate_subdata
+#define GL_ARB_invalidate_subdata 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glInvalidateTexSubImage (GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth);
+GLAPI void APIENTRY glInvalidateTexImage (GLuint texture, GLint level);
+GLAPI void APIENTRY glInvalidateBufferSubData (GLuint buffer, GLintptr offset, GLsizeiptr length);
+GLAPI void APIENTRY glInvalidateBufferData (GLuint buffer);
+GLAPI void APIENTRY glInvalidateFramebuffer (GLenum target, GLsizei numAttachments, const GLenum *attachments);
+GLAPI void APIENTRY glInvalidateSubFramebuffer (GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLINVALIDATETEXSUBIMAGEPROC) (GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth);
+typedef void (APIENTRYP PFNGLINVALIDATETEXIMAGEPROC) (GLuint texture, GLint level);
+typedef void (APIENTRYP PFNGLINVALIDATEBUFFERSUBDATAPROC) (GLuint buffer, GLintptr offset, GLsizeiptr length);
+typedef void (APIENTRYP PFNGLINVALIDATEBUFFERDATAPROC) (GLuint buffer);
+typedef void (APIENTRYP PFNGLINVALIDATEFRAMEBUFFERPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments);
+typedef void (APIENTRYP PFNGLINVALIDATESUBFRAMEBUFFERPROC) (GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height);
+#endif
+
+#ifndef GL_ARB_multi_draw_indirect
+#define GL_ARB_multi_draw_indirect 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glMultiDrawArraysIndirect (GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride);
+GLAPI void APIENTRY glMultiDrawElementsIndirect (GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLMULTIDRAWARRAYSINDIRECTPROC) (GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride);
+typedef void (APIENTRYP PFNGLMULTIDRAWELEMENTSINDIRECTPROC) (GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride);
+#endif
+
+#ifndef GL_ARB_program_interface_query
+#define GL_ARB_program_interface_query 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glGetProgramInterfaceiv (GLuint program, GLenum programInterface, GLenum pname, GLint *params);
+GLAPI GLuint APIENTRY glGetProgramResourceIndex (GLuint program, GLenum programInterface, const GLchar *name);
+GLAPI void APIENTRY glGetProgramResourceName (GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
+GLAPI void APIENTRY glGetProgramResourceiv (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params);
+GLAPI GLint APIENTRY glGetProgramResourceLocation (GLuint program, GLenum programInterface, const GLchar *name);
+GLAPI GLint APIENTRY glGetProgramResourceLocationIndex (GLuint program, GLenum programInterface, const GLchar *name);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLGETPROGRAMINTERFACEIVPROC) (GLuint program, GLenum programInterface, GLenum pname, GLint *params);
+typedef GLuint (APIENTRYP PFNGLGETPROGRAMRESOURCEINDEXPROC) (GLuint program, GLenum programInterface, const GLchar *name);
+typedef void (APIENTRYP PFNGLGETPROGRAMRESOURCENAMEPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
+typedef void (APIENTRYP PFNGLGETPROGRAMRESOURCEIVPROC) (GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params);
+typedef GLint (APIENTRYP PFNGLGETPROGRAMRESOURCELOCATIONPROC) (GLuint program, GLenum programInterface, const GLchar *name);
+typedef GLint (APIENTRYP PFNGLGETPROGRAMRESOURCELOCATIONINDEXPROC) (GLuint program, GLenum programInterface, const GLchar *name);
+#endif
+
+#ifndef GL_ARB_robust_buffer_access_behavior
+#define GL_ARB_robust_buffer_access_behavior 1
+#endif
+
+#ifndef GL_ARB_shader_image_size
+#define GL_ARB_shader_image_size 1
+#endif
+
+#ifndef GL_ARB_shader_storage_buffer_object
+#define GL_ARB_shader_storage_buffer_object 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glShaderStorageBlockBinding (GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLSHADERSTORAGEBLOCKBINDINGPROC) (GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding);
+#endif
+
+#ifndef GL_ARB_stencil_texturing
+#define GL_ARB_stencil_texturing 1
+#endif
+
+#ifndef GL_ARB_texture_buffer_range
+#define GL_ARB_texture_buffer_range 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glTexBufferRange (GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+GLAPI void APIENTRY glTextureBufferRangeEXT (GLuint texture, GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLTEXBUFFERRANGEPROC) (GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+typedef void (APIENTRYP PFNGLTEXTUREBUFFERRANGEEXTPROC) (GLuint texture, GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+#endif
+
+#ifndef GL_ARB_texture_query_levels
+#define GL_ARB_texture_query_levels 1
+#endif
+
+#ifndef GL_ARB_texture_storage_multisample
+#define GL_ARB_texture_storage_multisample 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glTexStorage2DMultisample (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+GLAPI void APIENTRY glTexStorage3DMultisample (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+GLAPI void APIENTRY glTextureStorage2DMultisampleEXT (GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+GLAPI void APIENTRY glTextureStorage3DMultisampleEXT (GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLTEXSTORAGE2DMULTISAMPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+typedef void (APIENTRYP PFNGLTEXSTORAGE3DMULTISAMPLEPROC) (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+typedef void (APIENTRYP PFNGLTEXTURESTORAGE2DMULTISAMPLEEXTPROC) (GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+typedef void (APIENTRYP PFNGLTEXTURESTORAGE3DMULTISAMPLEEXTPROC) (GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+#endif
+
#ifndef GL_EXT_abgr
#define GL_EXT_abgr 1
#endif
@@ -8635,11 +9597,15 @@ GLAPI void APIENTRY glPixelTransformParameteriEXT (GLenum target, GLenum pname,
GLAPI void APIENTRY glPixelTransformParameterfEXT (GLenum target, GLenum pname, GLfloat param);
GLAPI void APIENTRY glPixelTransformParameterivEXT (GLenum target, GLenum pname, const GLint *params);
GLAPI void APIENTRY glPixelTransformParameterfvEXT (GLenum target, GLenum pname, const GLfloat *params);
+GLAPI void APIENTRY glGetPixelTransformParameterivEXT (GLenum target, GLenum pname, GLint *params);
+GLAPI void APIENTRY glGetPixelTransformParameterfvEXT (GLenum target, GLenum pname, GLfloat *params);
#endif /* GL_GLEXT_PROTOTYPES */
typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERIEXTPROC) (GLenum target, GLenum pname, GLint param);
typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERFEXTPROC) (GLenum target, GLenum pname, GLfloat param);
typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERIVEXTPROC) (GLenum target, GLenum pname, const GLint *params);
typedef void (APIENTRYP PFNGLPIXELTRANSFORMPARAMETERFVEXTPROC) (GLenum target, GLenum pname, const GLfloat *params);
+typedef void (APIENTRYP PFNGLGETPIXELTRANSFORMPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params);
+typedef void (APIENTRYP PFNGLGETPIXELTRANSFORMPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params);
#endif
#ifndef GL_EXT_pixel_transform_color_table
@@ -8991,11 +9957,11 @@ typedef void (APIENTRYP PFNGLBLENDFUNCSEPARATEINGRPROC) (GLenum sfactorRGB, GLen
#ifdef GL_GLEXT_PROTOTYPES
GLAPI void APIENTRY glVertexWeightfEXT (GLfloat weight);
GLAPI void APIENTRY glVertexWeightfvEXT (const GLfloat *weight);
-GLAPI void APIENTRY glVertexWeightPointerEXT (GLsizei size, GLenum type, GLsizei stride, const GLvoid *pointer);
+GLAPI void APIENTRY glVertexWeightPointerEXT (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
#endif /* GL_GLEXT_PROTOTYPES */
typedef void (APIENTRYP PFNGLVERTEXWEIGHTFEXTPROC) (GLfloat weight);
typedef void (APIENTRYP PFNGLVERTEXWEIGHTFVEXTPROC) (const GLfloat *weight);
-typedef void (APIENTRYP PFNGLVERTEXWEIGHTPOINTEREXTPROC) (GLsizei size, GLenum type, GLsizei stride, const GLvoid *pointer);
+typedef void (APIENTRYP PFNGLVERTEXWEIGHTPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
#endif
#ifndef GL_NV_light_max_exponent
@@ -9944,15 +10910,15 @@ typedef void (APIENTRYP PFNGLDRAWBUFFERSATIPROC) (GLsizei n, const GLenum *bufs)
/* Some NV_fragment_program entry points are shared with ARB_vertex_program. */
#ifdef GL_GLEXT_PROTOTYPES
GLAPI void APIENTRY glProgramNamedParameter4fNV (GLuint id, GLsizei len, const GLubyte *name, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
-GLAPI void APIENTRY glProgramNamedParameter4dNV (GLuint id, GLsizei len, const GLubyte *name, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
GLAPI void APIENTRY glProgramNamedParameter4fvNV (GLuint id, GLsizei len, const GLubyte *name, const GLfloat *v);
+GLAPI void APIENTRY glProgramNamedParameter4dNV (GLuint id, GLsizei len, const GLubyte *name, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
GLAPI void APIENTRY glProgramNamedParameter4dvNV (GLuint id, GLsizei len, const GLubyte *name, const GLdouble *v);
GLAPI void APIENTRY glGetProgramNamedParameterfvNV (GLuint id, GLsizei len, const GLubyte *name, GLfloat *params);
GLAPI void APIENTRY glGetProgramNamedParameterdvNV (GLuint id, GLsizei len, const GLubyte *name, GLdouble *params);
#endif /* GL_GLEXT_PROTOTYPES */
typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4FNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
-typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4DNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4FVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, const GLfloat *v);
+typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4DNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
typedef void (APIENTRYP PFNGLPROGRAMNAMEDPARAMETER4DVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, const GLdouble *v);
typedef void (APIENTRYP PFNGLGETPROGRAMNAMEDPARAMETERFVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLfloat *params);
typedef void (APIENTRYP PFNGLGETPROGRAMNAMEDPARAMETERDVNVPROC) (GLuint id, GLsizei len, const GLubyte *name, GLdouble *params);
@@ -10059,10 +11025,10 @@ typedef void (APIENTRYP PFNGLVERTEXATTRIBS4HVNVPROC) (GLuint index, GLsizei n, c
#ifndef GL_NV_pixel_data_range
#define GL_NV_pixel_data_range 1
#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glPixelDataRangeNV (GLenum target, GLsizei length, GLvoid *pointer);
+GLAPI void APIENTRY glPixelDataRangeNV (GLenum target, GLsizei length, const GLvoid *pointer);
GLAPI void APIENTRY glFlushPixelDataRangeNV (GLenum target);
#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRYP PFNGLPIXELDATARANGENVPROC) (GLenum target, GLsizei length, GLvoid *pointer);
+typedef void (APIENTRYP PFNGLPIXELDATARANGENVPROC) (GLenum target, GLsizei length, const GLvoid *pointer);
typedef void (APIENTRYP PFNGLFLUSHPIXELDATARANGENVPROC) (GLenum target);
#endif
@@ -10116,10 +11082,304 @@ typedef void (APIENTRYP PFNGLGETVERTEXATTRIBARRAYOBJECTFVATIPROC) (GLuint index,
typedef void (APIENTRYP PFNGLGETVERTEXATTRIBARRAYOBJECTIVATIPROC) (GLuint index, GLenum pname, GLint *params);
#endif
+#ifndef GL_OES_byte_coordinates
+#define GL_OES_byte_coordinates 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glMultiTexCoord1bOES (GLenum texture, GLbyte s);
+GLAPI void APIENTRY glMultiTexCoord1bvOES (GLenum texture, const GLbyte *coords);
+GLAPI void APIENTRY glMultiTexCoord2bOES (GLenum texture, GLbyte s, GLbyte t);
+GLAPI void APIENTRY glMultiTexCoord2bvOES (GLenum texture, const GLbyte *coords);
+GLAPI void APIENTRY glMultiTexCoord3bOES (GLenum texture, GLbyte s, GLbyte t, GLbyte r);
+GLAPI void APIENTRY glMultiTexCoord3bvOES (GLenum texture, const GLbyte *coords);
+GLAPI void APIENTRY glMultiTexCoord4bOES (GLenum texture, GLbyte s, GLbyte t, GLbyte r, GLbyte q);
+GLAPI void APIENTRY glMultiTexCoord4bvOES (GLenum texture, const GLbyte *coords);
+GLAPI void APIENTRY glTexCoord1bOES (GLbyte s);
+GLAPI void APIENTRY glTexCoord1bvOES (const GLbyte *coords);
+GLAPI void APIENTRY glTexCoord2bOES (GLbyte s, GLbyte t);
+GLAPI void APIENTRY glTexCoord2bvOES (const GLbyte *coords);
+GLAPI void APIENTRY glTexCoord3bOES (GLbyte s, GLbyte t, GLbyte r);
+GLAPI void APIENTRY glTexCoord3bvOES (const GLbyte *coords);
+GLAPI void APIENTRY glTexCoord4bOES (GLbyte s, GLbyte t, GLbyte r, GLbyte q);
+GLAPI void APIENTRY glTexCoord4bvOES (const GLbyte *coords);
+GLAPI void APIENTRY glVertex2bOES (GLbyte x);
+GLAPI void APIENTRY glVertex2bvOES (const GLbyte *coords);
+GLAPI void APIENTRY glVertex3bOES (GLbyte x, GLbyte y);
+GLAPI void APIENTRY glVertex3bvOES (const GLbyte *coords);
+GLAPI void APIENTRY glVertex4bOES (GLbyte x, GLbyte y, GLbyte z);
+GLAPI void APIENTRY glVertex4bvOES (const GLbyte *coords);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLMULTITEXCOORD1BOESPROC) (GLenum texture, GLbyte s);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD1BVOESPROC) (GLenum texture, const GLbyte *coords);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD2BOESPROC) (GLenum texture, GLbyte s, GLbyte t);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD2BVOESPROC) (GLenum texture, const GLbyte *coords);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD3BOESPROC) (GLenum texture, GLbyte s, GLbyte t, GLbyte r);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD3BVOESPROC) (GLenum texture, const GLbyte *coords);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD4BOESPROC) (GLenum texture, GLbyte s, GLbyte t, GLbyte r, GLbyte q);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD4BVOESPROC) (GLenum texture, const GLbyte *coords);
+typedef void (APIENTRYP PFNGLTEXCOORD1BOESPROC) (GLbyte s);
+typedef void (APIENTRYP PFNGLTEXCOORD1BVOESPROC) (const GLbyte *coords);
+typedef void (APIENTRYP PFNGLTEXCOORD2BOESPROC) (GLbyte s, GLbyte t);
+typedef void (APIENTRYP PFNGLTEXCOORD2BVOESPROC) (const GLbyte *coords);
+typedef void (APIENTRYP PFNGLTEXCOORD3BOESPROC) (GLbyte s, GLbyte t, GLbyte r);
+typedef void (APIENTRYP PFNGLTEXCOORD3BVOESPROC) (const GLbyte *coords);
+typedef void (APIENTRYP PFNGLTEXCOORD4BOESPROC) (GLbyte s, GLbyte t, GLbyte r, GLbyte q);
+typedef void (APIENTRYP PFNGLTEXCOORD4BVOESPROC) (const GLbyte *coords);
+typedef void (APIENTRYP PFNGLVERTEX2BOESPROC) (GLbyte x);
+typedef void (APIENTRYP PFNGLVERTEX2BVOESPROC) (const GLbyte *coords);
+typedef void (APIENTRYP PFNGLVERTEX3BOESPROC) (GLbyte x, GLbyte y);
+typedef void (APIENTRYP PFNGLVERTEX3BVOESPROC) (const GLbyte *coords);
+typedef void (APIENTRYP PFNGLVERTEX4BOESPROC) (GLbyte x, GLbyte y, GLbyte z);
+typedef void (APIENTRYP PFNGLVERTEX4BVOESPROC) (const GLbyte *coords);
+#endif
+
+#ifndef GL_OES_fixed_point
+#define GL_OES_fixed_point 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glAccumxOES (GLenum op, GLfixed value);
+GLAPI void APIENTRY glAlphaFuncxOES (GLenum func, GLfixed ref);
+GLAPI void APIENTRY glBitmapxOES (GLsizei width, GLsizei height, GLfixed xorig, GLfixed yorig, GLfixed xmove, GLfixed ymove, const GLubyte *bitmap);
+GLAPI void APIENTRY glBlendColorxOES (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
+GLAPI void APIENTRY glClearAccumxOES (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
+GLAPI void APIENTRY glClearColorxOES (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
+GLAPI void APIENTRY glClearDepthxOES (GLfixed depth);
+GLAPI void APIENTRY glClipPlanexOES (GLenum plane, const GLfixed *equation);
+GLAPI void APIENTRY glColor3xOES (GLfixed red, GLfixed green, GLfixed blue);
+GLAPI void APIENTRY glColor4xOES (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
+GLAPI void APIENTRY glColor3xvOES (const GLfixed *components);
+GLAPI void APIENTRY glColor4xvOES (const GLfixed *components);
+GLAPI void APIENTRY glConvolutionParameterxOES (GLenum target, GLenum pname, GLfixed param);
+GLAPI void APIENTRY glConvolutionParameterxvOES (GLenum target, GLenum pname, const GLfixed *params);
+GLAPI void APIENTRY glDepthRangexOES (GLfixed n, GLfixed f);
+GLAPI void APIENTRY glEvalCoord1xOES (GLfixed u);
+GLAPI void APIENTRY glEvalCoord2xOES (GLfixed u, GLfixed v);
+GLAPI void APIENTRY glEvalCoord1xvOES (const GLfixed *coords);
+GLAPI void APIENTRY glEvalCoord2xvOES (const GLfixed *coords);
+GLAPI void APIENTRY glFeedbackBufferxOES (GLsizei n, GLenum type, const GLfixed *buffer);
+GLAPI void APIENTRY glFogxOES (GLenum pname, GLfixed param);
+GLAPI void APIENTRY glFogxvOES (GLenum pname, const GLfixed *param);
+GLAPI void APIENTRY glFrustumxOES (GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f);
+GLAPI void APIENTRY glGetClipPlanexOES (GLenum plane, GLfixed *equation);
+GLAPI void APIENTRY glGetConvolutionParameterxvOES (GLenum target, GLenum pname, GLfixed *params);
+GLAPI void APIENTRY glGetFixedvOES (GLenum pname, GLfixed *params);
+GLAPI void APIENTRY glGetHistogramParameterxvOES (GLenum target, GLenum pname, GLfixed *params);
+GLAPI void APIENTRY glGetLightxOES (GLenum light, GLenum pname, GLfixed *params);
+GLAPI void APIENTRY glGetMapxvOES (GLenum target, GLenum query, GLfixed *v);
+GLAPI void APIENTRY glGetMaterialxOES (GLenum face, GLenum pname, GLfixed param);
+GLAPI void APIENTRY glGetPixelMapxv (GLenum map, GLint size, GLfixed *values);
+GLAPI void APIENTRY glGetTexEnvxvOES (GLenum target, GLenum pname, GLfixed *params);
+GLAPI void APIENTRY glGetTexGenxvOES (GLenum coord, GLenum pname, GLfixed *params);
+GLAPI void APIENTRY glGetTexLevelParameterxvOES (GLenum target, GLint level, GLenum pname, GLfixed *params);
+GLAPI void APIENTRY glGetTexParameterxvOES (GLenum target, GLenum pname, GLfixed *params);
+GLAPI void APIENTRY glIndexxOES (GLfixed component);
+GLAPI void APIENTRY glIndexxvOES (const GLfixed *component);
+GLAPI void APIENTRY glLightModelxOES (GLenum pname, GLfixed param);
+GLAPI void APIENTRY glLightModelxvOES (GLenum pname, const GLfixed *param);
+GLAPI void APIENTRY glLightxOES (GLenum light, GLenum pname, GLfixed param);
+GLAPI void APIENTRY glLightxvOES (GLenum light, GLenum pname, const GLfixed *params);
+GLAPI void APIENTRY glLineWidthxOES (GLfixed width);
+GLAPI void APIENTRY glLoadMatrixxOES (const GLfixed *m);
+GLAPI void APIENTRY glLoadTransposeMatrixxOES (const GLfixed *m);
+GLAPI void APIENTRY glMap1xOES (GLenum target, GLfixed u1, GLfixed u2, GLint stride, GLint order, GLfixed points);
+GLAPI void APIENTRY glMap2xOES (GLenum target, GLfixed u1, GLfixed u2, GLint ustride, GLint uorder, GLfixed v1, GLfixed v2, GLint vstride, GLint vorder, GLfixed points);
+GLAPI void APIENTRY glMapGrid1xOES (GLint n, GLfixed u1, GLfixed u2);
+GLAPI void APIENTRY glMapGrid2xOES (GLint n, GLfixed u1, GLfixed u2, GLfixed v1, GLfixed v2);
+GLAPI void APIENTRY glMaterialxOES (GLenum face, GLenum pname, GLfixed param);
+GLAPI void APIENTRY glMaterialxvOES (GLenum face, GLenum pname, const GLfixed *param);
+GLAPI void APIENTRY glMultMatrixxOES (const GLfixed *m);
+GLAPI void APIENTRY glMultTransposeMatrixxOES (const GLfixed *m);
+GLAPI void APIENTRY glMultiTexCoord1xOES (GLenum texture, GLfixed s);
+GLAPI void APIENTRY glMultiTexCoord2xOES (GLenum texture, GLfixed s, GLfixed t);
+GLAPI void APIENTRY glMultiTexCoord3xOES (GLenum texture, GLfixed s, GLfixed t, GLfixed r);
+GLAPI void APIENTRY glMultiTexCoord4xOES (GLenum texture, GLfixed s, GLfixed t, GLfixed r, GLfixed q);
+GLAPI void APIENTRY glMultiTexCoord1xvOES (GLenum texture, const GLfixed *coords);
+GLAPI void APIENTRY glMultiTexCoord2xvOES (GLenum texture, const GLfixed *coords);
+GLAPI void APIENTRY glMultiTexCoord3xvOES (GLenum texture, const GLfixed *coords);
+GLAPI void APIENTRY glMultiTexCoord4xvOES (GLenum texture, const GLfixed *coords);
+GLAPI void APIENTRY glNormal3xOES (GLfixed nx, GLfixed ny, GLfixed nz);
+GLAPI void APIENTRY glNormal3xvOES (const GLfixed *coords);
+GLAPI void APIENTRY glOrthoxOES (GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f);
+GLAPI void APIENTRY glPassThroughxOES (GLfixed token);
+GLAPI void APIENTRY glPixelMapx (GLenum map, GLint size, const GLfixed *values);
+GLAPI void APIENTRY glPixelStorex (GLenum pname, GLfixed param);
+GLAPI void APIENTRY glPixelTransferxOES (GLenum pname, GLfixed param);
+GLAPI void APIENTRY glPixelZoomxOES (GLfixed xfactor, GLfixed yfactor);
+GLAPI void APIENTRY glPointParameterxvOES (GLenum pname, const GLfixed *params);
+GLAPI void APIENTRY glPointSizexOES (GLfixed size);
+GLAPI void APIENTRY glPolygonOffsetxOES (GLfixed factor, GLfixed units);
+GLAPI void APIENTRY glPrioritizeTexturesxOES (GLsizei n, const GLuint *textures, const GLfixed *priorities);
+GLAPI void APIENTRY glRasterPos2xOES (GLfixed x, GLfixed y);
+GLAPI void APIENTRY glRasterPos3xOES (GLfixed x, GLfixed y, GLfixed z);
+GLAPI void APIENTRY glRasterPos4xOES (GLfixed x, GLfixed y, GLfixed z, GLfixed w);
+GLAPI void APIENTRY glRasterPos2xvOES (const GLfixed *coords);
+GLAPI void APIENTRY glRasterPos3xvOES (const GLfixed *coords);
+GLAPI void APIENTRY glRasterPos4xvOES (const GLfixed *coords);
+GLAPI void APIENTRY glRectxOES (GLfixed x1, GLfixed y1, GLfixed x2, GLfixed y2);
+GLAPI void APIENTRY glRectxvOES (const GLfixed *v1, const GLfixed *v2);
+GLAPI void APIENTRY glRotatexOES (GLfixed angle, GLfixed x, GLfixed y, GLfixed z);
+GLAPI void APIENTRY glSampleCoverageOES (GLfixed value, GLboolean invert);
+GLAPI void APIENTRY glScalexOES (GLfixed x, GLfixed y, GLfixed z);
+GLAPI void APIENTRY glTexCoord1xOES (GLfixed s);
+GLAPI void APIENTRY glTexCoord2xOES (GLfixed s, GLfixed t);
+GLAPI void APIENTRY glTexCoord3xOES (GLfixed s, GLfixed t, GLfixed r);
+GLAPI void APIENTRY glTexCoord4xOES (GLfixed s, GLfixed t, GLfixed r, GLfixed q);
+GLAPI void APIENTRY glTexCoord1xvOES (const GLfixed *coords);
+GLAPI void APIENTRY glTexCoord2xvOES (const GLfixed *coords);
+GLAPI void APIENTRY glTexCoord3xvOES (const GLfixed *coords);
+GLAPI void APIENTRY glTexCoord4xvOES (const GLfixed *coords);
+GLAPI void APIENTRY glTexEnvxOES (GLenum target, GLenum pname, GLfixed param);
+GLAPI void APIENTRY glTexEnvxvOES (GLenum target, GLenum pname, const GLfixed *params);
+GLAPI void APIENTRY glTexGenxOES (GLenum coord, GLenum pname, GLfixed param);
+GLAPI void APIENTRY glTexGenxvOES (GLenum coord, GLenum pname, const GLfixed *params);
+GLAPI void APIENTRY glTexParameterxOES (GLenum target, GLenum pname, GLfixed param);
+GLAPI void APIENTRY glTexParameterxvOES (GLenum target, GLenum pname, const GLfixed *params);
+GLAPI void APIENTRY glTranslatexOES (GLfixed x, GLfixed y, GLfixed z);
+GLAPI void APIENTRY glVertex2xOES (GLfixed x);
+GLAPI void APIENTRY glVertex3xOES (GLfixed x, GLfixed y);
+GLAPI void APIENTRY glVertex4xOES (GLfixed x, GLfixed y, GLfixed z);
+GLAPI void APIENTRY glVertex2xvOES (const GLfixed *coords);
+GLAPI void APIENTRY glVertex3xvOES (const GLfixed *coords);
+GLAPI void APIENTRY glVertex4xvOES (const GLfixed *coords);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLACCUMXOESPROC) (GLenum op, GLfixed value);
+typedef void (APIENTRYP PFNGLALPHAFUNCXOESPROC) (GLenum func, GLfixed ref);
+typedef void (APIENTRYP PFNGLBITMAPXOESPROC) (GLsizei width, GLsizei height, GLfixed xorig, GLfixed yorig, GLfixed xmove, GLfixed ymove, const GLubyte *bitmap);
+typedef void (APIENTRYP PFNGLBLENDCOLORXOESPROC) (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
+typedef void (APIENTRYP PFNGLCLEARACCUMXOESPROC) (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
+typedef void (APIENTRYP PFNGLCLEARCOLORXOESPROC) (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
+typedef void (APIENTRYP PFNGLCLEARDEPTHXOESPROC) (GLfixed depth);
+typedef void (APIENTRYP PFNGLCLIPPLANEXOESPROC) (GLenum plane, const GLfixed *equation);
+typedef void (APIENTRYP PFNGLCOLOR3XOESPROC) (GLfixed red, GLfixed green, GLfixed blue);
+typedef void (APIENTRYP PFNGLCOLOR4XOESPROC) (GLfixed red, GLfixed green, GLfixed blue, GLfixed alpha);
+typedef void (APIENTRYP PFNGLCOLOR3XVOESPROC) (const GLfixed *components);
+typedef void (APIENTRYP PFNGLCOLOR4XVOESPROC) (const GLfixed *components);
+typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERXOESPROC) (GLenum target, GLenum pname, GLfixed param);
+typedef void (APIENTRYP PFNGLCONVOLUTIONPARAMETERXVOESPROC) (GLenum target, GLenum pname, const GLfixed *params);
+typedef void (APIENTRYP PFNGLDEPTHRANGEXOESPROC) (GLfixed n, GLfixed f);
+typedef void (APIENTRYP PFNGLEVALCOORD1XOESPROC) (GLfixed u);
+typedef void (APIENTRYP PFNGLEVALCOORD2XOESPROC) (GLfixed u, GLfixed v);
+typedef void (APIENTRYP PFNGLEVALCOORD1XVOESPROC) (const GLfixed *coords);
+typedef void (APIENTRYP PFNGLEVALCOORD2XVOESPROC) (const GLfixed *coords);
+typedef void (APIENTRYP PFNGLFEEDBACKBUFFERXOESPROC) (GLsizei n, GLenum type, const GLfixed *buffer);
+typedef void (APIENTRYP PFNGLFOGXOESPROC) (GLenum pname, GLfixed param);
+typedef void (APIENTRYP PFNGLFOGXVOESPROC) (GLenum pname, const GLfixed *param);
+typedef void (APIENTRYP PFNGLFRUSTUMXOESPROC) (GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f);
+typedef void (APIENTRYP PFNGLGETCLIPPLANEXOESPROC) (GLenum plane, GLfixed *equation);
+typedef void (APIENTRYP PFNGLGETCONVOLUTIONPARAMETERXVOESPROC) (GLenum target, GLenum pname, GLfixed *params);
+typedef void (APIENTRYP PFNGLGETFIXEDVOESPROC) (GLenum pname, GLfixed *params);
+typedef void (APIENTRYP PFNGLGETHISTOGRAMPARAMETERXVOESPROC) (GLenum target, GLenum pname, GLfixed *params);
+typedef void (APIENTRYP PFNGLGETLIGHTXOESPROC) (GLenum light, GLenum pname, GLfixed *params);
+typedef void (APIENTRYP PFNGLGETMAPXVOESPROC) (GLenum target, GLenum query, GLfixed *v);
+typedef void (APIENTRYP PFNGLGETMATERIALXOESPROC) (GLenum face, GLenum pname, GLfixed param);
+typedef void (APIENTRYP PFNGLGETPIXELMAPXVPROC) (GLenum map, GLint size, GLfixed *values);
+typedef void (APIENTRYP PFNGLGETTEXENVXVOESPROC) (GLenum target, GLenum pname, GLfixed *params);
+typedef void (APIENTRYP PFNGLGETTEXGENXVOESPROC) (GLenum coord, GLenum pname, GLfixed *params);
+typedef void (APIENTRYP PFNGLGETTEXLEVELPARAMETERXVOESPROC) (GLenum target, GLint level, GLenum pname, GLfixed *params);
+typedef void (APIENTRYP PFNGLGETTEXPARAMETERXVOESPROC) (GLenum target, GLenum pname, GLfixed *params);
+typedef void (APIENTRYP PFNGLINDEXXOESPROC) (GLfixed component);
+typedef void (APIENTRYP PFNGLINDEXXVOESPROC) (const GLfixed *component);
+typedef void (APIENTRYP PFNGLLIGHTMODELXOESPROC) (GLenum pname, GLfixed param);
+typedef void (APIENTRYP PFNGLLIGHTMODELXVOESPROC) (GLenum pname, const GLfixed *param);
+typedef void (APIENTRYP PFNGLLIGHTXOESPROC) (GLenum light, GLenum pname, GLfixed param);
+typedef void (APIENTRYP PFNGLLIGHTXVOESPROC) (GLenum light, GLenum pname, const GLfixed *params);
+typedef void (APIENTRYP PFNGLLINEWIDTHXOESPROC) (GLfixed width);
+typedef void (APIENTRYP PFNGLLOADMATRIXXOESPROC) (const GLfixed *m);
+typedef void (APIENTRYP PFNGLLOADTRANSPOSEMATRIXXOESPROC) (const GLfixed *m);
+typedef void (APIENTRYP PFNGLMAP1XOESPROC) (GLenum target, GLfixed u1, GLfixed u2, GLint stride, GLint order, GLfixed points);
+typedef void (APIENTRYP PFNGLMAP2XOESPROC) (GLenum target, GLfixed u1, GLfixed u2, GLint ustride, GLint uorder, GLfixed v1, GLfixed v2, GLint vstride, GLint vorder, GLfixed points);
+typedef void (APIENTRYP PFNGLMAPGRID1XOESPROC) (GLint n, GLfixed u1, GLfixed u2);
+typedef void (APIENTRYP PFNGLMAPGRID2XOESPROC) (GLint n, GLfixed u1, GLfixed u2, GLfixed v1, GLfixed v2);
+typedef void (APIENTRYP PFNGLMATERIALXOESPROC) (GLenum face, GLenum pname, GLfixed param);
+typedef void (APIENTRYP PFNGLMATERIALXVOESPROC) (GLenum face, GLenum pname, const GLfixed *param);
+typedef void (APIENTRYP PFNGLMULTMATRIXXOESPROC) (const GLfixed *m);
+typedef void (APIENTRYP PFNGLMULTTRANSPOSEMATRIXXOESPROC) (const GLfixed *m);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD1XOESPROC) (GLenum texture, GLfixed s);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD2XOESPROC) (GLenum texture, GLfixed s, GLfixed t);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD3XOESPROC) (GLenum texture, GLfixed s, GLfixed t, GLfixed r);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD4XOESPROC) (GLenum texture, GLfixed s, GLfixed t, GLfixed r, GLfixed q);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD1XVOESPROC) (GLenum texture, const GLfixed *coords);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD2XVOESPROC) (GLenum texture, const GLfixed *coords);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD3XVOESPROC) (GLenum texture, const GLfixed *coords);
+typedef void (APIENTRYP PFNGLMULTITEXCOORD4XVOESPROC) (GLenum texture, const GLfixed *coords);
+typedef void (APIENTRYP PFNGLNORMAL3XOESPROC) (GLfixed nx, GLfixed ny, GLfixed nz);
+typedef void (APIENTRYP PFNGLNORMAL3XVOESPROC) (const GLfixed *coords);
+typedef void (APIENTRYP PFNGLORTHOXOESPROC) (GLfixed l, GLfixed r, GLfixed b, GLfixed t, GLfixed n, GLfixed f);
+typedef void (APIENTRYP PFNGLPASSTHROUGHXOESPROC) (GLfixed token);
+typedef void (APIENTRYP PFNGLPIXELMAPXPROC) (GLenum map, GLint size, const GLfixed *values);
+typedef void (APIENTRYP PFNGLPIXELSTOREXPROC) (GLenum pname, GLfixed param);
+typedef void (APIENTRYP PFNGLPIXELTRANSFERXOESPROC) (GLenum pname, GLfixed param);
+typedef void (APIENTRYP PFNGLPIXELZOOMXOESPROC) (GLfixed xfactor, GLfixed yfactor);
+typedef void (APIENTRYP PFNGLPOINTPARAMETERXVOESPROC) (GLenum pname, const GLfixed *params);
+typedef void (APIENTRYP PFNGLPOINTSIZEXOESPROC) (GLfixed size);
+typedef void (APIENTRYP PFNGLPOLYGONOFFSETXOESPROC) (GLfixed factor, GLfixed units);
+typedef void (APIENTRYP PFNGLPRIORITIZETEXTURESXOESPROC) (GLsizei n, const GLuint *textures, const GLfixed *priorities);
+typedef void (APIENTRYP PFNGLRASTERPOS2XOESPROC) (GLfixed x, GLfixed y);
+typedef void (APIENTRYP PFNGLRASTERPOS3XOESPROC) (GLfixed x, GLfixed y, GLfixed z);
+typedef void (APIENTRYP PFNGLRASTERPOS4XOESPROC) (GLfixed x, GLfixed y, GLfixed z, GLfixed w);
+typedef void (APIENTRYP PFNGLRASTERPOS2XVOESPROC) (const GLfixed *coords);
+typedef void (APIENTRYP PFNGLRASTERPOS3XVOESPROC) (const GLfixed *coords);
+typedef void (APIENTRYP PFNGLRASTERPOS4XVOESPROC) (const GLfixed *coords);
+typedef void (APIENTRYP PFNGLRECTXOESPROC) (GLfixed x1, GLfixed y1, GLfixed x2, GLfixed y2);
+typedef void (APIENTRYP PFNGLRECTXVOESPROC) (const GLfixed *v1, const GLfixed *v2);
+typedef void (APIENTRYP PFNGLROTATEXOESPROC) (GLfixed angle, GLfixed x, GLfixed y, GLfixed z);
+typedef void (APIENTRYP PFNGLSAMPLECOVERAGEOESPROC) (GLfixed value, GLboolean invert);
+typedef void (APIENTRYP PFNGLSCALEXOESPROC) (GLfixed x, GLfixed y, GLfixed z);
+typedef void (APIENTRYP PFNGLTEXCOORD1XOESPROC) (GLfixed s);
+typedef void (APIENTRYP PFNGLTEXCOORD2XOESPROC) (GLfixed s, GLfixed t);
+typedef void (APIENTRYP PFNGLTEXCOORD3XOESPROC) (GLfixed s, GLfixed t, GLfixed r);
+typedef void (APIENTRYP PFNGLTEXCOORD4XOESPROC) (GLfixed s, GLfixed t, GLfixed r, GLfixed q);
+typedef void (APIENTRYP PFNGLTEXCOORD1XVOESPROC) (const GLfixed *coords);
+typedef void (APIENTRYP PFNGLTEXCOORD2XVOESPROC) (const GLfixed *coords);
+typedef void (APIENTRYP PFNGLTEXCOORD3XVOESPROC) (const GLfixed *coords);
+typedef void (APIENTRYP PFNGLTEXCOORD4XVOESPROC) (const GLfixed *coords);
+typedef void (APIENTRYP PFNGLTEXENVXOESPROC) (GLenum target, GLenum pname, GLfixed param);
+typedef void (APIENTRYP PFNGLTEXENVXVOESPROC) (GLenum target, GLenum pname, const GLfixed *params);
+typedef void (APIENTRYP PFNGLTEXGENXOESPROC) (GLenum coord, GLenum pname, GLfixed param);
+typedef void (APIENTRYP PFNGLTEXGENXVOESPROC) (GLenum coord, GLenum pname, const GLfixed *params);
+typedef void (APIENTRYP PFNGLTEXPARAMETERXOESPROC) (GLenum target, GLenum pname, GLfixed param);
+typedef void (APIENTRYP PFNGLTEXPARAMETERXVOESPROC) (GLenum target, GLenum pname, const GLfixed *params);
+typedef void (APIENTRYP PFNGLTRANSLATEXOESPROC) (GLfixed x, GLfixed y, GLfixed z);
+typedef void (APIENTRYP PFNGLVERTEX2XOESPROC) (GLfixed x);
+typedef void (APIENTRYP PFNGLVERTEX3XOESPROC) (GLfixed x, GLfixed y);
+typedef void (APIENTRYP PFNGLVERTEX4XOESPROC) (GLfixed x, GLfixed y, GLfixed z);
+typedef void (APIENTRYP PFNGLVERTEX2XVOESPROC) (const GLfixed *coords);
+typedef void (APIENTRYP PFNGLVERTEX3XVOESPROC) (const GLfixed *coords);
+typedef void (APIENTRYP PFNGLVERTEX4XVOESPROC) (const GLfixed *coords);
+#endif
+
+#ifndef GL_OES_single_precision
+#define GL_OES_single_precision 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glDepthRangefOES (GLclampf n, GLclampf f);
+GLAPI void APIENTRY glFrustumfOES (GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f);
+GLAPI void APIENTRY glOrthofOES (GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f);
+GLAPI void APIENTRY glClipPlanefOES (GLenum plane, const GLfloat *equation);
+GLAPI void APIENTRY glClearDepthfOES (GLclampd depth);
+GLAPI void APIENTRY glGetClipPlanefOES (GLenum plane, GLfloat *equation);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLDEPTHRANGEFOESPROC) (GLclampf n, GLclampf f);
+typedef void (APIENTRYP PFNGLFRUSTUMFOESPROC) (GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f);
+typedef void (APIENTRYP PFNGLORTHOFOESPROC) (GLfloat l, GLfloat r, GLfloat b, GLfloat t, GLfloat n, GLfloat f);
+typedef void (APIENTRYP PFNGLCLIPPLANEFOESPROC) (GLenum plane, const GLfloat *equation);
+typedef void (APIENTRYP PFNGLCLEARDEPTHFOESPROC) (GLclampd depth);
+typedef void (APIENTRYP PFNGLGETCLIPPLANEFOESPROC) (GLenum plane, GLfloat *equation);
+#endif
+
+#ifndef GL_OES_compressed_paletted_texture
+#define GL_OES_compressed_paletted_texture 1
+#endif
+
#ifndef GL_OES_read_format
#define GL_OES_read_format 1
#endif
+#ifndef GL_OES_query_matrix
+#define GL_OES_query_matrix 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI GLbitfield APIENTRY glQueryMatrixxOES (const GLfixed *mantissa, const GLint *exponent);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef GLbitfield (APIENTRYP PFNGLQUERYMATRIXXOESPROC) (const GLfixed *mantissa, const GLint *exponent);
+#endif
+
#ifndef GL_EXT_depth_bounds_test
#define GL_EXT_depth_bounds_test 1
#ifdef GL_GLEXT_PROTOTYPES
@@ -10495,13 +11755,13 @@ typedef void (APIENTRYP PFNGLRENDERBUFFERSTORAGEMULTISAMPLECOVERAGENVPROC) (GLen
#ifndef GL_NV_parameter_buffer_object
#define GL_NV_parameter_buffer_object 1
#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glProgramBufferParametersfvNV (GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLfloat *params);
-GLAPI void APIENTRY glProgramBufferParametersIivNV (GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLint *params);
-GLAPI void APIENTRY glProgramBufferParametersIuivNV (GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLuint *params);
+GLAPI void APIENTRY glProgramBufferParametersfvNV (GLenum target, GLuint bindingIndex, GLuint wordIndex, GLsizei count, const GLfloat *params);
+GLAPI void APIENTRY glProgramBufferParametersIivNV (GLenum target, GLuint bindingIndex, GLuint wordIndex, GLsizei count, const GLint *params);
+GLAPI void APIENTRY glProgramBufferParametersIuivNV (GLenum target, GLuint bindingIndex, GLuint wordIndex, GLsizei count, const GLuint *params);
#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRYP PFNGLPROGRAMBUFFERPARAMETERSFVNVPROC) (GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLfloat *params);
-typedef void (APIENTRYP PFNGLPROGRAMBUFFERPARAMETERSIIVNVPROC) (GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLint *params);
-typedef void (APIENTRYP PFNGLPROGRAMBUFFERPARAMETERSIUIVNVPROC) (GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLuint *params);
+typedef void (APIENTRYP PFNGLPROGRAMBUFFERPARAMETERSFVNVPROC) (GLenum target, GLuint bindingIndex, GLuint wordIndex, GLsizei count, const GLfloat *params);
+typedef void (APIENTRYP PFNGLPROGRAMBUFFERPARAMETERSIIVNVPROC) (GLenum target, GLuint bindingIndex, GLuint wordIndex, GLsizei count, const GLint *params);
+typedef void (APIENTRYP PFNGLPROGRAMBUFFERPARAMETERSIUIVNVPROC) (GLenum target, GLuint bindingIndex, GLuint wordIndex, GLsizei count, const GLuint *params);
#endif
#ifndef GL_EXT_draw_buffers2
@@ -11571,7 +12831,7 @@ typedef GLuint (APIENTRYP PFNGLGETDEBUGMESSAGELOGAMDPROC) (GLuint count, GLsizei
#ifdef GL_GLEXT_PROTOTYPES
GLAPI void APIENTRY glVDPAUInitNV (const GLvoid *vdpDevice, const GLvoid *getProcAddress);
GLAPI void APIENTRY glVDPAUFiniNV (void);
-GLAPI GLvdpauSurfaceNV APIENTRY glVDPAURegisterVideoSurfaceNV (GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames);
+GLAPI GLvdpauSurfaceNV APIENTRY glVDPAURegisterVideoSurfaceNV (const GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames);
GLAPI GLvdpauSurfaceNV APIENTRY glVDPAURegisterOutputSurfaceNV (GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames);
GLAPI void APIENTRY glVDPAUIsSurfaceNV (GLvdpauSurfaceNV surface);
GLAPI void APIENTRY glVDPAUUnregisterSurfaceNV (GLvdpauSurfaceNV surface);
@@ -11582,7 +12842,7 @@ GLAPI void APIENTRY glVDPAUUnmapSurfacesNV (GLsizei numSurface, const GLvdpauSur
#endif /* GL_GLEXT_PROTOTYPES */
typedef void (APIENTRYP PFNGLVDPAUINITNVPROC) (const GLvoid *vdpDevice, const GLvoid *getProcAddress);
typedef void (APIENTRYP PFNGLVDPAUFININVPROC) (void);
-typedef GLvdpauSurfaceNV (APIENTRYP PFNGLVDPAUREGISTERVIDEOSURFACENVPROC) (GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames);
+typedef GLvdpauSurfaceNV (APIENTRYP PFNGLVDPAUREGISTERVIDEOSURFACENVPROC) (const GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames);
typedef GLvdpauSurfaceNV (APIENTRYP PFNGLVDPAUREGISTEROUTPUTSURFACENVPROC) (GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames);
typedef void (APIENTRYP PFNGLVDPAUISSURFACENVPROC) (GLvdpauSurfaceNV surface);
typedef void (APIENTRYP PFNGLVDPAUUNREGISTERSURFACENVPROC) (GLvdpauSurfaceNV surface);
@@ -11820,6 +13080,66 @@ typedef GLboolean (APIENTRYP PFNGLISIMAGEHANDLERESIDENTNVPROC) (GLuint64 handle)
#define GL_AMD_query_buffer_object 1
#endif
+#ifndef GL_NV_compute_program5
+#define GL_NV_compute_program5 1
+#endif
+
+#ifndef GL_NV_shader_storage_buffer_object
+#define GL_NV_shader_storage_buffer_object 1
+#endif
+
+#ifndef GL_NV_shader_atomic_counters
+#define GL_NV_shader_atomic_counters 1
+#endif
+
+#ifndef GL_NV_deep_texture3D
+#define GL_NV_deep_texture3D 1
+#endif
+
+#ifndef GL_NVX_conditional_render
+#define GL_NVX_conditional_render 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glBeginConditionalRenderNVX (GLuint id);
+GLAPI void APIENTRY glEndConditionalRenderNVX (void);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLBEGINCONDITIONALRENDERNVXPROC) (GLuint id);
+typedef void (APIENTRYP PFNGLENDCONDITIONALRENDERNVXPROC) (void);
+#endif
+
+#ifndef GL_AMD_sparse_texture
+#define GL_AMD_sparse_texture 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glTexStorageSparseAMD (GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLsizei layers, GLbitfield flags);
+GLAPI void APIENTRY glTextureStorageSparseAMD (GLuint texture, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLsizei layers, GLbitfield flags);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLTEXSTORAGESPARSEAMDPROC) (GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLsizei layers, GLbitfield flags);
+typedef void (APIENTRYP PFNGLTEXTURESTORAGESPARSEAMDPROC) (GLuint texture, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLsizei layers, GLbitfield flags);
+#endif
+
+#ifndef GL_AMD_shader_trinary_minmax
+#define GL_AMD_shader_trinary_minmax 1
+#endif
+
+#ifndef GL_INTEL_map_texture
+#define GL_INTEL_map_texture 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glSyncTextureINTEL (GLuint texture);
+GLAPI void APIENTRY glUnmapTexture2DINTEL (GLuint texture, GLint level);
+GLAPI GLvoid* APIENTRY glMapTexture2DINTEL (GLuint texture, GLint level, GLbitfield access, const GLint *stride, const GLenum *layout);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLSYNCTEXTUREINTELPROC) (GLuint texture);
+typedef void (APIENTRYP PFNGLUNMAPTEXTURE2DINTELPROC) (GLuint texture, GLint level);
+typedef GLvoid* (APIENTRYP PFNGLMAPTEXTURE2DINTELPROC) (GLuint texture, GLint level, GLbitfield access, const GLint *stride, const GLenum *layout);
+#endif
+
+#ifndef GL_NV_draw_texture
+#define GL_NV_draw_texture 1
+#ifdef GL_GLEXT_PROTOTYPES
+GLAPI void APIENTRY glDrawTextureNV (GLuint texture, GLuint sampler, GLfloat x0, GLfloat y0, GLfloat x1, GLfloat y1, GLfloat z, GLfloat s0, GLfloat t0, GLfloat s1, GLfloat t1);
+#endif /* GL_GLEXT_PROTOTYPES */
+typedef void (APIENTRYP PFNGLDRAWTEXTURENVPROC) (GLuint texture, GLuint sampler, GLfloat x0, GLfloat y0, GLfloat x1, GLfloat y1, GLfloat z, GLfloat s0, GLfloat t0, GLfloat s1, GLfloat t1);
+#endif
+
#ifdef __cplusplus
}
diff --git a/src/gui/opengl/qopenglextensions_p.h b/src/gui/opengl/qopenglextensions_p.h
index a4e473c049..265771ce1b 100644
--- a/src/gui/opengl/qopenglextensions_p.h
+++ b/src/gui/opengl/qopenglextensions_p.h
@@ -55,8 +55,6 @@
#include "qopenglfunctions.h"
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -193,6 +191,4 @@ inline void QOpenGLExtensions::glGetBufferSubData(GLenum target, qopengl_GLintpt
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QOPENGL_EXTENSIONS_P_H
diff --git a/src/gui/opengl/qopenglframebufferobject.h b/src/gui/opengl/qopenglframebufferobject.h
index 9dbef318f0..215d3701ca 100644
--- a/src/gui/opengl/qopenglframebufferobject.h
+++ b/src/gui/opengl/qopenglframebufferobject.h
@@ -42,6 +42,8 @@
#ifndef QOPENGLFRAMEBUFFEROBJECT_H
#define QOPENGLFRAMEBUFFEROBJECT_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_OPENGL
#include <QtGui/qopengl.h>
@@ -49,8 +51,6 @@
#include <QtCore/qscopedpointer.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -161,8 +161,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_OPENGL
#endif // QOPENGLFRAMEBUFFEROBJECT_H
diff --git a/src/gui/opengl/qopenglfunctions.cpp b/src/gui/opengl/qopenglfunctions.cpp
index ee5855d866..3737df7497 100644
--- a/src/gui/opengl/qopenglfunctions.cpp
+++ b/src/gui/opengl/qopenglfunctions.cpp
@@ -289,7 +289,7 @@ static int qt_gl_resolve_features()
return features;
#else
int features = 0;
- //QOpenGLFormat::OpenGLVersionFlags versions = QOpenGLFormat::openGLVersionFlags();
+ QSurfaceFormat format = QOpenGLContext::currentContext()->format();
QOpenGLExtensionMatcher extensions;
// Recognize features by extension name.
@@ -327,6 +327,10 @@ static int qt_gl_resolve_features()
QOpenGLFunctions::StencilSeparate |
QOpenGLFunctions::BlendEquationSeparate |
QOpenGLFunctions::NPOTTextures;
+
+ if (format.majorVersion() >= 3)
+ features |= QOpenGLFunctions::Framebuffers;
+
return features;
#endif
}
@@ -349,10 +353,13 @@ static int qt_gl_resolve_extensions()
extensions |= QOpenGLExtensions::BGRATextureFormat;
#else
+ QSurfaceFormat format = QOpenGLContext::currentContext()->format();
extensions |= QOpenGLExtensions::ElementIndexUint | QOpenGLExtensions::MapBuffer;
// Recognize features by extension name.
- if (extensionMatcher.match("GL_ARB_framebuffer_object")) {
+ if (format.majorVersion() >= 3
+ || extensionMatcher.match("GL_ARB_framebuffer_object"))
+ {
extensions |= QOpenGLExtensions::FramebufferMultisample |
QOpenGLExtensions::FramebufferBlit |
QOpenGLExtensions::PackedDepthStencil;
diff --git a/src/gui/opengl/qopenglfunctions.h b/src/gui/opengl/qopenglfunctions.h
index 5f3b63d0a0..1548ad4a24 100644
--- a/src/gui/opengl/qopenglfunctions.h
+++ b/src/gui/opengl/qopenglfunctions.h
@@ -42,6 +42,8 @@
#ifndef QOPENGLFUNCTIONS_H
#define QOPENGLFUNCTIONS_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_OPENGL
#ifdef __GLEW_H__
@@ -71,31 +73,8 @@
#define Q_OPENGL_FUNCTIONS_DEBUG
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
-
-// Types that aren't defined in all system's gl.h files.
-typedef ptrdiff_t qopengl_GLintptr;
-typedef ptrdiff_t qopengl_GLsizeiptr;
-
-
-#if defined(APIENTRY) && !defined(QOPENGLF_APIENTRY)
-# define QOPENGLF_APIENTRY APIENTRY
-#elif defined(GL_APIENTRY) && !defined(QOPENGLF_APIENTRY)
-# define QOPENGLF_APIENTRY GL_APIENTRY
-#endif
-
-# ifndef QOPENGLF_APIENTRYP
-# ifdef QOPENGLF_APIENTRY
-# define QOPENGLF_APIENTRYP QOPENGLF_APIENTRY *
-# else
-# define QOPENGLF_APIENTRY
-# define QOPENGLF_APIENTRYP *
-# endif
-# endif
-
struct QOpenGLFunctionsPrivate;
// Undefine any macros from GLEW, qopenglextensions_p.h, etc that
@@ -1520,8 +1499,6 @@ inline void QOpenGLFunctions::glVertexAttribPointer(GLuint indx, GLint size, GLe
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_OPENGL
#endif
diff --git a/src/gui/opengl/qopenglfunctions_1_0.cpp b/src/gui/opengl/qopenglfunctions_1_0.cpp
new file mode 100644
index 0000000000..84db0f2d65
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_1_0.cpp
@@ -0,0 +1,141 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_1_0.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_1_0
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_1_0 class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_1_0::QOpenGLFunctions_1_0()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_0_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_1_0::~QOpenGLFunctions_1_0()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_1_0::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_1_0::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_1_0::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(1, 0))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_1_0::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(1, 0);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_1_0.h b/src/gui/opengl/qopenglfunctions_1_0.h
new file mode 100644
index 0000000000..189d06bfec
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_1_0.h
@@ -0,0 +1,1930 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_1_0_H
+#define QOPENGLVERSIONFUNCTIONS_1_0_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_1_0 : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_1_0();
+ ~QOpenGLFunctions_1_0();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_1_0::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_0::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_1_0::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_1_0::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_1_0::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_1_0::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_1_0::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_1_0::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_0::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_1_0::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_1_0::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_1_0::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_1_0::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_1_0::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_1_0::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_1_0::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_1_0::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_1_0::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_1_0::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_1_0::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_0::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_1_0::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_1_0::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_1_0::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_0::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_1_0::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_1_0::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_0::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_0::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_0::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_1_0::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_1_0::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_1_0::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_1_0::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_1_0::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_1_0::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_1_0::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_1_0::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_1_0::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_0::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_0::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_1_0::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_0::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_0::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_1_0::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_1_0::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_1_0::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_1_0::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_1_0::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_1_0::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_1_0::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_0::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_0::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_0::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_1_0::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_0::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_1_0::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_0::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_0::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_0::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_1_0::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_1_0::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_1_0::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_1_0::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_1_0::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_1_0::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_1_0::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_1_0::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_1_0::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_1_0::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_1_0::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_1_0::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_1_0::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_1_0::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_1_0::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_1_0::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_1_0::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_1_0::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_1_0::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_1_0::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_1_0::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_1_0::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_1_0::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_1_0::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_1_0::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_1_0::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_1_0::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_0::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_1_0::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_1_0::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_1_0::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_1_0::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_1_0::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_1_0::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_1_0::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_1_0::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_1_0::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_1_0::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_1_0::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_0::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_0::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_1_0::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_1_0::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_0::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_0::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_0::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_0::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_0::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_0::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_0::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_0::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_0::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_0::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_0::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_0::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_0::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_1_0::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_1_0::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_1_0::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_1_0::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_1_0::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_1_0::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_1_0::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_1_0::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_1_0::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_1_0::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_1_0::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_0::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_1_0::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_1_0::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_1_0::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_1_0::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_1_0::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_1_0::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_1_0::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_1_0::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_1_1.cpp b/src/gui/opengl/qopenglfunctions_1_1.cpp
new file mode 100644
index 0000000000..b4860bcec7
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_1_1.cpp
@@ -0,0 +1,167 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_1_1.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_1_1
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_1_1 class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_1_1::QOpenGLFunctions_1_1()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_1_1::~QOpenGLFunctions_1_1()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_1_1::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_1_1::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_1_1::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(1, 1))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_1_1::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(1, 1);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_1_1.h b/src/gui/opengl/qopenglfunctions_1_1.h
new file mode 100644
index 0000000000..fbe714c9ad
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_1_1.h
@@ -0,0 +1,2120 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_1_1_H
+#define QOPENGLVERSIONFUNCTIONS_1_1_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_1_1 : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_1_1();
+ ~QOpenGLFunctions_1_1();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_1_1::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_1::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_1_1::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_1_1::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_1_1::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_1_1::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_1_1::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_1_1::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_1::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_1_1::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_1_1::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_1_1::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_1_1::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_1_1::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_1_1::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_1_1::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_1_1::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_1_1::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_1_1::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_1_1::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_1::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_1_1::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_1_1::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_1_1::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_1::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_1_1::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_1_1::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_1::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_1::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_1::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_1_1::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_1_1::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_1_1::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_1_1::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_1_1::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_1_1::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_1_1::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_1_1::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_1_1::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_1_1::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_1_1::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_1_1::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_1::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_1::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_1::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_1::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_1_1::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_1_1::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_1_1::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_1_1::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_1_1::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_1_1::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_1_1::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_1_1::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_1::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_1::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_1_1::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_1::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_1::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_1_1::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_1_1::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_1_1::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_1_1::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_1_1::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_1_1::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_1_1::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_1::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_1::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_1::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_1_1::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_1::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_1_1::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_1::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_1::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_1::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_1_1::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_1_1::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_1_1::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_1_1::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_1_1::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_1_1::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_1_1::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_1_1::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_1_1::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_1_1::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_1_1::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_1_1::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_1_1::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_1_1::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_1_1::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_1_1::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_1_1::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_1_1::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_1_1::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_1_1::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_1_1::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_1_1::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_1_1::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_1_1::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_1_1::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_1_1::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_1_1::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_1::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_1_1::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_1_1::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_1_1::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_1_1::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_1_1::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_1_1::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_1_1::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_1_1::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_1_1::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_1_1::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_1_1::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_1::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_1::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_1_1::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_1_1::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_1::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_1::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_1::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_1::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_1::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_1::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_1::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_1::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_1::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_1::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_1::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_1::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_1::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_1_1::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_1_1::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_1_1::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_1_1::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_1_1::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_1_1::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_1_1::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_1_1::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_1_1::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_1_1::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_1_1::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_1::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_1_1::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_1_1::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_1_1::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_1_1::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_1_1::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_1_1::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_1_1::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_1_1::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_1_1::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_1_1::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_1_1::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_1_1::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_1_1::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_1::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_1::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_1::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_1::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_1::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_1_1::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_1::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_1_1::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_1::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_1_2.cpp b/src/gui/opengl/qopenglfunctions_1_2.cpp
new file mode 100644
index 0000000000..064980bebe
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_1_2.cpp
@@ -0,0 +1,193 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_1_2.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_1_2
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_1_2 class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_1_2::QOpenGLFunctions_1_2()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_1_2::~QOpenGLFunctions_1_2()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_1_2::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_1_2::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_1_2::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(1, 2))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_1_2::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(1, 2);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_1_2.h b/src/gui/opengl/qopenglfunctions_1_2.h
new file mode 100644
index 0000000000..e646fea703
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_1_2.h
@@ -0,0 +1,2358 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_1_2_H
+#define QOPENGLVERSIONFUNCTIONS_1_2_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_1_2 : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_1_2();
+ ~QOpenGLFunctions_1_2();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_1_2::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_2::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_1_2::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_1_2::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_1_2::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_1_2::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_1_2::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_1_2::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_2::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_1_2::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_1_2::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_1_2::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_1_2::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_1_2::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_1_2::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_1_2::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_1_2::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_1_2::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_1_2::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_1_2::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_2::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_1_2::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_1_2::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_1_2::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_2::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_1_2::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_1_2::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_2::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_2::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_2::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_1_2::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_1_2::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_1_2::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_1_2::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_1_2::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_1_2::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_1_2::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_1_2::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_1_2::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_1_2::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_1_2::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_1_2::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_2::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_2::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_2::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_2::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_1_2::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_1_2::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_1_2::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_1_2::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_1_2::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_2::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_2::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_2::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_1_2::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_1_2::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_1_2::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_1_2::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_1_2::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_1_2::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_2::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_2::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_1_2::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_2::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_2::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_1_2::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_1_2::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_1_2::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_1_2::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_1_2::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_1_2::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_1_2::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_2::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_2::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_2::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_1_2::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_2::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_1_2::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_2::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_2::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_2::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_1_2::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_1_2::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_1_2::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_1_2::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_1_2::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_1_2::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_1_2::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_1_2::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_1_2::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_1_2::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_1_2::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_1_2::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_1_2::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_1_2::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_1_2::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_1_2::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_1_2::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_1_2::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_1_2::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_1_2::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_1_2::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_1_2::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_1_2::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_1_2::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_1_2::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_1_2::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_1_2::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_2::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_1_2::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_1_2::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_1_2::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_1_2::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_1_2::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_1_2::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_1_2::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_1_2::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_1_2::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_1_2::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_1_2::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_2::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_1_2::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_1_2::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_2::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_2::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_2::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_2::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_2::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_2::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_2::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_2::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_2::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_2::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_2::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_2::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_2::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_1_2::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_1_2::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_1_2::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_1_2::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_1_2::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_1_2::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_1_2::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_1_2::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_1_2::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_1_2::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_1_2::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_2::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_1_2::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_1_2::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_1_2::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_1_2::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_1_2::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_1_2::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_1_2::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_1_2::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_1_2::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_1_2::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_1_2::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_1_2::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_1_2::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_2::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_2::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_2::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_2::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_2::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_1_2::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_2::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_1_2::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_2::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_1_2::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_1_2::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_1_2::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_1_2::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_1_2::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_1_2::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_1_2::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_1_2::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_1_2::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_1_2::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_2::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_2::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_1_2::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_1_2::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_2::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_1_2::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_1_2::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_2::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_2::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_1_3.cpp b/src/gui/opengl/qopenglfunctions_1_3.cpp
new file mode 100644
index 0000000000..ace7507e35
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_1_3.cpp
@@ -0,0 +1,219 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_1_3.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_1_3
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_1_3 class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_1_3::QOpenGLFunctions_1_3()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+ , d_1_3_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_1_3::~QOpenGLFunctions_1_3()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+ if (d_1_3_Deprecated && !d_1_3_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Deprecated->context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ delete d_1_3_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_1_3::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_1_3::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_1_3::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(1, 3))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_1_3::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(1, 3);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_1_3.h b/src/gui/opengl/qopenglfunctions_1_3.h
new file mode 100644
index 0000000000..44728a2d18
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_1_3.h
@@ -0,0 +1,2644 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_1_3_H
+#define QOPENGLVERSIONFUNCTIONS_1_3_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_1_3 : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_1_3();
+ ~QOpenGLFunctions_1_3();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+ // OpenGL 1.3 deprecated functions
+ void glMultTransposeMatrixd(const GLdouble *m);
+ void glMultTransposeMatrixf(const GLfloat *m);
+ void glLoadTransposeMatrixd(const GLdouble *m);
+ void glLoadTransposeMatrixf(const GLfloat *m);
+ void glMultiTexCoord4sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4iv(GLenum target, const GLint *v);
+ void glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3iv(GLenum target, const GLint *v);
+ void glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord2s(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2iv(GLenum target, const GLint *v);
+ void glMultiTexCoord2i(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord1s(GLenum target, GLshort s);
+ void glMultiTexCoord1iv(GLenum target, const GLint *v);
+ void glMultiTexCoord1i(GLenum target, GLint s);
+ void glMultiTexCoord1fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1f(GLenum target, GLfloat s);
+ void glMultiTexCoord1dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1d(GLenum target, GLdouble s);
+ void glClientActiveTexture(GLenum texture);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+ QOpenGLFunctions_1_3_DeprecatedBackend* d_1_3_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_1_3::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_3::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_1_3::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_1_3::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_1_3::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_1_3::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_1_3::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_1_3::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_3::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_1_3::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_1_3::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_1_3::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_1_3::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_1_3::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_1_3::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_1_3::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_1_3::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_1_3::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_1_3::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_1_3::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_3::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_1_3::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_1_3::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_1_3::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_3::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_1_3::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_1_3::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_3::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_3::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_3::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_1_3::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_1_3::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_1_3::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_1_3::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_1_3::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_1_3::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_1_3::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_1_3::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_1_3::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_1_3::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_1_3::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_1_3::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_3::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_3::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_3::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_3::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_1_3::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_1_3::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_1_3::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_1_3::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_1_3::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_3::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_3::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_3::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_1_3::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_1_3::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_1_3::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_1_3::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_3::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_3::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_3::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_3::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_3::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_3::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_1_3::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_1_3::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_1_3::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_1_3::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_1_3::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_3::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_3::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_1_3::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_3::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_3::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_1_3::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_1_3::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_1_3::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_1_3::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_1_3::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_1_3::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_1_3::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_3::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_3::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_3::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_1_3::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_3::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_1_3::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_3::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_3::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_3::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_1_3::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_1_3::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_1_3::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_1_3::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_1_3::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_1_3::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_1_3::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_1_3::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_1_3::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_1_3::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_1_3::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_1_3::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_1_3::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_1_3::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_1_3::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_1_3::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_1_3::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_1_3::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_1_3::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_1_3::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_1_3::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_1_3::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_1_3::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_1_3::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_1_3::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_1_3::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_1_3::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_3::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_1_3::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_1_3::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_1_3::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_1_3::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_1_3::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_1_3::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_1_3::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_1_3::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_1_3::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_1_3::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_1_3::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_3::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_1_3::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_1_3::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_3::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_3::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_3::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_3::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_3::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_3::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_3::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_3::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_3::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_3::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_3::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_3::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_3::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_1_3::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_1_3::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_1_3::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_1_3::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_1_3::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_1_3::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_1_3::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_1_3::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_1_3::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_1_3::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_1_3::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_3::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_1_3::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_1_3::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_1_3::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_1_3::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_1_3::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_1_3::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_1_3::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_1_3::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_1_3::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_1_3::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_1_3::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_1_3::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_1_3::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_3::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_3::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_3::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_3::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_3::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_1_3::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_3::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_1_3::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_3::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_1_3::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_1_3::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_1_3::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_1_3::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_1_3::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_1_3::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_1_3::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_1_3::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_1_3::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_1_3::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_3::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_3::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_1_3::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_1_3::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_3::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_1_3::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_1_3::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_3::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_3::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+// OpenGL 1.3 deprecated functions
+inline void QOpenGLFunctions_1_3::glMultTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_3::glMultTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_3::glLoadTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_3::glLoadTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord4sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4sv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_3_Deprecated->MultiTexCoord4s(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord4iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4iv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_3_Deprecated->MultiTexCoord4i(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord4fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4fv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_3_Deprecated->MultiTexCoord4f(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord4dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4dv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_3_Deprecated->MultiTexCoord4d(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord3sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3sv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ d_1_3_Deprecated->MultiTexCoord3s(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord3iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3iv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r)
+{
+ d_1_3_Deprecated->MultiTexCoord3i(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord3fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3fv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_3_Deprecated->MultiTexCoord3f(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord3dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3dv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_3_Deprecated->MultiTexCoord3d(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord2sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2sv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord2s(GLenum target, GLshort s, GLshort t)
+{
+ d_1_3_Deprecated->MultiTexCoord2s(target, s, t);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord2iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2iv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord2i(GLenum target, GLint s, GLint t)
+{
+ d_1_3_Deprecated->MultiTexCoord2i(target, s, t);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord2fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2fv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t)
+{
+ d_1_3_Deprecated->MultiTexCoord2f(target, s, t);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord2dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2dv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t)
+{
+ d_1_3_Deprecated->MultiTexCoord2d(target, s, t);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord1sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1sv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord1s(GLenum target, GLshort s)
+{
+ d_1_3_Deprecated->MultiTexCoord1s(target, s);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord1iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1iv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord1i(GLenum target, GLint s)
+{
+ d_1_3_Deprecated->MultiTexCoord1i(target, s);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord1fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1fv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord1f(GLenum target, GLfloat s)
+{
+ d_1_3_Deprecated->MultiTexCoord1f(target, s);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord1dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1dv(target, v);
+}
+
+inline void QOpenGLFunctions_1_3::glMultiTexCoord1d(GLenum target, GLdouble s)
+{
+ d_1_3_Deprecated->MultiTexCoord1d(target, s);
+}
+
+inline void QOpenGLFunctions_1_3::glClientActiveTexture(GLenum texture)
+{
+ d_1_3_Deprecated->ClientActiveTexture(texture);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_1_4.cpp b/src/gui/opengl/qopenglfunctions_1_4.cpp
new file mode 100644
index 0000000000..a27b81d6d8
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_1_4.cpp
@@ -0,0 +1,245 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_1_4.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_1_4
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_1_4 class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_1_4::QOpenGLFunctions_1_4()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+ , d_1_3_Deprecated(0)
+ , d_1_4_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_1_4::~QOpenGLFunctions_1_4()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+ if (d_1_3_Deprecated && !d_1_3_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Deprecated->context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ delete d_1_3_Deprecated;
+ }
+ if (d_1_4_Deprecated && !d_1_4_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Deprecated->context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ delete d_1_4_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_1_4::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_1_4::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_4_Deprecated = static_cast<QOpenGLFunctions_1_4_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_1_4::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(1, 4))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_1_4::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(1, 4);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_1_4.h b/src/gui/opengl/qopenglfunctions_1_4.h
new file mode 100644
index 0000000000..463927fdaf
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_1_4.h
@@ -0,0 +1,2924 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_1_4_H
+#define QOPENGLVERSIONFUNCTIONS_1_4_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_1_4 : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_1_4();
+ ~QOpenGLFunctions_1_4();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+ // OpenGL 1.3 deprecated functions
+ void glMultTransposeMatrixd(const GLdouble *m);
+ void glMultTransposeMatrixf(const GLfloat *m);
+ void glLoadTransposeMatrixd(const GLdouble *m);
+ void glLoadTransposeMatrixf(const GLfloat *m);
+ void glMultiTexCoord4sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4iv(GLenum target, const GLint *v);
+ void glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3iv(GLenum target, const GLint *v);
+ void glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord2s(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2iv(GLenum target, const GLint *v);
+ void glMultiTexCoord2i(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord1s(GLenum target, GLshort s);
+ void glMultiTexCoord1iv(GLenum target, const GLint *v);
+ void glMultiTexCoord1i(GLenum target, GLint s);
+ void glMultiTexCoord1fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1f(GLenum target, GLfloat s);
+ void glMultiTexCoord1dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1d(GLenum target, GLdouble s);
+ void glClientActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 deprecated functions
+ void glWindowPos3sv(const GLshort *v);
+ void glWindowPos3s(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3iv(const GLint *v);
+ void glWindowPos3i(GLint x, GLint y, GLint z);
+ void glWindowPos3fv(const GLfloat *v);
+ void glWindowPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dv(const GLdouble *v);
+ void glWindowPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2sv(const GLshort *v);
+ void glWindowPos2s(GLshort x, GLshort y);
+ void glWindowPos2iv(const GLint *v);
+ void glWindowPos2i(GLint x, GLint y);
+ void glWindowPos2fv(const GLfloat *v);
+ void glWindowPos2f(GLfloat x, GLfloat y);
+ void glWindowPos2dv(const GLdouble *v);
+ void glWindowPos2d(GLdouble x, GLdouble y);
+ void glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glSecondaryColor3usv(const GLushort *v);
+ void glSecondaryColor3us(GLushort red, GLushort green, GLushort blue);
+ void glSecondaryColor3uiv(const GLuint *v);
+ void glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glSecondaryColor3ubv(const GLubyte *v);
+ void glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glSecondaryColor3sv(const GLshort *v);
+ void glSecondaryColor3s(GLshort red, GLshort green, GLshort blue);
+ void glSecondaryColor3iv(const GLint *v);
+ void glSecondaryColor3i(GLint red, GLint green, GLint blue);
+ void glSecondaryColor3fv(const GLfloat *v);
+ void glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glSecondaryColor3dv(const GLdouble *v);
+ void glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glSecondaryColor3bv(const GLbyte *v);
+ void glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glFogCoorddv(const GLdouble *coord);
+ void glFogCoordd(GLdouble coord);
+ void glFogCoordfv(const GLfloat *coord);
+ void glFogCoordf(GLfloat coord);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+ QOpenGLFunctions_1_3_DeprecatedBackend* d_1_3_Deprecated;
+ QOpenGLFunctions_1_4_DeprecatedBackend* d_1_4_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_1_4::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_4::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_1_4::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_1_4::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_1_4::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_1_4::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_1_4::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_1_4::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_4::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_1_4::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_1_4::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_1_4::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_1_4::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_1_4::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_1_4::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_1_4::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_1_4::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_1_4::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_1_4::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_1_4::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_4::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_1_4::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_1_4::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_1_4::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_4::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_1_4::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_1_4::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_4::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_4::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_4::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_1_4::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_1_4::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_1_4::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_1_4::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_1_4::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_1_4::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_1_4::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_1_4::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_1_4::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_1_4::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_1_4::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_1_4::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_4::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_4::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_4::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_4::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_1_4::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_1_4::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_1_4::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_1_4::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_1_4::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_4::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_4::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_4::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_1_4::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_1_4::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_1_4::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_1_4::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_4::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_4::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_4::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_4::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_4::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_4::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_1_4::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_1_4::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_1_4::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_1_4::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_1_4::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_1_4::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_1_4::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_4::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_4::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_1_4::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_4::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_4::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_1_4::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_1_4::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_1_4::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_1_4::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_1_4::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_1_4::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_1_4::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_4::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_4::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_4::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_1_4::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_4::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_1_4::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_4::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_4::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_4::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_1_4::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_1_4::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_1_4::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_1_4::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_1_4::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_1_4::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_1_4::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_1_4::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_1_4::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_1_4::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_1_4::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_1_4::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_1_4::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_1_4::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_1_4::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_1_4::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_1_4::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_1_4::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_1_4::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_1_4::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_1_4::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_1_4::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_1_4::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_1_4::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_1_4::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_1_4::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_1_4::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_4::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_1_4::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_1_4::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_1_4::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_1_4::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_1_4::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_1_4::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_1_4::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_1_4::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_1_4::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_1_4::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_1_4::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_4::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_1_4::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_1_4::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_4::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_4::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_4::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_4::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_4::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_4::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_4::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_4::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_4::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_4::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_4::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_4::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_4::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_1_4::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_1_4::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_1_4::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_1_4::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_1_4::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_1_4::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_1_4::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_1_4::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_1_4::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_1_4::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_1_4::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_1_4::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_1_4::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_1_4::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_1_4::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_1_4::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_1_4::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_1_4::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_1_4::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_1_4::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_1_4::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_1_4::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_1_4::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_4::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_4::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_4::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_4::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_4::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_1_4::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_4::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_1_4::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_4::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_1_4::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_1_4::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_1_4::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_1_4::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_1_4::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_1_4::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_1_4::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_1_4::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_1_4::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_1_4::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_4::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_4::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_1_4::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_1_4::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_4::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_1_4::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_1_4::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_4::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_4::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+// OpenGL 1.3 deprecated functions
+inline void QOpenGLFunctions_1_4::glMultTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_4::glMultTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_4::glLoadTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_4::glLoadTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord4sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4sv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_3_Deprecated->MultiTexCoord4s(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord4iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4iv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_3_Deprecated->MultiTexCoord4i(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord4fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4fv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_3_Deprecated->MultiTexCoord4f(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord4dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4dv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_3_Deprecated->MultiTexCoord4d(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord3sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3sv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ d_1_3_Deprecated->MultiTexCoord3s(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord3iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3iv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r)
+{
+ d_1_3_Deprecated->MultiTexCoord3i(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord3fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3fv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_3_Deprecated->MultiTexCoord3f(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord3dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3dv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_3_Deprecated->MultiTexCoord3d(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord2sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2sv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord2s(GLenum target, GLshort s, GLshort t)
+{
+ d_1_3_Deprecated->MultiTexCoord2s(target, s, t);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord2iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2iv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord2i(GLenum target, GLint s, GLint t)
+{
+ d_1_3_Deprecated->MultiTexCoord2i(target, s, t);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord2fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2fv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t)
+{
+ d_1_3_Deprecated->MultiTexCoord2f(target, s, t);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord2dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2dv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t)
+{
+ d_1_3_Deprecated->MultiTexCoord2d(target, s, t);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord1sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1sv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord1s(GLenum target, GLshort s)
+{
+ d_1_3_Deprecated->MultiTexCoord1s(target, s);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord1iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1iv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord1i(GLenum target, GLint s)
+{
+ d_1_3_Deprecated->MultiTexCoord1i(target, s);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord1fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1fv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord1f(GLenum target, GLfloat s)
+{
+ d_1_3_Deprecated->MultiTexCoord1f(target, s);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord1dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1dv(target, v);
+}
+
+inline void QOpenGLFunctions_1_4::glMultiTexCoord1d(GLenum target, GLdouble s)
+{
+ d_1_3_Deprecated->MultiTexCoord1d(target, s);
+}
+
+inline void QOpenGLFunctions_1_4::glClientActiveTexture(GLenum texture)
+{
+ d_1_3_Deprecated->ClientActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 deprecated functions
+inline void QOpenGLFunctions_1_4::glWindowPos3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos3sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_4_Deprecated->WindowPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos3iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos3iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_4_Deprecated->WindowPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos3fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_4_Deprecated->WindowPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos3dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_4_Deprecated->WindowPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos2sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos2sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos2s(GLshort x, GLshort y)
+{
+ d_1_4_Deprecated->WindowPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos2iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos2iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos2i(GLint x, GLint y)
+{
+ d_1_4_Deprecated->WindowPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos2fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos2fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos2f(GLfloat x, GLfloat y)
+{
+ d_1_4_Deprecated->WindowPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos2dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos2dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glWindowPos2d(GLdouble x, GLdouble y)
+{
+ d_1_4_Deprecated->WindowPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->SecondaryColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3usv(const GLushort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3usv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3uiv(const GLuint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3uiv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3ubv(const GLubyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3ubv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3sv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3iv(const GLint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3iv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->SecondaryColor3fv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_4_Deprecated->SecondaryColor3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->SecondaryColor3dv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_4_Deprecated->SecondaryColor3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3bv(const GLbyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3bv(v);
+}
+
+inline void QOpenGLFunctions_1_4::glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_4::glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->FogCoordPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_4::glFogCoorddv(const GLdouble *coord)
+{
+ d_1_4_Deprecated->FogCoorddv(coord);
+}
+
+inline void QOpenGLFunctions_1_4::glFogCoordd(GLdouble coord)
+{
+ d_1_4_Deprecated->FogCoordd(coord);
+}
+
+inline void QOpenGLFunctions_1_4::glFogCoordfv(const GLfloat *coord)
+{
+ d_1_4_Deprecated->FogCoordfv(coord);
+}
+
+inline void QOpenGLFunctions_1_4::glFogCoordf(GLfloat coord)
+{
+ d_1_4_Deprecated->FogCoordf(coord);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_1_5.cpp b/src/gui/opengl/qopenglfunctions_1_5.cpp
new file mode 100644
index 0000000000..ceb004b02c
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_1_5.cpp
@@ -0,0 +1,258 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_1_5.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_1_5
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_1_5 class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_1_5::QOpenGLFunctions_1_5()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+ , d_1_3_Deprecated(0)
+ , d_1_4_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_1_5::~QOpenGLFunctions_1_5()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+ if (d_1_3_Deprecated && !d_1_3_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Deprecated->context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ delete d_1_3_Deprecated;
+ }
+ if (d_1_4_Deprecated && !d_1_4_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Deprecated->context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ delete d_1_4_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_1_5::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_1_5::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_4_Deprecated = static_cast<QOpenGLFunctions_1_4_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_1_5::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(1, 5))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_1_5::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(1, 5);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_1_5.h b/src/gui/opengl/qopenglfunctions_1_5.h
new file mode 100644
index 0000000000..c50dcabb90
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_1_5.h
@@ -0,0 +1,3047 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_1_5_H
+#define QOPENGLVERSIONFUNCTIONS_1_5_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_1_5 : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_1_5();
+ ~QOpenGLFunctions_1_5();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+ // OpenGL 1.3 deprecated functions
+ void glMultTransposeMatrixd(const GLdouble *m);
+ void glMultTransposeMatrixf(const GLfloat *m);
+ void glLoadTransposeMatrixd(const GLdouble *m);
+ void glLoadTransposeMatrixf(const GLfloat *m);
+ void glMultiTexCoord4sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4iv(GLenum target, const GLint *v);
+ void glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3iv(GLenum target, const GLint *v);
+ void glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord2s(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2iv(GLenum target, const GLint *v);
+ void glMultiTexCoord2i(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord1s(GLenum target, GLshort s);
+ void glMultiTexCoord1iv(GLenum target, const GLint *v);
+ void glMultiTexCoord1i(GLenum target, GLint s);
+ void glMultiTexCoord1fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1f(GLenum target, GLfloat s);
+ void glMultiTexCoord1dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1d(GLenum target, GLdouble s);
+ void glClientActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 deprecated functions
+ void glWindowPos3sv(const GLshort *v);
+ void glWindowPos3s(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3iv(const GLint *v);
+ void glWindowPos3i(GLint x, GLint y, GLint z);
+ void glWindowPos3fv(const GLfloat *v);
+ void glWindowPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dv(const GLdouble *v);
+ void glWindowPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2sv(const GLshort *v);
+ void glWindowPos2s(GLshort x, GLshort y);
+ void glWindowPos2iv(const GLint *v);
+ void glWindowPos2i(GLint x, GLint y);
+ void glWindowPos2fv(const GLfloat *v);
+ void glWindowPos2f(GLfloat x, GLfloat y);
+ void glWindowPos2dv(const GLdouble *v);
+ void glWindowPos2d(GLdouble x, GLdouble y);
+ void glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glSecondaryColor3usv(const GLushort *v);
+ void glSecondaryColor3us(GLushort red, GLushort green, GLushort blue);
+ void glSecondaryColor3uiv(const GLuint *v);
+ void glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glSecondaryColor3ubv(const GLubyte *v);
+ void glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glSecondaryColor3sv(const GLshort *v);
+ void glSecondaryColor3s(GLshort red, GLshort green, GLshort blue);
+ void glSecondaryColor3iv(const GLint *v);
+ void glSecondaryColor3i(GLint red, GLint green, GLint blue);
+ void glSecondaryColor3fv(const GLfloat *v);
+ void glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glSecondaryColor3dv(const GLdouble *v);
+ void glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glSecondaryColor3bv(const GLbyte *v);
+ void glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glFogCoorddv(const GLdouble *coord);
+ void glFogCoordd(GLdouble coord);
+ void glFogCoordfv(const GLfloat *coord);
+ void glFogCoordf(GLfloat coord);
+
+ // OpenGL 1.5 deprecated functions
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+ QOpenGLFunctions_1_3_DeprecatedBackend* d_1_3_Deprecated;
+ QOpenGLFunctions_1_4_DeprecatedBackend* d_1_4_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_1_5::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_5::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_1_5::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_1_5::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_1_5::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_1_5::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_1_5::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_1_5::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_5::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_1_5::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_1_5::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_1_5::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_1_5::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_1_5::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_1_5::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_1_5::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_1_5::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_1_5::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_1_5::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_1_5::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_5::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_1_5::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_1_5::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_1_5::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_5::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_1_5::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_1_5::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_5::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_5::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_5::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_1_5::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_1_5::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_1_5::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_1_5::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_1_5::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_1_5::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_1_5::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_1_5::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_1_5::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_1_5::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_1_5::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_1_5::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_5::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_5::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_5::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_5::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_1_5::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_1_5::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_1_5::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_1_5::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_1_5::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_5::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_5::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_5::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_1_5::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_1_5::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_1_5::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_1_5::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_5::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_5::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_5::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_5::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_5::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_1_5::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_1_5::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_1_5::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_1_5::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_1_5::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_1_5::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_1_5::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_1_5::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_1_5::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_1_5::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_1_5::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_1_5::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_1_5::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_1_5::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_1_5::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_1_5::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_1_5::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_1_5::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_1_5::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_1_5::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_1_5::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_1_5::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_1_5::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_5::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_5::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_1_5::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_5::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_5::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_1_5::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_1_5::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_1_5::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_1_5::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_1_5::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_1_5::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_1_5::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_5::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_5::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_1_5::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_1_5::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_1_5::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_1_5::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_5::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_5::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_1_5::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_1_5::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_1_5::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_1_5::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_1_5::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_1_5::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_1_5::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_1_5::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_1_5::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_1_5::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_1_5::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_1_5::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_1_5::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_1_5::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_1_5::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_1_5::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_1_5::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_1_5::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_1_5::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_1_5::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_1_5::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_1_5::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_1_5::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_1_5::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_1_5::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_1_5::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_1_5::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_1_5::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_5::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_1_5::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_1_5::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_1_5::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_1_5::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_1_5::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_1_5::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_1_5::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_1_5::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_1_5::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_1_5::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_1_5::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_1_5::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_1_5::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_1_5::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_5::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_5::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_5::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_5::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_5::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_5::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_1_5::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_5::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_5::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_5::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_5::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_5::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_1_5::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_1_5::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_1_5::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_1_5::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_1_5::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_1_5::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_1_5::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_1_5::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_1_5::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_1_5::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_1_5::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_1_5::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_1_5::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_1_5::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_1_5::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_1_5::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_1_5::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_1_5::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_1_5::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_1_5::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_1_5::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_1_5::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_1_5::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_1_5::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_5::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_5::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_5::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_5::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_5::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_1_5::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_5::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_1_5::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_5::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_1_5::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_1_5::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_1_5::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_1_5::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_1_5::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_1_5::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_1_5::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_1_5::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_1_5::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_1_5::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_1_5::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_5::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_1_5::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_1_5::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_5::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_1_5::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_1_5::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_1_5::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_1_5::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+// OpenGL 1.3 deprecated functions
+inline void QOpenGLFunctions_1_5::glMultTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_5::glMultTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_5::glLoadTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_1_5::glLoadTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord4sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4sv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_3_Deprecated->MultiTexCoord4s(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord4iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4iv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_3_Deprecated->MultiTexCoord4i(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord4fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4fv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_3_Deprecated->MultiTexCoord4f(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord4dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4dv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_3_Deprecated->MultiTexCoord4d(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord3sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3sv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ d_1_3_Deprecated->MultiTexCoord3s(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord3iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3iv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r)
+{
+ d_1_3_Deprecated->MultiTexCoord3i(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord3fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3fv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_3_Deprecated->MultiTexCoord3f(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord3dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3dv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_3_Deprecated->MultiTexCoord3d(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord2sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2sv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord2s(GLenum target, GLshort s, GLshort t)
+{
+ d_1_3_Deprecated->MultiTexCoord2s(target, s, t);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord2iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2iv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord2i(GLenum target, GLint s, GLint t)
+{
+ d_1_3_Deprecated->MultiTexCoord2i(target, s, t);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord2fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2fv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t)
+{
+ d_1_3_Deprecated->MultiTexCoord2f(target, s, t);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord2dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2dv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t)
+{
+ d_1_3_Deprecated->MultiTexCoord2d(target, s, t);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord1sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1sv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord1s(GLenum target, GLshort s)
+{
+ d_1_3_Deprecated->MultiTexCoord1s(target, s);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord1iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1iv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord1i(GLenum target, GLint s)
+{
+ d_1_3_Deprecated->MultiTexCoord1i(target, s);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord1fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1fv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord1f(GLenum target, GLfloat s)
+{
+ d_1_3_Deprecated->MultiTexCoord1f(target, s);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord1dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1dv(target, v);
+}
+
+inline void QOpenGLFunctions_1_5::glMultiTexCoord1d(GLenum target, GLdouble s)
+{
+ d_1_3_Deprecated->MultiTexCoord1d(target, s);
+}
+
+inline void QOpenGLFunctions_1_5::glClientActiveTexture(GLenum texture)
+{
+ d_1_3_Deprecated->ClientActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 deprecated functions
+inline void QOpenGLFunctions_1_5::glWindowPos3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos3sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_4_Deprecated->WindowPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos3iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos3iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_4_Deprecated->WindowPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos3fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_4_Deprecated->WindowPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos3dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_4_Deprecated->WindowPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos2sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos2sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos2s(GLshort x, GLshort y)
+{
+ d_1_4_Deprecated->WindowPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos2iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos2iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos2i(GLint x, GLint y)
+{
+ d_1_4_Deprecated->WindowPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos2fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos2fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos2f(GLfloat x, GLfloat y)
+{
+ d_1_4_Deprecated->WindowPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos2dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos2dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glWindowPos2d(GLdouble x, GLdouble y)
+{
+ d_1_4_Deprecated->WindowPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->SecondaryColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3usv(const GLushort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3usv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3uiv(const GLuint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3uiv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3ubv(const GLubyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3ubv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3sv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3iv(const GLint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3iv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->SecondaryColor3fv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_4_Deprecated->SecondaryColor3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->SecondaryColor3dv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_4_Deprecated->SecondaryColor3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3bv(const GLbyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3bv(v);
+}
+
+inline void QOpenGLFunctions_1_5::glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_1_5::glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->FogCoordPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_1_5::glFogCoorddv(const GLdouble *coord)
+{
+ d_1_4_Deprecated->FogCoorddv(coord);
+}
+
+inline void QOpenGLFunctions_1_5::glFogCoordd(GLdouble coord)
+{
+ d_1_4_Deprecated->FogCoordd(coord);
+}
+
+inline void QOpenGLFunctions_1_5::glFogCoordfv(const GLfloat *coord)
+{
+ d_1_4_Deprecated->FogCoordfv(coord);
+}
+
+inline void QOpenGLFunctions_1_5::glFogCoordf(GLfloat coord)
+{
+ d_1_4_Deprecated->FogCoordf(coord);
+}
+
+
+// OpenGL 1.5 deprecated functions
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_2_0.cpp b/src/gui/opengl/qopenglfunctions_2_0.cpp
new file mode 100644
index 0000000000..15c042177d
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_2_0.cpp
@@ -0,0 +1,284 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_2_0.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_2_0
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_2_0 class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_2_0::QOpenGLFunctions_2_0()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+ , d_1_3_Deprecated(0)
+ , d_1_4_Deprecated(0)
+ , d_2_0_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_2_0::~QOpenGLFunctions_2_0()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+ if (d_1_3_Deprecated && !d_1_3_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Deprecated->context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ delete d_1_3_Deprecated;
+ }
+ if (d_1_4_Deprecated && !d_1_4_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Deprecated->context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ delete d_1_4_Deprecated;
+ }
+ if (d_2_0_Deprecated && !d_2_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Deprecated->context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ delete d_2_0_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_2_0::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_2_0::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_4_Deprecated = static_cast<QOpenGLFunctions_1_4_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_2_0_Deprecated = static_cast<QOpenGLFunctions_2_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_2_0::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(2, 0))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_2_0::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(2, 0);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_2_0.h b/src/gui/opengl/qopenglfunctions_2_0.h
new file mode 100644
index 0000000000..ee610793ad
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_2_0.h
@@ -0,0 +1,3615 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_2_0_H
+#define QOPENGLVERSIONFUNCTIONS_2_0_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_2_0 : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_2_0();
+ ~QOpenGLFunctions_2_0();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+ // OpenGL 1.3 deprecated functions
+ void glMultTransposeMatrixd(const GLdouble *m);
+ void glMultTransposeMatrixf(const GLfloat *m);
+ void glLoadTransposeMatrixd(const GLdouble *m);
+ void glLoadTransposeMatrixf(const GLfloat *m);
+ void glMultiTexCoord4sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4iv(GLenum target, const GLint *v);
+ void glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3iv(GLenum target, const GLint *v);
+ void glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord2s(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2iv(GLenum target, const GLint *v);
+ void glMultiTexCoord2i(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord1s(GLenum target, GLshort s);
+ void glMultiTexCoord1iv(GLenum target, const GLint *v);
+ void glMultiTexCoord1i(GLenum target, GLint s);
+ void glMultiTexCoord1fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1f(GLenum target, GLfloat s);
+ void glMultiTexCoord1dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1d(GLenum target, GLdouble s);
+ void glClientActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 deprecated functions
+ void glWindowPos3sv(const GLshort *v);
+ void glWindowPos3s(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3iv(const GLint *v);
+ void glWindowPos3i(GLint x, GLint y, GLint z);
+ void glWindowPos3fv(const GLfloat *v);
+ void glWindowPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dv(const GLdouble *v);
+ void glWindowPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2sv(const GLshort *v);
+ void glWindowPos2s(GLshort x, GLshort y);
+ void glWindowPos2iv(const GLint *v);
+ void glWindowPos2i(GLint x, GLint y);
+ void glWindowPos2fv(const GLfloat *v);
+ void glWindowPos2f(GLfloat x, GLfloat y);
+ void glWindowPos2dv(const GLdouble *v);
+ void glWindowPos2d(GLdouble x, GLdouble y);
+ void glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glSecondaryColor3usv(const GLushort *v);
+ void glSecondaryColor3us(GLushort red, GLushort green, GLushort blue);
+ void glSecondaryColor3uiv(const GLuint *v);
+ void glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glSecondaryColor3ubv(const GLubyte *v);
+ void glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glSecondaryColor3sv(const GLshort *v);
+ void glSecondaryColor3s(GLshort red, GLshort green, GLshort blue);
+ void glSecondaryColor3iv(const GLint *v);
+ void glSecondaryColor3i(GLint red, GLint green, GLint blue);
+ void glSecondaryColor3fv(const GLfloat *v);
+ void glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glSecondaryColor3dv(const GLdouble *v);
+ void glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glSecondaryColor3bv(const GLbyte *v);
+ void glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glFogCoorddv(const GLdouble *coord);
+ void glFogCoordd(GLdouble coord);
+ void glFogCoordfv(const GLfloat *coord);
+ void glFogCoordf(GLfloat coord);
+
+ // OpenGL 1.5 deprecated functions
+
+ // OpenGL 2.0 deprecated functions
+ void glVertexAttrib4usv(GLuint index, const GLushort *v);
+ void glVertexAttrib4uiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4sv(GLuint index, const GLshort *v);
+ void glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertexAttrib4iv(GLuint index, const GLint *v);
+ void glVertexAttrib4fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexAttrib4dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttrib4bv(GLuint index, const GLbyte *v);
+ void glVertexAttrib4Nusv(GLuint index, const GLushort *v);
+ void glVertexAttrib4Nuiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4Nubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void glVertexAttrib4Nsv(GLuint index, const GLshort *v);
+ void glVertexAttrib4Niv(GLuint index, const GLint *v);
+ void glVertexAttrib4Nbv(GLuint index, const GLbyte *v);
+ void glVertexAttrib3sv(GLuint index, const GLshort *v);
+ void glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z);
+ void glVertexAttrib3fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexAttrib3dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttrib2sv(GLuint index, const GLshort *v);
+ void glVertexAttrib2s(GLuint index, GLshort x, GLshort y);
+ void glVertexAttrib2fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y);
+ void glVertexAttrib2dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttrib1sv(GLuint index, const GLshort *v);
+ void glVertexAttrib1s(GLuint index, GLshort x);
+ void glVertexAttrib1fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib1f(GLuint index, GLfloat x);
+ void glVertexAttrib1dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib1d(GLuint index, GLdouble x);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+ QOpenGLFunctions_1_3_DeprecatedBackend* d_1_3_Deprecated;
+ QOpenGLFunctions_1_4_DeprecatedBackend* d_1_4_Deprecated;
+ QOpenGLFunctions_2_0_DeprecatedBackend* d_2_0_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_2_0::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_2_0::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_2_0::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_2_0::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_2_0::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_2_0::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_2_0::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_2_0::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_0::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_2_0::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_2_0::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_2_0::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_2_0::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_2_0::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_2_0::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_2_0::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_2_0::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_2_0::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_2_0::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_2_0::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_0::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_2_0::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_2_0::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_2_0::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_0::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_2_0::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_2_0::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_0::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_0::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_2_0::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_2_0::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_2_0::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_2_0::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_2_0::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_2_0::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_2_0::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_2_0::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_2_0::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_2_0::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_2_0::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_2_0::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_2_0::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_0::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_0::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_2_0::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_2_0::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_2_0::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_2_0::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_2_0::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_2_0::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_2_0::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_2_0::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_0::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_0::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_2_0::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_2_0::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_2_0::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_2_0::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_2_0::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_2_0::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_2_0::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_2_0::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_2_0::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_2_0::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_2_0::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_2_0::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_2_0::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_2_0::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_2_0::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_2_0::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_2_0::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_2_0::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_2_0::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_2_0::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_2_0::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_2_0::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_2_0::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_2_0::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_2_0::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_2_0::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_2_0::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_2_0::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_2_0::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_0::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_2_0::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_2_0::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_2_0::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_2_0::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_2_0::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_2_0::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_2_0::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_2_0::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_2_0::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_2_0::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_2_0::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_2_0::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_2_0::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_2_0::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_2_0::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_2_0::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_2_0::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_2_0::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_2_0::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_2_0::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_2_0::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_2_0::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_2_0::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_2_0::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_2_0::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_2_0::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_2_0::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_2_0::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_2_0::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_2_0::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_2_0::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_2_0::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_2_0::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_2_0::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_2_0::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_2_0::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_2_0::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_2_0::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_2_0::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_2_0::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_2_0::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_2_0::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_2_0::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_2_0::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_2_0::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_2_0::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_2_0::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_2_0::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_2_0::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_2_0::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_2_0::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_2_0::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_2_0::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_2_0::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_2_0::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_0::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_2_0::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_2_0::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_2_0::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_2_0::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_2_0::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_2_0::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_2_0::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_2_0::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_2_0::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_2_0::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_2_0::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_2_0::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_2_0::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_2_0::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_2_0::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_2_0::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_2_0::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_2_0::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_2_0::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_2_0::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_2_0::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_2_0::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_2_0::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_2_0::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_2_0::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_2_0::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_2_0::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_2_0::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_2_0::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_2_0::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_2_0::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_0::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_2_0::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_2_0::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_2_0::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_2_0::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_2_0::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_2_0::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_2_0::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_2_0::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_2_0::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_2_0::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_2_0::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_2_0::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_2_0::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_2_0::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_2_0::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_2_0::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_2_0::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_2_0::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_2_0::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_2_0::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_2_0::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_2_0::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_2_0::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_2_0::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_2_0::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_2_0::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_2_0::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_2_0::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_2_0::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_2_0::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_2_0::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_2_0::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_2_0::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_2_0::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_2_0::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_2_0::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_2_0::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_2_0::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_2_0::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_2_0::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_2_0::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_2_0::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_2_0::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_2_0::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_2_0::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_2_0::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_2_0::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_2_0::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_0::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_0::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_0::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_0::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_0::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_2_0::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_0::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_2_0::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_0::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_2_0::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_2_0::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_2_0::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_2_0::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_2_0::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_2_0::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_2_0::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_2_0::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_2_0::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_2_0::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_2_0::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_2_0::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_2_0::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_2_0::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_2_0::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_2_0::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_2_0::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_2_0::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_0::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+// OpenGL 1.3 deprecated functions
+inline void QOpenGLFunctions_2_0::glMultTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_2_0::glMultTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_2_0::glLoadTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_2_0::glLoadTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord4sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4sv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_3_Deprecated->MultiTexCoord4s(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord4iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4iv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_3_Deprecated->MultiTexCoord4i(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord4fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4fv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_3_Deprecated->MultiTexCoord4f(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord4dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4dv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_3_Deprecated->MultiTexCoord4d(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord3sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3sv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ d_1_3_Deprecated->MultiTexCoord3s(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord3iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3iv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r)
+{
+ d_1_3_Deprecated->MultiTexCoord3i(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord3fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3fv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_3_Deprecated->MultiTexCoord3f(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord3dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3dv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_3_Deprecated->MultiTexCoord3d(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord2sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2sv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord2s(GLenum target, GLshort s, GLshort t)
+{
+ d_1_3_Deprecated->MultiTexCoord2s(target, s, t);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord2iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2iv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord2i(GLenum target, GLint s, GLint t)
+{
+ d_1_3_Deprecated->MultiTexCoord2i(target, s, t);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord2fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2fv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t)
+{
+ d_1_3_Deprecated->MultiTexCoord2f(target, s, t);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord2dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2dv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t)
+{
+ d_1_3_Deprecated->MultiTexCoord2d(target, s, t);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord1sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1sv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord1s(GLenum target, GLshort s)
+{
+ d_1_3_Deprecated->MultiTexCoord1s(target, s);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord1iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1iv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord1i(GLenum target, GLint s)
+{
+ d_1_3_Deprecated->MultiTexCoord1i(target, s);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord1fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1fv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord1f(GLenum target, GLfloat s)
+{
+ d_1_3_Deprecated->MultiTexCoord1f(target, s);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord1dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1dv(target, v);
+}
+
+inline void QOpenGLFunctions_2_0::glMultiTexCoord1d(GLenum target, GLdouble s)
+{
+ d_1_3_Deprecated->MultiTexCoord1d(target, s);
+}
+
+inline void QOpenGLFunctions_2_0::glClientActiveTexture(GLenum texture)
+{
+ d_1_3_Deprecated->ClientActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 deprecated functions
+inline void QOpenGLFunctions_2_0::glWindowPos3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos3sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_4_Deprecated->WindowPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos3iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos3iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_4_Deprecated->WindowPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos3fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_4_Deprecated->WindowPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos3dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_4_Deprecated->WindowPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos2sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos2sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos2s(GLshort x, GLshort y)
+{
+ d_1_4_Deprecated->WindowPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos2iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos2iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos2i(GLint x, GLint y)
+{
+ d_1_4_Deprecated->WindowPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos2fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos2fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos2f(GLfloat x, GLfloat y)
+{
+ d_1_4_Deprecated->WindowPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos2dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos2dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glWindowPos2d(GLdouble x, GLdouble y)
+{
+ d_1_4_Deprecated->WindowPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->SecondaryColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3usv(const GLushort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3usv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3uiv(const GLuint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3uiv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3ubv(const GLubyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3ubv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3sv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3iv(const GLint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3iv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->SecondaryColor3fv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_4_Deprecated->SecondaryColor3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->SecondaryColor3dv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_4_Deprecated->SecondaryColor3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3bv(const GLbyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3bv(v);
+}
+
+inline void QOpenGLFunctions_2_0::glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_0::glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->FogCoordPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_0::glFogCoorddv(const GLdouble *coord)
+{
+ d_1_4_Deprecated->FogCoorddv(coord);
+}
+
+inline void QOpenGLFunctions_2_0::glFogCoordd(GLdouble coord)
+{
+ d_1_4_Deprecated->FogCoordd(coord);
+}
+
+inline void QOpenGLFunctions_2_0::glFogCoordfv(const GLfloat *coord)
+{
+ d_1_4_Deprecated->FogCoordfv(coord);
+}
+
+inline void QOpenGLFunctions_2_0::glFogCoordf(GLfloat coord)
+{
+ d_1_4_Deprecated->FogCoordf(coord);
+}
+
+
+// OpenGL 1.5 deprecated functions
+
+// OpenGL 2.0 deprecated functions
+inline void QOpenGLFunctions_2_0::glVertexAttrib4usv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4usv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4uiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4ubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4sv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_2_0_Deprecated->VertexAttrib4s(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4iv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4iv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib4fv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_2_0_Deprecated->VertexAttrib4f(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib4dv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_2_0_Deprecated->VertexAttrib4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4bv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4bv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4Nusv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nusv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4Nuiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nuiv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4Nubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nubv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ d_2_0_Deprecated->VertexAttrib4Nub(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4Nsv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nsv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4Niv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Niv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib4Nbv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nbv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib3sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib3sv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ d_2_0_Deprecated->VertexAttrib3s(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib3fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib3fv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_2_0_Deprecated->VertexAttrib3f(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib3dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib3dv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_2_0_Deprecated->VertexAttrib3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib2sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib2sv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib2s(GLuint index, GLshort x, GLshort y)
+{
+ d_2_0_Deprecated->VertexAttrib2s(index, x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib2fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib2fv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y)
+{
+ d_2_0_Deprecated->VertexAttrib2f(index, x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib2dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib2dv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_2_0_Deprecated->VertexAttrib2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib1sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib1sv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib1s(GLuint index, GLshort x)
+{
+ d_2_0_Deprecated->VertexAttrib1s(index, x);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib1fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib1fv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib1f(GLuint index, GLfloat x)
+{
+ d_2_0_Deprecated->VertexAttrib1f(index, x);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib1dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib1dv(index, v);
+}
+
+inline void QOpenGLFunctions_2_0::glVertexAttrib1d(GLuint index, GLdouble x)
+{
+ d_2_0_Deprecated->VertexAttrib1d(index, x);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_2_1.cpp b/src/gui/opengl/qopenglfunctions_2_1.cpp
new file mode 100644
index 0000000000..143ac206ed
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_2_1.cpp
@@ -0,0 +1,297 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_2_1.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_2_1
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_2_1 class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_2_1::QOpenGLFunctions_2_1()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+ , d_1_3_Deprecated(0)
+ , d_1_4_Deprecated(0)
+ , d_2_0_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_2_1::~QOpenGLFunctions_2_1()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+ if (d_1_3_Deprecated && !d_1_3_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Deprecated->context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ delete d_1_3_Deprecated;
+ }
+ if (d_1_4_Deprecated && !d_1_4_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Deprecated->context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ delete d_1_4_Deprecated;
+ }
+ if (d_2_0_Deprecated && !d_2_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Deprecated->context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ delete d_2_0_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_2_1::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_2_1::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_4_Deprecated = static_cast<QOpenGLFunctions_1_4_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_2_0_Deprecated = static_cast<QOpenGLFunctions_2_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_2_1::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(2, 1))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_2_1::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(2, 1);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_2_1.h b/src/gui/opengl/qopenglfunctions_2_1.h
new file mode 100644
index 0000000000..2dc77cd165
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_2_1.h
@@ -0,0 +1,3660 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_2_1_H
+#define QOPENGLVERSIONFUNCTIONS_2_1_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_2_1 : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_2_1();
+ ~QOpenGLFunctions_2_1();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+ // OpenGL 1.3 deprecated functions
+ void glMultTransposeMatrixd(const GLdouble *m);
+ void glMultTransposeMatrixf(const GLfloat *m);
+ void glLoadTransposeMatrixd(const GLdouble *m);
+ void glLoadTransposeMatrixf(const GLfloat *m);
+ void glMultiTexCoord4sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4iv(GLenum target, const GLint *v);
+ void glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3iv(GLenum target, const GLint *v);
+ void glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord2s(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2iv(GLenum target, const GLint *v);
+ void glMultiTexCoord2i(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord1s(GLenum target, GLshort s);
+ void glMultiTexCoord1iv(GLenum target, const GLint *v);
+ void glMultiTexCoord1i(GLenum target, GLint s);
+ void glMultiTexCoord1fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1f(GLenum target, GLfloat s);
+ void glMultiTexCoord1dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1d(GLenum target, GLdouble s);
+ void glClientActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 deprecated functions
+ void glWindowPos3sv(const GLshort *v);
+ void glWindowPos3s(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3iv(const GLint *v);
+ void glWindowPos3i(GLint x, GLint y, GLint z);
+ void glWindowPos3fv(const GLfloat *v);
+ void glWindowPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dv(const GLdouble *v);
+ void glWindowPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2sv(const GLshort *v);
+ void glWindowPos2s(GLshort x, GLshort y);
+ void glWindowPos2iv(const GLint *v);
+ void glWindowPos2i(GLint x, GLint y);
+ void glWindowPos2fv(const GLfloat *v);
+ void glWindowPos2f(GLfloat x, GLfloat y);
+ void glWindowPos2dv(const GLdouble *v);
+ void glWindowPos2d(GLdouble x, GLdouble y);
+ void glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glSecondaryColor3usv(const GLushort *v);
+ void glSecondaryColor3us(GLushort red, GLushort green, GLushort blue);
+ void glSecondaryColor3uiv(const GLuint *v);
+ void glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glSecondaryColor3ubv(const GLubyte *v);
+ void glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glSecondaryColor3sv(const GLshort *v);
+ void glSecondaryColor3s(GLshort red, GLshort green, GLshort blue);
+ void glSecondaryColor3iv(const GLint *v);
+ void glSecondaryColor3i(GLint red, GLint green, GLint blue);
+ void glSecondaryColor3fv(const GLfloat *v);
+ void glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glSecondaryColor3dv(const GLdouble *v);
+ void glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glSecondaryColor3bv(const GLbyte *v);
+ void glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glFogCoorddv(const GLdouble *coord);
+ void glFogCoordd(GLdouble coord);
+ void glFogCoordfv(const GLfloat *coord);
+ void glFogCoordf(GLfloat coord);
+
+ // OpenGL 1.5 deprecated functions
+
+ // OpenGL 2.0 deprecated functions
+ void glVertexAttrib4usv(GLuint index, const GLushort *v);
+ void glVertexAttrib4uiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4sv(GLuint index, const GLshort *v);
+ void glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertexAttrib4iv(GLuint index, const GLint *v);
+ void glVertexAttrib4fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexAttrib4dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttrib4bv(GLuint index, const GLbyte *v);
+ void glVertexAttrib4Nusv(GLuint index, const GLushort *v);
+ void glVertexAttrib4Nuiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4Nubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void glVertexAttrib4Nsv(GLuint index, const GLshort *v);
+ void glVertexAttrib4Niv(GLuint index, const GLint *v);
+ void glVertexAttrib4Nbv(GLuint index, const GLbyte *v);
+ void glVertexAttrib3sv(GLuint index, const GLshort *v);
+ void glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z);
+ void glVertexAttrib3fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexAttrib3dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttrib2sv(GLuint index, const GLshort *v);
+ void glVertexAttrib2s(GLuint index, GLshort x, GLshort y);
+ void glVertexAttrib2fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y);
+ void glVertexAttrib2dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttrib1sv(GLuint index, const GLshort *v);
+ void glVertexAttrib1s(GLuint index, GLshort x);
+ void glVertexAttrib1fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib1f(GLuint index, GLfloat x);
+ void glVertexAttrib1dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib1d(GLuint index, GLdouble x);
+
+ // OpenGL 2.1 deprecated functions
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+ QOpenGLFunctions_1_3_DeprecatedBackend* d_1_3_Deprecated;
+ QOpenGLFunctions_1_4_DeprecatedBackend* d_1_4_Deprecated;
+ QOpenGLFunctions_2_0_DeprecatedBackend* d_2_0_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_2_1::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_2_1::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_2_1::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_2_1::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_2_1::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_2_1::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_2_1::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_2_1::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_1::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_2_1::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_2_1::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_2_1::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_2_1::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_2_1::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_2_1::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_2_1::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_2_1::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_2_1::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_2_1::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_2_1::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_1::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_2_1::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_2_1::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_2_1::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_1::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_2_1::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_2_1::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_1::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_1::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_2_1::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_2_1::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_2_1::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_2_1::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_2_1::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_2_1::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_2_1::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_2_1::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_2_1::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_2_1::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_2_1::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_2_1::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_2_1::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_1::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_1::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_2_1::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_2_1::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_2_1::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_2_1::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_2_1::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_2_1::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_2_1::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_2_1::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_1::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_1::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_2_1::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_2_1::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_2_1::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_2_1::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_2_1::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_2_1::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_2_1::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_2_1::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_2_1::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_2_1::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_2_1::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_2_1::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_2_1::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_2_1::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_2_1::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_2_1::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_2_1::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_2_1::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_2_1::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_2_1::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_2_1::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_2_1::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_2_1::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_2_1::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_2_1::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_2_1::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_2_1::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_2_1::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_2_1::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_1::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_2_1::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_2_1::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_2_1::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_2_1::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_2_1::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_2_1::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_2_1::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_2_1::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_2_1::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_2_1::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_2_1::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_2_1::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_2_1::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_2_1::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_2_1::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_2_1::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_2_1::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_2_1::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_2_1::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_2_1::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_2_1::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_2_1::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_2_1::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_2_1::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_2_1::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_2_1::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_2_1::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_2_1::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_2_1::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_2_1::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_2_1::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_2_1::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_2_1::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_2_1::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_2_1::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_2_1::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_2_1::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_2_1::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_2_1::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_2_1::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_2_1::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_2_1::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_2_1::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_2_1::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_2_1::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_2_1::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_2_1::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_2_1::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_2_1::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_2_1::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_2_1::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_2_1::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_2_1::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_2_1::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_2_1::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_2_1::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_2_1::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_2_1::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_2_1::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_2_1::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_2_1::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_2_1::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_2_1::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_2_1::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_2_1::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_2_1::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_2_1::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_2_1::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_2_1::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_2_1::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_2_1::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_2_1::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_2_1::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_2_1::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_2_1::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_2_1::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_2_1::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_2_1::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_2_1::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_2_1::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_2_1::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_2_1::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_2_1::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_2_1::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_2_1::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_2_1::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_2_1::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_1::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_2_1::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_2_1::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_2_1::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_2_1::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_2_1::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_2_1::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_2_1::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_2_1::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_2_1::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_2_1::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_2_1::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_2_1::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_2_1::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_2_1::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_2_1::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_2_1::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_2_1::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_2_1::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_2_1::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_2_1::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_2_1::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_2_1::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_2_1::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_2_1::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_2_1::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_2_1::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_2_1::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_2_1::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_2_1::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_2_1::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_2_1::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_2_1::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_2_1::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_2_1::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_2_1::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_2_1::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_2_1::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_2_1::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_2_1::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_2_1::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_2_1::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_2_1::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_2_1::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_2_1::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_2_1::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_2_1::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_2_1::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_2_1::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_1::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_1::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_1::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_1::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_1::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_2_1::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_1::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_2_1::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_1::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_2_1::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_2_1::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_2_1::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_2_1::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_2_1::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_2_1::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_2_1::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_2_1::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_2_1::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_2_1::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_2_1::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_2_1::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_2_1::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_2_1::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_2_1::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_2_1::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_2_1::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_2_1::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_2_1::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+// OpenGL 1.3 deprecated functions
+inline void QOpenGLFunctions_2_1::glMultTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_2_1::glMultTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_2_1::glLoadTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_2_1::glLoadTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord4sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4sv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_3_Deprecated->MultiTexCoord4s(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord4iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4iv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_3_Deprecated->MultiTexCoord4i(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord4fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4fv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_3_Deprecated->MultiTexCoord4f(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord4dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4dv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_3_Deprecated->MultiTexCoord4d(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord3sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3sv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ d_1_3_Deprecated->MultiTexCoord3s(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord3iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3iv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r)
+{
+ d_1_3_Deprecated->MultiTexCoord3i(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord3fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3fv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_3_Deprecated->MultiTexCoord3f(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord3dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3dv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_3_Deprecated->MultiTexCoord3d(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord2sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2sv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord2s(GLenum target, GLshort s, GLshort t)
+{
+ d_1_3_Deprecated->MultiTexCoord2s(target, s, t);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord2iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2iv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord2i(GLenum target, GLint s, GLint t)
+{
+ d_1_3_Deprecated->MultiTexCoord2i(target, s, t);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord2fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2fv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t)
+{
+ d_1_3_Deprecated->MultiTexCoord2f(target, s, t);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord2dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2dv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t)
+{
+ d_1_3_Deprecated->MultiTexCoord2d(target, s, t);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord1sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1sv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord1s(GLenum target, GLshort s)
+{
+ d_1_3_Deprecated->MultiTexCoord1s(target, s);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord1iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1iv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord1i(GLenum target, GLint s)
+{
+ d_1_3_Deprecated->MultiTexCoord1i(target, s);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord1fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1fv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord1f(GLenum target, GLfloat s)
+{
+ d_1_3_Deprecated->MultiTexCoord1f(target, s);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord1dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1dv(target, v);
+}
+
+inline void QOpenGLFunctions_2_1::glMultiTexCoord1d(GLenum target, GLdouble s)
+{
+ d_1_3_Deprecated->MultiTexCoord1d(target, s);
+}
+
+inline void QOpenGLFunctions_2_1::glClientActiveTexture(GLenum texture)
+{
+ d_1_3_Deprecated->ClientActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 deprecated functions
+inline void QOpenGLFunctions_2_1::glWindowPos3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos3sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_4_Deprecated->WindowPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos3iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos3iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_4_Deprecated->WindowPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos3fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_4_Deprecated->WindowPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos3dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_4_Deprecated->WindowPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos2sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos2sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos2s(GLshort x, GLshort y)
+{
+ d_1_4_Deprecated->WindowPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos2iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos2iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos2i(GLint x, GLint y)
+{
+ d_1_4_Deprecated->WindowPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos2fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos2fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos2f(GLfloat x, GLfloat y)
+{
+ d_1_4_Deprecated->WindowPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos2dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos2dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glWindowPos2d(GLdouble x, GLdouble y)
+{
+ d_1_4_Deprecated->WindowPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->SecondaryColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3usv(const GLushort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3usv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3uiv(const GLuint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3uiv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3ubv(const GLubyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3ubv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3sv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3iv(const GLint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3iv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->SecondaryColor3fv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_4_Deprecated->SecondaryColor3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->SecondaryColor3dv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_4_Deprecated->SecondaryColor3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3bv(const GLbyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3bv(v);
+}
+
+inline void QOpenGLFunctions_2_1::glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_2_1::glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->FogCoordPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_2_1::glFogCoorddv(const GLdouble *coord)
+{
+ d_1_4_Deprecated->FogCoorddv(coord);
+}
+
+inline void QOpenGLFunctions_2_1::glFogCoordd(GLdouble coord)
+{
+ d_1_4_Deprecated->FogCoordd(coord);
+}
+
+inline void QOpenGLFunctions_2_1::glFogCoordfv(const GLfloat *coord)
+{
+ d_1_4_Deprecated->FogCoordfv(coord);
+}
+
+inline void QOpenGLFunctions_2_1::glFogCoordf(GLfloat coord)
+{
+ d_1_4_Deprecated->FogCoordf(coord);
+}
+
+
+// OpenGL 1.5 deprecated functions
+
+// OpenGL 2.0 deprecated functions
+inline void QOpenGLFunctions_2_1::glVertexAttrib4usv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4usv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4uiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4ubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4sv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_2_0_Deprecated->VertexAttrib4s(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4iv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4iv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib4fv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_2_0_Deprecated->VertexAttrib4f(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib4dv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_2_0_Deprecated->VertexAttrib4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4bv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4bv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4Nusv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nusv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4Nuiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nuiv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4Nubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nubv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ d_2_0_Deprecated->VertexAttrib4Nub(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4Nsv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nsv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4Niv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Niv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib4Nbv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nbv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib3sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib3sv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ d_2_0_Deprecated->VertexAttrib3s(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib3fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib3fv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_2_0_Deprecated->VertexAttrib3f(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib3dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib3dv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_2_0_Deprecated->VertexAttrib3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib2sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib2sv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib2s(GLuint index, GLshort x, GLshort y)
+{
+ d_2_0_Deprecated->VertexAttrib2s(index, x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib2fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib2fv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y)
+{
+ d_2_0_Deprecated->VertexAttrib2f(index, x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib2dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib2dv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_2_0_Deprecated->VertexAttrib2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib1sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib1sv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib1s(GLuint index, GLshort x)
+{
+ d_2_0_Deprecated->VertexAttrib1s(index, x);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib1fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib1fv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib1f(GLuint index, GLfloat x)
+{
+ d_2_0_Deprecated->VertexAttrib1f(index, x);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib1dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib1dv(index, v);
+}
+
+inline void QOpenGLFunctions_2_1::glVertexAttrib1d(GLuint index, GLdouble x)
+{
+ d_2_0_Deprecated->VertexAttrib1d(index, x);
+}
+
+
+// OpenGL 2.1 deprecated functions
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_3_0.cpp b/src/gui/opengl/qopenglfunctions_3_0.cpp
new file mode 100644
index 0000000000..e13122e683
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_3_0.cpp
@@ -0,0 +1,323 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_3_0.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_3_0
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_3_0 class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_3_0::QOpenGLFunctions_3_0()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+ , d_1_3_Deprecated(0)
+ , d_1_4_Deprecated(0)
+ , d_2_0_Deprecated(0)
+ , d_3_0_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_3_0::~QOpenGLFunctions_3_0()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+ if (d_1_3_Deprecated && !d_1_3_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Deprecated->context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ delete d_1_3_Deprecated;
+ }
+ if (d_1_4_Deprecated && !d_1_4_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Deprecated->context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ delete d_1_4_Deprecated;
+ }
+ if (d_2_0_Deprecated && !d_2_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Deprecated->context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ delete d_2_0_Deprecated;
+ }
+ if (d_3_0_Deprecated && !d_3_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Deprecated->context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ delete d_3_0_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_3_0::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_3_0::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_4_Deprecated = static_cast<QOpenGLFunctions_1_4_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_2_0_Deprecated = static_cast<QOpenGLFunctions_2_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_3_0_Deprecated = static_cast<QOpenGLFunctions_3_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_3_0::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(3, 0))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_3_0::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(3, 0);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_3_0.h b/src/gui/opengl/qopenglfunctions_3_0.h
new file mode 100644
index 0000000000..d6448a08d6
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_3_0.h
@@ -0,0 +1,4174 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_3_0_H
+#define QOPENGLVERSIONFUNCTIONS_3_0_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_3_0 : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_3_0();
+ ~QOpenGLFunctions_3_0();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+ // OpenGL 1.3 deprecated functions
+ void glMultTransposeMatrixd(const GLdouble *m);
+ void glMultTransposeMatrixf(const GLfloat *m);
+ void glLoadTransposeMatrixd(const GLdouble *m);
+ void glLoadTransposeMatrixf(const GLfloat *m);
+ void glMultiTexCoord4sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4iv(GLenum target, const GLint *v);
+ void glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3iv(GLenum target, const GLint *v);
+ void glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord2s(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2iv(GLenum target, const GLint *v);
+ void glMultiTexCoord2i(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord1s(GLenum target, GLshort s);
+ void glMultiTexCoord1iv(GLenum target, const GLint *v);
+ void glMultiTexCoord1i(GLenum target, GLint s);
+ void glMultiTexCoord1fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1f(GLenum target, GLfloat s);
+ void glMultiTexCoord1dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1d(GLenum target, GLdouble s);
+ void glClientActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 deprecated functions
+ void glWindowPos3sv(const GLshort *v);
+ void glWindowPos3s(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3iv(const GLint *v);
+ void glWindowPos3i(GLint x, GLint y, GLint z);
+ void glWindowPos3fv(const GLfloat *v);
+ void glWindowPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dv(const GLdouble *v);
+ void glWindowPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2sv(const GLshort *v);
+ void glWindowPos2s(GLshort x, GLshort y);
+ void glWindowPos2iv(const GLint *v);
+ void glWindowPos2i(GLint x, GLint y);
+ void glWindowPos2fv(const GLfloat *v);
+ void glWindowPos2f(GLfloat x, GLfloat y);
+ void glWindowPos2dv(const GLdouble *v);
+ void glWindowPos2d(GLdouble x, GLdouble y);
+ void glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glSecondaryColor3usv(const GLushort *v);
+ void glSecondaryColor3us(GLushort red, GLushort green, GLushort blue);
+ void glSecondaryColor3uiv(const GLuint *v);
+ void glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glSecondaryColor3ubv(const GLubyte *v);
+ void glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glSecondaryColor3sv(const GLshort *v);
+ void glSecondaryColor3s(GLshort red, GLshort green, GLshort blue);
+ void glSecondaryColor3iv(const GLint *v);
+ void glSecondaryColor3i(GLint red, GLint green, GLint blue);
+ void glSecondaryColor3fv(const GLfloat *v);
+ void glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glSecondaryColor3dv(const GLdouble *v);
+ void glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glSecondaryColor3bv(const GLbyte *v);
+ void glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glFogCoorddv(const GLdouble *coord);
+ void glFogCoordd(GLdouble coord);
+ void glFogCoordfv(const GLfloat *coord);
+ void glFogCoordf(GLfloat coord);
+
+ // OpenGL 1.5 deprecated functions
+
+ // OpenGL 2.0 deprecated functions
+ void glVertexAttrib4usv(GLuint index, const GLushort *v);
+ void glVertexAttrib4uiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4sv(GLuint index, const GLshort *v);
+ void glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertexAttrib4iv(GLuint index, const GLint *v);
+ void glVertexAttrib4fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexAttrib4dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttrib4bv(GLuint index, const GLbyte *v);
+ void glVertexAttrib4Nusv(GLuint index, const GLushort *v);
+ void glVertexAttrib4Nuiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4Nubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void glVertexAttrib4Nsv(GLuint index, const GLshort *v);
+ void glVertexAttrib4Niv(GLuint index, const GLint *v);
+ void glVertexAttrib4Nbv(GLuint index, const GLbyte *v);
+ void glVertexAttrib3sv(GLuint index, const GLshort *v);
+ void glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z);
+ void glVertexAttrib3fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexAttrib3dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttrib2sv(GLuint index, const GLshort *v);
+ void glVertexAttrib2s(GLuint index, GLshort x, GLshort y);
+ void glVertexAttrib2fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y);
+ void glVertexAttrib2dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttrib1sv(GLuint index, const GLshort *v);
+ void glVertexAttrib1s(GLuint index, GLshort x);
+ void glVertexAttrib1fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib1f(GLuint index, GLfloat x);
+ void glVertexAttrib1dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib1d(GLuint index, GLdouble x);
+
+ // OpenGL 2.1 deprecated functions
+
+ // OpenGL 3.0 deprecated functions
+ void glVertexAttribI4usv(GLuint index, const GLushort *v);
+ void glVertexAttribI4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttribI4sv(GLuint index, const GLshort *v);
+ void glVertexAttribI4bv(GLuint index, const GLbyte *v);
+ void glVertexAttribI4uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI3uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI2uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI1uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI4iv(GLuint index, const GLint *v);
+ void glVertexAttribI3iv(GLuint index, const GLint *v);
+ void glVertexAttribI2iv(GLuint index, const GLint *v);
+ void glVertexAttribI1iv(GLuint index, const GLint *v);
+ void glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z);
+ void glVertexAttribI2ui(GLuint index, GLuint x, GLuint y);
+ void glVertexAttribI1ui(GLuint index, GLuint x);
+ void glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z);
+ void glVertexAttribI2i(GLuint index, GLint x, GLint y);
+ void glVertexAttribI1i(GLuint index, GLint x);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+ QOpenGLFunctions_1_3_DeprecatedBackend* d_1_3_Deprecated;
+ QOpenGLFunctions_1_4_DeprecatedBackend* d_1_4_Deprecated;
+ QOpenGLFunctions_2_0_DeprecatedBackend* d_2_0_Deprecated;
+ QOpenGLFunctions_3_0_DeprecatedBackend* d_3_0_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_3_0::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_0::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_3_0::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_3_0::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_3_0::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_3_0::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_3_0::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_0::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_3_0::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_3_0::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_3_0::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_3_0::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_3_0::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_3_0::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_3_0::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_3_0::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_3_0::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_3_0::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_3_0::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_0::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_3_0::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_3_0::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_3_0::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_0::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_3_0::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_3_0::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_0::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_0::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_0::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_3_0::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_3_0::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_3_0::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_3_0::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_3_0::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_3_0::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_3_0::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_3_0::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_3_0::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_3_0::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_3_0::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_3_0::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_0::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_0::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_0::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_0::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_3_0::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_3_0::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_3_0::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_3_0::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_3_0::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_0::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_0::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_0::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_3_0::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_3_0::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_3_0::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_3_0::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_0::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_0::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_0::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_0::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_0::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_0::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_3_0::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_3_0::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_3_0::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_3_0::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_3_0::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_3_0::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_3_0::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_3_0::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_3_0::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_3_0::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_3_0::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_3_0::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_3_0::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_3_0::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_3_0::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_3_0::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_3_0::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_3_0::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_3_0::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_0::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_3_0::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_3_0::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_3_0::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_3_0::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_3_0::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_3_0::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_3_0::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_3_0::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_3_0::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_0::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_3_0::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_3_0::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_3_0::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_3_0::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_0::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_3_0::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_0::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_0::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_3_0::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_3_0::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_3_0::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_3_0::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_3_0::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_3_0::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_3_0::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_3_0::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_3_0::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_3_0::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_3_0::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_3_0::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_3_0::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_3_0::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_3_0::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_3_0::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_3_0::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_3_0::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_3_0::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_3_0::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_3_0::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_3_0::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_3_0::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_3_0::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_3_0::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_3_0::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_3_0::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_3_0::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_3_0::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_3_0::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_3_0::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_3_0::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_3_0::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_3_0::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_3_0::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_3_0::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_3_0::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_3_0::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_3_0::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_3_0::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_3_0::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_3_0::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_0::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_0::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_0::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_3_0::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_0::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_3_0::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_0::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_3_0::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_3_0::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_0::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_3_0::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_3_0::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_3_0::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_3_0::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_3_0::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_3_0::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_3_0::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_3_0::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_3_0::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_3_0::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_3_0::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_3_0::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_3_0::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_3_0::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_3_0::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_3_0::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_3_0::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_3_0::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_3_0::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_3_0::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_3_0::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_3_0::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_3_0::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_3_0::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_3_0::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_3_0::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_3_0::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_3_0::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_3_0::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_0::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_3_0::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_3_0::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_3_0::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_3_0::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_3_0::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_3_0::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_3_0::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_3_0::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_3_0::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_3_0::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_3_0::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_3_0::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_3_0::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_3_0::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_3_0::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_3_0::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_3_0::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_3_0::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_0::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_0::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_3_0::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_3_0::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_3_0::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_3_0::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_3_0::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_3_0::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_3_0::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_3_0::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_3_0::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_3_0::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_3_0::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_0::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_3_0::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_3_0::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_3_0::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_3_0::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_3_0::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_3_0::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_3_0::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_3_0::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_3_0::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_3_0::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_3_0::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_0::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_3_0::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_3_0::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_3_0::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_3_0::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_3_0::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_3_0::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_3_0::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_3_0::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_3_0::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_0::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_0::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_0::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_0::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_0::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_3_0::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_3_0::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_3_0::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_3_0::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_3_0::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_3_0::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_3_0::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_3_0::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_3_0::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_3_0::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_3_0::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_3_0::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_3_0::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_3_0::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_3_0::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_3_0::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_3_0::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_3_0::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_3_0::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_3_0::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_3_0::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_3_0::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_0::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_0::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_0::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_0::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_0::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_3_0::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_0::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_3_0::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_0::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_3_0::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_3_0::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_3_0::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_3_0::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_3_0::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_3_0::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_3_0::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_3_0::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_3_0::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_3_0::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_0::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_0::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_3_0::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_3_0::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_0::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_3_0::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_3_0::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_0::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_0::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+// OpenGL 1.3 deprecated functions
+inline void QOpenGLFunctions_3_0::glMultTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_3_0::glMultTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_3_0::glLoadTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_3_0::glLoadTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord4sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4sv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_3_Deprecated->MultiTexCoord4s(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord4iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4iv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_3_Deprecated->MultiTexCoord4i(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord4fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4fv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_3_Deprecated->MultiTexCoord4f(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord4dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4dv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_3_Deprecated->MultiTexCoord4d(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord3sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3sv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ d_1_3_Deprecated->MultiTexCoord3s(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord3iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3iv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r)
+{
+ d_1_3_Deprecated->MultiTexCoord3i(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord3fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3fv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_3_Deprecated->MultiTexCoord3f(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord3dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3dv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_3_Deprecated->MultiTexCoord3d(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord2sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2sv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord2s(GLenum target, GLshort s, GLshort t)
+{
+ d_1_3_Deprecated->MultiTexCoord2s(target, s, t);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord2iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2iv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord2i(GLenum target, GLint s, GLint t)
+{
+ d_1_3_Deprecated->MultiTexCoord2i(target, s, t);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord2fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2fv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t)
+{
+ d_1_3_Deprecated->MultiTexCoord2f(target, s, t);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord2dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2dv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t)
+{
+ d_1_3_Deprecated->MultiTexCoord2d(target, s, t);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord1sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1sv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord1s(GLenum target, GLshort s)
+{
+ d_1_3_Deprecated->MultiTexCoord1s(target, s);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord1iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1iv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord1i(GLenum target, GLint s)
+{
+ d_1_3_Deprecated->MultiTexCoord1i(target, s);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord1fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1fv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord1f(GLenum target, GLfloat s)
+{
+ d_1_3_Deprecated->MultiTexCoord1f(target, s);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord1dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1dv(target, v);
+}
+
+inline void QOpenGLFunctions_3_0::glMultiTexCoord1d(GLenum target, GLdouble s)
+{
+ d_1_3_Deprecated->MultiTexCoord1d(target, s);
+}
+
+inline void QOpenGLFunctions_3_0::glClientActiveTexture(GLenum texture)
+{
+ d_1_3_Deprecated->ClientActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 deprecated functions
+inline void QOpenGLFunctions_3_0::glWindowPos3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos3sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_4_Deprecated->WindowPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos3iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos3iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_4_Deprecated->WindowPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos3fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_4_Deprecated->WindowPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos3dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_4_Deprecated->WindowPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos2sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos2sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos2s(GLshort x, GLshort y)
+{
+ d_1_4_Deprecated->WindowPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos2iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos2iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos2i(GLint x, GLint y)
+{
+ d_1_4_Deprecated->WindowPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos2fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos2fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos2f(GLfloat x, GLfloat y)
+{
+ d_1_4_Deprecated->WindowPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos2dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos2dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glWindowPos2d(GLdouble x, GLdouble y)
+{
+ d_1_4_Deprecated->WindowPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->SecondaryColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3usv(const GLushort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3usv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3uiv(const GLuint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3uiv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3ubv(const GLubyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3ubv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3sv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3iv(const GLint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3iv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->SecondaryColor3fv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_4_Deprecated->SecondaryColor3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->SecondaryColor3dv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_4_Deprecated->SecondaryColor3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3bv(const GLbyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3bv(v);
+}
+
+inline void QOpenGLFunctions_3_0::glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_0::glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->FogCoordPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_0::glFogCoorddv(const GLdouble *coord)
+{
+ d_1_4_Deprecated->FogCoorddv(coord);
+}
+
+inline void QOpenGLFunctions_3_0::glFogCoordd(GLdouble coord)
+{
+ d_1_4_Deprecated->FogCoordd(coord);
+}
+
+inline void QOpenGLFunctions_3_0::glFogCoordfv(const GLfloat *coord)
+{
+ d_1_4_Deprecated->FogCoordfv(coord);
+}
+
+inline void QOpenGLFunctions_3_0::glFogCoordf(GLfloat coord)
+{
+ d_1_4_Deprecated->FogCoordf(coord);
+}
+
+
+// OpenGL 1.5 deprecated functions
+
+// OpenGL 2.0 deprecated functions
+inline void QOpenGLFunctions_3_0::glVertexAttrib4usv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4usv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4uiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4ubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_2_0_Deprecated->VertexAttrib4s(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4iv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib4fv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_2_0_Deprecated->VertexAttrib4f(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib4dv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_2_0_Deprecated->VertexAttrib4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4bv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4bv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4Nusv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nusv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4Nuiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nuiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4Nubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nubv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ d_2_0_Deprecated->VertexAttrib4Nub(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4Nsv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nsv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4Niv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Niv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib4Nbv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nbv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib3sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib3sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ d_2_0_Deprecated->VertexAttrib3s(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib3fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib3fv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_2_0_Deprecated->VertexAttrib3f(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib3dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib3dv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_2_0_Deprecated->VertexAttrib3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib2sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib2sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib2s(GLuint index, GLshort x, GLshort y)
+{
+ d_2_0_Deprecated->VertexAttrib2s(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib2fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib2fv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y)
+{
+ d_2_0_Deprecated->VertexAttrib2f(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib2dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib2dv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_2_0_Deprecated->VertexAttrib2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib1sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib1sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib1s(GLuint index, GLshort x)
+{
+ d_2_0_Deprecated->VertexAttrib1s(index, x);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib1fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib1fv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib1f(GLuint index, GLfloat x)
+{
+ d_2_0_Deprecated->VertexAttrib1f(index, x);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib1dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib1dv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttrib1d(GLuint index, GLdouble x)
+{
+ d_2_0_Deprecated->VertexAttrib1d(index, x);
+}
+
+
+// OpenGL 2.1 deprecated functions
+
+// OpenGL 3.0 deprecated functions
+inline void QOpenGLFunctions_3_0::glVertexAttribI4usv(GLuint index, const GLushort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4usv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI4ubv(GLuint index, const GLubyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI4sv(GLuint index, const GLshort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI4bv(GLuint index, const GLbyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4bv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI4uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI3uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI2uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI1uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI4iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI3iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI2iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI1iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ d_3_0_Deprecated->VertexAttribI4ui(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ d_3_0_Deprecated->VertexAttribI3ui(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI2ui(GLuint index, GLuint x, GLuint y)
+{
+ d_3_0_Deprecated->VertexAttribI2ui(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI1ui(GLuint index, GLuint x)
+{
+ d_3_0_Deprecated->VertexAttribI1ui(index, x);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ d_3_0_Deprecated->VertexAttribI4i(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z)
+{
+ d_3_0_Deprecated->VertexAttribI3i(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI2i(GLuint index, GLint x, GLint y)
+{
+ d_3_0_Deprecated->VertexAttribI2i(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_0::glVertexAttribI1i(GLuint index, GLint x)
+{
+ d_3_0_Deprecated->VertexAttribI1i(index, x);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_3_1.cpp b/src/gui/opengl/qopenglfunctions_3_1.cpp
new file mode 100644
index 0000000000..104029177c
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_3_1.cpp
@@ -0,0 +1,242 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_3_1.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_3_1
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_3_1 class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_3_1::QOpenGLFunctions_3_1()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+{
+}
+
+QOpenGLFunctions_3_1::~QOpenGLFunctions_3_1()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+}
+
+bool QOpenGLFunctions_3_1::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_3_1::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_3_1::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(3, 1))
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_3_1::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(3, 1);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_3_1.h b/src/gui/opengl/qopenglfunctions_3_1.h
new file mode 100644
index 0000000000..b483ac21ad
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_3_1.h
@@ -0,0 +1,1598 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_3_1_H
+#define QOPENGLVERSIONFUNCTIONS_3_1_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_3_1 : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_3_1();
+ ~QOpenGLFunctions_3_1();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_3_1::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_1::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_3_1::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_3_1::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_3_1::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_3_1::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_3_1::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_3_1::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_1::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_3_1::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_3_1::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_3_1::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_3_1::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_3_1::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_3_1::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_3_1::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_3_1::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_3_1::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_3_1::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_3_1::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_3_1::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_3_1::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_1::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_3_1::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_3_1::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_3_1::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_1::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_3_1::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_3_1::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_1::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_1::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_1::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_1::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_1::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_3_1::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_3_1::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_3_1::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_3_1::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_3_1::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_3_1::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_3_1::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_3_1::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_3_1::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_3_1::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_3_1::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_3_1::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_1::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_1::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_1::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_1::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_3_1::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_3_1::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_3_1::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_3_1::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_3_1::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_1::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_1::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_1::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_3_1::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_3_1::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_3_1::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_3_1::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_1::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_1::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_1::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_1::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_1::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_1::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_3_1::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_3_1::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_3_1::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_1::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_3_1::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_3_1::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_3_1::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_3_1::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_3_1::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_3_1::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_3_1::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_3_1::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_3_1::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_3_1::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_3_1::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_3_1::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_3_1::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_3_1::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_3_1::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_3_1::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_3_1::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_3_1::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_1::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_3_1::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_3_1::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_3_1::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_3_1::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_3_1::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_3_1::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_3_1::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_3_1::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_3_1::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_1::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_3_1::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_3_1::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_3_1::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_3_1::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_1::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_3_1::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_1::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_1::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_3_1::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_3_1::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_3_1::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_3_1::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_3_1::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_3_1::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_3_1::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_3_1::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_3_1::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_3_1::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_3_1::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_3_1::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_3_1::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_3_1::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_3_1::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_3_1::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_3_1::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_3_1::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_3_1::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_3_1::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_3_1::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_3_1::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_3_1::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_3_1::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_3_1::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_3_1::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_3_1::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_3_1::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_3_1::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_3_1::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_3_1::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_3_1::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_3_1::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_3_1::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_3_1::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_3_1::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_3_1::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_3_1::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_3_1::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_3_1::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_3_1::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_3_1::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_1::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_1::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_1::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_1::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_3_1::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_1::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_3_1::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_1::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_3_1::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_3_1::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_3_1::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_1::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_3_1::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_3_1::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_3_1::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_3_1::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_3_1::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_3_1::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_3_1::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_3_1::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_3_1::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_3_1::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_3_1::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_3_1::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_3_1::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_3_1::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_3_1::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_3_1::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_3_1::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_3_1::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_3_1::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_3_1::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_3_1::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_3_1::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_3_2_compatibility.cpp b/src/gui/opengl/qopenglfunctions_3_2_compatibility.cpp
new file mode 100644
index 0000000000..f808f2e6dd
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_3_2_compatibility.cpp
@@ -0,0 +1,350 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_3_2_compatibility.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_3_2_Compatibility
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_3_2_Compatibility class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_3_2_Compatibility::QOpenGLFunctions_3_2_Compatibility()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+ , d_3_2_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+ , d_1_3_Deprecated(0)
+ , d_1_4_Deprecated(0)
+ , d_2_0_Deprecated(0)
+ , d_3_0_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_3_2_Compatibility::~QOpenGLFunctions_3_2_Compatibility()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+ if (d_3_2_Core && !d_3_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_2_Core->context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ delete d_3_2_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+ if (d_1_3_Deprecated && !d_1_3_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Deprecated->context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ delete d_1_3_Deprecated;
+ }
+ if (d_1_4_Deprecated && !d_1_4_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Deprecated->context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ delete d_1_4_Deprecated;
+ }
+ if (d_2_0_Deprecated && !d_2_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Deprecated->context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ delete d_2_0_Deprecated;
+ }
+ if (d_3_0_Deprecated && !d_3_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Deprecated->context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ delete d_3_0_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_3_2_Compatibility::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_3_2_Compatibility::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus(), d);
+ }
+ d_3_2_Core = static_cast<QOpenGLFunctions_3_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_4_Deprecated = static_cast<QOpenGLFunctions_1_4_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_2_0_Deprecated = static_cast<QOpenGLFunctions_2_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_3_0_Deprecated = static_cast<QOpenGLFunctions_3_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_3_2_Compatibility::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(3, 2))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_3_2_Compatibility::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(3, 2);
+ v.setProfile(QSurfaceFormat::CompatibilityProfile);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_3_2_compatibility.h b/src/gui/opengl/qopenglfunctions_3_2_compatibility.h
new file mode 100644
index 0000000000..599f493104
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_3_2_compatibility.h
@@ -0,0 +1,4378 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_3_2_COMPATIBILITY_H
+#define QOPENGLVERSIONFUNCTIONS_3_2_COMPATIBILITY_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_3_2_Compatibility : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_3_2_Compatibility();
+ ~QOpenGLFunctions_3_2_Compatibility();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+ // OpenGL 3.2 core functions
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+ void glProvokingVertex(GLenum mode);
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params);
+ void glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+ // OpenGL 1.3 deprecated functions
+ void glMultTransposeMatrixd(const GLdouble *m);
+ void glMultTransposeMatrixf(const GLfloat *m);
+ void glLoadTransposeMatrixd(const GLdouble *m);
+ void glLoadTransposeMatrixf(const GLfloat *m);
+ void glMultiTexCoord4sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4iv(GLenum target, const GLint *v);
+ void glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3iv(GLenum target, const GLint *v);
+ void glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord2s(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2iv(GLenum target, const GLint *v);
+ void glMultiTexCoord2i(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord1s(GLenum target, GLshort s);
+ void glMultiTexCoord1iv(GLenum target, const GLint *v);
+ void glMultiTexCoord1i(GLenum target, GLint s);
+ void glMultiTexCoord1fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1f(GLenum target, GLfloat s);
+ void glMultiTexCoord1dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1d(GLenum target, GLdouble s);
+ void glClientActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 deprecated functions
+ void glWindowPos3sv(const GLshort *v);
+ void glWindowPos3s(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3iv(const GLint *v);
+ void glWindowPos3i(GLint x, GLint y, GLint z);
+ void glWindowPos3fv(const GLfloat *v);
+ void glWindowPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dv(const GLdouble *v);
+ void glWindowPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2sv(const GLshort *v);
+ void glWindowPos2s(GLshort x, GLshort y);
+ void glWindowPos2iv(const GLint *v);
+ void glWindowPos2i(GLint x, GLint y);
+ void glWindowPos2fv(const GLfloat *v);
+ void glWindowPos2f(GLfloat x, GLfloat y);
+ void glWindowPos2dv(const GLdouble *v);
+ void glWindowPos2d(GLdouble x, GLdouble y);
+ void glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glSecondaryColor3usv(const GLushort *v);
+ void glSecondaryColor3us(GLushort red, GLushort green, GLushort blue);
+ void glSecondaryColor3uiv(const GLuint *v);
+ void glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glSecondaryColor3ubv(const GLubyte *v);
+ void glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glSecondaryColor3sv(const GLshort *v);
+ void glSecondaryColor3s(GLshort red, GLshort green, GLshort blue);
+ void glSecondaryColor3iv(const GLint *v);
+ void glSecondaryColor3i(GLint red, GLint green, GLint blue);
+ void glSecondaryColor3fv(const GLfloat *v);
+ void glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glSecondaryColor3dv(const GLdouble *v);
+ void glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glSecondaryColor3bv(const GLbyte *v);
+ void glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glFogCoorddv(const GLdouble *coord);
+ void glFogCoordd(GLdouble coord);
+ void glFogCoordfv(const GLfloat *coord);
+ void glFogCoordf(GLfloat coord);
+
+ // OpenGL 1.5 deprecated functions
+
+ // OpenGL 2.0 deprecated functions
+ void glVertexAttrib4usv(GLuint index, const GLushort *v);
+ void glVertexAttrib4uiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4sv(GLuint index, const GLshort *v);
+ void glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertexAttrib4iv(GLuint index, const GLint *v);
+ void glVertexAttrib4fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexAttrib4dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttrib4bv(GLuint index, const GLbyte *v);
+ void glVertexAttrib4Nusv(GLuint index, const GLushort *v);
+ void glVertexAttrib4Nuiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4Nubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void glVertexAttrib4Nsv(GLuint index, const GLshort *v);
+ void glVertexAttrib4Niv(GLuint index, const GLint *v);
+ void glVertexAttrib4Nbv(GLuint index, const GLbyte *v);
+ void glVertexAttrib3sv(GLuint index, const GLshort *v);
+ void glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z);
+ void glVertexAttrib3fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexAttrib3dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttrib2sv(GLuint index, const GLshort *v);
+ void glVertexAttrib2s(GLuint index, GLshort x, GLshort y);
+ void glVertexAttrib2fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y);
+ void glVertexAttrib2dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttrib1sv(GLuint index, const GLshort *v);
+ void glVertexAttrib1s(GLuint index, GLshort x);
+ void glVertexAttrib1fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib1f(GLuint index, GLfloat x);
+ void glVertexAttrib1dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib1d(GLuint index, GLdouble x);
+
+ // OpenGL 2.1 deprecated functions
+
+ // OpenGL 3.0 deprecated functions
+ void glVertexAttribI4usv(GLuint index, const GLushort *v);
+ void glVertexAttribI4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttribI4sv(GLuint index, const GLshort *v);
+ void glVertexAttribI4bv(GLuint index, const GLbyte *v);
+ void glVertexAttribI4uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI3uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI2uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI1uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI4iv(GLuint index, const GLint *v);
+ void glVertexAttribI3iv(GLuint index, const GLint *v);
+ void glVertexAttribI2iv(GLuint index, const GLint *v);
+ void glVertexAttribI1iv(GLuint index, const GLint *v);
+ void glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z);
+ void glVertexAttribI2ui(GLuint index, GLuint x, GLuint y);
+ void glVertexAttribI1ui(GLuint index, GLuint x);
+ void glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z);
+ void glVertexAttribI2i(GLuint index, GLint x, GLint y);
+ void glVertexAttribI1i(GLuint index, GLint x);
+
+ // OpenGL 3.1 deprecated functions
+
+ // OpenGL 3.2 deprecated functions
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+ QOpenGLFunctions_3_2_CoreBackend* d_3_2_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+ QOpenGLFunctions_1_3_DeprecatedBackend* d_1_3_Deprecated;
+ QOpenGLFunctions_1_4_DeprecatedBackend* d_1_4_Deprecated;
+ QOpenGLFunctions_2_0_DeprecatedBackend* d_2_0_Deprecated;
+ QOpenGLFunctions_3_0_DeprecatedBackend* d_3_0_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_3_2_Compatibility::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_3_2_Compatibility::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_3_2_Compatibility::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_3_2_Compatibility::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_3_2_Compatibility::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_3_2_Compatibility::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_3_2_Compatibility::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_3_2_Compatibility::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_3_2_Compatibility::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_3_2_Compatibility::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_3_2_Compatibility::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_3_2_Compatibility::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_3_2_Compatibility::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_3_2_Compatibility::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_3_2_Compatibility::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_3_2_Compatibility::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_3_2_Compatibility::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_3_2_Compatibility::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_3_2_Compatibility::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_3_2_Compatibility::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+// OpenGL 3.2 core functions
+inline void QOpenGLFunctions_3_2_Compatibility::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ d_3_2_Core->SampleMaski(index, mask);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ d_3_2_Core->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ d_3_2_Core->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ d_3_2_Core->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLFunctions_3_2_Compatibility::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ return d_3_2_Core->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDeleteSync(GLsync sync)
+{
+ d_3_2_Core->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glIsSync(GLsync sync)
+{
+ return d_3_2_Core->IsSync(sync);
+}
+
+inline GLsync QOpenGLFunctions_3_2_Compatibility::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ return d_3_2_Core->FenceSync(condition, flags);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glProvokingVertex(GLenum mode)
+{
+ d_3_2_Core->ProvokingVertex(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ d_3_2_Core->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ d_3_2_Core->FramebufferTexture(target, attachment, texture, level);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetBufferParameteri64v(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data)
+{
+ d_3_2_Core->GetInteger64i_v(target, index, data);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_3_2_Compatibility::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_3_2_Compatibility::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_3_2_Compatibility::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_3_2_Compatibility::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Compatibility::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_3_2_Compatibility::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+// OpenGL 1.3 deprecated functions
+inline void QOpenGLFunctions_3_2_Compatibility::glMultTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLoadTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glLoadTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord4sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4sv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_3_Deprecated->MultiTexCoord4s(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord4iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4iv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_3_Deprecated->MultiTexCoord4i(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord4fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4fv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_3_Deprecated->MultiTexCoord4f(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord4dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4dv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_3_Deprecated->MultiTexCoord4d(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord3sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3sv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ d_1_3_Deprecated->MultiTexCoord3s(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord3iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3iv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r)
+{
+ d_1_3_Deprecated->MultiTexCoord3i(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord3fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3fv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_3_Deprecated->MultiTexCoord3f(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord3dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3dv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_3_Deprecated->MultiTexCoord3d(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord2sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2sv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord2s(GLenum target, GLshort s, GLshort t)
+{
+ d_1_3_Deprecated->MultiTexCoord2s(target, s, t);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord2iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2iv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord2i(GLenum target, GLint s, GLint t)
+{
+ d_1_3_Deprecated->MultiTexCoord2i(target, s, t);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord2fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2fv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t)
+{
+ d_1_3_Deprecated->MultiTexCoord2f(target, s, t);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord2dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2dv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t)
+{
+ d_1_3_Deprecated->MultiTexCoord2d(target, s, t);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord1sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1sv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord1s(GLenum target, GLshort s)
+{
+ d_1_3_Deprecated->MultiTexCoord1s(target, s);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord1iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1iv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord1i(GLenum target, GLint s)
+{
+ d_1_3_Deprecated->MultiTexCoord1i(target, s);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord1fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1fv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord1f(GLenum target, GLfloat s)
+{
+ d_1_3_Deprecated->MultiTexCoord1f(target, s);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord1dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1dv(target, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glMultiTexCoord1d(GLenum target, GLdouble s)
+{
+ d_1_3_Deprecated->MultiTexCoord1d(target, s);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glClientActiveTexture(GLenum texture)
+{
+ d_1_3_Deprecated->ClientActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 deprecated functions
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos3sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_4_Deprecated->WindowPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos3iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos3iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_4_Deprecated->WindowPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos3fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_4_Deprecated->WindowPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos3dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_4_Deprecated->WindowPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos2sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos2sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos2s(GLshort x, GLshort y)
+{
+ d_1_4_Deprecated->WindowPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos2iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos2iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos2i(GLint x, GLint y)
+{
+ d_1_4_Deprecated->WindowPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos2fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos2fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos2f(GLfloat x, GLfloat y)
+{
+ d_1_4_Deprecated->WindowPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos2dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos2dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glWindowPos2d(GLdouble x, GLdouble y)
+{
+ d_1_4_Deprecated->WindowPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->SecondaryColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3usv(const GLushort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3usv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3uiv(const GLuint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3uiv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3ubv(const GLubyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3ubv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3sv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3iv(const GLint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3iv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->SecondaryColor3fv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_4_Deprecated->SecondaryColor3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->SecondaryColor3dv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_4_Deprecated->SecondaryColor3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3bv(const GLbyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3bv(v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->FogCoordPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFogCoorddv(const GLdouble *coord)
+{
+ d_1_4_Deprecated->FogCoorddv(coord);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFogCoordd(GLdouble coord)
+{
+ d_1_4_Deprecated->FogCoordd(coord);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFogCoordfv(const GLfloat *coord)
+{
+ d_1_4_Deprecated->FogCoordfv(coord);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glFogCoordf(GLfloat coord)
+{
+ d_1_4_Deprecated->FogCoordf(coord);
+}
+
+
+// OpenGL 1.5 deprecated functions
+
+// OpenGL 2.0 deprecated functions
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4usv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4usv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4uiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4ubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_2_0_Deprecated->VertexAttrib4s(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4iv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib4fv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_2_0_Deprecated->VertexAttrib4f(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib4dv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_2_0_Deprecated->VertexAttrib4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4bv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4bv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4Nusv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nusv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4Nuiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nuiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4Nubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nubv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ d_2_0_Deprecated->VertexAttrib4Nub(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4Nsv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nsv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4Niv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Niv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib4Nbv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nbv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib3sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib3sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ d_2_0_Deprecated->VertexAttrib3s(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib3fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib3fv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_2_0_Deprecated->VertexAttrib3f(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib3dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib3dv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_2_0_Deprecated->VertexAttrib3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib2sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib2sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib2s(GLuint index, GLshort x, GLshort y)
+{
+ d_2_0_Deprecated->VertexAttrib2s(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib2fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib2fv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y)
+{
+ d_2_0_Deprecated->VertexAttrib2f(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib2dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib2dv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_2_0_Deprecated->VertexAttrib2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib1sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib1sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib1s(GLuint index, GLshort x)
+{
+ d_2_0_Deprecated->VertexAttrib1s(index, x);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib1fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib1fv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib1f(GLuint index, GLfloat x)
+{
+ d_2_0_Deprecated->VertexAttrib1f(index, x);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib1dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib1dv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttrib1d(GLuint index, GLdouble x)
+{
+ d_2_0_Deprecated->VertexAttrib1d(index, x);
+}
+
+
+// OpenGL 2.1 deprecated functions
+
+// OpenGL 3.0 deprecated functions
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI4usv(GLuint index, const GLushort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4usv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI4ubv(GLuint index, const GLubyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI4sv(GLuint index, const GLshort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI4bv(GLuint index, const GLbyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4bv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI4uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI3uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI2uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI1uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI4iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI3iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI2iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI1iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ d_3_0_Deprecated->VertexAttribI4ui(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ d_3_0_Deprecated->VertexAttribI3ui(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI2ui(GLuint index, GLuint x, GLuint y)
+{
+ d_3_0_Deprecated->VertexAttribI2ui(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI1ui(GLuint index, GLuint x)
+{
+ d_3_0_Deprecated->VertexAttribI1ui(index, x);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ d_3_0_Deprecated->VertexAttribI4i(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z)
+{
+ d_3_0_Deprecated->VertexAttribI3i(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI2i(GLuint index, GLint x, GLint y)
+{
+ d_3_0_Deprecated->VertexAttribI2i(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_2_Compatibility::glVertexAttribI1i(GLuint index, GLint x)
+{
+ d_3_0_Deprecated->VertexAttribI1i(index, x);
+}
+
+
+// OpenGL 3.1 deprecated functions
+
+// OpenGL 3.2 deprecated functions
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_3_2_core.cpp b/src/gui/opengl/qopenglfunctions_3_2_core.cpp
new file mode 100644
index 0000000000..0e1af4c28b
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_3_2_core.cpp
@@ -0,0 +1,256 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_3_2_core.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_3_2_Core
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_3_2_Core class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_3_2_Core::QOpenGLFunctions_3_2_Core()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+ , d_3_2_Core(0)
+{
+}
+
+QOpenGLFunctions_3_2_Core::~QOpenGLFunctions_3_2_Core()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+ if (d_3_2_Core && !d_3_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_2_Core->context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ delete d_3_2_Core;
+ }
+}
+
+bool QOpenGLFunctions_3_2_Core::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_3_2_Core::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus(), d);
+ }
+ d_3_2_Core = static_cast<QOpenGLFunctions_3_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_3_2_Core::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(3, 2))
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_3_2_Core::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(3, 2);
+ v.setProfile(QSurfaceFormat::CoreProfile);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_3_2_core.h b/src/gui/opengl/qopenglfunctions_3_2_core.h
new file mode 100644
index 0000000000..8445384b60
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_3_2_core.h
@@ -0,0 +1,1717 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_3_2_CORE_H
+#define QOPENGLVERSIONFUNCTIONS_3_2_CORE_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_3_2_Core : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_3_2_Core();
+ ~QOpenGLFunctions_3_2_Core();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+ // OpenGL 3.2 core functions
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+ void glProvokingVertex(GLenum mode);
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params);
+ void glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+ QOpenGLFunctions_3_2_CoreBackend* d_3_2_Core;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_3_2_Core::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Core::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_3_2_Core::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_3_2_Core::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_3_2_Core::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_3_2_Core::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_3_2_Core::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Core::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_3_2_Core::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_3_2_Core::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_3_2_Core::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_3_2_Core::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Core::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_3_2_Core::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Core::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Core::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_3_2_Core::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Core::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Core::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_3_2_Core::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_3_2_Core::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_3_2_Core::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_3_2_Core::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_3_2_Core::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_3_2_Core::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_3_2_Core::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_3_2_Core::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_3_2_Core::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Core::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Core::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_3_2_Core::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_3_2_Core::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_3_2_Core::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Core::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_3_2_Core::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_3_2_Core::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+// OpenGL 3.2 core functions
+inline void QOpenGLFunctions_3_2_Core::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ d_3_2_Core->SampleMaski(index, mask);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ d_3_2_Core->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ d_3_2_Core->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ d_3_2_Core->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLFunctions_3_2_Core::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ return d_3_2_Core->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDeleteSync(GLsync sync)
+{
+ d_3_2_Core->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLFunctions_3_2_Core::glIsSync(GLsync sync)
+{
+ return d_3_2_Core->IsSync(sync);
+}
+
+inline GLsync QOpenGLFunctions_3_2_Core::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ return d_3_2_Core->FenceSync(condition, flags);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glProvokingVertex(GLenum mode)
+{
+ d_3_2_Core->ProvokingVertex(mode);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ d_3_2_Core->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ d_3_2_Core->FramebufferTexture(target, attachment, texture, level);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetBufferParameteri64v(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_2_Core::glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data)
+{
+ d_3_2_Core->GetInteger64i_v(target, index, data);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_3_3_compatibility.cpp b/src/gui/opengl/qopenglfunctions_3_3_compatibility.cpp
new file mode 100644
index 0000000000..aa53b7d03b
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_3_3_compatibility.cpp
@@ -0,0 +1,363 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_3_3_compatibility.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_3_3_Compatibility
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_3_3_Compatibility class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_3_3_Compatibility::QOpenGLFunctions_3_3_Compatibility()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+ , d_3_2_Core(0)
+ , d_3_3_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+ , d_1_3_Deprecated(0)
+ , d_1_4_Deprecated(0)
+ , d_2_0_Deprecated(0)
+ , d_3_0_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_3_3_Compatibility::~QOpenGLFunctions_3_3_Compatibility()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+ if (d_3_2_Core && !d_3_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_2_Core->context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ delete d_3_2_Core;
+ }
+ if (d_3_3_Core && !d_3_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_3_Core->context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ delete d_3_3_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+ if (d_1_3_Deprecated && !d_1_3_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Deprecated->context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ delete d_1_3_Deprecated;
+ }
+ if (d_1_4_Deprecated && !d_1_4_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Deprecated->context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ delete d_1_4_Deprecated;
+ }
+ if (d_2_0_Deprecated && !d_2_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Deprecated->context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ delete d_2_0_Deprecated;
+ }
+ if (d_3_0_Deprecated && !d_3_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Deprecated->context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ delete d_3_0_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_3_3_Compatibility::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_3_3_Compatibility::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus(), d);
+ }
+ d_3_2_Core = static_cast<QOpenGLFunctions_3_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus(), d);
+ }
+ d_3_3_Core = static_cast<QOpenGLFunctions_3_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_4_Deprecated = static_cast<QOpenGLFunctions_1_4_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_2_0_Deprecated = static_cast<QOpenGLFunctions_2_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_3_0_Deprecated = static_cast<QOpenGLFunctions_3_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_3_3_Compatibility::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(3, 3))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_3_3_Compatibility::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(3, 3);
+ v.setProfile(QSurfaceFormat::CompatibilityProfile);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_3_3_compatibility.h b/src/gui/opengl/qopenglfunctions_3_3_compatibility.h
new file mode 100644
index 0000000000..6230ebccec
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_3_3_compatibility.h
@@ -0,0 +1,4735 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_3_3_COMPATIBILITY_H
+#define QOPENGLVERSIONFUNCTIONS_3_3_COMPATIBILITY_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_3_3_Compatibility : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_3_3_Compatibility();
+ ~QOpenGLFunctions_3_3_Compatibility();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+ // OpenGL 3.2 core functions
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+ void glProvokingVertex(GLenum mode);
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params);
+ void glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data);
+
+ // OpenGL 3.3 core functions
+ void glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glSecondaryColorP3uiv(GLenum type, const GLuint *color);
+ void glSecondaryColorP3ui(GLenum type, GLuint color);
+ void glColorP4uiv(GLenum type, const GLuint *color);
+ void glColorP4ui(GLenum type, GLuint color);
+ void glColorP3uiv(GLenum type, const GLuint *color);
+ void glColorP3ui(GLenum type, GLuint color);
+ void glNormalP3uiv(GLenum type, const GLuint *coords);
+ void glNormalP3ui(GLenum type, GLuint coords);
+ void glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords);
+ void glTexCoordP4uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP4ui(GLenum type, GLuint coords);
+ void glTexCoordP3uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP3ui(GLenum type, GLuint coords);
+ void glTexCoordP2uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP2ui(GLenum type, GLuint coords);
+ void glTexCoordP1uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP1ui(GLenum type, GLuint coords);
+ void glVertexP4uiv(GLenum type, const GLuint *value);
+ void glVertexP4ui(GLenum type, GLuint value);
+ void glVertexP3uiv(GLenum type, const GLuint *value);
+ void glVertexP3ui(GLenum type, GLuint value);
+ void glVertexP2uiv(GLenum type, const GLuint *value);
+ void glVertexP2ui(GLenum type, GLuint value);
+ void glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params);
+ void glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params);
+ void glQueryCounter(GLuint id, GLenum target);
+ void glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params);
+ void glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params);
+ void glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params);
+ void glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params);
+ void glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param);
+ void glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param);
+ void glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param);
+ void glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameteri(GLuint sampler, GLenum pname, GLint param);
+ void glBindSampler(GLuint unit, GLuint sampler);
+ GLboolean glIsSampler(GLuint sampler);
+ void glDeleteSamplers(GLsizei count, const GLuint *samplers);
+ void glGenSamplers(GLsizei count, GLuint *samplers);
+ GLint glGetFragDataIndex(GLuint program, const GLchar *name);
+ void glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+ void glVertexAttribDivisor(GLuint index, GLuint divisor);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+ // OpenGL 1.3 deprecated functions
+ void glMultTransposeMatrixd(const GLdouble *m);
+ void glMultTransposeMatrixf(const GLfloat *m);
+ void glLoadTransposeMatrixd(const GLdouble *m);
+ void glLoadTransposeMatrixf(const GLfloat *m);
+ void glMultiTexCoord4sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4iv(GLenum target, const GLint *v);
+ void glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3iv(GLenum target, const GLint *v);
+ void glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord2s(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2iv(GLenum target, const GLint *v);
+ void glMultiTexCoord2i(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord1s(GLenum target, GLshort s);
+ void glMultiTexCoord1iv(GLenum target, const GLint *v);
+ void glMultiTexCoord1i(GLenum target, GLint s);
+ void glMultiTexCoord1fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1f(GLenum target, GLfloat s);
+ void glMultiTexCoord1dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1d(GLenum target, GLdouble s);
+ void glClientActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 deprecated functions
+ void glWindowPos3sv(const GLshort *v);
+ void glWindowPos3s(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3iv(const GLint *v);
+ void glWindowPos3i(GLint x, GLint y, GLint z);
+ void glWindowPos3fv(const GLfloat *v);
+ void glWindowPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dv(const GLdouble *v);
+ void glWindowPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2sv(const GLshort *v);
+ void glWindowPos2s(GLshort x, GLshort y);
+ void glWindowPos2iv(const GLint *v);
+ void glWindowPos2i(GLint x, GLint y);
+ void glWindowPos2fv(const GLfloat *v);
+ void glWindowPos2f(GLfloat x, GLfloat y);
+ void glWindowPos2dv(const GLdouble *v);
+ void glWindowPos2d(GLdouble x, GLdouble y);
+ void glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glSecondaryColor3usv(const GLushort *v);
+ void glSecondaryColor3us(GLushort red, GLushort green, GLushort blue);
+ void glSecondaryColor3uiv(const GLuint *v);
+ void glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glSecondaryColor3ubv(const GLubyte *v);
+ void glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glSecondaryColor3sv(const GLshort *v);
+ void glSecondaryColor3s(GLshort red, GLshort green, GLshort blue);
+ void glSecondaryColor3iv(const GLint *v);
+ void glSecondaryColor3i(GLint red, GLint green, GLint blue);
+ void glSecondaryColor3fv(const GLfloat *v);
+ void glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glSecondaryColor3dv(const GLdouble *v);
+ void glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glSecondaryColor3bv(const GLbyte *v);
+ void glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glFogCoorddv(const GLdouble *coord);
+ void glFogCoordd(GLdouble coord);
+ void glFogCoordfv(const GLfloat *coord);
+ void glFogCoordf(GLfloat coord);
+
+ // OpenGL 1.5 deprecated functions
+
+ // OpenGL 2.0 deprecated functions
+ void glVertexAttrib4usv(GLuint index, const GLushort *v);
+ void glVertexAttrib4uiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4sv(GLuint index, const GLshort *v);
+ void glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertexAttrib4iv(GLuint index, const GLint *v);
+ void glVertexAttrib4fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexAttrib4dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttrib4bv(GLuint index, const GLbyte *v);
+ void glVertexAttrib4Nusv(GLuint index, const GLushort *v);
+ void glVertexAttrib4Nuiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4Nubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void glVertexAttrib4Nsv(GLuint index, const GLshort *v);
+ void glVertexAttrib4Niv(GLuint index, const GLint *v);
+ void glVertexAttrib4Nbv(GLuint index, const GLbyte *v);
+ void glVertexAttrib3sv(GLuint index, const GLshort *v);
+ void glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z);
+ void glVertexAttrib3fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexAttrib3dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttrib2sv(GLuint index, const GLshort *v);
+ void glVertexAttrib2s(GLuint index, GLshort x, GLshort y);
+ void glVertexAttrib2fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y);
+ void glVertexAttrib2dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttrib1sv(GLuint index, const GLshort *v);
+ void glVertexAttrib1s(GLuint index, GLshort x);
+ void glVertexAttrib1fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib1f(GLuint index, GLfloat x);
+ void glVertexAttrib1dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib1d(GLuint index, GLdouble x);
+
+ // OpenGL 2.1 deprecated functions
+
+ // OpenGL 3.0 deprecated functions
+ void glVertexAttribI4usv(GLuint index, const GLushort *v);
+ void glVertexAttribI4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttribI4sv(GLuint index, const GLshort *v);
+ void glVertexAttribI4bv(GLuint index, const GLbyte *v);
+ void glVertexAttribI4uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI3uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI2uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI1uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI4iv(GLuint index, const GLint *v);
+ void glVertexAttribI3iv(GLuint index, const GLint *v);
+ void glVertexAttribI2iv(GLuint index, const GLint *v);
+ void glVertexAttribI1iv(GLuint index, const GLint *v);
+ void glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z);
+ void glVertexAttribI2ui(GLuint index, GLuint x, GLuint y);
+ void glVertexAttribI1ui(GLuint index, GLuint x);
+ void glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z);
+ void glVertexAttribI2i(GLuint index, GLint x, GLint y);
+ void glVertexAttribI1i(GLuint index, GLint x);
+
+ // OpenGL 3.1 deprecated functions
+
+ // OpenGL 3.2 deprecated functions
+
+ // OpenGL 3.3 deprecated functions
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+ QOpenGLFunctions_3_2_CoreBackend* d_3_2_Core;
+ QOpenGLFunctions_3_3_CoreBackend* d_3_3_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+ QOpenGLFunctions_1_3_DeprecatedBackend* d_1_3_Deprecated;
+ QOpenGLFunctions_1_4_DeprecatedBackend* d_1_4_Deprecated;
+ QOpenGLFunctions_2_0_DeprecatedBackend* d_2_0_Deprecated;
+ QOpenGLFunctions_3_0_DeprecatedBackend* d_3_0_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_3_3_Compatibility::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_3_3_Compatibility::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_3_3_Compatibility::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_3_3_Compatibility::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_3_3_Compatibility::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_3_3_Compatibility::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_3_3_Compatibility::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_3_3_Compatibility::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_3_3_Compatibility::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_3_3_Compatibility::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_3_3_Compatibility::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_3_3_Compatibility::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_3_3_Compatibility::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_3_3_Compatibility::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_3_3_Compatibility::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_3_3_Compatibility::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_3_3_Compatibility::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_3_3_Compatibility::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_3_3_Compatibility::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_3_3_Compatibility::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+// OpenGL 3.2 core functions
+inline void QOpenGLFunctions_3_3_Compatibility::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ d_3_2_Core->SampleMaski(index, mask);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ d_3_2_Core->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ d_3_2_Core->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ d_3_2_Core->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLFunctions_3_3_Compatibility::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ return d_3_2_Core->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDeleteSync(GLsync sync)
+{
+ d_3_2_Core->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsSync(GLsync sync)
+{
+ return d_3_2_Core->IsSync(sync);
+}
+
+inline GLsync QOpenGLFunctions_3_3_Compatibility::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ return d_3_2_Core->FenceSync(condition, flags);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glProvokingVertex(GLenum mode)
+{
+ d_3_2_Core->ProvokingVertex(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ d_3_2_Core->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ d_3_2_Core->FramebufferTexture(target, attachment, texture, level);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetBufferParameteri64v(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data)
+{
+ d_3_2_Core->GetInteger64i_v(target, index, data);
+}
+
+
+// OpenGL 3.3 core functions
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP4uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP4ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP3uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP3ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP2uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP2ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP1uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP1ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->SecondaryColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->SecondaryColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColorP4uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP4uiv(type, color);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColorP4ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP4ui(type, color);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormalP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->NormalP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormalP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->NormalP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP4uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP4ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP3uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP3ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP2uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP2ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP1uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP1ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoordP4uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP4uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoordP4ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP4ui(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoordP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoordP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoordP2uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP2uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoordP2ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP2ui(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoordP1uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP1uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoordP1ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP1ui(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexP4uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP4uiv(type, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexP4ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP4ui(type, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexP3uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP3uiv(type, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexP3ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP3ui(type, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexP2uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP2uiv(type, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexP2ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP2ui(type, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params)
+{
+ d_3_3_Core->GetQueryObjectui64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params)
+{
+ d_3_3_Core->GetQueryObjecti64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glQueryCounter(GLuint id, GLenum target)
+{
+ d_3_3_Core->QueryCounter(id, target);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params)
+{
+ d_3_3_Core->GetSamplerParameterIuiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params)
+{
+ d_3_3_Core->GetSamplerParameterfv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameterIiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameteriv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ d_3_3_Core->SamplerParameterIuiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameterIiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param)
+{
+ d_3_3_Core->SamplerParameterfv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param)
+{
+ d_3_3_Core->SamplerParameterf(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameteriv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSamplerParameteri(GLuint sampler, GLenum pname, GLint param)
+{
+ d_3_3_Core->SamplerParameteri(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBindSampler(GLuint unit, GLuint sampler)
+{
+ d_3_3_Core->BindSampler(unit, sampler);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsSampler(GLuint sampler)
+{
+ return d_3_3_Core->IsSampler(sampler);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDeleteSamplers(GLsizei count, const GLuint *samplers)
+{
+ d_3_3_Core->DeleteSamplers(count, samplers);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGenSamplers(GLsizei count, GLuint *samplers)
+{
+ d_3_3_Core->GenSamplers(count, samplers);
+}
+
+inline GLint QOpenGLFunctions_3_3_Compatibility::glGetFragDataIndex(GLuint program, const GLchar *name)
+{
+ return d_3_3_Core->GetFragDataIndex(program, name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name)
+{
+ d_3_3_Core->BindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribDivisor(GLuint index, GLuint divisor)
+{
+ d_3_3_Core->VertexAttribDivisor(index, divisor);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_3_3_Compatibility::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_3_3_Compatibility::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_3_3_Compatibility::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_3_3_Compatibility::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Compatibility::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_3_3_Compatibility::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+// OpenGL 1.3 deprecated functions
+inline void QOpenGLFunctions_3_3_Compatibility::glMultTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLoadTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glLoadTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord4sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4sv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_3_Deprecated->MultiTexCoord4s(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord4iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4iv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_3_Deprecated->MultiTexCoord4i(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord4fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4fv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_3_Deprecated->MultiTexCoord4f(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord4dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4dv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_3_Deprecated->MultiTexCoord4d(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord3sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3sv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ d_1_3_Deprecated->MultiTexCoord3s(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord3iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3iv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r)
+{
+ d_1_3_Deprecated->MultiTexCoord3i(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord3fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3fv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_3_Deprecated->MultiTexCoord3f(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord3dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3dv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_3_Deprecated->MultiTexCoord3d(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord2sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2sv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord2s(GLenum target, GLshort s, GLshort t)
+{
+ d_1_3_Deprecated->MultiTexCoord2s(target, s, t);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord2iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2iv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord2i(GLenum target, GLint s, GLint t)
+{
+ d_1_3_Deprecated->MultiTexCoord2i(target, s, t);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord2fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2fv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t)
+{
+ d_1_3_Deprecated->MultiTexCoord2f(target, s, t);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord2dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2dv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t)
+{
+ d_1_3_Deprecated->MultiTexCoord2d(target, s, t);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord1sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1sv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord1s(GLenum target, GLshort s)
+{
+ d_1_3_Deprecated->MultiTexCoord1s(target, s);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord1iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1iv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord1i(GLenum target, GLint s)
+{
+ d_1_3_Deprecated->MultiTexCoord1i(target, s);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord1fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1fv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord1f(GLenum target, GLfloat s)
+{
+ d_1_3_Deprecated->MultiTexCoord1f(target, s);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord1dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1dv(target, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glMultiTexCoord1d(GLenum target, GLdouble s)
+{
+ d_1_3_Deprecated->MultiTexCoord1d(target, s);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glClientActiveTexture(GLenum texture)
+{
+ d_1_3_Deprecated->ClientActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 deprecated functions
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos3sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_4_Deprecated->WindowPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos3iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos3iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_4_Deprecated->WindowPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos3fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_4_Deprecated->WindowPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos3dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_4_Deprecated->WindowPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos2sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos2sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos2s(GLshort x, GLshort y)
+{
+ d_1_4_Deprecated->WindowPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos2iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos2iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos2i(GLint x, GLint y)
+{
+ d_1_4_Deprecated->WindowPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos2fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos2fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos2f(GLfloat x, GLfloat y)
+{
+ d_1_4_Deprecated->WindowPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos2dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos2dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glWindowPos2d(GLdouble x, GLdouble y)
+{
+ d_1_4_Deprecated->WindowPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->SecondaryColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3usv(const GLushort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3usv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3uiv(const GLuint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3uiv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3ubv(const GLubyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3ubv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3sv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3iv(const GLint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3iv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->SecondaryColor3fv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_4_Deprecated->SecondaryColor3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->SecondaryColor3dv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_4_Deprecated->SecondaryColor3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3bv(const GLbyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3bv(v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->FogCoordPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFogCoorddv(const GLdouble *coord)
+{
+ d_1_4_Deprecated->FogCoorddv(coord);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFogCoordd(GLdouble coord)
+{
+ d_1_4_Deprecated->FogCoordd(coord);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFogCoordfv(const GLfloat *coord)
+{
+ d_1_4_Deprecated->FogCoordfv(coord);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glFogCoordf(GLfloat coord)
+{
+ d_1_4_Deprecated->FogCoordf(coord);
+}
+
+
+// OpenGL 1.5 deprecated functions
+
+// OpenGL 2.0 deprecated functions
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4usv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4usv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4uiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4ubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_2_0_Deprecated->VertexAttrib4s(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4iv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib4fv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_2_0_Deprecated->VertexAttrib4f(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib4dv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_2_0_Deprecated->VertexAttrib4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4bv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4bv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4Nusv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nusv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4Nuiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nuiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4Nubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nubv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ d_2_0_Deprecated->VertexAttrib4Nub(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4Nsv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nsv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4Niv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Niv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib4Nbv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nbv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib3sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib3sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ d_2_0_Deprecated->VertexAttrib3s(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib3fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib3fv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_2_0_Deprecated->VertexAttrib3f(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib3dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib3dv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_2_0_Deprecated->VertexAttrib3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib2sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib2sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib2s(GLuint index, GLshort x, GLshort y)
+{
+ d_2_0_Deprecated->VertexAttrib2s(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib2fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib2fv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y)
+{
+ d_2_0_Deprecated->VertexAttrib2f(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib2dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib2dv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_2_0_Deprecated->VertexAttrib2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib1sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib1sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib1s(GLuint index, GLshort x)
+{
+ d_2_0_Deprecated->VertexAttrib1s(index, x);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib1fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib1fv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib1f(GLuint index, GLfloat x)
+{
+ d_2_0_Deprecated->VertexAttrib1f(index, x);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib1dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib1dv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttrib1d(GLuint index, GLdouble x)
+{
+ d_2_0_Deprecated->VertexAttrib1d(index, x);
+}
+
+
+// OpenGL 2.1 deprecated functions
+
+// OpenGL 3.0 deprecated functions
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI4usv(GLuint index, const GLushort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4usv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI4ubv(GLuint index, const GLubyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI4sv(GLuint index, const GLshort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4sv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI4bv(GLuint index, const GLbyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4bv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI4uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI3uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI2uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI1uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1uiv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI4iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI3iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI2iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI1iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1iv(index, v);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ d_3_0_Deprecated->VertexAttribI4ui(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ d_3_0_Deprecated->VertexAttribI3ui(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI2ui(GLuint index, GLuint x, GLuint y)
+{
+ d_3_0_Deprecated->VertexAttribI2ui(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI1ui(GLuint index, GLuint x)
+{
+ d_3_0_Deprecated->VertexAttribI1ui(index, x);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ d_3_0_Deprecated->VertexAttribI4i(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z)
+{
+ d_3_0_Deprecated->VertexAttribI3i(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI2i(GLuint index, GLint x, GLint y)
+{
+ d_3_0_Deprecated->VertexAttribI2i(index, x, y);
+}
+
+inline void QOpenGLFunctions_3_3_Compatibility::glVertexAttribI1i(GLuint index, GLint x)
+{
+ d_3_0_Deprecated->VertexAttribI1i(index, x);
+}
+
+
+// OpenGL 3.1 deprecated functions
+
+// OpenGL 3.2 deprecated functions
+
+// OpenGL 3.3 deprecated functions
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_3_3_core.cpp b/src/gui/opengl/qopenglfunctions_3_3_core.cpp
new file mode 100644
index 0000000000..d355a466c1
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_3_3_core.cpp
@@ -0,0 +1,269 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_3_3_core.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_3_3_Core
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_3_3_Core class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_3_3_Core::QOpenGLFunctions_3_3_Core()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+ , d_3_2_Core(0)
+ , d_3_3_Core(0)
+{
+}
+
+QOpenGLFunctions_3_3_Core::~QOpenGLFunctions_3_3_Core()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+ if (d_3_2_Core && !d_3_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_2_Core->context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ delete d_3_2_Core;
+ }
+ if (d_3_3_Core && !d_3_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_3_Core->context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ delete d_3_3_Core;
+ }
+}
+
+bool QOpenGLFunctions_3_3_Core::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_3_3_Core::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus(), d);
+ }
+ d_3_2_Core = static_cast<QOpenGLFunctions_3_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus(), d);
+ }
+ d_3_3_Core = static_cast<QOpenGLFunctions_3_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_3_3_Core::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(3, 3))
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_3_3_Core::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(3, 3);
+ v.setProfile(QSurfaceFormat::CoreProfile);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_3_3_core.h b/src/gui/opengl/qopenglfunctions_3_3_core.h
new file mode 100644
index 0000000000..e24c678b9b
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_3_3_core.h
@@ -0,0 +1,2070 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_3_3_CORE_H
+#define QOPENGLVERSIONFUNCTIONS_3_3_CORE_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_3_3_Core : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_3_3_Core();
+ ~QOpenGLFunctions_3_3_Core();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+ // OpenGL 3.2 core functions
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+ void glProvokingVertex(GLenum mode);
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params);
+ void glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data);
+
+ // OpenGL 3.3 core functions
+ void glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glSecondaryColorP3uiv(GLenum type, const GLuint *color);
+ void glSecondaryColorP3ui(GLenum type, GLuint color);
+ void glColorP4uiv(GLenum type, const GLuint *color);
+ void glColorP4ui(GLenum type, GLuint color);
+ void glColorP3uiv(GLenum type, const GLuint *color);
+ void glColorP3ui(GLenum type, GLuint color);
+ void glNormalP3uiv(GLenum type, const GLuint *coords);
+ void glNormalP3ui(GLenum type, GLuint coords);
+ void glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords);
+ void glTexCoordP4uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP4ui(GLenum type, GLuint coords);
+ void glTexCoordP3uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP3ui(GLenum type, GLuint coords);
+ void glTexCoordP2uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP2ui(GLenum type, GLuint coords);
+ void glTexCoordP1uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP1ui(GLenum type, GLuint coords);
+ void glVertexP4uiv(GLenum type, const GLuint *value);
+ void glVertexP4ui(GLenum type, GLuint value);
+ void glVertexP3uiv(GLenum type, const GLuint *value);
+ void glVertexP3ui(GLenum type, GLuint value);
+ void glVertexP2uiv(GLenum type, const GLuint *value);
+ void glVertexP2ui(GLenum type, GLuint value);
+ void glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params);
+ void glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params);
+ void glQueryCounter(GLuint id, GLenum target);
+ void glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params);
+ void glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params);
+ void glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params);
+ void glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params);
+ void glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param);
+ void glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param);
+ void glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param);
+ void glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameteri(GLuint sampler, GLenum pname, GLint param);
+ void glBindSampler(GLuint unit, GLuint sampler);
+ GLboolean glIsSampler(GLuint sampler);
+ void glDeleteSamplers(GLsizei count, const GLuint *samplers);
+ void glGenSamplers(GLsizei count, GLuint *samplers);
+ GLint glGetFragDataIndex(GLuint program, const GLchar *name);
+ void glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+ void glVertexAttribDivisor(GLuint index, GLuint divisor);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+ QOpenGLFunctions_3_2_CoreBackend* d_3_2_Core;
+ QOpenGLFunctions_3_3_CoreBackend* d_3_3_Core;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_3_3_Core::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Core::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_3_3_Core::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_3_3_Core::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_3_3_Core::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_3_3_Core::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_3_3_Core::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Core::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_3_3_Core::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_3_3_Core::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_3_3_Core::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_3_3_Core::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Core::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_3_3_Core::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Core::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Core::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_3_3_Core::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Core::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Core::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_3_3_Core::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_3_3_Core::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_3_3_Core::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_3_3_Core::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_3_3_Core::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_3_3_Core::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_3_3_Core::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_3_3_Core::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_3_3_Core::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Core::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Core::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_3_3_Core::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_3_3_Core::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Core::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_3_3_Core::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_3_3_Core::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+// OpenGL 3.2 core functions
+inline void QOpenGLFunctions_3_3_Core::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ d_3_2_Core->SampleMaski(index, mask);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ d_3_2_Core->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ d_3_2_Core->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ d_3_2_Core->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLFunctions_3_3_Core::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ return d_3_2_Core->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDeleteSync(GLsync sync)
+{
+ d_3_2_Core->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Core::glIsSync(GLsync sync)
+{
+ return d_3_2_Core->IsSync(sync);
+}
+
+inline GLsync QOpenGLFunctions_3_3_Core::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ return d_3_2_Core->FenceSync(condition, flags);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glProvokingVertex(GLenum mode)
+{
+ d_3_2_Core->ProvokingVertex(mode);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ d_3_2_Core->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ d_3_2_Core->FramebufferTexture(target, attachment, texture, level);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetBufferParameteri64v(target, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data)
+{
+ d_3_2_Core->GetInteger64i_v(target, index, data);
+}
+
+
+// OpenGL 3.3 core functions
+inline void QOpenGLFunctions_3_3_Core::glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP4uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP4ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP3uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP3ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP2uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP2ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP1uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP1ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glSecondaryColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->SecondaryColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glSecondaryColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->SecondaryColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glColorP4uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP4uiv(type, color);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glColorP4ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP4ui(type, color);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glNormalP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->NormalP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glNormalP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->NormalP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP4uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP4ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP3uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP3ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP2uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP2ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP1uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP1ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexCoordP4uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP4uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexCoordP4ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP4ui(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexCoordP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexCoordP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexCoordP2uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP2uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexCoordP2ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP2ui(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexCoordP1uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP1uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glTexCoordP1ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP1ui(type, coords);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexP4uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP4uiv(type, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexP4ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP4ui(type, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexP3uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP3uiv(type, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexP3ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP3ui(type, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexP2uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP2uiv(type, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexP2ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP2ui(type, value);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params)
+{
+ d_3_3_Core->GetQueryObjectui64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params)
+{
+ d_3_3_Core->GetQueryObjecti64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glQueryCounter(GLuint id, GLenum target)
+{
+ d_3_3_Core->QueryCounter(id, target);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params)
+{
+ d_3_3_Core->GetSamplerParameterIuiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params)
+{
+ d_3_3_Core->GetSamplerParameterfv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameterIiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameteriv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ d_3_3_Core->SamplerParameterIuiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameterIiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param)
+{
+ d_3_3_Core->SamplerParameterfv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param)
+{
+ d_3_3_Core->SamplerParameterf(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameteriv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glSamplerParameteri(GLuint sampler, GLenum pname, GLint param)
+{
+ d_3_3_Core->SamplerParameteri(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBindSampler(GLuint unit, GLuint sampler)
+{
+ d_3_3_Core->BindSampler(unit, sampler);
+}
+
+inline GLboolean QOpenGLFunctions_3_3_Core::glIsSampler(GLuint sampler)
+{
+ return d_3_3_Core->IsSampler(sampler);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glDeleteSamplers(GLsizei count, const GLuint *samplers)
+{
+ d_3_3_Core->DeleteSamplers(count, samplers);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glGenSamplers(GLsizei count, GLuint *samplers)
+{
+ d_3_3_Core->GenSamplers(count, samplers);
+}
+
+inline GLint QOpenGLFunctions_3_3_Core::glGetFragDataIndex(GLuint program, const GLchar *name)
+{
+ return d_3_3_Core->GetFragDataIndex(program, name);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name)
+{
+ d_3_3_Core->BindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+inline void QOpenGLFunctions_3_3_Core::glVertexAttribDivisor(GLuint index, GLuint divisor)
+{
+ d_3_3_Core->VertexAttribDivisor(index, divisor);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_4_0_compatibility.cpp b/src/gui/opengl/qopenglfunctions_4_0_compatibility.cpp
new file mode 100644
index 0000000000..af5d3eccc1
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_0_compatibility.cpp
@@ -0,0 +1,376 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_4_0_compatibility.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_4_0_Compatibility
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_4_0_Compatibility class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_4_0_Compatibility::QOpenGLFunctions_4_0_Compatibility()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+ , d_3_2_Core(0)
+ , d_3_3_Core(0)
+ , d_4_0_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+ , d_1_3_Deprecated(0)
+ , d_1_4_Deprecated(0)
+ , d_2_0_Deprecated(0)
+ , d_3_0_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_4_0_Compatibility::~QOpenGLFunctions_4_0_Compatibility()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+ if (d_3_2_Core && !d_3_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_2_Core->context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ delete d_3_2_Core;
+ }
+ if (d_3_3_Core && !d_3_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_3_Core->context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ delete d_3_3_Core;
+ }
+ if (d_4_0_Core && !d_4_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_0_Core->context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ delete d_4_0_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+ if (d_1_3_Deprecated && !d_1_3_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Deprecated->context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ delete d_1_3_Deprecated;
+ }
+ if (d_1_4_Deprecated && !d_1_4_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Deprecated->context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ delete d_1_4_Deprecated;
+ }
+ if (d_2_0_Deprecated && !d_2_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Deprecated->context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ delete d_2_0_Deprecated;
+ }
+ if (d_3_0_Deprecated && !d_3_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Deprecated->context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ delete d_3_0_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_4_0_Compatibility::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_4_0_Compatibility::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus(), d);
+ }
+ d_3_2_Core = static_cast<QOpenGLFunctions_3_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus(), d);
+ }
+ d_3_3_Core = static_cast<QOpenGLFunctions_3_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus(), d);
+ }
+ d_4_0_Core = static_cast<QOpenGLFunctions_4_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_4_Deprecated = static_cast<QOpenGLFunctions_1_4_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_2_0_Deprecated = static_cast<QOpenGLFunctions_2_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_3_0_Deprecated = static_cast<QOpenGLFunctions_3_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_4_0_Compatibility::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(4, 0))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_4_0_Compatibility::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(4, 0);
+ v.setProfile(QSurfaceFormat::CompatibilityProfile);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_4_0_compatibility.h b/src/gui/opengl/qopenglfunctions_4_0_compatibility.h
new file mode 100644
index 0000000000..72e270a1c8
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_0_compatibility.h
@@ -0,0 +1,5020 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_4_0_COMPATIBILITY_H
+#define QOPENGLVERSIONFUNCTIONS_4_0_COMPATIBILITY_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_4_0_Compatibility : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_4_0_Compatibility();
+ ~QOpenGLFunctions_4_0_Compatibility();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+ // OpenGL 3.2 core functions
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+ void glProvokingVertex(GLenum mode);
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params);
+ void glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data);
+
+ // OpenGL 3.3 core functions
+ void glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glSecondaryColorP3uiv(GLenum type, const GLuint *color);
+ void glSecondaryColorP3ui(GLenum type, GLuint color);
+ void glColorP4uiv(GLenum type, const GLuint *color);
+ void glColorP4ui(GLenum type, GLuint color);
+ void glColorP3uiv(GLenum type, const GLuint *color);
+ void glColorP3ui(GLenum type, GLuint color);
+ void glNormalP3uiv(GLenum type, const GLuint *coords);
+ void glNormalP3ui(GLenum type, GLuint coords);
+ void glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords);
+ void glTexCoordP4uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP4ui(GLenum type, GLuint coords);
+ void glTexCoordP3uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP3ui(GLenum type, GLuint coords);
+ void glTexCoordP2uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP2ui(GLenum type, GLuint coords);
+ void glTexCoordP1uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP1ui(GLenum type, GLuint coords);
+ void glVertexP4uiv(GLenum type, const GLuint *value);
+ void glVertexP4ui(GLenum type, GLuint value);
+ void glVertexP3uiv(GLenum type, const GLuint *value);
+ void glVertexP3ui(GLenum type, GLuint value);
+ void glVertexP2uiv(GLenum type, const GLuint *value);
+ void glVertexP2ui(GLenum type, GLuint value);
+ void glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params);
+ void glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params);
+ void glQueryCounter(GLuint id, GLenum target);
+ void glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params);
+ void glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params);
+ void glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params);
+ void glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params);
+ void glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param);
+ void glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param);
+ void glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param);
+ void glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameteri(GLuint sampler, GLenum pname, GLint param);
+ void glBindSampler(GLuint unit, GLuint sampler);
+ GLboolean glIsSampler(GLuint sampler);
+ void glDeleteSamplers(GLsizei count, const GLuint *samplers);
+ void glGenSamplers(GLsizei count, GLuint *samplers);
+ GLint glGetFragDataIndex(GLuint program, const GLchar *name);
+ void glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+ void glVertexAttribDivisor(GLuint index, GLuint divisor);
+
+ // OpenGL 4.0 core functions
+ void glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void glEndQueryIndexed(GLenum target, GLuint index);
+ void glBeginQueryIndexed(GLenum target, GLuint index, GLuint id);
+ void glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream);
+ void glDrawTransformFeedback(GLenum mode, GLuint id);
+ void glResumeTransformFeedback();
+ void glPauseTransformFeedback();
+ GLboolean glIsTransformFeedback(GLuint id);
+ void glGenTransformFeedbacks(GLsizei n, GLuint *ids);
+ void glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids);
+ void glBindTransformFeedback(GLenum target, GLuint id);
+ void glPatchParameterfv(GLenum pname, const GLfloat *values);
+ void glPatchParameteri(GLenum pname, GLint value);
+ void glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values);
+ void glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params);
+ void glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices);
+ void glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
+ GLuint glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name);
+ GLint glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name);
+ void glGetUniformdv(GLuint program, GLint location, GLdouble *params);
+ void glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniform4dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform3dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform2dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform1dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void glUniform2d(GLint location, GLdouble x, GLdouble y);
+ void glUniform1d(GLint location, GLdouble x);
+ void glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect);
+ void glDrawArraysIndirect(GLenum mode, const GLvoid *indirect);
+ void glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void glBlendFunci(GLuint buf, GLenum src, GLenum dst);
+ void glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void glBlendEquationi(GLuint buf, GLenum mode);
+ void glMinSampleShading(GLfloat value);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+ // OpenGL 1.3 deprecated functions
+ void glMultTransposeMatrixd(const GLdouble *m);
+ void glMultTransposeMatrixf(const GLfloat *m);
+ void glLoadTransposeMatrixd(const GLdouble *m);
+ void glLoadTransposeMatrixf(const GLfloat *m);
+ void glMultiTexCoord4sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4iv(GLenum target, const GLint *v);
+ void glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3iv(GLenum target, const GLint *v);
+ void glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord2s(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2iv(GLenum target, const GLint *v);
+ void glMultiTexCoord2i(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord1s(GLenum target, GLshort s);
+ void glMultiTexCoord1iv(GLenum target, const GLint *v);
+ void glMultiTexCoord1i(GLenum target, GLint s);
+ void glMultiTexCoord1fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1f(GLenum target, GLfloat s);
+ void glMultiTexCoord1dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1d(GLenum target, GLdouble s);
+ void glClientActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 deprecated functions
+ void glWindowPos3sv(const GLshort *v);
+ void glWindowPos3s(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3iv(const GLint *v);
+ void glWindowPos3i(GLint x, GLint y, GLint z);
+ void glWindowPos3fv(const GLfloat *v);
+ void glWindowPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dv(const GLdouble *v);
+ void glWindowPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2sv(const GLshort *v);
+ void glWindowPos2s(GLshort x, GLshort y);
+ void glWindowPos2iv(const GLint *v);
+ void glWindowPos2i(GLint x, GLint y);
+ void glWindowPos2fv(const GLfloat *v);
+ void glWindowPos2f(GLfloat x, GLfloat y);
+ void glWindowPos2dv(const GLdouble *v);
+ void glWindowPos2d(GLdouble x, GLdouble y);
+ void glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glSecondaryColor3usv(const GLushort *v);
+ void glSecondaryColor3us(GLushort red, GLushort green, GLushort blue);
+ void glSecondaryColor3uiv(const GLuint *v);
+ void glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glSecondaryColor3ubv(const GLubyte *v);
+ void glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glSecondaryColor3sv(const GLshort *v);
+ void glSecondaryColor3s(GLshort red, GLshort green, GLshort blue);
+ void glSecondaryColor3iv(const GLint *v);
+ void glSecondaryColor3i(GLint red, GLint green, GLint blue);
+ void glSecondaryColor3fv(const GLfloat *v);
+ void glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glSecondaryColor3dv(const GLdouble *v);
+ void glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glSecondaryColor3bv(const GLbyte *v);
+ void glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glFogCoorddv(const GLdouble *coord);
+ void glFogCoordd(GLdouble coord);
+ void glFogCoordfv(const GLfloat *coord);
+ void glFogCoordf(GLfloat coord);
+
+ // OpenGL 1.5 deprecated functions
+
+ // OpenGL 2.0 deprecated functions
+ void glVertexAttrib4usv(GLuint index, const GLushort *v);
+ void glVertexAttrib4uiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4sv(GLuint index, const GLshort *v);
+ void glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertexAttrib4iv(GLuint index, const GLint *v);
+ void glVertexAttrib4fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexAttrib4dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttrib4bv(GLuint index, const GLbyte *v);
+ void glVertexAttrib4Nusv(GLuint index, const GLushort *v);
+ void glVertexAttrib4Nuiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4Nubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void glVertexAttrib4Nsv(GLuint index, const GLshort *v);
+ void glVertexAttrib4Niv(GLuint index, const GLint *v);
+ void glVertexAttrib4Nbv(GLuint index, const GLbyte *v);
+ void glVertexAttrib3sv(GLuint index, const GLshort *v);
+ void glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z);
+ void glVertexAttrib3fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexAttrib3dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttrib2sv(GLuint index, const GLshort *v);
+ void glVertexAttrib2s(GLuint index, GLshort x, GLshort y);
+ void glVertexAttrib2fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y);
+ void glVertexAttrib2dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttrib1sv(GLuint index, const GLshort *v);
+ void glVertexAttrib1s(GLuint index, GLshort x);
+ void glVertexAttrib1fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib1f(GLuint index, GLfloat x);
+ void glVertexAttrib1dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib1d(GLuint index, GLdouble x);
+
+ // OpenGL 2.1 deprecated functions
+
+ // OpenGL 3.0 deprecated functions
+ void glVertexAttribI4usv(GLuint index, const GLushort *v);
+ void glVertexAttribI4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttribI4sv(GLuint index, const GLshort *v);
+ void glVertexAttribI4bv(GLuint index, const GLbyte *v);
+ void glVertexAttribI4uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI3uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI2uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI1uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI4iv(GLuint index, const GLint *v);
+ void glVertexAttribI3iv(GLuint index, const GLint *v);
+ void glVertexAttribI2iv(GLuint index, const GLint *v);
+ void glVertexAttribI1iv(GLuint index, const GLint *v);
+ void glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z);
+ void glVertexAttribI2ui(GLuint index, GLuint x, GLuint y);
+ void glVertexAttribI1ui(GLuint index, GLuint x);
+ void glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z);
+ void glVertexAttribI2i(GLuint index, GLint x, GLint y);
+ void glVertexAttribI1i(GLuint index, GLint x);
+
+ // OpenGL 3.1 deprecated functions
+
+ // OpenGL 3.2 deprecated functions
+
+ // OpenGL 3.3 deprecated functions
+
+ // OpenGL 4.0 deprecated functions
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+ QOpenGLFunctions_3_2_CoreBackend* d_3_2_Core;
+ QOpenGLFunctions_3_3_CoreBackend* d_3_3_Core;
+ QOpenGLFunctions_4_0_CoreBackend* d_4_0_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+ QOpenGLFunctions_1_3_DeprecatedBackend* d_1_3_Deprecated;
+ QOpenGLFunctions_1_4_DeprecatedBackend* d_1_4_Deprecated;
+ QOpenGLFunctions_2_0_DeprecatedBackend* d_2_0_Deprecated;
+ QOpenGLFunctions_3_0_DeprecatedBackend* d_3_0_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_4_0_Compatibility::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_0_Compatibility::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_4_0_Compatibility::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_4_0_Compatibility::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_4_0_Compatibility::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_4_0_Compatibility::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_4_0_Compatibility::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_4_0_Compatibility::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_4_0_Compatibility::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_4_0_Compatibility::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_4_0_Compatibility::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_4_0_Compatibility::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_4_0_Compatibility::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_4_0_Compatibility::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_4_0_Compatibility::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_0_Compatibility::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_4_0_Compatibility::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_4_0_Compatibility::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_4_0_Compatibility::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+// OpenGL 3.2 core functions
+inline void QOpenGLFunctions_4_0_Compatibility::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ d_3_2_Core->SampleMaski(index, mask);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ d_3_2_Core->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ d_3_2_Core->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ d_3_2_Core->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLFunctions_4_0_Compatibility::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ return d_3_2_Core->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDeleteSync(GLsync sync)
+{
+ d_3_2_Core->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsSync(GLsync sync)
+{
+ return d_3_2_Core->IsSync(sync);
+}
+
+inline GLsync QOpenGLFunctions_4_0_Compatibility::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ return d_3_2_Core->FenceSync(condition, flags);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glProvokingVertex(GLenum mode)
+{
+ d_3_2_Core->ProvokingVertex(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ d_3_2_Core->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ d_3_2_Core->FramebufferTexture(target, attachment, texture, level);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetBufferParameteri64v(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data)
+{
+ d_3_2_Core->GetInteger64i_v(target, index, data);
+}
+
+
+// OpenGL 3.3 core functions
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP4uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP4ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP3uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP3ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP2uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP2ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP1uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP1ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->SecondaryColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->SecondaryColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColorP4uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP4uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColorP4ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP4ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormalP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->NormalP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormalP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->NormalP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP4uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP4ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP3uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP3ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP2uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP2ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP1uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP1ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoordP4uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP4uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoordP4ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP4ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoordP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoordP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoordP2uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP2uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoordP2ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP2ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoordP1uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP1uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoordP1ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP1ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexP4uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP4uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexP4ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP4ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexP3uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP3uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexP3ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP3ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexP2uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP2uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexP2ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP2ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params)
+{
+ d_3_3_Core->GetQueryObjectui64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params)
+{
+ d_3_3_Core->GetQueryObjecti64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glQueryCounter(GLuint id, GLenum target)
+{
+ d_3_3_Core->QueryCounter(id, target);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params)
+{
+ d_3_3_Core->GetSamplerParameterIuiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params)
+{
+ d_3_3_Core->GetSamplerParameterfv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameterIiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameteriv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ d_3_3_Core->SamplerParameterIuiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameterIiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param)
+{
+ d_3_3_Core->SamplerParameterfv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param)
+{
+ d_3_3_Core->SamplerParameterf(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameteriv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSamplerParameteri(GLuint sampler, GLenum pname, GLint param)
+{
+ d_3_3_Core->SamplerParameteri(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBindSampler(GLuint unit, GLuint sampler)
+{
+ d_3_3_Core->BindSampler(unit, sampler);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsSampler(GLuint sampler)
+{
+ return d_3_3_Core->IsSampler(sampler);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDeleteSamplers(GLsizei count, const GLuint *samplers)
+{
+ d_3_3_Core->DeleteSamplers(count, samplers);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGenSamplers(GLsizei count, GLuint *samplers)
+{
+ d_3_3_Core->GenSamplers(count, samplers);
+}
+
+inline GLint QOpenGLFunctions_4_0_Compatibility::glGetFragDataIndex(GLuint program, const GLchar *name)
+{
+ return d_3_3_Core->GetFragDataIndex(program, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name)
+{
+ d_3_3_Core->BindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribDivisor(GLuint index, GLuint divisor)
+{
+ d_3_3_Core->VertexAttribDivisor(index, divisor);
+}
+
+
+// OpenGL 4.0 core functions
+inline void QOpenGLFunctions_4_0_Compatibility::glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params)
+{
+ d_4_0_Core->GetQueryIndexediv(target, index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEndQueryIndexed(GLenum target, GLuint index)
+{
+ d_4_0_Core->EndQueryIndexed(target, index);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBeginQueryIndexed(GLenum target, GLuint index, GLuint id)
+{
+ d_4_0_Core->BeginQueryIndexed(target, index, id);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream)
+{
+ d_4_0_Core->DrawTransformFeedbackStream(mode, id, stream);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawTransformFeedback(GLenum mode, GLuint id)
+{
+ d_4_0_Core->DrawTransformFeedback(mode, id);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glResumeTransformFeedback()
+{
+ d_4_0_Core->ResumeTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPauseTransformFeedback()
+{
+ d_4_0_Core->PauseTransformFeedback();
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsTransformFeedback(GLuint id)
+{
+ return d_4_0_Core->IsTransformFeedback(id);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGenTransformFeedbacks(GLsizei n, GLuint *ids)
+{
+ d_4_0_Core->GenTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids)
+{
+ d_4_0_Core->DeleteTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBindTransformFeedback(GLenum target, GLuint id)
+{
+ d_4_0_Core->BindTransformFeedback(target, id);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPatchParameterfv(GLenum pname, const GLfloat *values)
+{
+ d_4_0_Core->PatchParameterfv(pname, values);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPatchParameteri(GLenum pname, GLint value)
+{
+ d_4_0_Core->PatchParameteri(pname, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetProgramStageiv(program, shadertype, pname, values);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params)
+{
+ d_4_0_Core->GetUniformSubroutineuiv(shadertype, location, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices)
+{
+ d_4_0_Core->UniformSubroutinesuiv(shadertype, count, indices);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineUniformName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+inline GLuint QOpenGLFunctions_4_0_Compatibility::glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineIndex(program, shadertype, name);
+}
+
+inline GLint QOpenGLFunctions_4_0_Compatibility::glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineUniformLocation(program, shadertype, name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetUniformdv(GLuint program, GLint location, GLdouble *params)
+{
+ d_4_0_Core->GetUniformdv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform4dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform4dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform3dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform3dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform2dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform2dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform1dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform1dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_0_Core->Uniform4d(location, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_0_Core->Uniform3d(location, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform2d(GLint location, GLdouble x, GLdouble y)
+{
+ d_4_0_Core->Uniform2d(location, x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glUniform1d(GLint location, GLdouble x)
+{
+ d_4_0_Core->Uniform1d(location, x);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawElementsIndirect(mode, type, indirect);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawArraysIndirect(GLenum mode, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawArraysIndirect(mode, indirect);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ d_4_0_Core->BlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBlendFunci(GLuint buf, GLenum src, GLenum dst)
+{
+ d_4_0_Core->BlendFunci(buf, src, dst);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ d_4_0_Core->BlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBlendEquationi(GLuint buf, GLenum mode)
+{
+ d_4_0_Core->BlendEquationi(buf, mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMinSampleShading(GLfloat value)
+{
+ d_4_0_Core->MinSampleShading(value);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_4_0_Compatibility::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_4_0_Compatibility::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_4_0_Compatibility::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_4_0_Compatibility::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Compatibility::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_4_0_Compatibility::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+// OpenGL 1.3 deprecated functions
+inline void QOpenGLFunctions_4_0_Compatibility::glMultTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLoadTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glLoadTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord4sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_3_Deprecated->MultiTexCoord4s(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord4iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_3_Deprecated->MultiTexCoord4i(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord4fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_3_Deprecated->MultiTexCoord4f(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord4dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_3_Deprecated->MultiTexCoord4d(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord3sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ d_1_3_Deprecated->MultiTexCoord3s(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord3iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r)
+{
+ d_1_3_Deprecated->MultiTexCoord3i(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord3fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_3_Deprecated->MultiTexCoord3f(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord3dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_3_Deprecated->MultiTexCoord3d(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord2sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord2s(GLenum target, GLshort s, GLshort t)
+{
+ d_1_3_Deprecated->MultiTexCoord2s(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord2iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord2i(GLenum target, GLint s, GLint t)
+{
+ d_1_3_Deprecated->MultiTexCoord2i(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord2fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t)
+{
+ d_1_3_Deprecated->MultiTexCoord2f(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord2dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t)
+{
+ d_1_3_Deprecated->MultiTexCoord2d(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord1sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord1s(GLenum target, GLshort s)
+{
+ d_1_3_Deprecated->MultiTexCoord1s(target, s);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord1iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord1i(GLenum target, GLint s)
+{
+ d_1_3_Deprecated->MultiTexCoord1i(target, s);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord1fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord1f(GLenum target, GLfloat s)
+{
+ d_1_3_Deprecated->MultiTexCoord1f(target, s);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord1dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glMultiTexCoord1d(GLenum target, GLdouble s)
+{
+ d_1_3_Deprecated->MultiTexCoord1d(target, s);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glClientActiveTexture(GLenum texture)
+{
+ d_1_3_Deprecated->ClientActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 deprecated functions
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos3sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_4_Deprecated->WindowPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos3iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos3iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_4_Deprecated->WindowPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos3fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_4_Deprecated->WindowPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos3dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_4_Deprecated->WindowPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos2sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos2sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos2s(GLshort x, GLshort y)
+{
+ d_1_4_Deprecated->WindowPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos2iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos2iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos2i(GLint x, GLint y)
+{
+ d_1_4_Deprecated->WindowPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos2fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos2fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos2f(GLfloat x, GLfloat y)
+{
+ d_1_4_Deprecated->WindowPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos2dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos2dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glWindowPos2d(GLdouble x, GLdouble y)
+{
+ d_1_4_Deprecated->WindowPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->SecondaryColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3usv(const GLushort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3usv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3uiv(const GLuint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3uiv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3ubv(const GLubyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3ubv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3sv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3iv(const GLint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3iv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->SecondaryColor3fv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_4_Deprecated->SecondaryColor3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->SecondaryColor3dv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_4_Deprecated->SecondaryColor3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3bv(const GLbyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3bv(v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->FogCoordPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFogCoorddv(const GLdouble *coord)
+{
+ d_1_4_Deprecated->FogCoorddv(coord);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFogCoordd(GLdouble coord)
+{
+ d_1_4_Deprecated->FogCoordd(coord);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFogCoordfv(const GLfloat *coord)
+{
+ d_1_4_Deprecated->FogCoordfv(coord);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glFogCoordf(GLfloat coord)
+{
+ d_1_4_Deprecated->FogCoordf(coord);
+}
+
+
+// OpenGL 1.5 deprecated functions
+
+// OpenGL 2.0 deprecated functions
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4usv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4usv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4uiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4ubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_2_0_Deprecated->VertexAttrib4s(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4iv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib4fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_2_0_Deprecated->VertexAttrib4f(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib4dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_2_0_Deprecated->VertexAttrib4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4bv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4bv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4Nusv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nusv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4Nuiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nuiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4Nubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nubv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ d_2_0_Deprecated->VertexAttrib4Nub(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4Nsv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nsv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4Niv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Niv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib4Nbv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nbv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib3sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib3sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ d_2_0_Deprecated->VertexAttrib3s(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib3fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib3fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_2_0_Deprecated->VertexAttrib3f(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib3dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib3dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_2_0_Deprecated->VertexAttrib3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib2sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib2sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib2s(GLuint index, GLshort x, GLshort y)
+{
+ d_2_0_Deprecated->VertexAttrib2s(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib2fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib2fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y)
+{
+ d_2_0_Deprecated->VertexAttrib2f(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib2dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib2dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_2_0_Deprecated->VertexAttrib2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib1sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib1sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib1s(GLuint index, GLshort x)
+{
+ d_2_0_Deprecated->VertexAttrib1s(index, x);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib1fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib1fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib1f(GLuint index, GLfloat x)
+{
+ d_2_0_Deprecated->VertexAttrib1f(index, x);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib1dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib1dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttrib1d(GLuint index, GLdouble x)
+{
+ d_2_0_Deprecated->VertexAttrib1d(index, x);
+}
+
+
+// OpenGL 2.1 deprecated functions
+
+// OpenGL 3.0 deprecated functions
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI4usv(GLuint index, const GLushort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4usv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI4ubv(GLuint index, const GLubyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI4sv(GLuint index, const GLshort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI4bv(GLuint index, const GLbyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4bv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI4uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI3uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI2uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI1uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI4iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI3iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI2iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI1iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ d_3_0_Deprecated->VertexAttribI4ui(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ d_3_0_Deprecated->VertexAttribI3ui(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI2ui(GLuint index, GLuint x, GLuint y)
+{
+ d_3_0_Deprecated->VertexAttribI2ui(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI1ui(GLuint index, GLuint x)
+{
+ d_3_0_Deprecated->VertexAttribI1ui(index, x);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ d_3_0_Deprecated->VertexAttribI4i(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z)
+{
+ d_3_0_Deprecated->VertexAttribI3i(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI2i(GLuint index, GLint x, GLint y)
+{
+ d_3_0_Deprecated->VertexAttribI2i(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Compatibility::glVertexAttribI1i(GLuint index, GLint x)
+{
+ d_3_0_Deprecated->VertexAttribI1i(index, x);
+}
+
+
+// OpenGL 3.1 deprecated functions
+
+// OpenGL 3.2 deprecated functions
+
+// OpenGL 3.3 deprecated functions
+
+// OpenGL 4.0 deprecated functions
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_4_0_core.cpp b/src/gui/opengl/qopenglfunctions_4_0_core.cpp
new file mode 100644
index 0000000000..b018531b37
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_0_core.cpp
@@ -0,0 +1,282 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_4_0_core.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_4_0_Core
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_4_0_Core class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_4_0_Core::QOpenGLFunctions_4_0_Core()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+ , d_3_2_Core(0)
+ , d_3_3_Core(0)
+ , d_4_0_Core(0)
+{
+}
+
+QOpenGLFunctions_4_0_Core::~QOpenGLFunctions_4_0_Core()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+ if (d_3_2_Core && !d_3_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_2_Core->context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ delete d_3_2_Core;
+ }
+ if (d_3_3_Core && !d_3_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_3_Core->context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ delete d_3_3_Core;
+ }
+ if (d_4_0_Core && !d_4_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_0_Core->context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ delete d_4_0_Core;
+ }
+}
+
+bool QOpenGLFunctions_4_0_Core::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_4_0_Core::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus(), d);
+ }
+ d_3_2_Core = static_cast<QOpenGLFunctions_3_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus(), d);
+ }
+ d_3_3_Core = static_cast<QOpenGLFunctions_3_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus(), d);
+ }
+ d_4_0_Core = static_cast<QOpenGLFunctions_4_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_4_0_Core::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(4, 0))
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_4_0_Core::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(4, 0);
+ v.setProfile(QSurfaceFormat::CoreProfile);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_4_0_core.h b/src/gui/opengl/qopenglfunctions_4_0_core.h
new file mode 100644
index 0000000000..7d4e468399
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_0_core.h
@@ -0,0 +1,2351 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_4_0_CORE_H
+#define QOPENGLVERSIONFUNCTIONS_4_0_CORE_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_4_0_Core : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_4_0_Core();
+ ~QOpenGLFunctions_4_0_Core();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+ // OpenGL 3.2 core functions
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+ void glProvokingVertex(GLenum mode);
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params);
+ void glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data);
+
+ // OpenGL 3.3 core functions
+ void glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glSecondaryColorP3uiv(GLenum type, const GLuint *color);
+ void glSecondaryColorP3ui(GLenum type, GLuint color);
+ void glColorP4uiv(GLenum type, const GLuint *color);
+ void glColorP4ui(GLenum type, GLuint color);
+ void glColorP3uiv(GLenum type, const GLuint *color);
+ void glColorP3ui(GLenum type, GLuint color);
+ void glNormalP3uiv(GLenum type, const GLuint *coords);
+ void glNormalP3ui(GLenum type, GLuint coords);
+ void glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords);
+ void glTexCoordP4uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP4ui(GLenum type, GLuint coords);
+ void glTexCoordP3uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP3ui(GLenum type, GLuint coords);
+ void glTexCoordP2uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP2ui(GLenum type, GLuint coords);
+ void glTexCoordP1uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP1ui(GLenum type, GLuint coords);
+ void glVertexP4uiv(GLenum type, const GLuint *value);
+ void glVertexP4ui(GLenum type, GLuint value);
+ void glVertexP3uiv(GLenum type, const GLuint *value);
+ void glVertexP3ui(GLenum type, GLuint value);
+ void glVertexP2uiv(GLenum type, const GLuint *value);
+ void glVertexP2ui(GLenum type, GLuint value);
+ void glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params);
+ void glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params);
+ void glQueryCounter(GLuint id, GLenum target);
+ void glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params);
+ void glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params);
+ void glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params);
+ void glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params);
+ void glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param);
+ void glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param);
+ void glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param);
+ void glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameteri(GLuint sampler, GLenum pname, GLint param);
+ void glBindSampler(GLuint unit, GLuint sampler);
+ GLboolean glIsSampler(GLuint sampler);
+ void glDeleteSamplers(GLsizei count, const GLuint *samplers);
+ void glGenSamplers(GLsizei count, GLuint *samplers);
+ GLint glGetFragDataIndex(GLuint program, const GLchar *name);
+ void glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+ void glVertexAttribDivisor(GLuint index, GLuint divisor);
+
+ // OpenGL 4.0 core functions
+ void glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void glEndQueryIndexed(GLenum target, GLuint index);
+ void glBeginQueryIndexed(GLenum target, GLuint index, GLuint id);
+ void glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream);
+ void glDrawTransformFeedback(GLenum mode, GLuint id);
+ void glResumeTransformFeedback();
+ void glPauseTransformFeedback();
+ GLboolean glIsTransformFeedback(GLuint id);
+ void glGenTransformFeedbacks(GLsizei n, GLuint *ids);
+ void glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids);
+ void glBindTransformFeedback(GLenum target, GLuint id);
+ void glPatchParameterfv(GLenum pname, const GLfloat *values);
+ void glPatchParameteri(GLenum pname, GLint value);
+ void glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values);
+ void glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params);
+ void glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices);
+ void glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
+ GLuint glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name);
+ GLint glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name);
+ void glGetUniformdv(GLuint program, GLint location, GLdouble *params);
+ void glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniform4dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform3dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform2dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform1dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void glUniform2d(GLint location, GLdouble x, GLdouble y);
+ void glUniform1d(GLint location, GLdouble x);
+ void glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect);
+ void glDrawArraysIndirect(GLenum mode, const GLvoid *indirect);
+ void glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void glBlendFunci(GLuint buf, GLenum src, GLenum dst);
+ void glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void glBlendEquationi(GLuint buf, GLenum mode);
+ void glMinSampleShading(GLfloat value);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+ QOpenGLFunctions_3_2_CoreBackend* d_3_2_Core;
+ QOpenGLFunctions_3_3_CoreBackend* d_3_3_Core;
+ QOpenGLFunctions_4_0_CoreBackend* d_4_0_Core;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_4_0_Core::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_0_Core::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_4_0_Core::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_4_0_Core::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_4_0_Core::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_4_0_Core::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_4_0_Core::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_4_0_Core::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_4_0_Core::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_4_0_Core::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_4_0_Core::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_4_0_Core::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_4_0_Core::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_4_0_Core::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_4_0_Core::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_4_0_Core::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_4_0_Core::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_4_0_Core::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_4_0_Core::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_0_Core::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_4_0_Core::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_4_0_Core::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_4_0_Core::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+// OpenGL 3.2 core functions
+inline void QOpenGLFunctions_4_0_Core::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ d_3_2_Core->SampleMaski(index, mask);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ d_3_2_Core->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ d_3_2_Core->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ d_3_2_Core->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLFunctions_4_0_Core::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ return d_3_2_Core->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDeleteSync(GLsync sync)
+{
+ d_3_2_Core->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsSync(GLsync sync)
+{
+ return d_3_2_Core->IsSync(sync);
+}
+
+inline GLsync QOpenGLFunctions_4_0_Core::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ return d_3_2_Core->FenceSync(condition, flags);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glProvokingVertex(GLenum mode)
+{
+ d_3_2_Core->ProvokingVertex(mode);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ d_3_2_Core->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ d_3_2_Core->FramebufferTexture(target, attachment, texture, level);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetBufferParameteri64v(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data)
+{
+ d_3_2_Core->GetInteger64i_v(target, index, data);
+}
+
+
+// OpenGL 3.3 core functions
+inline void QOpenGLFunctions_4_0_Core::glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP4uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP4ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP3uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP3ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP2uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP2ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP1uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP1ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glSecondaryColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->SecondaryColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glSecondaryColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->SecondaryColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glColorP4uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP4uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glColorP4ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP4ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glNormalP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->NormalP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glNormalP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->NormalP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP4uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP4ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP3uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP3ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP2uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP2ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP1uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP1ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexCoordP4uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP4uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexCoordP4ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP4ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexCoordP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexCoordP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexCoordP2uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP2uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexCoordP2ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP2ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexCoordP1uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP1uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glTexCoordP1ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP1ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexP4uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP4uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexP4ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP4ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexP3uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP3uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexP3ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP3ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexP2uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP2uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexP2ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP2ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params)
+{
+ d_3_3_Core->GetQueryObjectui64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params)
+{
+ d_3_3_Core->GetQueryObjecti64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glQueryCounter(GLuint id, GLenum target)
+{
+ d_3_3_Core->QueryCounter(id, target);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params)
+{
+ d_3_3_Core->GetSamplerParameterIuiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params)
+{
+ d_3_3_Core->GetSamplerParameterfv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameterIiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameteriv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ d_3_3_Core->SamplerParameterIuiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameterIiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param)
+{
+ d_3_3_Core->SamplerParameterfv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param)
+{
+ d_3_3_Core->SamplerParameterf(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameteriv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glSamplerParameteri(GLuint sampler, GLenum pname, GLint param)
+{
+ d_3_3_Core->SamplerParameteri(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBindSampler(GLuint unit, GLuint sampler)
+{
+ d_3_3_Core->BindSampler(unit, sampler);
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsSampler(GLuint sampler)
+{
+ return d_3_3_Core->IsSampler(sampler);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDeleteSamplers(GLsizei count, const GLuint *samplers)
+{
+ d_3_3_Core->DeleteSamplers(count, samplers);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGenSamplers(GLsizei count, GLuint *samplers)
+{
+ d_3_3_Core->GenSamplers(count, samplers);
+}
+
+inline GLint QOpenGLFunctions_4_0_Core::glGetFragDataIndex(GLuint program, const GLchar *name)
+{
+ return d_3_3_Core->GetFragDataIndex(program, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name)
+{
+ d_3_3_Core->BindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glVertexAttribDivisor(GLuint index, GLuint divisor)
+{
+ d_3_3_Core->VertexAttribDivisor(index, divisor);
+}
+
+
+// OpenGL 4.0 core functions
+inline void QOpenGLFunctions_4_0_Core::glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params)
+{
+ d_4_0_Core->GetQueryIndexediv(target, index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glEndQueryIndexed(GLenum target, GLuint index)
+{
+ d_4_0_Core->EndQueryIndexed(target, index);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBeginQueryIndexed(GLenum target, GLuint index, GLuint id)
+{
+ d_4_0_Core->BeginQueryIndexed(target, index, id);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream)
+{
+ d_4_0_Core->DrawTransformFeedbackStream(mode, id, stream);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawTransformFeedback(GLenum mode, GLuint id)
+{
+ d_4_0_Core->DrawTransformFeedback(mode, id);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glResumeTransformFeedback()
+{
+ d_4_0_Core->ResumeTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_0_Core::glPauseTransformFeedback()
+{
+ d_4_0_Core->PauseTransformFeedback();
+}
+
+inline GLboolean QOpenGLFunctions_4_0_Core::glIsTransformFeedback(GLuint id)
+{
+ return d_4_0_Core->IsTransformFeedback(id);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGenTransformFeedbacks(GLsizei n, GLuint *ids)
+{
+ d_4_0_Core->GenTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids)
+{
+ d_4_0_Core->DeleteTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBindTransformFeedback(GLenum target, GLuint id)
+{
+ d_4_0_Core->BindTransformFeedback(target, id);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glPatchParameterfv(GLenum pname, const GLfloat *values)
+{
+ d_4_0_Core->PatchParameterfv(pname, values);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glPatchParameteri(GLenum pname, GLint value)
+{
+ d_4_0_Core->PatchParameteri(pname, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetProgramStageiv(program, shadertype, pname, values);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params)
+{
+ d_4_0_Core->GetUniformSubroutineuiv(shadertype, location, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices)
+{
+ d_4_0_Core->UniformSubroutinesuiv(shadertype, count, indices);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineUniformName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+inline GLuint QOpenGLFunctions_4_0_Core::glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineIndex(program, shadertype, name);
+}
+
+inline GLint QOpenGLFunctions_4_0_Core::glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineUniformLocation(program, shadertype, name);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glGetUniformdv(GLuint program, GLint location, GLdouble *params)
+{
+ d_4_0_Core->GetUniformdv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform4dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform4dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform3dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform3dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform2dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform2dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform1dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform1dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_0_Core->Uniform4d(location, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_0_Core->Uniform3d(location, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform2d(GLint location, GLdouble x, GLdouble y)
+{
+ d_4_0_Core->Uniform2d(location, x, y);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glUniform1d(GLint location, GLdouble x)
+{
+ d_4_0_Core->Uniform1d(location, x);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawElementsIndirect(mode, type, indirect);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glDrawArraysIndirect(GLenum mode, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawArraysIndirect(mode, indirect);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ d_4_0_Core->BlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBlendFunci(GLuint buf, GLenum src, GLenum dst)
+{
+ d_4_0_Core->BlendFunci(buf, src, dst);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ d_4_0_Core->BlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glBlendEquationi(GLuint buf, GLenum mode)
+{
+ d_4_0_Core->BlendEquationi(buf, mode);
+}
+
+inline void QOpenGLFunctions_4_0_Core::glMinSampleShading(GLfloat value)
+{
+ d_4_0_Core->MinSampleShading(value);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_4_1_compatibility.cpp b/src/gui/opengl/qopenglfunctions_4_1_compatibility.cpp
new file mode 100644
index 0000000000..27c90adc5a
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_1_compatibility.cpp
@@ -0,0 +1,389 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_4_1_compatibility.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_4_1_Compatibility
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_4_1_Compatibility class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_4_1_Compatibility::QOpenGLFunctions_4_1_Compatibility()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+ , d_3_2_Core(0)
+ , d_3_3_Core(0)
+ , d_4_0_Core(0)
+ , d_4_1_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+ , d_1_3_Deprecated(0)
+ , d_1_4_Deprecated(0)
+ , d_2_0_Deprecated(0)
+ , d_3_0_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_4_1_Compatibility::~QOpenGLFunctions_4_1_Compatibility()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+ if (d_3_2_Core && !d_3_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_2_Core->context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ delete d_3_2_Core;
+ }
+ if (d_3_3_Core && !d_3_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_3_Core->context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ delete d_3_3_Core;
+ }
+ if (d_4_0_Core && !d_4_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_0_Core->context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ delete d_4_0_Core;
+ }
+ if (d_4_1_Core && !d_4_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_1_Core->context, QOpenGLFunctions_4_1_CoreBackend::versionStatus());
+ delete d_4_1_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+ if (d_1_3_Deprecated && !d_1_3_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Deprecated->context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ delete d_1_3_Deprecated;
+ }
+ if (d_1_4_Deprecated && !d_1_4_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Deprecated->context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ delete d_1_4_Deprecated;
+ }
+ if (d_2_0_Deprecated && !d_2_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Deprecated->context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ delete d_2_0_Deprecated;
+ }
+ if (d_3_0_Deprecated && !d_3_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Deprecated->context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ delete d_3_0_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_4_1_Compatibility::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_4_1_Compatibility::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus(), d);
+ }
+ d_3_2_Core = static_cast<QOpenGLFunctions_3_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus(), d);
+ }
+ d_3_3_Core = static_cast<QOpenGLFunctions_3_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus(), d);
+ }
+ d_4_0_Core = static_cast<QOpenGLFunctions_4_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_1_CoreBackend::versionStatus(), d);
+ }
+ d_4_1_Core = static_cast<QOpenGLFunctions_4_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_4_Deprecated = static_cast<QOpenGLFunctions_1_4_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_2_0_Deprecated = static_cast<QOpenGLFunctions_2_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_3_0_Deprecated = static_cast<QOpenGLFunctions_3_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_4_1_Compatibility::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(4, 1))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_4_1_Compatibility::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(4, 1);
+ v.setProfile(QSurfaceFormat::CompatibilityProfile);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_4_1_compatibility.h b/src/gui/opengl/qopenglfunctions_4_1_compatibility.h
new file mode 100644
index 0000000000..e343d2cba9
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_1_compatibility.h
@@ -0,0 +1,5557 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_4_1_COMPATIBILITY_H
+#define QOPENGLVERSIONFUNCTIONS_4_1_COMPATIBILITY_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_4_1_Compatibility : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_4_1_Compatibility();
+ ~QOpenGLFunctions_4_1_Compatibility();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+ // OpenGL 3.2 core functions
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+ void glProvokingVertex(GLenum mode);
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params);
+ void glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data);
+
+ // OpenGL 3.3 core functions
+ void glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glSecondaryColorP3uiv(GLenum type, const GLuint *color);
+ void glSecondaryColorP3ui(GLenum type, GLuint color);
+ void glColorP4uiv(GLenum type, const GLuint *color);
+ void glColorP4ui(GLenum type, GLuint color);
+ void glColorP3uiv(GLenum type, const GLuint *color);
+ void glColorP3ui(GLenum type, GLuint color);
+ void glNormalP3uiv(GLenum type, const GLuint *coords);
+ void glNormalP3ui(GLenum type, GLuint coords);
+ void glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords);
+ void glTexCoordP4uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP4ui(GLenum type, GLuint coords);
+ void glTexCoordP3uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP3ui(GLenum type, GLuint coords);
+ void glTexCoordP2uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP2ui(GLenum type, GLuint coords);
+ void glTexCoordP1uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP1ui(GLenum type, GLuint coords);
+ void glVertexP4uiv(GLenum type, const GLuint *value);
+ void glVertexP4ui(GLenum type, GLuint value);
+ void glVertexP3uiv(GLenum type, const GLuint *value);
+ void glVertexP3ui(GLenum type, GLuint value);
+ void glVertexP2uiv(GLenum type, const GLuint *value);
+ void glVertexP2ui(GLenum type, GLuint value);
+ void glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params);
+ void glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params);
+ void glQueryCounter(GLuint id, GLenum target);
+ void glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params);
+ void glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params);
+ void glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params);
+ void glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params);
+ void glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param);
+ void glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param);
+ void glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param);
+ void glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameteri(GLuint sampler, GLenum pname, GLint param);
+ void glBindSampler(GLuint unit, GLuint sampler);
+ GLboolean glIsSampler(GLuint sampler);
+ void glDeleteSamplers(GLsizei count, const GLuint *samplers);
+ void glGenSamplers(GLsizei count, GLuint *samplers);
+ GLint glGetFragDataIndex(GLuint program, const GLchar *name);
+ void glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+ void glVertexAttribDivisor(GLuint index, GLuint divisor);
+
+ // OpenGL 4.0 core functions
+ void glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void glEndQueryIndexed(GLenum target, GLuint index);
+ void glBeginQueryIndexed(GLenum target, GLuint index, GLuint id);
+ void glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream);
+ void glDrawTransformFeedback(GLenum mode, GLuint id);
+ void glResumeTransformFeedback();
+ void glPauseTransformFeedback();
+ GLboolean glIsTransformFeedback(GLuint id);
+ void glGenTransformFeedbacks(GLsizei n, GLuint *ids);
+ void glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids);
+ void glBindTransformFeedback(GLenum target, GLuint id);
+ void glPatchParameterfv(GLenum pname, const GLfloat *values);
+ void glPatchParameteri(GLenum pname, GLint value);
+ void glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values);
+ void glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params);
+ void glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices);
+ void glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
+ GLuint glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name);
+ GLint glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name);
+ void glGetUniformdv(GLuint program, GLint location, GLdouble *params);
+ void glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniform4dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform3dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform2dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform1dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void glUniform2d(GLint location, GLdouble x, GLdouble y);
+ void glUniform1d(GLint location, GLdouble x);
+ void glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect);
+ void glDrawArraysIndirect(GLenum mode, const GLvoid *indirect);
+ void glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void glBlendFunci(GLuint buf, GLenum src, GLenum dst);
+ void glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void glBlendEquationi(GLuint buf, GLenum mode);
+ void glMinSampleShading(GLfloat value);
+
+ // OpenGL 4.1 core functions
+ void glGetDoublei_v(GLenum target, GLuint index, GLdouble *data);
+ void glGetFloati_v(GLenum target, GLuint index, GLfloat *data);
+ void glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f);
+ void glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v);
+ void glScissorIndexedv(GLuint index, const GLint *v);
+ void glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+ void glScissorArrayv(GLuint first, GLsizei count, const GLint *v);
+ void glViewportIndexedfv(GLuint index, const GLfloat *v);
+ void glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+ void glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v);
+ void glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params);
+ void glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glVertexAttribL4dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL3dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL2dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL1dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttribL1d(GLuint index, GLdouble x);
+ void glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glValidateProgramPipeline(GLuint pipeline);
+ void glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+ void glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+ void glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+ void glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1);
+ void glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1);
+ void glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1);
+ void glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1);
+ void glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform1ui(GLuint program, GLint location, GLuint v0);
+ void glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform1d(GLuint program, GLint location, GLdouble v0);
+ void glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform1f(GLuint program, GLint location, GLfloat v0);
+ void glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform1i(GLuint program, GLint location, GLint v0);
+ void glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params);
+ GLboolean glIsProgramPipeline(GLuint pipeline);
+ void glGenProgramPipelines(GLsizei n, GLuint *pipelines);
+ void glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines);
+ void glBindProgramPipeline(GLuint pipeline);
+ GLuint glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings);
+ void glActiveShaderProgram(GLuint pipeline, GLuint program);
+ void glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program);
+ void glProgramParameteri(GLuint program, GLenum pname, GLint value);
+ void glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length);
+ void glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+ void glClearDepthf(GLfloat dd);
+ void glDepthRangef(GLfloat n, GLfloat f);
+ void glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision);
+ void glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length);
+ void glReleaseShaderCompiler();
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+ // OpenGL 1.3 deprecated functions
+ void glMultTransposeMatrixd(const GLdouble *m);
+ void glMultTransposeMatrixf(const GLfloat *m);
+ void glLoadTransposeMatrixd(const GLdouble *m);
+ void glLoadTransposeMatrixf(const GLfloat *m);
+ void glMultiTexCoord4sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4iv(GLenum target, const GLint *v);
+ void glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3iv(GLenum target, const GLint *v);
+ void glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord2s(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2iv(GLenum target, const GLint *v);
+ void glMultiTexCoord2i(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord1s(GLenum target, GLshort s);
+ void glMultiTexCoord1iv(GLenum target, const GLint *v);
+ void glMultiTexCoord1i(GLenum target, GLint s);
+ void glMultiTexCoord1fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1f(GLenum target, GLfloat s);
+ void glMultiTexCoord1dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1d(GLenum target, GLdouble s);
+ void glClientActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 deprecated functions
+ void glWindowPos3sv(const GLshort *v);
+ void glWindowPos3s(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3iv(const GLint *v);
+ void glWindowPos3i(GLint x, GLint y, GLint z);
+ void glWindowPos3fv(const GLfloat *v);
+ void glWindowPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dv(const GLdouble *v);
+ void glWindowPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2sv(const GLshort *v);
+ void glWindowPos2s(GLshort x, GLshort y);
+ void glWindowPos2iv(const GLint *v);
+ void glWindowPos2i(GLint x, GLint y);
+ void glWindowPos2fv(const GLfloat *v);
+ void glWindowPos2f(GLfloat x, GLfloat y);
+ void glWindowPos2dv(const GLdouble *v);
+ void glWindowPos2d(GLdouble x, GLdouble y);
+ void glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glSecondaryColor3usv(const GLushort *v);
+ void glSecondaryColor3us(GLushort red, GLushort green, GLushort blue);
+ void glSecondaryColor3uiv(const GLuint *v);
+ void glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glSecondaryColor3ubv(const GLubyte *v);
+ void glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glSecondaryColor3sv(const GLshort *v);
+ void glSecondaryColor3s(GLshort red, GLshort green, GLshort blue);
+ void glSecondaryColor3iv(const GLint *v);
+ void glSecondaryColor3i(GLint red, GLint green, GLint blue);
+ void glSecondaryColor3fv(const GLfloat *v);
+ void glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glSecondaryColor3dv(const GLdouble *v);
+ void glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glSecondaryColor3bv(const GLbyte *v);
+ void glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glFogCoorddv(const GLdouble *coord);
+ void glFogCoordd(GLdouble coord);
+ void glFogCoordfv(const GLfloat *coord);
+ void glFogCoordf(GLfloat coord);
+
+ // OpenGL 1.5 deprecated functions
+
+ // OpenGL 2.0 deprecated functions
+ void glVertexAttrib4usv(GLuint index, const GLushort *v);
+ void glVertexAttrib4uiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4sv(GLuint index, const GLshort *v);
+ void glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertexAttrib4iv(GLuint index, const GLint *v);
+ void glVertexAttrib4fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexAttrib4dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttrib4bv(GLuint index, const GLbyte *v);
+ void glVertexAttrib4Nusv(GLuint index, const GLushort *v);
+ void glVertexAttrib4Nuiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4Nubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void glVertexAttrib4Nsv(GLuint index, const GLshort *v);
+ void glVertexAttrib4Niv(GLuint index, const GLint *v);
+ void glVertexAttrib4Nbv(GLuint index, const GLbyte *v);
+ void glVertexAttrib3sv(GLuint index, const GLshort *v);
+ void glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z);
+ void glVertexAttrib3fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexAttrib3dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttrib2sv(GLuint index, const GLshort *v);
+ void glVertexAttrib2s(GLuint index, GLshort x, GLshort y);
+ void glVertexAttrib2fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y);
+ void glVertexAttrib2dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttrib1sv(GLuint index, const GLshort *v);
+ void glVertexAttrib1s(GLuint index, GLshort x);
+ void glVertexAttrib1fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib1f(GLuint index, GLfloat x);
+ void glVertexAttrib1dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib1d(GLuint index, GLdouble x);
+
+ // OpenGL 2.1 deprecated functions
+
+ // OpenGL 3.0 deprecated functions
+ void glVertexAttribI4usv(GLuint index, const GLushort *v);
+ void glVertexAttribI4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttribI4sv(GLuint index, const GLshort *v);
+ void glVertexAttribI4bv(GLuint index, const GLbyte *v);
+ void glVertexAttribI4uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI3uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI2uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI1uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI4iv(GLuint index, const GLint *v);
+ void glVertexAttribI3iv(GLuint index, const GLint *v);
+ void glVertexAttribI2iv(GLuint index, const GLint *v);
+ void glVertexAttribI1iv(GLuint index, const GLint *v);
+ void glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z);
+ void glVertexAttribI2ui(GLuint index, GLuint x, GLuint y);
+ void glVertexAttribI1ui(GLuint index, GLuint x);
+ void glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z);
+ void glVertexAttribI2i(GLuint index, GLint x, GLint y);
+ void glVertexAttribI1i(GLuint index, GLint x);
+
+ // OpenGL 3.1 deprecated functions
+
+ // OpenGL 3.2 deprecated functions
+
+ // OpenGL 3.3 deprecated functions
+
+ // OpenGL 4.0 deprecated functions
+
+ // OpenGL 4.1 deprecated functions
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+ QOpenGLFunctions_3_2_CoreBackend* d_3_2_Core;
+ QOpenGLFunctions_3_3_CoreBackend* d_3_3_Core;
+ QOpenGLFunctions_4_0_CoreBackend* d_4_0_Core;
+ QOpenGLFunctions_4_1_CoreBackend* d_4_1_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+ QOpenGLFunctions_1_3_DeprecatedBackend* d_1_3_Deprecated;
+ QOpenGLFunctions_1_4_DeprecatedBackend* d_1_4_Deprecated;
+ QOpenGLFunctions_2_0_DeprecatedBackend* d_2_0_Deprecated;
+ QOpenGLFunctions_3_0_DeprecatedBackend* d_3_0_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_1_Compatibility::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_4_1_Compatibility::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_4_1_Compatibility::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_4_1_Compatibility::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_4_1_Compatibility::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_4_1_Compatibility::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_4_1_Compatibility::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_4_1_Compatibility::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_4_1_Compatibility::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_1_Compatibility::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_4_1_Compatibility::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_4_1_Compatibility::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+// OpenGL 3.2 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ d_3_2_Core->SampleMaski(index, mask);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ d_3_2_Core->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ d_3_2_Core->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ d_3_2_Core->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLFunctions_4_1_Compatibility::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ return d_3_2_Core->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteSync(GLsync sync)
+{
+ d_3_2_Core->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsSync(GLsync sync)
+{
+ return d_3_2_Core->IsSync(sync);
+}
+
+inline GLsync QOpenGLFunctions_4_1_Compatibility::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ return d_3_2_Core->FenceSync(condition, flags);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProvokingVertex(GLenum mode)
+{
+ d_3_2_Core->ProvokingVertex(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ d_3_2_Core->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ d_3_2_Core->FramebufferTexture(target, attachment, texture, level);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetBufferParameteri64v(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data)
+{
+ d_3_2_Core->GetInteger64i_v(target, index, data);
+}
+
+
+// OpenGL 3.3 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP4uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP4ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP3uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP3ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP2uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP2ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP1uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP1ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->SecondaryColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->SecondaryColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColorP4uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP4uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColorP4ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP4ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormalP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->NormalP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormalP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->NormalP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP4uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP4ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP3uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP3ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP2uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP2ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP1uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP1ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoordP4uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP4uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoordP4ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP4ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoordP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoordP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoordP2uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP2uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoordP2ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP2ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoordP1uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP1uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoordP1ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP1ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexP4uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP4uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexP4ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP4ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexP3uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP3uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexP3ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP3ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexP2uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP2uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexP2ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP2ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params)
+{
+ d_3_3_Core->GetQueryObjectui64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params)
+{
+ d_3_3_Core->GetQueryObjecti64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glQueryCounter(GLuint id, GLenum target)
+{
+ d_3_3_Core->QueryCounter(id, target);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params)
+{
+ d_3_3_Core->GetSamplerParameterIuiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params)
+{
+ d_3_3_Core->GetSamplerParameterfv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameterIiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameteriv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ d_3_3_Core->SamplerParameterIuiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameterIiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param)
+{
+ d_3_3_Core->SamplerParameterfv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param)
+{
+ d_3_3_Core->SamplerParameterf(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameteriv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSamplerParameteri(GLuint sampler, GLenum pname, GLint param)
+{
+ d_3_3_Core->SamplerParameteri(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindSampler(GLuint unit, GLuint sampler)
+{
+ d_3_3_Core->BindSampler(unit, sampler);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsSampler(GLuint sampler)
+{
+ return d_3_3_Core->IsSampler(sampler);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteSamplers(GLsizei count, const GLuint *samplers)
+{
+ d_3_3_Core->DeleteSamplers(count, samplers);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGenSamplers(GLsizei count, GLuint *samplers)
+{
+ d_3_3_Core->GenSamplers(count, samplers);
+}
+
+inline GLint QOpenGLFunctions_4_1_Compatibility::glGetFragDataIndex(GLuint program, const GLchar *name)
+{
+ return d_3_3_Core->GetFragDataIndex(program, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name)
+{
+ d_3_3_Core->BindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribDivisor(GLuint index, GLuint divisor)
+{
+ d_3_3_Core->VertexAttribDivisor(index, divisor);
+}
+
+
+// OpenGL 4.0 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params)
+{
+ d_4_0_Core->GetQueryIndexediv(target, index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEndQueryIndexed(GLenum target, GLuint index)
+{
+ d_4_0_Core->EndQueryIndexed(target, index);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBeginQueryIndexed(GLenum target, GLuint index, GLuint id)
+{
+ d_4_0_Core->BeginQueryIndexed(target, index, id);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream)
+{
+ d_4_0_Core->DrawTransformFeedbackStream(mode, id, stream);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawTransformFeedback(GLenum mode, GLuint id)
+{
+ d_4_0_Core->DrawTransformFeedback(mode, id);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glResumeTransformFeedback()
+{
+ d_4_0_Core->ResumeTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPauseTransformFeedback()
+{
+ d_4_0_Core->PauseTransformFeedback();
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsTransformFeedback(GLuint id)
+{
+ return d_4_0_Core->IsTransformFeedback(id);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGenTransformFeedbacks(GLsizei n, GLuint *ids)
+{
+ d_4_0_Core->GenTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids)
+{
+ d_4_0_Core->DeleteTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindTransformFeedback(GLenum target, GLuint id)
+{
+ d_4_0_Core->BindTransformFeedback(target, id);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPatchParameterfv(GLenum pname, const GLfloat *values)
+{
+ d_4_0_Core->PatchParameterfv(pname, values);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPatchParameteri(GLenum pname, GLint value)
+{
+ d_4_0_Core->PatchParameteri(pname, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetProgramStageiv(program, shadertype, pname, values);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params)
+{
+ d_4_0_Core->GetUniformSubroutineuiv(shadertype, location, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices)
+{
+ d_4_0_Core->UniformSubroutinesuiv(shadertype, count, indices);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineUniformName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+inline GLuint QOpenGLFunctions_4_1_Compatibility::glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineIndex(program, shadertype, name);
+}
+
+inline GLint QOpenGLFunctions_4_1_Compatibility::glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineUniformLocation(program, shadertype, name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetUniformdv(GLuint program, GLint location, GLdouble *params)
+{
+ d_4_0_Core->GetUniformdv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform4dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform4dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform3dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform3dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform2dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform2dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform1dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform1dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_0_Core->Uniform4d(location, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_0_Core->Uniform3d(location, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform2d(GLint location, GLdouble x, GLdouble y)
+{
+ d_4_0_Core->Uniform2d(location, x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUniform1d(GLint location, GLdouble x)
+{
+ d_4_0_Core->Uniform1d(location, x);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawElementsIndirect(mode, type, indirect);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawArraysIndirect(GLenum mode, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawArraysIndirect(mode, indirect);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ d_4_0_Core->BlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBlendFunci(GLuint buf, GLenum src, GLenum dst)
+{
+ d_4_0_Core->BlendFunci(buf, src, dst);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ d_4_0_Core->BlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBlendEquationi(GLuint buf, GLenum mode)
+{
+ d_4_0_Core->BlendEquationi(buf, mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMinSampleShading(GLfloat value)
+{
+ d_4_0_Core->MinSampleShading(value);
+}
+
+
+// OpenGL 4.1 core functions
+inline void QOpenGLFunctions_4_1_Compatibility::glGetDoublei_v(GLenum target, GLuint index, GLdouble *data)
+{
+ d_4_1_Core->GetDoublei_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetFloati_v(GLenum target, GLuint index, GLfloat *data)
+{
+ d_4_1_Core->GetFloati_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f)
+{
+ d_4_1_Core->DepthRangeIndexed(index, n, f);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v)
+{
+ d_4_1_Core->DepthRangeArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glScissorIndexedv(GLuint index, const GLint *v)
+{
+ d_4_1_Core->ScissorIndexedv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ d_4_1_Core->ScissorIndexed(index, left, bottom, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glScissorArrayv(GLuint first, GLsizei count, const GLint *v)
+{
+ d_4_1_Core->ScissorArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glViewportIndexedfv(GLuint index, const GLfloat *v)
+{
+ d_4_1_Core->ViewportIndexedfv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ d_4_1_Core->ViewportIndexedf(index, x, y, w, h);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v)
+{
+ d_4_1_Core->ViewportArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_4_1_Core->GetVertexAttribLdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_4_1_Core->VertexAttribLPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribL4dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL4dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribL3dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL3dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribL2dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL2dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribL1dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL1dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_1_Core->VertexAttribL4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_1_Core->VertexAttribL3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_4_1_Core->VertexAttribL2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribL1d(GLuint index, GLdouble x)
+{
+ d_4_1_Core->VertexAttribL1d(index, x);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_4_1_Core->GetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glValidateProgramPipeline(GLuint pipeline)
+{
+ d_4_1_Core->ValidateProgramPipeline(pipeline);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform4uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_4_1_Core->ProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform4dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ d_4_1_Core->ProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform4fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_4_1_Core->ProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform4iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_4_1_Core->ProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform3uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_4_1_Core->ProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform3dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ d_4_1_Core->ProgramUniform3d(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform3fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_4_1_Core->ProgramUniform3f(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform3iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_4_1_Core->ProgramUniform3i(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform2uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ d_4_1_Core->ProgramUniform2ui(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform2dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ d_4_1_Core->ProgramUniform2d(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform2fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ d_4_1_Core->ProgramUniform2f(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform2iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1)
+{
+ d_4_1_Core->ProgramUniform2i(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform1uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform1ui(GLuint program, GLint location, GLuint v0)
+{
+ d_4_1_Core->ProgramUniform1ui(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform1dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform1d(GLuint program, GLint location, GLdouble v0)
+{
+ d_4_1_Core->ProgramUniform1d(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform1fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform1f(GLuint program, GLint location, GLfloat v0)
+{
+ d_4_1_Core->ProgramUniform1f(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform1iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramUniform1i(GLuint program, GLint location, GLint v0)
+{
+ d_4_1_Core->ProgramUniform1i(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params)
+{
+ d_4_1_Core->GetProgramPipelineiv(pipeline, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsProgramPipeline(GLuint pipeline)
+{
+ return d_4_1_Core->IsProgramPipeline(pipeline);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGenProgramPipelines(GLsizei n, GLuint *pipelines)
+{
+ d_4_1_Core->GenProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines)
+{
+ d_4_1_Core->DeleteProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBindProgramPipeline(GLuint pipeline)
+{
+ d_4_1_Core->BindProgramPipeline(pipeline);
+}
+
+inline GLuint QOpenGLFunctions_4_1_Compatibility::glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings)
+{
+ return d_4_1_Core->CreateShaderProgramv(type, count, strings);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glActiveShaderProgram(GLuint pipeline, GLuint program)
+{
+ d_4_1_Core->ActiveShaderProgram(pipeline, program);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ d_4_1_Core->UseProgramStages(pipeline, stages, program);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramParameteri(GLuint program, GLenum pname, GLint value)
+{
+ d_4_1_Core->ProgramParameteri(program, pname, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length)
+{
+ d_4_1_Core->ProgramBinary(program, binaryFormat, binary, length);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary)
+{
+ d_4_1_Core->GetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClearDepthf(GLfloat dd)
+{
+ d_4_1_Core->ClearDepthf(dd);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDepthRangef(GLfloat n, GLfloat f)
+{
+ d_4_1_Core->DepthRangef(n, f);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision)
+{
+ d_4_1_Core->GetShaderPrecisionFormat(shadertype, precisiontype, range, precision);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length)
+{
+ d_4_1_Core->ShaderBinary(count, shaders, binaryformat, binary, length);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glReleaseShaderCompiler()
+{
+ d_4_1_Core->ReleaseShaderCompiler();
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_4_1_Compatibility::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_4_1_Compatibility::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_4_1_Compatibility::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_4_1_Compatibility::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Compatibility::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_4_1_Compatibility::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+// OpenGL 1.3 deprecated functions
+inline void QOpenGLFunctions_4_1_Compatibility::glMultTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLoadTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glLoadTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord4sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_3_Deprecated->MultiTexCoord4s(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord4iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_3_Deprecated->MultiTexCoord4i(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord4fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_3_Deprecated->MultiTexCoord4f(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord4dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_3_Deprecated->MultiTexCoord4d(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord3sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ d_1_3_Deprecated->MultiTexCoord3s(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord3iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r)
+{
+ d_1_3_Deprecated->MultiTexCoord3i(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord3fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_3_Deprecated->MultiTexCoord3f(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord3dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_3_Deprecated->MultiTexCoord3d(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord2sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord2s(GLenum target, GLshort s, GLshort t)
+{
+ d_1_3_Deprecated->MultiTexCoord2s(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord2iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord2i(GLenum target, GLint s, GLint t)
+{
+ d_1_3_Deprecated->MultiTexCoord2i(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord2fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t)
+{
+ d_1_3_Deprecated->MultiTexCoord2f(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord2dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t)
+{
+ d_1_3_Deprecated->MultiTexCoord2d(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord1sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord1s(GLenum target, GLshort s)
+{
+ d_1_3_Deprecated->MultiTexCoord1s(target, s);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord1iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord1i(GLenum target, GLint s)
+{
+ d_1_3_Deprecated->MultiTexCoord1i(target, s);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord1fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord1f(GLenum target, GLfloat s)
+{
+ d_1_3_Deprecated->MultiTexCoord1f(target, s);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord1dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glMultiTexCoord1d(GLenum target, GLdouble s)
+{
+ d_1_3_Deprecated->MultiTexCoord1d(target, s);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glClientActiveTexture(GLenum texture)
+{
+ d_1_3_Deprecated->ClientActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 deprecated functions
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos3sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_4_Deprecated->WindowPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos3iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos3iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_4_Deprecated->WindowPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos3fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_4_Deprecated->WindowPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos3dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_4_Deprecated->WindowPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos2sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos2sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos2s(GLshort x, GLshort y)
+{
+ d_1_4_Deprecated->WindowPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos2iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos2iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos2i(GLint x, GLint y)
+{
+ d_1_4_Deprecated->WindowPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos2fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos2fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos2f(GLfloat x, GLfloat y)
+{
+ d_1_4_Deprecated->WindowPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos2dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos2dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glWindowPos2d(GLdouble x, GLdouble y)
+{
+ d_1_4_Deprecated->WindowPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->SecondaryColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3usv(const GLushort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3usv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3uiv(const GLuint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3uiv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3ubv(const GLubyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3ubv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3sv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3iv(const GLint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3iv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->SecondaryColor3fv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_4_Deprecated->SecondaryColor3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->SecondaryColor3dv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_4_Deprecated->SecondaryColor3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3bv(const GLbyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3bv(v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->FogCoordPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFogCoorddv(const GLdouble *coord)
+{
+ d_1_4_Deprecated->FogCoorddv(coord);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFogCoordd(GLdouble coord)
+{
+ d_1_4_Deprecated->FogCoordd(coord);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFogCoordfv(const GLfloat *coord)
+{
+ d_1_4_Deprecated->FogCoordfv(coord);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glFogCoordf(GLfloat coord)
+{
+ d_1_4_Deprecated->FogCoordf(coord);
+}
+
+
+// OpenGL 1.5 deprecated functions
+
+// OpenGL 2.0 deprecated functions
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4usv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4usv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4uiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4ubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_2_0_Deprecated->VertexAttrib4s(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4iv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib4fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_2_0_Deprecated->VertexAttrib4f(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib4dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_2_0_Deprecated->VertexAttrib4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4bv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4bv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4Nusv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nusv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4Nuiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nuiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4Nubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nubv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ d_2_0_Deprecated->VertexAttrib4Nub(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4Nsv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nsv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4Niv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Niv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib4Nbv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nbv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib3sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib3sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ d_2_0_Deprecated->VertexAttrib3s(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib3fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib3fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_2_0_Deprecated->VertexAttrib3f(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib3dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib3dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_2_0_Deprecated->VertexAttrib3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib2sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib2sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib2s(GLuint index, GLshort x, GLshort y)
+{
+ d_2_0_Deprecated->VertexAttrib2s(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib2fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib2fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y)
+{
+ d_2_0_Deprecated->VertexAttrib2f(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib2dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib2dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_2_0_Deprecated->VertexAttrib2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib1sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib1sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib1s(GLuint index, GLshort x)
+{
+ d_2_0_Deprecated->VertexAttrib1s(index, x);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib1fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib1fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib1f(GLuint index, GLfloat x)
+{
+ d_2_0_Deprecated->VertexAttrib1f(index, x);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib1dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib1dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttrib1d(GLuint index, GLdouble x)
+{
+ d_2_0_Deprecated->VertexAttrib1d(index, x);
+}
+
+
+// OpenGL 2.1 deprecated functions
+
+// OpenGL 3.0 deprecated functions
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI4usv(GLuint index, const GLushort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4usv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI4ubv(GLuint index, const GLubyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI4sv(GLuint index, const GLshort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI4bv(GLuint index, const GLbyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4bv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI4uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI3uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI2uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI1uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI4iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI3iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI2iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI1iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ d_3_0_Deprecated->VertexAttribI4ui(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ d_3_0_Deprecated->VertexAttribI3ui(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI2ui(GLuint index, GLuint x, GLuint y)
+{
+ d_3_0_Deprecated->VertexAttribI2ui(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI1ui(GLuint index, GLuint x)
+{
+ d_3_0_Deprecated->VertexAttribI1ui(index, x);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ d_3_0_Deprecated->VertexAttribI4i(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z)
+{
+ d_3_0_Deprecated->VertexAttribI3i(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI2i(GLuint index, GLint x, GLint y)
+{
+ d_3_0_Deprecated->VertexAttribI2i(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Compatibility::glVertexAttribI1i(GLuint index, GLint x)
+{
+ d_3_0_Deprecated->VertexAttribI1i(index, x);
+}
+
+
+// OpenGL 3.1 deprecated functions
+
+// OpenGL 3.2 deprecated functions
+
+// OpenGL 3.3 deprecated functions
+
+// OpenGL 4.0 deprecated functions
+
+// OpenGL 4.1 deprecated functions
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_4_1_core.cpp b/src/gui/opengl/qopenglfunctions_4_1_core.cpp
new file mode 100644
index 0000000000..b36cb0de94
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_1_core.cpp
@@ -0,0 +1,295 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_4_1_core.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_4_1_Core
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_4_1_Core class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_4_1_Core::QOpenGLFunctions_4_1_Core()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+ , d_3_2_Core(0)
+ , d_3_3_Core(0)
+ , d_4_0_Core(0)
+ , d_4_1_Core(0)
+{
+}
+
+QOpenGLFunctions_4_1_Core::~QOpenGLFunctions_4_1_Core()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+ if (d_3_2_Core && !d_3_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_2_Core->context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ delete d_3_2_Core;
+ }
+ if (d_3_3_Core && !d_3_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_3_Core->context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ delete d_3_3_Core;
+ }
+ if (d_4_0_Core && !d_4_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_0_Core->context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ delete d_4_0_Core;
+ }
+ if (d_4_1_Core && !d_4_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_1_Core->context, QOpenGLFunctions_4_1_CoreBackend::versionStatus());
+ delete d_4_1_Core;
+ }
+}
+
+bool QOpenGLFunctions_4_1_Core::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_4_1_Core::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus(), d);
+ }
+ d_3_2_Core = static_cast<QOpenGLFunctions_3_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus(), d);
+ }
+ d_3_3_Core = static_cast<QOpenGLFunctions_3_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus(), d);
+ }
+ d_4_0_Core = static_cast<QOpenGLFunctions_4_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_1_CoreBackend::versionStatus(), d);
+ }
+ d_4_1_Core = static_cast<QOpenGLFunctions_4_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_4_1_Core::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(4, 1))
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_4_1_Core::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(4, 1);
+ v.setProfile(QSurfaceFormat::CoreProfile);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_4_1_core.h b/src/gui/opengl/qopenglfunctions_4_1_core.h
new file mode 100644
index 0000000000..851d80bf36
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_1_core.h
@@ -0,0 +1,2884 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_4_1_CORE_H
+#define QOPENGLVERSIONFUNCTIONS_4_1_CORE_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_4_1_Core : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_4_1_Core();
+ ~QOpenGLFunctions_4_1_Core();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+ // OpenGL 3.2 core functions
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+ void glProvokingVertex(GLenum mode);
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params);
+ void glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data);
+
+ // OpenGL 3.3 core functions
+ void glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glSecondaryColorP3uiv(GLenum type, const GLuint *color);
+ void glSecondaryColorP3ui(GLenum type, GLuint color);
+ void glColorP4uiv(GLenum type, const GLuint *color);
+ void glColorP4ui(GLenum type, GLuint color);
+ void glColorP3uiv(GLenum type, const GLuint *color);
+ void glColorP3ui(GLenum type, GLuint color);
+ void glNormalP3uiv(GLenum type, const GLuint *coords);
+ void glNormalP3ui(GLenum type, GLuint coords);
+ void glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords);
+ void glTexCoordP4uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP4ui(GLenum type, GLuint coords);
+ void glTexCoordP3uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP3ui(GLenum type, GLuint coords);
+ void glTexCoordP2uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP2ui(GLenum type, GLuint coords);
+ void glTexCoordP1uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP1ui(GLenum type, GLuint coords);
+ void glVertexP4uiv(GLenum type, const GLuint *value);
+ void glVertexP4ui(GLenum type, GLuint value);
+ void glVertexP3uiv(GLenum type, const GLuint *value);
+ void glVertexP3ui(GLenum type, GLuint value);
+ void glVertexP2uiv(GLenum type, const GLuint *value);
+ void glVertexP2ui(GLenum type, GLuint value);
+ void glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params);
+ void glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params);
+ void glQueryCounter(GLuint id, GLenum target);
+ void glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params);
+ void glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params);
+ void glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params);
+ void glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params);
+ void glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param);
+ void glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param);
+ void glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param);
+ void glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameteri(GLuint sampler, GLenum pname, GLint param);
+ void glBindSampler(GLuint unit, GLuint sampler);
+ GLboolean glIsSampler(GLuint sampler);
+ void glDeleteSamplers(GLsizei count, const GLuint *samplers);
+ void glGenSamplers(GLsizei count, GLuint *samplers);
+ GLint glGetFragDataIndex(GLuint program, const GLchar *name);
+ void glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+ void glVertexAttribDivisor(GLuint index, GLuint divisor);
+
+ // OpenGL 4.0 core functions
+ void glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void glEndQueryIndexed(GLenum target, GLuint index);
+ void glBeginQueryIndexed(GLenum target, GLuint index, GLuint id);
+ void glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream);
+ void glDrawTransformFeedback(GLenum mode, GLuint id);
+ void glResumeTransformFeedback();
+ void glPauseTransformFeedback();
+ GLboolean glIsTransformFeedback(GLuint id);
+ void glGenTransformFeedbacks(GLsizei n, GLuint *ids);
+ void glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids);
+ void glBindTransformFeedback(GLenum target, GLuint id);
+ void glPatchParameterfv(GLenum pname, const GLfloat *values);
+ void glPatchParameteri(GLenum pname, GLint value);
+ void glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values);
+ void glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params);
+ void glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices);
+ void glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
+ GLuint glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name);
+ GLint glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name);
+ void glGetUniformdv(GLuint program, GLint location, GLdouble *params);
+ void glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniform4dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform3dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform2dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform1dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void glUniform2d(GLint location, GLdouble x, GLdouble y);
+ void glUniform1d(GLint location, GLdouble x);
+ void glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect);
+ void glDrawArraysIndirect(GLenum mode, const GLvoid *indirect);
+ void glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void glBlendFunci(GLuint buf, GLenum src, GLenum dst);
+ void glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void glBlendEquationi(GLuint buf, GLenum mode);
+ void glMinSampleShading(GLfloat value);
+
+ // OpenGL 4.1 core functions
+ void glGetDoublei_v(GLenum target, GLuint index, GLdouble *data);
+ void glGetFloati_v(GLenum target, GLuint index, GLfloat *data);
+ void glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f);
+ void glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v);
+ void glScissorIndexedv(GLuint index, const GLint *v);
+ void glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+ void glScissorArrayv(GLuint first, GLsizei count, const GLint *v);
+ void glViewportIndexedfv(GLuint index, const GLfloat *v);
+ void glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+ void glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v);
+ void glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params);
+ void glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glVertexAttribL4dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL3dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL2dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL1dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttribL1d(GLuint index, GLdouble x);
+ void glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glValidateProgramPipeline(GLuint pipeline);
+ void glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+ void glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+ void glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+ void glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1);
+ void glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1);
+ void glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1);
+ void glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1);
+ void glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform1ui(GLuint program, GLint location, GLuint v0);
+ void glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform1d(GLuint program, GLint location, GLdouble v0);
+ void glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform1f(GLuint program, GLint location, GLfloat v0);
+ void glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform1i(GLuint program, GLint location, GLint v0);
+ void glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params);
+ GLboolean glIsProgramPipeline(GLuint pipeline);
+ void glGenProgramPipelines(GLsizei n, GLuint *pipelines);
+ void glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines);
+ void glBindProgramPipeline(GLuint pipeline);
+ GLuint glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings);
+ void glActiveShaderProgram(GLuint pipeline, GLuint program);
+ void glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program);
+ void glProgramParameteri(GLuint program, GLenum pname, GLint value);
+ void glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length);
+ void glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+ void glClearDepthf(GLfloat dd);
+ void glDepthRangef(GLfloat n, GLfloat f);
+ void glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision);
+ void glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length);
+ void glReleaseShaderCompiler();
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+ QOpenGLFunctions_3_2_CoreBackend* d_3_2_Core;
+ QOpenGLFunctions_3_3_CoreBackend* d_3_3_Core;
+ QOpenGLFunctions_4_0_CoreBackend* d_4_0_Core;
+ QOpenGLFunctions_4_1_CoreBackend* d_4_1_Core;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_4_1_Core::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_1_Core::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_4_1_Core::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_4_1_Core::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_4_1_Core::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_4_1_Core::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_4_1_Core::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_4_1_Core::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_4_1_Core::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_4_1_Core::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_4_1_Core::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_4_1_Core::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_4_1_Core::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_4_1_Core::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_4_1_Core::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_4_1_Core::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_4_1_Core::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_4_1_Core::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_1_Core::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_4_1_Core::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_4_1_Core::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_4_1_Core::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+// OpenGL 3.2 core functions
+inline void QOpenGLFunctions_4_1_Core::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ d_3_2_Core->SampleMaski(index, mask);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ d_3_2_Core->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ d_3_2_Core->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ d_3_2_Core->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLFunctions_4_1_Core::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ return d_3_2_Core->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDeleteSync(GLsync sync)
+{
+ d_3_2_Core->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsSync(GLsync sync)
+{
+ return d_3_2_Core->IsSync(sync);
+}
+
+inline GLsync QOpenGLFunctions_4_1_Core::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ return d_3_2_Core->FenceSync(condition, flags);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProvokingVertex(GLenum mode)
+{
+ d_3_2_Core->ProvokingVertex(mode);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ d_3_2_Core->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ d_3_2_Core->FramebufferTexture(target, attachment, texture, level);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetBufferParameteri64v(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data)
+{
+ d_3_2_Core->GetInteger64i_v(target, index, data);
+}
+
+
+// OpenGL 3.3 core functions
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP4uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP4ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP3uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP3ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP2uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP2ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP1uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP1ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glSecondaryColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->SecondaryColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glSecondaryColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->SecondaryColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glColorP4uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP4uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glColorP4ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP4ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glNormalP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->NormalP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glNormalP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->NormalP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP4uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP4ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP3uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP3ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP2uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP2ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP1uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP1ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexCoordP4uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP4uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexCoordP4ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP4ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexCoordP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexCoordP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexCoordP2uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP2uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexCoordP2ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP2ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexCoordP1uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP1uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glTexCoordP1ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP1ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexP4uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP4uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexP4ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP4ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexP3uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP3uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexP3ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP3ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexP2uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP2uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexP2ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP2ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params)
+{
+ d_3_3_Core->GetQueryObjectui64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params)
+{
+ d_3_3_Core->GetQueryObjecti64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glQueryCounter(GLuint id, GLenum target)
+{
+ d_3_3_Core->QueryCounter(id, target);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params)
+{
+ d_3_3_Core->GetSamplerParameterIuiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params)
+{
+ d_3_3_Core->GetSamplerParameterfv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameterIiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameteriv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ d_3_3_Core->SamplerParameterIuiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameterIiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param)
+{
+ d_3_3_Core->SamplerParameterfv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param)
+{
+ d_3_3_Core->SamplerParameterf(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameteriv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glSamplerParameteri(GLuint sampler, GLenum pname, GLint param)
+{
+ d_3_3_Core->SamplerParameteri(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindSampler(GLuint unit, GLuint sampler)
+{
+ d_3_3_Core->BindSampler(unit, sampler);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsSampler(GLuint sampler)
+{
+ return d_3_3_Core->IsSampler(sampler);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDeleteSamplers(GLsizei count, const GLuint *samplers)
+{
+ d_3_3_Core->DeleteSamplers(count, samplers);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGenSamplers(GLsizei count, GLuint *samplers)
+{
+ d_3_3_Core->GenSamplers(count, samplers);
+}
+
+inline GLint QOpenGLFunctions_4_1_Core::glGetFragDataIndex(GLuint program, const GLchar *name)
+{
+ return d_3_3_Core->GetFragDataIndex(program, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name)
+{
+ d_3_3_Core->BindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribDivisor(GLuint index, GLuint divisor)
+{
+ d_3_3_Core->VertexAttribDivisor(index, divisor);
+}
+
+
+// OpenGL 4.0 core functions
+inline void QOpenGLFunctions_4_1_Core::glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params)
+{
+ d_4_0_Core->GetQueryIndexediv(target, index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glEndQueryIndexed(GLenum target, GLuint index)
+{
+ d_4_0_Core->EndQueryIndexed(target, index);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBeginQueryIndexed(GLenum target, GLuint index, GLuint id)
+{
+ d_4_0_Core->BeginQueryIndexed(target, index, id);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream)
+{
+ d_4_0_Core->DrawTransformFeedbackStream(mode, id, stream);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawTransformFeedback(GLenum mode, GLuint id)
+{
+ d_4_0_Core->DrawTransformFeedback(mode, id);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glResumeTransformFeedback()
+{
+ d_4_0_Core->ResumeTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_1_Core::glPauseTransformFeedback()
+{
+ d_4_0_Core->PauseTransformFeedback();
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsTransformFeedback(GLuint id)
+{
+ return d_4_0_Core->IsTransformFeedback(id);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGenTransformFeedbacks(GLsizei n, GLuint *ids)
+{
+ d_4_0_Core->GenTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids)
+{
+ d_4_0_Core->DeleteTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindTransformFeedback(GLenum target, GLuint id)
+{
+ d_4_0_Core->BindTransformFeedback(target, id);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glPatchParameterfv(GLenum pname, const GLfloat *values)
+{
+ d_4_0_Core->PatchParameterfv(pname, values);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glPatchParameteri(GLenum pname, GLint value)
+{
+ d_4_0_Core->PatchParameteri(pname, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetProgramStageiv(program, shadertype, pname, values);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params)
+{
+ d_4_0_Core->GetUniformSubroutineuiv(shadertype, location, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices)
+{
+ d_4_0_Core->UniformSubroutinesuiv(shadertype, count, indices);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineUniformName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+inline GLuint QOpenGLFunctions_4_1_Core::glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineIndex(program, shadertype, name);
+}
+
+inline GLint QOpenGLFunctions_4_1_Core::glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineUniformLocation(program, shadertype, name);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetUniformdv(GLuint program, GLint location, GLdouble *params)
+{
+ d_4_0_Core->GetUniformdv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform4dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform4dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform3dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform3dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform2dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform2dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform1dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform1dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_0_Core->Uniform4d(location, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_0_Core->Uniform3d(location, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform2d(GLint location, GLdouble x, GLdouble y)
+{
+ d_4_0_Core->Uniform2d(location, x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUniform1d(GLint location, GLdouble x)
+{
+ d_4_0_Core->Uniform1d(location, x);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawElementsIndirect(mode, type, indirect);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDrawArraysIndirect(GLenum mode, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawArraysIndirect(mode, indirect);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ d_4_0_Core->BlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBlendFunci(GLuint buf, GLenum src, GLenum dst)
+{
+ d_4_0_Core->BlendFunci(buf, src, dst);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ d_4_0_Core->BlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBlendEquationi(GLuint buf, GLenum mode)
+{
+ d_4_0_Core->BlendEquationi(buf, mode);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glMinSampleShading(GLfloat value)
+{
+ d_4_0_Core->MinSampleShading(value);
+}
+
+
+// OpenGL 4.1 core functions
+inline void QOpenGLFunctions_4_1_Core::glGetDoublei_v(GLenum target, GLuint index, GLdouble *data)
+{
+ d_4_1_Core->GetDoublei_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetFloati_v(GLenum target, GLuint index, GLfloat *data)
+{
+ d_4_1_Core->GetFloati_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f)
+{
+ d_4_1_Core->DepthRangeIndexed(index, n, f);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v)
+{
+ d_4_1_Core->DepthRangeArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glScissorIndexedv(GLuint index, const GLint *v)
+{
+ d_4_1_Core->ScissorIndexedv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ d_4_1_Core->ScissorIndexed(index, left, bottom, width, height);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glScissorArrayv(GLuint first, GLsizei count, const GLint *v)
+{
+ d_4_1_Core->ScissorArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glViewportIndexedfv(GLuint index, const GLfloat *v)
+{
+ d_4_1_Core->ViewportIndexedfv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ d_4_1_Core->ViewportIndexedf(index, x, y, w, h);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v)
+{
+ d_4_1_Core->ViewportArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_4_1_Core->GetVertexAttribLdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_4_1_Core->VertexAttribLPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribL4dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL4dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribL3dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL3dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribL2dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL2dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribL1dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL1dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_1_Core->VertexAttribL4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_1_Core->VertexAttribL3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_4_1_Core->VertexAttribL2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glVertexAttribL1d(GLuint index, GLdouble x)
+{
+ d_4_1_Core->VertexAttribL1d(index, x);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_4_1_Core->GetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glValidateProgramPipeline(GLuint pipeline)
+{
+ d_4_1_Core->ValidateProgramPipeline(pipeline);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform4uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_4_1_Core->ProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform4dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ d_4_1_Core->ProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform4fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_4_1_Core->ProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform4iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_4_1_Core->ProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform3uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_4_1_Core->ProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform3dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ d_4_1_Core->ProgramUniform3d(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform3fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_4_1_Core->ProgramUniform3f(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform3iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_4_1_Core->ProgramUniform3i(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform2uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ d_4_1_Core->ProgramUniform2ui(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform2dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ d_4_1_Core->ProgramUniform2d(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform2fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ d_4_1_Core->ProgramUniform2f(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform2iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1)
+{
+ d_4_1_Core->ProgramUniform2i(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform1uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform1ui(GLuint program, GLint location, GLuint v0)
+{
+ d_4_1_Core->ProgramUniform1ui(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform1dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform1d(GLuint program, GLint location, GLdouble v0)
+{
+ d_4_1_Core->ProgramUniform1d(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform1fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform1f(GLuint program, GLint location, GLfloat v0)
+{
+ d_4_1_Core->ProgramUniform1f(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform1iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramUniform1i(GLuint program, GLint location, GLint v0)
+{
+ d_4_1_Core->ProgramUniform1i(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params)
+{
+ d_4_1_Core->GetProgramPipelineiv(pipeline, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_1_Core::glIsProgramPipeline(GLuint pipeline)
+{
+ return d_4_1_Core->IsProgramPipeline(pipeline);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGenProgramPipelines(GLsizei n, GLuint *pipelines)
+{
+ d_4_1_Core->GenProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines)
+{
+ d_4_1_Core->DeleteProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glBindProgramPipeline(GLuint pipeline)
+{
+ d_4_1_Core->BindProgramPipeline(pipeline);
+}
+
+inline GLuint QOpenGLFunctions_4_1_Core::glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings)
+{
+ return d_4_1_Core->CreateShaderProgramv(type, count, strings);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glActiveShaderProgram(GLuint pipeline, GLuint program)
+{
+ d_4_1_Core->ActiveShaderProgram(pipeline, program);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ d_4_1_Core->UseProgramStages(pipeline, stages, program);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramParameteri(GLuint program, GLenum pname, GLint value)
+{
+ d_4_1_Core->ProgramParameteri(program, pname, value);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length)
+{
+ d_4_1_Core->ProgramBinary(program, binaryFormat, binary, length);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary)
+{
+ d_4_1_Core->GetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glClearDepthf(GLfloat dd)
+{
+ d_4_1_Core->ClearDepthf(dd);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glDepthRangef(GLfloat n, GLfloat f)
+{
+ d_4_1_Core->DepthRangef(n, f);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision)
+{
+ d_4_1_Core->GetShaderPrecisionFormat(shadertype, precisiontype, range, precision);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length)
+{
+ d_4_1_Core->ShaderBinary(count, shaders, binaryformat, binary, length);
+}
+
+inline void QOpenGLFunctions_4_1_Core::glReleaseShaderCompiler()
+{
+ d_4_1_Core->ReleaseShaderCompiler();
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_4_2_compatibility.cpp b/src/gui/opengl/qopenglfunctions_4_2_compatibility.cpp
new file mode 100644
index 0000000000..a415b24f33
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_2_compatibility.cpp
@@ -0,0 +1,402 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_4_2_compatibility.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_4_2_Compatibility
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_4_2_Compatibility class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_4_2_Compatibility::QOpenGLFunctions_4_2_Compatibility()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+ , d_3_2_Core(0)
+ , d_3_3_Core(0)
+ , d_4_0_Core(0)
+ , d_4_1_Core(0)
+ , d_4_2_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+ , d_1_3_Deprecated(0)
+ , d_1_4_Deprecated(0)
+ , d_2_0_Deprecated(0)
+ , d_3_0_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_4_2_Compatibility::~QOpenGLFunctions_4_2_Compatibility()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+ if (d_3_2_Core && !d_3_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_2_Core->context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ delete d_3_2_Core;
+ }
+ if (d_3_3_Core && !d_3_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_3_Core->context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ delete d_3_3_Core;
+ }
+ if (d_4_0_Core && !d_4_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_0_Core->context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ delete d_4_0_Core;
+ }
+ if (d_4_1_Core && !d_4_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_1_Core->context, QOpenGLFunctions_4_1_CoreBackend::versionStatus());
+ delete d_4_1_Core;
+ }
+ if (d_4_2_Core && !d_4_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_2_Core->context, QOpenGLFunctions_4_2_CoreBackend::versionStatus());
+ delete d_4_2_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+ if (d_1_3_Deprecated && !d_1_3_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Deprecated->context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ delete d_1_3_Deprecated;
+ }
+ if (d_1_4_Deprecated && !d_1_4_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Deprecated->context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ delete d_1_4_Deprecated;
+ }
+ if (d_2_0_Deprecated && !d_2_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Deprecated->context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ delete d_2_0_Deprecated;
+ }
+ if (d_3_0_Deprecated && !d_3_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Deprecated->context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ delete d_3_0_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_4_2_Compatibility::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_4_2_Compatibility::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus(), d);
+ }
+ d_3_2_Core = static_cast<QOpenGLFunctions_3_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus(), d);
+ }
+ d_3_3_Core = static_cast<QOpenGLFunctions_3_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus(), d);
+ }
+ d_4_0_Core = static_cast<QOpenGLFunctions_4_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_1_CoreBackend::versionStatus(), d);
+ }
+ d_4_1_Core = static_cast<QOpenGLFunctions_4_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_2_CoreBackend::versionStatus(), d);
+ }
+ d_4_2_Core = static_cast<QOpenGLFunctions_4_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_4_Deprecated = static_cast<QOpenGLFunctions_1_4_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_2_0_Deprecated = static_cast<QOpenGLFunctions_2_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_3_0_Deprecated = static_cast<QOpenGLFunctions_3_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_4_2_Compatibility::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(4, 2))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_4_2_Compatibility::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(4, 2);
+ v.setProfile(QSurfaceFormat::CompatibilityProfile);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_4_2_compatibility.h b/src/gui/opengl/qopenglfunctions_4_2_compatibility.h
new file mode 100644
index 0000000000..1819c79702
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_2_compatibility.h
@@ -0,0 +1,5638 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_4_2_COMPATIBILITY_H
+#define QOPENGLVERSIONFUNCTIONS_4_2_COMPATIBILITY_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_4_2_Compatibility : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_4_2_Compatibility();
+ ~QOpenGLFunctions_4_2_Compatibility();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+ // OpenGL 3.2 core functions
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+ void glProvokingVertex(GLenum mode);
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params);
+ void glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data);
+
+ // OpenGL 3.3 core functions
+ void glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glSecondaryColorP3uiv(GLenum type, const GLuint *color);
+ void glSecondaryColorP3ui(GLenum type, GLuint color);
+ void glColorP4uiv(GLenum type, const GLuint *color);
+ void glColorP4ui(GLenum type, GLuint color);
+ void glColorP3uiv(GLenum type, const GLuint *color);
+ void glColorP3ui(GLenum type, GLuint color);
+ void glNormalP3uiv(GLenum type, const GLuint *coords);
+ void glNormalP3ui(GLenum type, GLuint coords);
+ void glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords);
+ void glTexCoordP4uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP4ui(GLenum type, GLuint coords);
+ void glTexCoordP3uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP3ui(GLenum type, GLuint coords);
+ void glTexCoordP2uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP2ui(GLenum type, GLuint coords);
+ void glTexCoordP1uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP1ui(GLenum type, GLuint coords);
+ void glVertexP4uiv(GLenum type, const GLuint *value);
+ void glVertexP4ui(GLenum type, GLuint value);
+ void glVertexP3uiv(GLenum type, const GLuint *value);
+ void glVertexP3ui(GLenum type, GLuint value);
+ void glVertexP2uiv(GLenum type, const GLuint *value);
+ void glVertexP2ui(GLenum type, GLuint value);
+ void glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params);
+ void glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params);
+ void glQueryCounter(GLuint id, GLenum target);
+ void glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params);
+ void glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params);
+ void glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params);
+ void glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params);
+ void glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param);
+ void glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param);
+ void glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param);
+ void glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameteri(GLuint sampler, GLenum pname, GLint param);
+ void glBindSampler(GLuint unit, GLuint sampler);
+ GLboolean glIsSampler(GLuint sampler);
+ void glDeleteSamplers(GLsizei count, const GLuint *samplers);
+ void glGenSamplers(GLsizei count, GLuint *samplers);
+ GLint glGetFragDataIndex(GLuint program, const GLchar *name);
+ void glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+ void glVertexAttribDivisor(GLuint index, GLuint divisor);
+
+ // OpenGL 4.0 core functions
+ void glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void glEndQueryIndexed(GLenum target, GLuint index);
+ void glBeginQueryIndexed(GLenum target, GLuint index, GLuint id);
+ void glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream);
+ void glDrawTransformFeedback(GLenum mode, GLuint id);
+ void glResumeTransformFeedback();
+ void glPauseTransformFeedback();
+ GLboolean glIsTransformFeedback(GLuint id);
+ void glGenTransformFeedbacks(GLsizei n, GLuint *ids);
+ void glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids);
+ void glBindTransformFeedback(GLenum target, GLuint id);
+ void glPatchParameterfv(GLenum pname, const GLfloat *values);
+ void glPatchParameteri(GLenum pname, GLint value);
+ void glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values);
+ void glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params);
+ void glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices);
+ void glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
+ GLuint glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name);
+ GLint glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name);
+ void glGetUniformdv(GLuint program, GLint location, GLdouble *params);
+ void glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniform4dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform3dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform2dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform1dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void glUniform2d(GLint location, GLdouble x, GLdouble y);
+ void glUniform1d(GLint location, GLdouble x);
+ void glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect);
+ void glDrawArraysIndirect(GLenum mode, const GLvoid *indirect);
+ void glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void glBlendFunci(GLuint buf, GLenum src, GLenum dst);
+ void glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void glBlendEquationi(GLuint buf, GLenum mode);
+ void glMinSampleShading(GLfloat value);
+
+ // OpenGL 4.1 core functions
+ void glGetDoublei_v(GLenum target, GLuint index, GLdouble *data);
+ void glGetFloati_v(GLenum target, GLuint index, GLfloat *data);
+ void glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f);
+ void glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v);
+ void glScissorIndexedv(GLuint index, const GLint *v);
+ void glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+ void glScissorArrayv(GLuint first, GLsizei count, const GLint *v);
+ void glViewportIndexedfv(GLuint index, const GLfloat *v);
+ void glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+ void glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v);
+ void glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params);
+ void glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glVertexAttribL4dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL3dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL2dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL1dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttribL1d(GLuint index, GLdouble x);
+ void glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glValidateProgramPipeline(GLuint pipeline);
+ void glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+ void glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+ void glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+ void glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1);
+ void glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1);
+ void glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1);
+ void glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1);
+ void glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform1ui(GLuint program, GLint location, GLuint v0);
+ void glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform1d(GLuint program, GLint location, GLdouble v0);
+ void glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform1f(GLuint program, GLint location, GLfloat v0);
+ void glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform1i(GLuint program, GLint location, GLint v0);
+ void glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params);
+ GLboolean glIsProgramPipeline(GLuint pipeline);
+ void glGenProgramPipelines(GLsizei n, GLuint *pipelines);
+ void glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines);
+ void glBindProgramPipeline(GLuint pipeline);
+ GLuint glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings);
+ void glActiveShaderProgram(GLuint pipeline, GLuint program);
+ void glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program);
+ void glProgramParameteri(GLuint program, GLenum pname, GLint value);
+ void glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length);
+ void glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+ void glClearDepthf(GLfloat dd);
+ void glDepthRangef(GLfloat n, GLfloat f);
+ void glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision);
+ void glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length);
+ void glReleaseShaderCompiler();
+
+ // OpenGL 4.2 core functions
+ void glTexStorage3D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void glTexStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void glTexStorage1D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void glMemoryBarrier(GLbitfield barriers);
+ void glBindImageTexture(GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
+ void glGetActiveAtomicCounterBufferiv(GLuint program, GLuint bufferIndex, GLenum pname, GLint *params);
+ void glGetInternalformativ(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params);
+ void glDrawTransformFeedbackStreamInstanced(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
+ void glDrawTransformFeedbackInstanced(GLenum mode, GLuint id, GLsizei instancecount);
+ void glDrawElementsInstancedBaseVertexBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
+ void glDrawElementsInstancedBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance);
+ void glDrawArraysInstancedBaseInstance(GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+ // OpenGL 1.3 deprecated functions
+ void glMultTransposeMatrixd(const GLdouble *m);
+ void glMultTransposeMatrixf(const GLfloat *m);
+ void glLoadTransposeMatrixd(const GLdouble *m);
+ void glLoadTransposeMatrixf(const GLfloat *m);
+ void glMultiTexCoord4sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4iv(GLenum target, const GLint *v);
+ void glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3iv(GLenum target, const GLint *v);
+ void glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord2s(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2iv(GLenum target, const GLint *v);
+ void glMultiTexCoord2i(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord1s(GLenum target, GLshort s);
+ void glMultiTexCoord1iv(GLenum target, const GLint *v);
+ void glMultiTexCoord1i(GLenum target, GLint s);
+ void glMultiTexCoord1fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1f(GLenum target, GLfloat s);
+ void glMultiTexCoord1dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1d(GLenum target, GLdouble s);
+ void glClientActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 deprecated functions
+ void glWindowPos3sv(const GLshort *v);
+ void glWindowPos3s(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3iv(const GLint *v);
+ void glWindowPos3i(GLint x, GLint y, GLint z);
+ void glWindowPos3fv(const GLfloat *v);
+ void glWindowPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dv(const GLdouble *v);
+ void glWindowPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2sv(const GLshort *v);
+ void glWindowPos2s(GLshort x, GLshort y);
+ void glWindowPos2iv(const GLint *v);
+ void glWindowPos2i(GLint x, GLint y);
+ void glWindowPos2fv(const GLfloat *v);
+ void glWindowPos2f(GLfloat x, GLfloat y);
+ void glWindowPos2dv(const GLdouble *v);
+ void glWindowPos2d(GLdouble x, GLdouble y);
+ void glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glSecondaryColor3usv(const GLushort *v);
+ void glSecondaryColor3us(GLushort red, GLushort green, GLushort blue);
+ void glSecondaryColor3uiv(const GLuint *v);
+ void glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glSecondaryColor3ubv(const GLubyte *v);
+ void glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glSecondaryColor3sv(const GLshort *v);
+ void glSecondaryColor3s(GLshort red, GLshort green, GLshort blue);
+ void glSecondaryColor3iv(const GLint *v);
+ void glSecondaryColor3i(GLint red, GLint green, GLint blue);
+ void glSecondaryColor3fv(const GLfloat *v);
+ void glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glSecondaryColor3dv(const GLdouble *v);
+ void glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glSecondaryColor3bv(const GLbyte *v);
+ void glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glFogCoorddv(const GLdouble *coord);
+ void glFogCoordd(GLdouble coord);
+ void glFogCoordfv(const GLfloat *coord);
+ void glFogCoordf(GLfloat coord);
+
+ // OpenGL 1.5 deprecated functions
+
+ // OpenGL 2.0 deprecated functions
+ void glVertexAttrib4usv(GLuint index, const GLushort *v);
+ void glVertexAttrib4uiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4sv(GLuint index, const GLshort *v);
+ void glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertexAttrib4iv(GLuint index, const GLint *v);
+ void glVertexAttrib4fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexAttrib4dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttrib4bv(GLuint index, const GLbyte *v);
+ void glVertexAttrib4Nusv(GLuint index, const GLushort *v);
+ void glVertexAttrib4Nuiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4Nubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void glVertexAttrib4Nsv(GLuint index, const GLshort *v);
+ void glVertexAttrib4Niv(GLuint index, const GLint *v);
+ void glVertexAttrib4Nbv(GLuint index, const GLbyte *v);
+ void glVertexAttrib3sv(GLuint index, const GLshort *v);
+ void glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z);
+ void glVertexAttrib3fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexAttrib3dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttrib2sv(GLuint index, const GLshort *v);
+ void glVertexAttrib2s(GLuint index, GLshort x, GLshort y);
+ void glVertexAttrib2fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y);
+ void glVertexAttrib2dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttrib1sv(GLuint index, const GLshort *v);
+ void glVertexAttrib1s(GLuint index, GLshort x);
+ void glVertexAttrib1fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib1f(GLuint index, GLfloat x);
+ void glVertexAttrib1dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib1d(GLuint index, GLdouble x);
+
+ // OpenGL 2.1 deprecated functions
+
+ // OpenGL 3.0 deprecated functions
+ void glVertexAttribI4usv(GLuint index, const GLushort *v);
+ void glVertexAttribI4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttribI4sv(GLuint index, const GLshort *v);
+ void glVertexAttribI4bv(GLuint index, const GLbyte *v);
+ void glVertexAttribI4uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI3uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI2uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI1uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI4iv(GLuint index, const GLint *v);
+ void glVertexAttribI3iv(GLuint index, const GLint *v);
+ void glVertexAttribI2iv(GLuint index, const GLint *v);
+ void glVertexAttribI1iv(GLuint index, const GLint *v);
+ void glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z);
+ void glVertexAttribI2ui(GLuint index, GLuint x, GLuint y);
+ void glVertexAttribI1ui(GLuint index, GLuint x);
+ void glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z);
+ void glVertexAttribI2i(GLuint index, GLint x, GLint y);
+ void glVertexAttribI1i(GLuint index, GLint x);
+
+ // OpenGL 3.1 deprecated functions
+
+ // OpenGL 3.2 deprecated functions
+
+ // OpenGL 3.3 deprecated functions
+
+ // OpenGL 4.0 deprecated functions
+
+ // OpenGL 4.1 deprecated functions
+
+ // OpenGL 4.2 deprecated functions
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+ QOpenGLFunctions_3_2_CoreBackend* d_3_2_Core;
+ QOpenGLFunctions_3_3_CoreBackend* d_3_3_Core;
+ QOpenGLFunctions_4_0_CoreBackend* d_4_0_Core;
+ QOpenGLFunctions_4_1_CoreBackend* d_4_1_Core;
+ QOpenGLFunctions_4_2_CoreBackend* d_4_2_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+ QOpenGLFunctions_1_3_DeprecatedBackend* d_1_3_Deprecated;
+ QOpenGLFunctions_1_4_DeprecatedBackend* d_1_4_Deprecated;
+ QOpenGLFunctions_2_0_DeprecatedBackend* d_2_0_Deprecated;
+ QOpenGLFunctions_3_0_DeprecatedBackend* d_3_0_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_2_Compatibility::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_4_2_Compatibility::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_4_2_Compatibility::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_4_2_Compatibility::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_4_2_Compatibility::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_4_2_Compatibility::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_4_2_Compatibility::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_4_2_Compatibility::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_4_2_Compatibility::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_2_Compatibility::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_4_2_Compatibility::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_4_2_Compatibility::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+// OpenGL 3.2 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ d_3_2_Core->SampleMaski(index, mask);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ d_3_2_Core->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ d_3_2_Core->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ d_3_2_Core->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLFunctions_4_2_Compatibility::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ return d_3_2_Core->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteSync(GLsync sync)
+{
+ d_3_2_Core->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsSync(GLsync sync)
+{
+ return d_3_2_Core->IsSync(sync);
+}
+
+inline GLsync QOpenGLFunctions_4_2_Compatibility::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ return d_3_2_Core->FenceSync(condition, flags);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProvokingVertex(GLenum mode)
+{
+ d_3_2_Core->ProvokingVertex(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ d_3_2_Core->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ d_3_2_Core->FramebufferTexture(target, attachment, texture, level);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetBufferParameteri64v(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data)
+{
+ d_3_2_Core->GetInteger64i_v(target, index, data);
+}
+
+
+// OpenGL 3.3 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP4uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP4ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP3uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP3ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP2uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP2ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP1uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP1ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->SecondaryColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->SecondaryColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColorP4uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP4uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColorP4ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP4ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormalP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->NormalP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormalP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->NormalP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP4uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP4ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP3uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP3ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP2uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP2ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP1uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP1ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoordP4uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP4uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoordP4ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP4ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoordP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoordP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoordP2uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP2uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoordP2ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP2ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoordP1uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP1uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoordP1ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP1ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexP4uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP4uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexP4ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP4ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexP3uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP3uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexP3ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP3ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexP2uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP2uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexP2ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP2ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params)
+{
+ d_3_3_Core->GetQueryObjectui64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params)
+{
+ d_3_3_Core->GetQueryObjecti64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glQueryCounter(GLuint id, GLenum target)
+{
+ d_3_3_Core->QueryCounter(id, target);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params)
+{
+ d_3_3_Core->GetSamplerParameterIuiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params)
+{
+ d_3_3_Core->GetSamplerParameterfv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameterIiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameteriv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ d_3_3_Core->SamplerParameterIuiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameterIiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param)
+{
+ d_3_3_Core->SamplerParameterfv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param)
+{
+ d_3_3_Core->SamplerParameterf(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameteriv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSamplerParameteri(GLuint sampler, GLenum pname, GLint param)
+{
+ d_3_3_Core->SamplerParameteri(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindSampler(GLuint unit, GLuint sampler)
+{
+ d_3_3_Core->BindSampler(unit, sampler);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsSampler(GLuint sampler)
+{
+ return d_3_3_Core->IsSampler(sampler);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteSamplers(GLsizei count, const GLuint *samplers)
+{
+ d_3_3_Core->DeleteSamplers(count, samplers);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGenSamplers(GLsizei count, GLuint *samplers)
+{
+ d_3_3_Core->GenSamplers(count, samplers);
+}
+
+inline GLint QOpenGLFunctions_4_2_Compatibility::glGetFragDataIndex(GLuint program, const GLchar *name)
+{
+ return d_3_3_Core->GetFragDataIndex(program, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name)
+{
+ d_3_3_Core->BindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribDivisor(GLuint index, GLuint divisor)
+{
+ d_3_3_Core->VertexAttribDivisor(index, divisor);
+}
+
+
+// OpenGL 4.0 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params)
+{
+ d_4_0_Core->GetQueryIndexediv(target, index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEndQueryIndexed(GLenum target, GLuint index)
+{
+ d_4_0_Core->EndQueryIndexed(target, index);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBeginQueryIndexed(GLenum target, GLuint index, GLuint id)
+{
+ d_4_0_Core->BeginQueryIndexed(target, index, id);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream)
+{
+ d_4_0_Core->DrawTransformFeedbackStream(mode, id, stream);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawTransformFeedback(GLenum mode, GLuint id)
+{
+ d_4_0_Core->DrawTransformFeedback(mode, id);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glResumeTransformFeedback()
+{
+ d_4_0_Core->ResumeTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPauseTransformFeedback()
+{
+ d_4_0_Core->PauseTransformFeedback();
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsTransformFeedback(GLuint id)
+{
+ return d_4_0_Core->IsTransformFeedback(id);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGenTransformFeedbacks(GLsizei n, GLuint *ids)
+{
+ d_4_0_Core->GenTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids)
+{
+ d_4_0_Core->DeleteTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindTransformFeedback(GLenum target, GLuint id)
+{
+ d_4_0_Core->BindTransformFeedback(target, id);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPatchParameterfv(GLenum pname, const GLfloat *values)
+{
+ d_4_0_Core->PatchParameterfv(pname, values);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPatchParameteri(GLenum pname, GLint value)
+{
+ d_4_0_Core->PatchParameteri(pname, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetProgramStageiv(program, shadertype, pname, values);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params)
+{
+ d_4_0_Core->GetUniformSubroutineuiv(shadertype, location, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices)
+{
+ d_4_0_Core->UniformSubroutinesuiv(shadertype, count, indices);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineUniformName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+inline GLuint QOpenGLFunctions_4_2_Compatibility::glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineIndex(program, shadertype, name);
+}
+
+inline GLint QOpenGLFunctions_4_2_Compatibility::glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineUniformLocation(program, shadertype, name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetUniformdv(GLuint program, GLint location, GLdouble *params)
+{
+ d_4_0_Core->GetUniformdv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform4dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform4dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform3dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform3dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform2dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform2dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform1dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform1dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_0_Core->Uniform4d(location, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_0_Core->Uniform3d(location, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform2d(GLint location, GLdouble x, GLdouble y)
+{
+ d_4_0_Core->Uniform2d(location, x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUniform1d(GLint location, GLdouble x)
+{
+ d_4_0_Core->Uniform1d(location, x);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawElementsIndirect(mode, type, indirect);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawArraysIndirect(GLenum mode, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawArraysIndirect(mode, indirect);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ d_4_0_Core->BlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBlendFunci(GLuint buf, GLenum src, GLenum dst)
+{
+ d_4_0_Core->BlendFunci(buf, src, dst);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ d_4_0_Core->BlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBlendEquationi(GLuint buf, GLenum mode)
+{
+ d_4_0_Core->BlendEquationi(buf, mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMinSampleShading(GLfloat value)
+{
+ d_4_0_Core->MinSampleShading(value);
+}
+
+
+// OpenGL 4.1 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glGetDoublei_v(GLenum target, GLuint index, GLdouble *data)
+{
+ d_4_1_Core->GetDoublei_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetFloati_v(GLenum target, GLuint index, GLfloat *data)
+{
+ d_4_1_Core->GetFloati_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f)
+{
+ d_4_1_Core->DepthRangeIndexed(index, n, f);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v)
+{
+ d_4_1_Core->DepthRangeArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glScissorIndexedv(GLuint index, const GLint *v)
+{
+ d_4_1_Core->ScissorIndexedv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ d_4_1_Core->ScissorIndexed(index, left, bottom, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glScissorArrayv(GLuint first, GLsizei count, const GLint *v)
+{
+ d_4_1_Core->ScissorArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glViewportIndexedfv(GLuint index, const GLfloat *v)
+{
+ d_4_1_Core->ViewportIndexedfv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ d_4_1_Core->ViewportIndexedf(index, x, y, w, h);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v)
+{
+ d_4_1_Core->ViewportArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_4_1_Core->GetVertexAttribLdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_4_1_Core->VertexAttribLPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribL4dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL4dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribL3dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL3dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribL2dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL2dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribL1dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL1dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_1_Core->VertexAttribL4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_1_Core->VertexAttribL3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_4_1_Core->VertexAttribL2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribL1d(GLuint index, GLdouble x)
+{
+ d_4_1_Core->VertexAttribL1d(index, x);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_4_1_Core->GetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glValidateProgramPipeline(GLuint pipeline)
+{
+ d_4_1_Core->ValidateProgramPipeline(pipeline);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform4uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_4_1_Core->ProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform4dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ d_4_1_Core->ProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform4fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_4_1_Core->ProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform4iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_4_1_Core->ProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform3uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_4_1_Core->ProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform3dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ d_4_1_Core->ProgramUniform3d(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform3fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_4_1_Core->ProgramUniform3f(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform3iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_4_1_Core->ProgramUniform3i(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform2uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ d_4_1_Core->ProgramUniform2ui(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform2dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ d_4_1_Core->ProgramUniform2d(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform2fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ d_4_1_Core->ProgramUniform2f(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform2iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1)
+{
+ d_4_1_Core->ProgramUniform2i(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform1uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform1ui(GLuint program, GLint location, GLuint v0)
+{
+ d_4_1_Core->ProgramUniform1ui(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform1dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform1d(GLuint program, GLint location, GLdouble v0)
+{
+ d_4_1_Core->ProgramUniform1d(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform1fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform1f(GLuint program, GLint location, GLfloat v0)
+{
+ d_4_1_Core->ProgramUniform1f(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform1iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramUniform1i(GLuint program, GLint location, GLint v0)
+{
+ d_4_1_Core->ProgramUniform1i(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params)
+{
+ d_4_1_Core->GetProgramPipelineiv(pipeline, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsProgramPipeline(GLuint pipeline)
+{
+ return d_4_1_Core->IsProgramPipeline(pipeline);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGenProgramPipelines(GLsizei n, GLuint *pipelines)
+{
+ d_4_1_Core->GenProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines)
+{
+ d_4_1_Core->DeleteProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindProgramPipeline(GLuint pipeline)
+{
+ d_4_1_Core->BindProgramPipeline(pipeline);
+}
+
+inline GLuint QOpenGLFunctions_4_2_Compatibility::glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings)
+{
+ return d_4_1_Core->CreateShaderProgramv(type, count, strings);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glActiveShaderProgram(GLuint pipeline, GLuint program)
+{
+ d_4_1_Core->ActiveShaderProgram(pipeline, program);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ d_4_1_Core->UseProgramStages(pipeline, stages, program);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramParameteri(GLuint program, GLenum pname, GLint value)
+{
+ d_4_1_Core->ProgramParameteri(program, pname, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length)
+{
+ d_4_1_Core->ProgramBinary(program, binaryFormat, binary, length);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary)
+{
+ d_4_1_Core->GetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClearDepthf(GLfloat dd)
+{
+ d_4_1_Core->ClearDepthf(dd);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDepthRangef(GLfloat n, GLfloat f)
+{
+ d_4_1_Core->DepthRangef(n, f);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision)
+{
+ d_4_1_Core->GetShaderPrecisionFormat(shadertype, precisiontype, range, precision);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length)
+{
+ d_4_1_Core->ShaderBinary(count, shaders, binaryformat, binary, length);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glReleaseShaderCompiler()
+{
+ d_4_1_Core->ReleaseShaderCompiler();
+}
+
+
+// OpenGL 4.2 core functions
+inline void QOpenGLFunctions_4_2_Compatibility::glTexStorage3D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ d_4_2_Core->TexStorage3D(target, levels, internalformat, width, height, depth);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_4_2_Core->TexStorage2D(target, levels, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexStorage1D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width)
+{
+ d_4_2_Core->TexStorage1D(target, levels, internalformat, width);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMemoryBarrier(GLbitfield barriers)
+{
+ d_4_2_Core->MemoryBarrier(barriers);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBindImageTexture(GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format)
+{
+ d_4_2_Core->BindImageTexture(unit, texture, level, layered, layer, access, format);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetActiveAtomicCounterBufferiv(GLuint program, GLuint bufferIndex, GLenum pname, GLint *params)
+{
+ d_4_2_Core->GetActiveAtomicCounterBufferiv(program, bufferIndex, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetInternalformativ(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params)
+{
+ d_4_2_Core->GetInternalformativ(target, internalformat, pname, bufSize, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawTransformFeedbackStreamInstanced(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount)
+{
+ d_4_2_Core->DrawTransformFeedbackStreamInstanced(mode, id, stream, instancecount);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawTransformFeedbackInstanced(GLenum mode, GLuint id, GLsizei instancecount)
+{
+ d_4_2_Core->DrawTransformFeedbackInstanced(mode, id, instancecount);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawElementsInstancedBaseVertexBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance)
+{
+ d_4_2_Core->DrawElementsInstancedBaseVertexBaseInstance(mode, count, type, indices, instancecount, basevertex, baseinstance);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawElementsInstancedBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance)
+{
+ d_4_2_Core->DrawElementsInstancedBaseInstance(mode, count, type, indices, instancecount, baseinstance);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawArraysInstancedBaseInstance(GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance)
+{
+ d_4_2_Core->DrawArraysInstancedBaseInstance(mode, first, count, instancecount, baseinstance);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_4_2_Compatibility::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_4_2_Compatibility::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_4_2_Compatibility::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_4_2_Compatibility::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Compatibility::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_4_2_Compatibility::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+// OpenGL 1.3 deprecated functions
+inline void QOpenGLFunctions_4_2_Compatibility::glMultTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLoadTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glLoadTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord4sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_3_Deprecated->MultiTexCoord4s(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord4iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_3_Deprecated->MultiTexCoord4i(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord4fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_3_Deprecated->MultiTexCoord4f(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord4dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_3_Deprecated->MultiTexCoord4d(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord3sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ d_1_3_Deprecated->MultiTexCoord3s(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord3iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r)
+{
+ d_1_3_Deprecated->MultiTexCoord3i(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord3fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_3_Deprecated->MultiTexCoord3f(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord3dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_3_Deprecated->MultiTexCoord3d(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord2sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord2s(GLenum target, GLshort s, GLshort t)
+{
+ d_1_3_Deprecated->MultiTexCoord2s(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord2iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord2i(GLenum target, GLint s, GLint t)
+{
+ d_1_3_Deprecated->MultiTexCoord2i(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord2fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t)
+{
+ d_1_3_Deprecated->MultiTexCoord2f(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord2dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t)
+{
+ d_1_3_Deprecated->MultiTexCoord2d(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord1sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord1s(GLenum target, GLshort s)
+{
+ d_1_3_Deprecated->MultiTexCoord1s(target, s);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord1iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord1i(GLenum target, GLint s)
+{
+ d_1_3_Deprecated->MultiTexCoord1i(target, s);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord1fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord1f(GLenum target, GLfloat s)
+{
+ d_1_3_Deprecated->MultiTexCoord1f(target, s);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord1dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glMultiTexCoord1d(GLenum target, GLdouble s)
+{
+ d_1_3_Deprecated->MultiTexCoord1d(target, s);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glClientActiveTexture(GLenum texture)
+{
+ d_1_3_Deprecated->ClientActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 deprecated functions
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos3sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_4_Deprecated->WindowPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos3iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos3iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_4_Deprecated->WindowPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos3fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_4_Deprecated->WindowPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos3dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_4_Deprecated->WindowPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos2sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos2sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos2s(GLshort x, GLshort y)
+{
+ d_1_4_Deprecated->WindowPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos2iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos2iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos2i(GLint x, GLint y)
+{
+ d_1_4_Deprecated->WindowPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos2fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos2fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos2f(GLfloat x, GLfloat y)
+{
+ d_1_4_Deprecated->WindowPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos2dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos2dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glWindowPos2d(GLdouble x, GLdouble y)
+{
+ d_1_4_Deprecated->WindowPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->SecondaryColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3usv(const GLushort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3usv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3uiv(const GLuint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3uiv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3ubv(const GLubyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3ubv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3sv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3iv(const GLint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3iv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->SecondaryColor3fv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_4_Deprecated->SecondaryColor3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->SecondaryColor3dv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_4_Deprecated->SecondaryColor3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3bv(const GLbyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3bv(v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->FogCoordPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFogCoorddv(const GLdouble *coord)
+{
+ d_1_4_Deprecated->FogCoorddv(coord);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFogCoordd(GLdouble coord)
+{
+ d_1_4_Deprecated->FogCoordd(coord);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFogCoordfv(const GLfloat *coord)
+{
+ d_1_4_Deprecated->FogCoordfv(coord);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glFogCoordf(GLfloat coord)
+{
+ d_1_4_Deprecated->FogCoordf(coord);
+}
+
+
+// OpenGL 1.5 deprecated functions
+
+// OpenGL 2.0 deprecated functions
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4usv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4usv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4uiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4ubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_2_0_Deprecated->VertexAttrib4s(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4iv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib4fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_2_0_Deprecated->VertexAttrib4f(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib4dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_2_0_Deprecated->VertexAttrib4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4bv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4bv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4Nusv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nusv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4Nuiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nuiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4Nubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nubv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ d_2_0_Deprecated->VertexAttrib4Nub(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4Nsv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nsv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4Niv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Niv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib4Nbv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nbv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib3sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib3sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ d_2_0_Deprecated->VertexAttrib3s(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib3fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib3fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_2_0_Deprecated->VertexAttrib3f(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib3dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib3dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_2_0_Deprecated->VertexAttrib3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib2sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib2sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib2s(GLuint index, GLshort x, GLshort y)
+{
+ d_2_0_Deprecated->VertexAttrib2s(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib2fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib2fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y)
+{
+ d_2_0_Deprecated->VertexAttrib2f(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib2dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib2dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_2_0_Deprecated->VertexAttrib2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib1sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib1sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib1s(GLuint index, GLshort x)
+{
+ d_2_0_Deprecated->VertexAttrib1s(index, x);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib1fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib1fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib1f(GLuint index, GLfloat x)
+{
+ d_2_0_Deprecated->VertexAttrib1f(index, x);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib1dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib1dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttrib1d(GLuint index, GLdouble x)
+{
+ d_2_0_Deprecated->VertexAttrib1d(index, x);
+}
+
+
+// OpenGL 2.1 deprecated functions
+
+// OpenGL 3.0 deprecated functions
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI4usv(GLuint index, const GLushort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4usv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI4ubv(GLuint index, const GLubyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI4sv(GLuint index, const GLshort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI4bv(GLuint index, const GLbyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4bv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI4uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI3uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI2uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI1uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI4iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI3iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI2iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI1iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ d_3_0_Deprecated->VertexAttribI4ui(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ d_3_0_Deprecated->VertexAttribI3ui(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI2ui(GLuint index, GLuint x, GLuint y)
+{
+ d_3_0_Deprecated->VertexAttribI2ui(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI1ui(GLuint index, GLuint x)
+{
+ d_3_0_Deprecated->VertexAttribI1ui(index, x);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ d_3_0_Deprecated->VertexAttribI4i(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z)
+{
+ d_3_0_Deprecated->VertexAttribI3i(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI2i(GLuint index, GLint x, GLint y)
+{
+ d_3_0_Deprecated->VertexAttribI2i(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Compatibility::glVertexAttribI1i(GLuint index, GLint x)
+{
+ d_3_0_Deprecated->VertexAttribI1i(index, x);
+}
+
+
+// OpenGL 3.1 deprecated functions
+
+// OpenGL 3.2 deprecated functions
+
+// OpenGL 3.3 deprecated functions
+
+// OpenGL 4.0 deprecated functions
+
+// OpenGL 4.1 deprecated functions
+
+// OpenGL 4.2 deprecated functions
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_4_2_core.cpp b/src/gui/opengl/qopenglfunctions_4_2_core.cpp
new file mode 100644
index 0000000000..3600c20a41
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_2_core.cpp
@@ -0,0 +1,308 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_4_2_core.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_4_2_Core
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_4_2_Core class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_4_2_Core::QOpenGLFunctions_4_2_Core()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+ , d_3_2_Core(0)
+ , d_3_3_Core(0)
+ , d_4_0_Core(0)
+ , d_4_1_Core(0)
+ , d_4_2_Core(0)
+{
+}
+
+QOpenGLFunctions_4_2_Core::~QOpenGLFunctions_4_2_Core()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+ if (d_3_2_Core && !d_3_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_2_Core->context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ delete d_3_2_Core;
+ }
+ if (d_3_3_Core && !d_3_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_3_Core->context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ delete d_3_3_Core;
+ }
+ if (d_4_0_Core && !d_4_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_0_Core->context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ delete d_4_0_Core;
+ }
+ if (d_4_1_Core && !d_4_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_1_Core->context, QOpenGLFunctions_4_1_CoreBackend::versionStatus());
+ delete d_4_1_Core;
+ }
+ if (d_4_2_Core && !d_4_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_2_Core->context, QOpenGLFunctions_4_2_CoreBackend::versionStatus());
+ delete d_4_2_Core;
+ }
+}
+
+bool QOpenGLFunctions_4_2_Core::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_4_2_Core::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus(), d);
+ }
+ d_3_2_Core = static_cast<QOpenGLFunctions_3_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus(), d);
+ }
+ d_3_3_Core = static_cast<QOpenGLFunctions_3_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus(), d);
+ }
+ d_4_0_Core = static_cast<QOpenGLFunctions_4_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_1_CoreBackend::versionStatus(), d);
+ }
+ d_4_1_Core = static_cast<QOpenGLFunctions_4_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_2_CoreBackend::versionStatus(), d);
+ }
+ d_4_2_Core = static_cast<QOpenGLFunctions_4_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_4_2_Core::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(4, 2))
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_4_2_Core::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(4, 2);
+ v.setProfile(QSurfaceFormat::CoreProfile);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_4_2_core.h b/src/gui/opengl/qopenglfunctions_4_2_core.h
new file mode 100644
index 0000000000..dbdaa2996f
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_2_core.h
@@ -0,0 +1,2961 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_4_2_CORE_H
+#define QOPENGLVERSIONFUNCTIONS_4_2_CORE_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_4_2_Core : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_4_2_Core();
+ ~QOpenGLFunctions_4_2_Core();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+ // OpenGL 3.2 core functions
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+ void glProvokingVertex(GLenum mode);
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params);
+ void glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data);
+
+ // OpenGL 3.3 core functions
+ void glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glSecondaryColorP3uiv(GLenum type, const GLuint *color);
+ void glSecondaryColorP3ui(GLenum type, GLuint color);
+ void glColorP4uiv(GLenum type, const GLuint *color);
+ void glColorP4ui(GLenum type, GLuint color);
+ void glColorP3uiv(GLenum type, const GLuint *color);
+ void glColorP3ui(GLenum type, GLuint color);
+ void glNormalP3uiv(GLenum type, const GLuint *coords);
+ void glNormalP3ui(GLenum type, GLuint coords);
+ void glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords);
+ void glTexCoordP4uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP4ui(GLenum type, GLuint coords);
+ void glTexCoordP3uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP3ui(GLenum type, GLuint coords);
+ void glTexCoordP2uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP2ui(GLenum type, GLuint coords);
+ void glTexCoordP1uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP1ui(GLenum type, GLuint coords);
+ void glVertexP4uiv(GLenum type, const GLuint *value);
+ void glVertexP4ui(GLenum type, GLuint value);
+ void glVertexP3uiv(GLenum type, const GLuint *value);
+ void glVertexP3ui(GLenum type, GLuint value);
+ void glVertexP2uiv(GLenum type, const GLuint *value);
+ void glVertexP2ui(GLenum type, GLuint value);
+ void glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params);
+ void glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params);
+ void glQueryCounter(GLuint id, GLenum target);
+ void glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params);
+ void glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params);
+ void glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params);
+ void glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params);
+ void glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param);
+ void glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param);
+ void glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param);
+ void glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameteri(GLuint sampler, GLenum pname, GLint param);
+ void glBindSampler(GLuint unit, GLuint sampler);
+ GLboolean glIsSampler(GLuint sampler);
+ void glDeleteSamplers(GLsizei count, const GLuint *samplers);
+ void glGenSamplers(GLsizei count, GLuint *samplers);
+ GLint glGetFragDataIndex(GLuint program, const GLchar *name);
+ void glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+ void glVertexAttribDivisor(GLuint index, GLuint divisor);
+
+ // OpenGL 4.0 core functions
+ void glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void glEndQueryIndexed(GLenum target, GLuint index);
+ void glBeginQueryIndexed(GLenum target, GLuint index, GLuint id);
+ void glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream);
+ void glDrawTransformFeedback(GLenum mode, GLuint id);
+ void glResumeTransformFeedback();
+ void glPauseTransformFeedback();
+ GLboolean glIsTransformFeedback(GLuint id);
+ void glGenTransformFeedbacks(GLsizei n, GLuint *ids);
+ void glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids);
+ void glBindTransformFeedback(GLenum target, GLuint id);
+ void glPatchParameterfv(GLenum pname, const GLfloat *values);
+ void glPatchParameteri(GLenum pname, GLint value);
+ void glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values);
+ void glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params);
+ void glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices);
+ void glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
+ GLuint glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name);
+ GLint glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name);
+ void glGetUniformdv(GLuint program, GLint location, GLdouble *params);
+ void glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniform4dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform3dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform2dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform1dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void glUniform2d(GLint location, GLdouble x, GLdouble y);
+ void glUniform1d(GLint location, GLdouble x);
+ void glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect);
+ void glDrawArraysIndirect(GLenum mode, const GLvoid *indirect);
+ void glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void glBlendFunci(GLuint buf, GLenum src, GLenum dst);
+ void glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void glBlendEquationi(GLuint buf, GLenum mode);
+ void glMinSampleShading(GLfloat value);
+
+ // OpenGL 4.1 core functions
+ void glGetDoublei_v(GLenum target, GLuint index, GLdouble *data);
+ void glGetFloati_v(GLenum target, GLuint index, GLfloat *data);
+ void glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f);
+ void glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v);
+ void glScissorIndexedv(GLuint index, const GLint *v);
+ void glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+ void glScissorArrayv(GLuint first, GLsizei count, const GLint *v);
+ void glViewportIndexedfv(GLuint index, const GLfloat *v);
+ void glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+ void glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v);
+ void glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params);
+ void glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glVertexAttribL4dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL3dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL2dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL1dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttribL1d(GLuint index, GLdouble x);
+ void glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glValidateProgramPipeline(GLuint pipeline);
+ void glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+ void glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+ void glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+ void glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1);
+ void glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1);
+ void glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1);
+ void glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1);
+ void glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform1ui(GLuint program, GLint location, GLuint v0);
+ void glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform1d(GLuint program, GLint location, GLdouble v0);
+ void glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform1f(GLuint program, GLint location, GLfloat v0);
+ void glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform1i(GLuint program, GLint location, GLint v0);
+ void glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params);
+ GLboolean glIsProgramPipeline(GLuint pipeline);
+ void glGenProgramPipelines(GLsizei n, GLuint *pipelines);
+ void glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines);
+ void glBindProgramPipeline(GLuint pipeline);
+ GLuint glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings);
+ void glActiveShaderProgram(GLuint pipeline, GLuint program);
+ void glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program);
+ void glProgramParameteri(GLuint program, GLenum pname, GLint value);
+ void glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length);
+ void glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+ void glClearDepthf(GLfloat dd);
+ void glDepthRangef(GLfloat n, GLfloat f);
+ void glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision);
+ void glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length);
+ void glReleaseShaderCompiler();
+
+ // OpenGL 4.2 core functions
+ void glTexStorage3D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void glTexStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void glTexStorage1D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void glMemoryBarrier(GLbitfield barriers);
+ void glBindImageTexture(GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
+ void glGetActiveAtomicCounterBufferiv(GLuint program, GLuint bufferIndex, GLenum pname, GLint *params);
+ void glGetInternalformativ(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params);
+ void glDrawTransformFeedbackStreamInstanced(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
+ void glDrawTransformFeedbackInstanced(GLenum mode, GLuint id, GLsizei instancecount);
+ void glDrawElementsInstancedBaseVertexBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
+ void glDrawElementsInstancedBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance);
+ void glDrawArraysInstancedBaseInstance(GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+ QOpenGLFunctions_3_2_CoreBackend* d_3_2_Core;
+ QOpenGLFunctions_3_3_CoreBackend* d_3_3_Core;
+ QOpenGLFunctions_4_0_CoreBackend* d_4_0_Core;
+ QOpenGLFunctions_4_1_CoreBackend* d_4_1_Core;
+ QOpenGLFunctions_4_2_CoreBackend* d_4_2_Core;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_4_2_Core::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_2_Core::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_4_2_Core::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_4_2_Core::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_4_2_Core::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_4_2_Core::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_4_2_Core::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_4_2_Core::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_4_2_Core::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_4_2_Core::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_4_2_Core::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_4_2_Core::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_4_2_Core::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_4_2_Core::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_4_2_Core::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_4_2_Core::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_4_2_Core::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_4_2_Core::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_2_Core::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_4_2_Core::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_4_2_Core::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_4_2_Core::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+// OpenGL 3.2 core functions
+inline void QOpenGLFunctions_4_2_Core::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ d_3_2_Core->SampleMaski(index, mask);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ d_3_2_Core->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ d_3_2_Core->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ d_3_2_Core->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLFunctions_4_2_Core::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ return d_3_2_Core->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDeleteSync(GLsync sync)
+{
+ d_3_2_Core->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsSync(GLsync sync)
+{
+ return d_3_2_Core->IsSync(sync);
+}
+
+inline GLsync QOpenGLFunctions_4_2_Core::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ return d_3_2_Core->FenceSync(condition, flags);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProvokingVertex(GLenum mode)
+{
+ d_3_2_Core->ProvokingVertex(mode);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ d_3_2_Core->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ d_3_2_Core->FramebufferTexture(target, attachment, texture, level);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetBufferParameteri64v(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data)
+{
+ d_3_2_Core->GetInteger64i_v(target, index, data);
+}
+
+
+// OpenGL 3.3 core functions
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP4uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP4ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP3uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP3ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP2uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP2ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP1uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP1ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glSecondaryColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->SecondaryColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glSecondaryColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->SecondaryColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glColorP4uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP4uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glColorP4ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP4ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glNormalP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->NormalP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glNormalP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->NormalP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP4uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP4ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP3uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP3ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP2uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP2ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP1uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP1ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexCoordP4uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP4uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexCoordP4ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP4ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexCoordP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexCoordP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexCoordP2uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP2uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexCoordP2ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP2ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexCoordP1uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP1uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexCoordP1ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP1ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexP4uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP4uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexP4ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP4ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexP3uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP3uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexP3ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP3ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexP2uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP2uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexP2ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP2ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params)
+{
+ d_3_3_Core->GetQueryObjectui64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params)
+{
+ d_3_3_Core->GetQueryObjecti64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glQueryCounter(GLuint id, GLenum target)
+{
+ d_3_3_Core->QueryCounter(id, target);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params)
+{
+ d_3_3_Core->GetSamplerParameterIuiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params)
+{
+ d_3_3_Core->GetSamplerParameterfv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameterIiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameteriv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ d_3_3_Core->SamplerParameterIuiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameterIiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param)
+{
+ d_3_3_Core->SamplerParameterfv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param)
+{
+ d_3_3_Core->SamplerParameterf(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameteriv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glSamplerParameteri(GLuint sampler, GLenum pname, GLint param)
+{
+ d_3_3_Core->SamplerParameteri(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindSampler(GLuint unit, GLuint sampler)
+{
+ d_3_3_Core->BindSampler(unit, sampler);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsSampler(GLuint sampler)
+{
+ return d_3_3_Core->IsSampler(sampler);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDeleteSamplers(GLsizei count, const GLuint *samplers)
+{
+ d_3_3_Core->DeleteSamplers(count, samplers);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGenSamplers(GLsizei count, GLuint *samplers)
+{
+ d_3_3_Core->GenSamplers(count, samplers);
+}
+
+inline GLint QOpenGLFunctions_4_2_Core::glGetFragDataIndex(GLuint program, const GLchar *name)
+{
+ return d_3_3_Core->GetFragDataIndex(program, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name)
+{
+ d_3_3_Core->BindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribDivisor(GLuint index, GLuint divisor)
+{
+ d_3_3_Core->VertexAttribDivisor(index, divisor);
+}
+
+
+// OpenGL 4.0 core functions
+inline void QOpenGLFunctions_4_2_Core::glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params)
+{
+ d_4_0_Core->GetQueryIndexediv(target, index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glEndQueryIndexed(GLenum target, GLuint index)
+{
+ d_4_0_Core->EndQueryIndexed(target, index);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBeginQueryIndexed(GLenum target, GLuint index, GLuint id)
+{
+ d_4_0_Core->BeginQueryIndexed(target, index, id);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream)
+{
+ d_4_0_Core->DrawTransformFeedbackStream(mode, id, stream);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawTransformFeedback(GLenum mode, GLuint id)
+{
+ d_4_0_Core->DrawTransformFeedback(mode, id);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glResumeTransformFeedback()
+{
+ d_4_0_Core->ResumeTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_2_Core::glPauseTransformFeedback()
+{
+ d_4_0_Core->PauseTransformFeedback();
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsTransformFeedback(GLuint id)
+{
+ return d_4_0_Core->IsTransformFeedback(id);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGenTransformFeedbacks(GLsizei n, GLuint *ids)
+{
+ d_4_0_Core->GenTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids)
+{
+ d_4_0_Core->DeleteTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindTransformFeedback(GLenum target, GLuint id)
+{
+ d_4_0_Core->BindTransformFeedback(target, id);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glPatchParameterfv(GLenum pname, const GLfloat *values)
+{
+ d_4_0_Core->PatchParameterfv(pname, values);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glPatchParameteri(GLenum pname, GLint value)
+{
+ d_4_0_Core->PatchParameteri(pname, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetProgramStageiv(program, shadertype, pname, values);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params)
+{
+ d_4_0_Core->GetUniformSubroutineuiv(shadertype, location, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices)
+{
+ d_4_0_Core->UniformSubroutinesuiv(shadertype, count, indices);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineUniformName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+inline GLuint QOpenGLFunctions_4_2_Core::glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineIndex(program, shadertype, name);
+}
+
+inline GLint QOpenGLFunctions_4_2_Core::glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineUniformLocation(program, shadertype, name);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetUniformdv(GLuint program, GLint location, GLdouble *params)
+{
+ d_4_0_Core->GetUniformdv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform4dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform4dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform3dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform3dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform2dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform2dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform1dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform1dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_0_Core->Uniform4d(location, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_0_Core->Uniform3d(location, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform2d(GLint location, GLdouble x, GLdouble y)
+{
+ d_4_0_Core->Uniform2d(location, x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUniform1d(GLint location, GLdouble x)
+{
+ d_4_0_Core->Uniform1d(location, x);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawElementsIndirect(mode, type, indirect);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawArraysIndirect(GLenum mode, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawArraysIndirect(mode, indirect);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ d_4_0_Core->BlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBlendFunci(GLuint buf, GLenum src, GLenum dst)
+{
+ d_4_0_Core->BlendFunci(buf, src, dst);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ d_4_0_Core->BlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBlendEquationi(GLuint buf, GLenum mode)
+{
+ d_4_0_Core->BlendEquationi(buf, mode);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMinSampleShading(GLfloat value)
+{
+ d_4_0_Core->MinSampleShading(value);
+}
+
+
+// OpenGL 4.1 core functions
+inline void QOpenGLFunctions_4_2_Core::glGetDoublei_v(GLenum target, GLuint index, GLdouble *data)
+{
+ d_4_1_Core->GetDoublei_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetFloati_v(GLenum target, GLuint index, GLfloat *data)
+{
+ d_4_1_Core->GetFloati_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f)
+{
+ d_4_1_Core->DepthRangeIndexed(index, n, f);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v)
+{
+ d_4_1_Core->DepthRangeArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glScissorIndexedv(GLuint index, const GLint *v)
+{
+ d_4_1_Core->ScissorIndexedv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ d_4_1_Core->ScissorIndexed(index, left, bottom, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glScissorArrayv(GLuint first, GLsizei count, const GLint *v)
+{
+ d_4_1_Core->ScissorArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glViewportIndexedfv(GLuint index, const GLfloat *v)
+{
+ d_4_1_Core->ViewportIndexedfv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ d_4_1_Core->ViewportIndexedf(index, x, y, w, h);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v)
+{
+ d_4_1_Core->ViewportArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_4_1_Core->GetVertexAttribLdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_4_1_Core->VertexAttribLPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribL4dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL4dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribL3dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL3dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribL2dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL2dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribL1dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL1dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_1_Core->VertexAttribL4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_1_Core->VertexAttribL3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_4_1_Core->VertexAttribL2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glVertexAttribL1d(GLuint index, GLdouble x)
+{
+ d_4_1_Core->VertexAttribL1d(index, x);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_4_1_Core->GetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glValidateProgramPipeline(GLuint pipeline)
+{
+ d_4_1_Core->ValidateProgramPipeline(pipeline);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform4uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_4_1_Core->ProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform4dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ d_4_1_Core->ProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform4fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_4_1_Core->ProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform4iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_4_1_Core->ProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform3uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_4_1_Core->ProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform3dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ d_4_1_Core->ProgramUniform3d(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform3fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_4_1_Core->ProgramUniform3f(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform3iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_4_1_Core->ProgramUniform3i(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform2uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ d_4_1_Core->ProgramUniform2ui(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform2dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ d_4_1_Core->ProgramUniform2d(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform2fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ d_4_1_Core->ProgramUniform2f(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform2iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1)
+{
+ d_4_1_Core->ProgramUniform2i(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform1uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform1ui(GLuint program, GLint location, GLuint v0)
+{
+ d_4_1_Core->ProgramUniform1ui(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform1dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform1d(GLuint program, GLint location, GLdouble v0)
+{
+ d_4_1_Core->ProgramUniform1d(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform1fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform1f(GLuint program, GLint location, GLfloat v0)
+{
+ d_4_1_Core->ProgramUniform1f(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform1iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramUniform1i(GLuint program, GLint location, GLint v0)
+{
+ d_4_1_Core->ProgramUniform1i(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params)
+{
+ d_4_1_Core->GetProgramPipelineiv(pipeline, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_2_Core::glIsProgramPipeline(GLuint pipeline)
+{
+ return d_4_1_Core->IsProgramPipeline(pipeline);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGenProgramPipelines(GLsizei n, GLuint *pipelines)
+{
+ d_4_1_Core->GenProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines)
+{
+ d_4_1_Core->DeleteProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindProgramPipeline(GLuint pipeline)
+{
+ d_4_1_Core->BindProgramPipeline(pipeline);
+}
+
+inline GLuint QOpenGLFunctions_4_2_Core::glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings)
+{
+ return d_4_1_Core->CreateShaderProgramv(type, count, strings);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glActiveShaderProgram(GLuint pipeline, GLuint program)
+{
+ d_4_1_Core->ActiveShaderProgram(pipeline, program);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ d_4_1_Core->UseProgramStages(pipeline, stages, program);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramParameteri(GLuint program, GLenum pname, GLint value)
+{
+ d_4_1_Core->ProgramParameteri(program, pname, value);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length)
+{
+ d_4_1_Core->ProgramBinary(program, binaryFormat, binary, length);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary)
+{
+ d_4_1_Core->GetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glClearDepthf(GLfloat dd)
+{
+ d_4_1_Core->ClearDepthf(dd);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDepthRangef(GLfloat n, GLfloat f)
+{
+ d_4_1_Core->DepthRangef(n, f);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision)
+{
+ d_4_1_Core->GetShaderPrecisionFormat(shadertype, precisiontype, range, precision);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length)
+{
+ d_4_1_Core->ShaderBinary(count, shaders, binaryformat, binary, length);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glReleaseShaderCompiler()
+{
+ d_4_1_Core->ReleaseShaderCompiler();
+}
+
+
+// OpenGL 4.2 core functions
+inline void QOpenGLFunctions_4_2_Core::glTexStorage3D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ d_4_2_Core->TexStorage3D(target, levels, internalformat, width, height, depth);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_4_2_Core->TexStorage2D(target, levels, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glTexStorage1D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width)
+{
+ d_4_2_Core->TexStorage1D(target, levels, internalformat, width);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glMemoryBarrier(GLbitfield barriers)
+{
+ d_4_2_Core->MemoryBarrier(barriers);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glBindImageTexture(GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format)
+{
+ d_4_2_Core->BindImageTexture(unit, texture, level, layered, layer, access, format);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetActiveAtomicCounterBufferiv(GLuint program, GLuint bufferIndex, GLenum pname, GLint *params)
+{
+ d_4_2_Core->GetActiveAtomicCounterBufferiv(program, bufferIndex, pname, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glGetInternalformativ(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params)
+{
+ d_4_2_Core->GetInternalformativ(target, internalformat, pname, bufSize, params);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawTransformFeedbackStreamInstanced(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount)
+{
+ d_4_2_Core->DrawTransformFeedbackStreamInstanced(mode, id, stream, instancecount);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawTransformFeedbackInstanced(GLenum mode, GLuint id, GLsizei instancecount)
+{
+ d_4_2_Core->DrawTransformFeedbackInstanced(mode, id, instancecount);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawElementsInstancedBaseVertexBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance)
+{
+ d_4_2_Core->DrawElementsInstancedBaseVertexBaseInstance(mode, count, type, indices, instancecount, basevertex, baseinstance);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawElementsInstancedBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance)
+{
+ d_4_2_Core->DrawElementsInstancedBaseInstance(mode, count, type, indices, instancecount, baseinstance);
+}
+
+inline void QOpenGLFunctions_4_2_Core::glDrawArraysInstancedBaseInstance(GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance)
+{
+ d_4_2_Core->DrawArraysInstancedBaseInstance(mode, first, count, instancecount, baseinstance);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_4_3_compatibility.cpp b/src/gui/opengl/qopenglfunctions_4_3_compatibility.cpp
new file mode 100644
index 0000000000..75bcef1562
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_3_compatibility.cpp
@@ -0,0 +1,415 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_4_3_compatibility.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_4_3_Compatibility
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_4_3_Compatibility class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_4_3_Compatibility::QOpenGLFunctions_4_3_Compatibility()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+ , d_3_2_Core(0)
+ , d_3_3_Core(0)
+ , d_4_0_Core(0)
+ , d_4_1_Core(0)
+ , d_4_2_Core(0)
+ , d_4_3_Core(0)
+ , d_1_0_Deprecated(0)
+ , d_1_1_Deprecated(0)
+ , d_1_2_Deprecated(0)
+ , d_1_3_Deprecated(0)
+ , d_1_4_Deprecated(0)
+ , d_2_0_Deprecated(0)
+ , d_3_0_Deprecated(0)
+{
+}
+
+QOpenGLFunctions_4_3_Compatibility::~QOpenGLFunctions_4_3_Compatibility()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+ if (d_3_2_Core && !d_3_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_2_Core->context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ delete d_3_2_Core;
+ }
+ if (d_3_3_Core && !d_3_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_3_Core->context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ delete d_3_3_Core;
+ }
+ if (d_4_0_Core && !d_4_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_0_Core->context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ delete d_4_0_Core;
+ }
+ if (d_4_1_Core && !d_4_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_1_Core->context, QOpenGLFunctions_4_1_CoreBackend::versionStatus());
+ delete d_4_1_Core;
+ }
+ if (d_4_2_Core && !d_4_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_2_Core->context, QOpenGLFunctions_4_2_CoreBackend::versionStatus());
+ delete d_4_2_Core;
+ }
+ if (d_4_3_Core && !d_4_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_3_Core->context, QOpenGLFunctions_4_3_CoreBackend::versionStatus());
+ delete d_4_3_Core;
+ }
+ if (d_1_0_Deprecated && !d_1_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Deprecated->context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ delete d_1_0_Deprecated;
+ }
+ if (d_1_1_Deprecated && !d_1_1_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Deprecated->context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ delete d_1_1_Deprecated;
+ }
+ if (d_1_2_Deprecated && !d_1_2_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Deprecated->context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ delete d_1_2_Deprecated;
+ }
+ if (d_1_3_Deprecated && !d_1_3_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Deprecated->context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ delete d_1_3_Deprecated;
+ }
+ if (d_1_4_Deprecated && !d_1_4_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Deprecated->context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ delete d_1_4_Deprecated;
+ }
+ if (d_2_0_Deprecated && !d_2_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Deprecated->context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ delete d_2_0_Deprecated;
+ }
+ if (d_3_0_Deprecated && !d_3_0_Deprecated->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Deprecated->context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ delete d_3_0_Deprecated;
+ }
+}
+
+bool QOpenGLFunctions_4_3_Compatibility::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_4_3_Compatibility::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus(), d);
+ }
+ d_3_2_Core = static_cast<QOpenGLFunctions_3_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus(), d);
+ }
+ d_3_3_Core = static_cast<QOpenGLFunctions_3_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus(), d);
+ }
+ d_4_0_Core = static_cast<QOpenGLFunctions_4_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_1_CoreBackend::versionStatus(), d);
+ }
+ d_4_1_Core = static_cast<QOpenGLFunctions_4_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_2_CoreBackend::versionStatus(), d);
+ }
+ d_4_2_Core = static_cast<QOpenGLFunctions_4_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_3_CoreBackend::versionStatus(), d);
+ }
+ d_4_3_Core = static_cast<QOpenGLFunctions_4_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_0_Deprecated = static_cast<QOpenGLFunctions_1_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_1_Deprecated = static_cast<QOpenGLFunctions_1_1_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_2_Deprecated = static_cast<QOpenGLFunctions_1_2_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_3_Deprecated = static_cast<QOpenGLFunctions_1_3_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus(), d);
+ }
+ d_1_4_Deprecated = static_cast<QOpenGLFunctions_1_4_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_2_0_Deprecated = static_cast<QOpenGLFunctions_2_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_DeprecatedBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus(), d);
+ }
+ d_3_0_Deprecated = static_cast<QOpenGLFunctions_3_0_DeprecatedBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_4_3_Compatibility::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(4, 3))
+ return false;
+
+ if (f.profile() == QSurfaceFormat::CoreProfile)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_4_3_Compatibility::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(4, 3);
+ v.setProfile(QSurfaceFormat::CompatibilityProfile);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_4_3_compatibility.h b/src/gui/opengl/qopenglfunctions_4_3_compatibility.h
new file mode 100644
index 0000000000..60be506e6a
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_3_compatibility.h
@@ -0,0 +1,5845 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_4_3_COMPATIBILITY_H
+#define QOPENGLVERSIONFUNCTIONS_4_3_COMPATIBILITY_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_4_3_Compatibility : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_4_3_Compatibility();
+ ~QOpenGLFunctions_4_3_Compatibility();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+ // OpenGL 3.2 core functions
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+ void glProvokingVertex(GLenum mode);
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params);
+ void glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data);
+
+ // OpenGL 3.3 core functions
+ void glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glSecondaryColorP3uiv(GLenum type, const GLuint *color);
+ void glSecondaryColorP3ui(GLenum type, GLuint color);
+ void glColorP4uiv(GLenum type, const GLuint *color);
+ void glColorP4ui(GLenum type, GLuint color);
+ void glColorP3uiv(GLenum type, const GLuint *color);
+ void glColorP3ui(GLenum type, GLuint color);
+ void glNormalP3uiv(GLenum type, const GLuint *coords);
+ void glNormalP3ui(GLenum type, GLuint coords);
+ void glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords);
+ void glTexCoordP4uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP4ui(GLenum type, GLuint coords);
+ void glTexCoordP3uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP3ui(GLenum type, GLuint coords);
+ void glTexCoordP2uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP2ui(GLenum type, GLuint coords);
+ void glTexCoordP1uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP1ui(GLenum type, GLuint coords);
+ void glVertexP4uiv(GLenum type, const GLuint *value);
+ void glVertexP4ui(GLenum type, GLuint value);
+ void glVertexP3uiv(GLenum type, const GLuint *value);
+ void glVertexP3ui(GLenum type, GLuint value);
+ void glVertexP2uiv(GLenum type, const GLuint *value);
+ void glVertexP2ui(GLenum type, GLuint value);
+ void glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params);
+ void glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params);
+ void glQueryCounter(GLuint id, GLenum target);
+ void glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params);
+ void glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params);
+ void glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params);
+ void glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params);
+ void glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param);
+ void glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param);
+ void glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param);
+ void glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameteri(GLuint sampler, GLenum pname, GLint param);
+ void glBindSampler(GLuint unit, GLuint sampler);
+ GLboolean glIsSampler(GLuint sampler);
+ void glDeleteSamplers(GLsizei count, const GLuint *samplers);
+ void glGenSamplers(GLsizei count, GLuint *samplers);
+ GLint glGetFragDataIndex(GLuint program, const GLchar *name);
+ void glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+ void glVertexAttribDivisor(GLuint index, GLuint divisor);
+
+ // OpenGL 4.0 core functions
+ void glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void glEndQueryIndexed(GLenum target, GLuint index);
+ void glBeginQueryIndexed(GLenum target, GLuint index, GLuint id);
+ void glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream);
+ void glDrawTransformFeedback(GLenum mode, GLuint id);
+ void glResumeTransformFeedback();
+ void glPauseTransformFeedback();
+ GLboolean glIsTransformFeedback(GLuint id);
+ void glGenTransformFeedbacks(GLsizei n, GLuint *ids);
+ void glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids);
+ void glBindTransformFeedback(GLenum target, GLuint id);
+ void glPatchParameterfv(GLenum pname, const GLfloat *values);
+ void glPatchParameteri(GLenum pname, GLint value);
+ void glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values);
+ void glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params);
+ void glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices);
+ void glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
+ GLuint glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name);
+ GLint glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name);
+ void glGetUniformdv(GLuint program, GLint location, GLdouble *params);
+ void glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniform4dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform3dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform2dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform1dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void glUniform2d(GLint location, GLdouble x, GLdouble y);
+ void glUniform1d(GLint location, GLdouble x);
+ void glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect);
+ void glDrawArraysIndirect(GLenum mode, const GLvoid *indirect);
+ void glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void glBlendFunci(GLuint buf, GLenum src, GLenum dst);
+ void glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void glBlendEquationi(GLuint buf, GLenum mode);
+ void glMinSampleShading(GLfloat value);
+
+ // OpenGL 4.1 core functions
+ void glGetDoublei_v(GLenum target, GLuint index, GLdouble *data);
+ void glGetFloati_v(GLenum target, GLuint index, GLfloat *data);
+ void glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f);
+ void glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v);
+ void glScissorIndexedv(GLuint index, const GLint *v);
+ void glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+ void glScissorArrayv(GLuint first, GLsizei count, const GLint *v);
+ void glViewportIndexedfv(GLuint index, const GLfloat *v);
+ void glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+ void glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v);
+ void glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params);
+ void glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glVertexAttribL4dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL3dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL2dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL1dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttribL1d(GLuint index, GLdouble x);
+ void glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glValidateProgramPipeline(GLuint pipeline);
+ void glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+ void glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+ void glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+ void glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1);
+ void glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1);
+ void glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1);
+ void glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1);
+ void glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform1ui(GLuint program, GLint location, GLuint v0);
+ void glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform1d(GLuint program, GLint location, GLdouble v0);
+ void glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform1f(GLuint program, GLint location, GLfloat v0);
+ void glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform1i(GLuint program, GLint location, GLint v0);
+ void glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params);
+ GLboolean glIsProgramPipeline(GLuint pipeline);
+ void glGenProgramPipelines(GLsizei n, GLuint *pipelines);
+ void glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines);
+ void glBindProgramPipeline(GLuint pipeline);
+ GLuint glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings);
+ void glActiveShaderProgram(GLuint pipeline, GLuint program);
+ void glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program);
+ void glProgramParameteri(GLuint program, GLenum pname, GLint value);
+ void glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length);
+ void glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+ void glClearDepthf(GLfloat dd);
+ void glDepthRangef(GLfloat n, GLfloat f);
+ void glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision);
+ void glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length);
+ void glReleaseShaderCompiler();
+
+ // OpenGL 4.2 core functions
+ void glTexStorage3D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void glTexStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void glTexStorage1D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void glMemoryBarrier(GLbitfield barriers);
+ void glBindImageTexture(GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
+ void glGetActiveAtomicCounterBufferiv(GLuint program, GLuint bufferIndex, GLenum pname, GLint *params);
+ void glGetInternalformativ(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params);
+ void glDrawTransformFeedbackStreamInstanced(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
+ void glDrawTransformFeedbackInstanced(GLenum mode, GLuint id, GLsizei instancecount);
+ void glDrawElementsInstancedBaseVertexBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
+ void glDrawElementsInstancedBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance);
+ void glDrawArraysInstancedBaseInstance(GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+
+ // OpenGL 4.3 core functions
+ void glTexStorage3DMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexStorage2DMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glTexBufferRange(GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glShaderStorageBlockBinding(GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding);
+ GLint glGetProgramResourceLocationIndex(GLuint program, GLenum programInterface, const GLchar *name);
+ GLint glGetProgramResourceLocation(GLuint program, GLenum programInterface, const GLchar *name);
+ void glGetProgramResourceiv(GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params);
+ void glGetProgramResourceName(GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
+ GLuint glGetProgramResourceIndex(GLuint program, GLenum programInterface, const GLchar *name);
+ void glGetProgramInterfaceiv(GLuint program, GLenum programInterface, GLenum pname, GLint *params);
+ void glMultiDrawElementsIndirect(GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride);
+ void glMultiDrawArraysIndirect(GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride);
+ void glInvalidateSubFramebuffer(GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glInvalidateFramebuffer(GLenum target, GLsizei numAttachments, const GLenum *attachments);
+ void glInvalidateBufferData(GLuint buffer);
+ void glInvalidateBufferSubData(GLuint buffer, GLintptr offset, GLsizeiptr length);
+ void glInvalidateTexImage(GLuint texture, GLint level);
+ void glInvalidateTexSubImage(GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth);
+ void glGetInternalformati64v(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params);
+ void glGetFramebufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glFramebufferParameteri(GLenum target, GLenum pname, GLint param);
+ void glVertexBindingDivisor(GLuint bindingindex, GLuint divisor);
+ void glVertexAttribBinding(GLuint attribindex, GLuint bindingindex);
+ void glVertexAttribLFormat(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void glVertexAttribIFormat(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void glVertexAttribFormat(GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset);
+ void glBindVertexBuffer(GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+ void glTextureView(GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers);
+ void glCopyImageSubData(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 glDispatchComputeIndirect(GLintptr indirect);
+ void glDispatchCompute(GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z);
+ void glClearBufferSubData(GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data);
+ void glClearBufferData(GLenum target, GLenum internalformat, GLenum format, GLenum type, const void *data);
+
+ // OpenGL 1.0 deprecated functions
+ void glTranslatef(GLfloat x, GLfloat y, GLfloat z);
+ void glTranslated(GLdouble x, GLdouble y, GLdouble z);
+ void glScalef(GLfloat x, GLfloat y, GLfloat z);
+ void glScaled(GLdouble x, GLdouble y, GLdouble z);
+ void glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glPushMatrix();
+ void glPopMatrix();
+ void glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMultMatrixd(const GLdouble *m);
+ void glMultMatrixf(const GLfloat *m);
+ void glMatrixMode(GLenum mode);
+ void glLoadMatrixd(const GLdouble *m);
+ void glLoadMatrixf(const GLfloat *m);
+ void glLoadIdentity();
+ void glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean glIsList(GLuint list);
+ void glGetTexGeniv(GLenum coord, GLenum pname, GLint *params);
+ void glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params);
+ void glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params);
+ void glGetTexEnviv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPolygonStipple(GLubyte *mask);
+ void glGetPixelMapusv(GLenum map, GLushort *values);
+ void glGetPixelMapuiv(GLenum map, GLuint *values);
+ void glGetPixelMapfv(GLenum map, GLfloat *values);
+ void glGetMaterialiv(GLenum face, GLenum pname, GLint *params);
+ void glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params);
+ void glGetMapiv(GLenum target, GLenum query, GLint *v);
+ void glGetMapfv(GLenum target, GLenum query, GLfloat *v);
+ void glGetMapdv(GLenum target, GLenum query, GLdouble *v);
+ void glGetLightiv(GLenum light, GLenum pname, GLint *params);
+ void glGetLightfv(GLenum light, GLenum pname, GLfloat *params);
+ void glGetClipPlane(GLenum plane, GLdouble *equation);
+ void glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values);
+ void glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values);
+ void glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values);
+ void glPixelTransferi(GLenum pname, GLint param);
+ void glPixelTransferf(GLenum pname, GLfloat param);
+ void glPixelZoom(GLfloat xfactor, GLfloat yfactor);
+ void glAlphaFunc(GLenum func, GLfloat ref);
+ void glEvalPoint2(GLint i, GLint j);
+ void glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void glEvalPoint1(GLint i);
+ void glEvalMesh1(GLenum mode, GLint i1, GLint i2);
+ void glEvalCoord2fv(const GLfloat *u);
+ void glEvalCoord2f(GLfloat u, GLfloat v);
+ void glEvalCoord2dv(const GLdouble *u);
+ void glEvalCoord2d(GLdouble u, GLdouble v);
+ void glEvalCoord1fv(const GLfloat *u);
+ void glEvalCoord1f(GLfloat u);
+ void glEvalCoord1dv(const GLdouble *u);
+ void glEvalCoord1d(GLdouble u);
+ void glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void glMapGrid1f(GLint un, GLfloat u1, GLfloat u2);
+ void glMapGrid1d(GLint un, GLdouble u1, GLdouble u2);
+ void glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void glPushAttrib(GLbitfield mask);
+ void glPopAttrib();
+ void glAccum(GLenum op, GLfloat value);
+ void glIndexMask(GLuint mask);
+ void glClearIndex(GLfloat c);
+ void glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glPushName(GLuint name);
+ void glPopName();
+ void glPassThrough(GLfloat token);
+ void glLoadName(GLuint name);
+ void glInitNames();
+ GLint glRenderMode(GLenum mode);
+ void glSelectBuffer(GLsizei size, GLuint *buffer);
+ void glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer);
+ void glTexGeniv(GLenum coord, GLenum pname, const GLint *params);
+ void glTexGeni(GLenum coord, GLenum pname, GLint param);
+ void glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params);
+ void glTexGenf(GLenum coord, GLenum pname, GLfloat param);
+ void glTexGendv(GLenum coord, GLenum pname, const GLdouble *params);
+ void glTexGend(GLenum coord, GLenum pname, GLdouble param);
+ void glTexEnviv(GLenum target, GLenum pname, const GLint *params);
+ void glTexEnvi(GLenum target, GLenum pname, GLint param);
+ void glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexEnvf(GLenum target, GLenum pname, GLfloat param);
+ void glShadeModel(GLenum mode);
+ void glPolygonStipple(const GLubyte *mask);
+ void glMaterialiv(GLenum face, GLenum pname, const GLint *params);
+ void glMateriali(GLenum face, GLenum pname, GLint param);
+ void glMaterialfv(GLenum face, GLenum pname, const GLfloat *params);
+ void glMaterialf(GLenum face, GLenum pname, GLfloat param);
+ void glLineStipple(GLint factor, GLushort pattern);
+ void glLightModeliv(GLenum pname, const GLint *params);
+ void glLightModeli(GLenum pname, GLint param);
+ void glLightModelfv(GLenum pname, const GLfloat *params);
+ void glLightModelf(GLenum pname, GLfloat param);
+ void glLightiv(GLenum light, GLenum pname, const GLint *params);
+ void glLighti(GLenum light, GLenum pname, GLint param);
+ void glLightfv(GLenum light, GLenum pname, const GLfloat *params);
+ void glLightf(GLenum light, GLenum pname, GLfloat param);
+ void glFogiv(GLenum pname, const GLint *params);
+ void glFogi(GLenum pname, GLint param);
+ void glFogfv(GLenum pname, const GLfloat *params);
+ void glFogf(GLenum pname, GLfloat param);
+ void glColorMaterial(GLenum face, GLenum mode);
+ void glClipPlane(GLenum plane, const GLdouble *equation);
+ void glVertex4sv(const GLshort *v);
+ void glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertex4iv(const GLint *v);
+ void glVertex4i(GLint x, GLint y, GLint z, GLint w);
+ void glVertex4fv(const GLfloat *v);
+ void glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertex4dv(const GLdouble *v);
+ void glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertex3sv(const GLshort *v);
+ void glVertex3s(GLshort x, GLshort y, GLshort z);
+ void glVertex3iv(const GLint *v);
+ void glVertex3i(GLint x, GLint y, GLint z);
+ void glVertex3fv(const GLfloat *v);
+ void glVertex3f(GLfloat x, GLfloat y, GLfloat z);
+ void glVertex3dv(const GLdouble *v);
+ void glVertex3d(GLdouble x, GLdouble y, GLdouble z);
+ void glVertex2sv(const GLshort *v);
+ void glVertex2s(GLshort x, GLshort y);
+ void glVertex2iv(const GLint *v);
+ void glVertex2i(GLint x, GLint y);
+ void glVertex2fv(const GLfloat *v);
+ void glVertex2f(GLfloat x, GLfloat y);
+ void glVertex2dv(const GLdouble *v);
+ void glVertex2d(GLdouble x, GLdouble y);
+ void glTexCoord4sv(const GLshort *v);
+ void glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q);
+ void glTexCoord4iv(const GLint *v);
+ void glTexCoord4i(GLint s, GLint t, GLint r, GLint q);
+ void glTexCoord4fv(const GLfloat *v);
+ void glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glTexCoord4dv(const GLdouble *v);
+ void glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glTexCoord3sv(const GLshort *v);
+ void glTexCoord3s(GLshort s, GLshort t, GLshort r);
+ void glTexCoord3iv(const GLint *v);
+ void glTexCoord3i(GLint s, GLint t, GLint r);
+ void glTexCoord3fv(const GLfloat *v);
+ void glTexCoord3f(GLfloat s, GLfloat t, GLfloat r);
+ void glTexCoord3dv(const GLdouble *v);
+ void glTexCoord3d(GLdouble s, GLdouble t, GLdouble r);
+ void glTexCoord2sv(const GLshort *v);
+ void glTexCoord2s(GLshort s, GLshort t);
+ void glTexCoord2iv(const GLint *v);
+ void glTexCoord2i(GLint s, GLint t);
+ void glTexCoord2fv(const GLfloat *v);
+ void glTexCoord2f(GLfloat s, GLfloat t);
+ void glTexCoord2dv(const GLdouble *v);
+ void glTexCoord2d(GLdouble s, GLdouble t);
+ void glTexCoord1sv(const GLshort *v);
+ void glTexCoord1s(GLshort s);
+ void glTexCoord1iv(const GLint *v);
+ void glTexCoord1i(GLint s);
+ void glTexCoord1fv(const GLfloat *v);
+ void glTexCoord1f(GLfloat s);
+ void glTexCoord1dv(const GLdouble *v);
+ void glTexCoord1d(GLdouble s);
+ void glRectsv(const GLshort *v1, const GLshort *v2);
+ void glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void glRectiv(const GLint *v1, const GLint *v2);
+ void glRecti(GLint x1, GLint y1, GLint x2, GLint y2);
+ void glRectfv(const GLfloat *v1, const GLfloat *v2);
+ void glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void glRectdv(const GLdouble *v1, const GLdouble *v2);
+ void glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void glRasterPos4sv(const GLshort *v);
+ void glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glRasterPos4iv(const GLint *v);
+ void glRasterPos4i(GLint x, GLint y, GLint z, GLint w);
+ void glRasterPos4fv(const GLfloat *v);
+ void glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glRasterPos4dv(const GLdouble *v);
+ void glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glRasterPos3sv(const GLshort *v);
+ void glRasterPos3s(GLshort x, GLshort y, GLshort z);
+ void glRasterPos3iv(const GLint *v);
+ void glRasterPos3i(GLint x, GLint y, GLint z);
+ void glRasterPos3fv(const GLfloat *v);
+ void glRasterPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glRasterPos3dv(const GLdouble *v);
+ void glRasterPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glRasterPos2sv(const GLshort *v);
+ void glRasterPos2s(GLshort x, GLshort y);
+ void glRasterPos2iv(const GLint *v);
+ void glRasterPos2i(GLint x, GLint y);
+ void glRasterPos2fv(const GLfloat *v);
+ void glRasterPos2f(GLfloat x, GLfloat y);
+ void glRasterPos2dv(const GLdouble *v);
+ void glRasterPos2d(GLdouble x, GLdouble y);
+ void glNormal3sv(const GLshort *v);
+ void glNormal3s(GLshort nx, GLshort ny, GLshort nz);
+ void glNormal3iv(const GLint *v);
+ void glNormal3i(GLint nx, GLint ny, GLint nz);
+ void glNormal3fv(const GLfloat *v);
+ void glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormal3dv(const GLdouble *v);
+ void glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormal3bv(const GLbyte *v);
+ void glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz);
+ void glIndexsv(const GLshort *c);
+ void glIndexs(GLshort c);
+ void glIndexiv(const GLint *c);
+ void glIndexi(GLint c);
+ void glIndexfv(const GLfloat *c);
+ void glIndexf(GLfloat c);
+ void glIndexdv(const GLdouble *c);
+ void glIndexd(GLdouble c);
+ void glEnd();
+ void glEdgeFlagv(const GLboolean *flag);
+ void glEdgeFlag(GLboolean flag);
+ void glColor4usv(const GLushort *v);
+ void glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void glColor4uiv(const GLuint *v);
+ void glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glColor4ubv(const GLubyte *v);
+ void glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void glColor4sv(const GLshort *v);
+ void glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void glColor4iv(const GLint *v);
+ void glColor4i(GLint red, GLint green, GLint blue, GLint alpha);
+ void glColor4fv(const GLfloat *v);
+ void glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glColor4dv(const GLdouble *v);
+ void glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void glColor4bv(const GLbyte *v);
+ void glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void glColor3usv(const GLushort *v);
+ void glColor3us(GLushort red, GLushort green, GLushort blue);
+ void glColor3uiv(const GLuint *v);
+ void glColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glColor3ubv(const GLubyte *v);
+ void glColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glColor3sv(const GLshort *v);
+ void glColor3s(GLshort red, GLshort green, GLshort blue);
+ void glColor3iv(const GLint *v);
+ void glColor3i(GLint red, GLint green, GLint blue);
+ void glColor3fv(const GLfloat *v);
+ void glColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glColor3dv(const GLdouble *v);
+ void glColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glColor3bv(const GLbyte *v);
+ void glColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void glBegin(GLenum mode);
+ void glListBase(GLuint base);
+ GLuint glGenLists(GLsizei range);
+ void glDeleteLists(GLuint list, GLsizei range);
+ void glCallLists(GLsizei n, GLenum type, const GLvoid *lists);
+ void glCallList(GLuint list);
+ void glEndList();
+ void glNewList(GLuint list, GLenum mode);
+
+ // OpenGL 1.1 deprecated functions
+ void glPushClientAttrib(GLbitfield mask);
+ void glPopClientAttrib();
+ void glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEnableClientState(GLenum array);
+ void glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer);
+ void glDisableClientState(GLenum array);
+ void glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glArrayElement(GLint i);
+
+ // OpenGL 1.2 deprecated functions
+ void glResetMinmax(GLenum target);
+ void glResetHistogram(GLenum target);
+ void glMinmax(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteri(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+ // OpenGL 1.3 deprecated functions
+ void glMultTransposeMatrixd(const GLdouble *m);
+ void glMultTransposeMatrixf(const GLfloat *m);
+ void glLoadTransposeMatrixd(const GLdouble *m);
+ void glLoadTransposeMatrixf(const GLfloat *m);
+ void glMultiTexCoord4sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4iv(GLenum target, const GLint *v);
+ void glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3iv(GLenum target, const GLint *v);
+ void glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord2s(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2iv(GLenum target, const GLint *v);
+ void glMultiTexCoord2i(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1sv(GLenum target, const GLshort *v);
+ void glMultiTexCoord1s(GLenum target, GLshort s);
+ void glMultiTexCoord1iv(GLenum target, const GLint *v);
+ void glMultiTexCoord1i(GLenum target, GLint s);
+ void glMultiTexCoord1fv(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1f(GLenum target, GLfloat s);
+ void glMultiTexCoord1dv(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1d(GLenum target, GLdouble s);
+ void glClientActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 deprecated functions
+ void glWindowPos3sv(const GLshort *v);
+ void glWindowPos3s(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3iv(const GLint *v);
+ void glWindowPos3i(GLint x, GLint y, GLint z);
+ void glWindowPos3fv(const GLfloat *v);
+ void glWindowPos3f(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dv(const GLdouble *v);
+ void glWindowPos3d(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2sv(const GLshort *v);
+ void glWindowPos2s(GLshort x, GLshort y);
+ void glWindowPos2iv(const GLint *v);
+ void glWindowPos2i(GLint x, GLint y);
+ void glWindowPos2fv(const GLfloat *v);
+ void glWindowPos2f(GLfloat x, GLfloat y);
+ void glWindowPos2dv(const GLdouble *v);
+ void glWindowPos2d(GLdouble x, GLdouble y);
+ void glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glSecondaryColor3usv(const GLushort *v);
+ void glSecondaryColor3us(GLushort red, GLushort green, GLushort blue);
+ void glSecondaryColor3uiv(const GLuint *v);
+ void glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue);
+ void glSecondaryColor3ubv(const GLubyte *v);
+ void glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue);
+ void glSecondaryColor3sv(const GLshort *v);
+ void glSecondaryColor3s(GLshort red, GLshort green, GLshort blue);
+ void glSecondaryColor3iv(const GLint *v);
+ void glSecondaryColor3i(GLint red, GLint green, GLint blue);
+ void glSecondaryColor3fv(const GLfloat *v);
+ void glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue);
+ void glSecondaryColor3dv(const GLdouble *v);
+ void glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue);
+ void glSecondaryColor3bv(const GLbyte *v);
+ void glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue);
+ void glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glFogCoorddv(const GLdouble *coord);
+ void glFogCoordd(GLdouble coord);
+ void glFogCoordfv(const GLfloat *coord);
+ void glFogCoordf(GLfloat coord);
+
+ // OpenGL 1.5 deprecated functions
+
+ // OpenGL 2.0 deprecated functions
+ void glVertexAttrib4usv(GLuint index, const GLushort *v);
+ void glVertexAttrib4uiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4sv(GLuint index, const GLshort *v);
+ void glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertexAttrib4iv(GLuint index, const GLint *v);
+ void glVertexAttrib4fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexAttrib4dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttrib4bv(GLuint index, const GLbyte *v);
+ void glVertexAttrib4Nusv(GLuint index, const GLushort *v);
+ void glVertexAttrib4Nuiv(GLuint index, const GLuint *v);
+ void glVertexAttrib4Nubv(GLuint index, const GLubyte *v);
+ void glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void glVertexAttrib4Nsv(GLuint index, const GLshort *v);
+ void glVertexAttrib4Niv(GLuint index, const GLint *v);
+ void glVertexAttrib4Nbv(GLuint index, const GLbyte *v);
+ void glVertexAttrib3sv(GLuint index, const GLshort *v);
+ void glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z);
+ void glVertexAttrib3fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexAttrib3dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttrib2sv(GLuint index, const GLshort *v);
+ void glVertexAttrib2s(GLuint index, GLshort x, GLshort y);
+ void glVertexAttrib2fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y);
+ void glVertexAttrib2dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttrib1sv(GLuint index, const GLshort *v);
+ void glVertexAttrib1s(GLuint index, GLshort x);
+ void glVertexAttrib1fv(GLuint index, const GLfloat *v);
+ void glVertexAttrib1f(GLuint index, GLfloat x);
+ void glVertexAttrib1dv(GLuint index, const GLdouble *v);
+ void glVertexAttrib1d(GLuint index, GLdouble x);
+
+ // OpenGL 2.1 deprecated functions
+
+ // OpenGL 3.0 deprecated functions
+ void glVertexAttribI4usv(GLuint index, const GLushort *v);
+ void glVertexAttribI4ubv(GLuint index, const GLubyte *v);
+ void glVertexAttribI4sv(GLuint index, const GLshort *v);
+ void glVertexAttribI4bv(GLuint index, const GLbyte *v);
+ void glVertexAttribI4uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI3uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI2uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI1uiv(GLuint index, const GLuint *v);
+ void glVertexAttribI4iv(GLuint index, const GLint *v);
+ void glVertexAttribI3iv(GLuint index, const GLint *v);
+ void glVertexAttribI2iv(GLuint index, const GLint *v);
+ void glVertexAttribI1iv(GLuint index, const GLint *v);
+ void glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z);
+ void glVertexAttribI2ui(GLuint index, GLuint x, GLuint y);
+ void glVertexAttribI1ui(GLuint index, GLuint x);
+ void glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z);
+ void glVertexAttribI2i(GLuint index, GLint x, GLint y);
+ void glVertexAttribI1i(GLuint index, GLint x);
+
+ // OpenGL 3.1 deprecated functions
+
+ // OpenGL 3.2 deprecated functions
+
+ // OpenGL 3.3 deprecated functions
+
+ // OpenGL 4.0 deprecated functions
+
+ // OpenGL 4.1 deprecated functions
+
+ // OpenGL 4.2 deprecated functions
+
+ // OpenGL 4.3 deprecated functions
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+ QOpenGLFunctions_3_2_CoreBackend* d_3_2_Core;
+ QOpenGLFunctions_3_3_CoreBackend* d_3_3_Core;
+ QOpenGLFunctions_4_0_CoreBackend* d_4_0_Core;
+ QOpenGLFunctions_4_1_CoreBackend* d_4_1_Core;
+ QOpenGLFunctions_4_2_CoreBackend* d_4_2_Core;
+ QOpenGLFunctions_4_3_CoreBackend* d_4_3_Core;
+ QOpenGLFunctions_1_0_DeprecatedBackend* d_1_0_Deprecated;
+ QOpenGLFunctions_1_1_DeprecatedBackend* d_1_1_Deprecated;
+ QOpenGLFunctions_1_2_DeprecatedBackend* d_1_2_Deprecated;
+ QOpenGLFunctions_1_3_DeprecatedBackend* d_1_3_Deprecated;
+ QOpenGLFunctions_1_4_DeprecatedBackend* d_1_4_Deprecated;
+ QOpenGLFunctions_2_0_DeprecatedBackend* d_2_0_Deprecated;
+ QOpenGLFunctions_3_0_DeprecatedBackend* d_3_0_Deprecated;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_3_Compatibility::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_4_3_Compatibility::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_4_3_Compatibility::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_4_3_Compatibility::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_4_3_Compatibility::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Compatibility::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Compatibility::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_4_3_Compatibility::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_4_3_Compatibility::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_3_Compatibility::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_4_3_Compatibility::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Compatibility::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+// OpenGL 3.2 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ d_3_2_Core->SampleMaski(index, mask);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ d_3_2_Core->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ d_3_2_Core->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ d_3_2_Core->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLFunctions_4_3_Compatibility::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ return d_3_2_Core->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteSync(GLsync sync)
+{
+ d_3_2_Core->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsSync(GLsync sync)
+{
+ return d_3_2_Core->IsSync(sync);
+}
+
+inline GLsync QOpenGLFunctions_4_3_Compatibility::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ return d_3_2_Core->FenceSync(condition, flags);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProvokingVertex(GLenum mode)
+{
+ d_3_2_Core->ProvokingVertex(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ d_3_2_Core->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ d_3_2_Core->FramebufferTexture(target, attachment, texture, level);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetBufferParameteri64v(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data)
+{
+ d_3_2_Core->GetInteger64i_v(target, index, data);
+}
+
+
+// OpenGL 3.3 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP4uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP4ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP3uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP3ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP2uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP2ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP1uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP1ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->SecondaryColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->SecondaryColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColorP4uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP4uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColorP4ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP4ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormalP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->NormalP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormalP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->NormalP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP4uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP4ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP3uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP3ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP2uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP2ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP1uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP1ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoordP4uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP4uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoordP4ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP4ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoordP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoordP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoordP2uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP2uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoordP2ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP2ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoordP1uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP1uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoordP1ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP1ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexP4uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP4uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexP4ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP4ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexP3uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP3uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexP3ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP3ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexP2uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP2uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexP2ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP2ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params)
+{
+ d_3_3_Core->GetQueryObjectui64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params)
+{
+ d_3_3_Core->GetQueryObjecti64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glQueryCounter(GLuint id, GLenum target)
+{
+ d_3_3_Core->QueryCounter(id, target);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params)
+{
+ d_3_3_Core->GetSamplerParameterIuiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params)
+{
+ d_3_3_Core->GetSamplerParameterfv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameterIiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameteriv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ d_3_3_Core->SamplerParameterIuiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameterIiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param)
+{
+ d_3_3_Core->SamplerParameterfv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param)
+{
+ d_3_3_Core->SamplerParameterf(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameteriv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSamplerParameteri(GLuint sampler, GLenum pname, GLint param)
+{
+ d_3_3_Core->SamplerParameteri(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindSampler(GLuint unit, GLuint sampler)
+{
+ d_3_3_Core->BindSampler(unit, sampler);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsSampler(GLuint sampler)
+{
+ return d_3_3_Core->IsSampler(sampler);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteSamplers(GLsizei count, const GLuint *samplers)
+{
+ d_3_3_Core->DeleteSamplers(count, samplers);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGenSamplers(GLsizei count, GLuint *samplers)
+{
+ d_3_3_Core->GenSamplers(count, samplers);
+}
+
+inline GLint QOpenGLFunctions_4_3_Compatibility::glGetFragDataIndex(GLuint program, const GLchar *name)
+{
+ return d_3_3_Core->GetFragDataIndex(program, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name)
+{
+ d_3_3_Core->BindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribDivisor(GLuint index, GLuint divisor)
+{
+ d_3_3_Core->VertexAttribDivisor(index, divisor);
+}
+
+
+// OpenGL 4.0 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params)
+{
+ d_4_0_Core->GetQueryIndexediv(target, index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEndQueryIndexed(GLenum target, GLuint index)
+{
+ d_4_0_Core->EndQueryIndexed(target, index);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBeginQueryIndexed(GLenum target, GLuint index, GLuint id)
+{
+ d_4_0_Core->BeginQueryIndexed(target, index, id);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream)
+{
+ d_4_0_Core->DrawTransformFeedbackStream(mode, id, stream);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawTransformFeedback(GLenum mode, GLuint id)
+{
+ d_4_0_Core->DrawTransformFeedback(mode, id);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glResumeTransformFeedback()
+{
+ d_4_0_Core->ResumeTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPauseTransformFeedback()
+{
+ d_4_0_Core->PauseTransformFeedback();
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsTransformFeedback(GLuint id)
+{
+ return d_4_0_Core->IsTransformFeedback(id);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGenTransformFeedbacks(GLsizei n, GLuint *ids)
+{
+ d_4_0_Core->GenTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids)
+{
+ d_4_0_Core->DeleteTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindTransformFeedback(GLenum target, GLuint id)
+{
+ d_4_0_Core->BindTransformFeedback(target, id);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPatchParameterfv(GLenum pname, const GLfloat *values)
+{
+ d_4_0_Core->PatchParameterfv(pname, values);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPatchParameteri(GLenum pname, GLint value)
+{
+ d_4_0_Core->PatchParameteri(pname, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetProgramStageiv(program, shadertype, pname, values);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params)
+{
+ d_4_0_Core->GetUniformSubroutineuiv(shadertype, location, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices)
+{
+ d_4_0_Core->UniformSubroutinesuiv(shadertype, count, indices);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineUniformName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Compatibility::glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineIndex(program, shadertype, name);
+}
+
+inline GLint QOpenGLFunctions_4_3_Compatibility::glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineUniformLocation(program, shadertype, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetUniformdv(GLuint program, GLint location, GLdouble *params)
+{
+ d_4_0_Core->GetUniformdv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform4dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform4dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform3dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform3dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform2dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform2dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform1dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform1dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_0_Core->Uniform4d(location, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_0_Core->Uniform3d(location, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform2d(GLint location, GLdouble x, GLdouble y)
+{
+ d_4_0_Core->Uniform2d(location, x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUniform1d(GLint location, GLdouble x)
+{
+ d_4_0_Core->Uniform1d(location, x);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawElementsIndirect(mode, type, indirect);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawArraysIndirect(GLenum mode, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawArraysIndirect(mode, indirect);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ d_4_0_Core->BlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBlendFunci(GLuint buf, GLenum src, GLenum dst)
+{
+ d_4_0_Core->BlendFunci(buf, src, dst);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ d_4_0_Core->BlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBlendEquationi(GLuint buf, GLenum mode)
+{
+ d_4_0_Core->BlendEquationi(buf, mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMinSampleShading(GLfloat value)
+{
+ d_4_0_Core->MinSampleShading(value);
+}
+
+
+// OpenGL 4.1 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glGetDoublei_v(GLenum target, GLuint index, GLdouble *data)
+{
+ d_4_1_Core->GetDoublei_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetFloati_v(GLenum target, GLuint index, GLfloat *data)
+{
+ d_4_1_Core->GetFloati_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f)
+{
+ d_4_1_Core->DepthRangeIndexed(index, n, f);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v)
+{
+ d_4_1_Core->DepthRangeArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glScissorIndexedv(GLuint index, const GLint *v)
+{
+ d_4_1_Core->ScissorIndexedv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ d_4_1_Core->ScissorIndexed(index, left, bottom, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glScissorArrayv(GLuint first, GLsizei count, const GLint *v)
+{
+ d_4_1_Core->ScissorArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glViewportIndexedfv(GLuint index, const GLfloat *v)
+{
+ d_4_1_Core->ViewportIndexedfv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ d_4_1_Core->ViewportIndexedf(index, x, y, w, h);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v)
+{
+ d_4_1_Core->ViewportArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_4_1_Core->GetVertexAttribLdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_4_1_Core->VertexAttribLPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribL4dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL4dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribL3dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL3dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribL2dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL2dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribL1dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL1dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_1_Core->VertexAttribL4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_1_Core->VertexAttribL3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_4_1_Core->VertexAttribL2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribL1d(GLuint index, GLdouble x)
+{
+ d_4_1_Core->VertexAttribL1d(index, x);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_4_1_Core->GetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glValidateProgramPipeline(GLuint pipeline)
+{
+ d_4_1_Core->ValidateProgramPipeline(pipeline);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform4uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_4_1_Core->ProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform4dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ d_4_1_Core->ProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform4fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_4_1_Core->ProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform4iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_4_1_Core->ProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform3uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_4_1_Core->ProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform3dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ d_4_1_Core->ProgramUniform3d(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform3fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_4_1_Core->ProgramUniform3f(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform3iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_4_1_Core->ProgramUniform3i(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform2uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ d_4_1_Core->ProgramUniform2ui(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform2dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ d_4_1_Core->ProgramUniform2d(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform2fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ d_4_1_Core->ProgramUniform2f(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform2iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1)
+{
+ d_4_1_Core->ProgramUniform2i(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform1uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform1ui(GLuint program, GLint location, GLuint v0)
+{
+ d_4_1_Core->ProgramUniform1ui(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform1dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform1d(GLuint program, GLint location, GLdouble v0)
+{
+ d_4_1_Core->ProgramUniform1d(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform1fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform1f(GLuint program, GLint location, GLfloat v0)
+{
+ d_4_1_Core->ProgramUniform1f(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform1iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramUniform1i(GLuint program, GLint location, GLint v0)
+{
+ d_4_1_Core->ProgramUniform1i(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params)
+{
+ d_4_1_Core->GetProgramPipelineiv(pipeline, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsProgramPipeline(GLuint pipeline)
+{
+ return d_4_1_Core->IsProgramPipeline(pipeline);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGenProgramPipelines(GLsizei n, GLuint *pipelines)
+{
+ d_4_1_Core->GenProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines)
+{
+ d_4_1_Core->DeleteProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindProgramPipeline(GLuint pipeline)
+{
+ d_4_1_Core->BindProgramPipeline(pipeline);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Compatibility::glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings)
+{
+ return d_4_1_Core->CreateShaderProgramv(type, count, strings);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glActiveShaderProgram(GLuint pipeline, GLuint program)
+{
+ d_4_1_Core->ActiveShaderProgram(pipeline, program);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ d_4_1_Core->UseProgramStages(pipeline, stages, program);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramParameteri(GLuint program, GLenum pname, GLint value)
+{
+ d_4_1_Core->ProgramParameteri(program, pname, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length)
+{
+ d_4_1_Core->ProgramBinary(program, binaryFormat, binary, length);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary)
+{
+ d_4_1_Core->GetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClearDepthf(GLfloat dd)
+{
+ d_4_1_Core->ClearDepthf(dd);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDepthRangef(GLfloat n, GLfloat f)
+{
+ d_4_1_Core->DepthRangef(n, f);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision)
+{
+ d_4_1_Core->GetShaderPrecisionFormat(shadertype, precisiontype, range, precision);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length)
+{
+ d_4_1_Core->ShaderBinary(count, shaders, binaryformat, binary, length);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glReleaseShaderCompiler()
+{
+ d_4_1_Core->ReleaseShaderCompiler();
+}
+
+
+// OpenGL 4.2 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glTexStorage3D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ d_4_2_Core->TexStorage3D(target, levels, internalformat, width, height, depth);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_4_2_Core->TexStorage2D(target, levels, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexStorage1D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width)
+{
+ d_4_2_Core->TexStorage1D(target, levels, internalformat, width);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMemoryBarrier(GLbitfield barriers)
+{
+ d_4_2_Core->MemoryBarrier(barriers);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindImageTexture(GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format)
+{
+ d_4_2_Core->BindImageTexture(unit, texture, level, layered, layer, access, format);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetActiveAtomicCounterBufferiv(GLuint program, GLuint bufferIndex, GLenum pname, GLint *params)
+{
+ d_4_2_Core->GetActiveAtomicCounterBufferiv(program, bufferIndex, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetInternalformativ(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params)
+{
+ d_4_2_Core->GetInternalformativ(target, internalformat, pname, bufSize, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawTransformFeedbackStreamInstanced(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount)
+{
+ d_4_2_Core->DrawTransformFeedbackStreamInstanced(mode, id, stream, instancecount);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawTransformFeedbackInstanced(GLenum mode, GLuint id, GLsizei instancecount)
+{
+ d_4_2_Core->DrawTransformFeedbackInstanced(mode, id, instancecount);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawElementsInstancedBaseVertexBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance)
+{
+ d_4_2_Core->DrawElementsInstancedBaseVertexBaseInstance(mode, count, type, indices, instancecount, basevertex, baseinstance);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawElementsInstancedBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance)
+{
+ d_4_2_Core->DrawElementsInstancedBaseInstance(mode, count, type, indices, instancecount, baseinstance);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawArraysInstancedBaseInstance(GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance)
+{
+ d_4_2_Core->DrawArraysInstancedBaseInstance(mode, first, count, instancecount, baseinstance);
+}
+
+
+// OpenGL 4.3 core functions
+inline void QOpenGLFunctions_4_3_Compatibility::glTexStorage3DMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_4_3_Core->TexStorage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexStorage2DMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_4_3_Core->TexStorage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexBufferRange(GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_4_3_Core->TexBufferRange(target, internalformat, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glShaderStorageBlockBinding(GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding)
+{
+ d_4_3_Core->ShaderStorageBlockBinding(program, storageBlockIndex, storageBlockBinding);
+}
+
+inline GLint QOpenGLFunctions_4_3_Compatibility::glGetProgramResourceLocationIndex(GLuint program, GLenum programInterface, const GLchar *name)
+{
+ return d_4_3_Core->GetProgramResourceLocationIndex(program, programInterface, name);
+}
+
+inline GLint QOpenGLFunctions_4_3_Compatibility::glGetProgramResourceLocation(GLuint program, GLenum programInterface, const GLchar *name)
+{
+ return d_4_3_Core->GetProgramResourceLocation(program, programInterface, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetProgramResourceiv(GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params)
+{
+ d_4_3_Core->GetProgramResourceiv(program, programInterface, index, propCount, props, bufSize, length, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetProgramResourceName(GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name)
+{
+ d_4_3_Core->GetProgramResourceName(program, programInterface, index, bufSize, length, name);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Compatibility::glGetProgramResourceIndex(GLuint program, GLenum programInterface, const GLchar *name)
+{
+ return d_4_3_Core->GetProgramResourceIndex(program, programInterface, name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetProgramInterfaceiv(GLuint program, GLenum programInterface, GLenum pname, GLint *params)
+{
+ d_4_3_Core->GetProgramInterfaceiv(program, programInterface, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiDrawElementsIndirect(GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride)
+{
+ d_4_3_Core->MultiDrawElementsIndirect(mode, type, indirect, drawcount, stride);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiDrawArraysIndirect(GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride)
+{
+ d_4_3_Core->MultiDrawArraysIndirect(mode, indirect, drawcount, stride);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glInvalidateSubFramebuffer(GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_4_3_Core->InvalidateSubFramebuffer(target, numAttachments, attachments, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glInvalidateFramebuffer(GLenum target, GLsizei numAttachments, const GLenum *attachments)
+{
+ d_4_3_Core->InvalidateFramebuffer(target, numAttachments, attachments);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glInvalidateBufferData(GLuint buffer)
+{
+ d_4_3_Core->InvalidateBufferData(buffer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glInvalidateBufferSubData(GLuint buffer, GLintptr offset, GLsizeiptr length)
+{
+ d_4_3_Core->InvalidateBufferSubData(buffer, offset, length);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glInvalidateTexImage(GLuint texture, GLint level)
+{
+ d_4_3_Core->InvalidateTexImage(texture, level);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glInvalidateTexSubImage(GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth)
+{
+ d_4_3_Core->InvalidateTexSubImage(texture, level, xoffset, yoffset, zoffset, width, height, depth);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetInternalformati64v(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params)
+{
+ d_4_3_Core->GetInternalformati64v(target, internalformat, pname, bufSize, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetFramebufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_4_3_Core->GetFramebufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFramebufferParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_4_3_Core->FramebufferParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexBindingDivisor(GLuint bindingindex, GLuint divisor)
+{
+ d_4_3_Core->VertexBindingDivisor(bindingindex, divisor);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribBinding(GLuint attribindex, GLuint bindingindex)
+{
+ d_4_3_Core->VertexAttribBinding(attribindex, bindingindex);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribLFormat(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset)
+{
+ d_4_3_Core->VertexAttribLFormat(attribindex, size, type, relativeoffset);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribIFormat(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset)
+{
+ d_4_3_Core->VertexAttribIFormat(attribindex, size, type, relativeoffset);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribFormat(GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset)
+{
+ d_4_3_Core->VertexAttribFormat(attribindex, size, type, normalized, relativeoffset);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBindVertexBuffer(GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride)
+{
+ d_4_3_Core->BindVertexBuffer(bindingindex, buffer, offset, stride);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTextureView(GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers)
+{
+ d_4_3_Core->TextureView(texture, target, origtexture, internalformat, minlevel, numlevels, minlayer, numlayers);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCopyImageSubData(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)
+{
+ d_4_3_Core->CopyImageSubData(srcName, srcTarget, srcLevel, srcX, srcY, srcZ, dstName, dstTarget, dstLevel, dstX, dstY, dstZ, srcWidth, srcHeight, srcDepth);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDispatchComputeIndirect(GLintptr indirect)
+{
+ d_4_3_Core->DispatchComputeIndirect(indirect);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDispatchCompute(GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z)
+{
+ d_4_3_Core->DispatchCompute(num_groups_x, num_groups_y, num_groups_z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClearBufferSubData(GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data)
+{
+ d_4_3_Core->ClearBufferSubData(target, internalformat, offset, size, format, type, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClearBufferData(GLenum target, GLenum internalformat, GLenum format, GLenum type, const void *data)
+{
+ d_4_3_Core->ClearBufferData(target, internalformat, format, type, data);
+}
+
+
+// OpenGL 1.0 deprecated functions
+inline void QOpenGLFunctions_4_3_Compatibility::glTranslatef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Translatef(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTranslated(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Translated(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glScalef(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Scalef(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glScaled(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Scaled(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRotatef(GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Rotatef(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRotated(GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Rotated(angle, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPushMatrix()
+{
+ d_1_0_Deprecated->PushMatrix();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPopMatrix()
+{
+ d_1_0_Deprecated->PopMatrix();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glOrtho(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Ortho(left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->MultMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->MultMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMatrixMode(GLenum mode)
+{
+ d_1_0_Deprecated->MatrixMode(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLoadMatrixd(const GLdouble *m)
+{
+ d_1_0_Deprecated->LoadMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLoadMatrixf(const GLfloat *m)
+{
+ d_1_0_Deprecated->LoadMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLoadIdentity()
+{
+ d_1_0_Deprecated->LoadIdentity();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFrustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ d_1_0_Deprecated->Frustum(left, right, bottom, top, zNear, zFar);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glIsList(GLuint list)
+{
+ return d_1_0_Deprecated->IsList(list);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTexGeniv(GLenum coord, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTexGenfv(GLenum coord, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTexGendv(GLenum coord, GLenum pname, GLdouble *params)
+{
+ d_1_0_Deprecated->GetTexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTexEnviv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetTexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetTexEnvfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetTexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetPolygonStipple(GLubyte *mask)
+{
+ d_1_0_Deprecated->GetPolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetPixelMapusv(GLenum map, GLushort *values)
+{
+ d_1_0_Deprecated->GetPixelMapusv(map, values);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetPixelMapuiv(GLenum map, GLuint *values)
+{
+ d_1_0_Deprecated->GetPixelMapuiv(map, values);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetPixelMapfv(GLenum map, GLfloat *values)
+{
+ d_1_0_Deprecated->GetPixelMapfv(map, values);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetMaterialiv(GLenum face, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetMaterialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetMaterialfv(GLenum face, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetMaterialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetMapiv(GLenum target, GLenum query, GLint *v)
+{
+ d_1_0_Deprecated->GetMapiv(target, query, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetMapfv(GLenum target, GLenum query, GLfloat *v)
+{
+ d_1_0_Deprecated->GetMapfv(target, query, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetMapdv(GLenum target, GLenum query, GLdouble *v)
+{
+ d_1_0_Deprecated->GetMapdv(target, query, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetLightiv(GLenum light, GLenum pname, GLint *params)
+{
+ d_1_0_Deprecated->GetLightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetLightfv(GLenum light, GLenum pname, GLfloat *params)
+{
+ d_1_0_Deprecated->GetLightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetClipPlane(GLenum plane, GLdouble *equation)
+{
+ d_1_0_Deprecated->GetClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDrawPixels(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Deprecated->DrawPixels(width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCopyPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type)
+{
+ d_1_0_Deprecated->CopyPixels(x, y, width, height, type);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPixelMapusv(GLenum map, GLint mapsize, const GLushort *values)
+{
+ d_1_0_Deprecated->PixelMapusv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPixelMapuiv(GLenum map, GLint mapsize, const GLuint *values)
+{
+ d_1_0_Deprecated->PixelMapuiv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPixelMapfv(GLenum map, GLint mapsize, const GLfloat *values)
+{
+ d_1_0_Deprecated->PixelMapfv(map, mapsize, values);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPixelTransferi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->PixelTransferi(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPixelTransferf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->PixelTransferf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPixelZoom(GLfloat xfactor, GLfloat yfactor)
+{
+ d_1_0_Deprecated->PixelZoom(xfactor, yfactor);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glAlphaFunc(GLenum func, GLfloat ref)
+{
+ d_1_0_Deprecated->AlphaFunc(func, ref);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEvalPoint2(GLint i, GLint j)
+{
+ d_1_0_Deprecated->EvalPoint2(i, j);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEvalMesh2(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ d_1_0_Deprecated->EvalMesh2(mode, i1, i2, j1, j2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEvalPoint1(GLint i)
+{
+ d_1_0_Deprecated->EvalPoint1(i);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEvalMesh1(GLenum mode, GLint i1, GLint i2)
+{
+ d_1_0_Deprecated->EvalMesh1(mode, i1, i2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEvalCoord2fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord2fv(u);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEvalCoord2f(GLfloat u, GLfloat v)
+{
+ d_1_0_Deprecated->EvalCoord2f(u, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEvalCoord2dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord2dv(u);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEvalCoord2d(GLdouble u, GLdouble v)
+{
+ d_1_0_Deprecated->EvalCoord2d(u, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEvalCoord1fv(const GLfloat *u)
+{
+ d_1_0_Deprecated->EvalCoord1fv(u);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEvalCoord1f(GLfloat u)
+{
+ d_1_0_Deprecated->EvalCoord1f(u);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEvalCoord1dv(const GLdouble *u)
+{
+ d_1_0_Deprecated->EvalCoord1dv(u);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEvalCoord1d(GLdouble u)
+{
+ d_1_0_Deprecated->EvalCoord1d(u);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMapGrid2f(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ d_1_0_Deprecated->MapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMapGrid2d(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ d_1_0_Deprecated->MapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMapGrid1f(GLint un, GLfloat u1, GLfloat u2)
+{
+ d_1_0_Deprecated->MapGrid1f(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMapGrid1d(GLint un, GLdouble u1, GLdouble u2)
+{
+ d_1_0_Deprecated->MapGrid1d(un, u1, u2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMap2f(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMap2d(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMap1f(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ d_1_0_Deprecated->Map1f(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMap1d(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ d_1_0_Deprecated->Map1d(target, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPushAttrib(GLbitfield mask)
+{
+ d_1_0_Deprecated->PushAttrib(mask);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPopAttrib()
+{
+ d_1_0_Deprecated->PopAttrib();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glAccum(GLenum op, GLfloat value)
+{
+ d_1_0_Deprecated->Accum(op, value);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glIndexMask(GLuint mask)
+{
+ d_1_0_Deprecated->IndexMask(mask);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClearIndex(GLfloat c)
+{
+ d_1_0_Deprecated->ClearIndex(c);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClearAccum(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->ClearAccum(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPushName(GLuint name)
+{
+ d_1_0_Deprecated->PushName(name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPopName()
+{
+ d_1_0_Deprecated->PopName();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPassThrough(GLfloat token)
+{
+ d_1_0_Deprecated->PassThrough(token);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLoadName(GLuint name)
+{
+ d_1_0_Deprecated->LoadName(name);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glInitNames()
+{
+ d_1_0_Deprecated->InitNames();
+}
+
+inline GLint QOpenGLFunctions_4_3_Compatibility::glRenderMode(GLenum mode)
+{
+ return d_1_0_Deprecated->RenderMode(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSelectBuffer(GLsizei size, GLuint *buffer)
+{
+ d_1_0_Deprecated->SelectBuffer(size, buffer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFeedbackBuffer(GLsizei size, GLenum type, GLfloat *buffer)
+{
+ d_1_0_Deprecated->FeedbackBuffer(size, type, buffer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexGeniv(GLenum coord, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexGeniv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexGeni(GLenum coord, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexGeni(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexGenfv(GLenum coord, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexGenfv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexGenf(GLenum coord, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexGenf(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexGendv(GLenum coord, GLenum pname, const GLdouble *params)
+{
+ d_1_0_Deprecated->TexGendv(coord, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexGend(GLenum coord, GLenum pname, GLdouble param)
+{
+ d_1_0_Deprecated->TexGend(coord, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexEnviv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->TexEnviv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexEnvi(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->TexEnvi(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexEnvfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->TexEnvfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexEnvf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->TexEnvf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glShadeModel(GLenum mode)
+{
+ d_1_0_Deprecated->ShadeModel(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPolygonStipple(const GLubyte *mask)
+{
+ d_1_0_Deprecated->PolygonStipple(mask);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMaterialiv(GLenum face, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Materialiv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMateriali(GLenum face, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Materiali(face, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMaterialfv(GLenum face, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Materialfv(face, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMaterialf(GLenum face, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Materialf(face, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLineStipple(GLint factor, GLushort pattern)
+{
+ d_1_0_Deprecated->LineStipple(factor, pattern);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLightModeliv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->LightModeliv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLightModeli(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->LightModeli(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLightModelfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->LightModelfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLightModelf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->LightModelf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLightiv(GLenum light, GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Lightiv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLighti(GLenum light, GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Lighti(light, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLightfv(GLenum light, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Lightfv(light, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLightf(GLenum light, GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Lightf(light, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFogiv(GLenum pname, const GLint *params)
+{
+ d_1_0_Deprecated->Fogiv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFogi(GLenum pname, GLint param)
+{
+ d_1_0_Deprecated->Fogi(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFogfv(GLenum pname, const GLfloat *params)
+{
+ d_1_0_Deprecated->Fogfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFogf(GLenum pname, GLfloat param)
+{
+ d_1_0_Deprecated->Fogf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColorMaterial(GLenum face, GLenum mode)
+{
+ d_1_0_Deprecated->ColorMaterial(face, mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClipPlane(GLenum plane, const GLdouble *equation)
+{
+ d_1_0_Deprecated->ClipPlane(plane, equation);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex4sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->Vertex4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex4iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->Vertex4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex4fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->Vertex4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex4dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->Vertex4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex3sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->Vertex3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex3iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->Vertex3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex3fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->Vertex3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex3dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->Vertex3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Vertex2sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->Vertex2s(x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex2iv(const GLint *v)
+{
+ d_1_0_Deprecated->Vertex2iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->Vertex2i(x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Vertex2fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->Vertex2f(x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Vertex2dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertex2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->Vertex2d(x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord4sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord4s(GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_0_Deprecated->TexCoord4s(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord4iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord4iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord4i(GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_0_Deprecated->TexCoord4i(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord4fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord4f(GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_0_Deprecated->TexCoord4f(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord4dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord4d(GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_0_Deprecated->TexCoord4d(s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord3sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord3s(GLshort s, GLshort t, GLshort r)
+{
+ d_1_0_Deprecated->TexCoord3s(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord3iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord3iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord3i(GLint s, GLint t, GLint r)
+{
+ d_1_0_Deprecated->TexCoord3i(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord3fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord3f(GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_0_Deprecated->TexCoord3f(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord3dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord3d(GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_0_Deprecated->TexCoord3d(s, t, r);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord2sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord2s(GLshort s, GLshort t)
+{
+ d_1_0_Deprecated->TexCoord2s(s, t);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord2iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord2iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord2i(GLint s, GLint t)
+{
+ d_1_0_Deprecated->TexCoord2i(s, t);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord2fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord2f(GLfloat s, GLfloat t)
+{
+ d_1_0_Deprecated->TexCoord2f(s, t);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord2dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord2d(GLdouble s, GLdouble t)
+{
+ d_1_0_Deprecated->TexCoord2d(s, t);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord1sv(const GLshort *v)
+{
+ d_1_0_Deprecated->TexCoord1sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord1s(GLshort s)
+{
+ d_1_0_Deprecated->TexCoord1s(s);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord1iv(const GLint *v)
+{
+ d_1_0_Deprecated->TexCoord1iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord1i(GLint s)
+{
+ d_1_0_Deprecated->TexCoord1i(s);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord1fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->TexCoord1fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord1f(GLfloat s)
+{
+ d_1_0_Deprecated->TexCoord1f(s);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord1dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->TexCoord1dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoord1d(GLdouble s)
+{
+ d_1_0_Deprecated->TexCoord1d(s);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRectsv(const GLshort *v1, const GLshort *v2)
+{
+ d_1_0_Deprecated->Rectsv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRects(GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ d_1_0_Deprecated->Rects(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRectiv(const GLint *v1, const GLint *v2)
+{
+ d_1_0_Deprecated->Rectiv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRecti(GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ d_1_0_Deprecated->Recti(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRectfv(const GLfloat *v1, const GLfloat *v2)
+{
+ d_1_0_Deprecated->Rectfv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRectf(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ d_1_0_Deprecated->Rectf(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRectdv(const GLdouble *v1, const GLdouble *v2)
+{
+ d_1_0_Deprecated->Rectdv(v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRectd(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ d_1_0_Deprecated->Rectd(x1, y1, x2, y2);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos4sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos4s(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_1_0_Deprecated->RasterPos4s(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos4iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos4iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos4i(GLint x, GLint y, GLint z, GLint w)
+{
+ d_1_0_Deprecated->RasterPos4i(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos4fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos4f(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_1_0_Deprecated->RasterPos4f(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos4dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos4d(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_1_0_Deprecated->RasterPos4d(x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos3sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_0_Deprecated->RasterPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos3iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos3iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_0_Deprecated->RasterPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos3fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_0_Deprecated->RasterPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos3dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_0_Deprecated->RasterPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos2sv(const GLshort *v)
+{
+ d_1_0_Deprecated->RasterPos2sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos2s(GLshort x, GLshort y)
+{
+ d_1_0_Deprecated->RasterPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos2iv(const GLint *v)
+{
+ d_1_0_Deprecated->RasterPos2iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos2i(GLint x, GLint y)
+{
+ d_1_0_Deprecated->RasterPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos2fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->RasterPos2fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos2f(GLfloat x, GLfloat y)
+{
+ d_1_0_Deprecated->RasterPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos2dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->RasterPos2dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glRasterPos2d(GLdouble x, GLdouble y)
+{
+ d_1_0_Deprecated->RasterPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormal3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Normal3sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormal3s(GLshort nx, GLshort ny, GLshort nz)
+{
+ d_1_0_Deprecated->Normal3s(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormal3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Normal3iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormal3i(GLint nx, GLint ny, GLint nz)
+{
+ d_1_0_Deprecated->Normal3i(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormal3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Normal3fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ d_1_0_Deprecated->Normal3f(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormal3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Normal3dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormal3d(GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ d_1_0_Deprecated->Normal3d(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormal3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Normal3bv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormal3b(GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ d_1_0_Deprecated->Normal3b(nx, ny, nz);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glIndexsv(const GLshort *c)
+{
+ d_1_0_Deprecated->Indexsv(c);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glIndexs(GLshort c)
+{
+ d_1_0_Deprecated->Indexs(c);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glIndexiv(const GLint *c)
+{
+ d_1_0_Deprecated->Indexiv(c);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glIndexi(GLint c)
+{
+ d_1_0_Deprecated->Indexi(c);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glIndexfv(const GLfloat *c)
+{
+ d_1_0_Deprecated->Indexfv(c);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glIndexf(GLfloat c)
+{
+ d_1_0_Deprecated->Indexf(c);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glIndexdv(const GLdouble *c)
+{
+ d_1_0_Deprecated->Indexdv(c);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glIndexd(GLdouble c)
+{
+ d_1_0_Deprecated->Indexd(c);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEnd()
+{
+ d_1_0_Deprecated->End();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEdgeFlagv(const GLboolean *flag)
+{
+ d_1_0_Deprecated->EdgeFlagv(flag);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEdgeFlag(GLboolean flag)
+{
+ d_1_0_Deprecated->EdgeFlag(flag);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color4usv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4us(GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ d_1_0_Deprecated->Color4us(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color4uiv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4ui(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ d_1_0_Deprecated->Color4ui(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color4ubv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ d_1_0_Deprecated->Color4ub(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color4sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4s(GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ d_1_0_Deprecated->Color4s(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color4iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4i(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ d_1_0_Deprecated->Color4i(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color4fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4f(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Deprecated->Color4f(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color4dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4d(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ d_1_0_Deprecated->Color4d(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color4bv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor4b(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ d_1_0_Deprecated->Color4b(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3usv(const GLushort *v)
+{
+ d_1_0_Deprecated->Color3usv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_0_Deprecated->Color3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3uiv(const GLuint *v)
+{
+ d_1_0_Deprecated->Color3uiv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_0_Deprecated->Color3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3ubv(const GLubyte *v)
+{
+ d_1_0_Deprecated->Color3ubv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_0_Deprecated->Color3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3sv(const GLshort *v)
+{
+ d_1_0_Deprecated->Color3sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_0_Deprecated->Color3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3iv(const GLint *v)
+{
+ d_1_0_Deprecated->Color3iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_0_Deprecated->Color3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3fv(const GLfloat *v)
+{
+ d_1_0_Deprecated->Color3fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_0_Deprecated->Color3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3dv(const GLdouble *v)
+{
+ d_1_0_Deprecated->Color3dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_0_Deprecated->Color3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3bv(const GLbyte *v)
+{
+ d_1_0_Deprecated->Color3bv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_0_Deprecated->Color3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBitmap(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap)
+{
+ d_1_0_Deprecated->Bitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glBegin(GLenum mode)
+{
+ d_1_0_Deprecated->Begin(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glListBase(GLuint base)
+{
+ d_1_0_Deprecated->ListBase(base);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Compatibility::glGenLists(GLsizei range)
+{
+ return d_1_0_Deprecated->GenLists(range);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDeleteLists(GLuint list, GLsizei range)
+{
+ d_1_0_Deprecated->DeleteLists(list, range);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCallLists(GLsizei n, GLenum type, const GLvoid *lists)
+{
+ d_1_0_Deprecated->CallLists(n, type, lists);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCallList(GLuint list)
+{
+ d_1_0_Deprecated->CallList(list);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEndList()
+{
+ d_1_0_Deprecated->EndList();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNewList(GLuint list, GLenum mode)
+{
+ d_1_0_Deprecated->NewList(list, mode);
+}
+
+
+// OpenGL 1.1 deprecated functions
+inline void QOpenGLFunctions_4_3_Compatibility::glPushClientAttrib(GLbitfield mask)
+{
+ d_1_1_Deprecated->PushClientAttrib(mask);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPopClientAttrib()
+{
+ d_1_1_Deprecated->PopClientAttrib();
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glPrioritizeTextures(GLsizei n, const GLuint *textures, const GLfloat *priorities)
+{
+ d_1_1_Deprecated->PrioritizeTextures(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Compatibility::glAreTexturesResident(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ return d_1_1_Deprecated->AreTexturesResident(n, textures, residences);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->VertexPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glTexCoordPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->TexCoordPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glNormalPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->NormalPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glInterleavedArrays(GLenum format, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->InterleavedArrays(format, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glIndexPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->IndexPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEnableClientState(GLenum array)
+{
+ d_1_1_Deprecated->EnableClientState(array);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glEdgeFlagPointer(GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->EdgeFlagPointer(stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glDisableClientState(GLenum array)
+{
+ d_1_1_Deprecated->DisableClientState(array);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_1_Deprecated->ColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glArrayElement(GLint i)
+{
+ d_1_1_Deprecated->ArrayElement(i);
+}
+
+
+// OpenGL 1.2 deprecated functions
+inline void QOpenGLFunctions_4_3_Compatibility::glResetMinmax(GLenum target)
+{
+ d_1_2_Deprecated->ResetMinmax(target);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glResetHistogram(GLenum target)
+{
+ d_1_2_Deprecated->ResetHistogram(target);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMinmax(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Minmax(target, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glHistogram(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ d_1_2_Deprecated->Histogram(target, width, internalformat, sink);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetMinmaxParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetMinmaxParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetMinmaxParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetMinmax(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetMinmax(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetHistogramParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetHistogramParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetHistogramParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetHistogramParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetHistogram(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ d_1_2_Deprecated->GetHistogram(target, reset, format, type, values);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSeparableFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ d_1_2_Deprecated->SeparableFilter2D(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetSeparableFilter(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ d_1_2_Deprecated->GetSeparableFilter(target, format, type, row, column, span);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetConvolutionParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetConvolutionParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetConvolutionFilter(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ d_1_2_Deprecated->GetConvolutionFilter(target, format, type, image);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCopyConvolutionFilter2D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter2D(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCopyConvolutionFilter1D(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyConvolutionFilter1D(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glConvolutionParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ConvolutionParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glConvolutionParameteri(GLenum target, GLenum pname, GLint params)
+{
+ d_1_2_Deprecated->ConvolutionParameteri(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glConvolutionParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ConvolutionParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glConvolutionParameterf(GLenum target, GLenum pname, GLfloat params)
+{
+ d_1_2_Deprecated->ConvolutionParameterf(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glConvolutionFilter2D(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter2D(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glConvolutionFilter1D(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ d_1_2_Deprecated->ConvolutionFilter1D(target, internalformat, width, format, type, image);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCopyColorSubTable(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorSubTable(target, start, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColorSubTable(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ d_1_2_Deprecated->ColorSubTable(target, start, count, format, type, data);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetColorTableParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_2_Deprecated->GetColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetColorTableParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_2_Deprecated->GetColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glGetColorTable(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ d_1_2_Deprecated->GetColorTable(target, format, type, table);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glCopyColorTable(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ d_1_2_Deprecated->CopyColorTable(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColorTableParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_2_Deprecated->ColorTableParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColorTableParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_2_Deprecated->ColorTableParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glColorTable(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ d_1_2_Deprecated->ColorTable(target, internalformat, width, format, type, table);
+}
+
+
+// OpenGL 1.3 deprecated functions
+inline void QOpenGLFunctions_4_3_Compatibility::glMultTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->MultTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLoadTransposeMatrixd(const GLdouble *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixd(m);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glLoadTransposeMatrixf(const GLfloat *m)
+{
+ d_1_3_Deprecated->LoadTransposeMatrixf(m);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord4sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord4s(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ d_1_3_Deprecated->MultiTexCoord4s(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord4iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord4i(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ d_1_3_Deprecated->MultiTexCoord4i(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord4fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord4f(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ d_1_3_Deprecated->MultiTexCoord4f(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord4dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord4dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord4d(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ d_1_3_Deprecated->MultiTexCoord4d(target, s, t, r, q);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord3sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord3s(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ d_1_3_Deprecated->MultiTexCoord3s(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord3iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord3i(GLenum target, GLint s, GLint t, GLint r)
+{
+ d_1_3_Deprecated->MultiTexCoord3i(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord3fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord3f(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ d_1_3_Deprecated->MultiTexCoord3f(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord3dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord3dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord3d(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ d_1_3_Deprecated->MultiTexCoord3d(target, s, t, r);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord2sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord2s(GLenum target, GLshort s, GLshort t)
+{
+ d_1_3_Deprecated->MultiTexCoord2s(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord2iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord2i(GLenum target, GLint s, GLint t)
+{
+ d_1_3_Deprecated->MultiTexCoord2i(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord2fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord2f(GLenum target, GLfloat s, GLfloat t)
+{
+ d_1_3_Deprecated->MultiTexCoord2f(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord2dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord2dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord2d(GLenum target, GLdouble s, GLdouble t)
+{
+ d_1_3_Deprecated->MultiTexCoord2d(target, s, t);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord1sv(GLenum target, const GLshort *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1sv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord1s(GLenum target, GLshort s)
+{
+ d_1_3_Deprecated->MultiTexCoord1s(target, s);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord1iv(GLenum target, const GLint *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1iv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord1i(GLenum target, GLint s)
+{
+ d_1_3_Deprecated->MultiTexCoord1i(target, s);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord1fv(GLenum target, const GLfloat *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1fv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord1f(GLenum target, GLfloat s)
+{
+ d_1_3_Deprecated->MultiTexCoord1f(target, s);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord1dv(GLenum target, const GLdouble *v)
+{
+ d_1_3_Deprecated->MultiTexCoord1dv(target, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glMultiTexCoord1d(GLenum target, GLdouble s)
+{
+ d_1_3_Deprecated->MultiTexCoord1d(target, s);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glClientActiveTexture(GLenum texture)
+{
+ d_1_3_Deprecated->ClientActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 deprecated functions
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos3sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos3s(GLshort x, GLshort y, GLshort z)
+{
+ d_1_4_Deprecated->WindowPos3s(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos3iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos3iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos3i(GLint x, GLint y, GLint z)
+{
+ d_1_4_Deprecated->WindowPos3i(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos3fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos3f(GLfloat x, GLfloat y, GLfloat z)
+{
+ d_1_4_Deprecated->WindowPos3f(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos3dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos3d(GLdouble x, GLdouble y, GLdouble z)
+{
+ d_1_4_Deprecated->WindowPos3d(x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos2sv(const GLshort *v)
+{
+ d_1_4_Deprecated->WindowPos2sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos2s(GLshort x, GLshort y)
+{
+ d_1_4_Deprecated->WindowPos2s(x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos2iv(const GLint *v)
+{
+ d_1_4_Deprecated->WindowPos2iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos2i(GLint x, GLint y)
+{
+ d_1_4_Deprecated->WindowPos2i(x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos2fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->WindowPos2fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos2f(GLfloat x, GLfloat y)
+{
+ d_1_4_Deprecated->WindowPos2f(x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos2dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->WindowPos2dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glWindowPos2d(GLdouble x, GLdouble y)
+{
+ d_1_4_Deprecated->WindowPos2d(x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColorPointer(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->SecondaryColorPointer(size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3usv(const GLushort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3usv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3us(GLushort red, GLushort green, GLushort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3us(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3uiv(const GLuint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3uiv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3ui(GLuint red, GLuint green, GLuint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ui(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3ubv(const GLubyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3ubv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3ub(GLubyte red, GLubyte green, GLubyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3ub(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3sv(const GLshort *v)
+{
+ d_1_4_Deprecated->SecondaryColor3sv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3s(GLshort red, GLshort green, GLshort blue)
+{
+ d_1_4_Deprecated->SecondaryColor3s(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3iv(const GLint *v)
+{
+ d_1_4_Deprecated->SecondaryColor3iv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3i(GLint red, GLint green, GLint blue)
+{
+ d_1_4_Deprecated->SecondaryColor3i(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3fv(const GLfloat *v)
+{
+ d_1_4_Deprecated->SecondaryColor3fv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3f(GLfloat red, GLfloat green, GLfloat blue)
+{
+ d_1_4_Deprecated->SecondaryColor3f(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3dv(const GLdouble *v)
+{
+ d_1_4_Deprecated->SecondaryColor3dv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3d(GLdouble red, GLdouble green, GLdouble blue)
+{
+ d_1_4_Deprecated->SecondaryColor3d(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3bv(const GLbyte *v)
+{
+ d_1_4_Deprecated->SecondaryColor3bv(v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glSecondaryColor3b(GLbyte red, GLbyte green, GLbyte blue)
+{
+ d_1_4_Deprecated->SecondaryColor3b(red, green, blue);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFogCoordPointer(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_1_4_Deprecated->FogCoordPointer(type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFogCoorddv(const GLdouble *coord)
+{
+ d_1_4_Deprecated->FogCoorddv(coord);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFogCoordd(GLdouble coord)
+{
+ d_1_4_Deprecated->FogCoordd(coord);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFogCoordfv(const GLfloat *coord)
+{
+ d_1_4_Deprecated->FogCoordfv(coord);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glFogCoordf(GLfloat coord)
+{
+ d_1_4_Deprecated->FogCoordf(coord);
+}
+
+
+// OpenGL 1.5 deprecated functions
+
+// OpenGL 2.0 deprecated functions
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4usv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4usv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4uiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4ubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4s(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ d_2_0_Deprecated->VertexAttrib4s(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4iv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib4fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4f(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ d_2_0_Deprecated->VertexAttrib4f(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib4dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_2_0_Deprecated->VertexAttrib4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4bv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4bv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4Nusv(GLuint index, const GLushort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nusv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4Nuiv(GLuint index, const GLuint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nuiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4Nubv(GLuint index, const GLubyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nubv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4Nub(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ d_2_0_Deprecated->VertexAttrib4Nub(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4Nsv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nsv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4Niv(GLuint index, const GLint *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Niv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib4Nbv(GLuint index, const GLbyte *v)
+{
+ d_2_0_Deprecated->VertexAttrib4Nbv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib3sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib3sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib3s(GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ d_2_0_Deprecated->VertexAttrib3s(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib3fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib3fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib3f(GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ d_2_0_Deprecated->VertexAttrib3f(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib3dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib3dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_2_0_Deprecated->VertexAttrib3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib2sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib2sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib2s(GLuint index, GLshort x, GLshort y)
+{
+ d_2_0_Deprecated->VertexAttrib2s(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib2fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib2fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib2f(GLuint index, GLfloat x, GLfloat y)
+{
+ d_2_0_Deprecated->VertexAttrib2f(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib2dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib2dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_2_0_Deprecated->VertexAttrib2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib1sv(GLuint index, const GLshort *v)
+{
+ d_2_0_Deprecated->VertexAttrib1sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib1s(GLuint index, GLshort x)
+{
+ d_2_0_Deprecated->VertexAttrib1s(index, x);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib1fv(GLuint index, const GLfloat *v)
+{
+ d_2_0_Deprecated->VertexAttrib1fv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib1f(GLuint index, GLfloat x)
+{
+ d_2_0_Deprecated->VertexAttrib1f(index, x);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib1dv(GLuint index, const GLdouble *v)
+{
+ d_2_0_Deprecated->VertexAttrib1dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttrib1d(GLuint index, GLdouble x)
+{
+ d_2_0_Deprecated->VertexAttrib1d(index, x);
+}
+
+
+// OpenGL 2.1 deprecated functions
+
+// OpenGL 3.0 deprecated functions
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI4usv(GLuint index, const GLushort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4usv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI4ubv(GLuint index, const GLubyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4ubv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI4sv(GLuint index, const GLshort *v)
+{
+ d_3_0_Deprecated->VertexAttribI4sv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI4bv(GLuint index, const GLbyte *v)
+{
+ d_3_0_Deprecated->VertexAttribI4bv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI4uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI3uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI2uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI1uiv(GLuint index, const GLuint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1uiv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI4iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI4iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI3iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI3iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI2iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI2iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI1iv(GLuint index, const GLint *v)
+{
+ d_3_0_Deprecated->VertexAttribI1iv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI4ui(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ d_3_0_Deprecated->VertexAttribI4ui(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI3ui(GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ d_3_0_Deprecated->VertexAttribI3ui(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI2ui(GLuint index, GLuint x, GLuint y)
+{
+ d_3_0_Deprecated->VertexAttribI2ui(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI1ui(GLuint index, GLuint x)
+{
+ d_3_0_Deprecated->VertexAttribI1ui(index, x);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI4i(GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ d_3_0_Deprecated->VertexAttribI4i(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI3i(GLuint index, GLint x, GLint y, GLint z)
+{
+ d_3_0_Deprecated->VertexAttribI3i(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI2i(GLuint index, GLint x, GLint y)
+{
+ d_3_0_Deprecated->VertexAttribI2i(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Compatibility::glVertexAttribI1i(GLuint index, GLint x)
+{
+ d_3_0_Deprecated->VertexAttribI1i(index, x);
+}
+
+
+// OpenGL 3.1 deprecated functions
+
+// OpenGL 3.2 deprecated functions
+
+// OpenGL 3.3 deprecated functions
+
+// OpenGL 4.0 deprecated functions
+
+// OpenGL 4.1 deprecated functions
+
+// OpenGL 4.2 deprecated functions
+
+// OpenGL 4.3 deprecated functions
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_4_3_core.cpp b/src/gui/opengl/qopenglfunctions_4_3_core.cpp
new file mode 100644
index 0000000000..bfe1bcc9c4
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_3_core.cpp
@@ -0,0 +1,321 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions_4_3_core.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_4_3_Core
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_4_3_Core class provides all functions for this version and profile of OpenGL.
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_4_3_Core::QOpenGLFunctions_4_3_Core()
+ : QAbstractOpenGLFunctions()
+ , d_1_0_Core(0)
+ , d_1_1_Core(0)
+ , d_1_2_Core(0)
+ , d_1_3_Core(0)
+ , d_1_4_Core(0)
+ , d_1_5_Core(0)
+ , d_2_0_Core(0)
+ , d_2_1_Core(0)
+ , d_3_0_Core(0)
+ , d_3_1_Core(0)
+ , d_3_2_Core(0)
+ , d_3_3_Core(0)
+ , d_4_0_Core(0)
+ , d_4_1_Core(0)
+ , d_4_2_Core(0)
+ , d_4_3_Core(0)
+{
+}
+
+QOpenGLFunctions_4_3_Core::~QOpenGLFunctions_4_3_Core()
+{
+ if (d_1_0_Core && !d_1_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_0_Core->context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ delete d_1_0_Core;
+ }
+ if (d_1_1_Core && !d_1_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_1_Core->context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ delete d_1_1_Core;
+ }
+ if (d_1_2_Core && !d_1_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_2_Core->context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ delete d_1_2_Core;
+ }
+ if (d_1_3_Core && !d_1_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_3_Core->context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ delete d_1_3_Core;
+ }
+ if (d_1_4_Core && !d_1_4_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_4_Core->context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ delete d_1_4_Core;
+ }
+ if (d_1_5_Core && !d_1_5_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_1_5_Core->context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ delete d_1_5_Core;
+ }
+ if (d_2_0_Core && !d_2_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_0_Core->context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ delete d_2_0_Core;
+ }
+ if (d_2_1_Core && !d_2_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_2_1_Core->context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ delete d_2_1_Core;
+ }
+ if (d_3_0_Core && !d_3_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_0_Core->context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ delete d_3_0_Core;
+ }
+ if (d_3_1_Core && !d_3_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_1_Core->context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ delete d_3_1_Core;
+ }
+ if (d_3_2_Core && !d_3_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_2_Core->context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ delete d_3_2_Core;
+ }
+ if (d_3_3_Core && !d_3_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_3_3_Core->context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ delete d_3_3_Core;
+ }
+ if (d_4_0_Core && !d_4_0_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_0_Core->context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ delete d_4_0_Core;
+ }
+ if (d_4_1_Core && !d_4_1_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_1_Core->context, QOpenGLFunctions_4_1_CoreBackend::versionStatus());
+ delete d_4_1_Core;
+ }
+ if (d_4_2_Core && !d_4_2_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_2_Core->context, QOpenGLFunctions_4_2_CoreBackend::versionStatus());
+ delete d_4_2_Core;
+ }
+ if (d_4_3_Core && !d_4_3_Core->refs.deref()) {
+ QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(d_4_3_Core->context, QOpenGLFunctions_4_3_CoreBackend::versionStatus());
+ delete d_4_3_Core;
+ }
+}
+
+bool QOpenGLFunctions_4_3_Core::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is capable of resolving all needed functions
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_4_3_Core::isContextCompatible(context))
+ {
+ // Associate with private implementation, creating if necessary
+ // Function pointers in the backends are resolved at creation time
+ QOpenGLVersionFunctionsBackend* d = 0;
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_0_CoreBackend::versionStatus(), d);
+ }
+ d_1_0_Core = static_cast<QOpenGLFunctions_1_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_1_CoreBackend::versionStatus(), d);
+ }
+ d_1_1_Core = static_cast<QOpenGLFunctions_1_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_2_CoreBackend::versionStatus(), d);
+ }
+ d_1_2_Core = static_cast<QOpenGLFunctions_1_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_3_CoreBackend::versionStatus(), d);
+ }
+ d_1_3_Core = static_cast<QOpenGLFunctions_1_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_4_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_4_CoreBackend::versionStatus(), d);
+ }
+ d_1_4_Core = static_cast<QOpenGLFunctions_1_4_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_1_5_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_1_5_CoreBackend::versionStatus(), d);
+ }
+ d_1_5_Core = static_cast<QOpenGLFunctions_1_5_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_0_CoreBackend::versionStatus(), d);
+ }
+ d_2_0_Core = static_cast<QOpenGLFunctions_2_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_2_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_2_1_CoreBackend::versionStatus(), d);
+ }
+ d_2_1_Core = static_cast<QOpenGLFunctions_2_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_0_CoreBackend::versionStatus(), d);
+ }
+ d_3_0_Core = static_cast<QOpenGLFunctions_3_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_1_CoreBackend::versionStatus(), d);
+ }
+ d_3_1_Core = static_cast<QOpenGLFunctions_3_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_2_CoreBackend::versionStatus(), d);
+ }
+ d_3_2_Core = static_cast<QOpenGLFunctions_3_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_3_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_3_3_CoreBackend::versionStatus(), d);
+ }
+ d_3_3_Core = static_cast<QOpenGLFunctions_3_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_0_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_0_CoreBackend::versionStatus(), d);
+ }
+ d_4_0_Core = static_cast<QOpenGLFunctions_4_0_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_1_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_1_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_1_CoreBackend::versionStatus(), d);
+ }
+ d_4_1_Core = static_cast<QOpenGLFunctions_4_1_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_2_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_2_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_2_CoreBackend::versionStatus(), d);
+ }
+ d_4_2_Core = static_cast<QOpenGLFunctions_4_2_CoreBackend*>(d);
+ d->refs.ref();
+
+ d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, QOpenGLFunctions_4_3_CoreBackend::versionStatus());
+ if (!d) {
+ d = new QOpenGLFunctions_4_3_CoreBackend(context);
+ QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, QOpenGLFunctions_4_3_CoreBackend::versionStatus(), d);
+ }
+ d_4_3_Core = static_cast<QOpenGLFunctions_4_3_CoreBackend*>(d);
+ d->refs.ref();
+
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_4_3_Core::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(4, 3))
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_4_3_Core::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ v.setVersion(4, 3);
+ v.setProfile(QSurfaceFormat::CoreProfile);
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_4_3_core.h b/src/gui/opengl/qopenglfunctions_4_3_core.h
new file mode 100644
index 0000000000..f7823cd6aa
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_4_3_core.h
@@ -0,0 +1,3164 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_4_3_CORE_H
+#define QOPENGLVERSIONFUNCTIONS_4_3_CORE_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class Q_GUI_EXPORT QOpenGLFunctions_4_3_Core : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_4_3_Core();
+ ~QOpenGLFunctions_4_3_Core();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL 1.0 core functions
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glDepthRange(GLdouble nearVal, GLdouble farVal);
+ GLboolean glIsEnabled(GLenum cap);
+ void glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params);
+ void glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * glGetString(GLenum name);
+ void glGetIntegerv(GLenum pname, GLint *params);
+ void glGetFloatv(GLenum pname, GLfloat *params);
+ GLenum glGetError();
+ void glGetDoublev(GLenum pname, GLdouble *params);
+ void glGetBooleanv(GLenum pname, GLboolean *params);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void glReadBuffer(GLenum mode);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPixelStoref(GLenum pname, GLfloat param);
+ void glDepthFunc(GLenum func);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glLogicOp(GLenum opcode);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glFlush();
+ void glFinish();
+ void glEnable(GLenum cap);
+ void glDisable(GLenum cap);
+ void glDepthMask(GLboolean flag);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glStencilMask(GLuint mask);
+ void glClearDepth(GLdouble depth);
+ void glClearStencil(GLint s);
+ void glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void glClear(GLbitfield mask);
+ void glDrawBuffer(GLenum mode);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint *params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glPolygonMode(GLenum face, GLenum mode);
+ void glPointSize(GLfloat size);
+ void glLineWidth(GLfloat width);
+ void glHint(GLenum target, GLenum mode);
+ void glFrontFace(GLenum mode);
+ void glCullFace(GLenum mode);
+
+ // OpenGL 1.1 core functions
+ void glIndexubv(const GLubyte *c);
+ void glIndexub(GLubyte c);
+ GLboolean glIsTexture(GLuint texture);
+ void glGenTextures(GLsizei n, GLuint *textures);
+ void glDeleteTextures(GLsizei n, const GLuint *textures);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glGetPointerv(GLenum pname, GLvoid* *params);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+
+ // OpenGL 1.2 core functions
+ void glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void glBlendEquation(GLenum mode);
+ void glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+ // OpenGL 1.3 core functions
+ void glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glSampleCoverage(GLfloat value, GLboolean invert);
+ void glActiveTexture(GLenum texture);
+
+ // OpenGL 1.4 core functions
+ void glPointParameteriv(GLenum pname, const GLint *params);
+ void glPointParameteri(GLenum pname, GLint param);
+ void glPointParameterfv(GLenum pname, const GLfloat *params);
+ void glPointParameterf(GLenum pname, GLfloat param);
+ void glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+ // OpenGL 1.5 core functions
+ void glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBuffer(GLenum target);
+ GLvoid* glMapBuffer(GLenum target, GLenum access);
+ void glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBuffer(GLuint buffer);
+ void glGenBuffers(GLsizei n, GLuint *buffers);
+ void glDeleteBuffers(GLsizei n, const GLuint *buffers);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryiv(GLenum target, GLenum pname, GLint *params);
+ void glEndQuery(GLenum target);
+ void glBeginQuery(GLenum target, GLuint id);
+ GLboolean glIsQuery(GLuint id);
+ void glDeleteQueries(GLsizei n, const GLuint *ids);
+ void glGenQueries(GLsizei n, GLuint *ids);
+
+ // OpenGL 2.0 core functions
+ void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glValidateProgram(GLuint program);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform3iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform2iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform1iv(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3i(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2i(GLint location, GLint v0, GLint v1);
+ void glUniform1i(GLint location, GLint v0);
+ void glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2f(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1f(GLint location, GLfloat v0);
+ void glUseProgram(GLuint program);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void glLinkProgram(GLuint program);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsProgram(GLuint program);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params);
+ void glGetUniformiv(GLuint program, GLint location, GLint *params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat *params);
+ GLint glGetUniformLocation(GLuint program, const GLchar *name);
+ void glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint *params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint *params);
+ GLint glGetAttribLocation(GLuint program, const GLchar *name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void glEnableVertexAttribArray(GLuint index);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDeleteShader(GLuint shader);
+ void glDeleteProgram(GLuint program);
+ GLuint glCreateShader(GLenum type);
+ GLuint glCreateProgram();
+ void glCompileShader(GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar *name);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void glDrawBuffers(GLsizei n, const GLenum *bufs);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+
+ // OpenGL 2.1 core functions
+ void glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+ // OpenGL 3.0 core functions
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ const GLubyte * glGetStringi(GLenum name, GLuint index);
+ void glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIiv(GLenum target, GLenum pname, const GLint *params);
+ void glUniform4uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uiv(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2ui(GLint location, GLuint v0, GLuint v1);
+ void glUniform1ui(GLint location, GLuint v0);
+ GLint glGetFragDataLocation(GLuint program, const GLchar *name);
+ void glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuiv(GLuint program, GLint location, GLuint *params);
+ void glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glEndConditionalRender();
+ void glBeginConditionalRender(GLuint id, GLenum mode);
+ void glClampColor(GLenum target, GLenum clamp);
+ void glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void glBindBufferBase(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedback();
+ void glBeginTransformFeedback(GLenum primitiveMode);
+ GLboolean glIsEnabledi(GLenum target, GLuint index);
+ void glDisablei(GLenum target, GLuint index);
+ void glEnablei(GLenum target, GLuint index);
+ void glGetIntegeri_v(GLenum target, GLuint index, GLint *data);
+ void glGetBooleani_v(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+ // OpenGL 3.1 core functions
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void glPrimitiveRestartIndex(GLuint index);
+ void glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer);
+ void glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+ // OpenGL 3.2 core functions
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+ void glProvokingVertex(GLenum mode);
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params);
+ void glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data);
+
+ // OpenGL 3.3 core functions
+ void glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glSecondaryColorP3uiv(GLenum type, const GLuint *color);
+ void glSecondaryColorP3ui(GLenum type, GLuint color);
+ void glColorP4uiv(GLenum type, const GLuint *color);
+ void glColorP4ui(GLenum type, GLuint color);
+ void glColorP3uiv(GLenum type, const GLuint *color);
+ void glColorP3ui(GLenum type, GLuint color);
+ void glNormalP3uiv(GLenum type, const GLuint *coords);
+ void glNormalP3ui(GLenum type, GLuint coords);
+ void glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords);
+ void glTexCoordP4uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP4ui(GLenum type, GLuint coords);
+ void glTexCoordP3uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP3ui(GLenum type, GLuint coords);
+ void glTexCoordP2uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP2ui(GLenum type, GLuint coords);
+ void glTexCoordP1uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP1ui(GLenum type, GLuint coords);
+ void glVertexP4uiv(GLenum type, const GLuint *value);
+ void glVertexP4ui(GLenum type, GLuint value);
+ void glVertexP3uiv(GLenum type, const GLuint *value);
+ void glVertexP3ui(GLenum type, GLuint value);
+ void glVertexP2uiv(GLenum type, const GLuint *value);
+ void glVertexP2ui(GLenum type, GLuint value);
+ void glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params);
+ void glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params);
+ void glQueryCounter(GLuint id, GLenum target);
+ void glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params);
+ void glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params);
+ void glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params);
+ void glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params);
+ void glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param);
+ void glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param);
+ void glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param);
+ void glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameteri(GLuint sampler, GLenum pname, GLint param);
+ void glBindSampler(GLuint unit, GLuint sampler);
+ GLboolean glIsSampler(GLuint sampler);
+ void glDeleteSamplers(GLsizei count, const GLuint *samplers);
+ void glGenSamplers(GLsizei count, GLuint *samplers);
+ GLint glGetFragDataIndex(GLuint program, const GLchar *name);
+ void glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+ void glVertexAttribDivisor(GLuint index, GLuint divisor);
+
+ // OpenGL 4.0 core functions
+ void glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void glEndQueryIndexed(GLenum target, GLuint index);
+ void glBeginQueryIndexed(GLenum target, GLuint index, GLuint id);
+ void glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream);
+ void glDrawTransformFeedback(GLenum mode, GLuint id);
+ void glResumeTransformFeedback();
+ void glPauseTransformFeedback();
+ GLboolean glIsTransformFeedback(GLuint id);
+ void glGenTransformFeedbacks(GLsizei n, GLuint *ids);
+ void glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids);
+ void glBindTransformFeedback(GLenum target, GLuint id);
+ void glPatchParameterfv(GLenum pname, const GLfloat *values);
+ void glPatchParameteri(GLenum pname, GLint value);
+ void glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values);
+ void glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params);
+ void glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices);
+ void glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
+ GLuint glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name);
+ GLint glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name);
+ void glGetUniformdv(GLuint program, GLint location, GLdouble *params);
+ void glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniform4dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform3dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform2dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform1dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void glUniform2d(GLint location, GLdouble x, GLdouble y);
+ void glUniform1d(GLint location, GLdouble x);
+ void glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect);
+ void glDrawArraysIndirect(GLenum mode, const GLvoid *indirect);
+ void glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void glBlendFunci(GLuint buf, GLenum src, GLenum dst);
+ void glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void glBlendEquationi(GLuint buf, GLenum mode);
+ void glMinSampleShading(GLfloat value);
+
+ // OpenGL 4.1 core functions
+ void glGetDoublei_v(GLenum target, GLuint index, GLdouble *data);
+ void glGetFloati_v(GLenum target, GLuint index, GLfloat *data);
+ void glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f);
+ void glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v);
+ void glScissorIndexedv(GLuint index, const GLint *v);
+ void glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+ void glScissorArrayv(GLuint first, GLsizei count, const GLint *v);
+ void glViewportIndexedfv(GLuint index, const GLfloat *v);
+ void glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+ void glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v);
+ void glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params);
+ void glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glVertexAttribL4dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL3dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL2dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL1dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttribL1d(GLuint index, GLdouble x);
+ void glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glValidateProgramPipeline(GLuint pipeline);
+ void glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+ void glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+ void glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+ void glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1);
+ void glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1);
+ void glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1);
+ void glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1);
+ void glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform1ui(GLuint program, GLint location, GLuint v0);
+ void glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform1d(GLuint program, GLint location, GLdouble v0);
+ void glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform1f(GLuint program, GLint location, GLfloat v0);
+ void glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform1i(GLuint program, GLint location, GLint v0);
+ void glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params);
+ GLboolean glIsProgramPipeline(GLuint pipeline);
+ void glGenProgramPipelines(GLsizei n, GLuint *pipelines);
+ void glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines);
+ void glBindProgramPipeline(GLuint pipeline);
+ GLuint glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings);
+ void glActiveShaderProgram(GLuint pipeline, GLuint program);
+ void glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program);
+ void glProgramParameteri(GLuint program, GLenum pname, GLint value);
+ void glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length);
+ void glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+ void glClearDepthf(GLfloat dd);
+ void glDepthRangef(GLfloat n, GLfloat f);
+ void glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision);
+ void glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length);
+ void glReleaseShaderCompiler();
+
+ // OpenGL 4.2 core functions
+ void glTexStorage3D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void glTexStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void glTexStorage1D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void glMemoryBarrier(GLbitfield barriers);
+ void glBindImageTexture(GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
+ void glGetActiveAtomicCounterBufferiv(GLuint program, GLuint bufferIndex, GLenum pname, GLint *params);
+ void glGetInternalformativ(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params);
+ void glDrawTransformFeedbackStreamInstanced(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
+ void glDrawTransformFeedbackInstanced(GLenum mode, GLuint id, GLsizei instancecount);
+ void glDrawElementsInstancedBaseVertexBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
+ void glDrawElementsInstancedBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance);
+ void glDrawArraysInstancedBaseInstance(GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+
+ // OpenGL 4.3 core functions
+ void glTexStorage3DMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexStorage2DMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glTexBufferRange(GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glShaderStorageBlockBinding(GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding);
+ GLint glGetProgramResourceLocationIndex(GLuint program, GLenum programInterface, const GLchar *name);
+ GLint glGetProgramResourceLocation(GLuint program, GLenum programInterface, const GLchar *name);
+ void glGetProgramResourceiv(GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params);
+ void glGetProgramResourceName(GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
+ GLuint glGetProgramResourceIndex(GLuint program, GLenum programInterface, const GLchar *name);
+ void glGetProgramInterfaceiv(GLuint program, GLenum programInterface, GLenum pname, GLint *params);
+ void glMultiDrawElementsIndirect(GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride);
+ void glMultiDrawArraysIndirect(GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride);
+ void glInvalidateSubFramebuffer(GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glInvalidateFramebuffer(GLenum target, GLsizei numAttachments, const GLenum *attachments);
+ void glInvalidateBufferData(GLuint buffer);
+ void glInvalidateBufferSubData(GLuint buffer, GLintptr offset, GLsizeiptr length);
+ void glInvalidateTexImage(GLuint texture, GLint level);
+ void glInvalidateTexSubImage(GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth);
+ void glGetInternalformati64v(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params);
+ void glGetFramebufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glFramebufferParameteri(GLenum target, GLenum pname, GLint param);
+ void glVertexBindingDivisor(GLuint bindingindex, GLuint divisor);
+ void glVertexAttribBinding(GLuint attribindex, GLuint bindingindex);
+ void glVertexAttribLFormat(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void glVertexAttribIFormat(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void glVertexAttribFormat(GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset);
+ void glBindVertexBuffer(GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+ void glTextureView(GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers);
+ void glCopyImageSubData(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 glDispatchComputeIndirect(GLintptr indirect);
+ void glDispatchCompute(GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z);
+ void glClearBufferSubData(GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data);
+ void glClearBufferData(GLenum target, GLenum internalformat, GLenum format, GLenum type, const void *data);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ QOpenGLFunctions_1_0_CoreBackend* d_1_0_Core;
+ QOpenGLFunctions_1_1_CoreBackend* d_1_1_Core;
+ QOpenGLFunctions_1_2_CoreBackend* d_1_2_Core;
+ QOpenGLFunctions_1_3_CoreBackend* d_1_3_Core;
+ QOpenGLFunctions_1_4_CoreBackend* d_1_4_Core;
+ QOpenGLFunctions_1_5_CoreBackend* d_1_5_Core;
+ QOpenGLFunctions_2_0_CoreBackend* d_2_0_Core;
+ QOpenGLFunctions_2_1_CoreBackend* d_2_1_Core;
+ QOpenGLFunctions_3_0_CoreBackend* d_3_0_Core;
+ QOpenGLFunctions_3_1_CoreBackend* d_3_1_Core;
+ QOpenGLFunctions_3_2_CoreBackend* d_3_2_Core;
+ QOpenGLFunctions_3_3_CoreBackend* d_3_3_Core;
+ QOpenGLFunctions_4_0_CoreBackend* d_4_0_Core;
+ QOpenGLFunctions_4_1_CoreBackend* d_4_1_Core;
+ QOpenGLFunctions_4_2_CoreBackend* d_4_2_Core;
+ QOpenGLFunctions_4_3_CoreBackend* d_4_3_Core;
+};
+
+// OpenGL 1.0 core functions
+inline void QOpenGLFunctions_4_3_Core::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Viewport(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDepthRange(GLdouble nearVal, GLdouble farVal)
+{
+ d_1_0_Core->DepthRange(nearVal, farVal);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsEnabled(GLenum cap)
+{
+ return d_1_0_Core->IsEnabled(cap);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetTexLevelParameteriv(GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexLevelParameteriv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetTexLevelParameterfv(GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexLevelParameterfv(target, level, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetTexParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetTexImage(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->GetTexImage(target, level, format, type, pixels);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_3_Core::glGetString(GLenum name)
+{
+ return d_1_0_Core->GetString(name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetIntegerv(GLenum pname, GLint *params)
+{
+ d_1_0_Core->GetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetFloatv(GLenum pname, GLfloat *params)
+{
+ d_1_0_Core->GetFloatv(pname, params);
+}
+
+inline GLenum QOpenGLFunctions_4_3_Core::glGetError()
+{
+ return d_1_0_Core->GetError();
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetDoublev(GLenum pname, GLdouble *params)
+{
+ d_1_0_Core->GetDoublev(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetBooleanv(GLenum pname, GLboolean *params)
+{
+ d_1_0_Core->GetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels)
+{
+ d_1_0_Core->ReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glReadBuffer(GLenum mode)
+{
+ d_1_0_Core->ReadBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glPixelStorei(GLenum pname, GLint param)
+{
+ d_1_0_Core->PixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glPixelStoref(GLenum pname, GLfloat param)
+{
+ d_1_0_Core->PixelStoref(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDepthFunc(GLenum func)
+{
+ d_1_0_Core->DepthFunc(func);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ d_1_0_Core->StencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ d_1_0_Core->StencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glLogicOp(GLenum opcode)
+{
+ d_1_0_Core->LogicOp(opcode);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ d_1_0_Core->BlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glFlush()
+{
+ d_1_0_Core->Flush();
+}
+
+inline void QOpenGLFunctions_4_3_Core::glFinish()
+{
+ d_1_0_Core->Finish();
+}
+
+inline void QOpenGLFunctions_4_3_Core::glEnable(GLenum cap)
+{
+ d_1_0_Core->Enable(cap);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDisable(GLenum cap)
+{
+ d_1_0_Core->Disable(cap);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDepthMask(GLboolean flag)
+{
+ d_1_0_Core->DepthMask(flag);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ d_1_0_Core->ColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glStencilMask(GLuint mask)
+{
+ d_1_0_Core->StencilMask(mask);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glClearDepth(GLdouble depth)
+{
+ d_1_0_Core->ClearDepth(depth);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glClearStencil(GLint s)
+{
+ d_1_0_Core->ClearStencil(s);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glClearColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_0_Core->ClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glClear(GLbitfield mask)
+{
+ d_1_0_Core->Clear(mask);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawBuffer(GLenum mode)
+{
+ d_1_0_Core->DrawBuffer(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexImage1D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_0_Core->TexImage1D(target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexParameteriv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_1_0_Core->TexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_1_0_Core->TexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexParameterfv(GLenum target, GLenum pname, const GLfloat *params)
+{
+ d_1_0_Core->TexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ d_1_0_Core->TexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_0_Core->Scissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glPolygonMode(GLenum face, GLenum mode)
+{
+ d_1_0_Core->PolygonMode(face, mode);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glPointSize(GLfloat size)
+{
+ d_1_0_Core->PointSize(size);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glLineWidth(GLfloat width)
+{
+ d_1_0_Core->LineWidth(width);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glHint(GLenum target, GLenum mode)
+{
+ d_1_0_Core->Hint(target, mode);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glFrontFace(GLenum mode)
+{
+ d_1_0_Core->FrontFace(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCullFace(GLenum mode)
+{
+ d_1_0_Core->CullFace(mode);
+}
+
+
+// OpenGL 1.1 core functions
+inline void QOpenGLFunctions_4_3_Core::glIndexubv(const GLubyte *c)
+{
+ d_1_1_Core->Indexubv(c);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glIndexub(GLubyte c)
+{
+ d_1_1_Core->Indexub(c);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsTexture(GLuint texture)
+{
+ return d_1_1_Core->IsTexture(texture);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGenTextures(GLsizei n, GLuint *textures)
+{
+ d_1_1_Core->GenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDeleteTextures(GLsizei n, const GLuint *textures)
+{
+ d_1_1_Core->DeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindTexture(GLenum target, GLuint texture)
+{
+ d_1_1_Core->BindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_1_Core->TexSubImage1D(target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_1_Core->CopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCopyTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ d_1_1_Core->CopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ d_1_1_Core->CopyTexImage2D(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCopyTexImage1D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ d_1_1_Core->CopyTexImage1D(target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ d_1_1_Core->PolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetPointerv(GLenum pname, GLvoid* *params)
+{
+ d_1_1_Core->GetPointerv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_1_Core->DrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ d_1_1_Core->DrawArrays(mode, first, count);
+}
+
+
+// OpenGL 1.2 core functions
+inline void QOpenGLFunctions_4_3_Core::glCopyTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_1_2_Core->CopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexImage3D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ d_1_2_Core->TexImage3D(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawRangeElements(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ d_1_2_Core->DrawRangeElements(mode, start, end, count, type, indices);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBlendEquation(GLenum mode)
+{
+ d_1_2_Core->BlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBlendColor(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ d_1_2_Core->BlendColor(red, green, blue, alpha);
+}
+
+
+// OpenGL 1.3 core functions
+inline void QOpenGLFunctions_4_3_Core::glGetCompressedTexImage(GLenum target, GLint level, GLvoid *img)
+{
+ d_1_3_Core->GetCompressedTexImage(target, level, img);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCompressedTexSubImage1D(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCompressedTexSubImage3D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCompressedTexImage1D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage1D(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCompressedTexImage3D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ d_1_3_Core->CompressedTexImage3D(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glSampleCoverage(GLfloat value, GLboolean invert)
+{
+ d_1_3_Core->SampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glActiveTexture(GLenum texture)
+{
+ d_1_3_Core->ActiveTexture(texture);
+}
+
+
+// OpenGL 1.4 core functions
+inline void QOpenGLFunctions_4_3_Core::glPointParameteriv(GLenum pname, const GLint *params)
+{
+ d_1_4_Core->PointParameteriv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glPointParameteri(GLenum pname, GLint param)
+{
+ d_1_4_Core->PointParameteri(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glPointParameterfv(GLenum pname, const GLfloat *params)
+{
+ d_1_4_Core->PointParameterfv(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glPointParameterf(GLenum pname, GLfloat param)
+{
+ d_1_4_Core->PointParameterf(pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiDrawElements(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawElements(mode, count, type, indices, drawcount);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiDrawArrays(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount)
+{
+ d_1_4_Core->MultiDrawArrays(mode, first, count, drawcount);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBlendFuncSeparate(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ d_1_4_Core->BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+
+// OpenGL 1.5 core functions
+inline void QOpenGLFunctions_4_3_Core::glGetBufferPointerv(GLenum target, GLenum pname, GLvoid* *params)
+{
+ d_1_5_Core->GetBufferPointerv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetBufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetBufferParameteriv(target, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glUnmapBuffer(GLenum target)
+{
+ return d_1_5_Core->UnmapBuffer(target);
+}
+
+inline GLvoid* QOpenGLFunctions_4_3_Core::glMapBuffer(GLenum target, GLenum access)
+{
+ return d_1_5_Core->MapBuffer(target, access);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ d_1_5_Core->GetBufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ d_1_5_Core->BufferSubData(target, offset, size, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBufferData(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ d_1_5_Core->BufferData(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsBuffer(GLuint buffer)
+{
+ return d_1_5_Core->IsBuffer(buffer);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGenBuffers(GLsizei n, GLuint *buffers)
+{
+ d_1_5_Core->GenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDeleteBuffers(GLsizei n, const GLuint *buffers)
+{
+ d_1_5_Core->DeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindBuffer(GLenum target, GLuint buffer)
+{
+ d_1_5_Core->BindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+{
+ d_1_5_Core->GetQueryObjectuiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryObjectiv(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_1_5_Core->GetQueryiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glEndQuery(GLenum target)
+{
+ d_1_5_Core->EndQuery(target);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBeginQuery(GLenum target, GLuint id)
+{
+ d_1_5_Core->BeginQuery(target, id);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsQuery(GLuint id)
+{
+ return d_1_5_Core->IsQuery(id);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDeleteQueries(GLsizei n, const GLuint *ids)
+{
+ d_1_5_Core->DeleteQueries(n, ids);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGenQueries(GLsizei n, GLuint *ids)
+{
+ d_1_5_Core->GenQueries(n, ids);
+}
+
+
+// OpenGL 2.0 core functions
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ d_2_0_Core->VertexAttribPointer(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glValidateProgram(GLuint program)
+{
+ d_2_0_Core->ValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_0_Core->UniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform4iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform4iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform3iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform3iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform2iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform2iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform1iv(GLint location, GLsizei count, const GLint *value)
+{
+ d_2_0_Core->Uniform1iv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform4fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform4fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform3fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform3fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform2fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform2fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform1fv(GLint location, GLsizei count, const GLfloat *value)
+{
+ d_2_0_Core->Uniform1fv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform4i(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_2_0_Core->Uniform4i(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform3i(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_2_0_Core->Uniform3i(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform2i(GLint location, GLint v0, GLint v1)
+{
+ d_2_0_Core->Uniform2i(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform1i(GLint location, GLint v0)
+{
+ d_2_0_Core->Uniform1i(location, v0);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform4f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_2_0_Core->Uniform4f(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform3f(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_2_0_Core->Uniform3f(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform2f(GLint location, GLfloat v0, GLfloat v1)
+{
+ d_2_0_Core->Uniform2f(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform1f(GLint location, GLfloat v0)
+{
+ d_2_0_Core->Uniform1f(location, v0);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUseProgram(GLuint program)
+{
+ d_2_0_Core->UseProgram(program);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glShaderSource(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length)
+{
+ d_2_0_Core->ShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glLinkProgram(GLuint program)
+{
+ d_2_0_Core->LinkProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsShader(GLuint shader)
+{
+ return d_2_0_Core->IsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsProgram(GLuint program)
+{
+ return d_2_0_Core->IsProgram(program);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ d_2_0_Core->GetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetVertexAttribiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat *params)
+{
+ d_2_0_Core->GetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetVertexAttribdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_2_0_Core->GetVertexAttribdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetUniformiv(GLuint program, GLint location, GLint *params)
+{
+ d_2_0_Core->GetUniformiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetUniformfv(GLuint program, GLint location, GLfloat *params)
+{
+ d_2_0_Core->GetUniformfv(program, location, params);
+}
+
+inline GLint QOpenGLFunctions_4_3_Core::glGetUniformLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetShaderSource(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source)
+{
+ d_2_0_Core->GetShaderSource(shader, bufSize, length, source);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetShaderInfoLog(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetShaderiv(GLuint shader, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetProgramInfoLog(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_2_0_Core->GetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetProgramiv(GLuint program, GLenum pname, GLint *params)
+{
+ d_2_0_Core->GetProgramiv(program, pname, params);
+}
+
+inline GLint QOpenGLFunctions_4_3_Core::glGetAttribLocation(GLuint program, const GLchar *name)
+{
+ return d_2_0_Core->GetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetAttachedShaders(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj)
+{
+ d_2_0_Core->GetAttachedShaders(program, maxCount, count, obj);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveUniform(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name)
+{
+ d_2_0_Core->GetActiveAttrib(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glEnableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->EnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDisableVertexAttribArray(GLuint index)
+{
+ d_2_0_Core->DisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDetachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->DetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDeleteShader(GLuint shader)
+{
+ d_2_0_Core->DeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDeleteProgram(GLuint program)
+{
+ d_2_0_Core->DeleteProgram(program);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Core::glCreateShader(GLenum type)
+{
+ return d_2_0_Core->CreateShader(type);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Core::glCreateProgram()
+{
+ return d_2_0_Core->CreateProgram();
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCompileShader(GLuint shader)
+{
+ d_2_0_Core->CompileShader(shader);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindAttribLocation(GLuint program, GLuint index, const GLchar *name)
+{
+ d_2_0_Core->BindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glAttachShader(GLuint program, GLuint shader)
+{
+ d_2_0_Core->AttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ d_2_0_Core->StencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ d_2_0_Core->StencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glStencilOpSeparate(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ d_2_0_Core->StencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawBuffers(GLsizei n, const GLenum *bufs)
+{
+ d_2_0_Core->DrawBuffers(n, bufs);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ d_2_0_Core->BlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+
+// OpenGL 2.1 core functions
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix4x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix3x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix4x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix4x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix2x4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix3x2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix3x2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix2x3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_2_1_Core->UniformMatrix2x3fv(location, count, transpose, value);
+}
+
+
+// OpenGL 3.0 core functions
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsVertexArray(GLuint array)
+{
+ return d_3_0_Core->IsVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ d_3_0_Core->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ d_3_0_Core->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindVertexArray(GLuint array)
+{
+ d_3_0_Core->BindVertexArray(array);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ d_3_0_Core->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLFunctions_4_3_Core::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ return d_3_0_Core->MapBufferRange(target, offset, length, access);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ d_3_0_Core->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ d_3_0_Core->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGenerateMipmap(GLenum target)
+{
+ d_3_0_Core->GenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ d_3_0_Core->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ d_3_0_Core->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ d_3_0_Core->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLFunctions_4_3_Core::glCheckFramebufferStatus(GLenum target)
+{
+ return d_3_0_Core->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ d_3_0_Core->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ d_3_0_Core->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ d_3_0_Core->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsFramebuffer(GLuint framebuffer)
+{
+ return d_3_0_Core->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_3_0_Core->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ d_3_0_Core->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ d_3_0_Core->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ d_3_0_Core->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return d_3_0_Core->IsRenderbuffer(renderbuffer);
+}
+
+inline const GLubyte * QOpenGLFunctions_4_3_Core::glGetStringi(GLenum name, GLuint index)
+{
+ return d_3_0_Core->GetStringi(name, index);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glClearBufferfi(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ d_3_0_Core->ClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glClearBufferfv(GLenum buffer, GLint drawbuffer, const GLfloat *value)
+{
+ d_3_0_Core->ClearBufferfv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glClearBufferuiv(GLenum buffer, GLint drawbuffer, const GLuint *value)
+{
+ d_3_0_Core->ClearBufferuiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glClearBufferiv(GLenum buffer, GLint drawbuffer, const GLint *value)
+{
+ d_3_0_Core->ClearBufferiv(buffer, drawbuffer, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetTexParameterIuiv(GLenum target, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetTexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetTexParameterIiv(GLenum target, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetTexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexParameterIuiv(GLenum target, GLenum pname, const GLuint *params)
+{
+ d_3_0_Core->TexParameterIuiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexParameterIiv(GLenum target, GLenum pname, const GLint *params)
+{
+ d_3_0_Core->TexParameterIiv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform4uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform4uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform3uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform3uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform2uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform2uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform1uiv(GLint location, GLsizei count, const GLuint *value)
+{
+ d_3_0_Core->Uniform1uiv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform4ui(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_3_0_Core->Uniform4ui(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform3ui(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_3_0_Core->Uniform3ui(location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform2ui(GLint location, GLuint v0, GLuint v1)
+{
+ d_3_0_Core->Uniform2ui(location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform1ui(GLint location, GLuint v0)
+{
+ d_3_0_Core->Uniform1ui(location, v0);
+}
+
+inline GLint QOpenGLFunctions_4_3_Core::glGetFragDataLocation(GLuint program, const GLchar *name)
+{
+ return d_3_0_Core->GetFragDataLocation(program, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindFragDataLocation(GLuint program, GLuint color, const GLchar *name)
+{
+ d_3_0_Core->BindFragDataLocation(program, color, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetUniformuiv(GLuint program, GLint location, GLuint *params)
+{
+ d_3_0_Core->GetUniformuiv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetVertexAttribIuiv(GLuint index, GLenum pname, GLuint *params)
+{
+ d_3_0_Core->GetVertexAttribIuiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetVertexAttribIiv(GLuint index, GLenum pname, GLint *params)
+{
+ d_3_0_Core->GetVertexAttribIiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribIPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_3_0_Core->VertexAttribIPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glEndConditionalRender()
+{
+ d_3_0_Core->EndConditionalRender();
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBeginConditionalRender(GLuint id, GLenum mode)
+{
+ d_3_0_Core->BeginConditionalRender(id, mode);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glClampColor(GLenum target, GLenum clamp)
+{
+ d_3_0_Core->ClampColor(target, clamp);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetTransformFeedbackVarying(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ d_3_0_Core->GetTransformFeedbackVarying(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTransformFeedbackVaryings(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode)
+{
+ d_3_0_Core->TransformFeedbackVaryings(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindBufferBase(GLenum target, GLuint index, GLuint buffer)
+{
+ d_3_0_Core->BindBufferBase(target, index, buffer);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindBufferRange(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_3_0_Core->BindBufferRange(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glEndTransformFeedback()
+{
+ d_3_0_Core->EndTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBeginTransformFeedback(GLenum primitiveMode)
+{
+ d_3_0_Core->BeginTransformFeedback(primitiveMode);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsEnabledi(GLenum target, GLuint index)
+{
+ return d_3_0_Core->IsEnabledi(target, index);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDisablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Disablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glEnablei(GLenum target, GLuint index)
+{
+ d_3_0_Core->Enablei(target, index);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetIntegeri_v(GLenum target, GLuint index, GLint *data)
+{
+ d_3_0_Core->GetIntegeri_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetBooleani_v(GLenum target, GLuint index, GLboolean *data)
+{
+ d_3_0_Core->GetBooleani_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glColorMaski(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ d_3_0_Core->ColorMaski(index, r, g, b, a);
+}
+
+
+// OpenGL 3.1 core functions
+inline void QOpenGLFunctions_4_3_Core::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ d_3_1_Core->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ d_3_1_Core->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ d_3_1_Core->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Core::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ return d_3_1_Core->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ d_3_1_Core->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ d_3_1_Core->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ d_3_1_Core->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glPrimitiveRestartIndex(GLuint index)
+{
+ d_3_1_Core->PrimitiveRestartIndex(index);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexBuffer(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ d_3_1_Core->TexBuffer(target, internalformat, buffer);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawElementsInstanced(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount)
+{
+ d_3_1_Core->DrawElementsInstanced(mode, count, type, indices, instancecount);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawArraysInstanced(GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ d_3_1_Core->DrawArraysInstanced(mode, first, count, instancecount);
+}
+
+
+// OpenGL 3.2 core functions
+inline void QOpenGLFunctions_4_3_Core::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ d_3_2_Core->SampleMaski(index, mask);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ d_3_2_Core->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_3_2_Core->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ d_3_2_Core->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ d_3_2_Core->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLFunctions_4_3_Core::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ return d_3_2_Core->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDeleteSync(GLsync sync)
+{
+ d_3_2_Core->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsSync(GLsync sync)
+{
+ return d_3_2_Core->IsSync(sync);
+}
+
+inline GLsync QOpenGLFunctions_4_3_Core::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ return d_3_2_Core->FenceSync(condition, flags);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProvokingVertex(GLenum mode)
+{
+ d_3_2_Core->ProvokingVertex(mode);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ d_3_2_Core->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ d_3_2_Core->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glFramebufferTexture(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ d_3_2_Core->FramebufferTexture(target, attachment, texture, level);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetBufferParameteri64v(GLenum target, GLenum pname, GLint64 *params)
+{
+ d_3_2_Core->GetBufferParameteri64v(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetInteger64i_v(GLenum target, GLuint index, GLint64 *data)
+{
+ d_3_2_Core->GetInteger64i_v(target, index, data);
+}
+
+
+// OpenGL 3.3 core functions
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP4uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP4ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP3uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP3ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP2uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP2ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ d_3_3_Core->VertexAttribP1uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ d_3_3_Core->VertexAttribP1ui(index, type, normalized, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glSecondaryColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->SecondaryColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glSecondaryColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->SecondaryColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glColorP4uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP4uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glColorP4ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP4ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glColorP3uiv(GLenum type, const GLuint *color)
+{
+ d_3_3_Core->ColorP3uiv(type, color);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glColorP3ui(GLenum type, GLuint color)
+{
+ d_3_3_Core->ColorP3ui(type, color);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glNormalP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->NormalP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glNormalP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->NormalP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP4uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP4ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP3uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP3ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP2uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP2ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->MultiTexCoordP1uiv(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords)
+{
+ d_3_3_Core->MultiTexCoordP1ui(texture, type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexCoordP4uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP4uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexCoordP4ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP4ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexCoordP3uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP3uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexCoordP3ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP3ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexCoordP2uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP2uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexCoordP2ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP2ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexCoordP1uiv(GLenum type, const GLuint *coords)
+{
+ d_3_3_Core->TexCoordP1uiv(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexCoordP1ui(GLenum type, GLuint coords)
+{
+ d_3_3_Core->TexCoordP1ui(type, coords);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexP4uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP4uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexP4ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP4ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexP3uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP3uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexP3ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP3ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexP2uiv(GLenum type, const GLuint *value)
+{
+ d_3_3_Core->VertexP2uiv(type, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexP2ui(GLenum type, GLuint value)
+{
+ d_3_3_Core->VertexP2ui(type, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params)
+{
+ d_3_3_Core->GetQueryObjectui64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params)
+{
+ d_3_3_Core->GetQueryObjecti64v(id, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glQueryCounter(GLuint id, GLenum target)
+{
+ d_3_3_Core->QueryCounter(id, target);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params)
+{
+ d_3_3_Core->GetSamplerParameterIuiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params)
+{
+ d_3_3_Core->GetSamplerParameterfv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameterIiv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params)
+{
+ d_3_3_Core->GetSamplerParameteriv(sampler, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ d_3_3_Core->SamplerParameterIuiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameterIiv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param)
+{
+ d_3_3_Core->SamplerParameterfv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param)
+{
+ d_3_3_Core->SamplerParameterf(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ d_3_3_Core->SamplerParameteriv(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glSamplerParameteri(GLuint sampler, GLenum pname, GLint param)
+{
+ d_3_3_Core->SamplerParameteri(sampler, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindSampler(GLuint unit, GLuint sampler)
+{
+ d_3_3_Core->BindSampler(unit, sampler);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsSampler(GLuint sampler)
+{
+ return d_3_3_Core->IsSampler(sampler);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDeleteSamplers(GLsizei count, const GLuint *samplers)
+{
+ d_3_3_Core->DeleteSamplers(count, samplers);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGenSamplers(GLsizei count, GLuint *samplers)
+{
+ d_3_3_Core->GenSamplers(count, samplers);
+}
+
+inline GLint QOpenGLFunctions_4_3_Core::glGetFragDataIndex(GLuint program, const GLchar *name)
+{
+ return d_3_3_Core->GetFragDataIndex(program, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name)
+{
+ d_3_3_Core->BindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribDivisor(GLuint index, GLuint divisor)
+{
+ d_3_3_Core->VertexAttribDivisor(index, divisor);
+}
+
+
+// OpenGL 4.0 core functions
+inline void QOpenGLFunctions_4_3_Core::glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params)
+{
+ d_4_0_Core->GetQueryIndexediv(target, index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glEndQueryIndexed(GLenum target, GLuint index)
+{
+ d_4_0_Core->EndQueryIndexed(target, index);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBeginQueryIndexed(GLenum target, GLuint index, GLuint id)
+{
+ d_4_0_Core->BeginQueryIndexed(target, index, id);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream)
+{
+ d_4_0_Core->DrawTransformFeedbackStream(mode, id, stream);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawTransformFeedback(GLenum mode, GLuint id)
+{
+ d_4_0_Core->DrawTransformFeedback(mode, id);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glResumeTransformFeedback()
+{
+ d_4_0_Core->ResumeTransformFeedback();
+}
+
+inline void QOpenGLFunctions_4_3_Core::glPauseTransformFeedback()
+{
+ d_4_0_Core->PauseTransformFeedback();
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsTransformFeedback(GLuint id)
+{
+ return d_4_0_Core->IsTransformFeedback(id);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGenTransformFeedbacks(GLsizei n, GLuint *ids)
+{
+ d_4_0_Core->GenTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids)
+{
+ d_4_0_Core->DeleteTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindTransformFeedback(GLenum target, GLuint id)
+{
+ d_4_0_Core->BindTransformFeedback(target, id);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glPatchParameterfv(GLenum pname, const GLfloat *values)
+{
+ d_4_0_Core->PatchParameterfv(pname, values);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glPatchParameteri(GLenum pname, GLint value)
+{
+ d_4_0_Core->PatchParameteri(pname, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetProgramStageiv(program, shadertype, pname, values);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params)
+{
+ d_4_0_Core->GetUniformSubroutineuiv(shadertype, location, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices)
+{
+ d_4_0_Core->UniformSubroutinesuiv(shadertype, count, indices);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ d_4_0_Core->GetActiveSubroutineUniformName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values)
+{
+ d_4_0_Core->GetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Core::glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineIndex(program, shadertype, name);
+}
+
+inline GLint QOpenGLFunctions_4_3_Core::glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ return d_4_0_Core->GetSubroutineUniformLocation(program, shadertype, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetUniformdv(GLuint program, GLint location, GLdouble *params)
+{
+ d_4_0_Core->GetUniformdv(program, location, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_0_Core->UniformMatrix2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform4dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform4dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform3dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform3dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform2dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform2dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform1dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_0_Core->Uniform1dv(location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_0_Core->Uniform4d(location, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_0_Core->Uniform3d(location, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform2d(GLint location, GLdouble x, GLdouble y)
+{
+ d_4_0_Core->Uniform2d(location, x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUniform1d(GLint location, GLdouble x)
+{
+ d_4_0_Core->Uniform1d(location, x);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawElementsIndirect(mode, type, indirect);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawArraysIndirect(GLenum mode, const GLvoid *indirect)
+{
+ d_4_0_Core->DrawArraysIndirect(mode, indirect);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBlendFuncSeparatei(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ d_4_0_Core->BlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBlendFunci(GLuint buf, GLenum src, GLenum dst)
+{
+ d_4_0_Core->BlendFunci(buf, src, dst);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBlendEquationSeparatei(GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ d_4_0_Core->BlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBlendEquationi(GLuint buf, GLenum mode)
+{
+ d_4_0_Core->BlendEquationi(buf, mode);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMinSampleShading(GLfloat value)
+{
+ d_4_0_Core->MinSampleShading(value);
+}
+
+
+// OpenGL 4.1 core functions
+inline void QOpenGLFunctions_4_3_Core::glGetDoublei_v(GLenum target, GLuint index, GLdouble *data)
+{
+ d_4_1_Core->GetDoublei_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetFloati_v(GLenum target, GLuint index, GLfloat *data)
+{
+ d_4_1_Core->GetFloati_v(target, index, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f)
+{
+ d_4_1_Core->DepthRangeIndexed(index, n, f);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v)
+{
+ d_4_1_Core->DepthRangeArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glScissorIndexedv(GLuint index, const GLint *v)
+{
+ d_4_1_Core->ScissorIndexedv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ d_4_1_Core->ScissorIndexed(index, left, bottom, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glScissorArrayv(GLuint first, GLsizei count, const GLint *v)
+{
+ d_4_1_Core->ScissorArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glViewportIndexedfv(GLuint index, const GLfloat *v)
+{
+ d_4_1_Core->ViewportIndexedfv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ d_4_1_Core->ViewportIndexedf(index, x, y, w, h);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v)
+{
+ d_4_1_Core->ViewportArrayv(first, count, v);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ d_4_1_Core->GetVertexAttribLdv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ d_4_1_Core->VertexAttribLPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribL4dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL4dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribL3dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL3dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribL2dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL2dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribL1dv(GLuint index, const GLdouble *v)
+{
+ d_4_1_Core->VertexAttribL1dv(index, v);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ d_4_1_Core->VertexAttribL4d(index, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ d_4_1_Core->VertexAttribL3d(index, x, y, z);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y)
+{
+ d_4_1_Core->VertexAttribL2d(index, x, y);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribL1d(GLuint index, GLdouble x)
+{
+ d_4_1_Core->VertexAttribL1d(index, x);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ d_4_1_Core->GetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glValidateProgramPipeline(GLuint pipeline)
+{
+ d_4_1_Core->ValidateProgramPipeline(pipeline);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform4uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ d_4_1_Core->ProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform4dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ d_4_1_Core->ProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform4fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ d_4_1_Core->ProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform4iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ d_4_1_Core->ProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform3uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ d_4_1_Core->ProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform3dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ d_4_1_Core->ProgramUniform3d(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform3fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ d_4_1_Core->ProgramUniform3f(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform3iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ d_4_1_Core->ProgramUniform3i(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform2uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ d_4_1_Core->ProgramUniform2ui(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform2dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ d_4_1_Core->ProgramUniform2d(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform2fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ d_4_1_Core->ProgramUniform2f(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform2iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1)
+{
+ d_4_1_Core->ProgramUniform2i(program, location, v0, v1);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ d_4_1_Core->ProgramUniform1uiv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform1ui(GLuint program, GLint location, GLuint v0)
+{
+ d_4_1_Core->ProgramUniform1ui(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ d_4_1_Core->ProgramUniform1dv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform1d(GLuint program, GLint location, GLdouble v0)
+{
+ d_4_1_Core->ProgramUniform1d(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ d_4_1_Core->ProgramUniform1fv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform1f(GLuint program, GLint location, GLfloat v0)
+{
+ d_4_1_Core->ProgramUniform1f(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ d_4_1_Core->ProgramUniform1iv(program, location, count, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramUniform1i(GLuint program, GLint location, GLint v0)
+{
+ d_4_1_Core->ProgramUniform1i(program, location, v0);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params)
+{
+ d_4_1_Core->GetProgramPipelineiv(pipeline, pname, params);
+}
+
+inline GLboolean QOpenGLFunctions_4_3_Core::glIsProgramPipeline(GLuint pipeline)
+{
+ return d_4_1_Core->IsProgramPipeline(pipeline);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGenProgramPipelines(GLsizei n, GLuint *pipelines)
+{
+ d_4_1_Core->GenProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines)
+{
+ d_4_1_Core->DeleteProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindProgramPipeline(GLuint pipeline)
+{
+ d_4_1_Core->BindProgramPipeline(pipeline);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Core::glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings)
+{
+ return d_4_1_Core->CreateShaderProgramv(type, count, strings);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glActiveShaderProgram(GLuint pipeline, GLuint program)
+{
+ d_4_1_Core->ActiveShaderProgram(pipeline, program);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ d_4_1_Core->UseProgramStages(pipeline, stages, program);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramParameteri(GLuint program, GLenum pname, GLint value)
+{
+ d_4_1_Core->ProgramParameteri(program, pname, value);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length)
+{
+ d_4_1_Core->ProgramBinary(program, binaryFormat, binary, length);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary)
+{
+ d_4_1_Core->GetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glClearDepthf(GLfloat dd)
+{
+ d_4_1_Core->ClearDepthf(dd);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDepthRangef(GLfloat n, GLfloat f)
+{
+ d_4_1_Core->DepthRangef(n, f);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision)
+{
+ d_4_1_Core->GetShaderPrecisionFormat(shadertype, precisiontype, range, precision);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length)
+{
+ d_4_1_Core->ShaderBinary(count, shaders, binaryformat, binary, length);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glReleaseShaderCompiler()
+{
+ d_4_1_Core->ReleaseShaderCompiler();
+}
+
+
+// OpenGL 4.2 core functions
+inline void QOpenGLFunctions_4_3_Core::glTexStorage3D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ d_4_2_Core->TexStorage3D(target, levels, internalformat, width, height, depth);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ d_4_2_Core->TexStorage2D(target, levels, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexStorage1D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width)
+{
+ d_4_2_Core->TexStorage1D(target, levels, internalformat, width);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMemoryBarrier(GLbitfield barriers)
+{
+ d_4_2_Core->MemoryBarrier(barriers);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindImageTexture(GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format)
+{
+ d_4_2_Core->BindImageTexture(unit, texture, level, layered, layer, access, format);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetActiveAtomicCounterBufferiv(GLuint program, GLuint bufferIndex, GLenum pname, GLint *params)
+{
+ d_4_2_Core->GetActiveAtomicCounterBufferiv(program, bufferIndex, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetInternalformativ(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params)
+{
+ d_4_2_Core->GetInternalformativ(target, internalformat, pname, bufSize, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawTransformFeedbackStreamInstanced(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount)
+{
+ d_4_2_Core->DrawTransformFeedbackStreamInstanced(mode, id, stream, instancecount);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawTransformFeedbackInstanced(GLenum mode, GLuint id, GLsizei instancecount)
+{
+ d_4_2_Core->DrawTransformFeedbackInstanced(mode, id, instancecount);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawElementsInstancedBaseVertexBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance)
+{
+ d_4_2_Core->DrawElementsInstancedBaseVertexBaseInstance(mode, count, type, indices, instancecount, basevertex, baseinstance);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawElementsInstancedBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance)
+{
+ d_4_2_Core->DrawElementsInstancedBaseInstance(mode, count, type, indices, instancecount, baseinstance);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDrawArraysInstancedBaseInstance(GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance)
+{
+ d_4_2_Core->DrawArraysInstancedBaseInstance(mode, first, count, instancecount, baseinstance);
+}
+
+
+// OpenGL 4.3 core functions
+inline void QOpenGLFunctions_4_3_Core::glTexStorage3DMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ d_4_3_Core->TexStorage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexStorage2DMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ d_4_3_Core->TexStorage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTexBufferRange(GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ d_4_3_Core->TexBufferRange(target, internalformat, buffer, offset, size);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glShaderStorageBlockBinding(GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding)
+{
+ d_4_3_Core->ShaderStorageBlockBinding(program, storageBlockIndex, storageBlockBinding);
+}
+
+inline GLint QOpenGLFunctions_4_3_Core::glGetProgramResourceLocationIndex(GLuint program, GLenum programInterface, const GLchar *name)
+{
+ return d_4_3_Core->GetProgramResourceLocationIndex(program, programInterface, name);
+}
+
+inline GLint QOpenGLFunctions_4_3_Core::glGetProgramResourceLocation(GLuint program, GLenum programInterface, const GLchar *name)
+{
+ return d_4_3_Core->GetProgramResourceLocation(program, programInterface, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetProgramResourceiv(GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params)
+{
+ d_4_3_Core->GetProgramResourceiv(program, programInterface, index, propCount, props, bufSize, length, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetProgramResourceName(GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name)
+{
+ d_4_3_Core->GetProgramResourceName(program, programInterface, index, bufSize, length, name);
+}
+
+inline GLuint QOpenGLFunctions_4_3_Core::glGetProgramResourceIndex(GLuint program, GLenum programInterface, const GLchar *name)
+{
+ return d_4_3_Core->GetProgramResourceIndex(program, programInterface, name);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetProgramInterfaceiv(GLuint program, GLenum programInterface, GLenum pname, GLint *params)
+{
+ d_4_3_Core->GetProgramInterfaceiv(program, programInterface, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiDrawElementsIndirect(GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride)
+{
+ d_4_3_Core->MultiDrawElementsIndirect(mode, type, indirect, drawcount, stride);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glMultiDrawArraysIndirect(GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride)
+{
+ d_4_3_Core->MultiDrawArraysIndirect(mode, indirect, drawcount, stride);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glInvalidateSubFramebuffer(GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ d_4_3_Core->InvalidateSubFramebuffer(target, numAttachments, attachments, x, y, width, height);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glInvalidateFramebuffer(GLenum target, GLsizei numAttachments, const GLenum *attachments)
+{
+ d_4_3_Core->InvalidateFramebuffer(target, numAttachments, attachments);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glInvalidateBufferData(GLuint buffer)
+{
+ d_4_3_Core->InvalidateBufferData(buffer);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glInvalidateBufferSubData(GLuint buffer, GLintptr offset, GLsizeiptr length)
+{
+ d_4_3_Core->InvalidateBufferSubData(buffer, offset, length);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glInvalidateTexImage(GLuint texture, GLint level)
+{
+ d_4_3_Core->InvalidateTexImage(texture, level);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glInvalidateTexSubImage(GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth)
+{
+ d_4_3_Core->InvalidateTexSubImage(texture, level, xoffset, yoffset, zoffset, width, height, depth);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetInternalformati64v(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params)
+{
+ d_4_3_Core->GetInternalformati64v(target, internalformat, pname, bufSize, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glGetFramebufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ d_4_3_Core->GetFramebufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glFramebufferParameteri(GLenum target, GLenum pname, GLint param)
+{
+ d_4_3_Core->FramebufferParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexBindingDivisor(GLuint bindingindex, GLuint divisor)
+{
+ d_4_3_Core->VertexBindingDivisor(bindingindex, divisor);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribBinding(GLuint attribindex, GLuint bindingindex)
+{
+ d_4_3_Core->VertexAttribBinding(attribindex, bindingindex);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribLFormat(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset)
+{
+ d_4_3_Core->VertexAttribLFormat(attribindex, size, type, relativeoffset);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribIFormat(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset)
+{
+ d_4_3_Core->VertexAttribIFormat(attribindex, size, type, relativeoffset);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glVertexAttribFormat(GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset)
+{
+ d_4_3_Core->VertexAttribFormat(attribindex, size, type, normalized, relativeoffset);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glBindVertexBuffer(GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride)
+{
+ d_4_3_Core->BindVertexBuffer(bindingindex, buffer, offset, stride);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glTextureView(GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers)
+{
+ d_4_3_Core->TextureView(texture, target, origtexture, internalformat, minlevel, numlevels, minlayer, numlayers);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glCopyImageSubData(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)
+{
+ d_4_3_Core->CopyImageSubData(srcName, srcTarget, srcLevel, srcX, srcY, srcZ, dstName, dstTarget, dstLevel, dstX, dstY, dstZ, srcWidth, srcHeight, srcDepth);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDispatchComputeIndirect(GLintptr indirect)
+{
+ d_4_3_Core->DispatchComputeIndirect(indirect);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glDispatchCompute(GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z)
+{
+ d_4_3_Core->DispatchCompute(num_groups_x, num_groups_y, num_groups_z);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glClearBufferSubData(GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data)
+{
+ d_4_3_Core->ClearBufferSubData(target, internalformat, offset, size, format, type, data);
+}
+
+inline void QOpenGLFunctions_4_3_Core::glClearBufferData(GLenum target, GLenum internalformat, GLenum format, GLenum type, const void *data)
+{
+ d_4_3_Core->ClearBufferData(target, internalformat, format, type, data);
+}
+
+
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglfunctions_es2.cpp b/src/gui/opengl/qopenglfunctions_es2.cpp
new file mode 100644
index 0000000000..afac017d53
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_es2.cpp
@@ -0,0 +1,103 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qopenglfunctions_es2.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+/*!
+ \class QOpenGLFunctions_ES2
+ \inmodule QtGui
+ \since 5.1
+ \brief The QOpenGLFunctions_ES2 class provides all functions for OpenGL ES 2
+
+ \sa QAbstractOpenGLFunctions
+*/
+
+QOpenGLFunctions_ES2::QOpenGLFunctions_ES2()
+ : QAbstractOpenGLFunctions()
+ , d_es2(0)
+{
+}
+
+QOpenGLFunctions_ES2::~QOpenGLFunctions_ES2()
+{
+}
+
+bool QOpenGLFunctions_ES2::initializeOpenGLFunctions()
+{
+ if ( isInitialized() )
+ return true;
+
+ QOpenGLContext* context = QOpenGLContext::currentContext();
+
+ // If owned by a context object make sure it is current.
+ // Also check that current context is compatible
+ if (((owningContext() && owningContext() == context) || !owningContext())
+ && QOpenGLFunctions_ES2::isContextCompatible(context))
+ {
+ // Nothing to do, just flag that we are initialized
+ QAbstractOpenGLFunctions::initializeOpenGLFunctions();
+ }
+ return isInitialized();
+}
+
+bool QOpenGLFunctions_ES2::isContextCompatible(QOpenGLContext *context)
+{
+ Q_ASSERT(context);
+ QSurfaceFormat f = context->format();
+ const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());
+ if (v < qMakePair(2, 0))
+ return false;
+ if (f.renderableType() != QSurfaceFormat::OpenGLES)
+ return false;
+
+ return true;
+}
+
+QOpenGLVersionProfile QOpenGLFunctions_ES2::versionProfile()
+{
+ QOpenGLVersionProfile v;
+ return v;
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglfunctions_es2.h b/src/gui/opengl/qopenglfunctions_es2.h
new file mode 100644
index 0000000000..9c14567723
--- /dev/null
+++ b/src/gui/opengl/qopenglfunctions_es2.h
@@ -0,0 +1,933 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_ES2_H
+#define QOPENGLVERSIONFUNCTIONS_ES2_H
+
+#include <QtCore/qglobal.h>
+
+#if defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class QOpenGLFunctions_ES2Private;
+
+class Q_GUI_EXPORT QOpenGLFunctions_ES2 : public QAbstractOpenGLFunctions
+{
+public:
+ QOpenGLFunctions_ES2();
+ ~QOpenGLFunctions_ES2();
+
+ bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;
+
+ // OpenGL ES2 core functions
+ void glActiveTexture(GLenum texture);
+ void glAttachShader(GLuint program, GLuint shader);
+ void glBindAttribLocation(GLuint program, GLuint index, const GLchar* name);
+ void glBindBuffer(GLenum target, GLuint buffer);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ void glBindTexture(GLenum target, GLuint texture);
+ void glBlendColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha);
+ void glBlendEquation(GLenum mode);
+ void glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha);
+ void glBlendFunc(GLenum sfactor, GLenum dfactor);
+ void glBlendFuncSeparate(GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void glBufferData(GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+ void glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glClear(GLbitfield mask);
+ void glClearColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha);
+ void glClearDepthf(GLclampf depth);
+ void glClearStencil(GLint s);
+ void glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void glCompileShader(GLuint shader);
+ void glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+ void glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+ void glCopyTexImage2D(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ GLuint glCreateProgram(void);
+ GLuint glCreateShader(GLenum type);
+ void glCullFace(GLenum mode);
+ void glDeleteBuffers(GLsizei n, const GLuint* buffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint* framebuffers);
+ void glDeleteProgram(GLuint program);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint* renderbuffers);
+ void glDeleteShader(GLuint shader);
+ void glDeleteTextures(GLsizei n, const GLuint* textures);
+ void glDepthFunc(GLenum func);
+ void glDepthMask(GLboolean flag);
+ void glDepthRangef(GLclampf zNear, GLclampf zFar);
+ void glDetachShader(GLuint program, GLuint shader);
+ void glDisable(GLenum cap);
+ void glDisableVertexAttribArray(GLuint index);
+ void glDrawArrays(GLenum mode, GLint first, GLsizei count);
+ void glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid* indices);
+ void glEnable(GLenum cap);
+ void glEnableVertexAttribArray(GLuint index);
+ void glFinish(void);
+ void glFlush(void);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFrontFace(GLenum mode);
+ void glGenBuffers(GLsizei n, GLuint* buffers);
+ void glGenerateMipmap(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint* framebuffers);
+ void glGenRenderbuffers(GLsizei n, GLuint* renderbuffers);
+ void glGenTextures(GLsizei n, GLuint* textures);
+ void glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufsize, GLsizei* length, GLint* size, GLenum* type, GLchar* name);
+ void glGetActiveUniform(GLuint program, GLuint index, GLsizei bufsize, GLsizei* length, GLint* size, GLenum* type, GLchar* name);
+ void glGetAttachedShaders(GLuint program, GLsizei maxcount, GLsizei* count, GLuint* shaders);
+ int glGetAttribLocation(GLuint program, const GLchar* name);
+ void glGetBooleanv(GLenum pname, GLboolean* params);
+ void glGetBufferParameteriv(GLenum target, GLenum pname, GLint* params);
+ GLenum glGetError(void);
+ void glGetFloatv(GLenum pname, GLfloat* params);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint* params);
+ void glGetIntegerv(GLenum pname, GLint* params);
+ void glGetProgramiv(GLuint program, GLenum pname, GLint* params);
+ void glGetProgramInfoLog(GLuint program, GLsizei bufsize, GLsizei* length, GLchar* infolog);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint* params);
+ void glGetShaderiv(GLuint shader, GLenum pname, GLint* params);
+ void glGetShaderInfoLog(GLuint shader, GLsizei bufsize, GLsizei* length, GLchar* infolog);
+ void glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint* range, GLint* precision);
+ void glGetShaderSource(GLuint shader, GLsizei bufsize, GLsizei* length, GLchar* source);
+ const GLubyte* glGetString(GLenum name);
+ void glGetTexParameterfv(GLenum target, GLenum pname, GLfloat* params);
+ void glGetTexParameteriv(GLenum target, GLenum pname, GLint* params);
+ void glGetUniformfv(GLuint program, GLint location, GLfloat* params);
+ void glGetUniformiv(GLuint program, GLint location, GLint* params);
+ int glGetUniformLocation(GLuint program, const GLchar* name);
+ void glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat* params);
+ void glGetVertexAttribiv(GLuint index, GLenum pname, GLint* params);
+ void glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid** pointer);
+ void glHint(GLenum target, GLenum mode);
+ GLboolean glIsBuffer(GLuint buffer);
+ GLboolean glIsEnabled(GLenum cap);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ GLboolean glIsProgram(GLuint program);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+ GLboolean glIsShader(GLuint shader);
+ GLboolean glIsTexture(GLuint texture);
+ void glLineWidth(GLfloat width);
+ void glLinkProgram(GLuint program);
+ void glPixelStorei(GLenum pname, GLint param);
+ void glPolygonOffset(GLfloat factor, GLfloat units);
+ void glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid* pixels);
+ void glReleaseShaderCompiler(void);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glSampleCoverage(GLclampf value, GLboolean invert);
+ void glScissor(GLint x, GLint y, GLsizei width, GLsizei height);
+ void glShaderBinary(GLsizei n, const GLuint* shaders, GLenum binaryformat, const GLvoid* binary, GLsizei length);
+ void glShaderSource(GLuint shader, GLsizei count, const GLchar* *string, const GLint* length);
+ void glStencilFunc(GLenum func, GLint ref, GLuint mask);
+ void glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void glStencilMask(GLuint mask);
+ void glStencilMaskSeparate(GLenum face, GLuint mask);
+ void glStencilOp(GLenum fail, GLenum zfail, GLenum zpass);
+ void glStencilOpSeparate(GLenum face, GLenum fail, GLenum zfail, GLenum zpass);
+ void glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid* pixels);
+ void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
+ void glTexParameterfv(GLenum target, GLenum pname, const GLfloat* params);
+ void glTexParameteri(GLenum target, GLenum pname, GLint param);
+ void glTexParameteriv(GLenum target, GLenum pname, const GLint* params);
+ void glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid* pixels);
+ void glUniform1f(GLint location, GLfloat x);
+ void glUniform1fv(GLint location, GLsizei count, const GLfloat* v);
+ void glUniform1i(GLint location, GLint x);
+ void glUniform1iv(GLint location, GLsizei count, const GLint* v);
+ void glUniform2f(GLint location, GLfloat x, GLfloat y);
+ void glUniform2fv(GLint location, GLsizei count, const GLfloat* v);
+ void glUniform2i(GLint location, GLint x, GLint y);
+ void glUniform2iv(GLint location, GLsizei count, const GLint* v);
+ void glUniform3f(GLint location, GLfloat x, GLfloat y, GLfloat z);
+ void glUniform3fv(GLint location, GLsizei count, const GLfloat* v);
+ void glUniform3i(GLint location, GLint x, GLint y, GLint z);
+ void glUniform3iv(GLint location, GLsizei count, const GLint* v);
+ void glUniform4f(GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glUniform4fv(GLint location, GLsizei count, const GLfloat* v);
+ void glUniform4i(GLint location, GLint x, GLint y, GLint z, GLint w);
+ void glUniform4iv(GLint location, GLsizei count, const GLint* v);
+ void glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+ void glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+ void glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+ void glUseProgram(GLuint program);
+ void glValidateProgram(GLuint program);
+ void glVertexAttrib1f(GLuint indx, GLfloat x);
+ void glVertexAttrib1fv(GLuint indx, const GLfloat* values);
+ void glVertexAttrib2f(GLuint indx, GLfloat x, GLfloat y);
+ void glVertexAttrib2fv(GLuint indx, const GLfloat* values);
+ void glVertexAttrib3f(GLuint indx, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexAttrib3fv(GLuint indx, const GLfloat* values);
+ void glVertexAttrib4f(GLuint indx, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexAttrib4fv(GLuint indx, const GLfloat* values);
+ void glVertexAttribPointer(GLuint indx, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid* ptr);
+ void glViewport(GLint x, GLint y, GLsizei width, GLsizei height);
+
+private:
+ friend class QOpenGLContext;
+
+ static bool isContextCompatible(QOpenGLContext *context);
+ static QOpenGLVersionProfile versionProfile();
+
+ // For future expansion - not used
+ QOpenGLFunctions_ES2Private* d_es2;
+};
+
+// OpenGL ES2 core functions
+inline void QOpenGLFunctions_ES2::glActiveTexture(GLenum texture)
+{
+ ::glActiveTexture(texture);
+}
+
+inline void QOpenGLFunctions_ES2::glAttachShader(GLuint program, GLuint shader)
+{
+ ::glAttachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_ES2::glBindAttribLocation(GLuint program, GLuint index, const GLchar* name)
+{
+ ::glBindAttribLocation(program, index, name);
+}
+
+inline void QOpenGLFunctions_ES2::glBindBuffer(GLenum target, GLuint buffer)
+{
+ ::glBindBuffer(target, buffer);
+}
+
+inline void QOpenGLFunctions_ES2::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ ::glBindFramebuffer(target, framebuffer);
+}
+
+inline void QOpenGLFunctions_ES2::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ ::glBindRenderbuffer(target, renderbuffer);
+}
+
+inline void QOpenGLFunctions_ES2::glBindTexture(GLenum target, GLuint texture)
+{
+ ::glBindTexture(target, texture);
+}
+
+inline void QOpenGLFunctions_ES2::glBlendColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha)
+{
+ ::glBlendColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_ES2::glBlendEquation(GLenum mode)
+{
+ ::glBlendEquation(mode);
+}
+
+inline void QOpenGLFunctions_ES2::glBlendEquationSeparate(GLenum modeRGB, GLenum modeAlpha)
+{
+ ::glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+inline void QOpenGLFunctions_ES2::glBlendFunc(GLenum sfactor, GLenum dfactor)
+{
+ ::glBlendFunc(sfactor, dfactor);
+}
+
+inline void QOpenGLFunctions_ES2::glBlendFuncSeparate(GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ ::glBlendFuncSeparate(srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+inline void QOpenGLFunctions_ES2::glBufferData(GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ ::glBufferData(target, size, data, usage);
+}
+
+inline void QOpenGLFunctions_ES2::glBufferSubData(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ ::glBufferSubData(target, offset, size, data);
+}
+
+inline GLenum QOpenGLFunctions_ES2::glCheckFramebufferStatus(GLenum target)
+{
+ return ::glCheckFramebufferStatus(target);
+}
+
+inline void QOpenGLFunctions_ES2::glClear(GLbitfield mask)
+{
+ ::glClear(mask);
+}
+
+inline void QOpenGLFunctions_ES2::glClearColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha)
+{
+ ::glClearColor(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_ES2::glClearDepthf(GLclampf depth)
+{
+ ::glClearDepthf(depth);
+}
+
+inline void QOpenGLFunctions_ES2::glClearStencil(GLint s)
+{
+ ::glClearStencil(s);
+}
+
+inline void QOpenGLFunctions_ES2::glColorMask(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ ::glColorMask(red, green, blue, alpha);
+}
+
+inline void QOpenGLFunctions_ES2::glCompileShader(GLuint shader)
+{
+ ::glCompileShader(shader);
+}
+
+inline void QOpenGLFunctions_ES2::glCompressedTexImage2D(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ ::glCompressedTexImage2D(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLFunctions_ES2::glCompressedTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ ::glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLFunctions_ES2::glCopyTexImage2D(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);
+}
+
+inline void QOpenGLFunctions_ES2::glCopyTexSubImage2D(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);
+}
+
+inline GLuint QOpenGLFunctions_ES2::glCreateProgram(void)
+{
+ return ::glCreateProgram();
+}
+
+inline GLuint QOpenGLFunctions_ES2::glCreateShader(GLenum type)
+{
+ return ::glCreateShader(type);
+}
+
+inline void QOpenGLFunctions_ES2::glCullFace(GLenum mode)
+{
+ ::glCullFace(mode);
+}
+
+inline void QOpenGLFunctions_ES2::glDeleteBuffers(GLsizei n, const GLuint* buffers)
+{
+ ::glDeleteBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_ES2::glDeleteFramebuffers(GLsizei n, const GLuint* framebuffers)
+{
+ ::glDeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_ES2::glDeleteProgram(GLuint program)
+{
+ ::glDeleteProgram(program);
+}
+
+inline void QOpenGLFunctions_ES2::glDeleteRenderbuffers(GLsizei n, const GLuint* renderbuffers)
+{
+ ::glDeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_ES2::glDeleteShader(GLuint shader)
+{
+ ::glDeleteShader(shader);
+}
+
+inline void QOpenGLFunctions_ES2::glDeleteTextures(GLsizei n, const GLuint* textures)
+{
+ ::glDeleteTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_ES2::glDepthFunc(GLenum func)
+{
+ ::glDepthFunc(func);
+}
+
+inline void QOpenGLFunctions_ES2::glDepthMask(GLboolean flag)
+{
+ ::glDepthMask(flag);
+}
+
+inline void QOpenGLFunctions_ES2::glDepthRangef(GLclampf zNear, GLclampf zFar)
+{
+ ::glDepthRangef(zNear, zFar);
+}
+
+inline void QOpenGLFunctions_ES2::glDetachShader(GLuint program, GLuint shader)
+{
+ ::glDetachShader(program, shader);
+}
+
+inline void QOpenGLFunctions_ES2::glDisable(GLenum cap)
+{
+ ::glDisable(cap);
+}
+
+inline void QOpenGLFunctions_ES2::glDisableVertexAttribArray(GLuint index)
+{
+ ::glDisableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_ES2::glDrawArrays(GLenum mode, GLint first, GLsizei count)
+{
+ ::glDrawArrays(mode, first, count);
+}
+
+inline void QOpenGLFunctions_ES2::glDrawElements(GLenum mode, GLsizei count, GLenum type, const GLvoid* indices)
+{
+ ::glDrawElements(mode, count, type, indices);
+}
+
+inline void QOpenGLFunctions_ES2::glEnable(GLenum cap)
+{
+ ::glEnable(cap);
+}
+
+inline void QOpenGLFunctions_ES2::glEnableVertexAttribArray(GLuint index)
+{
+ ::glEnableVertexAttribArray(index);
+}
+
+inline void QOpenGLFunctions_ES2::glFinish(void)
+{
+ ::glFinish();
+}
+
+inline void QOpenGLFunctions_ES2::glFlush(void)
+{
+ ::glFlush();
+}
+
+inline void QOpenGLFunctions_ES2::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ ::glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLFunctions_ES2::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ ::glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLFunctions_ES2::glFrontFace(GLenum mode)
+{
+ ::glFrontFace(mode);
+}
+
+inline void QOpenGLFunctions_ES2::glGenBuffers(GLsizei n, GLuint* buffers)
+{
+ ::glGenBuffers(n, buffers);
+}
+
+inline void QOpenGLFunctions_ES2::glGenerateMipmap(GLenum target)
+{
+ ::glGenerateMipmap(target);
+}
+
+inline void QOpenGLFunctions_ES2::glGenFramebuffers(GLsizei n, GLuint* framebuffers)
+{
+ ::glGenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLFunctions_ES2::glGenRenderbuffers(GLsizei n, GLuint* renderbuffers)
+{
+ ::glGenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLFunctions_ES2::glGenTextures(GLsizei n, GLuint* textures)
+{
+ ::glGenTextures(n, textures);
+}
+
+inline void QOpenGLFunctions_ES2::glGetActiveAttrib(GLuint program, GLuint index, GLsizei bufsize, GLsizei* length, GLint* size, GLenum* type, GLchar* name)
+{
+ ::glGetActiveAttrib(program, index, bufsize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_ES2::glGetActiveUniform(GLuint program, GLuint index, GLsizei bufsize, GLsizei* length, GLint* size, GLenum* type, GLchar* name)
+{
+ ::glGetActiveUniform(program, index, bufsize, length, size, type, name);
+}
+
+inline void QOpenGLFunctions_ES2::glGetAttachedShaders(GLuint program, GLsizei maxcount, GLsizei* count, GLuint* shaders)
+{
+ ::glGetAttachedShaders(program, maxcount, count, shaders);
+}
+
+inline int QOpenGLFunctions_ES2::glGetAttribLocation(GLuint program, const GLchar* name)
+{
+ return ::glGetAttribLocation(program, name);
+}
+
+inline void QOpenGLFunctions_ES2::glGetBooleanv(GLenum pname, GLboolean* params)
+{
+ ::glGetBooleanv(pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glGetBufferParameteriv(GLenum target, GLenum pname, GLint* params)
+{
+ ::glGetBufferParameteriv(target, pname, params);
+}
+
+inline GLenum QOpenGLFunctions_ES2::glGetError(void)
+{
+ return ::glGetError();
+}
+
+inline void QOpenGLFunctions_ES2::glGetFloatv(GLenum pname, GLfloat* params)
+{
+ ::glGetFloatv(pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ ::glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glGetIntegerv(GLenum pname, GLint* params)
+{
+ ::glGetIntegerv(pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glGetProgramiv(GLuint program, GLenum pname, GLint* params)
+{
+ ::glGetProgramiv(program, pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glGetProgramInfoLog(GLuint program, GLsizei bufsize, GLsizei* length, GLchar* infolog)
+{
+ ::glGetProgramInfoLog(program, bufsize, length, infolog);
+}
+
+inline void QOpenGLFunctions_ES2::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint* params)
+{
+ ::glGetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glGetShaderiv(GLuint shader, GLenum pname, GLint* params)
+{
+ ::glGetShaderiv(shader, pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glGetShaderInfoLog(GLuint shader, GLsizei bufsize, GLsizei* length, GLchar* infolog)
+{
+ ::glGetShaderInfoLog(shader, bufsize, length, infolog);
+}
+
+inline void QOpenGLFunctions_ES2::glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint* range, GLint* precision)
+{
+ ::glGetShaderPrecisionFormat(shadertype, precisiontype, range, precision);
+}
+
+inline void QOpenGLFunctions_ES2::glGetShaderSource(GLuint shader, GLsizei bufsize, GLsizei* length, GLchar* source)
+{
+ ::glGetShaderSource(shader, bufsize, length, source);
+}
+
+inline const GLubyte* QOpenGLFunctions_ES2::glGetString(GLenum name)
+{
+ return ::glGetString(name);
+}
+
+inline void QOpenGLFunctions_ES2::glGetTexParameterfv(GLenum target, GLenum pname, GLfloat* params)
+{
+ ::glGetTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glGetTexParameteriv(GLenum target, GLenum pname, GLint* params)
+{
+ ::glGetTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glGetUniformfv(GLuint program, GLint location, GLfloat* params)
+{
+ ::glGetUniformfv(program, location, params);
+}
+
+inline void QOpenGLFunctions_ES2::glGetUniformiv(GLuint program, GLint location, GLint* params)
+{
+ ::glGetUniformiv(program, location, params);
+}
+
+inline int QOpenGLFunctions_ES2::glGetUniformLocation(GLuint program, const GLchar* name)
+{
+ return ::glGetUniformLocation(program, name);
+}
+
+inline void QOpenGLFunctions_ES2::glGetVertexAttribfv(GLuint index, GLenum pname, GLfloat* params)
+{
+ ::glGetVertexAttribfv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glGetVertexAttribiv(GLuint index, GLenum pname, GLint* params)
+{
+ ::glGetVertexAttribiv(index, pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glGetVertexAttribPointerv(GLuint index, GLenum pname, GLvoid** pointer)
+{
+ ::glGetVertexAttribPointerv(index, pname, pointer);
+}
+
+inline void QOpenGLFunctions_ES2::glHint(GLenum target, GLenum mode)
+{
+ ::glHint(target, mode);
+}
+
+inline GLboolean QOpenGLFunctions_ES2::glIsBuffer(GLuint buffer)
+{
+ return ::glIsBuffer(buffer);
+}
+
+inline GLboolean QOpenGLFunctions_ES2::glIsEnabled(GLenum cap)
+{
+ return ::glIsEnabled(cap);
+}
+
+inline GLboolean QOpenGLFunctions_ES2::glIsFramebuffer(GLuint framebuffer)
+{
+ return ::glIsFramebuffer(framebuffer);
+}
+
+inline GLboolean QOpenGLFunctions_ES2::glIsProgram(GLuint program)
+{
+ return ::glIsProgram(program);
+}
+
+inline GLboolean QOpenGLFunctions_ES2::glIsRenderbuffer(GLuint renderbuffer)
+{
+ return ::glIsRenderbuffer(renderbuffer);
+}
+
+inline GLboolean QOpenGLFunctions_ES2::glIsShader(GLuint shader)
+{
+ return ::glIsShader(shader);
+}
+
+inline GLboolean QOpenGLFunctions_ES2::glIsTexture(GLuint texture)
+{
+ return ::glIsTexture(texture);
+}
+
+inline void QOpenGLFunctions_ES2::glLineWidth(GLfloat width)
+{
+ ::glLineWidth(width);
+}
+
+inline void QOpenGLFunctions_ES2::glLinkProgram(GLuint program)
+{
+ ::glLinkProgram(program);
+}
+
+inline void QOpenGLFunctions_ES2::glPixelStorei(GLenum pname, GLint param)
+{
+ ::glPixelStorei(pname, param);
+}
+
+inline void QOpenGLFunctions_ES2::glPolygonOffset(GLfloat factor, GLfloat units)
+{
+ ::glPolygonOffset(factor, units);
+}
+
+inline void QOpenGLFunctions_ES2::glReadPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid* pixels)
+{
+ ::glReadPixels(x, y, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_ES2::glReleaseShaderCompiler(void)
+{
+ ::glReleaseShaderCompiler();
+}
+
+inline void QOpenGLFunctions_ES2::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ ::glRenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLFunctions_ES2::glSampleCoverage(GLclampf value, GLboolean invert)
+{
+ ::glSampleCoverage(value, invert);
+}
+
+inline void QOpenGLFunctions_ES2::glScissor(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ ::glScissor(x, y, width, height);
+}
+
+inline void QOpenGLFunctions_ES2::glShaderBinary(GLsizei n, const GLuint* shaders, GLenum binaryformat, const GLvoid* binary, GLsizei length)
+{
+ ::glShaderBinary(n, shaders, binaryformat, binary, length);
+}
+
+inline void QOpenGLFunctions_ES2::glShaderSource(GLuint shader, GLsizei count, const GLchar* *string, const GLint* length)
+{
+ ::glShaderSource(shader, count, string, length);
+}
+
+inline void QOpenGLFunctions_ES2::glStencilFunc(GLenum func, GLint ref, GLuint mask)
+{
+ ::glStencilFunc(func, ref, mask);
+}
+
+inline void QOpenGLFunctions_ES2::glStencilFuncSeparate(GLenum face, GLenum func, GLint ref, GLuint mask)
+{
+ ::glStencilFuncSeparate(face, func, ref, mask);
+}
+
+inline void QOpenGLFunctions_ES2::glStencilMask(GLuint mask)
+{
+ ::glStencilMask(mask);
+}
+
+inline void QOpenGLFunctions_ES2::glStencilMaskSeparate(GLenum face, GLuint mask)
+{
+ ::glStencilMaskSeparate(face, mask);
+}
+
+inline void QOpenGLFunctions_ES2::glStencilOp(GLenum fail, GLenum zfail, GLenum zpass)
+{
+ ::glStencilOp(fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_ES2::glStencilOpSeparate(GLenum face, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ ::glStencilOpSeparate(face, fail, zfail, zpass);
+}
+
+inline void QOpenGLFunctions_ES2::glTexImage2D(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid* pixels)
+{
+ ::glTexImage2D(target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_ES2::glTexParameterf(GLenum target, GLenum pname, GLfloat param)
+{
+ ::glTexParameterf(target, pname, param);
+}
+
+inline void QOpenGLFunctions_ES2::glTexParameterfv(GLenum target, GLenum pname, const GLfloat* params)
+{
+ ::glTexParameterfv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glTexParameteri(GLenum target, GLenum pname, GLint param)
+{
+ ::glTexParameteri(target, pname, param);
+}
+
+inline void QOpenGLFunctions_ES2::glTexParameteriv(GLenum target, GLenum pname, const GLint* params)
+{
+ ::glTexParameteriv(target, pname, params);
+}
+
+inline void QOpenGLFunctions_ES2::glTexSubImage2D(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid* pixels)
+{
+ ::glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform1f(GLint location, GLfloat x)
+{
+ ::glUniform1f(location, x);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform1fv(GLint location, GLsizei count, const GLfloat* v)
+{
+ ::glUniform1fv(location, count, v);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform1i(GLint location, GLint x)
+{
+ ::glUniform1i(location, x);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform1iv(GLint location, GLsizei count, const GLint* v)
+{
+ ::glUniform1iv(location, count, v);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform2f(GLint location, GLfloat x, GLfloat y)
+{
+ ::glUniform2f(location, x, y);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform2fv(GLint location, GLsizei count, const GLfloat* v)
+{
+ ::glUniform2fv(location, count, v);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform2i(GLint location, GLint x, GLint y)
+{
+ ::glUniform2i(location, x, y);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform2iv(GLint location, GLsizei count, const GLint* v)
+{
+ ::glUniform2iv(location, count, v);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform3f(GLint location, GLfloat x, GLfloat y, GLfloat z)
+{
+ ::glUniform3f(location, x, y, z);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform3fv(GLint location, GLsizei count, const GLfloat* v)
+{
+ ::glUniform3fv(location, count, v);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform3i(GLint location, GLint x, GLint y, GLint z)
+{
+ ::glUniform3i(location, x, y, z);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform3iv(GLint location, GLsizei count, const GLint* v)
+{
+ ::glUniform3iv(location, count, v);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform4f(GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ ::glUniform4f(location, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform4fv(GLint location, GLsizei count, const GLfloat* v)
+{
+ ::glUniform4fv(location, count, v);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform4i(GLint location, GLint x, GLint y, GLint z, GLint w)
+{
+ ::glUniform4i(location, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_ES2::glUniform4iv(GLint location, GLsizei count, const GLint* v)
+{
+ ::glUniform4iv(location, count, v);
+}
+
+inline void QOpenGLFunctions_ES2::glUniformMatrix2fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ ::glUniformMatrix2fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_ES2::glUniformMatrix3fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ ::glUniformMatrix3fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_ES2::glUniformMatrix4fv(GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ ::glUniformMatrix4fv(location, count, transpose, value);
+}
+
+inline void QOpenGLFunctions_ES2::glUseProgram(GLuint program)
+{
+ ::glUseProgram(program);
+}
+
+inline void QOpenGLFunctions_ES2::glValidateProgram(GLuint program)
+{
+ ::glValidateProgram(program);
+}
+
+inline void QOpenGLFunctions_ES2::glVertexAttrib1f(GLuint indx, GLfloat x)
+{
+ ::glVertexAttrib1f(indx, x);
+}
+
+inline void QOpenGLFunctions_ES2::glVertexAttrib1fv(GLuint indx, const GLfloat* values)
+{
+ ::glVertexAttrib1fv(indx, values);
+}
+
+inline void QOpenGLFunctions_ES2::glVertexAttrib2f(GLuint indx, GLfloat x, GLfloat y)
+{
+ ::glVertexAttrib2f(indx, x, y);
+}
+
+inline void QOpenGLFunctions_ES2::glVertexAttrib2fv(GLuint indx, const GLfloat* values)
+{
+ ::glVertexAttrib2fv(indx, values);
+}
+
+inline void QOpenGLFunctions_ES2::glVertexAttrib3f(GLuint indx, GLfloat x, GLfloat y, GLfloat z)
+{
+ ::glVertexAttrib3f(indx, x, y, z);
+}
+
+inline void QOpenGLFunctions_ES2::glVertexAttrib3fv(GLuint indx, const GLfloat* values)
+{
+ ::glVertexAttrib3fv(indx, values);
+}
+
+inline void QOpenGLFunctions_ES2::glVertexAttrib4f(GLuint indx, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ ::glVertexAttrib4f(indx, x, y, z, w);
+}
+
+inline void QOpenGLFunctions_ES2::glVertexAttrib4fv(GLuint indx, const GLfloat* values)
+{
+ ::glVertexAttrib4fv(indx, values);
+}
+
+inline void QOpenGLFunctions_ES2::glVertexAttribPointer(GLuint indx, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid* ptr)
+{
+ ::glVertexAttribPointer(indx, size, type, normalized, stride, ptr);
+}
+
+inline void QOpenGLFunctions_ES2::glViewport(GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ ::glViewport(x, y, width, height);
+}
+
+QT_END_NAMESPACE
+
+#endif // QT_OPENGL_ES_2
+
+#endif
diff --git a/src/gui/opengl/qopenglpaintdevice.cpp b/src/gui/opengl/qopenglpaintdevice.cpp
index 0b3d9dc46d..d55d6a91bf 100644
--- a/src/gui/opengl/qopenglpaintdevice.cpp
+++ b/src/gui/opengl/qopenglpaintdevice.cpp
@@ -116,6 +116,7 @@ public:
qreal dpmx;
qreal dpmy;
+ qreal devicePixelRatio;
bool flipped;
@@ -178,6 +179,7 @@ QOpenGLPaintDevicePrivate::QOpenGLPaintDevicePrivate(const QSize &sz)
, ctx(QOpenGLContext::currentContext())
, dpmx(qt_defaultDpiX() * 100. / 2.54)
, dpmy(qt_defaultDpiY() * 100. / 2.54)
+ , devicePixelRatio(1.0)
, flipped(false)
, engine(0)
{
@@ -249,6 +251,14 @@ void QOpenGLPaintDevice::setSize(const QSize &size)
}
/*!
+ Sets the device pixel ratio for the paint device to \a devicePixelRatio.
+*/
+void QOpenGLPaintDevice::setDevicePixelRatio(qreal devicePixelRatio)
+{
+ d_ptr->devicePixelRatio = devicePixelRatio;
+}
+
+/*!
\reimp
*/
@@ -272,9 +282,9 @@ int QOpenGLPaintDevice::metric(QPaintDevice::PaintDeviceMetric metric) const
case PdmDpiY:
return qRound(d_ptr->dpmy * 0.0254);
case PdmPhysicalDpiX:
- return qRound(d_ptr->dpmx * 0.0254);
+ return qRound(d_ptr->dpmx * 0.0254 * d_ptr->devicePixelRatio);
case PdmPhysicalDpiY:
- return qRound(d_ptr->dpmy * 0.0254);
+ return qRound(d_ptr->dpmy * 0.0254 * d_ptr->devicePixelRatio);
default:
qWarning("QOpenGLPaintDevice::metric() - metric %d not known", metric);
return 0;
diff --git a/src/gui/opengl/qopenglpaintdevice.h b/src/gui/opengl/qopenglpaintdevice.h
index 66850c73fc..c05571c928 100644
--- a/src/gui/opengl/qopenglpaintdevice.h
+++ b/src/gui/opengl/qopenglpaintdevice.h
@@ -42,14 +42,14 @@
#ifndef QOPENGLPAINTDEVICE_H
#define QOPENGLPAINTDEVICE_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_OPENGL
#include <QtGui/qpaintdevice.h>
#include <QtGui/qopengl.h>
#include <QtGui/qopenglcontext.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -70,6 +70,7 @@ public:
QOpenGLContext *context() const;
QSize size() const;
void setSize(const QSize &size);
+ void setDevicePixelRatio(qreal devicePixelRatio);
qreal dotsPerMeterX() const;
qreal dotsPerMeterY() const;
@@ -91,8 +92,6 @@ protected:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_OPENGL
#endif // QOPENGLPAINTDEVICE_H
diff --git a/src/gui/opengl/qopenglpaintengine.cpp b/src/gui/opengl/qopenglpaintengine.cpp
index 9fd8a7ada7..555c47f265 100644
--- a/src/gui/opengl/qopenglpaintengine.cpp
+++ b/src/gui/opengl/qopenglpaintengine.cpp
@@ -624,7 +624,7 @@ void QOpenGL2PaintEngineExPrivate::transferMode(EngineMode newMode)
if (newMode == mode)
return;
- if (mode == TextDrawingMode || mode == ImageDrawingMode || mode == ImageArrayDrawingMode) {
+ if (mode != BrushDrawingMode) {
lastTextureUsed = GLuint(-1);
}
@@ -639,10 +639,12 @@ void QOpenGL2PaintEngineExPrivate::transferMode(EngineMode newMode)
setVertexAttributePointer(QT_TEXTURE_COORDS_ATTR, staticTextureCoordinateArray);
}
- if (newMode == ImageArrayDrawingMode) {
+ if (newMode == ImageArrayDrawingMode || newMode == ImageOpacityArrayDrawingMode) {
setVertexAttributePointer(QT_VERTEX_COORDS_ATTR, (GLfloat*)vertexCoordinateArray.data());
setVertexAttributePointer(QT_TEXTURE_COORDS_ATTR, (GLfloat*)textureCoordinateArray.data());
- setVertexAttributePointer(QT_OPACITY_ATTR, (GLfloat*)opacityArray.data());
+
+ if (newMode == ImageOpacityArrayDrawingMode)
+ setVertexAttributePointer(QT_OPACITY_ATTR, (GLfloat*)opacityArray.data());
}
// This needs to change when we implement high-quality anti-aliasing...
@@ -1069,9 +1071,23 @@ void QOpenGL2PaintEngineExPrivate::resetClipIfNeeded()
glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE);
}
+bool QOpenGL2PaintEngineExPrivate::prepareForCachedGlyphDraw(const QFontEngineGlyphCache &cache)
+{
+ Q_Q(QOpenGL2PaintEngineEx);
+
+ Q_ASSERT(cache.transform().type() <= QTransform::TxScale);
+
+ QTransform &transform = q->state()->matrix;
+ transform.scale(1.0 / cache.transform().m11(), 1.0 / cache.transform().m22());
+ bool ret = prepareForDraw(false);
+ transform.scale(cache.transform().m11(), cache.transform().m22());
+
+ return ret;
+}
+
bool QOpenGL2PaintEngineExPrivate::prepareForDraw(bool srcPixelsAreOpaque)
{
- if (brushTextureDirty && mode != ImageDrawingMode && mode != ImageArrayDrawingMode)
+ if (brushTextureDirty && (mode == TextDrawingMode || mode == BrushDrawingMode))
updateBrushTexture();
if (compositionModeDirty)
@@ -1091,12 +1107,12 @@ bool QOpenGL2PaintEngineExPrivate::prepareForDraw(bool srcPixelsAreOpaque)
}
QOpenGLEngineShaderManager::OpacityMode opacityMode;
- if (mode == ImageArrayDrawingMode) {
+ if (mode == ImageOpacityArrayDrawingMode) {
opacityMode = QOpenGLEngineShaderManager::AttributeOpacity;
} else {
opacityMode = stateHasOpacity ? QOpenGLEngineShaderManager::UniformOpacity
: QOpenGLEngineShaderManager::NoOpacity;
- if (stateHasOpacity && (mode != ImageDrawingMode)) {
+ if (stateHasOpacity && (mode != ImageDrawingMode && mode != ImageArrayDrawingMode)) {
// Using a brush
bool brushIsPattern = (currentBrush.style() >= Qt::Dense1Pattern) &&
(currentBrush.style() <= Qt::DiagCrossPattern);
@@ -1116,7 +1132,7 @@ bool QOpenGL2PaintEngineExPrivate::prepareForDraw(bool srcPixelsAreOpaque)
matrixUniformDirty = true;
}
- if (brushUniformsDirty && mode != ImageDrawingMode && mode != ImageArrayDrawingMode)
+ if (brushUniformsDirty && (mode == TextDrawingMode || mode == BrushDrawingMode))
updateBrushUniforms();
if (opacityMode == QOpenGLEngineShaderManager::UniformOpacity && opacityUniformDirty) {
@@ -1407,11 +1423,9 @@ void QOpenGL2PaintEngineEx::drawStaticTextItem(QStaticTextItem *textItem)
ensureActive();
QPainterState *s = state();
- float det = s->matrix.determinant();
- // don't try to cache huge fonts or vastly transformed fonts
QFontEngine *fontEngine = textItem->fontEngine();
- if (shouldDrawCachedGlyphs(fontEngine, s->matrix) && det >= 0.25f && det <= 4.f) {
+ if (shouldDrawCachedGlyphs(fontEngine, s->matrix)) {
QFontEngineGlyphCache::Type glyphType = fontEngine->glyphFormat >= 0
? QFontEngineGlyphCache::Type(textItem->fontEngine()->glyphFormat)
: d->glyphCacheType;
@@ -1461,13 +1475,6 @@ void QOpenGL2PaintEngineEx::drawTextItem(const QPointF &p, const QTextItem &text
QTransform::TransformationType txtype = s->matrix.type();
- float det = s->matrix.determinant();
- bool drawCached = txtype < QTransform::TxProject;
-
- // don't try to cache huge fonts or vastly transformed fonts
- if (!shouldDrawCachedGlyphs(ti.fontEngine, s->matrix) || det < 0.25f || det > 4.f)
- drawCached = false;
-
QFontEngineGlyphCache::Type glyphType = ti.fontEngine->glyphFormat >= 0
? QFontEngineGlyphCache::Type(ti.fontEngine->glyphFormat)
: d->glyphCacheType;
@@ -1482,7 +1489,7 @@ void QOpenGL2PaintEngineEx::drawTextItem(const QPointF &p, const QTextItem &text
}
}
- if (drawCached) {
+ if (shouldDrawCachedGlyphs(ti.fontEngine, s->matrix)) {
QVarLengthArray<QFixedPoint> positions;
QVarLengthArray<glyph_t> glyphs;
QTransform matrix = QTransform::fromTranslate(p.x(), p.y());
@@ -1531,6 +1538,12 @@ namespace {
// #define QT_OPENGL_DRAWCACHEDGLYPHS_INDEX_ARRAY_VBO
+bool QOpenGL2PaintEngineEx::shouldDrawCachedGlyphs(QFontEngine *fontEngine, const QTransform &t) const
+{
+ // Don't try to cache vastly transformed fonts
+ return t.type() < QTransform::TxProject && QPaintEngineEx::shouldDrawCachedGlyphs(fontEngine, t);
+}
+
void QOpenGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type glyphType,
QStaticTextItem *staticTextItem)
{
@@ -1542,10 +1555,18 @@ void QOpenGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type
bool recreateVertexArrays = false;
QFontEngine *fe = staticTextItem->fontEngine();
+ // We allow scaling, so that the glyph-cache will contain glyphs with the
+ // appropriate resolution in the case of displays with a device-pixel-ratio != 1.
+ QTransform transform = s->matrix.type() < QTransform::TxRotate ?
+ QTransform::fromScale(qAbs(s->matrix.m11()), qAbs(s->matrix.m22())) :
+ QTransform::fromScale(
+ QVector2D(s->matrix.m11(), s->matrix.m12()).length(),
+ QVector2D(s->matrix.m21(), s->matrix.m22()).length());
+
QOpenGLTextureGlyphCache *cache =
- (QOpenGLTextureGlyphCache *) fe->glyphCache(cacheKey, glyphType, QTransform());
+ (QOpenGLTextureGlyphCache *) fe->glyphCache(cacheKey, glyphType, transform);
if (!cache || cache->cacheType() != glyphType || cache->contextGroup() == 0) {
- cache = new QOpenGLTextureGlyphCache(glyphType, QTransform());
+ cache = new QOpenGLTextureGlyphCache(glyphType, transform);
fe->setGlyphCache(cacheKey, cache);
recreateVertexArrays = true;
}
@@ -1583,7 +1604,10 @@ void QOpenGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type
if (cache->width() == 0 || cache->height() == 0)
return;
- transferMode(TextDrawingMode);
+ if (glyphType == QFontEngineGlyphCache::Raster_ARGB)
+ transferMode(ImageArrayDrawingMode);
+ else
+ transferMode(TextDrawingMode);
int margin = fe->glyphMargin(glyphType);
@@ -1637,8 +1661,8 @@ void QOpenGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type
if (c.isNull())
continue;
- int x = qFloor(staticTextItem->glyphPositions[i].x) + c.baseLineX - margin;
- int y = qRound(staticTextItem->glyphPositions[i].y) - c.baseLineY - margin;
+ int x = qFloor(staticTextItem->glyphPositions[i].x.toReal() * cache->transform().m11()) + c.baseLineX - margin;
+ int y = qRound(staticTextItem->glyphPositions[i].y.toReal() * cache->transform().m22()) - c.baseLineY - margin;
vertexCoordinates->addQuad(QRectF(x, y, c.w, c.h));
textureCoordinates->addQuad(QRectF(c.x*dx, c.y*dy, c.w * dx, c.h * dy));
@@ -1679,8 +1703,10 @@ void QOpenGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type
#endif
}
- setVertexAttributePointer(QT_VERTEX_COORDS_ATTR, (GLfloat*)vertexCoordinates->data());
- setVertexAttributePointer(QT_TEXTURE_COORDS_ATTR, (GLfloat*)textureCoordinates->data());
+ if (glyphType != QFontEngineGlyphCache::Raster_ARGB || recreateVertexArrays) {
+ setVertexAttributePointer(QT_VERTEX_COORDS_ATTR, (GLfloat*)vertexCoordinates->data());
+ setVertexAttributePointer(QT_TEXTURE_COORDS_ATTR, (GLfloat*)textureCoordinates->data());
+ }
if (!snapToPixelGrid) {
snapToPixelGrid = true;
@@ -1711,9 +1737,9 @@ void QOpenGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type
}
compositionModeDirty = false; // I can handle this myself, thank you very much
- prepareForDraw(false); // Text always causes src pixels to be transparent
+ prepareForCachedGlyphDraw(*cache);
- // prepareForDraw() have set the opacity on the current shader, so the opacity state can now be reset.
+ // prepareForCachedGlyphDraw() have set the opacity on the current shader, so the opacity state can now be reset.
if (compMode == QPainter::CompositionMode_Source) {
q->state()->opacity = oldOpacity;
opacityUniformDirty = true;
@@ -1734,7 +1760,7 @@ void QOpenGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type
}
compositionModeDirty = false; // I can handle this myself, thank you very much
- prepareForDraw(false); // Text always causes src pixels to be transparent
+ prepareForCachedGlyphDraw(*cache);
glEnable(GL_BLEND);
glBlendFunc(GL_ZERO, GL_ONE_MINUS_SRC_COLOR);
@@ -1758,22 +1784,31 @@ void QOpenGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type
}
compositionModeDirty = false;
- prepareForDraw(false); // Text always causes src pixels to be transparent
+ prepareForCachedGlyphDraw(*cache);
glEnable(GL_BLEND);
glBlendFunc(GL_ONE, GL_ONE);
}
compositionModeDirty = true;
+ } else if (glyphType == QFontEngineGlyphCache::Raster_ARGB) {
+ currentBrush = noBrush;
+ shaderManager->setSrcPixelType(QOpenGLEngineShaderManager::ImageSrc);
+ if (prepareForCachedGlyphDraw(*cache))
+ shaderManager->currentProgram()->setUniformValue(location(QOpenGLEngineShaderManager::ImageTexture), QT_IMAGE_TEXTURE_UNIT);
} else {
// Greyscale/mono glyphs
shaderManager->setMaskType(QOpenGLEngineShaderManager::PixelMask);
- prepareForDraw(false); // Text always causes src pixels to be transparent
+ prepareForCachedGlyphDraw(*cache);
}
QOpenGLTextureGlyphCache::FilterMode filterMode = (s->matrix.type() > QTransform::TxTranslate)?QOpenGLTextureGlyphCache::Linear:QOpenGLTextureGlyphCache::Nearest;
if (lastMaskTextureUsed != cache->texture() || cache->filterMode() != filterMode) {
- funcs.glActiveTexture(GL_TEXTURE0 + QT_MASK_TEXTURE_UNIT);
+ if (glyphType == QFontEngineGlyphCache::Raster_ARGB)
+ funcs.glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
+ else
+ funcs.glActiveTexture(GL_TEXTURE0 + QT_MASK_TEXTURE_UNIT);
+
if (lastMaskTextureUsed != cache->texture()) {
glBindTexture(GL_TEXTURE_2D, cache->texture());
lastMaskTextureUsed = cache->texture();
@@ -1889,7 +1924,7 @@ void QOpenGL2PaintEngineExPrivate::drawPixmapFragments(const QPainter::PixmapFra
funcs.glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
GLuint id = QOpenGLTextureCache::cacheForContext(ctx)->bindTexture(ctx, pixmap);
- transferMode(ImageArrayDrawingMode);
+ transferMode(ImageOpacityArrayDrawingMode);
bool isBitmap = pixmap.isQBitmap();
bool isOpaque = !isBitmap && (!pixmap.hasAlpha() || (hints & QPainter::OpaqueHint)) && allOpaque;
diff --git a/src/gui/opengl/qopenglpaintengine_p.h b/src/gui/opengl/qopenglpaintengine_p.h
index 93e1b4232e..d51f0e5256 100644
--- a/src/gui/opengl/qopenglpaintengine_p.h
+++ b/src/gui/opengl/qopenglpaintengine_p.h
@@ -70,7 +70,8 @@ enum EngineMode {
ImageDrawingMode,
TextDrawingMode,
BrushDrawingMode,
- ImageArrayDrawingMode
+ ImageArrayDrawingMode,
+ ImageOpacityArrayDrawingMode
};
QT_BEGIN_NAMESPACE
@@ -157,7 +158,8 @@ public:
void setRenderTextActive(bool);
bool isNativePaintingActive() const;
- bool supportsTransformations(QFontEngine *, const QTransform &) const { return true; }
+ bool requiresPretransformedGlyphPositions(QFontEngine *, const QTransform &) const { return false; }
+ bool shouldDrawCachedGlyphs(QFontEngine *, const QTransform &) const;
private:
Q_DISABLE_COPY(QOpenGL2PaintEngineEx)
@@ -235,6 +237,7 @@ public:
void setBrush(const QBrush& brush);
void transferMode(EngineMode newMode);
bool prepareForDraw(bool srcPixelsAreOpaque); // returns true if the program has changed
+ bool prepareForCachedGlyphDraw(const QFontEngineGlyphCache &cache);
inline void useSimpleShader();
inline GLuint location(const QOpenGLEngineShaderManager::Uniform uniform) {
return shaderManager->getUniformLocation(uniform);
diff --git a/src/gui/opengl/qopenglqueryhelper_p.h b/src/gui/opengl/qopenglqueryhelper_p.h
new file mode 100644
index 0000000000..a7136c1cb7
--- /dev/null
+++ b/src/gui/opengl/qopenglqueryhelper_p.h
@@ -0,0 +1,177 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QOPENGLQUERYHELPER_P_H
+#define QOPENGLQUERYHELPER_P_H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLContext>
+
+QT_BEGIN_NAMESPACE
+
+// Helper class used by QOpenGLTimerQuery and later will be used by
+// QOpenGLOcclusionQuery
+class QOpenGLQueryHelper
+{
+public:
+ QOpenGLQueryHelper(QOpenGLContext *context)
+ : GetQueryObjectuiv(0),
+ GetQueryObjectiv(0),
+ GetQueryiv(0),
+ EndQuery(0),
+ BeginQuery(0),
+ IsQuery(0),
+ DeleteQueries(0),
+ GenQueries(0),
+ GetInteger64v(0),
+ GetQueryObjectui64v(0),
+ GetQueryObjecti64v(0),
+ QueryCounter(0)
+ {
+ Q_ASSERT(context);
+
+ // Core in OpenGL >=1.5
+ GetQueryObjectuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint *)>(context->getProcAddress("glGetQueryObjectuiv"));
+ GetQueryObjectiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetQueryObjectiv"));
+ GetQueryiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetQueryiv"));
+ EndQuery = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glEndQuery"));
+ BeginQuery = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBeginQuery"));
+ IsQuery = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsQuery"));
+ DeleteQueries = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteQueries"));
+ GenQueries = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenQueries"));
+
+ // Core in OpenGL >=3.2
+ GetInteger64v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint64 *)>(context->getProcAddress("glGetInteger64v"));
+
+ // Core in OpenGL >=3.3 / ARB_timer_query
+ GetQueryObjectui64v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint64 *)>(context->getProcAddress("glGetQueryObjectui64v"));
+ GetQueryObjecti64v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint64 *)>(context->getProcAddress("glGetQueryObjecti64v"));
+ QueryCounter = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glQueryCounter"));
+ }
+
+ inline void glGetQueryObjectuiv(GLuint id, GLenum pname, GLuint *params)
+ {
+ GetQueryObjectuiv(id, pname, params);
+ }
+
+ inline void glGetQueryObjectiv(GLuint id, GLenum pname, GLint *params)
+ {
+ GetQueryObjectiv(id, pname, params);
+ }
+
+ inline void glGetQueryiv(GLenum target, GLenum pname, GLint *params)
+ {
+ GetQueryiv(target, pname, params);
+ }
+
+ inline void glEndQuery(GLenum target)
+ {
+ EndQuery(target);
+ }
+
+ inline void glBeginQuery(GLenum target, GLuint id)
+ {
+ BeginQuery(target, id);
+ }
+
+ inline GLboolean glIsQuery(GLuint id)
+ {
+ return IsQuery(id);
+ }
+
+ inline void glDeleteQueries(GLsizei n, const GLuint *ids)
+ {
+ DeleteQueries(n, ids);
+ }
+
+ inline void glGenQueries(GLsizei n, GLuint *ids)
+ {
+ GenQueries(n, ids);
+ }
+
+ inline void glGetInteger64v(GLenum pname, GLint64 *params)
+ {
+ GetInteger64v(pname, params);
+ }
+
+ inline void glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params)
+ {
+ GetQueryObjectui64v(id, pname, params);
+ }
+
+ inline void glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params)
+ {
+ GetQueryObjecti64v(id, pname, params);
+ }
+
+ inline void glQueryCounter(GLuint id, GLenum target)
+ {
+ QueryCounter(id, target);
+ }
+
+private:
+ // Core in OpenGL >=1.5
+ void (QOPENGLF_APIENTRYP GetQueryObjectuiv)(GLuint id, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetQueryObjectiv)(GLuint id, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetQueryiv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP EndQuery)(GLenum target);
+ void (QOPENGLF_APIENTRYP BeginQuery)(GLenum target, GLuint id);
+ GLboolean (QOPENGLF_APIENTRYP IsQuery)(GLuint id);
+ void (QOPENGLF_APIENTRYP DeleteQueries)(GLsizei n, const GLuint *ids);
+ void (QOPENGLF_APIENTRYP GenQueries)(GLsizei n, GLuint *ids);
+
+ // Core in OpenGL >=3.2
+ void (QOPENGLF_APIENTRYP GetInteger64v)(GLenum pname, GLint64 *params);
+
+ // Core in OpenGL >=3.3 and provided by ARB_timer_query
+ void (QOPENGLF_APIENTRYP GetQueryObjectui64v)(GLuint id, GLenum pname, GLuint64 *params);
+ void (QOPENGLF_APIENTRYP GetQueryObjecti64v)(GLuint id, GLenum pname, GLint64 *params);
+ void (QOPENGLF_APIENTRYP QueryCounter)(GLuint id, GLenum target);
+};
+
+QT_END_NAMESPACE
+
+#endif
+
+#endif // QOPENGLQUERYHELPER_P_H
diff --git a/src/gui/opengl/qopenglshadercache_meego_p.h b/src/gui/opengl/qopenglshadercache_meego_p.h
index 3d62d79ee7..d1c14150d1 100644
--- a/src/gui/opengl/qopenglshadercache_meego_p.h
+++ b/src/gui/opengl/qopenglshadercache_meego_p.h
@@ -68,8 +68,6 @@
# include <syslog.h>
#endif
-QT_BEGIN_HEADER
-
/*
This cache stores internal Qt shader programs in shared memory.
@@ -450,7 +448,5 @@ QT_END_NAMESPACE
#endif
-QT_END_HEADER
-
#endif
#endif
diff --git a/src/gui/opengl/qopenglshadercache_p.h b/src/gui/opengl/qopenglshadercache_p.h
index 0e0b6c3735..17305539df 100644
--- a/src/gui/opengl/qopenglshadercache_p.h
+++ b/src/gui/opengl/qopenglshadercache_p.h
@@ -59,8 +59,6 @@
# include "qopenglshadercache_meego_p.h"
#else
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -91,7 +89,5 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
#endif
diff --git a/src/gui/opengl/qopenglshaderprogram.cpp b/src/gui/opengl/qopenglshaderprogram.cpp
index 88c9c8008c..1cde0cb92d 100644
--- a/src/gui/opengl/qopenglshaderprogram.cpp
+++ b/src/gui/opengl/qopenglshaderprogram.cpp
@@ -49,6 +49,11 @@
#include <QtCore/qvector.h>
#include <QtGui/qtransform.h>
#include <QtGui/QColor>
+#include <QtGui/QSurfaceFormat>
+
+#if !defined(QT_OPENGL_ES_2)
+#include <QtGui/qopenglfunctions_4_0_core.h>
+#endif
QT_BEGIN_NAMESPACE
@@ -145,6 +150,14 @@ QT_BEGIN_NAMESPACE
\value Vertex Vertex shader written in the OpenGL Shading Language (GLSL).
\value Fragment Fragment shader written in the OpenGL Shading Language (GLSL).
+ \value Geometry Geometry shaders written in the OpenGL Shading Language (GLSL)
+ based on the OpenGL core feature (requires OpenGL >= 3.2).
+ \value TessellationControl Tessellation control shaders written in the OpenGL
+ shading language (GLSL), based on the core feature (requires OpenGL >= 4.0).
+ \value TessellationEvaluation Tessellation evaluation shaders written in the OpenGL
+ shading language (GLSL), based on the core feature (requires OpenGL >= 4.0).
+ \value Compute Compute shaders written in the OpenGL shading language (GLSL),
+ based on the core feature (requires OpenGL >= 4.3).
*/
class QOpenGLShaderPrivate : public QObjectPrivate
@@ -156,7 +169,20 @@ public:
, shaderType(type)
, compiled(false)
, glfuncs(new QOpenGLFunctions(ctx))
+#ifndef QT_OPENGL_ES_2
+ , supportsGeometryShaders(false)
+ , supportsTessellationShaders(false)
+#endif
{
+#ifndef QT_OPENGL_ES_2
+ QSurfaceFormat f = ctx->format();
+
+ // Geometry shaders require OpenGL >= 3.2
+ if (shaderType & QOpenGLShader::Geometry)
+ supportsGeometryShaders = (f.version() >= qMakePair<int, int>(3, 2));
+ else if (shaderType & (QOpenGLShader::TessellationControl | QOpenGLShader::TessellationEvaluation))
+ supportsTessellationShaders = (f.version() >= qMakePair<int, int>(4, 0));
+#endif
}
~QOpenGLShaderPrivate();
@@ -167,6 +193,14 @@ public:
QOpenGLFunctions *glfuncs;
+#ifndef QT_OPENGL_ES_2
+ // Support for geometry shaders
+ bool supportsGeometryShaders;
+
+ // Support for tessellation shaders
+ bool supportsTessellationShaders;
+#endif
+
bool create();
bool compile(QOpenGLShader *q);
void deleteShader();
@@ -192,10 +226,25 @@ bool QOpenGLShaderPrivate::create()
if (!context)
return false;
GLuint shader;
- if (shaderType == QOpenGLShader::Vertex)
+ if (shaderType == QOpenGLShader::Vertex) {
shader = glfuncs->glCreateShader(GL_VERTEX_SHADER);
- else
+#if defined(QT_OPENGL_3_2)
+ } else if (shaderType == QOpenGLShader::Geometry && supportsGeometryShaders) {
+ shader = glfuncs->glCreateShader(GL_GEOMETRY_SHADER);
+#endif
+#if defined(QT_OPENGL_4)
+ } else if (shaderType == QOpenGLShader::TessellationControl && supportsTessellationShaders) {
+ shader = glfuncs->glCreateShader(GL_TESS_CONTROL_SHADER);
+ } else if (shaderType == QOpenGLShader::TessellationEvaluation && supportsTessellationShaders) {
+ shader = glfuncs->glCreateShader(GL_TESS_EVALUATION_SHADER);
+#endif
+#if defined(QT_OPENGL_4_3)
+ } else if (shaderType == QOpenGLShader::Compute) {
+ shader = glfuncs->glCreateShader(GL_COMPUTE_SHADER);
+#endif
+ } else {
shader = glfuncs->glCreateShader(GL_FRAGMENT_SHADER);
+ }
if (!shader) {
qWarning() << "QOpenGLShader: could not create shader";
return false;
@@ -234,6 +283,8 @@ bool QOpenGLShaderPrivate::compile(QOpenGLShader *q)
type = types[0];
else if (shaderType == QOpenGLShader::Vertex)
type = types[1];
+ else if (shaderType == QOpenGLShader::Geometry)
+ type = types[2];
// Get info and source code lengths
GLint infoLogLength = 0;
@@ -329,18 +380,12 @@ QOpenGLShader::ShaderType QOpenGLShader::shaderType() const
return d->shaderType;
}
-// The precision qualifiers are useful on OpenGL/ES systems,
-// but usually not present on desktop systems. Define the
-// keywords to empty strings on desktop systems.
-#if !defined(QT_OPENGL_ES) || defined(QT_OPENGL_FORCE_SHADER_DEFINES)
-#define QOpenGL_DEFINE_QUALIFIERS 1
static const char qualifierDefines[] =
"#define lowp\n"
"#define mediump\n"
"#define highp\n";
-#else
-
+#if defined(QT_OPENGL_ES) && !defined(QT_OPENGL_FORCE_SHADER_DEFINES)
// The "highp" qualifier doesn't exist in fragment shaders
// on all ES platforms. When it doesn't exist, use "mediump".
#define QOpenGL_REDEFINE_HIGHP 1
@@ -380,10 +425,19 @@ bool QOpenGLShader::compileSourceCode(const char *source)
src.append(source);
srclen.append(GLint(headerLen));
}
-#ifdef QOpenGL_DEFINE_QUALIFIERS
- src.append(qualifierDefines);
- srclen.append(GLint(sizeof(qualifierDefines) - 1));
+
+ // The precision qualifiers are useful on OpenGL/ES systems,
+ // but usually not present on desktop systems.
+ const QSurfaceFormat currentSurfaceFormat = QOpenGLContext::currentContext()->format();
+ if (currentSurfaceFormat.renderableType() == QSurfaceFormat::OpenGL
+#ifdef QT_OPENGL_FORCE_SHADER_DEFINES
+ || true
#endif
+ ) {
+ src.append(qualifierDefines);
+ srclen.append(GLint(sizeof(qualifierDefines) - 1));
+ }
+
#ifdef QOpenGL_REDEFINE_HIGHP
if (d->shaderType == Fragment) {
src.append(redefineHighp);
@@ -510,6 +564,9 @@ public:
, inited(false)
, removingShaders(false)
, glfuncs(new QOpenGLFunctions)
+#ifndef QT_OPENGL_ES_2
+ , tessellationFuncs(0)
+#endif
{
}
~QOpenGLShaderProgramPrivate();
@@ -525,6 +582,11 @@ public:
QOpenGLFunctions *glfuncs;
+#ifndef QT_OPENGL_ES_2
+ // Tessellation shader support
+ QOpenGLFunctions_4_0_Core *tessellationFuncs;
+#endif
+
bool hasShader(QOpenGLShader::ShaderType type) const;
};
@@ -582,6 +644,16 @@ bool QOpenGLShaderProgram::init()
if (!context)
return false;
d->glfuncs->initializeOpenGLFunctions();
+
+#ifndef QT_OPENGL_ES_2
+ // Resolve OpenGL 4 functions for tessellation shader support
+ QSurfaceFormat format = context->format();
+ if (format.version() >= qMakePair<int, int>(4, 0)) {
+ d->tessellationFuncs = context->versionFunctions<QOpenGLFunctions_4_0_Core>();
+ d->tessellationFuncs->initializeOpenGLFunctions();
+ }
+#endif
+
GLuint program = d->glfuncs->glCreateProgram();
if (!program) {
qWarning() << "QOpenGLShaderProgram: could not create shader program";
@@ -2927,6 +2999,198 @@ void QOpenGLShaderProgram::setUniformValueArray(const char *name, const QMatrix4
}
/*!
+ Returns the hardware limit for how many vertices a geometry shader
+ can output.
+*/
+int QOpenGLShaderProgram::maxGeometryOutputVertices() const
+{
+ GLint n = 0;
+#if defined(QT_OPENGL_3_2)
+ glGetIntegerv(GL_MAX_GEOMETRY_OUTPUT_VERTICES, &n);
+#endif
+ return n;
+}
+
+/*!
+ Use this function to specify to OpenGL the number of vertices in
+ a patch to \a count. A patch is a custom OpenGL primitive whose interpretation
+ is entirely defined by the tessellation shader stages. Therefore, calling
+ this function only makes sense when using a QOpenGLShaderProgram
+ containing tessellation stage shaders. When using OpenGL tessellation,
+ the only primitive that can be rendered with \c{glDraw*()} functions is
+ \c{GL_PATCHES}.
+
+ This is equivalent to calling glPatchParameteri(GL_PATCH_VERTICES, count).
+
+ \note This modifies global OpenGL state and is not specific to this
+ QOpenGLShaderProgram instance. You should call this in your render
+ function when needed, as QOpenGLShaderProgram will not apply this for
+ you. This is purely a convenience function.
+
+ \sa patchVertexCount()
+*/
+void QOpenGLShaderProgram::setPatchVertexCount(int count)
+{
+#if defined(QT_OPENGL_4)
+ Q_D(QOpenGLShaderProgram);
+ if (d->tessellationFuncs)
+ d->tessellationFuncs->glPatchParameteri(GL_PATCH_VERTICES, count);
+#else
+ Q_UNUSED(count);
+#endif
+}
+
+/*!
+ Returns the number of vertices per-patch to be used when rendering.
+
+ \note This returns the global OpenGL state value. It is not specific to
+ this QOpenGLShaderProgram instance.
+
+ \sa setPatchVertexCount()
+*/
+int QOpenGLShaderProgram::patchVertexCount() const
+{
+ int patchVertices = 0;
+#if defined(QT_OPENGL_4)
+ Q_D(const QOpenGLShaderProgram);
+ if (d->tessellationFuncs)
+ d->tessellationFuncs->glGetIntegerv(GL_PATCH_VERTICES, &patchVertices);
+#endif
+ return patchVertices;
+}
+
+/*!
+ Sets the default outer tessellation levels to be used by the tessellation
+ primitive generator in the event that the tessellation control shader
+ does not output them to \a levels. For more details on OpenGL and Tessellation
+ shaders see \l{OpenGL Tessellation Shaders}.
+
+ The \a levels argument should be a QVector consisting of 4 floats. Not all
+ of the values make sense for all tessellation modes. If you specify a vector with
+ fewer than 4 elements, the remaining elements will be given a default value of 1.
+
+ \note This modifies global OpenGL state and is not specific to this
+ QOpenGLShaderProgram instance. You should call this in your render
+ function when needed, as QOpenGLShaderProgram will not apply this for
+ you. This is purely a convenience function.
+
+ \sa defaultOuterTessellationLevels(), setDefaultInnerTessellationLevels()
+*/
+void QOpenGLShaderProgram::setDefaultOuterTessellationLevels(const QVector<float> &levels)
+{
+#if defined(QT_OPENGL_4)
+ QVector<float> tessLevels = levels;
+
+ // Ensure we have the required 4 outer tessellation levels
+ // Use default of 1 for missing entries (same as spec)
+ const int argCount = 4;
+ if (tessLevels.size() < argCount) {
+ tessLevels.reserve(argCount);
+ for (int i = tessLevels.size(); i < argCount; ++i)
+ tessLevels.append(1.0f);
+ }
+
+ Q_D(QOpenGLShaderProgram);
+ if (d->tessellationFuncs)
+ d->tessellationFuncs->glPatchParameterfv(GL_PATCH_DEFAULT_OUTER_LEVEL, tessLevels.data());
+#else
+ Q_UNUSED(levels);
+#endif
+}
+
+/*!
+ Returns the default outer tessellation levels to be used by the tessellation
+ primitive generator in the event that the tessellation control shader
+ does not output them. For more details on OpenGL and Tessellation shaders see
+ \l{OpenGL Tessellation Shaders}.
+
+ Returns a QVector of floats describing the outer tessellation levels. The vector
+ will always have four elements but not all of them make sense for every mode
+ of tessellation.
+
+ \note This returns the global OpenGL state value. It is not specific to
+ this QOpenGLShaderProgram instance.
+
+ \sa setDefaultOuterTessellationLevels(), defaultInnerTessellationLevels()
+*/
+QVector<float> QOpenGLShaderProgram::defaultOuterTessellationLevels() const
+{
+ QVector<float> tessLevels(4, 1.0f);
+#if defined(QT_OPENGL_4)
+ Q_D(const QOpenGLShaderProgram);
+ if (d->tessellationFuncs)
+ d->tessellationFuncs->glGetFloatv(GL_PATCH_DEFAULT_OUTER_LEVEL, tessLevels.data());
+#endif
+ return tessLevels;
+}
+
+/*!
+ Sets the default outer tessellation levels to be used by the tessellation
+ primitive generator in the event that the tessellation control shader
+ does not output them to \a levels. For more details on OpenGL and Tessellation shaders see
+ \l{OpenGL Tessellation Shaders}.
+
+ The \a levels argument should be a QVector consisting of 2 floats. Not all
+ of the values make sense for all tessellation modes. If you specify a vector with
+ fewer than 2 elements, the remaining elements will be given a default value of 1.
+
+ \note This modifies global OpenGL state and is not specific to this
+ QOpenGLShaderProgram instance. You should call this in your render
+ function when needed, as QOpenGLShaderProgram will not apply this for
+ you. This is purely a convenience function.
+
+ \sa defaultInnerTessellationLevels(), setDefaultOuterTessellationLevels()
+*/
+void QOpenGLShaderProgram::setDefaultInnerTessellationLevels(const QVector<float> &levels)
+{
+#if defined(QT_OPENGL_4)
+ QVector<float> tessLevels = levels;
+
+ // Ensure we have the required 2 inner tessellation levels
+ // Use default of 1 for missing entries (same as spec)
+ const int argCount = 2;
+ if (tessLevels.size() < argCount) {
+ tessLevels.reserve(argCount);
+ for (int i = tessLevels.size(); i < argCount; ++i)
+ tessLevels.append(1.0f);
+ }
+
+ Q_D(QOpenGLShaderProgram);
+ if (d->tessellationFuncs)
+ d->tessellationFuncs->glPatchParameterfv(GL_PATCH_DEFAULT_INNER_LEVEL, tessLevels.data());
+#else
+ Q_UNUSED(levels);
+#endif
+}
+
+/*!
+ Returns the default inner tessellation levels to be used by the tessellation
+ primitive generator in the event that the tessellation control shader
+ does not output them. For more details on OpenGL and Tessellation shaders see
+ \l{OpenGL Tessellation Shaders}.
+
+ Returns a QVector of floats describing the inner tessellation levels. The vector
+ will always have two elements but not all of them make sense for every mode
+ of tessellation.
+
+ \note This returns the global OpenGL state value. It is not specific to
+ this QOpenGLShaderProgram instance.
+
+ \sa setDefaultInnerTessellationLevels(), defaultOuterTessellationLevels()
+*/
+QVector<float> QOpenGLShaderProgram::defaultInnerTessellationLevels() const
+{
+ QVector<float> tessLevels(2, 1.0f);
+#if defined(QT_OPENGL_4)
+ Q_D(const QOpenGLShaderProgram);
+ if (d->tessellationFuncs)
+ d->tessellationFuncs->glGetFloatv(GL_PATCH_DEFAULT_OUTER_LEVEL, tessLevels.data());
+#endif
+ return tessLevels;
+}
+
+
+/*!
Returns true if shader programs written in the OpenGL Shading
Language (GLSL) are supported on this system; false otherwise.
@@ -2972,9 +3236,37 @@ bool QOpenGLShader::hasOpenGLShaders(ShaderType type, QOpenGLContext *context)
if (!context)
return false;
- if ((type & ~(Vertex | Fragment)) || type == 0)
+ if ((type & ~(Geometry | Vertex | Fragment | TessellationControl | TessellationEvaluation | Compute)) || type == 0)
+ return false;
+
+ QSurfaceFormat format = context->format();
+ if (type == Geometry) {
+#ifndef QT_OPENGL_ES_2
+ // Geometry shaders require OpenGL 3.2 or newer
+ QSurfaceFormat format = context->format();
+ return (format.version() >= qMakePair<int, int>(3, 2));
+#else
+ // No geometry shader support in OpenGL ES2
+ return false;
+#endif
+ } else if (type == TessellationControl || type == TessellationEvaluation) {
+#if !defined(QT_OPENGL_ES_2)
+ return (format.version() >= qMakePair<int, int>(4, 0));
+#else
+ // No tessellation shader support in OpenGL ES2
return false;
+#endif
+ } else if (type == Compute) {
+#if defined(QT_OPENGL_4_3)
+ return (format.version() >= qMakePair<int, int>(4, 3));
+#else
+ // No compute shader support without OpenGL 4.3 or newer
+ return false;
+#endif
+ }
+ // Unconditional support of vertex and fragment shaders implicitly assumes
+ // a minimum OpenGL version of 2.0
return true;
}
diff --git a/src/gui/opengl/qopenglshaderprogram.h b/src/gui/opengl/qopenglshaderprogram.h
index cd05d0f96b..b894ae3af8 100644
--- a/src/gui/opengl/qopenglshaderprogram.h
+++ b/src/gui/opengl/qopenglshaderprogram.h
@@ -42,6 +42,8 @@
#ifndef QOPENGLSHADERPROGRAM_H
#define QOPENGLSHADERPROGRAM_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_OPENGL
#include <QtGui/qopengl.h>
@@ -50,8 +52,6 @@
#include <QtGui/qvector4d.h>
#include <QtGui/qmatrix4x4.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -65,8 +65,12 @@ class Q_GUI_EXPORT QOpenGLShader : public QObject
public:
enum ShaderTypeBit
{
- Vertex = 0x0001,
- Fragment = 0x0002
+ Vertex = 0x0001,
+ Fragment = 0x0002,
+ Geometry = 0x0004,
+ TessellationControl = 0x0008,
+ TessellationEvaluation = 0x0010,
+ Compute = 0x0020
};
Q_DECLARE_FLAGS(ShaderType, ShaderTypeBit)
@@ -128,6 +132,17 @@ public:
GLuint programId() const;
+ int maxGeometryOutputVertices() const;
+
+ void setPatchVertexCount(int count);
+ int patchVertexCount() const;
+
+ void setDefaultOuterTessellationLevels(const QVector<float> &levels);
+ QVector<float> defaultOuterTessellationLevels() const;
+
+ void setDefaultInnerTessellationLevels(const QVector<float> &levels);
+ QVector<float> defaultInnerTessellationLevels() const;
+
void bindAttributeLocation(const char *name, int location);
void bindAttributeLocation(const QByteArray& name, int location);
void bindAttributeLocation(const QString& name, int location);
@@ -293,8 +308,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_OPENGL
#endif
diff --git a/src/gui/opengl/qopengltexturecache.cpp b/src/gui/opengl/qopengltexturecache.cpp
index fffc3688e3..94b82885ff 100644
--- a/src/gui/opengl/qopengltexturecache.cpp
+++ b/src/gui/opengl/qopengltexturecache.cpp
@@ -95,9 +95,10 @@ void QOpenGLTextureCacheWrapper::cleanupTexturesForPixmapData(QPlatformPixmap *p
cleanupTexturesForCacheKey(pmd->cacheKey());
}
-QOpenGLTextureCache::QOpenGLTextureCache(QOpenGLContext *ctx)
+QOpenGLTextureCache::QOpenGLTextureCache(QOpenGLContext *ctx, bool useByteSwapImage)
: QOpenGLSharedResource(ctx->shareGroup())
, m_cache(64 * 1024) // 64 MB cache
+ , m_useByteSwapImage(useByteSwapImage)
{
}
@@ -180,7 +181,9 @@ GLuint QOpenGLTextureCache::bindTexture(QOpenGLContext *context, qint64 key, con
QImage tx = image.convertToFormat(QImage::Format_ARGB32_Premultiplied);
- qgl_byteSwapImage(tx);
+ // Performance could be improved by skipping qgl_byteSwapImage().
+ if (m_useByteSwapImage)
+ qgl_byteSwapImage(tx);
glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, tx.width(), tx.height(), 0, GL_RGBA, GL_UNSIGNED_BYTE, const_cast<const QImage &>(tx).bits());
diff --git a/src/gui/opengl/qopengltexturecache_p.h b/src/gui/opengl/qopengltexturecache_p.h
index 2e82d5f373..d4d3f00069 100644
--- a/src/gui/opengl/qopengltexturecache_p.h
+++ b/src/gui/opengl/qopengltexturecache_p.h
@@ -78,7 +78,7 @@ class Q_GUI_EXPORT QOpenGLTextureCache : public QOpenGLSharedResource
public:
static QOpenGLTextureCache *cacheForContext(QOpenGLContext *context);
- QOpenGLTextureCache(QOpenGLContext *);
+ QOpenGLTextureCache(QOpenGLContext *, bool useByteSwapImage = true);
~QOpenGLTextureCache();
GLuint bindTexture(QOpenGLContext *context, const QPixmap &pixmap);
@@ -94,6 +94,7 @@ private:
QMutex m_mutex;
QCache<quint64, QOpenGLCachedTexture> m_cache;
+ bool m_useByteSwapImage;
};
QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopengltextureglyphcache.cpp b/src/gui/opengl/qopengltextureglyphcache.cpp
index b751629117..83f407575e 100644
--- a/src/gui/opengl/qopengltextureglyphcache.cpp
+++ b/src/gui/opengl/qopengltextureglyphcache.cpp
@@ -120,7 +120,7 @@ void QOpenGLTextureGlyphCache::createTextureData(int width, int height)
m_textureResource->m_width = width;
m_textureResource->m_height = height;
- if (m_type == QFontEngineGlyphCache::Raster_RGBMask) {
+ if (m_type == QFontEngineGlyphCache::Raster_RGBMask || m_type == QFontEngineGlyphCache::Raster_ARGB) {
QVarLengthArray<uchar> data(width * height * 4);
for (int i = 0; i < data.size(); ++i)
data[i] = 0;
@@ -314,30 +314,40 @@ void QOpenGLTextureGlyphCache::fillTexture(const Coord &c, glyph_t glyph, QFixed
for (int x = 0; x < maskWidth; ++x)
src[x] = -src[x]; // convert 0 and 1 into 0 and 255
}
- } else if (mask.format() == QImage::Format_RGB32) {
- // Make the alpha component equal to the average of the RGB values.
- // This is needed when drawing sub-pixel antialiased text on translucent targets.
- for (int y = 0; y < maskHeight; ++y) {
- quint32 *src = (quint32 *) mask.scanLine(y);
- for (int x = 0; x < maskWidth; ++x) {
- uchar r = src[x] >> 16;
- uchar g = src[x] >> 8;
- uchar b = src[x];
- quint32 avg = (quint32(r) + quint32(g) + quint32(b) + 1) / 3; // "+1" for rounding.
+ } else if (mask.depth() == 32) {
+ if (mask.format() == QImage::Format_RGB32
+ // We need to make the alpha component equal to the average of the RGB values.
+ // This is needed when drawing sub-pixel antialiased text on translucent targets.
+#if defined(QT_OPENGL_ES_2)
+ || !hasBGRA // We need to reverse the bytes
+#endif
+ ) {
+ for (int y = 0; y < maskHeight; ++y) {
+ quint32 *src = (quint32 *) mask.scanLine(y);
+ for (int x = 0; x < maskWidth; ++x) {
+ uchar r = src[x] >> 16;
+ uchar g = src[x] >> 8;
+ uchar b = src[x];
+ quint32 avg;
+ if (mask.format() == QImage::Format_RGB32)
+ avg = (quint32(r) + quint32(g) + quint32(b) + 1) / 3; // "+1" for rounding.
+ else // Format_ARGB_Premultiplied
+ avg = src[x] >> 24;
#if defined(QT_OPENGL_ES_2)
- if (!hasBGRA) {
- // Reverse bytes to match GL_RGBA
- src[x] = (avg << 24) | (quint32(r) << 0) | (quint32(g) << 8) | (quint32(b) << 16);
- } else
+ if (!hasBGRA) {
+ // Reverse bytes to match GL_RGBA
+ src[x] = (avg << 24) | (quint32(r) << 0) | (quint32(g) << 8) | (quint32(b) << 16);
+ } else
#endif
- src[x] = (src[x] & 0x00ffffff) | (avg << 24);
+ src[x] = (src[x] & 0x00ffffff) | (avg << 24);
+ }
}
}
}
glBindTexture(GL_TEXTURE_2D, m_textureResource->m_texture);
- if (mask.format() == QImage::Format_RGB32) {
+ if (mask.depth() == 32) {
#if defined(QT_OPENGL_ES_2)
glTexSubImage2D(GL_TEXTURE_2D, 0, c.x, c.y, maskWidth, maskHeight, hasBGRA ? GL_BGRA_EXT : GL_RGBA, GL_UNSIGNED_BYTE, mask.bits());
#else
diff --git a/src/gui/opengl/qopengltimerquery.cpp b/src/gui/opengl/qopengltimerquery.cpp
new file mode 100644
index 0000000000..38e988c4df
--- /dev/null
+++ b/src/gui/opengl/qopengltimerquery.cpp
@@ -0,0 +1,876 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qopengltimerquery.h"
+
+#include "qopenglqueryhelper_p.h"
+#include <QtCore/private/qobject_p.h>
+#include <QtGui/QOpenGLContext>
+
+QT_BEGIN_NAMESPACE
+
+// Helper class used as fallback if OpenGL <3.3 is being used with EXT_timer_query
+class QExtTimerQueryHelper
+{
+public:
+ QExtTimerQueryHelper(QOpenGLContext *context)
+ {
+ Q_ASSERT(context);
+ GetQueryObjectui64vEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint64EXT *)>(context->getProcAddress("glGetQueryObjectui64vEXT"));
+ GetQueryObjecti64vEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint64EXT *)>(context->getProcAddress("glGetQueryObjecti64vEXT"));
+ }
+
+ inline void glGetQueryObjectui64vEXT(GLuint id, GLenum pname, GLuint64EXT *params)
+ {
+ GetQueryObjectui64vEXT(id, pname, params);
+ }
+
+ inline void glGetQueryObjecti64vEXT(GLuint id, GLenum pname, GLint64EXT *params)
+ {
+ GetQueryObjecti64vEXT(id, pname, params);
+ }
+
+private:
+ void (QOPENGLF_APIENTRYP GetQueryObjectui64vEXT)(GLuint id, GLenum pname, GLuint64EXT *params);
+ void (QOPENGLF_APIENTRYP GetQueryObjecti64vEXT)(GLuint id, GLenum pname, GLint64EXT *params);
+};
+
+class QOpenGLTimerQueryPrivate : public QObjectPrivate
+{
+public:
+ QOpenGLTimerQueryPrivate()
+ : QObjectPrivate(),
+ context(0),
+ ext(0),
+ timeInterval(0),
+ timer(0)
+ {
+ }
+
+ ~QOpenGLTimerQueryPrivate()
+ {
+ delete core;
+ delete ext;
+ }
+
+ bool create();
+ void destroy();
+ void begin();
+ void end();
+ GLuint64 waitForTimeStamp() const;
+ void recordTimestamp();
+ bool isResultAvailable() const;
+ GLuint64 result() const;
+
+ // There are several cases we must handle:
+ // OpenGL >=3.3 includes timer queries as a core feature
+ // ARB_timer_query has same functionality as above. Requires OpenGL 3.2
+ // EXT_timer_query offers limited support. Can be used with OpenGL >=1.5
+ //
+ // Note that some implementations (OS X) provide OpenGL 3.2 but do not expose the
+ // ARB_timer_query extension. In such situations we must also be able to handle
+ // using the EXT_timer_query extension with any version of OpenGL.
+ //
+ // OpenGL 1.5 or above contains the generic query API and OpenGL 3.3 and
+ // ARB_timer_query provide the 64-bit query API. These are wrapped by
+ // QOpenGLQueryHelper. All we need to handle in addition is the EXT_timer_query
+ // case and to take care not to call the Core/ARB functions when we only
+ // have EXT_timer_query available.
+ QOpenGLContext *context;
+ QOpenGLQueryHelper *core;
+ QExtTimerQueryHelper *ext;
+ mutable GLuint64 timeInterval;
+ GLuint timer;
+};
+
+bool QOpenGLTimerQueryPrivate::create()
+{
+ QOpenGLContext *ctx = QOpenGLContext::currentContext();
+
+ if (timer && context == ctx)
+ return true;
+
+ context = ctx;
+ if (!context) {
+ qWarning("A current OpenGL context is required to create timer query objects");
+ return false;
+ }
+
+ // Resolve the functions provided by OpenGL 1.5 and OpenGL 3.3 or ARB_timer_query
+ core = new QOpenGLQueryHelper(context);
+
+ // Check to see if we also need to resolve the functions for EXT_timer_query
+ QSurfaceFormat f = context->format();
+ if (f.version() <= qMakePair<int, int>(3, 2)
+ && !context->hasExtension(QByteArrayLiteral("GL_ARB_timer_query"))
+ && context->hasExtension(QByteArrayLiteral("GL_EXT_timer_query"))) {
+ ext = new QExtTimerQueryHelper(context);
+ } else if (f.version() <= qMakePair<int, int>(3, 2)
+ && !context->hasExtension(QByteArrayLiteral("GL_ARB_timer_query"))
+ && !context->hasExtension(QByteArrayLiteral("GL_EXT_timer_query"))) {
+ qWarning("QOpenGLTimerQuery requires one of:\n"
+ " OpenGL 3.3 or newer,\n"
+ " OpenGL 3.2 and the ARB_timer_query extension\n"
+ " or the EXT_timer query extension");
+ return false;
+ }
+
+ core->glGenQueries(1, &timer);
+ return (timer != 0);
+}
+
+void QOpenGLTimerQueryPrivate::destroy()
+{
+ if (!timer)
+ return;
+
+ core->glDeleteQueries(1, &timer);
+ timer = 0;
+ context = 0;
+}
+
+// GL_TIME_ELAPSED_EXT is not defined on OS X 10.6
+#if !defined(GL_TIME_ELAPSED_EXT)
+#define GL_TIME_ELAPSED_EXT 0x88BF
+#endif
+
+// GL_TIME_ELAPSED is not defined on OS X 10.7 or 10.8 yet
+#if !defined(GL_TIME_ELAPSED)
+#define GL_TIME_ELAPSED GL_TIME_ELAPSED_EXT
+#endif
+
+void QOpenGLTimerQueryPrivate::begin()
+{
+ core->glBeginQuery(GL_TIME_ELAPSED, timer);
+}
+
+void QOpenGLTimerQueryPrivate::end()
+{
+ core->glEndQuery(GL_TIME_ELAPSED);
+}
+
+void QOpenGLTimerQueryPrivate::recordTimestamp()
+{
+ // Don't call glQueryCounter if we only have EXT_timer_query
+#if defined(GL_TIMESTAMP)
+ if (!ext)
+ core->glQueryCounter(timer, GL_TIMESTAMP);
+ else
+ qWarning("QOpenGLTimerQuery::recordTimestamp() requires OpenGL 3.3 or GL_ARB_timer_query");
+#else
+ qWarning("QOpenGLTimerQuery::recordTimestamp() requires OpenGL 3.3 or GL_ARB_timer_query");
+#endif
+}
+
+GLuint64 QOpenGLTimerQueryPrivate::waitForTimeStamp() const
+{
+ GLint64 tmp = 0;
+#if defined(GL_TIMESTAMP)
+ if (!ext)
+ core->glGetInteger64v(GL_TIMESTAMP, &tmp);
+ else
+ qWarning("QOpenGLTimerQuery::waitForTimestamp() requires OpenGL 3.3 or GL_ARB_timer_query");
+#else
+ qWarning("QOpenGLTimerQuery::waitForTimestamp() requires OpenGL 3.3 or GL_ARB_timer_query");
+#endif
+ GLuint64 timestamp(tmp);
+ return timestamp;
+}
+
+bool QOpenGLTimerQueryPrivate::isResultAvailable() const
+{
+ GLuint available = GL_FALSE;
+ core->glGetQueryObjectuiv(timer, GL_QUERY_RESULT_AVAILABLE, &available);
+ return available;
+}
+
+GLuint64 QOpenGLTimerQueryPrivate::result() const
+{
+ if (!ext)
+ core->glGetQueryObjectui64v(timer, GL_QUERY_RESULT, &timeInterval);
+ else
+ ext->glGetQueryObjectui64vEXT(timer, GL_QUERY_RESULT, &timeInterval);
+ return timeInterval;
+}
+
+/*!
+ \class QOpenGLTimerQuery
+ \brief The QOpenGLTimerQuery class wraps an OpenGL timer query object.
+ \inmodule QtGui
+ \since 5.1
+ \ingroup painting-3D
+
+ OpenGL timer query objects are OpenGL managed resources to measure the
+ execution times of sequences of OpenGL commands on the GPU.
+
+ OpenGL offers various levels of support for timer queries, depending on
+ the version of OpenGL you have and the presence of the ARB_timer_query or
+ EXT_timer_query extensions. The support can be summarized as:
+
+ \list
+ \li OpenGL >=3.3 offers full support for all timer query functionality.
+ \li OpenGL 3.2 with the ARB_timer_query extension offers full support
+ for all timer query functionality.
+ \li OpenGL <=3.2 with the EXT_timer_query extension offers limited support
+ in that the timestamp of the GPU cannot be queried. Places where this
+ impacts functions provided by Qt classes will be highlighted in the
+ function documentation.
+ \li OpenGL ES 2 (and OpenGL ES 3) do not provide any support for OpenGL
+ timer queries.
+ \endlist
+
+ OpenGL represents time with a granularity of 1 nanosecond (1e-9 seconds). As a
+ consequence of this, 32-bit integers would only give a total possible duration
+ of approximately 4 seconds, which would not be difficult to exceed in poorly
+ performing or lengthy operations. OpenGL therefore uses 64 bit integer types
+ to represent times. A GLuint64 variable has enough width to contain a duration
+ of hundreds of years, which is plenty for real-time rendering needs.
+
+ As with the other Qt OpenGL classes, QOpenGLTimerQuery has a create()
+ function to create the underlying OpenGL object. This is to allow the developer to
+ ensure that there is a valid current OpenGL context at the time.
+
+ Once created, timer queries can be issued in one of several ways. The simplest
+ method is to delimit a block of commands with calls to begin() and end(). This
+ instructs OpenGL to measure the time taken from completing all commands issued
+ prior to begin() until the completion of all commands issued prior to end().
+
+ At the end of a frame we can retrieve the results by calling waitForResult().
+ As this function's name implies, it blocks CPU execution until OpenGL notifies
+ that the timer query result is available. To avoid blocking, you can check
+ if the query result is available by calling isResultAvailable(). Note that
+ modern GPUs are deeply pipelined and query results may not become availble for
+ between 1-5 frames after they were issued.
+
+ Note that OpenGL does not permit nesting or interleaving of multiple timer queries
+ using begin() and end(). Using multiple timer queries and recordTimestamp() avoids
+ this limitation. When using recordTimestamp() the result can be obtained at
+ some later time using isResultAvailable() and waitForResult(). Qt provides the
+ convenience class QOpenGLTimeMonitor that helps with using multiple query objects.
+
+ \sa QOpenGLTimeMonitor
+*/
+
+/*!
+ Creates a QOpenGLTimerQuery instance with the given \a parent. You must call create()
+ with a valid OpenGL context before using.
+*/
+QOpenGLTimerQuery::QOpenGLTimerQuery(QObject *parent)
+ : QObject(*new QOpenGLTimerQueryPrivate, parent)
+{
+}
+
+/*!
+ Destroys the QOpenGLTimerQuery and the underlying OpenGL resource.
+*/
+QOpenGLTimerQuery::~QOpenGLTimerQuery()
+{
+ QOpenGLContext* ctx = QOpenGLContext::currentContext();
+
+ Q_D(QOpenGLTimerQuery);
+ QOpenGLContext *oldContext = 0;
+ if (d->context != ctx) {
+ oldContext = ctx;
+ if (d->context->makeCurrent(oldContext->surface())) {
+ ctx = d->context;
+ } else {
+ qWarning("QOpenGLTimerQuery::~QOpenGLTimerQuery() failed to make query objects's context current");
+ ctx = 0;
+ }
+ }
+
+ if (ctx)
+ destroy();
+
+ if (oldContext) {
+ if (!oldContext->makeCurrent(oldContext->surface()))
+ qWarning("QOpenGLTimerQuery::~QOpenGLTimerQuery() failed to restore current context");
+ }
+}
+
+/*!
+ Creates the underlying OpenGL timer query object. There must be a valid OpenGL context
+ that supports query objects current for this function to succeed.
+
+ Returns true if the OpenGL timer query object was successfully created.
+*/
+bool QOpenGLTimerQuery::create()
+{
+ Q_D(QOpenGLTimerQuery);
+ return d->create();
+}
+
+/*!
+ Destroys the underlying OpenGL timer query object. The context that was current when
+ create() was called must be current when calling this function.
+*/
+void QOpenGLTimerQuery::destroy()
+{
+ Q_D(QOpenGLTimerQuery);
+ d->destroy();
+}
+
+/*!
+ Returns true if the underlying OpenGL query object has been created. If this
+ returns true and the associated OpenGL context is current, then you are able to issue
+ queries with this object.
+*/
+bool QOpenGLTimerQuery::isCreated() const
+{
+ Q_D(const QOpenGLTimerQuery);
+ return (d->timer != 0);
+}
+
+/*!
+ Returns the id of the underlying OpenGL query object.
+*/
+GLuint QOpenGLTimerQuery::objectId() const
+{
+ Q_D(const QOpenGLTimerQuery);
+ return d->timer;
+}
+
+/*!
+ Marks the start point in the OpenGL command queue for a sequence of commands to
+ be timed by this query object.
+
+ This is useful for simple use-cases. Usually it is better to use recordTimestamp().
+
+ \sa end(), isResultAvailable(), waitForResult(), recordTimestamp()
+*/
+void QOpenGLTimerQuery::begin()
+{
+ Q_D(QOpenGLTimerQuery);
+ d->begin();
+}
+
+/*!
+ Marks the end point in the OpenGL command queue for a sequence of commands to
+ be timed by this query object.
+
+ This is useful for simple use-cases. Usually it is better to use recordTimestamp().
+
+ \sa begin(), isResultAvailable(), waitForResult(), recordTimestamp()
+*/
+void QOpenGLTimerQuery::end()
+{
+ Q_D(QOpenGLTimerQuery);
+ d->end();
+}
+
+/*!
+ Places a marker in the OpenGL command queue for the GPU to record the timestamp
+ when this marker is reached by the GPU. This function is non-blocking and the
+ result will become available at some later time.
+
+ The availability of the result can be checked with isResultAvailable(). The result
+ can be fetched with waitForResult() which will block if the result is not yet
+ available.
+
+ \sa waitForResult(), isResultAvailable(), begin(), end()
+*/
+void QOpenGLTimerQuery::recordTimestamp()
+{
+ Q_D(QOpenGLTimerQuery);
+ return d->recordTimestamp();
+}
+
+/*!
+ Returns the current timestamp of the GPU when all previously issued OpenGL
+ commands have been received but not necessarily executed by the GPU.
+
+ This function blocks until the result is returned.
+
+ \sa recordTimestamp()
+*/
+GLuint64 QOpenGLTimerQuery::waitForTimestamp() const
+{
+ Q_D(const QOpenGLTimerQuery);
+ return d->waitForTimeStamp();
+}
+
+/*!
+ Returns true if the OpenGL timer query result is available.
+
+ This function is non-blocking and ideally should be used to check for the
+ availability of the query result before calling waitForResult().
+
+ \sa waitForResult()
+*/
+bool QOpenGLTimerQuery::isResultAvailable() const
+{
+ Q_D(const QOpenGLTimerQuery);
+ return d->isResultAvailable();
+}
+
+/*!
+ Returns the result of the OpenGL timer query.
+
+ This function will block until the result is made available by OpenGL. It is
+ recommended to call isResultAvailable() to ensure that the result is available
+ to avoid unnecessary blocking and stalling.
+
+ \sa isResultAvailable()
+*/
+GLuint64 QOpenGLTimerQuery::waitForResult() const
+{
+ Q_D(const QOpenGLTimerQuery);
+ return d->result();
+}
+
+
+class QOpenGLTimeMonitorPrivate : public QObjectPrivate
+{
+public:
+ QOpenGLTimeMonitorPrivate()
+ : QObjectPrivate(),
+ timers(),
+ timeSamples(),
+ context(0),
+ core(0),
+ ext(0),
+ requestedSampleCount(2),
+ currentSample(-1),
+ timerQueryActive(false)
+ {
+ }
+
+ ~QOpenGLTimeMonitorPrivate()
+ {
+ delete core;
+ delete ext;
+ }
+
+ bool create();
+ void destroy();
+ void recordSample();
+ bool isResultAvailable() const;
+ QVector<GLuint64> samples() const;
+ QVector<GLuint64> intervals() const;
+ void reset();
+
+ QVector<GLuint> timers;
+ mutable QVector<GLuint64> timeSamples;
+
+ QOpenGLContext *context;
+ QOpenGLQueryHelper *core;
+ QExtTimerQueryHelper *ext;
+
+ int requestedSampleCount;
+ int currentSample;
+ mutable bool timerQueryActive;
+};
+
+bool QOpenGLTimeMonitorPrivate::create()
+{
+ if (!timers.isEmpty() && timers.at(0) != 0 && timers.size() == requestedSampleCount)
+ return true;
+
+ QOpenGLContext *ctx = QOpenGLContext::currentContext();
+ if (context && context != ctx) {
+ qWarning("QTimeMonitor: Attempting to use different OpenGL context to recreate timers.\n"
+ "Please call destroy() first or use the same context to previously create");
+ return false;
+ }
+
+ context = ctx;
+ if (!context) {
+ qWarning("A current OpenGL context is required to create timer query objects");
+ return false;
+ }
+
+ // Resize the vectors that hold the timers and the recorded samples
+ timers.resize(requestedSampleCount);
+ timeSamples.resize(requestedSampleCount);
+
+ // Resolve the functions provided by OpenGL 1.5 and OpenGL 3.3 or ARB_timer_query
+ core = new QOpenGLQueryHelper(context);
+
+ // Check to see if we also need to resolve the functions for EXT_timer_query
+ QSurfaceFormat f = context->format();
+ if (f.version() <= qMakePair<int, int>(3, 2)
+ && !context->hasExtension(QByteArrayLiteral("GL_ARB_timer_query"))
+ && context->hasExtension(QByteArrayLiteral("GL_EXT_timer_query"))) {
+ ext = new QExtTimerQueryHelper(context);
+ } else if (f.version() <= qMakePair<int, int>(3, 2)
+ && !context->hasExtension(QByteArrayLiteral("GL_ARB_timer_query"))
+ && !context->hasExtension(QByteArrayLiteral("GL_EXT_timer_query"))) {
+ qWarning("QOpenGLTimeMonitor requires one of:\n"
+ " OpenGL 3.3 or newer,\n"
+ " OpenGL 3.2 and the ARB_timer_query extension\n"
+ " or the EXT_timer query extension");
+ return false;
+ }
+
+ core->glGenQueries(requestedSampleCount, timers.data());
+ return (timers.at(0) != 0);
+}
+
+void QOpenGLTimeMonitorPrivate::destroy()
+{
+ if (timers.isEmpty() || timers.at(0) == 0)
+ return;
+
+ core->glDeleteQueries(timers.size(), timers.data());
+ timers.clear();
+ delete core;
+ core = 0;
+ delete ext;
+ ext = 0;
+ context = 0;
+}
+
+void QOpenGLTimeMonitorPrivate::recordSample()
+{
+ // Use glQueryCounter() and GL_TIMESTAMP where available.
+ // Otherwise, simulate it with glBeginQuery()/glEndQuery()
+ if (!ext) {
+#if defined(GL_TIMESTAMP)
+ core->glQueryCounter(timers.at(++currentSample), GL_TIMESTAMP);
+#endif
+ } else {
+ if (currentSample == -1) {
+ core->glBeginQuery(GL_TIME_ELAPSED_EXT, timers.at(++currentSample));
+ timerQueryActive = true;
+ } else if (currentSample < timers.size() - 1) {
+ core->glEndQuery(GL_TIME_ELAPSED_EXT);
+ core->glBeginQuery(GL_TIME_ELAPSED_EXT, timers.at(++currentSample));
+ } else {
+ if (timerQueryActive) {
+ core->glEndQuery(GL_TIME_ELAPSED_EXT);
+ timerQueryActive = false;
+ }
+ }
+ }
+}
+
+bool QOpenGLTimeMonitorPrivate::isResultAvailable() const
+{
+ // The OpenGL spec says that if a query result is ready then the results of all queries
+ // of the same type issued before it must also be ready. Therefore we only need to check
+ // the availability of the result for the last issued query
+ GLuint available = GL_FALSE;
+ core->glGetQueryObjectuiv(timers.at(currentSample), GL_QUERY_RESULT_AVAILABLE, &available);
+ return available;
+}
+
+QVector<GLuint64> QOpenGLTimeMonitorPrivate::samples() const
+{
+ // For the Core and ARB options just ask for the timestamp for each timer query.
+ // For the EXT implementation we cannot obtain timestamps so we defer any result
+ // collection to the intervals() function
+ if (!ext) {
+ for (int i = 0; i <= currentSample; ++i)
+ core->glGetQueryObjectui64v(timers.at(i), GL_QUERY_RESULT, &timeSamples[i]);
+ } else {
+ qWarning("QOpenGLTimeMonitor::samples() requires OpenGL >=3.3\n"
+ "or OpenGL 3.2 and GL_ARB_timer_query");
+ }
+ return timeSamples;
+}
+
+QVector<GLuint64> QOpenGLTimeMonitorPrivate::intervals() const
+{
+ QVector<GLuint64> intervals(timers.size() - 1);
+ if (!ext) {
+ // Obtain the timestamp samples and calculate the interval durations
+ const QVector<GLuint64> timeStamps = samples();
+ for (int i = 0; i < intervals.size(); ++i)
+ intervals[i] = timeStamps[i+1] - timeStamps[i];
+ } else {
+ // Stop the last timer if needed
+ if (timerQueryActive) {
+ core->glEndQuery(GL_TIME_ELAPSED_EXT);
+ timerQueryActive = false;
+ }
+
+ // Obtain the results from all timers apart from the redundant last one. In this
+ // case the results actually are the intervals not timestamps
+ for (int i = 0; i < currentSample; ++i)
+ ext->glGetQueryObjectui64vEXT(timers.at(i), GL_QUERY_RESULT, &intervals[i]);
+ }
+
+ return intervals;
+}
+
+void QOpenGLTimeMonitorPrivate::reset()
+{
+ currentSample = -1;
+ timeSamples.fill(0);
+}
+
+
+/*!
+ \class QOpenGLTimeMonitor
+ \brief The QOpenGLTimeMonitor class wraps a sequence of OpenGL timer query objects.
+ \inmodule QtGui
+ \since 5.1
+ \ingroup painting-3D
+
+ The QOpenGLTimeMonitor class is a convenience wrapper around a collection of OpenGL
+ timer query objects used to measure intervals of time on the GPU to the level of
+ granularity required by your rendering application.
+
+ The OpenGL timer queries objects are queried in sequence to record the GPU
+ timestamps at positions of interest in your rendering code. Once the results for
+ all issues timer queries become available, the results can be fetched and
+ QOpenGLTimerMonitor will calculate the recorded time intervals for you.
+
+ The typical use case of this class is to either profile your application's rendering
+ algorithms or to adjust those algorithms in real-time for dynamic performance/quality
+ balancing.
+
+ Prior to using QOpenGLTimeMonitor in your rendering function you should set the
+ required number of sample points that you wish to record by calling setSamples(). Note
+ that measuring N sample points will produce N-1 time intervals. Once you have set the
+ number of sample points, call the create() function with a valid current OpenGL context
+ to create the necessary query timer objects. These steps are usually performed just
+ once in an initialization function.
+
+ Use the recordSample() function to delimit blocks of code containing OpenGL commands
+ that you wish to time. You can check availability of the resulting time
+ samples and time intervals with isResultAvailable(). The calculated time intervals and
+ the raw timestamp samples can be retrieved with the blocking waitForIntervals() and
+ waitForSamples() functions respectively.
+
+ After retrieving the results and before starting a new round of taking samples
+ (for example, in the next frame) be sure to call the reset() function which will clear
+ the cached results and reset the timer index back to the first timer object.
+
+ \sa QOpenGLTimerQuery
+*/
+
+/*!
+ Creates a QOpenGLTimeMonitor instance with the given \a parent. You must call create()
+ with a valid OpenGL context before using.
+
+ \sa setSampleCount(), create()
+*/
+QOpenGLTimeMonitor::QOpenGLTimeMonitor(QObject *parent)
+ : QObject(*new QOpenGLTimeMonitorPrivate, parent)
+{
+}
+
+/*!
+ Destroys the QOpenGLTimeMonitor and any underlying OpenGL resources.
+*/
+QOpenGLTimeMonitor::~QOpenGLTimeMonitor()
+{
+ QOpenGLContext* ctx = QOpenGLContext::currentContext();
+
+ Q_D(QOpenGLTimeMonitor);
+ QOpenGLContext *oldContext = 0;
+ if (d->context != ctx) {
+ oldContext = ctx;
+ if (d->context->makeCurrent(oldContext->surface())) {
+ ctx = d->context;
+ } else {
+ qWarning("QOpenGLTimeMonitor::~QOpenGLTimeMonitor() failed to make time monitor's context current");
+ ctx = 0;
+ }
+ }
+
+ if (ctx)
+ destroy();
+
+ if (oldContext) {
+ if (!oldContext->makeCurrent(oldContext->surface()))
+ qWarning("QOpenGLTimeMonitor::~QOpenGLTimeMonitor() failed to restore current context");
+ }
+}
+
+/*!
+ Sets the number of sample points to \a sampleCount. After setting the number
+ of samples with this function, you must call create() to instantiate the underlying
+ OpenGL timer query objects.
+
+ The new \a sampleCount must be at least 2.
+
+ \sa sampleCount(), create(), recordSample()
+*/
+void QOpenGLTimeMonitor::setSampleCount(int sampleCount)
+{
+ // We need at least 2 samples to get an interval
+ if (sampleCount < 2)
+ return;
+ Q_D(QOpenGLTimeMonitor);
+ d->requestedSampleCount = sampleCount;
+}
+
+/*!
+ Returns the number of sample points that have been requested with
+ setSampleCount(). If create was successfully called following setSampleCount(),
+ then the value returned will be the actual number of sample points
+ that can be used.
+
+ The default value for sample count is 2, leading to the measurement of a
+ single interval.
+
+ \sa setSampleCount()
+*/
+int QOpenGLTimeMonitor::sampleCount() const
+{
+ Q_D(const QOpenGLTimeMonitor);
+ return d->requestedSampleCount;
+}
+
+/*!
+ Instantiate sampleCount() OpenGL timer query objects that will be used
+ to track the amount of time taken to execute OpenGL commands between
+ successive calls to recordSample().
+
+ Returns true if the OpenGL timer query objects could be created.
+
+ \sa destroy(), setSampleCount(), recordSample()
+*/
+bool QOpenGLTimeMonitor::create()
+{
+ Q_D(QOpenGLTimeMonitor);
+ return d->create();
+}
+
+/*!
+ Destroys any OpenGL timer query objects used within this instance.
+
+ \sa create()
+*/
+void QOpenGLTimeMonitor::destroy()
+{
+ Q_D(QOpenGLTimeMonitor);
+ d->destroy();
+}
+
+/*!
+ Returns true if the underlying OpenGL query objects have been created. If this
+ returns true and the associated OpenGL context is current, then you are able to record
+ time samples with this object.
+*/
+bool QOpenGLTimeMonitor::isCreated() const
+{
+ Q_D(const QOpenGLTimeMonitor);
+ return (!d->timers.isEmpty() && d->timers.at(0) != 0);
+}
+
+/*!
+ Returns a QVector containing the object Ids of the OpenGL timer query objects.
+*/
+QVector<GLuint> QOpenGLTimeMonitor::objectIds() const
+{
+ Q_D(const QOpenGLTimeMonitor);
+ return d->timers;
+}
+
+/*!
+ Issues an OpenGL timer query at this point in the OpenGL command queue. Calling this
+ function in a sequence in your application's rendering function, will build up
+ details of the GPU time taken to execute the OpenGL commands between successive
+ calls to this function.
+
+ \sa setSampleCount(), isResultAvailable(), waitForSamples(), waitForIntervals()
+*/
+int QOpenGLTimeMonitor::recordSample()
+{
+ Q_D(QOpenGLTimeMonitor);
+ d->recordSample();
+ return d->currentSample;
+}
+
+/*!
+ Returns true if the OpenGL timer query results are available.
+
+ \sa waitForSamples(), waitForIntervals()
+*/
+bool QOpenGLTimeMonitor::isResultAvailable() const
+{
+ Q_D(const QOpenGLTimeMonitor);
+ return d->isResultAvailable();
+}
+
+/*!
+ Returns a QVector containing the GPU timestamps taken with recordSample().
+
+ This function will block until OpenGL indicates the results are available. It
+ is recommended to check the availability of the result prior to calling this
+ function with isResultAvailable().
+
+ \note This function only works on systems that have OpenGL >=3.3 or the
+ ARB_timer_query extension. See QOpenGLTimerQuery for more details.
+
+ \sa waitForIntervals(), isResultAvailable()
+*/
+QVector<GLuint64> QOpenGLTimeMonitor::waitForSamples() const
+{
+ Q_D(const QOpenGLTimeMonitor);
+ return d->samples();
+}
+
+/*!
+ Returns a QVector containing the time intervals delimited by the calls to
+ recordSample(). The resulting vector will contain one fewer element as
+ this represents the intervening intervals rather than the actual timestamp
+ samples.
+
+ This function will block until OpenGL indicates the results are available. It
+ is recommended to check the availability of the result prior to calling this
+ function with isResultAvailable().
+
+ \sa waitForSamples(), isResultAvailable()
+*/
+QVector<GLuint64> QOpenGLTimeMonitor::waitForIntervals() const
+{
+ Q_D(const QOpenGLTimeMonitor);
+ return d->intervals();
+}
+
+/*!
+ Resets the time monitor ready for use in another frame of rendering. Call
+ this once you have obtained the previous results and before calling
+ recordSample() for the first time on the next frame.
+
+ \sa recordSample()
+*/
+void QOpenGLTimeMonitor::reset()
+{
+ Q_D(QOpenGLTimeMonitor);
+ d->reset();
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopengltimerquery.h b/src/gui/opengl/qopengltimerquery.h
new file mode 100644
index 0000000000..649e80d6c0
--- /dev/null
+++ b/src/gui/opengl/qopengltimerquery.h
@@ -0,0 +1,116 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QOPENGLTIMERQUERY_H
+#define QOPENGLTIMERQUERY_H
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtCore/QObject>
+#include <QtGui/qopengl.h>
+
+QT_BEGIN_NAMESPACE
+
+class QOpenGLTimerQueryPrivate;
+
+class Q_GUI_EXPORT QOpenGLTimerQuery : public QObject
+{
+ Q_OBJECT
+
+public:
+ explicit QOpenGLTimerQuery(QObject *parent = 0);
+ ~QOpenGLTimerQuery();
+
+ bool create();
+ void destroy();
+ bool isCreated() const;
+ GLuint objectId() const;
+
+ void begin();
+ void end();
+ GLuint64 waitForTimestamp() const;
+ void recordTimestamp();
+ bool isResultAvailable() const;
+ GLuint64 waitForResult() const;
+
+private:
+ Q_DECLARE_PRIVATE(QOpenGLTimerQuery)
+ Q_DISABLE_COPY(QOpenGLTimerQuery)
+};
+
+
+class QOpenGLTimeMonitorPrivate;
+
+class Q_GUI_EXPORT QOpenGLTimeMonitor : public QObject
+{
+ Q_OBJECT
+
+public:
+ explicit QOpenGLTimeMonitor(QObject *parent = 0);
+ ~QOpenGLTimeMonitor();
+
+ void setSampleCount(int sampleCount);
+ int sampleCount() const;
+
+ bool create();
+ void destroy();
+ bool isCreated() const;
+ QVector<GLuint> objectIds() const;
+
+ int recordSample();
+
+ bool isResultAvailable() const;
+
+ QVector<GLuint64> waitForSamples() const;
+ QVector<GLuint64> waitForIntervals() const;
+
+ void reset();
+
+private:
+ Q_DECLARE_PRIVATE(QOpenGLTimeMonitor)
+ Q_DISABLE_COPY(QOpenGLTimeMonitor)
+};
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL
+
+#endif // QOPENGLTIMERQUERY_H
diff --git a/src/gui/opengl/qopenglversionfunctions.cpp b/src/gui/opengl/qopenglversionfunctions.cpp
new file mode 100644
index 0000000000..0b1b6834e3
--- /dev/null
+++ b/src/gui/opengl/qopenglversionfunctions.cpp
@@ -0,0 +1,1791 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglversionfunctions.h"
+#include "qopenglcontext.h"
+#include "qdebug.h"
+
+QT_BEGIN_NAMESPACE
+
+QOpenGLVersionFunctionsBackend *QAbstractOpenGLFunctionsPrivate::functionsBackend(QOpenGLContext *context,
+ const QOpenGLVersionStatus &v)
+{
+ Q_ASSERT(context);
+ return context->functionsBackend(v);
+}
+
+void QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(QOpenGLContext *context,
+ const QOpenGLVersionStatus &v,
+ QOpenGLVersionFunctionsBackend *backend)
+{
+ Q_ASSERT(context);
+ context->insertFunctionsBackend(v, backend);
+}
+
+void QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(QOpenGLContext *context, const QOpenGLVersionStatus &v)
+{
+ Q_ASSERT(context);
+ context->removeFunctionsBackend(v);
+}
+
+
+/*!
+ \class QAbstractOpenGLFunctions
+ \inmodule QtGui
+ \since 5.1
+ \brief The QAbstractOpenGLFunctions class is the base class of a family of
+ classes that expose all functions for each OpenGL version and
+ profile.
+
+ OpenGL implementations on different platforms are able to link to a variable
+ number of OpenGL functions depending upon the OpenGL ABI on that platform.
+ For example, on Microsoft Windows only functions up to those in OpenGL 1.1
+ can be linked to at build time. All other functions must be resolved at
+ runtime. The traditional solution to this has been to use either
+ QOpenGLContext::getProcAddress() or QOpenGLFunctions. The former is tedious
+ and error prone and means dealing directly with function pointers. The
+ latter only exposes those functions common to OpenGL ES 2 and desktop
+ OpenGL. There is however much new OpenGL functionality that is useful when
+ writing real world OpenGL applications.
+
+ Qt now provides a family of classes which all inherit from
+ QAbstractOpenGLFunctions which expose every core OpenGL function by way of a
+ corresponding member function. There is a class for every valid combination
+ of OpenGL version and profile. Each class follows the naming convention
+ QOpenGLFunctions_<MAJOR VERSION>_<MINOR VERSION>[_PROFILE].
+
+ For OpenGL versions 1.0 through to 3.0 there are no profiles, leading to the
+ classes:
+
+ \list
+ \li QOpenGLFunctions_1_0
+ \li QOpenGLFunctions_1_1
+ \li QOpenGLFunctions_1_2
+ \li QOpenGLFunctions_1_3
+ \li QOpenGLFunctions_1_4
+ \li QOpenGLFunctions_1_5
+ \li QOpenGLFunctions_2_0
+ \li QOpenGLFunctions_2_1
+ \li QOpenGLFunctions_3_0
+ \endlist
+
+ where each class inherits from QAbstractOpenGLFunctions.
+
+ OpenGL version 3.1 removed many deprecated functions leading to a much
+ simpler and generic API.
+
+ With OpenGL 3.2 the concept of profiles was introduced. Two profiles are
+ currently defined for OpenGL: Core and Compatibility.
+
+ The Core profile does not include any of the functions that were removed
+ in OpenGL 3.1. The Compatibility profile contains all functions in the
+ Core profile of the same version plus all of the functions that were
+ removed in OpenGL 3.1. In this way the Compatibility profile classes allow
+ use of newer OpenGL functionality but also allows you to keep using your
+ legacy OpenGL code. For new OpenGL code the Core profile should be
+ preferred.
+
+ Please note that some vendors, notably Apple, do not implement the
+ Compatibility profile. Therefore if you wish to target new OpenGL features
+ on OS X then you should ensure that you request a Core profile context via
+ QSurfaceFormat::setProfile().
+
+ Qt provides classes for all version and Core and Compatibility profile
+ combinations. The classes for OpenGL versions 3.1 through to 4.3 are:
+
+ \list
+ \li QOpenGLFunctions_3_1
+ \li QOpenGLFunctions_3_2_Core
+ \li QOpenGLFunctions_3_2_Compatibility
+ \li QOpenGLFunctions_3_3_Core
+ \li QOpenGLFunctions_3_3_Compatibility
+ \li QOpenGLFunctions_4_0_Core
+ \li QOpenGLFunctions_4_0_Compatibility
+ \li QOpenGLFunctions_4_1_Core
+ \li QOpenGLFunctions_4_1_Compatibility
+ \li QOpenGLFunctions_4_2_Core
+ \li QOpenGLFunctions_4_2_Compatibility
+ \li QOpenGLFunctions_4_3_Core
+ \li QOpenGLFunctions_4_3_Compatibility
+ \endlist
+
+ where each class inherits from QAbstractOpenGLFunctions.
+
+ A pointer to an object of the class corresponding to the version and
+ profile of OpenGL in use can be obtained from
+ QOpenGLFunctions::versionFunctions(). If obtained in this way, note that
+ the QOpenGLContext retains ownership of the object. This is so that only
+ one instance need be created.
+
+ Before calling any of the exposed OpenGL functions you must ensure that the
+ object has resolved the function pointers to the OpenGL functions. This
+ only needs to be done once per instance with initializeOpenGLFunctions().
+ Once initialized, the object can be used to call any OpenGL function for
+ the corresponding version and profile. Note that initializeOpenGLFunctions()
+ can fail in some circumstances so check the return value. Situations in
+ which initialization can fail are if you have a functions object for a version
+ or profile that contains functions that are not part of the context being
+ used to resolve the function pointers.
+
+ If you exclusively use function objects then you will get compile time
+ errors if you attempt to use a function not included in that version and
+ profile. This is obviously a lot easier to debug than undefined behavior
+ at run time.
+
+ \sa QOpenGLContext::versionFunctions()
+*/
+QAbstractOpenGLFunctions::QAbstractOpenGLFunctions()
+ : d_ptr(new QAbstractOpenGLFunctionsPrivate)
+{
+}
+
+QAbstractOpenGLFunctions::~QAbstractOpenGLFunctions()
+{
+ delete d_ptr;
+}
+
+bool QAbstractOpenGLFunctions::initializeOpenGLFunctions()
+{
+ Q_D(QAbstractOpenGLFunctions);
+ d->initialized = true;
+ return true;
+}
+
+bool QAbstractOpenGLFunctions::isInitialized() const
+{
+ Q_D(const QAbstractOpenGLFunctions);
+ return d->initialized;
+}
+
+void QAbstractOpenGLFunctions::setOwningContext(const QOpenGLContext *context)
+{
+ Q_D(QAbstractOpenGLFunctions);
+ d->owningContext = const_cast<QOpenGLContext*>(context);
+}
+
+QOpenGLContext *QAbstractOpenGLFunctions::owningContext() const
+{
+ Q_D(const QAbstractOpenGLFunctions);
+ return d->owningContext;
+}
+
+#if !defined(QT_OPENGL_ES_2)
+
+QOpenGLFunctions_1_0_CoreBackend::QOpenGLFunctions_1_0_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 1.0 core functions
+#if defined(Q_OS_WIN)
+ HMODULE handle = GetModuleHandleA("opengl32.dll");
+ Viewport = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLsizei , GLsizei )>(GetProcAddress(handle, "glViewport"));
+ DepthRange = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(GetProcAddress(handle, "glDepthRange"));
+ IsEnabled = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glIsEnabled"));
+ GetTexLevelParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLint *)>(GetProcAddress(handle, "glGetTexLevelParameteriv"));
+ GetTexLevelParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLfloat *)>(GetProcAddress(handle, "glGetTexLevelParameterfv"));
+ GetTexParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(GetProcAddress(handle, "glGetTexParameteriv"));
+ GetTexParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(GetProcAddress(handle, "glGetTexParameterfv"));
+ GetTexImage = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLenum , GLvoid *)>(GetProcAddress(handle, "glGetTexImage"));
+ GetString = reinterpret_cast<const GLubyte * (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glGetString"));
+ GetIntegerv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint *)>(GetProcAddress(handle, "glGetIntegerv"));
+ GetFloatv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat *)>(GetProcAddress(handle, "glGetFloatv"));
+ GetError = reinterpret_cast<GLenum (QOPENGLF_APIENTRYP)()>(GetProcAddress(handle, "glGetError"));
+ GetDoublev = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble *)>(GetProcAddress(handle, "glGetDoublev"));
+ GetBooleanv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLboolean *)>(GetProcAddress(handle, "glGetBooleanv"));
+ ReadPixels = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLsizei , GLsizei , GLenum , GLenum , GLvoid *)>(GetProcAddress(handle, "glReadPixels"));
+ ReadBuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glReadBuffer"));
+ PixelStorei = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(GetProcAddress(handle, "glPixelStorei"));
+ PixelStoref = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(GetProcAddress(handle, "glPixelStoref"));
+ DepthFunc = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glDepthFunc"));
+ StencilOp = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum )>(GetProcAddress(handle, "glStencilOp"));
+ StencilFunc = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLuint )>(GetProcAddress(handle, "glStencilFunc"));
+ LogicOp = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glLogicOp"));
+ BlendFunc = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(GetProcAddress(handle, "glBlendFunc"));
+ Flush = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(GetProcAddress(handle, "glFlush"));
+ Finish = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(GetProcAddress(handle, "glFinish"));
+ Enable = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glEnable"));
+ Disable = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glDisable"));
+ DepthMask = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLboolean )>(GetProcAddress(handle, "glDepthMask"));
+ ColorMask = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLboolean , GLboolean , GLboolean , GLboolean )>(GetProcAddress(handle, "glColorMask"));
+ StencilMask = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(GetProcAddress(handle, "glStencilMask"));
+ ClearDepth = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble )>(GetProcAddress(handle, "glClearDepth"));
+ ClearStencil = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(GetProcAddress(handle, "glClearStencil"));
+ ClearColor = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glClearColor"));
+ Clear = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(GetProcAddress(handle, "glClear"));
+ DrawBuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glDrawBuffer"));
+ TexImage2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLsizei , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(GetProcAddress(handle, "glTexImage2D"));
+ TexImage1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(GetProcAddress(handle, "glTexImage1D"));
+ TexParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(GetProcAddress(handle, "glTexParameteriv"));
+ TexParameteri = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(GetProcAddress(handle, "glTexParameteri"));
+ TexParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(GetProcAddress(handle, "glTexParameterfv"));
+ TexParameterf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(GetProcAddress(handle, "glTexParameterf"));
+ Scissor = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLsizei , GLsizei )>(GetProcAddress(handle, "glScissor"));
+ PolygonMode = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(GetProcAddress(handle, "glPolygonMode"));
+ PointSize = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(GetProcAddress(handle, "glPointSize"));
+ LineWidth = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(GetProcAddress(handle, "glLineWidth"));
+ Hint = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(GetProcAddress(handle, "glHint"));
+ FrontFace = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glFrontFace"));
+ CullFace = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glCullFace"));
+#else
+ Viewport = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glViewport"));
+ DepthRange = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(context->getProcAddress("glDepthRange"));
+ IsEnabled = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glIsEnabled"));
+ GetTexLevelParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLint *)>(context->getProcAddress("glGetTexLevelParameteriv"));
+ GetTexLevelParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLfloat *)>(context->getProcAddress("glGetTexLevelParameterfv"));
+ GetTexParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetTexParameteriv"));
+ GetTexParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetTexParameterfv"));
+ GetTexImage = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetTexImage"));
+ GetString = reinterpret_cast<const GLubyte * (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glGetString"));
+ GetIntegerv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint *)>(context->getProcAddress("glGetIntegerv"));
+ GetFloatv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat *)>(context->getProcAddress("glGetFloatv"));
+ GetError = reinterpret_cast<GLenum (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glGetError"));
+ GetDoublev = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble *)>(context->getProcAddress("glGetDoublev"));
+ GetBooleanv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLboolean *)>(context->getProcAddress("glGetBooleanv"));
+ ReadPixels = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLsizei , GLsizei , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glReadPixels"));
+ ReadBuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glReadBuffer"));
+ PixelStorei = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glPixelStorei"));
+ PixelStoref = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glPixelStoref"));
+ DepthFunc = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glDepthFunc"));
+ StencilOp = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum )>(context->getProcAddress("glStencilOp"));
+ StencilFunc = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLuint )>(context->getProcAddress("glStencilFunc"));
+ LogicOp = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glLogicOp"));
+ BlendFunc = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glBlendFunc"));
+ Flush = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glFlush"));
+ Finish = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glFinish"));
+ Enable = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glEnable"));
+ Disable = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glDisable"));
+ DepthMask = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLboolean )>(context->getProcAddress("glDepthMask"));
+ ColorMask = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLboolean , GLboolean , GLboolean , GLboolean )>(context->getProcAddress("glColorMask"));
+ StencilMask = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glStencilMask"));
+ ClearDepth = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble )>(context->getProcAddress("glClearDepth"));
+ ClearStencil = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(context->getProcAddress("glClearStencil"));
+ ClearColor = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glClearColor"));
+ Clear = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(context->getProcAddress("glClear"));
+ DrawBuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glDrawBuffer"));
+ TexImage2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLsizei , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTexImage2D"));
+ TexImage1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTexImage1D"));
+ TexParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glTexParameteriv"));
+ TexParameteri = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glTexParameteri"));
+ TexParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glTexParameterfv"));
+ TexParameterf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(context->getProcAddress("glTexParameterf"));
+ Scissor = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glScissor"));
+ PolygonMode = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glPolygonMode"));
+ PointSize = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glPointSize"));
+ LineWidth = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glLineWidth"));
+ Hint = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glHint"));
+ FrontFace = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glFrontFace"));
+ CullFace = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glCullFace"));
+#endif
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_1_0_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(1, 0, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_1_1_CoreBackend::QOpenGLFunctions_1_1_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 1.1 core functions
+#if defined(Q_OS_WIN)
+ HMODULE handle = GetModuleHandleA("opengl32.dll");
+ Indexubv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *)>(GetProcAddress(handle, "glIndexubv"));
+ Indexub = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte )>(GetProcAddress(handle, "glIndexub"));
+ IsTexture = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(GetProcAddress(handle, "glIsTexture"));
+ GenTextures = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(GetProcAddress(handle, "glGenTextures"));
+ DeleteTextures = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(GetProcAddress(handle, "glDeleteTextures"));
+ BindTexture = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(GetProcAddress(handle, "glBindTexture"));
+ TexSubImage2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(GetProcAddress(handle, "glTexSubImage2D"));
+ TexSubImage1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLsizei , GLenum , GLenum , const GLvoid *)>(GetProcAddress(handle, "glTexSubImage1D"));
+ CopyTexSubImage2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLint , GLsizei , GLsizei )>(GetProcAddress(handle, "glCopyTexSubImage2D"));
+ CopyTexSubImage1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLsizei )>(GetProcAddress(handle, "glCopyTexSubImage1D"));
+ CopyTexImage2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLint , GLint , GLsizei , GLsizei , GLint )>(GetProcAddress(handle, "glCopyTexImage2D"));
+ CopyTexImage1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLint , GLint , GLsizei , GLint )>(GetProcAddress(handle, "glCopyTexImage1D"));
+ PolygonOffset = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(GetProcAddress(handle, "glPolygonOffset"));
+ GetPointerv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLvoid* *)>(GetProcAddress(handle, "glGetPointerv"));
+ DrawElements = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const GLvoid *)>(GetProcAddress(handle, "glDrawElements"));
+ DrawArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLsizei )>(GetProcAddress(handle, "glDrawArrays"));
+#else
+ Indexubv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *)>(context->getProcAddress("glIndexubv"));
+ Indexub = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte )>(context->getProcAddress("glIndexub"));
+ IsTexture = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsTexture"));
+ GenTextures = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenTextures"));
+ DeleteTextures = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteTextures"));
+ BindTexture = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindTexture"));
+ TexSubImage2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTexSubImage2D"));
+ TexSubImage1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTexSubImage1D"));
+ CopyTexSubImage2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glCopyTexSubImage2D"));
+ CopyTexSubImage1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLsizei )>(context->getProcAddress("glCopyTexSubImage1D"));
+ CopyTexImage2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLint , GLint , GLsizei , GLsizei , GLint )>(context->getProcAddress("glCopyTexImage2D"));
+ CopyTexImage1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLint , GLint , GLsizei , GLint )>(context->getProcAddress("glCopyTexImage1D"));
+ PolygonOffset = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glPolygonOffset"));
+ GetPointerv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLvoid* *)>(context->getProcAddress("glGetPointerv"));
+ DrawElements = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const GLvoid *)>(context->getProcAddress("glDrawElements"));
+ DrawArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLsizei )>(context->getProcAddress("glDrawArrays"));
+#endif
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_1_1_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(1, 1, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_1_2_CoreBackend::QOpenGLFunctions_1_2_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 1.2 core functions
+ CopyTexSubImage3D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glCopyTexSubImage3D"));
+ TexSubImage3D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTexSubImage3D"));
+ TexImage3D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLsizei , GLsizei , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTexImage3D"));
+ DrawRangeElements = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLsizei , GLenum , const GLvoid *)>(context->getProcAddress("glDrawRangeElements"));
+ BlendEquation = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glBlendEquation"));
+ BlendColor = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glBlendColor"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_1_2_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(1, 2, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_1_3_CoreBackend::QOpenGLFunctions_1_3_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 1.3 core functions
+ GetCompressedTexImage = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLvoid *)>(context->getProcAddress("glGetCompressedTexImage"));
+ CompressedTexSubImage1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLsizei , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTexSubImage1D"));
+ CompressedTexSubImage2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLsizei , GLsizei , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTexSubImage2D"));
+ CompressedTexSubImage3D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTexSubImage3D"));
+ CompressedTexImage1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLsizei , GLint , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTexImage1D"));
+ CompressedTexImage2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLsizei , GLsizei , GLint , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTexImage2D"));
+ CompressedTexImage3D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLsizei , GLsizei , GLsizei , GLint , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTexImage3D"));
+ SampleCoverage = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLboolean )>(context->getProcAddress("glSampleCoverage"));
+ ActiveTexture = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glActiveTexture"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_1_3_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(1, 3, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_1_4_CoreBackend::QOpenGLFunctions_1_4_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 1.4 core functions
+ PointParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glPointParameteriv"));
+ PointParameteri = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glPointParameteri"));
+ PointParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glPointParameterfv"));
+ PointParameterf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glPointParameterf"));
+ MultiDrawElements = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLsizei *, GLenum , const GLvoid* const *, GLsizei )>(context->getProcAddress("glMultiDrawElements"));
+ MultiDrawArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *, const GLsizei *, GLsizei )>(context->getProcAddress("glMultiDrawArrays"));
+ BlendFuncSeparate = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLenum )>(context->getProcAddress("glBlendFuncSeparate"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_1_4_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(1, 4, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_1_5_CoreBackend::QOpenGLFunctions_1_5_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 1.5 core functions
+ GetBufferPointerv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLvoid* *)>(context->getProcAddress("glGetBufferPointerv"));
+ GetBufferParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetBufferParameteriv"));
+ UnmapBuffer = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glUnmapBuffer"));
+ MapBuffer = reinterpret_cast<GLvoid* (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glMapBuffer"));
+ GetBufferSubData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLintptr , GLsizeiptr , GLvoid *)>(context->getProcAddress("glGetBufferSubData"));
+ BufferSubData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLintptr , GLsizeiptr , const GLvoid *)>(context->getProcAddress("glBufferSubData"));
+ BufferData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizeiptr , const GLvoid *, GLenum )>(context->getProcAddress("glBufferData"));
+ IsBuffer = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsBuffer"));
+ GenBuffers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenBuffers"));
+ DeleteBuffers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteBuffers"));
+ BindBuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindBuffer"));
+ GetQueryObjectuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint *)>(context->getProcAddress("glGetQueryObjectuiv"));
+ GetQueryObjectiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetQueryObjectiv"));
+ GetQueryiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetQueryiv"));
+ EndQuery = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glEndQuery"));
+ BeginQuery = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBeginQuery"));
+ IsQuery = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsQuery"));
+ DeleteQueries = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteQueries"));
+ GenQueries = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenQueries"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_1_5_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(1, 5, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_2_0_CoreBackend::QOpenGLFunctions_2_0_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 2.0 core functions
+ VertexAttribPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLboolean , GLsizei , const GLvoid *)>(context->getProcAddress("glVertexAttribPointer"));
+ ValidateProgram = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glValidateProgram"));
+ UniformMatrix4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glUniformMatrix4fv"));
+ UniformMatrix3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glUniformMatrix3fv"));
+ UniformMatrix2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glUniformMatrix2fv"));
+ Uniform4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLint *)>(context->getProcAddress("glUniform4iv"));
+ Uniform3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLint *)>(context->getProcAddress("glUniform3iv"));
+ Uniform2iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLint *)>(context->getProcAddress("glUniform2iv"));
+ Uniform1iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLint *)>(context->getProcAddress("glUniform1iv"));
+ Uniform4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glUniform4fv"));
+ Uniform3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glUniform3fv"));
+ Uniform2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glUniform2fv"));
+ Uniform1fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glUniform1fv"));
+ Uniform4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glUniform4i"));
+ Uniform3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(context->getProcAddress("glUniform3i"));
+ Uniform2i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glUniform2i"));
+ Uniform1i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(context->getProcAddress("glUniform1i"));
+ Uniform4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glUniform4f"));
+ Uniform3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glUniform3f"));
+ Uniform2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLfloat , GLfloat )>(context->getProcAddress("glUniform2f"));
+ Uniform1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLfloat )>(context->getProcAddress("glUniform1f"));
+ UseProgram = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glUseProgram"));
+ ShaderSource = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLchar* const *, const GLint *)>(context->getProcAddress("glShaderSource"));
+ LinkProgram = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glLinkProgram"));
+ IsShader = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsShader"));
+ IsProgram = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsProgram"));
+ GetVertexAttribPointerv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLvoid* *)>(context->getProcAddress("glGetVertexAttribPointerv"));
+ GetVertexAttribiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetVertexAttribiv"));
+ GetVertexAttribfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetVertexAttribfv"));
+ GetVertexAttribdv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLdouble *)>(context->getProcAddress("glGetVertexAttribdv"));
+ GetUniformiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint *)>(context->getProcAddress("glGetUniformiv"));
+ GetUniformfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat *)>(context->getProcAddress("glGetUniformfv"));
+ GetUniformLocation = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , const GLchar *)>(context->getProcAddress("glGetUniformLocation"));
+ GetShaderSource = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetShaderSource"));
+ GetShaderInfoLog = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetShaderInfoLog"));
+ GetShaderiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetShaderiv"));
+ GetProgramInfoLog = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetProgramInfoLog"));
+ GetProgramiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetProgramiv"));
+ GetAttribLocation = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , const GLchar *)>(context->getProcAddress("glGetAttribLocation"));
+ GetAttachedShaders = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei *, GLuint *)>(context->getProcAddress("glGetAttachedShaders"));
+ GetActiveUniform = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLsizei , GLsizei *, GLint *, GLenum *, GLchar *)>(context->getProcAddress("glGetActiveUniform"));
+ GetActiveAttrib = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLsizei , GLsizei *, GLint *, GLenum *, GLchar *)>(context->getProcAddress("glGetActiveAttrib"));
+ EnableVertexAttribArray = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glEnableVertexAttribArray"));
+ DisableVertexAttribArray = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glDisableVertexAttribArray"));
+ DetachShader = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glDetachShader"));
+ DeleteShader = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glDeleteShader"));
+ DeleteProgram = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glDeleteProgram"));
+ CreateShader = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glCreateShader"));
+ CreateProgram = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glCreateProgram"));
+ CompileShader = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glCompileShader"));
+ BindAttribLocation = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , const GLchar *)>(context->getProcAddress("glBindAttribLocation"));
+ AttachShader = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glAttachShader"));
+ StencilMaskSeparate = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glStencilMaskSeparate"));
+ StencilFuncSeparate = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLuint )>(context->getProcAddress("glStencilFuncSeparate"));
+ StencilOpSeparate = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLenum )>(context->getProcAddress("glStencilOpSeparate"));
+ DrawBuffers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLenum *)>(context->getProcAddress("glDrawBuffers"));
+ BlendEquationSeparate = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glBlendEquationSeparate"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_2_0_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(2, 0, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_2_1_CoreBackend::QOpenGLFunctions_2_1_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 2.1 core functions
+ UniformMatrix4x3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glUniformMatrix4x3fv"));
+ UniformMatrix3x4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glUniformMatrix3x4fv"));
+ UniformMatrix4x2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glUniformMatrix4x2fv"));
+ UniformMatrix2x4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glUniformMatrix2x4fv"));
+ UniformMatrix3x2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glUniformMatrix3x2fv"));
+ UniformMatrix2x3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glUniformMatrix2x3fv"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_2_1_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(2, 1, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_3_0_CoreBackend::QOpenGLFunctions_3_0_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 3.0 core functions
+ IsVertexArray = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsVertexArray"));
+ GenVertexArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenVertexArrays"));
+ DeleteVertexArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteVertexArrays"));
+ BindVertexArray = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glBindVertexArray"));
+ FlushMappedBufferRange = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLintptr , GLsizeiptr )>(context->getProcAddress("glFlushMappedBufferRange"));
+ MapBufferRange = reinterpret_cast<GLvoid* (QOPENGLF_APIENTRYP)(GLenum , GLintptr , GLsizeiptr , GLbitfield )>(context->getProcAddress("glMapBufferRange"));
+ FramebufferTextureLayer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLint , GLint )>(context->getProcAddress("glFramebufferTextureLayer"));
+ RenderbufferStorageMultisample = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glRenderbufferStorageMultisample"));
+ BlitFramebuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint , GLint , GLint , GLint , GLint , GLbitfield , GLenum )>(context->getProcAddress("glBlitFramebuffer"));
+ GenerateMipmap = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glGenerateMipmap"));
+ GetFramebufferAttachmentParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetFramebufferAttachmentParameteriv"));
+ FramebufferRenderbuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint )>(context->getProcAddress("glFramebufferRenderbuffer"));
+ FramebufferTexture3D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint , GLint , GLint )>(context->getProcAddress("glFramebufferTexture3D"));
+ FramebufferTexture2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint , GLint )>(context->getProcAddress("glFramebufferTexture2D"));
+ FramebufferTexture1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint , GLint )>(context->getProcAddress("glFramebufferTexture1D"));
+ CheckFramebufferStatus = reinterpret_cast<GLenum (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glCheckFramebufferStatus"));
+ GenFramebuffers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenFramebuffers"));
+ DeleteFramebuffers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteFramebuffers"));
+ BindFramebuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindFramebuffer"));
+ IsFramebuffer = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsFramebuffer"));
+ GetRenderbufferParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetRenderbufferParameteriv"));
+ RenderbufferStorage = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glRenderbufferStorage"));
+ GenRenderbuffers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenRenderbuffers"));
+ DeleteRenderbuffers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteRenderbuffers"));
+ BindRenderbuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindRenderbuffer"));
+ IsRenderbuffer = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsRenderbuffer"));
+ GetStringi = reinterpret_cast<const GLubyte * (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glGetStringi"));
+ ClearBufferfi = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLfloat , GLint )>(context->getProcAddress("glClearBufferfi"));
+ ClearBufferfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLfloat *)>(context->getProcAddress("glClearBufferfv"));
+ ClearBufferuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLuint *)>(context->getProcAddress("glClearBufferuiv"));
+ ClearBufferiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLint *)>(context->getProcAddress("glClearBufferiv"));
+ GetTexParameterIuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint *)>(context->getProcAddress("glGetTexParameterIuiv"));
+ GetTexParameterIiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetTexParameterIiv"));
+ TexParameterIuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLuint *)>(context->getProcAddress("glTexParameterIuiv"));
+ TexParameterIiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glTexParameterIiv"));
+ Uniform4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint *)>(context->getProcAddress("glUniform4uiv"));
+ Uniform3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint *)>(context->getProcAddress("glUniform3uiv"));
+ Uniform2uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint *)>(context->getProcAddress("glUniform2uiv"));
+ Uniform1uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint *)>(context->getProcAddress("glUniform1uiv"));
+ Uniform4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glUniform4ui"));
+ Uniform3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint , GLuint , GLuint )>(context->getProcAddress("glUniform3ui"));
+ Uniform2ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint , GLuint )>(context->getProcAddress("glUniform2ui"));
+ Uniform1ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint )>(context->getProcAddress("glUniform1ui"));
+ GetFragDataLocation = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , const GLchar *)>(context->getProcAddress("glGetFragDataLocation"));
+ BindFragDataLocation = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , const GLchar *)>(context->getProcAddress("glBindFragDataLocation"));
+ GetUniformuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint *)>(context->getProcAddress("glGetUniformuiv"));
+ GetVertexAttribIuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint *)>(context->getProcAddress("glGetVertexAttribIuiv"));
+ GetVertexAttribIiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetVertexAttribIiv"));
+ VertexAttribIPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glVertexAttribIPointer"));
+ EndConditionalRender = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glEndConditionalRender"));
+ BeginConditionalRender = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glBeginConditionalRender"));
+ ClampColor = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glClampColor"));
+ GetTransformFeedbackVarying = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLsizei , GLsizei *, GLsizei *, GLenum *, GLchar *)>(context->getProcAddress("glGetTransformFeedbackVarying"));
+ TransformFeedbackVaryings = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLchar* const *, GLenum )>(context->getProcAddress("glTransformFeedbackVaryings"));
+ BindBufferBase = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint )>(context->getProcAddress("glBindBufferBase"));
+ BindBufferRange = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLintptr , GLsizeiptr )>(context->getProcAddress("glBindBufferRange"));
+ EndTransformFeedback = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glEndTransformFeedback"));
+ BeginTransformFeedback = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glBeginTransformFeedback"));
+ IsEnabledi = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glIsEnabledi"));
+ Disablei = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glDisablei"));
+ Enablei = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glEnablei"));
+ GetIntegeri_v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLint *)>(context->getProcAddress("glGetIntegeri_v"));
+ GetBooleani_v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLboolean *)>(context->getProcAddress("glGetBooleani_v"));
+ ColorMaski = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLboolean , GLboolean , GLboolean , GLboolean )>(context->getProcAddress("glColorMaski"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_3_0_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(3, 0, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_3_1_CoreBackend::QOpenGLFunctions_3_1_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 3.1 core functions
+ CopyBufferSubData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLintptr , GLintptr , GLsizeiptr )>(context->getProcAddress("glCopyBufferSubData"));
+ UniformBlockBinding = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glUniformBlockBinding"));
+ GetActiveUniformBlockName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetActiveUniformBlockName"));
+ GetActiveUniformBlockiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , GLint *)>(context->getProcAddress("glGetActiveUniformBlockiv"));
+ GetUniformBlockIndex = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLuint , const GLchar *)>(context->getProcAddress("glGetUniformBlockIndex"));
+ GetActiveUniformName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetActiveUniformName"));
+ GetActiveUniformsiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLuint *, GLenum , GLint *)>(context->getProcAddress("glGetActiveUniformsiv"));
+ GetUniformIndices = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLchar* const *, GLuint *)>(context->getProcAddress("glGetUniformIndices"));
+ PrimitiveRestartIndex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glPrimitiveRestartIndex"));
+ TexBuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glTexBuffer"));
+ DrawElementsInstanced = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const GLvoid *, GLsizei )>(context->getProcAddress("glDrawElementsInstanced"));
+ DrawArraysInstanced = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLsizei , GLsizei )>(context->getProcAddress("glDrawArraysInstanced"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_3_1_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(3, 1, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_3_2_CoreBackend::QOpenGLFunctions_3_2_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 3.2 core functions
+ SampleMaski = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLbitfield )>(context->getProcAddress("glSampleMaski"));
+ GetMultisamplefv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLfloat *)>(context->getProcAddress("glGetMultisamplefv"));
+ TexImage3DMultisample = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLint , GLsizei , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTexImage3DMultisample"));
+ TexImage2DMultisample = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLint , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTexImage2DMultisample"));
+ GetSynciv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsync , GLenum , GLsizei , GLsizei *, GLint *)>(context->getProcAddress("glGetSynciv"));
+ GetInteger64v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint64 *)>(context->getProcAddress("glGetInteger64v"));
+ WaitSync = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsync , GLbitfield , GLuint64 )>(context->getProcAddress("glWaitSync"));
+ ClientWaitSync = reinterpret_cast<GLenum (QOPENGLF_APIENTRYP)(GLsync , GLbitfield , GLuint64 )>(context->getProcAddress("glClientWaitSync"));
+ DeleteSync = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsync )>(context->getProcAddress("glDeleteSync"));
+ IsSync = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLsync )>(context->getProcAddress("glIsSync"));
+ FenceSync = reinterpret_cast<GLsync (QOPENGLF_APIENTRYP)(GLenum , GLbitfield )>(context->getProcAddress("glFenceSync"));
+ ProvokingVertex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glProvokingVertex"));
+ MultiDrawElementsBaseVertex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLsizei *, GLenum , const GLvoid* const *, GLsizei , const GLint *)>(context->getProcAddress("glMultiDrawElementsBaseVertex"));
+ DrawElementsInstancedBaseVertex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const GLvoid *, GLsizei , GLint )>(context->getProcAddress("glDrawElementsInstancedBaseVertex"));
+ DrawRangeElementsBaseVertex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLsizei , GLenum , const GLvoid *, GLint )>(context->getProcAddress("glDrawRangeElementsBaseVertex"));
+ DrawElementsBaseVertex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const GLvoid *, GLint )>(context->getProcAddress("glDrawElementsBaseVertex"));
+ FramebufferTexture = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLint )>(context->getProcAddress("glFramebufferTexture"));
+ GetBufferParameteri64v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint64 *)>(context->getProcAddress("glGetBufferParameteri64v"));
+ GetInteger64i_v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLint64 *)>(context->getProcAddress("glGetInteger64i_v"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_3_2_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(3, 2, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_3_3_CoreBackend::QOpenGLFunctions_3_3_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 3.3 core functions
+ VertexAttribP4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , const GLuint *)>(context->getProcAddress("glVertexAttribP4uiv"));
+ VertexAttribP4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , GLuint )>(context->getProcAddress("glVertexAttribP4ui"));
+ VertexAttribP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , const GLuint *)>(context->getProcAddress("glVertexAttribP3uiv"));
+ VertexAttribP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , GLuint )>(context->getProcAddress("glVertexAttribP3ui"));
+ VertexAttribP2uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , const GLuint *)>(context->getProcAddress("glVertexAttribP2uiv"));
+ VertexAttribP2ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , GLuint )>(context->getProcAddress("glVertexAttribP2ui"));
+ VertexAttribP1uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , const GLuint *)>(context->getProcAddress("glVertexAttribP1uiv"));
+ VertexAttribP1ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , GLuint )>(context->getProcAddress("glVertexAttribP1ui"));
+ SecondaryColorP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glSecondaryColorP3uiv"));
+ SecondaryColorP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glSecondaryColorP3ui"));
+ ColorP4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glColorP4uiv"));
+ ColorP4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glColorP4ui"));
+ ColorP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glColorP3uiv"));
+ ColorP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glColorP3ui"));
+ NormalP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glNormalP3uiv"));
+ NormalP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glNormalP3ui"));
+ MultiTexCoordP4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLuint *)>(context->getProcAddress("glMultiTexCoordP4uiv"));
+ MultiTexCoordP4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glMultiTexCoordP4ui"));
+ MultiTexCoordP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLuint *)>(context->getProcAddress("glMultiTexCoordP3uiv"));
+ MultiTexCoordP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glMultiTexCoordP3ui"));
+ MultiTexCoordP2uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLuint *)>(context->getProcAddress("glMultiTexCoordP2uiv"));
+ MultiTexCoordP2ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glMultiTexCoordP2ui"));
+ MultiTexCoordP1uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLuint *)>(context->getProcAddress("glMultiTexCoordP1uiv"));
+ MultiTexCoordP1ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glMultiTexCoordP1ui"));
+ TexCoordP4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glTexCoordP4uiv"));
+ TexCoordP4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glTexCoordP4ui"));
+ TexCoordP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glTexCoordP3uiv"));
+ TexCoordP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glTexCoordP3ui"));
+ TexCoordP2uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glTexCoordP2uiv"));
+ TexCoordP2ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glTexCoordP2ui"));
+ TexCoordP1uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glTexCoordP1uiv"));
+ TexCoordP1ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glTexCoordP1ui"));
+ VertexP4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glVertexP4uiv"));
+ VertexP4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glVertexP4ui"));
+ VertexP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glVertexP3uiv"));
+ VertexP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glVertexP3ui"));
+ VertexP2uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glVertexP2uiv"));
+ VertexP2ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glVertexP2ui"));
+ GetQueryObjectui64v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint64 *)>(context->getProcAddress("glGetQueryObjectui64v"));
+ GetQueryObjecti64v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint64 *)>(context->getProcAddress("glGetQueryObjecti64v"));
+ QueryCounter = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glQueryCounter"));
+ GetSamplerParameterIuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint *)>(context->getProcAddress("glGetSamplerParameterIuiv"));
+ GetSamplerParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetSamplerParameterfv"));
+ GetSamplerParameterIiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetSamplerParameterIiv"));
+ GetSamplerParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetSamplerParameteriv"));
+ SamplerParameterIuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLuint *)>(context->getProcAddress("glSamplerParameterIuiv"));
+ SamplerParameterIiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLint *)>(context->getProcAddress("glSamplerParameterIiv"));
+ SamplerParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLfloat *)>(context->getProcAddress("glSamplerParameterfv"));
+ SamplerParameterf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat )>(context->getProcAddress("glSamplerParameterf"));
+ SamplerParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLint *)>(context->getProcAddress("glSamplerParameteriv"));
+ SamplerParameteri = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint )>(context->getProcAddress("glSamplerParameteri"));
+ BindSampler = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glBindSampler"));
+ IsSampler = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsSampler"));
+ DeleteSamplers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteSamplers"));
+ GenSamplers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenSamplers"));
+ GetFragDataIndex = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , const GLchar *)>(context->getProcAddress("glGetFragDataIndex"));
+ BindFragDataLocationIndexed = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint , const GLchar *)>(context->getProcAddress("glBindFragDataLocationIndexed"));
+ VertexAttribDivisor = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glVertexAttribDivisor"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_3_3_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(3, 3, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_4_0_CoreBackend::QOpenGLFunctions_4_0_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 4.0 core functions
+ GetQueryIndexediv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum , GLint *)>(context->getProcAddress("glGetQueryIndexediv"));
+ EndQueryIndexed = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glEndQueryIndexed"));
+ BeginQueryIndexed = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint )>(context->getProcAddress("glBeginQueryIndexed"));
+ DrawTransformFeedbackStream = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint )>(context->getProcAddress("glDrawTransformFeedbackStream"));
+ DrawTransformFeedback = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glDrawTransformFeedback"));
+ ResumeTransformFeedback = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glResumeTransformFeedback"));
+ PauseTransformFeedback = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glPauseTransformFeedback"));
+ IsTransformFeedback = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsTransformFeedback"));
+ GenTransformFeedbacks = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenTransformFeedbacks"));
+ DeleteTransformFeedbacks = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteTransformFeedbacks"));
+ BindTransformFeedback = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindTransformFeedback"));
+ PatchParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glPatchParameterfv"));
+ PatchParameteri = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glPatchParameteri"));
+ GetProgramStageiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetProgramStageiv"));
+ GetUniformSubroutineuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLuint *)>(context->getProcAddress("glGetUniformSubroutineuiv"));
+ UniformSubroutinesuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLuint *)>(context->getProcAddress("glUniformSubroutinesuiv"));
+ GetActiveSubroutineName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetActiveSubroutineName"));
+ GetActiveSubroutineUniformName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetActiveSubroutineUniformName"));
+ GetActiveSubroutineUniformiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLenum , GLint *)>(context->getProcAddress("glGetActiveSubroutineUniformiv"));
+ GetSubroutineIndex = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLchar *)>(context->getProcAddress("glGetSubroutineIndex"));
+ GetSubroutineUniformLocation = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLchar *)>(context->getProcAddress("glGetSubroutineUniformLocation"));
+ GetUniformdv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble *)>(context->getProcAddress("glGetUniformdv"));
+ UniformMatrix4x3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix4x3dv"));
+ UniformMatrix4x2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix4x2dv"));
+ UniformMatrix3x4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix3x4dv"));
+ UniformMatrix3x2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix3x2dv"));
+ UniformMatrix2x4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix2x4dv"));
+ UniformMatrix2x3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix2x3dv"));
+ UniformMatrix4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix4dv"));
+ UniformMatrix3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix3dv"));
+ UniformMatrix2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix2dv"));
+ Uniform4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glUniform4dv"));
+ Uniform3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glUniform3dv"));
+ Uniform2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glUniform2dv"));
+ Uniform1dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glUniform1dv"));
+ Uniform4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glUniform4d"));
+ Uniform3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glUniform3d"));
+ Uniform2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLdouble , GLdouble )>(context->getProcAddress("glUniform2d"));
+ Uniform1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLdouble )>(context->getProcAddress("glUniform1d"));
+ DrawElementsIndirect = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glDrawElementsIndirect"));
+ DrawArraysIndirect = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLvoid *)>(context->getProcAddress("glDrawArraysIndirect"));
+ BlendFuncSeparatei = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLenum , GLenum )>(context->getProcAddress("glBlendFuncSeparatei"));
+ BlendFunci = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum )>(context->getProcAddress("glBlendFunci"));
+ BlendEquationSeparatei = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum )>(context->getProcAddress("glBlendEquationSeparatei"));
+ BlendEquationi = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glBlendEquationi"));
+ MinSampleShading = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glMinSampleShading"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_4_0_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(4, 0, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_4_1_CoreBackend::QOpenGLFunctions_4_1_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 4.1 core functions
+ GetDoublei_v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLdouble *)>(context->getProcAddress("glGetDoublei_v"));
+ GetFloati_v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLfloat *)>(context->getProcAddress("glGetFloati_v"));
+ DepthRangeIndexed = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble )>(context->getProcAddress("glDepthRangeIndexed"));
+ DepthRangeArrayv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLdouble *)>(context->getProcAddress("glDepthRangeArrayv"));
+ ScissorIndexedv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glScissorIndexedv"));
+ ScissorIndexed = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glScissorIndexed"));
+ ScissorArrayv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLint *)>(context->getProcAddress("glScissorArrayv"));
+ ViewportIndexedfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glViewportIndexedfv"));
+ ViewportIndexedf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glViewportIndexedf"));
+ ViewportArrayv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLfloat *)>(context->getProcAddress("glViewportArrayv"));
+ GetVertexAttribLdv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLdouble *)>(context->getProcAddress("glGetVertexAttribLdv"));
+ VertexAttribLPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glVertexAttribLPointer"));
+ VertexAttribL4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttribL4dv"));
+ VertexAttribL3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttribL3dv"));
+ VertexAttribL2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttribL2dv"));
+ VertexAttribL1dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttribL1dv"));
+ VertexAttribL4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttribL4d"));
+ VertexAttribL3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttribL3d"));
+ VertexAttribL2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttribL2d"));
+ VertexAttribL1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble )>(context->getProcAddress("glVertexAttribL1d"));
+ GetProgramPipelineInfoLog = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetProgramPipelineInfoLog"));
+ ValidateProgramPipeline = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glValidateProgramPipeline"));
+ ProgramUniformMatrix4x3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix4x3dv"));
+ ProgramUniformMatrix3x4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix3x4dv"));
+ ProgramUniformMatrix4x2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix4x2dv"));
+ ProgramUniformMatrix2x4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix2x4dv"));
+ ProgramUniformMatrix3x2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix3x2dv"));
+ ProgramUniformMatrix2x3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix2x3dv"));
+ ProgramUniformMatrix4x3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix4x3fv"));
+ ProgramUniformMatrix3x4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix3x4fv"));
+ ProgramUniformMatrix4x2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix4x2fv"));
+ ProgramUniformMatrix2x4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix2x4fv"));
+ ProgramUniformMatrix3x2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix3x2fv"));
+ ProgramUniformMatrix2x3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix2x3fv"));
+ ProgramUniformMatrix4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix4dv"));
+ ProgramUniformMatrix3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix3dv"));
+ ProgramUniformMatrix2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix2dv"));
+ ProgramUniformMatrix4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix4fv"));
+ ProgramUniformMatrix3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix3fv"));
+ ProgramUniformMatrix2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix2fv"));
+ ProgramUniform4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramUniform4uiv"));
+ ProgramUniform4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glProgramUniform4ui"));
+ ProgramUniform4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramUniform4dv"));
+ ProgramUniform4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glProgramUniform4d"));
+ ProgramUniform4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramUniform4fv"));
+ ProgramUniform4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glProgramUniform4f"));
+ ProgramUniform4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint *)>(context->getProcAddress("glProgramUniform4iv"));
+ ProgramUniform4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glProgramUniform4i"));
+ ProgramUniform3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramUniform3uiv"));
+ ProgramUniform3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint , GLuint , GLuint )>(context->getProcAddress("glProgramUniform3ui"));
+ ProgramUniform3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramUniform3dv"));
+ ProgramUniform3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glProgramUniform3d"));
+ ProgramUniform3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramUniform3fv"));
+ ProgramUniform3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glProgramUniform3f"));
+ ProgramUniform3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint *)>(context->getProcAddress("glProgramUniform3iv"));
+ ProgramUniform3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glProgramUniform3i"));
+ ProgramUniform2uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramUniform2uiv"));
+ ProgramUniform2ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint , GLuint )>(context->getProcAddress("glProgramUniform2ui"));
+ ProgramUniform2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramUniform2dv"));
+ ProgramUniform2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble , GLdouble )>(context->getProcAddress("glProgramUniform2d"));
+ ProgramUniform2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramUniform2fv"));
+ ProgramUniform2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat , GLfloat )>(context->getProcAddress("glProgramUniform2f"));
+ ProgramUniform2iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint *)>(context->getProcAddress("glProgramUniform2iv"));
+ ProgramUniform2i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint )>(context->getProcAddress("glProgramUniform2i"));
+ ProgramUniform1uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramUniform1uiv"));
+ ProgramUniform1ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint )>(context->getProcAddress("glProgramUniform1ui"));
+ ProgramUniform1dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramUniform1dv"));
+ ProgramUniform1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble )>(context->getProcAddress("glProgramUniform1d"));
+ ProgramUniform1fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramUniform1fv"));
+ ProgramUniform1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat )>(context->getProcAddress("glProgramUniform1f"));
+ ProgramUniform1iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint *)>(context->getProcAddress("glProgramUniform1iv"));
+ ProgramUniform1i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint )>(context->getProcAddress("glProgramUniform1i"));
+ GetProgramPipelineiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetProgramPipelineiv"));
+ IsProgramPipeline = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsProgramPipeline"));
+ GenProgramPipelines = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenProgramPipelines"));
+ DeleteProgramPipelines = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteProgramPipelines"));
+ BindProgramPipeline = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glBindProgramPipeline"));
+ CreateShaderProgramv = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLchar* const *)>(context->getProcAddress("glCreateShaderProgramv"));
+ ActiveShaderProgram = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glActiveShaderProgram"));
+ UseProgramStages = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLbitfield , GLuint )>(context->getProcAddress("glUseProgramStages"));
+ ProgramParameteri = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint )>(context->getProcAddress("glProgramParameteri"));
+ ProgramBinary = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLvoid *, GLsizei )>(context->getProcAddress("glProgramBinary"));
+ GetProgramBinary = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei *, GLenum *, GLvoid *)>(context->getProcAddress("glGetProgramBinary"));
+ ClearDepthf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glClearDepthf"));
+ DepthRangef = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glDepthRangef"));
+ GetShaderPrecisionFormat = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *, GLint *)>(context->getProcAddress("glGetShaderPrecisionFormat"));
+ ShaderBinary = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *, GLenum , const GLvoid *, GLsizei )>(context->getProcAddress("glShaderBinary"));
+ ReleaseShaderCompiler = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glReleaseShaderCompiler"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_4_1_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(4, 1, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_4_2_CoreBackend::QOpenGLFunctions_4_2_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 4.2 core functions
+ TexStorage3D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei , GLsizei , GLsizei )>(context->getProcAddress("glTexStorage3D"));
+ TexStorage2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glTexStorage2D"));
+ TexStorage1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei )>(context->getProcAddress("glTexStorage1D"));
+ MemoryBarrier = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(context->getProcAddress("glMemoryBarrier"));
+ BindImageTexture = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLint , GLboolean , GLint , GLenum , GLenum )>(context->getProcAddress("glBindImageTexture"));
+ GetActiveAtomicCounterBufferiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , GLint *)>(context->getProcAddress("glGetActiveAtomicCounterBufferiv"));
+ GetInternalformativ = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLsizei , GLint *)>(context->getProcAddress("glGetInternalformativ"));
+ DrawTransformFeedbackStreamInstanced = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLsizei )>(context->getProcAddress("glDrawTransformFeedbackStreamInstanced"));
+ DrawTransformFeedbackInstanced = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei )>(context->getProcAddress("glDrawTransformFeedbackInstanced"));
+ DrawElementsInstancedBaseVertexBaseInstance = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const void *, GLsizei , GLint , GLuint )>(context->getProcAddress("glDrawElementsInstancedBaseVertexBaseInstance"));
+ DrawElementsInstancedBaseInstance = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const void *, GLsizei , GLuint )>(context->getProcAddress("glDrawElementsInstancedBaseInstance"));
+ DrawArraysInstancedBaseInstance = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLsizei , GLsizei , GLuint )>(context->getProcAddress("glDrawArraysInstancedBaseInstance"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_4_2_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(4, 2, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_4_3_CoreBackend::QOpenGLFunctions_4_3_CoreBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 4.3 core functions
+ TexStorage3DMultisample = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTexStorage3DMultisample"));
+ TexStorage2DMultisample = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTexStorage2DMultisample"));
+ TexBufferRange = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLintptr , GLsizeiptr )>(context->getProcAddress("glTexBufferRange"));
+ ShaderStorageBlockBinding = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glShaderStorageBlockBinding"));
+ GetProgramResourceLocationIndex = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLchar *)>(context->getProcAddress("glGetProgramResourceLocationIndex"));
+ GetProgramResourceLocation = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLchar *)>(context->getProcAddress("glGetProgramResourceLocation"));
+ GetProgramResourceiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLsizei , const GLenum *, GLsizei , GLsizei *, GLint *)>(context->getProcAddress("glGetProgramResourceiv"));
+ GetProgramResourceName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetProgramResourceName"));
+ GetProgramResourceIndex = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLchar *)>(context->getProcAddress("glGetProgramResourceIndex"));
+ GetProgramInterfaceiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetProgramInterfaceiv"));
+ MultiDrawElementsIndirect = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const void *, GLsizei , GLsizei )>(context->getProcAddress("glMultiDrawElementsIndirect"));
+ MultiDrawArraysIndirect = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const void *, GLsizei , GLsizei )>(context->getProcAddress("glMultiDrawArraysIndirect"));
+ InvalidateSubFramebuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLenum *, GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glInvalidateSubFramebuffer"));
+ InvalidateFramebuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLenum *)>(context->getProcAddress("glInvalidateFramebuffer"));
+ InvalidateBufferData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glInvalidateBufferData"));
+ InvalidateBufferSubData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLintptr , GLsizeiptr )>(context->getProcAddress("glInvalidateBufferSubData"));
+ InvalidateTexImage = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint )>(context->getProcAddress("glInvalidateTexImage"));
+ InvalidateTexSubImage = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei )>(context->getProcAddress("glInvalidateTexSubImage"));
+ GetInternalformati64v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLsizei , GLint64 *)>(context->getProcAddress("glGetInternalformati64v"));
+ GetFramebufferParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetFramebufferParameteriv"));
+ FramebufferParameteri = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glFramebufferParameteri"));
+ VertexBindingDivisor = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glVertexBindingDivisor"));
+ VertexAttribBinding = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glVertexAttribBinding"));
+ VertexAttribLFormat = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLuint )>(context->getProcAddress("glVertexAttribLFormat"));
+ VertexAttribIFormat = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLuint )>(context->getProcAddress("glVertexAttribIFormat"));
+ VertexAttribFormat = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLboolean , GLuint )>(context->getProcAddress("glVertexAttribFormat"));
+ BindVertexBuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLintptr , GLsizei )>(context->getProcAddress("glBindVertexBuffer"));
+ TextureView = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLenum , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glTextureView"));
+ CopyImageSubData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLint , GLint , GLint , GLuint , GLenum , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei )>(context->getProcAddress("glCopyImageSubData"));
+ DispatchComputeIndirect = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLintptr )>(context->getProcAddress("glDispatchComputeIndirect"));
+ DispatchCompute = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glDispatchCompute"));
+ ClearBufferSubData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLintptr , GLsizeiptr , GLenum , GLenum , const void *)>(context->getProcAddress("glClearBufferSubData"));
+ ClearBufferData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLenum , const void *)>(context->getProcAddress("glClearBufferData"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_4_3_CoreBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(4, 3, QOpenGLVersionStatus::CoreStatus);
+}
+
+QOpenGLFunctions_1_0_DeprecatedBackend::QOpenGLFunctions_1_0_DeprecatedBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 1.0 deprecated functions
+#if defined(Q_OS_WIN)
+ HMODULE handle = GetModuleHandleA("opengl32.dll");
+ Translatef = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glTranslatef"));
+ Translated = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glTranslated"));
+ Scalef = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glScalef"));
+ Scaled = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glScaled"));
+ Rotatef = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glRotatef"));
+ Rotated = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glRotated"));
+ PushMatrix = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(GetProcAddress(handle, "glPushMatrix"));
+ PopMatrix = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(GetProcAddress(handle, "glPopMatrix"));
+ Ortho = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glOrtho"));
+ MultMatrixd = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glMultMatrixd"));
+ MultMatrixf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glMultMatrixf"));
+ MatrixMode = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glMatrixMode"));
+ LoadMatrixd = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glLoadMatrixd"));
+ LoadMatrixf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glLoadMatrixf"));
+ LoadIdentity = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(GetProcAddress(handle, "glLoadIdentity"));
+ Frustum = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glFrustum"));
+ IsList = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(GetProcAddress(handle, "glIsList"));
+ GetTexGeniv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(GetProcAddress(handle, "glGetTexGeniv"));
+ GetTexGenfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(GetProcAddress(handle, "glGetTexGenfv"));
+ GetTexGendv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLdouble *)>(GetProcAddress(handle, "glGetTexGendv"));
+ GetTexEnviv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(GetProcAddress(handle, "glGetTexEnviv"));
+ GetTexEnvfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(GetProcAddress(handle, "glGetTexEnvfv"));
+ GetPolygonStipple = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte *)>(GetProcAddress(handle, "glGetPolygonStipple"));
+ GetPixelMapusv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLushort *)>(GetProcAddress(handle, "glGetPixelMapusv"));
+ GetPixelMapuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint *)>(GetProcAddress(handle, "glGetPixelMapuiv"));
+ GetPixelMapfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat *)>(GetProcAddress(handle, "glGetPixelMapfv"));
+ GetMaterialiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(GetProcAddress(handle, "glGetMaterialiv"));
+ GetMaterialfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(GetProcAddress(handle, "glGetMaterialfv"));
+ GetMapiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(GetProcAddress(handle, "glGetMapiv"));
+ GetMapfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(GetProcAddress(handle, "glGetMapfv"));
+ GetMapdv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLdouble *)>(GetProcAddress(handle, "glGetMapdv"));
+ GetLightiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(GetProcAddress(handle, "glGetLightiv"));
+ GetLightfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(GetProcAddress(handle, "glGetLightfv"));
+ GetClipPlane = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble *)>(GetProcAddress(handle, "glGetClipPlane"));
+ DrawPixels = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(GetProcAddress(handle, "glDrawPixels"));
+ CopyPixels = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLsizei , GLsizei , GLenum )>(GetProcAddress(handle, "glCopyPixels"));
+ PixelMapusv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLushort *)>(GetProcAddress(handle, "glPixelMapusv"));
+ PixelMapuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLuint *)>(GetProcAddress(handle, "glPixelMapuiv"));
+ PixelMapfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLfloat *)>(GetProcAddress(handle, "glPixelMapfv"));
+ PixelTransferi = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(GetProcAddress(handle, "glPixelTransferi"));
+ PixelTransferf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(GetProcAddress(handle, "glPixelTransferf"));
+ PixelZoom = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(GetProcAddress(handle, "glPixelZoom"));
+ AlphaFunc = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(GetProcAddress(handle, "glAlphaFunc"));
+ EvalPoint2 = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(GetProcAddress(handle, "glEvalPoint2"));
+ EvalMesh2 = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint )>(GetProcAddress(handle, "glEvalMesh2"));
+ EvalPoint1 = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(GetProcAddress(handle, "glEvalPoint1"));
+ EvalMesh1 = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint )>(GetProcAddress(handle, "glEvalMesh1"));
+ EvalCoord2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glEvalCoord2fv"));
+ EvalCoord2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(GetProcAddress(handle, "glEvalCoord2f"));
+ EvalCoord2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glEvalCoord2dv"));
+ EvalCoord2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(GetProcAddress(handle, "glEvalCoord2d"));
+ EvalCoord1fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glEvalCoord1fv"));
+ EvalCoord1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(GetProcAddress(handle, "glEvalCoord1f"));
+ EvalCoord1dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glEvalCoord1dv"));
+ EvalCoord1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble )>(GetProcAddress(handle, "glEvalCoord1d"));
+ MapGrid2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLfloat , GLfloat , GLint , GLfloat , GLfloat )>(GetProcAddress(handle, "glMapGrid2f"));
+ MapGrid2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLdouble , GLdouble , GLint , GLdouble , GLdouble )>(GetProcAddress(handle, "glMapGrid2d"));
+ MapGrid1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLfloat , GLfloat )>(GetProcAddress(handle, "glMapGrid1f"));
+ MapGrid1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLdouble , GLdouble )>(GetProcAddress(handle, "glMapGrid1d"));
+ Map2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLint , GLint , GLfloat , GLfloat , GLint , GLint , const GLfloat *)>(GetProcAddress(handle, "glMap2f"));
+ Map2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLint , GLint , GLdouble , GLdouble , GLint , GLint , const GLdouble *)>(GetProcAddress(handle, "glMap2d"));
+ Map1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLint , GLint , const GLfloat *)>(GetProcAddress(handle, "glMap1f"));
+ Map1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLint , GLint , const GLdouble *)>(GetProcAddress(handle, "glMap1d"));
+ PushAttrib = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(GetProcAddress(handle, "glPushAttrib"));
+ PopAttrib = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(GetProcAddress(handle, "glPopAttrib"));
+ Accum = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(GetProcAddress(handle, "glAccum"));
+ IndexMask = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(GetProcAddress(handle, "glIndexMask"));
+ ClearIndex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(GetProcAddress(handle, "glClearIndex"));
+ ClearAccum = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glClearAccum"));
+ PushName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(GetProcAddress(handle, "glPushName"));
+ PopName = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(GetProcAddress(handle, "glPopName"));
+ PassThrough = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(GetProcAddress(handle, "glPassThrough"));
+ LoadName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(GetProcAddress(handle, "glLoadName"));
+ InitNames = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(GetProcAddress(handle, "glInitNames"));
+ RenderMode = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glRenderMode"));
+ SelectBuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(GetProcAddress(handle, "glSelectBuffer"));
+ FeedbackBuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLenum , GLfloat *)>(GetProcAddress(handle, "glFeedbackBuffer"));
+ TexGeniv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(GetProcAddress(handle, "glTexGeniv"));
+ TexGeni = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(GetProcAddress(handle, "glTexGeni"));
+ TexGenfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(GetProcAddress(handle, "glTexGenfv"));
+ TexGenf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(GetProcAddress(handle, "glTexGenf"));
+ TexGendv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLdouble *)>(GetProcAddress(handle, "glTexGendv"));
+ TexGend = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLdouble )>(GetProcAddress(handle, "glTexGend"));
+ TexEnviv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(GetProcAddress(handle, "glTexEnviv"));
+ TexEnvi = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(GetProcAddress(handle, "glTexEnvi"));
+ TexEnvfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(GetProcAddress(handle, "glTexEnvfv"));
+ TexEnvf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(GetProcAddress(handle, "glTexEnvf"));
+ ShadeModel = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glShadeModel"));
+ PolygonStipple = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *)>(GetProcAddress(handle, "glPolygonStipple"));
+ Materialiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(GetProcAddress(handle, "glMaterialiv"));
+ Materiali = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(GetProcAddress(handle, "glMateriali"));
+ Materialfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(GetProcAddress(handle, "glMaterialfv"));
+ Materialf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(GetProcAddress(handle, "glMaterialf"));
+ LineStipple = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLushort )>(GetProcAddress(handle, "glLineStipple"));
+ LightModeliv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(GetProcAddress(handle, "glLightModeliv"));
+ LightModeli = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(GetProcAddress(handle, "glLightModeli"));
+ LightModelfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(GetProcAddress(handle, "glLightModelfv"));
+ LightModelf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(GetProcAddress(handle, "glLightModelf"));
+ Lightiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(GetProcAddress(handle, "glLightiv"));
+ Lighti = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(GetProcAddress(handle, "glLighti"));
+ Lightfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(GetProcAddress(handle, "glLightfv"));
+ Lightf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(GetProcAddress(handle, "glLightf"));
+ Fogiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(GetProcAddress(handle, "glFogiv"));
+ Fogi = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(GetProcAddress(handle, "glFogi"));
+ Fogfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(GetProcAddress(handle, "glFogfv"));
+ Fogf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(GetProcAddress(handle, "glFogf"));
+ ColorMaterial = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(GetProcAddress(handle, "glColorMaterial"));
+ ClipPlane = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(GetProcAddress(handle, "glClipPlane"));
+ Vertex4sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glVertex4sv"));
+ Vertex4s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort , GLshort )>(GetProcAddress(handle, "glVertex4s"));
+ Vertex4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glVertex4iv"));
+ Vertex4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(GetProcAddress(handle, "glVertex4i"));
+ Vertex4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glVertex4fv"));
+ Vertex4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glVertex4f"));
+ Vertex4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glVertex4dv"));
+ Vertex4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glVertex4d"));
+ Vertex3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glVertex3sv"));
+ Vertex3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(GetProcAddress(handle, "glVertex3s"));
+ Vertex3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glVertex3iv"));
+ Vertex3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(GetProcAddress(handle, "glVertex3i"));
+ Vertex3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glVertex3fv"));
+ Vertex3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glVertex3f"));
+ Vertex3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glVertex3dv"));
+ Vertex3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glVertex3d"));
+ Vertex2sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glVertex2sv"));
+ Vertex2s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort )>(GetProcAddress(handle, "glVertex2s"));
+ Vertex2iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glVertex2iv"));
+ Vertex2i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(GetProcAddress(handle, "glVertex2i"));
+ Vertex2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glVertex2fv"));
+ Vertex2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(GetProcAddress(handle, "glVertex2f"));
+ Vertex2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glVertex2dv"));
+ Vertex2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(GetProcAddress(handle, "glVertex2d"));
+ TexCoord4sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glTexCoord4sv"));
+ TexCoord4s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort , GLshort )>(GetProcAddress(handle, "glTexCoord4s"));
+ TexCoord4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glTexCoord4iv"));
+ TexCoord4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(GetProcAddress(handle, "glTexCoord4i"));
+ TexCoord4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glTexCoord4fv"));
+ TexCoord4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glTexCoord4f"));
+ TexCoord4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glTexCoord4dv"));
+ TexCoord4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glTexCoord4d"));
+ TexCoord3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glTexCoord3sv"));
+ TexCoord3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(GetProcAddress(handle, "glTexCoord3s"));
+ TexCoord3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glTexCoord3iv"));
+ TexCoord3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(GetProcAddress(handle, "glTexCoord3i"));
+ TexCoord3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glTexCoord3fv"));
+ TexCoord3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glTexCoord3f"));
+ TexCoord3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glTexCoord3dv"));
+ TexCoord3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glTexCoord3d"));
+ TexCoord2sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glTexCoord2sv"));
+ TexCoord2s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort )>(GetProcAddress(handle, "glTexCoord2s"));
+ TexCoord2iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glTexCoord2iv"));
+ TexCoord2i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(GetProcAddress(handle, "glTexCoord2i"));
+ TexCoord2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glTexCoord2fv"));
+ TexCoord2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(GetProcAddress(handle, "glTexCoord2f"));
+ TexCoord2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glTexCoord2dv"));
+ TexCoord2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(GetProcAddress(handle, "glTexCoord2d"));
+ TexCoord1sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glTexCoord1sv"));
+ TexCoord1s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort )>(GetProcAddress(handle, "glTexCoord1s"));
+ TexCoord1iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glTexCoord1iv"));
+ TexCoord1i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(GetProcAddress(handle, "glTexCoord1i"));
+ TexCoord1fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glTexCoord1fv"));
+ TexCoord1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(GetProcAddress(handle, "glTexCoord1f"));
+ TexCoord1dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glTexCoord1dv"));
+ TexCoord1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble )>(GetProcAddress(handle, "glTexCoord1d"));
+ Rectsv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *, const GLshort *)>(GetProcAddress(handle, "glRectsv"));
+ Rects = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort , GLshort )>(GetProcAddress(handle, "glRects"));
+ Rectiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *, const GLint *)>(GetProcAddress(handle, "glRectiv"));
+ Recti = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(GetProcAddress(handle, "glRecti"));
+ Rectfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *, const GLfloat *)>(GetProcAddress(handle, "glRectfv"));
+ Rectf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glRectf"));
+ Rectdv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *, const GLdouble *)>(GetProcAddress(handle, "glRectdv"));
+ Rectd = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glRectd"));
+ RasterPos4sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glRasterPos4sv"));
+ RasterPos4s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort , GLshort )>(GetProcAddress(handle, "glRasterPos4s"));
+ RasterPos4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glRasterPos4iv"));
+ RasterPos4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(GetProcAddress(handle, "glRasterPos4i"));
+ RasterPos4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glRasterPos4fv"));
+ RasterPos4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glRasterPos4f"));
+ RasterPos4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glRasterPos4dv"));
+ RasterPos4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glRasterPos4d"));
+ RasterPos3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glRasterPos3sv"));
+ RasterPos3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(GetProcAddress(handle, "glRasterPos3s"));
+ RasterPos3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glRasterPos3iv"));
+ RasterPos3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(GetProcAddress(handle, "glRasterPos3i"));
+ RasterPos3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glRasterPos3fv"));
+ RasterPos3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glRasterPos3f"));
+ RasterPos3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glRasterPos3dv"));
+ RasterPos3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glRasterPos3d"));
+ RasterPos2sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glRasterPos2sv"));
+ RasterPos2s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort )>(GetProcAddress(handle, "glRasterPos2s"));
+ RasterPos2iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glRasterPos2iv"));
+ RasterPos2i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(GetProcAddress(handle, "glRasterPos2i"));
+ RasterPos2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glRasterPos2fv"));
+ RasterPos2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(GetProcAddress(handle, "glRasterPos2f"));
+ RasterPos2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glRasterPos2dv"));
+ RasterPos2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(GetProcAddress(handle, "glRasterPos2d"));
+ Normal3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glNormal3sv"));
+ Normal3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(GetProcAddress(handle, "glNormal3s"));
+ Normal3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glNormal3iv"));
+ Normal3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(GetProcAddress(handle, "glNormal3i"));
+ Normal3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glNormal3fv"));
+ Normal3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glNormal3f"));
+ Normal3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glNormal3dv"));
+ Normal3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glNormal3d"));
+ Normal3bv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLbyte *)>(GetProcAddress(handle, "glNormal3bv"));
+ Normal3b = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbyte , GLbyte , GLbyte )>(GetProcAddress(handle, "glNormal3b"));
+ Indexsv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glIndexsv"));
+ Indexs = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort )>(GetProcAddress(handle, "glIndexs"));
+ Indexiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glIndexiv"));
+ Indexi = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(GetProcAddress(handle, "glIndexi"));
+ Indexfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glIndexfv"));
+ Indexf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(GetProcAddress(handle, "glIndexf"));
+ Indexdv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glIndexdv"));
+ Indexd = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble )>(GetProcAddress(handle, "glIndexd"));
+ End = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(GetProcAddress(handle, "glEnd"));
+ EdgeFlagv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLboolean *)>(GetProcAddress(handle, "glEdgeFlagv"));
+ EdgeFlag = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLboolean )>(GetProcAddress(handle, "glEdgeFlag"));
+ Color4usv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLushort *)>(GetProcAddress(handle, "glColor4usv"));
+ Color4us = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLushort , GLushort , GLushort , GLushort )>(GetProcAddress(handle, "glColor4us"));
+ Color4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *)>(GetProcAddress(handle, "glColor4uiv"));
+ Color4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint , GLuint )>(GetProcAddress(handle, "glColor4ui"));
+ Color4ubv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *)>(GetProcAddress(handle, "glColor4ubv"));
+ Color4ub = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte , GLubyte , GLubyte , GLubyte )>(GetProcAddress(handle, "glColor4ub"));
+ Color4sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glColor4sv"));
+ Color4s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort , GLshort )>(GetProcAddress(handle, "glColor4s"));
+ Color4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glColor4iv"));
+ Color4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(GetProcAddress(handle, "glColor4i"));
+ Color4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glColor4fv"));
+ Color4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glColor4f"));
+ Color4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glColor4dv"));
+ Color4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glColor4d"));
+ Color4bv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLbyte *)>(GetProcAddress(handle, "glColor4bv"));
+ Color4b = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbyte , GLbyte , GLbyte , GLbyte )>(GetProcAddress(handle, "glColor4b"));
+ Color3usv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLushort *)>(GetProcAddress(handle, "glColor3usv"));
+ Color3us = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLushort , GLushort , GLushort )>(GetProcAddress(handle, "glColor3us"));
+ Color3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *)>(GetProcAddress(handle, "glColor3uiv"));
+ Color3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(GetProcAddress(handle, "glColor3ui"));
+ Color3ubv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *)>(GetProcAddress(handle, "glColor3ubv"));
+ Color3ub = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte , GLubyte , GLubyte )>(GetProcAddress(handle, "glColor3ub"));
+ Color3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(GetProcAddress(handle, "glColor3sv"));
+ Color3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(GetProcAddress(handle, "glColor3s"));
+ Color3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(GetProcAddress(handle, "glColor3iv"));
+ Color3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(GetProcAddress(handle, "glColor3i"));
+ Color3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(GetProcAddress(handle, "glColor3fv"));
+ Color3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(GetProcAddress(handle, "glColor3f"));
+ Color3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(GetProcAddress(handle, "glColor3dv"));
+ Color3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(GetProcAddress(handle, "glColor3d"));
+ Color3bv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLbyte *)>(GetProcAddress(handle, "glColor3bv"));
+ Color3b = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbyte , GLbyte , GLbyte )>(GetProcAddress(handle, "glColor3b"));
+ Bitmap = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLsizei , GLfloat , GLfloat , GLfloat , GLfloat , const GLubyte *)>(GetProcAddress(handle, "glBitmap"));
+ Begin = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glBegin"));
+ ListBase = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(GetProcAddress(handle, "glListBase"));
+ GenLists = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLsizei )>(GetProcAddress(handle, "glGenLists"));
+ DeleteLists = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei )>(GetProcAddress(handle, "glDeleteLists"));
+ CallLists = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLenum , const GLvoid *)>(GetProcAddress(handle, "glCallLists"));
+ CallList = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(GetProcAddress(handle, "glCallList"));
+ EndList = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(GetProcAddress(handle, "glEndList"));
+ NewList = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(GetProcAddress(handle, "glNewList"));
+#else
+ Translatef = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glTranslatef"));
+ Translated = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glTranslated"));
+ Scalef = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glScalef"));
+ Scaled = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glScaled"));
+ Rotatef = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glRotatef"));
+ Rotated = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glRotated"));
+ PushMatrix = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glPushMatrix"));
+ PopMatrix = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glPopMatrix"));
+ Ortho = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glOrtho"));
+ MultMatrixd = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glMultMatrixd"));
+ MultMatrixf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glMultMatrixf"));
+ MatrixMode = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glMatrixMode"));
+ LoadMatrixd = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glLoadMatrixd"));
+ LoadMatrixf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glLoadMatrixf"));
+ LoadIdentity = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glLoadIdentity"));
+ Frustum = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glFrustum"));
+ IsList = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsList"));
+ GetTexGeniv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetTexGeniv"));
+ GetTexGenfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetTexGenfv"));
+ GetTexGendv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLdouble *)>(context->getProcAddress("glGetTexGendv"));
+ GetTexEnviv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetTexEnviv"));
+ GetTexEnvfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetTexEnvfv"));
+ GetPolygonStipple = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte *)>(context->getProcAddress("glGetPolygonStipple"));
+ GetPixelMapusv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLushort *)>(context->getProcAddress("glGetPixelMapusv"));
+ GetPixelMapuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint *)>(context->getProcAddress("glGetPixelMapuiv"));
+ GetPixelMapfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat *)>(context->getProcAddress("glGetPixelMapfv"));
+ GetMaterialiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetMaterialiv"));
+ GetMaterialfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetMaterialfv"));
+ GetMapiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetMapiv"));
+ GetMapfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetMapfv"));
+ GetMapdv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLdouble *)>(context->getProcAddress("glGetMapdv"));
+ GetLightiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetLightiv"));
+ GetLightfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetLightfv"));
+ GetClipPlane = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble *)>(context->getProcAddress("glGetClipPlane"));
+ DrawPixels = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glDrawPixels"));
+ CopyPixels = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLsizei , GLsizei , GLenum )>(context->getProcAddress("glCopyPixels"));
+ PixelMapusv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLushort *)>(context->getProcAddress("glPixelMapusv"));
+ PixelMapuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLuint *)>(context->getProcAddress("glPixelMapuiv"));
+ PixelMapfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLfloat *)>(context->getProcAddress("glPixelMapfv"));
+ PixelTransferi = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glPixelTransferi"));
+ PixelTransferf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glPixelTransferf"));
+ PixelZoom = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glPixelZoom"));
+ AlphaFunc = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glAlphaFunc"));
+ EvalPoint2 = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(context->getProcAddress("glEvalPoint2"));
+ EvalMesh2 = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint )>(context->getProcAddress("glEvalMesh2"));
+ EvalPoint1 = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(context->getProcAddress("glEvalPoint1"));
+ EvalMesh1 = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint )>(context->getProcAddress("glEvalMesh1"));
+ EvalCoord2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glEvalCoord2fv"));
+ EvalCoord2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glEvalCoord2f"));
+ EvalCoord2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glEvalCoord2dv"));
+ EvalCoord2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(context->getProcAddress("glEvalCoord2d"));
+ EvalCoord1fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glEvalCoord1fv"));
+ EvalCoord1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glEvalCoord1f"));
+ EvalCoord1dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glEvalCoord1dv"));
+ EvalCoord1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble )>(context->getProcAddress("glEvalCoord1d"));
+ MapGrid2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLfloat , GLfloat , GLint , GLfloat , GLfloat )>(context->getProcAddress("glMapGrid2f"));
+ MapGrid2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLdouble , GLdouble , GLint , GLdouble , GLdouble )>(context->getProcAddress("glMapGrid2d"));
+ MapGrid1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLfloat , GLfloat )>(context->getProcAddress("glMapGrid1f"));
+ MapGrid1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLdouble , GLdouble )>(context->getProcAddress("glMapGrid1d"));
+ Map2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLint , GLint , GLfloat , GLfloat , GLint , GLint , const GLfloat *)>(context->getProcAddress("glMap2f"));
+ Map2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLint , GLint , GLdouble , GLdouble , GLint , GLint , const GLdouble *)>(context->getProcAddress("glMap2d"));
+ Map1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLint , GLint , const GLfloat *)>(context->getProcAddress("glMap1f"));
+ Map1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLint , GLint , const GLdouble *)>(context->getProcAddress("glMap1d"));
+ PushAttrib = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(context->getProcAddress("glPushAttrib"));
+ PopAttrib = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glPopAttrib"));
+ Accum = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glAccum"));
+ IndexMask = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIndexMask"));
+ ClearIndex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glClearIndex"));
+ ClearAccum = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glClearAccum"));
+ PushName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glPushName"));
+ PopName = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glPopName"));
+ PassThrough = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glPassThrough"));
+ LoadName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glLoadName"));
+ InitNames = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glInitNames"));
+ RenderMode = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glRenderMode"));
+ SelectBuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glSelectBuffer"));
+ FeedbackBuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLenum , GLfloat *)>(context->getProcAddress("glFeedbackBuffer"));
+ TexGeniv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glTexGeniv"));
+ TexGeni = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glTexGeni"));
+ TexGenfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glTexGenfv"));
+ TexGenf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(context->getProcAddress("glTexGenf"));
+ TexGendv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLdouble *)>(context->getProcAddress("glTexGendv"));
+ TexGend = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLdouble )>(context->getProcAddress("glTexGend"));
+ TexEnviv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glTexEnviv"));
+ TexEnvi = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glTexEnvi"));
+ TexEnvfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glTexEnvfv"));
+ TexEnvf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(context->getProcAddress("glTexEnvf"));
+ ShadeModel = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glShadeModel"));
+ PolygonStipple = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *)>(context->getProcAddress("glPolygonStipple"));
+ Materialiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glMaterialiv"));
+ Materiali = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glMateriali"));
+ Materialfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glMaterialfv"));
+ Materialf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(context->getProcAddress("glMaterialf"));
+ LineStipple = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLushort )>(context->getProcAddress("glLineStipple"));
+ LightModeliv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glLightModeliv"));
+ LightModeli = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glLightModeli"));
+ LightModelfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glLightModelfv"));
+ LightModelf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glLightModelf"));
+ Lightiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glLightiv"));
+ Lighti = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glLighti"));
+ Lightfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glLightfv"));
+ Lightf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(context->getProcAddress("glLightf"));
+ Fogiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glFogiv"));
+ Fogi = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glFogi"));
+ Fogfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glFogfv"));
+ Fogf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glFogf"));
+ ColorMaterial = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glColorMaterial"));
+ ClipPlane = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glClipPlane"));
+ Vertex4sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glVertex4sv"));
+ Vertex4s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort , GLshort )>(context->getProcAddress("glVertex4s"));
+ Vertex4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glVertex4iv"));
+ Vertex4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(context->getProcAddress("glVertex4i"));
+ Vertex4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glVertex4fv"));
+ Vertex4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glVertex4f"));
+ Vertex4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glVertex4dv"));
+ Vertex4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertex4d"));
+ Vertex3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glVertex3sv"));
+ Vertex3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(context->getProcAddress("glVertex3s"));
+ Vertex3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glVertex3iv"));
+ Vertex3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glVertex3i"));
+ Vertex3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glVertex3fv"));
+ Vertex3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glVertex3f"));
+ Vertex3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glVertex3dv"));
+ Vertex3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertex3d"));
+ Vertex2sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glVertex2sv"));
+ Vertex2s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort )>(context->getProcAddress("glVertex2s"));
+ Vertex2iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glVertex2iv"));
+ Vertex2i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(context->getProcAddress("glVertex2i"));
+ Vertex2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glVertex2fv"));
+ Vertex2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glVertex2f"));
+ Vertex2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glVertex2dv"));
+ Vertex2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(context->getProcAddress("glVertex2d"));
+ TexCoord4sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glTexCoord4sv"));
+ TexCoord4s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort , GLshort )>(context->getProcAddress("glTexCoord4s"));
+ TexCoord4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glTexCoord4iv"));
+ TexCoord4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(context->getProcAddress("glTexCoord4i"));
+ TexCoord4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glTexCoord4fv"));
+ TexCoord4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glTexCoord4f"));
+ TexCoord4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glTexCoord4dv"));
+ TexCoord4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glTexCoord4d"));
+ TexCoord3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glTexCoord3sv"));
+ TexCoord3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(context->getProcAddress("glTexCoord3s"));
+ TexCoord3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glTexCoord3iv"));
+ TexCoord3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glTexCoord3i"));
+ TexCoord3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glTexCoord3fv"));
+ TexCoord3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glTexCoord3f"));
+ TexCoord3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glTexCoord3dv"));
+ TexCoord3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glTexCoord3d"));
+ TexCoord2sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glTexCoord2sv"));
+ TexCoord2s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort )>(context->getProcAddress("glTexCoord2s"));
+ TexCoord2iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glTexCoord2iv"));
+ TexCoord2i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(context->getProcAddress("glTexCoord2i"));
+ TexCoord2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glTexCoord2fv"));
+ TexCoord2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glTexCoord2f"));
+ TexCoord2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glTexCoord2dv"));
+ TexCoord2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(context->getProcAddress("glTexCoord2d"));
+ TexCoord1sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glTexCoord1sv"));
+ TexCoord1s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort )>(context->getProcAddress("glTexCoord1s"));
+ TexCoord1iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glTexCoord1iv"));
+ TexCoord1i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(context->getProcAddress("glTexCoord1i"));
+ TexCoord1fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glTexCoord1fv"));
+ TexCoord1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glTexCoord1f"));
+ TexCoord1dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glTexCoord1dv"));
+ TexCoord1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble )>(context->getProcAddress("glTexCoord1d"));
+ Rectsv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *, const GLshort *)>(context->getProcAddress("glRectsv"));
+ Rects = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort , GLshort )>(context->getProcAddress("glRects"));
+ Rectiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *, const GLint *)>(context->getProcAddress("glRectiv"));
+ Recti = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(context->getProcAddress("glRecti"));
+ Rectfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *, const GLfloat *)>(context->getProcAddress("glRectfv"));
+ Rectf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glRectf"));
+ Rectdv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *, const GLdouble *)>(context->getProcAddress("glRectdv"));
+ Rectd = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glRectd"));
+ RasterPos4sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glRasterPos4sv"));
+ RasterPos4s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort , GLshort )>(context->getProcAddress("glRasterPos4s"));
+ RasterPos4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glRasterPos4iv"));
+ RasterPos4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(context->getProcAddress("glRasterPos4i"));
+ RasterPos4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glRasterPos4fv"));
+ RasterPos4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glRasterPos4f"));
+ RasterPos4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glRasterPos4dv"));
+ RasterPos4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glRasterPos4d"));
+ RasterPos3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glRasterPos3sv"));
+ RasterPos3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(context->getProcAddress("glRasterPos3s"));
+ RasterPos3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glRasterPos3iv"));
+ RasterPos3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glRasterPos3i"));
+ RasterPos3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glRasterPos3fv"));
+ RasterPos3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glRasterPos3f"));
+ RasterPos3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glRasterPos3dv"));
+ RasterPos3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glRasterPos3d"));
+ RasterPos2sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glRasterPos2sv"));
+ RasterPos2s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort )>(context->getProcAddress("glRasterPos2s"));
+ RasterPos2iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glRasterPos2iv"));
+ RasterPos2i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(context->getProcAddress("glRasterPos2i"));
+ RasterPos2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glRasterPos2fv"));
+ RasterPos2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glRasterPos2f"));
+ RasterPos2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glRasterPos2dv"));
+ RasterPos2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(context->getProcAddress("glRasterPos2d"));
+ Normal3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glNormal3sv"));
+ Normal3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(context->getProcAddress("glNormal3s"));
+ Normal3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glNormal3iv"));
+ Normal3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glNormal3i"));
+ Normal3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glNormal3fv"));
+ Normal3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glNormal3f"));
+ Normal3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glNormal3dv"));
+ Normal3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glNormal3d"));
+ Normal3bv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLbyte *)>(context->getProcAddress("glNormal3bv"));
+ Normal3b = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbyte , GLbyte , GLbyte )>(context->getProcAddress("glNormal3b"));
+ Indexsv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glIndexsv"));
+ Indexs = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort )>(context->getProcAddress("glIndexs"));
+ Indexiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glIndexiv"));
+ Indexi = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(context->getProcAddress("glIndexi"));
+ Indexfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glIndexfv"));
+ Indexf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glIndexf"));
+ Indexdv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glIndexdv"));
+ Indexd = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble )>(context->getProcAddress("glIndexd"));
+ End = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glEnd"));
+ EdgeFlagv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLboolean *)>(context->getProcAddress("glEdgeFlagv"));
+ EdgeFlag = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLboolean )>(context->getProcAddress("glEdgeFlag"));
+ Color4usv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLushort *)>(context->getProcAddress("glColor4usv"));
+ Color4us = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLushort , GLushort , GLushort , GLushort )>(context->getProcAddress("glColor4us"));
+ Color4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *)>(context->getProcAddress("glColor4uiv"));
+ Color4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glColor4ui"));
+ Color4ubv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *)>(context->getProcAddress("glColor4ubv"));
+ Color4ub = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte , GLubyte , GLubyte , GLubyte )>(context->getProcAddress("glColor4ub"));
+ Color4sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glColor4sv"));
+ Color4s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort , GLshort )>(context->getProcAddress("glColor4s"));
+ Color4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glColor4iv"));
+ Color4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(context->getProcAddress("glColor4i"));
+ Color4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glColor4fv"));
+ Color4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glColor4f"));
+ Color4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glColor4dv"));
+ Color4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glColor4d"));
+ Color4bv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLbyte *)>(context->getProcAddress("glColor4bv"));
+ Color4b = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbyte , GLbyte , GLbyte , GLbyte )>(context->getProcAddress("glColor4b"));
+ Color3usv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLushort *)>(context->getProcAddress("glColor3usv"));
+ Color3us = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLushort , GLushort , GLushort )>(context->getProcAddress("glColor3us"));
+ Color3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *)>(context->getProcAddress("glColor3uiv"));
+ Color3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glColor3ui"));
+ Color3ubv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *)>(context->getProcAddress("glColor3ubv"));
+ Color3ub = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte , GLubyte , GLubyte )>(context->getProcAddress("glColor3ub"));
+ Color3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glColor3sv"));
+ Color3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(context->getProcAddress("glColor3s"));
+ Color3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glColor3iv"));
+ Color3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glColor3i"));
+ Color3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glColor3fv"));
+ Color3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glColor3f"));
+ Color3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glColor3dv"));
+ Color3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glColor3d"));
+ Color3bv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLbyte *)>(context->getProcAddress("glColor3bv"));
+ Color3b = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbyte , GLbyte , GLbyte )>(context->getProcAddress("glColor3b"));
+ Bitmap = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLsizei , GLfloat , GLfloat , GLfloat , GLfloat , const GLubyte *)>(context->getProcAddress("glBitmap"));
+ Begin = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glBegin"));
+ ListBase = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glListBase"));
+ GenLists = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLsizei )>(context->getProcAddress("glGenLists"));
+ DeleteLists = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei )>(context->getProcAddress("glDeleteLists"));
+ CallLists = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLenum , const GLvoid *)>(context->getProcAddress("glCallLists"));
+ CallList = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glCallList"));
+ EndList = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glEndList"));
+ NewList = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glNewList"));
+#endif
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_1_0_DeprecatedBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(1, 0, QOpenGLVersionStatus::DeprecatedStatus);
+}
+
+QOpenGLFunctions_1_1_DeprecatedBackend::QOpenGLFunctions_1_1_DeprecatedBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 1.1 deprecated functions
+#if defined(Q_OS_WIN)
+ HMODULE handle = GetModuleHandleA("opengl32.dll");
+ PushClientAttrib = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(GetProcAddress(handle, "glPushClientAttrib"));
+ PopClientAttrib = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(GetProcAddress(handle, "glPopClientAttrib"));
+ PrioritizeTextures = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *, const GLfloat *)>(GetProcAddress(handle, "glPrioritizeTextures"));
+ AreTexturesResident = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *, GLboolean *)>(GetProcAddress(handle, "glAreTexturesResident"));
+ VertexPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , const GLvoid *)>(GetProcAddress(handle, "glVertexPointer"));
+ TexCoordPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , const GLvoid *)>(GetProcAddress(handle, "glTexCoordPointer"));
+ NormalPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid *)>(GetProcAddress(handle, "glNormalPointer"));
+ InterleavedArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid *)>(GetProcAddress(handle, "glInterleavedArrays"));
+ IndexPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid *)>(GetProcAddress(handle, "glIndexPointer"));
+ EnableClientState = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glEnableClientState"));
+ EdgeFlagPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLvoid *)>(GetProcAddress(handle, "glEdgeFlagPointer"));
+ DisableClientState = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(GetProcAddress(handle, "glDisableClientState"));
+ ColorPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , const GLvoid *)>(GetProcAddress(handle, "glColorPointer"));
+ ArrayElement = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(GetProcAddress(handle, "glArrayElement"));
+#else
+ PushClientAttrib = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(context->getProcAddress("glPushClientAttrib"));
+ PopClientAttrib = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glPopClientAttrib"));
+ PrioritizeTextures = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *, const GLfloat *)>(context->getProcAddress("glPrioritizeTextures"));
+ AreTexturesResident = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *, GLboolean *)>(context->getProcAddress("glAreTexturesResident"));
+ VertexPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glVertexPointer"));
+ TexCoordPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glTexCoordPointer"));
+ NormalPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glNormalPointer"));
+ InterleavedArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glInterleavedArrays"));
+ IndexPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glIndexPointer"));
+ EnableClientState = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glEnableClientState"));
+ EdgeFlagPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLvoid *)>(context->getProcAddress("glEdgeFlagPointer"));
+ DisableClientState = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glDisableClientState"));
+ ColorPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glColorPointer"));
+ ArrayElement = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(context->getProcAddress("glArrayElement"));
+#endif
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_1_1_DeprecatedBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(1, 1, QOpenGLVersionStatus::DeprecatedStatus);
+}
+
+QOpenGLFunctions_1_2_DeprecatedBackend::QOpenGLFunctions_1_2_DeprecatedBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 1.2 deprecated functions
+ ResetMinmax = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glResetMinmax"));
+ ResetHistogram = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glResetHistogram"));
+ Minmax = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLboolean )>(context->getProcAddress("glMinmax"));
+ Histogram = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLboolean )>(context->getProcAddress("glHistogram"));
+ GetMinmaxParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetMinmaxParameteriv"));
+ GetMinmaxParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetMinmaxParameterfv"));
+ GetMinmax = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLboolean , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetMinmax"));
+ GetHistogramParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetHistogramParameteriv"));
+ GetHistogramParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetHistogramParameterfv"));
+ GetHistogram = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLboolean , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetHistogram"));
+ SeparableFilter2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *, const GLvoid *)>(context->getProcAddress("glSeparableFilter2D"));
+ GetSeparableFilter = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLvoid *, GLvoid *, GLvoid *)>(context->getProcAddress("glGetSeparableFilter"));
+ GetConvolutionParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetConvolutionParameteriv"));
+ GetConvolutionParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetConvolutionParameterfv"));
+ GetConvolutionFilter = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetConvolutionFilter"));
+ CopyConvolutionFilter2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glCopyConvolutionFilter2D"));
+ CopyConvolutionFilter1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLsizei )>(context->getProcAddress("glCopyConvolutionFilter1D"));
+ ConvolutionParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glConvolutionParameteriv"));
+ ConvolutionParameteri = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glConvolutionParameteri"));
+ ConvolutionParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glConvolutionParameterfv"));
+ ConvolutionParameterf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(context->getProcAddress("glConvolutionParameterf"));
+ ConvolutionFilter2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glConvolutionFilter2D"));
+ ConvolutionFilter1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glConvolutionFilter1D"));
+ CopyColorSubTable = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLint , GLint , GLsizei )>(context->getProcAddress("glCopyColorSubTable"));
+ ColorSubTable = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glColorSubTable"));
+ GetColorTableParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetColorTableParameteriv"));
+ GetColorTableParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetColorTableParameterfv"));
+ GetColorTable = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetColorTable"));
+ CopyColorTable = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLsizei )>(context->getProcAddress("glCopyColorTable"));
+ ColorTableParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glColorTableParameteriv"));
+ ColorTableParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glColorTableParameterfv"));
+ ColorTable = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glColorTable"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_1_2_DeprecatedBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(1, 2, QOpenGLVersionStatus::DeprecatedStatus);
+}
+
+QOpenGLFunctions_1_3_DeprecatedBackend::QOpenGLFunctions_1_3_DeprecatedBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 1.3 deprecated functions
+ MultTransposeMatrixd = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glMultTransposeMatrixd"));
+ MultTransposeMatrixf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glMultTransposeMatrixf"));
+ LoadTransposeMatrixd = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glLoadTransposeMatrixd"));
+ LoadTransposeMatrixf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glLoadTransposeMatrixf"));
+ MultiTexCoord4sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glMultiTexCoord4sv"));
+ MultiTexCoord4s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort , GLshort , GLshort , GLshort )>(context->getProcAddress("glMultiTexCoord4s"));
+ MultiTexCoord4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glMultiTexCoord4iv"));
+ MultiTexCoord4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint )>(context->getProcAddress("glMultiTexCoord4i"));
+ MultiTexCoord4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glMultiTexCoord4fv"));
+ MultiTexCoord4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glMultiTexCoord4f"));
+ MultiTexCoord4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glMultiTexCoord4dv"));
+ MultiTexCoord4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glMultiTexCoord4d"));
+ MultiTexCoord3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glMultiTexCoord3sv"));
+ MultiTexCoord3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort , GLshort , GLshort )>(context->getProcAddress("glMultiTexCoord3s"));
+ MultiTexCoord3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glMultiTexCoord3iv"));
+ MultiTexCoord3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint )>(context->getProcAddress("glMultiTexCoord3i"));
+ MultiTexCoord3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glMultiTexCoord3fv"));
+ MultiTexCoord3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glMultiTexCoord3f"));
+ MultiTexCoord3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glMultiTexCoord3dv"));
+ MultiTexCoord3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glMultiTexCoord3d"));
+ MultiTexCoord2sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glMultiTexCoord2sv"));
+ MultiTexCoord2s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort , GLshort )>(context->getProcAddress("glMultiTexCoord2s"));
+ MultiTexCoord2iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glMultiTexCoord2iv"));
+ MultiTexCoord2i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint )>(context->getProcAddress("glMultiTexCoord2i"));
+ MultiTexCoord2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glMultiTexCoord2fv"));
+ MultiTexCoord2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat )>(context->getProcAddress("glMultiTexCoord2f"));
+ MultiTexCoord2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glMultiTexCoord2dv"));
+ MultiTexCoord2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble )>(context->getProcAddress("glMultiTexCoord2d"));
+ MultiTexCoord1sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glMultiTexCoord1sv"));
+ MultiTexCoord1s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort )>(context->getProcAddress("glMultiTexCoord1s"));
+ MultiTexCoord1iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glMultiTexCoord1iv"));
+ MultiTexCoord1i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glMultiTexCoord1i"));
+ MultiTexCoord1fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glMultiTexCoord1fv"));
+ MultiTexCoord1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glMultiTexCoord1f"));
+ MultiTexCoord1dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glMultiTexCoord1dv"));
+ MultiTexCoord1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble )>(context->getProcAddress("glMultiTexCoord1d"));
+ ClientActiveTexture = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glClientActiveTexture"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_1_3_DeprecatedBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(1, 3, QOpenGLVersionStatus::DeprecatedStatus);
+}
+
+QOpenGLFunctions_1_4_DeprecatedBackend::QOpenGLFunctions_1_4_DeprecatedBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 1.4 deprecated functions
+ WindowPos3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glWindowPos3sv"));
+ WindowPos3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(context->getProcAddress("glWindowPos3s"));
+ WindowPos3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glWindowPos3iv"));
+ WindowPos3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glWindowPos3i"));
+ WindowPos3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glWindowPos3fv"));
+ WindowPos3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glWindowPos3f"));
+ WindowPos3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glWindowPos3dv"));
+ WindowPos3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glWindowPos3d"));
+ WindowPos2sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glWindowPos2sv"));
+ WindowPos2s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort )>(context->getProcAddress("glWindowPos2s"));
+ WindowPos2iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glWindowPos2iv"));
+ WindowPos2i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(context->getProcAddress("glWindowPos2i"));
+ WindowPos2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glWindowPos2fv"));
+ WindowPos2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glWindowPos2f"));
+ WindowPos2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glWindowPos2dv"));
+ WindowPos2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(context->getProcAddress("glWindowPos2d"));
+ SecondaryColorPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glSecondaryColorPointer"));
+ SecondaryColor3usv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLushort *)>(context->getProcAddress("glSecondaryColor3usv"));
+ SecondaryColor3us = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLushort , GLushort , GLushort )>(context->getProcAddress("glSecondaryColor3us"));
+ SecondaryColor3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *)>(context->getProcAddress("glSecondaryColor3uiv"));
+ SecondaryColor3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glSecondaryColor3ui"));
+ SecondaryColor3ubv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *)>(context->getProcAddress("glSecondaryColor3ubv"));
+ SecondaryColor3ub = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte , GLubyte , GLubyte )>(context->getProcAddress("glSecondaryColor3ub"));
+ SecondaryColor3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glSecondaryColor3sv"));
+ SecondaryColor3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(context->getProcAddress("glSecondaryColor3s"));
+ SecondaryColor3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glSecondaryColor3iv"));
+ SecondaryColor3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glSecondaryColor3i"));
+ SecondaryColor3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glSecondaryColor3fv"));
+ SecondaryColor3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glSecondaryColor3f"));
+ SecondaryColor3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glSecondaryColor3dv"));
+ SecondaryColor3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glSecondaryColor3d"));
+ SecondaryColor3bv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLbyte *)>(context->getProcAddress("glSecondaryColor3bv"));
+ SecondaryColor3b = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbyte , GLbyte , GLbyte )>(context->getProcAddress("glSecondaryColor3b"));
+ FogCoordPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glFogCoordPointer"));
+ FogCoorddv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glFogCoorddv"));
+ FogCoordd = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble )>(context->getProcAddress("glFogCoordd"));
+ FogCoordfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glFogCoordfv"));
+ FogCoordf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glFogCoordf"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_1_4_DeprecatedBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(1, 4, QOpenGLVersionStatus::DeprecatedStatus);
+}
+
+QOpenGLFunctions_2_0_DeprecatedBackend::QOpenGLFunctions_2_0_DeprecatedBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 2.0 deprecated functions
+ VertexAttrib4usv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLushort *)>(context->getProcAddress("glVertexAttrib4usv"));
+ VertexAttrib4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVertexAttrib4uiv"));
+ VertexAttrib4ubv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLubyte *)>(context->getProcAddress("glVertexAttrib4ubv"));
+ VertexAttrib4sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib4sv"));
+ VertexAttrib4s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLshort , GLshort , GLshort , GLshort )>(context->getProcAddress("glVertexAttrib4s"));
+ VertexAttrib4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVertexAttrib4iv"));
+ VertexAttrib4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVertexAttrib4fv"));
+ VertexAttrib4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glVertexAttrib4f"));
+ VertexAttrib4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttrib4dv"));
+ VertexAttrib4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttrib4d"));
+ VertexAttrib4bv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLbyte *)>(context->getProcAddress("glVertexAttrib4bv"));
+ VertexAttrib4Nusv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLushort *)>(context->getProcAddress("glVertexAttrib4Nusv"));
+ VertexAttrib4Nuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVertexAttrib4Nuiv"));
+ VertexAttrib4Nubv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLubyte *)>(context->getProcAddress("glVertexAttrib4Nubv"));
+ VertexAttrib4Nub = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLubyte , GLubyte , GLubyte , GLubyte )>(context->getProcAddress("glVertexAttrib4Nub"));
+ VertexAttrib4Nsv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib4Nsv"));
+ VertexAttrib4Niv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVertexAttrib4Niv"));
+ VertexAttrib4Nbv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLbyte *)>(context->getProcAddress("glVertexAttrib4Nbv"));
+ VertexAttrib3sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib3sv"));
+ VertexAttrib3s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLshort , GLshort , GLshort )>(context->getProcAddress("glVertexAttrib3s"));
+ VertexAttrib3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVertexAttrib3fv"));
+ VertexAttrib3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glVertexAttrib3f"));
+ VertexAttrib3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttrib3dv"));
+ VertexAttrib3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttrib3d"));
+ VertexAttrib2sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib2sv"));
+ VertexAttrib2s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLshort , GLshort )>(context->getProcAddress("glVertexAttrib2s"));
+ VertexAttrib2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVertexAttrib2fv"));
+ VertexAttrib2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat )>(context->getProcAddress("glVertexAttrib2f"));
+ VertexAttrib2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttrib2dv"));
+ VertexAttrib2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttrib2d"));
+ VertexAttrib1sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib1sv"));
+ VertexAttrib1s = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLshort )>(context->getProcAddress("glVertexAttrib1s"));
+ VertexAttrib1fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVertexAttrib1fv"));
+ VertexAttrib1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat )>(context->getProcAddress("glVertexAttrib1f"));
+ VertexAttrib1dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttrib1dv"));
+ VertexAttrib1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble )>(context->getProcAddress("glVertexAttrib1d"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_2_0_DeprecatedBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(2, 0, QOpenGLVersionStatus::DeprecatedStatus);
+}
+
+QOpenGLFunctions_3_0_DeprecatedBackend::QOpenGLFunctions_3_0_DeprecatedBackend(QOpenGLContext *context)
+ : QOpenGLVersionFunctionsBackend(context)
+{
+ // OpenGL 3.0 deprecated functions
+ VertexAttribI4usv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLushort *)>(context->getProcAddress("glVertexAttribI4usv"));
+ VertexAttribI4ubv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLubyte *)>(context->getProcAddress("glVertexAttribI4ubv"));
+ VertexAttribI4sv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttribI4sv"));
+ VertexAttribI4bv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLbyte *)>(context->getProcAddress("glVertexAttribI4bv"));
+ VertexAttribI4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVertexAttribI4uiv"));
+ VertexAttribI3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVertexAttribI3uiv"));
+ VertexAttribI2uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVertexAttribI2uiv"));
+ VertexAttribI1uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVertexAttribI1uiv"));
+ VertexAttribI4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVertexAttribI4iv"));
+ VertexAttribI3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVertexAttribI3iv"));
+ VertexAttribI2iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVertexAttribI2iv"));
+ VertexAttribI1iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVertexAttribI1iv"));
+ VertexAttribI4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glVertexAttribI4ui"));
+ VertexAttribI3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glVertexAttribI3ui"));
+ VertexAttribI2ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glVertexAttribI2ui"));
+ VertexAttribI1ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glVertexAttribI1ui"));
+ VertexAttribI4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glVertexAttribI4i"));
+ VertexAttribI3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint )>(context->getProcAddress("glVertexAttribI3i"));
+ VertexAttribI2i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint )>(context->getProcAddress("glVertexAttribI2i"));
+ VertexAttribI1i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint )>(context->getProcAddress("glVertexAttribI1i"));
+
+}
+
+QOpenGLVersionStatus QOpenGLFunctions_3_0_DeprecatedBackend::versionStatus()
+{
+ return QOpenGLVersionStatus(3, 0, QOpenGLVersionStatus::DeprecatedStatus);
+}
+
+
+#else
+
+// No backends for OpenGL ES 2
+
+#endif // !QT_OPENGL_ES_2
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglversionfunctions.h b/src/gui/opengl/qopenglversionfunctions.h
new file mode 100644
index 0000000000..833c5adf9f
--- /dev/null
+++ b/src/gui/opengl/qopenglversionfunctions.h
@@ -0,0 +1,1365 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_H
+#define QOPENGLVERSIONFUNCTIONS_H
+
+#include <QtCore/qglobal.h>
+
+#ifndef QT_NO_OPENGL
+
+#include <QtCore/qhash.h>
+#include <QtCore/qpair.h>
+#include <QtGui/qopengl.h>
+
+QT_BEGIN_NAMESPACE
+
+class QOpenGLContext;
+
+#if 0
+// silence syncqt warnings
+#pragma qt_class(QOpenGLVersionFunctions)
+#pragma qt_sync_stop_processing
+#endif
+
+struct QOpenGLVersionStatus
+{
+ enum OpenGLStatus {
+ CoreStatus,
+ DeprecatedStatus,
+ InvalidStatus
+ };
+
+ QOpenGLVersionStatus()
+ : version(qMakePair(0, 0)),
+ status(InvalidStatus)
+ {}
+
+ QOpenGLVersionStatus(int majorVersion, int minorVersion, QOpenGLVersionStatus::OpenGLStatus functionStatus)
+ : version(qMakePair(majorVersion, minorVersion)),
+ status(functionStatus)
+ {}
+
+ QPair<int, int> version;
+ OpenGLStatus status;
+};
+
+inline uint qHash(const QOpenGLVersionStatus &v, uint seed)
+{
+ return qHash(static_cast<int>(v.status * 1000)
+ + v.version.first * 100 + v.version.second * 10, seed);
+}
+
+inline bool operator==(const QOpenGLVersionStatus &lhs, const QOpenGLVersionStatus &rhs)
+{
+ if (lhs.status != rhs.status)
+ return false;
+ return lhs.version == rhs.version;
+}
+
+inline bool operator!=(const QOpenGLVersionStatus &lhs, const QOpenGLVersionStatus &rhs)
+{
+ return !operator==(lhs, rhs);
+}
+
+class QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLVersionFunctionsBackend(QOpenGLContext *ctx)
+ : context(ctx)
+ {}
+
+ QOpenGLContext *context;
+ QAtomicInt refs;
+};
+
+class QAbstractOpenGLFunctionsPrivate
+{
+public:
+ QAbstractOpenGLFunctionsPrivate()
+ : owningContext(0),
+ initialized(false)
+ {}
+
+ static QOpenGLVersionFunctionsBackend *functionsBackend(QOpenGLContext *context,
+ const QOpenGLVersionStatus &v);
+ static void insertFunctionsBackend(QOpenGLContext *context,
+ const QOpenGLVersionStatus &v,
+ QOpenGLVersionFunctionsBackend *backend);
+ static void removeFunctionsBackend(QOpenGLContext *context, const QOpenGLVersionStatus &v);
+
+ QOpenGLContext *owningContext;
+ bool initialized;
+};
+
+class QAbstractOpenGLFunctions
+{
+public:
+ virtual ~QAbstractOpenGLFunctions();
+
+ virtual bool initializeOpenGLFunctions();
+
+ Q_DECLARE_PRIVATE(QAbstractOpenGLFunctions)
+
+protected:
+ QAbstractOpenGLFunctions();
+ QAbstractOpenGLFunctionsPrivate *d_ptr;
+
+ bool isInitialized() const;
+
+ void setOwningContext(const QOpenGLContext *context);
+ QOpenGLContext *owningContext() const;
+
+ friend class QOpenGLContext;
+};
+
+#if !defined(QT_OPENGL_ES_2)
+
+class QOpenGLFunctions_1_0_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_1_0_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 1.0 core functions
+ void (QOPENGLF_APIENTRYP Viewport)(GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP DepthRange)(GLdouble nearVal, GLdouble farVal);
+ GLboolean (QOPENGLF_APIENTRYP IsEnabled)(GLenum cap);
+ void (QOPENGLF_APIENTRYP GetTexLevelParameteriv)(GLenum target, GLint level, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetTexLevelParameterfv)(GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetTexParameteriv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetTexParameterfv)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetTexImage)(GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ const GLubyte * (QOPENGLF_APIENTRYP GetString)(GLenum name);
+ void (QOPENGLF_APIENTRYP GetIntegerv)(GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetFloatv)(GLenum pname, GLfloat *params);
+ GLenum (QOPENGLF_APIENTRYP GetError)();
+ void (QOPENGLF_APIENTRYP GetDoublev)(GLenum pname, GLdouble *params);
+ void (QOPENGLF_APIENTRYP GetBooleanv)(GLenum pname, GLboolean *params);
+ void (QOPENGLF_APIENTRYP ReadPixels)(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP ReadBuffer)(GLenum mode);
+ void (QOPENGLF_APIENTRYP PixelStorei)(GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP PixelStoref)(GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP DepthFunc)(GLenum func);
+ void (QOPENGLF_APIENTRYP StencilOp)(GLenum fail, GLenum zfail, GLenum zpass);
+ void (QOPENGLF_APIENTRYP StencilFunc)(GLenum func, GLint ref, GLuint mask);
+ void (QOPENGLF_APIENTRYP LogicOp)(GLenum opcode);
+ void (QOPENGLF_APIENTRYP BlendFunc)(GLenum sfactor, GLenum dfactor);
+ void (QOPENGLF_APIENTRYP Flush)();
+ void (QOPENGLF_APIENTRYP Finish)();
+ void (QOPENGLF_APIENTRYP Enable)(GLenum cap);
+ void (QOPENGLF_APIENTRYP Disable)(GLenum cap);
+ void (QOPENGLF_APIENTRYP DepthMask)(GLboolean flag);
+ void (QOPENGLF_APIENTRYP ColorMask)(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+ void (QOPENGLF_APIENTRYP StencilMask)(GLuint mask);
+ void (QOPENGLF_APIENTRYP ClearDepth)(GLdouble depth);
+ void (QOPENGLF_APIENTRYP ClearStencil)(GLint s);
+ void (QOPENGLF_APIENTRYP ClearColor)(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void (QOPENGLF_APIENTRYP Clear)(GLbitfield mask);
+ void (QOPENGLF_APIENTRYP DrawBuffer)(GLenum mode);
+ void (QOPENGLF_APIENTRYP TexImage2D)(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP TexImage1D)(GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP TexParameteriv)(GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP TexParameteri)(GLenum target, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP TexParameterfv)(GLenum target, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP TexParameterf)(GLenum target, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP Scissor)(GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP PolygonMode)(GLenum face, GLenum mode);
+ void (QOPENGLF_APIENTRYP PointSize)(GLfloat size);
+ void (QOPENGLF_APIENTRYP LineWidth)(GLfloat width);
+ void (QOPENGLF_APIENTRYP Hint)(GLenum target, GLenum mode);
+ void (QOPENGLF_APIENTRYP FrontFace)(GLenum mode);
+ void (QOPENGLF_APIENTRYP CullFace)(GLenum mode);
+
+};
+
+class QOpenGLFunctions_1_1_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_1_1_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 1.1 core functions
+ void (QOPENGLF_APIENTRYP Indexubv)(const GLubyte *c);
+ void (QOPENGLF_APIENTRYP Indexub)(GLubyte c);
+ GLboolean (QOPENGLF_APIENTRYP IsTexture)(GLuint texture);
+ void (QOPENGLF_APIENTRYP GenTextures)(GLsizei n, GLuint *textures);
+ void (QOPENGLF_APIENTRYP DeleteTextures)(GLsizei n, const GLuint *textures);
+ void (QOPENGLF_APIENTRYP BindTexture)(GLenum target, GLuint texture);
+ void (QOPENGLF_APIENTRYP TexSubImage2D)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP TexSubImage1D)(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP CopyTexSubImage2D)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP CopyTexSubImage1D)(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void (QOPENGLF_APIENTRYP CopyTexImage2D)(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void (QOPENGLF_APIENTRYP CopyTexImage1D)(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void (QOPENGLF_APIENTRYP PolygonOffset)(GLfloat factor, GLfloat units);
+ void (QOPENGLF_APIENTRYP GetPointerv)(GLenum pname, GLvoid* *params);
+ void (QOPENGLF_APIENTRYP DrawElements)(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices);
+ void (QOPENGLF_APIENTRYP DrawArrays)(GLenum mode, GLint first, GLsizei count);
+
+};
+
+class QOpenGLFunctions_1_2_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_1_2_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 1.2 core functions
+ void (QOPENGLF_APIENTRYP CopyTexSubImage3D)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP TexSubImage3D)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP TexImage3D)(GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP DrawRangeElements)(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+ void (QOPENGLF_APIENTRYP BlendEquation)(GLenum mode);
+ void (QOPENGLF_APIENTRYP BlendColor)(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+};
+
+class QOpenGLFunctions_1_3_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_1_3_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 1.3 core functions
+ void (QOPENGLF_APIENTRYP GetCompressedTexImage)(GLenum target, GLint level, GLvoid *img);
+ void (QOPENGLF_APIENTRYP CompressedTexSubImage1D)(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP CompressedTexSubImage2D)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP CompressedTexSubImage3D)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP CompressedTexImage1D)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP CompressedTexImage2D)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP CompressedTexImage3D)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP SampleCoverage)(GLfloat value, GLboolean invert);
+ void (QOPENGLF_APIENTRYP ActiveTexture)(GLenum texture);
+
+};
+
+class QOpenGLFunctions_1_4_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_1_4_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 1.4 core functions
+ void (QOPENGLF_APIENTRYP PointParameteriv)(GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP PointParameteri)(GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP PointParameterfv)(GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP PointParameterf)(GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP MultiDrawElements)(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount);
+ void (QOPENGLF_APIENTRYP MultiDrawArrays)(GLenum mode, const GLint *first, const GLsizei *count, GLsizei drawcount);
+ void (QOPENGLF_APIENTRYP BlendFuncSeparate)(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+};
+
+class QOpenGLFunctions_1_5_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_1_5_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 1.5 core functions
+ void (QOPENGLF_APIENTRYP GetBufferPointerv)(GLenum target, GLenum pname, GLvoid* *params);
+ void (QOPENGLF_APIENTRYP GetBufferParameteriv)(GLenum target, GLenum pname, GLint *params);
+ GLboolean (QOPENGLF_APIENTRYP UnmapBuffer)(GLenum target);
+ GLvoid* (QOPENGLF_APIENTRYP MapBuffer)(GLenum target, GLenum access);
+ void (QOPENGLF_APIENTRYP GetBufferSubData)(GLenum target, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void (QOPENGLF_APIENTRYP BufferSubData)(GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP BufferData)(GLenum target, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ GLboolean (QOPENGLF_APIENTRYP IsBuffer)(GLuint buffer);
+ void (QOPENGLF_APIENTRYP GenBuffers)(GLsizei n, GLuint *buffers);
+ void (QOPENGLF_APIENTRYP DeleteBuffers)(GLsizei n, const GLuint *buffers);
+ void (QOPENGLF_APIENTRYP BindBuffer)(GLenum target, GLuint buffer);
+ void (QOPENGLF_APIENTRYP GetQueryObjectuiv)(GLuint id, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetQueryObjectiv)(GLuint id, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetQueryiv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP EndQuery)(GLenum target);
+ void (QOPENGLF_APIENTRYP BeginQuery)(GLenum target, GLuint id);
+ GLboolean (QOPENGLF_APIENTRYP IsQuery)(GLuint id);
+ void (QOPENGLF_APIENTRYP DeleteQueries)(GLsizei n, const GLuint *ids);
+ void (QOPENGLF_APIENTRYP GenQueries)(GLsizei n, GLuint *ids);
+
+};
+
+class QOpenGLFunctions_2_0_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_2_0_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 2.0 core functions
+ void (QOPENGLF_APIENTRYP VertexAttribPointer)(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP ValidateProgram)(GLuint program);
+ void (QOPENGLF_APIENTRYP UniformMatrix4fv)(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix3fv)(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix2fv)(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP Uniform4iv)(GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP Uniform3iv)(GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP Uniform2iv)(GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP Uniform1iv)(GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP Uniform4fv)(GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP Uniform3fv)(GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP Uniform2fv)(GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP Uniform1fv)(GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP Uniform4i)(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void (QOPENGLF_APIENTRYP Uniform3i)(GLint location, GLint v0, GLint v1, GLint v2);
+ void (QOPENGLF_APIENTRYP Uniform2i)(GLint location, GLint v0, GLint v1);
+ void (QOPENGLF_APIENTRYP Uniform1i)(GLint location, GLint v0);
+ void (QOPENGLF_APIENTRYP Uniform4f)(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void (QOPENGLF_APIENTRYP Uniform3f)(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void (QOPENGLF_APIENTRYP Uniform2f)(GLint location, GLfloat v0, GLfloat v1);
+ void (QOPENGLF_APIENTRYP Uniform1f)(GLint location, GLfloat v0);
+ void (QOPENGLF_APIENTRYP UseProgram)(GLuint program);
+ void (QOPENGLF_APIENTRYP ShaderSource)(GLuint shader, GLsizei count, const GLchar* const *string, const GLint *length);
+ void (QOPENGLF_APIENTRYP LinkProgram)(GLuint program);
+ GLboolean (QOPENGLF_APIENTRYP IsShader)(GLuint shader);
+ GLboolean (QOPENGLF_APIENTRYP IsProgram)(GLuint program);
+ void (QOPENGLF_APIENTRYP GetVertexAttribPointerv)(GLuint index, GLenum pname, GLvoid* *pointer);
+ void (QOPENGLF_APIENTRYP GetVertexAttribiv)(GLuint index, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetVertexAttribfv)(GLuint index, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetVertexAttribdv)(GLuint index, GLenum pname, GLdouble *params);
+ void (QOPENGLF_APIENTRYP GetUniformiv)(GLuint program, GLint location, GLint *params);
+ void (QOPENGLF_APIENTRYP GetUniformfv)(GLuint program, GLint location, GLfloat *params);
+ GLint (QOPENGLF_APIENTRYP GetUniformLocation)(GLuint program, const GLchar *name);
+ void (QOPENGLF_APIENTRYP GetShaderSource)(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *source);
+ void (QOPENGLF_APIENTRYP GetShaderInfoLog)(GLuint shader, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void (QOPENGLF_APIENTRYP GetShaderiv)(GLuint shader, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetProgramInfoLog)(GLuint program, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void (QOPENGLF_APIENTRYP GetProgramiv)(GLuint program, GLenum pname, GLint *params);
+ GLint (QOPENGLF_APIENTRYP GetAttribLocation)(GLuint program, const GLchar *name);
+ void (QOPENGLF_APIENTRYP GetAttachedShaders)(GLuint program, GLsizei maxCount, GLsizei *count, GLuint *obj);
+ void (QOPENGLF_APIENTRYP GetActiveUniform)(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void (QOPENGLF_APIENTRYP GetActiveAttrib)(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLint *size, GLenum *type, GLchar *name);
+ void (QOPENGLF_APIENTRYP EnableVertexAttribArray)(GLuint index);
+ void (QOPENGLF_APIENTRYP DisableVertexAttribArray)(GLuint index);
+ void (QOPENGLF_APIENTRYP DetachShader)(GLuint program, GLuint shader);
+ void (QOPENGLF_APIENTRYP DeleteShader)(GLuint shader);
+ void (QOPENGLF_APIENTRYP DeleteProgram)(GLuint program);
+ GLuint (QOPENGLF_APIENTRYP CreateShader)(GLenum type);
+ GLuint (QOPENGLF_APIENTRYP CreateProgram)();
+ void (QOPENGLF_APIENTRYP CompileShader)(GLuint shader);
+ void (QOPENGLF_APIENTRYP BindAttribLocation)(GLuint program, GLuint index, const GLchar *name);
+ void (QOPENGLF_APIENTRYP AttachShader)(GLuint program, GLuint shader);
+ void (QOPENGLF_APIENTRYP StencilMaskSeparate)(GLenum face, GLuint mask);
+ void (QOPENGLF_APIENTRYP StencilFuncSeparate)(GLenum face, GLenum func, GLint ref, GLuint mask);
+ void (QOPENGLF_APIENTRYP StencilOpSeparate)(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+ void (QOPENGLF_APIENTRYP DrawBuffers)(GLsizei n, const GLenum *bufs);
+ void (QOPENGLF_APIENTRYP BlendEquationSeparate)(GLenum modeRGB, GLenum modeAlpha);
+
+};
+
+class QOpenGLFunctions_2_1_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_2_1_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 2.1 core functions
+ void (QOPENGLF_APIENTRYP UniformMatrix4x3fv)(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix3x4fv)(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix4x2fv)(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix2x4fv)(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix3x2fv)(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix2x3fv)(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+
+};
+
+class QOpenGLFunctions_3_0_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_3_0_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 3.0 core functions
+ GLboolean (QOPENGLF_APIENTRYP IsVertexArray)(GLuint array);
+ void (QOPENGLF_APIENTRYP GenVertexArrays)(GLsizei n, GLuint *arrays);
+ void (QOPENGLF_APIENTRYP DeleteVertexArrays)(GLsizei n, const GLuint *arrays);
+ void (QOPENGLF_APIENTRYP BindVertexArray)(GLuint array);
+ void (QOPENGLF_APIENTRYP FlushMappedBufferRange)(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* (QOPENGLF_APIENTRYP MapBufferRange)(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ void (QOPENGLF_APIENTRYP FramebufferTextureLayer)(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void (QOPENGLF_APIENTRYP RenderbufferStorageMultisample)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP BlitFramebuffer)(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void (QOPENGLF_APIENTRYP GenerateMipmap)(GLenum target);
+ void (QOPENGLF_APIENTRYP GetFramebufferAttachmentParameteriv)(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP FramebufferRenderbuffer)(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void (QOPENGLF_APIENTRYP FramebufferTexture3D)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void (QOPENGLF_APIENTRYP FramebufferTexture2D)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void (QOPENGLF_APIENTRYP FramebufferTexture1D)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum (QOPENGLF_APIENTRYP CheckFramebufferStatus)(GLenum target);
+ void (QOPENGLF_APIENTRYP GenFramebuffers)(GLsizei n, GLuint *framebuffers);
+ void (QOPENGLF_APIENTRYP DeleteFramebuffers)(GLsizei n, const GLuint *framebuffers);
+ void (QOPENGLF_APIENTRYP BindFramebuffer)(GLenum target, GLuint framebuffer);
+ GLboolean (QOPENGLF_APIENTRYP IsFramebuffer)(GLuint framebuffer);
+ void (QOPENGLF_APIENTRYP GetRenderbufferParameteriv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP RenderbufferStorage)(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP GenRenderbuffers)(GLsizei n, GLuint *renderbuffers);
+ void (QOPENGLF_APIENTRYP DeleteRenderbuffers)(GLsizei n, const GLuint *renderbuffers);
+ void (QOPENGLF_APIENTRYP BindRenderbuffer)(GLenum target, GLuint renderbuffer);
+ GLboolean (QOPENGLF_APIENTRYP IsRenderbuffer)(GLuint renderbuffer);
+ const GLubyte * (QOPENGLF_APIENTRYP GetStringi)(GLenum name, GLuint index);
+ void (QOPENGLF_APIENTRYP ClearBufferfi)(GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+ void (QOPENGLF_APIENTRYP ClearBufferfv)(GLenum buffer, GLint drawbuffer, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ClearBufferuiv)(GLenum buffer, GLint drawbuffer, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ClearBufferiv)(GLenum buffer, GLint drawbuffer, const GLint *value);
+ void (QOPENGLF_APIENTRYP GetTexParameterIuiv)(GLenum target, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetTexParameterIiv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP TexParameterIuiv)(GLenum target, GLenum pname, const GLuint *params);
+ void (QOPENGLF_APIENTRYP TexParameterIiv)(GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP Uniform4uiv)(GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP Uniform3uiv)(GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP Uniform2uiv)(GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP Uniform1uiv)(GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP Uniform4ui)(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void (QOPENGLF_APIENTRYP Uniform3ui)(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void (QOPENGLF_APIENTRYP Uniform2ui)(GLint location, GLuint v0, GLuint v1);
+ void (QOPENGLF_APIENTRYP Uniform1ui)(GLint location, GLuint v0);
+ GLint (QOPENGLF_APIENTRYP GetFragDataLocation)(GLuint program, const GLchar *name);
+ void (QOPENGLF_APIENTRYP BindFragDataLocation)(GLuint program, GLuint color, const GLchar *name);
+ void (QOPENGLF_APIENTRYP GetUniformuiv)(GLuint program, GLint location, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetVertexAttribIuiv)(GLuint index, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetVertexAttribIiv)(GLuint index, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP VertexAttribIPointer)(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP EndConditionalRender)();
+ void (QOPENGLF_APIENTRYP BeginConditionalRender)(GLuint id, GLenum mode);
+ void (QOPENGLF_APIENTRYP ClampColor)(GLenum target, GLenum clamp);
+ void (QOPENGLF_APIENTRYP GetTransformFeedbackVarying)(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void (QOPENGLF_APIENTRYP TransformFeedbackVaryings)(GLuint program, GLsizei count, const GLchar* const *varyings, GLenum bufferMode);
+ void (QOPENGLF_APIENTRYP BindBufferBase)(GLenum target, GLuint index, GLuint buffer);
+ void (QOPENGLF_APIENTRYP BindBufferRange)(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void (QOPENGLF_APIENTRYP EndTransformFeedback)();
+ void (QOPENGLF_APIENTRYP BeginTransformFeedback)(GLenum primitiveMode);
+ GLboolean (QOPENGLF_APIENTRYP IsEnabledi)(GLenum target, GLuint index);
+ void (QOPENGLF_APIENTRYP Disablei)(GLenum target, GLuint index);
+ void (QOPENGLF_APIENTRYP Enablei)(GLenum target, GLuint index);
+ void (QOPENGLF_APIENTRYP GetIntegeri_v)(GLenum target, GLuint index, GLint *data);
+ void (QOPENGLF_APIENTRYP GetBooleani_v)(GLenum target, GLuint index, GLboolean *data);
+ void (QOPENGLF_APIENTRYP ColorMaski)(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+};
+
+class QOpenGLFunctions_3_1_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_3_1_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 3.1 core functions
+ void (QOPENGLF_APIENTRYP CopyBufferSubData)(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void (QOPENGLF_APIENTRYP UniformBlockBinding)(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void (QOPENGLF_APIENTRYP GetActiveUniformBlockName)(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void (QOPENGLF_APIENTRYP GetActiveUniformBlockiv)(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint (QOPENGLF_APIENTRYP GetUniformBlockIndex)(GLuint program, const GLchar *uniformBlockName);
+ void (QOPENGLF_APIENTRYP GetActiveUniformName)(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void (QOPENGLF_APIENTRYP GetActiveUniformsiv)(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetUniformIndices)(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+ void (QOPENGLF_APIENTRYP PrimitiveRestartIndex)(GLuint index);
+ void (QOPENGLF_APIENTRYP TexBuffer)(GLenum target, GLenum internalformat, GLuint buffer);
+ void (QOPENGLF_APIENTRYP DrawElementsInstanced)(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount);
+ void (QOPENGLF_APIENTRYP DrawArraysInstanced)(GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+};
+
+class QOpenGLFunctions_3_2_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_3_2_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 3.2 core functions
+ void (QOPENGLF_APIENTRYP SampleMaski)(GLuint index, GLbitfield mask);
+ void (QOPENGLF_APIENTRYP GetMultisamplefv)(GLenum pname, GLuint index, GLfloat *val);
+ void (QOPENGLF_APIENTRYP TexImage3DMultisample)(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void (QOPENGLF_APIENTRYP TexImage2DMultisample)(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void (QOPENGLF_APIENTRYP GetSynciv)(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void (QOPENGLF_APIENTRYP GetInteger64v)(GLenum pname, GLint64 *params);
+ void (QOPENGLF_APIENTRYP WaitSync)(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum (QOPENGLF_APIENTRYP ClientWaitSync)(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void (QOPENGLF_APIENTRYP DeleteSync)(GLsync sync);
+ GLboolean (QOPENGLF_APIENTRYP IsSync)(GLsync sync);
+ GLsync (QOPENGLF_APIENTRYP FenceSync)(GLenum condition, GLbitfield flags);
+ void (QOPENGLF_APIENTRYP ProvokingVertex)(GLenum mode);
+ void (QOPENGLF_APIENTRYP MultiDrawElementsBaseVertex)(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void (QOPENGLF_APIENTRYP DrawElementsInstancedBaseVertex)(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void (QOPENGLF_APIENTRYP DrawRangeElementsBaseVertex)(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void (QOPENGLF_APIENTRYP DrawElementsBaseVertex)(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void (QOPENGLF_APIENTRYP FramebufferTexture)(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void (QOPENGLF_APIENTRYP GetBufferParameteri64v)(GLenum target, GLenum pname, GLint64 *params);
+ void (QOPENGLF_APIENTRYP GetInteger64i_v)(GLenum target, GLuint index, GLint64 *data);
+
+};
+
+class QOpenGLFunctions_3_3_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_3_3_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 3.3 core functions
+ void (QOPENGLF_APIENTRYP VertexAttribP4uiv)(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexAttribP4ui)(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void (QOPENGLF_APIENTRYP VertexAttribP3uiv)(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexAttribP3ui)(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void (QOPENGLF_APIENTRYP VertexAttribP2uiv)(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexAttribP2ui)(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void (QOPENGLF_APIENTRYP VertexAttribP1uiv)(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexAttribP1ui)(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void (QOPENGLF_APIENTRYP SecondaryColorP3uiv)(GLenum type, const GLuint *color);
+ void (QOPENGLF_APIENTRYP SecondaryColorP3ui)(GLenum type, GLuint color);
+ void (QOPENGLF_APIENTRYP ColorP4uiv)(GLenum type, const GLuint *color);
+ void (QOPENGLF_APIENTRYP ColorP4ui)(GLenum type, GLuint color);
+ void (QOPENGLF_APIENTRYP ColorP3uiv)(GLenum type, const GLuint *color);
+ void (QOPENGLF_APIENTRYP ColorP3ui)(GLenum type, GLuint color);
+ void (QOPENGLF_APIENTRYP NormalP3uiv)(GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP NormalP3ui)(GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP4uiv)(GLenum texture, GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP4ui)(GLenum texture, GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP3uiv)(GLenum texture, GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP3ui)(GLenum texture, GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP2uiv)(GLenum texture, GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP2ui)(GLenum texture, GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP1uiv)(GLenum texture, GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP1ui)(GLenum texture, GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP TexCoordP4uiv)(GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP TexCoordP4ui)(GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP TexCoordP3uiv)(GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP TexCoordP3ui)(GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP TexCoordP2uiv)(GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP TexCoordP2ui)(GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP TexCoordP1uiv)(GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP TexCoordP1ui)(GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP VertexP4uiv)(GLenum type, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexP4ui)(GLenum type, GLuint value);
+ void (QOPENGLF_APIENTRYP VertexP3uiv)(GLenum type, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexP3ui)(GLenum type, GLuint value);
+ void (QOPENGLF_APIENTRYP VertexP2uiv)(GLenum type, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexP2ui)(GLenum type, GLuint value);
+ void (QOPENGLF_APIENTRYP GetQueryObjectui64v)(GLuint id, GLenum pname, GLuint64 *params);
+ void (QOPENGLF_APIENTRYP GetQueryObjecti64v)(GLuint id, GLenum pname, GLint64 *params);
+ void (QOPENGLF_APIENTRYP QueryCounter)(GLuint id, GLenum target);
+ void (QOPENGLF_APIENTRYP GetSamplerParameterIuiv)(GLuint sampler, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetSamplerParameterfv)(GLuint sampler, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetSamplerParameterIiv)(GLuint sampler, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetSamplerParameteriv)(GLuint sampler, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP SamplerParameterIuiv)(GLuint sampler, GLenum pname, const GLuint *param);
+ void (QOPENGLF_APIENTRYP SamplerParameterIiv)(GLuint sampler, GLenum pname, const GLint *param);
+ void (QOPENGLF_APIENTRYP SamplerParameterfv)(GLuint sampler, GLenum pname, const GLfloat *param);
+ void (QOPENGLF_APIENTRYP SamplerParameterf)(GLuint sampler, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP SamplerParameteriv)(GLuint sampler, GLenum pname, const GLint *param);
+ void (QOPENGLF_APIENTRYP SamplerParameteri)(GLuint sampler, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP BindSampler)(GLuint unit, GLuint sampler);
+ GLboolean (QOPENGLF_APIENTRYP IsSampler)(GLuint sampler);
+ void (QOPENGLF_APIENTRYP DeleteSamplers)(GLsizei count, const GLuint *samplers);
+ void (QOPENGLF_APIENTRYP GenSamplers)(GLsizei count, GLuint *samplers);
+ GLint (QOPENGLF_APIENTRYP GetFragDataIndex)(GLuint program, const GLchar *name);
+ void (QOPENGLF_APIENTRYP BindFragDataLocationIndexed)(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+ void (QOPENGLF_APIENTRYP VertexAttribDivisor)(GLuint index, GLuint divisor);
+
+};
+
+class QOpenGLFunctions_4_0_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_4_0_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 4.0 core functions
+ void (QOPENGLF_APIENTRYP GetQueryIndexediv)(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP EndQueryIndexed)(GLenum target, GLuint index);
+ void (QOPENGLF_APIENTRYP BeginQueryIndexed)(GLenum target, GLuint index, GLuint id);
+ void (QOPENGLF_APIENTRYP DrawTransformFeedbackStream)(GLenum mode, GLuint id, GLuint stream);
+ void (QOPENGLF_APIENTRYP DrawTransformFeedback)(GLenum mode, GLuint id);
+ void (QOPENGLF_APIENTRYP ResumeTransformFeedback)();
+ void (QOPENGLF_APIENTRYP PauseTransformFeedback)();
+ GLboolean (QOPENGLF_APIENTRYP IsTransformFeedback)(GLuint id);
+ void (QOPENGLF_APIENTRYP GenTransformFeedbacks)(GLsizei n, GLuint *ids);
+ void (QOPENGLF_APIENTRYP DeleteTransformFeedbacks)(GLsizei n, const GLuint *ids);
+ void (QOPENGLF_APIENTRYP BindTransformFeedback)(GLenum target, GLuint id);
+ void (QOPENGLF_APIENTRYP PatchParameterfv)(GLenum pname, const GLfloat *values);
+ void (QOPENGLF_APIENTRYP PatchParameteri)(GLenum pname, GLint value);
+ void (QOPENGLF_APIENTRYP GetProgramStageiv)(GLuint program, GLenum shadertype, GLenum pname, GLint *values);
+ void (QOPENGLF_APIENTRYP GetUniformSubroutineuiv)(GLenum shadertype, GLint location, GLuint *params);
+ void (QOPENGLF_APIENTRYP UniformSubroutinesuiv)(GLenum shadertype, GLsizei count, const GLuint *indices);
+ void (QOPENGLF_APIENTRYP GetActiveSubroutineName)(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void (QOPENGLF_APIENTRYP GetActiveSubroutineUniformName)(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void (QOPENGLF_APIENTRYP GetActiveSubroutineUniformiv)(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
+ GLuint (QOPENGLF_APIENTRYP GetSubroutineIndex)(GLuint program, GLenum shadertype, const GLchar *name);
+ GLint (QOPENGLF_APIENTRYP GetSubroutineUniformLocation)(GLuint program, GLenum shadertype, const GLchar *name);
+ void (QOPENGLF_APIENTRYP GetUniformdv)(GLuint program, GLint location, GLdouble *params);
+ void (QOPENGLF_APIENTRYP UniformMatrix4x3dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix4x2dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix3x4dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix3x2dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix2x4dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix2x3dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix4dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix3dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix2dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP Uniform4dv)(GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP Uniform3dv)(GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP Uniform2dv)(GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP Uniform1dv)(GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP Uniform4d)(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP Uniform3d)(GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP Uniform2d)(GLint location, GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP Uniform1d)(GLint location, GLdouble x);
+ void (QOPENGLF_APIENTRYP DrawElementsIndirect)(GLenum mode, GLenum type, const GLvoid *indirect);
+ void (QOPENGLF_APIENTRYP DrawArraysIndirect)(GLenum mode, const GLvoid *indirect);
+ void (QOPENGLF_APIENTRYP BlendFuncSeparatei)(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void (QOPENGLF_APIENTRYP BlendFunci)(GLuint buf, GLenum src, GLenum dst);
+ void (QOPENGLF_APIENTRYP BlendEquationSeparatei)(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void (QOPENGLF_APIENTRYP BlendEquationi)(GLuint buf, GLenum mode);
+ void (QOPENGLF_APIENTRYP MinSampleShading)(GLfloat value);
+
+};
+
+class QOpenGLFunctions_4_1_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_4_1_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 4.1 core functions
+ void (QOPENGLF_APIENTRYP GetDoublei_v)(GLenum target, GLuint index, GLdouble *data);
+ void (QOPENGLF_APIENTRYP GetFloati_v)(GLenum target, GLuint index, GLfloat *data);
+ void (QOPENGLF_APIENTRYP DepthRangeIndexed)(GLuint index, GLdouble n, GLdouble f);
+ void (QOPENGLF_APIENTRYP DepthRangeArrayv)(GLuint first, GLsizei count, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP ScissorIndexedv)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP ScissorIndexed)(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP ScissorArrayv)(GLuint first, GLsizei count, const GLint *v);
+ void (QOPENGLF_APIENTRYP ViewportIndexedfv)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ViewportIndexedf)(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+ void (QOPENGLF_APIENTRYP ViewportArrayv)(GLuint first, GLsizei count, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP GetVertexAttribLdv)(GLuint index, GLenum pname, GLdouble *params);
+ void (QOPENGLF_APIENTRYP VertexAttribLPointer)(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP VertexAttribL4dv)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL3dv)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL2dv)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL1dv)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL4d)(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP VertexAttribL3d)(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP VertexAttribL2d)(GLuint index, GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP VertexAttribL1d)(GLuint index, GLdouble x);
+ void (QOPENGLF_APIENTRYP GetProgramPipelineInfoLog)(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void (QOPENGLF_APIENTRYP ValidateProgramPipeline)(GLuint pipeline);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4x3dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3x4dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4x2dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2x4dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3x2dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2x3dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4x3fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3x4fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4x2fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2x4fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3x2fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2x3fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4uiv)(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4ui)(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void (QOPENGLF_APIENTRYP ProgramUniform4dv)(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4d)(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+ void (QOPENGLF_APIENTRYP ProgramUniform4fv)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4f)(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void (QOPENGLF_APIENTRYP ProgramUniform4iv)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4i)(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void (QOPENGLF_APIENTRYP ProgramUniform3uiv)(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3ui)(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void (QOPENGLF_APIENTRYP ProgramUniform3dv)(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3d)(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+ void (QOPENGLF_APIENTRYP ProgramUniform3fv)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3f)(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void (QOPENGLF_APIENTRYP ProgramUniform3iv)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3i)(GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+ void (QOPENGLF_APIENTRYP ProgramUniform2uiv)(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2ui)(GLuint program, GLint location, GLuint v0, GLuint v1);
+ void (QOPENGLF_APIENTRYP ProgramUniform2dv)(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2d)(GLuint program, GLint location, GLdouble v0, GLdouble v1);
+ void (QOPENGLF_APIENTRYP ProgramUniform2fv)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2f)(GLuint program, GLint location, GLfloat v0, GLfloat v1);
+ void (QOPENGLF_APIENTRYP ProgramUniform2iv)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2i)(GLuint program, GLint location, GLint v0, GLint v1);
+ void (QOPENGLF_APIENTRYP ProgramUniform1uiv)(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1ui)(GLuint program, GLint location, GLuint v0);
+ void (QOPENGLF_APIENTRYP ProgramUniform1dv)(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1d)(GLuint program, GLint location, GLdouble v0);
+ void (QOPENGLF_APIENTRYP ProgramUniform1fv)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1f)(GLuint program, GLint location, GLfloat v0);
+ void (QOPENGLF_APIENTRYP ProgramUniform1iv)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1i)(GLuint program, GLint location, GLint v0);
+ void (QOPENGLF_APIENTRYP GetProgramPipelineiv)(GLuint pipeline, GLenum pname, GLint *params);
+ GLboolean (QOPENGLF_APIENTRYP IsProgramPipeline)(GLuint pipeline);
+ void (QOPENGLF_APIENTRYP GenProgramPipelines)(GLsizei n, GLuint *pipelines);
+ void (QOPENGLF_APIENTRYP DeleteProgramPipelines)(GLsizei n, const GLuint *pipelines);
+ void (QOPENGLF_APIENTRYP BindProgramPipeline)(GLuint pipeline);
+ GLuint (QOPENGLF_APIENTRYP CreateShaderProgramv)(GLenum type, GLsizei count, const GLchar* const *strings);
+ void (QOPENGLF_APIENTRYP ActiveShaderProgram)(GLuint pipeline, GLuint program);
+ void (QOPENGLF_APIENTRYP UseProgramStages)(GLuint pipeline, GLbitfield stages, GLuint program);
+ void (QOPENGLF_APIENTRYP ProgramParameteri)(GLuint program, GLenum pname, GLint value);
+ void (QOPENGLF_APIENTRYP ProgramBinary)(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length);
+ void (QOPENGLF_APIENTRYP GetProgramBinary)(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+ void (QOPENGLF_APIENTRYP ClearDepthf)(GLfloat dd);
+ void (QOPENGLF_APIENTRYP DepthRangef)(GLfloat n, GLfloat f);
+ void (QOPENGLF_APIENTRYP GetShaderPrecisionFormat)(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision);
+ void (QOPENGLF_APIENTRYP ShaderBinary)(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length);
+ void (QOPENGLF_APIENTRYP ReleaseShaderCompiler)();
+
+};
+
+class QOpenGLFunctions_4_2_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_4_2_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 4.2 core functions
+ void (QOPENGLF_APIENTRYP TexStorage3D)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void (QOPENGLF_APIENTRYP TexStorage2D)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP TexStorage1D)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void (QOPENGLF_APIENTRYP MemoryBarrier)(GLbitfield barriers);
+ void (QOPENGLF_APIENTRYP BindImageTexture)(GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
+ void (QOPENGLF_APIENTRYP GetActiveAtomicCounterBufferiv)(GLuint program, GLuint bufferIndex, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetInternalformativ)(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params);
+ void (QOPENGLF_APIENTRYP DrawTransformFeedbackStreamInstanced)(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
+ void (QOPENGLF_APIENTRYP DrawTransformFeedbackInstanced)(GLenum mode, GLuint id, GLsizei instancecount);
+ void (QOPENGLF_APIENTRYP DrawElementsInstancedBaseVertexBaseInstance)(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
+ void (QOPENGLF_APIENTRYP DrawElementsInstancedBaseInstance)(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance);
+ void (QOPENGLF_APIENTRYP DrawArraysInstancedBaseInstance)(GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+
+};
+
+class QOpenGLFunctions_4_3_CoreBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_4_3_CoreBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 4.3 core functions
+ void (QOPENGLF_APIENTRYP TexStorage3DMultisample)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void (QOPENGLF_APIENTRYP TexStorage2DMultisample)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void (QOPENGLF_APIENTRYP TexBufferRange)(GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void (QOPENGLF_APIENTRYP ShaderStorageBlockBinding)(GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding);
+ GLint (QOPENGLF_APIENTRYP GetProgramResourceLocationIndex)(GLuint program, GLenum programInterface, const GLchar *name);
+ GLint (QOPENGLF_APIENTRYP GetProgramResourceLocation)(GLuint program, GLenum programInterface, const GLchar *name);
+ void (QOPENGLF_APIENTRYP GetProgramResourceiv)(GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params);
+ void (QOPENGLF_APIENTRYP GetProgramResourceName)(GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
+ GLuint (QOPENGLF_APIENTRYP GetProgramResourceIndex)(GLuint program, GLenum programInterface, const GLchar *name);
+ void (QOPENGLF_APIENTRYP GetProgramInterfaceiv)(GLuint program, GLenum programInterface, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP MultiDrawElementsIndirect)(GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride);
+ void (QOPENGLF_APIENTRYP MultiDrawArraysIndirect)(GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride);
+ void (QOPENGLF_APIENTRYP InvalidateSubFramebuffer)(GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP InvalidateFramebuffer)(GLenum target, GLsizei numAttachments, const GLenum *attachments);
+ void (QOPENGLF_APIENTRYP InvalidateBufferData)(GLuint buffer);
+ void (QOPENGLF_APIENTRYP InvalidateBufferSubData)(GLuint buffer, GLintptr offset, GLsizeiptr length);
+ void (QOPENGLF_APIENTRYP InvalidateTexImage)(GLuint texture, GLint level);
+ void (QOPENGLF_APIENTRYP InvalidateTexSubImage)(GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth);
+ void (QOPENGLF_APIENTRYP GetInternalformati64v)(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params);
+ void (QOPENGLF_APIENTRYP GetFramebufferParameteriv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP FramebufferParameteri)(GLenum target, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP VertexBindingDivisor)(GLuint bindingindex, GLuint divisor);
+ void (QOPENGLF_APIENTRYP VertexAttribBinding)(GLuint attribindex, GLuint bindingindex);
+ void (QOPENGLF_APIENTRYP VertexAttribLFormat)(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void (QOPENGLF_APIENTRYP VertexAttribIFormat)(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void (QOPENGLF_APIENTRYP VertexAttribFormat)(GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset);
+ void (QOPENGLF_APIENTRYP BindVertexBuffer)(GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+ void (QOPENGLF_APIENTRYP TextureView)(GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers);
+ void (QOPENGLF_APIENTRYP CopyImageSubData)(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 (QOPENGLF_APIENTRYP DispatchComputeIndirect)(GLintptr indirect);
+ void (QOPENGLF_APIENTRYP DispatchCompute)(GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z);
+ void (QOPENGLF_APIENTRYP ClearBufferSubData)(GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data);
+ void (QOPENGLF_APIENTRYP ClearBufferData)(GLenum target, GLenum internalformat, GLenum format, GLenum type, const void *data);
+
+};
+
+class QOpenGLFunctions_1_0_DeprecatedBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_1_0_DeprecatedBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 1.0 deprecated functions
+ void (QOPENGLF_APIENTRYP Translatef)(GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP Translated)(GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP Scalef)(GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP Scaled)(GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP Rotatef)(GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP Rotated)(GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP PushMatrix)();
+ void (QOPENGLF_APIENTRYP PopMatrix)();
+ void (QOPENGLF_APIENTRYP Ortho)(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void (QOPENGLF_APIENTRYP MultMatrixd)(const GLdouble *m);
+ void (QOPENGLF_APIENTRYP MultMatrixf)(const GLfloat *m);
+ void (QOPENGLF_APIENTRYP MatrixMode)(GLenum mode);
+ void (QOPENGLF_APIENTRYP LoadMatrixd)(const GLdouble *m);
+ void (QOPENGLF_APIENTRYP LoadMatrixf)(const GLfloat *m);
+ void (QOPENGLF_APIENTRYP LoadIdentity)();
+ void (QOPENGLF_APIENTRYP Frustum)(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ GLboolean (QOPENGLF_APIENTRYP IsList)(GLuint list);
+ void (QOPENGLF_APIENTRYP GetTexGeniv)(GLenum coord, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetTexGenfv)(GLenum coord, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetTexGendv)(GLenum coord, GLenum pname, GLdouble *params);
+ void (QOPENGLF_APIENTRYP GetTexEnviv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetTexEnvfv)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetPolygonStipple)(GLubyte *mask);
+ void (QOPENGLF_APIENTRYP GetPixelMapusv)(GLenum map, GLushort *values);
+ void (QOPENGLF_APIENTRYP GetPixelMapuiv)(GLenum map, GLuint *values);
+ void (QOPENGLF_APIENTRYP GetPixelMapfv)(GLenum map, GLfloat *values);
+ void (QOPENGLF_APIENTRYP GetMaterialiv)(GLenum face, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetMaterialfv)(GLenum face, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetMapiv)(GLenum target, GLenum query, GLint *v);
+ void (QOPENGLF_APIENTRYP GetMapfv)(GLenum target, GLenum query, GLfloat *v);
+ void (QOPENGLF_APIENTRYP GetMapdv)(GLenum target, GLenum query, GLdouble *v);
+ void (QOPENGLF_APIENTRYP GetLightiv)(GLenum light, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetLightfv)(GLenum light, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetClipPlane)(GLenum plane, GLdouble *equation);
+ void (QOPENGLF_APIENTRYP DrawPixels)(GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP CopyPixels)(GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+ void (QOPENGLF_APIENTRYP PixelMapusv)(GLenum map, GLint mapsize, const GLushort *values);
+ void (QOPENGLF_APIENTRYP PixelMapuiv)(GLenum map, GLint mapsize, const GLuint *values);
+ void (QOPENGLF_APIENTRYP PixelMapfv)(GLenum map, GLint mapsize, const GLfloat *values);
+ void (QOPENGLF_APIENTRYP PixelTransferi)(GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP PixelTransferf)(GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP PixelZoom)(GLfloat xfactor, GLfloat yfactor);
+ void (QOPENGLF_APIENTRYP AlphaFunc)(GLenum func, GLfloat ref);
+ void (QOPENGLF_APIENTRYP EvalPoint2)(GLint i, GLint j);
+ void (QOPENGLF_APIENTRYP EvalMesh2)(GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+ void (QOPENGLF_APIENTRYP EvalPoint1)(GLint i);
+ void (QOPENGLF_APIENTRYP EvalMesh1)(GLenum mode, GLint i1, GLint i2);
+ void (QOPENGLF_APIENTRYP EvalCoord2fv)(const GLfloat *u);
+ void (QOPENGLF_APIENTRYP EvalCoord2f)(GLfloat u, GLfloat v);
+ void (QOPENGLF_APIENTRYP EvalCoord2dv)(const GLdouble *u);
+ void (QOPENGLF_APIENTRYP EvalCoord2d)(GLdouble u, GLdouble v);
+ void (QOPENGLF_APIENTRYP EvalCoord1fv)(const GLfloat *u);
+ void (QOPENGLF_APIENTRYP EvalCoord1f)(GLfloat u);
+ void (QOPENGLF_APIENTRYP EvalCoord1dv)(const GLdouble *u);
+ void (QOPENGLF_APIENTRYP EvalCoord1d)(GLdouble u);
+ void (QOPENGLF_APIENTRYP MapGrid2f)(GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+ void (QOPENGLF_APIENTRYP MapGrid2d)(GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+ void (QOPENGLF_APIENTRYP MapGrid1f)(GLint un, GLfloat u1, GLfloat u2);
+ void (QOPENGLF_APIENTRYP MapGrid1d)(GLint un, GLdouble u1, GLdouble u2);
+ void (QOPENGLF_APIENTRYP Map2f)(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void (QOPENGLF_APIENTRYP Map2d)(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void (QOPENGLF_APIENTRYP Map1f)(GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void (QOPENGLF_APIENTRYP Map1d)(GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ void (QOPENGLF_APIENTRYP PushAttrib)(GLbitfield mask);
+ void (QOPENGLF_APIENTRYP PopAttrib)();
+ void (QOPENGLF_APIENTRYP Accum)(GLenum op, GLfloat value);
+ void (QOPENGLF_APIENTRYP IndexMask)(GLuint mask);
+ void (QOPENGLF_APIENTRYP ClearIndex)(GLfloat c);
+ void (QOPENGLF_APIENTRYP ClearAccum)(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void (QOPENGLF_APIENTRYP PushName)(GLuint name);
+ void (QOPENGLF_APIENTRYP PopName)();
+ void (QOPENGLF_APIENTRYP PassThrough)(GLfloat token);
+ void (QOPENGLF_APIENTRYP LoadName)(GLuint name);
+ void (QOPENGLF_APIENTRYP InitNames)();
+ GLint (QOPENGLF_APIENTRYP RenderMode)(GLenum mode);
+ void (QOPENGLF_APIENTRYP SelectBuffer)(GLsizei size, GLuint *buffer);
+ void (QOPENGLF_APIENTRYP FeedbackBuffer)(GLsizei size, GLenum type, GLfloat *buffer);
+ void (QOPENGLF_APIENTRYP TexGeniv)(GLenum coord, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP TexGeni)(GLenum coord, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP TexGenfv)(GLenum coord, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP TexGenf)(GLenum coord, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP TexGendv)(GLenum coord, GLenum pname, const GLdouble *params);
+ void (QOPENGLF_APIENTRYP TexGend)(GLenum coord, GLenum pname, GLdouble param);
+ void (QOPENGLF_APIENTRYP TexEnviv)(GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP TexEnvi)(GLenum target, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP TexEnvfv)(GLenum target, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP TexEnvf)(GLenum target, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP ShadeModel)(GLenum mode);
+ void (QOPENGLF_APIENTRYP PolygonStipple)(const GLubyte *mask);
+ void (QOPENGLF_APIENTRYP Materialiv)(GLenum face, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP Materiali)(GLenum face, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP Materialfv)(GLenum face, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP Materialf)(GLenum face, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP LineStipple)(GLint factor, GLushort pattern);
+ void (QOPENGLF_APIENTRYP LightModeliv)(GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP LightModeli)(GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP LightModelfv)(GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP LightModelf)(GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP Lightiv)(GLenum light, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP Lighti)(GLenum light, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP Lightfv)(GLenum light, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP Lightf)(GLenum light, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP Fogiv)(GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP Fogi)(GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP Fogfv)(GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP Fogf)(GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP ColorMaterial)(GLenum face, GLenum mode);
+ void (QOPENGLF_APIENTRYP ClipPlane)(GLenum plane, const GLdouble *equation);
+ void (QOPENGLF_APIENTRYP Vertex4sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP Vertex4s)(GLshort x, GLshort y, GLshort z, GLshort w);
+ void (QOPENGLF_APIENTRYP Vertex4iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP Vertex4i)(GLint x, GLint y, GLint z, GLint w);
+ void (QOPENGLF_APIENTRYP Vertex4fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Vertex4f)(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP Vertex4dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP Vertex4d)(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP Vertex3sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP Vertex3s)(GLshort x, GLshort y, GLshort z);
+ void (QOPENGLF_APIENTRYP Vertex3iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP Vertex3i)(GLint x, GLint y, GLint z);
+ void (QOPENGLF_APIENTRYP Vertex3fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Vertex3f)(GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP Vertex3dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP Vertex3d)(GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP Vertex2sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP Vertex2s)(GLshort x, GLshort y);
+ void (QOPENGLF_APIENTRYP Vertex2iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP Vertex2i)(GLint x, GLint y);
+ void (QOPENGLF_APIENTRYP Vertex2fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Vertex2f)(GLfloat x, GLfloat y);
+ void (QOPENGLF_APIENTRYP Vertex2dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP Vertex2d)(GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP TexCoord4sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP TexCoord4s)(GLshort s, GLshort t, GLshort r, GLshort q);
+ void (QOPENGLF_APIENTRYP TexCoord4iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP TexCoord4i)(GLint s, GLint t, GLint r, GLint q);
+ void (QOPENGLF_APIENTRYP TexCoord4fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP TexCoord4f)(GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void (QOPENGLF_APIENTRYP TexCoord4dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP TexCoord4d)(GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void (QOPENGLF_APIENTRYP TexCoord3sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP TexCoord3s)(GLshort s, GLshort t, GLshort r);
+ void (QOPENGLF_APIENTRYP TexCoord3iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP TexCoord3i)(GLint s, GLint t, GLint r);
+ void (QOPENGLF_APIENTRYP TexCoord3fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP TexCoord3f)(GLfloat s, GLfloat t, GLfloat r);
+ void (QOPENGLF_APIENTRYP TexCoord3dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP TexCoord3d)(GLdouble s, GLdouble t, GLdouble r);
+ void (QOPENGLF_APIENTRYP TexCoord2sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP TexCoord2s)(GLshort s, GLshort t);
+ void (QOPENGLF_APIENTRYP TexCoord2iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP TexCoord2i)(GLint s, GLint t);
+ void (QOPENGLF_APIENTRYP TexCoord2fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP TexCoord2f)(GLfloat s, GLfloat t);
+ void (QOPENGLF_APIENTRYP TexCoord2dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP TexCoord2d)(GLdouble s, GLdouble t);
+ void (QOPENGLF_APIENTRYP TexCoord1sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP TexCoord1s)(GLshort s);
+ void (QOPENGLF_APIENTRYP TexCoord1iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP TexCoord1i)(GLint s);
+ void (QOPENGLF_APIENTRYP TexCoord1fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP TexCoord1f)(GLfloat s);
+ void (QOPENGLF_APIENTRYP TexCoord1dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP TexCoord1d)(GLdouble s);
+ void (QOPENGLF_APIENTRYP Rectsv)(const GLshort *v1, const GLshort *v2);
+ void (QOPENGLF_APIENTRYP Rects)(GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+ void (QOPENGLF_APIENTRYP Rectiv)(const GLint *v1, const GLint *v2);
+ void (QOPENGLF_APIENTRYP Recti)(GLint x1, GLint y1, GLint x2, GLint y2);
+ void (QOPENGLF_APIENTRYP Rectfv)(const GLfloat *v1, const GLfloat *v2);
+ void (QOPENGLF_APIENTRYP Rectf)(GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+ void (QOPENGLF_APIENTRYP Rectdv)(const GLdouble *v1, const GLdouble *v2);
+ void (QOPENGLF_APIENTRYP Rectd)(GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+ void (QOPENGLF_APIENTRYP RasterPos4sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP RasterPos4s)(GLshort x, GLshort y, GLshort z, GLshort w);
+ void (QOPENGLF_APIENTRYP RasterPos4iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP RasterPos4i)(GLint x, GLint y, GLint z, GLint w);
+ void (QOPENGLF_APIENTRYP RasterPos4fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP RasterPos4f)(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP RasterPos4dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP RasterPos4d)(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP RasterPos3sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP RasterPos3s)(GLshort x, GLshort y, GLshort z);
+ void (QOPENGLF_APIENTRYP RasterPos3iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP RasterPos3i)(GLint x, GLint y, GLint z);
+ void (QOPENGLF_APIENTRYP RasterPos3fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP RasterPos3f)(GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP RasterPos3dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP RasterPos3d)(GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP RasterPos2sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP RasterPos2s)(GLshort x, GLshort y);
+ void (QOPENGLF_APIENTRYP RasterPos2iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP RasterPos2i)(GLint x, GLint y);
+ void (QOPENGLF_APIENTRYP RasterPos2fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP RasterPos2f)(GLfloat x, GLfloat y);
+ void (QOPENGLF_APIENTRYP RasterPos2dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP RasterPos2d)(GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP Normal3sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP Normal3s)(GLshort nx, GLshort ny, GLshort nz);
+ void (QOPENGLF_APIENTRYP Normal3iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP Normal3i)(GLint nx, GLint ny, GLint nz);
+ void (QOPENGLF_APIENTRYP Normal3fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Normal3f)(GLfloat nx, GLfloat ny, GLfloat nz);
+ void (QOPENGLF_APIENTRYP Normal3dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP Normal3d)(GLdouble nx, GLdouble ny, GLdouble nz);
+ void (QOPENGLF_APIENTRYP Normal3bv)(const GLbyte *v);
+ void (QOPENGLF_APIENTRYP Normal3b)(GLbyte nx, GLbyte ny, GLbyte nz);
+ void (QOPENGLF_APIENTRYP Indexsv)(const GLshort *c);
+ void (QOPENGLF_APIENTRYP Indexs)(GLshort c);
+ void (QOPENGLF_APIENTRYP Indexiv)(const GLint *c);
+ void (QOPENGLF_APIENTRYP Indexi)(GLint c);
+ void (QOPENGLF_APIENTRYP Indexfv)(const GLfloat *c);
+ void (QOPENGLF_APIENTRYP Indexf)(GLfloat c);
+ void (QOPENGLF_APIENTRYP Indexdv)(const GLdouble *c);
+ void (QOPENGLF_APIENTRYP Indexd)(GLdouble c);
+ void (QOPENGLF_APIENTRYP End)();
+ void (QOPENGLF_APIENTRYP EdgeFlagv)(const GLboolean *flag);
+ void (QOPENGLF_APIENTRYP EdgeFlag)(GLboolean flag);
+ void (QOPENGLF_APIENTRYP Color4usv)(const GLushort *v);
+ void (QOPENGLF_APIENTRYP Color4us)(GLushort red, GLushort green, GLushort blue, GLushort alpha);
+ void (QOPENGLF_APIENTRYP Color4uiv)(const GLuint *v);
+ void (QOPENGLF_APIENTRYP Color4ui)(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void (QOPENGLF_APIENTRYP Color4ubv)(const GLubyte *v);
+ void (QOPENGLF_APIENTRYP Color4ub)(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+ void (QOPENGLF_APIENTRYP Color4sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP Color4s)(GLshort red, GLshort green, GLshort blue, GLshort alpha);
+ void (QOPENGLF_APIENTRYP Color4iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP Color4i)(GLint red, GLint green, GLint blue, GLint alpha);
+ void (QOPENGLF_APIENTRYP Color4fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Color4f)(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+ void (QOPENGLF_APIENTRYP Color4dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP Color4d)(GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+ void (QOPENGLF_APIENTRYP Color4bv)(const GLbyte *v);
+ void (QOPENGLF_APIENTRYP Color4b)(GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+ void (QOPENGLF_APIENTRYP Color3usv)(const GLushort *v);
+ void (QOPENGLF_APIENTRYP Color3us)(GLushort red, GLushort green, GLushort blue);
+ void (QOPENGLF_APIENTRYP Color3uiv)(const GLuint *v);
+ void (QOPENGLF_APIENTRYP Color3ui)(GLuint red, GLuint green, GLuint blue);
+ void (QOPENGLF_APIENTRYP Color3ubv)(const GLubyte *v);
+ void (QOPENGLF_APIENTRYP Color3ub)(GLubyte red, GLubyte green, GLubyte blue);
+ void (QOPENGLF_APIENTRYP Color3sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP Color3s)(GLshort red, GLshort green, GLshort blue);
+ void (QOPENGLF_APIENTRYP Color3iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP Color3i)(GLint red, GLint green, GLint blue);
+ void (QOPENGLF_APIENTRYP Color3fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Color3f)(GLfloat red, GLfloat green, GLfloat blue);
+ void (QOPENGLF_APIENTRYP Color3dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP Color3d)(GLdouble red, GLdouble green, GLdouble blue);
+ void (QOPENGLF_APIENTRYP Color3bv)(const GLbyte *v);
+ void (QOPENGLF_APIENTRYP Color3b)(GLbyte red, GLbyte green, GLbyte blue);
+ void (QOPENGLF_APIENTRYP Bitmap)(GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte *bitmap);
+ void (QOPENGLF_APIENTRYP Begin)(GLenum mode);
+ void (QOPENGLF_APIENTRYP ListBase)(GLuint base);
+ GLuint (QOPENGLF_APIENTRYP GenLists)(GLsizei range);
+ void (QOPENGLF_APIENTRYP DeleteLists)(GLuint list, GLsizei range);
+ void (QOPENGLF_APIENTRYP CallLists)(GLsizei n, GLenum type, const GLvoid *lists);
+ void (QOPENGLF_APIENTRYP CallList)(GLuint list);
+ void (QOPENGLF_APIENTRYP EndList)();
+ void (QOPENGLF_APIENTRYP NewList)(GLuint list, GLenum mode);
+
+};
+
+class QOpenGLFunctions_1_1_DeprecatedBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_1_1_DeprecatedBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 1.1 deprecated functions
+ void (QOPENGLF_APIENTRYP PushClientAttrib)(GLbitfield mask);
+ void (QOPENGLF_APIENTRYP PopClientAttrib)();
+ void (QOPENGLF_APIENTRYP PrioritizeTextures)(GLsizei n, const GLuint *textures, const GLfloat *priorities);
+ GLboolean (QOPENGLF_APIENTRYP AreTexturesResident)(GLsizei n, const GLuint *textures, GLboolean *residences);
+ void (QOPENGLF_APIENTRYP VertexPointer)(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP TexCoordPointer)(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP NormalPointer)(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP InterleavedArrays)(GLenum format, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP IndexPointer)(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP EnableClientState)(GLenum array);
+ void (QOPENGLF_APIENTRYP EdgeFlagPointer)(GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP DisableClientState)(GLenum array);
+ void (QOPENGLF_APIENTRYP ColorPointer)(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP ArrayElement)(GLint i);
+
+};
+
+class QOpenGLFunctions_1_2_DeprecatedBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_1_2_DeprecatedBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 1.2 deprecated functions
+ void (QOPENGLF_APIENTRYP ResetMinmax)(GLenum target);
+ void (QOPENGLF_APIENTRYP ResetHistogram)(GLenum target);
+ void (QOPENGLF_APIENTRYP Minmax)(GLenum target, GLenum internalformat, GLboolean sink);
+ void (QOPENGLF_APIENTRYP Histogram)(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void (QOPENGLF_APIENTRYP GetMinmaxParameteriv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetMinmaxParameterfv)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetMinmax)(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void (QOPENGLF_APIENTRYP GetHistogramParameteriv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetHistogramParameterfv)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetHistogram)(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void (QOPENGLF_APIENTRYP SeparableFilter2D)(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void (QOPENGLF_APIENTRYP GetSeparableFilter)(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void (QOPENGLF_APIENTRYP GetConvolutionParameteriv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetConvolutionParameterfv)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetConvolutionFilter)(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void (QOPENGLF_APIENTRYP CopyConvolutionFilter2D)(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP CopyConvolutionFilter1D)(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void (QOPENGLF_APIENTRYP ConvolutionParameteriv)(GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP ConvolutionParameteri)(GLenum target, GLenum pname, GLint params);
+ void (QOPENGLF_APIENTRYP ConvolutionParameterfv)(GLenum target, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP ConvolutionParameterf)(GLenum target, GLenum pname, GLfloat params);
+ void (QOPENGLF_APIENTRYP ConvolutionFilter2D)(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void (QOPENGLF_APIENTRYP ConvolutionFilter1D)(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+ void (QOPENGLF_APIENTRYP CopyColorSubTable)(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void (QOPENGLF_APIENTRYP ColorSubTable)(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP GetColorTableParameteriv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetColorTableParameterfv)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetColorTable)(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void (QOPENGLF_APIENTRYP CopyColorTable)(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void (QOPENGLF_APIENTRYP ColorTableParameteriv)(GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP ColorTableParameterfv)(GLenum target, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP ColorTable)(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+};
+
+class QOpenGLFunctions_1_3_DeprecatedBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_1_3_DeprecatedBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 1.3 deprecated functions
+ void (QOPENGLF_APIENTRYP MultTransposeMatrixd)(const GLdouble *m);
+ void (QOPENGLF_APIENTRYP MultTransposeMatrixf)(const GLfloat *m);
+ void (QOPENGLF_APIENTRYP LoadTransposeMatrixd)(const GLdouble *m);
+ void (QOPENGLF_APIENTRYP LoadTransposeMatrixf)(const GLfloat *m);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4sv)(GLenum target, const GLshort *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4s)(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4iv)(GLenum target, const GLint *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4i)(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4fv)(GLenum target, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4f)(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4dv)(GLenum target, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4d)(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3sv)(GLenum target, const GLshort *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3s)(GLenum target, GLshort s, GLshort t, GLshort r);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3iv)(GLenum target, const GLint *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3i)(GLenum target, GLint s, GLint t, GLint r);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3fv)(GLenum target, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3f)(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3dv)(GLenum target, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3d)(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2sv)(GLenum target, const GLshort *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2s)(GLenum target, GLshort s, GLshort t);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2iv)(GLenum target, const GLint *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2i)(GLenum target, GLint s, GLint t);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2fv)(GLenum target, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2f)(GLenum target, GLfloat s, GLfloat t);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2dv)(GLenum target, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2d)(GLenum target, GLdouble s, GLdouble t);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1sv)(GLenum target, const GLshort *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1s)(GLenum target, GLshort s);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1iv)(GLenum target, const GLint *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1i)(GLenum target, GLint s);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1fv)(GLenum target, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1f)(GLenum target, GLfloat s);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1dv)(GLenum target, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1d)(GLenum target, GLdouble s);
+ void (QOPENGLF_APIENTRYP ClientActiveTexture)(GLenum texture);
+
+};
+
+class QOpenGLFunctions_1_4_DeprecatedBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_1_4_DeprecatedBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 1.4 deprecated functions
+ void (QOPENGLF_APIENTRYP WindowPos3sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP WindowPos3s)(GLshort x, GLshort y, GLshort z);
+ void (QOPENGLF_APIENTRYP WindowPos3iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP WindowPos3i)(GLint x, GLint y, GLint z);
+ void (QOPENGLF_APIENTRYP WindowPos3fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP WindowPos3f)(GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP WindowPos3dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP WindowPos3d)(GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP WindowPos2sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP WindowPos2s)(GLshort x, GLshort y);
+ void (QOPENGLF_APIENTRYP WindowPos2iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP WindowPos2i)(GLint x, GLint y);
+ void (QOPENGLF_APIENTRYP WindowPos2fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP WindowPos2f)(GLfloat x, GLfloat y);
+ void (QOPENGLF_APIENTRYP WindowPos2dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP WindowPos2d)(GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP SecondaryColorPointer)(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP SecondaryColor3usv)(const GLushort *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3us)(GLushort red, GLushort green, GLushort blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3uiv)(const GLuint *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3ui)(GLuint red, GLuint green, GLuint blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3ubv)(const GLubyte *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3ub)(GLubyte red, GLubyte green, GLubyte blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3sv)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3s)(GLshort red, GLshort green, GLshort blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3iv)(const GLint *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3i)(GLint red, GLint green, GLint blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3fv)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3f)(GLfloat red, GLfloat green, GLfloat blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3dv)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3d)(GLdouble red, GLdouble green, GLdouble blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3bv)(const GLbyte *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3b)(GLbyte red, GLbyte green, GLbyte blue);
+ void (QOPENGLF_APIENTRYP FogCoordPointer)(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP FogCoorddv)(const GLdouble *coord);
+ void (QOPENGLF_APIENTRYP FogCoordd)(GLdouble coord);
+ void (QOPENGLF_APIENTRYP FogCoordfv)(const GLfloat *coord);
+ void (QOPENGLF_APIENTRYP FogCoordf)(GLfloat coord);
+
+};
+
+class QOpenGLFunctions_2_0_DeprecatedBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_2_0_DeprecatedBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 2.0 deprecated functions
+ void (QOPENGLF_APIENTRYP VertexAttrib4usv)(GLuint index, const GLushort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4uiv)(GLuint index, const GLuint *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4ubv)(GLuint index, const GLubyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4sv)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4s)(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void (QOPENGLF_APIENTRYP VertexAttrib4iv)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4fv)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4f)(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP VertexAttrib4dv)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4d)(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP VertexAttrib4bv)(GLuint index, const GLbyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4Nusv)(GLuint index, const GLushort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4Nuiv)(GLuint index, const GLuint *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4Nubv)(GLuint index, const GLubyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4Nub)(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void (QOPENGLF_APIENTRYP VertexAttrib4Nsv)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4Niv)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4Nbv)(GLuint index, const GLbyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib3sv)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib3s)(GLuint index, GLshort x, GLshort y, GLshort z);
+ void (QOPENGLF_APIENTRYP VertexAttrib3fv)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib3f)(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP VertexAttrib3dv)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib3d)(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP VertexAttrib2sv)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib2s)(GLuint index, GLshort x, GLshort y);
+ void (QOPENGLF_APIENTRYP VertexAttrib2fv)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib2f)(GLuint index, GLfloat x, GLfloat y);
+ void (QOPENGLF_APIENTRYP VertexAttrib2dv)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib2d)(GLuint index, GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP VertexAttrib1sv)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib1s)(GLuint index, GLshort x);
+ void (QOPENGLF_APIENTRYP VertexAttrib1fv)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib1f)(GLuint index, GLfloat x);
+ void (QOPENGLF_APIENTRYP VertexAttrib1dv)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib1d)(GLuint index, GLdouble x);
+
+};
+
+class QOpenGLFunctions_3_0_DeprecatedBackend : public QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLFunctions_3_0_DeprecatedBackend(QOpenGLContext *context);
+
+ static QOpenGLVersionStatus versionStatus();
+
+ // OpenGL 3.0 deprecated functions
+ void (QOPENGLF_APIENTRYP VertexAttribI4usv)(GLuint index, const GLushort *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI4ubv)(GLuint index, const GLubyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI4sv)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI4bv)(GLuint index, const GLbyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI4uiv)(GLuint index, const GLuint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI3uiv)(GLuint index, const GLuint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI2uiv)(GLuint index, const GLuint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI1uiv)(GLuint index, const GLuint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI4iv)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI3iv)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI2iv)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI1iv)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI4ui)(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void (QOPENGLF_APIENTRYP VertexAttribI3ui)(GLuint index, GLuint x, GLuint y, GLuint z);
+ void (QOPENGLF_APIENTRYP VertexAttribI2ui)(GLuint index, GLuint x, GLuint y);
+ void (QOPENGLF_APIENTRYP VertexAttribI1ui)(GLuint index, GLuint x);
+ void (QOPENGLF_APIENTRYP VertexAttribI4i)(GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void (QOPENGLF_APIENTRYP VertexAttribI3i)(GLuint index, GLint x, GLint y, GLint z);
+ void (QOPENGLF_APIENTRYP VertexAttribI2i)(GLuint index, GLint x, GLint y);
+ void (QOPENGLF_APIENTRYP VertexAttribI1i)(GLuint index, GLint x);
+
+};
+
+
+#else
+
+// No need for backend classes with function pointers with ES2.
+// All function addresses are independent of context and display.
+
+#endif // !QT_OPENGL_ES_2
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL
+
+#endif
diff --git a/src/gui/opengl/qopenglversionfunctionsfactory.cpp b/src/gui/opengl/qopenglversionfunctionsfactory.cpp
new file mode 100644
index 0000000000..fed2c1537a
--- /dev/null
+++ b/src/gui/opengl/qopenglversionfunctionsfactory.cpp
@@ -0,0 +1,153 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglversionfunctionsfactory_p.h"
+
+#if !defined(QT_OPENGL_ES_2)
+#include "qopenglfunctions_4_3_core.h"
+#include "qopenglfunctions_4_3_compatibility.h"
+#include "qopenglfunctions_4_2_core.h"
+#include "qopenglfunctions_4_2_compatibility.h"
+#include "qopenglfunctions_4_1_core.h"
+#include "qopenglfunctions_4_1_compatibility.h"
+#include "qopenglfunctions_4_0_core.h"
+#include "qopenglfunctions_4_0_compatibility.h"
+#include "qopenglfunctions_3_3_core.h"
+#include "qopenglfunctions_3_3_compatibility.h"
+#include "qopenglfunctions_3_2_core.h"
+#include "qopenglfunctions_3_2_compatibility.h"
+#include "qopenglfunctions_3_1.h"
+#include "qopenglfunctions_3_0.h"
+#include "qopenglfunctions_2_1.h"
+#include "qopenglfunctions_2_0.h"
+#include "qopenglfunctions_1_5.h"
+#include "qopenglfunctions_1_4.h"
+#include "qopenglfunctions_1_3.h"
+#include "qopenglfunctions_1_2.h"
+#include "qopenglfunctions_1_1.h"
+#include "qopenglfunctions_1_0.h"
+#else
+#include "qopenglfunctions_es2.h"
+#endif
+
+QT_BEGIN_NAMESPACE
+
+QAbstractOpenGLFunctions *QOpenGLVersionFunctionsFactory::create(const QOpenGLVersionProfile &versionProfile)
+{
+#if !defined(QT_OPENGL_ES_2)
+ const int major = versionProfile.version().first;
+ const int minor = versionProfile.version().second;
+
+ if (versionProfile.hasProfiles()) {
+ switch (versionProfile.profile()) {
+ case QSurfaceFormat::CoreProfile:
+ if (major == 4 && minor == 3)
+ return new QOpenGLFunctions_4_3_Core;
+ else if (major == 4 && minor == 2)
+ return new QOpenGLFunctions_4_2_Core;
+ else if (major == 4 && minor == 1)
+ return new QOpenGLFunctions_4_1_Core;
+ else if (major == 4 && minor == 0)
+ return new QOpenGLFunctions_4_0_Core;
+ else if (major == 3 && minor == 3)
+ return new QOpenGLFunctions_3_3_Core;
+ else if (major == 3 && minor == 2)
+ return new QOpenGLFunctions_3_2_Core;
+ break;
+
+ case QSurfaceFormat::CompatibilityProfile:
+ if (major == 4 && minor == 3)
+ return new QOpenGLFunctions_4_3_Compatibility;
+ else if (major == 4 && minor == 2)
+ return new QOpenGLFunctions_4_2_Compatibility;
+ else if (major == 4 && minor == 1)
+ return new QOpenGLFunctions_4_1_Compatibility;
+ else if (major == 4 && minor == 0)
+ return new QOpenGLFunctions_4_0_Compatibility;
+ else if (major == 3 && minor == 3)
+ return new QOpenGLFunctions_3_3_Compatibility;
+ else if (major == 3 && minor == 2)
+ return new QOpenGLFunctions_3_2_Compatibility;
+ break;
+
+ case QSurfaceFormat::NoProfile:
+ default:
+ break;
+ };
+ } else {
+ if (major == 3 && minor == 1)
+ return new QOpenGLFunctions_3_1;
+ else if (major == 3 && minor == 0)
+ return new QOpenGLFunctions_3_0;
+ else if (major == 2 && minor == 1)
+ return new QOpenGLFunctions_2_1;
+ else if (major == 2 && minor == 0)
+ return new QOpenGLFunctions_2_0;
+ else if (major == 1 && minor == 5)
+ return new QOpenGLFunctions_1_5;
+ else if (major == 1 && minor == 4)
+ return new QOpenGLFunctions_1_4;
+ else if (major == 1 && minor == 3)
+ return new QOpenGLFunctions_1_3;
+ else if (major == 1 && minor == 2)
+ return new QOpenGLFunctions_1_2;
+ else if (major == 1 && minor == 1)
+ return new QOpenGLFunctions_1_1;
+ else if (major == 1 && minor == 0)
+ return new QOpenGLFunctions_1_0;
+ }
+ return 0;
+#else
+ Q_UNUSED(versionProfile);
+ return new QOpenGLFunctions_ES2;
+#endif
+}
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglversionfunctionsfactory_p.h b/src/gui/opengl/qopenglversionfunctionsfactory_p.h
new file mode 100644
index 0000000000..2312e900f9
--- /dev/null
+++ b/src/gui/opengl/qopenglversionfunctionsfactory_p.h
@@ -0,0 +1,73 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2012 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONFACTORY_P_H
+#define QOPENGLVERSIONFUNCTIONFACTORY_P_H
+
+#ifndef QT_NO_OPENGL
+
+#include <QtCore/QtGlobal>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class QAbstractOpenGLFunctions;
+
+class QOpenGLVersionFunctionsFactory
+{
+public:
+ static QAbstractOpenGLFunctions *create(const QOpenGLVersionProfile &versionProfile);
+};
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL
+
+#endif
diff --git a/src/gui/opengl/qopenglvertexarrayobject.cpp b/src/gui/opengl/qopenglvertexarrayobject.cpp
new file mode 100644
index 0000000000..e450fe708f
--- /dev/null
+++ b/src/gui/opengl/qopenglvertexarrayobject.cpp
@@ -0,0 +1,473 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qopenglvertexarrayobject.h"
+
+#include <QtCore/private/qobject_p.h>
+#include <QtGui/qopenglcontext.h>
+
+#if !defined(QT_OPENGL_ES_2)
+#include <QtGui/qopenglfunctions_3_0.h>
+#include <QtGui/qopenglfunctions_3_2_core.h>
+#endif
+
+QT_BEGIN_NAMESPACE
+
+class QVertexArrayObjectHelper
+{
+public:
+ QVertexArrayObjectHelper(QOpenGLContext *context)
+ {
+ Q_ASSERT(context);
+#if !defined(QT_OPENGL_ES_2)
+ GenVertexArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenVertexArrays"));
+ DeleteVertexArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteVertexArrays"));
+ BindVertexArray = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glBindVertexArray"));
+#else
+ GenVertexArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenVertexArraysOES"));
+ DeleteVertexArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteVertexArraysOES"));
+ BindVertexArray = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glBindVertexArrayOES"));
+#endif
+ }
+
+ inline void glGenVertexArrays(GLsizei n, GLuint *arrays)
+ {
+ GenVertexArrays(n, arrays);
+ }
+
+ inline void glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+ {
+ DeleteVertexArrays(n, arrays);
+ }
+
+ inline void glBindVertexArray(GLuint array)
+ {
+ BindVertexArray(array);
+ }
+
+private:
+ // Function signatures are equivalent between desktop core, ARB and ES 2 extensions
+ void (QOPENGLF_APIENTRYP GenVertexArrays)(GLsizei n, GLuint *arrays);
+ void (QOPENGLF_APIENTRYP DeleteVertexArrays)(GLsizei n, const GLuint *arrays);
+ void (QOPENGLF_APIENTRYP BindVertexArray)(GLuint array);
+};
+
+class QOpenGLVertexArrayObjectPrivate : public QObjectPrivate
+{
+public:
+ QOpenGLVertexArrayObjectPrivate()
+ : vao(0)
+#if defined(QT_OPENGL_ES_2)
+ , vaoFuncs(0)
+#else
+ , vaoFuncsType(NotSupported)
+#endif
+ , context(0)
+ {
+ }
+
+ ~QOpenGLVertexArrayObjectPrivate()
+ {
+#if defined(QT_OPENGL_ES_2)
+ delete vaoFuncs;
+#else
+ if (vaoFuncsType == ARB)
+ delete vaoFuncs.arb;
+#endif
+ }
+
+ bool create();
+ void destroy();
+ void bind();
+ void release();
+
+ GLuint vao;
+
+#if defined(QT_OPENGL_ES_2)
+ QVertexArrayObjectHelper *vaoFuncs;
+#else
+ union {
+ QOpenGLFunctions_3_0 *core_3_0;
+ QOpenGLFunctions_3_2_Core *core_3_2;
+ QVertexArrayObjectHelper *arb;
+ } vaoFuncs;
+ enum {
+ NotSupported,
+ Core_3_0,
+ Core_3_2,
+ ARB
+ } vaoFuncsType;
+#endif
+ QOpenGLContext *context;
+};
+
+bool QOpenGLVertexArrayObjectPrivate::create()
+{
+ QOpenGLContext *ctx = QOpenGLContext::currentContext();
+ if (!ctx) {
+ qWarning("QOpenGLVertexArrayObject::create() requires a valid current OpenGL context");
+ return false;
+ }
+ context = ctx;
+
+#if defined(QT_OPENGL_ES_2)
+ if (ctx->hasExtension("GL_OES_vertex_array_object")) {
+ vaoFuncs = new QVertexArrayObjectHelper(ctx);
+ vaoFuncs->glGenVertexArrays(1, &vao);
+ }
+#else
+ vaoFuncs.core_3_0 = 0;
+ vaoFuncsType = NotSupported;
+ QSurfaceFormat format = ctx->format();
+ if (format.version() >= qMakePair<int, int>(3,2)) {
+ vaoFuncs.core_3_2 = ctx->versionFunctions<QOpenGLFunctions_3_2_Core>();
+ vaoFuncsType = Core_3_2;
+ vaoFuncs.core_3_2->initializeOpenGLFunctions();
+ vaoFuncs.core_3_2->glGenVertexArrays(1, &vao);
+ } else if (format.majorVersion() >= 3) {
+ vaoFuncs.core_3_0 = ctx->versionFunctions<QOpenGLFunctions_3_0>();
+ vaoFuncsType = Core_3_0;
+ vaoFuncs.core_3_0->initializeOpenGLFunctions();
+ vaoFuncs.core_3_0->glGenVertexArrays(1, &vao);
+ } else if (ctx->hasExtension("GL_ARB_vertex_array_object")) {
+ vaoFuncs.arb = new QVertexArrayObjectHelper(ctx);
+ vaoFuncsType = ARB;
+ vaoFuncs.arb->glGenVertexArrays(1, &vao);
+ }
+#endif
+ return (vao != 0);
+}
+
+void QOpenGLVertexArrayObjectPrivate::destroy()
+{
+ if (!vao)
+ return;
+#if defined(QT_OPENGL_ES_2)
+ if (vaoFuncs)
+ vaoFuncs->glDeleteVertexArrays(1, &vao);
+#else
+ switch (vaoFuncsType) {
+ case Core_3_2:
+ vaoFuncs.core_3_2->glDeleteVertexArrays(1, &vao);
+ break;
+ case Core_3_0:
+ vaoFuncs.core_3_0->glDeleteVertexArrays(1, &vao);
+ break;
+ case ARB:
+ vaoFuncs.arb->glDeleteVertexArrays(1, &vao);
+ break;
+ case NotSupported:
+ break;
+ }
+ vao = 0;
+#endif
+}
+
+void QOpenGLVertexArrayObjectPrivate::bind()
+{
+#if defined(QT_OPENGL_ES_2)
+ if (vaoFuncs)
+ vaoFuncs->glBindVertexArray(vao);
+#else
+ switch (vaoFuncsType) {
+ case Core_3_2:
+ vaoFuncs.core_3_2->glBindVertexArray(vao);
+ break;
+ case Core_3_0:
+ vaoFuncs.core_3_0->glBindVertexArray(vao);
+ break;
+ case ARB:
+ vaoFuncs.arb->glBindVertexArray(vao);
+ break;
+ case NotSupported:
+ break;
+ }
+#endif
+}
+
+void QOpenGLVertexArrayObjectPrivate::release()
+{
+#if defined(QT_OPENGL_ES_2)
+ if (vaoFuncs)
+ vaoFuncs->glBindVertexArray(0);
+#else
+ switch (vaoFuncsType) {
+ case Core_3_2:
+ vaoFuncs.core_3_2->glBindVertexArray(0);
+ break;
+ case Core_3_0:
+ vaoFuncs.core_3_0->glBindVertexArray(0);
+ break;
+ case ARB:
+ vaoFuncs.arb->glBindVertexArray(0);
+ break;
+ case NotSupported:
+ break;
+ }
+#endif
+}
+
+
+/*!
+ \class QOpenGLVertexArrayObject
+ \brief The QOpenGLVertexArrayObject class wraps an OpenGL Vertex Array Object.
+ \inmodule QtGui
+ \since 5.1
+ \ingroup painting-3D
+
+ A Vertex Array Object (VAO) is an OpenGL container object that encapsulates
+ the state needed to specify per-vertex attribute data to the OpenGL pipeline.
+ To put it another way, a VAO remembers the states of buffer objects (see
+ QOpenGLBuffer) and their associated state (e.g. vertex attribute divisors).
+ This allows a very easy and efficient method of switching between OpenGL buffer
+ states for rendering different "objects" in a scene. The QOpenGLVertexArrayObject
+ class is a thin wrapper around an OpenGL VAO.
+
+ For the desktop, VAOs are supported as a core feature in OpenGL 3.0 or newer and by the
+ GL_ARB_vertex_array_object for older versions. On OpenGL ES 2, VAOs are provided by
+ the optional GL_OES_vertex_array_object extension. You can check the version of
+ OpenGL with QOpenGLContext::surfaceFormat() and check for the presence of extensions
+ with QOpenGLContext::hasExtension().
+
+ As with the other Qt OpenGL classes, QOpenGLVertexArrayObject has a create()
+ function to create the underlying OpenGL object. This is to allow the developer to
+ ensure that there is a valid current OpenGL context at the time.
+
+ Once you have successfully created a VAO the typical usage pattern is:
+
+ \list
+ \li In scene initialization function, for each visual object:
+ \list
+ \li Bind the VAO
+ \li Set vertex data state for this visual object (vertices, normals, texture coordinates etc.)
+ \li Unbind (release()) the VAO
+ \endlist
+ \li In render function, for each visual object:
+ \list
+ \li Bind the VAO (and shader program if needed)
+ \li Call a glDraw*() function
+ \li Unbind (release()) the VAO
+ \endlist
+ \endlist
+
+ The act of binding the VAO in the render function has the effect of restoring
+ all of the vertex data state setup in the initialization phase. In this way we can
+ set a great deal of state when setting up a VAO and efficiently switch between
+ state sets of objects to be rendered. Using VAOs also allows the OpenGL driver
+ to amortise the validation checks of the vertex data.
+
+ \note Vertex Array Objects, like all other OpenGL container objects, are specific
+ to the context for which they were created and cannot be shared amongst a
+ context group.
+
+ \sa QOpenGLVertexArrayObject::Binder, QOpenGLBuffer
+*/
+
+/*!
+ Creates a QOpenGLVertexArrayObject with the given \a parent. You must call create()
+ with a valid OpenGL context before using.
+*/
+QOpenGLVertexArrayObject::QOpenGLVertexArrayObject(QObject* parent)
+ : QObject(*new QOpenGLVertexArrayObjectPrivate, parent)
+{
+}
+
+/*!
+ \internal
+*/
+QOpenGLVertexArrayObject::QOpenGLVertexArrayObject(QOpenGLVertexArrayObjectPrivate &dd)
+ : QObject(dd)
+{
+}
+
+/*!
+ Destroys the QOpenGLVertexArrayObject and the underlying OpenGL resource.
+*/
+QOpenGLVertexArrayObject::~QOpenGLVertexArrayObject()
+{
+ QOpenGLContext* ctx = QOpenGLContext::currentContext();
+
+ Q_D(QOpenGLVertexArrayObject);
+ QOpenGLContext *oldContext = 0;
+ if (d->context && d->context != ctx) {
+ oldContext = ctx;
+ if (d->context->makeCurrent(oldContext->surface())) {
+ ctx = d->context;
+ } else {
+ qWarning("QOpenGLVertexArrayObject::~QOpenGLVertexArrayObject() failed to make VAO's context current");
+ ctx = 0;
+ }
+ }
+
+ if (ctx)
+ destroy();
+
+ if (oldContext) {
+ if (!oldContext->makeCurrent(oldContext->surface()))
+ qWarning("QOpenGLVertexArrayObject::~QOpenGLVertexArrayObject() failed to restore current context");
+ }
+}
+
+/*!
+ Creates the underlying OpenGL vertex array object. There must be a valid OpenGL context
+ that supports vertex array objects current for this function to succeed.
+
+ Returns true if the OpenGL vertex array object was successfully created.
+*/
+bool QOpenGLVertexArrayObject::create()
+{
+ Q_D(QOpenGLVertexArrayObject);
+ return d->create();
+}
+
+/*!
+ Destroys the underlying OpenGL vertex array object. There must be a valid OpenGL context
+ that supports vertex array objects current for this function to succeed.
+*/
+void QOpenGLVertexArrayObject::destroy()
+{
+ Q_D(QOpenGLVertexArrayObject);
+ d->destroy();
+}
+
+/*!
+ Returns true is the underlying OpenGL vertex array object has been created. If this
+ returns true and the associated OpenGL context is current, then you are able to bind()
+ this object.
+*/
+bool QOpenGLVertexArrayObject::isCreated() const
+{
+ Q_D(const QOpenGLVertexArrayObject);
+ return (d->vao != 0);
+}
+
+/*!
+ Returns the id of the underlying OpenGL vertex array object.
+*/
+GLuint QOpenGLVertexArrayObject::objectId() const
+{
+ Q_D(const QOpenGLVertexArrayObject);
+ return d->vao;
+}
+
+/*!
+ Binds this vertex array object to the OpenGL binding point. From this point on
+ and until release() is called or another vertex array object is bound, any
+ modifications made to vertex data state are stored inside this vertex array object.
+
+ If another vertex array object is then bound you can later restore the set of
+ state associated with this object by calling bind() on this object once again.
+ This allows efficient changes between vertex data states in rendering functions.
+*/
+void QOpenGLVertexArrayObject::bind()
+{
+ Q_D(QOpenGLVertexArrayObject);
+ d->bind();
+}
+
+/*!
+ Unbinds this vertex array object by binding the default vertex array object (id = 0).
+*/
+void QOpenGLVertexArrayObject::release()
+{
+ Q_D(QOpenGLVertexArrayObject);
+ d->release();
+}
+
+
+/*!
+ \class QOpenGLVertexArrayObject::Binder
+ \brief The QOpenGLVertexArrayObject::Binder class is a convenience class to help
+ with the binding and releasing of OpenGL Vertex Array Objects.
+ \inmodule QtGui
+ \reentrant
+ \since 5.1
+ \ingroup painting-3D
+
+ QOpenGLVertexArrayObject::Binder is a simple convenience class that can be used
+ to assist with the binding and releasing of QOpenGLVertexArrayObject instances.
+ This class is to QOpenGLVertexArrayObject as QMutexLocker is to QMutex.
+
+ This class implements the RAII principle which helps to ensure behavior in
+ complex code or in the presence of exceptions.
+
+ The constructor of this class accepts a QOpenGLVertexArrayObject (VAO) as an
+ argument and attempts to bind the VAO, calling QOpenGLVertexArrayObject::create()
+ if necessary. The destructor of this class calls QOpenGLVertexArrayObject::release()
+ which unbinds the VAO.
+
+ If needed the VAO can be temporarily unbound with the release() function and bound
+ once more with rebind().
+
+ \sa QOpenGLVertexArrayObject
+*/
+
+/*!
+ \fn QOpenGLVertexArrayObject::Binder::Binder(QOpenGLVertexArrayObject *v)
+
+ Creates a QOpenGLVertexArrayObject::Binder object and binds \a v by calling
+ QOpenGLVertexArrayObject::bind(). If necessary it first calls
+ QOpenGLVertexArrayObject::create().
+*/
+
+/*!
+ \fn QOpenGLVertexArrayObject::Binder::~Binder()
+
+ Destroys the QOpenGLVertexArrayObject::Binder and releases the associated vertex array object.
+*/
+
+/*!
+ \fn QOpenGLVertexArrayObject::Binder::release()
+
+ Can be used to temporarily release the associated vertex array object.
+
+ \sa rebind()
+*/
+
+/*!
+ \fn QOpenGLVertexArrayObject::Binder::rebind()
+
+ Can be used to rebind the associated vertex array object.
+
+ \sa release()
+*/
+
+QT_END_NAMESPACE
diff --git a/src/gui/opengl/qopenglvertexarrayobject.h b/src/gui/opengl/qopenglvertexarrayobject.h
new file mode 100644
index 0000000000..d5226d3ebd
--- /dev/null
+++ b/src/gui/opengl/qopenglvertexarrayobject.h
@@ -0,0 +1,110 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERTEXARRAYOBJECT_H
+#define QOPENGLVERTEXARRAYOBJECT_H
+
+#ifndef QT_NO_OPENGL
+
+#include <QtCore/QObject>
+#include <QtGui/qopengl.h>
+
+QT_BEGIN_NAMESPACE
+
+class QOpenGLVertexArrayObjectPrivate;
+
+class Q_GUI_EXPORT QOpenGLVertexArrayObject : public QObject
+{
+ Q_OBJECT
+
+public:
+ explicit QOpenGLVertexArrayObject(QObject* parent = 0);
+ ~QOpenGLVertexArrayObject();
+
+ bool create();
+ void destroy();
+ bool isCreated() const;
+ GLuint objectId() const;
+ void bind();
+ void release();
+
+ class Q_GUI_EXPORT Binder
+ {
+ public:
+ inline Binder(QOpenGLVertexArrayObject *v)
+ : vao(v)
+ {
+ Q_ASSERT(v);
+ if (vao->isCreated() || vao->create())
+ vao->bind();
+ }
+
+ inline ~Binder()
+ {
+ release();
+ }
+
+ inline void release()
+ {
+ vao->release();
+ }
+
+ inline void rebind()
+ {
+ vao->bind();
+ }
+
+ private:
+ Q_DISABLE_COPY(Binder)
+ QOpenGLVertexArrayObject *vao;
+ };
+
+private:
+ Q_DISABLE_COPY(QOpenGLVertexArrayObject)
+ Q_DECLARE_PRIVATE(QOpenGLVertexArrayObject)
+ QOpenGLVertexArrayObject(QOpenGLVertexArrayObjectPrivate &dd);
+};
+
+QT_END_NAMESPACE
+
+#endif
+
+#endif // QOPENGLVERTEXARRAYOBJECT_H
diff --git a/src/gui/opengl/qtriangulator.cpp b/src/gui/opengl/qtriangulator.cpp
index 83c7c93fdf..d3c80e264f 100644
--- a/src/gui/opengl/qtriangulator.cpp
+++ b/src/gui/opengl/qtriangulator.cpp
@@ -370,7 +370,7 @@ bool QIntersectionPoint::isOnLine(const QPodPoint &u, const QPodPoint &v) const
if (((q.x < 0) == (q.y < 0)) != ((p.x < 0) == (p.y < 0)))
return false; // 'p + offset' and 'q' pass through different quadrants.
-
+
// Move all coordinates into the first quadrant.
quint64 nx, ny;
if (p.x < 0)
@@ -991,7 +991,7 @@ void QTriangulator<T>::ComplexToSimple::initEdges()
if (first != m_edges.size())
m_edges.last().to = m_edges.at(first).from;
for (int i = 0; i < m_edges.size(); ++i) {
- m_edges.at(i).originallyPointingUp = m_edges.at(i).pointingUp =
+ m_edges.at(i).originallyPointingUp = m_edges.at(i).pointingUp =
m_parent->m_vertices.at(m_edges.at(i).to) < m_parent->m_vertices.at(m_edges.at(i).from);
}
}
@@ -1646,7 +1646,7 @@ QTriangulator<T>::ComplexToSimple::DebugDialog::DebugDialog(ComplexToSimple *par
QDataBuffer<QPodPoint> &vertices = m_parent->m_parent->m_vertices;
if (vertices.isEmpty())
return;
-
+
int minX, maxX, minY, maxY;
minX = maxX = vertices.at(0).x;
minY = maxY = vertices.at(0).y;
@@ -1671,7 +1671,7 @@ void QTriangulator<T>::ComplexToSimple::DebugDialog::paintEvent(QPaintEvent *)
QDataBuffer<QPodPoint> &vertices = m_parent->m_parent->m_vertices;
if (vertices.isEmpty())
return;
-
+
qreal halfPointSize = qMin(m_window.width(), m_window.height()) / 300.0;
p.setWindow(m_window.toRect());
@@ -1725,7 +1725,7 @@ void QTriangulator<T>::ComplexToSimple::DebugDialog::paintEvent(QPaintEvent *)
}
u += q;
v += q;
- p.drawLine(u.x, u.y, v.x, v.y);
+ p.drawLine(u.x, u.y, v.x, v.y);
}
}
diff --git a/src/gui/painting/qbackingstore.cpp b/src/gui/painting/qbackingstore.cpp
index 1bf0b33047..cd3f935c5b 100644
--- a/src/gui/painting/qbackingstore.cpp
+++ b/src/gui/painting/qbackingstore.cpp
@@ -45,6 +45,7 @@
#include <qpa/qplatformbackingstore.h>
#include <qpa/qplatformintegration.h>
#include <qscreen.h>
+#include <qdebug.h>
#include <private/qguiapplication_p.h>
#include <private/qwindow_p.h>
@@ -97,8 +98,10 @@ void QBackingStore::flush(const QRegion &region, QWindow *win, const QPoint &off
if (!win)
win = window();
- if (win && !qt_window_private(win)->receivedExpose)
- qWarning("QBackingStore::flush() called with non-exposed window, behavior is undefined");
+ if (win && win->isTopLevel() && !qt_window_private(win)->receivedExpose) {
+ qWarning().nospace() << "QBackingStore::flush() called with non-exposed window "
+ << win << ", behavior is undefined";
+ }
d_ptr->platformBackingStore->flush(win, region, offset);
}
diff --git a/src/gui/painting/qbackingstore.h b/src/gui/painting/qbackingstore.h
index 2a3f91246b..65efab2f48 100644
--- a/src/gui/painting/qbackingstore.h
+++ b/src/gui/painting/qbackingstore.h
@@ -47,8 +47,6 @@
#include <QtGui/qwindow.h>
#include <QtGui/qregion.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -93,6 +91,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QBACKINGSTORE_H
diff --git a/src/gui/painting/qbrush.h b/src/gui/painting/qbrush.h
index 294e0b7931..4d8c97e255 100644
--- a/src/gui/painting/qbrush.h
+++ b/src/gui/painting/qbrush.h
@@ -52,17 +52,6 @@
#include <QtGui/qimage.h>
#include <QtGui/qpixmap.h>
-#if defined(Q_OS_VXWORKS)
-# if defined(m_data)
-# undef m_data
-# endif
-# if defined(m_type)
-# undef m_type
-# endif
-#endif
-
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -326,6 +315,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QBRUSH_H
diff --git a/src/gui/painting/qcolor.cpp b/src/gui/painting/qcolor.cpp
index 7eec60ed12..12ca84d8d1 100644
--- a/src/gui/painting/qcolor.cpp
+++ b/src/gui/painting/qcolor.cpp
@@ -1572,7 +1572,7 @@ QColor QColor::toRgb() const
// achromatic case
color.ct.argb.red = color.ct.argb.green = color.ct.argb.blue = ct.ahsl.lightness;
} else if (ct.ahsl.lightness == 0) {
- // lightness 0
+ // lightness 0
color.ct.argb.red = color.ct.argb.green = color.ct.argb.blue = 0;
} else {
// chromatic case
diff --git a/src/gui/painting/qcolor.h b/src/gui/painting/qcolor.h
index cd65984f4e..ef3503e8d8 100644
--- a/src/gui/painting/qcolor.h
+++ b/src/gui/painting/qcolor.h
@@ -46,8 +46,6 @@
#include <QtCore/qnamespace.h>
#include <QtCore/qstringlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -268,14 +266,12 @@ inline QColor::QColor(const QColor &acolor)
inline bool QColor::isValid() const
{ return cspec != Invalid; }
-inline QColor QColor::lighter(int f) const
+inline QColor QColor::lighter(int f) const
{ return light(f); }
-inline QColor QColor::darker(int f) const
+inline QColor QColor::darker(int f) const
{ return dark(f); }
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOLOR_H
diff --git a/src/gui/painting/qcosmeticstroker.cpp b/src/gui/painting/qcosmeticstroker.cpp
index 3659c56ac7..0f3cde3efd 100644
--- a/src/gui/painting/qcosmeticstroker.cpp
+++ b/src/gui/painting/qcosmeticstroker.cpp
@@ -583,6 +583,7 @@ void QCosmeticStroker::drawPath(const QVectorPath &path)
patternOffset = state->lastPen.dashOffset()*64;
lastPixel.x = -1;
+ const qreal *begin = points;
const qreal *end = points + 2*path.elementCount();
// handle closed path case
bool closed = path.hasImplicitClose() || (points[0] == end[-2] && points[1] == end[-1]);
@@ -592,6 +593,7 @@ void QCosmeticStroker::drawPath(const QVectorPath &path)
calculateLastPoint(p2.x(), p2.y(), p.x(), p.y());
}
+ bool fastPenAliased = (state->flags.fast_pen && !state->flags.antialiased);
points += 2;
while (points < end) {
QPointF p2 = QPointF(points[0], points[1]) * state->matrix;
@@ -599,9 +601,22 @@ void QCosmeticStroker::drawPath(const QVectorPath &path)
if (!closed && drawCaps && points == end - 2)
caps |= CapEnd;
+ QCosmeticStroker::Point last = this->lastPixel;
stroke(this, p.x(), p.y(), p2.x(), p2.y(), caps);
- p = p2;
+ /* fix for gaps in polylines with fastpen and aliased in a sequence
+ of points with small distances: if current point p2 has been dropped
+ out, keep last non dropped point p. */
+ if (fastPenAliased) {
+ if (last.x != lastPixel.x || last.y != lastPixel.y ||
+ points == begin + 2 || points == end - 2 ) {
+ {
+ p = p2;
+ }
+ }
+ } else {
+ p = p2;
+ }
points += 2;
caps = NoCaps;
}
diff --git a/src/gui/painting/qcosmeticstroker_p.h b/src/gui/painting/qcosmeticstroker_p.h
index f4fb5fab30..05c8a2b0cf 100644
--- a/src/gui/painting/qcosmeticstroker_p.h
+++ b/src/gui/painting/qcosmeticstroker_p.h
@@ -47,8 +47,6 @@
#include <private/qpaintengine_raster_p.h>
#include <qpen.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -157,6 +155,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOSMETICLINE_H
diff --git a/src/gui/painting/qcssutil_p.h b/src/gui/painting/qcssutil_p.h
index 38e45ae7c9..7888b9edf1 100644
--- a/src/gui/painting/qcssutil_p.h
+++ b/src/gui/painting/qcssutil_p.h
@@ -78,7 +78,7 @@ extern void Q_GUI_EXPORT qNormalizeRadii(const QRect &br, const QSize *radii,
QSize *tlr, QSize *trr, QSize *blr, QSize *brr);
QT_END_NAMESPACE
-
+
#endif //QT_NO_CSSPARSER
#endif // QCSSUTIL_P_H
diff --git a/src/gui/painting/qdrawhelper.cpp b/src/gui/painting/qdrawhelper.cpp
index 61a6f2a5f9..628d12d881 100644
--- a/src/gui/painting/qdrawhelper.cpp
+++ b/src/gui/painting/qdrawhelper.cpp
@@ -5373,7 +5373,7 @@ void qBlendTexture(int count, const QSpan *spans, void *userData)
proc(count, spans, userData);
}
-template <class DST>
+template <class DST> Q_STATIC_TEMPLATE_FUNCTION
inline void qt_bitmapblit_template(QRasterBuffer *rasterBuffer,
int x, int y, DST color,
const uchar *map,
diff --git a/src/gui/painting/qdrawhelper_p.h b/src/gui/painting/qdrawhelper_p.h
index 258f130efc..5d9867012f 100644
--- a/src/gui/painting/qdrawhelper_p.h
+++ b/src/gui/painting/qdrawhelper_p.h
@@ -70,15 +70,19 @@ QT_BEGIN_NAMESPACE
#if defined(Q_CC_RVCT)
// RVCT doesn't like static template functions
# define Q_STATIC_TEMPLATE_FUNCTION
-# define Q_STATIC_INLINE_FUNCTION static __forceinline
+# define Q_ALWAYS_INLINE __forceinline
# define Q_DECL_RESTRICT
#elif defined(Q_CC_GNU)
-# define Q_STATIC_TEMPLATE_FUNCTION static __attribute__((always_inline))
-# define Q_STATIC_INLINE_FUNCTION static inline __attribute__((always_inline))
+# define Q_STATIC_TEMPLATE_FUNCTION static
+# define Q_ALWAYS_INLINE inline __attribute__((always_inline))
# define Q_DECL_RESTRICT __restrict__
+#elif defined(Q_CC_MSVC)
+# define Q_STATIC_TEMPLATE_FUNCTION static
+# define Q_ALWAYS_INLINE __forceinline
+# define Q_DECL_RESTRICT __restrict
#else
# define Q_STATIC_TEMPLATE_FUNCTION static
-# define Q_STATIC_INLINE_FUNCTION static inline
+# define Q_ALWAYS_INLINE inline
# define Q_DECL_RESTRICT
#endif
@@ -382,13 +386,14 @@ static inline qreal qRadialDeterminant(qreal a, qreal b, qreal c)
return (b * b) - (4 * a * c);
}
-template <class RadialFetchFunc>
+extern void (*qt_memfill32)(quint32 *dest, quint32 value, int count);
+
+template <class RadialFetchFunc> Q_STATIC_TEMPLATE_FUNCTION
const uint * QT_FASTCALL qt_fetch_radial_gradient_template(uint *buffer, const Operator *op, const QSpanData *data,
int y, int x, int length)
{
// avoid division by zero
if (qFuzzyIsNull(op->radial.a)) {
- extern void (*qt_memfill32)(quint32 *dest, quint32 value, int count);
qt_memfill32(buffer, 0, length);
return buffer;
}
@@ -562,7 +567,7 @@ public:
# pragma push
# pragma arm
#endif
-Q_STATIC_INLINE_FUNCTION uint INTERPOLATE_PIXEL_255(uint x, uint a, uint y, uint b) {
+static Q_ALWAYS_INLINE uint INTERPOLATE_PIXEL_255(uint x, uint a, uint y, uint b) {
uint t = (x & 0xff00ff) * a + (y & 0xff00ff) * b;
t = (t + ((t >> 8) & 0xff00ff) + 0x800080) >> 8;
t &= 0xff00ff;
@@ -579,7 +584,7 @@ Q_STATIC_INLINE_FUNCTION uint INTERPOLATE_PIXEL_255(uint x, uint a, uint y, uint
#if QT_POINTER_SIZE == 8 // 64-bit versions
-Q_STATIC_INLINE_FUNCTION uint INTERPOLATE_PIXEL_256(uint x, uint a, uint y, uint b) {
+static Q_ALWAYS_INLINE uint INTERPOLATE_PIXEL_256(uint x, uint a, uint y, uint b) {
quint64 t = (((quint64(x)) | ((quint64(x)) << 24)) & 0x00ff00ff00ff00ff) * a;
t += (((quint64(y)) | ((quint64(y)) << 24)) & 0x00ff00ff00ff00ff) * b;
t >>= 8;
@@ -587,14 +592,14 @@ Q_STATIC_INLINE_FUNCTION uint INTERPOLATE_PIXEL_256(uint x, uint a, uint y, uint
return (uint(t)) | (uint(t >> 24));
}
-Q_STATIC_INLINE_FUNCTION uint BYTE_MUL(uint x, uint a) {
+static Q_ALWAYS_INLINE uint BYTE_MUL(uint x, uint a) {
quint64 t = (((quint64(x)) | ((quint64(x)) << 24)) & 0x00ff00ff00ff00ff) * a;
t = (t + ((t >> 8) & 0xff00ff00ff00ff) + 0x80008000800080) >> 8;
t &= 0x00ff00ff00ff00ff;
return (uint(t)) | (uint(t >> 24));
}
-Q_STATIC_INLINE_FUNCTION uint PREMUL(uint x) {
+static Q_ALWAYS_INLINE uint PREMUL(uint x) {
uint a = x >> 24;
quint64 t = (((quint64(x)) | ((quint64(x)) << 24)) & 0x00ff00ff00ff00ff) * a;
t = (t + ((t >> 8) & 0xff00ff00ff00ff) + 0x80008000800080) >> 8;
@@ -604,7 +609,7 @@ Q_STATIC_INLINE_FUNCTION uint PREMUL(uint x) {
#else // 32-bit versions
-Q_STATIC_INLINE_FUNCTION uint INTERPOLATE_PIXEL_256(uint x, uint a, uint y, uint b) {
+static Q_ALWAYS_INLINE uint INTERPOLATE_PIXEL_256(uint x, uint a, uint y, uint b) {
uint t = (x & 0xff00ff) * a + (y & 0xff00ff) * b;
t >>= 8;
t &= 0xff00ff;
@@ -619,7 +624,7 @@ Q_STATIC_INLINE_FUNCTION uint INTERPOLATE_PIXEL_256(uint x, uint a, uint y, uint
# pragma push
# pragma arm
#endif
-Q_STATIC_INLINE_FUNCTION uint BYTE_MUL(uint x, uint a) {
+static Q_ALWAYS_INLINE uint BYTE_MUL(uint x, uint a) {
uint t = (x & 0xff00ff) * a;
t = (t + ((t >> 8) & 0xff00ff) + 0x800080) >> 8;
t &= 0xff00ff;
@@ -634,7 +639,7 @@ Q_STATIC_INLINE_FUNCTION uint BYTE_MUL(uint x, uint a) {
# pragma pop
#endif
-Q_STATIC_INLINE_FUNCTION uint PREMUL(uint x) {
+static Q_ALWAYS_INLINE uint PREMUL(uint x) {
uint a = x >> 24;
uint t = (x & 0xff00ff) * a;
t = (t + ((t >> 8) & 0xff00ff) + 0x800080) >> 8;
@@ -649,14 +654,14 @@ Q_STATIC_INLINE_FUNCTION uint PREMUL(uint x) {
#endif
-Q_STATIC_INLINE_FUNCTION uint BYTE_MUL_RGB16(uint x, uint a) {
+static Q_ALWAYS_INLINE uint BYTE_MUL_RGB16(uint x, uint a) {
a += 1;
uint t = (((x & 0x07e0)*a) >> 8) & 0x07e0;
t |= (((x & 0xf81f)*(a>>2)) >> 6) & 0xf81f;
return t;
}
-Q_STATIC_INLINE_FUNCTION uint BYTE_MUL_RGB16_32(uint x, uint a) {
+static Q_ALWAYS_INLINE uint BYTE_MUL_RGB16_32(uint x, uint a) {
uint t = (((x & 0xf81f07e0) >> 5)*a) & 0xf81f07e0;
t |= (((x & 0x07e0f81f)*a) >> 5) & 0x07e0f81f;
return t;
@@ -687,12 +692,11 @@ inline quint24::operator uint() const
return data[2] | (data[1] << 8) | (data[0] << 16);
}
-template <class T>
+template <class T> Q_STATIC_TEMPLATE_FUNCTION
void qt_memfill(T *dest, T value, int count);
template<> inline void qt_memfill(quint32 *dest, quint32 color, int count)
{
- extern void (*qt_memfill32)(quint32 *dest, quint32 value, int count);
qt_memfill32(dest, color, count);
}
@@ -728,7 +732,7 @@ inline void qt_memfill(T *dest, T value, int count)
}
}
-template <class T>
+template <class T> Q_STATIC_TEMPLATE_FUNCTION
inline void qt_rectfill(T *dest, T value,
int x, int y, int width, int height, int stride)
{
@@ -794,7 +798,7 @@ do { \
# pragma push
# pragma arm
#endif
-Q_STATIC_INLINE_FUNCTION int qt_div_255(int x) { return (x + (x>>8) + 0x80) >> 8; }
+static Q_ALWAYS_INLINE int qt_div_255(int x) { return (x + (x>>8) + 0x80) >> 8; }
#if defined(Q_CC_RVCT)
# pragma pop
#endif
diff --git a/src/gui/painting/qemulationpaintengine_p.h b/src/gui/painting/qemulationpaintengine_p.h
index f706ef3705..db2d51e53a 100644
--- a/src/gui/painting/qemulationpaintengine_p.h
+++ b/src/gui/painting/qemulationpaintengine_p.h
@@ -55,8 +55,6 @@
#include <private/qpaintengineex_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -64,10 +62,10 @@ class QEmulationPaintEngine : public QPaintEngineEx
{
public:
QEmulationPaintEngine(QPaintEngineEx *engine);
-
+
virtual bool begin(QPaintDevice *pdev);
virtual bool end();
-
+
virtual Type type() const;
virtual QPainterState *createState(QPainterState *orig) const;
@@ -80,7 +78,7 @@ public:
virtual void drawStaticTextItem(QStaticTextItem *item);
virtual void drawTiledPixmap(const QRectF &r, const QPixmap &pixmap, const QPointF &s);
virtual void drawImage(const QRectF &r, const QImage &pm, const QRectF &sr, Qt::ImageConversionFlags flags);
-
+
virtual void clipEnabledChanged();
virtual void penChanged();
virtual void brushChanged();
@@ -107,6 +105,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/painting/qgrayraster.c b/src/gui/painting/qgrayraster.c
index 8be462517c..7dfb743ae2 100644
--- a/src/gui/painting/qgrayraster.c
+++ b/src/gui/painting/qgrayraster.c
@@ -1736,9 +1736,9 @@
if ( raster->worker )
raster->worker->skip_spans = params->skip_spans;
- // If raster object and raster buffer are allocated, but
- // raster size isn't of the minimum size, indicate out of
- // memory.
+ /* If raster object and raster buffer are allocated, but */
+ /* raster size isn't of the minimum size, indicate out of */
+ /* memory. */
if (raster->buffer_allocated_size < MINIMUM_POOL_SIZE )
return ErrRaster_OutOfMemory;
@@ -1866,8 +1866,8 @@
( sizeof ( TCell ) * 8 ) );
}
else if ( pool_base)
- { // Case when there is a raster pool allocated, but it
- // doesn't have the minimum size (and so memory will be reallocated)
+ { /* Case when there is a raster pool allocated, but it */
+ /* doesn't have the minimum size (and so memory will be reallocated) */
rast->buffer = pool_base;
rast->worker = NULL;
rast->buffer_size = pool_size;
diff --git a/src/gui/painting/qmatrix.h b/src/gui/painting/qmatrix.h
index 672bbdcfd1..d2c1ae3a3c 100644
--- a/src/gui/painting/qmatrix.h
+++ b/src/gui/painting/qmatrix.h
@@ -49,8 +49,6 @@
#include <QtCore/qpoint.h>
#include <QtCore/qrect.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -185,6 +183,4 @@ Q_GUI_EXPORT QDebug operator<<(QDebug, const QMatrix &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMATRIX_H
diff --git a/src/gui/painting/qoutlinemapper.cpp b/src/gui/painting/qoutlinemapper.cpp
index 2f2fe44209..8b47dae5ff 100644
--- a/src/gui/painting/qoutlinemapper.cpp
+++ b/src/gui/painting/qoutlinemapper.cpp
@@ -48,8 +48,6 @@
QT_BEGIN_NAMESPACE
-static const qreal aliasedCoordinateDelta = 0.5 - 0.015625;
-
#define qreal_to_fixed_26_6(f) (int(f * 64))
diff --git a/src/gui/painting/qpagedpaintdevice.h b/src/gui/painting/qpagedpaintdevice.h
index b2b53d8038..d44a401184 100644
--- a/src/gui/painting/qpagedpaintdevice.h
+++ b/src/gui/painting/qpagedpaintdevice.h
@@ -44,8 +44,6 @@
#include <QtGui/qpaintdevice.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#if defined(B0)
@@ -90,6 +88,4 @@ protected:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/painting/qpaintbuffer.cpp b/src/gui/painting/qpaintbuffer.cpp
index 1a5a19a366..bb0c441b40 100644
--- a/src/gui/painting/qpaintbuffer.cpp
+++ b/src/gui/painting/qpaintbuffer.cpp
@@ -74,11 +74,11 @@ QTextItemIntCopy::QTextItemIntCopy(const QTextItem &item)
char *glyphLayoutData = new char[size];
QGlyphLayout glyphs(glyphLayoutData, m_item.glyphs.numGlyphs);
memcpy(glyphs.offsets, m_item.glyphs.offsets, m_item.glyphs.numGlyphs * sizeof(QFixedPoint));
- memcpy(glyphs.glyphs, m_item.glyphs.glyphs, m_item.glyphs.numGlyphs * sizeof(HB_Glyph));
+ memcpy(glyphs.glyphs, m_item.glyphs.glyphs, m_item.glyphs.numGlyphs * sizeof(glyph_t));
memcpy(glyphs.advances_x, m_item.glyphs.advances_x, m_item.glyphs.numGlyphs * sizeof(QFixed));
memcpy(glyphs.advances_y, m_item.glyphs.advances_y, m_item.glyphs.numGlyphs * sizeof(QFixed));
memcpy(glyphs.justifications, m_item.glyphs.justifications, m_item.glyphs.numGlyphs * sizeof(QGlyphJustification));
- memcpy(glyphs.attributes, m_item.glyphs.attributes, m_item.glyphs.numGlyphs * sizeof(HB_GlyphAttributes));
+ memcpy(glyphs.attributes, m_item.glyphs.attributes, m_item.glyphs.numGlyphs * sizeof(QGlyphAttributes));
m_item.glyphs = glyphs;
m_font = *m_item.f;
@@ -1731,12 +1731,12 @@ void QPainterReplayer::process(const QPaintBufferCommand &cmd)
#endif
painter->setClipRegion(region, Qt::ClipOperation(cmd.extra));
break; }
-
+
#if !defined(QT_NO_RAWFONT)
case QPaintBufferPrivate::Cmd_DrawStaticText: {
-
+
QVariantList variants(d->variants.at(cmd.offset).value<QVariantList>());
-
+
QFont font = variants.at(0).value<QFont>();
QVector<quint32> glyphIndexes;
@@ -1752,7 +1752,7 @@ void QPainterReplayer::process(const QPaintBufferCommand &cmd)
QRawFont rawFont;
QRawFontPrivate *rawFontD = QRawFontPrivate::get(rawFont);
QFontPrivate *fontD = QFontPrivate::get(font);
- rawFontD->fontEngine = fontD->engineForScript(QUnicodeTables::Common);
+ rawFontD->fontEngine = fontD->engineForScript(QChar::Script_Common);
rawFontD->fontEngine->ref.ref();
QGlyphRun glyphs;
diff --git a/src/gui/painting/qpaintdevice.h b/src/gui/painting/qpaintdevice.h
index 1a638ffeba..1529b701cf 100644
--- a/src/gui/painting/qpaintdevice.h
+++ b/src/gui/painting/qpaintdevice.h
@@ -45,8 +45,6 @@
#include <QtGui/qwindowdefs.h>
#include <QtCore/qrect.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -120,6 +118,4 @@ inline bool QPaintDevice::paintingActive() const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPAINTDEVICE_H
diff --git a/src/gui/painting/qpaintengine.h b/src/gui/painting/qpaintengine.h
index 85f4d2159e..b3e3762cc8 100644
--- a/src/gui/painting/qpaintengine.h
+++ b/src/gui/painting/qpaintengine.h
@@ -47,8 +47,6 @@
#include <QtCore/qscopedpointer.h>
#include <QtGui/qpainter.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -348,6 +346,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QPaintEngine::DirtyFlags)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPAINTENGINE_H
diff --git a/src/gui/painting/qpaintengine_raster.cpp b/src/gui/painting/qpaintengine_raster.cpp
index 941e3ea71a..a123c147a2 100644
--- a/src/gui/painting/qpaintengine_raster.cpp
+++ b/src/gui/painting/qpaintengine_raster.cpp
@@ -2858,7 +2858,19 @@ bool QRasterPaintEngine::drawCachedGlyphs(int numGlyphs, const glyph_t *glyphs,
// x, y,
// positions[i].x.toInt(), positions[i].y.toInt());
- alphaPenBlt(bits + ((c.x << leftShift) >> rightShift) + c.y * bpl, bpl, depth, x, y, c.w, c.h);
+ const uchar *glyphBits = bits + ((c.x << leftShift) >> rightShift) + c.y * bpl;
+
+ if (glyphType == QFontEngineGlyphCache::Raster_ARGB) {
+ // The current state transform has already been applied to the positions,
+ // so we prevent drawImage() from re-applying the transform by clearing
+ // the state for the duration of the call.
+ QTransform originalTransform = s->matrix;
+ s->matrix = QTransform();
+ drawImage(QPoint(x, y), QImage(glyphBits, c.w, c.h, bpl, image.format()));
+ s->matrix = originalTransform;
+ } else {
+ alphaPenBlt(glyphBits, bpl, depth, x, y, c.w, c.h);
+ }
}
}
return true;
@@ -3011,13 +3023,15 @@ void QRasterPaintEngine::drawStaticTextItem(QStaticTextItem *textItem)
ensurePen();
ensureRasterState();
+ QTransform matrix = state()->matrix;
+
QFontEngine *fontEngine = textItem->fontEngine();
- if (!supportsTransformations(fontEngine)) {
+ if (shouldDrawCachedGlyphs(fontEngine, matrix)) {
drawCachedGlyphs(textItem->numGlyphs, textItem->glyphs, textItem->glyphPositions,
fontEngine);
- } else if (state()->matrix.type() < QTransform::TxProject) {
+ } else if (matrix.type() < QTransform::TxProject) {
bool invertible;
- QTransform invMat = state()->matrix.inverted(&invertible);
+ QTransform invMat = matrix.inverted(&invertible);
if (!invertible)
return;
@@ -3056,7 +3070,7 @@ void QRasterPaintEngine::drawTextItem(const QPointF &p, const QTextItem &textIte
QRasterPaintEngineState *s = state();
QTransform matrix = s->matrix;
- if (!supportsTransformations(ti.fontEngine)) {
+ if (shouldDrawCachedGlyphs(ti.fontEngine, matrix)) {
QVarLengthArray<QFixedPoint> positions;
QVarLengthArray<glyph_t> glyphs;
@@ -3300,21 +3314,25 @@ void QRasterPaintEngine::releaseDC(HDC) const
/*!
\internal
*/
-bool QRasterPaintEngine::supportsTransformations(QFontEngine *fontEngine) const
+bool QRasterPaintEngine::requiresPretransformedGlyphPositions(QFontEngine *fontEngine, const QTransform &m) const
{
- const QTransform &m = state()->matrix;
- return supportsTransformations(fontEngine, m);
+ // Cached glyphs always require pretransformed positions
+ if (shouldDrawCachedGlyphs(fontEngine, m))
+ return true;
+
+ // Otherwise let the base-class decide based on the transform
+ return QPaintEngineEx::requiresPretransformedGlyphPositions(fontEngine, m);
}
-/*!
- \internal
-*/
-bool QRasterPaintEngine::supportsTransformations(QFontEngine *fontEngine, const QTransform &m) const
+bool QRasterPaintEngine::shouldDrawCachedGlyphs(QFontEngine *fontEngine, const QTransform &m) const
{
- if (fontEngine->supportsTransformations(m))
- return true;
+ // The font engine might not support filling the glyph cache
+ // with the given transform applied, in which case we need to
+ // fall back to the QPainterPath code-path.
+ if (!fontEngine->supportsTransformation(m))
+ return false;
- return !shouldDrawCachedGlyphs(fontEngine, m);
+ return QPaintEngineEx::shouldDrawCachedGlyphs(fontEngine, m);
}
/*!
diff --git a/src/gui/painting/qpaintengine_raster_p.h b/src/gui/painting/qpaintengine_raster_p.h
index d9e4a4b505..00a9ae750c 100644
--- a/src/gui/painting/qpaintengine_raster_p.h
+++ b/src/gui/painting/qpaintengine_raster_p.h
@@ -231,8 +231,8 @@ public:
QPoint coordinateOffset() const;
- bool supportsTransformations(QFontEngine *fontEngine) const;
- bool supportsTransformations(QFontEngine *fontEngine, const QTransform &m) const;
+ bool requiresPretransformedGlyphPositions(QFontEngine *fontEngine, const QTransform &m) const;
+ bool shouldDrawCachedGlyphs(QFontEngine *fontEngine, const QTransform &m) const;
protected:
QRasterPaintEngine(QRasterPaintEnginePrivate &d, QPaintDevice *);
diff --git a/src/gui/painting/qpaintengineex.cpp b/src/gui/painting/qpaintengineex.cpp
index 83b684da1e..6e72b5db7f 100644
--- a/src/gui/painting/qpaintengineex.cpp
+++ b/src/gui/painting/qpaintengineex.cpp
@@ -1081,18 +1081,16 @@ void QPaintEngineEx::drawStaticTextItem(QStaticTextItem *staticTextItem)
}
}
-bool QPaintEngineEx::supportsTransformations(QFontEngine *fontEngine, const QTransform &m) const
+bool QPaintEngineEx::requiresPretransformedGlyphPositions(QFontEngine *, const QTransform &t) const
{
- Q_UNUSED(fontEngine);
-
- if (!m.isAffine())
- return true;
-
- return false;
+ return t.type() >= QTransform::TxProject;
}
bool QPaintEngineEx::shouldDrawCachedGlyphs(QFontEngine *fontEngine, const QTransform &m) const
{
+ if (fontEngine->glyphFormat == QFontEngineGlyphCache::Raster_ARGB)
+ return true;
+
qreal pixelSize = fontEngine->fontDef.pixelSize;
return (pixelSize * pixelSize * qAbs(m.determinant())) <
QT_MAX_CACHED_GLYPH_SIZE * QT_MAX_CACHED_GLYPH_SIZE;
diff --git a/src/gui/painting/qpaintengineex_p.h b/src/gui/painting/qpaintengineex_p.h
index 399a6f63b0..5a9df72c76 100644
--- a/src/gui/painting/qpaintengineex_p.h
+++ b/src/gui/painting/qpaintengineex_p.h
@@ -61,8 +61,6 @@
#include <private/qvectorpath_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -164,7 +162,7 @@ public:
IsEmulationEngine = 0x02 // If set, this object is a QEmulationEngine.
};
virtual uint flags() const {return 0;}
- virtual bool supportsTransformations(QFontEngine *fontEngine, const QTransform &m) const;
+ virtual bool requiresPretransformedGlyphPositions(QFontEngine *fontEngine, const QTransform &m) const;
virtual bool shouldDrawCachedGlyphs(QFontEngine *fontEngine, const QTransform &m) const;
protected:
@@ -192,6 +190,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/painting/qpainter.cpp b/src/gui/painting/qpainter.cpp
index 786136d203..be77fffc7c 100644
--- a/src/gui/painting/qpainter.cpp
+++ b/src/gui/painting/qpainter.cpp
@@ -1155,9 +1155,6 @@ void QPainterPrivate::updateState(QPainterState *newState)
should antialias text if possible, and the \l
{RenderHint}{QPainter::SmoothPixmapTransform} indicates that the
engine should use a smooth pixmap transformation algorithm.
- \l {RenderHint}{HighQualityAntialiasing} is an OpenGL-specific rendering hint
- indicating that the engine should use fragment programs and offscreen
- rendering for antialiasing.
The renderHints() function returns a flag that specifies the
rendering hints that are set for this painter. Use the
@@ -1409,9 +1406,8 @@ void QPainterPrivate::updateState(QPainterState *newState)
a smooth pixmap transformation algorithm (such as bilinear) rather
than nearest neighbor.
- \value HighQualityAntialiasing An OpenGL-specific rendering hint
- indicating that the engine should use fragment programs and offscreen
- rendering for antialiasing.
+ \value HighQualityAntialiasing This value is obsolete and will be ignored,
+ use the Antialiasing render hint instead.
\value NonCosmeticDefaultPen This value is obsolete, the default for QPen
is now non-cosmetic.
@@ -5552,13 +5548,13 @@ void QPainter::drawGlyphRun(const QPointF &position, const QGlyphRun &glyphRun)
QVarLengthArray<QFixedPoint, 128> fixedPointPositions(count);
QRawFontPrivate *fontD = QRawFontPrivate::get(font);
- bool supportsTransformations = d->extended
- ? d->extended->supportsTransformations(fontD->fontEngine, d->state->matrix)
- : d->engine->type() == QPaintEngine::CoreGraphics || d->state->matrix.isAffine();
+ bool engineRequiresPretransformedGlyphPositions = d->extended
+ ? d->extended->requiresPretransformedGlyphPositions(fontD->fontEngine, d->state->matrix)
+ : d->engine->type() != QPaintEngine::CoreGraphics && !d->state->matrix.isAffine();
for (int i=0; i<count; ++i) {
QPointF processedPosition = position + glyphPositions[i];
- if (!supportsTransformations)
+ if (engineRequiresPretransformedGlyphPositions)
processedPosition = d->state->transform().map(processedPosition);
fixedPointPositions[i] = QFixedPoint::fromPointF(processedPosition);
}
@@ -5616,13 +5612,13 @@ void QPainterPrivate::drawGlyphs(const quint32 *glyphArray, QFixedPoint *positio
QVarLengthArray<QFixed, 128> advances(glyphCount);
QVarLengthArray<QGlyphJustification, 128> glyphJustifications(glyphCount);
- QVarLengthArray<HB_GlyphAttributes, 128> glyphAttributes(glyphCount);
- memset(glyphAttributes.data(), 0, glyphAttributes.size() * sizeof(HB_GlyphAttributes));
+ QVarLengthArray<QGlyphAttributes, 128> glyphAttributes(glyphCount);
+ memset(glyphAttributes.data(), 0, glyphAttributes.size() * sizeof(QGlyphAttributes));
memset(advances.data(), 0, advances.size() * sizeof(QFixed));
memset(glyphJustifications.data(), 0, glyphJustifications.size() * sizeof(QGlyphJustification));
textItem.glyphs.numGlyphs = glyphCount;
- textItem.glyphs.glyphs = reinterpret_cast<HB_Glyph *>(const_cast<quint32 *>(glyphArray));
+ textItem.glyphs.glyphs = const_cast<glyph_t *>(glyphArray);
textItem.glyphs.offsets = positions;
textItem.glyphs.advances_x = advances.data();
textItem.glyphs.advances_y = advances.data();
@@ -5738,17 +5734,21 @@ void QPainter::drawStaticText(const QPointF &topLeftPosition, const QStaticText
return;
}
- QFontEngine *fe = staticText_d->font.d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *fe = staticText_d->font.d->engineForScript(QChar::Script_Common);
if (fe->type() == QFontEngine::Multi)
fe = static_cast<QFontEngineMulti *>(fe)->engine(0);
- bool supportsTransformations = d->extended->supportsTransformations(fe,
- d->state->matrix);
- if (supportsTransformations && !staticText_d->untransformedCoordinates) {
- staticText_d->untransformedCoordinates = true;
- staticText_d->needsRelayout = true;
- } else if (!supportsTransformations && staticText_d->untransformedCoordinates) {
+
+ bool engineRequiresPretransform = d->extended->requiresPretransformedGlyphPositions(fe, d->state->matrix);
+ if (staticText_d->untransformedCoordinates && engineRequiresPretransform) {
+ // The coordinates are untransformed, and the engine can't deal with that
+ // nativly, so we have to pre-transform the static text.
staticText_d->untransformedCoordinates = false;
staticText_d->needsRelayout = true;
+ } else if (!staticText_d->untransformedCoordinates && !engineRequiresPretransform) {
+ // The coordinates are already transformed, but the engine can handle that
+ // nativly, so undo the transform of the static text.
+ staticText_d->untransformedCoordinates = true;
+ staticText_d->needsRelayout = true;
}
// Don't recalculate entire layout because of translation, rather add the dx and dy
@@ -5841,11 +5841,11 @@ void QPainter::drawText(const QPointF &p, const QString &str, int tf, int justif
return;
if (tf & Qt::TextBypassShaping) {
- // Skip harfbuzz complex shaping, shape using glyph advances only
+ // Skip complex shaping, shape using glyph advances only
int len = str.length();
int numGlyphs = len;
QVarLengthGlyphLayoutArray glyphs(len);
- QFontEngine *fontEngine = d->state->font.d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *fontEngine = d->state->font.d->engineForScript(QChar::Script_Common);
if (!fontEngine->stringToCMap(str.data(), len, &glyphs, &numGlyphs, 0)) {
glyphs.resize(numGlyphs);
if (!fontEngine->stringToCMap(str.data(), len, &glyphs, &numGlyphs, 0))
diff --git a/src/gui/painting/qpainter.h b/src/gui/painting/qpainter.h
index 9f390b9865..874b244bd6 100644
--- a/src/gui/painting/qpainter.h
+++ b/src/gui/painting/qpainter.h
@@ -60,8 +60,6 @@
#include <QtGui/qfontmetrics.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -932,6 +930,4 @@ inline void QPainter::drawPicture(const QPoint &pt, const QPicture &p)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPAINTER_H
diff --git a/src/gui/painting/qpainterpath.h b/src/gui/painting/qpainterpath.h
index 7c3365875e..e22c1729f3 100644
--- a/src/gui/painting/qpainterpath.h
+++ b/src/gui/painting/qpainterpath.h
@@ -49,8 +49,6 @@
#include <QtCore/qvector.h>
#include <QtCore/qscopedpointer.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -375,6 +373,4 @@ Q_GUI_EXPORT QDebug operator<<(QDebug, const QPainterPath &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPAINTERPATH_H
diff --git a/src/gui/painting/qpathclipper.cpp b/src/gui/painting/qpathclipper.cpp
index 6ad9a7f436..2702b56e73 100644
--- a/src/gui/painting/qpathclipper.cpp
+++ b/src/gui/painting/qpathclipper.cpp
@@ -713,8 +713,7 @@ class QKdPointFinder
{
public:
QKdPointFinder(int point, const QPathSegments &segments, QKdPointTree &tree)
- : m_point(point)
- , m_result(-1)
+ : m_result(-1)
, m_segments(&segments)
, m_tree(&tree)
{
@@ -759,7 +758,6 @@ public:
}
private:
- int m_point;
qreal pointComponents[2];
int m_result;
const QPathSegments *m_segments;
diff --git a/src/gui/painting/qpathclipper_p.h b/src/gui/painting/qpathclipper_p.h
index 4ab2b9d88a..45cce640c5 100644
--- a/src/gui/painting/qpathclipper_p.h
+++ b/src/gui/painting/qpathclipper_p.h
@@ -60,8 +60,6 @@
#include <private/qdatabuffer_p.h>
#include <stdio.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -488,6 +486,4 @@ inline QPathEdge::Direction QWingedEdge::flip(QPathEdge::Direction direction)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPATHCLIPPER_P_H
diff --git a/src/gui/painting/qpdfwriter.h b/src/gui/painting/qpdfwriter.h
index 792aeefad1..45bb5ad4b4 100644
--- a/src/gui/painting/qpdfwriter.h
+++ b/src/gui/painting/qpdfwriter.h
@@ -45,8 +45,6 @@
#include <QtCore/qobject.h>
#include <QtGui/qpagedpaintdevice.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -85,6 +83,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/painting/qpen.h b/src/gui/painting/qpen.h
index 3e5e258123..c5144f784f 100644
--- a/src/gui/painting/qpen.h
+++ b/src/gui/painting/qpen.h
@@ -45,8 +45,6 @@
#include <QtGui/qcolor.h>
#include <QtGui/qbrush.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -139,6 +137,4 @@ Q_GUI_EXPORT QDebug operator<<(QDebug, const QPen &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPEN_H
diff --git a/src/gui/painting/qplatformbackingstore.h b/src/gui/painting/qplatformbackingstore.h
index 0429ec7e89..1b19b2c379 100644
--- a/src/gui/painting/qplatformbackingstore.h
+++ b/src/gui/painting/qplatformbackingstore.h
@@ -56,8 +56,6 @@
#include <QtGui/qwindow.h>
#include <QtGui/qregion.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -95,6 +93,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMBACKINGSTORE_H
diff --git a/src/gui/painting/qpolygon.h b/src/gui/painting/qpolygon.h
index 32de4ddd65..1039e842ab 100644
--- a/src/gui/painting/qpolygon.h
+++ b/src/gui/painting/qpolygon.h
@@ -46,8 +46,6 @@
#include <QtCore/qpoint.h>
#include <QtCore/qrect.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -185,6 +183,4 @@ inline QPolygonF QPolygonF::translated(qreal dx, qreal dy) const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPOLYGON_H
diff --git a/src/gui/painting/qrasterizer.cpp b/src/gui/painting/qrasterizer.cpp
index 8483a05d60..a6be7c6c78 100644
--- a/src/gui/painting/qrasterizer.cpp
+++ b/src/gui/painting/qrasterizer.cpp
@@ -891,6 +891,8 @@ void QRasterizer::rasterizeLine(const QPointF &a, const QPointF &b, qreal width,
const Q16Dot16 rowHeight = qMin(yFP + Q16Dot16Factor, yPb)
- qMax(yFP, yPa);
const int y = Q16Dot16ToInt(yFP);
+ if (y > d->clipRect.bottom())
+ break;
for (int i = 0; i < n; ++i) {
buffer.addSpan(x[i], len[i], y,
Q16Dot16ToInt(Q16Dot16Multiply(rowHeight, coverage[i])));
diff --git a/src/gui/painting/qregion.h b/src/gui/painting/qregion.h
index dee996c523..0e436e3fb4 100644
--- a/src/gui/painting/qregion.h
+++ b/src/gui/painting/qregion.h
@@ -50,8 +50,6 @@
#include <QtCore/qdatastream.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -173,6 +171,4 @@ Q_GUI_EXPORT QDebug operator<<(QDebug, const QRegion &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QREGION_H
diff --git a/src/gui/painting/qrgb.h b/src/gui/painting/qrgb.h
index 06c479e5cd..d7a01840e8 100644
--- a/src/gui/painting/qrgb.h
+++ b/src/gui/painting/qrgb.h
@@ -44,14 +44,13 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
typedef unsigned int QRgb; // RGB triplet
-const QRgb RGB_MASK = 0x00ffffff; // masks RGB values
+// non-namespaced Qt global variable
+const Q_DECL_UNUSED QRgb RGB_MASK = 0x00ffffff; // masks RGB values
inline int qRed(QRgb rgb) // get red part of RGB
{ return ((rgb >> 16) & 0xff); }
@@ -82,6 +81,4 @@ inline bool qIsGray(QRgb rgb)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QRGB_H
diff --git a/src/gui/painting/qtextureglyphcache.cpp b/src/gui/painting/qtextureglyphcache.cpp
index 2ffdc9cd59..6676d3daa6 100644
--- a/src/gui/painting/qtextureglyphcache.cpp
+++ b/src/gui/painting/qtextureglyphcache.cpp
@@ -109,7 +109,8 @@ bool QTextureGlyphCache::populate(QFontEngine *fontEngine, int numGlyphs, const
m_current_fontengine = fontEngine;
const int margin = m_current_fontengine->glyphMargin(m_type);
- const int paddingDoubled = glyphPadding() * 2;
+ const int padding = glyphPadding();
+ const int paddingDoubled = padding * 2;
bool supportsSubPixelPositions = fontEngine->supportsSubPixelPositions();
if (fontEngine->m_subPixelPositionCount == 0) {
@@ -122,6 +123,11 @@ bool QTextureGlyphCache::populate(QFontEngine *fontEngine, int numGlyphs, const
}
}
+ if (m_cx == 0 && m_cy == 0) {
+ m_cx = padding;
+ m_cy = padding;
+ }
+
QHash<GlyphAndSubPixelPosition, Coord> listItemCoordinates;
int rowHeight = 0;
@@ -129,6 +135,7 @@ bool QTextureGlyphCache::populate(QFontEngine *fontEngine, int numGlyphs, const
switch (m_type) {
case Raster_A8: format = QFontEngine::Format_A8; break;
case Raster_RGBMask: format = QFontEngine::Format_A32; break;
+ case Raster_ARGB: format = QFontEngine::Format_ARGB; break;
default: format = QFontEngine::Format_Mono; break;
}
@@ -157,7 +164,7 @@ bool QTextureGlyphCache::populate(QFontEngine *fontEngine, int numGlyphs, const
metrics.yoff.toReal(),
metrics.x.toReal(),
metrics.y.toReal());
-#endif
+#endif
GlyphAndSubPixelPosition key(glyph, subPixelPosition);
int glyph_width = metrics.width.ceil().toInt();
int glyph_height = metrics.height.ceil().toInt();
@@ -202,21 +209,21 @@ bool QTextureGlyphCache::populate(QFontEngine *fontEngine, int numGlyphs, const
m_currentRowHeight = qMax(m_currentRowHeight, c.h + margin * 2);
- if (m_cx + c.w > requiredWidth) {
+ if (m_cx + c.w + padding > requiredWidth) {
int new_width = requiredWidth*2;
- while (new_width < m_cx + c.w)
+ while (new_width < m_cx + c.w + padding)
new_width *= 2;
if (new_width <= maxTextureWidth()) {
requiredWidth = new_width;
} else {
// no room on the current line, start new glyph strip
- m_cx = 0;
+ m_cx = padding;
m_cy += m_currentRowHeight + paddingDoubled;
m_currentRowHeight = c.h + margin * 2; // New row
}
}
- if (maxTextureHeight() > 0 && m_cy + c.h > maxTextureHeight()) {
+ if (maxTextureHeight() > 0 && m_cy + c.h + padding > maxTextureHeight()) {
// We can't make a cache of the required size, so we bail out
return false;
}
@@ -275,6 +282,8 @@ QImage QTextureGlyphCache::textureMapForGlyph(glyph_t g, QFixed subPixelPosition
{
if (m_type == QFontEngineGlyphCache::Raster_RGBMask)
return m_current_fontengine->alphaRGBMapForGlyph(g, subPixelPosition, m_transform);
+ else if (m_type == QFontEngineGlyphCache::Raster_ARGB)
+ return m_current_fontengine->bitmapForGlyph(g, subPixelPosition, m_transform);
return m_current_fontengine->alphaMapForGlyph(g, subPixelPosition, m_transform);
}
@@ -306,6 +315,7 @@ void QImageTextureGlyphCache::createTextureData(int width, int height)
m_image = QImage(width, height, QImage::Format_RGB32);
break;
case QFontEngineGlyphCache::Raster_ARGB:
+ m_image = QImage(width, height, QImage::Format_ARGB32_Premultiplied);
break;
}
}
@@ -322,7 +332,8 @@ void QImageTextureGlyphCache::fillTexture(const Coord &c, glyph_t g, QFixed subP
}
#endif
- if (m_type == QFontEngineGlyphCache::Raster_RGBMask) {
+ if (m_type == QFontEngineGlyphCache::Raster_RGBMask
+ || m_type == QFontEngineGlyphCache::Raster_ARGB) {
QImage ref(m_image.bits() + (c.x * 4 + c.y * m_image.bytesPerLine()),
qMax(mask.width(), c.w), qMax(mask.height(), c.h), m_image.bytesPerLine(),
m_image.format());
diff --git a/src/gui/painting/qtextureglyphcache_p.h b/src/gui/painting/qtextureglyphcache_p.h
index d0fe7ab8cb..d93f57ad80 100644
--- a/src/gui/painting/qtextureglyphcache_p.h
+++ b/src/gui/painting/qtextureglyphcache_p.h
@@ -60,10 +60,6 @@
#include <private/qfontengineglyphcache_p.h>
-#if defined(Q_OS_VXWORKS) && defined(m_type)
-# undef m_type
-#endif
-
#ifndef QT_DEFAULT_TEXTURE_GLYPH_CACHE_WIDTH
#define QT_DEFAULT_TEXTURE_GLYPH_CACHE_WIDTH 256
#endif
diff --git a/src/gui/painting/qtransform.h b/src/gui/painting/qtransform.h
index f98642cd98..060362f63e 100644
--- a/src/gui/painting/qtransform.h
+++ b/src/gui/painting/qtransform.h
@@ -50,12 +50,6 @@
#include <QtCore/qpoint.h>
#include <QtCore/qrect.h>
-#if defined(Q_OS_VXWORKS) && defined(m_type)
-# undef m_type
-#endif
-
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -389,6 +383,4 @@ inline QTransform operator -(const QTransform &a, qreal n)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTRANSFORM_H
diff --git a/src/gui/painting/qvectorpath_p.h b/src/gui/painting/qvectorpath_p.h
index f8ba02dc79..e97d6e1dce 100644
--- a/src/gui/painting/qvectorpath_p.h
+++ b/src/gui/painting/qvectorpath_p.h
@@ -60,8 +60,6 @@
#include <private/qpainter_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -187,6 +185,4 @@ Q_GUI_EXPORT const QVectorPath &qtVectorPathForPath(const QPainterPath &path);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/text/qabstractfontengine_p.h b/src/gui/text/qabstractfontengine_p.h
deleted file mode 100644
index e122cc5b4f..0000000000
--- a/src/gui/text/qabstractfontengine_p.h
+++ /dev/null
@@ -1,108 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
-**
-** This file is part of the QtGui module of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and Digia. For licensing terms and
-** conditions see http://qt.digia.com/licensing. For further information
-** use the contact form at http://qt.digia.com/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 2.1 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-**
-** In addition, as a special exception, Digia gives you certain additional
-** rights. These rights are described in the Digia Qt LGPL Exception
-** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3.0 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU General Public License version 3.0 requirements will be
-** met: http://www.gnu.org/copyleft/gpl.html.
-**
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#ifndef QABSTRACTFONTENGINE_P_H
-#define QABSTRACTFONTENGINE_P_H
-
-//
-// W A R N I N G
-// -------------
-//
-// This file is not part of the Qt API. It exists purely as an
-// implementation detail. This header file may change from version to
-// version without notice, or even be removed.
-//
-// We mean it.
-//
-
-#include "qfontengine_p.h"
-#include "qabstractfontengine_qws.h"
-
-QT_BEGIN_NAMESPACE
-
-class QCustomFontEngine;
-
-class QProxyFontEngine : public QFontEngine
-{
- Q_OBJECT
-public:
- QProxyFontEngine(QAbstractFontEngine *engine, const QFontDef &def);
- virtual ~QProxyFontEngine();
-
- virtual bool stringToCMap(const QChar *str, int len, QGlyphLayout *glyphs, int *nglyphs, ShaperFlags flags) const;
- virtual void recalcAdvances(QGlyphLayout *, ShaperFlags) const;
- virtual QImage alphaMapForGlyph(glyph_t);
- virtual void addGlyphsToPath(glyph_t *glyphs, QFixedPoint *positions, int nglyphs, QPainterPath *path, QTextItem::RenderFlags flags);
- virtual glyph_metrics_t boundingBox(const QGlyphLayout &glyphs);
- virtual glyph_metrics_t boundingBox(glyph_t glyph);
-
- virtual QFixed ascent() const;
- virtual QFixed descent() const;
- virtual QFixed leading() const;
- virtual QFixed xHeight() const;
- virtual QFixed averageCharWidth() const;
- virtual QFixed lineThickness() const;
- virtual QFixed underlinePosition() const;
- virtual qreal maxCharWidth() const;
- virtual qreal minLeftBearing() const;
- virtual qreal minRightBearing() const;
- virtual int glyphCount() const;
-
- virtual bool canRender(const QChar *string, int len);
-
- virtual Type type() const { return Proxy; }
- virtual const char *name() const { return "proxy engine"; }
-
- virtual void draw(QPaintEngine *, qreal, qreal, const QTextItemInt &);
-
- inline QAbstractFontEngine::Capabilities capabilities() const
- { return engineCapabilities; }
-
- bool drawAsOutline() const;
-
-private:
- QAbstractFontEngine *engine;
- QAbstractFontEngine::Capabilities engineCapabilities;
-};
-
-QT_END_NAMESPACE
-
-#endif
diff --git a/src/gui/text/qabstracttextdocumentlayout.cpp b/src/gui/text/qabstracttextdocumentlayout.cpp
index eaca605652..b7b8e919ad 100644
--- a/src/gui/text/qabstracttextdocumentlayout.cpp
+++ b/src/gui/text/qabstracttextdocumentlayout.cpp
@@ -183,7 +183,7 @@ QT_BEGIN_NAMESPACE
This signal is emitted when the specified \a block has been updated.
Subclasses of QAbstractTextDocumentLayout should emit this signal when
- the layout of \a block has changed in order to repaint.
+ the layout of \a block has changed in order to repaint.
*/
/*!
diff --git a/src/gui/text/qabstracttextdocumentlayout.h b/src/gui/text/qabstracttextdocumentlayout.h
index 4979c3b03b..95733f5da7 100644
--- a/src/gui/text/qabstracttextdocumentlayout.h
+++ b/src/gui/text/qabstracttextdocumentlayout.h
@@ -48,8 +48,6 @@
#include <QtGui/qtextcursor.h>
#include <QtGui/qpalette.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -144,6 +142,4 @@ Q_DECLARE_INTERFACE(QTextObjectInterface, "org.qt-project.Qt.QTextObjectInterfac
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QABSTRACTTEXTDOCUMENTLAYOUT_H
diff --git a/src/gui/text/qcssparser.cpp b/src/gui/text/qcssparser.cpp
index 5f610e3fb7..1264330873 100644
--- a/src/gui/text/qcssparser.cpp
+++ b/src/gui/text/qcssparser.cpp
@@ -537,7 +537,7 @@ QSize ValueExtractor::sizeValue(const Declaration &decl)
lengthValueFromData(qvariant_cast<LengthData>(v.at(1)), f));
}
- LengthData x[2] = { {0, LengthData::None }, {0, LengthData::None} };
+ LengthData x[2] = { {0, LengthData::None }, {0, LengthData::None} };
if (decl.d->values.count() > 0)
x[0] = lengthValue(decl.d->values.at(0));
if (decl.d->values.count() > 1)
@@ -917,7 +917,7 @@ void ValueExtractor::borderValue(const Declaration &decl, int *width, QCss::Bord
if (decl.d->values.isEmpty())
return;
-
+
BorderData data;
data.width.number = 0;
data.width.unit = LengthData::None;
@@ -1465,7 +1465,7 @@ QRect Declaration::rectValue() const
{
if (d->values.count() != 1)
return QRect();
-
+
if (d->parsed.isValid())
return qvariant_cast<QRect>(d->parsed);
@@ -1934,7 +1934,7 @@ QVector<StyleRule> StyleSelector::styleRulesForNode(NodePtr node)
return rules;
QMap<uint, StyleRule> weightedRules; // (spec, rule) that will be sorted below
-
+
//prune using indexed stylesheet
for (int sheetIdx = 0; sheetIdx < styleSheets.count(); ++sheetIdx) {
const StyleSheet &styleSheet = styleSheets.at(sheetIdx);
diff --git a/src/gui/text/qfont.cpp b/src/gui/text/qfont.cpp
index 2961cb9493..fc694dc497 100644
--- a/src/gui/text/qfont.cpp
+++ b/src/gui/text/qfont.cpp
@@ -55,7 +55,6 @@
#include "qthread.h"
#include "qthreadstorage.h"
-#include <private/qunicodetables_p.h>
#include "qfont_p.h"
#include <private/qfontengine_p.h>
#include <private/qpainter_p.h>
@@ -207,8 +206,8 @@ extern QMutex *qt_fontdatabase_mutex();
QFontEngine *QFontPrivate::engineForScript(int script) const
{
QMutexLocker locker(qt_fontdatabase_mutex());
- if (script >= QUnicodeTables::Inherited)
- script = QUnicodeTables::Common;
+ if (script <= QChar::Script_Latin)
+ script = QChar::Script_Common;
if (engineData && engineData->fontCache != QFontCache::instance()) {
// throw out engineData that came from a different thread
engineData->ref.deref();
@@ -319,15 +318,17 @@ void QFontPrivate::resolve(uint mask, const QFontPrivate *other)
QFontEngineData::QFontEngineData()
: ref(1), fontCache(QFontCache::instance())
{
- memset(engines, 0, QUnicodeTables::ScriptCount * sizeof(QFontEngine *));
+ memset(engines, 0, QChar::ScriptCount * sizeof(QFontEngine *));
}
QFontEngineData::~QFontEngineData()
{
- for (int i = 0; i < QUnicodeTables::ScriptCount; ++i) {
- if (engines[i])
- engines[i]->ref.deref();
- engines[i] = 0;
+ for (int i = 0; i < QChar::ScriptCount; ++i) {
+ if (engines[i]) {
+ if (!engines[i]->ref.deref())
+ delete engines[i];
+ engines[i] = 0;
+ }
}
}
@@ -1667,7 +1668,7 @@ void QFont::setRawMode(bool enable)
*/
bool QFont::exactMatch() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return (d->rawMode
? engine->type() != QFontEngine::Box
@@ -2363,7 +2364,7 @@ QFontInfo &QFontInfo::operator=(const QFontInfo &fi)
*/
QString QFontInfo::family() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->fontDef.family;
}
@@ -2378,7 +2379,7 @@ QString QFontInfo::family() const
*/
QString QFontInfo::styleName() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->fontDef.styleName;
}
@@ -2390,7 +2391,7 @@ QString QFontInfo::styleName() const
*/
int QFontInfo::pointSize() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return qRound(engine->fontDef.pointSize);
}
@@ -2402,7 +2403,7 @@ int QFontInfo::pointSize() const
*/
qreal QFontInfo::pointSizeF() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->fontDef.pointSize;
}
@@ -2414,7 +2415,7 @@ qreal QFontInfo::pointSizeF() const
*/
int QFontInfo::pixelSize() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->fontDef.pixelSize;
}
@@ -2426,7 +2427,7 @@ int QFontInfo::pixelSize() const
*/
bool QFontInfo::italic() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->fontDef.style != QFont::StyleNormal;
}
@@ -2438,7 +2439,7 @@ bool QFontInfo::italic() const
*/
QFont::Style QFontInfo::style() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return (QFont::Style)engine->fontDef.style;
}
@@ -2450,7 +2451,7 @@ QFont::Style QFontInfo::style() const
*/
int QFontInfo::weight() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->fontDef.weight;
@@ -2515,7 +2516,7 @@ bool QFontInfo::strikeOut() const
*/
bool QFontInfo::fixedPitch() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
#ifdef Q_OS_MAC
if (!engine->fontDef.fixedPitchComputed) {
@@ -2539,7 +2540,7 @@ bool QFontInfo::fixedPitch() const
*/
QFont::StyleHint QFontInfo::styleHint() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return (QFont::StyleHint) engine->fontDef.styleHint;
}
@@ -2567,7 +2568,7 @@ bool QFontInfo::rawMode() const
*/
bool QFontInfo::exactMatch() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return (d->rawMode
? engine->type() != QFontEngine::Box
@@ -2648,24 +2649,6 @@ QFontCache::~QFontCache()
++it;
}
}
- EngineCache::ConstIterator it = engineCache.constBegin(),
- end = engineCache.constEnd();
- while (it != end) {
- if (--it.value().data->cache_count == 0) {
- if (it.value().data->ref.load() == 0) {
- FC_DEBUG("QFontCache::~QFontCache: deleting engine %p key=(%d / %g %g %d %d %d)",
- it.value().data, it.key().script, it.key().def.pointSize,
- it.key().def.pixelSize, it.key().def.weight, it.key().def.style,
- it.key().def.fixedPitch);
-
- delete it.value().data;
- } else {
- FC_DEBUG("QFontCache::~QFontCache: engine = %p still has refcount %d",
- it.value().data, it.value().data->ref.load());
- }
- }
- ++it;
- }
}
void QFontCache::clear()
@@ -2675,9 +2658,12 @@ void QFontCache::clear()
end = engineDataCache.end();
while (it != end) {
QFontEngineData *data = it.value();
- for (int i = 0; i < QUnicodeTables::ScriptCount; ++i) {
+ for (int i = 0; i < QChar::ScriptCount; ++i) {
if (data->engines[i]) {
- data->engines[i]->ref.deref();
+ if (!data->engines[i]->ref.deref()) {
+ Q_ASSERT(engineCacheCount.value(data->engines[i]) == 0);
+ delete data->engines[i];
+ }
data->engines[i] = 0;
}
}
@@ -2685,23 +2671,25 @@ void QFontCache::clear()
}
}
- for (EngineCache::Iterator it = engineCache.begin(), end = engineCache.end();
- it != end; ++it) {
- if (it->data->ref.load() == 0) {
- delete it->data;
- it->data = 0;
- }
- }
-
- for (EngineCache::Iterator it = engineCache.begin(), end = engineCache.end();
- it != end; ++it) {
- if (it->data && it->data->ref.load() == 0) {
- delete it->data;
- it->data = 0;
+ bool mightHaveEnginesLeftForCleanup = true;
+ while (mightHaveEnginesLeftForCleanup) {
+ mightHaveEnginesLeftForCleanup = false;
+ for (EngineCache::Iterator it = engineCache.begin(), end = engineCache.end();
+ it != end; ++it) {
+ if (it.value().data && engineCacheCount.value(it.value().data) > 0) {
+ --engineCacheCount[it.value().data];
+ if (!it.value().data->ref.deref()) {
+ Q_ASSERT(engineCacheCount.value(it.value().data) == 0);
+ delete it.value().data;
+ mightHaveEnginesLeftForCleanup = true;
+ }
+ it.value().data = 0;
+ }
}
}
engineCache.clear();
+ engineCacheCount.clear();
}
@@ -2717,7 +2705,14 @@ QFontEngineData *QFontCache::findEngineData(const QFontDef &def) const
void QFontCache::insertEngineData(const QFontDef &def, QFontEngineData *engineData)
{
+#ifdef QFONTCACHE_DEBUG
FC_DEBUG("QFontCache: inserting new engine data %p", engineData);
+ if (engineDataCache.contains(def)) {
+ FC_DEBUG(" QFontCache already contains engine data %p for key=(%g %g %d %d %d)",
+ engineDataCache.value(def), def.pointSize,
+ def.pixelSize, def.weight, def.style, def.fixedPitch);
+ }
+#endif
engineDataCache.insert(def, engineData);
increaseCost(sizeof(QFontEngineData));
@@ -2742,13 +2737,22 @@ void QFontCache::updateHitCountAndTimeStamp(Engine &value)
FC_DEBUG("QFontCache: found font engine\n"
" %p: timestamp %4u hits %3u ref %2d/%2d, type '%s'",
value.data, value.timestamp, value.hits,
- value.data->ref.load(), value.data->cache_count,
+ value.data->ref.load(), engineCacheCount.value(value.data),
value.data->name());
}
void QFontCache::insertEngine(const Key &key, QFontEngine *engine, bool insertMulti)
{
- FC_DEBUG("QFontCache: inserting new engine %p", engine);
+#ifdef QFONTCACHE_DEBUG
+ FC_DEBUG("QFontCache: inserting new engine %p, refcount %d", engine, engine->ref.load());
+ if (!insertMulti && engineCache.contains(key)) {
+ FC_DEBUG(" QFontCache already contains engine %p for key=(%g %g %d %d %d)",
+ engineCache.value(key).data, key.def.pointSize,
+ key.def.pixelSize, key.def.weight, key.def.style, key.def.fixedPitch);
+ }
+#endif
+
+ engine->ref.ref();
Engine data(engine);
data.timestamp = ++current_timestamp;
@@ -2757,12 +2761,9 @@ void QFontCache::insertEngine(const Key &key, QFontEngine *engine, bool insertMu
engineCache.insertMulti(key, data);
else
engineCache.insert(key, data);
-
// only increase the cost if this is the first time we insert the engine
- if (engine->cache_count == 0)
+ if (++engineCacheCount[engine] == 1)
increaseCost(engine->cache_cost);
-
- ++engine->cache_count;
}
void QFontCache::increaseCost(uint cost)
@@ -2826,11 +2827,8 @@ void QFontCache::timerEvent(QTimerEvent *)
EngineDataCache::ConstIterator it = engineDataCache.constBegin(),
end = engineDataCache.constEnd();
for (; it != end; ++it) {
-#ifdef QFONTCACHE_DEBUG
FC_DEBUG(" %p: ref %2d", it.value(), int(it.value()->ref.load()));
-#endif // QFONTCACHE_DEBUG
-
if (it.value()->ref.load() != 0)
in_use_cost += engine_data_cost;
}
@@ -2844,11 +2842,11 @@ void QFontCache::timerEvent(QTimerEvent *)
for (; it != end; ++it) {
FC_DEBUG(" %p: timestamp %4u hits %2u ref %2d/%2d, cost %u bytes",
it.value().data, it.value().timestamp, it.value().hits,
- it.value().data->ref.load(), it.value().data->cache_count,
+ it.value().data->ref.load(), engineCacheCount.value(it.value().data),
it.value().data->cache_cost);
if (it.value().data->ref.load() != 0)
- in_use_cost += it.value().data->cache_cost / it.value().data->cache_count;
+ in_use_cost += it.value().data->cache_cost / engineCacheCount.value(it.value().data);
}
// attempt to make up for rounding errors
@@ -2894,29 +2892,25 @@ void QFontCache::timerEvent(QTimerEvent *)
FC_DEBUG(" CLEAN engine data:");
// clean out all unused engine data
- EngineDataCache::Iterator it = engineDataCache.begin(),
- end = engineDataCache.end();
- while (it != end) {
- if (it.value()->ref.load() != 0) {
+ EngineDataCache::Iterator it = engineDataCache.begin();
+ while (it != engineDataCache.end()) {
+ if (it.value()->ref.load() == 0) {
+ FC_DEBUG(" %p", it.value());
+ decreaseCost(sizeof(QFontEngineData));
+ delete it.value();
+ it = engineDataCache.erase(it);
+ } else {
++it;
- continue;
}
-
- EngineDataCache::Iterator rem = it++;
-
- decreaseCost(sizeof(QFontEngineData));
-
- FC_DEBUG(" %p", rem.value());
-
- delete rem.value();
- engineDataCache.erase(rem);
}
}
+ FC_DEBUG(" CLEAN engine:");
+
// clean out the engine cache just enough to get below our new max cost
- uint current_cost;
+ bool cost_decreased;
do {
- current_cost = total_cost;
+ cost_decreased = false;
EngineCache::Iterator it = engineCache.begin(),
end = engineCache.end();
@@ -2924,49 +2918,46 @@ void QFontCache::timerEvent(QTimerEvent *)
uint oldest = ~0u;
uint least_popular = ~0u;
- for (; it != end; ++it) {
- if (it.value().data->ref.load() != 0)
+ EngineCache::Iterator jt = end;
+
+ for ( ; it != end; ++it) {
+ if (it.value().data->ref.load() != engineCacheCount.value(it.value().data))
continue;
- if (it.value().timestamp < oldest &&
- it.value().hits <= least_popular) {
+ if (it.value().timestamp < oldest && it.value().hits <= least_popular) {
oldest = it.value().timestamp;
least_popular = it.value().hits;
+ jt = it;
}
}
- FC_DEBUG(" oldest %u least popular %u", oldest, least_popular);
-
- for (it = engineCache.begin(); it != end; ++it) {
- if (it.value().data->ref.load() == 0 &&
- it.value().timestamp == oldest &&
- it.value().hits == least_popular)
- break;
- }
-
+ it = jt;
if (it != end) {
FC_DEBUG(" %p: timestamp %4u hits %2u ref %2d/%2d, type '%s'",
it.value().data, it.value().timestamp, it.value().hits,
- it.value().data->ref.load(), it.value().data->cache_count,
+ it.value().data->ref.load(), engineCacheCount.value(it.value().data),
it.value().data->name());
- if (--it.value().data->cache_count == 0) {
- FC_DEBUG(" DELETE: last occurrence in cache");
-
- decreaseCost(it.value().data->cache_cost);
- delete it.value().data;
- } else {
- /*
- this particular font engine is in the cache multiple
- times... set current_cost to zero, so that we can
- keep looping to get rid of all occurrences
- */
- current_cost = 0;
+ QFontEngine *fontEngine = it.value().data;
+ // get rid of all occurrences
+ it = engineCache.begin();
+ while (it != engineCache.end()) {
+ if (it.value().data == fontEngine) {
+ fontEngine->ref.deref();
+ it = engineCache.erase(it);
+ } else {
+ ++it;
+ }
}
+ // and delete the last occurrence
+ Q_ASSERT(fontEngine->ref.load() == 0);
+ decreaseCost(fontEngine->cache_cost);
+ delete fontEngine;
+ engineCacheCount.remove(fontEngine);
- engineCache.erase(it);
+ cost_decreased = true;
}
- } while (current_cost != total_cost && total_cost > max_cost);
+ } while (cost_decreased && total_cost > max_cost);
}
diff --git a/src/gui/text/qfont.h b/src/gui/text/qfont.h
index c59b222ccc..24a1c4c7c3 100644
--- a/src/gui/text/qfont.h
+++ b/src/gui/text/qfont.h
@@ -47,8 +47,6 @@
#include <QtCore/qsharedpointer.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -350,6 +348,4 @@ Q_GUI_EXPORT QDebug operator<<(QDebug, const QFont &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFONT_H
diff --git a/src/gui/text/qfont_p.h b/src/gui/text/qfont_p.h
index b5e753e246..4cbf51d59c 100644
--- a/src/gui/text/qfont_p.h
+++ b/src/gui/text/qfont_p.h
@@ -57,7 +57,6 @@
#include "QtCore/qmap.h"
#include "QtCore/qobject.h"
#include "QtCore/qstringlist.h"
-#include <private/qunicodetables_p.h>
#include <QtGui/qfontdatabase.h>
#include "private/qfixed_p.h"
@@ -143,7 +142,7 @@ public:
QAtomicInt ref;
QFontCache *fontCache;
- QFontEngine *engines[QUnicodeTables::ScriptCount];
+ QFontEngine *engines[QChar::ScriptCount];
};
@@ -194,9 +193,8 @@ private:
};
-class QFontCache : public QObject
+class Q_AUTOTEST_EXPORT QFontCache : public QObject
{
- Q_OBJECT
public:
// note: these static functions work on a per-thread basis
static QFontCache *instance();
@@ -206,8 +204,7 @@ public:
~QFontCache();
void clear();
- // universal key structure. QFontEngineDatas and QFontEngines are cached using
- // the same keys
+
struct Key {
Key() : script(0), screen(0) { }
Key(const QFontDef &d, int c, int s = 0)
@@ -246,13 +243,14 @@ public:
typedef QMap<Key,Engine> EngineCache;
EngineCache engineCache;
+ QHash<QFontEngine *, int> engineCacheCount;
QFontEngine *findEngine(const Key &key);
void updateHitCountAndTimeStamp(Engine &value);
void insertEngine(const Key &key, QFontEngine *engine, bool insertMulti = false);
- private:
+private:
void increaseCost(uint cost);
void decreaseCost(uint cost);
void timerEvent(QTimerEvent *event);
diff --git a/src/gui/text/qfont_qpa.cpp b/src/gui/text/qfont_qpa.cpp
index a955f5446d..be432dc52f 100644
--- a/src/gui/text/qfont_qpa.cpp
+++ b/src/gui/text/qfont_qpa.cpp
@@ -72,7 +72,7 @@ QString QFont::defaultFamily() const
{
QPlatformFontDatabase *fontDB = QGuiApplicationPrivate::platformIntegration()->fontDatabase();
const QStringList fallbacks = fontDB->fallbacksForFamily(QString(), QFont::StyleNormal
- , QFont::StyleHint(d->request.styleHint), QUnicodeTables::Common);
+ , QFont::StyleHint(d->request.styleHint), QChar::Script_Common);
if (!fallbacks.isEmpty())
return fallbacks.first();
return QString();
diff --git a/src/gui/text/qfontdatabase.cpp b/src/gui/text/qfontdatabase.cpp
index 5b728403cb..e3270b430f 100644
--- a/src/gui/text/qfontdatabase.cpp
+++ b/src/gui/text/qfontdatabase.cpp
@@ -48,7 +48,6 @@
#include "qmutex.h"
#include "qfile.h"
#include "qfileinfo.h"
-#include "private/qunicodetables_p.h"
#include "qfontengine_p.h"
#include <qpa/qplatformintegration.h>
@@ -384,133 +383,6 @@ QtFontFoundry *QtFontFamily::foundry(const QString &f, bool create)
return foundries[count++];
}
-// ### copied to tools/makeqpf/qpf2.cpp
-
-// see the Unicode subset bitfields in the MSDN docs
-static int requiredUnicodeBits[QFontDatabase::WritingSystemsCount][2] = {
- // Any,
- { 127, 127 },
- // Latin,
- { 0, 127 },
- // Greek,
- { 7, 127 },
- // Cyrillic,
- { 9, 127 },
- // Armenian,
- { 10, 127 },
- // Hebrew,
- { 11, 127 },
- // Arabic,
- { 13, 127 },
- // Syriac,
- { 71, 127 },
- //Thaana,
- { 72, 127 },
- //Devanagari,
- { 15, 127 },
- //Bengali,
- { 16, 127 },
- //Gurmukhi,
- { 17, 127 },
- //Gujarati,
- { 18, 127 },
- //Oriya,
- { 19, 127 },
- //Tamil,
- { 20, 127 },
- //Telugu,
- { 21, 127 },
- //Kannada,
- { 22, 127 },
- //Malayalam,
- { 23, 127 },
- //Sinhala,
- { 73, 127 },
- //Thai,
- { 24, 127 },
- //Lao,
- { 25, 127 },
- //Tibetan,
- { 70, 127 },
- //Myanmar,
- { 74, 127 },
- // Georgian,
- { 26, 127 },
- // Khmer,
- { 80, 127 },
- // SimplifiedChinese,
- { 126, 127 },
- // TraditionalChinese,
- { 126, 127 },
- // Japanese,
- { 126, 127 },
- // Korean,
- { 56, 127 },
- // Vietnamese,
- { 0, 127 }, // same as latin1
- // Other,
- { 126, 127 },
- // Ogham,
- { 78, 127 },
- // Runic,
- { 79, 127 },
- // Nko,
- { 14, 127 },
-};
-
-#define SimplifiedChineseCsbBit 18
-#define TraditionalChineseCsbBit 20
-#define JapaneseCsbBit 17
-#define KoreanCsbBit 21
-
-QList<QFontDatabase::WritingSystem> qt_determine_writing_systems_from_truetype_bits(quint32 unicodeRange[4], quint32 codePageRange[2])
-{
- QList<QFontDatabase::WritingSystem> writingSystems;
- bool hasScript = false;
-
- int i;
- for(i = 0; i < QFontDatabase::WritingSystemsCount; i++) {
- int bit = requiredUnicodeBits[i][0];
- int index = bit/32;
- int flag = 1 << (bit&31);
- if (bit != 126 && unicodeRange[index] & flag) {
- bit = requiredUnicodeBits[i][1];
- index = bit/32;
-
- flag = 1 << (bit&31);
- if (bit == 127 || unicodeRange[index] & flag) {
- writingSystems.append(QFontDatabase::WritingSystem(i));
- hasScript = true;
- // qDebug("font %s: index=%d, flag=%8x supports script %d", familyName.latin1(), index, flag, i);
- }
- }
- }
- if(codePageRange[0] & (1 << SimplifiedChineseCsbBit)) {
- writingSystems.append(QFontDatabase::SimplifiedChinese);
- hasScript = true;
- //qDebug("font %s supports Simplified Chinese", familyName.latin1());
- }
- if(codePageRange[0] & (1 << TraditionalChineseCsbBit)) {
- writingSystems.append(QFontDatabase::TraditionalChinese);
- hasScript = true;
- //qDebug("font %s supports Traditional Chinese", familyName.latin1());
- }
- if(codePageRange[0] & (1 << JapaneseCsbBit)) {
- writingSystems.append(QFontDatabase::Japanese);
- hasScript = true;
- //qDebug("font %s supports Japanese", familyName.latin1());
- }
- if(codePageRange[0] & (1 << KoreanCsbBit)) {
- writingSystems.append(QFontDatabase::Korean);
- hasScript = true;
- //qDebug("font %s supports Korean", familyName.latin1());
- }
- if (!hasScript)
- writingSystems.append(QFontDatabase::Symbol);
-
- return writingSystems;
-}
-
class QFontDatabasePrivate
{
@@ -601,48 +473,40 @@ QtFontFamily *QFontDatabasePrivate::family(const QString &f, bool create)
static const int scriptForWritingSystem[] = {
- QUnicodeTables::Common, // Any
- QUnicodeTables::Latin, // Latin
- QUnicodeTables::Greek, // Greek
- QUnicodeTables::Cyrillic, // Cyrillic
- QUnicodeTables::Armenian, // Armenian
- QUnicodeTables::Hebrew, // Hebrew
- QUnicodeTables::Arabic, // Arabic
- QUnicodeTables::Syriac, // Syriac
- QUnicodeTables::Thaana, // Thaana
- QUnicodeTables::Devanagari, // Devanagari
- QUnicodeTables::Bengali, // Bengali
- QUnicodeTables::Gurmukhi, // Gurmukhi
- QUnicodeTables::Gujarati, // Gujarati
- QUnicodeTables::Oriya, // Oriya
- QUnicodeTables::Tamil, // Tamil
- QUnicodeTables::Telugu, // Telugu
- QUnicodeTables::Kannada, // Kannada
- QUnicodeTables::Malayalam, // Malayalam
- QUnicodeTables::Sinhala, // Sinhala
- QUnicodeTables::Thai, // Thai
- QUnicodeTables::Lao, // Lao
- QUnicodeTables::Tibetan, // Tibetan
- QUnicodeTables::Myanmar, // Myanmar
- QUnicodeTables::Georgian, // Georgian
- QUnicodeTables::Khmer, // Khmer
- QUnicodeTables::Common, // SimplifiedChinese
- QUnicodeTables::Common, // TraditionalChinese
- QUnicodeTables::Common, // Japanese
- QUnicodeTables::Hangul, // Korean
- QUnicodeTables::Common, // Vietnamese
- QUnicodeTables::Common, // Yi
- QUnicodeTables::Common, // Tagalog
- QUnicodeTables::Common, // Hanunoo
- QUnicodeTables::Common, // Buhid
- QUnicodeTables::Common, // Tagbanwa
- QUnicodeTables::Common, // Limbu
- QUnicodeTables::Common, // TaiLe
- QUnicodeTables::Common, // Braille
- QUnicodeTables::Common, // Symbol
- QUnicodeTables::Ogham, // Ogham
- QUnicodeTables::Runic, // Runic
- QUnicodeTables::Nko // Nko
+ QChar::Script_Common, // Any
+ QChar::Script_Latin, // Latin
+ QChar::Script_Greek, // Greek
+ QChar::Script_Cyrillic, // Cyrillic
+ QChar::Script_Armenian, // Armenian
+ QChar::Script_Hebrew, // Hebrew
+ QChar::Script_Arabic, // Arabic
+ QChar::Script_Syriac, // Syriac
+ QChar::Script_Thaana, // Thaana
+ QChar::Script_Devanagari, // Devanagari
+ QChar::Script_Bengali, // Bengali
+ QChar::Script_Gurmukhi, // Gurmukhi
+ QChar::Script_Gujarati, // Gujarati
+ QChar::Script_Oriya, // Oriya
+ QChar::Script_Tamil, // Tamil
+ QChar::Script_Telugu, // Telugu
+ QChar::Script_Kannada, // Kannada
+ QChar::Script_Malayalam, // Malayalam
+ QChar::Script_Sinhala, // Sinhala
+ QChar::Script_Thai, // Thai
+ QChar::Script_Lao, // Lao
+ QChar::Script_Tibetan, // Tibetan
+ QChar::Script_Myanmar, // Myanmar
+ QChar::Script_Georgian, // Georgian
+ QChar::Script_Khmer, // Khmer
+ QChar::Script_Han, // SimplifiedChinese
+ QChar::Script_Han, // TraditionalChinese
+ QChar::Script_Han, // Japanese
+ QChar::Script_Hangul, // Korean
+ QChar::Script_Latin, // Vietnamese
+ QChar::Script_Common, // Symbol
+ QChar::Script_Ogham, // Ogham
+ QChar::Script_Runic, // Runic
+ QChar::Script_Nko // Nko
};
int qt_script_for_writing_system(QFontDatabase::WritingSystem writingSystem)
@@ -1059,7 +923,7 @@ static void match(int script, const QFontDef &request,
uint score_adjust = 0;
- bool supported = (script == QUnicodeTables::Common);
+ bool supported = (script == QChar::Script_Common);
for (int ws = 1; !supported && ws < QFontDatabase::WritingSystemsCount; ++ws) {
if (scriptForWritingSystem[ws] != script)
continue;
diff --git a/src/gui/text/qfontdatabase.h b/src/gui/text/qfontdatabase.h
index 373ff5e950..05f1a85f24 100644
--- a/src/gui/text/qfontdatabase.h
+++ b/src/gui/text/qfontdatabase.h
@@ -46,8 +46,6 @@
#include <QtCore/qstring.h>
#include <QtGui/qfont.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -166,6 +164,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFONTDATABASE_H
diff --git a/src/gui/text/qfontdatabase_qpa.cpp b/src/gui/text/qfontdatabase_qpa.cpp
index a72b21ede3..be42e892fa 100644
--- a/src/gui/text/qfontdatabase_qpa.cpp
+++ b/src/gui/text/qfontdatabase_qpa.cpp
@@ -68,11 +68,8 @@ Q_GUI_EXPORT void qt_registerFont(const QString &familyName, const QString &sty
f->fixedPitch = fixedPitch;
for (int i = 0; i < QFontDatabase::WritingSystemsCount; ++i) {
- if (writingSystems.supported(QFontDatabase::WritingSystem(i))) {
+ if (writingSystems.supported(QFontDatabase::WritingSystem(i)))
f->writingSystems[i] = QtFontFamily::Supported;
- } else {
- f->writingSystems[i] = QtFontFamily::Unsupported;
- }
}
QtFontFoundry *foundry = f->foundry(foundryname, true);
@@ -104,7 +101,7 @@ Q_GUI_EXPORT void qt_registerAliasToFontFamily(const QString &familyName, const
f->aliases.push_back(alias);
}
-static QStringList fallbackFamilies(const QString &family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script)
+static QStringList fallbackFamilies(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script)
{
QStringList retList = QGuiApplicationPrivate::platformIntegration()->fontDatabase()->fallbacksForFamily(family,style,styleHint,script);
QFontDatabasePrivate *db = privateDb();
@@ -175,7 +172,7 @@ QFontEngine *loadSingleEngine(int script,
QFontCache::Key key(def,script);
QFontEngine *engine = QFontCache::instance()->findEngine(key);
if (!engine) {
- engine = pfdb->fontEngine(def,QUnicodeTables::Script(script),size->handle);
+ engine = pfdb->fontEngine(def, QChar::Script(script), size->handle);
if (engine) {
QFontCache::Key key(def,script);
QFontCache::instance()->instance()->insertEngine(key,engine);
@@ -200,7 +197,7 @@ QFontEngine *loadEngine(int script, const QFontDef &request,
QFont::StyleHint styleHint = QFont::StyleHint(request.styleHint);
if (styleHint == QFont::AnyStyle && request.fixedPitch)
styleHint = QFont::TypeWriter;
- family->fallbackFamilies = fallbackFamilies(family->name,fontStyle,styleHint,QUnicodeTables::Script(script));
+ family->fallbackFamilies = fallbackFamilies(family->name, fontStyle, styleHint, QChar::Script(script));
family->askedForFallback = true;
}
@@ -210,7 +207,7 @@ QFontEngine *loadEngine(int script, const QFontDef &request,
fallbacks = family->fallbackFamilies;
QPlatformFontDatabase *pfdb = QGuiApplicationPrivate::platformIntegration()->fontDatabase();
- QFontEngineMulti *pfMultiEngine = pfdb->fontEngineMulti(engine, QUnicodeTables::Script(script));
+ QFontEngineMulti *pfMultiEngine = pfdb->fontEngineMulti(engine, QChar::Script(script));
pfMultiEngine->setFallbackFamiliesList(fallbacks);
engine = pfMultiEngine;
@@ -322,7 +319,7 @@ QFontDatabase::findFont(int script, const QFontPrivate *fp,
+ fallbackFamilies(request.family,
QFont::Style(request.style),
QFont::StyleHint(request.styleHint),
- QUnicodeTables::Script(script));
+ QChar::Script(script));
for (int i = 0; !engine && i < fallbacks.size(); i++) {
QFontDef def = request;
@@ -427,7 +424,7 @@ void QFontDatabase::load(const QFontPrivate *d, int script)
}
if (fe->symbol || (d->request.styleStrategy & QFont::NoFontMerging)) {
- for (int i = 0; i < QUnicodeTables::ScriptCount; ++i) {
+ for (int i = 0; i < QChar::ScriptCount; ++i) {
if (!d->engineData->engines[i]) {
d->engineData->engines[i] = fe;
fe->ref.ref();
diff --git a/src/gui/text/qfontengine.cpp b/src/gui/text/qfontengine.cpp
index 87fa202fb4..47c59fb826 100644
--- a/src/gui/text/qfontengine.cpp
+++ b/src/gui/text/qfontengine.cpp
@@ -135,7 +135,7 @@ static HB_Fixed hb_getFontMetric(HB_Font font, HB_FontMetric metric)
return 0;
}
-HB_Error QFontEngine::getPointInOutline(HB_Glyph glyph, int flags, hb_uint32 point, HB_Fixed *xpos, HB_Fixed *ypos, hb_uint32 *nPoints)
+int QFontEngine::getPointInOutline(glyph_t glyph, int flags, quint32 point, QFixed *xpos, QFixed *ypos, quint32 *nPoints)
{
Q_UNUSED(glyph)
Q_UNUSED(flags)
@@ -149,7 +149,7 @@ HB_Error QFontEngine::getPointInOutline(HB_Glyph glyph, int flags, hb_uint32 poi
static HB_Error hb_getPointInOutline(HB_Font font, HB_Glyph glyph, int flags, hb_uint32 point, HB_Fixed *xpos, HB_Fixed *ypos, hb_uint32 *nPoints)
{
QFontEngine *fe = (QFontEngine *)font->userData;
- return fe->getPointInOutline(glyph, flags, point, xpos, ypos, nPoints);
+ return (HB_Error)fe->getPointInOutline(glyph, flags, point, (QFixed *)xpos, (QFixed *)ypos, (quint32 *)nPoints);
}
static const HB_FontClass hb_fontClass = {
@@ -165,27 +165,80 @@ static HB_Error hb_getSFntTable(void *font, HB_Tag tableTag, HB_Byte *buffer, HB
return HB_Err_Ok;
}
+static void hb_freeFace(void *face)
+{
+ qHBFreeFace((HB_Face)face);
+}
+
+
+#ifdef QT_BUILD_INTERNAL
+// for testing purpose only, not thread-safe!
+static QList<QFontEngine *> *enginesCollector = 0;
+
+Q_AUTOTEST_EXPORT void QFontEngine_startCollectingEngines()
+{
+ delete enginesCollector;
+ enginesCollector = new QList<QFontEngine *>();
+}
+
+Q_AUTOTEST_EXPORT QList<QFontEngine *> QFontEngine_stopCollectingEngines()
+{
+ Q_ASSERT(enginesCollector);
+ QList<QFontEngine *> ret = *enginesCollector;
+ delete enginesCollector;
+ enginesCollector = 0;
+ return ret;
+}
+#endif // QT_BUILD_INTERNAL
+
+
// QFontEngine
QFontEngine::QFontEngine()
- : QObject(), ref(0)
+ : QObject(), ref(0),
+ font_(0), font_destroy_func(0),
+ face_(0), face_destroy_func(0)
{
- cache_count = 0;
fsType = 0;
symbol = false;
- memset(&hbFont, 0, sizeof(hbFont));
- hbFont.klass = &hb_fontClass;
- hbFont.userData = this;
- hbFace = 0;
+ {
+ HB_FontRec *hbFont = (HB_FontRec *) malloc(sizeof(HB_FontRec));
+ Q_CHECK_PTR(hbFont);
+ memset(hbFont, 0, sizeof(HB_FontRec));
+ hbFont->klass = &hb_fontClass;
+ hbFont->userData = this;
+
+ font_ = (void *)hbFont;
+ font_destroy_func = free;
+ }
+
glyphFormat = -1;
m_subPixelPositionCount = 0;
+
+#ifdef QT_BUILD_INTERNAL
+ if (enginesCollector)
+ enginesCollector->append(this);
+#endif
}
QFontEngine::~QFontEngine()
{
m_glyphCaches.clear();
- qHBFreeFace(hbFace);
+
+ if (font_ && font_destroy_func) {
+ font_destroy_func(font_);
+ font_ = 0;
+ }
+ if (face_ && face_destroy_func) {
+ face_destroy_func(face_);
+ face_ = 0;
+ }
+
+#ifdef QT_BUILD_INTERNAL
+ if (enginesCollector)
+ enginesCollector->removeOne(this);
+#endif
}
QFixed QFontEngine::lineThickness() const
@@ -206,34 +259,38 @@ QFixed QFontEngine::underlinePosition() const
return ((lineThickness() * 2) + 3) / 6;
}
-HB_Font QFontEngine::harfbuzzFont() const
+void *QFontEngine::harfbuzzFont() const
{
- if (!hbFont.x_ppem) {
+ HB_FontRec *hbFont = (HB_FontRec *)font_;
+ if (!hbFont->x_ppem) {
QFixed emSquare = emSquareSize();
- hbFont.x_ppem = fontDef.pixelSize;
- hbFont.y_ppem = fontDef.pixelSize * fontDef.stretch / 100;
- hbFont.x_scale = (QFixed(hbFont.x_ppem * (1 << 16)) / emSquare).value();
- hbFont.y_scale = (QFixed(hbFont.y_ppem * (1 << 16)) / emSquare).value();
+ hbFont->y_ppem = fontDef.pixelSize;
+ hbFont->x_ppem = fontDef.pixelSize * fontDef.stretch / 100;
+ hbFont->x_scale = (QFixed(hbFont->x_ppem * (1 << 16)) / emSquare).value();
+ hbFont->y_scale = (QFixed(hbFont->y_ppem * (1 << 16)) / emSquare).value();
}
- return &hbFont;
+ return font_;
}
-HB_Face QFontEngine::harfbuzzFace() const
+void *QFontEngine::harfbuzzFace() const
{
- if (!hbFace) {
- hbFace = qHBNewFace(const_cast<QFontEngine *>(this), hb_getSFntTable);
+ if (!face_) {
+ HB_Face hbFace = qHBNewFace(const_cast<QFontEngine *>(this), hb_getSFntTable);
Q_CHECK_PTR(hbFace);
+ if (hbFace->font_for_init != 0)
+ hbFace = qHBLoadFace(hbFace);
+ hbFace->isSymbolFont = symbol;
+
+ face_ = (void *)hbFace;
+ face_destroy_func = hb_freeFace;
}
- return hbFace;
+ return face_;
}
-HB_Face QFontEngine::initializedHarfbuzzFace() const
+bool QFontEngine::supportsScript(QChar::Script script) const
{
- HB_Face face = harfbuzzFace();
- if (face != 0 && face->font_for_init != 0)
- face = qHBLoadFace(face);
-
- return face;
+ HB_Face hbFace = (HB_Face)harfbuzzFace();
+ return hbFace->supported_scripts[script_to_hbscript(script)];
}
glyph_metrics_t QFontEngine::boundingBox(glyph_t glyph, const QTransform &matrix)
@@ -268,9 +325,9 @@ QFixed QFontEngine::averageCharWidth() const
return bb.xoff;
}
-bool QFontEngine::supportsTransformations(const QTransform &transform) const
+bool QFontEngine::supportsTransformation(const QTransform &transform) const
{
- return (transform.type() >= QTransform::TxProject);
+ return transform.type() < QTransform::TxProject;
}
void QFontEngine::getGlyphPositions(const QGlyphLayout &glyphs, const QTransform &matrix, QTextItem::RenderFlags flags,
@@ -649,6 +706,13 @@ QImage QFontEngine::alphaRGBMapForGlyph(glyph_t glyph, QFixed /*subPixelPosition
return rgbMask;
}
+QImage QFontEngine::bitmapForGlyph(glyph_t, QFixed subPixelPosition, const QTransform&)
+{
+ Q_UNUSED(subPixelPosition);
+
+ return QImage();
+}
+
QFixed QFontEngine::subPixelPositionForX(QFixed x) const
{
if (m_subPixelPositionCount <= 1 || !supportsSubPixelPositions())
@@ -1194,7 +1258,7 @@ bool QFontEngineBox::stringToCMap(const QChar *, int len, QGlyphLayout *glyphs,
return false;
}
- memset(glyphs->glyphs, 0, len * sizeof(HB_Glyph));
+ memset(glyphs->glyphs, 0, len * sizeof(glyph_t));
*nglyphs = len;
glyphs->numGlyphs = len;
@@ -1352,11 +1416,8 @@ QFontEngineMulti::~QFontEngineMulti()
{
for (int i = 0; i < engines.size(); ++i) {
QFontEngine *fontEngine = engines.at(i);
- if (fontEngine) {
- fontEngine->ref.deref();
- if (fontEngine->cache_count == 0 && fontEngine->ref.load() == 0)
- delete fontEngine;
- }
+ if (fontEngine && !fontEngine->ref.deref())
+ delete fontEngine;
}
}
diff --git a/src/gui/text/qfontengine_ft.cpp b/src/gui/text/qfontengine_ft.cpp
index 07e4cae1ee..19b4411b47 100644
--- a/src/gui/text/qfontengine_ft.cpp
+++ b/src/gui/text/qfontengine_ft.cpp
@@ -46,6 +46,8 @@
#include "qfontengine_ft_p.h"
#include "private/qimage_p.h"
+#include <private/qharfbuzz_p.h>
+
#ifndef QT_NO_FREETYPE
#include "qfile.h"
@@ -183,9 +185,9 @@ int QFreetypeFace::fsType() const
return fsType;
}
-HB_Error QFreetypeFace::getPointInOutline(HB_Glyph glyph, int flags, hb_uint32 point, HB_Fixed *xpos, HB_Fixed *ypos, hb_uint32 *nPoints)
+int QFreetypeFace::getPointInOutline(glyph_t glyph, int flags, quint32 point, QFixed *xpos, QFixed *ypos, quint32 *nPoints)
{
- if (HB_Error error = (HB_Error)FT_Load_Glyph(face, glyph, flags))
+ if (int error = FT_Load_Glyph(face, glyph, flags))
return error;
if (face->glyph->format != FT_GLYPH_FORMAT_OUTLINE)
@@ -198,8 +200,8 @@ HB_Error QFreetypeFace::getPointInOutline(HB_Glyph glyph, int flags, hb_uint32 p
if (point > *nPoints)
return HB_Err_Invalid_SubTable;
- *xpos = face->glyph->outline.points[point].x;
- *ypos = face->glyph->outline.points[point].y;
+ *xpos = QFixed::fromFixed(face->glyph->outline.points[point].x);
+ *ypos = QFixed::fromFixed(face->glyph->outline.points[point].y);
return HB_Err_Ok;
}
@@ -258,8 +260,12 @@ QFreetypeFace *QFreetypeFace::getFace(const QFontEngine::FaceId &face_id,
}
newFreetype->face = face;
- newFreetype->hbFace = qHBNewFace(face, hb_getSFntTable);
- Q_CHECK_PTR(newFreetype->hbFace);
+ HB_Face hbFace = qHBNewFace(face, hb_getSFntTable);
+ Q_CHECK_PTR(hbFace);
+ if (hbFace->font_for_init != 0)
+ hbFace = qHBLoadFace(hbFace);
+ newFreetype->hbFace = (void *)hbFace;
+
newFreetype->ref.store(1);
newFreetype->xsize = 0;
newFreetype->ysize = 0;
@@ -313,7 +319,7 @@ void QFreetypeFace::release(const QFontEngine::FaceId &face_id)
{
QtFreetypeData *freetypeData = qt_getFreetypeData();
if (!ref.deref()) {
- qHBFreeFace(hbFace);
+ qHBFreeFace((HB_Face)hbFace);
FT_Done_Face(face);
if(freetypeData->faces.contains(face_id))
freetypeData->faces.take(face_id);
@@ -654,7 +660,6 @@ QFontEngineFT::~QFontEngineFT()
{
if (freetype)
freetype->release(face_id);
- hbFace = 0; // we share the face in QFreeTypeFace, don't let ~QFontEngine delete it
}
bool QFontEngineFT::init(FaceId faceId, bool antialias, GlyphFormat format,
@@ -691,7 +696,7 @@ bool QFontEngineFT::init(FaceId faceId, bool antialias, GlyphFormat format,
symbol = bool(fontDef.family.contains(QLatin1String("symbol"), Qt::CaseInsensitive));
}
// #####
- freetype->hbFace->isSymbolFont = symbol;
+ ((HB_Face)freetype->hbFace)->isSymbolFont = symbol;
lbearing = rbearing = SHRT_MIN;
freetype->computeSize(fontDef, &xsize, &ysize, &defaultGlyphSet.outline_drawing);
@@ -729,12 +734,17 @@ bool QFontEngineFT::init(FaceId faceId, bool antialias, GlyphFormat format,
if (line_thickness < 1)
line_thickness = 1;
- hbFont.x_ppem = face->size->metrics.x_ppem;
- hbFont.y_ppem = face->size->metrics.y_ppem;
- hbFont.x_scale = face->size->metrics.x_scale;
- hbFont.y_scale = face->size->metrics.y_scale;
+ HB_FontRec *hbFont = (HB_FontRec *)font_;
+ hbFont->x_ppem = face->size->metrics.x_ppem;
+ hbFont->y_ppem = face->size->metrics.y_ppem;
+ hbFont->x_scale = face->size->metrics.x_scale;
+ hbFont->y_scale = face->size->metrics.y_scale;
- hbFace = freetype->hbFace;
+ // ###
+ if (face_ && face_destroy_func)
+ face_destroy_func(face_);
+ face_ = freetype->hbFace;
+ face_destroy_func = 0; // we share the face in QFreeTypeFace, don't let ~QFontEngine delete it
metrics = face->size->metrics;
@@ -889,18 +899,28 @@ QFontEngineFT::Glyph *QFontEngineFT::loadGlyph(QGlyphSet *set, uint glyph,
info.yOff = 0;
if ((set && set->outline_drawing) || fetchMetricsOnly) {
- // If the advance doesn't fit in signed char, don't cache it
- if (qAbs(info.xOff) >= 128)
- return 0;
- g = new Glyph;
- g->data = 0;
- g->linearAdvance = slot->linearHoriAdvance >> 10;
int left = FLOOR(slot->metrics.horiBearingX);
int right = CEIL(slot->metrics.horiBearingX + slot->metrics.width);
int top = CEIL(slot->metrics.horiBearingY);
int bottom = FLOOR(slot->metrics.horiBearingY - slot->metrics.height);
- g->width = TRUNC(right-left);
- g->height = TRUNC(top-bottom);
+ int width = right-left;
+ int height = top-bottom;
+
+ // If any of the metrics are too large to fit, don't cache them
+ if (qAbs(info.xOff) >= 128
+ || qAbs(TRUNC(top)) >= 128
+ || TRUNC(width) >= 256
+ || TRUNC(height) >= 256
+ || qAbs(TRUNC(left)) >= 128
+ || qAbs(TRUNC(ROUND(slot->advance.x))) >= 128) {
+ return 0;
+ }
+
+ g = new Glyph;
+ g->data = 0;
+ g->linearAdvance = slot->linearHoriAdvance >> 10;
+ g->width = TRUNC(width);
+ g->height = TRUNC(height);
g->x = TRUNC(left);
g->y = TRUNC(top);
g->advance = TRUNC(ROUND(slot->advance.x));
@@ -1570,12 +1590,15 @@ void QFontEngineFT::recalcAdvances(QGlyphLayout *glyphs, QFontEngine::ShaperFlag
glyphs->advances_x[i] = design ? QFixed::fromFixed(face->glyph->linearHoriAdvance >> 10)
: QFixed::fromFixed(face->glyph->metrics.horiAdvance).round();
}
- if (fontDef.styleStrategy & QFont::ForceIntegerMetrics)
- glyphs->advances_x[i] = glyphs->advances_x[i].round();
glyphs->advances_y[i] = 0;
}
if (face)
unlockFace();
+
+ if (fontDef.styleStrategy & QFont::ForceIntegerMetrics) {
+ for (int i = 0; i < glyphs->numGlyphs; ++i)
+ glyphs->advances_x[i] = glyphs->advances_x[i].round();
+ }
}
glyph_metrics_t QFontEngineFT::boundingBox(const QGlyphLayout &glyphs)
@@ -2026,13 +2049,13 @@ void QFontEngineFT::QGlyphSet::setGlyph(glyph_t index, QFixed subPixelPosition,
}
}
-HB_Error QFontEngineFT::getPointInOutline(HB_Glyph glyph, int flags, hb_uint32 point, HB_Fixed *xpos, HB_Fixed *ypos, hb_uint32 *nPoints)
+int QFontEngineFT::getPointInOutline(glyph_t glyph, int flags, quint32 point, QFixed *xpos, QFixed *ypos, quint32 *nPoints)
{
lockFace();
bool hsubpixel = true;
int vfactor = 1;
int load_flags = loadFlags(0, Format_A8, flags, hsubpixel, vfactor);
- HB_Error result = freetype->getPointInOutline(glyph, load_flags, point, xpos, ypos, nPoints);
+ int result = freetype->getPointInOutline(glyph, load_flags, point, xpos, ypos, nPoints);
unlockFace();
return result;
}
diff --git a/src/gui/text/qfontengine_ft_p.h b/src/gui/text/qfontengine_ft_p.h
index 2f2a705329..434eb76c33 100644
--- a/src/gui/text/qfontengine_ft_p.h
+++ b/src/gui/text/qfontengine_ft_p.h
@@ -69,8 +69,6 @@
#include <qmutex.h>
-#include "private/qharfbuzz_copy_p.h"
-
QT_BEGIN_NAMESPACE
class QFontEngineFTRawFont;
@@ -101,7 +99,7 @@ struct QFreetypeFace
}
FT_Face face;
- HB_Face hbFace;
+ void *hbFace;
int xsize; // 26.6
int ysize; // 26.6
FT_Matrix matrix;
@@ -113,7 +111,7 @@ struct QFreetypeFace
int fsType() const;
- HB_Error getPointInOutline(HB_Glyph glyph, int flags, hb_uint32 point, HB_Fixed *xpos, HB_Fixed *ypos, hb_uint32 *nPoints);
+ int getPointInOutline(glyph_t glyph, int flags, quint32 point, QFixed *xpos, QFixed *ypos, quint32 *nPoints);
static void addGlyphToPath(FT_Face face, FT_GlyphSlot g, const QFixedPoint &point, QPainterPath *path, FT_Fixed x_scale, FT_Fixed y_scale);
static void addBitmapToPath(FT_GlyphSlot slot, const QFixedPoint &point, QPainterPath *path, bool = false);
@@ -298,7 +296,7 @@ private:
bool init(FaceId faceId, bool antialias, GlyphFormat format,
QFreetypeFace *freetypeFace);
- virtual HB_Error getPointInOutline(HB_Glyph glyph, int flags, hb_uint32 point, HB_Fixed *xpos, HB_Fixed *ypos, hb_uint32 *nPoints);
+ virtual int getPointInOutline(glyph_t glyph, int flags, quint32 point, QFixed *xpos, QFixed *ypos, quint32 *nPoints);
virtual void setDefaultHintStyle(HintStyle style);
diff --git a/src/gui/text/qfontengine_p.h b/src/gui/text/qfontengine_p.h
index c2d22d9e83..f0f8713f74 100644
--- a/src/gui/text/qfontengine_p.h
+++ b/src/gui/text/qfontengine_p.h
@@ -60,16 +60,10 @@
#include "private/qtextengine_p.h"
#include "private/qfont_p.h"
-
-
#include <private/qfontengineglyphcache_p.h>
-struct glyph_metrics_t;
-typedef unsigned int glyph_t;
-
QT_BEGIN_NAMESPACE
-class QChar;
class QPainterPath;
struct QGlyphLayout;
@@ -81,6 +75,7 @@ struct QGlyphLayout;
((quint32)(ch4)) \
)
+typedef void (*qt_destroy_func_t) (void *user_data);
class Q_GUI_EXPORT QFontEngine : public QObject
{
@@ -112,7 +107,8 @@ public:
Format_Render = Format_None,
Format_Mono,
Format_A8,
- Format_A32
+ Format_A32,
+ Format_ARGB
};
enum ShaperFlag {
@@ -165,11 +161,6 @@ public:
/* returns 0 as glyph index for non existent glyphs */
virtual bool stringToCMap(const QChar *str, int len, QGlyphLayout *glyphs, int *nglyphs, ShaperFlags flags) const = 0;
-
- /**
- * This is a callback from harfbuzz. The font engine uses the font-system in use to find out the
- * advances of each glyph and set it on the layout.
- */
virtual void recalcAdvances(QGlyphLayout *, ShaperFlags) const {}
virtual void doKerning(QGlyphLayout *, ShaperFlags) const;
@@ -191,6 +182,7 @@ public:
virtual QImage alphaMapForGlyph(glyph_t, const QTransform &t);
virtual QImage alphaMapForGlyph(glyph_t, QFixed subPixelPosition, const QTransform &t);
virtual QImage alphaRGBMapForGlyph(glyph_t, QFixed subPixelPosition, const QTransform &t);
+ virtual QImage bitmapForGlyph(glyph_t, QFixed subPixelPosition, const QTransform &t);
virtual QImage *lockedAlphaMapForGlyph(glyph_t glyph, QFixed subPixelPosition,
GlyphFormat neededFormat,
const QTransform &t = QTransform(),
@@ -241,7 +233,7 @@ public:
return canRender(utf16, utf16len);
}
- virtual bool supportsTransformations(const QTransform &transform) const;
+ virtual bool supportsTransformation(const QTransform &transform) const;
virtual Type type() const = 0;
@@ -250,11 +242,11 @@ public:
virtual QFontEngine *cloneWithSize(qreal /*pixelSize*/) const { return 0; }
- HB_Font harfbuzzFont() const;
- HB_Face harfbuzzFace() const;
- HB_Face initializedHarfbuzzFace() const;
+ void *harfbuzzFont() const;
+ void *harfbuzzFace() const;
+ bool supportsScript(QChar::Script script) const;
- virtual HB_Error getPointInOutline(HB_Glyph glyph, int flags, hb_uint32 point, HB_Fixed *xpos, HB_Fixed *ypos, hb_uint32 *nPoints);
+ virtual int getPointInOutline(glyph_t glyph, int flags, quint32 point, QFixed *xpos, QFixed *ypos, quint32 *nPoints);
void setGlyphCache(const void *key, QFontEngineGlyphCache *data);
QFontEngineGlyphCache *glyphCache(const void *key, QFontEngineGlyphCache::Type type, const QTransform &transform) const;
@@ -274,12 +266,15 @@ public:
QAtomicInt ref;
QFontDef fontDef;
+
+ mutable void *font_;
+ mutable qt_destroy_func_t font_destroy_func;
+ mutable void *face_;
+ mutable qt_destroy_func_t face_destroy_func;
+
uint cache_cost; // amount of mem used in kb by the font
- int cache_count;
uint fsType : 16;
bool symbol;
- mutable HB_FontRec hbFont;
- mutable HB_Face hbFace;
struct KernPair {
uint left_right;
QFixed adjust;
diff --git a/src/gui/text/qfontengine_qpa.cpp b/src/gui/text/qfontengine_qpa.cpp
index 4a61b27298..837850e4be 100644
--- a/src/gui/text/qfontengine_qpa.cpp
+++ b/src/gui/text/qfontengine_qpa.cpp
@@ -710,7 +710,7 @@ void QFontEngineMultiQPA::ensureFallbackFamiliesQueried()
if (fallbacksQueried)
return;
QStringList fallbacks = QGuiApplicationPrivate::instance()->platformIntegration()->fontDatabase()->fallbacksForFamily(engine(0)->fontDef.family, QFont::Style(engine(0)->fontDef.style)
- , QFont::AnyStyle, QUnicodeTables::Script(script));
+ , QFont::AnyStyle, QChar::Script(script));
setFallbackFamiliesList(fallbacks);
}
@@ -762,7 +762,7 @@ QFontEngine* QFontEngineMultiQPA::createMultiFontEngine(QFontEngine *fe, int scr
it++;
}
if (!engine) {
- engine = QGuiApplicationPrivate::instance()->platformIntegration()->fontDatabase()->fontEngineMulti(fe, QUnicodeTables::Script(script));
+ engine = QGuiApplicationPrivate::instance()->platformIntegration()->fontDatabase()->fontEngineMulti(fe, QChar::Script(script));
QFontCache::instance()->insertEngine(key, engine, /* insertMulti */ !faceIsLocal);
}
Q_ASSERT(engine);
diff --git a/src/gui/text/qfontengine_qpa_p.h b/src/gui/text/qfontengine_qpa_p.h
index 161b11e2d5..5fbdafdf56 100644
--- a/src/gui/text/qfontengine_qpa_p.h
+++ b/src/gui/text/qfontengine_qpa_p.h
@@ -61,8 +61,6 @@
#include <QtCore/QFile>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QFontEngine;
@@ -268,6 +266,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFONTENGINE_QPA_P_H
diff --git a/src/gui/text/qfontengine_qpf.cpp b/src/gui/text/qfontengine_qpf.cpp
index df80e9e87d..def671c62f 100644
--- a/src/gui/text/qfontengine_qpf.cpp
+++ b/src/gui/text/qfontengine_qpf.cpp
@@ -50,6 +50,7 @@
#include <QtCore/qbuffer.h>
#if !defined(QT_NO_FREETYPE)
#include "private/qfontengine_ft_p.h"
+#include <private/qharfbuzz_p.h>
#endif
#include "private/qcore_unix_p.h" // overrides QT_OPEN
@@ -666,9 +667,7 @@ void QFontEngineQPF::draw(QPaintEngine *p, qreal _x, qreal _y, const QTextItemIn
void QFontEngineQPF::addOutlineToPath(qreal x, qreal y, const QGlyphLayout &glyphs, QPainterPath *path, QTextItem::RenderFlags flags)
{
- if (renderingFontEngine &&
- (renderingFontEngine->type() != QFontEngine::Proxy
- || static_cast<QProxyFontEngine *>(renderingFontEngine)->capabilities() & QAbstractFontEngine::CanOutlineGlyphs)) {
+ if (renderingFontEngine && renderingFontEngine->type() != QFontEngine::Proxy) {
renderingFontEngine->addOutlineToPath(x, y, glyphs, path, flags);
return;
}
@@ -856,12 +855,12 @@ void QFontEngineQPF::doKerning(QGlyphLayout *g, QFontEngine::ShaperFlags flags)
QFontEngine::doKerning(g, flags);
}
-HB_Error QFontEngineQPF::getPointInOutline(HB_Glyph glyph, int flags, hb_uint32 point, HB_Fixed *xpos, HB_Fixed *ypos, hb_uint32 *nPoints)
+int QFontEngineQPF::getPointInOutline(glyph_t glyph, int flags, quint32 point, QFixed *xpos, QFixed *ypos, quint32 *nPoints)
{
if (!freetype)
return HB_Err_Not_Covered;
lockFace();
- HB_Error result = freetype->getPointInOutline(glyph, flags, point, xpos, ypos, nPoints);
+ int result = freetype->getPointInOutline(glyph, flags, point, xpos, ypos, nPoints);
unlockFace();
return result;
}
diff --git a/src/gui/text/qfontengine_qpf_p.h b/src/gui/text/qfontengine_qpf_p.h
index 9392872a26..35355d3a65 100644
--- a/src/gui/text/qfontengine_qpf_p.h
+++ b/src/gui/text/qfontengine_qpf_p.h
@@ -208,7 +208,7 @@ public:
FT_Face lockFace() const;
void unlockFace() const;
void doKerning(QGlyphLayout *g, ShaperFlags flags) const;
- virtual HB_Error getPointInOutline(HB_Glyph glyph, int flags, hb_uint32 point, HB_Fixed *xpos, HB_Fixed *ypos, hb_uint32 *nPoints);
+ virtual int getPointInOutline(glyph_t glyph, int flags, quint32 point, QFixed *xpos, QFixed *ypos, quint32 *nPoints);
virtual QFixed emSquareSize() const;
#endif
diff --git a/src/gui/text/qfontengineglyphcache_p.h b/src/gui/text/qfontengineglyphcache_p.h
index 1dc4db00c4..ac01c78399 100644
--- a/src/gui/text/qfontengineglyphcache_p.h
+++ b/src/gui/text/qfontengineglyphcache_p.h
@@ -78,6 +78,7 @@ public:
virtual ~QFontEngineGlyphCache() { }
Type cacheType() const { return m_type; }
+ const QTransform &transform() const { return m_transform; }
QTransform m_transform;
QFontEngineGlyphCache::Type m_type;
diff --git a/src/gui/text/qfontinfo.h b/src/gui/text/qfontinfo.h
index c9cc42ead5..efa8f6ef61 100644
--- a/src/gui/text/qfontinfo.h
+++ b/src/gui/text/qfontinfo.h
@@ -45,8 +45,6 @@
#include <QtGui/qfont.h>
#include <QtCore/qsharedpointer.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -87,6 +85,4 @@ Q_DECLARE_SHARED(QFontInfo)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFONTINFO_H
diff --git a/src/gui/text/qfontmetrics.cpp b/src/gui/text/qfontmetrics.cpp
index f3151da16b..ad3d2bb813 100644
--- a/src/gui/text/qfontmetrics.cpp
+++ b/src/gui/text/qfontmetrics.cpp
@@ -45,7 +45,6 @@
#include "qfont_p.h"
#include "qfontengine_p.h"
-#include <private/qunicodetables_p.h>
#include <math.h>
@@ -262,7 +261,7 @@ bool QFontMetrics::operator ==(const QFontMetrics &other) const
*/
int QFontMetrics::ascent() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return qRound(engine->ascent());
}
@@ -280,7 +279,7 @@ int QFontMetrics::ascent() const
*/
int QFontMetrics::descent() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return qRound(engine->descent());
}
@@ -295,7 +294,7 @@ int QFontMetrics::descent() const
*/
int QFontMetrics::height() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return qRound(engine->ascent()) + qRound(engine->descent());
}
@@ -309,7 +308,7 @@ int QFontMetrics::height() const
*/
int QFontMetrics::leading() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return qRound(engine->leading());
}
@@ -323,7 +322,7 @@ int QFontMetrics::leading() const
*/
int QFontMetrics::lineSpacing() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return qRound(engine->leading()) + qRound(engine->ascent()) + qRound(engine->descent());
}
@@ -340,7 +339,7 @@ int QFontMetrics::lineSpacing() const
*/
int QFontMetrics::minLeftBearing() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return qRound(engine->minLeftBearing());
}
@@ -357,7 +356,7 @@ int QFontMetrics::minLeftBearing() const
*/
int QFontMetrics::minRightBearing() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return qRound(engine->minRightBearing());
}
@@ -367,7 +366,7 @@ int QFontMetrics::minRightBearing() const
*/
int QFontMetrics::maxWidth() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return qRound(engine->maxCharWidth());
}
@@ -378,10 +377,10 @@ int QFontMetrics::maxWidth() const
*/
int QFontMetrics::xHeight() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
if (d->capital == QFont::SmallCaps)
- return qRound(d->smallCapsFontPrivate()->engineForScript(QUnicodeTables::Common)->ascent());
+ return qRound(d->smallCapsFontPrivate()->engineForScript(QChar::Script_Common)->ascent());
return qRound(engine->xHeight());
}
@@ -392,7 +391,7 @@ int QFontMetrics::xHeight() const
*/
int QFontMetrics::averageCharWidth() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return qRound(engine->averageCharWidth());
}
@@ -403,7 +402,7 @@ int QFontMetrics::averageCharWidth() const
*/
bool QFontMetrics::inFont(QChar ch) const
{
- const int script = QUnicodeTables::script(ch);
+ const int script = ch.script();
QFontEngine *engine = d->engineForScript(script);
Q_ASSERT(engine != 0);
if (engine->type() == QFontEngine::Box)
@@ -417,7 +416,7 @@ bool QFontMetrics::inFont(QChar ch) const
*/
bool QFontMetrics::inFontUcs4(uint ucs4) const
{
- const int script = QUnicodeTables::script(ucs4);
+ const int script = QChar::script(ucs4);
QFontEngine *engine = d->engineForScript(script);
Q_ASSERT(engine != 0);
if (engine->type() == QFontEngine::Box)
@@ -439,7 +438,7 @@ bool QFontMetrics::inFontUcs4(uint ucs4) const
*/
int QFontMetrics::leftBearing(QChar ch) const
{
- const int script = QUnicodeTables::script(ch);
+ const int script = ch.script();
QFontEngine *engine;
if (d->capital == QFont::SmallCaps && ch.isLower())
engine = d->smallCapsFontPrivate()->engineForScript(script);
@@ -474,7 +473,7 @@ int QFontMetrics::leftBearing(QChar ch) const
*/
int QFontMetrics::rightBearing(QChar ch) const
{
- const int script = QUnicodeTables::script(ch);
+ const int script = ch.script();
QFontEngine *engine;
if (d->capital == QFont::SmallCaps && ch.isLower())
engine = d->smallCapsFontPrivate()->engineForScript(script);
@@ -527,10 +526,10 @@ int QFontMetrics::width(const QString &text, int len, int flags) const
return 0;
if (flags & Qt::TextBypassShaping) {
- // Skip harfbuzz complex shaping, only use advances
+ // Skip complex shaping, only use advances
int numGlyphs = len;
QVarLengthGlyphLayoutArray glyphs(numGlyphs);
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
if (!engine->stringToCMap(text.data(), len, &glyphs, &numGlyphs, 0)) {
glyphs.resize(numGlyphs);
if (!engine->stringToCMap(text.data(), len, &glyphs, &numGlyphs, 0))
@@ -577,7 +576,7 @@ int QFontMetrics::width(QChar ch) const
if (QChar::category(ch.unicode()) == QChar::Mark_NonSpacing)
return 0;
- const int script = QUnicodeTables::script(ch);
+ const int script = ch.script();
QFontEngine *engine;
if (d->capital == QFont::SmallCaps && ch.isLower())
engine = d->smallCapsFontPrivate()->engineForScript(script);
@@ -607,14 +606,13 @@ int QFontMetrics::width(QChar ch) const
*/
int QFontMetrics::charWidth(const QString &text, int pos) const
{
+ int width = 0;
if (pos < 0 || pos > (int)text.length())
- return 0;
-
- QChar ch = text.unicode()[pos];
- const int script = QUnicodeTables::script(ch);
- int width;
+ return width;
- if (script != QUnicodeTables::Common) {
+ QChar ch = text.at(pos);
+ const int script = ch.script();
+ if (script != QChar::Script_Common) {
// complex script shaping. Have to do some hard work
int from = qMax(0, pos - 8);
int to = qMin(text.length(), pos + 8);
@@ -623,9 +621,7 @@ int QFontMetrics::charWidth(const QString &text, int pos) const
layout.ignoreBidi = true;
layout.itemize();
width = qRound(layout.width(pos-from, 1));
- } else if (QChar::category(ch.unicode()) == QChar::Mark_NonSpacing) {
- width = 0;
- } else {
+ } else if (ch.category() != QChar::Mark_NonSpacing) {
QFontEngine *engine;
if (d->capital == QFont::SmallCaps && ch.isLower())
engine = d->smallCapsFontPrivate()->engineForScript(script);
@@ -694,7 +690,7 @@ QRect QFontMetrics::boundingRect(const QString &text) const
*/
QRect QFontMetrics::boundingRect(QChar ch) const
{
- const int script = QUnicodeTables::script(ch);
+ const int script = ch.script();
QFontEngine *engine;
if (d->capital == QFont::SmallCaps && ch.isLower())
engine = d->smallCapsFontPrivate()->engineForScript(script);
@@ -895,7 +891,7 @@ QString QFontMetrics::elidedText(const QString &text, Qt::TextElideMode mode, in
*/
int QFontMetrics::underlinePos() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return qRound(engine->underlinePosition());
}
@@ -931,7 +927,7 @@ int QFontMetrics::strikeOutPos() const
*/
int QFontMetrics::lineWidth() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return qRound(engine->lineThickness());
}
@@ -1129,7 +1125,7 @@ bool QFontMetricsF::operator ==(const QFontMetricsF &other) const
*/
qreal QFontMetricsF::ascent() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->ascent().toReal();
}
@@ -1148,7 +1144,7 @@ qreal QFontMetricsF::ascent() const
*/
qreal QFontMetricsF::descent() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->descent().toReal();
}
@@ -1163,7 +1159,7 @@ qreal QFontMetricsF::descent() const
*/
qreal QFontMetricsF::height() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return (engine->ascent() + engine->descent()).toReal();
@@ -1178,7 +1174,7 @@ qreal QFontMetricsF::height() const
*/
qreal QFontMetricsF::leading() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->leading().toReal();
}
@@ -1192,7 +1188,7 @@ qreal QFontMetricsF::leading() const
*/
qreal QFontMetricsF::lineSpacing() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return (engine->leading() + engine->ascent() + engine->descent()).toReal();
}
@@ -1209,7 +1205,7 @@ qreal QFontMetricsF::lineSpacing() const
*/
qreal QFontMetricsF::minLeftBearing() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->minLeftBearing();
}
@@ -1226,7 +1222,7 @@ qreal QFontMetricsF::minLeftBearing() const
*/
qreal QFontMetricsF::minRightBearing() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->minRightBearing();
}
@@ -1236,7 +1232,7 @@ qreal QFontMetricsF::minRightBearing() const
*/
qreal QFontMetricsF::maxWidth() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->maxCharWidth();
}
@@ -1247,10 +1243,10 @@ qreal QFontMetricsF::maxWidth() const
*/
qreal QFontMetricsF::xHeight() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
if (d->capital == QFont::SmallCaps)
- return d->smallCapsFontPrivate()->engineForScript(QUnicodeTables::Common)->ascent().toReal();
+ return d->smallCapsFontPrivate()->engineForScript(QChar::Script_Common)->ascent().toReal();
return engine->xHeight().toReal();
}
@@ -1261,7 +1257,7 @@ qreal QFontMetricsF::xHeight() const
*/
qreal QFontMetricsF::averageCharWidth() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->averageCharWidth().toReal();
}
@@ -1272,7 +1268,7 @@ qreal QFontMetricsF::averageCharWidth() const
*/
bool QFontMetricsF::inFont(QChar ch) const
{
- const int script = QUnicodeTables::script(ch);
+ const int script = ch.script();
QFontEngine *engine = d->engineForScript(script);
Q_ASSERT(engine != 0);
if (engine->type() == QFontEngine::Box)
@@ -1288,7 +1284,7 @@ bool QFontMetricsF::inFont(QChar ch) const
*/
bool QFontMetricsF::inFontUcs4(uint ucs4) const
{
- const int script = QUnicodeTables::script(ucs4);
+ const int script = QChar::script(ucs4);
QFontEngine *engine = d->engineForScript(script);
Q_ASSERT(engine != 0);
if (engine->type() == QFontEngine::Box)
@@ -1310,7 +1306,7 @@ bool QFontMetricsF::inFontUcs4(uint ucs4) const
*/
qreal QFontMetricsF::leftBearing(QChar ch) const
{
- const int script = QUnicodeTables::script(ch);
+ const int script = ch.script();
QFontEngine *engine;
if (d->capital == QFont::SmallCaps && ch.isLower())
engine = d->smallCapsFontPrivate()->engineForScript(script);
@@ -1345,7 +1341,7 @@ qreal QFontMetricsF::leftBearing(QChar ch) const
*/
qreal QFontMetricsF::rightBearing(QChar ch) const
{
- const int script = QUnicodeTables::script(ch);
+ const int script = ch.script();
QFontEngine *engine;
if (d->capital == QFont::SmallCaps && ch.isLower())
engine = d->smallCapsFontPrivate()->engineForScript(script);
@@ -1414,10 +1410,10 @@ qreal QFontMetricsF::width(const QString &text) const
*/
qreal QFontMetricsF::width(QChar ch) const
{
- if (QChar::category(ch.unicode()) == QChar::Mark_NonSpacing)
+ if (ch.category() == QChar::Mark_NonSpacing)
return 0.;
- const int script = QUnicodeTables::script(ch);
+ const int script = ch.script();
QFontEngine *engine;
if (d->capital == QFont::SmallCaps && ch.isLower())
engine = d->smallCapsFontPrivate()->engineForScript(script);
@@ -1482,7 +1478,7 @@ QRectF QFontMetricsF::boundingRect(const QString &text) const
*/
QRectF QFontMetricsF::boundingRect(QChar ch) const
{
- const int script = QUnicodeTables::script(ch);
+ const int script = ch.script();
QFontEngine *engine;
if (d->capital == QFont::SmallCaps && ch.isLower())
engine = d->smallCapsFontPrivate()->engineForScript(script);
@@ -1682,7 +1678,7 @@ QString QFontMetricsF::elidedText(const QString &text, Qt::TextElideMode mode, q
*/
qreal QFontMetricsF::underlinePos() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->underlinePosition().toReal();
}
@@ -1717,7 +1713,7 @@ qreal QFontMetricsF::strikeOutPos() const
*/
qreal QFontMetricsF::lineWidth() const
{
- QFontEngine *engine = d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = d->engineForScript(QChar::Script_Common);
Q_ASSERT(engine != 0);
return engine->lineThickness().toReal();
}
diff --git a/src/gui/text/qfontmetrics.h b/src/gui/text/qfontmetrics.h
index ab7437b6fb..00b38eb674 100644
--- a/src/gui/text/qfontmetrics.h
+++ b/src/gui/text/qfontmetrics.h
@@ -48,8 +48,6 @@
#include <QtCore/qrect.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -191,6 +189,4 @@ Q_DECLARE_SHARED(QFontMetricsF)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFONTMETRICS_H
diff --git a/src/gui/text/qglyphrun.h b/src/gui/text/qglyphrun.h
index 43743d8a99..435379085e 100644
--- a/src/gui/text/qglyphrun.h
+++ b/src/gui/text/qglyphrun.h
@@ -49,8 +49,6 @@
#if !defined(QT_NO_RAWFONT)
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -130,8 +128,6 @@ Q_DECLARE_SHARED(QGlyphRun)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_RAWFONT
#endif // QGLYPHRUN_H
diff --git a/src/gui/text/qglyphrun_p.h b/src/gui/text/qglyphrun_p.h
index c70aa91db1..2e209a3429 100644
--- a/src/gui/text/qglyphrun_p.h
+++ b/src/gui/text/qglyphrun_p.h
@@ -60,8 +60,6 @@
#if !defined(QT_NO_RAWFONT)
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QGlyphRunPrivate: public QSharedData
@@ -111,8 +109,6 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_RAWFONT
#endif // QGLYPHRUN_P_H
diff --git a/src/gui/text/qharfbuzz_copy_p.h b/src/gui/text/qharfbuzz_copy_p.h
deleted file mode 100644
index 34acca3f9a..0000000000
--- a/src/gui/text/qharfbuzz_copy_p.h
+++ /dev/null
@@ -1,95 +0,0 @@
-/*
- * Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies)
- * Copyright (C) 2007 Red Hat, Inc.
- *
- * This code is a modified version of some part of HarfBuzz,
- * an OpenType Layout engine library.
- *
- * Permission is hereby granted, without written agreement and without
- * license or royalty fees, to use, copy, modify, and distribute this
- * software and its documentation for any purpose, provided that the
- * above copyright notice and the following two paragraphs appear in
- * all copies of this software.
- *
- * IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE TO ANY PARTY FOR
- * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES
- * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN
- * IF THE COPYRIGHT HOLDER HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
- * DAMAGE.
- *
- * THE COPYRIGHT HOLDER SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING,
- * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
- * FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
- * ON AN "AS IS" BASIS, AND THE COPYRIGHT HOLDER HAS NO OBLIGATION TO
- * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
- *
- * Red Hat Author(s): Behdad Esfahbod
- */
-
-#ifndef QHARFBUZZ_COPY_P_H
-#define QHARFBUZZ_COPY_P_H
-
-/*
- The purpose of this header file is to allow inclusion of the private
- headers for font and text classes without having to pull in the full
- harfbuzz library under QTDIR/src/3rdparty/harfbuzz/src
-*/
-#if defined(QT_BUILD_GUI_LIB) || defined(QT_COMPILES_IN_HARFBUZZ)
-#include <private/qharfbuzz_p.h>
-#else
-
-extern "C" {
-
-#ifdef __xlC__
-typedef unsigned hb_bitfield;
-#else
-typedef QT_PREPEND_NAMESPACE(quint8) hb_bitfield;
-#endif
-
-typedef enum {
- /* no error */
- HB_Err_Ok = 0x0000,
- HB_Err_Not_Covered = 0xFFFF,
-
- /* _hb_err() is called whenever returning the following errors,
- * and in a couple places for HB_Err_Not_Covered too. */
-
- /* programmer error */
- HB_Err_Invalid_Argument = 0x1A66,
-
- /* font error */
- HB_Err_Invalid_SubTable_Format = 0x157F,
- HB_Err_Invalid_SubTable = 0x1570,
- HB_Err_Read_Error = 0x6EAD,
-
- /* system error */
- HB_Err_Out_Of_Memory = 0xDEAD
-} HB_Error;
-
-typedef QT_PREPEND_NAMESPACE(quint32) HB_Glyph;
-typedef void * HB_Font;
-typedef void * HB_Face;
-typedef void * HB_FontRec;
-typedef QT_PREPEND_NAMESPACE(quint32) hb_uint32;
-typedef QT_PREPEND_NAMESPACE(qint32) HB_Fixed;
-
-typedef struct {
- HB_Fixed x;
- HB_Fixed y;
-} HB_FixedPoint;
-
-// The GlyphAttrbutes class is used inline so it needs to be complete.
-typedef struct {
- hb_bitfield justification :4; /* Justification class */
- hb_bitfield clusterStart :1; /* First glyph of representation of cluster */
- hb_bitfield mark :1; /* needs to be positioned around base char */
- hb_bitfield zeroWidth :1; /* ZWJ, ZWNJ etc, with no width */
- hb_bitfield dontPrint :1;
- hb_bitfield combiningClass :8;
-} HB_GlyphAttributes;
-
-}
-
-#endif // ifdef QT_BUILD_GUI_LIB
-
-#endif // QHARFBUZZ_COPY_P_H
diff --git a/src/gui/text/qplatformfontdatabase.cpp b/src/gui/text/qplatformfontdatabase.cpp
index 070550730d..4e2a2df66a 100644
--- a/src/gui/text/qplatformfontdatabase.cpp
+++ b/src/gui/text/qplatformfontdatabase.cpp
@@ -278,8 +278,7 @@ void QPlatformFontDatabase::populateFontDatabase()
option to fall back to the fonts given by \a fallbacks if \a fontEngine does not support
a certain character.
*/
-QFontEngineMulti *QPlatformFontDatabase::fontEngineMulti(QFontEngine *fontEngine,
- QUnicodeTables::Script script)
+QFontEngineMulti *QPlatformFontDatabase::fontEngineMulti(QFontEngine *fontEngine, QChar::Script script)
{
return new QFontEngineMultiQPA(fontEngine, script);
}
@@ -288,7 +287,7 @@ QFontEngineMulti *QPlatformFontDatabase::fontEngineMulti(QFontEngine *fontEngine
Returns the font engine that can be used to render the font described by
the font definition, \a fontDef, in the specified \a script.
*/
-QFontEngine *QPlatformFontDatabase::fontEngine(const QFontDef &fontDef, QUnicodeTables::Script script, void *handle)
+QFontEngine *QPlatformFontDatabase::fontEngine(const QFontDef &fontDef, QChar::Script script, void *handle)
{
Q_UNUSED(script);
Q_UNUSED(handle);
@@ -312,7 +311,7 @@ QFontEngine *QPlatformFontDatabase::fontEngine(const QByteArray &fontData, qreal
Returns a list of alternative fonts for the specified \a family and
\a style and \a script using the \a styleHint given.
*/
-QStringList QPlatformFontDatabase::fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const
+QStringList QPlatformFontDatabase::fallbacksForFamily(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script) const
{
Q_UNUSED(family);
Q_UNUSED(style);
@@ -414,6 +413,107 @@ bool QPlatformFontDatabase::fontsAlwaysScalable() const
return ret;
}
+
+// ### copied to tools/makeqpf/qpf2.cpp
+
+// see the Unicode subset bitfields in the MSDN docs
+static const ushort requiredUnicodeBits[QFontDatabase::WritingSystemsCount][2] = {
+ { 127, 127 }, // Any
+ { 0, 127 }, // Latin
+ { 7, 127 }, // Greek
+ { 9, 127 }, // Cyrillic
+ { 10, 127 }, // Armenian
+ { 11, 127 }, // Hebrew
+ { 13, 127 }, // Arabic
+ { 71, 127 }, // Syriac
+ { 72, 127 }, // Thaana
+ { 15, 127 }, // Devanagari
+ { 16, 127 }, // Bengali
+ { 17, 127 }, // Gurmukhi
+ { 18, 127 }, // Gujarati
+ { 19, 127 }, // Oriya
+ { 20, 127 }, // Tamil
+ { 21, 127 }, // Telugu
+ { 22, 127 }, // Kannada
+ { 23, 127 }, // Malayalam
+ { 73, 127 }, // Sinhala
+ { 24, 127 }, // Thai
+ { 25, 127 }, // Lao
+ { 70, 127 }, // Tibetan
+ { 74, 127 }, // Myanmar
+ { 26, 127 }, // Georgian
+ { 80, 127 }, // Khmer
+ { 126, 127 }, // SimplifiedChinese
+ { 126, 127 }, // TraditionalChinese
+ { 126, 127 }, // Japanese
+ { 56, 127 }, // Korean
+ { 0, 127 }, // Vietnamese (same as latin1)
+ { 126, 127 }, // Other
+ { 78, 127 }, // Ogham
+ { 79, 127 }, // Runic
+ { 14, 127 }, // Nko
+};
+
+enum {
+ SimplifiedChineseCsbBit = 18,
+ TraditionalChineseCsbBit = 20,
+ JapaneseCsbBit = 17,
+ KoreanCsbBit = 21
+};
+
+/*!
+ Helper function that determines the writing systems support by a given
+ \a unicodeRange and \a codePageRange.
+
+ \since 5.1
+*/
+QSupportedWritingSystems QPlatformFontDatabase::writingSystemsFromTrueTypeBits(quint32 unicodeRange[4], quint32 codePageRange[2])
+{
+ QSupportedWritingSystems writingSystems;
+
+ bool hasScript = false;
+ for (int i = 0; i < QFontDatabase::WritingSystemsCount; ++i) {
+ int bit = requiredUnicodeBits[i][0];
+ int index = bit/32;
+ int flag = 1 << (bit&31);
+ if (bit != 126 && (unicodeRange[index] & flag)) {
+ bit = requiredUnicodeBits[i][1];
+ index = bit/32;
+
+ flag = 1 << (bit&31);
+ if (bit == 127 || (unicodeRange[index] & flag)) {
+ writingSystems.setSupported(QFontDatabase::WritingSystem(i));
+ hasScript = true;
+ // qDebug("font %s: index=%d, flag=%8x supports script %d", familyName.latin1(), index, flag, i);
+ }
+ }
+ }
+ if (codePageRange[0] & (1 << SimplifiedChineseCsbBit)) {
+ writingSystems.setSupported(QFontDatabase::SimplifiedChinese);
+ hasScript = true;
+ //qDebug("font %s supports Simplified Chinese", familyName.latin1());
+ }
+ if (codePageRange[0] & (1 << TraditionalChineseCsbBit)) {
+ writingSystems.setSupported(QFontDatabase::TraditionalChinese);
+ hasScript = true;
+ //qDebug("font %s supports Traditional Chinese", familyName.latin1());
+ }
+ if (codePageRange[0] & (1 << JapaneseCsbBit)) {
+ writingSystems.setSupported(QFontDatabase::Japanese);
+ hasScript = true;
+ //qDebug("font %s supports Japanese", familyName.latin1());
+ }
+ if (codePageRange[0] & (1 << KoreanCsbBit)) {
+ writingSystems.setSupported(QFontDatabase::Korean);
+ hasScript = true;
+ //qDebug("font %s supports Korean", familyName.latin1());
+ }
+ if (!hasScript)
+ writingSystems.setSupported(QFontDatabase::Symbol);
+
+ return writingSystems;
+}
+
/*!
\class QPlatformFontDatabase
\since 5.0
diff --git a/src/gui/text/qplatformfontdatabase.h b/src/gui/text/qplatformfontdatabase.h
index 319447c19f..6e53eba98b 100644
--- a/src/gui/text/qplatformfontdatabase.h
+++ b/src/gui/text/qplatformfontdatabase.h
@@ -59,8 +59,6 @@
#include <QtGui/QFontDatabase>
#include <QtGui/private/qfont_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -98,9 +96,9 @@ class Q_GUI_EXPORT QPlatformFontDatabase
public:
virtual ~QPlatformFontDatabase();
virtual void populateFontDatabase();
- virtual QFontEngineMulti *fontEngineMulti(QFontEngine *fontEngine, QUnicodeTables::Script script);
- virtual QFontEngine *fontEngine(const QFontDef &fontDef, QUnicodeTables::Script script, void *handle);
- virtual QStringList fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const;
+ virtual QFontEngineMulti *fontEngineMulti(QFontEngine *fontEngine, QChar::Script script);
+ virtual QFontEngine *fontEngine(const QFontDef &fontDef, QChar::Script script, void *handle);
+ virtual QStringList fallbacksForFamily(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script) const;
virtual QStringList addApplicationFont(const QByteArray &fontData, const QString &fileName);
virtual void releaseHandle(void *handle);
@@ -114,6 +112,9 @@ public:
virtual bool fontsAlwaysScalable() const;
virtual QList<int> standardSizes() const;
+ // helper
+ static QSupportedWritingSystems writingSystemsFromTrueTypeBits(quint32 unicodeRange[4], quint32 codePageRange[2]);
+
//callback
static void registerQPF2Font(const QByteArray &dataArray, void *handle);
static void registerFont(const QString &familyname, const QString &stylename,
@@ -125,6 +126,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMFONTDATABASE_H
diff --git a/src/gui/text/qrawfont.cpp b/src/gui/text/qrawfont.cpp
index 279f0ecd90..f52b46eeae 100644
--- a/src/gui/text/qrawfont.cpp
+++ b/src/gui/text/qrawfont.cpp
@@ -45,6 +45,7 @@
#include "qrawfont.h"
#include "qrawfont_p.h"
+#include "qplatformfontdatabase.h"
#include <QtCore/qendian.h>
@@ -125,6 +126,20 @@ QT_BEGIN_NAMESPACE
*/
/*!
+ \enum QRawFont::LayoutFlag
+ \since 5.1
+
+ This enum tells the function advancesForGlyphIndexes() how to calculate the advances.
+
+ \value SeparateAdvances Will calculate the advance for each glyph separately.
+ \value KernedAdvances Will apply kerning between adjacent glyphs. Note that OpenType GPOS based
+ kerning is currently not supported.
+ \value UseDesignMetrics Use design metrics instead of hinted metrics adjusted to the resolution
+ of the paint device.
+ Can be OR-ed with any of the options above.
+*/
+
+/*!
Constructs an invalid QRawFont.
*/
QRawFont::QRawFont()
@@ -509,39 +524,60 @@ bool QRawFont::glyphIndexesForChars(const QChar *chars, int numChars, quint32 *g
}
/*!
- \fn QVector<QPointF> QRawFont::advancesForGlyphIndexes(const QVector<quint32> &glyphIndexes) const
+ \fn QVector<QPointF> QRawFont::advancesForGlyphIndexes(const QVector<quint32> &glyphIndexes, LayoutFlags layoutFlags) const
+ \since 5.1
+
+ Returns the QRawFont's advances for each of the \a glyphIndexes in pixel units. The advances
+ give the distance from the position of a given glyph to where the next glyph should be drawn
+ to make it appear as if the two glyphs are unspaced. How the advances are calculated is
+ controlled by \a layoutFlags.
+
+ \sa QTextLine::horizontalAdvance(), QFontMetricsF::width()
+*/
+
+/*!
+ \fn QVector<QPointF> QRawFont::advancesForGlyphIndexes(const QVector<quint32> &glyphIndexes) const
+
+ \overload
Returns the QRawFont's advances for each of the \a glyphIndexes in pixel units. The advances
give the distance from the position of a given glyph to where the next glyph should be drawn
- to make it appear as if the two glyphs are unspaced.
+ to make it appear as if the two glyphs are unspaced. The advance of each glyph is calculated
+ separately.
\sa QTextLine::horizontalAdvance(), QFontMetricsF::width()
*/
/*!
+ \since 5.1
+
Returns the QRawFont's advances for each of the \a glyphIndexes in pixel units. The advances
give the distance from the position of a given glyph to where the next glyph should be drawn
to make it appear as if the two glyphs are unspaced. The glyph indexes are given with the
array \a glyphIndexes while the results are returned through \a advances, both of them must
- have \a numGlyphs elements.
+ have \a numGlyphs elements. How the advances are calculated is controlled by \a layoutFlags.
\sa QTextLine::horizontalAdvance(), QFontMetricsF::width()
*/
-bool QRawFont::advancesForGlyphIndexes(const quint32 *glyphIndexes, QPointF *advances, int numGlyphs) const
+bool QRawFont::advancesForGlyphIndexes(const quint32 *glyphIndexes, QPointF *advances, int numGlyphs, LayoutFlags layoutFlags) const
{
Q_ASSERT(glyphIndexes && advances);
if (!d->isValid() || numGlyphs <= 0)
return false;
QGlyphLayout glyphs;
- glyphs.glyphs = const_cast<HB_Glyph *>(glyphIndexes);
+ glyphs.glyphs = const_cast<glyph_t *>(glyphIndexes);
glyphs.numGlyphs = numGlyphs;
QVarLengthArray<QFixed> advances_x(numGlyphs);
QVarLengthArray<QFixed> advances_y(numGlyphs);
glyphs.advances_x = advances_x.data();
glyphs.advances_y = advances_y.data();
- d->fontEngine->recalcAdvances(&glyphs, 0);
+ bool design = layoutFlags & UseDesignMetrics;
+
+ d->fontEngine->recalcAdvances(&glyphs, design ? QFontEngine::DesignMetrics : QFontEngine::ShaperFlag(0));
+ if (layoutFlags & KernedAdvances)
+ d->fontEngine->doKerning(&glyphs, design ? QFontEngine::DesignMetrics : QFontEngine::ShaperFlag(0));
for (int i=0; i<numGlyphs; ++i)
advances[i] = QPointF(glyphs.advances_x[i].toReal(), glyphs.advances_y[i].toReal());
@@ -550,6 +586,22 @@ bool QRawFont::advancesForGlyphIndexes(const quint32 *glyphIndexes, QPointF *adv
}
/*!
+ \overload
+
+ Returns the QRawFont's advances for each of the \a glyphIndexes in pixel units. The advances
+ give the distance from the position of a given glyph to where the next glyph should be drawn
+ to make it appear as if the two glyphs are unspaced. The glyph indexes are given with the
+ array \a glyphIndexes while the results are returned through \a advances, both of them must
+ have \a numGlyphs elements. The advance of each glyph is calculated separately
+
+ \sa QTextLine::horizontalAdvance(), QFontMetricsF::width()
+*/
+bool QRawFont::advancesForGlyphIndexes(const quint32 *glyphIndexes, QPointF *advances, int numGlyphs) const
+{
+ return QRawFont::advancesForGlyphIndexes(glyphIndexes, advances, numGlyphs, SeparateAdvances);
+}
+
+/*!
Returns the hinting preference used to construct this QRawFont.
\sa QFont::hintingPreference()
@@ -574,9 +626,6 @@ QByteArray QRawFont::fontTable(const char *tagName) const
return d->fontEngine->getSfntTable(qToBigEndian(*tagId));
}
-// From qfontdatabase.cpp
-extern QList<QFontDatabase::WritingSystem> qt_determine_writing_systems_from_truetype_bits(quint32 unicodeRange[4], quint32 codePageRange[2]);
-
/*!
Returns a list of writing systems supported by the font according to designer supplied
information in the font file. Please note that this does not guarantee support for a
@@ -590,6 +639,7 @@ extern QList<QFontDatabase::WritingSystem> qt_determine_writing_systems_from_tru
*/
QList<QFontDatabase::WritingSystem> QRawFont::supportedWritingSystems() const
{
+ QList<QFontDatabase::WritingSystem> writingSystems;
if (d->isValid()) {
QByteArray os2Table = fontTable("OS/2");
if (os2Table.size() > 86) {
@@ -606,11 +656,15 @@ QList<QFontDatabase::WritingSystem> QRawFont::supportedWritingSystems() const
unicodeRanges[i] = qFromBigEndian(bigEndianUnicodeRanges[i]);
}
- return qt_determine_writing_systems_from_truetype_bits(unicodeRanges, codepageRanges);
+ QSupportedWritingSystems ws = QPlatformFontDatabase::writingSystemsFromTrueTypeBits(unicodeRanges, codepageRanges);
+ for (int i = 0; i < QFontDatabase::WritingSystemsCount; ++i) {
+ if (ws.supported(QFontDatabase::WritingSystem(i)))
+ writingSystems.append(QFontDatabase::WritingSystem(i));
+ }
}
}
- return QList<QFontDatabase::WritingSystem>();
+ return writingSystems;
}
/*!
@@ -684,8 +738,7 @@ void QRawFont::setPixelSize(qreal pixelSize)
if (d->fontEngine != 0)
d->fontEngine->ref.ref();
- oldFontEngine->ref.deref();
- if (oldFontEngine->cache_count == 0 && oldFontEngine->ref.load() == 0)
+ if (!oldFontEngine->ref.deref())
delete oldFontEngine;
}
@@ -696,8 +749,7 @@ void QRawFontPrivate::cleanUp()
{
platformCleanUp();
if (fontEngine != 0) {
- fontEngine->ref.deref();
- if (fontEngine->cache_count == 0 && fontEngine->ref.load() == 0)
+ if (!fontEngine->ref.deref())
delete fontEngine;
fontEngine = 0;
}
diff --git a/src/gui/text/qrawfont.h b/src/gui/text/qrawfont.h
index 9a8af41437..eb84a8fee7 100644
--- a/src/gui/text/qrawfont.h
+++ b/src/gui/text/qrawfont.h
@@ -53,8 +53,6 @@
#if !defined(QT_NO_RAWFONT)
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -67,6 +65,13 @@ public:
SubPixelAntialiasing
};
+ enum LayoutFlag {
+ SeparateAdvances = 0,
+ KernedAdvances = 1,
+ UseDesignMetrics = 2
+ };
+ Q_DECLARE_FLAGS(LayoutFlags, LayoutFlag)
+
QRawFont();
QRawFont(const QString &fileName,
qreal pixelSize,
@@ -95,8 +100,10 @@ public:
QVector<quint32> glyphIndexesForString(const QString &text) const;
inline QVector<QPointF> advancesForGlyphIndexes(const QVector<quint32> &glyphIndexes) const;
+ inline QVector<QPointF> advancesForGlyphIndexes(const QVector<quint32> &glyphIndexes, LayoutFlags layoutFlags) const;
bool glyphIndexesForChars(const QChar *chars, int numChars, quint32 *glyphIndexes, int *numGlyphs) const;
bool advancesForGlyphIndexes(const quint32 *glyphIndexes, QPointF *advances, int numGlyphs) const;
+ bool advancesForGlyphIndexes(const quint32 *glyphIndexes, QPointF *advances, int numGlyphs, LayoutFlags layoutFlags) const;
QImage alphaMapForGlyph(quint32 glyphIndex,
AntialiasingType antialiasingType = SubPixelAntialiasing,
@@ -147,17 +154,22 @@ private:
Q_DECLARE_SHARED(QRawFont)
-inline QVector<QPointF> QRawFont::advancesForGlyphIndexes(const QVector<quint32> &glyphIndexes) const
+Q_DECLARE_OPERATORS_FOR_FLAGS(QRawFont::LayoutFlags)
+
+inline QVector<QPointF> QRawFont::advancesForGlyphIndexes(const QVector<quint32> &glyphIndexes, QRawFont::LayoutFlags layoutFlags) const
{
QVector<QPointF> advances(glyphIndexes.size());
- if (advancesForGlyphIndexes(glyphIndexes.constData(), advances.data(), glyphIndexes.size()))
+ if (advancesForGlyphIndexes(glyphIndexes.constData(), advances.data(), glyphIndexes.size(), layoutFlags))
return advances;
return QVector<QPointF>();
}
-QT_END_NAMESPACE
+inline QVector<QPointF> QRawFont::advancesForGlyphIndexes(const QVector<quint32> &glyphIndexes) const
+{
+ return advancesForGlyphIndexes(glyphIndexes, QRawFont::SeparateAdvances);
+}
-QT_END_HEADER
+QT_END_NAMESPACE
#endif // QT_NO_RAWFONT
diff --git a/src/gui/text/qstatictext.cpp b/src/gui/text/qstatictext.cpp
index 2c1683f416..cd88e3bbe4 100644
--- a/src/gui/text/qstatictext.cpp
+++ b/src/gui/text/qstatictext.cpp
@@ -60,8 +60,8 @@ QT_BEGIN_NAMESPACE
\mainclass
QStaticText provides a way to cache layout data for a block of text so that it can be drawn
- more efficiently than by using QPainter::drawText() in which the layout information is
- recalculated with every call.
+ more efficiently than by using QPainter::drawText() in which the layout information is
+ recalculated with every call.
The class primarily provides an optimization for cases where the text, its font and the
transformations on the painter are static over several paint events. If the text or its layout
@@ -97,8 +97,8 @@ QT_BEGIN_NAMESPACE
\endcode
The QStaticText class can be used to mimic the behavior of QPainter::drawText() to a specific
- point with no boundaries, and also when QPainter::drawText() is called with a bounding
- rectangle.
+ point with no boundaries, and also when QPainter::drawText() is called with a bounding
+ rectangle.
If a bounding rectangle is not required, create a QStaticText object without setting a preferred
text width. The text will then occupy a single line.
@@ -151,7 +151,7 @@ QT_BEGIN_NAMESPACE
/*!
Constructs an empty QStaticText
*/
-QStaticText::QStaticText()
+QStaticText::QStaticText()
: data(new QStaticTextPrivate)
{
}
@@ -161,7 +161,7 @@ QStaticText::QStaticText()
*/
QStaticText::QStaticText(const QString &text)
: data(new QStaticTextPrivate)
-{
+{
data->text = text;
data->invalidate();
}
@@ -169,7 +169,7 @@ QStaticText::QStaticText(const QString &text)
/*!
Constructs a QStaticText object which is a copy of \a other.
*/
-QStaticText::QStaticText(const QStaticText &other)
+QStaticText::QStaticText(const QStaticText &other)
{
data = other.data;
}
@@ -186,7 +186,7 @@ QStaticText::~QStaticText()
\internal
*/
void QStaticText::detach()
-{
+{
if (data->ref.load() != 1)
data.detach();
}
@@ -219,7 +219,7 @@ void QStaticText::prepare(const QTransform &matrix, const QFont &font)
Assigns \a other to this QStaticText.
*/
QStaticText &QStaticText::operator=(const QStaticText &other)
-{
+{
data = other.data;
return *this;
}
@@ -300,7 +300,7 @@ Qt::TextFormat QStaticText::textFormat() const
\sa setText()
*/
-QString QStaticText::text() const
+QString QStaticText::text() const
{
return data->text;
}
@@ -651,7 +651,7 @@ void QStaticTextPrivate::paintText(const QPointF &topLeftPosition, QPainter *p)
.arg(QString::number(color.blue(), 16), 2, QLatin1Char('0')));
#endif
document.setDefaultFont(font);
- document.setDocumentMargin(0.0);
+ document.setDocumentMargin(0.0);
#ifndef QT_NO_TEXTHTMLPARSER
document.setHtml(text);
#else
diff --git a/src/gui/text/qstatictext.h b/src/gui/text/qstatictext.h
index f11e7403fc..e41c475495 100644
--- a/src/gui/text/qstatictext.h
+++ b/src/gui/text/qstatictext.h
@@ -50,14 +50,12 @@
#include <QtGui/qfont.h>
#include <QtGui/qtextoption.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QStaticTextPrivate;
class Q_GUI_EXPORT QStaticText
-{
+{
public:
enum PerformanceHint {
ModerateCaching,
@@ -107,6 +105,4 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QStaticText)
-QT_END_HEADER
-
#endif // QSTATICTEXT_H
diff --git a/src/gui/text/qstatictext_p.h b/src/gui/text/qstatictext_p.h
index 1434c54417..4451f27b27 100644
--- a/src/gui/text/qstatictext_p.h
+++ b/src/gui/text/qstatictext_p.h
@@ -77,7 +77,7 @@ public:
class Q_GUI_EXPORT QStaticTextItem
{
-public:
+public:
QStaticTextItem() : chars(0), numChars(0), useBackendOptimizations(false),
userDataNeedsUpdate(0), m_fontEngine(0), m_userData(0) {}
diff --git a/src/gui/text/qsyntaxhighlighter.cpp b/src/gui/text/qsyntaxhighlighter.cpp
index e8e1c81dab..784aeb9a71 100644
--- a/src/gui/text/qsyntaxhighlighter.cpp
+++ b/src/gui/text/qsyntaxhighlighter.cpp
@@ -380,7 +380,7 @@ void QSyntaxHighlighter::rehighlight()
\since 4.6
Reapplies the highlighting to the given QTextBlock \a block.
-
+
\sa rehighlight()
*/
void QSyntaxHighlighter::rehighlightBlock(const QTextBlock &block)
diff --git a/src/gui/text/qsyntaxhighlighter.h b/src/gui/text/qsyntaxhighlighter.h
index 0bd81c4273..8af35a1345 100644
--- a/src/gui/text/qsyntaxhighlighter.h
+++ b/src/gui/text/qsyntaxhighlighter.h
@@ -49,8 +49,6 @@
#include <QtCore/qobject.h>
#include <QtGui/qtextobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -102,8 +100,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_SYNTAXHIGHLIGHTER
#endif // QSYNTAXHIGHLIGHTER_H
diff --git a/src/gui/text/qtextcursor.h b/src/gui/text/qtextcursor.h
index b302fc220c..560e80d174 100644
--- a/src/gui/text/qtextcursor.h
+++ b/src/gui/text/qtextcursor.h
@@ -46,8 +46,6 @@
#include <QtCore/qshareddata.h>
#include <QtGui/qtextformat.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -239,6 +237,4 @@ Q_DECLARE_SHARED(QTextCursor)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEXTCURSOR_H
diff --git a/src/gui/text/qtextdocument.cpp b/src/gui/text/qtextdocument.cpp
index 34133c5e07..b83af30f7f 100644
--- a/src/gui/text/qtextdocument.cpp
+++ b/src/gui/text/qtextdocument.cpp
@@ -416,12 +416,12 @@ void QTextDocument::redo(QTextCursor *cursor)
}
/*! \enum QTextDocument::Stacks
-
+
\value UndoStack The undo stack.
\value RedoStack The redo stack.
\value UndoAndRedoStacks Both the undo and redo stacks.
*/
-
+
/*!
\since 4.7
Clears the stacks specified by \a stacksToClear.
diff --git a/src/gui/text/qtextdocument.h b/src/gui/text/qtextdocument.h
index 7176cb8d12..9d9cbcf6c1 100644
--- a/src/gui/text/qtextdocument.h
+++ b/src/gui/text/qtextdocument.h
@@ -48,8 +48,6 @@
#include <QtCore/qvariant.h>
#include <QtGui/qfont.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -296,6 +294,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QTextDocument::FindFlags)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEXTDOCUMENT_H
diff --git a/src/gui/text/qtextdocumentfragment.h b/src/gui/text/qtextdocumentfragment.h
index f474541c1b..fe9fbffa56 100644
--- a/src/gui/text/qtextdocumentfragment.h
+++ b/src/gui/text/qtextdocumentfragment.h
@@ -44,8 +44,6 @@
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -85,6 +83,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEXTDOCUMENTFRAGMENT_H
diff --git a/src/gui/text/qtextdocumentwriter.h b/src/gui/text/qtextdocumentwriter.h
index 7fe82ac919..7fba23139b 100644
--- a/src/gui/text/qtextdocumentwriter.h
+++ b/src/gui/text/qtextdocumentwriter.h
@@ -43,8 +43,6 @@
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -87,6 +85,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/gui/text/qtextengine.cpp b/src/gui/text/qtextengine.cpp
index f0776c6098..2fa7f0232d 100644
--- a/src/gui/text/qtextengine.cpp
+++ b/src/gui/text/qtextengine.cpp
@@ -51,7 +51,6 @@
#include "qfont_p.h"
#include "qfontengine_p.h"
#include "qstring.h"
-#include <private/qunicodetables_p.h>
#include "qtextdocument_p.h"
#include "qrawfont.h"
#include "qrawfont_p.h"
@@ -62,6 +61,8 @@
#include "qfontengine_qpa_p.h"
+#include <private/qharfbuzz_p.h>
+
QT_BEGIN_NAMESPACE
static const float smallCapsFraction = 0.7f;
@@ -837,13 +838,6 @@ void QTextEngine::bidiReorder(int numItems, const quint8 *levels, int *visualOrd
#endif
}
-QT_BEGIN_INCLUDE_NAMESPACE
-
-
-#include <private/qharfbuzz_p.h>
-
-QT_END_INCLUDE_NAMESPACE
-
// ask the font engine to find out which glyphs (as an index in the specific font) to use for the text in one item.
static bool stringToGlyphs(HB_ShaperItem *item, QGlyphLayout *glyphs, QFontEngine *fontEngine)
{
@@ -972,19 +966,21 @@ static inline bool hasCaseChange(const QScriptItem &si)
static inline void moveGlyphData(const QGlyphLayout &destination, const QGlyphLayout &source, int num)
{
if (num > 0 && destination.glyphs != source.glyphs) {
- memmove(destination.glyphs, source.glyphs, num * sizeof(HB_Glyph));
- memmove(destination.attributes, source.attributes, num * sizeof(HB_GlyphAttributes));
- memmove(destination.advances_x, source.advances_x, num * sizeof(HB_Fixed));
- memmove(destination.offsets, source.offsets, num * sizeof(HB_FixedPoint));
+ memmove(destination.glyphs, source.glyphs, num * sizeof(glyph_t));
+ memmove(destination.attributes, source.attributes, num * sizeof(QGlyphAttributes));
+ memmove(destination.advances_x, source.advances_x, num * sizeof(QFixed));
+ memmove(destination.offsets, source.offsets, num * sizeof(QFixedPoint));
}
}
+Q_STATIC_ASSERT(sizeof(HB_Glyph) == sizeof(glyph_t));
+Q_STATIC_ASSERT(sizeof(HB_GlyphAttributes) == sizeof(QGlyphAttributes));
+Q_STATIC_ASSERT(sizeof(HB_Fixed) == sizeof(QFixed));
+Q_STATIC_ASSERT(sizeof(HB_FixedPoint) == sizeof(QFixedPoint));
+
/// take the item from layoutData->items and
void QTextEngine::shapeTextWithHarfbuzz(int item) const
{
- Q_ASSERT(sizeof(HB_Fixed) == sizeof(QFixed));
- Q_ASSERT(sizeof(HB_FixedPoint) == sizeof(QFixedPoint));
-
QScriptItem &si = layoutData->items[item];
si.glyph_data_offset = layoutData->used;
@@ -1004,7 +1000,7 @@ void QTextEngine::shapeTextWithHarfbuzz(int item) const
memset(&entire_shaper_item, 0, sizeof(entire_shaper_item));
entire_shaper_item.string = reinterpret_cast<const HB_UChar16 *>(layoutData->string.constData());
entire_shaper_item.stringLength = layoutData->string.length();
- entire_shaper_item.item.script = (HB_Script)si.analysis.script;
+ entire_shaper_item.item.script = script_to_hbscript(si.analysis.script);
entire_shaper_item.item.pos = si.position;
entire_shaper_item.item.length = length(item);
entire_shaper_item.item.bidiLevel = si.analysis.bidiLevel;
@@ -1075,9 +1071,9 @@ void QTextEngine::shapeTextWithHarfbuzz(int item) const
itemBoundaries.append(i);
}
lastEngine = engineIdx;
- if (HB_IsHighSurrogate(entire_shaper_item.string[charIdx])
+ if (QChar::isHighSurrogate(entire_shaper_item.string[charIdx])
&& charIdx < stringEnd - 1
- && HB_IsLowSurrogate(entire_shaper_item.string[charIdx + 1]))
+ && QChar::isLowSurrogate(entire_shaper_item.string[charIdx + 1]))
++charIdx;
}
}
@@ -1115,8 +1111,8 @@ void QTextEngine::shapeTextWithHarfbuzz(int item) const
si.descent = qMax(actualFontEngine->descent(), si.descent);
si.leading = qMax(actualFontEngine->leading(), si.leading);
- shaper_item.font = actualFontEngine->harfbuzzFont();
- shaper_item.face = actualFontEngine->initializedHarfbuzzFace();
+ shaper_item.font = (HB_Font)actualFontEngine->harfbuzzFont();
+ shaper_item.face = (HB_Face)actualFontEngine->harfbuzzFace();
shaper_item.glyphIndicesPresent = true;
@@ -1130,13 +1126,13 @@ void QTextEngine::shapeTextWithHarfbuzz(int item) const
if (shaper_item.num_glyphs > shaper_item.item.length)
moveGlyphData(g.mid(shaper_item.num_glyphs), g.mid(shaper_item.initialGlyphCount), remaining_glyphs);
- shaper_item.glyphs = g.glyphs;
- shaper_item.attributes = g.attributes;
+ shaper_item.glyphs = reinterpret_cast<HB_Glyph *>(g.glyphs);
+ shaper_item.attributes = reinterpret_cast<HB_GlyphAttributes *>(g.attributes);
shaper_item.advances = reinterpret_cast<HB_Fixed *>(g.advances_x);
shaper_item.offsets = reinterpret_cast<HB_FixedPoint *>(g.offsets);
if (engineIdx != 0 && shaper_item.glyphIndicesPresent) {
- for (hb_uint32 i = 0; i < shaper_item.initialGlyphCount; ++i)
+ for (quint32 i = 0; i < shaper_item.initialGlyphCount; ++i)
shaper_item.glyphs[i] &= 0x00ffffff;
}
@@ -1148,14 +1144,14 @@ void QTextEngine::shapeTextWithHarfbuzz(int item) const
QGlyphLayout g = availableGlyphs(&si).mid(glyph_pos, shaper_item.num_glyphs);
moveGlyphData(g.mid(shaper_item.num_glyphs), g.mid(shaper_item.initialGlyphCount), remaining_glyphs);
- for (hb_uint32 i = 0; i < shaper_item.item.length; ++i)
+ for (quint32 i = 0; i < shaper_item.item.length; ++i)
shaper_item.log_clusters[i] += glyph_pos;
if (kerningEnabled && !shaper_item.kerning_applied)
actualFontEngine->doKerning(&g, option.useDesignMetrics() ? QFontEngine::DesignMetrics : QFontEngine::ShaperFlags(0));
if (engineIdx != 0) {
- for (hb_uint32 i = 0; i < shaper_item.num_glyphs; ++i)
+ for (quint32 i = 0; i < shaper_item.num_glyphs; ++i)
g.glyphs[i] |= (engineIdx << 24);
}
@@ -1168,7 +1164,7 @@ void QTextEngine::shapeTextWithHarfbuzz(int item) const
layoutData->used += si.num_glyphs;
}
-static void init(QTextEngine *e)
+void QTextEngine::init(QTextEngine *e)
{
e->ignoreBidi = false;
e->cacheGlyphs = false;
@@ -1225,7 +1221,7 @@ const QCharAttributes *QTextEngine::attributes() const
scriptItems[i].script = si.analysis.script;
}
- QUnicodeTools::initCharAttributes(reinterpret_cast<const HB_UChar16 *>(layoutData->string.constData()),
+ QUnicodeTools::initCharAttributes(reinterpret_cast<const ushort *>(layoutData->string.constData()),
layoutData->string.length(),
scriptItems.data(), scriptItems.size(),
(QCharAttributes *)layoutData->memory);
@@ -1257,11 +1253,8 @@ void QTextEngine::shape(int item) const
static inline void releaseCachedFontEngine(QFontEngine *fontEngine)
{
- if (fontEngine) {
- fontEngine->ref.deref();
- if (fontEngine->cache_count == 0 && fontEngine->ref.load() == 0)
- delete fontEngine;
- }
+ if (fontEngine && !fontEngine->ref.deref())
+ delete fontEngine;
}
void QTextEngine::resetFontEngineCache()
@@ -1313,6 +1306,8 @@ void QTextEngine::itemize() const
if (!length)
return;
+ const ushort *string = reinterpret_cast<const ushort *>(layoutData->string.unicode());
+
bool ignore = ignoreBidi;
bool rtl = isRightToLeft();
@@ -1346,44 +1341,48 @@ void QTextEngine::itemize() const
layoutData->hasBidi = bidiItemize(const_cast<QTextEngine *>(this), analysis, control);
}
- const ushort *uc = reinterpret_cast<const ushort *>(layoutData->string.unicode());
+ {
+ QVarLengthArray<uchar> scripts(length);
+ QUnicodeTools::initScripts(string, length, scripts.data());
+ for (int i = 0; i < length; ++i)
+ analysis[i].script = scripts.at(i);
+ }
+
+ const ushort *uc = string;
const ushort *e = uc + length;
- int lastScript = QUnicodeTables::Common;
while (uc < e) {
switch (*uc) {
case QChar::ObjectReplacementCharacter:
- analysis->script = QUnicodeTables::Common;
+ analysis->script = QChar::Script_Common;
analysis->flags = QScriptAnalysis::Object;
break;
case QChar::LineSeparator:
if (analysis->bidiLevel % 2)
--analysis->bidiLevel;
- analysis->script = QUnicodeTables::Common;
+ analysis->script = QChar::Script_Common;
analysis->flags = QScriptAnalysis::LineOrParagraphSeparator;
if (option.flags() & QTextOption::ShowLineAndParagraphSeparators)
*const_cast<ushort*>(uc) = 0x21B5; // visual line separator
break;
case QChar::Tabulation:
- analysis->script = QUnicodeTables::Common;
+ analysis->script = QChar::Script_Common;
analysis->flags = QScriptAnalysis::Tab;
analysis->bidiLevel = control.baseLevel();
break;
case QChar::Space:
case QChar::Nbsp:
if (option.flags() & QTextOption::ShowTabsAndSpaces) {
- analysis->script = QUnicodeTables::Common;
+ analysis->script = QChar::Script_Common;
analysis->flags = QScriptAnalysis::Space;
analysis->bidiLevel = control.baseLevel();
break;
}
// fall through
default:
- int script = QUnicodeTables::script(*uc);
- analysis->script = script == QUnicodeTables::Inherited ? lastScript : script;
analysis->flags = QScriptAnalysis::None;
break;
}
- lastScript = analysis->script;
+ analysis->script = hbscript_to_script(script_to_hbscript(analysis->script)); // retain the old behavior
++uc;
++analysis;
}
@@ -1431,11 +1430,13 @@ void QTextEngine::itemize() const
#ifndef QT_NO_RAWFONT
if (useRawFont && specialData) {
int lastIndex = 0;
+ const QTextFormatCollection *collection = formats();
for (int i = 0; i < specialData->addFormats.size(); ++i) {
const QTextLayout::FormatRange &range = specialData->addFormats.at(i);
- if (range.format.fontCapitalization()) {
+ const QTextCharFormat format = collection->charFormat(specialData->addFormatIndices.at(i));
+ if (format.hasProperty(QTextFormat::FontCapitalization)) {
itemizer.generate(lastIndex, range.start - lastIndex, QFont::MixedCase);
- itemizer.generate(range.start, range.length, range.format.fontCapitalization());
+ itemizer.generate(range.start, range.length, format.fontCapitalization());
lastIndex = range.start + range.length;
}
}
@@ -2035,9 +2036,9 @@ void QScriptLine::setDefaultHeight(QTextEngine *eng)
QPaintDevice *pdev = eng->block.docHandle()->layout()->paintDevice();
if (pdev)
f = QFont(f, pdev);
- e = f.d->engineForScript(QUnicodeTables::Common);
+ e = f.d->engineForScript(QChar::Script_Common);
} else {
- e = eng->fnt.d->engineForScript(QUnicodeTables::Common);
+ e = eng->fnt.d->engineForScript(QChar::Script_Common);
}
QFixed other_ascent = e->ascent();
@@ -2155,11 +2156,11 @@ void QGlyphLayout::grow(char *address, int totalGlyphs)
if (numGlyphs) {
// move the existing data
- memmove(newLayout.attributes, oldLayout.attributes, numGlyphs * sizeof(HB_GlyphAttributes));
+ memmove(newLayout.attributes, oldLayout.attributes, numGlyphs * sizeof(QGlyphAttributes));
memmove(newLayout.justifications, oldLayout.justifications, numGlyphs * sizeof(QGlyphJustification));
memmove(newLayout.advances_y, oldLayout.advances_y, numGlyphs * sizeof(QFixed));
memmove(newLayout.advances_x, oldLayout.advances_x, numGlyphs * sizeof(QFixed));
- memmove(newLayout.glyphs, oldLayout.glyphs, numGlyphs * sizeof(HB_Glyph));
+ memmove(newLayout.glyphs, oldLayout.glyphs, numGlyphs * sizeof(glyph_t));
}
// clear the new data
@@ -2206,25 +2207,9 @@ int QTextEngine::formatIndex(const QScriptItem *si) const
QTextCharFormat QTextEngine::format(const QScriptItem *si) const
{
- QTextCharFormat format;
- const QTextFormatCollection *formats = this->formats();
-
- if (formats)
- format = formats->charFormat(formatIndex(si));
-
- if (specialData && specialData->resolvedFormatIndices.isEmpty()) {
- int end = si->position + length(si);
- for (int i = 0; i < specialData->addFormats.size(); ++i) {
- const QTextLayout::FormatRange &r = specialData->addFormats.at(i);
- if (r.start <= si->position && r.start + r.length >= end) {
- if (!specialData->addFormatIndices.isEmpty())
- format.merge(formats->format(specialData->addFormatIndices.at(i)));
- else
- format.merge(r.format);
- }
- }
- }
- return format;
+ if (const QTextFormatCollection *formats = this->formats())
+ return formats->charFormat(formatIndex(si));
+ return QTextCharFormat();
}
void QTextEngine::addRequiredBoundaries() const
@@ -2295,6 +2280,67 @@ bool QTextEngine::atSpace(int position) const
return false;
}
+void QTextEngine::setPreeditArea(int position, const QString &preeditText)
+{
+ if (preeditText.isEmpty()) {
+ if (!specialData)
+ return;
+ if (specialData->addFormats.isEmpty()) {
+ delete specialData;
+ specialData = 0;
+ } else {
+ specialData->preeditText = QString();
+ specialData->preeditPosition = -1;
+ }
+ } else {
+ if (!specialData)
+ specialData = new SpecialData;
+ specialData->preeditPosition = position;
+ specialData->preeditText = preeditText;
+ }
+ invalidate();
+ clearLineData();
+}
+
+QList<QTextLayout::FormatRange> QTextEngine::additionalFormats() const
+{
+ QList<QTextLayout::FormatRange> formatList;
+ if (!specialData)
+ return formatList;
+
+ formatList = specialData->addFormats;
+ if (!specialData->addFormatIndices.isEmpty()) {
+ const QTextFormatCollection *formats = this->formats();
+ Q_ASSERT(formats);
+ for (int i = 0; i < specialData->addFormatIndices.size(); ++i)
+ formatList[i].format = formats->charFormat(specialData->addFormatIndices.at(i));
+ }
+
+ return formatList;
+}
+
+void QTextEngine::setAdditionalFormats(const QList<QTextLayout::FormatRange> &formatList)
+{
+ if (formatList.isEmpty()) {
+ if (!specialData)
+ return;
+ if (specialData->preeditText.isEmpty()) {
+ delete specialData;
+ specialData = 0;
+ } else {
+ specialData->addFormats.clear();
+ specialData->addFormatIndices.clear();
+ }
+ } else {
+ if (!specialData) {
+ specialData = new SpecialData;
+ specialData->preeditPosition = -1;
+ }
+ specialData->addFormats = formatList;
+ indexAdditionalFormats();
+ }
+ resetFontEngineCache();
+}
void QTextEngine::indexAdditionalFormats()
{
@@ -2421,7 +2467,7 @@ QString QTextEngine::elidedText(Qt::TextElideMode mode, const QFixed &width, int
{
QChar ellipsisChar(0x2026);
- QFontEngine *fe = fnt.d->engineForScript(QUnicodeTables::Common);
+ QFontEngine *fe = fnt.d->engineForScript(QChar::Script_Common);
QGlyphLayoutArray<1> ellipsisGlyph;
{
@@ -2772,13 +2818,9 @@ void QTextEngine::resolveAdditionalFormats() const
}
foreach (int cur, currentFormats) {
- const QTextLayout::FormatRange &r = specialData->addFormats.at(cur);
- Q_ASSERT (r.start <= si->position && r.start + r.length >= end);
- if (!specialData->addFormatIndices.isEmpty()) {
- format.merge(collection->format(specialData->addFormatIndices.at(cur)));
- } else {
- format.merge(r.format);
- }
+ Q_ASSERT(specialData->addFormats.at(cur).start <= si->position
+ && specialData->addFormats.at(cur).start + specialData->addFormats.at(cur).length >= end);
+ format.merge(collection->format(specialData->addFormatIndices.at(cur)));
}
indices[i] = collection->indexForFormat(format);
}
@@ -2868,8 +2910,8 @@ int QTextEngine::positionInLigature(const QScriptItem *si, int end,
int clusterStart = -1;
int clusterLength = 0;
- if (si->analysis.script != QUnicodeTables::Common &&
- si->analysis.script != QUnicodeTables::Greek) {
+ if (si->analysis.script != QChar::Script_Common &&
+ si->analysis.script != QChar::Script_Greek) {
if (glyph_pos == -1)
return si->position + end;
else {
diff --git a/src/gui/text/qtextengine_p.h b/src/gui/text/qtextengine_p.h
index 93e92e7ca8..ec7f7407b2 100644
--- a/src/gui/text/qtextengine_p.h
+++ b/src/gui/text/qtextengine_p.h
@@ -71,8 +71,6 @@
#include "private/qtextdocument_p.h"
#endif
-#include "private/qharfbuzz_copy_p.h"
-
#include "private/qfixed_p.h"
#include <private/qunicodetools_p.h>
@@ -89,6 +87,22 @@ class QPainter;
class QAbstractTextDocumentLayout;
+typedef quint32 glyph_t;
+
+#ifdef __xlC__
+typedef unsigned q_hb_bitfield;
+#else
+typedef quint8 q_hb_bitfield;
+#endif
+
+typedef struct {
+ q_hb_bitfield justification :4; /* Justification class */
+ q_hb_bitfield clusterStart :1; /* First glyph of representation of cluster */
+ q_hb_bitfield mark :1; /* needs to be positioned around base char */
+ q_hb_bitfield zeroWidth :1; /* ZWJ, ZWNJ etc, with no width */
+ q_hb_bitfield dontPrint :1;
+ q_hb_bitfield combiningClass :8;
+} QGlyphAttributes;
// this uses the same coordinate system as Qt, but a different one to freetype.
// * y is usually negative, and is equal to the ascent.
@@ -164,20 +178,20 @@ struct QGlyphLayoutInstance
{
QFixedPoint offset;
QFixedPoint advance;
- HB_Glyph glyph;
+ glyph_t glyph;
QGlyphJustification justification;
- HB_GlyphAttributes attributes;
+ QGlyphAttributes attributes;
};
struct QGlyphLayout
{
// init to 0 not needed, done when shaping
QFixedPoint *offsets; // 8 bytes per element
- HB_Glyph *glyphs; // 4 bytes per element
+ glyph_t *glyphs; // 4 bytes per element
QFixed *advances_x; // 4 bytes per element
QFixed *advances_y; // 4 bytes per element
QGlyphJustification *justifications; // 4 bytes per element
- HB_GlyphAttributes *attributes; // 2 bytes per element
+ QGlyphAttributes *attributes; // 2 bytes per element
int numGlyphs;
@@ -186,16 +200,16 @@ struct QGlyphLayout
inline explicit QGlyphLayout(char *address, int totalGlyphs)
{
offsets = reinterpret_cast<QFixedPoint *>(address);
- int offset = totalGlyphs * sizeof(HB_FixedPoint);
- glyphs = reinterpret_cast<HB_Glyph *>(address + offset);
- offset += totalGlyphs * sizeof(HB_Glyph);
+ int offset = totalGlyphs * sizeof(QFixedPoint);
+ glyphs = reinterpret_cast<glyph_t *>(address + offset);
+ offset += totalGlyphs * sizeof(glyph_t);
advances_x = reinterpret_cast<QFixed *>(address + offset);
offset += totalGlyphs * sizeof(QFixed);
advances_y = reinterpret_cast<QFixed *>(address + offset);
offset += totalGlyphs * sizeof(QFixed);
justifications = reinterpret_cast<QGlyphJustification *>(address + offset);
offset += totalGlyphs * sizeof(QGlyphJustification);
- attributes = reinterpret_cast<HB_GlyphAttributes *>(address + offset);
+ attributes = reinterpret_cast<QGlyphAttributes *>(address + offset);
numGlyphs = totalGlyphs;
}
@@ -215,7 +229,7 @@ struct QGlyphLayout
}
static inline int spaceNeededForGlyphLayout(int totalGlyphs) {
- return totalGlyphs * (sizeof(HB_Glyph) + sizeof(HB_GlyphAttributes)
+ return totalGlyphs * (sizeof(glyph_t) + sizeof(QGlyphAttributes)
+ sizeof(QFixed) + sizeof(QFixed) + sizeof(QFixedPoint)
+ sizeof(QGlyphJustification));
}
@@ -254,11 +268,11 @@ struct QGlyphLayout
} else {
const int num = last - first;
memset(offsets + first, 0, num * sizeof(QFixedPoint));
- memset(glyphs + first, 0, num * sizeof(HB_Glyph));
+ memset(glyphs + first, 0, num * sizeof(glyph_t));
memset(advances_x + first, 0, num * sizeof(QFixed));
memset(advances_y + first, 0, num * sizeof(QFixed));
memset(justifications + first, 0, num * sizeof(QGlyphJustification));
- memset(attributes + first, 0, num * sizeof(HB_GlyphAttributes));
+ memset(attributes + first, 0, num * sizeof(QGlyphAttributes));
}
}
@@ -300,7 +314,7 @@ public:
}
private:
- void *buffer[(N * (sizeof(HB_Glyph) + sizeof(HB_GlyphAttributes)
+ void *buffer[(N * (sizeof(glyph_t) + sizeof(QGlyphAttributes)
+ sizeof(QFixed) + sizeof(QFixed) + sizeof(QFixedPoint)
+ sizeof(QGlyphJustification)))
/ sizeof(void *) + 1];
@@ -603,13 +617,23 @@ public:
ItemDecorationList strikeOutList;
ItemDecorationList overlineList;
- inline bool hasFormats() const { return (block.docHandle() || specialData); }
inline bool visualCursorMovement() const
{
return (visualMovement ||
(block.docHandle() ? block.docHandle()->defaultCursorMoveStyle == Qt::VisualMoveStyle : false));
}
+ inline int preeditAreaPosition() const { return specialData ? specialData->preeditPosition : -1; }
+ inline QString preeditAreaText() const { return specialData ? specialData->preeditText : QString(); }
+ void setPreeditArea(int position, const QString &text);
+
+ inline bool hasFormats() const { return block.docHandle() || (specialData && !specialData->addFormats.isEmpty()); }
+ QList<QTextLayout::FormatRange> additionalFormats() const;
+ void setAdditionalFormats(const QList<QTextLayout::FormatRange> &formatList);
+
+private:
+ static void init(QTextEngine *e);
+
struct SpecialData {
int preeditPosition;
QString preeditText;
@@ -621,9 +645,12 @@ public:
};
SpecialData *specialData;
+ void indexAdditionalFormats();
+ void resolveAdditionalFormats() const;
+
+public:
bool atWordSeparator(int position) const;
bool atSpace(int position) const;
- void indexAdditionalFormats();
QString elidedText(Qt::TextElideMode mode, const QFixed &width, int flags = 0, int from = 0, int count = -1) const;
@@ -661,7 +688,6 @@ private:
void shapeTextWithHarfbuzz(int item) const;
void splitItem(int item, int pos) const;
- void resolveAdditionalFormats() const;
int endOfLine(int lineNum);
int beginningOfLine(int lineNum);
int getClusterLength(unsigned short *logClusters, const QCharAttributes *attributes, int from, int to, int glyph_pos, int *start);
diff --git a/src/gui/text/qtextformat.cpp b/src/gui/text/qtextformat.cpp
index 4decb3d248..4f8a25c5a8 100644
--- a/src/gui/text/qtextformat.cpp
+++ b/src/gui/text/qtextformat.cpp
@@ -1898,6 +1898,7 @@ void QTextCharFormat::setFont(const QFont &font)
setFontStretch(font.stretch());
setFontStyleHint(font.styleHint());
setFontStyleStrategy(font.styleStrategy());
+ setFontHintingPreference(font.hintingPreference());
setFontKerning(font.kerning());
}
diff --git a/src/gui/text/qtextformat.h b/src/gui/text/qtextformat.h
index bdecdad66a..2098369811 100644
--- a/src/gui/text/qtextformat.h
+++ b/src/gui/text/qtextformat.h
@@ -51,8 +51,6 @@
#include <QtGui/qbrush.h>
#include <QtGui/qtextoption.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -1009,6 +1007,4 @@ inline void QTextTableCellFormat::setPadding(qreal padding)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEXTFORMAT_H
diff --git a/src/gui/text/qtextlayout.cpp b/src/gui/text/qtextlayout.cpp
index 833e4c5037..eed6758cc9 100644
--- a/src/gui/text/qtextlayout.cpp
+++ b/src/gui/text/qtextlayout.cpp
@@ -463,24 +463,10 @@ const QTextOption &QTextLayout::textOption() const
*/
void QTextLayout::setPreeditArea(int position, const QString &text)
{
- if (text.isEmpty()) {
- if (!d->specialData)
- return;
- if (d->specialData->addFormats.isEmpty()) {
- delete d->specialData;
- d->specialData = 0;
- } else {
- d->specialData->preeditText = QString();
- d->specialData->preeditPosition = -1;
- }
- } else {
- if (!d->specialData)
- d->specialData = new QTextEngine::SpecialData;
- d->specialData->preeditPosition = position;
- d->specialData->preeditText = text;
- }
- d->invalidate();
- d->clearLineData();
+ if (d->preeditAreaPosition() == position && d->preeditAreaText() == text)
+ return;
+ d->setPreeditArea(position, text);
+
if (d->block.docHandle())
d->block.docHandle()->documentChange(d->block.position(), d->block.length());
}
@@ -493,7 +479,7 @@ void QTextLayout::setPreeditArea(int position, const QString &text)
*/
int QTextLayout::preeditAreaPosition() const
{
- return d->specialData ? d->specialData->preeditPosition : -1;
+ return d->preeditAreaPosition();
}
/*!
@@ -503,7 +489,7 @@ int QTextLayout::preeditAreaPosition() const
*/
QString QTextLayout::preeditAreaText() const
{
- return d->specialData ? d->specialData->preeditText : QString();
+ return d->preeditAreaText();
}
@@ -515,27 +501,10 @@ QString QTextLayout::preeditAreaText() const
*/
void QTextLayout::setAdditionalFormats(const QList<FormatRange> &formatList)
{
- if (formatList.isEmpty()) {
- if (!d->specialData)
- return;
- if (d->specialData->preeditText.isEmpty()) {
- delete d->specialData;
- d->specialData = 0;
- } else {
- d->specialData->addFormats = formatList;
- d->specialData->addFormatIndices.clear();
- }
- } else {
- if (!d->specialData) {
- d->specialData = new QTextEngine::SpecialData;
- d->specialData->preeditPosition = -1;
- }
- d->specialData->addFormats = formatList;
- d->indexAdditionalFormats();
- }
+ d->setAdditionalFormats(formatList);
+
if (d->block.docHandle())
d->block.docHandle()->documentChange(d->block.position(), d->block.length());
- d->resetFontEngineCache();
}
/*!
@@ -545,21 +514,7 @@ void QTextLayout::setAdditionalFormats(const QList<FormatRange> &formatList)
*/
QList<QTextLayout::FormatRange> QTextLayout::additionalFormats() const
{
- QList<FormatRange> formats;
- if (!d->specialData)
- return formats;
-
- formats = d->specialData->addFormats;
-
- if (d->specialData->addFormatIndices.isEmpty())
- return formats;
-
- const QTextFormatCollection *collection = d->formats();
-
- for (int i = 0; i < d->specialData->addFormatIndices.count(); ++i)
- formats[i].format = collection->charFormat(d->specialData->addFormatIndices.at(i));
-
- return formats;
+ return d->additionalFormats();
}
/*!
@@ -1022,7 +977,7 @@ static inline QRectF clipIfValid(const QRectF &rect, const QRectF &clip)
*/
#if !defined(QT_NO_RAWFONT)
QList<QGlyphRun> QTextLayout::glyphRuns(int from, int length) const
-{
+{
if (from < 0)
from = 0;
if (length < 0)
@@ -1651,7 +1606,7 @@ namespace {
}
inline glyph_t currentGlyph() const
- {
+ {
Q_ASSERT(currentPosition > 0);
Q_ASSERT(logClusters[currentPosition - 1] < glyphs.numGlyphs);
diff --git a/src/gui/text/qtextlayout.h b/src/gui/text/qtextlayout.h
index f1a027ade4..8a26fed924 100644
--- a/src/gui/text/qtextlayout.h
+++ b/src/gui/text/qtextlayout.h
@@ -52,8 +52,6 @@
#include <QtGui/qglyphrun.h>
#include <QtGui/qtextcursor.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -266,6 +264,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEXTLAYOUT_H
diff --git a/src/gui/text/qtextlist.h b/src/gui/text/qtextlist.h
index 4aebd1ed0c..1fcc99d963 100644
--- a/src/gui/text/qtextlist.h
+++ b/src/gui/text/qtextlist.h
@@ -45,8 +45,6 @@
#include <QtGui/qtextobject.h>
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -88,6 +86,4 @@ inline void QTextList::setFormat(const QTextListFormat &aformat)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEXTLIST_H
diff --git a/src/gui/text/qtextobject.cpp b/src/gui/text/qtextobject.cpp
index 80ed2f023f..8465dcdaad 100644
--- a/src/gui/text/qtextobject.cpp
+++ b/src/gui/text/qtextobject.cpp
@@ -636,7 +636,7 @@ QTextFrame::iterator QTextFrame::begin() const
/*!
Returns an iterator pointing to the position past the last document element inside the frame.
- Please see the document \l{STL-Style Iterators} for more information.
+ Please see the document \l{STL-Style Iterators} for more information.
\sa begin()
*/
QTextFrame::iterator QTextFrame::end() const
diff --git a/src/gui/text/qtextobject.h b/src/gui/text/qtextobject.h
index 08eaf943a5..87f2cf6197 100644
--- a/src/gui/text/qtextobject.h
+++ b/src/gui/text/qtextobject.h
@@ -46,8 +46,6 @@
#include <QtGui/qtextformat.h>
#include <QtGui/qglyphrun.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -329,6 +327,4 @@ Q_DECLARE_TYPEINFO(QTextFragment, Q_MOVABLE_TYPE);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEXTOBJECT_H
diff --git a/src/gui/text/qtextodfwriter.cpp b/src/gui/text/qtextodfwriter.cpp
index d83dc98e22..1572648d7f 100644
--- a/src/gui/text/qtextodfwriter.cpp
+++ b/src/gui/text/qtextodfwriter.cpp
@@ -677,13 +677,13 @@ void QTextOdfWriter::writeFrameFormat(QXmlStreamWriter &writer, QTextFrameFormat
writer.writeEndElement(); // style
// TODO consider putting the following properties in a qt-namespace.
-// Position position () const
-// qreal border () const
-// QBrush borderBrush () const
-// BorderStyle borderStyle () const
-// qreal padding () const
-// QTextLength width () const
-// QTextLength height () const
+// Position position () const
+// qreal border () const
+// QBrush borderBrush () const
+// BorderStyle borderStyle () const
+// qreal padding () const
+// QTextLength width () const
+// QTextLength height () const
// PageBreakFlags pageBreakPolicy () const
}
diff --git a/src/gui/text/qtextodfwriter_p.h b/src/gui/text/qtextodfwriter_p.h
index cbdc5fbb95..6683e1eed9 100644
--- a/src/gui/text/qtextodfwriter_p.h
+++ b/src/gui/text/qtextodfwriter_p.h
@@ -41,6 +41,9 @@
#ifndef QTEXTODFWRITER_H
#define QTEXTODFWRITER_H
+
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_TEXTODFWRITER
//
diff --git a/src/gui/text/qtextoption.cpp b/src/gui/text/qtextoption.cpp
index 7b5d20bc5c..c939020457 100644
--- a/src/gui/text/qtextoption.cpp
+++ b/src/gui/text/qtextoption.cpp
@@ -394,7 +394,7 @@ QList<QTextOption::Tab> QTextOption::tabs() const
/*!
\fn Tab::Tab(qreal pos, TabType tabType, QChar delim = QChar())
-
+
Creates a tab with the given position, tab type, and delimiter
(\a pos, \a tabType, \a delim).
diff --git a/src/gui/text/qtextoption.h b/src/gui/text/qtextoption.h
index 0030fabe40..a6818eb79a 100644
--- a/src/gui/text/qtextoption.h
+++ b/src/gui/text/qtextoption.h
@@ -47,8 +47,6 @@
#include <QtCore/qmetatype.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -157,6 +155,4 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE( QTextOption::Tab )
-QT_END_HEADER
-
#endif // QTEXTOPTION_H
diff --git a/src/gui/text/qtexttable.cpp b/src/gui/text/qtexttable.cpp
index 0c9ec6203e..a56f8060e0 100644
--- a/src/gui/text/qtexttable.cpp
+++ b/src/gui/text/qtexttable.cpp
@@ -535,11 +535,11 @@ void QTextTablePrivate::update() const
Rows and columns within a QTextTable can be merged and split using
the mergeCells() and splitCell() functions. However, only cells that span multiple
rows or columns can be split. (Merging or splitting does not increase or decrease
- the number of rows and columns.)
+ the number of rows and columns.)
Note that if you have merged multiple columns and rows into one cell, you will not
- be able to split the merged cell into new cells spanning over more than one row
- or column. To be able to split cells spanning over several rows and columns you
+ be able to split the merged cell into new cells spanning over more than one row
+ or column. To be able to split cells spanning over several rows and columns you
need to do this over several iterations.
\table 80%
diff --git a/src/gui/text/qtexttable.h b/src/gui/text/qtexttable.h
index 6dddda210f..9da205af7f 100644
--- a/src/gui/text/qtexttable.h
+++ b/src/gui/text/qtexttable.h
@@ -46,8 +46,6 @@
#include <QtCore/qobject.h>
#include <QtGui/qtextobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -139,6 +137,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEXTTABLE_H
diff --git a/src/gui/text/qzip.cpp b/src/gui/text/qzip.cpp
index 9e37330381..151b0bcfeb 100644
--- a/src/gui/text/qzip.cpp
+++ b/src/gui/text/qzip.cpp
@@ -1302,7 +1302,7 @@ QFile::Permissions QZipWriter::creationPermissions() const
*/
void QZipWriter::addFile(const QString &fileName, const QByteArray &data)
{
- d->addEntry(QZipWriterPrivate::File, fileName, data);
+ d->addEntry(QZipWriterPrivate::File, QDir::fromNativeSeparators(fileName), data);
}
/*!
@@ -1324,7 +1324,7 @@ void QZipWriter::addFile(const QString &fileName, QIODevice *device)
return;
}
}
- d->addEntry(QZipWriterPrivate::File, fileName, device->readAll());
+ d->addEntry(QZipWriterPrivate::File, QDir::fromNativeSeparators(fileName), device->readAll());
if (opened)
device->close();
}
@@ -1335,10 +1335,10 @@ void QZipWriter::addFile(const QString &fileName, QIODevice *device)
*/
void QZipWriter::addDirectory(const QString &dirName)
{
- QString name = dirName;
+ QString name(QDir::fromNativeSeparators(dirName));
// separator is mandatory
- if (!name.endsWith(QDir::separator()))
- name.append(QDir::separator());
+ if (!name.endsWith(QLatin1Char('/')))
+ name.append(QLatin1Char('/'));
d->addEntry(QZipWriterPrivate::Directory, name, QByteArray());
}
@@ -1349,7 +1349,7 @@ void QZipWriter::addDirectory(const QString &dirName)
*/
void QZipWriter::addSymLink(const QString &fileName, const QString &destination)
{
- d->addEntry(QZipWriterPrivate::Symlink, fileName, QFile::encodeName(destination));
+ d->addEntry(QZipWriterPrivate::Symlink, QDir::fromNativeSeparators(fileName), QFile::encodeName(destination));
}
/*!
diff --git a/src/gui/text/qzipreader_p.h b/src/gui/text/qzipreader_p.h
index a784d7d9ea..b641689e47 100644
--- a/src/gui/text/qzipreader_p.h
+++ b/src/gui/text/qzipreader_p.h
@@ -42,6 +42,8 @@
#ifndef QZIPREADER_H
#define QZIPREADER_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_TEXTODFWRITER
//
diff --git a/src/gui/text/qzipwriter_p.h b/src/gui/text/qzipwriter_p.h
index 1246da5a05..e6a19e22e4 100644
--- a/src/gui/text/qzipwriter_p.h
+++ b/src/gui/text/qzipwriter_p.h
@@ -40,6 +40,9 @@
****************************************************************************/
#ifndef QZIPWRITER_H
#define QZIPWRITER_H
+
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_TEXTODFWRITER
//
diff --git a/src/gui/text/text.pri b/src/gui/text/text.pri
index 436b7c7aec..e9ea2a3f83 100644
--- a/src/gui/text/text.pri
+++ b/src/gui/text/text.pri
@@ -42,7 +42,6 @@ HEADERS += \
text/qrawfont_p.h \
text/qglyphrun.h \
text/qglyphrun_p.h \
- text/qharfbuzz_copy_p.h \
text/qdistancefield_p.h
SOURCES += \
diff --git a/src/gui/util/qdesktopservices.h b/src/gui/util/qdesktopservices.h
index 15139ea7b7..9b1d71052c 100644
--- a/src/gui/util/qdesktopservices.h
+++ b/src/gui/util/qdesktopservices.h
@@ -45,8 +45,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qstandardpaths.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -94,7 +92,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDESKTOPSERVICES_H
diff --git a/src/gui/util/qvalidator.cpp b/src/gui/util/qvalidator.cpp
index b94ec7f1bb..ed3b3b6dd6 100644
--- a/src/gui/util/qvalidator.cpp
+++ b/src/gui/util/qvalidator.cpp
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
** Contact: http://www.qt-project.org/legal
**
** This file is part of the QtGui module of the Qt Toolkit.
@@ -501,9 +502,6 @@ void QIntValidator::setTop(int top)
setRange(bottom(), top);
}
-
-#ifndef QT_NO_REGEXP
-
/*!
\internal
*/
@@ -520,6 +518,8 @@ QValidator::QValidator(QValidatorPrivate &d, QObject *parent)
{
}
+#ifndef QT_NO_REGEXP
+
class QDoubleValidatorPrivate : public QValidatorPrivate
{
Q_DECLARE_PUBLIC(QDoubleValidator)
@@ -906,6 +906,159 @@ void QRegExpValidator::setRegExp(const QRegExp& rx)
#endif
+#ifndef QT_NO_REGULAREXPRESSION
+
+/*!
+ \class QRegularExpressionValidator
+ \brief The QRegularExpressionValidator class is used to check a string
+ against a regular expression.
+
+ \since 5.1
+
+ QRegularExpressionValidator uses a regular expression (regexp) to
+ determine whether an input string is \l Acceptable, \l
+ Intermediate, or \l Invalid. The regexp can either be supplied
+ when the QRegularExpressionValidator is constructed, or at a later time.
+
+ If the regexp partially matches against the string, the result is
+ considered \l Intermediate. For example, "" and "A" are \l Intermediate for
+ the regexp \b{[A-Z][0-9]} (whereas "_" would be \l Invalid).
+
+ QRegularExpressionValidator automatically wraps the regular expression in
+ the \c{\\A} and \c{\\z} anchors; in other words, it always attempts to do
+ an exact match.
+
+ Example of use:
+ \snippet code/src_gui_util_qvalidator.cpp 5
+
+ Below we present some examples of validators. In practice they would
+ normally be associated with a widget as in the example above.
+
+ \snippet code/src_gui_util_qvalidator.cpp 6
+
+ \sa QRegularExpression, QIntValidator, QDoubleValidator, QRegExpValidator
+*/
+
+class QRegularExpressionValidatorPrivate : public QValidatorPrivate
+{
+ Q_DECLARE_PUBLIC(QRegularExpressionValidator)
+
+public:
+ QRegularExpression origRe; // the one set by the user
+ QRegularExpression usedRe; // the one actually used
+ void setRegularExpression(const QRegularExpression &re);
+};
+
+/*!
+ Constructs a validator with a \a parent object that accepts
+ any string (including an empty one) as valid.
+*/
+
+QRegularExpressionValidator::QRegularExpressionValidator(QObject *parent)
+ : QValidator(*new QRegularExpressionValidatorPrivate, parent)
+{
+ // origRe in the private will be an empty QRegularExpression,
+ // and therefore this validator will match any string.
+}
+
+/*!
+ Constructs a validator with a \a parent object that
+ accepts all strings that match the regular expression \a re.
+*/
+
+QRegularExpressionValidator::QRegularExpressionValidator(const QRegularExpression &re, QObject *parent)
+ : QValidator(*new QRegularExpressionValidatorPrivate, parent)
+{
+ Q_D(QRegularExpressionValidator);
+ d->setRegularExpression(re);
+}
+
+
+/*!
+ Destroys the validator.
+*/
+
+QRegularExpressionValidator::~QRegularExpressionValidator()
+{
+}
+
+/*!
+ Returns \l Acceptable if \a input is matched by the regular expression for
+ this validator, \l Intermediate if it has matched partially (i.e. could be
+ a valid match if additional valid characters are added), and \l Invalid if
+ \a input is not matched.
+
+ In case the \a input is not matched, the \a pos parameter is set to
+ the length of the \a input parameter; otherwise, it is not modified.
+
+ For example, if the regular expression is \b{\\w\\d\\d} (word-character,
+ digit, digit) then "A57" is \l Acceptable, "E5" is \l Intermediate, and
+ "+9" is \l Invalid.
+
+ \sa QRegularExpression::match()
+*/
+
+QValidator::State QRegularExpressionValidator::validate(QString &input, int &pos) const
+{
+ Q_D(const QRegularExpressionValidator);
+
+ // We want a validator with an empty QRegularExpression to match anything;
+ // since we're going to do an exact match (by using d->usedRe), first check if the rx is empty
+ // (and, if so, accept the input).
+ if (d->origRe.pattern().isEmpty())
+ return Acceptable;
+
+ const QRegularExpressionMatch m = d->usedRe.match(input, 0, QRegularExpression::PartialPreferCompleteMatch);
+ if (m.hasMatch()) {
+ return Acceptable;
+ } else if (m.hasPartialMatch()) {
+ return Intermediate;
+ } else {
+ pos = input.size();
+ return Invalid;
+ }
+}
+
+/*!
+ \property QRegularExpressionValidator::regularExpression
+ \brief the regular expression used for validation
+
+ By default, this property contains a regular expression with an empty
+ pattern (which therefore matches any string).
+*/
+
+QRegularExpression QRegularExpressionValidator::regularExpression() const
+{
+ Q_D(const QRegularExpressionValidator);
+ return d->origRe;
+}
+
+void QRegularExpressionValidator::setRegularExpression(const QRegularExpression &re)
+{
+ Q_D(QRegularExpressionValidator);
+ d->setRegularExpression(re);
+}
+
+/*!
+ \internal
+
+ Sets \a re as the regular expression. It wraps the regexp that's actually used
+ between \\A and \\z, therefore forcing an exact match.
+*/
+void QRegularExpressionValidatorPrivate::setRegularExpression(const QRegularExpression &re)
+{
+ Q_Q(QRegularExpressionValidator);
+
+ if (origRe != re) {
+ usedRe = origRe = re; // copies also the pattern options
+ usedRe.setPattern(QStringLiteral("\\A(?:") + re.pattern() + QStringLiteral(")\\z"));
+ emit q->regularExpressionChanged(re);
+ emit q->changed();
+ }
+}
+
+#endif // QT_NO_REGULAREXPRESSION
+
QT_END_NAMESPACE
#endif // QT_NO_VALIDATOR
diff --git a/src/gui/util/qvalidator.h b/src/gui/util/qvalidator.h
index 6ffab4907b..386af1bc74 100644
--- a/src/gui/util/qvalidator.h
+++ b/src/gui/util/qvalidator.h
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
** Contact: http://www.qt-project.org/legal
**
** This file is part of the QtGui module of the Qt Toolkit.
@@ -45,10 +46,9 @@
#include <QtCore/qobject.h>
#include <QtCore/qstring.h>
#include <QtCore/qregexp.h>
+#include <QtCore/qregularexpression.h>
#include <QtCore/qlocale.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -195,10 +195,39 @@ private:
#endif // QT_NO_REGEXP
+#ifndef QT_NO_REGULAREXPRESSION
+
+class QRegularExpressionValidatorPrivate;
+
+class Q_GUI_EXPORT QRegularExpressionValidator : public QValidator
+{
+ Q_OBJECT
+ Q_PROPERTY(QRegularExpression regularExpression READ regularExpression WRITE setRegularExpression NOTIFY regularExpressionChanged)
+
+public:
+ explicit QRegularExpressionValidator(QObject *parent = 0);
+ explicit QRegularExpressionValidator(const QRegularExpression &re, QObject *parent = 0);
+ ~QRegularExpressionValidator();
+
+ virtual QValidator::State validate(QString &input, int &pos) const Q_DECL_OVERRIDE;
+
+ QRegularExpression regularExpression() const;
+
+public Q_SLOTS:
+ void setRegularExpression(const QRegularExpression &re);
+
+Q_SIGNALS:
+ void regularExpressionChanged(const QRegularExpression &re);
+
+private:
+ Q_DISABLE_COPY(QRegularExpressionValidator)
+ Q_DECLARE_PRIVATE(QRegularExpressionValidator)
+};
+
+#endif // QT_NO_REGULAREXPRESSION
+
#endif // QT_NO_VALIDATOR
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QVALIDATOR_H
diff --git a/src/network/access/qabstractnetworkcache.h b/src/network/access/qabstractnetworkcache.h
index 6a4d36ced3..b9a086f047 100644
--- a/src/network/access/qabstractnetworkcache.h
+++ b/src/network/access/qabstractnetworkcache.h
@@ -47,8 +47,6 @@
#include <QtCore/qpair.h>
#include <QtNetwork/qnetworkrequest.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -141,6 +139,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/network/access/qftp_p.h b/src/network/access/qftp_p.h
index d87a743036..ee5d124650 100644
--- a/src/network/access/qftp_p.h
+++ b/src/network/access/qftp_p.h
@@ -57,8 +57,6 @@
#include <private/qurlinfo_p.h>
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -176,6 +174,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFTP_H
diff --git a/src/network/access/qhttpmultipart.cpp b/src/network/access/qhttpmultipart.cpp
index ade121925b..4397ef8205 100644
--- a/src/network/access/qhttpmultipart.cpp
+++ b/src/network/access/qhttpmultipart.cpp
@@ -488,6 +488,7 @@ bool QHttpMultiPartIODevice::reset()
for (int a = 0; a < multiPart->parts.count(); a++)
if (!multiPart->parts[a].d->reset())
return false;
+ readPointer = 0;
return true;
}
qint64 QHttpMultiPartIODevice::readData(char *data, qint64 maxSize)
diff --git a/src/network/access/qhttpmultipart.h b/src/network/access/qhttpmultipart.h
index 9913b64de6..71075ad2f3 100644
--- a/src/network/access/qhttpmultipart.h
+++ b/src/network/access/qhttpmultipart.h
@@ -47,8 +47,6 @@
#include <QtCore/QIODevice>
#include <QtNetwork/QNetworkRequest>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -119,6 +117,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QHTTPMULTIPART_H
diff --git a/src/network/access/qhttpnetworkconnection.cpp b/src/network/access/qhttpnetworkconnection.cpp
index eec5cfa96d..a279990f4c 100644
--- a/src/network/access/qhttpnetworkconnection.cpp
+++ b/src/network/access/qhttpnetworkconnection.cpp
@@ -923,7 +923,7 @@ void QHttpNetworkConnectionPrivate::_q_startNextRequest()
fillPipeline(channels[i].socket);
// If there is not already any connected channels we need to connect a new one.
- // We do not pair the channel with the request until we know if it is
+ // We do not pair the channel with the request until we know if it is
// connected or not. This is to reuse connected channels before we connect new once.
int queuedRequest = highPriorityQueue.count() + lowPriorityQueue.count();
for (int i = 0; i < channelCount; ++i) {
@@ -1224,6 +1224,18 @@ void QHttpNetworkConnection::setSslConfiguration(const QSslConfiguration &config
d->channels[i].setSslConfiguration(config);
}
+QSharedPointer<QSslContext> QHttpNetworkConnection::sslContext()
+{
+ Q_D(QHttpNetworkConnection);
+ return d->sslContext;
+}
+
+void QHttpNetworkConnection::setSslContext(QSharedPointer<QSslContext> context)
+{
+ Q_D(QHttpNetworkConnection);
+ d->sslContext = context;
+}
+
void QHttpNetworkConnection::ignoreSslErrors(int channel)
{
Q_D(QHttpNetworkConnection);
diff --git a/src/network/access/qhttpnetworkconnection_p.h b/src/network/access/qhttpnetworkconnection_p.h
index 57d40bfcf2..956499ddab 100644
--- a/src/network/access/qhttpnetworkconnection_p.h
+++ b/src/network/access/qhttpnetworkconnection_p.h
@@ -62,6 +62,7 @@
#include <qnetworkproxy.h>
#include <qbuffer.h>
#include <qtimer.h>
+#include <qsharedpointer.h>
#include <private/qhttpnetworkheader_p.h>
#include <private/qhttpnetworkrequest_p.h>
@@ -72,6 +73,8 @@
#ifndef QT_NO_HTTP
#ifndef QT_NO_SSL
+# include <private/qsslcontext_p.h>
+# include <private/qsslsocket_p.h>
# include <QtNetwork/qsslsocket.h>
# include <QtNetwork/qsslerror.h>
#else
@@ -124,6 +127,8 @@ public:
void setSslConfiguration(const QSslConfiguration &config);
void ignoreSslErrors(int channel = -1);
void ignoreSslErrors(const QList<QSslError> &errors, int channel = -1);
+ QSharedPointer<QSslContext> sslContext();
+ void setSslContext(QSharedPointer<QSslContext> context);
#endif
private:
@@ -234,6 +239,10 @@ public:
QList<HttpMessagePair> highPriorityQueue;
QList<HttpMessagePair> lowPriorityQueue;
+#ifndef QT_NO_SSL
+ QSharedPointer<QSslContext> sslContext;
+#endif
+
#ifndef QT_NO_BEARERMANAGEMENT
QSharedPointer<QNetworkSession> networkSession;
#endif
diff --git a/src/network/access/qhttpnetworkconnectionchannel.cpp b/src/network/access/qhttpnetworkconnectionchannel.cpp
index 38723a7032..4b8fe8aca7 100644
--- a/src/network/access/qhttpnetworkconnectionchannel.cpp
+++ b/src/network/access/qhttpnetworkconnectionchannel.cpp
@@ -622,6 +622,13 @@ bool QHttpNetworkConnectionChannel::ensureConnection()
if (ssl) {
#ifndef QT_NO_SSL
QSslSocket *sslSocket = qobject_cast<QSslSocket*>(socket);
+
+ // check whether we can re-use an existing SSL session
+ // (meaning another socket in this connection has already
+ // performed a full handshake)
+ if (!connection->sslContext().isNull())
+ QSslSocketPrivate::checkSettingSslContext(sslSocket, connection->sslContext());
+
sslSocket->connectToHostEncrypted(connectHost, connectPort, QIODevice::ReadWrite, networkLayerPreference);
if (ignoreAllSslErrors)
sslSocket->ignoreSslErrors();
@@ -1065,7 +1072,17 @@ void QHttpNetworkConnectionChannel::_q_connected()
// ### FIXME: if the server closes the connection unexpectedly, we shouldn't send the same broken request again!
//channels[i].reconnectAttempts = 2;
- if (!pendingEncrypt) {
+ if (pendingEncrypt) {
+#ifndef QT_NO_SSL
+ if (connection->sslContext().isNull()) {
+ // this socket is making the 1st handshake for this connection,
+ // we need to set the SSL context so new sockets can reuse it
+ QSharedPointer<QSslContext> socketSslContext = QSslSocketPrivate::sslContext(static_cast<QSslSocket*>(socket));
+ if (!socketSslContext.isNull())
+ connection->setSslContext(socketSslContext);
+ }
+#endif
+ } else {
state = QHttpNetworkConnectionChannel::IdleState;
if (!reply)
connection->d_func()->dequeueRequest(socket);
@@ -1208,6 +1225,8 @@ void QHttpNetworkConnectionChannel::_q_encrypted()
if (!reply)
connection->d_func()->dequeueRequest(socket);
if (reply)
+ emit reply->encrypted();
+ if (reply)
sendRequest();
}
diff --git a/src/network/access/qhttpnetworkconnectionchannel_p.h b/src/network/access/qhttpnetworkconnectionchannel_p.h
index 3577d76df5..c8138b5453 100644
--- a/src/network/access/qhttpnetworkconnectionchannel_p.h
+++ b/src/network/access/qhttpnetworkconnectionchannel_p.h
@@ -146,7 +146,7 @@ public:
QHttpNetworkConnectionChannel();
QAbstractSocket::NetworkLayerProtocol networkLayerPreference;
-
+
void setConnection(QHttpNetworkConnection *c);
QPointer<QHttpNetworkConnection> connection;
diff --git a/src/network/access/qhttpnetworkreply_p.h b/src/network/access/qhttpnetworkreply_p.h
index e849c66659..7aea9f14ec 100644
--- a/src/network/access/qhttpnetworkreply_p.h
+++ b/src/network/access/qhttpnetworkreply_p.h
@@ -142,6 +142,7 @@ public:
void ignoreSslErrors(const QList<QSslError> &errors);
Q_SIGNALS:
+ void encrypted();
void sslErrors(const QList<QSslError> &errors);
#endif
diff --git a/src/network/access/qhttpthreaddelegate.cpp b/src/network/access/qhttpthreaddelegate.cpp
index 117265dbfb..a2cee48b22 100644
--- a/src/network/access/qhttpthreaddelegate.cpp
+++ b/src/network/access/qhttpthreaddelegate.cpp
@@ -315,6 +315,7 @@ void QHttpThreadDelegate::startRequest()
connect(httpReply,SIGNAL(readyRead()), this, SLOT(readyReadSlot()));
connect(httpReply,SIGNAL(dataReadProgress(qint64,qint64)), this, SLOT(dataReadProgressSlot(qint64,qint64)));
#ifndef QT_NO_SSL
+ connect(httpReply,SIGNAL(encrypted()), this, SLOT(encryptedSlot()));
connect(httpReply,SIGNAL(sslErrors(QList<QSslError>)), this, SLOT(sslErrorsSlot(QList<QSslError>)));
#endif
@@ -589,6 +590,14 @@ void QHttpThreadDelegate::cacheCredentialsSlot(const QHttpNetworkRequest &reques
#ifndef QT_NO_SSL
+void QHttpThreadDelegate::encryptedSlot()
+{
+ if (!httpReply)
+ return;
+
+ emit encrypted();
+}
+
void QHttpThreadDelegate::sslErrorsSlot(const QList<QSslError> &errors)
{
if (!httpReply)
diff --git a/src/network/access/qhttpthreaddelegate_p.h b/src/network/access/qhttpthreaddelegate_p.h
index 86192c77cc..d9ef1a0a55 100644
--- a/src/network/access/qhttpthreaddelegate_p.h
+++ b/src/network/access/qhttpthreaddelegate_p.h
@@ -135,6 +135,7 @@ signals:
void proxyAuthenticationRequired(const QNetworkProxy &, QAuthenticator *);
#endif
#ifndef QT_NO_SSL
+ void encrypted();
void sslErrors(const QList<QSslError> &, bool *, QList<QSslError> *);
void sslConfigurationChanged(const QSslConfiguration);
#endif
@@ -164,6 +165,7 @@ protected slots:
void dataReadProgressSlot(qint64 done, qint64 total);
void cacheCredentialsSlot(const QHttpNetworkRequest &request, QAuthenticator *authenticator);
#ifndef QT_NO_SSL
+ void encryptedSlot();
void sslErrorsSlot(const QList<QSslError> &errors);
#endif
diff --git a/src/network/access/qnetworkaccessbackend.cpp b/src/network/access/qnetworkaccessbackend.cpp
index 84f9b82a22..a895864d76 100644
--- a/src/network/access/qnetworkaccessbackend.cpp
+++ b/src/network/access/qnetworkaccessbackend.cpp
@@ -340,6 +340,13 @@ void QNetworkAccessBackend::redirectionRequested(const QUrl &target)
reply->redirectionRequested(target);
}
+void QNetworkAccessBackend::encrypted()
+{
+#ifndef QT_NO_SSL
+ reply->encrypted();
+#endif
+}
+
void QNetworkAccessBackend::sslErrors(const QList<QSslError> &errors)
{
#ifndef QT_NO_SSL
diff --git a/src/network/access/qnetworkaccessbackend_p.h b/src/network/access/qnetworkaccessbackend_p.h
index 23f8416e0e..bf284414e0 100644
--- a/src/network/access/qnetworkaccessbackend_p.h
+++ b/src/network/access/qnetworkaccessbackend_p.h
@@ -196,6 +196,7 @@ protected slots:
void authenticationRequired(QAuthenticator *auth);
void metaDataChanged();
void redirectionRequested(const QUrl &destination);
+ void encrypted();
void sslErrors(const QList<QSslError> &errors);
void emitReplyUploadProgress(qint64 bytesSent, qint64 bytesTotal);
diff --git a/src/network/access/qnetworkaccessdebugpipebackend.cpp b/src/network/access/qnetworkaccessdebugpipebackend.cpp
index d9d3200564..b6c04dddea 100644
--- a/src/network/access/qnetworkaccessdebugpipebackend.cpp
+++ b/src/network/access/qnetworkaccessdebugpipebackend.cpp
@@ -143,7 +143,7 @@ void QNetworkAccessDebugPipeBackend::pushFromSocketToDownstream()
buffer.resize(ReadBufferSize);
qint64 haveRead = socket.read(buffer.data(), ReadBufferSize);
-
+
if (haveRead == -1) {
hasDownloadFinished = true;
// this ensures a good last downloadProgress is emitted
diff --git a/src/network/access/qnetworkaccessfilebackend.cpp b/src/network/access/qnetworkaccessfilebackend.cpp
index a7f35815f9..13428cc802 100644
--- a/src/network/access/qnetworkaccessfilebackend.cpp
+++ b/src/network/access/qnetworkaccessfilebackend.cpp
@@ -65,7 +65,11 @@ QNetworkAccessFileBackendFactory::create(QNetworkAccessManager::Operation op,
}
QUrl url = request.url();
- if (url.scheme().compare(QLatin1String("qrc"), Qt::CaseInsensitive) == 0 || url.isLocalFile()) {
+ if (url.scheme().compare(QLatin1String("qrc"), Qt::CaseInsensitive) == 0
+#if defined(Q_OS_ANDROID)
+ || url.scheme().compare(QLatin1String("assets"), Qt::CaseInsensitive) == 0
+#endif
+ || url.isLocalFile()) {
return new QNetworkAccessFileBackend;
} else if (!url.scheme().isEmpty() && url.authority().isEmpty() && (url.scheme().length() > 1)) {
// check if QFile could, in theory, open this URL via the file engines
@@ -113,10 +117,16 @@ void QNetworkAccessFileBackend::open()
QString fileName = url.toLocalFile();
if (fileName.isEmpty()) {
- if (url.scheme() == QLatin1String("qrc"))
+ if (url.scheme() == QLatin1String("qrc")) {
fileName = QLatin1Char(':') + url.path();
- else
- fileName = url.toString(QUrl::RemoveAuthority | QUrl::RemoveFragment | QUrl::RemoveQuery);
+ } else {
+#if defined(Q_OS_ANDROID)
+ if (url.scheme() == QLatin1String("assets"))
+ fileName = QLatin1String("assets:") + url.path();
+ else
+#endif
+ fileName = url.toString(QUrl::RemoveAuthority | QUrl::RemoveFragment | QUrl::RemoveQuery);
+ }
}
file.setFileName(fileName);
diff --git a/src/network/access/qnetworkaccessmanager.cpp b/src/network/access/qnetworkaccessmanager.cpp
index 6899653800..83cb729589 100644
--- a/src/network/access/qnetworkaccessmanager.cpp
+++ b/src/network/access/qnetworkaccessmanager.cpp
@@ -374,6 +374,32 @@ static void ensureInitialized()
*/
/*!
+ \fn void QNetworkAccessManager::encrypted(QNetworkReply *reply)
+ \since 5.1
+
+ This signal is emitted when an SSL/TLS session has successfully
+ completed the initial handshake. At this point, no user data
+ has been transmitted. The signal can be used to perform
+ additional checks on the certificate chain, for example to
+ notify users when the certificate for a website has changed. The
+ \a reply parameter specifies which network reply is responsible.
+ If the reply does not match the expected criteria then it should
+ be aborted by calling QNetworkReply::abort() by a slot connected
+ to this signal. The SSL configuration in use can be inspected
+ using the QNetworkReply::sslConfiguration() method.
+
+ Internally, QNetworkAccessManager may open multiple connections
+ to a server, in order to allow it process requests in parallel.
+ These connections may be reused, which means that the encrypted()
+ signal would not be emitted. This means that you are only
+ guaranteed to receive this signal for the first connection to a
+ site in the lifespan of the QNetworkAccessManager.
+
+ \sa QSslSocket::encrypted()
+ \sa QNetworkReply::encrypted()
+*/
+
+/*!
\fn void QNetworkAccessManager::sslErrors(QNetworkReply *reply, const QList<QSslError> &errors)
This signal is emitted if the SSL/TLS session encountered errors
@@ -646,8 +672,8 @@ QNetworkReply *QNetworkAccessManager::head(const QNetworkRequest &request)
/*!
Posts a request to obtain the contents of the target \a request
- and returns a new QNetworkReply object opened for reading which emits the
- \l{QIODevice::readyRead()}{readyRead()} signal whenever new data
+ and returns a new QNetworkReply object opened for reading which emits the
+ \l{QIODevice::readyRead()}{readyRead()} signal whenever new data
arrives.
The contents as well as associated headers will be downloaded.
@@ -661,11 +687,11 @@ QNetworkReply *QNetworkAccessManager::get(const QNetworkRequest &request)
/*!
Sends an HTTP POST request to the destination specified by \a request
- and returns a new QNetworkReply object opened for reading that will
- contain the reply sent by the server. The contents of the \a data
+ and returns a new QNetworkReply object opened for reading that will
+ contain the reply sent by the server. The contents of the \a data
device will be uploaded to the server.
- \a data must be open for reading and must remain valid until the
+ \a data must be open for reading and must remain valid until the
finished() signal is emitted for this reply.
\note Sending a POST request on protocols other than HTTP and
@@ -681,7 +707,7 @@ QNetworkReply *QNetworkAccessManager::post(const QNetworkRequest &request, QIODe
/*!
\overload
- Sends the contents of the \a data byte array to the destination
+ Sends the contents of the \a data byte array to the destination
specified by \a request.
*/
QNetworkReply *QNetworkAccessManager::post(const QNetworkRequest &request, const QByteArray &data)
@@ -744,8 +770,8 @@ QNetworkReply *QNetworkAccessManager::put(const QNetworkRequest &request, QHttpM
this reply.
Whether anything will be available for reading from the returned
- object is protocol dependent. For HTTP, the server may send a
- small HTML page indicating the upload was successful (or not).
+ object is protocol dependent. For HTTP, the server may send a
+ small HTML page indicating the upload was successful (or not).
Other protocols will probably have content in their replies.
\note For HTTP, this request will send a PUT request, which most servers
@@ -781,7 +807,7 @@ QNetworkReply *QNetworkAccessManager::put(const QNetworkRequest &request, const
Sends a request to delete the resource identified by the URL of \a request.
- \note This feature is currently available for HTTP only, performing an
+ \note This feature is currently available for HTTP only, performing an
HTTP DELETE request.
\sa get(), post(), put(), sendCustomRequest()
@@ -834,10 +860,12 @@ QNetworkConfiguration QNetworkAccessManager::configuration() const
Q_D(const QNetworkAccessManager);
QSharedPointer<QNetworkSession> session(d->getNetworkSession());
- if (session)
+ if (session) {
return session->configuration();
- else
- return QNetworkConfiguration();
+ } else {
+ QNetworkConfigurationManager manager;
+ return manager.defaultConfiguration();
+ }
}
/*!
@@ -860,13 +888,12 @@ QNetworkConfiguration QNetworkAccessManager::activeConfiguration() const
Q_D(const QNetworkAccessManager);
QSharedPointer<QNetworkSession> networkSession(d->getNetworkSession());
+ QNetworkConfigurationManager manager;
if (networkSession) {
- QNetworkConfigurationManager manager;
-
return manager.configurationFromIdentifier(
networkSession->sessionProperty(QLatin1String("ActiveConfiguration")).toString());
} else {
- return QNetworkConfiguration();
+ return manager.defaultConfiguration();
}
}
@@ -983,7 +1010,11 @@ QNetworkReply *QNetworkAccessManager::createRequest(QNetworkAccessManager::Opera
// fast path for GET on file:// URLs
// The QNetworkAccessFileBackend will right now only be used for PUT
if ((op == QNetworkAccessManager::GetOperation || op == QNetworkAccessManager::HeadOperation)
- && (isLocalFile || scheme == QLatin1String("qrc"))) {
+ && (isLocalFile || scheme == QLatin1String("qrc")
+#if defined(Q_OS_ANDROID)
+ || scheme == QLatin1String("assets")
+#endif
+ )) {
return new QNetworkReplyFileImpl(this, req, op);
}
@@ -1131,6 +1162,16 @@ void QNetworkAccessManagerPrivate::_q_replyFinished()
#endif
}
+void QNetworkAccessManagerPrivate::_q_replyEncrypted()
+{
+#ifndef QT_NO_SSL
+ Q_Q(QNetworkAccessManager);
+ QNetworkReply *reply = qobject_cast<QNetworkReply *>(q->sender());
+ if (reply)
+ emit q->encrypted(reply);
+#endif
+}
+
void QNetworkAccessManagerPrivate::_q_replySslErrors(const QList<QSslError> &errors)
{
#ifndef QT_NO_SSL
@@ -1151,6 +1192,7 @@ QNetworkReply *QNetworkAccessManagerPrivate::postProcess(QNetworkReply *reply)
#ifndef QT_NO_SSL
/* In case we're compiled without SSL support, we don't have this signal and we need to
* avoid getting a connection error. */
+ q->connect(reply, SIGNAL(encrypted()), SLOT(_q_replyEncrypted()));
q->connect(reply, SIGNAL(sslErrors(QList<QSslError>)), SLOT(_q_replySslErrors(QList<QSslError>)));
#endif
#ifndef QT_NO_BEARERMANAGEMENT
diff --git a/src/network/access/qnetworkaccessmanager.h b/src/network/access/qnetworkaccessmanager.h
index af5f6933a4..826c8e47d7 100644
--- a/src/network/access/qnetworkaccessmanager.h
+++ b/src/network/access/qnetworkaccessmanager.h
@@ -44,8 +44,6 @@
#include <QtCore/QObject>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -141,6 +139,7 @@ Q_SIGNALS:
void authenticationRequired(QNetworkReply *reply, QAuthenticator *authenticator);
void finished(QNetworkReply *reply);
#ifndef QT_NO_SSL
+ void encrypted(QNetworkReply *reply);
void sslErrors(QNetworkReply *reply, const QList<QSslError> &errors);
#endif
@@ -161,6 +160,7 @@ private:
Q_DECLARE_PRIVATE(QNetworkAccessManager)
Q_PRIVATE_SLOT(d_func(), void _q_replyFinished())
+ Q_PRIVATE_SLOT(d_func(), void _q_replyEncrypted())
Q_PRIVATE_SLOT(d_func(), void _q_replySslErrors(QList<QSslError>))
#ifndef QT_NO_BEARERMANAGEMENT
Q_PRIVATE_SLOT(d_func(), void _q_networkSessionClosed())
@@ -170,6 +170,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/network/access/qnetworkaccessmanager_p.h b/src/network/access/qnetworkaccessmanager_p.h
index b4ad3511fa..cf756dad7b 100644
--- a/src/network/access/qnetworkaccessmanager_p.h
+++ b/src/network/access/qnetworkaccessmanager_p.h
@@ -90,6 +90,7 @@ public:
~QNetworkAccessManagerPrivate();
void _q_replyFinished();
+ void _q_replyEncrypted();
void _q_replySslErrors(const QList<QSslError> &errors);
QNetworkReply *postProcess(QNetworkReply *reply);
void createCookieJar() const;
diff --git a/src/network/access/qnetworkcookie.h b/src/network/access/qnetworkcookie.h
index e7f6c8fe3f..2a4e686b2c 100644
--- a/src/network/access/qnetworkcookie.h
+++ b/src/network/access/qnetworkcookie.h
@@ -47,8 +47,6 @@
#include <QtCore/QMetaType>
#include <QtCore/QObject>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -121,6 +119,4 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QNetworkCookie)
-QT_END_HEADER
-
#endif
diff --git a/src/network/access/qnetworkcookiejar.h b/src/network/access/qnetworkcookiejar.h
index 7868e1fc04..3c787c5dd8 100644
--- a/src/network/access/qnetworkcookiejar.h
+++ b/src/network/access/qnetworkcookiejar.h
@@ -45,8 +45,6 @@
#include <QtCore/QObject>
#include <QtCore/QUrl>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -79,6 +77,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/network/access/qnetworkdiskcache.h b/src/network/access/qnetworkdiskcache.h
index 1d5f293a2c..20a412c96e 100644
--- a/src/network/access/qnetworkdiskcache.h
+++ b/src/network/access/qnetworkdiskcache.h
@@ -44,8 +44,6 @@
#include <QtNetwork/qabstractnetworkcache.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -91,6 +89,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QNETWORKDISKCACHE_H
diff --git a/src/network/access/qnetworkreply.cpp b/src/network/access/qnetworkreply.cpp
index fd3b7760cb..dc42adc612 100644
--- a/src/network/access/qnetworkreply.cpp
+++ b/src/network/access/qnetworkreply.cpp
@@ -195,6 +195,31 @@ QNetworkReplyPrivate::QNetworkReplyPrivate()
*/
/*!
+ \fn void QNetworkReply::encrypted()
+ \since 5.1
+
+ This signal is emitted when an SSL/TLS session has successfully
+ completed the initial handshake. At this point, no user data
+ has been transmitted. The signal can be used to perform
+ additional checks on the certificate chain, for example to
+ notify users when the certificate for a website has changed.
+ If the reply does not match the expected criteria then it should
+ be aborted by calling QNetworkReply::abort() by a slot connected
+ to this signal. The SSL configuration in use can be inspected
+ using the QNetworkReply::sslConfiguration() method.
+
+ Internally, QNetworkAccessManager may open multiple connections
+ to a server, in order to allow it process requests in parallel.
+ These connections may be reused, which means that the encrypted()
+ signal would not be emitted. This means that you are only
+ guaranteed to receive this signal for the first connection to a
+ site in the lifespan of the QNetworkAccessManager.
+
+ \sa QSslSocket::encrypted()
+ \sa QNetworkAccessManager::encrypted()
+*/
+
+/*!
\fn void QNetworkReply::sslErrors(const QList<QSslError> &errors)
This signal is emitted if the SSL/TLS session encountered errors
diff --git a/src/network/access/qnetworkreply.h b/src/network/access/qnetworkreply.h
index 8e770bc96b..a7db2d189c 100644
--- a/src/network/access/qnetworkreply.h
+++ b/src/network/access/qnetworkreply.h
@@ -49,8 +49,6 @@
#include <QtNetwork/QNetworkRequest>
#include <QtNetwork/QNetworkAccessManager>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -150,6 +148,7 @@ Q_SIGNALS:
void finished();
void error(QNetworkReply::NetworkError);
#ifndef QT_NO_SSL
+ void encrypted();
void sslErrors(const QList<QSslError> &errors);
#endif
@@ -182,6 +181,4 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QNetworkReply::NetworkError)
-QT_END_HEADER
-
#endif
diff --git a/src/network/access/qnetworkreplyfileimpl.cpp b/src/network/access/qnetworkreplyfileimpl.cpp
index 8a8f73c24f..f7555f8fc3 100644
--- a/src/network/access/qnetworkreplyfileimpl.cpp
+++ b/src/network/access/qnetworkreplyfileimpl.cpp
@@ -91,10 +91,16 @@ QNetworkReplyFileImpl::QNetworkReplyFileImpl(QObject *parent, const QNetworkRequ
QString fileName = url.toLocalFile();
if (fileName.isEmpty()) {
- if (url.scheme() == QLatin1String("qrc"))
+ if (url.scheme() == QLatin1String("qrc")) {
fileName = QLatin1Char(':') + url.path();
- else
- fileName = url.toString(QUrl::RemoveAuthority | QUrl::RemoveFragment | QUrl::RemoveQuery);
+ } else {
+#if defined(Q_OS_ANDROID)
+ if (url.scheme() == QLatin1String("assets"))
+ fileName = QLatin1String("assets:") + url.path();
+ else
+#endif
+ fileName = url.toString(QUrl::RemoveAuthority | QUrl::RemoveFragment | QUrl::RemoveQuery);
+ }
}
QFileInfo fi(fileName);
diff --git a/src/network/access/qnetworkreplyhttpimpl.cpp b/src/network/access/qnetworkreplyhttpimpl.cpp
index 1520816e8d..c04421e5c7 100644
--- a/src/network/access/qnetworkreplyhttpimpl.cpp
+++ b/src/network/access/qnetworkreplyhttpimpl.cpp
@@ -610,14 +610,14 @@ void QNetworkReplyHttpImplPrivate::postRequest()
if (synchronous) {
// A synchronous HTTP request uses its own thread
thread = new QThread();
- thread->setObjectName(QStringLiteral("httpReply"));
+ thread->setObjectName(QStringLiteral("Qt HTTP synchronous thread"));
QObject::connect(thread, SIGNAL(finished()), thread, SLOT(deleteLater()));
thread->start();
} else if (!managerPrivate->httpThread) {
// We use the manager-global thread.
// At some point we could switch to having multiple threads if it makes sense.
managerPrivate->httpThread = new QThread();
- managerPrivate->httpThread->setObjectName(QStringLiteral("httpThread"));
+ managerPrivate->httpThread->setObjectName(QStringLiteral("Qt HTTP thread"));
managerPrivate->httpThread->start();
thread = managerPrivate->httpThread;
@@ -830,6 +830,8 @@ void QNetworkReplyHttpImplPrivate::postRequest()
Qt::BlockingQueuedConnection);
#endif
#ifndef QT_NO_SSL
+ QObject::connect(delegate, SIGNAL(encrypted()), q, SLOT(replyEncrypted()),
+ Qt::BlockingQueuedConnection);
QObject::connect(delegate, SIGNAL(sslErrors(QList<QSslError>,bool*,QList<QSslError>*)),
q, SLOT(replySslErrors(QList<QSslError>,bool*,QList<QSslError>*)),
Qt::BlockingQueuedConnection);
@@ -1220,6 +1222,12 @@ void QNetworkReplyHttpImplPrivate::httpError(QNetworkReply::NetworkError errorCo
}
#ifndef QT_NO_SSL
+void QNetworkReplyHttpImplPrivate::replyEncrypted()
+{
+ Q_Q(QNetworkReplyHttpImpl);
+ emit q->encrypted();
+}
+
void QNetworkReplyHttpImplPrivate::replySslErrors(
const QList<QSslError> &list, bool *ignoreAll, QList<QSslError> *toBeIgnored)
{
diff --git a/src/network/access/qnetworkreplyhttpimpl_p.h b/src/network/access/qnetworkreplyhttpimpl_p.h
index 5f8f0badf7..15cc0ec476 100644
--- a/src/network/access/qnetworkreplyhttpimpl_p.h
+++ b/src/network/access/qnetworkreplyhttpimpl_p.h
@@ -116,6 +116,7 @@ public:
Q_PRIVATE_SLOT(d_func(), void httpAuthenticationRequired(const QHttpNetworkRequest &, QAuthenticator *))
Q_PRIVATE_SLOT(d_func(), void httpError(QNetworkReply::NetworkError, const QString &))
#ifndef QT_NO_SSL
+ Q_PRIVATE_SLOT(d_func(), void replyEncrypted())
Q_PRIVATE_SLOT(d_func(), void replySslErrors(const QList<QSslError> &, bool *, QList<QSslError> *))
Q_PRIVATE_SLOT(d_func(), void replySslConfigurationChanged(const QSslConfiguration&))
#endif
@@ -280,6 +281,7 @@ public:
void httpAuthenticationRequired(const QHttpNetworkRequest &request, QAuthenticator *auth);
void httpError(QNetworkReply::NetworkError error, const QString &errorString);
#ifndef QT_NO_SSL
+ void replyEncrypted();
void replySslErrors(const QList<QSslError> &, bool *, QList<QSslError> *);
void replySslConfigurationChanged(const QSslConfiguration&);
#endif
diff --git a/src/network/access/qnetworkreplyimpl.cpp b/src/network/access/qnetworkreplyimpl.cpp
index e12286c459..33357293a3 100644
--- a/src/network/access/qnetworkreplyimpl.cpp
+++ b/src/network/access/qnetworkreplyimpl.cpp
@@ -879,6 +879,14 @@ void QNetworkReplyImplPrivate::redirectionRequested(const QUrl &target)
attributes.insert(QNetworkRequest::RedirectionTargetAttribute, target);
}
+void QNetworkReplyImplPrivate::encrypted()
+{
+#ifndef QT_NO_SSL
+ Q_Q(QNetworkReplyImpl);
+ emit q->encrypted();
+#endif
+}
+
void QNetworkReplyImplPrivate::sslErrors(const QList<QSslError> &errors)
{
#ifndef QT_NO_SSL
diff --git a/src/network/access/qnetworkreplyimpl_p.h b/src/network/access/qnetworkreplyimpl_p.h
index ca9a3b5fd1..9edc0f6b59 100644
--- a/src/network/access/qnetworkreplyimpl_p.h
+++ b/src/network/access/qnetworkreplyimpl_p.h
@@ -176,6 +176,7 @@ public:
void error(QNetworkReply::NetworkError code, const QString &errorString);
void metaDataChanged();
void redirectionRequested(const QUrl &target);
+ void encrypted();
void sslErrors(const QList<QSslError> &errors);
QNetworkAccessBackend *backend;
diff --git a/src/network/access/qnetworkrequest.h b/src/network/access/qnetworkrequest.h
index 0d3c72d18a..1512c6dadd 100644
--- a/src/network/access/qnetworkrequest.h
+++ b/src/network/access/qnetworkrequest.h
@@ -47,8 +47,6 @@
#include <QtCore/QUrl>
#include <QtCore/QVariant>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -159,6 +157,4 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QNetworkRequest)
-QT_END_HEADER
-
#endif
diff --git a/src/network/bearer/qbearerplugin_p.h b/src/network/bearer/qbearerplugin_p.h
index cd646d61a5..7b4611074b 100644
--- a/src/network/bearer/qbearerplugin_p.h
+++ b/src/network/bearer/qbearerplugin_p.h
@@ -60,8 +60,6 @@
#ifndef QT_NO_BEARERMANAGEMENT
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -79,8 +77,6 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_BEARERMANAGEMENT
#endif // QBEARERPLUGIN_P_H
diff --git a/src/network/bearer/qnetworkconfigmanager.cpp b/src/network/bearer/qnetworkconfigmanager.cpp
index ec8d7894fa..4f74936ac7 100644
--- a/src/network/bearer/qnetworkconfigmanager.cpp
+++ b/src/network/bearer/qnetworkconfigmanager.cpp
@@ -55,10 +55,13 @@
QT_BEGIN_NAMESPACE
static QBasicAtomicPointer<QNetworkConfigurationManagerPrivate> connManager_ptr;
+static QBasicAtomicInt appShutdown;
static void connManager_cleanup()
{
// this is not atomic or thread-safe!
+ int shutdown = appShutdown.fetchAndStoreAcquire(1);
+ Q_ASSERT(shutdown == 0);
QNetworkConfigurationManagerPrivate *cmp = connManager_ptr.fetchAndStoreAcquire(0);
if (cmp)
cmp->cleanup();
@@ -72,7 +75,8 @@ void QNetworkConfigurationManagerPrivate::addPostRoutine()
QNetworkConfigurationManagerPrivate *qNetworkConfigurationManagerPrivate()
{
QNetworkConfigurationManagerPrivate *ptr = connManager_ptr.loadAcquire();
- if (!ptr) {
+ int shutdown = appShutdown.loadAcquire();
+ if (!ptr && !shutdown) {
static QBasicMutex connManager_mutex;
QMutexLocker locker(&connManager_mutex);
if (!(ptr = connManager_ptr.loadAcquire())) {
@@ -134,7 +138,7 @@ QNetworkConfigurationManagerPrivate *qNetworkConfigurationManagerPrivate()
\sa QNetworkConfiguration
*/
-/*!
+/*!
\fn void QNetworkConfigurationManager::configurationAdded(const QNetworkConfiguration &config)
This signal is emitted whenever a new network configuration is added to the system. The new
diff --git a/src/network/bearer/qnetworkconfigmanager.h b/src/network/bearer/qnetworkconfigmanager.h
index c1b3b57825..62b93b19c1 100644
--- a/src/network/bearer/qnetworkconfigmanager.h
+++ b/src/network/bearer/qnetworkconfigmanager.h
@@ -47,8 +47,6 @@
#ifndef QT_NO_BEARERMANAGEMENT
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QNetworkConfigurationManagerPrivate;
@@ -98,8 +96,6 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QNetworkConfigurationManager::Capabilities)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_BEARERMANAGEMENT
#endif // QNETWORKCONFIGMANAGER_H
diff --git a/src/network/bearer/qnetworkconfigmanager_p.cpp b/src/network/bearer/qnetworkconfigmanager_p.cpp
index c710556f1c..192bf15b50 100644
--- a/src/network/bearer/qnetworkconfigmanager_p.cpp
+++ b/src/network/bearer/qnetworkconfigmanager_p.cpp
@@ -70,7 +70,7 @@ void QNetworkConfigurationManagerPrivate::initialize()
{
//Two stage construction, because we only want to do this heavyweight work for the winner of the Q_GLOBAL_STATIC race.
bearerThread = new QThread();
- bearerThread->setObjectName(QStringLiteral("bearerThread"));
+ bearerThread->setObjectName(QStringLiteral("Qt bearer thread"));
bearerThread->moveToThread(QCoreApplicationPrivate::mainThread()); // because cleanup() is called in main thread context.
moveToThread(bearerThread);
diff --git a/src/network/bearer/qnetworkconfiguration.h b/src/network/bearer/qnetworkconfiguration.h
index 97fb1d270b..25dafcb282 100644
--- a/src/network/bearer/qnetworkconfiguration.h
+++ b/src/network/bearer/qnetworkconfiguration.h
@@ -49,8 +49,6 @@
#include <QtCore/qlist.h>
#include <QtCore/qmetatype.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QNetworkConfigurationPrivate;
@@ -130,6 +128,4 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QNetworkConfiguration)
-QT_END_HEADER
-
#endif // QNETWORKCONFIGURATION_H
diff --git a/src/network/bearer/qnetworksession.cpp b/src/network/bearer/qnetworksession.cpp
index f06a2d0df4..cca95fce8c 100644
--- a/src/network/bearer/qnetworksession.cpp
+++ b/src/network/bearer/qnetworksession.cpp
@@ -66,37 +66,37 @@ QT_BEGIN_NAMESPACE
\ingroup network
A QNetworkSession enables control over the system's network interfaces. The session's configuration
- parameter are determined via the QNetworkConfiguration object to which it is bound. Depending on the
+ parameter are determined via the QNetworkConfiguration object to which it is bound. Depending on the
type of the session (single access point or service network) a session may be linked to one or more
- network interfaces. By means of \l{open()}{opening} and \l{close()}{closing} of network sessions
- a developer can start and stop the systems network interfaces. If the configuration represents
+ network interfaces. By means of \l{open()}{opening} and \l{close()}{closing} of network sessions
+ a developer can start and stop the systems network interfaces. If the configuration represents
multiple access points (see \l QNetworkConfiguration::ServiceNetwork) more advanced features such as roaming may be supported.
- QNetworkSession supports session management within the same process and depending on the platform's
- capabilities may support out-of-process sessions. If the same
+ QNetworkSession supports session management within the same process and depending on the platform's
+ capabilities may support out-of-process sessions. If the same
network configuration is used by multiple open sessions the underlying network interface is only terminated once
the last session has been closed.
\section1 Roaming
- Applications may connect to the preferredConfigurationChanged() signal in order to
- receive notifications when a more suitable access point becomes available.
+ Applications may connect to the preferredConfigurationChanged() signal in order to
+ receive notifications when a more suitable access point becomes available.
In response to this signal the application must either initiate the roaming via migrate()
- or ignore() the new access point. Once the session has roamed the
- newConfigurationActivated() signal is emitted. The application may now test the
+ or ignore() the new access point. Once the session has roamed the
+ newConfigurationActivated() signal is emitted. The application may now test the
carrier and must either accept() or reject() it. The session will return to the previous
access point if the roaming was rejected. The subsequent state diagram depicts the required
state transitions.
-
+
\image roaming-states.png
- Some platforms may distinguish forced roaming and application level roaming (ALR).
- ALR implies that the application controls (via migrate(), ignore(), accept() and reject())
+ Some platforms may distinguish forced roaming and application level roaming (ALR).
+ ALR implies that the application controls (via migrate(), ignore(), accept() and reject())
whether a network session can roam from one access point to the next. Such control is useful
if the application maintains stateful socket connections and wants to control the transition from
- one interface to the next. Forced roaming implies that the system automatically roams to the next network without
+ one interface to the next. Forced roaming implies that the system automatically roams to the next network without
consulting the application. This has the advantage that the application can make use of roaming features
- without actually being aware of it. It is expected that the application detects that the underlying
+ without actually being aware of it. It is expected that the application detects that the underlying
socket is broken and automatically reconnects via the new network link.
If the platform supports both modes of roaming, an application indicates its preference
@@ -105,7 +105,7 @@ QT_BEGIN_NAMESPACE
level roaming. If the client does not connect to the preferredConfigurationChanged(), forced roaming
is used. If forced roaming is not supported the network session will not roam by default.
- Some applications may want to suppress any form of roaming altogether. Possible use cases may be
+ Some applications may want to suppress any form of roaming altogether. Possible use cases may be
high priority downloads or remote services which cannot handle a roaming enabled client. Clients
can suppress roaming by connecting to the preferredConfigurationChanged() signal and answer each
signal emission with ignore().
@@ -120,19 +120,19 @@ QT_BEGIN_NAMESPACE
single access point configuration the state of the session is the same as the state of the
associated network interface.
- \value Invalid The session is invalid due to an invalid configuration. This may
- happen due to a removed access point or a configuration that was
+ \value Invalid The session is invalid due to an invalid configuration. This may
+ happen due to a removed access point or a configuration that was
invalid to begin with.
\value NotAvailable The session is based on a defined but not yet discovered QNetworkConfiguration
(see \l QNetworkConfiguration::StateFlag).
\value Connecting The network session is being established.
\value Connected The network session is connected. If the current process wishes to use this session
- it has to register its interest by calling open(). A network session
+ it has to register its interest by calling open(). A network session
is considered to be ready for socket operations if it isOpen() and connected.
\value Closing The network session is in the process of being shut down.
\value Disconnected The network session is not connected. The associated QNetworkConfiguration
has the state QNetworkConfiguration::Discovered.
- \value Roaming The network session is roaming from one access point to another
+ \value Roaming The network session is roaming from one access point to another
access point.
*/
@@ -194,16 +194,16 @@ QT_BEGIN_NAMESPACE
If the roaming process is non-seamless the IP address will change which means that
a socket becomes invalid. However seamless mobility can ensure that the local IP address
does not change. This is achieved by using a virtual IP address which is bound to the actual
- link address. During the roaming process the virtual address is attached to the new link
+ link address. During the roaming process the virtual address is attached to the new link
address.
- Some platforms may support the concept of Forced Roaming and Application Level Roaming (ALR).
- Forced roaming implies that the platform may simply roam to a new configuration without
+ Some platforms may support the concept of Forced Roaming and Application Level Roaming (ALR).
+ Forced roaming implies that the platform may simply roam to a new configuration without
consulting applications. It is up to the application to detect the link layer loss and reestablish
- its sockets. In contrast ALR provides the opportunity to prevent the system from roaming.
+ its sockets. In contrast ALR provides the opportunity to prevent the system from roaming.
If this session is based on a configuration that supports roaming the application can choose
- whether it wants to be consulted (ALR use case) by connecting to this signal. For as long as this signal
- connection remains the session remains registered as a roaming stakeholder; otherwise roaming will
+ whether it wants to be consulted (ALR use case) by connecting to this signal. For as long as this signal
+ connection remains the session remains registered as a roaming stakeholder; otherwise roaming will
be enforced by the platform.
\sa migrate(), ignore(), QNetworkConfiguration::isRoamingAvailable()
@@ -214,7 +214,7 @@ QT_BEGIN_NAMESPACE
This signal is emitted once the session has roamed to the new access point.
The application may reopen its socket and test the suitability of the new network link.
- Subsequently it must either accept() or reject() the new access point.
+ Subsequently it must either accept() or reject() the new access point.
\sa accept(), reject()
*/
@@ -222,8 +222,8 @@ QT_BEGIN_NAMESPACE
/*!
\fn void QNetworkSession::opened()
- This signal is emitted when the network session has been opened.
-
+ This signal is emitted when the network session has been opened.
+
The underlying network interface will not be shut down as long as the session remains open.
Note that this feature is dependent on \l{QNetworkConfigurationManager::SystemSessionSupport}{system wide session support}.
*/
@@ -292,12 +292,12 @@ QNetworkSession::~QNetworkSession()
The system will not terminate a network interface until the session reference counter reaches zero.
Therefore an open session allows an application to register its use of the interface.
- As a result of calling open() the interface will be started if it is not connected/up yet.
+ As a result of calling open() the interface will be started if it is not connected/up yet.
Some platforms may not provide support for out-of-process sessions. On such platforms the session
- counter ignores any sessions held by another process. The platform capabilities can be
+ counter ignores any sessions held by another process. The platform capabilities can be
detected via QNetworkConfigurationManager::capabilities().
- Note that this call is asynchronous. Depending on the outcome of this call the results can be enquired
+ Note that this call is asynchronous. Depending on the outcome of this call the results can be enquired
by connecting to the stateChanged(), opened() or error() signals.
It is not a requirement to open a session in order to monitor the underlying network interface.
@@ -361,10 +361,10 @@ bool QNetworkSession::waitForOpened(int msecs)
\l Disconnected if the current session was the last open session.
If the platform does not support out-of-process sessions calling this function does not stop the
- interface. In this case \l{stop()} has to be used to force a shut down.
+ interface. In this case \l{stop()} has to be used to force a shut down.
The platform capabilities can be detected via QNetworkConfigurationManager::capabilities().
- Note that this call is asynchronous. Depending on the outcome of this call the results can be enquired
+ Note that this call is asynchronous. Depending on the outcome of this call the results can be enquired
by connecting to the stateChanged(), opened() or error() signals.
\sa open(), stop(), isOpen()
@@ -376,7 +376,7 @@ void QNetworkSession::close()
}
/*!
- Invalidates all open sessions against the network interface and therefore stops the
+ Invalidates all open sessions against the network interface and therefore stops the
underlying network interface. This function always changes the session's state() flag to
\l Disconnected.
@@ -426,15 +426,15 @@ bool QNetworkSession::isOpen() const
}
/*!
- Returns the state of the session.
-
- If the session is based on a single access point configuration the state of the
+ Returns the state of the session.
+
+ If the session is based on a single access point configuration the state of the
session is the same as the state of the associated network interface. Therefore
- a network session object can be used to monitor network interfaces.
+ a network session object can be used to monitor network interfaces.
A \l QNetworkConfiguration::ServiceNetwork based session summarizes the state of all its children
- and therefore returns the \l Connected state if at least one of the service network's
- \l {QNetworkConfiguration::children()}{children()} configurations is active.
+ and therefore returns the \l Connected state if at least one of the service network's
+ \l {QNetworkConfiguration::children()}{children()} configurations is active.
Note that it is not required to hold an open session in order to obtain the network interface state.
A connected but closed session may be used to monitor network interfaces whereas an open and connected
@@ -458,7 +458,7 @@ QNetworkSession::SessionError QNetworkSession::error() const
}
/*!
- Returns a human-readable description of the last device error that
+ Returns a human-readable description of the last device error that
occurred.
\sa error()
@@ -485,7 +485,7 @@ QString QNetworkSession::errorString() const
QNetworkConfiguration that is used by this session; otherwise an empty string.
The main purpose of this key is to determine which Internet access point is used
- if the session is based on a \l{QNetworkConfiguration::ServiceNetwork}{ServiceNetwork}.
+ if the session is based on a \l{QNetworkConfiguration::ServiceNetwork}{ServiceNetwork}.
The following code snippet highlights the difference:
\code
QNetworkConfigurationManager mgr;
@@ -512,7 +512,7 @@ QString QNetworkSession::errorString() const
this key may return an identifier for either a
\l {QNetworkConfiguration::ServiceNetwork}{service network} or a
\l {QNetworkConfiguration::InternetAccessPoint}{Internet access points} configurations,
- whereas \e ActiveConfiguration always returns identifiers to
+ whereas \e ActiveConfiguration always returns identifiers to
\l {QNetworkConfiguration::InternetAccessPoint}{Internet access points} configurations.
\row
\li ConnectInBackground
@@ -558,7 +558,7 @@ QVariant QNetworkSession::sessionProperty(const QString &key) const
/*!
Sets the property \a value on the session. The property is identified using
- \a key. Removing an already set property can be achieved by passing an
+ \a key. Removing an already set property can be achieved by passing an
invalid QVariant.
Note that the \e UserChoiceConfiguration and \e ActiveConfiguration
@@ -578,7 +578,7 @@ void QNetworkSession::setSessionProperty(const QString &key, const QVariant &val
}
/*!
- Instructs the session to roam to the new access point. The old access point remains active
+ Instructs the session to roam to the new access point. The old access point remains active
until the application calls accept().
The newConfigurationActivated() signal is emitted once roaming has been completed.
@@ -603,11 +603,11 @@ void QNetworkSession::ignore()
}
/*!
- Instructs the session to permanently accept the new access point. Once this function
+ Instructs the session to permanently accept the new access point. Once this function
has been called the session may not return to the old access point.
The old access point may be closed in the process if there are no other network sessions for it.
- Therefore any open socket that still uses the old access point
+ Therefore any open socket that still uses the old access point
may become unusable and should be closed before completing the migration.
*/
void QNetworkSession::accept()
@@ -617,7 +617,7 @@ void QNetworkSession::accept()
}
/*!
- The new access point is not suitable for the application. By calling this function the
+ The new access point is not suitable for the application. By calling this function the
session returns to the previous access point/configuration. This action may invalidate
any socket that has been created via the not desired access point.
@@ -633,10 +633,10 @@ void QNetworkSession::reject()
/*!
Returns the amount of data sent in bytes; otherwise 0.
- This field value includes the usage across all open network
+ This field value includes the usage across all open network
sessions which use the same network interface.
- If the session is based on a service network configuration the number of
+ If the session is based on a service network configuration the number of
sent bytes across all active member configurations are returned.
This function may not always be supported on all platforms and returns 0.
@@ -652,10 +652,10 @@ quint64 QNetworkSession::bytesWritten() const
/*!
Returns the amount of data received in bytes; otherwise 0.
- This field value includes the usage across all open network
+ This field value includes the usage across all open network
sessions which use the same network interface.
- If the session is based on a service network configuration the number of
+ If the session is based on a service network configuration the number of
sent bytes across all active member configurations are returned.
This function may not always be supported on all platforms and returns 0.
@@ -699,12 +699,12 @@ void QNetworkSessionPrivate::setUsagePolicies(QNetworkSession &session, QNetwork
/*!
\internal
- This function is required to detect whether the client wants to control
+ This function is required to detect whether the client wants to control
the roaming process. If he connects to preferredConfigurationChanged() signal
he intends to influence it. Otherwise QNetworkSession always roams
without registering this session as a stakeholder in the roaming process.
- For more details check the Forced vs ALR roaming section in the QNetworkSession
+ For more details check the Forced vs ALR roaming section in the QNetworkSession
class description.
*/
void QNetworkSession::connectNotify(const QMetaMethod &signal)
diff --git a/src/network/bearer/qnetworksession.h b/src/network/bearer/qnetworksession.h
index 94ab133040..1a76b232e7 100644
--- a/src/network/bearer/qnetworksession.h
+++ b/src/network/bearer/qnetworksession.h
@@ -54,8 +54,6 @@
#undef interface
#endif
-QT_BEGIN_HEADER
-
#include <QtCore/qshareddata.h>
QT_BEGIN_NAMESPACE
@@ -148,8 +146,6 @@ Q_DECLARE_METATYPE(QNetworkSession::State)
Q_DECLARE_METATYPE(QNetworkSession::SessionError)
Q_DECLARE_METATYPE(QNetworkSession::UsagePolicies)
-QT_END_HEADER
-
#endif // QT_NO_BEARERMANAGEMENT
#endif // QNETWORKSESSION_H
diff --git a/src/network/bearer/qnetworksession_p.h b/src/network/bearer/qnetworksession_p.h
index c5af8d8ca0..909cce5e4b 100644
--- a/src/network/bearer/qnetworksession_p.h
+++ b/src/network/bearer/qnetworksession_p.h
@@ -76,7 +76,7 @@ public:
//called by QNetworkSession constructor and ensures
//that the state is immediately updated (w/o actually opening
- //a session). Also this function should take care of
+ //a session). Also this function should take care of
//notification hooks to discover future state changes.
virtual void syncStateWithInterface() = 0;
diff --git a/src/network/doc/snippets/code/src_network_socket_qabstractsocket.cpp b/src/network/doc/snippets/code/src_network_socket_qabstractsocket.cpp
index 01ec19c0ba..af1273dd85 100644
--- a/src/network/doc/snippets/code/src_network_socket_qabstractsocket.cpp
+++ b/src/network/doc/snippets/code/src_network_socket_qabstractsocket.cpp
@@ -47,7 +47,7 @@ if (socket->waitForConnected(1000))
//! [1]
socket->disconnectFromHost();
- if (socket->state() == QAbstractSocket::UnconnectedState ||
+ if (socket->state() == QAbstractSocket::UnconnectedState ||
socket->waitForDisconnected(1000))
qDebug("Disconnected!");
//! [1]
diff --git a/src/network/doc/snippets/network/tcpwait.cpp b/src/network/doc/snippets/network/tcpwait.cpp
index 2be8d7c8ea..fb44e2ded9 100644
--- a/src/network/doc/snippets/network/tcpwait.cpp
+++ b/src/network/doc/snippets/network/tcpwait.cpp
@@ -49,7 +49,7 @@ int main(int argv, char **args)
QTcpSocket socket;
socket.connectToHost("localhost", 1025);
-
+
//! [0]
int numRead = 0, numReadTotal = 0;
char buffer[50];
@@ -58,12 +58,12 @@ int main(int argv, char **args)
numRead = socket.read(buffer, 50);
// do whatever with array
-
+
numReadTotal += numRead;
- if (numRead == 0 && !socket.waitForReadyRead())
+ if (numRead == 0 && !socket.waitForReadyRead())
break;
}
//! [0]
-
+
return app.exec();
}
diff --git a/src/network/kernel/kernel.pri b/src/network/kernel/kernel.pri
index 57df8c8bc8..a4a19988b3 100644
--- a/src/network/kernel/kernel.pri
+++ b/src/network/kernel/kernel.pri
@@ -27,7 +27,7 @@ SOURCES += kernel/qauthenticator.cpp \
unix:SOURCES += kernel/qdnslookup_unix.cpp kernel/qhostinfo_unix.cpp kernel/qnetworkinterface_unix.cpp
-linux-android* {
+android {
SOURCES -= kernel/qdnslookup_unix.cpp
SOURCES += kernel/qdnslookup_android.cpp
}
@@ -39,7 +39,11 @@ win32: {
}
integrity:SOURCES += kernel/qdnslookup_unix.cpp kernel/qhostinfo_unix.cpp kernel/qnetworkinterface_unix.cpp
-mac:LIBS_PRIVATE += -framework SystemConfiguration -framework CoreFoundation -framework CoreServices
+mac {
+ LIBS_PRIVATE += -framework SystemConfiguration -framework CoreFoundation
+ !ios: LIBS_PRIVATE += -framework CoreServices
+}
+
mac:!ios:SOURCES += kernel/qnetworkproxy_mac.cpp
else:win32:SOURCES += kernel/qnetworkproxy_win.cpp
else:blackberry:SOURCES += kernel/qnetworkproxy_blackberry.cpp
diff --git a/src/network/kernel/qauthenticator.cpp b/src/network/kernel/qauthenticator.cpp
index e337a39415..73991aba96 100644
--- a/src/network/kernel/qauthenticator.cpp
+++ b/src/network/kernel/qauthenticator.cpp
@@ -852,7 +852,6 @@ QByteArray QAuthenticatorPrivate::digestMd5Response(const QByteArray &challenge,
//************************Global variables***************************
const int blockSize = 64; //As per RFC2104 Block-size is 512 bits
-const int nDigestLen = 16; //Trunctaion Length of the Hmac-Md5 digest
const quint8 respversion = 1;
const quint8 hirespversion = 1;
diff --git a/src/network/kernel/qauthenticator.h b/src/network/kernel/qauthenticator.h
index 7d199d1dce..4d96104bc0 100644
--- a/src/network/kernel/qauthenticator.h
+++ b/src/network/kernel/qauthenticator.h
@@ -45,8 +45,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qvariant.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -64,7 +62,7 @@ public:
bool operator==(const QAuthenticator &other) const;
inline bool operator!=(const QAuthenticator &other) const { return !operator==(other); }
-
+
QString user() const;
void setUser(const QString &user);
@@ -86,6 +84,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/network/kernel/qdnslookup.h b/src/network/kernel/qdnslookup.h
index 5218c2618a..1df21d866e 100644
--- a/src/network/kernel/qdnslookup.h
+++ b/src/network/kernel/qdnslookup.h
@@ -48,8 +48,6 @@
#include <QtCore/qsharedpointer.h>
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QHostAddress;
@@ -248,6 +246,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDNSLOOKUP_H
diff --git a/src/network/kernel/qhostaddress.cpp b/src/network/kernel/qhostaddress.cpp
index f15c49104d..dc67b0d835 100644
--- a/src/network/kernel/qhostaddress.cpp
+++ b/src/network/kernel/qhostaddress.cpp
@@ -664,7 +664,7 @@ Q_IPV6ADDR QHostAddress::toIPv6Address() const
Returns the address as a string.
For example, if the address is the IPv4 address 127.0.0.1, the
- returned string is "127.0.0.1". For IPv6 the string format will
+ returned string is "127.0.0.1". For IPv6 the string format will
follow the RFC5952 recommendation.
For QHostAddress::Any, its IPv4 address will be returned ("0.0.0.0")
diff --git a/src/network/kernel/qhostaddress.h b/src/network/kernel/qhostaddress.h
index 0e50a677ed..77a2ec4105 100644
--- a/src/network/kernel/qhostaddress.h
+++ b/src/network/kernel/qhostaddress.h
@@ -49,8 +49,6 @@
struct sockaddr;
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -142,5 +140,4 @@ Q_NETWORK_EXPORT QDataStream &operator>>(QDataStream &, QHostAddress &);
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QHOSTADDRESS_H
diff --git a/src/network/kernel/qhostinfo.cpp b/src/network/kernel/qhostinfo.cpp
index 6de83c3754..d25372ece6 100644
--- a/src/network/kernel/qhostinfo.cpp
+++ b/src/network/kernel/qhostinfo.cpp
@@ -164,6 +164,9 @@ int QHostInfo::lookupHost(const QString &name, QObject *receiver,
int id = theIdCounter.fetchAndAddRelaxed(1); // generate unique ID
if (name.isEmpty()) {
+ if (!receiver)
+ return -1;
+
QHostInfo hostInfo(id);
hostInfo.setError(QHostInfo::HostNotFound);
hostInfo.setErrorString(QCoreApplication::translate("QHostInfo", "No host name given"));
@@ -183,6 +186,9 @@ int QHostInfo::lookupHost(const QString &name, QObject *receiver,
bool valid = false;
QHostInfo info = manager->cache.get(name, &valid);
if (valid) {
+ if (!receiver)
+ return -1;
+
info.setLookupId(id);
QHostInfoResult result;
QObject::connect(&result, SIGNAL(resultsReady(QHostInfo)), receiver, member, Qt::QueuedConnection);
@@ -193,7 +199,8 @@ int QHostInfo::lookupHost(const QString &name, QObject *receiver,
// cache is not enabled or it was not in the cache, do normal lookup
QHostInfoRunnable* runnable = new QHostInfoRunnable(name, id);
- QObject::connect(&runnable->resultEmitter, SIGNAL(resultsReady(QHostInfo)), receiver, member, Qt::QueuedConnection);
+ if (receiver)
+ QObject::connect(&runnable->resultEmitter, SIGNAL(resultsReady(QHostInfo)), receiver, member, Qt::QueuedConnection);
manager->scheduleLookup(runnable);
}
return id;
@@ -699,8 +706,8 @@ void Q_AUTOTEST_EXPORT qt_qhostinfo_enable_cache(bool e)
}
// cache for 60 seconds
-// cache 64 items
-QHostInfoCache::QHostInfoCache() : max_age(60), enabled(true), cache(64)
+// cache 128 items
+QHostInfoCache::QHostInfoCache() : max_age(60), enabled(true), cache(128)
{
#ifdef QT_QHOSTINFO_CACHE_DISABLED_BY_DEFAULT
enabled = false;
diff --git a/src/network/kernel/qhostinfo.h b/src/network/kernel/qhostinfo.h
index 89cc5ba26b..38d55def34 100644
--- a/src/network/kernel/qhostinfo.h
+++ b/src/network/kernel/qhostinfo.h
@@ -46,8 +46,6 @@
#include <QtCore/qscopedpointer.h>
#include <QtNetwork/qhostaddress.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -98,6 +96,4 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QHostInfo)
-QT_END_HEADER
-
#endif // QHOSTINFO_H
diff --git a/src/network/kernel/qhostinfo_unix.cpp b/src/network/kernel/qhostinfo_unix.cpp
index 0e147c4877..fac83b922b 100644
--- a/src/network/kernel/qhostinfo_unix.cpp
+++ b/src/network/kernel/qhostinfo_unix.cpp
@@ -323,7 +323,7 @@ QString QHostInfo::localHostName()
QString QHostInfo::localDomainName()
{
-#if !defined(Q_OS_VXWORKS) && !defined(Q_OS_LINUX_ANDROID)
+#if !defined(Q_OS_VXWORKS) && !defined(Q_OS_ANDROID)
resolveLibrary();
if (local_res_ninit) {
// using thread-safe version
diff --git a/src/network/kernel/qnetworkfunctions_wince.h b/src/network/kernel/qnetworkfunctions_wince.h
index 858600bcca..ccf1ed9e38 100644
--- a/src/network/kernel/qnetworkfunctions_wince.h
+++ b/src/network/kernel/qnetworkfunctions_wince.h
@@ -50,8 +50,6 @@
#include <qt_windows.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
DECLARE_HANDLE(SC_HANDLE);
@@ -96,7 +94,5 @@ typedef LPENUM_SERVICE_STATUS_PROCESSA LPENUM_SERVICE_STATUS_PROCESS;
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // Q_OS_WINCE
#endif // QNETWORKFUNCTIONS_WINCE_H
diff --git a/src/network/kernel/qnetworkinterface.h b/src/network/kernel/qnetworkinterface.h
index 9ecc371b54..53d5d6e664 100644
--- a/src/network/kernel/qnetworkinterface.h
+++ b/src/network/kernel/qnetworkinterface.h
@@ -48,8 +48,6 @@
#ifndef QT_NO_NETWORKINTERFACE
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -100,7 +98,7 @@ public:
CanMulticast = 0x20
};
Q_DECLARE_FLAGS(InterfaceFlags, InterfaceFlag)
-
+
QNetworkInterface();
QNetworkInterface(const QNetworkInterface &other);
QNetworkInterface &operator=(const QNetworkInterface &other);
@@ -137,8 +135,6 @@ Q_NETWORK_EXPORT QDebug operator<<(QDebug debug, const QNetworkInterface &networ
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_NETWORKINTERFACE
#endif
diff --git a/src/network/kernel/qnetworkinterface_unix.cpp b/src/network/kernel/qnetworkinterface_unix.cpp
index 46eeb46f98..0ec9554c82 100644
--- a/src/network/kernel/qnetworkinterface_unix.cpp
+++ b/src/network/kernel/qnetworkinterface_unix.cpp
@@ -61,7 +61,7 @@
# define QT_NO_GETIFADDRS
#endif
-#ifdef Q_OS_LINUX_ANDROID
+#ifdef Q_OS_ANDROID
// android lacks if_nameindex
# define QT_NO_IPV6IFNAME
#endif
@@ -328,9 +328,9 @@ static QList<QNetworkInterfacePrivate *> createInterfaces(ifaddrs *rawList)
}
break;
}
- if ( if_it != interfaces.end() )
+ if ( if_it != interfaces.end() )
continue;
-
+
QNetworkInterfacePrivate *iface = new QNetworkInterfacePrivate;
interfaces << iface;
iface->index = ifindex;
diff --git a/src/network/kernel/qnetworkinterface_win.cpp b/src/network/kernel/qnetworkinterface_win.cpp
index 0a2deb8711..02c0801cef 100644
--- a/src/network/kernel/qnetworkinterface_win.cpp
+++ b/src/network/kernel/qnetworkinterface_win.cpp
@@ -109,7 +109,7 @@ static QHash<QHostAddress, QHostAddress> ipv4Netmasks()
IP_ADAPTER_INFO staticBuf[2]; // 2 is arbitrary
PIP_ADAPTER_INFO pAdapter = staticBuf;
ULONG bufSize = sizeof staticBuf;
- QHash<QHostAddress, QHostAddress> ipv4netmasks;
+ QHash<QHostAddress, QHostAddress> ipv4netmasks;
DWORD retval = ptrGetAdaptersInfo(pAdapter, &bufSize);
if (retval == ERROR_BUFFER_OVERFLOW) {
diff --git a/src/network/kernel/qnetworkinterface_win_p.h b/src/network/kernel/qnetworkinterface_win_p.h
index 34f4e18d5e..d6a3366316 100644
--- a/src/network/kernel/qnetworkinterface_win_p.h
+++ b/src/network/kernel/qnetworkinterface_win_p.h
@@ -112,19 +112,19 @@ typedef struct {
// copied from MSDN online help
typedef enum {
- IpPrefixOriginOther = 0,
- IpPrefixOriginManual,
- IpPrefixOriginWellKnown,
- IpPrefixOriginDhcp,
+ IpPrefixOriginOther = 0,
+ IpPrefixOriginManual,
+ IpPrefixOriginWellKnown,
+ IpPrefixOriginDhcp,
IpPrefixOriginRouterAdvertisement
} IP_PREFIX_ORIGIN;
typedef enum {
- IpSuffixOriginOther = 0,
- IpSuffixOriginManual,
- IpSuffixOriginWellKnown,
- IpSuffixOriginDhcp,
- IpSuffixOriginLinkLayerAddress,
+ IpSuffixOriginOther = 0,
+ IpSuffixOriginManual,
+ IpSuffixOriginWellKnown,
+ IpSuffixOriginDhcp,
+ IpSuffixOriginLinkLayerAddress,
IpSuffixOriginRandom
} IP_SUFFIX_ORIGIN;
@@ -164,11 +164,11 @@ typedef struct _IP_ADAPTER_UNICAST_ADDRESS {
ULONG LeaseLifetime;
} IP_ADAPTER_UNICAST_ADDRESS, *PIP_ADAPTER_UNICAST_ADDRESS;
-typedef struct _IP_ADAPTER_ANYCAST_ADDRESS
+typedef struct _IP_ADAPTER_ANYCAST_ADDRESS
IP_ADAPTER_ANYCAST_ADDRESS, *PIP_ADAPTER_ANYCAST_ADDRESS;
-typedef struct _IP_ADAPTER_MULTICAST_ADDRESS
- IP_ADAPTER_MULTICAST_ADDRESS,
+typedef struct _IP_ADAPTER_MULTICAST_ADDRESS
+ IP_ADAPTER_MULTICAST_ADDRESS,
*PIP_ADAPTER_MULTICAST_ADDRESS;
typedef struct _IP_ADAPTER_DNS_SERVER_ADDRESS
@@ -186,7 +186,7 @@ typedef struct _IP_ADAPTER_PREFIX {
struct _IP_ADAPTER_PREFIX* Next;
SOCKET_ADDRESS Address;
ULONG PrefixLength;
-} IP_ADAPTER_PREFIX,
+} IP_ADAPTER_PREFIX,
*PIP_ADAPTER_PREFIX;
typedef struct _IP_ADAPTER_ADDRESSES {
@@ -215,7 +215,7 @@ typedef struct _IP_ADAPTER_ADDRESSES {
DWORD Ipv6IfIndex;
DWORD ZoneIndices[16];
PIP_ADAPTER_PREFIX FirstPrefix;
-} IP_ADAPTER_ADDRESSES,
+} IP_ADAPTER_ADDRESSES,
*PIP_ADAPTER_ADDRESSES;
typedef struct {
@@ -227,7 +227,7 @@ typedef struct _IP_ADDR_STRING {
IP_ADDRESS_STRING IpAddress;
IP_MASK_STRING IpMask;
DWORD Context;
-} IP_ADDR_STRING,
+} IP_ADDR_STRING,
*PIP_ADDR_STRING;
typedef struct _IP_ADAPTER_INFO {
@@ -249,7 +249,7 @@ typedef struct _IP_ADAPTER_INFO {
IP_ADDR_STRING SecondaryWinsServer;
time_t LeaseObtained;
time_t LeaseExpires;
-} IP_ADAPTER_INFO,
+} IP_ADAPTER_INFO,
*PIP_ADAPTER_INFO;
typedef struct {
diff --git a/src/network/kernel/qnetworkproxy.cpp b/src/network/kernel/qnetworkproxy.cpp
index 54229295bb..a38655d244 100644
--- a/src/network/kernel/qnetworkproxy.cpp
+++ b/src/network/kernel/qnetworkproxy.cpp
@@ -1562,7 +1562,7 @@ void QNetworkProxyFactory::setApplicationProxyFactory(QNetworkProxyFactory *fact
\li On Windows platforms, this function may take several seconds to
execute depending on the configuration of the user's system.
- \li On BlackBerry, only UrlRequest queries are supported. SOCKS is
+ \li On BlackBerry, only UrlRequest and TcpSocket queries are supported. SOCKS is
not supported. The proxy credentials are only retrieved for the
default configuration.
\endlist
diff --git a/src/network/kernel/qnetworkproxy.h b/src/network/kernel/qnetworkproxy.h
index 081a993e33..153c84028a 100644
--- a/src/network/kernel/qnetworkproxy.h
+++ b/src/network/kernel/qnetworkproxy.h
@@ -48,8 +48,6 @@
#ifndef QT_NO_NETWORKPROXY
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -220,8 +218,6 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QNetworkProxy)
-QT_END_HEADER
-
#endif // QT_NO_NETWORKPROXY
#endif // QHOSTINFO_H
diff --git a/src/network/kernel/qnetworkproxy_blackberry.cpp b/src/network/kernel/qnetworkproxy_blackberry.cpp
index 2743b90404..c0f5c43a78 100644
--- a/src/network/kernel/qnetworkproxy_blackberry.cpp
+++ b/src/network/kernel/qnetworkproxy_blackberry.cpp
@@ -63,14 +63,36 @@ QT_BEGIN_NAMESPACE
QList<QNetworkProxy> QNetworkProxyFactory::systemProxyForQuery(const QNetworkProxyQuery &query)
{
- QNetworkProxy proxy;
+ if (query.url().scheme() == QLatin1String("file")
+ || query.url().scheme() == QLatin1String("qrc"))
+ return QList<QNetworkProxy>() << QNetworkProxy(QNetworkProxy::NoProxy);
- if (query.queryType() != QNetworkProxyQuery::UrlRequest) {
+ if (query.queryType() != QNetworkProxyQuery::UrlRequest
+ && query.queryType() != QNetworkProxyQuery::TcpSocket) {
qWarning("Unsupported query type: %d", query.queryType());
return QList<QNetworkProxy>() << QNetworkProxy(QNetworkProxy::NoProxy);
}
- QUrl url = query.url();
+ QUrl url;
+ if (query.queryType() == QNetworkProxyQuery::UrlRequest) {
+ url = query.url();
+ } else if (query.queryType() == QNetworkProxyQuery::TcpSocket
+ && !query.peerHostName().isEmpty()) {
+ url.setHost(query.peerHostName());
+ switch (query.peerPort()) {
+ case 443:
+ url.setScheme(QStringLiteral("https"));
+ break;
+ case 21:
+ url.setScheme(QStringLiteral("ftp"));
+ break;
+ default:
+ // for unknown ports, we just pretend we are dealing
+ // with a HTTP URL, otherwise we will not get a proxy
+ // from the netstatus API
+ url.setScheme(QStringLiteral("http"));
+ }
+ }
if (!url.isValid()) {
qWarning("Invalid URL: %s", qPrintable(url.toString()));
@@ -112,6 +134,8 @@ QList<QNetworkProxy> QNetworkProxyFactory::systemProxyForQuery(const QNetworkPro
return QList<QNetworkProxy>() << QNetworkProxy(QNetworkProxy::NoProxy);
}
+ QNetworkProxy proxy;
+
QString protocol = query.protocolTag();
if (protocol.startsWith(QLatin1String("http"), Qt::CaseInsensitive)) { // http, https
proxy.setType((QNetworkProxy::HttpProxy));
diff --git a/src/network/kernel/qnetworkproxy_mac.cpp b/src/network/kernel/qnetworkproxy_mac.cpp
index a283b7ee05..4a4acb59d4 100644
--- a/src/network/kernel/qnetworkproxy_mac.cpp
+++ b/src/network/kernel/qnetworkproxy_mac.cpp
@@ -231,7 +231,6 @@ QList<QNetworkProxy> macQueryInternal(const QNetworkProxyQuery &query)
// PAC is enabled
CFStringRef cfPacLocation = (CFStringRef)CFDictionaryGetValue(dict, kSCPropNetProxiesProxyAutoConfigURLString);
-#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_5) {
QCFType<CFDataRef> pacData;
QCFType<CFURLRef> pacUrl = CFURLCreateWithString(kCFAllocatorDefault, cfPacLocation, NULL);
@@ -275,9 +274,7 @@ QList<QNetworkProxy> macQueryInternal(const QNetworkProxyQuery &query)
result << proxyFromDictionary(proxy);
}
return result;
- } else
-#endif
- {
+ } else {
QString pacLocation = QCFString::toQString(cfPacLocation);
qWarning("Mac system proxy: PAC script at \"%s\" not handled", qPrintable(pacLocation));
}
diff --git a/src/network/kernel/qurlinfo_p.h b/src/network/kernel/qurlinfo_p.h
index 955a2eb325..1aa59f25ad 100644
--- a/src/network/kernel/qurlinfo_p.h
+++ b/src/network/kernel/qurlinfo_p.h
@@ -46,8 +46,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qiodevice.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -125,6 +123,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QURLINFO_H
diff --git a/src/network/socket/qabstractsocket.cpp b/src/network/socket/qabstractsocket.cpp
index c19238d768..71d6166840 100644
--- a/src/network/socket/qabstractsocket.cpp
+++ b/src/network/socket/qabstractsocket.cpp
@@ -643,7 +643,7 @@ bool QAbstractSocketPrivate::initSocketLayer(QAbstractSocket::NetworkLayerProtoc
return false;
}
- if (threadData->eventDispatcher)
+ if (threadData->hasEventDispatcher())
socketEngine->setReceiver(this);
#if defined (QABSTRACTSOCKET_DEBUG)
@@ -1134,7 +1134,7 @@ void QAbstractSocketPrivate::_q_connectToNextAddress()
}
// Start the connect timer.
- if (threadData->eventDispatcher) {
+ if (threadData->hasEventDispatcher()) {
if (!connectTimer) {
connectTimer = new QTimer(q);
QObject::connect(connectTimer, SIGNAL(timeout()),
@@ -1159,7 +1159,7 @@ void QAbstractSocketPrivate::_q_connectToNextAddress()
void QAbstractSocketPrivate::_q_testConnection()
{
if (socketEngine) {
- if (threadData->eventDispatcher) {
+ if (threadData->hasEventDispatcher()) {
if (connectTimer)
connectTimer->stop();
}
@@ -1180,7 +1180,7 @@ void QAbstractSocketPrivate::_q_testConnection()
addresses.clear();
}
- if (threadData->eventDispatcher) {
+ if (threadData->hasEventDispatcher()) {
if (connectTimer)
connectTimer->stop();
}
@@ -1640,7 +1640,7 @@ void QAbstractSocket::connectToHost(const QString &hostName, quint16 port,
return;
#endif
} else {
- if (d->threadData->eventDispatcher) {
+ if (d->threadData->hasEventDispatcher()) {
// this internal API for QHostInfo either immediately gives us the desired
// QHostInfo from cache or later calls the _q_startConnecting slot.
bool immediateResultValid = false;
@@ -1846,7 +1846,7 @@ bool QAbstractSocket::setSocketDescriptor(qintptr socketDescriptor, SocketState
return false;
}
- if (d->threadData->eventDispatcher)
+ if (d->threadData->hasEventDispatcher())
d->socketEngine->setReceiver(d);
QIODevice::open(openMode);
diff --git a/src/network/socket/qabstractsocket.h b/src/network/socket/qabstractsocket.h
index b7e3f2853a..46114abf73 100644
--- a/src/network/socket/qabstractsocket.h
+++ b/src/network/socket/qabstractsocket.h
@@ -48,8 +48,6 @@
#include <QtCore/qdebug.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -242,6 +240,4 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QAbstractSocket::SocketState)
Q_DECLARE_METATYPE(QAbstractSocket::SocketError)
-QT_END_HEADER
-
#endif // QABSTRACTSOCKET_H
diff --git a/src/network/socket/qlocalserver.h b/src/network/socket/qlocalserver.h
index d7d6b16e10..b5791db653 100644
--- a/src/network/socket/qlocalserver.h
+++ b/src/network/socket/qlocalserver.h
@@ -44,8 +44,6 @@
#include <QtNetwork/qabstractsocket.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -109,7 +107,5 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QLocalServer::SocketOptions)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLOCALSERVER_H
diff --git a/src/network/socket/qlocalserver_unix.cpp b/src/network/socket/qlocalserver_unix.cpp
index 2bcf1ac83e..51a33a4b35 100644
--- a/src/network/socket/qlocalserver_unix.cpp
+++ b/src/network/socket/qlocalserver_unix.cpp
@@ -297,9 +297,9 @@ void QLocalServerPrivate::waitForNewConnection(int msec, bool *timedOut)
FD_ZERO(&readfds);
FD_SET(listenSocket, &readfds);
- timeval timeout;
+ struct timespec timeout;
timeout.tv_sec = msec / 1000;
- timeout.tv_usec = (msec % 1000) * 1000;
+ timeout.tv_nsec = (msec % 1000) * 1000 * 1000;
int result = -1;
result = qt_safe_select(listenSocket + 1, &readfds, 0, 0, (msec == -1) ? 0 : &timeout);
diff --git a/src/network/socket/qlocalsocket.cpp b/src/network/socket/qlocalsocket.cpp
index bd2c4258b5..1ce6568364 100644
--- a/src/network/socket/qlocalsocket.cpp
+++ b/src/network/socket/qlocalsocket.cpp
@@ -71,18 +71,17 @@ QT_BEGIN_NAMESPACE
*/
/*!
- \fn void QLocalSocket::connectToServer(const QString &name, OpenMode openMode)
+ \fn void QLocalSocket::open(OpenMode openMode)
- Attempts to make a connection to \a name.
+ Equivalent to connectToServer(OpenMode mode).
+ The socket is opened in the given \a openMode to the server defined by setServerName().
- The socket is opened in the given \a openMode and first enters ConnectingState.
- It then attempts to connect to the address or addresses returned by the lookup.
- Finally, if a connection is established, QLocalSocket enters ConnectedState
- and emits connected().
-
- At any point, the socket can emit error() to signal that an error occurred.
+ Note that unlike in most other QIODevice subclasses, open() may not open the device directly.
+ The function return false if the socket was already connected or if the server to connect
+ to was not defined and true in any other case. The connected() or error() signals will be
+ emitted once the device is actualy open (or the connection failed).
- See also state(), serverName(), and waitForConnected().
+ See connectToServer() for more details.
*/
/*!
@@ -354,8 +353,62 @@ QLocalSocket::~QLocalSocket()
}
/*!
- Returns the name of the peer as specified by connectToServer(), or an
- empty QString if connectToServer() has not been called or it failed.
+ \since 5.1
+
+ Attempts to make a connection to serverName().
+ setServerName() must be called before you open the connection.
+ Alternatively you can use connectToServer(const QString &name, OpenMode openMode);
+
+ The socket is opened in the given \a openMode and first enters ConnectingState.
+ If a connection is established, QLocalSocket enters ConnectedState and emits connected().
+
+ After calling this function, the socket can emit error() to signal that an error occurred.
+
+ \sa state(), serverName(), waitForConnected()
+*/
+void QLocalSocket::connectToServer(OpenMode openMode)
+{
+ open(openMode);
+}
+
+/*! \overload
+
+ Set the server \a name and attempts to make a connection to it.
+
+ The socket is opened in the given \a openMode and first enters ConnectingState.
+ If a connection is established, QLocalSocket enters ConnectedState and emits connected().
+
+ After calling this function, the socket can emit error() to signal that an error occurred.
+
+ \sa state(), serverName(), waitForConnected()
+*/
+void QLocalSocket::connectToServer(const QString &name, OpenMode openMode)
+{
+ setServerName(name);
+ open(openMode);
+}
+
+/*!
+ \since 5.1
+
+ Set the \a name of the peer to connect to.
+ On Windows name is the name of a named pipe; on Unix name is the name of a local domain socket.
+
+ This function must be called when the socket is not connected.
+*/
+void QLocalSocket::setServerName(const QString & name)
+{
+ Q_D(QLocalSocket);
+ if (d->state != UnconnectedState) {
+ qWarning("QLocalSocket::setServerName() called while not in unconnected state");
+ return;
+ }
+ d->serverName = name;
+}
+
+/*!
+ Returns the name of the peer as specified by setServerName(), or an
+ empty QString if setServerName() has not been called or connectToServer() failed.
\sa connectToServer(), fullServerName()
diff --git a/src/network/socket/qlocalsocket.h b/src/network/socket/qlocalsocket.h
index e1ee174608..427dab1def 100644
--- a/src/network/socket/qlocalsocket.h
+++ b/src/network/socket/qlocalsocket.h
@@ -45,8 +45,6 @@
#include <QtCore/qiodevice.h>
#include <QtNetwork/qabstractsocket.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -86,9 +84,11 @@ public:
QLocalSocket(QObject *parent = 0);
~QLocalSocket();
+ void connectToServer(OpenMode openMode = ReadWrite);
void connectToServer(const QString &name, OpenMode openMode = ReadWrite);
void disconnectFromServer();
+ void setServerName(const QString &name);
QString serverName() const;
QString fullServerName() const;
@@ -97,6 +97,7 @@ public:
virtual qint64 bytesAvailable() const;
virtual qint64 bytesToWrite() const;
virtual bool canReadLine() const;
+ virtual bool open(OpenMode openMode = ReadWrite) Q_DECL_OVERRIDE;
virtual void close();
LocalSocketError error() const;
bool flush();
@@ -152,6 +153,4 @@ Q_NETWORK_EXPORT QDebug operator<<(QDebug, QLocalSocket::LocalSocketState);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLOCALSOCKET_H
diff --git a/src/network/socket/qlocalsocket_tcp.cpp b/src/network/socket/qlocalsocket_tcp.cpp
index cbae8d58ff..edde5a4687 100644
--- a/src/network/socket/qlocalsocket_tcp.cpp
+++ b/src/network/socket/qlocalsocket_tcp.cpp
@@ -214,29 +214,30 @@ void QLocalSocketPrivate::errorOccurred(QLocalSocket::LocalSocketError error, co
q->emit stateChanged(state);
}
-void QLocalSocket::connectToServer(const QString &name, OpenMode openMode)
+bool QLocalSocket::open(OpenMode openMode)
{
Q_D(QLocalSocket);
- if (state() == ConnectedState
- || state() == ConnectingState)
- return;
+ if (state() == ConnectedState || state() == ConnectingState) {
+ setErrorString(tr("Trying to connect while connection is in progress"));
+ emit error(QLocalSocket::OperationError);
+ return false;
+ }
d->errorString.clear();
d->state = ConnectingState;
emit stateChanged(d->state);
- if (name.isEmpty()) {
+ if (d->serverName.isEmpty()) {
d->errorOccurred(ServerNotFoundError,
QLatin1String("QLocalSocket::connectToServer"));
- return;
+ return false;
}
- d->serverName = name;
const QLatin1String prefix("QLocalServer/");
if (name.startsWith(prefix))
- d->fullServerName = name;
+ d->fullServerName = d->serverName;
else
- d->fullServerName = prefix + name;
+ d->fullServerName = prefix + d->serverName;
QSettings settings(QLatin1String("QtProject"), QLatin1String("Qt"));
bool ok;
@@ -244,10 +245,11 @@ void QLocalSocket::connectToServer(const QString &name, OpenMode openMode)
if (!ok) {
d->errorOccurred(ServerNotFoundError,
QLatin1String("QLocalSocket::connectToServer"));
- return;
+ return false;
}
d->tcpSocket->connectToHost(QHostAddress::LocalHost, port, openMode);
QIODevice::open(openMode);
+ return true;
}
bool QLocalSocket::setSocketDescriptor(qintptr socketDescriptor,
diff --git a/src/network/socket/qlocalsocket_unix.cpp b/src/network/socket/qlocalsocket_unix.cpp
index e846e43e73..67182e57b0 100644
--- a/src/network/socket/qlocalsocket_unix.cpp
+++ b/src/network/socket/qlocalsocket_unix.cpp
@@ -221,14 +221,14 @@ void QLocalSocketPrivate::errorOccurred(QLocalSocket::LocalSocketError error, co
q->emit stateChanged(state);
}
-void QLocalSocket::connectToServer(const QString &name, OpenMode openMode)
+bool QLocalSocket::open(OpenMode openMode)
{
Q_D(QLocalSocket);
if (state() == ConnectedState || state() == ConnectingState) {
QString errorString = d->generateErrorString(QLocalSocket::OperationError, QLatin1String("QLocalSocket::connectToserver"));
setErrorString(errorString);
emit error(QLocalSocket::OperationError);
- return;
+ return false;
}
d->errorString.clear();
@@ -236,17 +236,17 @@ void QLocalSocket::connectToServer(const QString &name, OpenMode openMode)
d->state = ConnectingState;
emit stateChanged(d->state);
- if (name.isEmpty()) {
+ if (d->serverName.isEmpty()) {
d->errorOccurred(ServerNotFoundError,
QLatin1String("QLocalSocket::connectToServer"));
- return;
+ return false;
}
// create the socket
if (-1 == (d->connectingSocket = qt_safe_socket(PF_UNIX, SOCK_STREAM, 0))) {
d->errorOccurred(UnsupportedSocketOperationError,
QLatin1String("QLocalSocket::connectToServer"));
- return;
+ return false;
}
// set non blocking so we can try to connect and it won't wait
int flags = fcntl(d->connectingSocket, F_GETFL, 0);
@@ -254,13 +254,14 @@ void QLocalSocket::connectToServer(const QString &name, OpenMode openMode)
|| -1 == (fcntl(d->connectingSocket, F_SETFL, flags | O_NONBLOCK))) {
d->errorOccurred(UnknownSocketError,
QLatin1String("QLocalSocket::connectToServer"));
- return;
+ return false;
}
// _q_connectToSocket does the actual connecting
- d->connectingName = name;
+ d->connectingName = d->serverName;
d->connectingOpenMode = openMode;
d->_q_connectToSocket();
+ return true;
}
/*!
diff --git a/src/network/socket/qlocalsocket_win.cpp b/src/network/socket/qlocalsocket_win.cpp
index 660e0901f8..cdfa18377d 100644
--- a/src/network/socket/qlocalsocket_win.cpp
+++ b/src/network/socket/qlocalsocket_win.cpp
@@ -128,33 +128,33 @@ void QLocalSocketPrivate::destroyPipeHandles()
}
}
-void QLocalSocket::connectToServer(const QString &name, OpenMode openMode)
+bool QLocalSocket::open(OpenMode openMode)
{
Q_D(QLocalSocket);
if (state() == ConnectedState || state() == ConnectingState) {
setErrorString(tr("Trying to connect while connection is in progress"));
emit error(QLocalSocket::OperationError);
- return;
+ return false;
}
d->error = QLocalSocket::UnknownSocketError;
d->errorString = QString();
d->state = ConnectingState;
emit stateChanged(d->state);
- if (name.isEmpty()) {
+ if (d->serverName.isEmpty()) {
d->error = QLocalSocket::ServerNotFoundError;
setErrorString(QLocalSocket::tr("%1: Invalid name").arg(QLatin1String("QLocalSocket::connectToServer")));
d->state = UnconnectedState;
emit error(d->error);
emit stateChanged(d->state);
- return;
+ return false;
}
QString pipePath = QLatin1String("\\\\.\\pipe\\");
- if (name.startsWith(pipePath))
- d->fullServerName = name;
+ if (d->serverName.startsWith(pipePath))
+ d->fullServerName = d->serverName;
else
- d->fullServerName = pipePath + name;
+ d->fullServerName = pipePath + d->serverName;
// Try to open a named pipe
HANDLE localSocket;
forever {
@@ -184,15 +184,15 @@ void QLocalSocket::connectToServer(const QString &name, OpenMode openMode)
if (localSocket == INVALID_HANDLE_VALUE) {
d->setErrorString(QLatin1String("QLocalSocket::connectToServer"));
d->fullServerName = QString();
- return;
+ return false;
}
// we have a valid handle
- d->serverName = name;
if (setSocketDescriptor((qintptr)localSocket, ConnectedState, openMode)) {
d->handle = localSocket;
emit connected();
}
+ return true;
}
// This is reading from the buffer
diff --git a/src/network/socket/qnativesocketengine.cpp b/src/network/socket/qnativesocketengine.cpp
index 6dbc25db4c..536bc63ed0 100644
--- a/src/network/socket/qnativesocketengine.cpp
+++ b/src/network/socket/qnativesocketengine.cpp
@@ -623,8 +623,8 @@ int QNativeSocketEngine::accept()
{
Q_D(QNativeSocketEngine);
Q_CHECK_VALID_SOCKETLAYER(QNativeSocketEngine::accept(), -1);
- Q_CHECK_STATE(QNativeSocketEngine::accept(), QAbstractSocket::ListeningState, false);
- Q_CHECK_TYPE(QNativeSocketEngine::accept(), QAbstractSocket::TcpSocket, false);
+ Q_CHECK_STATE(QNativeSocketEngine::accept(), QAbstractSocket::ListeningState, -1);
+ Q_CHECK_TYPE(QNativeSocketEngine::accept(), QAbstractSocket::TcpSocket, -1);
return d->nativeAccept();
}
@@ -702,7 +702,7 @@ qint64 QNativeSocketEngine::bytesAvailable() const
{
Q_D(const QNativeSocketEngine);
Q_CHECK_VALID_SOCKETLAYER(QNativeSocketEngine::bytesAvailable(), -1);
- Q_CHECK_NOT_STATE(QNativeSocketEngine::bytesAvailable(), QAbstractSocket::UnconnectedState, false);
+ Q_CHECK_NOT_STATE(QNativeSocketEngine::bytesAvailable(), QAbstractSocket::UnconnectedState, -1);
return d->nativeBytesAvailable();
}
@@ -732,7 +732,7 @@ qint64 QNativeSocketEngine::pendingDatagramSize() const
{
Q_D(const QNativeSocketEngine);
Q_CHECK_VALID_SOCKETLAYER(QNativeSocketEngine::pendingDatagramSize(), -1);
- Q_CHECK_TYPE(QNativeSocketEngine::pendingDatagramSize(), QAbstractSocket::UdpSocket, false);
+ Q_CHECK_TYPE(QNativeSocketEngine::pendingDatagramSize(), QAbstractSocket::UdpSocket, -1);
return d->nativePendingDatagramSize();
}
@@ -757,7 +757,7 @@ qint64 QNativeSocketEngine::readDatagram(char *data, qint64 maxSize, QHostAddres
{
Q_D(QNativeSocketEngine);
Q_CHECK_VALID_SOCKETLAYER(QNativeSocketEngine::readDatagram(), -1);
- Q_CHECK_TYPE(QNativeSocketEngine::readDatagram(), QAbstractSocket::UdpSocket, false);
+ Q_CHECK_TYPE(QNativeSocketEngine::readDatagram(), QAbstractSocket::UdpSocket, -1);
return d->nativeReceiveDatagram(data, maxSize, address, port);
}
@@ -1214,7 +1214,7 @@ void QNativeSocketEngine::setReadNotificationEnabled(bool enable)
Q_D(QNativeSocketEngine);
if (d->readNotifier) {
d->readNotifier->setEnabled(enable);
- } else if (enable && d->threadData->eventDispatcher) {
+ } else if (enable && d->threadData->hasEventDispatcher()) {
d->readNotifier = new QReadNotifier(d->socketDescriptor, this);
d->readNotifier->setEnabled(true);
}
@@ -1231,7 +1231,7 @@ void QNativeSocketEngine::setWriteNotificationEnabled(bool enable)
Q_D(QNativeSocketEngine);
if (d->writeNotifier) {
d->writeNotifier->setEnabled(enable);
- } else if (enable && d->threadData->eventDispatcher) {
+ } else if (enable && d->threadData->hasEventDispatcher()) {
d->writeNotifier = new QWriteNotifier(d->socketDescriptor, this);
d->writeNotifier->setEnabled(true);
}
@@ -1248,7 +1248,7 @@ void QNativeSocketEngine::setExceptionNotificationEnabled(bool enable)
Q_D(QNativeSocketEngine);
if (d->exceptNotifier) {
d->exceptNotifier->setEnabled(enable);
- } else if (enable && d->threadData->eventDispatcher) {
+ } else if (enable && d->threadData->hasEventDispatcher()) {
d->exceptNotifier = new QExceptionNotifier(d->socketDescriptor, this);
d->exceptNotifier->setEnabled(true);
}
diff --git a/src/network/socket/qnativesocketengine_unix.cpp b/src/network/socket/qnativesocketengine_unix.cpp
index 4f3408b067..4c94c4dbb9 100644
--- a/src/network/socket/qnativesocketengine_unix.cpp
+++ b/src/network/socket/qnativesocketengine_unix.cpp
@@ -1126,9 +1126,9 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout, bool selectForRead) co
FD_ZERO(&fds);
FD_SET(socketDescriptor, &fds);
- struct timeval tv;
+ struct timespec tv;
tv.tv_sec = timeout / 1000;
- tv.tv_usec = (timeout % 1000) * 1000;
+ tv.tv_nsec = (timeout % 1000) * 1000 * 1000;
int retval;
if (selectForRead)
@@ -1152,9 +1152,9 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout, bool checkRead, bool c
if (checkWrite)
FD_SET(socketDescriptor, &fdwrite);
- struct timeval tv;
+ struct timespec tv;
tv.tv_sec = timeout / 1000;
- tv.tv_usec = (timeout % 1000) * 1000;
+ tv.tv_nsec = (timeout % 1000) * 1000 * 1000;
int ret;
ret = qt_safe_select(socketDescriptor + 1, &fdread, &fdwrite, 0, timeout < 0 ? 0 : &tv);
diff --git a/src/network/socket/qnativesocketengine_win.cpp b/src/network/socket/qnativesocketengine_win.cpp
index a135abd5e3..3027b77161 100644
--- a/src/network/socket/qnativesocketengine_win.cpp
+++ b/src/network/socket/qnativesocketengine_win.cpp
@@ -1450,7 +1450,7 @@ int QNativeSocketEnginePrivate::nativeSelect(int timeout, bool selectForRead) co
bool readEnabled = selectForRead && readNotifier && readNotifier->isEnabled();
if (readEnabled)
readNotifier->setEnabled(false);
-
+
fd_set fds;
int ret = 0;
diff --git a/src/network/socket/qtcpserver.h b/src/network/socket/qtcpserver.h
index dfabfa1be7..8e25aa5a29 100644
--- a/src/network/socket/qtcpserver.h
+++ b/src/network/socket/qtcpserver.h
@@ -46,8 +46,6 @@
#include <QtNetwork/qabstractsocket.h>
#include <QtNetwork/qhostaddress.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -108,6 +106,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTCPSERVER_H
diff --git a/src/network/socket/qtcpsocket.cpp b/src/network/socket/qtcpsocket.cpp
index fb5d46a9f7..ce37401a89 100644
--- a/src/network/socket/qtcpsocket.cpp
+++ b/src/network/socket/qtcpsocket.cpp
@@ -41,7 +41,7 @@
//#define QTCPSOCKET_DEBUG
-/*!
+/*!
\class QTcpSocket
\brief The QTcpSocket class provides a TCP socket.
diff --git a/src/network/socket/qtcpsocket.h b/src/network/socket/qtcpsocket.h
index 44fb68a207..ed5ce4aeed 100644
--- a/src/network/socket/qtcpsocket.h
+++ b/src/network/socket/qtcpsocket.h
@@ -45,8 +45,6 @@
#include <QtNetwork/qabstractsocket.h>
#include <QtCore/qvariant.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -69,6 +67,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTCPSOCKET_H
diff --git a/src/network/socket/qudpsocket.h b/src/network/socket/qudpsocket.h
index 7a064a3432..da6306a430 100644
--- a/src/network/socket/qudpsocket.h
+++ b/src/network/socket/qudpsocket.h
@@ -45,8 +45,6 @@
#include <QtNetwork/qabstractsocket.h>
#include <QtNetwork/qhostaddress.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -90,6 +88,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QUDPSOCKET_H
diff --git a/src/network/ssl/qssl.cpp b/src/network/ssl/qssl.cpp
index 6fcd977759..4e33001d8d 100644
--- a/src/network/ssl/qssl.cpp
+++ b/src/network/ssl/qssl.cpp
@@ -58,7 +58,7 @@ QT_BEGIN_NAMESPACE
\enum QSsl::KeyType
Describes the two types of keys QSslKey supports.
-
+
\value PrivateKey A private key.
\value PublicKey A public key.
*/
diff --git a/src/network/ssl/qssl.h b/src/network/ssl/qssl.h
index 80ccfadecb..06d80965e2 100644
--- a/src/network/ssl/qssl.h
+++ b/src/network/ssl/qssl.h
@@ -46,8 +46,6 @@
#include <QtCore/qglobal.h>
#include <QtCore/QFlags>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -106,6 +104,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QSsl::SslOptions)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSSL_H
diff --git a/src/network/ssl/qsslcertificate.h b/src/network/ssl/qsslcertificate.h
index 23f9638981..988071eb9d 100644
--- a/src/network/ssl/qsslcertificate.h
+++ b/src/network/ssl/qsslcertificate.h
@@ -56,8 +56,6 @@
#include <QtCore/qmap.h>
#include <QtNetwork/qssl.h>
-QT_BEGIN_HEADER
-
#ifndef QT_NO_SSL
QT_BEGIN_NAMESPACE
@@ -164,6 +162,4 @@ Q_DECLARE_METATYPE(QSslCertificate)
#endif // QT_NO_SSL
-QT_END_HEADER
-
#endif
diff --git a/src/network/ssl/qsslcertificateextension.h b/src/network/ssl/qsslcertificateextension.h
index ce7ff54941..080b1ccc4e 100644
--- a/src/network/ssl/qsslcertificateextension.h
+++ b/src/network/ssl/qsslcertificateextension.h
@@ -47,8 +47,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qvariant.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -85,8 +83,6 @@ Q_DECLARE_SHARED(QSslCertificateExtension)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSSLCERTIFICATEEXTENSION_H
diff --git a/src/network/ssl/qsslcipher.cpp b/src/network/ssl/qsslcipher.cpp
index 46131fc1aa..b045d2eba9 100644
--- a/src/network/ssl/qsslcipher.cpp
+++ b/src/network/ssl/qsslcipher.cpp
@@ -194,7 +194,7 @@ QString QSslCipher::keyExchangeMethod() const
{
return d->keyExchangeMethod;
}
-
+
/*!
Returns the cipher's authentication method as a QString.
*/
diff --git a/src/network/ssl/qsslcipher.h b/src/network/ssl/qsslcipher.h
index 93ae15c3f5..e351d7949b 100644
--- a/src/network/ssl/qsslcipher.h
+++ b/src/network/ssl/qsslcipher.h
@@ -47,8 +47,6 @@
#include <QtCore/qscopedpointer.h>
#include <QtNetwork/qssl.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -97,7 +95,5 @@ Q_NETWORK_EXPORT QDebug operator<<(QDebug debug, const QSslCipher &cipher);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/network/ssl/qsslconfiguration.cpp b/src/network/ssl/qsslconfiguration.cpp
index 0ae67b3c1f..afbd4fac77 100644
--- a/src/network/ssl/qsslconfiguration.cpp
+++ b/src/network/ssl/qsslconfiguration.cpp
@@ -173,7 +173,7 @@ bool QSslConfiguration::operator==(const QSslConfiguration &other) const
return true;
return d->peerCertificate == other.d->peerCertificate &&
d->peerCertificateChain == other.d->peerCertificateChain &&
- d->localCertificate == other.d->localCertificate &&
+ d->localCertificateChain == other.d->localCertificateChain &&
d->privateKey == other.d->privateKey &&
d->sessionCipher == other.d->sessionCipher &&
d->ciphers == other.d->ciphers &&
@@ -212,7 +212,7 @@ bool QSslConfiguration::isNull() const
d->allowRootCertOnDemandLoading == true &&
d->caCertificates.count() == 0 &&
d->ciphers.count() == 0 &&
- d->localCertificate.isNull() &&
+ d->localCertificateChain.isEmpty() &&
d->privateKey.isNull() &&
d->peerCertificate.isNull() &&
d->peerCertificateChain.count() == 0 &&
@@ -313,6 +313,45 @@ void QSslConfiguration::setPeerVerifyDepth(int depth)
}
/*!
+ Returns the certificate chain to be presented to the peer during
+ the SSL handshake process.
+
+ \sa localCertificate()
+ \since 5.1
+*/
+QList<QSslCertificate> QSslConfiguration::localCertificateChain() const
+{
+ return d->localCertificateChain;
+}
+
+/*!
+ Sets the certificate chain to be presented to the peer during the
+ SSL handshake to be \a localChain.
+
+ Setting the certificate chain once the connection has been
+ established has no effect.
+
+ A certificate is the means of identification used in the SSL
+ process. The local certificate is used by the remote end to verify
+ the local user's identity against its list of Certification
+ Authorities. In most cases, such as in HTTP web browsing, only
+ servers identify to the clients, so the client does not send a
+ certificate.
+
+ Unlike QSslConfiguration::setLocalCertificate() this method allows
+ you to specify any intermediate certificates required in order to
+ validate your certificate. The first item in the list must be the
+ leaf certificate.
+
+ \sa localCertificateChain()
+ \since 5.1
+ */
+void QSslConfiguration::setLocalCertificateChain(const QList<QSslCertificate> &localChain)
+{
+ d->localCertificateChain = localChain;
+}
+
+/*!
Returns the certificate to be presented to the peer during the SSL
handshake process.
@@ -320,7 +359,9 @@ void QSslConfiguration::setPeerVerifyDepth(int depth)
*/
QSslCertificate QSslConfiguration::localCertificate() const
{
- return d->localCertificate;
+ if (d->localCertificateChain.isEmpty())
+ return QSslCertificate();
+ return d->localCertificateChain[0];
}
/*!
@@ -341,7 +382,8 @@ QSslCertificate QSslConfiguration::localCertificate() const
*/
void QSslConfiguration::setLocalCertificate(const QSslCertificate &certificate)
{
- d->localCertificate = certificate;
+ d->localCertificateChain = QList<QSslCertificate>();
+ d->localCertificateChain += certificate;
}
/*!
@@ -584,4 +626,10 @@ void QSslConfiguration::setDefaultConfiguration(const QSslConfiguration &configu
QSslConfigurationPrivate::setDefaultConfiguration(configuration);
}
+/*! \internal
+*/
+bool QSslConfigurationPrivate::peerSessionWasShared(const QSslConfiguration &configuration) {
+ return configuration.d->peerSessionShared;
+ }
+
QT_END_NAMESPACE
diff --git a/src/network/ssl/qsslconfiguration.h b/src/network/ssl/qsslconfiguration.h
index ae6e225ce5..0000382ed5 100644
--- a/src/network/ssl/qsslconfiguration.h
+++ b/src/network/ssl/qsslconfiguration.h
@@ -61,8 +61,6 @@
#include <QtNetwork/qsslsocket.h>
#include <QtNetwork/qssl.h>
-QT_BEGIN_HEADER
-
#ifndef QT_NO_SSL
QT_BEGIN_NAMESPACE
@@ -101,6 +99,9 @@ public:
void setPeerVerifyDepth(int depth);
// Certificate & cipher configuration
+ QList<QSslCertificate> localCertificateChain() const;
+ void setLocalCertificateChain(const QList<QSslCertificate> &localChain);
+
QSslCertificate localCertificate() const;
void setLocalCertificate(const QSslCertificate &certificate);
@@ -129,6 +130,8 @@ public:
private:
friend class QSslSocket;
friend class QSslConfigurationPrivate;
+ friend class QSslSocketBackendPrivate;
+ friend class QSslContext;
QSslConfiguration(QSslConfigurationPrivate *dd);
QSharedDataPointer<QSslConfigurationPrivate> d;
};
@@ -141,6 +144,4 @@ Q_DECLARE_METATYPE(QSslConfiguration)
#endif // QT_NO_SSL
-QT_END_HEADER
-
#endif
diff --git a/src/network/ssl/qsslconfiguration_p.h b/src/network/ssl/qsslconfiguration_p.h
index 30f1ed66f9..54b7264d3d 100644
--- a/src/network/ssl/qsslconfiguration_p.h
+++ b/src/network/ssl/qsslconfiguration_p.h
@@ -84,12 +84,14 @@ public:
peerVerifyMode(QSslSocket::AutoVerifyPeer),
peerVerifyDepth(0),
allowRootCertOnDemandLoading(true),
+ peerSessionShared(false),
sslOptions(QSslConfigurationPrivate::defaultSslOptions)
{ }
QSslCertificate peerCertificate;
QList<QSslCertificate> peerCertificateChain;
- QSslCertificate localCertificate;
+
+ QList<QSslCertificate> localCertificateChain;
QSslKey privateKey;
QSslCipher sessionCipher;
@@ -100,6 +102,9 @@ public:
QSslSocket::PeerVerifyMode peerVerifyMode;
int peerVerifyDepth;
bool allowRootCertOnDemandLoading;
+ bool peerSessionShared;
+
+ Q_AUTOTEST_EXPORT static bool peerSessionWasShared(const QSslConfiguration &configuration);
QSsl::SslOptions sslOptions;
diff --git a/src/network/ssl/qsslcontext.cpp b/src/network/ssl/qsslcontext.cpp
new file mode 100644
index 0000000000..22ad42116b
--- /dev/null
+++ b/src/network/ssl/qsslcontext.cpp
@@ -0,0 +1,309 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtNetwork module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+#include <QtNetwork/qsslsocket.h>
+#include <QtCore/qmutex.h>
+
+#include "private/qsslcontext_p.h"
+#include "private/qsslsocket_p.h"
+#include "private/qsslsocket_openssl_p.h"
+#include "private/qsslsocket_openssl_symbols_p.h"
+
+QT_BEGIN_NAMESPACE
+
+// defined in qsslsocket_openssl.cpp:
+extern int q_X509Callback(int ok, X509_STORE_CTX *ctx);
+extern QString getErrorsFromOpenSsl();
+
+QSslContext::QSslContext()
+ : ctx(0),
+ pkey(0),
+ session(0)
+{
+}
+
+QSslContext::~QSslContext()
+{
+ if (ctx)
+ // This will decrement the reference count by 1 and free the context eventually when possible
+ q_SSL_CTX_free(ctx);
+
+ if (pkey)
+ q_EVP_PKEY_free(pkey);
+
+ if (session)
+ q_SSL_SESSION_free(session);
+}
+
+QSslContext* QSslContext::fromConfiguration(QSslSocket::SslMode mode, const QSslConfiguration &configuration, bool allowRootCertOnDemandLoading)
+{
+ QSslContext *sslContext = new QSslContext();
+ sslContext->sslConfiguration = configuration;
+ sslContext->errorCode = QSslError::NoError;
+
+ bool client = (mode == QSslSocket::SslClientMode);
+
+ bool reinitialized = false;
+init_context:
+ switch (sslContext->sslConfiguration.protocol()) {
+ case QSsl::SslV2:
+#ifndef OPENSSL_NO_SSL2
+ sslContext->ctx = q_SSL_CTX_new(client ? q_SSLv2_client_method() : q_SSLv2_server_method());
+#else
+ sslContext->ctx = 0; // SSL 2 not supported by the system, but chosen deliberately -> error
+#endif
+ break;
+ case QSsl::SslV3:
+ sslContext->ctx = q_SSL_CTX_new(client ? q_SSLv3_client_method() : q_SSLv3_server_method());
+ break;
+ case QSsl::SecureProtocols: // SslV2 will be disabled below
+ case QSsl::TlsV1SslV3: // SslV2 will be disabled below
+ case QSsl::AnyProtocol:
+ default:
+ sslContext->ctx = q_SSL_CTX_new(client ? q_SSLv23_client_method() : q_SSLv23_server_method());
+ break;
+ case QSsl::TlsV1_0:
+ sslContext->ctx = q_SSL_CTX_new(client ? q_TLSv1_client_method() : q_TLSv1_server_method());
+ break;
+ case QSsl::TlsV1_1:
+#if OPENSSL_VERSION_NUMBER >= 0x10001000L
+ sslContext->ctx = q_SSL_CTX_new(client ? q_TLSv1_1_client_method() : q_TLSv1_1_server_method());
+#else
+ sslContext->ctx = 0; // TLS 1.1 not supported by the system, but chosen deliberately -> error
+#endif
+ break;
+ case QSsl::TlsV1_2:
+#if OPENSSL_VERSION_NUMBER >= 0x10001000L
+ sslContext->ctx = q_SSL_CTX_new(client ? q_TLSv1_2_client_method() : q_TLSv1_2_server_method());
+#else
+ sslContext->ctx = 0; // TLS 1.2 not supported by the system, but chosen deliberately -> error
+#endif
+ break;
+ }
+ if (!sslContext->ctx) {
+ // After stopping Flash 10 the SSL library looses its ciphers. Try re-adding them
+ // by re-initializing the library.
+ if (!reinitialized) {
+ reinitialized = true;
+ if (q_SSL_library_init() == 1)
+ goto init_context;
+ }
+
+ sslContext->errorStr = QSslSocket::tr("Error creating SSL context (%1)").arg(QSslSocketBackendPrivate::getErrorsFromOpenSsl());
+ sslContext->errorCode = QSslError::UnspecifiedError;
+ return sslContext;
+ }
+
+ // Enable bug workarounds.
+ long options = QSslSocketBackendPrivate::setupOpenSslOptions(configuration.protocol(), configuration.d->sslOptions);
+ q_SSL_CTX_set_options(sslContext->ctx, options);
+
+#if OPENSSL_VERSION_NUMBER >= 0x10000000L
+ // Tell OpenSSL to release memory early
+ // http://www.openssl.org/docs/ssl/SSL_CTX_set_mode.html
+ if (q_SSLeay() >= 0x10000000L)
+ q_SSL_CTX_set_mode(sslContext->ctx, SSL_MODE_RELEASE_BUFFERS);
+#endif
+
+ // Initialize ciphers
+ QByteArray cipherString;
+ int first = true;
+ QList<QSslCipher> ciphers = sslContext->sslConfiguration.ciphers();
+ if (ciphers.isEmpty())
+ ciphers = QSslSocketPrivate::defaultCiphers();
+ foreach (const QSslCipher &cipher, ciphers) {
+ if (first)
+ first = false;
+ else
+ cipherString.append(':');
+ cipherString.append(cipher.name().toLatin1());
+ }
+
+ if (!q_SSL_CTX_set_cipher_list(sslContext->ctx, cipherString.data())) {
+ sslContext->errorStr = QSslSocket::tr("Invalid or empty cipher list (%1)").arg(QSslSocketBackendPrivate::getErrorsFromOpenSsl());
+ sslContext->errorCode = QSslError::UnspecifiedError;
+ return sslContext;
+ }
+
+ // Add all our CAs to this store.
+ QList<QSslCertificate> expiredCerts;
+ foreach (const QSslCertificate &caCertificate, sslContext->sslConfiguration.caCertificates()) {
+ // add expired certs later, so that the
+ // valid ones are used before the expired ones
+ if (caCertificate.expiryDate() < QDateTime::currentDateTime()) {
+ expiredCerts.append(caCertificate);
+ } else {
+ q_X509_STORE_add_cert(sslContext->ctx->cert_store, (X509 *)caCertificate.handle());
+ }
+ }
+
+ // now add the expired certs
+ foreach (const QSslCertificate &caCertificate, expiredCerts) {
+ q_X509_STORE_add_cert(sslContext->ctx->cert_store, reinterpret_cast<X509 *>(caCertificate.handle()));
+ }
+
+ if (QSslSocketPrivate::s_loadRootCertsOnDemand && allowRootCertOnDemandLoading) {
+ // tell OpenSSL the directories where to look up the root certs on demand
+ QList<QByteArray> unixDirs = QSslSocketPrivate::unixRootCertDirectories();
+ for (int a = 0; a < unixDirs.count(); ++a)
+ q_SSL_CTX_load_verify_locations(sslContext->ctx, 0, unixDirs.at(a).constData());
+ }
+
+ // Register a custom callback to get all verification errors.
+ X509_STORE_set_verify_cb_func(sslContext->ctx->cert_store, q_X509Callback);
+
+ if (!sslContext->sslConfiguration.localCertificate().isNull()) {
+ // Require a private key as well.
+ if (sslContext->sslConfiguration.privateKey().isNull()) {
+ sslContext->errorStr = QSslSocket::tr("Cannot provide a certificate with no key, %1").arg(QSslSocketBackendPrivate::getErrorsFromOpenSsl());
+ sslContext->errorCode = QSslError::UnspecifiedError;
+ return sslContext;
+ }
+
+ // Load certificate
+ if (!q_SSL_CTX_use_certificate(sslContext->ctx, (X509 *)sslContext->sslConfiguration.localCertificate().handle())) {
+ sslContext->errorStr = QSslSocket::tr("Error loading local certificate, %1").arg(QSslSocketBackendPrivate::getErrorsFromOpenSsl());
+ sslContext->errorCode = QSslError::UnspecifiedError;
+ return sslContext;
+ }
+
+ if (configuration.d->privateKey.algorithm() == QSsl::Opaque) {
+ sslContext->pkey = reinterpret_cast<EVP_PKEY *>(configuration.d->privateKey.handle());
+ } else {
+ // Load private key
+ sslContext->pkey = q_EVP_PKEY_new();
+ // before we were using EVP_PKEY_assign_R* functions and did not use EVP_PKEY_free.
+ // this lead to a memory leak. Now we use the *_set1_* functions which do not
+ // take ownership of the RSA/DSA key instance because the QSslKey already has ownership.
+ if (configuration.d->privateKey.algorithm() == QSsl::Rsa)
+ q_EVP_PKEY_set1_RSA(sslContext->pkey, reinterpret_cast<RSA *>(configuration.d->privateKey.handle()));
+ else
+ q_EVP_PKEY_set1_DSA(sslContext->pkey, reinterpret_cast<DSA *>(configuration.d->privateKey.handle()));
+ }
+
+ if (!q_SSL_CTX_use_PrivateKey(sslContext->ctx, sslContext->pkey)) {
+ sslContext->errorStr = QSslSocket::tr("Error loading private key, %1").arg(QSslSocketBackendPrivate::getErrorsFromOpenSsl());
+ sslContext->errorCode = QSslError::UnspecifiedError;
+ return sslContext;
+ }
+ if (configuration.d->privateKey.algorithm() == QSsl::Opaque)
+ sslContext->pkey = 0; // Don't free the private key, it belongs to QSslKey
+
+ // Check if the certificate matches the private key.
+ if (!q_SSL_CTX_check_private_key(sslContext->ctx)) {
+ sslContext->errorStr = QSslSocket::tr("Private key does not certify public key, %1").arg(QSslSocketBackendPrivate::getErrorsFromOpenSsl());
+ sslContext->errorCode = QSslError::UnspecifiedError;
+ return sslContext;
+ }
+
+ // If we have any intermediate certificates then we need to add them to our chain
+ bool first = true;
+ foreach (const QSslCertificate &cert, configuration.d->localCertificateChain) {
+ if (first) {
+ first = false;
+ continue;
+ }
+ q_SSL_CTX_ctrl(sslContext->ctx, SSL_CTRL_EXTRA_CHAIN_CERT, 0,
+ q_X509_dup(reinterpret_cast<X509 *>(cert.handle())));
+ }
+ }
+
+ // Initialize peer verification.
+ if (sslContext->sslConfiguration.peerVerifyMode() == QSslSocket::VerifyNone) {
+ q_SSL_CTX_set_verify(sslContext->ctx, SSL_VERIFY_NONE, 0);
+ } else {
+ q_SSL_CTX_set_verify(sslContext->ctx, SSL_VERIFY_PEER, q_X509Callback);
+ }
+
+ // Set verification depth.
+ if (sslContext->sslConfiguration.peerVerifyDepth() != 0)
+ q_SSL_CTX_set_verify_depth(sslContext->ctx, sslContext->sslConfiguration.peerVerifyDepth());
+
+ return sslContext;
+}
+
+// Needs to be deleted by caller
+SSL* QSslContext::createSsl()
+{
+ SSL* ssl = q_SSL_new(ctx);
+ q_SSL_clear(ssl);
+
+ if (session) {
+ // Try to resume the last session we cached
+ if (!q_SSL_set_session(ssl, session)) {
+ qWarning("could not set SSL session");
+ q_SSL_SESSION_free(session);
+ session = 0;
+ }
+ }
+ return ssl;
+}
+
+// We cache exactly one session here
+bool QSslContext::cacheSession(SSL* ssl)
+{
+ // dont cache the same session again
+ if (session && session == q_SSL_get_session(ssl))
+ return true;
+
+ // decrease refcount of currently stored session
+ // (this might happen if there are several concurrent handshakes in flight)
+ if (session)
+ q_SSL_SESSION_free(session);
+
+ // cache the session the caller gave us and increase reference count
+ session = q_SSL_get1_session(ssl);
+ return (session != NULL);
+
+}
+
+QSslError::SslError QSslContext::error() const
+{
+ return errorCode;
+}
+
+QString QSslContext::errorString() const
+{
+ return errorStr;
+}
+
+QT_END_NAMESPACE
diff --git a/src/network/ssl/qsslcontext_p.h b/src/network/ssl/qsslcontext_p.h
new file mode 100644
index 0000000000..c8578d349e
--- /dev/null
+++ b/src/network/ssl/qsslcontext_p.h
@@ -0,0 +1,88 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtNetwork module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+#ifndef QSSLCONTEXT_H
+#define QSSLCONTEXT_H
+
+#include <QtCore/qvariant.h>
+#include <QtNetwork/qsslcertificate.h>
+#include <QtNetwork/qsslconfiguration.h>
+#include <openssl/ssl.h>
+
+QT_BEGIN_NAMESPACE
+
+#ifndef QT_NO_SSL
+
+class QSslContextPrivate;
+
+class QSslContext
+{
+public:
+
+ ~QSslContext();
+
+ static QSslContext* fromConfiguration(QSslSocket::SslMode mode, const QSslConfiguration &configuration,
+ bool allowRootCertOnDemandLoading);
+
+ QSslError::SslError error() const;
+ QString errorString() const;
+
+ SSL* createSsl();
+ bool cacheSession(SSL*); // should be called when handshake completed
+
+protected:
+ QSslContext();
+
+private:
+ SSL_CTX* ctx;
+ EVP_PKEY *pkey;
+ SSL_SESSION *session;
+ QSslError::SslError errorCode;
+ QString errorStr;
+ QSslConfiguration sslConfiguration;
+};
+
+#endif // QT_NO_SSL
+
+QT_END_NAMESPACE
+
+#endif // QSSLCONTEXT_H
diff --git a/src/network/ssl/qsslerror.cpp b/src/network/ssl/qsslerror.cpp
index d151b376d5..bf75d2e610 100644
--- a/src/network/ssl/qsslerror.cpp
+++ b/src/network/ssl/qsslerror.cpp
@@ -61,7 +61,7 @@
\enum QSslError::SslError
Describes all recognized errors that can occur during an SSL handshake.
-
+
\value NoError
\value UnableToGetIssuerCertificate
\value UnableToDecryptCertificateSignature
@@ -108,7 +108,7 @@ public:
};
/*!
- Constructs a QSslError object with no error and default certificate.
+ Constructs a QSslError object with no error and default certificate.
*/
diff --git a/src/network/ssl/qsslerror.h b/src/network/ssl/qsslerror.h
index 847a48cbc1..73549ce648 100644
--- a/src/network/ssl/qsslerror.h
+++ b/src/network/ssl/qsslerror.h
@@ -46,8 +46,6 @@
#include <QtCore/qvariant.h>
#include <QtNetwork/qsslcertificate.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -106,7 +104,7 @@ public:
SslError error() const;
QString errorString() const;
QSslCertificate certificate() const;
-
+
private:
QScopedPointer<QSslErrorPrivate> d;
};
@@ -126,6 +124,4 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QList<QSslError>)
#endif
-QT_END_HEADER
-
#endif
diff --git a/src/network/ssl/qsslkey.h b/src/network/ssl/qsslkey.h
index 986b1c41de..145d4a28f1 100644
--- a/src/network/ssl/qsslkey.h
+++ b/src/network/ssl/qsslkey.h
@@ -48,8 +48,6 @@
#include <QtCore/qsharedpointer.h>
#include <QtNetwork/qssl.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -110,6 +108,4 @@ Q_NETWORK_EXPORT QDebug operator<<(QDebug debug, const QSslKey &key);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/network/ssl/qsslsocket.cpp b/src/network/ssl/qsslsocket.cpp
index f0c3f40a28..a8bf8f83b8 100644
--- a/src/network/ssl/qsslsocket.cpp
+++ b/src/network/ssl/qsslsocket.cpp
@@ -267,7 +267,7 @@
/*!
\fn void QSslSocket::sslErrors(const QList<QSslError> &errors);
-
+
QSslSocket emits this signal after the SSL handshake to indicate that one
or more errors have occurred while establishing the identity of the
peer. The errors are usually an indication that QSslSocket is unable to
@@ -281,7 +281,7 @@
\a errors contains one or more errors that prevent QSslSocket from
verifying the identity of the peer.
-
+
Note: You cannot use Qt::QueuedConnection when connecting to this signal,
or calling QSslSocket::ignoreSslErrors() will have no effect.
@@ -436,7 +436,7 @@ void QSslSocket::connectToHostEncrypted(const QString &hostName, quint16 port, O
\overload
In addition to the original behaviour of connectToHostEncrypted,
- this overloaded method enables the usage of a different hostname
+ this overloaded method enables the usage of a different hostname
(\a sslPeerName) for the certificate validation instead of
the one used for the TCP connection (\a hostName).
@@ -827,7 +827,7 @@ bool QSslSocket::flush()
/*!
\since 4.4
- Sets the size of QSslSocket's internal read buffer to be \a size bytes.
+ Sets the size of QSslSocket's internal read buffer to be \a size bytes.
*/
void QSslSocket::setReadBufferSize(qint64 size)
{
@@ -895,7 +895,7 @@ QSslConfiguration QSslSocket::sslConfiguration() const
void QSslSocket::setSslConfiguration(const QSslConfiguration &configuration)
{
Q_D(QSslSocket);
- d->configuration.localCertificate = configuration.localCertificate();
+ d->configuration.localCertificateChain = configuration.localCertificateChain();
d->configuration.privateKey = configuration.privateKey();
d->configuration.ciphers = configuration.ciphers();
d->configuration.caCertificates = configuration.caCertificates();
@@ -912,6 +912,32 @@ void QSslSocket::setSslConfiguration(const QSslConfiguration &configuration)
}
/*!
+ Sets the certificate chain to be presented to the peer during the
+ SSL handshake to be \a localChain.
+
+ \sa QSslConfiguration::setLocalCertificateChain()
+ \since 5.1
+ */
+void QSslSocket::setLocalCertificateChain(const QList<QSslCertificate> &localChain)
+{
+ Q_D(QSslSocket);
+ d->configuration.localCertificateChain = localChain;
+}
+
+/*!
+ Returns the socket's local \l {QSslCertificate} {certificate} chain,
+ or an empty list if no local certificates have been assigned.
+
+ \sa setLocalCertificateChain()
+ \since 5.1
+*/
+QList<QSslCertificate> QSslSocket::localCertificateChain() const
+{
+ Q_D(const QSslSocket);
+ return d->configuration.localCertificateChain;
+}
+
+/*!
Sets the socket's local certificate to \a certificate. The local
certificate is necessary if you need to confirm your identity to the
peer. It is used together with the private key; if you set the local
@@ -926,23 +952,24 @@ void QSslSocket::setSslConfiguration(const QSslConfiguration &configuration)
void QSslSocket::setLocalCertificate(const QSslCertificate &certificate)
{
Q_D(QSslSocket);
- d->configuration.localCertificate = certificate;
+ d->configuration.localCertificateChain = QList<QSslCertificate>();
+ d->configuration.localCertificateChain += certificate;
}
/*!
\overload
Sets the socket's local \l {QSslCertificate} {certificate} to the
- first one found in file \a path, which is parsed according to the
+ first one found in file \a path, which is parsed according to the
specified \a format.
*/
void QSslSocket::setLocalCertificate(const QString &path,
QSsl::EncodingFormat format)
{
- Q_D(QSslSocket);
QFile file(path);
if (file.open(QIODevice::ReadOnly | QIODevice::Text))
- d->configuration.localCertificate = QSslCertificate(file.readAll(), format);
+ setLocalCertificate(QSslCertificate(file.readAll(), format));
+
}
/*!
@@ -954,14 +981,16 @@ void QSslSocket::setLocalCertificate(const QString &path,
QSslCertificate QSslSocket::localCertificate() const
{
Q_D(const QSslSocket);
- return d->configuration.localCertificate;
+ if (d->configuration.localCertificateChain.isEmpty())
+ return QSslCertificate();
+ return d->configuration.localCertificateChain[0];
}
/*!
Returns the peer's digital certificate (i.e., the immediate
certificate of the host you are connected to), or a null
certificate, if the peer has not assigned a certificate.
-
+
The peer certificate is checked automatically during the
handshake phase, so this function is normally used to fetch
the certificate for display or for connection diagnostic
@@ -1073,7 +1102,7 @@ void QSslSocket::setPrivateKey(const QSslKey &key)
creating an SSL server socket. If you are creating an SSL client
socket, the key and local certificate are required if your client
must identify itself to an SSL server.
-
+
\sa privateKey(), setLocalCertificate()
*/
void QSslSocket::setPrivateKey(const QString &fileName, QSsl::KeyAlgorithm algorithm,
@@ -1681,7 +1710,7 @@ void QSslSocket::startClientEncryption()
subclass of QTcpServer and reimplement
QTcpServer::incomingConnection(). The returned socket descriptor
is then passed to QSslSocket::setSocketDescriptor().
-
+
\sa connectToHostEncrypted(), startClientEncryption()
*/
void QSslSocket::startServerEncryption()
@@ -2057,7 +2086,7 @@ void QSslConfigurationPrivate::deepCopyDefaultConfiguration(QSslConfigurationPri
ptr->ref.store(1);
ptr->peerCertificate = global->peerCertificate;
ptr->peerCertificateChain = global->peerCertificateChain;
- ptr->localCertificate = global->localCertificate;
+ ptr->localCertificateChain = global->localCertificateChain;
ptr->privateKey = global->privateKey;
ptr->sessionCipher = global->sessionCipher;
ptr->ciphers = global->ciphers;
@@ -2410,6 +2439,23 @@ QList<QByteArray> QSslSocketPrivate::unixRootCertDirectories()
<< "/opt/openssl/certs/"; // HP-UX
}
+/*!
+ \internal
+*/
+void QSslSocketPrivate::checkSettingSslContext(QSslSocket* socket, QSharedPointer<QSslContext> sslContext)
+{
+ if (socket->d_func()->sslContextPointer.isNull())
+ socket->d_func()->sslContextPointer = sslContext;
+}
+
+/*!
+ \internal
+*/
+QSharedPointer<QSslContext> QSslSocketPrivate::sslContext(QSslSocket *socket)
+{
+ return (socket) ? socket->d_func()->sslContextPointer : QSharedPointer<QSslContext>();
+}
+
QT_END_NAMESPACE
#include "moc_qsslsocket.cpp"
diff --git a/src/network/ssl/qsslsocket.h b/src/network/ssl/qsslsocket.h
index 929e437554..d89933efda 100644
--- a/src/network/ssl/qsslsocket.h
+++ b/src/network/ssl/qsslsocket.h
@@ -50,8 +50,6 @@
# include <QtNetwork/qsslerror.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -133,6 +131,9 @@ public:
void setSslConfiguration(const QSslConfiguration &config);
// Certificate & cipher accessors.
+ void setLocalCertificateChain(const QList<QSslCertificate> &localChain);
+ QList<QSslCertificate> localCertificateChain() const;
+
void setLocalCertificate(const QSslCertificate &certificate);
void setLocalCertificate(const QString &fileName, QSsl::EncodingFormat format = QSsl::Pem);
QSslCertificate localCertificate() const;
@@ -223,6 +224,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/network/ssl/qsslsocket_openssl.cpp b/src/network/ssl/qsslsocket_openssl.cpp
index f846bf2d8b..2b9c4b5bd2 100644
--- a/src/network/ssl/qsslsocket_openssl.cpp
+++ b/src/network/ssl/qsslsocket_openssl.cpp
@@ -55,6 +55,7 @@
****************************************************************************/
//#define QSSLSOCKET_DEBUG
+//#define QT_DECRYPT_SSL_TRAFFIC
#include "qsslsocket_openssl_p.h"
#include "qsslsocket_openssl_symbols_p.h"
@@ -156,6 +157,19 @@ private:
};
Q_GLOBAL_STATIC(QOpenSslLocks, openssl_locks)
+QString QSslSocketBackendPrivate::getErrorsFromOpenSsl()
+{
+ QString errorString;
+ unsigned long errNum;
+ while ((errNum = q_ERR_get_error())) {
+ if (! errorString.isEmpty())
+ errorString.append(QLatin1String(", "));
+ const char *error = q_ERR_error_string(errNum, NULL);
+ errorString.append(QString::fromLatin1(error)); // error is ascii according to man ERR_error_string
+ }
+ return errorString;
+}
+
extern "C" {
static void locking_function(int mode, int lockNumber, const char *, int)
{
@@ -175,8 +189,6 @@ static unsigned long id_function()
QSslSocketBackendPrivate::QSslSocketBackendPrivate()
: ssl(0),
- ctx(0),
- pkey(0),
readBio(0),
writeBio(0),
session(0)
@@ -240,7 +252,8 @@ struct QSslErrorList
QList<QPair<int, int> > errors;
};
Q_GLOBAL_STATIC(QSslErrorList, _q_sslErrorList)
-static int q_X509Callback(int ok, X509_STORE_CTX *ctx)
+
+int q_X509Callback(int ok, X509_STORE_CTX *ctx)
{
if (!ok) {
// Store the error and at which depth the error was detected.
@@ -311,191 +324,21 @@ bool QSslSocketBackendPrivate::initSslContext()
{
Q_Q(QSslSocket);
- // Create and initialize SSL context. Accept SSLv2, SSLv3 and TLSv1_0.
- bool client = (mode == QSslSocket::SslClientMode);
-
- bool reinitialized = false;
+ // If no external context was set (e.g. bei QHttpNetworkConnection) we will create a default context
+ if (!sslContextPointer)
+ sslContextPointer = QSharedPointer<QSslContext>(
+ QSslContext::fromConfiguration(mode, QSslConfiguration(&configuration), allowRootCertOnDemandLoading));
-init_context:
- switch (configuration.protocol) {
- case QSsl::SslV2:
-#ifndef OPENSSL_NO_SSL2
- ctx = q_SSL_CTX_new(client ? q_SSLv2_client_method() : q_SSLv2_server_method());
-#else
- ctx = 0; // SSL 2 not supported by the system, but chosen deliberately -> error
-#endif
- break;
- case QSsl::SslV3:
- ctx = q_SSL_CTX_new(client ? q_SSLv3_client_method() : q_SSLv3_server_method());
- break;
- case QSsl::SecureProtocols: // SslV2 will be disabled below
- case QSsl::TlsV1SslV3: // SslV2 will be disabled below
- case QSsl::AnyProtocol:
- default:
- ctx = q_SSL_CTX_new(client ? q_SSLv23_client_method() : q_SSLv23_server_method());
- break;
- case QSsl::TlsV1_0:
- ctx = q_SSL_CTX_new(client ? q_TLSv1_client_method() : q_TLSv1_server_method());
- break;
- case QSsl::TlsV1_1:
-#if OPENSSL_VERSION_NUMBER >= 0x10001000L
- ctx = q_SSL_CTX_new(client ? q_TLSv1_1_client_method() : q_TLSv1_1_server_method());
-#else
- ctx = 0; // TLS 1.1 not supported by the system, but chosen deliberately -> error
-#endif
- break;
- case QSsl::TlsV1_2:
-#if OPENSSL_VERSION_NUMBER >= 0x10001000L
- ctx = q_SSL_CTX_new(client ? q_TLSv1_2_client_method() : q_TLSv1_2_server_method());
-#else
- ctx = 0; // TLS 1.2 not supported by the system, but chosen deliberately -> error
-#endif
- break;
- }
- if (!ctx) {
- // After stopping Flash 10 the SSL library looses its ciphers. Try re-adding them
- // by re-initializing the library.
- if (!reinitialized) {
- reinitialized = true;
- if (q_SSL_library_init() == 1)
- goto init_context;
- }
-
- q->setErrorString(QSslSocket::tr("Error creating SSL context (%1)").arg(getErrorsFromOpenSsl()));
- q->setSocketError(QAbstractSocket::SslInternalError);
- emit q->error(QAbstractSocket::SslInternalError);
- return false;
- }
-
- // Enable bug workarounds.
- long options = setupOpenSslOptions(configuration.protocol, configuration.sslOptions);
- q_SSL_CTX_set_options(ctx, options);
-
-#if OPENSSL_VERSION_NUMBER >= 0x10000000L
- // Tell OpenSSL to release memory early
- // http://www.openssl.org/docs/ssl/SSL_CTX_set_mode.html
- if (q_SSLeay() >= 0x10000000L)
- q_SSL_CTX_set_mode(ctx, SSL_MODE_RELEASE_BUFFERS);
-#endif
-
- // Initialize ciphers
- QByteArray cipherString;
- int first = true;
- QList<QSslCipher> ciphers = configuration.ciphers;
- if (ciphers.isEmpty())
- ciphers = defaultCiphers();
- foreach (const QSslCipher &cipher, ciphers) {
- if (first)
- first = false;
- else
- cipherString.append(':');
- cipherString.append(cipher.name().toLatin1());
- }
-
- if (!q_SSL_CTX_set_cipher_list(ctx, cipherString.data())) {
- q->setErrorString(QSslSocket::tr("Invalid or empty cipher list (%1)").arg(getErrorsFromOpenSsl()));
+ if (sslContextPointer->error() != QSslError::NoError) {
+ q->setErrorString(sslContextPointer->errorString());
q->setSocketError(QAbstractSocket::SslInvalidUserDataError);
emit q->error(QAbstractSocket::SslInvalidUserDataError);
+ sslContextPointer.clear(); // deletes the QSslContext
return false;
}
- // Add all our CAs to this store.
- QList<QSslCertificate> expiredCerts;
- foreach (const QSslCertificate &caCertificate, q->caCertificates()) {
- // add expired certs later, so that the
- // valid ones are used before the expired ones
- if (caCertificate.expiryDate() < QDateTime::currentDateTime()) {
- expiredCerts.append(caCertificate);
- } else {
- q_X509_STORE_add_cert(ctx->cert_store, reinterpret_cast<X509 *>(caCertificate.handle()));
- }
- }
-
- bool addExpiredCerts = true;
-#if defined(Q_OS_MAC) && (MAC_OS_X_VERSION_MAX_ALLOWED == MAC_OS_X_VERSION_10_5)
- //On Leopard SSL does not work if we add the expired certificates.
- if (QSysInfo::MacintoshVersion == QSysInfo::MV_10_5)
- addExpiredCerts = false;
-#endif
- // now add the expired certs
- if (addExpiredCerts) {
- foreach (const QSslCertificate &caCertificate, expiredCerts) {
- q_X509_STORE_add_cert(ctx->cert_store, reinterpret_cast<X509 *>(caCertificate.handle()));
- }
- }
-
- if (s_loadRootCertsOnDemand && allowRootCertOnDemandLoading) {
- // tell OpenSSL the directories where to look up the root certs on demand
- QList<QByteArray> unixDirs = unixRootCertDirectories();
- for (int a = 0; a < unixDirs.count(); ++a)
- q_SSL_CTX_load_verify_locations(ctx, 0, unixDirs.at(a).constData());
- }
-
- // Register a custom callback to get all verification errors.
- X509_STORE_set_verify_cb_func(ctx->cert_store, q_X509Callback);
-
- if (!configuration.localCertificate.isNull()) {
- // Require a private key as well.
- if (configuration.privateKey.isNull()) {
- q->setErrorString(QSslSocket::tr("Cannot provide a certificate with no key, %1").arg(getErrorsFromOpenSsl()));
- q->setSocketError(QAbstractSocket::SslInvalidUserDataError);
- emit q->error(QAbstractSocket::SslInvalidUserDataError);
- return false;
- }
-
- // Load certificate
- if (!q_SSL_CTX_use_certificate(ctx, reinterpret_cast<X509 *>(configuration.localCertificate.handle()))) {
- q->setErrorString(QSslSocket::tr("Error loading local certificate, %1").arg(getErrorsFromOpenSsl()));
- q->setSocketError(QAbstractSocket::SslInternalError);
- emit q->error(QAbstractSocket::SslInternalError);
- return false;
- }
-
- if (configuration.privateKey.algorithm() == QSsl::Opaque) {
- pkey = reinterpret_cast<EVP_PKEY *>(configuration.privateKey.handle());
- } else {
- // Load private key
- pkey = q_EVP_PKEY_new();
- // before we were using EVP_PKEY_assign_R* functions and did not use EVP_PKEY_free.
- // this lead to a memory leak. Now we use the *_set1_* functions which do not
- // take ownership of the RSA/DSA key instance because the QSslKey already has ownership.
- if (configuration.privateKey.algorithm() == QSsl::Rsa)
- q_EVP_PKEY_set1_RSA(pkey, reinterpret_cast<RSA *>(configuration.privateKey.handle()));
- else
- q_EVP_PKEY_set1_DSA(pkey, reinterpret_cast<DSA *>(configuration.privateKey.handle()));
- }
-
- if (!q_SSL_CTX_use_PrivateKey(ctx, pkey)) {
- q->setErrorString(QSslSocket::tr("Error loading private key, %1").arg(getErrorsFromOpenSsl()));
- q->setSocketError(QAbstractSocket::SslInternalError);
- emit q->error(QAbstractSocket::SslInternalError);
- return false;
- }
- if (configuration.privateKey.algorithm() == QSsl::Opaque)
- pkey = 0; // Don't free the private key, it belongs to QSslKey
-
- // Check if the certificate matches the private key.
- if (!q_SSL_CTX_check_private_key(ctx)) {
- q->setErrorString(QSslSocket::tr("Private key does not certify public key, %1").arg(getErrorsFromOpenSsl()));
- q->setSocketError(QAbstractSocket::SslInvalidUserDataError);
- emit q->error(QAbstractSocket::SslInvalidUserDataError);
- return false;
- }
- }
-
- // Initialize peer verification.
- if (configuration.peerVerifyMode == QSslSocket::VerifyNone) {
- q_SSL_CTX_set_verify(ctx, SSL_VERIFY_NONE, 0);
- } else {
- q_SSL_CTX_set_verify(ctx, SSL_VERIFY_PEER, q_X509Callback);
- }
-
- // Set verification depth.
- if (configuration.peerVerifyDepth != 0)
- q_SSL_CTX_set_verify_depth(ctx, configuration.peerVerifyDepth);
-
// Create and initialize SSL session
- if (!(ssl = q_SSL_new(ctx))) {
+ if (!(ssl = sslContextPointer->createSsl())) {
// ### Bad error code
q->setErrorString(QSslSocket::tr("Error creating SSL session, %1").arg(getErrorsFromOpenSsl()));
q->setSocketError(QAbstractSocket::SslInternalError);
@@ -510,7 +353,7 @@ init_context:
configuration.protocol == QSsl::TlsV1_2 ||
configuration.protocol == QSsl::SecureProtocols ||
configuration.protocol == QSsl::AnyProtocol) &&
- client && q_SSLeay() >= 0x00090806fL) {
+ mode == QSslSocket::SslClientMode && q_SSLeay() >= 0x00090806fL) {
// Set server hostname on TLS extension. RFC4366 section 3.1 requires it in ACE format.
QString tlsHostName = verificationPeerName.isEmpty() ? q->peerName() : verificationPeerName;
if (tlsHostName.isEmpty())
@@ -527,7 +370,6 @@ init_context:
#endif
// Clear the session.
- q_SSL_clear(ssl);
errorList.clear();
// Initialize memory BIOs for encryption and decryption.
@@ -557,14 +399,7 @@ void QSslSocketBackendPrivate::destroySslContext()
q_SSL_free(ssl);
ssl = 0;
}
- if (ctx) {
- q_SSL_CTX_free(ctx);
- ctx = 0;
- }
- if (pkey) {
- q_EVP_PKEY_free(pkey);
- pkey = 0;
- }
+ sslContextPointer.clear();
}
/*!
@@ -847,10 +682,19 @@ QList<QSslCertificate> QSslSocketPrivate::systemCaCertificates()
}
#elif defined(Q_OS_UNIX)
QSet<QString> certFiles;
+# ifdef Q_OS_ANDROID
+ QList<QByteArray> directories;
+ directories << qgetenv("MINISTRO_SSL_CERTS_PATH"); // Set by Ministro
+# else
QList<QByteArray> directories = unixRootCertDirectories();
+# endif
QDir currentDir;
QStringList nameFilters;
+# ifdef Q_OS_ANDROID
+ nameFilters << QLatin1String("*.der");
+#else
nameFilters << QLatin1String("*.pem") << QLatin1String("*.crt");
+# endif
currentDir.setNameFilters(nameFilters);
for (int a = 0; a < directories.count(); a++) {
currentDir.setPath(QLatin1String(directories.at(a)));
@@ -863,10 +707,16 @@ QList<QSslCertificate> QSslSocketPrivate::systemCaCertificates()
}
QSetIterator<QString> it(certFiles);
while(it.hasNext()) {
- systemCerts.append(QSslCertificate::fromPath(it.next()));
+# ifdef Q_OS_ANDROID
+ systemCerts.append(QSslCertificate::fromPath(it.next(), QSsl::Der));
+# else
+ systemCerts.append(QSslCertificate::fromPath(it.next(), QSsl::Pem));
+# endif
}
+# ifndef Q_OS_ANDROID
systemCerts.append(QSslCertificate::fromPath(QLatin1String("/etc/pki/tls/certs/ca-bundle.crt"), QSsl::Pem)); // Fedora, Mandriva
systemCerts.append(QSslCertificate::fromPath(QLatin1String("/usr/local/share/certs/ca-root-nss.crt"), QSsl::Pem)); // FreeBSD's ca_root_nss
+# endif
#endif
#ifdef QSSLSOCKET_DEBUG
qDebug() << "systemCaCertificates retrieval time " << timer.elapsed() << "ms";
@@ -1102,7 +952,7 @@ void QSslSocketBackendPrivate::transmit()
break;
}
} while (ssl && readBytes > 0);
- } while (ssl && ctx && transmitting);
+ } while (ssl && transmitting);
}
static QSslError _q_OpenSSL_to_QSslError(int errorCode, const QSslCertificate &cert)
@@ -1308,7 +1158,6 @@ bool QSslSocketBackendPrivate::startHandshake()
}
}
#endif
-
if (!checkSslErrors())
return false;
} else {
@@ -1532,7 +1381,7 @@ void QSslSocketBackendPrivate::disconnected()
QSslCipher QSslSocketBackendPrivate::sessionCipher() const
{
- if (!ssl || !ctx)
+ if (!ssl)
return QSslCipher();
#if OPENSSL_VERSION_NUMBER >= 0x10000000L
// FIXME This is fairly evil, but needed to keep source level compatibility
@@ -1552,6 +1401,49 @@ void QSslSocketBackendPrivate::continueHandshake()
if (readBufferMaxSize)
plainSocket->setReadBufferSize(readBufferMaxSize);
+ if (q_SSL_ctrl((ssl), SSL_CTRL_GET_SESSION_REUSED, 0, NULL))
+ configuration.peerSessionShared = true;
+
+#ifdef QT_DECRYPT_SSL_TRAFFIC
+ if (ssl->session && ssl->s3) {
+ const char *mk = reinterpret_cast<const char *>(ssl->session->master_key);
+ QByteArray masterKey(mk, ssl->session->master_key_length);
+ const char *random = reinterpret_cast<const char *>(ssl->s3->client_random);
+ QByteArray clientRandom(random, SSL3_RANDOM_SIZE);
+
+ // different format, needed for e.g. older Wireshark versions:
+// const char *sid = reinterpret_cast<const char *>(ssl->session->session_id);
+// QByteArray sessionID(sid, ssl->session->session_id_length);
+// QByteArray debugLineRSA("RSA Session-ID:");
+// debugLineRSA.append(sessionID.toHex().toUpper());
+// debugLineRSA.append(" Master-Key:");
+// debugLineRSA.append(masterKey.toHex().toUpper());
+// debugLineRSA.append("\n");
+
+ QByteArray debugLineClientRandom("CLIENT_RANDOM ");
+ debugLineClientRandom.append(clientRandom.toHex().toUpper());
+ debugLineClientRandom.append(" ");
+ debugLineClientRandom.append(masterKey.toHex().toUpper());
+ debugLineClientRandom.append("\n");
+
+ QString sslKeyFile = QDir::tempPath() + QLatin1String("/qt-ssl-keys");
+ QFile file(sslKeyFile);
+ if (!file.open(QIODevice::Append))
+ qWarning() << "could not open file" << sslKeyFile << "for appending";
+ if (!file.write(debugLineClientRandom))
+ qWarning() << "could not write to file" << sslKeyFile;
+ file.close();
+ } else {
+ qWarning("could not decrypt SSL traffic");
+ }
+#endif
+
+ // Cache this SSL session inside the QSslContext
+ if (!(configuration.sslOptions & QSsl::SslOptionDisableSessionTickets)) {
+ if (!sslContextPointer->cacheSession(ssl))
+ sslContextPointer.clear(); // we could not cache the session
+ }
+
connectionEncrypted = true;
emit q->encrypted();
if (autoStartHandshake && pendingClose) {
@@ -1571,19 +1463,6 @@ QList<QSslCertificate> QSslSocketBackendPrivate::STACKOFX509_to_QSslCertificates
return certificates;
}
-QString QSslSocketBackendPrivate::getErrorsFromOpenSsl()
-{
- QString errorString;
- unsigned long errNum;
- while((errNum = q_ERR_get_error())) {
- if (! errorString.isEmpty())
- errorString.append(QLatin1String(", "));
- const char *error = q_ERR_error_string(errNum, NULL);
- errorString.append(QString::fromLatin1(error)); // error is ascii according to man ERR_error_string
- }
- return errorString;
-}
-
bool QSslSocketBackendPrivate::isMatchingHostname(const QSslCertificate &cert, const QString &peerName)
{
QStringList commonNameList = cert.subjectInfo(QSslCertificate::CommonName);
@@ -1675,17 +1554,9 @@ QList<QSslError> QSslSocketBackendPrivate::verify(QList<QSslCertificate> certifi
}
}
- bool addExpiredCerts = true;
-#if defined(Q_OS_MAC) && (MAC_OS_X_VERSION_MAX_ALLOWED == MAC_OS_X_VERSION_10_5)
- //On Leopard SSL does not work if we add the expired certificates.
- if (QSysInfo::MacintoshVersion == QSysInfo::MV_10_5)
- addExpiredCerts = false;
-#endif
// now add the expired certs
- if (addExpiredCerts) {
- foreach (const QSslCertificate &caCertificate, expiredCerts) {
- q_X509_STORE_add_cert(certStore, reinterpret_cast<X509 *>(caCertificate.handle()));
- }
+ foreach (const QSslCertificate &caCertificate, expiredCerts) {
+ q_X509_STORE_add_cert(certStore, reinterpret_cast<X509 *>(caCertificate.handle()));
}
QMutexLocker sslErrorListMutexLocker(&_q_sslErrorList()->mutex);
diff --git a/src/network/ssl/qsslsocket_openssl_p.h b/src/network/ssl/qsslsocket_openssl_p.h
index d6675197b4..c8b23e6cad 100644
--- a/src/network/ssl/qsslsocket_openssl_p.h
+++ b/src/network/ssl/qsslsocket_openssl_p.h
@@ -75,7 +75,10 @@
#if defined(OCSP_RESPONSE)
#undef OCSP_RESPONSE
#endif
+#if defined(X509_NAME)
+#undef X509_NAME
#endif
+#endif // Q_OS_WIN
#include <openssl/asn1.h>
#include <openssl/bio.h>
@@ -115,8 +118,6 @@ public:
bool initSslContext();
void destroySslContext();
SSL *ssl;
- SSL_CTX *ctx;
- EVP_PKEY *pkey;
BIO *readBio;
BIO *writeBio;
SSL_SESSION *session;
diff --git a/src/network/ssl/qsslsocket_openssl_symbols.cpp b/src/network/ssl/qsslsocket_openssl_symbols.cpp
index 9f271f863a..fed99752b0 100644
--- a/src/network/ssl/qsslsocket_openssl_symbols.cpp
+++ b/src/network/ssl/qsslsocket_openssl_symbols.cpp
@@ -67,7 +67,7 @@
#if defined(Q_OS_UNIX)
#include <QtCore/qdir.h>
#endif
-#ifdef Q_OS_LINUX
+#if defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID_NO_SDK)
#include <link.h>
#endif
@@ -245,6 +245,10 @@ DEFINEFUNC3(void, SSL_set_bio, SSL *a, a, BIO *b, b, BIO *c, c, return, DUMMYARG
DEFINEFUNC(void, SSL_set_accept_state, SSL *a, a, return, DUMMYARG)
DEFINEFUNC(void, SSL_set_connect_state, SSL *a, a, return, DUMMYARG)
DEFINEFUNC(int, SSL_shutdown, SSL *a, a, return -1, return)
+DEFINEFUNC2(int, SSL_set_session, SSL* to, to, SSL_SESSION *session, session, return -1, return)
+DEFINEFUNC(void, SSL_SESSION_free, SSL_SESSION *ses, ses, return, DUMMYARG)
+DEFINEFUNC(SSL_SESSION*, SSL_get1_session, SSL *ssl, ssl, return 0, return)
+DEFINEFUNC(SSL_SESSION*, SSL_get_session, const SSL *ssl, ssl, return 0, return)
#if OPENSSL_VERSION_NUMBER >= 0x10000000L
#ifndef OPENSSL_NO_SSL2
DEFINEFUNC(const SSL_METHOD *, SSLv2_client_method, DUMMYARG, DUMMYARG, return 0, return)
@@ -379,7 +383,7 @@ static bool libGreaterThan(const QString &lhs, const QString &rhs)
return true;
}
-#ifdef Q_OS_LINUX
+#if defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID_NO_SDK)
static int dlIterateCallback(struct dl_phdr_info *info, size_t size, void *data)
{
if (size < sizeof (info->dlpi_addr) + sizeof (info->dlpi_name))
@@ -410,7 +414,9 @@ static QStringList libraryPathList()
paths << QLatin1String("/lib64") << QLatin1String("/usr/lib64") << QLatin1String("/usr/local/lib64");
paths << QLatin1String("/lib32") << QLatin1String("/usr/lib32") << QLatin1String("/usr/local/lib32");
-#ifdef Q_OS_LINUX
+#if defined(Q_OS_ANDROID_NO_SDK)
+ paths << QLatin1String("/system/lib");
+#elif defined(Q_OS_LINUX)
// discover paths of already loaded libraries
QSet<QString> loadedPaths;
dl_iterate_phdr(dlIterateCallback, &loadedPaths);
@@ -457,28 +463,46 @@ static QStringList findAllLibCrypto()
# endif
#ifdef Q_OS_WIN
-static QPair<QSystemLibrary*, QSystemLibrary*> loadOpenSslWin32()
+static bool tryToLoadOpenSslWin32Library(QLatin1String ssleay32LibName, QLatin1String libeay32LibName, QPair<QSystemLibrary*, QSystemLibrary*> &pair)
{
- QPair<QSystemLibrary*,QSystemLibrary*> pair;
pair.first = 0;
pair.second = 0;
- QSystemLibrary *ssleay32 = new QSystemLibrary(QLatin1String("ssleay32"));
+ QSystemLibrary *ssleay32 = new QSystemLibrary(ssleay32LibName);
if (!ssleay32->load(false)) {
- // Cannot find ssleay32.dll
delete ssleay32;
- return pair;
+ return FALSE;
}
- QSystemLibrary *libeay32 = new QSystemLibrary(QLatin1String("libeay32"));
+ QSystemLibrary *libeay32 = new QSystemLibrary(libeay32LibName);
if (!libeay32->load(false)) {
delete ssleay32;
delete libeay32;
- return pair;
+ return FALSE;
}
pair.first = ssleay32;
pair.second = libeay32;
+ return TRUE;
+}
+
+static QPair<QSystemLibrary*, QSystemLibrary*> loadOpenSslWin32()
+{
+ QPair<QSystemLibrary*,QSystemLibrary*> pair;
+ pair.first = 0;
+ pair.second = 0;
+
+ // When OpenSSL is built using MSVC then the libraries are named 'ssleay32.dll' and 'libeay32'dll'.
+ // When OpenSSL is built using GCC then different library names are used (depending on the OpenSSL version)
+ // The oldest version of a GCC-based OpenSSL which can be detected by the code below is 0.9.8g (released in 2007)
+ if (!tryToLoadOpenSslWin32Library(QLatin1String("ssleay32"), QLatin1String("libeay32"), pair)) {
+ if (!tryToLoadOpenSslWin32Library(QLatin1String("libssl-10"), QLatin1String("libcrypto-10"), pair)) {
+ if (!tryToLoadOpenSslWin32Library(QLatin1String("libssl-8"), QLatin1String("libcrypto-8"), pair)) {
+ tryToLoadOpenSslWin32Library(QLatin1String("libssl-7"), QLatin1String("libcrypto-7"), pair);
+ }
+ }
+ }
+
return pair;
}
#else
@@ -699,6 +723,10 @@ bool q_resolveOpenSslSymbols()
RESOLVEFUNC(SSL_set_bio)
RESOLVEFUNC(SSL_set_connect_state)
RESOLVEFUNC(SSL_shutdown)
+ RESOLVEFUNC(SSL_set_session)
+ RESOLVEFUNC(SSL_SESSION_free)
+ RESOLVEFUNC(SSL_get1_session)
+ RESOLVEFUNC(SSL_get_session)
RESOLVEFUNC(SSL_write)
#ifndef OPENSSL_NO_SSL2
RESOLVEFUNC(SSLv2_client_method)
diff --git a/src/network/ssl/qsslsocket_openssl_symbols_p.h b/src/network/ssl/qsslsocket_openssl_symbols_p.h
index ccd9d3cfb9..62648e3e37 100644
--- a/src/network/ssl/qsslsocket_openssl_symbols_p.h
+++ b/src/network/ssl/qsslsocket_openssl_symbols_p.h
@@ -347,6 +347,10 @@ void q_SSL_set_bio(SSL *a, BIO *b, BIO *c);
void q_SSL_set_accept_state(SSL *a);
void q_SSL_set_connect_state(SSL *a);
int q_SSL_shutdown(SSL *a);
+int q_SSL_set_session(SSL *to, SSL_SESSION *session);
+void q_SSL_SESSION_free(SSL_SESSION *ses);
+SSL_SESSION *q_SSL_get1_session(SSL *ssl);
+SSL_SESSION *q_SSL_get_session(const SSL *ssl);
#if OPENSSL_VERSION_NUMBER >= 0x10000000L
const SSL_METHOD *q_SSLv2_client_method();
const SSL_METHOD *q_SSLv3_client_method();
diff --git a/src/network/ssl/qsslsocket_p.h b/src/network/ssl/qsslsocket_p.h
index 851dec5840..72117353ac 100644
--- a/src/network/ssl/qsslsocket_p.h
+++ b/src/network/ssl/qsslsocket_p.h
@@ -59,6 +59,7 @@
#include <private/qtcpsocket_p.h>
#include "qsslkey.h"
#include "qsslconfiguration_p.h"
+#include <private/qsslcontext_p.h>
#include <QtCore/qstringlist.h>
@@ -114,6 +115,7 @@ public:
QSslConfigurationPrivate configuration;
QList<QSslError> sslErrors;
+ QSharedPointer<QSslContext> sslContextPointer;
// if set, this hostname is used for certificate validation instead of the hostname
// that was used for connecting to.
@@ -121,6 +123,8 @@ public:
bool allowRootCertOnDemandLoading;
+ static bool s_loadRootCertsOnDemand;
+
static bool supportsSsl();
static long sslLibraryVersionNumber();
static QString sslLibraryVersionString();
@@ -155,6 +159,9 @@ public:
void createPlainSocket(QIODevice::OpenMode openMode);
static void pauseSocketNotifiers(QSslSocket*);
static void resumeSocketNotifiers(QSslSocket*);
+ // ### The 2 methods below should be made member methods once the QSslContext class is made public
+ static void checkSettingSslContext(QSslSocket*, QSharedPointer<QSslContext>);
+ static QSharedPointer<QSslContext> sslContext(QSslSocket *socket);
bool isPaused() const;
void _q_connectedSlot();
void _q_hostFoundSlot();
@@ -170,6 +177,8 @@ public:
virtual void _q_caRootLoaded(QSslCertificate,QSslCertificate) = 0;
#endif
+ static QList<QByteArray> unixRootCertDirectories(); // used also by QSslContext
+
virtual qint64 peek(char *data, qint64 maxSize);
virtual QByteArray peek(qint64 maxSize);
@@ -192,8 +201,6 @@ private:
static bool s_loadedCiphersAndCerts;
protected:
bool verifyErrorsHaveBeenIgnored();
- static bool s_loadRootCertsOnDemand;
- static QList<QByteArray> unixRootCertDirectories();
bool paused;
};
diff --git a/src/network/ssl/ssl.pri b/src/network/ssl/ssl.pri
index 8ebb4b29af..f5afb43759 100644
--- a/src/network/ssl/ssl.pri
+++ b/src/network/ssl/ssl.pri
@@ -14,7 +14,8 @@ contains(QT_CONFIG, openssl) | contains(QT_CONFIG, openssl-linked) {
ssl/qsslsocket_openssl_symbols_p.h \
ssl/qsslsocket_p.h \
ssl/qsslcertificateextension.h \
- ssl/qsslcertificateextension_p.h
+ ssl/qsslcertificateextension_p.h \
+ ssl/qsslcontext_p.h
SOURCES += ssl/qssl.cpp \
ssl/qsslcertificate.cpp \
ssl/qsslconfiguration.cpp \
@@ -24,7 +25,8 @@ contains(QT_CONFIG, openssl) | contains(QT_CONFIG, openssl-linked) {
ssl/qsslsocket.cpp \
ssl/qsslsocket_openssl.cpp \
ssl/qsslsocket_openssl_symbols.cpp \
- ssl/qsslcertificateextension.cpp
+ ssl/qsslcertificateextension.cpp \
+ ssl/qsslcontext.cpp
# Add optional SSL libs
# Static linking of OpenSSL with msvc:
diff --git a/src/opengl/doc/src/qtopengl-examples.qdoc b/src/opengl/doc/src/qtopengl-examples.qdoc
index 17fee37b7c..67c6aa3c0d 100644
--- a/src/opengl/doc/src/qtopengl-examples.qdoc
+++ b/src/opengl/doc/src/qtopengl-examples.qdoc
@@ -35,7 +35,7 @@
These examples describe how to use the Qt OpenGL Module. For new code,
please use the OpenGL classes in the \l {Qt GUI Module}.
-
+
Qt provides support for integration with OpenGL implementations on all
platforms, giving developers the opportunity to display hardware accelerated
diff --git a/src/opengl/gl2paintengineex/qgl2pexvertexarray_p.h b/src/opengl/gl2paintengineex/qgl2pexvertexarray_p.h
index 44a0274da4..f1a664c93d 100644
--- a/src/opengl/gl2paintengineex/qgl2pexvertexarray_p.h
+++ b/src/opengl/gl2paintengineex/qgl2pexvertexarray_p.h
@@ -104,20 +104,20 @@ public:
maxX(-2e10), maxY(-2e10), minX(2e10), minY(2e10),
boundingRectDirty(true)
{ }
-
+
inline void addRect(const QRectF &rect)
{
qreal top = rect.top();
qreal left = rect.left();
qreal bottom = rect.bottom();
qreal right = rect.right();
-
+
vertexArray << QGLPoint(left, top)
<< QGLPoint(right, top)
<< QGLPoint(right, bottom)
<< QGLPoint(right, bottom)
<< QGLPoint(left, bottom)
- << QGLPoint(left, top);
+ << QGLPoint(left, top);
}
inline void addQuad(const QRectF &rect)
diff --git a/src/opengl/gl2paintengineex/qglcustomshaderstage_p.h b/src/opengl/gl2paintengineex/qglcustomshaderstage_p.h
index 4dffeb6bc6..69a6ef2896 100644
--- a/src/opengl/gl2paintengineex/qglcustomshaderstage_p.h
+++ b/src/opengl/gl2paintengineex/qglcustomshaderstage_p.h
@@ -55,8 +55,6 @@
#include <QGLShaderProgram>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -86,7 +84,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/opengl/gl2paintengineex/qglengineshadermanager_p.h b/src/opengl/gl2paintengineex/qglengineshadermanager_p.h
index 1c519231ef..eff33d6da0 100644
--- a/src/opengl/gl2paintengineex/qglengineshadermanager_p.h
+++ b/src/opengl/gl2paintengineex/qglengineshadermanager_p.h
@@ -228,8 +228,6 @@
#include <private/qgl_p.h>
#include <private/qglcustomshaderstage_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -508,6 +506,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QGLENGINE_SHADER_MANAGER_H
diff --git a/src/opengl/gl2paintengineex/qglengineshadersource_p.h b/src/opengl/gl2paintengineex/qglengineshadersource_p.h
index 5e689804e4..65fbada48f 100644
--- a/src/opengl/gl2paintengineex/qglengineshadersource_p.h
+++ b/src/opengl/gl2paintengineex/qglengineshadersource_p.h
@@ -56,8 +56,6 @@
#include "qglengineshadermanager_p.h"
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -523,6 +521,4 @@ static const char* const qglslRgbMaskFragmentShaderPass2 = "\n\
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // GLGC_SHADER_SOURCE_H
diff --git a/src/opengl/gl2paintengineex/qglshadercache_meego_p.h b/src/opengl/gl2paintengineex/qglshadercache_meego_p.h
index f104b9cc88..f3c345f9ac 100644
--- a/src/opengl/gl2paintengineex/qglshadercache_meego_p.h
+++ b/src/opengl/gl2paintengineex/qglshadercache_meego_p.h
@@ -68,8 +68,6 @@
# include <syslog.h>
#endif
-QT_BEGIN_HEADER
-
/*
This cache stores internal Qt shader programs in shared memory.
@@ -450,7 +448,5 @@ QT_END_NAMESPACE
#endif
-QT_END_HEADER
-
#endif
#endif
diff --git a/src/opengl/gl2paintengineex/qglshadercache_p.h b/src/opengl/gl2paintengineex/qglshadercache_p.h
index e05987c219..4fbddd4966 100644
--- a/src/opengl/gl2paintengineex/qglshadercache_p.h
+++ b/src/opengl/gl2paintengineex/qglshadercache_p.h
@@ -59,8 +59,6 @@
# include "qglshadercache_meego_p.h"
#else
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -91,7 +89,5 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
#endif
diff --git a/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp b/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp
index 8196c4def4..27073e80be 100644
--- a/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp
+++ b/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp
@@ -112,7 +112,7 @@ QGL2PaintEngineExPrivate::~QGL2PaintEngineExPrivate()
}
if (elementIndicesVBOId != 0) {
- glDeleteBuffers(1, &elementIndicesVBOId);
+ funcs.glDeleteBuffers(1, &elementIndicesVBOId);
elementIndicesVBOId = 0;
}
}
@@ -199,7 +199,7 @@ void QGL2PaintEngineExPrivate::updateBrushTexture()
// Get the image data for the pattern
QImage texImage = qt_imageForBrush(style, false);
- glActiveTexture(GL_TEXTURE0 + QT_BRUSH_TEXTURE_UNIT);
+ funcs.glActiveTexture(GL_TEXTURE0 + QT_BRUSH_TEXTURE_UNIT);
ctx->d_func()->bindTexture(texImage, GL_TEXTURE_2D, GL_RGBA, QGLContext::InternalBindOption);
updateTextureFilter(GL_TEXTURE_2D, GL_REPEAT, q->state()->renderHints & QPainter::SmoothPixmapTransform);
}
@@ -212,7 +212,7 @@ void QGL2PaintEngineExPrivate::updateBrushTexture()
// for opacity to the cache.
GLuint texId = QGL2GradientCache::cacheForContext(ctx)->getBuffer(*g, 1.0);
- glActiveTexture(GL_TEXTURE0 + QT_BRUSH_TEXTURE_UNIT);
+ funcs.glActiveTexture(GL_TEXTURE0 + QT_BRUSH_TEXTURE_UNIT);
glBindTexture(GL_TEXTURE_2D, texId);
if (g->spread() == QGradient::RepeatSpread || g->type() == QGradient::ConicalGradient)
@@ -229,7 +229,7 @@ void QGL2PaintEngineExPrivate::updateBrushTexture()
if (currentBrushPixmap.width() > max_texture_size || currentBrushPixmap.height() > max_texture_size)
currentBrushPixmap = currentBrushPixmap.scaled(max_texture_size, max_texture_size, Qt::KeepAspectRatio);
- glActiveTexture(GL_TEXTURE0 + QT_BRUSH_TEXTURE_UNIT);
+ funcs.glActiveTexture(GL_TEXTURE0 + QT_BRUSH_TEXTURE_UNIT);
QGLTexture *tex = ctx->d_func()->bindTexture(currentBrushPixmap, GL_TEXTURE_2D, GL_RGBA,
QGLContext::InternalBindOption |
QGLContext::CanFlipNativePixmapBindOption);
@@ -426,9 +426,9 @@ void QGL2PaintEngineExPrivate::updateMatrix()
// Set the PMV matrix attribute. As we use an attributes rather than uniforms, we only
// need to do this once for every matrix change and persists across all shader programs.
- glVertexAttrib3fv(QT_PMV_MATRIX_1_ATTR, pmvMatrix[0]);
- glVertexAttrib3fv(QT_PMV_MATRIX_2_ATTR, pmvMatrix[1]);
- glVertexAttrib3fv(QT_PMV_MATRIX_3_ATTR, pmvMatrix[2]);
+ funcs.glVertexAttrib3fv(QT_PMV_MATRIX_1_ATTR, pmvMatrix[0]);
+ funcs.glVertexAttrib3fv(QT_PMV_MATRIX_2_ATTR, pmvMatrix[1]);
+ funcs.glVertexAttrib3fv(QT_PMV_MATRIX_3_ATTR, pmvMatrix[2]);
dasher.setInvScale(inverseScale);
stroker.setInvScale(inverseScale);
@@ -538,12 +538,11 @@ void QGL2PaintEngineEx::beginNativePainting()
d->nativePaintingActive = true;
- QGLContext *ctx = d->ctx;
- glUseProgram(0);
+ d->funcs.glUseProgram(0);
// Disable all the vertex attribute arrays:
for (int i = 0; i < QT_GL_VERTEX_ARRAY_TRACKED_COUNT; ++i)
- glDisableVertexAttribArray(i);
+ d->funcs.glDisableVertexAttribArray(i);
#ifndef QT_OPENGL_ES_2
const QGLFormat &fmt = d->device->format();
@@ -572,8 +571,6 @@ void QGL2PaintEngineEx::beginNativePainting()
glMatrixMode(GL_MODELVIEW);
glLoadMatrixf(&mv_matrix[0][0]);
}
-#else
- Q_UNUSED(ctx);
#endif
d->lastTextureUsed = GLuint(-1);
@@ -588,13 +585,13 @@ void QGL2PaintEngineEx::beginNativePainting()
void QGL2PaintEngineExPrivate::resetGLState()
{
glDisable(GL_BLEND);
- glActiveTexture(GL_TEXTURE0);
+ funcs.glActiveTexture(GL_TEXTURE0);
glDisable(GL_STENCIL_TEST);
glDisable(GL_DEPTH_TEST);
glDisable(GL_SCISSOR_TEST);
glDepthMask(true);
glDepthFunc(GL_LESS);
- glClearDepth(1);
+ funcs.glClearDepthf(1);
glStencilMask(0xff);
glStencilOp(GL_KEEP, GL_KEEP, GL_KEEP);
glStencilFunc(GL_ALWAYS, 0, 0xff);
@@ -604,7 +601,7 @@ void QGL2PaintEngineExPrivate::resetGLState()
#ifndef QT_OPENGL_ES_2
// gl_Color, corresponding to vertex attribute 3, may have been changed
float color[] = { 1.0f, 1.0f, 1.0f, 1.0f };
- glVertexAttrib4fv(3, color);
+ funcs.glVertexAttrib4fv(3, color);
#endif
}
@@ -626,6 +623,12 @@ bool QGL2PaintEngineEx::isNativePaintingActive() const {
return d->nativePaintingActive;
}
+bool QGL2PaintEngineEx::shouldDrawCachedGlyphs(QFontEngine *fontEngine, const QTransform &t) const
+{
+ // Don't try to cache vastly transformed fonts
+ return t.type() < QTransform::TxProject && QPaintEngineEx::shouldDrawCachedGlyphs(fontEngine, t);
+}
+
void QGL2PaintEngineExPrivate::transferMode(EngineMode newMode)
{
if (newMode == mode)
@@ -727,7 +730,7 @@ void QGL2PaintEngineExPrivate::fill(const QVectorPath& path)
qreal scaleFactor = cache->iscale / inverseScale;
if (scaleFactor < 0.5 || scaleFactor > 2.0) {
#ifdef QT_OPENGL_CACHE_AS_VBOS
- glDeleteBuffers(1, &cache->vbo);
+ funcs.glDeleteBuffers(1, &cache->vbo);
cache->vbo = 0;
Q_ASSERT(cache->ibo == 0);
#else
@@ -754,9 +757,9 @@ void QGL2PaintEngineExPrivate::fill(const QVectorPath& path)
cache->primitiveType = GL_TRIANGLE_FAN;
cache->iscale = inverseScale;
#ifdef QT_OPENGL_CACHE_AS_VBOS
- glGenBuffers(1, &cache->vbo);
- glBindBuffer(GL_ARRAY_BUFFER, cache->vbo);
- glBufferData(GL_ARRAY_BUFFER, floatSizeInBytes, vertexCoordinateArray.data(), GL_STATIC_DRAW);
+ funcs.glGenBuffers(1, &cache->vbo);
+ funcs.glBindBuffer(GL_ARRAY_BUFFER, cache->vbo);
+ funcs.glBufferData(GL_ARRAY_BUFFER, floatSizeInBytes, vertexCoordinateArray.data(), GL_STATIC_DRAW);
cache->ibo = 0;
#else
cache->vertices = (float *) malloc(floatSizeInBytes);
@@ -767,7 +770,7 @@ void QGL2PaintEngineExPrivate::fill(const QVectorPath& path)
prepareForDraw(currentBrush.isOpaque());
#ifdef QT_OPENGL_CACHE_AS_VBOS
- glBindBuffer(GL_ARRAY_BUFFER, cache->vbo);
+ funcs.glBindBuffer(GL_ARRAY_BUFFER, cache->vbo);
setVertexAttributePointer(QT_VERTEX_COORDS_ATTR, 0);
#else
setVertexAttributePointer(QT_VERTEX_COORDS_ATTR, cache->vertices);
@@ -993,9 +996,9 @@ void QGL2PaintEngineExPrivate::fillStencilWithVertexArray(const float *data,
}
// Inc. for front-facing triangle
- glStencilOpSeparate(GL_FRONT, GL_KEEP, GL_INCR_WRAP, GL_INCR_WRAP);
+ funcs.glStencilOpSeparate(GL_FRONT, GL_KEEP, GL_INCR_WRAP, GL_INCR_WRAP);
// Dec. for back-facing "holes"
- glStencilOpSeparate(GL_BACK, GL_KEEP, GL_DECR_WRAP, GL_DECR_WRAP);
+ funcs.glStencilOpSeparate(GL_BACK, GL_KEEP, GL_DECR_WRAP, GL_DECR_WRAP);
glStencilMask(~GL_STENCIL_HIGH_BIT);
drawVertexArrays(data, stops, stopCount, GL_TRIANGLE_FAN);
@@ -1076,6 +1079,20 @@ void QGL2PaintEngineExPrivate::resetClipIfNeeded()
glColorMask(GL_TRUE, GL_TRUE, GL_TRUE, GL_TRUE);
}
+bool QGL2PaintEngineExPrivate::prepareForCachedGlyphDraw(const QFontEngineGlyphCache &cache)
+{
+ Q_Q(QGL2PaintEngineEx);
+
+ Q_ASSERT(cache.transform().type() <= QTransform::TxScale);
+
+ QTransform &transform = q->state()->matrix;
+ transform.scale(1.0 / cache.transform().m11(), 1.0 / cache.transform().m22());
+ bool ret = prepareForDraw(false);
+ transform.scale(cache.transform().m11(), cache.transform().m22());
+
+ return ret;
+}
+
bool QGL2PaintEngineExPrivate::prepareForDraw(bool srcPixelsAreOpaque)
{
if (brushTextureDirty && mode != ImageDrawingMode && mode != ImageArrayDrawingMode)
@@ -1369,7 +1386,7 @@ void QGL2PaintEngineEx::drawPixmap(const QRectF& dest, const QPixmap & pixmap, c
bindOptions |= QGLContext::TemporarilyCachedBindOption;
#endif
- glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
+ d->funcs.glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
QGLTexture *texture =
ctx->d_func()->bindTexture(pixmap, GL_TEXTURE_2D, GL_RGBA, bindOptions);
@@ -1411,7 +1428,7 @@ void QGL2PaintEngineEx::drawImage(const QRectF& dest, const QImage& image, const
ensureActive();
d->transferMode(ImageDrawingMode);
- glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
+ d->funcs.glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
QGLContext::BindOptions bindOptions = QGLContext::InternalBindOption;
#ifdef QGL_USE_TEXTURE_POOL
@@ -1439,11 +1456,10 @@ void QGL2PaintEngineEx::drawStaticTextItem(QStaticTextItem *textItem)
ensureActive();
QPainterState *s = state();
- float det = s->matrix.determinant();
// don't try to cache huge fonts or vastly transformed fonts
QFontEngine *fontEngine = textItem->fontEngine();
- if (shouldDrawCachedGlyphs(fontEngine, s->matrix) && det >= 0.25f && det <= 4.f) {
+ if (shouldDrawCachedGlyphs(fontEngine, s->matrix)) {
QFontEngineGlyphCache::Type glyphType = fontEngine->glyphFormat >= 0
? QFontEngineGlyphCache::Type(textItem->fontEngine()->glyphFormat)
: d->glyphCacheType;
@@ -1472,10 +1488,7 @@ bool QGL2PaintEngineEx::drawTexture(const QRectF &dest, GLuint textureId, const
ensureActive();
d->transferMode(ImageDrawingMode);
-#ifndef QT_OPENGL_ES_2
- QGLContext *ctx = d->ctx;
-#endif
- glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
+ d->funcs.glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
glBindTexture(GL_TEXTURE_2D, textureId);
QGLRect srcRect(src.left(), src.bottom(), src.right(), src.top());
@@ -1497,13 +1510,6 @@ void QGL2PaintEngineEx::drawTextItem(const QPointF &p, const QTextItem &textItem
QTransform::TransformationType txtype = s->matrix.type();
- float det = s->matrix.determinant();
- bool drawCached = txtype < QTransform::TxProject;
-
- // don't try to cache huge fonts or vastly transformed fonts
- if (!shouldDrawCachedGlyphs(ti.fontEngine, s->matrix) || det < 0.25f || det > 4.f)
- drawCached = false;
-
QFontEngineGlyphCache::Type glyphType = ti.fontEngine->glyphFormat >= 0
? QFontEngineGlyphCache::Type(ti.fontEngine->glyphFormat)
: d->glyphCacheType;
@@ -1519,7 +1525,7 @@ void QGL2PaintEngineEx::drawTextItem(const QPointF &p, const QTextItem &textItem
}
}
- if (drawCached) {
+ if (shouldDrawCachedGlyphs(ti.fontEngine, s->matrix)) {
QVarLengthArray<QFixedPoint> positions;
QVarLengthArray<glyph_t> glyphs;
QTransform matrix = QTransform::fromTranslate(p.x(), p.y());
@@ -1578,11 +1584,19 @@ void QGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type glyp
void *cacheKey = const_cast<QGLContext *>(QGLContextPrivate::contextGroup(ctx)->context());
bool recreateVertexArrays = false;
+ // We allow scaling, so that the glyph-cache will contain glyphs with the
+ // appropriate resolution in the case of displays with a device-pixel-ratio != 1.
+ QTransform transform = s->matrix.type() < QTransform::TxRotate ?
+ QTransform::fromScale(qAbs(s->matrix.m11()), qAbs(s->matrix.m22())) :
+ QTransform::fromScale(
+ QVector2D(s->matrix.m11(), s->matrix.m12()).length(),
+ QVector2D(s->matrix.m21(), s->matrix.m22()).length());
+
QFontEngine *fe = staticTextItem->fontEngine();
QGLTextureGlyphCache *cache =
- (QGLTextureGlyphCache *) fe->glyphCache(cacheKey, glyphType, QTransform());
+ (QGLTextureGlyphCache *) fe->glyphCache(cacheKey, glyphType, transform);
if (!cache || cache->cacheType() != glyphType || cache->contextGroup() == 0) {
- cache = new QGLTextureGlyphCache(glyphType, QTransform());
+ cache = new QGLTextureGlyphCache(glyphType, transform);
fe->setGlyphCache(cacheKey, cache);
recreateVertexArrays = true;
}
@@ -1674,8 +1688,8 @@ void QGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type glyp
if (c.isNull())
continue;
- int x = qFloor(staticTextItem->glyphPositions[i].x) + c.baseLineX - margin;
- int y = qRound(staticTextItem->glyphPositions[i].y) - c.baseLineY - margin;
+ int x = qFloor(staticTextItem->glyphPositions[i].x.toReal() * cache->transform().m11()) + c.baseLineX - margin;
+ int y = qRound(staticTextItem->glyphPositions[i].y.toReal() * cache->transform().m22()) - c.baseLineY - margin;
vertexCoordinates->addQuad(QRectF(x, y, c.w, c.h));
textureCoordinates->addQuad(QRectF(c.x*dx, c.y*dy, c.w * dx, c.h * dy));
@@ -1748,9 +1762,9 @@ void QGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type glyp
}
compositionModeDirty = false; // I can handle this myself, thank you very much
- prepareForDraw(false); // Text always causes src pixels to be transparent
+ prepareForCachedGlyphDraw(*cache);
- // prepareForDraw() have set the opacity on the current shader, so the opacity state can now be reset.
+ // prepareForCachedGlyphDraw() have set the opacity on the current shader, so the opacity state can now be reset.
if (compMode == QPainter::CompositionMode_Source) {
q->state()->opacity = oldOpacity;
opacityUniformDirty = true;
@@ -1758,7 +1772,7 @@ void QGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type glyp
glEnable(GL_BLEND);
glBlendFunc(GL_CONSTANT_COLOR, GL_ONE_MINUS_SRC_COLOR);
- glBlendColor(c.redF(), c.greenF(), c.blueF(), c.alphaF());
+ funcs.glBlendColor(c.redF(), c.greenF(), c.blueF(), c.alphaF());
} else {
// Other brush styles need two passes.
@@ -1771,11 +1785,11 @@ void QGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type glyp
}
compositionModeDirty = false; // I can handle this myself, thank you very much
- prepareForDraw(false); // Text always causes src pixels to be transparent
+ prepareForCachedGlyphDraw(*cache);
glEnable(GL_BLEND);
glBlendFunc(GL_ZERO, GL_ONE_MINUS_SRC_COLOR);
- glActiveTexture(GL_TEXTURE0 + QT_MASK_TEXTURE_UNIT);
+ funcs.glActiveTexture(GL_TEXTURE0 + QT_MASK_TEXTURE_UNIT);
glBindTexture(GL_TEXTURE_2D, cache->texture());
updateTextureFilter(GL_TEXTURE_2D, GL_REPEAT, false);
@@ -1795,7 +1809,7 @@ void QGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type glyp
}
compositionModeDirty = false;
- prepareForDraw(false); // Text always causes src pixels to be transparent
+ prepareForCachedGlyphDraw(*cache);
glEnable(GL_BLEND);
glBlendFunc(GL_ONE, GL_ONE);
}
@@ -1804,13 +1818,13 @@ void QGL2PaintEngineExPrivate::drawCachedGlyphs(QFontEngineGlyphCache::Type glyp
// Greyscale/mono glyphs
shaderManager->setMaskType(QGLEngineShaderManager::PixelMask);
- prepareForDraw(false); // Text always causes src pixels to be transparent
+ prepareForCachedGlyphDraw(*cache);
}
QGLTextureGlyphCache::FilterMode filterMode = (s->matrix.type() > QTransform::TxTranslate)?QGLTextureGlyphCache::Linear:QGLTextureGlyphCache::Nearest;
if (lastMaskTextureUsed != cache->texture() || cache->filterMode() != filterMode) {
- glActiveTexture(GL_TEXTURE0 + QT_MASK_TEXTURE_UNIT);
+ funcs.glActiveTexture(GL_TEXTURE0 + QT_MASK_TEXTURE_UNIT);
if (lastMaskTextureUsed != cache->texture()) {
glBindTexture(GL_TEXTURE_2D, cache->texture());
lastMaskTextureUsed = cache->texture();
@@ -1917,7 +1931,7 @@ void QGL2PaintEngineExPrivate::drawPixmapFragments(const QPainter::PixmapFragmen
allOpaque &= (opacity >= 0.99f);
}
- glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
+ funcs.glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
QGLTexture *texture = ctx->d_func()->bindTexture(pixmap, GL_TEXTURE_2D, GL_RGBA,
QGLContext::InternalBindOption
| QGLContext::CanFlipNativePixmapBindOption);
@@ -1990,14 +2004,7 @@ bool QGL2PaintEngineEx::begin(QPaintDevice *pdev)
// go after beginPaint:
d->device->beginPaint();
-#if !defined(QT_OPENGL_ES_2)
- bool success = qt_resolve_version_2_0_functions(d->ctx)
- && qt_resolve_buffer_extensions(d->ctx)
- && (!QGLFramebufferObject::hasOpenGLFramebufferObjects()
- || qt_resolve_framebufferobject_extensions(d->ctx));
- Q_ASSERT(success);
- Q_UNUSED(success);
-#endif
+ d->funcs.initializeOpenGLFunctions();
d->shaderManager = new QGLEngineShaderManager(d->ctx);
@@ -2031,7 +2038,7 @@ bool QGL2PaintEngineEx::end()
Q_D(QGL2PaintEngineEx);
QGLContext *ctx = d->ctx;
- glUseProgram(0);
+ d->funcs.glUseProgram(0);
d->transferMode(BrushDrawingMode);
d->device->endPaint();
diff --git a/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h b/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h
index 7835885c47..b0517fd083 100644
--- a/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h
+++ b/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h
@@ -62,6 +62,7 @@
#include <private/qfontengine_p.h>
#include <private/qdatabuffer_p.h>
#include <private/qtriangulatingstroker_p.h>
+#include <private/qopenglextensions_p.h>
enum EngineMode {
ImageDrawingMode,
@@ -155,7 +156,8 @@ public:
void setRenderTextActive(bool);
bool isNativePaintingActive() const;
- bool supportsTransformations(QFontEngine *, const QTransform &) const { return true; }
+ bool requiresPretransformedGlyphPositions(QFontEngine *, const QTransform &) const { return false; }
+ bool shouldDrawCachedGlyphs(QFontEngine *, const QTransform &) const;
private:
Q_DISABLE_COPY(QGL2PaintEngineEx)
};
@@ -190,7 +192,7 @@ public:
void updateBrushUniforms();
void updateMatrix();
void updateCompositionMode();
- void updateTextureFilter(GLenum target, GLenum wrapMode, bool smoothPixmapTransform, GLuint id = -1);
+ void updateTextureFilter(GLenum target, GLenum wrapMode, bool smoothPixmapTransform, GLuint id = GLuint(-1));
void resetGLState();
@@ -226,6 +228,7 @@ public:
void setBrush(const QBrush& brush);
void transferMode(EngineMode newMode);
bool prepareForDraw(bool srcPixelsAreOpaque); // returns true if the program has changed
+ bool prepareForCachedGlyphDraw(const QFontEngineGlyphCache &cache);
inline void useSimpleShader();
inline GLuint location(const QGLEngineShaderManager::Uniform uniform) {
return shaderManager->getUniformLocation(uniform);
@@ -254,6 +257,8 @@ public:
EngineMode mode;
QFontEngineGlyphCache::Type glyphCacheType;
+ QOpenGLExtensions funcs;
+
// Dirty flags
bool matrixDirty; // Implies matrix uniforms are also dirty
bool compositionModeDirty;
@@ -315,9 +320,9 @@ void QGL2PaintEngineExPrivate::setVertexAttributePointer(unsigned int arrayIndex
vertexAttribPointers[arrayIndex] = pointer;
if (arrayIndex == QT_OPACITY_ATTR)
- glVertexAttribPointer(arrayIndex, 1, GL_FLOAT, GL_FALSE, 0, pointer);
+ funcs.glVertexAttribPointer(arrayIndex, 1, GL_FLOAT, GL_FALSE, 0, pointer);
else
- glVertexAttribPointer(arrayIndex, 2, GL_FLOAT, GL_FALSE, 0, pointer);
+ funcs.glVertexAttribPointer(arrayIndex, 2, GL_FLOAT, GL_FALSE, 0, pointer);
}
QT_END_NAMESPACE
diff --git a/src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp b/src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp
index 045979e7ce..59401fe1e9 100644
--- a/src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp
+++ b/src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp
@@ -41,6 +41,7 @@
#include "qtextureglyphcache_gl_p.h"
#include "qpaintengineex_opengl2_p.h"
+#include "qglfunctions.h"
#include "private/qglengineshadersource_p.h"
QT_BEGIN_NAMESPACE
@@ -167,10 +168,12 @@ void QGLTextureGlyphCache::resizeTextureData(int width, int height)
return;
}
+ QOpenGLFunctions *funcs = ctx->contextHandle()->functions();
+
// ### the QTextureGlyphCache API needs to be reworked to allow
// ### resizeTextureData to fail
- glBindFramebuffer(GL_FRAMEBUFFER, m_textureResource->m_fbo);
+ funcs->glBindFramebuffer(GL_FRAMEBUFFER, m_textureResource->m_fbo);
GLuint tmp_texture;
glGenTextures(1, &tmp_texture);
@@ -183,10 +186,10 @@ void QGLTextureGlyphCache::resizeTextureData(int width, int height)
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
m_filterMode = Nearest;
glBindTexture(GL_TEXTURE_2D, 0);
- glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0,
- GL_TEXTURE_2D, tmp_texture, 0);
+ funcs->glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0,
+ GL_TEXTURE_2D, tmp_texture, 0);
- glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
+ funcs->glActiveTexture(GL_TEXTURE0 + QT_IMAGE_TEXTURE_UNIT);
glBindTexture(GL_TEXTURE_2D, oldTexture);
if (pex != 0)
@@ -232,8 +235,8 @@ void QGLTextureGlyphCache::resizeTextureData(int width, int height)
m_blitProgram->link();
}
- glVertexAttribPointer(QT_VERTEX_COORDS_ATTR, 2, GL_FLOAT, GL_FALSE, 0, m_vertexCoordinateArray);
- glVertexAttribPointer(QT_TEXTURE_COORDS_ATTR, 2, GL_FLOAT, GL_FALSE, 0, m_textureCoordinateArray);
+ funcs->glVertexAttribPointer(QT_VERTEX_COORDS_ATTR, 2, GL_FLOAT, GL_FALSE, 0, m_vertexCoordinateArray);
+ funcs->glVertexAttribPointer(QT_TEXTURE_COORDS_ATTR, 2, GL_FLOAT, GL_FALSE, 0, m_textureCoordinateArray);
m_blitProgram->bind();
m_blitProgram->enableAttributeArray(int(QT_VERTEX_COORDS_ATTR));
@@ -258,12 +261,12 @@ void QGLTextureGlyphCache::resizeTextureData(int width, int height)
glCopyTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, 0, 0, oldWidth, oldHeight);
- glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0,
- GL_RENDERBUFFER, 0);
+ funcs->glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0,
+ GL_RENDERBUFFER, 0);
glDeleteTextures(1, &tmp_texture);
glDeleteTextures(1, &oldTexture);
- glBindFramebuffer(GL_FRAMEBUFFER, ctx->d_ptr->current_fbo);
+ funcs->glBindFramebuffer(GL_FRAMEBUFFER, ctx->d_ptr->current_fbo);
if (pex != 0) {
glViewport(0, 0, pex->width, pex->height);
diff --git a/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h b/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h
index 16a7aacf20..8f43a906c0 100644
--- a/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h
+++ b/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h
@@ -57,6 +57,7 @@
#include <private/qgl_p.h>
#include <qglshaderprogram.h>
#include <qglframebufferobject.h>
+#include <qopenglfunctions.h>
// #define QT_GL_TEXTURE_GLYPH_CACHE_DEBUG
@@ -73,7 +74,7 @@ struct QGLGlyphTexture : public QOpenGLSharedResource
, m_height(0)
{
if (ctx && QGLFramebufferObject::hasOpenGLFramebufferObjects() && !ctx->d_ptr->workaround_brokenFBOReadBack)
- glGenFramebuffers(1, &m_fbo);
+ ctx->contextHandle()->functions()->glGenFramebuffers(1, &m_fbo);
#ifdef QT_GL_TEXTURE_GLYPH_CACHE_DEBUG
qDebug(" -> QGLGlyphTexture() %p for context %p.", this, ctx);
@@ -88,8 +89,8 @@ struct QGLGlyphTexture : public QOpenGLSharedResource
#else
Q_UNUSED(ctx);
#endif
- if (m_fbo)
- glDeleteFramebuffers(1, &m_fbo);
+ if (ctx && m_fbo)
+ ctx->contextHandle()->functions()->glDeleteFramebuffers(1, &m_fbo);
if (m_width || m_height)
glDeleteTextures(1, &m_texture);
}
diff --git a/src/opengl/opengl.pro b/src/opengl/opengl.pro
index 64b33b8c97..b01ca80829 100644
--- a/src/opengl/opengl.pro
+++ b/src/opengl/opengl.pro
@@ -8,6 +8,9 @@ irix-cc*:QMAKE_CXXFLAGS += -no_prelink -ptused
QMAKE_DOCS = $$PWD/doc/qtopengl.qdocconf
+ANDROID_LIB_DEPENDENCY_REPLACEMENTS = \
+ "plugins/platforms/android/libqtforandroid.so:plugins/platforms/android/libqtforandroidGL.so"
+
load(qt_module)
contains(QT_CONFIG, opengl):CONFIG += opengl
@@ -23,7 +26,6 @@ HEADERS += qgl.h \
qglpixelbuffer_p.h \
qglframebufferobject.h \
qglframebufferobject_p.h \
- qglextensions_p.h \
qglpaintdevice_p.h \
qglbuffer.h \
qtopenglglobal.h
@@ -33,7 +35,6 @@ SOURCES += qgl.cpp \
qglfunctions.cpp \
qglpixelbuffer.cpp \
qglframebufferobject.cpp \
- qglextensions.cpp \
qglpaintdevice.cpp \
qglbuffer.cpp \
diff --git a/src/opengl/qgl.cpp b/src/opengl/qgl.cpp
index 6476e2b26c..def0470622 100644
--- a/src/opengl/qgl.cpp
+++ b/src/opengl/qgl.cpp
@@ -59,6 +59,7 @@
#include <qglpixelbuffer.h>
#include <qglframebufferobject.h>
+#include <private/qopenglextensions_p.h>
#include <private/qimage_p.h>
#include <qpa/qplatformpixmap.h>
@@ -73,7 +74,52 @@
QT_BEGIN_NAMESPACE
-QGLExtensionFuncs QGLContextPrivate::qt_extensionFuncs;
+class QGLDefaultExtensions
+{
+public:
+ QGLDefaultExtensions() : extensions(0) {
+ QGLTemporaryContext tempContext;
+ Q_ASSERT(QOpenGLContext::currentContext());
+ QOpenGLExtensions *ext = qgl_extensions();
+ Q_ASSERT(ext);
+ extensions = ext->openGLExtensions();
+ features = ext->openGLFeatures();
+ }
+
+ QOpenGLFunctions::OpenGLFeatures features;
+ QOpenGLExtensions::OpenGLExtensions extensions;
+};
+
+Q_GLOBAL_STATIC(QGLDefaultExtensions, qtDefaultExtensions)
+
+bool qgl_hasFeature(QOpenGLFunctions::OpenGLFeature feature)
+{
+ if (QOpenGLContext::currentContext())
+ return QOpenGLContext::currentContext()->functions()->hasOpenGLFeature(feature);
+ return qtDefaultExtensions()->features & feature;
+}
+
+bool qgl_hasExtension(QOpenGLExtensions::OpenGLExtension extension)
+{
+ if (QOpenGLContext::currentContext())
+ return qgl_extensions()->hasOpenGLExtension(extension);
+ return qtDefaultExtensions()->extensions & extension;
+}
+
+QOpenGLExtensions::OpenGLExtensions extensions;
+/*
+ Returns the GL extensions for the current QOpenGLContext. If there is no
+ current QOpenGLContext, a default context will be created and the extensions
+ for that context will be returned instead.
+*/
+QOpenGLExtensions* qgl_extensions()
+{
+ if (QOpenGLContext *context = QOpenGLContext::currentContext())
+ return static_cast<QOpenGLExtensions *>(context->functions());
+
+ Q_ASSERT(false);
+ return 0;
+}
struct QGLThreadContext {
~QGLThreadContext() {
@@ -1567,8 +1613,6 @@ void QGLContextPrivate::init(QPaintDevice *dev, const QGLFormat &format)
max_texture_size = -1;
version_flags_cached = false;
version_flags = QGLFormat::OpenGL_Version_None;
- extension_flags_cached = false;
- extension_flags = 0;
current_fbo = 0;
default_fbo = 0;
active_engine = 0;
@@ -1956,30 +2000,32 @@ void QGLContextPrivate::cleanup()
#define ctx q_ptr
void QGLContextPrivate::setVertexAttribArrayEnabled(int arrayIndex, bool enabled)
{
+ Q_Q(QGLContext);
Q_ASSERT(arrayIndex < QT_GL_VERTEX_ARRAY_TRACKED_COUNT);
#ifdef glEnableVertexAttribArray
Q_ASSERT(glEnableVertexAttribArray);
#endif
if (vertexAttributeArraysEnabledState[arrayIndex] && !enabled)
- glDisableVertexAttribArray(arrayIndex);
+ q->functions()->glDisableVertexAttribArray(arrayIndex);
if (!vertexAttributeArraysEnabledState[arrayIndex] && enabled)
- glEnableVertexAttribArray(arrayIndex);
+ q->functions()->glEnableVertexAttribArray(arrayIndex);
vertexAttributeArraysEnabledState[arrayIndex] = enabled;
}
void QGLContextPrivate::syncGlState()
{
+ Q_Q(QGLContext);
#ifdef glEnableVertexAttribArray
Q_ASSERT(glEnableVertexAttribArray);
#endif
for (int i = 0; i < QT_GL_VERTEX_ARRAY_TRACKED_COUNT; ++i) {
if (vertexAttributeArraysEnabledState[i])
- glEnableVertexAttribArray(i);
+ q->functions()->glEnableVertexAttribArray(i);
else
- glDisableVertexAttribArray(i);
+ q->functions()->glDisableVertexAttribArray(i);
}
}
@@ -2041,11 +2087,6 @@ static inline QRgb qt_gl_convertToGLFormatHelper(QRgb src_pixel, GLenum texture_
}
}
-QRgb qt_gl_convertToGLFormat(QRgb src_pixel, GLenum texture_format)
-{
- return qt_gl_convertToGLFormatHelper(src_pixel, texture_format);
-}
-
static void convertToGLFormatHelper(QImage &dst, const QImage &img, GLenum texture_format)
{
Q_ASSERT(dst.depth() == 32);
@@ -2134,23 +2175,6 @@ static void convertToGLFormatHelper(QImage &dst, const QImage &img, GLenum textu
}
}
-QGLExtensionFuncs& QGLContextPrivate::extensionFuncs(const QGLContext *)
-{
- return qt_extensionFuncs;
-}
-
-QImage QGLContextPrivate::convertToGLFormat(const QImage &image, bool force_premul,
- GLenum texture_format)
-{
- QImage::Format target_format = image.format();
- if (force_premul || image.format() != QImage::Format_ARGB32)
- target_format = QImage::Format_ARGB32_Premultiplied;
-
- QImage result(image.width(), image.height(), target_format);
- convertToGLFormatHelper(result, image.convertToFormat(target_format), texture_format);
- return result;
-}
-
/*! \internal */
QGLTexture *QGLContextPrivate::bindTexture(const QImage &image, GLenum target, GLint format,
QGLContext::BindOptions options)
@@ -2238,7 +2262,7 @@ QGLTexture* QGLContextPrivate::bindTexture(const QImage &image, GLenum target, G
QImage img = image;
- if (!(QGLExtensions::glExtensions() & QGLExtensions::NPOTTextures)
+ if (!qgl_extensions()->hasOpenGLFeature(QOpenGLFunctions::NPOTTextures)
&& !(QGLFormat::openGLVersionFlags() & QGLFormat::OpenGL_ES_Version_2_0)
&& (target == GL_TEXTURE_2D && (tx_w != image.width() || tx_h != image.height())))
{
@@ -2260,7 +2284,7 @@ QGLTexture* QGLContextPrivate::bindTexture(const QImage &image, GLenum target, G
bool genMipmap = false;
#endif
if (glFormat.directRendering()
- && (QGLExtensions::glExtensions() & QGLExtensions::GenerateMipmap)
+ && (qgl_extensions()->hasOpenGLExtension(QOpenGLExtensions::GenerateMipmap))
&& target == GL_TEXTURE_2D
&& (options & QGLContext::MipmapBindOption))
{
@@ -2284,7 +2308,7 @@ QGLTexture* QGLContextPrivate::bindTexture(const QImage &image, GLenum target, G
bool premul = options & QGLContext::PremultipliedAlphaBindOption;
GLenum externalFormat;
GLuint pixel_type;
- if (QGLExtensions::glExtensions() & QGLExtensions::BGRATextureFormat) {
+ if (qgl_extensions()->hasOpenGLExtension(QOpenGLExtensions::BGRATextureFormat)) {
externalFormat = GL_BGRA;
if (QGLFormat::openGLVersionFlags() & QGLFormat::OpenGL_Version_1_2)
pixel_type = GL_UNSIGNED_INT_8_8_8_8_REV;
@@ -3786,7 +3810,7 @@ void QGLWidget::setFormat(const QGLFormat &format)
attributes that were requested.
*/
-/*
+/*!
\fn void QGLWidget::setContext(QGLContext *context,
const QGLContext* shareContext,
bool deleteOldContext)
@@ -3812,6 +3836,12 @@ void QGLWidget::setFormat(const QGLFormat &format)
to the old context (as returned by context()), and want to restore
that context later.
+ \note This function is obsolete and should no longer be used. If you were
+ using it to recreate the context for a QGLWidget, you should instead create a
+ new QGLWidget or use the QOpenGLContext API in conjunction with QWindow.
+ There is currently no officially supported way to substitute QGLWidget's
+ context with your own implementation of QGLContext.
+
\sa context(), isSharing()
*/
@@ -4668,192 +4698,6 @@ QPaintEngine *QGLWidget::paintEngine() const
return qt_qgl_paint_engine();
}
-typedef const GLubyte * (QGLF_APIENTRYP qt_glGetStringi)(GLenum, GLuint);
-
-#ifndef GL_NUM_EXTENSIONS
-#define GL_NUM_EXTENSIONS 0x821D
-#endif
-
-QGLExtensionMatcher::QGLExtensionMatcher(const char *str)
-{
- init(str);
-}
-
-QGLExtensionMatcher::QGLExtensionMatcher()
-{
- const char *extensionStr = reinterpret_cast<const char *>(glGetString(GL_EXTENSIONS));
-
- if (extensionStr) {
- init(extensionStr);
- } else {
- // clear error state
- while (glGetError()) {}
-
- const QGLContext *ctx = QGLContext::currentContext();
- if (ctx) {
- qt_glGetStringi glGetStringi = (qt_glGetStringi)ctx->getProcAddress(QLatin1String("glGetStringi"));
-
- GLint numExtensions;
- glGetIntegerv(GL_NUM_EXTENSIONS, &numExtensions);
-
- for (int i = 0; i < numExtensions; ++i) {
- const char *str = reinterpret_cast<const char *>(glGetStringi(GL_EXTENSIONS, i));
-
- m_offsets << m_extensions.size();
-
- while (*str != 0)
- m_extensions.append(*str++);
- m_extensions.append(' ');
- }
- }
- }
-}
-
-void QGLExtensionMatcher::init(const char *str)
-{
- m_extensions = str;
-
- // make sure extension string ends with a space
- if (!m_extensions.endsWith(' '))
- m_extensions.append(' ');
-
- int index = 0;
- int next = 0;
- while ((next = m_extensions.indexOf(' ', index)) >= 0) {
- m_offsets << index;
- index = next + 1;
- }
-}
-
-// ####TODO Properly #ifdef this class to use #define symbols actually defined
-// by OpenGL/ES includes
-#ifndef GL_FRAMEBUFFER_SRGB_CAPABLE_EXT
-#define GL_FRAMEBUFFER_SRGB_CAPABLE_EXT 0x8DBA
-#endif
-
-/*
- Returns the GL extensions for the current context.
-*/
-QGLExtensions::Extensions QGLExtensions::currentContextExtensions()
-{
- QGLExtensionMatcher extensions;
- Extensions glExtensions;
-
- if (extensions.match("GL_ARB_texture_rectangle"))
- glExtensions |= TextureRectangle;
- if (extensions.match("GL_ARB_multisample"))
- glExtensions |= SampleBuffers;
- if (extensions.match("GL_SGIS_generate_mipmap"))
- glExtensions |= GenerateMipmap;
- if (extensions.match("GL_ARB_texture_compression"))
- glExtensions |= TextureCompression;
- if (extensions.match("GL_EXT_texture_compression_s3tc"))
- glExtensions |= DDSTextureCompression;
- if (extensions.match("GL_OES_compressed_ETC1_RGB8_texture"))
- glExtensions |= ETC1TextureCompression;
- if (extensions.match("GL_IMG_texture_compression_pvrtc"))
- glExtensions |= PVRTCTextureCompression;
- if (extensions.match("GL_ARB_fragment_program"))
- glExtensions |= FragmentProgram;
- if (extensions.match("GL_ARB_fragment_shader"))
- glExtensions |= FragmentShader;
- if (extensions.match("GL_ARB_shader_objects"))
- glExtensions |= FragmentShader;
- if (extensions.match("GL_ARB_texture_mirrored_repeat"))
- glExtensions |= MirroredRepeat;
- if (extensions.match("GL_EXT_framebuffer_object"))
- glExtensions |= FramebufferObject;
- if (extensions.match("GL_EXT_stencil_two_side"))
- glExtensions |= StencilTwoSide;
- if (extensions.match("GL_EXT_stencil_wrap"))
- glExtensions |= StencilWrap;
- if (extensions.match("GL_EXT_packed_depth_stencil"))
- glExtensions |= PackedDepthStencil;
- if (extensions.match("GL_NV_float_buffer"))
- glExtensions |= NVFloatBuffer;
- if (extensions.match("GL_ARB_pixel_buffer_object"))
- glExtensions |= PixelBufferObject;
- if (extensions.match("GL_IMG_texture_format_BGRA8888"))
- glExtensions |= BGRATextureFormat;
-#if defined(QT_OPENGL_ES_2)
- glExtensions |= FramebufferObject;
- glExtensions |= GenerateMipmap;
- glExtensions |= FragmentShader;
-#endif
-#if defined(QT_OPENGL_ES)
- if (extensions.match("GL_OES_packed_depth_stencil"))
- glExtensions |= PackedDepthStencil;
- if (extensions.match("GL_OES_element_index_uint"))
- glExtensions |= ElementIndexUint;
- if (extensions.match("GL_OES_depth24"))
- glExtensions |= Depth24;
-#else
- glExtensions |= ElementIndexUint;
-#endif
- if (extensions.match("GL_ARB_framebuffer_object")) {
- // ARB_framebuffer_object also includes EXT_framebuffer_blit.
- glExtensions |= FramebufferObject;
- glExtensions |= FramebufferBlit;
- }
-
- if (extensions.match("GL_EXT_framebuffer_blit"))
- glExtensions |= FramebufferBlit;
-
- if (extensions.match("GL_ARB_texture_non_power_of_two"))
- glExtensions |= NPOTTextures;
-
- if (extensions.match("GL_EXT_bgra"))
- glExtensions |= BGRATextureFormat;
-
-#if !defined(QT_OPENGL_ES)
- {
- GLboolean srgbCapableFramebuffers = false;
- glGetBooleanv(GL_FRAMEBUFFER_SRGB_CAPABLE_EXT, &srgbCapableFramebuffers);
- if (srgbCapableFramebuffers)
- glExtensions |= SRGBFrameBuffer;
- }
-#endif
-
- return glExtensions;
-}
-
-
-class QGLDefaultExtensions
-{
-public:
- QGLDefaultExtensions() {
- QGLTemporaryContext tempContext;
- extensions = QGLExtensions::currentContextExtensions();
- }
-
- QGLExtensions::Extensions extensions;
-};
-
-Q_GLOBAL_STATIC(QGLDefaultExtensions, qtDefaultExtensions)
-
-/*
- Returns the GL extensions for the current QGLContext. If there is no
- current QGLContext, a default context will be created and the extensions
- for that context will be returned instead.
-*/
-QGLExtensions::Extensions QGLExtensions::glExtensions()
-{
- Extensions extensionFlags = 0;
- QGLContext *currentCtx = const_cast<QGLContext *>(QGLContext::currentContext());
-
- if (currentCtx && currentCtx->d_func()->extension_flags_cached)
- return currentCtx->d_func()->extension_flags;
-
- if (!currentCtx) {
- extensionFlags = qtDefaultExtensions()->extensions;
- } else {
- extensionFlags = currentContextExtensions();
- currentCtx->d_func()->extension_flags_cached = true;
- currentCtx->d_func()->extension_flags = extensionFlags;
- }
- return extensionFlags;
-}
-
/*
This is the shared initialization for all platforms. Called from QGLWidgetPrivate::init()
*/
@@ -5040,21 +4884,6 @@ QSize QGLTexture::bindCompressedTexture
// systems such as x86 and ARM at the moment.
return QSize();
}
-#if !defined(QT_OPENGL_ES)
- if (!glCompressedTexImage2D) {
- if (!(QGLExtensions::glExtensions() & QGLExtensions::TextureCompression)) {
- qWarning("QGLContext::bindTexture(): The GL implementation does "
- "not support texture compression extensions.");
- return QSize();
- }
- glCompressedTexImage2D = (_glCompressedTexImage2DARB) ctx->getProcAddress(QLatin1String("glCompressedTexImage2DARB"));
- if (!glCompressedTexImage2D) {
- qWarning("QGLContext::bindTexture(): could not resolve "
- "glCompressedTexImage2DARB.");
- return QSize();
- }
- }
-#endif
if (!format) {
// Auto-detect the format from the header.
if (len >= 4 && !qstrncmp(buf, "DDS ", 4))
@@ -5081,7 +4910,7 @@ QSize QGLTexture::bindCompressedTextureDDS(const char *buf, int len)
return QSize();
// Bail out if the necessary extension is not present.
- if (!(QGLExtensions::glExtensions() & QGLExtensions::DDSTextureCompression)) {
+ if (!qgl_extensions()->hasOpenGLExtension(QOpenGLExtensions::DDSTextureCompression)) {
qWarning("QGLContext::bindTexture(): DDS texture compression is not supported.");
return QSize();
}
@@ -5133,7 +4962,7 @@ QSize QGLTexture::bindCompressedTextureDDS(const char *buf, int len)
size = ((w+3)/4) * ((h+3)/4) * blockSize;
if (size > available)
break;
- glCompressedTexImage2D(GL_TEXTURE_2D, i, format, w, h, 0,
+ qgl_extensions()->glCompressedTexImage2D(GL_TEXTURE_2D, i, format, w, h, 0,
size, pixels + offset);
offset += size;
available -= size;
@@ -5191,14 +5020,12 @@ QSize QGLTexture::bindCompressedTexturePVR(const char *buf, int len)
// Bail out if the necessary extension is not present.
if (textureFormat == GL_ETC1_RGB8_OES) {
- if (!(QGLExtensions::glExtensions() &
- QGLExtensions::ETC1TextureCompression)) {
+ if (!qgl_extensions()->hasOpenGLExtension(QOpenGLExtensions::ETC1TextureCompression)) {
qWarning("QGLContext::bindTexture(): ETC1 texture compression is not supported.");
return QSize();
}
} else {
- if (!(QGLExtensions::glExtensions() &
- QGLExtensions::PVRTCTextureCompression)) {
+ if (!qgl_extensions()->hasOpenGLExtension(QOpenGLExtensions::PVRTCTextureCompression)) {
qWarning("QGLContext::bindTexture(): PVRTC texture compression is not supported.");
return QSize();
}
@@ -5244,7 +5071,7 @@ QSize QGLTexture::bindCompressedTexturePVR(const char *buf, int len)
pvrHeader->bitsPerPixel) / 8;
if (size > bufferSize)
break;
- glCompressedTexImage2D(GL_TEXTURE_2D, GLint(level), textureFormat,
+ qgl_extensions()->glCompressedTexImage2D(GL_TEXTURE_2D, GLint(level), textureFormat,
GLsizei(width), GLsizei(height), 0,
GLsizei(size), buffer);
width /= 2;
diff --git a/src/opengl/qgl.h b/src/opengl/qgl.h
index 2fc21cb501..72fe7b8da6 100644
--- a/src/opengl/qgl.h
+++ b/src/opengl/qgl.h
@@ -53,7 +53,6 @@
#include <QtGui/QSurfaceFormat>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
@@ -344,7 +343,6 @@ private:
friend struct QGLGlyphTexture;
friend class QGLContextGroup;
friend class QGLPixmapBlurFilter;
- friend class QGLExtensions;
friend class QGLTexture;
friend QGLFormat::OpenGLVersionFlags QGLFormat::openGLVersionFlags();
friend class QGLFramebufferObject;
@@ -525,7 +523,5 @@ inline bool QGLFormat::sampleBuffers() const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_OPENGL
#endif // QGL_H
diff --git a/src/opengl/qgl_p.h b/src/opengl/qgl_p.h
index 5fd870beee..9a58beb3d7 100644
--- a/src/opengl/qgl_p.h
+++ b/src/opengl/qgl_p.h
@@ -62,17 +62,18 @@
#include "QtCore/qatomic.h"
#include "QtWidgets/private/qwidget_p.h"
#include "QtGui/private/qopenglcontext_p.h"
+#include "QtGui/private/qopenglextensions_p.h"
#include "qcache.h"
#include "qglpaintdevice_p.h"
#include <QtGui/QOpenGLContext>
-#include <QtOpenGL/private/qglextensions_p.h>
QT_BEGIN_NAMESPACE
class QGLContext;
class QGLOverlayWidget;
class QPixmap;
+class QOpenGLExtensions;
class QGLFormatPrivate
{
@@ -162,7 +163,6 @@ class QGLContextGroup
public:
~QGLContextGroup();
- QGLExtensionFuncs &extensionFuncs() {return m_extensionFuncs;}
const QGLContext *context() const {return m_context;}
bool isSharing() const { return m_shares.size() >= 2; }
QList<const QGLContext *> shares() const { return m_shares; }
@@ -173,7 +173,6 @@ public:
private:
QGLContextGroup(const QGLContext *context);
- QGLExtensionFuncs m_extensionFuncs;
const QGLContext *m_context; // context group's representative
QList<const QGLContext *> m_shares;
QAtomicInt m_refs;
@@ -187,39 +186,6 @@ private:
// "ctx" is destroyed. Returns null if nothing is sharing with ctx.
const QGLContext *qt_gl_transfer_context(const QGLContext *);
-// GL extension definitions
-class QGLExtensions {
-public:
- enum Extension {
- TextureRectangle = 0x00000001,
- SampleBuffers = 0x00000002,
- GenerateMipmap = 0x00000004,
- TextureCompression = 0x00000008,
- FragmentProgram = 0x00000010,
- MirroredRepeat = 0x00000020,
- FramebufferObject = 0x00000040,
- StencilTwoSide = 0x00000080,
- StencilWrap = 0x00000100,
- PackedDepthStencil = 0x00000200,
- NVFloatBuffer = 0x00000400,
- PixelBufferObject = 0x00000800,
- FramebufferBlit = 0x00001000,
- NPOTTextures = 0x00002000,
- BGRATextureFormat = 0x00004000,
- DDSTextureCompression = 0x00008000,
- ETC1TextureCompression = 0x00010000,
- PVRTCTextureCompression = 0x00020000,
- FragmentShader = 0x00040000,
- ElementIndexUint = 0x00080000,
- Depth24 = 0x00100000,
- SRGBFrameBuffer = 0x00200000
- };
- Q_DECLARE_FLAGS(Extensions, Extension)
-
- static Extensions glExtensions();
- static Extensions currentContextExtensions();
-};
-
/*
QGLTemporaryContext - the main objective of this class is to have a way of
creating a GL context and making it current, without going via QGLWidget
@@ -265,7 +231,6 @@ public:
QGLContext::BindOptions options);
QGLTexture *textureCacheLookup(const qint64 key, GLenum target);
void init(QPaintDevice *dev, const QGLFormat &format);
- QImage convertToGLFormat(const QImage &image, bool force_premul, GLenum texture_format);
int maxTextureSize();
void cleanup();
@@ -289,7 +254,6 @@ public:
uint crWin : 1;
uint internal_context : 1;
uint version_flags_cached : 1;
- uint extension_flags_cached : 1;
// workarounds for driver/hw bugs on different platforms
uint workaround_needsFullClearOnEveryFrame : 1;
@@ -307,7 +271,6 @@ public:
QColor transpColor;
QGLContext *q_ptr;
QGLFormat::OpenGLVersionFlags version_flags;
- QGLExtensions::Extensions extension_flags;
QGLContextGroup *group;
GLint max_texture_size;
@@ -323,14 +286,9 @@ public:
static inline QGLContextGroup *contextGroup(const QGLContext *ctx) { return ctx->d_ptr->group; }
- static Q_OPENGL_EXPORT QGLExtensionFuncs qt_extensionFuncs;
- static Q_OPENGL_EXPORT QGLExtensionFuncs& extensionFuncs(const QGLContext *);
-
static void setCurrentContext(QGLContext *context);
};
-Q_DECLARE_OPERATORS_FOR_FLAGS(QGLExtensions::Extensions)
-
// Temporarily make a context current if not already current or
// shared with the current contex. The previous context is made
// current when the object goes out of scope.
@@ -511,6 +469,10 @@ QGLTexture* QGLTextureCache::getTexture(QGLContext *ctx, qint64 key)
Q_OPENGL_EXPORT extern QPaintEngine* qt_qgl_paint_engine();
+QOpenGLExtensions* qgl_extensions();
+bool qgl_hasFeature(QOpenGLFunctions::OpenGLFeature feature);
+bool qgl_hasExtension(QOpenGLExtensions::OpenGLExtension extension);
+
// Put a guard around a GL object identifier and its context.
// When the context goes away, a shared context will be used
// in its place. If there are no more shared contexts, then
@@ -575,35 +537,6 @@ QGLSharedResourceGuardBase *createSharedResourceGuard(QGLContext *context, GLuin
return new QGLSharedResourceGuard<Func>(context, id, cleanupFunc);
}
-class QGLExtensionMatcher
-{
-public:
- QGLExtensionMatcher(const char *str);
- QGLExtensionMatcher();
-
- bool match(const char *str) const {
- int str_length = qstrlen(str);
-
- Q_ASSERT(str);
- Q_ASSERT(str_length > 0);
- Q_ASSERT(str[str_length-1] != ' ');
-
- for (int i = 0; i < m_offsets.size(); ++i) {
- const char *extension = m_extensions.constData() + m_offsets.at(i);
- if (qstrncmp(extension, str, str_length) == 0 && extension[str_length] == ' ')
- return true;
- }
- return false;
- }
-
-private:
- void init(const char *str);
-
- QByteArray m_extensions;
- QVector<int> m_offsets;
-};
-
-
// this is a class that wraps a QThreadStorage object for storing
// thread local instances of the GL 1 and GL 2 paint engines
diff --git a/src/opengl/qglbuffer.cpp b/src/opengl/qglbuffer.cpp
index 425e8cff09..e10bc010c5 100644
--- a/src/opengl/qglbuffer.cpp
+++ b/src/opengl/qglbuffer.cpp
@@ -41,7 +41,7 @@
#include <QtOpenGL/qgl.h>
#include <QtOpenGL/private/qgl_p.h>
-#include <QtOpenGL/private/qglextensions_p.h>
+#include <private/qopenglextensions_p.h>
#include <QtCore/qatomic.h>
#include "qglbuffer.h"
@@ -139,7 +139,8 @@ public:
type(t),
guard(0),
usagePattern(QGLBuffer::StaticDraw),
- actualUsagePattern(QGLBuffer::StaticDraw)
+ actualUsagePattern(QGLBuffer::StaticDraw),
+ funcs(0)
{
}
@@ -148,6 +149,7 @@ public:
QGLSharedResourceGuardBase *guard;
QGLBuffer::UsagePattern usagePattern;
QGLBuffer::UsagePattern actualUsagePattern;
+ QOpenGLExtensions *funcs;
};
/*!
@@ -259,8 +261,8 @@ void QGLBuffer::setUsagePattern(QGLBuffer::UsagePattern value)
namespace {
void freeBufferFunc(QGLContext *ctx, GLuint id)
{
- Q_UNUSED(ctx);
- glDeleteBuffers(1, &id);
+ Q_ASSERT(ctx);
+ ctx->contextHandle()->functions()->glDeleteBuffers(1, &id);
}
}
@@ -284,10 +286,13 @@ bool QGLBuffer::create()
return true;
QGLContext *ctx = const_cast<QGLContext *>(QGLContext::currentContext());
if (ctx) {
- if (!qt_resolve_buffer_extensions(ctx))
+ delete d->funcs;
+ d->funcs = new QOpenGLExtensions(ctx->contextHandle());
+ if (!d->funcs->hasOpenGLFeature(QOpenGLFunctions::Buffers))
return false;
+
GLuint bufferId = 0;
- glGenBuffers(1, &bufferId);
+ d->funcs->glGenBuffers(1, &bufferId);
if (bufferId) {
if (d->guard)
d->guard->free();
@@ -340,10 +345,10 @@ bool QGLBuffer::read(int offset, void *data, int count)
{
#if !defined(QT_OPENGL_ES)
Q_D(QGLBuffer);
- if (!glGetBufferSubData || !d->guard->id())
+ if (!d->funcs->hasOpenGLFeature(QOpenGLFunctions::Buffers) || !d->guard->id())
return false;
while (glGetError() != GL_NO_ERROR) ; // Clear error state.
- glGetBufferSubData(d->type, offset, count, data);
+ d->funcs->glGetBufferSubData(d->type, offset, count, data);
return glGetError() == GL_NO_ERROR;
#else
Q_UNUSED(offset);
@@ -371,7 +376,7 @@ void QGLBuffer::write(int offset, const void *data, int count)
#endif
Q_D(QGLBuffer);
if (d->guard && d->guard->id())
- glBufferSubData(d->type, offset, count, data);
+ d->funcs->glBufferSubData(d->type, offset, count, data);
}
/*!
@@ -391,7 +396,7 @@ void QGLBuffer::allocate(const void *data, int count)
#endif
Q_D(QGLBuffer);
if (d->guard && d->guard->id())
- glBufferData(d->type, count, data, d->actualUsagePattern);
+ d->funcs->glBufferData(d->type, count, data, d->actualUsagePattern);
}
/*!
@@ -433,7 +438,7 @@ bool QGLBuffer::bind()
#endif
return false;
}
- glBindBuffer(d->type, bufferId);
+ d->funcs->glBindBuffer(d->type, bufferId);
return true;
} else {
return false;
@@ -457,7 +462,7 @@ void QGLBuffer::release()
#endif
Q_D(const QGLBuffer);
if (d->guard && d->guard->id())
- glBindBuffer(d->type, 0);
+ d->funcs->glBindBuffer(d->type, 0);
}
#undef ctx
@@ -477,9 +482,8 @@ void QGLBuffer::release()
*/
void QGLBuffer::release(QGLBuffer::Type type)
{
- const QGLContext *ctx = QGLContext::currentContext();
- if (ctx && qt_resolve_buffer_extensions(const_cast<QGLContext *>(ctx)))
- glBindBuffer(GLenum(type), 0);
+ if (QOpenGLContext *ctx = QOpenGLContext::currentContext())
+ ctx->functions()->glBindBuffer(GLenum(type), 0);
}
#define ctx QGLContext::currentContext()
@@ -515,7 +519,7 @@ int QGLBuffer::size() const
if (!d->guard || !d->guard->id())
return -1;
GLint value = -1;
- glGetBufferParameteriv(d->type, GL_BUFFER_SIZE, &value);
+ d->funcs->glGetBufferParameteriv(d->type, GL_BUFFER_SIZE, &value);
return value;
}
@@ -542,9 +546,7 @@ void *QGLBuffer::map(QGLBuffer::Access access)
#endif
if (!d->guard || !d->guard->id())
return 0;
- if (!glMapBufferARB)
- return 0;
- return glMapBufferARB(d->type, access);
+ return d->funcs->glMapBuffer(d->type, access);
}
/*!
@@ -569,9 +571,7 @@ bool QGLBuffer::unmap()
#endif
if (!d->guard || !d->guard->id())
return false;
- if (!glUnmapBufferARB)
- return false;
- return glUnmapBufferARB(d->type) == GL_TRUE;
+ return d->funcs->glUnmapBuffer(d->type) == GL_TRUE;
}
QT_END_NAMESPACE
diff --git a/src/opengl/qglbuffer.h b/src/opengl/qglbuffer.h
index 0a60b01840..2c26c7a0b2 100644
--- a/src/opengl/qglbuffer.h
+++ b/src/opengl/qglbuffer.h
@@ -45,8 +45,6 @@
#include <QtCore/qscopedpointer.h>
#include <QtOpenGL/qgl.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -126,6 +124,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/opengl/qglcolormap.h b/src/opengl/qglcolormap.h
index aa29aead6e..ecca5aa6b7 100644
--- a/src/opengl/qglcolormap.h
+++ b/src/opengl/qglcolormap.h
@@ -46,8 +46,6 @@
#include <QtCore/qvector.h>
#include <QtOpenGL/qtopenglglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -100,6 +98,4 @@ inline void QGLColormap::detach()
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGLCOLORMAP_H
diff --git a/src/opengl/qglextensions.cpp b/src/opengl/qglextensions.cpp
deleted file mode 100644
index 32304ca3bb..0000000000
--- a/src/opengl/qglextensions.cpp
+++ /dev/null
@@ -1,414 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
-**
-** This file is part of the QtOpenGL module of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and Digia. For licensing terms and
-** conditions see http://qt.digia.com/licensing. For further information
-** use the contact form at http://qt.digia.com/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 2.1 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-**
-** In addition, as a special exception, Digia gives you certain additional
-** rights. These rights are described in the Digia Qt LGPL Exception
-** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3.0 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU General Public License version 3.0 requirements will be
-** met: http://www.gnu.org/copyleft/gpl.html.
-**
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include "qgl_p.h"
-#include <qglframebufferobject.h>
-
-QT_BEGIN_NAMESPACE
-
-static QFunctionPointer qt_gl_getProcAddress_search
- (QGLContext *ctx, const char *name1, const char *name2,
- const char *name3, const char *name4)
-{
- QFunctionPointer addr = ctx->getProcAddress(QLatin1String(name1));
- if (addr)
- return addr;
-
- addr = ctx->getProcAddress(QLatin1String(name2));
- if (addr)
- return addr;
-
- addr = ctx->getProcAddress(QLatin1String(name3));
- if (addr)
- return addr;
-
- if (name4)
- return ctx->getProcAddress(QLatin1String(name4));
-
- return 0;
-}
-
-// Search for an extension function starting with the most likely
-// function suffix first, and then trying the other variations.
-#if defined(QT_OPENGL_ES)
-#define qt_gl_getProcAddress(ctx,name) \
- qt_gl_getProcAddress_search((ctx), name, name "OES", name "EXT", name "ARB")
-#define qt_gl_getProcAddressEXT(ctx,name) \
- qt_gl_getProcAddress_search((ctx), name "OES", name, name "EXT", name "ARB")
-#define qt_gl_getProcAddressARB(ctx,name) \
- qt_gl_getProcAddress_search((ctx), name "OES", name, name "ARB", name "EXT")
-#define qt_gl_getProcAddressOES(ctx,name) \
- qt_gl_getProcAddress_search((ctx), name "OES", name, name "EXT", name "ARB")
-#else
-#define qt_gl_getProcAddress(ctx,name) \
- qt_gl_getProcAddress_search((ctx), name, name "ARB", name "EXT", 0)
-#define qt_gl_getProcAddressEXT(ctx,name) \
- qt_gl_getProcAddress_search((ctx), name "EXT", name, name "ARB", 0)
-#define qt_gl_getProcAddressARB(ctx,name) \
- qt_gl_getProcAddress_search((ctx), name "ARB", name, name "EXT", 0)
-#define qt_gl_getProcAddressOES(ctx,name) \
- qt_gl_getProcAddress_search((ctx), name "OES", name, name "EXT", name "ARB")
-#endif
-
-bool qt_resolve_framebufferobject_extensions(QGLContext *ctx)
-{
-#if defined(QT_OPENGL_ES_2)
- static bool have_resolved = false;
- if (have_resolved)
- return true;
- have_resolved = true;
-#else
- if (glIsRenderbuffer != 0)
- return true;
-#endif
-
- if (ctx == 0) {
- qWarning("QGLFramebufferObject: Unable to resolve framebuffer object extensions -"
- " make sure there is a current context when creating the framebuffer object.");
- return false;
- }
-
-
- glBlitFramebufferEXT = (_glBlitFramebufferEXT) qt_gl_getProcAddressEXT(ctx, "glBlitFramebuffer");
- glRenderbufferStorageMultisampleEXT =
- (_glRenderbufferStorageMultisampleEXT) qt_gl_getProcAddressEXT(ctx, "glRenderbufferStorageMultisample");
-
-#if !defined(QT_OPENGL_ES_2)
- glIsRenderbuffer = (_glIsRenderbuffer) qt_gl_getProcAddressEXT(ctx, "glIsRenderbuffer");
- if (!glIsRenderbuffer)
- return false; // Not much point searching for anything else.
- glBindRenderbuffer = (_glBindRenderbuffer) qt_gl_getProcAddressEXT(ctx, "glBindRenderbuffer");
- glDeleteRenderbuffers = (_glDeleteRenderbuffers) qt_gl_getProcAddressEXT(ctx, "glDeleteRenderbuffers");
- glGenRenderbuffers = (_glGenRenderbuffers) qt_gl_getProcAddressEXT(ctx, "glGenRenderbuffers");
- glRenderbufferStorage = (_glRenderbufferStorage) qt_gl_getProcAddressEXT(ctx, "glRenderbufferStorage");
- glGetRenderbufferParameteriv =
- (_glGetRenderbufferParameteriv) qt_gl_getProcAddressEXT(ctx, "glGetRenderbufferParameteriv");
- glIsFramebuffer = (_glIsFramebuffer) qt_gl_getProcAddressEXT(ctx, "glIsFramebuffer");
- glBindFramebuffer = (_glBindFramebuffer) qt_gl_getProcAddressEXT(ctx, "glBindFramebuffer");
- glDeleteFramebuffers = (_glDeleteFramebuffers) qt_gl_getProcAddressEXT(ctx, "glDeleteFramebuffers");
- glGenFramebuffers = (_glGenFramebuffers) qt_gl_getProcAddressEXT(ctx, "glGenFramebuffers");
- glCheckFramebufferStatus = (_glCheckFramebufferStatus) qt_gl_getProcAddressEXT(ctx, "glCheckFramebufferStatus");
- glFramebufferTexture2D = (_glFramebufferTexture2D) qt_gl_getProcAddressEXT(ctx, "glFramebufferTexture2D");
- glFramebufferRenderbuffer = (_glFramebufferRenderbuffer) qt_gl_getProcAddressEXT(ctx, "glFramebufferRenderbuffer");
- glGetFramebufferAttachmentParameteriv =
- (_glGetFramebufferAttachmentParameteriv) qt_gl_getProcAddressEXT(ctx, "glGetFramebufferAttachmentParameteriv");
- glGenerateMipmap = (_glGenerateMipmap) qt_gl_getProcAddressEXT(ctx, "glGenerateMipmap");
-
- return glIsRenderbuffer != 0;
-#else
- return true;
-#endif
-}
-
-#if !defined(QT_OPENGL_ES_2)
-bool qt_resolve_version_1_3_functions(QGLContext *ctx)
-{
- if (glMultiTexCoord4f != 0)
- return true;
-
- QGLContext cx(QGLFormat::defaultFormat());
- glMultiTexCoord4f = (_glMultiTexCoord4f) ctx->getProcAddress(QLatin1String("glMultiTexCoord4f"));
-
- glActiveTexture = (_glActiveTexture) ctx->getProcAddress(QLatin1String("glActiveTexture"));
- return glMultiTexCoord4f && glActiveTexture;
-}
-#endif
-
-#if !defined(QT_OPENGL_ES_2)
-bool qt_resolve_stencil_face_extension(QGLContext *ctx)
-{
- if (glActiveStencilFaceEXT != 0)
- return true;
-
- QGLContext cx(QGLFormat::defaultFormat());
- glActiveStencilFaceEXT = (_glActiveStencilFaceEXT) ctx->getProcAddress(QLatin1String("glActiveStencilFaceEXT"));
-
- return glActiveStencilFaceEXT;
-}
-#endif
-
-
-#if !defined(QT_OPENGL_ES_2)
-bool qt_resolve_frag_program_extensions(QGLContext *ctx)
-{
- if (glProgramStringARB != 0)
- return true;
-
- // ARB_fragment_program
- glProgramStringARB = (_glProgramStringARB) ctx->getProcAddress(QLatin1String("glProgramStringARB"));
- glBindProgramARB = (_glBindProgramARB) ctx->getProcAddress(QLatin1String("glBindProgramARB"));
- glDeleteProgramsARB = (_glDeleteProgramsARB) ctx->getProcAddress(QLatin1String("glDeleteProgramsARB"));
- glGenProgramsARB = (_glGenProgramsARB) ctx->getProcAddress(QLatin1String("glGenProgramsARB"));
- glProgramLocalParameter4fvARB = (_glProgramLocalParameter4fvARB) ctx->getProcAddress(QLatin1String("glProgramLocalParameter4fvARB"));
-
- return glProgramStringARB
- && glBindProgramARB
- && glDeleteProgramsARB
- && glGenProgramsARB
- && glProgramLocalParameter4fvARB;
-}
-#endif
-
-
-bool qt_resolve_buffer_extensions(QGLContext *ctx)
-{
-#if defined(QGL_RESOLVE_BUFFER_FUNCS)
- if (glBindBuffer && glDeleteBuffers && glGenBuffers && glBufferData
- && glBufferSubData && glGetBufferParameteriv)
- return true;
-#endif
-
-#if defined(QGL_RESOLVE_BUFFER_FUNCS)
- glBindBuffer = (_glBindBuffer) qt_gl_getProcAddressARB(ctx, "glBindBuffer");
- glDeleteBuffers = (_glDeleteBuffers) qt_gl_getProcAddressARB(ctx, "glDeleteBuffers");
- glGenBuffers = (_glGenBuffers) qt_gl_getProcAddressARB(ctx, "glGenBuffers");
- glBufferData = (_glBufferData) qt_gl_getProcAddressARB(ctx, "glBufferData");
- glBufferSubData = (_glBufferSubData) qt_gl_getProcAddressARB(ctx, "glBufferSubData");
- glGetBufferSubData = (_glGetBufferSubData) qt_gl_getProcAddressARB(ctx, "glGetBufferSubData");
- glGetBufferParameteriv = (_glGetBufferParameteriv) qt_gl_getProcAddressARB(ctx, "glGetBufferParameteriv");
-#endif
- glMapBufferARB = (_glMapBufferARB) qt_gl_getProcAddressARB(ctx, "glMapBuffer");
- glUnmapBufferARB = (_glUnmapBufferARB) qt_gl_getProcAddressARB(ctx, "glUnmapBuffer");
-
-#if defined(QGL_RESOLVE_BUFFER_FUNCS)
- return glBindBuffer
- && glDeleteBuffers
- && glGenBuffers
- && glBufferData
- && glBufferSubData
- && glGetBufferParameteriv;
- // glGetBufferSubData() is optional
-#else
- return true;
-#endif
-}
-
-bool qt_resolve_glsl_extensions(QGLContext *ctx)
-{
-
-#if defined(QT_OPENGL_ES_2)
- // The GLSL shader functions are always present in OpenGL/ES 2.0.
- // The only exceptions are glGetProgramBinaryOES and glProgramBinaryOES.
- if (!QGLContextPrivate::extensionFuncs(ctx).qt_glslResolved) {
- glGetProgramBinaryOES = (_glGetProgramBinaryOES) ctx->getProcAddress(QLatin1String("glGetProgramBinaryOES"));
- glProgramBinaryOES = (_glProgramBinaryOES) ctx->getProcAddress(QLatin1String("glProgramBinaryOES"));
- QGLContextPrivate::extensionFuncs(ctx).qt_glslResolved = true;
- }
- return true;
-#else
- if (glCreateShader)
- return true;
-
- // Geometry shaders are optional...
- glProgramParameteriEXT = (_glProgramParameteriEXT) ctx->getProcAddress(QLatin1String("glProgramParameteriEXT"));
- glFramebufferTextureEXT = (_glFramebufferTextureEXT) ctx->getProcAddress(QLatin1String("glFramebufferTextureEXT"));
- glFramebufferTextureLayerEXT = (_glFramebufferTextureLayerEXT) ctx->getProcAddress(QLatin1String("glFramebufferTextureLayerEXT"));
- glFramebufferTextureFaceEXT = (_glFramebufferTextureFaceEXT) ctx->getProcAddress(QLatin1String("glFramebufferTextureFaceEXT"));
-
- // Must at least have the FragmentShader extension to continue.
- if (!(QGLExtensions::glExtensions() & QGLExtensions::FragmentShader))
- return false;
-
- glCreateShader = (_glCreateShader) ctx->getProcAddress(QLatin1String("glCreateShader"));
- if (glCreateShader) {
- glShaderSource = (_glShaderSource) ctx->getProcAddress(QLatin1String("glShaderSource"));
- glShaderBinary = (_glShaderBinary) ctx->getProcAddress(QLatin1String("glShaderBinary"));
- glCompileShader = (_glCompileShader) ctx->getProcAddress(QLatin1String("glCompileShader"));
- glDeleteShader = (_glDeleteShader) ctx->getProcAddress(QLatin1String("glDeleteShader"));
- glIsShader = (_glIsShader) ctx->getProcAddress(QLatin1String("glIsShader"));
-
- glCreateProgram = (_glCreateProgram) ctx->getProcAddress(QLatin1String("glCreateProgram"));
- glAttachShader = (_glAttachShader) ctx->getProcAddress(QLatin1String("glAttachShader"));
- glDetachShader = (_glDetachShader) ctx->getProcAddress(QLatin1String("glDetachShader"));
- glLinkProgram = (_glLinkProgram) ctx->getProcAddress(QLatin1String("glLinkProgram"));
- glUseProgram = (_glUseProgram) ctx->getProcAddress(QLatin1String("glUseProgram"));
- glDeleteProgram = (_glDeleteProgram) ctx->getProcAddress(QLatin1String("glDeleteProgram"));
- glIsProgram = (_glIsProgram) ctx->getProcAddress(QLatin1String("glIsProgram"));
-
- glGetShaderInfoLog = (_glGetShaderInfoLog) ctx->getProcAddress(QLatin1String("glGetShaderInfoLog"));
- glGetShaderiv = (_glGetShaderiv) ctx->getProcAddress(QLatin1String("glGetShaderiv"));
- glGetShaderSource = (_glGetShaderSource) ctx->getProcAddress(QLatin1String("glGetShaderSource"));
- glGetProgramiv = (_glGetProgramiv) ctx->getProcAddress(QLatin1String("glGetProgramiv"));
- glGetProgramInfoLog = (_glGetProgramInfoLog) ctx->getProcAddress(QLatin1String("glGetProgramInfoLog"));
-
- glGetUniformLocation = (_glGetUniformLocation) ctx->getProcAddress(QLatin1String("glGetUniformLocation"));
- glUniform4fv = (_glUniform4fv) ctx->getProcAddress(QLatin1String("glUniform4fv"));
- glUniform3fv = (_glUniform3fv) ctx->getProcAddress(QLatin1String("glUniform3fv"));
- glUniform2fv = (_glUniform2fv) ctx->getProcAddress(QLatin1String("glUniform2fv"));
- glUniform1fv = (_glUniform1fv) ctx->getProcAddress(QLatin1String("glUniform1fv"));
- glUniform1i = (_glUniform1i) ctx->getProcAddress(QLatin1String("glUniform1i"));
- glUniform1iv = (_glUniform1iv) ctx->getProcAddress(QLatin1String("glUniform1iv"));
- glUniformMatrix2fv = (_glUniformMatrix2fv) ctx->getProcAddress(QLatin1String("glUniformMatrix2fv"));
- glUniformMatrix3fv = (_glUniformMatrix3fv) ctx->getProcAddress(QLatin1String("glUniformMatrix3fv"));
- glUniformMatrix4fv = (_glUniformMatrix4fv) ctx->getProcAddress(QLatin1String("glUniformMatrix4fv"));
- glUniformMatrix2x3fv = (_glUniformMatrix2x3fv) ctx->getProcAddress(QLatin1String("glUniformMatrix2x3fv"));
- glUniformMatrix2x4fv = (_glUniformMatrix2x4fv) ctx->getProcAddress(QLatin1String("glUniformMatrix2x4fv"));
- glUniformMatrix3x2fv = (_glUniformMatrix3x2fv) ctx->getProcAddress(QLatin1String("glUniformMatrix3x2fv"));
- glUniformMatrix3x4fv = (_glUniformMatrix3x4fv) ctx->getProcAddress(QLatin1String("glUniformMatrix3x4fv"));
- glUniformMatrix4x2fv = (_glUniformMatrix4x2fv) ctx->getProcAddress(QLatin1String("glUniformMatrix4x2fv"));
- glUniformMatrix4x3fv = (_glUniformMatrix4x3fv) ctx->getProcAddress(QLatin1String("glUniformMatrix4x3fv"));
-
- glBindAttribLocation = (_glBindAttribLocation) ctx->getProcAddress(QLatin1String("glBindAttribLocation"));
- glGetAttribLocation = (_glGetAttribLocation) ctx->getProcAddress(QLatin1String("glGetAttribLocation"));
- glVertexAttrib1fv = (_glVertexAttrib1fv) ctx->getProcAddress(QLatin1String("glVertexAttrib1fv"));
- glVertexAttrib2fv = (_glVertexAttrib2fv) ctx->getProcAddress(QLatin1String("glVertexAttrib2fv"));
- glVertexAttrib3fv = (_glVertexAttrib3fv) ctx->getProcAddress(QLatin1String("glVertexAttrib3fv"));
- glVertexAttrib4fv = (_glVertexAttrib4fv) ctx->getProcAddress(QLatin1String("glVertexAttrib4fv"));
- glVertexAttribPointer = (_glVertexAttribPointer) ctx->getProcAddress(QLatin1String("glVertexAttribPointer"));
- glDisableVertexAttribArray = (_glDisableVertexAttribArray) ctx->getProcAddress(QLatin1String("glDisableVertexAttribArray"));
- glEnableVertexAttribArray = (_glEnableVertexAttribArray) ctx->getProcAddress(QLatin1String("glEnableVertexAttribArray"));
-
- } else {
- // We may not have the standard shader functions, but we might
- // have the older ARB functions instead.
- glCreateShader = (_glCreateShader) ctx->getProcAddress(QLatin1String("glCreateShaderObjectARB"));
- glShaderSource = (_glShaderSource) ctx->getProcAddress(QLatin1String("glShaderSourceARB"));
- glShaderBinary = (_glShaderBinary) ctx->getProcAddress(QLatin1String("glShaderBinaryARB"));
- glCompileShader = (_glCompileShader) ctx->getProcAddress(QLatin1String("glCompileShaderARB"));
- glDeleteShader = (_glDeleteShader) ctx->getProcAddress(QLatin1String("glDeleteObjectARB"));
- glIsShader = 0;
-
- glCreateProgram = (_glCreateProgram) ctx->getProcAddress(QLatin1String("glCreateProgramObjectARB"));
- glAttachShader = (_glAttachShader) ctx->getProcAddress(QLatin1String("glAttachObjectARB"));
- glDetachShader = (_glDetachShader) ctx->getProcAddress(QLatin1String("glDetachObjectARB"));
- glLinkProgram = (_glLinkProgram) ctx->getProcAddress(QLatin1String("glLinkProgramARB"));
- glUseProgram = (_glUseProgram) ctx->getProcAddress(QLatin1String("glUseProgramObjectARB"));
- glDeleteProgram = (_glDeleteProgram) ctx->getProcAddress(QLatin1String("glDeleteObjectARB"));
- glIsProgram = 0;
-
- glGetShaderInfoLog = (_glGetShaderInfoLog) ctx->getProcAddress(QLatin1String("glGetInfoLogARB"));
- glGetShaderiv = (_glGetShaderiv) ctx->getProcAddress(QLatin1String("glGetObjectParameterivARB"));
- glGetShaderSource = (_glGetShaderSource) ctx->getProcAddress(QLatin1String("glGetShaderSourceARB"));
- glGetProgramiv = (_glGetProgramiv) ctx->getProcAddress(QLatin1String("glGetObjectParameterivARB"));
- glGetProgramInfoLog = (_glGetProgramInfoLog) ctx->getProcAddress(QLatin1String("glGetInfoLogARB"));
-
- glGetUniformLocation = (_glGetUniformLocation) ctx->getProcAddress(QLatin1String("glGetUniformLocationARB"));
- glUniform4fv = (_glUniform4fv) ctx->getProcAddress(QLatin1String("glUniform4fvARB"));
- glUniform3fv = (_glUniform3fv) ctx->getProcAddress(QLatin1String("glUniform3fvARB"));
- glUniform2fv = (_glUniform2fv) ctx->getProcAddress(QLatin1String("glUniform2fvARB"));
- glUniform1fv = (_glUniform1fv) ctx->getProcAddress(QLatin1String("glUniform1fvARB"));
- glUniform1i = (_glUniform1i) ctx->getProcAddress(QLatin1String("glUniform1iARB"));
- glUniform1iv = (_glUniform1iv) ctx->getProcAddress(QLatin1String("glUniform1ivARB"));
- glUniformMatrix2fv = (_glUniformMatrix2fv) ctx->getProcAddress(QLatin1String("glUniformMatrix2fvARB"));
- glUniformMatrix3fv = (_glUniformMatrix3fv) ctx->getProcAddress(QLatin1String("glUniformMatrix3fvARB"));
- glUniformMatrix4fv = (_glUniformMatrix4fv) ctx->getProcAddress(QLatin1String("glUniformMatrix4fvARB"));
- glUniformMatrix2x3fv = (_glUniformMatrix2x3fv) ctx->getProcAddress(QLatin1String("glUniformMatrix2x3fvARB"));
- glUniformMatrix2x4fv = (_glUniformMatrix2x4fv) ctx->getProcAddress(QLatin1String("glUniformMatrix2x4fvARB"));
- glUniformMatrix3x2fv = (_glUniformMatrix3x2fv) ctx->getProcAddress(QLatin1String("glUniformMatrix3x2fvARB"));
- glUniformMatrix3x4fv = (_glUniformMatrix3x4fv) ctx->getProcAddress(QLatin1String("glUniformMatrix3x4fvARB"));
- glUniformMatrix4x2fv = (_glUniformMatrix4x2fv) ctx->getProcAddress(QLatin1String("glUniformMatrix4x2fvARB"));
- glUniformMatrix4x3fv = (_glUniformMatrix4x3fv) ctx->getProcAddress(QLatin1String("glUniformMatrix4x3fvARB"));
-
- glBindAttribLocation = (_glBindAttribLocation) ctx->getProcAddress(QLatin1String("glBindAttribLocationARB"));
- glGetAttribLocation = (_glGetAttribLocation) ctx->getProcAddress(QLatin1String("glGetAttribLocationARB"));
- glVertexAttrib1fv = (_glVertexAttrib1fv) ctx->getProcAddress(QLatin1String("glVertexAttrib1fvARB"));
- glVertexAttrib2fv = (_glVertexAttrib2fv) ctx->getProcAddress(QLatin1String("glVertexAttrib2fvARB"));
- glVertexAttrib3fv = (_glVertexAttrib3fv) ctx->getProcAddress(QLatin1String("glVertexAttrib3fvARB"));
- glVertexAttrib4fv = (_glVertexAttrib4fv) ctx->getProcAddress(QLatin1String("glVertexAttrib4fvARB"));
- glVertexAttribPointer = (_glVertexAttribPointer) ctx->getProcAddress(QLatin1String("glVertexAttribPointerARB"));
- glDisableVertexAttribArray = (_glDisableVertexAttribArray) ctx->getProcAddress(QLatin1String("glDisableVertexAttribArrayARB"));
- glEnableVertexAttribArray = (_glEnableVertexAttribArray) ctx->getProcAddress(QLatin1String("glEnableVertexAttribArrayARB"));
- }
-
- // Note: glShaderBinary(), glIsShader(), glIsProgram(), and
- // glUniformMatrixNxMfv() are optional, but all other functions
- // are required.
-
- return glCreateShader &&
- glShaderSource &&
- glCompileShader &&
- glDeleteProgram &&
- glCreateProgram &&
- glAttachShader &&
- glDetachShader &&
- glLinkProgram &&
- glUseProgram &&
- glGetShaderInfoLog &&
- glGetShaderiv &&
- glGetShaderSource &&
- glGetProgramiv &&
- glGetProgramInfoLog &&
- glGetUniformLocation &&
- glUniform1fv &&
- glUniform2fv &&
- glUniform3fv &&
- glUniform4fv &&
- glUniform1i &&
- glUniform1iv &&
- glUniformMatrix2fv &&
- glUniformMatrix3fv &&
- glUniformMatrix4fv &&
- glBindAttribLocation &&
- glGetAttribLocation &&
- glVertexAttrib1fv &&
- glVertexAttrib2fv &&
- glVertexAttrib3fv &&
- glVertexAttrib4fv &&
- glVertexAttribPointer &&
- glDisableVertexAttribArray &&
- glEnableVertexAttribArray;
-#endif
-}
-
-#if !defined(QT_OPENGL_ES_2)
-bool qt_resolve_version_2_0_functions(QGLContext *ctx)
-{
- bool gl2supported = true;
- if (!qt_resolve_glsl_extensions(ctx))
- gl2supported = false;
-
- if (!qt_resolve_version_1_3_functions(ctx))
- gl2supported = false;
-
- if (glStencilOpSeparate)
- return gl2supported;
-
- glBlendColor = (_glBlendColor) ctx->getProcAddress(QLatin1String("glBlendColor"));
- glStencilOpSeparate = (_glStencilOpSeparate) ctx->getProcAddress(QLatin1String("glStencilOpSeparate"));
- if (!glBlendColor || !glStencilOpSeparate)
- gl2supported = false;
-
- return gl2supported;
-}
-#endif
-
-
-QT_END_NAMESPACE
diff --git a/src/opengl/qglextensions_p.h b/src/opengl/qglextensions_p.h
deleted file mode 100644
index 2e4ceaf4b9..0000000000
--- a/src/opengl/qglextensions_p.h
+++ /dev/null
@@ -1,587 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
-** Contact: http://www.qt-project.org/legal
-**
-** This file is part of the QtOpenGL module of the Qt Toolkit.
-**
-** $QT_BEGIN_LICENSE:LGPL$
-** Commercial License Usage
-** Licensees holding valid commercial Qt licenses may use this file in
-** accordance with the commercial license agreement provided with the
-** Software or, alternatively, in accordance with the terms contained in
-** a written agreement between you and Digia. For licensing terms and
-** conditions see http://qt.digia.com/licensing. For further information
-** use the contact form at http://qt.digia.com/contact-us.
-**
-** GNU Lesser General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU Lesser
-** General Public License version 2.1 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-**
-** In addition, as a special exception, Digia gives you certain additional
-** rights. These rights are described in the Digia Qt LGPL Exception
-** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-**
-** GNU General Public License Usage
-** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 3.0 as published by the Free Software
-** Foundation and appearing in the file LICENSE.GPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU General Public License version 3.0 requirements will be
-** met: http://www.gnu.org/copyleft/gpl.html.
-**
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#ifndef QGL_EXTENSIONS_P_H
-#define QGL_EXTENSIONS_P_H
-
-//
-// W A R N I N G
-// -------------
-//
-// This file is not part of the Qt API. It exists for the convenience
-// of the Qt OpenGL classes. This header file may change from
-// version to version without notice, or even be removed.
-//
-// We mean it.
-//
-
-// extension prototypes
-# ifndef APIENTRYP
-# ifdef APIENTRY
-# define APIENTRYP APIENTRY *
-# else
-# define APIENTRY
-# define APIENTRYP *
-# endif
-# endif
-
-#include <QtCore/qglobal.h>
-
-#ifndef GL_ARB_vertex_buffer_object
-typedef ptrdiff_t GLintptrARB;
-typedef ptrdiff_t GLsizeiptrARB;
-#endif
-
-#ifndef GL_VERSION_2_0
-typedef char GLchar;
-#endif
-
-// ARB_vertex_buffer_object
-typedef void (APIENTRY *_glBindBuffer) (GLenum, GLuint);
-typedef void (APIENTRY *_glDeleteBuffers) (GLsizei, const GLuint *);
-typedef void (APIENTRY *_glGenBuffers) (GLsizei, GLuint *);
-typedef void (APIENTRY *_glBufferData) (GLenum, GLsizeiptrARB, const GLvoid *, GLenum);
-typedef void (APIENTRY *_glBufferSubData) (GLenum, GLintptrARB, GLsizeiptrARB, const GLvoid *);
-typedef void (APIENTRY *_glGetBufferSubData) (GLenum, GLintptrARB, GLsizeiptrARB, GLvoid *);
-typedef void (APIENTRY *_glGetBufferParameteriv) (GLenum, GLenum, GLint *);
-typedef GLvoid* (APIENTRY *_glMapBufferARB) (GLenum, GLenum);
-typedef GLboolean (APIENTRY *_glUnmapBufferARB) (GLenum);
-// We can call the buffer functions directly in OpenGL/ES 1.1 or higher,
-// but all other platforms need to resolve the extensions.
-#if defined(QT_OPENGL_ES)
-#if defined(GL_OES_VERSION_1_0) && !defined(GL_OES_VERSION_1_1)
-#define QGL_RESOLVE_BUFFER_FUNCS 1
-#endif
-#else
-#define QGL_RESOLVE_BUFFER_FUNCS 1
-#endif
-
-// ARB_fragment_program
-typedef void (APIENTRY *_glProgramStringARB) (GLenum, GLenum, GLsizei, const GLvoid *);
-typedef void (APIENTRY *_glBindProgramARB) (GLenum, GLuint);
-typedef void (APIENTRY *_glDeleteProgramsARB) (GLsizei, const GLuint *);
-typedef void (APIENTRY *_glGenProgramsARB) (GLsizei, GLuint *);
-typedef void (APIENTRY *_glProgramLocalParameter4fvARB) (GLenum, GLuint, const GLfloat *);
-
-// GLSL
-typedef GLuint (APIENTRY *_glCreateShader) (GLenum);
-typedef void (APIENTRY *_glShaderSource) (GLuint, GLsizei, const char **, const GLint *);
-typedef void (APIENTRY *_glShaderBinary) (GLint, const GLuint*, GLenum, const void*, GLint);
-typedef void (APIENTRY *_glCompileShader) (GLuint);
-typedef void (APIENTRY *_glDeleteShader) (GLuint);
-typedef GLboolean (APIENTRY *_glIsShader) (GLuint);
-
-typedef GLuint (APIENTRY *_glCreateProgram) ();
-typedef void (APIENTRY *_glAttachShader) (GLuint, GLuint);
-typedef void (APIENTRY *_glDetachShader) (GLuint, GLuint);
-typedef void (APIENTRY *_glLinkProgram) (GLuint);
-typedef void (APIENTRY *_glUseProgram) (GLuint);
-typedef void (APIENTRY *_glDeleteProgram) (GLuint);
-typedef GLboolean (APIENTRY *_glIsProgram) (GLuint);
-
-typedef void (APIENTRY *_glGetShaderInfoLog) (GLuint, GLsizei, GLsizei *, char *);
-typedef void (APIENTRY *_glGetShaderiv) (GLuint, GLenum, GLint *);
-typedef void (APIENTRY *_glGetShaderSource) (GLuint, GLsizei, GLsizei *, char *);
-typedef void (APIENTRY *_glGetProgramiv) (GLuint, GLenum, GLint *);
-typedef void (APIENTRY *_glGetProgramInfoLog) (GLuint, GLsizei, GLsizei *, char *);
-
-typedef GLuint (APIENTRY *_glGetUniformLocation) (GLuint, const char*);
-typedef void (APIENTRY *_glUniform4fv) (GLint, GLsizei, const GLfloat *);
-typedef void (APIENTRY *_glUniform3fv) (GLint, GLsizei, const GLfloat *);
-typedef void (APIENTRY *_glUniform2fv) (GLint, GLsizei, const GLfloat *);
-typedef void (APIENTRY *_glUniform1fv) (GLint, GLsizei, const GLfloat *);
-typedef void (APIENTRY *_glUniform1i) (GLint, GLint);
-typedef void (APIENTRY *_glUniform1iv) (GLint, GLsizei, const GLint *);
-typedef void (APIENTRY *_glUniformMatrix2fv) (GLint, GLsizei, GLboolean, const GLfloat *);
-typedef void (APIENTRY *_glUniformMatrix3fv) (GLint, GLsizei, GLboolean, const GLfloat *);
-typedef void (APIENTRY *_glUniformMatrix4fv) (GLint, GLsizei, GLboolean, const GLfloat *);
-typedef void (APIENTRY *_glUniformMatrix2x3fv) (GLint, GLsizei, GLboolean, const GLfloat *);
-typedef void (APIENTRY *_glUniformMatrix2x4fv) (GLint, GLsizei, GLboolean, const GLfloat *);
-typedef void (APIENTRY *_glUniformMatrix3x2fv) (GLint, GLsizei, GLboolean, const GLfloat *);
-typedef void (APIENTRY *_glUniformMatrix3x4fv) (GLint, GLsizei, GLboolean, const GLfloat *);
-typedef void (APIENTRY *_glUniformMatrix4x2fv) (GLint, GLsizei, GLboolean, const GLfloat *);
-typedef void (APIENTRY *_glUniformMatrix4x3fv) (GLint, GLsizei, GLboolean, const GLfloat *);
-
-typedef void (APIENTRY *_glBindAttribLocation) (GLuint, GLuint, const char *);
-typedef GLint (APIENTRY *_glGetAttribLocation) (GLuint, const char *);
-typedef void (APIENTRY *_glVertexAttrib1fv) (GLuint, const GLfloat *);
-typedef void (APIENTRY *_glVertexAttrib2fv) (GLuint, const GLfloat *);
-typedef void (APIENTRY *_glVertexAttrib3fv) (GLuint, const GLfloat *);
-typedef void (APIENTRY *_glVertexAttrib4fv) (GLuint, const GLfloat *);
-typedef void (APIENTRY *_glVertexAttribPointer) (GLuint, GLint, GLenum, GLboolean, GLsizei, const GLvoid *);
-typedef void (APIENTRY *_glDisableVertexAttribArray) (GLuint);
-typedef void (APIENTRY *_glEnableVertexAttribArray) (GLuint);
-
-typedef void (APIENTRY *_glGetProgramBinaryOES) (GLuint, GLsizei, GLsizei *, GLenum *, void *);
-typedef void (APIENTRY *_glProgramBinaryOES) (GLuint, GLenum, const void *, GLint);
-
-
-typedef void (APIENTRY *_glMultiTexCoord4f) (GLenum, GLfloat, GLfloat, GLfloat, GLfloat);
-typedef void (APIENTRY *_glActiveStencilFaceEXT) (GLenum );
-
-// Needed for GL2 engine:
-typedef void (APIENTRY *_glStencilOpSeparate) (GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
-typedef void (APIENTRY *_glActiveTexture) (GLenum);
-typedef void (APIENTRY *_glBlendColor) (GLclampf, GLclampf, GLclampf, GLclampf);
-
-
-// EXT_GL_framebuffer_object
-typedef GLboolean (APIENTRY *_glIsRenderbuffer) (GLuint renderbuffer);
-typedef void (APIENTRY *_glBindRenderbuffer) (GLenum target, GLuint renderbuffer);
-typedef void (APIENTRY *_glDeleteRenderbuffers) (GLsizei n, const GLuint *renderbuffers);
-typedef void (APIENTRY *_glGenRenderbuffers) (GLsizei n, GLuint *renderbuffers);
-typedef void (APIENTRY *_glRenderbufferStorage) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
-typedef void (APIENTRY *_glGetRenderbufferParameteriv) (GLenum target, GLenum pname, GLint *params);
-typedef GLboolean (APIENTRY *_glIsFramebuffer) (GLuint framebuffer);
-typedef void (APIENTRY *_glBindFramebuffer) (GLenum target, GLuint framebuffer);
-typedef void (APIENTRY *_glDeleteFramebuffers) (GLsizei n, const GLuint *framebuffers);
-typedef void (APIENTRY *_glGenFramebuffers) (GLsizei n, GLuint *framebuffers);
-typedef GLenum (APIENTRY *_glCheckFramebufferStatus) (GLenum target);
-typedef void (APIENTRY *_glFramebufferTexture2D) (GLenum target, GLenum attachment, GLenum textarget,
- GLuint texture, GLint level);
-typedef void (APIENTRY *_glFramebufferRenderbuffer) (GLenum target, GLenum attachment, GLenum renderbuffertarget,
- GLuint renderbuffer);
-typedef void (APIENTRY *_glGetFramebufferAttachmentParameteriv) (GLenum target, GLenum attachment, GLenum pname,
- GLint *params);
-typedef void (APIENTRY *_glGenerateMipmap) (GLenum target);
-
-// EXT_GL_framebuffer_blit
-typedef void (APIENTRY *_glBlitFramebufferEXT) (int srcX0, int srcY0, int srcX1, int srcY1,
- int dstX0, int dstY0, int dstX1, int dstY1,
- GLbitfield mask, GLenum filter);
-
-// EXT_GL_framebuffer_multisample
-typedef void (APIENTRY *_glRenderbufferStorageMultisampleEXT) (GLenum target, GLsizei samples,
- GLenum internalformat, GLsizei width, GLsizei height);
-
-// GL_EXT_geometry_shader4
-typedef void (APIENTRY *_glProgramParameteriEXT)(GLuint program, GLenum pname, GLint value);
-typedef void (APIENTRY *_glFramebufferTextureEXT)(GLenum target, GLenum attachment,
- GLuint texture, GLint level);
-typedef void (APIENTRY *_glFramebufferTextureLayerEXT)(GLenum target, GLenum attachment,
- GLuint texture, GLint level, GLint layer);
-typedef void (APIENTRY *_glFramebufferTextureFaceEXT)(GLenum target, GLenum attachment,
- GLuint texture, GLint level, GLenum face);
-
-// ARB_texture_compression
-typedef void (APIENTRY *_glCompressedTexImage2DARB) (GLenum, GLint, GLenum, GLsizei,
- GLsizei, GLint, GLsizei, const GLvoid *);
-QT_BEGIN_NAMESPACE
-
-struct QGLExtensionFuncs
-{
- QGLExtensionFuncs() {
-#if !defined(QT_OPENGL_ES_2)
- qt_glProgramStringARB = 0;
- qt_glBindProgramARB = 0;
- qt_glDeleteProgramsARB = 0;
- qt_glGenProgramsARB = 0;
- qt_glProgramLocalParameter4fvARB = 0;
-
- // GLSL
- qt_glCreateShader = 0;
- qt_glShaderSource = 0;
- qt_glShaderBinary = 0;
- qt_glCompileShader = 0;
- qt_glDeleteShader = 0;
- qt_glIsShader = 0;
-
- qt_glCreateProgram = 0;
- qt_glAttachShader = 0;
- qt_glDetachShader = 0;
- qt_glLinkProgram = 0;
- qt_glUseProgram = 0;
- qt_glDeleteProgram = 0;
- qt_glIsProgram = 0;
-
- qt_glGetShaderInfoLog = 0;
- qt_glGetShaderiv = 0;
- qt_glGetShaderSource = 0;
- qt_glGetProgramiv = 0;
- qt_glGetProgramInfoLog = 0;
-
- qt_glGetUniformLocation = 0;
- qt_glUniform4fv = 0;
- qt_glUniform3fv = 0;
- qt_glUniform2fv = 0;
- qt_glUniform1fv = 0;
- qt_glUniform1i = 0;
- qt_glUniform1iv = 0;
- qt_glUniformMatrix2fv = 0;
- qt_glUniformMatrix3fv = 0;
- qt_glUniformMatrix4fv = 0;
- qt_glUniformMatrix2x3fv = 0;
- qt_glUniformMatrix2x4fv = 0;
- qt_glUniformMatrix3x2fv = 0;
- qt_glUniformMatrix3x4fv = 0;
- qt_glUniformMatrix4x2fv = 0;
- qt_glUniformMatrix4x3fv = 0;
-
- qt_glBindAttribLocation = 0;
- qt_glGetAttribLocation = 0;
- qt_glVertexAttrib1fv = 0;
- qt_glVertexAttrib2fv = 0;
- qt_glVertexAttrib3fv = 0;
- qt_glVertexAttrib4fv = 0;
- qt_glVertexAttribPointer = 0;
- qt_glDisableVertexAttribArray = 0;
- qt_glEnableVertexAttribArray = 0;
-
- // Extras for GL2 engine:
- qt_glActiveTexture = 0;
- qt_glStencilOpSeparate = 0;
- qt_glBlendColor = 0;
-
- qt_glActiveStencilFaceEXT = 0;
- qt_glMultiTexCoord4f = 0;
-#else
- qt_glslResolved = false;
-
- qt_glGetProgramBinaryOES = 0;
- qt_glProgramBinaryOES = 0;
-#endif
-
- // FBOs
-#if !defined(QT_OPENGL_ES_2)
- qt_glIsRenderbuffer = 0;
- qt_glBindRenderbuffer = 0;
- qt_glDeleteRenderbuffers = 0;
- qt_glGenRenderbuffers = 0;
- qt_glRenderbufferStorage = 0;
- qt_glGetRenderbufferParameteriv = 0;
- qt_glIsFramebuffer = 0;
- qt_glBindFramebuffer = 0;
- qt_glDeleteFramebuffers = 0;
- qt_glGenFramebuffers = 0;
- qt_glCheckFramebufferStatus = 0;
- qt_glFramebufferTexture2D = 0;
- qt_glFramebufferRenderbuffer = 0;
- qt_glGetFramebufferAttachmentParameteriv = 0;
- qt_glGenerateMipmap = 0;
-#endif
- qt_glBlitFramebufferEXT = 0;
- qt_glRenderbufferStorageMultisampleEXT = 0;
-
- // Buffer objects:
-#if defined(QGL_RESOLVE_BUFFER_FUNCS)
- qt_glBindBuffer = 0;
- qt_glDeleteBuffers = 0;
- qt_glGenBuffers = 0;
- qt_glBufferData = 0;
- qt_glBufferSubData = 0;
- qt_glGetBufferSubData = 0;
- qt_glGetBufferParameteriv = 0;
-#endif
- qt_glMapBufferARB = 0;
- qt_glUnmapBufferARB = 0;
-
- qt_glProgramParameteriEXT = 0;
- qt_glFramebufferTextureEXT = 0;
- qt_glFramebufferTextureLayerEXT = 0;
- qt_glFramebufferTextureFaceEXT = 0;
-#if !defined(QT_OPENGL_ES)
- // Texture compression
- qt_glCompressedTexImage2DARB = 0;
-#endif
- }
-
-
-#if !defined(QT_OPENGL_ES_2)
- _glProgramStringARB qt_glProgramStringARB;
- _glBindProgramARB qt_glBindProgramARB;
- _glDeleteProgramsARB qt_glDeleteProgramsARB;
- _glGenProgramsARB qt_glGenProgramsARB;
- _glProgramLocalParameter4fvARB qt_glProgramLocalParameter4fvARB;
-
- // GLSL definitions
- _glCreateShader qt_glCreateShader;
- _glShaderSource qt_glShaderSource;
- _glShaderBinary qt_glShaderBinary;
- _glCompileShader qt_glCompileShader;
- _glDeleteShader qt_glDeleteShader;
- _glIsShader qt_glIsShader;
-
- _glCreateProgram qt_glCreateProgram;
- _glAttachShader qt_glAttachShader;
- _glDetachShader qt_glDetachShader;
- _glLinkProgram qt_glLinkProgram;
- _glUseProgram qt_glUseProgram;
- _glDeleteProgram qt_glDeleteProgram;
- _glIsProgram qt_glIsProgram;
-
- _glGetShaderInfoLog qt_glGetShaderInfoLog;
- _glGetShaderiv qt_glGetShaderiv;
- _glGetShaderSource qt_glGetShaderSource;
- _glGetProgramiv qt_glGetProgramiv;
- _glGetProgramInfoLog qt_glGetProgramInfoLog;
-
- _glGetUniformLocation qt_glGetUniformLocation;
- _glUniform4fv qt_glUniform4fv;
- _glUniform3fv qt_glUniform3fv;
- _glUniform2fv qt_glUniform2fv;
- _glUniform1fv qt_glUniform1fv;
- _glUniform1i qt_glUniform1i;
- _glUniform1iv qt_glUniform1iv;
- _glUniformMatrix2fv qt_glUniformMatrix2fv;
- _glUniformMatrix3fv qt_glUniformMatrix3fv;
- _glUniformMatrix4fv qt_glUniformMatrix4fv;
- _glUniformMatrix2x3fv qt_glUniformMatrix2x3fv;
- _glUniformMatrix2x4fv qt_glUniformMatrix2x4fv;
- _glUniformMatrix3x2fv qt_glUniformMatrix3x2fv;
- _glUniformMatrix3x4fv qt_glUniformMatrix3x4fv;
- _glUniformMatrix4x2fv qt_glUniformMatrix4x2fv;
- _glUniformMatrix4x3fv qt_glUniformMatrix4x3fv;
-
- _glBindAttribLocation qt_glBindAttribLocation;
- _glGetAttribLocation qt_glGetAttribLocation;
- _glVertexAttrib1fv qt_glVertexAttrib1fv;
- _glVertexAttrib2fv qt_glVertexAttrib2fv;
- _glVertexAttrib3fv qt_glVertexAttrib3fv;
- _glVertexAttrib4fv qt_glVertexAttrib4fv;
- _glVertexAttribPointer qt_glVertexAttribPointer;
- _glDisableVertexAttribArray qt_glDisableVertexAttribArray;
- _glEnableVertexAttribArray qt_glEnableVertexAttribArray;
-
-#else
- bool qt_glslResolved;
-
- _glGetProgramBinaryOES qt_glGetProgramBinaryOES;
- _glProgramBinaryOES qt_glProgramBinaryOES;
-#endif
-
- _glActiveStencilFaceEXT qt_glActiveStencilFaceEXT;
- _glMultiTexCoord4f qt_glMultiTexCoord4f;
-
-#if !defined(QT_OPENGL_ES_2)
- // Extras needed for GL2 engine:
- _glActiveTexture qt_glActiveTexture;
- _glStencilOpSeparate qt_glStencilOpSeparate;
- _glBlendColor qt_glBlendColor;
-
-#endif
-
- // FBOs
-#if !defined(QT_OPENGL_ES_2)
- _glIsRenderbuffer qt_glIsRenderbuffer;
- _glBindRenderbuffer qt_glBindRenderbuffer;
- _glDeleteRenderbuffers qt_glDeleteRenderbuffers;
- _glGenRenderbuffers qt_glGenRenderbuffers;
- _glRenderbufferStorage qt_glRenderbufferStorage;
- _glGetRenderbufferParameteriv qt_glGetRenderbufferParameteriv;
- _glIsFramebuffer qt_glIsFramebuffer;
- _glBindFramebuffer qt_glBindFramebuffer;
- _glDeleteFramebuffers qt_glDeleteFramebuffers;
- _glGenFramebuffers qt_glGenFramebuffers;
- _glCheckFramebufferStatus qt_glCheckFramebufferStatus;
- _glFramebufferTexture2D qt_glFramebufferTexture2D;
- _glFramebufferRenderbuffer qt_glFramebufferRenderbuffer;
- _glGetFramebufferAttachmentParameteriv qt_glGetFramebufferAttachmentParameteriv;
- _glGenerateMipmap qt_glGenerateMipmap;
-#endif
- _glBlitFramebufferEXT qt_glBlitFramebufferEXT;
- _glRenderbufferStorageMultisampleEXT qt_glRenderbufferStorageMultisampleEXT;
-
- // Buffer objects
-#if defined(QGL_RESOLVE_BUFFER_FUNCS)
- _glBindBuffer qt_glBindBuffer;
- _glDeleteBuffers qt_glDeleteBuffers;
- _glGenBuffers qt_glGenBuffers;
- _glBufferData qt_glBufferData;
- _glBufferSubData qt_glBufferSubData;
- _glGetBufferSubData qt_glGetBufferSubData;
- _glGetBufferParameteriv qt_glGetBufferParameteriv;
-#endif
- _glMapBufferARB qt_glMapBufferARB;
- _glUnmapBufferARB qt_glUnmapBufferARB;
-
- // Geometry shaders...
- _glProgramParameteriEXT qt_glProgramParameteriEXT;
- _glFramebufferTextureEXT qt_glFramebufferTextureEXT;
- _glFramebufferTextureLayerEXT qt_glFramebufferTextureLayerEXT;
- _glFramebufferTextureFaceEXT qt_glFramebufferTextureFaceEXT;
-#if !defined(QT_OPENGL_ES)
- // Texture compression
- _glCompressedTexImage2DARB qt_glCompressedTexImage2DARB;
-#endif
-};
-
-
-#if !defined(QT_OPENGL_ES_2)
-#define glProgramStringARB QGLContextPrivate::extensionFuncs(ctx).qt_glProgramStringARB
-#define glBindProgramARB QGLContextPrivate::extensionFuncs(ctx).qt_glBindProgramARB
-#define glDeleteProgramsARB QGLContextPrivate::extensionFuncs(ctx).qt_glDeleteProgramsARB
-#define glGenProgramsARB QGLContextPrivate::extensionFuncs(ctx).qt_glGenProgramsARB
-#define glProgramLocalParameter4fvARB QGLContextPrivate::extensionFuncs(ctx).qt_glProgramLocalParameter4fvARB
-
-#define glActiveStencilFaceEXT QGLContextPrivate::extensionFuncs(ctx).qt_glActiveStencilFaceEXT
-
-#define glMultiTexCoord4f QGLContextPrivate::extensionFuncs(ctx).qt_glMultiTexCoord4f
-
-#define glActiveTexture QGLContextPrivate::extensionFuncs(ctx).qt_glActiveTexture
-#endif // !defined(QT_OPENGL_ES_2)
-
-
-// FBOs
-#if !defined(QT_OPENGL_ES_2)
-#define glIsRenderbuffer QGLContextPrivate::extensionFuncs(ctx).qt_glIsRenderbuffer
-#define glBindRenderbuffer QGLContextPrivate::extensionFuncs(ctx).qt_glBindRenderbuffer
-#define glDeleteRenderbuffers QGLContextPrivate::extensionFuncs(ctx).qt_glDeleteRenderbuffers
-#define glGenRenderbuffers QGLContextPrivate::extensionFuncs(ctx).qt_glGenRenderbuffers
-#define glRenderbufferStorage QGLContextPrivate::extensionFuncs(ctx).qt_glRenderbufferStorage
-#define glGetRenderbufferParameteriv QGLContextPrivate::extensionFuncs(ctx).qt_glGetRenderbufferParameteriv
-#define glIsFramebuffer QGLContextPrivate::extensionFuncs(ctx).qt_glIsFramebuffer
-#define glBindFramebuffer QGLContextPrivate::extensionFuncs(ctx).qt_glBindFramebuffer
-#define glDeleteFramebuffers QGLContextPrivate::extensionFuncs(ctx).qt_glDeleteFramebuffers
-#define glGenFramebuffers QGLContextPrivate::extensionFuncs(ctx).qt_glGenFramebuffers
-#define glCheckFramebufferStatus QGLContextPrivate::extensionFuncs(ctx).qt_glCheckFramebufferStatus
-#define glFramebufferTexture2D QGLContextPrivate::extensionFuncs(ctx).qt_glFramebufferTexture2D
-#define glFramebufferRenderbuffer QGLContextPrivate::extensionFuncs(ctx).qt_glFramebufferRenderbuffer
-#define glGetFramebufferAttachmentParameteriv QGLContextPrivate::extensionFuncs(ctx).qt_glGetFramebufferAttachmentParameteriv
-#define glGenerateMipmap QGLContextPrivate::extensionFuncs(ctx).qt_glGenerateMipmap
-#endif // QT_OPENGL_ES_2
-#define glBlitFramebufferEXT QGLContextPrivate::extensionFuncs(ctx).qt_glBlitFramebufferEXT
-#define glRenderbufferStorageMultisampleEXT QGLContextPrivate::extensionFuncs(ctx).qt_glRenderbufferStorageMultisampleEXT
-
-
-// Buffer objects
-#if defined(QGL_RESOLVE_BUFFER_FUNCS)
-#define glBindBuffer QGLContextPrivate::extensionFuncs(ctx).qt_glBindBuffer
-#define glDeleteBuffers QGLContextPrivate::extensionFuncs(ctx).qt_glDeleteBuffers
-#define glGenBuffers QGLContextPrivate::extensionFuncs(ctx).qt_glGenBuffers
-#define glBufferData QGLContextPrivate::extensionFuncs(ctx).qt_glBufferData
-#define glBufferSubData QGLContextPrivate::extensionFuncs(ctx).qt_glBufferSubData
-#define glGetBufferSubData QGLContextPrivate::extensionFuncs(ctx).qt_glGetBufferSubData
-#define glGetBufferParameteriv QGLContextPrivate::extensionFuncs(ctx).qt_glGetBufferParameteriv
-#endif
-#define glMapBufferARB QGLContextPrivate::extensionFuncs(ctx).qt_glMapBufferARB
-#define glUnmapBufferARB QGLContextPrivate::extensionFuncs(ctx).qt_glUnmapBufferARB
-
-
-// GLSL
-#if !defined(QT_OPENGL_ES_2)
-
-#define glCreateShader QGLContextPrivate::extensionFuncs(ctx).qt_glCreateShader
-#define glShaderSource QGLContextPrivate::extensionFuncs(ctx).qt_glShaderSource
-#define glShaderBinary QGLContextPrivate::extensionFuncs(ctx).qt_glShaderBinary
-#define glCompileShader QGLContextPrivate::extensionFuncs(ctx).qt_glCompileShader
-#define glDeleteShader QGLContextPrivate::extensionFuncs(ctx).qt_glDeleteShader
-#define glIsShader QGLContextPrivate::extensionFuncs(ctx).qt_glIsShader
-
-#define glCreateProgram QGLContextPrivate::extensionFuncs(ctx).qt_glCreateProgram
-#define glAttachShader QGLContextPrivate::extensionFuncs(ctx).qt_glAttachShader
-#define glDetachShader QGLContextPrivate::extensionFuncs(ctx).qt_glDetachShader
-#define glLinkProgram QGLContextPrivate::extensionFuncs(ctx).qt_glLinkProgram
-#define glUseProgram QGLContextPrivate::extensionFuncs(ctx).qt_glUseProgram
-#define glDeleteProgram QGLContextPrivate::extensionFuncs(ctx).qt_glDeleteProgram
-#define glIsProgram QGLContextPrivate::extensionFuncs(ctx).qt_glIsProgram
-
-#define glGetShaderInfoLog QGLContextPrivate::extensionFuncs(ctx).qt_glGetShaderInfoLog
-#define glGetShaderiv QGLContextPrivate::extensionFuncs(ctx).qt_glGetShaderiv
-#define glGetShaderSource QGLContextPrivate::extensionFuncs(ctx).qt_glGetShaderSource
-#define glGetProgramiv QGLContextPrivate::extensionFuncs(ctx).qt_glGetProgramiv
-#define glGetProgramInfoLog QGLContextPrivate::extensionFuncs(ctx).qt_glGetProgramInfoLog
-
-#define glGetUniformLocation QGLContextPrivate::extensionFuncs(ctx).qt_glGetUniformLocation
-#define glUniform4fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniform4fv
-#define glUniform3fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniform3fv
-#define glUniform2fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniform2fv
-#define glUniform1fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniform1fv
-#define glUniform1i QGLContextPrivate::extensionFuncs(ctx).qt_glUniform1i
-#define glUniform1iv QGLContextPrivate::extensionFuncs(ctx).qt_glUniform1iv
-#define glUniformMatrix2fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniformMatrix2fv
-#define glUniformMatrix3fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniformMatrix3fv
-#define glUniformMatrix4fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniformMatrix4fv
-#define glUniformMatrix2x3fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniformMatrix2x3fv
-#define glUniformMatrix2x4fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniformMatrix2x4fv
-#define glUniformMatrix3x2fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniformMatrix3x2fv
-#define glUniformMatrix3x4fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniformMatrix3x4fv
-#define glUniformMatrix4x2fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniformMatrix4x2fv
-#define glUniformMatrix4x3fv QGLContextPrivate::extensionFuncs(ctx).qt_glUniformMatrix4x3fv
-
-#define glBindAttribLocation QGLContextPrivate::extensionFuncs(ctx).qt_glBindAttribLocation
-#define glGetAttribLocation QGLContextPrivate::extensionFuncs(ctx).qt_glGetAttribLocation
-#define glVertexAttrib1fv QGLContextPrivate::extensionFuncs(ctx).qt_glVertexAttrib1fv
-#define glVertexAttrib2fv QGLContextPrivate::extensionFuncs(ctx).qt_glVertexAttrib2fv
-#define glVertexAttrib3fv QGLContextPrivate::extensionFuncs(ctx).qt_glVertexAttrib3fv
-#define glVertexAttrib4fv QGLContextPrivate::extensionFuncs(ctx).qt_glVertexAttrib4fv
-#define glVertexAttribPointer QGLContextPrivate::extensionFuncs(ctx).qt_glVertexAttribPointer
-#define glDisableVertexAttribArray QGLContextPrivate::extensionFuncs(ctx).qt_glDisableVertexAttribArray
-#define glEnableVertexAttribArray QGLContextPrivate::extensionFuncs(ctx).qt_glEnableVertexAttribArray
-
-#else // QT_OPENGL_ES_2
-
-#define glGetProgramBinaryOES QGLContextPrivate::extensionFuncs(ctx).qt_glGetProgramBinaryOES
-#define glProgramBinaryOES QGLContextPrivate::extensionFuncs(ctx).qt_glProgramBinaryOES
-
-#endif // QT_OPENGL_ES_2
-
-
-#if !defined(QT_OPENGL_ES_2)
-#define glStencilOpSeparate QGLContextPrivate::extensionFuncs(ctx).qt_glStencilOpSeparate
-#define glBlendColor QGLContextPrivate::extensionFuncs(ctx).qt_glBlendColor
-#endif
-
-#if defined(QT_OPENGL_ES_2)
-#define glClearDepth glClearDepthf
-#endif
-
-#define glProgramParameteriEXT QGLContextPrivate::extensionFuncs(ctx).qt_glProgramParameteriEXT
-#define glFramebufferTextureEXT QGLContextPrivate::extensionFuncs(ctx).qt_glFramebufferTextureEXT
-#define glFramebufferTextureLayerEXT QGLContextPrivate::extensionFuncs(ctx).qt_glFramebufferTextureLayerEXT
-#define glFramebufferTextureFaceEXT QGLContextPrivate::extensionFuncs(ctx).qt_glFramebufferTextureFaceEXT
-
-#if !defined(QT_OPENGL_ES)
-#define glCompressedTexImage2D QGLContextPrivate::extensionFuncs(ctx).qt_glCompressedTexImage2DARB
-#endif
-
-extern bool qt_resolve_framebufferobject_extensions(QGLContext *ctx);
-bool qt_resolve_buffer_extensions(QGLContext *ctx);
-
-bool qt_resolve_version_1_3_functions(QGLContext *ctx);
-bool qt_resolve_version_2_0_functions(QGLContext *ctx);
-bool qt_resolve_stencil_face_extension(QGLContext *ctx);
-bool qt_resolve_frag_program_extensions(QGLContext *ctx);
-
-bool qt_resolve_glsl_extensions(QGLContext *ctx);
-
-QT_END_NAMESPACE
-
-#endif // QGL_EXTENSIONS_P_H
diff --git a/src/opengl/qglframebufferobject.cpp b/src/opengl/qglframebufferobject.cpp
index 42d1280bb2..15880108f3 100644
--- a/src/opengl/qglframebufferobject.cpp
+++ b/src/opengl/qglframebufferobject.cpp
@@ -389,7 +389,7 @@ bool QGLFramebufferObjectPrivate::checkFramebufferStatus() const
QGL_FUNCP_CONTEXT;
if (!ctx)
return false; // Context no longer exists.
- GLenum status = glCheckFramebufferStatus(GL_FRAMEBUFFER);
+ GLenum status = ctx->contextHandle()->functions()->glCheckFramebufferStatus(GL_FRAMEBUFFER);
switch(status) {
case GL_NO_ERROR:
case GL_FRAMEBUFFER_COMPLETE:
@@ -444,14 +444,14 @@ namespace
{
void freeFramebufferFunc(QGLContext *ctx, GLuint id)
{
- Q_UNUSED(ctx);
- glDeleteFramebuffers(1, &id);
+ Q_ASSERT(ctx);
+ ctx->contextHandle()->functions()->glDeleteFramebuffers(1, &id);
}
void freeRenderbufferFunc(QGLContext *ctx, GLuint id)
{
- Q_UNUSED(ctx);
- glDeleteRenderbuffers(1, &id);
+ Q_ASSERT(ctx);
+ ctx->contextHandle()->functions()->glDeleteRenderbuffers(1, &id);
}
void freeTextureFunc(QGLContext *ctx, GLuint id)
@@ -468,8 +468,9 @@ void QGLFramebufferObjectPrivate::init(QGLFramebufferObject *q, const QSize &sz,
{
QGLContext *ctx = const_cast<QGLContext *>(QGLContext::currentContext());
- bool ext_detected = (QGLExtensions::glExtensions() & QGLExtensions::FramebufferObject);
- if (!ext_detected || (ext_detected && !qt_resolve_framebufferobject_extensions(ctx)))
+ funcs.initializeOpenGLFunctions();
+
+ if (!funcs.hasOpenGLFeature(QOpenGLFunctions::Framebuffers))
return;
size = sz;
@@ -478,8 +479,8 @@ void QGLFramebufferObjectPrivate::init(QGLFramebufferObject *q, const QSize &sz,
QT_RESET_GLERROR(); // reset error state
GLuint fbo = 0;
- glGenFramebuffers(1, &fbo);
- glBindFramebuffer(GL_FRAMEBUFFER, fbo);
+ funcs.glGenFramebuffers(1, &fbo);
+ funcs.glBindFramebuffer(GL_FRAMEBUFFER, fbo);
GLuint texture = 0;
GLuint color_buffer = 0;
@@ -509,7 +510,7 @@ void QGLFramebufferObjectPrivate::init(QGLFramebufferObject *q, const QSize &sz,
glTexParameteri(target, GL_TEXTURE_MAG_FILTER, GL_NEAREST);
glTexParameteri(target, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
glTexParameteri(target, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
- glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0,
+ funcs.glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0,
target, texture, 0);
QT_CHECK_GLERROR();
@@ -524,25 +525,25 @@ void QGLFramebufferObjectPrivate::init(QGLFramebufferObject *q, const QSize &sz,
samples = qBound(0, int(samples), int(maxSamples));
- glGenRenderbuffers(1, &color_buffer);
- glBindRenderbuffer(GL_RENDERBUFFER, color_buffer);
- if (glRenderbufferStorageMultisampleEXT && samples > 0) {
- glRenderbufferStorageMultisampleEXT(GL_RENDERBUFFER, samples,
+ funcs.glGenRenderbuffers(1, &color_buffer);
+ funcs.glBindRenderbuffer(GL_RENDERBUFFER, color_buffer);
+ if (funcs.hasOpenGLExtension(QOpenGLExtensions::FramebufferMultisample) && samples > 0) {
+ funcs.glRenderbufferStorageMultisample(GL_RENDERBUFFER, samples,
internal_format, size.width(), size.height());
} else {
samples = 0;
- glRenderbufferStorage(GL_RENDERBUFFER, internal_format,
+ funcs.glRenderbufferStorage(GL_RENDERBUFFER, internal_format,
size.width(), size.height());
}
- glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0,
+ funcs.glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0,
GL_RENDERBUFFER, color_buffer);
QT_CHECK_GLERROR();
valid = checkFramebufferStatus();
if (valid)
- glGetRenderbufferParameteriv(GL_RENDERBUFFER, GL_RENDERBUFFER_SAMPLES, &samples);
+ funcs.glGetRenderbufferParameteriv(GL_RENDERBUFFER, GL_RENDERBUFFER_SAMPLES, &samples);
}
// In practice, a combined depth-stencil buffer is supported by all desktop platforms, while a
@@ -550,28 +551,28 @@ void QGLFramebufferObjectPrivate::init(QGLFramebufferObject *q, const QSize &sz,
// might not be supported while separate buffers are, according to QTBUG-12861.
if (attachment == QGLFramebufferObject::CombinedDepthStencil
- && (QGLExtensions::glExtensions() & QGLExtensions::PackedDepthStencil)) {
+ && funcs.hasOpenGLExtension(QOpenGLExtensions::PackedDepthStencil)) {
// depth and stencil buffer needs another extension
- glGenRenderbuffers(1, &depth_buffer);
- Q_ASSERT(!glIsRenderbuffer(depth_buffer));
- glBindRenderbuffer(GL_RENDERBUFFER, depth_buffer);
- Q_ASSERT(glIsRenderbuffer(depth_buffer));
- if (samples != 0 && glRenderbufferStorageMultisampleEXT)
- glRenderbufferStorageMultisampleEXT(GL_RENDERBUFFER, samples,
+ funcs.glGenRenderbuffers(1, &depth_buffer);
+ Q_ASSERT(!funcs.glIsRenderbuffer(depth_buffer));
+ funcs.glBindRenderbuffer(GL_RENDERBUFFER, depth_buffer);
+ Q_ASSERT(funcs.glIsRenderbuffer(depth_buffer));
+ if (samples != 0 && funcs.hasOpenGLExtension(QOpenGLExtensions::FramebufferMultisample))
+ funcs.glRenderbufferStorageMultisample(GL_RENDERBUFFER, samples,
GL_DEPTH24_STENCIL8, size.width(), size.height());
else
- glRenderbufferStorage(GL_RENDERBUFFER,
+ funcs.glRenderbufferStorage(GL_RENDERBUFFER,
GL_DEPTH24_STENCIL8, size.width(), size.height());
stencil_buffer = depth_buffer;
- glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT,
+ funcs.glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT,
GL_RENDERBUFFER, depth_buffer);
- glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT,
+ funcs.glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT,
GL_RENDERBUFFER, stencil_buffer);
valid = checkFramebufferStatus();
if (!valid) {
- glDeleteRenderbuffers(1, &depth_buffer);
+ funcs.glDeleteRenderbuffers(1, &depth_buffer);
stencil_buffer = depth_buffer = 0;
}
}
@@ -579,72 +580,72 @@ void QGLFramebufferObjectPrivate::init(QGLFramebufferObject *q, const QSize &sz,
if (depth_buffer == 0 && (attachment == QGLFramebufferObject::CombinedDepthStencil
|| (attachment == QGLFramebufferObject::Depth)))
{
- glGenRenderbuffers(1, &depth_buffer);
- Q_ASSERT(!glIsRenderbuffer(depth_buffer));
- glBindRenderbuffer(GL_RENDERBUFFER, depth_buffer);
- Q_ASSERT(glIsRenderbuffer(depth_buffer));
- if (samples != 0 && glRenderbufferStorageMultisampleEXT) {
+ funcs.glGenRenderbuffers(1, &depth_buffer);
+ Q_ASSERT(!funcs.glIsRenderbuffer(depth_buffer));
+ funcs.glBindRenderbuffer(GL_RENDERBUFFER, depth_buffer);
+ Q_ASSERT(funcs.glIsRenderbuffer(depth_buffer));
+ if (samples != 0 && funcs.hasOpenGLExtension(QOpenGLExtensions::FramebufferMultisample)) {
#ifdef QT_OPENGL_ES
- if (QGLExtensions::glExtensions() & QGLExtensions::Depth24) {
- glRenderbufferStorageMultisampleEXT(GL_RENDERBUFFER, samples,
+ if (funcs.hasOpenGLExtension(QOpenGLExtensions::Depth24)) {
+ funcs.glRenderbufferStorageMultisample(GL_RENDERBUFFER, samples,
GL_DEPTH_COMPONENT24_OES, size.width(), size.height());
} else {
- glRenderbufferStorageMultisampleEXT(GL_RENDERBUFFER, samples,
+ funcs.glRenderbufferStorageMultisample(GL_RENDERBUFFER, samples,
GL_DEPTH_COMPONENT16, size.width(), size.height());
}
#else
- glRenderbufferStorageMultisampleEXT(GL_RENDERBUFFER, samples,
+ funcs.glRenderbufferStorageMultisample(GL_RENDERBUFFER, samples,
GL_DEPTH_COMPONENT, size.width(), size.height());
#endif
} else {
#ifdef QT_OPENGL_ES
- if (QGLExtensions::glExtensions() & QGLExtensions::Depth24) {
- glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH_COMPONENT24_OES,
+ if (funcs.hasOpenGLExtension(QOpenGLExtensions::Depth24)) {
+ funcs.glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH_COMPONENT24_OES,
size.width(), size.height());
} else {
- glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH_COMPONENT16,
+ funcs.glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH_COMPONENT16,
size.width(), size.height());
}
#else
- glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH_COMPONENT, size.width(), size.height());
+ funcs.glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH_COMPONENT, size.width(), size.height());
#endif
}
- glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT,
+ funcs.glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT,
GL_RENDERBUFFER, depth_buffer);
valid = checkFramebufferStatus();
if (!valid) {
- glDeleteRenderbuffers(1, &depth_buffer);
+ funcs.glDeleteRenderbuffers(1, &depth_buffer);
depth_buffer = 0;
}
}
if (stencil_buffer == 0 && (attachment == QGLFramebufferObject::CombinedDepthStencil)) {
- glGenRenderbuffers(1, &stencil_buffer);
- Q_ASSERT(!glIsRenderbuffer(stencil_buffer));
- glBindRenderbuffer(GL_RENDERBUFFER, stencil_buffer);
- Q_ASSERT(glIsRenderbuffer(stencil_buffer));
- if (samples != 0 && glRenderbufferStorageMultisampleEXT) {
+ funcs.glGenRenderbuffers(1, &stencil_buffer);
+ Q_ASSERT(!funcs.glIsRenderbuffer(stencil_buffer));
+ funcs.glBindRenderbuffer(GL_RENDERBUFFER, stencil_buffer);
+ Q_ASSERT(funcs.glIsRenderbuffer(stencil_buffer));
+ if (samples != 0 && funcs.hasOpenGLExtension(QOpenGLExtensions::FramebufferMultisample)) {
#ifdef QT_OPENGL_ES
- glRenderbufferStorageMultisampleEXT(GL_RENDERBUFFER, samples,
+ funcs.glRenderbufferStorageMultisample(GL_RENDERBUFFER, samples,
GL_STENCIL_INDEX8, size.width(), size.height());
#else
- glRenderbufferStorageMultisampleEXT(GL_RENDERBUFFER, samples,
+ funcs.glRenderbufferStorageMultisample(GL_RENDERBUFFER, samples,
GL_STENCIL_INDEX, size.width(), size.height());
#endif
} else {
#ifdef QT_OPENGL_ES
- glRenderbufferStorage(GL_RENDERBUFFER, GL_STENCIL_INDEX8,
+ funcs.glRenderbufferStorage(GL_RENDERBUFFER, GL_STENCIL_INDEX8,
size.width(), size.height());
#else
- glRenderbufferStorage(GL_RENDERBUFFER, GL_STENCIL_INDEX,
+ funcs.glRenderbufferStorage(GL_RENDERBUFFER, GL_STENCIL_INDEX,
size.width(), size.height());
#endif
}
- glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT,
+ funcs.glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT,
GL_RENDERBUFFER, stencil_buffer);
valid = checkFramebufferStatus();
if (!valid) {
- glDeleteRenderbuffers(1, &stencil_buffer);
+ funcs.glDeleteRenderbuffers(1, &stencil_buffer);
stencil_buffer = 0;
}
}
@@ -660,7 +661,7 @@ void QGLFramebufferObjectPrivate::init(QGLFramebufferObject *q, const QSize &sz,
fbo_attachment = QGLFramebufferObject::NoAttachment;
}
- glBindFramebuffer(GL_FRAMEBUFFER, ctx->d_ptr->current_fbo);
+ funcs.glBindFramebuffer(GL_FRAMEBUFFER, ctx->d_ptr->current_fbo);
if (valid) {
fbo_guard = createSharedResourceGuard(ctx, fbo, freeFramebufferFunc);
if (color_buffer)
@@ -677,14 +678,14 @@ void QGLFramebufferObjectPrivate::init(QGLFramebufferObject *q, const QSize &sz,
}
} else {
if (color_buffer)
- glDeleteRenderbuffers(1, &color_buffer);
+ funcs.glDeleteRenderbuffers(1, &color_buffer);
else
glDeleteTextures(1, &texture);
if (depth_buffer)
- glDeleteRenderbuffers(1, &depth_buffer);
+ funcs.glDeleteRenderbuffers(1, &depth_buffer);
if (stencil_buffer && depth_buffer != stencil_buffer)
- glDeleteRenderbuffers(1, &stencil_buffer);
- glDeleteFramebuffers(1, &fbo);
+ funcs.glDeleteRenderbuffers(1, &stencil_buffer);
+ funcs.glDeleteFramebuffers(1, &fbo);
}
QT_CHECK_GLERROR();
@@ -991,7 +992,7 @@ bool QGLFramebufferObject::bind()
qWarning("QGLFramebufferObject::bind() called from incompatible context");
}
#endif
- glBindFramebuffer(GL_FRAMEBUFFER, d->fbo());
+ d->funcs.glBindFramebuffer(GL_FRAMEBUFFER, d->fbo());
d->valid = d->checkFramebufferStatus();
if (d->valid && current)
current->d_ptr->current_fbo = d->fbo();
@@ -1011,6 +1012,7 @@ bool QGLFramebufferObject::release()
{
if (!isValid())
return false;
+ Q_D(QGLFramebufferObject);
QGL_FUNC_CONTEXT;
if (!ctx)
return false; // Context no longer exists.
@@ -1027,7 +1029,7 @@ bool QGLFramebufferObject::release()
if (current) {
current->d_ptr->current_fbo = current->d_ptr->default_fbo;
- glBindFramebuffer(GL_FRAMEBUFFER, current->d_ptr->default_fbo);
+ d->funcs.glBindFramebuffer(GL_FRAMEBUFFER, current->d_ptr->default_fbo);
}
return true;
@@ -1133,12 +1135,12 @@ bool QGLFramebufferObject::bindDefault()
QGLContext *ctx = const_cast<QGLContext *>(QGLContext::currentContext());
if (ctx) {
- bool ext_detected = (QGLExtensions::glExtensions() & QGLExtensions::FramebufferObject);
- if (!ext_detected || (ext_detected && !qt_resolve_framebufferobject_extensions(ctx)))
+ QOpenGLFunctions functions(ctx->contextHandle());
+ if (!functions.hasOpenGLFeature(QOpenGLFunctions::Framebuffers))
return false;
ctx->d_ptr->current_fbo = ctx->d_ptr->default_fbo;
- glBindFramebuffer(GL_FRAMEBUFFER, ctx->d_ptr->default_fbo);
+ functions.glBindFramebuffer(GL_FRAMEBUFFER, ctx->d_ptr->default_fbo);
#ifdef QT_DEBUG
} else {
qWarning("QGLFramebufferObject::bindDefault() called without current context.");
@@ -1156,7 +1158,7 @@ bool QGLFramebufferObject::bindDefault()
*/
bool QGLFramebufferObject::hasOpenGLFramebufferObjects()
{
- return (QGLExtensions::glExtensions() & QGLExtensions::FramebufferObject);
+ return qgl_hasFeature(QOpenGLFunctions::Framebuffers);
}
/*!
@@ -1296,7 +1298,7 @@ bool QGLFramebufferObject::isBound() const
*/
bool QGLFramebufferObject::hasOpenGLFramebufferBlit()
{
- return (QGLExtensions::glExtensions() & QGLExtensions::FramebufferBlit);
+ return QOpenGLExtensions(QOpenGLContext::currentContext()).hasOpenGLExtension(QOpenGLExtensions::FramebufferBlit);
}
/*!
@@ -1336,13 +1338,14 @@ void QGLFramebufferObject::blitFramebuffer(QGLFramebufferObject *target, const Q
GLbitfield buffers,
GLenum filter)
{
- if (!(QGLExtensions::glExtensions() & QGLExtensions::FramebufferBlit))
- return;
-
const QGLContext *ctx = QGLContext::currentContext();
if (!ctx || !ctx->contextHandle())
return;
+ QOpenGLExtensions functions(ctx->contextHandle());
+ if (!functions.hasOpenGLExtension(QOpenGLExtensions::FramebufferBlit))
+ return;
+
QSurface *surface = ctx->contextHandle()->surface();
const int height = static_cast<QWindow *>(surface)->height();
@@ -1360,14 +1363,14 @@ void QGLFramebufferObject::blitFramebuffer(QGLFramebufferObject *target, const Q
const int ty0 = th - (targetRect.top() + targetRect.height());
const int ty1 = th - targetRect.top();
- glBindFramebuffer(GL_READ_FRAMEBUFFER, source ? source->handle() : 0);
- glBindFramebuffer(GL_DRAW_FRAMEBUFFER, target ? target->handle() : 0);
+ functions.glBindFramebuffer(GL_READ_FRAMEBUFFER, source ? source->handle() : 0);
+ functions.glBindFramebuffer(GL_DRAW_FRAMEBUFFER, target ? target->handle() : 0);
- glBlitFramebufferEXT(sx0, sy0, sx1, sy1,
+ functions.glBlitFramebuffer(sx0, sy0, sx1, sy1,
tx0, ty0, tx1, ty1,
buffers, filter);
- glBindFramebuffer(GL_FRAMEBUFFER, ctx->d_ptr->current_fbo);
+ functions.glBindFramebuffer(GL_FRAMEBUFFER, ctx->d_ptr->current_fbo);
}
QT_END_NAMESPACE
diff --git a/src/opengl/qglframebufferobject.h b/src/opengl/qglframebufferobject.h
index e1ecc026fb..9312a23822 100644
--- a/src/opengl/qglframebufferobject.h
+++ b/src/opengl/qglframebufferobject.h
@@ -45,8 +45,6 @@
#include <QtOpenGL/qgl.h>
#include <QtGui/qpaintdevice.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -156,5 +154,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QGLFRAMEBUFFEROBJECT_H
diff --git a/src/opengl/qglframebufferobject_p.h b/src/opengl/qglframebufferobject_p.h
index 7fdf278431..0f1128e8f6 100644
--- a/src/opengl/qglframebufferobject_p.h
+++ b/src/opengl/qglframebufferobject_p.h
@@ -56,6 +56,7 @@
#include <qglframebufferobject.h>
#include <private/qglpaintdevice_p.h>
#include <private/qgl_p.h>
+#include <private/qopenglextensions_p.h>
QT_BEGIN_NAMESPACE
@@ -119,7 +120,6 @@ public:
private:
QGLFramebufferObject* fbo;
QGLFormat fboFormat;
- bool wasBound;
bool reqAlpha;
};
@@ -148,6 +148,7 @@ public:
QGLFramebufferObject::Attachment fbo_attachment;
mutable QPaintEngine *engine;
QGLFBOGLPaintDevice glDevice;
+ QOpenGLExtensions funcs;
inline GLuint fbo() const { return fbo_guard ? fbo_guard->id() : 0; }
};
diff --git a/src/opengl/qglfunctions.cpp b/src/opengl/qglfunctions.cpp
index 5ec691073f..3d3bc0e947 100644
--- a/src/opengl/qglfunctions.cpp
+++ b/src/opengl/qglfunctions.cpp
@@ -42,6 +42,7 @@
#include "qglfunctions.h"
#include "qgl_p.h"
#include "QtGui/private/qopenglcontext_p.h"
+#include <private/qopengl_p.h>
QT_BEGIN_NAMESPACE
@@ -225,7 +226,7 @@ static int qt_gl_resolve_features()
QGLFunctions::CompressedTextures |
QGLFunctions::Multisample |
QGLFunctions::StencilSeparate;
- QGLExtensionMatcher extensions;
+ QOpenGLExtensionMatcher extensions;
if (extensions.match("GL_OES_texture_npot"))
features |= QGLFunctions::NPOTTextures;
if (extensions.match("GL_IMG_texture_npot"))
@@ -236,7 +237,7 @@ static int qt_gl_resolve_features()
QGLFunctions::Buffers |
QGLFunctions::CompressedTextures |
QGLFunctions::Multisample;
- QGLExtensionMatcher extensions;
+ QOpenGLExtensionMatcher extensions;
if (extensions.match("GL_OES_framebuffer_object"))
features |= QGLFunctions::Framebuffers;
if (extensions.match("GL_OES_blend_equation_separate"))
@@ -253,7 +254,7 @@ static int qt_gl_resolve_features()
#else
int features = 0;
QGLFormat::OpenGLVersionFlags versions = QGLFormat::openGLVersionFlags();
- QGLExtensionMatcher extensions;
+ QOpenGLExtensionMatcher extensions;
// Recognize features by extension name.
if (extensions.match("GL_ARB_multitexture"))
diff --git a/src/opengl/qglfunctions.h b/src/opengl/qglfunctions.h
index 59ccc59f13..fd867d7a91 100644
--- a/src/opengl/qglfunctions.h
+++ b/src/opengl/qglfunctions.h
@@ -52,8 +52,6 @@
#include <QtOpenGL/qgl.h>
#include <QtGui/qopenglcontext.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -2298,6 +2296,4 @@ inline void QGLFunctions::glVertexAttribPointer(GLuint indx, GLint size, GLenum
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/opengl/qglpixelbuffer.h b/src/opengl/qglpixelbuffer.h
index 8f11a8effb..1a2297da95 100644
--- a/src/opengl/qglpixelbuffer.h
+++ b/src/opengl/qglpixelbuffer.h
@@ -45,8 +45,6 @@
#include <QtOpenGL/qgl.h>
#include <QtGui/qpaintdevice.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -105,6 +103,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGLPIXELBUFFER_H
diff --git a/src/opengl/qglshaderprogram.cpp b/src/opengl/qglshaderprogram.cpp
index 537921bdc4..4859df21d6 100644
--- a/src/opengl/qglshaderprogram.cpp
+++ b/src/opengl/qglshaderprogram.cpp
@@ -40,7 +40,7 @@
****************************************************************************/
#include "qglshaderprogram.h"
-#include "qglextensions_p.h"
+#include <private/qopenglextensions_p.h>
#include "qgl_p.h"
#include <QtCore/private/qobject_p.h>
#include <QtCore/qdebug.h>
@@ -197,10 +197,11 @@ class QGLShaderPrivate : public QObjectPrivate
{
Q_DECLARE_PUBLIC(QGLShader)
public:
- QGLShaderPrivate(const QGLContext *, QGLShader::ShaderType type)
+ QGLShaderPrivate(const QGLContext *ctx, QGLShader::ShaderType type)
: shaderGuard(0)
, shaderType(type)
, compiled(false)
+ , glfuncs(new QOpenGLFunctions(ctx->contextHandle()))
{
}
~QGLShaderPrivate();
@@ -210,6 +211,8 @@ public:
bool compiled;
QString log;
+ QOpenGLFunctions *glfuncs;
+
bool create();
bool compile(QGLShader *q);
void deleteShader();
@@ -218,8 +221,8 @@ public:
namespace {
void freeShaderFunc(QGLContext *ctx, GLuint id)
{
- Q_UNUSED(ctx);
- glDeleteShader(id);
+ Q_ASSERT(ctx);
+ ctx->contextHandle()->functions()->glDeleteShader(id);
}
}
@@ -227,6 +230,7 @@ namespace {
QGLShaderPrivate::~QGLShaderPrivate()
{
+ delete glfuncs;
if (shaderGuard)
shaderGuard->free();
}
@@ -236,16 +240,17 @@ bool QGLShaderPrivate::create()
QGLContext *context = const_cast<QGLContext *>(QGLContext::currentContext());
if (!context)
return false;
- if (qt_resolve_glsl_extensions(context)) {
+
+ if (glfuncs->hasOpenGLFeature(QOpenGLFunctions::Shaders)) {
GLuint shader;
if (shaderType == QGLShader::Vertex)
- shader = glCreateShader(GL_VERTEX_SHADER);
+ shader = glfuncs->glCreateShader(GL_VERTEX_SHADER);
#if !defined(QT_OPENGL_ES_2)
else if (shaderType == QGLShader::Geometry)
- shader = glCreateShader(GL_GEOMETRY_SHADER_EXT);
+ shader = glfuncs->glCreateShader(GL_GEOMETRY_SHADER_EXT);
#endif
else
- shader = glCreateShader(GL_FRAGMENT_SHADER);
+ shader = glfuncs->glCreateShader(GL_FRAGMENT_SHADER);
if (!shader) {
qWarning("%s: Could not create shader of type %d.",
Q_FUNC_INFO, int(shaderType));
@@ -263,16 +268,16 @@ bool QGLShaderPrivate::compile(QGLShader *q)
GLuint shader = shaderGuard ? shaderGuard->id() : 0;
if (!shader)
return false;
- glCompileShader(shader);
+ glfuncs->glCompileShader(shader);
GLint value = 0;
- glGetShaderiv(shader, GL_COMPILE_STATUS, &value);
+ glfuncs->glGetShaderiv(shader, GL_COMPILE_STATUS, &value);
compiled = (value != 0);
value = 0;
- glGetShaderiv(shader, GL_INFO_LOG_LENGTH, &value);
+ glfuncs->glGetShaderiv(shader, GL_INFO_LOG_LENGTH, &value);
if (!compiled && value > 1) {
char *logbuf = new char [value];
GLint len;
- glGetShaderInfoLog(shader, value, &len, logbuf);
+ glfuncs->glGetShaderInfoLog(shader, value, &len, logbuf);
log = QString::fromLatin1(logbuf);
QString name = q->objectName();
@@ -434,7 +439,7 @@ bool QGLShader::compileSourceCode(const char *source)
#endif
src.append(source + headerLen);
srclen.append(GLint(qstrlen(source + headerLen)));
- glShaderSource(d->shaderGuard->id(), src.size(), src.data(), srclen.data());
+ d->glfuncs->glShaderSource(d->shaderGuard->id(), src.size(), src.data(), srclen.data());
return d->compile(this);
} else {
return false;
@@ -498,12 +503,12 @@ QByteArray QGLShader::sourceCode() const
if (!shader)
return QByteArray();
GLint size = 0;
- glGetShaderiv(shader, GL_SHADER_SOURCE_LENGTH, &size);
+ d->glfuncs->glGetShaderiv(shader, GL_SHADER_SOURCE_LENGTH, &size);
if (size <= 0)
return QByteArray();
GLint len = 0;
char *source = new char [size];
- glGetShaderSource(shader, size, &len, source);
+ d->glfuncs->glGetShaderSource(shader, size, &len, source);
QByteArray src(source);
delete [] source;
return src;
@@ -544,6 +549,32 @@ GLuint QGLShader::shaderId() const
#undef ctx
+class ShaderProgramOpenGLFunctions : public QOpenGLFunctions
+{
+public:
+ ShaderProgramOpenGLFunctions()
+ : QOpenGLFunctions()
+ , glProgramParameteri(0)
+ {
+ }
+
+ typedef void (QOPENGLF_APIENTRYP type_glProgramParameteri)(GLuint program, GLenum pname, GLint value);
+
+ void initializeGeometryShaderFunctions()
+ {
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ glProgramParameteri = (type_glProgramParameteri)
+ context->getProcAddress("glProgramParameteri");
+
+ if (!glProgramParameteri) {
+ glProgramParameteri = (type_glProgramParameteri)
+ context->getProcAddress("glProgramParameteriEXT");
+ }
+ }
+
+ type_glProgramParameteri glProgramParameteri;
+};
+
class QGLShaderProgramPrivate : public QObjectPrivate
{
Q_DECLARE_PUBLIC(QGLShaderProgram)
@@ -556,6 +587,7 @@ public:
, geometryVertexCount(64)
, geometryInputType(0)
, geometryOutputType(0)
+ , glfuncs(new ShaderProgramOpenGLFunctions)
{
}
~QGLShaderProgramPrivate();
@@ -573,20 +605,23 @@ public:
QList<QGLShader *> shaders;
QList<QGLShader *> anonShaders;
+ ShaderProgramOpenGLFunctions *glfuncs;
+
bool hasShader(QGLShader::ShaderType type) const;
};
namespace {
void freeProgramFunc(QGLContext *ctx, GLuint id)
{
- Q_UNUSED(ctx);
- glDeleteProgram(id);
+ Q_ASSERT(ctx);
+ ctx->contextHandle()->functions()->glDeleteProgram(id);
}
}
QGLShaderProgramPrivate::~QGLShaderProgramPrivate()
{
+ delete glfuncs;
if (programGuard)
programGuard->free();
}
@@ -644,8 +679,10 @@ bool QGLShaderProgram::init()
QGLContext *context = const_cast<QGLContext *>(QGLContext::currentContext());
if (!context)
return false;
- if (qt_resolve_glsl_extensions(context)) {
- GLuint program = glCreateProgram();
+ d->glfuncs->initializeOpenGLFunctions();
+ d->glfuncs->initializeGeometryShaderFunctions();
+ if (d->glfuncs->hasOpenGLFeature(QOpenGLFunctions::Shaders)) {
+ GLuint program = d->glfuncs->glCreateProgram();
if (!program) {
qWarning() << "QGLShaderProgram: could not create shader program";
return false;
@@ -686,7 +723,7 @@ bool QGLShaderProgram::addShader(QGLShader *shader)
qWarning("QGLShaderProgram::addShader: Program and shader are not associated with same context.");
return false;
}
- glAttachShader(d->programGuard->id(), shader->d_func()->shaderGuard->id());
+ d->glfuncs->glAttachShader(d->programGuard->id(), shader->d_func()->shaderGuard->id());
d->linked = false; // Program needs to be relinked.
d->shaders.append(shader);
connect(shader, SIGNAL(destroyed()), this, SLOT(shaderDestroyed()));
@@ -805,7 +842,7 @@ void QGLShaderProgram::removeShader(QGLShader *shader)
if (d->programGuard && d->programGuard->id()
&& shader && shader->d_func()->shaderGuard)
{
- glDetachShader(d->programGuard->id(), shader->d_func()->shaderGuard->id());
+ d->glfuncs->glDetachShader(d->programGuard->id(), shader->d_func()->shaderGuard->id());
}
d->linked = false; // Program needs to be relinked.
if (shader) {
@@ -843,7 +880,7 @@ void QGLShaderProgram::removeAllShaders()
if (d->programGuard && d->programGuard->id()
&& shader && shader->d_func()->shaderGuard)
{
- glDetachShader(d->programGuard->id(), shader->d_func()->shaderGuard->id());
+ d->glfuncs->glDetachShader(d->programGuard->id(), shader->d_func()->shaderGuard->id());
}
}
foreach (QGLShader *shader, d->anonShaders) {
@@ -884,7 +921,7 @@ bool QGLShaderProgram::link()
// or otherwise populated the shaders itself. Check to see if the
// program is already linked and bail out if so.
value = 0;
- glGetProgramiv(program, GL_LINK_STATUS, &value);
+ d->glfuncs->glGetProgramiv(program, GL_LINK_STATUS, &value);
d->linked = (value != 0);
if (d->linked)
return true;
@@ -892,14 +929,14 @@ bool QGLShaderProgram::link()
#if !defined(QT_OPENGL_ES_2)
// Set up the geometry shader parameters
- if (glProgramParameteriEXT) {
+ if (d->glfuncs->glProgramParameteri) {
foreach (QGLShader *shader, d->shaders) {
if (shader->shaderType() & QGLShader::Geometry) {
- glProgramParameteriEXT(program, GL_GEOMETRY_INPUT_TYPE_EXT,
+ d->glfuncs->glProgramParameteri(program, GL_GEOMETRY_INPUT_TYPE_EXT,
d->geometryInputType);
- glProgramParameteriEXT(program, GL_GEOMETRY_OUTPUT_TYPE_EXT,
+ d->glfuncs->glProgramParameteri(program, GL_GEOMETRY_OUTPUT_TYPE_EXT,
d->geometryOutputType);
- glProgramParameteriEXT(program, GL_GEOMETRY_VERTICES_OUT_EXT,
+ d->glfuncs->glProgramParameteri(program, GL_GEOMETRY_VERTICES_OUT_EXT,
d->geometryVertexCount);
break;
}
@@ -907,17 +944,17 @@ bool QGLShaderProgram::link()
}
#endif
- glLinkProgram(program);
+ d->glfuncs->glLinkProgram(program);
value = 0;
- glGetProgramiv(program, GL_LINK_STATUS, &value);
+ d->glfuncs->glGetProgramiv(program, GL_LINK_STATUS, &value);
d->linked = (value != 0);
value = 0;
- glGetProgramiv(program, GL_INFO_LOG_LENGTH, &value);
+ d->glfuncs->glGetProgramiv(program, GL_INFO_LOG_LENGTH, &value);
d->log = QString();
if (value > 1) {
char *logbuf = new char [value];
GLint len;
- glGetProgramInfoLog(program, value, &len, logbuf);
+ d->glfuncs->glGetProgramInfoLog(program, value, &len, logbuf);
d->log = QString::fromLatin1(logbuf);
QString name = objectName();
if (name.isEmpty())
@@ -976,7 +1013,7 @@ bool QGLShaderProgram::bind()
return false;
}
#endif
- glUseProgram(program);
+ d->glfuncs->glUseProgram(program);
return true;
}
@@ -991,17 +1028,12 @@ bool QGLShaderProgram::bind()
*/
void QGLShaderProgram::release()
{
-#ifndef QT_NO_DEBUG
Q_D(QGLShaderProgram);
+#ifndef QT_NO_DEBUG
if (d->programGuard && d->programGuard->group() != QOpenGLContextGroup::currentContextGroup())
qWarning("QGLShaderProgram::release: program is not valid in the current context.");
#endif
-#if defined(QT_OPENGL_ES_2)
- glUseProgram(0);
-#else
- if (glUseProgram)
- glUseProgram(0);
-#endif
+ d->glfuncs->glUseProgram(0);
}
/*!
@@ -1040,7 +1072,7 @@ void QGLShaderProgram::bindAttributeLocation(const char *name, int location)
Q_D(QGLShaderProgram);
if (!init() || !d->programGuard || !d->programGuard->id())
return;
- glBindAttribLocation(d->programGuard->id(), location, name);
+ d->glfuncs->glBindAttribLocation(d->programGuard->id(), location, name);
d->linked = false; // Program needs to be relinked.
}
@@ -1091,7 +1123,7 @@ int QGLShaderProgram::attributeLocation(const char *name) const
{
Q_D(const QGLShaderProgram);
if (d->linked && d->programGuard && d->programGuard->id()) {
- return glGetAttribLocation(d->programGuard->id(), name);
+ return d->glfuncs->glGetAttribLocation(d->programGuard->id(), name);
} else {
qWarning() << "QGLShaderProgram::attributeLocation(" << name
<< "): shader program is not linked";
@@ -1137,7 +1169,7 @@ void QGLShaderProgram::setAttributeValue(int location, GLfloat value)
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glVertexAttrib1fv(location, &value);
+ d->glfuncs->glVertexAttrib1fv(location, &value);
}
/*!
@@ -1164,7 +1196,7 @@ void QGLShaderProgram::setAttributeValue(int location, GLfloat x, GLfloat y)
Q_UNUSED(d);
if (location != -1) {
GLfloat values[2] = {x, y};
- glVertexAttrib2fv(location, values);
+ d->glfuncs->glVertexAttrib2fv(location, values);
}
}
@@ -1194,7 +1226,7 @@ void QGLShaderProgram::setAttributeValue
Q_UNUSED(d);
if (location != -1) {
GLfloat values[3] = {x, y, z};
- glVertexAttrib3fv(location, values);
+ d->glfuncs->glVertexAttrib3fv(location, values);
}
}
@@ -1225,7 +1257,7 @@ void QGLShaderProgram::setAttributeValue
Q_UNUSED(d);
if (location != -1) {
GLfloat values[4] = {x, y, z, w};
- glVertexAttrib4fv(location, values);
+ d->glfuncs->glVertexAttrib4fv(location, values);
}
}
@@ -1253,7 +1285,7 @@ void QGLShaderProgram::setAttributeValue(int location, const QVector2D& value)
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glVertexAttrib2fv(location, reinterpret_cast<const GLfloat *>(&value));
+ d->glfuncs->glVertexAttrib2fv(location, reinterpret_cast<const GLfloat *>(&value));
}
/*!
@@ -1278,7 +1310,7 @@ void QGLShaderProgram::setAttributeValue(int location, const QVector3D& value)
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glVertexAttrib3fv(location, reinterpret_cast<const GLfloat *>(&value));
+ d->glfuncs->glVertexAttrib3fv(location, reinterpret_cast<const GLfloat *>(&value));
}
/*!
@@ -1303,7 +1335,7 @@ void QGLShaderProgram::setAttributeValue(int location, const QVector4D& value)
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glVertexAttrib4fv(location, reinterpret_cast<const GLfloat *>(&value));
+ d->glfuncs->glVertexAttrib4fv(location, reinterpret_cast<const GLfloat *>(&value));
}
/*!
@@ -1330,7 +1362,7 @@ void QGLShaderProgram::setAttributeValue(int location, const QColor& value)
if (location != -1) {
GLfloat values[4] = {GLfloat(value.redF()), GLfloat(value.greenF()),
GLfloat(value.blueF()), GLfloat(value.alphaF())};
- glVertexAttrib4fv(location, values);
+ d->glfuncs->glVertexAttrib4fv(location, values);
}
}
@@ -1367,13 +1399,13 @@ void QGLShaderProgram::setAttributeValue
if (location != -1) {
while (columns-- > 0) {
if (rows == 1)
- glVertexAttrib1fv(location, values);
+ d->glfuncs->glVertexAttrib1fv(location, values);
else if (rows == 2)
- glVertexAttrib2fv(location, values);
+ d->glfuncs->glVertexAttrib2fv(location, values);
else if (rows == 3)
- glVertexAttrib3fv(location, values);
+ d->glfuncs->glVertexAttrib3fv(location, values);
else
- glVertexAttrib4fv(location, values);
+ d->glfuncs->glVertexAttrib4fv(location, values);
values += rows;
++location;
}
@@ -1417,7 +1449,7 @@ void QGLShaderProgram::setAttributeArray
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1) {
- glVertexAttribPointer(location, tupleSize, GL_FLOAT, GL_FALSE,
+ d->glfuncs->glVertexAttribPointer(location, tupleSize, GL_FLOAT, GL_FALSE,
stride, values);
}
}
@@ -1441,7 +1473,7 @@ void QGLShaderProgram::setAttributeArray
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1) {
- glVertexAttribPointer(location, 2, GL_FLOAT, GL_FALSE,
+ d->glfuncs->glVertexAttribPointer(location, 2, GL_FLOAT, GL_FALSE,
stride, values);
}
}
@@ -1465,7 +1497,7 @@ void QGLShaderProgram::setAttributeArray
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1) {
- glVertexAttribPointer(location, 3, GL_FLOAT, GL_FALSE,
+ d->glfuncs->glVertexAttribPointer(location, 3, GL_FLOAT, GL_FALSE,
stride, values);
}
}
@@ -1489,7 +1521,7 @@ void QGLShaderProgram::setAttributeArray
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1) {
- glVertexAttribPointer(location, 4, GL_FLOAT, GL_FALSE,
+ d->glfuncs->glVertexAttribPointer(location, 4, GL_FLOAT, GL_FALSE,
stride, values);
}
}
@@ -1521,7 +1553,7 @@ void QGLShaderProgram::setAttributeArray
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1) {
- glVertexAttribPointer(location, tupleSize, type, GL_TRUE,
+ d->glfuncs->glVertexAttribPointer(location, tupleSize, type, GL_TRUE,
stride, values);
}
}
@@ -1665,7 +1697,7 @@ void QGLShaderProgram::setAttributeBuffer
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1) {
- glVertexAttribPointer(location, tupleSize, type, GL_TRUE, stride,
+ d->glfuncs->glVertexAttribPointer(location, tupleSize, type, GL_TRUE, stride,
reinterpret_cast<const void *>(offset));
}
}
@@ -1710,7 +1742,7 @@ void QGLShaderProgram::enableAttributeArray(int location)
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glEnableVertexAttribArray(location);
+ d->glfuncs->glEnableVertexAttribArray(location);
}
/*!
@@ -1740,7 +1772,7 @@ void QGLShaderProgram::disableAttributeArray(int location)
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glDisableVertexAttribArray(location);
+ d->glfuncs->glDisableVertexAttribArray(location);
}
/*!
@@ -1769,7 +1801,7 @@ int QGLShaderProgram::uniformLocation(const char *name) const
Q_D(const QGLShaderProgram);
Q_UNUSED(d);
if (d->linked && d->programGuard && d->programGuard->id()) {
- return glGetUniformLocation(d->programGuard->id(), name);
+ return d->glfuncs->glGetUniformLocation(d->programGuard->id(), name);
} else {
qWarning() << "QGLShaderProgram::uniformLocation(" << name
<< "): shader program is not linked";
@@ -1815,7 +1847,7 @@ void QGLShaderProgram::setUniformValue(int location, GLfloat value)
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glUniform1fv(location, 1, &value);
+ d->glfuncs->glUniform1fv(location, 1, &value);
}
/*!
@@ -1841,7 +1873,7 @@ void QGLShaderProgram::setUniformValue(int location, GLint value)
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glUniform1i(location, value);
+ d->glfuncs->glUniform1i(location, value);
}
/*!
@@ -1868,7 +1900,7 @@ void QGLShaderProgram::setUniformValue(int location, GLuint value)
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glUniform1i(location, value);
+ d->glfuncs->glUniform1i(location, value);
}
/*!
@@ -1896,7 +1928,7 @@ void QGLShaderProgram::setUniformValue(int location, GLfloat x, GLfloat y)
Q_UNUSED(d);
if (location != -1) {
GLfloat values[2] = {x, y};
- glUniform2fv(location, 1, values);
+ d->glfuncs->glUniform2fv(location, 1, values);
}
}
@@ -1926,7 +1958,7 @@ void QGLShaderProgram::setUniformValue
Q_UNUSED(d);
if (location != -1) {
GLfloat values[3] = {x, y, z};
- glUniform3fv(location, 1, values);
+ d->glfuncs->glUniform3fv(location, 1, values);
}
}
@@ -1957,7 +1989,7 @@ void QGLShaderProgram::setUniformValue
Q_UNUSED(d);
if (location != -1) {
GLfloat values[4] = {x, y, z, w};
- glUniform4fv(location, 1, values);
+ d->glfuncs->glUniform4fv(location, 1, values);
}
}
@@ -1985,7 +2017,7 @@ void QGLShaderProgram::setUniformValue(int location, const QVector2D& value)
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glUniform2fv(location, 1, reinterpret_cast<const GLfloat *>(&value));
+ d->glfuncs->glUniform2fv(location, 1, reinterpret_cast<const GLfloat *>(&value));
}
/*!
@@ -2011,7 +2043,7 @@ void QGLShaderProgram::setUniformValue(int location, const QVector3D& value)
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glUniform3fv(location, 1, reinterpret_cast<const GLfloat *>(&value));
+ d->glfuncs->glUniform3fv(location, 1, reinterpret_cast<const GLfloat *>(&value));
}
/*!
@@ -2037,7 +2069,7 @@ void QGLShaderProgram::setUniformValue(int location, const QVector4D& value)
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glUniform4fv(location, 1, reinterpret_cast<const GLfloat *>(&value));
+ d->glfuncs->glUniform4fv(location, 1, reinterpret_cast<const GLfloat *>(&value));
}
/*!
@@ -2066,7 +2098,7 @@ void QGLShaderProgram::setUniformValue(int location, const QColor& color)
if (location != -1) {
GLfloat values[4] = {GLfloat(color.redF()), GLfloat(color.greenF()),
GLfloat(color.blueF()), GLfloat(color.alphaF())};
- glUniform4fv(location, 1, values);
+ d->glfuncs->glUniform4fv(location, 1, values);
}
}
@@ -2095,7 +2127,7 @@ void QGLShaderProgram::setUniformValue(int location, const QPoint& point)
Q_UNUSED(d);
if (location != -1) {
GLfloat values[4] = {GLfloat(point.x()), GLfloat(point.y())};
- glUniform2fv(location, 1, values);
+ d->glfuncs->glUniform2fv(location, 1, values);
}
}
@@ -2124,7 +2156,7 @@ void QGLShaderProgram::setUniformValue(int location, const QPointF& point)
Q_UNUSED(d);
if (location != -1) {
GLfloat values[4] = {GLfloat(point.x()), GLfloat(point.y())};
- glUniform2fv(location, 1, values);
+ d->glfuncs->glUniform2fv(location, 1, values);
}
}
@@ -2153,7 +2185,7 @@ void QGLShaderProgram::setUniformValue(int location, const QSize& size)
Q_UNUSED(d);
if (location != -1) {
GLfloat values[4] = {GLfloat(size.width()), GLfloat(size.height())};
- glUniform2fv(location, 1, values);
+ d->glfuncs->glUniform2fv(location, 1, values);
}
}
@@ -2182,7 +2214,7 @@ void QGLShaderProgram::setUniformValue(int location, const QSizeF& size)
Q_UNUSED(d);
if (location != -1) {
GLfloat values[4] = {GLfloat(size.width()), GLfloat(size.height())};
- glUniform2fv(location, 1, values);
+ d->glfuncs->glUniform2fv(location, 1, values);
}
}
@@ -2208,8 +2240,7 @@ void QGLShaderProgram::setUniformValue(const char *name, const QSizeF& size)
void QGLShaderProgram::setUniformValue(int location, const QMatrix2x2& value)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
- glUniformMatrix2fv(location, 1, GL_FALSE, value.constData());
+ d->glfuncs->glUniformMatrix2fv(location, 1, GL_FALSE, value.constData());
}
/*!
@@ -2234,8 +2265,7 @@ void QGLShaderProgram::setUniformValue(const char *name, const QMatrix2x2& value
void QGLShaderProgram::setUniformValue(int location, const QMatrix2x3& value)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
- glUniform3fv(location, 2, value.constData());
+ d->glfuncs->glUniform3fv(location, 2, value.constData());
}
/*!
@@ -2260,8 +2290,7 @@ void QGLShaderProgram::setUniformValue(const char *name, const QMatrix2x3& value
void QGLShaderProgram::setUniformValue(int location, const QMatrix2x4& value)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
- glUniform4fv(location, 2, value.constData());
+ d->glfuncs->glUniform4fv(location, 2, value.constData());
}
/*!
@@ -2286,8 +2315,7 @@ void QGLShaderProgram::setUniformValue(const char *name, const QMatrix2x4& value
void QGLShaderProgram::setUniformValue(int location, const QMatrix3x2& value)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
- glUniform2fv(location, 3, value.constData());
+ d->glfuncs->glUniform2fv(location, 3, value.constData());
}
/*!
@@ -2312,8 +2340,7 @@ void QGLShaderProgram::setUniformValue(const char *name, const QMatrix3x2& value
void QGLShaderProgram::setUniformValue(int location, const QMatrix3x3& value)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
- glUniformMatrix3fv(location, 1, GL_FALSE, value.constData());
+ d->glfuncs->glUniformMatrix3fv(location, 1, GL_FALSE, value.constData());
}
/*!
@@ -2338,8 +2365,7 @@ void QGLShaderProgram::setUniformValue(const char *name, const QMatrix3x3& value
void QGLShaderProgram::setUniformValue(int location, const QMatrix3x4& value)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
- glUniform4fv(location, 3, value.constData());
+ d->glfuncs->glUniform4fv(location, 3, value.constData());
}
/*!
@@ -2364,8 +2390,7 @@ void QGLShaderProgram::setUniformValue(const char *name, const QMatrix3x4& value
void QGLShaderProgram::setUniformValue(int location, const QMatrix4x2& value)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
- glUniform2fv(location, 4, value.constData());
+ d->glfuncs->glUniform2fv(location, 4, value.constData());
}
/*!
@@ -2390,8 +2415,7 @@ void QGLShaderProgram::setUniformValue(const char *name, const QMatrix4x2& value
void QGLShaderProgram::setUniformValue(int location, const QMatrix4x3& value)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
- glUniform3fv(location, 4, value.constData());
+ d->glfuncs->glUniform3fv(location, 4, value.constData());
}
/*!
@@ -2416,8 +2440,7 @@ void QGLShaderProgram::setUniformValue(const char *name, const QMatrix4x3& value
void QGLShaderProgram::setUniformValue(int location, const QMatrix4x4& value)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
- glUniformMatrix4fv(location, 1, GL_FALSE, value.constData());
+ d->glfuncs->glUniformMatrix4fv(location, 1, GL_FALSE, value.constData());
}
/*!
@@ -2446,9 +2469,8 @@ void QGLShaderProgram::setUniformValue(const char *name, const QMatrix4x4& value
void QGLShaderProgram::setUniformValue(int location, const GLfloat value[2][2])
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
if (location != -1)
- glUniformMatrix2fv(location, 1, GL_FALSE, value[0]);
+ d->glfuncs->glUniformMatrix2fv(location, 1, GL_FALSE, value[0]);
}
/*!
@@ -2464,9 +2486,8 @@ void QGLShaderProgram::setUniformValue(int location, const GLfloat value[2][2])
void QGLShaderProgram::setUniformValue(int location, const GLfloat value[3][3])
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
if (location != -1)
- glUniformMatrix3fv(location, 1, GL_FALSE, value[0]);
+ d->glfuncs->glUniformMatrix3fv(location, 1, GL_FALSE, value[0]);
}
/*!
@@ -2481,9 +2502,8 @@ void QGLShaderProgram::setUniformValue(int location, const GLfloat value[3][3])
void QGLShaderProgram::setUniformValue(int location, const GLfloat value[4][4])
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
if (location != -1)
- glUniformMatrix4fv(location, 1, GL_FALSE, value[0]);
+ d->glfuncs->glUniformMatrix4fv(location, 1, GL_FALSE, value[0]);
}
@@ -2541,14 +2561,13 @@ void QGLShaderProgram::setUniformValue(const char *name, const GLfloat value[4][
void QGLShaderProgram::setUniformValue(int location, const QTransform& value)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
if (location != -1) {
GLfloat mat[3][3] = {
{GLfloat(value.m11()), GLfloat(value.m12()), GLfloat(value.m13())},
{GLfloat(value.m21()), GLfloat(value.m22()), GLfloat(value.m23())},
{GLfloat(value.m31()), GLfloat(value.m32()), GLfloat(value.m33())}
};
- glUniformMatrix3fv(location, 1, GL_FALSE, mat[0]);
+ d->glfuncs->glUniformMatrix3fv(location, 1, GL_FALSE, mat[0]);
}
}
@@ -2576,9 +2595,8 @@ void QGLShaderProgram::setUniformValue
void QGLShaderProgram::setUniformValueArray(int location, const GLint *values, int count)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
if (location != -1)
- glUniform1iv(location, count, values);
+ d->glfuncs->glUniform1iv(location, count, values);
}
/*!
@@ -2605,9 +2623,8 @@ void QGLShaderProgram::setUniformValueArray
void QGLShaderProgram::setUniformValueArray(int location, const GLuint *values, int count)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
if (location != -1)
- glUniform1iv(location, count, reinterpret_cast<const GLint *>(values));
+ d->glfuncs->glUniform1iv(location, count, reinterpret_cast<const GLint *>(values));
}
/*!
@@ -2635,16 +2652,15 @@ void QGLShaderProgram::setUniformValueArray
void QGLShaderProgram::setUniformValueArray(int location, const GLfloat *values, int count, int tupleSize)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
if (location != -1) {
if (tupleSize == 1)
- glUniform1fv(location, count, values);
+ d->glfuncs->glUniform1fv(location, count, values);
else if (tupleSize == 2)
- glUniform2fv(location, count, values);
+ d->glfuncs->glUniform2fv(location, count, values);
else if (tupleSize == 3)
- glUniform3fv(location, count, values);
+ d->glfuncs->glUniform3fv(location, count, values);
else if (tupleSize == 4)
- glUniform4fv(location, count, values);
+ d->glfuncs->glUniform4fv(location, count, values);
else
qWarning() << "QGLShaderProgram::setUniformValue: size" << tupleSize << "not supported";
}
@@ -2674,9 +2690,8 @@ void QGLShaderProgram::setUniformValueArray
void QGLShaderProgram::setUniformValueArray(int location, const QVector2D *values, int count)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
if (location != -1)
- glUniform2fv(location, count, reinterpret_cast<const GLfloat *>(values));
+ d->glfuncs->glUniform2fv(location, count, reinterpret_cast<const GLfloat *>(values));
}
/*!
@@ -2701,9 +2716,8 @@ void QGLShaderProgram::setUniformValueArray(const char *name, const QVector2D *v
void QGLShaderProgram::setUniformValueArray(int location, const QVector3D *values, int count)
{
Q_D(QGLShaderProgram);
- Q_UNUSED(d);
if (location != -1)
- glUniform3fv(location, count, reinterpret_cast<const GLfloat *>(values));
+ d->glfuncs->glUniform3fv(location, count, reinterpret_cast<const GLfloat *>(values));
}
/*!
@@ -2730,7 +2744,7 @@ void QGLShaderProgram::setUniformValueArray(int location, const QVector4D *value
Q_D(QGLShaderProgram);
Q_UNUSED(d);
if (location != -1)
- glUniform4fv(location, count, reinterpret_cast<const GLfloat *>(values));
+ d->glfuncs->glUniform4fv(location, count, reinterpret_cast<const GLfloat *>(values));
}
/*!
@@ -2763,32 +2777,7 @@ void QGLShaderProgram::setUniformValueArray(const char *name, const QVector4D *v
} \
func(location, count, GL_FALSE, temp.constData()); \
}
-#if !defined(QT_OPENGL_ES_2)
-#define setUniformGenericMatrixArray(func,colfunc,location,values,count,type,cols,rows) \
- if (location == -1 || count <= 0) \
- return; \
- if (sizeof(type) == sizeof(GLfloat) * cols * rows) { \
- const GLfloat *data = reinterpret_cast<const GLfloat *> \
- (values[0].constData()); \
- if (func) \
- func(location, count, GL_FALSE, data); \
- else \
- colfunc(location, count * cols, data); \
- } else { \
- QVarLengthArray<GLfloat> temp(cols * rows * count); \
- for (int index = 0; index < count; ++index) { \
- for (int index2 = 0; index2 < (cols * rows); ++index2) { \
- temp.data()[cols * rows * index + index2] = \
- values[index].constData()[index2]; \
- } \
- } \
- if (func) \
- func(location, count, GL_FALSE, temp.constData()); \
- else \
- colfunc(location, count * cols, temp.constData()); \
- }
-#else
-#define setUniformGenericMatrixArray(func,colfunc,location,values,count,type,cols,rows) \
+#define setUniformGenericMatrixArray(colfunc,location,values,count,type,cols,rows) \
if (location == -1 || count <= 0) \
return; \
if (sizeof(type) == sizeof(GLfloat) * cols * rows) { \
@@ -2805,7 +2794,6 @@ void QGLShaderProgram::setUniformValueArray(const char *name, const QVector4D *v
} \
colfunc(location, count * cols, temp.constData()); \
}
-#endif
/*!
Sets the uniform variable array at \a location in the current
@@ -2818,7 +2806,7 @@ void QGLShaderProgram::setUniformValueArray(int location, const QMatrix2x2 *valu
Q_D(QGLShaderProgram);
Q_UNUSED(d);
setUniformMatrixArray
- (glUniformMatrix2fv, location, values, count, QMatrix2x2, 2, 2);
+ (d->glfuncs->glUniformMatrix2fv, location, values, count, QMatrix2x2, 2, 2);
}
/*!
@@ -2845,7 +2833,7 @@ void QGLShaderProgram::setUniformValueArray(int location, const QMatrix2x3 *valu
Q_D(QGLShaderProgram);
Q_UNUSED(d);
setUniformGenericMatrixArray
- (glUniformMatrix2x3fv, glUniform3fv, location, values, count,
+ (d->glfuncs->glUniform3fv, location, values, count,
QMatrix2x3, 2, 3);
}
@@ -2873,7 +2861,7 @@ void QGLShaderProgram::setUniformValueArray(int location, const QMatrix2x4 *valu
Q_D(QGLShaderProgram);
Q_UNUSED(d);
setUniformGenericMatrixArray
- (glUniformMatrix2x4fv, glUniform4fv, location, values, count,
+ (d->glfuncs->glUniform4fv, location, values, count,
QMatrix2x4, 2, 4);
}
@@ -2901,7 +2889,7 @@ void QGLShaderProgram::setUniformValueArray(int location, const QMatrix3x2 *valu
Q_D(QGLShaderProgram);
Q_UNUSED(d);
setUniformGenericMatrixArray
- (glUniformMatrix3x2fv, glUniform2fv, location, values, count,
+ (d->glfuncs->glUniform2fv, location, values, count,
QMatrix3x2, 3, 2);
}
@@ -2929,7 +2917,7 @@ void QGLShaderProgram::setUniformValueArray(int location, const QMatrix3x3 *valu
Q_D(QGLShaderProgram);
Q_UNUSED(d);
setUniformMatrixArray
- (glUniformMatrix3fv, location, values, count, QMatrix3x3, 3, 3);
+ (d->glfuncs->glUniformMatrix3fv, location, values, count, QMatrix3x3, 3, 3);
}
/*!
@@ -2956,7 +2944,7 @@ void QGLShaderProgram::setUniformValueArray(int location, const QMatrix3x4 *valu
Q_D(QGLShaderProgram);
Q_UNUSED(d);
setUniformGenericMatrixArray
- (glUniformMatrix3x4fv, glUniform4fv, location, values, count,
+ (d->glfuncs->glUniform4fv, location, values, count,
QMatrix3x4, 3, 4);
}
@@ -2984,7 +2972,7 @@ void QGLShaderProgram::setUniformValueArray(int location, const QMatrix4x2 *valu
Q_D(QGLShaderProgram);
Q_UNUSED(d);
setUniformGenericMatrixArray
- (glUniformMatrix4x2fv, glUniform2fv, location, values, count,
+ (d->glfuncs->glUniform2fv, location, values, count,
QMatrix4x2, 4, 2);
}
@@ -3012,7 +3000,7 @@ void QGLShaderProgram::setUniformValueArray(int location, const QMatrix4x3 *valu
Q_D(QGLShaderProgram);
Q_UNUSED(d);
setUniformGenericMatrixArray
- (glUniformMatrix4x3fv, glUniform3fv, location, values, count,
+ (d->glfuncs->glUniform3fv, location, values, count,
QMatrix4x3, 4, 3);
}
@@ -3040,7 +3028,7 @@ void QGLShaderProgram::setUniformValueArray(int location, const QMatrix4x4 *valu
Q_D(QGLShaderProgram);
Q_UNUSED(d);
setUniformMatrixArray
- (glUniformMatrix4fv, location, values, count, QMatrix4x4, 4, 4);
+ (d->glfuncs->glUniformMatrix4fv, location, values, count, QMatrix4x4, 4, 4);
}
/*!
@@ -3176,7 +3164,9 @@ bool QGLShaderProgram::hasOpenGLShaderPrograms(const QGLContext *context)
context = QGLContext::currentContext();
if (!context)
return false;
- return qt_resolve_glsl_extensions(const_cast<QGLContext *>(context));
+
+ QOpenGLFunctions functions(context->contextHandle());
+ return functions.hasOpenGLFeature(QOpenGLFunctions::Shaders);
#else
Q_UNUSED(context);
return true;
@@ -3217,7 +3207,8 @@ bool QGLShader::hasOpenGLShaders(ShaderType type, const QGLContext *context)
if ((type & ~(Geometry | Vertex | Fragment)) || type == 0)
return false;
- bool resolved = qt_resolve_glsl_extensions(const_cast<QGLContext *>(context));
+ QOpenGLFunctions functions(context->contextHandle());
+ bool resolved = functions.hasOpenGLFeature(QOpenGLFunctions::Shaders);
if (!resolved)
return false;
diff --git a/src/opengl/qglshaderprogram.h b/src/opengl/qglshaderprogram.h
index 2aae95a5aa..93f11e1826 100644
--- a/src/opengl/qglshaderprogram.h
+++ b/src/opengl/qglshaderprogram.h
@@ -48,8 +48,6 @@
#include <QtGui/qvector4d.h>
#include <QtGui/qmatrix4x4.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -304,6 +302,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/opengl/qgraphicsshadereffect_p.h b/src/opengl/qgraphicsshadereffect_p.h
index e1e7c1f049..8a7c082afa 100644
--- a/src/opengl/qgraphicsshadereffect_p.h
+++ b/src/opengl/qgraphicsshadereffect_p.h
@@ -56,8 +56,6 @@
#include <QtWidgets/qgraphicseffect.h>
#include <QtOpenGL/qtopenglglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -89,6 +87,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGRAPHICSSHADEREFFECT_P_H
diff --git a/src/opengl/qtopenglglobal.h b/src/opengl/qtopenglglobal.h
index 4657e195fd..bce329404f 100644
--- a/src/opengl/qtopenglglobal.h
+++ b/src/opengl/qtopenglglobal.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#ifndef QT_STATIC
@@ -60,6 +58,4 @@ QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTOPENGLGLOBAL_H
diff --git a/src/openglextensions/openglextensions.pro b/src/openglextensions/openglextensions.pro
new file mode 100644
index 0000000000..5ab750bee8
--- /dev/null
+++ b/src/openglextensions/openglextensions.pro
@@ -0,0 +1,15 @@
+TARGET = QtOpenGLExtensions
+CONFIG += static
+
+contains(QT_CONFIG, opengl):CONFIG += opengl
+contains(QT_CONFIG, opengles1):CONFIG += opengles1
+contains(QT_CONFIG, opengles2):CONFIG += opengles2
+
+load(qt_module)
+
+DEFINES += QT_NO_CAST_FROM_ASCII
+PRECOMPILED_HEADER = ../corelib/global/qt_pch.h
+
+HEADERS = qopenglextensions.h
+
+SOURCES = qopenglextensions.cpp
diff --git a/src/openglextensions/qopenglextensions.cpp b/src/openglextensions/qopenglextensions.cpp
new file mode 100644
index 0000000000..2119a86ccf
--- /dev/null
+++ b/src/openglextensions/qopenglextensions.cpp
@@ -0,0 +1,7713 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglextensions.h"
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+QAbstractOpenGLExtension::~QAbstractOpenGLExtension()
+{
+ if (d_ptr)
+ delete d_ptr;
+}
+
+bool QAbstractOpenGLExtension::initializeOpenGLFunctions()
+{
+ Q_D(QAbstractOpenGLExtension);
+ d->initialized = true;
+ return true;
+}
+
+bool QAbstractOpenGLExtension::isInitialized() const
+{
+ Q_D(const QAbstractOpenGLExtension);
+ return d->initialized;
+}
+
+#if !defined(QT_OPENGL_ES_2)
+
+QOpenGLExtension_3DFX_tbuffer::QOpenGLExtension_3DFX_tbuffer()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_3DFX_tbufferPrivate))
+{
+}
+
+bool QOpenGLExtension_3DFX_tbuffer::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_3DFX_tbuffer);
+
+ d->TbufferMask3DFX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glTbufferMask3DFX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_AMD_debug_output::QOpenGLExtension_AMD_debug_output()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_AMD_debug_outputPrivate))
+{
+}
+
+bool QOpenGLExtension_AMD_debug_output::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_AMD_debug_output);
+
+ d->GetDebugMessageLogAMD = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLenum *, GLuint *, GLuint *, GLsizei *, GLchar *)>(context->getProcAddress("glGetDebugMessageLogAMD"));
+ d->DebugMessageCallbackAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLDEBUGPROCAMD , GLvoid *)>(context->getProcAddress("glDebugMessageCallbackAMD"));
+ d->DebugMessageInsertAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLsizei , const GLchar *)>(context->getProcAddress("glDebugMessageInsertAMD"));
+ d->DebugMessageEnableAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , const GLuint *, GLboolean )>(context->getProcAddress("glDebugMessageEnableAMD"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_AMD_draw_buffers_blend::QOpenGLExtension_AMD_draw_buffers_blend()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_AMD_draw_buffers_blendPrivate))
+{
+}
+
+bool QOpenGLExtension_AMD_draw_buffers_blend::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_AMD_draw_buffers_blend);
+
+ d->BlendEquationSeparateIndexedAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum )>(context->getProcAddress("glBlendEquationSeparateIndexedAMD"));
+ d->BlendEquationIndexedAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glBlendEquationIndexedAMD"));
+ d->BlendFuncSeparateIndexedAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLenum , GLenum )>(context->getProcAddress("glBlendFuncSeparateIndexedAMD"));
+ d->BlendFuncIndexedAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum )>(context->getProcAddress("glBlendFuncIndexedAMD"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_AMD_multi_draw_indirect::QOpenGLExtension_AMD_multi_draw_indirect()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_AMD_multi_draw_indirectPrivate))
+{
+}
+
+bool QOpenGLExtension_AMD_multi_draw_indirect::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_AMD_multi_draw_indirect);
+
+ d->MultiDrawElementsIndirectAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLvoid *, GLsizei , GLsizei )>(context->getProcAddress("glMultiDrawElementsIndirectAMD"));
+ d->MultiDrawArraysIndirectAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLvoid *, GLsizei , GLsizei )>(context->getProcAddress("glMultiDrawArraysIndirectAMD"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_AMD_name_gen_delete::QOpenGLExtension_AMD_name_gen_delete()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_AMD_name_gen_deletePrivate))
+{
+}
+
+bool QOpenGLExtension_AMD_name_gen_delete::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_AMD_name_gen_delete);
+
+ d->IsNameAMD = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glIsNameAMD"));
+ d->DeleteNamesAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLuint *)>(context->getProcAddress("glDeleteNamesAMD"));
+ d->GenNamesAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint *)>(context->getProcAddress("glGenNamesAMD"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_AMD_performance_monitor::QOpenGLExtension_AMD_performance_monitor()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_AMD_performance_monitorPrivate))
+{
+}
+
+bool QOpenGLExtension_AMD_performance_monitor::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+
+ d->GetPerfMonitorCounterDataAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , GLuint *, GLint *)>(context->getProcAddress("glGetPerfMonitorCounterDataAMD"));
+ d->EndPerfMonitorAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glEndPerfMonitorAMD"));
+ d->BeginPerfMonitorAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glBeginPerfMonitorAMD"));
+ d->SelectPerfMonitorCountersAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLboolean , GLuint , GLint , GLuint *)>(context->getProcAddress("glSelectPerfMonitorCountersAMD"));
+ d->DeletePerfMonitorsAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glDeletePerfMonitorsAMD"));
+ d->GenPerfMonitorsAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenPerfMonitorsAMD"));
+ d->GetPerfMonitorCounterInfoAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , GLvoid *)>(context->getProcAddress("glGetPerfMonitorCounterInfoAMD"));
+ d->GetPerfMonitorCounterStringAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetPerfMonitorCounterStringAMD"));
+ d->GetPerfMonitorGroupStringAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetPerfMonitorGroupStringAMD"));
+ d->GetPerfMonitorCountersAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint *, GLint *, GLsizei , GLuint *)>(context->getProcAddress("glGetPerfMonitorCountersAMD"));
+ d->GetPerfMonitorGroupsAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint *, GLsizei , GLuint *)>(context->getProcAddress("glGetPerfMonitorGroupsAMD"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_AMD_sample_positions::QOpenGLExtension_AMD_sample_positions()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_AMD_sample_positionsPrivate))
+{
+}
+
+bool QOpenGLExtension_AMD_sample_positions::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_AMD_sample_positions);
+
+ d->SetMultisamplefvAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLfloat *)>(context->getProcAddress("glSetMultisamplefvAMD"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_AMD_sparse_texture::QOpenGLExtension_AMD_sparse_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_AMD_sparse_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_AMD_sparse_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_AMD_sparse_texture);
+
+ d->TexStorageSparseAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLsizei , GLsizei , GLsizei , GLbitfield )>(context->getProcAddress("glTexStorageSparseAMD"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_AMD_stencil_operation_extended::QOpenGLExtension_AMD_stencil_operation_extended()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_AMD_stencil_operation_extendedPrivate))
+{
+}
+
+bool QOpenGLExtension_AMD_stencil_operation_extended::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_AMD_stencil_operation_extended);
+
+ d->StencilOpValueAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glStencilOpValueAMD"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_AMD_vertex_shader_tesselator::QOpenGLExtension_AMD_vertex_shader_tesselator()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_AMD_vertex_shader_tesselatorPrivate))
+{
+}
+
+bool QOpenGLExtension_AMD_vertex_shader_tesselator::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_AMD_vertex_shader_tesselator);
+
+ d->TessellationModeAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glTessellationModeAMD"));
+ d->TessellationFactorAMD = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glTessellationFactorAMD"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_APPLE_element_array::QOpenGLExtension_APPLE_element_array()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_APPLE_element_arrayPrivate))
+{
+}
+
+bool QOpenGLExtension_APPLE_element_array::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_APPLE_element_array);
+
+ d->MultiDrawRangeElementArrayAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , const GLint *, const GLsizei *, GLsizei )>(context->getProcAddress("glMultiDrawRangeElementArrayAPPLE"));
+ d->MultiDrawElementArrayAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *, const GLsizei *, GLsizei )>(context->getProcAddress("glMultiDrawElementArrayAPPLE"));
+ d->DrawRangeElementArrayAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLint , GLsizei )>(context->getProcAddress("glDrawRangeElementArrayAPPLE"));
+ d->DrawElementArrayAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLsizei )>(context->getProcAddress("glDrawElementArrayAPPLE"));
+ d->ElementPointerAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLvoid *)>(context->getProcAddress("glElementPointerAPPLE"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_APPLE_fence::QOpenGLExtension_APPLE_fence()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_APPLE_fencePrivate))
+{
+}
+
+bool QOpenGLExtension_APPLE_fence::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_APPLE_fence);
+
+ d->FinishObjectAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glFinishObjectAPPLE"));
+ d->TestObjectAPPLE = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glTestObjectAPPLE"));
+ d->FinishFenceAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glFinishFenceAPPLE"));
+ d->TestFenceAPPLE = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glTestFenceAPPLE"));
+ d->IsFenceAPPLE = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsFenceAPPLE"));
+ d->SetFenceAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glSetFenceAPPLE"));
+ d->DeleteFencesAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteFencesAPPLE"));
+ d->GenFencesAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenFencesAPPLE"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_APPLE_flush_buffer_range::QOpenGLExtension_APPLE_flush_buffer_range()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_APPLE_flush_buffer_rangePrivate))
+{
+}
+
+bool QOpenGLExtension_APPLE_flush_buffer_range::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_APPLE_flush_buffer_range);
+
+ d->FlushMappedBufferRangeAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLintptr , GLsizeiptr )>(context->getProcAddress("glFlushMappedBufferRangeAPPLE"));
+ d->BufferParameteriAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glBufferParameteriAPPLE"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_APPLE_object_purgeable::QOpenGLExtension_APPLE_object_purgeable()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_APPLE_object_purgeablePrivate))
+{
+}
+
+bool QOpenGLExtension_APPLE_object_purgeable::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_APPLE_object_purgeable);
+
+ d->GetObjectParameterivAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum , GLint *)>(context->getProcAddress("glGetObjectParameterivAPPLE"));
+ d->ObjectUnpurgeableAPPLE = reinterpret_cast<GLenum (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum )>(context->getProcAddress("glObjectUnpurgeableAPPLE"));
+ d->ObjectPurgeableAPPLE = reinterpret_cast<GLenum (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum )>(context->getProcAddress("glObjectPurgeableAPPLE"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_APPLE_texture_range::QOpenGLExtension_APPLE_texture_range()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_APPLE_texture_rangePrivate))
+{
+}
+
+bool QOpenGLExtension_APPLE_texture_range::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_APPLE_texture_range);
+
+ d->GetTexParameterPointervAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLvoid* *)>(context->getProcAddress("glGetTexParameterPointervAPPLE"));
+ d->TextureRangeAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glTextureRangeAPPLE"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_APPLE_vertex_array_object::QOpenGLExtension_APPLE_vertex_array_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_APPLE_vertex_array_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_APPLE_vertex_array_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_APPLE_vertex_array_object);
+
+ d->IsVertexArrayAPPLE = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsVertexArrayAPPLE"));
+ d->GenVertexArraysAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenVertexArraysAPPLE"));
+ d->DeleteVertexArraysAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteVertexArraysAPPLE"));
+ d->BindVertexArrayAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glBindVertexArrayAPPLE"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_APPLE_vertex_array_range::QOpenGLExtension_APPLE_vertex_array_range()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_APPLE_vertex_array_rangePrivate))
+{
+}
+
+bool QOpenGLExtension_APPLE_vertex_array_range::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_APPLE_vertex_array_range);
+
+ d->VertexArrayParameteriAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glVertexArrayParameteriAPPLE"));
+ d->FlushVertexArrayRangeAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLvoid *)>(context->getProcAddress("glFlushVertexArrayRangeAPPLE"));
+ d->VertexArrayRangeAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLvoid *)>(context->getProcAddress("glVertexArrayRangeAPPLE"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_APPLE_vertex_program_evaluators::QOpenGLExtension_APPLE_vertex_program_evaluators()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_APPLE_vertex_program_evaluatorsPrivate))
+{
+}
+
+bool QOpenGLExtension_APPLE_vertex_program_evaluators::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_APPLE_vertex_program_evaluators);
+
+ d->MapVertexAttrib2fAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLfloat , GLfloat , GLint , GLint , GLfloat , GLfloat , GLint , GLint , const GLfloat *)>(context->getProcAddress("glMapVertexAttrib2fAPPLE"));
+ d->MapVertexAttrib2dAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLdouble , GLdouble , GLint , GLint , GLdouble , GLdouble , GLint , GLint , const GLdouble *)>(context->getProcAddress("glMapVertexAttrib2dAPPLE"));
+ d->MapVertexAttrib1fAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLfloat , GLfloat , GLint , GLint , const GLfloat *)>(context->getProcAddress("glMapVertexAttrib1fAPPLE"));
+ d->MapVertexAttrib1dAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLdouble , GLdouble , GLint , GLint , const GLdouble *)>(context->getProcAddress("glMapVertexAttrib1dAPPLE"));
+ d->IsVertexAttribEnabledAPPLE = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glIsVertexAttribEnabledAPPLE"));
+ d->DisableVertexAttribAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glDisableVertexAttribAPPLE"));
+ d->EnableVertexAttribAPPLE = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glEnableVertexAttribAPPLE"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_ES2_compatibility::QOpenGLExtension_ARB_ES2_compatibility()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_ES2_compatibilityPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_ES2_compatibility::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_ES2_compatibility);
+
+ d->ClearDepthf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glClearDepthf"));
+ d->DepthRangef = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glDepthRangef"));
+ d->GetShaderPrecisionFormat = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *, GLint *)>(context->getProcAddress("glGetShaderPrecisionFormat"));
+ d->ShaderBinary = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *, GLenum , const GLvoid *, GLsizei )>(context->getProcAddress("glShaderBinary"));
+ d->ReleaseShaderCompiler = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glReleaseShaderCompiler"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_base_instance::QOpenGLExtension_ARB_base_instance()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_base_instancePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_base_instance::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_base_instance);
+
+ d->DrawElementsInstancedBaseVertexBaseInstance = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const void *, GLsizei , GLint , GLuint )>(context->getProcAddress("glDrawElementsInstancedBaseVertexBaseInstance"));
+ d->DrawElementsInstancedBaseInstance = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const void *, GLsizei , GLuint )>(context->getProcAddress("glDrawElementsInstancedBaseInstance"));
+ d->DrawArraysInstancedBaseInstance = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLsizei , GLsizei , GLuint )>(context->getProcAddress("glDrawArraysInstancedBaseInstance"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_blend_func_extended::QOpenGLExtension_ARB_blend_func_extended()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_blend_func_extendedPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_blend_func_extended::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_blend_func_extended);
+
+ d->GetFragDataIndex = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , const GLchar *)>(context->getProcAddress("glGetFragDataIndex"));
+ d->BindFragDataLocationIndexed = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint , const GLchar *)>(context->getProcAddress("glBindFragDataLocationIndexed"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_cl_event::QOpenGLExtension_ARB_cl_event()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_cl_eventPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_cl_event::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_cl_event);
+
+ d->CreateSyncFromCLeventARB = reinterpret_cast<GLsync (QOPENGLF_APIENTRYP)(struct _cl_context * , struct _cl_event * , GLbitfield )>(context->getProcAddress("glCreateSyncFromCLeventARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_clear_buffer_object::QOpenGLExtension_ARB_clear_buffer_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_clear_buffer_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_clear_buffer_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_clear_buffer_object);
+
+ d->ClearBufferSubData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLintptr , GLsizeiptr , GLenum , GLenum , const void *)>(context->getProcAddress("glClearBufferSubData"));
+ d->ClearBufferData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLenum , const void *)>(context->getProcAddress("glClearBufferData"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_color_buffer_float::QOpenGLExtension_ARB_color_buffer_float()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_color_buffer_floatPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_color_buffer_float::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_color_buffer_float);
+
+ d->ClampColorARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glClampColorARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_compute_shader::QOpenGLExtension_ARB_compute_shader()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_compute_shaderPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_compute_shader::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_compute_shader);
+
+ d->DispatchComputeIndirect = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLintptr )>(context->getProcAddress("glDispatchComputeIndirect"));
+ d->DispatchCompute = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glDispatchCompute"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_copy_buffer::QOpenGLExtension_ARB_copy_buffer()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_copy_bufferPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_copy_buffer::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_copy_buffer);
+
+ d->CopyBufferSubData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLintptr , GLintptr , GLsizeiptr )>(context->getProcAddress("glCopyBufferSubData"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_copy_image::QOpenGLExtension_ARB_copy_image()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_copy_imagePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_copy_image::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_copy_image);
+
+ d->CopyImageSubData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLint , GLint , GLint , GLuint , GLenum , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei )>(context->getProcAddress("glCopyImageSubData"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_debug_output::QOpenGLExtension_ARB_debug_output()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_debug_outputPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_debug_output::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_debug_output);
+
+ d->GetDebugMessageLogARB = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLenum *, GLenum *, GLuint *, GLenum *, GLsizei *, GLchar *)>(context->getProcAddress("glGetDebugMessageLogARB"));
+ d->DebugMessageCallbackARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLDEBUGPROCARB , const GLvoid *)>(context->getProcAddress("glDebugMessageCallbackARB"));
+ d->DebugMessageInsertARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLenum , GLsizei , const GLchar *)>(context->getProcAddress("glDebugMessageInsertARB"));
+ d->DebugMessageControlARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLsizei , const GLuint *, GLboolean )>(context->getProcAddress("glDebugMessageControlARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_draw_buffers::QOpenGLExtension_ARB_draw_buffers()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_draw_buffersPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_draw_buffers::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_draw_buffers);
+
+ d->DrawBuffersARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLenum *)>(context->getProcAddress("glDrawBuffersARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_draw_buffers_blend::QOpenGLExtension_ARB_draw_buffers_blend()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_draw_buffers_blendPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_draw_buffers_blend::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_draw_buffers_blend);
+
+ d->BlendFuncSeparateiARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLenum , GLenum )>(context->getProcAddress("glBlendFuncSeparateiARB"));
+ d->BlendFunciARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum )>(context->getProcAddress("glBlendFunciARB"));
+ d->BlendEquationSeparateiARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum )>(context->getProcAddress("glBlendEquationSeparateiARB"));
+ d->BlendEquationiARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glBlendEquationiARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_draw_elements_base_vertex::QOpenGLExtension_ARB_draw_elements_base_vertex()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_draw_elements_base_vertexPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_draw_elements_base_vertex::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_draw_elements_base_vertex);
+
+ d->MultiDrawElementsBaseVertex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLsizei *, GLenum , const GLvoid* const *, GLsizei , const GLint *)>(context->getProcAddress("glMultiDrawElementsBaseVertex"));
+ d->DrawElementsInstancedBaseVertex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const GLvoid *, GLsizei , GLint )>(context->getProcAddress("glDrawElementsInstancedBaseVertex"));
+ d->DrawRangeElementsBaseVertex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLsizei , GLenum , const GLvoid *, GLint )>(context->getProcAddress("glDrawRangeElementsBaseVertex"));
+ d->DrawElementsBaseVertex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const GLvoid *, GLint )>(context->getProcAddress("glDrawElementsBaseVertex"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_draw_indirect::QOpenGLExtension_ARB_draw_indirect()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_draw_indirectPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_draw_indirect::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_draw_indirect);
+
+ d->DrawElementsIndirect = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glDrawElementsIndirect"));
+ d->DrawArraysIndirect = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLvoid *)>(context->getProcAddress("glDrawArraysIndirect"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_draw_instanced::QOpenGLExtension_ARB_draw_instanced()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_draw_instancedPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_draw_instanced::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_draw_instanced);
+
+ d->DrawElementsInstancedARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const GLvoid *, GLsizei )>(context->getProcAddress("glDrawElementsInstancedARB"));
+ d->DrawArraysInstancedARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLsizei , GLsizei )>(context->getProcAddress("glDrawArraysInstancedARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_framebuffer_no_attachments::QOpenGLExtension_ARB_framebuffer_no_attachments()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_framebuffer_no_attachmentsPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_framebuffer_no_attachments::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_framebuffer_no_attachments);
+
+ d->GetFramebufferParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetFramebufferParameteriv"));
+ d->FramebufferParameteri = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glFramebufferParameteri"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_framebuffer_object::QOpenGLExtension_ARB_framebuffer_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_framebuffer_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_framebuffer_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+
+ d->FramebufferTextureLayer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLint , GLint )>(context->getProcAddress("glFramebufferTextureLayer"));
+ d->RenderbufferStorageMultisample = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glRenderbufferStorageMultisample"));
+ d->BlitFramebuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint , GLint , GLint , GLint , GLint , GLbitfield , GLenum )>(context->getProcAddress("glBlitFramebuffer"));
+ d->GenerateMipmap = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glGenerateMipmap"));
+ d->GetFramebufferAttachmentParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetFramebufferAttachmentParameteriv"));
+ d->FramebufferRenderbuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint )>(context->getProcAddress("glFramebufferRenderbuffer"));
+ d->FramebufferTexture3D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint , GLint , GLint )>(context->getProcAddress("glFramebufferTexture3D"));
+ d->FramebufferTexture2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint , GLint )>(context->getProcAddress("glFramebufferTexture2D"));
+ d->FramebufferTexture1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint , GLint )>(context->getProcAddress("glFramebufferTexture1D"));
+ d->CheckFramebufferStatus = reinterpret_cast<GLenum (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glCheckFramebufferStatus"));
+ d->GenFramebuffers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenFramebuffers"));
+ d->DeleteFramebuffers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteFramebuffers"));
+ d->BindFramebuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindFramebuffer"));
+ d->IsFramebuffer = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsFramebuffer"));
+ d->GetRenderbufferParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetRenderbufferParameteriv"));
+ d->RenderbufferStorage = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glRenderbufferStorage"));
+ d->GenRenderbuffers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenRenderbuffers"));
+ d->DeleteRenderbuffers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteRenderbuffers"));
+ d->BindRenderbuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindRenderbuffer"));
+ d->IsRenderbuffer = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsRenderbuffer"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_geometry_shader4::QOpenGLExtension_ARB_geometry_shader4()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_geometry_shader4Private))
+{
+}
+
+bool QOpenGLExtension_ARB_geometry_shader4::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_geometry_shader4);
+
+ d->FramebufferTextureFaceARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLint , GLenum )>(context->getProcAddress("glFramebufferTextureFaceARB"));
+ d->FramebufferTextureLayerARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLint , GLint )>(context->getProcAddress("glFramebufferTextureLayerARB"));
+ d->FramebufferTextureARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLint )>(context->getProcAddress("glFramebufferTextureARB"));
+ d->ProgramParameteriARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint )>(context->getProcAddress("glProgramParameteriARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_get_program_binary::QOpenGLExtension_ARB_get_program_binary()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_get_program_binaryPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_get_program_binary::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_get_program_binary);
+
+ d->ProgramParameteri = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint )>(context->getProcAddress("glProgramParameteri"));
+ d->ProgramBinary = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLvoid *, GLsizei )>(context->getProcAddress("glProgramBinary"));
+ d->GetProgramBinary = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei *, GLenum *, GLvoid *)>(context->getProcAddress("glGetProgramBinary"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_gpu_shader_fp64::QOpenGLExtension_ARB_gpu_shader_fp64()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_gpu_shader_fp64Private))
+{
+}
+
+bool QOpenGLExtension_ARB_gpu_shader_fp64::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+
+ d->GetUniformdv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble *)>(context->getProcAddress("glGetUniformdv"));
+ d->UniformMatrix4x3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix4x3dv"));
+ d->UniformMatrix4x2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix4x2dv"));
+ d->UniformMatrix3x4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix3x4dv"));
+ d->UniformMatrix3x2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix3x2dv"));
+ d->UniformMatrix2x4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix2x4dv"));
+ d->UniformMatrix2x3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix2x3dv"));
+ d->UniformMatrix4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix4dv"));
+ d->UniformMatrix3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix3dv"));
+ d->UniformMatrix2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glUniformMatrix2dv"));
+ d->Uniform4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glUniform4dv"));
+ d->Uniform3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glUniform3dv"));
+ d->Uniform2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glUniform2dv"));
+ d->Uniform1dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glUniform1dv"));
+ d->Uniform4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glUniform4d"));
+ d->Uniform3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glUniform3d"));
+ d->Uniform2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLdouble , GLdouble )>(context->getProcAddress("glUniform2d"));
+ d->Uniform1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLdouble )>(context->getProcAddress("glUniform1d"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_instanced_arrays::QOpenGLExtension_ARB_instanced_arrays()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_instanced_arraysPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_instanced_arrays::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_instanced_arrays);
+
+ d->VertexAttribDivisorARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glVertexAttribDivisorARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_internalformat_query::QOpenGLExtension_ARB_internalformat_query()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_internalformat_queryPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_internalformat_query::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_internalformat_query);
+
+ d->GetInternalformativ = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLsizei , GLint *)>(context->getProcAddress("glGetInternalformativ"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_internalformat_query2::QOpenGLExtension_ARB_internalformat_query2()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_internalformat_query2Private))
+{
+}
+
+bool QOpenGLExtension_ARB_internalformat_query2::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_internalformat_query2);
+
+ d->GetInternalformati64v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLsizei , GLint64 *)>(context->getProcAddress("glGetInternalformati64v"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_invalidate_subdata::QOpenGLExtension_ARB_invalidate_subdata()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_invalidate_subdataPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_invalidate_subdata::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_invalidate_subdata);
+
+ d->InvalidateSubFramebuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLenum *, GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glInvalidateSubFramebuffer"));
+ d->InvalidateFramebuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLenum *)>(context->getProcAddress("glInvalidateFramebuffer"));
+ d->InvalidateBufferData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glInvalidateBufferData"));
+ d->InvalidateBufferSubData = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLintptr , GLsizeiptr )>(context->getProcAddress("glInvalidateBufferSubData"));
+ d->InvalidateTexImage = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint )>(context->getProcAddress("glInvalidateTexImage"));
+ d->InvalidateTexSubImage = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei )>(context->getProcAddress("glInvalidateTexSubImage"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_map_buffer_range::QOpenGLExtension_ARB_map_buffer_range()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_map_buffer_rangePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_map_buffer_range::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_map_buffer_range);
+
+ d->FlushMappedBufferRange = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLintptr , GLsizeiptr )>(context->getProcAddress("glFlushMappedBufferRange"));
+ d->MapBufferRange = reinterpret_cast<GLvoid* (QOPENGLF_APIENTRYP)(GLenum , GLintptr , GLsizeiptr , GLbitfield )>(context->getProcAddress("glMapBufferRange"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_matrix_palette::QOpenGLExtension_ARB_matrix_palette()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_matrix_palettePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_matrix_palette::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_matrix_palette);
+
+ d->MatrixIndexPointerARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glMatrixIndexPointerARB"));
+ d->MatrixIndexuivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLuint *)>(context->getProcAddress("glMatrixIndexuivARB"));
+ d->MatrixIndexusvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLushort *)>(context->getProcAddress("glMatrixIndexusvARB"));
+ d->MatrixIndexubvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLubyte *)>(context->getProcAddress("glMatrixIndexubvARB"));
+ d->CurrentPaletteMatrixARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(context->getProcAddress("glCurrentPaletteMatrixARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_multi_draw_indirect::QOpenGLExtension_ARB_multi_draw_indirect()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_multi_draw_indirectPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_multi_draw_indirect::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_multi_draw_indirect);
+
+ d->MultiDrawElementsIndirect = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const void *, GLsizei , GLsizei )>(context->getProcAddress("glMultiDrawElementsIndirect"));
+ d->MultiDrawArraysIndirect = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const void *, GLsizei , GLsizei )>(context->getProcAddress("glMultiDrawArraysIndirect"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_multisample::QOpenGLExtension_ARB_multisample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_multisamplePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_multisample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_multisample);
+
+ d->SampleCoverageARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLboolean )>(context->getProcAddress("glSampleCoverageARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_multitexture::QOpenGLExtension_ARB_multitexture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_multitexturePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_multitexture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_multitexture);
+
+ d->MultiTexCoord4svARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glMultiTexCoord4svARB"));
+ d->MultiTexCoord4sARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort , GLshort , GLshort , GLshort )>(context->getProcAddress("glMultiTexCoord4sARB"));
+ d->MultiTexCoord4ivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glMultiTexCoord4ivARB"));
+ d->MultiTexCoord4iARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint )>(context->getProcAddress("glMultiTexCoord4iARB"));
+ d->MultiTexCoord4fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glMultiTexCoord4fvARB"));
+ d->MultiTexCoord4fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glMultiTexCoord4fARB"));
+ d->MultiTexCoord4dvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glMultiTexCoord4dvARB"));
+ d->MultiTexCoord4dARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glMultiTexCoord4dARB"));
+ d->MultiTexCoord3svARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glMultiTexCoord3svARB"));
+ d->MultiTexCoord3sARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort , GLshort , GLshort )>(context->getProcAddress("glMultiTexCoord3sARB"));
+ d->MultiTexCoord3ivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glMultiTexCoord3ivARB"));
+ d->MultiTexCoord3iARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint )>(context->getProcAddress("glMultiTexCoord3iARB"));
+ d->MultiTexCoord3fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glMultiTexCoord3fvARB"));
+ d->MultiTexCoord3fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glMultiTexCoord3fARB"));
+ d->MultiTexCoord3dvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glMultiTexCoord3dvARB"));
+ d->MultiTexCoord3dARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glMultiTexCoord3dARB"));
+ d->MultiTexCoord2svARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glMultiTexCoord2svARB"));
+ d->MultiTexCoord2sARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort , GLshort )>(context->getProcAddress("glMultiTexCoord2sARB"));
+ d->MultiTexCoord2ivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glMultiTexCoord2ivARB"));
+ d->MultiTexCoord2iARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint )>(context->getProcAddress("glMultiTexCoord2iARB"));
+ d->MultiTexCoord2fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glMultiTexCoord2fvARB"));
+ d->MultiTexCoord2fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat )>(context->getProcAddress("glMultiTexCoord2fARB"));
+ d->MultiTexCoord2dvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glMultiTexCoord2dvARB"));
+ d->MultiTexCoord2dARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble )>(context->getProcAddress("glMultiTexCoord2dARB"));
+ d->MultiTexCoord1svARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glMultiTexCoord1svARB"));
+ d->MultiTexCoord1sARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort )>(context->getProcAddress("glMultiTexCoord1sARB"));
+ d->MultiTexCoord1ivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glMultiTexCoord1ivARB"));
+ d->MultiTexCoord1iARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glMultiTexCoord1iARB"));
+ d->MultiTexCoord1fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glMultiTexCoord1fvARB"));
+ d->MultiTexCoord1fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glMultiTexCoord1fARB"));
+ d->MultiTexCoord1dvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glMultiTexCoord1dvARB"));
+ d->MultiTexCoord1dARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble )>(context->getProcAddress("glMultiTexCoord1dARB"));
+ d->ClientActiveTextureARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glClientActiveTextureARB"));
+ d->ActiveTextureARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glActiveTextureARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_occlusion_query::QOpenGLExtension_ARB_occlusion_query()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_occlusion_queryPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_occlusion_query::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_occlusion_query);
+
+ d->GetQueryObjectuivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint *)>(context->getProcAddress("glGetQueryObjectuivARB"));
+ d->GetQueryObjectivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetQueryObjectivARB"));
+ d->GetQueryivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetQueryivARB"));
+ d->EndQueryARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glEndQueryARB"));
+ d->BeginQueryARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBeginQueryARB"));
+ d->IsQueryARB = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsQueryARB"));
+ d->DeleteQueriesARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteQueriesARB"));
+ d->GenQueriesARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenQueriesARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_point_parameters::QOpenGLExtension_ARB_point_parameters()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_point_parametersPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_point_parameters::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_point_parameters);
+
+ d->PointParameterfvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glPointParameterfvARB"));
+ d->PointParameterfARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glPointParameterfARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_program_interface_query::QOpenGLExtension_ARB_program_interface_query()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_program_interface_queryPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_program_interface_query::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_program_interface_query);
+
+ d->GetProgramResourceLocationIndex = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLchar *)>(context->getProcAddress("glGetProgramResourceLocationIndex"));
+ d->GetProgramResourceLocation = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLchar *)>(context->getProcAddress("glGetProgramResourceLocation"));
+ d->GetProgramResourceiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLsizei , const GLenum *, GLsizei , GLsizei *, GLint *)>(context->getProcAddress("glGetProgramResourceiv"));
+ d->GetProgramResourceName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetProgramResourceName"));
+ d->GetProgramResourceIndex = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLchar *)>(context->getProcAddress("glGetProgramResourceIndex"));
+ d->GetProgramInterfaceiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetProgramInterfaceiv"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_provoking_vertex::QOpenGLExtension_ARB_provoking_vertex()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_provoking_vertexPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_provoking_vertex::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_provoking_vertex);
+
+ d->ProvokingVertex = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glProvokingVertex"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_robustness::QOpenGLExtension_ARB_robustness()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_robustnessPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_robustness::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_robustness);
+
+ d->GetnUniformdvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLdouble *)>(context->getProcAddress("glGetnUniformdvARB"));
+ d->GetnUniformuivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLuint *)>(context->getProcAddress("glGetnUniformuivARB"));
+ d->GetnUniformivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLint *)>(context->getProcAddress("glGetnUniformivARB"));
+ d->GetnUniformfvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLfloat *)>(context->getProcAddress("glGetnUniformfvARB"));
+ d->GetnCompressedTexImageARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLsizei , GLvoid *)>(context->getProcAddress("glGetnCompressedTexImageARB"));
+ d->ReadnPixelsARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLsizei , GLsizei , GLenum , GLenum , GLsizei , GLvoid *)>(context->getProcAddress("glReadnPixelsARB"));
+ d->GetnTexImageARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLenum , GLsizei , GLvoid *)>(context->getProcAddress("glGetnTexImageARB"));
+ d->GetnMinmaxARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLboolean , GLenum , GLenum , GLsizei , GLvoid *)>(context->getProcAddress("glGetnMinmaxARB"));
+ d->GetnHistogramARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLboolean , GLenum , GLenum , GLsizei , GLvoid *)>(context->getProcAddress("glGetnHistogramARB"));
+ d->GetnSeparableFilterARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLsizei , GLvoid *, GLsizei , GLvoid *, GLvoid *)>(context->getProcAddress("glGetnSeparableFilterARB"));
+ d->GetnConvolutionFilterARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLsizei , GLvoid *)>(context->getProcAddress("glGetnConvolutionFilterARB"));
+ d->GetnColorTableARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLsizei , GLvoid *)>(context->getProcAddress("glGetnColorTableARB"));
+ d->GetnPolygonStippleARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLubyte *)>(context->getProcAddress("glGetnPolygonStippleARB"));
+ d->GetnPixelMapusvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLushort *)>(context->getProcAddress("glGetnPixelMapusvARB"));
+ d->GetnPixelMapuivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLuint *)>(context->getProcAddress("glGetnPixelMapuivARB"));
+ d->GetnPixelMapfvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLfloat *)>(context->getProcAddress("glGetnPixelMapfvARB"));
+ d->GetnMapivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLint *)>(context->getProcAddress("glGetnMapivARB"));
+ d->GetnMapfvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLfloat *)>(context->getProcAddress("glGetnMapfvARB"));
+ d->GetnMapdvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLdouble *)>(context->getProcAddress("glGetnMapdvARB"));
+ d->GetGraphicsResetStatusARB = reinterpret_cast<GLenum (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glGetGraphicsResetStatusARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_sample_shading::QOpenGLExtension_ARB_sample_shading()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_sample_shadingPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_sample_shading::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_sample_shading);
+
+ d->MinSampleShadingARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glMinSampleShadingARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_sampler_objects::QOpenGLExtension_ARB_sampler_objects()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_sampler_objectsPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_sampler_objects::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+
+ d->GetSamplerParameterIuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint *)>(context->getProcAddress("glGetSamplerParameterIuiv"));
+ d->GetSamplerParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetSamplerParameterfv"));
+ d->GetSamplerParameterIiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetSamplerParameterIiv"));
+ d->GetSamplerParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetSamplerParameteriv"));
+ d->SamplerParameterIuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLuint *)>(context->getProcAddress("glSamplerParameterIuiv"));
+ d->SamplerParameterIiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLint *)>(context->getProcAddress("glSamplerParameterIiv"));
+ d->SamplerParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLfloat *)>(context->getProcAddress("glSamplerParameterfv"));
+ d->SamplerParameterf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat )>(context->getProcAddress("glSamplerParameterf"));
+ d->SamplerParameteriv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLint *)>(context->getProcAddress("glSamplerParameteriv"));
+ d->SamplerParameteri = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint )>(context->getProcAddress("glSamplerParameteri"));
+ d->BindSampler = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glBindSampler"));
+ d->IsSampler = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsSampler"));
+ d->DeleteSamplers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteSamplers"));
+ d->GenSamplers = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenSamplers"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_separate_shader_objects::QOpenGLExtension_ARB_separate_shader_objects()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_separate_shader_objectsPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_separate_shader_objects::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+
+ d->GetProgramPipelineInfoLog = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetProgramPipelineInfoLog"));
+ d->ValidateProgramPipeline = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glValidateProgramPipeline"));
+ d->ProgramUniformMatrix4x3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix4x3dv"));
+ d->ProgramUniformMatrix3x4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix3x4dv"));
+ d->ProgramUniformMatrix4x2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix4x2dv"));
+ d->ProgramUniformMatrix2x4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix2x4dv"));
+ d->ProgramUniformMatrix3x2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix3x2dv"));
+ d->ProgramUniformMatrix2x3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix2x3dv"));
+ d->ProgramUniformMatrix4x3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix4x3fv"));
+ d->ProgramUniformMatrix3x4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix3x4fv"));
+ d->ProgramUniformMatrix4x2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix4x2fv"));
+ d->ProgramUniformMatrix2x4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix2x4fv"));
+ d->ProgramUniformMatrix3x2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix3x2fv"));
+ d->ProgramUniformMatrix2x3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix2x3fv"));
+ d->ProgramUniformMatrix4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix4dv"));
+ d->ProgramUniformMatrix3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix3dv"));
+ d->ProgramUniformMatrix2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix2dv"));
+ d->ProgramUniformMatrix4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix4fv"));
+ d->ProgramUniformMatrix3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix3fv"));
+ d->ProgramUniformMatrix2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix2fv"));
+ d->ProgramUniform4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramUniform4uiv"));
+ d->ProgramUniform4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glProgramUniform4ui"));
+ d->ProgramUniform4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramUniform4dv"));
+ d->ProgramUniform4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glProgramUniform4d"));
+ d->ProgramUniform4fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramUniform4fv"));
+ d->ProgramUniform4f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glProgramUniform4f"));
+ d->ProgramUniform4iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint *)>(context->getProcAddress("glProgramUniform4iv"));
+ d->ProgramUniform4i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glProgramUniform4i"));
+ d->ProgramUniform3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramUniform3uiv"));
+ d->ProgramUniform3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint , GLuint , GLuint )>(context->getProcAddress("glProgramUniform3ui"));
+ d->ProgramUniform3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramUniform3dv"));
+ d->ProgramUniform3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glProgramUniform3d"));
+ d->ProgramUniform3fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramUniform3fv"));
+ d->ProgramUniform3f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glProgramUniform3f"));
+ d->ProgramUniform3iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint *)>(context->getProcAddress("glProgramUniform3iv"));
+ d->ProgramUniform3i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glProgramUniform3i"));
+ d->ProgramUniform2uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramUniform2uiv"));
+ d->ProgramUniform2ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint , GLuint )>(context->getProcAddress("glProgramUniform2ui"));
+ d->ProgramUniform2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramUniform2dv"));
+ d->ProgramUniform2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble , GLdouble )>(context->getProcAddress("glProgramUniform2d"));
+ d->ProgramUniform2fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramUniform2fv"));
+ d->ProgramUniform2f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat , GLfloat )>(context->getProcAddress("glProgramUniform2f"));
+ d->ProgramUniform2iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint *)>(context->getProcAddress("glProgramUniform2iv"));
+ d->ProgramUniform2i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint )>(context->getProcAddress("glProgramUniform2i"));
+ d->ProgramUniform1uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramUniform1uiv"));
+ d->ProgramUniform1ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint )>(context->getProcAddress("glProgramUniform1ui"));
+ d->ProgramUniform1dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramUniform1dv"));
+ d->ProgramUniform1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble )>(context->getProcAddress("glProgramUniform1d"));
+ d->ProgramUniform1fv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramUniform1fv"));
+ d->ProgramUniform1f = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat )>(context->getProcAddress("glProgramUniform1f"));
+ d->ProgramUniform1iv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint *)>(context->getProcAddress("glProgramUniform1iv"));
+ d->ProgramUniform1i = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint )>(context->getProcAddress("glProgramUniform1i"));
+ d->GetProgramPipelineiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetProgramPipelineiv"));
+ d->IsProgramPipeline = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsProgramPipeline"));
+ d->GenProgramPipelines = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenProgramPipelines"));
+ d->DeleteProgramPipelines = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteProgramPipelines"));
+ d->BindProgramPipeline = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glBindProgramPipeline"));
+ d->CreateShaderProgramv = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLchar* const *)>(context->getProcAddress("glCreateShaderProgramv"));
+ d->ActiveShaderProgram = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glActiveShaderProgram"));
+ d->UseProgramStages = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLbitfield , GLuint )>(context->getProcAddress("glUseProgramStages"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_shader_atomic_counters::QOpenGLExtension_ARB_shader_atomic_counters()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_shader_atomic_countersPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_shader_atomic_counters::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_shader_atomic_counters);
+
+ d->GetActiveAtomicCounterBufferiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , GLint *)>(context->getProcAddress("glGetActiveAtomicCounterBufferiv"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_shader_image_load_store::QOpenGLExtension_ARB_shader_image_load_store()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_shader_image_load_storePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_shader_image_load_store::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_shader_image_load_store);
+
+ d->MemoryBarrier = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(context->getProcAddress("glMemoryBarrier"));
+ d->BindImageTexture = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLint , GLboolean , GLint , GLenum , GLenum )>(context->getProcAddress("glBindImageTexture"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_shader_objects::QOpenGLExtension_ARB_shader_objects()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_shader_objectsPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_shader_objects::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+
+ d->GetShaderSourceARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLsizei , GLsizei *, GLcharARB *)>(context->getProcAddress("glGetShaderSourceARB"));
+ d->GetUniformivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLint , GLint *)>(context->getProcAddress("glGetUniformivARB"));
+ d->GetUniformfvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLint , GLfloat *)>(context->getProcAddress("glGetUniformfvARB"));
+ d->GetActiveUniformARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLuint , GLsizei , GLsizei *, GLint *, GLenum *, GLcharARB *)>(context->getProcAddress("glGetActiveUniformARB"));
+ d->GetUniformLocationARB = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLhandleARB , const GLcharARB *)>(context->getProcAddress("glGetUniformLocationARB"));
+ d->GetAttachedObjectsARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLsizei , GLsizei *, GLhandleARB *)>(context->getProcAddress("glGetAttachedObjectsARB"));
+ d->GetInfoLogARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLsizei , GLsizei *, GLcharARB *)>(context->getProcAddress("glGetInfoLogARB"));
+ d->GetObjectParameterivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLenum , GLint *)>(context->getProcAddress("glGetObjectParameterivARB"));
+ d->GetObjectParameterfvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLenum , GLfloat *)>(context->getProcAddress("glGetObjectParameterfvARB"));
+ d->UniformMatrix4fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glUniformMatrix4fvARB"));
+ d->UniformMatrix3fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glUniformMatrix3fvARB"));
+ d->UniformMatrix2fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glUniformMatrix2fvARB"));
+ d->Uniform4ivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLint *)>(context->getProcAddress("glUniform4ivARB"));
+ d->Uniform3ivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLint *)>(context->getProcAddress("glUniform3ivARB"));
+ d->Uniform2ivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLint *)>(context->getProcAddress("glUniform2ivARB"));
+ d->Uniform1ivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLint *)>(context->getProcAddress("glUniform1ivARB"));
+ d->Uniform4fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glUniform4fvARB"));
+ d->Uniform3fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glUniform3fvARB"));
+ d->Uniform2fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glUniform2fvARB"));
+ d->Uniform1fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glUniform1fvARB"));
+ d->Uniform4iARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glUniform4iARB"));
+ d->Uniform3iARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(context->getProcAddress("glUniform3iARB"));
+ d->Uniform2iARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glUniform2iARB"));
+ d->Uniform1iARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(context->getProcAddress("glUniform1iARB"));
+ d->Uniform4fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glUniform4fARB"));
+ d->Uniform3fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glUniform3fARB"));
+ d->Uniform2fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLfloat , GLfloat )>(context->getProcAddress("glUniform2fARB"));
+ d->Uniform1fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLfloat )>(context->getProcAddress("glUniform1fARB"));
+ d->ValidateProgramARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB )>(context->getProcAddress("glValidateProgramARB"));
+ d->UseProgramObjectARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB )>(context->getProcAddress("glUseProgramObjectARB"));
+ d->LinkProgramARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB )>(context->getProcAddress("glLinkProgramARB"));
+ d->AttachObjectARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLhandleARB )>(context->getProcAddress("glAttachObjectARB"));
+ d->CreateProgramObjectARB = reinterpret_cast<GLhandleARB (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glCreateProgramObjectARB"));
+ d->CompileShaderARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB )>(context->getProcAddress("glCompileShaderARB"));
+ d->ShaderSourceARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLsizei , const GLcharARB* *, const GLint *)>(context->getProcAddress("glShaderSourceARB"));
+ d->CreateShaderObjectARB = reinterpret_cast<GLhandleARB (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glCreateShaderObjectARB"));
+ d->DetachObjectARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLhandleARB )>(context->getProcAddress("glDetachObjectARB"));
+ d->GetHandleARB = reinterpret_cast<GLhandleARB (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glGetHandleARB"));
+ d->DeleteObjectARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB )>(context->getProcAddress("glDeleteObjectARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_shader_storage_buffer_object::QOpenGLExtension_ARB_shader_storage_buffer_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_shader_storage_buffer_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_shader_storage_buffer_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_shader_storage_buffer_object);
+
+ d->ShaderStorageBlockBinding = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glShaderStorageBlockBinding"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_shader_subroutine::QOpenGLExtension_ARB_shader_subroutine()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_shader_subroutinePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_shader_subroutine::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_shader_subroutine);
+
+ d->GetProgramStageiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetProgramStageiv"));
+ d->GetUniformSubroutineuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLuint *)>(context->getProcAddress("glGetUniformSubroutineuiv"));
+ d->UniformSubroutinesuiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLuint *)>(context->getProcAddress("glUniformSubroutinesuiv"));
+ d->GetActiveSubroutineName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetActiveSubroutineName"));
+ d->GetActiveSubroutineUniformName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetActiveSubroutineUniformName"));
+ d->GetActiveSubroutineUniformiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLenum , GLint *)>(context->getProcAddress("glGetActiveSubroutineUniformiv"));
+ d->GetSubroutineIndex = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLchar *)>(context->getProcAddress("glGetSubroutineIndex"));
+ d->GetSubroutineUniformLocation = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLchar *)>(context->getProcAddress("glGetSubroutineUniformLocation"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_shading_language_include::QOpenGLExtension_ARB_shading_language_include()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_shading_language_includePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_shading_language_include::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_shading_language_include);
+
+ d->GetNamedStringivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLchar *, GLenum , GLint *)>(context->getProcAddress("glGetNamedStringivARB"));
+ d->GetNamedStringARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLchar *, GLsizei , GLint *, GLchar *)>(context->getProcAddress("glGetNamedStringARB"));
+ d->IsNamedStringARB = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLint , const GLchar *)>(context->getProcAddress("glIsNamedStringARB"));
+ d->CompileShaderIncludeARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLchar* *, const GLint *)>(context->getProcAddress("glCompileShaderIncludeARB"));
+ d->DeleteNamedStringARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLchar *)>(context->getProcAddress("glDeleteNamedStringARB"));
+ d->NamedStringARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLchar *, GLint , const GLchar *)>(context->getProcAddress("glNamedStringARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_sync::QOpenGLExtension_ARB_sync()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_syncPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_sync::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_sync);
+
+ d->GetSynciv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsync , GLenum , GLsizei , GLsizei *, GLint *)>(context->getProcAddress("glGetSynciv"));
+ d->GetInteger64v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint64 *)>(context->getProcAddress("glGetInteger64v"));
+ d->WaitSync = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsync , GLbitfield , GLuint64 )>(context->getProcAddress("glWaitSync"));
+ d->ClientWaitSync = reinterpret_cast<GLenum (QOPENGLF_APIENTRYP)(GLsync , GLbitfield , GLuint64 )>(context->getProcAddress("glClientWaitSync"));
+ d->DeleteSync = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsync )>(context->getProcAddress("glDeleteSync"));
+ d->IsSync = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLsync )>(context->getProcAddress("glIsSync"));
+ d->FenceSync = reinterpret_cast<GLsync (QOPENGLF_APIENTRYP)(GLenum , GLbitfield )>(context->getProcAddress("glFenceSync"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_tessellation_shader::QOpenGLExtension_ARB_tessellation_shader()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_tessellation_shaderPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_tessellation_shader::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_tessellation_shader);
+
+ d->PatchParameterfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glPatchParameterfv"));
+ d->PatchParameteri = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glPatchParameteri"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_texture_buffer_object::QOpenGLExtension_ARB_texture_buffer_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_texture_buffer_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_texture_buffer_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_texture_buffer_object);
+
+ d->TexBufferARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glTexBufferARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_texture_buffer_range::QOpenGLExtension_ARB_texture_buffer_range()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_texture_buffer_rangePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_texture_buffer_range::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_texture_buffer_range);
+
+ d->TexBufferRange = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLintptr , GLsizeiptr )>(context->getProcAddress("glTexBufferRange"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_texture_compression::QOpenGLExtension_ARB_texture_compression()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_texture_compressionPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_texture_compression::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_texture_compression);
+
+ d->GetCompressedTexImageARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLvoid *)>(context->getProcAddress("glGetCompressedTexImageARB"));
+ d->CompressedTexSubImage1DARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLsizei , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTexSubImage1DARB"));
+ d->CompressedTexSubImage2DARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLsizei , GLsizei , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTexSubImage2DARB"));
+ d->CompressedTexSubImage3DARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTexSubImage3DARB"));
+ d->CompressedTexImage1DARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLsizei , GLint , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTexImage1DARB"));
+ d->CompressedTexImage2DARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLsizei , GLsizei , GLint , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTexImage2DARB"));
+ d->CompressedTexImage3DARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLsizei , GLsizei , GLsizei , GLint , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTexImage3DARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_texture_multisample::QOpenGLExtension_ARB_texture_multisample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_texture_multisamplePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_texture_multisample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_texture_multisample);
+
+ d->SampleMaski = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLbitfield )>(context->getProcAddress("glSampleMaski"));
+ d->GetMultisamplefv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLfloat *)>(context->getProcAddress("glGetMultisamplefv"));
+ d->TexImage3DMultisample = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLint , GLsizei , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTexImage3DMultisample"));
+ d->TexImage2DMultisample = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLint , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTexImage2DMultisample"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_texture_storage::QOpenGLExtension_ARB_texture_storage()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_texture_storagePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_texture_storage::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_texture_storage);
+
+ d->TexStorage3D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei , GLsizei , GLsizei )>(context->getProcAddress("glTexStorage3D"));
+ d->TexStorage2D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glTexStorage2D"));
+ d->TexStorage1D = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei )>(context->getProcAddress("glTexStorage1D"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_texture_storage_multisample::QOpenGLExtension_ARB_texture_storage_multisample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_texture_storage_multisamplePrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_texture_storage_multisample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_texture_storage_multisample);
+
+ d->TexStorage3DMultisample = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTexStorage3DMultisample"));
+ d->TexStorage2DMultisample = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTexStorage2DMultisample"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_texture_view::QOpenGLExtension_ARB_texture_view()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_texture_viewPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_texture_view::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_texture_view);
+
+ d->TextureView = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLenum , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glTextureView"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_timer_query::QOpenGLExtension_ARB_timer_query()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_timer_queryPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_timer_query::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_timer_query);
+
+ d->GetQueryObjectui64v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint64 *)>(context->getProcAddress("glGetQueryObjectui64v"));
+ d->GetQueryObjecti64v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint64 *)>(context->getProcAddress("glGetQueryObjecti64v"));
+ d->QueryCounter = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glQueryCounter"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_transform_feedback2::QOpenGLExtension_ARB_transform_feedback2()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_transform_feedback2Private))
+{
+}
+
+bool QOpenGLExtension_ARB_transform_feedback2::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_transform_feedback2);
+
+ d->DrawTransformFeedback = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glDrawTransformFeedback"));
+ d->ResumeTransformFeedback = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glResumeTransformFeedback"));
+ d->PauseTransformFeedback = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glPauseTransformFeedback"));
+ d->IsTransformFeedback = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsTransformFeedback"));
+ d->GenTransformFeedbacks = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenTransformFeedbacks"));
+ d->DeleteTransformFeedbacks = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteTransformFeedbacks"));
+ d->BindTransformFeedback = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindTransformFeedback"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_transform_feedback3::QOpenGLExtension_ARB_transform_feedback3()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_transform_feedback3Private))
+{
+}
+
+bool QOpenGLExtension_ARB_transform_feedback3::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_transform_feedback3);
+
+ d->GetQueryIndexediv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum , GLint *)>(context->getProcAddress("glGetQueryIndexediv"));
+ d->EndQueryIndexed = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glEndQueryIndexed"));
+ d->BeginQueryIndexed = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint )>(context->getProcAddress("glBeginQueryIndexed"));
+ d->DrawTransformFeedbackStream = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint )>(context->getProcAddress("glDrawTransformFeedbackStream"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_transform_feedback_instanced::QOpenGLExtension_ARB_transform_feedback_instanced()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_transform_feedback_instancedPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_transform_feedback_instanced::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_transform_feedback_instanced);
+
+ d->DrawTransformFeedbackStreamInstanced = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLsizei )>(context->getProcAddress("glDrawTransformFeedbackStreamInstanced"));
+ d->DrawTransformFeedbackInstanced = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei )>(context->getProcAddress("glDrawTransformFeedbackInstanced"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_transpose_matrix::QOpenGLExtension_ARB_transpose_matrix()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_transpose_matrixPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_transpose_matrix::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_transpose_matrix);
+
+ d->MultTransposeMatrixdARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glMultTransposeMatrixdARB"));
+ d->MultTransposeMatrixfARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glMultTransposeMatrixfARB"));
+ d->LoadTransposeMatrixdARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glLoadTransposeMatrixdARB"));
+ d->LoadTransposeMatrixfARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glLoadTransposeMatrixfARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_uniform_buffer_object::QOpenGLExtension_ARB_uniform_buffer_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_uniform_buffer_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_uniform_buffer_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_uniform_buffer_object);
+
+ d->UniformBlockBinding = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glUniformBlockBinding"));
+ d->GetActiveUniformBlockName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetActiveUniformBlockName"));
+ d->GetActiveUniformBlockiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , GLint *)>(context->getProcAddress("glGetActiveUniformBlockiv"));
+ d->GetUniformBlockIndex = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLuint , const GLchar *)>(context->getProcAddress("glGetUniformBlockIndex"));
+ d->GetActiveUniformName = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetActiveUniformName"));
+ d->GetActiveUniformsiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLuint *, GLenum , GLint *)>(context->getProcAddress("glGetActiveUniformsiv"));
+ d->GetUniformIndices = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLchar* const *, GLuint *)>(context->getProcAddress("glGetUniformIndices"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_vertex_array_object::QOpenGLExtension_ARB_vertex_array_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_vertex_array_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_vertex_array_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_vertex_array_object);
+
+ d->IsVertexArray = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsVertexArray"));
+ d->GenVertexArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenVertexArrays"));
+ d->DeleteVertexArrays = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteVertexArrays"));
+ d->BindVertexArray = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glBindVertexArray"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_vertex_attrib_64bit::QOpenGLExtension_ARB_vertex_attrib_64bit()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_vertex_attrib_64bitPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_vertex_attrib_64bit::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_64bit);
+
+ d->GetVertexAttribLdv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLdouble *)>(context->getProcAddress("glGetVertexAttribLdv"));
+ d->VertexAttribLPointer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glVertexAttribLPointer"));
+ d->VertexAttribL4dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttribL4dv"));
+ d->VertexAttribL3dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttribL3dv"));
+ d->VertexAttribL2dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttribL2dv"));
+ d->VertexAttribL1dv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttribL1dv"));
+ d->VertexAttribL4d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttribL4d"));
+ d->VertexAttribL3d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttribL3d"));
+ d->VertexAttribL2d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttribL2d"));
+ d->VertexAttribL1d = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble )>(context->getProcAddress("glVertexAttribL1d"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_vertex_attrib_binding::QOpenGLExtension_ARB_vertex_attrib_binding()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_vertex_attrib_bindingPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_vertex_attrib_binding::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_binding);
+
+ d->VertexBindingDivisor = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glVertexBindingDivisor"));
+ d->VertexAttribBinding = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glVertexAttribBinding"));
+ d->VertexAttribLFormat = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLuint )>(context->getProcAddress("glVertexAttribLFormat"));
+ d->VertexAttribIFormat = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLuint )>(context->getProcAddress("glVertexAttribIFormat"));
+ d->VertexAttribFormat = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLboolean , GLuint )>(context->getProcAddress("glVertexAttribFormat"));
+ d->BindVertexBuffer = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLintptr , GLsizei )>(context->getProcAddress("glBindVertexBuffer"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_vertex_blend::QOpenGLExtension_ARB_vertex_blend()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_vertex_blendPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_vertex_blend::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_vertex_blend);
+
+ d->VertexBlendARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(context->getProcAddress("glVertexBlendARB"));
+ d->WeightPointerARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glWeightPointerARB"));
+ d->WeightuivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLuint *)>(context->getProcAddress("glWeightuivARB"));
+ d->WeightusvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLushort *)>(context->getProcAddress("glWeightusvARB"));
+ d->WeightubvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLubyte *)>(context->getProcAddress("glWeightubvARB"));
+ d->WeightdvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLdouble *)>(context->getProcAddress("glWeightdvARB"));
+ d->WeightfvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLfloat *)>(context->getProcAddress("glWeightfvARB"));
+ d->WeightivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLint *)>(context->getProcAddress("glWeightivARB"));
+ d->WeightsvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLshort *)>(context->getProcAddress("glWeightsvARB"));
+ d->WeightbvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLbyte *)>(context->getProcAddress("glWeightbvARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_vertex_buffer_object::QOpenGLExtension_ARB_vertex_buffer_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_vertex_buffer_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_vertex_buffer_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_vertex_buffer_object);
+
+ d->GetBufferPointervARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLvoid* *)>(context->getProcAddress("glGetBufferPointervARB"));
+ d->GetBufferParameterivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetBufferParameterivARB"));
+ d->UnmapBufferARB = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glUnmapBufferARB"));
+ d->MapBufferARB = reinterpret_cast<GLvoid* (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glMapBufferARB"));
+ d->GetBufferSubDataARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLintptrARB , GLsizeiptrARB , GLvoid *)>(context->getProcAddress("glGetBufferSubDataARB"));
+ d->BufferSubDataARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLintptrARB , GLsizeiptrARB , const GLvoid *)>(context->getProcAddress("glBufferSubDataARB"));
+ d->BufferDataARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizeiptrARB , const GLvoid *, GLenum )>(context->getProcAddress("glBufferDataARB"));
+ d->IsBufferARB = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsBufferARB"));
+ d->GenBuffersARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenBuffersARB"));
+ d->DeleteBuffersARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteBuffersARB"));
+ d->BindBufferARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindBufferARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_vertex_program::QOpenGLExtension_ARB_vertex_program()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_vertex_programPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_vertex_program::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+
+ d->IsProgramARB = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsProgramARB"));
+ d->GetVertexAttribPointervARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLvoid* *)>(context->getProcAddress("glGetVertexAttribPointervARB"));
+ d->GetVertexAttribivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetVertexAttribivARB"));
+ d->GetVertexAttribfvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetVertexAttribfvARB"));
+ d->GetVertexAttribdvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLdouble *)>(context->getProcAddress("glGetVertexAttribdvARB"));
+ d->GetProgramStringARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetProgramStringARB"));
+ d->GetProgramivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetProgramivARB"));
+ d->GetProgramLocalParameterfvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLfloat *)>(context->getProcAddress("glGetProgramLocalParameterfvARB"));
+ d->GetProgramLocalParameterdvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLdouble *)>(context->getProcAddress("glGetProgramLocalParameterdvARB"));
+ d->GetProgramEnvParameterfvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLfloat *)>(context->getProcAddress("glGetProgramEnvParameterfvARB"));
+ d->GetProgramEnvParameterdvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLdouble *)>(context->getProcAddress("glGetProgramEnvParameterdvARB"));
+ d->ProgramLocalParameter4fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLfloat *)>(context->getProcAddress("glProgramLocalParameter4fvARB"));
+ d->ProgramLocalParameter4fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glProgramLocalParameter4fARB"));
+ d->ProgramLocalParameter4dvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLdouble *)>(context->getProcAddress("glProgramLocalParameter4dvARB"));
+ d->ProgramLocalParameter4dARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glProgramLocalParameter4dARB"));
+ d->ProgramEnvParameter4fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLfloat *)>(context->getProcAddress("glProgramEnvParameter4fvARB"));
+ d->ProgramEnvParameter4fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glProgramEnvParameter4fARB"));
+ d->ProgramEnvParameter4dvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLdouble *)>(context->getProcAddress("glProgramEnvParameter4dvARB"));
+ d->ProgramEnvParameter4dARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glProgramEnvParameter4dARB"));
+ d->GenProgramsARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenProgramsARB"));
+ d->DeleteProgramsARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteProgramsARB"));
+ d->BindProgramARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindProgramARB"));
+ d->ProgramStringARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glProgramStringARB"));
+ d->DisableVertexAttribArrayARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glDisableVertexAttribArrayARB"));
+ d->EnableVertexAttribArrayARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glEnableVertexAttribArrayARB"));
+ d->VertexAttribPointerARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLboolean , GLsizei , const GLvoid *)>(context->getProcAddress("glVertexAttribPointerARB"));
+ d->VertexAttrib4usvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLushort *)>(context->getProcAddress("glVertexAttrib4usvARB"));
+ d->VertexAttrib4uivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVertexAttrib4uivARB"));
+ d->VertexAttrib4ubvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLubyte *)>(context->getProcAddress("glVertexAttrib4ubvARB"));
+ d->VertexAttrib4svARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib4svARB"));
+ d->VertexAttrib4sARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLshort , GLshort , GLshort , GLshort )>(context->getProcAddress("glVertexAttrib4sARB"));
+ d->VertexAttrib4ivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVertexAttrib4ivARB"));
+ d->VertexAttrib4fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVertexAttrib4fvARB"));
+ d->VertexAttrib4fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glVertexAttrib4fARB"));
+ d->VertexAttrib4dvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttrib4dvARB"));
+ d->VertexAttrib4dARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttrib4dARB"));
+ d->VertexAttrib4bvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLbyte *)>(context->getProcAddress("glVertexAttrib4bvARB"));
+ d->VertexAttrib4NusvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLushort *)>(context->getProcAddress("glVertexAttrib4NusvARB"));
+ d->VertexAttrib4NuivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVertexAttrib4NuivARB"));
+ d->VertexAttrib4NubvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLubyte *)>(context->getProcAddress("glVertexAttrib4NubvARB"));
+ d->VertexAttrib4NubARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLubyte , GLubyte , GLubyte , GLubyte )>(context->getProcAddress("glVertexAttrib4NubARB"));
+ d->VertexAttrib4NsvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib4NsvARB"));
+ d->VertexAttrib4NivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVertexAttrib4NivARB"));
+ d->VertexAttrib4NbvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLbyte *)>(context->getProcAddress("glVertexAttrib4NbvARB"));
+ d->VertexAttrib3svARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib3svARB"));
+ d->VertexAttrib3sARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLshort , GLshort , GLshort )>(context->getProcAddress("glVertexAttrib3sARB"));
+ d->VertexAttrib3fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVertexAttrib3fvARB"));
+ d->VertexAttrib3fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glVertexAttrib3fARB"));
+ d->VertexAttrib3dvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttrib3dvARB"));
+ d->VertexAttrib3dARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttrib3dARB"));
+ d->VertexAttrib2svARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib2svARB"));
+ d->VertexAttrib2sARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLshort , GLshort )>(context->getProcAddress("glVertexAttrib2sARB"));
+ d->VertexAttrib2fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVertexAttrib2fvARB"));
+ d->VertexAttrib2fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat )>(context->getProcAddress("glVertexAttrib2fARB"));
+ d->VertexAttrib2dvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttrib2dvARB"));
+ d->VertexAttrib2dARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttrib2dARB"));
+ d->VertexAttrib1svARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib1svARB"));
+ d->VertexAttrib1sARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLshort )>(context->getProcAddress("glVertexAttrib1sARB"));
+ d->VertexAttrib1fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVertexAttrib1fvARB"));
+ d->VertexAttrib1fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat )>(context->getProcAddress("glVertexAttrib1fARB"));
+ d->VertexAttrib1dvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttrib1dvARB"));
+ d->VertexAttrib1dARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble )>(context->getProcAddress("glVertexAttrib1dARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_vertex_shader::QOpenGLExtension_ARB_vertex_shader()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_vertex_shaderPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_vertex_shader::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_vertex_shader);
+
+ d->GetAttribLocationARB = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLhandleARB , const GLcharARB *)>(context->getProcAddress("glGetAttribLocationARB"));
+ d->GetActiveAttribARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLuint , GLsizei , GLsizei *, GLint *, GLenum *, GLcharARB *)>(context->getProcAddress("glGetActiveAttribARB"));
+ d->BindAttribLocationARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhandleARB , GLuint , const GLcharARB *)>(context->getProcAddress("glBindAttribLocationARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_vertex_type_2_10_10_10_revPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+
+ d->VertexAttribP4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , const GLuint *)>(context->getProcAddress("glVertexAttribP4uiv"));
+ d->VertexAttribP4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , GLuint )>(context->getProcAddress("glVertexAttribP4ui"));
+ d->VertexAttribP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , const GLuint *)>(context->getProcAddress("glVertexAttribP3uiv"));
+ d->VertexAttribP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , GLuint )>(context->getProcAddress("glVertexAttribP3ui"));
+ d->VertexAttribP2uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , const GLuint *)>(context->getProcAddress("glVertexAttribP2uiv"));
+ d->VertexAttribP2ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , GLuint )>(context->getProcAddress("glVertexAttribP2ui"));
+ d->VertexAttribP1uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , const GLuint *)>(context->getProcAddress("glVertexAttribP1uiv"));
+ d->VertexAttribP1ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean , GLuint )>(context->getProcAddress("glVertexAttribP1ui"));
+ d->SecondaryColorP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glSecondaryColorP3uiv"));
+ d->SecondaryColorP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glSecondaryColorP3ui"));
+ d->ColorP4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glColorP4uiv"));
+ d->ColorP4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glColorP4ui"));
+ d->ColorP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glColorP3uiv"));
+ d->ColorP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glColorP3ui"));
+ d->NormalP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glNormalP3uiv"));
+ d->NormalP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glNormalP3ui"));
+ d->MultiTexCoordP4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLuint *)>(context->getProcAddress("glMultiTexCoordP4uiv"));
+ d->MultiTexCoordP4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glMultiTexCoordP4ui"));
+ d->MultiTexCoordP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLuint *)>(context->getProcAddress("glMultiTexCoordP3uiv"));
+ d->MultiTexCoordP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glMultiTexCoordP3ui"));
+ d->MultiTexCoordP2uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLuint *)>(context->getProcAddress("glMultiTexCoordP2uiv"));
+ d->MultiTexCoordP2ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glMultiTexCoordP2ui"));
+ d->MultiTexCoordP1uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLuint *)>(context->getProcAddress("glMultiTexCoordP1uiv"));
+ d->MultiTexCoordP1ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glMultiTexCoordP1ui"));
+ d->TexCoordP4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glTexCoordP4uiv"));
+ d->TexCoordP4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glTexCoordP4ui"));
+ d->TexCoordP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glTexCoordP3uiv"));
+ d->TexCoordP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glTexCoordP3ui"));
+ d->TexCoordP2uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glTexCoordP2uiv"));
+ d->TexCoordP2ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glTexCoordP2ui"));
+ d->TexCoordP1uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glTexCoordP1uiv"));
+ d->TexCoordP1ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glTexCoordP1ui"));
+ d->VertexP4uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glVertexP4uiv"));
+ d->VertexP4ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glVertexP4ui"));
+ d->VertexP3uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glVertexP3uiv"));
+ d->VertexP3ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glVertexP3ui"));
+ d->VertexP2uiv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLuint *)>(context->getProcAddress("glVertexP2uiv"));
+ d->VertexP2ui = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glVertexP2ui"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_viewport_array::QOpenGLExtension_ARB_viewport_array()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_viewport_arrayPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_viewport_array::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_viewport_array);
+
+ d->GetDoublei_v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLdouble *)>(context->getProcAddress("glGetDoublei_v"));
+ d->GetFloati_v = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLfloat *)>(context->getProcAddress("glGetFloati_v"));
+ d->DepthRangeIndexed = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble )>(context->getProcAddress("glDepthRangeIndexed"));
+ d->DepthRangeArrayv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLdouble *)>(context->getProcAddress("glDepthRangeArrayv"));
+ d->ScissorIndexedv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glScissorIndexedv"));
+ d->ScissorIndexed = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glScissorIndexed"));
+ d->ScissorArrayv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLint *)>(context->getProcAddress("glScissorArrayv"));
+ d->ViewportIndexedfv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glViewportIndexedfv"));
+ d->ViewportIndexedf = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glViewportIndexedf"));
+ d->ViewportArrayv = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLfloat *)>(context->getProcAddress("glViewportArrayv"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ARB_window_pos::QOpenGLExtension_ARB_window_pos()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ARB_window_posPrivate))
+{
+}
+
+bool QOpenGLExtension_ARB_window_pos::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ARB_window_pos);
+
+ d->WindowPos3svARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glWindowPos3svARB"));
+ d->WindowPos3sARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(context->getProcAddress("glWindowPos3sARB"));
+ d->WindowPos3ivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glWindowPos3ivARB"));
+ d->WindowPos3iARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glWindowPos3iARB"));
+ d->WindowPos3fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glWindowPos3fvARB"));
+ d->WindowPos3fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glWindowPos3fARB"));
+ d->WindowPos3dvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glWindowPos3dvARB"));
+ d->WindowPos3dARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glWindowPos3dARB"));
+ d->WindowPos2svARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glWindowPos2svARB"));
+ d->WindowPos2sARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort )>(context->getProcAddress("glWindowPos2sARB"));
+ d->WindowPos2ivARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glWindowPos2ivARB"));
+ d->WindowPos2iARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(context->getProcAddress("glWindowPos2iARB"));
+ d->WindowPos2fvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glWindowPos2fvARB"));
+ d->WindowPos2fARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glWindowPos2fARB"));
+ d->WindowPos2dvARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glWindowPos2dvARB"));
+ d->WindowPos2dARB = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(context->getProcAddress("glWindowPos2dARB"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ATI_draw_buffers::QOpenGLExtension_ATI_draw_buffers()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ATI_draw_buffersPrivate))
+{
+}
+
+bool QOpenGLExtension_ATI_draw_buffers::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ATI_draw_buffers);
+
+ d->DrawBuffersATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLenum *)>(context->getProcAddress("glDrawBuffersATI"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ATI_element_array::QOpenGLExtension_ATI_element_array()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ATI_element_arrayPrivate))
+{
+}
+
+bool QOpenGLExtension_ATI_element_array::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ATI_element_array);
+
+ d->DrawRangeElementArrayATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLsizei )>(context->getProcAddress("glDrawRangeElementArrayATI"));
+ d->DrawElementArrayATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei )>(context->getProcAddress("glDrawElementArrayATI"));
+ d->ElementPointerATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLvoid *)>(context->getProcAddress("glElementPointerATI"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ATI_envmap_bumpmap::QOpenGLExtension_ATI_envmap_bumpmap()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ATI_envmap_bumpmapPrivate))
+{
+}
+
+bool QOpenGLExtension_ATI_envmap_bumpmap::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ATI_envmap_bumpmap);
+
+ d->GetTexBumpParameterfvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat *)>(context->getProcAddress("glGetTexBumpParameterfvATI"));
+ d->GetTexBumpParameterivATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint *)>(context->getProcAddress("glGetTexBumpParameterivATI"));
+ d->TexBumpParameterfvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glTexBumpParameterfvATI"));
+ d->TexBumpParameterivATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glTexBumpParameterivATI"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ATI_fragment_shader::QOpenGLExtension_ATI_fragment_shader()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ATI_fragment_shaderPrivate))
+{
+}
+
+bool QOpenGLExtension_ATI_fragment_shader::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+
+ d->SetFragmentShaderConstantATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glSetFragmentShaderConstantATI"));
+ d->AlphaFragmentOp3ATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glAlphaFragmentOp3ATI"));
+ d->AlphaFragmentOp2ATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glAlphaFragmentOp2ATI"));
+ d->AlphaFragmentOp1ATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glAlphaFragmentOp1ATI"));
+ d->ColorFragmentOp3ATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glColorFragmentOp3ATI"));
+ d->ColorFragmentOp2ATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glColorFragmentOp2ATI"));
+ d->ColorFragmentOp1ATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glColorFragmentOp1ATI"));
+ d->SampleMapATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum )>(context->getProcAddress("glSampleMapATI"));
+ d->PassTexCoordATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum )>(context->getProcAddress("glPassTexCoordATI"));
+ d->EndFragmentShaderATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glEndFragmentShaderATI"));
+ d->BeginFragmentShaderATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glBeginFragmentShaderATI"));
+ d->DeleteFragmentShaderATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glDeleteFragmentShaderATI"));
+ d->BindFragmentShaderATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glBindFragmentShaderATI"));
+ d->GenFragmentShadersATI = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glGenFragmentShadersATI"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ATI_map_object_buffer::QOpenGLExtension_ATI_map_object_buffer()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ATI_map_object_bufferPrivate))
+{
+}
+
+bool QOpenGLExtension_ATI_map_object_buffer::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ATI_map_object_buffer);
+
+ d->UnmapObjectBufferATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glUnmapObjectBufferATI"));
+ d->MapObjectBufferATI = reinterpret_cast<GLvoid* (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glMapObjectBufferATI"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ATI_pn_triangles::QOpenGLExtension_ATI_pn_triangles()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ATI_pn_trianglesPrivate))
+{
+}
+
+bool QOpenGLExtension_ATI_pn_triangles::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ATI_pn_triangles);
+
+ d->PNTrianglesfATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glPNTrianglesfATI"));
+ d->PNTrianglesiATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glPNTrianglesiATI"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ATI_separate_stencil::QOpenGLExtension_ATI_separate_stencil()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ATI_separate_stencilPrivate))
+{
+}
+
+bool QOpenGLExtension_ATI_separate_stencil::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ATI_separate_stencil);
+
+ d->StencilFuncSeparateATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLuint )>(context->getProcAddress("glStencilFuncSeparateATI"));
+ d->StencilOpSeparateATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLenum )>(context->getProcAddress("glStencilOpSeparateATI"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ATI_vertex_array_object::QOpenGLExtension_ATI_vertex_array_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ATI_vertex_array_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_ATI_vertex_array_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+
+ d->GetVariantArrayObjectivATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetVariantArrayObjectivATI"));
+ d->GetVariantArrayObjectfvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetVariantArrayObjectfvATI"));
+ d->VariantArrayObjectATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , GLuint , GLuint )>(context->getProcAddress("glVariantArrayObjectATI"));
+ d->GetArrayObjectivATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetArrayObjectivATI"));
+ d->GetArrayObjectfvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetArrayObjectfvATI"));
+ d->ArrayObjectATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLsizei , GLuint , GLuint )>(context->getProcAddress("glArrayObjectATI"));
+ d->FreeObjectBufferATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glFreeObjectBufferATI"));
+ d->GetObjectBufferivATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetObjectBufferivATI"));
+ d->GetObjectBufferfvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetObjectBufferfvATI"));
+ d->UpdateObjectBufferATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLsizei , const GLvoid *, GLenum )>(context->getProcAddress("glUpdateObjectBufferATI"));
+ d->IsObjectBufferATI = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsObjectBufferATI"));
+ d->NewObjectBufferATI = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLsizei , const GLvoid *, GLenum )>(context->getProcAddress("glNewObjectBufferATI"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ATI_vertex_attrib_array_object::QOpenGLExtension_ATI_vertex_attrib_array_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ATI_vertex_attrib_array_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_ATI_vertex_attrib_array_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ATI_vertex_attrib_array_object);
+
+ d->GetVertexAttribArrayObjectivATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetVertexAttribArrayObjectivATI"));
+ d->GetVertexAttribArrayObjectfvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetVertexAttribArrayObjectfvATI"));
+ d->VertexAttribArrayObjectATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLboolean , GLsizei , GLuint , GLuint )>(context->getProcAddress("glVertexAttribArrayObjectATI"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_ATI_vertex_streams::QOpenGLExtension_ATI_vertex_streams()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ATI_vertex_streamsPrivate))
+{
+}
+
+bool QOpenGLExtension_ATI_vertex_streams::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+
+ d->VertexBlendEnvfATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glVertexBlendEnvfATI"));
+ d->VertexBlendEnviATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glVertexBlendEnviATI"));
+ d->ClientActiveVertexStreamATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glClientActiveVertexStreamATI"));
+ d->NormalStream3dvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glNormalStream3dvATI"));
+ d->NormalStream3dATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glNormalStream3dATI"));
+ d->NormalStream3fvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glNormalStream3fvATI"));
+ d->NormalStream3fATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glNormalStream3fATI"));
+ d->NormalStream3ivATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glNormalStream3ivATI"));
+ d->NormalStream3iATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint )>(context->getProcAddress("glNormalStream3iATI"));
+ d->NormalStream3svATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glNormalStream3svATI"));
+ d->NormalStream3sATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort , GLshort , GLshort )>(context->getProcAddress("glNormalStream3sATI"));
+ d->NormalStream3bvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLbyte *)>(context->getProcAddress("glNormalStream3bvATI"));
+ d->NormalStream3bATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLbyte , GLbyte , GLbyte )>(context->getProcAddress("glNormalStream3bATI"));
+ d->VertexStream4dvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glVertexStream4dvATI"));
+ d->VertexStream4dATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexStream4dATI"));
+ d->VertexStream4fvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glVertexStream4fvATI"));
+ d->VertexStream4fATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glVertexStream4fATI"));
+ d->VertexStream4ivATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glVertexStream4ivATI"));
+ d->VertexStream4iATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint )>(context->getProcAddress("glVertexStream4iATI"));
+ d->VertexStream4svATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glVertexStream4svATI"));
+ d->VertexStream4sATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort , GLshort , GLshort , GLshort )>(context->getProcAddress("glVertexStream4sATI"));
+ d->VertexStream3dvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glVertexStream3dvATI"));
+ d->VertexStream3dATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexStream3dATI"));
+ d->VertexStream3fvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glVertexStream3fvATI"));
+ d->VertexStream3fATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glVertexStream3fATI"));
+ d->VertexStream3ivATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glVertexStream3ivATI"));
+ d->VertexStream3iATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint )>(context->getProcAddress("glVertexStream3iATI"));
+ d->VertexStream3svATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glVertexStream3svATI"));
+ d->VertexStream3sATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort , GLshort , GLshort )>(context->getProcAddress("glVertexStream3sATI"));
+ d->VertexStream2dvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glVertexStream2dvATI"));
+ d->VertexStream2dATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble )>(context->getProcAddress("glVertexStream2dATI"));
+ d->VertexStream2fvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glVertexStream2fvATI"));
+ d->VertexStream2fATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat )>(context->getProcAddress("glVertexStream2fATI"));
+ d->VertexStream2ivATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glVertexStream2ivATI"));
+ d->VertexStream2iATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint )>(context->getProcAddress("glVertexStream2iATI"));
+ d->VertexStream2svATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glVertexStream2svATI"));
+ d->VertexStream2sATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort , GLshort )>(context->getProcAddress("glVertexStream2sATI"));
+ d->VertexStream1dvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glVertexStream1dvATI"));
+ d->VertexStream1dATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble )>(context->getProcAddress("glVertexStream1dATI"));
+ d->VertexStream1fvATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glVertexStream1fvATI"));
+ d->VertexStream1fATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glVertexStream1fATI"));
+ d->VertexStream1ivATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glVertexStream1ivATI"));
+ d->VertexStream1iATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glVertexStream1iATI"));
+ d->VertexStream1svATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLshort *)>(context->getProcAddress("glVertexStream1svATI"));
+ d->VertexStream1sATI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLshort )>(context->getProcAddress("glVertexStream1sATI"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_bindable_uniform::QOpenGLExtension_EXT_bindable_uniform()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_bindable_uniformPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_bindable_uniform::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_bindable_uniform);
+
+ d->GetUniformOffsetEXT = reinterpret_cast<GLintptr (QOPENGLF_APIENTRYP)(GLuint , GLint )>(context->getProcAddress("glGetUniformOffsetEXT"));
+ d->GetUniformBufferSizeEXT = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , GLint )>(context->getProcAddress("glGetUniformBufferSizeEXT"));
+ d->UniformBufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint )>(context->getProcAddress("glUniformBufferEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_blend_color::QOpenGLExtension_EXT_blend_color()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_blend_colorPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_blend_color::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_blend_color);
+
+ d->BlendColorEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glBlendColorEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_blend_equation_separate::QOpenGLExtension_EXT_blend_equation_separate()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_blend_equation_separatePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_blend_equation_separate::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_blend_equation_separate);
+
+ d->BlendEquationSeparateEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glBlendEquationSeparateEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_blend_func_separate::QOpenGLExtension_EXT_blend_func_separate()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_blend_func_separatePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_blend_func_separate::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_blend_func_separate);
+
+ d->BlendFuncSeparateEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLenum )>(context->getProcAddress("glBlendFuncSeparateEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_blend_minmax::QOpenGLExtension_EXT_blend_minmax()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_blend_minmaxPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_blend_minmax::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_blend_minmax);
+
+ d->BlendEquationEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glBlendEquationEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_color_subtable::QOpenGLExtension_EXT_color_subtable()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_color_subtablePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_color_subtable::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_color_subtable);
+
+ d->CopyColorSubTableEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLint , GLint , GLsizei )>(context->getProcAddress("glCopyColorSubTableEXT"));
+ d->ColorSubTableEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glColorSubTableEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_compiled_vertex_array::QOpenGLExtension_EXT_compiled_vertex_array()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_compiled_vertex_arrayPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_compiled_vertex_array::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_compiled_vertex_array);
+
+ d->UnlockArraysEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glUnlockArraysEXT"));
+ d->LockArraysEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei )>(context->getProcAddress("glLockArraysEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_convolution::QOpenGLExtension_EXT_convolution()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_convolutionPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_convolution::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_convolution);
+
+ d->SeparableFilter2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *, const GLvoid *)>(context->getProcAddress("glSeparableFilter2DEXT"));
+ d->GetSeparableFilterEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLvoid *, GLvoid *, GLvoid *)>(context->getProcAddress("glGetSeparableFilterEXT"));
+ d->GetConvolutionParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetConvolutionParameterivEXT"));
+ d->GetConvolutionParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetConvolutionParameterfvEXT"));
+ d->GetConvolutionFilterEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetConvolutionFilterEXT"));
+ d->CopyConvolutionFilter2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glCopyConvolutionFilter2DEXT"));
+ d->CopyConvolutionFilter1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLsizei )>(context->getProcAddress("glCopyConvolutionFilter1DEXT"));
+ d->ConvolutionParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glConvolutionParameterivEXT"));
+ d->ConvolutionParameteriEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glConvolutionParameteriEXT"));
+ d->ConvolutionParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glConvolutionParameterfvEXT"));
+ d->ConvolutionParameterfEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(context->getProcAddress("glConvolutionParameterfEXT"));
+ d->ConvolutionFilter2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glConvolutionFilter2DEXT"));
+ d->ConvolutionFilter1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glConvolutionFilter1DEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_coordinate_frame::QOpenGLExtension_EXT_coordinate_frame()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_coordinate_framePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_coordinate_frame::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+
+ d->BinormalPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glBinormalPointerEXT"));
+ d->TangentPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glTangentPointerEXT"));
+ d->Binormal3svEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glBinormal3svEXT"));
+ d->Binormal3sEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(context->getProcAddress("glBinormal3sEXT"));
+ d->Binormal3ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glBinormal3ivEXT"));
+ d->Binormal3iEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glBinormal3iEXT"));
+ d->Binormal3fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glBinormal3fvEXT"));
+ d->Binormal3fEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glBinormal3fEXT"));
+ d->Binormal3dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glBinormal3dvEXT"));
+ d->Binormal3dEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glBinormal3dEXT"));
+ d->Binormal3bvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLbyte *)>(context->getProcAddress("glBinormal3bvEXT"));
+ d->Binormal3bEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbyte , GLbyte , GLbyte )>(context->getProcAddress("glBinormal3bEXT"));
+ d->Tangent3svEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glTangent3svEXT"));
+ d->Tangent3sEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(context->getProcAddress("glTangent3sEXT"));
+ d->Tangent3ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glTangent3ivEXT"));
+ d->Tangent3iEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glTangent3iEXT"));
+ d->Tangent3fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glTangent3fvEXT"));
+ d->Tangent3fEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glTangent3fEXT"));
+ d->Tangent3dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glTangent3dvEXT"));
+ d->Tangent3dEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glTangent3dEXT"));
+ d->Tangent3bvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLbyte *)>(context->getProcAddress("glTangent3bvEXT"));
+ d->Tangent3bEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbyte , GLbyte , GLbyte )>(context->getProcAddress("glTangent3bEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_copy_texture::QOpenGLExtension_EXT_copy_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_copy_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_copy_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_copy_texture);
+
+ d->CopyTexSubImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glCopyTexSubImage3DEXT"));
+ d->CopyTexSubImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glCopyTexSubImage2DEXT"));
+ d->CopyTexSubImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLsizei )>(context->getProcAddress("glCopyTexSubImage1DEXT"));
+ d->CopyTexImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLint , GLint , GLsizei , GLsizei , GLint )>(context->getProcAddress("glCopyTexImage2DEXT"));
+ d->CopyTexImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLint , GLint , GLsizei , GLint )>(context->getProcAddress("glCopyTexImage1DEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_cull_vertex::QOpenGLExtension_EXT_cull_vertex()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_cull_vertexPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_cull_vertex::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_cull_vertex);
+
+ d->CullParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat *)>(context->getProcAddress("glCullParameterfvEXT"));
+ d->CullParameterdvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble *)>(context->getProcAddress("glCullParameterdvEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_depth_bounds_test::QOpenGLExtension_EXT_depth_bounds_test()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_depth_bounds_testPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_depth_bounds_test::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_depth_bounds_test);
+
+ d->DepthBoundsEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLclampd , GLclampd )>(context->getProcAddress("glDepthBoundsEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_direct_state_access::QOpenGLExtension_EXT_direct_state_access()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_direct_state_accessPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_direct_state_access::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+
+ d->ProgramUniformMatrix4x3dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix4x3dvEXT"));
+ d->ProgramUniformMatrix4x2dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix4x2dvEXT"));
+ d->ProgramUniformMatrix3x4dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix3x4dvEXT"));
+ d->ProgramUniformMatrix3x2dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix3x2dvEXT"));
+ d->ProgramUniformMatrix2x4dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix2x4dvEXT"));
+ d->ProgramUniformMatrix2x3dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix2x3dvEXT"));
+ d->ProgramUniformMatrix4dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix4dvEXT"));
+ d->ProgramUniformMatrix3dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix3dvEXT"));
+ d->ProgramUniformMatrix2dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLdouble *)>(context->getProcAddress("glProgramUniformMatrix2dvEXT"));
+ d->ProgramUniform4dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramUniform4dvEXT"));
+ d->ProgramUniform3dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramUniform3dvEXT"));
+ d->ProgramUniform2dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramUniform2dvEXT"));
+ d->ProgramUniform1dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramUniform1dvEXT"));
+ d->ProgramUniform4dEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glProgramUniform4dEXT"));
+ d->ProgramUniform3dEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glProgramUniform3dEXT"));
+ d->ProgramUniform2dEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble , GLdouble )>(context->getProcAddress("glProgramUniform2dEXT"));
+ d->ProgramUniform1dEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLdouble )>(context->getProcAddress("glProgramUniform1dEXT"));
+ d->MultiTexRenderbufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glMultiTexRenderbufferEXT"));
+ d->TextureRenderbufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint )>(context->getProcAddress("glTextureRenderbufferEXT"));
+ d->NamedFramebufferTextureFaceEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLint , GLenum )>(context->getProcAddress("glNamedFramebufferTextureFaceEXT"));
+ d->NamedFramebufferTextureLayerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLint , GLint )>(context->getProcAddress("glNamedFramebufferTextureLayerEXT"));
+ d->NamedFramebufferTextureEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLint )>(context->getProcAddress("glNamedFramebufferTextureEXT"));
+ d->NamedRenderbufferStorageMultisampleCoverageEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glNamedRenderbufferStorageMultisampleCoverageEXT"));
+ d->NamedRenderbufferStorageMultisampleEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glNamedRenderbufferStorageMultisampleEXT"));
+ d->GetFramebufferParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetFramebufferParameterivEXT"));
+ d->FramebufferReadBufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glFramebufferReadBufferEXT"));
+ d->FramebufferDrawBuffersEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLenum *)>(context->getProcAddress("glFramebufferDrawBuffersEXT"));
+ d->FramebufferDrawBufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glFramebufferDrawBufferEXT"));
+ d->GenerateMultiTexMipmapEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glGenerateMultiTexMipmapEXT"));
+ d->GenerateTextureMipmapEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glGenerateTextureMipmapEXT"));
+ d->GetNamedFramebufferAttachmentParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetNamedFramebufferAttachmentParameterivEXT"));
+ d->NamedFramebufferRenderbufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLuint )>(context->getProcAddress("glNamedFramebufferRenderbufferEXT"));
+ d->NamedFramebufferTexture3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLuint , GLint , GLint )>(context->getProcAddress("glNamedFramebufferTexture3DEXT"));
+ d->NamedFramebufferTexture2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLuint , GLint )>(context->getProcAddress("glNamedFramebufferTexture2DEXT"));
+ d->NamedFramebufferTexture1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLuint , GLint )>(context->getProcAddress("glNamedFramebufferTexture1DEXT"));
+ d->CheckNamedFramebufferStatusEXT = reinterpret_cast<GLenum (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glCheckNamedFramebufferStatusEXT"));
+ d->GetNamedRenderbufferParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetNamedRenderbufferParameterivEXT"));
+ d->NamedRenderbufferStorageEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glNamedRenderbufferStorageEXT"));
+ d->MultiTexBufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint )>(context->getProcAddress("glMultiTexBufferEXT"));
+ d->TextureBufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLuint )>(context->getProcAddress("glTextureBufferEXT"));
+ d->GetNamedBufferSubDataEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLintptr , GLsizeiptr , GLvoid *)>(context->getProcAddress("glGetNamedBufferSubDataEXT"));
+ d->GetNamedBufferPointervEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLvoid* *)>(context->getProcAddress("glGetNamedBufferPointervEXT"));
+ d->GetNamedBufferParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetNamedBufferParameterivEXT"));
+ d->NamedCopyBufferSubDataEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLintptr , GLintptr , GLsizeiptr )>(context->getProcAddress("glNamedCopyBufferSubDataEXT"));
+ d->FlushMappedNamedBufferRangeEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLintptr , GLsizeiptr )>(context->getProcAddress("glFlushMappedNamedBufferRangeEXT"));
+ d->MapNamedBufferRangeEXT = reinterpret_cast<GLvoid* (QOPENGLF_APIENTRYP)(GLuint , GLintptr , GLsizeiptr , GLbitfield )>(context->getProcAddress("glMapNamedBufferRangeEXT"));
+ d->UnmapNamedBufferEXT = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glUnmapNamedBufferEXT"));
+ d->MapNamedBufferEXT = reinterpret_cast<GLvoid* (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glMapNamedBufferEXT"));
+ d->NamedBufferSubDataEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLintptr , GLsizeiptr , const GLvoid *)>(context->getProcAddress("glNamedBufferSubDataEXT"));
+ d->NamedBufferDataEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizeiptr , const GLvoid *, GLenum )>(context->getProcAddress("glNamedBufferDataEXT"));
+ d->ProgramUniform4uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramUniform4uivEXT"));
+ d->ProgramUniform3uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramUniform3uivEXT"));
+ d->ProgramUniform2uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramUniform2uivEXT"));
+ d->ProgramUniform1uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramUniform1uivEXT"));
+ d->ProgramUniform4uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glProgramUniform4uiEXT"));
+ d->ProgramUniform3uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint , GLuint , GLuint )>(context->getProcAddress("glProgramUniform3uiEXT"));
+ d->ProgramUniform2uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint , GLuint )>(context->getProcAddress("glProgramUniform2uiEXT"));
+ d->ProgramUniform1uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint )>(context->getProcAddress("glProgramUniform1uiEXT"));
+ d->ProgramUniformMatrix4x3fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix4x3fvEXT"));
+ d->ProgramUniformMatrix3x4fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix3x4fvEXT"));
+ d->ProgramUniformMatrix4x2fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix4x2fvEXT"));
+ d->ProgramUniformMatrix2x4fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix2x4fvEXT"));
+ d->ProgramUniformMatrix3x2fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix3x2fvEXT"));
+ d->ProgramUniformMatrix2x3fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix2x3fvEXT"));
+ d->ProgramUniformMatrix4fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix4fvEXT"));
+ d->ProgramUniformMatrix3fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix3fvEXT"));
+ d->ProgramUniformMatrix2fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , GLboolean , const GLfloat *)>(context->getProcAddress("glProgramUniformMatrix2fvEXT"));
+ d->ProgramUniform4ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint *)>(context->getProcAddress("glProgramUniform4ivEXT"));
+ d->ProgramUniform3ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint *)>(context->getProcAddress("glProgramUniform3ivEXT"));
+ d->ProgramUniform2ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint *)>(context->getProcAddress("glProgramUniform2ivEXT"));
+ d->ProgramUniform1ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint *)>(context->getProcAddress("glProgramUniform1ivEXT"));
+ d->ProgramUniform4fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramUniform4fvEXT"));
+ d->ProgramUniform3fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramUniform3fvEXT"));
+ d->ProgramUniform2fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramUniform2fvEXT"));
+ d->ProgramUniform1fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramUniform1fvEXT"));
+ d->ProgramUniform4iEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glProgramUniform4iEXT"));
+ d->ProgramUniform3iEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glProgramUniform3iEXT"));
+ d->ProgramUniform2iEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint )>(context->getProcAddress("glProgramUniform2iEXT"));
+ d->ProgramUniform1iEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint )>(context->getProcAddress("glProgramUniform1iEXT"));
+ d->ProgramUniform4fEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glProgramUniform4fEXT"));
+ d->ProgramUniform3fEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glProgramUniform3fEXT"));
+ d->ProgramUniform2fEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat , GLfloat )>(context->getProcAddress("glProgramUniform2fEXT"));
+ d->ProgramUniform1fEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLfloat )>(context->getProcAddress("glProgramUniform1fEXT"));
+ d->GetMultiTexParameterIuivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint *)>(context->getProcAddress("glGetMultiTexParameterIuivEXT"));
+ d->GetMultiTexParameterIivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetMultiTexParameterIivEXT"));
+ d->MultiTexParameterIuivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , const GLuint *)>(context->getProcAddress("glMultiTexParameterIuivEXT"));
+ d->MultiTexParameterIivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , const GLint *)>(context->getProcAddress("glMultiTexParameterIivEXT"));
+ d->GetTextureParameterIuivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLuint *)>(context->getProcAddress("glGetTextureParameterIuivEXT"));
+ d->GetTextureParameterIivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetTextureParameterIivEXT"));
+ d->TextureParameterIuivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , const GLuint *)>(context->getProcAddress("glTextureParameterIuivEXT"));
+ d->TextureParameterIivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , const GLint *)>(context->getProcAddress("glTextureParameterIivEXT"));
+ d->GetNamedProgramLocalParameterIuivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLuint *)>(context->getProcAddress("glGetNamedProgramLocalParameterIuivEXT"));
+ d->GetNamedProgramLocalParameterIivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLint *)>(context->getProcAddress("glGetNamedProgramLocalParameterIivEXT"));
+ d->NamedProgramLocalParametersI4uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLsizei , const GLuint *)>(context->getProcAddress("glNamedProgramLocalParametersI4uivEXT"));
+ d->NamedProgramLocalParameterI4uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , const GLuint *)>(context->getProcAddress("glNamedProgramLocalParameterI4uivEXT"));
+ d->NamedProgramLocalParameterI4uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glNamedProgramLocalParameterI4uiEXT"));
+ d->NamedProgramLocalParametersI4ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLsizei , const GLint *)>(context->getProcAddress("glNamedProgramLocalParametersI4ivEXT"));
+ d->NamedProgramLocalParameterI4ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , const GLint *)>(context->getProcAddress("glNamedProgramLocalParameterI4ivEXT"));
+ d->NamedProgramLocalParameterI4iEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glNamedProgramLocalParameterI4iEXT"));
+ d->NamedProgramLocalParameters4fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLsizei , const GLfloat *)>(context->getProcAddress("glNamedProgramLocalParameters4fvEXT"));
+ d->GetNamedProgramStringEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetNamedProgramStringEXT"));
+ d->GetNamedProgramivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetNamedProgramivEXT"));
+ d->GetNamedProgramLocalParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLfloat *)>(context->getProcAddress("glGetNamedProgramLocalParameterfvEXT"));
+ d->GetNamedProgramLocalParameterdvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLdouble *)>(context->getProcAddress("glGetNamedProgramLocalParameterdvEXT"));
+ d->NamedProgramLocalParameter4fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , const GLfloat *)>(context->getProcAddress("glNamedProgramLocalParameter4fvEXT"));
+ d->NamedProgramLocalParameter4fEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glNamedProgramLocalParameter4fEXT"));
+ d->NamedProgramLocalParameter4dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , const GLdouble *)>(context->getProcAddress("glNamedProgramLocalParameter4dvEXT"));
+ d->NamedProgramLocalParameter4dEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glNamedProgramLocalParameter4dEXT"));
+ d->NamedProgramStringEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glNamedProgramStringEXT"));
+ d->GetCompressedMultiTexImageEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLvoid *)>(context->getProcAddress("glGetCompressedMultiTexImageEXT"));
+ d->CompressedMultiTexSubImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLsizei , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedMultiTexSubImage1DEXT"));
+ d->CompressedMultiTexSubImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLint , GLsizei , GLsizei , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedMultiTexSubImage2DEXT"));
+ d->CompressedMultiTexSubImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedMultiTexSubImage3DEXT"));
+ d->CompressedMultiTexImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLenum , GLsizei , GLint , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedMultiTexImage1DEXT"));
+ d->CompressedMultiTexImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLenum , GLsizei , GLsizei , GLint , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedMultiTexImage2DEXT"));
+ d->CompressedMultiTexImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLenum , GLsizei , GLsizei , GLsizei , GLint , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedMultiTexImage3DEXT"));
+ d->GetCompressedTextureImageEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLvoid *)>(context->getProcAddress("glGetCompressedTextureImageEXT"));
+ d->CompressedTextureSubImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLint , GLsizei , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTextureSubImage1DEXT"));
+ d->CompressedTextureSubImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLint , GLint , GLsizei , GLsizei , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTextureSubImage2DEXT"));
+ d->CompressedTextureSubImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTextureSubImage3DEXT"));
+ d->CompressedTextureImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLenum , GLsizei , GLint , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTextureImage1DEXT"));
+ d->CompressedTextureImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLenum , GLsizei , GLsizei , GLint , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTextureImage2DEXT"));
+ d->CompressedTextureImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLenum , GLsizei , GLsizei , GLsizei , GLint , GLsizei , const GLvoid *)>(context->getProcAddress("glCompressedTextureImage3DEXT"));
+ d->GetPointerIndexedvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLvoid* *)>(context->getProcAddress("glGetPointerIndexedvEXT"));
+ d->GetDoubleIndexedvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLdouble *)>(context->getProcAddress("glGetDoubleIndexedvEXT"));
+ d->GetFloatIndexedvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLfloat *)>(context->getProcAddress("glGetFloatIndexedvEXT"));
+ d->GetMultiTexGenivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetMultiTexGenivEXT"));
+ d->GetMultiTexGenfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetMultiTexGenfvEXT"));
+ d->GetMultiTexGendvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLdouble *)>(context->getProcAddress("glGetMultiTexGendvEXT"));
+ d->GetMultiTexEnvivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetMultiTexEnvivEXT"));
+ d->GetMultiTexEnvfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetMultiTexEnvfvEXT"));
+ d->MultiTexGenivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , const GLint *)>(context->getProcAddress("glMultiTexGenivEXT"));
+ d->MultiTexGeniEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLint )>(context->getProcAddress("glMultiTexGeniEXT"));
+ d->MultiTexGenfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glMultiTexGenfvEXT"));
+ d->MultiTexGenfEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLfloat )>(context->getProcAddress("glMultiTexGenfEXT"));
+ d->MultiTexGendvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , const GLdouble *)>(context->getProcAddress("glMultiTexGendvEXT"));
+ d->MultiTexGendEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLdouble )>(context->getProcAddress("glMultiTexGendEXT"));
+ d->MultiTexEnvivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , const GLint *)>(context->getProcAddress("glMultiTexEnvivEXT"));
+ d->MultiTexEnviEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLint )>(context->getProcAddress("glMultiTexEnviEXT"));
+ d->MultiTexEnvfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glMultiTexEnvfvEXT"));
+ d->MultiTexEnvfEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLfloat )>(context->getProcAddress("glMultiTexEnvfEXT"));
+ d->MultiTexCoordPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glMultiTexCoordPointerEXT"));
+ d->DisableClientStateIndexedEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glDisableClientStateIndexedEXT"));
+ d->EnableClientStateIndexedEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glEnableClientStateIndexedEXT"));
+ d->BindMultiTextureEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glBindMultiTextureEXT"));
+ d->CopyMultiTexSubImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLint , GLint , GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glCopyMultiTexSubImage3DEXT"));
+ d->MultiTexSubImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glMultiTexSubImage3DEXT"));
+ d->MultiTexImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLenum , GLsizei , GLsizei , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glMultiTexImage3DEXT"));
+ d->GetMultiTexLevelParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLenum , GLint *)>(context->getProcAddress("glGetMultiTexLevelParameterivEXT"));
+ d->GetMultiTexLevelParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLenum , GLfloat *)>(context->getProcAddress("glGetMultiTexLevelParameterfvEXT"));
+ d->GetMultiTexParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetMultiTexParameterivEXT"));
+ d->GetMultiTexParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetMultiTexParameterfvEXT"));
+ d->GetMultiTexImageEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetMultiTexImageEXT"));
+ d->CopyMultiTexSubImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLint , GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glCopyMultiTexSubImage2DEXT"));
+ d->CopyMultiTexSubImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLint , GLint , GLsizei )>(context->getProcAddress("glCopyMultiTexSubImage1DEXT"));
+ d->CopyMultiTexImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLenum , GLint , GLint , GLsizei , GLsizei , GLint )>(context->getProcAddress("glCopyMultiTexImage2DEXT"));
+ d->CopyMultiTexImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLenum , GLint , GLint , GLsizei , GLint )>(context->getProcAddress("glCopyMultiTexImage1DEXT"));
+ d->MultiTexSubImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLint , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glMultiTexSubImage2DEXT"));
+ d->MultiTexSubImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glMultiTexSubImage1DEXT"));
+ d->MultiTexImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLenum , GLsizei , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glMultiTexImage2DEXT"));
+ d->MultiTexImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLenum , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glMultiTexImage1DEXT"));
+ d->MultiTexParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , const GLint *)>(context->getProcAddress("glMultiTexParameterivEXT"));
+ d->MultiTexParameteriEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLint )>(context->getProcAddress("glMultiTexParameteriEXT"));
+ d->MultiTexParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glMultiTexParameterfvEXT"));
+ d->MultiTexParameterfEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLfloat )>(context->getProcAddress("glMultiTexParameterfEXT"));
+ d->CopyTextureSubImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLint , GLint , GLint , GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glCopyTextureSubImage3DEXT"));
+ d->TextureSubImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTextureSubImage3DEXT"));
+ d->TextureImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLenum , GLsizei , GLsizei , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTextureImage3DEXT"));
+ d->GetTextureLevelParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLenum , GLint *)>(context->getProcAddress("glGetTextureLevelParameterivEXT"));
+ d->GetTextureLevelParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLenum , GLfloat *)>(context->getProcAddress("glGetTextureLevelParameterfvEXT"));
+ d->GetTextureParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetTextureParameterivEXT"));
+ d->GetTextureParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetTextureParameterfvEXT"));
+ d->GetTextureImageEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetTextureImageEXT"));
+ d->CopyTextureSubImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLint , GLint , GLint , GLint , GLsizei , GLsizei )>(context->getProcAddress("glCopyTextureSubImage2DEXT"));
+ d->CopyTextureSubImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLint , GLint , GLint , GLsizei )>(context->getProcAddress("glCopyTextureSubImage1DEXT"));
+ d->CopyTextureImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLenum , GLint , GLint , GLsizei , GLsizei , GLint )>(context->getProcAddress("glCopyTextureImage2DEXT"));
+ d->CopyTextureImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLenum , GLint , GLint , GLsizei , GLint )>(context->getProcAddress("glCopyTextureImage1DEXT"));
+ d->TextureSubImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLint , GLint , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTextureSubImage2DEXT"));
+ d->TextureSubImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLint , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTextureSubImage1DEXT"));
+ d->TextureImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLenum , GLsizei , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTextureImage2DEXT"));
+ d->TextureImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLenum , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTextureImage1DEXT"));
+ d->TextureParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , const GLint *)>(context->getProcAddress("glTextureParameterivEXT"));
+ d->TextureParameteriEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLint )>(context->getProcAddress("glTextureParameteriEXT"));
+ d->TextureParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glTextureParameterfvEXT"));
+ d->TextureParameterfEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLfloat )>(context->getProcAddress("glTextureParameterfEXT"));
+ d->MatrixMultTransposedEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glMatrixMultTransposedEXT"));
+ d->MatrixMultTransposefEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glMatrixMultTransposefEXT"));
+ d->MatrixLoadTransposedEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glMatrixLoadTransposedEXT"));
+ d->MatrixLoadTransposefEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glMatrixLoadTransposefEXT"));
+ d->MatrixPushEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glMatrixPushEXT"));
+ d->MatrixPopEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glMatrixPopEXT"));
+ d->MatrixOrthoEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glMatrixOrthoEXT"));
+ d->MatrixFrustumEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glMatrixFrustumEXT"));
+ d->MatrixTranslatedEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glMatrixTranslatedEXT"));
+ d->MatrixTranslatefEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glMatrixTranslatefEXT"));
+ d->MatrixScaledEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glMatrixScaledEXT"));
+ d->MatrixScalefEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glMatrixScalefEXT"));
+ d->MatrixRotatedEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glMatrixRotatedEXT"));
+ d->MatrixRotatefEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glMatrixRotatefEXT"));
+ d->MatrixLoadIdentityEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glMatrixLoadIdentityEXT"));
+ d->MatrixMultdEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glMatrixMultdEXT"));
+ d->MatrixMultfEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glMatrixMultfEXT"));
+ d->MatrixLoaddEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLdouble *)>(context->getProcAddress("glMatrixLoaddEXT"));
+ d->MatrixLoadfEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glMatrixLoadfEXT"));
+ d->PushClientAttribDefaultEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(context->getProcAddress("glPushClientAttribDefaultEXT"));
+ d->ClientAttribDefaultEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(context->getProcAddress("glClientAttribDefaultEXT"));
+ d->TextureStorage3DMultisampleEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , GLenum , GLsizei , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTextureStorage3DMultisampleEXT"));
+ d->TextureStorage2DMultisampleEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , GLenum , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTextureStorage2DMultisampleEXT"));
+ d->TextureBufferRangeEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLuint , GLintptr , GLsizeiptr )>(context->getProcAddress("glTextureBufferRangeEXT"));
+ d->GetNamedFramebufferParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetNamedFramebufferParameterivEXT"));
+ d->NamedFramebufferParameteriEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint )>(context->getProcAddress("glNamedFramebufferParameteriEXT"));
+ d->VertexArrayVertexBindingDivisorEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glVertexArrayVertexBindingDivisorEXT"));
+ d->VertexArrayVertexAttribBindingEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glVertexArrayVertexAttribBindingEXT"));
+ d->VertexArrayVertexAttribLFormatEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLint , GLenum , GLuint )>(context->getProcAddress("glVertexArrayVertexAttribLFormatEXT"));
+ d->VertexArrayVertexAttribIFormatEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLint , GLenum , GLuint )>(context->getProcAddress("glVertexArrayVertexAttribIFormatEXT"));
+ d->VertexArrayVertexAttribFormatEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLint , GLenum , GLboolean , GLuint )>(context->getProcAddress("glVertexArrayVertexAttribFormatEXT"));
+ d->VertexArrayBindVertexBufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint , GLintptr , GLsizei )>(context->getProcAddress("glVertexArrayBindVertexBufferEXT"));
+ d->ClearNamedBufferSubDataEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizeiptr , GLsizeiptr , GLenum , GLenum , const void *)>(context->getProcAddress("glClearNamedBufferSubDataEXT"));
+ d->ClearNamedBufferDataEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLenum , GLenum , const void *)>(context->getProcAddress("glClearNamedBufferDataEXT"));
+ d->TextureStorage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , GLenum , GLsizei , GLsizei , GLsizei )>(context->getProcAddress("glTextureStorage3DEXT"));
+ d->TextureStorage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glTextureStorage2DEXT"));
+ d->TextureStorage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , GLenum , GLsizei )>(context->getProcAddress("glTextureStorage1DEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_draw_buffers2::QOpenGLExtension_EXT_draw_buffers2()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_draw_buffers2Private))
+{
+}
+
+bool QOpenGLExtension_EXT_draw_buffers2::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_draw_buffers2);
+
+ d->IsEnabledIndexedEXT = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glIsEnabledIndexedEXT"));
+ d->DisableIndexedEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glDisableIndexedEXT"));
+ d->EnableIndexedEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glEnableIndexedEXT"));
+ d->GetIntegerIndexedvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLint *)>(context->getProcAddress("glGetIntegerIndexedvEXT"));
+ d->GetBooleanIndexedvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLboolean *)>(context->getProcAddress("glGetBooleanIndexedvEXT"));
+ d->ColorMaskIndexedEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLboolean , GLboolean , GLboolean , GLboolean )>(context->getProcAddress("glColorMaskIndexedEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_draw_instanced::QOpenGLExtension_EXT_draw_instanced()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_draw_instancedPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_draw_instanced::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_draw_instanced);
+
+ d->DrawElementsInstancedEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const GLvoid *, GLsizei )>(context->getProcAddress("glDrawElementsInstancedEXT"));
+ d->DrawArraysInstancedEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLsizei , GLsizei )>(context->getProcAddress("glDrawArraysInstancedEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_draw_range_elements::QOpenGLExtension_EXT_draw_range_elements()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_draw_range_elementsPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_draw_range_elements::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_draw_range_elements);
+
+ d->DrawRangeElementsEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLsizei , GLenum , const GLvoid *)>(context->getProcAddress("glDrawRangeElementsEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_fog_coord::QOpenGLExtension_EXT_fog_coord()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_fog_coordPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_fog_coord::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_fog_coord);
+
+ d->FogCoordPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glFogCoordPointerEXT"));
+ d->FogCoorddvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glFogCoorddvEXT"));
+ d->FogCoorddEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble )>(context->getProcAddress("glFogCoorddEXT"));
+ d->FogCoordfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glFogCoordfvEXT"));
+ d->FogCoordfEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glFogCoordfEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_framebuffer_blit::QOpenGLExtension_EXT_framebuffer_blit()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_framebuffer_blitPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_framebuffer_blit::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_framebuffer_blit);
+
+ d->BlitFramebufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint , GLint , GLint , GLint , GLint , GLbitfield , GLenum )>(context->getProcAddress("glBlitFramebufferEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_framebuffer_multisample::QOpenGLExtension_EXT_framebuffer_multisample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_framebuffer_multisamplePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_framebuffer_multisample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_framebuffer_multisample);
+
+ d->RenderbufferStorageMultisampleEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glRenderbufferStorageMultisampleEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_framebuffer_object::QOpenGLExtension_EXT_framebuffer_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_framebuffer_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_framebuffer_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+
+ d->GenerateMipmapEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glGenerateMipmapEXT"));
+ d->GetFramebufferAttachmentParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetFramebufferAttachmentParameterivEXT"));
+ d->FramebufferRenderbufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint )>(context->getProcAddress("glFramebufferRenderbufferEXT"));
+ d->FramebufferTexture3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint , GLint , GLint )>(context->getProcAddress("glFramebufferTexture3DEXT"));
+ d->FramebufferTexture2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint , GLint )>(context->getProcAddress("glFramebufferTexture2DEXT"));
+ d->FramebufferTexture1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint , GLint )>(context->getProcAddress("glFramebufferTexture1DEXT"));
+ d->CheckFramebufferStatusEXT = reinterpret_cast<GLenum (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glCheckFramebufferStatusEXT"));
+ d->GenFramebuffersEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenFramebuffersEXT"));
+ d->DeleteFramebuffersEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteFramebuffersEXT"));
+ d->BindFramebufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindFramebufferEXT"));
+ d->IsFramebufferEXT = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsFramebufferEXT"));
+ d->GetRenderbufferParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetRenderbufferParameterivEXT"));
+ d->RenderbufferStorageEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glRenderbufferStorageEXT"));
+ d->GenRenderbuffersEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenRenderbuffersEXT"));
+ d->DeleteRenderbuffersEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteRenderbuffersEXT"));
+ d->BindRenderbufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindRenderbufferEXT"));
+ d->IsRenderbufferEXT = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsRenderbufferEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_geometry_shader4::QOpenGLExtension_EXT_geometry_shader4()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_geometry_shader4Private))
+{
+}
+
+bool QOpenGLExtension_EXT_geometry_shader4::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_geometry_shader4);
+
+ d->ProgramParameteriEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint )>(context->getProcAddress("glProgramParameteriEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_gpu_program_parameters::QOpenGLExtension_EXT_gpu_program_parameters()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_gpu_program_parametersPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_gpu_program_parameters::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_gpu_program_parameters);
+
+ d->ProgramLocalParameters4fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramLocalParameters4fvEXT"));
+ d->ProgramEnvParameters4fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramEnvParameters4fvEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_gpu_shader4::QOpenGLExtension_EXT_gpu_shader4()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_gpu_shader4Private))
+{
+}
+
+bool QOpenGLExtension_EXT_gpu_shader4::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_gpu_shader4);
+
+ d->Uniform4uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint *)>(context->getProcAddress("glUniform4uivEXT"));
+ d->Uniform3uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint *)>(context->getProcAddress("glUniform3uivEXT"));
+ d->Uniform2uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint *)>(context->getProcAddress("glUniform2uivEXT"));
+ d->Uniform1uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint *)>(context->getProcAddress("glUniform1uivEXT"));
+ d->Uniform4uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glUniform4uiEXT"));
+ d->Uniform3uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint , GLuint , GLuint )>(context->getProcAddress("glUniform3uiEXT"));
+ d->Uniform2uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint , GLuint )>(context->getProcAddress("glUniform2uiEXT"));
+ d->Uniform1uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint )>(context->getProcAddress("glUniform1uiEXT"));
+ d->GetFragDataLocationEXT = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , const GLchar *)>(context->getProcAddress("glGetFragDataLocationEXT"));
+ d->BindFragDataLocationEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , const GLchar *)>(context->getProcAddress("glBindFragDataLocationEXT"));
+ d->GetUniformuivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint *)>(context->getProcAddress("glGetUniformuivEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_histogram::QOpenGLExtension_EXT_histogram()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_histogramPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_histogram::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_histogram);
+
+ d->ResetMinmaxEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glResetMinmaxEXT"));
+ d->ResetHistogramEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glResetHistogramEXT"));
+ d->MinmaxEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLboolean )>(context->getProcAddress("glMinmaxEXT"));
+ d->HistogramEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , GLboolean )>(context->getProcAddress("glHistogramEXT"));
+ d->GetMinmaxParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetMinmaxParameterivEXT"));
+ d->GetMinmaxParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetMinmaxParameterfvEXT"));
+ d->GetMinmaxEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLboolean , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetMinmaxEXT"));
+ d->GetHistogramParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetHistogramParameterivEXT"));
+ d->GetHistogramParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetHistogramParameterfvEXT"));
+ d->GetHistogramEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLboolean , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetHistogramEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_index_func::QOpenGLExtension_EXT_index_func()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_index_funcPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_index_func::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_index_func);
+
+ d->IndexFuncEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLclampf )>(context->getProcAddress("glIndexFuncEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_index_material::QOpenGLExtension_EXT_index_material()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_index_materialPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_index_material::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_index_material);
+
+ d->IndexMaterialEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glIndexMaterialEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_light_texture::QOpenGLExtension_EXT_light_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_light_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_light_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_light_texture);
+
+ d->TextureMaterialEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glTextureMaterialEXT"));
+ d->TextureLightEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glTextureLightEXT"));
+ d->ApplyTextureEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glApplyTextureEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_multi_draw_arrays::QOpenGLExtension_EXT_multi_draw_arrays()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_multi_draw_arraysPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_multi_draw_arrays::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_multi_draw_arrays);
+
+ d->MultiDrawElementsEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLsizei *, GLenum , const GLvoid* *, GLsizei )>(context->getProcAddress("glMultiDrawElementsEXT"));
+ d->MultiDrawArraysEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *, const GLsizei *, GLsizei )>(context->getProcAddress("glMultiDrawArraysEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_multisample::QOpenGLExtension_EXT_multisample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_multisamplePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_multisample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_multisample);
+
+ d->SamplePatternEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glSamplePatternEXT"));
+ d->SampleMaskEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLclampf , GLboolean )>(context->getProcAddress("glSampleMaskEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_paletted_texture::QOpenGLExtension_EXT_paletted_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_paletted_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_paletted_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_paletted_texture);
+
+ d->GetColorTableParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetColorTableParameterfvEXT"));
+ d->GetColorTableParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetColorTableParameterivEXT"));
+ d->GetColorTableEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetColorTableEXT"));
+ d->ColorTableEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glColorTableEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_pixel_transform::QOpenGLExtension_EXT_pixel_transform()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_pixel_transformPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_pixel_transform::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_pixel_transform);
+
+ d->GetPixelTransformParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetPixelTransformParameterfvEXT"));
+ d->GetPixelTransformParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetPixelTransformParameterivEXT"));
+ d->PixelTransformParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glPixelTransformParameterfvEXT"));
+ d->PixelTransformParameterivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glPixelTransformParameterivEXT"));
+ d->PixelTransformParameterfEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(context->getProcAddress("glPixelTransformParameterfEXT"));
+ d->PixelTransformParameteriEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glPixelTransformParameteriEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_point_parameters::QOpenGLExtension_EXT_point_parameters()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_point_parametersPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_point_parameters::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_point_parameters);
+
+ d->PointParameterfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glPointParameterfvEXT"));
+ d->PointParameterfEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glPointParameterfEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_polygon_offset::QOpenGLExtension_EXT_polygon_offset()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_polygon_offsetPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_polygon_offset::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_polygon_offset);
+
+ d->PolygonOffsetEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glPolygonOffsetEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_provoking_vertex::QOpenGLExtension_EXT_provoking_vertex()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_provoking_vertexPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_provoking_vertex::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_provoking_vertex);
+
+ d->ProvokingVertexEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glProvokingVertexEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_secondary_color::QOpenGLExtension_EXT_secondary_color()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_secondary_colorPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_secondary_color::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+
+ d->SecondaryColorPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glSecondaryColorPointerEXT"));
+ d->SecondaryColor3usvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLushort *)>(context->getProcAddress("glSecondaryColor3usvEXT"));
+ d->SecondaryColor3usEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLushort , GLushort , GLushort )>(context->getProcAddress("glSecondaryColor3usEXT"));
+ d->SecondaryColor3uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *)>(context->getProcAddress("glSecondaryColor3uivEXT"));
+ d->SecondaryColor3uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glSecondaryColor3uiEXT"));
+ d->SecondaryColor3ubvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *)>(context->getProcAddress("glSecondaryColor3ubvEXT"));
+ d->SecondaryColor3ubEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte , GLubyte , GLubyte )>(context->getProcAddress("glSecondaryColor3ubEXT"));
+ d->SecondaryColor3svEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glSecondaryColor3svEXT"));
+ d->SecondaryColor3sEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(context->getProcAddress("glSecondaryColor3sEXT"));
+ d->SecondaryColor3ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glSecondaryColor3ivEXT"));
+ d->SecondaryColor3iEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glSecondaryColor3iEXT"));
+ d->SecondaryColor3fvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glSecondaryColor3fvEXT"));
+ d->SecondaryColor3fEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glSecondaryColor3fEXT"));
+ d->SecondaryColor3dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glSecondaryColor3dvEXT"));
+ d->SecondaryColor3dEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glSecondaryColor3dEXT"));
+ d->SecondaryColor3bvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLbyte *)>(context->getProcAddress("glSecondaryColor3bvEXT"));
+ d->SecondaryColor3bEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbyte , GLbyte , GLbyte )>(context->getProcAddress("glSecondaryColor3bEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_separate_shader_objects::QOpenGLExtension_EXT_separate_shader_objects()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_separate_shader_objectsPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_separate_shader_objects::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+
+ d->CreateShaderProgramEXT = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLenum , const GLchar *)>(context->getProcAddress("glCreateShaderProgramEXT"));
+ d->ActiveProgramEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glActiveProgramEXT"));
+ d->UseShaderProgramEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glUseShaderProgramEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_shader_image_load_store::QOpenGLExtension_EXT_shader_image_load_store()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_shader_image_load_storePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_shader_image_load_store::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_shader_image_load_store);
+
+ d->MemoryBarrierEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(context->getProcAddress("glMemoryBarrierEXT"));
+ d->BindImageTextureEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLint , GLboolean , GLint , GLenum , GLint )>(context->getProcAddress("glBindImageTextureEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_stencil_clear_tag::QOpenGLExtension_EXT_stencil_clear_tag()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_stencil_clear_tagPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_stencil_clear_tag::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_stencil_clear_tag);
+
+ d->StencilClearTagEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint )>(context->getProcAddress("glStencilClearTagEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_stencil_two_side::QOpenGLExtension_EXT_stencil_two_side()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_stencil_two_sidePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_stencil_two_side::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_stencil_two_side);
+
+ d->ActiveStencilFaceEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glActiveStencilFaceEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_subtexture::QOpenGLExtension_EXT_subtexture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_subtexturePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_subtexture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_subtexture);
+
+ d->TexSubImage2DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTexSubImage2DEXT"));
+ d->TexSubImage1DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTexSubImage1DEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_texture3D::QOpenGLExtension_EXT_texture3D()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_texture3DPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_texture3D::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_texture3D);
+
+ d->TexSubImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTexSubImage3DEXT"));
+ d->TexImage3DEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLsizei , GLsizei , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTexImage3DEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_texture_buffer_object::QOpenGLExtension_EXT_texture_buffer_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_texture_buffer_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_texture_buffer_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_texture_buffer_object);
+
+ d->TexBufferEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint )>(context->getProcAddress("glTexBufferEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_texture_integer::QOpenGLExtension_EXT_texture_integer()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_texture_integerPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_texture_integer::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_texture_integer);
+
+ d->ClearColorIuiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glClearColorIuiEXT"));
+ d->ClearColorIiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(context->getProcAddress("glClearColorIiEXT"));
+ d->GetTexParameterIuivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint *)>(context->getProcAddress("glGetTexParameterIuivEXT"));
+ d->GetTexParameterIivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetTexParameterIivEXT"));
+ d->TexParameterIuivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLuint *)>(context->getProcAddress("glTexParameterIuivEXT"));
+ d->TexParameterIivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glTexParameterIivEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_texture_object::QOpenGLExtension_EXT_texture_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_texture_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_texture_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_texture_object);
+
+ d->PrioritizeTexturesEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *, const GLclampf *)>(context->getProcAddress("glPrioritizeTexturesEXT"));
+ d->IsTextureEXT = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsTextureEXT"));
+ d->GenTexturesEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenTexturesEXT"));
+ d->DeleteTexturesEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteTexturesEXT"));
+ d->BindTextureEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindTextureEXT"));
+ d->AreTexturesResidentEXT = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *, GLboolean *)>(context->getProcAddress("glAreTexturesResidentEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_texture_perturb_normal::QOpenGLExtension_EXT_texture_perturb_normal()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_texture_perturb_normalPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_texture_perturb_normal::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_texture_perturb_normal);
+
+ d->TextureNormalEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glTextureNormalEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_timer_query::QOpenGLExtension_EXT_timer_query()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_timer_queryPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_timer_query::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_timer_query);
+
+ d->GetQueryObjectui64vEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint64EXT *)>(context->getProcAddress("glGetQueryObjectui64vEXT"));
+ d->GetQueryObjecti64vEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint64EXT *)>(context->getProcAddress("glGetQueryObjecti64vEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_transform_feedback::QOpenGLExtension_EXT_transform_feedback()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_transform_feedbackPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_transform_feedback::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_transform_feedback);
+
+ d->GetTransformFeedbackVaryingEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLsizei , GLsizei *, GLsizei *, GLenum *, GLchar *)>(context->getProcAddress("glGetTransformFeedbackVaryingEXT"));
+ d->TransformFeedbackVaryingsEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLchar* *, GLenum )>(context->getProcAddress("glTransformFeedbackVaryingsEXT"));
+ d->BindBufferBaseEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint )>(context->getProcAddress("glBindBufferBaseEXT"));
+ d->BindBufferOffsetEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLintptr )>(context->getProcAddress("glBindBufferOffsetEXT"));
+ d->BindBufferRangeEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLintptr , GLsizeiptr )>(context->getProcAddress("glBindBufferRangeEXT"));
+ d->EndTransformFeedbackEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glEndTransformFeedbackEXT"));
+ d->BeginTransformFeedbackEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glBeginTransformFeedbackEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_vertex_array::QOpenGLExtension_EXT_vertex_array()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_vertex_arrayPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_vertex_array::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_vertex_array);
+
+ d->VertexPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , GLsizei , const GLvoid *)>(context->getProcAddress("glVertexPointerEXT"));
+ d->TexCoordPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , GLsizei , const GLvoid *)>(context->getProcAddress("glTexCoordPointerEXT"));
+ d->NormalPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLsizei , const GLvoid *)>(context->getProcAddress("glNormalPointerEXT"));
+ d->IndexPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLsizei , const GLvoid *)>(context->getProcAddress("glIndexPointerEXT"));
+ d->GetPointervEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLvoid* *)>(context->getProcAddress("glGetPointervEXT"));
+ d->EdgeFlagPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLsizei , const GLboolean *)>(context->getProcAddress("glEdgeFlagPointerEXT"));
+ d->DrawArraysEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLsizei )>(context->getProcAddress("glDrawArraysEXT"));
+ d->ColorPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , GLsizei , const GLvoid *)>(context->getProcAddress("glColorPointerEXT"));
+ d->ArrayElementEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(context->getProcAddress("glArrayElementEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_vertex_attrib_64bit::QOpenGLExtension_EXT_vertex_attrib_64bit()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_vertex_attrib_64bitPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_vertex_attrib_64bit::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_vertex_attrib_64bit);
+
+ d->VertexArrayVertexAttribLOffsetEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint , GLint , GLenum , GLsizei , GLintptr )>(context->getProcAddress("glVertexArrayVertexAttribLOffsetEXT"));
+ d->GetVertexAttribLdvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLdouble *)>(context->getProcAddress("glGetVertexAttribLdvEXT"));
+ d->VertexAttribLPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glVertexAttribLPointerEXT"));
+ d->VertexAttribL4dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttribL4dvEXT"));
+ d->VertexAttribL3dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttribL3dvEXT"));
+ d->VertexAttribL2dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttribL2dvEXT"));
+ d->VertexAttribL1dvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttribL1dvEXT"));
+ d->VertexAttribL4dEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttribL4dEXT"));
+ d->VertexAttribL3dEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttribL3dEXT"));
+ d->VertexAttribL2dEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttribL2dEXT"));
+ d->VertexAttribL1dEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble )>(context->getProcAddress("glVertexAttribL1dEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_vertex_shader::QOpenGLExtension_EXT_vertex_shader()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_vertex_shaderPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_vertex_shader::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+
+ d->GetLocalConstantFloatvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetLocalConstantFloatvEXT"));
+ d->GetLocalConstantIntegervEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetLocalConstantIntegervEXT"));
+ d->GetLocalConstantBooleanvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean *)>(context->getProcAddress("glGetLocalConstantBooleanvEXT"));
+ d->GetInvariantFloatvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetInvariantFloatvEXT"));
+ d->GetInvariantIntegervEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetInvariantIntegervEXT"));
+ d->GetInvariantBooleanvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean *)>(context->getProcAddress("glGetInvariantBooleanvEXT"));
+ d->GetVariantPointervEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLvoid* *)>(context->getProcAddress("glGetVariantPointervEXT"));
+ d->GetVariantFloatvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetVariantFloatvEXT"));
+ d->GetVariantIntegervEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetVariantIntegervEXT"));
+ d->GetVariantBooleanvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLboolean *)>(context->getProcAddress("glGetVariantBooleanvEXT"));
+ d->IsVariantEnabledEXT = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glIsVariantEnabledEXT"));
+ d->BindParameterEXT = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glBindParameterEXT"));
+ d->BindTextureUnitParameterEXT = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glBindTextureUnitParameterEXT"));
+ d->BindTexGenParameterEXT = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum )>(context->getProcAddress("glBindTexGenParameterEXT"));
+ d->BindMaterialParameterEXT = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glBindMaterialParameterEXT"));
+ d->BindLightParameterEXT = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glBindLightParameterEXT"));
+ d->DisableVariantClientStateEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glDisableVariantClientStateEXT"));
+ d->EnableVariantClientStateEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glEnableVariantClientStateEXT"));
+ d->VariantPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint , const GLvoid *)>(context->getProcAddress("glVariantPointerEXT"));
+ d->VariantuivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVariantuivEXT"));
+ d->VariantusvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLushort *)>(context->getProcAddress("glVariantusvEXT"));
+ d->VariantubvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLubyte *)>(context->getProcAddress("glVariantubvEXT"));
+ d->VariantdvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVariantdvEXT"));
+ d->VariantfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVariantfvEXT"));
+ d->VariantivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVariantivEXT"));
+ d->VariantsvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVariantsvEXT"));
+ d->VariantbvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLbyte *)>(context->getProcAddress("glVariantbvEXT"));
+ d->SetLocalConstantEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLvoid *)>(context->getProcAddress("glSetLocalConstantEXT"));
+ d->SetInvariantEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLvoid *)>(context->getProcAddress("glSetInvariantEXT"));
+ d->GenSymbolsEXT = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLuint )>(context->getProcAddress("glGenSymbolsEXT"));
+ d->ExtractComponentEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glExtractComponentEXT"));
+ d->InsertComponentEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glInsertComponentEXT"));
+ d->WriteMaskEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , GLenum , GLenum , GLenum )>(context->getProcAddress("glWriteMaskEXT"));
+ d->SwizzleEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , GLenum , GLenum , GLenum )>(context->getProcAddress("glSwizzleEXT"));
+ d->ShaderOp3EXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glShaderOp3EXT"));
+ d->ShaderOp2EXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLuint )>(context->getProcAddress("glShaderOp2EXT"));
+ d->ShaderOp1EXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint )>(context->getProcAddress("glShaderOp1EXT"));
+ d->DeleteVertexShaderEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glDeleteVertexShaderEXT"));
+ d->GenVertexShadersEXT = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glGenVertexShadersEXT"));
+ d->BindVertexShaderEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glBindVertexShaderEXT"));
+ d->EndVertexShaderEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glEndVertexShaderEXT"));
+ d->BeginVertexShaderEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glBeginVertexShaderEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_vertex_weighting::QOpenGLExtension_EXT_vertex_weighting()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_vertex_weightingPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_vertex_weighting::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_vertex_weighting);
+
+ d->VertexWeightPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glVertexWeightPointerEXT"));
+ d->VertexWeightfvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glVertexWeightfvEXT"));
+ d->VertexWeightfEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glVertexWeightfEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_EXT_x11_sync_object::QOpenGLExtension_EXT_x11_sync_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_x11_sync_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_x11_sync_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_x11_sync_object);
+
+ d->ImportSyncEXT = reinterpret_cast<GLsync (QOPENGLF_APIENTRYP)(GLenum , GLintptr , GLbitfield )>(context->getProcAddress("glImportSyncEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_GREMEDY_frame_terminator::QOpenGLExtension_GREMEDY_frame_terminator()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_GREMEDY_frame_terminatorPrivate))
+{
+}
+
+bool QOpenGLExtension_GREMEDY_frame_terminator::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_GREMEDY_frame_terminator);
+
+ d->FrameTerminatorGREMEDY = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glFrameTerminatorGREMEDY"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_GREMEDY_string_marker::QOpenGLExtension_GREMEDY_string_marker()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_GREMEDY_string_markerPrivate))
+{
+}
+
+bool QOpenGLExtension_GREMEDY_string_marker::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_GREMEDY_string_marker);
+
+ d->StringMarkerGREMEDY = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLvoid *)>(context->getProcAddress("glStringMarkerGREMEDY"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_HP_image_transform::QOpenGLExtension_HP_image_transform()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_HP_image_transformPrivate))
+{
+}
+
+bool QOpenGLExtension_HP_image_transform::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_HP_image_transform);
+
+ d->GetImageTransformParameterfvHP = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetImageTransformParameterfvHP"));
+ d->GetImageTransformParameterivHP = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetImageTransformParameterivHP"));
+ d->ImageTransformParameterfvHP = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glImageTransformParameterfvHP"));
+ d->ImageTransformParameterivHP = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glImageTransformParameterivHP"));
+ d->ImageTransformParameterfHP = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(context->getProcAddress("glImageTransformParameterfHP"));
+ d->ImageTransformParameteriHP = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glImageTransformParameteriHP"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_IBM_multimode_draw_arrays::QOpenGLExtension_IBM_multimode_draw_arrays()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_IBM_multimode_draw_arraysPrivate))
+{
+}
+
+bool QOpenGLExtension_IBM_multimode_draw_arrays::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_IBM_multimode_draw_arrays);
+
+ d->MultiModeDrawElementsIBM = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLenum *, const GLsizei *, GLenum , const GLvoid* const *, GLsizei , GLint )>(context->getProcAddress("glMultiModeDrawElementsIBM"));
+ d->MultiModeDrawArraysIBM = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLenum *, const GLint *, const GLsizei *, GLsizei , GLint )>(context->getProcAddress("glMultiModeDrawArraysIBM"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_IBM_vertex_array_lists::QOpenGLExtension_IBM_vertex_array_lists()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_IBM_vertex_array_listsPrivate))
+{
+}
+
+bool QOpenGLExtension_IBM_vertex_array_lists::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_IBM_vertex_array_lists);
+
+ d->VertexPointerListIBM = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLint , const GLvoid* *, GLint )>(context->getProcAddress("glVertexPointerListIBM"));
+ d->TexCoordPointerListIBM = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLint , const GLvoid* *, GLint )>(context->getProcAddress("glTexCoordPointerListIBM"));
+ d->NormalPointerListIBM = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLvoid* *, GLint )>(context->getProcAddress("glNormalPointerListIBM"));
+ d->IndexPointerListIBM = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLvoid* *, GLint )>(context->getProcAddress("glIndexPointerListIBM"));
+ d->FogCoordPointerListIBM = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , const GLvoid* *, GLint )>(context->getProcAddress("glFogCoordPointerListIBM"));
+ d->EdgeFlagPointerListIBM = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , const GLboolean* *, GLint )>(context->getProcAddress("glEdgeFlagPointerListIBM"));
+ d->SecondaryColorPointerListIBM = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLint , const GLvoid* *, GLint )>(context->getProcAddress("glSecondaryColorPointerListIBM"));
+ d->ColorPointerListIBM = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLint , const GLvoid* *, GLint )>(context->getProcAddress("glColorPointerListIBM"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_INGR_blend_func_separate::QOpenGLExtension_INGR_blend_func_separate()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_INGR_blend_func_separatePrivate))
+{
+}
+
+bool QOpenGLExtension_INGR_blend_func_separate::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_INGR_blend_func_separate);
+
+ d->BlendFuncSeparateINGR = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLenum )>(context->getProcAddress("glBlendFuncSeparateINGR"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_INTEL_parallel_arrays::QOpenGLExtension_INTEL_parallel_arrays()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_INTEL_parallel_arraysPrivate))
+{
+}
+
+bool QOpenGLExtension_INTEL_parallel_arrays::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_INTEL_parallel_arrays);
+
+ d->TexCoordPointervINTEL = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , const GLvoid* *)>(context->getProcAddress("glTexCoordPointervINTEL"));
+ d->ColorPointervINTEL = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , const GLvoid* *)>(context->getProcAddress("glColorPointervINTEL"));
+ d->NormalPointervINTEL = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLvoid* *)>(context->getProcAddress("glNormalPointervINTEL"));
+ d->VertexPointervINTEL = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , const GLvoid* *)>(context->getProcAddress("glVertexPointervINTEL"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_KHR_debug::QOpenGLExtension_KHR_debug()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_KHR_debugPrivate))
+{
+}
+
+bool QOpenGLExtension_KHR_debug::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_KHR_debug);
+
+ d->GetObjectPtrLabel = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const void *, GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetObjectPtrLabel"));
+ d->ObjectPtrLabel = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const void *, GLsizei , const GLchar *)>(context->getProcAddress("glObjectPtrLabel"));
+ d->GetObjectLabel = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei , GLsizei *, GLchar *)>(context->getProcAddress("glGetObjectLabel"));
+ d->ObjectLabel = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei , const GLchar *)>(context->getProcAddress("glObjectLabel"));
+ d->PopDebugGroup = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glPopDebugGroup"));
+ d->PushDebugGroup = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei , const GLchar *)>(context->getProcAddress("glPushDebugGroup"));
+ d->GetDebugMessageLog = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLenum *, GLenum *, GLuint *, GLenum *, GLsizei *, GLchar *)>(context->getProcAddress("glGetDebugMessageLog"));
+ d->DebugMessageCallback = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLDEBUGPROC , const void *)>(context->getProcAddress("glDebugMessageCallback"));
+ d->DebugMessageInsert = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLenum , GLsizei , const GLchar *)>(context->getProcAddress("glDebugMessageInsert"));
+ d->DebugMessageControl = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLsizei , const GLuint *, GLboolean )>(context->getProcAddress("glDebugMessageControl"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_MESA_resize_buffers::QOpenGLExtension_MESA_resize_buffers()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_MESA_resize_buffersPrivate))
+{
+}
+
+bool QOpenGLExtension_MESA_resize_buffers::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_MESA_resize_buffers);
+
+ d->ResizeBuffersMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glResizeBuffersMESA"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_MESA_window_pos::QOpenGLExtension_MESA_window_pos()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_MESA_window_posPrivate))
+{
+}
+
+bool QOpenGLExtension_MESA_window_pos::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_MESA_window_pos);
+
+ d->WindowPos4svMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glWindowPos4svMESA"));
+ d->WindowPos4sMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort , GLshort )>(context->getProcAddress("glWindowPos4sMESA"));
+ d->WindowPos4ivMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glWindowPos4ivMESA"));
+ d->WindowPos4iMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint , GLint )>(context->getProcAddress("glWindowPos4iMESA"));
+ d->WindowPos4fvMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glWindowPos4fvMESA"));
+ d->WindowPos4fMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glWindowPos4fMESA"));
+ d->WindowPos4dvMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glWindowPos4dvMESA"));
+ d->WindowPos4dMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glWindowPos4dMESA"));
+ d->WindowPos3svMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glWindowPos3svMESA"));
+ d->WindowPos3sMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort , GLshort )>(context->getProcAddress("glWindowPos3sMESA"));
+ d->WindowPos3ivMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glWindowPos3ivMESA"));
+ d->WindowPos3iMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint , GLint )>(context->getProcAddress("glWindowPos3iMESA"));
+ d->WindowPos3fvMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glWindowPos3fvMESA"));
+ d->WindowPos3fMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glWindowPos3fMESA"));
+ d->WindowPos3dvMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glWindowPos3dvMESA"));
+ d->WindowPos3dMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glWindowPos3dMESA"));
+ d->WindowPos2svMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLshort *)>(context->getProcAddress("glWindowPos2svMESA"));
+ d->WindowPos2sMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort , GLshort )>(context->getProcAddress("glWindowPos2sMESA"));
+ d->WindowPos2ivMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLint *)>(context->getProcAddress("glWindowPos2ivMESA"));
+ d->WindowPos2iMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint )>(context->getProcAddress("glWindowPos2iMESA"));
+ d->WindowPos2fvMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *)>(context->getProcAddress("glWindowPos2fvMESA"));
+ d->WindowPos2fMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glWindowPos2fMESA"));
+ d->WindowPos2dvMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glWindowPos2dvMESA"));
+ d->WindowPos2dMESA = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(context->getProcAddress("glWindowPos2dMESA"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_bindless_texture::QOpenGLExtension_NV_bindless_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_bindless_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_bindless_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+
+ d->IsImageHandleResidentNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint64 )>(context->getProcAddress("glIsImageHandleResidentNV"));
+ d->IsTextureHandleResidentNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint64 )>(context->getProcAddress("glIsTextureHandleResidentNV"));
+ d->ProgramUniformHandleui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint64 *)>(context->getProcAddress("glProgramUniformHandleui64vNV"));
+ d->ProgramUniformHandleui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint64 )>(context->getProcAddress("glProgramUniformHandleui64NV"));
+ d->UniformHandleui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint64 *)>(context->getProcAddress("glUniformHandleui64vNV"));
+ d->UniformHandleui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint64 )>(context->getProcAddress("glUniformHandleui64NV"));
+ d->MakeImageHandleNonResidentNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint64 )>(context->getProcAddress("glMakeImageHandleNonResidentNV"));
+ d->MakeImageHandleResidentNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint64 , GLenum )>(context->getProcAddress("glMakeImageHandleResidentNV"));
+ d->GetImageHandleNV = reinterpret_cast<GLuint64 (QOPENGLF_APIENTRYP)(GLuint , GLint , GLboolean , GLint , GLenum )>(context->getProcAddress("glGetImageHandleNV"));
+ d->MakeTextureHandleNonResidentNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint64 )>(context->getProcAddress("glMakeTextureHandleNonResidentNV"));
+ d->MakeTextureHandleResidentNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint64 )>(context->getProcAddress("glMakeTextureHandleResidentNV"));
+ d->GetTextureSamplerHandleNV = reinterpret_cast<GLuint64 (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glGetTextureSamplerHandleNV"));
+ d->GetTextureHandleNV = reinterpret_cast<GLuint64 (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glGetTextureHandleNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_conditional_render::QOpenGLExtension_NV_conditional_render()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_conditional_renderPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_conditional_render::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_conditional_render);
+
+ d->EndConditionalRenderNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glEndConditionalRenderNV"));
+ d->BeginConditionalRenderNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glBeginConditionalRenderNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_copy_image::QOpenGLExtension_NV_copy_image()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_copy_imagePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_copy_image::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_copy_image);
+
+ d->CopyImageSubDataNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint , GLint , GLint , GLint , GLuint , GLenum , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei )>(context->getProcAddress("glCopyImageSubDataNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_depth_buffer_float::QOpenGLExtension_NV_depth_buffer_float()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_depth_buffer_floatPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_depth_buffer_float::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_depth_buffer_float);
+
+ d->DepthBoundsdNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(context->getProcAddress("glDepthBoundsdNV"));
+ d->ClearDepthdNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble )>(context->getProcAddress("glClearDepthdNV"));
+ d->DepthRangedNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble , GLdouble )>(context->getProcAddress("glDepthRangedNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_evaluators::QOpenGLExtension_NV_evaluators()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_evaluatorsPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_evaluators::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_evaluators);
+
+ d->EvalMapsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glEvalMapsNV"));
+ d->GetMapAttribParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetMapAttribParameterfvNV"));
+ d->GetMapAttribParameterivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum , GLint *)>(context->getProcAddress("glGetMapAttribParameterivNV"));
+ d->GetMapParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetMapParameterfvNV"));
+ d->GetMapParameterivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetMapParameterivNV"));
+ d->GetMapControlPointsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum , GLsizei , GLsizei , GLboolean , GLvoid *)>(context->getProcAddress("glGetMapControlPointsNV"));
+ d->MapParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glMapParameterfvNV"));
+ d->MapParameterivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glMapParameterivNV"));
+ d->MapControlPointsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum , GLsizei , GLsizei , GLint , GLint , GLboolean , const GLvoid *)>(context->getProcAddress("glMapControlPointsNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_explicit_multisample::QOpenGLExtension_NV_explicit_multisample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_explicit_multisamplePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_explicit_multisample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_explicit_multisample);
+
+ d->TexRenderbufferNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glTexRenderbufferNV"));
+ d->SampleMaskIndexedNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLbitfield )>(context->getProcAddress("glSampleMaskIndexedNV"));
+ d->GetMultisamplefvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLfloat *)>(context->getProcAddress("glGetMultisamplefvNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_fence::QOpenGLExtension_NV_fence()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_fencePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_fence::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_fence);
+
+ d->SetFenceNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glSetFenceNV"));
+ d->FinishFenceNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glFinishFenceNV"));
+ d->GetFenceivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetFenceivNV"));
+ d->TestFenceNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glTestFenceNV"));
+ d->IsFenceNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsFenceNV"));
+ d->GenFencesNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenFencesNV"));
+ d->DeleteFencesNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteFencesNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_fragment_program::QOpenGLExtension_NV_fragment_program()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_fragment_programPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_fragment_program::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_fragment_program);
+
+ d->GetProgramNamedParameterdvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLubyte *, GLdouble *)>(context->getProcAddress("glGetProgramNamedParameterdvNV"));
+ d->GetProgramNamedParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLubyte *, GLfloat *)>(context->getProcAddress("glGetProgramNamedParameterfvNV"));
+ d->ProgramNamedParameter4dvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLubyte *, const GLdouble *)>(context->getProcAddress("glProgramNamedParameter4dvNV"));
+ d->ProgramNamedParameter4fvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLubyte *, const GLfloat *)>(context->getProcAddress("glProgramNamedParameter4fvNV"));
+ d->ProgramNamedParameter4dNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLubyte *, GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glProgramNamedParameter4dNV"));
+ d->ProgramNamedParameter4fNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLubyte *, GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glProgramNamedParameter4fNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_framebuffer_multisample_coverage::QOpenGLExtension_NV_framebuffer_multisample_coverage()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_framebuffer_multisample_coveragePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_framebuffer_multisample_coverage::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_framebuffer_multisample_coverage);
+
+ d->RenderbufferStorageMultisampleCoverageNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLsizei , GLenum , GLsizei , GLsizei )>(context->getProcAddress("glRenderbufferStorageMultisampleCoverageNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_geometry_program4::QOpenGLExtension_NV_geometry_program4()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_geometry_program4Private))
+{
+}
+
+bool QOpenGLExtension_NV_geometry_program4::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_geometry_program4);
+
+ d->FramebufferTextureFaceEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLint , GLenum )>(context->getProcAddress("glFramebufferTextureFaceEXT"));
+ d->FramebufferTextureLayerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLint , GLint )>(context->getProcAddress("glFramebufferTextureLayerEXT"));
+ d->FramebufferTextureEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint , GLint )>(context->getProcAddress("glFramebufferTextureEXT"));
+ d->ProgramVertexLimitNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glProgramVertexLimitNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_gpu_program4::QOpenGLExtension_NV_gpu_program4()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_gpu_program4Private))
+{
+}
+
+bool QOpenGLExtension_NV_gpu_program4::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+
+ d->GetProgramEnvParameterIuivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint *)>(context->getProcAddress("glGetProgramEnvParameterIuivNV"));
+ d->GetProgramEnvParameterIivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLint *)>(context->getProcAddress("glGetProgramEnvParameterIivNV"));
+ d->GetProgramLocalParameterIuivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint *)>(context->getProcAddress("glGetProgramLocalParameterIuivNV"));
+ d->GetProgramLocalParameterIivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLint *)>(context->getProcAddress("glGetProgramLocalParameterIivNV"));
+ d->ProgramEnvParametersI4uivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramEnvParametersI4uivNV"));
+ d->ProgramEnvParameterI4uivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLuint *)>(context->getProcAddress("glProgramEnvParameterI4uivNV"));
+ d->ProgramEnvParameterI4uiNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glProgramEnvParameterI4uiNV"));
+ d->ProgramEnvParametersI4ivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei , const GLint *)>(context->getProcAddress("glProgramEnvParametersI4ivNV"));
+ d->ProgramEnvParameterI4ivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLint *)>(context->getProcAddress("glProgramEnvParameterI4ivNV"));
+ d->ProgramEnvParameterI4iNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glProgramEnvParameterI4iNV"));
+ d->ProgramLocalParametersI4uivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramLocalParametersI4uivNV"));
+ d->ProgramLocalParameterI4uivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLuint *)>(context->getProcAddress("glProgramLocalParameterI4uivNV"));
+ d->ProgramLocalParameterI4uiNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glProgramLocalParameterI4uiNV"));
+ d->ProgramLocalParametersI4ivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei , const GLint *)>(context->getProcAddress("glProgramLocalParametersI4ivNV"));
+ d->ProgramLocalParameterI4ivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLint *)>(context->getProcAddress("glProgramLocalParameterI4ivNV"));
+ d->ProgramLocalParameterI4iNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glProgramLocalParameterI4iNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_gpu_program5::QOpenGLExtension_NV_gpu_program5()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_gpu_program5Private))
+{
+}
+
+bool QOpenGLExtension_NV_gpu_program5::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_gpu_program5);
+
+ d->GetProgramSubroutineParameteruivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint *)>(context->getProcAddress("glGetProgramSubroutineParameteruivNV"));
+ d->ProgramSubroutineParametersuivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLuint *)>(context->getProcAddress("glProgramSubroutineParametersuivNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_gpu_shader5::QOpenGLExtension_NV_gpu_shader5()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_gpu_shader5Private))
+{
+}
+
+bool QOpenGLExtension_NV_gpu_shader5::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+
+ d->ProgramUniform4ui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint64EXT *)>(context->getProcAddress("glProgramUniform4ui64vNV"));
+ d->ProgramUniform3ui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint64EXT *)>(context->getProcAddress("glProgramUniform3ui64vNV"));
+ d->ProgramUniform2ui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint64EXT *)>(context->getProcAddress("glProgramUniform2ui64vNV"));
+ d->ProgramUniform1ui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint64EXT *)>(context->getProcAddress("glProgramUniform1ui64vNV"));
+ d->ProgramUniform4ui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint64EXT , GLuint64EXT , GLuint64EXT , GLuint64EXT )>(context->getProcAddress("glProgramUniform4ui64NV"));
+ d->ProgramUniform3ui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint64EXT , GLuint64EXT , GLuint64EXT )>(context->getProcAddress("glProgramUniform3ui64NV"));
+ d->ProgramUniform2ui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint64EXT , GLuint64EXT )>(context->getProcAddress("glProgramUniform2ui64NV"));
+ d->ProgramUniform1ui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint64EXT )>(context->getProcAddress("glProgramUniform1ui64NV"));
+ d->ProgramUniform4i64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint64EXT *)>(context->getProcAddress("glProgramUniform4i64vNV"));
+ d->ProgramUniform3i64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint64EXT *)>(context->getProcAddress("glProgramUniform3i64vNV"));
+ d->ProgramUniform2i64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint64EXT *)>(context->getProcAddress("glProgramUniform2i64vNV"));
+ d->ProgramUniform1i64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLint64EXT *)>(context->getProcAddress("glProgramUniform1i64vNV"));
+ d->ProgramUniform4i64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint64EXT , GLint64EXT , GLint64EXT , GLint64EXT )>(context->getProcAddress("glProgramUniform4i64NV"));
+ d->ProgramUniform3i64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint64EXT , GLint64EXT , GLint64EXT )>(context->getProcAddress("glProgramUniform3i64NV"));
+ d->ProgramUniform2i64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint64EXT , GLint64EXT )>(context->getProcAddress("glProgramUniform2i64NV"));
+ d->ProgramUniform1i64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint64EXT )>(context->getProcAddress("glProgramUniform1i64NV"));
+ d->GetUniformi64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint64EXT *)>(context->getProcAddress("glGetUniformi64vNV"));
+ d->Uniform4ui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint64EXT *)>(context->getProcAddress("glUniform4ui64vNV"));
+ d->Uniform3ui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint64EXT *)>(context->getProcAddress("glUniform3ui64vNV"));
+ d->Uniform2ui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint64EXT *)>(context->getProcAddress("glUniform2ui64vNV"));
+ d->Uniform1ui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint64EXT *)>(context->getProcAddress("glUniform1ui64vNV"));
+ d->Uniform4ui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint64EXT , GLuint64EXT , GLuint64EXT , GLuint64EXT )>(context->getProcAddress("glUniform4ui64NV"));
+ d->Uniform3ui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint64EXT , GLuint64EXT , GLuint64EXT )>(context->getProcAddress("glUniform3ui64NV"));
+ d->Uniform2ui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint64EXT , GLuint64EXT )>(context->getProcAddress("glUniform2ui64NV"));
+ d->Uniform1ui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint64EXT )>(context->getProcAddress("glUniform1ui64NV"));
+ d->Uniform4i64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLint64EXT *)>(context->getProcAddress("glUniform4i64vNV"));
+ d->Uniform3i64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLint64EXT *)>(context->getProcAddress("glUniform3i64vNV"));
+ d->Uniform2i64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLint64EXT *)>(context->getProcAddress("glUniform2i64vNV"));
+ d->Uniform1i64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLint64EXT *)>(context->getProcAddress("glUniform1i64vNV"));
+ d->Uniform4i64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint64EXT , GLint64EXT , GLint64EXT , GLint64EXT )>(context->getProcAddress("glUniform4i64NV"));
+ d->Uniform3i64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint64EXT , GLint64EXT , GLint64EXT )>(context->getProcAddress("glUniform3i64NV"));
+ d->Uniform2i64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint64EXT , GLint64EXT )>(context->getProcAddress("glUniform2i64NV"));
+ d->Uniform1i64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLint64EXT )>(context->getProcAddress("glUniform1i64NV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_half_float::QOpenGLExtension_NV_half_float()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_half_floatPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_half_float::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_half_float);
+
+ d->VertexAttribs4hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLhalfNV *)>(context->getProcAddress("glVertexAttribs4hvNV"));
+ d->VertexAttribs3hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLhalfNV *)>(context->getProcAddress("glVertexAttribs3hvNV"));
+ d->VertexAttribs2hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLhalfNV *)>(context->getProcAddress("glVertexAttribs2hvNV"));
+ d->VertexAttribs1hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLhalfNV *)>(context->getProcAddress("glVertexAttribs1hvNV"));
+ d->VertexAttrib4hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLhalfNV *)>(context->getProcAddress("glVertexAttrib4hvNV"));
+ d->VertexAttrib4hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLhalfNV , GLhalfNV , GLhalfNV , GLhalfNV )>(context->getProcAddress("glVertexAttrib4hNV"));
+ d->VertexAttrib3hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLhalfNV *)>(context->getProcAddress("glVertexAttrib3hvNV"));
+ d->VertexAttrib3hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLhalfNV , GLhalfNV , GLhalfNV )>(context->getProcAddress("glVertexAttrib3hNV"));
+ d->VertexAttrib2hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLhalfNV *)>(context->getProcAddress("glVertexAttrib2hvNV"));
+ d->VertexAttrib2hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLhalfNV , GLhalfNV )>(context->getProcAddress("glVertexAttrib2hNV"));
+ d->VertexAttrib1hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLhalfNV *)>(context->getProcAddress("glVertexAttrib1hvNV"));
+ d->VertexAttrib1hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLhalfNV )>(context->getProcAddress("glVertexAttrib1hNV"));
+ d->VertexWeighthvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glVertexWeighthvNV"));
+ d->VertexWeighthNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV )>(context->getProcAddress("glVertexWeighthNV"));
+ d->SecondaryColor3hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glSecondaryColor3hvNV"));
+ d->SecondaryColor3hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV , GLhalfNV , GLhalfNV )>(context->getProcAddress("glSecondaryColor3hNV"));
+ d->FogCoordhvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glFogCoordhvNV"));
+ d->FogCoordhNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV )>(context->getProcAddress("glFogCoordhNV"));
+ d->MultiTexCoord4hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLhalfNV *)>(context->getProcAddress("glMultiTexCoord4hvNV"));
+ d->MultiTexCoord4hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLhalfNV , GLhalfNV , GLhalfNV , GLhalfNV )>(context->getProcAddress("glMultiTexCoord4hNV"));
+ d->MultiTexCoord3hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLhalfNV *)>(context->getProcAddress("glMultiTexCoord3hvNV"));
+ d->MultiTexCoord3hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLhalfNV , GLhalfNV , GLhalfNV )>(context->getProcAddress("glMultiTexCoord3hNV"));
+ d->MultiTexCoord2hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLhalfNV *)>(context->getProcAddress("glMultiTexCoord2hvNV"));
+ d->MultiTexCoord2hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLhalfNV , GLhalfNV )>(context->getProcAddress("glMultiTexCoord2hNV"));
+ d->MultiTexCoord1hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLhalfNV *)>(context->getProcAddress("glMultiTexCoord1hvNV"));
+ d->MultiTexCoord1hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLhalfNV )>(context->getProcAddress("glMultiTexCoord1hNV"));
+ d->TexCoord4hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glTexCoord4hvNV"));
+ d->TexCoord4hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV , GLhalfNV , GLhalfNV , GLhalfNV )>(context->getProcAddress("glTexCoord4hNV"));
+ d->TexCoord3hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glTexCoord3hvNV"));
+ d->TexCoord3hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV , GLhalfNV , GLhalfNV )>(context->getProcAddress("glTexCoord3hNV"));
+ d->TexCoord2hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glTexCoord2hvNV"));
+ d->TexCoord2hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV , GLhalfNV )>(context->getProcAddress("glTexCoord2hNV"));
+ d->TexCoord1hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glTexCoord1hvNV"));
+ d->TexCoord1hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV )>(context->getProcAddress("glTexCoord1hNV"));
+ d->Color4hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glColor4hvNV"));
+ d->Color4hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV , GLhalfNV , GLhalfNV , GLhalfNV )>(context->getProcAddress("glColor4hNV"));
+ d->Color3hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glColor3hvNV"));
+ d->Color3hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV , GLhalfNV , GLhalfNV )>(context->getProcAddress("glColor3hNV"));
+ d->Normal3hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glNormal3hvNV"));
+ d->Normal3hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV , GLhalfNV , GLhalfNV )>(context->getProcAddress("glNormal3hNV"));
+ d->Vertex4hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glVertex4hvNV"));
+ d->Vertex4hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV , GLhalfNV , GLhalfNV , GLhalfNV )>(context->getProcAddress("glVertex4hNV"));
+ d->Vertex3hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glVertex3hvNV"));
+ d->Vertex3hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV , GLhalfNV , GLhalfNV )>(context->getProcAddress("glVertex3hNV"));
+ d->Vertex2hvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLhalfNV *)>(context->getProcAddress("glVertex2hvNV"));
+ d->Vertex2hNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLhalfNV , GLhalfNV )>(context->getProcAddress("glVertex2hNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_occlusion_query::QOpenGLExtension_NV_occlusion_query()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_occlusion_queryPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_occlusion_query::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_occlusion_query);
+
+ d->GetOcclusionQueryuivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint *)>(context->getProcAddress("glGetOcclusionQueryuivNV"));
+ d->GetOcclusionQueryivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetOcclusionQueryivNV"));
+ d->EndOcclusionQueryNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glEndOcclusionQueryNV"));
+ d->BeginOcclusionQueryNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glBeginOcclusionQueryNV"));
+ d->IsOcclusionQueryNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsOcclusionQueryNV"));
+ d->DeleteOcclusionQueriesNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteOcclusionQueriesNV"));
+ d->GenOcclusionQueriesNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenOcclusionQueriesNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_parameter_buffer_object::QOpenGLExtension_NV_parameter_buffer_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_parameter_buffer_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_parameter_buffer_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_parameter_buffer_object);
+
+ d->ProgramBufferParametersIuivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLsizei , const GLuint *)>(context->getProcAddress("glProgramBufferParametersIuivNV"));
+ d->ProgramBufferParametersIivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLsizei , const GLint *)>(context->getProcAddress("glProgramBufferParametersIivNV"));
+ d->ProgramBufferParametersfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramBufferParametersfvNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_path_rendering::QOpenGLExtension_NV_path_rendering()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_path_renderingPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_path_rendering::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_path_rendering);
+
+ d->PointAlongPathNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei , GLfloat , GLfloat *, GLfloat *, GLfloat *, GLfloat *)>(context->getProcAddress("glPointAlongPathNV"));
+ d->GetPathLengthNV = reinterpret_cast<GLfloat (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei )>(context->getProcAddress("glGetPathLengthNV"));
+ d->IsPointInStrokePathNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat )>(context->getProcAddress("glIsPointInStrokePathNV"));
+ d->IsPointInFillPathNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLfloat , GLfloat )>(context->getProcAddress("glIsPointInFillPathNV"));
+ d->GetPathTexGenfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetPathTexGenfvNV"));
+ d->GetPathTexGenivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetPathTexGenivNV"));
+ d->GetPathColorGenfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetPathColorGenfvNV"));
+ d->GetPathColorGenivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetPathColorGenivNV"));
+ d->GetPathSpacingNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLenum , const GLvoid *, GLuint , GLfloat , GLfloat , GLenum , GLfloat *)>(context->getProcAddress("glGetPathSpacingNV"));
+ d->GetPathMetricRangeNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield , GLuint , GLsizei , GLsizei , GLfloat *)>(context->getProcAddress("glGetPathMetricRangeNV"));
+ d->GetPathMetricsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield , GLsizei , GLenum , const GLvoid *, GLuint , GLsizei , GLfloat *)>(context->getProcAddress("glGetPathMetricsNV"));
+ d->GetPathDashArrayNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat *)>(context->getProcAddress("glGetPathDashArrayNV"));
+ d->GetPathCoordsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat *)>(context->getProcAddress("glGetPathCoordsNV"));
+ d->GetPathCommandsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLubyte *)>(context->getProcAddress("glGetPathCommandsNV"));
+ d->GetPathParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetPathParameterfvNV"));
+ d->GetPathParameterivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetPathParameterivNV"));
+ d->CoverStrokePathInstancedNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLenum , const GLvoid *, GLuint , GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glCoverStrokePathInstancedNV"));
+ d->CoverFillPathInstancedNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLenum , const GLvoid *, GLuint , GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glCoverFillPathInstancedNV"));
+ d->CoverStrokePathNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glCoverStrokePathNV"));
+ d->CoverFillPathNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glCoverFillPathNV"));
+ d->PathFogGenNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glPathFogGenNV"));
+ d->PathTexGenNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , const GLfloat *)>(context->getProcAddress("glPathTexGenNV"));
+ d->PathColorGenNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glPathColorGenNV"));
+ d->PathCoverDepthFuncNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glPathCoverDepthFuncNV"));
+ d->StencilStrokePathInstancedNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLenum , const GLvoid *, GLuint , GLint , GLuint , GLenum , const GLfloat *)>(context->getProcAddress("glStencilStrokePathInstancedNV"));
+ d->StencilFillPathInstancedNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLenum , const GLvoid *, GLuint , GLenum , GLuint , GLenum , const GLfloat *)>(context->getProcAddress("glStencilFillPathInstancedNV"));
+ d->StencilStrokePathNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint )>(context->getProcAddress("glStencilStrokePathNV"));
+ d->StencilFillPathNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint )>(context->getProcAddress("glStencilFillPathNV"));
+ d->PathStencilDepthOffsetNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat )>(context->getProcAddress("glPathStencilDepthOffsetNV"));
+ d->PathStencilFuncNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLuint )>(context->getProcAddress("glPathStencilFuncNV"));
+ d->PathDashArrayNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLfloat *)>(context->getProcAddress("glPathDashArrayNV"));
+ d->PathParameterfNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat )>(context->getProcAddress("glPathParameterfNV"));
+ d->PathParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLfloat *)>(context->getProcAddress("glPathParameterfvNV"));
+ d->PathParameteriNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint )>(context->getProcAddress("glPathParameteriNV"));
+ d->PathParameterivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLint *)>(context->getProcAddress("glPathParameterivNV"));
+ d->TransformPathNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , const GLfloat *)>(context->getProcAddress("glTransformPathNV"));
+ d->InterpolatePathsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint , GLfloat )>(context->getProcAddress("glInterpolatePathsNV"));
+ d->CopyPathNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glCopyPathNV"));
+ d->WeightPathsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLuint *, const GLfloat *)>(context->getProcAddress("glWeightPathsNV"));
+ d->PathGlyphRangeNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLvoid *, GLbitfield , GLuint , GLsizei , GLenum , GLuint , GLfloat )>(context->getProcAddress("glPathGlyphRangeNV"));
+ d->PathGlyphsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLvoid *, GLbitfield , GLsizei , GLenum , const GLvoid *, GLenum , GLuint , GLfloat )>(context->getProcAddress("glPathGlyphsNV"));
+ d->PathStringNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glPathStringNV"));
+ d->PathSubCoordsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei , GLenum , const GLvoid *)>(context->getProcAddress("glPathSubCoordsNV"));
+ d->PathSubCommandsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLsizei , GLsizei , const GLubyte *, GLsizei , GLenum , const GLvoid *)>(context->getProcAddress("glPathSubCommandsNV"));
+ d->PathCoordsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , GLenum , const GLvoid *)>(context->getProcAddress("glPathCoordsNV"));
+ d->PathCommandsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLubyte *, GLsizei , GLenum , const GLvoid *)>(context->getProcAddress("glPathCommandsNV"));
+ d->IsPathNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsPathNV"));
+ d->DeletePathsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei )>(context->getProcAddress("glDeletePathsNV"));
+ d->GenPathsNV = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLsizei )>(context->getProcAddress("glGenPathsNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_pixel_data_range::QOpenGLExtension_NV_pixel_data_range()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_pixel_data_rangePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_pixel_data_range::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_pixel_data_range);
+
+ d->FlushPixelDataRangeNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glFlushPixelDataRangeNV"));
+ d->PixelDataRangeNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glPixelDataRangeNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_point_sprite::QOpenGLExtension_NV_point_sprite()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_point_spritePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_point_sprite::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_point_sprite);
+
+ d->PointParameterivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glPointParameterivNV"));
+ d->PointParameteriNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glPointParameteriNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_present_video::QOpenGLExtension_NV_present_video()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_present_videoPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_present_video::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_present_video);
+
+ d->GetVideoui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint64EXT *)>(context->getProcAddress("glGetVideoui64vNV"));
+ d->GetVideoi64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint64EXT *)>(context->getProcAddress("glGetVideoi64vNV"));
+ d->GetVideouivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint *)>(context->getProcAddress("glGetVideouivNV"));
+ d->GetVideoivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetVideoivNV"));
+ d->PresentFrameDualFillNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint64EXT , GLuint , GLuint , GLenum , GLenum , GLuint , GLenum , GLuint , GLenum , GLuint , GLenum , GLuint )>(context->getProcAddress("glPresentFrameDualFillNV"));
+ d->PresentFrameKeyedNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint64EXT , GLuint , GLuint , GLenum , GLenum , GLuint , GLuint , GLenum , GLuint , GLuint )>(context->getProcAddress("glPresentFrameKeyedNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_primitive_restart::QOpenGLExtension_NV_primitive_restart()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_primitive_restartPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_primitive_restart::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_primitive_restart);
+
+ d->PrimitiveRestartIndexNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glPrimitiveRestartIndexNV"));
+ d->PrimitiveRestartNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glPrimitiveRestartNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_register_combiners::QOpenGLExtension_NV_register_combiners()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_register_combinersPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_register_combiners::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_register_combiners);
+
+ d->GetFinalCombinerInputParameterivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetFinalCombinerInputParameterivNV"));
+ d->GetFinalCombinerInputParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetFinalCombinerInputParameterfvNV"));
+ d->GetCombinerOutputParameterivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetCombinerOutputParameterivNV"));
+ d->GetCombinerOutputParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetCombinerOutputParameterfvNV"));
+ d->GetCombinerInputParameterivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLenum , GLint *)>(context->getProcAddress("glGetCombinerInputParameterivNV"));
+ d->GetCombinerInputParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetCombinerInputParameterfvNV"));
+ d->FinalCombinerInputNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLenum )>(context->getProcAddress("glFinalCombinerInputNV"));
+ d->CombinerOutputNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLenum , GLenum , GLenum , GLenum , GLboolean , GLboolean , GLboolean )>(context->getProcAddress("glCombinerOutputNV"));
+ d->CombinerInputNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLenum , GLenum , GLenum )>(context->getProcAddress("glCombinerInputNV"));
+ d->CombinerParameteriNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glCombinerParameteriNV"));
+ d->CombinerParameterivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glCombinerParameterivNV"));
+ d->CombinerParameterfNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glCombinerParameterfNV"));
+ d->CombinerParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glCombinerParameterfvNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_register_combiners2::QOpenGLExtension_NV_register_combiners2()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_register_combiners2Private))
+{
+}
+
+bool QOpenGLExtension_NV_register_combiners2::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_register_combiners2);
+
+ d->GetCombinerStageParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetCombinerStageParameterfvNV"));
+ d->CombinerStageParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glCombinerStageParameterfvNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_shader_buffer_load::QOpenGLExtension_NV_shader_buffer_load()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_shader_buffer_loadPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_shader_buffer_load::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+
+ d->ProgramUniformui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLsizei , const GLuint64EXT *)>(context->getProcAddress("glProgramUniformui64vNV"));
+ d->ProgramUniformui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint64EXT )>(context->getProcAddress("glProgramUniformui64NV"));
+ d->GetUniformui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLuint64EXT *)>(context->getProcAddress("glGetUniformui64vNV"));
+ d->Uniformui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLsizei , const GLuint64EXT *)>(context->getProcAddress("glUniformui64vNV"));
+ d->Uniformui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLuint64EXT )>(context->getProcAddress("glUniformui64NV"));
+ d->GetIntegerui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint64EXT *)>(context->getProcAddress("glGetIntegerui64vNV"));
+ d->GetNamedBufferParameterui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint64EXT *)>(context->getProcAddress("glGetNamedBufferParameterui64vNV"));
+ d->GetBufferParameterui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLuint64EXT *)>(context->getProcAddress("glGetBufferParameterui64vNV"));
+ d->IsNamedBufferResidentNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsNamedBufferResidentNV"));
+ d->MakeNamedBufferNonResidentNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glMakeNamedBufferNonResidentNV"));
+ d->MakeNamedBufferResidentNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum )>(context->getProcAddress("glMakeNamedBufferResidentNV"));
+ d->IsBufferResidentNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glIsBufferResidentNV"));
+ d->MakeBufferNonResidentNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glMakeBufferNonResidentNV"));
+ d->MakeBufferResidentNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glMakeBufferResidentNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_texture_barrier::QOpenGLExtension_NV_texture_barrier()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_texture_barrierPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_texture_barrier::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_texture_barrier);
+
+ d->TextureBarrierNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glTextureBarrierNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_texture_multisample::QOpenGLExtension_NV_texture_multisample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_texture_multisamplePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_texture_multisample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_texture_multisample);
+
+ d->TextureImage3DMultisampleCoverageNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , GLsizei , GLint , GLsizei , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTextureImage3DMultisampleCoverageNV"));
+ d->TextureImage2DMultisampleCoverageNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , GLsizei , GLint , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTextureImage2DMultisampleCoverageNV"));
+ d->TextureImage3DMultisampleNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , GLint , GLsizei , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTextureImage3DMultisampleNV"));
+ d->TextureImage2DMultisampleNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLsizei , GLint , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTextureImage2DMultisampleNV"));
+ d->TexImage3DMultisampleCoverageNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLsizei , GLint , GLsizei , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTexImage3DMultisampleCoverageNV"));
+ d->TexImage2DMultisampleCoverageNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , GLsizei , GLint , GLsizei , GLsizei , GLboolean )>(context->getProcAddress("glTexImage2DMultisampleCoverageNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_transform_feedback::QOpenGLExtension_NV_transform_feedback()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_transform_feedbackPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_transform_feedback::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+
+ d->TransformFeedbackStreamAttribsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLint *, GLsizei , const GLint *, GLenum )>(context->getProcAddress("glTransformFeedbackStreamAttribsNV"));
+ d->GetTransformFeedbackVaryingNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLint *)>(context->getProcAddress("glGetTransformFeedbackVaryingNV"));
+ d->GetActiveVaryingNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLsizei , GLsizei *, GLsizei *, GLenum *, GLchar *)>(context->getProcAddress("glGetActiveVaryingNV"));
+ d->GetVaryingLocationNV = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint , const GLchar *)>(context->getProcAddress("glGetVaryingLocationNV"));
+ d->ActiveVaryingNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLchar *)>(context->getProcAddress("glActiveVaryingNV"));
+ d->TransformFeedbackVaryingsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLint *, GLenum )>(context->getProcAddress("glTransformFeedbackVaryingsNV"));
+ d->BindBufferBaseNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint )>(context->getProcAddress("glBindBufferBaseNV"));
+ d->BindBufferOffsetNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLintptr )>(context->getProcAddress("glBindBufferOffsetNV"));
+ d->BindBufferRangeNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint , GLintptr , GLsizeiptr )>(context->getProcAddress("glBindBufferRangeNV"));
+ d->TransformFeedbackAttribsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *, GLenum )>(context->getProcAddress("glTransformFeedbackAttribsNV"));
+ d->EndTransformFeedbackNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glEndTransformFeedbackNV"));
+ d->BeginTransformFeedbackNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glBeginTransformFeedbackNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_transform_feedback2::QOpenGLExtension_NV_transform_feedback2()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_transform_feedback2Private))
+{
+}
+
+bool QOpenGLExtension_NV_transform_feedback2::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_transform_feedback2);
+
+ d->DrawTransformFeedbackNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glDrawTransformFeedbackNV"));
+ d->ResumeTransformFeedbackNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glResumeTransformFeedbackNV"));
+ d->PauseTransformFeedbackNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glPauseTransformFeedbackNV"));
+ d->IsTransformFeedbackNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsTransformFeedbackNV"));
+ d->GenTransformFeedbacksNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenTransformFeedbacksNV"));
+ d->DeleteTransformFeedbacksNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteTransformFeedbacksNV"));
+ d->BindTransformFeedbackNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindTransformFeedbackNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_vdpau_interop::QOpenGLExtension_NV_vdpau_interop()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_vdpau_interopPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_vdpau_interop::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_vdpau_interop);
+
+ d->VDPAUUnmapSurfacesNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLvdpauSurfaceNV *)>(context->getProcAddress("glVDPAUUnmapSurfacesNV"));
+ d->VDPAUMapSurfacesNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLvdpauSurfaceNV *)>(context->getProcAddress("glVDPAUMapSurfacesNV"));
+ d->VDPAUSurfaceAccessNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLvdpauSurfaceNV , GLenum )>(context->getProcAddress("glVDPAUSurfaceAccessNV"));
+ d->VDPAUGetSurfaceivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLvdpauSurfaceNV , GLenum , GLsizei , GLsizei *, GLint *)>(context->getProcAddress("glVDPAUGetSurfaceivNV"));
+ d->VDPAUUnregisterSurfaceNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLvdpauSurfaceNV )>(context->getProcAddress("glVDPAUUnregisterSurfaceNV"));
+ d->VDPAUIsSurfaceNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLvdpauSurfaceNV )>(context->getProcAddress("glVDPAUIsSurfaceNV"));
+ d->VDPAURegisterOutputSurfaceNV = reinterpret_cast<GLvdpauSurfaceNV (QOPENGLF_APIENTRYP)(GLvoid *, GLenum , GLsizei , const GLuint *)>(context->getProcAddress("glVDPAURegisterOutputSurfaceNV"));
+ d->VDPAURegisterVideoSurfaceNV = reinterpret_cast<GLvdpauSurfaceNV (QOPENGLF_APIENTRYP)(const GLvoid *, GLenum , GLsizei , const GLuint *)>(context->getProcAddress("glVDPAURegisterVideoSurfaceNV"));
+ d->VDPAUFiniNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glVDPAUFiniNV"));
+ d->VDPAUInitNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLvoid *, const GLvoid *)>(context->getProcAddress("glVDPAUInitNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_vertex_array_range::QOpenGLExtension_NV_vertex_array_range()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_vertex_array_rangePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_vertex_array_range::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_vertex_array_range);
+
+ d->VertexArrayRangeNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLvoid *)>(context->getProcAddress("glVertexArrayRangeNV"));
+ d->FlushVertexArrayRangeNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glFlushVertexArrayRangeNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_vertex_attrib_integer_64bit::QOpenGLExtension_NV_vertex_attrib_integer_64bit()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_vertex_attrib_integer_64bitPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_vertex_attrib_integer_64bit::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+
+ d->VertexAttribLFormatNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLsizei )>(context->getProcAddress("glVertexAttribLFormatNV"));
+ d->GetVertexAttribLui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint64EXT *)>(context->getProcAddress("glGetVertexAttribLui64vNV"));
+ d->GetVertexAttribLi64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint64EXT *)>(context->getProcAddress("glGetVertexAttribLi64vNV"));
+ d->VertexAttribL4ui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint64EXT *)>(context->getProcAddress("glVertexAttribL4ui64vNV"));
+ d->VertexAttribL3ui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint64EXT *)>(context->getProcAddress("glVertexAttribL3ui64vNV"));
+ d->VertexAttribL2ui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint64EXT *)>(context->getProcAddress("glVertexAttribL2ui64vNV"));
+ d->VertexAttribL1ui64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint64EXT *)>(context->getProcAddress("glVertexAttribL1ui64vNV"));
+ d->VertexAttribL4ui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint64EXT , GLuint64EXT , GLuint64EXT , GLuint64EXT )>(context->getProcAddress("glVertexAttribL4ui64NV"));
+ d->VertexAttribL3ui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint64EXT , GLuint64EXT , GLuint64EXT )>(context->getProcAddress("glVertexAttribL3ui64NV"));
+ d->VertexAttribL2ui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint64EXT , GLuint64EXT )>(context->getProcAddress("glVertexAttribL2ui64NV"));
+ d->VertexAttribL1ui64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint64EXT )>(context->getProcAddress("glVertexAttribL1ui64NV"));
+ d->VertexAttribL4i64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint64EXT *)>(context->getProcAddress("glVertexAttribL4i64vNV"));
+ d->VertexAttribL3i64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint64EXT *)>(context->getProcAddress("glVertexAttribL3i64vNV"));
+ d->VertexAttribL2i64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint64EXT *)>(context->getProcAddress("glVertexAttribL2i64vNV"));
+ d->VertexAttribL1i64vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint64EXT *)>(context->getProcAddress("glVertexAttribL1i64vNV"));
+ d->VertexAttribL4i64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint64EXT , GLint64EXT , GLint64EXT , GLint64EXT )>(context->getProcAddress("glVertexAttribL4i64NV"));
+ d->VertexAttribL3i64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint64EXT , GLint64EXT , GLint64EXT )>(context->getProcAddress("glVertexAttribL3i64NV"));
+ d->VertexAttribL2i64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint64EXT , GLint64EXT )>(context->getProcAddress("glVertexAttribL2i64NV"));
+ d->VertexAttribL1i64NV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint64EXT )>(context->getProcAddress("glVertexAttribL1i64NV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_vertex_buffer_unified_memory::QOpenGLExtension_NV_vertex_buffer_unified_memory()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_vertex_buffer_unified_memoryPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_vertex_buffer_unified_memory::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+
+ d->GetIntegerui64i_vNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint64EXT *)>(context->getProcAddress("glGetIntegerui64i_vNV"));
+ d->VertexAttribIFormatNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLsizei )>(context->getProcAddress("glVertexAttribIFormatNV"));
+ d->VertexAttribFormatNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLboolean , GLsizei )>(context->getProcAddress("glVertexAttribFormatNV"));
+ d->FogCoordFormatNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei )>(context->getProcAddress("glFogCoordFormatNV"));
+ d->SecondaryColorFormatNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei )>(context->getProcAddress("glSecondaryColorFormatNV"));
+ d->EdgeFlagFormatNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei )>(context->getProcAddress("glEdgeFlagFormatNV"));
+ d->TexCoordFormatNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei )>(context->getProcAddress("glTexCoordFormatNV"));
+ d->IndexFormatNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei )>(context->getProcAddress("glIndexFormatNV"));
+ d->ColorFormatNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei )>(context->getProcAddress("glColorFormatNV"));
+ d->NormalFormatNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei )>(context->getProcAddress("glNormalFormatNV"));
+ d->VertexFormatNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint , GLenum , GLsizei )>(context->getProcAddress("glVertexFormatNV"));
+ d->BufferAddressRangeNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLuint64EXT , GLsizeiptr )>(context->getProcAddress("glBufferAddressRangeNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_vertex_program::QOpenGLExtension_NV_vertex_program()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_vertex_programPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_vertex_program::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_vertex_program);
+
+ d->VertexAttribs4ubvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLubyte *)>(context->getProcAddress("glVertexAttribs4ubvNV"));
+ d->VertexAttribs4svNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLshort *)>(context->getProcAddress("glVertexAttribs4svNV"));
+ d->VertexAttribs4fvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLfloat *)>(context->getProcAddress("glVertexAttribs4fvNV"));
+ d->VertexAttribs4dvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLdouble *)>(context->getProcAddress("glVertexAttribs4dvNV"));
+ d->VertexAttribs3svNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLshort *)>(context->getProcAddress("glVertexAttribs3svNV"));
+ d->VertexAttribs3fvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLfloat *)>(context->getProcAddress("glVertexAttribs3fvNV"));
+ d->VertexAttribs3dvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLdouble *)>(context->getProcAddress("glVertexAttribs3dvNV"));
+ d->VertexAttribs2svNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLshort *)>(context->getProcAddress("glVertexAttribs2svNV"));
+ d->VertexAttribs2fvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLfloat *)>(context->getProcAddress("glVertexAttribs2fvNV"));
+ d->VertexAttribs2dvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLdouble *)>(context->getProcAddress("glVertexAttribs2dvNV"));
+ d->VertexAttribs1svNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLshort *)>(context->getProcAddress("glVertexAttribs1svNV"));
+ d->VertexAttribs1fvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLfloat *)>(context->getProcAddress("glVertexAttribs1fvNV"));
+ d->VertexAttribs1dvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei , const GLdouble *)>(context->getProcAddress("glVertexAttribs1dvNV"));
+ d->VertexAttrib4ubvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLubyte *)>(context->getProcAddress("glVertexAttrib4ubvNV"));
+ d->VertexAttrib4ubNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLubyte , GLubyte , GLubyte , GLubyte )>(context->getProcAddress("glVertexAttrib4ubNV"));
+ d->VertexAttrib4svNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib4svNV"));
+ d->VertexAttrib4sNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLshort , GLshort , GLshort , GLshort )>(context->getProcAddress("glVertexAttrib4sNV"));
+ d->VertexAttrib4fvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVertexAttrib4fvNV"));
+ d->VertexAttrib4fNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glVertexAttrib4fNV"));
+ d->VertexAttrib4dvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttrib4dvNV"));
+ d->VertexAttrib4dNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttrib4dNV"));
+ d->VertexAttrib3svNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib3svNV"));
+ d->VertexAttrib3sNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLshort , GLshort , GLshort )>(context->getProcAddress("glVertexAttrib3sNV"));
+ d->VertexAttrib3fvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVertexAttrib3fvNV"));
+ d->VertexAttrib3fNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glVertexAttrib3fNV"));
+ d->VertexAttrib3dvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttrib3dvNV"));
+ d->VertexAttrib3dNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttrib3dNV"));
+ d->VertexAttrib2svNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib2svNV"));
+ d->VertexAttrib2sNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLshort , GLshort )>(context->getProcAddress("glVertexAttrib2sNV"));
+ d->VertexAttrib2fvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVertexAttrib2fvNV"));
+ d->VertexAttrib2fNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat )>(context->getProcAddress("glVertexAttrib2fNV"));
+ d->VertexAttrib2dvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttrib2dvNV"));
+ d->VertexAttrib2dNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble , GLdouble )>(context->getProcAddress("glVertexAttrib2dNV"));
+ d->VertexAttrib1svNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttrib1svNV"));
+ d->VertexAttrib1sNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLshort )>(context->getProcAddress("glVertexAttrib1sNV"));
+ d->VertexAttrib1fvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLfloat *)>(context->getProcAddress("glVertexAttrib1fvNV"));
+ d->VertexAttrib1fNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat )>(context->getProcAddress("glVertexAttrib1fNV"));
+ d->VertexAttrib1dvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLdouble *)>(context->getProcAddress("glVertexAttrib1dvNV"));
+ d->VertexAttrib1dNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLdouble )>(context->getProcAddress("glVertexAttrib1dNV"));
+ d->VertexAttribPointerNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glVertexAttribPointerNV"));
+ d->TrackMatrixNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum , GLenum )>(context->getProcAddress("glTrackMatrixNV"));
+ d->RequestResidentProgramsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glRequestResidentProgramsNV"));
+ d->ProgramParameters4fvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei , const GLfloat *)>(context->getProcAddress("glProgramParameters4fvNV"));
+ d->ProgramParameters4dvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei , const GLdouble *)>(context->getProcAddress("glProgramParameters4dvNV"));
+ d->ProgramParameter4fvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLfloat *)>(context->getProcAddress("glProgramParameter4fvNV"));
+ d->ProgramParameter4fNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glProgramParameter4fNV"));
+ d->ProgramParameter4dvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLdouble *)>(context->getProcAddress("glProgramParameter4dvNV"));
+ d->ProgramParameter4dNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLdouble , GLdouble , GLdouble , GLdouble )>(context->getProcAddress("glProgramParameter4dNV"));
+ d->LoadProgramNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLsizei , const GLubyte *)>(context->getProcAddress("glLoadProgramNV"));
+ d->IsProgramNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsProgramNV"));
+ d->GetVertexAttribPointervNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLvoid* *)>(context->getProcAddress("glGetVertexAttribPointervNV"));
+ d->GetVertexAttribivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetVertexAttribivNV"));
+ d->GetVertexAttribfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetVertexAttribfvNV"));
+ d->GetVertexAttribdvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLdouble *)>(context->getProcAddress("glGetVertexAttribdvNV"));
+ d->GetTrackMatrixivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum , GLint *)>(context->getProcAddress("glGetTrackMatrixivNV"));
+ d->GetProgramStringNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLubyte *)>(context->getProcAddress("glGetProgramStringNV"));
+ d->GetProgramivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetProgramivNV"));
+ d->GetProgramParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetProgramParameterfvNV"));
+ d->GetProgramParameterdvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , GLenum , GLdouble *)>(context->getProcAddress("glGetProgramParameterdvNV"));
+ d->GenProgramsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLuint *)>(context->getProcAddress("glGenProgramsNV"));
+ d->ExecuteProgramNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint , const GLfloat *)>(context->getProcAddress("glExecuteProgramNV"));
+ d->DeleteProgramsNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *)>(context->getProcAddress("glDeleteProgramsNV"));
+ d->BindProgramNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLuint )>(context->getProcAddress("glBindProgramNV"));
+ d->AreProgramsResidentNV = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLsizei , const GLuint *, GLboolean *)>(context->getProcAddress("glAreProgramsResidentNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_vertex_program4::QOpenGLExtension_NV_vertex_program4()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_vertex_program4Private))
+{
+}
+
+bool QOpenGLExtension_NV_vertex_program4::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+
+ d->GetVertexAttribIuivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLuint *)>(context->getProcAddress("glGetVertexAttribIuivEXT"));
+ d->GetVertexAttribIivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetVertexAttribIivEXT"));
+ d->VertexAttribIPointerEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLenum , GLsizei , const GLvoid *)>(context->getProcAddress("glVertexAttribIPointerEXT"));
+ d->VertexAttribI4usvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLushort *)>(context->getProcAddress("glVertexAttribI4usvEXT"));
+ d->VertexAttribI4ubvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLubyte *)>(context->getProcAddress("glVertexAttribI4ubvEXT"));
+ d->VertexAttribI4svEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLshort *)>(context->getProcAddress("glVertexAttribI4svEXT"));
+ d->VertexAttribI4bvEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLbyte *)>(context->getProcAddress("glVertexAttribI4bvEXT"));
+ d->VertexAttribI4uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVertexAttribI4uivEXT"));
+ d->VertexAttribI3uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVertexAttribI3uivEXT"));
+ d->VertexAttribI2uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVertexAttribI2uivEXT"));
+ d->VertexAttribI1uivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLuint *)>(context->getProcAddress("glVertexAttribI1uivEXT"));
+ d->VertexAttribI4ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVertexAttribI4ivEXT"));
+ d->VertexAttribI3ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVertexAttribI3ivEXT"));
+ d->VertexAttribI2ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVertexAttribI2ivEXT"));
+ d->VertexAttribI1ivEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , const GLint *)>(context->getProcAddress("glVertexAttribI1ivEXT"));
+ d->VertexAttribI4uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glVertexAttribI4uiEXT"));
+ d->VertexAttribI3uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint , GLuint )>(context->getProcAddress("glVertexAttribI3uiEXT"));
+ d->VertexAttribI2uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLuint )>(context->getProcAddress("glVertexAttribI2uiEXT"));
+ d->VertexAttribI1uiEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint )>(context->getProcAddress("glVertexAttribI1uiEXT"));
+ d->VertexAttribI4iEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint , GLint )>(context->getProcAddress("glVertexAttribI4iEXT"));
+ d->VertexAttribI3iEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint , GLint )>(context->getProcAddress("glVertexAttribI3iEXT"));
+ d->VertexAttribI2iEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint , GLint )>(context->getProcAddress("glVertexAttribI2iEXT"));
+ d->VertexAttribI1iEXT = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLint )>(context->getProcAddress("glVertexAttribI1iEXT"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_NV_video_capture::QOpenGLExtension_NV_video_capture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_video_capturePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_video_capture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_video_capture);
+
+ d->VideoCaptureStreamParameterdvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , const GLdouble *)>(context->getProcAddress("glVideoCaptureStreamParameterdvNV"));
+ d->VideoCaptureStreamParameterfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , const GLfloat *)>(context->getProcAddress("glVideoCaptureStreamParameterfvNV"));
+ d->VideoCaptureStreamParameterivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , const GLint *)>(context->getProcAddress("glVideoCaptureStreamParameterivNV"));
+ d->VideoCaptureNV = reinterpret_cast<GLenum (QOPENGLF_APIENTRYP)(GLuint , GLuint *, GLuint64EXT *)>(context->getProcAddress("glVideoCaptureNV"));
+ d->GetVideoCaptureStreamdvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , GLdouble *)>(context->getProcAddress("glGetVideoCaptureStreamdvNV"));
+ d->GetVideoCaptureStreamfvNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetVideoCaptureStreamfvNV"));
+ d->GetVideoCaptureStreamivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , GLint *)>(context->getProcAddress("glGetVideoCaptureStreamivNV"));
+ d->GetVideoCaptureivNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetVideoCaptureivNV"));
+ d->EndVideoCaptureNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glEndVideoCaptureNV"));
+ d->BindVideoCaptureStreamTextureNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , GLenum , GLuint )>(context->getProcAddress("glBindVideoCaptureStreamTextureNV"));
+ d->BindVideoCaptureStreamBufferNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLuint , GLenum , GLintptrARB )>(context->getProcAddress("glBindVideoCaptureStreamBufferNV"));
+ d->BeginVideoCaptureNV = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glBeginVideoCaptureNV"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_PGI_misc_hints::QOpenGLExtension_PGI_misc_hints()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_PGI_misc_hintsPrivate))
+{
+}
+
+bool QOpenGLExtension_PGI_misc_hints::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_PGI_misc_hints);
+
+ d->HintPGI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glHintPGI"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIS_detail_texture::QOpenGLExtension_SGIS_detail_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIS_detail_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_SGIS_detail_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIS_detail_texture);
+
+ d->GetDetailTexFuncSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat *)>(context->getProcAddress("glGetDetailTexFuncSGIS"));
+ d->DetailTexFuncSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLfloat *)>(context->getProcAddress("glDetailTexFuncSGIS"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIS_fog_function::QOpenGLExtension_SGIS_fog_function()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIS_fog_functionPrivate))
+{
+}
+
+bool QOpenGLExtension_SGIS_fog_function::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIS_fog_function);
+
+ d->GetFogFuncSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat *)>(context->getProcAddress("glGetFogFuncSGIS"));
+ d->FogFuncSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , const GLfloat *)>(context->getProcAddress("glFogFuncSGIS"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIS_multisample::QOpenGLExtension_SGIS_multisample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIS_multisamplePrivate))
+{
+}
+
+bool QOpenGLExtension_SGIS_multisample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIS_multisample);
+
+ d->SamplePatternSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glSamplePatternSGIS"));
+ d->SampleMaskSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLclampf , GLboolean )>(context->getProcAddress("glSampleMaskSGIS"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIS_pixel_texture::QOpenGLExtension_SGIS_pixel_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIS_pixel_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_SGIS_pixel_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIS_pixel_texture);
+
+ d->GetPixelTexGenParameterfvSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat *)>(context->getProcAddress("glGetPixelTexGenParameterfvSGIS"));
+ d->GetPixelTexGenParameterivSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint *)>(context->getProcAddress("glGetPixelTexGenParameterivSGIS"));
+ d->PixelTexGenParameterfvSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glPixelTexGenParameterfvSGIS"));
+ d->PixelTexGenParameterfSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glPixelTexGenParameterfSGIS"));
+ d->PixelTexGenParameterivSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glPixelTexGenParameterivSGIS"));
+ d->PixelTexGenParameteriSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glPixelTexGenParameteriSGIS"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIS_point_parameters::QOpenGLExtension_SGIS_point_parameters()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIS_point_parametersPrivate))
+{
+}
+
+bool QOpenGLExtension_SGIS_point_parameters::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIS_point_parameters);
+
+ d->PointParameterfvSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glPointParameterfvSGIS"));
+ d->PointParameterfSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glPointParameterfSGIS"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIS_sharpen_texture::QOpenGLExtension_SGIS_sharpen_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIS_sharpen_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_SGIS_sharpen_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIS_sharpen_texture);
+
+ d->GetSharpenTexFuncSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat *)>(context->getProcAddress("glGetSharpenTexFuncSGIS"));
+ d->SharpenTexFuncSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLfloat *)>(context->getProcAddress("glSharpenTexFuncSGIS"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIS_texture4D::QOpenGLExtension_SGIS_texture4D()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIS_texture4DPrivate))
+{
+}
+
+bool QOpenGLExtension_SGIS_texture4D::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIS_texture4D);
+
+ d->TexSubImage4DSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLint , GLint , GLint , GLint , GLsizei , GLsizei , GLsizei , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTexSubImage4DSGIS"));
+ d->TexImage4DSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLenum , GLsizei , GLsizei , GLsizei , GLsizei , GLint , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glTexImage4DSGIS"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIS_texture_color_mask::QOpenGLExtension_SGIS_texture_color_mask()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIS_texture_color_maskPrivate))
+{
+}
+
+bool QOpenGLExtension_SGIS_texture_color_mask::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIS_texture_color_mask);
+
+ d->TextureColorMaskSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLboolean , GLboolean , GLboolean , GLboolean )>(context->getProcAddress("glTextureColorMaskSGIS"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIS_texture_filter4::QOpenGLExtension_SGIS_texture_filter4()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIS_texture_filter4Private))
+{
+}
+
+bool QOpenGLExtension_SGIS_texture_filter4::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIS_texture_filter4);
+
+ d->TexFilterFuncSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , const GLfloat *)>(context->getProcAddress("glTexFilterFuncSGIS"));
+ d->GetTexFilterFuncSGIS = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetTexFilterFuncSGIS"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIX_async::QOpenGLExtension_SGIX_async()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIX_asyncPrivate))
+{
+}
+
+bool QOpenGLExtension_SGIX_async::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIX_async);
+
+ d->IsAsyncMarkerSGIX = reinterpret_cast<GLboolean (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glIsAsyncMarkerSGIX"));
+ d->DeleteAsyncMarkersSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLsizei )>(context->getProcAddress("glDeleteAsyncMarkersSGIX"));
+ d->GenAsyncMarkersSGIX = reinterpret_cast<GLuint (QOPENGLF_APIENTRYP)(GLsizei )>(context->getProcAddress("glGenAsyncMarkersSGIX"));
+ d->PollAsyncSGIX = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint *)>(context->getProcAddress("glPollAsyncSGIX"));
+ d->FinishAsyncSGIX = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLuint *)>(context->getProcAddress("glFinishAsyncSGIX"));
+ d->AsyncMarkerSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glAsyncMarkerSGIX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIX_flush_raster::QOpenGLExtension_SGIX_flush_raster()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIX_flush_rasterPrivate))
+{
+}
+
+bool QOpenGLExtension_SGIX_flush_raster::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIX_flush_raster);
+
+ d->FlushRasterSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glFlushRasterSGIX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIX_fragment_lighting::QOpenGLExtension_SGIX_fragment_lighting()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIX_fragment_lightingPrivate))
+{
+}
+
+bool QOpenGLExtension_SGIX_fragment_lighting::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+
+ d->LightEnviSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glLightEnviSGIX"));
+ d->GetFragmentMaterialivSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetFragmentMaterialivSGIX"));
+ d->GetFragmentMaterialfvSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetFragmentMaterialfvSGIX"));
+ d->GetFragmentLightivSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetFragmentLightivSGIX"));
+ d->GetFragmentLightfvSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetFragmentLightfvSGIX"));
+ d->FragmentMaterialivSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glFragmentMaterialivSGIX"));
+ d->FragmentMaterialiSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glFragmentMaterialiSGIX"));
+ d->FragmentMaterialfvSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glFragmentMaterialfvSGIX"));
+ d->FragmentMaterialfSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(context->getProcAddress("glFragmentMaterialfSGIX"));
+ d->FragmentLightModelivSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glFragmentLightModelivSGIX"));
+ d->FragmentLightModeliSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glFragmentLightModeliSGIX"));
+ d->FragmentLightModelfvSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glFragmentLightModelfvSGIX"));
+ d->FragmentLightModelfSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glFragmentLightModelfSGIX"));
+ d->FragmentLightivSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glFragmentLightivSGIX"));
+ d->FragmentLightiSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint )>(context->getProcAddress("glFragmentLightiSGIX"));
+ d->FragmentLightfvSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glFragmentLightfvSGIX"));
+ d->FragmentLightfSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat )>(context->getProcAddress("glFragmentLightfSGIX"));
+ d->FragmentColorMaterialSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum )>(context->getProcAddress("glFragmentColorMaterialSGIX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIX_framezoom::QOpenGLExtension_SGIX_framezoom()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIX_framezoomPrivate))
+{
+}
+
+bool QOpenGLExtension_SGIX_framezoom::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIX_framezoom);
+
+ d->FrameZoomSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(context->getProcAddress("glFrameZoomSGIX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIX_igloo_interface::QOpenGLExtension_SGIX_igloo_interface()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIX_igloo_interfacePrivate))
+{
+}
+
+bool QOpenGLExtension_SGIX_igloo_interface::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIX_igloo_interface);
+
+ d->IglooInterfaceSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLvoid *)>(context->getProcAddress("glIglooInterfaceSGIX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIX_instruments::QOpenGLExtension_SGIX_instruments()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIX_instrumentsPrivate))
+{
+}
+
+bool QOpenGLExtension_SGIX_instruments::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIX_instruments);
+
+ d->StopInstrumentsSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(context->getProcAddress("glStopInstrumentsSGIX"));
+ d->StartInstrumentsSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glStartInstrumentsSGIX"));
+ d->ReadInstrumentsSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(context->getProcAddress("glReadInstrumentsSGIX"));
+ d->PollInstrumentsSGIX = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)(GLint *)>(context->getProcAddress("glPollInstrumentsSGIX"));
+ d->InstrumentsBufferSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLsizei , GLint *)>(context->getProcAddress("glInstrumentsBufferSGIX"));
+ d->GetInstrumentsSGIX = reinterpret_cast<GLint (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glGetInstrumentsSGIX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIX_list_priority::QOpenGLExtension_SGIX_list_priority()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIX_list_priorityPrivate))
+{
+}
+
+bool QOpenGLExtension_SGIX_list_priority::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIX_list_priority);
+
+ d->ListParameterivSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLint *)>(context->getProcAddress("glListParameterivSGIX"));
+ d->ListParameteriSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint )>(context->getProcAddress("glListParameteriSGIX"));
+ d->ListParameterfvSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , const GLfloat *)>(context->getProcAddress("glListParameterfvSGIX"));
+ d->ListParameterfSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat )>(context->getProcAddress("glListParameterfSGIX"));
+ d->GetListParameterivSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLint *)>(context->getProcAddress("glGetListParameterivSGIX"));
+ d->GetListParameterfvSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLenum , GLfloat *)>(context->getProcAddress("glGetListParameterfvSGIX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIX_pixel_texture::QOpenGLExtension_SGIX_pixel_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIX_pixel_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_SGIX_pixel_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIX_pixel_texture);
+
+ d->PixelTexGenSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum )>(context->getProcAddress("glPixelTexGenSGIX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIX_polynomial_ffd::QOpenGLExtension_SGIX_polynomial_ffd()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIX_polynomial_ffdPrivate))
+{
+}
+
+bool QOpenGLExtension_SGIX_polynomial_ffd::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIX_polynomial_ffd);
+
+ d->LoadIdentityDeformationMapSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(context->getProcAddress("glLoadIdentityDeformationMapSGIX"));
+ d->DeformSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbitfield )>(context->getProcAddress("glDeformSGIX"));
+ d->DeformationMap3fSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat , GLfloat , GLint , GLint , GLfloat , GLfloat , GLint , GLint , GLfloat , GLfloat , GLint , GLint , const GLfloat *)>(context->getProcAddress("glDeformationMap3fSGIX"));
+ d->DeformationMap3dSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLdouble , GLdouble , GLint , GLint , GLdouble , GLdouble , GLint , GLint , GLdouble , GLdouble , GLint , GLint , const GLdouble *)>(context->getProcAddress("glDeformationMap3dSGIX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIX_reference_plane::QOpenGLExtension_SGIX_reference_plane()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIX_reference_planePrivate))
+{
+}
+
+bool QOpenGLExtension_SGIX_reference_plane::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIX_reference_plane);
+
+ d->ReferencePlaneSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLdouble *)>(context->getProcAddress("glReferencePlaneSGIX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIX_sprite::QOpenGLExtension_SGIX_sprite()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIX_spritePrivate))
+{
+}
+
+bool QOpenGLExtension_SGIX_sprite::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIX_sprite);
+
+ d->SpriteParameterivSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLint *)>(context->getProcAddress("glSpriteParameterivSGIX"));
+ d->SpriteParameteriSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint )>(context->getProcAddress("glSpriteParameteriSGIX"));
+ d->SpriteParameterfvSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , const GLfloat *)>(context->getProcAddress("glSpriteParameterfvSGIX"));
+ d->SpriteParameterfSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLfloat )>(context->getProcAddress("glSpriteParameterfSGIX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGIX_tag_sample_buffer::QOpenGLExtension_SGIX_tag_sample_buffer()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGIX_tag_sample_bufferPrivate))
+{
+}
+
+bool QOpenGLExtension_SGIX_tag_sample_buffer::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGIX_tag_sample_buffer);
+
+ d->TagSampleBufferSGIX = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glTagSampleBufferSGIX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SGI_color_table::QOpenGLExtension_SGI_color_table()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SGI_color_tablePrivate))
+{
+}
+
+bool QOpenGLExtension_SGI_color_table::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SGI_color_table);
+
+ d->GetColorTableParameterivSGI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint *)>(context->getProcAddress("glGetColorTableParameterivSGI"));
+ d->GetColorTableParameterfvSGI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLfloat *)>(context->getProcAddress("glGetColorTableParameterfvSGI"));
+ d->GetColorTableSGI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLenum , GLvoid *)>(context->getProcAddress("glGetColorTableSGI"));
+ d->CopyColorTableSGI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLint , GLint , GLsizei )>(context->getProcAddress("glCopyColorTableSGI"));
+ d->ColorTableParameterivSGI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLint *)>(context->getProcAddress("glColorTableParameterivSGI"));
+ d->ColorTableParameterfvSGI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , const GLfloat *)>(context->getProcAddress("glColorTableParameterfvSGI"));
+ d->ColorTableSGI = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLenum , GLsizei , GLenum , GLenum , const GLvoid *)>(context->getProcAddress("glColorTableSGI"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SUNX_constant_data::QOpenGLExtension_SUNX_constant_data()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SUNX_constant_dataPrivate))
+{
+}
+
+bool QOpenGLExtension_SUNX_constant_data::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SUNX_constant_data);
+
+ d->FinishTextureSUNX = reinterpret_cast<void (QOPENGLF_APIENTRYP)()>(context->getProcAddress("glFinishTextureSUNX"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SUN_global_alpha::QOpenGLExtension_SUN_global_alpha()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SUN_global_alphaPrivate))
+{
+}
+
+bool QOpenGLExtension_SUN_global_alpha::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SUN_global_alpha);
+
+ d->GlobalAlphaFactoruiSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glGlobalAlphaFactoruiSUN"));
+ d->GlobalAlphaFactorusSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLushort )>(context->getProcAddress("glGlobalAlphaFactorusSUN"));
+ d->GlobalAlphaFactorubSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte )>(context->getProcAddress("glGlobalAlphaFactorubSUN"));
+ d->GlobalAlphaFactordSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLdouble )>(context->getProcAddress("glGlobalAlphaFactordSUN"));
+ d->GlobalAlphaFactorfSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat )>(context->getProcAddress("glGlobalAlphaFactorfSUN"));
+ d->GlobalAlphaFactoriSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLint )>(context->getProcAddress("glGlobalAlphaFactoriSUN"));
+ d->GlobalAlphaFactorsSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLshort )>(context->getProcAddress("glGlobalAlphaFactorsSUN"));
+ d->GlobalAlphaFactorbSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLbyte )>(context->getProcAddress("glGlobalAlphaFactorbSUN"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SUN_mesh_array::QOpenGLExtension_SUN_mesh_array()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SUN_mesh_arrayPrivate))
+{
+}
+
+bool QOpenGLExtension_SUN_mesh_array::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SUN_mesh_array);
+
+ d->DrawMeshArraysSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLint , GLsizei , GLsizei )>(context->getProcAddress("glDrawMeshArraysSUN"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SUN_triangle_list::QOpenGLExtension_SUN_triangle_list()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SUN_triangle_listPrivate))
+{
+}
+
+bool QOpenGLExtension_SUN_triangle_list::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SUN_triangle_list);
+
+ d->ReplacementCodePointerSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLenum , GLsizei , const GLvoid* *)>(context->getProcAddress("glReplacementCodePointerSUN"));
+ d->ReplacementCodeubvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *)>(context->getProcAddress("glReplacementCodeubvSUN"));
+ d->ReplacementCodeusvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLushort *)>(context->getProcAddress("glReplacementCodeusvSUN"));
+ d->ReplacementCodeuivSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *)>(context->getProcAddress("glReplacementCodeuivSUN"));
+ d->ReplacementCodeubSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte )>(context->getProcAddress("glReplacementCodeubSUN"));
+ d->ReplacementCodeusSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLushort )>(context->getProcAddress("glReplacementCodeusSUN"));
+ d->ReplacementCodeuiSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint )>(context->getProcAddress("glReplacementCodeuiSUN"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+QOpenGLExtension_SUN_vertex::QOpenGLExtension_SUN_vertex()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_SUN_vertexPrivate))
+{
+}
+
+bool QOpenGLExtension_SUN_vertex::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_SUN_vertex);
+
+ d->ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *)>(context->getProcAddress("glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN"));
+ d->ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN"));
+ d->ReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *)>(context->getProcAddress("glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN"));
+ d->ReplacementCodeuiTexCoord2fNormal3fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN"));
+ d->ReplacementCodeuiTexCoord2fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *, const GLfloat *, const GLfloat *)>(context->getProcAddress("glReplacementCodeuiTexCoord2fVertex3fvSUN"));
+ d->ReplacementCodeuiTexCoord2fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glReplacementCodeuiTexCoord2fVertex3fSUN"));
+ d->ReplacementCodeuiColor4fNormal3fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *)>(context->getProcAddress("glReplacementCodeuiColor4fNormal3fVertex3fvSUN"));
+ d->ReplacementCodeuiColor4fNormal3fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glReplacementCodeuiColor4fNormal3fVertex3fSUN"));
+ d->ReplacementCodeuiNormal3fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *, const GLfloat *, const GLfloat *)>(context->getProcAddress("glReplacementCodeuiNormal3fVertex3fvSUN"));
+ d->ReplacementCodeuiNormal3fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glReplacementCodeuiNormal3fVertex3fSUN"));
+ d->ReplacementCodeuiColor3fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *, const GLfloat *, const GLfloat *)>(context->getProcAddress("glReplacementCodeuiColor3fVertex3fvSUN"));
+ d->ReplacementCodeuiColor3fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glReplacementCodeuiColor3fVertex3fSUN"));
+ d->ReplacementCodeuiColor4ubVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *, const GLubyte *, const GLfloat *)>(context->getProcAddress("glReplacementCodeuiColor4ubVertex3fvSUN"));
+ d->ReplacementCodeuiColor4ubVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLubyte , GLubyte , GLubyte , GLubyte , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glReplacementCodeuiColor4ubVertex3fSUN"));
+ d->ReplacementCodeuiVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLuint *, const GLfloat *)>(context->getProcAddress("glReplacementCodeuiVertex3fvSUN"));
+ d->ReplacementCodeuiVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLuint , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glReplacementCodeuiVertex3fSUN"));
+ d->TexCoord4fColor4fNormal3fVertex4fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *)>(context->getProcAddress("glTexCoord4fColor4fNormal3fVertex4fvSUN"));
+ d->TexCoord4fColor4fNormal3fVertex4fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glTexCoord4fColor4fNormal3fVertex4fSUN"));
+ d->TexCoord2fColor4fNormal3fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *)>(context->getProcAddress("glTexCoord2fColor4fNormal3fVertex3fvSUN"));
+ d->TexCoord2fColor4fNormal3fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glTexCoord2fColor4fNormal3fVertex3fSUN"));
+ d->TexCoord2fNormal3fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *, const GLfloat *, const GLfloat *)>(context->getProcAddress("glTexCoord2fNormal3fVertex3fvSUN"));
+ d->TexCoord2fNormal3fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glTexCoord2fNormal3fVertex3fSUN"));
+ d->TexCoord2fColor3fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *, const GLfloat *, const GLfloat *)>(context->getProcAddress("glTexCoord2fColor3fVertex3fvSUN"));
+ d->TexCoord2fColor3fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glTexCoord2fColor3fVertex3fSUN"));
+ d->TexCoord2fColor4ubVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *, const GLubyte *, const GLfloat *)>(context->getProcAddress("glTexCoord2fColor4ubVertex3fvSUN"));
+ d->TexCoord2fColor4ubVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLubyte , GLubyte , GLubyte , GLubyte , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glTexCoord2fColor4ubVertex3fSUN"));
+ d->TexCoord4fVertex4fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *, const GLfloat *)>(context->getProcAddress("glTexCoord4fVertex4fvSUN"));
+ d->TexCoord4fVertex4fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glTexCoord4fVertex4fSUN"));
+ d->TexCoord2fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *, const GLfloat *)>(context->getProcAddress("glTexCoord2fVertex3fvSUN"));
+ d->TexCoord2fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glTexCoord2fVertex3fSUN"));
+ d->Color4fNormal3fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *, const GLfloat *, const GLfloat *)>(context->getProcAddress("glColor4fNormal3fVertex3fvSUN"));
+ d->Color4fNormal3fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glColor4fNormal3fVertex3fSUN"));
+ d->Normal3fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *, const GLfloat *)>(context->getProcAddress("glNormal3fVertex3fvSUN"));
+ d->Normal3fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glNormal3fVertex3fSUN"));
+ d->Color3fVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLfloat *, const GLfloat *)>(context->getProcAddress("glColor3fVertex3fvSUN"));
+ d->Color3fVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLfloat , GLfloat , GLfloat , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glColor3fVertex3fSUN"));
+ d->Color4ubVertex3fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *, const GLfloat *)>(context->getProcAddress("glColor4ubVertex3fvSUN"));
+ d->Color4ubVertex3fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte , GLubyte , GLubyte , GLubyte , GLfloat , GLfloat , GLfloat )>(context->getProcAddress("glColor4ubVertex3fSUN"));
+ d->Color4ubVertex2fvSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(const GLubyte *, const GLfloat *)>(context->getProcAddress("glColor4ubVertex2fvSUN"));
+ d->Color4ubVertex2fSUN = reinterpret_cast<void (QOPENGLF_APIENTRYP)(GLubyte , GLubyte , GLubyte , GLubyte , GLfloat , GLfloat )>(context->getProcAddress("glColor4ubVertex2fSUN"));
+ QAbstractOpenGLExtension::initializeOpenGLFunctions();
+ return true;
+}
+
+
+#else
+
+QOpenGLExtension_OES_EGL_image::QOpenGLExtension_OES_EGL_image()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_OES_EGL_imagePrivate))
+{
+}
+
+bool QOpenGLExtension_OES_EGL_image::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_OES_EGL_image);
+
+ d->EGLImageTargetTexture2DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLeglImageOES image))context->getProcAddress("glEGLImageTargetTexture2DOES");
+ d->EGLImageTargetRenderbufferStorageOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLeglImageOES image))context->getProcAddress("glEGLImageTargetRenderbufferStorageOESs");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_OES_get_program_binary::QOpenGLExtension_OES_get_program_binary()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_OES_get_program_binaryPrivate))
+{
+}
+
+bool QOpenGLExtension_OES_get_program_binary::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_OES_get_program_binary);
+
+ d->GetProgramBinaryOES = (void (QOPENGLF_APIENTRYP)(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary))context->getProcAddress("glGetProgramBinaryOES");
+ d->ProgramBinaryOES = (void (QOPENGLF_APIENTRYP)(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLint length))context->getProcAddress("glProgramBinaryOES");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_OES_mapbuffer::QOpenGLExtension_OES_mapbuffer()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_OES_mapbufferPrivate))
+{
+}
+
+bool QOpenGLExtension_OES_mapbuffer::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_OES_mapbuffer);
+
+ d->MapBufferOES = (void* (QOPENGLF_APIENTRYP)(GLenum target, GLenum access))context->getProcAddress("glMapBufferOES");
+ d->UnmapBufferOES = (GLboolean (QOPENGLF_APIENTRYP)(GLenum target))context->getProcAddress("glUnmapBufferOES");
+ d->GetBufferPointervOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLenum pname, GLvoid** params))context->getProcAddress("glGetBufferPointervOES");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_OES_texture_3D::QOpenGLExtension_OES_texture_3D()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_OES_texture_3DPrivate))
+{
+}
+
+bool QOpenGLExtension_OES_texture_3D::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_OES_texture_3D);
+
+ d->TexImage3DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid* pixels))context->getProcAddress("glTexImage3DOES");
+ d->TexSubImage3DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid* pixels))context->getProcAddress("glTexSubImage3DOES");
+ d->CopyTexSubImage3DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height))context->getProcAddress("glCopyTexSubImage3DOES");
+ d->CompressedTexImage3DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data))context->getProcAddress("glCompressedTexImage3DOES");
+ d->CompressedTexSubImage3DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data))context->getProcAddress("glCompressedTexSubImage3DOES");
+ d->FramebufferTexture3DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset))context->getProcAddress("glFramebufferTexture3DOES");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_OES_vertex_array_object::QOpenGLExtension_OES_vertex_array_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_OES_vertex_array_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_OES_vertex_array_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_OES_vertex_array_object);
+
+ d->BindVertexArrayOES = (void (QOPENGLF_APIENTRYP)(GLuint array))context->getProcAddress("glBindVertexArrayOES");
+ d->DeleteVertexArraysOES = (void (QOPENGLF_APIENTRYP)(GLsizei n, const GLuint *arrays))context->getProcAddress("glDeleteVertexArraysOES");
+ d->GenVertexArraysOES = (void (QOPENGLF_APIENTRYP)(GLsizei n, GLuint *arrays))context->getProcAddress("glGenVertexArraysOES");
+ d->IsVertexArrayOES = (GLboolean (QOPENGLF_APIENTRYP)(GLuint array))context->getProcAddress("glIsVertexArrayOES");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_AMD_performance_monitor::QOpenGLExtension_AMD_performance_monitor()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_AMD_performance_monitorPrivate))
+{
+}
+
+bool QOpenGLExtension_AMD_performance_monitor::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+
+ d->GetPerfMonitorGroupsAMD = (void (QOPENGLF_APIENTRYP)(GLint *numGroups, GLsizei groupsSize, GLuint *groups))context->getProcAddress("glGetPerfMonitorGroupsAMD");
+ d->GetPerfMonitorCountersAMD = (void (QOPENGLF_APIENTRYP)(GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters))context->getProcAddress("glGetPerfMonitorCountersAMD");
+ d->GetPerfMonitorGroupStringAMD = (void (QOPENGLF_APIENTRYP)(GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString))context->getProcAddress("glGetPerfMonitorGroupStringAMD");
+ d->GetPerfMonitorCounterStringAMD = (void (QOPENGLF_APIENTRYP)(GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString))context->getProcAddress("glGetPerfMonitorCounterStringAMD");
+ d->GetPerfMonitorCounterInfoAMD = (void (QOPENGLF_APIENTRYP)(GLuint group, GLuint counter, GLenum pname, GLvoid *data))context->getProcAddress("glGetPerfMonitorCounterInfoAMD");
+ d->GenPerfMonitorsAMD = (void (QOPENGLF_APIENTRYP)(GLsizei n, GLuint *monitors))context->getProcAddress("glGenPerfMonitorsAMD");
+ d->DeletePerfMonitorsAMD = (void (QOPENGLF_APIENTRYP)(GLsizei n, GLuint *monitors))context->getProcAddress("glDeletePerfMonitorsAMD");
+ d->SelectPerfMonitorCountersAMD = (void (QOPENGLF_APIENTRYP)(GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *countersList))context->getProcAddress("glSelectPerfMonitorCountersAMD");
+ d->BeginPerfMonitorAMD = (void (QOPENGLF_APIENTRYP)(GLuint monitor))context->getProcAddress("glBeginPerfMonitorAMD");
+ d->EndPerfMonitorAMD = (void (QOPENGLF_APIENTRYP )(GLuint monitor))context->getProcAddress("glEndPerfMonitorAMD");
+ d->GetPerfMonitorCounterDataAMD = (void (QOPENGLF_APIENTRYP)(GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten))context->getProcAddress("glGetPerfMonitorCounterDataAMD");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_ANGLE_framebuffer_blit::QOpenGLExtension_ANGLE_framebuffer_blit()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ANGLE_framebuffer_blitPrivate))
+{
+}
+
+bool QOpenGLExtension_ANGLE_framebuffer_blit::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ANGLE_framebuffer_blit);
+
+ d->BlitFramebufferANGLE = (void (QOPENGLF_APIENTRYP)(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter))context->getProcAddress("glBlitFramebufferANGLE");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_ANGLE_framebuffer_multisample::QOpenGLExtension_ANGLE_framebuffer_multisample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ANGLE_framebuffer_multisamplePrivate))
+{
+}
+
+bool QOpenGLExtension_ANGLE_framebuffer_multisample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ANGLE_framebuffer_multisample);
+
+ d->RenderbufferStorageMultisampleANGLE = (void (QOPENGLF_APIENTRYP)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height))context->getProcAddress("glRenderbufferStorageMultisampleANGLE");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_ANGLE_instanced_arrays::QOpenGLExtension_ANGLE_instanced_arrays()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ANGLE_instanced_arraysPrivate))
+{
+}
+
+bool QOpenGLExtension_ANGLE_instanced_arrays::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ANGLE_instanced_arrays);
+
+ d->DrawArraysInstancedANGLE = (void (QOPENGLF_APIENTRYP)(GLenum mode, GLint first, GLsizei count, GLsizei primcount))context->getProcAddress("glDrawArraysInstancedANGLE");
+ d->DrawElementsInstancedANGLE = (void (QOPENGLF_APIENTRYP)(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount))context->getProcAddress("glDrawElementsInstancedANGLE");
+ d->VertexAttribDivisorANGLE = (void (QOPENGLF_APIENTRYP)(GLuint index, GLuint divisor))context->getProcAddress("glVertexAttribDivisorANGLE");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_ANGLE_translated_shader_source::QOpenGLExtension_ANGLE_translated_shader_source()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ANGLE_translated_shader_sourcePrivate))
+{
+}
+
+bool QOpenGLExtension_ANGLE_translated_shader_source::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ANGLE_translated_shader_source);
+
+ d->GetTranslatedShaderSourceANGLE = (void (QOPENGLF_APIENTRYP)(GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source))context->getProcAddress("glGetTranslatedShaderSourceANGLE");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_APPLE_framebuffer_multisample::QOpenGLExtension_APPLE_framebuffer_multisample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_APPLE_framebuffer_multisamplePrivate))
+{
+}
+
+bool QOpenGLExtension_APPLE_framebuffer_multisample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_APPLE_framebuffer_multisample);
+
+ d->RenderbufferStorageMultisampleAPPLE = (void (QOPENGLF_APIENTRYP)(GLenum, GLsizei, GLenum, GLsizei, GLsizei))context->getProcAddress("glRenderbufferStorageMultisampleAPPLE");
+ d->ResolveMultisampleFramebufferAPPLE = (void (QOPENGLF_APIENTRYP)(void))context->getProcAddress("glResolveMultisampleFramebufferAPPLE");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_debug_label::QOpenGLExtension_EXT_debug_label()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_debug_labelPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_debug_label::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_debug_label);
+
+ d->LabelObjectEXT = (void (QOPENGLF_APIENTRYP)(GLenum type, GLuint object, GLsizei length, const GLchar *label))context->getProcAddress("glLabelObjectEXT");
+ d->GetObjectLabelEXT = (void (QOPENGLF_APIENTRYP)(GLenum type, GLuint object, GLsizei bufSize, GLsizei *length, GLchar *label))context->getProcAddress("glGetObjectLabelEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_debug_marker::QOpenGLExtension_EXT_debug_marker()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_debug_markerPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_debug_marker::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_debug_marker);
+
+ d->InsertEventMarkerEXT = (void (QOPENGLF_APIENTRYP)(GLsizei length, const GLchar *marker))context->getProcAddress("glInsertEventMarkerEXT");
+ d->PushGroupMarkerEXT = (void (QOPENGLF_APIENTRYP)(GLsizei length, const GLchar *marker))context->getProcAddress("glPushGroupMarkerEXT");
+ d->PopGroupMarkerEXT = (void (QOPENGLF_APIENTRYP)(void))context->getProcAddress("glPopGroupMarkerEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_discard_framebuffer::QOpenGLExtension_EXT_discard_framebuffer()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_discard_framebufferPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_discard_framebuffer::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_discard_framebuffer);
+
+ d->DiscardFramebufferEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLsizei numAttachments, const GLenum *attachments))context->getProcAddress("glDiscardFramebufferEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_multisampled_render_to_texture::QOpenGLExtension_EXT_multisampled_render_to_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_multisampled_render_to_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_multisampled_render_to_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_multisampled_render_to_texture);
+
+ d->RenderbufferStorageMultisampleEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height))context->getProcAddress("glRenderbufferStorageMultisampleEXT");
+ d->FramebufferTexture2DMultisampleEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples))context->getProcAddress("glFramebufferTexture2DMultisampleEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_multi_draw_arrays::QOpenGLExtension_EXT_multi_draw_arrays()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_multi_draw_arraysPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_multi_draw_arrays::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_multi_draw_arrays);
+
+ d->MultiDrawArraysEXT = (void (QOPENGLF_APIENTRYP)(GLenum mode, GLint *first, GLsizei *count, GLsizei primcount))context->getProcAddress("glMultiDrawArraysEXT");
+ d->MultiDrawElementsEXT = (void (QOPENGLF_APIENTRYP)(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount))context->getProcAddress("glMultiDrawElementsEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_occlusion_query_boolean::QOpenGLExtension_EXT_occlusion_query_boolean()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_occlusion_query_booleanPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_occlusion_query_boolean::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+
+ d->GenQueriesEXT = (void (QOPENGLF_APIENTRYP)(GLsizei n, GLuint *ids))context->getProcAddress("glGenQueriesEXT");
+ d->DeleteQueriesEXT = (void (QOPENGLF_APIENTRYP)(GLsizei n, const GLuint *ids))context->getProcAddress("glDeleteQueriesEXT");
+ d->IsQueryEXT = (GLboolean (QOPENGLF_APIENTRYP)(GLuint id))context->getProcAddress("glIsQueryEXT");
+ d->BeginQueryEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLuint id))context->getProcAddress("glBeginQueryEXT");
+ d->EndQueryEXT = (void (QOPENGLF_APIENTRYP)(GLenum target))context->getProcAddress("glEndQueryEXT");
+ d->GetQueryivEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLenum pname, GLint *params))context->getProcAddress("glGetQueryivEXT");
+ d->GetQueryObjectuivEXT = (void (QOPENGLF_APIENTRYP)(GLuint id, GLenum pname, GLuint *params))context->getProcAddress("glGetQueryObjectuivEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_robustness::QOpenGLExtension_EXT_robustness()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_robustnessPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_robustness::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_robustness);
+
+ d->GetGraphicsResetStatusEXT = (GLenum (QOPENGLF_APIENTRYP)(void))context->getProcAddress("glGetGraphicsResetStatusEXT");
+ d->ReadnPixelsEXT = (void (QOPENGLF_APIENTRYP)(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data))context->getProcAddress("glReadnPixelsEXT");
+ d->GetnUniformfvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei bufSize, float *params))context->getProcAddress("glGetnUniformfvEXT");
+ d->GetnUniformivEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei bufSize, GLint *params))context->getProcAddress("glGetnUniformivEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_separate_shader_objects::QOpenGLExtension_EXT_separate_shader_objects()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_separate_shader_objectsPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_separate_shader_objects::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+
+ d->UseProgramStagesEXT = (void (QOPENGLF_APIENTRYP)(GLuint pipeline, GLbitfield stages, GLuint program))context->getProcAddress("glUseProgramStagesEXT");
+ d->ActiveShaderProgramEXT = (void (QOPENGLF_APIENTRYP)(GLuint pipeline, GLuint program))context->getProcAddress("glActiveShaderProgramEXT");
+ d->CreateShaderProgramvEXT = (GLuint (QOPENGLF_APIENTRYP)(GLenum type, GLsizei count, const GLchar **strings))context->getProcAddress("glCreateShaderProgramvEXT");
+ d->BindProgramPipelineEXT = (void (QOPENGLF_APIENTRYP)(GLuint pipeline))context->getProcAddress("glBindProgramPipelineEXT");
+ d->DeleteProgramPipelinesEXT = (void (QOPENGLF_APIENTRYP)(GLsizei n, const GLuint *pipelines))context->getProcAddress("glDeleteProgramPipelinesEXT");
+ d->GenProgramPipelinesEXT = (void (QOPENGLF_APIENTRYP)(GLsizei n, GLuint *pipelines))context->getProcAddress("glGenProgramPipelinesEXT");
+ d->IsProgramPipelineEXT = (GLboolean (QOPENGLF_APIENTRYP)(GLuint pipeline))context->getProcAddress("glIsProgramPipelineEXT");
+ d->ProgramParameteriEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLenum pname, GLint value))context->getProcAddress("glProgramParameteriEXT");
+ d->GetProgramPipelineivEXT = (void (QOPENGLF_APIENTRYP)(GLuint pipeline, GLenum pname, GLint *params))context->getProcAddress("glGetProgramPipelineivEXT");
+ d->ProgramUniform1iEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLint x))context->getProcAddress("glProgramUniform1iEXT");
+ d->ProgramUniform2iEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLint x, GLint y))context->getProcAddress("glProgramUniform2iEXT");
+ d->ProgramUniform3iEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLint x, GLint y, GLint z))context->getProcAddress("glProgramUniform3iEXT");
+ d->ProgramUniform4iEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLint x, GLint y, GLint z, GLint w))context->getProcAddress("glProgramUniform4iEXT");
+ d->ProgramUniform1fEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLfloat x))context->getProcAddress("glProgramUniform1fEXT");
+ d->ProgramUniform2fEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLfloat x, GLfloat y))context->getProcAddress("glProgramUniform2fEXT");
+ d->ProgramUniform3fEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z))context->getProcAddress("glProgramUniform3fEXT");
+ d->ProgramUniform4fEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w))context->getProcAddress("glProgramUniform4fEXT");
+ d->ProgramUniform1ivEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLint *value))context->getProcAddress("glProgramUniform1ivEXT");
+ d->ProgramUniform2ivEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLint *value))context->getProcAddress("glProgramUniform2ivEXT");
+ d->ProgramUniform3ivEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLint *value))context->getProcAddress("glProgramUniform3ivEXT");
+ d->ProgramUniform4ivEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLint *value))context->getProcAddress("glProgramUniform4ivEXT");
+ d->ProgramUniform1fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLfloat *value))context->getProcAddress("glProgramUniform1fvEXT");
+ d->ProgramUniform2fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLfloat *value))context->getProcAddress("glProgramUniform2fvEXT");
+ d->ProgramUniform3fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLfloat *value))context->getProcAddress("glProgramUniform3fvEXT");
+ d->ProgramUniform4fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLfloat *value))context->getProcAddress("glProgramUniform4fvEXT");
+ d->ProgramUniformMatrix2fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value))context->getProcAddress("glProgramUniformMatrix2fvEXT");
+ d->ProgramUniformMatrix3fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value))context->getProcAddress("glProgramUniformMatrix3fvEXT");
+ d->ProgramUniformMatrix4fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value))context->getProcAddress("glProgramUniformMatrix4fvEXT");
+ d->ValidateProgramPipelineEXT = (void (QOPENGLF_APIENTRYP)(GLuint pipeline))context->getProcAddress("glValidateProgramPipelineEXT");
+ d->GetProgramPipelineInfoLogEXT = (void (QOPENGLF_APIENTRYP)(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog))context->getProcAddress("glGetProgramPipelineInfoLogEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_texture_storage::QOpenGLExtension_EXT_texture_storage()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_texture_storagePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_texture_storage::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+
+ d->TexStorage1DEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width))context->getProcAddress("glTexStorage1DEXT");
+ d->TexStorage2DEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height))context->getProcAddress("glTexStorage2DEXT");
+ d->TexStorage3DEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth))context->getProcAddress("glTexStorage3DEXT");
+ d->TextureStorage1DEXT = (void (QOPENGLF_APIENTRYP)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width))context->getProcAddress("glTextureStorage1DEXT");
+ d->TextureStorage2DEXT = (void (QOPENGLF_APIENTRYP)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height))context->getProcAddress("glTextureStorage2DEXT");
+ d->TextureStorage3DEXT = (void (QOPENGLF_APIENTRYP)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth))context->getProcAddress("glTextureStorage3DEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_IMG_multisampled_render_to_texture::QOpenGLExtension_IMG_multisampled_render_to_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_IMG_multisampled_render_to_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_IMG_multisampled_render_to_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_IMG_multisampled_render_to_texture);
+
+ d->RenderbufferStorageMultisampleIMG = (void (QOPENGLF_APIENTRYP)(GLenum, GLsizei, GLenum, GLsizei, GLsizei))context->getProcAddress("glRenderbufferStorageMultisampleIMG");
+ d->FramebufferTexture2DMultisampleIMG = (void (QOPENGLF_APIENTRYP)(GLenum, GLenum, GLenum, GLuint, GLint, GLsizei))context->getProcAddress("glFramebufferTexture2DMultisampleIMG");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_NV_coverage_sample::QOpenGLExtension_NV_coverage_sample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_coverage_samplePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_coverage_sample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_coverage_sample);
+
+ d->CoverageMaskNV = (void (QOPENGLF_APIENTRYP)(GLboolean mask))context->getProcAddress("glCoverageMaskNV");
+ d->CoverageOperationNV = (void (QOPENGLF_APIENTRYP)(GLenum operation))context->getProcAddress("glCoverageOperationNV");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_NV_draw_buffers::QOpenGLExtension_NV_draw_buffers()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_draw_buffersPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_draw_buffers::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_draw_buffers);
+
+ d->DrawBuffersNV = (void (QOPENGLF_APIENTRYP)(GLsizei n, const GLenum *bufs))context->getProcAddress("glDrawBuffersNV");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_NV_fence::QOpenGLExtension_NV_fence()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_fencePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_fence::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_fence);
+
+ d->DeleteFencesNV = (void (QOPENGLF_APIENTRYP)(GLsizei n, const GLuint *fences))context->getProcAddress("glDeleteFencesNV");
+ d->GenFencesNV = (void (QOPENGLF_APIENTRYP)(GLsizei n, GLuint *fences))context->getProcAddress("glGenFencesNV");
+ d->IsFenceNV = (GLboolean (QOPENGLF_APIENTRYP)(GLuint fence))context->getProcAddress("glIsFenceNV");
+ d->TestFenceNV = (GLboolean (QOPENGLF_APIENTRYP)(GLuint fence))context->getProcAddress("glTestFenceNV");
+ d->GetFenceivNV = (void (QOPENGLF_APIENTRYP)(GLuint fence, GLenum pname, GLint *params))context->getProcAddress("glGetFenceivNV");
+ d->FinishFenceNV = (void (QOPENGLF_APIENTRYP)(GLuint fence))context->getProcAddress("glFinishFenceNV");
+ d->SetFenceNV = (void (QOPENGLF_APIENTRYP)(GLuint fence, GLenum condition))context->getProcAddress("glSetFenceNV");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_NV_read_buffer::QOpenGLExtension_NV_read_buffer()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_read_bufferPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_read_buffer::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_read_buffer);
+
+ d->ReadBufferNV = (void (QOPENGLF_APIENTRYP)(GLenum mode))context->getProcAddress("glReadBufferNV");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_QCOM_alpha_test::QOpenGLExtension_QCOM_alpha_test()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_QCOM_alpha_testPrivate))
+{
+}
+
+bool QOpenGLExtension_QCOM_alpha_test::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_QCOM_alpha_test);
+
+ d->AlphaFuncQCOM = (void (QOPENGLF_APIENTRYP )(GLenum func, GLclampf ref))context->getProcAddress("glAlphaFuncQCOM");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_QCOM_driver_control::QOpenGLExtension_QCOM_driver_control()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_QCOM_driver_controlPrivate))
+{
+}
+
+bool QOpenGLExtension_QCOM_driver_control::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_QCOM_driver_control);
+
+ d->GetDriverControlsQCOM = (void (QOPENGLF_APIENTRYP)(GLint *num, GLsizei size, GLuint *driverControls))context->getProcAddress("glGetDriverControlsQCOM");
+ d->GetDriverControlStringQCOM = (void (QOPENGLF_APIENTRYP)(GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString))context->getProcAddress("glGetDriverControlStringQCOM");
+ d->EnableDriverControlQCOM = (void (QOPENGLF_APIENTRYP)(GLuint driverControl))context->getProcAddress("glEnableDriverControlQCOM");
+ d->DisableDriverControlQCOM = (void (QOPENGLF_APIENTRYP)(GLuint driverControl))context->getProcAddress("glDisableDriverControlQCOM");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_QCOM_extended_get::QOpenGLExtension_QCOM_extended_get()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_QCOM_extended_getPrivate))
+{
+}
+
+bool QOpenGLExtension_QCOM_extended_get::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+
+ d->ExtGetTexturesQCOM = (void (QOPENGLF_APIENTRYP)(GLuint *textures, GLint maxTextures, GLint *numTextures))context->getProcAddress("glExtGetTexturesQCOM");
+ d->ExtGetBuffersQCOM = (void (QOPENGLF_APIENTRYP)(GLuint *buffers, GLint maxBuffers, GLint *numBuffers))context->getProcAddress("glExtGetBuffersQCOM");
+ d->ExtGetRenderbuffersQCOM = (void (QOPENGLF_APIENTRYP)(GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers))context->getProcAddress("glExtGetRenderbuffersQCOM");
+ d->ExtGetFramebuffersQCOM = (void (QOPENGLF_APIENTRYP)(GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers))context->getProcAddress("glExtGetFramebuffersQCOM");
+ d->ExtGetTexLevelParameterivQCOM = (void (QOPENGLF_APIENTRYP)(GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params))context->getProcAddress("glExtGetTexLevelParameterivQCOM");
+ d->ExtTexObjectStateOverrideiQCOM = (void (QOPENGLF_APIENTRYP)(GLenum target, GLenum pname, GLint param))context->getProcAddress("glExtTexObjectStateOverrideiQCOM");
+ d->ExtGetTexSubImageQCOM = (void (QOPENGLF_APIENTRYP)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLvoid *texels))context->getProcAddress("glExtGetTexSubImageQCOM");
+ d->ExtGetBufferPointervQCOM = (void (QOPENGLF_APIENTRYP)(GLenum target, GLvoid **params))context->getProcAddress("glExtGetBufferPointervQCOM");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_QCOM_extended_get2::QOpenGLExtension_QCOM_extended_get2()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_QCOM_extended_get2Private))
+{
+}
+
+bool QOpenGLExtension_QCOM_extended_get2::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_QCOM_extended_get2);
+
+ d->ExtGetShadersQCOM = (void (QOPENGLF_APIENTRYP)(GLuint *shaders, GLint maxShaders, GLint *numShaders))context->getProcAddress("glExtGetShadersQCOM");
+ d->ExtGetProgramsQCOM = (void (QOPENGLF_APIENTRYP)(GLuint *programs, GLint maxPrograms, GLint *numPrograms))context->getProcAddress("glExtGetProgramsQCOM");
+ d->ExtIsProgramBinaryQCOM = (GLboolean (QOPENGLF_APIENTRYP)(GLuint program))context->getProcAddress("glExtIsProgramBinaryQCOM");
+ d->ExtGetProgramBinarySourceQCOM = (void (QOPENGLF_APIENTRYP)(GLuint program, GLenum shadertype, GLchar *source, GLint *length))context->getProcAddress("glExtGetProgramBinarySourceQCOM");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_QCOM_tiled_rendering::QOpenGLExtension_QCOM_tiled_rendering()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_QCOM_tiled_renderingPrivate))
+{
+}
+
+bool QOpenGLExtension_QCOM_tiled_rendering::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_QCOM_tiled_rendering);
+
+ d->StartTilingQCOM = (void (QOPENGLF_APIENTRYP)(GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask))context->getProcAddress("glStartTilingQCOM");
+ d->EndTilingQCOM = (void (QOPENGLF_APIENTRYP)(GLbitfield preserveMask))context->getProcAddress("glEndTilingQCOM");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+#endif
+
+QT_END_NAMESPACE
+
diff --git a/src/openglextensions/qopenglextensions.h b/src/openglextensions/qopenglextensions.h
new file mode 100644
index 0000000000..7d6c21e4e5
--- /dev/null
+++ b/src/openglextensions/qopenglextensions.h
@@ -0,0 +1,19469 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLEXTENSIONS_H
+#define QOPENGLEXTENSIONS_H
+
+#include <QtCore/qglobal.h>
+
+#ifndef QT_NO_OPENGL
+
+#include <QtGui/qopengl.h>
+
+class QOpenGLContext;
+
+QT_BEGIN_NAMESPACE
+
+#if 0
+// silence syncqt warnings
+#pragma qt_class(QOpenGLExtensions)
+#pragma qt_sync_stop_processing
+#endif
+
+
+class QAbstractOpenGLExtensionPrivate
+{
+public:
+ QAbstractOpenGLExtensionPrivate() : initialized(false) {}
+ bool initialized;
+};
+
+class QAbstractOpenGLExtension
+{
+public:
+ virtual ~QAbstractOpenGLExtension();
+
+ virtual bool initializeOpenGLFunctions();
+
+ Q_DECLARE_PRIVATE(QAbstractOpenGLExtension)
+
+protected:
+ bool isInitialized() const;
+
+ QAbstractOpenGLExtension() {}
+ QAbstractOpenGLExtension(QAbstractOpenGLExtensionPrivate &dd) : d_ptr(&dd) {}
+ QAbstractOpenGLExtensionPrivate *d_ptr;
+};
+
+#if !defined(QT_OPENGL_ES_2)
+
+class QOpenGLExtension_3DFX_tbufferPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TbufferMask3DFX)(GLuint mask);
+};
+
+class QOpenGLExtension_3DFX_tbuffer : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_3DFX_tbuffer();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTbufferMask3DFX(GLuint mask);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_3DFX_tbuffer)
+};
+
+inline void QOpenGLExtension_3DFX_tbuffer::glTbufferMask3DFX(GLuint mask)
+{
+ Q_D(QOpenGLExtension_3DFX_tbuffer);
+ d->TbufferMask3DFX(mask);
+}
+
+class QOpenGLExtension_AMD_debug_outputPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLuint (QOPENGLF_APIENTRYP GetDebugMessageLogAMD)(GLuint count, GLsizei bufsize, GLenum *categories, GLuint *severities, GLuint *ids, GLsizei *lengths, GLchar *message);
+ void (QOPENGLF_APIENTRYP DebugMessageCallbackAMD)(GLDEBUGPROCAMD callback, GLvoid *userParam);
+ void (QOPENGLF_APIENTRYP DebugMessageInsertAMD)(GLenum category, GLenum severity, GLuint id, GLsizei length, const GLchar *buf);
+ void (QOPENGLF_APIENTRYP DebugMessageEnableAMD)(GLenum category, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
+};
+
+class QOpenGLExtension_AMD_debug_output : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_AMD_debug_output();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLuint glGetDebugMessageLogAMD(GLuint count, GLsizei bufsize, GLenum *categories, GLuint *severities, GLuint *ids, GLsizei *lengths, GLchar *message);
+ void glDebugMessageCallbackAMD(GLDEBUGPROCAMD callback, GLvoid *userParam);
+ void glDebugMessageInsertAMD(GLenum category, GLenum severity, GLuint id, GLsizei length, const GLchar *buf);
+ void glDebugMessageEnableAMD(GLenum category, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_AMD_debug_output)
+};
+
+inline GLuint QOpenGLExtension_AMD_debug_output::glGetDebugMessageLogAMD(GLuint count, GLsizei bufsize, GLenum *categories, GLuint *severities, GLuint *ids, GLsizei *lengths, GLchar *message)
+{
+ Q_D(QOpenGLExtension_AMD_debug_output);
+ return d->GetDebugMessageLogAMD(count, bufsize, categories, severities, ids, lengths, message);
+}
+
+inline void QOpenGLExtension_AMD_debug_output::glDebugMessageCallbackAMD(GLDEBUGPROCAMD callback, GLvoid *userParam)
+{
+ Q_D(QOpenGLExtension_AMD_debug_output);
+ d->DebugMessageCallbackAMD(callback, userParam);
+}
+
+inline void QOpenGLExtension_AMD_debug_output::glDebugMessageInsertAMD(GLenum category, GLenum severity, GLuint id, GLsizei length, const GLchar *buf)
+{
+ Q_D(QOpenGLExtension_AMD_debug_output);
+ d->DebugMessageInsertAMD(category, severity, id, length, buf);
+}
+
+inline void QOpenGLExtension_AMD_debug_output::glDebugMessageEnableAMD(GLenum category, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled)
+{
+ Q_D(QOpenGLExtension_AMD_debug_output);
+ d->DebugMessageEnableAMD(category, severity, count, ids, enabled);
+}
+
+class QOpenGLExtension_AMD_draw_buffers_blendPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BlendEquationSeparateIndexedAMD)(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void (QOPENGLF_APIENTRYP BlendEquationIndexedAMD)(GLuint buf, GLenum mode);
+ void (QOPENGLF_APIENTRYP BlendFuncSeparateIndexedAMD)(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void (QOPENGLF_APIENTRYP BlendFuncIndexedAMD)(GLuint buf, GLenum src, GLenum dst);
+};
+
+class QOpenGLExtension_AMD_draw_buffers_blend : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_AMD_draw_buffers_blend();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBlendEquationSeparateIndexedAMD(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void glBlendEquationIndexedAMD(GLuint buf, GLenum mode);
+ void glBlendFuncSeparateIndexedAMD(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void glBlendFuncIndexedAMD(GLuint buf, GLenum src, GLenum dst);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_AMD_draw_buffers_blend)
+};
+
+inline void QOpenGLExtension_AMD_draw_buffers_blend::glBlendEquationSeparateIndexedAMD(GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ Q_D(QOpenGLExtension_AMD_draw_buffers_blend);
+ d->BlendEquationSeparateIndexedAMD(buf, modeRGB, modeAlpha);
+}
+
+inline void QOpenGLExtension_AMD_draw_buffers_blend::glBlendEquationIndexedAMD(GLuint buf, GLenum mode)
+{
+ Q_D(QOpenGLExtension_AMD_draw_buffers_blend);
+ d->BlendEquationIndexedAMD(buf, mode);
+}
+
+inline void QOpenGLExtension_AMD_draw_buffers_blend::glBlendFuncSeparateIndexedAMD(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ Q_D(QOpenGLExtension_AMD_draw_buffers_blend);
+ d->BlendFuncSeparateIndexedAMD(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+inline void QOpenGLExtension_AMD_draw_buffers_blend::glBlendFuncIndexedAMD(GLuint buf, GLenum src, GLenum dst)
+{
+ Q_D(QOpenGLExtension_AMD_draw_buffers_blend);
+ d->BlendFuncIndexedAMD(buf, src, dst);
+}
+
+class QOpenGLExtension_AMD_multi_draw_indirectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MultiDrawElementsIndirectAMD)(GLenum mode, GLenum type, const GLvoid *indirect, GLsizei primcount, GLsizei stride);
+ void (QOPENGLF_APIENTRYP MultiDrawArraysIndirectAMD)(GLenum mode, const GLvoid *indirect, GLsizei primcount, GLsizei stride);
+};
+
+class QOpenGLExtension_AMD_multi_draw_indirect : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_AMD_multi_draw_indirect();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMultiDrawElementsIndirectAMD(GLenum mode, GLenum type, const GLvoid *indirect, GLsizei primcount, GLsizei stride);
+ void glMultiDrawArraysIndirectAMD(GLenum mode, const GLvoid *indirect, GLsizei primcount, GLsizei stride);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_AMD_multi_draw_indirect)
+};
+
+inline void QOpenGLExtension_AMD_multi_draw_indirect::glMultiDrawElementsIndirectAMD(GLenum mode, GLenum type, const GLvoid *indirect, GLsizei primcount, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_AMD_multi_draw_indirect);
+ d->MultiDrawElementsIndirectAMD(mode, type, indirect, primcount, stride);
+}
+
+inline void QOpenGLExtension_AMD_multi_draw_indirect::glMultiDrawArraysIndirectAMD(GLenum mode, const GLvoid *indirect, GLsizei primcount, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_AMD_multi_draw_indirect);
+ d->MultiDrawArraysIndirectAMD(mode, indirect, primcount, stride);
+}
+
+class QOpenGLExtension_AMD_name_gen_deletePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLboolean (QOPENGLF_APIENTRYP IsNameAMD)(GLenum identifier, GLuint name);
+ void (QOPENGLF_APIENTRYP DeleteNamesAMD)(GLenum identifier, GLuint num, const GLuint *names);
+ void (QOPENGLF_APIENTRYP GenNamesAMD)(GLenum identifier, GLuint num, GLuint *names);
+};
+
+class QOpenGLExtension_AMD_name_gen_delete : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_AMD_name_gen_delete();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLboolean glIsNameAMD(GLenum identifier, GLuint name);
+ void glDeleteNamesAMD(GLenum identifier, GLuint num, const GLuint *names);
+ void glGenNamesAMD(GLenum identifier, GLuint num, GLuint *names);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_AMD_name_gen_delete)
+};
+
+inline GLboolean QOpenGLExtension_AMD_name_gen_delete::glIsNameAMD(GLenum identifier, GLuint name)
+{
+ Q_D(QOpenGLExtension_AMD_name_gen_delete);
+ return d->IsNameAMD(identifier, name);
+}
+
+inline void QOpenGLExtension_AMD_name_gen_delete::glDeleteNamesAMD(GLenum identifier, GLuint num, const GLuint *names)
+{
+ Q_D(QOpenGLExtension_AMD_name_gen_delete);
+ d->DeleteNamesAMD(identifier, num, names);
+}
+
+inline void QOpenGLExtension_AMD_name_gen_delete::glGenNamesAMD(GLenum identifier, GLuint num, GLuint *names)
+{
+ Q_D(QOpenGLExtension_AMD_name_gen_delete);
+ d->GenNamesAMD(identifier, num, names);
+}
+
+class QOpenGLExtension_AMD_performance_monitorPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetPerfMonitorCounterDataAMD)(GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten);
+ void (QOPENGLF_APIENTRYP EndPerfMonitorAMD)(GLuint monitor);
+ void (QOPENGLF_APIENTRYP BeginPerfMonitorAMD)(GLuint monitor);
+ void (QOPENGLF_APIENTRYP SelectPerfMonitorCountersAMD)(GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *counterList);
+ void (QOPENGLF_APIENTRYP DeletePerfMonitorsAMD)(GLsizei n, GLuint *monitors);
+ void (QOPENGLF_APIENTRYP GenPerfMonitorsAMD)(GLsizei n, GLuint *monitors);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorCounterInfoAMD)(GLuint group, GLuint counter, GLenum pname, GLvoid *data);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorCounterStringAMD)(GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorGroupStringAMD)(GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorCountersAMD)(GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorGroupsAMD)(GLint *numGroups, GLsizei groupsSize, GLuint *groups);
+};
+
+class QOpenGLExtension_AMD_performance_monitor : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_AMD_performance_monitor();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetPerfMonitorCounterDataAMD(GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten);
+ void glEndPerfMonitorAMD(GLuint monitor);
+ void glBeginPerfMonitorAMD(GLuint monitor);
+ void glSelectPerfMonitorCountersAMD(GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *counterList);
+ void glDeletePerfMonitorsAMD(GLsizei n, GLuint *monitors);
+ void glGenPerfMonitorsAMD(GLsizei n, GLuint *monitors);
+ void glGetPerfMonitorCounterInfoAMD(GLuint group, GLuint counter, GLenum pname, GLvoid *data);
+ void glGetPerfMonitorCounterStringAMD(GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString);
+ void glGetPerfMonitorGroupStringAMD(GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString);
+ void glGetPerfMonitorCountersAMD(GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters);
+ void glGetPerfMonitorGroupsAMD(GLint *numGroups, GLsizei groupsSize, GLuint *groups);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_AMD_performance_monitor)
+};
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorCounterDataAMD(GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorCounterDataAMD(monitor, pname, dataSize, data, bytesWritten);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glEndPerfMonitorAMD(GLuint monitor)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->EndPerfMonitorAMD(monitor);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glBeginPerfMonitorAMD(GLuint monitor)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->BeginPerfMonitorAMD(monitor);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glSelectPerfMonitorCountersAMD(GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *counterList)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->SelectPerfMonitorCountersAMD(monitor, enable, group, numCounters, counterList);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glDeletePerfMonitorsAMD(GLsizei n, GLuint *monitors)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->DeletePerfMonitorsAMD(n, monitors);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGenPerfMonitorsAMD(GLsizei n, GLuint *monitors)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GenPerfMonitorsAMD(n, monitors);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorCounterInfoAMD(GLuint group, GLuint counter, GLenum pname, GLvoid *data)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorCounterInfoAMD(group, counter, pname, data);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorCounterStringAMD(GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorCounterStringAMD(group, counter, bufSize, length, counterString);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorGroupStringAMD(GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorGroupStringAMD(group, bufSize, length, groupString);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorCountersAMD(GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorCountersAMD(group, numCounters, maxActiveCounters, counterSize, counters);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorGroupsAMD(GLint *numGroups, GLsizei groupsSize, GLuint *groups)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorGroupsAMD(numGroups, groupsSize, groups);
+}
+
+class QOpenGLExtension_AMD_sample_positionsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP SetMultisamplefvAMD)(GLenum pname, GLuint index, const GLfloat *val);
+};
+
+class QOpenGLExtension_AMD_sample_positions : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_AMD_sample_positions();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glSetMultisamplefvAMD(GLenum pname, GLuint index, const GLfloat *val);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_AMD_sample_positions)
+};
+
+inline void QOpenGLExtension_AMD_sample_positions::glSetMultisamplefvAMD(GLenum pname, GLuint index, const GLfloat *val)
+{
+ Q_D(QOpenGLExtension_AMD_sample_positions);
+ d->SetMultisamplefvAMD(pname, index, val);
+}
+
+class QOpenGLExtension_AMD_sparse_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexStorageSparseAMD)(GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLsizei layers, GLbitfield flags);
+};
+
+class QOpenGLExtension_AMD_sparse_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_AMD_sparse_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexStorageSparseAMD(GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLsizei layers, GLbitfield flags);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_AMD_sparse_texture)
+};
+
+inline void QOpenGLExtension_AMD_sparse_texture::glTexStorageSparseAMD(GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLsizei layers, GLbitfield flags)
+{
+ Q_D(QOpenGLExtension_AMD_sparse_texture);
+ d->TexStorageSparseAMD(target, internalFormat, width, height, depth, layers, flags);
+}
+
+class QOpenGLExtension_AMD_stencil_operation_extendedPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP StencilOpValueAMD)(GLenum face, GLuint value);
+};
+
+class QOpenGLExtension_AMD_stencil_operation_extended : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_AMD_stencil_operation_extended();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glStencilOpValueAMD(GLenum face, GLuint value);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_AMD_stencil_operation_extended)
+};
+
+inline void QOpenGLExtension_AMD_stencil_operation_extended::glStencilOpValueAMD(GLenum face, GLuint value)
+{
+ Q_D(QOpenGLExtension_AMD_stencil_operation_extended);
+ d->StencilOpValueAMD(face, value);
+}
+
+class QOpenGLExtension_AMD_vertex_shader_tesselatorPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TessellationModeAMD)(GLenum mode);
+ void (QOPENGLF_APIENTRYP TessellationFactorAMD)(GLfloat factor);
+};
+
+class QOpenGLExtension_AMD_vertex_shader_tesselator : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_AMD_vertex_shader_tesselator();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTessellationModeAMD(GLenum mode);
+ void glTessellationFactorAMD(GLfloat factor);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_AMD_vertex_shader_tesselator)
+};
+
+inline void QOpenGLExtension_AMD_vertex_shader_tesselator::glTessellationModeAMD(GLenum mode)
+{
+ Q_D(QOpenGLExtension_AMD_vertex_shader_tesselator);
+ d->TessellationModeAMD(mode);
+}
+
+inline void QOpenGLExtension_AMD_vertex_shader_tesselator::glTessellationFactorAMD(GLfloat factor)
+{
+ Q_D(QOpenGLExtension_AMD_vertex_shader_tesselator);
+ d->TessellationFactorAMD(factor);
+}
+
+class QOpenGLExtension_APPLE_element_arrayPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MultiDrawRangeElementArrayAPPLE)(GLenum mode, GLuint start, GLuint end, const GLint *first, const GLsizei *count, GLsizei primcount);
+ void (QOPENGLF_APIENTRYP MultiDrawElementArrayAPPLE)(GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount);
+ void (QOPENGLF_APIENTRYP DrawRangeElementArrayAPPLE)(GLenum mode, GLuint start, GLuint end, GLint first, GLsizei count);
+ void (QOPENGLF_APIENTRYP DrawElementArrayAPPLE)(GLenum mode, GLint first, GLsizei count);
+ void (QOPENGLF_APIENTRYP ElementPointerAPPLE)(GLenum type, const GLvoid *pointer);
+};
+
+class QOpenGLExtension_APPLE_element_array : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_APPLE_element_array();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMultiDrawRangeElementArrayAPPLE(GLenum mode, GLuint start, GLuint end, const GLint *first, const GLsizei *count, GLsizei primcount);
+ void glMultiDrawElementArrayAPPLE(GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount);
+ void glDrawRangeElementArrayAPPLE(GLenum mode, GLuint start, GLuint end, GLint first, GLsizei count);
+ void glDrawElementArrayAPPLE(GLenum mode, GLint first, GLsizei count);
+ void glElementPointerAPPLE(GLenum type, const GLvoid *pointer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_APPLE_element_array)
+};
+
+inline void QOpenGLExtension_APPLE_element_array::glMultiDrawRangeElementArrayAPPLE(GLenum mode, GLuint start, GLuint end, const GLint *first, const GLsizei *count, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_APPLE_element_array);
+ d->MultiDrawRangeElementArrayAPPLE(mode, start, end, first, count, primcount);
+}
+
+inline void QOpenGLExtension_APPLE_element_array::glMultiDrawElementArrayAPPLE(GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_APPLE_element_array);
+ d->MultiDrawElementArrayAPPLE(mode, first, count, primcount);
+}
+
+inline void QOpenGLExtension_APPLE_element_array::glDrawRangeElementArrayAPPLE(GLenum mode, GLuint start, GLuint end, GLint first, GLsizei count)
+{
+ Q_D(QOpenGLExtension_APPLE_element_array);
+ d->DrawRangeElementArrayAPPLE(mode, start, end, first, count);
+}
+
+inline void QOpenGLExtension_APPLE_element_array::glDrawElementArrayAPPLE(GLenum mode, GLint first, GLsizei count)
+{
+ Q_D(QOpenGLExtension_APPLE_element_array);
+ d->DrawElementArrayAPPLE(mode, first, count);
+}
+
+inline void QOpenGLExtension_APPLE_element_array::glElementPointerAPPLE(GLenum type, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_APPLE_element_array);
+ d->ElementPointerAPPLE(type, pointer);
+}
+
+class QOpenGLExtension_APPLE_fencePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP FinishObjectAPPLE)(GLenum object, GLint name);
+ GLboolean (QOPENGLF_APIENTRYP TestObjectAPPLE)(GLenum object, GLuint name);
+ void (QOPENGLF_APIENTRYP FinishFenceAPPLE)(GLuint fence);
+ GLboolean (QOPENGLF_APIENTRYP TestFenceAPPLE)(GLuint fence);
+ GLboolean (QOPENGLF_APIENTRYP IsFenceAPPLE)(GLuint fence);
+ void (QOPENGLF_APIENTRYP SetFenceAPPLE)(GLuint fence);
+ void (QOPENGLF_APIENTRYP DeleteFencesAPPLE)(GLsizei n, const GLuint *fences);
+ void (QOPENGLF_APIENTRYP GenFencesAPPLE)(GLsizei n, GLuint *fences);
+};
+
+class QOpenGLExtension_APPLE_fence : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_APPLE_fence();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glFinishObjectAPPLE(GLenum object, GLint name);
+ GLboolean glTestObjectAPPLE(GLenum object, GLuint name);
+ void glFinishFenceAPPLE(GLuint fence);
+ GLboolean glTestFenceAPPLE(GLuint fence);
+ GLboolean glIsFenceAPPLE(GLuint fence);
+ void glSetFenceAPPLE(GLuint fence);
+ void glDeleteFencesAPPLE(GLsizei n, const GLuint *fences);
+ void glGenFencesAPPLE(GLsizei n, GLuint *fences);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_APPLE_fence)
+};
+
+inline void QOpenGLExtension_APPLE_fence::glFinishObjectAPPLE(GLenum object, GLint name)
+{
+ Q_D(QOpenGLExtension_APPLE_fence);
+ d->FinishObjectAPPLE(object, name);
+}
+
+inline GLboolean QOpenGLExtension_APPLE_fence::glTestObjectAPPLE(GLenum object, GLuint name)
+{
+ Q_D(QOpenGLExtension_APPLE_fence);
+ return d->TestObjectAPPLE(object, name);
+}
+
+inline void QOpenGLExtension_APPLE_fence::glFinishFenceAPPLE(GLuint fence)
+{
+ Q_D(QOpenGLExtension_APPLE_fence);
+ d->FinishFenceAPPLE(fence);
+}
+
+inline GLboolean QOpenGLExtension_APPLE_fence::glTestFenceAPPLE(GLuint fence)
+{
+ Q_D(QOpenGLExtension_APPLE_fence);
+ return d->TestFenceAPPLE(fence);
+}
+
+inline GLboolean QOpenGLExtension_APPLE_fence::glIsFenceAPPLE(GLuint fence)
+{
+ Q_D(QOpenGLExtension_APPLE_fence);
+ return d->IsFenceAPPLE(fence);
+}
+
+inline void QOpenGLExtension_APPLE_fence::glSetFenceAPPLE(GLuint fence)
+{
+ Q_D(QOpenGLExtension_APPLE_fence);
+ d->SetFenceAPPLE(fence);
+}
+
+inline void QOpenGLExtension_APPLE_fence::glDeleteFencesAPPLE(GLsizei n, const GLuint *fences)
+{
+ Q_D(QOpenGLExtension_APPLE_fence);
+ d->DeleteFencesAPPLE(n, fences);
+}
+
+inline void QOpenGLExtension_APPLE_fence::glGenFencesAPPLE(GLsizei n, GLuint *fences)
+{
+ Q_D(QOpenGLExtension_APPLE_fence);
+ d->GenFencesAPPLE(n, fences);
+}
+
+class QOpenGLExtension_APPLE_flush_buffer_rangePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP FlushMappedBufferRangeAPPLE)(GLenum target, GLintptr offset, GLsizeiptr size);
+ void (QOPENGLF_APIENTRYP BufferParameteriAPPLE)(GLenum target, GLenum pname, GLint param);
+};
+
+class QOpenGLExtension_APPLE_flush_buffer_range : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_APPLE_flush_buffer_range();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glFlushMappedBufferRangeAPPLE(GLenum target, GLintptr offset, GLsizeiptr size);
+ void glBufferParameteriAPPLE(GLenum target, GLenum pname, GLint param);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_APPLE_flush_buffer_range)
+};
+
+inline void QOpenGLExtension_APPLE_flush_buffer_range::glFlushMappedBufferRangeAPPLE(GLenum target, GLintptr offset, GLsizeiptr size)
+{
+ Q_D(QOpenGLExtension_APPLE_flush_buffer_range);
+ d->FlushMappedBufferRangeAPPLE(target, offset, size);
+}
+
+inline void QOpenGLExtension_APPLE_flush_buffer_range::glBufferParameteriAPPLE(GLenum target, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_APPLE_flush_buffer_range);
+ d->BufferParameteriAPPLE(target, pname, param);
+}
+
+class QOpenGLExtension_APPLE_object_purgeablePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetObjectParameterivAPPLE)(GLenum objectType, GLuint name, GLenum pname, GLint *params);
+ GLenum (QOPENGLF_APIENTRYP ObjectUnpurgeableAPPLE)(GLenum objectType, GLuint name, GLenum option);
+ GLenum (QOPENGLF_APIENTRYP ObjectPurgeableAPPLE)(GLenum objectType, GLuint name, GLenum option);
+};
+
+class QOpenGLExtension_APPLE_object_purgeable : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_APPLE_object_purgeable();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetObjectParameterivAPPLE(GLenum objectType, GLuint name, GLenum pname, GLint *params);
+ GLenum glObjectUnpurgeableAPPLE(GLenum objectType, GLuint name, GLenum option);
+ GLenum glObjectPurgeableAPPLE(GLenum objectType, GLuint name, GLenum option);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_APPLE_object_purgeable)
+};
+
+inline void QOpenGLExtension_APPLE_object_purgeable::glGetObjectParameterivAPPLE(GLenum objectType, GLuint name, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_APPLE_object_purgeable);
+ d->GetObjectParameterivAPPLE(objectType, name, pname, params);
+}
+
+inline GLenum QOpenGLExtension_APPLE_object_purgeable::glObjectUnpurgeableAPPLE(GLenum objectType, GLuint name, GLenum option)
+{
+ Q_D(QOpenGLExtension_APPLE_object_purgeable);
+ return d->ObjectUnpurgeableAPPLE(objectType, name, option);
+}
+
+inline GLenum QOpenGLExtension_APPLE_object_purgeable::glObjectPurgeableAPPLE(GLenum objectType, GLuint name, GLenum option)
+{
+ Q_D(QOpenGLExtension_APPLE_object_purgeable);
+ return d->ObjectPurgeableAPPLE(objectType, name, option);
+}
+
+class QOpenGLExtension_APPLE_texture_rangePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetTexParameterPointervAPPLE)(GLenum target, GLenum pname, GLvoid* *params);
+ void (QOPENGLF_APIENTRYP TextureRangeAPPLE)(GLenum target, GLsizei length, const GLvoid *pointer);
+};
+
+class QOpenGLExtension_APPLE_texture_range : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_APPLE_texture_range();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetTexParameterPointervAPPLE(GLenum target, GLenum pname, GLvoid* *params);
+ void glTextureRangeAPPLE(GLenum target, GLsizei length, const GLvoid *pointer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_APPLE_texture_range)
+};
+
+inline void QOpenGLExtension_APPLE_texture_range::glGetTexParameterPointervAPPLE(GLenum target, GLenum pname, GLvoid* *params)
+{
+ Q_D(QOpenGLExtension_APPLE_texture_range);
+ d->GetTexParameterPointervAPPLE(target, pname, params);
+}
+
+inline void QOpenGLExtension_APPLE_texture_range::glTextureRangeAPPLE(GLenum target, GLsizei length, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_APPLE_texture_range);
+ d->TextureRangeAPPLE(target, length, pointer);
+}
+
+class QOpenGLExtension_APPLE_vertex_array_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLboolean (QOPENGLF_APIENTRYP IsVertexArrayAPPLE)(GLuint array);
+ void (QOPENGLF_APIENTRYP GenVertexArraysAPPLE)(GLsizei n, GLuint *arrays);
+ void (QOPENGLF_APIENTRYP DeleteVertexArraysAPPLE)(GLsizei n, const GLuint *arrays);
+ void (QOPENGLF_APIENTRYP BindVertexArrayAPPLE)(GLuint array);
+};
+
+class QOpenGLExtension_APPLE_vertex_array_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_APPLE_vertex_array_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLboolean glIsVertexArrayAPPLE(GLuint array);
+ void glGenVertexArraysAPPLE(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArraysAPPLE(GLsizei n, const GLuint *arrays);
+ void glBindVertexArrayAPPLE(GLuint array);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_APPLE_vertex_array_object)
+};
+
+inline GLboolean QOpenGLExtension_APPLE_vertex_array_object::glIsVertexArrayAPPLE(GLuint array)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_array_object);
+ return d->IsVertexArrayAPPLE(array);
+}
+
+inline void QOpenGLExtension_APPLE_vertex_array_object::glGenVertexArraysAPPLE(GLsizei n, GLuint *arrays)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_array_object);
+ d->GenVertexArraysAPPLE(n, arrays);
+}
+
+inline void QOpenGLExtension_APPLE_vertex_array_object::glDeleteVertexArraysAPPLE(GLsizei n, const GLuint *arrays)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_array_object);
+ d->DeleteVertexArraysAPPLE(n, arrays);
+}
+
+inline void QOpenGLExtension_APPLE_vertex_array_object::glBindVertexArrayAPPLE(GLuint array)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_array_object);
+ d->BindVertexArrayAPPLE(array);
+}
+
+class QOpenGLExtension_APPLE_vertex_array_rangePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexArrayParameteriAPPLE)(GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP FlushVertexArrayRangeAPPLE)(GLsizei length, GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP VertexArrayRangeAPPLE)(GLsizei length, GLvoid *pointer);
+};
+
+class QOpenGLExtension_APPLE_vertex_array_range : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_APPLE_vertex_array_range();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexArrayParameteriAPPLE(GLenum pname, GLint param);
+ void glFlushVertexArrayRangeAPPLE(GLsizei length, GLvoid *pointer);
+ void glVertexArrayRangeAPPLE(GLsizei length, GLvoid *pointer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_APPLE_vertex_array_range)
+};
+
+inline void QOpenGLExtension_APPLE_vertex_array_range::glVertexArrayParameteriAPPLE(GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_array_range);
+ d->VertexArrayParameteriAPPLE(pname, param);
+}
+
+inline void QOpenGLExtension_APPLE_vertex_array_range::glFlushVertexArrayRangeAPPLE(GLsizei length, GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_array_range);
+ d->FlushVertexArrayRangeAPPLE(length, pointer);
+}
+
+inline void QOpenGLExtension_APPLE_vertex_array_range::glVertexArrayRangeAPPLE(GLsizei length, GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_array_range);
+ d->VertexArrayRangeAPPLE(length, pointer);
+}
+
+class QOpenGLExtension_APPLE_vertex_program_evaluatorsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MapVertexAttrib2fAPPLE)(GLuint index, GLuint size, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void (QOPENGLF_APIENTRYP MapVertexAttrib2dAPPLE)(GLuint index, GLuint size, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void (QOPENGLF_APIENTRYP MapVertexAttrib1fAPPLE)(GLuint index, GLuint size, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void (QOPENGLF_APIENTRYP MapVertexAttrib1dAPPLE)(GLuint index, GLuint size, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ GLboolean (QOPENGLF_APIENTRYP IsVertexAttribEnabledAPPLE)(GLuint index, GLenum pname);
+ void (QOPENGLF_APIENTRYP DisableVertexAttribAPPLE)(GLuint index, GLenum pname);
+ void (QOPENGLF_APIENTRYP EnableVertexAttribAPPLE)(GLuint index, GLenum pname);
+};
+
+class QOpenGLExtension_APPLE_vertex_program_evaluators : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_APPLE_vertex_program_evaluators();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMapVertexAttrib2fAPPLE(GLuint index, GLuint size, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points);
+ void glMapVertexAttrib2dAPPLE(GLuint index, GLuint size, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points);
+ void glMapVertexAttrib1fAPPLE(GLuint index, GLuint size, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points);
+ void glMapVertexAttrib1dAPPLE(GLuint index, GLuint size, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points);
+ GLboolean glIsVertexAttribEnabledAPPLE(GLuint index, GLenum pname);
+ void glDisableVertexAttribAPPLE(GLuint index, GLenum pname);
+ void glEnableVertexAttribAPPLE(GLuint index, GLenum pname);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_APPLE_vertex_program_evaluators)
+};
+
+inline void QOpenGLExtension_APPLE_vertex_program_evaluators::glMapVertexAttrib2fAPPLE(GLuint index, GLuint size, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat *points)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_program_evaluators);
+ d->MapVertexAttrib2fAPPLE(index, size, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLExtension_APPLE_vertex_program_evaluators::glMapVertexAttrib2dAPPLE(GLuint index, GLuint size, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble *points)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_program_evaluators);
+ d->MapVertexAttrib2dAPPLE(index, size, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+inline void QOpenGLExtension_APPLE_vertex_program_evaluators::glMapVertexAttrib1fAPPLE(GLuint index, GLuint size, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat *points)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_program_evaluators);
+ d->MapVertexAttrib1fAPPLE(index, size, u1, u2, stride, order, points);
+}
+
+inline void QOpenGLExtension_APPLE_vertex_program_evaluators::glMapVertexAttrib1dAPPLE(GLuint index, GLuint size, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble *points)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_program_evaluators);
+ d->MapVertexAttrib1dAPPLE(index, size, u1, u2, stride, order, points);
+}
+
+inline GLboolean QOpenGLExtension_APPLE_vertex_program_evaluators::glIsVertexAttribEnabledAPPLE(GLuint index, GLenum pname)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_program_evaluators);
+ return d->IsVertexAttribEnabledAPPLE(index, pname);
+}
+
+inline void QOpenGLExtension_APPLE_vertex_program_evaluators::glDisableVertexAttribAPPLE(GLuint index, GLenum pname)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_program_evaluators);
+ d->DisableVertexAttribAPPLE(index, pname);
+}
+
+inline void QOpenGLExtension_APPLE_vertex_program_evaluators::glEnableVertexAttribAPPLE(GLuint index, GLenum pname)
+{
+ Q_D(QOpenGLExtension_APPLE_vertex_program_evaluators);
+ d->EnableVertexAttribAPPLE(index, pname);
+}
+
+class QOpenGLExtension_ARB_ES2_compatibilityPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ClearDepthf)(GLfloat dd);
+ void (QOPENGLF_APIENTRYP DepthRangef)(GLfloat n, GLfloat f);
+ void (QOPENGLF_APIENTRYP GetShaderPrecisionFormat)(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision);
+ void (QOPENGLF_APIENTRYP ShaderBinary)(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length);
+ void (QOPENGLF_APIENTRYP ReleaseShaderCompiler)();
+};
+
+class QOpenGLExtension_ARB_ES2_compatibility : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_ES2_compatibility();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glClearDepthf(GLfloat dd);
+ void glDepthRangef(GLfloat n, GLfloat f);
+ void glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision);
+ void glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length);
+ void glReleaseShaderCompiler();
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_ES2_compatibility)
+};
+
+inline void QOpenGLExtension_ARB_ES2_compatibility::glClearDepthf(GLfloat dd)
+{
+ Q_D(QOpenGLExtension_ARB_ES2_compatibility);
+ d->ClearDepthf(dd);
+}
+
+inline void QOpenGLExtension_ARB_ES2_compatibility::glDepthRangef(GLfloat n, GLfloat f)
+{
+ Q_D(QOpenGLExtension_ARB_ES2_compatibility);
+ d->DepthRangef(n, f);
+}
+
+inline void QOpenGLExtension_ARB_ES2_compatibility::glGetShaderPrecisionFormat(GLenum shadertype, GLenum precisiontype, GLint *range, GLint *precision)
+{
+ Q_D(QOpenGLExtension_ARB_ES2_compatibility);
+ d->GetShaderPrecisionFormat(shadertype, precisiontype, range, precision);
+}
+
+inline void QOpenGLExtension_ARB_ES2_compatibility::glShaderBinary(GLsizei count, const GLuint *shaders, GLenum binaryformat, const GLvoid *binary, GLsizei length)
+{
+ Q_D(QOpenGLExtension_ARB_ES2_compatibility);
+ d->ShaderBinary(count, shaders, binaryformat, binary, length);
+}
+
+inline void QOpenGLExtension_ARB_ES2_compatibility::glReleaseShaderCompiler()
+{
+ Q_D(QOpenGLExtension_ARB_ES2_compatibility);
+ d->ReleaseShaderCompiler();
+}
+
+class QOpenGLExtension_ARB_base_instancePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawElementsInstancedBaseVertexBaseInstance)(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
+ void (QOPENGLF_APIENTRYP DrawElementsInstancedBaseInstance)(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance);
+ void (QOPENGLF_APIENTRYP DrawArraysInstancedBaseInstance)(GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+};
+
+class QOpenGLExtension_ARB_base_instance : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_base_instance();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawElementsInstancedBaseVertexBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
+ void glDrawElementsInstancedBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance);
+ void glDrawArraysInstancedBaseInstance(GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_base_instance)
+};
+
+inline void QOpenGLExtension_ARB_base_instance::glDrawElementsInstancedBaseVertexBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance)
+{
+ Q_D(QOpenGLExtension_ARB_base_instance);
+ d->DrawElementsInstancedBaseVertexBaseInstance(mode, count, type, indices, instancecount, basevertex, baseinstance);
+}
+
+inline void QOpenGLExtension_ARB_base_instance::glDrawElementsInstancedBaseInstance(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei instancecount, GLuint baseinstance)
+{
+ Q_D(QOpenGLExtension_ARB_base_instance);
+ d->DrawElementsInstancedBaseInstance(mode, count, type, indices, instancecount, baseinstance);
+}
+
+inline void QOpenGLExtension_ARB_base_instance::glDrawArraysInstancedBaseInstance(GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance)
+{
+ Q_D(QOpenGLExtension_ARB_base_instance);
+ d->DrawArraysInstancedBaseInstance(mode, first, count, instancecount, baseinstance);
+}
+
+class QOpenGLExtension_ARB_blend_func_extendedPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLint (QOPENGLF_APIENTRYP GetFragDataIndex)(GLuint program, const GLchar *name);
+ void (QOPENGLF_APIENTRYP BindFragDataLocationIndexed)(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+};
+
+class QOpenGLExtension_ARB_blend_func_extended : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_blend_func_extended();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLint glGetFragDataIndex(GLuint program, const GLchar *name);
+ void glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_blend_func_extended)
+};
+
+inline GLint QOpenGLExtension_ARB_blend_func_extended::glGetFragDataIndex(GLuint program, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_ARB_blend_func_extended);
+ return d->GetFragDataIndex(program, name);
+}
+
+inline void QOpenGLExtension_ARB_blend_func_extended::glBindFragDataLocationIndexed(GLuint program, GLuint colorNumber, GLuint index, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_ARB_blend_func_extended);
+ d->BindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+class QOpenGLExtension_ARB_cl_eventPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLsync (QOPENGLF_APIENTRYP CreateSyncFromCLeventARB)(struct _cl_context * context, struct _cl_event * event, GLbitfield flags);
+};
+
+class QOpenGLExtension_ARB_cl_event : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_cl_event();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLsync glCreateSyncFromCLeventARB(struct _cl_context * context, struct _cl_event * event, GLbitfield flags);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_cl_event)
+};
+
+inline GLsync QOpenGLExtension_ARB_cl_event::glCreateSyncFromCLeventARB(struct _cl_context * context, struct _cl_event * event, GLbitfield flags)
+{
+ Q_D(QOpenGLExtension_ARB_cl_event);
+ return d->CreateSyncFromCLeventARB(context, event, flags);
+}
+
+class QOpenGLExtension_ARB_clear_buffer_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ClearBufferSubData)(GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data);
+ void (QOPENGLF_APIENTRYP ClearBufferData)(GLenum target, GLenum internalformat, GLenum format, GLenum type, const void *data);
+};
+
+class QOpenGLExtension_ARB_clear_buffer_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_clear_buffer_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glClearBufferSubData(GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data);
+ void glClearBufferData(GLenum target, GLenum internalformat, GLenum format, GLenum type, const void *data);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_clear_buffer_object)
+};
+
+inline void QOpenGLExtension_ARB_clear_buffer_object::glClearBufferSubData(GLenum target, GLenum internalformat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data)
+{
+ Q_D(QOpenGLExtension_ARB_clear_buffer_object);
+ d->ClearBufferSubData(target, internalformat, offset, size, format, type, data);
+}
+
+inline void QOpenGLExtension_ARB_clear_buffer_object::glClearBufferData(GLenum target, GLenum internalformat, GLenum format, GLenum type, const void *data)
+{
+ Q_D(QOpenGLExtension_ARB_clear_buffer_object);
+ d->ClearBufferData(target, internalformat, format, type, data);
+}
+
+class QOpenGLExtension_ARB_color_buffer_floatPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ClampColorARB)(GLenum target, GLenum clamp);
+};
+
+class QOpenGLExtension_ARB_color_buffer_float : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_color_buffer_float();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glClampColorARB(GLenum target, GLenum clamp);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_color_buffer_float)
+};
+
+inline void QOpenGLExtension_ARB_color_buffer_float::glClampColorARB(GLenum target, GLenum clamp)
+{
+ Q_D(QOpenGLExtension_ARB_color_buffer_float);
+ d->ClampColorARB(target, clamp);
+}
+
+class QOpenGLExtension_ARB_compute_shaderPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DispatchComputeIndirect)(GLintptr indirect);
+ void (QOPENGLF_APIENTRYP DispatchCompute)(GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z);
+};
+
+class QOpenGLExtension_ARB_compute_shader : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_compute_shader();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDispatchComputeIndirect(GLintptr indirect);
+ void glDispatchCompute(GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_compute_shader)
+};
+
+inline void QOpenGLExtension_ARB_compute_shader::glDispatchComputeIndirect(GLintptr indirect)
+{
+ Q_D(QOpenGLExtension_ARB_compute_shader);
+ d->DispatchComputeIndirect(indirect);
+}
+
+inline void QOpenGLExtension_ARB_compute_shader::glDispatchCompute(GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z)
+{
+ Q_D(QOpenGLExtension_ARB_compute_shader);
+ d->DispatchCompute(num_groups_x, num_groups_y, num_groups_z);
+}
+
+class QOpenGLExtension_ARB_copy_bufferPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP CopyBufferSubData)(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+};
+
+class QOpenGLExtension_ARB_copy_buffer : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_copy_buffer();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_copy_buffer)
+};
+
+inline void QOpenGLExtension_ARB_copy_buffer::glCopyBufferSubData(GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ Q_D(QOpenGLExtension_ARB_copy_buffer);
+ d->CopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+class QOpenGLExtension_ARB_copy_imagePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP CopyImageSubData)(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);
+};
+
+class QOpenGLExtension_ARB_copy_image : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_copy_image();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glCopyImageSubData(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);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_copy_image)
+};
+
+inline void QOpenGLExtension_ARB_copy_image::glCopyImageSubData(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)
+{
+ Q_D(QOpenGLExtension_ARB_copy_image);
+ d->CopyImageSubData(srcName, srcTarget, srcLevel, srcX, srcY, srcZ, dstName, dstTarget, dstLevel, dstX, dstY, dstZ, srcWidth, srcHeight, srcDepth);
+}
+
+class QOpenGLExtension_ARB_debug_outputPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLuint (QOPENGLF_APIENTRYP GetDebugMessageLogARB)(GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog);
+ void (QOPENGLF_APIENTRYP DebugMessageCallbackARB)(GLDEBUGPROCARB callback, const GLvoid *userParam);
+ void (QOPENGLF_APIENTRYP DebugMessageInsertARB)(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf);
+ void (QOPENGLF_APIENTRYP DebugMessageControlARB)(GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
+};
+
+class QOpenGLExtension_ARB_debug_output : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_debug_output();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLuint glGetDebugMessageLogARB(GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog);
+ void glDebugMessageCallbackARB(GLDEBUGPROCARB callback, const GLvoid *userParam);
+ void glDebugMessageInsertARB(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf);
+ void glDebugMessageControlARB(GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_debug_output)
+};
+
+inline GLuint QOpenGLExtension_ARB_debug_output::glGetDebugMessageLogARB(GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog)
+{
+ Q_D(QOpenGLExtension_ARB_debug_output);
+ return d->GetDebugMessageLogARB(count, bufsize, sources, types, ids, severities, lengths, messageLog);
+}
+
+inline void QOpenGLExtension_ARB_debug_output::glDebugMessageCallbackARB(GLDEBUGPROCARB callback, const GLvoid *userParam)
+{
+ Q_D(QOpenGLExtension_ARB_debug_output);
+ d->DebugMessageCallbackARB(callback, userParam);
+}
+
+inline void QOpenGLExtension_ARB_debug_output::glDebugMessageInsertARB(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf)
+{
+ Q_D(QOpenGLExtension_ARB_debug_output);
+ d->DebugMessageInsertARB(source, type, id, severity, length, buf);
+}
+
+inline void QOpenGLExtension_ARB_debug_output::glDebugMessageControlARB(GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled)
+{
+ Q_D(QOpenGLExtension_ARB_debug_output);
+ d->DebugMessageControlARB(source, type, severity, count, ids, enabled);
+}
+
+class QOpenGLExtension_ARB_draw_buffersPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawBuffersARB)(GLsizei n, const GLenum *bufs);
+};
+
+class QOpenGLExtension_ARB_draw_buffers : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_draw_buffers();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawBuffersARB(GLsizei n, const GLenum *bufs);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_draw_buffers)
+};
+
+inline void QOpenGLExtension_ARB_draw_buffers::glDrawBuffersARB(GLsizei n, const GLenum *bufs)
+{
+ Q_D(QOpenGLExtension_ARB_draw_buffers);
+ d->DrawBuffersARB(n, bufs);
+}
+
+class QOpenGLExtension_ARB_draw_buffers_blendPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BlendFuncSeparateiARB)(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void (QOPENGLF_APIENTRYP BlendFunciARB)(GLuint buf, GLenum src, GLenum dst);
+ void (QOPENGLF_APIENTRYP BlendEquationSeparateiARB)(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void (QOPENGLF_APIENTRYP BlendEquationiARB)(GLuint buf, GLenum mode);
+};
+
+class QOpenGLExtension_ARB_draw_buffers_blend : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_draw_buffers_blend();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBlendFuncSeparateiARB(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+ void glBlendFunciARB(GLuint buf, GLenum src, GLenum dst);
+ void glBlendEquationSeparateiARB(GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+ void glBlendEquationiARB(GLuint buf, GLenum mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_draw_buffers_blend)
+};
+
+inline void QOpenGLExtension_ARB_draw_buffers_blend::glBlendFuncSeparateiARB(GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ Q_D(QOpenGLExtension_ARB_draw_buffers_blend);
+ d->BlendFuncSeparateiARB(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+inline void QOpenGLExtension_ARB_draw_buffers_blend::glBlendFunciARB(GLuint buf, GLenum src, GLenum dst)
+{
+ Q_D(QOpenGLExtension_ARB_draw_buffers_blend);
+ d->BlendFunciARB(buf, src, dst);
+}
+
+inline void QOpenGLExtension_ARB_draw_buffers_blend::glBlendEquationSeparateiARB(GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ Q_D(QOpenGLExtension_ARB_draw_buffers_blend);
+ d->BlendEquationSeparateiARB(buf, modeRGB, modeAlpha);
+}
+
+inline void QOpenGLExtension_ARB_draw_buffers_blend::glBlendEquationiARB(GLuint buf, GLenum mode)
+{
+ Q_D(QOpenGLExtension_ARB_draw_buffers_blend);
+ d->BlendEquationiARB(buf, mode);
+}
+
+class QOpenGLExtension_ARB_draw_elements_base_vertexPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MultiDrawElementsBaseVertex)(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void (QOPENGLF_APIENTRYP DrawElementsInstancedBaseVertex)(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void (QOPENGLF_APIENTRYP DrawRangeElementsBaseVertex)(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void (QOPENGLF_APIENTRYP DrawElementsBaseVertex)(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+};
+
+class QOpenGLExtension_ARB_draw_elements_base_vertex : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_draw_elements_base_vertex();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex);
+ void glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex);
+ void glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+ void glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_draw_elements_base_vertex)
+};
+
+inline void QOpenGLExtension_ARB_draw_elements_base_vertex::glMultiDrawElementsBaseVertex(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei drawcount, const GLint *basevertex)
+{
+ Q_D(QOpenGLExtension_ARB_draw_elements_base_vertex);
+ d->MultiDrawElementsBaseVertex(mode, count, type, indices, drawcount, basevertex);
+}
+
+inline void QOpenGLExtension_ARB_draw_elements_base_vertex::glDrawElementsInstancedBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei instancecount, GLint basevertex)
+{
+ Q_D(QOpenGLExtension_ARB_draw_elements_base_vertex);
+ d->DrawElementsInstancedBaseVertex(mode, count, type, indices, instancecount, basevertex);
+}
+
+inline void QOpenGLExtension_ARB_draw_elements_base_vertex::glDrawRangeElementsBaseVertex(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ Q_D(QOpenGLExtension_ARB_draw_elements_base_vertex);
+ d->DrawRangeElementsBaseVertex(mode, start, end, count, type, indices, basevertex);
+}
+
+inline void QOpenGLExtension_ARB_draw_elements_base_vertex::glDrawElementsBaseVertex(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLint basevertex)
+{
+ Q_D(QOpenGLExtension_ARB_draw_elements_base_vertex);
+ d->DrawElementsBaseVertex(mode, count, type, indices, basevertex);
+}
+
+class QOpenGLExtension_ARB_draw_indirectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawElementsIndirect)(GLenum mode, GLenum type, const GLvoid *indirect);
+ void (QOPENGLF_APIENTRYP DrawArraysIndirect)(GLenum mode, const GLvoid *indirect);
+};
+
+class QOpenGLExtension_ARB_draw_indirect : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_draw_indirect();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect);
+ void glDrawArraysIndirect(GLenum mode, const GLvoid *indirect);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_draw_indirect)
+};
+
+inline void QOpenGLExtension_ARB_draw_indirect::glDrawElementsIndirect(GLenum mode, GLenum type, const GLvoid *indirect)
+{
+ Q_D(QOpenGLExtension_ARB_draw_indirect);
+ d->DrawElementsIndirect(mode, type, indirect);
+}
+
+inline void QOpenGLExtension_ARB_draw_indirect::glDrawArraysIndirect(GLenum mode, const GLvoid *indirect)
+{
+ Q_D(QOpenGLExtension_ARB_draw_indirect);
+ d->DrawArraysIndirect(mode, indirect);
+}
+
+class QOpenGLExtension_ARB_draw_instancedPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawElementsInstancedARB)(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount);
+ void (QOPENGLF_APIENTRYP DrawArraysInstancedARB)(GLenum mode, GLint first, GLsizei count, GLsizei primcount);
+};
+
+class QOpenGLExtension_ARB_draw_instanced : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_draw_instanced();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawElementsInstancedARB(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount);
+ void glDrawArraysInstancedARB(GLenum mode, GLint first, GLsizei count, GLsizei primcount);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_draw_instanced)
+};
+
+inline void QOpenGLExtension_ARB_draw_instanced::glDrawElementsInstancedARB(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_ARB_draw_instanced);
+ d->DrawElementsInstancedARB(mode, count, type, indices, primcount);
+}
+
+inline void QOpenGLExtension_ARB_draw_instanced::glDrawArraysInstancedARB(GLenum mode, GLint first, GLsizei count, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_ARB_draw_instanced);
+ d->DrawArraysInstancedARB(mode, first, count, primcount);
+}
+
+class QOpenGLExtension_ARB_framebuffer_no_attachmentsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetFramebufferParameteriv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP FramebufferParameteri)(GLenum target, GLenum pname, GLint param);
+};
+
+class QOpenGLExtension_ARB_framebuffer_no_attachments : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_framebuffer_no_attachments();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetFramebufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glFramebufferParameteri(GLenum target, GLenum pname, GLint param);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_framebuffer_no_attachments)
+};
+
+inline void QOpenGLExtension_ARB_framebuffer_no_attachments::glGetFramebufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_no_attachments);
+ d->GetFramebufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_no_attachments::glFramebufferParameteri(GLenum target, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_no_attachments);
+ d->FramebufferParameteri(target, pname, param);
+}
+
+class QOpenGLExtension_ARB_framebuffer_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP FramebufferTextureLayer)(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void (QOPENGLF_APIENTRYP RenderbufferStorageMultisample)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP BlitFramebuffer)(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void (QOPENGLF_APIENTRYP GenerateMipmap)(GLenum target);
+ void (QOPENGLF_APIENTRYP GetFramebufferAttachmentParameteriv)(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP FramebufferRenderbuffer)(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void (QOPENGLF_APIENTRYP FramebufferTexture3D)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void (QOPENGLF_APIENTRYP FramebufferTexture2D)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void (QOPENGLF_APIENTRYP FramebufferTexture1D)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum (QOPENGLF_APIENTRYP CheckFramebufferStatus)(GLenum target);
+ void (QOPENGLF_APIENTRYP GenFramebuffers)(GLsizei n, GLuint *framebuffers);
+ void (QOPENGLF_APIENTRYP DeleteFramebuffers)(GLsizei n, const GLuint *framebuffers);
+ void (QOPENGLF_APIENTRYP BindFramebuffer)(GLenum target, GLuint framebuffer);
+ GLboolean (QOPENGLF_APIENTRYP IsFramebuffer)(GLuint framebuffer);
+ void (QOPENGLF_APIENTRYP GetRenderbufferParameteriv)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP RenderbufferStorage)(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP GenRenderbuffers)(GLsizei n, GLuint *renderbuffers);
+ void (QOPENGLF_APIENTRYP DeleteRenderbuffers)(GLsizei n, const GLuint *renderbuffers);
+ void (QOPENGLF_APIENTRYP BindRenderbuffer)(GLenum target, GLuint renderbuffer);
+ GLboolean (QOPENGLF_APIENTRYP IsRenderbuffer)(GLuint renderbuffer);
+};
+
+class QOpenGLExtension_ARB_framebuffer_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_framebuffer_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+ void glGenerateMipmap(GLenum target);
+ void glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatus(GLenum target);
+ void glGenFramebuffers(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebuffer(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebuffer(GLuint framebuffer);
+ void glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffers(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbuffer(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbuffer(GLuint renderbuffer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_framebuffer_object)
+};
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glFramebufferTextureLayer(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->FramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glRenderbufferStorageMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->RenderbufferStorageMultisample(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glBlitFramebuffer(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glGenerateMipmap(GLenum target)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->GenerateMipmap(target);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glGetFramebufferAttachmentParameteriv(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->GetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glFramebufferRenderbuffer(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->FramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glFramebufferTexture3D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->FramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glFramebufferTexture2D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->FramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glFramebufferTexture1D(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->FramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLExtension_ARB_framebuffer_object::glCheckFramebufferStatus(GLenum target)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ return d->CheckFramebufferStatus(target);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glGenFramebuffers(GLsizei n, GLuint *framebuffers)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->GenFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glDeleteFramebuffers(GLsizei n, const GLuint *framebuffers)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->DeleteFramebuffers(n, framebuffers);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glBindFramebuffer(GLenum target, GLuint framebuffer)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->BindFramebuffer(target, framebuffer);
+}
+
+inline GLboolean QOpenGLExtension_ARB_framebuffer_object::glIsFramebuffer(GLuint framebuffer)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ return d->IsFramebuffer(framebuffer);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glGetRenderbufferParameteriv(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->GetRenderbufferParameteriv(target, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glRenderbufferStorage(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->RenderbufferStorage(target, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glGenRenderbuffers(GLsizei n, GLuint *renderbuffers)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->GenRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glDeleteRenderbuffers(GLsizei n, const GLuint *renderbuffers)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->DeleteRenderbuffers(n, renderbuffers);
+}
+
+inline void QOpenGLExtension_ARB_framebuffer_object::glBindRenderbuffer(GLenum target, GLuint renderbuffer)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ d->BindRenderbuffer(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLExtension_ARB_framebuffer_object::glIsRenderbuffer(GLuint renderbuffer)
+{
+ Q_D(QOpenGLExtension_ARB_framebuffer_object);
+ return d->IsRenderbuffer(renderbuffer);
+}
+
+class QOpenGLExtension_ARB_geometry_shader4Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP FramebufferTextureFaceARB)(GLenum target, GLenum attachment, GLuint texture, GLint level, GLenum face);
+ void (QOPENGLF_APIENTRYP FramebufferTextureLayerARB)(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void (QOPENGLF_APIENTRYP FramebufferTextureARB)(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void (QOPENGLF_APIENTRYP ProgramParameteriARB)(GLuint program, GLenum pname, GLint value);
+};
+
+class QOpenGLExtension_ARB_geometry_shader4 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_geometry_shader4();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glFramebufferTextureFaceARB(GLenum target, GLenum attachment, GLuint texture, GLint level, GLenum face);
+ void glFramebufferTextureLayerARB(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glFramebufferTextureARB(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glProgramParameteriARB(GLuint program, GLenum pname, GLint value);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_geometry_shader4)
+};
+
+inline void QOpenGLExtension_ARB_geometry_shader4::glFramebufferTextureFaceARB(GLenum target, GLenum attachment, GLuint texture, GLint level, GLenum face)
+{
+ Q_D(QOpenGLExtension_ARB_geometry_shader4);
+ d->FramebufferTextureFaceARB(target, attachment, texture, level, face);
+}
+
+inline void QOpenGLExtension_ARB_geometry_shader4::glFramebufferTextureLayerARB(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ Q_D(QOpenGLExtension_ARB_geometry_shader4);
+ d->FramebufferTextureLayerARB(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLExtension_ARB_geometry_shader4::glFramebufferTextureARB(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ Q_D(QOpenGLExtension_ARB_geometry_shader4);
+ d->FramebufferTextureARB(target, attachment, texture, level);
+}
+
+inline void QOpenGLExtension_ARB_geometry_shader4::glProgramParameteriARB(GLuint program, GLenum pname, GLint value)
+{
+ Q_D(QOpenGLExtension_ARB_geometry_shader4);
+ d->ProgramParameteriARB(program, pname, value);
+}
+
+class QOpenGLExtension_ARB_get_program_binaryPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ProgramParameteri)(GLuint program, GLenum pname, GLint value);
+ void (QOPENGLF_APIENTRYP ProgramBinary)(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length);
+ void (QOPENGLF_APIENTRYP GetProgramBinary)(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+};
+
+class QOpenGLExtension_ARB_get_program_binary : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_get_program_binary();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glProgramParameteri(GLuint program, GLenum pname, GLint value);
+ void glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length);
+ void glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_get_program_binary)
+};
+
+inline void QOpenGLExtension_ARB_get_program_binary::glProgramParameteri(GLuint program, GLenum pname, GLint value)
+{
+ Q_D(QOpenGLExtension_ARB_get_program_binary);
+ d->ProgramParameteri(program, pname, value);
+}
+
+inline void QOpenGLExtension_ARB_get_program_binary::glProgramBinary(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLsizei length)
+{
+ Q_D(QOpenGLExtension_ARB_get_program_binary);
+ d->ProgramBinary(program, binaryFormat, binary, length);
+}
+
+inline void QOpenGLExtension_ARB_get_program_binary::glGetProgramBinary(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary)
+{
+ Q_D(QOpenGLExtension_ARB_get_program_binary);
+ d->GetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+class QOpenGLExtension_ARB_gpu_shader_fp64Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetUniformdv)(GLuint program, GLint location, GLdouble *params);
+ void (QOPENGLF_APIENTRYP UniformMatrix4x3dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix4x2dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix3x4dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix3x2dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix2x4dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix2x3dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix4dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix3dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix2dv)(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP Uniform4dv)(GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP Uniform3dv)(GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP Uniform2dv)(GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP Uniform1dv)(GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP Uniform4d)(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP Uniform3d)(GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP Uniform2d)(GLint location, GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP Uniform1d)(GLint location, GLdouble x);
+};
+
+class QOpenGLExtension_ARB_gpu_shader_fp64 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_gpu_shader_fp64();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetUniformdv(GLuint program, GLint location, GLdouble *params);
+ void glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glUniform4dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform3dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform2dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform1dv(GLint location, GLsizei count, const GLdouble *value);
+ void glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void glUniform2d(GLint location, GLdouble x, GLdouble y);
+ void glUniform1d(GLint location, GLdouble x);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_gpu_shader_fp64)
+};
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glGetUniformdv(GLuint program, GLint location, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->GetUniformdv(program, location, params);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniformMatrix4x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->UniformMatrix4x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniformMatrix4x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->UniformMatrix4x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniformMatrix3x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->UniformMatrix3x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniformMatrix3x2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->UniformMatrix3x2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniformMatrix2x4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->UniformMatrix2x4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniformMatrix2x3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->UniformMatrix2x3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniformMatrix4dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->UniformMatrix4dv(location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniformMatrix3dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->UniformMatrix3dv(location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniformMatrix2dv(GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->UniformMatrix2dv(location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniform4dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->Uniform4dv(location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniform3dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->Uniform3dv(location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniform2dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->Uniform2dv(location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniform1dv(GLint location, GLsizei count, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->Uniform1dv(location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniform4d(GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->Uniform4d(location, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniform3d(GLint location, GLdouble x, GLdouble y, GLdouble z)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->Uniform3d(location, x, y, z);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniform2d(GLint location, GLdouble x, GLdouble y)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->Uniform2d(location, x, y);
+}
+
+inline void QOpenGLExtension_ARB_gpu_shader_fp64::glUniform1d(GLint location, GLdouble x)
+{
+ Q_D(QOpenGLExtension_ARB_gpu_shader_fp64);
+ d->Uniform1d(location, x);
+}
+
+class QOpenGLExtension_ARB_instanced_arraysPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexAttribDivisorARB)(GLuint index, GLuint divisor);
+};
+
+class QOpenGLExtension_ARB_instanced_arrays : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_instanced_arrays();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexAttribDivisorARB(GLuint index, GLuint divisor);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_instanced_arrays)
+};
+
+inline void QOpenGLExtension_ARB_instanced_arrays::glVertexAttribDivisorARB(GLuint index, GLuint divisor)
+{
+ Q_D(QOpenGLExtension_ARB_instanced_arrays);
+ d->VertexAttribDivisorARB(index, divisor);
+}
+
+class QOpenGLExtension_ARB_internalformat_queryPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetInternalformativ)(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params);
+};
+
+class QOpenGLExtension_ARB_internalformat_query : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_internalformat_query();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetInternalformativ(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_internalformat_query)
+};
+
+inline void QOpenGLExtension_ARB_internalformat_query::glGetInternalformativ(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_internalformat_query);
+ d->GetInternalformativ(target, internalformat, pname, bufSize, params);
+}
+
+class QOpenGLExtension_ARB_internalformat_query2Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetInternalformati64v)(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params);
+};
+
+class QOpenGLExtension_ARB_internalformat_query2 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_internalformat_query2();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetInternalformati64v(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_internalformat_query2)
+};
+
+inline void QOpenGLExtension_ARB_internalformat_query2::glGetInternalformati64v(GLenum target, GLenum internalformat, GLenum pname, GLsizei bufSize, GLint64 *params)
+{
+ Q_D(QOpenGLExtension_ARB_internalformat_query2);
+ d->GetInternalformati64v(target, internalformat, pname, bufSize, params);
+}
+
+class QOpenGLExtension_ARB_invalidate_subdataPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP InvalidateSubFramebuffer)(GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP InvalidateFramebuffer)(GLenum target, GLsizei numAttachments, const GLenum *attachments);
+ void (QOPENGLF_APIENTRYP InvalidateBufferData)(GLuint buffer);
+ void (QOPENGLF_APIENTRYP InvalidateBufferSubData)(GLuint buffer, GLintptr offset, GLsizeiptr length);
+ void (QOPENGLF_APIENTRYP InvalidateTexImage)(GLuint texture, GLint level);
+ void (QOPENGLF_APIENTRYP InvalidateTexSubImage)(GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth);
+};
+
+class QOpenGLExtension_ARB_invalidate_subdata : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_invalidate_subdata();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glInvalidateSubFramebuffer(GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glInvalidateFramebuffer(GLenum target, GLsizei numAttachments, const GLenum *attachments);
+ void glInvalidateBufferData(GLuint buffer);
+ void glInvalidateBufferSubData(GLuint buffer, GLintptr offset, GLsizeiptr length);
+ void glInvalidateTexImage(GLuint texture, GLint level);
+ void glInvalidateTexSubImage(GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_invalidate_subdata)
+};
+
+inline void QOpenGLExtension_ARB_invalidate_subdata::glInvalidateSubFramebuffer(GLenum target, GLsizei numAttachments, const GLenum *attachments, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_ARB_invalidate_subdata);
+ d->InvalidateSubFramebuffer(target, numAttachments, attachments, x, y, width, height);
+}
+
+inline void QOpenGLExtension_ARB_invalidate_subdata::glInvalidateFramebuffer(GLenum target, GLsizei numAttachments, const GLenum *attachments)
+{
+ Q_D(QOpenGLExtension_ARB_invalidate_subdata);
+ d->InvalidateFramebuffer(target, numAttachments, attachments);
+}
+
+inline void QOpenGLExtension_ARB_invalidate_subdata::glInvalidateBufferData(GLuint buffer)
+{
+ Q_D(QOpenGLExtension_ARB_invalidate_subdata);
+ d->InvalidateBufferData(buffer);
+}
+
+inline void QOpenGLExtension_ARB_invalidate_subdata::glInvalidateBufferSubData(GLuint buffer, GLintptr offset, GLsizeiptr length)
+{
+ Q_D(QOpenGLExtension_ARB_invalidate_subdata);
+ d->InvalidateBufferSubData(buffer, offset, length);
+}
+
+inline void QOpenGLExtension_ARB_invalidate_subdata::glInvalidateTexImage(GLuint texture, GLint level)
+{
+ Q_D(QOpenGLExtension_ARB_invalidate_subdata);
+ d->InvalidateTexImage(texture, level);
+}
+
+inline void QOpenGLExtension_ARB_invalidate_subdata::glInvalidateTexSubImage(GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth)
+{
+ Q_D(QOpenGLExtension_ARB_invalidate_subdata);
+ d->InvalidateTexSubImage(texture, level, xoffset, yoffset, zoffset, width, height, depth);
+}
+
+class QOpenGLExtension_ARB_map_buffer_rangePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP FlushMappedBufferRange)(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* (QOPENGLF_APIENTRYP MapBufferRange)(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+};
+
+class QOpenGLExtension_ARB_map_buffer_range : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_map_buffer_range();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_map_buffer_range)
+};
+
+inline void QOpenGLExtension_ARB_map_buffer_range::glFlushMappedBufferRange(GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ Q_D(QOpenGLExtension_ARB_map_buffer_range);
+ d->FlushMappedBufferRange(target, offset, length);
+}
+
+inline GLvoid* QOpenGLExtension_ARB_map_buffer_range::glMapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ Q_D(QOpenGLExtension_ARB_map_buffer_range);
+ return d->MapBufferRange(target, offset, length, access);
+}
+
+class QOpenGLExtension_ARB_matrix_palettePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MatrixIndexPointerARB)(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP MatrixIndexuivARB)(GLint size, const GLuint *indices);
+ void (QOPENGLF_APIENTRYP MatrixIndexusvARB)(GLint size, const GLushort *indices);
+ void (QOPENGLF_APIENTRYP MatrixIndexubvARB)(GLint size, const GLubyte *indices);
+ void (QOPENGLF_APIENTRYP CurrentPaletteMatrixARB)(GLint index);
+};
+
+class QOpenGLExtension_ARB_matrix_palette : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_matrix_palette();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMatrixIndexPointerARB(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glMatrixIndexuivARB(GLint size, const GLuint *indices);
+ void glMatrixIndexusvARB(GLint size, const GLushort *indices);
+ void glMatrixIndexubvARB(GLint size, const GLubyte *indices);
+ void glCurrentPaletteMatrixARB(GLint index);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_matrix_palette)
+};
+
+inline void QOpenGLExtension_ARB_matrix_palette::glMatrixIndexPointerARB(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_ARB_matrix_palette);
+ d->MatrixIndexPointerARB(size, type, stride, pointer);
+}
+
+inline void QOpenGLExtension_ARB_matrix_palette::glMatrixIndexuivARB(GLint size, const GLuint *indices)
+{
+ Q_D(QOpenGLExtension_ARB_matrix_palette);
+ d->MatrixIndexuivARB(size, indices);
+}
+
+inline void QOpenGLExtension_ARB_matrix_palette::glMatrixIndexusvARB(GLint size, const GLushort *indices)
+{
+ Q_D(QOpenGLExtension_ARB_matrix_palette);
+ d->MatrixIndexusvARB(size, indices);
+}
+
+inline void QOpenGLExtension_ARB_matrix_palette::glMatrixIndexubvARB(GLint size, const GLubyte *indices)
+{
+ Q_D(QOpenGLExtension_ARB_matrix_palette);
+ d->MatrixIndexubvARB(size, indices);
+}
+
+inline void QOpenGLExtension_ARB_matrix_palette::glCurrentPaletteMatrixARB(GLint index)
+{
+ Q_D(QOpenGLExtension_ARB_matrix_palette);
+ d->CurrentPaletteMatrixARB(index);
+}
+
+class QOpenGLExtension_ARB_multi_draw_indirectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MultiDrawElementsIndirect)(GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride);
+ void (QOPENGLF_APIENTRYP MultiDrawArraysIndirect)(GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride);
+};
+
+class QOpenGLExtension_ARB_multi_draw_indirect : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_multi_draw_indirect();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMultiDrawElementsIndirect(GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride);
+ void glMultiDrawArraysIndirect(GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_multi_draw_indirect)
+};
+
+inline void QOpenGLExtension_ARB_multi_draw_indirect::glMultiDrawElementsIndirect(GLenum mode, GLenum type, const void *indirect, GLsizei drawcount, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_ARB_multi_draw_indirect);
+ d->MultiDrawElementsIndirect(mode, type, indirect, drawcount, stride);
+}
+
+inline void QOpenGLExtension_ARB_multi_draw_indirect::glMultiDrawArraysIndirect(GLenum mode, const void *indirect, GLsizei drawcount, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_ARB_multi_draw_indirect);
+ d->MultiDrawArraysIndirect(mode, indirect, drawcount, stride);
+}
+
+class QOpenGLExtension_ARB_multisamplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP SampleCoverageARB)(GLfloat value, GLboolean invert);
+};
+
+class QOpenGLExtension_ARB_multisample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_multisample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glSampleCoverageARB(GLfloat value, GLboolean invert);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_multisample)
+};
+
+inline void QOpenGLExtension_ARB_multisample::glSampleCoverageARB(GLfloat value, GLboolean invert)
+{
+ Q_D(QOpenGLExtension_ARB_multisample);
+ d->SampleCoverageARB(value, invert);
+}
+
+class QOpenGLExtension_ARB_multitexturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MultiTexCoord4svARB)(GLenum target, const GLshort *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4sARB)(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4ivARB)(GLenum target, const GLint *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4iARB)(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4fvARB)(GLenum target, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4fARB)(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4dvARB)(GLenum target, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4dARB)(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3svARB)(GLenum target, const GLshort *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3sARB)(GLenum target, GLshort s, GLshort t, GLshort r);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3ivARB)(GLenum target, const GLint *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3iARB)(GLenum target, GLint s, GLint t, GLint r);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3fvARB)(GLenum target, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3fARB)(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3dvARB)(GLenum target, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3dARB)(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2svARB)(GLenum target, const GLshort *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2sARB)(GLenum target, GLshort s, GLshort t);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2ivARB)(GLenum target, const GLint *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2iARB)(GLenum target, GLint s, GLint t);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2fvARB)(GLenum target, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2fARB)(GLenum target, GLfloat s, GLfloat t);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2dvARB)(GLenum target, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2dARB)(GLenum target, GLdouble s, GLdouble t);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1svARB)(GLenum target, const GLshort *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1sARB)(GLenum target, GLshort s);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1ivARB)(GLenum target, const GLint *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1iARB)(GLenum target, GLint s);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1fvARB)(GLenum target, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1fARB)(GLenum target, GLfloat s);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1dvARB)(GLenum target, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1dARB)(GLenum target, GLdouble s);
+ void (QOPENGLF_APIENTRYP ClientActiveTextureARB)(GLenum texture);
+ void (QOPENGLF_APIENTRYP ActiveTextureARB)(GLenum texture);
+};
+
+class QOpenGLExtension_ARB_multitexture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_multitexture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMultiTexCoord4svARB(GLenum target, const GLshort *v);
+ void glMultiTexCoord4sARB(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+ void glMultiTexCoord4ivARB(GLenum target, const GLint *v);
+ void glMultiTexCoord4iARB(GLenum target, GLint s, GLint t, GLint r, GLint q);
+ void glMultiTexCoord4fvARB(GLenum target, const GLfloat *v);
+ void glMultiTexCoord4fARB(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+ void glMultiTexCoord4dvARB(GLenum target, const GLdouble *v);
+ void glMultiTexCoord4dARB(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+ void glMultiTexCoord3svARB(GLenum target, const GLshort *v);
+ void glMultiTexCoord3sARB(GLenum target, GLshort s, GLshort t, GLshort r);
+ void glMultiTexCoord3ivARB(GLenum target, const GLint *v);
+ void glMultiTexCoord3iARB(GLenum target, GLint s, GLint t, GLint r);
+ void glMultiTexCoord3fvARB(GLenum target, const GLfloat *v);
+ void glMultiTexCoord3fARB(GLenum target, GLfloat s, GLfloat t, GLfloat r);
+ void glMultiTexCoord3dvARB(GLenum target, const GLdouble *v);
+ void glMultiTexCoord3dARB(GLenum target, GLdouble s, GLdouble t, GLdouble r);
+ void glMultiTexCoord2svARB(GLenum target, const GLshort *v);
+ void glMultiTexCoord2sARB(GLenum target, GLshort s, GLshort t);
+ void glMultiTexCoord2ivARB(GLenum target, const GLint *v);
+ void glMultiTexCoord2iARB(GLenum target, GLint s, GLint t);
+ void glMultiTexCoord2fvARB(GLenum target, const GLfloat *v);
+ void glMultiTexCoord2fARB(GLenum target, GLfloat s, GLfloat t);
+ void glMultiTexCoord2dvARB(GLenum target, const GLdouble *v);
+ void glMultiTexCoord2dARB(GLenum target, GLdouble s, GLdouble t);
+ void glMultiTexCoord1svARB(GLenum target, const GLshort *v);
+ void glMultiTexCoord1sARB(GLenum target, GLshort s);
+ void glMultiTexCoord1ivARB(GLenum target, const GLint *v);
+ void glMultiTexCoord1iARB(GLenum target, GLint s);
+ void glMultiTexCoord1fvARB(GLenum target, const GLfloat *v);
+ void glMultiTexCoord1fARB(GLenum target, GLfloat s);
+ void glMultiTexCoord1dvARB(GLenum target, const GLdouble *v);
+ void glMultiTexCoord1dARB(GLenum target, GLdouble s);
+ void glClientActiveTextureARB(GLenum texture);
+ void glActiveTextureARB(GLenum texture);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_multitexture)
+};
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord4svARB(GLenum target, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord4svARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord4sARB(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord4sARB(target, s, t, r, q);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord4ivARB(GLenum target, const GLint *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord4ivARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord4iARB(GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord4iARB(target, s, t, r, q);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord4fvARB(GLenum target, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord4fvARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord4fARB(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord4fARB(target, s, t, r, q);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord4dvARB(GLenum target, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord4dvARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord4dARB(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord4dARB(target, s, t, r, q);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord3svARB(GLenum target, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord3svARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord3sARB(GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord3sARB(target, s, t, r);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord3ivARB(GLenum target, const GLint *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord3ivARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord3iARB(GLenum target, GLint s, GLint t, GLint r)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord3iARB(target, s, t, r);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord3fvARB(GLenum target, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord3fvARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord3fARB(GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord3fARB(target, s, t, r);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord3dvARB(GLenum target, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord3dvARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord3dARB(GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord3dARB(target, s, t, r);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord2svARB(GLenum target, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord2svARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord2sARB(GLenum target, GLshort s, GLshort t)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord2sARB(target, s, t);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord2ivARB(GLenum target, const GLint *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord2ivARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord2iARB(GLenum target, GLint s, GLint t)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord2iARB(target, s, t);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord2fvARB(GLenum target, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord2fvARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord2fARB(GLenum target, GLfloat s, GLfloat t)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord2fARB(target, s, t);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord2dvARB(GLenum target, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord2dvARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord2dARB(GLenum target, GLdouble s, GLdouble t)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord2dARB(target, s, t);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord1svARB(GLenum target, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord1svARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord1sARB(GLenum target, GLshort s)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord1sARB(target, s);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord1ivARB(GLenum target, const GLint *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord1ivARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord1iARB(GLenum target, GLint s)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord1iARB(target, s);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord1fvARB(GLenum target, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord1fvARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord1fARB(GLenum target, GLfloat s)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord1fARB(target, s);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord1dvARB(GLenum target, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord1dvARB(target, v);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glMultiTexCoord1dARB(GLenum target, GLdouble s)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->MultiTexCoord1dARB(target, s);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glClientActiveTextureARB(GLenum texture)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->ClientActiveTextureARB(texture);
+}
+
+inline void QOpenGLExtension_ARB_multitexture::glActiveTextureARB(GLenum texture)
+{
+ Q_D(QOpenGLExtension_ARB_multitexture);
+ d->ActiveTextureARB(texture);
+}
+
+class QOpenGLExtension_ARB_occlusion_queryPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetQueryObjectuivARB)(GLuint id, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetQueryObjectivARB)(GLuint id, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetQueryivARB)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP EndQueryARB)(GLenum target);
+ void (QOPENGLF_APIENTRYP BeginQueryARB)(GLenum target, GLuint id);
+ GLboolean (QOPENGLF_APIENTRYP IsQueryARB)(GLuint id);
+ void (QOPENGLF_APIENTRYP DeleteQueriesARB)(GLsizei n, const GLuint *ids);
+ void (QOPENGLF_APIENTRYP GenQueriesARB)(GLsizei n, GLuint *ids);
+};
+
+class QOpenGLExtension_ARB_occlusion_query : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_occlusion_query();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetQueryObjectuivARB(GLuint id, GLenum pname, GLuint *params);
+ void glGetQueryObjectivARB(GLuint id, GLenum pname, GLint *params);
+ void glGetQueryivARB(GLenum target, GLenum pname, GLint *params);
+ void glEndQueryARB(GLenum target);
+ void glBeginQueryARB(GLenum target, GLuint id);
+ GLboolean glIsQueryARB(GLuint id);
+ void glDeleteQueriesARB(GLsizei n, const GLuint *ids);
+ void glGenQueriesARB(GLsizei n, GLuint *ids);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_occlusion_query)
+};
+
+inline void QOpenGLExtension_ARB_occlusion_query::glGetQueryObjectuivARB(GLuint id, GLenum pname, GLuint *params)
+{
+ Q_D(QOpenGLExtension_ARB_occlusion_query);
+ d->GetQueryObjectuivARB(id, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_occlusion_query::glGetQueryObjectivARB(GLuint id, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_occlusion_query);
+ d->GetQueryObjectivARB(id, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_occlusion_query::glGetQueryivARB(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_occlusion_query);
+ d->GetQueryivARB(target, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_occlusion_query::glEndQueryARB(GLenum target)
+{
+ Q_D(QOpenGLExtension_ARB_occlusion_query);
+ d->EndQueryARB(target);
+}
+
+inline void QOpenGLExtension_ARB_occlusion_query::glBeginQueryARB(GLenum target, GLuint id)
+{
+ Q_D(QOpenGLExtension_ARB_occlusion_query);
+ d->BeginQueryARB(target, id);
+}
+
+inline GLboolean QOpenGLExtension_ARB_occlusion_query::glIsQueryARB(GLuint id)
+{
+ Q_D(QOpenGLExtension_ARB_occlusion_query);
+ return d->IsQueryARB(id);
+}
+
+inline void QOpenGLExtension_ARB_occlusion_query::glDeleteQueriesARB(GLsizei n, const GLuint *ids)
+{
+ Q_D(QOpenGLExtension_ARB_occlusion_query);
+ d->DeleteQueriesARB(n, ids);
+}
+
+inline void QOpenGLExtension_ARB_occlusion_query::glGenQueriesARB(GLsizei n, GLuint *ids)
+{
+ Q_D(QOpenGLExtension_ARB_occlusion_query);
+ d->GenQueriesARB(n, ids);
+}
+
+class QOpenGLExtension_ARB_point_parametersPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP PointParameterfvARB)(GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP PointParameterfARB)(GLenum pname, GLfloat param);
+};
+
+class QOpenGLExtension_ARB_point_parameters : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_point_parameters();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glPointParameterfvARB(GLenum pname, const GLfloat *params);
+ void glPointParameterfARB(GLenum pname, GLfloat param);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_point_parameters)
+};
+
+inline void QOpenGLExtension_ARB_point_parameters::glPointParameterfvARB(GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ARB_point_parameters);
+ d->PointParameterfvARB(pname, params);
+}
+
+inline void QOpenGLExtension_ARB_point_parameters::glPointParameterfARB(GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_ARB_point_parameters);
+ d->PointParameterfARB(pname, param);
+}
+
+class QOpenGLExtension_ARB_program_interface_queryPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLint (QOPENGLF_APIENTRYP GetProgramResourceLocationIndex)(GLuint program, GLenum programInterface, const GLchar *name);
+ GLint (QOPENGLF_APIENTRYP GetProgramResourceLocation)(GLuint program, GLenum programInterface, const GLchar *name);
+ void (QOPENGLF_APIENTRYP GetProgramResourceiv)(GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params);
+ void (QOPENGLF_APIENTRYP GetProgramResourceName)(GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
+ GLuint (QOPENGLF_APIENTRYP GetProgramResourceIndex)(GLuint program, GLenum programInterface, const GLchar *name);
+ void (QOPENGLF_APIENTRYP GetProgramInterfaceiv)(GLuint program, GLenum programInterface, GLenum pname, GLint *params);
+};
+
+class QOpenGLExtension_ARB_program_interface_query : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_program_interface_query();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLint glGetProgramResourceLocationIndex(GLuint program, GLenum programInterface, const GLchar *name);
+ GLint glGetProgramResourceLocation(GLuint program, GLenum programInterface, const GLchar *name);
+ void glGetProgramResourceiv(GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params);
+ void glGetProgramResourceName(GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name);
+ GLuint glGetProgramResourceIndex(GLuint program, GLenum programInterface, const GLchar *name);
+ void glGetProgramInterfaceiv(GLuint program, GLenum programInterface, GLenum pname, GLint *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_program_interface_query)
+};
+
+inline GLint QOpenGLExtension_ARB_program_interface_query::glGetProgramResourceLocationIndex(GLuint program, GLenum programInterface, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_ARB_program_interface_query);
+ return d->GetProgramResourceLocationIndex(program, programInterface, name);
+}
+
+inline GLint QOpenGLExtension_ARB_program_interface_query::glGetProgramResourceLocation(GLuint program, GLenum programInterface, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_ARB_program_interface_query);
+ return d->GetProgramResourceLocation(program, programInterface, name);
+}
+
+inline void QOpenGLExtension_ARB_program_interface_query::glGetProgramResourceiv(GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum *props, GLsizei bufSize, GLsizei *length, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_program_interface_query);
+ d->GetProgramResourceiv(program, programInterface, index, propCount, props, bufSize, length, params);
+}
+
+inline void QOpenGLExtension_ARB_program_interface_query::glGetProgramResourceName(GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei *length, GLchar *name)
+{
+ Q_D(QOpenGLExtension_ARB_program_interface_query);
+ d->GetProgramResourceName(program, programInterface, index, bufSize, length, name);
+}
+
+inline GLuint QOpenGLExtension_ARB_program_interface_query::glGetProgramResourceIndex(GLuint program, GLenum programInterface, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_ARB_program_interface_query);
+ return d->GetProgramResourceIndex(program, programInterface, name);
+}
+
+inline void QOpenGLExtension_ARB_program_interface_query::glGetProgramInterfaceiv(GLuint program, GLenum programInterface, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_program_interface_query);
+ d->GetProgramInterfaceiv(program, programInterface, pname, params);
+}
+
+class QOpenGLExtension_ARB_provoking_vertexPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ProvokingVertex)(GLenum mode);
+};
+
+class QOpenGLExtension_ARB_provoking_vertex : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_provoking_vertex();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glProvokingVertex(GLenum mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_provoking_vertex)
+};
+
+inline void QOpenGLExtension_ARB_provoking_vertex::glProvokingVertex(GLenum mode)
+{
+ Q_D(QOpenGLExtension_ARB_provoking_vertex);
+ d->ProvokingVertex(mode);
+}
+
+class QOpenGLExtension_ARB_robustnessPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetnUniformdvARB)(GLuint program, GLint location, GLsizei bufSize, GLdouble *params);
+ void (QOPENGLF_APIENTRYP GetnUniformuivARB)(GLuint program, GLint location, GLsizei bufSize, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetnUniformivARB)(GLuint program, GLint location, GLsizei bufSize, GLint *params);
+ void (QOPENGLF_APIENTRYP GetnUniformfvARB)(GLuint program, GLint location, GLsizei bufSize, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetnCompressedTexImageARB)(GLenum target, GLint lod, GLsizei bufSize, GLvoid *img);
+ void (QOPENGLF_APIENTRYP ReadnPixelsARB)(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, GLvoid *data);
+ void (QOPENGLF_APIENTRYP GetnTexImageARB)(GLenum target, GLint level, GLenum format, GLenum type, GLsizei bufSize, GLvoid *img);
+ void (QOPENGLF_APIENTRYP GetnMinmaxARB)(GLenum target, GLboolean reset, GLenum format, GLenum type, GLsizei bufSize, GLvoid *values);
+ void (QOPENGLF_APIENTRYP GetnHistogramARB)(GLenum target, GLboolean reset, GLenum format, GLenum type, GLsizei bufSize, GLvoid *values);
+ void (QOPENGLF_APIENTRYP GetnSeparableFilterARB)(GLenum target, GLenum format, GLenum type, GLsizei rowBufSize, GLvoid *row, GLsizei columnBufSize, GLvoid *column, GLvoid *span);
+ void (QOPENGLF_APIENTRYP GetnConvolutionFilterARB)(GLenum target, GLenum format, GLenum type, GLsizei bufSize, GLvoid *image);
+ void (QOPENGLF_APIENTRYP GetnColorTableARB)(GLenum target, GLenum format, GLenum type, GLsizei bufSize, GLvoid *table);
+ void (QOPENGLF_APIENTRYP GetnPolygonStippleARB)(GLsizei bufSize, GLubyte *pattern);
+ void (QOPENGLF_APIENTRYP GetnPixelMapusvARB)(GLenum map, GLsizei bufSize, GLushort *values);
+ void (QOPENGLF_APIENTRYP GetnPixelMapuivARB)(GLenum map, GLsizei bufSize, GLuint *values);
+ void (QOPENGLF_APIENTRYP GetnPixelMapfvARB)(GLenum map, GLsizei bufSize, GLfloat *values);
+ void (QOPENGLF_APIENTRYP GetnMapivARB)(GLenum target, GLenum query, GLsizei bufSize, GLint *v);
+ void (QOPENGLF_APIENTRYP GetnMapfvARB)(GLenum target, GLenum query, GLsizei bufSize, GLfloat *v);
+ void (QOPENGLF_APIENTRYP GetnMapdvARB)(GLenum target, GLenum query, GLsizei bufSize, GLdouble *v);
+ GLenum (QOPENGLF_APIENTRYP GetGraphicsResetStatusARB)();
+};
+
+class QOpenGLExtension_ARB_robustness : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_robustness();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetnUniformdvARB(GLuint program, GLint location, GLsizei bufSize, GLdouble *params);
+ void glGetnUniformuivARB(GLuint program, GLint location, GLsizei bufSize, GLuint *params);
+ void glGetnUniformivARB(GLuint program, GLint location, GLsizei bufSize, GLint *params);
+ void glGetnUniformfvARB(GLuint program, GLint location, GLsizei bufSize, GLfloat *params);
+ void glGetnCompressedTexImageARB(GLenum target, GLint lod, GLsizei bufSize, GLvoid *img);
+ void glReadnPixelsARB(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, GLvoid *data);
+ void glGetnTexImageARB(GLenum target, GLint level, GLenum format, GLenum type, GLsizei bufSize, GLvoid *img);
+ void glGetnMinmaxARB(GLenum target, GLboolean reset, GLenum format, GLenum type, GLsizei bufSize, GLvoid *values);
+ void glGetnHistogramARB(GLenum target, GLboolean reset, GLenum format, GLenum type, GLsizei bufSize, GLvoid *values);
+ void glGetnSeparableFilterARB(GLenum target, GLenum format, GLenum type, GLsizei rowBufSize, GLvoid *row, GLsizei columnBufSize, GLvoid *column, GLvoid *span);
+ void glGetnConvolutionFilterARB(GLenum target, GLenum format, GLenum type, GLsizei bufSize, GLvoid *image);
+ void glGetnColorTableARB(GLenum target, GLenum format, GLenum type, GLsizei bufSize, GLvoid *table);
+ void glGetnPolygonStippleARB(GLsizei bufSize, GLubyte *pattern);
+ void glGetnPixelMapusvARB(GLenum map, GLsizei bufSize, GLushort *values);
+ void glGetnPixelMapuivARB(GLenum map, GLsizei bufSize, GLuint *values);
+ void glGetnPixelMapfvARB(GLenum map, GLsizei bufSize, GLfloat *values);
+ void glGetnMapivARB(GLenum target, GLenum query, GLsizei bufSize, GLint *v);
+ void glGetnMapfvARB(GLenum target, GLenum query, GLsizei bufSize, GLfloat *v);
+ void glGetnMapdvARB(GLenum target, GLenum query, GLsizei bufSize, GLdouble *v);
+ GLenum glGetGraphicsResetStatusARB();
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_robustness)
+};
+
+inline void QOpenGLExtension_ARB_robustness::glGetnUniformdvARB(GLuint program, GLint location, GLsizei bufSize, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnUniformdvARB(program, location, bufSize, params);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnUniformuivARB(GLuint program, GLint location, GLsizei bufSize, GLuint *params)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnUniformuivARB(program, location, bufSize, params);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnUniformivARB(GLuint program, GLint location, GLsizei bufSize, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnUniformivARB(program, location, bufSize, params);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnUniformfvARB(GLuint program, GLint location, GLsizei bufSize, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnUniformfvARB(program, location, bufSize, params);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnCompressedTexImageARB(GLenum target, GLint lod, GLsizei bufSize, GLvoid *img)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnCompressedTexImageARB(target, lod, bufSize, img);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glReadnPixelsARB(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, GLvoid *data)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->ReadnPixelsARB(x, y, width, height, format, type, bufSize, data);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnTexImageARB(GLenum target, GLint level, GLenum format, GLenum type, GLsizei bufSize, GLvoid *img)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnTexImageARB(target, level, format, type, bufSize, img);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnMinmaxARB(GLenum target, GLboolean reset, GLenum format, GLenum type, GLsizei bufSize, GLvoid *values)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnMinmaxARB(target, reset, format, type, bufSize, values);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnHistogramARB(GLenum target, GLboolean reset, GLenum format, GLenum type, GLsizei bufSize, GLvoid *values)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnHistogramARB(target, reset, format, type, bufSize, values);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnSeparableFilterARB(GLenum target, GLenum format, GLenum type, GLsizei rowBufSize, GLvoid *row, GLsizei columnBufSize, GLvoid *column, GLvoid *span)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnSeparableFilterARB(target, format, type, rowBufSize, row, columnBufSize, column, span);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnConvolutionFilterARB(GLenum target, GLenum format, GLenum type, GLsizei bufSize, GLvoid *image)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnConvolutionFilterARB(target, format, type, bufSize, image);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnColorTableARB(GLenum target, GLenum format, GLenum type, GLsizei bufSize, GLvoid *table)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnColorTableARB(target, format, type, bufSize, table);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnPolygonStippleARB(GLsizei bufSize, GLubyte *pattern)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnPolygonStippleARB(bufSize, pattern);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnPixelMapusvARB(GLenum map, GLsizei bufSize, GLushort *values)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnPixelMapusvARB(map, bufSize, values);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnPixelMapuivARB(GLenum map, GLsizei bufSize, GLuint *values)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnPixelMapuivARB(map, bufSize, values);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnPixelMapfvARB(GLenum map, GLsizei bufSize, GLfloat *values)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnPixelMapfvARB(map, bufSize, values);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnMapivARB(GLenum target, GLenum query, GLsizei bufSize, GLint *v)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnMapivARB(target, query, bufSize, v);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnMapfvARB(GLenum target, GLenum query, GLsizei bufSize, GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnMapfvARB(target, query, bufSize, v);
+}
+
+inline void QOpenGLExtension_ARB_robustness::glGetnMapdvARB(GLenum target, GLenum query, GLsizei bufSize, GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ d->GetnMapdvARB(target, query, bufSize, v);
+}
+
+inline GLenum QOpenGLExtension_ARB_robustness::glGetGraphicsResetStatusARB()
+{
+ Q_D(QOpenGLExtension_ARB_robustness);
+ return d->GetGraphicsResetStatusARB();
+}
+
+class QOpenGLExtension_ARB_sample_shadingPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MinSampleShadingARB)(GLfloat value);
+};
+
+class QOpenGLExtension_ARB_sample_shading : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_sample_shading();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMinSampleShadingARB(GLfloat value);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_sample_shading)
+};
+
+inline void QOpenGLExtension_ARB_sample_shading::glMinSampleShadingARB(GLfloat value)
+{
+ Q_D(QOpenGLExtension_ARB_sample_shading);
+ d->MinSampleShadingARB(value);
+}
+
+class QOpenGLExtension_ARB_sampler_objectsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetSamplerParameterIuiv)(GLuint sampler, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetSamplerParameterfv)(GLuint sampler, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetSamplerParameterIiv)(GLuint sampler, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetSamplerParameteriv)(GLuint sampler, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP SamplerParameterIuiv)(GLuint sampler, GLenum pname, const GLuint *param);
+ void (QOPENGLF_APIENTRYP SamplerParameterIiv)(GLuint sampler, GLenum pname, const GLint *param);
+ void (QOPENGLF_APIENTRYP SamplerParameterfv)(GLuint sampler, GLenum pname, const GLfloat *param);
+ void (QOPENGLF_APIENTRYP SamplerParameterf)(GLuint sampler, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP SamplerParameteriv)(GLuint sampler, GLenum pname, const GLint *param);
+ void (QOPENGLF_APIENTRYP SamplerParameteri)(GLuint sampler, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP BindSampler)(GLuint unit, GLuint sampler);
+ GLboolean (QOPENGLF_APIENTRYP IsSampler)(GLuint sampler);
+ void (QOPENGLF_APIENTRYP DeleteSamplers)(GLsizei count, const GLuint *samplers);
+ void (QOPENGLF_APIENTRYP GenSamplers)(GLsizei count, GLuint *samplers);
+};
+
+class QOpenGLExtension_ARB_sampler_objects : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_sampler_objects();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params);
+ void glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params);
+ void glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params);
+ void glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params);
+ void glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param);
+ void glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param);
+ void glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param);
+ void glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param);
+ void glSamplerParameteri(GLuint sampler, GLenum pname, GLint param);
+ void glBindSampler(GLuint unit, GLuint sampler);
+ GLboolean glIsSampler(GLuint sampler);
+ void glDeleteSamplers(GLsizei count, const GLuint *samplers);
+ void glGenSamplers(GLsizei count, GLuint *samplers);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_sampler_objects)
+};
+
+inline void QOpenGLExtension_ARB_sampler_objects::glGetSamplerParameterIuiv(GLuint sampler, GLenum pname, GLuint *params)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->GetSamplerParameterIuiv(sampler, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_sampler_objects::glGetSamplerParameterfv(GLuint sampler, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->GetSamplerParameterfv(sampler, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_sampler_objects::glGetSamplerParameterIiv(GLuint sampler, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->GetSamplerParameterIiv(sampler, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_sampler_objects::glGetSamplerParameteriv(GLuint sampler, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->GetSamplerParameteriv(sampler, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_sampler_objects::glSamplerParameterIuiv(GLuint sampler, GLenum pname, const GLuint *param)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->SamplerParameterIuiv(sampler, pname, param);
+}
+
+inline void QOpenGLExtension_ARB_sampler_objects::glSamplerParameterIiv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->SamplerParameterIiv(sampler, pname, param);
+}
+
+inline void QOpenGLExtension_ARB_sampler_objects::glSamplerParameterfv(GLuint sampler, GLenum pname, const GLfloat *param)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->SamplerParameterfv(sampler, pname, param);
+}
+
+inline void QOpenGLExtension_ARB_sampler_objects::glSamplerParameterf(GLuint sampler, GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->SamplerParameterf(sampler, pname, param);
+}
+
+inline void QOpenGLExtension_ARB_sampler_objects::glSamplerParameteriv(GLuint sampler, GLenum pname, const GLint *param)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->SamplerParameteriv(sampler, pname, param);
+}
+
+inline void QOpenGLExtension_ARB_sampler_objects::glSamplerParameteri(GLuint sampler, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->SamplerParameteri(sampler, pname, param);
+}
+
+inline void QOpenGLExtension_ARB_sampler_objects::glBindSampler(GLuint unit, GLuint sampler)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->BindSampler(unit, sampler);
+}
+
+inline GLboolean QOpenGLExtension_ARB_sampler_objects::glIsSampler(GLuint sampler)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ return d->IsSampler(sampler);
+}
+
+inline void QOpenGLExtension_ARB_sampler_objects::glDeleteSamplers(GLsizei count, const GLuint *samplers)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->DeleteSamplers(count, samplers);
+}
+
+inline void QOpenGLExtension_ARB_sampler_objects::glGenSamplers(GLsizei count, GLuint *samplers)
+{
+ Q_D(QOpenGLExtension_ARB_sampler_objects);
+ d->GenSamplers(count, samplers);
+}
+
+class QOpenGLExtension_ARB_separate_shader_objectsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetProgramPipelineInfoLog)(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void (QOPENGLF_APIENTRYP ValidateProgramPipeline)(GLuint pipeline);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4x3dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3x4dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4x2dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2x4dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3x2dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2x3dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4x3fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3x4fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4x2fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2x4fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3x2fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2x3fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2dv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2fv)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4uiv)(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4ui)(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void (QOPENGLF_APIENTRYP ProgramUniform4dv)(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4d)(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+ void (QOPENGLF_APIENTRYP ProgramUniform4fv)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4f)(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void (QOPENGLF_APIENTRYP ProgramUniform4iv)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4i)(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void (QOPENGLF_APIENTRYP ProgramUniform3uiv)(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3ui)(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void (QOPENGLF_APIENTRYP ProgramUniform3dv)(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3d)(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+ void (QOPENGLF_APIENTRYP ProgramUniform3fv)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3f)(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void (QOPENGLF_APIENTRYP ProgramUniform3iv)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3i)(GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+ void (QOPENGLF_APIENTRYP ProgramUniform2uiv)(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2ui)(GLuint program, GLint location, GLuint v0, GLuint v1);
+ void (QOPENGLF_APIENTRYP ProgramUniform2dv)(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2d)(GLuint program, GLint location, GLdouble v0, GLdouble v1);
+ void (QOPENGLF_APIENTRYP ProgramUniform2fv)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2f)(GLuint program, GLint location, GLfloat v0, GLfloat v1);
+ void (QOPENGLF_APIENTRYP ProgramUniform2iv)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2i)(GLuint program, GLint location, GLint v0, GLint v1);
+ void (QOPENGLF_APIENTRYP ProgramUniform1uiv)(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1ui)(GLuint program, GLint location, GLuint v0);
+ void (QOPENGLF_APIENTRYP ProgramUniform1dv)(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1d)(GLuint program, GLint location, GLdouble v0);
+ void (QOPENGLF_APIENTRYP ProgramUniform1fv)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1f)(GLuint program, GLint location, GLfloat v0);
+ void (QOPENGLF_APIENTRYP ProgramUniform1iv)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1i)(GLuint program, GLint location, GLint v0);
+ void (QOPENGLF_APIENTRYP GetProgramPipelineiv)(GLuint pipeline, GLenum pname, GLint *params);
+ GLboolean (QOPENGLF_APIENTRYP IsProgramPipeline)(GLuint pipeline);
+ void (QOPENGLF_APIENTRYP GenProgramPipelines)(GLsizei n, GLuint *pipelines);
+ void (QOPENGLF_APIENTRYP DeleteProgramPipelines)(GLsizei n, const GLuint *pipelines);
+ void (QOPENGLF_APIENTRYP BindProgramPipeline)(GLuint pipeline);
+ GLuint (QOPENGLF_APIENTRYP CreateShaderProgramv)(GLenum type, GLsizei count, const GLchar* const *strings);
+ void (QOPENGLF_APIENTRYP ActiveShaderProgram)(GLuint pipeline, GLuint program);
+ void (QOPENGLF_APIENTRYP UseProgramStages)(GLuint pipeline, GLbitfield stages, GLuint program);
+};
+
+class QOpenGLExtension_ARB_separate_shader_objects : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_separate_shader_objects();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+ void glValidateProgramPipeline(GLuint pipeline);
+ void glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+ void glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+ void glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+ void glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1);
+ void glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1);
+ void glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1);
+ void glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1);
+ void glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform1ui(GLuint program, GLint location, GLuint v0);
+ void glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform1d(GLuint program, GLint location, GLdouble v0);
+ void glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform1f(GLuint program, GLint location, GLfloat v0);
+ void glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform1i(GLuint program, GLint location, GLint v0);
+ void glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params);
+ GLboolean glIsProgramPipeline(GLuint pipeline);
+ void glGenProgramPipelines(GLsizei n, GLuint *pipelines);
+ void glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines);
+ void glBindProgramPipeline(GLuint pipeline);
+ GLuint glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings);
+ void glActiveShaderProgram(GLuint pipeline, GLuint program);
+ void glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_separate_shader_objects)
+};
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glGetProgramPipelineInfoLog(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->GetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glValidateProgramPipeline(GLuint pipeline)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ValidateProgramPipeline(pipeline);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix4x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix3x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix4x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix2x4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix3x2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix2x3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix4x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix3x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix4x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix2x4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix3x2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix2x3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix4dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix3dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix2dv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix4fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix3fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniformMatrix2fv(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform4uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform4uiv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform4ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform4dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform4dv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform4d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform4fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform4fv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform4f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform4iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform4iv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform4i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform3uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform3uiv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform3ui(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform3dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform3dv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform3d(GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform3d(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform3fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform3fv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform3f(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform3f(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform3iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform3iv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform3i(GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform3i(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform2uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform2uiv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform2ui(GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform2ui(program, location, v0, v1);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform2dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform2dv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform2d(GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform2d(program, location, v0, v1);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform2fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform2fv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform2f(GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform2f(program, location, v0, v1);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform2iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform2iv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform2i(GLuint program, GLint location, GLint v0, GLint v1)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform2i(program, location, v0, v1);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform1uiv(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform1uiv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform1ui(GLuint program, GLint location, GLuint v0)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform1ui(program, location, v0);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform1dv(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform1dv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform1d(GLuint program, GLint location, GLdouble v0)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform1d(program, location, v0);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform1fv(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform1fv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform1f(GLuint program, GLint location, GLfloat v0)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform1f(program, location, v0);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform1iv(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform1iv(program, location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glProgramUniform1i(GLuint program, GLint location, GLint v0)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ProgramUniform1i(program, location, v0);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glGetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->GetProgramPipelineiv(pipeline, pname, params);
+}
+
+inline GLboolean QOpenGLExtension_ARB_separate_shader_objects::glIsProgramPipeline(GLuint pipeline)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ return d->IsProgramPipeline(pipeline);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glGenProgramPipelines(GLsizei n, GLuint *pipelines)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->GenProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glDeleteProgramPipelines(GLsizei n, const GLuint *pipelines)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->DeleteProgramPipelines(n, pipelines);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glBindProgramPipeline(GLuint pipeline)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->BindProgramPipeline(pipeline);
+}
+
+inline GLuint QOpenGLExtension_ARB_separate_shader_objects::glCreateShaderProgramv(GLenum type, GLsizei count, const GLchar* const *strings)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ return d->CreateShaderProgramv(type, count, strings);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glActiveShaderProgram(GLuint pipeline, GLuint program)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->ActiveShaderProgram(pipeline, program);
+}
+
+inline void QOpenGLExtension_ARB_separate_shader_objects::glUseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ Q_D(QOpenGLExtension_ARB_separate_shader_objects);
+ d->UseProgramStages(pipeline, stages, program);
+}
+
+class QOpenGLExtension_ARB_shader_atomic_countersPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetActiveAtomicCounterBufferiv)(GLuint program, GLuint bufferIndex, GLenum pname, GLint *params);
+};
+
+class QOpenGLExtension_ARB_shader_atomic_counters : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_shader_atomic_counters();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetActiveAtomicCounterBufferiv(GLuint program, GLuint bufferIndex, GLenum pname, GLint *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_shader_atomic_counters)
+};
+
+inline void QOpenGLExtension_ARB_shader_atomic_counters::glGetActiveAtomicCounterBufferiv(GLuint program, GLuint bufferIndex, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_shader_atomic_counters);
+ d->GetActiveAtomicCounterBufferiv(program, bufferIndex, pname, params);
+}
+
+class QOpenGLExtension_ARB_shader_image_load_storePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MemoryBarrier)(GLbitfield barriers);
+ void (QOPENGLF_APIENTRYP BindImageTexture)(GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
+};
+
+class QOpenGLExtension_ARB_shader_image_load_store : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_shader_image_load_store();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMemoryBarrier(GLbitfield barriers);
+ void glBindImageTexture(GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_shader_image_load_store)
+};
+
+inline void QOpenGLExtension_ARB_shader_image_load_store::glMemoryBarrier(GLbitfield barriers)
+{
+ Q_D(QOpenGLExtension_ARB_shader_image_load_store);
+ d->MemoryBarrier(barriers);
+}
+
+inline void QOpenGLExtension_ARB_shader_image_load_store::glBindImageTexture(GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format)
+{
+ Q_D(QOpenGLExtension_ARB_shader_image_load_store);
+ d->BindImageTexture(unit, texture, level, layered, layer, access, format);
+}
+
+class QOpenGLExtension_ARB_shader_objectsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetShaderSourceARB)(GLhandleARB obj, GLsizei maxLength, GLsizei *length, GLcharARB *source);
+ void (QOPENGLF_APIENTRYP GetUniformivARB)(GLhandleARB programObj, GLint location, GLint *params);
+ void (QOPENGLF_APIENTRYP GetUniformfvARB)(GLhandleARB programObj, GLint location, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetActiveUniformARB)(GLhandleARB programObj, GLuint index, GLsizei maxLength, GLsizei *length, GLint *size, GLenum *type, GLcharARB *name);
+ GLint (QOPENGLF_APIENTRYP GetUniformLocationARB)(GLhandleARB programObj, const GLcharARB *name);
+ void (QOPENGLF_APIENTRYP GetAttachedObjectsARB)(GLhandleARB containerObj, GLsizei maxCount, GLsizei *count, GLhandleARB *obj);
+ void (QOPENGLF_APIENTRYP GetInfoLogARB)(GLhandleARB obj, GLsizei maxLength, GLsizei *length, GLcharARB *infoLog);
+ void (QOPENGLF_APIENTRYP GetObjectParameterivARB)(GLhandleARB obj, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetObjectParameterfvARB)(GLhandleARB obj, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP UniformMatrix4fvARB)(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix3fvARB)(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP UniformMatrix2fvARB)(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP Uniform4ivARB)(GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP Uniform3ivARB)(GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP Uniform2ivARB)(GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP Uniform1ivARB)(GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP Uniform4fvARB)(GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP Uniform3fvARB)(GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP Uniform2fvARB)(GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP Uniform1fvARB)(GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP Uniform4iARB)(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void (QOPENGLF_APIENTRYP Uniform3iARB)(GLint location, GLint v0, GLint v1, GLint v2);
+ void (QOPENGLF_APIENTRYP Uniform2iARB)(GLint location, GLint v0, GLint v1);
+ void (QOPENGLF_APIENTRYP Uniform1iARB)(GLint location, GLint v0);
+ void (QOPENGLF_APIENTRYP Uniform4fARB)(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void (QOPENGLF_APIENTRYP Uniform3fARB)(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void (QOPENGLF_APIENTRYP Uniform2fARB)(GLint location, GLfloat v0, GLfloat v1);
+ void (QOPENGLF_APIENTRYP Uniform1fARB)(GLint location, GLfloat v0);
+ void (QOPENGLF_APIENTRYP ValidateProgramARB)(GLhandleARB programObj);
+ void (QOPENGLF_APIENTRYP UseProgramObjectARB)(GLhandleARB programObj);
+ void (QOPENGLF_APIENTRYP LinkProgramARB)(GLhandleARB programObj);
+ void (QOPENGLF_APIENTRYP AttachObjectARB)(GLhandleARB containerObj, GLhandleARB obj);
+ GLhandleARB (QOPENGLF_APIENTRYP CreateProgramObjectARB)();
+ void (QOPENGLF_APIENTRYP CompileShaderARB)(GLhandleARB shaderObj);
+ void (QOPENGLF_APIENTRYP ShaderSourceARB)(GLhandleARB shaderObj, GLsizei count, const GLcharARB* *string, const GLint *length);
+ GLhandleARB (QOPENGLF_APIENTRYP CreateShaderObjectARB)(GLenum shaderType);
+ void (QOPENGLF_APIENTRYP DetachObjectARB)(GLhandleARB containerObj, GLhandleARB attachedObj);
+ GLhandleARB (QOPENGLF_APIENTRYP GetHandleARB)(GLenum pname);
+ void (QOPENGLF_APIENTRYP DeleteObjectARB)(GLhandleARB obj);
+};
+
+class QOpenGLExtension_ARB_shader_objects : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_shader_objects();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetShaderSourceARB(GLhandleARB obj, GLsizei maxLength, GLsizei *length, GLcharARB *source);
+ void glGetUniformivARB(GLhandleARB programObj, GLint location, GLint *params);
+ void glGetUniformfvARB(GLhandleARB programObj, GLint location, GLfloat *params);
+ void glGetActiveUniformARB(GLhandleARB programObj, GLuint index, GLsizei maxLength, GLsizei *length, GLint *size, GLenum *type, GLcharARB *name);
+ GLint glGetUniformLocationARB(GLhandleARB programObj, const GLcharARB *name);
+ void glGetAttachedObjectsARB(GLhandleARB containerObj, GLsizei maxCount, GLsizei *count, GLhandleARB *obj);
+ void glGetInfoLogARB(GLhandleARB obj, GLsizei maxLength, GLsizei *length, GLcharARB *infoLog);
+ void glGetObjectParameterivARB(GLhandleARB obj, GLenum pname, GLint *params);
+ void glGetObjectParameterfvARB(GLhandleARB obj, GLenum pname, GLfloat *params);
+ void glUniformMatrix4fvARB(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix3fvARB(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniformMatrix2fvARB(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glUniform4ivARB(GLint location, GLsizei count, const GLint *value);
+ void glUniform3ivARB(GLint location, GLsizei count, const GLint *value);
+ void glUniform2ivARB(GLint location, GLsizei count, const GLint *value);
+ void glUniform1ivARB(GLint location, GLsizei count, const GLint *value);
+ void glUniform4fvARB(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform3fvARB(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform2fvARB(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform1fvARB(GLint location, GLsizei count, const GLfloat *value);
+ void glUniform4iARB(GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glUniform3iARB(GLint location, GLint v0, GLint v1, GLint v2);
+ void glUniform2iARB(GLint location, GLint v0, GLint v1);
+ void glUniform1iARB(GLint location, GLint v0);
+ void glUniform4fARB(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glUniform3fARB(GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glUniform2fARB(GLint location, GLfloat v0, GLfloat v1);
+ void glUniform1fARB(GLint location, GLfloat v0);
+ void glValidateProgramARB(GLhandleARB programObj);
+ void glUseProgramObjectARB(GLhandleARB programObj);
+ void glLinkProgramARB(GLhandleARB programObj);
+ void glAttachObjectARB(GLhandleARB containerObj, GLhandleARB obj);
+ GLhandleARB glCreateProgramObjectARB();
+ void glCompileShaderARB(GLhandleARB shaderObj);
+ void glShaderSourceARB(GLhandleARB shaderObj, GLsizei count, const GLcharARB* *string, const GLint *length);
+ GLhandleARB glCreateShaderObjectARB(GLenum shaderType);
+ void glDetachObjectARB(GLhandleARB containerObj, GLhandleARB attachedObj);
+ GLhandleARB glGetHandleARB(GLenum pname);
+ void glDeleteObjectARB(GLhandleARB obj);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_shader_objects)
+};
+
+inline void QOpenGLExtension_ARB_shader_objects::glGetShaderSourceARB(GLhandleARB obj, GLsizei maxLength, GLsizei *length, GLcharARB *source)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->GetShaderSourceARB(obj, maxLength, length, source);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glGetUniformivARB(GLhandleARB programObj, GLint location, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->GetUniformivARB(programObj, location, params);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glGetUniformfvARB(GLhandleARB programObj, GLint location, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->GetUniformfvARB(programObj, location, params);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glGetActiveUniformARB(GLhandleARB programObj, GLuint index, GLsizei maxLength, GLsizei *length, GLint *size, GLenum *type, GLcharARB *name)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->GetActiveUniformARB(programObj, index, maxLength, length, size, type, name);
+}
+
+inline GLint QOpenGLExtension_ARB_shader_objects::glGetUniformLocationARB(GLhandleARB programObj, const GLcharARB *name)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ return d->GetUniformLocationARB(programObj, name);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glGetAttachedObjectsARB(GLhandleARB containerObj, GLsizei maxCount, GLsizei *count, GLhandleARB *obj)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->GetAttachedObjectsARB(containerObj, maxCount, count, obj);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glGetInfoLogARB(GLhandleARB obj, GLsizei maxLength, GLsizei *length, GLcharARB *infoLog)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->GetInfoLogARB(obj, maxLength, length, infoLog);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glGetObjectParameterivARB(GLhandleARB obj, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->GetObjectParameterivARB(obj, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glGetObjectParameterfvARB(GLhandleARB obj, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->GetObjectParameterfvARB(obj, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniformMatrix4fvARB(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->UniformMatrix4fvARB(location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniformMatrix3fvARB(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->UniformMatrix3fvARB(location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniformMatrix2fvARB(GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->UniformMatrix2fvARB(location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform4ivARB(GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform4ivARB(location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform3ivARB(GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform3ivARB(location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform2ivARB(GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform2ivARB(location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform1ivARB(GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform1ivARB(location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform4fvARB(GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform4fvARB(location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform3fvARB(GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform3fvARB(location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform2fvARB(GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform2fvARB(location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform1fvARB(GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform1fvARB(location, count, value);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform4iARB(GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform4iARB(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform3iARB(GLint location, GLint v0, GLint v1, GLint v2)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform3iARB(location, v0, v1, v2);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform2iARB(GLint location, GLint v0, GLint v1)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform2iARB(location, v0, v1);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform1iARB(GLint location, GLint v0)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform1iARB(location, v0);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform4fARB(GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform4fARB(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform3fARB(GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform3fARB(location, v0, v1, v2);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform2fARB(GLint location, GLfloat v0, GLfloat v1)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform2fARB(location, v0, v1);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUniform1fARB(GLint location, GLfloat v0)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->Uniform1fARB(location, v0);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glValidateProgramARB(GLhandleARB programObj)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->ValidateProgramARB(programObj);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glUseProgramObjectARB(GLhandleARB programObj)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->UseProgramObjectARB(programObj);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glLinkProgramARB(GLhandleARB programObj)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->LinkProgramARB(programObj);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glAttachObjectARB(GLhandleARB containerObj, GLhandleARB obj)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->AttachObjectARB(containerObj, obj);
+}
+
+inline GLhandleARB QOpenGLExtension_ARB_shader_objects::glCreateProgramObjectARB()
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ return d->CreateProgramObjectARB();
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glCompileShaderARB(GLhandleARB shaderObj)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->CompileShaderARB(shaderObj);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glShaderSourceARB(GLhandleARB shaderObj, GLsizei count, const GLcharARB* *string, const GLint *length)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->ShaderSourceARB(shaderObj, count, string, length);
+}
+
+inline GLhandleARB QOpenGLExtension_ARB_shader_objects::glCreateShaderObjectARB(GLenum shaderType)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ return d->CreateShaderObjectARB(shaderType);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glDetachObjectARB(GLhandleARB containerObj, GLhandleARB attachedObj)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->DetachObjectARB(containerObj, attachedObj);
+}
+
+inline GLhandleARB QOpenGLExtension_ARB_shader_objects::glGetHandleARB(GLenum pname)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ return d->GetHandleARB(pname);
+}
+
+inline void QOpenGLExtension_ARB_shader_objects::glDeleteObjectARB(GLhandleARB obj)
+{
+ Q_D(QOpenGLExtension_ARB_shader_objects);
+ d->DeleteObjectARB(obj);
+}
+
+class QOpenGLExtension_ARB_shader_storage_buffer_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ShaderStorageBlockBinding)(GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding);
+};
+
+class QOpenGLExtension_ARB_shader_storage_buffer_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_shader_storage_buffer_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glShaderStorageBlockBinding(GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_shader_storage_buffer_object)
+};
+
+inline void QOpenGLExtension_ARB_shader_storage_buffer_object::glShaderStorageBlockBinding(GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding)
+{
+ Q_D(QOpenGLExtension_ARB_shader_storage_buffer_object);
+ d->ShaderStorageBlockBinding(program, storageBlockIndex, storageBlockBinding);
+}
+
+class QOpenGLExtension_ARB_shader_subroutinePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetProgramStageiv)(GLuint program, GLenum shadertype, GLenum pname, GLint *values);
+ void (QOPENGLF_APIENTRYP GetUniformSubroutineuiv)(GLenum shadertype, GLint location, GLuint *params);
+ void (QOPENGLF_APIENTRYP UniformSubroutinesuiv)(GLenum shadertype, GLsizei count, const GLuint *indices);
+ void (QOPENGLF_APIENTRYP GetActiveSubroutineName)(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void (QOPENGLF_APIENTRYP GetActiveSubroutineUniformName)(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void (QOPENGLF_APIENTRYP GetActiveSubroutineUniformiv)(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
+ GLuint (QOPENGLF_APIENTRYP GetSubroutineIndex)(GLuint program, GLenum shadertype, const GLchar *name);
+ GLint (QOPENGLF_APIENTRYP GetSubroutineUniformLocation)(GLuint program, GLenum shadertype, const GLchar *name);
+};
+
+class QOpenGLExtension_ARB_shader_subroutine : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_shader_subroutine();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values);
+ void glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params);
+ void glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices);
+ void glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name);
+ void glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values);
+ GLuint glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name);
+ GLint glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_shader_subroutine)
+};
+
+inline void QOpenGLExtension_ARB_shader_subroutine::glGetProgramStageiv(GLuint program, GLenum shadertype, GLenum pname, GLint *values)
+{
+ Q_D(QOpenGLExtension_ARB_shader_subroutine);
+ d->GetProgramStageiv(program, shadertype, pname, values);
+}
+
+inline void QOpenGLExtension_ARB_shader_subroutine::glGetUniformSubroutineuiv(GLenum shadertype, GLint location, GLuint *params)
+{
+ Q_D(QOpenGLExtension_ARB_shader_subroutine);
+ d->GetUniformSubroutineuiv(shadertype, location, params);
+}
+
+inline void QOpenGLExtension_ARB_shader_subroutine::glUniformSubroutinesuiv(GLenum shadertype, GLsizei count, const GLuint *indices)
+{
+ Q_D(QOpenGLExtension_ARB_shader_subroutine);
+ d->UniformSubroutinesuiv(shadertype, count, indices);
+}
+
+inline void QOpenGLExtension_ARB_shader_subroutine::glGetActiveSubroutineName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ Q_D(QOpenGLExtension_ARB_shader_subroutine);
+ d->GetActiveSubroutineName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLExtension_ARB_shader_subroutine::glGetActiveSubroutineUniformName(GLuint program, GLenum shadertype, GLuint index, GLsizei bufsize, GLsizei *length, GLchar *name)
+{
+ Q_D(QOpenGLExtension_ARB_shader_subroutine);
+ d->GetActiveSubroutineUniformName(program, shadertype, index, bufsize, length, name);
+}
+
+inline void QOpenGLExtension_ARB_shader_subroutine::glGetActiveSubroutineUniformiv(GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint *values)
+{
+ Q_D(QOpenGLExtension_ARB_shader_subroutine);
+ d->GetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+inline GLuint QOpenGLExtension_ARB_shader_subroutine::glGetSubroutineIndex(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_ARB_shader_subroutine);
+ return d->GetSubroutineIndex(program, shadertype, name);
+}
+
+inline GLint QOpenGLExtension_ARB_shader_subroutine::glGetSubroutineUniformLocation(GLuint program, GLenum shadertype, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_ARB_shader_subroutine);
+ return d->GetSubroutineUniformLocation(program, shadertype, name);
+}
+
+class QOpenGLExtension_ARB_shading_language_includePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetNamedStringivARB)(GLint namelen, const GLchar *name, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetNamedStringARB)(GLint namelen, const GLchar *name, GLsizei bufSize, GLint *stringlen, GLchar *string);
+ GLboolean (QOPENGLF_APIENTRYP IsNamedStringARB)(GLint namelen, const GLchar *name);
+ void (QOPENGLF_APIENTRYP CompileShaderIncludeARB)(GLuint shader, GLsizei count, const GLchar* *path, const GLint *length);
+ void (QOPENGLF_APIENTRYP DeleteNamedStringARB)(GLint namelen, const GLchar *name);
+ void (QOPENGLF_APIENTRYP NamedStringARB)(GLenum type, GLint namelen, const GLchar *name, GLint stringlen, const GLchar *string);
+};
+
+class QOpenGLExtension_ARB_shading_language_include : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_shading_language_include();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetNamedStringivARB(GLint namelen, const GLchar *name, GLenum pname, GLint *params);
+ void glGetNamedStringARB(GLint namelen, const GLchar *name, GLsizei bufSize, GLint *stringlen, GLchar *string);
+ GLboolean glIsNamedStringARB(GLint namelen, const GLchar *name);
+ void glCompileShaderIncludeARB(GLuint shader, GLsizei count, const GLchar* *path, const GLint *length);
+ void glDeleteNamedStringARB(GLint namelen, const GLchar *name);
+ void glNamedStringARB(GLenum type, GLint namelen, const GLchar *name, GLint stringlen, const GLchar *string);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_shading_language_include)
+};
+
+inline void QOpenGLExtension_ARB_shading_language_include::glGetNamedStringivARB(GLint namelen, const GLchar *name, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_shading_language_include);
+ d->GetNamedStringivARB(namelen, name, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_shading_language_include::glGetNamedStringARB(GLint namelen, const GLchar *name, GLsizei bufSize, GLint *stringlen, GLchar *string)
+{
+ Q_D(QOpenGLExtension_ARB_shading_language_include);
+ d->GetNamedStringARB(namelen, name, bufSize, stringlen, string);
+}
+
+inline GLboolean QOpenGLExtension_ARB_shading_language_include::glIsNamedStringARB(GLint namelen, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_ARB_shading_language_include);
+ return d->IsNamedStringARB(namelen, name);
+}
+
+inline void QOpenGLExtension_ARB_shading_language_include::glCompileShaderIncludeARB(GLuint shader, GLsizei count, const GLchar* *path, const GLint *length)
+{
+ Q_D(QOpenGLExtension_ARB_shading_language_include);
+ d->CompileShaderIncludeARB(shader, count, path, length);
+}
+
+inline void QOpenGLExtension_ARB_shading_language_include::glDeleteNamedStringARB(GLint namelen, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_ARB_shading_language_include);
+ d->DeleteNamedStringARB(namelen, name);
+}
+
+inline void QOpenGLExtension_ARB_shading_language_include::glNamedStringARB(GLenum type, GLint namelen, const GLchar *name, GLint stringlen, const GLchar *string)
+{
+ Q_D(QOpenGLExtension_ARB_shading_language_include);
+ d->NamedStringARB(type, namelen, name, stringlen, string);
+}
+
+class QOpenGLExtension_ARB_syncPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetSynciv)(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void (QOPENGLF_APIENTRYP GetInteger64v)(GLenum pname, GLint64 *params);
+ void (QOPENGLF_APIENTRYP WaitSync)(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum (QOPENGLF_APIENTRYP ClientWaitSync)(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void (QOPENGLF_APIENTRYP DeleteSync)(GLsync sync);
+ GLboolean (QOPENGLF_APIENTRYP IsSync)(GLsync sync);
+ GLsync (QOPENGLF_APIENTRYP FenceSync)(GLenum condition, GLbitfield flags);
+};
+
+class QOpenGLExtension_ARB_sync : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_sync();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glGetInteger64v(GLenum pname, GLint64 *params);
+ void glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ GLenum glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout);
+ void glDeleteSync(GLsync sync);
+ GLboolean glIsSync(GLsync sync);
+ GLsync glFenceSync(GLenum condition, GLbitfield flags);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_sync)
+};
+
+inline void QOpenGLExtension_ARB_sync::glGetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ Q_D(QOpenGLExtension_ARB_sync);
+ d->GetSynciv(sync, pname, bufSize, length, values);
+}
+
+inline void QOpenGLExtension_ARB_sync::glGetInteger64v(GLenum pname, GLint64 *params)
+{
+ Q_D(QOpenGLExtension_ARB_sync);
+ d->GetInteger64v(pname, params);
+}
+
+inline void QOpenGLExtension_ARB_sync::glWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ Q_D(QOpenGLExtension_ARB_sync);
+ d->WaitSync(sync, flags, timeout);
+}
+
+inline GLenum QOpenGLExtension_ARB_sync::glClientWaitSync(GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ Q_D(QOpenGLExtension_ARB_sync);
+ return d->ClientWaitSync(sync, flags, timeout);
+}
+
+inline void QOpenGLExtension_ARB_sync::glDeleteSync(GLsync sync)
+{
+ Q_D(QOpenGLExtension_ARB_sync);
+ d->DeleteSync(sync);
+}
+
+inline GLboolean QOpenGLExtension_ARB_sync::glIsSync(GLsync sync)
+{
+ Q_D(QOpenGLExtension_ARB_sync);
+ return d->IsSync(sync);
+}
+
+inline GLsync QOpenGLExtension_ARB_sync::glFenceSync(GLenum condition, GLbitfield flags)
+{
+ Q_D(QOpenGLExtension_ARB_sync);
+ return d->FenceSync(condition, flags);
+}
+
+class QOpenGLExtension_ARB_tessellation_shaderPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP PatchParameterfv)(GLenum pname, const GLfloat *values);
+ void (QOPENGLF_APIENTRYP PatchParameteri)(GLenum pname, GLint value);
+};
+
+class QOpenGLExtension_ARB_tessellation_shader : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_tessellation_shader();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glPatchParameterfv(GLenum pname, const GLfloat *values);
+ void glPatchParameteri(GLenum pname, GLint value);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_tessellation_shader)
+};
+
+inline void QOpenGLExtension_ARB_tessellation_shader::glPatchParameterfv(GLenum pname, const GLfloat *values)
+{
+ Q_D(QOpenGLExtension_ARB_tessellation_shader);
+ d->PatchParameterfv(pname, values);
+}
+
+inline void QOpenGLExtension_ARB_tessellation_shader::glPatchParameteri(GLenum pname, GLint value)
+{
+ Q_D(QOpenGLExtension_ARB_tessellation_shader);
+ d->PatchParameteri(pname, value);
+}
+
+class QOpenGLExtension_ARB_texture_buffer_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexBufferARB)(GLenum target, GLenum internalformat, GLuint buffer);
+};
+
+class QOpenGLExtension_ARB_texture_buffer_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_texture_buffer_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexBufferARB(GLenum target, GLenum internalformat, GLuint buffer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_texture_buffer_object)
+};
+
+inline void QOpenGLExtension_ARB_texture_buffer_object::glTexBufferARB(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ Q_D(QOpenGLExtension_ARB_texture_buffer_object);
+ d->TexBufferARB(target, internalformat, buffer);
+}
+
+class QOpenGLExtension_ARB_texture_buffer_rangePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexBufferRange)(GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+};
+
+class QOpenGLExtension_ARB_texture_buffer_range : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_texture_buffer_range();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexBufferRange(GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_texture_buffer_range)
+};
+
+inline void QOpenGLExtension_ARB_texture_buffer_range::glTexBufferRange(GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ Q_D(QOpenGLExtension_ARB_texture_buffer_range);
+ d->TexBufferRange(target, internalformat, buffer, offset, size);
+}
+
+class QOpenGLExtension_ARB_texture_compressionPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetCompressedTexImageARB)(GLenum target, GLint level, GLvoid *img);
+ void (QOPENGLF_APIENTRYP CompressedTexSubImage1DARB)(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP CompressedTexSubImage2DARB)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP CompressedTexSubImage3DARB)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP CompressedTexImage1DARB)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP CompressedTexImage2DARB)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP CompressedTexImage3DARB)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+};
+
+class QOpenGLExtension_ARB_texture_compression : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_texture_compression();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetCompressedTexImageARB(GLenum target, GLint level, GLvoid *img);
+ void glCompressedTexSubImage1DARB(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage2DARB(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexSubImage3DARB(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage1DARB(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage2DARB(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
+ void glCompressedTexImage3DARB(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_texture_compression)
+};
+
+inline void QOpenGLExtension_ARB_texture_compression::glGetCompressedTexImageARB(GLenum target, GLint level, GLvoid *img)
+{
+ Q_D(QOpenGLExtension_ARB_texture_compression);
+ d->GetCompressedTexImageARB(target, level, img);
+}
+
+inline void QOpenGLExtension_ARB_texture_compression::glCompressedTexSubImage1DARB(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ Q_D(QOpenGLExtension_ARB_texture_compression);
+ d->CompressedTexSubImage1DARB(target, level, xoffset, width, format, imageSize, data);
+}
+
+inline void QOpenGLExtension_ARB_texture_compression::glCompressedTexSubImage2DARB(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ Q_D(QOpenGLExtension_ARB_texture_compression);
+ d->CompressedTexSubImage2DARB(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+inline void QOpenGLExtension_ARB_texture_compression::glCompressedTexSubImage3DARB(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data)
+{
+ Q_D(QOpenGLExtension_ARB_texture_compression);
+ d->CompressedTexSubImage3DARB(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLExtension_ARB_texture_compression::glCompressedTexImage1DARB(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ Q_D(QOpenGLExtension_ARB_texture_compression);
+ d->CompressedTexImage1DARB(target, level, internalformat, width, border, imageSize, data);
+}
+
+inline void QOpenGLExtension_ARB_texture_compression::glCompressedTexImage2DARB(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ Q_D(QOpenGLExtension_ARB_texture_compression);
+ d->CompressedTexImage2DARB(target, level, internalformat, width, height, border, imageSize, data);
+}
+
+inline void QOpenGLExtension_ARB_texture_compression::glCompressedTexImage3DARB(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data)
+{
+ Q_D(QOpenGLExtension_ARB_texture_compression);
+ d->CompressedTexImage3DARB(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+class QOpenGLExtension_ARB_texture_multisamplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP SampleMaski)(GLuint index, GLbitfield mask);
+ void (QOPENGLF_APIENTRYP GetMultisamplefv)(GLenum pname, GLuint index, GLfloat *val);
+ void (QOPENGLF_APIENTRYP TexImage3DMultisample)(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void (QOPENGLF_APIENTRYP TexImage2DMultisample)(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+};
+
+class QOpenGLExtension_ARB_texture_multisample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_texture_multisample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glSampleMaski(GLuint index, GLbitfield mask);
+ void glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val);
+ void glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_texture_multisample)
+};
+
+inline void QOpenGLExtension_ARB_texture_multisample::glSampleMaski(GLuint index, GLbitfield mask)
+{
+ Q_D(QOpenGLExtension_ARB_texture_multisample);
+ d->SampleMaski(index, mask);
+}
+
+inline void QOpenGLExtension_ARB_texture_multisample::glGetMultisamplefv(GLenum pname, GLuint index, GLfloat *val)
+{
+ Q_D(QOpenGLExtension_ARB_texture_multisample);
+ d->GetMultisamplefv(pname, index, val);
+}
+
+inline void QOpenGLExtension_ARB_texture_multisample::glTexImage3DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ Q_D(QOpenGLExtension_ARB_texture_multisample);
+ d->TexImage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLExtension_ARB_texture_multisample::glTexImage2DMultisample(GLenum target, GLsizei samples, GLint internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ Q_D(QOpenGLExtension_ARB_texture_multisample);
+ d->TexImage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+class QOpenGLExtension_ARB_texture_storagePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexStorage3D)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void (QOPENGLF_APIENTRYP TexStorage2D)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP TexStorage1D)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+};
+
+class QOpenGLExtension_ARB_texture_storage : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_texture_storage();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexStorage3D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void glTexStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void glTexStorage1D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_texture_storage)
+};
+
+inline void QOpenGLExtension_ARB_texture_storage::glTexStorage3D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ Q_D(QOpenGLExtension_ARB_texture_storage);
+ d->TexStorage3D(target, levels, internalformat, width, height, depth);
+}
+
+inline void QOpenGLExtension_ARB_texture_storage::glTexStorage2D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_ARB_texture_storage);
+ d->TexStorage2D(target, levels, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_ARB_texture_storage::glTexStorage1D(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width)
+{
+ Q_D(QOpenGLExtension_ARB_texture_storage);
+ d->TexStorage1D(target, levels, internalformat, width);
+}
+
+class QOpenGLExtension_ARB_texture_storage_multisamplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexStorage3DMultisample)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void (QOPENGLF_APIENTRYP TexStorage2DMultisample)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+};
+
+class QOpenGLExtension_ARB_texture_storage_multisample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_texture_storage_multisample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexStorage3DMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTexStorage2DMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_texture_storage_multisample)
+};
+
+inline void QOpenGLExtension_ARB_texture_storage_multisample::glTexStorage3DMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ Q_D(QOpenGLExtension_ARB_texture_storage_multisample);
+ d->TexStorage3DMultisample(target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLExtension_ARB_texture_storage_multisample::glTexStorage2DMultisample(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ Q_D(QOpenGLExtension_ARB_texture_storage_multisample);
+ d->TexStorage2DMultisample(target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+class QOpenGLExtension_ARB_texture_viewPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TextureView)(GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers);
+};
+
+class QOpenGLExtension_ARB_texture_view : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_texture_view();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTextureView(GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_texture_view)
+};
+
+inline void QOpenGLExtension_ARB_texture_view::glTextureView(GLuint texture, GLenum target, GLuint origtexture, GLenum internalformat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers)
+{
+ Q_D(QOpenGLExtension_ARB_texture_view);
+ d->TextureView(texture, target, origtexture, internalformat, minlevel, numlevels, minlayer, numlayers);
+}
+
+class QOpenGLExtension_ARB_timer_queryPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetQueryObjectui64v)(GLuint id, GLenum pname, GLuint64 *params);
+ void (QOPENGLF_APIENTRYP GetQueryObjecti64v)(GLuint id, GLenum pname, GLint64 *params);
+ void (QOPENGLF_APIENTRYP QueryCounter)(GLuint id, GLenum target);
+};
+
+class QOpenGLExtension_ARB_timer_query : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_timer_query();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params);
+ void glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params);
+ void glQueryCounter(GLuint id, GLenum target);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_timer_query)
+};
+
+inline void QOpenGLExtension_ARB_timer_query::glGetQueryObjectui64v(GLuint id, GLenum pname, GLuint64 *params)
+{
+ Q_D(QOpenGLExtension_ARB_timer_query);
+ d->GetQueryObjectui64v(id, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_timer_query::glGetQueryObjecti64v(GLuint id, GLenum pname, GLint64 *params)
+{
+ Q_D(QOpenGLExtension_ARB_timer_query);
+ d->GetQueryObjecti64v(id, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_timer_query::glQueryCounter(GLuint id, GLenum target)
+{
+ Q_D(QOpenGLExtension_ARB_timer_query);
+ d->QueryCounter(id, target);
+}
+
+class QOpenGLExtension_ARB_transform_feedback2Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawTransformFeedback)(GLenum mode, GLuint id);
+ void (QOPENGLF_APIENTRYP ResumeTransformFeedback)();
+ void (QOPENGLF_APIENTRYP PauseTransformFeedback)();
+ GLboolean (QOPENGLF_APIENTRYP IsTransformFeedback)(GLuint id);
+ void (QOPENGLF_APIENTRYP GenTransformFeedbacks)(GLsizei n, GLuint *ids);
+ void (QOPENGLF_APIENTRYP DeleteTransformFeedbacks)(GLsizei n, const GLuint *ids);
+ void (QOPENGLF_APIENTRYP BindTransformFeedback)(GLenum target, GLuint id);
+};
+
+class QOpenGLExtension_ARB_transform_feedback2 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_transform_feedback2();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawTransformFeedback(GLenum mode, GLuint id);
+ void glResumeTransformFeedback();
+ void glPauseTransformFeedback();
+ GLboolean glIsTransformFeedback(GLuint id);
+ void glGenTransformFeedbacks(GLsizei n, GLuint *ids);
+ void glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids);
+ void glBindTransformFeedback(GLenum target, GLuint id);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_transform_feedback2)
+};
+
+inline void QOpenGLExtension_ARB_transform_feedback2::glDrawTransformFeedback(GLenum mode, GLuint id)
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback2);
+ d->DrawTransformFeedback(mode, id);
+}
+
+inline void QOpenGLExtension_ARB_transform_feedback2::glResumeTransformFeedback()
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback2);
+ d->ResumeTransformFeedback();
+}
+
+inline void QOpenGLExtension_ARB_transform_feedback2::glPauseTransformFeedback()
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback2);
+ d->PauseTransformFeedback();
+}
+
+inline GLboolean QOpenGLExtension_ARB_transform_feedback2::glIsTransformFeedback(GLuint id)
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback2);
+ return d->IsTransformFeedback(id);
+}
+
+inline void QOpenGLExtension_ARB_transform_feedback2::glGenTransformFeedbacks(GLsizei n, GLuint *ids)
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback2);
+ d->GenTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLExtension_ARB_transform_feedback2::glDeleteTransformFeedbacks(GLsizei n, const GLuint *ids)
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback2);
+ d->DeleteTransformFeedbacks(n, ids);
+}
+
+inline void QOpenGLExtension_ARB_transform_feedback2::glBindTransformFeedback(GLenum target, GLuint id)
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback2);
+ d->BindTransformFeedback(target, id);
+}
+
+class QOpenGLExtension_ARB_transform_feedback3Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetQueryIndexediv)(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP EndQueryIndexed)(GLenum target, GLuint index);
+ void (QOPENGLF_APIENTRYP BeginQueryIndexed)(GLenum target, GLuint index, GLuint id);
+ void (QOPENGLF_APIENTRYP DrawTransformFeedbackStream)(GLenum mode, GLuint id, GLuint stream);
+};
+
+class QOpenGLExtension_ARB_transform_feedback3 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_transform_feedback3();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void glEndQueryIndexed(GLenum target, GLuint index);
+ void glBeginQueryIndexed(GLenum target, GLuint index, GLuint id);
+ void glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_transform_feedback3)
+};
+
+inline void QOpenGLExtension_ARB_transform_feedback3::glGetQueryIndexediv(GLenum target, GLuint index, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback3);
+ d->GetQueryIndexediv(target, index, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_transform_feedback3::glEndQueryIndexed(GLenum target, GLuint index)
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback3);
+ d->EndQueryIndexed(target, index);
+}
+
+inline void QOpenGLExtension_ARB_transform_feedback3::glBeginQueryIndexed(GLenum target, GLuint index, GLuint id)
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback3);
+ d->BeginQueryIndexed(target, index, id);
+}
+
+inline void QOpenGLExtension_ARB_transform_feedback3::glDrawTransformFeedbackStream(GLenum mode, GLuint id, GLuint stream)
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback3);
+ d->DrawTransformFeedbackStream(mode, id, stream);
+}
+
+class QOpenGLExtension_ARB_transform_feedback_instancedPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawTransformFeedbackStreamInstanced)(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
+ void (QOPENGLF_APIENTRYP DrawTransformFeedbackInstanced)(GLenum mode, GLuint id, GLsizei instancecount);
+};
+
+class QOpenGLExtension_ARB_transform_feedback_instanced : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_transform_feedback_instanced();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawTransformFeedbackStreamInstanced(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
+ void glDrawTransformFeedbackInstanced(GLenum mode, GLuint id, GLsizei instancecount);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_transform_feedback_instanced)
+};
+
+inline void QOpenGLExtension_ARB_transform_feedback_instanced::glDrawTransformFeedbackStreamInstanced(GLenum mode, GLuint id, GLuint stream, GLsizei instancecount)
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback_instanced);
+ d->DrawTransformFeedbackStreamInstanced(mode, id, stream, instancecount);
+}
+
+inline void QOpenGLExtension_ARB_transform_feedback_instanced::glDrawTransformFeedbackInstanced(GLenum mode, GLuint id, GLsizei instancecount)
+{
+ Q_D(QOpenGLExtension_ARB_transform_feedback_instanced);
+ d->DrawTransformFeedbackInstanced(mode, id, instancecount);
+}
+
+class QOpenGLExtension_ARB_transpose_matrixPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MultTransposeMatrixdARB)(const GLdouble *m);
+ void (QOPENGLF_APIENTRYP MultTransposeMatrixfARB)(const GLfloat *m);
+ void (QOPENGLF_APIENTRYP LoadTransposeMatrixdARB)(const GLdouble *m);
+ void (QOPENGLF_APIENTRYP LoadTransposeMatrixfARB)(const GLfloat *m);
+};
+
+class QOpenGLExtension_ARB_transpose_matrix : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_transpose_matrix();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMultTransposeMatrixdARB(const GLdouble *m);
+ void glMultTransposeMatrixfARB(const GLfloat *m);
+ void glLoadTransposeMatrixdARB(const GLdouble *m);
+ void glLoadTransposeMatrixfARB(const GLfloat *m);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_transpose_matrix)
+};
+
+inline void QOpenGLExtension_ARB_transpose_matrix::glMultTransposeMatrixdARB(const GLdouble *m)
+{
+ Q_D(QOpenGLExtension_ARB_transpose_matrix);
+ d->MultTransposeMatrixdARB(m);
+}
+
+inline void QOpenGLExtension_ARB_transpose_matrix::glMultTransposeMatrixfARB(const GLfloat *m)
+{
+ Q_D(QOpenGLExtension_ARB_transpose_matrix);
+ d->MultTransposeMatrixfARB(m);
+}
+
+inline void QOpenGLExtension_ARB_transpose_matrix::glLoadTransposeMatrixdARB(const GLdouble *m)
+{
+ Q_D(QOpenGLExtension_ARB_transpose_matrix);
+ d->LoadTransposeMatrixdARB(m);
+}
+
+inline void QOpenGLExtension_ARB_transpose_matrix::glLoadTransposeMatrixfARB(const GLfloat *m)
+{
+ Q_D(QOpenGLExtension_ARB_transpose_matrix);
+ d->LoadTransposeMatrixfARB(m);
+}
+
+class QOpenGLExtension_ARB_uniform_buffer_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP UniformBlockBinding)(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void (QOPENGLF_APIENTRYP GetActiveUniformBlockName)(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void (QOPENGLF_APIENTRYP GetActiveUniformBlockiv)(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint (QOPENGLF_APIENTRYP GetUniformBlockIndex)(GLuint program, const GLchar *uniformBlockName);
+ void (QOPENGLF_APIENTRYP GetActiveUniformName)(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void (QOPENGLF_APIENTRYP GetActiveUniformsiv)(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetUniformIndices)(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+};
+
+class QOpenGLExtension_ARB_uniform_buffer_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_uniform_buffer_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding);
+ void glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName);
+ void glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params);
+ GLuint glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName);
+ void glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName);
+ void glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params);
+ void glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_uniform_buffer_object)
+};
+
+inline void QOpenGLExtension_ARB_uniform_buffer_object::glUniformBlockBinding(GLuint program, GLuint uniformBlockIndex, GLuint uniformBlockBinding)
+{
+ Q_D(QOpenGLExtension_ARB_uniform_buffer_object);
+ d->UniformBlockBinding(program, uniformBlockIndex, uniformBlockBinding);
+}
+
+inline void QOpenGLExtension_ARB_uniform_buffer_object::glGetActiveUniformBlockName(GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformBlockName)
+{
+ Q_D(QOpenGLExtension_ARB_uniform_buffer_object);
+ d->GetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+inline void QOpenGLExtension_ARB_uniform_buffer_object::glGetActiveUniformBlockiv(GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_uniform_buffer_object);
+ d->GetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+inline GLuint QOpenGLExtension_ARB_uniform_buffer_object::glGetUniformBlockIndex(GLuint program, const GLchar *uniformBlockName)
+{
+ Q_D(QOpenGLExtension_ARB_uniform_buffer_object);
+ return d->GetUniformBlockIndex(program, uniformBlockName);
+}
+
+inline void QOpenGLExtension_ARB_uniform_buffer_object::glGetActiveUniformName(GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei *length, GLchar *uniformName)
+{
+ Q_D(QOpenGLExtension_ARB_uniform_buffer_object);
+ d->GetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+inline void QOpenGLExtension_ARB_uniform_buffer_object::glGetActiveUniformsiv(GLuint program, GLsizei uniformCount, const GLuint *uniformIndices, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_uniform_buffer_object);
+ d->GetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_uniform_buffer_object::glGetUniformIndices(GLuint program, GLsizei uniformCount, const GLchar* const *uniformNames, GLuint *uniformIndices)
+{
+ Q_D(QOpenGLExtension_ARB_uniform_buffer_object);
+ d->GetUniformIndices(program, uniformCount, uniformNames, uniformIndices);
+}
+
+class QOpenGLExtension_ARB_vertex_array_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLboolean (QOPENGLF_APIENTRYP IsVertexArray)(GLuint array);
+ void (QOPENGLF_APIENTRYP GenVertexArrays)(GLsizei n, GLuint *arrays);
+ void (QOPENGLF_APIENTRYP DeleteVertexArrays)(GLsizei n, const GLuint *arrays);
+ void (QOPENGLF_APIENTRYP BindVertexArray)(GLuint array);
+};
+
+class QOpenGLExtension_ARB_vertex_array_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_vertex_array_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLboolean glIsVertexArray(GLuint array);
+ void glGenVertexArrays(GLsizei n, GLuint *arrays);
+ void glDeleteVertexArrays(GLsizei n, const GLuint *arrays);
+ void glBindVertexArray(GLuint array);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_vertex_array_object)
+};
+
+inline GLboolean QOpenGLExtension_ARB_vertex_array_object::glIsVertexArray(GLuint array)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_array_object);
+ return d->IsVertexArray(array);
+}
+
+inline void QOpenGLExtension_ARB_vertex_array_object::glGenVertexArrays(GLsizei n, GLuint *arrays)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_array_object);
+ d->GenVertexArrays(n, arrays);
+}
+
+inline void QOpenGLExtension_ARB_vertex_array_object::glDeleteVertexArrays(GLsizei n, const GLuint *arrays)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_array_object);
+ d->DeleteVertexArrays(n, arrays);
+}
+
+inline void QOpenGLExtension_ARB_vertex_array_object::glBindVertexArray(GLuint array)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_array_object);
+ d->BindVertexArray(array);
+}
+
+class QOpenGLExtension_ARB_vertex_attrib_64bitPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetVertexAttribLdv)(GLuint index, GLenum pname, GLdouble *params);
+ void (QOPENGLF_APIENTRYP VertexAttribLPointer)(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP VertexAttribL4dv)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL3dv)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL2dv)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL1dv)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL4d)(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP VertexAttribL3d)(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP VertexAttribL2d)(GLuint index, GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP VertexAttribL1d)(GLuint index, GLdouble x);
+};
+
+class QOpenGLExtension_ARB_vertex_attrib_64bit : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_vertex_attrib_64bit();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params);
+ void glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glVertexAttribL4dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL3dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL2dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL1dv(GLuint index, const GLdouble *v);
+ void glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttribL1d(GLuint index, GLdouble x);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_vertex_attrib_64bit)
+};
+
+inline void QOpenGLExtension_ARB_vertex_attrib_64bit::glGetVertexAttribLdv(GLuint index, GLenum pname, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_64bit);
+ d->GetVertexAttribLdv(index, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_64bit::glVertexAttribLPointer(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_64bit);
+ d->VertexAttribLPointer(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_64bit::glVertexAttribL4dv(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_64bit);
+ d->VertexAttribL4dv(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_64bit::glVertexAttribL3dv(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_64bit);
+ d->VertexAttribL3dv(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_64bit::glVertexAttribL2dv(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_64bit);
+ d->VertexAttribL2dv(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_64bit::glVertexAttribL1dv(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_64bit);
+ d->VertexAttribL1dv(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_64bit::glVertexAttribL4d(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_64bit);
+ d->VertexAttribL4d(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_64bit::glVertexAttribL3d(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_64bit);
+ d->VertexAttribL3d(index, x, y, z);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_64bit::glVertexAttribL2d(GLuint index, GLdouble x, GLdouble y)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_64bit);
+ d->VertexAttribL2d(index, x, y);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_64bit::glVertexAttribL1d(GLuint index, GLdouble x)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_64bit);
+ d->VertexAttribL1d(index, x);
+}
+
+class QOpenGLExtension_ARB_vertex_attrib_bindingPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexBindingDivisor)(GLuint bindingindex, GLuint divisor);
+ void (QOPENGLF_APIENTRYP VertexAttribBinding)(GLuint attribindex, GLuint bindingindex);
+ void (QOPENGLF_APIENTRYP VertexAttribLFormat)(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void (QOPENGLF_APIENTRYP VertexAttribIFormat)(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void (QOPENGLF_APIENTRYP VertexAttribFormat)(GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset);
+ void (QOPENGLF_APIENTRYP BindVertexBuffer)(GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+};
+
+class QOpenGLExtension_ARB_vertex_attrib_binding : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_vertex_attrib_binding();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexBindingDivisor(GLuint bindingindex, GLuint divisor);
+ void glVertexAttribBinding(GLuint attribindex, GLuint bindingindex);
+ void glVertexAttribLFormat(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void glVertexAttribIFormat(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void glVertexAttribFormat(GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset);
+ void glBindVertexBuffer(GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_vertex_attrib_binding)
+};
+
+inline void QOpenGLExtension_ARB_vertex_attrib_binding::glVertexBindingDivisor(GLuint bindingindex, GLuint divisor)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_binding);
+ d->VertexBindingDivisor(bindingindex, divisor);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_binding::glVertexAttribBinding(GLuint attribindex, GLuint bindingindex)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_binding);
+ d->VertexAttribBinding(attribindex, bindingindex);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_binding::glVertexAttribLFormat(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_binding);
+ d->VertexAttribLFormat(attribindex, size, type, relativeoffset);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_binding::glVertexAttribIFormat(GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_binding);
+ d->VertexAttribIFormat(attribindex, size, type, relativeoffset);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_binding::glVertexAttribFormat(GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_binding);
+ d->VertexAttribFormat(attribindex, size, type, normalized, relativeoffset);
+}
+
+inline void QOpenGLExtension_ARB_vertex_attrib_binding::glBindVertexBuffer(GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_attrib_binding);
+ d->BindVertexBuffer(bindingindex, buffer, offset, stride);
+}
+
+class QOpenGLExtension_ARB_vertex_blendPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexBlendARB)(GLint count);
+ void (QOPENGLF_APIENTRYP WeightPointerARB)(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP WeightuivARB)(GLint size, const GLuint *weights);
+ void (QOPENGLF_APIENTRYP WeightusvARB)(GLint size, const GLushort *weights);
+ void (QOPENGLF_APIENTRYP WeightubvARB)(GLint size, const GLubyte *weights);
+ void (QOPENGLF_APIENTRYP WeightdvARB)(GLint size, const GLdouble *weights);
+ void (QOPENGLF_APIENTRYP WeightfvARB)(GLint size, const GLfloat *weights);
+ void (QOPENGLF_APIENTRYP WeightivARB)(GLint size, const GLint *weights);
+ void (QOPENGLF_APIENTRYP WeightsvARB)(GLint size, const GLshort *weights);
+ void (QOPENGLF_APIENTRYP WeightbvARB)(GLint size, const GLbyte *weights);
+};
+
+class QOpenGLExtension_ARB_vertex_blend : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_vertex_blend();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexBlendARB(GLint count);
+ void glWeightPointerARB(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glWeightuivARB(GLint size, const GLuint *weights);
+ void glWeightusvARB(GLint size, const GLushort *weights);
+ void glWeightubvARB(GLint size, const GLubyte *weights);
+ void glWeightdvARB(GLint size, const GLdouble *weights);
+ void glWeightfvARB(GLint size, const GLfloat *weights);
+ void glWeightivARB(GLint size, const GLint *weights);
+ void glWeightsvARB(GLint size, const GLshort *weights);
+ void glWeightbvARB(GLint size, const GLbyte *weights);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_vertex_blend)
+};
+
+inline void QOpenGLExtension_ARB_vertex_blend::glVertexBlendARB(GLint count)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_blend);
+ d->VertexBlendARB(count);
+}
+
+inline void QOpenGLExtension_ARB_vertex_blend::glWeightPointerARB(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_blend);
+ d->WeightPointerARB(size, type, stride, pointer);
+}
+
+inline void QOpenGLExtension_ARB_vertex_blend::glWeightuivARB(GLint size, const GLuint *weights)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_blend);
+ d->WeightuivARB(size, weights);
+}
+
+inline void QOpenGLExtension_ARB_vertex_blend::glWeightusvARB(GLint size, const GLushort *weights)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_blend);
+ d->WeightusvARB(size, weights);
+}
+
+inline void QOpenGLExtension_ARB_vertex_blend::glWeightubvARB(GLint size, const GLubyte *weights)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_blend);
+ d->WeightubvARB(size, weights);
+}
+
+inline void QOpenGLExtension_ARB_vertex_blend::glWeightdvARB(GLint size, const GLdouble *weights)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_blend);
+ d->WeightdvARB(size, weights);
+}
+
+inline void QOpenGLExtension_ARB_vertex_blend::glWeightfvARB(GLint size, const GLfloat *weights)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_blend);
+ d->WeightfvARB(size, weights);
+}
+
+inline void QOpenGLExtension_ARB_vertex_blend::glWeightivARB(GLint size, const GLint *weights)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_blend);
+ d->WeightivARB(size, weights);
+}
+
+inline void QOpenGLExtension_ARB_vertex_blend::glWeightsvARB(GLint size, const GLshort *weights)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_blend);
+ d->WeightsvARB(size, weights);
+}
+
+inline void QOpenGLExtension_ARB_vertex_blend::glWeightbvARB(GLint size, const GLbyte *weights)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_blend);
+ d->WeightbvARB(size, weights);
+}
+
+class QOpenGLExtension_ARB_vertex_buffer_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetBufferPointervARB)(GLenum target, GLenum pname, GLvoid* *params);
+ void (QOPENGLF_APIENTRYP GetBufferParameterivARB)(GLenum target, GLenum pname, GLint *params);
+ GLboolean (QOPENGLF_APIENTRYP UnmapBufferARB)(GLenum target);
+ GLvoid* (QOPENGLF_APIENTRYP MapBufferARB)(GLenum target, GLenum access);
+ void (QOPENGLF_APIENTRYP GetBufferSubDataARB)(GLenum target, GLintptrARB offset, GLsizeiptrARB size, GLvoid *data);
+ void (QOPENGLF_APIENTRYP BufferSubDataARB)(GLenum target, GLintptrARB offset, GLsizeiptrARB size, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP BufferDataARB)(GLenum target, GLsizeiptrARB size, const GLvoid *data, GLenum usage);
+ GLboolean (QOPENGLF_APIENTRYP IsBufferARB)(GLuint buffer);
+ void (QOPENGLF_APIENTRYP GenBuffersARB)(GLsizei n, GLuint *buffers);
+ void (QOPENGLF_APIENTRYP DeleteBuffersARB)(GLsizei n, const GLuint *buffers);
+ void (QOPENGLF_APIENTRYP BindBufferARB)(GLenum target, GLuint buffer);
+};
+
+class QOpenGLExtension_ARB_vertex_buffer_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_vertex_buffer_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetBufferPointervARB(GLenum target, GLenum pname, GLvoid* *params);
+ void glGetBufferParameterivARB(GLenum target, GLenum pname, GLint *params);
+ GLboolean glUnmapBufferARB(GLenum target);
+ GLvoid* glMapBufferARB(GLenum target, GLenum access);
+ void glGetBufferSubDataARB(GLenum target, GLintptrARB offset, GLsizeiptrARB size, GLvoid *data);
+ void glBufferSubDataARB(GLenum target, GLintptrARB offset, GLsizeiptrARB size, const GLvoid *data);
+ void glBufferDataARB(GLenum target, GLsizeiptrARB size, const GLvoid *data, GLenum usage);
+ GLboolean glIsBufferARB(GLuint buffer);
+ void glGenBuffersARB(GLsizei n, GLuint *buffers);
+ void glDeleteBuffersARB(GLsizei n, const GLuint *buffers);
+ void glBindBufferARB(GLenum target, GLuint buffer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_vertex_buffer_object)
+};
+
+inline void QOpenGLExtension_ARB_vertex_buffer_object::glGetBufferPointervARB(GLenum target, GLenum pname, GLvoid* *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_buffer_object);
+ d->GetBufferPointervARB(target, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_buffer_object::glGetBufferParameterivARB(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_buffer_object);
+ d->GetBufferParameterivARB(target, pname, params);
+}
+
+inline GLboolean QOpenGLExtension_ARB_vertex_buffer_object::glUnmapBufferARB(GLenum target)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_buffer_object);
+ return d->UnmapBufferARB(target);
+}
+
+inline GLvoid* QOpenGLExtension_ARB_vertex_buffer_object::glMapBufferARB(GLenum target, GLenum access)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_buffer_object);
+ return d->MapBufferARB(target, access);
+}
+
+inline void QOpenGLExtension_ARB_vertex_buffer_object::glGetBufferSubDataARB(GLenum target, GLintptrARB offset, GLsizeiptrARB size, GLvoid *data)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_buffer_object);
+ d->GetBufferSubDataARB(target, offset, size, data);
+}
+
+inline void QOpenGLExtension_ARB_vertex_buffer_object::glBufferSubDataARB(GLenum target, GLintptrARB offset, GLsizeiptrARB size, const GLvoid *data)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_buffer_object);
+ d->BufferSubDataARB(target, offset, size, data);
+}
+
+inline void QOpenGLExtension_ARB_vertex_buffer_object::glBufferDataARB(GLenum target, GLsizeiptrARB size, const GLvoid *data, GLenum usage)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_buffer_object);
+ d->BufferDataARB(target, size, data, usage);
+}
+
+inline GLboolean QOpenGLExtension_ARB_vertex_buffer_object::glIsBufferARB(GLuint buffer)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_buffer_object);
+ return d->IsBufferARB(buffer);
+}
+
+inline void QOpenGLExtension_ARB_vertex_buffer_object::glGenBuffersARB(GLsizei n, GLuint *buffers)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_buffer_object);
+ d->GenBuffersARB(n, buffers);
+}
+
+inline void QOpenGLExtension_ARB_vertex_buffer_object::glDeleteBuffersARB(GLsizei n, const GLuint *buffers)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_buffer_object);
+ d->DeleteBuffersARB(n, buffers);
+}
+
+inline void QOpenGLExtension_ARB_vertex_buffer_object::glBindBufferARB(GLenum target, GLuint buffer)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_buffer_object);
+ d->BindBufferARB(target, buffer);
+}
+
+class QOpenGLExtension_ARB_vertex_programPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLboolean (QOPENGLF_APIENTRYP IsProgramARB)(GLuint program);
+ void (QOPENGLF_APIENTRYP GetVertexAttribPointervARB)(GLuint index, GLenum pname, GLvoid* *pointer);
+ void (QOPENGLF_APIENTRYP GetVertexAttribivARB)(GLuint index, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetVertexAttribfvARB)(GLuint index, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetVertexAttribdvARB)(GLuint index, GLenum pname, GLdouble *params);
+ void (QOPENGLF_APIENTRYP GetProgramStringARB)(GLenum target, GLenum pname, GLvoid *string);
+ void (QOPENGLF_APIENTRYP GetProgramivARB)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetProgramLocalParameterfvARB)(GLenum target, GLuint index, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetProgramLocalParameterdvARB)(GLenum target, GLuint index, GLdouble *params);
+ void (QOPENGLF_APIENTRYP GetProgramEnvParameterfvARB)(GLenum target, GLuint index, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetProgramEnvParameterdvARB)(GLenum target, GLuint index, GLdouble *params);
+ void (QOPENGLF_APIENTRYP ProgramLocalParameter4fvARB)(GLenum target, GLuint index, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP ProgramLocalParameter4fARB)(GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP ProgramLocalParameter4dvARB)(GLenum target, GLuint index, const GLdouble *params);
+ void (QOPENGLF_APIENTRYP ProgramLocalParameter4dARB)(GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP ProgramEnvParameter4fvARB)(GLenum target, GLuint index, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP ProgramEnvParameter4fARB)(GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP ProgramEnvParameter4dvARB)(GLenum target, GLuint index, const GLdouble *params);
+ void (QOPENGLF_APIENTRYP ProgramEnvParameter4dARB)(GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP GenProgramsARB)(GLsizei n, GLuint *programs);
+ void (QOPENGLF_APIENTRYP DeleteProgramsARB)(GLsizei n, const GLuint *programs);
+ void (QOPENGLF_APIENTRYP BindProgramARB)(GLenum target, GLuint program);
+ void (QOPENGLF_APIENTRYP ProgramStringARB)(GLenum target, GLenum format, GLsizei len, const GLvoid *string);
+ void (QOPENGLF_APIENTRYP DisableVertexAttribArrayARB)(GLuint index);
+ void (QOPENGLF_APIENTRYP EnableVertexAttribArrayARB)(GLuint index);
+ void (QOPENGLF_APIENTRYP VertexAttribPointerARB)(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP VertexAttrib4usvARB)(GLuint index, const GLushort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4uivARB)(GLuint index, const GLuint *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4ubvARB)(GLuint index, const GLubyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4svARB)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4sARB)(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void (QOPENGLF_APIENTRYP VertexAttrib4ivARB)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4fvARB)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4fARB)(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP VertexAttrib4dvARB)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4dARB)(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP VertexAttrib4bvARB)(GLuint index, const GLbyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4NusvARB)(GLuint index, const GLushort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4NuivARB)(GLuint index, const GLuint *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4NubvARB)(GLuint index, const GLubyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4NubARB)(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void (QOPENGLF_APIENTRYP VertexAttrib4NsvARB)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4NivARB)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4NbvARB)(GLuint index, const GLbyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib3svARB)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib3sARB)(GLuint index, GLshort x, GLshort y, GLshort z);
+ void (QOPENGLF_APIENTRYP VertexAttrib3fvARB)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib3fARB)(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP VertexAttrib3dvARB)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib3dARB)(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP VertexAttrib2svARB)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib2sARB)(GLuint index, GLshort x, GLshort y);
+ void (QOPENGLF_APIENTRYP VertexAttrib2fvARB)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib2fARB)(GLuint index, GLfloat x, GLfloat y);
+ void (QOPENGLF_APIENTRYP VertexAttrib2dvARB)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib2dARB)(GLuint index, GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP VertexAttrib1svARB)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib1sARB)(GLuint index, GLshort x);
+ void (QOPENGLF_APIENTRYP VertexAttrib1fvARB)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib1fARB)(GLuint index, GLfloat x);
+ void (QOPENGLF_APIENTRYP VertexAttrib1dvARB)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib1dARB)(GLuint index, GLdouble x);
+};
+
+class QOpenGLExtension_ARB_vertex_program : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_vertex_program();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLboolean glIsProgramARB(GLuint program);
+ void glGetVertexAttribPointervARB(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribivARB(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfvARB(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdvARB(GLuint index, GLenum pname, GLdouble *params);
+ void glGetProgramStringARB(GLenum target, GLenum pname, GLvoid *string);
+ void glGetProgramivARB(GLenum target, GLenum pname, GLint *params);
+ void glGetProgramLocalParameterfvARB(GLenum target, GLuint index, GLfloat *params);
+ void glGetProgramLocalParameterdvARB(GLenum target, GLuint index, GLdouble *params);
+ void glGetProgramEnvParameterfvARB(GLenum target, GLuint index, GLfloat *params);
+ void glGetProgramEnvParameterdvARB(GLenum target, GLuint index, GLdouble *params);
+ void glProgramLocalParameter4fvARB(GLenum target, GLuint index, const GLfloat *params);
+ void glProgramLocalParameter4fARB(GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glProgramLocalParameter4dvARB(GLenum target, GLuint index, const GLdouble *params);
+ void glProgramLocalParameter4dARB(GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glProgramEnvParameter4fvARB(GLenum target, GLuint index, const GLfloat *params);
+ void glProgramEnvParameter4fARB(GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glProgramEnvParameter4dvARB(GLenum target, GLuint index, const GLdouble *params);
+ void glProgramEnvParameter4dARB(GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glGenProgramsARB(GLsizei n, GLuint *programs);
+ void glDeleteProgramsARB(GLsizei n, const GLuint *programs);
+ void glBindProgramARB(GLenum target, GLuint program);
+ void glProgramStringARB(GLenum target, GLenum format, GLsizei len, const GLvoid *string);
+ void glDisableVertexAttribArrayARB(GLuint index);
+ void glEnableVertexAttribArrayARB(GLuint index);
+ void glVertexAttribPointerARB(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
+ void glVertexAttrib4usvARB(GLuint index, const GLushort *v);
+ void glVertexAttrib4uivARB(GLuint index, const GLuint *v);
+ void glVertexAttrib4ubvARB(GLuint index, const GLubyte *v);
+ void glVertexAttrib4svARB(GLuint index, const GLshort *v);
+ void glVertexAttrib4sARB(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertexAttrib4ivARB(GLuint index, const GLint *v);
+ void glVertexAttrib4fvARB(GLuint index, const GLfloat *v);
+ void glVertexAttrib4fARB(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexAttrib4dvARB(GLuint index, const GLdouble *v);
+ void glVertexAttrib4dARB(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttrib4bvARB(GLuint index, const GLbyte *v);
+ void glVertexAttrib4NusvARB(GLuint index, const GLushort *v);
+ void glVertexAttrib4NuivARB(GLuint index, const GLuint *v);
+ void glVertexAttrib4NubvARB(GLuint index, const GLubyte *v);
+ void glVertexAttrib4NubARB(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void glVertexAttrib4NsvARB(GLuint index, const GLshort *v);
+ void glVertexAttrib4NivARB(GLuint index, const GLint *v);
+ void glVertexAttrib4NbvARB(GLuint index, const GLbyte *v);
+ void glVertexAttrib3svARB(GLuint index, const GLshort *v);
+ void glVertexAttrib3sARB(GLuint index, GLshort x, GLshort y, GLshort z);
+ void glVertexAttrib3fvARB(GLuint index, const GLfloat *v);
+ void glVertexAttrib3fARB(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexAttrib3dvARB(GLuint index, const GLdouble *v);
+ void glVertexAttrib3dARB(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttrib2svARB(GLuint index, const GLshort *v);
+ void glVertexAttrib2sARB(GLuint index, GLshort x, GLshort y);
+ void glVertexAttrib2fvARB(GLuint index, const GLfloat *v);
+ void glVertexAttrib2fARB(GLuint index, GLfloat x, GLfloat y);
+ void glVertexAttrib2dvARB(GLuint index, const GLdouble *v);
+ void glVertexAttrib2dARB(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttrib1svARB(GLuint index, const GLshort *v);
+ void glVertexAttrib1sARB(GLuint index, GLshort x);
+ void glVertexAttrib1fvARB(GLuint index, const GLfloat *v);
+ void glVertexAttrib1fARB(GLuint index, GLfloat x);
+ void glVertexAttrib1dvARB(GLuint index, const GLdouble *v);
+ void glVertexAttrib1dARB(GLuint index, GLdouble x);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_vertex_program)
+};
+
+inline GLboolean QOpenGLExtension_ARB_vertex_program::glIsProgramARB(GLuint program)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ return d->IsProgramARB(program);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glGetVertexAttribPointervARB(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->GetVertexAttribPointervARB(index, pname, pointer);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glGetVertexAttribivARB(GLuint index, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->GetVertexAttribivARB(index, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glGetVertexAttribfvARB(GLuint index, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->GetVertexAttribfvARB(index, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glGetVertexAttribdvARB(GLuint index, GLenum pname, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->GetVertexAttribdvARB(index, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glGetProgramStringARB(GLenum target, GLenum pname, GLvoid *string)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->GetProgramStringARB(target, pname, string);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glGetProgramivARB(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->GetProgramivARB(target, pname, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glGetProgramLocalParameterfvARB(GLenum target, GLuint index, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->GetProgramLocalParameterfvARB(target, index, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glGetProgramLocalParameterdvARB(GLenum target, GLuint index, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->GetProgramLocalParameterdvARB(target, index, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glGetProgramEnvParameterfvARB(GLenum target, GLuint index, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->GetProgramEnvParameterfvARB(target, index, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glGetProgramEnvParameterdvARB(GLenum target, GLuint index, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->GetProgramEnvParameterdvARB(target, index, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glProgramLocalParameter4fvARB(GLenum target, GLuint index, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->ProgramLocalParameter4fvARB(target, index, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glProgramLocalParameter4fARB(GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->ProgramLocalParameter4fARB(target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glProgramLocalParameter4dvARB(GLenum target, GLuint index, const GLdouble *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->ProgramLocalParameter4dvARB(target, index, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glProgramLocalParameter4dARB(GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->ProgramLocalParameter4dARB(target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glProgramEnvParameter4fvARB(GLenum target, GLuint index, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->ProgramEnvParameter4fvARB(target, index, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glProgramEnvParameter4fARB(GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->ProgramEnvParameter4fARB(target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glProgramEnvParameter4dvARB(GLenum target, GLuint index, const GLdouble *params)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->ProgramEnvParameter4dvARB(target, index, params);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glProgramEnvParameter4dARB(GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->ProgramEnvParameter4dARB(target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glGenProgramsARB(GLsizei n, GLuint *programs)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->GenProgramsARB(n, programs);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glDeleteProgramsARB(GLsizei n, const GLuint *programs)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->DeleteProgramsARB(n, programs);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glBindProgramARB(GLenum target, GLuint program)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->BindProgramARB(target, program);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glProgramStringARB(GLenum target, GLenum format, GLsizei len, const GLvoid *string)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->ProgramStringARB(target, format, len, string);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glDisableVertexAttribArrayARB(GLuint index)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->DisableVertexAttribArrayARB(index);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glEnableVertexAttribArrayARB(GLuint index)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->EnableVertexAttribArrayARB(index);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttribPointerARB(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttribPointerARB(index, size, type, normalized, stride, pointer);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4usvARB(GLuint index, const GLushort *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4usvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4uivARB(GLuint index, const GLuint *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4uivARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4ubvARB(GLuint index, const GLubyte *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4ubvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4svARB(GLuint index, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4svARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4sARB(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4sARB(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4ivARB(GLuint index, const GLint *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4ivARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4fvARB(GLuint index, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4fvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4fARB(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4fARB(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4dvARB(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4dvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4dARB(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4dARB(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4bvARB(GLuint index, const GLbyte *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4bvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4NusvARB(GLuint index, const GLushort *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4NusvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4NuivARB(GLuint index, const GLuint *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4NuivARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4NubvARB(GLuint index, const GLubyte *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4NubvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4NubARB(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4NubARB(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4NsvARB(GLuint index, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4NsvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4NivARB(GLuint index, const GLint *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4NivARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib4NbvARB(GLuint index, const GLbyte *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib4NbvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib3svARB(GLuint index, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib3svARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib3sARB(GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib3sARB(index, x, y, z);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib3fvARB(GLuint index, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib3fvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib3fARB(GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib3fARB(index, x, y, z);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib3dvARB(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib3dvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib3dARB(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib3dARB(index, x, y, z);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib2svARB(GLuint index, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib2svARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib2sARB(GLuint index, GLshort x, GLshort y)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib2sARB(index, x, y);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib2fvARB(GLuint index, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib2fvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib2fARB(GLuint index, GLfloat x, GLfloat y)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib2fARB(index, x, y);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib2dvARB(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib2dvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib2dARB(GLuint index, GLdouble x, GLdouble y)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib2dARB(index, x, y);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib1svARB(GLuint index, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib1svARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib1sARB(GLuint index, GLshort x)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib1sARB(index, x);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib1fvARB(GLuint index, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib1fvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib1fARB(GLuint index, GLfloat x)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib1fARB(index, x);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib1dvARB(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib1dvARB(index, v);
+}
+
+inline void QOpenGLExtension_ARB_vertex_program::glVertexAttrib1dARB(GLuint index, GLdouble x)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_program);
+ d->VertexAttrib1dARB(index, x);
+}
+
+class QOpenGLExtension_ARB_vertex_shaderPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLint (QOPENGLF_APIENTRYP GetAttribLocationARB)(GLhandleARB programObj, const GLcharARB *name);
+ void (QOPENGLF_APIENTRYP GetActiveAttribARB)(GLhandleARB programObj, GLuint index, GLsizei maxLength, GLsizei *length, GLint *size, GLenum *type, GLcharARB *name);
+ void (QOPENGLF_APIENTRYP BindAttribLocationARB)(GLhandleARB programObj, GLuint index, const GLcharARB *name);
+};
+
+class QOpenGLExtension_ARB_vertex_shader : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_vertex_shader();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLint glGetAttribLocationARB(GLhandleARB programObj, const GLcharARB *name);
+ void glGetActiveAttribARB(GLhandleARB programObj, GLuint index, GLsizei maxLength, GLsizei *length, GLint *size, GLenum *type, GLcharARB *name);
+ void glBindAttribLocationARB(GLhandleARB programObj, GLuint index, const GLcharARB *name);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_vertex_shader)
+};
+
+inline GLint QOpenGLExtension_ARB_vertex_shader::glGetAttribLocationARB(GLhandleARB programObj, const GLcharARB *name)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_shader);
+ return d->GetAttribLocationARB(programObj, name);
+}
+
+inline void QOpenGLExtension_ARB_vertex_shader::glGetActiveAttribARB(GLhandleARB programObj, GLuint index, GLsizei maxLength, GLsizei *length, GLint *size, GLenum *type, GLcharARB *name)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_shader);
+ d->GetActiveAttribARB(programObj, index, maxLength, length, size, type, name);
+}
+
+inline void QOpenGLExtension_ARB_vertex_shader::glBindAttribLocationARB(GLhandleARB programObj, GLuint index, const GLcharARB *name)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_shader);
+ d->BindAttribLocationARB(programObj, index, name);
+}
+
+class QOpenGLExtension_ARB_vertex_type_2_10_10_10_revPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexAttribP4uiv)(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexAttribP4ui)(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void (QOPENGLF_APIENTRYP VertexAttribP3uiv)(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexAttribP3ui)(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void (QOPENGLF_APIENTRYP VertexAttribP2uiv)(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexAttribP2ui)(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void (QOPENGLF_APIENTRYP VertexAttribP1uiv)(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexAttribP1ui)(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void (QOPENGLF_APIENTRYP SecondaryColorP3uiv)(GLenum type, const GLuint *color);
+ void (QOPENGLF_APIENTRYP SecondaryColorP3ui)(GLenum type, GLuint color);
+ void (QOPENGLF_APIENTRYP ColorP4uiv)(GLenum type, const GLuint *color);
+ void (QOPENGLF_APIENTRYP ColorP4ui)(GLenum type, GLuint color);
+ void (QOPENGLF_APIENTRYP ColorP3uiv)(GLenum type, const GLuint *color);
+ void (QOPENGLF_APIENTRYP ColorP3ui)(GLenum type, GLuint color);
+ void (QOPENGLF_APIENTRYP NormalP3uiv)(GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP NormalP3ui)(GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP4uiv)(GLenum texture, GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP4ui)(GLenum texture, GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP3uiv)(GLenum texture, GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP3ui)(GLenum texture, GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP2uiv)(GLenum texture, GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP2ui)(GLenum texture, GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP1uiv)(GLenum texture, GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP MultiTexCoordP1ui)(GLenum texture, GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP TexCoordP4uiv)(GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP TexCoordP4ui)(GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP TexCoordP3uiv)(GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP TexCoordP3ui)(GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP TexCoordP2uiv)(GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP TexCoordP2ui)(GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP TexCoordP1uiv)(GLenum type, const GLuint *coords);
+ void (QOPENGLF_APIENTRYP TexCoordP1ui)(GLenum type, GLuint coords);
+ void (QOPENGLF_APIENTRYP VertexP4uiv)(GLenum type, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexP4ui)(GLenum type, GLuint value);
+ void (QOPENGLF_APIENTRYP VertexP3uiv)(GLenum type, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexP3ui)(GLenum type, GLuint value);
+ void (QOPENGLF_APIENTRYP VertexP2uiv)(GLenum type, const GLuint *value);
+ void (QOPENGLF_APIENTRYP VertexP2ui)(GLenum type, GLuint value);
+};
+
+class QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value);
+ void glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value);
+ void glSecondaryColorP3uiv(GLenum type, const GLuint *color);
+ void glSecondaryColorP3ui(GLenum type, GLuint color);
+ void glColorP4uiv(GLenum type, const GLuint *color);
+ void glColorP4ui(GLenum type, GLuint color);
+ void glColorP3uiv(GLenum type, const GLuint *color);
+ void glColorP3ui(GLenum type, GLuint color);
+ void glNormalP3uiv(GLenum type, const GLuint *coords);
+ void glNormalP3ui(GLenum type, GLuint coords);
+ void glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords);
+ void glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords);
+ void glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords);
+ void glTexCoordP4uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP4ui(GLenum type, GLuint coords);
+ void glTexCoordP3uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP3ui(GLenum type, GLuint coords);
+ void glTexCoordP2uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP2ui(GLenum type, GLuint coords);
+ void glTexCoordP1uiv(GLenum type, const GLuint *coords);
+ void glTexCoordP1ui(GLenum type, GLuint coords);
+ void glVertexP4uiv(GLenum type, const GLuint *value);
+ void glVertexP4ui(GLenum type, GLuint value);
+ void glVertexP3uiv(GLenum type, const GLuint *value);
+ void glVertexP3ui(GLenum type, GLuint value);
+ void glVertexP2uiv(GLenum type, const GLuint *value);
+ void glVertexP2ui(GLenum type, GLuint value);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev)
+};
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexAttribP4uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexAttribP4uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexAttribP4ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexAttribP4ui(index, type, normalized, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexAttribP3uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexAttribP3uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexAttribP3ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexAttribP3ui(index, type, normalized, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexAttribP2uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexAttribP2uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexAttribP2ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexAttribP2ui(index, type, normalized, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexAttribP1uiv(GLuint index, GLenum type, GLboolean normalized, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexAttribP1uiv(index, type, normalized, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexAttribP1ui(GLuint index, GLenum type, GLboolean normalized, GLuint value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexAttribP1ui(index, type, normalized, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glSecondaryColorP3uiv(GLenum type, const GLuint *color)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->SecondaryColorP3uiv(type, color);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glSecondaryColorP3ui(GLenum type, GLuint color)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->SecondaryColorP3ui(type, color);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glColorP4uiv(GLenum type, const GLuint *color)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->ColorP4uiv(type, color);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glColorP4ui(GLenum type, GLuint color)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->ColorP4ui(type, color);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glColorP3uiv(GLenum type, const GLuint *color)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->ColorP3uiv(type, color);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glColorP3ui(GLenum type, GLuint color)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->ColorP3ui(type, color);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glNormalP3uiv(GLenum type, const GLuint *coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->NormalP3uiv(type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glNormalP3ui(GLenum type, GLuint coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->NormalP3ui(type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glMultiTexCoordP4uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->MultiTexCoordP4uiv(texture, type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glMultiTexCoordP4ui(GLenum texture, GLenum type, GLuint coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->MultiTexCoordP4ui(texture, type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glMultiTexCoordP3uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->MultiTexCoordP3uiv(texture, type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glMultiTexCoordP3ui(GLenum texture, GLenum type, GLuint coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->MultiTexCoordP3ui(texture, type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glMultiTexCoordP2uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->MultiTexCoordP2uiv(texture, type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glMultiTexCoordP2ui(GLenum texture, GLenum type, GLuint coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->MultiTexCoordP2ui(texture, type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glMultiTexCoordP1uiv(GLenum texture, GLenum type, const GLuint *coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->MultiTexCoordP1uiv(texture, type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glMultiTexCoordP1ui(GLenum texture, GLenum type, GLuint coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->MultiTexCoordP1ui(texture, type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glTexCoordP4uiv(GLenum type, const GLuint *coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->TexCoordP4uiv(type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glTexCoordP4ui(GLenum type, GLuint coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->TexCoordP4ui(type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glTexCoordP3uiv(GLenum type, const GLuint *coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->TexCoordP3uiv(type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glTexCoordP3ui(GLenum type, GLuint coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->TexCoordP3ui(type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glTexCoordP2uiv(GLenum type, const GLuint *coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->TexCoordP2uiv(type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glTexCoordP2ui(GLenum type, GLuint coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->TexCoordP2ui(type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glTexCoordP1uiv(GLenum type, const GLuint *coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->TexCoordP1uiv(type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glTexCoordP1ui(GLenum type, GLuint coords)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->TexCoordP1ui(type, coords);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexP4uiv(GLenum type, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexP4uiv(type, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexP4ui(GLenum type, GLuint value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexP4ui(type, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexP3uiv(GLenum type, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexP3uiv(type, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexP3ui(GLenum type, GLuint value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexP3ui(type, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexP2uiv(GLenum type, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexP2uiv(type, value);
+}
+
+inline void QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev::glVertexP2ui(GLenum type, GLuint value)
+{
+ Q_D(QOpenGLExtension_ARB_vertex_type_2_10_10_10_rev);
+ d->VertexP2ui(type, value);
+}
+
+class QOpenGLExtension_ARB_viewport_arrayPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetDoublei_v)(GLenum target, GLuint index, GLdouble *data);
+ void (QOPENGLF_APIENTRYP GetFloati_v)(GLenum target, GLuint index, GLfloat *data);
+ void (QOPENGLF_APIENTRYP DepthRangeIndexed)(GLuint index, GLdouble n, GLdouble f);
+ void (QOPENGLF_APIENTRYP DepthRangeArrayv)(GLuint first, GLsizei count, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP ScissorIndexedv)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP ScissorIndexed)(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP ScissorArrayv)(GLuint first, GLsizei count, const GLint *v);
+ void (QOPENGLF_APIENTRYP ViewportIndexedfv)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ViewportIndexedf)(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+ void (QOPENGLF_APIENTRYP ViewportArrayv)(GLuint first, GLsizei count, const GLfloat *v);
+};
+
+class QOpenGLExtension_ARB_viewport_array : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_viewport_array();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetDoublei_v(GLenum target, GLuint index, GLdouble *data);
+ void glGetFloati_v(GLenum target, GLuint index, GLfloat *data);
+ void glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f);
+ void glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v);
+ void glScissorIndexedv(GLuint index, const GLint *v);
+ void glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+ void glScissorArrayv(GLuint first, GLsizei count, const GLint *v);
+ void glViewportIndexedfv(GLuint index, const GLfloat *v);
+ void glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+ void glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_viewport_array)
+};
+
+inline void QOpenGLExtension_ARB_viewport_array::glGetDoublei_v(GLenum target, GLuint index, GLdouble *data)
+{
+ Q_D(QOpenGLExtension_ARB_viewport_array);
+ d->GetDoublei_v(target, index, data);
+}
+
+inline void QOpenGLExtension_ARB_viewport_array::glGetFloati_v(GLenum target, GLuint index, GLfloat *data)
+{
+ Q_D(QOpenGLExtension_ARB_viewport_array);
+ d->GetFloati_v(target, index, data);
+}
+
+inline void QOpenGLExtension_ARB_viewport_array::glDepthRangeIndexed(GLuint index, GLdouble n, GLdouble f)
+{
+ Q_D(QOpenGLExtension_ARB_viewport_array);
+ d->DepthRangeIndexed(index, n, f);
+}
+
+inline void QOpenGLExtension_ARB_viewport_array::glDepthRangeArrayv(GLuint first, GLsizei count, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_viewport_array);
+ d->DepthRangeArrayv(first, count, v);
+}
+
+inline void QOpenGLExtension_ARB_viewport_array::glScissorIndexedv(GLuint index, const GLint *v)
+{
+ Q_D(QOpenGLExtension_ARB_viewport_array);
+ d->ScissorIndexedv(index, v);
+}
+
+inline void QOpenGLExtension_ARB_viewport_array::glScissorIndexed(GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_ARB_viewport_array);
+ d->ScissorIndexed(index, left, bottom, width, height);
+}
+
+inline void QOpenGLExtension_ARB_viewport_array::glScissorArrayv(GLuint first, GLsizei count, const GLint *v)
+{
+ Q_D(QOpenGLExtension_ARB_viewport_array);
+ d->ScissorArrayv(first, count, v);
+}
+
+inline void QOpenGLExtension_ARB_viewport_array::glViewportIndexedfv(GLuint index, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_viewport_array);
+ d->ViewportIndexedfv(index, v);
+}
+
+inline void QOpenGLExtension_ARB_viewport_array::glViewportIndexedf(GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ Q_D(QOpenGLExtension_ARB_viewport_array);
+ d->ViewportIndexedf(index, x, y, w, h);
+}
+
+inline void QOpenGLExtension_ARB_viewport_array::glViewportArrayv(GLuint first, GLsizei count, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_viewport_array);
+ d->ViewportArrayv(first, count, v);
+}
+
+class QOpenGLExtension_ARB_window_posPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP WindowPos3svARB)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP WindowPos3sARB)(GLshort x, GLshort y, GLshort z);
+ void (QOPENGLF_APIENTRYP WindowPos3ivARB)(const GLint *v);
+ void (QOPENGLF_APIENTRYP WindowPos3iARB)(GLint x, GLint y, GLint z);
+ void (QOPENGLF_APIENTRYP WindowPos3fvARB)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP WindowPos3fARB)(GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP WindowPos3dvARB)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP WindowPos3dARB)(GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP WindowPos2svARB)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP WindowPos2sARB)(GLshort x, GLshort y);
+ void (QOPENGLF_APIENTRYP WindowPos2ivARB)(const GLint *v);
+ void (QOPENGLF_APIENTRYP WindowPos2iARB)(GLint x, GLint y);
+ void (QOPENGLF_APIENTRYP WindowPos2fvARB)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP WindowPos2fARB)(GLfloat x, GLfloat y);
+ void (QOPENGLF_APIENTRYP WindowPos2dvARB)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP WindowPos2dARB)(GLdouble x, GLdouble y);
+};
+
+class QOpenGLExtension_ARB_window_pos : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ARB_window_pos();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glWindowPos3svARB(const GLshort *v);
+ void glWindowPos3sARB(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3ivARB(const GLint *v);
+ void glWindowPos3iARB(GLint x, GLint y, GLint z);
+ void glWindowPos3fvARB(const GLfloat *v);
+ void glWindowPos3fARB(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dvARB(const GLdouble *v);
+ void glWindowPos3dARB(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2svARB(const GLshort *v);
+ void glWindowPos2sARB(GLshort x, GLshort y);
+ void glWindowPos2ivARB(const GLint *v);
+ void glWindowPos2iARB(GLint x, GLint y);
+ void glWindowPos2fvARB(const GLfloat *v);
+ void glWindowPos2fARB(GLfloat x, GLfloat y);
+ void glWindowPos2dvARB(const GLdouble *v);
+ void glWindowPos2dARB(GLdouble x, GLdouble y);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ARB_window_pos)
+};
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos3svARB(const GLshort *v)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos3svARB(v);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos3sARB(GLshort x, GLshort y, GLshort z)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos3sARB(x, y, z);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos3ivARB(const GLint *v)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos3ivARB(v);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos3iARB(GLint x, GLint y, GLint z)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos3iARB(x, y, z);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos3fvARB(const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos3fvARB(v);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos3fARB(GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos3fARB(x, y, z);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos3dvARB(const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos3dvARB(v);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos3dARB(GLdouble x, GLdouble y, GLdouble z)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos3dARB(x, y, z);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos2svARB(const GLshort *v)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos2svARB(v);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos2sARB(GLshort x, GLshort y)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos2sARB(x, y);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos2ivARB(const GLint *v)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos2ivARB(v);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos2iARB(GLint x, GLint y)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos2iARB(x, y);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos2fvARB(const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos2fvARB(v);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos2fARB(GLfloat x, GLfloat y)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos2fARB(x, y);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos2dvARB(const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos2dvARB(v);
+}
+
+inline void QOpenGLExtension_ARB_window_pos::glWindowPos2dARB(GLdouble x, GLdouble y)
+{
+ Q_D(QOpenGLExtension_ARB_window_pos);
+ d->WindowPos2dARB(x, y);
+}
+
+class QOpenGLExtension_ATI_draw_buffersPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawBuffersATI)(GLsizei n, const GLenum *bufs);
+};
+
+class QOpenGLExtension_ATI_draw_buffers : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ATI_draw_buffers();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawBuffersATI(GLsizei n, const GLenum *bufs);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ATI_draw_buffers)
+};
+
+inline void QOpenGLExtension_ATI_draw_buffers::glDrawBuffersATI(GLsizei n, const GLenum *bufs)
+{
+ Q_D(QOpenGLExtension_ATI_draw_buffers);
+ d->DrawBuffersATI(n, bufs);
+}
+
+class QOpenGLExtension_ATI_element_arrayPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawRangeElementArrayATI)(GLenum mode, GLuint start, GLuint end, GLsizei count);
+ void (QOPENGLF_APIENTRYP DrawElementArrayATI)(GLenum mode, GLsizei count);
+ void (QOPENGLF_APIENTRYP ElementPointerATI)(GLenum type, const GLvoid *pointer);
+};
+
+class QOpenGLExtension_ATI_element_array : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ATI_element_array();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawRangeElementArrayATI(GLenum mode, GLuint start, GLuint end, GLsizei count);
+ void glDrawElementArrayATI(GLenum mode, GLsizei count);
+ void glElementPointerATI(GLenum type, const GLvoid *pointer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ATI_element_array)
+};
+
+inline void QOpenGLExtension_ATI_element_array::glDrawRangeElementArrayATI(GLenum mode, GLuint start, GLuint end, GLsizei count)
+{
+ Q_D(QOpenGLExtension_ATI_element_array);
+ d->DrawRangeElementArrayATI(mode, start, end, count);
+}
+
+inline void QOpenGLExtension_ATI_element_array::glDrawElementArrayATI(GLenum mode, GLsizei count)
+{
+ Q_D(QOpenGLExtension_ATI_element_array);
+ d->DrawElementArrayATI(mode, count);
+}
+
+inline void QOpenGLExtension_ATI_element_array::glElementPointerATI(GLenum type, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_ATI_element_array);
+ d->ElementPointerATI(type, pointer);
+}
+
+class QOpenGLExtension_ATI_envmap_bumpmapPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetTexBumpParameterfvATI)(GLenum pname, GLfloat *param);
+ void (QOPENGLF_APIENTRYP GetTexBumpParameterivATI)(GLenum pname, GLint *param);
+ void (QOPENGLF_APIENTRYP TexBumpParameterfvATI)(GLenum pname, const GLfloat *param);
+ void (QOPENGLF_APIENTRYP TexBumpParameterivATI)(GLenum pname, const GLint *param);
+};
+
+class QOpenGLExtension_ATI_envmap_bumpmap : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ATI_envmap_bumpmap();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetTexBumpParameterfvATI(GLenum pname, GLfloat *param);
+ void glGetTexBumpParameterivATI(GLenum pname, GLint *param);
+ void glTexBumpParameterfvATI(GLenum pname, const GLfloat *param);
+ void glTexBumpParameterivATI(GLenum pname, const GLint *param);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ATI_envmap_bumpmap)
+};
+
+inline void QOpenGLExtension_ATI_envmap_bumpmap::glGetTexBumpParameterfvATI(GLenum pname, GLfloat *param)
+{
+ Q_D(QOpenGLExtension_ATI_envmap_bumpmap);
+ d->GetTexBumpParameterfvATI(pname, param);
+}
+
+inline void QOpenGLExtension_ATI_envmap_bumpmap::glGetTexBumpParameterivATI(GLenum pname, GLint *param)
+{
+ Q_D(QOpenGLExtension_ATI_envmap_bumpmap);
+ d->GetTexBumpParameterivATI(pname, param);
+}
+
+inline void QOpenGLExtension_ATI_envmap_bumpmap::glTexBumpParameterfvATI(GLenum pname, const GLfloat *param)
+{
+ Q_D(QOpenGLExtension_ATI_envmap_bumpmap);
+ d->TexBumpParameterfvATI(pname, param);
+}
+
+inline void QOpenGLExtension_ATI_envmap_bumpmap::glTexBumpParameterivATI(GLenum pname, const GLint *param)
+{
+ Q_D(QOpenGLExtension_ATI_envmap_bumpmap);
+ d->TexBumpParameterivATI(pname, param);
+}
+
+class QOpenGLExtension_ATI_fragment_shaderPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP SetFragmentShaderConstantATI)(GLuint dst, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP AlphaFragmentOp3ATI)(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod);
+ void (QOPENGLF_APIENTRYP AlphaFragmentOp2ATI)(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod);
+ void (QOPENGLF_APIENTRYP AlphaFragmentOp1ATI)(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod);
+ void (QOPENGLF_APIENTRYP ColorFragmentOp3ATI)(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod);
+ void (QOPENGLF_APIENTRYP ColorFragmentOp2ATI)(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod);
+ void (QOPENGLF_APIENTRYP ColorFragmentOp1ATI)(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod);
+ void (QOPENGLF_APIENTRYP SampleMapATI)(GLuint dst, GLuint interp, GLenum swizzle);
+ void (QOPENGLF_APIENTRYP PassTexCoordATI)(GLuint dst, GLuint coord, GLenum swizzle);
+ void (QOPENGLF_APIENTRYP EndFragmentShaderATI)();
+ void (QOPENGLF_APIENTRYP BeginFragmentShaderATI)();
+ void (QOPENGLF_APIENTRYP DeleteFragmentShaderATI)(GLuint id);
+ void (QOPENGLF_APIENTRYP BindFragmentShaderATI)(GLuint id);
+ GLuint (QOPENGLF_APIENTRYP GenFragmentShadersATI)(GLuint range);
+};
+
+class QOpenGLExtension_ATI_fragment_shader : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ATI_fragment_shader();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glSetFragmentShaderConstantATI(GLuint dst, const GLfloat *value);
+ void glAlphaFragmentOp3ATI(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod);
+ void glAlphaFragmentOp2ATI(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod);
+ void glAlphaFragmentOp1ATI(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod);
+ void glColorFragmentOp3ATI(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod);
+ void glColorFragmentOp2ATI(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod);
+ void glColorFragmentOp1ATI(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod);
+ void glSampleMapATI(GLuint dst, GLuint interp, GLenum swizzle);
+ void glPassTexCoordATI(GLuint dst, GLuint coord, GLenum swizzle);
+ void glEndFragmentShaderATI();
+ void glBeginFragmentShaderATI();
+ void glDeleteFragmentShaderATI(GLuint id);
+ void glBindFragmentShaderATI(GLuint id);
+ GLuint glGenFragmentShadersATI(GLuint range);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ATI_fragment_shader)
+};
+
+inline void QOpenGLExtension_ATI_fragment_shader::glSetFragmentShaderConstantATI(GLuint dst, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->SetFragmentShaderConstantATI(dst, value);
+}
+
+inline void QOpenGLExtension_ATI_fragment_shader::glAlphaFragmentOp3ATI(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod)
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->AlphaFragmentOp3ATI(op, dst, dstMod, arg1, arg1Rep, arg1Mod, arg2, arg2Rep, arg2Mod, arg3, arg3Rep, arg3Mod);
+}
+
+inline void QOpenGLExtension_ATI_fragment_shader::glAlphaFragmentOp2ATI(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod)
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->AlphaFragmentOp2ATI(op, dst, dstMod, arg1, arg1Rep, arg1Mod, arg2, arg2Rep, arg2Mod);
+}
+
+inline void QOpenGLExtension_ATI_fragment_shader::glAlphaFragmentOp1ATI(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod)
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->AlphaFragmentOp1ATI(op, dst, dstMod, arg1, arg1Rep, arg1Mod);
+}
+
+inline void QOpenGLExtension_ATI_fragment_shader::glColorFragmentOp3ATI(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod)
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->ColorFragmentOp3ATI(op, dst, dstMask, dstMod, arg1, arg1Rep, arg1Mod, arg2, arg2Rep, arg2Mod, arg3, arg3Rep, arg3Mod);
+}
+
+inline void QOpenGLExtension_ATI_fragment_shader::glColorFragmentOp2ATI(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod)
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->ColorFragmentOp2ATI(op, dst, dstMask, dstMod, arg1, arg1Rep, arg1Mod, arg2, arg2Rep, arg2Mod);
+}
+
+inline void QOpenGLExtension_ATI_fragment_shader::glColorFragmentOp1ATI(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod)
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->ColorFragmentOp1ATI(op, dst, dstMask, dstMod, arg1, arg1Rep, arg1Mod);
+}
+
+inline void QOpenGLExtension_ATI_fragment_shader::glSampleMapATI(GLuint dst, GLuint interp, GLenum swizzle)
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->SampleMapATI(dst, interp, swizzle);
+}
+
+inline void QOpenGLExtension_ATI_fragment_shader::glPassTexCoordATI(GLuint dst, GLuint coord, GLenum swizzle)
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->PassTexCoordATI(dst, coord, swizzle);
+}
+
+inline void QOpenGLExtension_ATI_fragment_shader::glEndFragmentShaderATI()
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->EndFragmentShaderATI();
+}
+
+inline void QOpenGLExtension_ATI_fragment_shader::glBeginFragmentShaderATI()
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->BeginFragmentShaderATI();
+}
+
+inline void QOpenGLExtension_ATI_fragment_shader::glDeleteFragmentShaderATI(GLuint id)
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->DeleteFragmentShaderATI(id);
+}
+
+inline void QOpenGLExtension_ATI_fragment_shader::glBindFragmentShaderATI(GLuint id)
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ d->BindFragmentShaderATI(id);
+}
+
+inline GLuint QOpenGLExtension_ATI_fragment_shader::glGenFragmentShadersATI(GLuint range)
+{
+ Q_D(QOpenGLExtension_ATI_fragment_shader);
+ return d->GenFragmentShadersATI(range);
+}
+
+class QOpenGLExtension_ATI_map_object_bufferPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP UnmapObjectBufferATI)(GLuint buffer);
+ GLvoid* (QOPENGLF_APIENTRYP MapObjectBufferATI)(GLuint buffer);
+};
+
+class QOpenGLExtension_ATI_map_object_buffer : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ATI_map_object_buffer();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glUnmapObjectBufferATI(GLuint buffer);
+ GLvoid* glMapObjectBufferATI(GLuint buffer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ATI_map_object_buffer)
+};
+
+inline void QOpenGLExtension_ATI_map_object_buffer::glUnmapObjectBufferATI(GLuint buffer)
+{
+ Q_D(QOpenGLExtension_ATI_map_object_buffer);
+ d->UnmapObjectBufferATI(buffer);
+}
+
+inline GLvoid* QOpenGLExtension_ATI_map_object_buffer::glMapObjectBufferATI(GLuint buffer)
+{
+ Q_D(QOpenGLExtension_ATI_map_object_buffer);
+ return d->MapObjectBufferATI(buffer);
+}
+
+class QOpenGLExtension_ATI_pn_trianglesPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP PNTrianglesfATI)(GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP PNTrianglesiATI)(GLenum pname, GLint param);
+};
+
+class QOpenGLExtension_ATI_pn_triangles : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ATI_pn_triangles();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glPNTrianglesfATI(GLenum pname, GLfloat param);
+ void glPNTrianglesiATI(GLenum pname, GLint param);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ATI_pn_triangles)
+};
+
+inline void QOpenGLExtension_ATI_pn_triangles::glPNTrianglesfATI(GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_ATI_pn_triangles);
+ d->PNTrianglesfATI(pname, param);
+}
+
+inline void QOpenGLExtension_ATI_pn_triangles::glPNTrianglesiATI(GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_ATI_pn_triangles);
+ d->PNTrianglesiATI(pname, param);
+}
+
+class QOpenGLExtension_ATI_separate_stencilPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP StencilFuncSeparateATI)(GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask);
+ void (QOPENGLF_APIENTRYP StencilOpSeparateATI)(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+};
+
+class QOpenGLExtension_ATI_separate_stencil : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ATI_separate_stencil();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glStencilFuncSeparateATI(GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask);
+ void glStencilOpSeparateATI(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ATI_separate_stencil)
+};
+
+inline void QOpenGLExtension_ATI_separate_stencil::glStencilFuncSeparateATI(GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask)
+{
+ Q_D(QOpenGLExtension_ATI_separate_stencil);
+ d->StencilFuncSeparateATI(frontfunc, backfunc, ref, mask);
+}
+
+inline void QOpenGLExtension_ATI_separate_stencil::glStencilOpSeparateATI(GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ Q_D(QOpenGLExtension_ATI_separate_stencil);
+ d->StencilOpSeparateATI(face, sfail, dpfail, dppass);
+}
+
+class QOpenGLExtension_ATI_vertex_array_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetVariantArrayObjectivATI)(GLuint id, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetVariantArrayObjectfvATI)(GLuint id, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP VariantArrayObjectATI)(GLuint id, GLenum type, GLsizei stride, GLuint buffer, GLuint offset);
+ void (QOPENGLF_APIENTRYP GetArrayObjectivATI)(GLenum array, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetArrayObjectfvATI)(GLenum array, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP ArrayObjectATI)(GLenum array, GLint size, GLenum type, GLsizei stride, GLuint buffer, GLuint offset);
+ void (QOPENGLF_APIENTRYP FreeObjectBufferATI)(GLuint buffer);
+ void (QOPENGLF_APIENTRYP GetObjectBufferivATI)(GLuint buffer, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetObjectBufferfvATI)(GLuint buffer, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP UpdateObjectBufferATI)(GLuint buffer, GLuint offset, GLsizei size, const GLvoid *pointer, GLenum preserve);
+ GLboolean (QOPENGLF_APIENTRYP IsObjectBufferATI)(GLuint buffer);
+ GLuint (QOPENGLF_APIENTRYP NewObjectBufferATI)(GLsizei size, const GLvoid *pointer, GLenum usage);
+};
+
+class QOpenGLExtension_ATI_vertex_array_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ATI_vertex_array_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetVariantArrayObjectivATI(GLuint id, GLenum pname, GLint *params);
+ void glGetVariantArrayObjectfvATI(GLuint id, GLenum pname, GLfloat *params);
+ void glVariantArrayObjectATI(GLuint id, GLenum type, GLsizei stride, GLuint buffer, GLuint offset);
+ void glGetArrayObjectivATI(GLenum array, GLenum pname, GLint *params);
+ void glGetArrayObjectfvATI(GLenum array, GLenum pname, GLfloat *params);
+ void glArrayObjectATI(GLenum array, GLint size, GLenum type, GLsizei stride, GLuint buffer, GLuint offset);
+ void glFreeObjectBufferATI(GLuint buffer);
+ void glGetObjectBufferivATI(GLuint buffer, GLenum pname, GLint *params);
+ void glGetObjectBufferfvATI(GLuint buffer, GLenum pname, GLfloat *params);
+ void glUpdateObjectBufferATI(GLuint buffer, GLuint offset, GLsizei size, const GLvoid *pointer, GLenum preserve);
+ GLboolean glIsObjectBufferATI(GLuint buffer);
+ GLuint glNewObjectBufferATI(GLsizei size, const GLvoid *pointer, GLenum usage);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ATI_vertex_array_object)
+};
+
+inline void QOpenGLExtension_ATI_vertex_array_object::glGetVariantArrayObjectivATI(GLuint id, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+ d->GetVariantArrayObjectivATI(id, pname, params);
+}
+
+inline void QOpenGLExtension_ATI_vertex_array_object::glGetVariantArrayObjectfvATI(GLuint id, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+ d->GetVariantArrayObjectfvATI(id, pname, params);
+}
+
+inline void QOpenGLExtension_ATI_vertex_array_object::glVariantArrayObjectATI(GLuint id, GLenum type, GLsizei stride, GLuint buffer, GLuint offset)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+ d->VariantArrayObjectATI(id, type, stride, buffer, offset);
+}
+
+inline void QOpenGLExtension_ATI_vertex_array_object::glGetArrayObjectivATI(GLenum array, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+ d->GetArrayObjectivATI(array, pname, params);
+}
+
+inline void QOpenGLExtension_ATI_vertex_array_object::glGetArrayObjectfvATI(GLenum array, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+ d->GetArrayObjectfvATI(array, pname, params);
+}
+
+inline void QOpenGLExtension_ATI_vertex_array_object::glArrayObjectATI(GLenum array, GLint size, GLenum type, GLsizei stride, GLuint buffer, GLuint offset)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+ d->ArrayObjectATI(array, size, type, stride, buffer, offset);
+}
+
+inline void QOpenGLExtension_ATI_vertex_array_object::glFreeObjectBufferATI(GLuint buffer)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+ d->FreeObjectBufferATI(buffer);
+}
+
+inline void QOpenGLExtension_ATI_vertex_array_object::glGetObjectBufferivATI(GLuint buffer, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+ d->GetObjectBufferivATI(buffer, pname, params);
+}
+
+inline void QOpenGLExtension_ATI_vertex_array_object::glGetObjectBufferfvATI(GLuint buffer, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+ d->GetObjectBufferfvATI(buffer, pname, params);
+}
+
+inline void QOpenGLExtension_ATI_vertex_array_object::glUpdateObjectBufferATI(GLuint buffer, GLuint offset, GLsizei size, const GLvoid *pointer, GLenum preserve)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+ d->UpdateObjectBufferATI(buffer, offset, size, pointer, preserve);
+}
+
+inline GLboolean QOpenGLExtension_ATI_vertex_array_object::glIsObjectBufferATI(GLuint buffer)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+ return d->IsObjectBufferATI(buffer);
+}
+
+inline GLuint QOpenGLExtension_ATI_vertex_array_object::glNewObjectBufferATI(GLsizei size, const GLvoid *pointer, GLenum usage)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_array_object);
+ return d->NewObjectBufferATI(size, pointer, usage);
+}
+
+class QOpenGLExtension_ATI_vertex_attrib_array_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetVertexAttribArrayObjectivATI)(GLuint index, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetVertexAttribArrayObjectfvATI)(GLuint index, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP VertexAttribArrayObjectATI)(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, GLuint buffer, GLuint offset);
+};
+
+class QOpenGLExtension_ATI_vertex_attrib_array_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ATI_vertex_attrib_array_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetVertexAttribArrayObjectivATI(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribArrayObjectfvATI(GLuint index, GLenum pname, GLfloat *params);
+ void glVertexAttribArrayObjectATI(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, GLuint buffer, GLuint offset);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ATI_vertex_attrib_array_object)
+};
+
+inline void QOpenGLExtension_ATI_vertex_attrib_array_object::glGetVertexAttribArrayObjectivATI(GLuint index, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_attrib_array_object);
+ d->GetVertexAttribArrayObjectivATI(index, pname, params);
+}
+
+inline void QOpenGLExtension_ATI_vertex_attrib_array_object::glGetVertexAttribArrayObjectfvATI(GLuint index, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_attrib_array_object);
+ d->GetVertexAttribArrayObjectfvATI(index, pname, params);
+}
+
+inline void QOpenGLExtension_ATI_vertex_attrib_array_object::glVertexAttribArrayObjectATI(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, GLuint buffer, GLuint offset)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_attrib_array_object);
+ d->VertexAttribArrayObjectATI(index, size, type, normalized, stride, buffer, offset);
+}
+
+class QOpenGLExtension_ATI_vertex_streamsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexBlendEnvfATI)(GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP VertexBlendEnviATI)(GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP ClientActiveVertexStreamATI)(GLenum stream);
+ void (QOPENGLF_APIENTRYP NormalStream3dvATI)(GLenum stream, const GLdouble *coords);
+ void (QOPENGLF_APIENTRYP NormalStream3dATI)(GLenum stream, GLdouble nx, GLdouble ny, GLdouble nz);
+ void (QOPENGLF_APIENTRYP NormalStream3fvATI)(GLenum stream, const GLfloat *coords);
+ void (QOPENGLF_APIENTRYP NormalStream3fATI)(GLenum stream, GLfloat nx, GLfloat ny, GLfloat nz);
+ void (QOPENGLF_APIENTRYP NormalStream3ivATI)(GLenum stream, const GLint *coords);
+ void (QOPENGLF_APIENTRYP NormalStream3iATI)(GLenum stream, GLint nx, GLint ny, GLint nz);
+ void (QOPENGLF_APIENTRYP NormalStream3svATI)(GLenum stream, const GLshort *coords);
+ void (QOPENGLF_APIENTRYP NormalStream3sATI)(GLenum stream, GLshort nx, GLshort ny, GLshort nz);
+ void (QOPENGLF_APIENTRYP NormalStream3bvATI)(GLenum stream, const GLbyte *coords);
+ void (QOPENGLF_APIENTRYP NormalStream3bATI)(GLenum stream, GLbyte nx, GLbyte ny, GLbyte nz);
+ void (QOPENGLF_APIENTRYP VertexStream4dvATI)(GLenum stream, const GLdouble *coords);
+ void (QOPENGLF_APIENTRYP VertexStream4dATI)(GLenum stream, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP VertexStream4fvATI)(GLenum stream, const GLfloat *coords);
+ void (QOPENGLF_APIENTRYP VertexStream4fATI)(GLenum stream, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP VertexStream4ivATI)(GLenum stream, const GLint *coords);
+ void (QOPENGLF_APIENTRYP VertexStream4iATI)(GLenum stream, GLint x, GLint y, GLint z, GLint w);
+ void (QOPENGLF_APIENTRYP VertexStream4svATI)(GLenum stream, const GLshort *coords);
+ void (QOPENGLF_APIENTRYP VertexStream4sATI)(GLenum stream, GLshort x, GLshort y, GLshort z, GLshort w);
+ void (QOPENGLF_APIENTRYP VertexStream3dvATI)(GLenum stream, const GLdouble *coords);
+ void (QOPENGLF_APIENTRYP VertexStream3dATI)(GLenum stream, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP VertexStream3fvATI)(GLenum stream, const GLfloat *coords);
+ void (QOPENGLF_APIENTRYP VertexStream3fATI)(GLenum stream, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP VertexStream3ivATI)(GLenum stream, const GLint *coords);
+ void (QOPENGLF_APIENTRYP VertexStream3iATI)(GLenum stream, GLint x, GLint y, GLint z);
+ void (QOPENGLF_APIENTRYP VertexStream3svATI)(GLenum stream, const GLshort *coords);
+ void (QOPENGLF_APIENTRYP VertexStream3sATI)(GLenum stream, GLshort x, GLshort y, GLshort z);
+ void (QOPENGLF_APIENTRYP VertexStream2dvATI)(GLenum stream, const GLdouble *coords);
+ void (QOPENGLF_APIENTRYP VertexStream2dATI)(GLenum stream, GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP VertexStream2fvATI)(GLenum stream, const GLfloat *coords);
+ void (QOPENGLF_APIENTRYP VertexStream2fATI)(GLenum stream, GLfloat x, GLfloat y);
+ void (QOPENGLF_APIENTRYP VertexStream2ivATI)(GLenum stream, const GLint *coords);
+ void (QOPENGLF_APIENTRYP VertexStream2iATI)(GLenum stream, GLint x, GLint y);
+ void (QOPENGLF_APIENTRYP VertexStream2svATI)(GLenum stream, const GLshort *coords);
+ void (QOPENGLF_APIENTRYP VertexStream2sATI)(GLenum stream, GLshort x, GLshort y);
+ void (QOPENGLF_APIENTRYP VertexStream1dvATI)(GLenum stream, const GLdouble *coords);
+ void (QOPENGLF_APIENTRYP VertexStream1dATI)(GLenum stream, GLdouble x);
+ void (QOPENGLF_APIENTRYP VertexStream1fvATI)(GLenum stream, const GLfloat *coords);
+ void (QOPENGLF_APIENTRYP VertexStream1fATI)(GLenum stream, GLfloat x);
+ void (QOPENGLF_APIENTRYP VertexStream1ivATI)(GLenum stream, const GLint *coords);
+ void (QOPENGLF_APIENTRYP VertexStream1iATI)(GLenum stream, GLint x);
+ void (QOPENGLF_APIENTRYP VertexStream1svATI)(GLenum stream, const GLshort *coords);
+ void (QOPENGLF_APIENTRYP VertexStream1sATI)(GLenum stream, GLshort x);
+};
+
+class QOpenGLExtension_ATI_vertex_streams : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ATI_vertex_streams();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexBlendEnvfATI(GLenum pname, GLfloat param);
+ void glVertexBlendEnviATI(GLenum pname, GLint param);
+ void glClientActiveVertexStreamATI(GLenum stream);
+ void glNormalStream3dvATI(GLenum stream, const GLdouble *coords);
+ void glNormalStream3dATI(GLenum stream, GLdouble nx, GLdouble ny, GLdouble nz);
+ void glNormalStream3fvATI(GLenum stream, const GLfloat *coords);
+ void glNormalStream3fATI(GLenum stream, GLfloat nx, GLfloat ny, GLfloat nz);
+ void glNormalStream3ivATI(GLenum stream, const GLint *coords);
+ void glNormalStream3iATI(GLenum stream, GLint nx, GLint ny, GLint nz);
+ void glNormalStream3svATI(GLenum stream, const GLshort *coords);
+ void glNormalStream3sATI(GLenum stream, GLshort nx, GLshort ny, GLshort nz);
+ void glNormalStream3bvATI(GLenum stream, const GLbyte *coords);
+ void glNormalStream3bATI(GLenum stream, GLbyte nx, GLbyte ny, GLbyte nz);
+ void glVertexStream4dvATI(GLenum stream, const GLdouble *coords);
+ void glVertexStream4dATI(GLenum stream, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexStream4fvATI(GLenum stream, const GLfloat *coords);
+ void glVertexStream4fATI(GLenum stream, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexStream4ivATI(GLenum stream, const GLint *coords);
+ void glVertexStream4iATI(GLenum stream, GLint x, GLint y, GLint z, GLint w);
+ void glVertexStream4svATI(GLenum stream, const GLshort *coords);
+ void glVertexStream4sATI(GLenum stream, GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertexStream3dvATI(GLenum stream, const GLdouble *coords);
+ void glVertexStream3dATI(GLenum stream, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexStream3fvATI(GLenum stream, const GLfloat *coords);
+ void glVertexStream3fATI(GLenum stream, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexStream3ivATI(GLenum stream, const GLint *coords);
+ void glVertexStream3iATI(GLenum stream, GLint x, GLint y, GLint z);
+ void glVertexStream3svATI(GLenum stream, const GLshort *coords);
+ void glVertexStream3sATI(GLenum stream, GLshort x, GLshort y, GLshort z);
+ void glVertexStream2dvATI(GLenum stream, const GLdouble *coords);
+ void glVertexStream2dATI(GLenum stream, GLdouble x, GLdouble y);
+ void glVertexStream2fvATI(GLenum stream, const GLfloat *coords);
+ void glVertexStream2fATI(GLenum stream, GLfloat x, GLfloat y);
+ void glVertexStream2ivATI(GLenum stream, const GLint *coords);
+ void glVertexStream2iATI(GLenum stream, GLint x, GLint y);
+ void glVertexStream2svATI(GLenum stream, const GLshort *coords);
+ void glVertexStream2sATI(GLenum stream, GLshort x, GLshort y);
+ void glVertexStream1dvATI(GLenum stream, const GLdouble *coords);
+ void glVertexStream1dATI(GLenum stream, GLdouble x);
+ void glVertexStream1fvATI(GLenum stream, const GLfloat *coords);
+ void glVertexStream1fATI(GLenum stream, GLfloat x);
+ void glVertexStream1ivATI(GLenum stream, const GLint *coords);
+ void glVertexStream1iATI(GLenum stream, GLint x);
+ void glVertexStream1svATI(GLenum stream, const GLshort *coords);
+ void glVertexStream1sATI(GLenum stream, GLshort x);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ATI_vertex_streams)
+};
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexBlendEnvfATI(GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexBlendEnvfATI(pname, param);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexBlendEnviATI(GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexBlendEnviATI(pname, param);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glClientActiveVertexStreamATI(GLenum stream)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->ClientActiveVertexStreamATI(stream);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glNormalStream3dvATI(GLenum stream, const GLdouble *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->NormalStream3dvATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glNormalStream3dATI(GLenum stream, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->NormalStream3dATI(stream, nx, ny, nz);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glNormalStream3fvATI(GLenum stream, const GLfloat *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->NormalStream3fvATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glNormalStream3fATI(GLenum stream, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->NormalStream3fATI(stream, nx, ny, nz);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glNormalStream3ivATI(GLenum stream, const GLint *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->NormalStream3ivATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glNormalStream3iATI(GLenum stream, GLint nx, GLint ny, GLint nz)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->NormalStream3iATI(stream, nx, ny, nz);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glNormalStream3svATI(GLenum stream, const GLshort *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->NormalStream3svATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glNormalStream3sATI(GLenum stream, GLshort nx, GLshort ny, GLshort nz)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->NormalStream3sATI(stream, nx, ny, nz);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glNormalStream3bvATI(GLenum stream, const GLbyte *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->NormalStream3bvATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glNormalStream3bATI(GLenum stream, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->NormalStream3bATI(stream, nx, ny, nz);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream4dvATI(GLenum stream, const GLdouble *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream4dvATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream4dATI(GLenum stream, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream4dATI(stream, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream4fvATI(GLenum stream, const GLfloat *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream4fvATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream4fATI(GLenum stream, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream4fATI(stream, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream4ivATI(GLenum stream, const GLint *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream4ivATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream4iATI(GLenum stream, GLint x, GLint y, GLint z, GLint w)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream4iATI(stream, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream4svATI(GLenum stream, const GLshort *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream4svATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream4sATI(GLenum stream, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream4sATI(stream, x, y, z, w);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream3dvATI(GLenum stream, const GLdouble *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream3dvATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream3dATI(GLenum stream, GLdouble x, GLdouble y, GLdouble z)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream3dATI(stream, x, y, z);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream3fvATI(GLenum stream, const GLfloat *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream3fvATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream3fATI(GLenum stream, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream3fATI(stream, x, y, z);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream3ivATI(GLenum stream, const GLint *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream3ivATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream3iATI(GLenum stream, GLint x, GLint y, GLint z)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream3iATI(stream, x, y, z);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream3svATI(GLenum stream, const GLshort *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream3svATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream3sATI(GLenum stream, GLshort x, GLshort y, GLshort z)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream3sATI(stream, x, y, z);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream2dvATI(GLenum stream, const GLdouble *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream2dvATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream2dATI(GLenum stream, GLdouble x, GLdouble y)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream2dATI(stream, x, y);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream2fvATI(GLenum stream, const GLfloat *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream2fvATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream2fATI(GLenum stream, GLfloat x, GLfloat y)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream2fATI(stream, x, y);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream2ivATI(GLenum stream, const GLint *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream2ivATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream2iATI(GLenum stream, GLint x, GLint y)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream2iATI(stream, x, y);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream2svATI(GLenum stream, const GLshort *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream2svATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream2sATI(GLenum stream, GLshort x, GLshort y)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream2sATI(stream, x, y);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream1dvATI(GLenum stream, const GLdouble *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream1dvATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream1dATI(GLenum stream, GLdouble x)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream1dATI(stream, x);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream1fvATI(GLenum stream, const GLfloat *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream1fvATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream1fATI(GLenum stream, GLfloat x)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream1fATI(stream, x);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream1ivATI(GLenum stream, const GLint *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream1ivATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream1iATI(GLenum stream, GLint x)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream1iATI(stream, x);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream1svATI(GLenum stream, const GLshort *coords)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream1svATI(stream, coords);
+}
+
+inline void QOpenGLExtension_ATI_vertex_streams::glVertexStream1sATI(GLenum stream, GLshort x)
+{
+ Q_D(QOpenGLExtension_ATI_vertex_streams);
+ d->VertexStream1sATI(stream, x);
+}
+
+class QOpenGLExtension_EXT_bindable_uniformPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLintptr (QOPENGLF_APIENTRYP GetUniformOffsetEXT)(GLuint program, GLint location);
+ GLint (QOPENGLF_APIENTRYP GetUniformBufferSizeEXT)(GLuint program, GLint location);
+ void (QOPENGLF_APIENTRYP UniformBufferEXT)(GLuint program, GLint location, GLuint buffer);
+};
+
+class QOpenGLExtension_EXT_bindable_uniform : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_bindable_uniform();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLintptr glGetUniformOffsetEXT(GLuint program, GLint location);
+ GLint glGetUniformBufferSizeEXT(GLuint program, GLint location);
+ void glUniformBufferEXT(GLuint program, GLint location, GLuint buffer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_bindable_uniform)
+};
+
+inline GLintptr QOpenGLExtension_EXT_bindable_uniform::glGetUniformOffsetEXT(GLuint program, GLint location)
+{
+ Q_D(QOpenGLExtension_EXT_bindable_uniform);
+ return d->GetUniformOffsetEXT(program, location);
+}
+
+inline GLint QOpenGLExtension_EXT_bindable_uniform::glGetUniformBufferSizeEXT(GLuint program, GLint location)
+{
+ Q_D(QOpenGLExtension_EXT_bindable_uniform);
+ return d->GetUniformBufferSizeEXT(program, location);
+}
+
+inline void QOpenGLExtension_EXT_bindable_uniform::glUniformBufferEXT(GLuint program, GLint location, GLuint buffer)
+{
+ Q_D(QOpenGLExtension_EXT_bindable_uniform);
+ d->UniformBufferEXT(program, location, buffer);
+}
+
+class QOpenGLExtension_EXT_blend_colorPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BlendColorEXT)(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+};
+
+class QOpenGLExtension_EXT_blend_color : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_blend_color();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBlendColorEXT(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_blend_color)
+};
+
+inline void QOpenGLExtension_EXT_blend_color::glBlendColorEXT(GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ Q_D(QOpenGLExtension_EXT_blend_color);
+ d->BlendColorEXT(red, green, blue, alpha);
+}
+
+class QOpenGLExtension_EXT_blend_equation_separatePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BlendEquationSeparateEXT)(GLenum modeRGB, GLenum modeAlpha);
+};
+
+class QOpenGLExtension_EXT_blend_equation_separate : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_blend_equation_separate();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBlendEquationSeparateEXT(GLenum modeRGB, GLenum modeAlpha);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_blend_equation_separate)
+};
+
+inline void QOpenGLExtension_EXT_blend_equation_separate::glBlendEquationSeparateEXT(GLenum modeRGB, GLenum modeAlpha)
+{
+ Q_D(QOpenGLExtension_EXT_blend_equation_separate);
+ d->BlendEquationSeparateEXT(modeRGB, modeAlpha);
+}
+
+class QOpenGLExtension_EXT_blend_func_separatePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BlendFuncSeparateEXT)(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+};
+
+class QOpenGLExtension_EXT_blend_func_separate : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_blend_func_separate();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBlendFuncSeparateEXT(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_blend_func_separate)
+};
+
+inline void QOpenGLExtension_EXT_blend_func_separate::glBlendFuncSeparateEXT(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ Q_D(QOpenGLExtension_EXT_blend_func_separate);
+ d->BlendFuncSeparateEXT(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+class QOpenGLExtension_EXT_blend_minmaxPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BlendEquationEXT)(GLenum mode);
+};
+
+class QOpenGLExtension_EXT_blend_minmax : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_blend_minmax();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBlendEquationEXT(GLenum mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_blend_minmax)
+};
+
+inline void QOpenGLExtension_EXT_blend_minmax::glBlendEquationEXT(GLenum mode)
+{
+ Q_D(QOpenGLExtension_EXT_blend_minmax);
+ d->BlendEquationEXT(mode);
+}
+
+class QOpenGLExtension_EXT_color_subtablePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP CopyColorSubTableEXT)(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void (QOPENGLF_APIENTRYP ColorSubTableEXT)(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+};
+
+class QOpenGLExtension_EXT_color_subtable : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_color_subtable();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glCopyColorSubTableEXT(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+ void glColorSubTableEXT(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_color_subtable)
+};
+
+inline void QOpenGLExtension_EXT_color_subtable::glCopyColorSubTableEXT(GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ Q_D(QOpenGLExtension_EXT_color_subtable);
+ d->CopyColorSubTableEXT(target, start, x, y, width);
+}
+
+inline void QOpenGLExtension_EXT_color_subtable::glColorSubTableEXT(GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data)
+{
+ Q_D(QOpenGLExtension_EXT_color_subtable);
+ d->ColorSubTableEXT(target, start, count, format, type, data);
+}
+
+class QOpenGLExtension_EXT_compiled_vertex_arrayPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP UnlockArraysEXT)();
+ void (QOPENGLF_APIENTRYP LockArraysEXT)(GLint first, GLsizei count);
+};
+
+class QOpenGLExtension_EXT_compiled_vertex_array : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_compiled_vertex_array();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glUnlockArraysEXT();
+ void glLockArraysEXT(GLint first, GLsizei count);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_compiled_vertex_array)
+};
+
+inline void QOpenGLExtension_EXT_compiled_vertex_array::glUnlockArraysEXT()
+{
+ Q_D(QOpenGLExtension_EXT_compiled_vertex_array);
+ d->UnlockArraysEXT();
+}
+
+inline void QOpenGLExtension_EXT_compiled_vertex_array::glLockArraysEXT(GLint first, GLsizei count)
+{
+ Q_D(QOpenGLExtension_EXT_compiled_vertex_array);
+ d->LockArraysEXT(first, count);
+}
+
+class QOpenGLExtension_EXT_convolutionPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP SeparableFilter2DEXT)(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void (QOPENGLF_APIENTRYP GetSeparableFilterEXT)(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void (QOPENGLF_APIENTRYP GetConvolutionParameterivEXT)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetConvolutionParameterfvEXT)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetConvolutionFilterEXT)(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void (QOPENGLF_APIENTRYP CopyConvolutionFilter2DEXT)(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP CopyConvolutionFilter1DEXT)(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void (QOPENGLF_APIENTRYP ConvolutionParameterivEXT)(GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP ConvolutionParameteriEXT)(GLenum target, GLenum pname, GLint params);
+ void (QOPENGLF_APIENTRYP ConvolutionParameterfvEXT)(GLenum target, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP ConvolutionParameterfEXT)(GLenum target, GLenum pname, GLfloat params);
+ void (QOPENGLF_APIENTRYP ConvolutionFilter2DEXT)(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void (QOPENGLF_APIENTRYP ConvolutionFilter1DEXT)(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+};
+
+class QOpenGLExtension_EXT_convolution : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_convolution();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glSeparableFilter2DEXT(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
+ void glGetSeparableFilterEXT(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
+ void glGetConvolutionParameterivEXT(GLenum target, GLenum pname, GLint *params);
+ void glGetConvolutionParameterfvEXT(GLenum target, GLenum pname, GLfloat *params);
+ void glGetConvolutionFilterEXT(GLenum target, GLenum format, GLenum type, GLvoid *image);
+ void glCopyConvolutionFilter2DEXT(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyConvolutionFilter1DEXT(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glConvolutionParameterivEXT(GLenum target, GLenum pname, const GLint *params);
+ void glConvolutionParameteriEXT(GLenum target, GLenum pname, GLint params);
+ void glConvolutionParameterfvEXT(GLenum target, GLenum pname, const GLfloat *params);
+ void glConvolutionParameterfEXT(GLenum target, GLenum pname, GLfloat params);
+ void glConvolutionFilter2DEXT(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
+ void glConvolutionFilter1DEXT(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_convolution)
+};
+
+inline void QOpenGLExtension_EXT_convolution::glSeparableFilter2DEXT(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->SeparableFilter2DEXT(target, internalformat, width, height, format, type, row, column);
+}
+
+inline void QOpenGLExtension_EXT_convolution::glGetSeparableFilterEXT(GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->GetSeparableFilterEXT(target, format, type, row, column, span);
+}
+
+inline void QOpenGLExtension_EXT_convolution::glGetConvolutionParameterivEXT(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->GetConvolutionParameterivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_convolution::glGetConvolutionParameterfvEXT(GLenum target, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->GetConvolutionParameterfvEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_convolution::glGetConvolutionFilterEXT(GLenum target, GLenum format, GLenum type, GLvoid *image)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->GetConvolutionFilterEXT(target, format, type, image);
+}
+
+inline void QOpenGLExtension_EXT_convolution::glCopyConvolutionFilter2DEXT(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->CopyConvolutionFilter2DEXT(target, internalformat, x, y, width, height);
+}
+
+inline void QOpenGLExtension_EXT_convolution::glCopyConvolutionFilter1DEXT(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->CopyConvolutionFilter1DEXT(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLExtension_EXT_convolution::glConvolutionParameterivEXT(GLenum target, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->ConvolutionParameterivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_convolution::glConvolutionParameteriEXT(GLenum target, GLenum pname, GLint params)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->ConvolutionParameteriEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_convolution::glConvolutionParameterfvEXT(GLenum target, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->ConvolutionParameterfvEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_convolution::glConvolutionParameterfEXT(GLenum target, GLenum pname, GLfloat params)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->ConvolutionParameterfEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_convolution::glConvolutionFilter2DEXT(GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->ConvolutionFilter2DEXT(target, internalformat, width, height, format, type, image);
+}
+
+inline void QOpenGLExtension_EXT_convolution::glConvolutionFilter1DEXT(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image)
+{
+ Q_D(QOpenGLExtension_EXT_convolution);
+ d->ConvolutionFilter1DEXT(target, internalformat, width, format, type, image);
+}
+
+class QOpenGLExtension_EXT_coordinate_framePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BinormalPointerEXT)(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP TangentPointerEXT)(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP Binormal3svEXT)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP Binormal3sEXT)(GLshort bx, GLshort by, GLshort bz);
+ void (QOPENGLF_APIENTRYP Binormal3ivEXT)(const GLint *v);
+ void (QOPENGLF_APIENTRYP Binormal3iEXT)(GLint bx, GLint by, GLint bz);
+ void (QOPENGLF_APIENTRYP Binormal3fvEXT)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Binormal3fEXT)(GLfloat bx, GLfloat by, GLfloat bz);
+ void (QOPENGLF_APIENTRYP Binormal3dvEXT)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP Binormal3dEXT)(GLdouble bx, GLdouble by, GLdouble bz);
+ void (QOPENGLF_APIENTRYP Binormal3bvEXT)(const GLbyte *v);
+ void (QOPENGLF_APIENTRYP Binormal3bEXT)(GLbyte bx, GLbyte by, GLbyte bz);
+ void (QOPENGLF_APIENTRYP Tangent3svEXT)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP Tangent3sEXT)(GLshort tx, GLshort ty, GLshort tz);
+ void (QOPENGLF_APIENTRYP Tangent3ivEXT)(const GLint *v);
+ void (QOPENGLF_APIENTRYP Tangent3iEXT)(GLint tx, GLint ty, GLint tz);
+ void (QOPENGLF_APIENTRYP Tangent3fvEXT)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Tangent3fEXT)(GLfloat tx, GLfloat ty, GLfloat tz);
+ void (QOPENGLF_APIENTRYP Tangent3dvEXT)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP Tangent3dEXT)(GLdouble tx, GLdouble ty, GLdouble tz);
+ void (QOPENGLF_APIENTRYP Tangent3bvEXT)(const GLbyte *v);
+ void (QOPENGLF_APIENTRYP Tangent3bEXT)(GLbyte tx, GLbyte ty, GLbyte tz);
+};
+
+class QOpenGLExtension_EXT_coordinate_frame : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_coordinate_frame();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBinormalPointerEXT(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTangentPointerEXT(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glBinormal3svEXT(const GLshort *v);
+ void glBinormal3sEXT(GLshort bx, GLshort by, GLshort bz);
+ void glBinormal3ivEXT(const GLint *v);
+ void glBinormal3iEXT(GLint bx, GLint by, GLint bz);
+ void glBinormal3fvEXT(const GLfloat *v);
+ void glBinormal3fEXT(GLfloat bx, GLfloat by, GLfloat bz);
+ void glBinormal3dvEXT(const GLdouble *v);
+ void glBinormal3dEXT(GLdouble bx, GLdouble by, GLdouble bz);
+ void glBinormal3bvEXT(const GLbyte *v);
+ void glBinormal3bEXT(GLbyte bx, GLbyte by, GLbyte bz);
+ void glTangent3svEXT(const GLshort *v);
+ void glTangent3sEXT(GLshort tx, GLshort ty, GLshort tz);
+ void glTangent3ivEXT(const GLint *v);
+ void glTangent3iEXT(GLint tx, GLint ty, GLint tz);
+ void glTangent3fvEXT(const GLfloat *v);
+ void glTangent3fEXT(GLfloat tx, GLfloat ty, GLfloat tz);
+ void glTangent3dvEXT(const GLdouble *v);
+ void glTangent3dEXT(GLdouble tx, GLdouble ty, GLdouble tz);
+ void glTangent3bvEXT(const GLbyte *v);
+ void glTangent3bEXT(GLbyte tx, GLbyte ty, GLbyte tz);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_coordinate_frame)
+};
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glBinormalPointerEXT(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->BinormalPointerEXT(type, stride, pointer);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glTangentPointerEXT(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->TangentPointerEXT(type, stride, pointer);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glBinormal3svEXT(const GLshort *v)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Binormal3svEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glBinormal3sEXT(GLshort bx, GLshort by, GLshort bz)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Binormal3sEXT(bx, by, bz);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glBinormal3ivEXT(const GLint *v)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Binormal3ivEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glBinormal3iEXT(GLint bx, GLint by, GLint bz)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Binormal3iEXT(bx, by, bz);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glBinormal3fvEXT(const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Binormal3fvEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glBinormal3fEXT(GLfloat bx, GLfloat by, GLfloat bz)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Binormal3fEXT(bx, by, bz);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glBinormal3dvEXT(const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Binormal3dvEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glBinormal3dEXT(GLdouble bx, GLdouble by, GLdouble bz)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Binormal3dEXT(bx, by, bz);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glBinormal3bvEXT(const GLbyte *v)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Binormal3bvEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glBinormal3bEXT(GLbyte bx, GLbyte by, GLbyte bz)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Binormal3bEXT(bx, by, bz);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glTangent3svEXT(const GLshort *v)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Tangent3svEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glTangent3sEXT(GLshort tx, GLshort ty, GLshort tz)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Tangent3sEXT(tx, ty, tz);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glTangent3ivEXT(const GLint *v)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Tangent3ivEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glTangent3iEXT(GLint tx, GLint ty, GLint tz)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Tangent3iEXT(tx, ty, tz);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glTangent3fvEXT(const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Tangent3fvEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glTangent3fEXT(GLfloat tx, GLfloat ty, GLfloat tz)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Tangent3fEXT(tx, ty, tz);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glTangent3dvEXT(const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Tangent3dvEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glTangent3dEXT(GLdouble tx, GLdouble ty, GLdouble tz)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Tangent3dEXT(tx, ty, tz);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glTangent3bvEXT(const GLbyte *v)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Tangent3bvEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_coordinate_frame::glTangent3bEXT(GLbyte tx, GLbyte ty, GLbyte tz)
+{
+ Q_D(QOpenGLExtension_EXT_coordinate_frame);
+ d->Tangent3bEXT(tx, ty, tz);
+}
+
+class QOpenGLExtension_EXT_copy_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP CopyTexSubImage3DEXT)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP CopyTexSubImage2DEXT)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP CopyTexSubImage1DEXT)(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void (QOPENGLF_APIENTRYP CopyTexImage2DEXT)(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void (QOPENGLF_APIENTRYP CopyTexImage1DEXT)(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+};
+
+class QOpenGLExtension_EXT_copy_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_copy_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glCopyTexSubImage3DEXT(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage2DEXT(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTexSubImage1DEXT(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTexImage2DEXT(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTexImage1DEXT(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_copy_texture)
+};
+
+inline void QOpenGLExtension_EXT_copy_texture::glCopyTexSubImage3DEXT(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_copy_texture);
+ d->CopyTexSubImage3DEXT(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLExtension_EXT_copy_texture::glCopyTexSubImage2DEXT(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_copy_texture);
+ d->CopyTexSubImage2DEXT(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLExtension_EXT_copy_texture::glCopyTexSubImage1DEXT(GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ Q_D(QOpenGLExtension_EXT_copy_texture);
+ d->CopyTexSubImage1DEXT(target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLExtension_EXT_copy_texture::glCopyTexImage2DEXT(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ Q_D(QOpenGLExtension_EXT_copy_texture);
+ d->CopyTexImage2DEXT(target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLExtension_EXT_copy_texture::glCopyTexImage1DEXT(GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ Q_D(QOpenGLExtension_EXT_copy_texture);
+ d->CopyTexImage1DEXT(target, level, internalformat, x, y, width, border);
+}
+
+class QOpenGLExtension_EXT_cull_vertexPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP CullParameterfvEXT)(GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP CullParameterdvEXT)(GLenum pname, GLdouble *params);
+};
+
+class QOpenGLExtension_EXT_cull_vertex : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_cull_vertex();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glCullParameterfvEXT(GLenum pname, GLfloat *params);
+ void glCullParameterdvEXT(GLenum pname, GLdouble *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_cull_vertex)
+};
+
+inline void QOpenGLExtension_EXT_cull_vertex::glCullParameterfvEXT(GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_cull_vertex);
+ d->CullParameterfvEXT(pname, params);
+}
+
+inline void QOpenGLExtension_EXT_cull_vertex::glCullParameterdvEXT(GLenum pname, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_EXT_cull_vertex);
+ d->CullParameterdvEXT(pname, params);
+}
+
+class QOpenGLExtension_EXT_depth_bounds_testPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DepthBoundsEXT)(GLclampd zmin, GLclampd zmax);
+};
+
+class QOpenGLExtension_EXT_depth_bounds_test : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_depth_bounds_test();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDepthBoundsEXT(GLclampd zmin, GLclampd zmax);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_depth_bounds_test)
+};
+
+inline void QOpenGLExtension_EXT_depth_bounds_test::glDepthBoundsEXT(GLclampd zmin, GLclampd zmax)
+{
+ Q_D(QOpenGLExtension_EXT_depth_bounds_test);
+ d->DepthBoundsEXT(zmin, zmax);
+}
+
+class QOpenGLExtension_EXT_direct_state_accessPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4x3dvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4x2dvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3x4dvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3x2dvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2x4dvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2x3dvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4dvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3dvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2dvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4dvEXT)(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3dvEXT)(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2dvEXT)(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1dvEXT)(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4dEXT)(GLuint program, GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP ProgramUniform3dEXT)(GLuint program, GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP ProgramUniform2dEXT)(GLuint program, GLint location, GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP ProgramUniform1dEXT)(GLuint program, GLint location, GLdouble x);
+ void (QOPENGLF_APIENTRYP MultiTexRenderbufferEXT)(GLenum texunit, GLenum target, GLuint renderbuffer);
+ void (QOPENGLF_APIENTRYP TextureRenderbufferEXT)(GLuint texture, GLenum target, GLuint renderbuffer);
+ void (QOPENGLF_APIENTRYP NamedFramebufferTextureFaceEXT)(GLuint framebuffer, GLenum attachment, GLuint texture, GLint level, GLenum face);
+ void (QOPENGLF_APIENTRYP NamedFramebufferTextureLayerEXT)(GLuint framebuffer, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void (QOPENGLF_APIENTRYP NamedFramebufferTextureEXT)(GLuint framebuffer, GLenum attachment, GLuint texture, GLint level);
+ void (QOPENGLF_APIENTRYP NamedRenderbufferStorageMultisampleCoverageEXT)(GLuint renderbuffer, GLsizei coverageSamples, GLsizei colorSamples, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP NamedRenderbufferStorageMultisampleEXT)(GLuint renderbuffer, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP GetFramebufferParameterivEXT)(GLuint framebuffer, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP FramebufferReadBufferEXT)(GLuint framebuffer, GLenum mode);
+ void (QOPENGLF_APIENTRYP FramebufferDrawBuffersEXT)(GLuint framebuffer, GLsizei n, const GLenum *bufs);
+ void (QOPENGLF_APIENTRYP FramebufferDrawBufferEXT)(GLuint framebuffer, GLenum mode);
+ void (QOPENGLF_APIENTRYP GenerateMultiTexMipmapEXT)(GLenum texunit, GLenum target);
+ void (QOPENGLF_APIENTRYP GenerateTextureMipmapEXT)(GLuint texture, GLenum target);
+ void (QOPENGLF_APIENTRYP GetNamedFramebufferAttachmentParameterivEXT)(GLuint framebuffer, GLenum attachment, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP NamedFramebufferRenderbufferEXT)(GLuint framebuffer, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void (QOPENGLF_APIENTRYP NamedFramebufferTexture3DEXT)(GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void (QOPENGLF_APIENTRYP NamedFramebufferTexture2DEXT)(GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void (QOPENGLF_APIENTRYP NamedFramebufferTexture1DEXT)(GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum (QOPENGLF_APIENTRYP CheckNamedFramebufferStatusEXT)(GLuint framebuffer, GLenum target);
+ void (QOPENGLF_APIENTRYP GetNamedRenderbufferParameterivEXT)(GLuint renderbuffer, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP NamedRenderbufferStorageEXT)(GLuint renderbuffer, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP MultiTexBufferEXT)(GLenum texunit, GLenum target, GLenum internalformat, GLuint buffer);
+ void (QOPENGLF_APIENTRYP TextureBufferEXT)(GLuint texture, GLenum target, GLenum internalformat, GLuint buffer);
+ void (QOPENGLF_APIENTRYP GetNamedBufferSubDataEXT)(GLuint buffer, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void (QOPENGLF_APIENTRYP GetNamedBufferPointervEXT)(GLuint buffer, GLenum pname, GLvoid* *params);
+ void (QOPENGLF_APIENTRYP GetNamedBufferParameterivEXT)(GLuint buffer, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP NamedCopyBufferSubDataEXT)(GLuint readBuffer, GLuint writeBuffer, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void (QOPENGLF_APIENTRYP FlushMappedNamedBufferRangeEXT)(GLuint buffer, GLintptr offset, GLsizeiptr length);
+ GLvoid* (QOPENGLF_APIENTRYP MapNamedBufferRangeEXT)(GLuint buffer, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ GLboolean (QOPENGLF_APIENTRYP UnmapNamedBufferEXT)(GLuint buffer);
+ GLvoid* (QOPENGLF_APIENTRYP MapNamedBufferEXT)(GLuint buffer, GLenum access);
+ void (QOPENGLF_APIENTRYP NamedBufferSubDataEXT)(GLuint buffer, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void (QOPENGLF_APIENTRYP NamedBufferDataEXT)(GLuint buffer, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ void (QOPENGLF_APIENTRYP ProgramUniform4uivEXT)(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3uivEXT)(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2uivEXT)(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1uivEXT)(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4uiEXT)(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void (QOPENGLF_APIENTRYP ProgramUniform3uiEXT)(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void (QOPENGLF_APIENTRYP ProgramUniform2uiEXT)(GLuint program, GLint location, GLuint v0, GLuint v1);
+ void (QOPENGLF_APIENTRYP ProgramUniform1uiEXT)(GLuint program, GLint location, GLuint v0);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4x3fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3x4fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4x2fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2x4fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3x2fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2x3fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4ivEXT)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3ivEXT)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2ivEXT)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1ivEXT)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4fvEXT)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3fvEXT)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2fvEXT)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1fvEXT)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4iEXT)(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void (QOPENGLF_APIENTRYP ProgramUniform3iEXT)(GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+ void (QOPENGLF_APIENTRYP ProgramUniform2iEXT)(GLuint program, GLint location, GLint v0, GLint v1);
+ void (QOPENGLF_APIENTRYP ProgramUniform1iEXT)(GLuint program, GLint location, GLint v0);
+ void (QOPENGLF_APIENTRYP ProgramUniform4fEXT)(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void (QOPENGLF_APIENTRYP ProgramUniform3fEXT)(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void (QOPENGLF_APIENTRYP ProgramUniform2fEXT)(GLuint program, GLint location, GLfloat v0, GLfloat v1);
+ void (QOPENGLF_APIENTRYP ProgramUniform1fEXT)(GLuint program, GLint location, GLfloat v0);
+ void (QOPENGLF_APIENTRYP GetMultiTexParameterIuivEXT)(GLenum texunit, GLenum target, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetMultiTexParameterIivEXT)(GLenum texunit, GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP MultiTexParameterIuivEXT)(GLenum texunit, GLenum target, GLenum pname, const GLuint *params);
+ void (QOPENGLF_APIENTRYP MultiTexParameterIivEXT)(GLenum texunit, GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP GetTextureParameterIuivEXT)(GLuint texture, GLenum target, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetTextureParameterIivEXT)(GLuint texture, GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP TextureParameterIuivEXT)(GLuint texture, GLenum target, GLenum pname, const GLuint *params);
+ void (QOPENGLF_APIENTRYP TextureParameterIivEXT)(GLuint texture, GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP GetNamedProgramLocalParameterIuivEXT)(GLuint program, GLenum target, GLuint index, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetNamedProgramLocalParameterIivEXT)(GLuint program, GLenum target, GLuint index, GLint *params);
+ void (QOPENGLF_APIENTRYP NamedProgramLocalParametersI4uivEXT)(GLuint program, GLenum target, GLuint index, GLsizei count, const GLuint *params);
+ void (QOPENGLF_APIENTRYP NamedProgramLocalParameterI4uivEXT)(GLuint program, GLenum target, GLuint index, const GLuint *params);
+ void (QOPENGLF_APIENTRYP NamedProgramLocalParameterI4uiEXT)(GLuint program, GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void (QOPENGLF_APIENTRYP NamedProgramLocalParametersI4ivEXT)(GLuint program, GLenum target, GLuint index, GLsizei count, const GLint *params);
+ void (QOPENGLF_APIENTRYP NamedProgramLocalParameterI4ivEXT)(GLuint program, GLenum target, GLuint index, const GLint *params);
+ void (QOPENGLF_APIENTRYP NamedProgramLocalParameterI4iEXT)(GLuint program, GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void (QOPENGLF_APIENTRYP NamedProgramLocalParameters4fvEXT)(GLuint program, GLenum target, GLuint index, GLsizei count, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetNamedProgramStringEXT)(GLuint program, GLenum target, GLenum pname, GLvoid *string);
+ void (QOPENGLF_APIENTRYP GetNamedProgramivEXT)(GLuint program, GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetNamedProgramLocalParameterfvEXT)(GLuint program, GLenum target, GLuint index, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetNamedProgramLocalParameterdvEXT)(GLuint program, GLenum target, GLuint index, GLdouble *params);
+ void (QOPENGLF_APIENTRYP NamedProgramLocalParameter4fvEXT)(GLuint program, GLenum target, GLuint index, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP NamedProgramLocalParameter4fEXT)(GLuint program, GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP NamedProgramLocalParameter4dvEXT)(GLuint program, GLenum target, GLuint index, const GLdouble *params);
+ void (QOPENGLF_APIENTRYP NamedProgramLocalParameter4dEXT)(GLuint program, GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP NamedProgramStringEXT)(GLuint program, GLenum target, GLenum format, GLsizei len, const GLvoid *string);
+ void (QOPENGLF_APIENTRYP GetCompressedMultiTexImageEXT)(GLenum texunit, GLenum target, GLint lod, GLvoid *img);
+ void (QOPENGLF_APIENTRYP CompressedMultiTexSubImage1DEXT)(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *bits);
+ void (QOPENGLF_APIENTRYP CompressedMultiTexSubImage2DEXT)(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *bits);
+ void (QOPENGLF_APIENTRYP CompressedMultiTexSubImage3DEXT)(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *bits);
+ void (QOPENGLF_APIENTRYP CompressedMultiTexImage1DEXT)(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *bits);
+ void (QOPENGLF_APIENTRYP CompressedMultiTexImage2DEXT)(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *bits);
+ void (QOPENGLF_APIENTRYP CompressedMultiTexImage3DEXT)(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *bits);
+ void (QOPENGLF_APIENTRYP GetCompressedTextureImageEXT)(GLuint texture, GLenum target, GLint lod, GLvoid *img);
+ void (QOPENGLF_APIENTRYP CompressedTextureSubImage1DEXT)(GLuint texture, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *bits);
+ void (QOPENGLF_APIENTRYP CompressedTextureSubImage2DEXT)(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *bits);
+ void (QOPENGLF_APIENTRYP CompressedTextureSubImage3DEXT)(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *bits);
+ void (QOPENGLF_APIENTRYP CompressedTextureImage1DEXT)(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *bits);
+ void (QOPENGLF_APIENTRYP CompressedTextureImage2DEXT)(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *bits);
+ void (QOPENGLF_APIENTRYP CompressedTextureImage3DEXT)(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *bits);
+ void (QOPENGLF_APIENTRYP GetPointerIndexedvEXT)(GLenum target, GLuint index, GLvoid* *data);
+ void (QOPENGLF_APIENTRYP GetDoubleIndexedvEXT)(GLenum target, GLuint index, GLdouble *data);
+ void (QOPENGLF_APIENTRYP GetFloatIndexedvEXT)(GLenum target, GLuint index, GLfloat *data);
+ void (QOPENGLF_APIENTRYP GetMultiTexGenivEXT)(GLenum texunit, GLenum coord, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetMultiTexGenfvEXT)(GLenum texunit, GLenum coord, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetMultiTexGendvEXT)(GLenum texunit, GLenum coord, GLenum pname, GLdouble *params);
+ void (QOPENGLF_APIENTRYP GetMultiTexEnvivEXT)(GLenum texunit, GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetMultiTexEnvfvEXT)(GLenum texunit, GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP MultiTexGenivEXT)(GLenum texunit, GLenum coord, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP MultiTexGeniEXT)(GLenum texunit, GLenum coord, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP MultiTexGenfvEXT)(GLenum texunit, GLenum coord, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP MultiTexGenfEXT)(GLenum texunit, GLenum coord, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP MultiTexGendvEXT)(GLenum texunit, GLenum coord, GLenum pname, const GLdouble *params);
+ void (QOPENGLF_APIENTRYP MultiTexGendEXT)(GLenum texunit, GLenum coord, GLenum pname, GLdouble param);
+ void (QOPENGLF_APIENTRYP MultiTexEnvivEXT)(GLenum texunit, GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP MultiTexEnviEXT)(GLenum texunit, GLenum target, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP MultiTexEnvfvEXT)(GLenum texunit, GLenum target, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP MultiTexEnvfEXT)(GLenum texunit, GLenum target, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP MultiTexCoordPointerEXT)(GLenum texunit, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP DisableClientStateIndexedEXT)(GLenum array, GLuint index);
+ void (QOPENGLF_APIENTRYP EnableClientStateIndexedEXT)(GLenum array, GLuint index);
+ void (QOPENGLF_APIENTRYP BindMultiTextureEXT)(GLenum texunit, GLenum target, GLuint texture);
+ void (QOPENGLF_APIENTRYP CopyMultiTexSubImage3DEXT)(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP MultiTexSubImage3DEXT)(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP MultiTexImage3DEXT)(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP GetMultiTexLevelParameterivEXT)(GLenum texunit, GLenum target, GLint level, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetMultiTexLevelParameterfvEXT)(GLenum texunit, GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetMultiTexParameterivEXT)(GLenum texunit, GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetMultiTexParameterfvEXT)(GLenum texunit, GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetMultiTexImageEXT)(GLenum texunit, GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP CopyMultiTexSubImage2DEXT)(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP CopyMultiTexSubImage1DEXT)(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void (QOPENGLF_APIENTRYP CopyMultiTexImage2DEXT)(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void (QOPENGLF_APIENTRYP CopyMultiTexImage1DEXT)(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void (QOPENGLF_APIENTRYP MultiTexSubImage2DEXT)(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP MultiTexSubImage1DEXT)(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP MultiTexImage2DEXT)(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP MultiTexImage1DEXT)(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP MultiTexParameterivEXT)(GLenum texunit, GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP MultiTexParameteriEXT)(GLenum texunit, GLenum target, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP MultiTexParameterfvEXT)(GLenum texunit, GLenum target, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP MultiTexParameterfEXT)(GLenum texunit, GLenum target, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP CopyTextureSubImage3DEXT)(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP TextureSubImage3DEXT)(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP TextureImage3DEXT)(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP GetTextureLevelParameterivEXT)(GLuint texture, GLenum target, GLint level, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetTextureLevelParameterfvEXT)(GLuint texture, GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetTextureParameterivEXT)(GLuint texture, GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetTextureParameterfvEXT)(GLuint texture, GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetTextureImageEXT)(GLuint texture, GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP CopyTextureSubImage2DEXT)(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP CopyTextureSubImage1DEXT)(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void (QOPENGLF_APIENTRYP CopyTextureImage2DEXT)(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void (QOPENGLF_APIENTRYP CopyTextureImage1DEXT)(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void (QOPENGLF_APIENTRYP TextureSubImage2DEXT)(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP TextureSubImage1DEXT)(GLuint texture, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP TextureImage2DEXT)(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP TextureImage1DEXT)(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP TextureParameterivEXT)(GLuint texture, GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP TextureParameteriEXT)(GLuint texture, GLenum target, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP TextureParameterfvEXT)(GLuint texture, GLenum target, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP TextureParameterfEXT)(GLuint texture, GLenum target, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP MatrixMultTransposedEXT)(GLenum mode, const GLdouble *m);
+ void (QOPENGLF_APIENTRYP MatrixMultTransposefEXT)(GLenum mode, const GLfloat *m);
+ void (QOPENGLF_APIENTRYP MatrixLoadTransposedEXT)(GLenum mode, const GLdouble *m);
+ void (QOPENGLF_APIENTRYP MatrixLoadTransposefEXT)(GLenum mode, const GLfloat *m);
+ void (QOPENGLF_APIENTRYP MatrixPushEXT)(GLenum mode);
+ void (QOPENGLF_APIENTRYP MatrixPopEXT)(GLenum mode);
+ void (QOPENGLF_APIENTRYP MatrixOrthoEXT)(GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void (QOPENGLF_APIENTRYP MatrixFrustumEXT)(GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void (QOPENGLF_APIENTRYP MatrixTranslatedEXT)(GLenum mode, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP MatrixTranslatefEXT)(GLenum mode, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP MatrixScaledEXT)(GLenum mode, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP MatrixScalefEXT)(GLenum mode, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP MatrixRotatedEXT)(GLenum mode, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP MatrixRotatefEXT)(GLenum mode, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP MatrixLoadIdentityEXT)(GLenum mode);
+ void (QOPENGLF_APIENTRYP MatrixMultdEXT)(GLenum mode, const GLdouble *m);
+ void (QOPENGLF_APIENTRYP MatrixMultfEXT)(GLenum mode, const GLfloat *m);
+ void (QOPENGLF_APIENTRYP MatrixLoaddEXT)(GLenum mode, const GLdouble *m);
+ void (QOPENGLF_APIENTRYP MatrixLoadfEXT)(GLenum mode, const GLfloat *m);
+ void (QOPENGLF_APIENTRYP PushClientAttribDefaultEXT)(GLbitfield mask);
+ void (QOPENGLF_APIENTRYP ClientAttribDefaultEXT)(GLbitfield mask);
+ void (QOPENGLF_APIENTRYP TextureStorage3DMultisampleEXT)(GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void (QOPENGLF_APIENTRYP TextureStorage2DMultisampleEXT)(GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void (QOPENGLF_APIENTRYP TextureBufferRangeEXT)(GLuint texture, GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void (QOPENGLF_APIENTRYP GetNamedFramebufferParameterivEXT)(GLuint framebuffer, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP NamedFramebufferParameteriEXT)(GLuint framebuffer, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP VertexArrayVertexBindingDivisorEXT)(GLuint vaobj, GLuint bindingindex, GLuint divisor);
+ void (QOPENGLF_APIENTRYP VertexArrayVertexAttribBindingEXT)(GLuint vaobj, GLuint attribindex, GLuint bindingindex);
+ void (QOPENGLF_APIENTRYP VertexArrayVertexAttribLFormatEXT)(GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void (QOPENGLF_APIENTRYP VertexArrayVertexAttribIFormatEXT)(GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void (QOPENGLF_APIENTRYP VertexArrayVertexAttribFormatEXT)(GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset);
+ void (QOPENGLF_APIENTRYP VertexArrayBindVertexBufferEXT)(GLuint vaobj, GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+ void (QOPENGLF_APIENTRYP ClearNamedBufferSubDataEXT)(GLuint buffer, GLenum internalformat, GLsizeiptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data);
+ void (QOPENGLF_APIENTRYP ClearNamedBufferDataEXT)(GLuint buffer, GLenum internalformat, GLenum format, GLenum type, const void *data);
+ void (QOPENGLF_APIENTRYP TextureStorage3DEXT)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void (QOPENGLF_APIENTRYP TextureStorage2DEXT)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP TextureStorage1DEXT)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+};
+
+class QOpenGLExtension_EXT_direct_state_access : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_direct_state_access();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glProgramUniformMatrix4x3dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4x2dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x4dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3x2dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x4dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2x3dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix4dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix3dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniformMatrix2dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value);
+ void glProgramUniform4dvEXT(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform3dvEXT(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform2dvEXT(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform1dvEXT(GLuint program, GLint location, GLsizei count, const GLdouble *value);
+ void glProgramUniform4dEXT(GLuint program, GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glProgramUniform3dEXT(GLuint program, GLint location, GLdouble x, GLdouble y, GLdouble z);
+ void glProgramUniform2dEXT(GLuint program, GLint location, GLdouble x, GLdouble y);
+ void glProgramUniform1dEXT(GLuint program, GLint location, GLdouble x);
+ void glMultiTexRenderbufferEXT(GLenum texunit, GLenum target, GLuint renderbuffer);
+ void glTextureRenderbufferEXT(GLuint texture, GLenum target, GLuint renderbuffer);
+ void glNamedFramebufferTextureFaceEXT(GLuint framebuffer, GLenum attachment, GLuint texture, GLint level, GLenum face);
+ void glNamedFramebufferTextureLayerEXT(GLuint framebuffer, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glNamedFramebufferTextureEXT(GLuint framebuffer, GLenum attachment, GLuint texture, GLint level);
+ void glNamedRenderbufferStorageMultisampleCoverageEXT(GLuint renderbuffer, GLsizei coverageSamples, GLsizei colorSamples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glNamedRenderbufferStorageMultisampleEXT(GLuint renderbuffer, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGetFramebufferParameterivEXT(GLuint framebuffer, GLenum pname, GLint *params);
+ void glFramebufferReadBufferEXT(GLuint framebuffer, GLenum mode);
+ void glFramebufferDrawBuffersEXT(GLuint framebuffer, GLsizei n, const GLenum *bufs);
+ void glFramebufferDrawBufferEXT(GLuint framebuffer, GLenum mode);
+ void glGenerateMultiTexMipmapEXT(GLenum texunit, GLenum target);
+ void glGenerateTextureMipmapEXT(GLuint texture, GLenum target);
+ void glGetNamedFramebufferAttachmentParameterivEXT(GLuint framebuffer, GLenum attachment, GLenum pname, GLint *params);
+ void glNamedFramebufferRenderbufferEXT(GLuint framebuffer, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glNamedFramebufferTexture3DEXT(GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glNamedFramebufferTexture2DEXT(GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glNamedFramebufferTexture1DEXT(GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckNamedFramebufferStatusEXT(GLuint framebuffer, GLenum target);
+ void glGetNamedRenderbufferParameterivEXT(GLuint renderbuffer, GLenum pname, GLint *params);
+ void glNamedRenderbufferStorageEXT(GLuint renderbuffer, GLenum internalformat, GLsizei width, GLsizei height);
+ void glMultiTexBufferEXT(GLenum texunit, GLenum target, GLenum internalformat, GLuint buffer);
+ void glTextureBufferEXT(GLuint texture, GLenum target, GLenum internalformat, GLuint buffer);
+ void glGetNamedBufferSubDataEXT(GLuint buffer, GLintptr offset, GLsizeiptr size, GLvoid *data);
+ void glGetNamedBufferPointervEXT(GLuint buffer, GLenum pname, GLvoid* *params);
+ void glGetNamedBufferParameterivEXT(GLuint buffer, GLenum pname, GLint *params);
+ void glNamedCopyBufferSubDataEXT(GLuint readBuffer, GLuint writeBuffer, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+ void glFlushMappedNamedBufferRangeEXT(GLuint buffer, GLintptr offset, GLsizeiptr length);
+ GLvoid* glMapNamedBufferRangeEXT(GLuint buffer, GLintptr offset, GLsizeiptr length, GLbitfield access);
+ GLboolean glUnmapNamedBufferEXT(GLuint buffer);
+ GLvoid* glMapNamedBufferEXT(GLuint buffer, GLenum access);
+ void glNamedBufferSubDataEXT(GLuint buffer, GLintptr offset, GLsizeiptr size, const GLvoid *data);
+ void glNamedBufferDataEXT(GLuint buffer, GLsizeiptr size, const GLvoid *data, GLenum usage);
+ void glProgramUniform4uivEXT(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform3uivEXT(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform2uivEXT(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform1uivEXT(GLuint program, GLint location, GLsizei count, const GLuint *value);
+ void glProgramUniform4uiEXT(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glProgramUniform3uiEXT(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glProgramUniform2uiEXT(GLuint program, GLint location, GLuint v0, GLuint v1);
+ void glProgramUniform1uiEXT(GLuint program, GLint location, GLuint v0);
+ void glProgramUniformMatrix4x3fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x4fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4x2fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x4fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3x2fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2x3fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix2fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniform4ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform3ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform2ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform1ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform4fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform3fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform2fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform1fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform4iEXT(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+ void glProgramUniform3iEXT(GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+ void glProgramUniform2iEXT(GLuint program, GLint location, GLint v0, GLint v1);
+ void glProgramUniform1iEXT(GLuint program, GLint location, GLint v0);
+ void glProgramUniform4fEXT(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+ void glProgramUniform3fEXT(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+ void glProgramUniform2fEXT(GLuint program, GLint location, GLfloat v0, GLfloat v1);
+ void glProgramUniform1fEXT(GLuint program, GLint location, GLfloat v0);
+ void glGetMultiTexParameterIuivEXT(GLenum texunit, GLenum target, GLenum pname, GLuint *params);
+ void glGetMultiTexParameterIivEXT(GLenum texunit, GLenum target, GLenum pname, GLint *params);
+ void glMultiTexParameterIuivEXT(GLenum texunit, GLenum target, GLenum pname, const GLuint *params);
+ void glMultiTexParameterIivEXT(GLenum texunit, GLenum target, GLenum pname, const GLint *params);
+ void glGetTextureParameterIuivEXT(GLuint texture, GLenum target, GLenum pname, GLuint *params);
+ void glGetTextureParameterIivEXT(GLuint texture, GLenum target, GLenum pname, GLint *params);
+ void glTextureParameterIuivEXT(GLuint texture, GLenum target, GLenum pname, const GLuint *params);
+ void glTextureParameterIivEXT(GLuint texture, GLenum target, GLenum pname, const GLint *params);
+ void glGetNamedProgramLocalParameterIuivEXT(GLuint program, GLenum target, GLuint index, GLuint *params);
+ void glGetNamedProgramLocalParameterIivEXT(GLuint program, GLenum target, GLuint index, GLint *params);
+ void glNamedProgramLocalParametersI4uivEXT(GLuint program, GLenum target, GLuint index, GLsizei count, const GLuint *params);
+ void glNamedProgramLocalParameterI4uivEXT(GLuint program, GLenum target, GLuint index, const GLuint *params);
+ void glNamedProgramLocalParameterI4uiEXT(GLuint program, GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void glNamedProgramLocalParametersI4ivEXT(GLuint program, GLenum target, GLuint index, GLsizei count, const GLint *params);
+ void glNamedProgramLocalParameterI4ivEXT(GLuint program, GLenum target, GLuint index, const GLint *params);
+ void glNamedProgramLocalParameterI4iEXT(GLuint program, GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void glNamedProgramLocalParameters4fvEXT(GLuint program, GLenum target, GLuint index, GLsizei count, const GLfloat *params);
+ void glGetNamedProgramStringEXT(GLuint program, GLenum target, GLenum pname, GLvoid *string);
+ void glGetNamedProgramivEXT(GLuint program, GLenum target, GLenum pname, GLint *params);
+ void glGetNamedProgramLocalParameterfvEXT(GLuint program, GLenum target, GLuint index, GLfloat *params);
+ void glGetNamedProgramLocalParameterdvEXT(GLuint program, GLenum target, GLuint index, GLdouble *params);
+ void glNamedProgramLocalParameter4fvEXT(GLuint program, GLenum target, GLuint index, const GLfloat *params);
+ void glNamedProgramLocalParameter4fEXT(GLuint program, GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glNamedProgramLocalParameter4dvEXT(GLuint program, GLenum target, GLuint index, const GLdouble *params);
+ void glNamedProgramLocalParameter4dEXT(GLuint program, GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glNamedProgramStringEXT(GLuint program, GLenum target, GLenum format, GLsizei len, const GLvoid *string);
+ void glGetCompressedMultiTexImageEXT(GLenum texunit, GLenum target, GLint lod, GLvoid *img);
+ void glCompressedMultiTexSubImage1DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *bits);
+ void glCompressedMultiTexSubImage2DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *bits);
+ void glCompressedMultiTexSubImage3DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *bits);
+ void glCompressedMultiTexImage1DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *bits);
+ void glCompressedMultiTexImage2DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *bits);
+ void glCompressedMultiTexImage3DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *bits);
+ void glGetCompressedTextureImageEXT(GLuint texture, GLenum target, GLint lod, GLvoid *img);
+ void glCompressedTextureSubImage1DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *bits);
+ void glCompressedTextureSubImage2DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *bits);
+ void glCompressedTextureSubImage3DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *bits);
+ void glCompressedTextureImage1DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *bits);
+ void glCompressedTextureImage2DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *bits);
+ void glCompressedTextureImage3DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *bits);
+ void glGetPointerIndexedvEXT(GLenum target, GLuint index, GLvoid* *data);
+ void glGetDoubleIndexedvEXT(GLenum target, GLuint index, GLdouble *data);
+ void glGetFloatIndexedvEXT(GLenum target, GLuint index, GLfloat *data);
+ void glGetMultiTexGenivEXT(GLenum texunit, GLenum coord, GLenum pname, GLint *params);
+ void glGetMultiTexGenfvEXT(GLenum texunit, GLenum coord, GLenum pname, GLfloat *params);
+ void glGetMultiTexGendvEXT(GLenum texunit, GLenum coord, GLenum pname, GLdouble *params);
+ void glGetMultiTexEnvivEXT(GLenum texunit, GLenum target, GLenum pname, GLint *params);
+ void glGetMultiTexEnvfvEXT(GLenum texunit, GLenum target, GLenum pname, GLfloat *params);
+ void glMultiTexGenivEXT(GLenum texunit, GLenum coord, GLenum pname, const GLint *params);
+ void glMultiTexGeniEXT(GLenum texunit, GLenum coord, GLenum pname, GLint param);
+ void glMultiTexGenfvEXT(GLenum texunit, GLenum coord, GLenum pname, const GLfloat *params);
+ void glMultiTexGenfEXT(GLenum texunit, GLenum coord, GLenum pname, GLfloat param);
+ void glMultiTexGendvEXT(GLenum texunit, GLenum coord, GLenum pname, const GLdouble *params);
+ void glMultiTexGendEXT(GLenum texunit, GLenum coord, GLenum pname, GLdouble param);
+ void glMultiTexEnvivEXT(GLenum texunit, GLenum target, GLenum pname, const GLint *params);
+ void glMultiTexEnviEXT(GLenum texunit, GLenum target, GLenum pname, GLint param);
+ void glMultiTexEnvfvEXT(GLenum texunit, GLenum target, GLenum pname, const GLfloat *params);
+ void glMultiTexEnvfEXT(GLenum texunit, GLenum target, GLenum pname, GLfloat param);
+ void glMultiTexCoordPointerEXT(GLenum texunit, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glDisableClientStateIndexedEXT(GLenum array, GLuint index);
+ void glEnableClientStateIndexedEXT(GLenum array, GLuint index);
+ void glBindMultiTextureEXT(GLenum texunit, GLenum target, GLuint texture);
+ void glCopyMultiTexSubImage3DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glMultiTexSubImage3DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glMultiTexImage3DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glGetMultiTexLevelParameterivEXT(GLenum texunit, GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetMultiTexLevelParameterfvEXT(GLenum texunit, GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetMultiTexParameterivEXT(GLenum texunit, GLenum target, GLenum pname, GLint *params);
+ void glGetMultiTexParameterfvEXT(GLenum texunit, GLenum target, GLenum pname, GLfloat *params);
+ void glGetMultiTexImageEXT(GLenum texunit, GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ void glCopyMultiTexSubImage2DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyMultiTexSubImage1DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyMultiTexImage2DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyMultiTexImage1DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glMultiTexSubImage2DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glMultiTexSubImage1DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glMultiTexImage2DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glMultiTexImage1DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glMultiTexParameterivEXT(GLenum texunit, GLenum target, GLenum pname, const GLint *params);
+ void glMultiTexParameteriEXT(GLenum texunit, GLenum target, GLenum pname, GLint param);
+ void glMultiTexParameterfvEXT(GLenum texunit, GLenum target, GLenum pname, const GLfloat *params);
+ void glMultiTexParameterfEXT(GLenum texunit, GLenum target, GLenum pname, GLfloat param);
+ void glCopyTextureSubImage3DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glTextureSubImage3DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTextureImage3DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glGetTextureLevelParameterivEXT(GLuint texture, GLenum target, GLint level, GLenum pname, GLint *params);
+ void glGetTextureLevelParameterfvEXT(GLuint texture, GLenum target, GLint level, GLenum pname, GLfloat *params);
+ void glGetTextureParameterivEXT(GLuint texture, GLenum target, GLenum pname, GLint *params);
+ void glGetTextureParameterfvEXT(GLuint texture, GLenum target, GLenum pname, GLfloat *params);
+ void glGetTextureImageEXT(GLuint texture, GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+ void glCopyTextureSubImage2DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCopyTextureSubImage1DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+ void glCopyTextureImage2DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+ void glCopyTextureImage1DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
+ void glTextureSubImage2DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTextureSubImage1DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTextureImage2DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTextureImage1DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTextureParameterivEXT(GLuint texture, GLenum target, GLenum pname, const GLint *params);
+ void glTextureParameteriEXT(GLuint texture, GLenum target, GLenum pname, GLint param);
+ void glTextureParameterfvEXT(GLuint texture, GLenum target, GLenum pname, const GLfloat *params);
+ void glTextureParameterfEXT(GLuint texture, GLenum target, GLenum pname, GLfloat param);
+ void glMatrixMultTransposedEXT(GLenum mode, const GLdouble *m);
+ void glMatrixMultTransposefEXT(GLenum mode, const GLfloat *m);
+ void glMatrixLoadTransposedEXT(GLenum mode, const GLdouble *m);
+ void glMatrixLoadTransposefEXT(GLenum mode, const GLfloat *m);
+ void glMatrixPushEXT(GLenum mode);
+ void glMatrixPopEXT(GLenum mode);
+ void glMatrixOrthoEXT(GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMatrixFrustumEXT(GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+ void glMatrixTranslatedEXT(GLenum mode, GLdouble x, GLdouble y, GLdouble z);
+ void glMatrixTranslatefEXT(GLenum mode, GLfloat x, GLfloat y, GLfloat z);
+ void glMatrixScaledEXT(GLenum mode, GLdouble x, GLdouble y, GLdouble z);
+ void glMatrixScalefEXT(GLenum mode, GLfloat x, GLfloat y, GLfloat z);
+ void glMatrixRotatedEXT(GLenum mode, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+ void glMatrixRotatefEXT(GLenum mode, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+ void glMatrixLoadIdentityEXT(GLenum mode);
+ void glMatrixMultdEXT(GLenum mode, const GLdouble *m);
+ void glMatrixMultfEXT(GLenum mode, const GLfloat *m);
+ void glMatrixLoaddEXT(GLenum mode, const GLdouble *m);
+ void glMatrixLoadfEXT(GLenum mode, const GLfloat *m);
+ void glPushClientAttribDefaultEXT(GLbitfield mask);
+ void glClientAttribDefaultEXT(GLbitfield mask);
+ void glTextureStorage3DMultisampleEXT(GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+ void glTextureStorage2DMultisampleEXT(GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+ void glTextureBufferRangeEXT(GLuint texture, GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glGetNamedFramebufferParameterivEXT(GLuint framebuffer, GLenum pname, GLint *params);
+ void glNamedFramebufferParameteriEXT(GLuint framebuffer, GLenum pname, GLint param);
+ void glVertexArrayVertexBindingDivisorEXT(GLuint vaobj, GLuint bindingindex, GLuint divisor);
+ void glVertexArrayVertexAttribBindingEXT(GLuint vaobj, GLuint attribindex, GLuint bindingindex);
+ void glVertexArrayVertexAttribLFormatEXT(GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void glVertexArrayVertexAttribIFormatEXT(GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset);
+ void glVertexArrayVertexAttribFormatEXT(GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset);
+ void glVertexArrayBindVertexBufferEXT(GLuint vaobj, GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+ void glClearNamedBufferSubDataEXT(GLuint buffer, GLenum internalformat, GLsizeiptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data);
+ void glClearNamedBufferDataEXT(GLuint buffer, GLenum internalformat, GLenum format, GLenum type, const void *data);
+ void glTextureStorage3DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void glTextureStorage2DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void glTextureStorage1DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_direct_state_access)
+};
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix4x3dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix4x3dvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix4x2dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix4x2dvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix3x4dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix3x4dvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix3x2dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix3x2dvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix2x4dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix2x4dvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix2x3dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix2x3dvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix4dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix4dvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix3dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix3dvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix2dvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix2dvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform4dvEXT(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform4dvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform3dvEXT(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform3dvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform2dvEXT(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform2dvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform1dvEXT(GLuint program, GLint location, GLsizei count, const GLdouble *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform1dvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform4dEXT(GLuint program, GLint location, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform4dEXT(program, location, x, y, z, w);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform3dEXT(GLuint program, GLint location, GLdouble x, GLdouble y, GLdouble z)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform3dEXT(program, location, x, y, z);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform2dEXT(GLuint program, GLint location, GLdouble x, GLdouble y)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform2dEXT(program, location, x, y);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform1dEXT(GLuint program, GLint location, GLdouble x)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform1dEXT(program, location, x);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexRenderbufferEXT(GLenum texunit, GLenum target, GLuint renderbuffer)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexRenderbufferEXT(texunit, target, renderbuffer);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureRenderbufferEXT(GLuint texture, GLenum target, GLuint renderbuffer)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureRenderbufferEXT(texture, target, renderbuffer);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedFramebufferTextureFaceEXT(GLuint framebuffer, GLenum attachment, GLuint texture, GLint level, GLenum face)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedFramebufferTextureFaceEXT(framebuffer, attachment, texture, level, face);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedFramebufferTextureLayerEXT(GLuint framebuffer, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedFramebufferTextureLayerEXT(framebuffer, attachment, texture, level, layer);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedFramebufferTextureEXT(GLuint framebuffer, GLenum attachment, GLuint texture, GLint level)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedFramebufferTextureEXT(framebuffer, attachment, texture, level);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedRenderbufferStorageMultisampleCoverageEXT(GLuint renderbuffer, GLsizei coverageSamples, GLsizei colorSamples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedRenderbufferStorageMultisampleCoverageEXT(renderbuffer, coverageSamples, colorSamples, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedRenderbufferStorageMultisampleEXT(GLuint renderbuffer, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedRenderbufferStorageMultisampleEXT(renderbuffer, samples, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetFramebufferParameterivEXT(GLuint framebuffer, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetFramebufferParameterivEXT(framebuffer, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glFramebufferReadBufferEXT(GLuint framebuffer, GLenum mode)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->FramebufferReadBufferEXT(framebuffer, mode);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glFramebufferDrawBuffersEXT(GLuint framebuffer, GLsizei n, const GLenum *bufs)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->FramebufferDrawBuffersEXT(framebuffer, n, bufs);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glFramebufferDrawBufferEXT(GLuint framebuffer, GLenum mode)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->FramebufferDrawBufferEXT(framebuffer, mode);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGenerateMultiTexMipmapEXT(GLenum texunit, GLenum target)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GenerateMultiTexMipmapEXT(texunit, target);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGenerateTextureMipmapEXT(GLuint texture, GLenum target)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GenerateTextureMipmapEXT(texture, target);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetNamedFramebufferAttachmentParameterivEXT(GLuint framebuffer, GLenum attachment, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetNamedFramebufferAttachmentParameterivEXT(framebuffer, attachment, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedFramebufferRenderbufferEXT(GLuint framebuffer, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedFramebufferRenderbufferEXT(framebuffer, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedFramebufferTexture3DEXT(GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedFramebufferTexture3DEXT(framebuffer, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedFramebufferTexture2DEXT(GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedFramebufferTexture2DEXT(framebuffer, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedFramebufferTexture1DEXT(GLuint framebuffer, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedFramebufferTexture1DEXT(framebuffer, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLExtension_EXT_direct_state_access::glCheckNamedFramebufferStatusEXT(GLuint framebuffer, GLenum target)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ return d->CheckNamedFramebufferStatusEXT(framebuffer, target);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetNamedRenderbufferParameterivEXT(GLuint renderbuffer, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetNamedRenderbufferParameterivEXT(renderbuffer, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedRenderbufferStorageEXT(GLuint renderbuffer, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedRenderbufferStorageEXT(renderbuffer, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexBufferEXT(GLenum texunit, GLenum target, GLenum internalformat, GLuint buffer)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexBufferEXT(texunit, target, internalformat, buffer);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureBufferEXT(GLuint texture, GLenum target, GLenum internalformat, GLuint buffer)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureBufferEXT(texture, target, internalformat, buffer);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetNamedBufferSubDataEXT(GLuint buffer, GLintptr offset, GLsizeiptr size, GLvoid *data)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetNamedBufferSubDataEXT(buffer, offset, size, data);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetNamedBufferPointervEXT(GLuint buffer, GLenum pname, GLvoid* *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetNamedBufferPointervEXT(buffer, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetNamedBufferParameterivEXT(GLuint buffer, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetNamedBufferParameterivEXT(buffer, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedCopyBufferSubDataEXT(GLuint readBuffer, GLuint writeBuffer, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedCopyBufferSubDataEXT(readBuffer, writeBuffer, readOffset, writeOffset, size);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glFlushMappedNamedBufferRangeEXT(GLuint buffer, GLintptr offset, GLsizeiptr length)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->FlushMappedNamedBufferRangeEXT(buffer, offset, length);
+}
+
+inline GLvoid* QOpenGLExtension_EXT_direct_state_access::glMapNamedBufferRangeEXT(GLuint buffer, GLintptr offset, GLsizeiptr length, GLbitfield access)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ return d->MapNamedBufferRangeEXT(buffer, offset, length, access);
+}
+
+inline GLboolean QOpenGLExtension_EXT_direct_state_access::glUnmapNamedBufferEXT(GLuint buffer)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ return d->UnmapNamedBufferEXT(buffer);
+}
+
+inline GLvoid* QOpenGLExtension_EXT_direct_state_access::glMapNamedBufferEXT(GLuint buffer, GLenum access)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ return d->MapNamedBufferEXT(buffer, access);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedBufferSubDataEXT(GLuint buffer, GLintptr offset, GLsizeiptr size, const GLvoid *data)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedBufferSubDataEXT(buffer, offset, size, data);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedBufferDataEXT(GLuint buffer, GLsizeiptr size, const GLvoid *data, GLenum usage)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedBufferDataEXT(buffer, size, data, usage);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform4uivEXT(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform4uivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform3uivEXT(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform3uivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform2uivEXT(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform2uivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform1uivEXT(GLuint program, GLint location, GLsizei count, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform1uivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform4uiEXT(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform4uiEXT(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform3uiEXT(GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform3uiEXT(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform2uiEXT(GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform2uiEXT(program, location, v0, v1);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform1uiEXT(GLuint program, GLint location, GLuint v0)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform1uiEXT(program, location, v0);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix4x3fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix4x3fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix3x4fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix3x4fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix4x2fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix4x2fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix2x4fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix2x4fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix3x2fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix3x2fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix2x3fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix2x3fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix4fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix4fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix3fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix3fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniformMatrix2fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniformMatrix2fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform4ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform4ivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform3ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform3ivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform2ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform2ivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform1ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform1ivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform4fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform4fvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform3fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform3fvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform2fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform2fvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform1fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform1fvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform4iEXT(GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform4iEXT(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform3iEXT(GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform3iEXT(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform2iEXT(GLuint program, GLint location, GLint v0, GLint v1)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform2iEXT(program, location, v0, v1);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform1iEXT(GLuint program, GLint location, GLint v0)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform1iEXT(program, location, v0);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform4fEXT(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform4fEXT(program, location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform3fEXT(GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform3fEXT(program, location, v0, v1, v2);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform2fEXT(GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform2fEXT(program, location, v0, v1);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glProgramUniform1fEXT(GLuint program, GLint location, GLfloat v0)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ProgramUniform1fEXT(program, location, v0);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetMultiTexParameterIuivEXT(GLenum texunit, GLenum target, GLenum pname, GLuint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetMultiTexParameterIuivEXT(texunit, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetMultiTexParameterIivEXT(GLenum texunit, GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetMultiTexParameterIivEXT(texunit, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexParameterIuivEXT(GLenum texunit, GLenum target, GLenum pname, const GLuint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexParameterIuivEXT(texunit, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexParameterIivEXT(GLenum texunit, GLenum target, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexParameterIivEXT(texunit, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetTextureParameterIuivEXT(GLuint texture, GLenum target, GLenum pname, GLuint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetTextureParameterIuivEXT(texture, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetTextureParameterIivEXT(GLuint texture, GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetTextureParameterIivEXT(texture, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureParameterIuivEXT(GLuint texture, GLenum target, GLenum pname, const GLuint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureParameterIuivEXT(texture, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureParameterIivEXT(GLuint texture, GLenum target, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureParameterIivEXT(texture, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetNamedProgramLocalParameterIuivEXT(GLuint program, GLenum target, GLuint index, GLuint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetNamedProgramLocalParameterIuivEXT(program, target, index, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetNamedProgramLocalParameterIivEXT(GLuint program, GLenum target, GLuint index, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetNamedProgramLocalParameterIivEXT(program, target, index, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedProgramLocalParametersI4uivEXT(GLuint program, GLenum target, GLuint index, GLsizei count, const GLuint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedProgramLocalParametersI4uivEXT(program, target, index, count, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedProgramLocalParameterI4uivEXT(GLuint program, GLenum target, GLuint index, const GLuint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedProgramLocalParameterI4uivEXT(program, target, index, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedProgramLocalParameterI4uiEXT(GLuint program, GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedProgramLocalParameterI4uiEXT(program, target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedProgramLocalParametersI4ivEXT(GLuint program, GLenum target, GLuint index, GLsizei count, const GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedProgramLocalParametersI4ivEXT(program, target, index, count, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedProgramLocalParameterI4ivEXT(GLuint program, GLenum target, GLuint index, const GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedProgramLocalParameterI4ivEXT(program, target, index, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedProgramLocalParameterI4iEXT(GLuint program, GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedProgramLocalParameterI4iEXT(program, target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedProgramLocalParameters4fvEXT(GLuint program, GLenum target, GLuint index, GLsizei count, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedProgramLocalParameters4fvEXT(program, target, index, count, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetNamedProgramStringEXT(GLuint program, GLenum target, GLenum pname, GLvoid *string)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetNamedProgramStringEXT(program, target, pname, string);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetNamedProgramivEXT(GLuint program, GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetNamedProgramivEXT(program, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetNamedProgramLocalParameterfvEXT(GLuint program, GLenum target, GLuint index, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetNamedProgramLocalParameterfvEXT(program, target, index, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetNamedProgramLocalParameterdvEXT(GLuint program, GLenum target, GLuint index, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetNamedProgramLocalParameterdvEXT(program, target, index, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedProgramLocalParameter4fvEXT(GLuint program, GLenum target, GLuint index, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedProgramLocalParameter4fvEXT(program, target, index, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedProgramLocalParameter4fEXT(GLuint program, GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedProgramLocalParameter4fEXT(program, target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedProgramLocalParameter4dvEXT(GLuint program, GLenum target, GLuint index, const GLdouble *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedProgramLocalParameter4dvEXT(program, target, index, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedProgramLocalParameter4dEXT(GLuint program, GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedProgramLocalParameter4dEXT(program, target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedProgramStringEXT(GLuint program, GLenum target, GLenum format, GLsizei len, const GLvoid *string)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedProgramStringEXT(program, target, format, len, string);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetCompressedMultiTexImageEXT(GLenum texunit, GLenum target, GLint lod, GLvoid *img)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetCompressedMultiTexImageEXT(texunit, target, lod, img);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCompressedMultiTexSubImage1DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *bits)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CompressedMultiTexSubImage1DEXT(texunit, target, level, xoffset, width, format, imageSize, bits);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCompressedMultiTexSubImage2DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *bits)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CompressedMultiTexSubImage2DEXT(texunit, target, level, xoffset, yoffset, width, height, format, imageSize, bits);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCompressedMultiTexSubImage3DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *bits)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CompressedMultiTexSubImage3DEXT(texunit, target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, bits);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCompressedMultiTexImage1DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *bits)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CompressedMultiTexImage1DEXT(texunit, target, level, internalformat, width, border, imageSize, bits);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCompressedMultiTexImage2DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *bits)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CompressedMultiTexImage2DEXT(texunit, target, level, internalformat, width, height, border, imageSize, bits);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCompressedMultiTexImage3DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *bits)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CompressedMultiTexImage3DEXT(texunit, target, level, internalformat, width, height, depth, border, imageSize, bits);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetCompressedTextureImageEXT(GLuint texture, GLenum target, GLint lod, GLvoid *img)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetCompressedTextureImageEXT(texture, target, lod, img);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCompressedTextureSubImage1DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *bits)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CompressedTextureSubImage1DEXT(texture, target, level, xoffset, width, format, imageSize, bits);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCompressedTextureSubImage2DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *bits)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CompressedTextureSubImage2DEXT(texture, target, level, xoffset, yoffset, width, height, format, imageSize, bits);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCompressedTextureSubImage3DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *bits)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CompressedTextureSubImage3DEXT(texture, target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, bits);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCompressedTextureImage1DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *bits)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CompressedTextureImage1DEXT(texture, target, level, internalformat, width, border, imageSize, bits);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCompressedTextureImage2DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *bits)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CompressedTextureImage2DEXT(texture, target, level, internalformat, width, height, border, imageSize, bits);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCompressedTextureImage3DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *bits)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CompressedTextureImage3DEXT(texture, target, level, internalformat, width, height, depth, border, imageSize, bits);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetPointerIndexedvEXT(GLenum target, GLuint index, GLvoid* *data)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetPointerIndexedvEXT(target, index, data);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetDoubleIndexedvEXT(GLenum target, GLuint index, GLdouble *data)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetDoubleIndexedvEXT(target, index, data);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetFloatIndexedvEXT(GLenum target, GLuint index, GLfloat *data)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetFloatIndexedvEXT(target, index, data);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetMultiTexGenivEXT(GLenum texunit, GLenum coord, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetMultiTexGenivEXT(texunit, coord, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetMultiTexGenfvEXT(GLenum texunit, GLenum coord, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetMultiTexGenfvEXT(texunit, coord, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetMultiTexGendvEXT(GLenum texunit, GLenum coord, GLenum pname, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetMultiTexGendvEXT(texunit, coord, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetMultiTexEnvivEXT(GLenum texunit, GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetMultiTexEnvivEXT(texunit, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetMultiTexEnvfvEXT(GLenum texunit, GLenum target, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetMultiTexEnvfvEXT(texunit, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexGenivEXT(GLenum texunit, GLenum coord, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexGenivEXT(texunit, coord, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexGeniEXT(GLenum texunit, GLenum coord, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexGeniEXT(texunit, coord, pname, param);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexGenfvEXT(GLenum texunit, GLenum coord, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexGenfvEXT(texunit, coord, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexGenfEXT(GLenum texunit, GLenum coord, GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexGenfEXT(texunit, coord, pname, param);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexGendvEXT(GLenum texunit, GLenum coord, GLenum pname, const GLdouble *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexGendvEXT(texunit, coord, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexGendEXT(GLenum texunit, GLenum coord, GLenum pname, GLdouble param)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexGendEXT(texunit, coord, pname, param);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexEnvivEXT(GLenum texunit, GLenum target, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexEnvivEXT(texunit, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexEnviEXT(GLenum texunit, GLenum target, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexEnviEXT(texunit, target, pname, param);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexEnvfvEXT(GLenum texunit, GLenum target, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexEnvfvEXT(texunit, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexEnvfEXT(GLenum texunit, GLenum target, GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexEnvfEXT(texunit, target, pname, param);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexCoordPointerEXT(GLenum texunit, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexCoordPointerEXT(texunit, size, type, stride, pointer);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glDisableClientStateIndexedEXT(GLenum array, GLuint index)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->DisableClientStateIndexedEXT(array, index);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glEnableClientStateIndexedEXT(GLenum array, GLuint index)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->EnableClientStateIndexedEXT(array, index);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glBindMultiTextureEXT(GLenum texunit, GLenum target, GLuint texture)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->BindMultiTextureEXT(texunit, target, texture);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCopyMultiTexSubImage3DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CopyMultiTexSubImage3DEXT(texunit, target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexSubImage3DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexSubImage3DEXT(texunit, target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexImage3DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexImage3DEXT(texunit, target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetMultiTexLevelParameterivEXT(GLenum texunit, GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetMultiTexLevelParameterivEXT(texunit, target, level, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetMultiTexLevelParameterfvEXT(GLenum texunit, GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetMultiTexLevelParameterfvEXT(texunit, target, level, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetMultiTexParameterivEXT(GLenum texunit, GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetMultiTexParameterivEXT(texunit, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetMultiTexParameterfvEXT(GLenum texunit, GLenum target, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetMultiTexParameterfvEXT(texunit, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetMultiTexImageEXT(GLenum texunit, GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetMultiTexImageEXT(texunit, target, level, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCopyMultiTexSubImage2DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CopyMultiTexSubImage2DEXT(texunit, target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCopyMultiTexSubImage1DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CopyMultiTexSubImage1DEXT(texunit, target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCopyMultiTexImage2DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CopyMultiTexImage2DEXT(texunit, target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCopyMultiTexImage1DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CopyMultiTexImage1DEXT(texunit, target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexSubImage2DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexSubImage2DEXT(texunit, target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexSubImage1DEXT(GLenum texunit, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexSubImage1DEXT(texunit, target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexImage2DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexImage2DEXT(texunit, target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexImage1DEXT(GLenum texunit, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexImage1DEXT(texunit, target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexParameterivEXT(GLenum texunit, GLenum target, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexParameterivEXT(texunit, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexParameteriEXT(GLenum texunit, GLenum target, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexParameteriEXT(texunit, target, pname, param);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexParameterfvEXT(GLenum texunit, GLenum target, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexParameterfvEXT(texunit, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMultiTexParameterfEXT(GLenum texunit, GLenum target, GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MultiTexParameterfEXT(texunit, target, pname, param);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCopyTextureSubImage3DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CopyTextureSubImage3DEXT(texture, target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureSubImage3DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureSubImage3DEXT(texture, target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureImage3DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureImage3DEXT(texture, target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetTextureLevelParameterivEXT(GLuint texture, GLenum target, GLint level, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetTextureLevelParameterivEXT(texture, target, level, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetTextureLevelParameterfvEXT(GLuint texture, GLenum target, GLint level, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetTextureLevelParameterfvEXT(texture, target, level, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetTextureParameterivEXT(GLuint texture, GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetTextureParameterivEXT(texture, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetTextureParameterfvEXT(GLuint texture, GLenum target, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetTextureParameterfvEXT(texture, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetTextureImageEXT(GLuint texture, GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetTextureImageEXT(texture, target, level, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCopyTextureSubImage2DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CopyTextureSubImage2DEXT(texture, target, level, xoffset, yoffset, x, y, width, height);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCopyTextureSubImage1DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CopyTextureSubImage1DEXT(texture, target, level, xoffset, x, y, width);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCopyTextureImage2DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CopyTextureImage2DEXT(texture, target, level, internalformat, x, y, width, height, border);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glCopyTextureImage1DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->CopyTextureImage1DEXT(texture, target, level, internalformat, x, y, width, border);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureSubImage2DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureSubImage2DEXT(texture, target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureSubImage1DEXT(GLuint texture, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureSubImage1DEXT(texture, target, level, xoffset, width, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureImage2DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureImage2DEXT(texture, target, level, internalformat, width, height, border, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureImage1DEXT(GLuint texture, GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureImage1DEXT(texture, target, level, internalformat, width, border, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureParameterivEXT(GLuint texture, GLenum target, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureParameterivEXT(texture, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureParameteriEXT(GLuint texture, GLenum target, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureParameteriEXT(texture, target, pname, param);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureParameterfvEXT(GLuint texture, GLenum target, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureParameterfvEXT(texture, target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureParameterfEXT(GLuint texture, GLenum target, GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureParameterfEXT(texture, target, pname, param);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixMultTransposedEXT(GLenum mode, const GLdouble *m)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixMultTransposedEXT(mode, m);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixMultTransposefEXT(GLenum mode, const GLfloat *m)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixMultTransposefEXT(mode, m);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixLoadTransposedEXT(GLenum mode, const GLdouble *m)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixLoadTransposedEXT(mode, m);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixLoadTransposefEXT(GLenum mode, const GLfloat *m)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixLoadTransposefEXT(mode, m);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixPushEXT(GLenum mode)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixPushEXT(mode);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixPopEXT(GLenum mode)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixPopEXT(mode);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixOrthoEXT(GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixOrthoEXT(mode, left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixFrustumEXT(GLenum mode, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixFrustumEXT(mode, left, right, bottom, top, zNear, zFar);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixTranslatedEXT(GLenum mode, GLdouble x, GLdouble y, GLdouble z)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixTranslatedEXT(mode, x, y, z);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixTranslatefEXT(GLenum mode, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixTranslatefEXT(mode, x, y, z);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixScaledEXT(GLenum mode, GLdouble x, GLdouble y, GLdouble z)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixScaledEXT(mode, x, y, z);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixScalefEXT(GLenum mode, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixScalefEXT(mode, x, y, z);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixRotatedEXT(GLenum mode, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixRotatedEXT(mode, angle, x, y, z);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixRotatefEXT(GLenum mode, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixRotatefEXT(mode, angle, x, y, z);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixLoadIdentityEXT(GLenum mode)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixLoadIdentityEXT(mode);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixMultdEXT(GLenum mode, const GLdouble *m)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixMultdEXT(mode, m);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixMultfEXT(GLenum mode, const GLfloat *m)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixMultfEXT(mode, m);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixLoaddEXT(GLenum mode, const GLdouble *m)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixLoaddEXT(mode, m);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glMatrixLoadfEXT(GLenum mode, const GLfloat *m)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->MatrixLoadfEXT(mode, m);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glPushClientAttribDefaultEXT(GLbitfield mask)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->PushClientAttribDefaultEXT(mask);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glClientAttribDefaultEXT(GLbitfield mask)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ClientAttribDefaultEXT(mask);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureStorage3DMultisampleEXT(GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureStorage3DMultisampleEXT(texture, target, samples, internalformat, width, height, depth, fixedsamplelocations);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureStorage2DMultisampleEXT(GLuint texture, GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureStorage2DMultisampleEXT(texture, target, samples, internalformat, width, height, fixedsamplelocations);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureBufferRangeEXT(GLuint texture, GLenum target, GLenum internalformat, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureBufferRangeEXT(texture, target, internalformat, buffer, offset, size);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glGetNamedFramebufferParameterivEXT(GLuint framebuffer, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->GetNamedFramebufferParameterivEXT(framebuffer, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glNamedFramebufferParameteriEXT(GLuint framebuffer, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->NamedFramebufferParameteriEXT(framebuffer, pname, param);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glVertexArrayVertexBindingDivisorEXT(GLuint vaobj, GLuint bindingindex, GLuint divisor)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->VertexArrayVertexBindingDivisorEXT(vaobj, bindingindex, divisor);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glVertexArrayVertexAttribBindingEXT(GLuint vaobj, GLuint attribindex, GLuint bindingindex)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->VertexArrayVertexAttribBindingEXT(vaobj, attribindex, bindingindex);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glVertexArrayVertexAttribLFormatEXT(GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->VertexArrayVertexAttribLFormatEXT(vaobj, attribindex, size, type, relativeoffset);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glVertexArrayVertexAttribIFormatEXT(GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLuint relativeoffset)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->VertexArrayVertexAttribIFormatEXT(vaobj, attribindex, size, type, relativeoffset);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glVertexArrayVertexAttribFormatEXT(GLuint vaobj, GLuint attribindex, GLint size, GLenum type, GLboolean normalized, GLuint relativeoffset)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->VertexArrayVertexAttribFormatEXT(vaobj, attribindex, size, type, normalized, relativeoffset);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glVertexArrayBindVertexBufferEXT(GLuint vaobj, GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->VertexArrayBindVertexBufferEXT(vaobj, bindingindex, buffer, offset, stride);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glClearNamedBufferSubDataEXT(GLuint buffer, GLenum internalformat, GLsizeiptr offset, GLsizeiptr size, GLenum format, GLenum type, const void *data)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ClearNamedBufferSubDataEXT(buffer, internalformat, offset, size, format, type, data);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glClearNamedBufferDataEXT(GLuint buffer, GLenum internalformat, GLenum format, GLenum type, const void *data)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->ClearNamedBufferDataEXT(buffer, internalformat, format, type, data);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureStorage3DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureStorage3DEXT(texture, target, levels, internalformat, width, height, depth);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureStorage2DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureStorage2DEXT(texture, target, levels, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_EXT_direct_state_access::glTextureStorage1DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width)
+{
+ Q_D(QOpenGLExtension_EXT_direct_state_access);
+ d->TextureStorage1DEXT(texture, target, levels, internalformat, width);
+}
+
+class QOpenGLExtension_EXT_draw_buffers2Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLboolean (QOPENGLF_APIENTRYP IsEnabledIndexedEXT)(GLenum target, GLuint index);
+ void (QOPENGLF_APIENTRYP DisableIndexedEXT)(GLenum target, GLuint index);
+ void (QOPENGLF_APIENTRYP EnableIndexedEXT)(GLenum target, GLuint index);
+ void (QOPENGLF_APIENTRYP GetIntegerIndexedvEXT)(GLenum target, GLuint index, GLint *data);
+ void (QOPENGLF_APIENTRYP GetBooleanIndexedvEXT)(GLenum target, GLuint index, GLboolean *data);
+ void (QOPENGLF_APIENTRYP ColorMaskIndexedEXT)(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+};
+
+class QOpenGLExtension_EXT_draw_buffers2 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_draw_buffers2();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLboolean glIsEnabledIndexedEXT(GLenum target, GLuint index);
+ void glDisableIndexedEXT(GLenum target, GLuint index);
+ void glEnableIndexedEXT(GLenum target, GLuint index);
+ void glGetIntegerIndexedvEXT(GLenum target, GLuint index, GLint *data);
+ void glGetBooleanIndexedvEXT(GLenum target, GLuint index, GLboolean *data);
+ void glColorMaskIndexedEXT(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_draw_buffers2)
+};
+
+inline GLboolean QOpenGLExtension_EXT_draw_buffers2::glIsEnabledIndexedEXT(GLenum target, GLuint index)
+{
+ Q_D(QOpenGLExtension_EXT_draw_buffers2);
+ return d->IsEnabledIndexedEXT(target, index);
+}
+
+inline void QOpenGLExtension_EXT_draw_buffers2::glDisableIndexedEXT(GLenum target, GLuint index)
+{
+ Q_D(QOpenGLExtension_EXT_draw_buffers2);
+ d->DisableIndexedEXT(target, index);
+}
+
+inline void QOpenGLExtension_EXT_draw_buffers2::glEnableIndexedEXT(GLenum target, GLuint index)
+{
+ Q_D(QOpenGLExtension_EXT_draw_buffers2);
+ d->EnableIndexedEXT(target, index);
+}
+
+inline void QOpenGLExtension_EXT_draw_buffers2::glGetIntegerIndexedvEXT(GLenum target, GLuint index, GLint *data)
+{
+ Q_D(QOpenGLExtension_EXT_draw_buffers2);
+ d->GetIntegerIndexedvEXT(target, index, data);
+}
+
+inline void QOpenGLExtension_EXT_draw_buffers2::glGetBooleanIndexedvEXT(GLenum target, GLuint index, GLboolean *data)
+{
+ Q_D(QOpenGLExtension_EXT_draw_buffers2);
+ d->GetBooleanIndexedvEXT(target, index, data);
+}
+
+inline void QOpenGLExtension_EXT_draw_buffers2::glColorMaskIndexedEXT(GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ Q_D(QOpenGLExtension_EXT_draw_buffers2);
+ d->ColorMaskIndexedEXT(index, r, g, b, a);
+}
+
+class QOpenGLExtension_EXT_draw_instancedPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawElementsInstancedEXT)(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount);
+ void (QOPENGLF_APIENTRYP DrawArraysInstancedEXT)(GLenum mode, GLint start, GLsizei count, GLsizei primcount);
+};
+
+class QOpenGLExtension_EXT_draw_instanced : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_draw_instanced();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawElementsInstancedEXT(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount);
+ void glDrawArraysInstancedEXT(GLenum mode, GLint start, GLsizei count, GLsizei primcount);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_draw_instanced)
+};
+
+inline void QOpenGLExtension_EXT_draw_instanced::glDrawElementsInstancedEXT(GLenum mode, GLsizei count, GLenum type, const GLvoid *indices, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_EXT_draw_instanced);
+ d->DrawElementsInstancedEXT(mode, count, type, indices, primcount);
+}
+
+inline void QOpenGLExtension_EXT_draw_instanced::glDrawArraysInstancedEXT(GLenum mode, GLint start, GLsizei count, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_EXT_draw_instanced);
+ d->DrawArraysInstancedEXT(mode, start, count, primcount);
+}
+
+class QOpenGLExtension_EXT_draw_range_elementsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawRangeElementsEXT)(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+};
+
+class QOpenGLExtension_EXT_draw_range_elements : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_draw_range_elements();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawRangeElementsEXT(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_draw_range_elements)
+};
+
+inline void QOpenGLExtension_EXT_draw_range_elements::glDrawRangeElementsEXT(GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices)
+{
+ Q_D(QOpenGLExtension_EXT_draw_range_elements);
+ d->DrawRangeElementsEXT(mode, start, end, count, type, indices);
+}
+
+class QOpenGLExtension_EXT_fog_coordPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP FogCoordPointerEXT)(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP FogCoorddvEXT)(const GLdouble *coord);
+ void (QOPENGLF_APIENTRYP FogCoorddEXT)(GLdouble coord);
+ void (QOPENGLF_APIENTRYP FogCoordfvEXT)(const GLfloat *coord);
+ void (QOPENGLF_APIENTRYP FogCoordfEXT)(GLfloat coord);
+};
+
+class QOpenGLExtension_EXT_fog_coord : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_fog_coord();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glFogCoordPointerEXT(GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glFogCoorddvEXT(const GLdouble *coord);
+ void glFogCoorddEXT(GLdouble coord);
+ void glFogCoordfvEXT(const GLfloat *coord);
+ void glFogCoordfEXT(GLfloat coord);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_fog_coord)
+};
+
+inline void QOpenGLExtension_EXT_fog_coord::glFogCoordPointerEXT(GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_fog_coord);
+ d->FogCoordPointerEXT(type, stride, pointer);
+}
+
+inline void QOpenGLExtension_EXT_fog_coord::glFogCoorddvEXT(const GLdouble *coord)
+{
+ Q_D(QOpenGLExtension_EXT_fog_coord);
+ d->FogCoorddvEXT(coord);
+}
+
+inline void QOpenGLExtension_EXT_fog_coord::glFogCoorddEXT(GLdouble coord)
+{
+ Q_D(QOpenGLExtension_EXT_fog_coord);
+ d->FogCoorddEXT(coord);
+}
+
+inline void QOpenGLExtension_EXT_fog_coord::glFogCoordfvEXT(const GLfloat *coord)
+{
+ Q_D(QOpenGLExtension_EXT_fog_coord);
+ d->FogCoordfvEXT(coord);
+}
+
+inline void QOpenGLExtension_EXT_fog_coord::glFogCoordfEXT(GLfloat coord)
+{
+ Q_D(QOpenGLExtension_EXT_fog_coord);
+ d->FogCoordfEXT(coord);
+}
+
+class QOpenGLExtension_EXT_framebuffer_blitPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BlitFramebufferEXT)(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+};
+
+class QOpenGLExtension_EXT_framebuffer_blit : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_framebuffer_blit();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBlitFramebufferEXT(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_framebuffer_blit)
+};
+
+inline void QOpenGLExtension_EXT_framebuffer_blit::glBlitFramebufferEXT(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_blit);
+ d->BlitFramebufferEXT(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+class QOpenGLExtension_EXT_framebuffer_multisamplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP RenderbufferStorageMultisampleEXT)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+};
+
+class QOpenGLExtension_EXT_framebuffer_multisample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_framebuffer_multisample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glRenderbufferStorageMultisampleEXT(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_framebuffer_multisample)
+};
+
+inline void QOpenGLExtension_EXT_framebuffer_multisample::glRenderbufferStorageMultisampleEXT(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_multisample);
+ d->RenderbufferStorageMultisampleEXT(target, samples, internalformat, width, height);
+}
+
+class QOpenGLExtension_EXT_framebuffer_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GenerateMipmapEXT)(GLenum target);
+ void (QOPENGLF_APIENTRYP GetFramebufferAttachmentParameterivEXT)(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP FramebufferRenderbufferEXT)(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void (QOPENGLF_APIENTRYP FramebufferTexture3DEXT)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void (QOPENGLF_APIENTRYP FramebufferTexture2DEXT)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void (QOPENGLF_APIENTRYP FramebufferTexture1DEXT)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum (QOPENGLF_APIENTRYP CheckFramebufferStatusEXT)(GLenum target);
+ void (QOPENGLF_APIENTRYP GenFramebuffersEXT)(GLsizei n, GLuint *framebuffers);
+ void (QOPENGLF_APIENTRYP DeleteFramebuffersEXT)(GLsizei n, const GLuint *framebuffers);
+ void (QOPENGLF_APIENTRYP BindFramebufferEXT)(GLenum target, GLuint framebuffer);
+ GLboolean (QOPENGLF_APIENTRYP IsFramebufferEXT)(GLuint framebuffer);
+ void (QOPENGLF_APIENTRYP GetRenderbufferParameterivEXT)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP RenderbufferStorageEXT)(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP GenRenderbuffersEXT)(GLsizei n, GLuint *renderbuffers);
+ void (QOPENGLF_APIENTRYP DeleteRenderbuffersEXT)(GLsizei n, const GLuint *renderbuffers);
+ void (QOPENGLF_APIENTRYP BindRenderbufferEXT)(GLenum target, GLuint renderbuffer);
+ GLboolean (QOPENGLF_APIENTRYP IsRenderbufferEXT)(GLuint renderbuffer);
+};
+
+class QOpenGLExtension_EXT_framebuffer_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_framebuffer_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGenerateMipmapEXT(GLenum target);
+ void glGetFramebufferAttachmentParameterivEXT(GLenum target, GLenum attachment, GLenum pname, GLint *params);
+ void glFramebufferRenderbufferEXT(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+ void glFramebufferTexture3DEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+ void glFramebufferTexture2DEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ void glFramebufferTexture1DEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+ GLenum glCheckFramebufferStatusEXT(GLenum target);
+ void glGenFramebuffersEXT(GLsizei n, GLuint *framebuffers);
+ void glDeleteFramebuffersEXT(GLsizei n, const GLuint *framebuffers);
+ void glBindFramebufferEXT(GLenum target, GLuint framebuffer);
+ GLboolean glIsFramebufferEXT(GLuint framebuffer);
+ void glGetRenderbufferParameterivEXT(GLenum target, GLenum pname, GLint *params);
+ void glRenderbufferStorageEXT(GLenum target, GLenum internalformat, GLsizei width, GLsizei height);
+ void glGenRenderbuffersEXT(GLsizei n, GLuint *renderbuffers);
+ void glDeleteRenderbuffersEXT(GLsizei n, const GLuint *renderbuffers);
+ void glBindRenderbufferEXT(GLenum target, GLuint renderbuffer);
+ GLboolean glIsRenderbufferEXT(GLuint renderbuffer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_framebuffer_object)
+};
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glGenerateMipmapEXT(GLenum target)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->GenerateMipmapEXT(target);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glGetFramebufferAttachmentParameterivEXT(GLenum target, GLenum attachment, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->GetFramebufferAttachmentParameterivEXT(target, attachment, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glFramebufferRenderbufferEXT(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->FramebufferRenderbufferEXT(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glFramebufferTexture3DEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->FramebufferTexture3DEXT(target, attachment, textarget, texture, level, zoffset);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glFramebufferTexture2DEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->FramebufferTexture2DEXT(target, attachment, textarget, texture, level);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glFramebufferTexture1DEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->FramebufferTexture1DEXT(target, attachment, textarget, texture, level);
+}
+
+inline GLenum QOpenGLExtension_EXT_framebuffer_object::glCheckFramebufferStatusEXT(GLenum target)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ return d->CheckFramebufferStatusEXT(target);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glGenFramebuffersEXT(GLsizei n, GLuint *framebuffers)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->GenFramebuffersEXT(n, framebuffers);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glDeleteFramebuffersEXT(GLsizei n, const GLuint *framebuffers)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->DeleteFramebuffersEXT(n, framebuffers);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glBindFramebufferEXT(GLenum target, GLuint framebuffer)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->BindFramebufferEXT(target, framebuffer);
+}
+
+inline GLboolean QOpenGLExtension_EXT_framebuffer_object::glIsFramebufferEXT(GLuint framebuffer)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ return d->IsFramebufferEXT(framebuffer);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glGetRenderbufferParameterivEXT(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->GetRenderbufferParameterivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glRenderbufferStorageEXT(GLenum target, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->RenderbufferStorageEXT(target, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glGenRenderbuffersEXT(GLsizei n, GLuint *renderbuffers)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->GenRenderbuffersEXT(n, renderbuffers);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glDeleteRenderbuffersEXT(GLsizei n, const GLuint *renderbuffers)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->DeleteRenderbuffersEXT(n, renderbuffers);
+}
+
+inline void QOpenGLExtension_EXT_framebuffer_object::glBindRenderbufferEXT(GLenum target, GLuint renderbuffer)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ d->BindRenderbufferEXT(target, renderbuffer);
+}
+
+inline GLboolean QOpenGLExtension_EXT_framebuffer_object::glIsRenderbufferEXT(GLuint renderbuffer)
+{
+ Q_D(QOpenGLExtension_EXT_framebuffer_object);
+ return d->IsRenderbufferEXT(renderbuffer);
+}
+
+class QOpenGLExtension_EXT_geometry_shader4Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ProgramParameteriEXT)(GLuint program, GLenum pname, GLint value);
+};
+
+class QOpenGLExtension_EXT_geometry_shader4 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_geometry_shader4();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glProgramParameteriEXT(GLuint program, GLenum pname, GLint value);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_geometry_shader4)
+};
+
+inline void QOpenGLExtension_EXT_geometry_shader4::glProgramParameteriEXT(GLuint program, GLenum pname, GLint value)
+{
+ Q_D(QOpenGLExtension_EXT_geometry_shader4);
+ d->ProgramParameteriEXT(program, pname, value);
+}
+
+class QOpenGLExtension_EXT_gpu_program_parametersPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ProgramLocalParameters4fvEXT)(GLenum target, GLuint index, GLsizei count, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP ProgramEnvParameters4fvEXT)(GLenum target, GLuint index, GLsizei count, const GLfloat *params);
+};
+
+class QOpenGLExtension_EXT_gpu_program_parameters : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_gpu_program_parameters();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glProgramLocalParameters4fvEXT(GLenum target, GLuint index, GLsizei count, const GLfloat *params);
+ void glProgramEnvParameters4fvEXT(GLenum target, GLuint index, GLsizei count, const GLfloat *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_gpu_program_parameters)
+};
+
+inline void QOpenGLExtension_EXT_gpu_program_parameters::glProgramLocalParameters4fvEXT(GLenum target, GLuint index, GLsizei count, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_program_parameters);
+ d->ProgramLocalParameters4fvEXT(target, index, count, params);
+}
+
+inline void QOpenGLExtension_EXT_gpu_program_parameters::glProgramEnvParameters4fvEXT(GLenum target, GLuint index, GLsizei count, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_program_parameters);
+ d->ProgramEnvParameters4fvEXT(target, index, count, params);
+}
+
+class QOpenGLExtension_EXT_gpu_shader4Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP Uniform4uivEXT)(GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP Uniform3uivEXT)(GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP Uniform2uivEXT)(GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP Uniform1uivEXT)(GLint location, GLsizei count, const GLuint *value);
+ void (QOPENGLF_APIENTRYP Uniform4uiEXT)(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void (QOPENGLF_APIENTRYP Uniform3uiEXT)(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void (QOPENGLF_APIENTRYP Uniform2uiEXT)(GLint location, GLuint v0, GLuint v1);
+ void (QOPENGLF_APIENTRYP Uniform1uiEXT)(GLint location, GLuint v0);
+ GLint (QOPENGLF_APIENTRYP GetFragDataLocationEXT)(GLuint program, const GLchar *name);
+ void (QOPENGLF_APIENTRYP BindFragDataLocationEXT)(GLuint program, GLuint color, const GLchar *name);
+ void (QOPENGLF_APIENTRYP GetUniformuivEXT)(GLuint program, GLint location, GLuint *params);
+};
+
+class QOpenGLExtension_EXT_gpu_shader4 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_gpu_shader4();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glUniform4uivEXT(GLint location, GLsizei count, const GLuint *value);
+ void glUniform3uivEXT(GLint location, GLsizei count, const GLuint *value);
+ void glUniform2uivEXT(GLint location, GLsizei count, const GLuint *value);
+ void glUniform1uivEXT(GLint location, GLsizei count, const GLuint *value);
+ void glUniform4uiEXT(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+ void glUniform3uiEXT(GLint location, GLuint v0, GLuint v1, GLuint v2);
+ void glUniform2uiEXT(GLint location, GLuint v0, GLuint v1);
+ void glUniform1uiEXT(GLint location, GLuint v0);
+ GLint glGetFragDataLocationEXT(GLuint program, const GLchar *name);
+ void glBindFragDataLocationEXT(GLuint program, GLuint color, const GLchar *name);
+ void glGetUniformuivEXT(GLuint program, GLint location, GLuint *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_gpu_shader4)
+};
+
+inline void QOpenGLExtension_EXT_gpu_shader4::glUniform4uivEXT(GLint location, GLsizei count, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_shader4);
+ d->Uniform4uivEXT(location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_gpu_shader4::glUniform3uivEXT(GLint location, GLsizei count, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_shader4);
+ d->Uniform3uivEXT(location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_gpu_shader4::glUniform2uivEXT(GLint location, GLsizei count, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_shader4);
+ d->Uniform2uivEXT(location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_gpu_shader4::glUniform1uivEXT(GLint location, GLsizei count, const GLuint *value)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_shader4);
+ d->Uniform1uivEXT(location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_gpu_shader4::glUniform4uiEXT(GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_shader4);
+ d->Uniform4uiEXT(location, v0, v1, v2, v3);
+}
+
+inline void QOpenGLExtension_EXT_gpu_shader4::glUniform3uiEXT(GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_shader4);
+ d->Uniform3uiEXT(location, v0, v1, v2);
+}
+
+inline void QOpenGLExtension_EXT_gpu_shader4::glUniform2uiEXT(GLint location, GLuint v0, GLuint v1)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_shader4);
+ d->Uniform2uiEXT(location, v0, v1);
+}
+
+inline void QOpenGLExtension_EXT_gpu_shader4::glUniform1uiEXT(GLint location, GLuint v0)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_shader4);
+ d->Uniform1uiEXT(location, v0);
+}
+
+inline GLint QOpenGLExtension_EXT_gpu_shader4::glGetFragDataLocationEXT(GLuint program, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_shader4);
+ return d->GetFragDataLocationEXT(program, name);
+}
+
+inline void QOpenGLExtension_EXT_gpu_shader4::glBindFragDataLocationEXT(GLuint program, GLuint color, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_shader4);
+ d->BindFragDataLocationEXT(program, color, name);
+}
+
+inline void QOpenGLExtension_EXT_gpu_shader4::glGetUniformuivEXT(GLuint program, GLint location, GLuint *params)
+{
+ Q_D(QOpenGLExtension_EXT_gpu_shader4);
+ d->GetUniformuivEXT(program, location, params);
+}
+
+class QOpenGLExtension_EXT_histogramPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ResetMinmaxEXT)(GLenum target);
+ void (QOPENGLF_APIENTRYP ResetHistogramEXT)(GLenum target);
+ void (QOPENGLF_APIENTRYP MinmaxEXT)(GLenum target, GLenum internalformat, GLboolean sink);
+ void (QOPENGLF_APIENTRYP HistogramEXT)(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void (QOPENGLF_APIENTRYP GetMinmaxParameterivEXT)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetMinmaxParameterfvEXT)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetMinmaxEXT)(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void (QOPENGLF_APIENTRYP GetHistogramParameterivEXT)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetHistogramParameterfvEXT)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetHistogramEXT)(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+};
+
+class QOpenGLExtension_EXT_histogram : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_histogram();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glResetMinmaxEXT(GLenum target);
+ void glResetHistogramEXT(GLenum target);
+ void glMinmaxEXT(GLenum target, GLenum internalformat, GLboolean sink);
+ void glHistogramEXT(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
+ void glGetMinmaxParameterivEXT(GLenum target, GLenum pname, GLint *params);
+ void glGetMinmaxParameterfvEXT(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMinmaxEXT(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+ void glGetHistogramParameterivEXT(GLenum target, GLenum pname, GLint *params);
+ void glGetHistogramParameterfvEXT(GLenum target, GLenum pname, GLfloat *params);
+ void glGetHistogramEXT(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_histogram)
+};
+
+inline void QOpenGLExtension_EXT_histogram::glResetMinmaxEXT(GLenum target)
+{
+ Q_D(QOpenGLExtension_EXT_histogram);
+ d->ResetMinmaxEXT(target);
+}
+
+inline void QOpenGLExtension_EXT_histogram::glResetHistogramEXT(GLenum target)
+{
+ Q_D(QOpenGLExtension_EXT_histogram);
+ d->ResetHistogramEXT(target);
+}
+
+inline void QOpenGLExtension_EXT_histogram::glMinmaxEXT(GLenum target, GLenum internalformat, GLboolean sink)
+{
+ Q_D(QOpenGLExtension_EXT_histogram);
+ d->MinmaxEXT(target, internalformat, sink);
+}
+
+inline void QOpenGLExtension_EXT_histogram::glHistogramEXT(GLenum target, GLsizei width, GLenum internalformat, GLboolean sink)
+{
+ Q_D(QOpenGLExtension_EXT_histogram);
+ d->HistogramEXT(target, width, internalformat, sink);
+}
+
+inline void QOpenGLExtension_EXT_histogram::glGetMinmaxParameterivEXT(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_histogram);
+ d->GetMinmaxParameterivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_histogram::glGetMinmaxParameterfvEXT(GLenum target, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_histogram);
+ d->GetMinmaxParameterfvEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_histogram::glGetMinmaxEXT(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ Q_D(QOpenGLExtension_EXT_histogram);
+ d->GetMinmaxEXT(target, reset, format, type, values);
+}
+
+inline void QOpenGLExtension_EXT_histogram::glGetHistogramParameterivEXT(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_histogram);
+ d->GetHistogramParameterivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_histogram::glGetHistogramParameterfvEXT(GLenum target, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_histogram);
+ d->GetHistogramParameterfvEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_histogram::glGetHistogramEXT(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values)
+{
+ Q_D(QOpenGLExtension_EXT_histogram);
+ d->GetHistogramEXT(target, reset, format, type, values);
+}
+
+class QOpenGLExtension_EXT_index_funcPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP IndexFuncEXT)(GLenum func, GLclampf ref);
+};
+
+class QOpenGLExtension_EXT_index_func : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_index_func();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glIndexFuncEXT(GLenum func, GLclampf ref);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_index_func)
+};
+
+inline void QOpenGLExtension_EXT_index_func::glIndexFuncEXT(GLenum func, GLclampf ref)
+{
+ Q_D(QOpenGLExtension_EXT_index_func);
+ d->IndexFuncEXT(func, ref);
+}
+
+class QOpenGLExtension_EXT_index_materialPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP IndexMaterialEXT)(GLenum face, GLenum mode);
+};
+
+class QOpenGLExtension_EXT_index_material : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_index_material();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glIndexMaterialEXT(GLenum face, GLenum mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_index_material)
+};
+
+inline void QOpenGLExtension_EXT_index_material::glIndexMaterialEXT(GLenum face, GLenum mode)
+{
+ Q_D(QOpenGLExtension_EXT_index_material);
+ d->IndexMaterialEXT(face, mode);
+}
+
+class QOpenGLExtension_EXT_light_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TextureMaterialEXT)(GLenum face, GLenum mode);
+ void (QOPENGLF_APIENTRYP TextureLightEXT)(GLenum pname);
+ void (QOPENGLF_APIENTRYP ApplyTextureEXT)(GLenum mode);
+};
+
+class QOpenGLExtension_EXT_light_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_light_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTextureMaterialEXT(GLenum face, GLenum mode);
+ void glTextureLightEXT(GLenum pname);
+ void glApplyTextureEXT(GLenum mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_light_texture)
+};
+
+inline void QOpenGLExtension_EXT_light_texture::glTextureMaterialEXT(GLenum face, GLenum mode)
+{
+ Q_D(QOpenGLExtension_EXT_light_texture);
+ d->TextureMaterialEXT(face, mode);
+}
+
+inline void QOpenGLExtension_EXT_light_texture::glTextureLightEXT(GLenum pname)
+{
+ Q_D(QOpenGLExtension_EXT_light_texture);
+ d->TextureLightEXT(pname);
+}
+
+inline void QOpenGLExtension_EXT_light_texture::glApplyTextureEXT(GLenum mode)
+{
+ Q_D(QOpenGLExtension_EXT_light_texture);
+ d->ApplyTextureEXT(mode);
+}
+
+class QOpenGLExtension_EXT_multi_draw_arraysPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MultiDrawElementsEXT)(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount);
+ void (QOPENGLF_APIENTRYP MultiDrawArraysEXT)(GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount);
+};
+
+class QOpenGLExtension_EXT_multi_draw_arrays : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_multi_draw_arrays();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMultiDrawElementsEXT(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount);
+ void glMultiDrawArraysEXT(GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_multi_draw_arrays)
+};
+
+inline void QOpenGLExtension_EXT_multi_draw_arrays::glMultiDrawElementsEXT(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_EXT_multi_draw_arrays);
+ d->MultiDrawElementsEXT(mode, count, type, indices, primcount);
+}
+
+inline void QOpenGLExtension_EXT_multi_draw_arrays::glMultiDrawArraysEXT(GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_EXT_multi_draw_arrays);
+ d->MultiDrawArraysEXT(mode, first, count, primcount);
+}
+
+class QOpenGLExtension_EXT_multisamplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP SamplePatternEXT)(GLenum pattern);
+ void (QOPENGLF_APIENTRYP SampleMaskEXT)(GLclampf value, GLboolean invert);
+};
+
+class QOpenGLExtension_EXT_multisample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_multisample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glSamplePatternEXT(GLenum pattern);
+ void glSampleMaskEXT(GLclampf value, GLboolean invert);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_multisample)
+};
+
+inline void QOpenGLExtension_EXT_multisample::glSamplePatternEXT(GLenum pattern)
+{
+ Q_D(QOpenGLExtension_EXT_multisample);
+ d->SamplePatternEXT(pattern);
+}
+
+inline void QOpenGLExtension_EXT_multisample::glSampleMaskEXT(GLclampf value, GLboolean invert)
+{
+ Q_D(QOpenGLExtension_EXT_multisample);
+ d->SampleMaskEXT(value, invert);
+}
+
+class QOpenGLExtension_EXT_paletted_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetColorTableParameterfvEXT)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetColorTableParameterivEXT)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetColorTableEXT)(GLenum target, GLenum format, GLenum type, GLvoid *data);
+ void (QOPENGLF_APIENTRYP ColorTableEXT)(GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+};
+
+class QOpenGLExtension_EXT_paletted_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_paletted_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetColorTableParameterfvEXT(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTableParameterivEXT(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableEXT(GLenum target, GLenum format, GLenum type, GLvoid *data);
+ void glColorTableEXT(GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_paletted_texture)
+};
+
+inline void QOpenGLExtension_EXT_paletted_texture::glGetColorTableParameterfvEXT(GLenum target, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_paletted_texture);
+ d->GetColorTableParameterfvEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_paletted_texture::glGetColorTableParameterivEXT(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_paletted_texture);
+ d->GetColorTableParameterivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_paletted_texture::glGetColorTableEXT(GLenum target, GLenum format, GLenum type, GLvoid *data)
+{
+ Q_D(QOpenGLExtension_EXT_paletted_texture);
+ d->GetColorTableEXT(target, format, type, data);
+}
+
+inline void QOpenGLExtension_EXT_paletted_texture::glColorTableEXT(GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ Q_D(QOpenGLExtension_EXT_paletted_texture);
+ d->ColorTableEXT(target, internalFormat, width, format, type, table);
+}
+
+class QOpenGLExtension_EXT_pixel_transformPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetPixelTransformParameterfvEXT)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetPixelTransformParameterivEXT)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP PixelTransformParameterfvEXT)(GLenum target, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP PixelTransformParameterivEXT)(GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP PixelTransformParameterfEXT)(GLenum target, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP PixelTransformParameteriEXT)(GLenum target, GLenum pname, GLint param);
+};
+
+class QOpenGLExtension_EXT_pixel_transform : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_pixel_transform();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetPixelTransformParameterfvEXT(GLenum target, GLenum pname, GLfloat *params);
+ void glGetPixelTransformParameterivEXT(GLenum target, GLenum pname, GLint *params);
+ void glPixelTransformParameterfvEXT(GLenum target, GLenum pname, const GLfloat *params);
+ void glPixelTransformParameterivEXT(GLenum target, GLenum pname, const GLint *params);
+ void glPixelTransformParameterfEXT(GLenum target, GLenum pname, GLfloat param);
+ void glPixelTransformParameteriEXT(GLenum target, GLenum pname, GLint param);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_pixel_transform)
+};
+
+inline void QOpenGLExtension_EXT_pixel_transform::glGetPixelTransformParameterfvEXT(GLenum target, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_pixel_transform);
+ d->GetPixelTransformParameterfvEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_pixel_transform::glGetPixelTransformParameterivEXT(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_pixel_transform);
+ d->GetPixelTransformParameterivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_pixel_transform::glPixelTransformParameterfvEXT(GLenum target, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_pixel_transform);
+ d->PixelTransformParameterfvEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_pixel_transform::glPixelTransformParameterivEXT(GLenum target, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_pixel_transform);
+ d->PixelTransformParameterivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_pixel_transform::glPixelTransformParameterfEXT(GLenum target, GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_EXT_pixel_transform);
+ d->PixelTransformParameterfEXT(target, pname, param);
+}
+
+inline void QOpenGLExtension_EXT_pixel_transform::glPixelTransformParameteriEXT(GLenum target, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_EXT_pixel_transform);
+ d->PixelTransformParameteriEXT(target, pname, param);
+}
+
+class QOpenGLExtension_EXT_point_parametersPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP PointParameterfvEXT)(GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP PointParameterfEXT)(GLenum pname, GLfloat param);
+};
+
+class QOpenGLExtension_EXT_point_parameters : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_point_parameters();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glPointParameterfvEXT(GLenum pname, const GLfloat *params);
+ void glPointParameterfEXT(GLenum pname, GLfloat param);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_point_parameters)
+};
+
+inline void QOpenGLExtension_EXT_point_parameters::glPointParameterfvEXT(GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_EXT_point_parameters);
+ d->PointParameterfvEXT(pname, params);
+}
+
+inline void QOpenGLExtension_EXT_point_parameters::glPointParameterfEXT(GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_EXT_point_parameters);
+ d->PointParameterfEXT(pname, param);
+}
+
+class QOpenGLExtension_EXT_polygon_offsetPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP PolygonOffsetEXT)(GLfloat factor, GLfloat bias);
+};
+
+class QOpenGLExtension_EXT_polygon_offset : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_polygon_offset();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glPolygonOffsetEXT(GLfloat factor, GLfloat bias);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_polygon_offset)
+};
+
+inline void QOpenGLExtension_EXT_polygon_offset::glPolygonOffsetEXT(GLfloat factor, GLfloat bias)
+{
+ Q_D(QOpenGLExtension_EXT_polygon_offset);
+ d->PolygonOffsetEXT(factor, bias);
+}
+
+class QOpenGLExtension_EXT_provoking_vertexPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ProvokingVertexEXT)(GLenum mode);
+};
+
+class QOpenGLExtension_EXT_provoking_vertex : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_provoking_vertex();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glProvokingVertexEXT(GLenum mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_provoking_vertex)
+};
+
+inline void QOpenGLExtension_EXT_provoking_vertex::glProvokingVertexEXT(GLenum mode)
+{
+ Q_D(QOpenGLExtension_EXT_provoking_vertex);
+ d->ProvokingVertexEXT(mode);
+}
+
+class QOpenGLExtension_EXT_secondary_colorPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP SecondaryColorPointerEXT)(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP SecondaryColor3usvEXT)(const GLushort *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3usEXT)(GLushort red, GLushort green, GLushort blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3uivEXT)(const GLuint *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3uiEXT)(GLuint red, GLuint green, GLuint blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3ubvEXT)(const GLubyte *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3ubEXT)(GLubyte red, GLubyte green, GLubyte blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3svEXT)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3sEXT)(GLshort red, GLshort green, GLshort blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3ivEXT)(const GLint *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3iEXT)(GLint red, GLint green, GLint blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3fvEXT)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3fEXT)(GLfloat red, GLfloat green, GLfloat blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3dvEXT)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3dEXT)(GLdouble red, GLdouble green, GLdouble blue);
+ void (QOPENGLF_APIENTRYP SecondaryColor3bvEXT)(const GLbyte *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3bEXT)(GLbyte red, GLbyte green, GLbyte blue);
+};
+
+class QOpenGLExtension_EXT_secondary_color : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_secondary_color();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glSecondaryColorPointerEXT(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glSecondaryColor3usvEXT(const GLushort *v);
+ void glSecondaryColor3usEXT(GLushort red, GLushort green, GLushort blue);
+ void glSecondaryColor3uivEXT(const GLuint *v);
+ void glSecondaryColor3uiEXT(GLuint red, GLuint green, GLuint blue);
+ void glSecondaryColor3ubvEXT(const GLubyte *v);
+ void glSecondaryColor3ubEXT(GLubyte red, GLubyte green, GLubyte blue);
+ void glSecondaryColor3svEXT(const GLshort *v);
+ void glSecondaryColor3sEXT(GLshort red, GLshort green, GLshort blue);
+ void glSecondaryColor3ivEXT(const GLint *v);
+ void glSecondaryColor3iEXT(GLint red, GLint green, GLint blue);
+ void glSecondaryColor3fvEXT(const GLfloat *v);
+ void glSecondaryColor3fEXT(GLfloat red, GLfloat green, GLfloat blue);
+ void glSecondaryColor3dvEXT(const GLdouble *v);
+ void glSecondaryColor3dEXT(GLdouble red, GLdouble green, GLdouble blue);
+ void glSecondaryColor3bvEXT(const GLbyte *v);
+ void glSecondaryColor3bEXT(GLbyte red, GLbyte green, GLbyte blue);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_secondary_color)
+};
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColorPointerEXT(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColorPointerEXT(size, type, stride, pointer);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3usvEXT(const GLushort *v)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3usvEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3usEXT(GLushort red, GLushort green, GLushort blue)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3usEXT(red, green, blue);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3uivEXT(const GLuint *v)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3uivEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3uiEXT(GLuint red, GLuint green, GLuint blue)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3uiEXT(red, green, blue);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3ubvEXT(const GLubyte *v)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3ubvEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3ubEXT(GLubyte red, GLubyte green, GLubyte blue)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3ubEXT(red, green, blue);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3svEXT(const GLshort *v)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3svEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3sEXT(GLshort red, GLshort green, GLshort blue)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3sEXT(red, green, blue);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3ivEXT(const GLint *v)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3ivEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3iEXT(GLint red, GLint green, GLint blue)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3iEXT(red, green, blue);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3fvEXT(const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3fvEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3fEXT(GLfloat red, GLfloat green, GLfloat blue)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3fEXT(red, green, blue);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3dvEXT(const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3dvEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3dEXT(GLdouble red, GLdouble green, GLdouble blue)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3dEXT(red, green, blue);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3bvEXT(const GLbyte *v)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3bvEXT(v);
+}
+
+inline void QOpenGLExtension_EXT_secondary_color::glSecondaryColor3bEXT(GLbyte red, GLbyte green, GLbyte blue)
+{
+ Q_D(QOpenGLExtension_EXT_secondary_color);
+ d->SecondaryColor3bEXT(red, green, blue);
+}
+
+class QOpenGLExtension_EXT_separate_shader_objectsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLuint (QOPENGLF_APIENTRYP CreateShaderProgramEXT)(GLenum type, const GLchar *string);
+ void (QOPENGLF_APIENTRYP ActiveProgramEXT)(GLuint program);
+ void (QOPENGLF_APIENTRYP UseShaderProgramEXT)(GLenum type, GLuint program);
+};
+
+class QOpenGLExtension_EXT_separate_shader_objects : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_separate_shader_objects();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLuint glCreateShaderProgramEXT(GLenum type, const GLchar *string);
+ void glActiveProgramEXT(GLuint program);
+ void glUseShaderProgramEXT(GLenum type, GLuint program);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_separate_shader_objects)
+};
+
+inline GLuint QOpenGLExtension_EXT_separate_shader_objects::glCreateShaderProgramEXT(GLenum type, const GLchar *string)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ return d->CreateShaderProgramEXT(type, string);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glActiveProgramEXT(GLuint program)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ActiveProgramEXT(program);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glUseShaderProgramEXT(GLenum type, GLuint program)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->UseShaderProgramEXT(type, program);
+}
+
+class QOpenGLExtension_EXT_shader_image_load_storePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MemoryBarrierEXT)(GLbitfield barriers);
+ void (QOPENGLF_APIENTRYP BindImageTextureEXT)(GLuint index, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLint format);
+};
+
+class QOpenGLExtension_EXT_shader_image_load_store : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_shader_image_load_store();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMemoryBarrierEXT(GLbitfield barriers);
+ void glBindImageTextureEXT(GLuint index, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLint format);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_shader_image_load_store)
+};
+
+inline void QOpenGLExtension_EXT_shader_image_load_store::glMemoryBarrierEXT(GLbitfield barriers)
+{
+ Q_D(QOpenGLExtension_EXT_shader_image_load_store);
+ d->MemoryBarrierEXT(barriers);
+}
+
+inline void QOpenGLExtension_EXT_shader_image_load_store::glBindImageTextureEXT(GLuint index, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLint format)
+{
+ Q_D(QOpenGLExtension_EXT_shader_image_load_store);
+ d->BindImageTextureEXT(index, texture, level, layered, layer, access, format);
+}
+
+class QOpenGLExtension_EXT_stencil_clear_tagPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP StencilClearTagEXT)(GLsizei stencilTagBits, GLuint stencilClearTag);
+};
+
+class QOpenGLExtension_EXT_stencil_clear_tag : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_stencil_clear_tag();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glStencilClearTagEXT(GLsizei stencilTagBits, GLuint stencilClearTag);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_stencil_clear_tag)
+};
+
+inline void QOpenGLExtension_EXT_stencil_clear_tag::glStencilClearTagEXT(GLsizei stencilTagBits, GLuint stencilClearTag)
+{
+ Q_D(QOpenGLExtension_EXT_stencil_clear_tag);
+ d->StencilClearTagEXT(stencilTagBits, stencilClearTag);
+}
+
+class QOpenGLExtension_EXT_stencil_two_sidePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ActiveStencilFaceEXT)(GLenum face);
+};
+
+class QOpenGLExtension_EXT_stencil_two_side : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_stencil_two_side();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glActiveStencilFaceEXT(GLenum face);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_stencil_two_side)
+};
+
+inline void QOpenGLExtension_EXT_stencil_two_side::glActiveStencilFaceEXT(GLenum face)
+{
+ Q_D(QOpenGLExtension_EXT_stencil_two_side);
+ d->ActiveStencilFaceEXT(face);
+}
+
+class QOpenGLExtension_EXT_subtexturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexSubImage2DEXT)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP TexSubImage1DEXT)(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+};
+
+class QOpenGLExtension_EXT_subtexture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_subtexture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexSubImage2DEXT(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexSubImage1DEXT(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_subtexture)
+};
+
+inline void QOpenGLExtension_EXT_subtexture::glTexSubImage2DEXT(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_subtexture);
+ d->TexSubImage2DEXT(target, level, xoffset, yoffset, width, height, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_subtexture::glTexSubImage1DEXT(GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_subtexture);
+ d->TexSubImage1DEXT(target, level, xoffset, width, format, type, pixels);
+}
+
+class QOpenGLExtension_EXT_texture3DPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexSubImage3DEXT)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP TexImage3DEXT)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+};
+
+class QOpenGLExtension_EXT_texture3D : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_texture3D();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexSubImage3DEXT(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage3DEXT(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_texture3D)
+};
+
+inline void QOpenGLExtension_EXT_texture3D::glTexSubImage3DEXT(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_texture3D);
+ d->TexSubImage3DEXT(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLExtension_EXT_texture3D::glTexImage3DEXT(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_EXT_texture3D);
+ d->TexImage3DEXT(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+class QOpenGLExtension_EXT_texture_buffer_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexBufferEXT)(GLenum target, GLenum internalformat, GLuint buffer);
+};
+
+class QOpenGLExtension_EXT_texture_buffer_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_texture_buffer_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexBufferEXT(GLenum target, GLenum internalformat, GLuint buffer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_texture_buffer_object)
+};
+
+inline void QOpenGLExtension_EXT_texture_buffer_object::glTexBufferEXT(GLenum target, GLenum internalformat, GLuint buffer)
+{
+ Q_D(QOpenGLExtension_EXT_texture_buffer_object);
+ d->TexBufferEXT(target, internalformat, buffer);
+}
+
+class QOpenGLExtension_EXT_texture_integerPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ClearColorIuiEXT)(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void (QOPENGLF_APIENTRYP ClearColorIiEXT)(GLint red, GLint green, GLint blue, GLint alpha);
+ void (QOPENGLF_APIENTRYP GetTexParameterIuivEXT)(GLenum target, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetTexParameterIivEXT)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP TexParameterIuivEXT)(GLenum target, GLenum pname, const GLuint *params);
+ void (QOPENGLF_APIENTRYP TexParameterIivEXT)(GLenum target, GLenum pname, const GLint *params);
+};
+
+class QOpenGLExtension_EXT_texture_integer : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_texture_integer();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glClearColorIuiEXT(GLuint red, GLuint green, GLuint blue, GLuint alpha);
+ void glClearColorIiEXT(GLint red, GLint green, GLint blue, GLint alpha);
+ void glGetTexParameterIuivEXT(GLenum target, GLenum pname, GLuint *params);
+ void glGetTexParameterIivEXT(GLenum target, GLenum pname, GLint *params);
+ void glTexParameterIuivEXT(GLenum target, GLenum pname, const GLuint *params);
+ void glTexParameterIivEXT(GLenum target, GLenum pname, const GLint *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_texture_integer)
+};
+
+inline void QOpenGLExtension_EXT_texture_integer::glClearColorIuiEXT(GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ Q_D(QOpenGLExtension_EXT_texture_integer);
+ d->ClearColorIuiEXT(red, green, blue, alpha);
+}
+
+inline void QOpenGLExtension_EXT_texture_integer::glClearColorIiEXT(GLint red, GLint green, GLint blue, GLint alpha)
+{
+ Q_D(QOpenGLExtension_EXT_texture_integer);
+ d->ClearColorIiEXT(red, green, blue, alpha);
+}
+
+inline void QOpenGLExtension_EXT_texture_integer::glGetTexParameterIuivEXT(GLenum target, GLenum pname, GLuint *params)
+{
+ Q_D(QOpenGLExtension_EXT_texture_integer);
+ d->GetTexParameterIuivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_texture_integer::glGetTexParameterIivEXT(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_texture_integer);
+ d->GetTexParameterIivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_texture_integer::glTexParameterIuivEXT(GLenum target, GLenum pname, const GLuint *params)
+{
+ Q_D(QOpenGLExtension_EXT_texture_integer);
+ d->TexParameterIuivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_texture_integer::glTexParameterIivEXT(GLenum target, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_texture_integer);
+ d->TexParameterIivEXT(target, pname, params);
+}
+
+class QOpenGLExtension_EXT_texture_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP PrioritizeTexturesEXT)(GLsizei n, const GLuint *textures, const GLclampf *priorities);
+ GLboolean (QOPENGLF_APIENTRYP IsTextureEXT)(GLuint texture);
+ void (QOPENGLF_APIENTRYP GenTexturesEXT)(GLsizei n, GLuint *textures);
+ void (QOPENGLF_APIENTRYP DeleteTexturesEXT)(GLsizei n, const GLuint *textures);
+ void (QOPENGLF_APIENTRYP BindTextureEXT)(GLenum target, GLuint texture);
+ GLboolean (QOPENGLF_APIENTRYP AreTexturesResidentEXT)(GLsizei n, const GLuint *textures, GLboolean *residences);
+};
+
+class QOpenGLExtension_EXT_texture_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_texture_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glPrioritizeTexturesEXT(GLsizei n, const GLuint *textures, const GLclampf *priorities);
+ GLboolean glIsTextureEXT(GLuint texture);
+ void glGenTexturesEXT(GLsizei n, GLuint *textures);
+ void glDeleteTexturesEXT(GLsizei n, const GLuint *textures);
+ void glBindTextureEXT(GLenum target, GLuint texture);
+ GLboolean glAreTexturesResidentEXT(GLsizei n, const GLuint *textures, GLboolean *residences);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_texture_object)
+};
+
+inline void QOpenGLExtension_EXT_texture_object::glPrioritizeTexturesEXT(GLsizei n, const GLuint *textures, const GLclampf *priorities)
+{
+ Q_D(QOpenGLExtension_EXT_texture_object);
+ d->PrioritizeTexturesEXT(n, textures, priorities);
+}
+
+inline GLboolean QOpenGLExtension_EXT_texture_object::glIsTextureEXT(GLuint texture)
+{
+ Q_D(QOpenGLExtension_EXT_texture_object);
+ return d->IsTextureEXT(texture);
+}
+
+inline void QOpenGLExtension_EXT_texture_object::glGenTexturesEXT(GLsizei n, GLuint *textures)
+{
+ Q_D(QOpenGLExtension_EXT_texture_object);
+ d->GenTexturesEXT(n, textures);
+}
+
+inline void QOpenGLExtension_EXT_texture_object::glDeleteTexturesEXT(GLsizei n, const GLuint *textures)
+{
+ Q_D(QOpenGLExtension_EXT_texture_object);
+ d->DeleteTexturesEXT(n, textures);
+}
+
+inline void QOpenGLExtension_EXT_texture_object::glBindTextureEXT(GLenum target, GLuint texture)
+{
+ Q_D(QOpenGLExtension_EXT_texture_object);
+ d->BindTextureEXT(target, texture);
+}
+
+inline GLboolean QOpenGLExtension_EXT_texture_object::glAreTexturesResidentEXT(GLsizei n, const GLuint *textures, GLboolean *residences)
+{
+ Q_D(QOpenGLExtension_EXT_texture_object);
+ return d->AreTexturesResidentEXT(n, textures, residences);
+}
+
+class QOpenGLExtension_EXT_texture_perturb_normalPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TextureNormalEXT)(GLenum mode);
+};
+
+class QOpenGLExtension_EXT_texture_perturb_normal : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_texture_perturb_normal();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTextureNormalEXT(GLenum mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_texture_perturb_normal)
+};
+
+inline void QOpenGLExtension_EXT_texture_perturb_normal::glTextureNormalEXT(GLenum mode)
+{
+ Q_D(QOpenGLExtension_EXT_texture_perturb_normal);
+ d->TextureNormalEXT(mode);
+}
+
+class QOpenGLExtension_EXT_timer_queryPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetQueryObjectui64vEXT)(GLuint id, GLenum pname, GLuint64EXT *params);
+ void (QOPENGLF_APIENTRYP GetQueryObjecti64vEXT)(GLuint id, GLenum pname, GLint64EXT *params);
+};
+
+class QOpenGLExtension_EXT_timer_query : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_timer_query();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetQueryObjectui64vEXT(GLuint id, GLenum pname, GLuint64EXT *params);
+ void glGetQueryObjecti64vEXT(GLuint id, GLenum pname, GLint64EXT *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_timer_query)
+};
+
+inline void QOpenGLExtension_EXT_timer_query::glGetQueryObjectui64vEXT(GLuint id, GLenum pname, GLuint64EXT *params)
+{
+ Q_D(QOpenGLExtension_EXT_timer_query);
+ d->GetQueryObjectui64vEXT(id, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_timer_query::glGetQueryObjecti64vEXT(GLuint id, GLenum pname, GLint64EXT *params)
+{
+ Q_D(QOpenGLExtension_EXT_timer_query);
+ d->GetQueryObjecti64vEXT(id, pname, params);
+}
+
+class QOpenGLExtension_EXT_transform_feedbackPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetTransformFeedbackVaryingEXT)(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void (QOPENGLF_APIENTRYP TransformFeedbackVaryingsEXT)(GLuint program, GLsizei count, const GLchar* *varyings, GLenum bufferMode);
+ void (QOPENGLF_APIENTRYP BindBufferBaseEXT)(GLenum target, GLuint index, GLuint buffer);
+ void (QOPENGLF_APIENTRYP BindBufferOffsetEXT)(GLenum target, GLuint index, GLuint buffer, GLintptr offset);
+ void (QOPENGLF_APIENTRYP BindBufferRangeEXT)(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void (QOPENGLF_APIENTRYP EndTransformFeedbackEXT)();
+ void (QOPENGLF_APIENTRYP BeginTransformFeedbackEXT)(GLenum primitiveMode);
+};
+
+class QOpenGLExtension_EXT_transform_feedback : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_transform_feedback();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetTransformFeedbackVaryingEXT(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ void glTransformFeedbackVaryingsEXT(GLuint program, GLsizei count, const GLchar* *varyings, GLenum bufferMode);
+ void glBindBufferBaseEXT(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferOffsetEXT(GLenum target, GLuint index, GLuint buffer, GLintptr offset);
+ void glBindBufferRangeEXT(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glEndTransformFeedbackEXT();
+ void glBeginTransformFeedbackEXT(GLenum primitiveMode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_transform_feedback)
+};
+
+inline void QOpenGLExtension_EXT_transform_feedback::glGetTransformFeedbackVaryingEXT(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ Q_D(QOpenGLExtension_EXT_transform_feedback);
+ d->GetTransformFeedbackVaryingEXT(program, index, bufSize, length, size, type, name);
+}
+
+inline void QOpenGLExtension_EXT_transform_feedback::glTransformFeedbackVaryingsEXT(GLuint program, GLsizei count, const GLchar* *varyings, GLenum bufferMode)
+{
+ Q_D(QOpenGLExtension_EXT_transform_feedback);
+ d->TransformFeedbackVaryingsEXT(program, count, varyings, bufferMode);
+}
+
+inline void QOpenGLExtension_EXT_transform_feedback::glBindBufferBaseEXT(GLenum target, GLuint index, GLuint buffer)
+{
+ Q_D(QOpenGLExtension_EXT_transform_feedback);
+ d->BindBufferBaseEXT(target, index, buffer);
+}
+
+inline void QOpenGLExtension_EXT_transform_feedback::glBindBufferOffsetEXT(GLenum target, GLuint index, GLuint buffer, GLintptr offset)
+{
+ Q_D(QOpenGLExtension_EXT_transform_feedback);
+ d->BindBufferOffsetEXT(target, index, buffer, offset);
+}
+
+inline void QOpenGLExtension_EXT_transform_feedback::glBindBufferRangeEXT(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ Q_D(QOpenGLExtension_EXT_transform_feedback);
+ d->BindBufferRangeEXT(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLExtension_EXT_transform_feedback::glEndTransformFeedbackEXT()
+{
+ Q_D(QOpenGLExtension_EXT_transform_feedback);
+ d->EndTransformFeedbackEXT();
+}
+
+inline void QOpenGLExtension_EXT_transform_feedback::glBeginTransformFeedbackEXT(GLenum primitiveMode)
+{
+ Q_D(QOpenGLExtension_EXT_transform_feedback);
+ d->BeginTransformFeedbackEXT(primitiveMode);
+}
+
+class QOpenGLExtension_EXT_vertex_arrayPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexPointerEXT)(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP TexCoordPointerEXT)(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP NormalPointerEXT)(GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP IndexPointerEXT)(GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP GetPointervEXT)(GLenum pname, GLvoid* *params);
+ void (QOPENGLF_APIENTRYP EdgeFlagPointerEXT)(GLsizei stride, GLsizei count, const GLboolean *pointer);
+ void (QOPENGLF_APIENTRYP DrawArraysEXT)(GLenum mode, GLint first, GLsizei count);
+ void (QOPENGLF_APIENTRYP ColorPointerEXT)(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP ArrayElementEXT)(GLint i);
+};
+
+class QOpenGLExtension_EXT_vertex_array : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_vertex_array();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexPointerEXT(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
+ void glTexCoordPointerEXT(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
+ void glNormalPointerEXT(GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
+ void glIndexPointerEXT(GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
+ void glGetPointervEXT(GLenum pname, GLvoid* *params);
+ void glEdgeFlagPointerEXT(GLsizei stride, GLsizei count, const GLboolean *pointer);
+ void glDrawArraysEXT(GLenum mode, GLint first, GLsizei count);
+ void glColorPointerEXT(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
+ void glArrayElementEXT(GLint i);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_vertex_array)
+};
+
+inline void QOpenGLExtension_EXT_vertex_array::glVertexPointerEXT(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_array);
+ d->VertexPointerEXT(size, type, stride, count, pointer);
+}
+
+inline void QOpenGLExtension_EXT_vertex_array::glTexCoordPointerEXT(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_array);
+ d->TexCoordPointerEXT(size, type, stride, count, pointer);
+}
+
+inline void QOpenGLExtension_EXT_vertex_array::glNormalPointerEXT(GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_array);
+ d->NormalPointerEXT(type, stride, count, pointer);
+}
+
+inline void QOpenGLExtension_EXT_vertex_array::glIndexPointerEXT(GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_array);
+ d->IndexPointerEXT(type, stride, count, pointer);
+}
+
+inline void QOpenGLExtension_EXT_vertex_array::glGetPointervEXT(GLenum pname, GLvoid* *params)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_array);
+ d->GetPointervEXT(pname, params);
+}
+
+inline void QOpenGLExtension_EXT_vertex_array::glEdgeFlagPointerEXT(GLsizei stride, GLsizei count, const GLboolean *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_array);
+ d->EdgeFlagPointerEXT(stride, count, pointer);
+}
+
+inline void QOpenGLExtension_EXT_vertex_array::glDrawArraysEXT(GLenum mode, GLint first, GLsizei count)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_array);
+ d->DrawArraysEXT(mode, first, count);
+}
+
+inline void QOpenGLExtension_EXT_vertex_array::glColorPointerEXT(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_array);
+ d->ColorPointerEXT(size, type, stride, count, pointer);
+}
+
+inline void QOpenGLExtension_EXT_vertex_array::glArrayElementEXT(GLint i)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_array);
+ d->ArrayElementEXT(i);
+}
+
+class QOpenGLExtension_EXT_vertex_attrib_64bitPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexArrayVertexAttribLOffsetEXT)(GLuint vaobj, GLuint buffer, GLuint index, GLint size, GLenum type, GLsizei stride, GLintptr offset);
+ void (QOPENGLF_APIENTRYP GetVertexAttribLdvEXT)(GLuint index, GLenum pname, GLdouble *params);
+ void (QOPENGLF_APIENTRYP VertexAttribLPointerEXT)(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP VertexAttribL4dvEXT)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL3dvEXT)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL2dvEXT)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL1dvEXT)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL4dEXT)(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP VertexAttribL3dEXT)(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP VertexAttribL2dEXT)(GLuint index, GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP VertexAttribL1dEXT)(GLuint index, GLdouble x);
+};
+
+class QOpenGLExtension_EXT_vertex_attrib_64bit : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_vertex_attrib_64bit();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexArrayVertexAttribLOffsetEXT(GLuint vaobj, GLuint buffer, GLuint index, GLint size, GLenum type, GLsizei stride, GLintptr offset);
+ void glGetVertexAttribLdvEXT(GLuint index, GLenum pname, GLdouble *params);
+ void glVertexAttribLPointerEXT(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glVertexAttribL4dvEXT(GLuint index, const GLdouble *v);
+ void glVertexAttribL3dvEXT(GLuint index, const GLdouble *v);
+ void glVertexAttribL2dvEXT(GLuint index, const GLdouble *v);
+ void glVertexAttribL1dvEXT(GLuint index, const GLdouble *v);
+ void glVertexAttribL4dEXT(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttribL3dEXT(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttribL2dEXT(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttribL1dEXT(GLuint index, GLdouble x);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_vertex_attrib_64bit)
+};
+
+inline void QOpenGLExtension_EXT_vertex_attrib_64bit::glVertexArrayVertexAttribLOffsetEXT(GLuint vaobj, GLuint buffer, GLuint index, GLint size, GLenum type, GLsizei stride, GLintptr offset)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_attrib_64bit);
+ d->VertexArrayVertexAttribLOffsetEXT(vaobj, buffer, index, size, type, stride, offset);
+}
+
+inline void QOpenGLExtension_EXT_vertex_attrib_64bit::glGetVertexAttribLdvEXT(GLuint index, GLenum pname, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_attrib_64bit);
+ d->GetVertexAttribLdvEXT(index, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_vertex_attrib_64bit::glVertexAttribLPointerEXT(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_attrib_64bit);
+ d->VertexAttribLPointerEXT(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLExtension_EXT_vertex_attrib_64bit::glVertexAttribL4dvEXT(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_attrib_64bit);
+ d->VertexAttribL4dvEXT(index, v);
+}
+
+inline void QOpenGLExtension_EXT_vertex_attrib_64bit::glVertexAttribL3dvEXT(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_attrib_64bit);
+ d->VertexAttribL3dvEXT(index, v);
+}
+
+inline void QOpenGLExtension_EXT_vertex_attrib_64bit::glVertexAttribL2dvEXT(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_attrib_64bit);
+ d->VertexAttribL2dvEXT(index, v);
+}
+
+inline void QOpenGLExtension_EXT_vertex_attrib_64bit::glVertexAttribL1dvEXT(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_attrib_64bit);
+ d->VertexAttribL1dvEXT(index, v);
+}
+
+inline void QOpenGLExtension_EXT_vertex_attrib_64bit::glVertexAttribL4dEXT(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_attrib_64bit);
+ d->VertexAttribL4dEXT(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_EXT_vertex_attrib_64bit::glVertexAttribL3dEXT(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_attrib_64bit);
+ d->VertexAttribL3dEXT(index, x, y, z);
+}
+
+inline void QOpenGLExtension_EXT_vertex_attrib_64bit::glVertexAttribL2dEXT(GLuint index, GLdouble x, GLdouble y)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_attrib_64bit);
+ d->VertexAttribL2dEXT(index, x, y);
+}
+
+inline void QOpenGLExtension_EXT_vertex_attrib_64bit::glVertexAttribL1dEXT(GLuint index, GLdouble x)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_attrib_64bit);
+ d->VertexAttribL1dEXT(index, x);
+}
+
+class QOpenGLExtension_EXT_vertex_shaderPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetLocalConstantFloatvEXT)(GLuint id, GLenum value, GLfloat *data);
+ void (QOPENGLF_APIENTRYP GetLocalConstantIntegervEXT)(GLuint id, GLenum value, GLint *data);
+ void (QOPENGLF_APIENTRYP GetLocalConstantBooleanvEXT)(GLuint id, GLenum value, GLboolean *data);
+ void (QOPENGLF_APIENTRYP GetInvariantFloatvEXT)(GLuint id, GLenum value, GLfloat *data);
+ void (QOPENGLF_APIENTRYP GetInvariantIntegervEXT)(GLuint id, GLenum value, GLint *data);
+ void (QOPENGLF_APIENTRYP GetInvariantBooleanvEXT)(GLuint id, GLenum value, GLboolean *data);
+ void (QOPENGLF_APIENTRYP GetVariantPointervEXT)(GLuint id, GLenum value, GLvoid* *data);
+ void (QOPENGLF_APIENTRYP GetVariantFloatvEXT)(GLuint id, GLenum value, GLfloat *data);
+ void (QOPENGLF_APIENTRYP GetVariantIntegervEXT)(GLuint id, GLenum value, GLint *data);
+ void (QOPENGLF_APIENTRYP GetVariantBooleanvEXT)(GLuint id, GLenum value, GLboolean *data);
+ GLboolean (QOPENGLF_APIENTRYP IsVariantEnabledEXT)(GLuint id, GLenum cap);
+ GLuint (QOPENGLF_APIENTRYP BindParameterEXT)(GLenum value);
+ GLuint (QOPENGLF_APIENTRYP BindTextureUnitParameterEXT)(GLenum unit, GLenum value);
+ GLuint (QOPENGLF_APIENTRYP BindTexGenParameterEXT)(GLenum unit, GLenum coord, GLenum value);
+ GLuint (QOPENGLF_APIENTRYP BindMaterialParameterEXT)(GLenum face, GLenum value);
+ GLuint (QOPENGLF_APIENTRYP BindLightParameterEXT)(GLenum light, GLenum value);
+ void (QOPENGLF_APIENTRYP DisableVariantClientStateEXT)(GLuint id);
+ void (QOPENGLF_APIENTRYP EnableVariantClientStateEXT)(GLuint id);
+ void (QOPENGLF_APIENTRYP VariantPointerEXT)(GLuint id, GLenum type, GLuint stride, const GLvoid *addr);
+ void (QOPENGLF_APIENTRYP VariantuivEXT)(GLuint id, const GLuint *addr);
+ void (QOPENGLF_APIENTRYP VariantusvEXT)(GLuint id, const GLushort *addr);
+ void (QOPENGLF_APIENTRYP VariantubvEXT)(GLuint id, const GLubyte *addr);
+ void (QOPENGLF_APIENTRYP VariantdvEXT)(GLuint id, const GLdouble *addr);
+ void (QOPENGLF_APIENTRYP VariantfvEXT)(GLuint id, const GLfloat *addr);
+ void (QOPENGLF_APIENTRYP VariantivEXT)(GLuint id, const GLint *addr);
+ void (QOPENGLF_APIENTRYP VariantsvEXT)(GLuint id, const GLshort *addr);
+ void (QOPENGLF_APIENTRYP VariantbvEXT)(GLuint id, const GLbyte *addr);
+ void (QOPENGLF_APIENTRYP SetLocalConstantEXT)(GLuint id, GLenum type, const GLvoid *addr);
+ void (QOPENGLF_APIENTRYP SetInvariantEXT)(GLuint id, GLenum type, const GLvoid *addr);
+ GLuint (QOPENGLF_APIENTRYP GenSymbolsEXT)(GLenum datatype, GLenum storagetype, GLenum range, GLuint components);
+ void (QOPENGLF_APIENTRYP ExtractComponentEXT)(GLuint res, GLuint src, GLuint num);
+ void (QOPENGLF_APIENTRYP InsertComponentEXT)(GLuint res, GLuint src, GLuint num);
+ void (QOPENGLF_APIENTRYP WriteMaskEXT)(GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW);
+ void (QOPENGLF_APIENTRYP SwizzleEXT)(GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW);
+ void (QOPENGLF_APIENTRYP ShaderOp3EXT)(GLenum op, GLuint res, GLuint arg1, GLuint arg2, GLuint arg3);
+ void (QOPENGLF_APIENTRYP ShaderOp2EXT)(GLenum op, GLuint res, GLuint arg1, GLuint arg2);
+ void (QOPENGLF_APIENTRYP ShaderOp1EXT)(GLenum op, GLuint res, GLuint arg1);
+ void (QOPENGLF_APIENTRYP DeleteVertexShaderEXT)(GLuint id);
+ GLuint (QOPENGLF_APIENTRYP GenVertexShadersEXT)(GLuint range);
+ void (QOPENGLF_APIENTRYP BindVertexShaderEXT)(GLuint id);
+ void (QOPENGLF_APIENTRYP EndVertexShaderEXT)();
+ void (QOPENGLF_APIENTRYP BeginVertexShaderEXT)();
+};
+
+class QOpenGLExtension_EXT_vertex_shader : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_vertex_shader();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetLocalConstantFloatvEXT(GLuint id, GLenum value, GLfloat *data);
+ void glGetLocalConstantIntegervEXT(GLuint id, GLenum value, GLint *data);
+ void glGetLocalConstantBooleanvEXT(GLuint id, GLenum value, GLboolean *data);
+ void glGetInvariantFloatvEXT(GLuint id, GLenum value, GLfloat *data);
+ void glGetInvariantIntegervEXT(GLuint id, GLenum value, GLint *data);
+ void glGetInvariantBooleanvEXT(GLuint id, GLenum value, GLboolean *data);
+ void glGetVariantPointervEXT(GLuint id, GLenum value, GLvoid* *data);
+ void glGetVariantFloatvEXT(GLuint id, GLenum value, GLfloat *data);
+ void glGetVariantIntegervEXT(GLuint id, GLenum value, GLint *data);
+ void glGetVariantBooleanvEXT(GLuint id, GLenum value, GLboolean *data);
+ GLboolean glIsVariantEnabledEXT(GLuint id, GLenum cap);
+ GLuint glBindParameterEXT(GLenum value);
+ GLuint glBindTextureUnitParameterEXT(GLenum unit, GLenum value);
+ GLuint glBindTexGenParameterEXT(GLenum unit, GLenum coord, GLenum value);
+ GLuint glBindMaterialParameterEXT(GLenum face, GLenum value);
+ GLuint glBindLightParameterEXT(GLenum light, GLenum value);
+ void glDisableVariantClientStateEXT(GLuint id);
+ void glEnableVariantClientStateEXT(GLuint id);
+ void glVariantPointerEXT(GLuint id, GLenum type, GLuint stride, const GLvoid *addr);
+ void glVariantuivEXT(GLuint id, const GLuint *addr);
+ void glVariantusvEXT(GLuint id, const GLushort *addr);
+ void glVariantubvEXT(GLuint id, const GLubyte *addr);
+ void glVariantdvEXT(GLuint id, const GLdouble *addr);
+ void glVariantfvEXT(GLuint id, const GLfloat *addr);
+ void glVariantivEXT(GLuint id, const GLint *addr);
+ void glVariantsvEXT(GLuint id, const GLshort *addr);
+ void glVariantbvEXT(GLuint id, const GLbyte *addr);
+ void glSetLocalConstantEXT(GLuint id, GLenum type, const GLvoid *addr);
+ void glSetInvariantEXT(GLuint id, GLenum type, const GLvoid *addr);
+ GLuint glGenSymbolsEXT(GLenum datatype, GLenum storagetype, GLenum range, GLuint components);
+ void glExtractComponentEXT(GLuint res, GLuint src, GLuint num);
+ void glInsertComponentEXT(GLuint res, GLuint src, GLuint num);
+ void glWriteMaskEXT(GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW);
+ void glSwizzleEXT(GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW);
+ void glShaderOp3EXT(GLenum op, GLuint res, GLuint arg1, GLuint arg2, GLuint arg3);
+ void glShaderOp2EXT(GLenum op, GLuint res, GLuint arg1, GLuint arg2);
+ void glShaderOp1EXT(GLenum op, GLuint res, GLuint arg1);
+ void glDeleteVertexShaderEXT(GLuint id);
+ GLuint glGenVertexShadersEXT(GLuint range);
+ void glBindVertexShaderEXT(GLuint id);
+ void glEndVertexShaderEXT();
+ void glBeginVertexShaderEXT();
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_vertex_shader)
+};
+
+inline void QOpenGLExtension_EXT_vertex_shader::glGetLocalConstantFloatvEXT(GLuint id, GLenum value, GLfloat *data)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->GetLocalConstantFloatvEXT(id, value, data);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glGetLocalConstantIntegervEXT(GLuint id, GLenum value, GLint *data)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->GetLocalConstantIntegervEXT(id, value, data);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glGetLocalConstantBooleanvEXT(GLuint id, GLenum value, GLboolean *data)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->GetLocalConstantBooleanvEXT(id, value, data);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glGetInvariantFloatvEXT(GLuint id, GLenum value, GLfloat *data)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->GetInvariantFloatvEXT(id, value, data);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glGetInvariantIntegervEXT(GLuint id, GLenum value, GLint *data)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->GetInvariantIntegervEXT(id, value, data);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glGetInvariantBooleanvEXT(GLuint id, GLenum value, GLboolean *data)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->GetInvariantBooleanvEXT(id, value, data);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glGetVariantPointervEXT(GLuint id, GLenum value, GLvoid* *data)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->GetVariantPointervEXT(id, value, data);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glGetVariantFloatvEXT(GLuint id, GLenum value, GLfloat *data)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->GetVariantFloatvEXT(id, value, data);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glGetVariantIntegervEXT(GLuint id, GLenum value, GLint *data)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->GetVariantIntegervEXT(id, value, data);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glGetVariantBooleanvEXT(GLuint id, GLenum value, GLboolean *data)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->GetVariantBooleanvEXT(id, value, data);
+}
+
+inline GLboolean QOpenGLExtension_EXT_vertex_shader::glIsVariantEnabledEXT(GLuint id, GLenum cap)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ return d->IsVariantEnabledEXT(id, cap);
+}
+
+inline GLuint QOpenGLExtension_EXT_vertex_shader::glBindParameterEXT(GLenum value)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ return d->BindParameterEXT(value);
+}
+
+inline GLuint QOpenGLExtension_EXT_vertex_shader::glBindTextureUnitParameterEXT(GLenum unit, GLenum value)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ return d->BindTextureUnitParameterEXT(unit, value);
+}
+
+inline GLuint QOpenGLExtension_EXT_vertex_shader::glBindTexGenParameterEXT(GLenum unit, GLenum coord, GLenum value)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ return d->BindTexGenParameterEXT(unit, coord, value);
+}
+
+inline GLuint QOpenGLExtension_EXT_vertex_shader::glBindMaterialParameterEXT(GLenum face, GLenum value)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ return d->BindMaterialParameterEXT(face, value);
+}
+
+inline GLuint QOpenGLExtension_EXT_vertex_shader::glBindLightParameterEXT(GLenum light, GLenum value)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ return d->BindLightParameterEXT(light, value);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glDisableVariantClientStateEXT(GLuint id)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->DisableVariantClientStateEXT(id);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glEnableVariantClientStateEXT(GLuint id)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->EnableVariantClientStateEXT(id);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glVariantPointerEXT(GLuint id, GLenum type, GLuint stride, const GLvoid *addr)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->VariantPointerEXT(id, type, stride, addr);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glVariantuivEXT(GLuint id, const GLuint *addr)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->VariantuivEXT(id, addr);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glVariantusvEXT(GLuint id, const GLushort *addr)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->VariantusvEXT(id, addr);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glVariantubvEXT(GLuint id, const GLubyte *addr)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->VariantubvEXT(id, addr);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glVariantdvEXT(GLuint id, const GLdouble *addr)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->VariantdvEXT(id, addr);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glVariantfvEXT(GLuint id, const GLfloat *addr)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->VariantfvEXT(id, addr);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glVariantivEXT(GLuint id, const GLint *addr)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->VariantivEXT(id, addr);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glVariantsvEXT(GLuint id, const GLshort *addr)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->VariantsvEXT(id, addr);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glVariantbvEXT(GLuint id, const GLbyte *addr)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->VariantbvEXT(id, addr);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glSetLocalConstantEXT(GLuint id, GLenum type, const GLvoid *addr)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->SetLocalConstantEXT(id, type, addr);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glSetInvariantEXT(GLuint id, GLenum type, const GLvoid *addr)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->SetInvariantEXT(id, type, addr);
+}
+
+inline GLuint QOpenGLExtension_EXT_vertex_shader::glGenSymbolsEXT(GLenum datatype, GLenum storagetype, GLenum range, GLuint components)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ return d->GenSymbolsEXT(datatype, storagetype, range, components);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glExtractComponentEXT(GLuint res, GLuint src, GLuint num)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->ExtractComponentEXT(res, src, num);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glInsertComponentEXT(GLuint res, GLuint src, GLuint num)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->InsertComponentEXT(res, src, num);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glWriteMaskEXT(GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->WriteMaskEXT(res, in, outX, outY, outZ, outW);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glSwizzleEXT(GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->SwizzleEXT(res, in, outX, outY, outZ, outW);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glShaderOp3EXT(GLenum op, GLuint res, GLuint arg1, GLuint arg2, GLuint arg3)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->ShaderOp3EXT(op, res, arg1, arg2, arg3);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glShaderOp2EXT(GLenum op, GLuint res, GLuint arg1, GLuint arg2)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->ShaderOp2EXT(op, res, arg1, arg2);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glShaderOp1EXT(GLenum op, GLuint res, GLuint arg1)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->ShaderOp1EXT(op, res, arg1);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glDeleteVertexShaderEXT(GLuint id)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->DeleteVertexShaderEXT(id);
+}
+
+inline GLuint QOpenGLExtension_EXT_vertex_shader::glGenVertexShadersEXT(GLuint range)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ return d->GenVertexShadersEXT(range);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glBindVertexShaderEXT(GLuint id)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->BindVertexShaderEXT(id);
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glEndVertexShaderEXT()
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->EndVertexShaderEXT();
+}
+
+inline void QOpenGLExtension_EXT_vertex_shader::glBeginVertexShaderEXT()
+{
+ Q_D(QOpenGLExtension_EXT_vertex_shader);
+ d->BeginVertexShaderEXT();
+}
+
+class QOpenGLExtension_EXT_vertex_weightingPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexWeightPointerEXT)(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP VertexWeightfvEXT)(const GLfloat *weight);
+ void (QOPENGLF_APIENTRYP VertexWeightfEXT)(GLfloat weight);
+};
+
+class QOpenGLExtension_EXT_vertex_weighting : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_vertex_weighting();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexWeightPointerEXT(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glVertexWeightfvEXT(const GLfloat *weight);
+ void glVertexWeightfEXT(GLfloat weight);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_vertex_weighting)
+};
+
+inline void QOpenGLExtension_EXT_vertex_weighting::glVertexWeightPointerEXT(GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_weighting);
+ d->VertexWeightPointerEXT(size, type, stride, pointer);
+}
+
+inline void QOpenGLExtension_EXT_vertex_weighting::glVertexWeightfvEXT(const GLfloat *weight)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_weighting);
+ d->VertexWeightfvEXT(weight);
+}
+
+inline void QOpenGLExtension_EXT_vertex_weighting::glVertexWeightfEXT(GLfloat weight)
+{
+ Q_D(QOpenGLExtension_EXT_vertex_weighting);
+ d->VertexWeightfEXT(weight);
+}
+
+class QOpenGLExtension_EXT_x11_sync_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLsync (QOPENGLF_APIENTRYP ImportSyncEXT)(GLenum external_sync_type, GLintptr external_sync, GLbitfield flags);
+};
+
+class QOpenGLExtension_EXT_x11_sync_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_x11_sync_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLsync glImportSyncEXT(GLenum external_sync_type, GLintptr external_sync, GLbitfield flags);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_x11_sync_object)
+};
+
+inline GLsync QOpenGLExtension_EXT_x11_sync_object::glImportSyncEXT(GLenum external_sync_type, GLintptr external_sync, GLbitfield flags)
+{
+ Q_D(QOpenGLExtension_EXT_x11_sync_object);
+ return d->ImportSyncEXT(external_sync_type, external_sync, flags);
+}
+
+class QOpenGLExtension_GREMEDY_frame_terminatorPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP FrameTerminatorGREMEDY)();
+};
+
+class QOpenGLExtension_GREMEDY_frame_terminator : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_GREMEDY_frame_terminator();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glFrameTerminatorGREMEDY();
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_GREMEDY_frame_terminator)
+};
+
+inline void QOpenGLExtension_GREMEDY_frame_terminator::glFrameTerminatorGREMEDY()
+{
+ Q_D(QOpenGLExtension_GREMEDY_frame_terminator);
+ d->FrameTerminatorGREMEDY();
+}
+
+class QOpenGLExtension_GREMEDY_string_markerPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP StringMarkerGREMEDY)(GLsizei len, const GLvoid *string);
+};
+
+class QOpenGLExtension_GREMEDY_string_marker : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_GREMEDY_string_marker();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glStringMarkerGREMEDY(GLsizei len, const GLvoid *string);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_GREMEDY_string_marker)
+};
+
+inline void QOpenGLExtension_GREMEDY_string_marker::glStringMarkerGREMEDY(GLsizei len, const GLvoid *string)
+{
+ Q_D(QOpenGLExtension_GREMEDY_string_marker);
+ d->StringMarkerGREMEDY(len, string);
+}
+
+class QOpenGLExtension_HP_image_transformPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetImageTransformParameterfvHP)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetImageTransformParameterivHP)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP ImageTransformParameterfvHP)(GLenum target, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP ImageTransformParameterivHP)(GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP ImageTransformParameterfHP)(GLenum target, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP ImageTransformParameteriHP)(GLenum target, GLenum pname, GLint param);
+};
+
+class QOpenGLExtension_HP_image_transform : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_HP_image_transform();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetImageTransformParameterfvHP(GLenum target, GLenum pname, GLfloat *params);
+ void glGetImageTransformParameterivHP(GLenum target, GLenum pname, GLint *params);
+ void glImageTransformParameterfvHP(GLenum target, GLenum pname, const GLfloat *params);
+ void glImageTransformParameterivHP(GLenum target, GLenum pname, const GLint *params);
+ void glImageTransformParameterfHP(GLenum target, GLenum pname, GLfloat param);
+ void glImageTransformParameteriHP(GLenum target, GLenum pname, GLint param);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_HP_image_transform)
+};
+
+inline void QOpenGLExtension_HP_image_transform::glGetImageTransformParameterfvHP(GLenum target, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_HP_image_transform);
+ d->GetImageTransformParameterfvHP(target, pname, params);
+}
+
+inline void QOpenGLExtension_HP_image_transform::glGetImageTransformParameterivHP(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_HP_image_transform);
+ d->GetImageTransformParameterivHP(target, pname, params);
+}
+
+inline void QOpenGLExtension_HP_image_transform::glImageTransformParameterfvHP(GLenum target, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_HP_image_transform);
+ d->ImageTransformParameterfvHP(target, pname, params);
+}
+
+inline void QOpenGLExtension_HP_image_transform::glImageTransformParameterivHP(GLenum target, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_HP_image_transform);
+ d->ImageTransformParameterivHP(target, pname, params);
+}
+
+inline void QOpenGLExtension_HP_image_transform::glImageTransformParameterfHP(GLenum target, GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_HP_image_transform);
+ d->ImageTransformParameterfHP(target, pname, param);
+}
+
+inline void QOpenGLExtension_HP_image_transform::glImageTransformParameteriHP(GLenum target, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_HP_image_transform);
+ d->ImageTransformParameteriHP(target, pname, param);
+}
+
+class QOpenGLExtension_IBM_multimode_draw_arraysPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MultiModeDrawElementsIBM)(const GLenum *mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount, GLint modestride);
+ void (QOPENGLF_APIENTRYP MultiModeDrawArraysIBM)(const GLenum *mode, const GLint *first, const GLsizei *count, GLsizei primcount, GLint modestride);
+};
+
+class QOpenGLExtension_IBM_multimode_draw_arrays : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_IBM_multimode_draw_arrays();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMultiModeDrawElementsIBM(const GLenum *mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount, GLint modestride);
+ void glMultiModeDrawArraysIBM(const GLenum *mode, const GLint *first, const GLsizei *count, GLsizei primcount, GLint modestride);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_IBM_multimode_draw_arrays)
+};
+
+inline void QOpenGLExtension_IBM_multimode_draw_arrays::glMultiModeDrawElementsIBM(const GLenum *mode, const GLsizei *count, GLenum type, const GLvoid* const *indices, GLsizei primcount, GLint modestride)
+{
+ Q_D(QOpenGLExtension_IBM_multimode_draw_arrays);
+ d->MultiModeDrawElementsIBM(mode, count, type, indices, primcount, modestride);
+}
+
+inline void QOpenGLExtension_IBM_multimode_draw_arrays::glMultiModeDrawArraysIBM(const GLenum *mode, const GLint *first, const GLsizei *count, GLsizei primcount, GLint modestride)
+{
+ Q_D(QOpenGLExtension_IBM_multimode_draw_arrays);
+ d->MultiModeDrawArraysIBM(mode, first, count, primcount, modestride);
+}
+
+class QOpenGLExtension_IBM_vertex_array_listsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexPointerListIBM)(GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+ void (QOPENGLF_APIENTRYP TexCoordPointerListIBM)(GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+ void (QOPENGLF_APIENTRYP NormalPointerListIBM)(GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+ void (QOPENGLF_APIENTRYP IndexPointerListIBM)(GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+ void (QOPENGLF_APIENTRYP FogCoordPointerListIBM)(GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+ void (QOPENGLF_APIENTRYP EdgeFlagPointerListIBM)(GLint stride, const GLboolean* *pointer, GLint ptrstride);
+ void (QOPENGLF_APIENTRYP SecondaryColorPointerListIBM)(GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+ void (QOPENGLF_APIENTRYP ColorPointerListIBM)(GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+};
+
+class QOpenGLExtension_IBM_vertex_array_lists : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_IBM_vertex_array_lists();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexPointerListIBM(GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+ void glTexCoordPointerListIBM(GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+ void glNormalPointerListIBM(GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+ void glIndexPointerListIBM(GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+ void glFogCoordPointerListIBM(GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+ void glEdgeFlagPointerListIBM(GLint stride, const GLboolean* *pointer, GLint ptrstride);
+ void glSecondaryColorPointerListIBM(GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+ void glColorPointerListIBM(GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_IBM_vertex_array_lists)
+};
+
+inline void QOpenGLExtension_IBM_vertex_array_lists::glVertexPointerListIBM(GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride)
+{
+ Q_D(QOpenGLExtension_IBM_vertex_array_lists);
+ d->VertexPointerListIBM(size, type, stride, pointer, ptrstride);
+}
+
+inline void QOpenGLExtension_IBM_vertex_array_lists::glTexCoordPointerListIBM(GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride)
+{
+ Q_D(QOpenGLExtension_IBM_vertex_array_lists);
+ d->TexCoordPointerListIBM(size, type, stride, pointer, ptrstride);
+}
+
+inline void QOpenGLExtension_IBM_vertex_array_lists::glNormalPointerListIBM(GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride)
+{
+ Q_D(QOpenGLExtension_IBM_vertex_array_lists);
+ d->NormalPointerListIBM(type, stride, pointer, ptrstride);
+}
+
+inline void QOpenGLExtension_IBM_vertex_array_lists::glIndexPointerListIBM(GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride)
+{
+ Q_D(QOpenGLExtension_IBM_vertex_array_lists);
+ d->IndexPointerListIBM(type, stride, pointer, ptrstride);
+}
+
+inline void QOpenGLExtension_IBM_vertex_array_lists::glFogCoordPointerListIBM(GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride)
+{
+ Q_D(QOpenGLExtension_IBM_vertex_array_lists);
+ d->FogCoordPointerListIBM(type, stride, pointer, ptrstride);
+}
+
+inline void QOpenGLExtension_IBM_vertex_array_lists::glEdgeFlagPointerListIBM(GLint stride, const GLboolean* *pointer, GLint ptrstride)
+{
+ Q_D(QOpenGLExtension_IBM_vertex_array_lists);
+ d->EdgeFlagPointerListIBM(stride, pointer, ptrstride);
+}
+
+inline void QOpenGLExtension_IBM_vertex_array_lists::glSecondaryColorPointerListIBM(GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride)
+{
+ Q_D(QOpenGLExtension_IBM_vertex_array_lists);
+ d->SecondaryColorPointerListIBM(size, type, stride, pointer, ptrstride);
+}
+
+inline void QOpenGLExtension_IBM_vertex_array_lists::glColorPointerListIBM(GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride)
+{
+ Q_D(QOpenGLExtension_IBM_vertex_array_lists);
+ d->ColorPointerListIBM(size, type, stride, pointer, ptrstride);
+}
+
+class QOpenGLExtension_INGR_blend_func_separatePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BlendFuncSeparateINGR)(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+};
+
+class QOpenGLExtension_INGR_blend_func_separate : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_INGR_blend_func_separate();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBlendFuncSeparateINGR(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_INGR_blend_func_separate)
+};
+
+inline void QOpenGLExtension_INGR_blend_func_separate::glBlendFuncSeparateINGR(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ Q_D(QOpenGLExtension_INGR_blend_func_separate);
+ d->BlendFuncSeparateINGR(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+class QOpenGLExtension_INTEL_parallel_arraysPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexCoordPointervINTEL)(GLint size, GLenum type, const GLvoid* *pointer);
+ void (QOPENGLF_APIENTRYP ColorPointervINTEL)(GLint size, GLenum type, const GLvoid* *pointer);
+ void (QOPENGLF_APIENTRYP NormalPointervINTEL)(GLenum type, const GLvoid* *pointer);
+ void (QOPENGLF_APIENTRYP VertexPointervINTEL)(GLint size, GLenum type, const GLvoid* *pointer);
+};
+
+class QOpenGLExtension_INTEL_parallel_arrays : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_INTEL_parallel_arrays();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexCoordPointervINTEL(GLint size, GLenum type, const GLvoid* *pointer);
+ void glColorPointervINTEL(GLint size, GLenum type, const GLvoid* *pointer);
+ void glNormalPointervINTEL(GLenum type, const GLvoid* *pointer);
+ void glVertexPointervINTEL(GLint size, GLenum type, const GLvoid* *pointer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_INTEL_parallel_arrays)
+};
+
+inline void QOpenGLExtension_INTEL_parallel_arrays::glTexCoordPointervINTEL(GLint size, GLenum type, const GLvoid* *pointer)
+{
+ Q_D(QOpenGLExtension_INTEL_parallel_arrays);
+ d->TexCoordPointervINTEL(size, type, pointer);
+}
+
+inline void QOpenGLExtension_INTEL_parallel_arrays::glColorPointervINTEL(GLint size, GLenum type, const GLvoid* *pointer)
+{
+ Q_D(QOpenGLExtension_INTEL_parallel_arrays);
+ d->ColorPointervINTEL(size, type, pointer);
+}
+
+inline void QOpenGLExtension_INTEL_parallel_arrays::glNormalPointervINTEL(GLenum type, const GLvoid* *pointer)
+{
+ Q_D(QOpenGLExtension_INTEL_parallel_arrays);
+ d->NormalPointervINTEL(type, pointer);
+}
+
+inline void QOpenGLExtension_INTEL_parallel_arrays::glVertexPointervINTEL(GLint size, GLenum type, const GLvoid* *pointer)
+{
+ Q_D(QOpenGLExtension_INTEL_parallel_arrays);
+ d->VertexPointervINTEL(size, type, pointer);
+}
+
+class QOpenGLExtension_KHR_debugPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetObjectPtrLabel)(const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label);
+ void (QOPENGLF_APIENTRYP ObjectPtrLabel)(const void *ptr, GLsizei length, const GLchar *label);
+ void (QOPENGLF_APIENTRYP GetObjectLabel)(GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label);
+ void (QOPENGLF_APIENTRYP ObjectLabel)(GLenum identifier, GLuint name, GLsizei length, const GLchar *label);
+ void (QOPENGLF_APIENTRYP PopDebugGroup)();
+ void (QOPENGLF_APIENTRYP PushDebugGroup)(GLenum source, GLuint id, GLsizei length, const GLchar *message);
+ GLuint (QOPENGLF_APIENTRYP GetDebugMessageLog)(GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog);
+ void (QOPENGLF_APIENTRYP DebugMessageCallback)(GLDEBUGPROC callback, const void *userParam);
+ void (QOPENGLF_APIENTRYP DebugMessageInsert)(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf);
+ void (QOPENGLF_APIENTRYP DebugMessageControl)(GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
+};
+
+class QOpenGLExtension_KHR_debug : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_KHR_debug();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetObjectPtrLabel(const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label);
+ void glObjectPtrLabel(const void *ptr, GLsizei length, const GLchar *label);
+ void glGetObjectLabel(GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label);
+ void glObjectLabel(GLenum identifier, GLuint name, GLsizei length, const GLchar *label);
+ void glPopDebugGroup();
+ void glPushDebugGroup(GLenum source, GLuint id, GLsizei length, const GLchar *message);
+ GLuint glGetDebugMessageLog(GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog);
+ void glDebugMessageCallback(GLDEBUGPROC callback, const void *userParam);
+ void glDebugMessageInsert(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf);
+ void glDebugMessageControl(GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_KHR_debug)
+};
+
+inline void QOpenGLExtension_KHR_debug::glGetObjectPtrLabel(const void *ptr, GLsizei bufSize, GLsizei *length, GLchar *label)
+{
+ Q_D(QOpenGLExtension_KHR_debug);
+ d->GetObjectPtrLabel(ptr, bufSize, length, label);
+}
+
+inline void QOpenGLExtension_KHR_debug::glObjectPtrLabel(const void *ptr, GLsizei length, const GLchar *label)
+{
+ Q_D(QOpenGLExtension_KHR_debug);
+ d->ObjectPtrLabel(ptr, length, label);
+}
+
+inline void QOpenGLExtension_KHR_debug::glGetObjectLabel(GLenum identifier, GLuint name, GLsizei bufSize, GLsizei *length, GLchar *label)
+{
+ Q_D(QOpenGLExtension_KHR_debug);
+ d->GetObjectLabel(identifier, name, bufSize, length, label);
+}
+
+inline void QOpenGLExtension_KHR_debug::glObjectLabel(GLenum identifier, GLuint name, GLsizei length, const GLchar *label)
+{
+ Q_D(QOpenGLExtension_KHR_debug);
+ d->ObjectLabel(identifier, name, length, label);
+}
+
+inline void QOpenGLExtension_KHR_debug::glPopDebugGroup()
+{
+ Q_D(QOpenGLExtension_KHR_debug);
+ d->PopDebugGroup();
+}
+
+inline void QOpenGLExtension_KHR_debug::glPushDebugGroup(GLenum source, GLuint id, GLsizei length, const GLchar *message)
+{
+ Q_D(QOpenGLExtension_KHR_debug);
+ d->PushDebugGroup(source, id, length, message);
+}
+
+inline GLuint QOpenGLExtension_KHR_debug::glGetDebugMessageLog(GLuint count, GLsizei bufsize, GLenum *sources, GLenum *types, GLuint *ids, GLenum *severities, GLsizei *lengths, GLchar *messageLog)
+{
+ Q_D(QOpenGLExtension_KHR_debug);
+ return d->GetDebugMessageLog(count, bufsize, sources, types, ids, severities, lengths, messageLog);
+}
+
+inline void QOpenGLExtension_KHR_debug::glDebugMessageCallback(GLDEBUGPROC callback, const void *userParam)
+{
+ Q_D(QOpenGLExtension_KHR_debug);
+ d->DebugMessageCallback(callback, userParam);
+}
+
+inline void QOpenGLExtension_KHR_debug::glDebugMessageInsert(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar *buf)
+{
+ Q_D(QOpenGLExtension_KHR_debug);
+ d->DebugMessageInsert(source, type, id, severity, length, buf);
+}
+
+inline void QOpenGLExtension_KHR_debug::glDebugMessageControl(GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint *ids, GLboolean enabled)
+{
+ Q_D(QOpenGLExtension_KHR_debug);
+ d->DebugMessageControl(source, type, severity, count, ids, enabled);
+}
+
+class QOpenGLExtension_MESA_resize_buffersPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ResizeBuffersMESA)();
+};
+
+class QOpenGLExtension_MESA_resize_buffers : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_MESA_resize_buffers();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glResizeBuffersMESA();
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_MESA_resize_buffers)
+};
+
+inline void QOpenGLExtension_MESA_resize_buffers::glResizeBuffersMESA()
+{
+ Q_D(QOpenGLExtension_MESA_resize_buffers);
+ d->ResizeBuffersMESA();
+}
+
+class QOpenGLExtension_MESA_window_posPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP WindowPos4svMESA)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP WindowPos4sMESA)(GLshort x, GLshort y, GLshort z, GLshort w);
+ void (QOPENGLF_APIENTRYP WindowPos4ivMESA)(const GLint *v);
+ void (QOPENGLF_APIENTRYP WindowPos4iMESA)(GLint x, GLint y, GLint z, GLint w);
+ void (QOPENGLF_APIENTRYP WindowPos4fvMESA)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP WindowPos4fMESA)(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP WindowPos4dvMESA)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP WindowPos4dMESA)(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP WindowPos3svMESA)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP WindowPos3sMESA)(GLshort x, GLshort y, GLshort z);
+ void (QOPENGLF_APIENTRYP WindowPos3ivMESA)(const GLint *v);
+ void (QOPENGLF_APIENTRYP WindowPos3iMESA)(GLint x, GLint y, GLint z);
+ void (QOPENGLF_APIENTRYP WindowPos3fvMESA)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP WindowPos3fMESA)(GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP WindowPos3dvMESA)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP WindowPos3dMESA)(GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP WindowPos2svMESA)(const GLshort *v);
+ void (QOPENGLF_APIENTRYP WindowPos2sMESA)(GLshort x, GLshort y);
+ void (QOPENGLF_APIENTRYP WindowPos2ivMESA)(const GLint *v);
+ void (QOPENGLF_APIENTRYP WindowPos2iMESA)(GLint x, GLint y);
+ void (QOPENGLF_APIENTRYP WindowPos2fvMESA)(const GLfloat *v);
+ void (QOPENGLF_APIENTRYP WindowPos2fMESA)(GLfloat x, GLfloat y);
+ void (QOPENGLF_APIENTRYP WindowPos2dvMESA)(const GLdouble *v);
+ void (QOPENGLF_APIENTRYP WindowPos2dMESA)(GLdouble x, GLdouble y);
+};
+
+class QOpenGLExtension_MESA_window_pos : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_MESA_window_pos();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glWindowPos4svMESA(const GLshort *v);
+ void glWindowPos4sMESA(GLshort x, GLshort y, GLshort z, GLshort w);
+ void glWindowPos4ivMESA(const GLint *v);
+ void glWindowPos4iMESA(GLint x, GLint y, GLint z, GLint w);
+ void glWindowPos4fvMESA(const GLfloat *v);
+ void glWindowPos4fMESA(GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glWindowPos4dvMESA(const GLdouble *v);
+ void glWindowPos4dMESA(GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glWindowPos3svMESA(const GLshort *v);
+ void glWindowPos3sMESA(GLshort x, GLshort y, GLshort z);
+ void glWindowPos3ivMESA(const GLint *v);
+ void glWindowPos3iMESA(GLint x, GLint y, GLint z);
+ void glWindowPos3fvMESA(const GLfloat *v);
+ void glWindowPos3fMESA(GLfloat x, GLfloat y, GLfloat z);
+ void glWindowPos3dvMESA(const GLdouble *v);
+ void glWindowPos3dMESA(GLdouble x, GLdouble y, GLdouble z);
+ void glWindowPos2svMESA(const GLshort *v);
+ void glWindowPos2sMESA(GLshort x, GLshort y);
+ void glWindowPos2ivMESA(const GLint *v);
+ void glWindowPos2iMESA(GLint x, GLint y);
+ void glWindowPos2fvMESA(const GLfloat *v);
+ void glWindowPos2fMESA(GLfloat x, GLfloat y);
+ void glWindowPos2dvMESA(const GLdouble *v);
+ void glWindowPos2dMESA(GLdouble x, GLdouble y);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_MESA_window_pos)
+};
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos4svMESA(const GLshort *v)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos4svMESA(v);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos4sMESA(GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos4sMESA(x, y, z, w);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos4ivMESA(const GLint *v)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos4ivMESA(v);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos4iMESA(GLint x, GLint y, GLint z, GLint w)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos4iMESA(x, y, z, w);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos4fvMESA(const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos4fvMESA(v);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos4fMESA(GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos4fMESA(x, y, z, w);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos4dvMESA(const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos4dvMESA(v);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos4dMESA(GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos4dMESA(x, y, z, w);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos3svMESA(const GLshort *v)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos3svMESA(v);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos3sMESA(GLshort x, GLshort y, GLshort z)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos3sMESA(x, y, z);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos3ivMESA(const GLint *v)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos3ivMESA(v);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos3iMESA(GLint x, GLint y, GLint z)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos3iMESA(x, y, z);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos3fvMESA(const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos3fvMESA(v);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos3fMESA(GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos3fMESA(x, y, z);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos3dvMESA(const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos3dvMESA(v);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos3dMESA(GLdouble x, GLdouble y, GLdouble z)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos3dMESA(x, y, z);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos2svMESA(const GLshort *v)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos2svMESA(v);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos2sMESA(GLshort x, GLshort y)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos2sMESA(x, y);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos2ivMESA(const GLint *v)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos2ivMESA(v);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos2iMESA(GLint x, GLint y)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos2iMESA(x, y);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos2fvMESA(const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos2fvMESA(v);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos2fMESA(GLfloat x, GLfloat y)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos2fMESA(x, y);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos2dvMESA(const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos2dvMESA(v);
+}
+
+inline void QOpenGLExtension_MESA_window_pos::glWindowPos2dMESA(GLdouble x, GLdouble y)
+{
+ Q_D(QOpenGLExtension_MESA_window_pos);
+ d->WindowPos2dMESA(x, y);
+}
+
+class QOpenGLExtension_NV_bindless_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLboolean (QOPENGLF_APIENTRYP IsImageHandleResidentNV)(GLuint64 handle);
+ GLboolean (QOPENGLF_APIENTRYP IsTextureHandleResidentNV)(GLuint64 handle);
+ void (QOPENGLF_APIENTRYP ProgramUniformHandleui64vNV)(GLuint program, GLint location, GLsizei count, const GLuint64 *values);
+ void (QOPENGLF_APIENTRYP ProgramUniformHandleui64NV)(GLuint program, GLint location, GLuint64 value);
+ void (QOPENGLF_APIENTRYP UniformHandleui64vNV)(GLint location, GLsizei count, const GLuint64 *value);
+ void (QOPENGLF_APIENTRYP UniformHandleui64NV)(GLint location, GLuint64 value);
+ void (QOPENGLF_APIENTRYP MakeImageHandleNonResidentNV)(GLuint64 handle);
+ void (QOPENGLF_APIENTRYP MakeImageHandleResidentNV)(GLuint64 handle, GLenum access);
+ GLuint64 (QOPENGLF_APIENTRYP GetImageHandleNV)(GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum format);
+ void (QOPENGLF_APIENTRYP MakeTextureHandleNonResidentNV)(GLuint64 handle);
+ void (QOPENGLF_APIENTRYP MakeTextureHandleResidentNV)(GLuint64 handle);
+ GLuint64 (QOPENGLF_APIENTRYP GetTextureSamplerHandleNV)(GLuint texture, GLuint sampler);
+ GLuint64 (QOPENGLF_APIENTRYP GetTextureHandleNV)(GLuint texture);
+};
+
+class QOpenGLExtension_NV_bindless_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_bindless_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLboolean glIsImageHandleResidentNV(GLuint64 handle);
+ GLboolean glIsTextureHandleResidentNV(GLuint64 handle);
+ void glProgramUniformHandleui64vNV(GLuint program, GLint location, GLsizei count, const GLuint64 *values);
+ void glProgramUniformHandleui64NV(GLuint program, GLint location, GLuint64 value);
+ void glUniformHandleui64vNV(GLint location, GLsizei count, const GLuint64 *value);
+ void glUniformHandleui64NV(GLint location, GLuint64 value);
+ void glMakeImageHandleNonResidentNV(GLuint64 handle);
+ void glMakeImageHandleResidentNV(GLuint64 handle, GLenum access);
+ GLuint64 glGetImageHandleNV(GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum format);
+ void glMakeTextureHandleNonResidentNV(GLuint64 handle);
+ void glMakeTextureHandleResidentNV(GLuint64 handle);
+ GLuint64 glGetTextureSamplerHandleNV(GLuint texture, GLuint sampler);
+ GLuint64 glGetTextureHandleNV(GLuint texture);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_bindless_texture)
+};
+
+inline GLboolean QOpenGLExtension_NV_bindless_texture::glIsImageHandleResidentNV(GLuint64 handle)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ return d->IsImageHandleResidentNV(handle);
+}
+
+inline GLboolean QOpenGLExtension_NV_bindless_texture::glIsTextureHandleResidentNV(GLuint64 handle)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ return d->IsTextureHandleResidentNV(handle);
+}
+
+inline void QOpenGLExtension_NV_bindless_texture::glProgramUniformHandleui64vNV(GLuint program, GLint location, GLsizei count, const GLuint64 *values)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ d->ProgramUniformHandleui64vNV(program, location, count, values);
+}
+
+inline void QOpenGLExtension_NV_bindless_texture::glProgramUniformHandleui64NV(GLuint program, GLint location, GLuint64 value)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ d->ProgramUniformHandleui64NV(program, location, value);
+}
+
+inline void QOpenGLExtension_NV_bindless_texture::glUniformHandleui64vNV(GLint location, GLsizei count, const GLuint64 *value)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ d->UniformHandleui64vNV(location, count, value);
+}
+
+inline void QOpenGLExtension_NV_bindless_texture::glUniformHandleui64NV(GLint location, GLuint64 value)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ d->UniformHandleui64NV(location, value);
+}
+
+inline void QOpenGLExtension_NV_bindless_texture::glMakeImageHandleNonResidentNV(GLuint64 handle)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ d->MakeImageHandleNonResidentNV(handle);
+}
+
+inline void QOpenGLExtension_NV_bindless_texture::glMakeImageHandleResidentNV(GLuint64 handle, GLenum access)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ d->MakeImageHandleResidentNV(handle, access);
+}
+
+inline GLuint64 QOpenGLExtension_NV_bindless_texture::glGetImageHandleNV(GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum format)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ return d->GetImageHandleNV(texture, level, layered, layer, format);
+}
+
+inline void QOpenGLExtension_NV_bindless_texture::glMakeTextureHandleNonResidentNV(GLuint64 handle)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ d->MakeTextureHandleNonResidentNV(handle);
+}
+
+inline void QOpenGLExtension_NV_bindless_texture::glMakeTextureHandleResidentNV(GLuint64 handle)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ d->MakeTextureHandleResidentNV(handle);
+}
+
+inline GLuint64 QOpenGLExtension_NV_bindless_texture::glGetTextureSamplerHandleNV(GLuint texture, GLuint sampler)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ return d->GetTextureSamplerHandleNV(texture, sampler);
+}
+
+inline GLuint64 QOpenGLExtension_NV_bindless_texture::glGetTextureHandleNV(GLuint texture)
+{
+ Q_D(QOpenGLExtension_NV_bindless_texture);
+ return d->GetTextureHandleNV(texture);
+}
+
+class QOpenGLExtension_NV_conditional_renderPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP EndConditionalRenderNV)();
+ void (QOPENGLF_APIENTRYP BeginConditionalRenderNV)(GLuint id, GLenum mode);
+};
+
+class QOpenGLExtension_NV_conditional_render : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_conditional_render();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glEndConditionalRenderNV();
+ void glBeginConditionalRenderNV(GLuint id, GLenum mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_conditional_render)
+};
+
+inline void QOpenGLExtension_NV_conditional_render::glEndConditionalRenderNV()
+{
+ Q_D(QOpenGLExtension_NV_conditional_render);
+ d->EndConditionalRenderNV();
+}
+
+inline void QOpenGLExtension_NV_conditional_render::glBeginConditionalRenderNV(GLuint id, GLenum mode)
+{
+ Q_D(QOpenGLExtension_NV_conditional_render);
+ d->BeginConditionalRenderNV(id, mode);
+}
+
+class QOpenGLExtension_NV_copy_imagePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP CopyImageSubDataNV)(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 width, GLsizei height, GLsizei depth);
+};
+
+class QOpenGLExtension_NV_copy_image : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_copy_image();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glCopyImageSubDataNV(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 width, GLsizei height, GLsizei depth);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_copy_image)
+};
+
+inline void QOpenGLExtension_NV_copy_image::glCopyImageSubDataNV(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 width, GLsizei height, GLsizei depth)
+{
+ Q_D(QOpenGLExtension_NV_copy_image);
+ d->CopyImageSubDataNV(srcName, srcTarget, srcLevel, srcX, srcY, srcZ, dstName, dstTarget, dstLevel, dstX, dstY, dstZ, width, height, depth);
+}
+
+class QOpenGLExtension_NV_depth_buffer_floatPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DepthBoundsdNV)(GLdouble zmin, GLdouble zmax);
+ void (QOPENGLF_APIENTRYP ClearDepthdNV)(GLdouble depth);
+ void (QOPENGLF_APIENTRYP DepthRangedNV)(GLdouble zNear, GLdouble zFar);
+};
+
+class QOpenGLExtension_NV_depth_buffer_float : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_depth_buffer_float();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDepthBoundsdNV(GLdouble zmin, GLdouble zmax);
+ void glClearDepthdNV(GLdouble depth);
+ void glDepthRangedNV(GLdouble zNear, GLdouble zFar);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_depth_buffer_float)
+};
+
+inline void QOpenGLExtension_NV_depth_buffer_float::glDepthBoundsdNV(GLdouble zmin, GLdouble zmax)
+{
+ Q_D(QOpenGLExtension_NV_depth_buffer_float);
+ d->DepthBoundsdNV(zmin, zmax);
+}
+
+inline void QOpenGLExtension_NV_depth_buffer_float::glClearDepthdNV(GLdouble depth)
+{
+ Q_D(QOpenGLExtension_NV_depth_buffer_float);
+ d->ClearDepthdNV(depth);
+}
+
+inline void QOpenGLExtension_NV_depth_buffer_float::glDepthRangedNV(GLdouble zNear, GLdouble zFar)
+{
+ Q_D(QOpenGLExtension_NV_depth_buffer_float);
+ d->DepthRangedNV(zNear, zFar);
+}
+
+class QOpenGLExtension_NV_evaluatorsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP EvalMapsNV)(GLenum target, GLenum mode);
+ void (QOPENGLF_APIENTRYP GetMapAttribParameterfvNV)(GLenum target, GLuint index, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetMapAttribParameterivNV)(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetMapParameterfvNV)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetMapParameterivNV)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetMapControlPointsNV)(GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLboolean packed, GLvoid *points);
+ void (QOPENGLF_APIENTRYP MapParameterfvNV)(GLenum target, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP MapParameterivNV)(GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP MapControlPointsNV)(GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLint uorder, GLint vorder, GLboolean packed, const GLvoid *points);
+};
+
+class QOpenGLExtension_NV_evaluators : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_evaluators();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glEvalMapsNV(GLenum target, GLenum mode);
+ void glGetMapAttribParameterfvNV(GLenum target, GLuint index, GLenum pname, GLfloat *params);
+ void glGetMapAttribParameterivNV(GLenum target, GLuint index, GLenum pname, GLint *params);
+ void glGetMapParameterfvNV(GLenum target, GLenum pname, GLfloat *params);
+ void glGetMapParameterivNV(GLenum target, GLenum pname, GLint *params);
+ void glGetMapControlPointsNV(GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLboolean packed, GLvoid *points);
+ void glMapParameterfvNV(GLenum target, GLenum pname, const GLfloat *params);
+ void glMapParameterivNV(GLenum target, GLenum pname, const GLint *params);
+ void glMapControlPointsNV(GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLint uorder, GLint vorder, GLboolean packed, const GLvoid *points);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_evaluators)
+};
+
+inline void QOpenGLExtension_NV_evaluators::glEvalMapsNV(GLenum target, GLenum mode)
+{
+ Q_D(QOpenGLExtension_NV_evaluators);
+ d->EvalMapsNV(target, mode);
+}
+
+inline void QOpenGLExtension_NV_evaluators::glGetMapAttribParameterfvNV(GLenum target, GLuint index, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_evaluators);
+ d->GetMapAttribParameterfvNV(target, index, pname, params);
+}
+
+inline void QOpenGLExtension_NV_evaluators::glGetMapAttribParameterivNV(GLenum target, GLuint index, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_evaluators);
+ d->GetMapAttribParameterivNV(target, index, pname, params);
+}
+
+inline void QOpenGLExtension_NV_evaluators::glGetMapParameterfvNV(GLenum target, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_evaluators);
+ d->GetMapParameterfvNV(target, pname, params);
+}
+
+inline void QOpenGLExtension_NV_evaluators::glGetMapParameterivNV(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_evaluators);
+ d->GetMapParameterivNV(target, pname, params);
+}
+
+inline void QOpenGLExtension_NV_evaluators::glGetMapControlPointsNV(GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLboolean packed, GLvoid *points)
+{
+ Q_D(QOpenGLExtension_NV_evaluators);
+ d->GetMapControlPointsNV(target, index, type, ustride, vstride, packed, points);
+}
+
+inline void QOpenGLExtension_NV_evaluators::glMapParameterfvNV(GLenum target, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_evaluators);
+ d->MapParameterfvNV(target, pname, params);
+}
+
+inline void QOpenGLExtension_NV_evaluators::glMapParameterivNV(GLenum target, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_evaluators);
+ d->MapParameterivNV(target, pname, params);
+}
+
+inline void QOpenGLExtension_NV_evaluators::glMapControlPointsNV(GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLint uorder, GLint vorder, GLboolean packed, const GLvoid *points)
+{
+ Q_D(QOpenGLExtension_NV_evaluators);
+ d->MapControlPointsNV(target, index, type, ustride, vstride, uorder, vorder, packed, points);
+}
+
+class QOpenGLExtension_NV_explicit_multisamplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexRenderbufferNV)(GLenum target, GLuint renderbuffer);
+ void (QOPENGLF_APIENTRYP SampleMaskIndexedNV)(GLuint index, GLbitfield mask);
+ void (QOPENGLF_APIENTRYP GetMultisamplefvNV)(GLenum pname, GLuint index, GLfloat *val);
+};
+
+class QOpenGLExtension_NV_explicit_multisample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_explicit_multisample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexRenderbufferNV(GLenum target, GLuint renderbuffer);
+ void glSampleMaskIndexedNV(GLuint index, GLbitfield mask);
+ void glGetMultisamplefvNV(GLenum pname, GLuint index, GLfloat *val);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_explicit_multisample)
+};
+
+inline void QOpenGLExtension_NV_explicit_multisample::glTexRenderbufferNV(GLenum target, GLuint renderbuffer)
+{
+ Q_D(QOpenGLExtension_NV_explicit_multisample);
+ d->TexRenderbufferNV(target, renderbuffer);
+}
+
+inline void QOpenGLExtension_NV_explicit_multisample::glSampleMaskIndexedNV(GLuint index, GLbitfield mask)
+{
+ Q_D(QOpenGLExtension_NV_explicit_multisample);
+ d->SampleMaskIndexedNV(index, mask);
+}
+
+inline void QOpenGLExtension_NV_explicit_multisample::glGetMultisamplefvNV(GLenum pname, GLuint index, GLfloat *val)
+{
+ Q_D(QOpenGLExtension_NV_explicit_multisample);
+ d->GetMultisamplefvNV(pname, index, val);
+}
+
+class QOpenGLExtension_NV_fencePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP SetFenceNV)(GLuint fence, GLenum condition);
+ void (QOPENGLF_APIENTRYP FinishFenceNV)(GLuint fence);
+ void (QOPENGLF_APIENTRYP GetFenceivNV)(GLuint fence, GLenum pname, GLint *params);
+ GLboolean (QOPENGLF_APIENTRYP TestFenceNV)(GLuint fence);
+ GLboolean (QOPENGLF_APIENTRYP IsFenceNV)(GLuint fence);
+ void (QOPENGLF_APIENTRYP GenFencesNV)(GLsizei n, GLuint *fences);
+ void (QOPENGLF_APIENTRYP DeleteFencesNV)(GLsizei n, const GLuint *fences);
+};
+
+class QOpenGLExtension_NV_fence : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_fence();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glSetFenceNV(GLuint fence, GLenum condition);
+ void glFinishFenceNV(GLuint fence);
+ void glGetFenceivNV(GLuint fence, GLenum pname, GLint *params);
+ GLboolean glTestFenceNV(GLuint fence);
+ GLboolean glIsFenceNV(GLuint fence);
+ void glGenFencesNV(GLsizei n, GLuint *fences);
+ void glDeleteFencesNV(GLsizei n, const GLuint *fences);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_fence)
+};
+
+inline void QOpenGLExtension_NV_fence::glSetFenceNV(GLuint fence, GLenum condition)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->SetFenceNV(fence, condition);
+}
+
+inline void QOpenGLExtension_NV_fence::glFinishFenceNV(GLuint fence)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->FinishFenceNV(fence);
+}
+
+inline void QOpenGLExtension_NV_fence::glGetFenceivNV(GLuint fence, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->GetFenceivNV(fence, pname, params);
+}
+
+inline GLboolean QOpenGLExtension_NV_fence::glTestFenceNV(GLuint fence)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ return d->TestFenceNV(fence);
+}
+
+inline GLboolean QOpenGLExtension_NV_fence::glIsFenceNV(GLuint fence)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ return d->IsFenceNV(fence);
+}
+
+inline void QOpenGLExtension_NV_fence::glGenFencesNV(GLsizei n, GLuint *fences)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->GenFencesNV(n, fences);
+}
+
+inline void QOpenGLExtension_NV_fence::glDeleteFencesNV(GLsizei n, const GLuint *fences)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->DeleteFencesNV(n, fences);
+}
+
+class QOpenGLExtension_NV_fragment_programPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetProgramNamedParameterdvNV)(GLuint id, GLsizei len, const GLubyte *name, GLdouble *params);
+ void (QOPENGLF_APIENTRYP GetProgramNamedParameterfvNV)(GLuint id, GLsizei len, const GLubyte *name, GLfloat *params);
+ void (QOPENGLF_APIENTRYP ProgramNamedParameter4dvNV)(GLuint id, GLsizei len, const GLubyte *name, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP ProgramNamedParameter4fvNV)(GLuint id, GLsizei len, const GLubyte *name, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ProgramNamedParameter4dNV)(GLuint id, GLsizei len, const GLubyte *name, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP ProgramNamedParameter4fNV)(GLuint id, GLsizei len, const GLubyte *name, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+};
+
+class QOpenGLExtension_NV_fragment_program : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_fragment_program();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetProgramNamedParameterdvNV(GLuint id, GLsizei len, const GLubyte *name, GLdouble *params);
+ void glGetProgramNamedParameterfvNV(GLuint id, GLsizei len, const GLubyte *name, GLfloat *params);
+ void glProgramNamedParameter4dvNV(GLuint id, GLsizei len, const GLubyte *name, const GLdouble *v);
+ void glProgramNamedParameter4fvNV(GLuint id, GLsizei len, const GLubyte *name, const GLfloat *v);
+ void glProgramNamedParameter4dNV(GLuint id, GLsizei len, const GLubyte *name, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glProgramNamedParameter4fNV(GLuint id, GLsizei len, const GLubyte *name, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_fragment_program)
+};
+
+inline void QOpenGLExtension_NV_fragment_program::glGetProgramNamedParameterdvNV(GLuint id, GLsizei len, const GLubyte *name, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_NV_fragment_program);
+ d->GetProgramNamedParameterdvNV(id, len, name, params);
+}
+
+inline void QOpenGLExtension_NV_fragment_program::glGetProgramNamedParameterfvNV(GLuint id, GLsizei len, const GLubyte *name, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_fragment_program);
+ d->GetProgramNamedParameterfvNV(id, len, name, params);
+}
+
+inline void QOpenGLExtension_NV_fragment_program::glProgramNamedParameter4dvNV(GLuint id, GLsizei len, const GLubyte *name, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_NV_fragment_program);
+ d->ProgramNamedParameter4dvNV(id, len, name, v);
+}
+
+inline void QOpenGLExtension_NV_fragment_program::glProgramNamedParameter4fvNV(GLuint id, GLsizei len, const GLubyte *name, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_NV_fragment_program);
+ d->ProgramNamedParameter4fvNV(id, len, name, v);
+}
+
+inline void QOpenGLExtension_NV_fragment_program::glProgramNamedParameter4dNV(GLuint id, GLsizei len, const GLubyte *name, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_NV_fragment_program);
+ d->ProgramNamedParameter4dNV(id, len, name, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_fragment_program::glProgramNamedParameter4fNV(GLuint id, GLsizei len, const GLubyte *name, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_NV_fragment_program);
+ d->ProgramNamedParameter4fNV(id, len, name, x, y, z, w);
+}
+
+class QOpenGLExtension_NV_framebuffer_multisample_coveragePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP RenderbufferStorageMultisampleCoverageNV)(GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLenum internalformat, GLsizei width, GLsizei height);
+};
+
+class QOpenGLExtension_NV_framebuffer_multisample_coverage : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_framebuffer_multisample_coverage();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glRenderbufferStorageMultisampleCoverageNV(GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLenum internalformat, GLsizei width, GLsizei height);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_framebuffer_multisample_coverage)
+};
+
+inline void QOpenGLExtension_NV_framebuffer_multisample_coverage::glRenderbufferStorageMultisampleCoverageNV(GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_NV_framebuffer_multisample_coverage);
+ d->RenderbufferStorageMultisampleCoverageNV(target, coverageSamples, colorSamples, internalformat, width, height);
+}
+
+class QOpenGLExtension_NV_geometry_program4Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP FramebufferTextureFaceEXT)(GLenum target, GLenum attachment, GLuint texture, GLint level, GLenum face);
+ void (QOPENGLF_APIENTRYP FramebufferTextureLayerEXT)(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void (QOPENGLF_APIENTRYP FramebufferTextureEXT)(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void (QOPENGLF_APIENTRYP ProgramVertexLimitNV)(GLenum target, GLint limit);
+};
+
+class QOpenGLExtension_NV_geometry_program4 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_geometry_program4();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glFramebufferTextureFaceEXT(GLenum target, GLenum attachment, GLuint texture, GLint level, GLenum face);
+ void glFramebufferTextureLayerEXT(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+ void glFramebufferTextureEXT(GLenum target, GLenum attachment, GLuint texture, GLint level);
+ void glProgramVertexLimitNV(GLenum target, GLint limit);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_geometry_program4)
+};
+
+inline void QOpenGLExtension_NV_geometry_program4::glFramebufferTextureFaceEXT(GLenum target, GLenum attachment, GLuint texture, GLint level, GLenum face)
+{
+ Q_D(QOpenGLExtension_NV_geometry_program4);
+ d->FramebufferTextureFaceEXT(target, attachment, texture, level, face);
+}
+
+inline void QOpenGLExtension_NV_geometry_program4::glFramebufferTextureLayerEXT(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ Q_D(QOpenGLExtension_NV_geometry_program4);
+ d->FramebufferTextureLayerEXT(target, attachment, texture, level, layer);
+}
+
+inline void QOpenGLExtension_NV_geometry_program4::glFramebufferTextureEXT(GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ Q_D(QOpenGLExtension_NV_geometry_program4);
+ d->FramebufferTextureEXT(target, attachment, texture, level);
+}
+
+inline void QOpenGLExtension_NV_geometry_program4::glProgramVertexLimitNV(GLenum target, GLint limit)
+{
+ Q_D(QOpenGLExtension_NV_geometry_program4);
+ d->ProgramVertexLimitNV(target, limit);
+}
+
+class QOpenGLExtension_NV_gpu_program4Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetProgramEnvParameterIuivNV)(GLenum target, GLuint index, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetProgramEnvParameterIivNV)(GLenum target, GLuint index, GLint *params);
+ void (QOPENGLF_APIENTRYP GetProgramLocalParameterIuivNV)(GLenum target, GLuint index, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetProgramLocalParameterIivNV)(GLenum target, GLuint index, GLint *params);
+ void (QOPENGLF_APIENTRYP ProgramEnvParametersI4uivNV)(GLenum target, GLuint index, GLsizei count, const GLuint *params);
+ void (QOPENGLF_APIENTRYP ProgramEnvParameterI4uivNV)(GLenum target, GLuint index, const GLuint *params);
+ void (QOPENGLF_APIENTRYP ProgramEnvParameterI4uiNV)(GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void (QOPENGLF_APIENTRYP ProgramEnvParametersI4ivNV)(GLenum target, GLuint index, GLsizei count, const GLint *params);
+ void (QOPENGLF_APIENTRYP ProgramEnvParameterI4ivNV)(GLenum target, GLuint index, const GLint *params);
+ void (QOPENGLF_APIENTRYP ProgramEnvParameterI4iNV)(GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void (QOPENGLF_APIENTRYP ProgramLocalParametersI4uivNV)(GLenum target, GLuint index, GLsizei count, const GLuint *params);
+ void (QOPENGLF_APIENTRYP ProgramLocalParameterI4uivNV)(GLenum target, GLuint index, const GLuint *params);
+ void (QOPENGLF_APIENTRYP ProgramLocalParameterI4uiNV)(GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void (QOPENGLF_APIENTRYP ProgramLocalParametersI4ivNV)(GLenum target, GLuint index, GLsizei count, const GLint *params);
+ void (QOPENGLF_APIENTRYP ProgramLocalParameterI4ivNV)(GLenum target, GLuint index, const GLint *params);
+ void (QOPENGLF_APIENTRYP ProgramLocalParameterI4iNV)(GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w);
+};
+
+class QOpenGLExtension_NV_gpu_program4 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_gpu_program4();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetProgramEnvParameterIuivNV(GLenum target, GLuint index, GLuint *params);
+ void glGetProgramEnvParameterIivNV(GLenum target, GLuint index, GLint *params);
+ void glGetProgramLocalParameterIuivNV(GLenum target, GLuint index, GLuint *params);
+ void glGetProgramLocalParameterIivNV(GLenum target, GLuint index, GLint *params);
+ void glProgramEnvParametersI4uivNV(GLenum target, GLuint index, GLsizei count, const GLuint *params);
+ void glProgramEnvParameterI4uivNV(GLenum target, GLuint index, const GLuint *params);
+ void glProgramEnvParameterI4uiNV(GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void glProgramEnvParametersI4ivNV(GLenum target, GLuint index, GLsizei count, const GLint *params);
+ void glProgramEnvParameterI4ivNV(GLenum target, GLuint index, const GLint *params);
+ void glProgramEnvParameterI4iNV(GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void glProgramLocalParametersI4uivNV(GLenum target, GLuint index, GLsizei count, const GLuint *params);
+ void glProgramLocalParameterI4uivNV(GLenum target, GLuint index, const GLuint *params);
+ void glProgramLocalParameterI4uiNV(GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void glProgramLocalParametersI4ivNV(GLenum target, GLuint index, GLsizei count, const GLint *params);
+ void glProgramLocalParameterI4ivNV(GLenum target, GLuint index, const GLint *params);
+ void glProgramLocalParameterI4iNV(GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_gpu_program4)
+};
+
+inline void QOpenGLExtension_NV_gpu_program4::glGetProgramEnvParameterIuivNV(GLenum target, GLuint index, GLuint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->GetProgramEnvParameterIuivNV(target, index, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glGetProgramEnvParameterIivNV(GLenum target, GLuint index, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->GetProgramEnvParameterIivNV(target, index, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glGetProgramLocalParameterIuivNV(GLenum target, GLuint index, GLuint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->GetProgramLocalParameterIuivNV(target, index, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glGetProgramLocalParameterIivNV(GLenum target, GLuint index, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->GetProgramLocalParameterIivNV(target, index, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glProgramEnvParametersI4uivNV(GLenum target, GLuint index, GLsizei count, const GLuint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->ProgramEnvParametersI4uivNV(target, index, count, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glProgramEnvParameterI4uivNV(GLenum target, GLuint index, const GLuint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->ProgramEnvParameterI4uivNV(target, index, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glProgramEnvParameterI4uiNV(GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->ProgramEnvParameterI4uiNV(target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glProgramEnvParametersI4ivNV(GLenum target, GLuint index, GLsizei count, const GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->ProgramEnvParametersI4ivNV(target, index, count, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glProgramEnvParameterI4ivNV(GLenum target, GLuint index, const GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->ProgramEnvParameterI4ivNV(target, index, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glProgramEnvParameterI4iNV(GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->ProgramEnvParameterI4iNV(target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glProgramLocalParametersI4uivNV(GLenum target, GLuint index, GLsizei count, const GLuint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->ProgramLocalParametersI4uivNV(target, index, count, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glProgramLocalParameterI4uivNV(GLenum target, GLuint index, const GLuint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->ProgramLocalParameterI4uivNV(target, index, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glProgramLocalParameterI4uiNV(GLenum target, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->ProgramLocalParameterI4uiNV(target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glProgramLocalParametersI4ivNV(GLenum target, GLuint index, GLsizei count, const GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->ProgramLocalParametersI4ivNV(target, index, count, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glProgramLocalParameterI4ivNV(GLenum target, GLuint index, const GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->ProgramLocalParameterI4ivNV(target, index, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_program4::glProgramLocalParameterI4iNV(GLenum target, GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program4);
+ d->ProgramLocalParameterI4iNV(target, index, x, y, z, w);
+}
+
+class QOpenGLExtension_NV_gpu_program5Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetProgramSubroutineParameteruivNV)(GLenum target, GLuint index, GLuint *param);
+ void (QOPENGLF_APIENTRYP ProgramSubroutineParametersuivNV)(GLenum target, GLsizei count, const GLuint *params);
+};
+
+class QOpenGLExtension_NV_gpu_program5 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_gpu_program5();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetProgramSubroutineParameteruivNV(GLenum target, GLuint index, GLuint *param);
+ void glProgramSubroutineParametersuivNV(GLenum target, GLsizei count, const GLuint *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_gpu_program5)
+};
+
+inline void QOpenGLExtension_NV_gpu_program5::glGetProgramSubroutineParameteruivNV(GLenum target, GLuint index, GLuint *param)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program5);
+ d->GetProgramSubroutineParameteruivNV(target, index, param);
+}
+
+inline void QOpenGLExtension_NV_gpu_program5::glProgramSubroutineParametersuivNV(GLenum target, GLsizei count, const GLuint *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_program5);
+ d->ProgramSubroutineParametersuivNV(target, count, params);
+}
+
+class QOpenGLExtension_NV_gpu_shader5Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ProgramUniform4ui64vNV)(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3ui64vNV)(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2ui64vNV)(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1ui64vNV)(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4ui64NV)(GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w);
+ void (QOPENGLF_APIENTRYP ProgramUniform3ui64NV)(GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z);
+ void (QOPENGLF_APIENTRYP ProgramUniform2ui64NV)(GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y);
+ void (QOPENGLF_APIENTRYP ProgramUniform1ui64NV)(GLuint program, GLint location, GLuint64EXT x);
+ void (QOPENGLF_APIENTRYP ProgramUniform4i64vNV)(GLuint program, GLint location, GLsizei count, const GLint64EXT *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3i64vNV)(GLuint program, GLint location, GLsizei count, const GLint64EXT *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2i64vNV)(GLuint program, GLint location, GLsizei count, const GLint64EXT *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1i64vNV)(GLuint program, GLint location, GLsizei count, const GLint64EXT *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4i64NV)(GLuint program, GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w);
+ void (QOPENGLF_APIENTRYP ProgramUniform3i64NV)(GLuint program, GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z);
+ void (QOPENGLF_APIENTRYP ProgramUniform2i64NV)(GLuint program, GLint location, GLint64EXT x, GLint64EXT y);
+ void (QOPENGLF_APIENTRYP ProgramUniform1i64NV)(GLuint program, GLint location, GLint64EXT x);
+ void (QOPENGLF_APIENTRYP GetUniformi64vNV)(GLuint program, GLint location, GLint64EXT *params);
+ void (QOPENGLF_APIENTRYP Uniform4ui64vNV)(GLint location, GLsizei count, const GLuint64EXT *value);
+ void (QOPENGLF_APIENTRYP Uniform3ui64vNV)(GLint location, GLsizei count, const GLuint64EXT *value);
+ void (QOPENGLF_APIENTRYP Uniform2ui64vNV)(GLint location, GLsizei count, const GLuint64EXT *value);
+ void (QOPENGLF_APIENTRYP Uniform1ui64vNV)(GLint location, GLsizei count, const GLuint64EXT *value);
+ void (QOPENGLF_APIENTRYP Uniform4ui64NV)(GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w);
+ void (QOPENGLF_APIENTRYP Uniform3ui64NV)(GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z);
+ void (QOPENGLF_APIENTRYP Uniform2ui64NV)(GLint location, GLuint64EXT x, GLuint64EXT y);
+ void (QOPENGLF_APIENTRYP Uniform1ui64NV)(GLint location, GLuint64EXT x);
+ void (QOPENGLF_APIENTRYP Uniform4i64vNV)(GLint location, GLsizei count, const GLint64EXT *value);
+ void (QOPENGLF_APIENTRYP Uniform3i64vNV)(GLint location, GLsizei count, const GLint64EXT *value);
+ void (QOPENGLF_APIENTRYP Uniform2i64vNV)(GLint location, GLsizei count, const GLint64EXT *value);
+ void (QOPENGLF_APIENTRYP Uniform1i64vNV)(GLint location, GLsizei count, const GLint64EXT *value);
+ void (QOPENGLF_APIENTRYP Uniform4i64NV)(GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w);
+ void (QOPENGLF_APIENTRYP Uniform3i64NV)(GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z);
+ void (QOPENGLF_APIENTRYP Uniform2i64NV)(GLint location, GLint64EXT x, GLint64EXT y);
+ void (QOPENGLF_APIENTRYP Uniform1i64NV)(GLint location, GLint64EXT x);
+};
+
+class QOpenGLExtension_NV_gpu_shader5 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_gpu_shader5();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glProgramUniform4ui64vNV(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value);
+ void glProgramUniform3ui64vNV(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value);
+ void glProgramUniform2ui64vNV(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value);
+ void glProgramUniform1ui64vNV(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value);
+ void glProgramUniform4ui64NV(GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w);
+ void glProgramUniform3ui64NV(GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z);
+ void glProgramUniform2ui64NV(GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y);
+ void glProgramUniform1ui64NV(GLuint program, GLint location, GLuint64EXT x);
+ void glProgramUniform4i64vNV(GLuint program, GLint location, GLsizei count, const GLint64EXT *value);
+ void glProgramUniform3i64vNV(GLuint program, GLint location, GLsizei count, const GLint64EXT *value);
+ void glProgramUniform2i64vNV(GLuint program, GLint location, GLsizei count, const GLint64EXT *value);
+ void glProgramUniform1i64vNV(GLuint program, GLint location, GLsizei count, const GLint64EXT *value);
+ void glProgramUniform4i64NV(GLuint program, GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w);
+ void glProgramUniform3i64NV(GLuint program, GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z);
+ void glProgramUniform2i64NV(GLuint program, GLint location, GLint64EXT x, GLint64EXT y);
+ void glProgramUniform1i64NV(GLuint program, GLint location, GLint64EXT x);
+ void glGetUniformi64vNV(GLuint program, GLint location, GLint64EXT *params);
+ void glUniform4ui64vNV(GLint location, GLsizei count, const GLuint64EXT *value);
+ void glUniform3ui64vNV(GLint location, GLsizei count, const GLuint64EXT *value);
+ void glUniform2ui64vNV(GLint location, GLsizei count, const GLuint64EXT *value);
+ void glUniform1ui64vNV(GLint location, GLsizei count, const GLuint64EXT *value);
+ void glUniform4ui64NV(GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w);
+ void glUniform3ui64NV(GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z);
+ void glUniform2ui64NV(GLint location, GLuint64EXT x, GLuint64EXT y);
+ void glUniform1ui64NV(GLint location, GLuint64EXT x);
+ void glUniform4i64vNV(GLint location, GLsizei count, const GLint64EXT *value);
+ void glUniform3i64vNV(GLint location, GLsizei count, const GLint64EXT *value);
+ void glUniform2i64vNV(GLint location, GLsizei count, const GLint64EXT *value);
+ void glUniform1i64vNV(GLint location, GLsizei count, const GLint64EXT *value);
+ void glUniform4i64NV(GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w);
+ void glUniform3i64NV(GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z);
+ void glUniform2i64NV(GLint location, GLint64EXT x, GLint64EXT y);
+ void glUniform1i64NV(GLint location, GLint64EXT x);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_gpu_shader5)
+};
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform4ui64vNV(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform4ui64vNV(program, location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform3ui64vNV(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform3ui64vNV(program, location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform2ui64vNV(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform2ui64vNV(program, location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform1ui64vNV(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform1ui64vNV(program, location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform4ui64NV(GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform4ui64NV(program, location, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform3ui64NV(GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform3ui64NV(program, location, x, y, z);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform2ui64NV(GLuint program, GLint location, GLuint64EXT x, GLuint64EXT y)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform2ui64NV(program, location, x, y);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform1ui64NV(GLuint program, GLint location, GLuint64EXT x)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform1ui64NV(program, location, x);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform4i64vNV(GLuint program, GLint location, GLsizei count, const GLint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform4i64vNV(program, location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform3i64vNV(GLuint program, GLint location, GLsizei count, const GLint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform3i64vNV(program, location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform2i64vNV(GLuint program, GLint location, GLsizei count, const GLint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform2i64vNV(program, location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform1i64vNV(GLuint program, GLint location, GLsizei count, const GLint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform1i64vNV(program, location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform4i64NV(GLuint program, GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform4i64NV(program, location, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform3i64NV(GLuint program, GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform3i64NV(program, location, x, y, z);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform2i64NV(GLuint program, GLint location, GLint64EXT x, GLint64EXT y)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform2i64NV(program, location, x, y);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glProgramUniform1i64NV(GLuint program, GLint location, GLint64EXT x)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->ProgramUniform1i64NV(program, location, x);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glGetUniformi64vNV(GLuint program, GLint location, GLint64EXT *params)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->GetUniformi64vNV(program, location, params);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform4ui64vNV(GLint location, GLsizei count, const GLuint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform4ui64vNV(location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform3ui64vNV(GLint location, GLsizei count, const GLuint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform3ui64vNV(location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform2ui64vNV(GLint location, GLsizei count, const GLuint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform2ui64vNV(location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform1ui64vNV(GLint location, GLsizei count, const GLuint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform1ui64vNV(location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform4ui64NV(GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform4ui64NV(location, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform3ui64NV(GLint location, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform3ui64NV(location, x, y, z);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform2ui64NV(GLint location, GLuint64EXT x, GLuint64EXT y)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform2ui64NV(location, x, y);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform1ui64NV(GLint location, GLuint64EXT x)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform1ui64NV(location, x);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform4i64vNV(GLint location, GLsizei count, const GLint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform4i64vNV(location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform3i64vNV(GLint location, GLsizei count, const GLint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform3i64vNV(location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform2i64vNV(GLint location, GLsizei count, const GLint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform2i64vNV(location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform1i64vNV(GLint location, GLsizei count, const GLint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform1i64vNV(location, count, value);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform4i64NV(GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform4i64NV(location, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform3i64NV(GLint location, GLint64EXT x, GLint64EXT y, GLint64EXT z)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform3i64NV(location, x, y, z);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform2i64NV(GLint location, GLint64EXT x, GLint64EXT y)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform2i64NV(location, x, y);
+}
+
+inline void QOpenGLExtension_NV_gpu_shader5::glUniform1i64NV(GLint location, GLint64EXT x)
+{
+ Q_D(QOpenGLExtension_NV_gpu_shader5);
+ d->Uniform1i64NV(location, x);
+}
+
+class QOpenGLExtension_NV_half_floatPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexAttribs4hvNV)(GLuint index, GLsizei n, const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs3hvNV)(GLuint index, GLsizei n, const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs2hvNV)(GLuint index, GLsizei n, const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs1hvNV)(GLuint index, GLsizei n, const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4hvNV)(GLuint index, const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4hNV)(GLuint index, GLhalfNV x, GLhalfNV y, GLhalfNV z, GLhalfNV w);
+ void (QOPENGLF_APIENTRYP VertexAttrib3hvNV)(GLuint index, const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib3hNV)(GLuint index, GLhalfNV x, GLhalfNV y, GLhalfNV z);
+ void (QOPENGLF_APIENTRYP VertexAttrib2hvNV)(GLuint index, const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib2hNV)(GLuint index, GLhalfNV x, GLhalfNV y);
+ void (QOPENGLF_APIENTRYP VertexAttrib1hvNV)(GLuint index, const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib1hNV)(GLuint index, GLhalfNV x);
+ void (QOPENGLF_APIENTRYP VertexWeighthvNV)(const GLhalfNV *weight);
+ void (QOPENGLF_APIENTRYP VertexWeighthNV)(GLhalfNV weight);
+ void (QOPENGLF_APIENTRYP SecondaryColor3hvNV)(const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP SecondaryColor3hNV)(GLhalfNV red, GLhalfNV green, GLhalfNV blue);
+ void (QOPENGLF_APIENTRYP FogCoordhvNV)(const GLhalfNV *fog);
+ void (QOPENGLF_APIENTRYP FogCoordhNV)(GLhalfNV fog);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4hvNV)(GLenum target, const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord4hNV)(GLenum target, GLhalfNV s, GLhalfNV t, GLhalfNV r, GLhalfNV q);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3hvNV)(GLenum target, const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord3hNV)(GLenum target, GLhalfNV s, GLhalfNV t, GLhalfNV r);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2hvNV)(GLenum target, const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord2hNV)(GLenum target, GLhalfNV s, GLhalfNV t);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1hvNV)(GLenum target, const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP MultiTexCoord1hNV)(GLenum target, GLhalfNV s);
+ void (QOPENGLF_APIENTRYP TexCoord4hvNV)(const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP TexCoord4hNV)(GLhalfNV s, GLhalfNV t, GLhalfNV r, GLhalfNV q);
+ void (QOPENGLF_APIENTRYP TexCoord3hvNV)(const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP TexCoord3hNV)(GLhalfNV s, GLhalfNV t, GLhalfNV r);
+ void (QOPENGLF_APIENTRYP TexCoord2hvNV)(const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP TexCoord2hNV)(GLhalfNV s, GLhalfNV t);
+ void (QOPENGLF_APIENTRYP TexCoord1hvNV)(const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP TexCoord1hNV)(GLhalfNV s);
+ void (QOPENGLF_APIENTRYP Color4hvNV)(const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP Color4hNV)(GLhalfNV red, GLhalfNV green, GLhalfNV blue, GLhalfNV alpha);
+ void (QOPENGLF_APIENTRYP Color3hvNV)(const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP Color3hNV)(GLhalfNV red, GLhalfNV green, GLhalfNV blue);
+ void (QOPENGLF_APIENTRYP Normal3hvNV)(const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP Normal3hNV)(GLhalfNV nx, GLhalfNV ny, GLhalfNV nz);
+ void (QOPENGLF_APIENTRYP Vertex4hvNV)(const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP Vertex4hNV)(GLhalfNV x, GLhalfNV y, GLhalfNV z, GLhalfNV w);
+ void (QOPENGLF_APIENTRYP Vertex3hvNV)(const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP Vertex3hNV)(GLhalfNV x, GLhalfNV y, GLhalfNV z);
+ void (QOPENGLF_APIENTRYP Vertex2hvNV)(const GLhalfNV *v);
+ void (QOPENGLF_APIENTRYP Vertex2hNV)(GLhalfNV x, GLhalfNV y);
+};
+
+class QOpenGLExtension_NV_half_float : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_half_float();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexAttribs4hvNV(GLuint index, GLsizei n, const GLhalfNV *v);
+ void glVertexAttribs3hvNV(GLuint index, GLsizei n, const GLhalfNV *v);
+ void glVertexAttribs2hvNV(GLuint index, GLsizei n, const GLhalfNV *v);
+ void glVertexAttribs1hvNV(GLuint index, GLsizei n, const GLhalfNV *v);
+ void glVertexAttrib4hvNV(GLuint index, const GLhalfNV *v);
+ void glVertexAttrib4hNV(GLuint index, GLhalfNV x, GLhalfNV y, GLhalfNV z, GLhalfNV w);
+ void glVertexAttrib3hvNV(GLuint index, const GLhalfNV *v);
+ void glVertexAttrib3hNV(GLuint index, GLhalfNV x, GLhalfNV y, GLhalfNV z);
+ void glVertexAttrib2hvNV(GLuint index, const GLhalfNV *v);
+ void glVertexAttrib2hNV(GLuint index, GLhalfNV x, GLhalfNV y);
+ void glVertexAttrib1hvNV(GLuint index, const GLhalfNV *v);
+ void glVertexAttrib1hNV(GLuint index, GLhalfNV x);
+ void glVertexWeighthvNV(const GLhalfNV *weight);
+ void glVertexWeighthNV(GLhalfNV weight);
+ void glSecondaryColor3hvNV(const GLhalfNV *v);
+ void glSecondaryColor3hNV(GLhalfNV red, GLhalfNV green, GLhalfNV blue);
+ void glFogCoordhvNV(const GLhalfNV *fog);
+ void glFogCoordhNV(GLhalfNV fog);
+ void glMultiTexCoord4hvNV(GLenum target, const GLhalfNV *v);
+ void glMultiTexCoord4hNV(GLenum target, GLhalfNV s, GLhalfNV t, GLhalfNV r, GLhalfNV q);
+ void glMultiTexCoord3hvNV(GLenum target, const GLhalfNV *v);
+ void glMultiTexCoord3hNV(GLenum target, GLhalfNV s, GLhalfNV t, GLhalfNV r);
+ void glMultiTexCoord2hvNV(GLenum target, const GLhalfNV *v);
+ void glMultiTexCoord2hNV(GLenum target, GLhalfNV s, GLhalfNV t);
+ void glMultiTexCoord1hvNV(GLenum target, const GLhalfNV *v);
+ void glMultiTexCoord1hNV(GLenum target, GLhalfNV s);
+ void glTexCoord4hvNV(const GLhalfNV *v);
+ void glTexCoord4hNV(GLhalfNV s, GLhalfNV t, GLhalfNV r, GLhalfNV q);
+ void glTexCoord3hvNV(const GLhalfNV *v);
+ void glTexCoord3hNV(GLhalfNV s, GLhalfNV t, GLhalfNV r);
+ void glTexCoord2hvNV(const GLhalfNV *v);
+ void glTexCoord2hNV(GLhalfNV s, GLhalfNV t);
+ void glTexCoord1hvNV(const GLhalfNV *v);
+ void glTexCoord1hNV(GLhalfNV s);
+ void glColor4hvNV(const GLhalfNV *v);
+ void glColor4hNV(GLhalfNV red, GLhalfNV green, GLhalfNV blue, GLhalfNV alpha);
+ void glColor3hvNV(const GLhalfNV *v);
+ void glColor3hNV(GLhalfNV red, GLhalfNV green, GLhalfNV blue);
+ void glNormal3hvNV(const GLhalfNV *v);
+ void glNormal3hNV(GLhalfNV nx, GLhalfNV ny, GLhalfNV nz);
+ void glVertex4hvNV(const GLhalfNV *v);
+ void glVertex4hNV(GLhalfNV x, GLhalfNV y, GLhalfNV z, GLhalfNV w);
+ void glVertex3hvNV(const GLhalfNV *v);
+ void glVertex3hNV(GLhalfNV x, GLhalfNV y, GLhalfNV z);
+ void glVertex2hvNV(const GLhalfNV *v);
+ void glVertex2hNV(GLhalfNV x, GLhalfNV y);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_half_float)
+};
+
+inline void QOpenGLExtension_NV_half_float::glVertexAttribs4hvNV(GLuint index, GLsizei n, const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexAttribs4hvNV(index, n, v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexAttribs3hvNV(GLuint index, GLsizei n, const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexAttribs3hvNV(index, n, v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexAttribs2hvNV(GLuint index, GLsizei n, const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexAttribs2hvNV(index, n, v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexAttribs1hvNV(GLuint index, GLsizei n, const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexAttribs1hvNV(index, n, v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexAttrib4hvNV(GLuint index, const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexAttrib4hvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexAttrib4hNV(GLuint index, GLhalfNV x, GLhalfNV y, GLhalfNV z, GLhalfNV w)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexAttrib4hNV(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexAttrib3hvNV(GLuint index, const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexAttrib3hvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexAttrib3hNV(GLuint index, GLhalfNV x, GLhalfNV y, GLhalfNV z)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexAttrib3hNV(index, x, y, z);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexAttrib2hvNV(GLuint index, const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexAttrib2hvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexAttrib2hNV(GLuint index, GLhalfNV x, GLhalfNV y)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexAttrib2hNV(index, x, y);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexAttrib1hvNV(GLuint index, const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexAttrib1hvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexAttrib1hNV(GLuint index, GLhalfNV x)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexAttrib1hNV(index, x);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexWeighthvNV(const GLhalfNV *weight)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexWeighthvNV(weight);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertexWeighthNV(GLhalfNV weight)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->VertexWeighthNV(weight);
+}
+
+inline void QOpenGLExtension_NV_half_float::glSecondaryColor3hvNV(const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->SecondaryColor3hvNV(v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glSecondaryColor3hNV(GLhalfNV red, GLhalfNV green, GLhalfNV blue)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->SecondaryColor3hNV(red, green, blue);
+}
+
+inline void QOpenGLExtension_NV_half_float::glFogCoordhvNV(const GLhalfNV *fog)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->FogCoordhvNV(fog);
+}
+
+inline void QOpenGLExtension_NV_half_float::glFogCoordhNV(GLhalfNV fog)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->FogCoordhNV(fog);
+}
+
+inline void QOpenGLExtension_NV_half_float::glMultiTexCoord4hvNV(GLenum target, const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->MultiTexCoord4hvNV(target, v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glMultiTexCoord4hNV(GLenum target, GLhalfNV s, GLhalfNV t, GLhalfNV r, GLhalfNV q)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->MultiTexCoord4hNV(target, s, t, r, q);
+}
+
+inline void QOpenGLExtension_NV_half_float::glMultiTexCoord3hvNV(GLenum target, const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->MultiTexCoord3hvNV(target, v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glMultiTexCoord3hNV(GLenum target, GLhalfNV s, GLhalfNV t, GLhalfNV r)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->MultiTexCoord3hNV(target, s, t, r);
+}
+
+inline void QOpenGLExtension_NV_half_float::glMultiTexCoord2hvNV(GLenum target, const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->MultiTexCoord2hvNV(target, v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glMultiTexCoord2hNV(GLenum target, GLhalfNV s, GLhalfNV t)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->MultiTexCoord2hNV(target, s, t);
+}
+
+inline void QOpenGLExtension_NV_half_float::glMultiTexCoord1hvNV(GLenum target, const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->MultiTexCoord1hvNV(target, v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glMultiTexCoord1hNV(GLenum target, GLhalfNV s)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->MultiTexCoord1hNV(target, s);
+}
+
+inline void QOpenGLExtension_NV_half_float::glTexCoord4hvNV(const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->TexCoord4hvNV(v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glTexCoord4hNV(GLhalfNV s, GLhalfNV t, GLhalfNV r, GLhalfNV q)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->TexCoord4hNV(s, t, r, q);
+}
+
+inline void QOpenGLExtension_NV_half_float::glTexCoord3hvNV(const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->TexCoord3hvNV(v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glTexCoord3hNV(GLhalfNV s, GLhalfNV t, GLhalfNV r)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->TexCoord3hNV(s, t, r);
+}
+
+inline void QOpenGLExtension_NV_half_float::glTexCoord2hvNV(const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->TexCoord2hvNV(v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glTexCoord2hNV(GLhalfNV s, GLhalfNV t)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->TexCoord2hNV(s, t);
+}
+
+inline void QOpenGLExtension_NV_half_float::glTexCoord1hvNV(const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->TexCoord1hvNV(v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glTexCoord1hNV(GLhalfNV s)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->TexCoord1hNV(s);
+}
+
+inline void QOpenGLExtension_NV_half_float::glColor4hvNV(const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->Color4hvNV(v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glColor4hNV(GLhalfNV red, GLhalfNV green, GLhalfNV blue, GLhalfNV alpha)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->Color4hNV(red, green, blue, alpha);
+}
+
+inline void QOpenGLExtension_NV_half_float::glColor3hvNV(const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->Color3hvNV(v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glColor3hNV(GLhalfNV red, GLhalfNV green, GLhalfNV blue)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->Color3hNV(red, green, blue);
+}
+
+inline void QOpenGLExtension_NV_half_float::glNormal3hvNV(const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->Normal3hvNV(v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glNormal3hNV(GLhalfNV nx, GLhalfNV ny, GLhalfNV nz)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->Normal3hNV(nx, ny, nz);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertex4hvNV(const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->Vertex4hvNV(v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertex4hNV(GLhalfNV x, GLhalfNV y, GLhalfNV z, GLhalfNV w)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->Vertex4hNV(x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertex3hvNV(const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->Vertex3hvNV(v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertex3hNV(GLhalfNV x, GLhalfNV y, GLhalfNV z)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->Vertex3hNV(x, y, z);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertex2hvNV(const GLhalfNV *v)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->Vertex2hvNV(v);
+}
+
+inline void QOpenGLExtension_NV_half_float::glVertex2hNV(GLhalfNV x, GLhalfNV y)
+{
+ Q_D(QOpenGLExtension_NV_half_float);
+ d->Vertex2hNV(x, y);
+}
+
+class QOpenGLExtension_NV_occlusion_queryPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetOcclusionQueryuivNV)(GLuint id, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetOcclusionQueryivNV)(GLuint id, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP EndOcclusionQueryNV)();
+ void (QOPENGLF_APIENTRYP BeginOcclusionQueryNV)(GLuint id);
+ GLboolean (QOPENGLF_APIENTRYP IsOcclusionQueryNV)(GLuint id);
+ void (QOPENGLF_APIENTRYP DeleteOcclusionQueriesNV)(GLsizei n, const GLuint *ids);
+ void (QOPENGLF_APIENTRYP GenOcclusionQueriesNV)(GLsizei n, GLuint *ids);
+};
+
+class QOpenGLExtension_NV_occlusion_query : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_occlusion_query();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetOcclusionQueryuivNV(GLuint id, GLenum pname, GLuint *params);
+ void glGetOcclusionQueryivNV(GLuint id, GLenum pname, GLint *params);
+ void glEndOcclusionQueryNV();
+ void glBeginOcclusionQueryNV(GLuint id);
+ GLboolean glIsOcclusionQueryNV(GLuint id);
+ void glDeleteOcclusionQueriesNV(GLsizei n, const GLuint *ids);
+ void glGenOcclusionQueriesNV(GLsizei n, GLuint *ids);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_occlusion_query)
+};
+
+inline void QOpenGLExtension_NV_occlusion_query::glGetOcclusionQueryuivNV(GLuint id, GLenum pname, GLuint *params)
+{
+ Q_D(QOpenGLExtension_NV_occlusion_query);
+ d->GetOcclusionQueryuivNV(id, pname, params);
+}
+
+inline void QOpenGLExtension_NV_occlusion_query::glGetOcclusionQueryivNV(GLuint id, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_occlusion_query);
+ d->GetOcclusionQueryivNV(id, pname, params);
+}
+
+inline void QOpenGLExtension_NV_occlusion_query::glEndOcclusionQueryNV()
+{
+ Q_D(QOpenGLExtension_NV_occlusion_query);
+ d->EndOcclusionQueryNV();
+}
+
+inline void QOpenGLExtension_NV_occlusion_query::glBeginOcclusionQueryNV(GLuint id)
+{
+ Q_D(QOpenGLExtension_NV_occlusion_query);
+ d->BeginOcclusionQueryNV(id);
+}
+
+inline GLboolean QOpenGLExtension_NV_occlusion_query::glIsOcclusionQueryNV(GLuint id)
+{
+ Q_D(QOpenGLExtension_NV_occlusion_query);
+ return d->IsOcclusionQueryNV(id);
+}
+
+inline void QOpenGLExtension_NV_occlusion_query::glDeleteOcclusionQueriesNV(GLsizei n, const GLuint *ids)
+{
+ Q_D(QOpenGLExtension_NV_occlusion_query);
+ d->DeleteOcclusionQueriesNV(n, ids);
+}
+
+inline void QOpenGLExtension_NV_occlusion_query::glGenOcclusionQueriesNV(GLsizei n, GLuint *ids)
+{
+ Q_D(QOpenGLExtension_NV_occlusion_query);
+ d->GenOcclusionQueriesNV(n, ids);
+}
+
+class QOpenGLExtension_NV_parameter_buffer_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ProgramBufferParametersIuivNV)(GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLuint *params);
+ void (QOPENGLF_APIENTRYP ProgramBufferParametersIivNV)(GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLint *params);
+ void (QOPENGLF_APIENTRYP ProgramBufferParametersfvNV)(GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLfloat *params);
+};
+
+class QOpenGLExtension_NV_parameter_buffer_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_parameter_buffer_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glProgramBufferParametersIuivNV(GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLuint *params);
+ void glProgramBufferParametersIivNV(GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLint *params);
+ void glProgramBufferParametersfvNV(GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLfloat *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_parameter_buffer_object)
+};
+
+inline void QOpenGLExtension_NV_parameter_buffer_object::glProgramBufferParametersIuivNV(GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLuint *params)
+{
+ Q_D(QOpenGLExtension_NV_parameter_buffer_object);
+ d->ProgramBufferParametersIuivNV(target, buffer, index, count, params);
+}
+
+inline void QOpenGLExtension_NV_parameter_buffer_object::glProgramBufferParametersIivNV(GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_parameter_buffer_object);
+ d->ProgramBufferParametersIivNV(target, buffer, index, count, params);
+}
+
+inline void QOpenGLExtension_NV_parameter_buffer_object::glProgramBufferParametersfvNV(GLenum target, GLuint buffer, GLuint index, GLsizei count, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_parameter_buffer_object);
+ d->ProgramBufferParametersfvNV(target, buffer, index, count, params);
+}
+
+class QOpenGLExtension_NV_path_renderingPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLboolean (QOPENGLF_APIENTRYP PointAlongPathNV)(GLuint path, GLsizei startSegment, GLsizei numSegments, GLfloat distance, GLfloat *x, GLfloat *y, GLfloat *tangentX, GLfloat *tangentY);
+ GLfloat (QOPENGLF_APIENTRYP GetPathLengthNV)(GLuint path, GLsizei startSegment, GLsizei numSegments);
+ GLboolean (QOPENGLF_APIENTRYP IsPointInStrokePathNV)(GLuint path, GLfloat x, GLfloat y);
+ GLboolean (QOPENGLF_APIENTRYP IsPointInFillPathNV)(GLuint path, GLuint mask, GLfloat x, GLfloat y);
+ void (QOPENGLF_APIENTRYP GetPathTexGenfvNV)(GLenum texCoordSet, GLenum pname, GLfloat *value);
+ void (QOPENGLF_APIENTRYP GetPathTexGenivNV)(GLenum texCoordSet, GLenum pname, GLint *value);
+ void (QOPENGLF_APIENTRYP GetPathColorGenfvNV)(GLenum color, GLenum pname, GLfloat *value);
+ void (QOPENGLF_APIENTRYP GetPathColorGenivNV)(GLenum color, GLenum pname, GLint *value);
+ void (QOPENGLF_APIENTRYP GetPathSpacingNV)(GLenum pathListMode, GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLfloat advanceScale, GLfloat kerningScale, GLenum transformType, GLfloat *returnedSpacing);
+ void (QOPENGLF_APIENTRYP GetPathMetricRangeNV)(GLbitfield metricQueryMask, GLuint firstPathName, GLsizei numPaths, GLsizei stride, GLfloat *metrics);
+ void (QOPENGLF_APIENTRYP GetPathMetricsNV)(GLbitfield metricQueryMask, GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLsizei stride, GLfloat *metrics);
+ void (QOPENGLF_APIENTRYP GetPathDashArrayNV)(GLuint path, GLfloat *dashArray);
+ void (QOPENGLF_APIENTRYP GetPathCoordsNV)(GLuint path, GLfloat *coords);
+ void (QOPENGLF_APIENTRYP GetPathCommandsNV)(GLuint path, GLubyte *commands);
+ void (QOPENGLF_APIENTRYP GetPathParameterfvNV)(GLuint path, GLenum pname, GLfloat *value);
+ void (QOPENGLF_APIENTRYP GetPathParameterivNV)(GLuint path, GLenum pname, GLint *value);
+ void (QOPENGLF_APIENTRYP CoverStrokePathInstancedNV)(GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLenum coverMode, GLenum transformType, const GLfloat *transformValues);
+ void (QOPENGLF_APIENTRYP CoverFillPathInstancedNV)(GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLenum coverMode, GLenum transformType, const GLfloat *transformValues);
+ void (QOPENGLF_APIENTRYP CoverStrokePathNV)(GLuint path, GLenum coverMode);
+ void (QOPENGLF_APIENTRYP CoverFillPathNV)(GLuint path, GLenum coverMode);
+ void (QOPENGLF_APIENTRYP PathFogGenNV)(GLenum genMode);
+ void (QOPENGLF_APIENTRYP PathTexGenNV)(GLenum texCoordSet, GLenum genMode, GLint components, const GLfloat *coeffs);
+ void (QOPENGLF_APIENTRYP PathColorGenNV)(GLenum color, GLenum genMode, GLenum colorFormat, const GLfloat *coeffs);
+ void (QOPENGLF_APIENTRYP PathCoverDepthFuncNV)(GLenum func);
+ void (QOPENGLF_APIENTRYP StencilStrokePathInstancedNV)(GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLint reference, GLuint mask, GLenum transformType, const GLfloat *transformValues);
+ void (QOPENGLF_APIENTRYP StencilFillPathInstancedNV)(GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLenum fillMode, GLuint mask, GLenum transformType, const GLfloat *transformValues);
+ void (QOPENGLF_APIENTRYP StencilStrokePathNV)(GLuint path, GLint reference, GLuint mask);
+ void (QOPENGLF_APIENTRYP StencilFillPathNV)(GLuint path, GLenum fillMode, GLuint mask);
+ void (QOPENGLF_APIENTRYP PathStencilDepthOffsetNV)(GLfloat factor, GLfloat units);
+ void (QOPENGLF_APIENTRYP PathStencilFuncNV)(GLenum func, GLint ref, GLuint mask);
+ void (QOPENGLF_APIENTRYP PathDashArrayNV)(GLuint path, GLsizei dashCount, const GLfloat *dashArray);
+ void (QOPENGLF_APIENTRYP PathParameterfNV)(GLuint path, GLenum pname, GLfloat value);
+ void (QOPENGLF_APIENTRYP PathParameterfvNV)(GLuint path, GLenum pname, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP PathParameteriNV)(GLuint path, GLenum pname, GLint value);
+ void (QOPENGLF_APIENTRYP PathParameterivNV)(GLuint path, GLenum pname, const GLint *value);
+ void (QOPENGLF_APIENTRYP TransformPathNV)(GLuint resultPath, GLuint srcPath, GLenum transformType, const GLfloat *transformValues);
+ void (QOPENGLF_APIENTRYP InterpolatePathsNV)(GLuint resultPath, GLuint pathA, GLuint pathB, GLfloat weight);
+ void (QOPENGLF_APIENTRYP CopyPathNV)(GLuint resultPath, GLuint srcPath);
+ void (QOPENGLF_APIENTRYP WeightPathsNV)(GLuint resultPath, GLsizei numPaths, const GLuint *paths, const GLfloat *weights);
+ void (QOPENGLF_APIENTRYP PathGlyphRangeNV)(GLuint firstPathName, GLenum fontTarget, const GLvoid *fontName, GLbitfield fontStyle, GLuint firstGlyph, GLsizei numGlyphs, GLenum handleMissingGlyphs, GLuint pathParameterTemplate, GLfloat emScale);
+ void (QOPENGLF_APIENTRYP PathGlyphsNV)(GLuint firstPathName, GLenum fontTarget, const GLvoid *fontName, GLbitfield fontStyle, GLsizei numGlyphs, GLenum type, const GLvoid *charcodes, GLenum handleMissingGlyphs, GLuint pathParameterTemplate, GLfloat emScale);
+ void (QOPENGLF_APIENTRYP PathStringNV)(GLuint path, GLenum format, GLsizei length, const GLvoid *pathString);
+ void (QOPENGLF_APIENTRYP PathSubCoordsNV)(GLuint path, GLsizei coordStart, GLsizei numCoords, GLenum coordType, const GLvoid *coords);
+ void (QOPENGLF_APIENTRYP PathSubCommandsNV)(GLuint path, GLsizei commandStart, GLsizei commandsToDelete, GLsizei numCommands, const GLubyte *commands, GLsizei numCoords, GLenum coordType, const GLvoid *coords);
+ void (QOPENGLF_APIENTRYP PathCoordsNV)(GLuint path, GLsizei numCoords, GLenum coordType, const GLvoid *coords);
+ void (QOPENGLF_APIENTRYP PathCommandsNV)(GLuint path, GLsizei numCommands, const GLubyte *commands, GLsizei numCoords, GLenum coordType, const GLvoid *coords);
+ GLboolean (QOPENGLF_APIENTRYP IsPathNV)(GLuint path);
+ void (QOPENGLF_APIENTRYP DeletePathsNV)(GLuint path, GLsizei range);
+ GLuint (QOPENGLF_APIENTRYP GenPathsNV)(GLsizei range);
+};
+
+class QOpenGLExtension_NV_path_rendering : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_path_rendering();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLboolean glPointAlongPathNV(GLuint path, GLsizei startSegment, GLsizei numSegments, GLfloat distance, GLfloat *x, GLfloat *y, GLfloat *tangentX, GLfloat *tangentY);
+ GLfloat glGetPathLengthNV(GLuint path, GLsizei startSegment, GLsizei numSegments);
+ GLboolean glIsPointInStrokePathNV(GLuint path, GLfloat x, GLfloat y);
+ GLboolean glIsPointInFillPathNV(GLuint path, GLuint mask, GLfloat x, GLfloat y);
+ void glGetPathTexGenfvNV(GLenum texCoordSet, GLenum pname, GLfloat *value);
+ void glGetPathTexGenivNV(GLenum texCoordSet, GLenum pname, GLint *value);
+ void glGetPathColorGenfvNV(GLenum color, GLenum pname, GLfloat *value);
+ void glGetPathColorGenivNV(GLenum color, GLenum pname, GLint *value);
+ void glGetPathSpacingNV(GLenum pathListMode, GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLfloat advanceScale, GLfloat kerningScale, GLenum transformType, GLfloat *returnedSpacing);
+ void glGetPathMetricRangeNV(GLbitfield metricQueryMask, GLuint firstPathName, GLsizei numPaths, GLsizei stride, GLfloat *metrics);
+ void glGetPathMetricsNV(GLbitfield metricQueryMask, GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLsizei stride, GLfloat *metrics);
+ void glGetPathDashArrayNV(GLuint path, GLfloat *dashArray);
+ void glGetPathCoordsNV(GLuint path, GLfloat *coords);
+ void glGetPathCommandsNV(GLuint path, GLubyte *commands);
+ void glGetPathParameterfvNV(GLuint path, GLenum pname, GLfloat *value);
+ void glGetPathParameterivNV(GLuint path, GLenum pname, GLint *value);
+ void glCoverStrokePathInstancedNV(GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLenum coverMode, GLenum transformType, const GLfloat *transformValues);
+ void glCoverFillPathInstancedNV(GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLenum coverMode, GLenum transformType, const GLfloat *transformValues);
+ void glCoverStrokePathNV(GLuint path, GLenum coverMode);
+ void glCoverFillPathNV(GLuint path, GLenum coverMode);
+ void glPathFogGenNV(GLenum genMode);
+ void glPathTexGenNV(GLenum texCoordSet, GLenum genMode, GLint components, const GLfloat *coeffs);
+ void glPathColorGenNV(GLenum color, GLenum genMode, GLenum colorFormat, const GLfloat *coeffs);
+ void glPathCoverDepthFuncNV(GLenum func);
+ void glStencilStrokePathInstancedNV(GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLint reference, GLuint mask, GLenum transformType, const GLfloat *transformValues);
+ void glStencilFillPathInstancedNV(GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLenum fillMode, GLuint mask, GLenum transformType, const GLfloat *transformValues);
+ void glStencilStrokePathNV(GLuint path, GLint reference, GLuint mask);
+ void glStencilFillPathNV(GLuint path, GLenum fillMode, GLuint mask);
+ void glPathStencilDepthOffsetNV(GLfloat factor, GLfloat units);
+ void glPathStencilFuncNV(GLenum func, GLint ref, GLuint mask);
+ void glPathDashArrayNV(GLuint path, GLsizei dashCount, const GLfloat *dashArray);
+ void glPathParameterfNV(GLuint path, GLenum pname, GLfloat value);
+ void glPathParameterfvNV(GLuint path, GLenum pname, const GLfloat *value);
+ void glPathParameteriNV(GLuint path, GLenum pname, GLint value);
+ void glPathParameterivNV(GLuint path, GLenum pname, const GLint *value);
+ void glTransformPathNV(GLuint resultPath, GLuint srcPath, GLenum transformType, const GLfloat *transformValues);
+ void glInterpolatePathsNV(GLuint resultPath, GLuint pathA, GLuint pathB, GLfloat weight);
+ void glCopyPathNV(GLuint resultPath, GLuint srcPath);
+ void glWeightPathsNV(GLuint resultPath, GLsizei numPaths, const GLuint *paths, const GLfloat *weights);
+ void glPathGlyphRangeNV(GLuint firstPathName, GLenum fontTarget, const GLvoid *fontName, GLbitfield fontStyle, GLuint firstGlyph, GLsizei numGlyphs, GLenum handleMissingGlyphs, GLuint pathParameterTemplate, GLfloat emScale);
+ void glPathGlyphsNV(GLuint firstPathName, GLenum fontTarget, const GLvoid *fontName, GLbitfield fontStyle, GLsizei numGlyphs, GLenum type, const GLvoid *charcodes, GLenum handleMissingGlyphs, GLuint pathParameterTemplate, GLfloat emScale);
+ void glPathStringNV(GLuint path, GLenum format, GLsizei length, const GLvoid *pathString);
+ void glPathSubCoordsNV(GLuint path, GLsizei coordStart, GLsizei numCoords, GLenum coordType, const GLvoid *coords);
+ void glPathSubCommandsNV(GLuint path, GLsizei commandStart, GLsizei commandsToDelete, GLsizei numCommands, const GLubyte *commands, GLsizei numCoords, GLenum coordType, const GLvoid *coords);
+ void glPathCoordsNV(GLuint path, GLsizei numCoords, GLenum coordType, const GLvoid *coords);
+ void glPathCommandsNV(GLuint path, GLsizei numCommands, const GLubyte *commands, GLsizei numCoords, GLenum coordType, const GLvoid *coords);
+ GLboolean glIsPathNV(GLuint path);
+ void glDeletePathsNV(GLuint path, GLsizei range);
+ GLuint glGenPathsNV(GLsizei range);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_path_rendering)
+};
+
+inline GLboolean QOpenGLExtension_NV_path_rendering::glPointAlongPathNV(GLuint path, GLsizei startSegment, GLsizei numSegments, GLfloat distance, GLfloat *x, GLfloat *y, GLfloat *tangentX, GLfloat *tangentY)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ return d->PointAlongPathNV(path, startSegment, numSegments, distance, x, y, tangentX, tangentY);
+}
+
+inline GLfloat QOpenGLExtension_NV_path_rendering::glGetPathLengthNV(GLuint path, GLsizei startSegment, GLsizei numSegments)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ return d->GetPathLengthNV(path, startSegment, numSegments);
+}
+
+inline GLboolean QOpenGLExtension_NV_path_rendering::glIsPointInStrokePathNV(GLuint path, GLfloat x, GLfloat y)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ return d->IsPointInStrokePathNV(path, x, y);
+}
+
+inline GLboolean QOpenGLExtension_NV_path_rendering::glIsPointInFillPathNV(GLuint path, GLuint mask, GLfloat x, GLfloat y)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ return d->IsPointInFillPathNV(path, mask, x, y);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glGetPathTexGenfvNV(GLenum texCoordSet, GLenum pname, GLfloat *value)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->GetPathTexGenfvNV(texCoordSet, pname, value);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glGetPathTexGenivNV(GLenum texCoordSet, GLenum pname, GLint *value)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->GetPathTexGenivNV(texCoordSet, pname, value);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glGetPathColorGenfvNV(GLenum color, GLenum pname, GLfloat *value)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->GetPathColorGenfvNV(color, pname, value);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glGetPathColorGenivNV(GLenum color, GLenum pname, GLint *value)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->GetPathColorGenivNV(color, pname, value);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glGetPathSpacingNV(GLenum pathListMode, GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLfloat advanceScale, GLfloat kerningScale, GLenum transformType, GLfloat *returnedSpacing)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->GetPathSpacingNV(pathListMode, numPaths, pathNameType, paths, pathBase, advanceScale, kerningScale, transformType, returnedSpacing);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glGetPathMetricRangeNV(GLbitfield metricQueryMask, GLuint firstPathName, GLsizei numPaths, GLsizei stride, GLfloat *metrics)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->GetPathMetricRangeNV(metricQueryMask, firstPathName, numPaths, stride, metrics);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glGetPathMetricsNV(GLbitfield metricQueryMask, GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLsizei stride, GLfloat *metrics)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->GetPathMetricsNV(metricQueryMask, numPaths, pathNameType, paths, pathBase, stride, metrics);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glGetPathDashArrayNV(GLuint path, GLfloat *dashArray)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->GetPathDashArrayNV(path, dashArray);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glGetPathCoordsNV(GLuint path, GLfloat *coords)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->GetPathCoordsNV(path, coords);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glGetPathCommandsNV(GLuint path, GLubyte *commands)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->GetPathCommandsNV(path, commands);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glGetPathParameterfvNV(GLuint path, GLenum pname, GLfloat *value)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->GetPathParameterfvNV(path, pname, value);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glGetPathParameterivNV(GLuint path, GLenum pname, GLint *value)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->GetPathParameterivNV(path, pname, value);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glCoverStrokePathInstancedNV(GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLenum coverMode, GLenum transformType, const GLfloat *transformValues)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->CoverStrokePathInstancedNV(numPaths, pathNameType, paths, pathBase, coverMode, transformType, transformValues);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glCoverFillPathInstancedNV(GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLenum coverMode, GLenum transformType, const GLfloat *transformValues)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->CoverFillPathInstancedNV(numPaths, pathNameType, paths, pathBase, coverMode, transformType, transformValues);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glCoverStrokePathNV(GLuint path, GLenum coverMode)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->CoverStrokePathNV(path, coverMode);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glCoverFillPathNV(GLuint path, GLenum coverMode)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->CoverFillPathNV(path, coverMode);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathFogGenNV(GLenum genMode)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathFogGenNV(genMode);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathTexGenNV(GLenum texCoordSet, GLenum genMode, GLint components, const GLfloat *coeffs)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathTexGenNV(texCoordSet, genMode, components, coeffs);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathColorGenNV(GLenum color, GLenum genMode, GLenum colorFormat, const GLfloat *coeffs)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathColorGenNV(color, genMode, colorFormat, coeffs);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathCoverDepthFuncNV(GLenum func)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathCoverDepthFuncNV(func);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glStencilStrokePathInstancedNV(GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLint reference, GLuint mask, GLenum transformType, const GLfloat *transformValues)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->StencilStrokePathInstancedNV(numPaths, pathNameType, paths, pathBase, reference, mask, transformType, transformValues);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glStencilFillPathInstancedNV(GLsizei numPaths, GLenum pathNameType, const GLvoid *paths, GLuint pathBase, GLenum fillMode, GLuint mask, GLenum transformType, const GLfloat *transformValues)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->StencilFillPathInstancedNV(numPaths, pathNameType, paths, pathBase, fillMode, mask, transformType, transformValues);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glStencilStrokePathNV(GLuint path, GLint reference, GLuint mask)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->StencilStrokePathNV(path, reference, mask);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glStencilFillPathNV(GLuint path, GLenum fillMode, GLuint mask)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->StencilFillPathNV(path, fillMode, mask);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathStencilDepthOffsetNV(GLfloat factor, GLfloat units)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathStencilDepthOffsetNV(factor, units);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathStencilFuncNV(GLenum func, GLint ref, GLuint mask)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathStencilFuncNV(func, ref, mask);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathDashArrayNV(GLuint path, GLsizei dashCount, const GLfloat *dashArray)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathDashArrayNV(path, dashCount, dashArray);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathParameterfNV(GLuint path, GLenum pname, GLfloat value)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathParameterfNV(path, pname, value);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathParameterfvNV(GLuint path, GLenum pname, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathParameterfvNV(path, pname, value);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathParameteriNV(GLuint path, GLenum pname, GLint value)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathParameteriNV(path, pname, value);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathParameterivNV(GLuint path, GLenum pname, const GLint *value)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathParameterivNV(path, pname, value);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glTransformPathNV(GLuint resultPath, GLuint srcPath, GLenum transformType, const GLfloat *transformValues)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->TransformPathNV(resultPath, srcPath, transformType, transformValues);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glInterpolatePathsNV(GLuint resultPath, GLuint pathA, GLuint pathB, GLfloat weight)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->InterpolatePathsNV(resultPath, pathA, pathB, weight);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glCopyPathNV(GLuint resultPath, GLuint srcPath)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->CopyPathNV(resultPath, srcPath);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glWeightPathsNV(GLuint resultPath, GLsizei numPaths, const GLuint *paths, const GLfloat *weights)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->WeightPathsNV(resultPath, numPaths, paths, weights);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathGlyphRangeNV(GLuint firstPathName, GLenum fontTarget, const GLvoid *fontName, GLbitfield fontStyle, GLuint firstGlyph, GLsizei numGlyphs, GLenum handleMissingGlyphs, GLuint pathParameterTemplate, GLfloat emScale)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathGlyphRangeNV(firstPathName, fontTarget, fontName, fontStyle, firstGlyph, numGlyphs, handleMissingGlyphs, pathParameterTemplate, emScale);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathGlyphsNV(GLuint firstPathName, GLenum fontTarget, const GLvoid *fontName, GLbitfield fontStyle, GLsizei numGlyphs, GLenum type, const GLvoid *charcodes, GLenum handleMissingGlyphs, GLuint pathParameterTemplate, GLfloat emScale)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathGlyphsNV(firstPathName, fontTarget, fontName, fontStyle, numGlyphs, type, charcodes, handleMissingGlyphs, pathParameterTemplate, emScale);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathStringNV(GLuint path, GLenum format, GLsizei length, const GLvoid *pathString)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathStringNV(path, format, length, pathString);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathSubCoordsNV(GLuint path, GLsizei coordStart, GLsizei numCoords, GLenum coordType, const GLvoid *coords)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathSubCoordsNV(path, coordStart, numCoords, coordType, coords);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathSubCommandsNV(GLuint path, GLsizei commandStart, GLsizei commandsToDelete, GLsizei numCommands, const GLubyte *commands, GLsizei numCoords, GLenum coordType, const GLvoid *coords)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathSubCommandsNV(path, commandStart, commandsToDelete, numCommands, commands, numCoords, coordType, coords);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathCoordsNV(GLuint path, GLsizei numCoords, GLenum coordType, const GLvoid *coords)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathCoordsNV(path, numCoords, coordType, coords);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glPathCommandsNV(GLuint path, GLsizei numCommands, const GLubyte *commands, GLsizei numCoords, GLenum coordType, const GLvoid *coords)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->PathCommandsNV(path, numCommands, commands, numCoords, coordType, coords);
+}
+
+inline GLboolean QOpenGLExtension_NV_path_rendering::glIsPathNV(GLuint path)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ return d->IsPathNV(path);
+}
+
+inline void QOpenGLExtension_NV_path_rendering::glDeletePathsNV(GLuint path, GLsizei range)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ d->DeletePathsNV(path, range);
+}
+
+inline GLuint QOpenGLExtension_NV_path_rendering::glGenPathsNV(GLsizei range)
+{
+ Q_D(QOpenGLExtension_NV_path_rendering);
+ return d->GenPathsNV(range);
+}
+
+class QOpenGLExtension_NV_pixel_data_rangePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP FlushPixelDataRangeNV)(GLenum target);
+ void (QOPENGLF_APIENTRYP PixelDataRangeNV)(GLenum target, GLsizei length, const GLvoid *pointer);
+};
+
+class QOpenGLExtension_NV_pixel_data_range : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_pixel_data_range();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glFlushPixelDataRangeNV(GLenum target);
+ void glPixelDataRangeNV(GLenum target, GLsizei length, const GLvoid *pointer);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_pixel_data_range)
+};
+
+inline void QOpenGLExtension_NV_pixel_data_range::glFlushPixelDataRangeNV(GLenum target)
+{
+ Q_D(QOpenGLExtension_NV_pixel_data_range);
+ d->FlushPixelDataRangeNV(target);
+}
+
+inline void QOpenGLExtension_NV_pixel_data_range::glPixelDataRangeNV(GLenum target, GLsizei length, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_NV_pixel_data_range);
+ d->PixelDataRangeNV(target, length, pointer);
+}
+
+class QOpenGLExtension_NV_point_spritePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP PointParameterivNV)(GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP PointParameteriNV)(GLenum pname, GLint param);
+};
+
+class QOpenGLExtension_NV_point_sprite : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_point_sprite();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glPointParameterivNV(GLenum pname, const GLint *params);
+ void glPointParameteriNV(GLenum pname, GLint param);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_point_sprite)
+};
+
+inline void QOpenGLExtension_NV_point_sprite::glPointParameterivNV(GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_point_sprite);
+ d->PointParameterivNV(pname, params);
+}
+
+inline void QOpenGLExtension_NV_point_sprite::glPointParameteriNV(GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_NV_point_sprite);
+ d->PointParameteriNV(pname, param);
+}
+
+class QOpenGLExtension_NV_present_videoPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetVideoui64vNV)(GLuint video_slot, GLenum pname, GLuint64EXT *params);
+ void (QOPENGLF_APIENTRYP GetVideoi64vNV)(GLuint video_slot, GLenum pname, GLint64EXT *params);
+ void (QOPENGLF_APIENTRYP GetVideouivNV)(GLuint video_slot, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetVideoivNV)(GLuint video_slot, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP PresentFrameDualFillNV)(GLuint video_slot, GLuint64EXT minPresentTime, GLuint beginPresentTimeId, GLuint presentDurationId, GLenum type, GLenum target0, GLuint fill0, GLenum target1, GLuint fill1, GLenum target2, GLuint fill2, GLenum target3, GLuint fill3);
+ void (QOPENGLF_APIENTRYP PresentFrameKeyedNV)(GLuint video_slot, GLuint64EXT minPresentTime, GLuint beginPresentTimeId, GLuint presentDurationId, GLenum type, GLenum target0, GLuint fill0, GLuint key0, GLenum target1, GLuint fill1, GLuint key1);
+};
+
+class QOpenGLExtension_NV_present_video : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_present_video();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetVideoui64vNV(GLuint video_slot, GLenum pname, GLuint64EXT *params);
+ void glGetVideoi64vNV(GLuint video_slot, GLenum pname, GLint64EXT *params);
+ void glGetVideouivNV(GLuint video_slot, GLenum pname, GLuint *params);
+ void glGetVideoivNV(GLuint video_slot, GLenum pname, GLint *params);
+ void glPresentFrameDualFillNV(GLuint video_slot, GLuint64EXT minPresentTime, GLuint beginPresentTimeId, GLuint presentDurationId, GLenum type, GLenum target0, GLuint fill0, GLenum target1, GLuint fill1, GLenum target2, GLuint fill2, GLenum target3, GLuint fill3);
+ void glPresentFrameKeyedNV(GLuint video_slot, GLuint64EXT minPresentTime, GLuint beginPresentTimeId, GLuint presentDurationId, GLenum type, GLenum target0, GLuint fill0, GLuint key0, GLenum target1, GLuint fill1, GLuint key1);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_present_video)
+};
+
+inline void QOpenGLExtension_NV_present_video::glGetVideoui64vNV(GLuint video_slot, GLenum pname, GLuint64EXT *params)
+{
+ Q_D(QOpenGLExtension_NV_present_video);
+ d->GetVideoui64vNV(video_slot, pname, params);
+}
+
+inline void QOpenGLExtension_NV_present_video::glGetVideoi64vNV(GLuint video_slot, GLenum pname, GLint64EXT *params)
+{
+ Q_D(QOpenGLExtension_NV_present_video);
+ d->GetVideoi64vNV(video_slot, pname, params);
+}
+
+inline void QOpenGLExtension_NV_present_video::glGetVideouivNV(GLuint video_slot, GLenum pname, GLuint *params)
+{
+ Q_D(QOpenGLExtension_NV_present_video);
+ d->GetVideouivNV(video_slot, pname, params);
+}
+
+inline void QOpenGLExtension_NV_present_video::glGetVideoivNV(GLuint video_slot, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_present_video);
+ d->GetVideoivNV(video_slot, pname, params);
+}
+
+inline void QOpenGLExtension_NV_present_video::glPresentFrameDualFillNV(GLuint video_slot, GLuint64EXT minPresentTime, GLuint beginPresentTimeId, GLuint presentDurationId, GLenum type, GLenum target0, GLuint fill0, GLenum target1, GLuint fill1, GLenum target2, GLuint fill2, GLenum target3, GLuint fill3)
+{
+ Q_D(QOpenGLExtension_NV_present_video);
+ d->PresentFrameDualFillNV(video_slot, minPresentTime, beginPresentTimeId, presentDurationId, type, target0, fill0, target1, fill1, target2, fill2, target3, fill3);
+}
+
+inline void QOpenGLExtension_NV_present_video::glPresentFrameKeyedNV(GLuint video_slot, GLuint64EXT minPresentTime, GLuint beginPresentTimeId, GLuint presentDurationId, GLenum type, GLenum target0, GLuint fill0, GLuint key0, GLenum target1, GLuint fill1, GLuint key1)
+{
+ Q_D(QOpenGLExtension_NV_present_video);
+ d->PresentFrameKeyedNV(video_slot, minPresentTime, beginPresentTimeId, presentDurationId, type, target0, fill0, key0, target1, fill1, key1);
+}
+
+class QOpenGLExtension_NV_primitive_restartPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP PrimitiveRestartIndexNV)(GLuint index);
+ void (QOPENGLF_APIENTRYP PrimitiveRestartNV)();
+};
+
+class QOpenGLExtension_NV_primitive_restart : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_primitive_restart();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glPrimitiveRestartIndexNV(GLuint index);
+ void glPrimitiveRestartNV();
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_primitive_restart)
+};
+
+inline void QOpenGLExtension_NV_primitive_restart::glPrimitiveRestartIndexNV(GLuint index)
+{
+ Q_D(QOpenGLExtension_NV_primitive_restart);
+ d->PrimitiveRestartIndexNV(index);
+}
+
+inline void QOpenGLExtension_NV_primitive_restart::glPrimitiveRestartNV()
+{
+ Q_D(QOpenGLExtension_NV_primitive_restart);
+ d->PrimitiveRestartNV();
+}
+
+class QOpenGLExtension_NV_register_combinersPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetFinalCombinerInputParameterivNV)(GLenum variable, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetFinalCombinerInputParameterfvNV)(GLenum variable, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetCombinerOutputParameterivNV)(GLenum stage, GLenum portion, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetCombinerOutputParameterfvNV)(GLenum stage, GLenum portion, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetCombinerInputParameterivNV)(GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetCombinerInputParameterfvNV)(GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP FinalCombinerInputNV)(GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage);
+ void (QOPENGLF_APIENTRYP CombinerOutputNV)(GLenum stage, GLenum portion, GLenum abOutput, GLenum cdOutput, GLenum sumOutput, GLenum scale, GLenum bias, GLboolean abDotProduct, GLboolean cdDotProduct, GLboolean muxSum);
+ void (QOPENGLF_APIENTRYP CombinerInputNV)(GLenum stage, GLenum portion, GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage);
+ void (QOPENGLF_APIENTRYP CombinerParameteriNV)(GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP CombinerParameterivNV)(GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP CombinerParameterfNV)(GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP CombinerParameterfvNV)(GLenum pname, const GLfloat *params);
+};
+
+class QOpenGLExtension_NV_register_combiners : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_register_combiners();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetFinalCombinerInputParameterivNV(GLenum variable, GLenum pname, GLint *params);
+ void glGetFinalCombinerInputParameterfvNV(GLenum variable, GLenum pname, GLfloat *params);
+ void glGetCombinerOutputParameterivNV(GLenum stage, GLenum portion, GLenum pname, GLint *params);
+ void glGetCombinerOutputParameterfvNV(GLenum stage, GLenum portion, GLenum pname, GLfloat *params);
+ void glGetCombinerInputParameterivNV(GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLint *params);
+ void glGetCombinerInputParameterfvNV(GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLfloat *params);
+ void glFinalCombinerInputNV(GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage);
+ void glCombinerOutputNV(GLenum stage, GLenum portion, GLenum abOutput, GLenum cdOutput, GLenum sumOutput, GLenum scale, GLenum bias, GLboolean abDotProduct, GLboolean cdDotProduct, GLboolean muxSum);
+ void glCombinerInputNV(GLenum stage, GLenum portion, GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage);
+ void glCombinerParameteriNV(GLenum pname, GLint param);
+ void glCombinerParameterivNV(GLenum pname, const GLint *params);
+ void glCombinerParameterfNV(GLenum pname, GLfloat param);
+ void glCombinerParameterfvNV(GLenum pname, const GLfloat *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_register_combiners)
+};
+
+inline void QOpenGLExtension_NV_register_combiners::glGetFinalCombinerInputParameterivNV(GLenum variable, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->GetFinalCombinerInputParameterivNV(variable, pname, params);
+}
+
+inline void QOpenGLExtension_NV_register_combiners::glGetFinalCombinerInputParameterfvNV(GLenum variable, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->GetFinalCombinerInputParameterfvNV(variable, pname, params);
+}
+
+inline void QOpenGLExtension_NV_register_combiners::glGetCombinerOutputParameterivNV(GLenum stage, GLenum portion, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->GetCombinerOutputParameterivNV(stage, portion, pname, params);
+}
+
+inline void QOpenGLExtension_NV_register_combiners::glGetCombinerOutputParameterfvNV(GLenum stage, GLenum portion, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->GetCombinerOutputParameterfvNV(stage, portion, pname, params);
+}
+
+inline void QOpenGLExtension_NV_register_combiners::glGetCombinerInputParameterivNV(GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->GetCombinerInputParameterivNV(stage, portion, variable, pname, params);
+}
+
+inline void QOpenGLExtension_NV_register_combiners::glGetCombinerInputParameterfvNV(GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->GetCombinerInputParameterfvNV(stage, portion, variable, pname, params);
+}
+
+inline void QOpenGLExtension_NV_register_combiners::glFinalCombinerInputNV(GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->FinalCombinerInputNV(variable, input, mapping, componentUsage);
+}
+
+inline void QOpenGLExtension_NV_register_combiners::glCombinerOutputNV(GLenum stage, GLenum portion, GLenum abOutput, GLenum cdOutput, GLenum sumOutput, GLenum scale, GLenum bias, GLboolean abDotProduct, GLboolean cdDotProduct, GLboolean muxSum)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->CombinerOutputNV(stage, portion, abOutput, cdOutput, sumOutput, scale, bias, abDotProduct, cdDotProduct, muxSum);
+}
+
+inline void QOpenGLExtension_NV_register_combiners::glCombinerInputNV(GLenum stage, GLenum portion, GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->CombinerInputNV(stage, portion, variable, input, mapping, componentUsage);
+}
+
+inline void QOpenGLExtension_NV_register_combiners::glCombinerParameteriNV(GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->CombinerParameteriNV(pname, param);
+}
+
+inline void QOpenGLExtension_NV_register_combiners::glCombinerParameterivNV(GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->CombinerParameterivNV(pname, params);
+}
+
+inline void QOpenGLExtension_NV_register_combiners::glCombinerParameterfNV(GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->CombinerParameterfNV(pname, param);
+}
+
+inline void QOpenGLExtension_NV_register_combiners::glCombinerParameterfvNV(GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners);
+ d->CombinerParameterfvNV(pname, params);
+}
+
+class QOpenGLExtension_NV_register_combiners2Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetCombinerStageParameterfvNV)(GLenum stage, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP CombinerStageParameterfvNV)(GLenum stage, GLenum pname, const GLfloat *params);
+};
+
+class QOpenGLExtension_NV_register_combiners2 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_register_combiners2();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetCombinerStageParameterfvNV(GLenum stage, GLenum pname, GLfloat *params);
+ void glCombinerStageParameterfvNV(GLenum stage, GLenum pname, const GLfloat *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_register_combiners2)
+};
+
+inline void QOpenGLExtension_NV_register_combiners2::glGetCombinerStageParameterfvNV(GLenum stage, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners2);
+ d->GetCombinerStageParameterfvNV(stage, pname, params);
+}
+
+inline void QOpenGLExtension_NV_register_combiners2::glCombinerStageParameterfvNV(GLenum stage, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_register_combiners2);
+ d->CombinerStageParameterfvNV(stage, pname, params);
+}
+
+class QOpenGLExtension_NV_shader_buffer_loadPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ProgramUniformui64vNV)(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformui64NV)(GLuint program, GLint location, GLuint64EXT value);
+ void (QOPENGLF_APIENTRYP GetUniformui64vNV)(GLuint program, GLint location, GLuint64EXT *params);
+ void (QOPENGLF_APIENTRYP Uniformui64vNV)(GLint location, GLsizei count, const GLuint64EXT *value);
+ void (QOPENGLF_APIENTRYP Uniformui64NV)(GLint location, GLuint64EXT value);
+ void (QOPENGLF_APIENTRYP GetIntegerui64vNV)(GLenum value, GLuint64EXT *result);
+ void (QOPENGLF_APIENTRYP GetNamedBufferParameterui64vNV)(GLuint buffer, GLenum pname, GLuint64EXT *params);
+ void (QOPENGLF_APIENTRYP GetBufferParameterui64vNV)(GLenum target, GLenum pname, GLuint64EXT *params);
+ GLboolean (QOPENGLF_APIENTRYP IsNamedBufferResidentNV)(GLuint buffer);
+ void (QOPENGLF_APIENTRYP MakeNamedBufferNonResidentNV)(GLuint buffer);
+ void (QOPENGLF_APIENTRYP MakeNamedBufferResidentNV)(GLuint buffer, GLenum access);
+ GLboolean (QOPENGLF_APIENTRYP IsBufferResidentNV)(GLenum target);
+ void (QOPENGLF_APIENTRYP MakeBufferNonResidentNV)(GLenum target);
+ void (QOPENGLF_APIENTRYP MakeBufferResidentNV)(GLenum target, GLenum access);
+};
+
+class QOpenGLExtension_NV_shader_buffer_load : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_shader_buffer_load();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glProgramUniformui64vNV(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value);
+ void glProgramUniformui64NV(GLuint program, GLint location, GLuint64EXT value);
+ void glGetUniformui64vNV(GLuint program, GLint location, GLuint64EXT *params);
+ void glUniformui64vNV(GLint location, GLsizei count, const GLuint64EXT *value);
+ void glUniformui64NV(GLint location, GLuint64EXT value);
+ void glGetIntegerui64vNV(GLenum value, GLuint64EXT *result);
+ void glGetNamedBufferParameterui64vNV(GLuint buffer, GLenum pname, GLuint64EXT *params);
+ void glGetBufferParameterui64vNV(GLenum target, GLenum pname, GLuint64EXT *params);
+ GLboolean glIsNamedBufferResidentNV(GLuint buffer);
+ void glMakeNamedBufferNonResidentNV(GLuint buffer);
+ void glMakeNamedBufferResidentNV(GLuint buffer, GLenum access);
+ GLboolean glIsBufferResidentNV(GLenum target);
+ void glMakeBufferNonResidentNV(GLenum target);
+ void glMakeBufferResidentNV(GLenum target, GLenum access);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_shader_buffer_load)
+};
+
+inline void QOpenGLExtension_NV_shader_buffer_load::glProgramUniformui64vNV(GLuint program, GLint location, GLsizei count, const GLuint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ d->ProgramUniformui64vNV(program, location, count, value);
+}
+
+inline void QOpenGLExtension_NV_shader_buffer_load::glProgramUniformui64NV(GLuint program, GLint location, GLuint64EXT value)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ d->ProgramUniformui64NV(program, location, value);
+}
+
+inline void QOpenGLExtension_NV_shader_buffer_load::glGetUniformui64vNV(GLuint program, GLint location, GLuint64EXT *params)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ d->GetUniformui64vNV(program, location, params);
+}
+
+inline void QOpenGLExtension_NV_shader_buffer_load::glUniformui64vNV(GLint location, GLsizei count, const GLuint64EXT *value)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ d->Uniformui64vNV(location, count, value);
+}
+
+inline void QOpenGLExtension_NV_shader_buffer_load::glUniformui64NV(GLint location, GLuint64EXT value)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ d->Uniformui64NV(location, value);
+}
+
+inline void QOpenGLExtension_NV_shader_buffer_load::glGetIntegerui64vNV(GLenum value, GLuint64EXT *result)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ d->GetIntegerui64vNV(value, result);
+}
+
+inline void QOpenGLExtension_NV_shader_buffer_load::glGetNamedBufferParameterui64vNV(GLuint buffer, GLenum pname, GLuint64EXT *params)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ d->GetNamedBufferParameterui64vNV(buffer, pname, params);
+}
+
+inline void QOpenGLExtension_NV_shader_buffer_load::glGetBufferParameterui64vNV(GLenum target, GLenum pname, GLuint64EXT *params)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ d->GetBufferParameterui64vNV(target, pname, params);
+}
+
+inline GLboolean QOpenGLExtension_NV_shader_buffer_load::glIsNamedBufferResidentNV(GLuint buffer)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ return d->IsNamedBufferResidentNV(buffer);
+}
+
+inline void QOpenGLExtension_NV_shader_buffer_load::glMakeNamedBufferNonResidentNV(GLuint buffer)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ d->MakeNamedBufferNonResidentNV(buffer);
+}
+
+inline void QOpenGLExtension_NV_shader_buffer_load::glMakeNamedBufferResidentNV(GLuint buffer, GLenum access)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ d->MakeNamedBufferResidentNV(buffer, access);
+}
+
+inline GLboolean QOpenGLExtension_NV_shader_buffer_load::glIsBufferResidentNV(GLenum target)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ return d->IsBufferResidentNV(target);
+}
+
+inline void QOpenGLExtension_NV_shader_buffer_load::glMakeBufferNonResidentNV(GLenum target)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ d->MakeBufferNonResidentNV(target);
+}
+
+inline void QOpenGLExtension_NV_shader_buffer_load::glMakeBufferResidentNV(GLenum target, GLenum access)
+{
+ Q_D(QOpenGLExtension_NV_shader_buffer_load);
+ d->MakeBufferResidentNV(target, access);
+}
+
+class QOpenGLExtension_NV_texture_barrierPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TextureBarrierNV)();
+};
+
+class QOpenGLExtension_NV_texture_barrier : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_texture_barrier();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTextureBarrierNV();
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_texture_barrier)
+};
+
+inline void QOpenGLExtension_NV_texture_barrier::glTextureBarrierNV()
+{
+ Q_D(QOpenGLExtension_NV_texture_barrier);
+ d->TextureBarrierNV();
+}
+
+class QOpenGLExtension_NV_texture_multisamplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TextureImage3DMultisampleCoverageNV)(GLuint texture, GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations);
+ void (QOPENGLF_APIENTRYP TextureImage2DMultisampleCoverageNV)(GLuint texture, GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations);
+ void (QOPENGLF_APIENTRYP TextureImage3DMultisampleNV)(GLuint texture, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations);
+ void (QOPENGLF_APIENTRYP TextureImage2DMultisampleNV)(GLuint texture, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations);
+ void (QOPENGLF_APIENTRYP TexImage3DMultisampleCoverageNV)(GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations);
+ void (QOPENGLF_APIENTRYP TexImage2DMultisampleCoverageNV)(GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations);
+};
+
+class QOpenGLExtension_NV_texture_multisample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_texture_multisample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTextureImage3DMultisampleCoverageNV(GLuint texture, GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations);
+ void glTextureImage2DMultisampleCoverageNV(GLuint texture, GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations);
+ void glTextureImage3DMultisampleNV(GLuint texture, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations);
+ void glTextureImage2DMultisampleNV(GLuint texture, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations);
+ void glTexImage3DMultisampleCoverageNV(GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations);
+ void glTexImage2DMultisampleCoverageNV(GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_texture_multisample)
+};
+
+inline void QOpenGLExtension_NV_texture_multisample::glTextureImage3DMultisampleCoverageNV(GLuint texture, GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations)
+{
+ Q_D(QOpenGLExtension_NV_texture_multisample);
+ d->TextureImage3DMultisampleCoverageNV(texture, target, coverageSamples, colorSamples, internalFormat, width, height, depth, fixedSampleLocations);
+}
+
+inline void QOpenGLExtension_NV_texture_multisample::glTextureImage2DMultisampleCoverageNV(GLuint texture, GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations)
+{
+ Q_D(QOpenGLExtension_NV_texture_multisample);
+ d->TextureImage2DMultisampleCoverageNV(texture, target, coverageSamples, colorSamples, internalFormat, width, height, fixedSampleLocations);
+}
+
+inline void QOpenGLExtension_NV_texture_multisample::glTextureImage3DMultisampleNV(GLuint texture, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations)
+{
+ Q_D(QOpenGLExtension_NV_texture_multisample);
+ d->TextureImage3DMultisampleNV(texture, target, samples, internalFormat, width, height, depth, fixedSampleLocations);
+}
+
+inline void QOpenGLExtension_NV_texture_multisample::glTextureImage2DMultisampleNV(GLuint texture, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations)
+{
+ Q_D(QOpenGLExtension_NV_texture_multisample);
+ d->TextureImage2DMultisampleNV(texture, target, samples, internalFormat, width, height, fixedSampleLocations);
+}
+
+inline void QOpenGLExtension_NV_texture_multisample::glTexImage3DMultisampleCoverageNV(GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedSampleLocations)
+{
+ Q_D(QOpenGLExtension_NV_texture_multisample);
+ d->TexImage3DMultisampleCoverageNV(target, coverageSamples, colorSamples, internalFormat, width, height, depth, fixedSampleLocations);
+}
+
+inline void QOpenGLExtension_NV_texture_multisample::glTexImage2DMultisampleCoverageNV(GLenum target, GLsizei coverageSamples, GLsizei colorSamples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedSampleLocations)
+{
+ Q_D(QOpenGLExtension_NV_texture_multisample);
+ d->TexImage2DMultisampleCoverageNV(target, coverageSamples, colorSamples, internalFormat, width, height, fixedSampleLocations);
+}
+
+class QOpenGLExtension_NV_transform_feedbackPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TransformFeedbackStreamAttribsNV)(GLsizei count, const GLint *attribs, GLsizei nbuffers, const GLint *bufstreams, GLenum bufferMode);
+ void (QOPENGLF_APIENTRYP GetTransformFeedbackVaryingNV)(GLuint program, GLuint index, GLint *location);
+ void (QOPENGLF_APIENTRYP GetActiveVaryingNV)(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ GLint (QOPENGLF_APIENTRYP GetVaryingLocationNV)(GLuint program, const GLchar *name);
+ void (QOPENGLF_APIENTRYP ActiveVaryingNV)(GLuint program, const GLchar *name);
+ void (QOPENGLF_APIENTRYP TransformFeedbackVaryingsNV)(GLuint program, GLsizei count, const GLint *locations, GLenum bufferMode);
+ void (QOPENGLF_APIENTRYP BindBufferBaseNV)(GLenum target, GLuint index, GLuint buffer);
+ void (QOPENGLF_APIENTRYP BindBufferOffsetNV)(GLenum target, GLuint index, GLuint buffer, GLintptr offset);
+ void (QOPENGLF_APIENTRYP BindBufferRangeNV)(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void (QOPENGLF_APIENTRYP TransformFeedbackAttribsNV)(GLuint count, const GLint *attribs, GLenum bufferMode);
+ void (QOPENGLF_APIENTRYP EndTransformFeedbackNV)();
+ void (QOPENGLF_APIENTRYP BeginTransformFeedbackNV)(GLenum primitiveMode);
+};
+
+class QOpenGLExtension_NV_transform_feedback : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_transform_feedback();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTransformFeedbackStreamAttribsNV(GLsizei count, const GLint *attribs, GLsizei nbuffers, const GLint *bufstreams, GLenum bufferMode);
+ void glGetTransformFeedbackVaryingNV(GLuint program, GLuint index, GLint *location);
+ void glGetActiveVaryingNV(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name);
+ GLint glGetVaryingLocationNV(GLuint program, const GLchar *name);
+ void glActiveVaryingNV(GLuint program, const GLchar *name);
+ void glTransformFeedbackVaryingsNV(GLuint program, GLsizei count, const GLint *locations, GLenum bufferMode);
+ void glBindBufferBaseNV(GLenum target, GLuint index, GLuint buffer);
+ void glBindBufferOffsetNV(GLenum target, GLuint index, GLuint buffer, GLintptr offset);
+ void glBindBufferRangeNV(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+ void glTransformFeedbackAttribsNV(GLuint count, const GLint *attribs, GLenum bufferMode);
+ void glEndTransformFeedbackNV();
+ void glBeginTransformFeedbackNV(GLenum primitiveMode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_transform_feedback)
+};
+
+inline void QOpenGLExtension_NV_transform_feedback::glTransformFeedbackStreamAttribsNV(GLsizei count, const GLint *attribs, GLsizei nbuffers, const GLint *bufstreams, GLenum bufferMode)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+ d->TransformFeedbackStreamAttribsNV(count, attribs, nbuffers, bufstreams, bufferMode);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback::glGetTransformFeedbackVaryingNV(GLuint program, GLuint index, GLint *location)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+ d->GetTransformFeedbackVaryingNV(program, index, location);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback::glGetActiveVaryingNV(GLuint program, GLuint index, GLsizei bufSize, GLsizei *length, GLsizei *size, GLenum *type, GLchar *name)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+ d->GetActiveVaryingNV(program, index, bufSize, length, size, type, name);
+}
+
+inline GLint QOpenGLExtension_NV_transform_feedback::glGetVaryingLocationNV(GLuint program, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+ return d->GetVaryingLocationNV(program, name);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback::glActiveVaryingNV(GLuint program, const GLchar *name)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+ d->ActiveVaryingNV(program, name);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback::glTransformFeedbackVaryingsNV(GLuint program, GLsizei count, const GLint *locations, GLenum bufferMode)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+ d->TransformFeedbackVaryingsNV(program, count, locations, bufferMode);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback::glBindBufferBaseNV(GLenum target, GLuint index, GLuint buffer)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+ d->BindBufferBaseNV(target, index, buffer);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback::glBindBufferOffsetNV(GLenum target, GLuint index, GLuint buffer, GLintptr offset)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+ d->BindBufferOffsetNV(target, index, buffer, offset);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback::glBindBufferRangeNV(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+ d->BindBufferRangeNV(target, index, buffer, offset, size);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback::glTransformFeedbackAttribsNV(GLuint count, const GLint *attribs, GLenum bufferMode)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+ d->TransformFeedbackAttribsNV(count, attribs, bufferMode);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback::glEndTransformFeedbackNV()
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+ d->EndTransformFeedbackNV();
+}
+
+inline void QOpenGLExtension_NV_transform_feedback::glBeginTransformFeedbackNV(GLenum primitiveMode)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback);
+ d->BeginTransformFeedbackNV(primitiveMode);
+}
+
+class QOpenGLExtension_NV_transform_feedback2Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawTransformFeedbackNV)(GLenum mode, GLuint id);
+ void (QOPENGLF_APIENTRYP ResumeTransformFeedbackNV)();
+ void (QOPENGLF_APIENTRYP PauseTransformFeedbackNV)();
+ GLboolean (QOPENGLF_APIENTRYP IsTransformFeedbackNV)(GLuint id);
+ void (QOPENGLF_APIENTRYP GenTransformFeedbacksNV)(GLsizei n, GLuint *ids);
+ void (QOPENGLF_APIENTRYP DeleteTransformFeedbacksNV)(GLsizei n, const GLuint *ids);
+ void (QOPENGLF_APIENTRYP BindTransformFeedbackNV)(GLenum target, GLuint id);
+};
+
+class QOpenGLExtension_NV_transform_feedback2 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_transform_feedback2();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawTransformFeedbackNV(GLenum mode, GLuint id);
+ void glResumeTransformFeedbackNV();
+ void glPauseTransformFeedbackNV();
+ GLboolean glIsTransformFeedbackNV(GLuint id);
+ void glGenTransformFeedbacksNV(GLsizei n, GLuint *ids);
+ void glDeleteTransformFeedbacksNV(GLsizei n, const GLuint *ids);
+ void glBindTransformFeedbackNV(GLenum target, GLuint id);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_transform_feedback2)
+};
+
+inline void QOpenGLExtension_NV_transform_feedback2::glDrawTransformFeedbackNV(GLenum mode, GLuint id)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback2);
+ d->DrawTransformFeedbackNV(mode, id);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback2::glResumeTransformFeedbackNV()
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback2);
+ d->ResumeTransformFeedbackNV();
+}
+
+inline void QOpenGLExtension_NV_transform_feedback2::glPauseTransformFeedbackNV()
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback2);
+ d->PauseTransformFeedbackNV();
+}
+
+inline GLboolean QOpenGLExtension_NV_transform_feedback2::glIsTransformFeedbackNV(GLuint id)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback2);
+ return d->IsTransformFeedbackNV(id);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback2::glGenTransformFeedbacksNV(GLsizei n, GLuint *ids)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback2);
+ d->GenTransformFeedbacksNV(n, ids);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback2::glDeleteTransformFeedbacksNV(GLsizei n, const GLuint *ids)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback2);
+ d->DeleteTransformFeedbacksNV(n, ids);
+}
+
+inline void QOpenGLExtension_NV_transform_feedback2::glBindTransformFeedbackNV(GLenum target, GLuint id)
+{
+ Q_D(QOpenGLExtension_NV_transform_feedback2);
+ d->BindTransformFeedbackNV(target, id);
+}
+
+class QOpenGLExtension_NV_vdpau_interopPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VDPAUUnmapSurfacesNV)(GLsizei numSurface, const GLvdpauSurfaceNV *surfaces);
+ void (QOPENGLF_APIENTRYP VDPAUMapSurfacesNV)(GLsizei numSurfaces, const GLvdpauSurfaceNV *surfaces);
+ void (QOPENGLF_APIENTRYP VDPAUSurfaceAccessNV)(GLvdpauSurfaceNV surface, GLenum access);
+ void (QOPENGLF_APIENTRYP VDPAUGetSurfaceivNV)(GLvdpauSurfaceNV surface, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void (QOPENGLF_APIENTRYP VDPAUUnregisterSurfaceNV)(GLvdpauSurfaceNV surface);
+ void (QOPENGLF_APIENTRYP VDPAUIsSurfaceNV)(GLvdpauSurfaceNV surface);
+ GLvdpauSurfaceNV (QOPENGLF_APIENTRYP VDPAURegisterOutputSurfaceNV)(GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames);
+ GLvdpauSurfaceNV (QOPENGLF_APIENTRYP VDPAURegisterVideoSurfaceNV)(const GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames);
+ void (QOPENGLF_APIENTRYP VDPAUFiniNV)();
+ void (QOPENGLF_APIENTRYP VDPAUInitNV)(const GLvoid *vdpDevice, const GLvoid *getProcAddress);
+};
+
+class QOpenGLExtension_NV_vdpau_interop : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_vdpau_interop();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVDPAUUnmapSurfacesNV(GLsizei numSurface, const GLvdpauSurfaceNV *surfaces);
+ void glVDPAUMapSurfacesNV(GLsizei numSurfaces, const GLvdpauSurfaceNV *surfaces);
+ void glVDPAUSurfaceAccessNV(GLvdpauSurfaceNV surface, GLenum access);
+ void glVDPAUGetSurfaceivNV(GLvdpauSurfaceNV surface, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values);
+ void glVDPAUUnregisterSurfaceNV(GLvdpauSurfaceNV surface);
+ void glVDPAUIsSurfaceNV(GLvdpauSurfaceNV surface);
+ GLvdpauSurfaceNV glVDPAURegisterOutputSurfaceNV(GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames);
+ GLvdpauSurfaceNV glVDPAURegisterVideoSurfaceNV(const GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames);
+ void glVDPAUFiniNV();
+ void glVDPAUInitNV(const GLvoid *vdpDevice, const GLvoid *getProcAddress);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_vdpau_interop)
+};
+
+inline void QOpenGLExtension_NV_vdpau_interop::glVDPAUUnmapSurfacesNV(GLsizei numSurface, const GLvdpauSurfaceNV *surfaces)
+{
+ Q_D(QOpenGLExtension_NV_vdpau_interop);
+ d->VDPAUUnmapSurfacesNV(numSurface, surfaces);
+}
+
+inline void QOpenGLExtension_NV_vdpau_interop::glVDPAUMapSurfacesNV(GLsizei numSurfaces, const GLvdpauSurfaceNV *surfaces)
+{
+ Q_D(QOpenGLExtension_NV_vdpau_interop);
+ d->VDPAUMapSurfacesNV(numSurfaces, surfaces);
+}
+
+inline void QOpenGLExtension_NV_vdpau_interop::glVDPAUSurfaceAccessNV(GLvdpauSurfaceNV surface, GLenum access)
+{
+ Q_D(QOpenGLExtension_NV_vdpau_interop);
+ d->VDPAUSurfaceAccessNV(surface, access);
+}
+
+inline void QOpenGLExtension_NV_vdpau_interop::glVDPAUGetSurfaceivNV(GLvdpauSurfaceNV surface, GLenum pname, GLsizei bufSize, GLsizei *length, GLint *values)
+{
+ Q_D(QOpenGLExtension_NV_vdpau_interop);
+ d->VDPAUGetSurfaceivNV(surface, pname, bufSize, length, values);
+}
+
+inline void QOpenGLExtension_NV_vdpau_interop::glVDPAUUnregisterSurfaceNV(GLvdpauSurfaceNV surface)
+{
+ Q_D(QOpenGLExtension_NV_vdpau_interop);
+ d->VDPAUUnregisterSurfaceNV(surface);
+}
+
+inline void QOpenGLExtension_NV_vdpau_interop::glVDPAUIsSurfaceNV(GLvdpauSurfaceNV surface)
+{
+ Q_D(QOpenGLExtension_NV_vdpau_interop);
+ d->VDPAUIsSurfaceNV(surface);
+}
+
+inline GLvdpauSurfaceNV QOpenGLExtension_NV_vdpau_interop::glVDPAURegisterOutputSurfaceNV(GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames)
+{
+ Q_D(QOpenGLExtension_NV_vdpau_interop);
+ return d->VDPAURegisterOutputSurfaceNV(vdpSurface, target, numTextureNames, textureNames);
+}
+
+inline GLvdpauSurfaceNV QOpenGLExtension_NV_vdpau_interop::glVDPAURegisterVideoSurfaceNV(const GLvoid *vdpSurface, GLenum target, GLsizei numTextureNames, const GLuint *textureNames)
+{
+ Q_D(QOpenGLExtension_NV_vdpau_interop);
+ return d->VDPAURegisterVideoSurfaceNV(vdpSurface, target, numTextureNames, textureNames);
+}
+
+inline void QOpenGLExtension_NV_vdpau_interop::glVDPAUFiniNV()
+{
+ Q_D(QOpenGLExtension_NV_vdpau_interop);
+ d->VDPAUFiniNV();
+}
+
+inline void QOpenGLExtension_NV_vdpau_interop::glVDPAUInitNV(const GLvoid *vdpDevice, const GLvoid *getProcAddress)
+{
+ Q_D(QOpenGLExtension_NV_vdpau_interop);
+ d->VDPAUInitNV(vdpDevice, getProcAddress);
+}
+
+class QOpenGLExtension_NV_vertex_array_rangePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexArrayRangeNV)(GLsizei length, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP FlushVertexArrayRangeNV)();
+};
+
+class QOpenGLExtension_NV_vertex_array_range : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_vertex_array_range();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexArrayRangeNV(GLsizei length, const GLvoid *pointer);
+ void glFlushVertexArrayRangeNV();
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_vertex_array_range)
+};
+
+inline void QOpenGLExtension_NV_vertex_array_range::glVertexArrayRangeNV(GLsizei length, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_NV_vertex_array_range);
+ d->VertexArrayRangeNV(length, pointer);
+}
+
+inline void QOpenGLExtension_NV_vertex_array_range::glFlushVertexArrayRangeNV()
+{
+ Q_D(QOpenGLExtension_NV_vertex_array_range);
+ d->FlushVertexArrayRangeNV();
+}
+
+class QOpenGLExtension_NV_vertex_attrib_integer_64bitPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexAttribLFormatNV)(GLuint index, GLint size, GLenum type, GLsizei stride);
+ void (QOPENGLF_APIENTRYP GetVertexAttribLui64vNV)(GLuint index, GLenum pname, GLuint64EXT *params);
+ void (QOPENGLF_APIENTRYP GetVertexAttribLi64vNV)(GLuint index, GLenum pname, GLint64EXT *params);
+ void (QOPENGLF_APIENTRYP VertexAttribL4ui64vNV)(GLuint index, const GLuint64EXT *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL3ui64vNV)(GLuint index, const GLuint64EXT *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL2ui64vNV)(GLuint index, const GLuint64EXT *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL1ui64vNV)(GLuint index, const GLuint64EXT *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL4ui64NV)(GLuint index, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w);
+ void (QOPENGLF_APIENTRYP VertexAttribL3ui64NV)(GLuint index, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z);
+ void (QOPENGLF_APIENTRYP VertexAttribL2ui64NV)(GLuint index, GLuint64EXT x, GLuint64EXT y);
+ void (QOPENGLF_APIENTRYP VertexAttribL1ui64NV)(GLuint index, GLuint64EXT x);
+ void (QOPENGLF_APIENTRYP VertexAttribL4i64vNV)(GLuint index, const GLint64EXT *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL3i64vNV)(GLuint index, const GLint64EXT *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL2i64vNV)(GLuint index, const GLint64EXT *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL1i64vNV)(GLuint index, const GLint64EXT *v);
+ void (QOPENGLF_APIENTRYP VertexAttribL4i64NV)(GLuint index, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w);
+ void (QOPENGLF_APIENTRYP VertexAttribL3i64NV)(GLuint index, GLint64EXT x, GLint64EXT y, GLint64EXT z);
+ void (QOPENGLF_APIENTRYP VertexAttribL2i64NV)(GLuint index, GLint64EXT x, GLint64EXT y);
+ void (QOPENGLF_APIENTRYP VertexAttribL1i64NV)(GLuint index, GLint64EXT x);
+};
+
+class QOpenGLExtension_NV_vertex_attrib_integer_64bit : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_vertex_attrib_integer_64bit();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexAttribLFormatNV(GLuint index, GLint size, GLenum type, GLsizei stride);
+ void glGetVertexAttribLui64vNV(GLuint index, GLenum pname, GLuint64EXT *params);
+ void glGetVertexAttribLi64vNV(GLuint index, GLenum pname, GLint64EXT *params);
+ void glVertexAttribL4ui64vNV(GLuint index, const GLuint64EXT *v);
+ void glVertexAttribL3ui64vNV(GLuint index, const GLuint64EXT *v);
+ void glVertexAttribL2ui64vNV(GLuint index, const GLuint64EXT *v);
+ void glVertexAttribL1ui64vNV(GLuint index, const GLuint64EXT *v);
+ void glVertexAttribL4ui64NV(GLuint index, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w);
+ void glVertexAttribL3ui64NV(GLuint index, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z);
+ void glVertexAttribL2ui64NV(GLuint index, GLuint64EXT x, GLuint64EXT y);
+ void glVertexAttribL1ui64NV(GLuint index, GLuint64EXT x);
+ void glVertexAttribL4i64vNV(GLuint index, const GLint64EXT *v);
+ void glVertexAttribL3i64vNV(GLuint index, const GLint64EXT *v);
+ void glVertexAttribL2i64vNV(GLuint index, const GLint64EXT *v);
+ void glVertexAttribL1i64vNV(GLuint index, const GLint64EXT *v);
+ void glVertexAttribL4i64NV(GLuint index, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w);
+ void glVertexAttribL3i64NV(GLuint index, GLint64EXT x, GLint64EXT y, GLint64EXT z);
+ void glVertexAttribL2i64NV(GLuint index, GLint64EXT x, GLint64EXT y);
+ void glVertexAttribL1i64NV(GLuint index, GLint64EXT x);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_vertex_attrib_integer_64bit)
+};
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribLFormatNV(GLuint index, GLint size, GLenum type, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribLFormatNV(index, size, type, stride);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glGetVertexAttribLui64vNV(GLuint index, GLenum pname, GLuint64EXT *params)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->GetVertexAttribLui64vNV(index, pname, params);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glGetVertexAttribLi64vNV(GLuint index, GLenum pname, GLint64EXT *params)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->GetVertexAttribLi64vNV(index, pname, params);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL4ui64vNV(GLuint index, const GLuint64EXT *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL4ui64vNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL3ui64vNV(GLuint index, const GLuint64EXT *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL3ui64vNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL2ui64vNV(GLuint index, const GLuint64EXT *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL2ui64vNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL1ui64vNV(GLuint index, const GLuint64EXT *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL1ui64vNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL4ui64NV(GLuint index, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z, GLuint64EXT w)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL4ui64NV(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL3ui64NV(GLuint index, GLuint64EXT x, GLuint64EXT y, GLuint64EXT z)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL3ui64NV(index, x, y, z);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL2ui64NV(GLuint index, GLuint64EXT x, GLuint64EXT y)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL2ui64NV(index, x, y);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL1ui64NV(GLuint index, GLuint64EXT x)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL1ui64NV(index, x);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL4i64vNV(GLuint index, const GLint64EXT *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL4i64vNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL3i64vNV(GLuint index, const GLint64EXT *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL3i64vNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL2i64vNV(GLuint index, const GLint64EXT *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL2i64vNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL1i64vNV(GLuint index, const GLint64EXT *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL1i64vNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL4i64NV(GLuint index, GLint64EXT x, GLint64EXT y, GLint64EXT z, GLint64EXT w)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL4i64NV(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL3i64NV(GLuint index, GLint64EXT x, GLint64EXT y, GLint64EXT z)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL3i64NV(index, x, y, z);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL2i64NV(GLuint index, GLint64EXT x, GLint64EXT y)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL2i64NV(index, x, y);
+}
+
+inline void QOpenGLExtension_NV_vertex_attrib_integer_64bit::glVertexAttribL1i64NV(GLuint index, GLint64EXT x)
+{
+ Q_D(QOpenGLExtension_NV_vertex_attrib_integer_64bit);
+ d->VertexAttribL1i64NV(index, x);
+}
+
+class QOpenGLExtension_NV_vertex_buffer_unified_memoryPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetIntegerui64i_vNV)(GLenum value, GLuint index, GLuint64EXT *result);
+ void (QOPENGLF_APIENTRYP VertexAttribIFormatNV)(GLuint index, GLint size, GLenum type, GLsizei stride);
+ void (QOPENGLF_APIENTRYP VertexAttribFormatNV)(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride);
+ void (QOPENGLF_APIENTRYP FogCoordFormatNV)(GLenum type, GLsizei stride);
+ void (QOPENGLF_APIENTRYP SecondaryColorFormatNV)(GLint size, GLenum type, GLsizei stride);
+ void (QOPENGLF_APIENTRYP EdgeFlagFormatNV)(GLsizei stride);
+ void (QOPENGLF_APIENTRYP TexCoordFormatNV)(GLint size, GLenum type, GLsizei stride);
+ void (QOPENGLF_APIENTRYP IndexFormatNV)(GLenum type, GLsizei stride);
+ void (QOPENGLF_APIENTRYP ColorFormatNV)(GLint size, GLenum type, GLsizei stride);
+ void (QOPENGLF_APIENTRYP NormalFormatNV)(GLenum type, GLsizei stride);
+ void (QOPENGLF_APIENTRYP VertexFormatNV)(GLint size, GLenum type, GLsizei stride);
+ void (QOPENGLF_APIENTRYP BufferAddressRangeNV)(GLenum pname, GLuint index, GLuint64EXT address, GLsizeiptr length);
+};
+
+class QOpenGLExtension_NV_vertex_buffer_unified_memory : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_vertex_buffer_unified_memory();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetIntegerui64i_vNV(GLenum value, GLuint index, GLuint64EXT *result);
+ void glVertexAttribIFormatNV(GLuint index, GLint size, GLenum type, GLsizei stride);
+ void glVertexAttribFormatNV(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride);
+ void glFogCoordFormatNV(GLenum type, GLsizei stride);
+ void glSecondaryColorFormatNV(GLint size, GLenum type, GLsizei stride);
+ void glEdgeFlagFormatNV(GLsizei stride);
+ void glTexCoordFormatNV(GLint size, GLenum type, GLsizei stride);
+ void glIndexFormatNV(GLenum type, GLsizei stride);
+ void glColorFormatNV(GLint size, GLenum type, GLsizei stride);
+ void glNormalFormatNV(GLenum type, GLsizei stride);
+ void glVertexFormatNV(GLint size, GLenum type, GLsizei stride);
+ void glBufferAddressRangeNV(GLenum pname, GLuint index, GLuint64EXT address, GLsizeiptr length);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_vertex_buffer_unified_memory)
+};
+
+inline void QOpenGLExtension_NV_vertex_buffer_unified_memory::glGetIntegerui64i_vNV(GLenum value, GLuint index, GLuint64EXT *result)
+{
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+ d->GetIntegerui64i_vNV(value, index, result);
+}
+
+inline void QOpenGLExtension_NV_vertex_buffer_unified_memory::glVertexAttribIFormatNV(GLuint index, GLint size, GLenum type, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+ d->VertexAttribIFormatNV(index, size, type, stride);
+}
+
+inline void QOpenGLExtension_NV_vertex_buffer_unified_memory::glVertexAttribFormatNV(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+ d->VertexAttribFormatNV(index, size, type, normalized, stride);
+}
+
+inline void QOpenGLExtension_NV_vertex_buffer_unified_memory::glFogCoordFormatNV(GLenum type, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+ d->FogCoordFormatNV(type, stride);
+}
+
+inline void QOpenGLExtension_NV_vertex_buffer_unified_memory::glSecondaryColorFormatNV(GLint size, GLenum type, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+ d->SecondaryColorFormatNV(size, type, stride);
+}
+
+inline void QOpenGLExtension_NV_vertex_buffer_unified_memory::glEdgeFlagFormatNV(GLsizei stride)
+{
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+ d->EdgeFlagFormatNV(stride);
+}
+
+inline void QOpenGLExtension_NV_vertex_buffer_unified_memory::glTexCoordFormatNV(GLint size, GLenum type, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+ d->TexCoordFormatNV(size, type, stride);
+}
+
+inline void QOpenGLExtension_NV_vertex_buffer_unified_memory::glIndexFormatNV(GLenum type, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+ d->IndexFormatNV(type, stride);
+}
+
+inline void QOpenGLExtension_NV_vertex_buffer_unified_memory::glColorFormatNV(GLint size, GLenum type, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+ d->ColorFormatNV(size, type, stride);
+}
+
+inline void QOpenGLExtension_NV_vertex_buffer_unified_memory::glNormalFormatNV(GLenum type, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+ d->NormalFormatNV(type, stride);
+}
+
+inline void QOpenGLExtension_NV_vertex_buffer_unified_memory::glVertexFormatNV(GLint size, GLenum type, GLsizei stride)
+{
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+ d->VertexFormatNV(size, type, stride);
+}
+
+inline void QOpenGLExtension_NV_vertex_buffer_unified_memory::glBufferAddressRangeNV(GLenum pname, GLuint index, GLuint64EXT address, GLsizeiptr length)
+{
+ Q_D(QOpenGLExtension_NV_vertex_buffer_unified_memory);
+ d->BufferAddressRangeNV(pname, index, address, length);
+}
+
+class QOpenGLExtension_NV_vertex_programPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VertexAttribs4ubvNV)(GLuint index, GLsizei count, const GLubyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs4svNV)(GLuint index, GLsizei count, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs4fvNV)(GLuint index, GLsizei count, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs4dvNV)(GLuint index, GLsizei count, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs3svNV)(GLuint index, GLsizei count, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs3fvNV)(GLuint index, GLsizei count, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs3dvNV)(GLuint index, GLsizei count, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs2svNV)(GLuint index, GLsizei count, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs2fvNV)(GLuint index, GLsizei count, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs2dvNV)(GLuint index, GLsizei count, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs1svNV)(GLuint index, GLsizei count, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs1fvNV)(GLuint index, GLsizei count, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttribs1dvNV)(GLuint index, GLsizei count, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4ubvNV)(GLuint index, const GLubyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4ubNV)(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void (QOPENGLF_APIENTRYP VertexAttrib4svNV)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4sNV)(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void (QOPENGLF_APIENTRYP VertexAttrib4fvNV)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4fNV)(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP VertexAttrib4dvNV)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib4dNV)(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP VertexAttrib3svNV)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib3sNV)(GLuint index, GLshort x, GLshort y, GLshort z);
+ void (QOPENGLF_APIENTRYP VertexAttrib3fvNV)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib3fNV)(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP VertexAttrib3dvNV)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib3dNV)(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void (QOPENGLF_APIENTRYP VertexAttrib2svNV)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib2sNV)(GLuint index, GLshort x, GLshort y);
+ void (QOPENGLF_APIENTRYP VertexAttrib2fvNV)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib2fNV)(GLuint index, GLfloat x, GLfloat y);
+ void (QOPENGLF_APIENTRYP VertexAttrib2dvNV)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib2dNV)(GLuint index, GLdouble x, GLdouble y);
+ void (QOPENGLF_APIENTRYP VertexAttrib1svNV)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib1sNV)(GLuint index, GLshort x);
+ void (QOPENGLF_APIENTRYP VertexAttrib1fvNV)(GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib1fNV)(GLuint index, GLfloat x);
+ void (QOPENGLF_APIENTRYP VertexAttrib1dvNV)(GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP VertexAttrib1dNV)(GLuint index, GLdouble x);
+ void (QOPENGLF_APIENTRYP VertexAttribPointerNV)(GLuint index, GLint fsize, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP TrackMatrixNV)(GLenum target, GLuint address, GLenum matrix, GLenum transform);
+ void (QOPENGLF_APIENTRYP RequestResidentProgramsNV)(GLsizei n, const GLuint *programs);
+ void (QOPENGLF_APIENTRYP ProgramParameters4fvNV)(GLenum target, GLuint index, GLsizei count, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ProgramParameters4dvNV)(GLenum target, GLuint index, GLsizei count, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP ProgramParameter4fvNV)(GLenum target, GLuint index, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ProgramParameter4fNV)(GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP ProgramParameter4dvNV)(GLenum target, GLuint index, const GLdouble *v);
+ void (QOPENGLF_APIENTRYP ProgramParameter4dNV)(GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void (QOPENGLF_APIENTRYP LoadProgramNV)(GLenum target, GLuint id, GLsizei len, const GLubyte *program);
+ GLboolean (QOPENGLF_APIENTRYP IsProgramNV)(GLuint id);
+ void (QOPENGLF_APIENTRYP GetVertexAttribPointervNV)(GLuint index, GLenum pname, GLvoid* *pointer);
+ void (QOPENGLF_APIENTRYP GetVertexAttribivNV)(GLuint index, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetVertexAttribfvNV)(GLuint index, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetVertexAttribdvNV)(GLuint index, GLenum pname, GLdouble *params);
+ void (QOPENGLF_APIENTRYP GetTrackMatrixivNV)(GLenum target, GLuint address, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetProgramStringNV)(GLuint id, GLenum pname, GLubyte *program);
+ void (QOPENGLF_APIENTRYP GetProgramivNV)(GLuint id, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetProgramParameterfvNV)(GLenum target, GLuint index, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetProgramParameterdvNV)(GLenum target, GLuint index, GLenum pname, GLdouble *params);
+ void (QOPENGLF_APIENTRYP GenProgramsNV)(GLsizei n, GLuint *programs);
+ void (QOPENGLF_APIENTRYP ExecuteProgramNV)(GLenum target, GLuint id, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP DeleteProgramsNV)(GLsizei n, const GLuint *programs);
+ void (QOPENGLF_APIENTRYP BindProgramNV)(GLenum target, GLuint id);
+ GLboolean (QOPENGLF_APIENTRYP AreProgramsResidentNV)(GLsizei n, const GLuint *programs, GLboolean *residences);
+};
+
+class QOpenGLExtension_NV_vertex_program : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_vertex_program();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVertexAttribs4ubvNV(GLuint index, GLsizei count, const GLubyte *v);
+ void glVertexAttribs4svNV(GLuint index, GLsizei count, const GLshort *v);
+ void glVertexAttribs4fvNV(GLuint index, GLsizei count, const GLfloat *v);
+ void glVertexAttribs4dvNV(GLuint index, GLsizei count, const GLdouble *v);
+ void glVertexAttribs3svNV(GLuint index, GLsizei count, const GLshort *v);
+ void glVertexAttribs3fvNV(GLuint index, GLsizei count, const GLfloat *v);
+ void glVertexAttribs3dvNV(GLuint index, GLsizei count, const GLdouble *v);
+ void glVertexAttribs2svNV(GLuint index, GLsizei count, const GLshort *v);
+ void glVertexAttribs2fvNV(GLuint index, GLsizei count, const GLfloat *v);
+ void glVertexAttribs2dvNV(GLuint index, GLsizei count, const GLdouble *v);
+ void glVertexAttribs1svNV(GLuint index, GLsizei count, const GLshort *v);
+ void glVertexAttribs1fvNV(GLuint index, GLsizei count, const GLfloat *v);
+ void glVertexAttribs1dvNV(GLuint index, GLsizei count, const GLdouble *v);
+ void glVertexAttrib4ubvNV(GLuint index, const GLubyte *v);
+ void glVertexAttrib4ubNV(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+ void glVertexAttrib4svNV(GLuint index, const GLshort *v);
+ void glVertexAttrib4sNV(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+ void glVertexAttrib4fvNV(GLuint index, const GLfloat *v);
+ void glVertexAttrib4fNV(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glVertexAttrib4dvNV(GLuint index, const GLdouble *v);
+ void glVertexAttrib4dNV(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glVertexAttrib3svNV(GLuint index, const GLshort *v);
+ void glVertexAttrib3sNV(GLuint index, GLshort x, GLshort y, GLshort z);
+ void glVertexAttrib3fvNV(GLuint index, const GLfloat *v);
+ void glVertexAttrib3fNV(GLuint index, GLfloat x, GLfloat y, GLfloat z);
+ void glVertexAttrib3dvNV(GLuint index, const GLdouble *v);
+ void glVertexAttrib3dNV(GLuint index, GLdouble x, GLdouble y, GLdouble z);
+ void glVertexAttrib2svNV(GLuint index, const GLshort *v);
+ void glVertexAttrib2sNV(GLuint index, GLshort x, GLshort y);
+ void glVertexAttrib2fvNV(GLuint index, const GLfloat *v);
+ void glVertexAttrib2fNV(GLuint index, GLfloat x, GLfloat y);
+ void glVertexAttrib2dvNV(GLuint index, const GLdouble *v);
+ void glVertexAttrib2dNV(GLuint index, GLdouble x, GLdouble y);
+ void glVertexAttrib1svNV(GLuint index, const GLshort *v);
+ void glVertexAttrib1sNV(GLuint index, GLshort x);
+ void glVertexAttrib1fvNV(GLuint index, const GLfloat *v);
+ void glVertexAttrib1fNV(GLuint index, GLfloat x);
+ void glVertexAttrib1dvNV(GLuint index, const GLdouble *v);
+ void glVertexAttrib1dNV(GLuint index, GLdouble x);
+ void glVertexAttribPointerNV(GLuint index, GLint fsize, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glTrackMatrixNV(GLenum target, GLuint address, GLenum matrix, GLenum transform);
+ void glRequestResidentProgramsNV(GLsizei n, const GLuint *programs);
+ void glProgramParameters4fvNV(GLenum target, GLuint index, GLsizei count, const GLfloat *v);
+ void glProgramParameters4dvNV(GLenum target, GLuint index, GLsizei count, const GLdouble *v);
+ void glProgramParameter4fvNV(GLenum target, GLuint index, const GLfloat *v);
+ void glProgramParameter4fNV(GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glProgramParameter4dvNV(GLenum target, GLuint index, const GLdouble *v);
+ void glProgramParameter4dNV(GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+ void glLoadProgramNV(GLenum target, GLuint id, GLsizei len, const GLubyte *program);
+ GLboolean glIsProgramNV(GLuint id);
+ void glGetVertexAttribPointervNV(GLuint index, GLenum pname, GLvoid* *pointer);
+ void glGetVertexAttribivNV(GLuint index, GLenum pname, GLint *params);
+ void glGetVertexAttribfvNV(GLuint index, GLenum pname, GLfloat *params);
+ void glGetVertexAttribdvNV(GLuint index, GLenum pname, GLdouble *params);
+ void glGetTrackMatrixivNV(GLenum target, GLuint address, GLenum pname, GLint *params);
+ void glGetProgramStringNV(GLuint id, GLenum pname, GLubyte *program);
+ void glGetProgramivNV(GLuint id, GLenum pname, GLint *params);
+ void glGetProgramParameterfvNV(GLenum target, GLuint index, GLenum pname, GLfloat *params);
+ void glGetProgramParameterdvNV(GLenum target, GLuint index, GLenum pname, GLdouble *params);
+ void glGenProgramsNV(GLsizei n, GLuint *programs);
+ void glExecuteProgramNV(GLenum target, GLuint id, const GLfloat *params);
+ void glDeleteProgramsNV(GLsizei n, const GLuint *programs);
+ void glBindProgramNV(GLenum target, GLuint id);
+ GLboolean glAreProgramsResidentNV(GLsizei n, const GLuint *programs, GLboolean *residences);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_vertex_program)
+};
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs4ubvNV(GLuint index, GLsizei count, const GLubyte *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs4ubvNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs4svNV(GLuint index, GLsizei count, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs4svNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs4fvNV(GLuint index, GLsizei count, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs4fvNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs4dvNV(GLuint index, GLsizei count, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs4dvNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs3svNV(GLuint index, GLsizei count, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs3svNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs3fvNV(GLuint index, GLsizei count, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs3fvNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs3dvNV(GLuint index, GLsizei count, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs3dvNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs2svNV(GLuint index, GLsizei count, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs2svNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs2fvNV(GLuint index, GLsizei count, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs2fvNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs2dvNV(GLuint index, GLsizei count, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs2dvNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs1svNV(GLuint index, GLsizei count, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs1svNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs1fvNV(GLuint index, GLsizei count, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs1fvNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribs1dvNV(GLuint index, GLsizei count, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribs1dvNV(index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib4ubvNV(GLuint index, const GLubyte *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib4ubvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib4ubNV(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib4ubNV(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib4svNV(GLuint index, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib4svNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib4sNV(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib4sNV(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib4fvNV(GLuint index, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib4fvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib4fNV(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib4fNV(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib4dvNV(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib4dvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib4dNV(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib4dNV(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib3svNV(GLuint index, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib3svNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib3sNV(GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib3sNV(index, x, y, z);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib3fvNV(GLuint index, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib3fvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib3fNV(GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib3fNV(index, x, y, z);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib3dvNV(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib3dvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib3dNV(GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib3dNV(index, x, y, z);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib2svNV(GLuint index, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib2svNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib2sNV(GLuint index, GLshort x, GLshort y)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib2sNV(index, x, y);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib2fvNV(GLuint index, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib2fvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib2fNV(GLuint index, GLfloat x, GLfloat y)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib2fNV(index, x, y);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib2dvNV(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib2dvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib2dNV(GLuint index, GLdouble x, GLdouble y)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib2dNV(index, x, y);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib1svNV(GLuint index, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib1svNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib1sNV(GLuint index, GLshort x)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib1sNV(index, x);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib1fvNV(GLuint index, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib1fvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib1fNV(GLuint index, GLfloat x)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib1fNV(index, x);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib1dvNV(GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib1dvNV(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttrib1dNV(GLuint index, GLdouble x)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttrib1dNV(index, x);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glVertexAttribPointerNV(GLuint index, GLint fsize, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->VertexAttribPointerNV(index, fsize, type, stride, pointer);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glTrackMatrixNV(GLenum target, GLuint address, GLenum matrix, GLenum transform)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->TrackMatrixNV(target, address, matrix, transform);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glRequestResidentProgramsNV(GLsizei n, const GLuint *programs)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->RequestResidentProgramsNV(n, programs);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glProgramParameters4fvNV(GLenum target, GLuint index, GLsizei count, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->ProgramParameters4fvNV(target, index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glProgramParameters4dvNV(GLenum target, GLuint index, GLsizei count, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->ProgramParameters4dvNV(target, index, count, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glProgramParameter4fvNV(GLenum target, GLuint index, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->ProgramParameter4fvNV(target, index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glProgramParameter4fNV(GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->ProgramParameter4fNV(target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glProgramParameter4dvNV(GLenum target, GLuint index, const GLdouble *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->ProgramParameter4dvNV(target, index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glProgramParameter4dNV(GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->ProgramParameter4dNV(target, index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glLoadProgramNV(GLenum target, GLuint id, GLsizei len, const GLubyte *program)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->LoadProgramNV(target, id, len, program);
+}
+
+inline GLboolean QOpenGLExtension_NV_vertex_program::glIsProgramNV(GLuint id)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ return d->IsProgramNV(id);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glGetVertexAttribPointervNV(GLuint index, GLenum pname, GLvoid* *pointer)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->GetVertexAttribPointervNV(index, pname, pointer);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glGetVertexAttribivNV(GLuint index, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->GetVertexAttribivNV(index, pname, params);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glGetVertexAttribfvNV(GLuint index, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->GetVertexAttribfvNV(index, pname, params);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glGetVertexAttribdvNV(GLuint index, GLenum pname, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->GetVertexAttribdvNV(index, pname, params);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glGetTrackMatrixivNV(GLenum target, GLuint address, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->GetTrackMatrixivNV(target, address, pname, params);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glGetProgramStringNV(GLuint id, GLenum pname, GLubyte *program)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->GetProgramStringNV(id, pname, program);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glGetProgramivNV(GLuint id, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->GetProgramivNV(id, pname, params);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glGetProgramParameterfvNV(GLenum target, GLuint index, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->GetProgramParameterfvNV(target, index, pname, params);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glGetProgramParameterdvNV(GLenum target, GLuint index, GLenum pname, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->GetProgramParameterdvNV(target, index, pname, params);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glGenProgramsNV(GLsizei n, GLuint *programs)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->GenProgramsNV(n, programs);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glExecuteProgramNV(GLenum target, GLuint id, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->ExecuteProgramNV(target, id, params);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glDeleteProgramsNV(GLsizei n, const GLuint *programs)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->DeleteProgramsNV(n, programs);
+}
+
+inline void QOpenGLExtension_NV_vertex_program::glBindProgramNV(GLenum target, GLuint id)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ d->BindProgramNV(target, id);
+}
+
+inline GLboolean QOpenGLExtension_NV_vertex_program::glAreProgramsResidentNV(GLsizei n, const GLuint *programs, GLboolean *residences)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program);
+ return d->AreProgramsResidentNV(n, programs, residences);
+}
+
+class QOpenGLExtension_NV_vertex_program4Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetVertexAttribIuivEXT)(GLuint index, GLenum pname, GLuint *params);
+ void (QOPENGLF_APIENTRYP GetVertexAttribIivEXT)(GLuint index, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP VertexAttribIPointerEXT)(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void (QOPENGLF_APIENTRYP VertexAttribI4usvEXT)(GLuint index, const GLushort *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI4ubvEXT)(GLuint index, const GLubyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI4svEXT)(GLuint index, const GLshort *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI4bvEXT)(GLuint index, const GLbyte *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI4uivEXT)(GLuint index, const GLuint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI3uivEXT)(GLuint index, const GLuint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI2uivEXT)(GLuint index, const GLuint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI1uivEXT)(GLuint index, const GLuint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI4ivEXT)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI3ivEXT)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI2ivEXT)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI1ivEXT)(GLuint index, const GLint *v);
+ void (QOPENGLF_APIENTRYP VertexAttribI4uiEXT)(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void (QOPENGLF_APIENTRYP VertexAttribI3uiEXT)(GLuint index, GLuint x, GLuint y, GLuint z);
+ void (QOPENGLF_APIENTRYP VertexAttribI2uiEXT)(GLuint index, GLuint x, GLuint y);
+ void (QOPENGLF_APIENTRYP VertexAttribI1uiEXT)(GLuint index, GLuint x);
+ void (QOPENGLF_APIENTRYP VertexAttribI4iEXT)(GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void (QOPENGLF_APIENTRYP VertexAttribI3iEXT)(GLuint index, GLint x, GLint y, GLint z);
+ void (QOPENGLF_APIENTRYP VertexAttribI2iEXT)(GLuint index, GLint x, GLint y);
+ void (QOPENGLF_APIENTRYP VertexAttribI1iEXT)(GLuint index, GLint x);
+};
+
+class QOpenGLExtension_NV_vertex_program4 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_vertex_program4();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetVertexAttribIuivEXT(GLuint index, GLenum pname, GLuint *params);
+ void glGetVertexAttribIivEXT(GLuint index, GLenum pname, GLint *params);
+ void glVertexAttribIPointerEXT(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
+ void glVertexAttribI4usvEXT(GLuint index, const GLushort *v);
+ void glVertexAttribI4ubvEXT(GLuint index, const GLubyte *v);
+ void glVertexAttribI4svEXT(GLuint index, const GLshort *v);
+ void glVertexAttribI4bvEXT(GLuint index, const GLbyte *v);
+ void glVertexAttribI4uivEXT(GLuint index, const GLuint *v);
+ void glVertexAttribI3uivEXT(GLuint index, const GLuint *v);
+ void glVertexAttribI2uivEXT(GLuint index, const GLuint *v);
+ void glVertexAttribI1uivEXT(GLuint index, const GLuint *v);
+ void glVertexAttribI4ivEXT(GLuint index, const GLint *v);
+ void glVertexAttribI3ivEXT(GLuint index, const GLint *v);
+ void glVertexAttribI2ivEXT(GLuint index, const GLint *v);
+ void glVertexAttribI1ivEXT(GLuint index, const GLint *v);
+ void glVertexAttribI4uiEXT(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+ void glVertexAttribI3uiEXT(GLuint index, GLuint x, GLuint y, GLuint z);
+ void glVertexAttribI2uiEXT(GLuint index, GLuint x, GLuint y);
+ void glVertexAttribI1uiEXT(GLuint index, GLuint x);
+ void glVertexAttribI4iEXT(GLuint index, GLint x, GLint y, GLint z, GLint w);
+ void glVertexAttribI3iEXT(GLuint index, GLint x, GLint y, GLint z);
+ void glVertexAttribI2iEXT(GLuint index, GLint x, GLint y);
+ void glVertexAttribI1iEXT(GLuint index, GLint x);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_vertex_program4)
+};
+
+inline void QOpenGLExtension_NV_vertex_program4::glGetVertexAttribIuivEXT(GLuint index, GLenum pname, GLuint *params)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->GetVertexAttribIuivEXT(index, pname, params);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glGetVertexAttribIivEXT(GLuint index, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->GetVertexAttribIivEXT(index, pname, params);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribIPointerEXT(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid *pointer)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribIPointerEXT(index, size, type, stride, pointer);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI4usvEXT(GLuint index, const GLushort *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI4usvEXT(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI4ubvEXT(GLuint index, const GLubyte *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI4ubvEXT(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI4svEXT(GLuint index, const GLshort *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI4svEXT(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI4bvEXT(GLuint index, const GLbyte *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI4bvEXT(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI4uivEXT(GLuint index, const GLuint *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI4uivEXT(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI3uivEXT(GLuint index, const GLuint *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI3uivEXT(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI2uivEXT(GLuint index, const GLuint *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI2uivEXT(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI1uivEXT(GLuint index, const GLuint *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI1uivEXT(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI4ivEXT(GLuint index, const GLint *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI4ivEXT(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI3ivEXT(GLuint index, const GLint *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI3ivEXT(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI2ivEXT(GLuint index, const GLint *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI2ivEXT(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI1ivEXT(GLuint index, const GLint *v)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI1ivEXT(index, v);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI4uiEXT(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI4uiEXT(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI3uiEXT(GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI3uiEXT(index, x, y, z);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI2uiEXT(GLuint index, GLuint x, GLuint y)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI2uiEXT(index, x, y);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI1uiEXT(GLuint index, GLuint x)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI1uiEXT(index, x);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI4iEXT(GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI4iEXT(index, x, y, z, w);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI3iEXT(GLuint index, GLint x, GLint y, GLint z)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI3iEXT(index, x, y, z);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI2iEXT(GLuint index, GLint x, GLint y)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI2iEXT(index, x, y);
+}
+
+inline void QOpenGLExtension_NV_vertex_program4::glVertexAttribI1iEXT(GLuint index, GLint x)
+{
+ Q_D(QOpenGLExtension_NV_vertex_program4);
+ d->VertexAttribI1iEXT(index, x);
+}
+
+class QOpenGLExtension_NV_video_capturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP VideoCaptureStreamParameterdvNV)(GLuint video_capture_slot, GLuint stream, GLenum pname, const GLdouble *params);
+ void (QOPENGLF_APIENTRYP VideoCaptureStreamParameterfvNV)(GLuint video_capture_slot, GLuint stream, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP VideoCaptureStreamParameterivNV)(GLuint video_capture_slot, GLuint stream, GLenum pname, const GLint *params);
+ GLenum (QOPENGLF_APIENTRYP VideoCaptureNV)(GLuint video_capture_slot, GLuint *sequence_num, GLuint64EXT *capture_time);
+ void (QOPENGLF_APIENTRYP GetVideoCaptureStreamdvNV)(GLuint video_capture_slot, GLuint stream, GLenum pname, GLdouble *params);
+ void (QOPENGLF_APIENTRYP GetVideoCaptureStreamfvNV)(GLuint video_capture_slot, GLuint stream, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetVideoCaptureStreamivNV)(GLuint video_capture_slot, GLuint stream, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetVideoCaptureivNV)(GLuint video_capture_slot, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP EndVideoCaptureNV)(GLuint video_capture_slot);
+ void (QOPENGLF_APIENTRYP BindVideoCaptureStreamTextureNV)(GLuint video_capture_slot, GLuint stream, GLenum frame_region, GLenum target, GLuint texture);
+ void (QOPENGLF_APIENTRYP BindVideoCaptureStreamBufferNV)(GLuint video_capture_slot, GLuint stream, GLenum frame_region, GLintptrARB offset);
+ void (QOPENGLF_APIENTRYP BeginVideoCaptureNV)(GLuint video_capture_slot);
+};
+
+class QOpenGLExtension_NV_video_capture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_video_capture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glVideoCaptureStreamParameterdvNV(GLuint video_capture_slot, GLuint stream, GLenum pname, const GLdouble *params);
+ void glVideoCaptureStreamParameterfvNV(GLuint video_capture_slot, GLuint stream, GLenum pname, const GLfloat *params);
+ void glVideoCaptureStreamParameterivNV(GLuint video_capture_slot, GLuint stream, GLenum pname, const GLint *params);
+ GLenum glVideoCaptureNV(GLuint video_capture_slot, GLuint *sequence_num, GLuint64EXT *capture_time);
+ void glGetVideoCaptureStreamdvNV(GLuint video_capture_slot, GLuint stream, GLenum pname, GLdouble *params);
+ void glGetVideoCaptureStreamfvNV(GLuint video_capture_slot, GLuint stream, GLenum pname, GLfloat *params);
+ void glGetVideoCaptureStreamivNV(GLuint video_capture_slot, GLuint stream, GLenum pname, GLint *params);
+ void glGetVideoCaptureivNV(GLuint video_capture_slot, GLenum pname, GLint *params);
+ void glEndVideoCaptureNV(GLuint video_capture_slot);
+ void glBindVideoCaptureStreamTextureNV(GLuint video_capture_slot, GLuint stream, GLenum frame_region, GLenum target, GLuint texture);
+ void glBindVideoCaptureStreamBufferNV(GLuint video_capture_slot, GLuint stream, GLenum frame_region, GLintptrARB offset);
+ void glBeginVideoCaptureNV(GLuint video_capture_slot);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_video_capture)
+};
+
+inline void QOpenGLExtension_NV_video_capture::glVideoCaptureStreamParameterdvNV(GLuint video_capture_slot, GLuint stream, GLenum pname, const GLdouble *params)
+{
+ Q_D(QOpenGLExtension_NV_video_capture);
+ d->VideoCaptureStreamParameterdvNV(video_capture_slot, stream, pname, params);
+}
+
+inline void QOpenGLExtension_NV_video_capture::glVideoCaptureStreamParameterfvNV(GLuint video_capture_slot, GLuint stream, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_video_capture);
+ d->VideoCaptureStreamParameterfvNV(video_capture_slot, stream, pname, params);
+}
+
+inline void QOpenGLExtension_NV_video_capture::glVideoCaptureStreamParameterivNV(GLuint video_capture_slot, GLuint stream, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_video_capture);
+ d->VideoCaptureStreamParameterivNV(video_capture_slot, stream, pname, params);
+}
+
+inline GLenum QOpenGLExtension_NV_video_capture::glVideoCaptureNV(GLuint video_capture_slot, GLuint *sequence_num, GLuint64EXT *capture_time)
+{
+ Q_D(QOpenGLExtension_NV_video_capture);
+ return d->VideoCaptureNV(video_capture_slot, sequence_num, capture_time);
+}
+
+inline void QOpenGLExtension_NV_video_capture::glGetVideoCaptureStreamdvNV(GLuint video_capture_slot, GLuint stream, GLenum pname, GLdouble *params)
+{
+ Q_D(QOpenGLExtension_NV_video_capture);
+ d->GetVideoCaptureStreamdvNV(video_capture_slot, stream, pname, params);
+}
+
+inline void QOpenGLExtension_NV_video_capture::glGetVideoCaptureStreamfvNV(GLuint video_capture_slot, GLuint stream, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_NV_video_capture);
+ d->GetVideoCaptureStreamfvNV(video_capture_slot, stream, pname, params);
+}
+
+inline void QOpenGLExtension_NV_video_capture::glGetVideoCaptureStreamivNV(GLuint video_capture_slot, GLuint stream, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_video_capture);
+ d->GetVideoCaptureStreamivNV(video_capture_slot, stream, pname, params);
+}
+
+inline void QOpenGLExtension_NV_video_capture::glGetVideoCaptureivNV(GLuint video_capture_slot, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_video_capture);
+ d->GetVideoCaptureivNV(video_capture_slot, pname, params);
+}
+
+inline void QOpenGLExtension_NV_video_capture::glEndVideoCaptureNV(GLuint video_capture_slot)
+{
+ Q_D(QOpenGLExtension_NV_video_capture);
+ d->EndVideoCaptureNV(video_capture_slot);
+}
+
+inline void QOpenGLExtension_NV_video_capture::glBindVideoCaptureStreamTextureNV(GLuint video_capture_slot, GLuint stream, GLenum frame_region, GLenum target, GLuint texture)
+{
+ Q_D(QOpenGLExtension_NV_video_capture);
+ d->BindVideoCaptureStreamTextureNV(video_capture_slot, stream, frame_region, target, texture);
+}
+
+inline void QOpenGLExtension_NV_video_capture::glBindVideoCaptureStreamBufferNV(GLuint video_capture_slot, GLuint stream, GLenum frame_region, GLintptrARB offset)
+{
+ Q_D(QOpenGLExtension_NV_video_capture);
+ d->BindVideoCaptureStreamBufferNV(video_capture_slot, stream, frame_region, offset);
+}
+
+inline void QOpenGLExtension_NV_video_capture::glBeginVideoCaptureNV(GLuint video_capture_slot)
+{
+ Q_D(QOpenGLExtension_NV_video_capture);
+ d->BeginVideoCaptureNV(video_capture_slot);
+}
+
+class QOpenGLExtension_PGI_misc_hintsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP HintPGI)(GLenum target, GLint mode);
+};
+
+class QOpenGLExtension_PGI_misc_hints : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_PGI_misc_hints();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glHintPGI(GLenum target, GLint mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_PGI_misc_hints)
+};
+
+inline void QOpenGLExtension_PGI_misc_hints::glHintPGI(GLenum target, GLint mode)
+{
+ Q_D(QOpenGLExtension_PGI_misc_hints);
+ d->HintPGI(target, mode);
+}
+
+class QOpenGLExtension_SGIS_detail_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetDetailTexFuncSGIS)(GLenum target, GLfloat *points);
+ void (QOPENGLF_APIENTRYP DetailTexFuncSGIS)(GLenum target, GLsizei n, const GLfloat *points);
+};
+
+class QOpenGLExtension_SGIS_detail_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIS_detail_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetDetailTexFuncSGIS(GLenum target, GLfloat *points);
+ void glDetailTexFuncSGIS(GLenum target, GLsizei n, const GLfloat *points);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIS_detail_texture)
+};
+
+inline void QOpenGLExtension_SGIS_detail_texture::glGetDetailTexFuncSGIS(GLenum target, GLfloat *points)
+{
+ Q_D(QOpenGLExtension_SGIS_detail_texture);
+ d->GetDetailTexFuncSGIS(target, points);
+}
+
+inline void QOpenGLExtension_SGIS_detail_texture::glDetailTexFuncSGIS(GLenum target, GLsizei n, const GLfloat *points)
+{
+ Q_D(QOpenGLExtension_SGIS_detail_texture);
+ d->DetailTexFuncSGIS(target, n, points);
+}
+
+class QOpenGLExtension_SGIS_fog_functionPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetFogFuncSGIS)(GLfloat *points);
+ void (QOPENGLF_APIENTRYP FogFuncSGIS)(GLsizei n, const GLfloat *points);
+};
+
+class QOpenGLExtension_SGIS_fog_function : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIS_fog_function();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetFogFuncSGIS(GLfloat *points);
+ void glFogFuncSGIS(GLsizei n, const GLfloat *points);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIS_fog_function)
+};
+
+inline void QOpenGLExtension_SGIS_fog_function::glGetFogFuncSGIS(GLfloat *points)
+{
+ Q_D(QOpenGLExtension_SGIS_fog_function);
+ d->GetFogFuncSGIS(points);
+}
+
+inline void QOpenGLExtension_SGIS_fog_function::glFogFuncSGIS(GLsizei n, const GLfloat *points)
+{
+ Q_D(QOpenGLExtension_SGIS_fog_function);
+ d->FogFuncSGIS(n, points);
+}
+
+class QOpenGLExtension_SGIS_multisamplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP SamplePatternSGIS)(GLenum pattern);
+ void (QOPENGLF_APIENTRYP SampleMaskSGIS)(GLclampf value, GLboolean invert);
+};
+
+class QOpenGLExtension_SGIS_multisample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIS_multisample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glSamplePatternSGIS(GLenum pattern);
+ void glSampleMaskSGIS(GLclampf value, GLboolean invert);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIS_multisample)
+};
+
+inline void QOpenGLExtension_SGIS_multisample::glSamplePatternSGIS(GLenum pattern)
+{
+ Q_D(QOpenGLExtension_SGIS_multisample);
+ d->SamplePatternSGIS(pattern);
+}
+
+inline void QOpenGLExtension_SGIS_multisample::glSampleMaskSGIS(GLclampf value, GLboolean invert)
+{
+ Q_D(QOpenGLExtension_SGIS_multisample);
+ d->SampleMaskSGIS(value, invert);
+}
+
+class QOpenGLExtension_SGIS_pixel_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetPixelTexGenParameterfvSGIS)(GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetPixelTexGenParameterivSGIS)(GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP PixelTexGenParameterfvSGIS)(GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP PixelTexGenParameterfSGIS)(GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP PixelTexGenParameterivSGIS)(GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP PixelTexGenParameteriSGIS)(GLenum pname, GLint param);
+};
+
+class QOpenGLExtension_SGIS_pixel_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIS_pixel_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetPixelTexGenParameterfvSGIS(GLenum pname, GLfloat *params);
+ void glGetPixelTexGenParameterivSGIS(GLenum pname, GLint *params);
+ void glPixelTexGenParameterfvSGIS(GLenum pname, const GLfloat *params);
+ void glPixelTexGenParameterfSGIS(GLenum pname, GLfloat param);
+ void glPixelTexGenParameterivSGIS(GLenum pname, const GLint *params);
+ void glPixelTexGenParameteriSGIS(GLenum pname, GLint param);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIS_pixel_texture)
+};
+
+inline void QOpenGLExtension_SGIS_pixel_texture::glGetPixelTexGenParameterfvSGIS(GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGIS_pixel_texture);
+ d->GetPixelTexGenParameterfvSGIS(pname, params);
+}
+
+inline void QOpenGLExtension_SGIS_pixel_texture::glGetPixelTexGenParameterivSGIS(GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_SGIS_pixel_texture);
+ d->GetPixelTexGenParameterivSGIS(pname, params);
+}
+
+inline void QOpenGLExtension_SGIS_pixel_texture::glPixelTexGenParameterfvSGIS(GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGIS_pixel_texture);
+ d->PixelTexGenParameterfvSGIS(pname, params);
+}
+
+inline void QOpenGLExtension_SGIS_pixel_texture::glPixelTexGenParameterfSGIS(GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_SGIS_pixel_texture);
+ d->PixelTexGenParameterfSGIS(pname, param);
+}
+
+inline void QOpenGLExtension_SGIS_pixel_texture::glPixelTexGenParameterivSGIS(GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_SGIS_pixel_texture);
+ d->PixelTexGenParameterivSGIS(pname, params);
+}
+
+inline void QOpenGLExtension_SGIS_pixel_texture::glPixelTexGenParameteriSGIS(GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_SGIS_pixel_texture);
+ d->PixelTexGenParameteriSGIS(pname, param);
+}
+
+class QOpenGLExtension_SGIS_point_parametersPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP PointParameterfvSGIS)(GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP PointParameterfSGIS)(GLenum pname, GLfloat param);
+};
+
+class QOpenGLExtension_SGIS_point_parameters : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIS_point_parameters();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glPointParameterfvSGIS(GLenum pname, const GLfloat *params);
+ void glPointParameterfSGIS(GLenum pname, GLfloat param);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIS_point_parameters)
+};
+
+inline void QOpenGLExtension_SGIS_point_parameters::glPointParameterfvSGIS(GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGIS_point_parameters);
+ d->PointParameterfvSGIS(pname, params);
+}
+
+inline void QOpenGLExtension_SGIS_point_parameters::glPointParameterfSGIS(GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_SGIS_point_parameters);
+ d->PointParameterfSGIS(pname, param);
+}
+
+class QOpenGLExtension_SGIS_sharpen_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetSharpenTexFuncSGIS)(GLenum target, GLfloat *points);
+ void (QOPENGLF_APIENTRYP SharpenTexFuncSGIS)(GLenum target, GLsizei n, const GLfloat *points);
+};
+
+class QOpenGLExtension_SGIS_sharpen_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIS_sharpen_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetSharpenTexFuncSGIS(GLenum target, GLfloat *points);
+ void glSharpenTexFuncSGIS(GLenum target, GLsizei n, const GLfloat *points);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIS_sharpen_texture)
+};
+
+inline void QOpenGLExtension_SGIS_sharpen_texture::glGetSharpenTexFuncSGIS(GLenum target, GLfloat *points)
+{
+ Q_D(QOpenGLExtension_SGIS_sharpen_texture);
+ d->GetSharpenTexFuncSGIS(target, points);
+}
+
+inline void QOpenGLExtension_SGIS_sharpen_texture::glSharpenTexFuncSGIS(GLenum target, GLsizei n, const GLfloat *points)
+{
+ Q_D(QOpenGLExtension_SGIS_sharpen_texture);
+ d->SharpenTexFuncSGIS(target, n, points);
+}
+
+class QOpenGLExtension_SGIS_texture4DPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexSubImage4DSGIS)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint woffset, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLenum format, GLenum type, const GLvoid *pixels);
+ void (QOPENGLF_APIENTRYP TexImage4DSGIS)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+};
+
+class QOpenGLExtension_SGIS_texture4D : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIS_texture4D();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexSubImage4DSGIS(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint woffset, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLenum format, GLenum type, const GLvoid *pixels);
+ void glTexImage4DSGIS(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIS_texture4D)
+};
+
+inline void QOpenGLExtension_SGIS_texture4D::glTexSubImage4DSGIS(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint woffset, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_SGIS_texture4D);
+ d->TexSubImage4DSGIS(target, level, xoffset, yoffset, zoffset, woffset, width, height, depth, size4d, format, type, pixels);
+}
+
+inline void QOpenGLExtension_SGIS_texture4D::glTexImage4DSGIS(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLint border, GLenum format, GLenum type, const GLvoid *pixels)
+{
+ Q_D(QOpenGLExtension_SGIS_texture4D);
+ d->TexImage4DSGIS(target, level, internalformat, width, height, depth, size4d, border, format, type, pixels);
+}
+
+class QOpenGLExtension_SGIS_texture_color_maskPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TextureColorMaskSGIS)(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+};
+
+class QOpenGLExtension_SGIS_texture_color_mask : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIS_texture_color_mask();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTextureColorMaskSGIS(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIS_texture_color_mask)
+};
+
+inline void QOpenGLExtension_SGIS_texture_color_mask::glTextureColorMaskSGIS(GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ Q_D(QOpenGLExtension_SGIS_texture_color_mask);
+ d->TextureColorMaskSGIS(red, green, blue, alpha);
+}
+
+class QOpenGLExtension_SGIS_texture_filter4Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexFilterFuncSGIS)(GLenum target, GLenum filter, GLsizei n, const GLfloat *weights);
+ void (QOPENGLF_APIENTRYP GetTexFilterFuncSGIS)(GLenum target, GLenum filter, GLfloat *weights);
+};
+
+class QOpenGLExtension_SGIS_texture_filter4 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIS_texture_filter4();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexFilterFuncSGIS(GLenum target, GLenum filter, GLsizei n, const GLfloat *weights);
+ void glGetTexFilterFuncSGIS(GLenum target, GLenum filter, GLfloat *weights);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIS_texture_filter4)
+};
+
+inline void QOpenGLExtension_SGIS_texture_filter4::glTexFilterFuncSGIS(GLenum target, GLenum filter, GLsizei n, const GLfloat *weights)
+{
+ Q_D(QOpenGLExtension_SGIS_texture_filter4);
+ d->TexFilterFuncSGIS(target, filter, n, weights);
+}
+
+inline void QOpenGLExtension_SGIS_texture_filter4::glGetTexFilterFuncSGIS(GLenum target, GLenum filter, GLfloat *weights)
+{
+ Q_D(QOpenGLExtension_SGIS_texture_filter4);
+ d->GetTexFilterFuncSGIS(target, filter, weights);
+}
+
+class QOpenGLExtension_SGIX_asyncPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLboolean (QOPENGLF_APIENTRYP IsAsyncMarkerSGIX)(GLuint marker);
+ void (QOPENGLF_APIENTRYP DeleteAsyncMarkersSGIX)(GLuint marker, GLsizei range);
+ GLuint (QOPENGLF_APIENTRYP GenAsyncMarkersSGIX)(GLsizei range);
+ GLint (QOPENGLF_APIENTRYP PollAsyncSGIX)(GLuint *markerp);
+ GLint (QOPENGLF_APIENTRYP FinishAsyncSGIX)(GLuint *markerp);
+ void (QOPENGLF_APIENTRYP AsyncMarkerSGIX)(GLuint marker);
+};
+
+class QOpenGLExtension_SGIX_async : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIX_async();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLboolean glIsAsyncMarkerSGIX(GLuint marker);
+ void glDeleteAsyncMarkersSGIX(GLuint marker, GLsizei range);
+ GLuint glGenAsyncMarkersSGIX(GLsizei range);
+ GLint glPollAsyncSGIX(GLuint *markerp);
+ GLint glFinishAsyncSGIX(GLuint *markerp);
+ void glAsyncMarkerSGIX(GLuint marker);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIX_async)
+};
+
+inline GLboolean QOpenGLExtension_SGIX_async::glIsAsyncMarkerSGIX(GLuint marker)
+{
+ Q_D(QOpenGLExtension_SGIX_async);
+ return d->IsAsyncMarkerSGIX(marker);
+}
+
+inline void QOpenGLExtension_SGIX_async::glDeleteAsyncMarkersSGIX(GLuint marker, GLsizei range)
+{
+ Q_D(QOpenGLExtension_SGIX_async);
+ d->DeleteAsyncMarkersSGIX(marker, range);
+}
+
+inline GLuint QOpenGLExtension_SGIX_async::glGenAsyncMarkersSGIX(GLsizei range)
+{
+ Q_D(QOpenGLExtension_SGIX_async);
+ return d->GenAsyncMarkersSGIX(range);
+}
+
+inline GLint QOpenGLExtension_SGIX_async::glPollAsyncSGIX(GLuint *markerp)
+{
+ Q_D(QOpenGLExtension_SGIX_async);
+ return d->PollAsyncSGIX(markerp);
+}
+
+inline GLint QOpenGLExtension_SGIX_async::glFinishAsyncSGIX(GLuint *markerp)
+{
+ Q_D(QOpenGLExtension_SGIX_async);
+ return d->FinishAsyncSGIX(markerp);
+}
+
+inline void QOpenGLExtension_SGIX_async::glAsyncMarkerSGIX(GLuint marker)
+{
+ Q_D(QOpenGLExtension_SGIX_async);
+ d->AsyncMarkerSGIX(marker);
+}
+
+class QOpenGLExtension_SGIX_flush_rasterPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP FlushRasterSGIX)();
+};
+
+class QOpenGLExtension_SGIX_flush_raster : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIX_flush_raster();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glFlushRasterSGIX();
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIX_flush_raster)
+};
+
+inline void QOpenGLExtension_SGIX_flush_raster::glFlushRasterSGIX()
+{
+ Q_D(QOpenGLExtension_SGIX_flush_raster);
+ d->FlushRasterSGIX();
+}
+
+class QOpenGLExtension_SGIX_fragment_lightingPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP LightEnviSGIX)(GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP GetFragmentMaterialivSGIX)(GLenum face, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetFragmentMaterialfvSGIX)(GLenum face, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetFragmentLightivSGIX)(GLenum light, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetFragmentLightfvSGIX)(GLenum light, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP FragmentMaterialivSGIX)(GLenum face, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP FragmentMaterialiSGIX)(GLenum face, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP FragmentMaterialfvSGIX)(GLenum face, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP FragmentMaterialfSGIX)(GLenum face, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP FragmentLightModelivSGIX)(GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP FragmentLightModeliSGIX)(GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP FragmentLightModelfvSGIX)(GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP FragmentLightModelfSGIX)(GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP FragmentLightivSGIX)(GLenum light, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP FragmentLightiSGIX)(GLenum light, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP FragmentLightfvSGIX)(GLenum light, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP FragmentLightfSGIX)(GLenum light, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP FragmentColorMaterialSGIX)(GLenum face, GLenum mode);
+};
+
+class QOpenGLExtension_SGIX_fragment_lighting : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIX_fragment_lighting();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glLightEnviSGIX(GLenum pname, GLint param);
+ void glGetFragmentMaterialivSGIX(GLenum face, GLenum pname, GLint *params);
+ void glGetFragmentMaterialfvSGIX(GLenum face, GLenum pname, GLfloat *params);
+ void glGetFragmentLightivSGIX(GLenum light, GLenum pname, GLint *params);
+ void glGetFragmentLightfvSGIX(GLenum light, GLenum pname, GLfloat *params);
+ void glFragmentMaterialivSGIX(GLenum face, GLenum pname, const GLint *params);
+ void glFragmentMaterialiSGIX(GLenum face, GLenum pname, GLint param);
+ void glFragmentMaterialfvSGIX(GLenum face, GLenum pname, const GLfloat *params);
+ void glFragmentMaterialfSGIX(GLenum face, GLenum pname, GLfloat param);
+ void glFragmentLightModelivSGIX(GLenum pname, const GLint *params);
+ void glFragmentLightModeliSGIX(GLenum pname, GLint param);
+ void glFragmentLightModelfvSGIX(GLenum pname, const GLfloat *params);
+ void glFragmentLightModelfSGIX(GLenum pname, GLfloat param);
+ void glFragmentLightivSGIX(GLenum light, GLenum pname, const GLint *params);
+ void glFragmentLightiSGIX(GLenum light, GLenum pname, GLint param);
+ void glFragmentLightfvSGIX(GLenum light, GLenum pname, const GLfloat *params);
+ void glFragmentLightfSGIX(GLenum light, GLenum pname, GLfloat param);
+ void glFragmentColorMaterialSGIX(GLenum face, GLenum mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIX_fragment_lighting)
+};
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glLightEnviSGIX(GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->LightEnviSGIX(pname, param);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glGetFragmentMaterialivSGIX(GLenum face, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->GetFragmentMaterialivSGIX(face, pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glGetFragmentMaterialfvSGIX(GLenum face, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->GetFragmentMaterialfvSGIX(face, pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glGetFragmentLightivSGIX(GLenum light, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->GetFragmentLightivSGIX(light, pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glGetFragmentLightfvSGIX(GLenum light, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->GetFragmentLightfvSGIX(light, pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentMaterialivSGIX(GLenum face, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentMaterialivSGIX(face, pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentMaterialiSGIX(GLenum face, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentMaterialiSGIX(face, pname, param);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentMaterialfvSGIX(GLenum face, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentMaterialfvSGIX(face, pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentMaterialfSGIX(GLenum face, GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentMaterialfSGIX(face, pname, param);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentLightModelivSGIX(GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentLightModelivSGIX(pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentLightModeliSGIX(GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentLightModeliSGIX(pname, param);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentLightModelfvSGIX(GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentLightModelfvSGIX(pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentLightModelfSGIX(GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentLightModelfSGIX(pname, param);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentLightivSGIX(GLenum light, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentLightivSGIX(light, pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentLightiSGIX(GLenum light, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentLightiSGIX(light, pname, param);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentLightfvSGIX(GLenum light, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentLightfvSGIX(light, pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentLightfSGIX(GLenum light, GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentLightfSGIX(light, pname, param);
+}
+
+inline void QOpenGLExtension_SGIX_fragment_lighting::glFragmentColorMaterialSGIX(GLenum face, GLenum mode)
+{
+ Q_D(QOpenGLExtension_SGIX_fragment_lighting);
+ d->FragmentColorMaterialSGIX(face, mode);
+}
+
+class QOpenGLExtension_SGIX_framezoomPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP FrameZoomSGIX)(GLint factor);
+};
+
+class QOpenGLExtension_SGIX_framezoom : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIX_framezoom();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glFrameZoomSGIX(GLint factor);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIX_framezoom)
+};
+
+inline void QOpenGLExtension_SGIX_framezoom::glFrameZoomSGIX(GLint factor)
+{
+ Q_D(QOpenGLExtension_SGIX_framezoom);
+ d->FrameZoomSGIX(factor);
+}
+
+class QOpenGLExtension_SGIX_igloo_interfacePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP IglooInterfaceSGIX)(GLenum pname, const GLvoid *params);
+};
+
+class QOpenGLExtension_SGIX_igloo_interface : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIX_igloo_interface();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glIglooInterfaceSGIX(GLenum pname, const GLvoid *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIX_igloo_interface)
+};
+
+inline void QOpenGLExtension_SGIX_igloo_interface::glIglooInterfaceSGIX(GLenum pname, const GLvoid *params)
+{
+ Q_D(QOpenGLExtension_SGIX_igloo_interface);
+ d->IglooInterfaceSGIX(pname, params);
+}
+
+class QOpenGLExtension_SGIX_instrumentsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP StopInstrumentsSGIX)(GLint marker);
+ void (QOPENGLF_APIENTRYP StartInstrumentsSGIX)();
+ void (QOPENGLF_APIENTRYP ReadInstrumentsSGIX)(GLint marker);
+ GLint (QOPENGLF_APIENTRYP PollInstrumentsSGIX)(GLint *marker_p);
+ void (QOPENGLF_APIENTRYP InstrumentsBufferSGIX)(GLsizei size, GLint *buffer);
+ GLint (QOPENGLF_APIENTRYP GetInstrumentsSGIX)();
+};
+
+class QOpenGLExtension_SGIX_instruments : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIX_instruments();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glStopInstrumentsSGIX(GLint marker);
+ void glStartInstrumentsSGIX();
+ void glReadInstrumentsSGIX(GLint marker);
+ GLint glPollInstrumentsSGIX(GLint *marker_p);
+ void glInstrumentsBufferSGIX(GLsizei size, GLint *buffer);
+ GLint glGetInstrumentsSGIX();
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIX_instruments)
+};
+
+inline void QOpenGLExtension_SGIX_instruments::glStopInstrumentsSGIX(GLint marker)
+{
+ Q_D(QOpenGLExtension_SGIX_instruments);
+ d->StopInstrumentsSGIX(marker);
+}
+
+inline void QOpenGLExtension_SGIX_instruments::glStartInstrumentsSGIX()
+{
+ Q_D(QOpenGLExtension_SGIX_instruments);
+ d->StartInstrumentsSGIX();
+}
+
+inline void QOpenGLExtension_SGIX_instruments::glReadInstrumentsSGIX(GLint marker)
+{
+ Q_D(QOpenGLExtension_SGIX_instruments);
+ d->ReadInstrumentsSGIX(marker);
+}
+
+inline GLint QOpenGLExtension_SGIX_instruments::glPollInstrumentsSGIX(GLint *marker_p)
+{
+ Q_D(QOpenGLExtension_SGIX_instruments);
+ return d->PollInstrumentsSGIX(marker_p);
+}
+
+inline void QOpenGLExtension_SGIX_instruments::glInstrumentsBufferSGIX(GLsizei size, GLint *buffer)
+{
+ Q_D(QOpenGLExtension_SGIX_instruments);
+ d->InstrumentsBufferSGIX(size, buffer);
+}
+
+inline GLint QOpenGLExtension_SGIX_instruments::glGetInstrumentsSGIX()
+{
+ Q_D(QOpenGLExtension_SGIX_instruments);
+ return d->GetInstrumentsSGIX();
+}
+
+class QOpenGLExtension_SGIX_list_priorityPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ListParameterivSGIX)(GLuint list, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP ListParameteriSGIX)(GLuint list, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP ListParameterfvSGIX)(GLuint list, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP ListParameterfSGIX)(GLuint list, GLenum pname, GLfloat param);
+ void (QOPENGLF_APIENTRYP GetListParameterivSGIX)(GLuint list, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetListParameterfvSGIX)(GLuint list, GLenum pname, GLfloat *params);
+};
+
+class QOpenGLExtension_SGIX_list_priority : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIX_list_priority();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glListParameterivSGIX(GLuint list, GLenum pname, const GLint *params);
+ void glListParameteriSGIX(GLuint list, GLenum pname, GLint param);
+ void glListParameterfvSGIX(GLuint list, GLenum pname, const GLfloat *params);
+ void glListParameterfSGIX(GLuint list, GLenum pname, GLfloat param);
+ void glGetListParameterivSGIX(GLuint list, GLenum pname, GLint *params);
+ void glGetListParameterfvSGIX(GLuint list, GLenum pname, GLfloat *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIX_list_priority)
+};
+
+inline void QOpenGLExtension_SGIX_list_priority::glListParameterivSGIX(GLuint list, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_SGIX_list_priority);
+ d->ListParameterivSGIX(list, pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_list_priority::glListParameteriSGIX(GLuint list, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_SGIX_list_priority);
+ d->ListParameteriSGIX(list, pname, param);
+}
+
+inline void QOpenGLExtension_SGIX_list_priority::glListParameterfvSGIX(GLuint list, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGIX_list_priority);
+ d->ListParameterfvSGIX(list, pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_list_priority::glListParameterfSGIX(GLuint list, GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_SGIX_list_priority);
+ d->ListParameterfSGIX(list, pname, param);
+}
+
+inline void QOpenGLExtension_SGIX_list_priority::glGetListParameterivSGIX(GLuint list, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_SGIX_list_priority);
+ d->GetListParameterivSGIX(list, pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_list_priority::glGetListParameterfvSGIX(GLuint list, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGIX_list_priority);
+ d->GetListParameterfvSGIX(list, pname, params);
+}
+
+class QOpenGLExtension_SGIX_pixel_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP PixelTexGenSGIX)(GLenum mode);
+};
+
+class QOpenGLExtension_SGIX_pixel_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIX_pixel_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glPixelTexGenSGIX(GLenum mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIX_pixel_texture)
+};
+
+inline void QOpenGLExtension_SGIX_pixel_texture::glPixelTexGenSGIX(GLenum mode)
+{
+ Q_D(QOpenGLExtension_SGIX_pixel_texture);
+ d->PixelTexGenSGIX(mode);
+}
+
+class QOpenGLExtension_SGIX_polynomial_ffdPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP LoadIdentityDeformationMapSGIX)(GLbitfield mask);
+ void (QOPENGLF_APIENTRYP DeformSGIX)(GLbitfield mask);
+ void (QOPENGLF_APIENTRYP DeformationMap3fSGIX)(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, GLfloat w1, GLfloat w2, GLint wstride, GLint worder, const GLfloat *points);
+ void (QOPENGLF_APIENTRYP DeformationMap3dSGIX)(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, GLdouble w1, GLdouble w2, GLint wstride, GLint worder, const GLdouble *points);
+};
+
+class QOpenGLExtension_SGIX_polynomial_ffd : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIX_polynomial_ffd();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glLoadIdentityDeformationMapSGIX(GLbitfield mask);
+ void glDeformSGIX(GLbitfield mask);
+ void glDeformationMap3fSGIX(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, GLfloat w1, GLfloat w2, GLint wstride, GLint worder, const GLfloat *points);
+ void glDeformationMap3dSGIX(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, GLdouble w1, GLdouble w2, GLint wstride, GLint worder, const GLdouble *points);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIX_polynomial_ffd)
+};
+
+inline void QOpenGLExtension_SGIX_polynomial_ffd::glLoadIdentityDeformationMapSGIX(GLbitfield mask)
+{
+ Q_D(QOpenGLExtension_SGIX_polynomial_ffd);
+ d->LoadIdentityDeformationMapSGIX(mask);
+}
+
+inline void QOpenGLExtension_SGIX_polynomial_ffd::glDeformSGIX(GLbitfield mask)
+{
+ Q_D(QOpenGLExtension_SGIX_polynomial_ffd);
+ d->DeformSGIX(mask);
+}
+
+inline void QOpenGLExtension_SGIX_polynomial_ffd::glDeformationMap3fSGIX(GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, GLfloat w1, GLfloat w2, GLint wstride, GLint worder, const GLfloat *points)
+{
+ Q_D(QOpenGLExtension_SGIX_polynomial_ffd);
+ d->DeformationMap3fSGIX(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, w1, w2, wstride, worder, points);
+}
+
+inline void QOpenGLExtension_SGIX_polynomial_ffd::glDeformationMap3dSGIX(GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, GLdouble w1, GLdouble w2, GLint wstride, GLint worder, const GLdouble *points)
+{
+ Q_D(QOpenGLExtension_SGIX_polynomial_ffd);
+ d->DeformationMap3dSGIX(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, w1, w2, wstride, worder, points);
+}
+
+class QOpenGLExtension_SGIX_reference_planePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ReferencePlaneSGIX)(const GLdouble *equation);
+};
+
+class QOpenGLExtension_SGIX_reference_plane : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIX_reference_plane();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glReferencePlaneSGIX(const GLdouble *equation);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIX_reference_plane)
+};
+
+inline void QOpenGLExtension_SGIX_reference_plane::glReferencePlaneSGIX(const GLdouble *equation)
+{
+ Q_D(QOpenGLExtension_SGIX_reference_plane);
+ d->ReferencePlaneSGIX(equation);
+}
+
+class QOpenGLExtension_SGIX_spritePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP SpriteParameterivSGIX)(GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP SpriteParameteriSGIX)(GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP SpriteParameterfvSGIX)(GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP SpriteParameterfSGIX)(GLenum pname, GLfloat param);
+};
+
+class QOpenGLExtension_SGIX_sprite : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIX_sprite();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glSpriteParameterivSGIX(GLenum pname, const GLint *params);
+ void glSpriteParameteriSGIX(GLenum pname, GLint param);
+ void glSpriteParameterfvSGIX(GLenum pname, const GLfloat *params);
+ void glSpriteParameterfSGIX(GLenum pname, GLfloat param);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIX_sprite)
+};
+
+inline void QOpenGLExtension_SGIX_sprite::glSpriteParameterivSGIX(GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_SGIX_sprite);
+ d->SpriteParameterivSGIX(pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_sprite::glSpriteParameteriSGIX(GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_SGIX_sprite);
+ d->SpriteParameteriSGIX(pname, param);
+}
+
+inline void QOpenGLExtension_SGIX_sprite::glSpriteParameterfvSGIX(GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGIX_sprite);
+ d->SpriteParameterfvSGIX(pname, params);
+}
+
+inline void QOpenGLExtension_SGIX_sprite::glSpriteParameterfSGIX(GLenum pname, GLfloat param)
+{
+ Q_D(QOpenGLExtension_SGIX_sprite);
+ d->SpriteParameterfSGIX(pname, param);
+}
+
+class QOpenGLExtension_SGIX_tag_sample_bufferPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TagSampleBufferSGIX)();
+};
+
+class QOpenGLExtension_SGIX_tag_sample_buffer : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGIX_tag_sample_buffer();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTagSampleBufferSGIX();
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGIX_tag_sample_buffer)
+};
+
+inline void QOpenGLExtension_SGIX_tag_sample_buffer::glTagSampleBufferSGIX()
+{
+ Q_D(QOpenGLExtension_SGIX_tag_sample_buffer);
+ d->TagSampleBufferSGIX();
+}
+
+class QOpenGLExtension_SGI_color_tablePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetColorTableParameterivSGI)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetColorTableParameterfvSGI)(GLenum target, GLenum pname, GLfloat *params);
+ void (QOPENGLF_APIENTRYP GetColorTableSGI)(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void (QOPENGLF_APIENTRYP CopyColorTableSGI)(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void (QOPENGLF_APIENTRYP ColorTableParameterivSGI)(GLenum target, GLenum pname, const GLint *params);
+ void (QOPENGLF_APIENTRYP ColorTableParameterfvSGI)(GLenum target, GLenum pname, const GLfloat *params);
+ void (QOPENGLF_APIENTRYP ColorTableSGI)(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+};
+
+class QOpenGLExtension_SGI_color_table : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SGI_color_table();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetColorTableParameterivSGI(GLenum target, GLenum pname, GLint *params);
+ void glGetColorTableParameterfvSGI(GLenum target, GLenum pname, GLfloat *params);
+ void glGetColorTableSGI(GLenum target, GLenum format, GLenum type, GLvoid *table);
+ void glCopyColorTableSGI(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
+ void glColorTableParameterivSGI(GLenum target, GLenum pname, const GLint *params);
+ void glColorTableParameterfvSGI(GLenum target, GLenum pname, const GLfloat *params);
+ void glColorTableSGI(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SGI_color_table)
+};
+
+inline void QOpenGLExtension_SGI_color_table::glGetColorTableParameterivSGI(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_SGI_color_table);
+ d->GetColorTableParameterivSGI(target, pname, params);
+}
+
+inline void QOpenGLExtension_SGI_color_table::glGetColorTableParameterfvSGI(GLenum target, GLenum pname, GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGI_color_table);
+ d->GetColorTableParameterfvSGI(target, pname, params);
+}
+
+inline void QOpenGLExtension_SGI_color_table::glGetColorTableSGI(GLenum target, GLenum format, GLenum type, GLvoid *table)
+{
+ Q_D(QOpenGLExtension_SGI_color_table);
+ d->GetColorTableSGI(target, format, type, table);
+}
+
+inline void QOpenGLExtension_SGI_color_table::glCopyColorTableSGI(GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width)
+{
+ Q_D(QOpenGLExtension_SGI_color_table);
+ d->CopyColorTableSGI(target, internalformat, x, y, width);
+}
+
+inline void QOpenGLExtension_SGI_color_table::glColorTableParameterivSGI(GLenum target, GLenum pname, const GLint *params)
+{
+ Q_D(QOpenGLExtension_SGI_color_table);
+ d->ColorTableParameterivSGI(target, pname, params);
+}
+
+inline void QOpenGLExtension_SGI_color_table::glColorTableParameterfvSGI(GLenum target, GLenum pname, const GLfloat *params)
+{
+ Q_D(QOpenGLExtension_SGI_color_table);
+ d->ColorTableParameterfvSGI(target, pname, params);
+}
+
+inline void QOpenGLExtension_SGI_color_table::glColorTableSGI(GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table)
+{
+ Q_D(QOpenGLExtension_SGI_color_table);
+ d->ColorTableSGI(target, internalformat, width, format, type, table);
+}
+
+class QOpenGLExtension_SUNX_constant_dataPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP FinishTextureSUNX)();
+};
+
+class QOpenGLExtension_SUNX_constant_data : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SUNX_constant_data();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glFinishTextureSUNX();
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SUNX_constant_data)
+};
+
+inline void QOpenGLExtension_SUNX_constant_data::glFinishTextureSUNX()
+{
+ Q_D(QOpenGLExtension_SUNX_constant_data);
+ d->FinishTextureSUNX();
+}
+
+class QOpenGLExtension_SUN_global_alphaPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GlobalAlphaFactoruiSUN)(GLuint factor);
+ void (QOPENGLF_APIENTRYP GlobalAlphaFactorusSUN)(GLushort factor);
+ void (QOPENGLF_APIENTRYP GlobalAlphaFactorubSUN)(GLubyte factor);
+ void (QOPENGLF_APIENTRYP GlobalAlphaFactordSUN)(GLdouble factor);
+ void (QOPENGLF_APIENTRYP GlobalAlphaFactorfSUN)(GLfloat factor);
+ void (QOPENGLF_APIENTRYP GlobalAlphaFactoriSUN)(GLint factor);
+ void (QOPENGLF_APIENTRYP GlobalAlphaFactorsSUN)(GLshort factor);
+ void (QOPENGLF_APIENTRYP GlobalAlphaFactorbSUN)(GLbyte factor);
+};
+
+class QOpenGLExtension_SUN_global_alpha : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SUN_global_alpha();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGlobalAlphaFactoruiSUN(GLuint factor);
+ void glGlobalAlphaFactorusSUN(GLushort factor);
+ void glGlobalAlphaFactorubSUN(GLubyte factor);
+ void glGlobalAlphaFactordSUN(GLdouble factor);
+ void glGlobalAlphaFactorfSUN(GLfloat factor);
+ void glGlobalAlphaFactoriSUN(GLint factor);
+ void glGlobalAlphaFactorsSUN(GLshort factor);
+ void glGlobalAlphaFactorbSUN(GLbyte factor);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SUN_global_alpha)
+};
+
+inline void QOpenGLExtension_SUN_global_alpha::glGlobalAlphaFactoruiSUN(GLuint factor)
+{
+ Q_D(QOpenGLExtension_SUN_global_alpha);
+ d->GlobalAlphaFactoruiSUN(factor);
+}
+
+inline void QOpenGLExtension_SUN_global_alpha::glGlobalAlphaFactorusSUN(GLushort factor)
+{
+ Q_D(QOpenGLExtension_SUN_global_alpha);
+ d->GlobalAlphaFactorusSUN(factor);
+}
+
+inline void QOpenGLExtension_SUN_global_alpha::glGlobalAlphaFactorubSUN(GLubyte factor)
+{
+ Q_D(QOpenGLExtension_SUN_global_alpha);
+ d->GlobalAlphaFactorubSUN(factor);
+}
+
+inline void QOpenGLExtension_SUN_global_alpha::glGlobalAlphaFactordSUN(GLdouble factor)
+{
+ Q_D(QOpenGLExtension_SUN_global_alpha);
+ d->GlobalAlphaFactordSUN(factor);
+}
+
+inline void QOpenGLExtension_SUN_global_alpha::glGlobalAlphaFactorfSUN(GLfloat factor)
+{
+ Q_D(QOpenGLExtension_SUN_global_alpha);
+ d->GlobalAlphaFactorfSUN(factor);
+}
+
+inline void QOpenGLExtension_SUN_global_alpha::glGlobalAlphaFactoriSUN(GLint factor)
+{
+ Q_D(QOpenGLExtension_SUN_global_alpha);
+ d->GlobalAlphaFactoriSUN(factor);
+}
+
+inline void QOpenGLExtension_SUN_global_alpha::glGlobalAlphaFactorsSUN(GLshort factor)
+{
+ Q_D(QOpenGLExtension_SUN_global_alpha);
+ d->GlobalAlphaFactorsSUN(factor);
+}
+
+inline void QOpenGLExtension_SUN_global_alpha::glGlobalAlphaFactorbSUN(GLbyte factor)
+{
+ Q_D(QOpenGLExtension_SUN_global_alpha);
+ d->GlobalAlphaFactorbSUN(factor);
+}
+
+class QOpenGLExtension_SUN_mesh_arrayPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawMeshArraysSUN)(GLenum mode, GLint first, GLsizei count, GLsizei width);
+};
+
+class QOpenGLExtension_SUN_mesh_array : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SUN_mesh_array();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawMeshArraysSUN(GLenum mode, GLint first, GLsizei count, GLsizei width);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SUN_mesh_array)
+};
+
+inline void QOpenGLExtension_SUN_mesh_array::glDrawMeshArraysSUN(GLenum mode, GLint first, GLsizei count, GLsizei width)
+{
+ Q_D(QOpenGLExtension_SUN_mesh_array);
+ d->DrawMeshArraysSUN(mode, first, count, width);
+}
+
+class QOpenGLExtension_SUN_triangle_listPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ReplacementCodePointerSUN)(GLenum type, GLsizei stride, const GLvoid* *pointer);
+ void (QOPENGLF_APIENTRYP ReplacementCodeubvSUN)(const GLubyte *code);
+ void (QOPENGLF_APIENTRYP ReplacementCodeusvSUN)(const GLushort *code);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuivSUN)(const GLuint *code);
+ void (QOPENGLF_APIENTRYP ReplacementCodeubSUN)(GLubyte code);
+ void (QOPENGLF_APIENTRYP ReplacementCodeusSUN)(GLushort code);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiSUN)(GLuint code);
+};
+
+class QOpenGLExtension_SUN_triangle_list : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SUN_triangle_list();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glReplacementCodePointerSUN(GLenum type, GLsizei stride, const GLvoid* *pointer);
+ void glReplacementCodeubvSUN(const GLubyte *code);
+ void glReplacementCodeusvSUN(const GLushort *code);
+ void glReplacementCodeuivSUN(const GLuint *code);
+ void glReplacementCodeubSUN(GLubyte code);
+ void glReplacementCodeusSUN(GLushort code);
+ void glReplacementCodeuiSUN(GLuint code);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SUN_triangle_list)
+};
+
+inline void QOpenGLExtension_SUN_triangle_list::glReplacementCodePointerSUN(GLenum type, GLsizei stride, const GLvoid* *pointer)
+{
+ Q_D(QOpenGLExtension_SUN_triangle_list);
+ d->ReplacementCodePointerSUN(type, stride, pointer);
+}
+
+inline void QOpenGLExtension_SUN_triangle_list::glReplacementCodeubvSUN(const GLubyte *code)
+{
+ Q_D(QOpenGLExtension_SUN_triangle_list);
+ d->ReplacementCodeubvSUN(code);
+}
+
+inline void QOpenGLExtension_SUN_triangle_list::glReplacementCodeusvSUN(const GLushort *code)
+{
+ Q_D(QOpenGLExtension_SUN_triangle_list);
+ d->ReplacementCodeusvSUN(code);
+}
+
+inline void QOpenGLExtension_SUN_triangle_list::glReplacementCodeuivSUN(const GLuint *code)
+{
+ Q_D(QOpenGLExtension_SUN_triangle_list);
+ d->ReplacementCodeuivSUN(code);
+}
+
+inline void QOpenGLExtension_SUN_triangle_list::glReplacementCodeubSUN(GLubyte code)
+{
+ Q_D(QOpenGLExtension_SUN_triangle_list);
+ d->ReplacementCodeubSUN(code);
+}
+
+inline void QOpenGLExtension_SUN_triangle_list::glReplacementCodeusSUN(GLushort code)
+{
+ Q_D(QOpenGLExtension_SUN_triangle_list);
+ d->ReplacementCodeusSUN(code);
+}
+
+inline void QOpenGLExtension_SUN_triangle_list::glReplacementCodeuiSUN(GLuint code)
+{
+ Q_D(QOpenGLExtension_SUN_triangle_list);
+ d->ReplacementCodeuiSUN(code);
+}
+
+class QOpenGLExtension_SUN_vertexPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN)(const GLuint *rc, const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN)(GLuint rc, GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN)(const GLuint *rc, const GLfloat *tc, const GLfloat *n, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiTexCoord2fNormal3fVertex3fSUN)(GLuint rc, GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiTexCoord2fVertex3fvSUN)(const GLuint *rc, const GLfloat *tc, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiTexCoord2fVertex3fSUN)(GLuint rc, GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiColor4fNormal3fVertex3fvSUN)(const GLuint *rc, const GLfloat *c, const GLfloat *n, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiColor4fNormal3fVertex3fSUN)(GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiNormal3fVertex3fvSUN)(const GLuint *rc, const GLfloat *n, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiNormal3fVertex3fSUN)(GLuint rc, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiColor3fVertex3fvSUN)(const GLuint *rc, const GLfloat *c, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiColor3fVertex3fSUN)(GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiColor4ubVertex3fvSUN)(const GLuint *rc, const GLubyte *c, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiColor4ubVertex3fSUN)(GLuint rc, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiVertex3fvSUN)(const GLuint *rc, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP ReplacementCodeuiVertex3fSUN)(GLuint rc, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP TexCoord4fColor4fNormal3fVertex4fvSUN)(const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP TexCoord4fColor4fNormal3fVertex4fSUN)(GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP TexCoord2fColor4fNormal3fVertex3fvSUN)(const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP TexCoord2fColor4fNormal3fVertex3fSUN)(GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP TexCoord2fNormal3fVertex3fvSUN)(const GLfloat *tc, const GLfloat *n, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP TexCoord2fNormal3fVertex3fSUN)(GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP TexCoord2fColor3fVertex3fvSUN)(const GLfloat *tc, const GLfloat *c, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP TexCoord2fColor3fVertex3fSUN)(GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP TexCoord2fColor4ubVertex3fvSUN)(const GLfloat *tc, const GLubyte *c, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP TexCoord2fColor4ubVertex3fSUN)(GLfloat s, GLfloat t, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP TexCoord4fVertex4fvSUN)(const GLfloat *tc, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP TexCoord4fVertex4fSUN)(GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP TexCoord2fVertex3fvSUN)(const GLfloat *tc, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP TexCoord2fVertex3fSUN)(GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP Color4fNormal3fVertex3fvSUN)(const GLfloat *c, const GLfloat *n, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Color4fNormal3fVertex3fSUN)(GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP Normal3fVertex3fvSUN)(const GLfloat *n, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Normal3fVertex3fSUN)(GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP Color3fVertex3fvSUN)(const GLfloat *c, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Color3fVertex3fSUN)(GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP Color4ubVertex3fvSUN)(const GLubyte *c, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Color4ubVertex3fSUN)(GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP Color4ubVertex2fvSUN)(const GLubyte *c, const GLfloat *v);
+ void (QOPENGLF_APIENTRYP Color4ubVertex2fSUN)(GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y);
+};
+
+class QOpenGLExtension_SUN_vertex : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_SUN_vertex();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN(const GLuint *rc, const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v);
+ void glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN(GLuint rc, GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN(const GLuint *rc, const GLfloat *tc, const GLfloat *n, const GLfloat *v);
+ void glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN(GLuint rc, GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void glReplacementCodeuiTexCoord2fVertex3fvSUN(const GLuint *rc, const GLfloat *tc, const GLfloat *v);
+ void glReplacementCodeuiTexCoord2fVertex3fSUN(GLuint rc, GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z);
+ void glReplacementCodeuiColor4fNormal3fVertex3fvSUN(const GLuint *rc, const GLfloat *c, const GLfloat *n, const GLfloat *v);
+ void glReplacementCodeuiColor4fNormal3fVertex3fSUN(GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void glReplacementCodeuiNormal3fVertex3fvSUN(const GLuint *rc, const GLfloat *n, const GLfloat *v);
+ void glReplacementCodeuiNormal3fVertex3fSUN(GLuint rc, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void glReplacementCodeuiColor3fVertex3fvSUN(const GLuint *rc, const GLfloat *c, const GLfloat *v);
+ void glReplacementCodeuiColor3fVertex3fSUN(GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z);
+ void glReplacementCodeuiColor4ubVertex3fvSUN(const GLuint *rc, const GLubyte *c, const GLfloat *v);
+ void glReplacementCodeuiColor4ubVertex3fSUN(GLuint rc, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z);
+ void glReplacementCodeuiVertex3fvSUN(const GLuint *rc, const GLfloat *v);
+ void glReplacementCodeuiVertex3fSUN(GLuint rc, GLfloat x, GLfloat y, GLfloat z);
+ void glTexCoord4fColor4fNormal3fVertex4fvSUN(const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v);
+ void glTexCoord4fColor4fNormal3fVertex4fSUN(GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glTexCoord2fColor4fNormal3fVertex3fvSUN(const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v);
+ void glTexCoord2fColor4fNormal3fVertex3fSUN(GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void glTexCoord2fNormal3fVertex3fvSUN(const GLfloat *tc, const GLfloat *n, const GLfloat *v);
+ void glTexCoord2fNormal3fVertex3fSUN(GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void glTexCoord2fColor3fVertex3fvSUN(const GLfloat *tc, const GLfloat *c, const GLfloat *v);
+ void glTexCoord2fColor3fVertex3fSUN(GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z);
+ void glTexCoord2fColor4ubVertex3fvSUN(const GLfloat *tc, const GLubyte *c, const GLfloat *v);
+ void glTexCoord2fColor4ubVertex3fSUN(GLfloat s, GLfloat t, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z);
+ void glTexCoord4fVertex4fvSUN(const GLfloat *tc, const GLfloat *v);
+ void glTexCoord4fVertex4fSUN(GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glTexCoord2fVertex3fvSUN(const GLfloat *tc, const GLfloat *v);
+ void glTexCoord2fVertex3fSUN(GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z);
+ void glColor4fNormal3fVertex3fvSUN(const GLfloat *c, const GLfloat *n, const GLfloat *v);
+ void glColor4fNormal3fVertex3fSUN(GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void glNormal3fVertex3fvSUN(const GLfloat *n, const GLfloat *v);
+ void glNormal3fVertex3fSUN(GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
+ void glColor3fVertex3fvSUN(const GLfloat *c, const GLfloat *v);
+ void glColor3fVertex3fSUN(GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z);
+ void glColor4ubVertex3fvSUN(const GLubyte *c, const GLfloat *v);
+ void glColor4ubVertex3fSUN(GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z);
+ void glColor4ubVertex2fvSUN(const GLubyte *c, const GLfloat *v);
+ void glColor4ubVertex2fSUN(GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_SUN_vertex)
+};
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN(const GLuint *rc, const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN(rc, tc, c, n, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN(GLuint rc, GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN(rc, s, t, r, g, b, a, nx, ny, nz, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN(const GLuint *rc, const GLfloat *tc, const GLfloat *n, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN(rc, tc, n, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN(GLuint rc, GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiTexCoord2fNormal3fVertex3fSUN(rc, s, t, nx, ny, nz, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiTexCoord2fVertex3fvSUN(const GLuint *rc, const GLfloat *tc, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiTexCoord2fVertex3fvSUN(rc, tc, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiTexCoord2fVertex3fSUN(GLuint rc, GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiTexCoord2fVertex3fSUN(rc, s, t, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiColor4fNormal3fVertex3fvSUN(const GLuint *rc, const GLfloat *c, const GLfloat *n, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiColor4fNormal3fVertex3fvSUN(rc, c, n, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiColor4fNormal3fVertex3fSUN(GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiColor4fNormal3fVertex3fSUN(rc, r, g, b, a, nx, ny, nz, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiNormal3fVertex3fvSUN(const GLuint *rc, const GLfloat *n, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiNormal3fVertex3fvSUN(rc, n, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiNormal3fVertex3fSUN(GLuint rc, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiNormal3fVertex3fSUN(rc, nx, ny, nz, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiColor3fVertex3fvSUN(const GLuint *rc, const GLfloat *c, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiColor3fVertex3fvSUN(rc, c, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiColor3fVertex3fSUN(GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiColor3fVertex3fSUN(rc, r, g, b, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiColor4ubVertex3fvSUN(const GLuint *rc, const GLubyte *c, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiColor4ubVertex3fvSUN(rc, c, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiColor4ubVertex3fSUN(GLuint rc, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiColor4ubVertex3fSUN(rc, r, g, b, a, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiVertex3fvSUN(const GLuint *rc, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiVertex3fvSUN(rc, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glReplacementCodeuiVertex3fSUN(GLuint rc, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->ReplacementCodeuiVertex3fSUN(rc, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord4fColor4fNormal3fVertex4fvSUN(const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord4fColor4fNormal3fVertex4fvSUN(tc, c, n, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord4fColor4fNormal3fVertex4fSUN(GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord4fColor4fNormal3fVertex4fSUN(s, t, p, q, r, g, b, a, nx, ny, nz, x, y, z, w);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord2fColor4fNormal3fVertex3fvSUN(const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord2fColor4fNormal3fVertex3fvSUN(tc, c, n, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord2fColor4fNormal3fVertex3fSUN(GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord2fColor4fNormal3fVertex3fSUN(s, t, r, g, b, a, nx, ny, nz, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord2fNormal3fVertex3fvSUN(const GLfloat *tc, const GLfloat *n, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord2fNormal3fVertex3fvSUN(tc, n, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord2fNormal3fVertex3fSUN(GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord2fNormal3fVertex3fSUN(s, t, nx, ny, nz, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord2fColor3fVertex3fvSUN(const GLfloat *tc, const GLfloat *c, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord2fColor3fVertex3fvSUN(tc, c, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord2fColor3fVertex3fSUN(GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord2fColor3fVertex3fSUN(s, t, r, g, b, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord2fColor4ubVertex3fvSUN(const GLfloat *tc, const GLubyte *c, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord2fColor4ubVertex3fvSUN(tc, c, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord2fColor4ubVertex3fSUN(GLfloat s, GLfloat t, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord2fColor4ubVertex3fSUN(s, t, r, g, b, a, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord4fVertex4fvSUN(const GLfloat *tc, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord4fVertex4fvSUN(tc, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord4fVertex4fSUN(GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord4fVertex4fSUN(s, t, p, q, x, y, z, w);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord2fVertex3fvSUN(const GLfloat *tc, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord2fVertex3fvSUN(tc, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glTexCoord2fVertex3fSUN(GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->TexCoord2fVertex3fSUN(s, t, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glColor4fNormal3fVertex3fvSUN(const GLfloat *c, const GLfloat *n, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->Color4fNormal3fVertex3fvSUN(c, n, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glColor4fNormal3fVertex3fSUN(GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->Color4fNormal3fVertex3fSUN(r, g, b, a, nx, ny, nz, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glNormal3fVertex3fvSUN(const GLfloat *n, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->Normal3fVertex3fvSUN(n, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glNormal3fVertex3fSUN(GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->Normal3fVertex3fSUN(nx, ny, nz, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glColor3fVertex3fvSUN(const GLfloat *c, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->Color3fVertex3fvSUN(c, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glColor3fVertex3fSUN(GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->Color3fVertex3fSUN(r, g, b, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glColor4ubVertex3fvSUN(const GLubyte *c, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->Color4ubVertex3fvSUN(c, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glColor4ubVertex3fSUN(GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->Color4ubVertex3fSUN(r, g, b, a, x, y, z);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glColor4ubVertex2fvSUN(const GLubyte *c, const GLfloat *v)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->Color4ubVertex2fvSUN(c, v);
+}
+
+inline void QOpenGLExtension_SUN_vertex::glColor4ubVertex2fSUN(GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y)
+{
+ Q_D(QOpenGLExtension_SUN_vertex);
+ d->Color4ubVertex2fSUN(r, g, b, a, x, y);
+}
+
+
+#else
+
+class QOpenGLExtension_OES_EGL_imagePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP EGLImageTargetTexture2DOES)(GLenum target, GLeglImageOES image);
+ void (QOPENGLF_APIENTRYP EGLImageTargetRenderbufferStorageOES)(GLenum target, GLeglImageOES image);
+};
+
+class QOpenGLExtension_OES_EGL_image : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_OES_EGL_image();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glEGLImageTargetTexture2DOES(GLenum target, GLeglImageOES image);
+ void glEGLImageTargetRenderbufferStorageOES(GLenum target, GLeglImageOES image);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_OES_EGL_image)
+};
+
+inline void QOpenGLExtension_OES_EGL_image::glEGLImageTargetTexture2DOES(GLenum target, GLeglImageOES image)
+{
+ Q_D(QOpenGLExtension_OES_EGL_image);
+ d->EGLImageTargetTexture2DOES(target, image);
+}
+
+inline void QOpenGLExtension_OES_EGL_image::glEGLImageTargetRenderbufferStorageOES(GLenum target, GLeglImageOES image)
+{
+ Q_D(QOpenGLExtension_OES_EGL_image);
+ d->EGLImageTargetRenderbufferStorageOES(target, image);
+}
+
+class QOpenGLExtension_OES_get_program_binaryPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetProgramBinaryOES)(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+ void (QOPENGLF_APIENTRYP ProgramBinaryOES)(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLint length);
+};
+
+class QOpenGLExtension_OES_get_program_binary : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_OES_get_program_binary();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetProgramBinaryOES(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+ void glProgramBinaryOES(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLint length);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_OES_get_program_binary)
+};
+
+inline void QOpenGLExtension_OES_get_program_binary::glGetProgramBinaryOES(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary)
+{
+ Q_D(QOpenGLExtension_OES_get_program_binary);
+ d->GetProgramBinaryOES(program, bufSize, length, binaryFormat, binary);
+}
+
+inline void QOpenGLExtension_OES_get_program_binary::glProgramBinaryOES(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLint length)
+{
+ Q_D(QOpenGLExtension_OES_get_program_binary);
+ d->ProgramBinaryOES(program, binaryFormat, binary, length);
+}
+
+class QOpenGLExtension_OES_mapbufferPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void* (QOPENGLF_APIENTRYP MapBufferOES)(GLenum target, GLenum access);
+ GLboolean (QOPENGLF_APIENTRYP UnmapBufferOES)(GLenum target);
+ void (QOPENGLF_APIENTRYP GetBufferPointervOES)(GLenum target, GLenum pname, GLvoid** params);
+};
+
+class QOpenGLExtension_OES_mapbuffer : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_OES_mapbuffer();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void* glMapBufferOES(GLenum target, GLenum access);
+ GLboolean glUnmapBufferOES(GLenum target);
+ void glGetBufferPointervOES(GLenum target, GLenum pname, GLvoid** params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_OES_mapbuffer)
+};
+
+inline void *QOpenGLExtension_OES_mapbuffer::glMapBufferOES(GLenum target, GLenum access)
+{
+ Q_D(QOpenGLExtension_OES_mapbuffer);
+ return d->MapBufferOES(target, access);
+}
+
+inline GLboolean QOpenGLExtension_OES_mapbuffer::glUnmapBufferOES(GLenum target)
+{
+ Q_D(QOpenGLExtension_OES_mapbuffer);
+ return d->UnmapBufferOES(target);
+}
+
+inline void QOpenGLExtension_OES_mapbuffer::glGetBufferPointervOES(GLenum target, GLenum pname, GLvoid** params)
+{
+ Q_D(QOpenGLExtension_OES_mapbuffer);
+ d->GetBufferPointervOES(target, pname, params);
+}
+
+class QOpenGLExtension_OES_texture_3DPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexImage3DOES)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid* pixels);
+ void (QOPENGLF_APIENTRYP TexSubImage3DOES)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid* pixels);
+ void (QOPENGLF_APIENTRYP CopyTexSubImage3DOES)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP CompressedTexImage3DOES)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+ void (QOPENGLF_APIENTRYP CompressedTexSubImage3DOES)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+ void (QOPENGLF_APIENTRYP FramebufferTexture3DOES)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+};
+
+class QOpenGLExtension_OES_texture_3D : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_OES_texture_3D();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexImage3DOES(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid* pixels);
+ void glTexSubImage3DOES(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid* pixels);
+ void glCopyTexSubImage3DOES(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCompressedTexImage3DOES(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+ void glCompressedTexSubImage3DOES(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+ void glFramebufferTexture3DOES(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_OES_texture_3D)
+};
+
+inline void QOpenGLExtension_OES_texture_3D::glTexImage3DOES(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid* pixels)
+{
+ Q_D(QOpenGLExtension_OES_texture_3D);
+ d->TexImage3DOES(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLExtension_OES_texture_3D::glTexSubImage3DOES(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid* pixels)
+{
+ Q_D(QOpenGLExtension_OES_texture_3D);
+ d->TexSubImage3DOES(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLExtension_OES_texture_3D::glCopyTexSubImage3DOES(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_OES_texture_3D);
+ d->CopyTexSubImage3DOES(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLExtension_OES_texture_3D::glCompressedTexImage3DOES(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ Q_D(QOpenGLExtension_OES_texture_3D);
+ d->CompressedTexImage3DOES(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLExtension_OES_texture_3D::glCompressedTexSubImage3DOES(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ Q_D(QOpenGLExtension_OES_texture_3D);
+ d->CompressedTexSubImage3DOES(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLExtension_OES_texture_3D::glFramebufferTexture3DOES(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ Q_D(QOpenGLExtension_OES_texture_3D);
+ d->FramebufferTexture3DOES(target, attachment, textarget, texture, level, zoffset);
+}
+
+class QOpenGLExtension_OES_vertex_array_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BindVertexArrayOES)(GLuint array);
+ void (QOPENGLF_APIENTRYP DeleteVertexArraysOES)(GLsizei n, const GLuint *arrays);
+ void (QOPENGLF_APIENTRYP GenVertexArraysOES)(GLsizei n, GLuint *arrays);
+ GLboolean (QOPENGLF_APIENTRYP IsVertexArrayOES)(GLuint array);
+};
+
+class QOpenGLExtension_OES_vertex_array_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_OES_vertex_array_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBindVertexArrayOES(GLuint array);
+ void glDeleteVertexArraysOES(GLsizei n, const GLuint *arrays);
+ void glGenVertexArraysOES(GLsizei n, GLuint *arrays);
+ GLboolean glIsVertexArrayOES(GLuint array);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_OES_vertex_array_object)
+};
+
+inline void QOpenGLExtension_OES_vertex_array_object::glBindVertexArrayOES(GLuint array)
+{
+ Q_D(QOpenGLExtension_OES_vertex_array_object);
+ d->BindVertexArrayOES(array);
+}
+
+inline void QOpenGLExtension_OES_vertex_array_object::glDeleteVertexArraysOES(GLsizei n, const GLuint *arrays)
+{
+ Q_D(QOpenGLExtension_OES_vertex_array_object);
+ d->DeleteVertexArraysOES(n, arrays);
+}
+
+inline void QOpenGLExtension_OES_vertex_array_object::glGenVertexArraysOES(GLsizei n, GLuint *arrays)
+{
+ Q_D(QOpenGLExtension_OES_vertex_array_object);
+ d->GenVertexArraysOES(n, arrays);
+}
+
+inline GLboolean QOpenGLExtension_OES_vertex_array_object::glIsVertexArrayOES(GLuint array)
+{
+ Q_D(QOpenGLExtension_OES_vertex_array_object);
+ return d->IsVertexArrayOES(array);
+}
+
+class QOpenGLExtension_AMD_performance_monitorPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetPerfMonitorGroupsAMD)(GLint *numGroups, GLsizei groupsSize, GLuint *groups);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorCountersAMD)(GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorGroupStringAMD)(GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorCounterStringAMD)(GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorCounterInfoAMD)(GLuint group, GLuint counter, GLenum pname, GLvoid *data);
+ void (QOPENGLF_APIENTRYP GenPerfMonitorsAMD)(GLsizei n, GLuint *monitors);
+ void (QOPENGLF_APIENTRYP DeletePerfMonitorsAMD)(GLsizei n, GLuint *monitors);
+ void (QOPENGLF_APIENTRYP SelectPerfMonitorCountersAMD)(GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *countersList);
+ void (QOPENGLF_APIENTRYP BeginPerfMonitorAMD)(GLuint monitor);
+ void (QOPENGLF_APIENTRYP EndPerfMonitorAMD)(GLuint monitor);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorCounterDataAMD)(GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten);
+};
+
+class QOpenGLExtension_AMD_performance_monitor : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_AMD_performance_monitor();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetPerfMonitorGroupsAMD(GLint *numGroups, GLsizei groupsSize, GLuint *groups);
+ void glGetPerfMonitorCountersAMD(GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters);
+ void glGetPerfMonitorGroupStringAMD(GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString);
+ void glGetPerfMonitorCounterStringAMD(GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString);
+ void glGetPerfMonitorCounterInfoAMD(GLuint group, GLuint counter, GLenum pname, GLvoid *data);
+ void glGenPerfMonitorsAMD(GLsizei n, GLuint *monitors);
+ void glDeletePerfMonitorsAMD(GLsizei n, GLuint *monitors);
+ void glSelectPerfMonitorCountersAMD(GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *countersList);
+ void glBeginPerfMonitorAMD(GLuint monitor);
+ void glEndPerfMonitorAMD(GLuint monitor);
+ void glGetPerfMonitorCounterDataAMD(GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_AMD_performance_monitor)
+};
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorGroupsAMD(GLint *numGroups, GLsizei groupsSize, GLuint *groups)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorGroupsAMD(numGroups, groupsSize, groups);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorCountersAMD(GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorCountersAMD(group, numCounters, maxActiveCounters, counterSize, counters);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorGroupStringAMD(GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorGroupStringAMD(group, bufSize, length, groupString);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorCounterStringAMD(GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorCounterStringAMD(group, counter, bufSize, length, counterString);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorCounterInfoAMD(GLuint group, GLuint counter, GLenum pname, GLvoid *data)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorCounterInfoAMD(group, counter, pname, data);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGenPerfMonitorsAMD(GLsizei n, GLuint *monitors)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GenPerfMonitorsAMD(n, monitors);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glDeletePerfMonitorsAMD(GLsizei n, GLuint *monitors)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->DeletePerfMonitorsAMD(n, monitors);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glSelectPerfMonitorCountersAMD(GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *countersList)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->SelectPerfMonitorCountersAMD(monitor, enable, group, numCounters, countersList);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glBeginPerfMonitorAMD(GLuint monitor)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->BeginPerfMonitorAMD(monitor);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glEndPerfMonitorAMD(GLuint monitor)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->EndPerfMonitorAMD(monitor);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorCounterDataAMD(GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorCounterDataAMD(monitor, pname, dataSize, data, bytesWritten);
+}
+
+class QOpenGLExtension_ANGLE_framebuffer_blitPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BlitFramebufferANGLE)(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+};
+
+class QOpenGLExtension_ANGLE_framebuffer_blit : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ANGLE_framebuffer_blit();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBlitFramebufferANGLE(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ANGLE_framebuffer_blit)
+};
+
+inline void QOpenGLExtension_ANGLE_framebuffer_blit::glBlitFramebufferANGLE(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ Q_D(QOpenGLExtension_ANGLE_framebuffer_blit);
+ d->BlitFramebufferANGLE(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+class QOpenGLExtension_ANGLE_framebuffer_multisamplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP RenderbufferStorageMultisampleANGLE)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+};
+
+class QOpenGLExtension_ANGLE_framebuffer_multisample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ANGLE_framebuffer_multisample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glRenderbufferStorageMultisampleANGLE(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ANGLE_framebuffer_multisample)
+};
+
+inline void QOpenGLExtension_ANGLE_framebuffer_multisample::glRenderbufferStorageMultisampleANGLE(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_ANGLE_framebuffer_multisample);
+ d->RenderbufferStorageMultisampleANGLE(target, samples, internalformat, width, height);
+}
+
+class QOpenGLExtension_ANGLE_instanced_arraysPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawArraysInstancedANGLE)(GLenum mode, GLint first, GLsizei count, GLsizei primcount);
+ void (QOPENGLF_APIENTRYP DrawElementsInstancedANGLE)(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount);
+ void (QOPENGLF_APIENTRYP VertexAttribDivisorANGLE)(GLuint index, GLuint divisor);
+};
+
+class QOpenGLExtension_ANGLE_instanced_arrays : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ANGLE_instanced_arrays();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawArraysInstancedANGLE(GLenum mode, GLint first, GLsizei count, GLsizei primcount);
+ void glDrawElementsInstancedANGLE(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount);
+ void glVertexAttribDivisorANGLE(GLuint index, GLuint divisor);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ANGLE_instanced_arrays)
+};
+
+inline void QOpenGLExtension_ANGLE_instanced_arrays::glDrawArraysInstancedANGLE(GLenum mode, GLint first, GLsizei count, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_ANGLE_instanced_arrays);
+ d->DrawArraysInstancedANGLE(mode, first, count, primcount);
+}
+
+inline void QOpenGLExtension_ANGLE_instanced_arrays::glDrawElementsInstancedANGLE(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_ANGLE_instanced_arrays);
+ d->DrawElementsInstancedANGLE(mode, count, type, indices, primcount);
+}
+
+inline void QOpenGLExtension_ANGLE_instanced_arrays::glVertexAttribDivisorANGLE(GLuint index, GLuint divisor)
+{
+ Q_D(QOpenGLExtension_ANGLE_instanced_arrays);
+ d->VertexAttribDivisorANGLE(index, divisor);
+}
+
+class QOpenGLExtension_ANGLE_translated_shader_sourcePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetTranslatedShaderSourceANGLE)(GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source);
+};
+
+class QOpenGLExtension_ANGLE_translated_shader_source : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ANGLE_translated_shader_source();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetTranslatedShaderSourceANGLE(GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ANGLE_translated_shader_source)
+};
+
+inline void QOpenGLExtension_ANGLE_translated_shader_source::glGetTranslatedShaderSourceANGLE(GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source)
+{
+ Q_D(QOpenGLExtension_ANGLE_translated_shader_source);
+ d->GetTranslatedShaderSourceANGLE(shader, bufsize, length, source);
+}
+
+class QOpenGLExtension_APPLE_framebuffer_multisamplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP RenderbufferStorageMultisampleAPPLE)(GLenum, GLsizei, GLenum, GLsizei, GLsizei);
+ void (QOPENGLF_APIENTRYP ResolveMultisampleFramebufferAPPLE)(void);
+};
+
+class QOpenGLExtension_APPLE_framebuffer_multisample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_APPLE_framebuffer_multisample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glRenderbufferStorageMultisampleAPPLE(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glResolveMultisampleFramebufferAPPLE(void);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_APPLE_framebuffer_multisample)
+};
+
+inline void QOpenGLExtension_APPLE_framebuffer_multisample::glRenderbufferStorageMultisampleAPPLE(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_APPLE_framebuffer_multisample);
+ d->RenderbufferStorageMultisampleAPPLE(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_APPLE_framebuffer_multisample::glResolveMultisampleFramebufferAPPLE(void)
+{
+ Q_D(QOpenGLExtension_APPLE_framebuffer_multisample);
+ d->ResolveMultisampleFramebufferAPPLE();
+}
+
+class QOpenGLExtension_EXT_debug_labelPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP LabelObjectEXT)(GLenum type, GLuint object, GLsizei length, const GLchar *label);
+ void (QOPENGLF_APIENTRYP GetObjectLabelEXT)(GLenum type, GLuint object, GLsizei bufSize, GLsizei *length, GLchar *label);
+};
+
+class QOpenGLExtension_EXT_debug_label : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_debug_label();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glLabelObjectEXT(GLenum type, GLuint object, GLsizei length, const GLchar *label);
+ void glGetObjectLabelEXT(GLenum type, GLuint object, GLsizei bufSize, GLsizei *length, GLchar *label);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_debug_label)
+};
+
+inline void QOpenGLExtension_EXT_debug_label::glLabelObjectEXT(GLenum type, GLuint object, GLsizei length, const GLchar *label)
+{
+ Q_D(QOpenGLExtension_EXT_debug_label);
+ d->LabelObjectEXT(type, object, length, label);
+}
+
+inline void QOpenGLExtension_EXT_debug_label::glGetObjectLabelEXT(GLenum type, GLuint object, GLsizei bufSize, GLsizei *length, GLchar *label)
+{
+ Q_D(QOpenGLExtension_EXT_debug_label);
+ d->GetObjectLabelEXT(type, object, bufSize, length, label);
+}
+
+class QOpenGLExtension_EXT_debug_markerPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP InsertEventMarkerEXT)(GLsizei length, const GLchar *marker);
+ void (QOPENGLF_APIENTRYP PushGroupMarkerEXT)(GLsizei length, const GLchar *marker);
+ void (QOPENGLF_APIENTRYP PopGroupMarkerEXT)(void);
+};
+
+class QOpenGLExtension_EXT_debug_marker : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_debug_marker();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glInsertEventMarkerEXT(GLsizei length, const GLchar *marker);
+ void glPushGroupMarkerEXT(GLsizei length, const GLchar *marker);
+ void glPopGroupMarkerEXT(void);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_debug_marker)
+};
+
+inline void QOpenGLExtension_EXT_debug_marker::glInsertEventMarkerEXT(GLsizei length, const GLchar *marker)
+{
+ Q_D(QOpenGLExtension_EXT_debug_marker);
+ d->InsertEventMarkerEXT(length, marker);
+}
+
+inline void QOpenGLExtension_EXT_debug_marker::glPushGroupMarkerEXT(GLsizei length, const GLchar *marker)
+{
+ Q_D(QOpenGLExtension_EXT_debug_marker);
+ d->PushGroupMarkerEXT(length, marker);
+}
+
+inline void QOpenGLExtension_EXT_debug_marker::glPopGroupMarkerEXT(void)
+{
+ Q_D(QOpenGLExtension_EXT_debug_marker);
+ d->PopGroupMarkerEXT();
+}
+
+class QOpenGLExtension_EXT_discard_framebufferPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DiscardFramebufferEXT)(GLenum target, GLsizei numAttachments, const GLenum *attachments);
+};
+
+class QOpenGLExtension_EXT_discard_framebuffer : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_discard_framebuffer();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDiscardFramebufferEXT(GLenum target, GLsizei numAttachments, const GLenum *attachments);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_discard_framebuffer)
+};
+
+inline void QOpenGLExtension_EXT_discard_framebuffer::glDiscardFramebufferEXT(GLenum target, GLsizei numAttachments, const GLenum *attachments)
+{
+ Q_D(QOpenGLExtension_EXT_discard_framebuffer);
+ d->DiscardFramebufferEXT(target, numAttachments, attachments);
+}
+
+class QOpenGLExtension_EXT_multisampled_render_to_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP RenderbufferStorageMultisampleEXT)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP FramebufferTexture2DMultisampleEXT)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples);
+};
+
+class QOpenGLExtension_EXT_multisampled_render_to_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_multisampled_render_to_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glRenderbufferStorageMultisampleEXT(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glFramebufferTexture2DMultisampleEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_multisampled_render_to_texture)
+};
+
+inline void QOpenGLExtension_EXT_multisampled_render_to_texture::glRenderbufferStorageMultisampleEXT(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_multisampled_render_to_texture);
+ d->RenderbufferStorageMultisampleEXT(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_EXT_multisampled_render_to_texture::glFramebufferTexture2DMultisampleEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples)
+{
+ Q_D(QOpenGLExtension_EXT_multisampled_render_to_texture);
+ d->FramebufferTexture2DMultisampleEXT(target, attachment, textarget, texture, level, samples);
+}
+
+class QOpenGLExtension_EXT_multi_draw_arraysPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MultiDrawArraysEXT)(GLenum mode, GLint *first, GLsizei *count, GLsizei primcount);
+ void (QOPENGLF_APIENTRYP MultiDrawElementsEXT)(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount);
+};
+
+class QOpenGLExtension_EXT_multi_draw_arrays : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_multi_draw_arrays();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMultiDrawArraysEXT(GLenum mode, GLint *first, GLsizei *count, GLsizei primcount);
+ void glMultiDrawElementsEXT(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_multi_draw_arrays)
+};
+
+inline void QOpenGLExtension_EXT_multi_draw_arrays::glMultiDrawArraysEXT(GLenum mode, GLint *first, GLsizei *count, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_EXT_multi_draw_arrays);
+ d->MultiDrawArraysEXT(mode, first, count, primcount);
+}
+
+inline void QOpenGLExtension_EXT_multi_draw_arrays::glMultiDrawElementsEXT(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_EXT_multi_draw_arrays);
+ d->MultiDrawElementsEXT(mode, count, type, indices, primcount);
+}
+
+class QOpenGLExtension_EXT_occlusion_query_booleanPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GenQueriesEXT)(GLsizei n, GLuint *ids);
+ void (QOPENGLF_APIENTRYP DeleteQueriesEXT)(GLsizei n, const GLuint *ids);
+ GLboolean (QOPENGLF_APIENTRYP IsQueryEXT)(GLuint id);
+ void (QOPENGLF_APIENTRYP BeginQueryEXT)(GLenum target, GLuint id);
+ void (QOPENGLF_APIENTRYP EndQueryEXT)(GLenum target);
+ void (QOPENGLF_APIENTRYP GetQueryivEXT)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetQueryObjectuivEXT)(GLuint id, GLenum pname, GLuint *params);
+};
+
+class QOpenGLExtension_EXT_occlusion_query_boolean : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_occlusion_query_boolean();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGenQueriesEXT(GLsizei n, GLuint *ids);
+ void glDeleteQueriesEXT(GLsizei n, const GLuint *ids);
+ GLboolean glIsQueryEXT(GLuint id);
+ void glBeginQueryEXT(GLenum target, GLuint id);
+ void glEndQueryEXT(GLenum target);
+ void glGetQueryivEXT(GLenum target, GLenum pname, GLint *params);
+ void glGetQueryObjectuivEXT(GLuint id, GLenum pname, GLuint *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_occlusion_query_boolean)
+};
+
+inline void QOpenGLExtension_EXT_occlusion_query_boolean::glGenQueriesEXT(GLsizei n, GLuint *ids)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ d->GenQueriesEXT(n, ids);
+}
+
+inline void QOpenGLExtension_EXT_occlusion_query_boolean::glDeleteQueriesEXT(GLsizei n, const GLuint *ids)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ d->DeleteQueriesEXT(n, ids);
+}
+
+inline GLboolean QOpenGLExtension_EXT_occlusion_query_boolean::glIsQueryEXT(GLuint id)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ return d->IsQueryEXT(id);
+}
+
+inline void QOpenGLExtension_EXT_occlusion_query_boolean::glBeginQueryEXT(GLenum target, GLuint id)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ d->BeginQueryEXT(target, id);
+}
+
+inline void QOpenGLExtension_EXT_occlusion_query_boolean::glEndQueryEXT(GLenum target)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ d->EndQueryEXT(target);
+}
+
+inline void QOpenGLExtension_EXT_occlusion_query_boolean::glGetQueryivEXT(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ d->GetQueryivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_occlusion_query_boolean::glGetQueryObjectuivEXT(GLuint id, GLenum pname, GLuint *params)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ d->GetQueryObjectuivEXT(id, pname, params);
+}
+
+class QOpenGLExtension_EXT_robustnessPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLenum (QOPENGLF_APIENTRYP GetGraphicsResetStatusEXT)(void);
+ void (QOPENGLF_APIENTRYP ReadnPixelsEXT)(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data);
+ void (QOPENGLF_APIENTRYP GetnUniformfvEXT)(GLuint program, GLint location, GLsizei bufSize, float *params);
+ void (QOPENGLF_APIENTRYP GetnUniformivEXT)(GLuint program, GLint location, GLsizei bufSize, GLint *params);
+};
+
+class QOpenGLExtension_EXT_robustness : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_robustness();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLenum glGetGraphicsResetStatusEXT(void);
+ void glReadnPixelsEXT(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data);
+ void glGetnUniformfvEXT(GLuint program, GLint location, GLsizei bufSize, float *params);
+ void glGetnUniformivEXT(GLuint program, GLint location, GLsizei bufSize, GLint *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_robustness)
+};
+
+inline GLenum QOpenGLExtension_EXT_robustness::glGetGraphicsResetStatusEXT(void)
+{
+ Q_D(QOpenGLExtension_EXT_robustness);
+ return d->GetGraphicsResetStatusEXT();
+}
+
+inline void QOpenGLExtension_EXT_robustness::glReadnPixelsEXT(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data)
+{
+ Q_D(QOpenGLExtension_EXT_robustness);
+ d->ReadnPixelsEXT(x, y, width, height, format, type, bufSize, data);
+}
+
+inline void QOpenGLExtension_EXT_robustness::glGetnUniformfvEXT(GLuint program, GLint location, GLsizei bufSize, float *params)
+{
+ Q_D(QOpenGLExtension_EXT_robustness);
+ d->GetnUniformfvEXT(program, location, bufSize, params);
+}
+
+inline void QOpenGLExtension_EXT_robustness::glGetnUniformivEXT(GLuint program, GLint location, GLsizei bufSize, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_robustness);
+ d->GetnUniformivEXT(program, location, bufSize, params);
+}
+
+class QOpenGLExtension_EXT_separate_shader_objectsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP UseProgramStagesEXT)(GLuint pipeline, GLbitfield stages, GLuint program);
+ void (QOPENGLF_APIENTRYP ActiveShaderProgramEXT)(GLuint pipeline, GLuint program);
+ GLuint (QOPENGLF_APIENTRYP CreateShaderProgramvEXT)(GLenum type, GLsizei count, const GLchar **strings);
+ void (QOPENGLF_APIENTRYP BindProgramPipelineEXT)(GLuint pipeline);
+ void (QOPENGLF_APIENTRYP DeleteProgramPipelinesEXT)(GLsizei n, const GLuint *pipelines);
+ void (QOPENGLF_APIENTRYP GenProgramPipelinesEXT)(GLsizei n, GLuint *pipelines);
+ GLboolean (QOPENGLF_APIENTRYP IsProgramPipelineEXT)(GLuint pipeline);
+ void (QOPENGLF_APIENTRYP ProgramParameteriEXT)(GLuint program, GLenum pname, GLint value);
+ void (QOPENGLF_APIENTRYP GetProgramPipelineivEXT)(GLuint pipeline, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP ProgramUniform1iEXT)(GLuint program, GLint location, GLint x);
+ void (QOPENGLF_APIENTRYP ProgramUniform2iEXT)(GLuint program, GLint location, GLint x, GLint y);
+ void (QOPENGLF_APIENTRYP ProgramUniform3iEXT)(GLuint program, GLint location, GLint x, GLint y, GLint z);
+ void (QOPENGLF_APIENTRYP ProgramUniform4iEXT)(GLuint program, GLint location, GLint x, GLint y, GLint z, GLint w);
+ void (QOPENGLF_APIENTRYP ProgramUniform1fEXT)(GLuint program, GLint location, GLfloat x);
+ void (QOPENGLF_APIENTRYP ProgramUniform2fEXT)(GLuint program, GLint location, GLfloat x, GLfloat y);
+ void (QOPENGLF_APIENTRYP ProgramUniform3fEXT)(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP ProgramUniform4fEXT)(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP ProgramUniform1ivEXT)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2ivEXT)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3ivEXT)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4ivEXT)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1fvEXT)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2fvEXT)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3fvEXT)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4fvEXT)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ValidateProgramPipelineEXT)(GLuint pipeline);
+ void (QOPENGLF_APIENTRYP GetProgramPipelineInfoLogEXT)(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+};
+
+class QOpenGLExtension_EXT_separate_shader_objects : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_separate_shader_objects();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glUseProgramStagesEXT(GLuint pipeline, GLbitfield stages, GLuint program);
+ void glActiveShaderProgramEXT(GLuint pipeline, GLuint program);
+ GLuint glCreateShaderProgramvEXT(GLenum type, GLsizei count, const GLchar **strings);
+ void glBindProgramPipelineEXT(GLuint pipeline);
+ void glDeleteProgramPipelinesEXT(GLsizei n, const GLuint *pipelines);
+ void glGenProgramPipelinesEXT(GLsizei n, GLuint *pipelines);
+ GLboolean glIsProgramPipelineEXT(GLuint pipeline);
+ void glProgramParameteriEXT(GLuint program, GLenum pname, GLint value);
+ void glGetProgramPipelineivEXT(GLuint pipeline, GLenum pname, GLint *params);
+ void glProgramUniform1iEXT(GLuint program, GLint location, GLint x);
+ void glProgramUniform2iEXT(GLuint program, GLint location, GLint x, GLint y);
+ void glProgramUniform3iEXT(GLuint program, GLint location, GLint x, GLint y, GLint z);
+ void glProgramUniform4iEXT(GLuint program, GLint location, GLint x, GLint y, GLint z, GLint w);
+ void glProgramUniform1fEXT(GLuint program, GLint location, GLfloat x);
+ void glProgramUniform2fEXT(GLuint program, GLint location, GLfloat x, GLfloat y);
+ void glProgramUniform3fEXT(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z);
+ void glProgramUniform4fEXT(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glProgramUniform1ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform2ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform3ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform4ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform1fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform2fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform3fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform4fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniformMatrix2fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glValidateProgramPipelineEXT(GLuint pipeline);
+ void glGetProgramPipelineInfoLogEXT(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_separate_shader_objects)
+};
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glUseProgramStagesEXT(GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->UseProgramStagesEXT(pipeline, stages, program);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glActiveShaderProgramEXT(GLuint pipeline, GLuint program)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ActiveShaderProgramEXT(pipeline, program);
+}
+
+inline GLuint QOpenGLExtension_EXT_separate_shader_objects::glCreateShaderProgramvEXT(GLenum type, GLsizei count, const GLchar **strings)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ return d->CreateShaderProgramvEXT(type, count, strings);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glBindProgramPipelineEXT(GLuint pipeline)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->BindProgramPipelineEXT(pipeline);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glDeleteProgramPipelinesEXT(GLsizei n, const GLuint *pipelines)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->DeleteProgramPipelinesEXT(n, pipelines);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glGenProgramPipelinesEXT(GLsizei n, GLuint *pipelines)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->GenProgramPipelinesEXT(n, pipelines);
+}
+
+inline GLboolean QOpenGLExtension_EXT_separate_shader_objects::glIsProgramPipelineEXT(GLuint pipeline)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ return d->IsProgramPipelineEXT(pipeline);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramParameteriEXT(GLuint program, GLenum pname, GLint value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramParameteriEXT(program, pname, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glGetProgramPipelineivEXT(GLuint pipeline, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->GetProgramPipelineivEXT(pipeline, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform1iEXT(GLuint program, GLint location, GLint x)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform1iEXT(program, location, x);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform2iEXT(GLuint program, GLint location, GLint x, GLint y)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform2iEXT(program, location, x, y);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform3iEXT(GLuint program, GLint location, GLint x, GLint y, GLint z)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform3iEXT(program, location, x, y, z);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform4iEXT(GLuint program, GLint location, GLint x, GLint y, GLint z, GLint w)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform4iEXT(program, location, x, y, z, w);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform1fEXT(GLuint program, GLint location, GLfloat x)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform1fEXT(program, location, x);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform2fEXT(GLuint program, GLint location, GLfloat x, GLfloat y)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform2fEXT(program, location, x, y);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform3fEXT(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform3fEXT(program, location, x, y, z);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform4fEXT(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform4fEXT(program, location, x, y, z, w);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform1ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform1ivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform2ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform2ivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform3ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform3ivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform4ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform4ivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform1fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform1fvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform2fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform2fvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform3fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform3fvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform4fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform4fvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniformMatrix2fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniformMatrix2fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniformMatrix3fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniformMatrix3fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniformMatrix4fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniformMatrix4fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glValidateProgramPipelineEXT(GLuint pipeline)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ValidateProgramPipelineEXT(pipeline);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glGetProgramPipelineInfoLogEXT(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->GetProgramPipelineInfoLogEXT(pipeline, bufSize, length, infoLog);
+}
+
+class QOpenGLExtension_EXT_texture_storagePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexStorage1DEXT)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void (QOPENGLF_APIENTRYP TexStorage2DEXT)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP TexStorage3DEXT)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void (QOPENGLF_APIENTRYP TextureStorage1DEXT)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void (QOPENGLF_APIENTRYP TextureStorage2DEXT)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP TextureStorage3DEXT)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+};
+
+class QOpenGLExtension_EXT_texture_storage : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_texture_storage();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexStorage1DEXT(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void glTexStorage3DEXT(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void glTextureStorage1DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void glTextureStorage2DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void glTextureStorage3DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_texture_storage)
+};
+
+inline void QOpenGLExtension_EXT_texture_storage::glTexStorage1DEXT(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width)
+{
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+ d->TexStorage1DEXT(target, levels, internalformat, width);
+}
+
+inline void QOpenGLExtension_EXT_texture_storage::glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+ d->TexStorage2DEXT(target, levels, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_EXT_texture_storage::glTexStorage3DEXT(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+ d->TexStorage3DEXT(target, levels, internalformat, width, height, depth);
+}
+
+inline void QOpenGLExtension_EXT_texture_storage::glTextureStorage1DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width)
+{
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+ d->TextureStorage1DEXT(texture, target, levels, internalformat, width);
+}
+
+inline void QOpenGLExtension_EXT_texture_storage::glTextureStorage2DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+ d->TextureStorage2DEXT(texture, target, levels, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_EXT_texture_storage::glTextureStorage3DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+ d->TextureStorage3DEXT(texture, target, levels, internalformat, width, height, depth);
+}
+
+class QOpenGLExtension_IMG_multisampled_render_to_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP RenderbufferStorageMultisampleIMG)(GLenum, GLsizei, GLenum, GLsizei, GLsizei);
+ void (QOPENGLF_APIENTRYP FramebufferTexture2DMultisampleIMG)(GLenum, GLenum, GLenum, GLuint, GLint, GLsizei);
+};
+
+class QOpenGLExtension_IMG_multisampled_render_to_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_IMG_multisampled_render_to_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glRenderbufferStorageMultisampleIMG(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glFramebufferTexture2DMultisampleIMG(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_IMG_multisampled_render_to_texture)
+};
+
+inline void QOpenGLExtension_IMG_multisampled_render_to_texture::glRenderbufferStorageMultisampleIMG(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_IMG_multisampled_render_to_texture);
+ d->RenderbufferStorageMultisampleIMG(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_IMG_multisampled_render_to_texture::glFramebufferTexture2DMultisampleIMG(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples)
+{
+ Q_D(QOpenGLExtension_IMG_multisampled_render_to_texture);
+ d->FramebufferTexture2DMultisampleIMG(target, attachment, textarget, texture, level, samples);
+}
+
+class QOpenGLExtension_NV_coverage_samplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP CoverageMaskNV)(GLboolean mask);
+ void (QOPENGLF_APIENTRYP CoverageOperationNV)(GLenum operation);
+};
+
+class QOpenGLExtension_NV_coverage_sample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_coverage_sample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glCoverageMaskNV(GLboolean mask);
+ void glCoverageOperationNV(GLenum operation);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_coverage_sample)
+};
+
+inline void QOpenGLExtension_NV_coverage_sample::glCoverageMaskNV(GLboolean mask)
+{
+ Q_D(QOpenGLExtension_NV_coverage_sample);
+ d->CoverageMaskNV(mask);
+}
+
+inline void QOpenGLExtension_NV_coverage_sample::glCoverageOperationNV(GLenum operation)
+{
+ Q_D(QOpenGLExtension_NV_coverage_sample);
+ d->CoverageOperationNV(operation);
+}
+
+class QOpenGLExtension_NV_draw_buffersPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawBuffersNV)(GLsizei n, const GLenum *bufs);
+};
+
+class QOpenGLExtension_NV_draw_buffers : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_draw_buffers();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawBuffersNV(GLsizei n, const GLenum *bufs);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_draw_buffers)
+};
+
+inline void QOpenGLExtension_NV_draw_buffers::glDrawBuffersNV(GLsizei n, const GLenum *bufs)
+{
+ Q_D(QOpenGLExtension_NV_draw_buffers);
+ d->DrawBuffersNV(n, bufs);
+}
+
+class QOpenGLExtension_NV_fencePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DeleteFencesNV)(GLsizei n, const GLuint *fences);
+ void (QOPENGLF_APIENTRYP GenFencesNV)(GLsizei n, GLuint *fences);
+ GLboolean (QOPENGLF_APIENTRYP IsFenceNV)(GLuint fence);
+ GLboolean (QOPENGLF_APIENTRYP TestFenceNV)(GLuint fence);
+ void (QOPENGLF_APIENTRYP GetFenceivNV)(GLuint fence, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP FinishFenceNV)(GLuint fence);
+ void (QOPENGLF_APIENTRYP SetFenceNV)(GLuint fence, GLenum condition);
+};
+
+class QOpenGLExtension_NV_fence : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_fence();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDeleteFencesNV(GLsizei n, const GLuint *fences);
+ void glGenFencesNV(GLsizei n, GLuint *fences);
+ GLboolean glIsFenceNV(GLuint fence);
+ GLboolean glTestFenceNV(GLuint fence);
+ void glGetFenceivNV(GLuint fence, GLenum pname, GLint *params);
+ void glFinishFenceNV(GLuint fence);
+ void glSetFenceNV(GLuint fence, GLenum condition);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_fence)
+};
+
+inline void QOpenGLExtension_NV_fence::glDeleteFencesNV(GLsizei n, const GLuint *fences)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->DeleteFencesNV(n, fences);
+}
+
+inline void QOpenGLExtension_NV_fence::glGenFencesNV(GLsizei n, GLuint *fences)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->GenFencesNV(n, fences);
+}
+
+inline GLboolean QOpenGLExtension_NV_fence::glIsFenceNV(GLuint fence)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ return d->IsFenceNV(fence);
+}
+
+inline GLboolean QOpenGLExtension_NV_fence::glTestFenceNV(GLuint fence)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ return d->TestFenceNV(fence);
+}
+
+inline void QOpenGLExtension_NV_fence::glGetFenceivNV(GLuint fence, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->GetFenceivNV(fence, pname, params);
+}
+
+inline void QOpenGLExtension_NV_fence::glFinishFenceNV(GLuint fence)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->FinishFenceNV(fence);
+}
+
+inline void QOpenGLExtension_NV_fence::glSetFenceNV(GLuint fence, GLenum condition)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->SetFenceNV(fence, condition);
+}
+
+class QOpenGLExtension_NV_read_bufferPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ReadBufferNV)(GLenum mode);
+};
+
+class QOpenGLExtension_NV_read_buffer : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_read_buffer();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glReadBufferNV(GLenum mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_read_buffer)
+};
+
+inline void QOpenGLExtension_NV_read_buffer::glReadBufferNV(GLenum mode)
+{
+ Q_D(QOpenGLExtension_NV_read_buffer);
+ d->ReadBufferNV(mode);
+}
+
+class QOpenGLExtension_QCOM_alpha_testPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP AlphaFuncQCOM)(GLenum func, GLclampf ref);
+};
+
+class QOpenGLExtension_QCOM_alpha_test : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_QCOM_alpha_test();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glAlphaFuncQCOM(GLenum func, GLclampf ref);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_QCOM_alpha_test)
+};
+
+inline void QOpenGLExtension_QCOM_alpha_test::glAlphaFuncQCOM(GLenum func, GLclampf ref)
+{
+ Q_D(QOpenGLExtension_QCOM_alpha_test);
+ d->AlphaFuncQCOM(func, ref);
+}
+
+class QOpenGLExtension_QCOM_driver_controlPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetDriverControlsQCOM)(GLint *num, GLsizei size, GLuint *driverControls);
+ void (QOPENGLF_APIENTRYP GetDriverControlStringQCOM)(GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString);
+ void (QOPENGLF_APIENTRYP EnableDriverControlQCOM)(GLuint driverControl);
+ void (QOPENGLF_APIENTRYP DisableDriverControlQCOM)(GLuint driverControl);
+};
+
+class QOpenGLExtension_QCOM_driver_control : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_QCOM_driver_control();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetDriverControlsQCOM(GLint *num, GLsizei size, GLuint *driverControls);
+ void glGetDriverControlStringQCOM(GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString);
+ void glEnableDriverControlQCOM(GLuint driverControl);
+ void glDisableDriverControlQCOM(GLuint driverControl);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_QCOM_driver_control)
+};
+
+inline void QOpenGLExtension_QCOM_driver_control::glGetDriverControlsQCOM(GLint *num, GLsizei size, GLuint *driverControls)
+{
+ Q_D(QOpenGLExtension_QCOM_driver_control);
+ d->GetDriverControlsQCOM(num, size, driverControls);
+}
+
+inline void QOpenGLExtension_QCOM_driver_control::glGetDriverControlStringQCOM(GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString)
+{
+ Q_D(QOpenGLExtension_QCOM_driver_control);
+ d->GetDriverControlStringQCOM(driverControl, bufSize, length, driverControlString);
+}
+
+inline void QOpenGLExtension_QCOM_driver_control::glEnableDriverControlQCOM(GLuint driverControl)
+{
+ Q_D(QOpenGLExtension_QCOM_driver_control);
+ d->EnableDriverControlQCOM(driverControl);
+}
+
+inline void QOpenGLExtension_QCOM_driver_control::glDisableDriverControlQCOM(GLuint driverControl)
+{
+ Q_D(QOpenGLExtension_QCOM_driver_control);
+ d->DisableDriverControlQCOM(driverControl);
+}
+
+class QOpenGLExtension_QCOM_extended_getPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ExtGetTexturesQCOM)(GLuint *textures, GLint maxTextures, GLint *numTextures);
+ void (QOPENGLF_APIENTRYP ExtGetBuffersQCOM)(GLuint *buffers, GLint maxBuffers, GLint *numBuffers);
+ void (QOPENGLF_APIENTRYP ExtGetRenderbuffersQCOM)(GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers);
+ void (QOPENGLF_APIENTRYP ExtGetFramebuffersQCOM)(GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers);
+ void (QOPENGLF_APIENTRYP ExtGetTexLevelParameterivQCOM)(GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP ExtTexObjectStateOverrideiQCOM)(GLenum target, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP ExtGetTexSubImageQCOM)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLvoid *texels);
+ void (QOPENGLF_APIENTRYP ExtGetBufferPointervQCOM)(GLenum target, GLvoid **params);
+};
+
+class QOpenGLExtension_QCOM_extended_get : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_QCOM_extended_get();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glExtGetTexturesQCOM(GLuint *textures, GLint maxTextures, GLint *numTextures);
+ void glExtGetBuffersQCOM(GLuint *buffers, GLint maxBuffers, GLint *numBuffers);
+ void glExtGetRenderbuffersQCOM(GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers);
+ void glExtGetFramebuffersQCOM(GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers);
+ void glExtGetTexLevelParameterivQCOM(GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params);
+ void glExtTexObjectStateOverrideiQCOM(GLenum target, GLenum pname, GLint param);
+ void glExtGetTexSubImageQCOM(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLvoid *texels);
+ void glExtGetBufferPointervQCOM(GLenum target, GLvoid **params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_QCOM_extended_get)
+};
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetTexturesQCOM(GLuint *textures, GLint maxTextures, GLint *numTextures)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetTexturesQCOM(textures, maxTextures, numTextures);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetBuffersQCOM(GLuint *buffers, GLint maxBuffers, GLint *numBuffers)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetBuffersQCOM(buffers, maxBuffers, numBuffers);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetRenderbuffersQCOM(GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetRenderbuffersQCOM(renderbuffers, maxRenderbuffers, numRenderbuffers);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetFramebuffersQCOM(GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetFramebuffersQCOM(framebuffers, maxFramebuffers, numFramebuffers);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetTexLevelParameterivQCOM(GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetTexLevelParameterivQCOM(texture, face, level, pname, params);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtTexObjectStateOverrideiQCOM(GLenum target, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtTexObjectStateOverrideiQCOM(target, pname, param);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetTexSubImageQCOM(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLvoid *texels)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetTexSubImageQCOM(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, texels);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetBufferPointervQCOM(GLenum target, GLvoid **params)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetBufferPointervQCOM(target, params);
+}
+
+class QOpenGLExtension_QCOM_extended_get2Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ExtGetShadersQCOM)(GLuint *shaders, GLint maxShaders, GLint *numShaders);
+ void (QOPENGLF_APIENTRYP ExtGetProgramsQCOM)(GLuint *programs, GLint maxPrograms, GLint *numPrograms);
+ GLboolean (QOPENGLF_APIENTRYP ExtIsProgramBinaryQCOM)(GLuint program);
+ void (QOPENGLF_APIENTRYP ExtGetProgramBinarySourceQCOM)(GLuint program, GLenum shadertype, GLchar *source, GLint *length);
+};
+
+class QOpenGLExtension_QCOM_extended_get2 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_QCOM_extended_get2();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glExtGetShadersQCOM(GLuint *shaders, GLint maxShaders, GLint *numShaders);
+ void glExtGetProgramsQCOM(GLuint *programs, GLint maxPrograms, GLint *numPrograms);
+ GLboolean glExtIsProgramBinaryQCOM(GLuint program);
+ void glExtGetProgramBinarySourceQCOM(GLuint program, GLenum shadertype, GLchar *source, GLint *length);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_QCOM_extended_get2)
+};
+
+inline void QOpenGLExtension_QCOM_extended_get2::glExtGetShadersQCOM(GLuint *shaders, GLint maxShaders, GLint *numShaders)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get2);
+ d->ExtGetShadersQCOM(shaders, maxShaders, numShaders);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get2::glExtGetProgramsQCOM(GLuint *programs, GLint maxPrograms, GLint *numPrograms)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get2);
+ d->ExtGetProgramsQCOM(programs, maxPrograms, numPrograms);
+}
+
+inline GLboolean QOpenGLExtension_QCOM_extended_get2::glExtIsProgramBinaryQCOM(GLuint program)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get2);
+ return d->ExtIsProgramBinaryQCOM(program);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get2::glExtGetProgramBinarySourceQCOM(GLuint program, GLenum shadertype, GLchar *source, GLint *length)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get2);
+ d->ExtGetProgramBinarySourceQCOM(program, shadertype, source, length);
+}
+
+class QOpenGLExtension_QCOM_tiled_renderingPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP StartTilingQCOM)(GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask);
+ void (QOPENGLF_APIENTRYP EndTilingQCOM)(GLbitfield preserveMask);
+};
+
+class QOpenGLExtension_QCOM_tiled_rendering : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_QCOM_tiled_rendering();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glStartTilingQCOM(GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask);
+ void glEndTilingQCOM(GLbitfield preserveMask);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_QCOM_tiled_rendering)
+};
+
+inline void QOpenGLExtension_QCOM_tiled_rendering::glStartTilingQCOM(GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask)
+{
+ Q_D(QOpenGLExtension_QCOM_tiled_rendering);
+ d->StartTilingQCOM(x, y, width, height, preserveMask);
+}
+
+inline void QOpenGLExtension_QCOM_tiled_rendering::glEndTilingQCOM(GLbitfield preserveMask)
+{
+ Q_D(QOpenGLExtension_QCOM_tiled_rendering);
+ d->EndTilingQCOM(preserveMask);
+}
+
+#endif
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL
+
+#endif
diff --git a/src/platformsupport/cfsocketnotifier/cfsocketnotifier.pri b/src/platformsupport/cfsocketnotifier/cfsocketnotifier.pri
new file mode 100644
index 0000000000..9a19d3c278
--- /dev/null
+++ b/src/platformsupport/cfsocketnotifier/cfsocketnotifier.pri
@@ -0,0 +1,4 @@
+mac {
+ HEADERS += $$PWD/qcfsocketnotifier_p.h
+ SOURCES += $$PWD/qcfsocketnotifier.cpp
+}
diff --git a/src/platformsupport/cfsocketnotifier/qcfsocketnotifier.cpp b/src/platformsupport/cfsocketnotifier/qcfsocketnotifier.cpp
new file mode 100644
index 0000000000..5dcd6a4ffd
--- /dev/null
+++ b/src/platformsupport/cfsocketnotifier/qcfsocketnotifier.cpp
@@ -0,0 +1,255 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qcfsocketnotifier_p.h"
+#include <QtGui/qguiapplication.h>
+#include <QtCore/qsocketnotifier.h>
+#include <QtCore/qthread.h>
+
+
+/**************************************************************************
+ Socket Notifiers
+ *************************************************************************/
+void qt_mac_socket_callback(CFSocketRef s, CFSocketCallBackType callbackType, CFDataRef,
+ const void *, void *info)
+{
+
+ QCFSocketNotifier *cfSocketNotifier = static_cast<QCFSocketNotifier *>(info);
+ int nativeSocket = CFSocketGetNative(s);
+ MacSocketInfo *socketInfo = cfSocketNotifier->macSockets.value(nativeSocket);
+ QEvent notifierEvent(QEvent::SockAct);
+
+ // There is a race condition that happen where we disable the notifier and
+ // the kernel still has a notification to pass on. We then get this
+ // notification after we've successfully disabled the CFSocket, but our Qt
+ // notifier is now gone. The upshot is we have to check the notifier
+ // every time.
+ if (callbackType == kCFSocketReadCallBack) {
+ if (socketInfo->readNotifier)
+ QGuiApplication::sendEvent(socketInfo->readNotifier, &notifierEvent);
+ } else if (callbackType == kCFSocketWriteCallBack) {
+ if (socketInfo->writeNotifier)
+ QGuiApplication::sendEvent(socketInfo->writeNotifier, &notifierEvent);
+ }
+
+ if (cfSocketNotifier->maybeCancelWaitForMoreEvents)
+ cfSocketNotifier->maybeCancelWaitForMoreEvents(cfSocketNotifier->eventDispatcher);
+}
+
+/*
+ Adds a loop source for the given socket to the current run loop.
+*/
+CFRunLoopSourceRef qt_mac_add_socket_to_runloop(const CFSocketRef socket)
+{
+ CFRunLoopSourceRef loopSource = CFSocketCreateRunLoopSource(kCFAllocatorDefault, socket, 0);
+ if (!loopSource)
+ return 0;
+
+ CFRunLoopAddSource(CFRunLoopGetMain(), loopSource, kCFRunLoopCommonModes);
+ return loopSource;
+}
+
+/*
+ Removes the loop source for the given socket from the current run loop.
+*/
+void qt_mac_remove_socket_from_runloop(const CFSocketRef socket, CFRunLoopSourceRef runloop)
+{
+ Q_ASSERT(runloop);
+ CFRunLoopRemoveSource(CFRunLoopGetMain(), runloop, kCFRunLoopCommonModes);
+ CFSocketDisableCallBacks(socket, kCFSocketReadCallBack);
+ CFSocketDisableCallBacks(socket, kCFSocketWriteCallBack);
+ CFRunLoopSourceInvalidate(runloop);
+}
+
+QCFSocketNotifier::QCFSocketNotifier()
+:eventDispatcher(0)
+{
+
+}
+
+QCFSocketNotifier::~QCFSocketNotifier()
+{
+
+}
+
+void QCFSocketNotifier::setHostEventDispatcher(QAbstractEventDispatcher *hostEventDispacher)
+{
+ eventDispatcher = hostEventDispacher;
+}
+
+void QCFSocketNotifier::setMaybeCancelWaitForMoreEventsCallback(MaybeCancelWaitForMoreEventsFn callBack)
+{
+ maybeCancelWaitForMoreEvents = callBack;
+}
+
+void QCFSocketNotifier::registerSocketNotifier(QSocketNotifier *notifier)
+{
+ Q_ASSERT(notifier);
+ int nativeSocket = notifier->socket();
+ int type = notifier->type();
+#ifndef QT_NO_DEBUG
+ if (nativeSocket < 0 || nativeSocket > FD_SETSIZE) {
+ qWarning("QSocketNotifier: Internal error");
+ return;
+ } else if (notifier->thread() != eventDispatcher->thread()
+ || eventDispatcher->thread() != QThread::currentThread()) {
+ qWarning("QSocketNotifier: socket notifiers cannot be enabled from another thread");
+ return;
+ }
+#endif
+
+ if (type == QSocketNotifier::Exception) {
+ qWarning("QSocketNotifier::Exception is not supported on iOS");
+ return;
+ }
+
+ // Check if we have a CFSocket for the native socket, create one if not.
+ MacSocketInfo *socketInfo = macSockets.value(nativeSocket);
+ if (!socketInfo) {
+ socketInfo = new MacSocketInfo();
+
+ // Create CFSocket, specify that we want both read and write callbacks (the callbacks
+ // are enabled/disabled later on).
+ const int callbackTypes = kCFSocketReadCallBack | kCFSocketWriteCallBack;
+ CFSocketContext context = {0, this, 0, 0, 0};
+ socketInfo->socket = CFSocketCreateWithNative(kCFAllocatorDefault, nativeSocket, callbackTypes, qt_mac_socket_callback, &context);
+ if (CFSocketIsValid(socketInfo->socket) == false) {
+ qWarning("QEventDispatcherMac::registerSocketNotifier: Failed to create CFSocket");
+ return;
+ }
+
+ CFOptionFlags flags = CFSocketGetSocketFlags(socketInfo->socket);
+ flags |= kCFSocketAutomaticallyReenableWriteCallBack; //QSocketNotifier stays enabled after a write
+ flags &= ~kCFSocketCloseOnInvalidate; //QSocketNotifier doesn't close the socket upon destruction/invalidation
+ CFSocketSetSocketFlags(socketInfo->socket, flags);
+
+ // Add CFSocket to runloop.
+ if (!(socketInfo->runloop = qt_mac_add_socket_to_runloop(socketInfo->socket))) {
+ qWarning("QEventDispatcherMac::registerSocketNotifier: Failed to add CFSocket to runloop");
+ CFSocketInvalidate(socketInfo->socket);
+ CFRelease(socketInfo->socket);
+ return;
+ }
+
+ // Disable both callback types by default. This must be done after
+ // we add the CFSocket to the runloop, or else these calls will have
+ // no effect.
+ CFSocketDisableCallBacks(socketInfo->socket, kCFSocketReadCallBack);
+ CFSocketDisableCallBacks(socketInfo->socket, kCFSocketWriteCallBack);
+
+ macSockets.insert(nativeSocket, socketInfo);
+ }
+
+ // Increment read/write counters and select enable callbacks if necessary.
+ if (type == QSocketNotifier::Read) {
+ Q_ASSERT(socketInfo->readNotifier == 0);
+ socketInfo->readNotifier = notifier;
+ CFSocketEnableCallBacks(socketInfo->socket, kCFSocketReadCallBack);
+ } else if (type == QSocketNotifier::Write) {
+ Q_ASSERT(socketInfo->writeNotifier == 0);
+ socketInfo->writeNotifier = notifier;
+ CFSocketEnableCallBacks(socketInfo->socket, kCFSocketWriteCallBack);
+ }
+}
+
+void QCFSocketNotifier::unregisterSocketNotifier(QSocketNotifier *notifier)
+{
+ Q_ASSERT(notifier);
+ int nativeSocket = notifier->socket();
+ int type = notifier->type();
+#ifndef QT_NO_DEBUG
+ if (nativeSocket < 0 || nativeSocket > FD_SETSIZE) {
+ qWarning("QSocketNotifier: Internal error");
+ return;
+ } else if (notifier->thread() != eventDispatcher->thread() || eventDispatcher->thread() != QThread::currentThread()) {
+ qWarning("QSocketNotifier: socket notifiers cannot be disabled from another thread");
+ return;
+ }
+#endif
+
+ if (type == QSocketNotifier::Exception) {
+ qWarning("QSocketNotifier::Exception is not supported on iOS");
+ return;
+ }
+ MacSocketInfo *socketInfo = macSockets.value(nativeSocket);
+ if (!socketInfo) {
+ qWarning("QEventDispatcherMac::unregisterSocketNotifier: Tried to unregister a not registered notifier");
+ return;
+ }
+
+ // Decrement read/write counters and disable callbacks if necessary.
+ if (type == QSocketNotifier::Read) {
+ Q_ASSERT(notifier == socketInfo->readNotifier);
+ socketInfo->readNotifier = 0;
+ CFSocketDisableCallBacks(socketInfo->socket, kCFSocketReadCallBack);
+ } else if (type == QSocketNotifier::Write) {
+ Q_ASSERT(notifier == socketInfo->writeNotifier);
+ socketInfo->writeNotifier = 0;
+ CFSocketDisableCallBacks(socketInfo->socket, kCFSocketWriteCallBack);
+ }
+
+ // Remove CFSocket from runloop if this was the last QSocketNotifier.
+ if (socketInfo->readNotifier == 0 && socketInfo->writeNotifier == 0) {
+ if (CFSocketIsValid(socketInfo->socket))
+ qt_mac_remove_socket_from_runloop(socketInfo->socket, socketInfo->runloop);
+ CFRunLoopSourceInvalidate(socketInfo->runloop);
+ CFRelease(socketInfo->runloop);
+ CFSocketInvalidate(socketInfo->socket);
+ CFRelease(socketInfo->socket);
+ delete socketInfo;
+ macSockets.remove(nativeSocket);
+ }
+}
+
+void QCFSocketNotifier::removeSocketNotifiers()
+{
+ // Remove CFSockets from the runloop.
+ for (MacSocketHash::ConstIterator it = macSockets.constBegin(); it != macSockets.constEnd(); ++it) {
+ MacSocketInfo *socketInfo = (*it);
+ if (CFSocketIsValid(socketInfo->socket)) {
+ qt_mac_remove_socket_from_runloop(socketInfo->socket, socketInfo->runloop);
+ CFRunLoopSourceInvalidate(socketInfo->runloop);
+ CFRelease(socketInfo->runloop);
+ CFSocketInvalidate(socketInfo->socket);
+ CFRelease(socketInfo->socket);
+ }
+ }
+}
diff --git a/src/platformsupport/cfsocketnotifier/qcfsocketnotifier_p.h b/src/platformsupport/cfsocketnotifier/qcfsocketnotifier_p.h
new file mode 100644
index 0000000000..cd1eb8e4ca
--- /dev/null
+++ b/src/platformsupport/cfsocketnotifier/qcfsocketnotifier_p.h
@@ -0,0 +1,90 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QCFSOCKETNOTIFIER_P_H
+#define QCFSOCKETNOTIFIER_P_H
+
+#include <QtCore/qabstracteventdispatcher.h>
+#include <QtCore/qhash.h>
+
+#include <CoreFoundation/CoreFoundation.h>
+
+QT_BEGIN_NAMESPACE
+
+struct MacSocketInfo {
+ MacSocketInfo() : socket(0), runloop(0), readNotifier(0), writeNotifier(0) {}
+ CFSocketRef socket;
+ CFRunLoopSourceRef runloop;
+ QObject *readNotifier;
+ QObject *writeNotifier;
+};
+typedef QHash<int, MacSocketInfo *> MacSocketHash;
+
+typedef void (*MaybeCancelWaitForMoreEventsFn)(QAbstractEventDispatcher *hostEventDispacher);
+
+// The CoreFoundationSocketNotifier class implements socket notifiers support using
+// CFSocket for event dispatchers running on top of the Core Foundation run loop system.
+// (currently Mac and iOS)
+//
+// The principal functions are registerSocketNotifier() and unregisterSocketNotifier().
+//
+// setHostEventDispatcher() should be called at startup.
+// removeSocketNotifiers() should be called at shutdown.
+//
+class QCFSocketNotifier
+{
+public:
+ QCFSocketNotifier();
+ ~QCFSocketNotifier();
+ void setHostEventDispatcher(QAbstractEventDispatcher *hostEventDispacher);
+ void setMaybeCancelWaitForMoreEventsCallback(MaybeCancelWaitForMoreEventsFn callBack);
+ void registerSocketNotifier(QSocketNotifier *notifier);
+ void unregisterSocketNotifier(QSocketNotifier *notifier);
+ void removeSocketNotifiers();
+
+ MacSocketHash macSockets;
+ QAbstractEventDispatcher *eventDispatcher;
+ MaybeCancelWaitForMoreEventsFn maybeCancelWaitForMoreEvents;
+};
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/platformsupport/cglconvenience/cglconvenience.mm b/src/platformsupport/cglconvenience/cglconvenience.mm
index b0ea2d2225..12ae5965df 100644
--- a/src/platformsupport/cglconvenience/cglconvenience.mm
+++ b/src/platformsupport/cglconvenience/cglconvenience.mm
@@ -61,6 +61,7 @@ void (*qcgl_getProcAddress(const QByteArray &procName))()
QSurfaceFormat qcgl_surfaceFormat()
{
QSurfaceFormat format;
+ format.setRenderableType(QSurfaceFormat::OpenGL);
format.setRedBufferSize(8);
format.setGreenBufferSize(8);
format.setBlueBufferSize(8);
@@ -125,13 +126,3 @@ void *qcgl_createNSOpenGLPixelFormat(const QSurfaceFormat &format)
NSOpenGLPixelFormat* pixelFormat = [[NSOpenGLPixelFormat alloc] initWithAttributes:attrs.constData()];
return pixelFormat;
}
-
-CGLContextObj qcgl_createGlContext()
-{
- CGLContextObj context;
- NSOpenGLPixelFormat *format = reinterpret_cast<NSOpenGLPixelFormat *>(qcgl_createNSOpenGLPixelFormat(qcgl_surfaceFormat()));
- CGLPixelFormatObj cglFormat = static_cast<CGLPixelFormatObj>([format CGLPixelFormatObj]);
- CGLCreateContext(cglFormat ,NULL, &context);
- return context;
-}
-
diff --git a/src/platformsupport/cglconvenience/cglconvenience_p.h b/src/platformsupport/cglconvenience/cglconvenience_p.h
index bd2de0abc0..82842a78f0 100644
--- a/src/platformsupport/cglconvenience/cglconvenience_p.h
+++ b/src/platformsupport/cglconvenience/cglconvenience_p.h
@@ -49,6 +49,5 @@
void (*qcgl_getProcAddress(const QByteArray &procName))();
QSurfaceFormat qcgl_surfaceFormat();
void *qcgl_createNSOpenGLPixelFormat(const QSurfaceFormat &format);
-CGLContextObj qcgl_createGlContext();
#endif // QMACGLCONVENIENCE_H
diff --git a/src/platformsupport/devicediscovery/devicediscovery.pri b/src/platformsupport/devicediscovery/devicediscovery.pri
index 530ae3dbb2..9faf6f24dd 100644
--- a/src/platformsupport/devicediscovery/devicediscovery.pri
+++ b/src/platformsupport/devicediscovery/devicediscovery.pri
@@ -1,4 +1,4 @@
-linux-*:contains(QT_CONFIG, evdev) {
+linux:contains(QT_CONFIG, evdev) {
HEADERS += $$PWD/qdevicediscovery_p.h
contains(QT_CONFIG, libudev) {
diff --git a/src/platformsupport/dnd/qshapedpixmapdndwindow.cpp b/src/platformsupport/dnd/qshapedpixmapdndwindow.cpp
index 67c3cb4701..b3e64b01d0 100644
--- a/src/platformsupport/dnd/qshapedpixmapdndwindow.cpp
+++ b/src/platformsupport/dnd/qshapedpixmapdndwindow.cpp
@@ -91,7 +91,9 @@ void QShapedPixmapWindow::setHotspot(const QPoint &hotspot)
void QShapedPixmapWindow::updateGeometry()
{
QRect rect(QCursor::pos() - m_hotSpot, m_pixmap.size());
- if (m_backingStore->size() != m_pixmap.size())
+ if (m_pixmap.isNull())
+ m_backingStore->resize(QSize(1,1));
+ else if (m_backingStore->size() != m_pixmap.size())
m_backingStore->resize(m_pixmap.size());
setGeometry(rect);
}
diff --git a/src/platformsupport/dnd/qshapedpixmapdndwindow_p.h b/src/platformsupport/dnd/qshapedpixmapdndwindow_p.h
index ed0819cf29..20674b6b19 100644
--- a/src/platformsupport/dnd/qshapedpixmapdndwindow_p.h
+++ b/src/platformsupport/dnd/qshapedpixmapdndwindow_p.h
@@ -48,8 +48,6 @@
QT_BEGIN_NAMESPACE
-QT_BEGIN_HEADER
-
class QShapedPixmapWindow : public QWindow
{
Q_OBJECT
@@ -72,8 +70,6 @@ private:
QPoint m_hotSpot;
};
-QT_END_HEADER
-
QT_END_NAMESPACE
#endif // QSHAPEDPIXMAPDNDWINDOW_H
diff --git a/src/platformsupport/dnd/qsimpledrag.cpp b/src/platformsupport/dnd/qsimpledrag.cpp
index 3b73380cab..587e70b0f3 100644
--- a/src/platformsupport/dnd/qsimpledrag.cpp
+++ b/src/platformsupport/dnd/qsimpledrag.cpp
@@ -95,7 +95,7 @@ static QWindow* topLevelAt(const QPoint &pos)
QBasicDrag::QBasicDrag() :
m_restoreCursor(false), m_eventLoop(0),
m_executed_drop_action(Qt::IgnoreAction), m_can_drop(false),
- m_drag(0), m_drag_icon_window(0), m_cursor_drop_action(Qt::IgnoreAction)
+ m_drag(0), m_drag_icon_window(0)
{
}
@@ -207,6 +207,8 @@ void QBasicDrag::resetDndState(bool /* deleteSource */)
void QBasicDrag::startDrag()
{
+ // ### TODO Check if its really necessary to have m_drag_icon_window
+ // when QDrag is used without a pixmap - QDrag::setPixmap()
if (!m_drag_icon_window)
m_drag_icon_window = new QShapedPixmapWindow();
diff --git a/src/platformsupport/dnd/qsimpledrag_p.h b/src/platformsupport/dnd/qsimpledrag_p.h
index 5cf3394919..b2d4191b89 100644
--- a/src/platformsupport/dnd/qsimpledrag_p.h
+++ b/src/platformsupport/dnd/qsimpledrag_p.h
@@ -48,8 +48,6 @@
QT_BEGIN_NAMESPACE
-QT_BEGIN_HEADER
-
#ifndef QT_NO_DRAGANDDROP
class QMouseEvent;
@@ -99,7 +97,6 @@ private:
bool m_can_drop;
QDrag *m_drag;
QShapedPixmapWindow *m_drag_icon_window;
- Qt::DropAction m_cursor_drop_action;
};
class QSimpleDrag : public QBasicDrag
@@ -120,8 +117,6 @@ private:
#endif // QT_NO_DRAGANDDROP
-QT_END_HEADER
-
QT_END_NAMESPACE
#endif
diff --git a/src/platformsupport/eglconvenience/eglconvenience.pri b/src/platformsupport/eglconvenience/eglconvenience.pri
index 188eb1ce64..506f4ab4ea 100644
--- a/src/platformsupport/eglconvenience/eglconvenience.pri
+++ b/src/platformsupport/eglconvenience/eglconvenience.pri
@@ -1,10 +1,12 @@
contains(QT_CONFIG,egl) {
HEADERS += \
$$PWD/qeglconvenience_p.h \
- $$PWD/qeglplatformcontext_p.h
+ $$PWD/qeglplatformcontext_p.h \
+ $$PWD/qeglpbuffer_p.h
SOURCES += \
$$PWD/qeglconvenience.cpp \
- $$PWD/qeglplatformcontext.cpp
+ $$PWD/qeglplatformcontext.cpp \
+ $$PWD/qeglpbuffer.cpp
contains(QT_CONFIG,xlib) {
HEADERS += \
@@ -12,5 +14,6 @@ contains(QT_CONFIG,egl) {
SOURCES += \
$$PWD/qxlibeglintegration.cpp
}
+ CONFIG += egl
}
diff --git a/src/platformsupport/eglconvenience/qeglconvenience.cpp b/src/platformsupport/eglconvenience/qeglconvenience.cpp
index 0f40a2e34b..b711a2aebd 100644
--- a/src/platformsupport/eglconvenience/qeglconvenience.cpp
+++ b/src/platformsupport/eglconvenience/qeglconvenience.cpp
@@ -210,75 +210,106 @@ bool q_reduceConfigAttributes(QVector<EGLint> *configAttributes)
return false;
}
-EGLConfig q_configFromGLFormat(EGLDisplay display, const QSurfaceFormat &format, bool highestPixelFormat, int surfaceType)
+QEglConfigChooser::QEglConfigChooser(EGLDisplay display)
+ : m_display(display)
+ , m_surfaceType(EGL_WINDOW_BIT)
+ , m_ignore(false)
+ , m_confAttrRed(0)
+ , m_confAttrGreen(0)
+ , m_confAttrBlue(0)
+ , m_confAttrAlpha(0)
{
- EGLConfig cfg = 0;
- QVector<EGLint> configureAttributes = q_createConfigAttributesFromFormat(format);
+}
+
+QEglConfigChooser::~QEglConfigChooser()
+{
+}
+
+EGLConfig QEglConfigChooser::chooseConfig()
+{
+ QVector<EGLint> configureAttributes = q_createConfigAttributesFromFormat(m_format);
configureAttributes.append(EGL_SURFACE_TYPE);
- configureAttributes.append(surfaceType);
+ configureAttributes.append(surfaceType());
configureAttributes.append(EGL_RENDERABLE_TYPE);
- if (format.renderableType() == QSurfaceFormat::OpenVG)
+ if (m_format.renderableType() == QSurfaceFormat::OpenVG)
configureAttributes.append(EGL_OPENVG_BIT);
#ifdef EGL_VERSION_1_4
- else if (format.renderableType() == QSurfaceFormat::OpenGL)
+ else if (m_format.renderableType() == QSurfaceFormat::OpenGL)
configureAttributes.append(EGL_OPENGL_BIT);
#endif
- else if (format.majorVersion() == 1)
+ else if (m_format.majorVersion() == 1)
configureAttributes.append(EGL_OPENGL_ES_BIT);
else
configureAttributes.append(EGL_OPENGL_ES2_BIT);
configureAttributes.append(EGL_NONE);
+ EGLConfig cfg = 0;
do {
// Get the number of matching configurations for this set of properties.
EGLint matching = 0;
- if (!eglChooseConfig(display, configureAttributes.constData(), 0, 0, &matching) || !matching)
+ if (!eglChooseConfig(display(), configureAttributes.constData(), 0, 0, &matching) || !matching)
continue;
- // If we want the best pixel format, then return the first
- // matching configuration.
- if (highestPixelFormat) {
- eglChooseConfig(display, configureAttributes.constData(), &cfg, 1, &matching);
- if (matching < 1)
- continue;
- return cfg;
- }
-
// Fetch all of the matching configurations and find the
// first that matches the pixel format we wanted.
int i = configureAttributes.indexOf(EGL_RED_SIZE);
- int confAttrRed = configureAttributes.at(i+1);
+ m_confAttrRed = configureAttributes.at(i+1);
i = configureAttributes.indexOf(EGL_GREEN_SIZE);
- int confAttrGreen = configureAttributes.at(i+1);
+ m_confAttrGreen = configureAttributes.at(i+1);
i = configureAttributes.indexOf(EGL_BLUE_SIZE);
- int confAttrBlue = configureAttributes.at(i+1);
+ m_confAttrBlue = configureAttributes.at(i+1);
i = configureAttributes.indexOf(EGL_ALPHA_SIZE);
- int confAttrAlpha = i == -1 ? 0 : configureAttributes.at(i+1);
-
- EGLint size = matching;
- EGLConfig *configs = new EGLConfig [size];
- eglChooseConfig(display, configureAttributes.constData(), configs, size, &matching);
- for (EGLint index = 0; index < size; ++index) {
- EGLint red, green, blue, alpha;
- eglGetConfigAttrib(display, configs[index], EGL_RED_SIZE, &red);
- eglGetConfigAttrib(display, configs[index], EGL_GREEN_SIZE, &green);
- eglGetConfigAttrib(display, configs[index], EGL_BLUE_SIZE, &blue);
- eglGetConfigAttrib(display, configs[index], EGL_ALPHA_SIZE, &alpha);
- if ((confAttrRed == 0 || red == confAttrRed) &&
- (confAttrGreen == 0 || green == confAttrGreen) &&
- (confAttrBlue == 0 || blue == confAttrBlue) &&
- (confAttrAlpha == 0 || alpha == confAttrAlpha)) {
- cfg = configs[index];
- delete [] configs;
- return cfg;
- }
+ m_confAttrAlpha = i == -1 ? 0 : configureAttributes.at(i+1);
+
+ QVector<EGLConfig> configs(matching);
+ eglChooseConfig(display(), configureAttributes.constData(), configs.data(), configs.size(), &matching);
+ if (!cfg && matching > 0)
+ cfg = configs.first();
+
+ for (int i = 0; i < configs.size(); ++i) {
+ if (filterConfig(configs[i]))
+ return configs.at(i);
}
- delete [] configs;
} while (q_reduceConfigAttributes(&configureAttributes));
- qWarning("Cant find EGLConfig, returning null config");
- return 0;
+
+ if (!cfg)
+ qWarning("Cant find EGLConfig, returning null config");
+ return cfg;
+}
+
+bool QEglConfigChooser::filterConfig(EGLConfig config) const
+{
+ if (m_ignore)
+ return true;
+
+ EGLint red = 0;
+ EGLint green = 0;
+ EGLint blue = 0;
+ EGLint alpha = 0;
+
+ if (m_confAttrRed)
+ eglGetConfigAttrib(display(), config, EGL_RED_SIZE, &red);
+ if (m_confAttrGreen)
+ eglGetConfigAttrib(display(), config, EGL_GREEN_SIZE, &green);
+ if (m_confAttrBlue)
+ eglGetConfigAttrib(display(), config, EGL_BLUE_SIZE, &blue);
+ if (m_confAttrAlpha)
+ eglGetConfigAttrib(display(), config, EGL_ALPHA_SIZE, &alpha);
+
+ return red == m_confAttrRed && green == m_confAttrGreen
+ && blue == m_confAttrBlue && alpha == m_confAttrAlpha;
+}
+
+EGLConfig q_configFromGLFormat(EGLDisplay display, const QSurfaceFormat &format, bool highestPixelFormat, int surfaceType)
+{
+ QEglConfigChooser chooser(display);
+ chooser.setSurfaceFormat(format);
+ chooser.setSurfaceType(surfaceType);
+ chooser.setIgnoreColorChannels(highestPixelFormat);
+
+ return chooser.chooseConfig();
}
QSurfaceFormat q_glFormatFromConfig(EGLDisplay display, const EGLConfig config, const QSurfaceFormat &referenceFormat)
diff --git a/src/platformsupport/eglconvenience/qeglconvenience_p.h b/src/platformsupport/eglconvenience/qeglconvenience_p.h
index 1e5cbafa61..35c225cc2f 100644
--- a/src/platformsupport/eglconvenience/qeglconvenience_p.h
+++ b/src/platformsupport/eglconvenience/qeglconvenience_p.h
@@ -56,6 +56,41 @@ QSurfaceFormat q_glFormatFromConfig(EGLDisplay display, const EGLConfig config,
bool q_hasEglExtension(EGLDisplay display,const char* extensionName);
void q_printEglConfig(EGLDisplay display, EGLConfig config);
+class QEglConfigChooser
+{
+public:
+ QEglConfigChooser(EGLDisplay display);
+ virtual ~QEglConfigChooser();
+
+ EGLDisplay display() const { return m_display; }
+
+ void setSurfaceType(EGLint surfaceType) { m_surfaceType = surfaceType; }
+ EGLint surfaceType() const { return m_surfaceType; }
+
+ void setSurfaceFormat(const QSurfaceFormat &format) { m_format = format; }
+ QSurfaceFormat surfaceFormat() const { return m_format; }
+
+ void setIgnoreColorChannels(bool ignore) { m_ignore = ignore; }
+ bool ignoreColorChannels() const { return m_ignore; }
+
+ EGLConfig chooseConfig();
+
+protected:
+ virtual bool filterConfig(EGLConfig config) const;
+
+private:
+ QSurfaceFormat m_format;
+ EGLDisplay m_display;
+ EGLint m_surfaceType;
+ bool m_ignore;
+
+ int m_confAttrRed;
+ int m_confAttrGreen;
+ int m_confAttrBlue;
+ int m_confAttrAlpha;
+};
+
+
QT_END_NAMESPACE
#endif //QEGLCONVENIENCE_H
diff --git a/src/platformsupport/eglconvenience/qeglpbuffer.cpp b/src/platformsupport/eglconvenience/qeglpbuffer.cpp
new file mode 100644
index 0000000000..919314e9aa
--- /dev/null
+++ b/src/platformsupport/eglconvenience/qeglpbuffer.cpp
@@ -0,0 +1,76 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QOffscreenSurface>
+#include "qeglpbuffer_p.h"
+#include "qeglconvenience_p.h"
+
+QT_BEGIN_NAMESPACE
+
+QEGLPbuffer::QEGLPbuffer(EGLDisplay display, const QSurfaceFormat &format, QOffscreenSurface *offscreenSurface)
+ : QPlatformOffscreenSurface(offscreenSurface)
+ , m_format(format)
+ , m_display(display)
+ , m_pbuffer(EGL_NO_SURFACE)
+{
+ EGLConfig config = q_configFromGLFormat(m_display, m_format, false, EGL_PBUFFER_BIT);
+
+ if (config) {
+ const EGLint attributes[] = {
+ EGL_WIDTH, offscreenSurface->size().width(),
+ EGL_HEIGHT, offscreenSurface->size().height(),
+ EGL_LARGEST_PBUFFER, EGL_FALSE,
+ EGL_NONE
+ };
+
+ m_pbuffer = eglCreatePbufferSurface(m_display, config, attributes);
+
+ if (m_pbuffer != EGL_NO_SURFACE)
+ m_format = q_glFormatFromConfig(m_display, config);
+ }
+}
+
+QEGLPbuffer::~QEGLPbuffer()
+{
+ eglDestroySurface(m_display, m_pbuffer);
+}
+
+QT_END_NAMESPACE
diff --git a/src/platformsupport/eglconvenience/qeglpbuffer_p.h b/src/platformsupport/eglconvenience/qeglpbuffer_p.h
new file mode 100644
index 0000000000..1b4ac6f991
--- /dev/null
+++ b/src/platformsupport/eglconvenience/qeglpbuffer_p.h
@@ -0,0 +1,69 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QEGLPBUFFER_H
+#define QEGLPBUFFER_H
+
+#include <EGL/egl.h>
+#include <qpa/qplatformoffscreensurface.h>
+
+QT_BEGIN_NAMESPACE
+
+class QEGLPbuffer : public QPlatformOffscreenSurface
+{
+public:
+ QEGLPbuffer(EGLDisplay display, const QSurfaceFormat &format, QOffscreenSurface *offscreenSurface);
+ ~QEGLPbuffer();
+
+ QSurfaceFormat format() const { return m_format; }
+ bool isValid() const { return m_pbuffer != EGL_NO_SURFACE; }
+
+ EGLSurface pbuffer() const { return m_pbuffer; }
+
+private:
+ QSurfaceFormat m_format;
+ EGLDisplay m_display;
+ EGLSurface m_pbuffer;
+};
+
+QT_END_NAMESPACE
+
+#endif // QEGLPBUFFER_H
diff --git a/src/platformsupport/eglconvenience/qeglplatformcontext.cpp b/src/platformsupport/eglconvenience/qeglplatformcontext.cpp
index 7cce8d89d5..8152f74067 100644
--- a/src/platformsupport/eglconvenience/qeglplatformcontext.cpp
+++ b/src/platformsupport/eglconvenience/qeglplatformcontext.cpp
@@ -63,9 +63,23 @@ QEGLPlatformContext::QEGLPlatformContext(const QSurfaceFormat &format, QPlatform
EGLenum eglApi)
: m_eglDisplay(display)
, m_eglApi(eglApi)
- , m_eglConfig(q_configFromGLFormat(display, format, true))
- , m_format(q_glFormatFromConfig(display, m_eglConfig))
+ , m_eglConfig(q_configFromGLFormat(display, format))
{
+ init(format, share);
+}
+
+QEGLPlatformContext::QEGLPlatformContext(const QSurfaceFormat &format, QPlatformOpenGLContext *share, EGLDisplay display,
+ EGLConfig config, EGLenum eglApi)
+ : m_eglDisplay(display)
+ , m_eglApi(eglApi)
+ , m_eglConfig(config)
+{
+ init(format, share);
+}
+
+void QEGLPlatformContext::init(const QSurfaceFormat &format, QPlatformOpenGLContext *share)
+{
+ m_format = q_glFormatFromConfig(m_eglDisplay, m_eglConfig);
m_shareContext = share ? static_cast<QEGLPlatformContext *>(share)->m_eglContext : 0;
QVector<EGLint> contextAttrs;
diff --git a/src/platformsupport/eglconvenience/qeglplatformcontext_p.h b/src/platformsupport/eglconvenience/qeglplatformcontext_p.h
index 76002da2df..952f5a856a 100644
--- a/src/platformsupport/eglconvenience/qeglplatformcontext_p.h
+++ b/src/platformsupport/eglconvenience/qeglplatformcontext_p.h
@@ -51,6 +51,8 @@ class QEGLPlatformContext : public QPlatformOpenGLContext
public:
QEGLPlatformContext(const QSurfaceFormat &format, QPlatformOpenGLContext *share, EGLDisplay display,
EGLenum eglApi = EGL_OPENGL_ES_API);
+ QEGLPlatformContext(const QSurfaceFormat &format, QPlatformOpenGLContext *share, EGLDisplay display,
+ EGLConfig config, EGLenum eglApi = EGL_OPENGL_ES_API);
~QEGLPlatformContext();
bool makeCurrent(QPlatformSurface *surface);
@@ -70,12 +72,14 @@ protected:
virtual EGLSurface eglSurfaceForPlatformSurface(QPlatformSurface *surface) = 0;
private:
+ void init(const QSurfaceFormat &format, QPlatformOpenGLContext *share);
+
EGLContext m_eglContext;
EGLContext m_shareContext;
EGLDisplay m_eglDisplay;
EGLenum m_eglApi;
EGLConfig m_eglConfig;
- const QSurfaceFormat m_format;
+ QSurfaceFormat m_format;
};
#endif //QEGLPLATFORMCONTEXT_H
diff --git a/src/platformsupport/fbconvenience/qfbcursor.cpp b/src/platformsupport/fbconvenience/qfbcursor.cpp
index ac2fc8528c..fecf9f6380 100644
--- a/src/platformsupport/fbconvenience/qfbcursor.cpp
+++ b/src/platformsupport/fbconvenience/qfbcursor.cpp
@@ -120,7 +120,7 @@ void QFbCursor::setCursor(const uchar *data, const uchar *mask, int width, int h
void QFbCursor::changeCursor(QCursor * widgetCursor, QWindow *window)
{
Q_UNUSED(window);
- Qt::CursorShape shape = widgetCursor->shape();
+ const Qt::CursorShape shape = widgetCursor ? widgetCursor->shape() : Qt::ArrowCursor;
if (shape == Qt::BitmapCursor) {
// application supplied cursor
diff --git a/src/platformsupport/fbconvenience/qfbscreen.cpp b/src/platformsupport/fbconvenience/qfbscreen.cpp
index efabf6e2a8..6427b62972 100644
--- a/src/platformsupport/fbconvenience/qfbscreen.cpp
+++ b/src/platformsupport/fbconvenience/qfbscreen.cpp
@@ -45,6 +45,7 @@
#include "qfbbackingstore_p.h"
#include <QtGui/QPainter>
+#include <qpa/qwindowsysteminterface.h>
QT_BEGIN_NAMESPACE
@@ -72,6 +73,9 @@ void QFbScreen::addWindow(QFbWindow *window)
mWindowStack.prepend(window);
invalidateRectCache();
setDirty(window->geometry());
+ QWindow *w = topWindow();
+ QWindowSystemInterface::handleWindowActivated(w);
+ topWindowChanged(w);
}
void QFbScreen::removeWindow(QFbWindow *window)
@@ -79,6 +83,9 @@ void QFbScreen::removeWindow(QFbWindow *window)
mWindowStack.removeOne(window);
invalidateRectCache();
setDirty(window->geometry());
+ QWindow *w = topWindow();
+ QWindowSystemInterface::handleWindowActivated(w);
+ topWindowChanged(w);
}
void QFbScreen::raise(QFbWindow *window)
@@ -89,6 +96,9 @@ void QFbScreen::raise(QFbWindow *window)
mWindowStack.move(index, 0);
invalidateRectCache();
setDirty(window->geometry());
+ QWindow *w = topWindow();
+ QWindowSystemInterface::handleWindowActivated(w);
+ topWindowChanged(w);
}
void QFbScreen::lower(QFbWindow *window)
@@ -99,20 +109,25 @@ void QFbScreen::lower(QFbWindow *window)
mWindowStack.move(index, mWindowStack.size() - 1);
invalidateRectCache();
setDirty(window->geometry());
+ QWindow *w = topWindow();
+ QWindowSystemInterface::handleWindowActivated(w);
+ topWindowChanged(w);
+}
+
+QWindow *QFbScreen::topWindow() const
+{
+ foreach (QFbWindow *fbw, mWindowStack)
+ if (fbw->window()->type() == Qt::Window || fbw->window()->type() == Qt::Dialog)
+ return fbw->window();
+ return 0;
}
QWindow *QFbScreen::topLevelAt(const QPoint & p) const
{
- Q_UNUSED(p);
-#if 0
- for (int i = 0; i < mWindowStack.size(); i++) {
- if (mWindowStack[i]->geometry().contains(p, false) &&
- mWindowStack[i]->visible() &&
- !mWindowStack[i]->widget()->isMinimized()) {
- return mWindowStack[i]->widget();
- }
+ foreach (QFbWindow *fbw, mWindowStack) {
+ if (fbw->geometry().contains(p, false) && fbw->window()->isVisible())
+ return fbw->window();
}
-#endif
return 0;
}
@@ -126,6 +141,24 @@ void QFbScreen::setDirty(const QRect &rect)
}
}
+void QFbScreen::setPhysicalSize(const QSize &size)
+{
+ mPhysicalSize = size;
+}
+
+void QFbScreen::setGeometry(const QRect &rect)
+{
+ delete mCompositePainter;
+ mCompositePainter = 0;
+ delete mScreenImage;
+ mGeometry = rect;
+ mScreenImage = new QImage(mGeometry.size(), mFormat);
+ invalidateRectCache();
+ QWindowSystemInterface::handleScreenGeometryChange(QPlatformScreen::screen(), geometry());
+ QWindowSystemInterface::handleScreenAvailableGeometryChange(QPlatformScreen::screen(), availableGeometry());
+ resizeMaximizedWindows();
+}
+
void QFbScreen::generateRects()
{
mCachedRects.clear();
diff --git a/src/platformsupport/fbconvenience/qfbscreen_p.h b/src/platformsupport/fbconvenience/qfbscreen_p.h
index 00e3f9bef4..c7106358d9 100644
--- a/src/platformsupport/fbconvenience/qfbscreen_p.h
+++ b/src/platformsupport/fbconvenience/qfbscreen_p.h
@@ -64,6 +64,7 @@ public:
virtual QImage::Format format() const { return mFormat; }
virtual QSizeF physicalSize() const { return mPhysicalSize; }
+ QWindow *topWindow() const;
virtual QWindow *topLevelAt(const QPoint & p) const;
// compositor api
@@ -71,7 +72,12 @@ public:
virtual void removeWindow(QFbWindow *window);
virtual void raise(QFbWindow *window);
virtual void lower(QFbWindow *window);
+ virtual void topWindowChanged(QWindow *) {}
+
+public slots:
virtual void setDirty(const QRect &rect);
+ void setPhysicalSize(const QSize &size);
+ void setGeometry(const QRect &rect);
protected slots:
virtual QRegion doRedraw();
diff --git a/src/platformsupport/fbconvenience/qfbwindow.cpp b/src/platformsupport/fbconvenience/qfbwindow.cpp
index e052907c79..246f50b4a9 100644
--- a/src/platformsupport/fbconvenience/qfbwindow.cpp
+++ b/src/platformsupport/fbconvenience/qfbwindow.cpp
@@ -43,6 +43,7 @@
#include "qfbscreen_p.h"
#include <QtGui/QScreen>
+#include <qpa/qwindowsysteminterface.h>
QT_BEGIN_NAMESPACE
@@ -71,7 +72,7 @@ void QFbWindow::setGeometry(const QRect &rect)
mOldGeometry = geometry();
platformScreen()->invalidateRectCache();
- //### QWindowSystemInterface::handleGeometryChange(window(), rect);
+ QWindowSystemInterface::handleGeometryChange(window(), rect);
QPlatformWindow::setGeometry(rect);
}
diff --git a/src/platformsupport/fbconvenience/qfbwindow_p.h b/src/platformsupport/fbconvenience/qfbwindow_p.h
index 8c7d5c6b7a..25e2afca14 100644
--- a/src/platformsupport/fbconvenience/qfbwindow_p.h
+++ b/src/platformsupport/fbconvenience/qfbwindow_p.h
@@ -58,7 +58,7 @@ public:
virtual void raise();
virtual void lower();
- void setGeometry(const QRect &rect);
+ virtual void setGeometry(const QRect &rect);
virtual void setWindowFlags(Qt::WindowFlags type);
virtual Qt::WindowFlags windowFlags() const;
diff --git a/src/platformsupport/fontdatabases/basic/qbasicfontdatabase.cpp b/src/platformsupport/fontdatabases/basic/qbasicfontdatabase.cpp
index a74516214b..49440c8566 100644
--- a/src/platformsupport/fontdatabases/basic/qbasicfontdatabase.cpp
+++ b/src/platformsupport/fontdatabases/basic/qbasicfontdatabase.cpp
@@ -60,82 +60,6 @@
QT_BEGIN_NAMESPACE
-#define SimplifiedChineseCsbBit 18
-#define TraditionalChineseCsbBit 20
-#define JapaneseCsbBit 17
-#define KoreanCsbBit 21
-
-static int requiredUnicodeBits[QFontDatabase::WritingSystemsCount][2] = {
- // Any,
- { 127, 127 },
- // Latin,
- { 0, 127 },
- // Greek,
- { 7, 127 },
- // Cyrillic,
- { 9, 127 },
- // Armenian,
- { 10, 127 },
- // Hebrew,
- { 11, 127 },
- // Arabic,
- { 13, 127 },
- // Syriac,
- { 71, 127 },
- //Thaana,
- { 72, 127 },
- //Devanagari,
- { 15, 127 },
- //Bengali,
- { 16, 127 },
- //Gurmukhi,
- { 17, 127 },
- //Gujarati,
- { 18, 127 },
- //Oriya,
- { 19, 127 },
- //Tamil,
- { 20, 127 },
- //Telugu,
- { 21, 127 },
- //Kannada,
- { 22, 127 },
- //Malayalam,
- { 23, 127 },
- //Sinhala,
- { 73, 127 },
- //Thai,
- { 24, 127 },
- //Lao,
- { 25, 127 },
- //Tibetan,
- { 70, 127 },
- //Myanmar,
- { 74, 127 },
- // Georgian,
- { 26, 127 },
- // Khmer,
- { 80, 127 },
- // SimplifiedChinese,
- { 126, 127 },
- // TraditionalChinese,
- { 126, 127 },
- // Japanese,
- { 126, 127 },
- // Korean,
- { 56, 127 },
- // Vietnamese,
- { 0, 127 }, // same as latin1
- // Other,
- { 126, 127 },
- // Ogham,
- { 78, 127 },
- // Runic,
- { 79, 127 },
- // Nko,
- { 14, 127 },
-};
-
typedef struct {
quint16 majorVersion;
quint16 minorVersion;
@@ -167,58 +91,10 @@ typedef struct {
quint16 stringOffset;
} NAME_RECORD;
-QSupportedWritingSystems QBasicFontDatabase::determineWritingSystemsFromTrueTypeBits(quint32 unicodeRange[4], quint32 codePageRange[2])
-{
- QSupportedWritingSystems writingSystems;
- bool hasScript = false;
-
- int i;
- for(i = 0; i < QFontDatabase::WritingSystemsCount; i++) {
- int bit = requiredUnicodeBits[i][0];
- int index = bit/32;
- int flag = 1 << (bit&31);
- if (bit != 126 && unicodeRange[index] & flag) {
- bit = requiredUnicodeBits[i][1];
- index = bit/32;
-
- flag = 1 << (bit&31);
- if (bit == 127 || unicodeRange[index] & flag) {
- writingSystems.setSupported(QFontDatabase::WritingSystem(i));
- hasScript = true;
- // qDebug("font %s: index=%d, flag=%8x supports script %d", familyName.latin1(), index, flag, i);
- }
- }
- }
- if(codePageRange[0] & (1 << SimplifiedChineseCsbBit)) {
- writingSystems.setSupported(QFontDatabase::SimplifiedChinese);
- hasScript = true;
- //qDebug("font %s supports Simplified Chinese", familyName.latin1());
- }
- if(codePageRange[0] & (1 << TraditionalChineseCsbBit)) {
- writingSystems.setSupported(QFontDatabase::TraditionalChinese);
- hasScript = true;
- //qDebug("font %s supports Traditional Chinese", familyName.latin1());
- }
- if(codePageRange[0] & (1 << JapaneseCsbBit)) {
- writingSystems.setSupported(QFontDatabase::Japanese);
- hasScript = true;
- //qDebug("font %s supports Japanese", familyName.latin1());
- }
- if(codePageRange[0] & (1 << KoreanCsbBit)) {
- writingSystems.setSupported(QFontDatabase::Korean);
- hasScript = true;
- //qDebug("font %s supports Korean", familyName.latin1());
- }
- if (!hasScript)
- writingSystems.setSupported(QFontDatabase::Symbol);
-
- return writingSystems;
-}
-
static inline bool scriptRequiresOpenType(int script)
{
- return ((script >= QUnicodeTables::Syriac && script <= QUnicodeTables::Sinhala)
- || script == QUnicodeTables::Khmer || script == QUnicodeTables::Nko);
+ return ((script >= QChar::Script_Syriac && script <= QChar::Script_Sinhala)
+ || script == QChar::Script_Khmer || script == QChar::Script_Nko);
}
void QBasicFontDatabase::populateFontDatabase()
@@ -242,7 +118,7 @@ void QBasicFontDatabase::populateFontDatabase()
}
}
-QFontEngine *QBasicFontDatabase::fontEngine(const QFontDef &fontDef, QUnicodeTables::Script script, void *usrPtr)
+QFontEngine *QBasicFontDatabase::fontEngine(const QFontDef &fontDef, QChar::Script script, void *usrPtr)
{
QFontEngineFT *engine;
FontFile *fontfile = static_cast<FontFile *> (usrPtr);
@@ -262,8 +138,7 @@ QFontEngine *QBasicFontDatabase::fontEngine(const QFontDef &fontDef, QUnicodeTab
delete engine;
engine = 0;
} else if (scriptRequiresOpenType(script)) {
- HB_Face hbFace = engine->initializedHarfbuzzFace();
- if (!hbFace || !hbFace->supported_scripts[script]) {
+ if (!engine->supportsScript(script)) {
delete engine;
engine = 0;
}
@@ -337,7 +212,7 @@ QFontEngine *QBasicFontDatabase::fontEngine(const QByteArray &fontData, qreal pi
return fe;
}
-QStringList QBasicFontDatabase::fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const
+QStringList QBasicFontDatabase::fallbacksForFamily(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script) const
{
Q_UNUSED(family);
Q_UNUSED(style);
@@ -415,7 +290,7 @@ QStringList QBasicFontDatabase::addTTFile(const QByteArray &fontData, const QByt
quint32(os2->ulCodePageRange2)
};
- writingSystems = determineWritingSystemsFromTrueTypeBits(unicodeRange, codePageRange);
+ writingSystems = QPlatformFontDatabase::writingSystemsFromTrueTypeBits(unicodeRange, codePageRange);
if (os2->usWeightClass == 0)
;
diff --git a/src/platformsupport/fontdatabases/basic/qbasicfontdatabase_p.h b/src/platformsupport/fontdatabases/basic/qbasicfontdatabase_p.h
index 23f60fc611..4d6fd2ceeb 100644
--- a/src/platformsupport/fontdatabases/basic/qbasicfontdatabase_p.h
+++ b/src/platformsupport/fontdatabases/basic/qbasicfontdatabase_p.h
@@ -58,14 +58,13 @@ class QBasicFontDatabase : public QPlatformFontDatabase
{
public:
void populateFontDatabase();
- QFontEngine *fontEngine(const QFontDef &fontDef, QUnicodeTables::Script script, void *handle);
+ QFontEngine *fontEngine(const QFontDef &fontDef, QChar::Script script, void *handle);
QFontEngine *fontEngine(const QByteArray &fontData, qreal pixelSize, QFont::HintingPreference hintingPreference);
- QStringList fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const;
+ QStringList fallbacksForFamily(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script) const;
QStringList addApplicationFont(const QByteArray &fontData, const QString &fileName);
void releaseHandle(void *handle);
static QStringList addTTFile(const QByteArray &fontData, const QByteArray &file);
- static QSupportedWritingSystems determineWritingSystemsFromTrueTypeBits(quint32 unicodeRange[4], quint32 codePageRange[2]);
static QString fontNameFromTTFile(const QString &filename);
};
diff --git a/src/platformsupport/fontdatabases/fontconfig/qfontconfigdatabase.cpp b/src/platformsupport/fontdatabases/fontconfig/qfontconfigdatabase.cpp
index 84eb6613a3..6ba71d112e 100644
--- a/src/platformsupport/fontdatabases/fontconfig/qfontconfigdatabase.cpp
+++ b/src/platformsupport/fontdatabases/fontconfig/qfontconfigdatabase.cpp
@@ -75,10 +75,11 @@ static inline bool requiresOpenType(int writingSystem)
return ((writingSystem >= QFontDatabase::Syriac && writingSystem <= QFontDatabase::Sinhala)
|| writingSystem == QFontDatabase::Khmer || writingSystem == QFontDatabase::Nko);
}
+
static inline bool scriptRequiresOpenType(int script)
{
- return ((script >= QUnicodeTables::Syriac && script <= QUnicodeTables::Sinhala)
- || script == QUnicodeTables::Khmer || script == QUnicodeTables::Nko);
+ return ((script >= QChar::Script_Syriac && script <= QChar::Script_Sinhala)
+ || script == QChar::Script_Khmer || script == QChar::Script_Nko);
}
static int getFCWeight(int fc_weight)
@@ -97,14 +98,17 @@ static int getFCWeight(int fc_weight)
}
static const char *specialLanguages[] = {
- "en", // Common
+ "", // Unknown
+ "", // Inherited
+ "", // Common
+ "en", // Latin
"el", // Greek
"ru", // Cyrillic
"hy", // Armenian
"he", // Hebrew
"ar", // Arabic
"syr", // Syriac
- "div", // Thaana
+ "dv", // Thaana
"hi", // Devanagari
"bn", // Bengali
"pa", // Gurmukhi
@@ -121,45 +125,85 @@ static const char *specialLanguages[] = {
"my", // Myanmar
"ka", // Georgian
"ko", // Hangul
- "", // Ogham
- "", // Runic
+ "am", // Ethiopic
+ "chr", // Cherokee
+ "cr", // CanadianAboriginal
+ "sga", // Ogham
+ "non", // Runic
"km", // Khmer
- "" // N'Ko
+ "mn", // Mongolian
+ "ja", // Hiragana
+ "ja", // Katakana
+ "zh-TW", // Bopomofo
+ "", // Han
+ "ii", // Yi
+ "ett", // OldItalic
+ "got", // Gothic
+ "en", // Deseret
+ "fil", // Tagalog
+ "hnn", // Hanunoo
+ "bku", // Buhid
+ "tbw", // Tagbanwa
+ "cop", // Coptic
+ "lif", // Limbu
+ "tdd", // TaiLe
+ "grc", // LinearB
+ "uga", // Ugaritic
+ "en", // Shavian
+ "so", // Osmanya
+ "grc", // Cypriot
+ "", // Braille
+ "bug", // Buginese
+ "khb", // NewTaiLue
+ "cu", // Glagolitic
+ "shi", // Tifinagh
+ "syl", // SylotiNagri
+ "peo", // OldPersian
+ "pra", // Kharoshthi
+ "ban", // Balinese
+ "akk", // Cuneiform
+ "phn", // Phoenician
+ "lzh", // PhagsPa
+ "man", // Nko
+ "su", // Sundanese
+ "lep", // Lepcha
+ "sat", // OlChiki
+ "vai", // Vai
+ "saz", // Saurashtra
+ "eky", // KayahLi
+ "rej", // Rejang
+ "xlc", // Lycian
+ "xcr", // Carian
+ "xld", // Lydian
+ "cjm", // Cham
+ "nod", // TaiTham
+ "blt", // TaiViet
+ "ae", // Avestan
+ "egy", // EgyptianHieroglyphs
+ "smp", // Samaritan
+ "lis", // Lisu
+ "bax", // Bamum
+ "jv", // Javanese
+ "mni", // MeeteiMayek
+ "arc", // ImperialAramaic
+ "xsa", // OldSouthArabian
+ "xpr", // InscriptionalParthian
+ "pal", // InscriptionalPahlavi
+ "otk", // OldTurkic
+ "bh", // Kaithi
+ "bbc", // Batak
+ "pra", // Brahmi
+ "myz", // Mandaic
+ "ccp", // Chakma
+ "xmr", // MeroiticCursive
+ "xmr", // MeroiticHieroglyphs
+ "hmd", // Miao
+ "sa", // Sharada
+ "srb", // SoraSompeng
+ "doi" // Takri
};
enum { SpecialLanguageCount = sizeof(specialLanguages) / sizeof(const char *) };
-static const ushort specialChars[] = {
- 0, // English
- 0, // Greek
- 0, // Cyrillic
- 0, // Armenian
- 0, // Hebrew
- 0, // Arabic
- 0, // Syriac
- 0, // Thaana
- 0, // Devanagari
- 0, // Bengali
- 0, // Gurmukhi
- 0, // Gujarati
- 0, // Oriya
- 0, // Tamil
- 0xc15, // Telugu
- 0xc95, // Kannada
- 0xd15, // Malayalam
- 0xd9a, // Sinhala
- 0, // Thai
- 0, // Lao
- 0, // Tibetan
- 0x1000, // Myanmar
- 0, // Georgian
- 0, // Hangul
- 0x1681, // Ogham
- 0x16a0, // Runic
- 0, // Khmer
- 0x7ca // N'Ko
-};
-enum { SpecialCharCount = sizeof(specialChars) / sizeof(ushort) };
-
// this could become a list of all languages used for each writing
// system, instead of using the single most common language.
static const char *languageForWritingSystem[] = {
@@ -194,9 +238,9 @@ static const char *languageForWritingSystem[] = {
"ko", // Korean
"vi", // Vietnamese
0, // Symbol
- 0, // Ogham
- 0, // Runic
- 0 // N'Ko
+ "sga", // Ogham
+ "non", // Runic
+ "man" // N'Ko
};
enum { LanguageCount = sizeof(languageForWritingSystem) / sizeof(const char *) };
@@ -306,6 +350,26 @@ static const char *getFcFamilyForStyleHint(const QFont::StyleHint style)
return stylehint;
}
+static bool isSymbolFont(FontFile *fontFile)
+{
+ if (fontFile == 0 || fontFile->fileName.isEmpty())
+ return false;
+
+ QFontEngine::FaceId id;
+ id.filename = fontFile->fileName.toLocal8Bit();
+ id.index = fontFile->indexValue;
+
+ QFreetypeFace *f = QFreetypeFace::getFace(id);
+ if (f == 0) {
+ qWarning("isSymbolFont: Couldn't open face %s/%d", id.filename.data(), id.index);
+ return false;
+ }
+
+ bool hasSymbolMap = f->symbol_map;
+ f->release(id);
+ return hasSymbolMap;
+}
+
void QFontconfigDatabase::populateFontDatabase()
{
FcFontSet *fonts;
@@ -402,7 +466,7 @@ void QFontconfigDatabase::populateFontDatabase()
// some languages are not supported by FontConfig, we rather check the
// charset to detect these
for (int i = 1; i < SampleCharCount; ++i) {
- if (!sampleCharForWritingSystem[i])
+ if (!sampleCharForWritingSystem[i] || writingSystems.supported(QFontDatabase::WritingSystem(i)))
continue;
if (FcCharSetHasChar(cs, sampleCharForWritingSystem[i]))
writingSystems.setSupported(QFontDatabase::WritingSystem(i));
@@ -425,6 +489,9 @@ void QFontconfigDatabase::populateFontDatabase()
fontFile->fileName = QLatin1String((const char *)file_value);
fontFile->indexValue = indexValue;
+ if (isSymbolFont(fontFile))
+ writingSystems.setSupported(QFontDatabase::Other);
+
QFont::Style style = (slant_value == FC_SLANT_ITALIC)
? QFont::StyleItalic
: ((slant_value == FC_SLANT_OBLIQUE)
@@ -481,13 +548,12 @@ void QFontconfigDatabase::populateFontDatabase()
// QApplication::setFont(font);
}
-QFontEngineMulti *QFontconfigDatabase::fontEngineMulti(QFontEngine *fontEngine,
- QUnicodeTables::Script script)
+QFontEngineMulti *QFontconfigDatabase::fontEngineMulti(QFontEngine *fontEngine, QChar::Script script)
{
return new QFontEngineMultiFontConfig(fontEngine, script);
}
-QFontEngine *QFontconfigDatabase::fontEngine(const QFontDef &f, QUnicodeTables::Script script, void *usrPtr)
+QFontEngine *QFontconfigDatabase::fontEngine(const QFontDef &f, QChar::Script script, void *usrPtr)
{
if (!usrPtr)
return 0;
@@ -595,8 +661,7 @@ QFontEngine *QFontconfigDatabase::fontEngine(const QFontDef &f, QUnicodeTables::
delete engine;
engine = 0;
} else if (scriptRequiresOpenType(script)) {
- HB_Face hbFace = engine->initializedHarfbuzzFace();
- if (!hbFace || !hbFace->supported_scripts[script]) {
+ if (!engine->supportsScript(script)) {
delete engine;
engine = 0;
}
@@ -605,7 +670,7 @@ QFontEngine *QFontconfigDatabase::fontEngine(const QFontDef &f, QUnicodeTables::
return engine;
}
-QStringList QFontconfigDatabase::fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const
+QStringList QFontconfigDatabase::fallbacksForFamily(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script) const
{
QStringList fallbackFamilies;
FcPattern *pattern = FcPatternCreate();
@@ -625,18 +690,18 @@ QStringList QFontconfigDatabase::fallbacksForFamily(const QString family, const
slant_value = FC_SLANT_OBLIQUE;
FcPatternAddInteger(pattern, FC_SLANT, slant_value);
- if (script != QUnicodeTables::Common && *specialLanguages[script] != '\0') {
- Q_ASSERT(script < QUnicodeTables::ScriptCount);
+ Q_ASSERT(uint(script) < SpecialLanguageCount);
+ if (*specialLanguages[script] != '\0') {
FcLangSet *ls = FcLangSetCreate();
FcLangSetAdd(ls, (const FcChar8*)specialLanguages[script]);
FcPatternAddLangSet(pattern, FC_LANG, ls);
FcLangSetDestroy(ls);
} else if (!family.isEmpty()) {
- // If script is common then it may include languages like CJK,
+ // If script is Common or Han, then it may include languages like CJK,
// we should attach system default language set to the pattern
// to obtain correct font fallback list (i.e. if LANG=zh_CN
// then we normally want to use a Chinese font for CJK text;
- // while a Japanese font should be use for that if LANG=ja)
+ // while a Japanese font should be used for that if LANG=ja)
FcPattern *dummy = FcPatternCreate();
FcDefaultSubstitute(dummy);
FcChar8 *lang = 0;
diff --git a/src/platformsupport/fontdatabases/fontconfig/qfontconfigdatabase_p.h b/src/platformsupport/fontdatabases/fontconfig/qfontconfigdatabase_p.h
index cb05ef4722..6d6dae680e 100644
--- a/src/platformsupport/fontdatabases/fontconfig/qfontconfigdatabase_p.h
+++ b/src/platformsupport/fontdatabases/fontconfig/qfontconfigdatabase_p.h
@@ -51,9 +51,9 @@ class QFontconfigDatabase : public QBasicFontDatabase
{
public:
void populateFontDatabase();
- QFontEngineMulti *fontEngineMulti(QFontEngine *fontEngine, QUnicodeTables::Script script);
- QFontEngine *fontEngine(const QFontDef &fontDef, QUnicodeTables::Script script, void *handle);
- QStringList fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const;
+ QFontEngineMulti *fontEngineMulti(QFontEngine *fontEngine, QChar::Script script);
+ QFontEngine *fontEngine(const QFontDef &fontDef, QChar::Script script, void *handle);
+ QStringList fallbacksForFamily(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script) const;
QStringList addApplicationFont(const QByteArray &fontData, const QString &fileName);
QString resolveFontFamilyAlias(const QString &family) const;
QFont defaultFont() const;
diff --git a/src/platformsupport/fontdatabases/fontdatabases.pri b/src/platformsupport/fontdatabases/fontdatabases.pri
index 003017473b..12b06d64cc 100644
--- a/src/platformsupport/fontdatabases/fontdatabases.pri
+++ b/src/platformsupport/fontdatabases/fontdatabases.pri
@@ -1,5 +1,3 @@
-DEFINES += QT_COMPILES_IN_HARFBUZZ
-
!win32|contains(QT_CONFIG, freetype):!mac {
include($$PWD/basic/basic.pri)
}
diff --git a/src/platformsupport/fontdatabases/genericunix/qgenericunixfontdatabase_p.h b/src/platformsupport/fontdatabases/genericunix/qgenericunixfontdatabase_p.h
index 1995ead657..a8a0b8fe9c 100644
--- a/src/platformsupport/fontdatabases/genericunix/qgenericunixfontdatabase_p.h
+++ b/src/platformsupport/fontdatabases/genericunix/qgenericunixfontdatabase_p.h
@@ -42,6 +42,8 @@
#ifndef QGENERICUNIXFONTDATABASE_H
#define QGENERICUNIXFONTDATABASE_H
+#include <QtCore/qglobal.h>
+
#ifdef Q_FONTCONFIGDATABASE
#include <QtPlatformSupport/private/qfontconfigdatabase_p.h>
typedef QFontconfigDatabase QGenericUnixFontDatabase;
diff --git a/src/platformsupport/fontdatabases/mac/coretext.pri b/src/platformsupport/fontdatabases/mac/coretext.pri
index f7977964fe..d1abf123aa 100644
--- a/src/platformsupport/fontdatabases/mac/coretext.pri
+++ b/src/platformsupport/fontdatabases/mac/coretext.pri
@@ -1,2 +1,10 @@
HEADERS += $$PWD/qcoretextfontdatabase_p.h $$PWD/qfontengine_coretext_p.h
OBJECTIVE_SOURCES += $$PWD/qfontengine_coretext.mm $$PWD/qcoretextfontdatabase.mm
+
+ios: \
+ # On iOS CoreText and CoreGraphics are stand-alone frameworks
+ LIBS += -framework CoreText -framework CoreGraphics
+else: \
+ # On Mac OS they are part of the ApplicationServices umbrella framework,
+ # even in 10.8 where they were also made available stand-alone.
+ LIBS += -framework ApplicationServices
diff --git a/src/platformsupport/fontdatabases/mac/qcoretextfontdatabase.mm b/src/platformsupport/fontdatabases/mac/qcoretextfontdatabase.mm
index d59bd5f116..fbd836f763 100644
--- a/src/platformsupport/fontdatabases/mac/qcoretextfontdatabase.mm
+++ b/src/platformsupport/fontdatabases/mac/qcoretextfontdatabase.mm
@@ -39,6 +39,8 @@
**
****************************************************************************/
+#include "qglobal.h"
+
#ifndef Q_OS_IOS
#import <Cocoa/Cocoa.h>
#import <IOKit/graphics/IOGraphicsLib.h>
@@ -85,28 +87,12 @@ static const char *languageForWritingSystem[] = {
"ko", // Korean
"vi", // Vietnamese
0, // Symbol
- 0, // Ogham
- 0, // Runic
- 0 // N'Ko
+ "sga", // Ogham
+ "non", // Runic
+ "man" // N'Ko
};
enum { LanguageCount = sizeof(languageForWritingSystem) / sizeof(const char *) };
-QFont::StyleHint styleHintFromNSString(NSString *style)
-{
- if ([style isEqual: @"sans-serif"])
- return QFont::SansSerif;
- else if ([style isEqual: @"monospace"])
- return QFont::Monospace;
- else if ([style isEqual: @"cursive"])
- return QFont::Cursive;
- else if ([style isEqual: @"serif"])
- return QFont::Serif;
- else if ([style isEqual: @"fantasy"])
- return QFont::Fantasy;
- else // if ([style isEqual: @"default"])
- return QFont::AnyStyle;
-}
-
static NSInteger languageMapSort(id obj1, id obj2, void *context)
{
NSArray *map1 = (NSArray *) obj1;
@@ -188,27 +174,6 @@ QCoreTextFontDatabase::~QCoreTextFontDatabase()
{
}
-static QString familyNameFromPostScriptName(QHash<QString, QString> &psNameToFamily,
- NSString *psName)
-{
- QString name = QCFString::toQString(psName);
- if (psNameToFamily.contains(name))
- return psNameToFamily[name];
- else {
- // Some of the font name in DefaultFontFallbacks.plist are hidden fonts like AquaHiraKaku,
- // their family name begins with a dot, like ".AquaHiraKaku" or ".Apple Symbols Fallback",
- // the only way (I've found) to get it are actually creating a CTFont with them. We only
- // need to do it once though.
- QCFType<CTFontRef> font = CTFontCreateWithName((CFStringRef) psName, 12.0, NULL);
- if (font) {
- QCFString family = CTFontCopyFamilyName(font);
- psNameToFamily[name] = family;
- return family;
- }
- return name;
- }
-}
-
void QCoreTextFontDatabase::populateFontDatabase()
{
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
@@ -223,7 +188,6 @@ void QCoreTextFontDatabase::populateFontDatabase()
QString foundryName = QLatin1String("CoreText");
const int numFonts = CFArrayGetCount(fonts);
- QHash<QString, QString> psNameToFamily;
for (int i = 0; i < numFonts; ++i) {
CTFontDescriptorRef font = (CTFontDescriptorRef) CFArrayGetValueAtIndex(fonts, i);
QCFString familyName = (CFStringRef) CTFontDescriptorCopyLocalizedAttribute(font, kCTFontFamilyNameAttribute, NULL);
@@ -289,35 +253,14 @@ void QCoreTextFontDatabase::populateFontDatabase()
QPlatformFontDatabase::registerFont(familyName, styleName, foundryName, weight, style, stretch,
true /* antialiased */, true /* scalable */,
pixelSize, fixedPitch, writingSystems, (void *) font);
+
+ // We need to map back and forth between PostScript-names and family-names for fallback list construction
CFStringRef psName = (CFStringRef) CTFontDescriptorCopyAttribute(font, kCTFontNameAttribute);
- // we need PostScript Name to family name mapping for fallback list construction
psNameToFamily[QCFString::toQString((NSString *) psName)] = familyName;
+ familyNameToPsName[familyName] = QCFString::toQString((NSString *) psName);
CFRelease(psName);
}
- NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
- NSArray *languages = [defaults stringArrayForKey: @"AppleLanguages"];
-
- NSDictionary *fallbackDict = [NSDictionary dictionaryWithContentsOfFile: @"/System/Library/Frameworks/ApplicationServices.framework/Frameworks/CoreText.framework/Resources/DefaultFontFallbacks.plist"];
-
- for (NSString *style in [fallbackDict allKeys]) {
- NSArray *list = [fallbackDict valueForKey: style];
- QFont::StyleHint styleHint = styleHintFromNSString(style);
- QStringList fallbackList;
- for (id item in list) {
- // sort the array based on system language preferences
- if ([item isKindOfClass: [NSArray class]]) {
- NSArray *langs = [(NSArray *) item sortedArrayUsingFunction: languageMapSort
- context: languages];
- for (NSArray *map in langs)
- fallbackList.append(familyNameFromPostScriptName(psNameToFamily, [map objectAtIndex: 1]));
- }
- else if ([item isKindOfClass: [NSString class]])
- fallbackList.append(familyNameFromPostScriptName(psNameToFamily, item));
- }
- fallbackLists[styleHint] = fallbackList;
- }
-
[pool release];
}
@@ -326,7 +269,7 @@ void QCoreTextFontDatabase::releaseHandle(void *handle)
CFRelease(CTFontDescriptorRef(handle));
}
-QFontEngine *QCoreTextFontDatabase::fontEngine(const QFontDef &f, QUnicodeTables::Script script, void *usrPtr)
+QFontEngine *QCoreTextFontDatabase::fontEngine(const QFontDef &f, QChar::Script script, void *usrPtr)
{
Q_UNUSED(script);
@@ -376,14 +319,142 @@ QFontEngine *QCoreTextFontDatabase::fontEngine(const QByteArray &fontData, qreal
return fontEngine;
}
-QStringList QCoreTextFontDatabase::fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const
+QFont::StyleHint styleHintFromNSString(NSString *style)
+{
+ if ([style isEqual: @"sans-serif"])
+ return QFont::SansSerif;
+ else if ([style isEqual: @"monospace"])
+ return QFont::Monospace;
+ else if ([style isEqual: @"cursive"])
+ return QFont::Cursive;
+ else if ([style isEqual: @"serif"])
+ return QFont::Serif;
+ else if ([style isEqual: @"fantasy"])
+ return QFont::Fantasy;
+ else // if ([style isEqual: @"default"])
+ return QFont::AnyStyle;
+}
+
+static QString familyNameFromPostScriptName(QHash<QString, QString> &psNameToFamily,
+ NSString *psName)
+{
+ QString name = QCFString::toQString(psName);
+ if (psNameToFamily.contains(name))
+ return psNameToFamily[name];
+ else {
+ // Some of the font name in DefaultFontFallbacks.plist are hidden fonts like AquaHiraKaku,
+ // their family name begins with a dot, like ".AquaHiraKaku" or ".Apple Symbols Fallback",
+ // the only way (I've found) to get it are actually creating a CTFont with them. We only
+ // need to do it once though.
+ QCFType<CTFontRef> font = CTFontCreateWithName((CFStringRef) psName, 12.0, NULL);
+ if (font) {
+ QCFString family = CTFontCopyFamilyName(font);
+ psNameToFamily[name] = family;
+ return family;
+ }
+ return name;
+ }
+}
+
+QStringList QCoreTextFontDatabase::fallbacksForFamily(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script) const
{
- Q_UNUSED(family);
Q_UNUSED(style);
Q_UNUSED(script);
- if (fallbackLists.isEmpty())
+
+ static QHash<QString, QStringList> fallbackLists;
+
+#if QT_MAC_PLATFORM_SDK_EQUAL_OR_ABOVE(__MAC_10_8, __IPHONE_6_0)
+ // CTFontCopyDefaultCascadeListForLanguages is available in the SDK
+ #if QT_MAC_DEPLOYMENT_TARGET_BELOW(__MAC_10_8, __IPHONE_6_0)
+ // But we have to feature check at runtime
+ if (&CTFontCopyDefaultCascadeListForLanguages)
+ #endif
+ {
+ if (fallbackLists.contains(family))
+ return fallbackLists.value(family);
+
+ if (!familyNameToPsName.contains(family))
+ const_cast<QCoreTextFontDatabase*>(this)->populateFontDatabase();
+
+ QCFType<CTFontRef> font = CTFontCreateWithName(QCFString(familyNameToPsName[family]), 12.0, NULL);
+ if (font) {
+ NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
+ NSArray *languages = [defaults stringArrayForKey: @"AppleLanguages"];
+
+ QCFType<CFArrayRef> cascadeList = (CFArrayRef) CTFontCopyDefaultCascadeListForLanguages(font, (CFArrayRef) languages);
+ if (cascadeList) {
+ QStringList fallbackList;
+ const int numCascades = CFArrayGetCount(cascadeList);
+ for (int i = 0; i < numCascades; ++i) {
+ CTFontDescriptorRef fontFallback = (CTFontDescriptorRef) CFArrayGetValueAtIndex(cascadeList, i);
+ QCFString fallbackFamilyName = (CFStringRef) CTFontDescriptorCopyLocalizedAttribute(fontFallback, kCTFontFamilyNameAttribute, NULL);
+ fallbackList.append(QCFString::toQString(fallbackFamilyName));
+ }
+ fallbackLists[family] = fallbackList;
+ }
+ }
+
+ if (fallbackLists.contains(family))
+ return fallbackLists.value(family);
+ }
+#else
+ Q_UNUSED(family);
+#endif
+
+ // We were not able to find a fallback for the specific family,
+ // so we fall back to the stylehint.
+
+ static const QString styleLookupKey = QString::fromLatin1(".QFontStyleHint_%1");
+
+ static bool didPopulateStyleFallbacks = false;
+ if (!didPopulateStyleFallbacks) {
+#if !defined(Q_OS_IOS)
+ // Ensure we have the psNameToFamily mapping set up
const_cast<QCoreTextFontDatabase*>(this)->populateFontDatabase();
- return fallbackLists[styleHint];
+
+ NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
+ NSArray *languages = [defaults stringArrayForKey: @"AppleLanguages"];
+
+ NSDictionary *fallbackDict = [NSDictionary dictionaryWithContentsOfFile: @"/System/Library/Frameworks/ApplicationServices.framework/Frameworks/CoreText.framework/Resources/DefaultFontFallbacks.plist"];
+
+ for (NSString *style in [fallbackDict allKeys]) {
+ NSArray *list = [fallbackDict valueForKey: style];
+ QFont::StyleHint fallbackStyleHint = styleHintFromNSString(style);
+ QStringList fallbackList;
+ for (id item in list) {
+ // sort the array based on system language preferences
+ if ([item isKindOfClass: [NSArray class]]) {
+ NSArray *langs = [(NSArray *) item sortedArrayUsingFunction: languageMapSort
+ context: languages];
+ for (NSArray *map in langs)
+ fallbackList.append(familyNameFromPostScriptName(psNameToFamily, [map objectAtIndex: 1]));
+ }
+ else if ([item isKindOfClass: [NSString class]])
+ fallbackList.append(familyNameFromPostScriptName(psNameToFamily, item));
+ }
+
+ if (QCoreTextFontEngine::supportsColorGlyphs())
+ fallbackList.append(QLatin1String("Apple Color Emoji"));
+
+ fallbackLists[styleLookupKey.arg(fallbackStyleHint)] = fallbackList;
+ }
+#else
+ QStringList staticFallbackList;
+ staticFallbackList << QString::fromLatin1("Helvetica,Apple Color Emoji,Geeza Pro,Arial Hebrew,Thonburi,Kailasa"
+ "Hiragino Kaku Gothic ProN,.Heiti J,Apple SD Gothic Neo,.Heiti K,Heiti SC,Heiti TC"
+ "Bangla Sangam MN,Devanagari Sangam MN,Gujarati Sangam MN,Gurmukhi MN,Kannada Sangam MN"
+ "Malayalam Sangam MN,Oriya Sangam MN,Sinhala Sangam MN,Tamil Sangam MN,Telugu Sangam MN"
+ "Euphemia UCAS,.PhoneFallback").split(QLatin1String(","));
+
+ for (int i = QFont::Helvetica; i <= QFont::Fantasy; ++i)
+ fallbackLists[styleLookupKey.arg(i)] = staticFallbackList;
+#endif
+
+ didPopulateStyleFallbacks = true;
+ }
+
+ Q_ASSERT(!fallbackLists.isEmpty());
+ return fallbackLists[styleLookupKey.arg(styleHint)];
}
#ifndef Q_OS_IOS
diff --git a/src/platformsupport/fontdatabases/mac/qcoretextfontdatabase_p.h b/src/platformsupport/fontdatabases/mac/qcoretextfontdatabase_p.h
index dcec738598..5b9b8e2329 100644
--- a/src/platformsupport/fontdatabases/mac/qcoretextfontdatabase_p.h
+++ b/src/platformsupport/fontdatabases/mac/qcoretextfontdatabase_p.h
@@ -52,9 +52,9 @@ public:
QCoreTextFontDatabase();
~QCoreTextFontDatabase();
void populateFontDatabase();
- QFontEngine *fontEngine(const QFontDef &fontDef, QUnicodeTables::Script script, void *handle);
+ QFontEngine *fontEngine(const QFontDef &fontDef, QChar::Script script, void *handle);
QFontEngine *fontEngine(const QByteArray &fontData, qreal pixelSize, QFont::HintingPreference hintingPreference);
- QStringList fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const;
+ QStringList fallbacksForFamily(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script) const;
#ifndef Q_OS_IOS
QStringList addApplicationFont(const QByteArray &fontData, const QString &fileName);
#endif
@@ -64,7 +64,8 @@ public:
private:
mutable QString defaultFontName;
- QHash<QFont::StyleHint, QStringList> fallbackLists;
+ mutable QHash<QString, QString> psNameToFamily;
+ mutable QHash<QString, QString> familyNameToPsName;
};
QT_END_NAMESPACE
diff --git a/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm b/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm
index 5c46907bc5..3e553acd0a 100644
--- a/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm
+++ b/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm
@@ -46,8 +46,6 @@
#include <private/qimage_p.h>
-#if !defined(Q_WS_MAC) || (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
-
QT_BEGIN_NAMESPACE
static float SYNTHETIC_ITALIC_SKEW = tanf(14 * acosf(0) / 90);
@@ -158,7 +156,7 @@ void QCoreTextFontEngine::init()
synthesisFlags = 0;
CTFontSymbolicTraits traits = CTFontGetSymbolicTraits(ctfont);
-#if MAC_OS_X_VERSION_MAX_ALLOWED >= 1070
+#if defined(Q_OS_IOS) || MAC_OS_X_VERSION_MAX_ALLOWED >= 1070
if (supportsColorGlyphs() && (traits & kCTFontColorGlyphsTrait))
glyphFormat = QFontEngineGlyphCache::Raster_ARGB;
else
@@ -457,7 +455,9 @@ QImage QCoreTextFontEngine::imageForGlyph(glyph_t glyph, QFixed subPixelPosition
br.y = QFixed::fromReal(br.y.toReal() * vscale);
}
- QImage im(qAbs(qRound(br.width))+2, qAbs(qRound(br.height))+2, QImage::Format_RGB32);
+ bool isColorGlyph = glyphFormat == QFontEngineGlyphCache::Raster_ARGB;
+ QImage::Format format = isColorGlyph ? QImage::Format_ARGB32_Premultiplied : QImage::Format_RGB32;
+ QImage im(qAbs(qRound(br.width)) + 2, qAbs(qRound(br.height)) + 2, format);
im.fill(0);
#ifndef Q_OS_IOS
@@ -465,7 +465,7 @@ QImage QCoreTextFontEngine::imageForGlyph(glyph_t glyph, QFixed subPixelPosition
#else
CGColorSpaceRef colorspace = CGColorSpaceCreateDeviceRGB();
#endif
- uint cgflags = kCGImageAlphaNoneSkipFirst;
+ uint cgflags = isColorGlyph ? kCGImageAlphaPremultipliedFirst : kCGImageAlphaNoneSkipFirst;
#ifdef kCGBitmapByteOrder32Host //only needed because CGImage.h added symbols in the minor version
cgflags |= kCGBitmapByteOrder32Host;
#endif
@@ -476,38 +476,49 @@ QImage QCoreTextFontEngine::imageForGlyph(glyph_t glyph, QFixed subPixelPosition
CGContextSetShouldAntialias(ctx, (aa || fontDef.pointSize > antialiasingThreshold)
&& !(fontDef.styleStrategy & QFont::NoAntialias));
CGContextSetShouldSmoothFonts(ctx, aa);
- CGAffineTransform oldTextMatrix = CGContextGetTextMatrix(ctx);
- CGAffineTransform cgMatrix = CGAffineTransformIdentity;
- CGAffineTransformConcat(cgMatrix, oldTextMatrix);
+ CGAffineTransform cgMatrix = CGAffineTransformIdentity;
if (synthesisFlags & QFontEngine::SynthesizedItalic)
cgMatrix = CGAffineTransformConcat(cgMatrix, CGAffineTransformMake(1, 0, SYNTHETIC_ITALIC_SKEW, 1, 0, 0));
- cgMatrix = CGAffineTransformConcat(cgMatrix, transform);
+ if (!isColorGlyph) // CTFontDrawGlyphs incorporates the font's matrix already
+ cgMatrix = CGAffineTransformConcat(cgMatrix, transform);
+
if (m.isScaling())
cgMatrix = CGAffineTransformConcat(cgMatrix, CGAffineTransformMakeScale(m.m11(), m.m22()));
- CGContextSetTextMatrix(ctx, cgMatrix);
- CGContextSetRGBFillColor(ctx, 1, 1, 1, 1);
- CGContextSetTextDrawingMode(ctx, kCGTextFill);
-
- CGContextSetFont(ctx, cgFont);
-
+ CGGlyph cgGlyph = glyph;
qreal pos_x = -br.x.truncate() + subPixelPosition.toReal();
qreal pos_y = im.height() + br.y.toReal();
- CGContextSetTextPosition(ctx, pos_x, pos_y);
- CGSize advance;
- advance.width = 0;
- advance.height = 0;
- CGGlyph cgGlyph = glyph;
- CGContextShowGlyphsWithAdvances(ctx, &cgGlyph, &advance, 1);
+ if (!isColorGlyph) {
+ CGContextSetTextMatrix(ctx, cgMatrix);
+ CGContextSetRGBFillColor(ctx, 1, 1, 1, 1);
+ CGContextSetTextDrawingMode(ctx, kCGTextFill);
+ CGContextSetFont(ctx, cgFont);
+ CGContextSetTextPosition(ctx, pos_x, pos_y);
- if (synthesisFlags & QFontEngine::SynthesizedBold) {
- CGContextSetTextPosition(ctx, pos_x + 0.5 * lineThickness().toReal(), pos_y);
- CGContextShowGlyphsWithAdvances(ctx, &cgGlyph, &advance, 1);
+ CGContextShowGlyphsWithAdvances(ctx, &cgGlyph, &CGSizeZero, 1);
+
+ if (synthesisFlags & QFontEngine::SynthesizedBold) {
+ CGContextSetTextPosition(ctx, pos_x + 0.5 * lineThickness().toReal(), pos_y);
+ CGContextShowGlyphsWithAdvances(ctx, &cgGlyph, &CGSizeZero, 1);
+ }
}
+#if defined(Q_OS_IOS) || MAC_OS_X_VERSION_MAX_ALLOWED >= 1070
+ else if (supportsColorGlyphs()) {
+ // CGContextSetTextMatrix does not work with color glyphs, so we use
+ // the CTM instead. This means we must translate the CTM as well, to
+ // set the glyph position, instead of using CGContextSetTextPosition.
+ CGContextTranslateCTM(ctx, pos_x, pos_y);
+ CGContextConcatCTM(ctx, cgMatrix);
+
+ // CGContextShowGlyphsWithAdvances does not support the 'sbix' color-bitmap
+ // glyphs in the Apple Color Emoji font, so we use CTFontDrawGlyphs instead.
+ CTFontDrawGlyphs(ctfont, &cgGlyph, &CGPointZero, 1, ctx);
+ }
+#endif
CGContextRelease(ctx);
CGColorSpaceRelease(colorspace);
@@ -517,7 +528,15 @@ QImage QCoreTextFontEngine::imageForGlyph(glyph_t glyph, QFixed subPixelPosition
QImage QCoreTextFontEngine::alphaMapForGlyph(glyph_t glyph, QFixed subPixelPosition)
{
- QImage im = imageForGlyph(glyph, subPixelPosition, false, QTransform());
+ return alphaMapForGlyph(glyph, subPixelPosition, QTransform());
+}
+
+QImage QCoreTextFontEngine::alphaMapForGlyph(glyph_t glyph, QFixed subPixelPosition, const QTransform &x)
+{
+ if (x.type() > QTransform::TxScale)
+ return QFontEngine::alphaMapForGlyph(glyph, subPixelPosition, x);
+
+ QImage im = imageForGlyph(glyph, subPixelPosition, false, x);
QImage indexed(im.width(), im.height(), QImage::Format_Indexed8);
QVector<QRgb> colors(256);
@@ -548,6 +567,14 @@ QImage QCoreTextFontEngine::alphaRGBMapForGlyph(glyph_t glyph, QFixed subPixelPo
return im;
}
+QImage QCoreTextFontEngine::bitmapForGlyph(glyph_t glyph, QFixed subPixelPosition, const QTransform &t)
+{
+ if (t.type() > QTransform::TxScale)
+ return QFontEngine::bitmapForGlyph(glyph, subPixelPosition, t);
+
+ return imageForGlyph(glyph, subPixelPosition, true, t);
+}
+
void QCoreTextFontEngine::recalcAdvances(QGlyphLayout *glyphs, QFontEngine::ShaperFlags flags) const
{
int i, numGlyphs = glyphs->numGlyphs;
@@ -609,12 +636,15 @@ QFontEngine *QCoreTextFontEngine::cloneWithSize(qreal pixelSize) const
return new QCoreTextFontEngine(cgFont, newFontDef);
}
-bool QCoreTextFontEngine::supportsTransformations(const QTransform &transform) const
+bool QCoreTextFontEngine::supportsTransformation(const QTransform &transform) const
{
- return transform.type() > QTransform::TxTranslate;
+ if (transform.type() < QTransform::TxScale)
+ return true;
+ else if (transform.type() == QTransform::TxScale &&
+ transform.m11() >= 0 && transform.m22() >= 0)
+ return true;
+ else
+ return false;
}
QT_END_NAMESPACE
-
-#endif// !defined(Q_WS_MAC) || (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
-
diff --git a/src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h b/src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h
index dc73d38522..a9b1960491 100644
--- a/src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h
+++ b/src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h
@@ -52,10 +52,6 @@
#include <CoreGraphics/CoreGraphics.h>
#endif
-#if !defined(Q_WS_MAC) || (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
-
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QRawFontPrivate;
@@ -98,12 +94,14 @@ public:
virtual bool getSfntTableData(uint /*tag*/, uchar * /*buffer*/, uint * /*length*/) const;
virtual void getUnscaledGlyph(glyph_t glyph, QPainterPath *path, glyph_metrics_t *metrics);
virtual QImage alphaMapForGlyph(glyph_t, QFixed subPixelPosition);
+ virtual QImage alphaMapForGlyph(glyph_t glyph, QFixed subPixelPosition, const QTransform &t);
virtual QImage alphaRGBMapForGlyph(glyph_t, QFixed subPixelPosition, const QTransform &t);
+ virtual QImage bitmapForGlyph(glyph_t, QFixed subPixelPosition, const QTransform &t);
virtual qreal minRightBearing() const;
virtual qreal minLeftBearing() const;
virtual QFixed emSquareSize() const;
- bool supportsTransformations(const QTransform &transform) const;
+ bool supportsTransformation(const QTransform &transform) const;
virtual QFontEngine *cloneWithSize(qreal pixelSize) const;
virtual int glyphMargin(QFontEngineGlyphCache::Type type) { Q_UNUSED(type); return 0; }
@@ -142,8 +140,4 @@ CGAffineTransform qt_transform_from_fontdef(const QFontDef &fontDef);
QT_END_NAMESPACE
-QT_END_HEADER
-
-#endif// !defined(Q_WS_MAC) || (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
-
#endif // QFONTENGINE_CORETEXT_P_H
diff --git a/src/platformsupport/glxconvenience/qglxconvenience.cpp b/src/platformsupport/glxconvenience/qglxconvenience.cpp
index e885ecc105..11d9377db7 100644
--- a/src/platformsupport/glxconvenience/qglxconvenience.cpp
+++ b/src/platformsupport/glxconvenience/qglxconvenience.cpp
@@ -171,7 +171,7 @@ XVisualInfo *qglx_findVisualInfo(Display *display, int screen, QSurfaceFormat *f
GLXFBConfig config = qglx_findConfig(display,screen,*format);
if (config) {
visualInfo = glXGetVisualFromFBConfig(display, config);
- *format = qglx_surfaceFormatFromGLXFBConfig(display, config);
+ qglx_surfaceFormatFromGLXFBConfig(format, display, config);
}
// attempt to fall back to glXChooseVisual
@@ -221,9 +221,8 @@ XVisualInfo *qglx_findVisualInfo(Display *display, int screen, QSurfaceFormat *f
return visualInfo;
}
-QSurfaceFormat qglx_surfaceFormatFromGLXFBConfig(Display *display, GLXFBConfig config, GLXContext)
+void qglx_surfaceFormatFromGLXFBConfig(QSurfaceFormat *format, Display *display, GLXFBConfig config, GLXContext)
{
- QSurfaceFormat format;
int redSize = 0;
int greenSize = 0;
int blueSize = 0;
@@ -245,20 +244,18 @@ QSurfaceFormat qglx_surfaceFormatFromGLXFBConfig(Display *display, GLXFBConfig c
glXGetFBConfigAttrib(display, config, GLX_SAMPLES_ARB, &sampleBuffers);
glXGetFBConfigAttrib(display, config, GLX_STEREO, &stereo);
- format.setRedBufferSize(redSize);
- format.setGreenBufferSize(greenSize);
- format.setBlueBufferSize(blueSize);
- format.setAlphaBufferSize(alphaSize);
- format.setDepthBufferSize(depthSize);
- format.setStencilBufferSize(stencilSize);
+ format->setRedBufferSize(redSize);
+ format->setGreenBufferSize(greenSize);
+ format->setBlueBufferSize(blueSize);
+ format->setAlphaBufferSize(alphaSize);
+ format->setDepthBufferSize(depthSize);
+ format->setStencilBufferSize(stencilSize);
if (sampleBuffers) {
glXGetFBConfigAttrib(display, config, GLX_SAMPLES_ARB, &sampleCount);
- format.setSamples(sampleCount);
+ format->setSamples(sampleCount);
}
- format.setStereo(stereo);
-
- return format;
+ format->setStereo(stereo);
}
QSurfaceFormat qglx_reduceSurfaceFormat(const QSurfaceFormat &format, bool *reduced)
diff --git a/src/platformsupport/glxconvenience/qglxconvenience_p.h b/src/platformsupport/glxconvenience/qglxconvenience_p.h
index 70f97d8b38..66548a3479 100644
--- a/src/platformsupport/glxconvenience/qglxconvenience_p.h
+++ b/src/platformsupport/glxconvenience/qglxconvenience_p.h
@@ -50,7 +50,7 @@
XVisualInfo *qglx_findVisualInfo(Display *display, int screen, QSurfaceFormat *format);
GLXFBConfig qglx_findConfig(Display *display, int screen, const QSurfaceFormat &format, int drawableBit = GLX_WINDOW_BIT);
-QSurfaceFormat qglx_surfaceFormatFromGLXFBConfig(Display *display, GLXFBConfig config, GLXContext context = 0);
+void qglx_surfaceFormatFromGLXFBConfig(QSurfaceFormat *format, Display *display, GLXFBConfig config, GLXContext context = 0);
QVector<int> qglx_buildSpec(const QSurfaceFormat &format, int drawableBit = GLX_WINDOW_BIT);
QSurfaceFormat qglx_reduceSurfaceFormat(const QSurfaceFormat &format, bool *reduced);
diff --git a/src/platformsupport/input/evdevkeyboard/qevdevkeyboardhandler_p.h b/src/platformsupport/input/evdevkeyboard/qevdevkeyboardhandler_p.h
index 3e5dcb2ac9..1065b05d51 100644
--- a/src/platformsupport/input/evdevkeyboard/qevdevkeyboardhandler_p.h
+++ b/src/platformsupport/input/evdevkeyboard/qevdevkeyboardhandler_p.h
@@ -46,8 +46,6 @@
#include <QTimer>
#include <QDataStream>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
namespace QEvdevKeyboardMap {
@@ -198,6 +196,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QEVDEVKEYBOARDHANDLER_P_H
diff --git a/src/platformsupport/input/evdevkeyboard/qevdevkeyboardmanager.cpp b/src/platformsupport/input/evdevkeyboard/qevdevkeyboardmanager.cpp
index 81acc161fe..4932087c5f 100644
--- a/src/platformsupport/input/evdevkeyboard/qevdevkeyboardmanager.cpp
+++ b/src/platformsupport/input/evdevkeyboard/qevdevkeyboardmanager.cpp
@@ -57,7 +57,13 @@ QEvdevKeyboardManager::QEvdevKeyboardManager(const QString &key, const QString &
{
Q_UNUSED(key);
- QStringList args = specification.split(QLatin1Char(':'));
+
+ QString spec = QString::fromLocal8Bit(qgetenv("QT_QPA_EVDEV_KEYBOARD_PARAMETERS"));
+
+ if (spec.isEmpty())
+ spec = specification;
+
+ QStringList args = spec.split(QLatin1Char(':'));
QStringList devices;
foreach (const QString &arg, args) {
diff --git a/src/platformsupport/input/evdevkeyboard/qevdevkeyboardmanager_p.h b/src/platformsupport/input/evdevkeyboard/qevdevkeyboardmanager_p.h
index e750f72c3b..37c60c035c 100644
--- a/src/platformsupport/input/evdevkeyboard/qevdevkeyboardmanager_p.h
+++ b/src/platformsupport/input/evdevkeyboard/qevdevkeyboardmanager_p.h
@@ -50,8 +50,6 @@
#include <QHash>
#include <QSocketNotifier>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QEvdevKeyboardManager : public QObject
@@ -71,8 +69,6 @@ private:
QDeviceDiscovery *m_deviceDiscovery;
};
-QT_END_HEADER
-
QT_END_NAMESPACE
#endif // QEVDEVKEYBOARDMANAGER_P_H
diff --git a/src/platformsupport/input/evdevmouse/qevdevmousehandler_p.h b/src/platformsupport/input/evdevmouse/qevdevmousehandler_p.h
index 6e078b2d70..d419a1913e 100644
--- a/src/platformsupport/input/evdevmouse/qevdevmousehandler_p.h
+++ b/src/platformsupport/input/evdevmouse/qevdevmousehandler_p.h
@@ -45,8 +45,6 @@
#include <QObject>
#include <QString>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QSocketNotifier;
@@ -83,6 +81,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QEVDEVMOUSEHANDLER_P_H
diff --git a/src/platformsupport/input/evdevmouse/qevdevmousemanager.cpp b/src/platformsupport/input/evdevmouse/qevdevmousemanager.cpp
index 415cffa4ae..6c430091c1 100644
--- a/src/platformsupport/input/evdevmouse/qevdevmousemanager.cpp
+++ b/src/platformsupport/input/evdevmouse/qevdevmousemanager.cpp
@@ -59,7 +59,12 @@ QEvdevMouseManager::QEvdevMouseManager(const QString &key, const QString &specif
{
Q_UNUSED(key);
- QStringList args = specification.split(QLatin1Char(':'));
+ QString spec = QString::fromLocal8Bit(qgetenv("QT_QPA_EVDEV_MOUSE_PARAMETERS"));
+
+ if (spec.isEmpty())
+ spec = specification;
+
+ QStringList args = spec.split(QLatin1Char(':'));
QStringList devices;
foreach (const QString &arg, args) {
diff --git a/src/platformsupport/input/evdevmouse/qevdevmousemanager_p.h b/src/platformsupport/input/evdevmouse/qevdevmousemanager_p.h
index a2c83c4a1c..6abe933371 100644
--- a/src/platformsupport/input/evdevmouse/qevdevmousemanager_p.h
+++ b/src/platformsupport/input/evdevmouse/qevdevmousemanager_p.h
@@ -50,8 +50,6 @@
#include <QHash>
#include <QSocketNotifier>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QEvdevMouseManager : public QObject
@@ -79,8 +77,6 @@ private:
int m_yoffset;
};
-QT_END_HEADER
-
QT_END_NAMESPACE
#endif // QEVDEVMOUSEMANAGER_P_H
diff --git a/src/platformsupport/input/evdevtablet/qevdevtablet_p.h b/src/platformsupport/input/evdevtablet/qevdevtablet_p.h
index ce49a01e7b..9222db9907 100644
--- a/src/platformsupport/input/evdevtablet/qevdevtablet_p.h
+++ b/src/platformsupport/input/evdevtablet/qevdevtablet_p.h
@@ -46,8 +46,6 @@
#include <QString>
#include <QThread>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QEvdevTabletData;
@@ -82,6 +80,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QEVDEVTABLET_P_H
diff --git a/src/platformsupport/input/evdevtouch/qevdevtouch.cpp b/src/platformsupport/input/evdevtouch/qevdevtouch.cpp
index 8c86eee469..2c93da147e 100644
--- a/src/platformsupport/input/evdevtouch/qevdevtouch.cpp
+++ b/src/platformsupport/input/evdevtouch/qevdevtouch.cpp
@@ -159,7 +159,7 @@ static inline bool testBit(long bit, const long *array)
return (array[bit / LONG_BITS] >> bit % LONG_BITS) & 1;
}
-QEvdevTouchScreenHandler::QEvdevTouchScreenHandler(const QString &spec, QObject *parent)
+QEvdevTouchScreenHandler::QEvdevTouchScreenHandler(const QString &specification, QObject *parent)
: QObject(parent), m_notify(0), m_fd(-1), d(0)
#ifdef USE_MTDEV
, m_mtdev(0)
@@ -170,7 +170,13 @@ QEvdevTouchScreenHandler::QEvdevTouchScreenHandler(const QString &spec, QObject
QString dev;
// only the first device argument is used for now
+ QString spec = QString::fromLocal8Bit(qgetenv("QT_QPA_EVDEV_TOUCHSCREEN_PARAMETERS"));
+
+ if (spec.isEmpty())
+ spec = specification;
+
QStringList args = spec.split(QLatin1Char(':'));
+
for (int i = 0; i < args.count(); ++i) {
if (args.at(i).startsWith(QLatin1String("/dev/"))) {
dev = args.at(i);
diff --git a/src/platformsupport/input/evdevtouch/qevdevtouch_p.h b/src/platformsupport/input/evdevtouch/qevdevtouch_p.h
index b4de2ca088..be7dbfba14 100644
--- a/src/platformsupport/input/evdevtouch/qevdevtouch_p.h
+++ b/src/platformsupport/input/evdevtouch/qevdevtouch_p.h
@@ -48,8 +48,6 @@
#include <QThread>
#include <qpa/qwindowsysteminterface.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QSocketNotifier;
@@ -63,7 +61,7 @@ class QEvdevTouchScreenHandler : public QObject
Q_OBJECT
public:
- explicit QEvdevTouchScreenHandler(const QString &spec = QString(), QObject *parent = 0);
+ explicit QEvdevTouchScreenHandler(const QString &specification = QString(), QObject *parent = 0);
~QEvdevTouchScreenHandler();
private slots:
@@ -93,6 +91,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QEVDEVTOUCH_P_H
diff --git a/src/platformsupport/jniconvenience/jniconvenience.pri b/src/platformsupport/jniconvenience/jniconvenience.pri
new file mode 100644
index 0000000000..ca7c5b1e96
--- /dev/null
+++ b/src/platformsupport/jniconvenience/jniconvenience.pri
@@ -0,0 +1,9 @@
+android:!android-no-sdk {
+ QT += gui-private
+
+ HEADERS += $$PWD/qjnihelpers_p.h \
+ $$PWD/qjniobject_p.h
+
+ SOURCES += $$PWD/qjnihelpers.cpp \
+ $$PWD/qjniobject.cpp
+}
diff --git a/src/platformsupport/jniconvenience/qjnihelpers.cpp b/src/platformsupport/jniconvenience/qjnihelpers.cpp
new file mode 100644
index 0000000000..3f9b568368
--- /dev/null
+++ b/src/platformsupport/jniconvenience/qjnihelpers.cpp
@@ -0,0 +1,115 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qjnihelpers_p.h"
+
+#include <qpa/qplatformnativeinterface.h>
+#include <qguiapplication.h>
+
+QT_BEGIN_NAMESPACE
+
+QString qt_convertJString(jstring string)
+{
+ QAttachedJNIEnv env;
+ int strLength = env->GetStringLength(string);
+ QString res;
+ res.resize(strLength);
+ env->GetStringRegion(string, 0, strLength, (jchar*)res.utf16());
+ return res;
+}
+
+QJNILocalRef<jstring> qt_toJString(const QString &string)
+{
+ QAttachedJNIEnv env;
+ return QJNILocalRef<jstring>(env->NewString(reinterpret_cast<const jchar*>(string.constData()),
+ string.length()));
+}
+
+
+static JavaVM *g_javaVM = 0;
+
+static JavaVM *getJavaVM()
+{
+ if (!g_javaVM){
+ QPlatformNativeInterface *nativeInterface = QGuiApplication::platformNativeInterface();
+ g_javaVM = static_cast<JavaVM*>(nativeInterface->nativeResourceForIntegration("JavaVM"));
+ }
+ return g_javaVM;
+}
+
+QThreadStorage<int> QAttachedJNIEnv::m_refCount;
+
+QAttachedJNIEnv::QAttachedJNIEnv()
+{
+ JavaVM *vm = javaVM();
+ if (vm->GetEnv((void**)&jniEnv, JNI_VERSION_1_6) == JNI_EDETACHED) {
+ if (vm->AttachCurrentThread(&jniEnv, 0) < 0) {
+ jniEnv = 0;
+ return;
+ }
+ }
+
+ if (!m_refCount.hasLocalData())
+ m_refCount.setLocalData(1);
+ else
+ m_refCount.setLocalData(m_refCount.localData() + 1);
+}
+
+QAttachedJNIEnv::~QAttachedJNIEnv()
+{
+ if (!jniEnv)
+ return;
+
+ int newRef = m_refCount.localData() - 1;
+ m_refCount.setLocalData(newRef);
+
+ if (newRef == 0)
+ javaVM()->DetachCurrentThread();
+
+ jniEnv = 0;
+}
+
+JavaVM *QAttachedJNIEnv::javaVM()
+{
+ return getJavaVM();
+}
+
+QT_END_NAMESPACE
diff --git a/src/platformsupport/jniconvenience/qjnihelpers_p.h b/src/platformsupport/jniconvenience/qjnihelpers_p.h
new file mode 100644
index 0000000000..fb44d156bd
--- /dev/null
+++ b/src/platformsupport/jniconvenience/qjnihelpers_p.h
@@ -0,0 +1,191 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QJNIHELPERS_H
+#define QJNIHELPERS_H
+
+#include <jni.h>
+#include <qglobal.h>
+#include <QString>
+#include <QThreadStorage>
+
+QT_BEGIN_NAMESPACE
+
+template <typename T>
+class QJNILocalRef;
+
+QString qt_convertJString(jstring string);
+QJNILocalRef<jstring> qt_toJString(const QString &string);
+
+
+struct QAttachedJNIEnv
+{
+ QAttachedJNIEnv();
+ ~QAttachedJNIEnv();
+
+ static JavaVM *javaVM();
+
+ JNIEnv *operator->()
+ {
+ return jniEnv;
+ }
+
+ operator JNIEnv*() const
+ {
+ return jniEnv;
+ }
+
+ JNIEnv *jniEnv;
+
+private:
+ static QThreadStorage<int> m_refCount;
+};
+
+
+template <typename T>
+class QJNILocalRef
+{
+public:
+ inline QJNILocalRef() : m_obj(0) { }
+ inline explicit QJNILocalRef(T o) : m_obj(o) { }
+ inline QJNILocalRef(const QJNILocalRef<T> &other) : m_obj(other.m_obj)
+ {
+ if (other.m_obj)
+ m_obj = static_cast<T>(m_env->NewLocalRef(other.m_obj));
+ }
+
+ template <typename X>
+ inline QJNILocalRef(const QJNILocalRef<X> &other) : m_obj(other.m_obj)
+ {
+ if (other.m_obj)
+ m_obj = static_cast<T>(m_env->NewLocalRef(other.m_obj));
+ }
+
+ inline ~QJNILocalRef() { release(); }
+
+ inline QJNILocalRef<T> &operator=(const QJNILocalRef<T> &other)
+ {
+ release();
+ m_obj = other.m_obj; // for type checking
+ if (other.m_obj)
+ m_obj = static_cast<T>(m_env->NewLocalRef(other.m_obj));
+ return *this;
+ }
+
+ template <typename X>
+ inline QJNILocalRef<T> &operator=(const QJNILocalRef<X> &other)
+ {
+ release();
+ m_obj = other.m_obj; // for type checking
+ if (other.m_obj)
+ m_obj = static_cast<T>(m_env->NewLocalRef(other.m_obj));
+ return *this;
+ }
+
+ inline QJNILocalRef<T> &operator=(T o)
+ {
+ release();
+ m_obj = o;
+ return *this;
+ }
+
+ template <typename X>
+ inline QJNILocalRef<T> &operator=(X o)
+ {
+ release();
+ m_obj = o;
+ return *this;
+ }
+
+ inline bool operator !() const { return !m_obj; }
+ inline bool isNull() const { return !m_obj; }
+ inline T object() const { return m_obj; }
+
+private:
+ void release()
+ {
+ if (m_obj) {
+ m_env->DeleteLocalRef(m_obj);
+ m_obj = 0;
+ }
+ }
+
+ QAttachedJNIEnv m_env;
+ T m_obj;
+
+ template <class X> friend class QJNILocalRef;
+};
+
+template <class T, class X>
+bool operator==(const QJNILocalRef<T> &ptr1, const QJNILocalRef<X> &ptr2)
+{
+ return ptr1.m_obj == ptr2.m_obj;
+}
+template <class T, class X>
+bool operator!=(const QJNILocalRef<T> &ptr1, const QJNILocalRef<X> &ptr2)
+{
+ return ptr1.m_obj != ptr2.m_obj;
+}
+
+template <class T, class X>
+bool operator==(const QJNILocalRef<T> &ptr1, X ptr2)
+{
+ return ptr1.m_obj == ptr2;
+}
+template <class T, class X>
+bool operator==(T ptr1, const QJNILocalRef<X> &ptr2)
+{
+ return ptr1 == ptr2.m_obj;
+}
+template <class T, class X>
+bool operator!=(const QJNILocalRef<T> &ptr1, X ptr2)
+{
+ return !(ptr1 == ptr2);
+}
+template <class T, class X>
+bool operator!=(const T *ptr1, const QJNILocalRef<X> &ptr2)
+{
+ return !(ptr2 == ptr1);
+}
+
+QT_END_NAMESPACE
+
+#endif // QJNIHELPERS_H
diff --git a/src/platformsupport/jniconvenience/qjniobject.cpp b/src/platformsupport/jniconvenience/qjniobject.cpp
new file mode 100644
index 0000000000..515e82b2f0
--- /dev/null
+++ b/src/platformsupport/jniconvenience/qjniobject.cpp
@@ -0,0 +1,3098 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qjniobject_p.h"
+
+#include "qjnihelpers_p.h"
+#include <qhash.h>
+
+QT_BEGIN_NAMESPACE
+
+static QHash<QString, jclass> g_cachedClasses;
+
+static jclass getCachedClass(JNIEnv *env, const char *className)
+{
+ jclass clazz = 0;
+ QString key = QLatin1String(className);
+ QHash<QString, jclass>::iterator it = g_cachedClasses.find(key);
+ if (it == g_cachedClasses.end()) {
+ jclass c = env->FindClass(className);
+ if (env->ExceptionCheck()) {
+ c = 0;
+ env->ExceptionClear();
+ }
+ if (c)
+ clazz = static_cast<jclass>(env->NewGlobalRef(c));
+ g_cachedClasses.insert(key, clazz);
+ } else {
+ clazz = it.value();
+ }
+ return clazz;
+}
+
+static QHash<QString, jmethodID> g_cachedMethodIDs;
+static QString g_keyBase(QLatin1String("%1%2%3"));
+
+static jmethodID getCachedMethodID(JNIEnv *env,
+ jclass clazz,
+ const char *name,
+ const char *sig,
+ bool isStatic = false)
+{
+ jmethodID id = 0;
+ QString key = g_keyBase.arg(size_t(clazz)).arg(QLatin1String(name)).arg(QLatin1String(sig));
+ QHash<QString, jmethodID>::iterator it = g_cachedMethodIDs.find(key);
+ if (it == g_cachedMethodIDs.end()) {
+ if (isStatic)
+ id = env->GetStaticMethodID(clazz, name, sig);
+ else
+ id = env->GetMethodID(clazz, name, sig);
+
+ if (env->ExceptionCheck()) {
+ id = 0;
+ env->ExceptionClear();
+ }
+
+ g_cachedMethodIDs.insert(key, id);
+ } else {
+ id = it.value();
+ }
+ return id;
+}
+
+static QHash<QString, jfieldID> g_cachedFieldIDs;
+
+static jfieldID getCachedFieldID(JNIEnv *env,
+ jclass clazz,
+ const char *name,
+ const char *sig,
+ bool isStatic = false)
+{
+ jfieldID id = 0;
+ QString key = g_keyBase.arg(size_t(clazz)).arg(QLatin1String(name)).arg(QLatin1String(sig));
+ QHash<QString, jfieldID>::iterator it = g_cachedFieldIDs.find(key);
+ if (it == g_cachedFieldIDs.end()) {
+ if (isStatic)
+ id = env->GetStaticFieldID(clazz, name, sig);
+ else
+ id = env->GetFieldID(clazz, name, sig);
+
+ if (env->ExceptionCheck()) {
+ id = 0;
+ env->ExceptionClear();
+ }
+
+ g_cachedFieldIDs.insert(key, id);
+ } else {
+ id = it.value();
+ }
+ return id;
+}
+
+QJNIObject::QJNIObject(const char *className)
+ : m_jobject(0)
+ , m_jclass(0)
+ , m_own_jclass(false)
+{
+ QAttachedJNIEnv env;
+ m_jclass = getCachedClass(env, className);
+ if (m_jclass) {
+ // get default constructor
+ jmethodID constructorId = getCachedMethodID(env, m_jclass, "<init>", "()V");
+ if (constructorId) {
+ jobject obj = env->NewObject(m_jclass, constructorId);
+ if (obj) {
+ m_jobject = env->NewGlobalRef(obj);
+ env->DeleteLocalRef(obj);
+ }
+ }
+ }
+}
+
+QJNIObject::QJNIObject(const char *className, const char *sig, ...)
+ : m_jobject(0)
+ , m_jclass(0)
+ , m_own_jclass(false)
+{
+ QAttachedJNIEnv env;
+ m_jclass = getCachedClass(env, className);
+ if (m_jclass) {
+ jmethodID constructorId = getCachedMethodID(env, m_jclass, "<init>", sig);
+ if (constructorId) {
+ va_list args;
+ va_start(args, sig);
+ jobject obj = env->NewObjectV(m_jclass, constructorId, args);
+ va_end(args);
+ if (obj) {
+ m_jobject = env->NewGlobalRef(obj);
+ env->DeleteLocalRef(obj);
+ }
+ }
+ }
+}
+
+QJNIObject::QJNIObject(jclass clazz)
+ : m_jobject(0)
+ , m_jclass(0)
+ , m_own_jclass(true)
+{
+ QAttachedJNIEnv env;
+ m_jclass = static_cast<jclass>(env->NewGlobalRef(clazz));
+ if (m_jclass) {
+ // get default constructor
+ jmethodID constructorId = getCachedMethodID(env, m_jclass, "<init>", "()V");
+ if (constructorId) {
+ jobject obj = env->NewObject(m_jclass, constructorId);
+ if (obj) {
+ m_jobject = env->NewGlobalRef(obj);
+ env->DeleteLocalRef(obj);
+ }
+ }
+ }
+}
+
+QJNIObject::QJNIObject(jclass clazz, const char *sig, ...)
+ : m_jobject(0)
+ , m_jclass(0)
+ , m_own_jclass(true)
+{
+ QAttachedJNIEnv env;
+ if (clazz) {
+ m_jclass = static_cast<jclass>(env->NewGlobalRef(clazz));
+ if (m_jclass) {
+ jmethodID constructorId = getCachedMethodID(env, m_jclass, "<init>", sig);
+ if (constructorId) {
+ va_list args;
+ va_start(args, sig);
+ jobject obj = env->NewObjectV(m_jclass, constructorId, args);
+ va_end(args);
+ if (obj) {
+ m_jobject = env->NewGlobalRef(obj);
+ env->DeleteLocalRef(obj);
+ }
+ }
+ }
+ }
+}
+
+QJNIObject::QJNIObject(jobject obj)
+ : m_jobject(0)
+ , m_jclass(0)
+ , m_own_jclass(true)
+{
+ QAttachedJNIEnv env;
+ m_jobject = env->NewGlobalRef(obj);
+ m_jclass = static_cast<jclass>(env->NewGlobalRef(env->GetObjectClass(m_jobject)));
+}
+
+QJNIObject::~QJNIObject()
+{
+ QAttachedJNIEnv env;
+ if (m_jobject)
+ env->DeleteGlobalRef(m_jobject);
+ if (m_jclass && m_own_jclass)
+ env->DeleteGlobalRef(m_jclass);
+}
+
+bool QJNIObject::isClassAvailable(const char *className)
+{
+ QAttachedJNIEnv env;
+
+ if (!env.jniEnv)
+ return false;
+
+ jclass clazz = getCachedClass(env, className);
+
+ return (clazz != 0);
+}
+
+template <>
+void QJNIObject::callMethod<void>(const char *methodName, const char *sig, ...)
+{
+ QAttachedJNIEnv env;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ env->CallVoidMethodV(m_jobject, id, args);
+ va_end(args);
+ }
+}
+
+template <>
+jboolean QJNIObject::callMethod<jboolean>(const char *methodName, const char *sig, ...)
+{
+ QAttachedJNIEnv env;
+ jboolean res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallBooleanMethodV(m_jobject, id, args);
+ va_end(args);
+ }
+ return res;
+}
+
+template <>
+jbyte QJNIObject::callMethod<jbyte>(const char *methodName, const char *sig, ...)
+{
+ QAttachedJNIEnv env;
+ jbyte res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallByteMethodV(m_jobject, id, args);
+ va_end(args);
+ }
+ return res;
+}
+
+template <>
+jchar QJNIObject::callMethod<jchar>(const char *methodName, const char *sig, ...)
+{
+ QAttachedJNIEnv env;
+ jchar res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallCharMethodV(m_jobject, id, args);
+ va_end(args);
+ }
+ return res;
+}
+
+template <>
+jshort QJNIObject::callMethod<jshort>(const char *methodName, const char *sig, ...)
+{
+ QAttachedJNIEnv env;
+ jshort res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallShortMethodV(m_jobject, id, args);
+ va_end(args);
+ }
+ return res;
+}
+
+template <>
+jint QJNIObject::callMethod<jint>(const char *methodName, const char *sig, ...)
+{
+ QAttachedJNIEnv env;
+ jint res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallIntMethodV(m_jobject, id, args);
+ va_end(args);
+ }
+ return res;
+}
+
+template <>
+jlong QJNIObject::callMethod<jlong>(const char *methodName, const char *sig, ...)
+{
+ QAttachedJNIEnv env;
+ jlong res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallLongMethodV(m_jobject, id, args);
+ va_end(args);
+ }
+ return res;
+}
+
+template <>
+jfloat QJNIObject::callMethod<jfloat>(const char *methodName, const char *sig, ...)
+{
+ QAttachedJNIEnv env;
+ jfloat res = 0.f;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallFloatMethodV(m_jobject, id, args);
+ va_end(args);
+ }
+ return res;
+}
+
+template <>
+jdouble QJNIObject::callMethod<jdouble>(const char *methodName, const char *sig, ...)
+{
+ QAttachedJNIEnv env;
+ jdouble res = 0.;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallDoubleMethodV(m_jobject, id, args);
+ va_end(args);
+ }
+ return res;
+}
+
+template <>
+QJNILocalRef<jobject> QJNIObject::callObjectMethod<jobject>(const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jobject res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallObjectMethodV(m_jobject, id, args);
+ va_end(args);
+ }
+ return QJNILocalRef<jobject>(res);
+}
+
+template <>
+QJNILocalRef<jstring> QJNIObject::callObjectMethod<jstring>(const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jstring res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jstring>(env->CallObjectMethodV(m_jobject, id, args));
+ va_end(args);
+ }
+ return QJNILocalRef<jstring>(res);
+}
+
+template <>
+QJNILocalRef<jobjectArray> QJNIObject::callObjectMethod<jobjectArray>(const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jobjectArray res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jobjectArray>(env->CallObjectMethodV(m_jobject, id, args));
+ va_end(args);
+ }
+ return QJNILocalRef<jobjectArray>(res);
+}
+
+template <>
+QJNILocalRef<jbooleanArray> QJNIObject::callObjectMethod<jbooleanArray>(const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jbooleanArray res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jbooleanArray>(env->CallObjectMethodV(m_jobject, id, args));
+ va_end(args);
+ }
+ return QJNILocalRef<jbooleanArray>(res);
+}
+
+template <>
+QJNILocalRef<jbyteArray> QJNIObject::callObjectMethod<jbyteArray>(const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jbyteArray res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jbyteArray>(env->CallObjectMethodV(m_jobject, id, args));
+ va_end(args);
+ }
+ return QJNILocalRef<jbyteArray>(res);
+}
+
+template <>
+QJNILocalRef<jcharArray> QJNIObject::callObjectMethod<jcharArray>(const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jcharArray res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jcharArray>(env->CallObjectMethodV(m_jobject, id, args));
+ va_end(args);
+ }
+ return QJNILocalRef<jcharArray>(res);
+}
+
+template <>
+QJNILocalRef<jshortArray> QJNIObject::callObjectMethod<jshortArray>(const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jshortArray res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jshortArray>(env->CallObjectMethodV(m_jobject, id, args));
+ va_end(args);
+ }
+ return QJNILocalRef<jshortArray>(res);
+}
+
+template <>
+QJNILocalRef<jintArray> QJNIObject::callObjectMethod<jintArray>(const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jintArray res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jintArray>(env->CallObjectMethodV(m_jobject, id, args));
+ va_end(args);
+ }
+ return QJNILocalRef<jintArray>(res);
+}
+
+template <>
+QJNILocalRef<jlongArray> QJNIObject::callObjectMethod<jlongArray>(const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jlongArray res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jlongArray>(env->CallObjectMethodV(m_jobject, id, args));
+ va_end(args);
+ }
+ return QJNILocalRef<jlongArray>(res);
+}
+
+template <>
+QJNILocalRef<jfloatArray> QJNIObject::callObjectMethod<jfloatArray>(const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jfloatArray res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jfloatArray>(env->CallObjectMethodV(m_jobject, id, args));
+ va_end(args);
+ }
+ return QJNILocalRef<jfloatArray>(res);
+}
+
+template <>
+QJNILocalRef<jdoubleArray> QJNIObject::callObjectMethod<jdoubleArray>(const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jdoubleArray res = 0;
+ jmethodID id = getCachedMethodID(env, m_jclass, methodName, sig);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jdoubleArray>(env->CallObjectMethodV(m_jobject, id, args));
+ va_end(args);
+ }
+ return QJNILocalRef<jdoubleArray>(res);
+}
+
+template <>
+void QJNIObject::callMethod<void>(const char *methodName)
+{
+ callMethod<void>(methodName, "()V");
+}
+
+template <>
+jboolean QJNIObject::callMethod<jboolean>(const char *methodName)
+{
+ return callMethod<jboolean>(methodName, "()Z");
+}
+
+template <>
+jbyte QJNIObject::callMethod<jbyte>(const char *methodName)
+{
+ return callMethod<jbyte>(methodName, "()B");
+}
+
+template <>
+jchar QJNIObject::callMethod<jchar>(const char *methodName)
+{
+ return callMethod<jchar>(methodName, "()C");
+}
+
+template <>
+jshort QJNIObject::callMethod<jshort>(const char *methodName)
+{
+ return callMethod<jshort>(methodName, "()S");
+}
+
+template <>
+jint QJNIObject::callMethod<jint>(const char *methodName)
+{
+ return callMethod<jint>(methodName, "()I");
+}
+
+template <>
+jlong QJNIObject::callMethod<jlong>(const char *methodName)
+{
+ return callMethod<jlong>(methodName, "()J");
+}
+
+template <>
+jfloat QJNIObject::callMethod<jfloat>(const char *methodName)
+{
+ return callMethod<jfloat>(methodName, "()F");
+}
+
+template <>
+jdouble QJNIObject::callMethod<jdouble>(const char *methodName)
+{
+ return callMethod<jdouble>(methodName, "()D");
+}
+
+template <>
+QJNILocalRef<jstring> QJNIObject::callObjectMethod<jstring>(const char *methodName)
+{
+ return callObjectMethod<jstring>(methodName, "()Ljava/lang/String;");
+}
+
+template <>
+QJNILocalRef<jbooleanArray> QJNIObject::callObjectMethod<jbooleanArray>(const char *methodName)
+{
+ return callObjectMethod<jbooleanArray>(methodName, "()[Z");
+}
+
+template <>
+QJNILocalRef<jbyteArray> QJNIObject::callObjectMethod<jbyteArray>(const char *methodName)
+{
+ return callObjectMethod<jbyteArray>(methodName, "()[B");
+}
+
+template <>
+QJNILocalRef<jshortArray> QJNIObject::callObjectMethod<jshortArray>(const char *methodName)
+{
+ return callObjectMethod<jshortArray>(methodName, "()[S");
+}
+
+template <>
+QJNILocalRef<jintArray> QJNIObject::callObjectMethod<jintArray>(const char *methodName)
+{
+ return callObjectMethod<jintArray>(methodName, "()[I");
+}
+
+template <>
+QJNILocalRef<jlongArray> QJNIObject::callObjectMethod<jlongArray>(const char *methodName)
+{
+ return callObjectMethod<jlongArray>(methodName, "()[J");
+}
+
+template <>
+QJNILocalRef<jfloatArray> QJNIObject::callObjectMethod<jfloatArray>(const char *methodName)
+{
+ return callObjectMethod<jfloatArray>(methodName, "()[F");
+}
+
+template <>
+QJNILocalRef<jdoubleArray> QJNIObject::callObjectMethod<jdoubleArray>(const char *methodName)
+{
+ return callObjectMethod<jdoubleArray>(methodName, "()[D");
+}
+
+template <>
+void QJNIObject::callStaticMethod<void>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ env->CallStaticVoidMethodV(clazz, id, args);
+ va_end(args);
+ }
+ }
+}
+
+template <>
+void QJNIObject::callStaticMethod<void>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ env->CallStaticVoidMethodV(clazz, id, args);
+ va_end(args);
+ }
+}
+
+template <>
+jboolean QJNIObject::callStaticMethod<jboolean>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jboolean res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticBooleanMethodV(clazz, id, args);
+ va_end(args);
+ }
+ }
+
+ return res;
+}
+
+template <>
+jboolean QJNIObject::callStaticMethod<jboolean>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jboolean res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticBooleanMethodV(clazz, id, args);
+ va_end(args);
+ }
+
+ return res;
+}
+
+template <>
+jbyte QJNIObject::callStaticMethod<jbyte>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jbyte res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticByteMethodV(clazz, id, args);
+ va_end(args);
+ }
+ }
+
+ return res;
+}
+
+template <>
+jbyte QJNIObject::callStaticMethod<jbyte>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jbyte res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticByteMethodV(clazz, id, args);
+ va_end(args);
+ }
+
+ return res;
+}
+
+template <>
+jchar QJNIObject::callStaticMethod<jchar>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jchar res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticCharMethodV(clazz, id, args);
+ va_end(args);
+ }
+ }
+
+ return res;
+}
+
+template <>
+jchar QJNIObject::callStaticMethod<jchar>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jchar res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticCharMethodV(clazz, id, args);
+ va_end(args);
+ }
+
+ return res;
+}
+
+
+template <>
+jshort QJNIObject::callStaticMethod<jshort>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jshort res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticShortMethodV(clazz, id, args);
+ va_end(args);
+ }
+ }
+
+ return res;
+}
+
+template <>
+jshort QJNIObject::callStaticMethod<jshort>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jshort res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticShortMethodV(clazz, id, args);
+ va_end(args);
+ }
+
+ return res;
+}
+
+template <>
+jint QJNIObject::callStaticMethod<jint>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jint res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticIntMethodV(clazz, id, args);
+ va_end(args);
+ }
+ }
+
+ return res;
+}
+
+template <>
+jint QJNIObject::callStaticMethod<jint>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jint res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticIntMethodV(clazz, id, args);
+ va_end(args);
+ }
+
+ return res;
+}
+
+template <>
+jlong QJNIObject::callStaticMethod<jlong>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jlong res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticLongMethodV(clazz, id, args);
+ va_end(args);
+ }
+ }
+
+ return res;
+}
+
+template <>
+jlong QJNIObject::callStaticMethod<jlong>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jlong res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticLongMethodV(clazz, id, args);
+ va_end(args);
+ }
+
+ return res;
+}
+
+template <>
+jfloat QJNIObject::callStaticMethod<jfloat>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jfloat res = 0.f;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticFloatMethodV(clazz, id, args);
+ va_end(args);
+ }
+ }
+
+ return res;
+}
+
+template <>
+jfloat QJNIObject::callStaticMethod<jfloat>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jfloat res = 0.f;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticFloatMethodV(clazz, id, args);
+ va_end(args);
+ }
+
+ return res;
+}
+
+template <>
+jdouble QJNIObject::callStaticMethod<jdouble>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jdouble res = 0.;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticDoubleMethodV(clazz, id, args);
+ va_end(args);
+ }
+ }
+
+ return res;
+}
+
+template <>
+jdouble QJNIObject::callStaticMethod<jdouble>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jdouble res = 0.;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticDoubleMethodV(clazz, id, args);
+ va_end(args);
+ }
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jobject> QJNIObject::callStaticObjectMethod<jobject>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jobject res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticObjectMethodV(clazz, id, args);
+ va_end(args);
+ }
+ }
+
+ return QJNILocalRef<jobject>(res);
+}
+
+template <>
+QJNILocalRef<jobject> QJNIObject::callStaticObjectMethod<jobject>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jobject res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = env->CallStaticObjectMethodV(clazz, id, args);
+ va_end(args);
+ }
+
+ return QJNILocalRef<jobject>(res);
+}
+
+template <>
+QJNILocalRef<jstring> QJNIObject::callStaticObjectMethod<jstring>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jstring res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jstring>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+ }
+
+ return QJNILocalRef<jstring>(res);
+}
+
+template <>
+QJNILocalRef<jstring> QJNIObject::callStaticObjectMethod<jstring>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jstring res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jstring>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+
+ return QJNILocalRef<jstring>(res);
+}
+
+template <>
+QJNILocalRef<jobjectArray> QJNIObject::callStaticObjectMethod<jobjectArray>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jobjectArray res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jobjectArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+ }
+
+ return QJNILocalRef<jobjectArray>(res);
+}
+
+template <>
+QJNILocalRef<jobjectArray> QJNIObject::callStaticObjectMethod<jobjectArray>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jobjectArray res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jobjectArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+
+ return QJNILocalRef<jobjectArray>(res);
+}
+
+template <>
+QJNILocalRef<jbooleanArray> QJNIObject::callStaticObjectMethod<jbooleanArray>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jbooleanArray res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jbooleanArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+ }
+
+ return QJNILocalRef<jbooleanArray>(res);
+}
+
+template <>
+QJNILocalRef<jbooleanArray> QJNIObject::callStaticObjectMethod<jbooleanArray>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jbooleanArray res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jbooleanArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+
+ return QJNILocalRef<jbooleanArray>(res);
+}
+
+template <>
+QJNILocalRef<jbyteArray> QJNIObject::callStaticObjectMethod<jbyteArray>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jbyteArray res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jbyteArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+ }
+
+ return QJNILocalRef<jbyteArray>(res);
+}
+
+template <>
+QJNILocalRef<jbyteArray> QJNIObject::callStaticObjectMethod<jbyteArray>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jbyteArray res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jbyteArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+
+ return QJNILocalRef<jbyteArray>(res);
+}
+
+template <>
+QJNILocalRef<jcharArray> QJNIObject::callStaticObjectMethod<jcharArray>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jcharArray res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jcharArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+ }
+
+ return QJNILocalRef<jcharArray>(res);
+}
+
+template <>
+QJNILocalRef<jcharArray> QJNIObject::callStaticObjectMethod<jcharArray>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jcharArray res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jcharArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+
+ return QJNILocalRef<jcharArray>(res);
+}
+
+template <>
+QJNILocalRef<jshortArray> QJNIObject::callStaticObjectMethod<jshortArray>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jshortArray res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jshortArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+ }
+
+ return QJNILocalRef<jshortArray>(res);
+}
+
+template <>
+QJNILocalRef<jshortArray> QJNIObject::callStaticObjectMethod<jshortArray>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jshortArray res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jshortArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+
+ return QJNILocalRef<jshortArray>(res);
+}
+
+template <>
+QJNILocalRef<jintArray> QJNIObject::callStaticObjectMethod<jintArray>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jintArray res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jintArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+ }
+
+ return QJNILocalRef<jintArray>(res);
+}
+
+template <>
+QJNILocalRef<jintArray> QJNIObject::callStaticObjectMethod<jintArray>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jintArray res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jintArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+
+ return QJNILocalRef<jintArray>(res);
+}
+
+template <>
+QJNILocalRef<jlongArray> QJNIObject::callStaticObjectMethod<jlongArray>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jlongArray res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jlongArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+ }
+
+ return QJNILocalRef<jlongArray>(res);
+}
+
+template <>
+QJNILocalRef<jlongArray> QJNIObject::callStaticObjectMethod<jlongArray>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jlongArray res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jlongArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+
+ return QJNILocalRef<jlongArray>(res);
+}
+
+template <>
+QJNILocalRef<jfloatArray> QJNIObject::callStaticObjectMethod<jfloatArray>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jfloatArray res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jfloatArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+ }
+
+ return QJNILocalRef<jfloatArray>(res);
+}
+
+template <>
+QJNILocalRef<jfloatArray> QJNIObject::callStaticObjectMethod<jfloatArray>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jfloatArray res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jfloatArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+
+ return QJNILocalRef<jfloatArray>(res);
+}
+
+template <>
+QJNILocalRef<jdoubleArray> QJNIObject::callStaticObjectMethod<jdoubleArray>(const char *className,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jdoubleArray res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz) {
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jdoubleArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+ }
+
+ return QJNILocalRef<jdoubleArray>(res);
+}
+
+template <>
+QJNILocalRef<jdoubleArray> QJNIObject::callStaticObjectMethod<jdoubleArray>(jclass clazz,
+ const char *methodName,
+ const char *sig,
+ ...)
+{
+ QAttachedJNIEnv env;
+
+ jdoubleArray res = 0;
+
+ jmethodID id = getCachedMethodID(env, clazz, methodName, sig, true);
+ if (id) {
+ va_list args;
+ va_start(args, sig);
+ res = static_cast<jdoubleArray>(env->CallStaticObjectMethodV(clazz, id, args));
+ va_end(args);
+ }
+
+ return QJNILocalRef<jdoubleArray>(res);
+}
+
+template <>
+void QJNIObject::callStaticMethod<void>(const char *className, const char *methodName)
+{
+ callStaticMethod<void>(className, methodName, "()V");
+}
+
+template <>
+void QJNIObject::callStaticMethod<void>(jclass clazz, const char *methodName)
+{
+ callStaticMethod<void>(clazz, methodName, "()V");
+}
+
+template <>
+jboolean QJNIObject::callStaticMethod<jboolean>(const char *className, const char *methodName)
+{
+ return callStaticMethod<jboolean>(className, methodName, "()Z");
+}
+
+template <>
+jboolean QJNIObject::callStaticMethod<jboolean>(jclass clazz, const char *methodName)
+{
+ return callStaticMethod<jboolean>(clazz, methodName, "()Z");
+}
+
+template <>
+jbyte QJNIObject::callStaticMethod<jbyte>(const char *className, const char *methodName)
+{
+ return callStaticMethod<jbyte>(className, methodName, "()B");
+}
+
+template <>
+jbyte QJNIObject::callStaticMethod<jbyte>(jclass clazz, const char *methodName)
+{
+ return callStaticMethod<jbyte>(clazz, methodName, "()B");
+}
+
+template <>
+jchar QJNIObject::callStaticMethod<jchar>(const char *className, const char *methodName)
+{
+ return callStaticMethod<jchar>(className, methodName, "()C");
+}
+
+template <>
+jchar QJNIObject::callStaticMethod<jchar>(jclass clazz, const char *methodName)
+{
+ return callStaticMethod<jchar>(clazz, methodName, "()C");
+}
+
+template <>
+jshort QJNIObject::callStaticMethod<jshort>(const char *className, const char *methodName)
+{
+ return callStaticMethod<jshort>(className, methodName, "()S");
+}
+
+template <>
+jshort QJNIObject::callStaticMethod<jshort>(jclass clazz, const char *methodName)
+{
+ return callStaticMethod<jshort>(clazz, methodName, "()S");
+}
+
+template <>
+jint QJNIObject::callStaticMethod<jint>(const char *className, const char *methodName)
+{
+ return callStaticMethod<jint>(className, methodName, "()I");
+}
+
+template <>
+jint QJNIObject::callStaticMethod<jint>(jclass clazz, const char *methodName)
+{
+ return callStaticMethod<jint>(clazz, methodName, "()I");
+}
+
+template <>
+jlong QJNIObject::callStaticMethod<jlong>(const char *className, const char *methodName)
+{
+ return callStaticMethod<jlong>(className, methodName, "()J");
+}
+
+template <>
+jlong QJNIObject::callStaticMethod<jlong>(jclass clazz, const char *methodName)
+{
+ return callStaticMethod<jlong>(clazz, methodName, "()J");
+}
+
+template <>
+jfloat QJNIObject::callStaticMethod<jfloat>(const char *className, const char *methodName)
+{
+ return callStaticMethod<jfloat>(className, methodName, "()F");
+}
+
+template <>
+jfloat QJNIObject::callStaticMethod<jfloat>(jclass clazz, const char *methodName)
+{
+ return callStaticMethod<jfloat>(clazz, methodName, "()F");
+}
+
+template <>
+jdouble QJNIObject::callStaticMethod<jdouble>(const char *className, const char *methodName)
+{
+ return callStaticMethod<jdouble>(className, methodName, "()D");
+}
+
+template <>
+jdouble QJNIObject::callStaticMethod<jdouble>(jclass clazz, const char *methodName)
+{
+ return callStaticMethod<jdouble>(clazz, methodName, "()D");
+}
+
+template <>
+QJNILocalRef<jstring> QJNIObject::callStaticObjectMethod<jstring>(const char *className,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jstring>(className, methodName, "()Ljava/lang/String;");
+}
+
+template <>
+QJNILocalRef<jstring> QJNIObject::callStaticObjectMethod<jstring>(jclass clazz,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jstring>(clazz, methodName, "()Ljava/lang/String;");
+}
+
+template <>
+QJNILocalRef<jbooleanArray> QJNIObject::callStaticObjectMethod<jbooleanArray>(const char *className,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jbooleanArray>(className, methodName, "()[Z");
+}
+
+template <>
+QJNILocalRef<jbooleanArray> QJNIObject::callStaticObjectMethod<jbooleanArray>(jclass clazz,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jbooleanArray>(clazz, methodName, "()[Z");
+}
+
+template <>
+QJNILocalRef<jbyteArray> QJNIObject::callStaticObjectMethod<jbyteArray>(const char *className,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jbyteArray>(className, methodName, "()[B");
+}
+
+template <>
+QJNILocalRef<jbyteArray> QJNIObject::callStaticObjectMethod<jbyteArray>(jclass clazz,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jbyteArray>(clazz, methodName, "()[B");
+}
+
+template <>
+QJNILocalRef<jcharArray> QJNIObject::callStaticObjectMethod<jcharArray>(const char *className,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jcharArray>(className, methodName, "()[C");
+}
+
+template <>
+QJNILocalRef<jcharArray> QJNIObject::callStaticObjectMethod<jcharArray>(jclass clazz,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jcharArray>(clazz, methodName, "()[C");
+}
+
+template <>
+QJNILocalRef<jshortArray> QJNIObject::callStaticObjectMethod<jshortArray>(const char *className,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jshortArray>(className, methodName, "()[S");
+}
+
+template <>
+QJNILocalRef<jshortArray> QJNIObject::callStaticObjectMethod<jshortArray>(jclass clazz,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jshortArray>(clazz, methodName, "()[S");
+}
+
+template <>
+QJNILocalRef<jintArray> QJNIObject::callStaticObjectMethod<jintArray>(const char *className,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jintArray>(className, methodName, "()[I");
+}
+
+template <>
+QJNILocalRef<jintArray> QJNIObject::callStaticObjectMethod<jintArray>(jclass clazz,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jintArray>(clazz, methodName, "()[I");
+}
+
+template <>
+QJNILocalRef<jlongArray> QJNIObject::callStaticObjectMethod<jlongArray>(const char *className,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jlongArray>(className, methodName, "()[J");
+}
+
+template <>
+QJNILocalRef<jlongArray> QJNIObject::callStaticObjectMethod<jlongArray>(jclass clazz,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jlongArray>(clazz, methodName, "()[J");
+}
+
+template <>
+QJNILocalRef<jfloatArray> QJNIObject::callStaticObjectMethod<jfloatArray>(const char *className,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jfloatArray>(className, methodName, "()[F");
+}
+
+template <>
+QJNILocalRef<jfloatArray> QJNIObject::callStaticObjectMethod<jfloatArray>(jclass clazz,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jfloatArray>(clazz, methodName, "()[F");
+}
+
+template <>
+QJNILocalRef<jdoubleArray> QJNIObject::callStaticObjectMethod<jdoubleArray>(const char *className,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jdoubleArray>(className, methodName, "()[D");
+}
+
+template <>
+QJNILocalRef<jdoubleArray> QJNIObject::callStaticObjectMethod<jdoubleArray>(jclass clazz,
+ const char *methodName)
+{
+ return callStaticObjectMethod<jdoubleArray>(clazz, methodName, "()[D");
+}
+
+template <>
+jboolean QJNIObject::getField<jboolean>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jboolean res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "Z");
+ if (id)
+ res = env->GetBooleanField(m_jobject, id);
+
+ return res;
+}
+
+template <>
+jbyte QJNIObject::getField<jbyte>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jbyte res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "B");
+ if (id)
+ res = env->GetByteField(m_jobject, id);
+
+ return res;
+}
+
+template <>
+jchar QJNIObject::getField<jchar>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jchar res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "C");
+ if (id)
+ res = env->GetCharField(m_jobject, id);
+
+ return res;
+}
+
+template <>
+jshort QJNIObject::getField<jshort>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jshort res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "S");
+ if (id)
+ res = env->GetShortField(m_jobject, id);
+
+ return res;
+}
+
+template <>
+jint QJNIObject::getField<jint>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jint res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "I");
+ if (id)
+ res = env->GetIntField(m_jobject, id);
+
+ return res;
+}
+
+template <>
+jlong QJNIObject::getField<jlong>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jlong res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "J");
+ if (id)
+ res = env->GetLongField(m_jobject, id);
+
+ return res;
+}
+
+template <>
+jfloat QJNIObject::getField<jfloat>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jfloat res = 0.f;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "F");
+ if (id)
+ res = env->GetFloatField(m_jobject, id);
+
+ return res;
+}
+
+template <>
+jdouble QJNIObject::getField<jdouble>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jdouble res = 0.;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "D");
+ if (id)
+ res = env->GetDoubleField(m_jobject, id);
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jobject> QJNIObject::getObjectField<jobject>(const char *fieldName, const char *sig)
+{
+ QAttachedJNIEnv env;
+ jobject res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, sig);
+ if (id)
+ res = env->GetObjectField(m_jobject, id);
+
+ return QJNILocalRef<jobject>(res);
+}
+
+template <>
+QJNILocalRef<jbooleanArray> QJNIObject::getObjectField<jbooleanArray>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jbooleanArray res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[Z");
+ if (id)
+ res = static_cast<jbooleanArray>(env->GetObjectField(m_jobject, id));
+
+ return QJNILocalRef<jbooleanArray>(res);
+}
+
+template <>
+QJNILocalRef<jbyteArray> QJNIObject::getObjectField<jbyteArray>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jbyteArray res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[B");
+ if (id)
+ res = static_cast<jbyteArray>(env->GetObjectField(m_jobject, id));
+
+ return QJNILocalRef<jbyteArray>(res);
+}
+
+template <>
+QJNILocalRef<jcharArray> QJNIObject::getObjectField<jcharArray>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jcharArray res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[C");
+ if (id)
+ res = static_cast<jcharArray>(env->GetObjectField(m_jobject, id));
+
+ return QJNILocalRef<jcharArray>(res);
+}
+
+template <>
+QJNILocalRef<jshortArray> QJNIObject::getObjectField<jshortArray>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jshortArray res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[S");
+ if (id)
+ res = static_cast<jshortArray>(env->GetObjectField(m_jobject, id));
+
+ return QJNILocalRef<jshortArray>(res);
+}
+
+template <>
+QJNILocalRef<jintArray> QJNIObject::getObjectField<jintArray>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jintArray res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[I");
+ if (id)
+ res = static_cast<jintArray>(env->GetObjectField(m_jobject, id));
+
+ return QJNILocalRef<jintArray>(res);
+}
+
+template <>
+QJNILocalRef<jlongArray> QJNIObject::getObjectField<jlongArray>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jlongArray res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[J");
+ if (id)
+ res = static_cast<jlongArray>(env->GetObjectField(m_jobject, id));
+
+ return QJNILocalRef<jlongArray>(res);
+}
+
+template <>
+QJNILocalRef<jfloatArray> QJNIObject::getObjectField<jfloatArray>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jfloatArray res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[F");
+ if (id)
+ res = static_cast<jfloatArray>(env->GetObjectField(m_jobject, id));
+
+ return QJNILocalRef<jfloatArray>(res);
+}
+
+template <>
+QJNILocalRef<jdoubleArray> QJNIObject::getObjectField<jdoubleArray>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jdoubleArray res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[D");
+ if (id)
+ res = static_cast<jdoubleArray>(env->GetObjectField(m_jobject, id));
+
+ return QJNILocalRef<jdoubleArray>(res);
+}
+
+template <>
+QJNILocalRef<jstring> QJNIObject::getObjectField<jstring>(const char *fieldName)
+{
+ QAttachedJNIEnv env;
+ jstring res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "Ljava/lang/String;");
+ if (id)
+ res = static_cast<jstring>(env->GetObjectField(m_jobject, id));
+
+ return QJNILocalRef<jstring>(res);
+}
+
+template <>
+QJNILocalRef<jobjectArray> QJNIObject::getObjectField<jobjectArray>(const char *fieldName,
+ const char *sig)
+{
+ QAttachedJNIEnv env;
+ jobjectArray res = 0;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, sig);
+ if (id)
+ res = static_cast<jobjectArray>(env->GetObjectField(m_jobject, id));
+
+ return QJNILocalRef<jobjectArray>(res);
+}
+
+template <>
+void QJNIObject::setField<jboolean>(const char *fieldName, jboolean value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "Z");
+ if (id)
+ env->SetBooleanField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jbyte>(const char *fieldName, jbyte value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "B");
+ if (id)
+ env->SetByteField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jchar>(const char *fieldName, jchar value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "C");
+ if (id)
+ env->SetCharField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jshort>(const char *fieldName, jshort value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "S");
+ if (id)
+ env->SetShortField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jint>(const char *fieldName, jint value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "I");
+ if (id)
+ env->SetIntField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jlong>(const char *fieldName, jlong value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "J");
+ if (id)
+ env->SetLongField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jfloat>(const char *fieldName, jfloat value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "F");
+ if (id)
+ env->SetFloatField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jdouble>(const char *fieldName, jdouble value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "D");
+ if (id)
+ env->SetDoubleField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jbooleanArray>(const char *fieldName, jbooleanArray value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[Z");
+ if (id)
+ env->SetObjectField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jbyteArray>(const char *fieldName, jbyteArray value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[B");
+ if (id)
+ env->SetObjectField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jcharArray>(const char *fieldName, jcharArray value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[C");
+ if (id)
+ env->SetObjectField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jshortArray>(const char *fieldName, jshortArray value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[S");
+ if (id)
+ env->SetObjectField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jintArray>(const char *fieldName, jintArray value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[I");
+ if (id)
+ env->SetObjectField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jlongArray>(const char *fieldName, jlongArray value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[J");
+ if (id)
+ env->SetObjectField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jfloatArray>(const char *fieldName, jfloatArray value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[F");
+ if (id)
+ env->SetObjectField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jdoubleArray>(const char *fieldName, jdoubleArray value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "[D");
+ if (id)
+ env->SetObjectField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jstring>(const char *fieldName, jstring value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, "Ljava/lang/String;");
+ if (id)
+ env->SetObjectField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jobject>(const char *fieldName, const char *sig, jobject value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, sig);
+ if (id)
+ env->SetObjectField(m_jobject, id, value);
+
+}
+
+template <>
+void QJNIObject::setField<jobjectArray>(const char *fieldName,
+ const char *sig,
+ jobjectArray value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, m_jclass, fieldName, sig);
+ if (id)
+ env->SetObjectField(m_jobject, id, value);
+
+}
+
+template <>
+jboolean QJNIObject::getStaticField<jboolean>(jclass clazz, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jboolean res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "Z", true);
+ if (id)
+ res = env->GetStaticBooleanField(clazz, id);
+
+ return res;
+}
+
+template <>
+jboolean QJNIObject::getStaticField<jboolean>(const char *className, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jboolean res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticField<jboolean>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+jbyte QJNIObject::getStaticField<jbyte>(jclass clazz, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jbyte res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "B", true);
+ if (id)
+ res = env->GetStaticByteField(clazz, id);
+
+ return res;
+}
+
+template <>
+jbyte QJNIObject::getStaticField<jbyte>(const char *className, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jbyte res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticField<jbyte>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+jchar QJNIObject::getStaticField<jchar>(jclass clazz, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jchar res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "C", true);
+ if (id)
+ res = env->GetStaticCharField(clazz, id);
+
+ return res;
+}
+
+template <>
+jchar QJNIObject::getStaticField<jchar>(const char *className, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jchar res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticField<jchar>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+jshort QJNIObject::getStaticField<jshort>(jclass clazz, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jshort res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "S", true);
+ if (id)
+ res = env->GetStaticShortField(clazz, id);
+
+ return res;
+}
+
+template <>
+jshort QJNIObject::getStaticField<jshort>(const char *className, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jshort res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticField<jshort>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+jint QJNIObject::getStaticField<jint>(jclass clazz, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jint res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "I", true);
+ if (id)
+ res = env->GetStaticIntField(clazz, id);
+
+ return res;
+}
+
+template <>
+jint QJNIObject::getStaticField<jint>(const char *className, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jint res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticField<jint>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+jlong QJNIObject::getStaticField<jlong>(jclass clazz, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jlong res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "J", true);
+ if (id)
+ res = env->GetStaticLongField(clazz, id);
+
+ return res;
+}
+
+template <>
+jlong QJNIObject::getStaticField<jlong>(const char *className, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jlong res = 0;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticField<jlong>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+jfloat QJNIObject::getStaticField<jfloat>(jclass clazz, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jfloat res = 0.f;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "F", true);
+ if (id)
+ res = env->GetStaticFloatField(clazz, id);
+
+ return res;
+}
+
+template <>
+jfloat QJNIObject::getStaticField<jfloat>(const char *className, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jfloat res = 0.f;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticField<jfloat>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+jdouble QJNIObject::getStaticField<jdouble>(jclass clazz, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jdouble res = 0.;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "D", true);
+ if (id)
+ res = env->GetStaticDoubleField(clazz, id);
+
+ return res;
+}
+
+template <>
+jdouble QJNIObject::getStaticField<jdouble>(const char *className, const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jdouble res = 0.;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticField<jdouble>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jobject> QJNIObject::getStaticObjectField<jobject>(jclass clazz,
+ const char *fieldName,
+ const char *sig)
+{
+ QAttachedJNIEnv env;
+
+ jobject res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, sig, true);
+ if (id)
+ res = env->GetStaticObjectField(clazz, id);
+
+ return QJNILocalRef<jobject>(res);
+}
+
+template <>
+QJNILocalRef<jobject> QJNIObject::getStaticObjectField<jobject>(const char *className,
+ const char *fieldName,
+ const char *sig)
+{
+ QAttachedJNIEnv env;
+
+ QJNILocalRef<jobject> res;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticObjectField<jobject>(clazz, fieldName, sig);
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jstring> QJNIObject::getStaticObjectField<jstring>(jclass clazz,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jstring res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "Ljava/lang/String;", true);
+ if (id)
+ res = static_cast<jstring>(env->GetStaticObjectField(clazz, id));
+
+ return QJNILocalRef<jstring>(res);
+}
+
+template <>
+QJNILocalRef<jstring> QJNIObject::getStaticObjectField<jstring>(const char *className,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ QJNILocalRef<jstring> res;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticObjectField<jstring>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jbooleanArray> QJNIObject::getStaticObjectField<jbooleanArray>(jclass clazz,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jbooleanArray res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "[Z", true);
+ if (id)
+ res = static_cast<jbooleanArray>(env->GetStaticObjectField(clazz, id));
+
+ return QJNILocalRef<jbooleanArray>(res);
+}
+
+template <>
+QJNILocalRef<jbooleanArray> QJNIObject::getStaticObjectField<jbooleanArray>(const char *className,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ QJNILocalRef<jbooleanArray> res;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticObjectField<jbooleanArray>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jbyteArray> QJNIObject::getStaticObjectField<jbyteArray>(jclass clazz,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jbyteArray res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "[B", true);
+ if (id)
+ res = static_cast<jbyteArray>(env->GetStaticObjectField(clazz, id));
+
+ return QJNILocalRef<jbyteArray>(res);
+}
+
+template <>
+QJNILocalRef<jbyteArray> QJNIObject::getStaticObjectField<jbyteArray>(const char *className,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ QJNILocalRef<jbyteArray> res;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticObjectField<jbyteArray>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jcharArray> QJNIObject::getStaticObjectField<jcharArray>(jclass clazz,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jcharArray res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "[C", true);
+ if (id)
+ res = static_cast<jcharArray>(env->GetStaticObjectField(clazz, id));
+
+ return QJNILocalRef<jcharArray>(res);
+}
+
+template <>
+QJNILocalRef<jcharArray> QJNIObject::getStaticObjectField<jcharArray>(const char *className,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ QJNILocalRef<jcharArray> res;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticObjectField<jcharArray>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jshortArray> QJNIObject::getStaticObjectField<jshortArray>(jclass clazz,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jshortArray res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "[S", true);
+ if (id)
+ res = static_cast<jshortArray>(env->GetStaticObjectField(clazz, id));
+
+ return QJNILocalRef<jshortArray>(res);
+}
+
+template <>
+QJNILocalRef<jshortArray> QJNIObject::getStaticObjectField<jshortArray>(const char *className,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ QJNILocalRef<jshortArray> res;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticObjectField<jshortArray>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jintArray> QJNIObject::getStaticObjectField<jintArray>(jclass clazz,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jintArray res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "[I", true);
+ if (id)
+ res = static_cast<jintArray>(env->GetStaticObjectField(clazz, id));
+
+ return QJNILocalRef<jintArray>(res);
+}
+
+template <>
+QJNILocalRef<jintArray> QJNIObject::getStaticObjectField<jintArray>(const char *className,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ QJNILocalRef<jintArray> res;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticObjectField<jintArray>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jlongArray> QJNIObject::getStaticObjectField<jlongArray>(jclass clazz,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jlongArray res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "[J", true);
+ if (id)
+ res = static_cast<jlongArray>(env->GetStaticObjectField(clazz, id));
+
+ return QJNILocalRef<jlongArray>(res);
+}
+
+template <>
+QJNILocalRef<jlongArray> QJNIObject::getStaticObjectField<jlongArray>(const char *className,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ QJNILocalRef<jlongArray> res;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticObjectField<jlongArray>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jfloatArray> QJNIObject::getStaticObjectField<jfloatArray>(jclass clazz,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jfloatArray res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "[F", true);
+ if (id)
+ res = static_cast<jfloatArray>(env->GetStaticObjectField(clazz, id));
+
+ return QJNILocalRef<jfloatArray>(res);
+}
+
+template <>
+QJNILocalRef<jfloatArray> QJNIObject::getStaticObjectField<jfloatArray>(const char *className,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ QJNILocalRef<jfloatArray> res;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticObjectField<jfloatArray>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jdoubleArray> QJNIObject::getStaticObjectField<jdoubleArray>(jclass clazz,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ jdoubleArray res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "[D", true);
+ if (id)
+ res = static_cast<jdoubleArray>(env->GetStaticObjectField(clazz, id));
+
+ return QJNILocalRef<jdoubleArray>(res);
+}
+
+template <>
+QJNILocalRef<jdoubleArray> QJNIObject::getStaticObjectField<jdoubleArray>(const char *className,
+ const char *fieldName)
+{
+ QAttachedJNIEnv env;
+
+ QJNILocalRef<jdoubleArray> res;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticObjectField<jdoubleArray>(clazz, fieldName);
+
+ return res;
+}
+
+template <>
+QJNILocalRef<jobjectArray> QJNIObject::getStaticObjectField<jobjectArray>(jclass clazz,
+ const char *fieldName,
+ const char *sig)
+{
+ QAttachedJNIEnv env;
+
+ jobjectArray res = 0;
+
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, sig, true);
+ if (id)
+ res = static_cast<jobjectArray>(env->GetStaticObjectField(clazz, id));
+
+ return QJNILocalRef<jobjectArray>(res);
+}
+
+template <>
+QJNILocalRef<jobjectArray> QJNIObject::getStaticObjectField<jobjectArray>(const char *className,
+ const char *fieldName,
+ const char *sig)
+{
+ QAttachedJNIEnv env;
+
+ QJNILocalRef<jobjectArray> res;
+
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ res = getStaticObjectField<jobjectArray>(clazz, fieldName, sig);
+
+ return res;
+}
+
+template <>
+void QJNIObject::setStaticField<jboolean>(jclass clazz, const char *fieldName, jboolean value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "Z", true);
+ if (id)
+ env->SetStaticBooleanField(clazz, id, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jboolean>(const char *className,
+ const char *fieldName,
+ jboolean value)
+{
+ QAttachedJNIEnv env;
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ setStaticField<jboolean>(clazz, fieldName, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jbyte>(jclass clazz, const char *fieldName, jbyte value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "B", true);
+ if (id)
+ env->SetStaticByteField(clazz, id, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jbyte>(const char *className,
+ const char *fieldName,
+ jbyte value)
+{
+ QAttachedJNIEnv env;
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ setStaticField<jbyte>(clazz, fieldName, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jchar>(jclass clazz, const char *fieldName, jchar value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "C", true);
+ if (id)
+ env->SetStaticCharField(clazz, id, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jchar>(const char *className,
+ const char *fieldName,
+ jchar value)
+{
+ QAttachedJNIEnv env;
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ setStaticField<jchar>(clazz, fieldName, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jshort>(jclass clazz, const char *fieldName, jshort value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "S", true);
+ if (id)
+ env->SetStaticShortField(clazz, id, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jshort>(const char *className,
+ const char *fieldName,
+ jshort value)
+{
+ QAttachedJNIEnv env;
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ setStaticField<jshort>(clazz, fieldName, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jint>(jclass clazz, const char *fieldName, jint value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "I", true);
+ if (id)
+ env->SetStaticIntField(clazz, id, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jint>(const char *className, const char *fieldName, jint value)
+{
+ QAttachedJNIEnv env;
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ setStaticField<jint>(clazz, fieldName, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jlong>(jclass clazz, const char *fieldName, jlong value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "J", true);
+ if (id)
+ env->SetStaticLongField(clazz, id, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jlong>(const char *className,
+ const char *fieldName,
+ jlong value)
+{
+ QAttachedJNIEnv env;
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ setStaticField<jlong>(clazz, fieldName, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jfloat>(jclass clazz, const char *fieldName, jfloat value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "F", true);
+ if (id)
+ env->SetStaticFloatField(clazz, id, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jfloat>(const char *className,
+ const char *fieldName,
+ jfloat value)
+{
+ QAttachedJNIEnv env;
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ setStaticField<jfloat>(clazz, fieldName, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jdouble>(jclass clazz, const char *fieldName, jdouble value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, "D", true);
+ if (id)
+ env->SetStaticDoubleField(clazz, id, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jdouble>(const char *className,
+ const char *fieldName,
+ jdouble value)
+{
+ QAttachedJNIEnv env;
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ setStaticField<jdouble>(clazz, fieldName, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jobject>(jclass clazz,
+ const char *fieldName,
+ const char *sig,
+ jobject value)
+{
+ QAttachedJNIEnv env;
+ jfieldID id = getCachedFieldID(env, clazz, fieldName, sig, true);
+ if (id)
+ env->SetStaticObjectField(clazz, id, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jobject>(const char *className,
+ const char *fieldName,
+ const char *sig,
+ jobject value)
+{
+ QAttachedJNIEnv env;
+ jclass clazz = getCachedClass(env, className);
+ if (clazz)
+ setStaticField<jobject>(clazz, fieldName, sig, value);
+}
+
+template <>
+void QJNIObject::setStaticField<jstring>(const char *className,
+ const char *fieldName,
+ jstring value)
+{
+ setStaticField<jobject>(className, fieldName, "Ljava/lang/String;", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jstring>(jclass clazz, const char *fieldName, jstring value)
+{
+ setStaticField<jobject>(clazz, fieldName, "Ljava/lang/String;", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jbooleanArray>(const char *className,
+ const char *fieldName,
+ jbooleanArray value)
+{
+ setStaticField<jobject>(className, fieldName, "[Z", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jbooleanArray>(jclass clazz,
+ const char *fieldName,
+ jbooleanArray value)
+{
+ setStaticField<jobject>(clazz, fieldName, "[Z", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jbyteArray>(const char *className,
+ const char *fieldName,
+ jbyteArray value)
+{
+ setStaticField<jobject>(className, fieldName, "[B", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jbyteArray>(jclass clazz,
+ const char *fieldName,
+ jbyteArray value)
+{
+ setStaticField<jobject>(clazz, fieldName, "[B", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jcharArray>(const char *className,
+ const char *fieldName,
+ jcharArray value)
+{
+ setStaticField<jobject>(className, fieldName, "[C", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jcharArray>(jclass clazz,
+ const char *fieldName,
+ jcharArray value)
+{
+ setStaticField<jobject>(clazz, fieldName, "[C", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jshortArray>(const char *className,
+ const char *fieldName,
+ jshortArray value)
+{
+ setStaticField<jobject>(className, fieldName, "[S", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jshortArray>(jclass clazz,
+ const char *fieldName,
+ jshortArray value)
+{
+ setStaticField<jobject>(clazz, fieldName, "[S", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jintArray>(const char *className,
+ const char *fieldName,
+ jintArray value)
+{
+ setStaticField<jobject>(className, fieldName, "[I", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jintArray>(jclass clazz,
+ const char *fieldName,
+ jintArray value)
+{
+ setStaticField<jobject>(clazz, fieldName, "[I", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jlongArray>(const char *className,
+ const char *fieldName,
+ jlongArray value)
+{
+ setStaticField<jobject>(className, fieldName, "[J", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jlongArray>(jclass clazz,
+ const char *fieldName,
+ jlongArray value)
+{
+ setStaticField<jobject>(clazz, fieldName, "[J", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jfloatArray>(const char *className,
+ const char *fieldName,
+ jfloatArray value)
+{
+ setStaticField<jobject>(className, fieldName, "[F", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jfloatArray>(jclass clazz,
+ const char *fieldName,
+ jfloatArray value)
+{
+ setStaticField<jobject>(clazz, fieldName, "[F", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jdoubleArray>(const char *className,
+ const char *fieldName,
+ jdoubleArray value)
+{
+ setStaticField<jobject>(className, fieldName, "[D", value);
+}
+
+template <>
+void QJNIObject::setStaticField<jdoubleArray>(jclass clazz,
+ const char *fieldName,
+ jdoubleArray value)
+{
+ setStaticField<jobject>(clazz, fieldName, "[D", value);
+}
+
+
+QT_END_NAMESPACE
diff --git a/src/platformsupport/jniconvenience/qjniobject_p.h b/src/platformsupport/jniconvenience/qjniobject_p.h
new file mode 100644
index 0000000000..6874765f06
--- /dev/null
+++ b/src/platformsupport/jniconvenience/qjniobject_p.h
@@ -0,0 +1,169 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QJNIOBJECT_H
+#define QJNIOBJECT_H
+
+#include <qglobal.h>
+#include <jni.h>
+
+QT_BEGIN_NAMESPACE
+
+template <typename T>
+class QJNILocalRef;
+
+/**
+ * Allows to wrap any Java class and partially hide some of the jni calls.
+ *
+ * Usage example:
+ *
+ * QJNIObject javaString("java/lang/String");
+ * jchar char = javaString.callMethod<jchar>("charAt", "(I)C", 0);
+ *
+ * ----
+ *
+ * jstring string = QJNIObject::callStaticMethod<jstring>("java/lang/String",
+ * "valueOf",
+ * "(I)Ljava/lang/String;", 2);
+ *
+ * ----
+ *
+ * // Constructor with argument
+ * jstring someString;
+ * QJNIObject someObject("java/some/Class", "(Ljava/lang/String;)V", someString);
+ * someObject.setField<jint>("fieldName", 10);
+ * someObject.callMethod<void>("doStuff");
+ */
+class QJNIObject
+{
+public:
+ QJNIObject(const char *className);
+ QJNIObject(const char *className, const char *sig, ...);
+ QJNIObject(jclass clazz);
+ QJNIObject(jclass clazz, const char *sig, ...);
+ QJNIObject(jobject obj);
+ virtual ~QJNIObject();
+
+ static bool isClassAvailable(const char *className);
+
+ bool isValid() const { return m_jobject != 0; }
+ jobject object() const { return m_jobject; }
+
+ template <typename T>
+ T callMethod(const char *methodName);
+ template <typename T>
+ T callMethod(const char *methodName, const char *sig, ...);
+ template <typename T>
+ QJNILocalRef<T> callObjectMethod(const char *methodName);
+ template <typename T>
+ QJNILocalRef<T> callObjectMethod(const char *methodName, const char *sig, ...);
+
+ template <typename T>
+ static T callStaticMethod(const char *className, const char *methodName);
+ template <typename T>
+ static T callStaticMethod(const char *className, const char *methodName, const char *sig, ...);
+ template <typename T>
+ static QJNILocalRef<T> callStaticObjectMethod(const char *className, const char *methodName);
+ template <typename T>
+ static QJNILocalRef<T> callStaticObjectMethod(const char *className,
+ const char *methodName,
+ const char *sig, ...);
+ template <typename T>
+ static T callStaticMethod(jclass clazz, const char *methodName);
+ template <typename T>
+ static T callStaticMethod(jclass clazz, const char *methodName, const char *sig, ...);
+ template <typename T>
+ static QJNILocalRef<T> callStaticObjectMethod(jclass clazz, const char *methodName);
+ template <typename T>
+ static QJNILocalRef<T> callStaticObjectMethod(jclass clazz,
+ const char *methodName,
+ const char *sig, ...);
+
+ template <typename T>
+ T getField(const char *fieldName);
+ template <typename T>
+ T getField(const char *fieldName, const char *sig);
+ template <typename T>
+ QJNILocalRef<T> getObjectField(const char *fieldName);
+ template <typename T>
+ QJNILocalRef<T> getObjectField(const char *fieldName, const char *sig);
+
+ template <typename T>
+ void setField(const char *fieldName, T value);
+ template <typename T>
+ void setField(const char *fieldName, const char *sig, T value);
+
+ template <typename T>
+ static QJNILocalRef<T> getStaticObjectField(const char *className, const char *fieldName);
+ template <typename T>
+ static QJNILocalRef<T> getStaticObjectField(const char *className,
+ const char *fieldName,
+ const char *sig);
+ template <typename T>
+ static T getStaticField(const char *className, const char *fieldName);
+ template <typename T>
+ static QJNILocalRef<T> getStaticObjectField(jclass clazz, const char *fieldName);
+ template <typename T>
+ static QJNILocalRef<T> getStaticObjectField(jclass clazz, const char *fieldName, const char *sig);
+ template <typename T>
+ static T getStaticField(jclass clazz, const char *fieldName);
+
+ template <typename T>
+ static void setStaticField(const char *className,
+ const char *fieldName,
+ const char *sig,
+ T value);
+ template <typename T>
+ static void setStaticField(const char *className, const char *fieldName, T value);
+ template <typename T>
+ static void setStaticField(jclass clazz, const char *fieldName, const char *sig, T value);
+ template <typename T>
+ static void setStaticField(jclass clazz, const char *fieldName, T value);
+
+protected:
+ jobject m_jobject;
+ jclass m_jclass;
+ bool m_own_jclass;
+};
+
+QT_END_NAMESPACE
+
+#endif // QJNIOBJECT_H
diff --git a/src/platformsupport/linuxaccessibility/application.cpp b/src/platformsupport/linuxaccessibility/application.cpp
index 6e826e4432..5c8f2e5fe2 100644
--- a/src/platformsupport/linuxaccessibility/application.cpp
+++ b/src/platformsupport/linuxaccessibility/application.cpp
@@ -174,7 +174,7 @@ bool QSpiApplicationAdaptor::eventFilter(QObject *target, QEvent *event)
SLOT(notifyKeyboardListenerError(QDBusError, QDBusMessage)), timeout);
if (sent) {
//queue the event and send it after callback
- keyEvents.enqueue(QPair<QObject*, QKeyEvent*> (target, copyKeyEvent(keyEvent)));
+ keyEvents.enqueue(QPair<QPointer<QObject>, QKeyEvent*> (QPointer<QObject>(target), copyKeyEvent(keyEvent)));
#ifdef KEYBOARD_DEBUG
qDebug() << QStringLiteral("Sent key: ") << de.text;
#endif
@@ -200,11 +200,12 @@ void QSpiApplicationAdaptor::notifyKeyboardListenerCallback(const QDBusMessage&
}
Q_ASSERT(message.arguments().length() == 1);
if (message.arguments().at(0).toBool() == true) {
- QPair<QObject*, QKeyEvent*> event = keyEvents.dequeue();
+ QPair<QPointer<QObject>, QKeyEvent*> event = keyEvents.dequeue();
delete event.second;
} else {
- QPair<QObject*, QKeyEvent*> event = keyEvents.dequeue();
- QCoreApplication::postEvent(event.first, event.second);
+ QPair<QPointer<QObject>, QKeyEvent*> event = keyEvents.dequeue();
+ if (event.first)
+ QCoreApplication::postEvent(event.first.data(), event.second);
}
}
@@ -212,8 +213,9 @@ void QSpiApplicationAdaptor::notifyKeyboardListenerError(const QDBusError& error
{
qWarning() << QStringLiteral("QSpiApplication::keyEventError ") << error.name() << error.message();
while (!keyEvents.isEmpty()) {
- QPair<QObject*, QKeyEvent*> event = keyEvents.dequeue();
- QCoreApplication::postEvent(event.first, event.second);
+ QPair<QPointer<QObject>, QKeyEvent*> event = keyEvents.dequeue();
+ if (event.first)
+ QCoreApplication::postEvent(event.first.data(), event.second);
}
}
diff --git a/src/platformsupport/linuxaccessibility/application_p.h b/src/platformsupport/linuxaccessibility/application_p.h
index 9b6763f111..e8684ab2b5 100644
--- a/src/platformsupport/linuxaccessibility/application_p.h
+++ b/src/platformsupport/linuxaccessibility/application_p.h
@@ -42,11 +42,11 @@
#ifndef Q_SPI_APPLICATION_H
#define Q_SPI_APPLICATION_H
+#include <QtCore/QPointer>
#include <QtCore/QQueue>
#include <QtDBus/QDBusConnection>
#include <QtGui/QAccessibleInterface>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
/*
@@ -76,11 +76,10 @@ private Q_SLOTS:
private:
static QKeyEvent* copyKeyEvent(QKeyEvent*);
- QQueue<QPair<QObject*, QKeyEvent*> > keyEvents;
+ QQueue<QPair<QPointer<QObject>, QKeyEvent*> > keyEvents;
QDBusConnection dbusConnection;
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif
diff --git a/src/platformsupport/linuxaccessibility/atspiadaptor.cpp b/src/platformsupport/linuxaccessibility/atspiadaptor.cpp
index 001976e9fe..6efd5085ac 100644
--- a/src/platformsupport/linuxaccessibility/atspiadaptor.cpp
+++ b/src/platformsupport/linuxaccessibility/atspiadaptor.cpp
@@ -587,7 +587,7 @@ QString AtSpiAdaptor::introspect(const QString &path) const
" </interface>\n"
);
- QAIPointer interface = interfaceFromPath(path);
+ QAccessibleInterface * interface = interfaceFromPath(path);
if (!interface) {
qAtspiDebug() << "WARNING Qt AtSpiAdaptor: Could not find accessible on path: " << path;
return QString();
@@ -809,10 +809,13 @@ void AtSpiAdaptor::windowActivated(QObject* window, bool active)
return;
QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(window);
- Q_ASSERT(iface && iface->isValid());
+ Q_ASSERT(iface);
+ Q_ASSERT(!active || iface->isValid());
- QString windowTitle = iface->text(QAccessible::Name);
- delete iface;
+ QString windowTitle;
+ // in dtor it may be invalid
+ if (iface->isValid())
+ windowTitle = iface->text(QAccessible::Name);
QDBusVariant data;
data.setVariant(windowTitle);
@@ -850,48 +853,28 @@ bool AtSpiAdaptor::sendDBusSignal(const QString &path, const QString &interface,
return m_dbus->connection().send(message);
}
-QAIPointer AtSpiAdaptor::interfaceFromPath(const QString& dbusPath) const
+QAccessibleInterface *AtSpiAdaptor::interfaceFromPath(const QString& dbusPath) const
{
if (dbusPath == QLatin1String(QSPI_OBJECT_PATH_ROOT))
- return QAIPointer(QAccessible::queryAccessibleInterface(qApp));
+ return QAccessible::queryAccessibleInterface(qApp);
QStringList parts = dbusPath.split(QLatin1Char('/'));
- if (parts.size() <= 5) {
+ if (parts.size() != 6) {
qAtspiDebug() << "invalid path: " << dbusPath;
- return QAIPointer();
+ return 0;
}
QString objectString = parts.at(5);
- quintptr uintptr = objectString.toULongLong();
-
- if (uintptr && m_handledObjects.contains(uintptr)) {
- // We found the pointer, check if it's still valid:
- if (m_handledObjects[uintptr]) {
- QObject* object = reinterpret_cast<QObject*>(uintptr);
-
- QAIPointer interface = QAIPointer(QAccessible::queryAccessibleInterface(object));
- if (!interface)
- return QAIPointer();
-
- for (int i = 6; i < parts.size(); ++i) {
- int childIndex = parts.at(i).toInt();
- if (childIndex < 0) {
- qAtspiDebug() << "Invalid child index";
- return QAIPointer();
- }
- QAIPointer childInterface(interface->child(childIndex));
- if (childInterface)
- interface = childInterface;
- }
- return interface;
- } else {
- m_handledObjects.remove(uintptr);
- }
- }
- return QAIPointer();
+ QAccessible::Id id = objectString.toUInt();
+
+ // The id is always in the range [INT_MAX+1, UINT_MAX]
+ if ((int)id >= 0)
+ qWarning() << "No accessible object found for id: " << id;
+
+ return QAccessible::accessibleInterface(id);
}
-void AtSpiAdaptor::notifyStateChange(const QAIPointer &interface, const QString &state, int value)
+void AtSpiAdaptor::notifyStateChange(QAccessibleInterface *interface, const QString &state, int value)
{
QString path = pathForInterface(interface);
QVariantList stateArgs = packDBusSignalArguments(state, value, 0, variantForPath(path));
@@ -908,28 +891,28 @@ void AtSpiAdaptor::notify(QAccessibleEvent *event)
switch (event->type()) {
case QAccessible::ObjectCreated:
if (sendObject || sendObject_children_changed)
- notifyAboutCreation(QAIPointer(event->accessibleInterface()));
+ notifyAboutCreation(event->accessibleInterface());
break;
case QAccessible::ObjectShow: {
if (sendObject || sendObject_state_changed) {
- notifyStateChange(QAIPointer(event->accessibleInterface()), QLatin1String("showing"), 1);
+ notifyStateChange(event->accessibleInterface(), QLatin1String("showing"), 1);
}
break;
}
case QAccessible::ObjectHide: {
if (sendObject || sendObject_state_changed) {
- notifyStateChange(QAIPointer(event->accessibleInterface()), QLatin1String("showing"), 0);
+ notifyStateChange(event->accessibleInterface(), QLatin1String("showing"), 0);
}
break;
}
case QAccessible::ObjectDestroyed: {
if (sendObject || sendObject_state_changed)
- notifyAboutDestruction(QAIPointer(event->accessibleInterface()));
+ notifyAboutDestruction(event->accessibleInterface());
break;
}
case QAccessible::NameChanged: {
if (sendObject || sendObject_property_change || sendObject_property_change_accessible_name) {
- QString path = pathForInterface(QAIPointer(event->accessibleInterface()));
+ QString path = pathForInterface(event->accessibleInterface());
QVariantList args = packDBusSignalArguments(QLatin1String("accessible-name"), 0, 0, variantForPath(path));
sendDBusSignal(path, QLatin1String(ATSPI_DBUS_INTERFACE_EVENT_OBJECT),
QLatin1String("PropertyChange"), args);
@@ -938,7 +921,7 @@ void AtSpiAdaptor::notify(QAccessibleEvent *event)
}
case QAccessible::DescriptionChanged: {
if (sendObject || sendObject_property_change || sendObject_property_change_accessible_description) {
- QString path = pathForInterface(QAIPointer(event->accessibleInterface()));
+ QString path = pathForInterface(event->accessibleInterface());
QVariantList args = packDBusSignalArguments(QLatin1String("accessible-description"), 0, 0, variantForPath(path));
sendDBusSignal(path, QLatin1String(ATSPI_DBUS_INTERFACE_EVENT_OBJECT),
QLatin1String("PropertyChange"), args);
@@ -947,14 +930,14 @@ void AtSpiAdaptor::notify(QAccessibleEvent *event)
}
case QAccessible::Focus: {
if (sendFocus || sendObject || sendObject_state_changed)
- sendFocusChanged(QAIPointer(event->accessibleInterface()));
+ sendFocusChanged(event->accessibleInterface());
break;
}
case QAccessible::TextInserted:
case QAccessible::TextRemoved:
case QAccessible::TextUpdated: {
if (sendObject || sendObject_text_changed) {
- QAIPointer iface = QAIPointer(event->accessibleInterface());
+ QAccessibleInterface * iface = event->accessibleInterface();
if (!iface || !iface->textInterface()) {
qAtspiDebug() << "Received text event for invalid interface.";
return;
@@ -1012,7 +995,7 @@ void AtSpiAdaptor::notify(QAccessibleEvent *event)
}
case QAccessible::TextCaretMoved: {
if (sendObject || sendObject_text_caret_moved) {
- QAIPointer iface = QAIPointer(event->accessibleInterface());
+ QAccessibleInterface * iface = event->accessibleInterface();
if (!iface || !iface->textInterface()) {
qWarning() << "Sending TextCaretMoved from object that does not implement text interface: " << iface;
return;
@@ -1030,7 +1013,7 @@ void AtSpiAdaptor::notify(QAccessibleEvent *event)
}
case QAccessible::TextSelectionChanged: {
if (sendObject || sendObject_text_selection_changed) {
- QAIPointer iface = QAIPointer(event->accessibleInterface());
+ QAccessibleInterface * iface = event->accessibleInterface();
QString path = pathForInterface(iface);
QVariantList args = packDBusSignalArguments(QString(), 0, 0, QVariant::fromValue(QDBusVariant(QVariant(QString()))));
sendDBusSignal(path, QLatin1String(ATSPI_DBUS_INTERFACE_EVENT_OBJECT),
@@ -1040,7 +1023,7 @@ void AtSpiAdaptor::notify(QAccessibleEvent *event)
}
case QAccessible::ValueChanged: {
if (sendObject || sendObject_value_changed || sendObject_property_change_accessible_value) {
- QAIPointer iface = QAIPointer(event->accessibleInterface());
+ QAccessibleInterface * iface = event->accessibleInterface();
if (!iface || !iface->valueInterface()) {
qWarning() << "ValueChanged event from invalid accessible: " << iface;
return;
@@ -1054,7 +1037,7 @@ void AtSpiAdaptor::notify(QAccessibleEvent *event)
break;
}
case QAccessible::Selection: {
- QAIPointer iface = QAIPointer(event->accessibleInterface());
+ QAccessibleInterface * iface = event->accessibleInterface();
if (!iface) {
qWarning() << "Selection event from invalid accessible.";
return;
@@ -1071,7 +1054,7 @@ void AtSpiAdaptor::notify(QAccessibleEvent *event)
if (sendObject || sendObject_state_changed || sendWindow || sendWindow_activate) {
QAccessible::State stateChange = static_cast<QAccessibleStateChangeEvent*>(event)->changedStates();
if (stateChange.checked) {
- QAIPointer iface = QAIPointer(event->accessibleInterface());
+ QAccessibleInterface * iface = event->accessibleInterface();
if (!iface) {
qWarning() << "StateChanged event from invalid accessible.";
return;
@@ -1079,7 +1062,7 @@ void AtSpiAdaptor::notify(QAccessibleEvent *event)
int checked = iface->state().checked;
notifyStateChange(iface, QLatin1String("checked"), checked);
} else if (stateChange.active) {
- QAIPointer iface = QAIPointer(event->accessibleInterface());
+ QAccessibleInterface * iface = event->accessibleInterface();
if (!iface || !(iface->role() == QAccessible::Window && (sendWindow || sendWindow_activate)))
return;
QString windowTitle = iface->text(QAccessible::Name);
@@ -1094,7 +1077,7 @@ void AtSpiAdaptor::notify(QAccessibleEvent *event)
int isActive = iface->state().active;
notifyStateChange(iface, QLatin1String("active"), isActive);
} else if (stateChange.disabled) {
- QAIPointer iface = QAIPointer(event->accessibleInterface());
+ QAccessibleInterface *iface = event->accessibleInterface();
QAccessible::State state = iface->state();
bool enabled = !state.disabled;
@@ -1166,7 +1149,7 @@ void AtSpiAdaptor::notify(QAccessibleEvent *event)
}
}
-void AtSpiAdaptor::sendFocusChanged(const QAIPointer &interface) const
+void AtSpiAdaptor::sendFocusChanged(QAccessibleInterface *interface) const
{
static QString lastFocusPath;
// "remove" old focus
@@ -1190,13 +1173,13 @@ void AtSpiAdaptor::sendFocusChanged(const QAIPointer &interface) const
}
}
-void AtSpiAdaptor::notifyAboutCreation(const QAIPointer &interface) const
+void AtSpiAdaptor::notifyAboutCreation(QAccessibleInterface *interface) const
{
// // say hello to d-bus
// cache->emitAddAccessible(accessible->getCacheItem());
// notify about the new child of our parent
- QAIPointer parent(interface->parent());
+ QAccessibleInterface * parent = interface->parent();
if (!parent) {
qAtspiDebug() << "AtSpiAdaptor::notifyAboutCreation: Could not find parent for " << interface->object();
return;
@@ -1208,12 +1191,12 @@ void AtSpiAdaptor::notifyAboutCreation(const QAIPointer &interface) const
sendDBusSignal(parentPath, QLatin1String(ATSPI_DBUS_INTERFACE_EVENT_OBJECT), QLatin1String("ChildrenChanged"), args);
}
-void AtSpiAdaptor::notifyAboutDestruction(const QAIPointer &interface) const
+void AtSpiAdaptor::notifyAboutDestruction(QAccessibleInterface *interface) const
{
if (!interface || !interface->isValid())
return;
- QAIPointer parent(interface->parent());
+ QAccessibleInterface * parent = interface->parent();
if (!parent) {
qAtspiDebug() << "AtSpiAdaptor::notifyAboutDestruction: Could not find parent for " << interface->object();
return;
@@ -1229,7 +1212,7 @@ void AtSpiAdaptor::notifyAboutDestruction(const QAIPointer &interface) const
// childIndex = parent->indexOfChild(interface);
// }
- QString parentPath = pathForInterface(parent, true);
+ QString parentPath = pathForInterface(parent);
QVariantList args = packDBusSignalArguments(QLatin1String("remove"), childIndex, 0, variantForPath(path));
sendDBusSignal(parentPath, QLatin1String(ATSPI_DBUS_INTERFACE_EVENT_OBJECT), QLatin1String("ChildrenChanged"), args);
}
@@ -1241,7 +1224,7 @@ void AtSpiAdaptor::notifyAboutDestruction(const QAIPointer &interface) const
bool AtSpiAdaptor::handleMessage(const QDBusMessage &message, const QDBusConnection &connection)
{
// get accessible interface
- QAIPointer accessible = interfaceFromPath(message.path());
+ QAccessibleInterface * accessible = interfaceFromPath(message.path());
if (!accessible) {
qAtspiDebug() << "WARNING Qt AtSpiAdaptor: Could not find accessible on path: " << message.path();
return false;
@@ -1291,7 +1274,7 @@ bool AtSpiAdaptor::handleMessage(const QDBusMessage &message, const QDBusConnect
}
// Application
-bool AtSpiAdaptor::applicationInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
+bool AtSpiAdaptor::applicationInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
{
if (message.path() != QLatin1String(ATSPI_DBUS_PATH_ROOT)) {
qAtspiDebug() << "WARNING Qt AtSpiAdaptor: Could not find application interface for: " << message.path() << interface;
@@ -1354,7 +1337,7 @@ void AtSpiAdaptor::registerApplication()
}
// Accessible
-bool AtSpiAdaptor::accessibleInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
+bool AtSpiAdaptor::accessibleInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
{
if (function == QLatin1String("GetRole")) {
sendReply(connection, message, (uint) getRole(interface));
@@ -1368,9 +1351,9 @@ bool AtSpiAdaptor::accessibleInterface(const QAIPointer &interface, const QStrin
sendReply(connection, message, QVariant::fromValue(QDBusVariant(interface->childCount())));
} else if (function == QLatin1String("GetIndexInParent")) {
int childIndex = -1;
- QAIPointer parent(interface->parent());
+ QAccessibleInterface * parent = interface->parent();
if (parent) {
- childIndex = parent->indexOfChild(interface.data());
+ childIndex = parent->indexOfChild(interface);
if (childIndex < 0) {
qAtspiDebug() << "GetIndexInParent get invalid index: " << childIndex << interface;
}
@@ -1378,7 +1361,7 @@ bool AtSpiAdaptor::accessibleInterface(const QAIPointer &interface, const QStrin
sendReply(connection, message, childIndex);
} else if (function == QLatin1String("GetParent")) {
QString path;
- QAIPointer parent(interface->parent());
+ QAccessibleInterface * parent = interface->parent();
if (!parent) {
path = QLatin1String(ATSPI_DBUS_PATH_NULL);
} else if (parent->role() == QAccessible::Application) {
@@ -1395,7 +1378,7 @@ bool AtSpiAdaptor::accessibleInterface(const QAIPointer &interface, const QStrin
sendReply(connection, message, QVariant::fromValue(
QSpiObjectReference(connection, QDBusObjectPath(ATSPI_DBUS_PATH_NULL))));
} else {
- QAIPointer childInterface = QAIPointer(interface->child(index));
+ QAccessibleInterface * childInterface = interface->child(index);
sendReply(connection, message, QVariant::fromValue(
QSpiObjectReference(connection, QDBusObjectPath(pathForInterface(childInterface)))));
}
@@ -1436,7 +1419,7 @@ bool AtSpiAdaptor::accessibleInterface(const QAIPointer &interface, const QStrin
} else if (function == QLatin1String("GetChildren")) {
QSpiObjectReferenceArray children;
for (int i = 0; i < interface->childCount(); ++i) {
- QString childPath = pathForInterface(QAIPointer(interface->child(i)));
+ QString childPath = pathForInterface(interface->child(i));
QSpiObjectReference ref(connection, QDBusObjectPath(childPath));
children << ref;
}
@@ -1448,7 +1431,7 @@ bool AtSpiAdaptor::accessibleInterface(const QAIPointer &interface, const QStrin
return true;
}
-AtspiRole AtSpiAdaptor::getRole(const QAIPointer &interface) const
+AtspiRole AtSpiAdaptor::getRole(QAccessibleInterface *interface) const
{
if ((interface->role() == QAccessible::EditableText) && interface->state().passwordEdit)
return ATSPI_ROLE_PASSWORD_TEXT;
@@ -1457,7 +1440,7 @@ AtspiRole AtSpiAdaptor::getRole(const QAIPointer &interface) const
//#define ACCESSIBLE_CREATION_DEBUG
-QStringList AtSpiAdaptor::accessibleInterfaces(const QAIPointer &interface) const
+QStringList AtSpiAdaptor::accessibleInterfaces(QAccessibleInterface *interface) const
{
QStringList ifaces;
#ifdef ACCESSIBLE_CREATION_DEBUG
@@ -1501,7 +1484,7 @@ QStringList AtSpiAdaptor::accessibleInterfaces(const QAIPointer &interface) cons
return ifaces;
}
-QSpiRelationArray AtSpiAdaptor::relationSet(const QAIPointer &interface, const QDBusConnection &connection) const
+QSpiRelationArray AtSpiAdaptor::relationSet(QAccessibleInterface *interface, const QDBusConnection &connection) const
{
typedef QPair<QAccessibleInterface*, QAccessible::Relation> RelationPair;
QVector<RelationPair> relationInterfaces;
@@ -1513,7 +1496,7 @@ QSpiRelationArray AtSpiAdaptor::relationSet(const QAIPointer &interface, const Q
//And why is it a list, when it always have one item? And it seems to assume that the QAccessible::Relation enum maps directly to AtSpi
QList<QSpiObjectReference> related;
- QDBusObjectPath path = QDBusObjectPath(pathForInterface(QAIPointer(pair.first)));
+ QDBusObjectPath path = QDBusObjectPath(pathForInterface(pair.first));
related.append(QSpiObjectReference(connection, path));
if (!related.isEmpty())
@@ -1533,56 +1516,24 @@ QString AtSpiAdaptor::pathForObject(QObject *object) const
{
Q_ASSERT(object);
- if (object == qApp) {
- return QLatin1String(QSPI_OBJECT_PATH_ROOT);
- }
-
- if (qstrcmp(object->metaObject()->className(), "QAction") == 0) {
+ if (inheritsQAction(object)) {
qAtspiDebug() << "AtSpiAdaptor::pathForObject: warning: creating path with QAction as object.";
}
- quintptr uintptr = reinterpret_cast<quintptr>(object);
- if (!m_handledObjects.contains(uintptr) || m_handledObjects.value(uintptr) == 0)
- m_handledObjects[uintptr] = QPointer<QObject>(object);
- return QLatin1String(QSPI_OBJECT_PATH_PREFIX) + QString::number(uintptr);
+
+ QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(object);
+ return pathForInterface(iface);
}
-QString AtSpiAdaptor::pathForInterface(const QAIPointer &interface, bool inDestructor) const
+QString AtSpiAdaptor::pathForInterface(QAccessibleInterface *interface) const
{
if (!interface || !interface->isValid())
return QLatin1String(ATSPI_DBUS_PATH_NULL);
if (interface->role() == QAccessible::Application)
return QLatin1String(QSPI_OBJECT_PATH_ROOT);
- QAIPointer interfaceWithObject = interface;
- QString path;
-
- QAccessible::Role role = interface->role();
- if (((role == QAccessible::MenuItem) || (role == QAccessible::Separator)) &&
- interface->object() && inheritsQAction(interface->object())) {
- interfaceWithObject = QAIPointer(interface->parent());
- int childIndex = interfaceWithObject->indexOfChild(interface.data());
- path.append(QString::fromLatin1("/%1").arg(childIndex));
- }
-
- while (!interfaceWithObject->object()) {
- QAIPointer parentInterface(interfaceWithObject->parent());
-
- Q_ASSERT(parentInterface->isValid());
- int index = parentInterface->indexOfChild(interfaceWithObject.data());
- if (index < 0) {
- qAtspiDebug() << "Object claims to have child that we cannot navigate to. FIX IT!" << parentInterface->object();
- return QLatin1String(ATSPI_DBUS_PATH_NULL);
- }
- path.prepend(QLatin1Char('/') + QString::number(index));
- interfaceWithObject = parentInterface;
- }
- quintptr uintptr = reinterpret_cast<quintptr>(interfaceWithObject->object());
- path.prepend(QLatin1String(QSPI_OBJECT_PATH_PREFIX) + QString::number(uintptr));
-
- if (!inDestructor && (!m_handledObjects.contains(uintptr) || m_handledObjects.value(uintptr) == 0))
- m_handledObjects[uintptr] = QPointer<QObject>(interfaceWithObject->object());
-
- return path;
+ QAccessible::Id id = QAccessible::uniqueId(interface);
+ Q_ASSERT((int)id < 0);
+ return QLatin1String(QSPI_OBJECT_PATH_PREFIX) + QString::number(id);
}
bool AtSpiAdaptor::inheritsQAction(QObject *object)
@@ -1598,21 +1549,21 @@ bool AtSpiAdaptor::inheritsQAction(QObject *object)
}
// Component
-static QAIPointer getWindow(QAIPointer interface)
+static QAccessibleInterface * getWindow(QAccessibleInterface * interface)
{
if (interface->role() == QAccessible::Window)
return interface;
- QAIPointer parent(interface->parent());
+ QAccessibleInterface * parent = interface->parent();
while (parent && parent->role() != QAccessible::Window)
- parent = QAIPointer(parent->parent());
+ parent = parent->parent();
return parent;
}
-static QRect getRelativeRect(const QAIPointer &interface)
+static QRect getRelativeRect(QAccessibleInterface *interface)
{
- QAIPointer window;
+ QAccessibleInterface * window;
QRect wr, cr;
cr = interface->rect();
@@ -1627,7 +1578,7 @@ static QRect getRelativeRect(const QAIPointer &interface)
return cr;
}
-bool AtSpiAdaptor::componentInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
+bool AtSpiAdaptor::componentInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
{
if (function == QLatin1String("Contains")) {
bool ret = false;
@@ -1645,11 +1596,11 @@ bool AtSpiAdaptor::componentInterface(const QAIPointer &interface, const QString
uint coordType = message.arguments().at(2).toUInt();
Q_UNUSED (coordType) // FIXME
- QAIPointer childInterface(interface->childAt(x, y));
- QAIPointer iface;
+ QAccessibleInterface * childInterface(interface->childAt(x, y));
+ QAccessibleInterface * iface = 0;
while (childInterface) {
iface = childInterface;
- childInterface = QAIPointer(iface->childAt(x, y));
+ childInterface = iface->childAt(x, y);
}
if (iface) {
QString path = pathForInterface(iface);
@@ -1717,13 +1668,13 @@ bool AtSpiAdaptor::componentInterface(const QAIPointer &interface, const QString
return true;
}
-QRect AtSpiAdaptor::getExtents(const QAIPointer &interface, uint coordType)
+QRect AtSpiAdaptor::getExtents(QAccessibleInterface *interface, uint coordType)
{
return (coordType == ATSPI_COORD_TYPE_SCREEN) ? interface->rect() : getRelativeRect(interface);
}
// Action interface
-bool AtSpiAdaptor::actionInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
+bool AtSpiAdaptor::actionInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
{
QAccessibleActionInterface *actionIface = interface->actionInterface();
if (!actionIface)
@@ -1793,7 +1744,7 @@ QSpiActionArray AtSpiAdaptor::getActions(QAccessibleActionInterface *actionInter
}
// Text interface
-bool AtSpiAdaptor::textInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
+bool AtSpiAdaptor::textInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
{
if (!interface->textInterface())
return false;
@@ -1840,7 +1791,7 @@ bool AtSpiAdaptor::textInterface(const QAIPointer &interface, const QString &fun
int offset = message.arguments().at(0).toInt();
int start;
int end;
- QString result = interface->textInterface()->textAtOffset(offset, QAccessible2::CharBoundary, &start, &end);
+ QString result = interface->textInterface()->textAtOffset(offset, QAccessible::CharBoundary, &start, &end);
sendReply(connection, message, (int) *(qPrintable (result)));
} else if (function == QLatin1String("GetCharacterExtents")) {
int offset = message.arguments().at(0).toInt();
@@ -1928,27 +1879,27 @@ bool AtSpiAdaptor::textInterface(const QAIPointer &interface, const QString &fun
return true;
}
-QAccessible2::BoundaryType AtSpiAdaptor::qAccessibleBoundaryType(int atspiTextBoundaryType) const
+QAccessible::TextBoundaryType AtSpiAdaptor::qAccessibleBoundaryType(int atspiTextBoundaryType) const
{
switch (atspiTextBoundaryType) {
case ATSPI_TEXT_BOUNDARY_CHAR:
- return QAccessible2::CharBoundary;
+ return QAccessible::CharBoundary;
case ATSPI_TEXT_BOUNDARY_WORD_START:
case ATSPI_TEXT_BOUNDARY_WORD_END:
- return QAccessible2::WordBoundary;
+ return QAccessible::WordBoundary;
case ATSPI_TEXT_BOUNDARY_SENTENCE_START:
case ATSPI_TEXT_BOUNDARY_SENTENCE_END:
- return QAccessible2::SentenceBoundary;
+ return QAccessible::SentenceBoundary;
case ATSPI_TEXT_BOUNDARY_LINE_START:
case ATSPI_TEXT_BOUNDARY_LINE_END:
- return QAccessible2::LineBoundary;
+ return QAccessible::LineBoundary;
}
Q_ASSERT_X(0, "", "Requested invalid boundary type.");
- return QAccessible2::CharBoundary;
+ return QAccessible::CharBoundary;
}
// FIXME all attribute methods below should share code
-QVariantList AtSpiAdaptor::getAttributes(const QAIPointer &interface, int offset, bool includeDefaults) const
+QVariantList AtSpiAdaptor::getAttributes(QAccessibleInterface *interface, int offset, bool includeDefaults) const
{
Q_UNUSED(includeDefaults);
@@ -1970,7 +1921,7 @@ QVariantList AtSpiAdaptor::getAttributes(const QAIPointer &interface, int offset
return list;
}
-QVariantList AtSpiAdaptor::getAttributeValue(const QAIPointer &interface, int offset, const QString &attributeName) const
+QVariantList AtSpiAdaptor::getAttributeValue(QAccessibleInterface *interface, int offset, const QString &attributeName) const
{
QString mapped;
QString joined;
@@ -1994,7 +1945,7 @@ QVariantList AtSpiAdaptor::getAttributeValue(const QAIPointer &interface, int of
return list;
}
-QRect AtSpiAdaptor::getCharacterExtents(const QAIPointer &interface, int offset, uint coordType) const
+QRect AtSpiAdaptor::getCharacterExtents(QAccessibleInterface *interface, int offset, uint coordType) const
{
QRect rect = interface->textInterface()->characterRect(offset);
@@ -2004,7 +1955,7 @@ QRect AtSpiAdaptor::getCharacterExtents(const QAIPointer &interface, int offset,
return rect;
}
-QRect AtSpiAdaptor::getRangeExtents(const QAIPointer &interface,
+QRect AtSpiAdaptor::getRangeExtents(QAccessibleInterface *interface,
int startOffset, int endOffset, uint coordType) const
{
if (endOffset == -1)
@@ -2025,9 +1976,9 @@ QRect AtSpiAdaptor::getRangeExtents(const QAIPointer &interface,
return rect;
}
-QRect AtSpiAdaptor::translateRectToWindowCoordinates(const QAIPointer &interface, const QRect &rect)
+QRect AtSpiAdaptor::translateRectToWindowCoordinates(QAccessibleInterface *interface, const QRect &rect)
{
- QAIPointer window = getWindow(interface);
+ QAccessibleInterface * window = getWindow(interface);
if (window)
return rect.translated(-window->rect().x(), -window->rect().y());
@@ -2061,13 +2012,13 @@ static void replaceTextFallback(QAccessibleInterface *accessible, long startOffs
accessible->setText(QAccessible::Value, t);
}
-bool AtSpiAdaptor::editableTextInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
+bool AtSpiAdaptor::editableTextInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
{
if (function == QLatin1String("CopyText")) {
#ifndef QT_NO_CLIPBOARD
int startOffset = message.arguments().at(0).toInt();
int endOffset = message.arguments().at(1).toInt();
- const QString t = textForRange(interface.data(), startOffset, endOffset);
+ const QString t = textForRange(interface, startOffset, endOffset);
QGuiApplication::clipboard()->setText(t);
#endif
connection.send(message.createReply(true));
@@ -2075,11 +2026,11 @@ bool AtSpiAdaptor::editableTextInterface(const QAIPointer &interface, const QStr
#ifndef QT_NO_CLIPBOARD
int startOffset = message.arguments().at(0).toInt();
int endOffset = message.arguments().at(1).toInt();
- const QString t = textForRange(interface.data(), startOffset, endOffset);
+ const QString t = textForRange(interface, startOffset, endOffset);
if (QAccessibleEditableTextInterface *editableTextIface = interface->editableTextInterface())
editableTextIface->deleteText(startOffset, endOffset);
else
- replaceTextFallback(interface.data(), startOffset, endOffset, QString());
+ replaceTextFallback(interface, startOffset, endOffset, QString());
QGuiApplication::clipboard()->setText(t);
#endif
connection.send(message.createReply(true));
@@ -2089,7 +2040,7 @@ bool AtSpiAdaptor::editableTextInterface(const QAIPointer &interface, const QStr
if (QAccessibleEditableTextInterface *editableTextIface = interface->editableTextInterface())
editableTextIface->deleteText(startOffset, endOffset);
else
- replaceTextFallback(interface.data(), startOffset, endOffset, QString());
+ replaceTextFallback(interface, startOffset, endOffset, QString());
connection.send(message.createReply(true));
} else if (function == QLatin1String("InsertText")) {
int position = message.arguments().at(0).toInt();
@@ -2099,7 +2050,7 @@ bool AtSpiAdaptor::editableTextInterface(const QAIPointer &interface, const QStr
if (QAccessibleEditableTextInterface *editableTextIface = interface->editableTextInterface())
editableTextIface->insertText(position, text);
else
- replaceTextFallback(interface.data(), position, position, text);
+ replaceTextFallback(interface, position, position, text);
connection.send(message.createReply(true));
} else if (function == QLatin1String("PasteText")) {
#ifndef QT_NO_CLIPBOARD
@@ -2108,7 +2059,7 @@ bool AtSpiAdaptor::editableTextInterface(const QAIPointer &interface, const QStr
if (QAccessibleEditableTextInterface *editableTextIface = interface->editableTextInterface())
editableTextIface->insertText(position, txt);
else
- replaceTextFallback(interface.data(), position, position, txt);
+ replaceTextFallback(interface, position, position, txt);
#endif
connection.send(message.createReply(true));
} else if (function == QLatin1String("SetTextContents")) {
@@ -2125,7 +2076,7 @@ bool AtSpiAdaptor::editableTextInterface(const QAIPointer &interface, const QStr
}
// Value interface
-bool AtSpiAdaptor::valueInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
+bool AtSpiAdaptor::valueInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
{
if (function == QLatin1String("SetCurrentValue")) {
QDBusVariant v = message.arguments().at(2).value<QDBusVariant>();
@@ -2161,7 +2112,7 @@ bool AtSpiAdaptor::valueInterface(const QAIPointer &interface, const QString &fu
}
// Table interface
-bool AtSpiAdaptor::tableInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
+bool AtSpiAdaptor::tableInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection)
{
if (!(interface->tableInterface() || interface->tableCellInterface())) {
qAtspiDebug() << "WARNING Qt AtSpiAdaptor: Could not find table interface for: " << message.path() << interface;
@@ -2171,7 +2122,7 @@ bool AtSpiAdaptor::tableInterface(const QAIPointer &interface, const QString &fu
if (0) {
// properties
} else if (function == QLatin1String("GetCaption")) {
- QAIPointer captionInterface= QAIPointer(interface->tableInterface()->caption());
+ QAccessibleInterface * captionInterface= interface->tableInterface()->caption();
if (captionInterface) {
QSpiObjectReference ref = QSpiObjectReference(connection, QDBusObjectPath(pathForInterface(captionInterface)));
sendReply(connection, message, QVariant::fromValue(ref));
@@ -2192,7 +2143,7 @@ bool AtSpiAdaptor::tableInterface(const QAIPointer &interface, const QString &fu
connection.send(message.createReply(QVariant::fromValue(QDBusVariant(
QVariant::fromValue(interface->tableInterface()->selectedRowCount())))));
} else if (function == QLatin1String("GetSummary")) {
- QAIPointer summary = interface->tableInterface() ? QAIPointer(interface->tableInterface()->summary()) : QAIPointer(0);
+ QAccessibleInterface * summary = interface->tableInterface() ? interface->tableInterface()->summary() : 0;
QSpiObjectReference ref(connection, QDBusObjectPath(pathForInterface(summary)));
connection.send(message.createReply(QVariant::fromValue(QDBusVariant(QVariant::fromValue(ref)))));
} else if (function == QLatin1String("GetAccessibleAt")) {
@@ -2207,7 +2158,7 @@ bool AtSpiAdaptor::tableInterface(const QAIPointer &interface, const QString &fu
}
QSpiObjectReference ref;
- QAIPointer cell(interface->tableInterface()->cellAt(row, column));
+ QAccessibleInterface * cell(interface->tableInterface()->cellAt(row, column));
if (cell) {
ref = QSpiObjectReference(connection, QDBusObjectPath(pathForInterface(cell)));
} else {
@@ -2227,13 +2178,12 @@ bool AtSpiAdaptor::tableInterface(const QAIPointer &interface, const QString &fu
int index = interface->indexOfChild(cell);
qAtspiDebug() << "QSpiAdaptor::GetIndexAt row:" << row << " col:" << column << " logical index:" << index;
Q_ASSERT(index > 0);
- delete cell;
connection.send(message.createReply(index));
} else if ((function == QLatin1String("GetColumnAtIndex")) || (function == QLatin1String("GetRowAtIndex"))) {
int index = message.arguments().at(0).toInt();
int ret = -1;
if (index >= 0) {
- QAIPointer cell = QAIPointer(interface->child(index));
+ QAccessibleInterface * cell = interface->child(index);
if (cell) {
if (function == QLatin1String("GetColumnAtIndex")) {
if (cell->role() == QAccessible::ColumnHeader) {
@@ -2290,7 +2240,6 @@ bool AtSpiAdaptor::tableInterface(const QAIPointer &interface, const QString &fu
if (cell) {
cell->rowColumnExtents(&row, &col, &rowExtents, &colExtents, &isSelected);
success = true;
- delete cell;
}
QVariantList list;
@@ -2311,12 +2260,11 @@ bool AtSpiAdaptor::tableInterface(const QAIPointer &interface, const QString &fu
int column = message.arguments().at(0).toInt();
QSpiObjectReference ref;
- QAIPointer cell(interface->tableInterface()->cellAt(0, column));
+ QAccessibleInterface * cell(interface->tableInterface()->cellAt(0, column));
if (cell && cell->tableCellInterface()) {
QList<QAccessibleInterface*> header = cell->tableCellInterface()->columnHeaderCells();
if (header.size() > 0) {
- ref = QSpiObjectReference(connection, QDBusObjectPath(pathForInterface(QAIPointer(header.takeAt(0)))));
- qDeleteAll(header);
+ ref = QSpiObjectReference(connection, QDBusObjectPath(pathForInterface(header.takeAt(0))));
}
}
connection.send(message.createReply(QVariant::fromValue(ref)));
@@ -2327,10 +2275,8 @@ bool AtSpiAdaptor::tableInterface(const QAIPointer &interface, const QString &fu
QAccessibleTableCellInterface *cell = interface->tableInterface()->cellAt(row, 0)->tableCellInterface();
if (cell) {
QList<QAccessibleInterface*> header = cell->rowHeaderCells();
- delete cell;
if (header.size() > 0) {
- ref = QSpiObjectReference(connection, QDBusObjectPath(pathForInterface(QAIPointer(header.takeAt(0)))));
- qDeleteAll(header);
+ ref = QSpiObjectReference(connection, QDBusObjectPath(pathForInterface(header.takeAt(0))));
}
}
connection.send(message.createReply(QVariant::fromValue(ref)));
@@ -2350,7 +2296,6 @@ bool AtSpiAdaptor::tableInterface(const QAIPointer &interface, const QString &fu
int column = message.arguments().at(1).toInt();
QAccessibleTableCellInterface* cell = interface->tableInterface()->cellAt(row, column)->tableCellInterface();
connection.send(message.createReply(cell->isSelected()));
- delete cell;
} else if (function == QLatin1String("AddColumnSelection")) {
int column = message.arguments().at(0).toInt();
connection.send(message.createReply(interface->tableInterface()->selectColumn(column)));
diff --git a/src/platformsupport/linuxaccessibility/atspiadaptor_p.h b/src/platformsupport/linuxaccessibility/atspiadaptor_p.h
index b7a29fdc15..6f005c33ab 100644
--- a/src/platformsupport/linuxaccessibility/atspiadaptor_p.h
+++ b/src/platformsupport/linuxaccessibility/atspiadaptor_p.h
@@ -48,19 +48,17 @@
#include <QtCore/qsharedpointer.h>
#include <QtDBus/qdbusvirtualobject.h>
#include <QtGui/qaccessible.h>
-#include <QtGui/qaccessible2.h>
+#include <QtGui/private/qaccessible2_p.h>
#include "dbusconnection_p.h"
#include "struct_marshallers_p.h"
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
class QAccessibleInterface;
class QSpiAccessibleInterface;
class QSpiApplicationAdaptor;
-typedef QSharedPointer<QAccessibleInterface> QAIPointer;
class AtSpiAdaptor :public QDBusVirtualObject
{
@@ -91,46 +89,46 @@ private:
bool sendDBusSignal(const QString &path, const QString &interface, const QString &name, const QVariantList &arguments) const;
QVariant variantForPath(const QString &path) const;
- void sendFocusChanged(const QAIPointer &interface) const;
- void notifyAboutCreation(const QAIPointer &interface) const;
- void notifyAboutDestruction(const QAIPointer &interface) const;
+ void sendFocusChanged(QAccessibleInterface *interface) const;
+ void notifyAboutCreation(QAccessibleInterface *interface) const;
+ void notifyAboutDestruction(QAccessibleInterface *interface) const;
// handlers for the different accessible interfaces
- bool applicationInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
- bool accessibleInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
- bool componentInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
- bool actionInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
- bool textInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
- bool editableTextInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
- bool valueInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
- bool tableInterface(const QAIPointer &interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
+ bool applicationInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
+ bool accessibleInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
+ bool componentInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
+ bool actionInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
+ bool textInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
+ bool editableTextInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
+ bool valueInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
+ bool tableInterface(QAccessibleInterface *interface, const QString &function, const QDBusMessage &message, const QDBusConnection &connection);
void sendReply(const QDBusConnection &connection, const QDBusMessage &message, const QVariant &argument) const;
- QAIPointer interfaceFromPath(const QString& dbusPath) const;
- QString pathForInterface(const QAIPointer &interface, bool inDestructor = false) const;
+ QAccessibleInterface *interfaceFromPath(const QString& dbusPath) const;
+ QString pathForInterface(QAccessibleInterface *interface) const;
QString pathForObject(QObject *object) const;
- void notifyStateChange(const QAIPointer& interface, const QString& state, int value);
+ void notifyStateChange(QAccessibleInterface *interface, const QString& state, int value);
// accessible helper functions
- AtspiRole getRole(const QAIPointer &interface) const;
- QSpiRelationArray relationSet(const QAIPointer &interface, const QDBusConnection &connection) const;
- QStringList accessibleInterfaces(const QAIPointer &interface) const;
+ AtspiRole getRole(QAccessibleInterface *interface) const;
+ QSpiRelationArray relationSet(QAccessibleInterface *interface, const QDBusConnection &connection) const;
+ QStringList accessibleInterfaces(QAccessibleInterface *interface) const;
// component helper functions
- static QRect getExtents(const QAIPointer &interface, uint coordType);
- static QRect translateRectToWindowCoordinates(const QAIPointer &interface, const QRect &rect);
+ static QRect getExtents(QAccessibleInterface *interface, uint coordType);
+ static QRect translateRectToWindowCoordinates(QAccessibleInterface *interface, const QRect &rect);
// action helper functions
QSpiActionArray getActions(QAccessibleActionInterface* interface) const;
// text helper functions
- QVariantList getAttributes(const QAIPointer &, int offset, bool includeDefaults) const;
- QVariantList getAttributeValue(const QAIPointer &, int offset, const QString &attributeName) const;
- QRect getCharacterExtents(const QAIPointer &, int offset, uint coordType) const;
- QRect getRangeExtents(const QAIPointer &, int startOffset, int endOffset, uint coordType) const;
- QAccessible2::BoundaryType qAccessibleBoundaryType(int atspiTextBoundaryType) const;
+ QVariantList getAttributes(QAccessibleInterface *, int offset, bool includeDefaults) const;
+ QVariantList getAttributeValue(QAccessibleInterface *, int offset, const QString &attributeName) const;
+ QRect getCharacterExtents(QAccessibleInterface *, int offset, uint coordType) const;
+ QRect getRangeExtents(QAccessibleInterface *, int startOffset, int endOffset, uint coordType) const;
+ QAccessible::TextBoundaryType qAccessibleBoundaryType(int atspiTextBoundaryType) const;
static bool inheritsQAction(QObject *object);
// private vars
@@ -141,8 +139,6 @@ private:
/// Assigned from the accessibility registry.
int m_applicationId;
- mutable QHash<quintptr, QPointer<QObject> > m_handledObjects;
-
// Bit fields - which updates to send
// AT-SPI has some events that we do not care about:
@@ -216,6 +212,5 @@ private:
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif
diff --git a/src/platformsupport/linuxaccessibility/bridge_p.h b/src/platformsupport/linuxaccessibility/bridge_p.h
index aed437b1e2..8a02847d3d 100644
--- a/src/platformsupport/linuxaccessibility/bridge_p.h
+++ b/src/platformsupport/linuxaccessibility/bridge_p.h
@@ -48,7 +48,6 @@
class DeviceEventControllerAdaptor;
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
class DBusConnection;
@@ -81,6 +80,5 @@ private:
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif
diff --git a/src/platformsupport/linuxaccessibility/cache_p.h b/src/platformsupport/linuxaccessibility/cache_p.h
index 25680cd8e8..a8128d9320 100644
--- a/src/platformsupport/linuxaccessibility/cache_p.h
+++ b/src/platformsupport/linuxaccessibility/cache_p.h
@@ -46,7 +46,6 @@
#include <QtCore/QObject>
#include "struct_marshallers_p.h"
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
class QSpiDBusCache : public QObject
@@ -67,6 +66,5 @@ public Q_SLOTS:
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif /* Q_SPI_CACHE_H */
diff --git a/src/platformsupport/linuxaccessibility/constant_mappings_p.h b/src/platformsupport/linuxaccessibility/constant_mappings_p.h
index 7410f5f94f..a0287a910b 100644
--- a/src/platformsupport/linuxaccessibility/constant_mappings_p.h
+++ b/src/platformsupport/linuxaccessibility/constant_mappings_p.h
@@ -95,7 +95,6 @@
#define QSPI_REGISTRY_NAME "org.a11y.atspi.Registry"
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
struct RoleNames {
@@ -133,6 +132,5 @@ QSpiUIntList spiStateSetFromSpiStates(quint64 states);
AtspiRelationType qAccessibleRelationToAtSpiRelation(QAccessible::Relation relation);
QT_END_NAMESPACE
-QT_END_HEADER
#endif /* Q_SPI_CONSTANT_MAPPINGS_H */
diff --git a/src/platformsupport/linuxaccessibility/dbusconnection_p.h b/src/platformsupport/linuxaccessibility/dbusconnection_p.h
index 2875dd89d8..2d55ccb547 100644
--- a/src/platformsupport/linuxaccessibility/dbusconnection_p.h
+++ b/src/platformsupport/linuxaccessibility/dbusconnection_p.h
@@ -47,7 +47,6 @@
#include <QtDBus/QDBusConnection>
#include <QtDBus/QDBusVariant>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
class QDBusServiceWatcher;
@@ -83,6 +82,5 @@ private:
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif // DBUSCONNECTION_H
diff --git a/src/platformsupport/linuxaccessibility/struct_marshallers_p.h b/src/platformsupport/linuxaccessibility/struct_marshallers_p.h
index 60d06cebb4..0b775d5521 100644
--- a/src/platformsupport/linuxaccessibility/struct_marshallers_p.h
+++ b/src/platformsupport/linuxaccessibility/struct_marshallers_p.h
@@ -49,7 +49,6 @@
#include <QtDBus/QDBusConnection>
#include <QtDBus/QDBusObjectPath>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
typedef QList <int> QSpiIntList;
@@ -173,5 +172,4 @@ Q_DECLARE_METATYPE(QSpiAttributeSet)
Q_DECLARE_METATYPE(QSpiAppUpdate)
Q_DECLARE_METATYPE(QSpiDeviceEvent)
-QT_END_HEADER
#endif /* Q_SPI_STRUCT_MARSHALLERS_H */
diff --git a/src/platformsupport/platformsupport.pro b/src/platformsupport/platformsupport.pro
index 57d9b422f4..0566e9d3ec 100644
--- a/src/platformsupport/platformsupport.pro
+++ b/src/platformsupport/platformsupport.pro
@@ -2,13 +2,14 @@ TARGET = QtPlatformSupport
QT = core-private gui-private
CONFIG += static internal_module
-mac:LIBS += -lz -framework CoreFoundation -framework Carbon
+mac:LIBS += -lz
load(qt_module)
DEFINES += QT_NO_CAST_FROM_ASCII
PRECOMPILED_HEADER = ../corelib/global/qt_pch.h
+include(cfsocketnotifier/cfsocketnotifier.pri)
include(cglconvenience/cglconvenience.pri)
include(dnd/dnd.pri)
include(eglconvenience/eglconvenience.pri)
@@ -21,3 +22,4 @@ include(devicediscovery/devicediscovery.pri)
include(services/services.pri)
include(themes/themes.pri)
include(linuxaccessibility/linuxaccessibility.pri)
+include(jniconvenience/jniconvenience.pri)
diff --git a/src/platformsupport/services/genericunix/qgenericunixservices_p.h b/src/platformsupport/services/genericunix/qgenericunixservices_p.h
index 13cf79de01..92166caf7b 100644
--- a/src/platformsupport/services/genericunix/qgenericunixservices_p.h
+++ b/src/platformsupport/services/genericunix/qgenericunixservices_p.h
@@ -45,8 +45,6 @@
#include <qpa/qplatformservices.h>
#include <QtCore/QString>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QGenericUnixServices : public QPlatformServices
@@ -66,6 +64,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGENERICUNIXDESKTOPSERVICES_H
diff --git a/src/platformsupport/themes/genericunix/qgenericunixthemes.cpp b/src/platformsupport/themes/genericunix/qgenericunixthemes.cpp
index f2babe41a4..6ea68397b6 100644
--- a/src/platformsupport/themes/genericunix/qgenericunixthemes.cpp
+++ b/src/platformsupport/themes/genericunix/qgenericunixthemes.cpp
@@ -380,7 +380,7 @@ QVariant QGnomeTheme::themeHint(QPlatformTheme::ThemeHint hint) const
return QVariant(QGenericUnixTheme::xdgIconThemePaths());
case QPlatformTheme::StyleNames: {
QStringList styleNames;
- styleNames << QStringLiteral("GTK+") << QStringLiteral("cleanlooks") << QStringLiteral("windows");
+ styleNames << QStringLiteral("GTK+") << QStringLiteral("fusion") << QStringLiteral("windows");
return QVariant(styleNames);
}
case QPlatformTheme::KeyboardScheme:
@@ -426,6 +426,9 @@ QStringList QGenericUnixTheme::themeNames()
result.push_back(QLatin1String(QKdeTheme::name));
#endif
} else { // Gnome, Unity, other Gtk-based desktops like XFCE.
+ // prefer the GTK2 theme implementation with native dialogs etc.
+ result.push_back(QStringLiteral("gtk2"));
+ // fallback to the generic Gnome theme if loading the GTK2 theme fails
result.push_back(QLatin1String(QGnomeTheme::name));
}
const QString session = QString::fromLocal8Bit(qgetenv("DESKTOP_SESSION"));
diff --git a/src/platformsupport/themes/genericunix/qgenericunixthemes_p.h b/src/platformsupport/themes/genericunix/qgenericunixthemes_p.h
index 370b703204..b0ac13efe4 100644
--- a/src/platformsupport/themes/genericunix/qgenericunixthemes_p.h
+++ b/src/platformsupport/themes/genericunix/qgenericunixthemes_p.h
@@ -47,8 +47,6 @@
#include <QtCore/QStringList>
#include <QtGui/QFont>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class ResourceHelper
@@ -132,6 +130,4 @@ QPlatformTheme *qt_createUnixTheme();
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGENERICUNIXTHEMES_H
diff --git a/src/plugins/accessible/widgets/complexwidgets.cpp b/src/plugins/accessible/widgets/complexwidgets.cpp
index b805e8c967..9dbf7d7e0f 100644
--- a/src/plugins/accessible/widgets/complexwidgets.cpp
+++ b/src/plugins/accessible/widgets/complexwidgets.cpp
@@ -96,7 +96,6 @@ public:
QAccessible::State state() const {
QAccessibleInterface *parentInterface = parent();
QAccessible::State state = parentInterface->state();
- delete parentInterface;
return state;
}
QRect rect() const {
@@ -153,6 +152,12 @@ QAccessibleTabBar::QAccessibleTabBar(QWidget *w)
Q_ASSERT(tabBar());
}
+QAccessibleTabBar::~QAccessibleTabBar()
+{
+ foreach (QAccessible::Id id, m_childInterfaces.values())
+ QAccessible::deleteAccessibleInterface(id);
+}
+
/*! Returns the QTabBar. */
QTabBar *QAccessibleTabBar::tabBar() const
{
@@ -161,9 +166,14 @@ QTabBar *QAccessibleTabBar::tabBar() const
QAccessibleInterface* QAccessibleTabBar::child(int index) const
{
+ if (QAccessible::Id id = m_childInterfaces.value(index))
+ return QAccessible::accessibleInterface(id);
+
// first the tabs, then 2 buttons
if (index < tabBar()->count()) {
QAccessibleTabButton *button = new QAccessibleTabButton(tabBar(), index);
+ QAccessible::registerAccessibleInterface(button);
+ m_childInterfaces.insert(index, QAccessible::uniqueId(button));
return button;
} else if (index >= tabBar()->count()) {
// left button
diff --git a/src/plugins/accessible/widgets/complexwidgets.h b/src/plugins/accessible/widgets/complexwidgets.h
index 1dc4d99ea8..306eae4a72 100644
--- a/src/plugins/accessible/widgets/complexwidgets.h
+++ b/src/plugins/accessible/widgets/complexwidgets.h
@@ -43,9 +43,10 @@
#define COMPLEXWIDGETS_H
#include <QtCore/qpointer.h>
-#include <QtWidgets/qaccessiblewidget.h>
+#include <QtWidgets/private/qaccessiblewidget_p.h>
#include <QtWidgets/qabstractitemview.h>
-#include <QtGui/qaccessible2.h>
+#include <QtGui/private/qaccessible2_p.h>
+
QT_BEGIN_NAMESPACE
@@ -101,6 +102,7 @@ class QAccessibleTabBar : public QAccessibleWidget
{
public:
explicit QAccessibleTabBar(QWidget *w);
+ ~QAccessibleTabBar();
int childCount() const;
QString text(QAccessible::Text t) const;
@@ -113,6 +115,7 @@ public:
protected:
QTabBar *tabBar() const;
+ mutable QHash<int, QAccessible::Id> m_childInterfaces;
};
#endif // QT_NO_TABBAR
diff --git a/src/plugins/accessible/widgets/itemviews.cpp b/src/plugins/accessible/widgets/itemviews.cpp
index a3fcc22fc4..4ddd39f7ea 100644
--- a/src/plugins/accessible/widgets/itemviews.cpp
+++ b/src/plugins/accessible/widgets/itemviews.cpp
@@ -46,8 +46,7 @@
#include <qlistview.h>
#include <qtreeview.h>
#include <private/qtreewidget_p.h>
-#include <qaccessible2.h>
-#include <QDebug>
+#include <QtGui/private/qaccessible2_p.h>
#ifndef QT_NO_ACCESSIBILITY
@@ -82,43 +81,6 @@ int QAccessibleTable::logicalIndex(const QModelIndex &index) const
return (index.row() + hHeader)*(index.model()->columnCount() + vHeader) + (index.column() + vHeader);
}
-QAccessibleInterface *QAccessibleTable::childFromLogical(int logicalIndex) const
-{
- if (!view()->model())
- return 0;
-
- int vHeader = verticalHeader() ? 1 : 0;
- int hHeader = horizontalHeader() ? 1 : 0;
-
- int columns = view()->model()->columnCount() + vHeader;
-
- int row = logicalIndex / columns;
- int column = logicalIndex % columns;
-
- if (vHeader) {
- if (column == 0) {
- if (row == 0) {
- return new QAccessibleTableCornerButton(view());
- }
- return new QAccessibleTableHeaderCell(view(), row-1, Qt::Vertical);
- }
- --column;
- }
- if (hHeader) {
- if (row == 0) {
- return new QAccessibleTableHeaderCell(view(), column, Qt::Horizontal);
- }
- --row;
- }
-
- QModelIndex index = view()->model()->index(row, column, view()->rootIndex());
- if (!index.isValid()) {
- qWarning() << "QAccessibleTable::childFromLogical: Invalid index at: " << row << column;
- return 0;
- }
- return new QAccessibleTableCell(view(), index, cellRole());
-}
-
QAccessibleTable::QAccessibleTable(QWidget *w)
: QAccessibleObject(w)
{
@@ -136,8 +98,15 @@ QAccessibleTable::QAccessibleTable(QWidget *w)
}
}
+bool QAccessibleTable::isValid() const
+{
+ return (view() && !qobject_cast<QWidget*>(view())->d_func()->data.in_destructor);
+}
+
QAccessibleTable::~QAccessibleTable()
{
+ Q_FOREACH (QAccessible::Id id, childToId.values())
+ QAccessible::deleteAccessibleInterface(id);
}
QHeaderView *QAccessibleTable::horizontalHeader() const
@@ -168,13 +137,6 @@ QHeaderView *QAccessibleTable::verticalHeader() const
return header;
}
-QAccessibleTableCell *QAccessibleTable::cell(const QModelIndex &index) const
-{
- if (index.isValid())
- return new QAccessibleTableCell(view(), index, cellRole());
- return 0;
-}
-
QAccessibleInterface *QAccessibleTable::cellAt(int row, int column) const
{
if (!view()->model())
@@ -185,7 +147,7 @@ QAccessibleInterface *QAccessibleTable::cellAt(int row, int column) const
qWarning() << "QAccessibleTable::cellAt: invalid index: " << index << " for " << view();
return 0;
}
- return cell(index);
+ return child(logicalIndex(index));
}
QAccessibleInterface *QAccessibleTable::caption() const
@@ -247,9 +209,8 @@ QList<QAccessibleInterface *> QAccessibleTable::selectedCells() const
QList<QAccessibleInterface*> cells;
if (!view()->selectionModel())
return cells;
- Q_FOREACH (const QModelIndex &index, view()->selectionModel()->selectedIndexes()) {
- cells.append(cell(index));
- }
+ Q_FOREACH (const QModelIndex &index, view()->selectionModel()->selectedIndexes())
+ cells.append(child(logicalIndex(index)));
return cells;
}
@@ -299,9 +260,28 @@ bool QAccessibleTable::selectRow(int row)
if (!view()->model() || !view()->selectionModel())
return false;
QModelIndex index = view()->model()->index(row, 0, view()->rootIndex());
- if (!index.isValid() || view()->selectionMode() & QAbstractItemView::NoSelection)
+
+ if (!index.isValid() || view()->selectionBehavior() == QAbstractItemView::SelectColumns)
return false;
- view()->selectionModel()->select(index, QItemSelectionModel::Select);
+
+ switch (view()->selectionMode()) {
+ case QAbstractItemView::NoSelection:
+ return false;
+ case QAbstractItemView::SingleSelection:
+ if (view()->selectionBehavior() != QAbstractItemView::SelectRows && columnCount() > 1 )
+ return false;
+ view()->clearSelection();
+ break;
+ case QAbstractItemView::ContiguousSelection:
+ if ((!row || !view()->selectionModel()->isRowSelected(row - 1, view()->rootIndex()))
+ && !view()->selectionModel()->isRowSelected(row + 1, view()->rootIndex()))
+ view()->clearSelection();
+ break;
+ default:
+ break;
+ }
+
+ view()->selectionModel()->select(index, QItemSelectionModel::Select | QItemSelectionModel::Rows);
return true;
}
@@ -310,9 +290,26 @@ bool QAccessibleTable::selectColumn(int column)
if (!view()->model() || !view()->selectionModel())
return false;
QModelIndex index = view()->model()->index(0, column, view()->rootIndex());
- if (!index.isValid() || view()->selectionMode() & QAbstractItemView::NoSelection)
+
+ if (!index.isValid() || view()->selectionBehavior() == QAbstractItemView::SelectRows)
+ return false;
+
+ switch (view()->selectionMode()) {
+ case QAbstractItemView::NoSelection:
return false;
- view()->selectionModel()->select(index, QItemSelectionModel::Select);
+ case QAbstractItemView::SingleSelection:
+ if (view()->selectionBehavior() != QAbstractItemView::SelectColumns && rowCount() > 1)
+ return false;
+ case QAbstractItemView::ContiguousSelection:
+ if ((!column || !view()->selectionModel()->isColumnSelected(column - 1, view()->rootIndex()))
+ && !view()->selectionModel()->isColumnSelected(column + 1, view()->rootIndex()))
+ view()->clearSelection();
+ break;
+ default:
+ break;
+ }
+
+ view()->selectionModel()->select(index, QItemSelectionModel::Select | QItemSelectionModel::Columns);
return true;
}
@@ -320,10 +317,35 @@ bool QAccessibleTable::unselectRow(int row)
{
if (!view()->model() || !view()->selectionModel())
return false;
+
QModelIndex index = view()->model()->index(row, 0, view()->rootIndex());
- if (!index.isValid() || view()->selectionMode() & QAbstractItemView::NoSelection)
+ if (!index.isValid())
return false;
- view()->selectionModel()->select(index, QItemSelectionModel::Deselect);
+
+ QItemSelection selection(index, index);
+
+ switch (view()->selectionMode()) {
+ case QAbstractItemView::SingleSelection:
+ //In SingleSelection and ContiguousSelection once an item
+ //is selected, there's no way for the user to unselect all items
+ if (selectedRowCount() == 1)
+ return false;
+ break;
+ case QAbstractItemView::ContiguousSelection:
+ if (selectedRowCount() == 1)
+ return false;
+
+ if ((!row || view()->selectionModel()->isRowSelected(row - 1, view()->rootIndex()))
+ && view()->selectionModel()->isRowSelected(row + 1, view()->rootIndex())) {
+ //If there are rows selected both up the current row and down the current rown,
+ //the ones which are down the current row will be deselected
+ selection = QItemSelection(index, view()->model()->index(rowCount() - 1, 0, view()->rootIndex()));
+ }
+ default:
+ break;
+ }
+
+ view()->selectionModel()->select(selection, QItemSelectionModel::Deselect | QItemSelectionModel::Rows);
return true;
}
@@ -331,10 +353,35 @@ bool QAccessibleTable::unselectColumn(int column)
{
if (!view()->model() || !view()->selectionModel())
return false;
+
QModelIndex index = view()->model()->index(0, column, view()->rootIndex());
- if (!index.isValid() || view()->selectionMode() & QAbstractItemView::NoSelection)
+ if (!index.isValid())
return false;
- view()->selectionModel()->select(index, QItemSelectionModel::Columns & QItemSelectionModel::Deselect);
+
+ QItemSelection selection(index, index);
+
+ switch (view()->selectionMode()) {
+ case QAbstractItemView::SingleSelection:
+ //In SingleSelection and ContiguousSelection once an item
+ //is selected, there's no way for the user to unselect all items
+ if (selectedColumnCount() == 1)
+ return false;
+ break;
+ case QAbstractItemView::ContiguousSelection:
+ if (selectedColumnCount() == 1)
+ return false;
+
+ if ((!column || view()->selectionModel()->isColumnSelected(column - 1, view()->rootIndex()))
+ && view()->selectionModel()->isColumnSelected(column + 1, view()->rootIndex())) {
+ //If there are columns selected both at the left of the current row and at the right
+ //of the current rown, the ones which are at the right will be deselected
+ selection = QItemSelection(index, view()->model()->index(0, columnCount() - 1, view()->rootIndex()));
+ }
+ default:
+ break;
+ }
+
+ view()->selectionModel()->select(selection, QItemSelectionModel::Deselect | QItemSelectionModel::Columns);
return true;
}
@@ -356,7 +403,7 @@ QAccessibleInterface *QAccessibleTable::childAt(int x, int y) const
QModelIndex index = view()->indexAt(indexPosition);
if (index.isValid()) {
- return childFromLogical(logicalIndex(index));
+ return child(logicalIndex(index));
}
return 0;
}
@@ -374,7 +421,7 @@ int QAccessibleTable::indexOfChild(const QAccessibleInterface *iface) const
{
if (!view()->model())
return -1;
- QSharedPointer<QAccessibleInterface> parent(iface->parent());
+ QAccessibleInterface *parent = iface->parent();
if (parent->object() != view())
return -1;
@@ -387,7 +434,7 @@ int QAccessibleTable::indexOfChild(const QAccessibleInterface *iface) const
return cell->index + (verticalHeader() ? 1 : 0);
} else if (iface->role() == QAccessible::RowHeader){
const QAccessibleTableHeaderCell* cell = static_cast<const QAccessibleTableHeaderCell*>(iface);
- return (cell->index + 1) * (view()->model()->rowCount() + 1);
+ return (cell->index + 1) * (view()->model()->columnCount() + 1);
} else if (iface->role() == QAccessible::Pane) {
return 0; // corner button
} else {
@@ -415,7 +462,7 @@ QRect QAccessibleTable::rect() const
QAccessibleInterface *QAccessibleTable::parent() const
{
- if (view()->parent()) {
+ if (view() && view()->parent()) {
if (qstrcmp("QComboBoxPrivateContainer", view()->parent()->metaObject()->className()) == 0) {
return QAccessible::queryAccessibleInterface(view()->parent()->parent());
}
@@ -424,9 +471,55 @@ QAccessibleInterface *QAccessibleTable::parent() const
return 0;
}
-QAccessibleInterface *QAccessibleTable::child(int index) const
+QAccessibleInterface *QAccessibleTable::child(int logicalIndex) const
{
- return childFromLogical(index);
+ if (!view()->model())
+ return 0;
+
+ if (childToId.contains(logicalIndex)) {
+ QAccessible::Id id = childToId.value(logicalIndex);
+ return QAccessible::accessibleInterface(id);
+ }
+
+ int vHeader = verticalHeader() ? 1 : 0;
+ int hHeader = horizontalHeader() ? 1 : 0;
+
+ int columns = view()->model()->columnCount() + vHeader;
+
+ int row = logicalIndex / columns;
+ int column = logicalIndex % columns;
+
+ QAccessibleInterface *iface = 0;
+
+ if (vHeader) {
+ if (column == 0) {
+ if (hHeader && row == 0) {
+ iface = new QAccessibleTableCornerButton(view());
+ } else {
+ iface = new QAccessibleTableHeaderCell(view(), row - hHeader, Qt::Vertical);
+ }
+ }
+ --column;
+ }
+ if (!iface && hHeader) {
+ if (row == 0) {
+ iface = new QAccessibleTableHeaderCell(view(), column, Qt::Horizontal);
+ }
+ --row;
+ }
+
+ if (!iface) {
+ QModelIndex index = view()->model()->index(row, column, view()->rootIndex());
+ if (!index.isValid()) {
+ qWarning() << "QAccessibleTable::child: Invalid index at: " << row << column;
+ return 0;
+ }
+ iface = new QAccessibleTableCell(view(), index, cellRole());
+ }
+
+ QAccessible::registerAccessibleInterface(iface);
+ childToId.insert(logicalIndex, QAccessible::uniqueId(iface));
+ return iface;
}
void *QAccessibleTable::interface_cast(QAccessible::InterfaceType t)
@@ -436,6 +529,140 @@ void *QAccessibleTable::interface_cast(QAccessible::InterfaceType t)
return 0;
}
+void QAccessibleTable::modelChange(QAccessibleTableModelChangeEvent *event)
+{
+ // if there is no cache yet, we don't update anything
+ if (childToId.isEmpty())
+ return;
+
+ switch (event->modelChangeType()) {
+ case QAccessibleTableModelChangeEvent::ModelReset:
+ Q_FOREACH (QAccessible::Id id, childToId.values())
+ QAccessible::deleteAccessibleInterface(id);
+ childToId.clear();
+ break;
+
+ // rows are inserted: move every row after that
+ case QAccessibleTableModelChangeEvent::RowsInserted:
+ case QAccessibleTableModelChangeEvent::ColumnsInserted: {
+ int newRows = event->lastRow() - event->firstRow() + 1;
+ int newColumns = event->lastColumn() - event->firstColumn() + 1;
+
+ ChildCache newCache;
+ ChildCache::ConstIterator iter = childToId.constBegin();
+
+ while (iter != childToId.constEnd()) {
+ QAccessible::Id id = iter.value();
+ QAccessibleInterface *iface = QAccessible::accessibleInterface(id);
+ Q_ASSERT(iface);
+ if (iface->role() == QAccessible::Cell || iface->role() == QAccessible::ListItem) {
+ Q_ASSERT(iface->tableCellInterface());
+ QAccessibleTableCell *cell = static_cast<QAccessibleTableCell*>(iface->tableCellInterface());
+ if (event->modelChangeType() == QAccessibleTableModelChangeEvent::RowsInserted
+ && cell->m_index.row() >= event->firstRow()) {
+ int newRow = cell->m_index.row() + newRows;
+ cell->m_index = cell->m_index.sibling(newRow, cell->m_index.column());
+ } else if (event->modelChangeType() == QAccessibleTableModelChangeEvent::ColumnsInserted
+ && cell->m_index.column() >= event->firstColumn()) {
+ int newColumn = cell->m_index.column() + newColumns;
+ cell->m_index = cell->m_index.sibling(cell->m_index.row(), newColumn);
+ }
+ } else if (event->modelChangeType() == QAccessibleTableModelChangeEvent::RowsInserted
+ && iface->role() == QAccessible::RowHeader) {
+ QAccessibleTableHeaderCell *cell = static_cast<QAccessibleTableHeaderCell*>(iface);
+ if (cell->index >= event->firstRow()) {
+ cell->index += newRows;
+ }
+ } else if (event->modelChangeType() == QAccessibleTableModelChangeEvent::ColumnsInserted
+ && iface->role() == QAccessible::ColumnHeader) {
+ QAccessibleTableHeaderCell *cell = static_cast<QAccessibleTableHeaderCell*>(iface);
+ if (cell->index >= event->firstColumn()) {
+ cell->index += newColumns;
+ }
+ }
+ if (indexOfChild(iface) >= 0) {
+ newCache.insert(indexOfChild(iface), id);
+ } else {
+ // ### This should really not happen,
+ // but it might if the view has a root index set.
+ // This needs to be fixed.
+ QAccessible::deleteAccessibleInterface(id);
+ }
+ ++iter;
+ }
+ childToId = newCache;
+ break;
+ }
+
+ case QAccessibleTableModelChangeEvent::ColumnsRemoved:
+ case QAccessibleTableModelChangeEvent::RowsRemoved: {
+ int deletedColumns = event->lastColumn() - event->firstColumn() + 1;
+ int deletedRows = event->lastRow() - event->firstRow() + 1;
+ ChildCache newCache;
+ ChildCache::ConstIterator iter = childToId.constBegin();
+ while (iter != childToId.constEnd()) {
+ QAccessible::Id id = iter.value();
+ QAccessibleInterface *iface = QAccessible::accessibleInterface(id);
+ Q_ASSERT(iface);
+ if (iface->role() == QAccessible::Cell || iface->role() == QAccessible::ListItem) {
+ Q_ASSERT(iface->tableCellInterface());
+ QAccessibleTableCell *cell = static_cast<QAccessibleTableCell*>(iface->tableCellInterface());
+ if (event->modelChangeType() == QAccessibleTableModelChangeEvent::RowsRemoved) {
+ if (cell->m_index.row() < event->firstRow()) {
+ newCache.insert(indexOfChild(cell), id);
+ } else if (cell->m_index.row() > event->lastRow()) {
+ int newRow = cell->m_index.row() - deletedRows;
+ cell->m_index = cell->m_index.sibling(newRow, cell->m_index.column());
+ newCache.insert(indexOfChild(cell), id);
+ } else {
+ QAccessible::deleteAccessibleInterface(id);
+ }
+ } else if (event->modelChangeType() == QAccessibleTableModelChangeEvent::ColumnsRemoved) {
+ if (cell->m_index.column() < event->firstColumn()) {
+ newCache.insert(indexOfChild(cell), id);
+ } else if (cell->m_index.column() > event->lastColumn()) {
+ int newColumn = cell->m_index.column() - deletedColumns;
+ cell->m_index = cell->m_index.sibling(cell->m_index.row(), newColumn);
+ newCache.insert(indexOfChild(cell), id);
+ } else {
+ QAccessible::deleteAccessibleInterface(id);
+ }
+ }
+ } else if (event->modelChangeType() == QAccessibleTableModelChangeEvent::RowsRemoved
+ && iface->role() == QAccessible::RowHeader) {
+ QAccessibleTableHeaderCell *cell = static_cast<QAccessibleTableHeaderCell*>(iface);
+ if (cell->index < event->firstRow()) {
+ newCache.insert(indexOfChild(cell), id);
+ } else if (cell->index > event->lastRow()) {
+ cell->index -= deletedRows;
+ newCache.insert(indexOfChild(cell), id);
+ } else {
+ QAccessible::deleteAccessibleInterface(id);
+ }
+ } else if (event->modelChangeType() == QAccessibleTableModelChangeEvent::ColumnsRemoved
+ && iface->role() == QAccessible::ColumnHeader) {
+ QAccessibleTableHeaderCell *cell = static_cast<QAccessibleTableHeaderCell*>(iface);
+ if (cell->index < event->firstColumn()) {
+ newCache.insert(indexOfChild(cell), id);
+ } else if (cell->index > event->lastColumn()) {
+ cell->index -= deletedColumns;
+ newCache.insert(indexOfChild(cell), id);
+ } else {
+ QAccessible::deleteAccessibleInterface(id);
+ }
+ }
+ ++iter;
+ }
+ childToId = newCache;
+ break;
+ }
+
+ case QAccessibleTableModelChangeEvent::DataChanged:
+ // nothing to do in this case
+ break;
+ }
+}
+
// TREE VIEW
QModelIndex QAccessibleTree::indexFromLogical(int row, int column) const
@@ -487,27 +714,33 @@ int QAccessibleTree::childCount() const
}
-QAccessibleInterface *QAccessibleTree::child(int index) const
+QAccessibleInterface *QAccessibleTree::child(int logicalIndex) const
{
- if (index < 0 || !view()->model() || !view()->model()->columnCount())
+ if (logicalIndex < 0 || !view()->model() || !view()->model()->columnCount())
return 0;
- int hHeader = horizontalHeader() ? 1 : 0;
- if (hHeader) {
+ QAccessibleInterface *iface = 0;
+ int index = logicalIndex;
+
+ if (horizontalHeader()) {
if (index < view()->model()->columnCount()) {
- return new QAccessibleTableHeaderCell(view(), index, Qt::Horizontal);
+ iface = new QAccessibleTableHeaderCell(view(), index, Qt::Horizontal);
} else {
index -= view()->model()->columnCount();
}
}
- int row = index / view()->model()->columnCount();
- int column = index % view()->model()->columnCount();
- QModelIndex modelIndex = indexFromLogical(row, column);
- if (modelIndex.isValid()) {
- return cell(modelIndex);
+ if (!iface) {
+ int row = index / view()->model()->columnCount();
+ int column = index % view()->model()->columnCount();
+ QModelIndex modelIndex = indexFromLogical(row, column);
+ if (!modelIndex.isValid())
+ return 0;
+ iface = new QAccessibleTableCell(view(), modelIndex, cellRole());
}
- return 0;
+ QAccessible::registerAccessibleInterface(iface);
+ // ### FIXME: get interfaces from the cache instead of re-creating them
+ return iface;
}
int QAccessibleTree::rowCount() const
@@ -521,7 +754,7 @@ int QAccessibleTree::indexOfChild(const QAccessibleInterface *iface) const
{
if (!view()->model())
return -1;
- QSharedPointer<QAccessibleInterface> parent(iface->parent());
+ QAccessibleInterface *parent = iface->parent();
if (parent->object() != view())
return -1;
@@ -533,12 +766,10 @@ int QAccessibleTree::indexOfChild(const QAccessibleInterface *iface) const
int column = cell->m_index.column();
int index = row * view()->model()->columnCount() + column;
- //qDebug() << "QAccessibleTree::indexOfChild r " << row << " c " << column << "index " << index;
Q_ASSERT(index >= treeView->model()->columnCount());
return index;
} else if (iface->role() == QAccessible::ColumnHeader){
const QAccessibleTableHeaderCell* cell = static_cast<const QAccessibleTableHeaderCell*>(iface);
- //qDebug() << "QAccessibleTree::indexOfChild header " << cell->index;
return cell->index;
} else {
qWarning() << "WARNING QAccessibleTable::indexOfChild invalid child"
@@ -555,7 +786,11 @@ QAccessibleInterface *QAccessibleTree::cellAt(int row, int column) const
qWarning() << "Requested invalid tree cell: " << row << column;
return 0;
}
- return new QAccessibleTableCell(view(), index, cellRole());
+ const QTreeView *treeView = qobject_cast<const QTreeView*>(view());
+ Q_ASSERT(treeView);
+ int logicalIndex = treeView->d_func()->accessibleTable2Index(index);
+
+ return child(logicalIndex); // FIXME ### new QAccessibleTableCell(view(), index, cellRole());
}
QString QAccessibleTree::rowDescription(int) const
@@ -576,9 +811,28 @@ bool QAccessibleTree::selectRow(int row)
if (!view()->selectionModel())
return false;
QModelIndex index = indexFromLogical(row);
- if (!index.isValid() || view()->selectionMode() & QAbstractItemView::NoSelection)
+
+ if (!index.isValid() || view()->selectionBehavior() == QAbstractItemView::SelectColumns)
return false;
- view()->selectionModel()->select(index, QItemSelectionModel::Select);
+
+ switch (view()->selectionMode()) {
+ case QAbstractItemView::NoSelection:
+ return false;
+ case QAbstractItemView::SingleSelection:
+ if ((view()->selectionBehavior() != QAbstractItemView::SelectRows) && (columnCount() > 1))
+ return false;
+ view()->clearSelection();
+ break;
+ case QAbstractItemView::ContiguousSelection:
+ if ((!row || !view()->selectionModel()->isRowSelected(row - 1, view()->rootIndex()))
+ && !view()->selectionModel()->isRowSelected(row + 1, view()->rootIndex()))
+ view()->clearSelection();
+ break;
+ default:
+ break;
+ }
+
+ view()->selectionModel()->select(index, QItemSelectionModel::Select | QItemSelectionModel::Rows);
return true;
}
@@ -595,6 +849,8 @@ void *QAccessibleTableCell::interface_cast(QAccessible::InterfaceType t)
{
if (t == QAccessible::TableCellInterface)
return static_cast<QAccessibleTableCellInterface*>(this);
+ if (t == QAccessible::ActionInterface)
+ return static_cast<QAccessibleActionInterface*>(this);
return 0;
}
@@ -605,6 +861,7 @@ QList<QAccessibleInterface*> QAccessibleTableCell::rowHeaderCells() const
{
QList<QAccessibleInterface*> headerCell;
if (verticalHeader()) {
+ // FIXME
headerCell.append(new QAccessibleTableHeaderCell(view, m_index.row(), Qt::Vertical));
}
return headerCell;
@@ -614,6 +871,7 @@ QList<QAccessibleInterface*> QAccessibleTableCell::columnHeaderCells() const
{
QList<QAccessibleInterface*> headerCell;
if (horizontalHeader()) {
+ // FIXME
headerCell.append(new QAccessibleTableHeaderCell(view, m_index.column(), Qt::Horizontal));
}
return headerCell;
@@ -668,6 +926,89 @@ bool QAccessibleTableCell::isSelected() const
return view->selectionModel()->isSelected(m_index);
}
+QStringList QAccessibleTableCell::actionNames() const
+{
+ QStringList names;
+ names << toggleAction();
+ return names;
+}
+
+void QAccessibleTableCell::doAction(const QString& actionName)
+{
+ if (actionName == toggleAction()) {
+ if (isSelected())
+ unselectCell();
+ else
+ selectCell();
+ }
+}
+
+QStringList QAccessibleTableCell::keyBindingsForAction(const QString &) const
+{
+ return QStringList();
+}
+
+
+void QAccessibleTableCell::selectCell()
+{
+ QAbstractItemView::SelectionMode selectionMode = view->selectionMode();
+ if (!m_index.isValid() || (selectionMode == QAbstractItemView::NoSelection))
+ return;
+ Q_ASSERT(table());
+ QAccessibleTableInterface *cellTable = table()->tableInterface();
+
+ switch (view->selectionBehavior()) {
+ case QAbstractItemView::SelectItems:
+ break;
+ case QAbstractItemView::SelectColumns:
+ if (cellTable)
+ cellTable->selectColumn(m_index.column());
+ return;
+ case QAbstractItemView::SelectRows:
+ if (cellTable)
+ cellTable->selectRow(m_index.row());
+ return;
+ }
+
+ if (selectionMode == QAbstractItemView::SingleSelection) {
+ view->clearSelection();
+ }
+
+ view->selectionModel()->select(m_index, QItemSelectionModel::Select);
+}
+
+void QAccessibleTableCell::unselectCell()
+{
+
+ QAbstractItemView::SelectionMode selectionMode = view->selectionMode();
+ if (!m_index.isValid() || (selectionMode & QAbstractItemView::NoSelection))
+ return;
+
+ QAccessibleTableInterface *cellTable = table()->tableInterface();
+
+ switch (view->selectionBehavior()) {
+ case QAbstractItemView::SelectItems:
+ break;
+ case QAbstractItemView::SelectColumns:
+ if (cellTable)
+ cellTable->unselectColumn(m_index.column());
+ return;
+ case QAbstractItemView::SelectRows:
+ if (cellTable)
+ cellTable->unselectRow(m_index.row());
+ return;
+ }
+
+ //If the mode is not MultiSelection or ExtendedSelection and only
+ //one cell is selected it cannot be unselected by the user
+ if ((selectionMode != QAbstractItemView::MultiSelection)
+ && (selectionMode != QAbstractItemView::ExtendedSelection)
+ && (view->selectionModel()->selectedIndexes().count() <= 1))
+ return;
+
+ view->selectionModel()->select(m_index, QItemSelectionModel::Deselect);
+}
+
void QAccessibleTableCell::rowColumnExtents(int *row, int *column, int *rowExtents, int *columnExtents, bool *selected) const
{
*row = m_index.row();
@@ -767,10 +1108,7 @@ bool QAccessibleTableCell::isValid() const
QAccessibleInterface *QAccessibleTableCell::parent() const
{
- if (m_role == QAccessible::TreeItem)
- return new QAccessibleTree(view);
-
- return new QAccessibleTable(view);
+ return QAccessible::queryAccessibleInterface(view);
}
QAccessibleInterface *QAccessibleTableCell::child(int) const
@@ -856,14 +1194,7 @@ bool QAccessibleTableHeaderCell::isValid() const
QAccessibleInterface *QAccessibleTableHeaderCell::parent() const
{
- if (false) {
-#ifndef QT_NO_TREEVIEW
- } else if (qobject_cast<const QTreeView*>(view)) {
- return new QAccessibleTree(view);
-#endif
- } else {
- return new QAccessibleTable(view);
- }
+ return QAccessible::queryAccessibleInterface(view);
}
QAccessibleInterface *QAccessibleTableHeaderCell::child(int) const
diff --git a/src/plugins/accessible/widgets/itemviews.h b/src/plugins/accessible/widgets/itemviews.h
index d58d504690..09dacde7a2 100644
--- a/src/plugins/accessible/widgets/itemviews.h
+++ b/src/plugins/accessible/widgets/itemviews.h
@@ -44,8 +44,8 @@
#include "QtCore/qpointer.h"
#include <QtGui/qaccessible.h>
-#include <QtGui/qaccessible2.h>
-#include <QtWidgets/qaccessiblewidget.h>
+#include <QtGui/private/qaccessible2_p.h>
+#include <QtWidgets/private/qaccessiblewidget_p.h>
#include <QtWidgets/qabstractitemview.h>
#include <QtWidgets/qheaderview.h>
@@ -63,8 +63,7 @@ class QAccessibleTable :public QAccessibleTableInterface, public QAccessibleObje
{
public:
explicit QAccessibleTable(QWidget *w);
-
- virtual ~QAccessibleTable();
+ bool isValid() const;
QAccessible::Role role() const;
QAccessible::State state() const;
@@ -105,9 +104,9 @@ public:
QAbstractItemView *view() const;
-protected:
- inline QAccessibleTableCell *cell(const QModelIndex &index) const;
+ void modelChange(QAccessibleTableModelChangeEvent *event);
+protected:
inline QAccessible::Role cellRole() const {
switch (m_role) {
case QAccessible::List:
@@ -124,11 +123,16 @@ protected:
QHeaderView *horizontalHeader() const;
QHeaderView *verticalHeader() const;
+
+ // maybe vector
+ typedef QHash<int, QAccessible::Id> ChildCache;
+ mutable ChildCache childToId;
+
+ virtual ~QAccessibleTable();
+
private:
// the child index for a model index
inline int logicalIndex(const QModelIndex &index) const;
- // the model index from the child index
- QAccessibleInterface *childFromLogical(int logicalIndex) const;
QAccessible::Role m_role;
};
@@ -139,7 +143,6 @@ public:
: QAccessibleTable(w)
{}
- virtual ~QAccessibleTree() {}
QAccessibleInterface *childAt(int x, int y) const;
int childCount() const;
@@ -157,9 +160,11 @@ public:
private:
QModelIndex indexFromLogical(int row, int column = 0) const;
+
+ inline int logicalIndex(const QModelIndex &index) const;
};
-class QAccessibleTableCell: public QAccessibleInterface, public QAccessibleTableCellInterface
+class QAccessibleTableCell: public QAccessibleInterface, public QAccessibleTableCellInterface, public QAccessibleActionInterface
{
public:
QAccessibleTableCell(QAbstractItemView *view, const QModelIndex &m_index, QAccessible::Role role);
@@ -192,6 +197,11 @@ public:
virtual void rowColumnExtents(int *row, int *column, int *rowExtents, int *columnExtents, bool *selected) const;
virtual QAccessibleInterface* table() const;
+ //action interface
+ virtual QStringList actionNames() const;
+ virtual void doAction(const QString &actionName);
+ virtual QStringList keyBindingsForAction(const QString &actionName) const;
+
private:
QHeaderView *verticalHeader() const;
QHeaderView *horizontalHeader() const;
@@ -199,6 +209,9 @@ private:
QModelIndex m_index;
QAccessible::Role m_role;
+ void selectCell();
+ void unselectCell();
+
friend class QAccessibleTable;
friend class QAccessibleTree;
};
@@ -227,7 +240,7 @@ public:
QAccessibleInterface *child(int index) const;
private:
- QAbstractItemView *view;
+ QPointer<QAbstractItemView> view;
int index;
Qt::Orientation orientation;
@@ -264,8 +277,9 @@ public:
QAccessibleInterface *child(int) const {
return 0;
}
+
private:
- QAbstractItemView *view;
+ QPointer<QAbstractItemView> view;
};
diff --git a/src/plugins/accessible/widgets/main.cpp b/src/plugins/accessible/widgets/main.cpp
index 9a42474910..686a90ca96 100644
--- a/src/plugins/accessible/widgets/main.cpp
+++ b/src/plugins/accessible/widgets/main.cpp
@@ -172,20 +172,11 @@ QAccessibleInterface *AccessibleFactory::create(const QString &classname, QObjec
iface = new QAccessibleMenu(widget);
#endif
#ifndef QT_NO_ITEMVIEWS
- } else if (classname == QLatin1String("QAbstractItemView")) {
- if (qobject_cast<const QTreeView*>(widget)) {
- iface = new QAccessibleTree(widget);
- } else {
- iface = new QAccessibleTable(widget);
- }
- } else if (classname == QLatin1String("QWidget")
- && widget->objectName() == QLatin1String("qt_scrollarea_viewport")
- && qobject_cast<QAbstractItemView*>(widget->parentWidget())) {
- if (qobject_cast<const QTreeView*>(widget->parentWidget())) {
- iface = new QAccessibleTree(widget->parentWidget());
- } else {
- iface = new QAccessibleTable(widget->parentWidget());
- }
+ } else if (classname == QLatin1String("QTreeView")) {
+ iface = new QAccessibleTree(widget);
+ } else if (classname == QLatin1String("QTableView") || classname == QLatin1String("QListView")) {
+ iface = new QAccessibleTable(widget);
+ // ### This should be cleaned up. We return the parent for the scrollarea to hide it.
#endif // QT_NO_ITEMVIEWS
#ifndef QT_NO_TABBAR
} else if (classname == QLatin1String("QTabBar")) {
@@ -251,7 +242,10 @@ QAccessibleInterface *AccessibleFactory::create(const QString &classname, QObjec
} else if (classname == QLatin1String("QDockWidget")) {
iface = new QAccessibleDockWidget(widget);
#endif
- } else {
+
+ } else if (classname == QLatin1String("QDesktopScreenWidget")) {
+ iface = 0;
+ } else if (classname == QLatin1String("QWidget")) {
iface = new QAccessibleWidget(widget);
}
diff --git a/src/plugins/accessible/widgets/qaccessiblemenu.cpp b/src/plugins/accessible/widgets/qaccessiblemenu.cpp
index e467ef50bd..f248e6d05e 100644
--- a/src/plugins/accessible/widgets/qaccessiblemenu.cpp
+++ b/src/plugins/accessible/widgets/qaccessiblemenu.cpp
@@ -55,6 +55,16 @@ QT_BEGIN_NAMESPACE
QString Q_GUI_EXPORT qt_accStripAmp(const QString &text);
QString Q_GUI_EXPORT qt_accHotKey(const QString &text);
+QAccessibleInterface *getOrCreateMenu(QWidget *menu, QAction *action)
+{
+ QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(action);
+ if (!iface) {
+ iface = new QAccessibleMenuItem(menu, action);
+ QAccessible::registerAccessibleInterface(iface);
+ }
+ return iface;
+}
+
QAccessibleMenu::QAccessibleMenu(QWidget *w)
: QAccessibleWidget(w)
{
@@ -76,7 +86,7 @@ QAccessibleInterface *QAccessibleMenu::childAt(int x, int y) const
QAction *act = menu()->actionAt(menu()->mapFromGlobal(QPoint(x,y)));
if(act && act->isSeparator())
act = 0;
- return act ? new QAccessibleMenuItem(menu(), act) : 0;
+ return act ? getOrCreateMenu(menu(), act) : 0;
}
QString QAccessibleMenu::text(QAccessible::Text t) const
@@ -98,7 +108,7 @@ QAccessible::Role QAccessibleMenu::role() const
QAccessibleInterface *QAccessibleMenu::child(int index) const
{
if (index < childCount())
- return new QAccessibleMenuItem(menu(), menu()->actions().at(index));
+ return getOrCreateMenu(menu(), menu()->actions().at(index));
return 0;
}
@@ -111,7 +121,7 @@ QAccessibleInterface *QAccessibleMenu::parent() const
foreach (QWidget *w, parentCandidates) {
if (qobject_cast<QMenu*>(w) || qobject_cast<QMenuBar*>(w)) {
if (w->actions().indexOf(menuAction) != -1)
- return new QAccessibleMenuItem(w, menuAction);
+ return getOrCreateMenu(w, menuAction);
}
}
}
@@ -146,8 +156,9 @@ int QAccessibleMenuBar::childCount() const
QAccessibleInterface *QAccessibleMenuBar::child(int index) const
{
- if (index < childCount())
- return new QAccessibleMenuItem(menuBar(), menuBar()->actions().at(index));
+ if (index < childCount()) {
+ return getOrCreateMenu(menuBar(), menuBar()->actions().at(index));
+ }
return 0;
}
@@ -177,7 +188,6 @@ QAccessibleInterface *QAccessibleMenuItem::childAt(int x, int y ) const
if (childInterface->rect().contains(x,y)) {
return childInterface;
}
- delete childInterface;
}
return 0;
}
@@ -207,7 +217,7 @@ QAccessibleInterface *QAccessibleMenuItem::parent() const
QAccessibleInterface *QAccessibleMenuItem::child(int index) const
{
if (index == 0 && action()->menu())
- return new QAccessibleMenu(action()->menu());
+ return QAccessible::queryAccessibleInterface(action()->menu());
return 0;
}
diff --git a/src/plugins/accessible/widgets/qaccessiblemenu.h b/src/plugins/accessible/widgets/qaccessiblemenu.h
index 0241cebab6..74d118a09e 100644
--- a/src/plugins/accessible/widgets/qaccessiblemenu.h
+++ b/src/plugins/accessible/widgets/qaccessiblemenu.h
@@ -42,7 +42,7 @@
#ifndef QACCESSIBLEMENU_H
#define QACCESSIBLEMENU_H
-#include <QtWidgets/qaccessiblewidget.h>
+#include <QtWidgets/private/qaccessiblewidget_p.h>
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/accessible/widgets/qaccessiblewidgets.cpp b/src/plugins/accessible/widgets/qaccessiblewidgets.cpp
index b5ee4a6046..f20823f25b 100644
--- a/src/plugins/accessible/widgets/qaccessiblewidgets.cpp
+++ b/src/plugins/accessible/widgets/qaccessiblewidgets.cpp
@@ -72,8 +72,6 @@
QT_BEGIN_NAMESPACE
-using namespace QAccessible2;
-
QString Q_GUI_EXPORT qt_accStripAmp(const QString &text);
QString Q_GUI_EXPORT qt_accHotKey(const QString &text);
@@ -718,7 +716,6 @@ QAccessibleInterface *QAccessibleTitleBar::childAt(int x, int y) const
if (childIface->rect().contains(x,y)) {
return childIface;
}
- delete childIface;
}
return 0;
}
@@ -998,83 +995,18 @@ QPoint QAccessibleTextWidget::scrollBarPosition() const
return QPoint(0, 0);
}
-QPair< int, int > QAccessibleTextWidget::getBoundaries(int offset, BoundaryType boundaryType) const
-{
- if (offset >= characterCount())
- return QPair<int, int>(characterCount(), characterCount());
- if (offset < 0)
- return QPair<int, int>(0, 0);
-
- QTextCursor cursor = textCursor();
- QPair<int, int> result;
-
- cursor.setPosition(offset);
- switch (boundaryType) {
- case CharBoundary:
- result.first = cursor.position();
- cursor.movePosition(QTextCursor::NextCharacter, QTextCursor::KeepAnchor);
- result.second = cursor.position();
- break;
- case WordBoundary:
- cursor.movePosition(QTextCursor::StartOfWord, QTextCursor::MoveAnchor);
- result.first = cursor.position();
- cursor.movePosition(QTextCursor::EndOfWord, QTextCursor::KeepAnchor);
- result.second = cursor.position();
- break;
- case SentenceBoundary: {
- // QCursor does not provide functionality to move to next sentence.
- // We therefore find the current block, then go through the block using
- // QTextBoundaryFinder and find the sentence the \offset represents
- cursor.movePosition(QTextCursor::StartOfBlock, QTextCursor::MoveAnchor);
- result.first = cursor.position();
- cursor.movePosition(QTextCursor::EndOfBlock, QTextCursor::KeepAnchor);
- result.second = cursor.position();
- QString blockText = cursor.selectedText();
- const int offsetWithinBlockText = offset - result.first;
- QTextBoundaryFinder sentenceFinder(QTextBoundaryFinder::Sentence, blockText);
- sentenceFinder.setPosition(offsetWithinBlockText);
- int prevBoundary = offsetWithinBlockText;
- int nextBoundary = offsetWithinBlockText;
- if (!(sentenceFinder.boundaryReasons() & QTextBoundaryFinder::StartOfItem))
- prevBoundary = sentenceFinder.toPreviousBoundary();
- nextBoundary = sentenceFinder.toNextBoundary();
- if (nextBoundary != -1)
- result.second = result.first + nextBoundary;
- if (prevBoundary != -1)
- result.first += prevBoundary;
- break; }
- case LineBoundary:
- cursor.movePosition(QTextCursor::StartOfLine, QTextCursor::MoveAnchor);
- result.first = cursor.position();
- cursor.movePosition(QTextCursor::EndOfLine, QTextCursor::KeepAnchor);
- result.second = cursor.position();
- break;
- case ParagraphBoundary:
- cursor.movePosition(QTextCursor::StartOfBlock, QTextCursor::MoveAnchor);
- result.first = cursor.position();
- cursor.movePosition(QTextCursor::EndOfBlock, QTextCursor::KeepAnchor);
- result.second = cursor.position();
- break;
- case NoBoundary:
- result.first = 0;
- result.second = characterCount();
- break;
- default:
- qWarning("QAccessibleTextWidget::getBoundaries: Unknown boundary type %d", boundaryType);
- result.first = -1;
- result.second = -1;
- }
- return result;
-}
-QString QAccessibleTextWidget::textBeforeOffset(int offset, BoundaryType boundaryType,
+QString QAccessibleTextWidget::textBeforeOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const
{
Q_ASSERT(startOffset);
Q_ASSERT(endOffset);
- QPair<int, int> boundaries = getBoundaries(offset, boundaryType);
- boundaries = getBoundaries(boundaries.first - 1, boundaryType);
+ QTextCursor cursor = textCursor();
+ cursor.setPosition(offset);
+ QPair<int, int> boundaries = QAccessible::qAccessibleTextBoundaryHelper(cursor, boundaryType);
+ cursor.setPosition(boundaries.first - 1);
+ boundaries = QAccessible::qAccessibleTextBoundaryHelper(cursor, boundaryType);
*startOffset = boundaries.first;
*endOffset = boundaries.second;
@@ -1083,14 +1015,17 @@ QString QAccessibleTextWidget::textBeforeOffset(int offset, BoundaryType boundar
}
-QString QAccessibleTextWidget::textAfterOffset(int offset, BoundaryType boundaryType,
+QString QAccessibleTextWidget::textAfterOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const
{
Q_ASSERT(startOffset);
Q_ASSERT(endOffset);
- QPair<int, int> boundaries = getBoundaries(offset, boundaryType);
- boundaries = getBoundaries(boundaries.second, boundaryType);
+ QTextCursor cursor = textCursor();
+ cursor.setPosition(offset);
+ QPair<int, int> boundaries = QAccessible::qAccessibleTextBoundaryHelper(cursor, boundaryType);
+ cursor.setPosition(boundaries.second);
+ boundaries = QAccessible::qAccessibleTextBoundaryHelper(cursor, boundaryType);
*startOffset = boundaries.first;
*endOffset = boundaries.second;
@@ -1098,13 +1033,15 @@ QString QAccessibleTextWidget::textAfterOffset(int offset, BoundaryType boundary
return text(boundaries.first, boundaries.second);
}
-QString QAccessibleTextWidget::textAtOffset(int offset, BoundaryType boundaryType,
+QString QAccessibleTextWidget::textAtOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const
{
Q_ASSERT(startOffset);
Q_ASSERT(endOffset);
- QPair<int, int> boundaries = getBoundaries(offset, boundaryType);
+ QTextCursor cursor = textCursor();
+ cursor.setPosition(offset);
+ QPair<int, int> boundaries = QAccessible::qAccessibleTextBoundaryHelper(cursor, boundaryType);
*startOffset = boundaries.first;
*endOffset = boundaries.second;
diff --git a/src/plugins/accessible/widgets/qaccessiblewidgets.h b/src/plugins/accessible/widgets/qaccessiblewidgets.h
index 683893f477..c60a1d893e 100644
--- a/src/plugins/accessible/widgets/qaccessiblewidgets.h
+++ b/src/plugins/accessible/widgets/qaccessiblewidgets.h
@@ -42,8 +42,8 @@
#ifndef QACCESSIBLEWIDGETS_H
#define QACCESSIBLEWIDGETS_H
-#include <QtGui/qaccessible2.h>
-#include <QtWidgets/qaccessiblewidget.h>
+#include <QtGui/private/qaccessible2_p.h>
+#include <QtWidgets/private/qaccessiblewidget_p.h>
#ifndef QT_NO_ACCESSIBILITY
@@ -92,11 +92,11 @@ public:
// text
QString text(int startOffset, int endOffset) const;
- QString textBeforeOffset(int offset, QAccessible2::BoundaryType boundaryType,
+ QString textBeforeOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const;
- QString textAfterOffset(int offset, QAccessible2::BoundaryType boundaryType,
+ QString textAfterOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const;
- QString textAtOffset(int offset, QAccessible2::BoundaryType boundaryType,
+ QString textAtOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const;
int characterCount() const;
@@ -115,8 +115,8 @@ public:
protected:
QTextCursor textCursorForRange(int startOffset, int endOffset) const;
- QPair<int, int> getBoundaries(int offset, QAccessible2::BoundaryType boundaryType) const;
virtual QPoint scrollBarPosition() const;
+ // return the current text cursor at the caret position including a potential selection
virtual QTextCursor textCursor() const = 0;
virtual void setTextCursor(const QTextCursor &) = 0;
virtual QTextDocument *textDocument() const = 0;
diff --git a/src/plugins/accessible/widgets/rangecontrols.h b/src/plugins/accessible/widgets/rangecontrols.h
index ef6f3fa226..a5bc11e1c8 100644
--- a/src/plugins/accessible/widgets/rangecontrols.h
+++ b/src/plugins/accessible/widgets/rangecontrols.h
@@ -42,8 +42,8 @@
#ifndef RANGECONTROLS_H
#define RANGECONTROLS_H
-#include <QtWidgets/qaccessiblewidget.h>
-#include <QtGui/qaccessible2.h>
+#include <QtWidgets/private/qaccessiblewidget_p.h>
+#include <QtGui/private/qaccessible2_p.h>
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/accessible/widgets/simplewidgets.cpp b/src/plugins/accessible/widgets/simplewidgets.cpp
index a9a43a7875..0112182a4b 100644
--- a/src/plugins/accessible/widgets/simplewidgets.cpp
+++ b/src/plugins/accessible/widgets/simplewidgets.cpp
@@ -67,7 +67,6 @@ QT_BEGIN_NAMESPACE
#ifndef QT_NO_ACCESSIBILITY
-using namespace QAccessible2;
extern QList<QWidget*> childWidgets(const QWidget *widget, bool includeTopLevel = false);
QString Q_GUI_EXPORT qt_accStripAmp(const QString &text);
@@ -724,7 +723,7 @@ QString QAccessibleLineEdit::text(int startOffset, int endOffset) const
return lineEdit()->text().mid(startOffset, endOffset - startOffset);
}
-QString QAccessibleLineEdit::textBeforeOffset(int offset, BoundaryType boundaryType,
+QString QAccessibleLineEdit::textBeforeOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const
{
if (lineEdit()->echoMode() != QLineEdit::Normal) {
@@ -734,7 +733,7 @@ QString QAccessibleLineEdit::textBeforeOffset(int offset, BoundaryType boundaryT
return QAccessibleTextInterface::textBeforeOffset(offset, boundaryType, startOffset, endOffset);
}
-QString QAccessibleLineEdit::textAfterOffset(int offset, BoundaryType boundaryType,
+QString QAccessibleLineEdit::textAfterOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const
{
if (lineEdit()->echoMode() != QLineEdit::Normal) {
@@ -744,7 +743,7 @@ QString QAccessibleLineEdit::textAfterOffset(int offset, BoundaryType boundaryTy
return QAccessibleTextInterface::textAfterOffset(offset, boundaryType, startOffset, endOffset);
}
-QString QAccessibleLineEdit::textAtOffset(int offset, BoundaryType boundaryType,
+QString QAccessibleLineEdit::textAtOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const
{
if (lineEdit()->echoMode() != QLineEdit::Normal) {
diff --git a/src/plugins/accessible/widgets/simplewidgets.h b/src/plugins/accessible/widgets/simplewidgets.h
index ae1a041dab..f1426354f1 100644
--- a/src/plugins/accessible/widgets/simplewidgets.h
+++ b/src/plugins/accessible/widgets/simplewidgets.h
@@ -43,8 +43,8 @@
#define SIMPLEWIDGETS_H
#include <QtCore/qcoreapplication.h>
-#include <QtGui/qaccessible2.h>
-#include <QtWidgets/qaccessiblewidget.h>
+#include <QtGui/private/qaccessible2_p.h>
+#include <QtWidgets/private/qaccessiblewidget_p.h>
QT_BEGIN_NAMESPACE
@@ -156,11 +156,11 @@ public:
int offsetAtPoint(const QPoint &point) const;
void selection(int selectionIndex, int *startOffset, int *endOffset) const;
QString text(int startOffset, int endOffset) const;
- QString textBeforeOffset (int offset, QAccessible2::BoundaryType boundaryType,
+ QString textBeforeOffset (int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const;
- QString textAfterOffset(int offset, QAccessible2::BoundaryType boundaryType,
+ QString textAfterOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const;
- QString textAtOffset(int offset, QAccessible2::BoundaryType boundaryType,
+ QString textAtOffset(int offset, QAccessible::TextBoundaryType boundaryType,
int *startOffset, int *endOffset) const;
void removeSelection(int selectionIndex);
void setCursorPosition(int position);
diff --git a/src/plugins/accessible/widgets/widgets.json b/src/plugins/accessible/widgets/widgets.json
index 69584b9bc8..3969fcd527 100644
--- a/src/plugins/accessible/widgets/widgets.json
+++ b/src/plugins/accessible/widgets/widgets.json
@@ -24,11 +24,12 @@
"QPlainTextEdit",
"QMenuBar",
"QMenu",
- "QHeaderView",
"QTabBar",
"QToolBar",
"QSizeGrip",
- "QAbstractItemView",
+ "QListView",
+ "QTreeView",
+ "QTableView",
"QWidget",
"QSplitter",
"QSplitterHandle",
@@ -47,5 +48,6 @@
"QScrollArea",
"QCalendarWidget",
"QDockWidget",
- "QAccessibleWidget" ]
+ "QDesktopScreenWidget"
+ ]
}
diff --git a/src/plugins/bearer/bearer.pro b/src/plugins/bearer/bearer.pro
index 0375500306..42f039b19b 100644
--- a/src/plugins/bearer/bearer.pro
+++ b/src/plugins/bearer/bearer.pro
@@ -9,7 +9,7 @@ linux*:qtHaveModule(dbus) {
win32:SUBDIRS += generic
blackberry:SUBDIRS += blackberry
win32:!wince*:SUBDIRS += nativewifi
-macx:contains(QT_CONFIG, corewlan):SUBDIRS += corewlan
-macx:SUBDIRS += generic
+mac:contains(QT_CONFIG, corewlan):SUBDIRS += corewlan
+mac:SUBDIRS += generic
isEmpty(SUBDIRS):SUBDIRS = generic
diff --git a/src/plugins/bearer/connman/qconnmanengine.cpp b/src/plugins/bearer/connman/qconnmanengine.cpp
index 2b28cdbf61..e85949afb6 100644
--- a/src/plugins/bearer/connman/qconnmanengine.cpp
+++ b/src/plugins/bearer/connman/qconnmanengine.cpp
@@ -159,7 +159,7 @@ void QConnmanEngine::connectToId(const QString &id)
QOfonoDataConnectionManagerInterface dc(modemPath,0);
foreach (const QDBusObjectPath &dcPath,dc.getPrimaryContexts()) {
if(dcPath.path().contains(servicePath.section("_",-1))) {
- QOfonoPrimaryDataContextInterface primaryContext(dcPath.path(),0);
+ QOfonoConnectionContextInterface primaryContext(dcPath.path(),0);
primaryContext.setActive(true);
}
}
@@ -183,7 +183,7 @@ void QConnmanEngine::disconnectFromId(const QString &id)
QOfonoDataConnectionManagerInterface dc(modemPath,0);
foreach (const QDBusObjectPath &dcPath,dc.getPrimaryContexts()) {
if(dcPath.path().contains(servicePath.section("_",-1))) {
- QOfonoPrimaryDataContextInterface primaryContext(dcPath.path(),0);
+ QOfonoConnectionContextInterface primaryContext(dcPath.path(),0);
primaryContext.setActive(false);
}
}
@@ -574,7 +574,7 @@ void QConnmanEngine::addServiceConfiguration(const QString &servicePath)
QNetworkConfigurationPrivatePointer ptr(cpPriv);
accessPointConfigurations.insert(ptr->id, ptr);
foundConfigurations.append(cpPriv);
- configInterfaces[cpPriv->id] = serv->getInterface();
+ configInterfaces[cpPriv->id] = serv->getInterface();
locker.unlock();
emit configurationAdded(ptr);
diff --git a/src/plugins/bearer/connman/qconnmanservice_linux.cpp b/src/plugins/bearer/connman/qconnmanservice_linux.cpp
index 56ae2b6e3c..e78a597433 100644
--- a/src/plugins/bearer/connman/qconnmanservice_linux.cpp
+++ b/src/plugins/bearer/connman/qconnmanservice_linux.cpp
@@ -405,7 +405,7 @@ QVariant QConnmanProfileInterface::getProperty(const QString &property)
QVariantMap map = getProperties();
if (map.contains(property)) {
var = map.value(property);
- }
+ }
return var;
}
@@ -493,7 +493,7 @@ QVariant QConnmanServiceInterface::getProperty(const QString &property)
QVariantMap map = getProperties();
if (map.contains(property)) {
var = map.value(property);
- }
+ }
return var;
}
diff --git a/src/plugins/bearer/connman/qconnmanservice_linux_p.h b/src/plugins/bearer/connman/qconnmanservice_linux_p.h
index d1524ca753..a437c6609c 100644
--- a/src/plugins/bearer/connman/qconnmanservice_linux_p.h
+++ b/src/plugins/bearer/connman/qconnmanservice_linux_p.h
@@ -134,7 +134,7 @@ public:
QString requestSession(const QString &bearerName);
void releaseSession();
-
+
// properties
QString getState();
QStringList getAvailableTechnologies();
diff --git a/src/plugins/bearer/connman/qofonoservice_linux.cpp b/src/plugins/bearer/connman/qofonoservice_linux.cpp
index f6fb55522e..1983276d94 100644
--- a/src/plugins/bearer/connman/qofonoservice_linux.cpp
+++ b/src/plugins/bearer/connman/qofonoservice_linux.cpp
@@ -108,7 +108,7 @@ QDBusObjectPath QOfonoManagerInterface::currentModem()
foreach (const QDBusObjectPath &modem, modems) {
QOfonoModemInterface device(modem.path());
if (device.isPowered() && device.isOnline())
- return modem;;
+ return modem;
}
return QDBusObjectPath();
}
@@ -770,7 +770,7 @@ QVariantMap QOfonoDataConnectionManagerInterface::getProperties()
return reply.value();
}
-QOfonoPrimaryDataContextInterface::QOfonoPrimaryDataContextInterface(const QString &dbusPathName, QObject *parent)
+QOfonoConnectionContextInterface::QOfonoConnectionContextInterface(const QString &dbusPathName, QObject *parent)
: QDBusAbstractInterface(QLatin1String(OFONO_SERVICE),
dbusPathName,
OFONO_DATA_CONTEXT_INTERFACE,
@@ -778,68 +778,68 @@ QOfonoPrimaryDataContextInterface::QOfonoPrimaryDataContextInterface(const QStri
{
}
-QOfonoPrimaryDataContextInterface::~QOfonoPrimaryDataContextInterface()
+QOfonoConnectionContextInterface::~QOfonoConnectionContextInterface()
{
}
-bool QOfonoPrimaryDataContextInterface::isActive()
+bool QOfonoConnectionContextInterface::isActive()
{
QVariant var = getProperty("Active");
return qdbus_cast<bool>(var);
}
-QString QOfonoPrimaryDataContextInterface::getApName()
+QString QOfonoConnectionContextInterface::getApName()
{
QVariant var = getProperty("AccessPointName");
return qdbus_cast<QString>(var);
}
-QString QOfonoPrimaryDataContextInterface::getType()
+QString QOfonoConnectionContextInterface::getType()
{
QVariant var = getProperty("Type");
return qdbus_cast<QString>(var);
}
-QString QOfonoPrimaryDataContextInterface::getName()
+QString QOfonoConnectionContextInterface::getName()
{
QVariant var = getProperty("Name");
return qdbus_cast<QString>(var);
}
-QVariantMap QOfonoPrimaryDataContextInterface::getSettings()
+QVariantMap QOfonoConnectionContextInterface::getSettings()
{
QVariant var = getProperty("Settings");
return qdbus_cast<QVariantMap>(var);
}
-QString QOfonoPrimaryDataContextInterface::getInterface()
+QString QOfonoConnectionContextInterface::getInterface()
{
QVariant var = getProperty("Interface");
return qdbus_cast<QString>(var);
}
-QString QOfonoPrimaryDataContextInterface::getAddress()
+QString QOfonoConnectionContextInterface::getAddress()
{
QVariant var = getProperty("Address");
return qdbus_cast<QString>(var);
}
-bool QOfonoPrimaryDataContextInterface::setActive(bool on)
+bool QOfonoConnectionContextInterface::setActive(bool on)
{
// this->setProperty("Active", QVariant(on));
return setProp("Active", QVariant::fromValue(on));
}
-bool QOfonoPrimaryDataContextInterface::setApn(const QString &name)
+bool QOfonoConnectionContextInterface::setApn(const QString &name)
{
return setProp("AccessPointName", QVariant::fromValue(name));
}
-void QOfonoPrimaryDataContextInterface::connectNotify(const QMetaMethod &signal)
+void QOfonoConnectionContextInterface::connectNotify(const QMetaMethod &signal)
{
Q_UNUSED(signal);
-// static const QMetaMethod propertyChangedSignal = QMetaMethod::fromSignal(&QOfonoPrimaryDataContextInterface::propertyChanged);
+// static const QMetaMethod propertyChangedSignal = QMetaMethod::fromSignal(&QOfonoConnectionContextInterface::propertyChanged);
// if (signal == propertyChangedSignal) {
// if (!connection().connect(QLatin1String(OFONO_SERVICE),
// this->path(),
@@ -850,7 +850,7 @@ void QOfonoPrimaryDataContextInterface::connectNotify(const QMetaMethod &signal)
// }
// }
-// static const QMetaMethod propertyChangedContextSignal = QMetaMethod::fromSignal(&QOfonoPrimaryDataContextInterface::propertyChangedContext);
+// static const QMetaMethod propertyChangedContextSignal = QMetaMethod::fromSignal(&QOfonoConnectionContextInterface::propertyChangedContext);
// if (signal == propertyChangedContextSignal) {
// QOfonoDBusHelper *helper;
// helper = new QOfonoDBusHelper(this);
@@ -867,16 +867,16 @@ void QOfonoPrimaryDataContextInterface::connectNotify(const QMetaMethod &signal)
// }
}
-void QOfonoPrimaryDataContextInterface::disconnectNotify(const QMetaMethod &signal)
+void QOfonoConnectionContextInterface::disconnectNotify(const QMetaMethod &signal)
{
Q_UNUSED(signal);
-// static const QMetaMethod propertyChangedSignal = QMetaMethod::fromSignal(&QOfonoPrimaryDataContextInterface::propertyChanged);
+// static const QMetaMethod propertyChangedSignal = QMetaMethod::fromSignal(&QOfonoConnectionContextInterface::propertyChanged);
// if (signal == propertyChangedSignal) {
// }
}
-QVariant QOfonoPrimaryDataContextInterface::getProperty(const QString &property)
+QVariant QOfonoConnectionContextInterface::getProperty(const QString &property)
{
QVariant var;
QVariantMap map = getProperties();
@@ -888,13 +888,13 @@ QVariant QOfonoPrimaryDataContextInterface::getProperty(const QString &property)
return var;
}
-QVariantMap QOfonoPrimaryDataContextInterface::getProperties()
+QVariantMap QOfonoConnectionContextInterface::getProperties()
{
QDBusReply<QVariantMap > reply = this->call(QLatin1String("GetProperties"));
return reply.value();
}
-bool QOfonoPrimaryDataContextInterface::setProp(const QString &property, const QVariant &var)
+bool QOfonoConnectionContextInterface::setProp(const QString &property, const QVariant &var)
{
QList<QVariant> args;
args << QVariant::fromValue(property) << QVariant::fromValue(QDBusVariant(var));
diff --git a/src/plugins/bearer/connman/qofonoservice_linux_p.h b/src/plugins/bearer/connman/qofonoservice_linux_p.h
index 00be9aa675..c73e8231a2 100644
--- a/src/plugins/bearer/connman/qofonoservice_linux_p.h
+++ b/src/plugins/bearer/connman/qofonoservice_linux_p.h
@@ -76,7 +76,7 @@
#define OFONO_NETWORK_OPERATOR_INTERFACE "org.ofono.NetworkOperator"
#define OFONO_DATA_CONNECTION_MANAGER_INTERFACE "org.ofono.DataConnectionManager"
#define OFONO_SIM_MANAGER_INTERFACE "org.ofono.SimManager"
-#define OFONO_DATA_CONTEXT_INTERFACE "org.ofono.PrimaryDataContext"
+#define OFONO_DATA_CONTEXT_INTERFACE "org.ofono.ConnectionContext"
#define OFONO_SMS_MANAGER_INTERFACE "org.ofono.SmsManager"
#define OFONO_PHONEBOOK_INTERFACE "org.ofono.Phonebook"
@@ -281,14 +281,14 @@ protected:
};
-class QOfonoPrimaryDataContextInterface : public QDBusAbstractInterface
+class QOfonoConnectionContextInterface : public QDBusAbstractInterface
{
Q_OBJECT
public:
- explicit QOfonoPrimaryDataContextInterface(const QString &dbusPathName, QObject *parent = 0);
- ~QOfonoPrimaryDataContextInterface();
+ explicit QOfonoConnectionContextInterface(const QString &dbusPathName, QObject *parent = 0);
+ ~QOfonoConnectionContextInterface();
QVariantMap getProperties();
diff --git a/src/plugins/bearer/corewlan/corewlan.pro b/src/plugins/bearer/corewlan/corewlan.pro
index db8651de6e..674af0cbbe 100644
--- a/src/plugins/bearer/corewlan/corewlan.pro
+++ b/src/plugins/bearer/corewlan/corewlan.pro
@@ -8,9 +8,7 @@ QT = core-private network-private
LIBS += -framework Foundation -framework SystemConfiguration
contains(QT_CONFIG, corewlan) {
- !contains(QMAKE_MAC_SDK, ".*MacOSX10\\.[345]\\.sdk") {
- LIBS += -framework CoreWLAN -framework Security
- }
+ LIBS += -framework CoreWLAN -framework Security
}
HEADERS += qcorewlanengine.h \
diff --git a/src/plugins/bearer/networkmanager/qnetworkmanagerservice.h b/src/plugins/bearer/networkmanager/qnetworkmanagerservice.h
index 7038dde3d9..7febe27ad2 100644
--- a/src/plugins/bearer/networkmanager/qnetworkmanagerservice.h
+++ b/src/plugins/bearer/networkmanager/qnetworkmanagerservice.h
@@ -139,26 +139,26 @@ class QNetworkManagerInterfacePrivate;
class QNetworkManagerInterface : public QObject
{
Q_OBJECT
-
+
public:
-
+
QNetworkManagerInterface(QObject *parent = 0);
~QNetworkManagerInterface();
-
+
QList <QDBusObjectPath> getDevices() const;
void activateConnection(const QString &serviceName, QDBusObjectPath connection, QDBusObjectPath device, QDBusObjectPath specificObject);
void deactivateConnection(QDBusObjectPath connectionPath) const;
-
+
QDBusObjectPath path() const;
QDBusInterface *connectionInterface() const;
-
+
bool wirelessEnabled() const;
bool wirelessHardwareEnabled() const;
QList <QDBusObjectPath> activeConnections() const;
quint32 state();
bool setConnections();
bool isValid();
-
+
Q_SIGNALS:
void deviceAdded(QDBusObjectPath);
void deviceRemoved(QDBusObjectPath);
@@ -176,9 +176,9 @@ class QNetworkManagerInterfaceAccessPointPrivate;
class QNetworkManagerInterfaceAccessPoint : public QObject
{
Q_OBJECT
-
+
public:
-
+
enum DeviceState {
Unknown = 0,
Unmanaged,
@@ -191,14 +191,14 @@ public:
Activated,
Failed
};
-
+
enum ApFlag {
ApNone = 0x0,
Privacy = 0x1
};
-
+
Q_DECLARE_FLAGS(ApFlags, ApFlag);
-
+
enum ApSecurityFlag {
ApSecurityNone = 0x0,
PairWep40 = 0x1,
@@ -212,9 +212,9 @@ public:
KeyPsk = 0x100,
Key8021x = 0x200
};
-
+
Q_DECLARE_FLAGS(ApSecurityFlags, ApSecurityFlag);
-
+
explicit QNetworkManagerInterfaceAccessPoint(const QString &dbusPathName, QObject *parent = 0);
~QNetworkManagerInterfaceAccessPoint();
@@ -231,7 +231,7 @@ public:
quint32 strength() const;
bool setConnections();
bool isValid();
-
+
Q_SIGNALS:
void propertiesChanged(QMap <QString,QVariant>);
void propertiesChanged( const QString &, QMap<QString,QVariant>);
@@ -245,23 +245,23 @@ class QNetworkManagerInterfaceDevicePrivate;
class QNetworkManagerInterfaceDevice : public QObject
{
Q_OBJECT
-
+
public:
-
+
explicit QNetworkManagerInterfaceDevice(const QString &deviceObjectPath, QObject *parent = 0);
~QNetworkManagerInterfaceDevice();
-
+
QString udi() const;
QString networkInterface() const;
QDBusInterface *connectionInterface() const;
quint32 ip4Address() const;
quint32 state() const;
quint32 deviceType() const;
-
+
QDBusObjectPath ip4config() const;
bool setConnections();
bool isValid();
-
+
Q_SIGNALS:
void stateChanged(const QString &, quint32);
@@ -274,20 +274,20 @@ class QNetworkManagerInterfaceDeviceWiredPrivate;
class QNetworkManagerInterfaceDeviceWired : public QObject
{
Q_OBJECT
-
+
public:
-
+
explicit QNetworkManagerInterfaceDeviceWired(const QString &ifaceDevicePath,
QObject *parent = 0);
~QNetworkManagerInterfaceDeviceWired();
-
+
QDBusInterface *connectionInterface() const;
QString hwAddress() const;
quint32 speed() const;
bool carrier() const;
bool setConnections();
bool isValid();
-
+
Q_SIGNALS:
void propertiesChanged( const QString &, QMap<QString,QVariant>);
private:
@@ -299,9 +299,9 @@ class QNetworkManagerInterfaceDeviceWirelessPrivate;
class QNetworkManagerInterfaceDeviceWireless : public QObject
{
Q_OBJECT
-
+
public:
-
+
enum DeviceCapability {
None = 0x0,
Wep40 = 0x1,
@@ -311,11 +311,11 @@ public:
Wpa = 0x10,
Rsn = 0x20
};
-
+
explicit QNetworkManagerInterfaceDeviceWireless(const QString &ifaceDevicePath,
QObject *parent = 0);
~QNetworkManagerInterfaceDeviceWireless();
-
+
QDBusObjectPath path() const;
QList <QDBusObjectPath> getAccessPoints();
QDBusInterface *connectionInterface() const;
@@ -327,7 +327,7 @@ public:
quint32 wirelessCapabilities() const;
bool setConnections();
bool isValid();
-
+
Q_SIGNALS:
void propertiesChanged( const QString &, QMap<QString,QVariant>);
void accessPointAdded(const QString &,QDBusObjectPath);
@@ -341,12 +341,12 @@ class QNetworkManagerSettingsPrivate;
class QNetworkManagerSettings : public QObject
{
Q_OBJECT
-
+
public:
-
+
explicit QNetworkManagerSettings(const QString &settingsService, QObject *parent = 0);
~QNetworkManagerSettings();
-
+
QDBusInterface *connectionInterface() const;
QList <QDBusObjectPath> listConnections();
bool setConnections();
@@ -362,12 +362,12 @@ class QNetworkManagerSettingsConnectionPrivate;
class QNetworkManagerSettingsConnection : public QObject
{
Q_OBJECT
-
+
public:
-
+
QNetworkManagerSettingsConnection(const QString &settingsService, const QString &connectionObjectPath, QObject *parent = 0);
~QNetworkManagerSettingsConnection();
-
+
QDBusInterface *connectionInterface() const;
QNmSettingsMap getSettings();
bool setConnections();
@@ -382,7 +382,7 @@ public:
bool isValid();
Q_SIGNALS:
-
+
void updated(const QNmSettingsMap &settings);
void removed(const QString &path);
@@ -395,18 +395,18 @@ class QNetworkManagerConnectionActivePrivate;
class QNetworkManagerConnectionActive : public QObject
{
Q_OBJECT
-
+
public:
-
+
enum ActiveConnectionState {
Unknown = 0,
Activating = 1,
Activated = 2
};
-
+
explicit QNetworkManagerConnectionActive(const QString &dbusPathName, QObject *parent = 0);
~ QNetworkManagerConnectionActive();
-
+
QDBusInterface *connectionInterface() const;
QString serviceName() const;
QDBusObjectPath connection() const;
@@ -417,7 +417,7 @@ public:
bool setConnections();
bool isValid();
-
+
Q_SIGNALS:
void propertiesChanged(QList<QDBusObjectPath>);
void propertiesChanged( const QString &, QMap<QString,QVariant>);
@@ -430,7 +430,7 @@ class QNetworkManagerIp4ConfigPrivate;
class QNetworkManagerIp4Config : public QObject
{
Q_OBJECT
-
+
public:
explicit QNetworkManagerIp4Config(const QString &dbusPathName, QObject *parent = 0);
~QNetworkManagerIp4Config();
@@ -439,7 +439,7 @@ public:
bool isValid();
private:
- QNetworkManagerIp4ConfigPrivate *d;
+ QNetworkManagerIp4ConfigPrivate *d;
};
QT_END_NAMESPACE
diff --git a/src/plugins/bearer/qnetworksession_impl.h b/src/plugins/bearer/qnetworksession_impl.h
index 12893108dc..23828c885c 100644
--- a/src/plugins/bearer/qnetworksession_impl.h
+++ b/src/plugins/bearer/qnetworksession_impl.h
@@ -77,7 +77,7 @@ public:
//called by QNetworkSession constructor and ensures
//that the state is immediately updated (w/o actually opening
- //a session). Also this function should take care of
+ //a session). Also this function should take care of
//notification hooks to discover future state changes.
void syncStateWithInterface();
diff --git a/src/plugins/generic/evdevtouch/README b/src/plugins/generic/evdevtouch/README
index fca2770106..ad406254d1 100644
--- a/src/plugins/generic/evdevtouch/README
+++ b/src/plugins/generic/evdevtouch/README
@@ -6,7 +6,7 @@ by this plugin. Use tslib or evdevmouse instead.
The protocol type will be detected automatically.
To enable libmtdev support uncomment the USE_MTDEV define in
-evdevtouch.pro.
+src/platformsupport/input/evdevtouch/evdevtouch.pri.
Tested with the following kernel drivers:
bcm5974 (type A)
diff --git a/src/plugins/generic/generic.pro b/src/plugins/generic/generic.pro
index 078db2f477..18a8295d3c 100644
--- a/src/plugins/generic/generic.pro
+++ b/src/plugins/generic/generic.pro
@@ -5,3 +5,7 @@ TEMPLATE = subdirs
contains(QT_CONFIG, evdev) {
SUBDIRS += evdevmouse evdevtouch evdevkeyboard evdevtablet
}
+
+contains(QT_CONFIG, tslib) {
+ SUBDIRS += tslib
+}
diff --git a/src/plugins/generic/meego/qmeegointegration.h b/src/plugins/generic/meego/qmeegointegration.h
index 88e2aae721..998bbbf8d3 100644
--- a/src/plugins/generic/meego/qmeegointegration.h
+++ b/src/plugins/generic/meego/qmeegointegration.h
@@ -47,8 +47,6 @@
#include "contextkitproperty.h"
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QMeeGoIntegration : public QObject
@@ -67,6 +65,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMEEGOINTEGRATION_H
diff --git a/src/plugins/generic/tslib/qtslib.h b/src/plugins/generic/tslib/qtslib.h
index 0c5c74f672..9342fdfea5 100644
--- a/src/plugins/generic/tslib/qtslib.h
+++ b/src/plugins/generic/tslib/qtslib.h
@@ -45,8 +45,6 @@
#include <qobject.h>
//#include <Qt>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QSocketNotifier;
@@ -72,6 +70,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTSLIB_H
diff --git a/src/plugins/imageformats/gif/gif.json b/src/plugins/imageformats/gif/gif.json
index b599b40ffe..1d6cb126c4 100644
--- a/src/plugins/imageformats/gif/gif.json
+++ b/src/plugins/imageformats/gif/gif.json
@@ -1,3 +1,4 @@
{
- "Keys": [ "gif" ]
+ "Keys": [ "gif" ],
+ "MimeTypes": [ "image/gif" ]
}
diff --git a/src/plugins/imageformats/ico/ico.json b/src/plugins/imageformats/ico/ico.json
index d22cb739a1..bd46e07e54 100644
--- a/src/plugins/imageformats/ico/ico.json
+++ b/src/plugins/imageformats/ico/ico.json
@@ -1,3 +1,4 @@
{
- "Keys": [ "ico" ]
+ "Keys": [ "ico" ],
+ "MimeTypes": [ "image/vnd.microsoft.icon" ]
}
diff --git a/src/plugins/imageformats/ico/qicohandler.cpp b/src/plugins/imageformats/ico/qicohandler.cpp
index b1ef823068..a45c3875bc 100644
--- a/src/plugins/imageformats/ico/qicohandler.cpp
+++ b/src/plugins/imageformats/ico/qicohandler.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-/*!
+/*!
\class QtIcoHandler
\since 4.4
\brief The QtIcoHandler class provides support for the ICO image format.
diff --git a/src/plugins/imageformats/ico/qicohandler.h b/src/plugins/imageformats/ico/qicohandler.h
index c0439b9d11..65c0f5cf59 100644
--- a/src/plugins/imageformats/ico/qicohandler.h
+++ b/src/plugins/imageformats/ico/qicohandler.h
@@ -57,13 +57,13 @@ public:
bool write(const QImage &image);
QByteArray name() const;
-
+
int imageCount() const;
bool jumpToImage(int imageNumber);
bool jumpToNextImage();
-
+
static bool canRead(QIODevice *device);
-
+
bool supportsOption(ImageOption option) const;
QVariant option(ImageOption option) const;
diff --git a/src/plugins/imageformats/jpeg/jpeg.json b/src/plugins/imageformats/jpeg/jpeg.json
index 132c642c05..5e26a97206 100644
--- a/src/plugins/imageformats/jpeg/jpeg.json
+++ b/src/plugins/imageformats/jpeg/jpeg.json
@@ -1,3 +1,4 @@
{
- "Keys": [ "jpg", "jpeg" ]
+ "Keys": [ "jpg", "jpeg" ],
+ "MimeTypes": [ "image/jpeg", "image/jpeg" ]
}
diff --git a/src/plugins/platforminputcontexts/compose/compose.json b/src/plugins/platforminputcontexts/compose/compose.json
new file mode 100644
index 0000000000..2daf89ed30
--- /dev/null
+++ b/src/plugins/platforminputcontexts/compose/compose.json
@@ -0,0 +1,3 @@
+{
+ "Keys": [ "compose" ]
+}
diff --git a/src/plugins/platforminputcontexts/compose/compose.pro b/src/plugins/platforminputcontexts/compose/compose.pro
new file mode 100644
index 0000000000..6387a47a4c
--- /dev/null
+++ b/src/plugins/platforminputcontexts/compose/compose.pro
@@ -0,0 +1,20 @@
+TARGET = composeplatforminputcontextplugin
+
+PLUGIN_TYPE = platforminputcontexts
+PLUGIN_CLASS_NAME = QComposePlatformInputContextPlugin
+load(qt_plugin)
+
+QT += gui-private
+
+LIBS += $$QMAKE_LIBS_XKBCOMMON
+QMAKE_CXXFLAGS += $$QMAKE_CFLAGS_XKBCOMMON
+
+SOURCES += $$PWD/main.cpp \
+ $$PWD/qcomposeplatforminputcontext.cpp \
+ $$PWD/generator/qtablegenerator.cpp \
+
+HEADERS += $$PWD/qcomposeplatforminputcontext.h \
+ $$PWD/generator/qtablegenerator.h \
+ $$PWD/xkbcommon_workaround.h \
+
+OTHER_FILES += $$PWD/compose.json
diff --git a/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp b/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp
new file mode 100644
index 0000000000..3c61a69480
--- /dev/null
+++ b/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.cpp
@@ -0,0 +1,401 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qtablegenerator.h"
+
+#include <QtCore/QRegularExpression>
+#include <QtCore/QByteArray>
+#include <QtCore/QTextCodec>
+#include <QtCore/QDebug>
+#include <QtCore/QStringList>
+#include <QtCore/QString>
+
+#include <xkbcommon/xkbcommon.h>
+#include <xkbcommon_workaround.h>
+
+//#define DEBUG_GENERATOR
+
+TableGenerator::TableGenerator() : m_state(NoErrors),
+ m_systemComposeDir(QString())
+{
+ initPossibleLocations();
+ findComposeFile();
+ orderComposeTable();
+#ifdef DEBUG_GENERATOR
+ printComposeTable();
+#endif
+}
+
+void TableGenerator::initPossibleLocations()
+{
+ // AFAICT there is no way to know the exact location
+ // of the compose files. It depends on how Xlib was configured
+ // on a specific platform. During the "./configure" process
+ // xlib generates a config.h file which contains a bunch of defines,
+ // including XLOCALEDIR which points to the location of the compose file dir.
+ // To add an extra system path use the QTCOMPOSE environment variable
+ if (qEnvironmentVariableIsSet("QTCOMPOSE")) {
+ m_possibleLocations.append(QString(qgetenv("QTCOMPOSE")));
+ }
+ m_possibleLocations.append(QStringLiteral("/usr/share/X11/locale"));
+ m_possibleLocations.append(QStringLiteral("/usr/lib/X11/locale"));
+}
+
+void TableGenerator::findComposeFile()
+{
+ bool found = false;
+ // check if XCOMPOSEFILE points to a Compose file
+ if (qEnvironmentVariableIsSet("XCOMPOSEFILE")) {
+ QString composeFile(qgetenv("XCOMPOSEFILE"));
+ if (composeFile.endsWith(QLatin1String("Compose")))
+ found = processFile(composeFile);
+ else
+ qWarning("Qt Warning: XCOMPOSEFILE doesn't point to a valid Compose file");
+#ifdef DEBUG_GENERATOR
+ if (found)
+ qDebug() << "Using Compose file from: " << composeFile;
+#endif
+ }
+
+ // check if user’s home directory has a file named .XCompose
+ if (!found && cleanState()) {
+ QString composeFile = qgetenv("HOME") + QStringLiteral("/.XCompose");
+ if (QFile(composeFile).exists())
+ found = processFile(composeFile);
+#ifdef DEBUG_GENERATOR
+ if (found)
+ qDebug() << "Using Compose file from: " << composeFile;
+#endif
+ }
+
+ // check for the system provided compose files
+ if (!found && cleanState()) {
+ readLocaleMappings();
+
+ if (cleanState()) {
+
+ QString table = m_localeToTable.value(locale().toUpper());
+ if (table.isEmpty())
+ // no table mappings for the system's locale in the compose.dir
+ m_state = UnsupportedLocale;
+ else
+ found = processFile(systemComposeDir() + QLatin1String("/") + table);
+#ifdef DEBUG_GENERATOR
+ if (found)
+ qDebug() << "Using Compose file from: " <<
+ systemComposeDir() + QLatin1String("/") + table;
+#endif
+ }
+ }
+
+ if (found && m_composeTable.isEmpty())
+ m_state = EmptyTable;
+
+ if (!found)
+ m_state = MissingComposeFile;
+}
+
+bool TableGenerator::findSystemComposeDir()
+{
+ bool found = false;
+ for (int i = 0; i < m_possibleLocations.size(); ++i) {
+ QString path = m_possibleLocations.at(i);
+ if (QFile(path + QLatin1String("/compose.dir")).exists()) {
+ m_systemComposeDir = path;
+ found = true;
+ break;
+ }
+ }
+
+ if (!found) {
+ // should we ask to report this in the qt bug tracker?
+ m_state = UnknownSystemComposeDir;
+ qWarning("Qt Warning: Could not find a location of the system's Compose files. "
+ "Consider setting the QTCOMPOSE environment variable.");
+ }
+
+ return found;
+}
+
+QString TableGenerator::systemComposeDir()
+{
+ if (m_systemComposeDir.isNull()
+ && !findSystemComposeDir()) {
+ return QLatin1String("$QTCOMPOSE");
+ }
+
+ return m_systemComposeDir;
+}
+
+QString TableGenerator::locale() const
+{
+ char *name = setlocale(LC_CTYPE, (char *)0);
+ return QLatin1String(name);
+}
+
+void TableGenerator::readLocaleMappings()
+{
+ QFile mappings(systemComposeDir() + QLatin1String("/compose.dir"));
+ if (mappings.exists()) {
+ mappings.open(QIODevice::ReadOnly);
+ QTextStream in(&mappings);
+ // formating of compose.dir has some inconsistencies
+ while (!in.atEnd()) {
+ QString line = in.readLine();
+ if (!line.startsWith("#") && line.size() != 0 &&
+ line.at(0).isLower()) {
+
+ QStringList pair = line.split(QRegExp(QLatin1String("\\s+")));
+ QString table = pair.at(0);
+ if (table.endsWith(QLatin1String(":")))
+ table.remove(table.size() - 1, 1);
+
+ m_localeToTable.insert(pair.at(1).toUpper(), table);
+ }
+ }
+ mappings.close();
+ }
+}
+
+bool TableGenerator::processFile(QString composeFileName)
+{
+ QFile composeFile(composeFileName);
+ if (composeFile.exists()) {
+ composeFile.open(QIODevice::ReadOnly);
+ parseComposeFile(&composeFile);
+ return true;
+ }
+ qWarning() << QString(QLatin1String("Qt Warning: Compose file: \"%1\" can't be found"))
+ .arg(composeFile.fileName());
+ return false;
+}
+
+TableGenerator::~TableGenerator()
+{
+}
+
+QList<QComposeTableElement> TableGenerator::composeTable() const
+{
+ return m_composeTable;
+}
+
+void TableGenerator::parseComposeFile(QFile *composeFile)
+{
+#ifdef DEBUG_GENERATOR
+ qDebug() << "TableGenerator::parseComposeFile: " << composeFile->fileName();
+#endif
+ QTextStream in(composeFile);
+
+ while (!in.atEnd()) {
+ QString line = in.readLine();
+ if (line.startsWith(QLatin1String("<"))) {
+ parseKeySequence(line);
+ } else if (line.startsWith(QLatin1String("include"))) {
+ parseIncludeInstruction(line);
+ }
+ }
+
+ composeFile->close();
+}
+
+void TableGenerator::parseIncludeInstruction(QString line)
+{
+ // Parse something that looks like:
+ // include "/usr/share/X11/locale/en_US.UTF-8/Compose"
+ QString quote = QStringLiteral("\"");
+ line.remove(0, line.indexOf(quote) + 1);
+ line.chop(line.length() - line.indexOf(quote));
+
+ // expand substitutions if present
+ line.replace(QLatin1String("%H"), QString(qgetenv("HOME")));
+ line.replace(QLatin1String("%L"), locale());
+ line.replace(QLatin1String("%S"), systemComposeDir());
+
+ processFile(line);
+}
+
+ushort TableGenerator::keysymToUtf8(uint32_t sym)
+{
+ QByteArray chars;
+ int bytes;
+ chars.resize(8);
+
+ if (needWorkaround(sym)) {
+ uint32_t codepoint;
+ if (sym == XKB_KEY_KP_Space)
+ codepoint = XKB_KEY_space & 0x7f;
+ else
+ codepoint = sym & 0x7f;
+
+ bytes = utf32_to_utf8(codepoint, chars.data());
+ } else {
+ bytes = xkb_keysym_to_utf8(sym, chars.data(), chars.size());
+ }
+
+ if (bytes == -1)
+ qWarning("TableGenerator::keysymToUtf8 - buffer too small");
+
+ chars.resize(bytes-1);
+
+#ifdef DEBUG_GENERATOR
+ QTextCodec *codec = QTextCodec::codecForLocale();
+ qDebug() << QString("keysym - 0x%1 : utf8 - %2").arg(QString::number(sym, 16))
+ .arg(codec->toUnicode(chars));
+#endif
+ const QChar *ch = QString(chars.data()).unicode();
+ return ch->unicode();
+}
+
+uint32_t TableGenerator::stringToKeysym(QString keysymName)
+{
+ uint32_t keysym;
+ QByteArray keysymArray = keysymName.toLatin1();
+ const char *name = keysymArray.constData();
+
+ if ((keysym = xkb_keysym_from_name(name, (xkb_keysym_flags)0)) == XKB_KEY_NoSymbol)
+ qWarning() << QString("Qt Warrning - invalid keysym: %1").arg(keysymName);
+
+ return keysym;
+}
+
+void TableGenerator::parseKeySequence(QString line)
+{
+ // we are interested in the lines with the following format:
+ // <Multi_key> <numbersign> <S> : "♬" U266c # BEAMED SIXTEENTH NOTE
+ int keysEnd = line.indexOf(QLatin1String(":"));
+ QString keys = line.left(keysEnd).trimmed();
+
+ // find the key sequence
+ QString regexp = QStringLiteral("<[^>]+>");
+ QRegularExpression reg(regexp);
+ QRegularExpressionMatchIterator i = reg.globalMatch(keys);
+ QStringList keyList;
+ while (i.hasNext()) {
+ QRegularExpressionMatch match = i.next();
+ QString word = match.captured(0);
+ keyList << word;
+ }
+
+ QComposeTableElement elem;
+ QString quote = QStringLiteral("\"");
+ // find the composed value - strings may be direct text encoded in the locale
+ // for which the compose file is to be used, or an escaped octal or hexadecimal
+ // character code. Octal codes are specified as "\123" and hexadecimal codes as "\0x123a".
+ int composeValueIndex = line.indexOf(quote, keysEnd) + 1;
+ const QChar valueType(line.at(composeValueIndex));
+
+ if (valueType == '\\' && line.at(composeValueIndex + 1).isDigit()) {
+ // handle octal and hex code values
+ QChar detectBase(line.at(composeValueIndex + 2));
+ QString codeValue = line.mid(composeValueIndex + 1, line.lastIndexOf(quote) - composeValueIndex - 1);
+ if (detectBase == 'x') {
+ // hexadecimal character code
+ elem.value = keysymToUtf8(codeValue.toUInt(0, 16));
+ } else {
+ // octal character code
+ QString hexStr = QString::number(codeValue.toUInt(0, 8), 16);
+ elem.value = keysymToUtf8(hexStr.toUInt(0, 16));
+ }
+ } else {
+ // handle direct text encoded in the locale
+ elem.value = valueType.unicode();
+ }
+
+ // find the comment
+ int commnetIndex = line.lastIndexOf(quote) + 1;
+ elem.comment = line.mid(commnetIndex).trimmed();
+
+ // Convert to X11 keysym
+ int count = keyList.length();
+ for (int i = 0; i < QT_KEYSEQUENCE_MAX_LEN; i++) {
+ if (i < count) {
+ QString keysym = keyList.at(i);
+ keysym.remove(keysym.length() - 1, 1);
+ keysym.remove(0, 1);
+
+ if (keysym == QLatin1String("dead_inverted_breve"))
+ keysym = QStringLiteral("dead_invertedbreve");
+ else if (keysym == QLatin1String("dead_double_grave"))
+ keysym = QStringLiteral("dead_doublegrave");
+
+ elem.keys[i] = stringToKeysym(keysym);
+ } else {
+ elem.keys[i] = 0;
+ }
+ }
+ m_composeTable.append(elem);
+}
+
+void TableGenerator::printComposeTable() const
+{
+ if (composeTable().isEmpty())
+ return;
+
+ QString output;
+ QComposeTableElement elem;
+ QString comma = QStringLiteral(",");
+ int tableSize = m_composeTable.size();
+ for (int i = 0; i < tableSize; ++i) {
+ elem = m_composeTable.at(i);
+ output.append(QLatin1String("{ {"));
+ for (int j = 0; j < QT_KEYSEQUENCE_MAX_LEN; j++) {
+ output.append(QString(QLatin1String("0x%1, ")).arg(QString::number(elem.keys[j],16)));
+ }
+ // take care of the trailing comma
+ if (i == tableSize - 1)
+ comma = QStringLiteral("");
+ output.append(QString(QLatin1String("}, 0x%1, \"\" }%2 // %3 \n"))
+ .arg(QString::number(elem.value,16))
+ .arg(comma)
+ .arg(elem.comment));
+ }
+
+ qDebug() << "output: \n" << output;
+}
+
+void TableGenerator::orderComposeTable()
+{
+ // Stable-sorting to ensure that the item that appeared before the other in the
+ // original container will still appear first after the sort. This property is
+ // needed to handle the cases when user re-defines already defined key sequence
+ qStableSort(m_composeTable.begin(), m_composeTable.end(), Compare());
+}
+
diff --git a/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.h b/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.h
new file mode 100644
index 0000000000..11e7b2b422
--- /dev/null
+++ b/src/plugins/platforminputcontexts/compose/generator/qtablegenerator.h
@@ -0,0 +1,128 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QTABLEGENERATOR_H
+#define QTABLEGENERATOR_H
+
+#include <QtCore/QList>
+#include <QtCore/QFile>
+#include <QtCore/QMap>
+#include <QtCore/QString>
+
+#define QT_KEYSEQUENCE_MAX_LEN 6
+
+struct QComposeTableElement {
+ uint keys[QT_KEYSEQUENCE_MAX_LEN];
+ uint value;
+ QString comment;
+};
+
+class Compare
+{
+public:
+ bool operator () (const QComposeTableElement &lhs, const uint rhs[QT_KEYSEQUENCE_MAX_LEN])
+ {
+ for (size_t i = 0; i < QT_KEYSEQUENCE_MAX_LEN; i++) {
+ if (lhs.keys[i] != rhs[i])
+ return (lhs.keys[i] < rhs[i]);
+ }
+ return false;
+ }
+
+ bool operator () (const QComposeTableElement &lhs, const QComposeTableElement &rhs)
+ {
+ for (size_t i = 0; i < QT_KEYSEQUENCE_MAX_LEN; i++) {
+ if (lhs.keys[i] != rhs.keys[i])
+ return (lhs.keys[i] < rhs.keys[i]);
+ }
+ return false;
+ }
+};
+
+class TableGenerator
+{
+
+public:
+ enum TableState
+ {
+ UnsupportedLocale,
+ EmptyTable,
+ UnknownSystemComposeDir,
+ MissingComposeFile,
+ NoErrors
+ };
+
+ TableGenerator();
+ ~TableGenerator();
+
+ void parseComposeFile(QFile *composeFile);
+ void printComposeTable() const;
+ void orderComposeTable();
+
+ QList<QComposeTableElement> composeTable() const;
+ TableState tableState() const { return m_state; }
+
+protected:
+ bool processFile(QString composeFileName);
+ void parseKeySequence(QString line);
+ void parseIncludeInstruction(QString line);
+
+ void findComposeFile();
+ bool findSystemComposeDir();
+ QString systemComposeDir();
+
+ ushort keysymToUtf8(uint32_t sym);
+ uint32_t stringToKeysym(QString keysymName);
+
+ void readLocaleMappings();
+ void initPossibleLocations();
+ bool cleanState() const { return ((m_state & NoErrors) == NoErrors); }
+ QString locale() const;
+
+private:
+ QList<QComposeTableElement> m_composeTable;
+ QMap<QString, QString> m_localeToTable;
+ TableState m_state;
+ QString m_systemComposeDir;
+ QList<QString> m_possibleLocations;
+};
+
+#endif // QTABLEGENERATOR_H
diff --git a/src/plugins/platforminputcontexts/compose/main.cpp b/src/plugins/platforminputcontexts/compose/main.cpp
new file mode 100644
index 0000000000..728c60caf5
--- /dev/null
+++ b/src/plugins/platforminputcontexts/compose/main.cpp
@@ -0,0 +1,70 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <qpa/qplatforminputcontextplugin_p.h>
+
+#include <QtCore/QStringList>
+
+#include "qcomposeplatforminputcontext.h"
+
+QT_BEGIN_NAMESPACE
+
+class QComposePlatformInputContextPlugin : public QPlatformInputContextPlugin
+{
+ Q_OBJECT
+ Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QPlatformInputContextFactoryInterface" FILE "compose.json")
+
+public:
+ QComposeInputContext *create(const QString &, const QStringList &);
+};
+
+QComposeInputContext *QComposePlatformInputContextPlugin::create(const QString &system, const QStringList &paramList)
+{
+ Q_UNUSED(paramList);
+
+ if (system.compare(system, QStringLiteral("compose"), Qt::CaseInsensitive) == 0)
+ return new QComposeInputContext;
+ return 0;
+}
+
+QT_END_NAMESPACE
+
+#include "main.moc"
diff --git a/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.cpp b/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.cpp
new file mode 100644
index 0000000000..433c9eec37
--- /dev/null
+++ b/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.cpp
@@ -0,0 +1,268 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qcomposeplatforminputcontext.h"
+
+#include <QtCore/QCoreApplication>
+#include <QtGui/QKeyEvent>
+#include <QtCore/QDebug>
+
+QT_BEGIN_NAMESPACE
+
+//#define DEBUG_COMPOSING
+
+static const int ignoreKeys[] = {
+ Qt::Key_Shift,
+ Qt::Key_Control,
+ Qt::Key_Meta,
+ Qt::Key_Alt,
+ Qt::Key_CapsLock,
+ Qt::Key_Super_L,
+ Qt::Key_Super_R,
+ Qt::Key_Hyper_L,
+ Qt::Key_Hyper_R,
+ Qt::Key_Mode_switch
+};
+
+static const int composingKeys[] = {
+ Qt::Key_Multi_key,
+ Qt::Key_Dead_Grave,
+ Qt::Key_Dead_Acute,
+ Qt::Key_Dead_Circumflex,
+ Qt::Key_Dead_Tilde,
+ Qt::Key_Dead_Macron,
+ Qt::Key_Dead_Breve,
+ Qt::Key_Dead_Abovedot,
+ Qt::Key_Dead_Diaeresis,
+ Qt::Key_Dead_Abovering,
+ Qt::Key_Dead_Doubleacute,
+ Qt::Key_Dead_Caron,
+ Qt::Key_Dead_Cedilla,
+ Qt::Key_Dead_Ogonek,
+ Qt::Key_Dead_Iota,
+ Qt::Key_Dead_Voiced_Sound,
+ Qt::Key_Dead_Semivoiced_Sound,
+ Qt::Key_Dead_Belowdot,
+ Qt::Key_Dead_Hook,
+ Qt::Key_Dead_Horn
+};
+
+QComposeInputContext::QComposeInputContext()
+{
+ TableGenerator reader;
+ m_tableState = reader.tableState();
+
+ if ((m_tableState & TableGenerator::NoErrors) == TableGenerator::NoErrors) {
+ m_composeTable = reader.composeTable();
+ clearComposeBuffer();
+ }
+}
+
+bool QComposeInputContext::filterEvent(const QEvent *event)
+{
+ // if there were errors when generating the compose table input
+ // context should not try to filter anything, simply return false
+ if ((m_tableState & TableGenerator::NoErrors) != TableGenerator::NoErrors)
+ return false;
+
+ QKeyEvent *keyEvent = (QKeyEvent *)event;
+ // should pass only the key presses
+ if (keyEvent->type() != QEvent::KeyPress) {
+ return false;
+ }
+
+ int keyval = keyEvent->key();
+ int keysym = 0;
+
+ if (ignoreKey(keyval))
+ return false;
+
+ QString text = keyEvent->text();
+ if (!composeKey(keyval) && text.isEmpty())
+ return false;
+
+ keysym = keyEvent->nativeVirtualKey();
+
+ int nCompose = 0;
+ while (m_composeBuffer[nCompose] != 0 && nCompose < QT_KEYSEQUENCE_MAX_LEN)
+ nCompose++;
+
+ if (nCompose == QT_KEYSEQUENCE_MAX_LEN) {
+ reset();
+ nCompose = 0;
+ }
+
+ m_composeBuffer[nCompose] = keysym;
+ // check sequence
+ if (checkComposeTable())
+ return true;
+
+ return false;
+}
+
+bool QComposeInputContext::isValid() const
+{
+ return true;
+}
+
+void QComposeInputContext::setFocusObject(QObject *object)
+{
+ m_focusObject = object;
+}
+
+void QComposeInputContext::reset()
+{
+ clearComposeBuffer();
+}
+
+void QComposeInputContext::update(Qt::InputMethodQueries q)
+{
+ QPlatformInputContext::update(q);
+}
+
+static bool isDuplicate(const QComposeTableElement &lhs, const QComposeTableElement &rhs)
+{
+ for (size_t i = 0; i < QT_KEYSEQUENCE_MAX_LEN; i++) {
+ if (lhs.keys[i] != rhs.keys[i])
+ return false;
+ }
+ return true;
+}
+
+bool QComposeInputContext::checkComposeTable()
+{
+ QList<QComposeTableElement>::iterator it =
+ qLowerBound(m_composeTable.begin(), m_composeTable.end(), m_composeBuffer, Compare());
+
+ // prevent dereferencing an 'end' iterator, which would result in a crash
+ if (it == m_composeTable.end())
+ it -= 1;
+
+ QComposeTableElement elem = *it;
+ // would be nicer if qLowerBound had API that tells if the item was actually found
+ if (m_composeBuffer[0] != elem.keys[0]) {
+#ifdef DEBUG_COMPOSING
+ qDebug( "### no match ###" );
+#endif
+ reset();
+ return false;
+ }
+ // check if compose buffer is matched
+ for (int i=0; i < QT_KEYSEQUENCE_MAX_LEN; i++) {
+
+ // check if partial match
+ if (m_composeBuffer[i] == 0 && elem.keys[i]) {
+#ifdef DEBUG_COMPOSING
+ qDebug("### partial match ###");
+#endif
+ return true;
+ }
+
+ if (m_composeBuffer[i] != elem.keys[i]) {
+#ifdef DEBUG_COMPOSING
+ qDebug("### different entry ###");
+#endif
+ reset();
+ return i != 0;
+ }
+ }
+#ifdef DEBUG_COMPOSING
+ qDebug("### match exactly ###");
+#endif
+
+ // check if the key sequence is overwriten - see the comment in
+ // TableGenerator::orderComposeTable()
+ int next = 1;
+ do {
+ // if we are at the end of the table, then we have nothing to do here
+ if (it + next != m_composeTable.end()) {
+ QComposeTableElement nextElem = *(it + next);
+ if (isDuplicate(elem, nextElem)) {
+ elem = nextElem;
+ next++;
+ continue;
+ } else {
+ break;
+ }
+ }
+ break;
+ } while (true);
+
+ commitText(elem.value);
+ reset();
+
+ return true;
+}
+
+void QComposeInputContext::commitText(uint character) const
+{
+ QInputMethodEvent event;
+ event.setCommitString(QChar(character));
+ QCoreApplication::sendEvent(m_focusObject, &event);
+}
+
+bool QComposeInputContext::ignoreKey(int keyval) const
+{
+ for (uint i = 0; i < (sizeof(ignoreKeys) / sizeof(ignoreKeys[0])); i++)
+ if (keyval == ignoreKeys[i])
+ return true;
+
+ return false;
+}
+
+bool QComposeInputContext::composeKey(int keyval) const
+{
+ for (uint i = 0; i < (sizeof(composingKeys) / sizeof(composingKeys[0])); i++)
+ if (keyval == composingKeys[i])
+ return true;
+
+ return false;
+}
+
+void QComposeInputContext::clearComposeBuffer()
+{
+ for (uint i=0; i < (sizeof(m_composeBuffer) / sizeof(int)); i++)
+ m_composeBuffer[i] = 0;
+}
+
+QComposeInputContext::~QComposeInputContext() {}
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.h b/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.h
new file mode 100644
index 0000000000..1ced2f8ded
--- /dev/null
+++ b/src/plugins/platforminputcontexts/compose/qcomposeplatforminputcontext.h
@@ -0,0 +1,85 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QCOMPOSEPLATFORMINPUTCONTEXT_H
+#define QCOMPOSEPLATFORMINPUTCONTEXT_H
+
+#include <qpa/qplatforminputcontext.h>
+
+#include <QtCore/QList>
+
+#include "generator/qtablegenerator.h"
+
+QT_BEGIN_NAMESPACE
+
+class QEvent;
+
+class QComposeInputContext : public QPlatformInputContext
+{
+ Q_OBJECT
+
+public:
+ QComposeInputContext();
+ ~QComposeInputContext();
+
+ bool isValid() const;
+ void setFocusObject(QObject *object);
+ void reset();
+ void update(Qt::InputMethodQueries);
+ bool filterEvent(const QEvent *event);
+
+protected:
+ void clearComposeBuffer();
+ bool ignoreKey(int keyval) const;
+ bool composeKey(int keyval) const;
+ bool checkComposeTable();
+ void commitText(uint character) const;
+
+private:
+ QObject *m_focusObject;
+ QList<QComposeTableElement> m_composeTable;
+ uint m_composeBuffer[QT_KEYSEQUENCE_MAX_LEN + 1];
+ TableGenerator::TableState m_tableState;
+};
+
+QT_END_NAMESPACE
+
+#endif // QCOMPOSEPLATFORMINPUTCONTEXT_H
diff --git a/src/plugins/platforminputcontexts/compose/xkbcommon_workaround.h b/src/plugins/platforminputcontexts/compose/xkbcommon_workaround.h
new file mode 100644
index 0000000000..58ce143978
--- /dev/null
+++ b/src/plugins/platforminputcontexts/compose/xkbcommon_workaround.h
@@ -0,0 +1,105 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef XKBCOMMON_WORKAROUND_H
+#define XKBCOMMON_WORKAROUND_H
+
+// Function utf32_to_utf8() is borrowed from the libxkbcommon library,
+// file keysym-utf.c. The workaround should be removed once the fix from
+// https://bugs.freedesktop.org/show_bug.cgi?id=56780 gets released.
+static int utf32_to_utf8(uint32_t unichar, char *buffer)
+{
+ int count, shift, length;
+ uint8_t head;
+
+ if (unichar <= 0x007f) {
+ buffer[0] = unichar;
+ buffer[1] = '\0';
+ return 2;
+ }
+ else if (unichar <= 0x07FF) {
+ length = 2;
+ head = 0xc0;
+ }
+ else if (unichar <= 0xffff) {
+ length = 3;
+ head = 0xe0;
+ }
+ else if (unichar <= 0x1fffff) {
+ length = 4;
+ head = 0xf0;
+ }
+ else if (unichar <= 0x3ffffff) {
+ length = 5;
+ head = 0xf8;
+ }
+ else {
+ length = 6;
+ head = 0xfc;
+ }
+
+ for (count = length - 1, shift = 0; count > 0; count--, shift += 6)
+ buffer[count] = 0x80 | ((unichar >> shift) & 0x3f);
+
+ buffer[0] = head | ((unichar >> shift) & 0x3f);
+ buffer[length] = '\0';
+
+ return length + 1;
+}
+
+static bool needWorkaround(uint32_t sym)
+{
+ /* patch encoding botch */
+ if (sym == XKB_KEY_KP_Space)
+ return true;
+
+ /* special keysyms */
+ if ((sym >= XKB_KEY_BackSpace && sym <= XKB_KEY_Clear) ||
+ (sym >= XKB_KEY_KP_Multiply && sym <= XKB_KEY_KP_9) ||
+ sym == XKB_KEY_Return || sym == XKB_KEY_Escape ||
+ sym == XKB_KEY_Delete || sym == XKB_KEY_KP_Tab ||
+ sym == XKB_KEY_KP_Enter || sym == XKB_KEY_KP_Equal)
+ return true;
+
+ return false;
+}
+
+#endif // XKBCOMMON_WORKAROUND_H
diff --git a/src/plugins/platforminputcontexts/ibus/qibusplatforminputcontext.cpp b/src/plugins/platforminputcontexts/ibus/qibusplatforminputcontext.cpp
index f4e7666a85..53e9b171d5 100644
--- a/src/plugins/platforminputcontexts/ibus/qibusplatforminputcontext.cpp
+++ b/src/plugins/platforminputcontexts/ibus/qibusplatforminputcontext.cpp
@@ -226,26 +226,6 @@ void QIBusPlatformInputContext::updatePreeditText(const QDBusVariant &text, uint
}
-/* Kernel keycode -> X keycode table */
-static const unsigned int keycode_table[256] = {
- 0, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23,
- 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39,
- 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55,
- 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71,
- 72, 73, 74, 75, 76, 77, 76, 79, 80, 81, 82, 83, 84, 85, 86, 87,
- 88, 89, 90, 91, 111, 221, 94, 95, 96, 211, 128, 127, 129, 208, 131, 126,
- 108, 109, 112, 111, 113, 181, 97, 98, 99, 100, 102, 103, 104, 105, 106, 107,
- 239, 160, 174, 176, 222, 157, 123, 110, 139, 134, 209, 210, 133, 115, 116, 117,
- 232, 133, 134, 135, 140, 248, 191, 192, 122, 188, 245, 158, 161, 193, 223, 227,
- 198, 199, 200, 147, 159, 151, 178, 201, 146, 203, 166, 236, 230, 235, 234, 233,
- 163, 204, 253, 153, 162, 144, 164, 177, 152, 190, 208, 129, 130, 231, 209, 210,
- 136, 220, 143, 246, 251, 137, 138, 182, 183, 184, 93, 184, 247, 132, 170, 219,
- 249, 205, 207, 149, 150, 154, 155, 167, 168, 169, 171, 172, 173, 165, 175, 179,
- 180, 0, 185, 186, 187, 118, 119, 120, 121, 229, 194, 195, 196, 197, 148, 202,
- 101, 212, 237, 214, 215, 216, 217, 218, 228, 142, 213, 240, 241, 242, 243, 244,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
-};
-
bool
QIBusPlatformInputContext::x11FilterEvent(uint keyval, uint keycode, uint state, bool press)
{
diff --git a/src/plugins/platforminputcontexts/platforminputcontexts.pro b/src/plugins/platforminputcontexts/platforminputcontexts.pro
index c8449e7e44..fb58de5edc 100644
--- a/src/plugins/platforminputcontexts/platforminputcontexts.pro
+++ b/src/plugins/platforminputcontexts/platforminputcontexts.pro
@@ -1,4 +1,10 @@
TEMPLATE = subdirs
+
qtHaveModule(dbus) {
-!macx:!win32:SUBDIRS += ibus maliit
+!mac:!win32:SUBDIRS += ibus maliit
}
+
+unix:!macx:contains(QT_CONFIG, xkbcommon): {
+ SUBDIRS += compose
+}
+
diff --git a/src/plugins/platforms/android/android.pro b/src/plugins/platforms/android/android.pro
new file mode 100644
index 0000000000..aa5ab4ddbd
--- /dev/null
+++ b/src/plugins/platforms/android/android.pro
@@ -0,0 +1,3 @@
+TEMPLATE = subdirs
+
+SUBDIRS += raster opengl
diff --git a/src/plugins/platforms/android/opengl/opengl.pro b/src/plugins/platforms/android/opengl/opengl.pro
new file mode 100644
index 0000000000..301c8e6e4c
--- /dev/null
+++ b/src/plugins/platforms/android/opengl/opengl.pro
@@ -0,0 +1,30 @@
+TARGET = qtforandroidGL
+
+PLUGIN_TYPE = platforms
+load(qt_plugin)
+
+# STATICPLUGIN needed because there's a Q_IMPORT_PLUGIN in androidjnimain.cpp
+# Yes, the plugin imports itself statically
+DEFINES += QT_STATICPLUGIN ANDROID_PLUGIN_OPENGL
+
+!equals(ANDROID_PLATFORM, android-9) {
+ INCLUDEPATH += $$NDK_ROOT/platforms/android-9/arch-$$ANDROID_ARCHITECTURE/usr/include
+ LIBS += -L$$NDK_ROOT/platforms/android-9/arch-$$ANDROID_ARCHITECTURE/usr/lib -ljnigraphics -landroid
+} else {
+ LIBS += -ljnigraphics -landroid
+}
+
+EGLFS_PLATFORM_HOOKS_SOURCES = $$PWD/../src/opengl/qeglfshooks_android.cpp
+
+INCLUDEPATH += $$PWD/../src/opengl/
+
+HEADERS += \
+ $$PWD/../src/opengl/qandroidopenglcontext.h \
+ $$PWD/../src/opengl/qandroidopenglplatformwindow.h
+
+SOURCES += \
+ $$PWD/../src/opengl/qandroidopenglcontext.cpp \
+ $$PWD/../src/opengl/qandroidopenglplatformwindow.cpp
+
+include($$PWD/../../eglfs/eglfs.pri)
+include($$PWD/../src/src.pri)
diff --git a/src/plugins/platforms/android/raster/raster.pro b/src/plugins/platforms/android/raster/raster.pro
new file mode 100644
index 0000000000..53d8ee7a2b
--- /dev/null
+++ b/src/plugins/platforms/android/raster/raster.pro
@@ -0,0 +1,19 @@
+TARGET = qtforandroid
+
+PLUGIN_TYPE = platforms
+
+# STATICPLUGIN needed because there's a Q_IMPORT_PLUGIN in androidjnimain.cpp
+# Yes, the plugin imports itself statically
+DEFINES += QT_STATICPLUGIN
+
+load(qt_plugin)
+
+!contains(ANDROID_PLATFORM, android-9) {
+ INCLUDEPATH += $$NDK_ROOT/platforms/android-9/arch-$$ANDROID_ARCHITECTURE/usr/include
+ LIBS += -L$$NDK_ROOT/platforms/android-9/arch-$$ANDROID_ARCHITECTURE/usr/lib -ljnigraphics -landroid
+} else {
+ LIBS += -ljnigraphics -landroid
+}
+
+include($$PWD/../src/src.pri)
+include($$PWD/../src/raster/raster.pri)
diff --git a/src/plugins/platforms/android/src/android.json b/src/plugins/platforms/android/src/android.json
new file mode 100644
index 0000000000..6843bd3301
--- /dev/null
+++ b/src/plugins/platforms/android/src/android.json
@@ -0,0 +1,3 @@
+{
+ "Keys": [ "android" ]
+}
diff --git a/src/plugins/platforms/android/src/androidjniclipboard.cpp b/src/plugins/platforms/android/src/androidjniclipboard.cpp
new file mode 100644
index 0000000000..05270ac374
--- /dev/null
+++ b/src/plugins/platforms/android/src/androidjniclipboard.cpp
@@ -0,0 +1,120 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "androidjniclipboard.h"
+#include "androidjnimain.h"
+
+using namespace QtAndroid;
+namespace QtAndroidClipboard
+{
+ // Clipboard support
+ static jmethodID m_registerClipboardManagerMethodID = 0;
+ static jmethodID m_setClipboardTextMethodID = 0;
+ static jmethodID m_hasClipboardTextMethodID = 0;
+ static jmethodID m_getClipboardTextMethodID = 0;
+ // Clipboard support
+
+ void setClipboardListener(QAndroidPlatformClipboard *listener)
+ {
+ Q_UNUSED(listener);
+
+ AttachedJNIEnv env;
+ if (!env.jniEnv)
+ return;
+
+ env.jniEnv->CallStaticVoidMethod(applicationClass(), m_registerClipboardManagerMethodID);
+ }
+
+ void setClipboardText(const QString &text)
+ {
+ AttachedJNIEnv env;
+ if (!env.jniEnv)
+ return;
+
+ jstring jtext = env.jniEnv->NewString(reinterpret_cast<const jchar *>(text.data()),
+ text.length());
+ env.jniEnv->CallStaticVoidMethod(applicationClass(), m_setClipboardTextMethodID, jtext);
+ env.jniEnv->DeleteLocalRef(jtext);
+ }
+
+ bool hasClipboardText()
+ {
+ AttachedJNIEnv env;
+ if (!env.jniEnv)
+ return false;
+
+ return env.jniEnv->CallStaticBooleanMethod(applicationClass(), m_hasClipboardTextMethodID);
+ }
+
+ QString clipboardText()
+ {
+ AttachedJNIEnv env;
+ if (!env.jniEnv)
+ return QString();
+
+ jstring text = reinterpret_cast<jstring>(env.jniEnv->CallStaticObjectMethod(applicationClass(),
+ m_getClipboardTextMethodID));
+ const jchar *jstr = env.jniEnv->GetStringChars(text, 0);
+ QString str(reinterpret_cast<const QChar *>(jstr), env.jniEnv->GetStringLength(text));
+ env.jniEnv->ReleaseStringChars(text, jstr);
+ return str;
+ }
+
+
+#define GET_AND_CHECK_STATIC_METHOD(VAR, CLASS, METHOD_NAME, METHOD_SIGNATURE) \
+ VAR = env->GetStaticMethodID(CLASS, METHOD_NAME, METHOD_SIGNATURE); \
+ if (!VAR) { \
+ __android_log_print(ANDROID_LOG_FATAL, qtTagText(), methodErrorMsgFmt(), METHOD_NAME, METHOD_SIGNATURE); \
+ return false; \
+ }
+
+ bool registerNatives(JNIEnv *env)
+ {
+ jclass appClass = QtAndroid::applicationClass();
+
+ GET_AND_CHECK_STATIC_METHOD(m_registerClipboardManagerMethodID, appClass, "registerClipboardManager", "()V");
+ GET_AND_CHECK_STATIC_METHOD(m_setClipboardTextMethodID, appClass, "setClipboardText", "(Ljava/lang/String;)V");
+ GET_AND_CHECK_STATIC_METHOD(m_hasClipboardTextMethodID, appClass, "hasClipboardText", "()Z");
+ GET_AND_CHECK_STATIC_METHOD(m_getClipboardTextMethodID, appClass, "getClipboardText", "()Ljava/lang/String;");
+
+ return true;
+ }
+}
diff --git a/src/plugins/platforms/android/src/androidjniclipboard.h b/src/plugins/platforms/android/src/androidjniclipboard.h
new file mode 100644
index 0000000000..15cd93202e
--- /dev/null
+++ b/src/plugins/platforms/android/src/androidjniclipboard.h
@@ -0,0 +1,61 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef ANDROIDJNICLIPBOARD_H
+#define ANDROIDJNICLIPBOARD_H
+
+#include <jni.h>
+#include <QString>
+
+class QAndroidPlatformClipboard;
+namespace QtAndroidClipboard
+{
+ // Clipboard support
+ void setClipboardListener(QAndroidPlatformClipboard *listener);
+ void setClipboardText(const QString &text);
+ bool hasClipboardText();
+ QString clipboardText();
+ // Clipboard support
+
+ bool registerNatives(JNIEnv *env);
+}
+
+#endif // ANDROIDJNICLIPBOARD_H
diff --git a/src/plugins/platforms/android/src/androidjniinput.cpp b/src/plugins/platforms/android/src/androidjniinput.cpp
new file mode 100644
index 0000000000..da6156a330
--- /dev/null
+++ b/src/plugins/platforms/android/src/androidjniinput.cpp
@@ -0,0 +1,497 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "androidjniinput.h"
+#include "androidjnimain.h"
+#include "qandroidplatformintegration.h"
+
+#include <qpa/qwindowsysteminterface.h>
+#include <QTouchEvent>
+#include <QPointer>
+
+using namespace QtAndroid;
+
+namespace QtAndroidInput
+{
+ static jmethodID m_showSoftwareKeyboardMethodID = 0;
+ static jmethodID m_resetSoftwareKeyboardMethodID = 0;
+ static jmethodID m_hideSoftwareKeyboardMethodID = 0;
+ static jmethodID m_isSoftwareKeyboardVisibleMethodID = 0;
+ static jmethodID m_updateSelectionMethodID = 0;
+
+ static bool m_ignoreMouseEvents = false;
+
+ static QList<QWindowSystemInterface::TouchPoint> m_touchPoints;
+
+ static QPointer<QWindow> m_mouseGrabber;
+
+ void updateSelection(int selStart, int selEnd, int candidatesStart, int candidatesEnd)
+ {
+ AttachedJNIEnv env;
+ if (!env.jniEnv)
+ return;
+
+ env.jniEnv->CallStaticVoidMethod(applicationClass(), m_updateSelectionMethodID,
+ selStart, selEnd, candidatesStart, candidatesEnd);
+ }
+
+ void showSoftwareKeyboard(int left, int top, int width, int height, int inputHints)
+ {
+ AttachedJNIEnv env;
+ if (!env.jniEnv)
+ return;
+
+ env.jniEnv->CallStaticVoidMethod(applicationClass(),
+ m_showSoftwareKeyboardMethodID,
+ left,
+ top,
+ width,
+ height,
+ inputHints);
+ }
+
+ void resetSoftwareKeyboard()
+ {
+ AttachedJNIEnv env;
+ if (!env.jniEnv)
+ return;
+
+ env.jniEnv->CallStaticVoidMethod(applicationClass(), m_resetSoftwareKeyboardMethodID);
+ }
+
+ void hideSoftwareKeyboard()
+ {
+ AttachedJNIEnv env;
+ if (!env.jniEnv)
+ return;
+
+ env.jniEnv->CallStaticVoidMethod(applicationClass(), m_hideSoftwareKeyboardMethodID);
+ }
+
+ bool isSoftwareKeyboardVisible()
+ {
+ AttachedJNIEnv env;
+ if (!env.jniEnv)
+ return false;
+
+ return env.jniEnv->CallStaticBooleanMethod(applicationClass(), m_isSoftwareKeyboardVisibleMethodID);
+ }
+
+
+ static void mouseDown(JNIEnv */*env*/, jobject /*thiz*/, jint /*winId*/, jint x, jint y)
+ {
+ if (m_ignoreMouseEvents)
+ return;
+
+ QPoint globalPos(x,y);
+ QWindow *tlw = topLevelWindowAt(globalPos);
+ m_mouseGrabber = tlw;
+ QPoint localPos = tlw ? (globalPos - tlw->position()) : globalPos;
+ QWindowSystemInterface::handleMouseEvent(tlw,
+ localPos,
+ globalPos,
+ Qt::MouseButtons(Qt::LeftButton));
+ }
+
+ static void mouseUp(JNIEnv */*env*/, jobject /*thiz*/, jint /*winId*/, jint x, jint y)
+ {
+ QPoint globalPos(x,y);
+ QWindow *tlw = m_mouseGrabber.data();
+ if (!tlw)
+ tlw = topLevelWindowAt(globalPos);
+ QPoint localPos = tlw ? (globalPos -tlw->position()) : globalPos;
+ QWindowSystemInterface::handleMouseEvent(tlw, localPos, globalPos
+ , Qt::MouseButtons(Qt::NoButton));
+ m_ignoreMouseEvents = false;
+ m_mouseGrabber = 0;
+ }
+
+ static void mouseMove(JNIEnv */*env*/, jobject /*thiz*/, jint /*winId*/, jint x, jint y)
+ {
+
+ if (m_ignoreMouseEvents)
+ return;
+
+ QPoint globalPos(x,y);
+ QWindow *tlw = m_mouseGrabber.data();
+ if (!tlw)
+ tlw = topLevelWindowAt(globalPos);
+ QPoint localPos = tlw ? (globalPos-tlw->position()) : globalPos;
+ QWindowSystemInterface::handleMouseEvent(tlw,
+ localPos,
+ globalPos,
+ Qt::MouseButtons(Qt::LeftButton));
+ }
+
+ static void longPress(JNIEnv */*env*/, jobject /*thiz*/, jint /*winId*/, jint x, jint y)
+ {
+ m_ignoreMouseEvents = true;
+ QPoint globalPos(x,y);
+ QWindow *tlw = topLevelWindowAt(globalPos);
+ QPoint localPos = tlw ? (globalPos-tlw->position()) : globalPos;
+
+ // Release left button
+ QWindowSystemInterface::handleMouseEvent(tlw,
+ localPos,
+ globalPos,
+ Qt::MouseButtons(Qt::NoButton));
+
+ // Press right button
+ QWindowSystemInterface::handleMouseEvent(tlw,
+ localPos,
+ globalPos,
+ Qt::MouseButtons(Qt::RightButton));
+ }
+
+ static void touchBegin(JNIEnv */*env*/, jobject /*thiz*/, jint /*winId*/)
+ {
+ m_touchPoints.clear();
+ }
+
+ static void touchAdd(JNIEnv */*env*/, jobject /*thiz*/, jint /*winId*/, jint id, jint action, jboolean /*primary*/, jint x, jint y, jfloat size, jfloat pressure)
+ {
+ Qt::TouchPointState state = Qt::TouchPointStationary;
+ switch (action) {
+ case 0:
+ state = Qt::TouchPointPressed;
+ break;
+ case 1:
+ state = Qt::TouchPointMoved;
+ break;
+ case 2:
+ state = Qt::TouchPointStationary;
+ break;
+ case 3:
+ state = Qt::TouchPointReleased;
+ break;
+ }
+
+ const int dw = desktopWidthPixels();
+ const int dh = desktopHeightPixels();
+ QWindowSystemInterface::TouchPoint touchPoint;
+ touchPoint.id = id;
+ touchPoint.pressure = pressure;
+ touchPoint.normalPosition = QPointF(double(x / dw), double(y / dh));
+ touchPoint.state = state;
+ touchPoint.area = QRectF(x - double(dw*size) / 2.0,
+ y - double(dh*size) / 2.0,
+ double(dw*size),
+ double(dh*size));
+ m_touchPoints.push_back(touchPoint);
+ }
+
+ static void touchEnd(JNIEnv */*env*/, jobject /*thiz*/, jint /*winId*/, jint action)
+ {
+ if (m_touchPoints.isEmpty())
+ return;
+
+ QEvent::Type eventType = QEvent::None;
+ switch (action) {
+ case 0:
+ eventType = QEvent::TouchBegin;
+ break;
+ case 1:
+ eventType = QEvent::TouchUpdate;
+ break;
+ case 2:
+ eventType = QEvent::TouchEnd;
+ break;
+ }
+
+ QAndroidPlatformIntegration *platformIntegration = QtAndroid::androidPlatformIntegration();
+ QTouchDevice *touchDevice = platformIntegration->touchDevice();
+ if (touchDevice == 0) {
+ touchDevice = new QTouchDevice;
+ touchDevice->setType(QTouchDevice::TouchScreen);
+ touchDevice->setCapabilities(QTouchDevice::Position
+ | QTouchDevice::Area
+ | QTouchDevice::Pressure
+ | QTouchDevice::NormalizedPosition);
+ QWindowSystemInterface::registerTouchDevice(touchDevice);
+ platformIntegration->setTouchDevice(touchDevice);
+ }
+
+ QWindow *window = QtAndroid::topLevelWindowAt(m_touchPoints.at(0).area.center().toPoint());
+ QWindowSystemInterface::handleTouchEvent(window, touchDevice, m_touchPoints);
+ }
+
+ static int mapAndroidKey(int key)
+ {
+ // 0--9 0x00000007 -- 0x00000010
+ if (key >= 0x00000007 && key <= 0x00000010)
+ return Qt::Key_0 + key - 0x00000007;
+
+ // A--Z 0x0000001d -- 0x00000036
+ if (key >= 0x0000001d && key <= 0x00000036)
+ return Qt::Key_A + key - 0x0000001d;
+
+ switch (key) {
+ case 0x00000039:
+ case 0x0000003a:
+ return Qt::Key_Alt;
+
+ case 0x0000004b:
+ return Qt::Key_Apostrophe;
+
+ case 0x00000004: // KEYCODE_BACK
+ return Qt::Key_Back;
+
+ case 0x00000049:
+ return Qt::Key_Backslash;
+
+ case 0x00000005:
+ return Qt::Key_Call;
+
+ case 0x0000001b:
+ return Qt::Key_WebCam;
+
+ case 0x0000001c:
+ return Qt::Key_Clear;
+
+ case 0x00000037:
+ return Qt::Key_Comma;
+
+ case 0x00000043:
+ return Qt::Key_Backspace;
+
+ case 0x00000017: // KEYCODE_DPAD_CENTER
+ return Qt::Key_Enter;
+
+ case 0x00000014: // KEYCODE_DPAD_DOWN
+ return Qt::Key_Down;
+
+ case 0x00000015: //KEYCODE_DPAD_LEFT
+ return Qt::Key_Left;
+
+ case 0x00000016: //KEYCODE_DPAD_RIGHT
+ return Qt::Key_Right;
+
+ case 0x00000013: //KEYCODE_DPAD_UP
+ return Qt::Key_Up;
+
+ case 0x00000006: //KEYCODE_ENDCALL
+ return Qt::Key_Hangup;
+
+ case 0x00000042:
+ return Qt::Key_Return;
+
+ case 0x00000041: //KEYCODE_ENVELOPE
+ return Qt::Key_LaunchMail;
+
+ case 0x00000046:
+ return Qt::Key_Equal;
+
+ case 0x00000040:
+ return Qt::Key_Explorer;
+
+ case 0x00000003:
+ return Qt::Key_Home;
+
+ case 0x00000047:
+ return Qt::Key_BracketLeft;
+
+ case 0x0000005a: // KEYCODE_MEDIA_FAST_FORWARD
+ return Qt::Key_Forward;
+
+ case 0x00000057:
+ return Qt::Key_MediaNext;
+
+ case 0x00000055:
+ return Qt::Key_MediaPlay;
+
+ case 0x00000058:
+ return Qt::Key_MediaPrevious;
+
+ case 0x00000059:
+ return Qt::Key_AudioRewind;
+
+ case 0x00000056:
+ return Qt::Key_MediaStop;
+
+ case 0x00000052: //KEYCODE_MENU
+ return Qt::Key_Menu;
+
+ case 0x00000045:
+ return Qt::Key_Minus;
+
+ case 0x0000005b:
+ return Qt::Key_VolumeMute;
+
+ case 0x0000004e:
+ return Qt::Key_NumLock;
+
+ case 0x00000038:
+ return Qt::Key_Period;
+
+ case 0x00000051:
+ return Qt::Key_Plus;
+
+ case 0x0000001a:
+ return Qt::Key_PowerOff;
+
+ case 0x00000048:
+ return Qt::Key_BracketRight;
+
+ case 0x00000054:
+ return Qt::Key_Search;
+
+ case 0x0000004a:
+ return Qt::Key_Semicolon;
+
+ case 0x0000003b:
+ case 0x0000003c:
+ return Qt::Key_Shift;
+
+ case 0x0000004c:
+ return Qt::Key_Slash;
+
+ case 0x00000001:
+ return Qt::Key_Left;
+
+ case 0x00000002:
+ return Qt::Key_Right;
+
+ case 0x0000003e:
+ return Qt::Key_Space;
+
+ case 0x0000003f: // KEYCODE_SYM
+ return Qt::Key_Meta;
+
+ case 0x0000003d:
+ return Qt::Key_Tab;
+
+ case 0x00000019:
+ return Qt::Key_VolumeDown;
+
+ case 0x00000018:
+ return Qt::Key_VolumeUp;
+
+ case 0x00000000: // KEYCODE_UNKNOWN
+ case 0x00000011: // KEYCODE_STAR ?!?!?
+ case 0x00000012: // KEYCODE_POUND ?!?!?
+ case 0x00000053: // KEYCODE_NOTIFICATION ?!?!?
+ case 0x0000004f: // KEYCODE_HEADSETHOOK ?!?!?
+ case 0x00000044: // KEYCODE_GRAVE ?!?!?
+ case 0x00000050: // KEYCODE_FOCUS ?!?!?
+ return Qt::Key_Any;
+
+ default:
+ return 0;
+ }
+ }
+
+ static void keyDown(JNIEnv */*env*/, jobject /*thiz*/, jint key, jint unicode, jint modifier)
+ {
+ Qt::KeyboardModifiers modifiers;
+ if (modifier & 1)
+ modifiers |= Qt::ShiftModifier;
+
+ if (modifier & 2)
+ modifiers |= Qt::AltModifier;
+
+ if (modifier & 4)
+ modifiers |= Qt::MetaModifier;
+
+ QWindowSystemInterface::handleKeyEvent(0,
+ QEvent::KeyPress,
+ mapAndroidKey(key),
+ modifiers,
+ QChar(unicode),
+ true);
+ }
+
+ static void keyUp(JNIEnv */*env*/, jobject /*thiz*/, jint key, jint unicode, jint modifier)
+ {
+ Qt::KeyboardModifiers modifiers;
+ if (modifier & 1)
+ modifiers |= Qt::ShiftModifier;
+
+ if (modifier & 2)
+ modifiers |= Qt::AltModifier;
+
+ if (modifier & 4)
+ modifiers |= Qt::MetaModifier;
+
+ QWindowSystemInterface::handleKeyEvent(0,
+ QEvent::KeyRelease,
+ mapAndroidKey(key),
+ modifiers,
+ QChar(unicode),
+ true);
+ }
+
+
+ static JNINativeMethod methods[] = {
+ {"touchBegin","(I)V",(void*)touchBegin},
+ {"touchAdd","(IIIZIIFF)V",(void*)touchAdd},
+ {"touchEnd","(II)V",(void*)touchEnd},
+ {"mouseDown", "(III)V", (void *)mouseDown},
+ {"mouseUp", "(III)V", (void *)mouseUp},
+ {"mouseMove", "(III)V", (void *)mouseMove},
+ {"longPress", "(III)V", (void *)longPress},
+ {"keyDown", "(III)V", (void *)keyDown},
+ {"keyUp", "(III)V", (void *)keyUp}
+ };
+
+#define GET_AND_CHECK_STATIC_METHOD(VAR, CLASS, METHOD_NAME, METHOD_SIGNATURE) \
+ VAR = env->GetStaticMethodID(CLASS, METHOD_NAME, METHOD_SIGNATURE); \
+ if (!VAR) { \
+ __android_log_print(ANDROID_LOG_FATAL, qtTagText(), methodErrorMsgFmt(), METHOD_NAME, METHOD_SIGNATURE); \
+ return false; \
+ }
+
+ bool registerNatives(JNIEnv *env)
+ {
+ jclass appClass = QtAndroid::applicationClass();
+
+ if (env->RegisterNatives(appClass, methods, sizeof(methods) / sizeof(methods[0])) < 0) {
+ __android_log_print(ANDROID_LOG_FATAL,"Qt", "RegisterNatives failed");
+ return false;
+ }
+
+ GET_AND_CHECK_STATIC_METHOD(m_showSoftwareKeyboardMethodID, appClass, "showSoftwareKeyboard", "(IIIII)V");
+ GET_AND_CHECK_STATIC_METHOD(m_resetSoftwareKeyboardMethodID, appClass, "resetSoftwareKeyboard", "()V");
+ GET_AND_CHECK_STATIC_METHOD(m_hideSoftwareKeyboardMethodID, appClass, "hideSoftwareKeyboard", "()V");
+ GET_AND_CHECK_STATIC_METHOD(m_isSoftwareKeyboardVisibleMethodID, appClass, "isSoftwareKeyboardVisible", "()Z");
+ GET_AND_CHECK_STATIC_METHOD(m_updateSelectionMethodID, appClass, "updateSelection", "(IIII)V");
+ return true;
+ }
+}
diff --git a/src/plugins/platforms/android/src/androidjniinput.h b/src/plugins/platforms/android/src/androidjniinput.h
new file mode 100644
index 0000000000..a78c7519db
--- /dev/null
+++ b/src/plugins/platforms/android/src/androidjniinput.h
@@ -0,0 +1,59 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef ANDROIDJNIINPUT_H
+#define ANDROIDJNIINPUT_H
+#include <jni.h>
+
+namespace QtAndroidInput
+{
+ // Software keyboard support
+ void showSoftwareKeyboard(int top, int left, int width, int height, int inputHints);
+ void resetSoftwareKeyboard();
+ void hideSoftwareKeyboard();
+ bool isSoftwareKeyboardVisible();
+ void updateSelection(int selStart, int selEnd, int candidatesStart, int candidatesEnd);
+ // Software keyboard support
+
+ bool registerNatives(JNIEnv *env);
+}
+
+#endif // ANDROIDJNIINPUT_H
diff --git a/src/plugins/platforms/android/src/androidjnimain.cpp b/src/plugins/platforms/android/src/androidjnimain.cpp
new file mode 100644
index 0000000000..36d95b0816
--- /dev/null
+++ b/src/plugins/platforms/android/src/androidjnimain.cpp
@@ -0,0 +1,831 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+#include <dlfcn.h>
+#include <pthread.h>
+#include <qcoreapplication.h>
+#include <qimage.h>
+#include <qpoint.h>
+#include <qplugin.h>
+#include <qsemaphore.h>
+#include <qmutex.h>
+#include <qdebug.h>
+#include <qglobal.h>
+#include <qobjectdefs.h>
+#include <stdlib.h>
+
+#include "androidjnimain.h"
+#include "androidjniinput.h"
+#include "androidjniclipboard.h"
+#include "androidjnimenu.h"
+#include "qandroidplatformintegration.h"
+#include <QtWidgets/QApplication>
+
+#include <qabstracteventdispatcher.h>
+
+#include <android/bitmap.h>
+#include <android/asset_manager_jni.h>
+#include "qandroidassetsfileenginehandler.h"
+#include <android/api-level.h>
+
+#include <qpa/qwindowsysteminterface.h>
+
+#ifdef ANDROID_PLUGIN_OPENGL
+# include "qandroidopenglplatformwindow.h"
+#endif
+
+#if __ANDROID_API__ > 8
+# include <android/native_window_jni.h>
+#endif
+
+static jmethodID m_redrawSurfaceMethodID = 0;
+
+Q_IMPORT_PLUGIN(QAndroidPlatformIntegrationPlugin)
+
+static JavaVM *m_javaVM = NULL;
+static jclass m_applicationClass = NULL;
+static jobject m_classLoaderObject = NULL;
+static jmethodID m_loadClassMethodID = NULL;
+static AAssetManager *m_assetManager = NULL;
+static jobject m_resourcesObj;
+static jobject m_activityObject = NULL;
+
+static jclass m_bitmapClass = 0;
+static jmethodID m_createBitmapMethodID = 0;
+static jobject m_ARGB_8888_BitmapConfigValue = 0;
+static jobject m_RGB_565_BitmapConfigValue = 0;
+
+static jclass m_bitmapDrawableClass = 0;
+static jmethodID m_bitmapDrawableConstructorMethodID = 0;
+
+extern "C" typedef int (*Main)(int, char **); //use the standard main method to start the application
+static Main m_main = NULL;
+static void *m_mainLibraryHnd = NULL;
+static QList<QByteArray> m_applicationParams;
+
+#ifndef ANDROID_PLUGIN_OPENGL
+static jobject m_surface = NULL;
+#else
+static EGLNativeWindowType m_nativeWindow = 0;
+static QSemaphore m_waitForWindowSemaphore;
+static bool m_waitForWindow = false;
+
+static jfieldID m_surfaceFieldID = 0;
+#endif
+
+
+static QSemaphore m_quitAppSemaphore;
+static QMutex m_surfaceMutex(QMutex::Recursive);
+static QSemaphore m_pauseApplicationSemaphore;
+static QMutex m_pauseApplicationMutex;
+
+static QAndroidPlatformIntegration *m_androidPlatformIntegration = 0;
+
+static int m_desktopWidthPixels = 0;
+static int m_desktopHeightPixels = 0;
+static double m_scaledDensity = 0;
+
+static volatile bool m_pauseApplication;
+
+static AndroidAssetsFileEngineHandler *m_androidAssetsFileEngineHandler = 0;
+
+
+
+static const char m_qtTag[] = "Qt";
+static const char m_classErrorMsg[] = "Can't find class \"%s\"";
+static const char m_methodErrorMsg[] = "Can't find method \"%s%s\"";
+
+static inline void checkPauseApplication()
+{
+ m_pauseApplicationMutex.lock();
+ if (m_pauseApplication) {
+ m_pauseApplicationMutex.unlock();
+ m_pauseApplicationSemaphore.acquire(); // wait until surface is created
+
+ m_pauseApplicationMutex.lock();
+ m_pauseApplication = false;
+ m_pauseApplicationMutex.unlock();
+
+ //FIXME
+// QWindowSystemInterface::handleScreenAvailableGeometryChange(0);
+// QWindowSystemInterface::handleScreenGeometryChange(0);
+ } else {
+ m_pauseApplicationMutex.unlock();
+ }
+}
+
+namespace QtAndroid
+{
+#ifndef ANDROID_PLUGIN_OPENGL
+ void flushImage(const QPoint &pos, const QImage &image, const QRect &destinationRect)
+ {
+ checkPauseApplication();
+ QMutexLocker locker(&m_surfaceMutex);
+ if (!m_surface)
+ return;
+ AttachedJNIEnv env;
+ if (!env.jniEnv)
+ return;
+
+ int bpp = 2;
+ AndroidBitmapInfo info;
+ int ret;
+
+ if ((ret = AndroidBitmap_getInfo(env.jniEnv, m_surface, &info)) < 0) {
+ qWarning() << "AndroidBitmap_getInfo() failed ! error=" << ret;
+ m_javaVM->DetachCurrentThread();
+ return;
+ }
+
+ if (info.format != ANDROID_BITMAP_FORMAT_RGB_565) {
+ qWarning() << "Bitmap format is not RGB_565!";
+ m_javaVM->DetachCurrentThread();
+ return;
+ }
+
+ void *pixels;
+ unsigned char *screenBits;
+ if ((ret = AndroidBitmap_lockPixels(env.jniEnv, m_surface, &pixels)) < 0) {
+ qWarning() << "AndroidBitmap_lockPixels() failed! error=" << ret;
+ m_javaVM->DetachCurrentThread();
+ return;
+ }
+
+ screenBits = static_cast<unsigned char *>(pixels);
+ int sbpl = info.stride;
+ int swidth = info.width;
+ int sheight = info.height;
+
+ unsigned sposx = pos.x() + destinationRect.x();
+ unsigned sposy = pos.y() + destinationRect.y();
+
+ screenBits += sposy * sbpl;
+
+ unsigned ibpl = image.bytesPerLine();
+ unsigned iposx = destinationRect.x();
+ unsigned iposy = destinationRect.y();
+
+ const unsigned char *imageBits = static_cast<const unsigned char *>(image.bits());
+ imageBits += iposy * ibpl;
+
+ unsigned width = swidth - sposx < unsigned(destinationRect.width())
+ ? (swidth-sposx)
+ : destinationRect.width();
+ unsigned height = sheight - sposy < unsigned(destinationRect.height())
+ ? (sheight - sposy)
+ : destinationRect.height();
+
+ for (unsigned y = 0; y < height; y++) {
+ memcpy(screenBits + y*sbpl + sposx*bpp,
+ imageBits + y*ibpl + iposx*bpp,
+ width*bpp);
+ }
+ AndroidBitmap_unlockPixels(env.jniEnv, m_surface);
+
+ env.jniEnv->CallStaticVoidMethod(m_applicationClass,
+ m_redrawSurfaceMethodID,
+ jint(destinationRect.left()),
+ jint(destinationRect.top()),
+ jint(destinationRect.right() + 1),
+ jint(destinationRect.bottom() + 1));
+#warning FIXME dirty hack, figure out why it needs to add 1 to right and bottom !!!!
+ }
+
+#else // for #ifndef ANDROID_PLUGIN_OPENGL
+ EGLNativeWindowType nativeWindow(bool waitForWindow)
+ {
+ m_surfaceMutex.lock();
+ if (!m_nativeWindow && waitForWindow) {
+ m_waitForWindow = true;
+ m_surfaceMutex.unlock();
+ m_waitForWindowSemaphore.acquire();
+ m_waitForWindow = false;
+ return m_nativeWindow;
+ }
+ m_surfaceMutex.unlock();
+ return m_nativeWindow;
+ }
+
+ QSize nativeWindowSize()
+ {
+ if (m_nativeWindow == 0)
+ return QAndroidPlatformIntegration::defaultDesktopSize();
+
+ int width = ANativeWindow_getWidth(m_nativeWindow);
+ int height = ANativeWindow_getHeight(m_nativeWindow);
+
+ return QSize(width, height);
+ }
+#endif
+
+ void setAndroidPlatformIntegration(QAndroidPlatformIntegration *androidPlatformIntegration)
+ {
+ m_surfaceMutex.lock();
+ m_androidPlatformIntegration = androidPlatformIntegration;
+ m_surfaceMutex.unlock();
+ }
+
+ QAndroidPlatformIntegration *androidPlatformIntegration()
+ {
+ QMutexLocker locker(&m_surfaceMutex);
+ return m_androidPlatformIntegration;
+ }
+
+ QWindow *topLevelWindowAt(const QPoint &globalPos)
+ {
+ return m_androidPlatformIntegration
+ ? m_androidPlatformIntegration->screen()->topLevelAt(globalPos)
+ : 0;
+ }
+
+ int desktopWidthPixels()
+ {
+ return m_desktopWidthPixels;
+ }
+
+ int desktopHeightPixels()
+ {
+ return m_desktopHeightPixels;
+ }
+
+ double scaledDensity()
+ {
+ return m_scaledDensity;
+ }
+
+ JavaVM *javaVM()
+ {
+ return m_javaVM;
+ }
+
+ jclass findClass(const QString &className, JNIEnv *env)
+ {
+ return static_cast<jclass>(env->CallObjectMethod(m_classLoaderObject,
+ m_loadClassMethodID,
+ env->NewString(reinterpret_cast<const jchar *>(className.constData()),
+ jsize(className.length()))));
+ }
+
+ AAssetManager *assetManager()
+ {
+ return m_assetManager;
+ }
+
+ jclass applicationClass()
+ {
+ return m_applicationClass;
+ }
+
+ jobject activity()
+ {
+ return m_activityObject;
+ }
+
+ jobject createBitmap(QImage img, JNIEnv *env)
+ {
+ if (img.format() != QImage::Format_ARGB32 && img.format() != QImage::Format_RGB16)
+ img = img.convertToFormat(QImage::Format_ARGB32);
+
+ jobject bitmap = env->CallStaticObjectMethod(m_bitmapClass,
+ m_createBitmapMethodID,
+ img.width(),
+ img.height(),
+ img.format() == QImage::Format_ARGB32
+ ? m_ARGB_8888_BitmapConfigValue
+ : m_RGB_565_BitmapConfigValue);
+ if (!bitmap)
+ return 0;
+
+ AndroidBitmapInfo info;
+ if (AndroidBitmap_getInfo(env, bitmap, &info) < 0) {
+ env->DeleteLocalRef(bitmap);
+ return 0;
+ }
+
+ void *pixels;
+ if (AndroidBitmap_lockPixels(env, bitmap, &pixels) < 0) {
+ env->DeleteLocalRef(bitmap);
+ return 0;
+ }
+
+ if (info.stride == uint(img.bytesPerLine())
+ && info.width == uint(img.width())
+ && info.height == uint(img.height())) {
+ memcpy(pixels, img.constBits(), info.stride * info.height);
+ } else {
+ uchar *bmpPtr = static_cast<uchar *>(pixels);
+ const unsigned width = qMin(info.width, (uint)img.width()); //should be the same
+ const unsigned height = qMin(info.height, (uint)img.height()); //should be the same
+ for (unsigned y = 0; y < height; y++, bmpPtr += info.stride)
+ memcpy(bmpPtr, img.constScanLine(y), width);
+ }
+ AndroidBitmap_unlockPixels(env, bitmap);
+ return bitmap;
+ }
+
+ jobject createBitmapDrawable(jobject bitmap, JNIEnv *env)
+ {
+ if (!bitmap)
+ return 0;
+
+ return env->NewObject(m_bitmapDrawableClass,
+ m_bitmapDrawableConstructorMethodID,
+ m_resourcesObj,
+ bitmap);
+ }
+
+ const char *classErrorMsgFmt()
+ {
+ return m_classErrorMsg;
+ }
+
+ const char *methodErrorMsgFmt()
+ {
+ return m_methodErrorMsg;
+ }
+
+ const char *qtTagText()
+ {
+ return m_qtTag;
+ }
+}
+
+static jboolean startQtAndroidPlugin(JNIEnv* /*env*/, jobject /*object*//*, jobject applicationAssetManager*/)
+{
+#ifndef ANDROID_PLUGIN_OPENGL
+ m_surface = 0;
+#else
+ m_nativeWindow = 0;
+ m_waitForWindow = false;
+#endif
+
+ m_androidPlatformIntegration = 0;
+ m_androidAssetsFileEngineHandler = new AndroidAssetsFileEngineHandler();
+
+#ifdef ANDROID_PLUGIN_OPENGL
+ return true;
+#else
+ return false;
+#endif
+}
+
+static void *startMainMethod(void */*data*/)
+{
+ char const **params;
+ params = static_cast<char const **>(malloc(m_applicationParams.length() * sizeof(char *)));
+ for (int i = 0; i < m_applicationParams.size(); i++)
+ params[i] = static_cast<const char *>(m_applicationParams[i].constData());
+
+ int ret = m_main(m_applicationParams.length(), const_cast<char **>(params));
+
+ free(params);
+ Q_UNUSED(ret);
+
+ if (m_mainLibraryHnd) {
+ int res = dlclose(m_mainLibraryHnd);
+ if (res < 0)
+ qWarning() << "dlclose failed:" << dlerror();
+ }
+
+ QtAndroid::AttachedJNIEnv env;
+ if (!env.jniEnv)
+ return 0;
+
+ if (m_applicationClass) {
+ jmethodID quitApp = env.jniEnv->GetStaticMethodID(m_applicationClass, "quitApp", "()V");
+ env.jniEnv->CallStaticVoidMethod(m_applicationClass, quitApp);
+ }
+
+ return 0;
+}
+
+static jboolean startQtApplication(JNIEnv *env, jobject /*object*/, jstring paramsString, jstring environmentString)
+{
+ m_mainLibraryHnd = NULL;
+ const char *nativeString = env->GetStringUTFChars(environmentString, 0);
+ QByteArray string = nativeString;
+ env->ReleaseStringUTFChars(environmentString, nativeString);
+ m_applicationParams=string.split('\t');
+ foreach (string, m_applicationParams) {
+ if (putenv(string.constData()))
+ qWarning() << "Can't set environment" << string;
+ }
+
+ nativeString = env->GetStringUTFChars(paramsString, 0);
+ string = nativeString;
+ env->ReleaseStringUTFChars(paramsString, nativeString);
+
+ m_applicationParams=string.split('\t');
+
+ // Go home
+ QDir::setCurrent(QDir::homePath());
+
+ //look for main()
+ if (m_applicationParams.length()) {
+ // Obtain a handle to the main library (the library that contains the main() function).
+ // This library should already be loaded, and calling dlopen() will just return a reference to it.
+ m_mainLibraryHnd = dlopen(m_applicationParams.first().data(), 0);
+ if (m_mainLibraryHnd == NULL) {
+ qCritical() << "dlopen failed:" << dlerror();
+ return false;
+ }
+ m_main = (Main)dlsym(m_mainLibraryHnd, "main");
+ } else {
+ qWarning() << "No main library was specified; searching entire process (this is slow!)";
+ m_main = (Main)dlsym(RTLD_DEFAULT, "main");
+ }
+
+ if (!m_main) {
+ qCritical() << "dlsym failed:" << dlerror();
+ qCritical() << "Could not find main method";
+ return false;
+ }
+
+ pthread_t appThread;
+ return pthread_create(&appThread, NULL, startMainMethod, NULL) == 0;
+}
+
+static void pauseQtApp(JNIEnv */*env*/, jobject /*thiz*/)
+{
+ m_surfaceMutex.lock();
+ m_pauseApplicationMutex.lock();
+
+ if (m_androidPlatformIntegration)
+ m_androidPlatformIntegration->pauseApp();
+ m_pauseApplication = true;
+
+ m_pauseApplicationMutex.unlock();
+ m_surfaceMutex.unlock();
+}
+
+static void resumeQtApp(JNIEnv */*env*/, jobject /*thiz*/)
+{
+ m_surfaceMutex.lock();
+ m_pauseApplicationMutex.lock();
+ if (m_androidPlatformIntegration)
+ m_androidPlatformIntegration->resumeApp();
+
+ if (m_pauseApplication)
+ m_pauseApplicationSemaphore.release();
+
+ m_pauseApplicationMutex.unlock();
+ m_surfaceMutex.unlock();
+}
+
+static void quitQtAndroidPlugin(JNIEnv *env, jclass /*clazz*/)
+{
+#ifndef ANDROID_PLUGIN_OPENGL
+ if (m_surface) {
+ env->DeleteGlobalRef(m_surface);
+ m_surface = 0;
+ }
+#else
+ Q_UNUSED(env);
+#endif
+
+ m_androidPlatformIntegration = 0;
+ delete m_androidAssetsFileEngineHandler;
+}
+
+static void terminateQt(JNIEnv *env, jclass /*clazz*/)
+{
+#ifndef ANDROID_PLUGIN_OPENGL
+ if (m_surface)
+ env->DeleteGlobalRef(m_surface);
+#endif
+ env->DeleteGlobalRef(m_applicationClass);
+ env->DeleteGlobalRef(m_classLoaderObject);
+ env->DeleteGlobalRef(m_resourcesObj);
+ env->DeleteGlobalRef(m_activityObject);
+ env->DeleteGlobalRef(m_bitmapClass);
+ env->DeleteGlobalRef(m_ARGB_8888_BitmapConfigValue);
+ env->DeleteGlobalRef(m_RGB_565_BitmapConfigValue);
+ env->DeleteGlobalRef(m_bitmapDrawableClass);
+}
+
+#ifdef ANDROID_PLUGIN_OPENGL
+#if __ANDROID_API__ < 9
+struct FakeNativeWindow
+{
+ long long dummyNativeWindow;// force 64 bits alignment
+};
+
+class FakeSurface: public FakeNativeWindow
+{
+public:
+ virtual void FakeSurfaceMethod()
+ {
+ fakeSurface = 0;
+ }
+
+ int fakeSurface;
+};
+
+EGLNativeWindowType ANativeWindow_fromSurface(JNIEnv *env, jobject jSurface)
+{
+ FakeSurface *surface = static_cast<FakeSurface *>(env->GetIntField(jSurface, m_surfaceFieldID));
+ return static_cast<EGLNativeWindowType>(static_cast<FakeNativeWindow*>(surface));
+}
+#endif // __ANDROID_API__ < 9
+#endif // ANDROID_PLUGIN_OPENGL
+
+static void setSurface(JNIEnv *env, jobject /*thiz*/, jobject jSurface)
+{
+#ifndef ANDROID_PLUGIN_OPENGL
+ if (m_surface)
+ env->DeleteGlobalRef(m_surface);
+ m_surface = env->NewGlobalRef(jSurface);
+#else
+ m_surfaceMutex.lock();
+ EGLNativeWindowType nativeWindow = ANativeWindow_fromSurface(env, jSurface);
+ bool sameNativeWindow = (nativeWindow != 0 && nativeWindow == m_nativeWindow);
+
+ m_nativeWindow = nativeWindow;
+ if (m_waitForWindow)
+ m_waitForWindowSemaphore.release();
+ if (m_androidPlatformIntegration && !sameNativeWindow) {
+ m_surfaceMutex.unlock();
+ m_androidPlatformIntegration->surfaceChanged();
+ } else if (m_androidPlatformIntegration && sameNativeWindow) {
+ QAndroidOpenGLPlatformWindow *window = m_androidPlatformIntegration->primaryWindow();
+ QPlatformScreen *screen = m_androidPlatformIntegration->screen();
+ QSize size = QtAndroid::nativeWindowSize();
+
+ QRect geometry(QPoint(0, 0), size);
+ QWindowSystemInterface::handleScreenAvailableGeometryChange(screen->screen(), geometry);
+ QWindowSystemInterface::handleScreenGeometryChange(screen->screen(), geometry);
+
+ if (window != 0) {
+ window->lock();
+ window->scheduleResize(size);
+
+ QWindowSystemInterface::handleExposeEvent(window->window(),
+ QRegion(window->window()->geometry()));
+ window->unlock();
+ }
+
+ m_surfaceMutex.unlock();
+ } else {
+ m_surfaceMutex.unlock();
+ }
+#endif // for #ifndef ANDROID_PLUGIN_OPENGL
+}
+
+static void destroySurface(JNIEnv *env, jobject /*thiz*/)
+{
+#ifndef ANDROID_PLUGIN_OPENGL
+ if (m_surface) {
+ env->DeleteGlobalRef(m_surface);
+ m_surface = 0;
+ }
+#else
+ Q_UNUSED(env);
+ m_nativeWindow = 0;
+ if (m_androidPlatformIntegration != 0)
+ m_androidPlatformIntegration->invalidateNativeSurface();
+#endif
+}
+
+static void setDisplayMetrics(JNIEnv */*env*/, jclass /*clazz*/,
+ jint /*widthPixels*/, jint /*heightPixels*/,
+ jint desktopWidthPixels, jint desktopHeightPixels,
+ jdouble xdpi, jdouble ydpi, jdouble scaledDensity)
+{
+ m_desktopWidthPixels = desktopWidthPixels;
+ m_desktopHeightPixels = desktopHeightPixels;
+ m_scaledDensity = scaledDensity;
+
+ if (!m_androidPlatformIntegration) {
+ QAndroidPlatformIntegration::setDefaultDisplayMetrics(desktopWidthPixels,desktopHeightPixels,
+ qRound(double(desktopWidthPixels) / xdpi * 25.4),
+ qRound(double(desktopHeightPixels) / ydpi * 25.4));
+ } else {
+ m_androidPlatformIntegration->setDisplayMetrics(qRound(double(desktopWidthPixels) / xdpi * 25.4),
+ qRound(double(desktopHeightPixels) / ydpi * 25.4));
+ m_androidPlatformIntegration->setDesktopSize(desktopWidthPixels, desktopHeightPixels);
+ }
+}
+
+static void lockSurface(JNIEnv */*env*/, jobject /*thiz*/)
+{
+ m_surfaceMutex.lock();
+}
+
+static void unlockSurface(JNIEnv */*env*/, jobject /*thiz*/)
+{
+ m_surfaceMutex.unlock();
+}
+
+static void updateWindow(JNIEnv */*env*/, jobject /*thiz*/)
+{
+ if (!m_androidPlatformIntegration)
+ return;
+
+ if (QGuiApplication::instance() != 0) {
+ foreach (QWindow *w, QGuiApplication::topLevelWindows())
+ QWindowSystemInterface::handleExposeEvent(w, QRegion(w->geometry()));
+ }
+
+#ifndef ANDROID_PLUGIN_OPENGL
+ QAndroidPlatformScreen *screen = static_cast<QAndroidPlatformScreen *>(m_androidPlatformIntegration->screen());
+ QMetaObject::invokeMethod(screen, "setDirty", Qt::QueuedConnection, Q_ARG(QRect,screen->geometry()));
+#else
+ qWarning("updateWindow: Dirty screen not implemented yet on OpenGL");
+#endif
+}
+
+static void handleOrientationChanged(JNIEnv */*env*/, jobject /*thiz*/, jint newOrientation)
+{
+ if (m_androidPlatformIntegration == 0)
+ return;
+
+ Qt::ScreenOrientation screenOrientation = newOrientation == 1
+ ? Qt::PortraitOrientation
+ : Qt::LandscapeOrientation;
+ QPlatformScreen *screen = m_androidPlatformIntegration->screen();
+ QWindowSystemInterface::handleScreenOrientationChange(screen->screen(),
+ screenOrientation);
+}
+
+static JNINativeMethod methods[] = {
+ {"startQtAndroidPlugin", "()Z", (void *)startQtAndroidPlugin},
+ {"startQtApplication", "(Ljava/lang/String;Ljava/lang/String;)V", (void *)startQtApplication},
+ {"pauseQtApp", "()V", (void *)pauseQtApp},
+ {"resumeQtApp", "()V", (void *)resumeQtApp},
+ {"quitQtAndroidPlugin", "()V", (void *)quitQtAndroidPlugin},
+ {"terminateQt", "()V", (void *)terminateQt},
+ {"setDisplayMetrics", "(IIIIDDD)V", (void *)setDisplayMetrics},
+ {"setSurface", "(Ljava/lang/Object;)V", (void *)setSurface},
+ {"destroySurface", "()V", (void *)destroySurface},
+ {"lockSurface", "()V", (void *)lockSurface},
+ {"unlockSurface", "()V", (void *)unlockSurface},
+ {"updateWindow", "()V", (void *)updateWindow},
+ {"handleOrientationChanged", "(I)V", (void *)handleOrientationChanged}
+};
+
+#define FIND_AND_CHECK_CLASS(CLASS_NAME) \
+clazz = env->FindClass(CLASS_NAME); \
+if (!clazz) { \
+ __android_log_print(ANDROID_LOG_FATAL, m_qtTag, m_classErrorMsg, CLASS_NAME); \
+ return JNI_FALSE; \
+}
+
+#define GET_AND_CHECK_METHOD(VAR, CLASS, METHOD_NAME, METHOD_SIGNATURE) \
+VAR = env->GetMethodID(CLASS, METHOD_NAME, METHOD_SIGNATURE); \
+if (!VAR) { \
+ __android_log_print(ANDROID_LOG_FATAL, m_qtTag, m_methodErrorMsg, METHOD_NAME, METHOD_SIGNATURE); \
+ return JNI_FALSE; \
+}
+
+#define GET_AND_CHECK_STATIC_METHOD(VAR, CLASS, METHOD_NAME, METHOD_SIGNATURE) \
+VAR = env->GetStaticMethodID(CLASS, METHOD_NAME, METHOD_SIGNATURE); \
+if (!VAR) { \
+ __android_log_print(ANDROID_LOG_FATAL, m_qtTag, m_methodErrorMsg, METHOD_NAME, METHOD_SIGNATURE); \
+ return JNI_FALSE; \
+}
+
+#define GET_AND_CHECK_FIELD(VAR, CLASS, FIELD_NAME, FIELD_SIGNATURE) \
+VAR = env->GetFieldID(CLASS, FIELD_NAME, FIELD_SIGNATURE); \
+if (!VAR) { \
+ __android_log_print(ANDROID_LOG_FATAL, m_qtTag, m_methodErrorMsg, FIELD_NAME, FIELD_SIGNATURE); \
+ return JNI_FALSE; \
+}
+
+#define GET_AND_CHECK_STATIC_FIELD(VAR, CLASS, FIELD_NAME, FIELD_SIGNATURE) \
+VAR = env->GetStaticFieldID(CLASS, FIELD_NAME, FIELD_SIGNATURE); \
+if (!VAR) { \
+ __android_log_print(ANDROID_LOG_FATAL, m_qtTag, m_methodErrorMsg, FIELD_NAME, FIELD_SIGNATURE); \
+ return JNI_FALSE; \
+}
+
+static int registerNatives(JNIEnv *env)
+{
+ jclass clazz;
+ FIND_AND_CHECK_CLASS("org/qtproject/qt5/android/QtNative");
+ m_applicationClass = static_cast<jclass>(env->NewGlobalRef(clazz));
+
+ if (env->RegisterNatives(m_applicationClass, methods, sizeof(methods) / sizeof(methods[0])) < 0) {
+ __android_log_print(ANDROID_LOG_FATAL,"Qt", "RegisterNatives failed");
+ return JNI_FALSE;
+ }
+
+ GET_AND_CHECK_STATIC_METHOD(m_redrawSurfaceMethodID, m_applicationClass, "redrawSurface", "(IIII)V");
+
+#ifdef ANDROID_PLUGIN_OPENGL
+ FIND_AND_CHECK_CLASS("android/view/Surface");
+#if __ANDROID_API__ < 9
+# define ANDROID_VIEW_SURFACE_JNI_ID "mSurface"
+#else
+# define ANDROID_VIEW_SURFACE_JNI_ID "mNativeSurface"
+#endif
+ GET_AND_CHECK_FIELD(m_surfaceFieldID, clazz, ANDROID_VIEW_SURFACE_JNI_ID, "I");
+#endif
+
+ jmethodID methodID;
+ GET_AND_CHECK_STATIC_METHOD(methodID, m_applicationClass, "activity", "()Landroid/app/Activity;");
+ jobject activityObject = env->CallStaticObjectMethod(m_applicationClass, methodID);
+ m_activityObject = env->NewGlobalRef(activityObject);
+ GET_AND_CHECK_STATIC_METHOD(methodID, m_applicationClass, "classLoader", "()Ljava/lang/ClassLoader;");
+ m_classLoaderObject = env->NewGlobalRef(env->CallStaticObjectMethod(m_applicationClass, methodID));
+
+ clazz = env->GetObjectClass(m_classLoaderObject);
+ GET_AND_CHECK_METHOD(m_loadClassMethodID, clazz, "loadClass", "(Ljava/lang/String;)Ljava/lang/Class;");
+
+ FIND_AND_CHECK_CLASS("android/content/ContextWrapper");
+ GET_AND_CHECK_METHOD(methodID, clazz, "getAssets", "()Landroid/content/res/AssetManager;");
+ m_assetManager = AAssetManager_fromJava(env, env->CallObjectMethod(activityObject, methodID));
+
+ GET_AND_CHECK_METHOD(methodID, clazz, "getResources", "()Landroid/content/res/Resources;");
+ m_resourcesObj = env->NewGlobalRef(env->CallObjectMethod(activityObject, methodID));
+
+ FIND_AND_CHECK_CLASS("android/graphics/Bitmap");
+ m_bitmapClass = static_cast<jclass>(env->NewGlobalRef(clazz));
+ GET_AND_CHECK_STATIC_METHOD(m_createBitmapMethodID, m_bitmapClass
+ , "createBitmap", "(IILandroid/graphics/Bitmap$Config;)Landroid/graphics/Bitmap;");
+
+ FIND_AND_CHECK_CLASS("android/graphics/Bitmap$Config");
+ jfieldID fieldId;
+ GET_AND_CHECK_STATIC_FIELD(fieldId, clazz, "ARGB_8888", "Landroid/graphics/Bitmap$Config;");
+ m_ARGB_8888_BitmapConfigValue = env->NewGlobalRef(env->GetStaticObjectField(clazz, fieldId));
+ GET_AND_CHECK_STATIC_FIELD(fieldId, clazz, "RGB_565", "Landroid/graphics/Bitmap$Config;");
+ m_RGB_565_BitmapConfigValue = env->NewGlobalRef(env->GetStaticObjectField(clazz, fieldId));
+
+ FIND_AND_CHECK_CLASS("android/graphics/drawable/BitmapDrawable");
+ m_bitmapDrawableClass = static_cast<jclass>(env->NewGlobalRef(clazz));
+ GET_AND_CHECK_METHOD(m_bitmapDrawableConstructorMethodID,
+ m_bitmapDrawableClass,
+ "<init>",
+ "(Landroid/content/res/Resources;Landroid/graphics/Bitmap;)V");
+
+ return JNI_TRUE;
+}
+
+Q_DECL_EXPORT jint JNICALL JNI_OnLoad(JavaVM *vm, void */*reserved*/)
+{
+ typedef union {
+ JNIEnv *nativeEnvironment;
+ void *venv;
+ } UnionJNIEnvToVoid;
+
+ __android_log_print(ANDROID_LOG_INFO, "Qt", "qt start");
+ UnionJNIEnvToVoid uenv;
+ uenv.venv = NULL;
+ m_javaVM = 0;
+
+ if (vm->GetEnv(&uenv.venv, JNI_VERSION_1_4) != JNI_OK) {
+ __android_log_print(ANDROID_LOG_FATAL, "Qt", "GetEnv failed");
+ return -1;
+ }
+
+ JNIEnv *env = uenv.nativeEnvironment;
+ if (!registerNatives(env)
+ || !QtAndroidInput::registerNatives(env)
+ || !QtAndroidClipboard::registerNatives(env)
+ || !QtAndroidMenu::registerNatives(env)) {
+ __android_log_print(ANDROID_LOG_FATAL, "Qt", "registerNatives failed");
+ return -1;
+ }
+
+ m_javaVM = vm;
+ return JNI_VERSION_1_4;
+}
diff --git a/src/plugins/platforms/android/src/androidjnimain.h b/src/plugins/platforms/android/src/androidjnimain.h
new file mode 100644
index 0000000000..f75df55e02
--- /dev/null
+++ b/src/plugins/platforms/android/src/androidjnimain.h
@@ -0,0 +1,122 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef ANDROID_APP_H
+#define ANDROID_APP_H
+
+#include <android/log.h>
+
+#ifdef ANDROID_PLUGIN_OPENGL
+# include <EGL/eglplatform.h>
+#endif
+
+#include <QtCore/qsize.h>
+
+#include <jni.h>
+#include <android/asset_manager.h>
+
+class QImage;
+class QRect;
+class QPoint;
+class QThread;
+class QAndroidPlatformIntegration;
+class QWidget;
+class QString;
+class QWindow;
+
+namespace QtAndroid
+{
+ QAndroidPlatformIntegration *androidPlatformIntegration();
+ void setAndroidPlatformIntegration(QAndroidPlatformIntegration *androidPlatformIntegration);
+ void setQtThread(QThread *thread);
+
+ void setFullScreen(QWidget *widget);
+
+#ifndef ANDROID_PLUGIN_OPENGL
+ void flushImage(const QPoint &pos, const QImage &image, const QRect &rect);
+#else
+ EGLNativeWindowType nativeWindow(bool waitToCreate = true);
+ QSize nativeWindowSize();
+#endif
+
+ QWindow *topLevelWindowAt(const QPoint &globalPos);
+ int desktopWidthPixels();
+ int desktopHeightPixels();
+ double scaledDensity();
+ JavaVM *javaVM();
+ jclass findClass(const QString &className, JNIEnv *env);
+ AAssetManager *assetManager();
+ jclass applicationClass();
+ jobject activity();
+
+ jobject createBitmap(QImage img, JNIEnv *env = 0);
+ jobject createBitmapDrawable(jobject bitmap, JNIEnv *env = 0);
+
+ struct AttachedJNIEnv
+ {
+ AttachedJNIEnv()
+ {
+ attached = false;
+ if (QtAndroid::javaVM()->GetEnv((void**)&jniEnv, JNI_VERSION_1_6) < 0) {
+ if (QtAndroid::javaVM()->AttachCurrentThread(&jniEnv, NULL) < 0) {
+ __android_log_print(ANDROID_LOG_ERROR, "Qt", "AttachCurrentThread failed");
+ jniEnv = 0;
+ return;
+ }
+ attached = true;
+ }
+ }
+
+ ~AttachedJNIEnv()
+ {
+ if (attached)
+ QtAndroid::javaVM()->DetachCurrentThread();
+ }
+ bool attached;
+ JNIEnv *jniEnv;
+ };
+ const char *classErrorMsgFmt();
+ const char *methodErrorMsgFmt();
+ const char *qtTagText();
+
+}
+#endif // ANDROID_APP_H
diff --git a/src/plugins/platforms/android/src/androidjnimenu.cpp b/src/plugins/platforms/android/src/androidjnimenu.cpp
new file mode 100644
index 0000000000..bb180347c1
--- /dev/null
+++ b/src/plugins/platforms/android/src/androidjnimenu.cpp
@@ -0,0 +1,422 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "androidjnimenu.h"
+#include "androidjnimain.h"
+#include <qmutex.h>
+#include <qset.h>
+#include <qqueue.h>
+#include <android/log.h>
+#include "qandroidplatformmenubar.h"
+#include "qandroidplatformmenu.h"
+#include <qandroidplatformmenuitem.h>
+
+using namespace QtAndroid;
+
+namespace QtAndroidMenu
+{
+ static QQueue<QAndroidPlatformMenu *> pendingContextMenus;
+ static QAndroidPlatformMenu *visibleMenu = 0;
+ static QMutex visibleMenuMutex(QMutex::Recursive);
+
+ static QSet<QAndroidPlatformMenuBar *> menuBars;
+ static QAndroidPlatformMenuBar *visibleMenuBar = 0;
+ static QWindow *activeTopLevelWindow = 0;
+ static QMutex menuBarMutex(QMutex::Recursive);
+
+ static jmethodID openContextMenuMethodID = 0;
+ static jmethodID closeContextMenuMethodID = 0;
+ static jmethodID resetOptionsMenuMethodID = 0;
+
+ static jmethodID clearMenuMethodID = 0;
+ static jmethodID addMenuItemMethodID = 0;
+ static int menuNoneValue = 0;
+ static jmethodID setHeaderTitleContextMenuMethodID = 0;
+
+ static jmethodID setCheckableMenuItemMethodID = 0;
+ static jmethodID setCheckedMenuItemMethodID = 0;
+ static jmethodID setEnabledMenuItemMethodID = 0;
+ static jmethodID setIconMenuItemMethodID = 0;
+ static jmethodID setVisibleMenuItemMethodID = 0;
+
+ void resetMenuBar()
+ {
+ AttachedJNIEnv env;
+ if (env.jniEnv)
+ env.jniEnv->CallStaticVoidMethod(applicationClass(), resetOptionsMenuMethodID);
+ }
+
+ void showContextMenu(QAndroidPlatformMenu *menu, JNIEnv *env)
+ {
+ QMutexLocker lock(&visibleMenuMutex);
+ if (visibleMenu) {
+ pendingContextMenus.enqueue(menu);
+ } else {
+ visibleMenu = menu;
+ menu->aboutToShow();
+ if (env) {
+ env->CallStaticVoidMethod(applicationClass(), openContextMenuMethodID);
+ } else {
+ AttachedJNIEnv aenv;
+ if (aenv.jniEnv)
+ aenv.jniEnv->CallStaticVoidMethod(applicationClass(), openContextMenuMethodID);
+ }
+ }
+ }
+
+ void hideContextMenu(QAndroidPlatformMenu *menu)
+ {
+ QMutexLocker lock(&visibleMenuMutex);
+ if (visibleMenu == menu) {
+ AttachedJNIEnv env;
+ if (env.jniEnv)
+ env.jniEnv->CallStaticVoidMethod(applicationClass(), openContextMenuMethodID);
+ } else {
+ pendingContextMenus.removeOne(menu);
+ }
+ }
+
+ void syncMenu(QAndroidPlatformMenu */*menu*/)
+ {
+// QMutexLocker lock(&visibleMenuMutex);
+// if (visibleMenu == menu)
+// {
+// hideContextMenu(menu);
+// showContextMenu(menu);
+// }
+ }
+
+ void androidPlatformMenuDestroyed(QAndroidPlatformMenu *menu)
+ {
+ QMutexLocker lock(&visibleMenuMutex);
+ if (visibleMenu == menu)
+ visibleMenu = 0;
+ }
+
+ void setMenuBar(QAndroidPlatformMenuBar *menuBar, QWindow *window)
+ {
+ if (activeTopLevelWindow == window && visibleMenuBar != menuBar) {
+ visibleMenuBar = menuBar;
+ resetMenuBar();
+ }
+ }
+
+ void setActiveTopLevelWindow(QWindow *window)
+ {
+ QMutexLocker lock(&menuBarMutex);
+ if (activeTopLevelWindow == window)
+ return;
+
+ visibleMenuBar = 0;
+ activeTopLevelWindow = window;
+#ifdef ANDROID_PLUGIN_OPENGL
+ //only one toplevel window, so the menu bar always belongs to us
+ if (menuBars.size() == 1) {
+ visibleMenuBar = *menuBars.constBegin(); //since QSet doesn't have first()
+ } else
+#endif
+ foreach (QAndroidPlatformMenuBar *menuBar, menuBars) {
+ if (menuBar->parentWindow() == window) {
+ visibleMenuBar = menuBar;
+ break;
+ }
+ }
+
+ resetMenuBar();
+ }
+
+ void addMenuBar(QAndroidPlatformMenuBar *menuBar)
+ {
+ QMutexLocker lock(&menuBarMutex);
+ menuBars.insert(menuBar);
+ }
+
+ void removeMenuBar(QAndroidPlatformMenuBar *menuBar)
+ {
+ QMutexLocker lock(&menuBarMutex);
+ menuBars.remove(menuBar);
+ if (visibleMenuBar == menuBar)
+ resetMenuBar();
+ }
+
+ static QString removeAmpersandEscapes(QString s)
+ {
+ int i = 0;
+ while (i < s.size()) {
+ ++i;
+ if (s.at(i-1) != QLatin1Char('&'))
+ continue;
+ if (i < s.size() && s.at(i) == QLatin1Char('&'))
+ ++i;
+ s.remove(i-1,1);
+ }
+ return s.trimmed();
+ }
+
+ static void fillMenuItem(JNIEnv *env, jobject menuItem, bool checkable, bool checked, bool enabled, bool visible, const QIcon &icon=QIcon())
+ {
+ env->CallObjectMethod(menuItem, setCheckableMenuItemMethodID, checkable);
+ env->CallObjectMethod(menuItem, setCheckedMenuItemMethodID, checked);
+ env->CallObjectMethod(menuItem, setEnabledMenuItemMethodID, enabled);
+
+ if (!icon.isNull()) {
+ int sz = qMax(36, qgetenv("QT_ANDROID_APP_ICON_SIZE").toInt());
+ QImage img = icon.pixmap(QSize(sz,sz),
+ enabled
+ ? QIcon::Normal
+ : QIcon::Disabled,
+ QIcon::On).toImage();
+ env->CallObjectMethod(menuItem,
+ setIconMenuItemMethodID,
+ createBitmapDrawable(createBitmap(img, env), env));
+ }
+
+ env->CallObjectMethod(menuItem, setVisibleMenuItemMethodID, visible);
+ }
+
+ static int addAllMenuItemsToMenu(JNIEnv *env, jobject menu, QAndroidPlatformMenu *platformMenu) {
+ int order = 0;
+ QMutexLocker lock(platformMenu->menuItemsMutex());
+ foreach (QAndroidPlatformMenuItem *item, platformMenu->menuItems()) {
+ if (item->isSeparator())
+ continue;
+ QString itemText = removeAmpersandEscapes(item->text());
+ jstring jtext = env->NewString(reinterpret_cast<const jchar *>(itemText.data()),
+ itemText.length());
+ jobject menuItem = env->CallObjectMethod(menu,
+ addMenuItemMethodID,
+ menuNoneValue,
+ int(item->tag()),
+ order++,
+ jtext);
+ env->DeleteLocalRef(jtext);
+ fillMenuItem(env,
+ menuItem,
+ item->isCheckable(),
+ item->isChecked(),
+ item->isEnabled(),
+ item->isVisible(),
+ item->icon());
+ }
+
+ return order;
+ }
+
+ static jboolean onPrepareOptionsMenu(JNIEnv *env, jobject /*thiz*/, jobject menu)
+ {
+ env->CallVoidMethod(menu, clearMenuMethodID);
+ QMutexLocker lock(&menuBarMutex);
+ if (!visibleMenuBar)
+ return JNI_FALSE;
+
+ const QAndroidPlatformMenuBar::PlatformMenusType &menus = visibleMenuBar->menus();
+ int order = 0;
+ QMutexLocker lockMenuBarMutex(visibleMenuBar->menusListMutex());
+ if (menus.size() == 1) { // Expand the menu
+ order = addAllMenuItemsToMenu(env, menu, static_cast<QAndroidPlatformMenu *>(menus.front()));
+ } else {
+ foreach (QAndroidPlatformMenu *item, menus) {
+ QString itemText = removeAmpersandEscapes(item->text());
+ jstring jtext = env->NewString(reinterpret_cast<const jchar *>(itemText.data()),
+ itemText.length());
+ jobject menuItem = env->CallObjectMethod(menu,
+ addMenuItemMethodID,
+ menuNoneValue,
+ int(item->tag()),
+ order++,
+ jtext);
+ env->DeleteLocalRef(jtext);
+
+ fillMenuItem(env,
+ menuItem,
+ false,
+ false,
+ item->isEnabled(),
+ item->isVisible(),
+ item->icon());
+ }
+ }
+ return order ? JNI_TRUE : JNI_FALSE;
+ }
+
+ static jboolean onOptionsItemSelected(JNIEnv *env, jobject /*thiz*/, jint menuId, jboolean checked)
+ {
+ QMutexLocker lock(&menuBarMutex);
+ if (!visibleMenuBar)
+ return JNI_FALSE;
+
+ const QAndroidPlatformMenuBar::PlatformMenusType &menus = visibleMenuBar->menus();
+ if (menus.size() == 1) { // Expanded menu
+ QAndroidPlatformMenuItem *item = static_cast<QAndroidPlatformMenuItem *>(menus.front()->menuItemForTag(menuId));
+ if (item) {
+ if (item->menu()) {
+ showContextMenu(item->menu(), env);
+ } else {
+ if (item->isCheckable())
+ item->setChecked(checked);
+ item->activated();
+ }
+ }
+ } else {
+ QAndroidPlatformMenu *menu = static_cast<QAndroidPlatformMenu *>(visibleMenuBar->menuForTag(menuId));
+ if (menu)
+ showContextMenu(menu, env);
+ }
+
+ return JNI_TRUE;
+ }
+
+ static void onOptionsMenuClosed(JNIEnv */*env*/, jobject /*thiz*/, jobject /*menu*/)
+ {
+ }
+
+ static void onCreateContextMenu(JNIEnv *env, jobject /*thiz*/, jobject menu)
+ {
+ env->CallVoidMethod(menu, clearMenuMethodID);
+ QMutexLocker lock(&visibleMenuMutex);
+ if (!visibleMenu)
+ return;
+
+ QString menuText = removeAmpersandEscapes(visibleMenu->text());
+ jstring jtext = env->NewString(reinterpret_cast<const jchar*>(menuText.data()),
+ menuText.length());
+ env->CallObjectMethod(menu, setHeaderTitleContextMenuMethodID, jtext);
+ env->DeleteLocalRef(jtext);
+ addAllMenuItemsToMenu(env, menu, visibleMenu);
+ }
+
+ static jboolean onContextItemSelected(JNIEnv *env, jobject /*thiz*/, jint menuId, jboolean checked)
+ {
+ QMutexLocker lock(&visibleMenuMutex);
+ QAndroidPlatformMenuItem * item = static_cast<QAndroidPlatformMenuItem *>(visibleMenu->menuItemForTag(menuId));
+ if (item) {
+ if (item->menu()) {
+ showContextMenu(item->menu(), env);
+ } else {
+ if (item->isCheckable())
+ item->setChecked(checked);
+ item->activated();
+ }
+ }
+ return JNI_TRUE;
+ }
+
+ static void onContextMenuClosed(JNIEnv *env, jobject /*thiz*/, jobject /*menu*/)
+ {
+ QMutexLocker lock(&visibleMenuMutex);
+ if (!visibleMenu)
+ return;
+ visibleMenu->aboutToHide();
+ visibleMenu = 0;
+ if (!pendingContextMenus.empty())
+ showContextMenu(pendingContextMenus.dequeue(), env);
+ }
+
+ static JNINativeMethod methods[] = {
+ {"onPrepareOptionsMenu", "(Landroid/view/Menu;)Z", (void *)onPrepareOptionsMenu},
+ {"onOptionsItemSelected", "(IZ)Z", (void *)onOptionsItemSelected},
+ {"onOptionsMenuClosed", "(Landroid/view/Menu;)V", (void*)onOptionsMenuClosed},
+ {"onCreateContextMenu", "(Landroid/view/ContextMenu;)V", (void *)onCreateContextMenu},
+ {"onContextItemSelected", "(IZ)Z", (void *)onContextItemSelected},
+ {"onContextMenuClosed", "(Landroid/view/Menu;)V", (void*)onContextMenuClosed},
+ };
+
+#define FIND_AND_CHECK_CLASS(CLASS_NAME) \
+ clazz = env->FindClass(CLASS_NAME); \
+ if (!clazz) { \
+ __android_log_print(ANDROID_LOG_FATAL, qtTagText(), classErrorMsgFmt(), CLASS_NAME); \
+ return false; \
+ }
+
+#define GET_AND_CHECK_METHOD(VAR, CLASS, METHOD_NAME, METHOD_SIGNATURE) \
+ VAR = env->GetMethodID(CLASS, METHOD_NAME, METHOD_SIGNATURE); \
+ if (!VAR) { \
+ __android_log_print(ANDROID_LOG_FATAL, qtTagText(), methodErrorMsgFmt(), METHOD_NAME, METHOD_SIGNATURE); \
+ return false; \
+ }
+
+#define GET_AND_CHECK_STATIC_METHOD(VAR, CLASS, METHOD_NAME, METHOD_SIGNATURE) \
+ VAR = env->GetStaticMethodID(CLASS, METHOD_NAME, METHOD_SIGNATURE); \
+ if (!VAR) { \
+ __android_log_print(ANDROID_LOG_FATAL, qtTagText(), methodErrorMsgFmt(), METHOD_NAME, METHOD_SIGNATURE); \
+ return false; \
+ }
+
+#define GET_AND_CHECK_STATIC_FIELD(VAR, CLASS, FIELD_NAME, FIELD_SIGNATURE) \
+ VAR = env->GetStaticFieldID(CLASS, FIELD_NAME, FIELD_SIGNATURE); \
+ if (!VAR) { \
+ __android_log_print(ANDROID_LOG_FATAL, qtTagText(), methodErrorMsgFmt(), FIELD_NAME, FIELD_SIGNATURE); \
+ return false; \
+ }
+
+ bool registerNatives(JNIEnv *env)
+ {
+ jclass appClass = applicationClass();
+
+ if (env->RegisterNatives(appClass, methods, sizeof(methods) / sizeof(methods[0])) < 0) {
+ __android_log_print(ANDROID_LOG_FATAL,"Qt", "RegisterNatives failed");
+ return false;
+ }
+
+ GET_AND_CHECK_STATIC_METHOD(openContextMenuMethodID, appClass, "openContextMenu", "()V");
+ GET_AND_CHECK_STATIC_METHOD(closeContextMenuMethodID, appClass, "closeContextMenu", "()V");
+ GET_AND_CHECK_STATIC_METHOD(resetOptionsMenuMethodID, appClass, "resetOptionsMenu", "()V");
+
+ jclass clazz;
+ FIND_AND_CHECK_CLASS("android/view/Menu");
+ GET_AND_CHECK_METHOD(clearMenuMethodID, clazz, "clear", "()V");
+ GET_AND_CHECK_METHOD(addMenuItemMethodID, clazz, "add", "(IIILjava/lang/CharSequence;)Landroid/view/MenuItem;");
+ jfieldID menuNoneFiledId;
+ GET_AND_CHECK_STATIC_FIELD(menuNoneFiledId, clazz, "NONE", "I");
+ menuNoneValue = env->GetStaticIntField(clazz, menuNoneFiledId);
+
+ FIND_AND_CHECK_CLASS("android/view/ContextMenu");
+ GET_AND_CHECK_METHOD(setHeaderTitleContextMenuMethodID, clazz, "setHeaderTitle","(Ljava/lang/CharSequence;)Landroid/view/ContextMenu;");
+
+ FIND_AND_CHECK_CLASS("android/view/MenuItem");
+ GET_AND_CHECK_METHOD(setCheckableMenuItemMethodID, clazz, "setCheckable", "(Z)Landroid/view/MenuItem;");
+ GET_AND_CHECK_METHOD(setCheckedMenuItemMethodID, clazz, "setChecked", "(Z)Landroid/view/MenuItem;");
+ GET_AND_CHECK_METHOD(setEnabledMenuItemMethodID, clazz, "setEnabled", "(Z)Landroid/view/MenuItem;");
+ GET_AND_CHECK_METHOD(setIconMenuItemMethodID, clazz, "setIcon", "(Landroid/graphics/drawable/Drawable;)Landroid/view/MenuItem;");
+ GET_AND_CHECK_METHOD(setVisibleMenuItemMethodID, clazz, "setVisible", "(Z)Landroid/view/MenuItem;");
+ return true;
+ }
+}
diff --git a/src/plugins/platforms/android/src/androidjnimenu.h b/src/plugins/platforms/android/src/androidjnimenu.h
new file mode 100644
index 0000000000..7c5422f67b
--- /dev/null
+++ b/src/plugins/platforms/android/src/androidjnimenu.h
@@ -0,0 +1,69 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef ANDROIDJNIMENU_H
+#define ANDROIDJNIMENU_H
+
+#include <jni.h>
+
+class QAndroidPlatformMenuBar;
+class QAndroidPlatformMenu;
+class QAndroidPlatformMenuItem;
+class QWindow;
+
+namespace QtAndroidMenu
+{
+ // Menu support
+ void showContextMenu(QAndroidPlatformMenu *menu, JNIEnv *env = 0);
+ void hideContextMenu(QAndroidPlatformMenu *menu);
+ void syncMenu(QAndroidPlatformMenu *menu);
+ void androidPlatformMenuDestroyed(QAndroidPlatformMenu *menu);
+
+ void setMenuBar(QAndroidPlatformMenuBar *menuBar, QWindow *window);
+ void setActiveTopLevelWindow(QWindow *window);
+ void addMenuBar(QAndroidPlatformMenuBar *menuBar);
+ void removeMenuBar(QAndroidPlatformMenuBar *menuBar);
+
+ // Menu support
+ bool registerNatives(JNIEnv *env);
+}
+
+#endif // ANDROIDJNIMENU_H
diff --git a/src/plugins/platforms/android/src/androidplatformplugin.cpp b/src/plugins/platforms/android/src/androidplatformplugin.cpp
new file mode 100644
index 0000000000..71c5096e16
--- /dev/null
+++ b/src/plugins/platforms/android/src/androidplatformplugin.cpp
@@ -0,0 +1,66 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <qpa/qplatformintegrationplugin.h>
+#include "qandroidplatformintegration.h"
+
+QT_BEGIN_NAMESPACE
+
+class QAndroidPlatformIntegrationPlugin: public QPlatformIntegrationPlugin
+{
+ Q_OBJECT
+ Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.1" FILE "android.json")
+public:
+ QPlatformIntegration *create(const QString &key, const QStringList &paramList);
+};
+
+
+QPlatformIntegration *QAndroidPlatformIntegrationPlugin::create(const QString &key, const QStringList &paramList)
+{
+ Q_UNUSED(paramList);
+ if (key.toLower() == "android")
+ return new QAndroidPlatformIntegration(paramList);
+ return 0;
+}
+
+QT_END_NAMESPACE
+#include "androidplatformplugin.moc"
+
diff --git a/mkspecs/common/ios/qplatformdefs.h b/src/plugins/platforms/android/src/opengl/qandroidopenglcontext.cpp
index cdefd3dba0..aa8ee57341 100644
--- a/mkspecs/common/ios/qplatformdefs.h
+++ b/src/plugins/platforms/android/src/opengl/qandroidopenglcontext.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the qmake spec of the Qt Toolkit.
+** This file is part of the plugins of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -39,59 +39,40 @@
**
****************************************************************************/
-#ifndef QPLATFORMDEFS_H
-#define QPLATFORMDEFS_H
-
-// Get Qt defines/settings
-
-#include "qglobal.h"
-
-// Set any POSIX/XOPEN defines at the top of this file to turn on specific APIs
-
-#include <unistd.h>
-
-
-// We are hot - unistd.h should have turned on the specific APIs we requested
-
-
-#include <pthread.h>
-#include <dirent.h>
-#include <fcntl.h>
-#include <grp.h>
-#include <pwd.h>
-#include <signal.h>
-#define QT_NO_LIBRARY_UNLOAD
-
-#include <sys/types.h>
-#include <sys/ioctl.h>
-#include <sys/ipc.h>
-#include <sys/time.h>
-#include <sys/shm.h>
-#include <sys/socket.h>
-#include <sys/stat.h>
-#include <sys/wait.h>
-#include <netinet/in.h>
-#ifndef QT_NO_IPV6IFNAME
-#include <net/if.h>
-#endif
-
-#include "../../common/posix/qplatformdefs.h"
-
-#undef QT_OPEN_LARGEFILE
-#undef QT_SOCKLEN_T
-#undef QT_SIGNAL_IGNORE
-
-#define QT_OPEN_LARGEFILE 0
-
-#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4)
-#define QT_SOCKLEN_T socklen_t
-#else
-#define QT_SOCKLEN_T int
-#endif
-
-#define QT_SIGNAL_IGNORE (void (*)(int))1
-
-#define QT_SNPRINTF ::snprintf
-#define QT_VSNPRINTF ::vsnprintf
-
-#endif // QPLATFORMDEFS_H
+#include "qandroidopenglcontext.h"
+#include "qandroidopenglplatformwindow.h"
+#include "qandroidplatformintegration.h"
+
+#include <QtCore/qdebug.h>
+#include <qpa/qwindowsysteminterface.h>
+
+QT_BEGIN_NAMESPACE
+
+QAndroidOpenGLContext::QAndroidOpenGLContext(const QAndroidPlatformIntegration *integration,
+ const QSurfaceFormat &format,
+ QPlatformOpenGLContext *share,
+ EGLDisplay display,
+ EGLenum eglApi)
+ : QEglFSContext(format, share, display, eglApi)
+ , m_platformIntegration(integration)
+{
+}
+
+void QAndroidOpenGLContext::swapBuffers(QPlatformSurface *surface)
+{
+ QEglFSContext::swapBuffers(surface);
+
+ QAndroidOpenGLPlatformWindow *primaryWindow = m_platformIntegration->primaryWindow();
+ if (primaryWindow == surface) {
+ primaryWindow->lock();
+ QSize size = primaryWindow->scheduledResize();
+ if (size.isValid()) {
+ QRect geometry(QPoint(0, 0), size);
+ primaryWindow->setGeometry(geometry);
+ primaryWindow->scheduleResize(QSize());
+ }
+ primaryWindow->unlock();
+ }
+}
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/android/src/opengl/qandroidopenglcontext.h b/src/plugins/platforms/android/src/opengl/qandroidopenglcontext.h
new file mode 100644
index 0000000000..c4c5a430ad
--- /dev/null
+++ b/src/plugins/platforms/android/src/opengl/qandroidopenglcontext.h
@@ -0,0 +1,68 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QANDROIDOPENGLCONTEXT_H
+#define QANDROIDOPENGLCONTEXT_H
+
+#include <QtCore/qreadwritelock.h>
+#include "qeglfscontext.h"
+
+QT_BEGIN_NAMESPACE
+
+class QAndroidPlatformIntegration;
+class QAndroidOpenGLContext : public QEglFSContext
+{
+public:
+ QAndroidOpenGLContext(const QAndroidPlatformIntegration *integration,
+ const QSurfaceFormat &format,
+ QPlatformOpenGLContext *share,
+ EGLDisplay display,
+ EGLenum eglApi = EGL_OPENGL_ES_API);
+
+ void swapBuffers(QPlatformSurface *surface);
+
+private:
+ const QAndroidPlatformIntegration *m_platformIntegration;
+};
+
+QT_END_NAMESPACE
+
+#endif // QANDROIDOPENGLCONTEXT_H
diff --git a/src/plugins/platforms/android/src/opengl/qandroidopenglplatformwindow.cpp b/src/plugins/platforms/android/src/opengl/qandroidopenglplatformwindow.cpp
new file mode 100644
index 0000000000..15c6559157
--- /dev/null
+++ b/src/plugins/platforms/android/src/opengl/qandroidopenglplatformwindow.cpp
@@ -0,0 +1,72 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qandroidopenglplatformwindow.h"
+#include "androidjnimain.h"
+#include <qpa/qwindowsysteminterface.h>
+
+QT_BEGIN_NAMESPACE
+
+QAndroidOpenGLPlatformWindow::QAndroidOpenGLPlatformWindow(QWindow *window)
+ : QEglFSWindow(window)
+{
+}
+
+bool QAndroidOpenGLPlatformWindow::isExposed() const
+{
+ return QtAndroid::nativeWindow(false) != 0 && QEglFSWindow::isExposed();
+}
+
+void QAndroidOpenGLPlatformWindow::invalidateSurface()
+{
+ QWindowSystemInterface::handleExposeEvent(window(), QRegion()); // Obscure event
+ QWindowSystemInterface::flushWindowSystemEvents();
+ QEglFSWindow::invalidateSurface();
+}
+
+void QAndroidOpenGLPlatformWindow::resetSurface()
+{
+ QEglFSWindow::resetSurface();
+ QWindowSystemInterface::handleExposeEvent(window(), QRegion(geometry())); // Expose event
+ QWindowSystemInterface::flushWindowSystemEvents();
+}
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/android/src/opengl/qandroidopenglplatformwindow.h b/src/plugins/platforms/android/src/opengl/qandroidopenglplatformwindow.h
new file mode 100644
index 0000000000..b835cb3246
--- /dev/null
+++ b/src/plugins/platforms/android/src/opengl/qandroidopenglplatformwindow.h
@@ -0,0 +1,73 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QANDROIDOPENGLPLATFORMWINDOW_H
+#define QANDROIDOPENGLPLATFORMWINDOW_H
+
+#include "qeglfswindow.h"
+#include <QtCore/qmutex.h>
+
+QT_BEGIN_NAMESPACE
+
+class QAndroidOpenGLPlatformWindow : public QEglFSWindow
+{
+public:
+ QAndroidOpenGLPlatformWindow(QWindow *window);
+
+ QSize scheduledResize() const { return m_scheduledResize; }
+ void scheduleResize(const QSize &size) { m_scheduledResize = size; }
+
+ void lock() { m_lock.lock(); }
+ void unlock() { m_lock.unlock(); }
+
+ bool isExposed() const;
+
+ void invalidateSurface();
+ void resetSurface();
+
+private:
+ QSize m_scheduledResize;
+ QMutex m_lock;
+};
+
+QT_END_NAMESPACE
+
+#endif // QANDROIDOPENGLPLATFORMWINDOW_H
diff --git a/src/plugins/platforms/android/src/opengl/qeglfshooks_android.cpp b/src/plugins/platforms/android/src/opengl/qeglfshooks_android.cpp
new file mode 100644
index 0000000000..4734d47eb3
--- /dev/null
+++ b/src/plugins/platforms/android/src/opengl/qeglfshooks_android.cpp
@@ -0,0 +1,139 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qeglfshooks.h"
+#include "androidjnimain.h"
+#include "qandroidplatformintegration.h"
+
+#include <android/native_window.h>
+#include <jni.h>
+
+QT_BEGIN_NAMESPACE
+
+class QEglFSAndroidHooks: public QEglFSHooks
+{
+public:
+ void platformInit();
+ void platformDestroy();
+ EGLNativeDisplayType platformDisplay() const;
+ QSize screenSize() const;
+ QSizeF physicalScreenSize() const;
+ QDpi logicalDpi() const;
+ int screenDepth() const;
+ QSurfaceFormat surfaceFormatFor(const QSurfaceFormat &inputFormat) const;
+ EGLNativeWindowType createNativeWindow(const QSize &size, const QSurfaceFormat &format);
+ void destroyNativeWindow(EGLNativeWindowType window);
+ bool hasCapability(QPlatformIntegration::Capability cap) const;
+};
+
+void QEglFSAndroidHooks::platformInit()
+{
+}
+
+void QEglFSAndroidHooks::platformDestroy()
+{
+}
+
+EGLNativeDisplayType QEglFSAndroidHooks::platformDisplay() const
+{
+ return EGL_DEFAULT_DISPLAY;
+}
+
+QSize QEglFSAndroidHooks::screenSize() const
+{
+ return QtAndroid::nativeWindowSize();
+}
+
+QSizeF QEglFSAndroidHooks::physicalScreenSize() const
+{
+ return QSizeF(QAndroidPlatformIntegration::m_defaultPhysicalSizeWidth, QAndroidPlatformIntegration::m_defaultPhysicalSizeHeight);
+}
+
+QDpi QEglFSAndroidHooks::logicalDpi() const
+{
+ qreal lDpi = QtAndroid::scaledDensity() * 100;
+ return QDpi(lDpi, lDpi);
+}
+
+
+EGLNativeWindowType QEglFSAndroidHooks::createNativeWindow(const QSize &size, const QSurfaceFormat &format)
+{
+ ANativeWindow *window = QtAndroid::nativeWindow();
+ if (window != 0)
+ ANativeWindow_acquire(window);
+
+ return window;
+}
+
+void QEglFSAndroidHooks::destroyNativeWindow(EGLNativeWindowType window)
+{
+ ANativeWindow_release(window);
+}
+
+bool QEglFSAndroidHooks::hasCapability(QPlatformIntegration::Capability capability) const
+{
+ switch (capability) {
+ case QPlatformIntegration::OpenGL: return true;
+ case QPlatformIntegration::ThreadedOpenGL: return true;
+ default: return false;
+ };
+}
+
+int QEglFSAndroidHooks::screenDepth() const
+{
+ // ### Hardcoded
+ return 32;
+}
+
+QSurfaceFormat QEglFSAndroidHooks::surfaceFormatFor(const QSurfaceFormat &inputFormat) const
+{
+ QSurfaceFormat ret(inputFormat);
+ ret.setAlphaBufferSize(8);
+ ret.setRedBufferSize(8);
+ ret.setGreenBufferSize(8);
+ ret.setBlueBufferSize(8);
+ return ret;
+}
+
+static QEglFSAndroidHooks eglFSAndroidHooks;
+QEglFSHooks *platformHooks = &eglFSAndroidHooks;
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/android/src/qandroidassetsfileenginehandler.cpp b/src/plugins/platforms/android/src/qandroidassetsfileenginehandler.cpp
new file mode 100644
index 0000000000..f3cb2586cc
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidassetsfileenginehandler.cpp
@@ -0,0 +1,288 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qandroidassetsfileenginehandler.h"
+#include "androidjnimain.h"
+
+#include <QCoreApplication>
+
+class AndroidAbstractFileEngineIterator: public QAbstractFileEngineIterator
+{
+public:
+ AndroidAbstractFileEngineIterator(QDir::Filters filters,
+ const QStringList &nameFilters,
+ AAssetDir *asset,
+ const QString &path)
+ : QAbstractFileEngineIterator(filters, nameFilters)
+ {
+ AAssetDir_rewind(asset);
+ const char *fileName;
+ while ((fileName = AAssetDir_getNextFileName(asset)))
+ m_items << fileName;
+ m_index = -1;
+ m_path = path;
+ }
+
+ virtual QFileInfo currentFileInfo() const
+ {
+ return QFileInfo(currentFilePath());
+ }
+
+ virtual QString currentFileName() const
+ {
+ if (m_index < 0 || m_index >= m_items.size())
+ return QString();
+ return m_items[m_index];
+ }
+
+ virtual QString currentFilePath() const
+ {
+ return m_path + currentFileName();
+ }
+
+ virtual bool hasNext() const
+ {
+ return m_items.size() && (m_index < m_items.size() - 1);
+ }
+
+ virtual QString next()
+ {
+ if (!hasNext())
+ return QString();
+ m_index++;
+ return currentFileName();
+ }
+
+private:
+ QString m_path;
+ QStringList m_items;
+ int m_index;
+};
+
+class AndroidAbstractFileEngine: public QAbstractFileEngine
+{
+public:
+ explicit AndroidAbstractFileEngine(AAsset *asset, const QString &fileName)
+ {
+ m_assetDir = 0;
+ m_assetFile = asset;
+ m_fileName = fileName;
+ }
+
+ explicit AndroidAbstractFileEngine(AAssetDir *asset, const QString &fileName)
+ {
+ m_assetFile = 0;
+ m_assetDir = asset;
+ m_fileName = fileName;
+ if (!m_fileName.endsWith(QChar(QLatin1Char('/'))))
+ m_fileName += "/";
+ }
+
+ ~AndroidAbstractFileEngine()
+ {
+ close();
+ if (m_assetDir)
+ AAssetDir_close(m_assetDir);
+ }
+
+ virtual bool open(QIODevice::OpenMode openMode)
+ {
+ if (m_assetFile)
+ return openMode & QIODevice::ReadOnly;
+ return false;
+ }
+
+ virtual bool close()
+ {
+ if (m_assetFile) {
+ AAsset_close(m_assetFile);
+ m_assetFile = 0;
+ return true;
+ }
+ return false;
+ }
+
+ virtual qint64 size() const
+ {
+ if (m_assetFile)
+ return AAsset_getLength(m_assetFile);
+ return -1;
+ }
+
+ virtual qint64 pos() const
+ {
+ if (m_assetFile)
+ return AAsset_seek(m_assetFile, 0, SEEK_CUR);
+ return -1;
+ }
+
+ virtual bool seek(qint64 pos)
+ {
+ if (m_assetFile)
+ return pos == AAsset_seek(m_assetFile, pos, SEEK_SET);
+ return false;
+ }
+
+ virtual qint64 read(char *data, qint64 maxlen)
+ {
+ if (m_assetFile)
+ return AAsset_read(m_assetFile, data, maxlen);
+ return -1;
+ }
+
+ virtual bool isSequential() const
+ {
+ return false;
+ }
+
+ virtual bool caseSensitive() const
+ {
+ return true;
+ }
+
+ virtual bool isRelativePath() const
+ {
+ return false;
+ }
+
+ virtual FileFlags fileFlags(FileFlags type = FileInfoAll) const
+ {
+ FileFlags flags(ReadOwnerPerm|ReadUserPerm|ReadGroupPerm|ReadOtherPerm|ExistsFlag);
+ if (m_assetFile)
+ flags |= FileType;
+ if (m_assetDir)
+ flags |= DirectoryType;
+
+ return type & flags;
+ }
+
+ virtual QString fileName(FileName file = DefaultName) const
+ {
+ int pos;
+ switch (file) {
+ case DefaultName:
+ case AbsoluteName:
+ case CanonicalName:
+ return m_fileName;
+ case BaseName:
+ if ((pos = m_fileName.lastIndexOf(QChar(QLatin1Char('/')))) != -1)
+ return m_fileName.mid(pos);
+ else
+ return m_fileName;
+ case PathName:
+ case AbsolutePathName:
+ case CanonicalPathName:
+ if ((pos = m_fileName.lastIndexOf(QChar(QLatin1Char('/')))) != -1)
+ return m_fileName.left(pos);
+ else
+ return m_fileName;
+ default:
+ return QString();
+ }
+ }
+
+ virtual void setFileName(const QString &file)
+ {
+ if (file == m_fileName)
+ return;
+
+ m_fileName = file;
+ if (!m_fileName.endsWith(QChar(QLatin1Char('/'))))
+ m_fileName += "/";
+
+ close();
+ }
+
+ virtual Iterator *beginEntryList(QDir::Filters filters, const QStringList &filterNames)
+ {
+ if (m_assetDir)
+ return new AndroidAbstractFileEngineIterator(filters, filterNames, m_assetDir, m_fileName);
+ return 0;
+ }
+
+private:
+ AAsset *m_assetFile;
+ AAssetDir *m_assetDir;
+ QString m_fileName;
+};
+
+
+AndroidAssetsFileEngineHandler::AndroidAssetsFileEngineHandler()
+{
+ m_assetManager = QtAndroid::assetManager();
+}
+
+AndroidAssetsFileEngineHandler::~AndroidAssetsFileEngineHandler()
+{
+}
+
+QAbstractFileEngine * AndroidAssetsFileEngineHandler::create(const QString &fileName) const
+{
+ if (fileName.isEmpty())
+ return 0;
+
+ if (!fileName.startsWith(QLatin1String("assets:/")))
+ return 0;
+
+ int prefixSize=8;
+
+ m_path.clear();
+ if (!fileName.endsWith(QLatin1Char('/'))) {
+ m_path = fileName.toUtf8();
+ AAsset *asset = AAssetManager_open(m_assetManager,
+ m_path.constData() + prefixSize,
+ AASSET_MODE_BUFFER);
+ if (asset)
+ return new AndroidAbstractFileEngine(asset, fileName);
+ }
+
+ if (!m_path.size())
+ m_path = fileName.left(fileName.length() - 1).toUtf8();
+
+ AAssetDir *assetDir = AAssetManager_openDir(m_assetManager, m_path.constData() + prefixSize);
+ if (assetDir) {
+ if (AAssetDir_getNextFileName(assetDir))
+ return new AndroidAbstractFileEngine(assetDir, fileName);
+ else
+ AAssetDir_close(assetDir);
+ }
+ return 0;
+}
diff --git a/src/plugins/platforms/android/src/qandroidassetsfileenginehandler.h b/src/plugins/platforms/android/src/qandroidassetsfileenginehandler.h
new file mode 100644
index 0000000000..9bff6a012e
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidassetsfileenginehandler.h
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QANDROIDASSETSFILEENGINEHANDLER_H
+#define QANDROIDASSETSFILEENGINEHANDLER_H
+
+#include <QtCore/private/qabstractfileengine_p.h>
+#include <android/asset_manager.h>
+
+class AndroidAssetsFileEngineHandler: public QAbstractFileEngineHandler
+{
+public:
+ AndroidAssetsFileEngineHandler();
+ virtual ~AndroidAssetsFileEngineHandler();
+ QAbstractFileEngine *create(const QString &fileName) const;
+
+private:
+ AAssetManager *m_assetManager;
+ mutable QByteArray m_path;
+};
+
+#endif // QANDROIDASSETSFILEENGINEHANDLER_H
diff --git a/src/plugins/platforms/android/src/qandroidinputcontext.cpp b/src/plugins/platforms/android/src/qandroidinputcontext.cpp
new file mode 100644
index 0000000000..2180560b04
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidinputcontext.cpp
@@ -0,0 +1,653 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <android/log.h>
+
+#include "qandroidinputcontext.h"
+#include "androidjnimain.h"
+#include "androidjniinput.h"
+#include <QDebug>
+#include <qevent.h>
+#include <qguiapplication.h>
+#include <qsharedpointer.h>
+#include <qthread.h>
+#include <qinputmethod.h>
+#include <qwindow.h>
+
+#include <QTextCharFormat>
+
+QT_BEGIN_NAMESPACE
+
+static QAndroidInputContext *m_androidInputContext = 0;
+static char const *const QtNativeInputConnectionClassName = "org/qtproject/qt5/android/QtNativeInputConnection";
+static char const *const QtExtractedTextClassName = "org/qtproject/qt5/android/QtExtractedText";
+static jclass m_extractedTextClass = 0;
+static jmethodID m_classConstructorMethodID = 0;
+static jfieldID m_partialEndOffsetFieldID = 0;
+static jfieldID m_partialStartOffsetFieldID = 0;
+static jfieldID m_selectionEndFieldID = 0;
+static jfieldID m_selectionStartFieldID = 0;
+static jfieldID m_startOffsetFieldID = 0;
+static jfieldID m_textFieldID = 0;
+
+static jboolean commitText(JNIEnv *env, jobject /*thiz*/, jstring text, jint newCursorPosition)
+{
+ if (!m_androidInputContext)
+ return JNI_FALSE;
+
+ jboolean isCopy;
+ const jchar *jstr = env->GetStringChars(text, &isCopy);
+ QString str(reinterpret_cast<const QChar *>(jstr), env->GetStringLength(text));
+ env->ReleaseStringChars(text, jstr);
+
+ return m_androidInputContext->commitText(str, newCursorPosition);
+}
+
+static jboolean deleteSurroundingText(JNIEnv */*env*/, jobject /*thiz*/, jint leftLength, jint rightLength)
+{
+ if (!m_androidInputContext)
+ return JNI_FALSE;
+
+ return m_androidInputContext->deleteSurroundingText(leftLength, rightLength);
+}
+
+static jboolean finishComposingText(JNIEnv */*env*/, jobject /*thiz*/)
+{
+ if (!m_androidInputContext)
+ return JNI_FALSE;
+
+ return m_androidInputContext->finishComposingText();
+}
+
+static jint getCursorCapsMode(JNIEnv */*env*/, jobject /*thiz*/, jint reqModes)
+{
+ if (!m_androidInputContext)
+ return 0;
+
+ return m_androidInputContext->getCursorCapsMode(reqModes);
+}
+
+static jobject getExtractedText(JNIEnv *env, jobject /*thiz*/, int hintMaxChars, int hintMaxLines, jint flags)
+{
+ if (!m_androidInputContext)
+ return 0;
+
+ const QAndroidInputContext::ExtractedText &extractedText =
+ m_androidInputContext->getExtractedText(hintMaxChars, hintMaxLines, flags);
+
+ jobject object = env->NewObject(m_extractedTextClass, m_classConstructorMethodID);
+ env->SetIntField(object, m_partialStartOffsetFieldID, extractedText.partialStartOffset);
+ env->SetIntField(object, m_partialEndOffsetFieldID, extractedText.partialEndOffset);
+ env->SetIntField(object, m_selectionStartFieldID, extractedText.selectionStart);
+ env->SetIntField(object, m_selectionEndFieldID, extractedText.selectionEnd);
+ env->SetIntField(object, m_startOffsetFieldID, extractedText.startOffset);
+ env->SetObjectField(object,
+ m_textFieldID,
+ env->NewString(reinterpret_cast<const jchar *>(extractedText.text.constData()),
+ jsize(extractedText.text.length())));
+
+ return object;
+}
+
+static jstring getSelectedText(JNIEnv *env, jobject /*thiz*/, jint flags)
+{
+ if (!m_androidInputContext)
+ return 0;
+
+ const QString &text = m_androidInputContext->getSelectedText(flags);
+ return env->NewString(reinterpret_cast<const jchar *>(text.constData()), jsize(text.length()));
+}
+
+static jstring getTextAfterCursor(JNIEnv *env, jobject /*thiz*/, jint length, jint flags)
+{
+ if (!m_androidInputContext)
+ return 0;
+
+ const QString &text = m_androidInputContext->getTextAfterCursor(length, flags);
+ return env->NewString(reinterpret_cast<const jchar *>(text.constData()), jsize(text.length()));
+}
+
+static jstring getTextBeforeCursor(JNIEnv *env, jobject /*thiz*/, jint length, jint flags)
+{
+ if (!m_androidInputContext)
+ return 0;
+
+ const QString &text = m_androidInputContext->getTextBeforeCursor(length, flags);
+ return env->NewString(reinterpret_cast<const jchar *>(text.constData()), jsize(text.length()));
+}
+
+static jboolean setComposingText(JNIEnv *env, jobject /*thiz*/, jstring text, jint newCursorPosition)
+{
+ if (!m_androidInputContext)
+ return JNI_FALSE;
+
+ jboolean isCopy;
+ const jchar *jstr = env->GetStringChars(text, &isCopy);
+ QString str(reinterpret_cast<const QChar *>(jstr), env->GetStringLength(text));
+ env->ReleaseStringChars(text, jstr);
+
+ return m_androidInputContext->setComposingText(str, newCursorPosition);
+}
+
+static jboolean setSelection(JNIEnv */*env*/, jobject /*thiz*/, jint start, jint end)
+{
+ if (!m_androidInputContext)
+ return JNI_FALSE;
+
+ return m_androidInputContext->setSelection(start, end);
+}
+
+static jboolean selectAll(JNIEnv */*env*/, jobject /*thiz*/)
+{
+ if (!m_androidInputContext)
+ return JNI_FALSE;
+
+ return m_androidInputContext->selectAll();
+}
+
+static jboolean cut(JNIEnv */*env*/, jobject /*thiz*/)
+{
+ if (!m_androidInputContext)
+ return JNI_FALSE;
+
+ return m_androidInputContext->cut();
+}
+
+static jboolean copy(JNIEnv */*env*/, jobject /*thiz*/)
+{
+ if (!m_androidInputContext)
+ return JNI_FALSE;
+
+ return m_androidInputContext->copy();
+}
+
+static jboolean copyURL(JNIEnv */*env*/, jobject /*thiz*/)
+{
+ if (!m_androidInputContext)
+ return JNI_FALSE;
+
+ return m_androidInputContext->copyURL();
+}
+
+static jboolean paste(JNIEnv */*env*/, jobject /*thiz*/)
+{
+ if (!m_androidInputContext)
+ return JNI_FALSE;
+
+ return m_androidInputContext->paste();
+}
+
+
+static JNINativeMethod methods[] = {
+ {"commitText", "(Ljava/lang/String;I)Z", (void *)commitText},
+ {"deleteSurroundingText", "(II)Z", (void *)deleteSurroundingText},
+ {"finishComposingText", "()Z", (void *)finishComposingText},
+ {"getCursorCapsMode", "(I)I", (void *)getCursorCapsMode},
+ {"getExtractedText", "(III)Lorg/qtproject/qt5/android/QtExtractedText;", (void *)getExtractedText},
+ {"getSelectedText", "(I)Ljava/lang/String;", (void *)getSelectedText},
+ {"getTextAfterCursor", "(II)Ljava/lang/String;", (void *)getTextAfterCursor},
+ {"getTextBeforeCursor", "(II)Ljava/lang/String;", (void *)getTextBeforeCursor},
+ {"setComposingText", "(Ljava/lang/String;I)Z", (void *)setComposingText},
+ {"setSelection", "(II)Z", (void *)setSelection},
+ {"selectAll", "()Z", (void *)selectAll},
+ {"cut", "()Z", (void *)cut},
+ {"copy", "()Z", (void *)copy},
+ {"copyURL", "()Z", (void *)copyURL},
+ {"paste", "()Z", (void *)paste}
+};
+
+
+QAndroidInputContext::QAndroidInputContext():QPlatformInputContext()
+{
+ JNIEnv *env = 0;
+ if (QtAndroid::javaVM()->AttachCurrentThread(&env, NULL) < 0) {
+ qCritical() << "AttachCurrentThread failed";
+ return;
+ }
+
+ jclass clazz = QtAndroid::findClass(QtNativeInputConnectionClassName, env);
+ if (clazz == NULL) {
+ qCritical() << "Native registration unable to find class '"
+ << QtNativeInputConnectionClassName
+ << "'";
+ return;
+ }
+
+ if (env->RegisterNatives(clazz, methods, sizeof(methods) / sizeof(methods[0])) < 0) {
+ qCritical() << "RegisterNatives failed for '"
+ << QtNativeInputConnectionClassName
+ << "'";
+ return;
+ }
+
+ clazz = QtAndroid::findClass(QtExtractedTextClassName, env);
+ if (clazz == NULL) {
+ qCritical() << "Native registration unable to find class '"
+ << QtExtractedTextClassName
+ << "'";
+ return;
+ }
+
+ m_extractedTextClass = static_cast<jclass>(env->NewGlobalRef(clazz));
+ m_classConstructorMethodID = env->GetMethodID(m_extractedTextClass, "<init>", "()V");
+ if (m_classConstructorMethodID == NULL) {
+ qCritical() << "GetMethodID failed";
+ return;
+ }
+
+ m_partialEndOffsetFieldID = env->GetFieldID(m_extractedTextClass, "partialEndOffset", "I");
+ if (m_partialEndOffsetFieldID == NULL) {
+ qCritical() << "Can't find field partialEndOffset";
+ return;
+ }
+
+ m_partialStartOffsetFieldID = env->GetFieldID(m_extractedTextClass, "partialStartOffset", "I");
+ if (m_partialStartOffsetFieldID == NULL) {
+ qCritical() << "Can't find field partialStartOffset";
+ return;
+ }
+
+ m_selectionEndFieldID = env->GetFieldID(m_extractedTextClass, "selectionEnd", "I");
+ if (m_selectionEndFieldID == NULL) {
+ qCritical() << "Can't find field selectionEnd";
+ return;
+ }
+
+ m_selectionStartFieldID = env->GetFieldID(m_extractedTextClass, "selectionStart", "I");
+ if (m_selectionStartFieldID == NULL) {
+ qCritical() << "Can't find field selectionStart";
+ return;
+ }
+
+ m_startOffsetFieldID = env->GetFieldID(m_extractedTextClass, "startOffset", "I");
+ if (m_startOffsetFieldID == NULL) {
+ qCritical() << "Can't find field startOffset";
+ return;
+ }
+
+ m_textFieldID = env->GetFieldID(m_extractedTextClass, "text", "Ljava/lang/String;");
+ if (m_textFieldID == NULL) {
+ qCritical() << "Can't find field text";
+ return;
+ }
+ qRegisterMetaType<QInputMethodEvent *>("QInputMethodEvent*");
+ qRegisterMetaType<QInputMethodQueryEvent *>("QInputMethodQueryEvent*");
+ m_androidInputContext = this;
+}
+
+QAndroidInputContext::~QAndroidInputContext()
+{
+ m_androidInputContext = 0;
+ m_extractedTextClass = 0;
+ m_partialEndOffsetFieldID = 0;
+ m_partialStartOffsetFieldID = 0;
+ m_selectionEndFieldID = 0;
+ m_selectionStartFieldID = 0;
+ m_startOffsetFieldID = 0;
+ m_textFieldID = 0;
+}
+
+void QAndroidInputContext::reset()
+{
+ clear();
+ if (qGuiApp->focusObject())
+ QtAndroidInput::resetSoftwareKeyboard();
+ else
+ QtAndroidInput::hideSoftwareKeyboard();
+}
+
+void QAndroidInputContext::commit()
+{
+ finishComposingText();
+}
+
+void QAndroidInputContext::updateCursorPosition()
+{
+ QSharedPointer<QInputMethodQueryEvent> query = focusObjectInputMethodQuery();
+ if (!query.isNull()) {
+ const int cursorPos = query->value(Qt::ImCursorPosition).toInt();
+ QtAndroidInput::updateSelection(cursorPos, cursorPos, -1, -1); //selection empty and no pre-edit text
+ }
+}
+
+void QAndroidInputContext::update(Qt::InputMethodQueries queries)
+{
+ QSharedPointer<QInputMethodQueryEvent> query = focusObjectInputMethodQuery(queries);
+ if (query.isNull())
+ return;
+#warning TODO extract the needed data from query
+}
+
+void QAndroidInputContext::invokeAction(QInputMethod::Action action, int cursorPosition)
+{
+#warning TODO Handle at least QInputMethod::ContextMenu action
+ Q_UNUSED(action)
+ Q_UNUSED(cursorPosition)
+
+ if (action == QInputMethod::Click)
+ commit();
+}
+
+QRectF QAndroidInputContext::keyboardRect() const
+{
+ return QPlatformInputContext::keyboardRect();
+}
+
+bool QAndroidInputContext::isAnimating() const
+{
+ return false;
+}
+
+void QAndroidInputContext::showInputPanel()
+{
+ QSharedPointer<QInputMethodQueryEvent> query = focusObjectInputMethodQuery();
+ if (query.isNull())
+ return;
+
+ disconnect(m_updateCursorPosConnection);
+ if (qGuiApp->focusObject()->metaObject()->indexOfSignal("cursorPositionChanged(int,int)") >= 0) // QLineEdit breaks the pattern
+ m_updateCursorPosConnection = connect(qGuiApp->focusObject(), SIGNAL(cursorPositionChanged(int,int)), this, SLOT(updateCursorPosition()));
+ else
+ m_updateCursorPosConnection = connect(qGuiApp->focusObject(), SIGNAL(cursorPositionChanged()), this, SLOT(updateCursorPosition()));
+ QRectF itemRect = qGuiApp->inputMethod()->inputItemRectangle();
+ QRect rect = qGuiApp->inputMethod()->inputItemTransform().mapRect(itemRect).toRect();
+ QWindow *window = qGuiApp->focusWindow();
+ if (window)
+ rect = QRect(window->mapToGlobal(rect.topLeft()), rect.size());
+
+ QtAndroidInput::showSoftwareKeyboard(rect.left(),
+ rect.top(),
+ rect.width(),
+ rect.height(),
+ query->value(Qt::ImHints).toUInt());
+}
+
+void QAndroidInputContext::hideInputPanel()
+{
+ QtAndroidInput::hideSoftwareKeyboard();
+}
+
+bool QAndroidInputContext::isInputPanelVisible() const
+{
+ return QtAndroidInput::isSoftwareKeyboardVisible();
+}
+
+bool QAndroidInputContext::isComposing() const
+{
+ return m_composingText.length();
+}
+
+void QAndroidInputContext::clear()
+{
+ m_composingText.clear();
+ m_extractedText.clear();
+}
+
+void QAndroidInputContext::sendEvent(QObject *receiver, QInputMethodEvent *event)
+{
+ QCoreApplication::sendEvent(receiver, event);
+}
+
+void QAndroidInputContext::sendEvent(QObject *receiver, QInputMethodQueryEvent *event)
+{
+ QCoreApplication::sendEvent(receiver, event);
+}
+
+jboolean QAndroidInputContext::commitText(const QString &text, jint /*newCursorPosition*/)
+{
+ m_composingText = text;
+ return finishComposingText();
+}
+
+jboolean QAndroidInputContext::deleteSurroundingText(jint leftLength, jint rightLength)
+{
+ QSharedPointer<QInputMethodQueryEvent> query = focusObjectInputMethodQuery();
+ if (query.isNull())
+ return JNI_TRUE;
+
+ m_composingText.clear();
+
+ QInputMethodEvent event;
+ event.setCommitString(QString(), -leftLength, leftLength+rightLength);
+ sendInputMethodEvent(&event);
+ clear();
+
+ return JNI_TRUE;
+}
+
+jboolean QAndroidInputContext::finishComposingText()
+{
+ QInputMethodEvent event;
+ event.setCommitString(m_composingText);
+ sendInputMethodEvent(&event);
+ clear();
+
+ return JNI_TRUE;
+}
+
+jint QAndroidInputContext::getCursorCapsMode(jint /*reqModes*/)
+{
+ jint res = 0;
+ QSharedPointer<QInputMethodQueryEvent> query = focusObjectInputMethodQuery();
+ if (query.isNull())
+ return res;
+
+ const uint qtInputMethodHints = query->value(Qt::ImHints).toUInt();
+
+ if (qtInputMethodHints & Qt::ImhPreferUppercase)
+ res = CAP_MODE_SENTENCES;
+
+ if (qtInputMethodHints & Qt::ImhUppercaseOnly)
+ res = CAP_MODE_CHARACTERS;
+
+ return res;
+}
+
+const QAndroidInputContext::ExtractedText &QAndroidInputContext::getExtractedText(jint hintMaxChars, jint /*hintMaxLines*/, jint /*flags*/)
+{
+ QSharedPointer<QInputMethodQueryEvent> query = focusObjectInputMethodQuery();
+ if (query.isNull())
+ return m_extractedText;
+
+ if (hintMaxChars)
+ m_extractedText.text = query->value(Qt::ImSurroundingText).toString().right(hintMaxChars);
+
+ m_extractedText.startOffset = query->value(Qt::ImCursorPosition).toInt();
+ const QString &selection = query->value(Qt::ImCurrentSelection).toString();
+ const int selLen = selection.length();
+ if (selLen) {
+ m_extractedText.selectionStart = query->value(Qt::ImAnchorPosition).toInt();
+ m_extractedText.selectionEnd = m_extractedText.startOffset;
+ }
+
+ return m_extractedText;
+}
+
+QString QAndroidInputContext::getSelectedText(jint /*flags*/)
+{
+ QSharedPointer<QInputMethodQueryEvent> query = focusObjectInputMethodQuery();
+ if (query.isNull())
+ return QString();
+
+ return query->value(Qt::ImCurrentSelection).toString();
+}
+
+QString QAndroidInputContext::getTextAfterCursor(jint length, jint /*flags*/)
+{
+ QSharedPointer<QInputMethodQueryEvent> query = focusObjectInputMethodQuery();
+ if (query.isNull())
+ return QString();
+
+ QString text = query->value(Qt::ImSurroundingText).toString();
+ if (!text.length())
+ return text;
+
+ int cursorPos = query->value(Qt::ImCursorPosition).toInt();
+ return text.mid(cursorPos, length);
+}
+
+QString QAndroidInputContext::getTextBeforeCursor(jint length, jint /*flags*/)
+{
+ QSharedPointer<QInputMethodQueryEvent> query = focusObjectInputMethodQuery();
+ if (query.isNull())
+ return QString();
+
+ QString text = query->value(Qt::ImSurroundingText).toString();
+ if (!text.length())
+ return text;
+
+ int cursorPos = query->value(Qt::ImCursorPosition).toInt();
+ const int wordLeftPos = cursorPos - length;
+ return text.mid(wordLeftPos > 0 ? wordLeftPos : 0, cursorPos);
+}
+
+jboolean QAndroidInputContext::setComposingText(const QString &text, jint newCursorPosition)
+{
+ if (newCursorPosition > 0)
+ newCursorPosition += text.length() - 1;
+ m_composingText = text;
+ QList<QInputMethodEvent::Attribute> attributes;
+ attributes.append(QInputMethodEvent::Attribute(QInputMethodEvent::Cursor,
+ newCursorPosition,
+ 1,
+ QVariant()));
+ // Show compose text underlined
+ QTextCharFormat underlined;
+ underlined.setFontUnderline(true);
+ attributes.append(QInputMethodEvent::Attribute(QInputMethodEvent::TextFormat,0, text.length(),
+ QVariant(underlined)));
+
+ QInputMethodEvent event(m_composingText, attributes);
+ sendInputMethodEvent(&event);
+
+ QSharedPointer<QInputMethodQueryEvent> query = focusObjectInputMethodQuery();
+ if (!query.isNull()) {
+ int cursorPos = query->value(Qt::ImCursorPosition).toInt();
+ int preeditLength = text.length();
+ QtAndroidInput::updateSelection(cursorPos+preeditLength, cursorPos+preeditLength, cursorPos, cursorPos+preeditLength);
+ }
+
+ return JNI_TRUE;
+}
+
+jboolean QAndroidInputContext::setSelection(jint start, jint end)
+{
+ QList<QInputMethodEvent::Attribute> attributes;
+ attributes.append(QInputMethodEvent::Attribute(QInputMethodEvent::Selection,
+ start,
+ end - start,
+ QVariant()));
+
+ QInputMethodEvent event(QString(), attributes);
+ sendInputMethodEvent(&event);
+ return JNI_TRUE;
+}
+
+jboolean QAndroidInputContext::selectAll()
+{
+#warning TODO
+ return JNI_FALSE;
+}
+
+jboolean QAndroidInputContext::cut()
+{
+#warning TODO
+ return JNI_FALSE;
+}
+
+jboolean QAndroidInputContext::copy()
+{
+#warning TODO
+ return JNI_FALSE;
+}
+
+jboolean QAndroidInputContext::copyURL()
+{
+#warning TODO
+ return JNI_FALSE;
+}
+
+jboolean QAndroidInputContext::paste()
+{
+#warning TODO
+ return JNI_FALSE;
+}
+
+QSharedPointer<QInputMethodQueryEvent> QAndroidInputContext::focusObjectInputMethodQuery(Qt::InputMethodQueries queries)
+{
+#warning TODO make qGuiApp->focusObject() thread safe !!!
+ QObject *focusObject = qGuiApp->focusObject();
+ if (!focusObject)
+ return QSharedPointer<QInputMethodQueryEvent>();
+
+ QSharedPointer<QInputMethodQueryEvent> ret = QSharedPointer<QInputMethodQueryEvent>(new QInputMethodQueryEvent(queries));
+ if (qGuiApp->thread()==QThread::currentThread()) {
+ QCoreApplication::sendEvent(focusObject, ret.data());
+ } else {
+ QMetaObject::invokeMethod(this,
+ "sendEvent",
+ Qt::BlockingQueuedConnection,
+ Q_ARG(QObject*, focusObject),
+ Q_ARG(QInputMethodQueryEvent*, ret.data()));
+ }
+
+ return ret;
+}
+
+void QAndroidInputContext::sendInputMethodEvent(QInputMethodEvent *event)
+{
+#warning TODO make qGuiApp->focusObject() thread safe !!!
+ QObject *focusObject = qGuiApp->focusObject();
+ if (!focusObject)
+ return;
+
+ if (qGuiApp->thread() == QThread::currentThread()) {
+ QCoreApplication::sendEvent(focusObject, event);
+ } else {
+ QMetaObject::invokeMethod(this,
+ "sendEvent",
+ Qt::BlockingQueuedConnection,
+ Q_ARG(QObject*, focusObject),
+ Q_ARG(QInputMethodEvent*, event));
+ }
+}
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/android/src/qandroidinputcontext.h b/src/plugins/platforms/android/src/qandroidinputcontext.h
new file mode 100644
index 0000000000..482aeffa50
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidinputcontext.h
@@ -0,0 +1,132 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef ANDROIDINPUTCONTEXT_H
+#define ANDROIDINPUTCONTEXT_H
+
+#include <qpa/qplatforminputcontext.h>
+#include <jni.h>
+#include <qevent.h>
+
+QT_BEGIN_NAMESPACE
+
+class QAndroidInputContext: public QPlatformInputContext
+{
+ Q_OBJECT
+ enum CapsMode
+ {
+ CAP_MODE_CHARACTERS = 0x00001000,
+ CAP_MODE_SENTENCES = 0x00004000,
+ CAP_MODE_WORDS = 0x00002000
+ };
+
+public:
+ struct ExtractedText
+ {
+ ExtractedText() { clear(); }
+
+ void clear()
+ {
+ partialEndOffset = partialStartOffset = selectionEnd = selectionStart = startOffset = -1;
+ text.clear();
+ }
+
+ int partialEndOffset;
+ int partialStartOffset;
+ int selectionEnd;
+ int selectionStart;
+ int startOffset;
+ QString text;
+ };
+
+public:
+ QAndroidInputContext();
+ ~QAndroidInputContext();
+ bool isValid() const { return true; }
+
+ void reset();
+ void commit();
+ void update(Qt::InputMethodQueries queries);
+ void invokeAction(QInputMethod::Action action, int cursorPosition);
+ QRectF keyboardRect() const;
+ bool isAnimating() const;
+ void showInputPanel();
+ void hideInputPanel();
+ bool isInputPanelVisible() const;
+
+ bool isComposing() const;
+ void clear();
+
+ //---------------//
+ jboolean commitText(const QString &text, jint newCursorPosition);
+ jboolean deleteSurroundingText(jint leftLength, jint rightLength);
+ jboolean finishComposingText();
+ jint getCursorCapsMode(jint reqModes);
+ const ExtractedText &getExtractedText(jint hintMaxChars, jint hintMaxLines, jint flags);
+ QString getSelectedText(jint flags);
+ QString getTextAfterCursor(jint length, jint flags);
+ QString getTextBeforeCursor(jint length, jint flags);
+ jboolean setComposingText(const QString &text, jint newCursorPosition);
+ jboolean setSelection(jint start, jint end);
+ jboolean selectAll();
+ jboolean cut();
+ jboolean copy();
+ jboolean copyURL();
+ jboolean paste();
+
+private:
+ QSharedPointer<QInputMethodQueryEvent> focusObjectInputMethodQuery(Qt::InputMethodQueries queries = Qt::ImQueryAll);
+ void sendInputMethodEvent(QInputMethodEvent *event);
+
+private slots:
+ virtual void sendEvent(QObject *receiver, QInputMethodEvent *event);
+ virtual void sendEvent(QObject *receiver, QInputMethodQueryEvent *event);
+ void updateCursorPosition();
+
+private:
+ ExtractedText m_extractedText;
+ QString m_composingText;
+ QMetaObject::Connection m_updateCursorPosConnection;
+};
+
+QT_END_NAMESPACE
+
+#endif // ANDROIDINPUTCONTEXT_H
diff --git a/src/plugins/platforms/android/src/qandroidplatformclipboard.cpp b/src/plugins/platforms/android/src/qandroidplatformclipboard.cpp
new file mode 100644
index 0000000000..bc48b4935b
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformclipboard.cpp
@@ -0,0 +1,79 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qandroidplatformclipboard.h"
+#include "androidjniclipboard.h"
+#ifndef QT_NO_CLIPBOARD
+#include <QMimeData>
+
+QT_BEGIN_NAMESPACE
+
+QAndroidPlatformClipboard::QAndroidPlatformClipboard()
+{
+ QtAndroidClipboard::setClipboardListener(this);
+}
+
+QMimeData *QAndroidPlatformClipboard::mimeData(QClipboard::Mode mode)
+{
+ if (QClipboard::Clipboard != mode || !QtAndroidClipboard::hasClipboardText())
+ return 0;
+
+ QMimeData *mimeData = new QMimeData();
+ mimeData->setText(QtAndroidClipboard::clipboardText());
+ return mimeData;
+}
+
+void QAndroidPlatformClipboard::setMimeData(QMimeData *data, QClipboard::Mode mode)
+{
+ if (!data || !data->hasText() || QClipboard::Clipboard != mode)
+ return;
+
+ QtAndroidClipboard::setClipboardText(data->text());
+}
+
+bool QAndroidPlatformClipboard::supportsMode(QClipboard::Mode mode) const
+{
+ return QClipboard::Clipboard == mode;
+}
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_CLIPBOARD
diff --git a/src/plugins/platforms/android/src/qandroidplatformclipboard.h b/src/plugins/platforms/android/src/qandroidplatformclipboard.h
new file mode 100644
index 0000000000..644f326934
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformclipboard.h
@@ -0,0 +1,63 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QANDROIDPLATFORMCLIPBOARD_H
+#define QANDROIDPLATFORMCLIPBOARD_H
+
+#include <qpa/qplatformclipboard.h>
+
+#ifndef QT_NO_CLIPBOARD
+QT_BEGIN_NAMESPACE
+
+class QAndroidPlatformClipboard: public QPlatformClipboard
+{
+public:
+ QAndroidPlatformClipboard();
+
+ virtual QMimeData *mimeData(QClipboard::Mode mode = QClipboard::Clipboard);
+ virtual void setMimeData(QMimeData *data, QClipboard::Mode mode = QClipboard::Clipboard);
+ virtual bool supportsMode(QClipboard::Mode mode) const;
+};
+
+QT_END_NAMESPACE
+#endif // QT_NO_CLIPBOARD
+
+#endif // QANDROIDPLATFORMCLIPBOARD_H
diff --git a/src/plugins/platforms/android/src/qandroidplatformfontdatabase.cpp b/src/plugins/platforms/android/src/qandroidplatformfontdatabase.cpp
new file mode 100644
index 0000000000..7f68b44ed8
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformfontdatabase.cpp
@@ -0,0 +1,79 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QDir>
+
+#include "qandroidplatformfontdatabase.h"
+
+QString QAndroidPlatformFontDatabase::fontDir() const
+{
+ return QLatin1String("/system/fonts");
+}
+
+void QAndroidPlatformFontDatabase::populateFontDatabase()
+{
+ QString fontpath = fontDir();
+
+ if (!QFile::exists(fontpath)) {
+ qFatal("QFontDatabase: Cannot find font directory %s - is Qt installed correctly?",
+ qPrintable(fontpath));
+ }
+
+ QDir dir(fontpath, QLatin1String("*.ttf"));
+ for (int i = 0; i < int(dir.count()); ++i) {
+ const QByteArray file = QFile::encodeName(dir.absoluteFilePath(dir[i]));
+ addTTFile(QByteArray(), file);
+ }
+}
+
+QStringList QAndroidPlatformFontDatabase::fallbacksForFamily(const QString &family,
+ QFont::Style style,
+ QFont::StyleHint styleHint,
+ QChar::Script script) const
+{
+ Q_UNUSED(family);
+ Q_UNUSED(style);
+ Q_UNUSED(script);
+ if (styleHint == QFont::Monospace)
+ return QString(qgetenv("QT_ANDROID_FONTS_MONOSPACE")).split(";");
+
+ return QString(qgetenv("QT_ANDROID_FONTS")).split(";");
+}
diff --git a/src/plugins/platforms/android/src/qandroidplatformfontdatabase.h b/src/plugins/platforms/android/src/qandroidplatformfontdatabase.h
new file mode 100644
index 0000000000..3cbfe95d36
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformfontdatabase.h
@@ -0,0 +1,58 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QANDROIDPLATFORMFONTDATABASE_H
+#define QANDROIDPLATFORMFONTDATABASE_H
+
+#include <QtPlatformSupport/private/qbasicfontdatabase_p.h>
+
+class QAndroidPlatformFontDatabase: public QBasicFontDatabase
+{
+public:
+ QString fontDir() const;
+ void populateFontDatabase();
+ QStringList fallbacksForFamily(const QString &family,
+ QFont::Style style,
+ QFont::StyleHint styleHint,
+ QChar::Script script) const;
+};
+
+#endif // QANDROIDPLATFORMFONTDATABASE_H
diff --git a/src/plugins/platforms/android/src/qandroidplatformintegration.cpp b/src/plugins/platforms/android/src/qandroidplatformintegration.cpp
new file mode 100644
index 0000000000..cbd0f26835
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformintegration.cpp
@@ -0,0 +1,285 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qandroidplatformintegration.h"
+#include "qabstracteventdispatcher.h"
+#include "androidjnimain.h"
+#include <QtGui/private/qpixmap_raster_p.h>
+#include <qpa/qwindowsysteminterface.h>
+#include <QThread>
+#include <qpa/qplatformwindow.h>
+#include "qandroidplatformservices.h"
+#include "qandroidplatformfontdatabase.h"
+#include "qandroidplatformclipboard.h"
+#include <QtPlatformSupport/private/qgenericunixeventdispatcher_p.h>
+
+#ifndef ANDROID_PLUGIN_OPENGL
+# include "qandroidplatformscreen.h"
+# include "qandroidplatformwindow.h"
+# include <QtPlatformSupport/private/qfbbackingstore_p.h>
+#else
+# include "qeglfswindow.h"
+# include "androidjnimenu.h"
+# include "qandroidopenglcontext.h"
+# include "qandroidopenglplatformwindow.h"
+# include "qeglfshooks.h"
+# include <QtGui/qopenglcontext.h>
+#endif
+
+#include "qandroidplatformtheme.h"
+
+QT_BEGIN_NAMESPACE
+
+int QAndroidPlatformIntegration::m_defaultGeometryWidth = 320;
+int QAndroidPlatformIntegration::m_defaultGeometryHeight = 455;
+int QAndroidPlatformIntegration::m_defaultPhysicalSizeWidth = 50;
+int QAndroidPlatformIntegration::m_defaultPhysicalSizeHeight = 71;
+
+void *QAndroidPlatformNativeInterface::nativeResourceForIntegration(const QByteArray &resource)
+{
+ if (resource=="JavaVM")
+ return QtAndroid::javaVM();
+ if (resource == "QtActivity")
+ return QtAndroid::activity();
+
+ return 0;
+}
+
+QAndroidPlatformIntegration::QAndroidPlatformIntegration(const QStringList &paramList)
+ : m_touchDevice(0)
+#ifdef ANDROID_PLUGIN_OPENGL
+ , m_primaryWindow(0)
+#endif
+{
+ Q_UNUSED(paramList);
+
+#ifndef ANDROID_PLUGIN_OPENGL
+ m_eventDispatcher = createUnixEventDispatcher();
+#endif
+
+ m_androidPlatformNativeInterface = new QAndroidPlatformNativeInterface();
+
+#ifndef ANDROID_PLUGIN_OPENGL
+ m_primaryScreen = new QAndroidPlatformScreen();
+ screenAdded(m_primaryScreen);
+ m_primaryScreen->setPhysicalSize(QSize(m_defaultPhysicalSizeWidth, m_defaultPhysicalSizeHeight));
+ m_primaryScreen->setGeometry(QRect(0, 0, m_defaultGeometryWidth, m_defaultGeometryHeight));
+#endif
+
+ m_mainThread = QThread::currentThread();
+ QtAndroid::setAndroidPlatformIntegration(this);
+
+ m_androidFDB = new QAndroidPlatformFontDatabase();
+ m_androidPlatformServices = new QAndroidPlatformServices();
+ m_androidPlatformClipboard = new QAndroidPlatformClipboard();
+}
+
+bool QAndroidPlatformIntegration::hasCapability(Capability cap) const
+{
+ switch (cap) {
+ case ThreadedPixmaps: return true;
+ default:
+#ifndef ANDROID_PLUGIN_OPENGL
+ return QPlatformIntegration::hasCapability(cap);
+#else
+ return QEglFSIntegration::hasCapability(cap);
+#endif
+ }
+}
+
+#ifndef ANDROID_PLUGIN_OPENGL
+QPlatformBackingStore *QAndroidPlatformIntegration::createPlatformBackingStore(QWindow *window) const
+{
+ return new QFbBackingStore(window);
+}
+
+QPlatformWindow *QAndroidPlatformIntegration::createPlatformWindow(QWindow *window) const
+{
+ return new QAndroidPlatformWindow(window);
+}
+
+QAbstractEventDispatcher *QAndroidPlatformIntegration::guiThreadEventDispatcher() const
+{
+ return m_eventDispatcher;
+}
+#else // !ANDROID_PLUGIN_OPENGL
+QPlatformWindow *QAndroidPlatformIntegration::createPlatformWindow(QWindow *window) const
+{
+ if (m_primaryWindow != 0) {
+ qWarning("QAndroidPlatformIntegration::createPlatformWindow: Unsupported case: More than "
+ "one top-level window created.");
+ }
+
+ m_primaryWindow = new QAndroidOpenGLPlatformWindow(window);
+ m_primaryWindow->requestActivateWindow();
+ QtAndroidMenu::setActiveTopLevelWindow(window);
+
+ return m_primaryWindow;
+}
+
+void QAndroidPlatformIntegration::invalidateNativeSurface()
+{
+ if (m_primaryWindow != 0)
+ m_primaryWindow->invalidateSurface();
+}
+
+void QAndroidPlatformIntegration::surfaceChanged()
+{
+ if (m_primaryWindow != 0)
+ m_primaryWindow->resetSurface();
+}
+
+QPlatformOpenGLContext *QAndroidPlatformIntegration::createPlatformOpenGLContext(QOpenGLContext *context) const
+{
+ return new QAndroidOpenGLContext(this,
+ QEglFSHooks::hooks()->surfaceFormatFor(context->format()),
+ context->shareHandle(),
+ display());
+}
+#endif // ANDROID_PLUGIN_OPENGL
+
+QAndroidPlatformIntegration::~QAndroidPlatformIntegration()
+{
+ delete m_androidPlatformNativeInterface;
+ delete m_androidFDB;
+ delete m_touchDevice;
+ QtAndroid::setAndroidPlatformIntegration(NULL);
+}
+QPlatformFontDatabase *QAndroidPlatformIntegration::fontDatabase() const
+{
+ return m_androidFDB;
+}
+
+#ifndef QT_NO_CLIPBOARD
+QPlatformClipboard *QAndroidPlatformIntegration::clipboard() const
+{
+static QAndroidPlatformClipboard *clipboard = 0;
+ if (!clipboard)
+ clipboard = new QAndroidPlatformClipboard;
+
+ return clipboard;
+}
+#endif
+
+QPlatformInputContext *QAndroidPlatformIntegration::inputContext() const
+{
+ return &m_platformInputContext;
+}
+
+QPlatformNativeInterface *QAndroidPlatformIntegration::nativeInterface() const
+{
+ return m_androidPlatformNativeInterface;
+}
+
+QPlatformServices *QAndroidPlatformIntegration::services() const
+{
+ return m_androidPlatformServices;
+}
+
+static const QLatin1String androidThemeName("android");
+QStringList QAndroidPlatformIntegration::themeNames() const
+{
+ return QStringList(QString(androidThemeName));
+}
+
+QPlatformTheme *QAndroidPlatformIntegration::createPlatformTheme(const QString &name) const
+{
+ if (androidThemeName == name)
+ return new QAndroidPlatformTheme;
+
+ return 0;
+}
+
+void QAndroidPlatformIntegration::setDefaultDisplayMetrics(int gw, int gh, int sw, int sh)
+{
+ m_defaultGeometryWidth = gw;
+ m_defaultGeometryHeight = gh;
+ m_defaultPhysicalSizeWidth = sw;
+ m_defaultPhysicalSizeHeight = sh;
+}
+
+void QAndroidPlatformIntegration::setDefaultDesktopSize(int gw, int gh)
+{
+ m_defaultGeometryWidth = gw;
+ m_defaultGeometryHeight = gh;
+}
+
+
+#ifndef ANDROID_PLUGIN_OPENGL
+void QAndroidPlatformIntegration::setDesktopSize(int width, int height)
+{
+ if (m_primaryScreen)
+ QMetaObject::invokeMethod(m_primaryScreen, "setGeometry", Qt::AutoConnection, Q_ARG(QRect, QRect(0,0,width, height)));
+}
+
+void QAndroidPlatformIntegration::setDisplayMetrics(int width, int height)
+{
+ if (m_primaryScreen)
+ QMetaObject::invokeMethod(m_primaryScreen, "setPhysicalSize", Qt::AutoConnection, Q_ARG(QSize, QSize(width, height)));
+}
+#else
+void QAndroidPlatformIntegration::setDesktopSize(int width, int height)
+{
+ m_defaultGeometryWidth = width;
+ m_defaultGeometryHeight = height;
+}
+
+void QAndroidPlatformIntegration::setDisplayMetrics(int width, int height)
+{
+ m_defaultPhysicalSizeWidth = width;
+ m_defaultPhysicalSizeHeight = height;
+}
+
+#endif
+
+void QAndroidPlatformIntegration::pauseApp()
+{
+ if (QAbstractEventDispatcher::instance(m_mainThread))
+ QAbstractEventDispatcher::instance(m_mainThread)->interrupt();
+}
+
+void QAndroidPlatformIntegration::resumeApp()
+{
+ if (QAbstractEventDispatcher::instance(m_mainThread))
+ QAbstractEventDispatcher::instance(m_mainThread)->wakeUp();
+}
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/android/src/qandroidplatformintegration.h b/src/plugins/platforms/android/src/qandroidplatformintegration.h
new file mode 100644
index 0000000000..3f8cc5a809
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformintegration.h
@@ -0,0 +1,164 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QANDROIDPLATFORMINTERATION_H
+#define QANDROIDPLATFORMINTERATION_H
+
+#include <qpa/qplatformintegration.h>
+#include <qpa/qplatformmenu.h>
+#include <qpa/qplatformnativeinterface.h>
+#include <QtWidgets/QAction>
+
+#include <jni.h>
+#include "qandroidinputcontext.h"
+
+#ifndef ANDROID_PLUGIN_OPENGL
+# include "qandroidplatformscreen.h"
+#else
+# include "qeglfsintegration.h"
+#endif
+
+QT_BEGIN_NAMESPACE
+
+class QDesktopWidget;
+class QAndroidPlatformServices;
+
+#ifdef ANDROID_PLUGIN_OPENGL
+class QAndroidOpenGLPlatformWindow;
+#endif
+
+class QAndroidPlatformNativeInterface: public QPlatformNativeInterface
+{
+public:
+ void *nativeResourceForIntegration(const QByteArray &resource);
+};
+
+class QAndroidPlatformIntegration
+#ifndef ANDROID_PLUGIN_OPENGL
+ : public QPlatformIntegration
+#else
+ : public QEglFSIntegration
+#endif
+{
+ friend class QAndroidPlatformScreen;
+
+public:
+ QAndroidPlatformIntegration(const QStringList &paramList);
+ ~QAndroidPlatformIntegration();
+
+ bool hasCapability(QPlatformIntegration::Capability cap) const;
+
+#ifndef ANDROID_PLUGIN_OPENGL
+ QPlatformBackingStore *createPlatformBackingStore(QWindow *window) const;
+ QPlatformWindow *createPlatformWindow(QWindow *window) const;
+ QAbstractEventDispatcher *guiThreadEventDispatcher() const;
+ QAndroidPlatformScreen *screen() { return m_primaryScreen; }
+#else
+ QPlatformWindow *createPlatformWindow(QWindow *window) const;
+ void invalidateNativeSurface();
+ void surfaceChanged();
+ QAndroidOpenGLPlatformWindow *primaryWindow() const { return m_primaryWindow; }
+ QPlatformOpenGLContext *createPlatformOpenGLContext(QOpenGLContext *context) const;
+#endif
+
+ virtual void setDesktopSize(int width, int height);
+ virtual void setDisplayMetrics(int width, int height);
+ bool isVirtualDesktop() { return true; }
+
+ QPlatformFontDatabase *fontDatabase() const;
+
+#ifndef QT_NO_CLIPBOARD
+ QPlatformClipboard *clipboard() const;
+#endif
+
+ QPlatformInputContext *inputContext() const;
+ QPlatformNativeInterface *nativeInterface() const;
+ QPlatformServices *services() const;
+
+ QStringList themeNames() const;
+ QPlatformTheme *createPlatformTheme(const QString &name) const;
+
+ void pauseApp();
+ void resumeApp();
+ static void setDefaultDisplayMetrics(int gw, int gh, int sw, int sh);
+ static void setDefaultDesktopSize(int gw, int gh);
+
+ static QSize defaultDesktopSize()
+ {
+ return QSize(m_defaultGeometryWidth, m_defaultGeometryHeight);
+ }
+
+ QTouchDevice *touchDevice() const { return m_touchDevice; }
+ void setTouchDevice(QTouchDevice *touchDevice) { m_touchDevice = touchDevice; }
+
+private:
+
+ friend class QEglFSAndroidHooks;
+
+ QTouchDevice *m_touchDevice;
+
+#ifndef ANDROID_PLUGIN_OPENGL
+ QAbstractEventDispatcher *m_eventDispatcher;
+ QAndroidPlatformScreen *m_primaryScreen;
+#else
+ mutable QAndroidOpenGLPlatformWindow *m_primaryWindow;
+#endif
+
+ QThread *m_mainThread;
+
+ static int m_defaultGeometryWidth;
+ static int m_defaultGeometryHeight;
+ static int m_defaultPhysicalSizeWidth;
+ static int m_defaultPhysicalSizeHeight;
+
+ QPlatformFontDatabase *m_androidFDB;
+ QImage *m_FbScreenImage;
+ QPainter *m_compositePainter;
+ QAndroidPlatformNativeInterface *m_androidPlatformNativeInterface;
+ QAndroidPlatformServices *m_androidPlatformServices;
+ QPlatformClipboard *m_androidPlatformClipboard;
+
+ mutable QAndroidInputContext m_platformInputContext;
+};
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/plugins/platforms/android/src/qandroidplatformmenu.cpp b/src/plugins/platforms/android/src/qandroidplatformmenu.cpp
new file mode 100644
index 0000000000..36247e86f9
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformmenu.cpp
@@ -0,0 +1,167 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qandroidplatformmenu.h"
+#include "qandroidplatformmenuitem.h"
+#include "androidjnimenu.h"
+
+QAndroidPlatformMenu::QAndroidPlatformMenu()
+{
+ m_tag = reinterpret_cast<quintptr>(this); // QMenu will overwrite this later, but we need a unique ID for QtQuick
+ m_enabled = true;
+ m_isVisible = true;
+}
+
+QAndroidPlatformMenu::~QAndroidPlatformMenu()
+{
+ QtAndroidMenu::androidPlatformMenuDestroyed(this);
+}
+
+void QAndroidPlatformMenu::insertMenuItem(QPlatformMenuItem *menuItem, QPlatformMenuItem *before)
+{
+ QMutexLocker lock(&m_menuItemsMutex);
+ m_menuItems.insert(qFind(m_menuItems.begin(),
+ m_menuItems.end(),
+ static_cast<QAndroidPlatformMenuItem *>(before)),
+ static_cast<QAndroidPlatformMenuItem *>(menuItem));
+}
+
+void QAndroidPlatformMenu::removeMenuItem(QPlatformMenuItem *menuItem)
+{
+ QMutexLocker lock(&m_menuItemsMutex);
+ m_menuItems.erase(qFind(m_menuItems.begin(),
+ m_menuItems.end(),
+ static_cast<QAndroidPlatformMenuItem *>(menuItem)));
+}
+
+void QAndroidPlatformMenu::syncMenuItem(QPlatformMenuItem *menuItem)
+{
+ PlatformMenuItemsType::iterator it;
+ for (it = m_menuItems.begin(); it != m_menuItems.end(); ++it) {
+ if ((*it)->tag() == menuItem->tag())
+ break;
+ }
+
+ if (it != m_menuItems.end())
+ QtAndroidMenu::syncMenu(this);
+}
+
+void QAndroidPlatformMenu::syncSeparatorsCollapsible(bool enable)
+{
+ Q_UNUSED(enable)
+}
+
+void QAndroidPlatformMenu::setTag(quintptr tag)
+{
+ m_tag = tag;
+}
+
+quintptr QAndroidPlatformMenu::tag() const
+{
+ return m_tag;
+}
+
+void QAndroidPlatformMenu::setText(const QString &text)
+{
+ m_text = text;
+}
+
+QString QAndroidPlatformMenu::text() const
+{
+ return m_text;
+}
+
+void QAndroidPlatformMenu::setIcon(const QIcon &icon)
+{
+ m_icon = icon;
+}
+
+QIcon QAndroidPlatformMenu::icon() const
+{
+ return m_icon;
+}
+
+void QAndroidPlatformMenu::setEnabled(bool enabled)
+{
+ m_enabled = enabled;
+}
+
+bool QAndroidPlatformMenu::isEnabled() const
+{
+ return m_enabled;
+}
+
+void QAndroidPlatformMenu::setVisible(bool visible)
+{
+ m_isVisible = visible;
+}
+
+bool QAndroidPlatformMenu::isVisible() const
+{
+ return m_isVisible;
+}
+
+QPlatformMenuItem *QAndroidPlatformMenu::menuItemAt(int position) const
+{
+ if (position < m_menuItems.size())
+ return m_menuItems[position];
+ return 0;
+}
+
+QPlatformMenuItem *QAndroidPlatformMenu::menuItemForTag(quintptr tag) const
+{
+ foreach (QPlatformMenuItem *menuItem, m_menuItems) {
+ if (menuItem->tag() == tag)
+ return menuItem;
+ }
+
+ return 0;
+}
+
+QAndroidPlatformMenu::PlatformMenuItemsType QAndroidPlatformMenu::menuItems() const
+{
+ return m_menuItems;
+}
+
+QMutex *QAndroidPlatformMenu::menuItemsMutex()
+{
+ return &m_menuItemsMutex;
+}
diff --git a/src/plugins/platforms/android/src/qandroidplatformmenu.h b/src/plugins/platforms/android/src/qandroidplatformmenu.h
new file mode 100644
index 0000000000..20236cb636
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformmenu.h
@@ -0,0 +1,91 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QANDROIDPLATFORMMENU_H
+#define QANDROIDPLATFORMMENU_H
+
+#include <qpa/qplatformmenu.h>
+#include <qvector.h>
+#include <qmutex.h>
+
+class QAndroidPlatformMenuItem;
+class QAndroidPlatformMenu: public QPlatformMenu
+{
+public:
+ typedef QVector<QAndroidPlatformMenuItem *> PlatformMenuItemsType;
+
+public:
+ QAndroidPlatformMenu();
+ ~QAndroidPlatformMenu();
+
+ void insertMenuItem(QPlatformMenuItem *menuItem, QPlatformMenuItem *before);
+ void removeMenuItem(QPlatformMenuItem *menuItem);
+ void syncMenuItem(QPlatformMenuItem *menuItem);
+ void syncSeparatorsCollapsible(bool enable);
+
+ void setTag(quintptr tag);
+ quintptr tag() const;
+ void setText(const QString &text);
+ QString text() const;
+ void setIcon(const QIcon &icon);
+ QIcon icon() const;
+ void setEnabled(bool enabled);
+ bool isEnabled() const;
+ void setVisible(bool visible);
+ bool isVisible() const;
+
+ QPlatformMenuItem *menuItemAt(int position) const;
+ QPlatformMenuItem *menuItemForTag(quintptr tag) const;
+
+ PlatformMenuItemsType menuItems() const;
+ QMutex *menuItemsMutex();
+
+private:
+ PlatformMenuItemsType m_menuItems;
+ quintptr m_tag;
+ QString m_text;
+ QIcon m_icon;
+ bool m_enabled;
+ bool m_isVisible;
+ QMutex m_menuItemsMutex;
+};
+
+#endif // QANDROIDPLATFORMMENU_H
diff --git a/src/plugins/platforms/android/src/qandroidplatformmenubar.cpp b/src/plugins/platforms/android/src/qandroidplatformmenubar.cpp
new file mode 100644
index 0000000000..ef1ac61356
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformmenubar.cpp
@@ -0,0 +1,109 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qandroidplatformmenubar.h"
+#include "qandroidplatformmenu.h"
+#include "androidjnimenu.h"
+
+
+QAndroidPlatformMenuBar::QAndroidPlatformMenuBar()
+{
+ m_parentWindow = 0;
+ QtAndroidMenu::addMenuBar(this);
+}
+
+QAndroidPlatformMenuBar::~QAndroidPlatformMenuBar()
+{
+ QtAndroidMenu::removeMenuBar(this);
+}
+
+void QAndroidPlatformMenuBar::insertMenu(QPlatformMenu *menu, QPlatformMenu *before)
+{
+ QMutexLocker lock(&m_menusListMutex);
+ m_menus.insert(qFind(m_menus.begin(),
+ m_menus.end(),
+ static_cast<QAndroidPlatformMenu *>(before)),
+ static_cast<QAndroidPlatformMenu *>(menu));
+}
+
+void QAndroidPlatformMenuBar::removeMenu(QPlatformMenu *menu)
+{
+ QMutexLocker lock(&m_menusListMutex);
+ m_menus.erase(qFind(m_menus.begin(),
+ m_menus.end(),
+ static_cast<QAndroidPlatformMenu *>(menu)));
+}
+
+void QAndroidPlatformMenuBar::syncMenu(QPlatformMenu *menu)
+{
+ QtAndroidMenu::syncMenu(static_cast<QAndroidPlatformMenu *>(menu));
+}
+
+void QAndroidPlatformMenuBar::handleReparent(QWindow *newParentWindow)
+{
+ m_parentWindow = newParentWindow;
+ QtAndroidMenu::setMenuBar(this, newParentWindow);
+}
+
+QPlatformMenu *QAndroidPlatformMenuBar::menuForTag(quintptr tag) const
+{
+ foreach (QPlatformMenu *menu, m_menus) {
+ if (menu->tag() == tag)
+ return menu;
+ }
+
+ return 0;
+}
+
+QWindow *QAndroidPlatformMenuBar::parentWindow() const
+{
+ return m_parentWindow;
+}
+
+QAndroidPlatformMenuBar::PlatformMenusType QAndroidPlatformMenuBar::menus() const
+{
+ return m_menus;
+}
+
+QMutex *QAndroidPlatformMenuBar::menusListMutex()
+{
+ return &m_menusListMutex;
+}
diff --git a/src/plugins/platforms/android/src/qandroidplatformmenubar.h b/src/plugins/platforms/android/src/qandroidplatformmenubar.h
new file mode 100644
index 0000000000..56915335c2
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformmenubar.h
@@ -0,0 +1,74 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QANDROIDPLATFORMMENUBAR_H
+#define QANDROIDPLATFORMMENUBAR_H
+
+#include <qpa/qplatformmenu.h>
+#include <qvector.h>
+#include <qmutex.h>
+
+class QAndroidPlatformMenu;
+class QAndroidPlatformMenuBar: public QPlatformMenuBar
+{
+public:
+ typedef QVector<QAndroidPlatformMenu *> PlatformMenusType;
+public:
+ QAndroidPlatformMenuBar();
+ ~QAndroidPlatformMenuBar();
+
+ void insertMenu(QPlatformMenu *menu, QPlatformMenu *before);
+ void removeMenu(QPlatformMenu *menu);
+ void syncMenu(QPlatformMenu *menu);
+ void handleReparent(QWindow *newParentWindow);
+ QPlatformMenu *menuForTag(quintptr tag) const;
+
+ QWindow *parentWindow() const;
+ PlatformMenusType menus() const;
+ QMutex *menusListMutex();
+
+private:
+ PlatformMenusType m_menus;
+ QWindow *m_parentWindow;
+ QMutex m_menusListMutex;
+};
+
+#endif // QANDROIDPLATFORMMENUBAR_H
diff --git a/src/plugins/platforms/android/src/qandroidplatformmenuitem.cpp b/src/plugins/platforms/android/src/qandroidplatformmenuitem.cpp
new file mode 100644
index 0000000000..bd37834d2a
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformmenuitem.cpp
@@ -0,0 +1,180 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qandroidplatformmenuitem.h"
+#include "qandroidplatformmenu.h"
+
+QAndroidPlatformMenuItem::QAndroidPlatformMenuItem()
+{
+ m_tag = reinterpret_cast<quintptr>(this); // QMenu will overwrite this later, but we need a unique ID for QtQuick
+ m_menu = 0;
+ m_isVisible = true;
+ m_isSeparator = false;
+ m_role = NoRole;
+ m_isCheckable = false;
+ m_isChecked = false;
+ m_isEnabled = true;
+}
+
+void QAndroidPlatformMenuItem::setTag(quintptr tag)
+{
+ m_tag = tag;
+}
+
+quintptr QAndroidPlatformMenuItem::tag() const
+{
+ return m_tag;
+}
+
+void QAndroidPlatformMenuItem::setText(const QString &text)
+{
+ m_text = text;
+ if (m_menu)
+ m_menu->setText(m_text);
+}
+
+QString QAndroidPlatformMenuItem::text() const
+{
+ return m_text;
+}
+
+void QAndroidPlatformMenuItem::setIcon(const QIcon &icon)
+{
+ m_icon = icon;
+ if (m_menu)
+ m_menu->setIcon(m_icon);
+}
+
+QIcon QAndroidPlatformMenuItem::icon() const
+{
+ return m_icon;
+}
+
+void QAndroidPlatformMenuItem::setMenu(QPlatformMenu *menu)
+{
+ m_menu = static_cast<QAndroidPlatformMenu *>(menu);
+ if (!m_menu)
+ return;
+
+ m_menu->setText(m_text);
+ m_menu->setIcon(m_icon);
+ m_menu->setVisible(m_isVisible);
+ m_menu->setEnabled(m_isEnabled);
+}
+
+QAndroidPlatformMenu *QAndroidPlatformMenuItem::menu() const
+{
+ return m_menu;
+}
+
+void QAndroidPlatformMenuItem::setVisible(bool isVisible)
+{
+ m_isVisible = isVisible;
+ if (m_menu)
+ m_menu->setVisible(m_isVisible);
+}
+
+bool QAndroidPlatformMenuItem::isVisible() const
+{
+ return m_isVisible;
+}
+
+void QAndroidPlatformMenuItem::setIsSeparator(bool isSeparator)
+{
+ m_isSeparator = isSeparator;
+}
+
+bool QAndroidPlatformMenuItem::isSeparator() const
+{
+ return m_isSeparator;
+}
+
+void QAndroidPlatformMenuItem::setFont(const QFont &font)
+{
+ Q_UNUSED(font)
+}
+
+void QAndroidPlatformMenuItem::setRole(QPlatformMenuItem::MenuRole role)
+{
+ m_role = role;
+}
+
+QPlatformMenuItem::MenuRole QAndroidPlatformMenuItem::role() const
+{
+ return m_role;
+}
+
+void QAndroidPlatformMenuItem::setCheckable(bool checkable)
+{
+ m_isCheckable = checkable;
+}
+
+bool QAndroidPlatformMenuItem::isCheckable() const
+{
+ return m_isCheckable;
+}
+
+void QAndroidPlatformMenuItem::setChecked(bool isChecked)
+{
+ m_isChecked = isChecked;
+}
+
+bool QAndroidPlatformMenuItem::isChecked() const
+{
+ return m_isChecked;
+}
+
+void QAndroidPlatformMenuItem::setShortcut(const QKeySequence &shortcut)
+{
+ Q_UNUSED(shortcut)
+}
+
+void QAndroidPlatformMenuItem::setEnabled(bool enabled)
+{
+ m_isEnabled = enabled;
+ if (m_menu)
+ m_menu->setEnabled(m_isEnabled);
+}
+
+bool QAndroidPlatformMenuItem::isEnabled() const
+{
+ return m_isEnabled;
+}
diff --git a/src/plugins/platforms/android/src/qandroidplatformmenuitem.h b/src/plugins/platforms/android/src/qandroidplatformmenuitem.h
new file mode 100644
index 0000000000..5861e8e195
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformmenuitem.h
@@ -0,0 +1,99 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QANDROIDPLATFORMMENUITEM_H
+#define QANDROIDPLATFORMMENUITEM_H
+#include <qpa/qplatformmenu.h>
+
+class QAndroidPlatformMenu;
+
+class QAndroidPlatformMenuItem: public QPlatformMenuItem
+{
+public:
+ QAndroidPlatformMenuItem();
+ void setTag(quintptr tag);
+ quintptr tag() const;
+
+ void setText(const QString &text);
+ QString text() const;
+
+ void setIcon(const QIcon &icon);
+ QIcon icon() const;
+
+ void setMenu(QPlatformMenu *menu);
+ QAndroidPlatformMenu *menu() const;
+
+ void setVisible(bool isVisible);
+ bool isVisible() const;
+
+ void setIsSeparator(bool isSeparator);
+ bool isSeparator() const;
+
+ void setFont(const QFont &font);
+
+ void setRole(MenuRole role);
+ MenuRole role() const;
+
+ void setCheckable(bool checkable);
+ bool isCheckable() const;
+
+ void setChecked(bool isChecked);
+ bool isChecked() const;
+
+ void setShortcut(const QKeySequence &shortcut);
+
+ void setEnabled(bool enabled);
+ bool isEnabled() const;
+
+private:
+ quintptr m_tag;
+ QString m_text;
+ QIcon m_icon;
+ QAndroidPlatformMenu *m_menu;
+ bool m_isVisible;
+ bool m_isSeparator;
+ MenuRole m_role;
+ bool m_isCheckable;
+ bool m_isChecked;
+ bool m_isEnabled;
+};
+
+#endif // QANDROIDPLATFORMMENUITEM_H
diff --git a/src/plugins/platforms/android/src/qandroidplatformservices.cpp b/src/plugins/platforms/android/src/qandroidplatformservices.cpp
new file mode 100644
index 0000000000..841a9d4d51
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformservices.cpp
@@ -0,0 +1,83 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qandroidplatformservices.h"
+#include <QUrl>
+#include <QDir>
+#include <QDebug>
+
+QAndroidPlatformServices::QAndroidPlatformServices()
+{
+ JNIEnv *env;
+ if (QtAndroid::javaVM()->AttachCurrentThread(&env, NULL) < 0) {
+ qCritical() << "AttachCurrentThread failed";
+ return;
+ }
+
+ m_openURIMethodID = env->GetStaticMethodID(QtAndroid::applicationClass(),
+ "openURL",
+ "(Ljava/lang/String;)V");
+}
+
+bool QAndroidPlatformServices::openUrl(const QUrl &url)
+{
+ JNIEnv *env;
+ if (QtAndroid::javaVM()->AttachCurrentThread(&env, NULL) < 0) {
+ qCritical() << "AttachCurrentThread failed";
+ return false;
+ }
+
+ jstring string = env->NewString(reinterpret_cast<const jchar *>(url.toString().constData()),
+ url.toString().length());
+ env->CallStaticVoidMethod(QtAndroid::applicationClass(), m_openURIMethodID, string);
+ env->DeleteLocalRef(string);
+ return true;
+}
+
+bool QAndroidPlatformServices::openDocument(const QUrl &url)
+{
+ return openUrl(url);
+}
+
+QByteArray QAndroidPlatformServices::desktopEnvironment() const
+{
+ return QByteArray("Android");
+}
diff --git a/src/plugins/platforms/android/src/qandroidplatformservices.h b/src/plugins/platforms/android/src/qandroidplatformservices.h
new file mode 100644
index 0000000000..8368b19043
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformservices.h
@@ -0,0 +1,61 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef ANDROIDPLATFORMDESKTOPSERVICE_H
+#define ANDROIDPLATFORMDESKTOPSERVICE_H
+
+#include <qpa/qplatformservices.h>
+#include "androidjnimain.h"
+#include <jni.h>
+
+class QAndroidPlatformServices: public QPlatformServices
+{
+public:
+ QAndroidPlatformServices();
+ bool openUrl(const QUrl &url);
+ bool openDocument(const QUrl &url);
+ QByteArray desktopEnvironment() const;
+private:
+ jmethodID m_openURIMethodID;
+
+};
+
+#endif // ANDROIDPLATFORMDESKTOPSERVICE_H
diff --git a/src/plugins/platforms/android/src/qandroidplatformtheme.cpp b/src/plugins/platforms/android/src/qandroidplatformtheme.cpp
new file mode 100644
index 0000000000..25f2ade11a
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformtheme.cpp
@@ -0,0 +1,78 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qandroidplatformtheme.h"
+#include "qandroidplatformmenubar.h"
+#include "qandroidplatformmenu.h"
+#include "qandroidplatformmenuitem.h"
+#include <QVariant>
+#include <QFileInfo>
+
+QPlatformMenuBar *QAndroidPlatformTheme::createPlatformMenuBar() const
+{
+ return new QAndroidPlatformMenuBar;
+}
+
+QPlatformMenu *QAndroidPlatformTheme::createPlatformMenu() const
+{
+ return new QAndroidPlatformMenu;
+}
+
+QPlatformMenuItem *QAndroidPlatformTheme::createPlatformMenuItem() const
+{
+ return new QAndroidPlatformMenuItem;
+}
+
+QVariant QAndroidPlatformTheme::themeHint(ThemeHint hint) const
+{
+ switch (hint) {
+ case StyleNames:
+ if (qgetenv("QT_USE_ANDROID_NATIVE_STYLE").toInt()
+ && (!qgetenv("MINISTRO_ANDROID_STYLE_PATH").isEmpty()
+ || QFileInfo("/data/data/org.kde.necessitas.ministro/files/qt/style/style.json").exists())) {
+ return QStringList("android");
+ }
+ return QStringList("fusion");
+ break;
+ default:
+ return QPlatformTheme::themeHint(hint);
+ }
+}
diff --git a/src/plugins/platforms/android/src/qandroidplatformtheme.h b/src/plugins/platforms/android/src/qandroidplatformtheme.h
new file mode 100644
index 0000000000..263878ee16
--- /dev/null
+++ b/src/plugins/platforms/android/src/qandroidplatformtheme.h
@@ -0,0 +1,56 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QANDROIDPLATFORMTHEME_H
+#define QANDROIDPLATFORMTHEME_H
+
+#include <qpa/qplatformtheme.h>
+
+class QAndroidPlatformTheme: public QPlatformTheme
+{
+public:
+ virtual QPlatformMenuBar *createPlatformMenuBar() const;
+ virtual QPlatformMenu *createPlatformMenu() const;
+ virtual QPlatformMenuItem *createPlatformMenuItem() const;
+ virtual QVariant themeHint(ThemeHint hint) const;
+};
+
+#endif // QANDROIDPLATFORMTHEME_H
diff --git a/src/plugins/platforms/android/src/raster/qandroidplatformscreen.cpp b/src/plugins/platforms/android/src/raster/qandroidplatformscreen.cpp
new file mode 100644
index 0000000000..409c833db3
--- /dev/null
+++ b/src/plugins/platforms/android/src/raster/qandroidplatformscreen.cpp
@@ -0,0 +1,77 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qandroidplatformscreen.h"
+#include "qandroidplatformintegration.h"
+#include "androidjnimain.h"
+#include "androidjnimenu.h"
+
+QAndroidPlatformScreen::QAndroidPlatformScreen():QFbScreen()
+{
+ mGeometry = QRect(0, 0, QAndroidPlatformIntegration::m_defaultGeometryWidth, QAndroidPlatformIntegration::m_defaultGeometryHeight);
+ mFormat = QImage::Format_RGB16;
+ mDepth = 16;
+ mPhysicalSize.setHeight(QAndroidPlatformIntegration::m_defaultPhysicalSizeHeight);
+ mPhysicalSize.setWidth(QAndroidPlatformIntegration::m_defaultPhysicalSizeWidth);
+ initializeCompositor();
+}
+
+void QAndroidPlatformScreen::topWindowChanged(QWindow *w)
+{
+ QtAndroidMenu::setActiveTopLevelWindow(w);
+}
+
+QRegion QAndroidPlatformScreen::doRedraw()
+{
+ QRegion touched;
+ touched = QFbScreen::doRedraw();
+ if (touched.isEmpty())
+ return touched;
+
+ QtAndroid::flushImage(mGeometry.topLeft(), *mScreenImage, touched.boundingRect());
+ return touched;
+}
+
+QDpi QAndroidPlatformScreen::logicalDpi() const
+{
+ qreal lDpi = QtAndroid::scaledDensity() * 100;
+ return QDpi(lDpi, lDpi);
+}
diff --git a/src/plugins/platforms/android/src/raster/qandroidplatformscreen.h b/src/plugins/platforms/android/src/raster/qandroidplatformscreen.h
new file mode 100644
index 0000000000..cfd503d611
--- /dev/null
+++ b/src/plugins/platforms/android/src/raster/qandroidplatformscreen.h
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QANDROIDPLATFORMSCREEN_H
+#define QANDROIDPLATFORMSCREEN_H
+
+#include <QtPlatformSupport/private/qfbscreen_p.h>
+
+class QAndroidPlatformScreen: public QFbScreen
+{
+ Q_OBJECT
+public:
+ QAndroidPlatformScreen();
+ void topWindowChanged(QWindow *w);
+ QDpi logicalDpi() const;
+
+public slots:
+ QRegion doRedraw();
+
+};
+
+#endif
diff --git a/src/plugins/platforms/android/src/raster/qandroidplatformwindow.cpp b/src/plugins/platforms/android/src/raster/qandroidplatformwindow.cpp
new file mode 100644
index 0000000000..94a69c10c7
--- /dev/null
+++ b/src/plugins/platforms/android/src/raster/qandroidplatformwindow.cpp
@@ -0,0 +1,56 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qandroidplatformwindow.h"
+
+QAndroidPlatformWindow::QAndroidPlatformWindow(QWindow *window) : QFbWindow(window)
+{
+}
+
+void QAndroidPlatformWindow::setGeometry(const QRect &rect)
+{
+ QFbWindow::setGeometry(rect);
+}
+
+void QAndroidPlatformWindow::propagateSizeHints()
+{
+ //shut up warning from default implementation
+}
diff --git a/src/plugins/platforms/android/src/raster/qandroidplatformwindow.h b/src/plugins/platforms/android/src/raster/qandroidplatformwindow.h
new file mode 100644
index 0000000000..3ee815fd69
--- /dev/null
+++ b/src/plugins/platforms/android/src/raster/qandroidplatformwindow.h
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef ANDROIDPLATFORMWINDOW_H
+#define ANDROIDPLATFORMWINDOW_H
+#include <qobject.h>
+#include <QtPlatformSupport/private/qfbwindow_p.h>
+
+class QAndroidPlatformWindow: public QObject, public QFbWindow
+{
+ Q_OBJECT
+public:
+ explicit QAndroidPlatformWindow(QWindow *window);
+
+ void propagateSizeHints();
+
+public slots:
+ void setGeometry(const QRect &rect);
+
+};
+
+#endif // ANDROIDPLATFORMWINDOW_H
diff --git a/src/plugins/platforms/android/src/raster/raster.pri b/src/plugins/platforms/android/src/raster/raster.pri
new file mode 100644
index 0000000000..86e5aa235f
--- /dev/null
+++ b/src/plugins/platforms/android/src/raster/raster.pri
@@ -0,0 +1,7 @@
+INCLUDEPATH += $$PWD
+
+SOURCES += $$PWD/qandroidplatformscreen.cpp \
+ $$PWD/qandroidplatformwindow.cpp
+
+HEADERS += $$PWD/qandroidplatformscreen.h \
+ $$PWD/qandroidplatformwindow.h
diff --git a/src/plugins/platforms/android/src/src.pri b/src/plugins/platforms/android/src/src.pri
new file mode 100644
index 0000000000..76539b50ab
--- /dev/null
+++ b/src/plugins/platforms/android/src/src.pri
@@ -0,0 +1,47 @@
+load(qt_plugin)
+
+QT += core-private gui-private platformsupport-private
+
+CONFIG += qpa/genericunixfontdatabase
+
+OTHER_FILES += $$PWD/android.json
+
+INCLUDEPATH += $$PWD
+INCLUDEPATH += $$PWD/../../../../3rdparty/android/src
+
+SOURCES += $$PWD/androidplatformplugin.cpp \
+ $$PWD/androidjnimain.cpp \
+ $$PWD/androidjniinput.cpp \
+ $$PWD/androidjnimenu.cpp \
+ $$PWD/androidjniclipboard.cpp \
+ $$PWD/qandroidplatformintegration.cpp \
+ $$PWD/qandroidplatformservices.cpp \
+ $$PWD/qandroidassetsfileenginehandler.cpp \
+ $$PWD/qandroidinputcontext.cpp \
+ $$PWD/qandroidplatformfontdatabase.cpp \
+ $$PWD/qandroidplatformclipboard.cpp \
+ $$PWD/qandroidplatformtheme.cpp \
+ $$PWD/qandroidplatformmenubar.cpp \
+ $$PWD/qandroidplatformmenu.cpp \
+ $$PWD/qandroidplatformmenuitem.cpp
+
+
+HEADERS += $$PWD/qandroidplatformintegration.h \
+ $$PWD/androidjnimain.h \
+ $$PWD/androidjniinput.h \
+ $$PWD/androidjnimenu.h \
+ $$PWD/androidjniclipboard.h \
+ $$PWD/qandroidplatformservices.h \
+ $$PWD/qandroidassetsfileenginehandler.h \
+ $$PWD/qandroidinputcontext.h \
+ $$PWD/qandroidplatformfontdatabase.h \
+ $$PWD/qandroidplatformclipboard.h \
+ $$PWD/qandroidplatformtheme.h \
+ $$PWD/qandroidplatformmenubar.h \
+ $$PWD/qandroidplatformmenu.h \
+ $$PWD/qandroidplatformmenuitem.h
+
+
+#Non-standard install directory, QTBUG-29859
+DESTDIR = $$DESTDIR/android
+target.path = $${target.path}/android
diff --git a/src/plugins/platforms/cocoa/cocoa.pro b/src/plugins/platforms/cocoa/cocoa.pro
index 83e2a88e6a..66c4e3c49c 100644
--- a/src/plugins/platforms/cocoa/cocoa.pro
+++ b/src/plugins/platforms/cocoa/cocoa.pro
@@ -78,7 +78,7 @@ HEADERS += qcocoaintegration.h \
RESOURCES += qcocoaresources.qrc
-LIBS += -framework Cocoa -framework IOKit
+LIBS += -framework Cocoa -framework Carbon -framework IOKit
QT += core-private gui-private platformsupport-private
@@ -102,8 +102,5 @@ OTHER_FILES += cocoa.json
# DEFINES += QT_COCOA_ENABLE_ACCESSIBILITY_INSPECTOR
# include ($$PWD/../../../../util/accessibilityinspector/accessibilityinspector.pri)
-# Accessibility is currently unstable and disabled.
-DEFINES += QT_NO_COCOA_ACCESSIBILITY
-
# Window debug support
#DEFINES += QT_COCOA_ENABLE_WINDOW_DEBUG
diff --git a/src/plugins/platforms/cocoa/qcocoaaccessibility.h b/src/plugins/platforms/cocoa/qcocoaaccessibility.h
index 0f1f96814f..3f0367d36a 100644
--- a/src/plugins/platforms/cocoa/qcocoaaccessibility.h
+++ b/src/plugins/platforms/cocoa/qcocoaaccessibility.h
@@ -44,9 +44,6 @@
#include <Cocoa/Cocoa.h>
#include <QtGui>
-
-#ifndef QT_NO_COCOA_ACCESSIBILITY
-
#include <qpa/qplatformaccessibility.h>
class QCococaAccessibility : public QPlatformAccessibility
@@ -81,7 +78,7 @@ namespace QCocoaAccessible {
*/
NSString *macRole(QAccessibleInterface *interface);
-bool shouldBeIgnrored(QAccessibleInterface *interface);
+bool shouldBeIgnored(QAccessibleInterface *interface);
NSString *getTranslatedAction(const QString &qtAction);
NSMutableArray *createTranslatedActionsList(const QStringList &qtActions);
QString translateAction(NSString *nsAction);
@@ -90,6 +87,4 @@ id getValueAttribute(QAccessibleInterface *interface);
}
-#endif // QT_NO_COCOA_ACCESSIBILITY
-
#endif
diff --git a/src/plugins/platforms/cocoa/qcocoaaccessibility.mm b/src/plugins/platforms/cocoa/qcocoaaccessibility.mm
index 070f23f028..34192e85b0 100644
--- a/src/plugins/platforms/cocoa/qcocoaaccessibility.mm
+++ b/src/plugins/platforms/cocoa/qcocoaaccessibility.mm
@@ -41,11 +41,9 @@
#include "qcocoaaccessibility.h"
#include "qcocoaaccessibilityelement.h"
#include <qaccessible.h>
-#include <qaccessible2.h>
+#include <QtGui/private/qaccessible2_p.h>
#include <private/qcore_mac_p.h>
-#ifndef QT_NO_COCOA_ACCESSIBILITY
-
QCococaAccessibility::QCococaAccessibility()
{
@@ -62,7 +60,7 @@ void QCococaAccessibility::notifyAccessibilityUpdate(QAccessibleEvent *event)
if (!object)
return;
- QAccessibleInterface *interface = QAccessible::queryAccessibleInterface(object);
+ QAccessibleInterface *interface = event->accessibleInterface();
if (!interface)
return;
@@ -71,13 +69,11 @@ void QCococaAccessibility::notifyAccessibilityUpdate(QAccessibleEvent *event)
case QAccessible::TextInserted :
case QAccessible::TextRemoved :
case QAccessible::TextUpdated : {
- QCocoaAccessibleElement *element = [QCocoaAccessibleElement createElementWithInterface : interface parent : nil];
+ QCocoaAccessibleElement *element = [QCocoaAccessibleElement createElementWithId : QAccessible::uniqueId(interface) parent : nil];
[element autorelease];
NSAccessibilityPostNotification(element, NSAccessibilityValueChangedNotification);
break; }
-
- default:
- delete interface;
+ default:
break;
}
}
@@ -178,7 +174,7 @@ NSString *macRole(QAccessibleInterface *interface)
the elements are still present in the accessibility tree but is
not used by the screen reader.
*/
-bool shouldBeIgnrored(QAccessibleInterface *interface)
+bool shouldBeIgnored(QAccessibleInterface *interface)
{
// Mac accessibility does not have an attribute that corresponds to the Invisible/Offscreen
// state. Ignore interfaces with those flags set.
@@ -280,6 +276,7 @@ QString translateAction(NSString *nsAction)
bool hasValueAttribute(QAccessibleInterface *interface)
{
+ Q_ASSERT(interface);
const QAccessible::Role qtrole = interface->role();
if (qtrole == QAccessible::EditableText
|| interface->valueInterface()) {
@@ -318,5 +315,3 @@ id getValueAttribute(QAccessibleInterface *interface)
}
} // namespace QCocoaAccessible
-
-#endif // QT_NO_COCOA_ACCESSIBILITY
diff --git a/src/plugins/platforms/cocoa/qcocoaaccessibilityelement.h b/src/plugins/platforms/cocoa/qcocoaaccessibilityelement.h
index 7ebe7a4e9d..c207cbee2d 100644
--- a/src/plugins/platforms/cocoa/qcocoaaccessibilityelement.h
+++ b/src/plugins/platforms/cocoa/qcocoaaccessibilityelement.h
@@ -41,26 +41,25 @@
#ifndef QCOCOAACCESIBILITYELEMENT_H
#define QCOCOAACCESIBILITYELEMENT_H
+#include <QtCore/qglobal.h>
#import <Cocoa/Cocoa.h>
#import <AppKit/NSAccessibility.h>
-#ifndef QT_NO_COCOA_ACCESSIBILITY
+#import <qaccessible.h>
@class QCocoaAccessibleElement;
@interface QCocoaAccessibleElement : NSObject {
NSString *role;
- NSObject * parent;
- void *accessibleInterface;
+ NSObject *parent;
+ QAccessible::Id axid;
}
-- (id)initWithInterface:(void *)anQAccessibleInterface parent:(id)aParent;
-+ (QCocoaAccessibleElement *)createElementWithInterface:(void *)anQAccessibleInterface parent:(id)aParent;
+- (id)initWithId:(QAccessible::Id)anId parent:(id)aParent;
++ (QCocoaAccessibleElement *)createElementWithId:(QAccessible::Id)anId parent:(id)aParent;
@end
-#endif // QT_NO_COCOA_ACCESSIBILITY
-
#endif
diff --git a/src/plugins/platforms/cocoa/qcocoaaccessibilityelement.mm b/src/plugins/platforms/cocoa/qcocoaaccessibilityelement.mm
index f5f37c5b00..1d6797e51a 100644
--- a/src/plugins/platforms/cocoa/qcocoaaccessibilityelement.mm
+++ b/src/plugins/platforms/cocoa/qcocoaaccessibilityelement.mm
@@ -43,52 +43,47 @@
#include "qcocoahelpers.h"
#include <QAccessible>
-#include "QAccessibleActionInterface"
+#include <QtGui/private/qaccessible2_p.h>
#import <AppKit/NSAccessibility.h>
-#ifndef QT_NO_COCOA_ACCESSIBILITY
-
-static QAccessibleInterface *acast(void *ptr)
-{
- return reinterpret_cast<QAccessibleInterface *>(ptr);
-}
-
@implementation QCocoaAccessibleElement
-- (id)initWithInterface:(void *)anQAccessibleInterface parent:(id)aParent
+- (id)initWithId:(QAccessible::Id)anId parent:(id)aParent
{
+ Q_ASSERT((int)anId < 0);
self = [super init];
if (self) {
- accessibleInterface = anQAccessibleInterface;
- role = QCocoaAccessible::macRole(acast(accessibleInterface));
+ axid = anId;
+ QAccessibleInterface *iface = QAccessible::accessibleInterface(axid);
+ Q_ASSERT(iface);
+ role = QCocoaAccessible::macRole(iface);
parent = aParent;
}
return self;
}
-+ (QCocoaAccessibleElement *)createElementWithInterface:(void *)anQAccessibleInterface parent:(id)aParent
++ (QCocoaAccessibleElement *)createElementWithId:(QAccessible::Id)anId parent:(id)aParent
{
- return [[self alloc] initWithInterface:anQAccessibleInterface parent:aParent];
+ return [[self alloc] initWithId:anId parent:aParent];
}
- (void)dealloc {
[super dealloc];
- delete acast(accessibleInterface);
}
- (BOOL)isEqual:(id)object {
if ([object isKindOfClass:[QCocoaAccessibleElement class]]) {
QCocoaAccessibleElement *other = object;
- return acast(other->accessibleInterface)->object() == acast(accessibleInterface)->object();
+ return other->axid == axid;
} else {
return NO;
}
}
- (NSUInteger)hash {
- return qHash(acast(accessibleInterface)->object());
+ return axid;
}
//
@@ -99,6 +94,11 @@ static QAccessibleInterface *acast(void *ptr)
- (NSArray *)accessibilityAttributeNames {
static NSArray *defaultAttributes = nil;
+
+ QAccessibleInterface *iface = QAccessible::accessibleInterface(axid);
+ if (!iface)
+ return defaultAttributes;
+
if (defaultAttributes == nil) {
defaultAttributes = [[NSArray alloc] initWithObjects:
NSAccessibilityRoleAttribute,
@@ -118,7 +118,7 @@ static QAccessibleInterface *acast(void *ptr)
NSMutableArray *attributes = [[NSMutableArray alloc] initWithCapacity : [defaultAttributes count]];
[attributes addObjectsFromArray : defaultAttributes];
- if (QCocoaAccessible::hasValueAttribute(acast(accessibleInterface))) {
+ if (QCocoaAccessible::hasValueAttribute(iface)) {
[attributes addObject : NSAccessibilityValueAttribute];
}
@@ -126,22 +126,33 @@ static QAccessibleInterface *acast(void *ptr)
}
- (id)accessibilityAttributeValue:(NSString *)attribute {
+ QAccessibleInterface *iface = QAccessible::accessibleInterface(axid);
+ if (!iface) {
+ qWarning() << "Called attribute on invalid object: " << axid;
+ return nil;
+ }
+
if ([attribute isEqualToString:NSAccessibilityRoleAttribute]) {
return role;
} else if ([attribute isEqualToString:NSAccessibilityRoleDescriptionAttribute]) {
return NSAccessibilityRoleDescription(role, nil);
} else if ([attribute isEqualToString:NSAccessibilityChildrenAttribute]) {
- int numKids = acast(accessibleInterface)->childCount();
+
+ int numKids = iface->childCount();
+ // qDebug() << "Children for: " << axid << iface << " are: " << numKids;
NSMutableArray *kids = [NSMutableArray arrayWithCapacity:numKids];
for (int i = 0; i < numKids; ++i) {
- QAccessibleInterface *childInterface = acast(accessibleInterface)->child(i);
- QCocoaAccessibleElement *element = [QCocoaAccessibleElement createElementWithInterface:(void*)childInterface parent:self];
+ QAccessibleInterface *child = iface->child(i);
+ Q_ASSERT(child);
+ QAccessible::Id childId = QAccessible::uniqueId(child);
+ //qDebug() << " kid: " << childId << child;
+ QCocoaAccessibleElement *element = [QCocoaAccessibleElement createElementWithId:childId parent:self];
[kids addObject: element];
[element release];
}
-
return kids;
+
} else if ([attribute isEqualToString:NSAccessibilityFocusedAttribute]) {
// Just check if the app thinks we're focused.
id focusedElement = [NSApp accessibilityAttributeValue:NSAccessibilityFocusedUIElementAttribute];
@@ -155,23 +166,23 @@ static QAccessibleInterface *acast(void *ptr)
// We're in the same top level element as our parent.
return [parent accessibilityAttributeValue:NSAccessibilityTopLevelUIElementAttribute];
} else if ([attribute isEqualToString:NSAccessibilityPositionAttribute]) {
- QPoint qtPosition = acast(accessibleInterface)->rect().topLeft();
- QSize qtSize = acast(accessibleInterface)->rect().size();
+ QPoint qtPosition = iface->rect().topLeft();
+ QSize qtSize = iface->rect().size();
return [NSValue valueWithPoint: NSMakePoint(qtPosition.x(), qt_mac_flipYCoordinate(qtPosition.y() + qtSize.height()))];
} else if ([attribute isEqualToString:NSAccessibilitySizeAttribute]) {
- QSize qtSize = acast(accessibleInterface)->rect().size();
+ QSize qtSize = iface->rect().size();
return [NSValue valueWithSize: NSMakeSize(qtSize.width(), qtSize.height())];
} else if ([attribute isEqualToString:NSAccessibilityDescriptionAttribute]) {
- return QCFString::toNSString(acast(accessibleInterface)->text(QAccessible::Name));
+ return QCFString::toNSString(iface->text(QAccessible::Name));
} else if ([attribute isEqualToString:NSAccessibilityEnabledAttribute]) {
- return [NSNumber numberWithBool:!acast(accessibleInterface)->state().disabled];
+ return [NSNumber numberWithBool:!iface->state().disabled];
} else if ([attribute isEqualToString:NSAccessibilityValueAttribute]) {
// VoiceOver asks for the value attribute for all elements. Return nil
// if we don't want the element to have a value attribute.
- if (!QCocoaAccessible::hasValueAttribute(acast(accessibleInterface)))
+ if (!QCocoaAccessible::hasValueAttribute(iface))
return nil;
- return QCocoaAccessible::getValueAttribute(acast(accessibleInterface));
+ return QCocoaAccessible::getValueAttribute(iface);
}
return nil;
@@ -196,8 +207,11 @@ static QAccessibleInterface *acast(void *ptr)
- (NSArray *)accessibilityActionNames {
NSMutableArray * nsActions = [NSMutableArray new];
+ QAccessibleInterface *iface = QAccessible::accessibleInterface(axid);
+ if (!iface)
+ return nsActions;
- QAccessibleActionInterface *actionInterface = acast(accessibleInterface)->actionInterface();
+ QAccessibleActionInterface *actionInterface = iface->actionInterface();
if (actionInterface) {
QStringList supportedActionNames = actionInterface->actionNames();
@@ -212,48 +226,58 @@ static QAccessibleInterface *acast(void *ptr)
}
- (NSString *)accessibilityActionDescription:(NSString *)action {
- QAccessibleActionInterface *actionInterface = acast(accessibleInterface)->actionInterface();
- QString qtAction = QCocoaAccessible::translateAction(action);
+ QAccessibleInterface *iface = QAccessible::accessibleInterface(axid);
+ if (!iface)
+ return nil; // FIXME is that the right return type??
+ QAccessibleActionInterface *actionInterface = iface->actionInterface();
+ if (actionInterface) {
+ QString qtAction = QCocoaAccessible::translateAction(action);
- // Return a description from the action interface if this action is not known to the OS.
- if (qtAction.isEmpty()) {
- QString description = actionInterface->localizedActionDescription(qtAction);
- return QCFString::toNSString(description);
+ // Return a description from the action interface if this action is not known to the OS.
+ if (qtAction.isEmpty()) {
+ QString description = actionInterface->localizedActionDescription(qtAction);
+ return QCFString::toNSString(description);
+ }
}
return NSAccessibilityActionDescription(action);
}
- (void)accessibilityPerformAction:(NSString *)action {
- QAccessibleActionInterface *actionInterface = acast(accessibleInterface)->actionInterface();
- if (actionInterface) {
- actionInterface->doAction(QCocoaAccessible::translateAction(action));
+ QAccessibleInterface *iface = QAccessible::accessibleInterface(axid);
+ if (iface) {
+ QAccessibleActionInterface *actionInterface = iface->actionInterface();
+ if (actionInterface) {
+ actionInterface->doAction(QCocoaAccessible::translateAction(action));
+ }
}
}
// misc
- (BOOL)accessibilityIsIgnored {
- return QCocoaAccessible::shouldBeIgnrored(acast(accessibleInterface));
+ return false; //QCocoaAccessible::shouldBeIgnored(QAccessible::accessibleInterface(id));
}
- (id)accessibilityHitTest:(NSPoint)point {
-
- if (!accessibleInterface)
- return NSAccessibilityUnignoredAncestor(self);
-
- if (!acast(accessibleInterface)->isValid())
+ QAccessibleInterface *iface = QAccessible::accessibleInterface(axid);
+ if (!iface || !iface->isValid()) {
+// qDebug() << "Hit test: INVALID";
return NSAccessibilityUnignoredAncestor(self);
+ }
- QAccessibleInterface *childInterface = acast(accessibleInterface)->childAt(point.x, qt_mac_flipYCoordinate(point.y));
+ QAccessibleInterface *childInterface = iface->childAt(point.x, qt_mac_flipYCoordinate(point.y));
// No child found, meaning we hit this element.
if (!childInterface) {
- return NSAccessibilityUnignoredAncestor(self);
+// qDebug() << "Hit test returns: " << id << iface;
+ return self;
+ //return NSAccessibilityUnignoredAncestor(self);
}
+ QAccessible::Id childId = QAccessible::uniqueId(childInterface);
// hit a child, forward to child accessible interface.
- QCocoaAccessibleElement *accessibleElement = [QCocoaAccessibleElement createElementWithInterface:childInterface parent:self];
+ QCocoaAccessibleElement *accessibleElement = [QCocoaAccessibleElement createElementWithId:childId parent:self];
[accessibleElement autorelease];
return [accessibleElement accessibilityHitTest:point];
@@ -264,6 +288,3 @@ static QAccessibleInterface *acast(void *ptr)
}
@end
-
-#endif // QT_NO_COCOA_ACCESSIBILITY
-
diff --git a/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.h b/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.h
index 6dd7ea2fb3..e44b2d1b6d 100644
--- a/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.h
+++ b/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.h
@@ -93,19 +93,6 @@
@class QT_MANGLE_NAMESPACE(QCocoaMenuLoader);
-#if MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_5
-
-@protocol NSApplicationDelegate <NSObject>
-- (NSApplicationTerminateReply)applicationShouldTerminate:(NSApplication *)sender;
-- (void)applicationDidFinishLaunching:(NSNotification *)aNotification;
-- (void)application:(NSApplication *)sender openFiles:(NSArray *)filenames;
-- (BOOL)applicationShouldTerminateAfterLastWindowClosed:(NSApplication *)sender;
-- (void)applicationDidBecomeActive:(NSNotification *)notification;
-- (void)applicationDidResignActive:(NSNotification *)notification;
-@end
-
-#endif
-
@interface QT_MANGLE_NAMESPACE(QCocoaApplicationDelegate) : NSObject <NSApplicationDelegate> {
bool startedQuit;
NSMenu *dockMenu;
diff --git a/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm b/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm
index e756c375f3..f676d613bc 100644
--- a/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm
+++ b/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.mm
@@ -145,8 +145,9 @@ static void cleanupCocoaApplicationDelegate()
dockMenu = newMenu;
}
-- (NSMenu *)applicationDockMenu
+- (NSMenu *)applicationDockMenu:(NSApplication *)sender
{
+ Q_UNUSED(sender);
return [[dockMenu retain] autorelease];
}
@@ -206,7 +207,6 @@ static void cleanupCocoaApplicationDelegate()
// events while the event loop is still running.
const QWindowList topLevels = QGuiApplication::topLevelWindows();
for (int i = 0; i < topLevels.size(); ++i) {
- QWindow *window = topLevels.at(i);
topLevels.at(i)->close();
}
diff --git a/src/plugins/platforms/cocoa/qcocoabackingstore.mm b/src/plugins/platforms/cocoa/qcocoabackingstore.mm
index 7f022da4c3..4881dcef71 100644
--- a/src/plugins/platforms/cocoa/qcocoabackingstore.mm
+++ b/src/plugins/platforms/cocoa/qcocoabackingstore.mm
@@ -73,7 +73,9 @@ QPaintDevice *QCocoaBackingStore::paintDevice()
}
#endif
- m_qImage = QImage(m_requestedSize * scaleFactor, QImage::Format_ARGB32_Premultiplied);
+ QImage::Format format = window()->format().hasAlpha()
+ ? QImage::Format_ARGB32_Premultiplied : QImage::Format_RGB32;
+ m_qImage = QImage(m_requestedSize * scaleFactor, format);
m_qImage.setDevicePixelRatio(scaleFactor);
}
return &m_qImage;
@@ -90,8 +92,10 @@ void QCocoaBackingStore::flush(QWindow *win, const QRegion &region, const QPoint
// m_cgImage is only a reference to the data inside m_qImage, it is not a copy.
CGImageRelease(m_cgImage);
m_cgImage = 0;
- if (QCocoaWindow *cocoaWindow = static_cast<QCocoaWindow *>(win->handle()))
- [cocoaWindow->m_contentView flushBackingStore:this region:region offset:offset];
+ if (!m_qImage.isNull()) {
+ if (QCocoaWindow *cocoaWindow = static_cast<QCocoaWindow *>(win->handle()))
+ [cocoaWindow->m_qtView flushBackingStore:this region:region offset:offset];
+ }
}
void QCocoaBackingStore::resize(const QSize &size, const QRegion &)
diff --git a/src/plugins/platforms/cocoa/qcocoacursor.mm b/src/plugins/platforms/cocoa/qcocoacursor.mm
index a36a855bcd..12808b7041 100644
--- a/src/plugins/platforms/cocoa/qcocoacursor.mm
+++ b/src/plugins/platforms/cocoa/qcocoacursor.mm
@@ -65,8 +65,9 @@ void QCocoaCursor::changeCursor(QCursor *cursor, QWindow *window)
{
Q_UNUSED(window);
+ const Qt::CursorShape newShape = cursor ? cursor->shape() : Qt::ArrowCursor;
// Check for a suitable built-in NSCursor first:
- switch (cursor->shape()) {
+ switch (newShape) {
case Qt::ArrowCursor:
[[NSCursor arrowCursor] set];
break;
@@ -104,7 +105,7 @@ void QCocoaCursor::changeCursor(QCursor *cursor, QWindow *window)
default : {
// No suitable OS cursor exist, use cursors provided
// by Qt for the rest. Check for a cached cursor:
- NSCursor *cocoaCursor = m_cursors.value(cursor->shape());
+ NSCursor *cocoaCursor = m_cursors.value(newShape);
if (cocoaCursor && cursor->shape() == Qt::BitmapCursor) {
[cocoaCursor release];
cocoaCursor = 0;
@@ -115,7 +116,7 @@ void QCocoaCursor::changeCursor(QCursor *cursor, QWindow *window)
[[NSCursor arrowCursor] set];
return;
}
- m_cursors.insert(cursor->shape(), cocoaCursor);
+ m_cursors.insert(newShape, cocoaCursor);
}
[cocoaCursor set];
diff --git a/src/plugins/platforms/cocoa/qcocoaeventdispatcher.h b/src/plugins/platforms/cocoa/qcocoaeventdispatcher.h
index f63ac0d205..93476ee1b4 100644
--- a/src/plugins/platforms/cocoa/qcocoaeventdispatcher.h
+++ b/src/plugins/platforms/cocoa/qcocoaeventdispatcher.h
@@ -93,6 +93,7 @@
#include <QtGui/qwindowdefs.h>
#include <QtCore/private/qabstracteventdispatcher_p.h>
#include <QtCore/private/qtimerinfo_unix_p.h>
+#include <QtPlatformSupport/private/qcfsocketnotifier_p.h>
#include <CoreFoundation/CoreFoundation.h>
@@ -132,16 +133,9 @@ public:
void wakeUp();
void interrupt();
void flush();
-};
-struct MacSocketInfo {
- MacSocketInfo() : socket(0), runloop(0), readNotifier(0), writeNotifier(0) {}
- CFSocketRef socket;
- CFRunLoopSourceRef runloop;
- QObject *readNotifier;
- QObject *writeNotifier;
+ friend void qt_mac_maybeCancelWaitForMoreEventsForwarder(QAbstractEventDispatcher *eventDispatcher);
};
-typedef QHash<int, MacSocketInfo *> MacSocketHash;
class QCocoaEventDispatcherPrivate : public QAbstractEventDispatcherPrivate
{
@@ -183,7 +177,7 @@ public:
void maybeCancelWaitForMoreEvents();
void ensureNSAppInitialized();
- MacSocketHash macSockets;
+ QCFSocketNotifier cfSocketNotifier;
QList<void *> queuedUserInputEvents; // NSEvent *
CFRunLoopSourceRef postedEventsSource;
CFRunLoopObserverRef waitingObserver;
diff --git a/src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm b/src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm
index a0734530c5..5c487b0bdd 100644
--- a/src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm
+++ b/src/plugins/platforms/cocoa/qcocoaeventdispatcher.mm
@@ -149,10 +149,10 @@ void QCocoaEventDispatcherPrivate::maybeStartCFRunLoopTimer()
CFTimeInterval oneyear = CFTimeInterval(3600. * 24. * 365.);
// Q: when should the CFRunLoopTimer fire for the first time?
- struct timeval tv;
+ struct timespec tv;
if (timerInfoList.timerWait(tv)) {
// A: when we have timers to fire, of course
- interval = qMax(tv.tv_sec + tv.tv_usec / 1000000., 0.0000001);
+ interval = qMax(tv.tv_sec + tv.tv_nsec / 1000000000., 0.0000001);
} else {
// this shouldn't really happen, but in case it does, set the timer to fire a some point in the distant future
interval = oneyear;
@@ -172,10 +172,10 @@ void QCocoaEventDispatcherPrivate::maybeStartCFRunLoopTimer()
CFTimeInterval interval;
// Q: when should the timer first next?
- struct timeval tv;
+ struct timespec tv;
if (timerInfoList.timerWait(tv)) {
// A: when we have timers to fire, of course
- interval = qMax(tv.tv_sec + tv.tv_usec / 1000000., 0.0000001);
+ interval = qMax(tv.tv_sec + tv.tv_nsec / 1000000000., 0.0000001);
} else {
// no timers can fire, but we cannot stop the CFRunLoopTimer, set the timer to fire at some
// point in the distant future (the timer interval is one year)
@@ -270,58 +270,6 @@ QCocoaEventDispatcher::registeredTimers(QObject *object) const
return d->timerInfoList.registeredTimers(object);
}
-/**************************************************************************
- Socket Notifiers
- *************************************************************************/
-void qt_mac_socket_callback(CFSocketRef s, CFSocketCallBackType callbackType, CFDataRef,
- const void *, void *info) {
- QCocoaEventDispatcherPrivate *const eventDispatcher
- = static_cast<QCocoaEventDispatcherPrivate *>(info);
- int nativeSocket = CFSocketGetNative(s);
- MacSocketInfo *socketInfo = eventDispatcher->macSockets.value(nativeSocket);
- QEvent notifierEvent(QEvent::SockAct);
-
- // There is a race condition that happen where we disable the notifier and
- // the kernel still has a notification to pass on. We then get this
- // notification after we've successfully disabled the CFSocket, but our Qt
- // notifier is now gone. The upshot is we have to check the notifier
- // everytime.
- if (callbackType == kCFSocketReadCallBack) {
- if (socketInfo->readNotifier)
- QGuiApplication::sendEvent(socketInfo->readNotifier, &notifierEvent);
- } else if (callbackType == kCFSocketWriteCallBack) {
- if (socketInfo->writeNotifier)
- QGuiApplication::sendEvent(socketInfo->writeNotifier, &notifierEvent);
- }
-
- eventDispatcher->maybeCancelWaitForMoreEvents();
-}
-
-/*
- Adds a loop source for the given socket to the current run loop.
-*/
-CFRunLoopSourceRef qt_mac_add_socket_to_runloop(const CFSocketRef socket)
-{
- CFRunLoopSourceRef loopSource = CFSocketCreateRunLoopSource(kCFAllocatorDefault, socket, 0);
- if (!loopSource)
- return 0;
-
- CFRunLoopAddSource(mainRunLoop(), loopSource, kCFRunLoopCommonModes);
- return loopSource;
-}
-
-/*
- Removes the loop source for the given socket from the current run loop.
-*/
-void qt_mac_remove_socket_from_runloop(const CFSocketRef socket, CFRunLoopSourceRef runloop)
-{
- Q_ASSERT(runloop);
- CFRunLoopRemoveSource(mainRunLoop(), runloop, kCFRunLoopCommonModes);
- CFSocketDisableCallBacks(socket, kCFSocketReadCallBack);
- CFSocketDisableCallBacks(socket, kCFSocketWriteCallBack);
- CFRunLoopSourceInvalidate(runloop);
-}
-
/*
Register a QSocketNotifier with the mac event system by creating a CFSocket with
with a read/write callback.
@@ -331,130 +279,14 @@ void qt_mac_remove_socket_from_runloop(const CFSocketRef socket, CFRunLoopSource
*/
void QCocoaEventDispatcher::registerSocketNotifier(QSocketNotifier *notifier)
{
- Q_ASSERT(notifier);
- int nativeSocket = notifier->socket();
- int type = notifier->type();
-#ifndef QT_NO_DEBUG
- if (nativeSocket < 0 || nativeSocket > FD_SETSIZE) {
- qWarning("QSocketNotifier: Internal error");
- return;
- } else if (notifier->thread() != thread()
- || thread() != QThread::currentThread()) {
- qWarning("QSocketNotifier: socket notifiers cannot be enabled from another thread");
- return;
- }
-#endif
-
Q_D(QCocoaEventDispatcher);
-
- if (type == QSocketNotifier::Exception) {
- qWarning("QSocketNotifier::Exception is not supported on Mac OS X");
- return;
- }
-
- // Check if we have a CFSocket for the native socket, create one if not.
- MacSocketInfo *socketInfo = d->macSockets.value(nativeSocket);
- if (!socketInfo) {
- socketInfo = new MacSocketInfo();
-
- // Create CFSocket, specify that we want both read and write callbacks (the callbacks
- // are enabled/disabled later on).
- const int callbackTypes = kCFSocketReadCallBack | kCFSocketWriteCallBack;
- CFSocketContext context = {0, d, 0, 0, 0};
- socketInfo->socket = CFSocketCreateWithNative(kCFAllocatorDefault, nativeSocket, callbackTypes, qt_mac_socket_callback, &context);
- if (CFSocketIsValid(socketInfo->socket) == false) {
- qWarning("QEventDispatcherMac::registerSocketNotifier: Failed to create CFSocket");
- return;
- }
-
- CFOptionFlags flags = CFSocketGetSocketFlags(socketInfo->socket);
- flags |= kCFSocketAutomaticallyReenableWriteCallBack; //QSocketNotifier stays enabled after a write
- flags &= ~kCFSocketCloseOnInvalidate; //QSocketNotifier doesn't close the socket upon destruction/invalidation
- CFSocketSetSocketFlags(socketInfo->socket, flags);
-
- // Add CFSocket to runloop.
- if(!(socketInfo->runloop = qt_mac_add_socket_to_runloop(socketInfo->socket))) {
- qWarning("QEventDispatcherMac::registerSocketNotifier: Failed to add CFSocket to runloop");
- CFSocketInvalidate(socketInfo->socket);
- CFRelease(socketInfo->socket);
- return;
- }
-
- // Disable both callback types by default. This must be done after
- // we add the CFSocket to the runloop, or else these calls will have
- // no effect.
- CFSocketDisableCallBacks(socketInfo->socket, kCFSocketReadCallBack);
- CFSocketDisableCallBacks(socketInfo->socket, kCFSocketWriteCallBack);
-
- d->macSockets.insert(nativeSocket, socketInfo);
- }
-
- // Increment read/write counters and select enable callbacks if necessary.
- if (type == QSocketNotifier::Read) {
- Q_ASSERT(socketInfo->readNotifier == 0);
- socketInfo->readNotifier = notifier;
- CFSocketEnableCallBacks(socketInfo->socket, kCFSocketReadCallBack);
- } else if (type == QSocketNotifier::Write) {
- Q_ASSERT(socketInfo->writeNotifier == 0);
- socketInfo->writeNotifier = notifier;
- CFSocketEnableCallBacks(socketInfo->socket, kCFSocketWriteCallBack);
- }
+ d->cfSocketNotifier.registerSocketNotifier(notifier);
}
-/*
- Unregister QSocketNotifer. The CFSocket correspoding to this notifier is
- removed from the runloop of this is the last notifier that users
- that CFSocket.
-*/
void QCocoaEventDispatcher::unregisterSocketNotifier(QSocketNotifier *notifier)
{
- Q_ASSERT(notifier);
- int nativeSocket = notifier->socket();
- int type = notifier->type();
-#ifndef QT_NO_DEBUG
- if (nativeSocket < 0 || nativeSocket > FD_SETSIZE) {
- qWarning("QSocketNotifier: Internal error");
- return;
- } else if (notifier->thread() != thread() || thread() != QThread::currentThread()) {
- qWarning("QSocketNotifier: socket notifiers cannot be disabled from another thread");
- return;
- }
-#endif
-
Q_D(QCocoaEventDispatcher);
-
- if (type == QSocketNotifier::Exception) {
- qWarning("QSocketNotifier::Exception is not supported on Mac OS X");
- return;
- }
- MacSocketInfo *socketInfo = d->macSockets.value(nativeSocket);
- if (!socketInfo) {
- qWarning("QEventDispatcherMac::unregisterSocketNotifier: Tried to unregister a not registered notifier");
- return;
- }
-
- // Decrement read/write counters and disable callbacks if necessary.
- if (type == QSocketNotifier::Read) {
- Q_ASSERT(notifier == socketInfo->readNotifier);
- socketInfo->readNotifier = 0;
- CFSocketDisableCallBacks(socketInfo->socket, kCFSocketReadCallBack);
- } else if (type == QSocketNotifier::Write) {
- Q_ASSERT(notifier == socketInfo->writeNotifier);
- socketInfo->writeNotifier = 0;
- CFSocketDisableCallBacks(socketInfo->socket, kCFSocketWriteCallBack);
- }
-
- // Remove CFSocket from runloop if this was the last QSocketNotifier.
- if (socketInfo->readNotifier == 0 && socketInfo->writeNotifier == 0) {
- if (CFSocketIsValid(socketInfo->socket))
- qt_mac_remove_socket_from_runloop(socketInfo->socket, socketInfo->runloop);
- CFRunLoopSourceInvalidate(socketInfo->runloop);
- CFRelease(socketInfo->runloop);
- CFSocketInvalidate(socketInfo->socket);
- CFRelease(socketInfo->socket);
- delete socketInfo;
- d->macSockets.remove(nativeSocket);
- }
+ d->cfSocketNotifier.unregisterSocketNotifier(notifier);
}
bool QCocoaEventDispatcher::hasPendingEvents()
@@ -467,37 +299,35 @@ bool QCocoaEventDispatcher::hasPendingEvents()
static bool IsMouseOrKeyEvent( NSEvent* event )
{
bool result = false;
-
+
switch( [event type] )
{
- case NSLeftMouseDown:
- case NSLeftMouseUp:
- case NSRightMouseDown:
- case NSRightMouseUp:
+ case NSLeftMouseDown:
+ case NSLeftMouseUp:
+ case NSRightMouseDown:
+ case NSRightMouseUp:
case NSMouseMoved: // ??
- case NSLeftMouseDragged:
+ case NSLeftMouseDragged:
case NSRightMouseDragged:
- case NSMouseEntered:
- case NSMouseExited:
- case NSKeyDown:
- case NSKeyUp:
+ case NSMouseEntered:
+ case NSMouseExited:
+ case NSKeyDown:
+ case NSKeyUp:
case NSFlagsChanged: // key modifiers changed?
case NSCursorUpdate: // ??
- case NSScrollWheel:
- case NSTabletPoint:
- case NSTabletProximity:
- case NSOtherMouseDown:
- case NSOtherMouseUp:
+ case NSScrollWheel:
+ case NSTabletPoint:
+ case NSTabletProximity:
+ case NSOtherMouseDown:
+ case NSOtherMouseUp:
case NSOtherMouseDragged:
#ifndef QT_NO_GESTURES
-#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
case NSEventTypeGesture: // touch events
case NSEventTypeMagnify:
case NSEventTypeSwipe:
case NSEventTypeRotate:
case NSEventTypeBeginGesture:
case NSEventTypeEndGesture:
-#endif
#endif // QT_NO_GESTURES
result = true;
break;
@@ -809,7 +639,7 @@ static void setChildrenWorksWhenModal(QWindow *window, bool worksWhenModal)
Q_UNUSED(worksWhenModal)
// For NSPanels (but not NSWindows, sadly), we can set the flag
- // worksWhenModal, so that they are active even when they are not modal.
+ // worksWhenModal, so that they are active even when they are not modal.
/*
### not ported
QList<QDialog *> dialogs = window->findChildren<QDialog *>();
@@ -850,7 +680,7 @@ void QCocoaEventDispatcherPrivate::cleanupModalSessions()
// this to actually end the sessions for real (rather than at the
// point they were marked as stopped), is that ending a session
// when no other session runs below it on the stack will make cocoa
- // drop some events on the floor.
+ // drop some events on the floor.
QCocoaAutoReleasePool pool;
int stackSize = cocoaModalSessionStack.size();
@@ -942,11 +772,19 @@ QCocoaEventDispatcherPrivate::QCocoaEventDispatcherPrivate()
{
}
+void qt_mac_maybeCancelWaitForMoreEventsForwarder(QAbstractEventDispatcher *eventDispatcher)
+{
+ static_cast<QCocoaEventDispatcher *>(eventDispatcher)->d_func()->maybeCancelWaitForMoreEvents();
+}
+
QCocoaEventDispatcher::QCocoaEventDispatcher(QObject *parent)
: QAbstractEventDispatcher(*new QCocoaEventDispatcherPrivate, parent)
{
Q_D(QCocoaEventDispatcher);
+ d->cfSocketNotifier.setHostEventDispatcher(this);
+ d->cfSocketNotifier.setMaybeCancelWaitForMoreEventsCallback(qt_mac_maybeCancelWaitForMoreEventsForwarder);
+
// keep our sources running when modal loops are running
CFRunLoopAddCommonMode(mainRunLoop(), (CFStringRef) NSModalPanelRunLoopMode);
@@ -1021,7 +859,7 @@ void QCocoaEventDispatcherPrivate::processPostedEvents()
if (currentExecIsNSAppRun) {
// The event dispatcher has been interrupted. But since
// [NSApplication run] is running the event loop, we
- // delayed stopping it until now (to let cocoa process
+ // delayed stopping it until now (to let cocoa process
// pending cocoa events first).
if (currentModalSessionCached)
temporarilyStopAllModalSessions();
@@ -1129,17 +967,8 @@ QCocoaEventDispatcher::~QCocoaEventDispatcher()
[nsevent release];
}
- // Remove CFSockets from the runloop.
- for (MacSocketHash::ConstIterator it = d->macSockets.constBegin(); it != d->macSockets.constEnd(); ++it) {
- MacSocketInfo *socketInfo = (*it);
- if (CFSocketIsValid(socketInfo->socket)) {
- qt_mac_remove_socket_from_runloop(socketInfo->socket, socketInfo->runloop);
- CFRunLoopSourceInvalidate(socketInfo->runloop);
- CFRelease(socketInfo->runloop);
- CFSocketInvalidate(socketInfo->socket);
- CFRelease(socketInfo->socket);
- }
- }
+ d->cfSocketNotifier.removeSocketNotifiers();
+
CFRunLoopRemoveSource(mainRunLoop(), d->postedEventsSource, kCFRunLoopCommonModes);
CFRelease(d->postedEventsSource);
diff --git a/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm b/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm
index 61646041fb..1e9acd79ed 100644
--- a/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm
+++ b/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm
@@ -77,11 +77,7 @@ typedef QSharedPointer<QFileDialogOptions> SharedPointerFileDialogOptions;
@class QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate);
@interface QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate)
-#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
: NSObject<NSOpenSavePanelDelegate>
-#else
- : NSObject
-#endif
{
@public
NSOpenPanel *mOpenPanel;
@@ -216,7 +212,7 @@ static QString strippedText(QString s)
- (void)closePanel
{
*mCurrentSelection = QT_PREPEND_NAMESPACE(QCFString::toQString)([[mSavePanel URL] path]);
- if ([mSavePanel respondsToSelector:@selector(closePanel:)])
+ if ([mSavePanel respondsToSelector:@selector(close)])
[mSavePanel close];
if ([mSavePanel isSheet])
[NSApp endSheet: mSavePanel];
@@ -230,6 +226,7 @@ static QString strippedText(QString s)
bool selectable = (mOptions->acceptMode() == QFileDialogOptions::AcceptSave)
|| [self panel:nil shouldShowFilename:filepath];
+ [self updateProperties];
[mOpenPanel setAllowedFileTypes:nil];
[mOpenPanel setDirectoryURL:selectable ? [NSURL fileURLWithPath:QT_PREPEND_NAMESPACE(QCFString::toNSString)(info.filePath())]
: [NSURL fileURLWithPath:QT_PREPEND_NAMESPACE(QCFString::toNSString)(info.path())]];
@@ -250,7 +247,7 @@ static QString strippedText(QString s)
[mSavePanel setDirectoryURL:selectable ? [NSURL fileURLWithPath:QT_PREPEND_NAMESPACE(QCFString::toNSString)(info.filePath())]
: [NSURL fileURLWithPath:QT_PREPEND_NAMESPACE(QCFString::toNSString)(info.path())]];
- [mSavePanel setNameFieldStringValue:selectable ? QT_PREPEND_NAMESPACE(QCFString::toNSString)(info.fileName()) : nil];
+ [mSavePanel setNameFieldStringValue:selectable ? QT_PREPEND_NAMESPACE(QCFString::toNSString)(info.fileName()) : @""];
// Call processEvents in case the event dispatcher has been interrupted, and needs to do
// cleanup of modal sessions. Do this before showing the native dialog, otherwise it will
@@ -274,9 +271,10 @@ static QString strippedText(QString s)
bool selectable = (mOptions->acceptMode() == QFileDialogOptions::AcceptSave)
|| [self panel:nil shouldShowFilename:filepath];
+ [self updateProperties];
[mSavePanel setDirectoryURL:selectable ? [NSURL fileURLWithPath:QT_PREPEND_NAMESPACE(QCFString::toNSString)(info.filePath())]
: [NSURL fileURLWithPath:QT_PREPEND_NAMESPACE(QCFString::toNSString)(info.path())]];
- [mSavePanel setNameFieldStringValue:selectable ? QT_PREPEND_NAMESPACE(QCFString::toNSString)(info.fileName()) : nil];
+ [mSavePanel setNameFieldStringValue:selectable ? QT_PREPEND_NAMESPACE(QCFString::toNSString)(info.fileName()) : @""];
NSWindow *nsparent = static_cast<NSWindow *>(qGuiApp->platformNativeInterface()->nativeResourceForWindow("nswindow", parent));
[mSavePanel beginSheetModalForWindow:nsparent completionHandler:^(NSInteger result){
@@ -405,6 +403,9 @@ static QString strippedText(QString s)
[mSavePanel setCanCreateDirectories:!(mOptions->testOption(QT_PREPEND_NAMESPACE(QFileDialogOptions::ReadOnly)))];
[mOpenPanel setAllowsMultipleSelection:(fileMode == QT_PREPEND_NAMESPACE(QFileDialogOptions::ExistingFiles))];
[mOpenPanel setResolvesAliases:!(mOptions->testOption(QT_PREPEND_NAMESPACE(QFileDialogOptions::DontResolveSymlinks)))];
+ [mOpenPanel setTitle:QCFString::toNSString(mOptions->windowTitle())];
+ [mSavePanel setTitle:QCFString::toNSString(mOptions->windowTitle())];
+ [mPopUpButton setHidden:chooseDirsOnly]; // TODO hide the whole sunken pane instead?
QStringList ext = [self acceptableExtensionsForSave];
const QString defaultSuffix = mOptions->defaultSuffix();
@@ -577,13 +578,16 @@ extern void qt_mac_to_pascal_string(QString s, Str255 str, TextEncoding encoding
void QCocoaFileDialogHelper::setDirectory(const QString &directory)
{
QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *delegate = static_cast<QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *>(mDelegate);
- [delegate->mSavePanel setDirectoryURL:[NSURL fileURLWithPath:QCFString::toNSString(directory)]];
+ if (delegate)
+ [delegate->mSavePanel setDirectoryURL:[NSURL fileURLWithPath:QCFString::toNSString(directory)]];
}
QString QCocoaFileDialogHelper::directory() const
{
QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *delegate = static_cast<QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *>(mDelegate);
- return QCFString::toQString([delegate->mSavePanel directory]);
+ if (delegate)
+ return QCFString::toQString([[delegate->mSavePanel directoryURL] path]);
+ return QString();
}
void QCocoaFileDialogHelper::selectFile(const QString &filename)
@@ -600,12 +604,16 @@ void QCocoaFileDialogHelper::selectFile(const QString &filename)
QStringList QCocoaFileDialogHelper::selectedFiles() const
{
QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *delegate = static_cast<QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *>(mDelegate);
- return [delegate selectedFiles];
+ if (delegate)
+ return [delegate selectedFiles];
+ return QStringList();
}
void QCocoaFileDialogHelper::setFilter()
{
QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *delegate = static_cast<QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *>(mDelegate);
+ if (!delegate)
+ return;
const SharedPointerFileDialogOptions &opts = options();
[delegate->mSavePanel setTitle:QCFString::toNSString(opts->windowTitle())];
if (opts->isLabelExplicitlySet(QFileDialogOptions::Accept))
@@ -618,9 +626,13 @@ void QCocoaFileDialogHelper::setFilter()
void QCocoaFileDialogHelper::selectNameFilter(const QString &filter)
{
+ if (!options())
+ return;
const int index = options()->nameFilters().indexOf(filter);
if (index != -1) {
QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *delegate = static_cast<QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *>(mDelegate);
+ if (!delegate)
+ return;
[delegate->mPopUpButton selectItemAtIndex:index];
[delegate filterChanged:nil];
}
@@ -629,7 +641,11 @@ void QCocoaFileDialogHelper::selectNameFilter(const QString &filter)
QString QCocoaFileDialogHelper::selectedNameFilter() const
{
QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *delegate = static_cast<QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *>(mDelegate);
+ if (!delegate)
+ return QString();
int index = [delegate->mPopUpButton indexOfSelectedItem];
+ if (index >= options()->nameFilters().count())
+ return QString();
return index != -1 ? options()->nameFilters().at(index) : QString();
}
@@ -675,6 +691,8 @@ bool QCocoaFileDialogHelper::showCocoaFilePanel(Qt::WindowModality windowModalit
{
createNSOpenSavePanelDelegate();
QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *delegate = static_cast<QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *>(mDelegate);
+ if (!delegate)
+ return false;
if (windowModality == Qt::NonModal)
[delegate showModelessPanel];
else if (windowModality == Qt::WindowModal && parent)
diff --git a/src/plugins/platforms/cocoa/qcocoaglcontext.mm b/src/plugins/platforms/cocoa/qcocoaglcontext.mm
index d0f5a58e22..d4673baaef 100644
--- a/src/plugins/platforms/cocoa/qcocoaglcontext.mm
+++ b/src/plugins/platforms/cocoa/qcocoaglcontext.mm
@@ -49,11 +49,19 @@
#import <Cocoa/Cocoa.h>
QCocoaGLContext::QCocoaGLContext(const QSurfaceFormat &format, QPlatformOpenGLContext *share)
- : m_format(format)
+ : m_context(nil),
+ m_shareContext(nil),
+ m_format(format)
{
+ // we only support OpenGL contexts under Cocoa
+ if (m_format.renderableType() == QSurfaceFormat::DefaultRenderableType)
+ m_format.setRenderableType(QSurfaceFormat::OpenGL);
+ if (m_format.renderableType() != QSurfaceFormat::OpenGL)
+ return;
+
QCocoaAutoReleasePool pool; // For the SG Canvas render thread
- NSOpenGLPixelFormat *pixelFormat = static_cast <NSOpenGLPixelFormat *>(qcgl_createNSOpenGLPixelFormat(format));
+ NSOpenGLPixelFormat *pixelFormat = static_cast <NSOpenGLPixelFormat *>(qcgl_createNSOpenGLPixelFormat(m_format));
m_shareContext = share ? static_cast<QCocoaGLContext *>(share)->nsOpenGLContext() : nil;
m_context = [NSOpenGLContext alloc];
@@ -70,6 +78,10 @@ QCocoaGLContext::QCocoaGLContext(const QSurfaceFormat &format, QPlatformOpenGLCo
const GLint interval = 1;
[m_context setValues:&interval forParameter:NSOpenGLCPSwapInterval];
+ if (format.alphaBufferSize() > 0) {
+ int zeroOpacity = 0;
+ [m_context setValues:&zeroOpacity forParameter:NSOpenGLCPSurfaceOpacity];
+ }
}
QCocoaGLContext::~QCocoaGLContext()
diff --git a/src/plugins/platforms/cocoa/qcocoahelpers.h b/src/plugins/platforms/cocoa/qcocoahelpers.h
index 831ab579f5..c801d9d926 100644
--- a/src/plugins/platforms/cocoa/qcocoahelpers.h
+++ b/src/plugins/platforms/cocoa/qcocoahelpers.h
@@ -84,8 +84,6 @@ HIMutableShapeRef qt_mac_QRegionToHIMutableShape(const QRegion &region);
OSStatus qt_mac_drawCGImage(CGContextRef inContext, const CGRect *inBounds, CGImageRef inImage);
-CGFloat qt_mac_get_scalefactor();
-
QChar qt_mac_qtKey2CocoaKey(Qt::Key key);
Qt::Key qt_mac_cocoaKey2QtKey(QChar keyCode);
diff --git a/src/plugins/platforms/cocoa/qcocoahelpers.mm b/src/plugins/platforms/cocoa/qcocoahelpers.mm
index 20702c6837..066b2d9cc1 100644
--- a/src/plugins/platforms/cocoa/qcocoahelpers.mm
+++ b/src/plugins/platforms/cocoa/qcocoahelpers.mm
@@ -47,6 +47,7 @@
#include <QtGui>
#include <qpa/qplatformscreen.h>
#include <private/qguiapplication_p.h>
+#include <private/qwindow_p.h>
#ifndef QT_NO_WIDGETS
#include <QtWidgets/QWidget>
@@ -261,7 +262,7 @@ static const KeyPair entries[NumEntries] = {
{ NSF6FunctionKey, Qt::Key_F6 },
{ NSF7FunctionKey, Qt::Key_F7 },
{ NSF8FunctionKey, Qt::Key_F8 },
- { NSF9FunctionKey, Qt::Key_F8 },
+ { NSF9FunctionKey, Qt::Key_F9 },
{ NSF10FunctionKey, Qt::Key_F10 },
{ NSF11FunctionKey, Qt::Key_F11 },
{ NSF12FunctionKey, Qt::Key_F12 },
@@ -474,11 +475,9 @@ CGColorSpaceRef qt_mac_genericColorSpace()
{
#if 0
if (!m_genericColorSpace) {
-#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4
if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_4) {
m_genericColorSpace = CGColorSpaceCreateWithName(kCGColorSpaceGenericRGB);
} else
-#endif
{
m_genericColorSpace = CGColorSpaceCreateDeviceRGB();
}
@@ -586,10 +585,28 @@ QString qt_mac_applicationName()
return appName;
}
+/*
+ Mac window coordinates are in the first quadrant: 0, 0 is at the lower-left
+ corner of the primary screen. This function converts the given rect to an
+ NSRect for the window geometry, flipping from 4th quadrant to 1st quadrant
+ and simultaneously ensuring that as much of the window as possible will be
+ onscreen. If the rect is too tall for the screen, the OS will reduce the
+ window's height anyway; but by moving the window upwards we can have more
+ of it onscreen. But the application can still control the y coordinate
+ in case it really wants the window to be positioned partially offscreen.
+*/
NSRect qt_mac_flipRect(const QRect &rect, QWindow *window)
{
QPlatformScreen *onScreen = QPlatformScreen::platformScreenForWindow(window);
- int flippedY = onScreen->geometry().height() - rect.y() - rect.height();
+ int flippedY = onScreen->geometry().height() - (rect.y() + rect.height());
+
+ // In case of automatic positioning, try to put as much of the window onscreen as possible.
+ if (window->isTopLevel() && qt_window_private(const_cast<QWindow*>(window))->positionAutomatic && flippedY < 0)
+ flippedY = onScreen->geometry().height() - onScreen->availableGeometry().height() - onScreen->availableGeometry().y();
+#ifdef QT_COCOA_ENABLE_WINDOW_DEBUG
+ qDebug() << Q_FUNC_INFO << rect << "flippedY" << flippedY <<
+ "screen" << onScreen->geometry() << "available" << onScreen->availableGeometry();
+#endif
return NSMakeRect(rect.x(), flippedY, rect.width(), rect.height());
}
@@ -615,11 +632,6 @@ InvalidContext:
return err;
}
-CGFloat qt_mac_get_scalefactor()
-{
- return [[NSScreen mainScreen] userSpaceScaleFactor];
-}
-
Qt::MouseButton cocoaButton2QtButton(NSInteger buttonNum)
{
if (buttonNum == 0)
@@ -752,6 +764,9 @@ CGContextRef qt_mac_cg_context(QPaintDevice *pdev)
return ret;
}
+// qpaintengine_mac.mm
+extern void qt_mac_cgimage_data_free(void *, const void *memoryToFree, size_t);
+
CGImageRef qt_mac_toCGImage(const QImage &qImage, bool isMask, uchar **dataCopy)
{
int width = qImage.width();
@@ -765,8 +780,7 @@ CGImageRef qt_mac_toCGImage(const QImage &qImage, bool isMask, uchar **dataCopy)
const uchar *imageData = qImage.bits();
if (dataCopy) {
- delete[] *dataCopy;
- *dataCopy = new uchar[qImage.byteCount()];
+ *dataCopy = static_cast<uchar *>(malloc(qImage.byteCount()));
memcpy(*dataCopy, imageData, qImage.byteCount());
}
int bitDepth = qImage.depth();
@@ -777,7 +791,7 @@ CGImageRef qt_mac_toCGImage(const QImage &qImage, bool isMask, uchar **dataCopy)
NULL,
dataCopy ? *dataCopy : imageData,
qImage.byteCount(),
- NULL);
+ dataCopy ? qt_mac_cgimage_data_free : NULL);
CGImageRef cgImage = 0;
if (isMask) {
diff --git a/src/plugins/platforms/cocoa/qcocoaintegration.h b/src/plugins/platforms/cocoa/qcocoaintegration.h
index d667ac4a86..6e690dd51e 100644
--- a/src/plugins/platforms/cocoa/qcocoaintegration.h
+++ b/src/plugins/platforms/cocoa/qcocoaintegration.h
@@ -132,7 +132,7 @@ private:
QAbstractEventDispatcher *mEventDispatcher;
QScopedPointer<QPlatformInputContext> mInputContext;
-#ifndef QT_NO_COCOA_ACCESSIBILITY
+#ifndef QT_NO_ACCESSIBILITY
QScopedPointer<QPlatformAccessibility> mAccessibility;
#endif
QScopedPointer<QPlatformTheme> mPlatformTheme;
diff --git a/src/plugins/platforms/cocoa/qcocoaintegration.mm b/src/plugins/platforms/cocoa/qcocoaintegration.mm
index 7fcdab4d97..e2d867e623 100644
--- a/src/plugins/platforms/cocoa/qcocoaintegration.mm
+++ b/src/plugins/platforms/cocoa/qcocoaintegration.mm
@@ -90,11 +90,28 @@ void QCocoaScreen::updateGeometry()
{
NSScreen *nsScreen = osScreen();
NSRect frameRect = [nsScreen frame];
- m_geometry = QRect(frameRect.origin.x, frameRect.origin.y, frameRect.size.width, frameRect.size.height);
- NSRect visibleRect = [nsScreen visibleFrame];
- m_availableGeometry = QRect(visibleRect.origin.x,
- frameRect.size.height - (visibleRect.origin.y + visibleRect.size.height), // invert y
- visibleRect.size.width, visibleRect.size.height);
+
+ if (m_screenIndex == 0) {
+ m_geometry = QRect(frameRect.origin.x, frameRect.origin.y, frameRect.size.width, frameRect.size.height);
+ // This is the primary screen, the one that contains the menubar. Its origin should be
+ // (0, 0), and it's the only one whose available geometry differs from its full geometry.
+ NSRect visibleRect = [nsScreen visibleFrame];
+ m_availableGeometry = QRect(visibleRect.origin.x,
+ frameRect.size.height - (visibleRect.origin.y + visibleRect.size.height), // invert y
+ visibleRect.size.width, visibleRect.size.height);
+ } else {
+ // NSScreen origin is at the bottom-left corner, QScreen is at the top-left corner.
+ // When we get the NSScreen frame rect, we need to re-align its origin y coordinate
+ // w.r.t. the primary screen, whose origin is (0, 0).
+ NSRect r = [[[NSScreen screens] objectAtIndex:0] frame];
+ QRect referenceScreenGeometry = QRect(r.origin.x, r.origin.y, r.size.width, r.size.height);
+ m_geometry = QRect(frameRect.origin.x,
+ referenceScreenGeometry.height() - (frameRect.origin.y + frameRect.size.height),
+ frameRect.size.width, frameRect.size.height);
+
+ // Not primary screen. See above.
+ m_availableGeometry = m_geometry;
+ }
m_format = QImage::Format_RGB32;
m_depth = NSBitsPerPixelFromDepth([nsScreen depth]);
@@ -105,7 +122,9 @@ void QCocoaScreen::updateGeometry()
m_physicalSize = QSizeF(size.width, size.height);
m_logicalDpi.first = 72;
m_logicalDpi.second = 72;
- m_refreshRate = CGDisplayModeGetRefreshRate(CGDisplayCopyDisplayMode(dpy));
+ float refresh = CGDisplayModeGetRefreshRate(CGDisplayCopyDisplayMode(dpy));
+ if (refresh > 0)
+ m_refreshRate = refresh;
// Get m_name (brand/model of the monitor)
NSDictionary *deviceInfo = (NSDictionary *)IODisplayCreateInfoDictionary(CGDisplayIOServicePort(dpy), kIODisplayOnlyPreferredName);
@@ -170,13 +189,13 @@ QPixmap QCocoaScreen::grabWindow(WId window, int x, int y, int width, int height
windowSize.setHeight(windowRect.height());
}
- QPixmap windowPixmap(windowSize);
+ QPixmap windowPixmap(windowSize * devicePixelRatio());
windowPixmap.fill(Qt::transparent);
for (uint i = 0; i < displayCount; ++i) {
const CGRect bounds = CGDisplayBounds(displays[i]);
- int w = (width < 0 ? bounds.size.width : width);
- int h = (height < 0 ? bounds.size.height : height);
+ int w = (width < 0 ? bounds.size.width : width) * devicePixelRatio();
+ int h = (height < 0 ? bounds.size.height : height) * devicePixelRatio();
QRect displayRect = QRect(x, y, w, h);
QCFType<CGImageRef> image = CGDisplayCreateImageForRect(displays[i],
CGRectMake(displayRect.x(), displayRect.y(), displayRect.width(), displayRect.height()));
@@ -197,7 +216,7 @@ QCocoaIntegration::QCocoaIntegration()
: mFontDb(new QCoreTextFontDatabase())
, mEventDispatcher(new QCocoaEventDispatcher())
, mInputContext(new QCocoaInputContext)
-#ifndef QT_NO_COCOA_ACCESSIBILITY
+#ifndef QT_NO_ACCESSIBILITY
, mAccessibility(new QCococaAccessibility)
#endif
, mCocoaClipboard(new QCocoaClipboard)
@@ -376,7 +395,7 @@ QPlatformInputContext *QCocoaIntegration::inputContext() const
QPlatformAccessibility *QCocoaIntegration::accessibility() const
{
-#ifndef QT_NO_COCOA_ACCESSIBILITY
+#ifndef QT_NO_ACCESSIBILITY
return mAccessibility.data();
#else
return 0;
diff --git a/src/plugins/platforms/cocoa/qcocoaintrospection.mm b/src/plugins/platforms/cocoa/qcocoaintrospection.mm
index ffb6ae4294..806effc929 100644
--- a/src/plugins/platforms/cocoa/qcocoaintrospection.mm
+++ b/src/plugins/platforms/cocoa/qcocoaintrospection.mm
@@ -83,7 +83,6 @@ void qt_cocoa_change_implementation(Class baseClass, SEL originalSel, Class prox
if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_5)
#endif
{
-#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5
// The following code replaces the _implementation_ for the selector we want to hack
// (originalSel) with the implementation found in proxyClass. Then it creates
// a new 'backup' method inside baseClass containing the old, original,
@@ -104,7 +103,6 @@ void qt_cocoa_change_implementation(Class baseClass, SEL originalSel, Class prox
Method backupMethod = class_getInstanceMethod(proxyClass, backupSel);
class_addMethod(baseClass, backupSel, originalImp, method_getTypeEncoding(backupMethod));
}
-#endif
}
}
@@ -114,11 +112,9 @@ void qt_cocoa_change_back_implementation(Class baseClass, SEL originalSel, SEL b
if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_5)
#endif
{
-#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5
Method originalMethod = class_getInstanceMethod(baseClass, originalSel);
Method backupMethodInBaseClass = class_getInstanceMethod(baseClass, backupSel);
method_setImplementation(originalMethod, method_getImplementation(backupMethodInBaseClass));
-#endif
}
}
diff --git a/src/plugins/platforms/cocoa/qcocoakeymapper.h b/src/plugins/platforms/cocoa/qcocoakeymapper.h
index 324b753131..0629de9317 100644
--- a/src/plugins/platforms/cocoa/qcocoakeymapper.h
+++ b/src/plugins/platforms/cocoa/qcocoakeymapper.h
@@ -99,7 +99,6 @@ private:
const UCKeyboardLayout *unicode;
void *other;
} keyboard_layout_format;
- KeyboardLayoutRef currentKeyboardLayout;
KeyboardLayoutKind keyboard_kind;
UInt32 keyboard_dead;
KeyboardLayoutItem *keyLayout[256];
diff --git a/src/plugins/platforms/cocoa/qcocoamenu.h b/src/plugins/platforms/cocoa/qcocoamenu.h
index 09b62a9bcd..439b7f1a75 100644
--- a/src/plugins/platforms/cocoa/qcocoamenu.h
+++ b/src/plugins/platforms/cocoa/qcocoamenu.h
@@ -51,8 +51,6 @@
@class NSMenu;
@class NSObject;
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QCocoaMenu : public QPlatformMenu
@@ -71,11 +69,17 @@ public:
void syncMenuItem(QPlatformMenuItem *menuItem);
void setEnabled(bool enabled);
void setVisible(bool visible);
+ void showPopup(const QWindow *parentWindow, QPoint pos, const QPlatformMenuItem *item);
+
void syncSeparatorsCollapsible(bool enable);
void syncModalState(bool modal);
- virtual void setText(const QString &text);
+ virtual void setIcon(const QIcon &icon) { Q_UNUSED(icon) }
+
+ void setText(const QString &text);
+ void setMinimumWidth(int width);
+ void setFont(const QFont &font);
void setParentItem(QCocoaMenuItem* item);
@@ -102,6 +106,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/plugins/platforms/cocoa/qcocoamenu.mm b/src/plugins/platforms/cocoa/qcocoamenu.mm
index 676f0683fa..0fe4c48510 100644
--- a/src/plugins/platforms/cocoa/qcocoamenu.mm
+++ b/src/plugins/platforms/cocoa/qcocoamenu.mm
@@ -47,6 +47,8 @@
#include <QtCore/QtDebug>
#include "qcocoaapplication.h"
#include "qcocoamenuloader.h"
+#include "qcocoawindow.h"
+#import "qnsview.h"
static inline QT_MANGLE_NAMESPACE(QCocoaMenuLoader) *getMenuLoader()
{
@@ -133,6 +135,20 @@ void QCocoaMenu::setText(const QString &text)
[m_nativeItem setTitle:QCFString::toNSString(stripped)];
}
+void QCocoaMenu::setMinimumWidth(int width)
+{
+ m_nativeMenu.minimumWidth = width;
+}
+
+void QCocoaMenu::setFont(const QFont &font)
+{
+ if (font.resolve()) {
+ NSFont *customMenuFont = [NSFont fontWithName:QCFString::toNSString(font.family())
+ size:font.pointSize()];
+ m_nativeMenu.font = customMenuFont;
+ }
+}
+
void QCocoaMenu::insertMenuItem(QPlatformMenuItem *menuItem, QPlatformMenuItem *before)
{
QCocoaAutoReleasePool pool;
@@ -290,9 +306,26 @@ void QCocoaMenu::setVisible(bool visible)
[m_nativeItem setSubmenu:(visible ? m_nativeMenu : nil)];
}
+void QCocoaMenu::showPopup(const QWindow *parentWindow, QPoint pos, const QPlatformMenuItem *item)
+{
+ QCocoaWindow *cocoaWindow = parentWindow ? static_cast<QCocoaWindow *>(parentWindow->handle()) : 0;
+ NSView *view = cocoaWindow ? cocoaWindow->contentView() : nil;
+ NSMenuItem *nsItem = item ? ((QCocoaMenuItem *)item)->nsItem() : nil;
+ NSPoint nsPos = NSMakePoint(pos.x(), pos.y());
+ [m_nativeMenu popUpMenuPositioningItem:nsItem atLocation:nsPos inView:view];
+
+ // The call above blocks, and also swallows any mouse release event,
+ // so we need to clear any mouse button that triggered the menu popup.
+ if ([view isKindOfClass:[QNSView class]])
+ [(QNSView *)view resetMouseButtons];
+}
+
QPlatformMenuItem *QCocoaMenu::menuItemAt(int position) const
{
- return m_menuItems.at(position);
+ if (0 <= position && position < m_menuItems.count())
+ return m_menuItems.at(position);
+
+ return 0;
}
QPlatformMenuItem *QCocoaMenu::menuItemForTag(quintptr tag) const
diff --git a/src/plugins/platforms/cocoa/qcocoamenubar.mm b/src/plugins/platforms/cocoa/qcocoamenubar.mm
index bae52c91b8..c0c8caed05 100644
--- a/src/plugins/platforms/cocoa/qcocoamenubar.mm
+++ b/src/plugins/platforms/cocoa/qcocoamenubar.mm
@@ -77,8 +77,10 @@ QCocoaMenuBar::~QCocoaMenuBar()
[m_nativeMenu release];
static_menubars.removeOne(this);
- if (m_window)
+ if (m_window && m_window->menubar() == this) {
m_window->setMenubar(0);
+ updateMenuBarImmediately();
+ }
}
void QCocoaMenuBar::insertMenu(QPlatformMenu *platformMenu, QPlatformMenu *before)
diff --git a/src/plugins/platforms/cocoa/qcocoamenuitem.h b/src/plugins/platforms/cocoa/qcocoamenuitem.h
index fe5193a50c..0e6d17343d 100644
--- a/src/plugins/platforms/cocoa/qcocoamenuitem.h
+++ b/src/plugins/platforms/cocoa/qcocoamenuitem.h
@@ -51,8 +51,6 @@
@class NSMenuItem;
@class NSMenu;
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QCocoaMenu;
@@ -76,6 +74,7 @@ public:
void setFont(const QFont &font);
void setRole(MenuRole role);
void setShortcut(const QKeySequence& shortcut);
+ void setCheckable(bool checkable) { Q_UNUSED(checkable) }
void setChecked(bool isChecked);
void setEnabled(bool isEnabled);
@@ -110,8 +109,6 @@ private:
quintptr m_tag;
};
-QT_END_HEADER
-
QT_END_NAMESPACE
#endif
diff --git a/src/plugins/platforms/cocoa/qcocoamenuitem.mm b/src/plugins/platforms/cocoa/qcocoamenuitem.mm
index d78ff73bb6..dd99a6f3bc 100644
--- a/src/plugins/platforms/cocoa/qcocoamenuitem.mm
+++ b/src/plugins/platforms/cocoa/qcocoamenuitem.mm
@@ -104,9 +104,9 @@ QCocoaMenuItem::~QCocoaMenuItem()
{
if (m_merged) {
[m_native setHidden:YES];
+ } else {
+ [m_native release];
}
-
- [m_native release];
}
void QCocoaMenuItem::setText(const QString &text)
@@ -195,7 +195,7 @@ NSMenuItem *QCocoaMenuItem::sync()
QT_MANGLE_NAMESPACE(QCocoaMenuLoader) *loader = getMenuLoader();
switch (m_role) {
case ApplicationSpecificRole:
- mergeItem = [loader appSpecificMenuItem];
+ mergeItem = [loader appSpecificMenuItem:reinterpret_cast<NSInteger>(this)];
break;
case AboutRole:
mergeItem = [loader aboutMenuItem];
@@ -315,9 +315,12 @@ NSMenuItem *QCocoaMenuItem::sync()
return m_native;
}
+QT_BEGIN_NAMESPACE
+extern QString qt_mac_applicationmenu_string(int type);
+QT_END_NAMESPACE
+
QString QCocoaMenuItem::mergeText()
{
- extern QString qt_mac_applicationmenu_string(int type);
QT_MANGLE_NAMESPACE(QCocoaMenuLoader) *loader = getMenuLoader();
if (m_native == [loader aboutMenuItem]) {
return qt_mac_applicationmenu_string(6).arg(qt_mac_applicationName());
diff --git a/src/plugins/platforms/cocoa/qcocoamenuloader.h b/src/plugins/platforms/cocoa/qcocoamenuloader.h
index f95f684e8c..a45ec0fa89 100644
--- a/src/plugins/platforms/cocoa/qcocoamenuloader.h
+++ b/src/plugins/platforms/cocoa/qcocoamenuloader.h
@@ -79,7 +79,7 @@
- (NSMenuItem *)aboutMenuItem;
- (NSMenuItem *)aboutQtMenuItem;
- (NSMenuItem *)hideMenuItem;
-- (NSMenuItem *)appSpecificMenuItem;
+- (NSMenuItem *)appSpecificMenuItem:(NSInteger)tag;
- (IBAction)terminate:(id)sender;
- (IBAction)orderFrontStandardAboutPanel:(id)sender;
- (IBAction)hideOtherApplications:(id)sender;
diff --git a/src/plugins/platforms/cocoa/qcocoamenuloader.mm b/src/plugins/platforms/cocoa/qcocoamenuloader.mm
index 2a9dcec64b..726fe5c6d2 100644
--- a/src/plugins/platforms/cocoa/qcocoamenuloader.mm
+++ b/src/plugins/platforms/cocoa/qcocoamenuloader.mm
@@ -246,11 +246,17 @@ QT_END_NAMESPACE
return [[hideItem retain] autorelease];
}
-- (NSMenuItem *)appSpecificMenuItem
+- (NSMenuItem *)appSpecificMenuItem:(NSInteger)tag
{
+ NSMenuItem *item = [appMenu itemWithTag:tag];
+
+ // No reason to create the item if it already exists. See QTBUG-27202.
+ if (item)
+ return [[item retain] autorelease];
+
// Create an App-Specific menu item, insert it into the menu and return
// it as an autorelease item.
- NSMenuItem *item = [[NSMenuItem alloc] init];
+ item = [[NSMenuItem alloc] init];
NSInteger location;
if (lastAppSpecificItem == nil) {
diff --git a/src/plugins/platforms/cocoa/qcocoanativeinterface.h b/src/plugins/platforms/cocoa/qcocoanativeinterface.h
index 9506f86238..ca84312059 100644
--- a/src/plugins/platforms/cocoa/qcocoanativeinterface.h
+++ b/src/plugins/platforms/cocoa/qcocoanativeinterface.h
@@ -52,6 +52,7 @@ class QWidget;
class QPlatformPrinterSupport;
class QPrintEngine;
class QPlatformMenu;
+class QPlatformMenuBar;
class QCocoaNativeInterface : public QPlatformNativeInterface
{
@@ -99,9 +100,27 @@ private:
// Dock menu support
static void setDockMenu(QPlatformMenu *platformMenu);
+ // Function to return NSMenu * from QPlatformMenu
+ static void *qMenuToNSMenu(QPlatformMenu *platformMenu);
+
+ // Function to return NSMenu * from QPlatformMenuBar
+ static void *qMenuBarToNSMenu(QPlatformMenuBar *platformMenuBar);
+
// QImage <-> CGImage conversion functions
static CGImageRef qImageToCGImage(const QImage &image);
static QImage cgImageToQImage(CGImageRef image);
+
+ // Embedding NSViews as child QWindows
+ static void setWindowContentView(QPlatformWindow *window, void *nsViewContentView);
+
+ // Register if a window should deliver touch events. Enabling
+ // touch events has implications for delivery of other events,
+ // for example by causing scrolling event lag.
+ //
+ // The registration is ref-counted: multiple widgets can enable
+ // touch events, which then will be delivered until the widget
+ // deregisters.
+ static void registerTouchWindow(QWindow *window, bool enable);
};
#endif // QCOCOANATIVEINTERFACE_H
diff --git a/src/plugins/platforms/cocoa/qcocoanativeinterface.mm b/src/plugins/platforms/cocoa/qcocoanativeinterface.mm
index bd3a909137..f0f1f56d90 100644
--- a/src/plugins/platforms/cocoa/qcocoanativeinterface.mm
+++ b/src/plugins/platforms/cocoa/qcocoanativeinterface.mm
@@ -46,6 +46,7 @@
#include "qcocoamenubar.h"
#include "qmacmime.h"
#include "qcocoahelpers.h"
+#include "qcocoaapplication.h"
#include <qbytearray.h>
#include <qwindow.h>
@@ -109,10 +110,18 @@ QPlatformNativeInterface::NativeResourceForIntegrationFunction QCocoaNativeInter
return NativeResourceForIntegrationFunction(QCocoaNativeInterface::registerDraggedTypes);
if (resource.toLower() == "setdockmenu")
return NativeResourceForIntegrationFunction(QCocoaNativeInterface::setDockMenu);
+ if (resource.toLower() == "qmenutonsmenu")
+ return NativeResourceForIntegrationFunction(QCocoaNativeInterface::qMenuToNSMenu);
+ if (resource.toLower() == "qmenubartonsmenu")
+ return NativeResourceForIntegrationFunction(QCocoaNativeInterface::qMenuBarToNSMenu);
if (resource.toLower() == "qimagetocgimage")
return NativeResourceForIntegrationFunction(QCocoaNativeInterface::qImageToCGImage);
if (resource.toLower() == "cgimagetoqimage")
return NativeResourceForIntegrationFunction(QCocoaNativeInterface::cgImageToQImage);
+ if (resource.toLower() == "setwindowcontentview")
+ return NativeResourceForIntegrationFunction(QCocoaNativeInterface::setWindowContentView);
+ if (resource.toLower() == "registertouchwindow")
+ return NativeResourceForIntegrationFunction(QCocoaNativeInterface::registerTouchWindow);
return 0;
}
@@ -184,8 +193,21 @@ void QCocoaNativeInterface::setDockMenu(QPlatformMenu *platformMenu)
{
QCocoaMenu *cocoaPlatformMenu = static_cast<QCocoaMenu *>(platformMenu);
NSMenu *menu = cocoaPlatformMenu->nsMenu();
- // setDockMenu seems to be undocumented, but this is what Qt 4 did.
- [NSApp setDockMenu: menu];
+ [NSApp QT_MANGLE_NAMESPACE(qt_setDockMenu): menu];
+}
+
+void *QCocoaNativeInterface::qMenuToNSMenu(QPlatformMenu *platformMenu)
+{
+ QCocoaMenu *cocoaPlatformMenu = static_cast<QCocoaMenu *>(platformMenu);
+ NSMenu *menu = cocoaPlatformMenu->nsMenu();
+ return reinterpret_cast<void *>(menu);
+}
+
+void *QCocoaNativeInterface::qMenuBarToNSMenu(QPlatformMenuBar *platformMenuBar)
+{
+ QCocoaMenuBar *cocoaPlatformMenuBar = static_cast<QCocoaMenuBar *>(platformMenuBar);
+ NSMenu *menu = cocoaPlatformMenuBar->nsMenu();
+ return reinterpret_cast<void *>(menu);
}
CGImageRef QCocoaNativeInterface::qImageToCGImage(const QImage &image)
@@ -198,5 +220,17 @@ QImage QCocoaNativeInterface::cgImageToQImage(CGImageRef image)
return qt_mac_toQImage(image);
}
+void QCocoaNativeInterface::setWindowContentView(QPlatformWindow *window, void *contentView)
+{
+ QCocoaWindow *cocoaPlatformWindow = static_cast<QCocoaWindow *>(window);
+ cocoaPlatformWindow->setContentView(reinterpret_cast<NSView *>(contentView));
+}
+
+void QCocoaNativeInterface::registerTouchWindow(QWindow *window, bool enable)
+{
+ QCocoaWindow *cocoaWindow = static_cast<QCocoaWindow *>(window->handle());
+ if (cocoaWindow)
+ cocoaWindow->registerTouch(enable);
+}
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/cocoa/qcocoaprintersupport.h b/src/plugins/platforms/cocoa/qcocoaprintersupport.h
index 040b687c4e..83cf1ffada 100644
--- a/src/plugins/platforms/cocoa/qcocoaprintersupport.h
+++ b/src/plugins/platforms/cocoa/qcocoaprintersupport.h
@@ -55,6 +55,7 @@ public:
QPrintEngine *createNativePrintEngine(QPrinter::PrinterMode printerMode) Q_DECL_OVERRIDE;
QPaintEngine *createPaintEngine(QPrintEngine *, QPrinter::PrinterMode printerMode) Q_DECL_OVERRIDE;
QList<QPrinter::PaperSize> supportedPaperSizes(const QPrinterInfo &) const Q_DECL_OVERRIDE;
+ QList<QPair<QString, QSizeF> > supportedSizesWithNames(const QPrinterInfo &) const Q_DECL_OVERRIDE;
QList<QPrinterInfo> availablePrinters() Q_DECL_OVERRIDE;
QPrinterInfo printerInfo(const QString &printerName) Q_DECL_OVERRIDE;
diff --git a/src/plugins/platforms/cocoa/qcocoaprintersupport.mm b/src/plugins/platforms/cocoa/qcocoaprintersupport.mm
index a48db02949..cfa23b7a30 100644
--- a/src/plugins/platforms/cocoa/qcocoaprintersupport.mm
+++ b/src/plugins/platforms/cocoa/qcocoaprintersupport.mm
@@ -138,3 +138,34 @@ QPrinterInfo QCocoaPrinterSupport::printerInfoFromPMPrinter(const PMPrinter &pri
return createPrinterInfo(name, description, location, makeAndModel, isDefault, 0);
}
+
+QList<QPair<QString, QSizeF> > QCocoaPrinterSupport::supportedSizesWithNames(const QPrinterInfo &printerInfo) const
+{
+ QList<QPair<QString, QSizeF> > returnValue;
+ if (printerInfo.isNull())
+ return returnValue;
+
+ PMPrinter printer = PMPrinterCreateFromPrinterID(QCFString::toCFStringRef(printerInfo.printerName()));
+ if (!printer)
+ return returnValue;
+
+ CFArrayRef array;
+ if (PMPrinterGetPaperList(printer, &array) != noErr) {
+ PMRelease(printer);
+ return returnValue;
+ }
+
+ int count = CFArrayGetCount(array);
+ for (int i = 0; i < count; ++i) {
+ PMPaper paper = static_cast<PMPaper>(const_cast<void *>(CFArrayGetValueAtIndex(array, i)));
+ double width, height;
+ if (PMPaperGetWidth(paper, &width) == noErr && PMPaperGetHeight(paper, &height) == noErr) {
+ static const double OnePointInMillimeters = 1.0 / 72.0 * 25.4;
+ QCFString paperName;
+ if (PMPaperCreateLocalizedName(paper, printer, &paperName) == noErr)
+ returnValue.append(qMakePair(QString(paperName), QSizeF(width * OnePointInMillimeters, height * OnePointInMillimeters)));
+ }
+ }
+ PMRelease(printer);
+ return returnValue;
+}
diff --git a/src/plugins/platforms/cocoa/qcocoasystemsettings.mm b/src/plugins/platforms/cocoa/qcocoasystemsettings.mm
index 6f8d0fa22a..e613dbbd1b 100644
--- a/src/plugins/platforms/cocoa/qcocoasystemsettings.mm
+++ b/src/plugins/platforms/cocoa/qcocoasystemsettings.mm
@@ -95,6 +95,7 @@ QColor qt_mac_colorForThemeTextColor(ThemeTextColor themeColor)
case kThemeTextColorPushButtonInactive:
case kThemeTextColorTabFrontInactive:
case kThemeTextColorBevelButtonInactive:
+ case kThemeTextColorMenuItemDisabled:
return QColor(127, 127, 127, 255);
case kThemeTextColorMenuItemSelected:
return Qt::white;
@@ -164,7 +165,7 @@ static QMacPaletteMap mac_widget_colors[] = {
QMacPaletteMap(QPlatformTheme::TabBarPalette, kThemeTextColorTabFrontActive, kThemeTextColorTabFrontInactive),
QMacPaletteMap(QPlatformTheme::LabelPalette, kThemeTextColorPlacardActive, kThemeTextColorPlacardInactive),
QMacPaletteMap(QPlatformTheme::GroupBoxPalette, kThemeTextColorPlacardActive, kThemeTextColorPlacardInactive),
- QMacPaletteMap(QPlatformTheme::MenuPalette, kThemeTextColorPopupLabelActive, kThemeTextColorPopupLabelInactive),
+ QMacPaletteMap(QPlatformTheme::MenuPalette, kThemeTextColorMenuItemActive, kThemeTextColorMenuItemDisabled),
//### TODO: The zeros below gives white-on-black text.
QMacPaletteMap(QPlatformTheme::TextEditPalette, 0, 0),
QMacPaletteMap(QPlatformTheme::TextLineEditPalette, 0, 0),
@@ -179,14 +180,14 @@ QHash<QPlatformTheme::Palette, QPalette*> qt_mac_createRolePalettes()
if (mac_widget_colors[i].active != 0) {
qc = qt_mac_colorForThemeTextColor(mac_widget_colors[i].active);
pal.setColor(QPalette::Active, QPalette::Text, qc);
+ pal.setColor(QPalette::Inactive, QPalette::Text, qc);
pal.setColor(QPalette::Active, QPalette::WindowText, qc);
+ pal.setColor(QPalette::Inactive, QPalette::WindowText, qc);
pal.setColor(QPalette::Active, QPalette::HighlightedText, qc);
+ pal.setColor(QPalette::Inactive, QPalette::HighlightedText, qc);
qc = qt_mac_colorForThemeTextColor(mac_widget_colors[i].inactive);
- pal.setColor(QPalette::Inactive, QPalette::Text, qc);
pal.setColor(QPalette::Disabled, QPalette::Text, qc);
- pal.setColor(QPalette::Inactive, QPalette::WindowText, qc);
pal.setColor(QPalette::Disabled, QPalette::WindowText, qc);
- pal.setColor(QPalette::Inactive, QPalette::HighlightedText, qc);
pal.setColor(QPalette::Disabled, QPalette::HighlightedText, qc);
}
if (mac_widget_colors[i].paletteRole == QPlatformTheme::MenuPalette) {
diff --git a/src/plugins/platforms/cocoa/qcocoasystemtrayicon.h b/src/plugins/platforms/cocoa/qcocoasystemtrayicon.h
index 89ab51cf05..61a6ba3e2f 100755
--- a/src/plugins/platforms/cocoa/qcocoasystemtrayicon.h
+++ b/src/plugins/platforms/cocoa/qcocoasystemtrayicon.h
@@ -43,6 +43,8 @@
#ifndef QCOCOASYSTEMTRAYICON_P_H
#define QCOCOASYSTEMTRAYICON_P_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_SYSTEMTRAYICON
#include "QtCore/qstring.h"
diff --git a/src/plugins/platforms/cocoa/qcocoasystemtrayicon.mm b/src/plugins/platforms/cocoa/qcocoasystemtrayicon.mm
index e092db8172..99f533b33a 100755
--- a/src/plugins/platforms/cocoa/qcocoasystemtrayicon.mm
+++ b/src/plugins/platforms/cocoa/qcocoasystemtrayicon.mm
@@ -93,7 +93,11 @@ QT_USE_NAMESPACE
@class QT_MANGLE_NAMESPACE(QNSMenu);
@class QT_MANGLE_NAMESPACE(QNSImageView);
-@interface QT_MANGLE_NAMESPACE(QNSStatusItem) : NSObject {
+@interface QT_MANGLE_NAMESPACE(QNSStatusItem) : NSObject
+#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_8
+ <NSUserNotificationCenterDelegate>
+#endif
+ {
@public
QCocoaSystemTrayIcon *systray;
NSStatusItem *item;
@@ -108,6 +112,11 @@ QT_USE_NAMESPACE
-(QRectF)geometry;
- (void)triggerSelector:(id)sender button:(Qt::MouseButton)mouseButton;
- (void)doubleClickSelector:(id)sender;
+
+#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_8
+- (BOOL)userNotificationCenter:(NSUserNotificationCenter *)center shouldPresentNotification:(NSUserNotification *)notification;
+- (void)userNotificationCenter:(NSUserNotificationCenter *)center didActivateNotification:(NSUserNotification *)notification;
+#endif
@end
@interface QT_MANGLE_NAMESPACE(QNSImageView) : NSImageView {
@@ -132,9 +141,19 @@ class QSystemTrayIconSys
public:
QSystemTrayIconSys(QCocoaSystemTrayIcon *sys) {
item = [[QT_MANGLE_NAMESPACE(QNSStatusItem) alloc] initWithSysTray:sys];
+#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_8
+ if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_8) {
+ [[NSUserNotificationCenter defaultUserNotificationCenter] setDelegate:item];
+ }
+#endif
}
~QSystemTrayIconSys() {
[[[item item] view] setHidden: YES];
+#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_8
+ if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_8) {
+ [[NSUserNotificationCenter defaultUserNotificationCenter] setDelegate:nil];
+ }
+#endif
[item release];
}
QT_MANGLE_NAMESPACE(QNSStatusItem) *item;
@@ -223,6 +242,18 @@ void QCocoaSystemTrayIcon::showMessage(const QString &title, const QString &mess
if (!m_sys)
return;
+#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_8
+ if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_8) {
+ NSUserNotification *notification = [[NSUserNotification alloc] init];
+ notification.title = [NSString stringWithUTF8String:title.toUtf8().data()];
+ notification.informativeText = [NSString stringWithUTF8String:message.toUtf8().data()];
+
+ [[NSUserNotificationCenter defaultUserNotificationCenter] deliverNotification:notification];
+
+ return;
+ }
+#endif
+
#ifdef QT_MAC_SYSTEMTRAY_USE_GROWL
// Make sure that we have Growl installed on the machine we are running on.
QCFType<CFURLRef> cfurl;
@@ -439,6 +470,20 @@ QT_END_NAMESPACE
emit systray->activated(QPlatformSystemTrayIcon::DoubleClick);
}
+#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_8
+- (BOOL)userNotificationCenter:(NSUserNotificationCenter *)center shouldPresentNotification:(NSUserNotification *)notification {
+ Q_UNUSED(center);
+ Q_UNUSED(notification);
+ return YES;
+}
+
+- (void)userNotificationCenter:(NSUserNotificationCenter *)center didActivateNotification:(NSUserNotification *)notification {
+ Q_UNUSED(center);
+ Q_UNUSED(notification);
+ emit systray->messageClicked();
+}
+#endif
+
@end
class QSystemTrayIconQMenu : public QPlatformMenu
diff --git a/src/plugins/platforms/cocoa/qcocoatheme.mm b/src/plugins/platforms/cocoa/qcocoatheme.mm
index beaa50da6d..f8eed0ebf1 100644
--- a/src/plugins/platforms/cocoa/qcocoatheme.mm
+++ b/src/plugins/platforms/cocoa/qcocoatheme.mm
@@ -74,6 +74,8 @@ QCocoaTheme::QCocoaTheme()
QCocoaTheme::~QCocoaTheme()
{
delete m_systemPalette;
+ qDeleteAll(m_palettes);
+ qDeleteAll(m_fonts);
}
bool QCocoaTheme::usePlatformNativeDialog(DialogType dialogType) const
diff --git a/src/plugins/platforms/cocoa/qcocoawindow.h b/src/plugins/platforms/cocoa/qcocoawindow.h
index 7140a68d49..e1de5f0add 100644
--- a/src/plugins/platforms/cocoa/qcocoawindow.h
+++ b/src/plugins/platforms/cocoa/qcocoawindow.h
@@ -109,6 +109,7 @@ public:
void raise();
void lower();
bool isExposed() const;
+ bool isOpaque() const;
void propagateSizeHints();
void setOpacity(qreal level);
void setMask(const QRegion &region);
@@ -116,10 +117,13 @@ public:
bool setMouseGrabEnabled(bool grab);
QMargins frameMargins() const;
+ void requestActivateWindow();
+
WId winId() const;
void setParent(const QPlatformWindow *window);
NSView *contentView() const;
+ void setContentView(NSView *contentView);
void windowWillMove();
void windowDidMove();
@@ -143,9 +147,12 @@ public:
void setMenubar(QCocoaMenuBar *mb);
QCocoaMenuBar *menubar() const;
+ void registerTouch(bool enable);
+
qreal devicePixelRatio() const;
void exposeWindow();
void obscureWindow();
+ QWindow *childWindowAt(QPoint windowPoint);
protected:
// NSWindow handling. The QCocoaWindow/QNSView can either be displayed
// in an existing NSWindow or in one created by Qt.
@@ -163,13 +170,17 @@ public: // for QNSView
friend class QCocoaBackingStore;
friend class QCocoaNativeInterface;
- QNSView *m_contentView;
+ NSView *m_contentView;
+ QNSView *m_qtView;
NSWindow *m_nsWindow;
+ bool m_contentViewIsEmbedded; // true if the m_contentView is embedded in a "foregin" NSView hiearchy
+
QNSWindowDelegate *m_nsWindowDelegate;
Qt::WindowFlags m_windowFlags;
Qt::WindowState m_synchedWindowState;
Qt::WindowModality m_windowModality;
QPointer<QWindow> m_activePopupWindow;
+ QPointer<QWindow> m_underMouseWindow;
bool m_inConstructor;
QCocoaGLContext *m_glContext;
@@ -178,6 +189,7 @@ public: // for QNSView
bool m_hasModalSession;
bool m_frameStrutEventsEnabled;
bool m_isExposed;
+ int m_registerTouchCount;
};
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/cocoa/qcocoawindow.mm b/src/plugins/platforms/cocoa/qcocoawindow.mm
index 7c665a35c5..4e567c6c63 100644
--- a/src/plugins/platforms/cocoa/qcocoawindow.mm
+++ b/src/plugins/platforms/cocoa/qcocoawindow.mm
@@ -58,6 +58,11 @@
#include <QDebug>
+enum {
+ defaultWindowWidth = 160,
+ defaultWindowHeight = 160
+};
+
static bool isMouseEvent(NSEvent *ev)
{
switch ([ev type]) {
@@ -186,6 +191,7 @@ static bool isMouseEvent(NSEvent *ev)
QCocoaWindow::QCocoaWindow(QWindow *tlw)
: QPlatformWindow(tlw)
, m_nsWindow(0)
+ , m_contentViewIsEmbedded(false)
, m_nsWindowDelegate(0)
, m_synchedWindowState(Qt::WindowActive)
, m_windowModality(Qt::NonModal)
@@ -195,17 +201,18 @@ QCocoaWindow::QCocoaWindow(QWindow *tlw)
, m_hasModalSession(false)
, m_frameStrutEventsEnabled(false)
, m_isExposed(false)
+ , m_registerTouchCount(0)
{
#ifdef QT_COCOA_ENABLE_WINDOW_DEBUG
qDebug() << "QCocoaWindow::QCocoaWindow" << this;
#endif
QCocoaAutoReleasePool pool;
- m_contentView = [[QNSView alloc] initWithQWindow:tlw platformWindow:this];
+ m_qtView = [[QNSView alloc] initWithQWindow:tlw platformWindow:this];
+ m_contentView = m_qtView;
setGeometry(tlw->geometry());
-
recreateWindow(parent());
-
+ tlw->setGeometry(geometry());
m_inConstructor = false;
}
@@ -238,6 +245,10 @@ void QCocoaWindow::setGeometry(const QRect &rect)
void QCocoaWindow::setCocoaGeometry(const QRect &rect)
{
QCocoaAutoReleasePool pool;
+
+ if (m_contentViewIsEmbedded)
+ return;
+
if (m_nsWindow) {
NSRect bounds = qt_mac_flipRect(rect, window());
[m_nsWindow setContentSize : bounds.size];
@@ -250,6 +261,9 @@ void QCocoaWindow::setCocoaGeometry(const QRect &rect)
void QCocoaWindow::setVisible(bool visible)
{
QCocoaAutoReleasePool pool;
+ QCocoaWindow *parentCocoaWindow = 0;
+ if (window()->transientParent())
+ parentCocoaWindow = static_cast<QCocoaWindow *>(window()->transientParent()->handle());
#ifdef QT_COCOA_ENABLE_WINDOW_DEBUG
qDebug() << "QCocoaWindow::setVisible" << window() << visible;
#endif
@@ -257,10 +271,7 @@ void QCocoaWindow::setVisible(bool visible)
// We need to recreate if the modality has changed as the style mask will need updating
if (m_windowModality != window()->modality())
recreateWindow(parent());
- QCocoaWindow *parentCocoaWindow = 0;
- if (window()->transientParent()) {
- parentCocoaWindow = static_cast<QCocoaWindow *>(window()->transientParent()->handle());
-
+ if (parentCocoaWindow) {
// The parent window might have moved while this window was hidden,
// update the window geometry if there is a parent.
setGeometry(window()->geometry());
@@ -270,6 +281,10 @@ void QCocoaWindow::setVisible(bool visible)
if (window()->type() == Qt::Popup) {
// qDebug() << "transientParent and popup" << window()->type() << Qt::Popup << (window()->type() & Qt::Popup);
parentCocoaWindow->m_activePopupWindow = window();
+ // QTBUG-30266: a window should not be resizable while a transient popup is open
+ // Since this isn't a native popup, the window manager doesn't close the popup when you click outside
+ [parentCocoaWindow->m_nsWindow setStyleMask:
+ (parentCocoaWindow->windowStyleMask(parentCocoaWindow->m_windowFlags) & ~NSResizableWindowMask)];
}
}
@@ -331,6 +346,9 @@ void QCocoaWindow::setVisible(bool visible)
} else {
[m_contentView setHidden:YES];
}
+ if (parentCocoaWindow && window()->type() == Qt::Popup)
+ // QTBUG-30266: a window should not be resizable while a transient popup is open
+ [parentCocoaWindow->m_nsWindow setStyleMask:parentCocoaWindow->windowStyleMask(parentCocoaWindow->m_windowFlags)];
}
}
@@ -367,7 +385,7 @@ NSUInteger QCocoaWindow::windowStyleMask(Qt::WindowFlags flags)
NSInteger styleMask = NSBorderlessWindowMask;
if ((type & Qt::Popup) == Qt::Popup) {
- if (!windowIsPopupType(type))
+ if (!windowIsPopupType(type) && !(flags & Qt::FramelessWindowHint))
styleMask = (NSUtilityWindowMask | NSResizableWindowMask | NSClosableWindowMask |
NSMiniaturizableWindowMask | NSTitledWindowMask);
} else {
@@ -376,8 +394,11 @@ NSUInteger QCocoaWindow::windowStyleMask(Qt::WindowFlags flags)
Qt::WindowMinMaxButtonsHint | Qt::WindowCloseButtonHint;
if (flags == Qt::Window) {
styleMask = (NSResizableWindowMask | NSClosableWindowMask | NSMiniaturizableWindowMask | NSTitledWindowMask);
- } else if ((flags & Qt::Dialog) && (window()->modality() != Qt::NonModal)) {
- styleMask = NSResizableWindowMask | NSTitledWindowMask;
+ } else if (flags & Qt::Dialog) {
+ if (window()->modality() == Qt::NonModal)
+ styleMask = NSResizableWindowMask | NSClosableWindowMask | NSTitledWindowMask;
+ else
+ styleMask = NSResizableWindowMask | NSTitledWindowMask;
} else if (!(flags & Qt::FramelessWindowHint)) {
if ((flags & Qt::Dialog) || (flags & Qt::WindowMaximizeButtonHint))
styleMask |= NSResizableWindowMask;
@@ -409,6 +430,8 @@ void QCocoaWindow::setWindowFlags(Qt::WindowFlags flags)
NSInteger level = this->windowLevel(flags);
[m_nsWindow setStyleMask:styleMask];
[m_nsWindow setLevel:level];
+ [m_nsWindow setIgnoresMouseEvents:((flags & Qt::ToolTip) == Qt::ToolTip) ? YES : NO];
+ // TODO deal with WindowTransparentForInput; setIgnoresMouseEvents is too extreme, you can't click the titlebar
setWindowShadow(flags);
}
@@ -485,6 +508,14 @@ bool QCocoaWindow::isExposed() const
return m_isExposed;
}
+bool QCocoaWindow::isOpaque() const
+{
+ bool translucent = (window()->format().alphaBufferSize() > 0
+ || window()->opacity() < 1
+ || (m_qtView && [m_qtView hasMask]));
+ return !translucent;
+}
+
void QCocoaWindow::propagateSizeHints()
{
QCocoaAutoReleasePool pool;
@@ -525,18 +556,19 @@ void QCocoaWindow::propagateSizeHints()
void QCocoaWindow::setOpacity(qreal level)
{
- if (m_nsWindow)
+ if (m_nsWindow) {
[m_nsWindow setAlphaValue:level];
+ [m_nsWindow setOpaque: isOpaque()];
+ }
}
void QCocoaWindow::setMask(const QRegion &region)
{
- if (m_nsWindow) {
- [m_nsWindow setOpaque:NO];
+ if (m_nsWindow)
[m_nsWindow setBackgroundColor:[NSColor clearColor]];
- }
- [m_contentView setMaskRegion:&region];
+ [m_qtView setMaskRegion:&region];
+ [m_nsWindow setOpaque: isOpaque()];
}
bool QCocoaWindow::setKeyboardGrabEnabled(bool grab)
@@ -580,6 +612,19 @@ NSView *QCocoaWindow::contentView() const
return m_contentView;
}
+void QCocoaWindow::setContentView(NSView *contentView)
+{
+ // Remove and release the previous content view
+ [m_contentView removeFromSuperview];
+ [m_contentView release];
+
+ // Insert and retain the new content view
+ [contentView retain];
+ m_contentView = contentView;
+ m_qtView = 0; // The new content view is not a QNSView.
+ recreateWindow(parent()); // Adds the content view to parent NSView
+}
+
void QCocoaWindow::windowWillMove()
{
// Close any open popups on window move
@@ -592,7 +637,7 @@ void QCocoaWindow::windowWillMove()
void QCocoaWindow::windowDidMove()
{
- [m_contentView updateGeometry];
+ [m_qtView updateGeometry];
}
void QCocoaWindow::windowDidResize()
@@ -600,7 +645,7 @@ void QCocoaWindow::windowDidResize()
if (!m_nsWindow)
return;
- [m_contentView updateGeometry];
+ [m_qtView updateGeometry];
}
void QCocoaWindow::windowWillClose()
@@ -641,7 +686,9 @@ void QCocoaWindow::recreateWindow(const QPlatformWindow *parentWindow)
m_nsWindowDelegate = 0;
}
- if (!parentWindow) {
+ if (window()->type() == Qt::SubWindow) {
+ // Subwindows don't have a NSWindow.
+ } else if (!parentWindow) {
// Create a new NSWindow if this is a top-level window.
m_nsWindow = createNSWindow();
setNSWindow(m_nsWindow);
@@ -665,11 +712,19 @@ void QCocoaWindow::recreateWindow(const QPlatformWindow *parentWindow)
setOpacity(opacity);
}
+void QCocoaWindow::requestActivateWindow()
+{
+ NSWindow *window = [m_contentView window];
+ [ window makeFirstResponder : m_contentView ];
+ [ window makeKeyWindow ];
+}
+
NSWindow * QCocoaWindow::createNSWindow()
{
QCocoaAutoReleasePool pool;
- NSRect frame = qt_mac_flipRect(window()->geometry(), window());
+ QRect rect = initialGeometry(window(), window()->geometry(), defaultWindowWidth, defaultWindowHeight);
+ NSRect frame = qt_mac_flipRect(rect, window());
Qt::WindowType type = window()->type();
Qt::WindowFlags flags = window()->flags();
@@ -726,6 +781,12 @@ NSWindow * QCocoaWindow::createNSWindow()
NSInteger level = windowLevel(flags);
[createdWindow setLevel:level];
+
+ if (window()->format().alphaBufferSize() > 0) {
+ [createdWindow setBackgroundColor:[NSColor clearColor]];
+ [createdWindow setOpaque:NO];
+ }
+
m_windowModality = window()->modality();
return createdWindow;
}
@@ -734,7 +795,6 @@ void QCocoaWindow::setNSWindow(NSWindow *window)
{
m_nsWindowDelegate = [[QNSWindowDelegate alloc] initWithQCocoaWindow:this];
[window setDelegate:m_nsWindowDelegate];
- [window setAcceptsMouseMovedEvents:YES];
// Prevent Cocoa from releasing the window on close. Qt
// handles the close event asynchronously and we want to
@@ -842,6 +902,15 @@ QCocoaMenuBar *QCocoaWindow::menubar() const
return m_menubar;
}
+void QCocoaWindow::registerTouch(bool enable)
+{
+ m_registerTouchCount += enable ? 1 : -1;
+ if (m_registerTouchCount == 1)
+ [m_contentView setAcceptsTouchEvents:YES];
+ else if (m_registerTouchCount == 0)
+ [m_contentView setAcceptsTouchEvents:NO];
+}
+
qreal QCocoaWindow::devicePixelRatio() const
{
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_7
@@ -870,6 +939,21 @@ void QCocoaWindow::obscureWindow()
}
}
+QWindow *QCocoaWindow::childWindowAt(QPoint windowPoint)
+{
+ QWindow *targetWindow = window();
+ foreach (QObject *child, targetWindow->children()) {
+ if (QWindow *childWindow = qobject_cast<QWindow *>(child)) {
+ if (childWindow->geometry().contains(windowPoint)) {
+ QCocoaWindow* platformWindow = static_cast<QCocoaWindow*>(childWindow->handle());
+ targetWindow = platformWindow->childWindowAt(windowPoint - childWindow->position());
+ }
+ }
+ }
+
+ return targetWindow;
+}
+
QMargins QCocoaWindow::frameMargins() const
{
NSRect frameW = [m_nsWindow frame];
diff --git a/src/plugins/platforms/cocoa/qmacdefines_mac.h b/src/plugins/platforms/cocoa/qmacdefines_mac.h
index 18c1ac84de..c03b398836 100644
--- a/src/plugins/platforms/cocoa/qmacdefines_mac.h
+++ b/src/plugins/platforms/cocoa/qmacdefines_mac.h
@@ -79,15 +79,11 @@
*/
/* This is just many defines. Therefore it doesn't need things like:
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
-
Yes, it is an informative comment ;-)
*/
diff --git a/src/plugins/platforms/cocoa/qmultitouch_mac.mm b/src/plugins/platforms/cocoa/qmultitouch_mac.mm
index 337d962c7f..fc0048f998 100644
--- a/src/plugins/platforms/cocoa/qmultitouch_mac.mm
+++ b/src/plugins/platforms/cocoa/qmultitouch_mac.mm
@@ -42,8 +42,6 @@
#include "qmultitouch_mac_p.h"
#include "qcocoahelpers.h"
-#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
-
QT_BEGIN_NAMESPACE
QHash<qint64, QCocoaTouch*> QCocoaTouch::_currentTouches;
@@ -214,6 +212,3 @@ QCocoaTouch::getCurrentTouchPointList(NSEvent *event, bool acceptSingleTouch)
}
QT_END_NAMESPACE
-
-#endif // MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
-
diff --git a/src/plugins/platforms/cocoa/qmultitouch_mac_p.h b/src/plugins/platforms/cocoa/qmultitouch_mac_p.h
index 1244b8223f..736eb3f878 100644
--- a/src/plugins/platforms/cocoa/qmultitouch_mac_p.h
+++ b/src/plugins/platforms/cocoa/qmultitouch_mac_p.h
@@ -61,8 +61,6 @@
#include <qhash.h>
#include <QtCore>
-#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
-
QT_BEGIN_NAMESPACE
class QCocoaTouch
@@ -92,7 +90,5 @@ class QCocoaTouch
QT_END_NAMESPACE
-#endif // MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6
-
#endif // QMULTITOUCH_MAC_P_H
diff --git a/src/plugins/platforms/cocoa/qnsview.h b/src/plugins/platforms/cocoa/qnsview.h
index 853b4b99e1..e7ea3d8f8d 100644
--- a/src/plugins/platforms/cocoa/qnsview.h
+++ b/src/plugins/platforms/cocoa/qnsview.h
@@ -86,6 +86,11 @@ QT_END_NAMESPACE
- (BOOL)isFlipped;
- (BOOL)acceptsFirstResponder;
+- (BOOL)becomeFirstResponder;
+- (BOOL)hasMask;
+- (BOOL)isOpaque;
+
+- (void)resetMouseButtons;
- (void)handleMouseEvent:(NSEvent *)theEvent;
- (void)mouseDown:(NSEvent *)theEvent;
diff --git a/src/plugins/platforms/cocoa/qnsview.mm b/src/plugins/platforms/cocoa/qnsview.mm
index fae68493f1..568cc4bebf 100644
--- a/src/plugins/platforms/cocoa/qnsview.mm
+++ b/src/plugins/platforms/cocoa/qnsview.mm
@@ -102,7 +102,6 @@ static QTouchDevice *touchDevice = 0;
{
CGImageRelease(m_maskImage);
m_maskImage = 0;
- delete[] m_maskData;
m_maskData = 0;
m_window = 0;
if (m_subscribesForGlobalFrameNotifications) {
@@ -174,6 +173,36 @@ static QTouchDevice *touchDevice = 0;
QWindowSystemInterface::handleExposeEvent(m_window, m_window->geometry());
}
+- (void)viewDidMoveToSuperview
+{
+ if (!(m_window->type() & Qt::SubWindow))
+ return;
+
+ if ([self superview]) {
+ m_platformWindow->m_contentViewIsEmbedded = true;
+ QWindowSystemInterface::handleGeometryChange(m_window, m_platformWindow->geometry());
+ QWindowSystemInterface::handleExposeEvent(m_window, m_platformWindow->geometry());
+ QWindowSystemInterface::flushWindowSystemEvents();
+ } else {
+ m_platformWindow->m_contentViewIsEmbedded = false;
+ }
+}
+
+- (void)viewWillMoveToWindow:(NSWindow *)newWindow
+{
+ // ### Merge "normal" window code path with this one for 5.1.
+ if (!(m_window->type() & Qt::SubWindow))
+ return;
+
+ if (newWindow) {
+ [[NSNotificationCenter defaultCenter] addObserver:self
+ selector:@selector(windowNotification:)
+ name:nil // Get all notifications
+ object:newWindow];
+ } else {
+ [[NSNotificationCenter defaultCenter] removeObserver:self name:nil object:[self window]];
+ }
+}
- (void)updateGeometry
{
QRect geometry;
@@ -182,6 +211,9 @@ static QTouchDevice *touchDevice = 0;
NSRect rect = [self frame];
NSRect windowRect = [[self window] frame];
geometry = QRect(windowRect.origin.x, qt_mac_flipYCoordinate(windowRect.origin.y + rect.size.height), rect.size.width, rect.size.height);
+ } else if (m_window->type() & Qt::SubWindow) {
+ // embedded child window, use the frame rect ### merge with case below
+ geometry = qt_mac_toQRect([self bounds]);
} else {
// child window, use the frame rect
geometry = qt_mac_toQRect([self frame]);
@@ -199,9 +231,16 @@ static QTouchDevice *touchDevice = 0;
// an infinite loop when this notification is triggered again.)
m_platformWindow->QPlatformWindow::setGeometry(geometry);
+ // Don't send the geometry change if the QWindow is designated to be
+ // embedded in a foregin view hiearchy but has not actually been
+ // embedded yet - it's too early.
+ if ((m_window->type() & Qt::SubWindow) && !m_platformWindow->m_contentViewIsEmbedded)
+ return;
+
// Send a geometry change event to Qt, if it's ready to handle events
if (!m_platformWindow->m_inConstructor) {
QWindowSystemInterface::handleGeometryChange(m_window, geometry);
+ QWindowSystemInterface::handleExposeEvent(m_window, geometry);
QWindowSystemInterface::flushWindowSystemEvents();
}
}
@@ -265,6 +304,16 @@ static QTouchDevice *touchDevice = 0;
[self setNeedsDisplayInRect:NSMakeRect(br.x(), br.y(), br.width(), br.height())];
}
+- (BOOL) hasMask
+{
+ return m_maskData != 0;
+}
+
+- (BOOL) isOpaque
+{
+ return m_platformWindow->isOpaque();
+}
+
- (void) setMaskRegion:(const QRegion *)region
{
m_shouldInvalidateWindowShadow = true;
@@ -272,6 +321,7 @@ static QTouchDevice *touchDevice = 0;
CGImageRelease(m_maskImage);
if (region->isEmpty()) {
m_maskImage = 0;
+ return;
}
const QRect &rect = region->boundingRect();
@@ -337,7 +387,12 @@ static QTouchDevice *touchDevice = 0;
);
CGImageRef bsCGImage = m_backingStore->getBackingStoreCGImage();
CGImageRef cleanImg = CGImageCreateWithImageInRect(bsCGImage, backingStoreRect);
- CGContextSetBlendMode(cgContext, kCGBlendModeCopy);
+
+ // Optimization: Copy frame buffer content instead of blending for
+ // top-level windows where Qt fills the entire window content area.
+ if (m_platformWindow->m_nsWindow)
+ CGContextSetBlendMode(cgContext, kCGBlendModeCopy);
+
CGContextDrawImage(cgContext, dirtyWindowRect, cleanImg);
// Clean-up:
@@ -353,14 +408,39 @@ static QTouchDevice *touchDevice = 0;
return YES;
}
+- (BOOL)becomeFirstResponder
+{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return NO;
+ QWindow *focusWindow = m_window;
+
+ // For widgets we need to do a bit of trickery as the window
+ // to activate is the window of the top-level widget.
+ if (m_window->metaObject()->className() == QStringLiteral("QWidgetWindow")) {
+ while (focusWindow->parent()) {
+ focusWindow = focusWindow->parent();
+ }
+ }
+ QWindowSystemInterface::handleWindowActivated(focusWindow);
+ return YES;
+}
+
- (BOOL)acceptsFirstResponder
{
+ if (m_window->flags() & Qt::WindowDoesNotAcceptFocus)
+ return NO;
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return NO;
+ if ((m_window->flags() & Qt::ToolTip) == Qt::ToolTip)
+ return NO;
return YES;
}
- (BOOL)acceptsFirstMouse:(NSEvent *)theEvent
{
- Q_UNUSED(theEvent);
+ Q_UNUSED(theEvent)
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return NO;
return YES;
}
@@ -403,6 +483,11 @@ static QTouchDevice *touchDevice = 0;
}
}
+- (void)resetMouseButtons
+{
+ m_buttons = Qt::NoButton;
+}
+
- (void)handleMouseEvent:(NSEvent *)theEvent
{
QPoint qtWindowPoint, qtScreenPoint;
@@ -460,6 +545,8 @@ static QTouchDevice *touchDevice = 0;
- (void)mouseDown:(NSEvent *)theEvent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super mouseDown:theEvent];
m_sendUpAsRightButton = false;
if (m_platformWindow->m_activePopupWindow) {
QWindowSystemInterface::handleCloseEvent(m_platformWindow->m_activePopupWindow);
@@ -484,6 +571,8 @@ static QTouchDevice *touchDevice = 0;
- (void)mouseDragged:(NSEvent *)theEvent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super mouseDragged:theEvent];
if (!(m_buttons & Qt::LeftButton))
qWarning("QNSView mouseDragged: Internal mouse button tracking invalid (missing Qt::LeftButton)");
[self handleMouseEvent:theEvent];
@@ -491,6 +580,8 @@ static QTouchDevice *touchDevice = 0;
- (void)mouseUp:(NSEvent *)theEvent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super mouseUp:theEvent];
if (m_sendUpAsRightButton) {
m_buttons &= ~Qt::RightButton;
m_sendUpAsRightButton = false;
@@ -508,6 +599,7 @@ static QTouchDevice *touchDevice = 0;
if (NSIsEmptyRect([self visibleRect]))
return;
+ // Remove current trakcing areas:
QCocoaAutoReleasePool pool;
if (NSArray *trackingArray = [self trackingAreas]) {
NSUInteger size = [trackingArray count];
@@ -520,7 +612,7 @@ static QTouchDevice *touchDevice = 0;
// Ideally, we shouldn't have NSTrackingMouseMoved events included below, it should
// only be turned on if mouseTracking, hover is on or a tool tip is set.
// Unfortunately, Qt will send "tooltip" events on mouse moves, so we need to
- // turn it on in ALL case. That means EVERY QCocoaView gets to pay the cost of
+ // turn it on in ALL case. That means EVERY QWindow gets to pay the cost of
// mouse moves delivered to it (Apple recommends keeping it OFF because there
// is a performance hit). So it goes.
NSUInteger trackingOptions = NSTrackingMouseEnteredAndExited | NSTrackingActiveInActiveApp
@@ -535,30 +627,74 @@ static QTouchDevice *touchDevice = 0;
- (void)mouseMoved:(NSEvent *)theEvent
{
- [self handleMouseEvent:theEvent];
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super mouseMoved:theEvent];
+
+ QPoint windowPoint, screenPoint;
+ [self convertFromEvent:theEvent toWindowPoint:&windowPoint andScreenPoint:&screenPoint];
+ QWindow *childWindow = m_platformWindow->childWindowAt(windowPoint);
+
+ // Top-level windows generate enter-leave events for sub-windows.
+ // Qt wants to know which window (if any) will be entered at the
+ // the time of the leave. This is dificult to accomplish by
+ // handling mouseEnter and mouseLeave envents, since they are sent
+ // individually to different views.
+ if (m_platformWindow->m_nsWindow && childWindow) {
+ if (childWindow != m_platformWindow->m_underMouseWindow) {
+ QWindowSystemInterface::handleEnterLeaveEvent(childWindow, m_platformWindow->m_underMouseWindow, windowPoint, screenPoint);
+ m_platformWindow->m_underMouseWindow = childWindow;
+ }
+ }
+
+ // Cocoa keeps firing mouse move events for obscured parent views. Qt should not
+ // send those events so filter them out here.
+ if (childWindow != m_window)
+ return;
+
+ [self handleMouseEvent: theEvent];
}
- (void)mouseEntered:(NSEvent *)theEvent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super mouseEntered:theEvent];
+
+ // Top-level windows generate enter events for sub-windows.
+ if (!m_platformWindow->m_nsWindow)
+ return;
+
QPoint windowPoint, screenPoint;
[self convertFromEvent:theEvent toWindowPoint:&windowPoint andScreenPoint:&screenPoint];
- QWindowSystemInterface::handleEnterEvent(m_window, windowPoint, screenPoint);
+ m_platformWindow->m_underMouseWindow = m_platformWindow->childWindowAt(windowPoint);
+ QWindowSystemInterface::handleEnterEvent(m_platformWindow->m_underMouseWindow, windowPoint, screenPoint);
}
- (void)mouseExited:(NSEvent *)theEvent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super mouseExited:theEvent];
Q_UNUSED(theEvent);
- QWindowSystemInterface::handleLeaveEvent(m_window);
+
+ // Top-level windows generate leave events for sub-windows.
+ if (!m_platformWindow->m_nsWindow)
+ return;
+
+ QWindowSystemInterface::handleLeaveEvent(m_platformWindow->m_underMouseWindow);
+ m_platformWindow->m_underMouseWindow = 0;
}
- (void)rightMouseDown:(NSEvent *)theEvent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super rightMouseDown:theEvent];
m_buttons |= Qt::RightButton;
[self handleMouseEvent:theEvent];
}
- (void)rightMouseDragged:(NSEvent *)theEvent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super rightMouseDragged:theEvent];
if (!(m_buttons & Qt::RightButton))
qWarning("QNSView rightMouseDragged: Internal mouse button tracking invalid (missing Qt::RightButton)");
[self handleMouseEvent:theEvent];
@@ -566,18 +702,24 @@ static QTouchDevice *touchDevice = 0;
- (void)rightMouseUp:(NSEvent *)theEvent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super rightMouseUp:theEvent];
m_buttons &= ~Qt::RightButton;
[self handleMouseEvent:theEvent];
}
- (void)otherMouseDown:(NSEvent *)theEvent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super otherMouseDown:theEvent];
m_buttons |= cocoaButton2QtButton([theEvent buttonNumber]);
[self handleMouseEvent:theEvent];
}
- (void)otherMouseDragged:(NSEvent *)theEvent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super otherMouseDragged:theEvent];
if (!(m_buttons & ~(Qt::LeftButton | Qt::RightButton)))
qWarning("QNSView otherMouseDragged: Internal mouse button tracking invalid (missing Qt::MiddleButton or Qt::ExtraButton*)");
[self handleMouseEvent:theEvent];
@@ -585,6 +727,8 @@ static QTouchDevice *touchDevice = 0;
- (void)otherMouseUp:(NSEvent *)theEvent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super otherMouseUp:theEvent];
m_buttons &= ~cocoaButton2QtButton([theEvent buttonNumber]);
[self handleMouseEvent:theEvent];
}
@@ -620,6 +764,8 @@ static QTouchDevice *touchDevice = 0;
#ifndef QT_NO_WHEELEVENT
- (void)scrollWheel:(NSEvent *)theEvent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super scrollWheel:theEvent];
const EventRef carbonEvent = (EventRef)[theEvent eventRef];
const UInt32 carbonEventKind = carbonEvent ? ::GetEventKind(carbonEvent) : 0;
const bool scrollEvent = carbonEventKind == kEventMouseScroll;
@@ -727,6 +873,7 @@ static QTouchDevice *touchDevice = 0;
ulong nativeModifiers = [nsevent modifierFlags];
Qt::KeyboardModifiers modifiers = [self convertKeyModifiers: nativeModifiers];
NSString *charactersIgnoringModifiers = [nsevent charactersIgnoringModifiers];
+ NSString *characters = [nsevent characters];
// [from Qt 4 impl] There is no way to get the scan code from carbon. But we cannot
// use the value 0, since it indicates that the event originates from somewhere
@@ -739,9 +886,12 @@ static QTouchDevice *touchDevice = 0;
QChar ch;
int keyCode;
- if ([charactersIgnoringModifiers length] > 0) {
- // convert the first character into a key code
- ch = QChar([charactersIgnoringModifiers characterAtIndex:0]);
+ if ([charactersIgnoringModifiers length] > 0) { // convert the first character into a key code
+ if ((modifiers & Qt::ControlModifier) && ([characters length] != 0)) {
+ ch = QChar([characters characterAtIndex:0]);
+ } else {
+ ch = QChar([charactersIgnoringModifiers characterAtIndex:0]);
+ }
keyCode = [self convertKeyCode:ch];
} else {
// might be a dead key
@@ -757,7 +907,7 @@ static QTouchDevice *touchDevice = 0;
// ignore text for the U+F700-U+F8FF range. This is used by Cocoa when
// delivering function keys (e.g. arrow keys, backspace, F1-F35, etc.)
if ([charactersIgnoringModifiers length] == 1 && (ch.unicode() < 0xf700 || ch.unicode() > 0xf8ff))
- text = QCFString::toQString([nsevent characters]);
+ text = QCFString::toQString(characters);
if (m_composingText.isEmpty())
m_sendKeyEvent = !QWindowSystemInterface::tryHandleShortcutEvent(m_window, timestamp, keyCode, modifiers, text);
@@ -785,11 +935,15 @@ static QTouchDevice *touchDevice = 0;
- (void)keyDown:(NSEvent *)nsevent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super keyDown:nsevent];
[self handleKeyEvent:nsevent eventType:int(QEvent::KeyPress)];
}
- (void)keyUp:(NSEvent *)nsevent
{
+ if (m_window->flags() & Qt::WindowTransparentForInput)
+ return [super keyUp:nsevent];
[self handleKeyEvent:nsevent eventType:int(QEvent::KeyRelease)];
}
diff --git a/src/plugins/platforms/cocoa/qnsviewaccessibility.mm b/src/plugins/platforms/cocoa/qnsviewaccessibility.mm
index 8ee39bf767..e3b8cf6532 100644
--- a/src/plugins/platforms/cocoa/qnsviewaccessibility.mm
+++ b/src/plugins/platforms/cocoa/qnsviewaccessibility.mm
@@ -46,13 +46,11 @@
#include "qcocoaaccessibility.h"
#include "qcocoaaccessibilityelement.h"
-#include "QAccessibleActionInterface"
+#include <QtGui/private/qaccessible2_p.h>
#include <QtCore/QDebug>
#import <AppKit/NSAccessibility.h>
-#ifndef QT_NO_COCOA_ACCESSIBILITY
-
@implementation QNSView (QNSViewAccessibility)
// The QNSView is a container that the user does not interact directly with:
@@ -77,7 +75,10 @@
int numKids = m_accessibleRoot->childCount();
NSMutableArray *kids = [NSMutableArray arrayWithCapacity:numKids];
for (int i = 0; i < numKids; ++i) {
- QCocoaAccessibleElement *element = [QCocoaAccessibleElement createElementWithInterface: m_accessibleRoot->child(i) parent:self ];
+ QAccessibleInterface *child = m_accessibleRoot->child(i);
+ Q_ASSERT(child);
+ QAccessible::Id childAxid = QAccessible::uniqueId(child);
+ QCocoaAccessibleElement *element = [QCocoaAccessibleElement createElementWithId:childAxid parent:self];
[kids addObject: element];
[element release];
}
@@ -99,12 +100,10 @@
}
// Hit a child, forward to child accessible interface.
-
- QCocoaAccessibleElement *accessibleElement = [QCocoaAccessibleElement createElementWithInterface: childInterface parent:self ];
+ QAccessible::Id childAxid = QAccessible::uniqueId(childInterface);
+ QCocoaAccessibleElement *accessibleElement = [QCocoaAccessibleElement createElementWithId:childAxid parent:self ];
[accessibleElement autorelease];
return [accessibleElement accessibilityHitTest:point];
}
@end
-
-#endif // QT_NO_COCOA_ACCESSIBILITY
diff --git a/src/plugins/platforms/cocoa/qnswindowdelegate.h b/src/plugins/platforms/cocoa/qnswindowdelegate.h
index 53bbeb1318..98ad7b8c9d 100644
--- a/src/plugins/platforms/cocoa/qnswindowdelegate.h
+++ b/src/plugins/platforms/cocoa/qnswindowdelegate.h
@@ -46,26 +46,6 @@
#include "qcocoawindow.h"
-#if MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_5
-@protocol NSWindowDelegate <NSObject>
-//- (NSSize)windowWillResize:(NSWindow *)window toSize:(NSSize)proposedFrameSize;
-//- (void)windowDidMiniaturize:(NSNotification*)notification;
-- (void)windowDidResize:(NSNotification *)notification;
-- (void)windowWillClose:(NSNotification *)notification;
-//- (NSRect)windowWillUseStandardFrame:(NSWindow *)window defaultFrame:(NSRect)defaultFrame;
-- (void)windowDidMove:(NSNotification *)notification;
-//- (BOOL)windowShouldClose:(id)window;
-//- (void)windowDidDeminiaturize:(NSNotification *)notification;
-//- (void)windowDidBecomeMain:(NSNotification*)notification;
-//- (void)windowDidResignMain:(NSNotification*)notification;
-//- (void)windowDidBecomeKey:(NSNotification*)notification;
-//- (void)windowDidResignKey:(NSNotification*)notification;
-//- (BOOL)window:(NSWindow *)window shouldPopUpDocumentPathMenu:(NSMenu *)menu;
-//- (BOOL)window:(NSWindow *)window shouldDragDocumentWithEvent:(NSEvent *)event from:(NSPoint)dragImageLocation withPasteboard:(NSPasteboard *)pasteboard;
-//- (BOOL)windowShouldZoom:(NSWindow *)window toFrame:(NSRect)newFrame;
-@end
-#endif
-
@interface QNSWindowDelegate : NSObject <NSWindowDelegate>
{
QCocoaWindow *m_cocoaWindow;
diff --git a/src/plugins/platforms/cocoa/qpaintengine_mac.mm b/src/plugins/platforms/cocoa/qpaintengine_mac.mm
index 101be611ad..301beb11c1 100644
--- a/src/plugins/platforms/cocoa/qpaintengine_mac.mm
+++ b/src/plugins/platforms/cocoa/qpaintengine_mac.mm
@@ -90,14 +90,11 @@ static void qt_mac_clip_cg(CGContextRef hd, const QRegion &rgn, CGAffineTransfor
if (rgn.isEmpty()) {
CGContextAddRect(hd, CGRectMake(0, 0, 0, 0));
} else {
-#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_5) {
QCFType<HIMutableShapeRef> shape = qt_mac_QRegionToHIMutableShape(rgn);
Q_ASSERT(!HIShapeIsEmpty(shape));
HIShapeReplacePathInCGContext(shape, hd);
- } else
-#endif
- {
+ } else {
QVector<QRect> rects = rgn.rects();
const int count = rects.size();
for (int i = 0; i < count; i++) {
@@ -338,11 +335,9 @@ CGColorSpaceRef QCoreGraphicsPaintEngine::macGenericColorSpace()
{
#if 0
if (!m_genericColorSpace) {
-#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4
if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_4) {
m_genericColorSpace = CGColorSpaceCreateWithName(kCGColorSpaceGenericRGB);
} else
-#endif
{
m_genericColorSpace = CGColorSpaceCreateDeviceRGB();
}
@@ -1185,7 +1180,6 @@ extern "C" {
void
QCoreGraphicsPaintEngine::updateCompositionMode(QPainter::CompositionMode mode)
{
-#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_5) {
int cg_mode = kCGBlendModeNormal;
switch (mode) {
@@ -1267,11 +1261,9 @@ QCoreGraphicsPaintEngine::updateCompositionMode(QPainter::CompositionMode mode)
if (cg_mode > -1) {
CGContextSetBlendMode(d_func()->hd, CGBlendMode(cg_mode));
}
- } else
-#endif
- // The standard porter duff ops.
- if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_3
+ } else if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_3
&& mode <= QPainter::CompositionMode_Xor) {
+ // The standard porter duff ops.
int cg_mode = kCGCompositeModeCopy;
switch (mode) {
case QPainter::CompositionMode_SourceOver:
@@ -1317,7 +1309,6 @@ QCoreGraphicsPaintEngine::updateCompositionMode(QPainter::CompositionMode mode)
if (cg_mode > -1)
CGContextSetCompositeOperation(d_func()->hd, CGCompositeMode(cg_mode));
} else {
-#if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4)
bool needPrivateAPI = false;
if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_4) {
int cg_mode = kCGBlendModeNormal;
@@ -1367,7 +1358,6 @@ QCoreGraphicsPaintEngine::updateCompositionMode(QPainter::CompositionMode mode)
else
CGContextSetCompositeOperation(d_func()->hd, CGCompositeMode(cg_mode));
}
-#endif
}
}
@@ -1376,13 +1366,8 @@ QCoreGraphicsPaintEngine::updateRenderHints(QPainter::RenderHints hints)
{
Q_D(QCoreGraphicsPaintEngine);
CGContextSetShouldAntialias(d->hd, hints & QPainter::Antialiasing);
- static const CGFloat ScaleFactor = qt_mac_get_scalefactor();
- if (ScaleFactor > 1.) {
- CGContextSetInterpolationQuality(d->hd, kCGInterpolationHigh);
- } else {
- CGContextSetInterpolationQuality(d->hd, (hints & QPainter::SmoothPixmapTransform) ?
- kCGInterpolationHigh : kCGInterpolationNone);
- }
+ CGContextSetInterpolationQuality(d->hd, (hints & QPainter::SmoothPixmapTransform) ?
+ kCGInterpolationHigh : kCGInterpolationNone);
bool textAntialiasing = (hints & QPainter::TextAntialiasing) == QPainter::TextAntialiasing;
if (!textAntialiasing || d->disabledSmoothFonts) {
d->disabledSmoothFonts = !textAntialiasing;
diff --git a/src/plugins/platforms/cocoa/qpaintengine_mac_p.h b/src/plugins/platforms/cocoa/qpaintengine_mac_p.h
index 2763a14690..08ede4cdd6 100644
--- a/src/plugins/platforms/cocoa/qpaintengine_mac_p.h
+++ b/src/plugins/platforms/cocoa/qpaintengine_mac_p.h
@@ -122,8 +122,6 @@ public:
void drawPolygon(const QPoint *points, int pointCount, PolygonDrawMode mode)
{ QPaintEngine::drawPolygon(points, pointCount, mode); }
- bool supportsTransformations(qreal, const QTransform &) const { return true; };
-
protected:
friend class QMacPrintEngine;
friend class QMacPrintEnginePrivate;
@@ -210,45 +208,6 @@ inline void QCoreGraphicsPaintEnginePrivate::restoreGraphicsState()
CGContextRestoreGState(hd);
}
-class QMacQuartzPaintDevice : public QPaintDevice
-{
-public:
- QMacQuartzPaintDevice(CGContextRef cg, int width, int height, int bytesPerLine)
- : mCG(cg), mWidth(width), mHeight(height), mBytesPerLine(bytesPerLine)
- { }
- int devType() const { return QInternal::MacQuartz; }
- CGContextRef cgContext() const { return mCG; }
- int metric(PaintDeviceMetric metric) const {
- switch (metric) {
- case PdmWidth:
- return mWidth;
- case PdmHeight:
- return mHeight;
- case PdmWidthMM:
- return (qt_defaultDpiX() * mWidth) / 2.54;
- case PdmHeightMM:
- return (qt_defaultDpiY() * mHeight) / 2.54;
- case PdmNumColors:
- return 0;
- case PdmDepth:
- return 32;
- case PdmDpiX:
- case PdmPhysicalDpiX:
- return qt_defaultDpiX();
- case PdmDpiY:
- case PdmPhysicalDpiY:
- return qt_defaultDpiY();
- }
- return 0;
- }
- QPaintEngine *paintEngine() const { qWarning("This function should never be called."); return 0; }
-private:
- CGContextRef mCG;
- int mWidth;
- int mHeight;
- int mBytesPerLine;
-};
-
QT_END_NAMESPACE
#endif // QPAINTENGINE_MAC_P_H
diff --git a/src/plugins/platforms/cocoa/qprintengine_mac.mm b/src/plugins/platforms/cocoa/qprintengine_mac.mm
index 54019372bc..4748005f1a 100644
--- a/src/plugins/platforms/cocoa/qprintengine_mac.mm
+++ b/src/plugins/platforms/cocoa/qprintengine_mac.mm
@@ -180,6 +180,38 @@ QPrinter::PaperSize QMacPrintEnginePrivate::paperSize() const
return QPlatformPrinterSupport::convertQSizeFToPaperSize(sizef);
}
+void QMacPrintEnginePrivate::setPaperName(const QString &name)
+{
+ Q_Q(QMacPrintEngine);
+ PMPrinter printer;
+
+ if (PMSessionGetCurrentPrinter(session(), &printer) == noErr) {
+ CFArrayRef array;
+ if (PMPrinterGetPaperList(printer, &array) != noErr) {
+ PMRelease(printer);
+ return;
+ }
+ int count = CFArrayGetCount(array);
+ for (int i = 0; i < count; ++i) {
+ PMPaper paper = static_cast<PMPaper>(const_cast<void *>(CFArrayGetValueAtIndex(array, i)));
+ QCFString paperName;
+ if (PMPaperCreateLocalizedName(paper, printer, &paperName) == noErr) {
+ if (QString(paperName) == name) {
+ PMPageFormat tmp;
+ PMCreatePageFormatWithPMPaper(&tmp, paper);
+ PMCopyPageFormat(tmp, format());
+ q->setProperty(QPrintEngine::PPK_Orientation, orient);
+ if (PMSessionValidatePageFormat(session(), format(), kPMDontWantBoolean) != noErr) {
+ // Don't know, warn for the moment.
+ qWarning("QMacPrintEngine, problem setting paper name");
+ }
+ }
+ }
+ }
+ PMRelease(printer);
+ }
+}
+
QList<QVariant> QMacPrintEnginePrivate::supportedResolutions() const
{
Q_ASSERT_X(printInfo, "QMacPrinterEngine::supportedResolutions",
@@ -190,23 +222,7 @@ QList<QVariant> QMacPrintEnginePrivate::supportedResolutions() const
if (PMSessionGetCurrentPrinter(session(), &printer) == noErr) {
PMResolution res;
OSStatus status = PMPrinterGetPrinterResolutionCount(printer, &resCount);
- if (status == kPMNotImplemented) {
-#if (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_5)
- // *Sigh* we have to use the non-indexed version.
- if (PMPrinterGetPrinterResolution(printer, kPMMinSquareResolution, &res) == noErr)
- resolutions.append(int(res.hRes));
- if (PMPrinterGetPrinterResolution(printer, kPMMaxSquareResolution, &res) == noErr) {
- QVariant var(int(res.hRes));
- if (!resolutions.contains(var))
- resolutions.append(var);
- }
- if (PMPrinterGetPrinterResolution(printer, kPMDefaultResolution, &res) == noErr) {
- QVariant var(int(res.hRes));
- if (!resolutions.contains(var))
- resolutions.append(var);
- }
-#endif
- } else if (status == noErr) {
+ if (status == noErr) {
// According to the docs, index start at 1.
for (UInt32 i = 1; i <= resCount; ++i) {
if (PMPrinterGetIndexedPrinterResolution(printer, i, &res) == noErr)
@@ -617,6 +633,9 @@ void QMacPrintEngine::setProperty(PrintEnginePropertyKey key, const QVariant &va
case PPK_PaperSize:
d->setPaperSize(QPrinter::PaperSize(value.toInt()));
break;
+ case PPK_PaperName:
+ d->setPaperName(value.toString());
+ break;
case PPK_PrinterName: {
bool printerNameSet = false;
OSStatus status = noErr;
@@ -755,6 +774,9 @@ QVariant QMacPrintEngine::property(PrintEnginePropertyKey key) const
case PPK_PaperSize:
ret = d->paperSize();
break;
+ case PPK_PaperName:
+ ret = QCFString::toQString([d->printInfo localizedPaperName]);
+ break;
case PPK_PaperRect: {
QRect r;
PMRect macrect;
diff --git a/src/plugins/platforms/cocoa/qprintengine_mac_p.h b/src/plugins/platforms/cocoa/qprintengine_mac_p.h
index e122cc5822..28183118d8 100644
--- a/src/plugins/platforms/cocoa/qprintengine_mac_p.h
+++ b/src/plugins/platforms/cocoa/qprintengine_mac_p.h
@@ -53,6 +53,8 @@
// We mean it.
//
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_PRINTER
#include <QtPrintSupport/qprinter.h>
@@ -142,6 +144,7 @@ public:
bool newPage_helper();
void setPaperSize(QPrinter::PaperSize ps);
QPrinter::PaperSize paperSize() const;
+ void setPaperName(const QString &name);
QList<QVariant> supportedResolutions() const;
inline bool isPrintSessionInitialized() const
{
diff --git a/src/plugins/platforms/directfb/qdirectfbcursor.cpp b/src/plugins/platforms/directfb/qdirectfbcursor.cpp
index afddba3482..b03af51b1a 100644
--- a/src/plugins/platforms/directfb/qdirectfbcursor.cpp
+++ b/src/plugins/platforms/directfb/qdirectfbcursor.cpp
@@ -59,8 +59,9 @@ void QDirectFBCursor::changeCursor(QCursor *cursor, QWindow *)
int ySpot;
QPixmap map;
- if (cursor->shape() != Qt::BitmapCursor) {
- m_image->set(cursor->shape());
+ const Qt::CursorShape newShape = cursor ? cursor->shape() : Qt::ArrowCursor;
+ if (newShape != Qt::BitmapCursor) {
+ m_image->set(newShape);
xSpot = m_image->hotspot().x();
ySpot = m_image->hotspot().y();
QImage *i = m_image->image();
diff --git a/src/plugins/platforms/eglfs/eglfs.pri b/src/plugins/platforms/eglfs/eglfs.pri
new file mode 100644
index 0000000000..eb66e17479
--- /dev/null
+++ b/src/plugins/platforms/eglfs/eglfs.pri
@@ -0,0 +1,44 @@
+QT += core-private gui-private platformsupport-private
+
+#DEFINES += QEGL_EXTRA_DEBUG
+
+#Avoid X11 header collision
+DEFINES += MESA_EGL_NO_X11_HEADERS
+
+#To test the hooks on x11 (xlib), comment the above define too
+#EGLFS_PLATFORM_HOOKS_SOURCES += qeglfshooks_x11.cpp
+#LIBS += -lX11
+
+SOURCES += $$PWD/qeglfsintegration.cpp \
+ $$PWD/qeglfswindow.cpp \
+ $$PWD/qeglfsbackingstore.cpp \
+ $$PWD/qeglfsscreen.cpp \
+ $$PWD/qeglfshooks_stub.cpp \
+ $$PWD/qeglfscursor.cpp \
+ $$PWD/qeglfscontext.cpp
+
+HEADERS += $$PWD/qeglfsintegration.h \
+ $$PWD/qeglfswindow.h \
+ $$PWD/qeglfsbackingstore.h \
+ $$PWD/qeglfsscreen.h \
+ $$PWD/qeglfscursor.h \
+ $$PWD/qeglfshooks.h \
+ $$PWD/qeglfscontext.h
+
+QMAKE_LFLAGS += $$QMAKE_LFLAGS_NOUNDEF
+
+INCLUDEPATH += $$PWD
+
+!isEmpty(EGLFS_PLATFORM_HOOKS_SOURCES) {
+ HEADERS += $$EGLFS_PLATFORM_HOOKS_HEADERS
+ SOURCES += $$EGLFS_PLATFORM_HOOKS_SOURCES
+ LIBS += $$EGLFS_PLATFORM_HOOKS_LIBS
+ DEFINES += EGLFS_PLATFORM_HOOKS
+}
+
+CONFIG += egl qpa/genericunixfontdatabase
+
+RESOURCES += $$PWD/cursor.qrc
+
+OTHER_FILES += \
+ $$PWD/eglfs.json
diff --git a/src/plugins/platforms/eglfs/eglfs.pro b/src/plugins/platforms/eglfs/eglfs.pro
index 45059a9cb9..8827f7680c 100644
--- a/src/plugins/platforms/eglfs/eglfs.pro
+++ b/src/plugins/platforms/eglfs/eglfs.pro
@@ -4,48 +4,6 @@ PLUGIN_TYPE = platforms
PLUGIN_CLASS_NAME = QEglFSIntegrationPlugin
load(qt_plugin)
-QT += core-private gui-private platformsupport-private
+SOURCES += $$PWD/main.cpp
-#DEFINES += QEGL_EXTRA_DEBUG
-
-#Avoid X11 header collision
-DEFINES += MESA_EGL_NO_X11_HEADERS
-
-#To test the hooks on x11 (xlib), comment the above define too
-#EGLFS_PLATFORM_HOOKS_SOURCES += qeglfshooks_x11.cpp
-#LIBS += -lX11
-
-SOURCES = main.cpp \
- qeglfsintegration.cpp \
- qeglfswindow.cpp \
- qeglfsbackingstore.cpp \
- qeglfsscreen.cpp \
- qeglfshooks_stub.cpp \
- qeglfscursor.cpp \
- qeglfscontext.cpp
-
-HEADERS = qeglfsintegration.h \
- qeglfswindow.h \
- qeglfsbackingstore.h \
- qeglfsscreen.h \
- qeglfscursor.h \
- qeglfshooks.h \
- qeglfscontext.h
-
-QMAKE_LFLAGS += $$QMAKE_LFLAGS_NOUNDEF
-
-INCLUDEPATH += $$PWD
-
-!isEmpty(EGLFS_PLATFORM_HOOKS_SOURCES) {
- HEADERS += $$EGLFS_PLATFORM_HOOKS_HEADERS
- SOURCES += $$EGLFS_PLATFORM_HOOKS_SOURCES
- LIBS += $$EGLFS_PLATFORM_HOOKS_LIBS
- DEFINES += EGLFS_PLATFORM_HOOKS
-}
-
-CONFIG += egl qpa/genericunixfontdatabase
-
-RESOURCES += cursor.qrc
-
-OTHER_FILES += \
- eglfs.json
+include(eglfs.pri)
diff --git a/src/plugins/platforms/eglfs/qeglfscontext.cpp b/src/plugins/platforms/eglfs/qeglfscontext.cpp
index 66b42d64e7..51439646c6 100644
--- a/src/plugins/platforms/eglfs/qeglfscontext.cpp
+++ b/src/plugins/platforms/eglfs/qeglfscontext.cpp
@@ -43,14 +43,17 @@
#include "qeglfswindow.h"
#include "qeglfscursor.h"
#include "qeglfshooks.h"
+#include "qeglfsintegration.h"
+#include <QtPlatformSupport/private/qeglpbuffer_p.h>
+#include <QtGui/QSurface>
#include <QtDebug>
QT_BEGIN_NAMESPACE
QEglFSContext::QEglFSContext(const QSurfaceFormat &format, QPlatformOpenGLContext *share,
EGLDisplay display, EGLenum eglApi)
- : QEGLPlatformContext(hooks->surfaceFormatFor(format), share, display, eglApi)
+ : QEGLPlatformContext(QEglFSHooks::hooks()->surfaceFormatFor(format), share, display, QEglFSIntegration::chooseConfig(display, QEglFSHooks::hooks()->surfaceFormatFor(format)), eglApi)
{
}
@@ -61,17 +64,22 @@ bool QEglFSContext::makeCurrent(QPlatformSurface *surface)
EGLSurface QEglFSContext::eglSurfaceForPlatformSurface(QPlatformSurface *surface)
{
- QEglFSWindow *window = static_cast<QEglFSWindow *>(surface);
- return window->surface();
+ if (surface->surface()->surfaceClass() == QSurface::Window)
+ return static_cast<QEglFSWindow *>(surface)->surface();
+ else
+ return static_cast<QEGLPbuffer *>(surface)->pbuffer();
}
void QEglFSContext::swapBuffers(QPlatformSurface *surface)
{
- QEglFSWindow *window = static_cast<QEglFSWindow *>(surface);
- // draw the cursor
- if (QEglFSCursor *cursor = static_cast<QEglFSCursor *>(window->screen()->cursor()))
- cursor->paintOnScreen();
+ if (surface->surface()->surfaceClass() == QSurface::Window) {
+ QEglFSWindow *window = static_cast<QEglFSWindow *>(surface);
+ // draw the cursor
+ if (QEglFSCursor *cursor = static_cast<QEglFSCursor *>(window->screen()->cursor()))
+ cursor->paintOnScreen();
+ }
+ QEglFSHooks::hooks()->waitForVSync();
QEGLPlatformContext::swapBuffers(surface);
}
diff --git a/src/plugins/platforms/eglfs/qeglfscursor.cpp b/src/plugins/platforms/eglfs/qeglfscursor.cpp
index c245b1b5bb..9dc836b8b1 100644
--- a/src/plugins/platforms/eglfs/qeglfscursor.cpp
+++ b/src/plugins/platforms/eglfs/qeglfscursor.cpp
@@ -196,15 +196,16 @@ void QEglFSCursor::changeCursor(QCursor *cursor, QWindow *window)
bool QEglFSCursor::setCurrentCursor(QCursor *cursor)
{
- if (m_cursor.shape == cursor->shape() && cursor->shape() != Qt::BitmapCursor)
+ const Qt::CursorShape newShape = cursor ? cursor->shape() : Qt::ArrowCursor;
+ if (m_cursor.shape == newShape && newShape != Qt::BitmapCursor)
return false;
if (m_cursor.shape == Qt::BitmapCursor) {
m_cursor.customCursorImage = QImage(); // in case render() never uploaded it
}
- m_cursor.shape = cursor->shape();
- if (cursor->shape() != Qt::BitmapCursor) { // standard cursor
+ m_cursor.shape = newShape;
+ if (newShape != Qt::BitmapCursor) { // standard cursor
const float ws = (float)m_cursorAtlas.cursorWidth / m_cursorAtlas.width,
hs = (float)m_cursorAtlas.cursorHeight / m_cursorAtlas.height;
m_cursor.textureRect = QRectF(ws * (m_cursor.shape % m_cursorAtlas.cursorsPerRow),
diff --git a/src/plugins/platforms/eglfs/qeglfshooks.h b/src/plugins/platforms/eglfs/qeglfshooks.h
index 2d095ba934..c8486b9378 100644
--- a/src/plugins/platforms/eglfs/qeglfshooks.h
+++ b/src/plugins/platforms/eglfs/qeglfshooks.h
@@ -43,6 +43,7 @@
#define QEGLFSHOOKS_H
#include <qpa/qplatformintegration.h>
+#include <qpa/qplatformscreen.h>
#include <QtGui/QSurfaceFormat>
#include <QtGui/QImage>
#include <EGL/egl.h>
@@ -55,11 +56,13 @@ class QEglFSScreen;
class QEglFSHooks
{
public:
- virtual ~QEglFSHooks() {};
+ virtual ~QEglFSHooks() {}
virtual void platformInit();
virtual void platformDestroy();
virtual EGLNativeDisplayType platformDisplay() const;
+ virtual QSizeF physicalScreenSize() const;
virtual QSize screenSize() const;
+ virtual QDpi logicalDpi() const;
virtual int screenDepth() const;
virtual QImage::Format screenFormat() const;
virtual QSurfaceFormat surfaceFormatFor(const QSurfaceFormat &inputFormat) const;
@@ -67,15 +70,22 @@ public:
virtual void destroyNativeWindow(EGLNativeWindowType window);
virtual bool hasCapability(QPlatformIntegration::Capability cap) const;
virtual QEglFSCursor *createCursor(QEglFSScreen *screen) const;
-};
+ virtual bool filterConfig(EGLDisplay display, EGLConfig config) const;
+ virtual void waitForVSync() const;
+
+ virtual const char *fbDeviceName() const;
+ static QEglFSHooks *hooks()
+ {
#ifdef EGLFS_PLATFORM_HOOKS
-extern QEglFSHooks *platformHooks;
-static QEglFSHooks *hooks = platformHooks;
+ extern QEglFSHooks *platformHooks;
+ return platformHooks;
#else
-extern QEglFSHooks stubHooks;
-static QEglFSHooks *hooks = &stubHooks;
+ extern QEglFSHooks stubHooks;
+ return &stubHooks;
#endif
+ }
+};
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/eglfs/qeglfshooks_stub.cpp b/src/plugins/platforms/eglfs/qeglfshooks_stub.cpp
index e9a22ea605..5c264834b3 100644
--- a/src/plugins/platforms/eglfs/qeglfshooks_stub.cpp
+++ b/src/plugins/platforms/eglfs/qeglfshooks_stub.cpp
@@ -46,15 +46,32 @@
#include <linux/fb.h>
#include <sys/ioctl.h>
+#include <private/qmath_p.h>
+#include <private/qcore_unix_p.h>
+
QT_BEGIN_NAMESPACE
+// file descriptor for the frame buffer
+// this is a global static to keep the QEglFSHooks interface as clean as possible
+static int framebuffer = -1;
+
+const char *QEglFSHooks::fbDeviceName() const
+{
+ return "/dev/fb0";
+}
+
void QEglFSHooks::platformInit()
{
- Q_UNUSED(hooks);
+ framebuffer = qt_safe_open(fbDeviceName(), O_RDONLY);
+
+ if (framebuffer == -1)
+ qWarning("EGLFS: Failed to open %s", fbDeviceName());
}
void QEglFSHooks::platformDestroy()
{
+ if (framebuffer != -1)
+ close(framebuffer);
}
EGLNativeDisplayType QEglFSHooks::platformDisplay() const
@@ -62,6 +79,55 @@ EGLNativeDisplayType QEglFSHooks::platformDisplay() const
return EGL_DEFAULT_DISPLAY;
}
+QSizeF QEglFSHooks::physicalScreenSize() const
+{
+ static QSizeF size;
+ if (size.isEmpty()) {
+
+ // Note: in millimeters
+ int width = qgetenv("QT_QPA_EGLFS_PHYSICAL_WIDTH").toInt();
+ int height = qgetenv("QT_QPA_EGLFS_PHYSICAL_HEIGHT").toInt();
+
+ if (width && height) {
+ // no need to read fb0
+ size.setWidth(width);
+ size.setHeight(height);
+ return size;
+ }
+
+ struct fb_var_screeninfo vinfo;
+ int w = -1;
+ int h = -1;
+
+ if (framebuffer != -1) {
+ if (ioctl(framebuffer, FBIOGET_VSCREENINFO, &vinfo) == -1) {
+ qWarning("EGLFS: Could not query variable screen info.");
+ } else {
+ w = vinfo.width;
+ h = vinfo.height;
+ }
+ }
+
+ const int defaultPhysicalDpi = 100;
+ size.setWidth(w <= 0 ? vinfo.xres * Q_MM_PER_INCH / defaultPhysicalDpi : qreal(w));
+ size.setHeight(h <= 0 ? vinfo.yres * Q_MM_PER_INCH / defaultPhysicalDpi : qreal(h));
+
+ if (w <= 0 || h <= 0) {
+ qWarning("EGLFS: Unable to query physical screen size, defaulting to %d dpi.\n"
+ "EGLFS: To override, set QT_QPA_EGLFS_PHYSICAL_WIDTH "
+ "and QT_QPA_EGLFS_PHYSICAL_HEIGHT (in millimeters).",
+ defaultPhysicalDpi);
+ }
+
+ // override fb0 from environment var setting
+ if (width)
+ size.setWidth(width);
+ if (height)
+ size.setWidth(height);
+ }
+ return size;
+}
+
QSize QEglFSHooks::screenSize() const
{
static QSize size;
@@ -78,17 +144,28 @@ QSize QEglFSHooks::screenSize() const
}
struct fb_var_screeninfo vinfo;
- int fd = open("/dev/fb0", O_RDONLY);
- if (fd != -1) {
- if (ioctl(fd, FBIOGET_VSCREENINFO, &vinfo) == -1)
- qWarning("Could not query variable screen info.");
- else
- size = QSize(vinfo.xres, vinfo.yres);
+ int xres = -1;
+ int yres = -1;
- close(fd);
- } else {
- qWarning("Failed to open /dev/fb0 to detect screen resolution.");
+ if (framebuffer != -1) {
+ if (ioctl(framebuffer, FBIOGET_VSCREENINFO, &vinfo) == -1) {
+ qWarning("EGLFS: Could not query variable screen info.");
+ } else {
+ xres = vinfo.xres;
+ yres = vinfo.yres;
+ }
+ }
+
+ const int defaultWidth = 800;
+ const int defaultHeight = 600;
+ size.setWidth(xres <= 0 ? defaultWidth : xres);
+ size.setHeight(yres <= 0 ? defaultHeight : yres);
+
+ if (xres <= 0 || yres <= 0) {
+ qWarning("EGLFS: Unable to query screen resolution, defaulting to %dx%d.\n"
+ "EGLFS: To override, set QT_QPA_EGLFS_WIDTH and QT_QPA_EGLFS_HEIGHT.",
+ defaultWidth, defaultHeight);
}
// override fb0 from environment var setting
@@ -101,27 +178,40 @@ QSize QEglFSHooks::screenSize() const
return size;
}
+QDpi QEglFSHooks::logicalDpi() const
+{
+ QSizeF ps = physicalScreenSize();
+ QSize s = screenSize();
+
+ return QDpi(25.4 * s.width() / ps.width(),
+ 25.4 * s.height() / ps.height());
+}
+
int QEglFSHooks::screenDepth() const
{
static int depth = qgetenv("QT_QPA_EGLFS_DEPTH").toInt();
if (depth == 0) {
struct fb_var_screeninfo vinfo;
- int fd = open("/dev/fb0", O_RDONLY);
- if (fd != -1) {
- if (ioctl(fd, FBIOGET_VSCREENINFO, &vinfo) == -1)
- qWarning("Could not query variable screen info.");
+ if (framebuffer != -1) {
+ if (ioctl(framebuffer, FBIOGET_VSCREENINFO, &vinfo) == -1)
+ qWarning("EGLFS: Could not query variable screen info.");
else
depth = vinfo.bits_per_pixel;
+ }
+
+ const int defaultDepth = 32;
- close(fd);
- } else {
- qWarning("Failed to open /dev/fb0 to detect screen depth.");
+ if (depth <= 0) {
+ depth = defaultDepth;
+
+ qWarning("EGLFS: Unable to query screen depth, defaulting to %d.\n"
+ "EGLFS: To override, set QT_QPA_EGLFS_DEPTH.", defaultDepth);
}
}
- return depth == 0 ? 32 : depth;
+ return depth;
}
QImage::Format QEglFSHooks::screenFormat() const
@@ -134,6 +224,11 @@ QSurfaceFormat QEglFSHooks::surfaceFormatFor(const QSurfaceFormat &inputFormat)
return inputFormat;
}
+bool QEglFSHooks::filterConfig(EGLDisplay, EGLConfig) const
+{
+ return true;
+}
+
EGLNativeWindowType QEglFSHooks::createNativeWindow(const QSize &size, const QSurfaceFormat &format)
{
Q_UNUSED(size);
@@ -158,6 +253,18 @@ QEglFSCursor *QEglFSHooks::createCursor(QEglFSScreen *screen) const
return 0;
}
+void QEglFSHooks::waitForVSync() const
+{
+#if defined(FBIO_WAITFORVSYNC)
+ static const bool forceSync = qgetenv("QT_QPA_EGLFS_FORCEVSYNC").toInt();
+ if (forceSync && framebuffer != -1) {
+ int arg = 0;
+ if (ioctl(framebuffer, FBIO_WAITFORVSYNC, &arg) == -1)
+ qWarning("Could not wait for vsync.");
+ }
+#endif
+}
+
#ifndef EGLFS_PLATFORM_HOOKS
QEglFSHooks stubHooks;
#endif
diff --git a/src/plugins/platforms/eglfs/qeglfsintegration.cpp b/src/plugins/platforms/eglfs/qeglfsintegration.cpp
index 0dcde9ca36..64e11b4e07 100644
--- a/src/plugins/platforms/eglfs/qeglfsintegration.cpp
+++ b/src/plugins/platforms/eglfs/qeglfsintegration.cpp
@@ -49,9 +49,11 @@
#include <QtPlatformSupport/private/qgenericunixfontdatabase_p.h>
#include <QtPlatformSupport/private/qgenericunixeventdispatcher_p.h>
+#include <QtPlatformSupport/private/qeglconvenience_p.h>
#include <QtPlatformSupport/private/qeglplatformcontext_p.h>
+#include <QtPlatformSupport/private/qeglpbuffer_p.h>
-#if !defined(QT_NO_EVDEV)
+#if !defined(QT_NO_EVDEV) && !defined(Q_OS_ANDROID)
#include <QtPlatformSupport/private/qevdevmousemanager_p.h>
#include <QtPlatformSupport/private/qevdevkeyboardmanager_p.h>
#include <QtPlatformSupport/private/qevdevtouch_p.h>
@@ -61,8 +63,11 @@
#include <QtGui/QSurfaceFormat>
#include <QtGui/QOpenGLContext>
#include <QtGui/QScreen>
+#include <QtGui/QOffscreenSurface>
#include <qpa/qplatformcursor.h>
+#include <qpa/qplatforminputcontextfactory_p.h>
+
#include "qeglfscontext.h"
#include <EGL/egl.h>
@@ -74,13 +79,13 @@ QEglFSIntegration::QEglFSIntegration()
{
QGuiApplicationPrivate::instance()->setEventDispatcher(mEventDispatcher);
-#if !defined(QT_NO_EVDEV)
+#if !defined(QT_NO_EVDEV) && !defined(Q_OS_ANDROID)
new QEvdevKeyboardManager(QLatin1String("EvdevKeyboard"), QString() /* spec */, this);
new QEvdevMouseManager(QLatin1String("EvdevMouse"), QString() /* spec */, this);
new QEvdevTouchScreenHandlerThread(QString() /* spec */, this);
#endif
- hooks->platformInit();
+ QEglFSHooks::hooks()->platformInit();
EGLint major, minor;
@@ -89,7 +94,7 @@ QEglFSIntegration::QEglFSIntegration()
qFatal("EGL error");
}
- mDisplay = eglGetDisplay(hooks ? hooks->platformDisplay() : EGL_DEFAULT_DISPLAY);
+ mDisplay = eglGetDisplay(QEglFSHooks::hooks() ? QEglFSHooks::hooks()->platformDisplay() : EGL_DEFAULT_DISPLAY);
if (mDisplay == EGL_NO_DISPLAY) {
qWarning("Could not open egl display\n");
qFatal("EGL error");
@@ -112,6 +117,8 @@ QEglFSIntegration::QEglFSIntegration()
mScreen = new QEglFSScreen(mDisplay);
screenAdded(mScreen);
+
+ mInputContext = QPlatformInputContextFactory::create();
}
QEglFSIntegration::~QEglFSIntegration()
@@ -119,13 +126,13 @@ QEglFSIntegration::~QEglFSIntegration()
delete mScreen;
eglTerminate(mDisplay);
- hooks->platformDestroy();
+ QEglFSHooks::hooks()->platformDestroy();
}
bool QEglFSIntegration::hasCapability(QPlatformIntegration::Capability cap) const
{
// We assume that devices will have more and not less capabilities
- if (hooks && hooks->hasCapability(cap))
+ if (QEglFSHooks::hooks() && QEglFSHooks::hooks()->hasCapability(cap))
return true;
switch (cap) {
@@ -150,7 +157,13 @@ QPlatformBackingStore *QEglFSIntegration::createPlatformBackingStore(QWindow *wi
QPlatformOpenGLContext *QEglFSIntegration::createPlatformOpenGLContext(QOpenGLContext *context) const
{
- return new QEglFSContext(context->format(), 0 /*share*/, mDisplay);
+ return new QEglFSContext(QEglFSHooks::hooks()->surfaceFormatFor(context->format()), context->shareHandle(), mDisplay);
+}
+
+QPlatformOffscreenSurface *QEglFSIntegration::createPlatformOffscreenSurface(QOffscreenSurface *surface) const
+{
+ QEglFSScreen *screen = static_cast<QEglFSScreen *>(surface->screen()->handle());
+ return new QEGLPbuffer(screen->display(), QEglFSHooks::hooks()->surfaceFormatFor(surface->requestedFormat()), surface);
}
QPlatformFontDatabase *QEglFSIntegration::fontDatabase() const
@@ -201,4 +214,29 @@ void *QEglFSIntegration::nativeResourceForContext(const QByteArray &resource, QO
return 0;
}
+EGLConfig QEglFSIntegration::chooseConfig(EGLDisplay display, const QSurfaceFormat &format)
+{
+ class Chooser : public QEglConfigChooser {
+ public:
+ Chooser(EGLDisplay display, QEglFSHooks *hooks)
+ : QEglConfigChooser(display)
+ , m_hooks(hooks)
+ {
+ }
+
+ protected:
+ bool filterConfig(EGLConfig config) const
+ {
+ return m_hooks->filterConfig(display(), config) && QEglConfigChooser::filterConfig(config);
+ }
+
+ private:
+ QEglFSHooks *m_hooks;
+ };
+
+ Chooser chooser(display, QEglFSHooks::hooks());
+ chooser.setSurfaceFormat(format);
+ return chooser.chooseConfig();
+}
+
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/eglfs/qeglfsintegration.h b/src/plugins/platforms/eglfs/qeglfsintegration.h
index 42b132b73a..bf044d6919 100644
--- a/src/plugins/platforms/eglfs/qeglfsintegration.h
+++ b/src/plugins/platforms/eglfs/qeglfsintegration.h
@@ -48,8 +48,6 @@
#include <qpa/qplatformnativeinterface.h>
#include <qpa/qplatformscreen.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QEglFSIntegration : public QPlatformIntegration, public QPlatformNativeInterface
@@ -63,6 +61,7 @@ public:
QPlatformWindow *createPlatformWindow(QWindow *window) const;
QPlatformBackingStore *createPlatformBackingStore(QWindow *window) const;
QPlatformOpenGLContext *createPlatformOpenGLContext(QOpenGLContext *context) const;
+ QPlatformOffscreenSurface *createPlatformOffscreenSurface(QOffscreenSurface *surface) const;
QPlatformNativeInterface *nativeInterface() const;
QPlatformFontDatabase *fontDatabase() const;
@@ -75,14 +74,21 @@ public:
void *nativeResourceForIntegration(const QByteArray &resource);
void *nativeResourceForContext(const QByteArray &resource, QOpenGLContext *context);
+ QPlatformScreen *screen() const { return mScreen; }
+ static EGLConfig chooseConfig(EGLDisplay display, const QSurfaceFormat &format);
+
+ EGLDisplay display() const { return mDisplay; }
+
+ QPlatformInputContext *inputContext() const { return mInputContext; }
+
private:
EGLDisplay mDisplay;
QAbstractEventDispatcher *mEventDispatcher;
QPlatformFontDatabase *mFontDb;
QPlatformScreen *mScreen;
+ QPlatformInputContext *mInputContext;
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QEGLFSINTEGRATION_H
diff --git a/src/plugins/platforms/eglfs/qeglfsscreen.cpp b/src/plugins/platforms/eglfs/qeglfsscreen.cpp
index 1bc1e944de..e104bd7f2b 100644
--- a/src/plugins/platforms/eglfs/qeglfsscreen.cpp
+++ b/src/plugins/platforms/eglfs/qeglfsscreen.cpp
@@ -56,7 +56,7 @@ QEglFSScreen::QEglFSScreen(EGLDisplay dpy)
static int hideCursor = qgetenv("QT_QPA_EGLFS_HIDECURSOR").toInt();
if (!hideCursor) {
- if (QEglFSCursor *customCursor = hooks->createCursor(this))
+ if (QEglFSCursor *customCursor = QEglFSHooks::hooks()->createCursor(this))
m_cursor = customCursor;
else
m_cursor = new QEglFSCursor(this);
@@ -70,19 +70,30 @@ QEglFSScreen::~QEglFSScreen()
QRect QEglFSScreen::geometry() const
{
- return QRect(QPoint(0, 0), hooks->screenSize());
+ return QRect(QPoint(0, 0), QEglFSHooks::hooks()->screenSize());
}
int QEglFSScreen::depth() const
{
- return hooks->screenDepth();
+ return QEglFSHooks::hooks()->screenDepth();
}
QImage::Format QEglFSScreen::format() const
{
- return hooks->screenFormat();
+ return QEglFSHooks::hooks()->screenFormat();
}
+QSizeF QEglFSScreen::physicalSize() const
+{
+ return QEglFSHooks::hooks()->physicalScreenSize();
+}
+
+QDpi QEglFSScreen::logicalDpi() const
+{
+ return QEglFSHooks::hooks()->logicalDpi();
+}
+
+
QPlatformCursor *QEglFSScreen::cursor() const
{
return m_cursor;
diff --git a/src/plugins/platforms/eglfs/qeglfsscreen.h b/src/plugins/platforms/eglfs/qeglfsscreen.h
index 309791d6c2..298a67cd3a 100644
--- a/src/plugins/platforms/eglfs/qeglfsscreen.h
+++ b/src/plugins/platforms/eglfs/qeglfsscreen.h
@@ -63,6 +63,9 @@ public:
int depth() const;
QImage::Format format() const;
+ QSizeF physicalSize() const;
+ QDpi logicalDpi() const;
+
QPlatformCursor *cursor() const;
EGLDisplay display() const { return m_dpy; }
diff --git a/src/plugins/platforms/eglfs/qeglfswindow.cpp b/src/plugins/platforms/eglfs/qeglfswindow.cpp
index ceb04901c4..68cef6253e 100644
--- a/src/plugins/platforms/eglfs/qeglfswindow.cpp
+++ b/src/plugins/platforms/eglfs/qeglfswindow.cpp
@@ -76,18 +76,36 @@ void QEglFSWindow::create()
return;
if (window()->type() == Qt::Desktop) {
- QRect rect(QPoint(), hooks->screenSize());
+ QRect rect(QPoint(), QEglFSHooks::hooks()->screenSize());
QPlatformWindow::setGeometry(rect);
QWindowSystemInterface::handleGeometryChange(window(), rect);
return;
}
EGLDisplay display = (static_cast<QEglFSScreen *>(window()->screen()->handle()))->display();
- QSurfaceFormat platformFormat = hooks->surfaceFormatFor(window()->requestedFormat());
- EGLConfig config = q_configFromGLFormat(display, platformFormat);
- m_format = q_glFormatFromConfig(display, config);
- m_window = hooks->createNativeWindow(hooks->screenSize(), m_format);
- m_surface = eglCreateWindowSurface(display, config, m_window, NULL);
+ QSurfaceFormat platformFormat = QEglFSHooks::hooks()->surfaceFormatFor(window()->requestedFormat());
+ m_config = QEglFSIntegration::chooseConfig(display, platformFormat);
+ m_format = q_glFormatFromConfig(display, m_config);
+ resetSurface();
+}
+
+void QEglFSWindow::invalidateSurface()
+{
+ // Native surface has been deleted behind our backs
+ m_window = 0;
+ if (m_surface != 0) {
+ EGLDisplay display = (static_cast<QEglFSScreen *>(window()->screen()->handle()))->display();
+ eglDestroySurface(display, m_surface);
+ m_surface = 0;
+ }
+}
+
+void QEglFSWindow::resetSurface()
+{
+ EGLDisplay display = static_cast<QEglFSScreen *>(screen())->display();
+
+ m_window = QEglFSHooks::hooks()->createNativeWindow(QEglFSHooks::hooks()->screenSize(), m_format);
+ m_surface = eglCreateWindowSurface(display, m_config, m_window, NULL);
if (m_surface == EGL_NO_SURFACE) {
EGLint error = eglGetError();
eglTerminate(display);
@@ -98,13 +116,13 @@ void QEglFSWindow::create()
void QEglFSWindow::destroy()
{
if (m_surface) {
- EGLDisplay display = (static_cast<QEglFSScreen *>(window()->screen()->handle()))->display();
+ EGLDisplay display = static_cast<QEglFSScreen *>(screen())->display();
eglDestroySurface(display, m_surface);
m_surface = 0;
}
if (m_window) {
- hooks->destroyNativeWindow(m_window);
+ QEglFSHooks::hooks()->destroyNativeWindow(m_window);
m_window = 0;
}
}
@@ -113,9 +131,8 @@ void QEglFSWindow::setGeometry(const QRect &)
{
// We only support full-screen windows
QRect rect(screen()->availableGeometry());
- QWindowSystemInterface::handleGeometryChange(window(), rect);
-
QPlatformWindow::setGeometry(rect);
+ QWindowSystemInterface::handleGeometryChange(window(), rect);
}
void QEglFSWindow::setWindowState(Qt::WindowState)
diff --git a/src/plugins/platforms/eglfs/qeglfswindow.h b/src/plugins/platforms/eglfs/qeglfswindow.h
index 706bbddd22..a351b4a6f4 100644
--- a/src/plugins/platforms/eglfs/qeglfswindow.h
+++ b/src/plugins/platforms/eglfs/qeglfswindow.h
@@ -65,10 +65,14 @@ public:
void create();
void destroy();
+ virtual void invalidateSurface();
+ virtual void resetSurface();
+
private:
WId m_winid;
EGLSurface m_surface;
EGLNativeWindowType m_window;
+ EGLConfig m_config;
QSurfaceFormat m_format;
};
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/ios/ios.json b/src/plugins/platforms/ios/ios.json
new file mode 100644
index 0000000000..f0b766dae1
--- /dev/null
+++ b/src/plugins/platforms/ios/ios.json
@@ -0,0 +1,3 @@
+{
+ "Keys": [ "ios" ]
+}
diff --git a/src/plugins/platforms/ios/ios.pro b/src/plugins/platforms/ios/ios.pro
new file mode 100644
index 0000000000..842ff17f1c
--- /dev/null
+++ b/src/plugins/platforms/ios/ios.pro
@@ -0,0 +1,3 @@
+TEMPLATE = subdirs
+
+SUBDIRS += plugin.pro qtmain.pro
diff --git a/src/plugins/platforms/ios/plugin.mm b/src/plugins/platforms/ios/plugin.mm
new file mode 100644
index 0000000000..a93b6037ad
--- /dev/null
+++ b/src/plugins/platforms/ios/plugin.mm
@@ -0,0 +1,69 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <qpa/qplatformintegrationplugin.h>
+#include <qpa/qplatformthemeplugin.h>
+#include "qiosintegration.h"
+
+QT_BEGIN_NAMESPACE
+
+class QIOSIntegrationPlugin : public QPlatformIntegrationPlugin
+{
+ Q_OBJECT
+ Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.1" FILE "ios.json")
+ public:
+ QPlatformIntegration *create(const QString&, const QStringList&);
+};
+
+QPlatformIntegration * QIOSIntegrationPlugin::create(const QString& system, const QStringList& paramList)
+{
+ Q_UNUSED(paramList);
+ if (system.toLower() == "ios")
+ return new QIOSIntegration;
+
+ return 0;
+}
+
+QT_END_NAMESPACE
+
+#include "plugin.moc"
+
+Q_IMPORT_PLUGIN(QIOSIntegrationPlugin)
diff --git a/src/plugins/platforms/ios/plugin.pro b/src/plugins/platforms/ios/plugin.pro
new file mode 100644
index 0000000000..591a0a67ed
--- /dev/null
+++ b/src/plugins/platforms/ios/plugin.pro
@@ -0,0 +1,36 @@
+TARGET = qios
+
+PLUGIN_TYPE = platforms
+load(qt_plugin)
+
+QT += core-private gui-private platformsupport-private
+LIBS += -framework UIKit -framework QuartzCore
+
+OBJECTIVE_SOURCES = \
+ plugin.mm \
+ qiosintegration.mm \
+ qioswindow.mm \
+ qiosscreen.mm \
+ qioseventdispatcher.mm \
+ qiosbackingstore.mm \
+ qiosapplicationdelegate.mm \
+ qiosviewcontroller.mm \
+ qioscontext.mm \
+ qiosinputcontext.mm \
+ qiostheme.mm \
+ qiosglobal.mm
+
+HEADERS = \
+ qiosintegration.h \
+ qioswindow.h \
+ qiosscreen.h \
+ qioseventdispatcher.h \
+ qiosbackingstore.h \
+ qiosapplicationdelegate.h \
+ qiosviewcontroller.h \
+ qioscontext.h \
+ qiosinputcontext.h \
+ qiostheme.h \
+ qiosglobal.h
+
+#HEADERS = qiossoftwareinputhandler.h
diff --git a/mkspecs/unsupported/macx-iosdevice-g++-legacy/qplatformdefs.h b/src/plugins/platforms/ios/qiosapplicationdelegate.h
index 5f80a17860..442b37f1b3 100644
--- a/mkspecs/unsupported/macx-iosdevice-g++-legacy/qplatformdefs.h
+++ b/src/plugins/platforms/ios/qiosapplicationdelegate.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the qmake spec of the Qt Toolkit.
+** This file is part of the plugins of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -39,4 +39,15 @@
**
****************************************************************************/
-#include "../../common/ios/qplatformdefs.h"
+#import <UIKit/UIKit.h>
+#import <QtGui/QtGui>
+
+@interface QIOSApplicationDelegate : UIResponder <UIApplicationDelegate>
+
+@property (strong, nonatomic) UIWindow *window;
+
+@end
+
+@interface QIOSMainWrapperApplicationDelegate : QIOSApplicationDelegate
+@end
+
diff --git a/src/plugins/platforms/ios/qiosapplicationdelegate.mm b/src/plugins/platforms/ios/qiosapplicationdelegate.mm
new file mode 100644
index 0000000000..41a3fff84f
--- /dev/null
+++ b/src/plugins/platforms/ios/qiosapplicationdelegate.mm
@@ -0,0 +1,94 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#import "qiosapplicationdelegate.h"
+#include "qioswindow.h"
+#include <QtCore/QtCore>
+
+@implementation QIOSApplicationDelegate
+
+@synthesize window;
+
+- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
+{
+ Q_UNUSED(application)
+ Q_UNUSED(launchOptions)
+
+ return YES;
+}
+
+- (void)applicationWillResignActive:(UIApplication *)application
+{
+ Q_UNUSED(application)
+}
+
+- (void)applicationDidEnterBackground:(UIApplication *)application
+{
+ Q_UNUSED(application)
+}
+
+- (void)applicationWillEnterForeground:(UIApplication *)application
+{
+ Q_UNUSED(application)
+ // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
+}
+
+- (void)applicationDidBecomeActive:(UIApplication *)application
+{
+ Q_UNUSED(application)
+ // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
+}
+
+- (void)applicationWillTerminate:(UIApplication *)application
+{
+ Q_UNUSED(application)
+ // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
+}
+
+- (void)dealloc
+{
+ [window release];
+ [super dealloc];
+}
+
+@end
+
+
diff --git a/src/plugins/platforms/ios/qiosbackingstore.h b/src/plugins/platforms/ios/qiosbackingstore.h
new file mode 100644
index 0000000000..c110f0e4d1
--- /dev/null
+++ b/src/plugins/platforms/ios/qiosbackingstore.h
@@ -0,0 +1,70 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QIOSBACKINGSTORE_H
+#define QIOSBACKINGSTORE_H
+
+#include <qpa/qplatformbackingstore.h>
+
+QT_BEGIN_NAMESPACE
+
+class QIOSBackingStore : public QPlatformBackingStore
+{
+public:
+ QIOSBackingStore(QWindow *window);
+ ~QIOSBackingStore();
+
+ QPaintDevice *paintDevice();
+
+ void beginPaint(const QRegion &);
+ void endPaint();
+
+ void flush(QWindow *window, const QRegion &region, const QPoint &offset);
+ void resize(const QSize &size, const QRegion &staticContents);
+
+private:
+ QOpenGLContext *m_context;
+ QPaintDevice *m_device;
+};
+
+QT_END_NAMESPACE
+
+#endif // QIOSBACKINGSTORE_H
diff --git a/src/plugins/platforms/ios/qiosbackingstore.mm b/src/plugins/platforms/ios/qiosbackingstore.mm
new file mode 100644
index 0000000000..566ff3a672
--- /dev/null
+++ b/src/plugins/platforms/ios/qiosbackingstore.mm
@@ -0,0 +1,125 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qiosbackingstore.h"
+#include "qioswindow.h"
+
+#include <QtGui/QOpenGLContext>
+#include <QtGui/QOpenGLPaintDevice>
+
+#include <QtDebug>
+
+QIOSBackingStore::QIOSBackingStore(QWindow *window)
+ : QPlatformBackingStore(window)
+ , m_context(new QOpenGLContext)
+ , m_device(0)
+{
+ m_context->setFormat(window->requestedFormat());
+ m_context->setScreen(window->screen());
+ m_context->create();
+}
+
+QIOSBackingStore::~QIOSBackingStore()
+{
+ delete m_context;
+ delete m_device;
+}
+
+void QIOSBackingStore::beginPaint(const QRegion &)
+{
+ // Needed to prevent QOpenGLContext::makeCurrent() from failing
+ window()->setSurfaceType(QSurface::OpenGLSurface);
+
+ m_context->makeCurrent(window());
+
+ static_cast<QOpenGLPaintDevice *>(paintDevice())->setSize(window()->size());
+ QIOSWindow *iosWindow = static_cast<QIOSWindow *>(window()->handle());
+ static_cast<QOpenGLPaintDevice *>(paintDevice())->setSize(window()->size() * iosWindow->devicePixelRatio());
+}
+
+QPaintDevice *QIOSBackingStore::paintDevice()
+{
+ if (!m_device) {
+ QIOSWindow *iosWindow = static_cast<QIOSWindow *>(window()->handle());
+ QOpenGLPaintDevice *openGLDevice = new QOpenGLPaintDevice(window()->size() * iosWindow->devicePixelRatio());
+ openGLDevice->setDevicePixelRatio(iosWindow->devicePixelRatio());
+ m_device = openGLDevice;
+ }
+
+ return m_device;
+}
+
+void QIOSBackingStore::flush(QWindow *window, const QRegion &region, const QPoint &offset)
+{
+ Q_UNUSED(region);
+ Q_UNUSED(offset);
+
+ if (window != this->window()) {
+ // We skip flushing raster-based child windows, to avoid the extra cost of copying from the
+ // parent FBO into the child FBO. Since the child is already drawn inside the parent FBO, it
+ // will become visible when flushing the parent. The only case we end up not supporting is if
+ // the child window overlaps a sibling window that's draws using a separate QOpenGLContext.
+ return;
+ }
+ m_context->swapBuffers(window);
+}
+
+void QIOSBackingStore::endPaint()
+{
+ // Calling makeDone() on the context here would be an option,
+ // but is not needed, and would actually add some overhead.
+}
+
+void QIOSBackingStore::resize(const QSize &size, const QRegion &staticContents)
+{
+ Q_UNUSED(staticContents);
+
+ // Resizing the backing store would in our case mean resizing the QWindow,
+ // as we cheat and use an QOpenGLPaintDevice that we target at the window.
+ // That's probably not what the user intended, so we ignore resizes of the
+ // backing store and always keep the paint device's size in sync with the
+ // window size in beginPaint().
+
+ if (size != window()->size())
+ qWarning() << "QIOSBackingStore needs to have the same size as its window";
+}
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/ios/qioscontext.h b/src/plugins/platforms/ios/qioscontext.h
new file mode 100644
index 0000000000..082ec4794c
--- /dev/null
+++ b/src/plugins/platforms/ios/qioscontext.h
@@ -0,0 +1,91 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QIOSCONTEXT_H
+#define QIOSCONTEXT_H
+
+#include <qpa/qplatformopenglcontext.h>
+
+@class EAGLContext;
+
+QT_BEGIN_NAMESPACE
+
+class QIOSContext : public QObject, public QPlatformOpenGLContext
+{
+ Q_OBJECT
+
+public:
+ QIOSContext(QOpenGLContext *context);
+ ~QIOSContext();
+
+ QSurfaceFormat format() const;
+
+ void swapBuffers(QPlatformSurface *surface);
+
+ bool makeCurrent(QPlatformSurface *surface);
+ void doneCurrent();
+
+ GLuint defaultFramebufferObject(QPlatformSurface *) const;
+ QFunctionPointer getProcAddress(const QByteArray &procName);
+
+private Q_SLOTS:
+ void windowDestroyed(QObject *object);
+
+private:
+ EAGLContext *m_eaglContext;
+ QSurfaceFormat m_format;
+
+ struct FramebufferObject {
+ GLuint handle;
+ GLuint colorRenderbuffer;
+ GLuint depthRenderbuffer;
+ GLint renderbufferWidth;
+ GLint renderbufferHeight;
+ };
+
+ static void deleteBuffers(const FramebufferObject &framebufferObject);
+
+ mutable QHash<QWindow *, FramebufferObject> m_framebufferObjects;
+};
+
+QT_END_NAMESPACE
+
+#endif // QIOSCONTEXT_H
diff --git a/src/plugins/platforms/ios/qioscontext.mm b/src/plugins/platforms/ios/qioscontext.mm
new file mode 100644
index 0000000000..e2a6113010
--- /dev/null
+++ b/src/plugins/platforms/ios/qioscontext.mm
@@ -0,0 +1,204 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qioscontext.h"
+#include "qioswindow.h"
+
+#include <dlfcn.h>
+
+#include <QtGui/QOpenGLContext>
+
+#import <OpenGLES/EAGL.h>
+#import <QuartzCore/CAEAGLLayer.h>
+
+QIOSContext::QIOSContext(QOpenGLContext *context)
+ : QPlatformOpenGLContext()
+ , m_eaglContext([[EAGLContext alloc] initWithAPI:kEAGLRenderingAPIOpenGLES2])
+{
+ // Start out with the requested format
+ QSurfaceFormat format = context->format();
+
+ format.setRenderableType(QSurfaceFormat::OpenGLES);
+ format.setMajorVersion(2);
+ format.setMinorVersion(0);
+
+ // Even though iOS internally double-buffers its rendering, we
+ // report single-buffered here since the buffer remains unchanged
+ // when swapping unlesss you manually clear it yourself.
+ format.setSwapBehavior(QSurfaceFormat::SingleBuffer);
+
+ m_format = format;
+}
+
+QIOSContext::~QIOSContext()
+{
+ [EAGLContext setCurrentContext:m_eaglContext];
+
+ foreach (const FramebufferObject &framebufferObject, m_framebufferObjects)
+ deleteBuffers(framebufferObject);
+
+ [EAGLContext setCurrentContext:nil];
+ [m_eaglContext release];
+}
+
+void QIOSContext::deleteBuffers(const FramebufferObject &framebufferObject)
+{
+ if (framebufferObject.handle)
+ glDeleteFramebuffers(1, &framebufferObject.handle);
+ if (framebufferObject.colorRenderbuffer)
+ glDeleteRenderbuffers(1, &framebufferObject.colorRenderbuffer);
+ if (framebufferObject.depthRenderbuffer)
+ glDeleteRenderbuffers(1, &framebufferObject.depthRenderbuffer);
+}
+
+QSurfaceFormat QIOSContext::format() const
+{
+ return m_format;
+}
+
+bool QIOSContext::makeCurrent(QPlatformSurface *surface)
+{
+ Q_ASSERT(surface && surface->surface()->surfaceType() == QSurface::OpenGLSurface);
+
+ [EAGLContext setCurrentContext:m_eaglContext];
+ glBindFramebuffer(GL_FRAMEBUFFER, defaultFramebufferObject(surface));
+
+ return true;
+}
+
+void QIOSContext::doneCurrent()
+{
+ [EAGLContext setCurrentContext:nil];
+}
+
+void QIOSContext::swapBuffers(QPlatformSurface *surface)
+{
+ Q_ASSERT(surface && surface->surface()->surfaceType() == QSurface::OpenGLSurface);
+ Q_ASSERT(surface->surface()->surfaceClass() == QSurface::Window);
+ QWindow *window = static_cast<QWindow *>(surface->surface());
+ Q_ASSERT(m_framebufferObjects.contains(window));
+
+ [EAGLContext setCurrentContext:m_eaglContext];
+ glBindRenderbuffer(GL_RENDERBUFFER, m_framebufferObjects[window].colorRenderbuffer);
+ [m_eaglContext presentRenderbuffer:GL_RENDERBUFFER];
+}
+
+GLuint QIOSContext::defaultFramebufferObject(QPlatformSurface *surface) const
+{
+ Q_ASSERT(surface && surface->surface()->surfaceClass() == QSurface::Window);
+ QWindow *window = static_cast<QWindow *>(surface->surface());
+
+ FramebufferObject &framebufferObject = m_framebufferObjects[window];
+
+ // Set up an FBO for the window if it hasn't been created yet
+ if (!framebufferObject.handle) {
+ [EAGLContext setCurrentContext:m_eaglContext];
+
+ glGenFramebuffers(1, &framebufferObject.handle);
+ glBindFramebuffer(GL_FRAMEBUFFER, framebufferObject.handle);
+
+ glGenRenderbuffers(1, &framebufferObject.colorRenderbuffer);
+ glBindRenderbuffer(GL_RENDERBUFFER, framebufferObject.colorRenderbuffer);
+ glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_RENDERBUFFER,
+ framebufferObject.colorRenderbuffer);
+
+ if (m_format.depthBufferSize() > 0 || m_format.stencilBufferSize() > 0) {
+ glGenRenderbuffers(1, &framebufferObject.depthRenderbuffer);
+ glBindRenderbuffer(GL_RENDERBUFFER, framebufferObject.depthRenderbuffer);
+ glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_RENDERBUFFER,
+ framebufferObject.depthRenderbuffer);
+
+ if (m_format.stencilBufferSize() > 0)
+ glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT, GL_RENDERBUFFER,
+ framebufferObject.depthRenderbuffer);
+ }
+
+ connect(window, SIGNAL(destroyed(QObject*)), this, SLOT(windowDestroyed(QObject*)));
+ }
+
+ // Ensure that the FBO's buffers match the size of the window
+ QIOSWindow *platformWindow = static_cast<QIOSWindow *>(surface);
+ if (framebufferObject.renderbufferWidth != platformWindow->effectiveWidth() ||
+ framebufferObject.renderbufferHeight != platformWindow->effectiveHeight()) {
+
+ glBindRenderbuffer(GL_RENDERBUFFER, framebufferObject.colorRenderbuffer);
+ UIView *view = reinterpret_cast<UIView *>(platformWindow->winId());
+ CAEAGLLayer *layer = static_cast<CAEAGLLayer *>(view.layer);
+ [m_eaglContext renderbufferStorage:GL_RENDERBUFFER fromDrawable:layer];
+
+ glGetRenderbufferParameteriv(GL_RENDERBUFFER, GL_RENDERBUFFER_WIDTH, &framebufferObject.renderbufferWidth);
+ glGetRenderbufferParameteriv(GL_RENDERBUFFER, GL_RENDERBUFFER_HEIGHT, &framebufferObject.renderbufferHeight);
+
+ if (framebufferObject.depthRenderbuffer) {
+ glBindRenderbuffer(GL_RENDERBUFFER, framebufferObject.depthRenderbuffer);
+
+ // FIXME: Support more fine grained control over depth/stencil buffer sizes
+ if (m_format.stencilBufferSize() > 0)
+ glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH24_STENCIL8_OES,
+ framebufferObject.renderbufferWidth, framebufferObject.renderbufferHeight);
+ else
+ glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH_COMPONENT16,
+ framebufferObject.renderbufferWidth, framebufferObject.renderbufferHeight);
+ }
+
+ if (glCheckFramebufferStatus(GL_FRAMEBUFFER) != GL_FRAMEBUFFER_COMPLETE)
+ NSLog(@"Failed to make complete framebuffer object %x", glCheckFramebufferStatus(GL_FRAMEBUFFER));
+ }
+
+ return framebufferObject.handle;
+}
+
+void QIOSContext::windowDestroyed(QObject *object)
+{
+ QWindow *window = static_cast<QWindow *>(object);
+ if (m_framebufferObjects.contains(window)) {
+ deleteBuffers(m_framebufferObjects[window]);
+ m_framebufferObjects.remove(window);
+ }
+}
+
+QFunctionPointer QIOSContext::getProcAddress(const QByteArray& functionName)
+{
+ return reinterpret_cast<QFunctionPointer>(dlsym(RTLD_NEXT, functionName.constData()));
+}
+
+#include "moc_qioscontext.cpp"
+
diff --git a/src/plugins/platforms/ios/qioseventdispatcher.h b/src/plugins/platforms/ios/qioseventdispatcher.h
new file mode 100644
index 0000000000..53a75618ce
--- /dev/null
+++ b/src/plugins/platforms/ios/qioseventdispatcher.h
@@ -0,0 +1,133 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+/****************************************************************************
+**
+** Copyright (c) 2007-2008, Apple, 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 Apple, 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.
+**
+****************************************************************************/
+
+#ifndef QEVENTDISPATCHER_IOS_P_H
+#define QEVENTDISPATCHER_IOS_P_H
+
+#include <QtCore/qabstracteventdispatcher.h>
+#include <QtCore/private/qtimerinfo_unix_p.h>
+#include <QtPlatformSupport/private/qcfsocketnotifier_p.h>
+#include <CoreFoundation/CoreFoundation.h>
+
+QT_BEGIN_NAMESPACE
+
+class QIOSEventDispatcher : public QAbstractEventDispatcher
+{
+ Q_OBJECT
+
+public:
+ explicit QIOSEventDispatcher(QObject *parent = 0);
+ ~QIOSEventDispatcher();
+
+ bool processEvents(QEventLoop::ProcessEventsFlags flags);
+ bool hasPendingEvents();
+
+ void registerSocketNotifier(QSocketNotifier *notifier);
+ void unregisterSocketNotifier(QSocketNotifier *notifier);
+
+ void registerTimer(int timerId, int interval, Qt::TimerType timerType, QObject *object);
+ bool unregisterTimer(int timerId);
+ bool unregisterTimers(QObject *object);
+ QList<QAbstractEventDispatcher::TimerInfo> registeredTimers(QObject *object) const;
+
+ int remainingTime(int timerId);
+
+ void wakeUp();
+ void interrupt();
+ void flush();
+
+private:
+ bool m_interrupted;
+
+ CFRunLoopSourceRef m_postedEventsRunLoopSource;
+ CFRunLoopSourceRef m_blockingTimerRunLoopSource;
+
+ QTimerInfoList m_timerInfoList;
+ CFRunLoopTimerRef m_runLoopTimerRef;
+
+ QCFSocketNotifier m_cfSocketNotifier;
+
+ void processPostedEvents();
+ void maybeStartCFRunLoopTimer();
+ void maybeStopCFRunLoopTimer();
+
+ static void postedEventsRunLoopCallback(void *info);
+ static void nonBlockingTimerRunLoopCallback(CFRunLoopTimerRef, void *info);
+ static void blockingTimerRunLoopCallback(void *info);
+};
+
+QT_END_NAMESPACE
+
+#endif // QEVENTDISPATCHER_IOS_P_H
diff --git a/src/plugins/platforms/ios/qioseventdispatcher.mm b/src/plugins/platforms/ios/qioseventdispatcher.mm
new file mode 100644
index 0000000000..e9bf039047
--- /dev/null
+++ b/src/plugins/platforms/ios/qioseventdispatcher.mm
@@ -0,0 +1,322 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qioseventdispatcher.h"
+#import "qiosapplicationdelegate.h"
+#include <qdebug.h>
+#include <qpa/qwindowsysteminterface.h>
+#include <QtCore/QThread>
+#include <QtCore/private/qcoreapplication_p.h>
+#include <UIKit/UIApplication.h>
+
+QT_BEGIN_NAMESPACE
+QT_USE_NAMESPACE
+
+static Boolean runLoopSourceEqualCallback(const void *info1, const void *info2)
+{
+ return info1 == info2;
+}
+
+void QIOSEventDispatcher::postedEventsRunLoopCallback(void *info)
+{
+ QIOSEventDispatcher *self = static_cast<QIOSEventDispatcher *>(info);
+ self->processPostedEvents();
+}
+
+void QIOSEventDispatcher::nonBlockingTimerRunLoopCallback(CFRunLoopTimerRef, void *info)
+{
+ // The (one and only) CFRunLoopTimer has fired, which means that at least
+ // one QTimer should now fire as well. Note that CFRunLoopTimer's callback will
+ // never recurse. So if the app starts a new QEventLoop within this callback, other
+ // timers will stop working. The work-around is to forward the callback to a
+ // dedicated CFRunLoopSource that can recurse:
+ QIOSEventDispatcher *self = static_cast<QIOSEventDispatcher *>(info);
+ CFRunLoopSourceSignal(self->m_blockingTimerRunLoopSource);
+}
+
+void QIOSEventDispatcher::blockingTimerRunLoopCallback(void *info)
+{
+ // TODO:
+ // We also need to block this new timer source
+ // along with the posted event source when calling processEvents()
+ // "manually" to prevent livelock deep in CFRunLoop.
+
+ QIOSEventDispatcher *self = static_cast<QIOSEventDispatcher *>(info);
+ self->m_timerInfoList.activateTimers();
+ self->maybeStartCFRunLoopTimer();
+}
+
+void QIOSEventDispatcher::maybeStartCFRunLoopTimer()
+{
+ // Find out when the next registered timer should fire, and schedule
+ // runLoopTimer accordingly. If the runLoopTimer does not yet exist, and
+ // at least one timer is registered, start by creating the timer:
+ if (m_timerInfoList.isEmpty()) {
+ Q_ASSERT(m_runLoopTimerRef == 0);
+ return;
+ }
+
+ CFAbsoluteTime ttf = CFAbsoluteTimeGetCurrent();
+ CFTimeInterval interval;
+
+ if (m_runLoopTimerRef == 0) {
+ // start the CFRunLoopTimer
+ CFTimeInterval oneyear = CFTimeInterval(3600. * 24. * 365.);
+
+ // calculate when the next timer should fire:
+ struct timespec tv;
+ if (m_timerInfoList.timerWait(tv)) {
+ interval = qMax(tv.tv_sec + tv.tv_nsec / 1000000000., 0.0000001);
+ } else {
+ // this shouldn't really happen, but in case it does, set the timer
+ // to fire a some point in the distant future:
+ interval = oneyear;
+ }
+
+ ttf += interval;
+ CFRunLoopTimerContext info = { 0, this, 0, 0, 0 };
+ // create the timer with a large interval, as recommended by the CFRunLoopTimerSetNextFireDate()
+ // documentation, since we will adjust the timer's time-to-fire as needed to keep Qt timers working
+ m_runLoopTimerRef = CFRunLoopTimerCreate(0, ttf, oneyear, 0, 0, QIOSEventDispatcher::nonBlockingTimerRunLoopCallback, &info);
+ Q_ASSERT(m_runLoopTimerRef != 0);
+
+ CFRunLoopAddTimer(CFRunLoopGetMain(), m_runLoopTimerRef, kCFRunLoopCommonModes);
+ } else {
+ struct timespec tv;
+ // Calculate when the next timer should fire:
+ if (m_timerInfoList.timerWait(tv)) {
+ interval = qMax(tv.tv_sec + tv.tv_nsec / 1000000000., 0.0000001);
+ } else {
+ // no timers can fire, but we cannot stop the CFRunLoopTimer, set the timer to fire at some
+ // point in the distant future (the timer interval is one year)
+ interval = CFRunLoopTimerGetInterval(m_runLoopTimerRef);
+ }
+
+ ttf += interval;
+ CFRunLoopTimerSetNextFireDate(m_runLoopTimerRef, ttf);
+ }
+}
+
+void QIOSEventDispatcher::maybeStopCFRunLoopTimer()
+{
+ if (m_runLoopTimerRef == 0)
+ return;
+
+ CFRunLoopTimerInvalidate(m_runLoopTimerRef);
+ CFRelease(m_runLoopTimerRef);
+ m_runLoopTimerRef = 0;
+}
+
+void QIOSEventDispatcher::processPostedEvents()
+{
+ QWindowSystemInterface::sendWindowSystemEvents(QEventLoop::AllEvents);
+}
+
+QIOSEventDispatcher::QIOSEventDispatcher(QObject *parent)
+ : QAbstractEventDispatcher(parent)
+ , m_interrupted(false)
+ , m_runLoopTimerRef(0)
+{
+ m_cfSocketNotifier.setHostEventDispatcher(this);
+
+ CFRunLoopRef mainRunLoop = CFRunLoopGetMain();
+ CFRunLoopSourceContext context;
+ bzero(&context, sizeof(CFRunLoopSourceContext));
+ context.equal = runLoopSourceEqualCallback;
+ context.info = this;
+
+ // source used to handle timers:
+ context.perform = QIOSEventDispatcher::blockingTimerRunLoopCallback;
+ m_blockingTimerRunLoopSource = CFRunLoopSourceCreate(kCFAllocatorDefault, 0, &context);
+ Q_ASSERT(m_blockingTimerRunLoopSource);
+ CFRunLoopAddSource(mainRunLoop, m_blockingTimerRunLoopSource, kCFRunLoopCommonModes);
+
+ // source used to handle posted events:
+ context.perform = QIOSEventDispatcher::postedEventsRunLoopCallback;
+ m_postedEventsRunLoopSource = CFRunLoopSourceCreate(kCFAllocatorDefault, 0, &context);
+ Q_ASSERT(m_postedEventsRunLoopSource);
+ CFRunLoopAddSource(mainRunLoop, m_postedEventsRunLoopSource, kCFRunLoopCommonModes);
+}
+
+QIOSEventDispatcher::~QIOSEventDispatcher()
+{
+ CFRunLoopRef mainRunLoop = CFRunLoopGetMain();
+ CFRunLoopRemoveSource(mainRunLoop, m_postedEventsRunLoopSource, kCFRunLoopCommonModes);
+ CFRelease(m_postedEventsRunLoopSource);
+
+ qDeleteAll(m_timerInfoList);
+ maybeStopCFRunLoopTimer();
+ CFRunLoopRemoveSource(CFRunLoopGetMain(), m_blockingTimerRunLoopSource, kCFRunLoopCommonModes);
+ CFRelease(m_blockingTimerRunLoopSource);
+
+ m_cfSocketNotifier.removeSocketNotifiers();
+}
+
+bool QIOSEventDispatcher::processEvents(QEventLoop::ProcessEventsFlags flags)
+{
+ m_interrupted = false;
+ bool eventsProcessed = false;
+
+ bool excludeUserEvents = flags & QEventLoop::ExcludeUserInputEvents;
+ bool execFlagSet = (flags & QEventLoop::DialogExec) || (flags & QEventLoop::EventLoopExec);
+ bool useExecMode = execFlagSet && !excludeUserEvents;
+
+ if (useExecMode) {
+ NSRunLoop *runLoop = [NSRunLoop currentRunLoop];
+ while ([runLoop runMode:NSDefaultRunLoopMode beforeDate:[NSDate distantFuture]] && !m_interrupted);
+ eventsProcessed = true;
+ } else {
+ if (!(flags & QEventLoop::WaitForMoreEvents))
+ wakeUp();
+ eventsProcessed = [[NSRunLoop currentRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate distantFuture]];
+ }
+ return eventsProcessed;
+}
+
+bool QIOSEventDispatcher::hasPendingEvents()
+{
+ qDebug() << __FUNCTION__ << "not implemented";
+ return false;
+}
+
+void QIOSEventDispatcher::registerSocketNotifier(QSocketNotifier *notifier)
+{
+ m_cfSocketNotifier.registerSocketNotifier(notifier);
+}
+
+void QIOSEventDispatcher::unregisterSocketNotifier(QSocketNotifier *notifier)
+{
+ m_cfSocketNotifier.unregisterSocketNotifier(notifier);
+}
+
+void QIOSEventDispatcher::registerTimer(int timerId, int interval, Qt::TimerType timerType, QObject *obj)
+{
+#ifndef QT_NO_DEBUG
+ if (timerId < 1 || interval < 0 || !obj) {
+ qWarning("QIOSEventDispatcher::registerTimer: invalid arguments");
+ return;
+ } else if (obj->thread() != thread() || thread() != QThread::currentThread()) {
+ qWarning("QIOSEventDispatcher: timers cannot be started from another thread");
+ return;
+ }
+#endif
+
+ m_timerInfoList.registerTimer(timerId, interval, timerType, obj);
+ maybeStartCFRunLoopTimer();
+}
+
+bool QIOSEventDispatcher::unregisterTimer(int timerId)
+{
+#ifndef QT_NO_DEBUG
+ if (timerId < 1) {
+ qWarning("QIOSEventDispatcher::unregisterTimer: invalid argument");
+ return false;
+ } else if (thread() != QThread::currentThread()) {
+ qWarning("QObject::killTimer: timers cannot be stopped from another thread");
+ return false;
+ }
+#endif
+
+ bool returnValue = m_timerInfoList.unregisterTimer(timerId);
+ m_timerInfoList.isEmpty() ? maybeStopCFRunLoopTimer() : maybeStartCFRunLoopTimer();
+ return returnValue;
+}
+
+bool QIOSEventDispatcher::unregisterTimers(QObject *object)
+{
+#ifndef QT_NO_DEBUG
+ if (!object) {
+ qWarning("QIOSEventDispatcher::unregisterTimers: invalid argument");
+ return false;
+ } else if (object->thread() != thread() || thread() != QThread::currentThread()) {
+ qWarning("QObject::killTimers: timers cannot be stopped from another thread");
+ return false;
+ }
+#endif
+
+ bool returnValue = m_timerInfoList.unregisterTimers(object);
+ m_timerInfoList.isEmpty() ? maybeStopCFRunLoopTimer() : maybeStartCFRunLoopTimer();
+ return returnValue;
+}
+
+QList<QAbstractEventDispatcher::TimerInfo> QIOSEventDispatcher::registeredTimers(QObject *object) const
+{
+#ifndef QT_NO_DEBUG
+ if (!object) {
+ qWarning("QIOSEventDispatcher:registeredTimers: invalid argument");
+ return QList<TimerInfo>();
+ }
+#endif
+
+ return m_timerInfoList.registeredTimers(object);
+}
+
+int QIOSEventDispatcher::remainingTime(int timerId)
+{
+#ifndef QT_NO_DEBUG
+ if (timerId < 1) {
+ qWarning("QIOSEventDispatcher::remainingTime: invalid argument");
+ return -1;
+ }
+#endif
+
+ return m_timerInfoList.timerRemainingTime(timerId);
+}
+
+void QIOSEventDispatcher::wakeUp()
+{
+ CFRunLoopSourceSignal(m_postedEventsRunLoopSource);
+ CFRunLoopWakeUp(CFRunLoopGetMain());
+}
+
+void QIOSEventDispatcher::interrupt()
+{
+ wakeUp();
+ m_interrupted = true;
+}
+
+void QIOSEventDispatcher::flush()
+{
+ // X11 only.
+}
+
+QT_END_NAMESPACE
+
diff --git a/src/plugins/platforms/ios/qiosglobal.h b/src/plugins/platforms/ios/qiosglobal.h
new file mode 100644
index 0000000000..3be9f8bb21
--- /dev/null
+++ b/src/plugins/platforms/ios/qiosglobal.h
@@ -0,0 +1,67 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QIOSGLOBAL_H
+#define QIOSGLOBAL_H
+
+#import <UIKit/UIKit.h>
+#include <QtCore/QtCore>
+
+@class QIOSViewController;
+
+QT_BEGIN_NAMESPACE
+
+class QPlatformScreen;
+
+bool isQtApplication();
+QIOSViewController *rootViewController();
+
+CGRect toCGRect(const QRect &rect);
+QRect fromCGRect(const CGRect &rect);
+CGPoint toCGPoint(const QPoint &point);
+QPoint fromCGPoint(const CGPoint &point);
+Qt::ScreenOrientation toQtScreenOrientation(UIDeviceOrientation uiDeviceOrientation);
+UIDeviceOrientation fromQtScreenOrientation(Qt::ScreenOrientation qtOrientation);
+QRect fromPortraitToPrimary(const QRect &rect, QPlatformScreen *screen);
+
+QT_END_NAMESPACE
+
+#endif // QIOSGLOBAL_H
diff --git a/src/plugins/platforms/ios/qiosglobal.mm b/src/plugins/platforms/ios/qiosglobal.mm
new file mode 100644
index 0000000000..5860078372
--- /dev/null
+++ b/src/plugins/platforms/ios/qiosglobal.mm
@@ -0,0 +1,144 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qiosglobal.h"
+#include "qiosapplicationdelegate.h"
+#include "qiosviewcontroller.h"
+#include "qiosscreen.h"
+
+QT_BEGIN_NAMESPACE
+
+bool isQtApplication()
+{
+ // Returns true if the plugin is in full control of the whole application. This means
+ // that we control the application delegate and the top view controller, and can take
+ // actions that impacts all parts of the application. The opposite means that we are
+ // embedded inside a native iOS application, and should be more focused on playing along
+ // with native UIControls, and less inclined to change structures that lies outside the
+ // scope of our QWindows/UIViews.
+ static bool isQt = ([[UIApplication sharedApplication].delegate isKindOfClass:[QIOSApplicationDelegate class]]);
+ return isQt;
+}
+
+QIOSViewController *rootViewController()
+{
+ static QIOSViewController *c = isQtApplication() ?
+ static_cast<QIOSViewController *>([UIApplication sharedApplication].delegate.window.rootViewController) : nil;
+ return c;
+}
+
+CGRect toCGRect(const QRect &rect)
+{
+ return CGRectMake(rect.x(), rect.y(), rect.width(), rect.height());
+}
+
+QRect fromCGRect(const CGRect &rect)
+{
+ return QRect(rect.origin.x, rect.origin.y, rect.size.width, rect.size.height);
+}
+
+CGPoint toCGPoint(const QPoint &point)
+{
+ return CGPointMake(point.x(), point.y());
+}
+
+QPoint fromCGPoint(const CGPoint &point)
+{
+ return QPoint(point.x, point.y);
+}
+
+Qt::ScreenOrientation toQtScreenOrientation(UIDeviceOrientation uiDeviceOrientation)
+{
+ Qt::ScreenOrientation qtOrientation;
+ switch (uiDeviceOrientation) {
+ case UIDeviceOrientationPortraitUpsideDown:
+ qtOrientation = Qt::InvertedPortraitOrientation;
+ break;
+ case UIDeviceOrientationLandscapeLeft:
+ qtOrientation = Qt::InvertedLandscapeOrientation;
+ break;
+ case UIDeviceOrientationLandscapeRight:
+ qtOrientation = Qt::LandscapeOrientation;
+ break;
+ case UIDeviceOrientationFaceUp:
+ case UIDeviceOrientationFaceDown:
+ qtOrientation = static_cast<Qt::ScreenOrientation>(-1); // not supported ATM.
+ break;
+ default:
+ qtOrientation = Qt::PortraitOrientation;
+ break;
+ }
+ return qtOrientation;
+}
+
+UIDeviceOrientation fromQtScreenOrientation(Qt::ScreenOrientation qtOrientation)
+{
+ UIDeviceOrientation uiOrientation;
+ switch (qtOrientation) {
+ case Qt::LandscapeOrientation:
+ uiOrientation = UIDeviceOrientationLandscapeRight;
+ break;
+ case Qt::InvertedLandscapeOrientation:
+ uiOrientation = UIDeviceOrientationLandscapeLeft;
+ break;
+ case Qt::InvertedPortraitOrientation:
+ uiOrientation = UIDeviceOrientationPortraitUpsideDown;
+ break;
+ case Qt::PrimaryOrientation:
+ case Qt::PortraitOrientation:
+ default:
+ uiOrientation = UIDeviceOrientationPortrait;
+ break;
+ }
+ return uiOrientation;
+}
+
+QRect fromPortraitToPrimary(const QRect &rect, QPlatformScreen *screen)
+{
+ // UIScreen is always in portrait. Use this function to convert CGRects
+ // aligned with UIScreen into whatever is the current orientation of QScreen.
+ QRect geometry = screen->geometry();
+ return geometry.width() < geometry.height() ? rect
+ : QRect(rect.y(), geometry.width() - rect.width() - rect.x(), rect.height(), rect.width());
+}
+
+QT_END_NAMESPACE
+
diff --git a/src/plugins/platforms/ios/qiosinputcontext.h b/src/plugins/platforms/ios/qiosinputcontext.h
new file mode 100644
index 0000000000..176ad05733
--- /dev/null
+++ b/src/plugins/platforms/ios/qiosinputcontext.h
@@ -0,0 +1,73 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QIOSINPUTCONTEXT_H
+#define QIOSINPUTCONTEXT_H
+
+#include <UIKit/UIKit.h>
+
+#include <qpa/qplatforminputcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+@class QIOSKeyboardListener;
+
+class QIOSInputContext : public QPlatformInputContext
+{
+public:
+ QIOSInputContext();
+ ~QIOSInputContext();
+
+ QRectF keyboardRect() const;
+ void showInputPanel();
+ void hideInputPanel();
+ bool isInputPanelVisible() const;
+
+ void focusViewChanged(UIView *view);
+
+private:
+ QIOSKeyboardListener *m_keyboardListener;
+ UIView *m_focusView;
+};
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/plugins/platforms/ios/qiosinputcontext.mm b/src/plugins/platforms/ios/qiosinputcontext.mm
new file mode 100644
index 0000000000..1d3ab12de9
--- /dev/null
+++ b/src/plugins/platforms/ios/qiosinputcontext.mm
@@ -0,0 +1,142 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qiosglobal.h"
+#include "qiosinputcontext.h"
+#include "qioswindow.h"
+#include <QGuiApplication>
+
+@interface QIOSKeyboardListener : NSObject {
+@public
+ QIOSInputContext *m_context;
+ BOOL m_keyboardVisible;
+ QRectF m_keyboardRect;
+}
+@end
+
+@implementation QIOSKeyboardListener
+
+- (id)initWithQIOSInputContext:(QIOSInputContext *)context
+{
+ self = [super init];
+ if (self) {
+ m_context = context;
+ m_keyboardVisible = NO;
+ // After the keyboard became undockable (iOS5), UIKeyboardWillShow/UIKeyboardWillHide
+ // no longer works for all cases. So listen to keyboard frame changes instead:
+ [[NSNotificationCenter defaultCenter]
+ addObserver:self
+ selector:@selector(keyboardDidChangeFrame:)
+ name:@"UIKeyboardDidChangeFrameNotification" object:nil];
+ }
+ return self;
+}
+
+- (void) dealloc
+{
+ [[NSNotificationCenter defaultCenter]
+ removeObserver:self
+ name:@"UIKeyboardDidChangeFrameNotification" object:nil];
+ [super dealloc];
+}
+
+- (void) keyboardDidChangeFrame:(NSNotification *)notification
+{
+ CGRect frame;
+ [[[notification userInfo] objectForKey:UIKeyboardFrameEndUserInfoKey] getValue:&frame];
+
+ m_keyboardRect = fromPortraitToPrimary(fromCGRect(frame), QGuiApplication::primaryScreen()->handle());
+ m_context->emitKeyboardRectChanged();
+
+ BOOL visible = CGRectIntersectsRect(frame, [UIScreen mainScreen].bounds);
+ if (m_keyboardVisible != visible) {
+ m_keyboardVisible = visible;
+ m_context->emitInputPanelVisibleChanged();
+ }
+}
+
+@end
+
+QIOSInputContext::QIOSInputContext()
+ : QPlatformInputContext()
+ , m_keyboardListener([[QIOSKeyboardListener alloc] initWithQIOSInputContext:this])
+ , m_focusView(0)
+{
+}
+
+QIOSInputContext::~QIOSInputContext()
+{
+ [m_keyboardListener release];
+ [m_focusView release];
+}
+
+QRectF QIOSInputContext::keyboardRect() const
+{
+ return m_keyboardListener->m_keyboardRect;
+}
+
+void QIOSInputContext::showInputPanel()
+{
+ // Documentation tells that one should call (and recall, if necessary) becomeFirstResponder/resignFirstResponder
+ // to show/hide the keyboard. This is slightly inconvenient, since there exist no API to get the current first
+ // responder. Rather than searching for it from the top, we let the active QIOSWindow tell us which view to use.
+ // Note that Qt will forward keyevents to whichever QObject that needs it, regardless of which UIView the input
+ // actually came from. So in this respect, we're undermining iOS' responder chain.
+ [m_focusView becomeFirstResponder];
+}
+
+void QIOSInputContext::hideInputPanel()
+{
+ [m_focusView resignFirstResponder];
+}
+
+bool QIOSInputContext::isInputPanelVisible() const
+{
+ return m_keyboardListener->m_keyboardVisible;
+}
+
+void QIOSInputContext::focusViewChanged(UIView *view)
+{
+ if ([m_focusView isFirstResponder])
+ [view becomeFirstResponder];
+ [m_focusView release];
+ m_focusView = [view retain];
+}
diff --git a/src/plugins/platforms/ios/qiosintegration.h b/src/plugins/platforms/ios/qiosintegration.h
new file mode 100644
index 0000000000..329a0a3d9b
--- /dev/null
+++ b/src/plugins/platforms/ios/qiosintegration.h
@@ -0,0 +1,88 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QPLATFORMINTEGRATION_UIKIT_H
+#define QPLATFORMINTEGRATION_UIKIT_H
+
+#include <qpa/qplatformintegration.h>
+#include <qpa/qplatformnativeinterface.h>
+#include <qpa/qwindowsysteminterface.h>
+
+QT_BEGIN_NAMESPACE
+
+class QIOSIntegration : public QPlatformIntegration, public QPlatformNativeInterface
+{
+public:
+ QIOSIntegration();
+ ~QIOSIntegration();
+
+ bool hasCapability(Capability cap) const;
+
+ QPlatformWindow *createPlatformWindow(QWindow *window) const;
+ QPlatformBackingStore *createPlatformBackingStore(QWindow *window) const;
+
+ QPlatformOpenGLContext *createPlatformOpenGLContext(QOpenGLContext *context) const;
+
+ QPlatformFontDatabase *fontDatabase() const;
+ QPlatformInputContext *inputContext() const;
+
+ QVariant styleHint(StyleHint hint) const;
+
+ QStringList themeNames() const;
+ QPlatformTheme *createPlatformTheme(const QString &name) const;
+
+ QAbstractEventDispatcher *guiThreadEventDispatcher() const;
+ QPlatformNativeInterface *nativeInterface() const;
+
+ void *nativeResourceForWindow(const QByteArray &resource, QWindow *window);
+
+ QTouchDevice *touchDevice();
+private:
+ QPlatformFontDatabase *m_fontDatabase;
+ QPlatformInputContext *m_inputContext;
+ QPlatformScreen *m_screen;
+ QTouchDevice *m_touchDevice;
+};
+
+QT_END_NAMESPACE
+
+#endif
+
diff --git a/src/plugins/platforms/ios/qiosintegration.mm b/src/plugins/platforms/ios/qiosintegration.mm
new file mode 100644
index 0000000000..c7541c3e38
--- /dev/null
+++ b/src/plugins/platforms/ios/qiosintegration.mm
@@ -0,0 +1,180 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qiosintegration.h"
+#include "qioswindow.h"
+#include "qiosbackingstore.h"
+#include "qiosscreen.h"
+#include "qioseventdispatcher.h"
+#include "qioscontext.h"
+#include "qiosinputcontext.h"
+#include "qiostheme.h"
+
+#include <QtPlatformSupport/private/qcoretextfontdatabase_p.h>
+
+#include <QtDebug>
+
+QT_BEGIN_NAMESPACE
+
+QIOSIntegration::QIOSIntegration()
+ : m_fontDatabase(new QCoreTextFontDatabase)
+ , m_inputContext(new QIOSInputContext)
+ , m_screen(new QIOSScreen(QIOSScreen::MainScreen))
+{
+ if (![UIApplication sharedApplication]) {
+ qWarning()
+ << "Error: You are creating QApplication before calling UIApplicationMain.\n"
+ << "If you are writing a native iOS application, and only want to use Qt for\n"
+ << "parts of the application, a good place to create QApplication is from within\n"
+ << "'applicationDidFinishLaunching' inside your UIApplication delegate.\n"
+ << "If you instead create a cross-platform Qt application and do not intend to call\n"
+ << "UIApplicationMain, you need to link in libqtmain.a, and substitute main with qt_main.\n"
+ << "This is normally done automatically by qmake.\n";
+ exit(-1);
+ }
+
+ screenAdded(m_screen);
+
+ m_touchDevice = new QTouchDevice;
+ m_touchDevice->setType(QTouchDevice::TouchScreen);
+ m_touchDevice->setCapabilities(QTouchDevice::Position | QTouchDevice::NormalizedPosition);
+ QWindowSystemInterface::registerTouchDevice(m_touchDevice);
+}
+
+QIOSIntegration::~QIOSIntegration()
+{
+ delete m_touchDevice;
+}
+
+bool QIOSIntegration::hasCapability(Capability cap) const
+{
+ switch (cap) {
+ case OpenGL:
+ return true;
+ case MultipleWindows:
+ return true;
+ default:
+ return QPlatformIntegration::hasCapability(cap);
+ }
+}
+
+QPlatformWindow *QIOSIntegration::createPlatformWindow(QWindow *window) const
+{
+ return new QIOSWindow(window);
+}
+
+// Used when the QWindow's surface type is set by the client to QSurface::RasterSurface
+QPlatformBackingStore *QIOSIntegration::createPlatformBackingStore(QWindow *window) const
+{
+ return new QIOSBackingStore(window);
+}
+
+// Used when the QWindow's surface type is set by the client to QSurface::OpenGLSurface
+QPlatformOpenGLContext *QIOSIntegration::createPlatformOpenGLContext(QOpenGLContext *context) const
+{
+ Q_UNUSED(context);
+ return new QIOSContext(context);
+}
+
+QAbstractEventDispatcher *QIOSIntegration::guiThreadEventDispatcher() const
+{
+ return new QIOSEventDispatcher();
+}
+
+QPlatformFontDatabase * QIOSIntegration::fontDatabase() const
+{
+ return m_fontDatabase;
+}
+
+QPlatformInputContext *QIOSIntegration::inputContext() const
+{
+ return m_inputContext;
+}
+
+QVariant QIOSIntegration::styleHint(StyleHint hint) const
+{
+ switch (hint) {
+ case ShowIsFullScreen:
+ return true;
+ default:
+ return QPlatformIntegration::styleHint(hint);
+ }
+}
+
+QStringList QIOSIntegration::themeNames() const
+{
+ return QStringList(QLatin1String(QIOSTheme::name));
+}
+
+QPlatformTheme *QIOSIntegration::createPlatformTheme(const QString &name) const
+{
+ if (name == QLatin1String(QIOSTheme::name))
+ return new QIOSTheme;
+
+ return QPlatformIntegration::createPlatformTheme(name);
+}
+
+QPlatformNativeInterface *QIOSIntegration::nativeInterface() const
+{
+ return const_cast<QIOSIntegration *>(this);
+}
+
+void *QIOSIntegration::nativeResourceForWindow(const QByteArray &resource, QWindow *window)
+{
+ if (!window || !window->handle())
+ return 0;
+
+ QByteArray lowerCaseResource = resource.toLower();
+
+ QIOSWindow *platformWindow = static_cast<QIOSWindow *>(window->handle());
+
+ if (lowerCaseResource == "uiview")
+ return reinterpret_cast<void *>(platformWindow->winId());
+
+ return 0;
+}
+
+QTouchDevice *QIOSIntegration::touchDevice()
+{
+ return m_touchDevice;
+}
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/ios/qiosscreen.h b/src/plugins/platforms/ios/qiosscreen.h
new file mode 100644
index 0000000000..40c7a3ccf7
--- /dev/null
+++ b/src/plugins/platforms/ios/qiosscreen.h
@@ -0,0 +1,88 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QIOSSCREEN_H
+#define QIOSSCREEN_H
+
+#include <UIKit/UIKit.h>
+
+#include <qpa/qplatformscreen.h>
+
+@class QIOSOrientationListener;
+
+QT_BEGIN_NAMESPACE
+
+class QIOSScreen : public QPlatformScreen
+{
+public:
+ QIOSScreen(unsigned int screenIndex);
+ ~QIOSScreen();
+
+ enum ScreenIndex { MainScreen = 0 };
+
+ QRect geometry() const;
+ QRect availableGeometry() const;
+ int depth() const;
+ QImage::Format format() const;
+ QSizeF physicalSize() const;
+ QDpi logicalDpi() const;
+ qreal devicePixelRatio() const;
+
+ Qt::ScreenOrientation nativeOrientation() const;
+ Qt::ScreenOrientation orientation() const;
+ void setOrientationUpdateMask(Qt::ScreenOrientations mask);
+
+ UIScreen *uiScreen() const;
+
+ void setPrimaryOrientation(Qt::ScreenOrientation orientation);
+
+private:
+ UIScreen *m_uiScreen;
+ QRect m_geometry;
+ QRect m_availableGeometry;
+ int m_depth;
+ QSizeF m_physicalSize;
+ QIOSOrientationListener *m_orientationListener;
+};
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/plugins/platforms/ios/qiosscreen.mm b/src/plugins/platforms/ios/qiosscreen.mm
new file mode 100644
index 0000000000..d86ed5f090
--- /dev/null
+++ b/src/plugins/platforms/ios/qiosscreen.mm
@@ -0,0 +1,238 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qiosglobal.h"
+#include "qiosscreen.h"
+#include "qioswindow.h"
+#include <qpa/qwindowsysteminterface.h>
+#include "qiosapplicationdelegate.h"
+#include "qiosviewcontroller.h"
+
+#include <sys/sysctl.h>
+
+@interface QIOSOrientationListener : NSObject {
+ @public
+ QIOSScreen *m_screen;
+}
+- (id) initWithQIOSScreen:(QIOSScreen *)screen;
+@end
+
+@implementation QIOSOrientationListener
+
+- (id) initWithQIOSScreen:(QIOSScreen *)screen
+{
+ self = [super init];
+ if (self) {
+ m_screen = screen;
+ [[UIDevice currentDevice] beginGeneratingDeviceOrientationNotifications];
+ [[NSNotificationCenter defaultCenter]
+ addObserver:self
+ selector:@selector(orientationChanged:)
+ name:@"UIDeviceOrientationDidChangeNotification" object:nil];
+ }
+ return self;
+}
+
+- (void) dealloc
+{
+ [[UIDevice currentDevice] endGeneratingDeviceOrientationNotifications];
+ [[NSNotificationCenter defaultCenter]
+ removeObserver:self
+ name:@"UIDeviceOrientationDidChangeNotification" object:nil];
+ [super dealloc];
+}
+
+- (void) orientationChanged:(NSNotification *)notification
+{
+ Q_UNUSED(notification);
+ Qt::ScreenOrientation orientation = toQtScreenOrientation([UIDevice currentDevice].orientation);
+ if (orientation != -1)
+ QWindowSystemInterface::handleScreenOrientationChange(m_screen->screen(), orientation);
+}
+
+@end
+
+/*!
+ Returns the model identifier of the device.
+
+ When running under the simulator, the identifier will not
+ match the simulated device, but will be x86_64 or i386.
+*/
+static QString deviceModelIdentifier()
+{
+ static const char key[] = "hw.machine";
+
+ size_t size;
+ sysctlbyname(key, NULL, &size, NULL, 0);
+
+ char value[size];
+ sysctlbyname(key, &value, &size, NULL, 0);
+
+ return QString::fromLatin1(value);
+}
+
+QIOSScreen::QIOSScreen(unsigned int screenIndex)
+ : QPlatformScreen()
+ , m_uiScreen([[UIScreen screens] objectAtIndex:qMin(screenIndex, [[UIScreen screens] count] - 1)])
+ , m_orientationListener(0)
+{
+ NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
+
+ QString deviceIdentifier = deviceModelIdentifier();
+
+ if (deviceIdentifier == QStringLiteral("iPhone2,1") /* iPhone 3GS */
+ || deviceIdentifier == QStringLiteral("iPod3,1") /* iPod touch 3G */) {
+ m_depth = 18;
+ } else {
+ m_depth = 24;
+ }
+
+ int unscaledDpi = 163; // Regular iPhone DPI
+ if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPad
+ && deviceIdentifier != QStringLiteral("iPad2,5") /* iPad Mini */) {
+ unscaledDpi = 132;
+ };
+
+ CGRect bounds = [m_uiScreen bounds];
+ m_geometry = QRect(bounds.origin.x, bounds.origin.y, bounds.size.width, bounds.size.height);
+
+ CGRect frame = m_uiScreen.applicationFrame;
+ m_availableGeometry = QRect(frame.origin.x, frame.origin.y, frame.size.width, frame.size.height);
+
+ const qreal millimetersPerInch = 25.4;
+ m_physicalSize = QSizeF(m_geometry.size()) / unscaledDpi * millimetersPerInch;
+
+ if (isQtApplication()) {
+ // When in a non-mixed environment, let QScreen follow the current interface orientation:
+ setPrimaryOrientation(toQtScreenOrientation(UIDeviceOrientation(rootViewController().interfaceOrientation)));
+ }
+
+ [pool release];
+}
+
+QIOSScreen::~QIOSScreen()
+{
+ [m_orientationListener release];
+}
+
+QRect QIOSScreen::geometry() const
+{
+ return m_geometry;
+}
+
+QRect QIOSScreen::availableGeometry() const
+{
+ return m_availableGeometry;
+}
+
+int QIOSScreen::depth() const
+{
+ return m_depth;
+}
+
+QImage::Format QIOSScreen::format() const
+{
+ return QImage::Format_ARGB32_Premultiplied;
+}
+
+QSizeF QIOSScreen::physicalSize() const
+{
+ return m_physicalSize;
+}
+
+QDpi QIOSScreen::logicalDpi() const
+{
+ return QDpi(72, 72);
+}
+
+qreal QIOSScreen::devicePixelRatio() const
+{
+ return [m_uiScreen scale];
+}
+
+Qt::ScreenOrientation QIOSScreen::nativeOrientation() const
+{
+ return Qt::PortraitOrientation;
+}
+
+Qt::ScreenOrientation QIOSScreen::orientation() const
+{
+ return toQtScreenOrientation([UIDevice currentDevice].orientation);
+}
+
+void QIOSScreen::setOrientationUpdateMask(Qt::ScreenOrientations mask)
+{
+ if (m_orientationListener && mask == Qt::PrimaryOrientation) {
+ [m_orientationListener release];
+ m_orientationListener = 0;
+ } else if (!m_orientationListener) {
+ m_orientationListener = [[QIOSOrientationListener alloc] initWithQIOSScreen:this];
+ }
+}
+
+void QIOSScreen::setPrimaryOrientation(Qt::ScreenOrientation orientation)
+{
+ // Note that UIScreen never changes orientation, but QScreen should. To work around
+ // this, we let QIOSViewController call us whenever interface orientation changes, and
+ // use that as primary orientation. After all, the viewcontrollers geometry is what we
+ // place QWindows on top of. A problem with this approach is that QIOSViewController is
+ // not in use in a mixed environment, which results in no change to primary orientation.
+ // We see that as acceptable since Qt should most likely not interfere with orientation
+ // for that case anyway.
+ bool portrait = screen()->isPortrait(orientation);
+ if (portrait && m_geometry.width() < m_geometry.height())
+ return;
+
+ // Switching portrait/landscape means swapping width/height (and adjusting x/y):
+ m_geometry = QRect(0, 0, m_geometry.height(), m_geometry.width());
+ m_physicalSize = QSizeF(m_physicalSize.height(), m_physicalSize.width());
+ m_availableGeometry = fromPortraitToPrimary(fromCGRect(m_uiScreen.applicationFrame), this);
+
+ QWindowSystemInterface::handleScreenGeometryChange(screen(), m_geometry);
+ QWindowSystemInterface::handleScreenAvailableGeometryChange(screen(), m_availableGeometry);
+}
+
+UIScreen *QIOSScreen::uiScreen() const
+{
+ return m_uiScreen;
+}
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/ios/qiossoftwareinputhandler.h b/src/plugins/platforms/ios/qiossoftwareinputhandler.h
new file mode 100644
index 0000000000..5dad6b8d86
--- /dev/null
+++ b/src/plugins/platforms/ios/qiossoftwareinputhandler.h
@@ -0,0 +1,71 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QIOSSOFTWAREINPUTHANDLER_H
+#define QIOSSOFTWAREINPUTHANDLER_H
+
+#include <QtCore/QObject>
+#include <QtCore/QPointer>
+#include <QtWidgets/QWidget>
+
+QT_BEGIN_NAMESPACE
+
+class QIOSSoftwareInputHandler : public QObject
+{
+ Q_OBJECT
+
+public:
+ QIOSSoftwareInputHandler() : m_CurrentFocusWidget(0), m_CurrentFocusObject(0) {}
+ bool eventFilter(QObject *obj, QEvent *event);
+
+private slots:
+ void activeFocusChanged(bool focus);
+
+private:
+ bool closeSoftwareInputPanel(QWidget *widget);
+
+ QPointer<QWidget> m_currentFocusWidget;
+ QPointer<QObject> m_currentFocusObject;
+};
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/plugins/platforms/ios/qiostheme.h b/src/plugins/platforms/ios/qiostheme.h
new file mode 100644
index 0000000000..b03f65f556
--- /dev/null
+++ b/src/plugins/platforms/ios/qiostheme.h
@@ -0,0 +1,68 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QIOSTHEME_H
+#define QIOSTHEME_H
+
+#include <QtCore/QHash>
+#include <qpa/qplatformtheme.h>
+
+QT_BEGIN_NAMESPACE
+
+class QIOSTheme : public QPlatformTheme
+{
+public:
+ QIOSTheme();
+ ~QIOSTheme();
+
+ QVariant themeHint(ThemeHint hint) const;
+
+ const QFont *font(Font type = SystemFont) const;
+
+ static const char *name;
+
+private:
+ mutable QHash<QPlatformTheme::Font, QFont *> m_fonts;
+};
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/plugins/platforms/ios/qiostheme.mm b/src/plugins/platforms/ios/qiostheme.mm
new file mode 100644
index 0000000000..e7093185aa
--- /dev/null
+++ b/src/plugins/platforms/ios/qiostheme.mm
@@ -0,0 +1,96 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qiostheme.h"
+
+#include <QtCore/QStringList>
+#include <QtCore/QVariant>
+
+#include <QtGui/QFont>
+
+#include <UIKit/UIFont.h>
+#include <UIKit/UIInterface.h>
+
+QT_BEGIN_NAMESPACE
+
+const char *QIOSTheme::name = "ios";
+
+QIOSTheme::QIOSTheme()
+{
+}
+
+QIOSTheme::~QIOSTheme()
+{
+ qDeleteAll(m_fonts);
+}
+
+QVariant QIOSTheme::themeHint(ThemeHint hint) const
+{
+ switch (hint) {
+ case QPlatformTheme::StyleNames:
+ return QStringList(QStringLiteral("fusion"));
+ default:
+ return QPlatformTheme::themeHint(hint);
+ }
+}
+
+const QFont *QIOSTheme::font(Font type) const
+{
+ if (m_fonts.isEmpty()) {
+ // The real system font on iOS is '.Helvetica Neue UI', as returned by both [UIFont systemFontOfSize]
+ // and CTFontCreateUIFontForLanguage(kCTFontSystemFontType, ...), but this font is not included when
+ // populating the available fonts in QCoreTextFontDatabase::populateFontDatabase(), since the font
+ // is internal to iOS and not supposed to be used by applications. We could potentially add this
+ // font to the font-database, but it would then show up when enumerating user fonts from Qt
+ // applications since we don't have a flag in Qt to mark a font as a private system font.
+ // For now we hard-code the font to Helvetica, which should be very close to the actual
+ // system font.
+ QLatin1String systemFontFamilyName("Helvetica");
+ m_fonts.insert(QPlatformTheme::SystemFont, new QFont(systemFontFamilyName, [UIFont systemFontSize]));
+ m_fonts.insert(QPlatformTheme::SmallFont, new QFont(systemFontFamilyName, [UIFont smallSystemFontSize]));
+ m_fonts.insert(QPlatformTheme::LabelFont, new QFont(systemFontFamilyName, [UIFont labelFontSize]));
+ m_fonts.insert(QPlatformTheme::PushButtonFont, new QFont(systemFontFamilyName, [UIFont buttonFontSize]));
+ }
+
+ return m_fonts.value(type, 0);
+}
+
+QT_END_NAMESPACE
diff --git a/mkspecs/common/ios/GLES/gl.h b/src/plugins/platforms/ios/qiosviewcontroller.h
index 2b94b162eb..d5a61cb3f4 100644
--- a/mkspecs/common/ios/GLES/gl.h
+++ b/src/plugins/platforms/ios/qiosviewcontroller.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the qmake spec of the Qt Toolkit.
+** This file is part of the plugins of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -39,5 +39,8 @@
**
****************************************************************************/
-#include <OpenGLES/ES1/gl.h>
-#include <OpenGLES/ES1/glext.h>
+#import <UIKit/UIKit.h>
+
+@interface QIOSViewController : UIViewController
+@end
+
diff --git a/src/plugins/platforms/ios/qiosviewcontroller.mm b/src/plugins/platforms/ios/qiosviewcontroller.mm
new file mode 100644
index 0000000000..404b213966
--- /dev/null
+++ b/src/plugins/platforms/ios/qiosviewcontroller.mm
@@ -0,0 +1,90 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#import "qiosviewcontroller.h"
+
+#include <QtGui/QGuiApplication>
+#include <QtGui/QScreen>
+#include "qiosscreen.h"
+#include "qiosglobal.h"
+
+@implementation QIOSViewController
+
+- (void)viewDidLoad
+{
+#ifdef QT_DEBUG
+ if (!self.nibName)
+ self.view.backgroundColor = [UIColor magentaColor];
+#endif
+}
+
+-(BOOL)shouldAutorotate
+{
+ // For now we assume that if the application doesn't listen to orientation
+ // updates it means it would like to enable auto-rotation, and vice versa.
+ if (QGuiApplication *guiApp = qobject_cast<QGuiApplication *>(qApp))
+ return !guiApp->primaryScreen()->orientationUpdateMask();
+ else
+ return YES; // Startup case: QGuiApplication is not ready yet.
+
+ // FIXME: Investigate a proper Qt API for auto-rotation and orientation locking
+}
+
+-(NSUInteger)supportedInterfaceOrientations
+{
+ // We need to tell iOS that we support all orientations in order to set
+ // status bar orientation when application content orientation changes.
+ return UIInterfaceOrientationMaskAll;
+}
+
+- (void)willRotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation duration:(NSTimeInterval)duration
+{
+ Q_UNUSED(duration);
+ Qt::ScreenOrientation orientation = toQtScreenOrientation(UIDeviceOrientation(toInterfaceOrientation));
+ if (orientation == -1)
+ return;
+
+ QIOSScreen *qiosScreen = static_cast<QIOSScreen *>(QGuiApplication::primaryScreen()->handle());
+ qiosScreen->setPrimaryOrientation(orientation);
+}
+
+@end
+
diff --git a/src/plugins/platforms/ios/qioswindow.h b/src/plugins/platforms/ios/qioswindow.h
new file mode 100644
index 0000000000..cefb6f9388
--- /dev/null
+++ b/src/plugins/platforms/ios/qioswindow.h
@@ -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 plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QIOSWINDOW_H
+#define QIOSWINDOW_H
+
+#include <qpa/qplatformwindow.h>
+#include <qpa/qwindowsysteminterface.h>
+
+#import <UIKit/UIKit.h>
+
+class QIOSContext;
+class QIOSWindow;
+
+@interface UIView (QIOS)
+@property(readonly) QWindow *qwindow;
+@end
+
+QT_BEGIN_NAMESPACE
+
+class QIOSWindow : public QPlatformWindow
+{
+public:
+ explicit QIOSWindow(QWindow *window);
+ ~QIOSWindow();
+
+ void setGeometry(const QRect &rect);
+
+ void setWindowState(Qt::WindowState state);
+ void setParent(const QPlatformWindow *window);
+ void handleContentOrientationChange(Qt::ScreenOrientation orientation);
+ void setVisible(bool visible);
+
+ void raise() { raiseOrLower(true); }
+ void lower() { raiseOrLower(false); }
+ void requestActivateWindow();
+
+ qreal devicePixelRatio() const;
+ int effectiveWidth() const;
+ int effectiveHeight() const;
+
+ WId winId() const { return WId(m_view); };
+
+ QList<QWindowSystemInterface::TouchPoint> &touchPoints() { return m_touchPoints; }
+ QHash<UITouch *, int> &activeTouches() { return m_activeTouches; }
+ int &touchId() { return m_touchId; }
+
+private:
+ UIView *m_view;
+ QList<QWindowSystemInterface::TouchPoint> m_touchPoints;
+ QHash<UITouch *, int> m_activeTouches;
+ int m_touchId;
+
+ QRect m_requestedGeometry;
+ int m_windowLevel;
+ qreal m_devicePixelRatio;
+
+ void raiseOrLower(bool raise);
+ void updateWindowLevel();
+ bool blockedByModal();
+};
+
+QT_END_NAMESPACE
+
+#endif // QIOSWINDOW_H
diff --git a/src/plugins/platforms/ios/qioswindow.mm b/src/plugins/platforms/ios/qioswindow.mm
new file mode 100644
index 0000000000..d7a2fa1a75
--- /dev/null
+++ b/src/plugins/platforms/ios/qioswindow.mm
@@ -0,0 +1,523 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qiosglobal.h"
+#include "qioswindow.h"
+#include "qioscontext.h"
+#include "qiosinputcontext.h"
+#include "qiosscreen.h"
+#include "qiosapplicationdelegate.h"
+#include "qiosviewcontroller.h"
+#include "qiosintegration.h"
+#include <QtGui/private/qguiapplication_p.h>
+#include <qpa/qplatformintegration.h>
+
+#import <QuartzCore/CAEAGLLayer.h>
+
+#include <QtGui/QKeyEvent>
+#include <qpa/qwindowsysteminterface.h>
+
+#include <QtDebug>
+
+@interface EAGLView : UIView <UIKeyInput>
+{
+@public
+ UITextAutocapitalizationType autocapitalizationType;
+ UITextAutocorrectionType autocorrectionType;
+ BOOL enablesReturnKeyAutomatically;
+ UIKeyboardAppearance keyboardAppearance;
+ UIKeyboardType keyboardType;
+ UIReturnKeyType returnKeyType;
+ BOOL secureTextEntry;
+ QIOSWindow *m_qioswindow;
+}
+
+@property(nonatomic) UITextAutocapitalizationType autocapitalizationType;
+@property(nonatomic) UITextAutocorrectionType autocorrectionType;
+@property(nonatomic) BOOL enablesReturnKeyAutomatically;
+@property(nonatomic) UIKeyboardAppearance keyboardAppearance;
+@property(nonatomic) UIKeyboardType keyboardType;
+@property(nonatomic) UIReturnKeyType returnKeyType;
+@property(nonatomic, getter=isSecureTextEntry) BOOL secureTextEntry;
+
+@end
+
+@implementation EAGLView
+
++ (Class)layerClass
+{
+ return [CAEAGLLayer class];
+}
+
+-(id)initWithQIOSWindow:(QIOSWindow *)window
+{
+ if (self = [self initWithFrame:toCGRect(window->geometry())])
+ m_qioswindow = window;
+
+ return self;
+}
+
+- (id)initWithFrame:(CGRect)frame
+{
+ if ((self = [super initWithFrame:frame])) {
+ // Set up EAGL layer
+ CAEAGLLayer *eaglLayer = static_cast<CAEAGLLayer *>(self.layer);
+ eaglLayer.opaque = TRUE;
+ eaglLayer.drawableProperties = [NSDictionary dictionaryWithObjectsAndKeys:
+ [NSNumber numberWithBool:YES], kEAGLDrawablePropertyRetainedBacking,
+ kEAGLColorFormatRGBA8, kEAGLDrawablePropertyColorFormat, nil];
+
+ // Set up text input
+ autocapitalizationType = UITextAutocapitalizationTypeNone;
+ autocorrectionType = UITextAutocorrectionTypeNo;
+ enablesReturnKeyAutomatically = NO;
+ keyboardAppearance = UIKeyboardAppearanceDefault;
+ keyboardType = UIKeyboardTypeDefault;
+ returnKeyType = UIReturnKeyDone;
+ secureTextEntry = NO;
+
+ if (isQtApplication())
+ self.hidden = YES;
+
+ self.multipleTouchEnabled = YES;
+ }
+
+ return self;
+}
+
+- (void)layoutSubviews
+{
+ // This method is the de facto way to know that view has been resized,
+ // or otherwise needs invalidation of its buffers. Note though that we
+ // do not get this callback when the view just changes its position, so
+ // the position of our QWindow (and platform window) will only get updated
+ // when the size is also changed.
+
+ if (!CGAffineTransformIsIdentity(self.transform))
+ qWarning() << m_qioswindow->window()
+ << "is backed by a UIView that has a transform set. This is not supported.";
+
+ QRect geometry = fromCGRect(self.frame);
+ m_qioswindow->QPlatformWindow::setGeometry(geometry);
+ QWindowSystemInterface::handleGeometryChange(m_qioswindow->window(), geometry);
+
+ // If we have a new size here we need to resize the FBO's corresponding buffers,
+ // but we defer that to when the application calls makeCurrent.
+
+ [super layoutSubviews];
+}
+
+/*
+ Touch handling:
+
+ UIKit generates [Began -> Moved -> Ended] event sequences for
+ each touch point. The iOS plugin tracks each individual
+ touch and assigns it an id for use by Qt. The id counter is
+ incremented on each began and decrement as follows:
+ 1) by one when the most recent touch ends.
+ 2) to zero when all touches ends.
+
+ The TouchPoint list is reused between events.
+*/
+- (void)updateTouchList:(NSSet *)touches withState:(Qt::TouchPointState)state
+{
+ QList<QWindowSystemInterface::TouchPoint> &touchPoints = m_qioswindow->touchPoints();
+ QHash<UITouch *, int> &activeTouches = m_qioswindow->activeTouches();
+
+ // Mark all touch points as stationary
+ for (QList<QWindowSystemInterface::TouchPoint>::iterator it = touchPoints.begin(); it != touchPoints.end(); ++it)
+ it->state = Qt::TouchPointStationary;
+
+ // Update changed touch points with the new state
+ for (UITouch *touch in touches) {
+ const int touchId = activeTouches.value(touch);
+ QWindowSystemInterface::TouchPoint &touchPoint = touchPoints[touchId];
+ touchPoint.state = state;
+ if (state == Qt::TouchPointPressed)
+ touchPoint.pressure = 1.0;
+ else if (state == Qt::TouchPointReleased)
+ touchPoint.pressure = 0.0;
+
+ // Set position
+ QRect viewGeometry = fromCGRect(self.frame);
+ QPoint touchViewLocation = fromCGPoint([touch locationInView:self]);
+ QPoint touchScreenLocation = touchViewLocation + viewGeometry.topLeft();
+ touchPoint.area = QRectF(touchScreenLocation , QSize(0, 0));
+
+ CGSize fullscreenSize = self.window.rootViewController.view.bounds.size;
+ touchPoint.normalPosition = QPointF(touchScreenLocation.x() / fullscreenSize.width, touchScreenLocation.y() / fullscreenSize.height);
+ }
+}
+
+- (void) sendTouchEventWithTimestamp:(ulong)timeStamp
+{
+ // Send touch event synchronously
+ QIOSIntegration *iosIntegration = static_cast<QIOSIntegration *>(QGuiApplicationPrivate::platformIntegration());
+ QWindowSystemInterface::handleTouchEvent(m_qioswindow->window(), timeStamp,
+ iosIntegration->touchDevice(), m_qioswindow->touchPoints());
+ QWindowSystemInterface::flushWindowSystemEvents();
+}
+
+- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event
+{
+ QWindow *window = m_qioswindow->window();
+
+ // Transfer focus to the touched window:
+ if (window != QGuiApplication::focusWindow())
+ m_qioswindow->requestActivateWindow();
+
+ // Track Cocoa touch id to Qt touch id. The UITouch pointer is constant
+ // for the touch duration.
+ QHash<UITouch *, int> &activeTouches = m_qioswindow->activeTouches();
+ QList<QWindowSystemInterface::TouchPoint> &touchPoints = m_qioswindow->touchPoints();
+ for (UITouch *touch in touches)
+ activeTouches.insert(touch, m_qioswindow->touchId()++);
+
+ // Create new touch points if needed.
+ int newTouchPointsNeeded = m_qioswindow->touchId() - touchPoints.count();
+ for (int i = 0; i < newTouchPointsNeeded; ++i) {
+ QWindowSystemInterface::TouchPoint touchPoint;
+ touchPoint.id = touchPoints.count(); // id is the index in the touchPoints list.
+ touchPoints.append(touchPoint);
+ }
+
+ [self updateTouchList:touches withState:Qt::TouchPointPressed];
+ [self sendTouchEventWithTimestamp:ulong(event.timestamp * 1000)];
+}
+
+- (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event
+{
+ [self updateTouchList:touches withState:Qt::TouchPointMoved];
+ [self sendTouchEventWithTimestamp:ulong(event.timestamp * 1000)];
+}
+
+- (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event
+{
+ [self updateTouchList:touches withState:Qt::TouchPointReleased];
+ [self sendTouchEventWithTimestamp:ulong(event.timestamp * 1000)];
+
+ // Remove ended touch points from the active set (event processing has completed at this point)
+ QHash<UITouch *, int> &activeTouches = m_qioswindow->activeTouches();
+ for (UITouch *touch in touches) {
+ int id = activeTouches.take(touch);
+
+ // If this touch is the most recent touch we can reuse its id
+ if (id == m_qioswindow->touchId() - 1)
+ --m_qioswindow->touchId();
+ }
+
+ // Reset the touch id when there are no more active touches
+ if (activeTouches.isEmpty())
+ m_qioswindow->touchId() = 0;
+}
+
+- (void)touchesCancelled:(NSSet *)touches withEvent:(UIEvent *)event
+{
+ Q_UNUSED(touches) // ### can a subset of the active touches be cancelled?
+
+ // Clear current touch points
+ m_qioswindow->activeTouches().clear();
+ m_qioswindow->touchId() = 0;
+
+ // Send cancel touch event synchronously
+ QIOSIntegration *iosIntegration = static_cast<QIOSIntegration *>(QGuiApplicationPrivate::platformIntegration());
+ QWindowSystemInterface::handleTouchCancelEvent(m_qioswindow->window(), ulong(event.timestamp * 1000), iosIntegration->touchDevice());
+ QWindowSystemInterface::flushWindowSystemEvents();
+}
+
+@synthesize autocapitalizationType;
+@synthesize autocorrectionType;
+@synthesize enablesReturnKeyAutomatically;
+@synthesize keyboardAppearance;
+@synthesize keyboardType;
+@synthesize returnKeyType;
+@synthesize secureTextEntry;
+
+- (BOOL)canBecomeFirstResponder
+{
+ return YES;
+}
+
+- (BOOL)hasText
+{
+ return YES;
+}
+
+- (void)insertText:(NSString *)text
+{
+ QString string = QString::fromUtf8([text UTF8String]);
+ int key = 0;
+ if ([text isEqualToString:@"\n"])
+ key = (int)Qt::Key_Return;
+
+ // Send key event to window system interface
+ QWindowSystemInterface::handleKeyEvent(
+ 0, QEvent::KeyPress, key, Qt::NoModifier, string, false, int(string.length()));
+ QWindowSystemInterface::handleKeyEvent(
+ 0, QEvent::KeyRelease, key, Qt::NoModifier, string, false, int(string.length()));
+}
+
+- (void)deleteBackward
+{
+ // Send key event to window system interface
+ QWindowSystemInterface::handleKeyEvent(
+ 0, QEvent::KeyPress, (int)Qt::Key_Backspace, Qt::NoModifier);
+ QWindowSystemInterface::handleKeyEvent(
+ 0, QEvent::KeyRelease, (int)Qt::Key_Backspace, Qt::NoModifier);
+}
+
+@end
+
+@implementation UIView (QIOS)
+
+- (QWindow *)qwindow
+{
+ if ([self isKindOfClass:[EAGLView class]])
+ return static_cast<EAGLView *>(self)->m_qioswindow->window();
+ return nil;
+}
+
+@end
+
+QT_BEGIN_NAMESPACE
+
+QIOSWindow::QIOSWindow(QWindow *window)
+ : QPlatformWindow(window)
+ , m_view([[EAGLView alloc] initWithQIOSWindow:this])
+ , m_touchId(0)
+ , m_requestedGeometry(QPlatformWindow::geometry())
+ , m_windowLevel(0)
+ , m_devicePixelRatio(1.0)
+{
+ setParent(parent());
+ setWindowState(window->windowState());
+
+ // Retina support: get screen scale factor and set it in the content view.
+ // This will make framebufferObject() create a 2x frame buffer on retina
+ // displays. Also set m_devicePixelRatio which is used for scaling the
+ // paint device.
+ if ([[UIScreen mainScreen] respondsToSelector:@selector(scale)] == YES) {
+ m_devicePixelRatio = [[UIScreen mainScreen] scale];
+ [m_view setContentScaleFactor: m_devicePixelRatio];
+ }
+}
+
+QIOSWindow::~QIOSWindow()
+{
+ [m_view removeFromSuperview];
+ [m_view release];
+}
+
+bool QIOSWindow::blockedByModal()
+{
+ QWindow *modalWindow = QGuiApplication::modalWindow();
+ return modalWindow && modalWindow != window();
+}
+
+void QIOSWindow::setVisible(bool visible)
+{
+ QPlatformWindow::setVisible(visible);
+ m_view.hidden = !visible;
+
+ if (!isQtApplication())
+ return;
+
+ // Since iOS doesn't do window management the way a Qt application
+ // expects, we need to raise and activate windows ourselves:
+ if (visible)
+ updateWindowLevel();
+
+ if (blockedByModal()) {
+ if (visible)
+ raise();
+ return;
+ }
+
+ if (visible) {
+ requestActivateWindow();
+ } else {
+ // Activate top-most visible QWindow:
+ NSArray *subviews = rootViewController().view.subviews;
+ for (int i = int(subviews.count) - 1; i >= 0; --i) {
+ UIView *view = [subviews objectAtIndex:i];
+ if (!view.hidden) {
+ if (QWindow *window = view.qwindow) {
+ static_cast<QIOSWindow *>(window->handle())->requestActivateWindow();
+ break;
+ }
+ }
+ }
+ }
+}
+
+void QIOSWindow::setGeometry(const QRect &rect)
+{
+ // If the window is in fullscreen, just bookkeep the requested
+ // geometry in case the window goes into Qt::WindowNoState later:
+ m_requestedGeometry = rect;
+ if (window()->windowState() & (Qt::WindowMaximized | Qt::WindowFullScreen))
+ return;
+
+ // Since we don't support transformations on the UIView, we can set the frame
+ // directly and let UIKit deal with translating that into bounds and center.
+ // Changing the size of the view will end up in a call to -[EAGLView layoutSubviews]
+ // which will update QWindowSystemInterface with the new size.
+ m_view.frame = toCGRect(rect);
+}
+
+void QIOSWindow::setWindowState(Qt::WindowState state)
+{
+ // FIXME: Figure out where or how we should disable/enable the statusbar.
+ // Perhaps setting QWindow to maximized should also mean that we'll show
+ // the statusbar, and vice versa for fullscreen?
+
+ switch (state) {
+ case Qt::WindowMaximized:
+ case Qt::WindowFullScreen: {
+ // Since UIScreen does not take orientation into account when
+ // reporting geometry, we need to look at the top view instead:
+ CGSize fullscreenSize = m_view.window.rootViewController.view.bounds.size;
+ m_view.frame = CGRectMake(0, 0, fullscreenSize.width, fullscreenSize.height);
+ m_view.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
+ break; }
+ default:
+ m_view.frame = toCGRect(m_requestedGeometry);
+ m_view.autoresizingMask = UIViewAutoresizingNone;
+ break;
+ }
+}
+
+void QIOSWindow::setParent(const QPlatformWindow *parentWindow)
+{
+ if (parentWindow) {
+ UIView *parentView = reinterpret_cast<UIView *>(parentWindow->winId());
+ [parentView addSubview:m_view];
+ } else if (isQtApplication()) {
+ [rootViewController().view addSubview:m_view];
+ }
+}
+
+void QIOSWindow::requestActivateWindow()
+{
+ // Note that several windows can be active at the same time if they exist in the same
+ // hierarchy (transient children). But only one window can be QGuiApplication::focusWindow().
+ // Dispite the name, 'requestActivateWindow' means raise and transfer focus to the window:
+ if (blockedByModal())
+ return;
+
+ raise();
+ QPlatformInputContext *context = QGuiApplicationPrivate::platformIntegration()->inputContext();
+ static_cast<QIOSInputContext *>(context)->focusViewChanged(m_view);
+ QPlatformWindow::requestActivateWindow();
+}
+
+void QIOSWindow::raiseOrLower(bool raise)
+{
+ // Re-insert m_view at the correct index among its sibling views
+ // (QWindows) according to their current m_windowLevel:
+ if (!isQtApplication())
+ return;
+
+ NSArray *subviews = m_view.superview.subviews;
+ if (subviews.count == 1)
+ return;
+
+ for (int i = int(subviews.count) - 1; i >= 0; --i) {
+ UIView *view = static_cast<UIView *>([subviews objectAtIndex:i]);
+ if (view.hidden || view == m_view)
+ continue;
+ int level = static_cast<QIOSWindow *>(view.qwindow->handle())->m_windowLevel;
+ if (m_windowLevel > level || (raise && m_windowLevel == level)) {
+ [m_view.superview insertSubview:m_view aboveSubview:view];
+ return;
+ }
+ }
+ [m_view.superview insertSubview:m_view atIndex:0];
+}
+
+void QIOSWindow::updateWindowLevel()
+{
+ Qt::WindowType type = static_cast<Qt::WindowType>(int(window()->flags() & Qt::WindowType_Mask));
+
+ if (type == Qt::ToolTip)
+ m_windowLevel = 120;
+ else if (window()->flags() & Qt::WindowStaysOnTopHint)
+ m_windowLevel = 100;
+ else if (window()->isModal())
+ m_windowLevel = 30;
+ else if (type & Qt::Popup & ~Qt::Window)
+ m_windowLevel = 20;
+ else if (type == Qt::Tool)
+ m_windowLevel = 10;
+ else
+ m_windowLevel = 0;
+
+ // A window should be in at least the same m_windowLevel as its parent:
+ QWindow *transientParent = window()->transientParent();
+ QIOSWindow *transientParentWindow = transientParent ? static_cast<QIOSWindow *>(transientParent->handle()) : 0;
+ if (transientParentWindow)
+ m_windowLevel = qMax(transientParentWindow->m_windowLevel, m_windowLevel);
+}
+
+void QIOSWindow::handleContentOrientationChange(Qt::ScreenOrientation orientation)
+{
+ // Keep the status bar in sync with content orientation. This will ensure
+ // that the task bar (and associated gestures) are aligned correctly:
+ UIInterfaceOrientation uiOrientation = UIInterfaceOrientation(fromQtScreenOrientation(orientation));
+ [[UIApplication sharedApplication] setStatusBarOrientation:uiOrientation animated:NO];
+}
+
+qreal QIOSWindow::devicePixelRatio() const
+{
+ return m_devicePixelRatio;
+}
+
+int QIOSWindow::effectiveWidth() const
+{
+ return geometry().width() * m_devicePixelRatio;
+}
+
+int QIOSWindow::effectiveHeight() const
+{
+ return geometry().height() * m_devicePixelRatio;
+}
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/ios/qtmain.mm b/src/plugins/platforms/ios/qtmain.mm
new file mode 100644
index 0000000000..916224f936
--- /dev/null
+++ b/src/plugins/platforms/ios/qtmain.mm
@@ -0,0 +1,93 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qiosapplicationdelegate.h"
+#include "qiosviewcontroller.h"
+
+int main(int argc, char *argv[])
+{
+ @autoreleasepool {
+ return UIApplicationMain(argc, argv, nil, NSStringFromClass([QIOSMainWrapperApplicationDelegate class]));
+ }
+}
+
+extern int qt_main(int argc, char *argv[]);
+
+@implementation QIOSMainWrapperApplicationDelegate
+
+- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
+{
+ self.window = [[[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]] autorelease];
+ self.window.rootViewController = [[[QIOSViewController alloc] init] autorelease];
+
+#ifdef QT_DEBUG
+ self.window.backgroundColor = [UIColor cyanColor];
+#endif
+
+ [self.window makeKeyAndVisible];
+
+ // We schedule the main-redirection for the next eventloop pass so that we
+ // can return from this function and let UIApplicationMain finish its job.
+ [NSTimer scheduledTimerWithTimeInterval:.01f target:self
+ selector:@selector(runUserMain) userInfo:nil repeats:NO];
+
+ if ([QIOSApplicationDelegate instancesRespondToSelector:_cmd])
+ return [super application:application didFinishLaunchingWithOptions:launchOptions];
+ else
+ return YES;
+}
+
+- (void)runUserMain
+{
+ NSArray *arguments = [[NSProcessInfo processInfo] arguments];
+ int argc = arguments.count;
+ char **argv = new char*[argc];
+ for (int i = 0; i < argc; ++i) {
+ NSString *arg = [arguments objectAtIndex:i];
+ argv[i] = reinterpret_cast<char *>(malloc([arg lengthOfBytesUsingEncoding:[NSString defaultCStringEncoding]]));
+ strcpy(argv[i], [arg cStringUsingEncoding:[NSString defaultCStringEncoding]]);
+ }
+
+ qt_main(argc, argv);
+ delete[] argv;
+}
+
+@end
diff --git a/src/plugins/platforms/ios/qtmain.pro b/src/plugins/platforms/ios/qtmain.pro
new file mode 100644
index 0000000000..cbcb272217
--- /dev/null
+++ b/src/plugins/platforms/ios/qtmain.pro
@@ -0,0 +1,8 @@
+TARGET = qiosmain
+
+PLUGIN_TYPE = platforms
+load(qt_plugin)
+
+QT += gui-private
+
+OBJECTIVE_SOURCES = qtmain.mm
diff --git a/src/plugins/platforms/kms/kms.pro b/src/plugins/platforms/kms/kms.pro
index c0300e0960..711cf9e5c7 100644
--- a/src/plugins/platforms/kms/kms.pro
+++ b/src/plugins/platforms/kms/kms.pro
@@ -4,9 +4,10 @@ PLUGIN_TYPE = platforms
PLUGIN_CLASS_NAME = QKmsIntegrationPlugin
load(qt_plugin)
-QT += core-private gui-private platformsupport-private opengl-private
+QT += core-private gui-private platformsupport-private
+qtHaveModule(opengl):QT += opengl-private
-DEFINES += MESA_EGL_NO_X11_HEADERS
+DEFINES += MESA_EGL_NO_X11_HEADERS __GBM__
CONFIG += link_pkgconfig egl qpa/genericunixfontdatabase
diff --git a/src/plugins/platforms/kms/qkmscursor.cpp b/src/plugins/platforms/kms/qkmscursor.cpp
index d9345ce89b..da5dc9bb06 100644
--- a/src/plugins/platforms/kms/qkmscursor.cpp
+++ b/src/plugins/platforms/kms/qkmscursor.cpp
@@ -48,22 +48,17 @@ QT_BEGIN_NAMESPACE
QKmsCursor::QKmsCursor(QKmsScreen *screen)
: m_screen(screen),
m_graphicsBufferManager(screen->device()->gbmDevice()),
+ m_cursorBufferObject(gbm_bo_create(m_graphicsBufferManager, 64, 64, GBM_FORMAT_ARGB8888,
+ GBM_BO_USE_CURSOR_64X64|GBM_BO_USE_WRITE)),
+ m_cursorImage(new QPlatformCursorImage(0, 0, 0, 0, 0, 0)),
m_moved(false)
{
- gbm_bo *bo = gbm_bo_create(m_graphicsBufferManager, 64, 64,
- GBM_BO_FORMAT_ARGB8888,
- GBM_BO_USE_CURSOR_64X64 | GBM_BO_USE_RENDERING);
-
- m_eglImage = eglCreateImageKHR(m_screen->device()->eglDisplay(), 0, EGL_NATIVE_PIXMAP_KHR,
- bo, 0);
- gbm_bo_destroy(bo);
- m_cursorImage = new QPlatformCursorImage(0, 0, 0, 0, 0, 0);
}
QKmsCursor::~QKmsCursor()
{
- drmModeSetCursor(m_screen->device()->fd(), m_screen->crtcId(),
- 0, 0, 0);
+ drmModeSetCursor(m_screen->device()->fd(), m_screen->crtcId(), 0, 0, 0);
+ gbm_bo_destroy(m_cursorBufferObject);
}
void QKmsCursor::pointerEvent(const QMouseEvent &event)
@@ -78,57 +73,30 @@ void QKmsCursor::pointerEvent(const QMouseEvent &event)
}
}
-void QKmsCursor::changeCursor(QCursor *widgetCursor, QWindow *window)
+void QKmsCursor::changeCursor(QCursor *windowCursor, QWindow *window)
{
Q_UNUSED(window)
if (!m_moved)
drmModeMoveCursor(m_screen->device()->fd(), m_screen->crtcId(), 0, 0);
- if (widgetCursor->shape() != Qt::BitmapCursor) {
- m_cursorImage->set(widgetCursor->shape());
- } else {
- m_cursorImage->set(widgetCursor->pixmap().toImage(),
- widgetCursor->hotSpot().x(),
- widgetCursor->hotSpot().y());
- }
-
- if ((m_cursorImage->image()->width() > 64) || (m_cursorImage->image()->width() > 64)) {
- qWarning("failed to set hardware cursor: larger than 64x64.");
- return;
- }
-
- QImage cursorImage = m_cursorImage->image()->convertToFormat(QImage::Format_RGB32);
-
- //Load cursor image into EGLImage
- GLuint cursorTexture;
- glGenTextures(1, &cursorTexture);
- glBindTexture(GL_TEXTURE_2D, cursorTexture);
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
- glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
-
-
- //TODO: Format may be wrong here, need a color icon to test.
- if (m_eglImage != EGL_NO_IMAGE_KHR) {
- glEGLImageTargetTexture2DOES(GL_TEXTURE_2D, m_eglImage);
- glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, cursorImage.width(),
- cursorImage.height(), GL_RGBA,
- GL_UNSIGNED_BYTE, cursorImage.constBits());
+ const Qt::CursorShape newShape = windowCursor ? windowCursor->shape() : Qt::ArrowCursor;
+ if (newShape != Qt::BitmapCursor) {
+ m_cursorImage->set(newShape);
} else {
- glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, cursorImage.width(),
- cursorImage.height(), 0, GL_RGBA,
- GL_UNSIGNED_BYTE, cursorImage.constBits());
+ m_cursorImage->set(windowCursor->pixmap().toImage(),
+ windowCursor->hotSpot().x(),
+ windowCursor->hotSpot().y());
}
- //EGLImage needs to contain sprite before calling this:
- gbm_bo *bufferObject = gbm_bo_import(m_graphicsBufferManager, GBM_BO_IMPORT_EGL_IMAGE,
- m_eglImage, GBM_BO_USE_CURSOR_64X64);
- quint32 handle = gbm_bo_get_handle(bufferObject).u32;
+ if ((m_cursorImage->image()->width() > 64) || (m_cursorImage->image()->width() > 64))
+ qWarning("Warning: cursor larger than 64x64; only 64x64 pixels will be shown.");
- gbm_bo_destroy(bufferObject);
+ QImage cursorImage = m_cursorImage->image()->
+ convertToFormat(QImage::Format_ARGB32).copy(0, 0, 64, 64);
+ gbm_bo_write(m_cursorBufferObject, cursorImage.constBits(), cursorImage.byteCount());
+ quint32 handle = gbm_bo_get_handle(m_cursorBufferObject).u32;
int status = drmModeSetCursor(m_screen->device()->fd(),
m_screen->crtcId(), handle, 64, 64);
diff --git a/src/plugins/platforms/kms/qkmscursor.h b/src/plugins/platforms/kms/qkmscursor.h
index fda47ebedc..ee65b01e36 100644
--- a/src/plugins/platforms/kms/qkmscursor.h
+++ b/src/plugins/platforms/kms/qkmscursor.h
@@ -44,15 +44,11 @@
#include <qpa/qplatformcursor.h>
-#define EGL_EGLEXT_PROTOTYPES 1
-
-#include <EGL/egl.h>
-#include <EGL/eglext.h>
-
QT_BEGIN_NAMESPACE
class QKmsScreen;
class gbm_device;
+class gbm_bo;
class QKmsCursor : public QPlatformCursor
{
@@ -61,12 +57,12 @@ public:
~QKmsCursor();
void pointerEvent(const QMouseEvent &event);
- void changeCursor(QCursor *widgetCursor, QWindow *window);
+ void changeCursor(QCursor *windowCursor, QWindow *window);
private:
QKmsScreen *m_screen;
gbm_device *m_graphicsBufferManager;
- EGLImageKHR m_eglImage;
+ gbm_bo *m_cursorBufferObject;
QPlatformCursorImage *m_cursorImage;
bool m_moved;
};
diff --git a/src/plugins/platforms/kms/qkmsscreen.cpp b/src/plugins/platforms/kms/qkmsscreen.cpp
index 123dcc283f..892f7bb01f 100644
--- a/src/plugins/platforms/kms/qkmsscreen.cpp
+++ b/src/plugins/platforms/kms/qkmsscreen.cpp
@@ -124,10 +124,14 @@ void QKmsScreen::initializeScreenMode()
drmModeConnector *connector = drmModeGetConnector(m_device->fd(), m_connectorId);
drmModeModeInfo *mode = 0;
- if (connector->count_modes > 0)
- mode = &connector->modes[0];
- else
- mode = &builtin_1024x768;
+ for (int i = 0; i < connector->count_modes; ++i) {
+ if (connector->modes[i].type & DRM_MODE_TYPE_PREFERRED) {
+ mode = &connector->modes[i];
+ break;
+ }
+ }
+ if (!mode)
+ mode = mode = &builtin_1024x768;
drmModeEncoder *encoder = drmModeGetEncoder(m_device->fd(), connector->encoders[0]);
if (encoder == 0)
diff --git a/src/plugins/platforms/minimalegl/qminimaleglbackingstore.cpp b/src/plugins/platforms/minimalegl/qminimaleglbackingstore.cpp
index da89100359..cb245f2e5c 100644
--- a/src/plugins/platforms/minimalegl/qminimaleglbackingstore.cpp
+++ b/src/plugins/platforms/minimalegl/qminimaleglbackingstore.cpp
@@ -49,6 +49,7 @@ QT_BEGIN_NAMESPACE
QMinimalEglBackingStore::QMinimalEglBackingStore(QWindow *window)
: QPlatformBackingStore(window)
, m_context(new QOpenGLContext)
+ , m_device(0)
{
m_context->setFormat(window->requestedFormat());
m_context->setScreen(window->screen());
diff --git a/src/plugins/platforms/minimalegl/qminimaleglintegration.h b/src/plugins/platforms/minimalegl/qminimaleglintegration.h
index fb86c967e1..dba7504033 100644
--- a/src/plugins/platforms/minimalegl/qminimaleglintegration.h
+++ b/src/plugins/platforms/minimalegl/qminimaleglintegration.h
@@ -47,8 +47,6 @@
#include <qpa/qplatformintegration.h>
#include <qpa/qplatformscreen.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QMinimalEglIntegration : public QPlatformIntegration
@@ -75,6 +73,5 @@ private:
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QMINIMALEGLINTEGRATION_H
diff --git a/src/plugins/platforms/offscreen/main.cpp b/src/plugins/platforms/offscreen/main.cpp
new file mode 100644
index 0000000000..ca7dc1d18b
--- /dev/null
+++ b/src/plugins/platforms/offscreen/main.cpp
@@ -0,0 +1,67 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+#include <qpa/qplatformintegrationplugin.h>
+#include "qoffscreenintegration.h"
+
+QT_BEGIN_NAMESPACE
+
+class QOffscreenIntegrationPlugin : public QPlatformIntegrationPlugin
+{
+ Q_OBJECT
+ Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.1" FILE "offscreen.json")
+public:
+ QPlatformIntegration *create(const QString&, const QStringList&);
+};
+
+QPlatformIntegration *QOffscreenIntegrationPlugin::create(const QString& system, const QStringList& paramList)
+{
+ Q_UNUSED(paramList);
+ if (system.toLower() == "offscreen")
+ return QOffscreenIntegration::createOffscreenIntegration();
+
+ return 0;
+}
+
+QT_END_NAMESPACE
+
+#include "main.moc"
diff --git a/src/plugins/platforms/offscreen/offscreen.json b/src/plugins/platforms/offscreen/offscreen.json
new file mode 100644
index 0000000000..6e87744de0
--- /dev/null
+++ b/src/plugins/platforms/offscreen/offscreen.json
@@ -0,0 +1,3 @@
+{
+ "Keys": [ "offscreen" ]
+}
diff --git a/src/plugins/platforms/offscreen/offscreen.pro b/src/plugins/platforms/offscreen/offscreen.pro
new file mode 100644
index 0000000000..270e3ce228
--- /dev/null
+++ b/src/plugins/platforms/offscreen/offscreen.pro
@@ -0,0 +1,25 @@
+TARGET = qoffscreen
+
+PLUGIN_TYPE = platforms
+load(qt_plugin)
+
+QT += core-private gui-private platformsupport-private
+
+SOURCES = main.cpp \
+ qoffscreenintegration.cpp \
+ qoffscreenwindow.cpp \
+ qoffscreencommon.cpp
+
+HEADERS = qoffscreenintegration.h \
+ qoffscreenwindow.h \
+ qoffscreencommon.h
+
+OTHER_FILES += offscreen.json
+
+contains(QT_CONFIG, xcb):contains(QT_CONFIG, opengl):!contains(QT_CONFIG, opengles2) {
+ SOURCES += qoffscreenintegration_x11.cpp
+ HEADERS += qoffscreenintegration_x11.h
+ system(echo "Using X11 offscreen integration with GLX")
+} else {
+ SOURCES += qoffscreenintegration_dummy.cpp
+}
diff --git a/src/plugins/platforms/offscreen/qoffscreencommon.cpp b/src/plugins/platforms/offscreen/qoffscreencommon.cpp
new file mode 100644
index 0000000000..069b20693d
--- /dev/null
+++ b/src/plugins/platforms/offscreen/qoffscreencommon.cpp
@@ -0,0 +1,229 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qoffscreencommon.h"
+#include "qoffscreenwindow.h"
+
+#include <QtGui/private/qpixmap_raster_p.h>
+#include <QtGui/private/qguiapplication_p.h>
+
+#include <qpa/qplatformcursor.h>
+#include <qpa/qplatformwindow.h>
+
+QT_BEGIN_NAMESPACE
+
+QPlatformWindow *QOffscreenScreen::windowContainingCursor = 0;
+
+class QOffscreenCursor : public QPlatformCursor
+{
+public:
+ QOffscreenCursor() : m_pos(10, 10) {}
+
+ QPoint pos() const { return m_pos; }
+ void setPos(const QPoint &pos)
+ {
+ m_pos = pos;
+ QWindowList wl = QGuiApplication::topLevelWindows();
+ QWindow *containing = 0;
+ foreach (QWindow *w, wl) {
+ if (w->type() != Qt::Desktop && w->isExposed() && w->geometry().contains(pos)) {
+ containing = w;
+ break;
+ }
+ }
+
+ QPoint local = pos;
+ if (containing)
+ local -= containing->position();
+
+ QWindow *previous = QOffscreenScreen::windowContainingCursor ? QOffscreenScreen::windowContainingCursor->window() : 0;
+
+ if (containing != previous)
+ QWindowSystemInterface::handleEnterLeaveEvent(containing, previous, local, pos);
+
+ QWindowSystemInterface::handleMouseEvent(containing, local, pos, QGuiApplication::mouseButtons(), QGuiApplication::keyboardModifiers());
+
+ QOffscreenScreen::windowContainingCursor = containing ? containing->handle() : 0;
+ }
+
+ void changeCursor(QCursor *windowCursor, QWindow *window)
+ {
+ Q_UNUSED(windowCursor);
+ Q_UNUSED(window);
+ }
+
+private:
+ QPoint m_pos;
+};
+
+QOffscreenScreen::QOffscreenScreen()
+ : m_geometry(0, 0, 800, 600)
+ , m_cursor(new QOffscreenCursor)
+{
+}
+
+QPixmap QOffscreenScreen::grabWindow(WId id, int x, int y, int width, int height) const
+{
+ QRect rect(x, y, width, height);
+
+ QOffscreenWindow *window = QOffscreenWindow::windowForWinId(id);
+ if (!window || window->window()->type() == Qt::Desktop) {
+ QWindowList wl = QGuiApplication::topLevelWindows();
+ QWindow *containing = 0;
+ foreach (QWindow *w, wl) {
+ if (w->type() != Qt::Desktop && w->isExposed() && w->geometry().contains(rect)) {
+ containing = w;
+ break;
+ }
+ }
+
+ if (!containing)
+ return QPixmap();
+
+ id = containing->winId();
+ rect = rect.translated(-containing->geometry().topLeft());
+ }
+
+ QOffscreenBackingStore *store = QOffscreenBackingStore::backingStoreForWinId(id);
+ if (store)
+ return store->grabWindow(id, rect);
+ return QPixmap();
+}
+
+QOffscreenBackingStore::QOffscreenBackingStore(QWindow *window)
+ : QPlatformBackingStore(window)
+{
+}
+
+QOffscreenBackingStore::~QOffscreenBackingStore()
+{
+ clearHash();
+}
+
+QPaintDevice *QOffscreenBackingStore::paintDevice()
+{
+ return &m_image;
+}
+
+void QOffscreenBackingStore::flush(QWindow *window, const QRegion &region, const QPoint &offset)
+{
+ Q_UNUSED(region);
+
+ if (m_image.size().isEmpty())
+ return;
+
+ QSize imageSize = m_image.size();
+
+ QRegion clipped = QRect(0, 0, window->width(), window->height());
+ clipped &= QRect(0, 0, imageSize.width(), imageSize.height()).translated(-offset);
+
+ QRect bounds = clipped.boundingRect().translated(offset);
+
+ if (bounds.isNull())
+ return;
+
+ WId id = window->winId();
+
+ m_windowAreaHash[id] = bounds;
+ m_backingStoreForWinIdHash[id] = this;
+}
+
+void QOffscreenBackingStore::resize(const QSize &size, const QRegion &)
+{
+ QImage::Format format = QGuiApplication::primaryScreen()->handle()->format();
+ if (m_image.size() != size)
+ m_image = QImage(size, format);
+ clearHash();
+}
+
+extern void qt_scrollRectInImage(QImage &img, const QRect &rect, const QPoint &offset);
+
+bool QOffscreenBackingStore::scroll(const QRegion &area, int dx, int dy)
+{
+ if (m_image.isNull())
+ return false;
+
+ const QVector<QRect> rects = area.rects();
+ for (int i = 0; i < rects.size(); ++i)
+ qt_scrollRectInImage(m_image, rects.at(i), QPoint(dx, dy));
+
+ return true;
+}
+
+QPixmap QOffscreenBackingStore::grabWindow(WId window, const QRect &rect) const
+{
+ QRect area = m_windowAreaHash.value(window, QRect());
+ if (area.isNull())
+ return QPixmap();
+
+ QRect adjusted = rect;
+ if (adjusted.width() <= 0)
+ adjusted.setWidth(area.width());
+ if (adjusted.height() <= 0)
+ adjusted.setHeight(area.height());
+
+ adjusted = adjusted.translated(area.topLeft()) & area;
+
+ if (adjusted.isEmpty())
+ return QPixmap();
+
+ return QPixmap::fromImage(m_image.copy(adjusted));
+}
+
+QOffscreenBackingStore *QOffscreenBackingStore::backingStoreForWinId(WId id)
+{
+ return m_backingStoreForWinIdHash.value(id, 0);
+}
+
+void QOffscreenBackingStore::clearHash()
+{
+ QList<WId> ids = m_windowAreaHash.keys();
+ foreach (WId id, ids) {
+ QHash<WId, QOffscreenBackingStore *>::iterator it = m_backingStoreForWinIdHash.find(id);
+ if (it.value() == this)
+ m_backingStoreForWinIdHash.remove(id);
+ }
+ m_windowAreaHash.clear();
+}
+
+QHash<WId, QOffscreenBackingStore *> QOffscreenBackingStore::m_backingStoreForWinIdHash;
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/offscreen/qoffscreencommon.h b/src/plugins/platforms/offscreen/qoffscreencommon.h
new file mode 100644
index 0000000000..a5df7d05d3
--- /dev/null
+++ b/src/plugins/platforms/offscreen/qoffscreencommon.h
@@ -0,0 +1,109 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QOFFSCREENCOMMON_H
+#define QOFFSCREENCOMMON_H
+
+#include <qpa/qplatformbackingstore.h>
+#include <qpa/qplatformdrag.h>
+#include <qpa/qplatformintegration.h>
+#include <qpa/qplatformscreen.h>
+#include <qpa/qplatformwindow.h>
+
+#include <qscopedpointer.h>
+#include <qimage.h>
+#include <qhash.h>
+
+QT_BEGIN_NAMESPACE
+
+class QOffscreenScreen : public QPlatformScreen
+{
+public:
+ QOffscreenScreen();
+
+ QRect geometry() const { return m_geometry; }
+ int depth() const { return 32; }
+ QImage::Format format() const { return QImage::Format_RGB32; }
+ QPlatformCursor *cursor() const { return m_cursor.data(); }
+
+ QPixmap grabWindow(WId window, int x, int y, int width, int height) const;
+
+ static QPlatformWindow *windowContainingCursor;
+
+public:
+ QRect m_geometry;
+ QScopedPointer<QPlatformCursor> m_cursor;
+};
+
+class QOffscreenDrag : public QPlatformDrag
+{
+public:
+ QMimeData *platformDropData() { return 0; }
+ Qt::DropAction drag(QDrag *) { return Qt::IgnoreAction; }
+};
+
+class QOffscreenBackingStore : public QPlatformBackingStore
+{
+public:
+ QOffscreenBackingStore(QWindow *window);
+ ~QOffscreenBackingStore();
+
+ QPaintDevice *paintDevice();
+ void flush(QWindow *window, const QRegion &region, const QPoint &offset);
+ void resize(const QSize &size, const QRegion &staticContents);
+ bool scroll(const QRegion &area, int dx, int dy);
+
+ QPixmap grabWindow(WId window, const QRect &rect) const;
+
+ static QOffscreenBackingStore *backingStoreForWinId(WId id);
+
+private:
+ void clearHash();
+
+ QImage m_image;
+ QHash<WId, QRect> m_windowAreaHash;
+
+ static QHash<WId, QOffscreenBackingStore *> m_backingStoreForWinIdHash;
+};
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/plugins/platforms/offscreen/qoffscreenintegration.cpp b/src/plugins/platforms/offscreen/qoffscreenintegration.cpp
new file mode 100644
index 0000000000..e3fcc7ebb0
--- /dev/null
+++ b/src/plugins/platforms/offscreen/qoffscreenintegration.cpp
@@ -0,0 +1,162 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qoffscreenintegration.h"
+#include "qoffscreenwindow.h"
+#include "qoffscreencommon.h"
+
+#if defined(Q_OS_UNIX)
+#include <QtPlatformSupport/private/qgenericunixeventdispatcher_p.h>
+#if defined(Q_OS_MAC)
+#include <qpa/qplatformfontdatabase.h>
+#else
+#include <QtPlatformSupport/private/qgenericunixfontdatabase_p.h>
+#endif
+#elif defined(Q_OS_WIN)
+#include <QtPlatformSupport/private/qbasicfontdatabase_p.h>
+#include <QtCore/private/qeventdispatcher_win_p.h>
+#endif
+
+#include <QtGui/private/qpixmap_raster_p.h>
+#include <QtGui/private/qguiapplication_p.h>
+
+#include <qpa/qplatformservices.h>
+
+QT_BEGIN_NAMESPACE
+
+template <typename BaseEventDispatcher>
+class QOffscreenEventDispatcher : public BaseEventDispatcher
+{
+public:
+ explicit QOffscreenEventDispatcher(QObject *parent = 0)
+ : BaseEventDispatcher(parent)
+ {
+ }
+
+ bool processEvents(QEventLoop::ProcessEventsFlags flags)
+ {
+ bool didSendEvents = QWindowSystemInterface::sendWindowSystemEvents(flags);
+
+ return BaseEventDispatcher::processEvents(flags) || didSendEvents;
+ }
+
+ bool hasPendingEvents()
+ {
+ return BaseEventDispatcher::hasPendingEvents()
+ || QWindowSystemInterface::windowSystemEventsQueued();
+ }
+
+ void flush()
+ {
+ if (qApp)
+ qApp->sendPostedEvents();
+ BaseEventDispatcher::flush();
+ }
+};
+
+QOffscreenIntegration::QOffscreenIntegration()
+{
+#if defined(Q_OS_UNIX)
+ m_eventDispatcher = createUnixEventDispatcher();
+#if defined(Q_OS_MAC)
+ m_fontDatabase.reset(new QPlatformFontDatabase());
+#else
+ m_fontDatabase.reset(new QGenericUnixFontDatabase());
+#endif
+#elif defined(Q_OS_WIN)
+ m_eventDispatcher = new QOffscreenEventDispatcher<QEventDispatcherWin32>();
+ m_fontDatabase.reset(new QBasicFontDatabase());
+#endif
+
+ m_drag.reset(new QOffscreenDrag);
+ m_services.reset(new QPlatformServices);
+
+ QGuiApplicationPrivate::instance()->setEventDispatcher(m_eventDispatcher);
+ screenAdded(new QOffscreenScreen);
+}
+
+QOffscreenIntegration::~QOffscreenIntegration()
+{
+}
+
+bool QOffscreenIntegration::hasCapability(QPlatformIntegration::Capability cap) const
+{
+ switch (cap) {
+ case ThreadedPixmaps: return true;
+ case MultipleWindows: return true;
+ default: return QPlatformIntegration::hasCapability(cap);
+ }
+}
+
+QPlatformWindow *QOffscreenIntegration::createPlatformWindow(QWindow *window) const
+{
+ Q_UNUSED(window);
+ QPlatformWindow *w = new QOffscreenWindow(window);
+ w->requestActivateWindow();
+ return w;
+}
+
+QPlatformBackingStore *QOffscreenIntegration::createPlatformBackingStore(QWindow *window) const
+{
+ return new QOffscreenBackingStore(window);
+}
+
+QAbstractEventDispatcher *QOffscreenIntegration::guiThreadEventDispatcher() const
+{
+ return m_eventDispatcher;
+}
+
+QPlatformFontDatabase *QOffscreenIntegration::fontDatabase() const
+{
+ return m_fontDatabase.data();
+}
+
+QPlatformDrag *QOffscreenIntegration::drag() const
+{
+ return m_drag.data();
+}
+
+QPlatformServices *QOffscreenIntegration::services() const
+{
+ return m_services.data();
+}
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/offscreen/qoffscreenintegration.h b/src/plugins/platforms/offscreen/qoffscreenintegration.h
new file mode 100644
index 0000000000..eb03100ec9
--- /dev/null
+++ b/src/plugins/platforms/offscreen/qoffscreenintegration.h
@@ -0,0 +1,80 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QOFFSCREENINTEGRATION_H
+#define QOFFSCREENINTEGRATION_H
+
+#include <qpa/qplatformintegration.h>
+
+#include <qscopedpointer.h>
+
+QT_BEGIN_NAMESPACE
+
+class QOffscreenBackendData;
+
+class QOffscreenIntegration : public QPlatformIntegration
+{
+public:
+ QOffscreenIntegration();
+ ~QOffscreenIntegration();
+
+ bool hasCapability(QPlatformIntegration::Capability cap) const;
+
+ QPlatformWindow *createPlatformWindow(QWindow *window) const;
+ QPlatformBackingStore *createPlatformBackingStore(QWindow *window) const;
+ QPlatformDrag *drag() const;
+ QPlatformServices *services() const;
+
+ QPlatformFontDatabase *fontDatabase() const;
+ QAbstractEventDispatcher *guiThreadEventDispatcher() const;
+
+ static QOffscreenIntegration *createOffscreenIntegration();
+
+private:
+ QAbstractEventDispatcher *m_eventDispatcher;
+ QScopedPointer<QPlatformFontDatabase> m_fontDatabase;
+ QScopedPointer<QPlatformDrag> m_drag;
+ QScopedPointer<QPlatformServices> m_services;
+};
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/corelib/io/qfilesystemengine_mac.cpp b/src/plugins/platforms/offscreen/qoffscreenintegration_dummy.cpp
index 65ae06d58d..8bc1b17a56 100644
--- a/src/corelib/io/qfilesystemengine_mac.cpp
+++ b/src/plugins/platforms/offscreen/qoffscreenintegration_dummy.cpp
@@ -1,9 +1,9 @@
/****************************************************************************
**
-** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtCore module of the Qt Toolkit.
+** This file is part of the plugins of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -39,10 +39,9 @@
**
****************************************************************************/
-#include "qfilesystemengine_p.h"
+#include "qoffscreenintegration.h"
-QT_BEGIN_NAMESPACE
-
-// Mac-specific implementations only!
-
-QT_END_NAMESPACE
+QOffscreenIntegration *QOffscreenIntegration::createOffscreenIntegration()
+{
+ return new QOffscreenIntegration;
+}
diff --git a/src/plugins/platforms/offscreen/qoffscreenintegration_x11.cpp b/src/plugins/platforms/offscreen/qoffscreenintegration_x11.cpp
new file mode 100644
index 0000000000..6c6c516a4e
--- /dev/null
+++ b/src/plugins/platforms/offscreen/qoffscreenintegration_x11.cpp
@@ -0,0 +1,252 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qoffscreenintegration_x11.h"
+
+#include <QByteArray>
+#include <QOpenGLContext>
+
+#include <X11/Xlib.h>
+#include <GL/glx.h>
+
+#include <QtPlatformSupport/private/qglxconvenience_p.h>
+
+#include <qpa/qplatformsurface.h>
+#include <qsurface.h>
+
+QT_BEGIN_NAMESPACE
+
+QOffscreenIntegration *QOffscreenIntegration::createOffscreenIntegration()
+{
+ return new QOffscreenX11Integration;
+}
+
+bool QOffscreenX11Integration::hasCapability(QPlatformIntegration::Capability cap) const
+{
+ switch (cap) {
+ case OpenGL: return true;
+ case ThreadedOpenGL: return true;
+ default: return QOffscreenIntegration::hasCapability(cap);
+ }
+}
+
+QPlatformOpenGLContext *QOffscreenX11Integration::createPlatformOpenGLContext(QOpenGLContext *context) const
+{
+ if (!m_connection)
+ m_connection.reset(new QOffscreenX11Connection);
+
+ return new QOffscreenX11GLXContext(m_connection->x11Info(), context);
+}
+
+QOffscreenX11Connection::QOffscreenX11Connection()
+{
+ XInitThreads();
+
+ QByteArray displayName = qgetenv("DISPLAY");
+ Display *display = XOpenDisplay(displayName.constData());
+ m_display = display;
+ m_screenNumber = DefaultScreen(display);
+}
+
+QOffscreenX11Connection::~QOffscreenX11Connection()
+{
+ XCloseDisplay((Display *)m_display);
+}
+
+class QOffscreenX11Info
+{
+public:
+ QOffscreenX11Info(QOffscreenX11Connection *connection)
+ : m_connection(connection)
+ {
+ }
+
+ Display *display() const {
+ return (Display *)m_connection->display();
+ }
+
+ Window root() const {
+ return DefaultRootWindow(display());
+ }
+
+ int screenNumber() const {
+ return m_connection->screenNumber();
+ }
+
+private:
+ QOffscreenX11Connection *m_connection;
+};
+
+QOffscreenX11Info *QOffscreenX11Connection::x11Info()
+{
+ if (!m_x11Info)
+ m_x11Info.reset(new QOffscreenX11Info(this));
+ return m_x11Info.data();
+}
+
+class QOffscreenX11GLXContextData
+{
+public:
+ QOffscreenX11Info *x11;
+ QSurfaceFormat format;
+ GLXContext context;
+ GLXContext shareContext;
+ Window window;
+};
+
+static Window createDummyWindow(QOffscreenX11Info *x11, XVisualInfo *visualInfo)
+{
+ Colormap cmap = XCreateColormap(x11->display(), x11->root(), visualInfo->visual, AllocNone);
+ XSetWindowAttributes a;
+ a.background_pixel = WhitePixel(x11->display(), x11->screenNumber());
+ a.border_pixel = BlackPixel(x11->display(), x11->screenNumber());
+ a.colormap = cmap;
+
+ Window window = XCreateWindow(x11->display(), x11->root(),
+ 0, 0, 100, 100,
+ 0, visualInfo->depth, InputOutput, visualInfo->visual,
+ CWBackPixel|CWBorderPixel|CWColormap, &a);
+ XFreeColormap(x11->display(), cmap);
+ return window;
+}
+
+static Window createDummyWindow(QOffscreenX11Info *x11, GLXFBConfig config)
+{
+ XVisualInfo *visualInfo = glXGetVisualFromFBConfig(x11->display(), config);
+ if (!visualInfo)
+ qFatal("Could not initialize GLX");
+ Window window = createDummyWindow(x11, visualInfo);
+ XFree(visualInfo);
+ return window;
+}
+
+QOffscreenX11GLXContext::QOffscreenX11GLXContext(QOffscreenX11Info *x11, QOpenGLContext *context)
+ : d(new QOffscreenX11GLXContextData)
+{
+ d->x11 = x11;
+ d->format = context->format();
+
+ d->shareContext = 0;
+ if (context->shareHandle())
+ d->shareContext = static_cast<QOffscreenX11GLXContext *>(context->shareHandle())->d->context;
+
+ GLXFBConfig config = qglx_findConfig(x11->display(), x11->screenNumber(), d->format);
+ if (config) {
+ d->context = glXCreateNewContext(x11->display(), config, GLX_RGBA_TYPE, d->shareContext, true);
+ if (!d->context && d->shareContext) {
+ d->shareContext = 0;
+ // re-try without a shared glx context
+ d->context = glXCreateNewContext(x11->display(), config, GLX_RGBA_TYPE, 0, true);
+ }
+
+ // Get the basic surface format details
+ if (d->context)
+ qglx_surfaceFormatFromGLXFBConfig(&d->format, x11->display(), config, d->context);
+
+ // Create a temporary window so that we can make the new context current
+ d->window = createDummyWindow(x11, config);
+ } else {
+ XVisualInfo *visualInfo = qglx_findVisualInfo(x11->display(), 0, &d->format);
+ if (!visualInfo)
+ qFatal("Could not initialize GLX");
+ d->context = glXCreateContext(x11->display(), visualInfo, d->shareContext, true);
+ if (!d->context && d->shareContext) {
+ // re-try without a shared glx context
+ d->shareContext = 0;
+ d->context = glXCreateContext(x11->display(), visualInfo, 0, true);
+ }
+
+ d->window = createDummyWindow(x11, visualInfo);
+ XFree(visualInfo);
+ }
+}
+
+QOffscreenX11GLXContext::~QOffscreenX11GLXContext()
+{
+ glXDestroyContext(d->x11->display(), d->context);
+ XDestroyWindow(d->x11->display(), d->window);
+}
+
+bool QOffscreenX11GLXContext::makeCurrent(QPlatformSurface *surface)
+{
+ QSize size = surface->surface()->size();
+
+ XResizeWindow(d->x11->display(), d->window, size.width(), size.height());
+ XSync(d->x11->display(), true);
+
+ if (glXMakeCurrent(d->x11->display(), d->window, d->context)) {
+ glViewport(0, 0, size.width(), size.height());
+ return true;
+ }
+
+ return false;
+}
+
+void QOffscreenX11GLXContext::doneCurrent()
+{
+ glXMakeCurrent(d->x11->display(), 0, 0);
+}
+
+void QOffscreenX11GLXContext::swapBuffers(QPlatformSurface *)
+{
+}
+
+void (*QOffscreenX11GLXContext::getProcAddress(const QByteArray &procName)) ()
+{
+ return (void (*)())glXGetProcAddressARB(reinterpret_cast<const GLubyte *>(procName.constData()));
+}
+
+QSurfaceFormat QOffscreenX11GLXContext::format() const
+{
+ return d->format;
+}
+
+bool QOffscreenX11GLXContext::isSharing() const
+{
+ return d->shareContext;
+}
+
+bool QOffscreenX11GLXContext::isValid() const
+{
+ return d->context && d->window;
+}
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/offscreen/qoffscreenintegration_x11.h b/src/plugins/platforms/offscreen/qoffscreenintegration_x11.h
new file mode 100644
index 0000000000..9afa302b04
--- /dev/null
+++ b/src/plugins/platforms/offscreen/qoffscreenintegration_x11.h
@@ -0,0 +1,108 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QOFFSCREENINTEGRATION_X11_H
+#define QOFFSCREENINTEGRATION_X11_H
+
+#include "qoffscreenintegration.h"
+
+#include <qglobal.h>
+#include <qscopedpointer.h>
+
+#include <qpa/qplatformopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class QOffscreenX11Connection;
+class QOffscreenX11Info;
+
+class QOffscreenX11Integration : public QOffscreenIntegration
+{
+public:
+ bool hasCapability(QPlatformIntegration::Capability cap) const;
+
+ QPlatformOpenGLContext *createPlatformOpenGLContext(QOpenGLContext *context) const;
+
+private:
+ mutable QScopedPointer<QOffscreenX11Connection> m_connection;
+};
+
+class QOffscreenX11Connection {
+public:
+ QOffscreenX11Connection();
+ ~QOffscreenX11Connection();
+
+ QOffscreenX11Info *x11Info();
+
+ void *display() const { return m_display; }
+ int screenNumber() const { return m_screenNumber; }
+
+private:
+ void *m_display;
+ int m_screenNumber;
+
+ QScopedPointer<QOffscreenX11Info> m_x11Info;
+};
+
+class QOffscreenX11GLXContextData;
+
+class QOffscreenX11GLXContext : public QPlatformOpenGLContext
+{
+public:
+ QOffscreenX11GLXContext(QOffscreenX11Info *x11, QOpenGLContext *context);
+ ~QOffscreenX11GLXContext();
+
+ bool makeCurrent(QPlatformSurface *surface);
+ void doneCurrent();
+ void swapBuffers(QPlatformSurface *surface);
+ void (*getProcAddress(const QByteArray &procName)) ();
+
+ QSurfaceFormat format() const;
+ bool isSharing() const;
+ bool isValid() const;
+
+private:
+ QScopedPointer<QOffscreenX11GLXContextData> d;
+};
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/plugins/platforms/offscreen/qoffscreenwindow.cpp b/src/plugins/platforms/offscreen/qoffscreenwindow.cpp
new file mode 100644
index 0000000000..702ef2300c
--- /dev/null
+++ b/src/plugins/platforms/offscreen/qoffscreenwindow.cpp
@@ -0,0 +1,199 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qoffscreenwindow.h"
+#include "qoffscreencommon.h"
+
+#include <qpa/qplatformscreen.h>
+#include <qpa/qwindowsysteminterface.h>
+
+#include <private/qwindow_p.h>
+
+QT_BEGIN_NAMESPACE
+
+QOffscreenWindow::QOffscreenWindow(QWindow *window)
+ : QPlatformWindow(window)
+ , m_positionIncludesFrame(false)
+ , m_visible(false)
+ , m_pendingGeometryChangeOnShow(true)
+{
+ if (window->windowState() == Qt::WindowNoState)
+ setGeometry(window->geometry());
+ else
+ setWindowState(window->windowState());
+
+ QWindowSystemInterface::flushWindowSystemEvents();
+
+ static WId counter = 0;
+ m_winId = ++counter;
+
+ m_windowForWinIdHash[m_winId] = this;
+}
+
+QOffscreenWindow::~QOffscreenWindow()
+{
+ if (QOffscreenScreen::windowContainingCursor == this)
+ QOffscreenScreen::windowContainingCursor = 0;
+ m_windowForWinIdHash.remove(m_winId);
+}
+
+void QOffscreenWindow::setGeometry(const QRect &rect)
+{
+ if (window()->windowState() != Qt::WindowNoState)
+ return;
+
+ m_positionIncludesFrame = qt_window_private(window())->positionPolicy == QWindowPrivate::WindowFrameInclusive;
+
+ setFrameMarginsEnabled(true);
+ setGeometryImpl(rect);
+
+ m_normalGeometry = geometry();
+}
+
+void QOffscreenWindow::setGeometryImpl(const QRect &rect)
+{
+ QRect adjusted = rect;
+ if (adjusted.width() <= 0)
+ adjusted.setWidth(1);
+ if (adjusted.height() <= 0)
+ adjusted.setHeight(1);
+
+ if (m_positionIncludesFrame) {
+ adjusted.translate(m_margins.left(), m_margins.top());
+ } else {
+ // make sure we're not placed off-screen
+ if (adjusted.left() < m_margins.left())
+ adjusted.translate(m_margins.left(), 0);
+ if (adjusted.top() < m_margins.top())
+ adjusted.translate(0, m_margins.top());
+ }
+
+ QPlatformWindow::setGeometry(adjusted);
+
+ if (m_visible) {
+ QWindowSystemInterface::handleGeometryChange(window(), adjusted);
+ QWindowSystemInterface::handleExposeEvent(window(), QRect(QPoint(), adjusted.size()));
+ } else {
+ m_pendingGeometryChangeOnShow = true;
+ }
+}
+
+void QOffscreenWindow::setVisible(bool visible)
+{
+ if (visible == m_visible)
+ return;
+
+ if (visible) {
+ if (window()->type() != Qt::ToolTip)
+ QWindowSystemInterface::handleWindowActivated(window());
+
+ if (m_pendingGeometryChangeOnShow) {
+ m_pendingGeometryChangeOnShow = false;
+ QWindowSystemInterface::handleGeometryChange(window(), geometry());
+ }
+ }
+
+ if (visible) {
+ QRect rect(QPoint(), geometry().size());
+ QWindowSystemInterface::handleExposeEvent(window(), rect);
+ } else {
+ QWindowSystemInterface::handleExposeEvent(window(), QRegion());
+ }
+
+ m_visible = visible;
+}
+
+void QOffscreenWindow::requestActivateWindow()
+{
+ if (m_visible)
+ QWindowSystemInterface::handleWindowActivated(window());
+}
+
+WId QOffscreenWindow::winId() const
+{
+ return m_winId;
+}
+
+QMargins QOffscreenWindow::frameMargins() const
+{
+ return m_margins;
+}
+
+void QOffscreenWindow::setFrameMarginsEnabled(bool enabled)
+{
+ if (enabled && !(window()->flags() & Qt::FramelessWindowHint))
+ m_margins = QMargins(2, 2, 2, 2);
+ else
+ m_margins = QMargins(0, 0, 0, 0);
+}
+
+void QOffscreenWindow::setWindowState(Qt::WindowState state)
+{
+ setFrameMarginsEnabled(state != Qt::WindowFullScreen);
+ m_positionIncludesFrame = false;
+
+ switch (state) {
+ case Qt::WindowFullScreen:
+ setGeometryImpl(screen()->geometry());
+ break;
+ case Qt::WindowMaximized:
+ setGeometryImpl(screen()->availableGeometry().adjusted(m_margins.left(), m_margins.top(), -m_margins.right(), -m_margins.bottom()));
+ break;
+ case Qt::WindowMinimized:
+ break;
+ case Qt::WindowNoState:
+ setGeometryImpl(m_normalGeometry);
+ break;
+ default:
+ break;
+ }
+
+ QWindowSystemInterface::handleWindowStateChanged(window(), state);
+}
+
+QOffscreenWindow *QOffscreenWindow::windowForWinId(WId id)
+{
+ return m_windowForWinIdHash.value(id, 0);
+}
+
+QHash<WId, QOffscreenWindow *> QOffscreenWindow::m_windowForWinIdHash;
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platforms/offscreen/qoffscreenwindow.h b/src/plugins/platforms/offscreen/qoffscreenwindow.h
new file mode 100644
index 0000000000..cd1cf8e0aa
--- /dev/null
+++ b/src/plugins/platforms/offscreen/qoffscreenwindow.h
@@ -0,0 +1,86 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QOFFSCREENWINDOW_H
+#define QOFFSCREENWINDOW_H
+
+#include <qpa/qplatformbackingstore.h>
+#include <qpa/qplatformwindow.h>
+
+#include <qhash.h>
+
+QT_BEGIN_NAMESPACE
+
+class QOffscreenWindow : public QPlatformWindow
+{
+public:
+ QOffscreenWindow(QWindow *window);
+ ~QOffscreenWindow();
+
+ void setGeometry(const QRect &rect);
+ void setWindowState(Qt::WindowState state);
+
+ QMargins frameMargins() const;
+
+ void setVisible(bool visible);
+ void requestActivateWindow();
+
+ WId winId() const;
+
+ static QOffscreenWindow *windowForWinId(WId id);
+
+private:
+ void setFrameMarginsEnabled(bool enabled);
+ void setGeometryImpl(const QRect &rect);
+
+ QRect m_normalGeometry;
+ QMargins m_margins;
+ bool m_positionIncludesFrame;
+ bool m_visible;
+ bool m_pendingGeometryChangeOnShow;
+ WId m_winId;
+
+ static QHash<WId, QOffscreenWindow *> m_windowForWinIdHash;
+};
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/plugins/platforms/platforms.pro b/src/plugins/platforms/platforms.pro
index 828867c3a7..92664826ab 100644
--- a/src/plugins/platforms/platforms.pro
+++ b/src/plugins/platforms/platforms.pro
@@ -1,12 +1,17 @@
TEMPLATE = subdirs
-SUBDIRS += minimal
+android:!android-no-sdk: SUBDIRS += android
+
+SUBDIRS += minimal offscreen
contains(QT_CONFIG, xcb) {
SUBDIRS += xcb
}
-mac:!ios: SUBDIRS += cocoa
+mac {
+ ios: SUBDIRS += ios
+ else: SUBDIRS += cocoa
+}
win32: SUBDIRS += windows
diff --git a/src/plugins/platforms/qnx/qnx.pro b/src/plugins/platforms/qnx/qnx.pro
index 8367513fc5..203cdebda9 100644
--- a/src/plugins/platforms/qnx/qnx.pro
+++ b/src/plugins/platforms/qnx/qnx.pro
@@ -39,6 +39,7 @@ CONFIG(blackberry) {
#DEFINES += QQNXSCREEN_DEBUG
#DEFINES += QQNXVIRTUALKEYBOARD_DEBUG
#DEFINES += QQNXWINDOW_DEBUG
+#DEFINES += QQNXCURSOR_DEBUG
SOURCES = main.cpp \
@@ -54,7 +55,8 @@ SOURCES = main.cpp \
qqnxnavigatoreventhandler.cpp \
qqnxabstractnavigator.cpp \
qqnxabstractvirtualkeyboard.cpp \
- qqnxservices.cpp
+ qqnxservices.cpp \
+ qqnxcursor.cpp
HEADERS = main.h \
qqnxbuffer.h \
@@ -70,7 +72,8 @@ HEADERS = main.h \
qqnxnavigatoreventhandler.h \
qqnxabstractnavigator.h \
qqnxabstractvirtualkeyboard.h \
- qqnxservices.h
+ qqnxservices.h \
+ qqnxcursor.h
LIBS += -lscreen
diff --git a/src/plugins/platforms/qnx/qqnxabstractnavigator.cpp b/src/plugins/platforms/qnx/qqnxabstractnavigator.cpp
index 08da98d690..5a94bff14e 100644
--- a/src/plugins/platforms/qnx/qqnxabstractnavigator.cpp
+++ b/src/plugins/platforms/qnx/qqnxabstractnavigator.cpp
@@ -44,7 +44,7 @@
#include <QDebug>
#include <QUrl>
-#ifdef QQNXNAVIGATOR_DEBUG
+#if defined(QQNXNAVIGATOR_DEBUG)
#define qNavigatorDebug qDebug
#else
#define qNavigatorDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxbpseventfilter.cpp b/src/plugins/platforms/qnx/qqnxbpseventfilter.cpp
index 2d19537896..d94d3c092a 100644
--- a/src/plugins/platforms/qnx/qqnxbpseventfilter.cpp
+++ b/src/plugins/platforms/qnx/qqnxbpseventfilter.cpp
@@ -53,7 +53,7 @@
#include <bps/navigator.h>
#include <bps/screen.h>
-#ifdef QQNXBPSEVENTFILTER_DEBUG
+#if defined(QQNXBPSEVENTFILTER_DEBUG)
#define qBpsEventFilterDebug qDebug
#else
#define qBpsEventFilterDebug QT_NO_QDEBUG_MACRO
@@ -87,7 +87,7 @@ void QQnxBpsEventFilter::installOnEventDispatcher(QAbstractEventDispatcher *disp
{
qBpsEventFilterDebug() << Q_FUNC_INFO << "dispatcher=" << dispatcher;
- if (navigator_request_events(0) != BPS_SUCCESS)
+ if (navigator_request_events(NAVIGATOR_EXTENDED_DATA) != BPS_SUCCESS)
qWarning("QQNX: failed to register for navigator events");
dispatcher->installNativeEventFilter(this);
@@ -210,6 +210,26 @@ bool QQnxBpsEventFilter::handleNavigatorEvent(bps_event_t *event)
m_navigatorEventHandler->handleExit();
break;
+ case NAVIGATOR_WINDOW_STATE: {
+ qBpsEventFilterDebug() << Q_FUNC_INFO << "WINDOW STATE event";
+ const navigator_window_state_t state = navigator_event_get_window_state(event);
+ const QByteArray id(navigator_event_get_groupid(event));
+
+ switch (state) {
+ case NAVIGATOR_WINDOW_FULLSCREEN:
+ m_navigatorEventHandler->handleWindowGroupStateChanged(id, Qt::WindowFullScreen);
+ break;
+ case NAVIGATOR_WINDOW_THUMBNAIL:
+ m_navigatorEventHandler->handleWindowGroupStateChanged(id, Qt::WindowMinimized);
+ break;
+ case NAVIGATOR_WINDOW_INVISIBLE:
+ m_navigatorEventHandler->handleWindowGroupDeactivated(id);
+ break;
+ }
+
+ break;
+ }
+
case NAVIGATOR_WINDOW_ACTIVE: {
qBpsEventFilterDebug() << Q_FUNC_INFO << "WINDOW ACTIVE event";
const QByteArray id(navigator_event_get_groupid(event));
diff --git a/src/plugins/platforms/qnx/qqnxbuffer.cpp b/src/plugins/platforms/qnx/qqnxbuffer.cpp
index 9007af7f70..c5e99a2001 100644
--- a/src/plugins/platforms/qnx/qqnxbuffer.cpp
+++ b/src/plugins/platforms/qnx/qqnxbuffer.cpp
@@ -46,7 +46,7 @@
#include <errno.h>
#include <sys/mman.h>
-#ifdef QQNXBUFFER_DEBUG
+#if defined(QQNXBUFFER_DEBUG)
#define qBufferDebug qDebug
#else
#define qBufferDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxbuttoneventnotifier.cpp b/src/plugins/platforms/qnx/qqnxbuttoneventnotifier.cpp
index 152b732556..2f531efd8b 100644
--- a/src/plugins/platforms/qnx/qqnxbuttoneventnotifier.cpp
+++ b/src/plugins/platforms/qnx/qqnxbuttoneventnotifier.cpp
@@ -49,7 +49,7 @@
#include <QtCore/QSocketNotifier>
#include <QtCore/private/qcore_unix_p.h>
-#ifdef QQNXBUTTON_DEBUG
+#if defined(QQNXBUTTON_DEBUG)
#define qButtonDebug qDebug
#else
#define qButtonDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxclipboard.cpp b/src/plugins/platforms/qnx/qqnxclipboard.cpp
index 8286febd35..dfd1345eed 100644
--- a/src/plugins/platforms/qnx/qqnxclipboard.cpp
+++ b/src/plugins/platforms/qnx/qqnxclipboard.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#ifndef QT_NO_CLIPBOARD
+#if !defined(QT_NO_CLIPBOARD)
#include "qqnxclipboard.h"
@@ -53,7 +53,7 @@
#include <clipboard/clipboard.h>
#include <errno.h>
-#ifdef QQNXCLIPBOARD_DEBUG
+#if defined(QQNXCLIPBOARD_DEBUG)
#define qClipboardDebug qDebug
#else
#define qClipboardDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxclipboard.h b/src/plugins/platforms/qnx/qqnxclipboard.h
index 0b75393efd..561b57299e 100644
--- a/src/plugins/platforms/qnx/qqnxclipboard.h
+++ b/src/plugins/platforms/qnx/qqnxclipboard.h
@@ -42,7 +42,9 @@
#ifndef QQNXCLIPBOARD_H
#define QQNXCLIPBOARD_H
-#ifndef QT_NO_CLIPBOARD
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_CLIPBOARD)
#include <qpa/qplatformclipboard.h>
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/platforms/qnx/qqnxcursor.cpp b/src/plugins/platforms/qnx/qqnxcursor.cpp
new file mode 100644
index 0000000000..3cf857bb27
--- /dev/null
+++ b/src/plugins/platforms/qnx/qqnxcursor.cpp
@@ -0,0 +1,78 @@
+/***************************************************************************
+**
+** Copyright (C) 2011 - 2012 Research In Motion
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qqnxcursor.h"
+
+#include <QtCore/QDebug>
+
+#if defined(QQNXCURSOR_DEBUG)
+#define qCursorDebug qDebug
+#else
+#define qCursorDebug QT_NO_QDEBUG_MACRO
+#endif
+
+QT_BEGIN_NAMESPACE
+
+QQnxCursor::QQnxCursor()
+{
+}
+
+#if !defined(QT_NO_CURSOR)
+void QQnxCursor::changeCursor(QCursor *windowCursor, QWindow *window)
+{
+ Q_UNUSED(windowCursor);
+ Q_UNUSED(window);
+}
+#endif
+
+void QQnxCursor::setPos(const QPoint &pos)
+{
+ qCursorDebug() << "QQnxCursor::setPos -" << pos;
+ m_pos = pos;
+}
+
+QPoint QQnxCursor::pos() const
+{
+ qCursorDebug() << "QQnxCursor::pos -" << m_pos;
+ return m_pos;
+}
+
+QT_END_NAMESPACE
diff --git a/mkspecs/unsupported/linux-android-x86-g++/qplatformdefs.h b/src/plugins/platforms/qnx/qqnxcursor.h
index 38b5f6e6d2..b62c299040 100644
--- a/mkspecs/unsupported/linux-android-x86-g++/qplatformdefs.h
+++ b/src/plugins/platforms/qnx/qqnxcursor.h
@@ -1,9 +1,9 @@
-/****************************************************************************
+/***************************************************************************
**
-** Copyright (C) 2012 Collabora Ltd, author <robin.burchell@collabora.co.uk>
+** Copyright (C) 2011 - 2012 Research In Motion
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtCore module of the Qt Toolkit.
+** This file is part of the plugins of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -39,4 +39,29 @@
**
****************************************************************************/
-#include "../../common/android/qplatformdefs.h"
+#ifndef QQNXCURSOR_H
+#define QQNXCURSOR_H
+
+#include <qpa/qplatformcursor.h>
+
+QT_BEGIN_NAMESPACE
+
+class QQnxCursor : public QPlatformCursor
+{
+public:
+ QQnxCursor();
+
+#if !defined(QT_NO_CURSOR)
+ void changeCursor(QCursor *windowCursor, QWindow *window);
+#endif
+ void setPos(const QPoint &pos);
+
+ QPoint pos() const;
+
+private:
+ QPoint m_pos;
+};
+
+QT_END_NAMESPACE
+
+#endif // QQNXCURSOR_H
diff --git a/src/plugins/platforms/qnx/qqnxfiledialoghelper.cpp b/src/plugins/platforms/qnx/qqnxfiledialoghelper.cpp
index 79d7c7d9ca..0325a33268 100644
--- a/src/plugins/platforms/qnx/qqnxfiledialoghelper.cpp
+++ b/src/plugins/platforms/qnx/qqnxfiledialoghelper.cpp
@@ -51,7 +51,7 @@
#include <QTimer>
#include <QWindow>
-#ifdef QQNXFILEDIALOGHELPER_DEBUG
+#if defined(QQNXFILEDIALOGHELPER_DEBUG)
#define qFileDialogHelperDebug qDebug
#else
#define qFileDialogHelperDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxglcontext.cpp b/src/plugins/platforms/qnx/qqnxglcontext.cpp
index 1c2ec23fa9..f77bb73614 100644
--- a/src/plugins/platforms/qnx/qqnxglcontext.cpp
+++ b/src/plugins/platforms/qnx/qqnxglcontext.cpp
@@ -50,7 +50,7 @@
#include <QtGui/QOpenGLContext>
#include <QtGui/QScreen>
-#ifdef QQNXGLCONTEXT_DEBUG
+#if defined(QQNXGLCONTEXT_DEBUG)
#define qGLContextDebug qDebug
#else
#define qGLContextDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp b/src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp
index 0d8f430c73..97a361158e 100644
--- a/src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp
+++ b/src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp
@@ -61,13 +61,13 @@
#include <process.h>
#include <sys/keycodes.h>
-#ifdef QQNXINPUTCONTEXT_IMF_EVENT_DEBUG
+#if defined(QQNXINPUTCONTEXT_IMF_EVENT_DEBUG)
#define qInputContextIMFEventDebug qDebug
#else
#define qInputContextIMFEventDebug QT_NO_QDEBUG_MACRO
#endif
-#ifdef QQNXINPUTCONTEXT_DEBUG
+#if defined(QQNXINPUTCONTEXT_DEBUG)
#define qInputContextDebug qDebug
#else
#define qInputContextDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxinputcontext_noimf.cpp b/src/plugins/platforms/qnx/qqnxinputcontext_noimf.cpp
index 71b925357a..f444d34b5e 100644
--- a/src/plugins/platforms/qnx/qqnxinputcontext_noimf.cpp
+++ b/src/plugins/platforms/qnx/qqnxinputcontext_noimf.cpp
@@ -47,7 +47,7 @@
#include <QtCore/QDebug>
#include <QtGui/QGuiApplication>
-#ifdef QQNXINPUTCONTEXT_DEBUG
+#if defined(QQNXINPUTCONTEXT_DEBUG)
#define qInputContextDebug qDebug
#else
#define qInputContextDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxintegration.cpp b/src/plugins/platforms/qnx/qqnxintegration.cpp
index f3cfdab9c6..5ea4fef698 100644
--- a/src/plugins/platforms/qnx/qqnxintegration.cpp
+++ b/src/plugins/platforms/qnx/qqnxintegration.cpp
@@ -96,7 +96,7 @@
#include <errno.h>
-#ifdef QQNXINTEGRATION_DEBUG
+#if defined(QQNXINTEGRATION_DEBUG)
#define qIntegrationDebug qDebug
#else
#define qIntegrationDebug QT_NO_QDEBUG_MACRO
@@ -495,6 +495,8 @@ void QQnxIntegration::createDisplay(screen_display_t display, bool isPrimary)
QObject::connect(m_navigatorEventHandler, SIGNAL(rotationChanged(int)), screen, SLOT(setRotation(int)));
QObject::connect(m_navigatorEventHandler, SIGNAL(windowGroupActivated(QByteArray)), screen, SLOT(activateWindowGroup(QByteArray)));
QObject::connect(m_navigatorEventHandler, SIGNAL(windowGroupDeactivated(QByteArray)), screen, SLOT(deactivateWindowGroup(QByteArray)));
+ QObject::connect(m_navigatorEventHandler, SIGNAL(windowGroupStateChanged(QByteArray,Qt::WindowState)),
+ screen, SLOT(windowGroupStateChanged(QByteArray,Qt::WindowState)));
}
void QQnxIntegration::removeDisplay(QQnxScreen *screen)
diff --git a/src/plugins/platforms/qnx/qqnxnavigatoreventhandler.cpp b/src/plugins/platforms/qnx/qqnxnavigatoreventhandler.cpp
index 19fa9c5a9f..30dbb330d7 100644
--- a/src/plugins/platforms/qnx/qqnxnavigatoreventhandler.cpp
+++ b/src/plugins/platforms/qnx/qqnxnavigatoreventhandler.cpp
@@ -45,7 +45,7 @@
#include <QGuiApplication>
#include <qpa/qwindowsysteminterface.h>
-#ifdef QQNXNAVIGATOREVENTHANDLER_DEBUG
+#if defined(QQNXNAVIGATOREVENTHANDLER_DEBUG)
#define qNavigatorEventHandlerDebug qDebug
#else
#define qNavigatorEventHandlerDebug QT_NO_QDEBUG_MACRO
@@ -106,4 +106,10 @@ void QQnxNavigatorEventHandler::handleWindowGroupDeactivated(const QByteArray &i
Q_EMIT windowGroupDeactivated(id);
}
+void QQnxNavigatorEventHandler::handleWindowGroupStateChanged(const QByteArray &id, Qt::WindowState state)
+{
+ qNavigatorEventHandlerDebug() << Q_FUNC_INFO << id;
+ Q_EMIT windowGroupStateChanged(id, state);
+}
+
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/qnx/qqnxnavigatoreventhandler.h b/src/plugins/platforms/qnx/qqnxnavigatoreventhandler.h
index 2068163473..cce3921a27 100644
--- a/src/plugins/platforms/qnx/qqnxnavigatoreventhandler.h
+++ b/src/plugins/platforms/qnx/qqnxnavigatoreventhandler.h
@@ -58,11 +58,13 @@ public:
void handleExit();
void handleWindowGroupActivated(const QByteArray &id);
void handleWindowGroupDeactivated(const QByteArray &id);
+ void handleWindowGroupStateChanged(const QByteArray &id, Qt::WindowState state);
Q_SIGNALS:
void rotationChanged(int angle);
void windowGroupActivated(const QByteArray &id);
void windowGroupDeactivated(const QByteArray &id);
+ void windowGroupStateChanged(const QByteArray &id, Qt::WindowState state);
};
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/qnx/qqnxnavigatoreventnotifier.cpp b/src/plugins/platforms/qnx/qqnxnavigatoreventnotifier.cpp
index 9fa8294815..640944fb45 100644
--- a/src/plugins/platforms/qnx/qqnxnavigatoreventnotifier.cpp
+++ b/src/plugins/platforms/qnx/qqnxnavigatoreventnotifier.cpp
@@ -55,7 +55,7 @@
#include <sys/types.h>
#include <sys/stat.h>
-#ifdef QQNXNAVIGATOREVENTNOTIFIER_DEBUG
+#if defined(QQNXNAVIGATOREVENTNOTIFIER_DEBUG)
#define qNavigatorEventNotifierDebug qDebug
#else
#define qNavigatorEventNotifierDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxnavigatorpps.cpp b/src/plugins/platforms/qnx/qqnxnavigatorpps.cpp
index 92a94e0a39..1656ab029b 100644
--- a/src/plugins/platforms/qnx/qqnxnavigatorpps.cpp
+++ b/src/plugins/platforms/qnx/qqnxnavigatorpps.cpp
@@ -44,7 +44,7 @@
#include <QDebug>
#include <private/qcore_unix_p.h>
-#ifdef QQNXNAVIGATOR_DEBUG
+#if defined(QQNXNAVIGATOR_DEBUG)
#define qNavigatorDebug qDebug
#else
#define qNavigatorDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxrasterbackingstore.cpp b/src/plugins/platforms/qnx/qqnxrasterbackingstore.cpp
index 47a72f173b..7204e5bce9 100644
--- a/src/plugins/platforms/qnx/qqnxrasterbackingstore.cpp
+++ b/src/plugins/platforms/qnx/qqnxrasterbackingstore.cpp
@@ -46,7 +46,7 @@
#include <errno.h>
-#ifdef QQNXRASTERBACKINGSTORE_DEBUG
+#if defined(QQNXRASTERBACKINGSTORE_DEBUG)
#define qRasterBackingStoreDebug qDebug
#else
#define qRasterBackingStoreDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxrootwindow.cpp b/src/plugins/platforms/qnx/qqnxrootwindow.cpp
index b01d468647..198801a832 100644
--- a/src/plugins/platforms/qnx/qqnxrootwindow.cpp
+++ b/src/plugins/platforms/qnx/qqnxrootwindow.cpp
@@ -46,7 +46,7 @@
#include <QtCore/QUuid>
#include <QtCore/QDebug>
-#ifdef QQNXROOTWINDOW_DEBUG
+#if defined(QQNXROOTWINDOW_DEBUG)
#define qRootWindowDebug qDebug
#else
#define qRootWindowDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxscreen.cpp b/src/plugins/platforms/qnx/qqnxscreen.cpp
index 1e58f047ab..7614abdc6a 100644
--- a/src/plugins/platforms/qnx/qqnxscreen.cpp
+++ b/src/plugins/platforms/qnx/qqnxscreen.cpp
@@ -41,6 +41,7 @@
#include "qqnxscreen.h"
#include "qqnxwindow.h"
+#include "qqnxcursor.h"
#include <QtCore/QThread>
#include <QtCore/QDebug>
@@ -48,7 +49,7 @@
#include <errno.h>
-#ifdef QQNXSCREEN_DEBUG
+#if defined(QQNXSCREEN_DEBUG)
#define qScreenDebug qDebug
#else
#define qScreenDebug QT_NO_QDEBUG_MACRO
@@ -110,7 +111,8 @@ QQnxScreen::QQnxScreen(screen_context_t screenContext, screen_display_t display,
m_posted(false),
m_keyboardHeight(0),
m_nativeOrientation(Qt::PrimaryOrientation),
- m_platformContext(0)
+ m_platformContext(0),
+ m_cursor(new QQnxCursor())
{
qScreenDebug() << Q_FUNC_INFO;
// Cache initial orientation of this display
@@ -149,6 +151,10 @@ QQnxScreen::QQnxScreen(screen_context_t screenContext, screen_display_t display,
QQnxScreen::~QQnxScreen()
{
qScreenDebug() << Q_FUNC_INFO;
+ Q_FOREACH (QQnxWindow *childWindow, m_childWindows)
+ childWindow->setScreen(0);
+
+ delete m_cursor;
}
static int defaultDepth()
@@ -492,6 +498,11 @@ void QQnxScreen::onWindowPost(QQnxWindow *window)
}
}
+QPlatformCursor * QQnxScreen::cursor() const
+{
+ return m_cursor;
+}
+
void QQnxScreen::keyboardHeightChanged(int height)
{
if (height == m_keyboardHeight)
@@ -542,6 +553,21 @@ void QQnxScreen::windowClosed(void *window)
removeOverlayWindow(windowHandle);
}
+void QQnxScreen::windowGroupStateChanged(const QByteArray &id, Qt::WindowState state)
+{
+ qScreenDebug() << Q_FUNC_INFO;
+
+ if (!rootWindow() || id != rootWindow()->groupName())
+ return;
+
+ QWindow * const window = topMostChildWindow();
+
+ if (!window)
+ return;
+
+ QWindowSystemInterface::handleWindowStateChanged(window, state);
+}
+
void QQnxScreen::activateWindowGroup(const QByteArray &id)
{
qScreenDebug() << Q_FUNC_INFO;
@@ -549,13 +575,12 @@ void QQnxScreen::activateWindowGroup(const QByteArray &id)
if (!rootWindow() || id != rootWindow()->groupName())
return;
- if (!m_childWindows.isEmpty()) {
- // We're picking up the last window of the list here
- // because this list is ordered by stacking order.
- // Last window is effectively the one on top.
- QWindow * const window = m_childWindows.last()->window();
- QWindowSystemInterface::handleWindowActivated(window);
- }
+ QWindow * const window = topMostChildWindow();
+
+ if (!window)
+ return;
+
+ QWindowSystemInterface::handleWindowActivated(window);
}
void QQnxScreen::deactivateWindowGroup(const QByteArray &id)
@@ -577,4 +602,17 @@ QSharedPointer<QQnxRootWindow> QQnxScreen::rootWindow() const
return m_rootWindow;
}
+QWindow * QQnxScreen::topMostChildWindow() const
+{
+ if (!m_childWindows.isEmpty()) {
+
+ // We're picking up the last window of the list here
+ // because this list is ordered by stacking order.
+ // Last window is effectively the one on top.
+ return m_childWindows.last()->window();
+ }
+
+ return 0;
+}
+
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/qnx/qqnxscreen.h b/src/plugins/platforms/qnx/qqnxscreen.h
index 2851c13c52..41dc675599 100644
--- a/src/plugins/platforms/qnx/qqnxscreen.h
+++ b/src/plugins/platforms/qnx/qqnxscreen.h
@@ -95,10 +95,13 @@ public:
QSharedPointer<QQnxRootWindow> rootWindow() const;
+ QPlatformCursor *cursor() const;
+
public Q_SLOTS:
void setRotation(int rotation);
void newWindowCreated(void *window);
void windowClosed(void *window);
+ void windowGroupStateChanged(const QByteArray &id, Qt::WindowState state);
void activateWindowGroup(const QByteArray &id);
void deactivateWindowGroup(const QByteArray &id);
@@ -112,6 +115,8 @@ private:
void addOverlayWindow(screen_window_t window);
void removeOverlayWindow(screen_window_t window);
+ QWindow *topMostChildWindow() const;
+
screen_context_t m_screenContext;
screen_display_t m_display;
mutable QSharedPointer<QQnxRootWindow> m_rootWindow;
@@ -130,6 +135,8 @@ private:
QList<QQnxWindow *> m_childWindows;
QList<screen_window_t> m_overlays;
+
+ QPlatformCursor *m_cursor;
};
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/qnx/qqnxscreeneventhandler.cpp b/src/plugins/platforms/qnx/qqnxscreeneventhandler.cpp
index 4412bb34bd..57cfdc5eb6 100644
--- a/src/plugins/platforms/qnx/qqnxscreeneventhandler.cpp
+++ b/src/plugins/platforms/qnx/qqnxscreeneventhandler.cpp
@@ -50,7 +50,7 @@
#include <errno.h>
#include <sys/keycodes.h>
-#ifdef QQNXSCREENEVENT_DEBUG
+#if defined(QQNXSCREENEVENT_DEBUG)
#define qScreenEventDebug qDebug
#else
#define qScreenEventDebug QT_NO_QDEBUG_MACRO
@@ -347,6 +347,8 @@ void QQnxScreenEventHandler::handleTouchEvent(screen_event_t event, int qnxType)
qFatal("QQNX: failed to query event position, errno=%d", errno);
}
+ QCursor::setPos(pos[0], pos[1]);
+
// get window coordinates of touch
errno = 0;
int windowPos[2];
diff --git a/src/plugins/platforms/qnx/qqnxscreeneventthread.cpp b/src/plugins/platforms/qnx/qqnxscreeneventthread.cpp
index 8f262a7083..f3f660bc03 100644
--- a/src/plugins/platforms/qnx/qqnxscreeneventthread.cpp
+++ b/src/plugins/platforms/qnx/qqnxscreeneventthread.cpp
@@ -49,7 +49,7 @@
#include <cctype>
-#ifdef QQNXSCREENEVENTTHREAD_DEBUG
+#if defined(QQNXSCREENEVENTTHREAD_DEBUG)
#define qScreenEventThreadDebug qDebug
#else
#define qScreenEventThreadDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxtheme.cpp b/src/plugins/platforms/qnx/qqnxtheme.cpp
index e8e9e39388..733b7223b6 100644
--- a/src/plugins/platforms/qnx/qqnxtheme.cpp
+++ b/src/plugins/platforms/qnx/qqnxtheme.cpp
@@ -80,10 +80,10 @@ QPlatformDialogHelper *QQnxTheme::createPlatformDialogHelper(DialogType type) co
case QPlatformTheme::FileDialog:
return new QQnxFileDialogHelper(m_integration);
#endif
-#ifndef QT_NO_COLORDIALOG
+#if !defined(QT_NO_COLORDIALOG)
case QPlatformTheme::ColorDialog:
#endif
-#ifndef QT_NO_FONTDIALOG
+#if !defined(QT_NO_FONTDIALOG)
case QPlatformTheme::FontDialog:
#endif
default:
diff --git a/src/plugins/platforms/qnx/qqnxvirtualkeyboardbps.cpp b/src/plugins/platforms/qnx/qqnxvirtualkeyboardbps.cpp
index 3d2f49aa6c..11eb4a5082 100644
--- a/src/plugins/platforms/qnx/qqnxvirtualkeyboardbps.cpp
+++ b/src/plugins/platforms/qnx/qqnxvirtualkeyboardbps.cpp
@@ -47,7 +47,7 @@
#include <bps/locale.h>
#include <bps/virtualkeyboard.h>
-#ifdef QQNXVIRTUALKEYBOARD_DEBUG
+#if defined(QQNXVIRTUALKEYBOARD_DEBUG)
#define qVirtualKeyboardDebug qDebug
#else
#define qVirtualKeyboardDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxvirtualkeyboardpps.cpp b/src/plugins/platforms/qnx/qqnxvirtualkeyboardpps.cpp
index ab912927bb..e810b47c22 100644
--- a/src/plugins/platforms/qnx/qqnxvirtualkeyboardpps.cpp
+++ b/src/plugins/platforms/qnx/qqnxvirtualkeyboardpps.cpp
@@ -56,7 +56,7 @@
#include <sys/types.h>
#include <unistd.h>
-#ifdef QQNXVIRTUALKEYBOARD_DEBUG
+#if defined(QQNXVIRTUALKEYBOARD_DEBUG)
#define qVirtualKeyboardDebug qDebug
#else
#define qVirtualKeyboardDebug QT_NO_QDEBUG_MACRO
diff --git a/src/plugins/platforms/qnx/qqnxvirtualkeyboardpps.h b/src/plugins/platforms/qnx/qqnxvirtualkeyboardpps.h
index eb41b2efd0..6048868b08 100644
--- a/src/plugins/platforms/qnx/qqnxvirtualkeyboardpps.h
+++ b/src/plugins/platforms/qnx/qqnxvirtualkeyboardpps.h
@@ -39,8 +39,8 @@
**
****************************************************************************/
-#ifndef VIRTUALKEYBOARDPPS_H_
-#define VIRTUALKEYBOARDPPS_H_
+#ifndef VIRTUALKEYBOARDPPS_H
+#define VIRTUALKEYBOARDPPS_H
#include "qqnxabstractvirtualkeyboard.h"
@@ -97,4 +97,4 @@ private:
static const size_t ms_bufferSize;
};
-#endif /* VIRTUALKEYBOARDPPS_H_ */
+#endif // VIRTUALKEYBOARDPPS_H
diff --git a/src/plugins/platforms/qnx/qqnxwindow.cpp b/src/plugins/platforms/qnx/qqnxwindow.cpp
index ab9c94772b..f1bebee9b2 100644
--- a/src/plugins/platforms/qnx/qqnxwindow.cpp
+++ b/src/plugins/platforms/qnx/qqnxwindow.cpp
@@ -40,7 +40,7 @@
****************************************************************************/
#include "qqnxwindow.h"
-#ifndef QT_NO_OPENGL
+#if !defined(QT_NO_OPENGL)
#include "qqnxglcontext.h"
#endif
#include "qqnxintegration.h"
@@ -53,7 +53,12 @@
#include <errno.h>
-#ifdef QQNXWINDOW_DEBUG
+#if defined(Q_OS_BLACKBERRY)
+#include <sys/pps.h>
+#include <bps/navigator.h>
+#endif
+
+#if defined(QQNXWINDOW_DEBUG)
#define qWindowDebug qDebug
#else
#define qWindowDebug QT_NO_QDEBUG_MACRO
@@ -67,7 +72,7 @@ QQnxWindow::QQnxWindow(QWindow *window, screen_context_t context)
m_window(0),
m_currentBufferIndex(-1),
m_previousBufferIndex(-1),
-#ifndef QT_NO_OPENGL
+#if !defined(QT_NO_OPENGL)
m_platformOpenGLContext(0),
#endif
m_screen(0),
@@ -156,7 +161,8 @@ QQnxWindow::~QQnxWindow()
// Remove from parent's Hierarchy.
removeFromParent();
- m_screen->updateHierarchy();
+ if (m_screen)
+ m_screen->updateHierarchy();
// Cleanup QNX window and its buffers
screen_destroy_window(m_window);
@@ -272,9 +278,9 @@ void QQnxWindow::setVisible(bool visible)
window()->requestActivate();
if (window()->isTopLevel()) {
- if (visible) {
- QWindowSystemInterface::handleExposeEvent(window(), window()->geometry());
- } else {
+ QWindowSystemInterface::handleExposeEvent(window(), window()->geometry());
+
+ if (!visible) {
// Flush the context, otherwise it won't disappear immediately
screen_flush_context(m_screenContext, 0);
}
@@ -347,7 +353,7 @@ void QQnxWindow::setBufferSize(const QSize &size)
// Create window buffers if they do not exist
if (m_bufferSize.isEmpty()) {
-#ifndef QT_NO_OPENGL
+#if !defined(QT_NO_OPENGL)
// Get pixel format from EGL config if using OpenGL;
// otherwise inherit pixel format of window's screen
if (m_platformOpenGLContext != 0) {
@@ -497,6 +503,11 @@ void QQnxWindow::setScreen(QQnxScreen *platformScreen)
{
qWindowDebug() << Q_FUNC_INFO << "window =" << window() << "platformScreen =" << platformScreen;
+ if (platformScreen == 0) { // The screen has been destroyed
+ m_screen = 0;
+ return;
+ }
+
if (m_screen == platformScreen)
return;
@@ -539,7 +550,7 @@ void QQnxWindow::removeFromParent()
m_parentWindow = 0;
else
qFatal("QQnxWindow: Window Hierarchy broken; window has parent, but parent hasn't got child.");
- } else {
+ } else if (m_screen) {
m_screen->removeWindow(this);
}
}
@@ -618,12 +629,20 @@ void QQnxWindow::setWindowState(Qt::WindowState state)
switch (state) {
- // WindowMinimized is not supported - navigator does not have an API to minimize a window
// WindowActive is not an accepted parameter according to the docs
- case Qt::WindowMinimized:
case Qt::WindowActive:
return;
+ case Qt::WindowMinimized:
+ minimize();
+
+ if (m_unmaximizedGeometry.isValid())
+ setGeometry(m_unmaximizedGeometry);
+ else
+ setGeometry(m_screen->geometry());
+
+ break;
+
case Qt::WindowMaximized:
case Qt::WindowFullScreen:
m_unmaximizedGeometry = geometry();
@@ -647,7 +666,7 @@ void QQnxWindow::gainedFocus()
QWindowSystemInterface::handleWindowActivated(window());
}
-#ifndef QT_NO_OPENGL
+#if !defined(QT_NO_OPENGL)
void QQnxWindow::setPlatformOpenGLContext(QQnxGLContext *platformOpenGLContext)
{
// This function does not take ownership of the platform gl context.
@@ -683,6 +702,27 @@ void QQnxWindow::blitFrom(QQnxWindow *sourceWindow, const QPoint &sourceOffset,
blitHelper(sourceBuffer, targetBuffer, sourceOffset, QPoint(0, 0), targetRegion, true);
}
+void QQnxWindow::minimize()
+{
+#if defined(Q_OS_BLACKBERRY) && !defined(Q_OS_BLACKBERRY_TABLET)
+ qWindowDebug() << Q_FUNC_INFO;
+
+ pps_encoder_t encoder;
+
+ pps_encoder_initialize(&encoder, false);
+ pps_encoder_add_string(&encoder, "msg", "minimizeWindow");
+
+ if (navigator_raw_write(pps_encoder_buffer(&encoder),
+ pps_encoder_length(&encoder)) != BPS_SUCCESS) {
+ qWindowDebug() << Q_FUNC_INFO << "navigator_raw_write failed:" << strerror(errno);
+ }
+
+ pps_encoder_cleanup(&encoder);
+#else
+ qWarning("Qt::WindowMinimized is not supported by this OS version");
+#endif
+}
+
void QQnxWindow::updateZorder(int &topZorder)
{
errno = 0;
diff --git a/src/plugins/platforms/qnx/qqnxwindow.h b/src/plugins/platforms/qnx/qqnxwindow.h
index 90226bb9a4..4a327fd54b 100644
--- a/src/plugins/platforms/qnx/qqnxwindow.h
+++ b/src/plugins/platforms/qnx/qqnxwindow.h
@@ -49,7 +49,7 @@
#include <QtGui/QImage>
#include <QtCore/QMutex>
-#ifndef QT_NO_OPENGL
+#if !defined(QT_NO_OPENGL)
#include <EGL/egl.h>
#endif
@@ -60,7 +60,7 @@ QT_BEGIN_NAMESPACE
// all surfaces double buffered
#define MAX_BUFFER_COUNT 2
-#ifndef QT_NO_OPENGL
+#if !defined(QT_NO_OPENGL)
class QQnxGLContext;
#endif
class QQnxScreen;
@@ -108,7 +108,7 @@ public:
QQnxScreen *screen() const { return m_screen; }
const QList<QQnxWindow*>& children() const { return m_childWindows; }
-#ifndef QT_NO_OPENGL
+#if !defined(QT_NO_OPENGL)
void setPlatformOpenGLContext(QQnxGLContext *platformOpenGLContext);
QQnxGLContext *platformOpenGLContext() const { return m_platformOpenGLContext; }
#endif
@@ -116,6 +116,7 @@ public:
QQnxWindow *findWindow(screen_window_t windowHandle);
void blitFrom(QQnxWindow *sourceWindow, const QPoint &sourceOffset, const QRegion &targetRegion);
+ void minimize();
private:
QRect setGeometryHelper(const QRect &rect);
@@ -143,7 +144,7 @@ private:
QRegion m_previousDirty;
QRegion m_scrolled;
-#ifndef QT_NO_OPENGL
+#if !defined(QT_NO_OPENGL)
QQnxGLContext *m_platformOpenGLContext;
#endif
QQnxScreen *m_screen;
diff --git a/src/plugins/platforms/windows/accessible/iaccessible2.cpp b/src/plugins/platforms/windows/accessible/iaccessible2.cpp
index 164bd6eed9..7a28fd9074 100644
--- a/src/plugins/platforms/windows/accessible/iaccessible2.cpp
+++ b/src/plugins/platforms/windows/accessible/iaccessible2.cpp
@@ -44,7 +44,7 @@
#include "iaccessible2.h"
#include "qwindowsaccessibility.h"
-#include <QtGui/qaccessible2.h>
+#include <QtGui/private/qaccessible2_p.h>
#include <QtGui/qclipboard.h>
#include <QtWidgets/qapplication.h>
#include <QtCore/qdebug.h>
@@ -230,6 +230,10 @@ HRESULT STDMETHODCALLTYPE AccessibleRelation::get_targets(
**************************************************************/
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::QueryInterface(REFIID id, LPVOID *iface)
{
+ QAccessibleInterface *accessible = accessibleInterface();
+ if (!accessible)
+ return E_NOINTERFACE;
+
HRESULT hr = QWindowsMsaaAccessible::QueryInterface(id, iface);
if (!SUCCEEDED(hr)) {
if (id == IID_IServiceProvider) {
@@ -301,10 +305,11 @@ ULONG STDMETHODCALLTYPE QWindowsIA2Accessible::Release()
**************************************************************/
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nRelations(long *nRelations)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (!nRelations)
return E_INVALIDARG;
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
return getRelationsHelper(0, 0, 0, nRelations);
@@ -312,10 +317,11 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nRelations(long *nRelations
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_relation(long relationIndex, IAccessibleRelation **relation)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (!relation)
return E_INVALIDARG;
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
return getRelationsHelper(relation, relationIndex, 1);
@@ -330,8 +336,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_relations(long maxRelations
IAccessibleRelation **relations,
long *nRelations)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
return getRelationsHelper(relations, 0, maxRelations, nRelations);
@@ -340,8 +347,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_relations(long maxRelations
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::role(long *ia2role)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
long r = accessible->role();
@@ -386,8 +394,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_groupPosition(long *groupLe
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_states(AccessibleStates *states)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (!states)
return E_POINTER;
@@ -462,23 +471,23 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_localizedExtendedStates(lon
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_uniqueID(long *outUniqueID)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
- // ### FIXME SERIOUSLY, NOT A STABLE SOLUTION IF NODES ARE DELETED ETC
- // Return 0 if no object and no parent. This is really an error case.
- uint uid = uniqueID();
- accessibleDebug("uniqueID: %08x", uid);
- *outUniqueID = (long)uid;
- return uid ? S_OK : S_FALSE;
+ accessibleDebug("uniqueID: %08x", id);
+
+ *outUniqueID = (long)id;
+ return int(id) < 0 ? S_OK : S_FALSE;
}
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_windowHandle(HWND *windowHandle)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
return GetWindow(windowHandle);
}
@@ -486,8 +495,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_windowHandle(HWND *windowHa
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_indexInParent(long *indexInParent)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (!indexInParent)
return E_INVALIDARG;
@@ -497,7 +507,6 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_indexInParent(long *indexIn
return S_FALSE;
}
int indexOfChild = par->indexOfChild(accessible);
- delete par;
Q_ASSERT(indexOfChild >= 0);
*indexInParent = indexOfChild;
return S_OK;
@@ -505,8 +514,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_indexInParent(long *indexIn
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_locale(IA2Locale *locale)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
IA2Locale res;
QLocale l;
@@ -519,8 +529,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_locale(IA2Locale *locale)
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_attributes(BSTR *attributes)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*attributes = 0;//QStringToBSTR(QString());
return S_FALSE;
@@ -531,8 +542,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_attributes(BSTR *attributes
**************************************************************/
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::nActions(long *nActions)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*nActions = 0;
@@ -543,8 +555,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::nActions(long *nActions)
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::doAction(long actionIndex)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleActionInterface *actionIface = actionInterface()) {
const QStringList actionNames = actionIface->actionNames();
@@ -559,8 +572,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::doAction(long actionIndex)
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_description(long actionIndex, BSTR *description)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*description = 0;
if (QAccessibleActionInterface *actionIface = actionInterface()) {
@@ -575,8 +589,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_description(long actionInde
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_keyBinding(long actionIndex, long nMaxBindings, BSTR **keyBindings, long *nBindings)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
Q_UNUSED(nMaxBindings);
BSTR *arrayOfBindingsToReturn = 0;
@@ -603,8 +618,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_keyBinding(long actionIndex
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_name(long actionIndex, BSTR *name)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*name = 0;
if (QAccessibleActionInterface *actionIface = actionInterface()) {
@@ -619,8 +635,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_name(long actionIndex, BSTR
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_localizedName(long actionIndex, BSTR *localizedName)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*localizedName = 0;
if (QAccessibleActionInterface *actionIface = actionInterface()) {
@@ -639,13 +656,15 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_localizedName(long actionIn
**************************************************************/
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_locationInParent(long *x, long *y)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
QPoint topLeft = accessible->rect().topLeft();
- if (QAccessibleInterface *parentIface = accessible->parent())
+ QAccessibleInterface *parentIface = accessible->parent();
+ if (parentIface && parentIface->isValid())
topLeft -= parentIface->rect().topLeft();
*x = topLeft.x();
@@ -655,8 +674,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_locationInParent(long *x, l
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_foreground(IA2Color *foreground)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
// IA2Color is a typedef for long
@@ -666,8 +686,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_foreground(IA2Color *foregr
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_background(IA2Color *background)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
// IA2Color is a typedef for long
@@ -686,6 +707,8 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_background(IA2Color *backgr
*/
QString QWindowsIA2Accessible::textForRange(int startOffset, int endOffset) const
{
+ QAccessibleInterface *accessible = accessibleInterface();
+
if (QAccessibleTextInterface *textIface = accessible->textInterface()) {
if (endOffset == IA2_TEXT_OFFSET_LENGTH)
endOffset = textIface->characterCount();
@@ -703,6 +726,7 @@ QString QWindowsIA2Accessible::textForRange(int startOffset, int endOffset) cons
*/
void QWindowsIA2Accessible::replaceTextFallback(long startOffset, long endOffset, const QString &txt)
{
+ QAccessibleInterface *accessible = accessibleInterface();
QString t = textForRange(0, -1);
if (endOffset == IA2_TEXT_OFFSET_LENGTH)
endOffset = t.length();
@@ -716,6 +740,7 @@ void QWindowsIA2Accessible::replaceTextFallback(long startOffset, long endOffset
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::copyText(long startOffset, long endOffset)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
#ifndef QT_NO_CLIPBOARD
const QString t = textForRange(startOffset, endOffset);
@@ -728,6 +753,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::copyText(long startOffset, long
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::deleteText(long startOffset, long endOffset)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleEditableTextInterface *editableTextIface = accessible->editableTextInterface())
editableTextIface->deleteText(startOffset, endOffset);
@@ -738,6 +764,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::deleteText(long startOffset, lo
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::insertText(long offset, BSTR *text)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
const QString txt(BSTRToQString(*text));
if (QAccessibleEditableTextInterface *editableTextIface = accessible->editableTextInterface())
@@ -749,6 +776,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::insertText(long offset, BSTR *t
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::cutText(long startOffset, long endOffset)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
#ifndef QT_NO_CLIPBOARD
const QString t = textForRange(startOffset, endOffset);
@@ -765,6 +793,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::cutText(long startOffset, long
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::pasteText(long offset)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
#ifndef QT_NO_CLIPBOARD
const QString txt = QGuiApplication::clipboard()->text();
@@ -780,6 +809,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::pasteText(long offset)
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::replaceText(long startOffset, long endOffset, BSTR *text)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
const QString txt(BSTRToQString(*text));
if (QAccessibleEditableTextInterface *editableTextIface = accessible->editableTextInterface())
@@ -800,8 +830,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::setAttributes(long /*startOffse
**************************************************************/
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_cellAt( long row, long column, IUnknown **cell)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*cell = 0;
@@ -816,8 +847,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_cellAt( long row, long colu
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_caption( IUnknown **captionInterface)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*captionInterface = 0;
@@ -830,8 +862,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_caption( IUnknown **caption
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_columnDescription( long column, BSTR *description)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*description = 0;
@@ -845,8 +878,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_columnDescription( long col
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nColumns( long *columnCount)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -858,8 +892,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nColumns( long *columnCount
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nRows(long *rowCount)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -871,8 +906,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nRows(long *rowCount)
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nSelectedCells(long *cellCount)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -884,8 +920,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nSelectedCells(long *cellCo
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nSelectedColumns(long *columnCount)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -897,8 +934,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nSelectedColumns(long *colu
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nSelectedRows(long *rowCount)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -910,8 +948,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nSelectedRows(long *rowCoun
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_rowDescription(long row, BSTR *description)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*description = 0;
@@ -925,10 +964,11 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_rowDescription(long row, BS
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_selectedCells(IUnknown ***cells, long *nSelectedCells)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
Q_UNUSED(cells);
Q_UNUSED(nSelectedCells);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
QList<QAccessibleInterface*> selectedCells = tableInterface()->selectedCells();
@@ -937,8 +977,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_selectedCells(IUnknown ***c
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_selectedColumns(long **selectedColumns, long *nColumns)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -957,8 +998,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_selectedColumns(long **sele
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_selectedRows(long **selectedRows, long *nRows)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -977,8 +1019,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_selectedRows(long **selecte
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_summary(IUnknown **summaryInterface)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*summaryInterface = 0;
@@ -991,8 +1034,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_summary(IUnknown **summaryI
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_isColumnSelected(long column, boolean *isSelected)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -1004,8 +1048,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_isColumnSelected(long colum
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_isRowSelected(long row, boolean *isSelected)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -1017,8 +1062,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_isRowSelected(long row, boo
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::selectRow(long row)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -1030,8 +1076,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::selectRow(long row)
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::selectColumn(long column)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -1043,8 +1090,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::selectColumn(long column)
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::unselectRow(long row)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -1056,8 +1104,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::unselectRow(long row)
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::unselectColumn(long column)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleTableInterface *tableIface = tableInterface()) {
@@ -1069,8 +1118,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::unselectColumn(long column)
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_modelChange( IA2TableModelChange * /*modelChange*/)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
return E_NOTIMPL;
}
@@ -1080,8 +1130,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_modelChange( IA2TableModelC
\**************************************************************/
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_columnExtent(long *nColumnsSpanned)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*nColumnsSpanned = tableCellInterface()->columnExtent();
@@ -1091,8 +1142,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_columnExtent(long *nColumns
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_columnHeaderCells(IUnknown ***cellAccessibles,
long *nColumnHeaderCells)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
const QList<QAccessibleInterface*> headerCells = tableCellInterface()->columnHeaderCells();
return wrapListOfCells(headerCells, cellAccessibles, nColumnHeaderCells);
@@ -1100,8 +1152,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_columnHeaderCells(IUnknown
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_columnIndex(long *columnIndex)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*columnIndex = tableCellInterface()->columnIndex();
return S_OK;
@@ -1109,8 +1162,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_columnIndex(long *columnInd
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_rowExtent(long *nRowsSpanned)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*nRowsSpanned = tableCellInterface()->rowExtent();
return S_OK;
@@ -1119,8 +1173,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_rowExtent(long *nRowsSpanne
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_rowHeaderCells(IUnknown ***cellAccessibles,
long *nRowHeaderCells)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
const QList<QAccessibleInterface*> headerCells = tableCellInterface()->rowHeaderCells();
return wrapListOfCells(headerCells, cellAccessibles, nRowHeaderCells);
@@ -1128,8 +1183,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_rowHeaderCells(IUnknown ***
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_rowIndex(long *rowIndex)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*rowIndex = tableCellInterface()->rowIndex();
return S_OK;
@@ -1137,8 +1193,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_rowIndex(long *rowIndex)
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_isSelected( boolean *isSelected)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*isSelected = tableCellInterface()->isSelected();
return S_OK;
@@ -1148,8 +1205,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_rowColumnExtents(long *row,
long *rowExtents, long *columnExtents,
boolean *isSelected)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
tableCellInterface()->rowColumnExtents((int*)row, (int*)column, (int*)rowExtents, (int*)columnExtents, (bool*)isSelected);
@@ -1158,8 +1216,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_rowColumnExtents(long *row,
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_table(IUnknown **table)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
QAccessibleInterface *tableIface = tableCellInterface()->table();
@@ -1174,6 +1233,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_table(IUnknown **table)
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::addSelection(long startOffset,
long endOffset)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *text = textInterface()) {
text->addSelection(startOffset, endOffset);
@@ -1187,6 +1247,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_attributes(long offset,
long *endOffset,
BSTR *textAttributes)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *text = textInterface()) {
const QString attrs = text->attributes(offset, (int*)startOffset, (int*)endOffset);
@@ -1198,6 +1259,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_attributes(long offset,
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_caretOffset(long *offset)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *text = textInterface()) {
*offset = text->cursorPosition();
@@ -1214,6 +1276,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_characterExtents(long offse
long *width,
long *height)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *text = textInterface()) {
QRect rect = text->characterRect(offset);
@@ -1227,6 +1290,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_characterExtents(long offse
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nSelections(long *nSelections)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *text = textInterface()) {
*nSelections = text->selectionCount();
@@ -1240,6 +1304,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_offsetAtPoint(long x,
enum IA2CoordinateType coordType,
long *offset)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *text = textInterface()) {
QPoint screenPos = mapToScreenPos(coordType, x, y);
@@ -1254,6 +1319,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_selection(long selectionInd
long *startOffset,
long *endOffset)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *text = textInterface()) {
text->selection(selectionIndex, (int*)startOffset, (int*)endOffset);
@@ -1266,6 +1332,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_text(long startOffset,
long endOffset,
BSTR *text)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *textif = textInterface()) {
const QString t = textif->text(startOffset, endOffset);
@@ -1284,9 +1351,10 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_textBeforeOffset(long offse
long *endOffset,
BSTR *text)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *textIface = textInterface()) {
- const QString txt = textIface->textBeforeOffset(offset, (QAccessible2::BoundaryType)boundaryType, (int*)startOffset, (int*)endOffset);
+ const QString txt = textIface->textBeforeOffset(offset, (QAccessible::TextBoundaryType)boundaryType, (int*)startOffset, (int*)endOffset);
if (!txt.isEmpty()) {
*text = QStringToBSTR(txt);
return S_OK;
@@ -1303,9 +1371,10 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_textAfterOffset(
long *endOffset,
BSTR *text)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *textIface = textInterface()) {
- const QString txt = textIface->textAfterOffset(offset, (QAccessible2::BoundaryType)boundaryType, (int*)startOffset, (int*)endOffset);
+ const QString txt = textIface->textAfterOffset(offset, (QAccessible::TextBoundaryType)boundaryType, (int*)startOffset, (int*)endOffset);
if (!txt.isEmpty()) {
*text = QStringToBSTR(txt);
return S_OK;
@@ -1321,9 +1390,10 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_textAtOffset(long offset,
long *endOffset,
BSTR *text)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *textIface = textInterface()) {
- const QString txt = textIface->textAtOffset(offset, (QAccessible2::BoundaryType)boundaryType, (int*)startOffset, (int*)endOffset);
+ const QString txt = textIface->textAtOffset(offset, (QAccessible::TextBoundaryType)boundaryType, (int*)startOffset, (int*)endOffset);
if (!txt.isEmpty()) {
*text = QStringToBSTR(txt);
return S_OK;
@@ -1335,6 +1405,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_textAtOffset(long offset,
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::removeSelection(long selectionIndex)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *textIface = textInterface()) {
textIface->removeSelection(selectionIndex);
@@ -1345,6 +1416,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::removeSelection(long selectionI
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::setCaretOffset(long offset)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *textIface = textInterface()) {
textIface->setCursorPosition(offset);
@@ -1357,6 +1429,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::setSelection(long selectionInde
long startOffset,
long endOffset)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *textIface = textInterface()) {
textIface->setSelection(selectionIndex, startOffset, endOffset);
@@ -1367,6 +1440,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::setSelection(long selectionInde
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_nCharacters(long *nCharacters)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *textIface = textInterface()) {
*nCharacters = textIface->characterCount();
@@ -1379,6 +1453,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::scrollSubstringTo(long startInd
long endIndex,
enum IA2ScrollType scrollType)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (QAccessibleTextInterface *textIface = textInterface()) {
Q_UNUSED(scrollType); //###
@@ -1420,8 +1495,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_oldText(IA2TextSegment *old
**************************************************************/
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_currentValue(VARIANT *currentValue)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleValueInterface *valueIface = valueInterface()) {
const QVariant var = valueIface->currentValue();
@@ -1435,8 +1511,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_currentValue(VARIANT *curre
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::setCurrentValue(VARIANT value)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
HRESULT hr = S_FALSE;
if (QAccessibleValueInterface *valueIface = valueInterface()) {
@@ -1451,8 +1528,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::setCurrentValue(VARIANT value)
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_maximumValue(VARIANT *maximumValue)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleValueInterface *valueIface = valueInterface()) {
const QVariant var = valueIface->maximumValue();
@@ -1465,8 +1543,9 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_maximumValue(VARIANT *maxim
HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::get_minimumValue(VARIANT *minimumValue)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleValueInterface *valueIface = valueInterface()) {
const QVariant var = valueIface->minimumValue();
@@ -1538,6 +1617,7 @@ HRESULT STDMETHODCALLTYPE QWindowsIA2Accessible::QueryService(REFGUID guidServic
*/
HRESULT QWindowsIA2Accessible::getRelationsHelper(IAccessibleRelation **relations, int startIndex, long maxRelations, long *nRelations /* = 0*/)
{
+ QAccessibleInterface *accessible = accessibleInterface();
if (nRelations)
*nRelations = 0;
typedef QPair<QAccessibleInterface *, QAccessible::Relation> RelationEntry;
@@ -1587,37 +1667,6 @@ HRESULT QWindowsIA2Accessible::wrapListOfCells(const QList<QAccessibleInterface*
return count > 0 ? S_OK : S_FALSE;
}
-uint QWindowsIA2Accessible::uniqueID() const
-{
- uint uid = 0;
- if (QObject *obj = accessible->object())
- uid = qHash(obj);
-
- if (!uid) {
- QAccessibleInterface *acc = accessible;
- QVector<int> indexOfNodes;
- while (acc && !acc->object()) {
- QAccessibleInterface *par = acc->parent();
- indexOfNodes.append(par->indexOfChild(acc));
- if (acc != accessible)
- delete acc;
- acc = par;
- }
- if (acc) {
- if (acc->object()) {
- uid = qHash(acc->object());
- for (int i = 0; i < indexOfNodes.count(); ++i)
- uid = qHash(uid + indexOfNodes.at(i));
-
- }
- if (acc != accessible)
- delete acc;
- }
- }
- return uid;
-}
-
-
#define IF_EQUAL_RETURN_IIDSTRING(id, iid) if (id == iid) return QByteArray(#iid)
QByteArray QWindowsIA2Accessible::IIDToString(REFIID id)
diff --git a/src/plugins/platforms/windows/accessible/iaccessible2.h b/src/plugins/platforms/windows/accessible/iaccessible2.h
index af9698b9b2..a391d495f9 100644
--- a/src/plugins/platforms/windows/accessible/iaccessible2.h
+++ b/src/plugins/platforms/windows/accessible/iaccessible2.h
@@ -132,7 +132,7 @@ public:
/* IAccessibleTable2 */
HRESULT STDMETHODCALLTYPE get_cellAt( long row, long column, IUnknown **cell);
- HRESULT STDMETHODCALLTYPE get_caption( IUnknown **accessible);
+ HRESULT STDMETHODCALLTYPE get_caption( IUnknown **accessibleInterface);
HRESULT STDMETHODCALLTYPE get_columnDescription( long column, BSTR *description);
HRESULT STDMETHODCALLTYPE get_nColumns( long *columnCount);
HRESULT STDMETHODCALLTYPE get_nRows( long *rowCount);
@@ -143,7 +143,7 @@ public:
HRESULT STDMETHODCALLTYPE get_selectedCells( IUnknown ***cells, long *nSelectedCells);
HRESULT STDMETHODCALLTYPE get_selectedColumns( long **selectedColumns, long *nColumns);
HRESULT STDMETHODCALLTYPE get_selectedRows( long **selectedRows, long *nRows);
- HRESULT STDMETHODCALLTYPE get_summary( IUnknown **accessible);
+ HRESULT STDMETHODCALLTYPE get_summary( IUnknown **accessibleInterface);
HRESULT STDMETHODCALLTYPE get_isColumnSelected( long column, boolean *isSelected);
HRESULT STDMETHODCALLTYPE get_isRowSelected( long row, boolean *isSelected);
HRESULT STDMETHODCALLTYPE selectRow( long row);
@@ -206,22 +206,27 @@ public:
/* private helper functions */
private:
inline QAccessibleTextInterface *textInterface() const {
- return accessible->isValid() ? accessible->textInterface() : static_cast<QAccessibleTextInterface *>(0);
+ QAccessibleInterface *accessible = accessibleInterface();
+ return accessible ? accessible->textInterface() : static_cast<QAccessibleTextInterface *>(0);
}
inline QAccessibleActionInterface *actionInterface() const {
+ QAccessibleInterface *accessible = accessibleInterface();
return accessible->actionInterface();
}
inline QAccessibleValueInterface *valueInterface() const {
+ QAccessibleInterface *accessible = accessibleInterface();
return accessible->valueInterface();
}
inline QAccessibleTableInterface *tableInterface() const {
+ QAccessibleInterface *accessible = accessibleInterface();
return accessible->tableInterface();
}
inline QAccessibleTableCellInterface *tableCellInterface() const {
+ QAccessibleInterface *accessible = accessibleInterface();
return accessible->tableCellInterface();
}
@@ -231,6 +236,7 @@ private:
\a x and \y (out) is in parent relative position if coordType == IA2_COORDTYPE_PARENT_RELATIVE
*/
void mapFromScreenPos(enum IA2CoordinateType coordType, const QPoint &screenPos, long *x, long *y) const {
+ QAccessibleInterface *accessible = accessibleInterface();
if (coordType == IA2_COORDTYPE_PARENT_RELATIVE) {
// caller wants relative to parent
if (QAccessibleInterface *parent = accessible->parent()) {
@@ -250,6 +256,7 @@ private:
\return a screen relative position
*/
QPoint mapToScreenPos(enum IA2CoordinateType coordType, long x, long y) const {
+ QAccessibleInterface *accessible = accessibleInterface();
if (coordType == IA2_COORDTYPE_PARENT_RELATIVE) {
if (QAccessibleInterface *parent = accessible->parent()) {
const QRect parentScreenRect = parent->rect();
@@ -261,7 +268,6 @@ private:
HRESULT getRelationsHelper(IAccessibleRelation **relations, int startIndex, long maxRelations, long *nRelations = 0);
HRESULT wrapListOfCells(const QList<QAccessibleInterface*> &inputCells, IUnknown ***outputAccessibles, long *nCellCount);
- uint uniqueID() const;
QByteArray IIDToString(REFIID id);
QString textForRange(int startOffset, int endOffset) const;
void replaceTextFallback(long startOffset, long endOffset, const QString &txt);
diff --git a/src/plugins/platforms/windows/accessible/qwindowsaccessibility.cpp b/src/plugins/platforms/windows/accessible/qwindowsaccessibility.cpp
index 3ccc6212a9..f222deeeac 100644
--- a/src/plugins/platforms/windows/accessible/qwindowsaccessibility.cpp
+++ b/src/plugins/platforms/windows/accessible/qwindowsaccessibility.cpp
@@ -51,7 +51,7 @@
#include <QtCore/qpointer.h>
#include <QtCore/qsettings.h>
#include <QtGui/qaccessible.h>
-#include <QtGui/qaccessible2.h>
+#include <QtGui/private/qaccessible2_p.h>
#include <qpa/qplatformnativeinterface.h>
#include <QtGui/qwindow.h>
#include <QtGui/qguiapplication.h>
@@ -86,14 +86,8 @@
#include "../qtwindows_additional.h"
-
-// This stuff is used for widgets/items with no window handle:
-typedef QMap<int, QPair<QPointer<QObject>,int> > NotifyMap;
-Q_GLOBAL_STATIC(NotifyMap, qAccessibleRecentSentEvents)
-
QT_BEGIN_NAMESPACE
-
/*!
\!internal
\class QWindowsAccessibility
@@ -162,26 +156,16 @@ void QWindowsAccessibility::notifyAccessibilityUpdate(QAccessibleEvent *event)
}
}
- typedef void (WINAPI *PtrNotifyWinEvent)(DWORD, HWND, LONG, LONG);
-
#if defined(Q_OS_WINCE) // ### TODO: check for NotifyWinEvent in CE 6.0
// There is no user32.lib nor NotifyWinEvent for CE
return;
#else
- static PtrNotifyWinEvent ptrNotifyWinEvent = 0;
- static bool resolvedNWE = false;
- if (!resolvedNWE) {
- resolvedNWE = true;
- ptrNotifyWinEvent = (PtrNotifyWinEvent)QSystemLibrary::resolve(QLatin1String("user32"), "NotifyWinEvent");
- }
- if (!ptrNotifyWinEvent)
- return;
-
// An event has to be associated with a window,
// so find the first parent that is a widget and that has a WId
QAccessibleInterface *iface = event->accessibleInterface();
- QWindow *window = iface ? QWindowsAccessibility::windowHelper(iface) : 0;
- delete iface;
+ if (!iface) // ### This should not happen, maybe make it an assert.
+ return;
+ QWindow *window = QWindowsAccessibility::windowHelper(iface);
if (!window) {
window = QGuiApplication::focusWindow();
@@ -194,27 +178,9 @@ void QWindowsAccessibility::notifyAccessibilityUpdate(QAccessibleEvent *event)
return;
HWND hWnd = (HWND)platform->nativeResourceForWindow("handle", window);
- static int eventNum = 0;
if (event->type() != QAccessible::MenuCommand && // MenuCommand is faked
event->type() != QAccessible::ObjectDestroyed) {
- /* In some rare occasions, the server (Qt) might get a ::get_accChild call with a
- childId that references an entry in the cache where there was a dangling
- QObject-pointer. Previously we crashed on this.
-
- There is no point in actually notifying the AT client that the object got destroyed,
- because the AT client won't query for get_accChild if the event is ObjectDestroyed
- anyway, and we have no other way of mapping the eventId argument to the actual
- child/descendant object. (Firefox seems to simply completely ignore
- EVENT_OBJECT_DESTROY).
-
- We therefore guard each QObject in the cache with a QPointer, and only notify the AT
- client if the type is not ObjectDestroyed.
- */
- eventNum %= 50; //[0..49]
- int eventId = - (eventNum - 1);
- qAccessibleRecentSentEvents()->insert(eventId, qMakePair(QPointer<QObject>(event->object()), event->child()));
- ptrNotifyWinEvent(event->type(), hWnd, OBJID_CLIENT, eventId);
- ++eventNum;
+ ::NotifyWinEvent(event->type(), hWnd, OBJID_CLIENT, QAccessible::uniqueId(iface));
}
#endif // Q_OS_WINCE
}
@@ -224,10 +190,9 @@ QWindow *QWindowsAccessibility::windowHelper(const QAccessibleInterface *iface)
QWindow *window = iface->window();
if (!window) {
QAccessibleInterface *acc = iface->parent();
- while (acc && !window) {
+ while (acc && acc->isValid() && !window) {
window = acc->window();
QAccessibleInterface *par = acc->parent();
- delete acc;
acc = par;
}
}
@@ -242,6 +207,11 @@ IAccessible *QWindowsAccessibility::wrap(QAccessibleInterface *acc)
{
if (!acc)
return 0;
+
+ // ### FIXME: maybe we should accept double insertions into the cache
+ if (!QAccessible::uniqueId(acc))
+ QAccessible::registerAccessibleInterface(acc);
+
#ifdef Q_CC_MINGW
QWindowsMsaaAccessible *wacc = new QWindowsMsaaAccessible(acc);
#else
@@ -252,15 +222,6 @@ IAccessible *QWindowsAccessibility::wrap(QAccessibleInterface *acc)
return iacc;
}
-/*!
- \internal
-*/
-QPair<QObject*, int> QWindowsAccessibility::getCachedObject(int entryId)
-{
- QPair<QPointer<QObject>, int> pair = qAccessibleRecentSentEvents()->value(entryId);
- return qMakePair(pair.first.data(), pair.second);
-}
-
/*
void QWindowsAccessibility::setRootObject(QObject *o)
{
@@ -283,7 +244,7 @@ bool QWindowsAccessibility::handleAccessibleObjectFromWindowRequest(HWND hwnd, W
{
if (static_cast<long>(lParam) == static_cast<long>(UiaRootObjectId)) {
/* For UI Automation */
- } else if ((DWORD)lParam == OBJID_CLIENT) {
+ } else if ((DWORD)lParam == DWORD(OBJID_CLIENT)) {
#if 1
// Ignoring all requests while starting up
// ### Maybe QPA takes care of this???
@@ -313,8 +274,6 @@ bool QWindowsAccessibility::handleAccessibleObjectFromWindowRequest(HWND hwnd, W
iface->Release(); // the client will release the object again, and then it will destroy itself
}
return true;
- } else {
- delete acc;
}
}
}
diff --git a/src/plugins/platforms/windows/accessible/qwindowsaccessibility.h b/src/plugins/platforms/windows/accessible/qwindowsaccessibility.h
index af0bd65c80..f25e2281a0 100644
--- a/src/plugins/platforms/windows/accessible/qwindowsaccessibility.h
+++ b/src/plugins/platforms/windows/accessible/qwindowsaccessibility.h
@@ -48,7 +48,6 @@
#include <oleacc.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
class QWindowsAccessibility : public QPlatformAccessibility
@@ -64,11 +63,8 @@ public:
*/
static IAccessible *wrap(QAccessibleInterface *acc);
static QWindow *windowHelper(const QAccessibleInterface *iface);
-
- static QPair<QObject*, int> getCachedObject(int entryId);
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QWINDOWSACCESSIBILITY_H
diff --git a/src/plugins/platforms/windows/accessible/qwindowsmsaaaccessible.cpp b/src/plugins/platforms/windows/accessible/qwindowsmsaaaccessible.cpp
index c23902014c..7eb1bd30c0 100644
--- a/src/plugins/platforms/windows/accessible/qwindowsmsaaaccessible.cpp
+++ b/src/plugins/platforms/windows/accessible/qwindowsmsaaaccessible.cpp
@@ -54,7 +54,7 @@
#include <QtCore/qpair.h>
#include <QtCore/qsettings.h>
#include <QtGui/qaccessible.h>
-#include <QtGui/qaccessible2.h>
+#include <QtGui/private/qaccessible2_p.h>
#include <QtGui/qguiapplication.h>
#include <qpa/qplatformnativeinterface.h>
#include <QtGui/qwindow.h>
@@ -186,21 +186,6 @@ HRESULT STDMETHODCALLTYPE QWindowsEnumerate::Skip(unsigned long celt)
return S_OK;
}
-static bool compareAccessible(QAccessibleInterface *one, QAccessibleInterface *other)
-{
- if (one == other) return true;
- if (!one || !other) return false;
-
- if (one->object() && other->object() && (one->object() == other->object()))
- return true;
- QAIPointer onePar(one->parent());
- QAIPointer otherPar(other->parent());
-
- if (compareAccessible(onePar.data(), otherPar.data()))
- return onePar->indexOfChild(one) == otherPar->indexOfChild(other);
- return false;
-}
-
#ifndef QT_NO_DEBUG
bool debug_accessibility()
{
@@ -232,7 +217,9 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::QueryInterface(REFIID id, LPVO
QByteArray strIID = IIDToString(id);
if (!strIID.isEmpty()) {
- QString ss; QDebug dbg(&ss); dbg << accessible;
+ QString ss;
+ QDebug dbg(&ss);
+ dbg << accessibleInterface();
accessibleDebug("QWindowsIA2Accessible::QI() - IID:%s, iface:%s ", strIID.constData(), qPrintable(ss));
}
if (id == IID_IUnknown) {
@@ -533,8 +520,9 @@ IAccessible::accHitTest documents the value returned in pvarID like this:
*/
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accHitTest(long xLeft, long yTop, VARIANT *pvarID)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
QAccessibleInterface *child = accessible->childAt(xLeft, yTop);
@@ -571,14 +559,15 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accHitTest(long xLeft, long yT
// moz: [important]
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accLocation(long *pxLeft, long *pyTop, long *pcxWidth, long *pcyHeight, VARIANT varID)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
QRect rect;
if (varID.lVal) {
- QAIPointer child(childPointer(varID));
- if (!child)
+ QAccessibleInterface *child = accessible->child(varID.lVal - 1);
+ if (!child || !child->isValid())
return E_FAIL;
rect = child->rect();
} else {
@@ -596,8 +585,9 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accLocation(long *pxLeft, long
// moz: [important, but no need to implement up/down/left/right]
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accNavigate(long navDir, VARIANT varStart, VARIANT *pvarEnd)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
QAccessibleInterface *acc = 0;
@@ -612,12 +602,11 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accNavigate(long navDir, VARIA
case NAVDIR_PREVIOUS:
if (!varStart.lVal){
QAccessibleInterface *parent = accessible->parent();
- if (parent) {
+ if (parent && parent->isValid()) {
int index = parent->indexOfChild(accessible);
index += (navDir == NAVDIR_NEXT) ? 1 : -1;
if (index >= 0 && index < parent->childCount())
acc = parent->child(index);
- delete parent;
}
} else {
int index = varStart.lVal;
@@ -631,8 +620,9 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accNavigate(long navDir, VARIA
case NAVDIR_UP:
case NAVDIR_DOWN:
case NAVDIR_LEFT:
- case NAVDIR_RIGHT:
- if (QAccessibleInterface *pIface = accessible->parent()) {
+ case NAVDIR_RIGHT: {
+ QAccessibleInterface *pIface = accessible->parent();
+ if (pIface && pIface->isValid()) {
const int indexOfOurself = pIface->indexOfChild(accessible);
QRect startg = accessible->rect();
QPoint startc = startg.center();
@@ -645,7 +635,6 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accNavigate(long navDir, VARIA
Q_ASSERT(sibling);
if (i == indexOfOurself || sibling->state().invisible) {
//ignore ourself and invisible siblings
- delete sibling;
continue;
}
@@ -659,7 +648,6 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accNavigate(long navDir, VARIA
startp = QPoint(startg.left(), startg.top() + startg.height() / 2);
sibp = QPoint(sibg.right(), sibg.top() + sibg.height() / 2);
if (QPoint(sibc - startc).x() >= 0) {
- delete sibling;
continue;
}
distp = sibp - startp;
@@ -668,7 +656,6 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accNavigate(long navDir, VARIA
startp = QPoint(startg.right(), startg.top() + startg.height() / 2);
sibp = QPoint(sibg.left(), sibg.top() + sibg.height() / 2);
if (QPoint(sibc - startc).x() <= 0) {
- delete sibling;
continue;
}
distp = sibp - startp;
@@ -677,7 +664,6 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accNavigate(long navDir, VARIA
startp = QPoint(startg.left() + startg.width() / 2, startg.top());
sibp = QPoint(sibg.left() + sibg.width() / 2, sibg.bottom());
if (QPoint(sibc - startc).y() >= 0) {
- delete sibling;
continue;
}
distp = sibp - startp;
@@ -686,7 +672,6 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accNavigate(long navDir, VARIA
startp = QPoint(startg.left() + startg.width() / 2, startg.bottom());
sibp = QPoint(sibg.left() + sibg.width() / 2, sibg.top());
if (QPoint(sibc - startc).y() <= 0) {
- delete sibling;
continue;
}
distp = sibp - startp;
@@ -699,16 +684,13 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accNavigate(long navDir, VARIA
// squared distance, (thus, no need to take the sqrt()).
unsigned dist = distp.x() * distp.x() + distp.y() * distp.y();
if (dist < mindist) {
- delete candidate;
candidate = sibling;
mindist = dist;
- } else {
- delete sibling;
}
}
- delete pIface;
acc = candidate;
}
+ }
break;
default:
break;
@@ -722,9 +704,6 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accNavigate(long navDir, VARIA
(*pvarEnd).vt = VT_DISPATCH;
(*pvarEnd).pdispVal = iface;
return S_OK;
- } else {
- if (acc != accessible)
- delete acc;
}
(*pvarEnd).vt = VT_EMPTY;
@@ -734,8 +713,9 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accNavigate(long navDir, VARIA
// moz: [important]
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accChild(VARIANT varChildID, IDispatch** ppdispChild)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (varChildID.vt != VT_I4)
@@ -743,38 +723,18 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accChild(VARIANT varChildI
int childIndex = varChildID.lVal;
+
QAccessibleInterface *acc = 0;
- if (childIndex < 0) {
- const int entry = childIndex;
- QPair<QObject*, int> ref = QWindowsAccessibility::getCachedObject(entry);
- if (ref.first) {
- acc = QAccessible::queryAccessibleInterface(ref.first);
- if (acc && ref.second >= 0) {
- QAccessibleInterface *res = acc->child(ref.second);
- delete acc;
- if (!res)
- return E_INVALIDARG;
- acc = res;
- }
- } else {
- qWarning("get_accChild got a negative varChildID (%d), but did not find it in cache", childIndex);
- }
+
+ if (childIndex == 0) {
+ // Yes, some AT clients (Active Accessibility Object Inspector)
+ // actually ask for the same object. As a consequence, we need to clone ourselves:
+ acc = accessible;
+ } else if (childIndex < 0) {
+ acc = QAccessible::accessibleInterface((QAccessible::Id)childIndex);
} else {
- if (childIndex) {
- acc = accessible->child(childIndex - 1);
- } else {
- // Yes, some AT clients (Active Accessibility Object Inspector)
- // actually ask for the same object. As a consequence, we need to clone ourselves:
- if (QAccessibleInterface *par = accessible->parent()) {
- const int indexOf = par->indexOfChild(accessible);
- if (indexOf == -1)
- qWarning() << "inconsistent hierarchy, parent:" << par << "child:" << accessible;
- else
- acc = par->child(indexOf);
- delete par;
- }
- }
+ acc = accessible->child(childIndex - 1);
}
if (acc) {
@@ -788,8 +748,9 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accChild(VARIANT varChildI
// moz: [important]
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accChildCount(long* pcountChildren)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*pcountChildren = accessible->childCount();
@@ -799,8 +760,9 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accChildCount(long* pcount
// moz: [important]
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accParent(IDispatch** ppdispParent)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
QAccessibleInterface *acc = accessible->parent();
@@ -808,8 +770,6 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accParent(IDispatch** ppdi
if (IAccessible *iface = QWindowsAccessibility::wrap(acc)) {
*ppdispParent = iface;
return S_OK;
- } else {
- delete acc;
}
}
@@ -823,8 +783,9 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accParent(IDispatch** ppdi
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accDoDefaultAction(VARIANT varID)
{
Q_UNUSED(varID);
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleActionInterface *actionIface = accessible->actionInterface()) {
@@ -840,8 +801,9 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accDoDefaultAction(VARIANT var
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accDefaultAction(VARIANT varID, BSTR* pszDefaultAction)
{
Q_UNUSED(varID);
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*pszDefaultAction = 0;
@@ -855,14 +817,15 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accDefaultAction(VARIANT v
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accDescription(VARIANT varID, BSTR* pszDescription)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
QString descr;
if (varID.lVal) {
- QAIPointer child = childPointer(varID);
+ QAccessibleInterface *child = childPointer(varID);
if (!child)
return E_FAIL;
descr = child->text(QAccessible::Description);
@@ -880,13 +843,14 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accDescription(VARIANT var
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accHelp(VARIANT varID, BSTR *pszHelp)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
QString help;
if (varID.lVal) {
- QAIPointer child = childPointer(varID);
+ QAccessibleInterface *child = childPointer(varID);
if (!child)
return E_FAIL;
help = child->text(QAccessible::Help);
@@ -910,8 +874,9 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accHelpTopic(BSTR *, VARIA
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accKeyboardShortcut(VARIANT varID, BSTR *pszKeyboardShortcut)
{
Q_UNUSED(varID);
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
*pszKeyboardShortcut = 0;
@@ -931,29 +896,26 @@ static QAccessibleInterface *relatedInterface(QAccessibleInterface *iface, QAcce
typedef QPair<QAccessibleInterface *, QAccessible::Relation> RelationPair;
QVector<RelationPair> rels = iface->relations(flag);
- for (int i = 1; i < rels.count(); ++i)
- delete rels.at(i).first;
-
return rels.value(0).first;
}
// moz: [important]
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accName(VARIANT varID, BSTR* pszName)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
QString name;
if (varID.lVal) {
- QAIPointer child = childPointer(varID);
+ QAccessibleInterface *child = childPointer(varID);
if (!child)
return E_FAIL;
name = child->text(QAccessible::Name);
if (name.isEmpty()) {
- if (QAccessibleInterface *labelInterface = relatedInterface(child.data(), QAccessible::Label)) {
+ if (QAccessibleInterface *labelInterface = relatedInterface(child, QAccessible::Label)) {
name = labelInterface->text(QAccessible::Name);
- delete labelInterface;
}
}
} else {
@@ -961,7 +923,6 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accName(VARIANT varID, BST
if (name.isEmpty()) {
if (QAccessibleInterface *labelInterface = relatedInterface(accessible, QAccessible::Label)) {
name = labelInterface->text(QAccessible::Name);
- delete labelInterface;
}
}
}
@@ -976,6 +937,7 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accName(VARIANT varID, BST
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::put_accName(VARIANT, BSTR)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
return DISP_E_MEMBERNOTFOUND;
}
@@ -983,13 +945,14 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::put_accName(VARIANT, BSTR)
// moz: [important]
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accRole(VARIANT varID, VARIANT *pvarRole)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
QAccessible::Role role;
if (varID.lVal) {
- QAIPointer child = childPointer(varID);
+ QAccessibleInterface *child = childPointer(varID);
if (!child)
return E_FAIL;
role = child->role();
@@ -1017,14 +980,15 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accRole(VARIANT varID, VAR
// moz: [important]
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accState(VARIANT varID, VARIANT *pvarState)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
QAccessible::State state;
if (varID.lVal) {
- QAIPointer child = childPointer(varID);
- if (!child.data())
+ QAccessibleInterface *child = childPointer(varID);
+ if (!child)
return E_FAIL;
state = child->state();
} else {
@@ -1093,11 +1057,12 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accState(VARIANT varID, VA
// moz: [important]
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accValue(VARIANT varID, BSTR* pszValue)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
if (varID.vt != VT_I4)
return E_INVALIDARG;
- if (!accessible->isValid() || varID.lVal) {
+ if (!accessible || !accessible->isValid() || varID.lVal) {
return E_FAIL;
}
@@ -1119,6 +1084,7 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accValue(VARIANT varID, BS
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::put_accValue(VARIANT, BSTR)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
return DISP_E_MEMBERNOTFOUND;
}
@@ -1128,8 +1094,9 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accSelect(long flagsSelect, VA
{
Q_UNUSED(flagsSelect);
Q_UNUSED(varID);
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
bool res = false;
@@ -1139,17 +1106,17 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accSelect(long flagsSelect, VA
### and if there are no ia2 interfaces we should do nothing??
if (flagsSelect & SELFLAG_TAKEFOCUS)
- res = accessible->doAction(SetFocus, varID.lVal, QVariantList());
+ res = accessible()->doAction(SetFocus, varID.lVal, QVariantList());
if (flagsSelect & SELFLAG_TAKESELECTION) {
- accessible->doAction(ClearSelection, 0, QVariantList());
- res = accessible->doAction(AddToSelection, varID.lVal, QVariantList());
+ accessible()->doAction(ClearSelection, 0, QVariantList());
+ res = accessible()->doAction(AddToSelection, varID.lVal, QVariantList());
}
if (flagsSelect & SELFLAG_EXTENDSELECTION)
- res = accessible->doAction(ExtendSelection, varID.lVal, QVariantList());
+ res = accessible()->doAction(ExtendSelection, varID.lVal, QVariantList());
if (flagsSelect & SELFLAG_ADDSELECTION)
- res = accessible->doAction(AddToSelection, varID.lVal, QVariantList());
+ res = accessible()->doAction(AddToSelection, varID.lVal, QVariantList());
if (flagsSelect & SELFLAG_REMOVESELECTION)
- res = accessible->doAction(RemoveSelection, varID.lVal, QVariantList());
+ res = accessible()->doAction(RemoveSelection, varID.lVal, QVariantList());
*/
return res ? S_OK : S_FALSE;
}
@@ -1172,15 +1139,15 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::accSelect(long flagsSelect, VA
*/
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accFocus(VARIANT *pvarID)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
if (QAccessibleInterface *acc = accessible->focusChild()) {
- if (compareAccessible(acc, accessible)) {
+ if (acc == accessible) {
(*pvarID).vt = VT_I4;
(*pvarID).lVal = CHILDID_SELF;
- delete acc;
return S_OK;
} else {
if (IAccessible *iface = QWindowsAccessibility::wrap(acc)) {
@@ -1189,7 +1156,6 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accFocus(VARIANT *pvarID)
return S_OK;
}
}
- delete acc;
}
(*pvarID).vt = VT_EMPTY;
return S_FALSE;
@@ -1197,8 +1163,9 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accFocus(VARIANT *pvarID)
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accSelection(VARIANT *pvarChildren)
{
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
int cc = accessible->childCount();
@@ -1209,7 +1176,6 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accSelection(VARIANT *pvar
QAccessibleInterface *child = accessible->child(i);
if (child) {
isSelected = child->state().selected;
- delete child;
}
if (isSelected)
sel[selIndex++] = i+1;
@@ -1239,11 +1205,10 @@ HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::get_accSelection(VARIANT *pvar
HRESULT STDMETHODCALLTYPE QWindowsMsaaAccessible::GetWindow(HWND *phwnd)
{
*phwnd = 0;
+ QAccessibleInterface *accessible = accessibleInterface();
accessibleDebugClientCalls(accessible);
- if (!accessible->isValid())
+ if (!accessible)
return E_FAIL;
- if (!accessible->isValid())
- return E_UNEXPECTED;
QWindow *window = QWindowsAccessibility::windowHelper(accessible);
if (!window)
diff --git a/src/plugins/platforms/windows/accessible/qwindowsmsaaaccessible.h b/src/plugins/platforms/windows/accessible/qwindowsmsaaaccessible.h
index ecb2e2bc18..ef17acf3e9 100644
--- a/src/plugins/platforms/windows/accessible/qwindowsmsaaaccessible.h
+++ b/src/plugins/platforms/windows/accessible/qwindowsmsaaaccessible.h
@@ -76,8 +76,6 @@ void accessibleDebugClientCalls_helper(const char* funcName, const QAccessibleIn
# define accessibleDebugClientCalls(iface)
#endif
-typedef QSharedPointer<QAccessibleInterface> QAIPointer;
-
QWindow *window_helper(const QAccessibleInterface *iface);
/**************************************************************\
@@ -93,14 +91,13 @@ class QWindowsMsaaAccessible : public
{
public:
QWindowsMsaaAccessible(QAccessibleInterface *a)
- : accessible(a)
- , ref(0)
+ : ref(0)
{
+ id = QAccessible::uniqueId(a);
}
virtual ~QWindowsMsaaAccessible()
{
- delete accessible;
}
/* IUnknown */
@@ -146,11 +143,23 @@ public:
protected:
virtual QByteArray IIDToString(REFIID id);
- QAccessibleInterface *accessible;
+ QAccessible::Id id;
+
+ QAccessibleInterface *accessibleInterface() const
+ {
+ QAccessibleInterface *iface = QAccessible::accessibleInterface(id);
+ if (iface && iface->isValid())
+ return iface;
+ return 0;
+ }
- QAIPointer childPointer(VARIANT varID)
+ QAccessibleInterface *childPointer(VARIANT varID)
{
- return QAIPointer(accessible->child(varID.lVal - 1));
+ // -1 since windows API always uses 1 for the first child
+ QAccessibleInterface *iface = accessibleInterface();
+ if (iface)
+ return accessibleInterface()->child(varID.lVal - 1);
+ return 0;
}
private:
diff --git a/src/plugins/platforms/windows/qtwindows_additional.h b/src/plugins/platforms/windows/qtwindows_additional.h
index 8d59fbd7c6..3b2e9787a2 100644
--- a/src/plugins/platforms/windows/qtwindows_additional.h
+++ b/src/plugins/platforms/windows/qtwindows_additional.h
@@ -126,6 +126,10 @@ typedef struct tagUPDATELAYEREDWINDOWINFO {
// IME.
#define IMR_CONFIRMRECONVERTSTRING 0x0005
+#ifndef MAPVK_VK_TO_CHAR
+# define MAPVK_VK_TO_CHAR 2
+#endif
+
#endif // if defined(Q_CC_MINGW)
/* Touch is supported from Windows 7 onwards and data structures
diff --git a/src/plugins/platforms/windows/qwindowscontext.cpp b/src/plugins/platforms/windows/qwindowscontext.cpp
index 88c9bf448d..545484de8d 100644
--- a/src/plugins/platforms/windows/qwindowscontext.cpp
+++ b/src/plugins/platforms/windows/qwindowscontext.cpp
@@ -372,56 +372,53 @@ void QWindowsContext::setKeyGrabber(QWindow *w)
}
// Window class registering code (from qapplication_win.cpp)
-// If 0 is passed as the widget pointer, register a window class
-// for QWidget as default. This is used in QGLTemporaryContext
-// during GL initialization, where we don't want to use temporary
-// QWidgets or QGLWidgets, neither do we want to have separate code
-// to register window classes.
QString QWindowsContext::registerWindowClass(const QWindow *w, bool isGL)
{
- const Qt::WindowFlags flags = w ? w->flags() : (Qt::WindowFlags)0;
+ Q_ASSERT(w);
+ const Qt::WindowFlags flags = w->flags();
const Qt::WindowFlags type = flags & Qt::WindowType_Mask;
-
- uint style = 0;
- bool icon = false;
- QString cname = QStringLiteral("Qt5");
- if (w && isGL) {
- cname += QStringLiteral("QGLWindow");
- style = CS_DBLCLKS|CS_OWNDC;
- icon = true;
- } else if (w && (flags & Qt::MSWindowsOwnDC)) {
- cname += QStringLiteral("QWindowOwnDC");
- style = CS_DBLCLKS|CS_OWNDC;
- icon = true;
- } else if (w && (type == Qt::Tool || type == Qt::ToolTip)) {
- style = CS_DBLCLKS;
- if (w->inherits("QTipLabel") || w->inherits("QAlphaWidget")) {
- if ((QSysInfo::WindowsVersion >= QSysInfo::WV_XP
- && (QSysInfo::WindowsVersion & QSysInfo::WV_NT_based))) {
- style |= CS_DROPSHADOW;
- }
- cname += QStringLiteral("QToolTip");
- } else {
- cname += QStringLiteral("QTool");
- }
- style |= CS_SAVEBITS;
- icon = false;
- } else if (w && (type == Qt::Popup)) {
- cname += QStringLiteral("QPopup");
- style = CS_DBLCLKS|CS_SAVEBITS;
- if ((QSysInfo::WindowsVersion >= QSysInfo::WV_XP
- && (QSysInfo::WindowsVersion & QSysInfo::WV_NT_based)))
- style |= CS_DROPSHADOW;
+ // Determine style and icon.
+ uint style = CS_DBLCLKS;
+ bool icon = true;
+ if (isGL || (flags & Qt::MSWindowsOwnDC))
+ style |= CS_OWNDC;
+ if ((QSysInfo::WindowsVersion & QSysInfo::WV_NT_based)
+ && (type == Qt::Popup || w->property("_q_windowsDropShadow").toBool())) {
+ style |= CS_DROPSHADOW;
+ }
+ if (type == Qt::Tool || type == Qt::ToolTip || type == Qt::Popup) {
+ style |= CS_SAVEBITS; // Save/restore background
icon = false;
- } else {
- cname += QStringLiteral("QWindow");
- style = CS_DBLCLKS;
- icon = true;
}
+ // Create a unique name for the flag combination
+ QString cname = QStringLiteral("Qt5QWindow");
+ switch (type) {
+ case Qt::Tool:
+ cname += QStringLiteral("Tool");
+ break;
+ case Qt::ToolTip:
+ cname += QStringLiteral("ToolTip");
+ break;
+ case Qt::Popup:
+ cname += QStringLiteral("Popup");
+ break;
+ default:
+ break;
+ }
+ if (isGL)
+ cname += QStringLiteral("GL");
+ if (style & CS_DROPSHADOW)
+ cname += QStringLiteral("DropShadow");
+ if (style & CS_SAVEBITS)
+ cname += QStringLiteral("SaveBits");
+ if (style & CS_OWNDC)
+ cname += QStringLiteral("OwnDC");
+ if (icon)
+ cname += QStringLiteral("Icon");
HBRUSH brush = 0;
- if (w && !isGL)
+ if (!isGL)
brush = GetSysColorBrush(COLOR_WINDOW);
return registerWindowClass(cname, qWindowsWndProc, style, brush, icon);
}
@@ -787,7 +784,7 @@ bool QWindowsContext::windowsProc(HWND hwnd, UINT message,
d->m_creationContext->obtainedGeometry.moveTo(GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam));
return true;
case QtWindows::CalculateSize:
- return false;
+ return QWindowsGeometryHint::handleCalculateSize(d->m_creationContext->customMargins, msg, result);
default:
break;
}
@@ -822,12 +819,7 @@ bool QWindowsContext::windowsProc(HWND hwnd, UINT message,
platformWindow->getSizeHints(reinterpret_cast<MINMAXINFO *>(lParam));
return true;// maybe available on some SDKs revisit WM_NCCALCSIZE
case QtWindows::CalculateSize:
- // NCCALCSIZE_PARAMS structure if wParam==TRUE
- if (wParam && QWindowsContext::verboseWindows) {
- const NCCALCSIZE_PARAMS *ncp = reinterpret_cast<NCCALCSIZE_PARAMS *>(lParam);
- qDebug() << platformWindow->window() << *ncp;
- }
- break;
+ return QWindowsGeometryHint::handleCalculateSize(platformWindow->customMargins(), msg, result);
#endif
case QtWindows::ExposeEvent:
return platformWindow->handleWmPaint(hwnd, message, wParam, lParam);
@@ -858,10 +850,10 @@ bool QWindowsContext::windowsProc(HWND hwnd, UINT message,
return true;
case QtWindows::ShowEvent:
platformWindow->handleShown();
- return true;
+ return false; // Indicate transient children should be shown by windows (SW_PARENTOPENING)
case QtWindows::HideEvent:
platformWindow->handleHidden();
- return true;
+ return false;// Indicate transient children should be hidden by windows (SW_PARENTCLOSING)
case QtWindows::CloseEvent:
QWindowSystemInterface::handleCloseEvent(platformWindow->window());
return true;
diff --git a/src/plugins/platforms/windows/qwindowscursor.cpp b/src/plugins/platforms/windows/qwindowscursor.cpp
index 4dc9af61d8..5b2a3acbae 100644
--- a/src/plugins/platforms/windows/qwindowscursor.cpp
+++ b/src/plugins/platforms/windows/qwindowscursor.cpp
@@ -395,6 +395,19 @@ QWindowsWindowCursor QWindowsCursor::standardWindowCursor(Qt::CursorShape shape)
}
/*!
+ \brief Return cached pixmap cursor or create new one.
+*/
+
+QWindowsWindowCursor QWindowsCursor::pixmapWindowCursor(const QCursor &c)
+{
+ const qint64 cacheKey = c.pixmap().cacheKey();
+ PixmapCursorCache::iterator it = m_pixmapCursorCache.find(cacheKey);
+ if (it == m_pixmapCursorCache.end())
+ it = m_pixmapCursorCache.insert(cacheKey, QWindowsWindowCursor(c));
+ return it.value();
+}
+
+/*!
\brief Set a cursor on a window.
This is called frequently as the mouse moves over widgets in the window
@@ -406,11 +419,15 @@ void QWindowsCursor::changeCursor(QCursor *cursorIn, QWindow *window)
if (QWindowsContext::verboseWindows > 1)
qDebug() << __FUNCTION__ << cursorIn << window;
- if (!cursorIn || !window)
+ if (!window)
+ return;
+ if (!cursorIn) {
+ QWindowsWindow::baseWindowOf(window)->setCursor(QWindowsWindowCursor());
return;
+ }
const QWindowsWindowCursor wcursor =
cursorIn->shape() == Qt::BitmapCursor ?
- QWindowsWindowCursor(*cursorIn) : standardWindowCursor(cursorIn->shape());
+ pixmapWindowCursor(*cursorIn) : standardWindowCursor(cursorIn->shape());
if (wcursor.handle()) {
QWindowsWindow::baseWindowOf(window)->setCursor(wcursor);
} else {
@@ -449,6 +466,7 @@ void QWindowsCursor::setPos(const QPoint &pos)
class QWindowsWindowCursorData : public QSharedData
{
public:
+ QWindowsWindowCursorData() : m_cursor(Qt::ArrowCursor), m_handle(0) {}
explicit QWindowsWindowCursorData(const QCursor &c);
~QWindowsWindowCursorData();
@@ -464,7 +482,13 @@ QWindowsWindowCursorData::QWindowsWindowCursorData(const QCursor &c) :
QWindowsWindowCursorData::~QWindowsWindowCursorData()
{
- DestroyCursor(m_handle);
+ if (m_handle)
+ DestroyCursor(m_handle);
+}
+
+QWindowsWindowCursor::QWindowsWindowCursor() :
+ m_data(new QWindowsWindowCursorData)
+{
}
QWindowsWindowCursor::QWindowsWindowCursor(const QCursor &c) :
@@ -488,6 +512,11 @@ QWindowsWindowCursor & QWindowsWindowCursor::operator =(const QWindowsWindowCurs
return *this;
}
+bool QWindowsWindowCursor::isNull() const
+{
+ return m_data->m_handle == 0;
+}
+
QCursor QWindowsWindowCursor::cursor() const
{
return m_data->m_cursor;
diff --git a/src/plugins/platforms/windows/qwindowscursor.h b/src/plugins/platforms/windows/qwindowscursor.h
index b0256d4203..1e818bc9b8 100644
--- a/src/plugins/platforms/windows/qwindowscursor.h
+++ b/src/plugins/platforms/windows/qwindowscursor.h
@@ -55,11 +55,13 @@ class QWindowsWindowCursorData;
class QWindowsWindowCursor
{
public:
+ QWindowsWindowCursor();
explicit QWindowsWindowCursor(const QCursor &c);
~QWindowsWindowCursor();
QWindowsWindowCursor(const QWindowsWindowCursor &c);
QWindowsWindowCursor &operator=(const QWindowsWindowCursor &c);
+ bool isNull() const;
QCursor cursor() const;
HCURSOR handle() const;
@@ -81,11 +83,14 @@ public:
static QPoint mousePosition();
QWindowsWindowCursor standardWindowCursor(Qt::CursorShape s = Qt::ArrowCursor);
+ QWindowsWindowCursor pixmapWindowCursor(const QCursor &c);
private:
typedef QHash<Qt::CursorShape, QWindowsWindowCursor> StandardCursorCache;
+ typedef QHash<qint64, QWindowsWindowCursor> PixmapCursorCache;
StandardCursorCache m_standardCursorCache;
+ PixmapCursorCache m_pixmapCursorCache;
};
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/windows/qwindowsdialoghelpers.cpp b/src/plugins/platforms/windows/qwindowsdialoghelpers.cpp
index daa4369d88..5b84725edf 100644
--- a/src/plugins/platforms/windows/qwindowsdialoghelpers.cpp
+++ b/src/plugins/platforms/windows/qwindowsdialoghelpers.cpp
@@ -58,6 +58,10 @@
#include <QtCore/QObject>
#include <QtCore/QThread>
#include <QtCore/QSysInfo>
+#include <QtCore/QSharedData>
+#include <QtCore/QExplicitlySharedDataPointer>
+#include <QtCore/QMutex>
+#include <QtCore/QMutexLocker>
#include <QtCore/private/qsystemlibrary_p.h>
#include "qtwindows_additional.h"
@@ -82,6 +86,8 @@ static const IID q_IID_IShellItem = {0x43826d1e, 0xe718, 0x42ee, {0xbc, 0
#define IID_IShellItem q_IID_IShellItem
#else
static const IID IID_IShellItem = {0x43826d1e, 0xe718, 0x42ee, {0xbc, 0x55, 0xa1, 0xe2, 0x61, 0xc3, 0x7b, 0xfe}};
+static const IID IID_IShellItemArray = {0xb63ea76d, 0x1f85, 0x456f, {0xa1, 0x9c, 0x48, 0x15, 0x9e, 0xfa, 0x85, 0x8b}};
+# define LFF_FORCEFILESYSTEM 1
#endif
static const IID IID_IFileDialogEvents = {0x973510db, 0x7d7f, 0x452b,{0x89, 0x75, 0x74, 0xa8, 0x58, 0x28, 0xd3, 0x54}};
static const CLSID CLSID_FileOpenDialog = {0xdc1c5a9c, 0xe88a, 0x4dde, {0xa5, 0xa1, 0x60, 0xf8, 0x2a, 0x20, 0xae, 0xf7}};
@@ -249,6 +255,34 @@ DECLARE_INTERFACE_(IShellItemArray, IUnknown)
};
#endif
+#ifndef __IShellLibrary_INTERFACE_DEFINED__
+
+enum LIBRARYOPTIONFLAGS {};
+enum DEFAULTSAVEFOLDERTYPE { DSFT_DETECT = 1 };
+enum LIBRARYSAVEFLAGS {};
+
+DECLARE_INTERFACE_(IShellLibrary, IUnknown)
+{
+ STDMETHOD(LoadLibraryFromItem)(THIS_ IShellItem *psiLibrary, DWORD grfMode) PURE;
+ STDMETHOD(LoadLibraryFromKnownFolder)(THIS_ const GUID &kfidLibrary, DWORD grfMode) PURE;
+ STDMETHOD(AddFolder)(THIS_ IShellItem *psiLocation) PURE;
+ STDMETHOD(RemoveFolder)(THIS_ IShellItem *psiLocation) PURE;
+ STDMETHOD(GetFolders)(THIS_ int lff, REFIID riid, void **ppv) PURE;
+ STDMETHOD(ResolveFolder)(THIS_ IShellItem *psiFolderToResolve, DWORD dwTimeout, REFIID riid, void **ppv) PURE;
+ STDMETHOD(GetDefaultSaveFolder)(THIS_ DEFAULTSAVEFOLDERTYPE dsft, REFIID riid, void **ppv) PURE;
+ STDMETHOD(SetDefaultSaveFolder)(THIS_ DEFAULTSAVEFOLDERTYPE dsft, IShellItem *psi) PURE;
+ STDMETHOD(GetOptions)(THIS_ LIBRARYOPTIONFLAGS *plofOptions) PURE;
+ STDMETHOD(SetOptions)(THIS_ LIBRARYOPTIONFLAGS lofMask, LIBRARYOPTIONFLAGS lofOptions) PURE;
+ STDMETHOD(GetFolderType)(THIS_ GUID *pftid) PURE;
+ STDMETHOD(SetFolderType)(THIS_ const GUID &ftid) PURE;
+ STDMETHOD(GetIcon)(THIS_ LPWSTR *ppszIcon) PURE;
+ STDMETHOD(SetIcon)(THIS_ LPCWSTR pszIcon) PURE;
+ STDMETHOD(Commit)(THIS_) PURE;
+ STDMETHOD(Save)(THIS_ IShellItem *psiFolderToSaveIn, LPCWSTR pszLibraryName, LIBRARYSAVEFLAGS lsf, IShellItem **ppsiSavedTo) PURE;
+ STDMETHOD(SaveInKnownFolder)(THIS_ const GUID &kfidToSaveIn, LPCWSTR pszLibraryName, LIBRARYSAVEFLAGS lsf,IShellItem **ppsiSavedTo) PURE;
+};
+#endif
+
#ifndef __IModalWindow_INTERFACE_DEFINED__
DECLARE_INTERFACE_(IModalWindow, IUnknown)
{
@@ -387,6 +421,9 @@ void eatMouseMove()
Vista on) that mimick the behaviour of their QDialog
counterparts as close as possible.
+ Instances of derived classes are controlled by
+ QWindowsDialogHelperBase-derived classes.
+
A major difference is that there is only an exec(), which
is a modal, blocking call; there is no non-blocking show().
There 2 types of native dialogs:
@@ -401,6 +438,7 @@ void eatMouseMove()
like close() can be called on them from event handlers.
\endlist
+ \sa QWindowsDialogHelperBase
\internal
\ingroup qt-lighthouse-win
*/
@@ -411,7 +449,6 @@ class QWindowsNativeDialogBase : public QObject
public:
virtual void setWindowTitle(const QString &title) = 0;
virtual void exec(HWND owner = 0) = 0;
- virtual QPlatformDialogHelper::DialogCode result() const = 0;
signals:
void accepted();
@@ -432,12 +469,10 @@ protected:
The native dialog is created in setVisible_sys() since
then modality and the state of DontUseNativeDialog is known.
- Modal dialogs are then started via the platformNativeDialogModalHelp(),
- platformNativeDialogModalHelp() slots.
- Non-modal dialogs are shown using a separate thread should
- they support it.
+ Modal dialogs are then run by exec(). Non-modal dialogs are shown using a
+ separate thread started in show() should they support it.
- \sa QWindowsDialogThread
+ \sa QWindowsDialogThread, QWindowsNativeDialogBase
\internal
\ingroup qt-lighthouse-win
*/
@@ -445,17 +480,12 @@ protected:
template <class BaseClass>
QWindowsDialogHelperBase<BaseClass>::QWindowsDialogHelperBase() :
m_nativeDialog(0),
- m_ownerWindow(0)
+ m_ownerWindow(0),
+ m_timerId(0)
{
}
template <class BaseClass>
-QWindowsDialogHelperBase<BaseClass>::~QWindowsDialogHelperBase()
-{
- delete m_nativeDialog;
-}
-
-template <class BaseClass>
QWindowsNativeDialogBase *QWindowsDialogHelperBase<BaseClass>::nativeDialog() const
{
if (!m_nativeDialog) {
@@ -466,6 +496,19 @@ QWindowsNativeDialogBase *QWindowsDialogHelperBase<BaseClass>::nativeDialog() co
}
template <class BaseClass>
+void QWindowsDialogHelperBase<BaseClass>::deleteNativeDialog()
+{
+ delete m_nativeDialog;
+ m_nativeDialog = 0;
+}
+
+template <class BaseClass>
+void QWindowsDialogHelperBase<BaseClass>::timerEvent(QTimerEvent *)
+{
+ startDialogThread();
+}
+
+template <class BaseClass>
QWindowsNativeDialogBase *QWindowsDialogHelperBase<BaseClass>::ensureNativeDialog()
{
// Create dialog and apply common settings.
@@ -486,22 +529,18 @@ QWindowsNativeDialogBase *QWindowsDialogHelperBase<BaseClass>::ensureNativeDialo
class QWindowsDialogThread : public QThread
{
public:
- QWindowsDialogThread(QWindowsNativeDialogBase *dialog,
- HWND owner = 0) :
- m_dialog(dialog), m_owner(owner) {}
-
+ QWindowsDialogThread(QPlatformDialogHelper *h) : m_helper(h) {}
void run();
private:
- QWindowsNativeDialogBase *m_dialog;
- const HWND m_owner;
+ QPlatformDialogHelper *m_helper;
};
void QWindowsDialogThread::run()
{
if (QWindowsContext::verboseDialogs)
qDebug(">%s" , __FUNCTION__);
- m_dialog->exec(m_owner);
+ m_helper->exec();
deleteLater();
if (QWindowsContext::verboseDialogs)
qDebug("<%s" , __FUNCTION__);
@@ -512,7 +551,7 @@ bool QWindowsDialogHelperBase<BaseClass>::show(Qt::WindowFlags,
Qt::WindowModality windowModality,
QWindow *parent)
{
- const bool modal = (windowModality == Qt::ApplicationModal);
+ const bool modal = (windowModality != Qt::NonModal);
if (parent) {
m_ownerWindow = QWindowsWindow::handleOf(parent);
} else {
@@ -521,18 +560,40 @@ bool QWindowsDialogHelperBase<BaseClass>::show(Qt::WindowFlags,
if (QWindowsContext::verboseDialogs)
qDebug("%s modal=%d native=%p parent=%p" ,
__FUNCTION__, modal, m_nativeDialog, m_ownerWindow);
- if (!modal && !supportsNonModalDialog())
+ if (!modal && !supportsNonModalDialog(parent))
return false; // Was it changed in-between?
if (!ensureNativeDialog())
return false;
- if (!modal) { // Modal dialogs are shown in separate slot.
- QWindowsDialogThread *thread = new QWindowsDialogThread(m_nativeDialog, m_ownerWindow);
- thread->start();
+ // Start a background thread to show the dialog. For modal dialogs,
+ // a subsequent call to exec() may follow. So, start an idle timer
+ // which will start the dialog thread. If exec() is then called, the
+ // timer is stopped and dialog->exec() is called directly.
+ if (modal) {
+ m_timerId = this->startTimer(0);
+ } else {
+ startDialogThread();
}
return true;
}
template <class BaseClass>
+void QWindowsDialogHelperBase<BaseClass>::startDialogThread()
+{
+ QWindowsDialogThread *thread = new QWindowsDialogThread(this);
+ thread->start();
+ stopTimer();
+}
+
+template <class BaseClass>
+void QWindowsDialogHelperBase<BaseClass>::stopTimer()
+{
+ if (m_timerId) {
+ this->killTimer(m_timerId);
+ m_timerId = 0;
+ }
+}
+
+template <class BaseClass>
void QWindowsDialogHelperBase<BaseClass>::hide()
{
if (m_nativeDialog)
@@ -545,8 +606,11 @@ void QWindowsDialogHelperBase<BaseClass>::exec()
{
if (QWindowsContext::verboseDialogs)
qDebug("%s" , __FUNCTION__);
- if (QWindowsNativeDialogBase *nd = nativeDialog())
+ stopTimer();
+ if (QWindowsNativeDialogBase *nd = nativeDialog()) {
nd->exec(m_ownerWindow);
+ deleteNativeDialog();
+ }
}
static inline bool snapToDefaultButtonHint()
@@ -568,6 +632,101 @@ QVariant QWindowsDialogHelperBase<BaseClass>::styleHint(QPlatformDialogHelper::S
}
/*!
+ \class QWindowsFileDialogSharedData
+ \brief Explicitly shared file dialog parameters that are not in QFileDialogOptions.
+
+ Contain Parameters that need to be cached while the native dialog does not
+ exist yet. In addition, the data are updated by the change notifications of the
+ IFileDialogEvent, as querying them after the dialog has closed
+ does not reliably work. Provides thread-safe setters (for the non-modal case).
+
+ \internal
+ \ingroup qt-lighthouse-win
+ \sa QFileDialogOptions
+*/
+
+class QWindowsFileDialogSharedData
+{
+public:
+ QWindowsFileDialogSharedData() : m_data(new Data) {}
+ void fromOptions(const QSharedPointer<QFileDialogOptions> &o);
+
+ QString directory() const;
+ void setDirectory(const QString &);
+ QString selectedNameFilter() const;
+ void setSelectedNameFilter(const QString &);
+ QStringList selectedFiles() const;
+ void setSelectedFiles(const QStringList &);
+ QString selectedFile() const;
+
+private:
+ class Data : public QSharedData {
+ public:
+ QString directory;
+ QString selectedNameFilter;
+ QStringList selectedFiles;
+ QMutex mutex;
+ };
+ QExplicitlySharedDataPointer<Data> m_data;
+};
+
+inline QString QWindowsFileDialogSharedData::directory() const
+{
+ m_data->mutex.lock();
+ const QString result = m_data->directory;
+ m_data->mutex.unlock();
+ return result;
+}
+
+inline void QWindowsFileDialogSharedData::setDirectory(const QString &d)
+{
+ QMutexLocker (&m_data->mutex);
+ m_data->directory = d;
+}
+
+inline QString QWindowsFileDialogSharedData::selectedNameFilter() const
+{
+ m_data->mutex.lock();
+ const QString result = m_data->selectedNameFilter;
+ m_data->mutex.unlock();
+ return result;
+}
+
+inline void QWindowsFileDialogSharedData::setSelectedNameFilter(const QString &f)
+{
+ QMutexLocker (&m_data->mutex);
+ m_data->selectedNameFilter = f;
+}
+
+inline QStringList QWindowsFileDialogSharedData::selectedFiles() const
+{
+ m_data->mutex.lock();
+ const QStringList result = m_data->selectedFiles;
+ m_data->mutex.unlock();
+ return result;
+}
+
+inline QString QWindowsFileDialogSharedData::selectedFile() const
+{
+ const QStringList files = selectedFiles();
+ return files.isEmpty() ? QString() : files.front();
+}
+
+inline void QWindowsFileDialogSharedData::setSelectedFiles(const QStringList &f)
+{
+ QMutexLocker (&m_data->mutex);
+ m_data->selectedFiles = f;
+}
+
+inline void QWindowsFileDialogSharedData::fromOptions(const QSharedPointer<QFileDialogOptions> &o)
+{
+ QMutexLocker (&m_data->mutex);
+ m_data->directory = o->initialDirectory();
+ m_data->selectedFiles = o->initiallySelectedFiles();
+ m_data->selectedNameFilter = o->initiallySelectedNameFilter();
+}
+
+/*!
\class QWindowsNativeFileDialogEventHandler
\brief Listens to IFileDialog events and forwards them to QWindowsNativeFileDialogBase
@@ -609,7 +768,7 @@ public:
}
// IFileDialogEvents methods
- IFACEMETHODIMP OnFileOk(IFileDialog *) { return S_OK; }
+ IFACEMETHODIMP OnFileOk(IFileDialog *);
IFACEMETHODIMP OnFolderChange(IFileDialog *) { return S_OK; }
IFACEMETHODIMP OnFolderChanging(IFileDialog *, IShellItem *);
IFACEMETHODIMP OnHelp(IFileDialog *) { return S_OK; }
@@ -658,15 +817,17 @@ class QWindowsNativeFileDialogBase : public QWindowsNativeDialogBase
public:
~QWindowsNativeFileDialogBase();
- inline static QWindowsNativeFileDialogBase *create(QFileDialogOptions::AcceptMode am);
+ inline static QWindowsNativeFileDialogBase *create(QFileDialogOptions::AcceptMode am, const QWindowsFileDialogSharedData &data);
virtual void setWindowTitle(const QString &title);
inline void setMode(QFileDialogOptions::FileMode mode, QFileDialogOptions::FileDialogOptions options);
inline void setDirectory(const QString &directory);
+ inline void updateDirectory() { setDirectory(m_data.directory()); }
inline QString directory() const;
virtual void exec(HWND owner = 0);
inline void setNameFilters(const QStringList &f);
inline void selectNameFilter(const QString &filter);
+ inline void updateSelectedNameFilter() { selectNameFilter(m_data.selectedNameFilter()); }
inline QString selectedNameFilter() const;
void selectFile(const QString &fileName) const;
bool hideFiltersDetails() const { return m_hideFiltersDetails; }
@@ -674,14 +835,16 @@ public:
void setDefaultSuffix(const QString &s);
inline void setLabelText(QFileDialogOptions::DialogLabel l, const QString &text);
- virtual QPlatformDialogHelper::DialogCode result() const
- { return fileResult(); }
- virtual QPlatformDialogHelper::DialogCode fileResult(QStringList *fileResult = 0) const = 0;
+ // Return the selected files for tracking in OnSelectionChanged().
virtual QStringList selectedFiles() const = 0;
+ // Return the result for tracking in OnFileOk(). Differs from selection for
+ // example by appended default suffixes, etc.
+ virtual QStringList dialogResult() const = 0;
inline void onFolderChange(IShellItem *);
inline void onSelectionChange();
inline void onTypeChange();
+ inline bool onFileOk();
signals:
void directoryEntered(const QString& directory);
@@ -692,23 +855,30 @@ public slots:
virtual void close() { m_fileDialog->Close(S_OK); }
protected:
- QWindowsNativeFileDialogBase();
+ explicit QWindowsNativeFileDialogBase(const QWindowsFileDialogSharedData &data);
bool init(const CLSID &clsId, const IID &iid);
inline IFileDialog * fileDialog() const { return m_fileDialog; }
static QString itemPath(IShellItem *item);
+ static QStringList libraryItemFolders(IShellItem *item);
+ static QString libraryItemDefaultSaveFolder(IShellItem *item);
static int itemPaths(IShellItemArray *items, QStringList *fileResult = 0);
static IShellItem *shellItem(const QString &path);
+ const QWindowsFileDialogSharedData &data() const { return m_data; }
+ QWindowsFileDialogSharedData &data() { return m_data; }
+
private:
IFileDialog *m_fileDialog;
IFileDialogEvents *m_dialogEvents;
DWORD m_cookie;
QStringList m_nameFilters;
bool m_hideFiltersDetails;
+ QWindowsFileDialogSharedData m_data;
};
-QWindowsNativeFileDialogBase::QWindowsNativeFileDialogBase() :
- m_fileDialog(0), m_dialogEvents(0), m_cookie(0), m_hideFiltersDetails(false)
+QWindowsNativeFileDialogBase::QWindowsNativeFileDialogBase(const QWindowsFileDialogSharedData &data) :
+ m_fileDialog(0), m_dialogEvents(0), m_cookie(0), m_hideFiltersDetails(false),
+ m_data(data)
{
}
@@ -764,15 +934,17 @@ IShellItem *QWindowsNativeFileDialogBase::shellItem(const QString &path)
return result;
}
#endif
- qErrnoWarning("%s: SHCreateItemFromParsingName()) failed", __FUNCTION__);
+ qErrnoWarning("%s: SHCreateItemFromParsingName(%s)) failed", __FUNCTION__, qPrintable(path));
return 0;
}
void QWindowsNativeFileDialogBase::setDirectory(const QString &directory)
{
- if (IShellItem *psi = QWindowsNativeFileDialogBase::shellItem(directory)) {
- m_fileDialog->SetFolder(psi);
- psi->Release();
+ if (!directory.isEmpty()) {
+ if (IShellItem *psi = QWindowsNativeFileDialogBase::shellItem(directory)) {
+ m_fileDialog->SetFolder(psi);
+ psi->Release();
+ }
}
}
@@ -832,17 +1004,94 @@ void QWindowsNativeFileDialogBase::setMode(QFileDialogOptions::FileMode mode, QF
qErrnoWarning("%s: SetOptions() failed", __FUNCTION__);
}
-QString QWindowsNativeFileDialogBase::itemPath(IShellItem *item)
+#if !defined(Q_OS_WINCE) && defined(__IShellLibrary_INTERFACE_DEFINED__) // Windows SDK 7
+
+// Helper for "Libraries": collections of folders appearing from Windows 7
+// on, visible in the file dialogs.
+
+// Load a library from a IShellItem (sanitized copy of the inline function
+// SHLoadLibraryFromItem from ShObjIdl.h, which does not exist for MinGW).
+static IShellLibrary *sHLoadLibraryFromItem(IShellItem *libraryItem, DWORD mode)
+{
+ // ID symbols present from Windows 7 on:
+ static const CLSID classId_ShellLibrary = {0xd9b3211d, 0xe57f, 0x4426, {0xaa, 0xef, 0x30, 0xa8, 0x6, 0xad, 0xd3, 0x97}};
+ static const IID iId_IShellLibrary = {0x11a66efa, 0x382e, 0x451a, {0x92, 0x34, 0x1e, 0xe, 0x12, 0xef, 0x30, 0x85}};
+
+ IShellLibrary *helper = 0;
+ IShellLibrary *result = 0;
+ if (SUCCEEDED(CoCreateInstance(classId_ShellLibrary, NULL, CLSCTX_INPROC_SERVER, iId_IShellLibrary, reinterpret_cast<void **>(&helper))))
+ if (SUCCEEDED(helper->LoadLibraryFromItem(libraryItem, mode)))
+ helper->QueryInterface(iId_IShellLibrary, reinterpret_cast<void **>(&result));
+ if (helper)
+ helper->Release();
+ return result;
+}
+
+// Return all folders of a library-type item.
+QStringList QWindowsNativeFileDialogBase::libraryItemFolders(IShellItem *item)
+{
+ QStringList result;
+ if (IShellLibrary *library = sHLoadLibraryFromItem(item, STGM_READ | STGM_SHARE_DENY_WRITE)) {
+ IShellItemArray *itemArray = 0;
+ if (SUCCEEDED(library->GetFolders(LFF_FORCEFILESYSTEM, IID_IShellItemArray, reinterpret_cast<void **>(&itemArray)))) {
+ QWindowsNativeFileDialogBase::itemPaths(itemArray, &result);
+ itemArray->Release();
+ }
+ library->Release();
+ }
+ return result;
+}
+
+// Return default save folders of a library-type item.
+QString QWindowsNativeFileDialogBase::libraryItemDefaultSaveFolder(IShellItem *item)
{
QString result;
- LPWSTR name = 0;
- if (SUCCEEDED(item->GetDisplayName(SIGDN_FILESYSPATH, &name))) {
- result = QDir::cleanPath(QString::fromWCharArray(name));
- CoTaskMemFree(name);
+ if (IShellLibrary *library = sHLoadLibraryFromItem(item, STGM_READ | STGM_SHARE_DENY_WRITE)) {
+ IShellItem *item = 0;
+ if (SUCCEEDED(library->GetDefaultSaveFolder(DSFT_DETECT, IID_IShellItem, reinterpret_cast<void **>(&item)))) {
+ result = QWindowsNativeFileDialogBase::itemPath(item);
+ item->Release();
+ }
+ library->Release();
}
return result;
}
+#else // !Q_OS_WINCE && __IShellLibrary_INTERFACE_DEFINED__
+
+QStringList QWindowsNativeFileDialogBase::libraryItemFolders(IShellItem *)
+{
+ return QStringList();
+}
+
+QString QWindowsNativeFileDialogBase::libraryItemDefaultSaveFolder(IShellItem *)
+{
+ return QString();
+}
+
+#endif // Q_OS_WINCE || !__IShellLibrary_INTERFACE_DEFINED__
+
+QString QWindowsNativeFileDialogBase::itemPath(IShellItem *item)
+{
+ SFGAOF attributes = 0;
+ // Check whether it has a file system representation?
+ if (FAILED(item->GetAttributes(SFGAO_FILESYSTEM, &attributes)))
+ return QString();
+ if (attributes & SFGAO_FILESYSTEM) {
+ LPWSTR name = 0;
+ QString result;
+ if (SUCCEEDED(item->GetDisplayName(SIGDN_FILESYSPATH, &name))) {
+ result = QDir::cleanPath(QString::fromWCharArray(name));
+ CoTaskMemFree(name);
+ }
+ return result;
+ }
+ // Check for a "Library" item
+ if ((QSysInfo::windowsVersion() & QSysInfo::WV_NT_based) && QSysInfo::windowsVersion() >= QSysInfo::WV_WINDOWS7)
+ return QWindowsNativeFileDialogBase::libraryItemDefaultSaveFolder(item);
+ return QString();
+}
+
int QWindowsNativeFileDialogBase::itemPaths(IShellItemArray *items,
QStringList *result /* = 0 */)
{
@@ -983,14 +1232,16 @@ static int indexOfNameFilter(const QStringList &filters, const QString &needle)
void QWindowsNativeFileDialogBase::selectNameFilter(const QString &filter)
{
+ if (filter.isEmpty())
+ return;
const int index = indexOfNameFilter(m_nameFilters, filter);
- if (index >= 0) {
- m_fileDialog->SetFileTypeIndex(index + 1); // one-based.
- } else {
+ if (index < 0) {
qWarning("%s: Invalid parameter '%s' not found in '%s'.",
__FUNCTION__, qPrintable(filter),
qPrintable(m_nameFilters.join(QStringLiteral(", "))));
+ return;
}
+ m_fileDialog->SetFileTypeIndex(index + 1); // one-based.
}
QString QWindowsNativeFileDialogBase::selectedNameFilter() const
@@ -1008,6 +1259,7 @@ void QWindowsNativeFileDialogBase::onFolderChange(IShellItem *item)
{
if (item) {
const QString directory = QWindowsNativeFileDialogBase::itemPath(item);
+ m_data.setDirectory(directory);
emit directoryEntered(directory);
}
}
@@ -1015,13 +1267,23 @@ void QWindowsNativeFileDialogBase::onFolderChange(IShellItem *item)
void QWindowsNativeFileDialogBase::onSelectionChange()
{
const QStringList current = selectedFiles();
+ m_data.setSelectedFiles(current);
if (current.size() == 1)
emit currentChanged(current.front());
}
void QWindowsNativeFileDialogBase::onTypeChange()
{
- emit filterSelected(selectedNameFilter());
+ const QString filter = selectedNameFilter();
+ m_data.setSelectedNameFilter(filter);
+ emit filterSelected(filter);
+}
+
+bool QWindowsNativeFileDialogBase::onFileOk()
+{
+ // Store selected files as GetResults() returns invalid data after the dialog closes.
+ m_data.setSelectedFiles(dialogResult());
+ return true;
}
HRESULT QWindowsNativeFileDialogEventHandler::OnFolderChanging(IFileDialog *, IShellItem *item)
@@ -1042,6 +1304,11 @@ HRESULT QWindowsNativeFileDialogEventHandler::OnTypeChange(IFileDialog *)
return S_OK;
}
+HRESULT QWindowsNativeFileDialogEventHandler::OnFileOk(IFileDialog *)
+{
+ return m_nativeFileDialog->onFileOk() ? S_OK : S_FALSE;
+}
+
/*!
\class QWindowsNativeSaveFileDialog
\brief Windows native file save dialog wrapper around IFileSaveDialog.
@@ -1055,8 +1322,10 @@ HRESULT QWindowsNativeFileDialogEventHandler::OnTypeChange(IFileDialog *)
class QWindowsNativeSaveFileDialog : public QWindowsNativeFileDialogBase
{
public:
- virtual QPlatformDialogHelper::DialogCode fileResult(QStringList *fileResult = 0) const;
+ explicit QWindowsNativeSaveFileDialog(const QWindowsFileDialogSharedData &data) :
+ QWindowsNativeFileDialogBase(data) {}
virtual QStringList selectedFiles() const;
+ virtual QStringList dialogResult() const;
};
// Append a suffix from the name filter "Foo files (*.foo;*.bar)"
@@ -1081,17 +1350,13 @@ static inline QString appendSuffix(const QString &fileName, const QString &filte
return fileName + QLatin1Char('.') + filter.mid(suffixPos, endPos - suffixPos);
}
-QPlatformDialogHelper::DialogCode QWindowsNativeSaveFileDialog::fileResult(QStringList *result /* = 0 */) const
+QStringList QWindowsNativeSaveFileDialog::dialogResult() const
{
- if (result)
- result->clear();
+ QStringList result;
IShellItem *item = 0;
- const HRESULT hr = fileDialog()->GetResult(&item);
- if (FAILED(hr) || !item)
- return QPlatformDialogHelper::Rejected;
- if (result)
- result->push_back(appendSuffix(QWindowsNativeFileDialogBase::itemPath(item), selectedNameFilter()));
- return QPlatformDialogHelper::Accepted;
+ if (SUCCEEDED(fileDialog()->GetResult(&item)) && item)
+ result.push_back(appendSuffix(QWindowsNativeFileDialogBase::itemPath(item), selectedNameFilter()));
+ return result;
}
QStringList QWindowsNativeSaveFileDialog::selectedFiles() const
@@ -1117,23 +1382,23 @@ QStringList QWindowsNativeSaveFileDialog::selectedFiles() const
class QWindowsNativeOpenFileDialog : public QWindowsNativeFileDialogBase
{
public:
- virtual QPlatformDialogHelper::DialogCode fileResult(QStringList *fileResult = 0) const;
+ explicit QWindowsNativeOpenFileDialog(const QWindowsFileDialogSharedData &data) :
+ QWindowsNativeFileDialogBase(data) {}
virtual QStringList selectedFiles() const;
+ virtual QStringList dialogResult() const;
private:
inline IFileOpenDialog *openFileDialog() const
{ return static_cast<IFileOpenDialog *>(fileDialog()); }
};
-QPlatformDialogHelper::DialogCode QWindowsNativeOpenFileDialog::fileResult(QStringList *result /* = 0 */) const
+QStringList QWindowsNativeOpenFileDialog::dialogResult() const
{
- if (result)
- result->clear();
+ QStringList result;
IShellItemArray *items = 0;
- const HRESULT hr = openFileDialog()->GetResults(&items);
- if (SUCCEEDED(hr) && items && QWindowsNativeFileDialogBase::itemPaths(items, result) > 0)
- return QPlatformDialogHelper::Accepted;
- return QPlatformDialogHelper::Rejected;
+ if (SUCCEEDED(openFileDialog()->GetResults(&items)) && items)
+ QWindowsNativeFileDialogBase::itemPaths(items, &result);
+ return result;
}
QStringList QWindowsNativeOpenFileDialog::selectedFiles() const
@@ -1152,17 +1417,18 @@ QStringList QWindowsNativeOpenFileDialog::selectedFiles() const
QFileDialog::AcceptMode.
*/
-QWindowsNativeFileDialogBase *QWindowsNativeFileDialogBase::create(QFileDialogOptions::AcceptMode am)
+QWindowsNativeFileDialogBase *QWindowsNativeFileDialogBase::create(QFileDialogOptions::AcceptMode am,
+ const QWindowsFileDialogSharedData &data)
{
QWindowsNativeFileDialogBase *result = 0;
if (am == QFileDialogOptions::AcceptOpen) {
- result = new QWindowsNativeOpenFileDialog;
+ result = new QWindowsNativeOpenFileDialog(data);
if (!result->init(CLSID_FileOpenDialog, IID_IFileOpenDialog)) {
delete result;
return 0;
}
} else {
- result = new QWindowsNativeSaveFileDialog;
+ result = new QWindowsNativeSaveFileDialog(data);
if (!result->init(CLSID_FileSaveDialog, IID_IFileSaveDialog)) {
delete result;
return 0;
@@ -1171,16 +1437,17 @@ QWindowsNativeFileDialogBase *QWindowsNativeFileDialogBase::create(QFileDialogOp
return result;
}
+static inline bool isQQuickWindow(const QWindow *w = 0)
+{
+ return w && w->inherits("QQuickWindow");
+}
+
/*!
\class QWindowsFileDialogHelper
\brief Helper for native Windows file dialogs
- Non-modal dialogs are disabled for now. The functionality is
- implemented in principle, however there are failures
- when querying the results from a dialog run in another thread.
- This could probably be fixed be calling CoInitializeEx() with
- the right parameters from each thread. The problem is though
- that calls to CoInitialize() occur in several places in Qt.
+ For Qt 4 compatibility, do not create native non-modal dialogs on widgets,
+ but only on QQuickWindows, which do not have a fallback.
\internal
\ingroup qt-lighthouse-win
@@ -1190,8 +1457,7 @@ class QWindowsFileDialogHelper : public QWindowsDialogHelperBase<QPlatformFileDi
{
public:
QWindowsFileDialogHelper() {}
- virtual bool supportsNonModalDialog() const { return false; }
-
+ virtual bool supportsNonModalDialog(const QWindow * /* parent */ = 0) const { return false; }
virtual bool defaultNameFilterDisables() const
{ return true; }
virtual void setDirectory(const QString &directory);
@@ -1207,11 +1473,14 @@ private:
virtual QWindowsNativeDialogBase *createNativeDialog();
inline QWindowsNativeFileDialogBase *nativeFileDialog() const
{ return static_cast<QWindowsNativeFileDialogBase *>(nativeDialog()); }
+
+ // Cache for the case no native dialog is created.
+ QWindowsFileDialogSharedData m_data;
};
QWindowsNativeDialogBase *QWindowsFileDialogHelper::createNativeDialog()
{
- QWindowsNativeFileDialogBase *result = QWindowsNativeFileDialogBase::create(options()->acceptMode());
+ QWindowsNativeFileDialogBase *result = QWindowsNativeFileDialogBase::create(options()->acceptMode(), m_data);
if (!result)
return 0;
QObject::connect(result, SIGNAL(accepted()), this, SIGNAL(accept()));
@@ -1225,8 +1494,10 @@ QWindowsNativeDialogBase *QWindowsFileDialogHelper::createNativeDialog()
// Apply settings.
const QSharedPointer<QFileDialogOptions> &opts = options();
+ m_data.fromOptions(opts);
+ const QFileDialogOptions::FileMode mode = opts->fileMode();
result->setWindowTitle(opts->windowTitle());
- result->setMode(opts->fileMode(), opts->options());
+ result->setMode(mode, opts->options());
result->setHideFiltersDetails(opts->testOption(QFileDialogOptions::HideNameFilterDetails));
const QStringList nameFilters = opts->nameFilters();
if (!nameFilters.isEmpty())
@@ -1235,18 +1506,20 @@ QWindowsNativeDialogBase *QWindowsFileDialogHelper::createNativeDialog()
result->setLabelText(QFileDialogOptions::FileName, opts->labelText(QFileDialogOptions::FileName));
if (opts->isLabelExplicitlySet(QFileDialogOptions::Accept))
result->setLabelText(QFileDialogOptions::Accept, opts->labelText(QFileDialogOptions::Accept));
- const QString initialDirectory = opts->initialDirectory();
- if (!initialDirectory.isEmpty())
- result->setDirectory(initialDirectory);
+ result->updateDirectory();
+ result->updateSelectedNameFilter();
const QStringList initialSelection = opts->initiallySelectedFiles();
if (initialSelection.size() > 0) {
QFileInfo info(initialSelection.front());
if (!info.isDir())
result->selectFile(info.fileName());
}
- const QString initialNameFilter = opts->initiallySelectedNameFilter();
- if (!initialNameFilter.isEmpty())
- result->selectNameFilter(initialNameFilter);
+ // No need to select initialNameFilter if mode is Dir
+ if (mode != QFileDialogOptions::Directory && mode != QFileDialogOptions::DirectoryOnly) {
+ const QString initialNameFilter = opts->initiallySelectedNameFilter();
+ if (!initialNameFilter.isEmpty())
+ result->selectNameFilter(initialNameFilter);
+ }
const QString defaultSuffix = opts->defaultSuffix();
if (!defaultSuffix.isEmpty())
result->setDefaultSuffix(defaultSuffix);
@@ -1258,15 +1531,14 @@ void QWindowsFileDialogHelper::setDirectory(const QString &directory)
if (QWindowsContext::verboseDialogs)
qDebug("%s %s" , __FUNCTION__, qPrintable(directory));
- if (QWindowsNativeFileDialogBase *nfd = nativeFileDialog())
- nfd->setDirectory(directory);
+ m_data.setDirectory(directory);
+ if (hasNativeDialog())
+ nativeFileDialog()->updateDirectory();
}
QString QWindowsFileDialogHelper::directory() const
{
- if (const QWindowsNativeFileDialogBase *nfd = nativeFileDialog())
- return nfd->directory();
- return QString();
+ return m_data.directory();
}
void QWindowsFileDialogHelper::selectFile(const QString &fileName)
@@ -1280,13 +1552,7 @@ void QWindowsFileDialogHelper::selectFile(const QString &fileName)
QStringList QWindowsFileDialogHelper::selectedFiles() const
{
- QStringList files;
- if (const QWindowsNativeFileDialogBase *nfd = nativeFileDialog())
- nfd->fileResult(&files);
- if (QWindowsContext::verboseDialogs)
- qDebug("%s files='%s'" , __FUNCTION__,
- qPrintable(files.join(QStringLiteral(", "))));
- return files;
+ return m_data.selectedFiles();
}
void QWindowsFileDialogHelper::setFilter()
@@ -1305,15 +1571,14 @@ void QWindowsFileDialogHelper::setNameFilters(const QStringList &filters)
void QWindowsFileDialogHelper::selectNameFilter(const QString &filter)
{
- if (QWindowsNativeFileDialogBase *nfd = nativeFileDialog())
- nfd->selectNameFilter(filter);
+ m_data.setSelectedNameFilter(filter);
+ if (hasNativeDialog())
+ nativeFileDialog()->updateSelectedNameFilter();
}
QString QWindowsFileDialogHelper::selectedNameFilter() const
{
- if (const QWindowsNativeFileDialogBase *nfd = nativeFileDialog())
- return nfd->selectedNameFilter();
- return QString();
+ return m_data.selectedNameFilter();
}
#ifndef Q_OS_WINCE
@@ -1337,20 +1602,12 @@ class QWindowsXpNativeFileDialog : public QWindowsNativeDialogBase
public:
typedef QSharedPointer<QFileDialogOptions> OptionsPtr;
- static QWindowsXpNativeFileDialog *create(const OptionsPtr &options);
+ static QWindowsXpNativeFileDialog *create(const OptionsPtr &options, const QWindowsFileDialogSharedData &data);
virtual void setWindowTitle(const QString &t) { m_title = t; }
virtual void exec(HWND owner = 0);
virtual QPlatformDialogHelper::DialogCode result() const { return m_result; }
- void setDirectory(const QString &d) { m_directory = d; }
- QString directory() const { return m_directory; }
- void selectFile(const QString &f) { m_initialFile = f; }
- QStringList selectedFiles() const { return m_selectedFiles; }
- void setNameFilters(const QStringList &n) { m_nameFilters = n; }
- void selectNameFilter(const QString &f);
- QString selectedNameFilter() const { return m_selectedNameFilter; }
-
int existingDirCallback(HWND hwnd, UINT uMsg, LPARAM lParam);
public slots:
@@ -1360,19 +1617,15 @@ private:
typedef BOOL (APIENTRY *PtrGetOpenFileNameW)(LPOPENFILENAMEW);
typedef BOOL (APIENTRY *PtrGetSaveFileNameW)(LPOPENFILENAMEW);
- explicit QWindowsXpNativeFileDialog(const OptionsPtr &options);
+ explicit QWindowsXpNativeFileDialog(const OptionsPtr &options, const QWindowsFileDialogSharedData &data);
void populateOpenFileName(OPENFILENAME *ofn, HWND owner) const;
QStringList execExistingDir(HWND owner);
QStringList execFileNames(HWND owner, int *selectedFilterIndex) const;
const OptionsPtr m_options;
QString m_title;
- QString m_directory;
- QString m_initialFile;
- QStringList m_selectedFiles;
- QString m_selectedNameFilter;
- QStringList m_nameFilters;
QPlatformDialogHelper::DialogCode m_result;
+ QWindowsFileDialogSharedData m_data;
static PtrGetOpenFileNameW m_getOpenFileNameW;
static PtrGetSaveFileNameW m_getSaveFileNameW;
@@ -1381,7 +1634,7 @@ private:
QWindowsXpNativeFileDialog::PtrGetOpenFileNameW QWindowsXpNativeFileDialog::m_getOpenFileNameW = 0;
QWindowsXpNativeFileDialog::PtrGetSaveFileNameW QWindowsXpNativeFileDialog::m_getSaveFileNameW = 0;
-QWindowsXpNativeFileDialog *QWindowsXpNativeFileDialog::create(const OptionsPtr &options)
+QWindowsXpNativeFileDialog *QWindowsXpNativeFileDialog::create(const OptionsPtr &options, const QWindowsFileDialogSharedData &data)
{
// GetOpenFileNameW() GetSaveFileName() are resolved
// dynamically as not to create a dependency on Comdlg32, which
@@ -1392,51 +1645,33 @@ QWindowsXpNativeFileDialog *QWindowsXpNativeFileDialog::create(const OptionsPtr
m_getSaveFileNameW = (PtrGetSaveFileNameW)(library.resolve("GetSaveFileNameW"));
}
if (m_getOpenFileNameW && m_getSaveFileNameW)
- return new QWindowsXpNativeFileDialog(options);
+ return new QWindowsXpNativeFileDialog(options, data);
return 0;
}
-QWindowsXpNativeFileDialog::QWindowsXpNativeFileDialog(const OptionsPtr &options) :
- m_options(options), m_result(QPlatformDialogHelper::Rejected)
+QWindowsXpNativeFileDialog::QWindowsXpNativeFileDialog(const OptionsPtr &options,
+ const QWindowsFileDialogSharedData &data) :
+ m_options(options), m_result(QPlatformDialogHelper::Rejected), m_data(data)
{
- const QStringList nameFilters = m_options->nameFilters();
- if (!nameFilters.isEmpty())
- setNameFilters(nameFilters);
- const QString initialDirectory = m_options->initialDirectory();
- if (!initialDirectory.isEmpty())
- setDirectory(initialDirectory);
- const QString initialNameFilter = m_options->initiallySelectedNameFilter();
- if (!initialNameFilter.isEmpty())
- selectNameFilter(initialNameFilter);
- const QStringList selectedFiles = m_options->initiallySelectedFiles();
- if (!selectedFiles.isEmpty())
- selectFile(selectedFiles.front());
setWindowTitle(m_options->windowTitle());
}
-void QWindowsXpNativeFileDialog::selectNameFilter(const QString &f)
-{
- const int index = indexOfNameFilter(m_nameFilters, f);
- if (index >= 0)
- m_selectedNameFilter = m_nameFilters.at(index);
-}
-
void QWindowsXpNativeFileDialog::exec(HWND owner)
{
int selectedFilterIndex = -1;
- m_selectedFiles = m_options->fileMode() == QFileDialogOptions::DirectoryOnly ?
+ const QStringList selectedFiles =
+ m_options->fileMode() == QFileDialogOptions::DirectoryOnly ?
execExistingDir(owner) : execFileNames(owner, &selectedFilterIndex);
+ m_data.setSelectedFiles(selectedFiles);
QWindowsDialogs::eatMouseMove();
- if (m_selectedFiles.isEmpty()) {
+ if (selectedFiles.isEmpty()) {
m_result = QPlatformDialogHelper::Rejected;
emit rejected();
} else {
- if (selectedFilterIndex >= 0 && selectedFilterIndex < m_nameFilters.size()) {
- m_selectedNameFilter = m_nameFilters.at(selectedFilterIndex);
- } else {
- m_selectedNameFilter.clear();
- }
- m_directory = QFileInfo(m_selectedFiles.front()).absolutePath();
+ const QStringList nameFilters = m_options->nameFilters();
+ if (selectedFilterIndex >= 0 && selectedFilterIndex < nameFilters.size())
+ m_data.setSelectedNameFilter(nameFilters.at(selectedFilterIndex));
+ m_data.setDirectory(QFileInfo(selectedFiles.front()).absolutePath());
m_result = QPlatformDialogHelper::Accepted;
emit accepted();
}
@@ -1460,9 +1695,11 @@ typedef PIDLIST_ABSOLUTE qt_LpItemIdList;
int QWindowsXpNativeFileDialog::existingDirCallback(HWND hwnd, UINT uMsg, LPARAM lParam)
{
switch (uMsg) {
- case BFFM_INITIALIZED:
- if (!m_initialFile.isEmpty())
- SendMessage(hwnd, BFFM_SETSELECTION, TRUE, LPARAM(m_initialFile.utf16()));
+ case BFFM_INITIALIZED: {
+ const QString initialFile = m_data.selectedFile();
+ if (!initialFile.isEmpty())
+ SendMessage(hwnd, BFFM_SETSELECTION, TRUE, LPARAM(initialFile.utf16()));
+ }
break;
case BFFM_SELCHANGED: {
wchar_t path[MAX_PATH];
@@ -1534,7 +1771,7 @@ void QWindowsXpNativeFileDialog::populateOpenFileName(OPENFILENAME *ofn, HWND ow
*ptr++ = 0;
}
*ptr = 0;
- const int nameFilterIndex = indexOfNameFilter(m_nameFilters, m_selectedNameFilter);
+ const int nameFilterIndex = indexOfNameFilter(m_options->nameFilters(), m_data.selectedNameFilter());
if (nameFilterIndex >= 0)
ofn->nFilterIndex = nameFilterIndex + 1; // 1..n based.
// lpstrFile receives the initial selection and is the buffer
@@ -1542,10 +1779,10 @@ void QWindowsXpNativeFileDialog::populateOpenFileName(OPENFILENAME *ofn, HWND ow
// will not show.
ofn->nMaxFile = 65535;
const QString initiallySelectedFile =
- QDir::toNativeSeparators(m_initialFile).remove(QLatin1Char('<')).
+ QDir::toNativeSeparators(m_data.selectedFile()).remove(QLatin1Char('<')).
remove(QLatin1Char('>')).remove(QLatin1Char('"')).remove(QLatin1Char('|'));
ofn->lpstrFile = qStringToWCharArray(initiallySelectedFile, ofn->nMaxFile);
- ofn->lpstrInitialDir = qStringToWCharArray(QDir::toNativeSeparators(m_directory));
+ ofn->lpstrInitialDir = qStringToWCharArray(QDir::toNativeSeparators(m_data.directory()));
ofn->lpstrTitle = (wchar_t*)m_title.utf16();
// Determine lpstrDefExt. Note that the current MSDN docs document this
// member wrong. It should rather be documented as "the default extension
@@ -1614,8 +1851,7 @@ class QWindowsXpFileDialogHelper : public QWindowsDialogHelperBase<QPlatformFile
{
public:
QWindowsXpFileDialogHelper() {}
- virtual bool supportsNonModalDialog() const { return false; }
-
+ virtual bool supportsNonModalDialog(const QWindow * /* parent */ = 0) const { return false; }
virtual bool defaultNameFilterDisables() const
{ return true; }
virtual void setDirectory(const QString &directory);
@@ -1631,11 +1867,14 @@ private:
virtual QWindowsNativeDialogBase *createNativeDialog();
inline QWindowsXpNativeFileDialog *nativeFileDialog() const
{ return static_cast<QWindowsXpNativeFileDialog *>(nativeDialog()); }
+
+ QWindowsFileDialogSharedData m_data;
};
QWindowsNativeDialogBase *QWindowsXpFileDialogHelper::createNativeDialog()
{
- if (QWindowsNativeDialogBase *result = QWindowsXpNativeFileDialog::create(options())) {
+ m_data.fromOptions(options());
+ if (QWindowsXpNativeFileDialog *result = QWindowsXpNativeFileDialog::create(options(), m_data)) {
QObject::connect(result, SIGNAL(accepted()), this, SIGNAL(accept()));
QObject::connect(result, SIGNAL(rejected()), this, SIGNAL(reject()));
return result;
@@ -1645,47 +1884,37 @@ QWindowsNativeDialogBase *QWindowsXpFileDialogHelper::createNativeDialog()
void QWindowsXpFileDialogHelper::setDirectory(const QString &directory)
{
- if (QWindowsXpNativeFileDialog *nfd = nativeFileDialog())
- nfd->setDirectory(directory);
+ m_data.setDirectory(directory); // Dialog cannot be updated at run-time.
}
QString QWindowsXpFileDialogHelper::directory() const
{
- if (const QWindowsXpNativeFileDialog *nfd = nativeFileDialog())
- return nfd->directory();
- return QString();
+ return m_data.directory();
}
void QWindowsXpFileDialogHelper::selectFile(const QString &filename)
{
- if (QWindowsXpNativeFileDialog *nfd = nativeFileDialog())
- nfd->selectFile(filename);
+ m_data.setSelectedFiles(QStringList(filename)); // Dialog cannot be updated at run-time.
}
QStringList QWindowsXpFileDialogHelper::selectedFiles() const
{
- if (const QWindowsXpNativeFileDialog *nfd = nativeFileDialog())
- return nfd->selectedFiles();
- return QStringList();
+ return m_data.selectedFiles();
}
-void QWindowsXpFileDialogHelper::setNameFilters(const QStringList &n)
+void QWindowsXpFileDialogHelper::setNameFilters(const QStringList &)
{
- if (QWindowsXpNativeFileDialog *nfd = nativeFileDialog())
- nfd->setNameFilters(n);
+ // Dialog cannot be updated at run-time.
}
void QWindowsXpFileDialogHelper::selectNameFilter(const QString &f)
{
- if (QWindowsXpNativeFileDialog *nfd = nativeFileDialog())
- nfd->selectNameFilter(f);
+ m_data.setSelectedNameFilter(f); // Dialog cannot be updated at run-time.
}
QString QWindowsXpFileDialogHelper::selectedNameFilter() const
{
- if (const QWindowsXpNativeFileDialog *nfd = nativeFileDialog())
- return nfd->selectedNameFilter();
- return QString();
+ return m_data.selectedNameFilter();
}
#endif // Q_OS_WINCE
diff --git a/src/plugins/platforms/windows/qwindowsdialoghelpers.h b/src/plugins/platforms/windows/qwindowsdialoghelpers.h
index 07f105cb35..7884f398f3 100644
--- a/src/plugins/platforms/windows/qwindowsdialoghelpers.h
+++ b/src/plugins/platforms/windows/qwindowsdialoghelpers.h
@@ -65,6 +65,7 @@ template <class BaseClass>
class QWindowsDialogHelperBase : public BaseClass
{
public:
+ ~QWindowsDialogHelperBase() { deleteNativeDialog(); }
virtual void exec();
virtual bool show(Qt::WindowFlags windowFlags,
@@ -73,19 +74,24 @@ public:
virtual void hide();
virtual QVariant styleHint(QPlatformDialogHelper::StyleHint) const;
- virtual bool supportsNonModalDialog() const { return true; }
+ virtual bool supportsNonModalDialog(const QWindow * /* parent */ = 0) const { return true; }
protected:
QWindowsDialogHelperBase();
- ~QWindowsDialogHelperBase();
QWindowsNativeDialogBase *nativeDialog() const;
+ inline bool hasNativeDialog() const { return m_nativeDialog; }
+ void deleteNativeDialog();
+ void timerEvent(QTimerEvent *);
private:
virtual QWindowsNativeDialogBase *createNativeDialog() = 0;
inline QWindowsNativeDialogBase *ensureNativeDialog();
+ inline void startDialogThread();
+ inline void stopTimer();
QWindowsNativeDialogBase *m_nativeDialog;
HWND m_ownerWindow;
+ int m_timerId;
};
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/windows/qwindowsdrag.cpp b/src/plugins/platforms/windows/qwindowsdrag.cpp
index 1286f5c106..fedda750d9 100644
--- a/src/plugins/platforms/windows/qwindowsdrag.cpp
+++ b/src/plugins/platforms/windows/qwindowsdrag.cpp
@@ -304,10 +304,10 @@ private:
class DragCursorHandle {
Q_DISABLE_COPY(DragCursorHandle)
public:
- DragCursorHandle(HCURSOR c, quint64 k) : cursor(c), cacheKey(k) {}
+ DragCursorHandle(HCURSOR c, qint64 k) : cursor(c), cacheKey(k) {}
~DragCursorHandle() { DestroyCursor(cursor); }
HCURSOR cursor;
- quint64 cacheKey;
+ qint64 cacheKey;
};
typedef QMap <Qt::DropAction, QSharedPointer<DragCursorHandle> > ActionCursorMap;
@@ -490,7 +490,7 @@ QWindowsOleDropSource::GiveFeedback(DWORD dwEffect)
qDebug("%s dwEffect=%lu, action=%d", __FUNCTION__, dwEffect, action);
QSharedPointer<DragCursorHandle> cursorHandler = m_cursors.value(action);
- quint64 currentCacheKey = m_drag->currentDrag()->dragCursor(action).cacheKey();
+ qint64 currentCacheKey = m_drag->currentDrag()->dragCursor(action).cacheKey();
if (cursorHandler.isNull() || currentCacheKey != cursorHandler->cacheKey)
createCursors();
diff --git a/src/plugins/platforms/windows/qwindowsfontdatabase.cpp b/src/plugins/platforms/windows/qwindowsfontdatabase.cpp
index b4fb19e8e8..5fa954cb12 100644
--- a/src/plugins/platforms/windows/qwindowsfontdatabase.cpp
+++ b/src/plugins/platforms/windows/qwindowsfontdatabase.cpp
@@ -606,130 +606,6 @@ QDebug operator<<(QDebug d, const QFontDef &def)
return d;
}
-/* From QFontDatabase.cpp, qt_determine_writing_systems_from_truetype_bits().
- * Fixme: Make public? */
-
-// see the Unicode subset bitfields in the MSDN docs
-static int requiredUnicodeBits[QFontDatabase::WritingSystemsCount][2] = {
- // Any,
- { 127, 127 },
- // Latin,
- { 0, 127 },
- // Greek,
- { 7, 127 },
- // Cyrillic,
- { 9, 127 },
- // Armenian,
- { 10, 127 },
- // Hebrew,
- { 11, 127 },
- // Arabic,
- { 13, 127 },
- // Syriac,
- { 71, 127 },
- //Thaana,
- { 72, 127 },
- //Devanagari,
- { 15, 127 },
- //Bengali,
- { 16, 127 },
- //Gurmukhi,
- { 17, 127 },
- //Gujarati,
- { 18, 127 },
- //Oriya,
- { 19, 127 },
- //Tamil,
- { 20, 127 },
- //Telugu,
- { 21, 127 },
- //Kannada,
- { 22, 127 },
- //Malayalam,
- { 23, 127 },
- //Sinhala,
- { 73, 127 },
- //Thai,
- { 24, 127 },
- //Lao,
- { 25, 127 },
- //Tibetan,
- { 70, 127 },
- //Myanmar,
- { 74, 127 },
- // Georgian,
- { 26, 127 },
- // Khmer,
- { 80, 127 },
- // SimplifiedChinese,
- { 126, 127 },
- // TraditionalChinese,
- { 126, 127 },
- // Japanese,
- { 126, 127 },
- // Korean,
- { 56, 127 },
- // Vietnamese,
- { 0, 127 }, // same as latin1
- // Other,
- { 126, 127 },
- // Ogham,
- { 78, 127 },
- // Runic,
- { 79, 127 },
- // Nko,
- { 14, 127 },
-};
-
-enum
-{
- SimplifiedChineseCsbBit = 18,
- TraditionalChineseCsbBit = 20,
- JapaneseCsbBit = 17,
- KoreanCsbBit = 21
-};
-
-static inline void writingSystemsFromTrueTypeBits(quint32 unicodeRange[4],
- quint32 codePageRange[2],
- QSupportedWritingSystems *ws)
-{
- bool hasScript = false;
- for(int i = 0; i < QFontDatabase::WritingSystemsCount; i++) {
- int bit = requiredUnicodeBits[i][0];
- int index = bit/32;
- int flag = 1 << (bit&31);
- if (bit != 126 && unicodeRange[index] & flag) {
- bit = requiredUnicodeBits[i][1];
- index = bit/32;
-
- flag = 1 << (bit&31);
- if (bit == 127 || unicodeRange[index] & flag) {
- ws->setSupported(QFontDatabase::WritingSystem(i), true);
- hasScript = true;
- }
- }
- }
- if(codePageRange[0] & (1 << SimplifiedChineseCsbBit)) {
- ws->setSupported(QFontDatabase::SimplifiedChinese, true);
- hasScript = true;
- }
- if(codePageRange[0] & (1 << TraditionalChineseCsbBit)) {
- ws->setSupported(QFontDatabase::TraditionalChinese, true);
- hasScript = true;
- }
- if(codePageRange[0] & (1 << JapaneseCsbBit)) {
- ws->setSupported(QFontDatabase::Japanese, true);
- hasScript = true;
- //qDebug("font %s supports Japanese", familyName.latin1());
- }
- if(codePageRange[0] & (1 << KoreanCsbBit)) {
- ws->setSupported(QFontDatabase::Korean, true);
- hasScript = true;
- }
- if (!hasScript)
- ws->setSupported(QFontDatabase::Symbol, true);
-}
-
// convert 0 ~ 1000 integer to QFont::Weight
static inline QFont::Weight weightFromInteger(long weight)
{
@@ -744,36 +620,43 @@ static inline QFont::Weight weightFromInteger(long weight)
return QFont::Black;
}
-static inline QFontDatabase::WritingSystem writingSystemFromScript(const QString &scriptName)
+static inline QFontDatabase::WritingSystem writingSystemFromCharSet(uchar charSet)
{
- if (scriptName == QStringLiteral("Western")
- || scriptName == QStringLiteral("Baltic")
- || scriptName == QStringLiteral("Central European")
- || scriptName == QStringLiteral("Turkish")
- || scriptName == QStringLiteral("Vietnamese")
- || scriptName == QStringLiteral("OEM/Dos"))
+ switch (charSet) {
+ case ANSI_CHARSET:
+ case EASTEUROPE_CHARSET:
+ case BALTIC_CHARSET:
+ case TURKISH_CHARSET:
+ case OEM_CHARSET:
return QFontDatabase::Latin;
- if (scriptName == QStringLiteral("Thai"))
+ case GREEK_CHARSET:
+ return QFontDatabase::Greek;
+ case RUSSIAN_CHARSET:
+ return QFontDatabase::Cyrillic;
+ case HEBREW_CHARSET:
+ return QFontDatabase::Hebrew;
+ case ARABIC_CHARSET:
+ return QFontDatabase::Arabic;
+ case THAI_CHARSET:
return QFontDatabase::Thai;
- if (scriptName == QStringLiteral("Symbol")
- || scriptName == QStringLiteral("Other"))
- return QFontDatabase::Symbol;
- if (scriptName == QStringLiteral("CHINESE_GB2312"))
+ case GB2312_CHARSET:
return QFontDatabase::SimplifiedChinese;
- if (scriptName == QStringLiteral("CHINESE_BIG5"))
+ case CHINESEBIG5_CHARSET:
return QFontDatabase::TraditionalChinese;
- if (scriptName == QStringLiteral("Cyrillic"))
- return QFontDatabase::Cyrillic;
- if (scriptName == QStringLiteral("Hangul"))
- return QFontDatabase::Korean;
- if (scriptName == QStringLiteral("Hebrew"))
- return QFontDatabase::Hebrew;
- if (scriptName == QStringLiteral("Greek"))
- return QFontDatabase::Greek;
- if (scriptName == QStringLiteral("Japanese"))
+ case SHIFTJIS_CHARSET:
return QFontDatabase::Japanese;
- if (scriptName == QStringLiteral("Arabic"))
- return QFontDatabase::Arabic;
+ case HANGUL_CHARSET:
+ case JOHAB_CHARSET:
+ return QFontDatabase::Korean;
+ case VIETNAMESE_CHARSET:
+ return QFontDatabase::Vietnamese;
+ case SYMBOL_CHARSET:
+ return QFontDatabase::Symbol;
+ // ### case MAC_CHARSET:
+ // ### case DEFAULT_CHARSET:
+ default:
+ break;
+ }
return QFontDatabase::Any;
}
@@ -957,7 +840,7 @@ error:
Q_GUI_EXPORT void qt_registerAliasToFontFamily(const QString &familyName, const QString &alias);
-static bool addFontToDatabase(QString familyName, const QString &scriptName,
+static bool addFontToDatabase(const QString &familyName, uchar charSet,
const TEXTMETRIC *textmetric,
const FONTSIGNATURE *signature,
int type)
@@ -981,7 +864,7 @@ static bool addFontToDatabase(QString familyName, const QString &scriptName,
#ifndef QT_NO_DEBUG_OUTPUT
if (QWindowsContext::verboseFonts > 2) {
QDebug nospace = qDebug().nospace();
- nospace << __FUNCTION__ << familyName << scriptName
+ nospace << __FUNCTION__ << familyName << charSet
<< "TTF=" << ttf;
if (type & DEVICE_FONTTYPE)
nospace << " DEVICE";
@@ -1001,6 +884,7 @@ static bool addFontToDatabase(QString familyName, const QString &scriptName,
QSupportedWritingSystems writingSystems;
if (type & TRUETYPE_FONTTYPE) {
+ Q_ASSERT(signature);
quint32 unicodeRange[4] = {
signature->fsUsb[0], signature->fsUsb[1],
signature->fsUsb[2], signature->fsUsb[3]
@@ -1019,7 +903,7 @@ static bool addFontToDatabase(QString familyName, const QString &scriptName,
unicodeRange[3] = 0xffffffff;
}
#endif
- writingSystemsFromTrueTypeBits(unicodeRange, codePageRange, &writingSystems);
+ writingSystems = QPlatformFontDatabase::writingSystemsFromTrueTypeBits(unicodeRange, codePageRange);
// ### Hack to work around problem with Thai text on Windows 7. Segoe UI contains
// the symbol for Baht, and Windows thus reports that it supports the Thai script.
// Since it's the default UI font on this platform, most widgets will be unable to
@@ -1029,7 +913,7 @@ static bool addFontToDatabase(QString familyName, const QString &scriptName,
familyName == QStringLiteral("Segoe UI"))
writingSystems.setSupported(QFontDatabase::Thai, false);
} else {
- const QFontDatabase::WritingSystem ws = writingSystemFromScript(scriptName);
+ const QFontDatabase::WritingSystem ws = writingSystemFromCharSet(charSet);
if (ws != QFontDatabase::Any)
writingSystems.setSupported(ws);
}
@@ -1058,14 +942,14 @@ static int CALLBACK storeFont(ENUMLOGFONTEX* f, NEWTEXTMETRICEX *textmetric,
{
typedef QSet<QString> StringSet;
const QString familyName = QString::fromWCharArray(f->elfLogFont.lfFaceName);
- const QString script = QString::fromWCharArray(f->elfScript);
+ const uchar charSet = f->elfLogFont.lfCharSet;
const FONTSIGNATURE signature = textmetric->ntmFontSig;
// NEWTEXTMETRICEX is a NEWTEXTMETRIC, which according to the documentation is
// identical to a TEXTMETRIC except for the last four members, which we don't use
// anyway
- if (addFontToDatabase(familyName, script, (TEXTMETRIC *)textmetric, &signature, type))
+ if (addFontToDatabase(familyName, charSet, (TEXTMETRIC *)textmetric, &signature, type))
reinterpret_cast<StringSet *>(namesSetIn)->insert(familyName);
// keep on enumerating
@@ -1160,9 +1044,7 @@ QWindowsFontDatabase::~QWindowsFontDatabase()
removeApplicationFonts();
}
-QFontEngine * QWindowsFontDatabase::fontEngine(const QFontDef &fontDef,
- QUnicodeTables::Script script,
- void *handle)
+QFontEngine * QWindowsFontDatabase::fontEngine(const QFontDef &fontDef, QChar::Script script, void *handle)
{
QFontEngine *fe = QWindowsFontDatabase::createEngine(script, fontDef,
0, QWindowsContext::instance()->defaultDPI(), false,
@@ -1215,7 +1097,7 @@ QFontEngine *QWindowsFontDatabase::fontEngine(const QByteArray &fontData, qreal
request.styleStrategy = QFont::NoFontMerging | QFont::PreferMatch;
request.hintingPreference = hintingPreference;
- fontEngine = QWindowsFontDatabase::createEngine(QUnicodeTables::Common, request, 0,
+ fontEngine = QWindowsFontDatabase::createEngine(QChar::Script_Common, request, 0,
QWindowsContext::instance()->defaultDPI(), false, QStringList(),
sharedFontData());
@@ -1223,11 +1105,11 @@ QFontEngine *QWindowsFontDatabase::fontEngine(const QByteArray &fontData, qreal
if (request.family != fontEngine->fontDef.family) {
qWarning("%s: Failed to load font. Got fallback instead: %s",
__FUNCTION__, qPrintable(fontEngine->fontDef.family));
- if (fontEngine->cache_count == 0 && fontEngine->ref.load() == 0)
+ if (fontEngine->ref.load() == 0)
delete fontEngine;
fontEngine = 0;
} else {
- Q_ASSERT(fontEngine->cache_count == 0 && fontEngine->ref.load() == 0);
+ Q_ASSERT(fontEngine->ref.load() == 0);
// Override the generated font name
static_cast<QWindowsFontEngine *>(fontEngine)->setUniqueFamilyName(uniqueFamilyName);
@@ -1439,7 +1321,7 @@ QStringList QWindowsFontDatabase::addApplicationFont(const QByteArray &fontData,
TEXTMETRIC textMetrics;
GetTextMetrics(hdc, &textMetrics);
- addFontToDatabase(familyName, QString(), &textMetrics, &signatures.at(j),
+ addFontToDatabase(familyName, lf.lfCharSet, &textMetrics, &signatures.at(j),
TRUETYPE_FONTTYPE);
SelectObject(hdc, oldobj);
@@ -1529,8 +1411,8 @@ HFONT QWindowsFontDatabase::systemFont()
static inline bool scriptRequiresOpenType(int script)
{
- return ((script >= QUnicodeTables::Syriac && script <= QUnicodeTables::Sinhala)
- || script == QUnicodeTables::Khmer || script == QUnicodeTables::Nko);
+ return ((script >= QChar::Script_Syriac && script <= QChar::Script_Sinhala)
+ || script == QChar::Script_Khmer || script == QChar::Script_Nko);
}
static const char *other_tryFonts[] = {
@@ -1715,7 +1597,7 @@ static QStringList extraTryFontsForFamily(const QString& family)
return result;
}
-QStringList QWindowsFontDatabase::fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const
+QStringList QWindowsFontDatabase::fallbacksForFamily(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script) const
{
QStringList result = QPlatformFontDatabase::fallbacksForFamily(family, style, styleHint, script);
if (!result.isEmpty())
@@ -1885,8 +1767,7 @@ QFontEngine *QWindowsFontDatabase::createEngine(int script, const QFontDef &requ
// for scripts that do not require OpenType we should just look at the list of
// supported writing systems in the font's OS/2 table.
if (scriptRequiresOpenType(script)) {
- HB_Face hbFace = few->harfbuzzFace();
- if (!hbFace || !hbFace->supported_scripts[script]) {
+ if (!few->supportsScript(QChar::Script(script))) {
qWarning(" OpenType support missing for script\n");
delete few;
return 0;
@@ -1917,7 +1798,7 @@ QFontEngine *QWindowsFontDatabase::createEngine(int script, const QFontDef &requ
directWriteFont->Release();
#endif
- if (script == QUnicodeTables::Common
+ if ((script == QChar::Script_Common || script == QChar::Script_Han)
&& !(request.styleStrategy & QFont::NoFontMerging)) {
QStringList extraFonts = extraTryFontsForFamily(request.family);
if (extraFonts.size()) {
diff --git a/src/plugins/platforms/windows/qwindowsfontdatabase.h b/src/plugins/platforms/windows/qwindowsfontdatabase.h
index c14d6027c2..b9e6c38eaa 100644
--- a/src/plugins/platforms/windows/qwindowsfontdatabase.h
+++ b/src/plugins/platforms/windows/qwindowsfontdatabase.h
@@ -78,9 +78,9 @@ public:
~QWindowsFontDatabase();
virtual void populateFontDatabase();
- virtual QFontEngine *fontEngine(const QFontDef &fontDef, QUnicodeTables::Script script, void *handle);
+ virtual QFontEngine *fontEngine(const QFontDef &fontDef, QChar::Script script, void *handle);
virtual QFontEngine *fontEngine(const QByteArray &fontData, qreal pixelSize, QFont::HintingPreference hintingPreference);
- virtual QStringList fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const;
+ virtual QStringList fallbacksForFamily(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script) const;
virtual QStringList addApplicationFont(const QByteArray &fontData, const QString &fileName);
virtual void releaseHandle(void *handle);
virtual QString fontDir() const;
diff --git a/src/plugins/platforms/windows/qwindowsfontdatabase_ft.cpp b/src/plugins/platforms/windows/qwindowsfontdatabase_ft.cpp
index 406dc636b8..98b4e7af62 100644
--- a/src/plugins/platforms/windows/qwindowsfontdatabase_ft.cpp
+++ b/src/plugins/platforms/windows/qwindowsfontdatabase_ft.cpp
@@ -57,39 +57,6 @@
QT_BEGIN_NAMESPACE
-static inline QFontDatabase::WritingSystem writingSystemFromScript(const QString &scriptName)
-{
- if (scriptName == QStringLiteral("Western")
- || scriptName == QStringLiteral("Baltic")
- || scriptName == QStringLiteral("Central European")
- || scriptName == QStringLiteral("Turkish")
- || scriptName == QStringLiteral("Vietnamese")
- || scriptName == QStringLiteral("OEM/Dos"))
- return QFontDatabase::Latin;
- if (scriptName == QStringLiteral("Thai"))
- return QFontDatabase::Thai;
- if (scriptName == QStringLiteral("Symbol")
- || scriptName == QStringLiteral("Other"))
- return QFontDatabase::Symbol;
- if (scriptName == QStringLiteral("CHINESE_GB2312"))
- return QFontDatabase::SimplifiedChinese;
- if (scriptName == QStringLiteral("CHINESE_BIG5"))
- return QFontDatabase::TraditionalChinese;
- if (scriptName == QStringLiteral("Cyrillic"))
- return QFontDatabase::Cyrillic;
- if (scriptName == QStringLiteral("Hangul"))
- return QFontDatabase::Korean;
- if (scriptName == QStringLiteral("Hebrew"))
- return QFontDatabase::Hebrew;
- if (scriptName == QStringLiteral("Greek"))
- return QFontDatabase::Greek;
- if (scriptName == QStringLiteral("Japanese"))
- return QFontDatabase::Japanese;
- if (scriptName == QStringLiteral("Arabic"))
- return QFontDatabase::Arabic;
- return QFontDatabase::Any;
-}
-
// convert 0 ~ 1000 integer to QFont::Weight
static inline QFont::Weight weightFromInteger(long weight)
{
@@ -104,6 +71,46 @@ static inline QFont::Weight weightFromInteger(long weight)
return QFont::Black;
}
+static inline QFontDatabase::WritingSystem writingSystemFromCharSet(uchar charSet)
+{
+ switch (charSet) {
+ case ANSI_CHARSET:
+ case EASTEUROPE_CHARSET:
+ case BALTIC_CHARSET:
+ case TURKISH_CHARSET:
+ case OEM_CHARSET:
+ return QFontDatabase::Latin;
+ case GREEK_CHARSET:
+ return QFontDatabase::Greek;
+ case RUSSIAN_CHARSET:
+ return QFontDatabase::Cyrillic;
+ case HEBREW_CHARSET:
+ return QFontDatabase::Hebrew;
+ case ARABIC_CHARSET:
+ return QFontDatabase::Arabic;
+ case THAI_CHARSET:
+ return QFontDatabase::Thai;
+ case GB2312_CHARSET:
+ return QFontDatabase::SimplifiedChinese;
+ case CHINESEBIG5_CHARSET:
+ return QFontDatabase::TraditionalChinese;
+ case SHIFTJIS_CHARSET:
+ return QFontDatabase::Japanese;
+ case HANGUL_CHARSET:
+ case JOHAB_CHARSET:
+ return QFontDatabase::Korean;
+ case VIETNAMESE_CHARSET:
+ return QFontDatabase::Vietnamese;
+ case SYMBOL_CHARSET:
+ return QFontDatabase::Symbol;
+ // ### case MAC_CHARSET:
+ // ### case DEFAULT_CHARSET:
+ default:
+ break;
+ }
+ return QFontDatabase::Any;
+}
+
static FontFile * createFontFile(const QString &fileName, int index)
{
FontFile *fontFile = new FontFile;
@@ -117,7 +124,7 @@ extern QString getEnglishName(const QString &familyName);
Q_GUI_EXPORT void qt_registerAliasToFontFamily(const QString &familyName, const QString &alias);
-static bool addFontToDatabase(QString familyName, const QString &scriptName,
+static bool addFontToDatabase(const QString &familyName, uchar charSet,
const TEXTMETRIC *textmetric,
const FONTSIGNATURE *signature,
int type)
@@ -148,7 +155,7 @@ static bool addFontToDatabase(QString familyName, const QString &scriptName,
#ifndef QT_NO_DEBUG_OUTPUT
if (QWindowsContext::verboseFonts > 2) {
QDebug nospace = qDebug().nospace();
- nospace << __FUNCTION__ << faceName << fullName << scriptName
+ nospace << __FUNCTION__ << familyName << faceName << fullName << charSet
<< "TTF=" << ttf;
if (type & DEVICE_FONTTYPE)
nospace << " DEVICE";
@@ -168,6 +175,7 @@ static bool addFontToDatabase(QString familyName, const QString &scriptName,
QSupportedWritingSystems writingSystems;
if (type & TRUETYPE_FONTTYPE) {
+ Q_ASSERT(signature);
quint32 unicodeRange[4] = {
signature->fsUsb[0], signature->fsUsb[1],
signature->fsUsb[2], signature->fsUsb[3]
@@ -175,7 +183,7 @@ static bool addFontToDatabase(QString familyName, const QString &scriptName,
quint32 codePageRange[2] = {
signature->fsCsb[0], signature->fsCsb[1]
};
- writingSystems = QBasicFontDatabase::determineWritingSystemsFromTrueTypeBits(unicodeRange, codePageRange);
+ writingSystems = QPlatformFontDatabase::writingSystemsFromTrueTypeBits(unicodeRange, codePageRange);
// ### Hack to work around problem with Thai text on Windows 7. Segoe UI contains
// the symbol for Baht, and Windows thus reports that it supports the Thai script.
// Since it's the default UI font on this platform, most widgets will be unable to
@@ -185,7 +193,7 @@ static bool addFontToDatabase(QString familyName, const QString &scriptName,
faceName == QStringLiteral("Segoe UI"))
writingSystems.setSupported(QFontDatabase::Thai, false);
} else {
- const QFontDatabase::WritingSystem ws = writingSystemFromScript(scriptName);
+ const QFontDatabase::WritingSystem ws = writingSystemFromCharSet(charSet);
if (ws != QFontDatabase::Any)
writingSystems.setSupported(ws);
}
@@ -308,14 +316,14 @@ static int CALLBACK storeFont(ENUMLOGFONTEX* f, NEWTEXTMETRICEX *textmetric,
const QString familyName = QString::fromWCharArray(f->elfLogFont.lfFaceName)
+ QStringLiteral("::")
+ QString::fromWCharArray(f->elfFullName);
- const QString script = QString::fromWCharArray(f->elfScript);
+ const uchar charSet = f->elfLogFont.lfCharSet;
const FONTSIGNATURE signature = textmetric->ntmFontSig;
// NEWTEXTMETRICEX is a NEWTEXTMETRIC, which according to the documentation is
// identical to a TEXTMETRIC except for the last four members, which we don't use
// anyway
- if (addFontToDatabase(familyName, script, (TEXTMETRIC *)textmetric, &signature, type))
+ if (addFontToDatabase(familyName, charSet, (TEXTMETRIC *)textmetric, &signature, type))
reinterpret_cast<StringSet *>(namesSetIn)->insert(familyName);
// keep on enumerating
@@ -362,7 +370,7 @@ void QWindowsFontDatabaseFT::populate(const QString &family)
ReleaseDC(0, dummy);
}
-QFontEngine * QWindowsFontDatabaseFT::fontEngine(const QFontDef &fontDef, QUnicodeTables::Script script, void *handle)
+QFontEngine * QWindowsFontDatabaseFT::fontEngine(const QFontDef &fontDef, QChar::Script script, void *handle)
{
QFontEngine *fe = QBasicFontDatabase::fontEngine(fontDef, script, handle);
if (QWindowsContext::verboseFonts)
@@ -430,9 +438,9 @@ static const char *kr_tryFonts[] = {
static const char **tryFonts = 0;
-QStringList QWindowsFontDatabaseFT::fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const
+QStringList QWindowsFontDatabaseFT::fallbacksForFamily(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script) const
{
- if(script == QUnicodeTables::Common) {
+ if (script == QChar::Script_Common || script == QChar::Script_Han) {
// && !(request.styleStrategy & QFont::NoFontMerging)) {
QFontDatabase db;
if (!db.writingSystems(family).contains(QFontDatabase::Symbol)) {
@@ -518,8 +526,8 @@ HFONT QWindowsFontDatabaseFT::systemFont()
static inline bool scriptRequiresOpenType(int script)
{
- return ((script >= QUnicodeTables::Syriac && script <= QUnicodeTables::Sinhala)
- || script == QUnicodeTables::Khmer || script == QUnicodeTables::Nko);
+ return ((script >= QChar::Script_Syriac && script <= QChar::Script_Sinhala)
+ || script == QChar::Script_Khmer || script == QChar::Script_Nko);
}
static inline int verticalDPI()
diff --git a/src/plugins/platforms/windows/qwindowsfontdatabase_ft.h b/src/plugins/platforms/windows/qwindowsfontdatabase_ft.h
index 2ce429d012..d3cbc0210a 100644
--- a/src/plugins/platforms/windows/qwindowsfontdatabase_ft.h
+++ b/src/plugins/platforms/windows/qwindowsfontdatabase_ft.h
@@ -52,10 +52,10 @@ class QWindowsFontDatabaseFT : public QBasicFontDatabase
{
public:
void populateFontDatabase();
- QFontEngine *fontEngine(const QFontDef &fontDef, QUnicodeTables::Script script, void *handle);
+ QFontEngine *fontEngine(const QFontDef &fontDef, QChar::Script script, void *handle);
QFontEngine *fontEngine(const QByteArray &fontData, qreal pixelSize, QFont::HintingPreference hintingPreference);
- QStringList fallbacksForFamily(const QString family, const QFont::Style &style, const QFont::StyleHint &styleHint, const QUnicodeTables::Script &script) const;
+ QStringList fallbacksForFamily(const QString &family, QFont::Style style, QFont::StyleHint styleHint, QChar::Script script) const;
virtual QString fontDir() const;
virtual QFont defaultFont() const;
diff --git a/src/plugins/platforms/windows/qwindowsfontengine.cpp b/src/plugins/platforms/windows/qwindowsfontengine.cpp
index 7fcd9814bd..c402f00453 100644
--- a/src/plugins/platforms/windows/qwindowsfontengine.cpp
+++ b/src/plugins/platforms/windows/qwindowsfontengine.cpp
@@ -66,7 +66,6 @@
#include <QtCore/QThreadStorage>
#include <QtCore/private/qsystemlibrary_p.h>
-#include <QtCore/private/qunicodetables_p.h>
#include <QtCore/QDebug>
#include <limits.h>
@@ -155,9 +154,20 @@ static OUTLINETEXTMETRIC *getOutlineTextMetric(HDC hdc)
return otm;
}
+bool QWindowsFontEngine::hasCFFTable() const
+{
+ HDC hdc = m_fontEngineData->hdc;
+ SelectObject(hdc, hfont);
+ return GetFontData(hdc, MAKE_TAG('C', 'F', 'F', ' '), 0, 0, 0) != GDI_ERROR;
+}
+
void QWindowsFontEngine::getCMap()
{
ttf = (bool)(tm.tmPitchAndFamily & TMPF_TRUETYPE);
+
+ // TMPF_TRUETYPE is not set for fonts with CFF tables
+ cffTable = !ttf && hasCFFTable();
+
HDC hdc = m_fontEngineData->hdc;
SelectObject(hdc, hfont);
bool symb = false;
@@ -1041,7 +1051,7 @@ void QWindowsFontEngine::getUnscaledGlyph(glyph_t glyph, QPainterPath *path, gly
bool QWindowsFontEngine::getSfntTableData(uint tag, uchar *buffer, uint *length) const
{
- if (!ttf)
+ if (!ttf && !cffTable)
return false;
HDC hdc = m_fontEngineData->hdc;
SelectObject(hdc, hfont);
@@ -1216,13 +1226,13 @@ QImage QWindowsFontEngine::alphaRGBMapForGlyph(glyph_t glyph, QFixed, const QTra
{
HFONT font = hfont;
- int contrast;
+ UINT contrast;
SystemParametersInfo(SPI_GETFONTSMOOTHINGCONTRAST, 0, &contrast, 0);
SystemParametersInfo(SPI_SETFONTSMOOTHINGCONTRAST, 0, (void *) 1000, 0);
int margin = glyphMargin(QFontEngineGlyphCache::Raster_RGBMask);
QWindowsNativeImage *mask = drawGDIGlyph(font, glyph, margin, t, QImage::Format_RGB32);
- SystemParametersInfo(SPI_SETFONTSMOOTHINGCONTRAST, 0, (void *) contrast, 0);
+ SystemParametersInfo(SPI_SETFONTSMOOTHINGCONTRAST, 0, (void *) quintptr(contrast), 0);
if (mask == 0)
return QImage();
@@ -1258,7 +1268,7 @@ QFontEngine *QWindowsFontEngine::cloneWithSize(qreal pixelSize) const
request.styleStrategy |= QFont::NoFontMerging;
QFontEngine *fontEngine =
- QWindowsFontDatabase::createEngine(QUnicodeTables::Common, request, 0,
+ QWindowsFontDatabase::createEngine(QChar::Script_Common, request, 0,
QWindowsContext::instance()->defaultDPI(),
false,
QStringList(), m_fontEngineData);
diff --git a/src/plugins/platforms/windows/qwindowsfontengine.h b/src/plugins/platforms/windows/qwindowsfontengine.h
index a23db2f235..2bf6ead503 100644
--- a/src/plugins/platforms/windows/qwindowsfontengine.h
+++ b/src/plugins/platforms/windows/qwindowsfontengine.h
@@ -145,6 +145,7 @@ public:
private:
QWindowsNativeImage *drawGDIGlyph(HFONT font, glyph_t, int margin, const QTransform &xform,
QImage::Format mask_format);
+ bool hasCFFTable() const;
const QSharedPointer<QWindowsFontEngineData> m_fontEngineData;
@@ -155,6 +156,7 @@ private:
uint stockFont : 1;
uint ttf : 1;
uint hasOutline : 1;
+ uint cffTable : 1;
TEXTMETRIC tm;
int lw;
const unsigned char *cmap;
diff --git a/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.cpp b/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.cpp
index 183acedfc8..5b6ce695d8 100644
--- a/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.cpp
+++ b/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.cpp
@@ -376,10 +376,12 @@ void QWindowsFontEngineDirectWrite::recalcAdvances(QGlyphLayout *glyphs, QFontEn
if (SUCCEEDED(hr)) {
for (int i=0; i<glyphs->numGlyphs; ++i) {
glyphs->advances_x[i] = DESIGN_TO_LOGICAL(glyphMetrics[i].advanceWidth);
- if (fontDef.styleStrategy & QFont::ForceIntegerMetrics)
- glyphs->advances_x[i] = glyphs->advances_x[i].round();
glyphs->advances_y[i] = 0;
}
+ if (fontDef.styleStrategy & QFont::ForceIntegerMetrics) {
+ for (int i = 0; i < glyphs->numGlyphs; ++i)
+ glyphs->advances_x[i] = glyphs->advances_x[i].round();
+ }
} else {
qErrnoWarning("%s: GetDesignGlyphMetrics failed", __FUNCTION__);
}
diff --git a/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.h b/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.h
index 35ed6f3891..106087f757 100644
--- a/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.h
+++ b/src/plugins/platforms/windows/qwindowsfontenginedirectwrite.h
@@ -42,6 +42,8 @@
#ifndef QWINDOWSFONTENGINEDIRECTWRITE_H
#define QWINDOWSFONTENGINEDIRECTWRITE_H
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_DIRECTWRITE
#include <QtGui/private/qfontengine_p.h>
diff --git a/src/plugins/platforms/windows/qwindowsglcontext.cpp b/src/plugins/platforms/windows/qwindowsglcontext.cpp
index 081b42ce65..da3e2a6a6a 100644
--- a/src/plugins/platforms/windows/qwindowsglcontext.cpp
+++ b/src/plugins/platforms/windows/qwindowsglcontext.cpp
@@ -232,6 +232,7 @@ static QSurfaceFormat
QWindowsOpenGLAdditionalFormat *additionalIn = 0)
{
QSurfaceFormat format;
+ format.setRenderableType(QSurfaceFormat::OpenGL);
if (pfd.dwFlags & PFD_DOUBLEBUFFER)
format.setSwapBehavior(QSurfaceFormat::DoubleBuffer);
format.setDepthBufferSize(pfd.cDepthBits);
@@ -278,7 +279,7 @@ static PIXELFORMATDESCRIPTOR
if (format.stereo())
pfd.dwFlags |= PFD_STEREO;
- if (format.swapBehavior() == QSurfaceFormat::DoubleBuffer && !isPixmap)
+ if (format.swapBehavior() != QSurfaceFormat::SingleBuffer && !isPixmap)
pfd.dwFlags |= PFD_DOUBLEBUFFER;
pfd.cDepthBits =
format.depthBufferSize() >= 0 ? format.depthBufferSize() : 32;
@@ -388,12 +389,11 @@ static int choosePixelFormat(HDC hdc,
iAttributes[i++] = WGL_COLOR_BITS_ARB;
iAttributes[i++] = 24;
switch (format.swapBehavior()) {
- case QSurfaceFormat::DefaultSwapBehavior:
- break;
case QSurfaceFormat::SingleBuffer:
iAttributes[i++] = WGL_DOUBLE_BUFFER_ARB;
iAttributes[i++] = FALSE;
break;
+ case QSurfaceFormat::DefaultSwapBehavior:
case QSurfaceFormat::DoubleBuffer:
case QSurfaceFormat::TripleBuffer:
iAttributes[i++] = WGL_DOUBLE_BUFFER_ARB;
@@ -500,6 +500,7 @@ static QSurfaceFormat
enum { attribSize =40 };
QSurfaceFormat result;
+ result.setRenderableType(QSurfaceFormat::OpenGL);
if (!staticContext.hasExtensions())
return result;
int iAttributes[attribSize];
@@ -875,6 +876,12 @@ QWindowsGLContext::QWindowsGLContext(const QOpenGLStaticContextPtr &staticContex
m_renderingContext(0),
m_pixelFormat(0), m_extensionsUsed(false)
{
+ QSurfaceFormat format = context->format();
+ if (format.renderableType() == QSurfaceFormat::DefaultRenderableType)
+ format.setRenderableType(QSurfaceFormat::OpenGL);
+ if (format.renderableType() != QSurfaceFormat::OpenGL)
+ return;
+
// workaround for matrox driver:
// make a cheap call to opengl to force loading of DLL
static bool opengl32dll = false;
@@ -912,7 +919,7 @@ QWindowsGLContext::QWindowsGLContext(const QOpenGLStaticContextPtr &staticContex
QWindowsOpenGLAdditionalFormat obtainedAdditional;
if (tryExtensions) {
m_pixelFormat =
- ARB::choosePixelFormat(hdc, *m_staticContext, context->format(),
+ ARB::choosePixelFormat(hdc, *m_staticContext, format,
requestedAdditional, &m_obtainedPixelFormatDescriptor);
if (m_pixelFormat > 0) {
m_obtainedFormat =
@@ -922,7 +929,7 @@ QWindowsGLContext::QWindowsGLContext(const QOpenGLStaticContextPtr &staticContex
}
} // tryExtensions
if (!m_pixelFormat) { // Failed, try GDI
- m_pixelFormat = GDI::choosePixelFormat(hdc, context->format(), requestedAdditional,
+ m_pixelFormat = GDI::choosePixelFormat(hdc, format, requestedAdditional,
&m_obtainedPixelFormatDescriptor);
if (m_pixelFormat)
m_obtainedFormat =
@@ -945,7 +952,7 @@ QWindowsGLContext::QWindowsGLContext(const QOpenGLStaticContextPtr &staticContex
if (m_extensionsUsed)
m_renderingContext =
ARB::createContext(*m_staticContext, hdc,
- context->format(),
+ format,
requestedAdditional,
sharingRenderingContext);
if (!m_renderingContext)
diff --git a/src/plugins/platforms/windows/qwindowsintegration.cpp b/src/plugins/platforms/windows/qwindowsintegration.cpp
index da4519199f..03e4925c3b 100644
--- a/src/plugins/platforms/windows/qwindowsintegration.cpp
+++ b/src/plugins/platforms/windows/qwindowsintegration.cpp
@@ -77,6 +77,7 @@
#include <QtCore/private/qeventdispatcher_win_p.h>
#include <QtCore/QDebug>
+#include <QtCore/QVariant>
QT_BEGIN_NAMESPACE
@@ -114,6 +115,11 @@ public:
bool asyncExpose() const;
void setAsyncExpose(bool value);
+
+ QVariantMap windowProperties(QPlatformWindow *window) const;
+ QVariant windowProperty(QPlatformWindow *window, const QString &name) const;
+ QVariant windowProperty(QPlatformWindow *window, const QString &name, const QVariant &defaultValue) const;
+ void setWindowProperty(QPlatformWindow *window, const QString &name, const QVariant &value);
};
void *QWindowsNativeInterface::nativeResourceForWindow(const QByteArray &resource, QWindow *window)
@@ -150,6 +156,37 @@ void *QWindowsNativeInterface::nativeResourceForBackingStore(const QByteArray &r
return 0;
}
+static const char customMarginPropertyC[] = "WindowsCustomMargins";
+
+QVariant QWindowsNativeInterface::windowProperty(QPlatformWindow *window, const QString &name) const
+{
+ QWindowsWindow *platformWindow = static_cast<QWindowsWindow *>(window);
+ if (name == QLatin1String(customMarginPropertyC))
+ return qVariantFromValue(platformWindow->customMargins());
+ return QVariant();
+}
+
+QVariant QWindowsNativeInterface::windowProperty(QPlatformWindow *window, const QString &name, const QVariant &defaultValue) const
+{
+ const QVariant result = windowProperty(window, name);
+ return result.isValid() ? result : defaultValue;
+}
+
+void QWindowsNativeInterface::setWindowProperty(QPlatformWindow *window, const QString &name, const QVariant &value)
+{
+ QWindowsWindow *platformWindow = static_cast<QWindowsWindow *>(window);
+ if (name == QLatin1String(customMarginPropertyC))
+ platformWindow->setCustomMargins(qvariant_cast<QMargins>(value));
+}
+
+QVariantMap QWindowsNativeInterface::windowProperties(QPlatformWindow *window) const
+{
+ QVariantMap result;
+ const QString customMarginProperty = QLatin1String(customMarginPropertyC);
+ result.insert(customMarginProperty, windowProperty(window, customMarginProperty));
+ return result;
+}
+
#ifndef QT_NO_OPENGL
void *QWindowsNativeInterface::nativeResourceForContext(const QByteArray &resource, QOpenGLContext *context)
{
@@ -372,6 +409,11 @@ QPlatformWindow *QWindowsIntegration::createPlatformWindow(QWindow *window) cons
QWindowsWindow::WindowData requested;
requested.flags = window->flags();
requested.geometry = window->geometry();
+ // Apply custom margins (see QWindowsWindow::setCustomMargins())).
+ const QVariant customMarginsV = window->property("_q_windowsCustomMargins");
+ if (customMarginsV.isValid())
+ requested.customMargins = qvariant_cast<QMargins>(customMarginsV);
+
const QWindowsWindow::WindowData obtained
= QWindowsWindow::WindowData::create(window, requested, window->title());
if (QWindowsContext::verboseIntegration || QWindowsContext::verboseWindows)
@@ -499,7 +541,6 @@ QVariant QWindowsIntegration::styleHint(QPlatformIntegration::StyleHint hint) co
case QPlatformIntegration::ShowIsFullScreen:
case QPlatformIntegration::PasswordMaskDelay:
case QPlatformIntegration::StartDragVelocity:
- case QPlatformIntegration::SynthesizeMouseFromTouchEvents:
break; // Not implemented
case QPlatformIntegration::FontSmoothingGamma:
return QVariant(QWindowsFontDatabase::fontSmoothingGamma());
@@ -509,6 +550,11 @@ QVariant QWindowsIntegration::styleHint(QPlatformIntegration::StyleHint hint) co
break;
case QPlatformIntegration::UseRtlExtensions:
return QVariant(d->m_context.useRTLExtensions());
+ case QPlatformIntegration::SynthesizeMouseFromTouchEvents:
+ // We do not want Qt to synthesize mouse events as Windows also does that.
+ // Alternatively, Windows-generated touch mouse events can be identified and
+ // ignored by checking GetMessageExtraInfo() for MI_WP_SIGNATURE (0xFF515700).
+ return false;
}
return QPlatformIntegration::styleHint(hint);
}
diff --git a/src/plugins/platforms/windows/qwindowsintegration.h b/src/plugins/platforms/windows/qwindowsintegration.h
index 24dc01f0bd..ca484415be 100644
--- a/src/plugins/platforms/windows/qwindowsintegration.h
+++ b/src/plugins/platforms/windows/qwindowsintegration.h
@@ -78,7 +78,7 @@ public:
# ifndef QT_NO_DRAGANDDROP
virtual QPlatformDrag *drag() const;
# endif
-#endif !QT_NO_CLIPBOARD
+#endif // !QT_NO_CLIPBOARD
virtual QPlatformInputContext *inputContext() const;
#ifndef QT_NO_ACCESSIBILITY
virtual QPlatformAccessibility *accessibility() const;
diff --git a/src/plugins/platforms/windows/qwindowskeymapper.cpp b/src/plugins/platforms/windows/qwindowskeymapper.cpp
index 56deb27442..924d604641 100644
--- a/src/plugins/platforms/windows/qwindowskeymapper.cpp
+++ b/src/plugins/platforms/windows/qwindowskeymapper.cpp
@@ -856,9 +856,15 @@ bool QWindowsKeyMapper::translateKeyEventInternal(QWindow *window, const MSG &ms
if (isNumpad && (nModifiers & AltAny)) {
code = winceKeyBend(msg.wParam);
} else if (!isDeadKey) {
- unsigned char kbdBuffer[256]; // Will hold the complete keyboard state
- GetKeyboardState(kbdBuffer);
- code = toKeyOrUnicode(msg.wParam, scancode, kbdBuffer);
+ // QTBUG-8764, QTBUG-10032
+ // Can't call toKeyOrUnicode because that would call ToUnicode, and, if a dead key
+ // is pressed at the moment, Windows would NOT use it to compose a character for the next
+ // WM_CHAR event.
+
+ // Instead, use MapVirtualKey, which will provide adequate values.
+ code = MapVirtualKey(msg.wParam, MAPVK_VK_TO_CHAR);
+ if (code < 0x20 || code == 0x7f) // The same logic as in toKeyOrUnicode()
+ code = winceKeyBend(msg.wParam);
}
// Invert state logic:
@@ -1120,7 +1126,7 @@ QList<int> QWindowsKeyMapper::possibleKeys(const QKeyEvent *e) const
}
result << int(baseKey + keyMods); // The base key is _always_ valid, of course
- for (int i = 1; i < NumMods; ++i) {
+ for (size_t i = 1; i < NumMods; ++i) {
Qt::KeyboardModifiers neededMods = ModsTbl[i];
quint32 key = kbItem.qtKey[i];
if (key && key != baseKey && ((keyMods & neededMods) == neededMods))
diff --git a/src/plugins/platforms/windows/qwindowsmime.cpp b/src/plugins/platforms/windows/qwindowsmime.cpp
index 7fb32d3513..a8bacd631d 100644
--- a/src/plugins/platforms/windows/qwindowsmime.cpp
+++ b/src/plugins/platforms/windows/qwindowsmime.cpp
@@ -703,14 +703,14 @@ QWindowsMimeURI::QWindowsMimeURI()
bool QWindowsMimeURI::canConvertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData) const
{
- if (getCf(formatetc) == CF_HDROP) {
+ if (mimeData->hasUrls() && getCf(formatetc) == CF_HDROP) {
QList<QUrl> urls = mimeData->urls();
for (int i=0; i<urls.size(); i++) {
if (!urls.at(i).toLocalFile().isEmpty())
return true;
}
}
- return (getCf(formatetc) == CF_INETURL_W || getCf(formatetc) == CF_INETURL) && mimeData->hasFormat(QStringLiteral("text/uri-list"));
+ return (getCf(formatetc) == CF_INETURL_W || getCf(formatetc) == CF_INETURL) && mimeData->hasUrls();
}
bool QWindowsMimeURI::convertFromMime(const FORMATETC &formatetc, const QMimeData *mimeData, STGMEDIUM *pmedium) const
diff --git a/src/plugins/platforms/windows/qwindowsmousehandler.cpp b/src/plugins/platforms/windows/qwindowsmousehandler.cpp
index e1f4f4b143..dd16ea1c6f 100644
--- a/src/plugins/platforms/windows/qwindowsmousehandler.cpp
+++ b/src/plugins/platforms/windows/qwindowsmousehandler.cpp
@@ -49,6 +49,7 @@
#include <qpa/qwindowsysteminterface.h>
#include <QtGui/QGuiApplication>
#include <QtGui/QScreen>
+#include <QtGui/QWindow>
#include <QtCore/QDebug>
#include <QtCore/QScopedArrayPointer>
@@ -236,6 +237,9 @@ bool QWindowsMouseHandler::translateMouseEvent(QWindow *window, HWND hwnd,
platformWindow->setFlag(QWindowsWindow::AutoMouseCapture);
if (QWindowsContext::verboseEvents)
qDebug() << "Automatic mouse capture " << window;
+ // Implement "Click to focus" for native child windows.
+ if (!window->isTopLevel() && QGuiApplication::focusWindow() != window)
+ window->requestActivate();
} else if (platformWindow->hasMouseCapture()
&& platformWindow->testFlag(QWindowsWindow::AutoMouseCapture)
&& (msg.message == WM_LBUTTONUP || msg.message == WM_MBUTTONUP
diff --git a/src/plugins/platforms/windows/qwindowsmousehandler.h b/src/plugins/platforms/windows/qwindowsmousehandler.h
index b3bfa03380..caf30e6b1a 100644
--- a/src/plugins/platforms/windows/qwindowsmousehandler.h
+++ b/src/plugins/platforms/windows/qwindowsmousehandler.h
@@ -109,6 +109,8 @@ Qt::KeyboardModifiers QWindowsMouseHandler::keyStateToModifiers(int wParam)
mods |= Qt::ControlModifier;
if (wParam & MK_SHIFT)
mods |= Qt::ShiftModifier;
+ if (GetKeyState(VK_MENU) < 0)
+ mods |= Qt::AltModifier;
return mods;
}
diff --git a/src/plugins/platforms/windows/qwindowsservices.cpp b/src/plugins/platforms/windows/qwindowsservices.cpp
index bcae2e0816..250fea56b1 100644
--- a/src/plugins/platforms/windows/qwindowsservices.cpp
+++ b/src/plugins/platforms/windows/qwindowsservices.cpp
@@ -44,6 +44,7 @@
#include <QtCore/QUrl>
#include <QtCore/QDebug>
+#include <QtCore/QDir>
#include <shlobj.h>
#ifndef Q_OS_WINCE
@@ -57,7 +58,8 @@ enum { debug = 0 };
static inline bool shellExecute(const QString &file)
{
#ifndef Q_OS_WINCE
- const quintptr result = (quintptr)ShellExecute(0, 0, (wchar_t*)file.utf16(), 0, 0, SW_SHOWNORMAL);
+ const QString nativeFilePath = QDir::toNativeSeparators(file);
+ const quintptr result = (quintptr)ShellExecute(0, 0, (wchar_t*)nativeFilePath.utf16(), 0, 0, SW_SHOWNORMAL);
// ShellExecute returns a value greater than 32 if successful
if (result <= 32) {
qWarning("ShellExecute '%s' failed (error %s).", qPrintable(file), qPrintable(QString::number(result)));
diff --git a/src/plugins/platforms/windows/qwindowswindow.cpp b/src/plugins/platforms/windows/qwindowswindow.cpp
index 07dc668b3f..9b2b67619d 100644
--- a/src/plugins/platforms/windows/qwindowswindow.cpp
+++ b/src/plugins/platforms/windows/qwindowswindow.cpp
@@ -64,6 +64,11 @@
QT_BEGIN_NAMESPACE
+enum {
+ defaultWindowWidth = 160,
+ defaultWindowHeight = 160
+};
+
Q_GUI_EXPORT HICON qt_pixmapToWinHICON(const QPixmap &);
static QByteArray debugWinStyle(DWORD style)
@@ -198,17 +203,16 @@ static inline QSize clientSize(HWND hwnd)
return qSizeOfRect(rect);
}
-// from qwidget_win.cpp/maximum layout size check removed.
-static bool shouldShowMaximizeButton(Qt::WindowFlags flags)
+// from qwidget_win.cpp
+static bool shouldShowMaximizeButton(const QWindow *w)
{
- if (flags & Qt::MSWindowsFixedSizeDialogHint)
+ const Qt::WindowFlags flags = w->flags();
+ if ((flags & Qt::MSWindowsFixedSizeDialogHint) || !(flags & Qt::WindowMaximizeButtonHint))
return false;
// if the user explicitly asked for the maximize button, we try to add
// it even if the window has fixed size.
- if (flags & Qt::CustomizeWindowHint &&
- flags & Qt::WindowMaximizeButtonHint)
- return true;
- return flags & Qt::WindowMaximizeButtonHint;
+ return (flags & Qt::CustomizeWindowHint) ||
+ w->maximumSize() == QSize(QWINDOWSIZE_MAX, QWINDOWSIZE_MAX);
}
// Set the WS_EX_LAYERED flag on a HWND if required. This is required for
@@ -253,6 +257,8 @@ static void setWindowOpacity(HWND hwnd, Qt::WindowFlags flags, bool hasAlpha, qr
} else {
QWindowsContext::user32dll.setLayeredWindowAttributes(hwnd, 0, (int)(level * 255), LWA_ALPHA);
}
+ } else if (IsWindowVisible(hwnd)) { // Repaint when switching from layered.
+ InvalidateRect(hwnd, NULL, TRUE);
}
#endif // !Q_OS_WINCE
}
@@ -296,7 +302,7 @@ struct WindowCreationData
tool(false), embedded(false), hasAlpha(false) {}
void fromWindow(const QWindow *w, const Qt::WindowFlags flags, unsigned creationFlags = 0);
- inline WindowData create(const QWindow *w, const QRect &geometry, QString title) const;
+ inline WindowData create(const QWindow *w, const WindowData &data, QString title) const;
inline void applyWindowFlags(HWND hwnd) const;
void initialize(HWND h, bool frameChange, qreal opacityLevel) const;
@@ -427,7 +433,7 @@ void WindowCreationData::fromWindow(const QWindow *w, const Qt::WindowFlags flag
style |= WS_SYSMENU;
if (flags & Qt::WindowMinimizeButtonHint)
style |= WS_MINIMIZEBOX;
- if (shouldShowMaximizeButton(flags))
+ if (shouldShowMaximizeButton(w))
style |= WS_MAXIMIZEBOX;
if (tool)
exStyle |= WS_EX_TOOLWINDOW;
@@ -448,7 +454,7 @@ void WindowCreationData::fromWindow(const QWindow *w, const Qt::WindowFlags flag
}
QWindowsWindow::WindowData
- WindowCreationData::create(const QWindow *w, const QRect &geometry, QString title) const
+ WindowCreationData::create(const QWindow *w, const WindowData &data, QString title) const
{
typedef QSharedPointer<QWindowCreationContext> QWindowCreationContextPtr;
@@ -468,30 +474,38 @@ QWindowsWindow::WindowData
const QString windowClassName = QWindowsContext::instance()->registerWindowClass(w, isGL);
+ QRect rect = QPlatformWindow::initialGeometry(w, data.geometry, defaultWindowWidth, defaultWindowHeight);
+
if (title.isEmpty() && (result.flags & Qt::WindowTitleHint))
title = topLevel ? qAppName() : w->objectName();
const wchar_t *titleUtf16 = reinterpret_cast<const wchar_t *>(title.utf16());
const wchar_t *classNameUtf16 = reinterpret_cast<const wchar_t *>(windowClassName.utf16());
- // Capture events before CreateWindowEx() returns.
- const QWindowCreationContextPtr context(new QWindowCreationContext(w, geometry, style, exStyle));
+ // Capture events before CreateWindowEx() returns. The context is cleared in
+ // the QWindowsWindow constructor.
+ const QWindowCreationContextPtr context(new QWindowCreationContext(w, rect, data.customMargins, style, exStyle));
QWindowsContext::instance()->setWindowCreationContext(context);
+ if (context->frameX < 0)
+ context->frameX = 0;
+ if (context->frameY < 0)
+ context->frameY = 0;
+
if (QWindowsContext::verboseWindows)
qDebug().nospace()
<< "CreateWindowEx: " << w << *this
<< " class=" <<windowClassName << " title=" << title
- << "\nrequested: " << geometry << ": "
+ << "\nrequested: " << rect << ": "
<< context->frameWidth << 'x' << context->frameHeight
- << '+' << context->frameX << '+' << context->frameY;
+ << '+' << context->frameX << '+' << context->frameY
+ << " custom margins: " << context->customMargins;
result.hwnd = CreateWindowEx(exStyle, classNameUtf16, titleUtf16,
style,
context->frameX, context->frameY,
context->frameWidth, context->frameHeight,
parentHandle, NULL, appinst, NULL);
- QWindowsContext::instance()->setWindowCreationContext(QWindowCreationContextPtr());
if (QWindowsContext::verboseWindows)
qDebug().nospace()
<< "CreateWindowEx: returns " << w << ' ' << result.hwnd << " obtained geometry: "
@@ -505,6 +519,7 @@ QWindowsWindow::WindowData
result.geometry = context->obtainedGeometry;
result.frame = context->margins;
result.embedded = embedded;
+ result.customMargins = context->customMargins;
return result;
}
@@ -543,6 +558,8 @@ void WindowCreationData::initialize(HWND hwnd, bool frameChange, qreal opacityLe
qWarning() << "QWidget: Incompatible window flags: the window can't be on top and on bottom at the same time";
} else if (flags & Qt::WindowStaysOnBottomHint) {
SetWindowPos(hwnd, HWND_BOTTOM, 0, 0, 0, 0, swpFlags);
+ } else if (frameChange) { // Force WM_NCCALCSIZE with wParam=1 in case of custom margins.
+ SetWindowPos(hwnd, 0, 0, 0, 0, 0, swpFlags);
}
if (flags & (Qt::CustomizeWindowHint|Qt::WindowTitleHint)) {
HMENU systemMenu = GetSystemMenu(hwnd, FALSE);
@@ -571,9 +588,10 @@ void WindowCreationData::initialize(HWND hwnd, bool frameChange, qreal opacityLe
#define QWINDOWSIZE_MAX ((1<<24)-1)
-QWindowsGeometryHint::QWindowsGeometryHint(const QWindow *w) :
+QWindowsGeometryHint::QWindowsGeometryHint(const QWindow *w, const QMargins &cm) :
minimumSize(w->minimumSize()),
- maximumSize(w->maximumSize())
+ maximumSize(w->maximumSize()),
+ customMargins(cm)
{
}
@@ -603,6 +621,33 @@ QMargins QWindowsGeometryHint::frame(DWORD style, DWORD exStyle)
return result;
}
+bool QWindowsGeometryHint::handleCalculateSize(const QMargins &customMargins, const MSG &msg, LRESULT *result)
+{
+#ifndef Q_OS_WINCE
+ // NCCALCSIZE_PARAMS structure if wParam==TRUE
+ if (!msg.wParam || customMargins.isNull())
+ return false;
+ *result = DefWindowProc(msg.hwnd, msg.message, msg.wParam, msg.lParam);
+ NCCALCSIZE_PARAMS *ncp = reinterpret_cast<NCCALCSIZE_PARAMS *>(msg.lParam);
+ const RECT oldClientArea = ncp->rgrc[0];
+ ncp->rgrc[0].left += customMargins.left();
+ ncp->rgrc[0].top += customMargins.top();
+ ncp->rgrc[0].right -= customMargins.right();
+ ncp->rgrc[0].bottom -= customMargins.bottom();
+ result = 0;
+ if (QWindowsContext::verboseWindows)
+ qDebug() << __FUNCTION__ << oldClientArea << '+' << customMargins << "-->"
+ << ncp->rgrc[0] << ' ' << ncp->rgrc[1] << ' ' << ncp->rgrc[2]
+ << ' ' << ncp->lppos->cx << ',' << ncp->lppos->cy;
+ return true;
+#else
+ Q_UNUSED(customMargins)
+ Q_UNUSED(msg)
+ Q_UNUSED(result)
+ return false;
+#endif
+}
+
#ifndef Q_OS_WINCE
void QWindowsGeometryHint::applyToMinMaxInfo(HWND hwnd, MINMAXINFO *mmi) const
{
@@ -619,8 +664,8 @@ void QWindowsGeometryHint::applyToMinMaxInfo(DWORD style, DWORD exStyle, MINMAXI
<< " in " << *mmi;
const QMargins margins = QWindowsGeometryHint::frame(style, exStyle);
- const int frameWidth = margins.left() + margins.right();
- const int frameHeight = margins.top() + margins.bottom();
+ const int frameWidth = margins.left() + margins.right() + customMargins.left() + customMargins.right();
+ const int frameHeight = margins.top() + margins.bottom() + customMargins.top() + customMargins.bottom();
if (minimumSize.width() > 0)
mmi->ptMinTrackSize.x = minimumSize.width() + frameWidth;
if (minimumSize.height() > 0)
@@ -669,10 +714,11 @@ bool QWindowsGeometryHint::positionIncludesFrame(const QWindow *w)
QWindowCreationContext::QWindowCreationContext(const QWindow *w,
const QRect &geometry,
+ const QMargins &cm,
DWORD style_, DWORD exStyle_) :
- geometryHint(w), style(style_), exStyle(exStyle_),
+ geometryHint(w, cm), style(style_), exStyle(exStyle_),
requestedGeometry(geometry), obtainedGeometry(geometry),
- margins(QWindowsGeometryHint::frame(style, exStyle)),
+ margins(QWindowsGeometryHint::frame(style, exStyle)), customMargins(cm),
frameX(CW_USEDEFAULT), frameY(CW_USEDEFAULT),
frameWidth(CW_USEDEFAULT), frameHeight(CW_USEDEFAULT)
{
@@ -683,14 +729,16 @@ QWindowCreationContext::QWindowCreationContext(const QWindow *w,
if (geometry.isValid()) {
frameX = geometry.x();
frameY = geometry.y();
- frameWidth = margins.left() + geometry.width() + margins.right();
- frameHeight = margins.top() + geometry.height() + margins.bottom();
+ const QMargins effectiveMargins = margins + customMargins;
+ frameWidth = effectiveMargins.left() + geometry.width() + effectiveMargins.right();
+ frameHeight = effectiveMargins.top() + geometry.height() + effectiveMargins.bottom();
const bool isDefaultPosition = !frameX && !frameY && w->isTopLevel();
if (!QWindowsGeometryHint::positionIncludesFrame(w) && !isDefaultPosition) {
- frameX -= margins.left();
- frameY -= margins.top();
+ frameX -= effectiveMargins.left();
+ frameY -= effectiveMargins.top();
}
}
+
if (QWindowsContext::verboseWindows)
qDebug().nospace()
<< __FUNCTION__ << ' ' << w << geometry
@@ -698,7 +746,8 @@ QWindowCreationContext::QWindowCreationContext(const QWindow *w,
<< " frame: " << frameWidth << 'x' << frameHeight << '+'
<< frameX << '+' << frameY
<< " min" << geometryHint.minimumSize
- << " max" << geometryHint.maximumSize;
+ << " max" << geometryHint.maximumSize
+ << " custom margins " << customMargins;
}
/*!
@@ -730,9 +779,6 @@ QWindowsWindow::QWindowsWindow(QWindow *aWindow, const WindowData &data) :
m_hdc(0),
m_windowState(Qt::WindowNoState),
m_opacity(1.0),
-#ifndef QT_NO_CURSOR
- m_cursor(QWindowsScreen::screenOf(aWindow)->windowsCursor()->standardWindowCursor()),
-#endif
m_dropTarget(0),
m_savedStyle(0),
m_format(aWindow->format()),
@@ -745,11 +791,16 @@ QWindowsWindow::QWindowsWindow(QWindow *aWindow, const WindowData &data) :
m_iconSmall(0),
m_iconBig(0)
{
+ // Clear the creation context as the window can be found in QWindowsContext's map.
+ QWindowsContext::instance()->setWindowCreationContext(QSharedPointer<QWindowCreationContext>());
+ QWindowsContext::instance()->addWindow(m_data.hwnd, this);
+ const Qt::WindowType type = aWindow->type();
+ if (type == Qt::Desktop)
+ return; // No further handling for Qt::Desktop
if (aWindow->surfaceType() == QWindow::OpenGLSurface)
setFlag(OpenGLSurface);
- QWindowsContext::instance()->addWindow(m_data.hwnd, this);
if (aWindow->isTopLevel()) {
- switch (aWindow->type()) {
+ switch (type) {
case Qt::Window:
case Qt::Dialog:
case Qt::Sheet:
@@ -763,8 +814,13 @@ QWindowsWindow::QWindowsWindow(QWindow *aWindow, const WindowData &data) :
}
}
#ifndef Q_OS_WINCE
- if (QWindowsContext::instance()->systemInfo() & QWindowsContext::SI_SupportsTouch)
- QWindowsContext::user32dll.registerTouchWindow(m_data.hwnd, 0);
+ if (QWindowsContext::instance()->systemInfo() & QWindowsContext::SI_SupportsTouch) {
+ if (QWindowsContext::user32dll.registerTouchWindow(m_data.hwnd, 0)) {
+ setFlag(TouchRegistered);
+ } else {
+ qErrnoWarning("RegisterTouchWindow() failed for window '%s'.", qPrintable(aWindow->objectName()));
+ }
+ }
#endif // !Q_OS_WINCE
setWindowState(aWindow->windowState());
const qreal opacity = qt_window_private(aWindow)->opacity;
@@ -775,7 +831,8 @@ QWindowsWindow::QWindowsWindow(QWindow *aWindow, const WindowData &data) :
QWindowsWindow::~QWindowsWindow()
{
#ifndef Q_OS_WINCE
- if (QWindowsContext::instance()->systemInfo() & QWindowsContext::SI_SupportsTouch)
+ QWindowSystemInterface::flushWindowSystemEvents();
+ if (testFlag(TouchRegistered))
QWindowsContext::user32dll.unregisterTouchWindow(m_data.hwnd);
#endif // !Q_OS_WINCE
destroyWindow();
@@ -872,8 +929,9 @@ QWindowsWindow::WindowData
{
WindowCreationData creationData;
creationData.fromWindow(w, parameters.flags);
- WindowData result = creationData.create(w, parameters.geometry, title);
- creationData.initialize(result.hwnd, false, 1);
+ WindowData result = creationData.create(w, parameters, title);
+ // Force WM_NCCALCSIZE (with wParam=1) via SWP_FRAMECHANGED for custom margin.
+ creationData.initialize(result.hwnd, !parameters.customMargins.isNull(), 1);
return result;
}
@@ -1060,7 +1118,7 @@ void QWindowsWindow::setGeometry(const QRect &rectIn)
const QSize newSize = rect.size();
// Check on hint.
if (newSize != oldSize) {
- const QWindowsGeometryHint hint(window());
+ const QWindowsGeometryHint hint(window(), m_data.customMargins);
if (!hint.validSize(newSize)) {
qWarning("%s: Attempt to set a size (%dx%d) violating the constraints"
"(%dx%d - %dx%d) on window '%s'.", __FUNCTION__,
@@ -1078,14 +1136,19 @@ void QWindowsWindow::setGeometry(const QRect &rectIn)
if (m_data.geometry != rect) {
qWarning("%s: Unable to set geometry %dx%d+%d+%d on '%s'."
" Resulting geometry: %dx%d+%d+%d "
- "(frame: %d, %d, %d, %d).",
+ "(frame: %d, %d, %d, %d, custom margin: %d, %d, %d, %d"
+ ", minimum size: %dx%d, maximum size: %dx%d).",
__FUNCTION__,
rect.width(), rect.height(), rect.x(), rect.y(),
qPrintable(window()->objectName()),
m_data.geometry.width(), m_data.geometry.height(),
m_data.geometry.x(), m_data.geometry.y(),
m_data.frame.left(), m_data.frame.top(),
- m_data.frame.right(), m_data.frame.bottom());
+ m_data.frame.right(), m_data.frame.bottom(),
+ m_data.customMargins.left(), m_data.customMargins.top(),
+ m_data.customMargins.right(), m_data.customMargins.bottom(),
+ window()->minimumWidth(), window()->minimumHeight(),
+ window()->maximumWidth(), window()->maximumHeight());
}
} else {
QPlatformWindow::setGeometry(rect);
@@ -1163,7 +1226,7 @@ QRect QWindowsWindow::frameGeometry_sys() const
QRect QWindowsWindow::geometry_sys() const
{
- return frameGeometry_sys() - frameMargins();
+ return frameGeometry_sys().marginsRemoved(frameMargins());
}
/*!
@@ -1490,7 +1553,7 @@ QMargins QWindowsWindow::frameMargins() const
m_data.frame = QWindowsGeometryHint::frame(style(), exStyle());
clearFlag(FrameDirty);
}
- return m_data.frame;
+ return m_data.frame + m_data.customMargins;
}
void QWindowsWindow::setOpacity(qreal level)
@@ -1648,13 +1711,23 @@ void QWindowsWindow::setFrameStrutEventsEnabled(bool enabled)
#ifndef Q_OS_WINCE // maybe available on some SDKs revisit WM_GETMINMAXINFO
void QWindowsWindow::getSizeHints(MINMAXINFO *mmi) const
{
- const QWindowsGeometryHint hint(window());
+ const QWindowsGeometryHint hint(window(), m_data.customMargins);
hint.applyToMinMaxInfo(m_data.hwnd, mmi);
if (QWindowsContext::verboseWindows)
qDebug() << __FUNCTION__ << window() << *mmi;
}
#endif // !Q_OS_WINCE
+// Return the default cursor (Arrow) from QWindowsCursor's cache.
+static inline QWindowsWindowCursor defaultCursor(const QWindow *w)
+{
+ if (QScreen *screen = w->screen())
+ if (const QPlatformScreen *platformScreen = screen->handle())
+ if (QPlatformCursor *cursor = platformScreen->cursor())
+ return static_cast<QWindowsCursor *>(cursor)->standardWindowCursor(Qt::ArrowCursor);
+ return QWindowsWindowCursor(Qt::ArrowCursor);
+}
+
/*!
\brief Applies to cursor property set on the window to the global cursor.
@@ -1664,20 +1737,45 @@ void QWindowsWindow::getSizeHints(MINMAXINFO *mmi) const
void QWindowsWindow::applyCursor()
{
#ifndef QT_NO_CURSOR
- SetCursor(m_cursor.handle());
+ if (m_cursor.isNull()) { // Recurse up to parent with non-null cursor. Set default for toplevel.
+ if (const QWindow *p = window()->parent()) {
+ QWindowsWindow::baseWindowOf(p)->applyCursor();
+ } else {
+ SetCursor(defaultCursor(window()).handle());
+ }
+ } else {
+ SetCursor(m_cursor.handle());
+ }
#endif
}
+// Check whether to apply a new cursor. Either the window in question is
+// currently under mouse, or it is the parent of the window under mouse and
+// there is no other window with an explicitly set cursor in-between.
+static inline bool applyNewCursor(const QWindow *w)
+{
+ const QWindow *underMouse = QWindowsContext::instance()->windowUnderMouse();
+ if (underMouse == w)
+ return true;
+ for (const QWindow *p = underMouse; p ; p = p->parent()) {
+ if (p == w)
+ return true;
+ if (!QWindowsWindow::baseWindowOf(p)->cursor().isNull())
+ return false;
+ }
+ return false;
+}
+
void QWindowsWindow::setCursor(const QWindowsWindowCursor &c)
{
#ifndef QT_NO_CURSOR
if (c.handle() != m_cursor.handle()) {
- const bool underMouse = QWindowsContext::instance()->windowUnderMouse() == window();
+ const bool apply = applyNewCursor(window());
if (QWindowsContext::verboseWindows)
qDebug() << window() << __FUNCTION__ << "Shape=" << c.cursor().shape()
- << " isWUM=" << underMouse;
+ << " doApply=" << apply;
m_cursor = c;
- if (underMouse)
+ if (apply)
applyCursor();
}
#endif
@@ -1850,4 +1948,32 @@ void QWindowsWindow::setWindowIcon(const QIcon &icon)
}
}
+/*!
+ \brief Sets custom margins to be added to the default margins determined by
+ the windows style in the handling of the WM_NCCALCSIZE message.
+
+ This is currently used to give the Aero-style QWizard a smaller top margin.
+ The property can be set using QPlatformNativeInterface::setWindowProperty() or,
+ before platform window creation, by setting a dynamic property
+ on the QWindow (see QWindowsIntegration::createPlatformWindow()).
+*/
+
+void QWindowsWindow::setCustomMargins(const QMargins &newCustomMargins)
+{
+ if (newCustomMargins != m_data.customMargins) {
+ const QMargins oldCustomMargins = m_data.customMargins;
+ m_data.customMargins = newCustomMargins;
+ // Re-trigger WM_NCALCSIZE with wParam=1 by passing SWP_FRAMECHANGED
+ const QRect currentFrameGeometry = frameGeometry_sys();
+ const QPoint topLeft = currentFrameGeometry.topLeft();
+ QRect newFrame = currentFrameGeometry.marginsRemoved(oldCustomMargins) + m_data.customMargins;
+ newFrame.moveTo(topLeft);
+ setFlag(FrameDirty);
+ if (QWindowsContext::verboseWindows)
+ qDebug() << __FUNCTION__ << oldCustomMargins << "->" << newCustomMargins
+ << currentFrameGeometry << "->" << newFrame;
+ SetWindowPos(m_data.hwnd, 0, newFrame.x(), newFrame.y(), newFrame.width(), newFrame.height(), SWP_NOZORDER | SWP_FRAMECHANGED);
+ }
+}
+
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/windows/qwindowswindow.h b/src/plugins/platforms/windows/qwindowswindow.h
index f3b480b0af..1148440f05 100644
--- a/src/plugins/platforms/windows/qwindowswindow.h
+++ b/src/plugins/platforms/windows/qwindowswindow.h
@@ -67,8 +67,9 @@ class QWindowsEGLStaticContext;
struct QWindowsGeometryHint
{
QWindowsGeometryHint() {}
- explicit QWindowsGeometryHint(const QWindow *w);
+ explicit QWindowsGeometryHint(const QWindow *w, const QMargins &customMargins);
static QMargins frame(DWORD style, DWORD exStyle);
+ static bool handleCalculateSize(const QMargins &customMargins, const MSG &msg, LRESULT *result);
#ifndef Q_OS_WINCE //MinMax maybe define struct if not available
void applyToMinMaxInfo(DWORD style, DWORD exStyle, MINMAXINFO *mmi) const;
void applyToMinMaxInfo(HWND hwnd, MINMAXINFO *mmi) const;
@@ -84,11 +85,13 @@ struct QWindowsGeometryHint
QSize minimumSize;
QSize maximumSize;
+ QMargins customMargins;
};
struct QWindowCreationContext
{
QWindowCreationContext(const QWindow *w, const QRect &r,
+ const QMargins &customMargins,
DWORD style, DWORD exStyle);
#ifndef Q_OS_WINCE //MinMax maybe define struct if not available
void applyToMinMaxInfo(MINMAXINFO *mmi) const
@@ -101,6 +104,7 @@ struct QWindowCreationContext
QRect requestedGeometry;
QRect obtainedGeometry;
QMargins margins;
+ QMargins customMargins; // User-defined, additional frame for WM_NCCALCSIZE
int frameX; // Passed on to CreateWindowEx(), including frame.
int frameY;
int frameWidth;
@@ -127,7 +131,8 @@ public:
FrameStrutEventsEnabled = 0x200,
SynchronousGeometryChangeEvent = 0x400,
WithinSetStyle = 0x800,
- WithinDestroy = 0x1000
+ WithinDestroy = 0x1000,
+ TouchRegistered = 0x2000
};
struct WindowData
@@ -137,6 +142,7 @@ public:
Qt::WindowFlags flags;
QRect geometry;
QMargins frame; // Do not use directly for windows, see FrameDirty.
+ QMargins customMargins; // User-defined, additional frame for NCCALCSIZE
HWND hwnd;
bool embedded;
@@ -191,6 +197,9 @@ public:
void setFrameStrutEventsEnabled(bool enabled);
bool frameStrutEventsEnabled() const { return testFlag(FrameStrutEventsEnabled); }
+ QMargins customMargins() const { return m_data.customMargins; }
+ void setCustomMargins(const QMargins &m);
+
#ifdef QT_OPENGL_ES_2
EGLSurface eglSurfaceHandle() const { return m_eglSurface;}
EGLSurface ensureEglSurfaceHandle(const QWindowsEGLStaticContextPtr &staticContext, EGLConfig config);
@@ -290,17 +299,6 @@ private:
HICON m_iconBig;
};
-// Conveniences for window frames.
-inline QRect operator+(const QRect &r, const QMargins &m)
-{
- return r.adjusted(-m.left(), -m.top(), m.right(), m.bottom());
-}
-
-inline QRect operator-(const QRect &r, const QMargins &m)
-{
- return r.adjusted(m.left(), m.top(), -m.right(), -m.bottom());
-}
-
// Debug
QDebug operator<<(QDebug d, const RECT &r);
#ifndef Q_OS_WINCE // maybe available on some SDKs revisit WM_GETMINMAXINFO/WM_NCCALCSIZE
@@ -371,4 +369,6 @@ inline void QWindowsWindow::destroyIcon()
QT_END_NAMESPACE
+Q_DECLARE_METATYPE(QMargins)
+
#endif // QWINDOWSWINDOW_H
diff --git a/src/plugins/platforms/windows/windows.pro b/src/plugins/platforms/windows/windows.pro
index ff162e2d41..3aa9caaa0f 100644
--- a/src/plugins/platforms/windows/windows.pro
+++ b/src/plugins/platforms/windows/windows.pro
@@ -102,12 +102,8 @@ contains(QT_CONFIG, opengles2) {
}
}
-# Enable access to HB_Face in harfbuzz includes included by qfontengine_p.h.
-DEFINES *= QT_COMPILES_IN_HARFBUZZ
-
contains(QT_CONFIG, freetype) {
DEFINES *= QT_NO_FONTCONFIG
- DEFINES *= QT_COMPILES_IN_HARFBUZZ
QT_FREETYPE_DIR = $$QT_SOURCE_TREE/src/3rdparty/freetype
HEADERS += \
diff --git a/src/plugins/platforms/xcb/qglxintegration.cpp b/src/plugins/platforms/xcb/qglxintegration.cpp
index 11c74edc45..516b35dac8 100644
--- a/src/plugins/platforms/xcb/qglxintegration.cpp
+++ b/src/plugins/platforms/xcb/qglxintegration.cpp
@@ -50,6 +50,7 @@
#include <GL/glx.h>
#include <QtGui/QOpenGLContext>
+#include <QtGui/QOffscreenSurface>
#include "qglxintegration.h"
#include <QtPlatformSupport/private/qglxconvenience_p.h>
@@ -70,6 +71,10 @@ typedef GLXContext (*glXCreateContextAttribsARBProc)(Display*, GLXFBConfig, GLXC
#define GLX_CONTEXT_COMPATIBILITY_PROFILE_BIT_ARB 0x00000002
#endif
+#ifndef GLX_CONTEXT_ES2_PROFILE_BIT_EXT
+#define GLX_CONTEXT_ES2_PROFILE_BIT_EXT 0x00000004
+#endif
+
#ifndef GLX_CONTEXT_PROFILE_MASK_ARB
#define GLX_CONTEXT_PROFILE_MASK_ARB 0x9126
#endif
@@ -104,57 +109,6 @@ static Window createDummyWindow(QXcbScreen *screen, GLXFBConfig config)
return window;
}
-// Per-window data for active OpenGL contexts.
-struct QOpenGLContextData
-{
- QOpenGLContextData(Display *display, Window window, GLXContext context)
- : m_display(display),
- m_window(window),
- m_context(context)
- {}
-
- QOpenGLContextData()
- : m_display(0),
- m_window(0),
- m_context(0)
- {}
-
- Display *m_display;
- Window m_window;
- GLXContext m_context;
-};
-
-static inline QOpenGLContextData currentOpenGLContextData()
-{
- QOpenGLContextData result;
- result.m_display = glXGetCurrentDisplay();
- result.m_window = glXGetCurrentDrawable();
- result.m_context = glXGetCurrentContext();
- return result;
-}
-
-static inline QOpenGLContextData createDummyWindowOpenGLContextData(QXcbScreen *screen)
-{
- QOpenGLContextData result;
- result.m_display = DISPLAY_FROM_XCB(screen);
-
- QSurfaceFormat format;
- GLXFBConfig config = qglx_findConfig(DISPLAY_FROM_XCB(screen), screen->screenNumber(), format);
- if (config) {
- result.m_context = glXCreateNewContext(DISPLAY_FROM_XCB(screen), config, GLX_RGBA_TYPE, 0, true);
- result.m_window = createDummyWindow(screen, config);
- } else {
- XVisualInfo *visualInfo = qglx_findVisualInfo(DISPLAY_FROM_XCB(screen), screen->screenNumber(), &format);
- if (!visualInfo)
- qFatal("Could not initialize GLX");
- result.m_context = glXCreateContext(DISPLAY_FROM_XCB(screen), visualInfo, 0, true);
- result.m_window = createDummyWindow(screen, visualInfo);
- XFree(visualInfo);
- }
-
- return result;
-}
-
static inline QByteArray getGlString(GLenum param)
{
if (const GLubyte *s = glGetString(param))
@@ -173,109 +127,53 @@ static void updateFormatFromContext(QSurfaceFormat &format)
}
format.setProfile(QSurfaceFormat::NoProfile);
+ format.setOption(QSurfaceFormat::FormatOptions());
- const int version = (major << 8) + minor;
- if (version < 0x0300) {
- format.setProfile(QSurfaceFormat::NoProfile);
- format.setOption(QSurfaceFormat::DeprecatedFunctions);
- return;
- }
-
- // Version 3.0 onwards - check if it includes deprecated functionality or is
- // a debug context
- GLint value = 0;
- glGetIntegerv(GL_CONTEXT_FLAGS, &value);
- if (!(value & GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT))
- format.setOption(QSurfaceFormat::DeprecatedFunctions);
- if (value & GL_CONTEXT_FLAG_DEBUG_BIT)
- format.setOption(QSurfaceFormat::DebugContext);
- if (version < 0x0302)
- return;
-
- // Version 3.2 and newer have a profile
- value = 0;
- glGetIntegerv(GL_CONTEXT_PROFILE_MASK, &value);
-
- if (value & GL_CONTEXT_CORE_PROFILE_BIT)
- format.setProfile(QSurfaceFormat::CoreProfile);
- else if (value & GL_CONTEXT_COMPATIBILITY_PROFILE_BIT)
- format.setProfile(QSurfaceFormat::CompatibilityProfile);
-}
-
-/*!
- \class QOpenGLTemporaryContext
- \brief A temporary context that can be instantiated on the stack.
-
- Functions like glGetString() only work if there is a current GL context.
-
- \internal
- \ingroup qt-lighthouse-xcb
-*/
-class QOpenGLTemporaryContext
-{
- Q_DISABLE_COPY(QOpenGLTemporaryContext)
-public:
- QOpenGLTemporaryContext(QXcbScreen *screen);
- ~QOpenGLTemporaryContext();
-
-private:
- const QOpenGLContextData m_previous;
- const QOpenGLContextData m_current;
-};
-
-QOpenGLTemporaryContext::QOpenGLTemporaryContext(QXcbScreen *screen)
- : m_previous(currentOpenGLContextData()),
- m_current(createDummyWindowOpenGLContextData(screen))
-{
- // Make our temporary context current on our temporary window
- glXMakeCurrent(m_current.m_display, m_current.m_window, m_current.m_context);
-}
-
-QOpenGLTemporaryContext::~QOpenGLTemporaryContext()
-{
- // Restore the previous context if possible, otherwise just release our temporary context
- if (m_previous.m_display)
- glXMakeCurrent(m_previous.m_display, m_previous.m_window, m_previous.m_context);
- else
- glXMakeCurrent(m_current.m_display, 0, 0);
-
- // Destroy our temporary window
- XDestroyWindow(m_current.m_display, m_current.m_window);
-
- // Finally destroy our temporary context itself
- glXDestroyContext(m_current.m_display, m_current.m_context);
-}
-
-QOpenGLDefaultContextInfo::QOpenGLDefaultContextInfo()
- : vendor(getGlString(GL_VENDOR)),
- renderer(getGlString(GL_RENDERER))
-{
- updateFormatFromContext(format);
-}
+ if (format.renderableType() == QSurfaceFormat::OpenGL) {
+ if (format.version() < qMakePair(3, 0)) {
+ format.setOption(QSurfaceFormat::DeprecatedFunctions);
+ return;
+ }
-QOpenGLDefaultContextInfo *QOpenGLDefaultContextInfo::create(QXcbScreen *screen)
-{
- // We need a current context for getGLString() to work. To have
- // the QOpenGLDefaultContextInfo contain the latest supported
- // context version, we rely upon the QOpenGLTemporaryContext to
- // correctly obtain a context with the latest version
- QScopedPointer<QOpenGLTemporaryContext> temporaryContext(new QOpenGLTemporaryContext(screen));
- QOpenGLDefaultContextInfo *result = new QOpenGLDefaultContextInfo;
- return result;
+ // Version 3.0 onwards - check if it includes deprecated functionality or is
+ // a debug context
+ GLint value = 0;
+ glGetIntegerv(GL_CONTEXT_FLAGS, &value);
+ if (!(value & GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT))
+ format.setOption(QSurfaceFormat::DeprecatedFunctions);
+ if (value & GL_CONTEXT_FLAG_DEBUG_BIT)
+ format.setOption(QSurfaceFormat::DebugContext);
+ if (format.version() < qMakePair(3, 2))
+ return;
+
+ // Version 3.2 and newer have a profile
+ value = 0;
+ glGetIntegerv(GL_CONTEXT_PROFILE_MASK, &value);
+
+ if (value & GL_CONTEXT_CORE_PROFILE_BIT)
+ format.setProfile(QSurfaceFormat::CoreProfile);
+ else if (value & GL_CONTEXT_COMPATIBILITY_PROFILE_BIT)
+ format.setProfile(QSurfaceFormat::CompatibilityProfile);
+ }
}
-
-QGLXContext::QGLXContext(QXcbScreen *screen, const QSurfaceFormat &format, QPlatformOpenGLContext *share, QOpenGLDefaultContextInfo *defaultContextInfo)
+QGLXContext::QGLXContext(QXcbScreen *screen, const QSurfaceFormat &format, QPlatformOpenGLContext *share)
: QPlatformOpenGLContext()
, m_screen(screen)
, m_context(0)
+ , m_shareContext(0)
, m_format(format)
+ , m_isPBufferCurrent(false)
{
- m_shareContext = 0;
+ if (m_format.renderableType() == QSurfaceFormat::DefaultRenderableType)
+ m_format.setRenderableType(QSurfaceFormat::OpenGL);
+ if (m_format.renderableType() != QSurfaceFormat::OpenGL && m_format.renderableType() != QSurfaceFormat::OpenGLES)
+ return;
+
if (share)
m_shareContext = static_cast<const QGLXContext*>(share)->glxContext();
- GLXFBConfig config = qglx_findConfig(DISPLAY_FROM_XCB(screen),screen->screenNumber(),format);
+ GLXFBConfig config = qglx_findConfig(DISPLAY_FROM_XCB(screen),screen->screenNumber(),m_format);
XVisualInfo *visualInfo = 0;
Window window = 0; // Temporary window used to query OpenGL context
@@ -287,56 +185,88 @@ QGLXContext::QGLXContext(QXcbScreen *screen, const QSurfaceFormat &format, QPlat
QList<QByteArray> glxExt = QByteArray(glXQueryExtensionsString(DISPLAY_FROM_XCB(m_screen), m_screen->screenNumber())).split(' ');
bool supportsProfiles = glxExt.contains("GLX_ARB_create_context_profile");
- // Use glXCreateContextAttribsARB if is available
- if (glxExt.contains("GLX_ARB_create_context") && glXCreateContextAttribsARB != 0) {
- // We limit the requested version by the version of the static context as
- // glXCreateContextAttribsARB fails and returns NULL if the requested context
- // version is not supported. This means that we will get the closest supported
- // context format that that which was requested and is supported by the driver
- const int maxSupportedVersion = (defaultContextInfo->format.majorVersion() << 8)
- + defaultContextInfo->format.minorVersion();
- const int requestedVersion = qMin((format.majorVersion() << 8) + format.minorVersion(),
- maxSupportedVersion);
- const int majorVersion = requestedVersion >> 8;
- const int minorVersion = requestedVersion & 0xFF;
-
- QVector<int> contextAttributes;
- contextAttributes << GLX_CONTEXT_MAJOR_VERSION_ARB << majorVersion
- << GLX_CONTEXT_MINOR_VERSION_ARB << minorVersion;
-
- // If asking for OpenGL 3.2 or newer we should also specify a profile
- if (supportsProfiles && (m_format.majorVersion() > 3 || (m_format.majorVersion() == 3 && m_format.minorVersion() > 1))) {
- if (m_format.profile() == QSurfaceFormat::CoreProfile)
- contextAttributes << GLX_CONTEXT_PROFILE_MASK_ARB << GLX_CONTEXT_CORE_PROFILE_BIT_ARB;
- else
- contextAttributes << GLX_CONTEXT_PROFILE_MASK_ARB << GLX_CONTEXT_COMPATIBILITY_PROFILE_BIT_ARB;
+ // Use glXCreateContextAttribsARB if available
+ // Also, GL ES context creation requires GLX_EXT_create_context_es2_profile
+ if (glxExt.contains("GLX_ARB_create_context") && glXCreateContextAttribsARB != 0
+ && (m_format.renderableType() != QSurfaceFormat::OpenGLES || (supportsProfiles && glxExt.contains("GLX_EXT_create_context_es2_profile")))) {
+ // Try to create an OpenGL context for each known OpenGL version in descending
+ // order from the requested version.
+ const int requestedVersion = format.majorVersion() * 10 + qMin(format.minorVersion(), 9);
+
+ QVector<int> glVersions;
+ if (m_format.renderableType() == QSurfaceFormat::OpenGL) {
+ if (requestedVersion > 43)
+ glVersions << requestedVersion;
+
+ // Don't bother with versions below 2.0
+ glVersions << 43 << 42 << 41 << 40 << 33 << 32 << 31 << 30 << 21 << 20;
+ } else if (m_format.renderableType() == QSurfaceFormat::OpenGLES) {
+ if (requestedVersion > 30)
+ glVersions << requestedVersion;
+
+ // Don't bother with versions below ES 2.0
+ glVersions << 30 << 20;
+ // ES does not support any format option
+ m_format.setOption(QSurfaceFormat::FormatOptions());
}
- int flags = 0;
+ Q_ASSERT(glVersions.count() > 0);
- if (m_format.testOption(QSurfaceFormat::DebugContext))
- flags |= GLX_CONTEXT_DEBUG_BIT_ARB;
+ for (int i = 0; !m_context && i < glVersions.count(); i++) {
+ const int version = glVersions[i];
+ if (version > requestedVersion)
+ continue;
- // A forward-compatible context may be requested for 3.0 and later
- if (m_format.majorVersion() >= 3 && !m_format.testOption(QSurfaceFormat::DeprecatedFunctions))
- flags |= GLX_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB;
+ const int majorVersion = version / 10;
+ const int minorVersion = version % 10;
- if (flags != 0)
- contextAttributes << GLX_CONTEXT_FLAGS_ARB << flags;
+ QVector<int> contextAttributes;
+ contextAttributes << GLX_CONTEXT_MAJOR_VERSION_ARB << majorVersion
+ << GLX_CONTEXT_MINOR_VERSION_ARB << minorVersion;
- contextAttributes << None;
- m_context = glXCreateContextAttribsARB(DISPLAY_FROM_XCB(screen), config, m_shareContext, true, contextAttributes.data());
- if (!m_context && m_shareContext) {
- // re-try without a shared glx context
- m_context = glXCreateContextAttribsARB(DISPLAY_FROM_XCB(screen), config, 0, true, contextAttributes.data());
- if (m_context)
- m_shareContext = 0;
+ if (m_format.renderableType() == QSurfaceFormat::OpenGL) {
+ // If asking for OpenGL 3.2 or newer we should also specify a profile
+ if (version >= 32 && supportsProfiles) {
+ if (m_format.profile() == QSurfaceFormat::CoreProfile)
+ contextAttributes << GLX_CONTEXT_PROFILE_MASK_ARB << GLX_CONTEXT_CORE_PROFILE_BIT_ARB;
+ else
+ contextAttributes << GLX_CONTEXT_PROFILE_MASK_ARB << GLX_CONTEXT_COMPATIBILITY_PROFILE_BIT_ARB;
+ }
+
+ int flags = 0;
+
+ if (m_format.testOption(QSurfaceFormat::DebugContext))
+ flags |= GLX_CONTEXT_DEBUG_BIT_ARB;
+
+ // A forward-compatible context may be requested for 3.0 and later
+ if (version >= 30 && !m_format.testOption(QSurfaceFormat::DeprecatedFunctions))
+ flags |= GLX_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB;
+
+ if (flags != 0)
+ contextAttributes << GLX_CONTEXT_FLAGS_ARB << flags;
+ } else if (m_format.renderableType() == QSurfaceFormat::OpenGLES) {
+ contextAttributes << GLX_CONTEXT_PROFILE_MASK_ARB << GLX_CONTEXT_ES2_PROFILE_BIT_EXT;
+ }
+
+ contextAttributes << None;
+
+ m_context = glXCreateContextAttribsARB(DISPLAY_FROM_XCB(screen), config, m_shareContext, true, contextAttributes.data());
+ if (!m_context && m_shareContext) {
+ // re-try without a shared glx context
+ m_context = glXCreateContextAttribsARB(DISPLAY_FROM_XCB(screen), config, 0, true, contextAttributes.data());
+ if (m_context)
+ m_shareContext = 0;
+ }
}
}
// Could not create a context using glXCreateContextAttribsARB, falling back to glXCreateNewContext.
if (!m_context) {
+ // requesting an OpenGL ES context requires glXCreateContextAttribsARB, so bail out
+ if (m_format.renderableType() == QSurfaceFormat::OpenGLES)
+ return;
+
m_context = glXCreateNewContext(DISPLAY_FROM_XCB(screen), config, GLX_RGBA_TYPE, m_shareContext, true);
if (!m_context && m_shareContext) {
// re-try without a shared glx context
@@ -348,11 +278,15 @@ QGLXContext::QGLXContext(QXcbScreen *screen, const QSurfaceFormat &format, QPlat
// Get the basic surface format details
if (m_context)
- m_format = qglx_surfaceFormatFromGLXFBConfig(DISPLAY_FROM_XCB(screen), config, m_context);
+ qglx_surfaceFormatFromGLXFBConfig(&m_format, DISPLAY_FROM_XCB(screen), config, m_context);
// Create a temporary window so that we can make the new context current
window = createDummyWindow(screen, config);
} else {
+ // requesting an OpenGL ES context requires glXCreateContextAttribsARB, so bail out
+ if (m_format.renderableType() == QSurfaceFormat::OpenGLES)
+ return;
+
// Note that m_format gets updated with the used surface format
visualInfo = qglx_findVisualInfo(DISPLAY_FROM_XCB(screen), screen->screenNumber(), &m_format);
if (!visualInfo)
@@ -391,19 +325,35 @@ bool QGLXContext::makeCurrent(QPlatformSurface *surface)
{
Q_ASSERT(surface->surface()->surfaceType() == QSurface::OpenGLSurface);
- GLXDrawable glxDrawable = static_cast<QXcbWindow *>(surface)->xcb_window();
-
- return glXMakeCurrent(DISPLAY_FROM_XCB(m_screen), glxDrawable, m_context);
+ QSurface::SurfaceClass surfaceClass = surface->surface()->surfaceClass();
+ if (surfaceClass == QSurface::Window) {
+ m_isPBufferCurrent = false;
+ QXcbWindow *window = static_cast<QXcbWindow *>(surface);
+ return glXMakeCurrent(DISPLAY_FROM_XCB(m_screen), window->xcb_window(), m_context);
+ } else if (surfaceClass == QSurface::Offscreen) {
+ m_isPBufferCurrent = true;
+ QGLXPbuffer *pbuffer = static_cast<QGLXPbuffer *>(surface);
+ return glXMakeContextCurrent(DISPLAY_FROM_XCB(m_screen), pbuffer->pbuffer(), pbuffer->pbuffer(), m_context);
+ }
+ return false;
}
void QGLXContext::doneCurrent()
{
- glXMakeCurrent(DISPLAY_FROM_XCB(m_screen), 0, 0);
+ if (m_isPBufferCurrent)
+ glXMakeContextCurrent(DISPLAY_FROM_XCB(m_screen), 0, 0, 0);
+ else
+ glXMakeCurrent(DISPLAY_FROM_XCB(m_screen), 0, 0);
+ m_isPBufferCurrent = false;
}
void QGLXContext::swapBuffers(QPlatformSurface *surface)
{
- GLXDrawable glxDrawable = static_cast<QXcbWindow *>(surface)->xcb_window();
+ GLXDrawable glxDrawable = 0;
+ if (surface->surface()->surfaceClass() == QSurface::Offscreen)
+ glxDrawable = static_cast<QGLXPbuffer *>(surface)->pbuffer();
+ else
+ glxDrawable = static_cast<QXcbWindow *>(surface)->xcb_window();
glXSwapBuffers(DISPLAY_FROM_XCB(m_screen), glxDrawable);
}
@@ -455,4 +405,36 @@ bool QGLXContext::isValid() const
return m_context != 0;
}
+
+QGLXPbuffer::QGLXPbuffer(QOffscreenSurface *offscreenSurface)
+ : QPlatformOffscreenSurface(offscreenSurface)
+ , m_format(offscreenSurface->requestedFormat())
+ , m_screen(static_cast<QXcbScreen *>(offscreenSurface->screen()->handle()))
+ , m_pbuffer(0)
+{
+ GLXFBConfig config = qglx_findConfig(DISPLAY_FROM_XCB(m_screen), m_screen->screenNumber(), m_format);
+
+ if (config) {
+ const int attributes[] = {
+ GLX_PBUFFER_WIDTH, offscreenSurface->size().width(),
+ GLX_PBUFFER_HEIGHT, offscreenSurface->size().height(),
+ GLX_LARGEST_PBUFFER, False,
+ GLX_PRESERVED_CONTENTS, False,
+ GLX_NONE
+ };
+
+ m_pbuffer = glXCreatePbuffer(DISPLAY_FROM_XCB(m_screen), config, attributes);
+
+ if (m_pbuffer)
+ qglx_surfaceFormatFromGLXFBConfig(&m_format, DISPLAY_FROM_XCB(m_screen), config);
+ }
+}
+
+QGLXPbuffer::~QGLXPbuffer()
+{
+ if (m_pbuffer)
+ glXDestroyPbuffer(DISPLAY_FROM_XCB(m_screen), m_pbuffer);
+}
+
+
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/xcb/qglxintegration.h b/src/plugins/platforms/xcb/qglxintegration.h
index 78e9985334..7116b2389d 100644
--- a/src/plugins/platforms/xcb/qglxintegration.h
+++ b/src/plugins/platforms/xcb/qglxintegration.h
@@ -46,6 +46,7 @@
#include "qxcbscreen.h"
#include <qpa/qplatformopenglcontext.h>
+#include <qpa/qplatformoffscreensurface.h>
#include <QtGui/QSurfaceFormat>
#include <QtCore/QMutex>
@@ -54,23 +55,10 @@
QT_BEGIN_NAMESPACE
-class QOpenGLDefaultContextInfo
-{
- Q_DISABLE_COPY(QOpenGLDefaultContextInfo)
- QOpenGLDefaultContextInfo();
-public:
- static QOpenGLDefaultContextInfo *create(QXcbScreen *screen);
-
- const QByteArray vendor;
- const QByteArray renderer;
- QSurfaceFormat format;
-};
-
-
class QGLXContext : public QPlatformOpenGLContext
{
public:
- QGLXContext(QXcbScreen *xd, const QSurfaceFormat &format, QPlatformOpenGLContext *share, QOpenGLDefaultContextInfo *defaultContextInfo);
+ QGLXContext(QXcbScreen *xd, const QSurfaceFormat &format, QPlatformOpenGLContext *share);
~QGLXContext();
bool makeCurrent(QPlatformSurface *surface);
@@ -89,6 +77,25 @@ private:
GLXContext m_context;
GLXContext m_shareContext;
QSurfaceFormat m_format;
+ bool m_isPBufferCurrent;
+};
+
+
+class QGLXPbuffer : public QPlatformOffscreenSurface
+{
+public:
+ explicit QGLXPbuffer(QOffscreenSurface *offscreenSurface);
+ ~QGLXPbuffer();
+
+ QSurfaceFormat format() const { return m_format; }
+ bool isValid() const { return m_pbuffer != 0; }
+
+ GLXPbuffer pbuffer() const { return m_pbuffer; }
+
+private:
+ QSurfaceFormat m_format;
+ QXcbScreen *m_screen;
+ GLXPbuffer m_pbuffer;
};
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/xcb/qxcbconnection.cpp b/src/plugins/platforms/xcb/qxcbconnection.cpp
index 32de54562a..1504bd99d2 100644
--- a/src/plugins/platforms/xcb/qxcbconnection.cpp
+++ b/src/plugins/platforms/xcb/qxcbconnection.cpp
@@ -184,7 +184,7 @@ void QXcbConnection::updateScreens()
activeScreens << screen;
++screenNumber;
if (!primaryScreen && primary) {
- if (primary->output == XCB_NONE || outputs[i] == primary->output) {
+ if (m_primaryScreen == xcbScreenNumber && (primary->output == XCB_NONE || outputs[i] == primary->output)) {
primaryScreen = screen;
siblings.prepend(siblings.takeLast());
#ifdef Q_XCB_DEBUG
@@ -222,7 +222,6 @@ void QXcbConnection::updateScreens()
// Delete any existing screens which are not in activeScreens
for (int i = m_screens.count() - 1; i >= 0; --i) {
if (!activeScreens.contains(m_screens[i])) {
- ((QXcbIntegration*)QGuiApplicationPrivate::platformIntegration())->removeDefaultOpenGLContextInfo(m_screens[i]);
delete m_screens[i];
m_screens.removeAt(i);
}
@@ -1067,7 +1066,7 @@ void QXcbConnection::processXcbEvents()
while (it != m_peekFuncs.end()) {
// These callbacks return true if the event is what they were
// waiting for, remove them from the list in that case.
- if ((*it)(event))
+ if ((*it)(this, event))
it = m_peekFuncs.erase(it);
else
++it;
@@ -1087,7 +1086,7 @@ void QXcbConnection::processXcbEvents()
// Indicate with a null event that the event the callbacks are waiting for
// is not in the queue currently.
Q_FOREACH (PeekFunc f, m_peekFuncs)
- f(0);
+ f(this, 0);
m_peekFuncs.clear();
xcb_flush(xcb_connection());
diff --git a/src/plugins/platforms/xcb/qxcbconnection.h b/src/plugins/platforms/xcb/qxcbconnection.h
index b499f75b78..f69a8a9f35 100644
--- a/src/plugins/platforms/xcb/qxcbconnection.h
+++ b/src/plugins/platforms/xcb/qxcbconnection.h
@@ -364,7 +364,7 @@ public:
template<typename T>
inline xcb_generic_event_t *checkEvent(T &checker);
- typedef bool (*PeekFunc)(xcb_generic_event_t *);
+ typedef bool (*PeekFunc)(QXcbConnection *, xcb_generic_event_t *);
void addPeekFunc(PeekFunc f);
inline xcb_timestamp_t time() const { return m_time; }
diff --git a/src/plugins/platforms/xcb/qxcbcursor.cpp b/src/plugins/platforms/xcb/qxcbcursor.cpp
index b40fdb0e92..3fd2ca70e3 100644
--- a/src/plugins/platforms/xcb/qxcbcursor.cpp
+++ b/src/plugins/platforms/xcb/qxcbcursor.cpp
@@ -287,8 +287,14 @@ QXcbCursor::QXcbCursor(QXcbConnection *conn, QXcbScreen *screen)
QXcbCursor::~QXcbCursor()
{
+ xcb_connection_t *conn = xcb_connection();
if (!--cursorCount)
- xcb_close_font(xcb_connection(), cursorFont);
+ xcb_close_font(conn, cursorFont);
+
+ foreach (xcb_cursor_t cursor, m_bitmapCursorMap)
+ xcb_free_cursor(conn, cursor);
+ foreach (xcb_cursor_t cursor, m_shapeCursorMap)
+ xcb_free_cursor(conn, cursor);
}
#ifndef QT_NO_CURSOR
@@ -300,18 +306,20 @@ void QXcbCursor::changeCursor(QCursor *cursor, QWindow *widget)
else
// No X11 cursor control when there is no widget under the cursor
return;
-
- xcb_cursor_t c;
- if (cursor->shape() == Qt::BitmapCursor) {
- qint64 id = cursor->pixmap().cacheKey();
- if (!m_bitmapCursorMap.contains(id))
- m_bitmapCursorMap.insert(id, createBitmapCursor(cursor));
- c = m_bitmapCursorMap.value(id);
- } else {
- int id = cursor->shape();
- if (!m_shapeCursorMap.contains(id))
- m_shapeCursorMap.insert(id, createFontCursor(cursor->shape()));
- c = m_shapeCursorMap.value(id);
+
+ xcb_cursor_t c = XCB_CURSOR_NONE;
+ if (cursor) {
+ if (cursor->shape() == Qt::BitmapCursor) {
+ qint64 id = cursor->pixmap().cacheKey();
+ if (!m_bitmapCursorMap.contains(id))
+ m_bitmapCursorMap.insert(id, createBitmapCursor(cursor));
+ c = m_bitmapCursorMap.value(id);
+ } else {
+ int id = cursor->shape();
+ if (!m_shapeCursorMap.contains(id))
+ m_shapeCursorMap.insert(id, createFontCursor(cursor->shape()));
+ c = m_shapeCursorMap.value(id);
+ }
}
w->setCursor(c);
diff --git a/src/plugins/platforms/xcb/qxcbintegration.cpp b/src/plugins/platforms/xcb/qxcbintegration.cpp
index 1840dd1ce5..f0cabea43d 100644
--- a/src/plugins/platforms/xcb/qxcbintegration.cpp
+++ b/src/plugins/platforms/xcb/qxcbintegration.cpp
@@ -78,10 +78,12 @@
#elif defined(XCB_USE_EGL)
#include "qxcbeglsurface.h"
#include <QtPlatformSupport/private/qeglplatformcontext_p.h>
+#include <QtPlatformSupport/private/qeglpbuffer_p.h>
#endif
#include <QtGui/QOpenGLContext>
#include <QtGui/QScreen>
+#include <QtGui/QOffscreenSurface>
#ifndef QT_NO_ACCESSIBILITY
#include <qpa/qplatformaccessibility.h>
#ifndef QT_NO_ACCESSIBILITY_ATSPI_BRIDGE
@@ -121,9 +123,6 @@ QXcbIntegration::QXcbIntegration(const QStringList &parameters)
QXcbIntegration::~QXcbIntegration()
{
-#if !defined(QT_NO_OPENGL) && defined(XCB_USE_GLX)
- qDeleteAll(m_defaultContextInfos);
-#endif
qDeleteAll(m_connections);
}
@@ -168,7 +167,10 @@ public:
EGLSurface eglSurfaceForPlatformSurface(QPlatformSurface *surface)
{
- return static_cast<QXcbWindow *>(surface)->eglSurface()->surface();
+ if (surface->surface()->surfaceClass() == QSurface::Window)
+ return static_cast<QXcbWindow *>(surface)->eglSurface()->surface();
+ else
+ return static_cast<QEGLPbuffer *>(surface)->pbuffer();
}
private:
@@ -181,14 +183,7 @@ QPlatformOpenGLContext *QXcbIntegration::createPlatformOpenGLContext(QOpenGLCont
{
QXcbScreen *screen = static_cast<QXcbScreen *>(context->screen()->handle());
#if defined(XCB_USE_GLX)
- QOpenGLDefaultContextInfo *defaultContextInfo;
- if (m_defaultContextInfos.contains(screen)) {
- defaultContextInfo = m_defaultContextInfos.value(screen);
- } else {
- defaultContextInfo = QOpenGLDefaultContextInfo::create(screen);
- m_defaultContextInfos.insert(screen, defaultContextInfo);
- }
- return new QGLXContext(screen, context->format(), context->shareHandle(), defaultContextInfo);
+ return new QGLXContext(screen, context->format(), context->shareHandle());
#elif defined(XCB_USE_EGL)
return new QEGLXcbPlatformContext(context->format(), context->shareHandle(),
screen->connection()->egl_display(), screen->connection());
@@ -205,6 +200,20 @@ QPlatformBackingStore *QXcbIntegration::createPlatformBackingStore(QWindow *wind
return new QXcbBackingStore(window);
}
+QPlatformOffscreenSurface *QXcbIntegration::createPlatformOffscreenSurface(QOffscreenSurface *surface) const
+{
+#if defined(XCB_USE_GLX)
+ return new QGLXPbuffer(surface);
+#elif defined(XCB_USE_EGL)
+ QXcbScreen *screen = static_cast<QXcbScreen *>(surface->screen()->handle());
+ return new QEGLPbuffer(screen->connection()->egl_display(), surface->requestedFormat(), surface);
+#else
+ Q_UNUSED(surface);
+ qWarning("QXcbIntegration: Cannot create platform offscreen surface, neither GLX nor EGL are enabled");
+ return 0;
+#endif
+}
+
bool QXcbIntegration::hasCapability(QPlatformIntegration::Capability cap) const
{
switch (cap) {
@@ -219,6 +228,7 @@ bool QXcbIntegration::hasCapability(QPlatformIntegration::Capability cap) const
case ThreadedOpenGL: return m_connections.at(0)->supportsThreadedRendering();
case WindowMasks: return true;
case MultipleWindows: return true;
+ case ForeignWindows: return true;
default: return QPlatformIntegration::hasCapability(cap);
}
}
@@ -293,21 +303,4 @@ QPlatformTheme *QXcbIntegration::createPlatformTheme(const QString &name) const
return QGenericUnixTheme::createUnixTheme(name);
}
-/*!
- Called by QXcbConnection prior to a QQnxScreen being deleted.
-
- Destroys and cleans up any default OpenGL context info for this screen.
-*/
-void QXcbIntegration::removeDefaultOpenGLContextInfo(QXcbScreen *screen)
-{
-#if !defined(QT_NO_OPENGL) && defined(XCB_USE_GLX)
- if (!m_defaultContextInfos.contains(screen))
- return;
- QOpenGLDefaultContextInfo* info = m_defaultContextInfos.take(screen);
- delete info;
-#else
- Q_UNUSED(screen);
-#endif
-}
-
QT_END_NAMESPACE
diff --git a/src/plugins/platforms/xcb/qxcbintegration.h b/src/plugins/platforms/xcb/qxcbintegration.h
index cd6c2fd73c..6db9d82cca 100644
--- a/src/plugins/platforms/xcb/qxcbintegration.h
+++ b/src/plugins/platforms/xcb/qxcbintegration.h
@@ -52,10 +52,6 @@ class QAbstractEventDispatcher;
class QXcbNativeInterface;
class QXcbScreen;
-#if !defined(QT_NO_OPENGL) && defined(XCB_USE_GLX)
-class QOpenGLDefaultContextInfo;
-#endif
-
class QXcbIntegration : public QPlatformIntegration
{
public:
@@ -68,6 +64,8 @@ public:
#endif
QPlatformBackingStore *createPlatformBackingStore(QWindow *window) const;
+ QPlatformOffscreenSurface *createPlatformOffscreenSurface(QOffscreenSurface *surface) const;
+
bool hasCapability(Capability cap) const;
QAbstractEventDispatcher *guiThreadEventDispatcher() const;
@@ -97,8 +95,6 @@ public:
QStringList themeNames() const;
QPlatformTheme *createPlatformTheme(const QString &name) const;
- void removeDefaultOpenGLContextInfo(QXcbScreen *screen);
-
private:
QList<QXcbConnection *> m_connections;
@@ -108,10 +104,6 @@ private:
QScopedPointer<QPlatformInputContext> m_inputContext;
QAbstractEventDispatcher *m_eventDispatcher;
-#if !defined(QT_NO_OPENGL) && defined(XCB_USE_GLX)
- mutable QHash<QXcbScreen *, QOpenGLDefaultContextInfo *> m_defaultContextInfos;
-#endif
-
#ifndef QT_NO_ACCESSIBILITY
QScopedPointer<QPlatformAccessibility> m_accessibility;
#endif
diff --git a/src/plugins/platforms/xcb/qxcbkeyboard.cpp b/src/plugins/platforms/xcb/qxcbkeyboard.cpp
index bda54b4682..4ac60f6077 100644
--- a/src/plugins/platforms/xcb/qxcbkeyboard.cpp
+++ b/src/plugins/platforms/xcb/qxcbkeyboard.cpp
@@ -1081,6 +1081,7 @@ void QXcbKeyboard::handleKeyEvent(QWindow *window, QEvent::Type type, xcb_keycod
int qtcode = 0;
int count = chars.count();
QString string = translateKeySym(sym, state, qtcode, modifiers, chars, count);
+ string.truncate(count);
bool isAutoRepeat = false;
@@ -1102,7 +1103,7 @@ void QXcbKeyboard::handleKeyEvent(QWindow *window, QEvent::Type type, xcb_keycod
bool filtered = false;
if (inputContext) {
- QKeyEvent event(type, qtcode, modifiers, code, sym, state, string.left(count), isAutoRepeat, count);
+ QKeyEvent event(type, qtcode, modifiers, code, sym, state, string, isAutoRepeat, count);
event.setTimestamp(time);
filtered = inputContext->filterEvent(&event);
}
@@ -1114,7 +1115,7 @@ void QXcbKeyboard::handleKeyEvent(QWindow *window, QEvent::Type type, xcb_keycod
QWindowSystemInterface::handleContextMenuEvent(window, false, pos, globalPos, modifiers);
}
QWindowSystemInterface::handleExtendedKeyEvent(window, time, type, qtcode, modifiers,
- code, sym, state, string.left(count), isAutoRepeat);
+ code, sym, state, string, isAutoRepeat);
}
if (isAutoRepeat && type == QEvent::KeyRelease) {
@@ -1130,13 +1131,13 @@ void QXcbKeyboard::handleKeyEvent(QWindow *window, QEvent::Type type, xcb_keycod
}
if (!filtered && inputContext) {
- QKeyEvent event(QEvent::KeyPress, qtcode, modifiers, code, sym, state, string.left(count), isAutoRepeat, count);
+ QKeyEvent event(QEvent::KeyPress, qtcode, modifiers, code, sym, state, string, isAutoRepeat, count);
event.setTimestamp(time);
filtered = inputContext->filterEvent(&event);
}
if (!filtered)
QWindowSystemInterface::handleExtendedKeyEvent(window, time, QEvent::KeyPress, qtcode, modifiers,
- code, sym, state, string.left(count), isAutoRepeat);
+ code, sym, state, string, isAutoRepeat);
}
}
diff --git a/src/plugins/platforms/xcb/qxcbwindow.cpp b/src/plugins/platforms/xcb/qxcbwindow.cpp
index c0ddf5c0ae..5af6a9ec9d 100644
--- a/src/plugins/platforms/xcb/qxcbwindow.cpp
+++ b/src/plugins/platforms/xcb/qxcbwindow.cpp
@@ -113,11 +113,45 @@
#endif
#define XCOORD_MAX 16383
+enum {
+ defaultWindowWidth = 160,
+ defaultWindowHeight = 160
+};
//#ifdef NET_WM_STATE_DEBUG
QT_BEGIN_NAMESPACE
+#undef FocusIn
+
+enum QX11EmbedFocusInDetail {
+ XEMBED_FOCUS_CURRENT = 0,
+ XEMBED_FOCUS_FIRST = 1,
+ XEMBED_FOCUS_LAST = 2
+};
+
+enum QX11EmbedInfoFlags {
+ XEMBED_MAPPED = (1 << 0),
+};
+
+enum QX11EmbedMessageType {
+ XEMBED_EMBEDDED_NOTIFY = 0,
+ XEMBED_WINDOW_ACTIVATE = 1,
+ XEMBED_WINDOW_DEACTIVATE = 2,
+ XEMBED_REQUEST_FOCUS = 3,
+ XEMBED_FOCUS_IN = 4,
+ XEMBED_FOCUS_OUT = 5,
+ XEMBED_FOCUS_NEXT = 6,
+ XEMBED_FOCUS_PREV = 7,
+ XEMBED_MODALITY_ON = 10,
+ XEMBED_MODALITY_OFF = 11,
+ XEMBED_REGISTER_ACCELERATOR = 12,
+ XEMBED_UNREGISTER_ACCELERATOR = 13,
+ XEMBED_ACTIVATE_ACCELERATOR = 14
+};
+
+static unsigned int XEMBED_VERSION = 0;
+
// Returns true if we should set WM_TRANSIENT_FOR on \a w
static inline bool isTransient(const QWindow *w)
{
@@ -152,7 +186,9 @@ QXcbWindow::QXcbWindow(QWindow *window)
, m_gravity(XCB_GRAVITY_STATIC)
, m_mapped(false)
, m_transparent(false)
+ , m_usingSyncProtocol(false)
, m_deferredActivation(false)
+ , m_embedded(false)
, m_netWmUserTimeWindow(XCB_NONE)
, m_dirtyFrameMargins(false)
#if defined(XCB_USE_EGL)
@@ -164,7 +200,10 @@ QXcbWindow::QXcbWindow(QWindow *window)
setConnection(m_screen->connection());
- create();
+ if (window->type() != Qt::ForeignWindow)
+ create();
+ else
+ m_window = window->winId();
}
void QXcbWindow::create()
@@ -219,12 +258,22 @@ void QXcbWindow::create()
QRect rect = window()->geometry();
QPlatformWindow::setGeometry(rect);
- rect.setWidth(qBound(1, rect.width(), XCOORD_MAX));
- rect.setHeight(qBound(1, rect.height(), XCOORD_MAX));
+ QSize minimumSize = window()->minimumSize();
+ if (rect.width() > 0 || rect.height() > 0) {
+ rect.setWidth(qBound(1, rect.width(), XCOORD_MAX));
+ rect.setHeight(qBound(1, rect.height(), XCOORD_MAX));
+ } else if (minimumSize.width() > 0 || minimumSize.height() > 0) {
+ rect.setSize(minimumSize);
+ } else {
+ rect.setWidth(defaultWindowWidth);
+ rect.setHeight(defaultWindowHeight);
+ }
xcb_window_t xcb_parent_id = m_screen->root();
- if (parent())
+ if (parent()) {
xcb_parent_id = static_cast<QXcbWindow *>(parent())->xcb_window();
+ m_embedded = parent()->window()->type() == Qt::ForeignWindow;
+ }
m_format = window()->requestedFormat();
@@ -306,7 +355,9 @@ void QXcbWindow::create()
properties[propertyCount++] = atom(QXcbAtom::WM_TAKE_FOCUS);
properties[propertyCount++] = atom(QXcbAtom::_NET_WM_PING);
- if (m_screen->syncRequestSupported())
+ m_usingSyncProtocol = m_screen->syncRequestSupported() && window()->surfaceType() != QSurface::OpenGLSurface;
+
+ if (m_usingSyncProtocol)
properties[propertyCount++] = atom(QXcbAtom::_NET_WM_SYNC_REQUEST);
if (window()->flags() & Qt::WindowContextHelpButtonHint)
@@ -323,7 +374,7 @@ void QXcbWindow::create()
m_syncValue.hi = 0;
m_syncValue.lo = 0;
- if (m_screen->syncRequestSupported()) {
+ if (m_usingSyncProtocol) {
m_syncCounter = xcb_generate_id(xcb_connection());
Q_XCB_CALL(xcb_sync_create_counter(xcb_connection(), m_syncCounter, m_syncValue));
@@ -356,6 +407,14 @@ void QXcbWindow::create()
atom(QXcbAtom::WM_CLIENT_LEADER), XCB_ATOM_WINDOW, 32,
1, &leader));
+ /* Add XEMBED info; this operation doesn't initiate the embedding. */
+ long data[] = { XEMBED_VERSION, XEMBED_MAPPED };
+ Q_XCB_CALL(xcb_change_property(xcb_connection(), XCB_PROP_MODE_REPLACE, m_window,
+ atom(QXcbAtom::_XEMBED_INFO),
+ atom(QXcbAtom::_XEMBED_INFO),
+ 32, 2, (void *)data));
+
+
#ifdef XCB_USE_XINPUT2_MAEMO
if (connection()->isUsingXInput2Maemo()) {
XIEventMask xieventmask;
@@ -398,7 +457,8 @@ void QXcbWindow::create()
QXcbWindow::~QXcbWindow()
{
- destroy();
+ if (window()->type() != Qt::ForeignWindow)
+ destroy();
}
void QXcbWindow::destroy()
@@ -406,7 +466,7 @@ void QXcbWindow::destroy()
if (connection()->focusWindow() == this)
connection()->setFocusWindow(0);
- if (m_syncCounter && m_screen->syncRequestSupported())
+ if (m_syncCounter && m_usingSyncProtocol)
Q_XCB_CALL(xcb_sync_destroy_counter(xcb_connection(), m_syncCounter));
if (m_window) {
if (m_netWmUserTimeWindow) {
@@ -436,15 +496,23 @@ void QXcbWindow::setGeometry(const QRect &rect)
propagateSizeHints();
const QRect wmGeometry = windowToWmGeometry(rect);
- const quint32 mask = XCB_CONFIG_WINDOW_X | XCB_CONFIG_WINDOW_Y | XCB_CONFIG_WINDOW_WIDTH | XCB_CONFIG_WINDOW_HEIGHT;
- const qint32 values[] = {
- qBound<qint32>(-XCOORD_MAX, wmGeometry.x(), XCOORD_MAX),
- qBound<qint32>(-XCOORD_MAX, wmGeometry.y(), XCOORD_MAX),
- qBound<qint32>(1, wmGeometry.width(), XCOORD_MAX),
- qBound<qint32>(1, wmGeometry.height(), XCOORD_MAX),
- };
-
- Q_XCB_CALL(xcb_configure_window(xcb_connection(), m_window, mask, reinterpret_cast<const quint32*>(values)));
+ if (qt_window_private(window())->positionAutomatic) {
+ const quint32 mask = XCB_CONFIG_WINDOW_WIDTH | XCB_CONFIG_WINDOW_HEIGHT;
+ const qint32 values[] = {
+ qBound<qint32>(1, wmGeometry.width(), XCOORD_MAX),
+ qBound<qint32>(1, wmGeometry.height(), XCOORD_MAX),
+ };
+ Q_XCB_CALL(xcb_configure_window(xcb_connection(), m_window, mask, reinterpret_cast<const quint32*>(values)));
+ } else {
+ const quint32 mask = XCB_CONFIG_WINDOW_X | XCB_CONFIG_WINDOW_Y | XCB_CONFIG_WINDOW_WIDTH | XCB_CONFIG_WINDOW_HEIGHT;
+ const qint32 values[] = {
+ qBound<qint32>(-XCOORD_MAX, wmGeometry.x(), XCOORD_MAX),
+ qBound<qint32>(-XCOORD_MAX, wmGeometry.y(), XCOORD_MAX),
+ qBound<qint32>(1, wmGeometry.width(), XCOORD_MAX),
+ qBound<qint32>(1, wmGeometry.height(), XCOORD_MAX),
+ };
+ Q_XCB_CALL(xcb_configure_window(xcb_connection(), m_window, mask, reinterpret_cast<const quint32*>(values)));
+ }
xcb_flush(xcb_connection());
}
@@ -554,15 +622,17 @@ void QXcbWindow::show()
propagateSizeHints();
// update WM_TRANSIENT_FOR
- if (isTransient(window())) {
+ const QWindow *tp = window()->transientParent();
+ if (isTransient(window()) || tp != 0) {
xcb_window_t transientXcbParent = 0;
- if (const QWindow *tp = window()->transientParent())
+ if (tp)
transientXcbParent = static_cast<const QXcbWindow *>(tp->handle())->winId();
// Default to client leader if there is no transient parent, else modal dialogs can
// be hidden by their parents.
if (!transientXcbParent)
transientXcbParent = static_cast<QXcbScreen *>(screen())->clientLeader();
if (transientXcbParent) { // ICCCM 4.1.2.6
+ m_gravity = XCB_GRAVITY_CENTER;
Q_XCB_CALL(xcb_change_property(xcb_connection(), XCB_PROP_MODE_REPLACE, m_window,
XCB_ATOM_WM_TRANSIENT_FOR, XCB_ATOM_WINDOW, 32,
1, &transientXcbParent));
@@ -1119,7 +1189,15 @@ void QXcbWindow::setParent(const QPlatformWindow *parent)
{
QPoint topLeft = geometry().topLeft();
- xcb_window_t xcb_parent_id = parent ? static_cast<const QXcbWindow *>(parent)->xcb_window() : m_screen->root();
+ xcb_window_t xcb_parent_id;
+ if (parent) {
+ const QXcbWindow *qXcbParent = static_cast<const QXcbWindow *>(parent);
+ xcb_parent_id = qXcbParent->xcb_window();
+ m_embedded = qXcbParent->window()->type() == Qt::ForeignWindow;
+ } else {
+ xcb_parent_id = m_screen->root();
+ m_embedded = false;
+ }
Q_XCB_CALL(xcb_reparent_window(xcb_connection(), xcb_window(), xcb_parent_id, topLeft.x(), topLeft.y()));
}
@@ -1221,8 +1299,10 @@ void QXcbWindow::propagateSizeHints()
QWindow *win = window();
- xcb_size_hints_set_position(&hints, true, rect.x(), rect.y());
- xcb_size_hints_set_size(&hints, true, rect.width(), rect.height());
+ if (!qt_window_private(win)->positionAutomatic)
+ xcb_size_hints_set_position(&hints, true, rect.x(), rect.y());
+ if (rect.width() < QWINDOWSIZE_MAX || rect.height() < QWINDOWSIZE_MAX)
+ xcb_size_hints_set_size(&hints, true, rect.width(), rect.height());
xcb_size_hints_set_win_gravity(&hints, m_gravity);
QSize minimumSize = win->minimumSize();
@@ -1248,6 +1328,13 @@ void QXcbWindow::propagateSizeHints()
void QXcbWindow::requestActivateWindow()
{
+ /* Never activate embedded windows; doing that would prevent the container
+ * to re-gain the keyboard focus later. */
+ if (m_embedded) {
+ QPlatformWindow::requestActivateWindow();
+ return;
+ }
+
if (!m_mapped) {
m_deferredActivation = true;
return;
@@ -1411,7 +1498,8 @@ void QXcbWindow::handleClientMessageEvent(const xcb_client_message_event_t *even
} else if (event->type == atom(QXcbAtom::XdndDrop)) {
connection()->drag()->handleDrop(window(), event);
#endif
- } else if (event->type == atom(QXcbAtom::_XEMBED)) { // QSystemTrayIcon
+ } else if (event->type == atom(QXcbAtom::_XEMBED)) {
+ handleXEmbedMessage(event);
} else {
qWarning() << "QXcbWindow: Unhandled client message:" << connection()->atomName(event->type);
}
@@ -1453,6 +1541,53 @@ bool QXcbWindow::isExposed() const
return m_mapped;
}
+bool QXcbWindow::isEmbedded(const QPlatformWindow *parentWindow) const
+{
+ if (!m_embedded)
+ return false;
+
+ return parentWindow ? (parentWindow == parent()) : true;
+}
+
+QPoint QXcbWindow::mapToGlobal(const QPoint &pos) const
+{
+ if (!m_embedded)
+ return pos;
+
+ QPoint ret;
+ xcb_translate_coordinates_cookie_t cookie =
+ xcb_translate_coordinates(xcb_connection(), xcb_window(), m_screen->root(),
+ pos.x(), pos.y());
+ xcb_translate_coordinates_reply_t *reply =
+ xcb_translate_coordinates_reply(xcb_connection(), cookie, NULL);
+ if (reply) {
+ ret.setX(reply->dst_x);
+ ret.setY(reply->dst_y);
+ free(reply);
+ }
+
+ return ret;
+}
+
+QPoint QXcbWindow::mapFromGlobal(const QPoint &pos) const
+{
+ if (!m_embedded)
+ return pos;
+ QPoint ret;
+ xcb_translate_coordinates_cookie_t cookie =
+ xcb_translate_coordinates(xcb_connection(), m_screen->root(), xcb_window(),
+ pos.x(), pos.y());
+ xcb_translate_coordinates_reply_t *reply =
+ xcb_translate_coordinates_reply(xcb_connection(), cookie, NULL);
+ if (reply) {
+ ret.setX(reply->dst_x);
+ ret.setY(reply->dst_y);
+ free(reply);
+ }
+
+ return ret;
+}
+
void QXcbWindow::handleMapNotifyEvent(const xcb_map_notify_event_t *event)
{
if (event->window == m_window) {
@@ -1483,6 +1618,15 @@ void QXcbWindow::handleButtonPressEvent(const xcb_button_press_event_t *event)
updateNetWmUserTime(event->time);
+ if (m_embedded) {
+ if (window() != QGuiApplication::focusWindow()) {
+ const QXcbWindow *container = static_cast<const QXcbWindow *>(parent());
+ Q_ASSERT(container != 0);
+
+ sendXEmbedMessage(container->xcb_window(), XEMBED_REQUEST_FOCUS);
+ }
+ }
+
QPoint local(event->event_x, event->event_y);
QPoint global(event->root_x, event->root_y);
@@ -1638,6 +1782,7 @@ void QXcbWindow::handlePropertyNotifyEvent(const xcb_property_notify_event_t *ev
QWindowSystemInterface::handleWindowStateChanged(window(), newState);
m_lastWindowStateEvent = newState;
}
+ return;
}
}
@@ -1649,7 +1794,7 @@ void QXcbWindow::handleFocusInEvent(const xcb_focus_in_event_t *)
QWindowSystemInterface::handleWindowActivated(w);
}
-static bool focusInPeeker(xcb_generic_event_t *event)
+static bool focusInPeeker(QXcbConnection *connection, xcb_generic_event_t *event)
{
if (!event) {
// FocusIn event is not in the queue, proceed with FocusOut normally.
@@ -1657,7 +1802,18 @@ static bool focusInPeeker(xcb_generic_event_t *event)
return true;
}
uint response_type = event->response_type & ~0x80;
- return response_type == XCB_FOCUS_IN;
+ if (response_type == XCB_FOCUS_IN)
+ return true;
+
+ /* We are also interested in XEMBED_FOCUS_IN events */
+ if (response_type == XCB_CLIENT_MESSAGE) {
+ xcb_client_message_event_t *cme = (xcb_client_message_event_t *)event;
+ if (cme->type == connection->atom(QXcbAtom::_XEMBED)
+ && cme->data.data32[1] == XEMBED_FOCUS_IN)
+ return true;
+ }
+
+ return false;
}
void QXcbWindow::handleFocusOutEvent(const xcb_focus_out_event_t *)
@@ -1671,7 +1827,7 @@ void QXcbWindow::handleFocusOutEvent(const xcb_focus_out_event_t *)
void QXcbWindow::updateSyncRequestCounter()
{
- if (m_screen->syncRequestSupported() && (m_syncValue.lo != 0 || m_syncValue.hi != 0)) {
+ if (m_usingSyncProtocol && (m_syncValue.lo != 0 || m_syncValue.hi != 0)) {
Q_XCB_CALL(xcb_sync_set_counter(xcb_connection(), m_syncCounter, m_syncValue));
xcb_flush(xcb_connection());
connection()->sync();
@@ -1721,6 +1877,35 @@ void QXcbWindow::setCursor(xcb_cursor_t cursor)
xcb_flush(xcb_connection());
}
+void QXcbWindow::windowEvent(QEvent *event)
+{
+ switch (event->type()) {
+ case QEvent::FocusIn:
+ if (m_embedded && !event->spontaneous()) {
+ QFocusEvent *focusEvent = static_cast<QFocusEvent *>(event);
+ switch (focusEvent->reason()) {
+ case Qt::TabFocusReason:
+ case Qt::BacktabFocusReason:
+ {
+ const QXcbWindow *container =
+ static_cast<const QXcbWindow *>(parent());
+ sendXEmbedMessage(container->xcb_window(),
+ focusEvent->reason() == Qt::TabFocusReason ?
+ XEMBED_FOCUS_NEXT : XEMBED_FOCUS_PREV);
+ event->accept();
+ }
+ break;
+ default:
+ break;
+ }
+ }
+ break;
+ default:
+ break;
+ }
+ QPlatformWindow::windowEvent(event);
+}
+
bool QXcbWindow::startSystemResize(const QPoint &pos, Qt::Corner corner)
{
const xcb_atom_t moveResize = connection()->atom(QXcbAtom::_NET_WM_MOVERESIZE);
@@ -1749,6 +1934,71 @@ bool QXcbWindow::startSystemResize(const QPoint &pos, Qt::Corner corner)
return true;
}
+// Sends an XEmbed message.
+void QXcbWindow::sendXEmbedMessage(xcb_window_t window, long message,
+ long detail, long data1, long data2)
+{
+ xcb_client_message_event_t event;
+
+ event.response_type = XCB_CLIENT_MESSAGE;
+ event.format = 32;
+ event.window = window;
+ event.type = atom(QXcbAtom::_XEMBED);
+ event.data.data32[0] = connection()->time();
+ event.data.data32[1] = message;
+ event.data.data32[2] = detail;
+ event.data.data32[3] = data1;
+ event.data.data32[4] = data2;
+ Q_XCB_CALL(xcb_send_event(xcb_connection(), false, window,
+ XCB_EVENT_MASK_NO_EVENT, (const char *)&event));
+}
+
+static bool activeWindowChangeQueued(const QWindow *window)
+{
+ /* Check from window system event queue if the next queued activation
+ * targets a window other than @window.
+ */
+ QWindowSystemInterfacePrivate::ActivatedWindowEvent *systemEvent =
+ static_cast<QWindowSystemInterfacePrivate::ActivatedWindowEvent *>
+ (QWindowSystemInterfacePrivate::peekWindowSystemEvent(QWindowSystemInterfacePrivate::ActivatedWindow));
+ return systemEvent && systemEvent->activated != window;
+}
+
+void QXcbWindow::handleXEmbedMessage(const xcb_client_message_event_t *event)
+{
+ connection()->setTime(event->data.data32[0]);
+ switch (event->data.data32[1]) {
+ case XEMBED_WINDOW_ACTIVATE:
+ case XEMBED_WINDOW_DEACTIVATE:
+ case XEMBED_EMBEDDED_NOTIFY:
+ break;
+ case XEMBED_FOCUS_IN:
+ Qt::FocusReason reason;
+ switch (event->data.data32[2]) {
+ case XEMBED_FOCUS_FIRST:
+ reason = Qt::TabFocusReason;
+ break;
+ case XEMBED_FOCUS_LAST:
+ reason = Qt::BacktabFocusReason;
+ break;
+ case XEMBED_FOCUS_CURRENT:
+ default:
+ reason = Qt::OtherFocusReason;
+ break;
+ }
+ connection()->setFocusWindow(static_cast<QXcbWindow*>(window()->handle()));
+ QWindowSystemInterface::handleWindowActivated(window(), reason);
+ break;
+ case XEMBED_FOCUS_OUT:
+ if (window() == QGuiApplication::focusWindow()
+ && !activeWindowChangeQueued(window())) {
+ connection()->setFocusWindow(0);
+ QWindowSystemInterface::handleWindowActivated(0);
+ }
+ break;
+ }
+}
+
#if !defined(QT_NO_SHAPE)
static inline xcb_rectangle_t qRectToXCBRectangle(const QRect &r)
diff --git a/src/plugins/platforms/xcb/qxcbwindow.h b/src/plugins/platforms/xcb/qxcbwindow.h
index 3b5404684f..f4bd2d96ff 100644
--- a/src/plugins/platforms/xcb/qxcbwindow.h
+++ b/src/plugins/platforms/xcb/qxcbwindow.h
@@ -87,6 +87,9 @@ public:
void setParent(const QPlatformWindow *window);
bool isExposed() const;
+ bool isEmbedded(const QPlatformWindow *parentWindow) const;
+ QPoint mapToGlobal(const QPoint &pos) const;
+ QPoint mapFromGlobal(const QPoint &pos) const;
void setWindowTitle(const QString &title);
void setWindowIcon(const QIcon &icon);
@@ -107,6 +110,8 @@ public:
QSurfaceFormat format() const;
+ void windowEvent(QEvent *event);
+
bool startSystemResize(const QPoint &pos, Qt::Corner corner);
void setOpacity(qreal level);
@@ -158,6 +163,9 @@ private:
void updateDoesNotAcceptFocus(bool doesNotAcceptFocus);
QRect windowToWmGeometry(QRect r) const;
+ void sendXEmbedMessage(xcb_window_t window, long message,
+ long detail = 0, long data1 = 0, long data2 = 0);
+ void handleXEmbedMessage(const xcb_client_message_event_t *event);
void create();
void destroy();
@@ -181,9 +189,11 @@ private:
bool m_mapped;
bool m_transparent;
+ bool m_usingSyncProtocol;
bool m_deferredActivation;
bool m_deferredExpose;
bool m_configureNotifyPending;
+ bool m_embedded;
xcb_window_t m_netWmUserTimeWindow;
QSurfaceFormat m_format;
diff --git a/src/plugins/platformthemes/gtk2/gtk2.json b/src/plugins/platformthemes/gtk2/gtk2.json
new file mode 100644
index 0000000000..86dd8e58fa
--- /dev/null
+++ b/src/plugins/platformthemes/gtk2/gtk2.json
@@ -0,0 +1,3 @@
+{
+ "Keys": [ "gtk2" ]
+}
diff --git a/src/plugins/platformthemes/gtk2/gtk2.pro b/src/plugins/platformthemes/gtk2/gtk2.pro
new file mode 100644
index 0000000000..bb02192f91
--- /dev/null
+++ b/src/plugins/platformthemes/gtk2/gtk2.pro
@@ -0,0 +1,20 @@
+TARGET = qgtk2
+
+PLUGIN_TYPE = platformthemes
+PLUGIN_CLASS_NAME = QGtk2ThemePlugin
+load(qt_plugin)
+
+QT += core-private gui-private platformsupport-private
+
+CONFIG += X11
+QMAKE_CXXFLAGS += $$QT_CFLAGS_QGTK2
+LIBS += $$QT_LIBS_QGTK2
+
+HEADERS += \
+ qgtk2dialoghelpers.h \
+ qgtk2theme.h
+
+SOURCES += \
+ main.cpp \
+ qgtk2dialoghelpers.cpp \
+ qgtk2theme.cpp \
diff --git a/src/plugins/platformthemes/gtk2/main.cpp b/src/plugins/platformthemes/gtk2/main.cpp
new file mode 100644
index 0000000000..13e7d57b13
--- /dev/null
+++ b/src/plugins/platformthemes/gtk2/main.cpp
@@ -0,0 +1,67 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <qpa/qplatformthemeplugin.h>
+#include "qgtk2theme.h"
+
+QT_BEGIN_NAMESPACE
+
+class QGtk2ThemePlugin : public QPlatformThemePlugin
+{
+ Q_OBJECT
+ Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QPA.QPlatformThemeFactoryInterface.5.1" FILE "gtk2.json")
+
+public:
+ QPlatformTheme *create(const QString &key, const QStringList &params);
+};
+
+QPlatformTheme *QGtk2ThemePlugin::create(const QString &key, const QStringList &params)
+{
+ Q_UNUSED(params);
+ if (!key.compare(QLatin1String(QGtk2Theme::name), Qt::CaseInsensitive))
+ return new QGtk2Theme;
+
+ return 0;
+}
+
+QT_END_NAMESPACE
+
+#include "main.moc"
diff --git a/src/plugins/platformthemes/gtk2/qgtk2dialoghelpers.cpp b/src/plugins/platformthemes/gtk2/qgtk2dialoghelpers.cpp
new file mode 100644
index 0000000000..25d45eb81d
--- /dev/null
+++ b/src/plugins/platformthemes/gtk2/qgtk2dialoghelpers.cpp
@@ -0,0 +1,609 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qgtk2dialoghelpers.h"
+
+#include <qeventloop.h>
+#include <qwindow.h>
+#include <qcolor.h>
+#include <qdebug.h>
+#include <qfont.h>
+
+#include <private/qguiapplication_p.h>
+
+#undef signals
+#include <gtk/gtk.h>
+#include <gdk/gdk.h>
+#include <gdk/gdkx.h>
+#include <pango/pango.h>
+
+QT_BEGIN_NAMESPACE
+
+class QGtk2Dialog : public QWindow
+{
+ Q_OBJECT
+
+public:
+ QGtk2Dialog(GtkWidget *gtkWidget);
+ ~QGtk2Dialog();
+
+ GtkDialog *gtkDialog() const;
+
+ void exec();
+ bool show(Qt::WindowFlags flags, Qt::WindowModality modality, QWindow *parent);
+ void hide();
+
+Q_SIGNALS:
+ void accept();
+ void reject();
+
+protected:
+ static void onResponse(QGtk2Dialog *dialog, int response);
+
+private:
+ GtkWidget *gtkWidget;
+};
+
+QGtk2Dialog::QGtk2Dialog(GtkWidget *gtkWidget) : gtkWidget(gtkWidget)
+{
+ g_signal_connect_swapped(G_OBJECT(gtkWidget), "response", G_CALLBACK(onResponse), this);
+ g_signal_connect(G_OBJECT(gtkWidget), "delete-event", G_CALLBACK(gtk_widget_hide_on_delete), NULL);
+}
+
+QGtk2Dialog::~QGtk2Dialog()
+{
+ gtk_widget_destroy(gtkWidget);
+}
+
+GtkDialog *QGtk2Dialog::gtkDialog() const
+{
+ return GTK_DIALOG(gtkWidget);
+}
+
+void QGtk2Dialog::exec()
+{
+ if (modality() == Qt::ApplicationModal) {
+ // block input to the whole app, including other GTK dialogs
+ gtk_dialog_run(gtkDialog());
+ } else {
+ // block input to the window, allow input to other GTK dialogs
+ QEventLoop loop;
+ connect(this, SIGNAL(accept()), &loop, SLOT(quit()));
+ connect(this, SIGNAL(reject()), &loop, SLOT(quit()));
+ loop.exec();
+ }
+}
+
+bool QGtk2Dialog::show(Qt::WindowFlags flags, Qt::WindowModality modality, QWindow *parent)
+{
+ setParent(parent);
+ setFlags(flags);
+ setModality(modality);
+
+ gtk_widget_realize(gtkWidget); // creates X window
+
+ if (parent) {
+ XSetTransientForHint(gdk_x11_drawable_get_xdisplay(gtkWidget->window),
+ gdk_x11_drawable_get_xid(gtkWidget->window),
+ parent->winId());
+ }
+
+ if (modality != Qt::NonModal) {
+ gdk_window_set_modal_hint(gtkWidget->window, true);
+ QGuiApplicationPrivate::showModalWindow(this);
+ }
+
+ gtk_widget_show(gtkWidget);
+ return true;
+}
+
+void QGtk2Dialog::hide()
+{
+ QGuiApplicationPrivate::hideModalWindow(this);
+ gtk_widget_hide(gtkWidget);
+}
+
+void QGtk2Dialog::onResponse(QGtk2Dialog *dialog, int response)
+{
+ if (response == GTK_RESPONSE_OK)
+ emit dialog->accept();
+ else
+ emit dialog->reject();
+}
+
+QGtk2ColorDialogHelper::QGtk2ColorDialogHelper()
+{
+ d.reset(new QGtk2Dialog(gtk_color_selection_dialog_new("")));
+ connect(d.data(), SIGNAL(accept()), this, SLOT(onAccepted()));
+ connect(d.data(), SIGNAL(reject()), this, SIGNAL(reject()));
+
+ GtkWidget *gtkColorSelection = gtk_color_selection_dialog_get_color_selection(GTK_COLOR_SELECTION_DIALOG(d->gtkDialog()));
+ g_signal_connect_swapped(gtkColorSelection, "color-changed", G_CALLBACK(onColorChanged), this);
+}
+
+QGtk2ColorDialogHelper::~QGtk2ColorDialogHelper()
+{
+}
+
+bool QGtk2ColorDialogHelper::show(Qt::WindowFlags flags, Qt::WindowModality modality, QWindow *parent)
+{
+ applyOptions();
+ return d->show(flags, modality, parent);
+}
+
+void QGtk2ColorDialogHelper::exec()
+{
+ d->exec();
+}
+
+void QGtk2ColorDialogHelper::hide()
+{
+ d->hide();
+}
+
+void QGtk2ColorDialogHelper::setCurrentColor(const QColor &color)
+{
+ GtkDialog *gtkDialog = d->gtkDialog();
+ GtkWidget *gtkColorSelection = gtk_color_selection_dialog_get_color_selection(GTK_COLOR_SELECTION_DIALOG(gtkDialog));
+ GdkColor gdkColor;
+ gdkColor.red = color.red() << 8;
+ gdkColor.green = color.green() << 8;
+ gdkColor.blue = color.blue() << 8;
+ gtk_color_selection_set_current_color(GTK_COLOR_SELECTION(gtkColorSelection), &gdkColor);
+ if (color.alpha() < 255) {
+ gtk_color_selection_set_has_opacity_control(GTK_COLOR_SELECTION(gtkColorSelection), true);
+ gtk_color_selection_set_current_alpha(GTK_COLOR_SELECTION(gtkColorSelection), color.alpha() << 8);
+ }
+}
+
+QColor QGtk2ColorDialogHelper::currentColor() const
+{
+ GtkDialog *gtkDialog = d->gtkDialog();
+ GtkWidget *gtkColorSelection = gtk_color_selection_dialog_get_color_selection(GTK_COLOR_SELECTION_DIALOG(gtkDialog));
+ GdkColor gdkColor;
+ gtk_color_selection_get_current_color(GTK_COLOR_SELECTION(gtkColorSelection), &gdkColor);
+ guint16 alpha = gtk_color_selection_get_current_alpha(GTK_COLOR_SELECTION(gtkColorSelection));
+ return QColor(gdkColor.red >> 8, gdkColor.green >> 8, gdkColor.blue >> 8, alpha >> 8);
+}
+
+void QGtk2ColorDialogHelper::onAccepted()
+{
+ emit accept();
+ emit colorSelected(currentColor());
+}
+
+void QGtk2ColorDialogHelper::onColorChanged(QGtk2ColorDialogHelper *dialog)
+{
+ emit dialog->currentColorChanged(dialog->currentColor());
+}
+
+void QGtk2ColorDialogHelper::applyOptions()
+{
+ GtkDialog *gtkDialog = d->gtkDialog();
+ gtk_window_set_title(GTK_WINDOW(gtkDialog), options()->windowTitle().toUtf8());
+
+ GtkWidget *gtkColorSelection = gtk_color_selection_dialog_get_color_selection(GTK_COLOR_SELECTION_DIALOG(gtkDialog));
+ gtk_color_selection_set_has_opacity_control(GTK_COLOR_SELECTION(gtkColorSelection), options()->testOption(QColorDialogOptions::ShowAlphaChannel));
+
+ GtkWidget *okButton = 0;
+ GtkWidget *cancelButton = 0;
+ GtkWidget *helpButton = 0;
+ g_object_get(G_OBJECT(gtkDialog), "ok-button", &okButton, "cancel-button", &cancelButton, "help-button", &helpButton, NULL);
+ if (okButton)
+ g_object_set(G_OBJECT(okButton), "visible", !options()->testOption(QColorDialogOptions::NoButtons), NULL);
+ if (cancelButton)
+ g_object_set(G_OBJECT(cancelButton), "visible", !options()->testOption(QColorDialogOptions::NoButtons), NULL);
+ if (helpButton)
+ gtk_widget_hide(helpButton);
+}
+
+QGtk2FileDialogHelper::QGtk2FileDialogHelper()
+{
+ d.reset(new QGtk2Dialog(gtk_file_chooser_dialog_new("", 0,
+ GTK_FILE_CHOOSER_ACTION_OPEN,
+ GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL,
+ GTK_STOCK_OK, GTK_RESPONSE_OK, NULL)));
+ connect(d.data(), SIGNAL(accept()), this, SLOT(onAccepted()));
+ connect(d.data(), SIGNAL(reject()), this, SIGNAL(reject()));
+
+ g_signal_connect(GTK_FILE_CHOOSER(d->gtkDialog()), "selection-changed", G_CALLBACK(onSelectionChanged), this);
+ g_signal_connect_swapped(GTK_FILE_CHOOSER(d->gtkDialog()), "current-folder-changed", G_CALLBACK(onCurrentFolderChanged), this);
+}
+
+QGtk2FileDialogHelper::~QGtk2FileDialogHelper()
+{
+}
+
+bool QGtk2FileDialogHelper::show(Qt::WindowFlags flags, Qt::WindowModality modality, QWindow *parent)
+{
+ _dir.clear();
+ _selection.clear();
+
+ applyOptions();
+ return d->show(flags, modality, parent);
+}
+
+void QGtk2FileDialogHelper::exec()
+{
+ d->exec();
+}
+
+void QGtk2FileDialogHelper::hide()
+{
+ // After GtkFileChooserDialog has been hidden, gtk_file_chooser_get_current_folder()
+ // & gtk_file_chooser_get_filenames() will return bogus values -> cache the actual
+ // values before hiding the dialog
+ _dir = directory();
+ _selection = selectedFiles();
+
+ d->hide();
+}
+
+bool QGtk2FileDialogHelper::defaultNameFilterDisables() const
+{
+ return false;
+}
+
+void QGtk2FileDialogHelper::setDirectory(const QString &directory)
+{
+ GtkDialog *gtkDialog = d->gtkDialog();
+ gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER(gtkDialog), directory.toUtf8());
+}
+
+QString QGtk2FileDialogHelper::directory() const
+{
+ // While GtkFileChooserDialog is hidden, gtk_file_chooser_get_current_folder()
+ // returns a bogus value -> return the cached value before hiding
+ if (!_dir.isEmpty())
+ return _dir;
+
+ QString ret;
+ GtkDialog *gtkDialog = d->gtkDialog();
+ gchar *folder = gtk_file_chooser_get_current_folder(GTK_FILE_CHOOSER(gtkDialog));
+ if (folder) {
+ ret = QString::fromUtf8(folder);
+ g_free(folder);
+ }
+ return ret;
+}
+
+void QGtk2FileDialogHelper::selectFile(const QString &filename)
+{
+ GtkDialog *gtkDialog = d->gtkDialog();
+ gtk_file_chooser_select_filename(GTK_FILE_CHOOSER(gtkDialog), filename.toUtf8());
+}
+
+QStringList QGtk2FileDialogHelper::selectedFiles() const
+{
+ // While GtkFileChooserDialog is hidden, gtk_file_chooser_get_filenames()
+ // returns a bogus value -> return the cached value before hiding
+ if (!_selection.isEmpty())
+ return _selection;
+
+ QStringList selection;
+ GtkDialog *gtkDialog = d->gtkDialog();
+ GSList *filenames = gtk_file_chooser_get_filenames(GTK_FILE_CHOOSER(gtkDialog));
+ for (GSList *it = filenames; it; it = it->next)
+ selection += QString::fromUtf8((const char*)it->data);
+ g_slist_free(filenames);
+ return selection;
+}
+
+void QGtk2FileDialogHelper::setFilter()
+{
+ applyOptions();
+}
+
+void QGtk2FileDialogHelper::selectNameFilter(const QString &filter)
+{
+ GtkFileFilter *gtkFilter = _filters.value(filter);
+ if (gtkFilter) {
+ GtkDialog *gtkDialog = d->gtkDialog();
+ gtk_file_chooser_set_filter(GTK_FILE_CHOOSER(gtkDialog), gtkFilter);
+ }
+}
+
+QString QGtk2FileDialogHelper::selectedNameFilter() const
+{
+ GtkDialog *gtkDialog = d->gtkDialog();
+ GtkFileFilter *gtkFilter = gtk_file_chooser_get_filter(GTK_FILE_CHOOSER(gtkDialog));
+ return _filterNames.value(gtkFilter);
+}
+
+void QGtk2FileDialogHelper::onAccepted()
+{
+ emit accept();
+
+ QString filter = selectedNameFilter();
+ if (filter.isEmpty())
+ emit filterSelected(filter);
+
+ QStringList files = selectedFiles();
+ emit filesSelected(files);
+ if (files.count() == 1)
+ emit fileSelected(files.first());
+}
+
+void QGtk2FileDialogHelper::onSelectionChanged(GtkDialog *gtkDialog, QGtk2FileDialogHelper *helper)
+{
+ QString selection;
+ gchar *filename = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(gtkDialog));
+ if (filename) {
+ selection = QString::fromUtf8(filename);
+ g_free(filename);
+ }
+ emit helper->currentChanged(selection);
+}
+
+void QGtk2FileDialogHelper::onCurrentFolderChanged(QGtk2FileDialogHelper *dialog)
+{
+ emit dialog->directoryEntered(dialog->directory());
+}
+
+static GtkFileChooserAction gtkFileChooserAction(const QSharedPointer<QFileDialogOptions> &options)
+{
+ switch (options->fileMode()) {
+ case QFileDialogOptions::AnyFile:
+ case QFileDialogOptions::ExistingFile:
+ case QFileDialogOptions::ExistingFiles:
+ if (options->acceptMode() == QFileDialogOptions::AcceptOpen)
+ return GTK_FILE_CHOOSER_ACTION_OPEN;
+ else
+ return GTK_FILE_CHOOSER_ACTION_SAVE;
+ case QFileDialogOptions::Directory:
+ case QFileDialogOptions::DirectoryOnly:
+ default:
+ if (options->acceptMode() == QFileDialogOptions::AcceptOpen)
+ return GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER;
+ else
+ return GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER;
+ }
+}
+
+void QGtk2FileDialogHelper::applyOptions()
+{
+ GtkDialog *gtkDialog = d->gtkDialog();
+ const QSharedPointer<QFileDialogOptions> &opts = options();
+
+ gtk_window_set_title(GTK_WINDOW(gtkDialog), opts->windowTitle().toUtf8());
+ gtk_file_chooser_set_local_only(GTK_FILE_CHOOSER(gtkDialog), true);
+
+ const GtkFileChooserAction action = gtkFileChooserAction(opts);
+ gtk_file_chooser_set_action(GTK_FILE_CHOOSER(gtkDialog), action);
+
+ const bool selectMultiple = opts->fileMode() == QFileDialogOptions::ExistingFiles;
+ gtk_file_chooser_set_select_multiple(GTK_FILE_CHOOSER(gtkDialog), selectMultiple);
+
+ const bool confirmOverwrite = !opts->testOption(QFileDialogOptions::DontConfirmOverwrite);
+ gtk_file_chooser_set_do_overwrite_confirmation(GTK_FILE_CHOOSER(gtkDialog), confirmOverwrite);
+
+ const QStringList nameFilters = opts->nameFilters();
+ if (!nameFilters.isEmpty())
+ setNameFilters(nameFilters);
+
+ const QString initialDirectory = opts->initialDirectory();
+ if (!initialDirectory.isEmpty())
+ setDirectory(initialDirectory);
+
+ foreach (const QString &filename, opts->initiallySelectedFiles())
+ selectFile(filename);
+
+ const QString initialNameFilter = opts->initiallySelectedNameFilter();
+ if (!initialNameFilter.isEmpty())
+ selectNameFilter(initialNameFilter);
+
+ GtkWidget *acceptButton = gtk_dialog_get_widget_for_response(gtkDialog, GTK_RESPONSE_OK);
+ if (acceptButton) {
+ if (opts->isLabelExplicitlySet(QFileDialogOptions::Accept))
+ gtk_button_set_label(GTK_BUTTON(acceptButton), opts->labelText(QFileDialogOptions::Accept).toUtf8());
+ else if (opts->acceptMode() == QFileDialogOptions::AcceptOpen)
+ gtk_button_set_label(GTK_BUTTON(acceptButton), GTK_STOCK_OPEN);
+ else
+ gtk_button_set_label(GTK_BUTTON(acceptButton), GTK_STOCK_SAVE);
+ }
+
+ GtkWidget *rejectButton = gtk_dialog_get_widget_for_response(gtkDialog, GTK_RESPONSE_CANCEL);
+ if (rejectButton) {
+ if (opts->isLabelExplicitlySet(QFileDialogOptions::Reject))
+ gtk_button_set_label(GTK_BUTTON(rejectButton), opts->labelText(QFileDialogOptions::Reject).toUtf8());
+ else
+ gtk_button_set_label(GTK_BUTTON(rejectButton), GTK_STOCK_CANCEL);
+ }
+}
+
+void QGtk2FileDialogHelper::setNameFilters(const QStringList &filters)
+{
+ GtkDialog *gtkDialog = d->gtkDialog();
+ foreach (GtkFileFilter *filter, _filters)
+ gtk_file_chooser_remove_filter(GTK_FILE_CHOOSER(gtkDialog), filter);
+
+ _filters.clear();
+ _filterNames.clear();
+
+ foreach (const QString &filter, filters) {
+ GtkFileFilter *gtkFilter = gtk_file_filter_new();
+ const QString name = filter.left(filter.indexOf(QLatin1Char('(')));
+ const QStringList extensions = cleanFilterList(filter);
+
+ gtk_file_filter_set_name(gtkFilter, name.isEmpty() ? extensions.join(QStringLiteral(", ")).toUtf8() : name.toUtf8());
+ foreach (const QString &ext, extensions)
+ gtk_file_filter_add_pattern(gtkFilter, ext.toUtf8());
+
+ gtk_file_chooser_add_filter(GTK_FILE_CHOOSER(gtkDialog), gtkFilter);
+
+ _filters.insert(filter, gtkFilter);
+ _filterNames.insert(gtkFilter, filter);
+ }
+}
+
+QGtk2FontDialogHelper::QGtk2FontDialogHelper()
+{
+ d.reset(new QGtk2Dialog(gtk_font_selection_dialog_new("")));
+ connect(d.data(), SIGNAL(accept()), this, SLOT(onAccepted()));
+ connect(d.data(), SIGNAL(reject()), this, SIGNAL(reject()));
+}
+
+QGtk2FontDialogHelper::~QGtk2FontDialogHelper()
+{
+}
+
+bool QGtk2FontDialogHelper::show(Qt::WindowFlags flags, Qt::WindowModality modality, QWindow *parent)
+{
+ applyOptions();
+ return d->show(flags, modality, parent);
+}
+
+void QGtk2FontDialogHelper::exec()
+{
+ d->exec();
+}
+
+void QGtk2FontDialogHelper::hide()
+{
+ d->hide();
+}
+
+static QString qt_fontToString(const QFont &font)
+{
+ PangoFontDescription *desc = pango_font_description_new();
+ pango_font_description_set_size(desc, font.pointSizeF() * PANGO_SCALE);
+ pango_font_description_set_family(desc, font.family().toUtf8());
+
+ int weight = font.weight();
+ if (weight >= QFont::Black)
+ pango_font_description_set_weight(desc, PANGO_WEIGHT_HEAVY);
+ else if (weight >= QFont::Bold)
+ pango_font_description_set_weight(desc, PANGO_WEIGHT_BOLD);
+ else if (weight >= QFont::DemiBold)
+ pango_font_description_set_weight(desc, PANGO_WEIGHT_SEMIBOLD);
+ else if (weight >= QFont::Normal)
+ pango_font_description_set_weight(desc, PANGO_WEIGHT_NORMAL);
+ else
+ pango_font_description_set_weight(desc, PANGO_WEIGHT_LIGHT);
+
+ int style = font.style();
+ if (style == QFont::StyleItalic)
+ pango_font_description_set_style(desc, PANGO_STYLE_ITALIC);
+ else if (style == QFont::StyleOblique)
+ pango_font_description_set_style(desc, PANGO_STYLE_OBLIQUE);
+ else
+ pango_font_description_set_style(desc, PANGO_STYLE_NORMAL);
+
+ char *str = pango_font_description_to_string(desc);
+ QString name = QString::fromUtf8(str);
+ pango_font_description_free(desc);
+ g_free(str);
+ return name;
+}
+
+static QFont qt_fontFromString(const QString &name)
+{
+ QFont font;
+ PangoFontDescription *desc = pango_font_description_from_string(name.toUtf8());
+ font.setPointSizeF(static_cast<float>(pango_font_description_get_size(desc)) / PANGO_SCALE);
+
+ QString family = QString::fromUtf8(pango_font_description_get_family(desc));
+ if (!family.isEmpty())
+ font.setFamily(family);
+
+ int weight = pango_font_description_get_weight(desc);
+ if (weight >= PANGO_WEIGHT_HEAVY)
+ font.setWeight(QFont::Black);
+ else if (weight >= PANGO_WEIGHT_BOLD)
+ font.setWeight(QFont::Bold);
+ else if (weight >= PANGO_WEIGHT_SEMIBOLD)
+ font.setWeight(QFont::DemiBold);
+ else if (weight >= PANGO_WEIGHT_NORMAL)
+ font.setWeight(QFont::Normal);
+ else
+ font.setWeight(QFont::Light);
+
+ PangoStyle style = pango_font_description_get_style(desc);
+ if (style == PANGO_STYLE_ITALIC)
+ font.setStyle(QFont::StyleItalic);
+ else if (style == PANGO_STYLE_OBLIQUE)
+ font.setStyle(QFont::StyleOblique);
+ else
+ font.setStyle(QFont::StyleNormal);
+
+ pango_font_description_free(desc);
+ return font;
+}
+
+void QGtk2FontDialogHelper::setCurrentFont(const QFont &font)
+{
+ GtkFontSelectionDialog *gtkDialog = GTK_FONT_SELECTION_DIALOG(d->gtkDialog());
+ gtk_font_selection_dialog_set_font_name(gtkDialog, qt_fontToString(font).toUtf8());
+}
+
+QFont QGtk2FontDialogHelper::currentFont() const
+{
+ GtkFontSelectionDialog *gtkDialog = GTK_FONT_SELECTION_DIALOG(d->gtkDialog());
+ gchar *name = gtk_font_selection_dialog_get_font_name(gtkDialog);
+ QFont font = qt_fontFromString(QString::fromUtf8(name));
+ g_free(name);
+ return font;
+}
+
+void QGtk2FontDialogHelper::onAccepted()
+{
+ emit accept();
+ emit fontSelected(currentFont());
+}
+
+void QGtk2FontDialogHelper::applyOptions()
+{
+ GtkDialog *gtkDialog = d->gtkDialog();
+ const QSharedPointer<QFontDialogOptions> &opts = options();
+
+ gtk_window_set_title(GTK_WINDOW(gtkDialog), opts->windowTitle().toUtf8());
+
+ GtkWidget *okButton = gtk_font_selection_dialog_get_ok_button(GTK_FONT_SELECTION_DIALOG(gtkDialog));
+ GtkWidget *cancelButton = gtk_font_selection_dialog_get_cancel_button(GTK_FONT_SELECTION_DIALOG(gtkDialog));
+ if (okButton)
+ gtk_widget_set_visible(okButton, !options()->testOption(QFontDialogOptions::NoButtons));
+ if (cancelButton)
+ gtk_widget_set_visible(cancelButton, !options()->testOption(QFontDialogOptions::NoButtons));
+}
+
+QT_END_NAMESPACE
+
+#include "qgtk2dialoghelpers.moc"
diff --git a/src/plugins/platformthemes/gtk2/qgtk2dialoghelpers.h b/src/plugins/platformthemes/gtk2/qgtk2dialoghelpers.h
new file mode 100644
index 0000000000..c2d12625f5
--- /dev/null
+++ b/src/plugins/platformthemes/gtk2/qgtk2dialoghelpers.h
@@ -0,0 +1,143 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QGTK2DIALOGHELPERS_P_H
+#define QGTK2DIALOGHELPERS_P_H
+
+#include <QtCore/qscopedpointer.h>
+#include <qpa/qplatformdialoghelper.h>
+
+typedef struct _GtkDialog GtkDialog;
+typedef struct _GtkFileFilter GtkFileFilter;
+
+QT_BEGIN_NAMESPACE
+
+class QGtk2Dialog;
+
+class QGtk2ColorDialogHelper : public QPlatformColorDialogHelper
+{
+ Q_OBJECT
+
+public:
+ QGtk2ColorDialogHelper();
+ ~QGtk2ColorDialogHelper();
+
+ bool show(Qt::WindowFlags flags, Qt::WindowModality modality, QWindow *parent);
+ void exec();
+ void hide();
+
+ void setCurrentColor(const QColor &color);
+ QColor currentColor() const;
+
+private Q_SLOTS:
+ void onAccepted();
+
+private:
+ static void onColorChanged(QGtk2ColorDialogHelper *helper);
+ void applyOptions();
+
+ QScopedPointer<QGtk2Dialog> d;
+};
+
+class QGtk2FileDialogHelper : public QPlatformFileDialogHelper
+{
+ Q_OBJECT
+
+public:
+ QGtk2FileDialogHelper();
+ ~QGtk2FileDialogHelper();
+
+ bool show(Qt::WindowFlags flags, Qt::WindowModality modality, QWindow *parent);
+ void exec();
+ void hide();
+
+ bool defaultNameFilterDisables() const;
+ void setDirectory(const QString &directory);
+ QString directory() const;
+ void selectFile(const QString &filename);
+ QStringList selectedFiles() const;
+ void setFilter();
+ void selectNameFilter(const QString &filter);
+ QString selectedNameFilter() const;
+
+private Q_SLOTS:
+ void onAccepted();
+
+private:
+ static void onSelectionChanged(GtkDialog *dialog, QGtk2FileDialogHelper *helper);
+ static void onCurrentFolderChanged(QGtk2FileDialogHelper *helper);
+ void applyOptions();
+ void setNameFilters(const QStringList &filters);
+
+ QString _dir;
+ QStringList _selection;
+ QHash<QString, GtkFileFilter*> _filters;
+ QHash<GtkFileFilter*, QString> _filterNames;
+ QScopedPointer<QGtk2Dialog> d;
+};
+
+class QGtk2FontDialogHelper : public QPlatformFontDialogHelper
+{
+ Q_OBJECT
+
+public:
+ QGtk2FontDialogHelper();
+ ~QGtk2FontDialogHelper();
+
+ bool show(Qt::WindowFlags flags, Qt::WindowModality modality, QWindow *parent);
+ void exec();
+ void hide();
+
+ void setCurrentFont(const QFont &font);
+ QFont currentFont() const;
+
+private Q_SLOTS:
+ void onAccepted();
+
+private:
+ void applyOptions();
+
+ QScopedPointer<QGtk2Dialog> d;
+};
+
+QT_END_NAMESPACE
+
+#endif // QGTK2DIALOGHELPERS_P_H
diff --git a/src/plugins/platformthemes/gtk2/qgtk2theme.cpp b/src/plugins/platformthemes/gtk2/qgtk2theme.cpp
new file mode 100644
index 0000000000..f069d9f97c
--- /dev/null
+++ b/src/plugins/platformthemes/gtk2/qgtk2theme.cpp
@@ -0,0 +1,108 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qgtk2theme.h"
+#include "qgtk2dialoghelpers.h"
+#include <QVariant>
+
+#undef signals
+#include <gtk/gtk.h>
+
+#include <X11/Xlib.h>
+
+QT_BEGIN_NAMESPACE
+
+const char *QGtk2Theme::name = "gtk2";
+
+static QString gtkSetting(const gchar *propertyName)
+{
+ GtkSettings *settings = gtk_settings_get_default();
+ gchararray value;
+ g_object_get(settings, propertyName, &value, NULL);
+ QString str = QString::fromUtf8(value);
+ g_free(value);
+ return str;
+}
+
+QGtk2Theme::QGtk2Theme()
+{
+ // gtk_init will reset the Xlib error handler, and that causes
+ // Qt applications to quit on X errors. Therefore, we need to manually restore it.
+ int (*oldErrorHandler)(Display *, XErrorEvent *) = XSetErrorHandler(NULL);
+
+ gtk_init(0, 0);
+
+ XSetErrorHandler(oldErrorHandler);
+}
+
+QVariant QGtk2Theme::themeHint(QPlatformTheme::ThemeHint hint) const
+{
+ switch (hint) {
+ case QPlatformTheme::SystemIconThemeName:
+ return QVariant(gtkSetting("gtk-icon-theme-name"));
+ case QPlatformTheme::SystemIconFallbackThemeName:
+ return QVariant(gtkSetting("gtk-fallback-icon-theme"));
+ default:
+ return QGnomeTheme::themeHint(hint);
+ }
+}
+
+bool QGtk2Theme::usePlatformNativeDialog(DialogType type) const
+{
+ Q_UNUSED(type);
+ return true;
+}
+
+QPlatformDialogHelper *QGtk2Theme::createPlatformDialogHelper(DialogType type) const
+{
+ switch (type) {
+ case ColorDialog:
+ return new QGtk2ColorDialogHelper;
+ case FileDialog:
+ return new QGtk2FileDialogHelper;
+ case FontDialog:
+ return new QGtk2FontDialogHelper;
+ default:
+ return 0;
+ }
+}
+
+QT_END_NAMESPACE
diff --git a/src/plugins/platformthemes/gtk2/qgtk2theme.h b/src/plugins/platformthemes/gtk2/qgtk2theme.h
new file mode 100644
index 0000000000..a0bd34ed9f
--- /dev/null
+++ b/src/plugins/platformthemes/gtk2/qgtk2theme.h
@@ -0,0 +1,64 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the plugins of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QGTK2THEME_H
+#define QGTK2THEME_H
+
+#include <private/qgenericunixthemes_p.h>
+
+QT_BEGIN_NAMESPACE
+
+class QGtk2Theme : public QGnomeTheme
+{
+public:
+ QGtk2Theme();
+
+ QVariant themeHint(ThemeHint hint) const;
+
+ bool usePlatformNativeDialog(DialogType type) const;
+ QPlatformDialogHelper *createPlatformDialogHelper(DialogType type) const;
+
+ static const char *name;
+};
+
+QT_END_NAMESPACE
+
+#endif // QGTK2THEME_H
diff --git a/src/plugins/platformthemes/platformthemes.pro b/src/plugins/platformthemes/platformthemes.pro
new file mode 100644
index 0000000000..23dcda2c82
--- /dev/null
+++ b/src/plugins/platformthemes/platformthemes.pro
@@ -0,0 +1,3 @@
+TEMPLATE = subdirs
+
+contains(QT_CONFIG, gtk2): SUBDIRS += gtk2
diff --git a/src/plugins/plugins.pro b/src/plugins/plugins.pro
index 3b0ff3f6c8..516105401e 100644
--- a/src/plugins/plugins.pro
+++ b/src/plugins/plugins.pro
@@ -1,7 +1,8 @@
TEMPLATE = subdirs
-SUBDIRS *= sqldrivers bearer
-qtHaveModule(gui): SUBDIRS *= imageformats platforms platforminputcontexts generic
+SUBDIRS *= sqldrivers
+qtHaveModule(network): SUBDIRS += bearer
+qtHaveModule(gui): SUBDIRS *= imageformats platforms platforminputcontexts platformthemes generic
qtHaveModule(widgets): SUBDIRS += accessible
!wince*:qtHaveModule(widgets): SUBDIRS += printsupport
diff --git a/src/plugins/printsupport/cups/qcupsprintengine.cpp b/src/plugins/printsupport/cups/qcupsprintengine.cpp
index 21895e9d28..1c86420cb2 100644
--- a/src/plugins/printsupport/cups/qcupsprintengine.cpp
+++ b/src/plugins/printsupport/cups/qcupsprintengine.cpp
@@ -103,7 +103,9 @@ void QCupsPrintEngine::setProperty(PrintEnginePropertyKey key, const QVariant &v
d->cupsOptions = value.toStringList();
break;
case PPK_CupsStringPageSize:
+ case PPK_PaperName:
d->cupsStringPageSize = value.toString();
+ d->setPaperName();
break;
case PPK_PrinterName:
// prevent setting the defaults again for the same printer
@@ -140,6 +142,7 @@ QVariant QCupsPrintEngine::property(PrintEnginePropertyKey key) const
ret = d->cupsOptions;
break;
case PPK_CupsStringPageSize:
+ case PPK_PaperName:
ret = d->cupsStringPageSize;
break;
default:
@@ -284,6 +287,7 @@ void QCupsPrintEnginePrivate::setPaperSize()
QPdf::PaperSize size = QPdf::paperSize(QPrinter::PaperSize(printerPaperSize));
if (cups.currentPPD()) {
+ cupsStringPageSize = QLatin1String("Custom");
const ppd_option_t* pageSizes = cups.pageSizes();
for (int i = 0; i < pageSizes->num_choices; ++i) {
QByteArray cupsPageSize = pageSizes->choices[i].choice;
@@ -293,7 +297,7 @@ void QCupsPrintEnginePrivate::setPaperSize()
if (qAbs(size.width - tmpCupsPaperRect.width()) < 5 && qAbs(size.height - tmpCupsPaperRect.height()) < 5) {
cupsPaperRect = tmpCupsPaperRect;
cupsPageRect = tmpCupsPageRect;
-
+ cupsStringPageSize = pageSizes->choices[i].text;
leftMargin = cupsPageRect.x() - cupsPaperRect.x();
topMargin = cupsPageRect.y() - cupsPaperRect.y();
rightMargin = cupsPaperRect.right() - cupsPageRect.right();
@@ -307,6 +311,43 @@ void QCupsPrintEnginePrivate::setPaperSize()
}
}
+void QCupsPrintEnginePrivate::setPaperName()
+{
+ if (QCUPSSupport::isAvailable()) {
+ QCUPSSupport cups;
+ if (cups.currentPPD()) {
+ const ppd_option_t* pageSizes = cups.pageSizes();
+ bool foundPaperName = false;
+ for (int i = 0; i < pageSizes->num_choices; ++i) {
+ if (cupsStringPageSize == pageSizes->choices[i].text) {
+ foundPaperName = true;
+ QByteArray cupsPageSize = pageSizes->choices[i].choice;
+ cupsPaperRect = cups.paperRect(cupsPageSize);
+ cupsPageRect = cups.pageRect(cupsPageSize);
+ leftMargin = cupsPageRect.x() - cupsPaperRect.x();
+ topMargin = cupsPageRect.y() - cupsPaperRect.y();
+ rightMargin = cupsPaperRect.right() - cupsPageRect.right();
+ bottomMargin = cupsPaperRect.bottom() - cupsPageRect.bottom();
+ printerPaperSize = QPrinter::Custom;
+ customPaperSize = cupsPaperRect.size();
+ for (int ps = 0; ps < QPrinter::NPageSize; ++ps) {
+ QPdf::PaperSize size = QPdf::paperSize(QPrinter::PaperSize(ps));
+ if (qAbs(size.width - cupsPaperRect.width()) < 5 && qAbs(size.height - cupsPaperRect.height()) < 5) {
+ printerPaperSize = static_cast<QPrinter::PaperSize>(ps);
+ customPaperSize = QSize();
+ break;
+ }
+ }
+ updatePaperSize();
+ break;
+ }
+ }
+ if (!foundPaperName)
+ cupsStringPageSize = QString();
+ }
+ }
+}
+
void QCupsPrintEnginePrivate::setCupsDefaults()
{
if (QCUPSSupport::isAvailable()) {
@@ -348,8 +389,10 @@ void QCupsPrintEnginePrivate::setCupsDefaults()
const ppd_option_t* pageSizes = cups.pageSizes();
QByteArray cupsPageSize;
for (int i = 0; i < pageSizes->num_choices; ++i) {
- if (static_cast<int>(pageSizes->choices[i].marked) == 1)
+ if (static_cast<int>(pageSizes->choices[i].marked) == 1) {
cupsPageSize = pageSizes->choices[i].choice;
+ cupsStringPageSize = pageSizes->choices[i].text;
+ }
}
cupsOptions = cups.options();
diff --git a/src/plugins/printsupport/cups/qcupsprintengine_p.h b/src/plugins/printsupport/cups/qcupsprintengine_p.h
index 31ee6bb256..db947a0232 100644
--- a/src/plugins/printsupport/cups/qcupsprintengine_p.h
+++ b/src/plugins/printsupport/cups/qcupsprintengine_p.h
@@ -97,6 +97,7 @@ public:
void updatePaperSize();
void setPaperSize();
+ void setPaperName();
void setCupsDefaults();
private:
diff --git a/src/plugins/printsupport/cups/qcupsprintersupport.cpp b/src/plugins/printsupport/cups/qcupsprintersupport.cpp
index c2e9bd445f..f41d4f5047 100644
--- a/src/plugins/printsupport/cups/qcupsprintersupport.cpp
+++ b/src/plugins/printsupport/cups/qcupsprintersupport.cpp
@@ -86,6 +86,11 @@ QList<QPrinter::PaperSize> QCupsPrinterSupport::supportedPaperSizes(const QPrint
return QCUPSSupport::getCupsPrinterPaperSizes(printerIndex(printerInfo));
}
+QList<QPair<QString, QSizeF> > QCupsPrinterSupport::supportedSizesWithNames(const QPrinterInfo &printerInfo) const
+{
+ return QCUPSSupport::getCupsPrinterPaperSizesWithNames(printerIndex(printerInfo));
+}
+
void QCupsPrinterSupport::loadCups()
{
cupsGetDests = (CupsGetDests) m_cups.resolve("cupsGetDests");
diff --git a/src/plugins/printsupport/cups/qcupsprintersupport_p.h b/src/plugins/printsupport/cups/qcupsprintersupport_p.h
index 43fe871021..e9fe24203e 100644
--- a/src/plugins/printsupport/cups/qcupsprintersupport_p.h
+++ b/src/plugins/printsupport/cups/qcupsprintersupport_p.h
@@ -52,7 +52,6 @@
#include <cups/cups.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
typedef int (*CupsGetDests)(cups_dest_t **dests);
@@ -68,6 +67,7 @@ public:
virtual QPrintEngine *createNativePrintEngine(QPrinter::PrinterMode printerMode);
virtual QPaintEngine *createPaintEngine(QPrintEngine *printEngine, QPrinter::PrinterMode);
virtual QList<QPrinter::PaperSize> supportedPaperSizes(const QPrinterInfo &) const;
+ virtual QList<QPair<QString, QSizeF> > supportedSizesWithNames(const QPrinterInfo &) const;
virtual QString printerOption(const QPrinterInfo &printer, const QString &key) const;
virtual PrinterOptions printerOptions(const QPrinterInfo &printer) const;
@@ -86,7 +86,6 @@ private:
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QT_NO_PRINTER
#endif // QCUPSPRINTERSUPPORT_H
diff --git a/src/plugins/printsupport/windows/qwindowsprintersupport.cpp b/src/plugins/printsupport/windows/qwindowsprintersupport.cpp
index 469dbdb34e..36e7a3fb8e 100644
--- a/src/plugins/printsupport/windows/qwindowsprintersupport.cpp
+++ b/src/plugins/printsupport/windows/qwindowsprintersupport.cpp
@@ -93,4 +93,9 @@ QList<QPrinter::PaperSize> QWindowsPrinterSupport::supportedPaperSizes(const QPr
return QWin32PrintEngine::supportedPaperSizes(printerInfo);
}
+QList<QPair<QString, QSizeF> >QWindowsPrinterSupport::supportedSizesWithNames(const QPrinterInfo &printerInfo) const
+{
+ return QWin32PrintEngine::supportedSizesWithNames(printerInfo);
+}
+
QT_END_NAMESPACE
diff --git a/src/plugins/printsupport/windows/qwindowsprintersupport.h b/src/plugins/printsupport/windows/qwindowsprintersupport.h
index afa341a82f..1d5a4f3da4 100644
--- a/src/plugins/printsupport/windows/qwindowsprintersupport.h
+++ b/src/plugins/printsupport/windows/qwindowsprintersupport.h
@@ -44,7 +44,6 @@
#include <qpa/qplatformprintersupport.h>
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
class QWin32PrintEngine;
@@ -58,9 +57,9 @@ public:
virtual QPrintEngine *createNativePrintEngine(QPrinter::PrinterMode printerMode);
virtual QPaintEngine *createPaintEngine(QPrintEngine *printEngine, QPrinter::PrinterMode);
virtual QList<QPrinter::PaperSize> supportedPaperSizes(const QPrinterInfo &) const;
+ virtual QList<QPair<QString, QSizeF> >supportedSizesWithNames(const QPrinterInfo &printerInfo) const;
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif // WINDOWSPRINTERSUPPORT_H
diff --git a/src/plugins/sqldrivers/db2/main.cpp b/src/plugins/sqldrivers/db2/main.cpp
index abde11b178..6c796beff6 100644
--- a/src/plugins/sqldrivers/db2/main.cpp
+++ b/src/plugins/sqldrivers/db2/main.cpp
@@ -41,7 +41,7 @@
#include <qsqldriverplugin.h>
#include <qstringlist.h>
-#include "../../../sql/drivers/db2/qsql_db2.h"
+#include "../../../sql/drivers/db2/qsql_db2_p.h"
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/sqldrivers/ibase/main.cpp b/src/plugins/sqldrivers/ibase/main.cpp
index 1ce663d868..e7d1c38690 100644
--- a/src/plugins/sqldrivers/ibase/main.cpp
+++ b/src/plugins/sqldrivers/ibase/main.cpp
@@ -41,7 +41,7 @@
#include <qsqldriverplugin.h>
#include <qstringlist.h>
-#include "../../../sql/drivers/ibase/qsql_ibase.h"
+#include "../../../sql/drivers/ibase/qsql_ibase_p.h"
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/sqldrivers/mysql/main.cpp b/src/plugins/sqldrivers/mysql/main.cpp
index d313152cd7..8aaee6c268 100644
--- a/src/plugins/sqldrivers/mysql/main.cpp
+++ b/src/plugins/sqldrivers/mysql/main.cpp
@@ -41,7 +41,7 @@
#include <qsqldriverplugin.h>
#include <qstringlist.h>
-#include "../../../sql/drivers/mysql/qsql_mysql.h"
+#include "../../../sql/drivers/mysql/qsql_mysql_p.h"
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/sqldrivers/oci/main.cpp b/src/plugins/sqldrivers/oci/main.cpp
index fc069df534..f1b0266536 100644
--- a/src/plugins/sqldrivers/oci/main.cpp
+++ b/src/plugins/sqldrivers/oci/main.cpp
@@ -41,7 +41,7 @@
#include <qsqldriverplugin.h>
#include <qstringlist.h>
-#include "../../../sql/drivers/oci/qsql_oci.h"
+#include "../../../sql/drivers/oci/qsql_oci_p.h"
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/sqldrivers/odbc/main.cpp b/src/plugins/sqldrivers/odbc/main.cpp
index 215cbf6042..fda5c68fcc 100644
--- a/src/plugins/sqldrivers/odbc/main.cpp
+++ b/src/plugins/sqldrivers/odbc/main.cpp
@@ -41,7 +41,7 @@
#include <qsqldriverplugin.h>
#include <qstringlist.h>
-#include "../../../sql/drivers/odbc/qsql_odbc.h"
+#include "../../../sql/drivers/odbc/qsql_odbc_p.h"
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/sqldrivers/psql/main.cpp b/src/plugins/sqldrivers/psql/main.cpp
index b3cba82f3e..3851ba6bfe 100644
--- a/src/plugins/sqldrivers/psql/main.cpp
+++ b/src/plugins/sqldrivers/psql/main.cpp
@@ -41,7 +41,7 @@
#include <qsqldriverplugin.h>
#include <qstringlist.h>
-#include "../../../sql/drivers/psql/qsql_psql.h"
+#include "../../../sql/drivers/psql/qsql_psql_p.h"
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/sqldrivers/qsqldriverbase.pri b/src/plugins/sqldrivers/qsqldriverbase.pri
index 17424f6764..512c046ec1 100644
--- a/src/plugins/sqldrivers/qsqldriverbase.pri
+++ b/src/plugins/sqldrivers/qsqldriverbase.pri
@@ -1,4 +1,4 @@
-QT = core sql-private
+QT = core core-private sql-private
PLUGIN_TYPE = sqldrivers
load(qt_plugin)
diff --git a/src/plugins/sqldrivers/sqlite/smain.cpp b/src/plugins/sqldrivers/sqlite/smain.cpp
index e52c235c18..1835962331 100644
--- a/src/plugins/sqldrivers/sqlite/smain.cpp
+++ b/src/plugins/sqldrivers/sqlite/smain.cpp
@@ -41,7 +41,7 @@
#include <qsqldriverplugin.h>
#include <qstringlist.h>
-#include "../../../../src/sql/drivers/sqlite/qsql_sqlite.h"
+#include "../../../../src/sql/drivers/sqlite/qsql_sqlite_p.h"
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/sqldrivers/sqlite2/smain.cpp b/src/plugins/sqldrivers/sqlite2/smain.cpp
index 38eb8e7fed..e15834a18e 100644
--- a/src/plugins/sqldrivers/sqlite2/smain.cpp
+++ b/src/plugins/sqldrivers/sqlite2/smain.cpp
@@ -41,7 +41,7 @@
#include <qsqldriverplugin.h>
#include <qstringlist.h>
-#include "../../../../src/sql/drivers/sqlite2/qsql_sqlite2.h"
+#include "../../../../src/sql/drivers/sqlite2/qsql_sqlite2_p.h"
QT_BEGIN_NAMESPACE
diff --git a/src/plugins/sqldrivers/tds/main.cpp b/src/plugins/sqldrivers/tds/main.cpp
index 9066efa172..1cb04e9e07 100644
--- a/src/plugins/sqldrivers/tds/main.cpp
+++ b/src/plugins/sqldrivers/tds/main.cpp
@@ -47,7 +47,7 @@
#define _WINSCARD_H_
#include <windows.h>
#endif
-#include "../../../sql/drivers/tds/qsql_tds.h"
+#include "../../../sql/drivers/tds/qsql_tds_p.h"
QT_BEGIN_NAMESPACE
diff --git a/src/printsupport/dialogs/dialogs.pri b/src/printsupport/dialogs/dialogs.pri
index 9db975e202..9659046f60 100644
--- a/src/printsupport/dialogs/dialogs.pri
+++ b/src/printsupport/dialogs/dialogs.pri
@@ -8,7 +8,7 @@ HEADERS += \
dialogs/qprintdialog.h \
dialogs/qprintpreviewdialog.h
-mac {
+mac:!ios {
OBJECTIVE_SOURCES += dialogs/qpagesetupdialog_mac.mm \
dialogs/qprintdialog_mac.mm
LIBS += -framework Cocoa
diff --git a/src/printsupport/dialogs/qabstractprintdialog.h b/src/printsupport/dialogs/qabstractprintdialog.h
index 3fdaa0f57d..87979310b5 100644
--- a/src/printsupport/dialogs/qabstractprintdialog.h
+++ b/src/printsupport/dialogs/qabstractprintdialog.h
@@ -45,8 +45,6 @@
#include <QtWidgets/qdialog.h>
#include <QtPrintSupport/qtprintsupportglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -125,6 +123,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QAbstractPrintDialog::PrintDialogOptions)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QABSTRACTPRINTDIALOG_H
diff --git a/src/printsupport/dialogs/qpagesetupdialog.h b/src/printsupport/dialogs/qpagesetupdialog.h
index aebc540e41..c316e42166 100644
--- a/src/printsupport/dialogs/qpagesetupdialog.h
+++ b/src/printsupport/dialogs/qpagesetupdialog.h
@@ -45,8 +45,6 @@
#include <QtWidgets/qdialog.h>
#include <QtPrintSupport/qtprintsupportglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -88,6 +86,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPAGESETUPDIALOG_H
diff --git a/src/printsupport/dialogs/qpagesetupdialog_unix.cpp b/src/printsupport/dialogs/qpagesetupdialog_unix.cpp
index 322d47d1fb..1e0251c6d2 100644
--- a/src/printsupport/dialogs/qpagesetupdialog_unix.cpp
+++ b/src/printsupport/dialogs/qpagesetupdialog_unix.cpp
@@ -360,7 +360,7 @@ void QPageSetupWidget::setupPrinter() const
else {
m_printer->setPaperSize(static_cast<QPrinter::PaperSize>(ps));
}
-
+ m_printer->setPaperName(widget.paperSize->currentText());
#ifdef PSD_ENABLE_PAPERSOURCE
m_printer->setPaperSource((QPrinter::PaperSource)widget.paperSource->currentIndex());
#endif
@@ -380,16 +380,22 @@ void QPageSetupWidget::selectPrinter()
int cupsDefaultSize = 0;
QSize qtPreferredSize = m_printer->paperSize(QPrinter::Point).toSize();
+ QString qtPaperName = m_printer->paperName();
bool preferredSizeMatched = false;
for (int i = 0; i < numChoices; ++i) {
widget.paperSize->addItem(QString::fromLocal8Bit(pageSizes->choices[i].text), QByteArray(pageSizes->choices[i].choice));
if (static_cast<int>(pageSizes->choices[i].marked) == 1)
cupsDefaultSize = i;
- QRect cupsPaperSize = cups.paperRect(pageSizes->choices[i].choice);
- QSize diff = cupsPaperSize.size() - qtPreferredSize;
- if (qAbs(diff.width()) < 5 && qAbs(diff.height()) < 5) {
+ if (qtPaperName == QString::fromLocal8Bit(pageSizes->choices[i].text)) {
widget.paperSize->setCurrentIndex(i);
preferredSizeMatched = true;
+ } else {
+ QRect cupsPaperSize = cups.paperRect(pageSizes->choices[i].choice);
+ QSize diff = cupsPaperSize.size() - qtPreferredSize;
+ if (qAbs(diff.width()) < 5 && qAbs(diff.height()) < 5) {
+ widget.paperSize->setCurrentIndex(i);
+ preferredSizeMatched = true;
+ }
}
}
if (!preferredSizeMatched)
@@ -452,7 +458,7 @@ void QPageSetupWidget::_q_paperSizeChanged()
bool custom = size == QPrinter::Custom;
#if !defined(QT_NO_CUPS) && !defined(QT_NO_LIBRARY)
- custom = custom ? m_cups : custom;
+ custom = custom && m_cups && (m_printer->paperName() == QLatin1String("Custom"));
#endif
widget.paperWidth->setEnabled(custom);
diff --git a/src/printsupport/dialogs/qprintdialog.h b/src/printsupport/dialogs/qprintdialog.h
index 124eb8746c..7d77c6af07 100644
--- a/src/printsupport/dialogs/qprintdialog.h
+++ b/src/printsupport/dialogs/qprintdialog.h
@@ -44,8 +44,6 @@
#include <QtPrintSupport/qabstractprintdialog.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -121,6 +119,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPRINTDIALOG_H
diff --git a/src/printsupport/dialogs/qprintpreviewdialog.h b/src/printsupport/dialogs/qprintpreviewdialog.h
index 4101cc8c20..b9c8737746 100644
--- a/src/printsupport/dialogs/qprintpreviewdialog.h
+++ b/src/printsupport/dialogs/qprintpreviewdialog.h
@@ -47,8 +47,6 @@
#ifndef QT_NO_PRINTPREVIEWDIALOG
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -99,8 +97,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_PRINTPREVIEWDIALOG
#endif // QPRINTPREVIEWDIALOG_H
diff --git a/src/printsupport/doc/snippets/widgetprinting.cpp b/src/printsupport/doc/snippets/widgetprinting.cpp
index 0204809988..3abef7a9a3 100644
--- a/src/printsupport/doc/snippets/widgetprinting.cpp
+++ b/src/printsupport/doc/snippets/widgetprinting.cpp
@@ -57,7 +57,7 @@ public:
private slots:
void print() {
QPrinter printer(QPrinter::HighResolution);
-
+
printer.setOutputFileName("test.pdf");
//! [0]
diff --git a/src/printsupport/doc/src/qtprintsupport-index.qdoc b/src/printsupport/doc/src/qtprintsupport-index.qdoc
index ea0d89aa34..dac915692e 100644
--- a/src/printsupport/doc/src/qtprintsupport-index.qdoc
+++ b/src/printsupport/doc/src/qtprintsupport-index.qdoc
@@ -40,12 +40,12 @@
generation facilities.
\tableofcontents
-
+
\section1 Classes Supporting Printing
The following classes support the selecting and setting up of printers and
printing output.
-
+
\annotatedlist printing
\section1 Paint Devices and Printing
diff --git a/src/printsupport/kernel/qcups.cpp b/src/printsupport/kernel/qcups.cpp
index 30de3d301c..d2deee1db3 100644
--- a/src/printsupport/kernel/qcups.cpp
+++ b/src/printsupport/kernel/qcups.cpp
@@ -52,6 +52,8 @@
QT_BEGIN_NAMESPACE
+extern double qt_multiplierForUnit(QPrinter::Unit unit, int resolution);
+
typedef int (*CupsGetDests)(cups_dest_t **dests);
typedef void (*CupsFreeDests)(int num_dests, cups_dest_t *dests);
typedef const char* (*CupsGetPPD)(const char *printer);
@@ -500,6 +502,25 @@ QList<QPrinter::PaperSize> QCUPSSupport::getCupsPrinterPaperSizes(int cupsPrinte
return result;
}
+QList<QPair<QString, QSizeF> > QCUPSSupport::getCupsPrinterPaperSizesWithNames(int cupsPrinterIndex)
+{
+ QList<QPair<QString, QSizeF> > result;
+ if (!QCUPSSupport::isAvailable() || cupsPrinterIndex < 0)
+ return result;
+ // Find paper sizes from CUPS.
+ QCUPSSupport cups;
+ cups.setCurrentPrinter(cupsPrinterIndex);
+ if (const ppd_option_t* size = cups.pageSizes()) {
+ for (int j = 0; j < size->num_choices; ++j) {
+ double multiplier = qt_multiplierForUnit(QPrinter::Millimeter, 0); // resolution is not needed here
+ QSize sz = cups.paperRect(size->choices[j].choice).size();
+ result.append(qMakePair(QString::fromUtf8(size->choices[j].text), QSizeF(sz.width() / multiplier, sz.height() / multiplier)));
+ }
+ }
+ return result;
+}
+
+
QT_END_NAMESPACE
#endif // QT_NO_CUPS
diff --git a/src/printsupport/kernel/qcups_p.h b/src/printsupport/kernel/qcups_p.h
index 67a8955d93..0828f582a3 100644
--- a/src/printsupport/kernel/qcups_p.h
+++ b/src/printsupport/kernel/qcups_p.h
@@ -121,6 +121,7 @@ public:
static QList<Printer> availableUnixPrinters();
static QList<QPrinter::PaperSize> getCupsPrinterPaperSizes(int cupsPrinterIndex);
+ static QList<QPair<QString, QSizeF> > getCupsPrinterPaperSizesWithNames(int cupsPrinterIndex);
private:
void collectMarkedOptions(QStringList& list, const ppd_group_t* group = 0) const;
diff --git a/src/printsupport/kernel/qpaintengine_alpha_p.h b/src/printsupport/kernel/qpaintengine_alpha_p.h
index 99b9b930e9..8a0781d0d3 100644
--- a/src/printsupport/kernel/qpaintengine_alpha_p.h
+++ b/src/printsupport/kernel/qpaintengine_alpha_p.h
@@ -53,6 +53,8 @@
// We mean it.
//
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_PRINTER
#include "private/qpaintengine_p.h"
#include <QtPrintSupport/qtprintsupportglobal.h>
diff --git a/src/printsupport/kernel/qplatformprintersupport.cpp b/src/printsupport/kernel/qplatformprintersupport.cpp
index f20ac5d177..4d80e55ab6 100644
--- a/src/printsupport/kernel/qplatformprintersupport.cpp
+++ b/src/printsupport/kernel/qplatformprintersupport.cpp
@@ -82,6 +82,11 @@ QList<QPrinter::PaperSize> QPlatformPrinterSupport::supportedPaperSizes(const QP
return QList<QPrinter::PaperSize>();
}
+QList<QPair<QString, QSizeF> > QPlatformPrinterSupport::supportedSizesWithNames(const QPrinterInfo &) const
+{
+ return QList<QPair<QString, QSizeF> >();
+}
+
QList<QPrinterInfo> QPlatformPrinterSupport::availablePrinters()
{
return m_printers;
diff --git a/src/printsupport/kernel/qplatformprintersupport.h b/src/printsupport/kernel/qplatformprintersupport.h
index 5d3c7d0aa6..c4ffcffd1e 100644
--- a/src/printsupport/kernel/qplatformprintersupport.h
+++ b/src/printsupport/kernel/qplatformprintersupport.h
@@ -55,8 +55,6 @@
#include <QtCore/qlist.h>
#include <QtCore/qhash.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#ifndef QT_NO_PRINTER
@@ -74,7 +72,7 @@ public:
virtual QPrintEngine *createNativePrintEngine(QPrinter::PrinterMode printerMode);
virtual QPaintEngine *createPaintEngine(QPrintEngine *, QPrinter::PrinterMode printerMode);
virtual QList<QPrinter::PaperSize> supportedPaperSizes(const QPrinterInfo &) const;
-
+ virtual QList<QPair<QString, QSizeF> > supportedSizesWithNames(const QPrinterInfo &printerInfo) const;
virtual QList<QPrinterInfo> availablePrinters();
virtual QPrinterInfo defaultPrinter();
virtual QPrinterInfo printerInfo(const QString &printerName);
@@ -98,6 +96,4 @@ protected:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMPRINTERSUPPORT_H
diff --git a/src/printsupport/kernel/qplatformprintplugin.h b/src/printsupport/kernel/qplatformprintplugin.h
index 67af44cd68..4a5a94616a 100644
--- a/src/printsupport/kernel/qplatformprintplugin.h
+++ b/src/printsupport/kernel/qplatformprintplugin.h
@@ -55,8 +55,6 @@
#include <QtCore/qfactoryinterface.h>
#include <QtPrintSupport/qtprintsupportglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -78,6 +76,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPLATFORMPRINTPLUGIN_H
diff --git a/src/printsupport/kernel/qprintengine.h b/src/printsupport/kernel/qprintengine.h
index 2abf3dda74..3993a22bef 100644
--- a/src/printsupport/kernel/qprintengine.h
+++ b/src/printsupport/kernel/qprintengine.h
@@ -45,8 +45,6 @@
#include <QtCore/qvariant.h>
#include <QtPrintSupport/qprinter.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -86,6 +84,7 @@ public:
PPK_PageMargins,
PPK_CopyCount,
PPK_SupportsMultipleCopies,
+ PPK_PaperName,
PPK_PaperSize = PPK_PageSize,
PPK_CustomBase = 0xff00
@@ -106,6 +105,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPRINTENGINE_H
diff --git a/src/printsupport/kernel/qprintengine_win.cpp b/src/printsupport/kernel/qprintengine_win.cpp
index 97453f2e0e..c798ac0c7f 100644
--- a/src/printsupport/kernel/qprintengine_win.cpp
+++ b/src/printsupport/kernel/qprintengine_win.cpp
@@ -167,6 +167,16 @@ static int mapPaperSourceDevmode(QPrinter::PaperSource s)
return sources[i].winSourceName ? sources[i].winSourceName : s;
}
+static inline uint qwcsnlen(const wchar_t *str, uint maxlen)
+{
+ uint length = 0;
+ if (str) {
+ while (length < maxlen && *str++)
+ length++;
+ }
+ return length;
+}
+
QWin32PrintEngine::QWin32PrintEngine(QPrinter::PrinterMode mode)
: QAlphaPaintEngine(*(new QWin32PrintEnginePrivate),
PaintEngineFeatures(PrimitiveTransform
@@ -1285,7 +1295,39 @@ void QWin32PrintEngine::setProperty(PrintEnginePropertyKey key, const QVariant &
d->has_custom_paper_size = (QPrinter::PaperSize(value.toInt()) == QPrinter::Custom);
d->doReinit();
break;
-
+ case PPK_PaperName:
+ {
+ if (!d->devMode)
+ break;
+ DWORD size = DeviceCapabilities(reinterpret_cast<const wchar_t*>(d->name.utf16()),
+ NULL, DC_PAPERNAMES, NULL, NULL);
+ if ((int)size > 0) {
+ wchar_t *paperNames = new wchar_t[size*64];
+ size = DeviceCapabilities(reinterpret_cast<const wchar_t*>(d->name.utf16()),
+ NULL, DC_PAPERNAMES, paperNames, NULL);
+ int paperPos = -1;
+ for (int i=0;i<(int)size;i++) {
+ wchar_t *copyOfPaper = paperNames + (i * 64);
+ if (value.toString() == QString::fromWCharArray(copyOfPaper, qwcsnlen(copyOfPaper, 64))) {
+ paperPos = i;
+ break;
+ }
+ }
+ delete [] paperNames;
+ size = DeviceCapabilities(reinterpret_cast<const wchar_t*>(d->name.utf16()),
+ NULL, DC_PAPERS, NULL, NULL);
+ if ((int)size > 0) {
+ wchar_t *papers = new wchar_t[size];
+ size = DeviceCapabilities(reinterpret_cast<const wchar_t*>(d->name.utf16()),
+ NULL, DC_PAPERS, papers, NULL);
+ d->has_custom_paper_size = false;
+ d->devMode->dmPaperSize = papers[paperPos];
+ d->doReinit();
+ delete [] papers;
+ }
+ }
+ }
+ break;
case PPK_PaperSource:
{
if (!d->devMode)
@@ -1479,7 +1521,40 @@ QVariant QWin32PrintEngine::property(PrintEnginePropertyKey key) const
value = QTransform(1/d->stretch_x, 0, 0, 1/d->stretch_y, 0, 0).mapRect(d->devPaperRect);
}
break;
+ case PPK_PaperName:
+ if (!d->devMode) {
+ value = QLatin1String("A4");
+ } else {
+ DWORD size = DeviceCapabilities(reinterpret_cast<const wchar_t*>(d->name.utf16()),
+ NULL, DC_PAPERS, NULL, NULL);
+ int paperSizePos = -1;
+ if ((int)size > 0) {
+ wchar_t *papers = new wchar_t[size];
+ size = DeviceCapabilities(reinterpret_cast<const wchar_t*>(d->name.utf16()),
+ NULL, DC_PAPERS, papers, NULL);
+ for (int i=0;i<(int)size;i++) {
+ if (papers[i] == d->devMode->dmPaperSize) {
+ paperSizePos = i;
+ break;
+ }
+ }
+ delete [] papers;
+ }
+ if (paperSizePos != -1) {
+ size = DeviceCapabilities(reinterpret_cast<const wchar_t*>(d->name.utf16()),
+ NULL, DC_PAPERNAMES, NULL, NULL);
+ if ((int)size > 0) {
+ wchar_t *papers = new wchar_t[size*64];
+ size = DeviceCapabilities(reinterpret_cast<const wchar_t*>(d->name.utf16()),
+ NULL, DC_PAPERNAMES, papers, NULL);
+ wchar_t *copyOfPaper = papers + (paperSizePos * 64);
+ value = QString::fromWCharArray(copyOfPaper, qwcsnlen(copyOfPaper, 64));
+ delete [] papers;
+ }
+ }
+ }
+ break;
case PPK_PaperSource:
if (!d->devMode) {
value = QPrinter::Auto;
@@ -1596,6 +1671,36 @@ QList<QPrinter::PaperSize> QWin32PrintEngine::supportedPaperSizes(const QPrinter
return returnList;
}
+QList<QPair<QString, QSizeF> > QWin32PrintEngine::supportedSizesWithNames(const QPrinterInfo &printerInfo)
+{
+ QList<QPair<QString, QSizeF> > paperSizes;
+ if (printerInfo.isNull())
+ return paperSizes;
+ DWORD size = DeviceCapabilities(reinterpret_cast<const wchar_t*>(printerInfo.printerName().utf16()),
+ NULL, DC_PAPERNAMES, NULL, NULL);
+ if ((int)size > 0) {
+ wchar_t *papers = new wchar_t[size*64];
+ size = DeviceCapabilities(reinterpret_cast<const wchar_t*>(printerInfo.printerName().utf16()),
+ NULL, DC_PAPERNAMES, papers, NULL);
+ DWORD size2 = DeviceCapabilities(reinterpret_cast<const wchar_t*>(printerInfo.printerName().utf16()),
+ NULL, DC_PAPERSIZE, NULL, NULL);
+ if ((int)size2 > 0) {
+ POINT *points = new POINT[size2*sizeof(POINT)];
+
+ size2 = DeviceCapabilities(reinterpret_cast<const wchar_t*>(printerInfo.printerName().utf16()),
+ NULL, DC_PAPERSIZE, (wchar_t *)points, NULL);
+ for (int i=0;i<(int)size;i++) {
+ wchar_t *paper = papers + (i * 64);
+ QString str = QString::fromWCharArray(paper, qwcsnlen(paper, 64));
+ paperSizes << qMakePair(str, QSizeF(points[i].x / 10, points[i].y / 10));
+ }
+ delete [] points;
+ }
+ delete [] papers;
+ }
+ return paperSizes;
+}
+
void QWin32PrintEngine::queryDefaultPrinter(QString &name, QString &program, QString &port)
{
/* Read the default printer name, driver and port with the intuitive function
diff --git a/src/printsupport/kernel/qprintengine_win_p.h b/src/printsupport/kernel/qprintengine_win_p.h
index 5197918710..93fe993088 100644
--- a/src/printsupport/kernel/qprintengine_win_p.h
+++ b/src/printsupport/kernel/qprintengine_win_p.h
@@ -53,6 +53,8 @@
// We mean it.
//
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_PRINTER
#include <QtGui/qpaintengine.h>
@@ -104,6 +106,7 @@ public:
void releaseDC(HDC) const;
static QList<QPrinter::PaperSize> supportedPaperSizes(const QPrinterInfo &printerInfo);
+ static QList<QPair<QString, QSizeF> > supportedSizesWithNames(const QPrinterInfo &printerInfo);
static void queryDefaultPrinter(QString &name, QString &program, QString &port);
private:
diff --git a/src/printsupport/kernel/qprinter.cpp b/src/printsupport/kernel/qprinter.cpp
index c1a2483f24..387101dc9b 100644
--- a/src/printsupport/kernel/qprinter.cpp
+++ b/src/printsupport/kernel/qprinter.cpp
@@ -1023,6 +1023,37 @@ QSizeF QPrinter::paperSize(Unit unit) const
}
/*!
+ \since 5.1
+
+ Sets the paper used by the printer to \a paperName.
+
+ \sa paperName()
+*/
+
+void QPrinter::setPaperName(const QString &paperName)
+{
+ Q_D(QPrinter);
+ if (d->paintEngine->type() != QPaintEngine::Pdf)
+ ABORT_IF_ACTIVE("QPrinter::setPaperName");
+ d->printEngine->setProperty(QPrintEngine::PPK_PaperName, paperName);
+ d->addToManualSetList(QPrintEngine::PPK_PaperName);
+}
+
+/*!
+ \since 5.1
+
+ Returns the paper name of the paper set on the printer.
+
+ The default value for this is driver-dependent.
+*/
+
+QString QPrinter::paperName() const
+{
+ Q_D(const QPrinter);
+ return d->printEngine->property(QPrintEngine::PPK_PaperName).toString();
+}
+
+/*!
Sets the page order to \a pageOrder.
The page order can be QPrinter::FirstPageFirst or
@@ -1959,6 +1990,8 @@ QPrinter::PrintRange QPrinter::printRange() const
\value PPK_PaperSources Specifies more than one QPrinter::PaperSource value.
+ \value PPK_PaperName A string specifying the name of the paper.
+
\value PPK_PaperSize Specifies a QPrinter::PaperSize value.
\value PPK_PrinterName A string specifying the name of the printer.
diff --git a/src/printsupport/kernel/qprinter.h b/src/printsupport/kernel/qprinter.h
index 23ccb0c2d0..2528157532 100644
--- a/src/printsupport/kernel/qprinter.h
+++ b/src/printsupport/kernel/qprinter.h
@@ -47,8 +47,6 @@
#include <QtGui/qpagedpaintdevice.h>
#include <QtPrintSupport/qtprintsupportglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -169,6 +167,9 @@ public:
void setPaperSize(const QSizeF &paperSize, Unit unit);
QSizeF paperSize(Unit unit) const;
+ void setPaperName(const QString &paperName);
+ QString paperName() const;
+
void setPageOrder(PageOrder);
PageOrder pageOrder() const;
@@ -267,6 +268,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPRINTER_H
diff --git a/src/printsupport/kernel/qprinterinfo.cpp b/src/printsupport/kernel/qprinterinfo.cpp
index 32ed4fa5af..f863b23e34 100644
--- a/src/printsupport/kernel/qprinterinfo.cpp
+++ b/src/printsupport/kernel/qprinterinfo.cpp
@@ -222,6 +222,25 @@ QList<QPrinter::PaperSize> QPrinterInfo::supportedPaperSizes() const
return d->paperSizes;
}
+/*!
+ Returns a list of all the paper names supported by the driver with the
+ corresponding size in millimeters.
+
+ Not all printer drivers support this query, so the list may be empty.
+
+ \since 5.1
+*/
+
+QList<QPair<QString, QSizeF> > QPrinterInfo::supportedSizesWithNames() const
+{
+ Q_D(const QPrinterInfo);
+ if (!isNull() && !d->hasPaperNames) {
+ d->paperNames = QPlatformPrinterSupportPlugin::get()->supportedSizesWithNames(*this);
+ d->hasPaperNames = true;
+ }
+ return d->paperNames;
+}
+
QList<QPrinterInfo> QPrinterInfo::availablePrinters()
{
QPlatformPrinterSupport *ps = QPlatformPrinterSupportPlugin::get();
diff --git a/src/printsupport/kernel/qprinterinfo.h b/src/printsupport/kernel/qprinterinfo.h
index 528423a635..0dc19c1da7 100644
--- a/src/printsupport/kernel/qprinterinfo.h
+++ b/src/printsupport/kernel/qprinterinfo.h
@@ -43,11 +43,9 @@
#define QPRINTERINFO_H
#include <QtCore/QList>
-
+#include <QtCore/QPair>
#include <QtPrintSupport/QPrinter>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -73,6 +71,7 @@ public:
bool isDefault() const;
QList<QPrinter::PaperSize> supportedPaperSizes() const;
+ QList<QPair<QString, QSizeF> > supportedSizesWithNames() const;
static QList<QPrinterInfo> availablePrinters();
static QPrinterInfo defaultPrinter();
@@ -91,6 +90,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPRINTERINFO_H
diff --git a/src/printsupport/kernel/qprinterinfo_p.h b/src/printsupport/kernel/qprinterinfo_p.h
index 97f4fd8a56..d4bb08f1f5 100644
--- a/src/printsupport/kernel/qprinterinfo_p.h
+++ b/src/printsupport/kernel/qprinterinfo_p.h
@@ -58,6 +58,7 @@
#ifndef QT_NO_PRINTER
#include "QtCore/qlist.h"
+#include "QtCore/qpair.h"
QT_BEGIN_NAMESPACE
@@ -65,7 +66,8 @@ class QPrinterInfoPrivate
{
public:
QPrinterInfoPrivate(const QString& name = QString()) :
- name(name), isDefault(false), index(-1), hasPaperSizes(false)
+ name(name), isDefault(false), index(-1), hasPaperSizes(false),
+ hasPaperNames(false)
{}
~QPrinterInfoPrivate()
{}
@@ -81,6 +83,8 @@ public:
mutable bool hasPaperSizes;
mutable QList<QPrinter::PaperSize> paperSizes;
+ mutable bool hasPaperNames;
+ mutable QList<QPair<QString, QSizeF> > paperNames;
};
diff --git a/src/printsupport/kernel/qtprintsupportglobal.h b/src/printsupport/kernel/qtprintsupportglobal.h
index 1927252433..0fdb306e8d 100644
--- a/src/printsupport/kernel/qtprintsupportglobal.h
+++ b/src/printsupport/kernel/qtprintsupportglobal.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#ifndef QT_STATIC
@@ -60,6 +58,4 @@ QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTPRINTSUPPORTGLOBAL_H
diff --git a/src/printsupport/widgets/qprintpreviewwidget.h b/src/printsupport/widgets/qprintpreviewwidget.h
index b48af10ae0..85ff77d975 100644
--- a/src/printsupport/widgets/qprintpreviewwidget.h
+++ b/src/printsupport/widgets/qprintpreviewwidget.h
@@ -47,8 +47,6 @@
#ifndef QT_NO_PRINTPREVIEWWIDGET
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -116,7 +114,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_PRINTPREVIEWWIDGET
#endif // QPRINTPREVIEWWIDGET_H
diff --git a/src/sql/doc/snippets/code/doc_src_sql-driver.cpp b/src/sql/doc/snippets/code/doc_src_sql-driver.cpp
index 48eb324cb8..695e7cdce8 100644
--- a/src/sql/doc/snippets/code/doc_src_sql-driver.cpp
+++ b/src/sql/doc/snippets/code/doc_src_sql-driver.cpp
@@ -62,7 +62,7 @@ db.setDatabaseName("C:\\test.gdb");
//! [25]
-// connect to database using the Latin-1 character set
+// connect to database using the Latin-1 character set
db.setConnectOptions("ISC_DPB_LC_CTYPE=Latin1");
db.open();
//! [25]
diff --git a/src/sql/doc/src/qsqldatatype-table.qdoc b/src/sql/doc/src/qsqldatatype-table.qdoc
index b278e045bb..8480b5d412 100644
--- a/src/sql/doc/src/qsqldatatype-table.qdoc
+++ b/src/sql/doc/src/qsqldatatype-table.qdoc
@@ -29,7 +29,7 @@
\page sql-types.html
\title Data Types for Qt-supported Database Systems
\brief Recommended data types for database systems
-
+
\ingroup qt-sql
\section1 Recommended Data Types for Qt-Supported Database Systems
diff --git a/src/sql/doc/src/sql-driver.qdoc b/src/sql/doc/src/sql-driver.qdoc
index 28db62537f..3de898c344 100644
--- a/src/sql/doc/src/sql-driver.qdoc
+++ b/src/sql/doc/src/sql-driver.qdoc
@@ -212,7 +212,7 @@
\li Open the DOS prompt, go to \c{C:\MySQL\MySQL51\lib\opt}, and run
the following commands:
- \list
+ \list
\li \c{reimp -d libmysql.lib}
\li \c{dlltool -k -d libmysql.def -l libmysql.a}
\endlist
@@ -227,7 +227,7 @@
\li Open the DOS prompt, go to
\c{C:\Qt\4.6.2\src\plugins\sqldrivers\mysql} and run the
- following command:
+ following command:
\list
\li \c{qmake "INCLUDEPATH+=C:/MySQL/MySQL51/include" "LIBS+=-L. mysql" mysql.pro}
\endlist
diff --git a/src/sql/doc/src/sql-programming.qdoc b/src/sql/doc/src/sql-programming.qdoc
index d4089c8ab2..9b5e9318e0 100644
--- a/src/sql/doc/src/sql-programming.qdoc
+++ b/src/sql/doc/src/sql-programming.qdoc
@@ -64,7 +64,7 @@
\li \l{Using the SQL Model Classes}
\li \l{Presenting Data in a Table View}
\li \l{Creating Data-Aware Forms}
- \endlist
+ \endlist
\section1 Database Classes
@@ -142,7 +142,7 @@
\l{QSqlDatabase::addDatabase()} {addDatabase()} specifies the type
of database driver to use for the connection. The set of database
drivers included with Qt are shown in the table of \l{SQL Database
- Drivers#Supported Databases} {supported database drivers}.
+ Drivers#Supported Databases} {supported database drivers}.
The connection in the snippet will be the \e{default} connection,
because we don't pass the second argument to
@@ -176,11 +176,11 @@
\page sql-sqlstatements.html
\title Executing SQL Statements
\ingroup qt-sql
-
+
\previouspage Connecting to Databases
\contentspage SQL Programming
\nextpage Using the SQL Model Classes
-
+
The QSqlQuery class provides an interface for executing SQL
statements and navigating through the result set of a query.
@@ -328,7 +328,7 @@
\page sql-model.html
\title Using the SQL Model Classes
\ingroup qt-sql
-
+
\previouspage Executing SQL Statements
\contentspage SQL Programming
\nextpage Presenting Data in a Table View
@@ -475,7 +475,7 @@
\page sql-presenting.html
\title Presenting Data in a Table View
\ingroup qt-sql
-
+
\previouspage Using the SQL Model Classes
\contentspage SQL Programming
\nextpage Creating Data-Aware Forms
@@ -580,7 +580,7 @@
\page sql-forms.html
\title Creating Data-Aware Forms
\ingroup qt-sql
-
+
\previouspage Presenting Data in a Table View
\contentspage SQL Programming
diff --git a/src/sql/drivers/db2/qsql_db2.cpp b/src/sql/drivers/db2/qsql_db2.cpp
index 9406861d4c..e58710e0f5 100644
--- a/src/sql/drivers/db2/qsql_db2.cpp
+++ b/src/sql/drivers/db2/qsql_db2.cpp
@@ -39,7 +39,8 @@
**
****************************************************************************/
-#include "qsql_db2.h"
+#include "qsql_db2_p.h"
+#include <QtSql/private/qsqldriver_p.h>
#include <qcoreapplication.h>
#include <qdatetime.h>
#include <qsqlfield.h>
@@ -70,10 +71,10 @@ QT_BEGIN_NAMESPACE
static const int COLNAMESIZE = 255;
static const SQLSMALLINT qParamType[4] = { SQL_PARAM_INPUT, SQL_PARAM_INPUT, SQL_PARAM_OUTPUT, SQL_PARAM_INPUT_OUTPUT };
-class QDB2DriverPrivate
+class QDB2DriverPrivate : public QSqlDriverPrivate
{
public:
- QDB2DriverPrivate(): hEnv(0), hDbc(0) {}
+ QDB2DriverPrivate() : QSqlDriverPrivate(), hEnv(0), hDbc(0) { dbmsType = DB2; }
SQLHANDLE hEnv;
SQLHANDLE hDbc;
QString user;
@@ -1131,15 +1132,14 @@ void QDB2Result::detachFromResultSet()
/************************************/
QDB2Driver::QDB2Driver(QObject* parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QDB2DriverPrivate, parent)
{
- d = new QDB2DriverPrivate;
}
QDB2Driver::QDB2Driver(Qt::HANDLE env, Qt::HANDLE con, QObject* parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QDB2DriverPrivate, parent)
{
- d = new QDB2DriverPrivate;
+ Q_D(QDB2Driver);
d->hEnv = (SQLHANDLE)env;
d->hDbc = (SQLHANDLE)con;
if (env && con) {
@@ -1151,12 +1151,12 @@ QDB2Driver::QDB2Driver(Qt::HANDLE env, Qt::HANDLE con, QObject* parent)
QDB2Driver::~QDB2Driver()
{
close();
- delete d;
}
bool QDB2Driver::open(const QString& db, const QString& user, const QString& password, const QString& host, int port,
const QString& connOpts)
{
+ Q_D(QDB2Driver);
if (isOpen())
close();
SQLRETURN r;
@@ -1259,6 +1259,7 @@ bool QDB2Driver::open(const QString& db, const QString& user, const QString& pas
void QDB2Driver::close()
{
+ Q_D(QDB2Driver);
SQLRETURN r;
if (d->hDbc) {
// Open statements/descriptors handles are automatically cleaned up by SQLDisconnect
@@ -1285,11 +1286,13 @@ void QDB2Driver::close()
QSqlResult *QDB2Driver::createResult() const
{
+ Q_D(const QDB2Driver);
return new QDB2Result(this, d);
}
QSqlRecord QDB2Driver::record(const QString& tableName) const
{
+ Q_D(const QDB2Driver);
QSqlRecord fil;
if (!isOpen())
return fil;
@@ -1363,6 +1366,7 @@ QSqlRecord QDB2Driver::record(const QString& tableName) const
QStringList QDB2Driver::tables(QSql::TableType type) const
{
+ Q_D(const QDB2Driver);
QStringList tl;
if (!isOpen())
return tl;
@@ -1434,6 +1438,7 @@ QStringList QDB2Driver::tables(QSql::TableType type) const
QSqlIndex QDB2Driver::primaryIndex(const QString& tablename) const
{
+ Q_D(const QDB2Driver);
QSqlIndex index(tablename);
if (!isOpen())
return index;
@@ -1535,6 +1540,7 @@ bool QDB2Driver::beginTransaction()
bool QDB2Driver::commitTransaction()
{
+ Q_D(QDB2Driver);
if (!isOpen()) {
qWarning("QDB2Driver::commitTransaction: Database not open");
return false;
@@ -1552,6 +1558,7 @@ bool QDB2Driver::commitTransaction()
bool QDB2Driver::rollbackTransaction()
{
+ Q_D(QDB2Driver);
if (!isOpen()) {
qWarning("QDB2Driver::rollbackTransaction: Database not open");
return false;
@@ -1569,6 +1576,7 @@ bool QDB2Driver::rollbackTransaction()
bool QDB2Driver::setAutoCommit(bool autoCommit)
{
+ Q_D(QDB2Driver);
SQLUINTEGER ac = autoCommit ? SQL_AUTOCOMMIT_ON : SQL_AUTOCOMMIT_OFF;
SQLRETURN r = SQLSetConnectAttr(d->hDbc,
SQL_ATTR_AUTOCOMMIT,
@@ -1627,6 +1635,7 @@ QString QDB2Driver::formatValue(const QSqlField &field, bool trimStrings) const
QVariant QDB2Driver::handle() const
{
+ Q_D(const QDB2Driver);
return QVariant(qRegisterMetaType<SQLHANDLE>("SQLHANDLE"), &d->hDbc);
}
diff --git a/src/sql/drivers/db2/qsql_db2.pri b/src/sql/drivers/db2/qsql_db2.pri
index 963732aaee..c9e65e2c2e 100644
--- a/src/sql/drivers/db2/qsql_db2.pri
+++ b/src/sql/drivers/db2/qsql_db2.pri
@@ -1,4 +1,4 @@
-HEADERS += $$PWD/qsql_db2.h
+HEADERS += $$PWD/qsql_db2_p.h
SOURCES += $$PWD/qsql_db2.cpp
unix {
diff --git a/src/sql/drivers/db2/qsql_db2.h b/src/sql/drivers/db2/qsql_db2_p.h
index 4e25c317eb..89b07c9c83 100644
--- a/src/sql/drivers/db2/qsql_db2.h
+++ b/src/sql/drivers/db2/qsql_db2_p.h
@@ -42,6 +42,19 @@
#ifndef QSQL_DB2_H
#define QSQL_DB2_H
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists purely as an
+// implementation detail. This header file may change from version to
+// version without notice, or even be removed.
+//
+// We mean it.
+//
+
+#include <QtCore/qglobal.h>
+
#ifdef QT_PLUGIN
#define Q_EXPORT_SQLDRIVER_DB2
#else
@@ -51,15 +64,8 @@
#include <QtSql/qsqlresult.h>
#include <QtSql/qsqldriver.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
-#if 0
-#pragma qt_no_master_include
-#pragma qt_sync_stop_processing
-#endif
-
class QDB2Driver;
class QDB2DriverPrivate;
class QDB2ResultPrivate;
@@ -95,6 +101,7 @@ private:
class Q_EXPORT_SQLDRIVER_DB2 QDB2Driver : public QSqlDriver
{
+ Q_DECLARE_PRIVATE(QDB2Driver)
Q_OBJECT
public:
explicit QDB2Driver(QObject* parent = 0);
@@ -121,11 +128,8 @@ public:
private:
bool setAutoCommit(bool autoCommit);
- QDB2DriverPrivate* d;
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQL_DB2_H
diff --git a/src/sql/drivers/ibase/qsql_ibase.cpp b/src/sql/drivers/ibase/qsql_ibase.cpp
index 5fd07318ec..bd97db189c 100644
--- a/src/sql/drivers/ibase/qsql_ibase.cpp
+++ b/src/sql/drivers/ibase/qsql_ibase.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include "qsql_ibase.h"
+#include "qsql_ibase_p.h"
#include <qcoreapplication.h>
#include <qdatetime.h>
#include <qvariant.h>
@@ -47,6 +47,8 @@
#include <qsqlfield.h>
#include <qsqlindex.h>
#include <qsqlquery.h>
+#include <QtSql/private/qsqlcachedresult_p.h>
+#include <QtSql/private/qsqldriver_p.h>
#include <qlist.h>
#include <qvector.h>
#include <qtextcodec.h>
@@ -308,13 +310,15 @@ struct QIBaseEventBuffer {
QIBaseSubscriptionState subscriptionState;
};
-class QIBaseDriverPrivate
+class QIBaseDriverPrivate : public QSqlDriverPrivate
{
+ Q_DECLARE_PUBLIC(QIBaseDriver)
public:
- QIBaseDriverPrivate(QIBaseDriver *d) : q(d), ibase(0), trans(0), tc(0) {}
+ QIBaseDriverPrivate() : QSqlDriverPrivate(), ibase(0), trans(0), tc(0) { dbmsType = Interbase; }
bool isError(const char *msg, QSqlError::ErrorType typ = QSqlError::UnknownError)
{
+ Q_Q(QIBaseDriver);
QString imsg;
ISC_LONG sqlcode;
if (!getIBaseError(imsg, status, sqlcode, tc))
@@ -326,7 +330,6 @@ public:
}
public:
- QIBaseDriver* q;
isc_db_handle ibase;
isc_tr_handle trans;
QTextCodec *tc;
@@ -346,6 +349,31 @@ static void qFreeEventBuffer(QIBaseEventBuffer* eBuffer)
delete eBuffer;
}
+class QIBaseResultPrivate;
+
+class QIBaseResult : public QSqlCachedResult
+{
+ friend class QIBaseResultPrivate;
+
+public:
+ explicit QIBaseResult(const QIBaseDriver* db);
+ virtual ~QIBaseResult();
+
+ bool prepare(const QString& query);
+ bool exec();
+ QVariant handle() const;
+
+protected:
+ bool gotoNext(QSqlCachedResult::ValueCache& row, int rowIdx);
+ bool reset (const QString& query);
+ int size();
+ int numRowsAffected();
+ QSqlRecord record() const;
+
+private:
+ QIBaseResultPrivate* d;
+};
+
class QIBaseResultPrivate
{
public:
@@ -391,9 +419,9 @@ public:
QIBaseResultPrivate::QIBaseResultPrivate(QIBaseResult *d, const QIBaseDriver *ddb):
- q(d), db(ddb), trans(0), stmt(0), ibase(ddb->d->ibase), sqlda(0), inda(0), queryType(-1), tc(ddb->d->tc)
+ q(d), db(ddb), trans(0), stmt(0), ibase(ddb->d_func()->ibase), sqlda(0), inda(0), queryType(-1), tc(ddb->d_func()->tc)
{
- localTransaction = (ddb->d->ibase == 0);
+ localTransaction = (ddb->d_func()->ibase == 0);
}
void QIBaseResultPrivate::cleanup()
@@ -834,9 +862,9 @@ bool QIBaseResultPrivate::transaction()
{
if (trans)
return true;
- if (db->d->trans) {
+ if (db->d_func()->trans) {
localTransaction = false;
- trans = db->d->trans;
+ trans = db->d_func()->trans;
return true;
}
localTransaction = true;
@@ -1369,15 +1397,14 @@ QVariant QIBaseResult::handle() const
/*********************************/
QIBaseDriver::QIBaseDriver(QObject * parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QIBaseDriverPrivate, parent)
{
- d = new QIBaseDriverPrivate(this);
}
QIBaseDriver::QIBaseDriver(isc_db_handle connection, QObject *parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QIBaseDriverPrivate, parent)
{
- d = new QIBaseDriverPrivate(this);
+ Q_D(QIBaseDriver);
d->ibase = connection;
setOpen(true);
setOpenError(false);
@@ -1385,7 +1412,6 @@ QIBaseDriver::QIBaseDriver(isc_db_handle connection, QObject *parent)
QIBaseDriver::~QIBaseDriver()
{
- delete d;
}
bool QIBaseDriver::hasFeature(DriverFeature f) const
@@ -1418,6 +1444,7 @@ bool QIBaseDriver::open(const QString & db,
int /*port*/,
const QString & connOpts)
{
+ Q_D(QIBaseDriver);
if (isOpen())
close();
@@ -1500,6 +1527,7 @@ bool QIBaseDriver::open(const QString & db,
void QIBaseDriver::close()
{
+ Q_D(QIBaseDriver);
if (isOpen()) {
if (d->eventBuffers.size()) {
@@ -1536,6 +1564,7 @@ QSqlResult *QIBaseDriver::createResult() const
bool QIBaseDriver::beginTransaction()
{
+ Q_D(QIBaseDriver);
if (!isOpen() || isOpenError())
return false;
if (d->trans)
@@ -1548,6 +1577,7 @@ bool QIBaseDriver::beginTransaction()
bool QIBaseDriver::commitTransaction()
{
+ Q_D(QIBaseDriver);
if (!isOpen() || isOpenError())
return false;
if (!d->trans)
@@ -1561,6 +1591,7 @@ bool QIBaseDriver::commitTransaction()
bool QIBaseDriver::rollbackTransaction()
{
+ Q_D(QIBaseDriver);
if (!isOpen() || isOpenError())
return false;
if (!d->trans)
@@ -1723,6 +1754,7 @@ QString QIBaseDriver::formatValue(const QSqlField &field, bool trimStrings) cons
QVariant QIBaseDriver::handle() const
{
+ Q_D(const QIBaseDriver);
return QVariant(qRegisterMetaType<isc_db_handle>("isc_db_handle"), &d->ibase);
}
@@ -1751,6 +1783,7 @@ static isc_callback qEventCallback(char *result, short length, char *updated)
bool QIBaseDriver::subscribeToNotification(const QString &name)
{
+ Q_D(QIBaseDriver);
if (!isOpen()) {
qWarning("QIBaseDriver::subscribeFromNotificationImplementation: database not open.");
return false;
@@ -1800,6 +1833,7 @@ bool QIBaseDriver::subscribeToNotification(const QString &name)
bool QIBaseDriver::unsubscribeFromNotification(const QString &name)
{
+ Q_D(QIBaseDriver);
if (!isOpen()) {
qWarning("QIBaseDriver::unsubscribeFromNotificationImplementation: database not open.");
return false;
@@ -1829,11 +1863,13 @@ bool QIBaseDriver::unsubscribeFromNotification(const QString &name)
QStringList QIBaseDriver::subscribedToNotifications() const
{
+ Q_D(const QIBaseDriver);
return QStringList(d->eventBuffers.keys());
}
void QIBaseDriver::qHandleEventNotification(void *updatedResultBuffer)
{
+ Q_D(QIBaseDriver);
QMap<QString, QIBaseEventBuffer *>::const_iterator i;
for (i = d->eventBuffers.constBegin(); i != d->eventBuffers.constEnd(); ++i) {
QIBaseEventBuffer* eBuffer = i.value();
diff --git a/src/sql/drivers/ibase/qsql_ibase.pri b/src/sql/drivers/ibase/qsql_ibase.pri
index 26017e8727..ef3b68d34e 100644
--- a/src/sql/drivers/ibase/qsql_ibase.pri
+++ b/src/sql/drivers/ibase/qsql_ibase.pri
@@ -1,4 +1,4 @@
-HEADERS += $$PWD/qsql_ibase.h
+HEADERS += $$PWD/qsql_ibase_p.h
SOURCES += $$PWD/qsql_ibase.cpp
unix {
diff --git a/src/sql/drivers/ibase/qsql_ibase.h b/src/sql/drivers/ibase/qsql_ibase_p.h
index 2ce20966c6..ab9edfd1a5 100644
--- a/src/sql/drivers/ibase/qsql_ibase.h
+++ b/src/sql/drivers/ibase/qsql_ibase_p.h
@@ -42,52 +42,31 @@
#ifndef QSQL_IBASE_H
#define QSQL_IBASE_H
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists purely as an
+// implementation detail. This header file may change from version to
+// version without notice, or even be removed.
+//
+// We mean it.
+//
+
#include <QtSql/qsqlresult.h>
#include <QtSql/qsqldriver.h>
-#include <QtSql/private/qsqlcachedresult_p.h>
#include <ibase.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
-#if 0
-#pragma qt_no_master_include
-#pragma qt_sync_stop_processing
-#endif
-
class QIBaseDriverPrivate;
-class QIBaseResultPrivate;
class QIBaseDriver;
-class QIBaseResult : public QSqlCachedResult
-{
- friend class QIBaseResultPrivate;
-
-public:
- explicit QIBaseResult(const QIBaseDriver* db);
- virtual ~QIBaseResult();
-
- bool prepare(const QString& query);
- bool exec();
- QVariant handle() const;
-
-protected:
- bool gotoNext(QSqlCachedResult::ValueCache& row, int rowIdx);
- bool reset (const QString& query);
- int size();
- int numRowsAffected();
- QSqlRecord record() const;
-
-private:
- QIBaseResultPrivate* d;
-};
-
class QIBaseDriver : public QSqlDriver
{
- Q_OBJECT
- friend class QIBaseDriverPrivate;
friend class QIBaseResultPrivate;
+ Q_DECLARE_PRIVATE(QIBaseDriver)
+ Q_OBJECT
public:
explicit QIBaseDriver(QObject *parent = 0);
explicit QIBaseDriver(isc_db_handle connection, QObject *parent = 0);
@@ -125,12 +104,8 @@ public:
private Q_SLOTS:
void qHandleEventNotification(void* updatedResultBuffer);
-
-private:
- QIBaseDriverPrivate* d;
};
QT_END_NAMESPACE
-QT_END_HEADER
#endif // QSQL_IBASE_H
diff --git a/src/sql/drivers/mysql/qsql_mysql.cpp b/src/sql/drivers/mysql/qsql_mysql.cpp
index b4aa5cd4cc..0e20cf539e 100644
--- a/src/sql/drivers/mysql/qsql_mysql.cpp
+++ b/src/sql/drivers/mysql/qsql_mysql.cpp
@@ -39,8 +39,9 @@
**
****************************************************************************/
-#include "qsql_mysql.h"
+#include "qsql_mysql_p.h"
+#include <QtSql/private/qsqldriver_p.h>
#include <qcoreapplication.h>
#include <qvariant.h>
#include <qdatetime.h>
@@ -76,16 +77,16 @@ Q_DECLARE_METATYPE(MYSQL_STMT*)
QT_BEGIN_NAMESPACE
-class QMYSQLDriverPrivate
+class QMYSQLDriverPrivate : public QSqlDriverPrivate
{
public:
- QMYSQLDriverPrivate() : mysql(0),
+ QMYSQLDriverPrivate() : QSqlDriverPrivate(), mysql(0),
#ifndef QT_NO_TEXTCODEC
tc(QTextCodec::codecForLocale()),
#else
tc(0),
#endif
- preparedQuerysEnabled(false) {}
+ preparedQuerysEnabled(false) { dbmsType = MySqlServer; }
MYSQL *mysql;
QTextCodec *tc;
@@ -166,7 +167,7 @@ class QMYSQLResultPrivate : public QObject
{
Q_OBJECT
public:
- QMYSQLResultPrivate(const QMYSQLDriver* dp, const QMYSQLResult* d) : driver(dp), result(0), q(d),
+ QMYSQLResultPrivate(const QMYSQLDriver* dp, const QMYSQLResult* d) : driver(dp), result(0), q(d),
rowsAffected(0), hasBlobs(false)
#if MYSQL_VERSION_ID >= 40108
, stmt(0), meta(0), inBinds(0), outBinds(0)
@@ -434,8 +435,8 @@ void QMYSQLResult::cleanup()
// must iterate trough leftover result sets from multi-selects or stored procedures
// if this isn't done subsequent queries will fail with "Commands out of sync"
#if MYSQL_VERSION_ID >= 40100
- while (d->driver && d->driver->d->mysql && mysql_next_result(d->driver->d->mysql) == 0) {
- MYSQL_RES *res = mysql_store_result(d->driver->d->mysql);
+ while (d->driver && d->driver->d_func()->mysql && mysql_next_result(d->driver->d_func()->mysql) == 0) {
+ MYSQL_RES *res = mysql_store_result(d->driver->d_func()->mysql);
if (res)
mysql_free_result(res);
}
@@ -605,7 +606,7 @@ QVariant QMYSQLResult::data(int field)
return QVariant(f.type);
if (f.type != QVariant::ByteArray)
- val = toUnicode(d->driver->d->tc, f.outField, f.bufLength);
+ val = toUnicode(d->driver->d_func()->tc, f.outField, f.bufLength);
} else {
if (d->row[field] == NULL) {
// NULL value
@@ -613,7 +614,7 @@ QVariant QMYSQLResult::data(int field)
}
fieldLength = mysql_fetch_lengths(d->result)[field];
if (f.type != QVariant::ByteArray)
- val = toUnicode(d->driver->d->tc, d->row[field], fieldLength);
+ val = toUnicode(d->driver->d_func()->tc, d->row[field], fieldLength);
}
switch(f.type) {
@@ -692,22 +693,22 @@ bool QMYSQLResult::reset (const QString& query)
cleanup();
- const QByteArray encQuery(fromUnicode(d->driver->d->tc, query));
- if (mysql_real_query(d->driver->d->mysql, encQuery.data(), encQuery.length())) {
+ const QByteArray encQuery(fromUnicode(d->driver->d_func()->tc, query));
+ if (mysql_real_query(d->driver->d_func()->mysql, encQuery.data(), encQuery.length())) {
setLastError(qMakeError(QCoreApplication::translate("QMYSQLResult", "Unable to execute query"),
- QSqlError::StatementError, d->driver->d));
+ QSqlError::StatementError, d->driver->d_func()));
return false;
}
- d->result = mysql_store_result(d->driver->d->mysql);
- if (!d->result && mysql_field_count(d->driver->d->mysql) > 0) {
+ d->result = mysql_store_result(d->driver->d_func()->mysql);
+ if (!d->result && mysql_field_count(d->driver->d_func()->mysql) > 0) {
setLastError(qMakeError(QCoreApplication::translate("QMYSQLResult", "Unable to store result"),
- QSqlError::StatementError, d->driver->d));
+ QSqlError::StatementError, d->driver->d_func()));
return false;
}
- int numFields = mysql_field_count(d->driver->d->mysql);
+ int numFields = mysql_field_count(d->driver->d_func()->mysql);
setSelect(numFields != 0);
d->fields.resize(numFields);
- d->rowsAffected = mysql_affected_rows(d->driver->d->mysql);
+ d->rowsAffected = mysql_affected_rows(d->driver->d_func()->mysql);
if (isSelect()) {
for(int i = 0; i < numFields; i++) {
@@ -752,7 +753,7 @@ QVariant QMYSQLResult::lastInsertId() const
return QVariant(id);
#endif
} else {
- quint64 id = mysql_insert_id(d->driver->d->mysql);
+ quint64 id = mysql_insert_id(d->driver->d_func()->mysql);
if (id)
return QVariant(id);
}
@@ -772,11 +773,11 @@ QSqlRecord QMYSQLResult::record() const
res = d->result;
#endif
- if (!mysql_errno(d->driver->d->mysql)) {
+ if (!mysql_errno(d->driver->d_func()->mysql)) {
mysql_field_seek(res, 0);
MYSQL_FIELD* field = mysql_fetch_field(res);
while(field) {
- info.append(qToField(field, d->driver->d->tc));
+ info.append(qToField(field, d->driver->d_func()->tc));
field = mysql_fetch_field(res);
}
}
@@ -788,7 +789,7 @@ bool QMYSQLResult::nextResult()
{
if(!d->driver)
return false;
-#if MYSQL_VERSION_ID >= 40100
+#if MYSQL_VERSION_ID >= 40100
setAt(-1);
setActive(false);
@@ -796,31 +797,31 @@ bool QMYSQLResult::nextResult()
mysql_free_result(d->result);
d->result = 0;
setSelect(false);
-
+
for (int i = 0; i < d->fields.count(); ++i)
delete[] d->fields[i].outField;
d->fields.clear();
- int status = mysql_next_result(d->driver->d->mysql);
+ int status = mysql_next_result(d->driver->d_func()->mysql);
if (status > 0) {
setLastError(qMakeError(QCoreApplication::translate("QMYSQLResult", "Unable to execute next query"),
- QSqlError::StatementError, d->driver->d));
+ QSqlError::StatementError, d->driver->d_func()));
return false;
} else if (status == -1) {
return false; // No more result sets
}
- d->result = mysql_store_result(d->driver->d->mysql);
- int numFields = mysql_field_count(d->driver->d->mysql);
+ d->result = mysql_store_result(d->driver->d_func()->mysql);
+ int numFields = mysql_field_count(d->driver->d_func()->mysql);
if (!d->result && numFields > 0) {
setLastError(qMakeError(QCoreApplication::translate("QMYSQLResult", "Unable to store next result"),
- QSqlError::StatementError, d->driver->d));
+ QSqlError::StatementError, d->driver->d_func()));
return false;
}
setSelect(numFields > 0);
d->fields.resize(numFields);
- d->rowsAffected = mysql_affected_rows(d->driver->d->mysql);
+ d->rowsAffected = mysql_affected_rows(d->driver->d_func()->mysql);
if (isSelect()) {
for (int i = 0; i < numFields; i++) {
@@ -873,7 +874,7 @@ bool QMYSQLResult::prepare(const QString& query)
return false;
#if MYSQL_VERSION_ID >= 40108
cleanup();
- if (!d->driver->d->preparedQuerysEnabled)
+ if (!d->driver->d_func()->preparedQuerysEnabled)
return QSqlResult::prepare(query);
int r;
@@ -882,14 +883,14 @@ bool QMYSQLResult::prepare(const QString& query)
return false;
if (!d->stmt)
- d->stmt = mysql_stmt_init(d->driver->d->mysql);
+ d->stmt = mysql_stmt_init(d->driver->d_func()->mysql);
if (!d->stmt) {
setLastError(qMakeError(QCoreApplication::translate("QMYSQLResult", "Unable to prepare statement"),
- QSqlError::StatementError, d->driver->d));
+ QSqlError::StatementError, d->driver->d_func()));
return false;
}
- const QByteArray encQuery(fromUnicode(d->driver->d->tc, query));
+ const QByteArray encQuery(fromUnicode(d->driver->d_func()->tc, query));
r = mysql_stmt_prepare(d->stmt, encQuery.constData(), encQuery.length());
if (r != 0) {
setLastError(qMakeStmtError(QCoreApplication::translate("QMYSQLResult",
@@ -1009,7 +1010,7 @@ bool QMYSQLResult::exec()
break;
case QVariant::String:
default: {
- QByteArray ba = fromUnicode(d->driver->d->tc, val.toString());
+ QByteArray ba = fromUnicode(d->driver->d_func()->tc, val.toString());
stringVector.append(ba);
currBind->buffer_type = MYSQL_TYPE_STRING;
currBind->buffer = const_cast<char *>(ba.constData());
@@ -1114,7 +1115,7 @@ static void qLibraryEnd()
}
QMYSQLDriver::QMYSQLDriver(QObject * parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QMYSQLDriverPrivate, parent)
{
init();
qLibraryInit();
@@ -1126,8 +1127,9 @@ QMYSQLDriver::QMYSQLDriver(QObject * parent)
*/
QMYSQLDriver::QMYSQLDriver(MYSQL * con, QObject * parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QMYSQLDriverPrivate, parent)
{
+ Q_D(QMYSQLDriver);
init();
if (con) {
d->mysql = (MYSQL *) con;
@@ -1145,7 +1147,7 @@ QMYSQLDriver::QMYSQLDriver(MYSQL * con, QObject * parent)
void QMYSQLDriver::init()
{
- d = new QMYSQLDriverPrivate();
+ Q_D(QMYSQLDriver);
d->mysql = 0;
qMySqlConnectionCount++;
}
@@ -1155,11 +1157,11 @@ QMYSQLDriver::~QMYSQLDriver()
qMySqlConnectionCount--;
if (qMySqlConnectionCount == 0 && !qMySqlInitHandledByUser)
qLibraryEnd();
- delete d;
}
bool QMYSQLDriver::hasFeature(DriverFeature f) const
{
+ Q_D(const QMYSQLDriver);
switch (f) {
case Transactions:
// CLIENT_TRANSACTION should be defined in all recent mysql client libs > 3.23.34
@@ -1227,6 +1229,7 @@ bool QMYSQLDriver::open(const QString& db,
int port,
const QString& connOpts)
{
+ Q_D(QMYSQLDriver);
if (isOpen())
close();
@@ -1328,6 +1331,7 @@ bool QMYSQLDriver::open(const QString& db,
void QMYSQLDriver::close()
{
+ Q_D(QMYSQLDriver);
if (isOpen()) {
#ifndef QT_NO_THREAD
mysql_thread_end();
@@ -1346,6 +1350,7 @@ QSqlResult *QMYSQLDriver::createResult() const
QStringList QMYSQLDriver::tables(QSql::TableType type) const
{
+ Q_D(const QMYSQLDriver);
QStringList tl;
#if MYSQL_VERSION_ID >= 40100
if( mysql_get_server_version(d->mysql) < 50000)
@@ -1374,14 +1379,14 @@ QStringList QMYSQLDriver::tables(QSql::TableType type) const
if(type & QSql::Tables) {
QString sql = QLatin1String("select table_name from information_schema.tables where table_schema = '") + QLatin1String(d->mysql->db) + QLatin1String("' and table_type = 'BASE TABLE'");
q.exec(sql);
-
+
while(q.next())
tl.append(q.value(0).toString());
}
if(type & QSql::Views) {
QString sql = QLatin1String("select table_name from information_schema.tables where table_schema = '") + QLatin1String(d->mysql->db) + QLatin1String("' and table_type = 'VIEW'");
q.exec(sql);
-
+
while(q.next())
tl.append(q.value(0).toString());
}
@@ -1413,6 +1418,7 @@ QSqlIndex QMYSQLDriver::primaryIndex(const QString& tablename) const
QSqlRecord QMYSQLDriver::record(const QString& tablename) const
{
+ Q_D(const QMYSQLDriver);
QString table=tablename;
if(isIdentifierEscaped(table, QSqlDriver::TableName))
table = stripDelimiters(table, QSqlDriver::TableName);
@@ -1434,11 +1440,13 @@ QSqlRecord QMYSQLDriver::record(const QString& tablename) const
QVariant QMYSQLDriver::handle() const
{
+ Q_D(const QMYSQLDriver);
return QVariant::fromValue(d->mysql);
}
bool QMYSQLDriver::beginTransaction()
{
+ Q_D(QMYSQLDriver);
#ifndef CLIENT_TRANSACTIONS
return false;
#endif
@@ -1456,6 +1464,7 @@ bool QMYSQLDriver::beginTransaction()
bool QMYSQLDriver::commitTransaction()
{
+ Q_D(QMYSQLDriver);
#ifndef CLIENT_TRANSACTIONS
return false;
#endif
@@ -1473,6 +1482,7 @@ bool QMYSQLDriver::commitTransaction()
bool QMYSQLDriver::rollbackTransaction()
{
+ Q_D(QMYSQLDriver);
#ifndef CLIENT_TRANSACTIONS
return false;
#endif
@@ -1490,6 +1500,7 @@ bool QMYSQLDriver::rollbackTransaction()
QString QMYSQLDriver::formatValue(const QSqlField &field, bool trimStrings) const
{
+ Q_D(const QMYSQLDriver);
QString r;
if (field.isNull()) {
r = QLatin1String("NULL");
diff --git a/src/sql/drivers/mysql/qsql_mysql.pri b/src/sql/drivers/mysql/qsql_mysql.pri
index 0423eb4ed9..50f49ca548 100644
--- a/src/sql/drivers/mysql/qsql_mysql.pri
+++ b/src/sql/drivers/mysql/qsql_mysql.pri
@@ -1,4 +1,4 @@
-HEADERS += $$PWD/qsql_mysql.h
+HEADERS += $$PWD/qsql_mysql_p.h
SOURCES += $$PWD/qsql_mysql.cpp
!isEmpty(MYSQL_PATH) {
diff --git a/src/sql/drivers/mysql/qsql_mysql.h b/src/sql/drivers/mysql/qsql_mysql_p.h
index 37e18c8fb1..a1be139b2a 100644
--- a/src/sql/drivers/mysql/qsql_mysql.h
+++ b/src/sql/drivers/mysql/qsql_mysql_p.h
@@ -42,6 +42,17 @@
#ifndef QSQL_MYSQL_H
#define QSQL_MYSQL_H
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists purely as an
+// implementation detail. This header file may change from version to
+// version without notice, or even be removed.
+//
+// We mean it.
+//
+
#include <QtSql/qsqldriver.h>
#include <QtSql/qsqlresult.h>
@@ -57,15 +68,8 @@
#define Q_EXPORT_SQLDRIVER_MYSQL Q_SQL_EXPORT
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
-#if 0
-#pragma qt_no_master_include
-#pragma qt_sync_stop_processing
-#endif
-
class QMYSQLDriverPrivate;
class QMYSQLResultPrivate;
class QMYSQLDriver;
@@ -106,8 +110,9 @@ private:
class Q_EXPORT_SQLDRIVER_MYSQL QMYSQLDriver : public QSqlDriver
{
- Q_OBJECT
friend class QMYSQLResult;
+ Q_DECLARE_PRIVATE(QMYSQLDriver)
+ Q_OBJECT
public:
explicit QMYSQLDriver(QObject *parent=0);
explicit QMYSQLDriver(MYSQL *con, QObject * parent=0);
@@ -137,11 +142,8 @@ protected:
bool rollbackTransaction();
private:
void init();
- QMYSQLDriverPrivate* d;
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQL_MYSQL_H
diff --git a/src/sql/drivers/oci/qsql_oci.cpp b/src/sql/drivers/oci/qsql_oci.cpp
index e2bb9a4eaf..fe9ae42e6f 100644
--- a/src/sql/drivers/oci/qsql_oci.cpp
+++ b/src/sql/drivers/oci/qsql_oci.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include "qsql_oci.h"
+#include "qsql_oci_p.h"
#include <qcoreapplication.h>
#include <qvariant.h>
@@ -51,6 +51,8 @@
#include <qsqlfield.h>
#include <qsqlindex.h>
#include <qsqlquery.h>
+#include <QtSql/private/qsqlcachedresult_p.h>
+#include <QtSql/private/qsqldriver_p.h>
#include <qstringlist.h>
#include <qvarlengtharray.h>
#include <qvector.h>
@@ -99,7 +101,7 @@ enum { QOCIEncoding = 2000 }; // AL16UTF16
// Always set the OCI_ATTR_CHARSET_FORM to SQLCS_NCHAR is safe
// because Oracle server will deal with the implicit Conversion
// Between CHAR and NCHAR.
-// see: http://download.oracle.com/docs/cd/A91202_01/901_doc/appdev.901/a89857/oci05bnd.htm#422705
+// see: http://download.oracle.com/docs/cd/A91202_01/901_doc/appdev.901/a89857/oci05bnd.htm#422705
static const ub1 qOraCharsetForm = SQLCS_NCHAR;
#endif
@@ -162,6 +164,33 @@ Q_DECLARE_METATYPE(QOCIRowIdPointer)
QT_END_INCLUDE_NAMESPACE
class QOCICols;
+struct QOCIResultPrivate;
+
+class Q_EXPORT_SQLDRIVER_OCI QOCIResult : public QSqlCachedResult
+{
+ friend class QOCIDriver;
+ friend struct QOCIResultPrivate;
+ friend class QOCICols;
+public:
+ QOCIResult(const QOCIDriver * db, const QOCIDriverPrivate* p);
+ ~QOCIResult();
+ bool prepare(const QString& query);
+ bool exec();
+ QVariant handle() const;
+
+protected:
+ bool gotoNext(ValueCache &values, int index);
+ bool reset (const QString& query);
+ int size();
+ int numRowsAffected();
+ QSqlRecord record() const;
+ QVariant lastInsertId() const;
+ bool execBatch(bool arrayBind = false);
+ void virtual_hook(int id, void *data);
+
+private:
+ QOCIResultPrivate *d;
+};
struct QOCIResultPrivate
{
@@ -464,8 +493,9 @@ void QOCIResultPrivate::outValues(QVector<QVariant> &values, IndicatorArray &ind
}
-struct QOCIDriverPrivate
+class QOCIDriverPrivate : public QSqlDriverPrivate
{
+public:
QOCIDriverPrivate();
OCIEnv *env;
@@ -483,9 +513,10 @@ struct QOCIDriverPrivate
};
QOCIDriverPrivate::QOCIDriverPrivate()
- : env(0), svc(0), srvhp(0), authp(0), err(0), transaction(false), serverVersion(-1),
- prefetchRows(-1), prefetchMem(QOCI_PREFETCH_MEM)
+ : QSqlDriverPrivate(), env(0), svc(0), srvhp(0), authp(0), err(0), transaction(false),
+ serverVersion(-1), prefetchRows(-1), prefetchMem(QOCI_PREFETCH_MEM)
{
+ dbmsType = Oracle;
}
void QOCIDriverPrivate::allocErrorHandle()
@@ -2057,10 +2088,9 @@ void QOCIResult::virtual_hook(int id, void *data)
QOCIDriver::QOCIDriver(QObject* parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QOCIDriverPrivate, parent)
{
- d = new QOCIDriverPrivate();
-
+ Q_D(QOCIDriver);
#ifdef QOCI_THREADED
const ub4 mode = OCI_UTF16 | OCI_OBJECT | OCI_THREADED;
#else
@@ -2085,9 +2115,9 @@ QOCIDriver::QOCIDriver(QObject* parent)
}
QOCIDriver::QOCIDriver(OCIEnv* env, OCISvcCtx* ctx, QObject* parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QOCIDriverPrivate, parent)
{
- d = new QOCIDriverPrivate();
+ Q_D(QOCIDriver);
d->env = env;
d->svc = ctx;
@@ -2101,6 +2131,7 @@ QOCIDriver::QOCIDriver(OCIEnv* env, OCISvcCtx* ctx, QObject* parent)
QOCIDriver::~QOCIDriver()
{
+ Q_D(QOCIDriver);
if (isOpen())
close();
int r = OCIHandleFree(d->err, OCI_HTYPE_ERROR);
@@ -2109,12 +2140,11 @@ QOCIDriver::~QOCIDriver()
r = OCIHandleFree(d->env, OCI_HTYPE_ENV);
if (r != OCI_SUCCESS)
qWarning("Unable to free Environment handle: %d", r);
-
- delete d;
}
bool QOCIDriver::hasFeature(DriverFeature f) const
{
+ Q_D(const QOCIDriver);
switch (f) {
case Transactions:
case LastInsertId:
@@ -2173,6 +2203,7 @@ bool QOCIDriver::open(const QString & db,
int port,
const QString &opts)
{
+ Q_D(QOCIDriver);
int r;
if (isOpen())
@@ -2183,7 +2214,7 @@ bool QOCIDriver::open(const QString & db,
// Connect without tnsnames.ora if a hostname is given
QString connectionString = db;
if (!hostname.isEmpty())
- connectionString =
+ connectionString =
QString::fromLatin1("(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(Host=%1)(Port=%2))"
"(CONNECT_DATA=(SID=%3)))").arg(hostname).arg((port > -1 ? port : 1521)).arg(db);
@@ -2259,6 +2290,7 @@ bool QOCIDriver::open(const QString & db,
void QOCIDriver::close()
{
+ Q_D(QOCIDriver);
if (!isOpen())
return;
@@ -2276,11 +2308,13 @@ void QOCIDriver::close()
QSqlResult *QOCIDriver::createResult() const
{
+ Q_D(const QOCIDriver);
return new QOCIResult(this, d);
}
bool QOCIDriver::beginTransaction()
{
+ Q_D(QOCIDriver);
if (!isOpen()) {
qWarning("QOCIDriver::beginTransaction: Database not open");
return false;
@@ -2301,6 +2335,7 @@ bool QOCIDriver::beginTransaction()
bool QOCIDriver::commitTransaction()
{
+ Q_D(QOCIDriver);
if (!isOpen()) {
qWarning("QOCIDriver::commitTransaction: Database not open");
return false;
@@ -2320,6 +2355,7 @@ bool QOCIDriver::commitTransaction()
bool QOCIDriver::rollbackTransaction()
{
+ Q_D(QOCIDriver);
if (!isOpen()) {
qWarning("QOCIDriver::rollbackTransaction: Database not open");
return false;
@@ -2339,6 +2375,7 @@ bool QOCIDriver::rollbackTransaction()
QStringList QOCIDriver::tables(QSql::TableType type) const
{
+ Q_D(const QOCIDriver);
QStringList tl;
QStringList sysUsers = QStringList() << QLatin1String("MDSYS")
<< QLatin1String("LBACSYS")
@@ -2444,6 +2481,7 @@ void qSplitTableAndOwner(const QString & tname, QString * tbl,
QSqlRecord QOCIDriver::record(const QString& tablename) const
{
+ Q_D(const QOCIDriver);
QSqlRecord fil;
if (!isOpen())
return fil;
@@ -2517,6 +2555,7 @@ QSqlRecord QOCIDriver::record(const QString& tablename) const
QSqlIndex QOCIDriver::primaryIndex(const QString& tablename) const
{
+ Q_D(const QOCIDriver);
QSqlIndex idx(tablename);
if (!isOpen())
return idx;
@@ -2637,6 +2676,7 @@ QString QOCIDriver::formatValue(const QSqlField &field, bool trimStrings) const
QVariant QOCIDriver::handle() const
{
+ Q_D(const QOCIDriver);
return QVariant::fromValue(d->env);
}
diff --git a/src/sql/drivers/oci/qsql_oci.pri b/src/sql/drivers/oci/qsql_oci.pri
index 60ccc4c227..66ccdb1abb 100644
--- a/src/sql/drivers/oci/qsql_oci.pri
+++ b/src/sql/drivers/oci/qsql_oci.pri
@@ -1,4 +1,4 @@
-HEADERS += $$PWD/qsql_oci.h
+HEADERS += $$PWD/qsql_oci_p.h
SOURCES += $$PWD/qsql_oci.cpp
unix {
@@ -6,4 +6,4 @@ unix {
} else {
LIBS *= -loci
}
-macx:QMAKE_LFLAGS += -Wl,-flat_namespace,-U,_environ
+mac:QMAKE_LFLAGS += -Wl,-flat_namespace,-U,_environ
diff --git a/src/sql/drivers/oci/qsql_oci.h b/src/sql/drivers/oci/qsql_oci_p.h
index 2488e696d2..c55a4209fa 100644
--- a/src/sql/drivers/oci/qsql_oci.h
+++ b/src/sql/drivers/oci/qsql_oci_p.h
@@ -42,9 +42,19 @@
#ifndef QSQL_OCI_H
#define QSQL_OCI_H
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists purely as an
+// implementation detail. This header file may change from version to
+// version without notice, or even be removed.
+//
+// We mean it.
+//
+
#include <QtSql/qsqlresult.h>
#include <QtSql/qsqldriver.h>
-#include <QtSql/private/qsqlcachedresult_p.h>
#ifdef QT_PLUGIN
#define Q_EXPORT_SQLDRIVER_OCI
@@ -52,51 +62,18 @@
#define Q_EXPORT_SQLDRIVER_OCI Q_SQL_EXPORT
#endif
-QT_BEGIN_HEADER
-
typedef struct OCIEnv OCIEnv;
typedef struct OCISvcCtx OCISvcCtx;
QT_BEGIN_NAMESPACE
-#if 0
-#pragma qt_no_master_include
-#pragma qt_sync_stop_processing
-#endif
-
class QOCIDriver;
class QOCICols;
-struct QOCIDriverPrivate;
-struct QOCIResultPrivate;
-
-class Q_EXPORT_SQLDRIVER_OCI QOCIResult : public QSqlCachedResult
-{
- friend class QOCIDriver;
- friend struct QOCIResultPrivate;
- friend class QOCICols;
-public:
- QOCIResult(const QOCIDriver * db, const QOCIDriverPrivate* p);
- ~QOCIResult();
- bool prepare(const QString& query);
- bool exec();
- QVariant handle() const;
-
-protected:
- bool gotoNext(ValueCache &values, int index);
- bool reset (const QString& query);
- int size();
- int numRowsAffected();
- QSqlRecord record() const;
- QVariant lastInsertId() const;
- bool execBatch(bool arrayBind = false);
- void virtual_hook(int id, void *data);
-
-private:
- QOCIResultPrivate *d;
-};
+class QOCIDriverPrivate;
class Q_EXPORT_SQLDRIVER_OCI QOCIDriver : public QSqlDriver
{
+ Q_DECLARE_PRIVATE(QOCIDriver)
Q_OBJECT
friend struct QOCIResultPrivate;
friend class QOCIPrivate;
@@ -125,12 +102,8 @@ protected:
bool beginTransaction();
bool commitTransaction();
bool rollbackTransaction();
-private:
- QOCIDriverPrivate *d;
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQL_OCI_H
diff --git a/src/sql/drivers/odbc/qsql_odbc.cpp b/src/sql/drivers/odbc/qsql_odbc.cpp
index 9517d95fc4..d36a224d8e 100644
--- a/src/sql/drivers/odbc/qsql_odbc.cpp
+++ b/src/sql/drivers/odbc/qsql_odbc.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include "qsql_odbc.h"
+#include "qsql_odbc_p.h"
#include <qsqlrecord.h>
#if defined (Q_OS_WIN32)
@@ -57,6 +57,7 @@
#include <qmath.h>
#include <QDebug>
#include <QSqlQuery>
+#include <QtSql/private/qsqldriver_p.h>
QT_BEGIN_NAMESPACE
@@ -111,14 +112,13 @@ inline static QVarLengthArray<SQLTCHAR> toSQLTCHAR(const QString &input)
return result;
}
-class QODBCDriverPrivate
+class QODBCDriverPrivate : public QSqlDriverPrivate
{
public:
enum DefaultCase{Lower, Mixed, Upper, Sensitive};
QODBCDriverPrivate()
- : hEnv(0), hDbc(0), unicode(false), useSchema(false), disconnectCount(0), datetime_precision(19), isMySqlServer(false),
- isMSSqlServer(false), isFreeTDSDriver(false), hasSQLFetchScroll(true),
- hasMultiResultSets(false), isQuoteInitialized(false), quote(QLatin1Char('"'))
+ : QSqlDriverPrivate(), hEnv(0), hDbc(0), unicode(false), useSchema(false), disconnectCount(0), datetime_precision(19),
+ isFreeTDSDriver(false), hasSQLFetchScroll(true), hasMultiResultSets(false), isQuoteInitialized(false), quote(QLatin1Char('"'))
{
}
@@ -129,15 +129,13 @@ public:
bool useSchema;
int disconnectCount;
int datetime_precision;
- bool isMySqlServer;
- bool isMSSqlServer;
bool isFreeTDSDriver;
bool hasSQLFetchScroll;
bool hasMultiResultSets;
bool checkDriver() const;
void checkUnicode();
- void checkSqlServer();
+ void checkDBMS();
void checkHasSQLFetchScroll();
void checkHasMultiResults();
void checkSchemaUsage();
@@ -190,13 +188,13 @@ public:
bool QODBCPrivate::isStmtHandleValid(const QSqlDriver *driver)
{
const QODBCDriver *odbcdriver = static_cast<const QODBCDriver*> (driver);
- return disconnectCount == odbcdriver->d->disconnectCount;
+ return disconnectCount == odbcdriver->d_func()->disconnectCount;
}
void QODBCPrivate::updateStmtHandleState(const QSqlDriver *driver)
{
const QODBCDriver *odbcdriver = static_cast<const QODBCDriver*> (driver);
- disconnectCount = odbcdriver->d->disconnectCount;
+ disconnectCount = odbcdriver->d_func()->disconnectCount;
}
static QString qWarnODBCHandle(int handleType, SQLHANDLE handle, int *nativeCode = 0)
@@ -960,11 +958,6 @@ bool QODBCResult::reset (const QString& query)
return false;
}
- if(r == SQL_NO_DATA) {
- setSelect(false);
- return true;
- }
-
SQLINTEGER bufferLength;
SQLULEN isScrollable;
r = SQLGetStmtAttr(d->hStmt, SQL_ATTR_CURSOR_SCROLLABLE, &isScrollable, SQL_IS_INTEGER, &bufferLength);
@@ -1407,7 +1400,7 @@ bool QODBCResult::exec()
// (How many leading digits do we want to keep? With SQL Server 2005, this should be 3: 123000000)
int keep = (int)qPow(10.0, 9 - qMin(9, precision));
- dt->fraction /= keep * keep;
+ dt->fraction = (dt->fraction / keep) * keep;
}
r = SQLBindParameter(d->hStmt,
@@ -1592,7 +1585,7 @@ bool QODBCResult::exec()
}
}
r = SQLExecute(d->hStmt);
- if (r != SQL_SUCCESS && r != SQL_SUCCESS_WITH_INFO) {
+ if (r != SQL_SUCCESS && r != SQL_SUCCESS_WITH_INFO && r != SQL_NO_DATA) {
qWarning() << "QODBCResult::exec: Unable to execute statement:" << qODBCWarn(d);
setLastError(qMakeError(QCoreApplication::translate("QODBCResult",
"Unable to execute statement"), QSqlError::StatementError, d));
@@ -1677,6 +1670,38 @@ QSqlRecord QODBCResult::record() const
return d->rInf;
}
+QVariant QODBCResult::lastInsertId() const
+{
+ QString sql;
+
+ switch (d->driverPrivate->dbmsType) {
+ case QODBCDriverPrivate::MSSqlServer:
+ case QODBCDriverPrivate::Sybase:
+ sql = QLatin1String("SELECT @@IDENTITY;");
+ break;
+ case QODBCDriverPrivate::MySqlServer:
+ sql = QLatin1String("SELECT LAST_INSERT_ID();");
+ break;
+ case QODBCDriverPrivate::PostgreSQL:
+ sql = QLatin1String("SELECT lastval();");
+ break;
+ default:
+ break;
+ }
+
+ if (!sql.isEmpty()) {
+ QSqlQuery qry(driver()->createResult());
+ if (qry.exec(sql) && qry.next())
+ return qry.value(0);
+
+ qSqlWarning(QLatin1String("QODBCResult::lastInsertId: Unable to get lastInsertId"), d);
+ } else {
+ qSqlWarning(QLatin1String("QODBCResult::lastInsertId: not implemented for this DBMS"), d);
+ }
+
+ return QVariant();
+}
+
QVariant QODBCResult::handle() const
{
return QVariant(qRegisterMetaType<SQLHANDLE>("SQLHANDLE"), &d->hStmt);
@@ -1742,15 +1767,14 @@ void QODBCResult::setForwardOnly(bool forward)
QODBCDriver::QODBCDriver(QObject *parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QODBCDriverPrivate, parent)
{
- init();
}
-QODBCDriver::QODBCDriver(SQLHANDLE env, SQLHANDLE con, QObject * parent)
- : QSqlDriver(parent)
+QODBCDriver::QODBCDriver(SQLHANDLE env, SQLHANDLE con, QObject *parent)
+ : QSqlDriver(*new QODBCDriverPrivate, parent)
{
- init();
+ Q_D(QODBCDriver);
d->hEnv = env;
d->hDbc = con;
if (env && con) {
@@ -1759,19 +1783,14 @@ QODBCDriver::QODBCDriver(SQLHANDLE env, SQLHANDLE con, QObject * parent)
}
}
-void QODBCDriver::init()
-{
- d = new QODBCDriverPrivate();
-}
-
QODBCDriver::~QODBCDriver()
{
cleanup();
- delete d;
}
bool QODBCDriver::hasFeature(DriverFeature f) const
{
+ Q_D(const QODBCDriver);
switch (f) {
case Transactions: {
if (!d->hDbc)
@@ -1797,16 +1816,20 @@ bool QODBCDriver::hasFeature(DriverFeature f) const
return true;
case QuerySize:
case NamedPlaceholders:
- case LastInsertId:
case BatchOperations:
case SimpleLocking:
case EventNotifications:
case CancelQuery:
return false;
+ case LastInsertId:
+ return (d->dbmsType == QODBCDriverPrivate::MSSqlServer)
+ || (d->dbmsType == QODBCDriverPrivate::Sybase)
+ || (d->dbmsType == QODBCDriverPrivate::MySqlServer)
+ || (d->dbmsType == QODBCDriverPrivate::PostgreSQL);
case MultipleResultSets:
return d->hasMultiResultSets;
case BLOB: {
- if(d->isMySqlServer)
+ if (d->dbmsType == QODBCDriverPrivate::MySqlServer)
return true;
else
return false;
@@ -1822,6 +1845,7 @@ bool QODBCDriver::open(const QString & db,
int,
const QString& connOpts)
{
+ Q_D(QODBCDriver);
if (isOpen())
close();
SQLRETURN r;
@@ -1896,13 +1920,13 @@ bool QODBCDriver::open(const QString & db,
d->checkUnicode();
d->checkSchemaUsage();
- d->checkSqlServer();
+ d->checkDBMS();
d->checkHasSQLFetchScroll();
d->checkHasMultiResults();
d->checkDateTimePrecision();
setOpen(true);
setOpenError(false);
- if(d->isMSSqlServer) {
+ if (d->dbmsType == QODBCDriverPrivate::MSSqlServer) {
QSqlQuery i(createResult());
i.exec(QLatin1String("SET QUOTED_IDENTIFIER ON"));
}
@@ -1918,9 +1942,8 @@ void QODBCDriver::close()
void QODBCDriver::cleanup()
{
+ Q_D(QODBCDriver);
SQLRETURN r;
- if (!d)
- return;
if(d->hDbc) {
// Open statements/descriptors handles are automatically cleaned up by SQLDisconnect
@@ -2069,7 +2092,7 @@ void QODBCDriverPrivate::checkSchemaUsage()
useSchema = (val != 0);
}
-void QODBCDriverPrivate::checkSqlServer()
+void QODBCDriverPrivate::checkDBMS()
{
SQLRETURN r;
QVarLengthArray<SQLTCHAR> serverString(200);
@@ -2088,8 +2111,16 @@ void QODBCDriverPrivate::checkSqlServer()
#else
serverType = QString::fromUtf8((const char *)serverString.constData(), t);
#endif
- isMySqlServer = serverType.contains(QLatin1String("mysql"), Qt::CaseInsensitive);
- isMSSqlServer = serverType.contains(QLatin1String("Microsoft SQL Server"), Qt::CaseInsensitive);
+ if (serverType.contains(QLatin1String("PostgreSQL"), Qt::CaseInsensitive))
+ dbmsType = PostgreSQL;
+ else if (serverType.contains(QLatin1String("Oracle"), Qt::CaseInsensitive))
+ dbmsType = Oracle;
+ else if (serverType.contains(QLatin1String("MySql"), Qt::CaseInsensitive))
+ dbmsType = MySqlServer;
+ else if (serverType.contains(QLatin1String("Microsoft SQL Server"), Qt::CaseInsensitive))
+ dbmsType = MSSqlServer;
+ else if (serverType.contains(QLatin1String("Sybase"), Qt::CaseInsensitive))
+ dbmsType = Sybase;
}
r = SQLGetInfo(hDbc,
SQL_DRIVER_NAME,
@@ -2160,11 +2191,13 @@ void QODBCDriverPrivate::checkDateTimePrecision()
QSqlResult *QODBCDriver::createResult() const
{
- return new QODBCResult(this, d);
+ Q_D(const QODBCDriver);
+ return new QODBCResult(this, const_cast<QODBCDriverPrivate*>(d));
}
bool QODBCDriver::beginTransaction()
{
+ Q_D(QODBCDriver);
if (!isOpen()) {
qWarning() << "QODBCDriver::beginTransaction: Database not open";
return false;
@@ -2184,6 +2217,7 @@ bool QODBCDriver::beginTransaction()
bool QODBCDriver::commitTransaction()
{
+ Q_D(QODBCDriver);
if (!isOpen()) {
qWarning() << "QODBCDriver::commitTransaction: Database not open";
return false;
@@ -2201,6 +2235,7 @@ bool QODBCDriver::commitTransaction()
bool QODBCDriver::rollbackTransaction()
{
+ Q_D(QODBCDriver);
if (!isOpen()) {
qWarning() << "QODBCDriver::rollbackTransaction: Database not open";
return false;
@@ -2218,6 +2253,7 @@ bool QODBCDriver::rollbackTransaction()
bool QODBCDriver::endTrans()
{
+ Q_D(QODBCDriver);
SQLUINTEGER ac(SQL_AUTOCOMMIT_ON);
SQLRETURN r = SQLSetConnectAttr(d->hDbc,
SQL_ATTR_AUTOCOMMIT,
@@ -2232,6 +2268,7 @@ bool QODBCDriver::endTrans()
QStringList QODBCDriver::tables(QSql::TableType type) const
{
+ Q_D(const QODBCDriver);
QStringList tl;
if (!isOpen())
return tl;
@@ -2309,6 +2346,7 @@ QStringList QODBCDriver::tables(QSql::TableType type) const
QSqlIndex QODBCDriver::primaryIndex(const QString& tablename) const
{
+ Q_D(const QODBCDriver);
QSqlIndex index(tablename);
if (!isOpen())
return index;
@@ -2324,7 +2362,7 @@ QSqlIndex QODBCDriver::primaryIndex(const QString& tablename) const
return index;
}
QString catalog, schema, table;
- d->splitTableQualifier(tablename, catalog, schema, table);
+ const_cast<QODBCDriverPrivate*>(d)->splitTableQualifier(tablename, catalog, schema, table);
if (isIdentifierEscaped(catalog, QSqlDriver::TableName))
catalog = stripDelimiters(catalog, QSqlDriver::TableName);
@@ -2436,13 +2474,14 @@ QSqlIndex QODBCDriver::primaryIndex(const QString& tablename) const
QSqlRecord QODBCDriver::record(const QString& tablename) const
{
+ Q_D(const QODBCDriver);
QSqlRecord fil;
if (!isOpen())
return fil;
SQLHANDLE hStmt;
QString catalog, schema, table;
- d->splitTableQualifier(tablename, catalog, schema, table);
+ const_cast<QODBCDriverPrivate*>(d)->splitTableQualifier(tablename, catalog, schema, table);
if (isIdentifierEscaped(catalog, QSqlDriver::TableName))
catalog = stripDelimiters(catalog, QSqlDriver::TableName);
@@ -2561,12 +2600,14 @@ QString QODBCDriver::formatValue(const QSqlField &field,
QVariant QODBCDriver::handle() const
{
+ Q_D(const QODBCDriver);
return QVariant(qRegisterMetaType<SQLHANDLE>("SQLHANDLE"), &d->hDbc);
}
QString QODBCDriver::escapeIdentifier(const QString &identifier, IdentifierType) const
{
- QChar quote = d->quoteChar();
+ Q_D(const QODBCDriver);
+ QChar quote = const_cast<QODBCDriverPrivate*>(d)->quoteChar();
QString res = identifier;
if(!identifier.isEmpty() && !identifier.startsWith(quote) && !identifier.endsWith(quote) ) {
res.replace(quote, QString(quote)+QString(quote));
@@ -2578,7 +2619,8 @@ QString QODBCDriver::escapeIdentifier(const QString &identifier, IdentifierType)
bool QODBCDriver::isIdentifierEscaped(const QString &identifier, IdentifierType) const
{
- QChar quote = d->quoteChar();
+ Q_D(const QODBCDriver);
+ QChar quote = const_cast<QODBCDriverPrivate*>(d)->quoteChar();
return identifier.size() > 2
&& identifier.startsWith(quote) //left delimited
&& identifier.endsWith(quote); //right delimited
diff --git a/src/sql/drivers/odbc/qsql_odbc.pri b/src/sql/drivers/odbc/qsql_odbc.pri
index 19ff784a04..b206df37c3 100644
--- a/src/sql/drivers/odbc/qsql_odbc.pri
+++ b/src/sql/drivers/odbc/qsql_odbc.pri
@@ -1,4 +1,4 @@
-HEADERS += $$PWD/qsql_odbc.h
+HEADERS += $$PWD/qsql_odbc_p.h
SOURCES += $$PWD/qsql_odbc.cpp
unix {
diff --git a/src/sql/drivers/odbc/qsql_odbc.h b/src/sql/drivers/odbc/qsql_odbc_p.h
index 4fba49b9c5..b18768a5a2 100644
--- a/src/sql/drivers/odbc/qsql_odbc.h
+++ b/src/sql/drivers/odbc/qsql_odbc_p.h
@@ -42,6 +42,17 @@
#ifndef QSQL_ODBC_H
#define QSQL_ODBC_H
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists purely as an
+// implementation detail. This header file may change from version to
+// version without notice, or even be removed.
+//
+// We mean it.
+//
+
#include <QtSql/qsqldriver.h>
#include <QtSql/qsqlresult.h>
@@ -70,15 +81,8 @@
#include <sqlext.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
-#if 0
-#pragma qt_no_master_include
-#pragma qt_sync_stop_processing
-#endif
-
class QODBCPrivate;
class QODBCDriverPrivate;
class QODBCDriver;
@@ -93,6 +97,7 @@ public:
bool prepare(const QString& query);
bool exec();
+ QVariant lastInsertId() const;
QVariant handle() const;
virtual void setForwardOnly(bool forward);
@@ -118,6 +123,7 @@ private:
class Q_EXPORT_SQLDRIVER_ODBC QODBCDriver : public QSqlDriver
{
+ Q_DECLARE_PRIVATE(QODBCDriver)
Q_OBJECT
public:
explicit QODBCDriver(QObject *parent=0);
@@ -149,15 +155,11 @@ protected:
bool rollbackTransaction();
private:
- void init();
bool endTrans();
void cleanup();
- QODBCDriverPrivate* d;
friend class QODBCPrivate;
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQL_ODBC_H
diff --git a/src/sql/drivers/psql/qsql_psql.cpp b/src/sql/drivers/psql/qsql_psql.cpp
index 0eadceb1d1..9331f5c371 100644
--- a/src/sql/drivers/psql/qsql_psql.cpp
+++ b/src/sql/drivers/psql/qsql_psql.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include "qsql_psql.h"
+#include "qsql_psql_p.h"
#include <qcoreapplication.h>
#include <qvariant.h>
@@ -54,6 +54,7 @@
#include <qstringlist.h>
#include <qmutex.h>
#include <QtSql/private/qsqlresult_p.h>
+#include <QtSql/private/qsqldriver_p.h>
#include <libpq-fe.h>
#include <pg_config.h>
@@ -121,17 +122,26 @@ inline void qPQfreemem(void *buffer)
PQfreemem(buffer);
}
-class QPSQLDriverPrivate
+class QPSQLDriverPrivate : public QSqlDriverPrivate
{
+ Q_DECLARE_PUBLIC(QPSQLDriver)
public:
- QPSQLDriverPrivate(QPSQLDriver *qq) : q(qq), connection(0), isUtf8(false), pro(QPSQLDriver::Version6), sn(0), pendingNotifyCheck(false) {}
- QPSQLDriver *q;
+ QPSQLDriverPrivate() : QSqlDriverPrivate(),
+ connection(0),
+ isUtf8(false),
+ pro(QPSQLDriver::Version6),
+ sn(0),
+ pendingNotifyCheck(false),
+ hasBackslashEscape(false)
+ { dbmsType = PostgreSQL; }
+
PGconn *connection;
bool isUtf8;
QPSQLDriver::Protocol pro;
QSocketNotifier *sn;
QStringList seid;
mutable bool pendingNotifyCheck;
+ bool hasBackslashEscape;
void appendTables(QStringList &tl, QSqlQuery &t, QChar type);
PGresult * exec(const char * stmt) const;
@@ -139,6 +149,7 @@ public:
QPSQLDriver::Protocol getPSQLVersion();
bool setEncodingUtf8();
void setDatestyle();
+ void detectBackslashEscape();
};
void QPSQLDriverPrivate::appendTables(QStringList &tl, QSqlQuery &t, QChar type)
@@ -167,10 +178,11 @@ void QPSQLDriverPrivate::appendTables(QStringList &tl, QSqlQuery &t, QChar type)
PGresult * QPSQLDriverPrivate::exec(const char * stmt) const
{
+ Q_Q(const QPSQLDriver);
PGresult *result = PQexec(connection, stmt);
if (seid.size() && !pendingNotifyCheck) {
pendingNotifyCheck = true;
- QMetaObject::invokeMethod(q, "_q_handleNotification", Qt::QueuedConnection, Q_ARG(int,0));
+ QMetaObject::invokeMethod(const_cast<QPSQLDriver*>(q), "_q_handleNotification", Qt::QueuedConnection, Q_ARG(int,0));
}
return result;
}
@@ -180,14 +192,25 @@ PGresult * QPSQLDriverPrivate::exec(const QString & stmt) const
return exec(isUtf8 ? stmt.toUtf8().constData() : stmt.toLocal8Bit().constData());
}
-class QPSQLResultPrivate
+class QPSQLResultPrivate : public QSqlResultPrivate
{
+ Q_DECLARE_PUBLIC(QPSQLResult)
public:
- QPSQLResultPrivate(QPSQLResult *qq): q(qq), driver(0), result(0), currentSize(-1), preparedQueriesEnabled(false) {}
- static QString fieldSerial(int i) { return QLatin1Char('$') + QString::number(i + 1); }
+ QPSQLResultPrivate()
+ : QSqlResultPrivate(),
+ result(0),
+ currentSize(-1),
+ preparedQueriesEnabled(false)
+ { }
+
+ QString fieldSerial(int i) const { return QLatin1Char('$') + QString::number(i + 1); }
+ void deallocatePreparedStmt();
+ const QPSQLDriverPrivate * privDriver() const
+ {
+ Q_Q(const QPSQLResult);
+ return reinterpret_cast<const QPSQLDriver *>(q->driver())->d_func();
+ }
- QPSQLResult *q;
- const QPSQLDriverPrivate *driver;
PGresult *result;
int currentSize;
bool preparedQueriesEnabled;
@@ -210,6 +233,7 @@ static QSqlError qMakeError(const QString& err, QSqlError::ErrorType type,
bool QPSQLResultPrivate::processResults()
{
+ Q_Q(QPSQLResult);
if (!result)
return false;
@@ -226,7 +250,7 @@ bool QPSQLResultPrivate::processResults()
return true;
}
q->setLastError(qMakeError(QCoreApplication::translate("QPSQLResult",
- "Unable to create query"), QSqlError::StatementError, driver, result));
+ "Unable to create query"), QSqlError::StatementError, privDriver(), result));
return false;
}
@@ -276,42 +300,42 @@ static QVariant::Type qDecodePSQLType(int t)
return type;
}
-static void qDeallocatePreparedStmt(QPSQLResultPrivate *d)
+void QPSQLResultPrivate::deallocatePreparedStmt()
{
- const QString stmt = QLatin1String("DEALLOCATE ") + d->preparedStmtId;
- PGresult *result = d->driver->exec(stmt);
+ const QString stmt = QLatin1String("DEALLOCATE ") + preparedStmtId;
+ PGresult *result = privDriver()->exec(stmt);
if (PQresultStatus(result) != PGRES_COMMAND_OK)
- qWarning("Unable to free statement: %s", PQerrorMessage(d->driver->connection));
+ qWarning("Unable to free statement: %s", PQerrorMessage(privDriver()->connection));
PQclear(result);
- d->preparedStmtId.clear();
+ preparedStmtId.clear();
}
-QPSQLResult::QPSQLResult(const QPSQLDriver* db, const QPSQLDriverPrivate* p)
- : QSqlResult(db)
+QPSQLResult::QPSQLResult(const QPSQLDriver* db)
+ : QSqlResult(*new QPSQLResultPrivate, db)
{
- d = new QPSQLResultPrivate(this);
- d->driver = p;
+ Q_D(QPSQLResult);
d->preparedQueriesEnabled = db->hasFeature(QSqlDriver::PreparedQueries);
}
QPSQLResult::~QPSQLResult()
{
+ Q_D(QPSQLResult);
cleanup();
if (d->preparedQueriesEnabled && !d->preparedStmtId.isNull())
- qDeallocatePreparedStmt(d);
-
- delete d;
+ d->deallocatePreparedStmt();
}
QVariant QPSQLResult::handle() const
{
+ Q_D(const QPSQLResult);
return QVariant::fromValue(d->result);
}
void QPSQLResult::cleanup()
{
+ Q_D(QPSQLResult);
if (d->result)
PQclear(d->result);
d->result = 0;
@@ -322,6 +346,7 @@ void QPSQLResult::cleanup()
bool QPSQLResult::fetch(int i)
{
+ Q_D(const QPSQLResult);
if (!isActive())
return false;
if (i < 0)
@@ -341,11 +366,13 @@ bool QPSQLResult::fetchFirst()
bool QPSQLResult::fetchLast()
{
+ Q_D(const QPSQLResult);
return fetch(PQntuples(d->result) - 1);
}
QVariant QPSQLResult::data(int i)
{
+ Q_D(const QPSQLResult);
if (i >= PQnfields(d->result)) {
qWarning("QPSQLResult::data: column %d out of range", i);
return QVariant();
@@ -359,7 +386,7 @@ QVariant QPSQLResult::data(int i)
case QVariant::Bool:
return QVariant((bool)(val[0] == 't'));
case QVariant::String:
- return d->driver->isUtf8 ? QString::fromUtf8(val) : QString::fromLatin1(val);
+ return d->privDriver()->isUtf8 ? QString::fromUtf8(val) : QString::fromLatin1(val);
case QVariant::LongLong:
if (val[0] == '-')
return QString::fromLatin1(val).toLongLong();
@@ -446,34 +473,44 @@ QVariant QPSQLResult::data(int i)
bool QPSQLResult::isNull(int field)
{
+ Q_D(const QPSQLResult);
PQgetvalue(d->result, at(), field);
return PQgetisnull(d->result, at(), field);
}
bool QPSQLResult::reset (const QString& query)
{
+ Q_D(QPSQLResult);
cleanup();
if (!driver())
return false;
if (!driver()->isOpen() || driver()->isOpenError())
return false;
- d->result = d->driver->exec(query);
+ d->result = d->privDriver()->exec(query);
return d->processResults();
}
int QPSQLResult::size()
{
+ Q_D(const QPSQLResult);
return d->currentSize;
}
int QPSQLResult::numRowsAffected()
{
+ Q_D(const QPSQLResult);
return QString::fromLatin1(PQcmdTuples(d->result)).toInt();
}
QVariant QPSQLResult::lastInsertId() const
{
- if (isActive()) {
+ Q_D(const QPSQLResult);
+ if (d->privDriver()->pro >= QPSQLDriver::Version81) {
+ QSqlQuery qry(driver()->createResult());
+ // Most recent sequence value obtained from nextval
+ if (qry.exec(QLatin1String("SELECT lastval();")) && qry.next())
+ return qry.value(0);
+ } else if (isActive()) {
Oid id = PQoidValue(d->result);
if (id != InvalidOid)
return QVariant(id);
@@ -483,6 +520,7 @@ QVariant QPSQLResult::lastInsertId() const
QSqlRecord QPSQLResult::record() const
{
+ Q_D(const QPSQLResult);
QSqlRecord info;
if (!isActive() || !isSelect())
return info;
@@ -490,7 +528,7 @@ QSqlRecord QPSQLResult::record() const
int count = PQnfields(d->result);
for (int i = 0; i < count; ++i) {
QSqlField f;
- if (d->driver->isUtf8)
+ if (d->privDriver()->isUtf8)
f.setName(QString::fromUtf8(PQfname(d->result, i)));
else
f.setName(QString::fromLocal8Bit(PQfname(d->result, i)));
@@ -551,22 +589,23 @@ QString qMakePreparedStmtId()
bool QPSQLResult::prepare(const QString &query)
{
+ Q_D(QPSQLResult);
if (!d->preparedQueriesEnabled)
return QSqlResult::prepare(query);
cleanup();
if (!d->preparedStmtId.isEmpty())
- qDeallocatePreparedStmt(d);
+ d->deallocatePreparedStmt();
const QString stmtId = qMakePreparedStmtId();
- const QString stmt = QString::fromLatin1("PREPARE %1 AS ").arg(stmtId).append(QSqlResultPrivate::positionalToNamedBinding(query, QPSQLResultPrivate::fieldSerial));
+ const QString stmt = QString::fromLatin1("PREPARE %1 AS ").arg(stmtId).append(d->positionalToNamedBinding(query));
- PGresult *result = d->driver->exec(stmt);
+ PGresult *result = d->privDriver()->exec(stmt);
if (PQresultStatus(result) != PGRES_COMMAND_OK) {
setLastError(qMakeError(QCoreApplication::translate("QPSQLResult",
- "Unable to prepare statement"), QSqlError::StatementError, d->driver, result));
+ "Unable to prepare statement"), QSqlError::StatementError, d->privDriver(), result));
PQclear(result);
d->preparedStmtId.clear();
return false;
@@ -579,19 +618,20 @@ bool QPSQLResult::prepare(const QString &query)
bool QPSQLResult::exec()
{
+ Q_D(QPSQLResult);
if (!d->preparedQueriesEnabled)
return QSqlResult::exec();
cleanup();
QString stmt;
- const QString params = qCreateParamString(boundValues(), d->q->driver());
+ const QString params = qCreateParamString(boundValues(), driver());
if (params.isEmpty())
stmt = QString::fromLatin1("EXECUTE %1").arg(d->preparedStmtId);
else
stmt = QString::fromLatin1("EXECUTE %1 (%2)").arg(d->preparedStmtId).arg(params);
- d->result = d->driver->exec(stmt);
+ d->result = d->privDriver()->exec(stmt);
return d->processResults();
}
@@ -615,6 +655,23 @@ void QPSQLDriverPrivate::setDatestyle()
PQclear(result);
}
+void QPSQLDriverPrivate::detectBackslashEscape()
+{
+ // standard_conforming_strings option introduced in 8.2
+ // http://www.postgresql.org/docs/8.2/static/runtime-config-compatible.html
+ if (pro < QPSQLDriver::Version82) {
+ hasBackslashEscape = true;
+ } else {
+ hasBackslashEscape = false;
+ PGresult* result = exec(QLatin1Literal("SELECT '\\\\' x"));
+ int status = PQresultStatus(result);
+ if (status == PGRES_COMMAND_OK || status == PGRES_TUPLES_OK)
+ if (QString::fromLatin1(PQgetvalue(result, 0, 0)) == QLatin1Literal("\\"))
+ hasBackslashEscape = true;
+ PQclear(result);
+ }
+}
+
static QPSQLDriver::Protocol qMakePSQLVersion(int vMaj, int vMin)
{
switch (vMaj) {
@@ -714,42 +771,39 @@ QPSQLDriver::Protocol QPSQLDriverPrivate::getPSQLVersion()
}
QPSQLDriver::QPSQLDriver(QObject *parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QPSQLDriverPrivate, parent)
{
- init();
}
QPSQLDriver::QPSQLDriver(PGconn *conn, QObject *parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QPSQLDriverPrivate, parent)
{
- init();
+ Q_D(QPSQLDriver);
d->connection = conn;
if (conn) {
d->pro = d->getPSQLVersion();
+ d->detectBackslashEscape();
setOpen(true);
setOpenError(false);
}
}
-void QPSQLDriver::init()
-{
- d = new QPSQLDriverPrivate(this);
-}
-
QPSQLDriver::~QPSQLDriver()
{
+ Q_D(QPSQLDriver);
if (d->connection)
PQfinish(d->connection);
- delete d;
}
QVariant QPSQLDriver::handle() const
{
+ Q_D(const QPSQLDriver);
return QVariant::fromValue(d->connection);
}
bool QPSQLDriver::hasFeature(DriverFeature f) const
{
+ Q_D(const QPSQLDriver);
switch (f) {
case Transactions:
case QuerySize:
@@ -796,6 +850,7 @@ bool QPSQLDriver::open(const QString & db,
int port,
const QString& connOpts)
{
+ Q_D(QPSQLDriver);
if (isOpen())
close();
QString connectString;
@@ -827,6 +882,7 @@ bool QPSQLDriver::open(const QString & db,
}
d->pro = d->getPSQLVersion();
+ d->detectBackslashEscape();
d->isUtf8 = d->setEncodingUtf8();
d->setDatestyle();
@@ -837,6 +893,7 @@ bool QPSQLDriver::open(const QString & db,
void QPSQLDriver::close()
{
+ Q_D(QPSQLDriver);
if (isOpen()) {
d->seid.clear();
@@ -856,11 +913,12 @@ void QPSQLDriver::close()
QSqlResult *QPSQLDriver::createResult() const
{
- return new QPSQLResult(this, d);
+ return new QPSQLResult(this);
}
bool QPSQLDriver::beginTransaction()
{
+ Q_D(const QPSQLDriver);
if (!isOpen()) {
qWarning("QPSQLDriver::beginTransaction: Database not open");
return false;
@@ -878,6 +936,7 @@ bool QPSQLDriver::beginTransaction()
bool QPSQLDriver::commitTransaction()
{
+ Q_D(QPSQLDriver);
if (!isOpen()) {
qWarning("QPSQLDriver::commitTransaction: Database not open");
return false;
@@ -911,6 +970,7 @@ bool QPSQLDriver::commitTransaction()
bool QPSQLDriver::rollbackTransaction()
{
+ Q_D(QPSQLDriver);
if (!isOpen()) {
qWarning("QPSQLDriver::rollbackTransaction: Database not open");
return false;
@@ -928,6 +988,7 @@ bool QPSQLDriver::rollbackTransaction()
QStringList QPSQLDriver::tables(QSql::TableType type) const
{
+ Q_D(const QPSQLDriver);
QStringList tl;
if (!isOpen())
return tl;
@@ -935,9 +996,9 @@ QStringList QPSQLDriver::tables(QSql::TableType type) const
t.setForwardOnly(true);
if (type & QSql::Tables)
- d->appendTables(tl, t, QLatin1Char('r'));
+ const_cast<QPSQLDriverPrivate*>(d)->appendTables(tl, t, QLatin1Char('r'));
if (type & QSql::Views)
- d->appendTables(tl, t, QLatin1Char('v'));
+ const_cast<QPSQLDriverPrivate*>(d)->appendTables(tl, t, QLatin1Char('v'));
if (type & QSql::SystemTables) {
t.exec(QLatin1String("select relname from pg_class where (relkind = 'r') "
"and (relname like 'pg_%') "));
@@ -959,6 +1020,7 @@ static void qSplitTableName(QString &tablename, QString &schema)
QSqlIndex QPSQLDriver::primaryIndex(const QString& tablename) const
{
+ Q_D(const QPSQLDriver);
QSqlIndex idx(tablename);
if (!isOpen())
return idx;
@@ -1040,6 +1102,7 @@ QSqlIndex QPSQLDriver::primaryIndex(const QString& tablename) const
QSqlRecord QPSQLDriver::record(const QString& tablename) const
{
+ Q_D(const QPSQLDriver);
QSqlRecord info;
if (!isOpen())
return info;
@@ -1177,6 +1240,7 @@ QSqlRecord QPSQLDriver::record(const QString& tablename) const
QString QPSQLDriver::formatValue(const QSqlField &field, bool trimStrings) const
{
+ Q_D(const QPSQLDriver);
QString r;
if (field.isNull()) {
r = QLatin1String("NULL");
@@ -1212,12 +1276,10 @@ QString QPSQLDriver::formatValue(const QSqlField &field, bool trimStrings) const
}
break;
case QVariant::String:
- {
- // Escape '\' characters
r = QSqlDriver::formatValue(field, trimStrings);
- r.replace(QLatin1String("\\"), QLatin1String("\\\\"));
+ if (d->hasBackslashEscape)
+ r.replace(QLatin1String("\\"), QLatin1String("\\\\"));
break;
- }
case QVariant::Bool:
if (field.value().toBool())
r = QLatin1String("TRUE");
@@ -1274,16 +1336,19 @@ QString QPSQLDriver::escapeIdentifier(const QString &identifier, IdentifierType)
bool QPSQLDriver::isOpen() const
{
+ Q_D(const QPSQLDriver);
return PQstatus(d->connection) == CONNECTION_OK;
}
QPSQLDriver::Protocol QPSQLDriver::protocol() const
{
+ Q_D(const QPSQLDriver);
return d->pro;
}
bool QPSQLDriver::subscribeToNotification(const QString &name)
{
+ Q_D(QPSQLDriver);
if (!isOpen()) {
qWarning("QPSQLDriver::subscribeToNotificationImplementation: database not open.");
return false;
@@ -1321,6 +1386,7 @@ bool QPSQLDriver::subscribeToNotification(const QString &name)
bool QPSQLDriver::unsubscribeFromNotification(const QString &name)
{
+ Q_D(QPSQLDriver);
if (!isOpen()) {
qWarning("QPSQLDriver::unsubscribeFromNotificationImplementation: database not open.");
return false;
@@ -1352,11 +1418,13 @@ bool QPSQLDriver::unsubscribeFromNotification(const QString &name)
QStringList QPSQLDriver::subscribedToNotifications() const
{
+ Q_D(const QPSQLDriver);
return d->seid;
}
void QPSQLDriver::_q_handleNotification(int)
{
+ Q_D(QPSQLDriver);
d->pendingNotifyCheck = false;
PQconsumeInput(d->connection);
diff --git a/src/sql/drivers/psql/qsql_psql.pri b/src/sql/drivers/psql/qsql_psql.pri
index 9b647d8200..d0ded5e625 100644
--- a/src/sql/drivers/psql/qsql_psql.pri
+++ b/src/sql/drivers/psql/qsql_psql.pri
@@ -1,4 +1,4 @@
-HEADERS += $$PWD/qsql_psql.h
+HEADERS += $$PWD/qsql_psql_p.h
SOURCES += $$PWD/qsql_psql.cpp
unix|win32-g++* {
diff --git a/src/sql/drivers/psql/qsql_psql.h b/src/sql/drivers/psql/qsql_psql_p.h
index 444ef1bccc..5f4aa68b9e 100644
--- a/src/sql/drivers/psql/qsql_psql.h
+++ b/src/sql/drivers/psql/qsql_psql_p.h
@@ -42,6 +42,17 @@
#ifndef QSQL_PSQL_H
#define QSQL_PSQL_H
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists purely as an
+// implementation detail. This header file may change from version to
+// version without notice, or even be removed.
+//
+// We mean it.
+//
+
#include <QtSql/qsqlresult.h>
#include <QtSql/qsqldriver.h>
@@ -51,28 +62,21 @@
#define Q_EXPORT_SQLDRIVER_PSQL Q_SQL_EXPORT
#endif
-QT_BEGIN_HEADER
-
typedef struct pg_conn PGconn;
typedef struct pg_result PGresult;
QT_BEGIN_NAMESPACE
-#if 0
-#pragma qt_no_master_include
-#pragma qt_sync_stop_processing
-#endif
-
class QPSQLResultPrivate;
-class QPSQLDriverPrivate;
class QPSQLDriver;
class QSqlRecordInfo;
class QPSQLResult : public QSqlResult
{
- friend class QPSQLResultPrivate;
+ Q_DECLARE_PRIVATE(QPSQLResult)
+
public:
- QPSQLResult(const QPSQLDriver* db, const QPSQLDriverPrivate* p);
+ QPSQLResult(const QPSQLDriver* db);
~QPSQLResult();
QVariant handle() const;
@@ -92,13 +96,15 @@ protected:
QVariant lastInsertId() const;
bool prepare(const QString& query);
bool exec();
-
-private:
- QPSQLResultPrivate *d;
};
+class QPSQLDriverPrivate;
+
class Q_EXPORT_SQLDRIVER_PSQL QPSQLDriver : public QSqlDriver
{
+ friend class QPSQLResultPrivate;
+ Q_DECLARE_PRIVATE(QPSQLDriver)
+
Q_OBJECT
public:
enum Protocol {
@@ -150,14 +156,8 @@ protected:
private Q_SLOTS:
void _q_handleNotification(int);
-
-private:
- void init();
- QPSQLDriverPrivate *d;
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQL_PSQL_H
diff --git a/src/sql/drivers/sqlite/qsql_sqlite.cpp b/src/sql/drivers/sqlite/qsql_sqlite.cpp
index f11279f262..ffeb7921b3 100644
--- a/src/sql/drivers/sqlite/qsql_sqlite.cpp
+++ b/src/sql/drivers/sqlite/qsql_sqlite.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include "qsql_sqlite.h"
+#include "qsql_sqlite_p.h"
#include <qcoreapplication.h>
#include <qvariant.h>
@@ -47,6 +47,8 @@
#include <qsqlfield.h>
#include <qsqlindex.h>
#include <qsqlquery.h>
+#include <QtSql/private/qsqlcachedresult_p.h>
+#include <QtSql/private/qsqldriver_p.h>
#include <qstringlist.h>
#include <qvector.h>
#include <qdebug.h>
@@ -67,7 +69,7 @@ Q_DECLARE_METATYPE(sqlite3_stmt*)
QT_BEGIN_NAMESPACE
-static QString _q_escapeIdentifier(const QString &identifier)
+static QString _q_escapeIdentifier(const QString &identifier)
{
QString res = identifier;
if(!identifier.isEmpty() && identifier.left(1) != QString(QLatin1Char('"')) && identifier.right(1) != QString(QLatin1Char('"')) ) {
@@ -106,10 +108,37 @@ static QSqlError qMakeError(sqlite3 *access, const QString &descr, QSqlError::Er
type, errorCode);
}
-class QSQLiteDriverPrivate
+class QSQLiteResultPrivate;
+
+class QSQLiteResult : public QSqlCachedResult
+{
+ friend class QSQLiteDriver;
+ friend class QSQLiteResultPrivate;
+public:
+ explicit QSQLiteResult(const QSQLiteDriver* db);
+ ~QSQLiteResult();
+ QVariant handle() const;
+
+protected:
+ bool gotoNext(QSqlCachedResult::ValueCache& row, int idx);
+ bool reset(const QString &query);
+ bool prepare(const QString &query);
+ bool exec();
+ int size();
+ int numRowsAffected();
+ QVariant lastInsertId() const;
+ QSqlRecord record() const;
+ void detachFromResultSet();
+ void virtual_hook(int id, void *data);
+
+private:
+ QSQLiteResultPrivate* d;
+};
+
+class QSQLiteDriverPrivate : public QSqlDriverPrivate
{
public:
- inline QSQLiteDriverPrivate() : access(0) {}
+ inline QSQLiteDriverPrivate() : QSqlDriverPrivate(), access(0) { dbmsType = SQLite; }
sqlite3 *access;
QList <QSQLiteResult *> results;
};
@@ -206,8 +235,7 @@ void QSQLiteResultPrivate::initColumns(bool emptyResultset)
}
}
- int dotIdx = colName.lastIndexOf(QLatin1Char('.'));
- QSqlField fld(colName.mid(dotIdx == -1 ? 0 : dotIdx + 1), fieldType);
+ QSqlField fld(colName, fieldType);
fld.setSqlType(stp);
rInf.append(fld);
}
@@ -318,15 +346,15 @@ QSQLiteResult::QSQLiteResult(const QSQLiteDriver* db)
: QSqlCachedResult(db)
{
d = new QSQLiteResultPrivate(this);
- d->access = db->d->access;
- db->d->results.append(this);
+ d->access = db->d_func()->access;
+ const_cast<QSQLiteDriverPrivate*>(db->d_func())->results.append(this);
}
QSQLiteResult::~QSQLiteResult()
{
const QSqlDriver *sqlDriver = driver();
if (sqlDriver)
- qobject_cast<const QSQLiteDriver *>(sqlDriver)->d->results.removeOne(this);
+ const_cast<QSQLiteDriverPrivate*>(qobject_cast<const QSQLiteDriver *>(sqlDriver)->d_func())->results.removeOne(this);
d->cleanup();
delete d;
}
@@ -502,15 +530,14 @@ QVariant QSQLiteResult::handle() const
/////////////////////////////////////////////////////////
QSQLiteDriver::QSQLiteDriver(QObject * parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QSQLiteDriverPrivate, parent)
{
- d = new QSQLiteDriverPrivate();
}
QSQLiteDriver::QSQLiteDriver(sqlite3 *connection, QObject *parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QSQLiteDriverPrivate, parent)
{
- d = new QSQLiteDriverPrivate();
+ Q_D(QSQLiteDriver);
d->access = connection;
setOpen(true);
setOpenError(false);
@@ -519,7 +546,6 @@ QSQLiteDriver::QSQLiteDriver(sqlite3 *connection, QObject *parent)
QSQLiteDriver::~QSQLiteDriver()
{
- delete d;
}
bool QSQLiteDriver::hasFeature(DriverFeature f) const
@@ -552,6 +578,7 @@ bool QSQLiteDriver::hasFeature(DriverFeature f) const
*/
bool QSQLiteDriver::open(const QString & db, const QString &, const QString &, const QString &, int, const QString &conOpts)
{
+ Q_D(QSQLiteDriver);
if (isOpen())
close();
@@ -595,6 +622,7 @@ bool QSQLiteDriver::open(const QString & db, const QString &, const QString &, c
void QSQLiteDriver::close()
{
+ Q_D(QSQLiteDriver);
if (isOpen()) {
foreach (QSQLiteResult *result, d->results) {
result->d->finalize();
@@ -751,6 +779,7 @@ QSqlRecord QSQLiteDriver::record(const QString &tbl) const
QVariant QSQLiteDriver::handle() const
{
+ Q_D(const QSQLiteDriver);
return QVariant::fromValue(d->access);
}
diff --git a/src/sql/drivers/sqlite/qsql_sqlite.pri b/src/sql/drivers/sqlite/qsql_sqlite.pri
index a2e80d4c74..e323f2eba5 100644
--- a/src/sql/drivers/sqlite/qsql_sqlite.pri
+++ b/src/sql/drivers/sqlite/qsql_sqlite.pri
@@ -1,4 +1,4 @@
-HEADERS += $$PWD/qsql_sqlite.h
+HEADERS += $$PWD/qsql_sqlite_p.h
SOURCES += $$PWD/qsql_sqlite.cpp
!system-sqlite:!contains(LIBS, .*sqlite3.*) {
diff --git a/src/sql/drivers/sqlite/qsql_sqlite.h b/src/sql/drivers/sqlite/qsql_sqlite_p.h
index 0fdcd4e240..526dd9a22a 100644
--- a/src/sql/drivers/sqlite/qsql_sqlite.h
+++ b/src/sql/drivers/sqlite/qsql_sqlite_p.h
@@ -42,9 +42,19 @@
#ifndef QSQL_SQLITE_H
#define QSQL_SQLITE_H
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists purely as an
+// implementation detail. This header file may change from version to
+// version without notice, or even be removed.
+//
+// We mean it.
+//
+
#include <QtSql/qsqldriver.h>
#include <QtSql/qsqlresult.h>
-#include <QtSql/private/qsqlcachedresult_p.h>
struct sqlite3;
@@ -54,46 +64,14 @@ struct sqlite3;
#define Q_EXPORT_SQLDRIVER_SQLITE Q_SQL_EXPORT
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
-#if 0
-#pragma qt_no_master_include
-#pragma qt_sync_stop_processing
-#endif
-
class QSQLiteDriverPrivate;
-class QSQLiteResultPrivate;
class QSQLiteDriver;
-class QSQLiteResult : public QSqlCachedResult
-{
- friend class QSQLiteDriver;
- friend class QSQLiteResultPrivate;
-public:
- explicit QSQLiteResult(const QSQLiteDriver* db);
- ~QSQLiteResult();
- QVariant handle() const;
-
-protected:
- bool gotoNext(QSqlCachedResult::ValueCache& row, int idx);
- bool reset(const QString &query);
- bool prepare(const QString &query);
- bool exec();
- int size();
- int numRowsAffected();
- QVariant lastInsertId() const;
- QSqlRecord record() const;
- void detachFromResultSet();
- void virtual_hook(int id, void *data);
-
-private:
- QSQLiteResultPrivate* d;
-};
-
class Q_EXPORT_SQLDRIVER_SQLITE QSQLiteDriver : public QSqlDriver
{
+ Q_DECLARE_PRIVATE(QSQLiteDriver)
Q_OBJECT
friend class QSQLiteResult;
public:
@@ -118,13 +96,8 @@ public:
QSqlIndex primaryIndex(const QString &table) const;
QVariant handle() const;
QString escapeIdentifier(const QString &identifier, IdentifierType) const;
-
-private:
- QSQLiteDriverPrivate* d;
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQL_SQLITE_H
diff --git a/src/sql/drivers/sqlite2/qsql_sqlite2.cpp b/src/sql/drivers/sqlite2/qsql_sqlite2.cpp
index 02e4004901..7e56d5cc17 100644
--- a/src/sql/drivers/sqlite2/qsql_sqlite2.cpp
+++ b/src/sql/drivers/sqlite2/qsql_sqlite2.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include "qsql_sqlite2.h"
+#include "qsql_sqlite2_p.h"
#include <qcoreapplication.h>
#include <qvariant.h>
@@ -50,6 +50,8 @@
#include <qsqlfield.h>
#include <qsqlindex.h>
#include <qsqlquery.h>
+#include <QtSql/private/qsqlcachedresult_p.h>
+#include <QtSql/private/qsqldriver_p.h>
#include <qstringlist.h>
#include <qvector.h>
@@ -81,7 +83,7 @@ static QVariant::Type nameToType(const QString& typeName)
return QVariant::String;
}
-class QSQLite2DriverPrivate
+class QSQLite2DriverPrivate : public QSqlDriverPrivate
{
public:
QSQLite2DriverPrivate();
@@ -89,11 +91,36 @@ public:
bool utf8;
};
-QSQLite2DriverPrivate::QSQLite2DriverPrivate() : access(0)
+QSQLite2DriverPrivate::QSQLite2DriverPrivate() : QSqlDriverPrivate(), access(0)
{
utf8 = (qstrcmp(sqlite_encoding, "UTF-8") == 0);
+ dbmsType = SQLite;
}
+class QSQLite2ResultPrivate;
+
+class QSQLite2Result : public QSqlCachedResult
+{
+ friend class QSQLite2Driver;
+ friend class QSQLite2ResultPrivate;
+public:
+ explicit QSQLite2Result(const QSQLite2Driver* db);
+ ~QSQLite2Result();
+ QVariant handle() const;
+
+protected:
+ bool gotoNext(QSqlCachedResult::ValueCache& row, int idx);
+ bool reset (const QString& query);
+ int size();
+ int numRowsAffected();
+ QSqlRecord record() const;
+ void detachFromResultSet();
+ void virtual_hook(int id, void *data);
+
+private:
+ QSQLite2ResultPrivate* d;
+};
+
class QSQLite2ResultPrivate
{
public:
@@ -170,7 +197,7 @@ void QSQLite2ResultPrivate::init(const char **cnames, int numCols)
for (int i = 0; i < numCols; ++i) {
const char* lastDot = strrchr(cnames[i], '.');
const char* fieldName = lastDot ? lastDot + 1 : cnames[i];
-
+
//remove quotations around the field name if any
QString fieldStr = QString::fromLatin1(fieldName);
QLatin1Char quote('\"');
@@ -219,7 +246,7 @@ bool QSQLite2ResultPrivate::fetchNext(QSqlCachedResult::ValueCache &values, int
firstRow.clear();
firstRow.resize(colNum);
}
-
+
switch(res) {
case SQLITE_ROW:
// check to see if should fill out columns
@@ -254,8 +281,8 @@ QSQLite2Result::QSQLite2Result(const QSQLite2Driver* db)
: QSqlCachedResult(db)
{
d = new QSQLite2ResultPrivate(this);
- d->access = db->d->access;
- d->utf8 = db->d->utf8;
+ d->access = db->d_func()->access;
+ d->utf8 = db->d_func()->utf8;
}
QSQLite2Result::~QSQLite2Result()
@@ -349,16 +376,15 @@ QVariant QSQLite2Result::handle() const
/////////////////////////////////////////////////////////
-QSQLite2Driver::QSQLite2Driver(QObject * parent)
- : QSqlDriver(parent)
+QSQLite2Driver::QSQLite2Driver(QObject *parent)
+ : QSqlDriver(*new QSQLite2DriverPrivate, parent)
{
- d = new QSQLite2DriverPrivate();
}
QSQLite2Driver::QSQLite2Driver(sqlite *connection, QObject *parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QSQLite2DriverPrivate, parent)
{
- d = new QSQLite2DriverPrivate();
+ Q_D(QSQLite2Driver);
d->access = connection;
setOpen(true);
setOpenError(false);
@@ -367,11 +393,11 @@ QSQLite2Driver::QSQLite2Driver(sqlite *connection, QObject *parent)
QSQLite2Driver::~QSQLite2Driver()
{
- delete d;
}
bool QSQLite2Driver::hasFeature(DriverFeature f) const
{
+ Q_D(const QSQLite2Driver);
switch (f) {
case Transactions:
case SimpleLocking:
@@ -389,6 +415,7 @@ bool QSQLite2Driver::hasFeature(DriverFeature f) const
*/
bool QSQLite2Driver::open(const QString & db, const QString &, const QString &, const QString &, int, const QString &)
{
+ Q_D(QSQLite2Driver);
if (isOpen())
close();
@@ -415,6 +442,7 @@ bool QSQLite2Driver::open(const QString & db, const QString &, const QString &,
void QSQLite2Driver::close()
{
+ Q_D(QSQLite2Driver);
if (isOpen()) {
sqlite_close(d->access);
d->access = 0;
@@ -430,6 +458,7 @@ QSqlResult *QSQLite2Driver::createResult() const
bool QSQLite2Driver::beginTransaction()
{
+ Q_D(QSQLite2Driver);
if (!isOpen() || isOpenError())
return false;
@@ -447,6 +476,7 @@ bool QSQLite2Driver::beginTransaction()
bool QSQLite2Driver::commitTransaction()
{
+ Q_D(QSQLite2Driver);
if (!isOpen() || isOpenError())
return false;
@@ -464,6 +494,7 @@ bool QSQLite2Driver::commitTransaction()
bool QSQLite2Driver::rollbackTransaction()
{
+ Q_D(QSQLite2Driver);
if (!isOpen() || isOpenError())
return false;
@@ -560,6 +591,7 @@ QSqlRecord QSQLite2Driver::record(const QString &tbl) const
QVariant QSQLite2Driver::handle() const
{
+ Q_D(const QSQLite2Driver);
return QVariant::fromValue(d->access);
}
diff --git a/src/sql/drivers/sqlite2/qsql_sqlite2.pri b/src/sql/drivers/sqlite2/qsql_sqlite2.pri
index 9a9f6cdf9e..5baba30db0 100644
--- a/src/sql/drivers/sqlite2/qsql_sqlite2.pri
+++ b/src/sql/drivers/sqlite2/qsql_sqlite2.pri
@@ -1,4 +1,4 @@
-HEADERS += $$PWD/qsql_sqlite2.h
+HEADERS += $$PWD/qsql_sqlite2_p.h
SOURCES += $$PWD/qsql_sqlite2.cpp
!contains(LIBS, .*sqlite.*):LIBS += -lsqlite
diff --git a/src/sql/drivers/sqlite2/qsql_sqlite2.h b/src/sql/drivers/sqlite2/qsql_sqlite2_p.h
index f141ad1cc2..ae38a662ac 100644
--- a/src/sql/drivers/sqlite2/qsql_sqlite2.h
+++ b/src/sql/drivers/sqlite2/qsql_sqlite2_p.h
@@ -42,11 +42,21 @@
#ifndef QSQL_SQLITE2_H
#define QSQL_SQLITE2_H
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists purely as an
+// implementation detail. This header file may change from version to
+// version without notice, or even be removed.
+//
+// We mean it.
+//
+
#include <QtSql/qsqldriver.h>
#include <QtSql/qsqlresult.h>
#include <QtSql/qsqlrecord.h>
#include <QtSql/qsqlindex.h>
-#include <QtSql/private/qsqlcachedresult_p.h>
#if defined (Q_OS_WIN32)
# include <QtCore/qt_windows.h>
@@ -54,45 +64,16 @@
struct sqlite;
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
-#if 0
-#pragma qt_no_master_include
-#pragma qt_sync_stop_processing
-#endif
-
class QSQLite2DriverPrivate;
-class QSQLite2ResultPrivate;
class QSQLite2Driver;
-class QSQLite2Result : public QSqlCachedResult
-{
- friend class QSQLite2Driver;
- friend class QSQLite2ResultPrivate;
-public:
- explicit QSQLite2Result(const QSQLite2Driver* db);
- ~QSQLite2Result();
- QVariant handle() const;
-
-protected:
- bool gotoNext(QSqlCachedResult::ValueCache& row, int idx);
- bool reset (const QString& query);
- int size();
- int numRowsAffected();
- QSqlRecord record() const;
- void detachFromResultSet();
- void virtual_hook(int id, void *data);
-
-private:
- QSQLite2ResultPrivate* d;
-};
-
class QSQLite2Driver : public QSqlDriver
{
- Q_OBJECT
friend class QSQLite2Result;
+ Q_DECLARE_PRIVATE(QSQLite2Driver)
+ Q_OBJECT
public:
explicit QSQLite2Driver(QObject *parent = 0);
explicit QSQLite2Driver(sqlite *connection, QObject *parent = 0);
@@ -120,13 +101,8 @@ public:
QSqlIndex primaryIndex(const QString &table) const;
QVariant handle() const;
QString escapeIdentifier(const QString &identifier, IdentifierType) const;
-
-private:
- QSQLite2DriverPrivate* d;
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQL_SQLITE2_H
diff --git a/src/sql/drivers/tds/qsql_tds.cpp b/src/sql/drivers/tds/qsql_tds.cpp
index 45bba42ca7..69534fe380 100644
--- a/src/sql/drivers/tds/qsql_tds.cpp
+++ b/src/sql/drivers/tds/qsql_tds.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include "qsql_tds.h"
+#include "qsql_tds_p.h"
#include <qglobal.h>
#ifdef Q_OS_WIN32 // We assume that MS SQL Server is used. Set Q_USE_SYBASE to force Sybase.
@@ -58,6 +58,8 @@
#include <qsqlfield.h>
#include <qsqlindex.h>
#include <qsqlquery.h>
+#include <QtSql/private/qsqlcachedresult_p.h>
+#include <QtSql/private/qsqldriver_p.h>
#include <qstringlist.h>
#include <qvector.h>
@@ -135,16 +137,43 @@ QSqlError qMakeError(const QString& err, QSqlError::ErrorType type, int errNo =
return QSqlError(QLatin1String("QTDS: ") + err, QString(), type, errNo);
}
-class QTDSDriverPrivate
+class QTDSDriverPrivate : public QSqlDriverPrivate
{
public:
- QTDSDriverPrivate(): login(0), initialized(false) {}
+ QTDSDriverPrivate() : QSqlDriverPrivate(), login(0), initialized(false) { dbmsType = Sybase; }
LOGINREC* login; // login information
QString hostName;
QString db;
bool initialized;
};
+struct QTDSColumnData
+{
+ void *data;
+ DBINT nullbind;
+};
+Q_DECLARE_TYPEINFO(QTDSColumnData, Q_MOVABLE_TYPE);
+
+class QTDSResultPrivate;
+
+class QTDSResult : public QSqlCachedResult
+{
+public:
+ explicit QTDSResult(const QTDSDriver* db);
+ ~QTDSResult();
+ QVariant handle() const;
+
+protected:
+ void cleanup();
+ bool reset (const QString& query);
+ int size();
+ int numRowsAffected();
+ bool gotoNext(QSqlCachedResult::ValueCache &values, int index);
+ QSqlRecord record() const;
+
+private:
+ QTDSResultPrivate* d;
+};
class QTDSResultPrivate
{
@@ -156,7 +185,7 @@ public:
void addErrorMsg(QString& errMsg) { errorMsgs.append(errMsg); }
QString getErrorMsgs() { return errorMsgs.join(QLatin1String("\n")); }
void clearErrorMsgs() { errorMsgs.clear(); }
- QVector<void *> buffer;
+ QVector<QTDSColumnData> buffer;
QSqlRecord rec;
private:
@@ -298,12 +327,12 @@ QTDSResult::QTDSResult(const QTDSDriver* db)
: QSqlCachedResult(db)
{
d = new QTDSResultPrivate();
- d->login = db->d->login;
+ d->login = db->d_func()->login;
- d->dbproc = dbopen(d->login, const_cast<char*>(db->d->hostName.toLatin1().constData()));
+ d->dbproc = dbopen(d->login, const_cast<char*>(db->d_func()->hostName.toLatin1().constData()));
if (!d->dbproc)
return;
- if (dbuse(d->dbproc, const_cast<char*>(db->d->db.toLatin1().constData())) == FAIL)
+ if (dbuse(d->dbproc, const_cast<char*>(db->d_func()->db.toLatin1().constData())) == FAIL)
return;
// insert d in error handler dict
@@ -325,8 +354,8 @@ void QTDSResult::cleanup()
{
d->clearErrorMsgs();
d->rec.clear();
- for (int i = 0; i < d->buffer.size() / 2; ++i)
- free(d->buffer.at(i * 2));
+ for (int i = 0; i < d->buffer.size(); ++i)
+ free(d->buffer.at(i).data);
d->buffer.clear();
// "can" stands for "cancel"... very clever.
dbcanquery(d->dbproc);
@@ -340,9 +369,9 @@ QVariant QTDSResult::handle() const
return QVariant(qRegisterMetaType<DBPROCESS *>("DBPROCESS*"), &d->dbproc);
}
-static inline bool qIsNull(const void *ind)
+static inline bool qIsNull(const QTDSColumnData &p)
{
- return *reinterpret_cast<const DBINT *>(&ind) == -1;
+ return p.nullbind == -1;
}
bool QTDSResult::gotoNext(QSqlCachedResult::ValueCache &values, int index)
@@ -364,33 +393,33 @@ bool QTDSResult::gotoNext(QSqlCachedResult::ValueCache &values, int index)
int idx = index + i;
switch (d->rec.field(i).type()) {
case QVariant::DateTime:
- if (qIsNull(d->buffer.at(i * 2 + 1))) {
+ if (qIsNull(d->buffer.at(i))) {
values[idx] = QVariant(QVariant::DateTime);
} else {
- DBDATETIME *bdt = (DBDATETIME*) d->buffer.at(i * 2);
+ DBDATETIME *bdt = (DBDATETIME*) d->buffer.at(i).data;
QDate date = QDate::fromString(QLatin1String("1900-01-01"), Qt::ISODate);
QTime time = QTime::fromString(QLatin1String("00:00:00"), Qt::ISODate);
values[idx] = QDateTime(date.addDays(bdt->dtdays), time.addMSecs(int(bdt->dttime / 0.3)));
}
break;
case QVariant::Int:
- if (qIsNull(d->buffer.at(i * 2 + 1)))
+ if (qIsNull(d->buffer.at(i)))
values[idx] = QVariant(QVariant::Int);
else
- values[idx] = *((int*)d->buffer.at(i * 2));
+ values[idx] = *((int*)d->buffer.at(i).data);
break;
case QVariant::Double:
case QVariant::String:
- if (qIsNull(d->buffer.at(i * 2 + 1)))
+ if (qIsNull(d->buffer.at(i)))
values[idx] = QVariant(QVariant::String);
else
- values[idx] = QString::fromLocal8Bit((const char*)d->buffer.at(i * 2)).trimmed();
+ values[idx] = QString::fromLocal8Bit((const char*)d->buffer.at(i).data).trimmed();
break;
case QVariant::ByteArray: {
- if (qIsNull(d->buffer.at(i * 2 + 1)))
+ if (qIsNull(d->buffer.at(i)))
values[idx] = QVariant(QVariant::ByteArray);
else
- values[idx] = QByteArray((const char*)d->buffer.at(i * 2));
+ values[idx] = QByteArray((const char*)d->buffer.at(i).data);
break;
}
default:
@@ -430,7 +459,7 @@ bool QTDSResult::reset (const QString& query)
setSelect((DBCMDROW(d->dbproc) == SUCCEED)); // decide whether or not we are dealing with a SELECT query
int numCols = dbnumcols(d->dbproc);
if (numCols > 0) {
- d->buffer.resize(numCols * 2);
+ d->buffer.resize(numCols);
init(numCols);
}
for (int i = 0; i < numCols; ++i) {
@@ -470,11 +499,11 @@ bool QTDSResult::reset (const QString& query)
break;
}
if (ret == SUCCEED) {
- d->buffer[i * 2] = p;
- ret = dbnullbind(d->dbproc, i+1, (DBINT*)(&d->buffer[i * 2 + 1]));
+ d->buffer[i].data = p;
+ ret = dbnullbind(d->dbproc, i+1, &d->buffer[i].nullbind);
} else {
- d->buffer[i * 2] = 0;
- d->buffer[i * 2 + 1] = 0;
+ d->buffer[i].data = 0;
+ d->buffer[i].nullbind = 0;
free(p);
}
if ((ret != SUCCEED) && (ret != -1)) {
@@ -512,14 +541,15 @@ QSqlRecord QTDSResult::record() const
///////////////////////////////////////////////////////////////////
QTDSDriver::QTDSDriver(QObject* parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QTDSDriverPrivate, parent)
{
init();
}
QTDSDriver::QTDSDriver(LOGINREC* rec, const QString& host, const QString &db, QObject* parent)
- : QSqlDriver(parent)
+ : QSqlDriver(*new QTDSDriverPrivate, parent)
{
+ Q_D(QTDSDriver);
init();
d->login = rec;
d->hostName = host;
@@ -532,12 +562,13 @@ QTDSDriver::QTDSDriver(LOGINREC* rec, const QString& host, const QString &db, QO
QVariant QTDSDriver::handle() const
{
+ Q_D(const QTDSDriver);
return QVariant(qRegisterMetaType<LOGINREC *>("LOGINREC*"), &d->login);
}
void QTDSDriver::init()
{
- d = new QTDSDriverPrivate();
+ Q_D(QTDSDriver);
d->initialized = (dbinit() == SUCCEED);
// the following two code-lines will fail compilation on some FreeTDS versions
// just comment them out if you have FreeTDS (you won't get any errors and warnings then)
@@ -551,7 +582,6 @@ QTDSDriver::~QTDSDriver()
dbmsghandle(0);
// dbexit also calls dbclose if necessary
dbexit();
- delete d;
}
bool QTDSDriver::hasFeature(DriverFeature f) const
@@ -578,6 +608,7 @@ bool QTDSDriver::open(const QString & db,
int /*port*/,
const QString& /*connOpts*/)
{
+ Q_D(QTDSDriver);
if (isOpen())
close();
if (!d->initialized) {
@@ -617,6 +648,7 @@ bool QTDSDriver::open(const QString & db,
void QTDSDriver::close()
{
+ Q_D(QTDSDriver);
if (isOpen()) {
#ifdef Q_USE_SYBASE
dbloginfree(d->login);
diff --git a/src/sql/drivers/tds/qsql_tds.pri b/src/sql/drivers/tds/qsql_tds.pri
index 38aab2f3e4..67d037aa6b 100644
--- a/src/sql/drivers/tds/qsql_tds.pri
+++ b/src/sql/drivers/tds/qsql_tds.pri
@@ -1,4 +1,4 @@
-HEADERS += $$PWD/qsql_tds.h
+HEADERS += $$PWD/qsql_tds_p.h
SOURCES += $$PWD/qsql_tds.cpp
unix|win32-g++*: {
diff --git a/src/sql/drivers/tds/qsql_tds.h b/src/sql/drivers/tds/qsql_tds_p.h
index 38cb2dc42e..dd7088a167 100644
--- a/src/sql/drivers/tds/qsql_tds.h
+++ b/src/sql/drivers/tds/qsql_tds_p.h
@@ -42,9 +42,19 @@
#ifndef QSQL_TDS_H
#define QSQL_TDS_H
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists purely as an
+// implementation detail. This header file may change from version to
+// version without notice, or even be removed.
+//
+// We mean it.
+//
+
#include <QtSql/qsqlresult.h>
#include <QtSql/qsqldriver.h>
-#include <QtSql/private/qsqlcachedresult_p.h>
#ifdef Q_OS_WIN32
#define WIN32_LEAN_AND_MEAN
@@ -67,40 +77,14 @@
#define Q_EXPORT_SQLDRIVER_TDS Q_SQL_EXPORT
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
-#if 0
-#pragma qt_no_master_include
-#pragma qt_sync_stop_processing
-#endif
-
class QTDSDriverPrivate;
-class QTDSResultPrivate;
class QTDSDriver;
-class QTDSResult : public QSqlCachedResult
-{
-public:
- explicit QTDSResult(const QTDSDriver* db);
- ~QTDSResult();
- QVariant handle() const;
-
-protected:
- void cleanup();
- bool reset (const QString& query);
- int size();
- int numRowsAffected();
- bool gotoNext(QSqlCachedResult::ValueCache &values, int index);
- QSqlRecord record() const;
-
-private:
- QTDSResultPrivate* d;
-};
-
class Q_EXPORT_SQLDRIVER_TDS QTDSDriver : public QSqlDriver
{
+ Q_DECLARE_PRIVATE(QTDSDriver)
Q_OBJECT
friend class QTDSResult;
public:
@@ -132,11 +116,8 @@ protected:
bool rollbackTransaction();
private:
void init();
- QTDSDriverPrivate *d;
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQL_TDS_H
diff --git a/src/sql/kernel/kernel.pri b/src/sql/kernel/kernel.pri
index fe7f1270f9..dad3b46781 100644
--- a/src/sql/kernel/kernel.pri
+++ b/src/sql/kernel/kernel.pri
@@ -4,6 +4,7 @@ HEADERS += kernel/qsql.h \
kernel/qsqlfield.h \
kernel/qsqlrecord.h \
kernel/qsqldriver.h \
+ kernel/qsqldriver_p.h \
kernel/qsqlnulldriver_p.h \
kernel/qsqldriverplugin.h \
kernel/qsqlerror.h \
diff --git a/src/sql/kernel/qsql.h b/src/sql/kernel/qsql.h
index 54c5fc13b6..9b9381f797 100644
--- a/src/sql/kernel/qsql.h
+++ b/src/sql/kernel/qsql.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#ifndef QT_STATIC
@@ -97,6 +95,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QSql::ParamType)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQL_H
diff --git a/src/sql/kernel/qsqldatabase.cpp b/src/sql/kernel/qsqldatabase.cpp
index 36422f5f62..0ca79fd39f 100644
--- a/src/sql/kernel/qsqldatabase.cpp
+++ b/src/sql/kernel/qsqldatabase.cpp
@@ -48,31 +48,31 @@
#endif
#ifdef QT_SQL_PSQL
-#include "../drivers/psql/qsql_psql.h"
+#include "../drivers/psql/qsql_psql_p.h"
#endif
#ifdef QT_SQL_MYSQL
-#include "../drivers/mysql/qsql_mysql.h"
+#include "../drivers/mysql/qsql_mysql_p.h"
#endif
#ifdef QT_SQL_ODBC
-#include "../drivers/odbc/qsql_odbc.h"
+#include "../drivers/odbc/qsql_odbc_p.h"
#endif
#ifdef QT_SQL_OCI
-#include "../drivers/oci/qsql_oci.h"
+#include "../drivers/oci/qsql_oci_p.h"
#endif
#ifdef QT_SQL_TDS
// conflicting RETCODE typedef between odbc and freetds
#define RETCODE DBRETCODE
-#include "../drivers/tds/qsql_tds.h"
+#include "../drivers/tds/qsql_tds_p.h"
#undef RETCODE
#endif
#ifdef QT_SQL_DB2
-#include "../drivers/db2/qsql_db2.h"
+#include "../drivers/db2/qsql_db2_p.h"
#endif
#ifdef QT_SQL_SQLITE
-#include "../drivers/sqlite/qsql_sqlite.h"
+#include "../drivers/sqlite/qsql_sqlite_p.h"
#endif
#ifdef QT_SQL_SQLITE2
-#include "../drivers/sqlite2/qsql_sqlite2.h"
+#include "../drivers/sqlite2/qsql_sqlite2_p.h"
#endif
#ifdef QT_SQL_IBASE
#undef SQL_FLOAT // avoid clash with ODBC
@@ -82,7 +82,7 @@
#undef SQL_TYPE_DATE
#undef SQL_DATE
#define SCHAR IBASE_SCHAR // avoid clash with ODBC (older versions of ibase.h with Firebird)
-#include "../drivers/ibase/qsql_ibase.h"
+#include "../drivers/ibase/qsql_ibase_p.h"
#undef SCHAR
#endif
diff --git a/src/sql/kernel/qsqldatabase.h b/src/sql/kernel/qsqldatabase.h
index f0e920ade1..7249e223a5 100644
--- a/src/sql/kernel/qsqldatabase.h
+++ b/src/sql/kernel/qsqldatabase.h
@@ -45,8 +45,6 @@
#include <QtCore/qstring.h>
#include <QtSql/qsql.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -146,6 +144,4 @@ Q_SQL_EXPORT QDebug operator<<(QDebug, const QSqlDatabase &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQLDATABASE_H
diff --git a/src/sql/kernel/qsqldriver.cpp b/src/sql/kernel/qsqldriver.cpp
index 690525f8ca..63b90f27c6 100644
--- a/src/sql/kernel/qsqldriver.cpp
+++ b/src/sql/kernel/qsqldriver.cpp
@@ -46,6 +46,7 @@
#include "qsqlfield.h"
#include "qsqlindex.h"
#include "private/qobject_p.h"
+#include "private/qsqldriver_p.h"
QT_BEGIN_NAMESPACE
@@ -60,30 +61,6 @@ static QString prepareIdentifier(const QString &identifier,
return ret;
}
-class QSqlDriverPrivate : public QObjectPrivate
-{
-public:
- QSqlDriverPrivate();
- virtual ~QSqlDriverPrivate();
-
-public:
- // @CHECK: this member is never used. It was named q, which expanded to q_func().
- QSqlDriver *q_func();
- uint isOpen : 1;
- uint isOpenError : 1;
- QSqlError error;
- QSql::NumericalPrecisionPolicy precisionPolicy;
-};
-
-inline QSqlDriverPrivate::QSqlDriverPrivate()
- : QObjectPrivate(), isOpen(false), isOpenError(false), precisionPolicy(QSql::LowPrecisionDouble)
-{
-}
-
-QSqlDriverPrivate::~QSqlDriverPrivate()
-{
-}
-
/*!
\class QSqlDriver
\brief The QSqlDriver class is an abstract base class for accessing
@@ -111,6 +88,13 @@ QSqlDriver::QSqlDriver(QObject *parent)
{
}
+/*! \internal
+*/
+QSqlDriver::QSqlDriver(QSqlDriverPrivate &dd, QObject *parent)
+ : QObject(dd, parent)
+{
+}
+
/*!
Destroys the object and frees any allocated resources.
*/
diff --git a/src/sql/kernel/qsqldriver.h b/src/sql/kernel/qsqldriver.h
index aaa879e957..017ffd4e4a 100644
--- a/src/sql/kernel/qsqldriver.h
+++ b/src/sql/kernel/qsqldriver.h
@@ -47,8 +47,6 @@
#include <QtCore/qstringlist.h>
#include <QtSql/qsql.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -128,6 +126,7 @@ Q_SIGNALS:
void notification(const QString &name, QSqlDriver::NotificationSource source, const QVariant &payload);
protected:
+ QSqlDriver(QSqlDriverPrivate &dd, QObject *parent = 0);
virtual void setOpen(bool o);
virtual void setOpenError(bool e);
virtual void setLastError(const QSqlError& e);
@@ -139,6 +138,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQLDRIVER_H
diff --git a/src/sql/kernel/qsqldriver_p.h b/src/sql/kernel/qsqldriver_p.h
new file mode 100644
index 0000000000..05570e584c
--- /dev/null
+++ b/src/sql/kernel/qsqldriver_p.h
@@ -0,0 +1,86 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtSql module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QSQLDRIVER_P_H
+#define QSQLDRIVER_P_H
+
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists for the convenience
+// of the QtSQL module. This header file may change from version to version
+// without notice, or even be removed.
+//
+// We mean it.
+//
+
+#include "private/qobject_p.h"
+#include "qsqldriver.h"
+#include "qsqlerror.h"
+
+QT_BEGIN_NAMESPACE
+
+class QSqlDriverPrivate : public QObjectPrivate
+{
+ Q_DECLARE_PUBLIC(QSqlDriver)
+
+public:
+ enum DBMSType {UnknownDB, MSSqlServer, MySqlServer, PostgreSQL, Oracle, Sybase, SQLite, Interbase, DB2};
+
+ QSqlDriverPrivate()
+ : QObjectPrivate(),
+ isOpen(false),
+ isOpenError(false),
+ precisionPolicy(QSql::LowPrecisionDouble),
+ dbmsType(UnknownDB)
+ { }
+
+ uint isOpen;
+ uint isOpenError;
+ QSqlError error;
+ QSql::NumericalPrecisionPolicy precisionPolicy;
+ DBMSType dbmsType;
+};
+
+QT_END_NAMESPACE
+
+#endif // QSQLDRIVER_P_H
diff --git a/src/sql/kernel/qsqldriverplugin.h b/src/sql/kernel/qsqldriverplugin.h
index a111c1257a..ca2e0f2474 100644
--- a/src/sql/kernel/qsqldriverplugin.h
+++ b/src/sql/kernel/qsqldriverplugin.h
@@ -46,8 +46,6 @@
#include <QtCore/qfactoryinterface.h>
#include <QtSql/qsql.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -68,6 +66,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQLDRIVERPLUGIN_H
diff --git a/src/sql/kernel/qsqlerror.cpp b/src/sql/kernel/qsqlerror.cpp
index adcb8de4d4..9beaf10a32 100644
--- a/src/sql/kernel/qsqlerror.cpp
+++ b/src/sql/kernel/qsqlerror.cpp
@@ -63,9 +63,7 @@ QDebug operator<<(QDebug dbg, const QSqlError &s)
A QSqlError object can provide database-specific error data,
including the driverText() and databaseText() messages (or both
concatenated together as text()), and the error number() and
- type(). The functions all have setters so that you can create and
- return QSqlError objects from your own classes, for example from
- your own SQL drivers.
+ type().
\sa QSqlDatabase::lastError(), QSqlQuery::lastError()
*/
@@ -149,7 +147,7 @@ QSqlError::~QSqlError()
Returns the text of the error as reported by the driver. This may
contain database-specific descriptions. It may also be empty.
- \sa setDriverText(), databaseText(), text()
+ \sa databaseText(), text()
*/
QString QSqlError::driverText() const
{
@@ -157,21 +155,29 @@ QString QSqlError::driverText() const
}
/*!
+ \fn void QSqlError::setDriverText(const QString &driverText)
+ \obsolete
+
Sets the driver error text to the value of \a driverText.
+ Use QSqlError(const QString &driverText, const QString &databaseText,
+ ErrorType type, int number) instead
+
\sa driverText(), setDatabaseText(), text()
*/
+#if QT_DEPRECATED_SINCE(5, 1)
void QSqlError::setDriverText(const QString& driverText)
{
driverError = driverText;
}
+#endif
/*!
Returns the text of the error as reported by the database. This
may contain database-specific descriptions; it may be empty.
- \sa setDatabaseText(), driverText(), text()
+ \sa driverText(), text()
*/
QString QSqlError::databaseText() const
@@ -180,20 +186,26 @@ QString QSqlError::databaseText() const
}
/*!
+ \fn void QSqlError::setDatabaseText(const QString &databaseText)
+ \obsolete
+
Sets the database error text to the value of \a databaseText.
+ Use QSqlError(const QString &driverText, const QString &databaseText,
+ ErrorType type, int number) instead
+
\sa databaseText(), setDriverText(), text()
*/
+#if QT_DEPRECATED_SINCE(5, 1)
void QSqlError::setDatabaseText(const QString& databaseText)
{
databaseError = databaseText;
}
+#endif
/*!
Returns the error type, or -1 if the type cannot be determined.
-
- \sa setType()
*/
QSqlError::ErrorType QSqlError::type() const
@@ -202,21 +214,27 @@ QSqlError::ErrorType QSqlError::type() const
}
/*!
+ \fn void QSqlError::setType(ErrorType type)
+ \obsolete
+
Sets the error type to the value of \a type.
+ Use QSqlError(const QString &driverText, const QString &databaseText,
+ ErrorType type, int number) instead
+
\sa type()
*/
+#if QT_DEPRECATED_SINCE(5, 1)
void QSqlError::setType(ErrorType type)
{
errorType = type;
}
+#endif
/*!
Returns the database-specific error number, or -1 if it cannot be
determined.
-
- \sa setNumber()
*/
int QSqlError::number() const
@@ -225,15 +243,23 @@ int QSqlError::number() const
}
/*!
+ \fn void QSqlError::setNumber(int number)
+ \obsolete
+
Sets the database-specific error number to \a number.
+ Use QSqlError(const QString &driverText, const QString &databaseText,
+ ErrorType type, int number) instead
+
\sa number()
*/
+#if QT_DEPRECATED_SINCE(5, 1)
void QSqlError::setNumber(int number)
{
errorNumber = number;
}
+#endif
/*!
This is a convenience function that returns databaseText() and
diff --git a/src/sql/kernel/qsqlerror.h b/src/sql/kernel/qsqlerror.h
index beab5f27ba..39c4cda958 100644
--- a/src/sql/kernel/qsqlerror.h
+++ b/src/sql/kernel/qsqlerror.h
@@ -45,8 +45,6 @@
#include <QtCore/qstring.h>
#include <QtSql/qsql.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -71,16 +69,19 @@ public:
~QSqlError();
QString driverText() const;
- void setDriverText(const QString& driverText);
QString databaseText() const;
- void setDatabaseText(const QString& databaseText);
ErrorType type() const;
- void setType(ErrorType type);
int number() const;
- void setNumber(int number);
QString text() const;
bool isValid() const;
+#if QT_DEPRECATED_SINCE(5, 1)
+ QT_DEPRECATED void setDriverText(const QString &driverText);
+ QT_DEPRECATED void setDatabaseText(const QString &databaseText);
+ QT_DEPRECATED void setType(ErrorType type);
+ QT_DEPRECATED void setNumber(int number);
+#endif
+
private:
QString driverError;
QString databaseError;
@@ -94,6 +95,4 @@ Q_SQL_EXPORT QDebug operator<<(QDebug, const QSqlError &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQLERROR_H
diff --git a/src/sql/kernel/qsqlfield.h b/src/sql/kernel/qsqlfield.h
index 626cce16ca..a642721039 100644
--- a/src/sql/kernel/qsqlfield.h
+++ b/src/sql/kernel/qsqlfield.h
@@ -46,8 +46,6 @@
#include <QtCore/qstring.h>
#include <QtSql/qsql.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -110,6 +108,4 @@ Q_SQL_EXPORT QDebug operator<<(QDebug, const QSqlField &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQLFIELD_H
diff --git a/src/sql/kernel/qsqlindex.h b/src/sql/kernel/qsqlindex.h
index 83e1f21e9d..96c2f614f1 100644
--- a/src/sql/kernel/qsqlindex.h
+++ b/src/sql/kernel/qsqlindex.h
@@ -46,8 +46,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -78,6 +76,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQLINDEX_H
diff --git a/src/sql/kernel/qsqlquery.cpp b/src/sql/kernel/qsqlquery.cpp
index cac2f1dad4..5b103f1bff 100644
--- a/src/sql/kernel/qsqlquery.cpp
+++ b/src/sql/kernel/qsqlquery.cpp
@@ -325,7 +325,7 @@ bool QSqlQuery::isNull(int field) const
}
/*!
-
+
Executes the SQL in \a query. Returns true and sets the query state
to \l{isActive()}{active} if the query was successful; otherwise
returns false. The \a query string must use syntax appropriate for
@@ -579,7 +579,7 @@ bool QSqlQuery::seek(int index, bool relative)
}
/*!
-
+
Retrieves the next record in the result, if available, and positions
the query on the retrieved record. Note that the result must be in
the \l{isActive()}{active} state and isSelect() must return true
@@ -783,7 +783,7 @@ bool QSqlQuery::isValid() const
}
/*!
-
+
Returns true if the query is \e{active}. An active QSqlQuery is one
that has been \l{QSqlQuery::exec()} {exec()'d} successfully but not
yet finished with. When you are finished with an active query, you
@@ -1143,7 +1143,7 @@ QString QSqlQuery::executedQuery() const
behavior is undefined.
For MySQL databases the row's auto-increment field will be returned.
-
+
\note For this function to work in PSQL, the table table must
contain OIDs, which may not have been created by default. Check the
\c default_with_oids configuration variable to be sure.
@@ -1199,7 +1199,7 @@ QSql::NumericalPrecisionPolicy QSqlQuery::numericalPrecisionPolicy() const
call this function, but it may be helpful in order to free resources
such as locks or cursors if you intend to re-use the query at a
later time.
-
+
Sets the query to inactive. Bound values retain their values.
\sa prepare(), exec(), isActive()
@@ -1216,7 +1216,7 @@ void QSqlQuery::finish()
/*!
\since 4.4
-
+
Discards the current result set and navigates to the next if available.
Some databases are capable of returning multiple result sets for
@@ -1224,7 +1224,7 @@ void QSqlQuery::finish()
multiple statements). If multiple result sets are available after
executing a query this function can be used to navigate to the next
result set(s).
-
+
If a new result set is available this function will return true.
The query will be repositioned on an \e invalid record in the new
result set and must be navigated to a valid record before data
diff --git a/src/sql/kernel/qsqlquery.h b/src/sql/kernel/qsqlquery.h
index 5c14f3808b..3719643174 100644
--- a/src/sql/kernel/qsqlquery.h
+++ b/src/sql/kernel/qsqlquery.h
@@ -46,8 +46,6 @@
#include <QtSql/qsqldatabase.h>
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -122,6 +120,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQLQUERY_H
diff --git a/src/sql/kernel/qsqlrecord.cpp b/src/sql/kernel/qsqlrecord.cpp
index ad6505c096..4cac5028c3 100644
--- a/src/sql/kernel/qsqlrecord.cpp
+++ b/src/sql/kernel/qsqlrecord.cpp
@@ -524,4 +524,19 @@ QDebug operator<<(QDebug dbg, const QSqlRecord &r)
}
#endif
+/*!
+ \since 5.1
+ Returns a record containing the fields represented in \a keyFields set to values
+ that match by field name.
+*/
+QSqlRecord QSqlRecord::keyValues(const QSqlRecord &keyFields) const
+{
+ QSqlRecord retValues(keyFields);
+
+ for (int i = retValues.count() - 1; i >= 0; --i)
+ retValues.setValue(i, value(retValues.fieldName(i)));
+
+ return retValues;
+}
+
QT_END_NAMESPACE
diff --git a/src/sql/kernel/qsqlrecord.h b/src/sql/kernel/qsqlrecord.h
index 0d0fae1460..7799b96588 100644
--- a/src/sql/kernel/qsqlrecord.h
+++ b/src/sql/kernel/qsqlrecord.h
@@ -45,8 +45,6 @@
#include <QtCore/qstring.h>
#include <QtSql/qsql.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -97,6 +95,7 @@ public:
void clear();
void clearValues();
int count() const;
+ QSqlRecord keyValues(const QSqlRecord &keyFields) const;
private:
void detach();
@@ -109,6 +108,4 @@ Q_SQL_EXPORT QDebug operator<<(QDebug, const QSqlRecord &);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQLRECORD_H
diff --git a/src/sql/kernel/qsqlresult.cpp b/src/sql/kernel/qsqlresult.cpp
index ea972abf50..e3203f983c 100644
--- a/src/sql/kernel/qsqlresult.cpp
+++ b/src/sql/kernel/qsqlresult.cpp
@@ -61,7 +61,7 @@ QString QSqlResultPrivate::holderAt(int index) const
}
// return a unique id for bound names
-QString QSqlResultPrivate::fieldSerial(int i)
+QString QSqlResultPrivate::fieldSerial(int i) const
{
ushort arr[] = { ':', 'f', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
ushort *ptr = &arr[1];
@@ -81,7 +81,7 @@ static bool qIsAlnum(QChar ch)
return u - 'a' < 26 || u - 'A' < 26 || u - '0' < 10 || u == '_';
}
-QString QSqlResultPrivate::positionalToNamedBinding(const QString &query, QString (fieldSerialFunc)(int idx))
+QString QSqlResultPrivate::positionalToNamedBinding(const QString &query) const
{
int n = query.size();
@@ -106,7 +106,7 @@ QString QSqlResultPrivate::positionalToNamedBinding(const QString &query, QStrin
result += ch;
} else {
if (ch == QLatin1Char('?')) {
- result += fieldSerialFunc(count++);
+ result += fieldSerial(count++);
} else {
if (ch == QLatin1Char('\'') || ch == QLatin1Char('"') || ch == QLatin1Char('`'))
closingQuote = ch;
@@ -218,11 +218,24 @@ QString QSqlResultPrivate::namedToPositionalBinding(const QString &query)
QSqlResult::QSqlResult(const QSqlDriver *db)
{
- d = new QSqlResultPrivate(this);
+ d_ptr = new QSqlResultPrivate;
+ Q_D(QSqlResult);
+ d->q_ptr = this;
d->sqldriver = const_cast<QSqlDriver *>(db);
- if(db) {
- setNumericalPrecisionPolicy(db->numericalPrecisionPolicy());
- }
+ if (d->sqldriver)
+ setNumericalPrecisionPolicy(d->sqldriver->numericalPrecisionPolicy());
+}
+
+/*! \internal
+*/
+QSqlResult::QSqlResult(QSqlResultPrivate &dd, const QSqlDriver *db)
+{
+ d_ptr = &dd;
+ Q_D(QSqlResult);
+ d->q_ptr = this;
+ d->sqldriver = const_cast<QSqlDriver *>(db);
+ if (d->sqldriver)
+ setNumericalPrecisionPolicy(d->sqldriver->numericalPrecisionPolicy());
}
/*!
@@ -231,6 +244,7 @@ QSqlResult::QSqlResult(const QSqlDriver *db)
QSqlResult::~QSqlResult()
{
+ Q_D(QSqlResult);
delete d;
}
@@ -243,6 +257,7 @@ QSqlResult::~QSqlResult()
void QSqlResult::setQuery(const QString& query)
{
+ Q_D(QSqlResult);
d->sql = query;
}
@@ -255,6 +270,7 @@ void QSqlResult::setQuery(const QString& query)
QString QSqlResult::lastQuery() const
{
+ Q_D(const QSqlResult);
return d->sql;
}
@@ -267,6 +283,7 @@ QString QSqlResult::lastQuery() const
*/
int QSqlResult::at() const
{
+ Q_D(const QSqlResult);
return d->idx;
}
@@ -281,6 +298,7 @@ int QSqlResult::at() const
bool QSqlResult::isValid() const
{
+ Q_D(const QSqlResult);
return d->idx != QSql::BeforeFirstRow && d->idx != QSql::AfterLastRow;
}
@@ -298,6 +316,7 @@ bool QSqlResult::isValid() const
bool QSqlResult::isActive() const
{
+ Q_D(const QSqlResult);
return d->active;
}
@@ -310,6 +329,7 @@ bool QSqlResult::isActive() const
void QSqlResult::setAt(int index)
{
+ Q_D(QSqlResult);
d->idx = index;
}
@@ -325,6 +345,7 @@ void QSqlResult::setAt(int index)
void QSqlResult::setSelect(bool select)
{
+ Q_D(QSqlResult);
d->isSel = select;
}
@@ -337,6 +358,7 @@ void QSqlResult::setSelect(bool select)
bool QSqlResult::isSelect() const
{
+ Q_D(const QSqlResult);
return d->isSel;
}
@@ -347,6 +369,7 @@ bool QSqlResult::isSelect() const
const QSqlDriver *QSqlResult::driver() const
{
+ Q_D(const QSqlResult);
return d->sqldriver;
}
@@ -360,6 +383,7 @@ const QSqlDriver *QSqlResult::driver() const
void QSqlResult::setActive(bool active)
{
+ Q_D(QSqlResult);
if (active && d->executedQuery.isEmpty())
d->executedQuery = d->sql;
@@ -375,6 +399,7 @@ void QSqlResult::setActive(bool active)
void QSqlResult::setLastError(const QSqlError &error)
{
+ Q_D(QSqlResult);
d->error = error;
}
@@ -385,6 +410,7 @@ void QSqlResult::setLastError(const QSqlError &error)
QSqlError QSqlResult::lastError() const
{
+ Q_D(const QSqlResult);
return d->error;
}
@@ -519,6 +545,7 @@ bool QSqlResult::fetchPrevious()
*/
bool QSqlResult::isForwardOnly() const
{
+ Q_D(const QSqlResult);
return d->forwardOnly;
}
@@ -540,6 +567,7 @@ bool QSqlResult::isForwardOnly() const
*/
void QSqlResult::setForwardOnly(bool forward)
{
+ Q_D(QSqlResult);
d->forwardOnly = forward;
}
@@ -554,6 +582,7 @@ void QSqlResult::setForwardOnly(bool forward)
*/
bool QSqlResult::savePrepare(const QString& query)
{
+ Q_D(QSqlResult);
if (!driver())
return false;
d->clear();
@@ -565,7 +594,7 @@ bool QSqlResult::savePrepare(const QString& query)
d->executedQuery = d->namedToPositionalBinding(query);
if (driver()->hasFeature(QSqlDriver::NamedPlaceholders))
- d->executedQuery = QSqlResultPrivate::positionalToNamedBinding(query);
+ d->executedQuery = d->positionalToNamedBinding(query);
return prepare(d->executedQuery);
}
@@ -579,6 +608,7 @@ bool QSqlResult::savePrepare(const QString& query)
*/
bool QSqlResult::prepare(const QString& query)
{
+ Q_D(QSqlResult);
d->sql = query;
if (d->holders.isEmpty()) {
// parse the query to memorize parameter location
@@ -595,6 +625,7 @@ bool QSqlResult::prepare(const QString& query)
*/
bool QSqlResult::exec()
{
+ Q_D(QSqlResult);
bool ret;
// fake preparation - just replace the placeholders..
QString query = lastQuery();
@@ -647,8 +678,9 @@ bool QSqlResult::exec()
*/
void QSqlResult::bindValue(int index, const QVariant& val, QSql::ParamType paramType)
{
+ Q_D(QSqlResult);
d->binds = PositionalBinding;
- d->indexes[QSqlResultPrivate::fieldSerial(index)].append(index);
+ d->indexes[d->fieldSerial(index)].append(index);
if (d->values.count() <= index)
d->values.resize(index + 1);
d->values[index] = val;
@@ -675,6 +707,7 @@ void QSqlResult::bindValue(int index, const QVariant& val, QSql::ParamType param
void QSqlResult::bindValue(const QString& placeholder, const QVariant& val,
QSql::ParamType paramType)
{
+ Q_D(QSqlResult);
d->binds = NamedBinding;
// if the index has already been set when doing emulated named
// bindings - don't reset it
@@ -696,6 +729,7 @@ void QSqlResult::bindValue(const QString& placeholder, const QVariant& val,
*/
void QSqlResult::addBindValue(const QVariant& val, QSql::ParamType paramType)
{
+ Q_D(QSqlResult);
d->binds = PositionalBinding;
bindValue(d->bindCount, val, paramType);
++d->bindCount;
@@ -709,6 +743,7 @@ void QSqlResult::addBindValue(const QVariant& val, QSql::ParamType paramType)
*/
QVariant QSqlResult::boundValue(int index) const
{
+ Q_D(const QSqlResult);
return d->values.value(index);
}
@@ -722,6 +757,7 @@ QVariant QSqlResult::boundValue(int index) const
*/
QVariant QSqlResult::boundValue(const QString& placeholder) const
{
+ Q_D(const QSqlResult);
QList<int> indexes = d->indexes.value(placeholder);
return d->values.value(indexes.value(0,-1));
}
@@ -733,6 +769,7 @@ QVariant QSqlResult::boundValue(const QString& placeholder) const
*/
QSql::ParamType QSqlResult::bindValueType(int index) const
{
+ Q_D(const QSqlResult);
return d->types.value(index, QSql::In);
}
@@ -744,6 +781,7 @@ QSql::ParamType QSqlResult::bindValueType(int index) const
*/
QSql::ParamType QSqlResult::bindValueType(const QString& placeholder) const
{
+ Q_D(const QSqlResult);
return d->types.value(d->indexes.value(placeholder).value(0,-1), QSql::In);
}
@@ -754,6 +792,7 @@ QSql::ParamType QSqlResult::bindValueType(const QString& placeholder) const
*/
int QSqlResult::boundValueCount() const
{
+ Q_D(const QSqlResult);
return d->values.count();
}
@@ -765,7 +804,8 @@ int QSqlResult::boundValueCount() const
*/
QVector<QVariant>& QSqlResult::boundValues() const
{
- return d->values;
+ Q_D(const QSqlResult);
+ return const_cast<QSqlResultPrivate *>(d)->values;
}
/*!
@@ -773,6 +813,7 @@ QVector<QVariant>& QSqlResult::boundValues() const
*/
QSqlResult::BindingSyntax QSqlResult::bindingSyntax() const
{
+ Q_D(const QSqlResult);
return d->binds;
}
@@ -782,6 +823,7 @@ QSqlResult::BindingSyntax QSqlResult::bindingSyntax() const
*/
void QSqlResult::clear()
{
+ Q_D(QSqlResult);
d->clear();
}
@@ -795,11 +837,13 @@ void QSqlResult::clear()
*/
QString QSqlResult::executedQuery() const
{
+ Q_D(const QSqlResult);
return d->executedQuery;
}
void QSqlResult::resetBindCount()
{
+ Q_D(QSqlResult);
d->resetBindCount();
}
@@ -811,6 +855,7 @@ void QSqlResult::resetBindCount()
*/
QString QSqlResult::boundValueName(int index) const
{
+ Q_D(const QSqlResult);
return d->holderAt(index);
}
@@ -822,6 +867,7 @@ QString QSqlResult::boundValueName(int index) const
*/
bool QSqlResult::hasOutValues() const
{
+ Q_D(const QSqlResult);
if (d->types.isEmpty())
return false;
QHash<int, QSql::ParamType>::ConstIterator it;
@@ -901,6 +947,7 @@ void QSqlResult::virtual_hook(int, void *)
bool QSqlResult::execBatch(bool arrayBind)
{
Q_UNUSED(arrayBind);
+ Q_D(QSqlResult);
QVector<QVariant> values = d->values;
if (values.count() == 0)
@@ -924,6 +971,7 @@ void QSqlResult::detachFromResultSet()
*/
void QSqlResult::setNumericalPrecisionPolicy(QSql::NumericalPrecisionPolicy policy)
{
+ Q_D(QSqlResult);
d->precisionPolicy = policy;
}
@@ -931,6 +979,7 @@ void QSqlResult::setNumericalPrecisionPolicy(QSql::NumericalPrecisionPolicy poli
*/
QSql::NumericalPrecisionPolicy QSqlResult::numericalPrecisionPolicy() const
{
+ Q_D(const QSqlResult);
return d->precisionPolicy;
}
diff --git a/src/sql/kernel/qsqlresult.h b/src/sql/kernel/qsqlresult.h
index 134b96e81d..05f3d7ffec 100644
--- a/src/sql/kernel/qsqlresult.h
+++ b/src/sql/kernel/qsqlresult.h
@@ -46,8 +46,6 @@
#include <QtCore/qvector.h>
#include <QtSql/qsql.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -61,9 +59,9 @@ class QSqlResultPrivate;
class Q_SQL_EXPORT QSqlResult
{
+ Q_DECLARE_PRIVATE(QSqlResult)
friend class QSqlQuery;
friend class QSqlTableModelPrivate;
- friend class QSqlResultPrivate;
public:
virtual ~QSqlResult();
@@ -76,6 +74,7 @@ protected:
};
explicit QSqlResult(const QSqlDriver * db);
+ QSqlResult(QSqlResultPrivate &dd, const QSqlDriver *db);
int at() const;
QString lastQuery() const;
QSqlError lastError() const;
@@ -134,8 +133,7 @@ protected:
virtual bool nextResult();
void resetBindCount(); // HACK
-private:
- QSqlResultPrivate* d;
+ QSqlResultPrivate *d_ptr;
private:
Q_DISABLE_COPY(QSqlResult)
@@ -143,6 +141,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQLRESULT_H
diff --git a/src/sql/kernel/qsqlresult_p.h b/src/sql/kernel/qsqlresult_p.h
index 246b914ec7..7f0459f3a8 100644
--- a/src/sql/kernel/qsqlresult_p.h
+++ b/src/sql/kernel/qsqlresult_p.h
@@ -70,9 +70,10 @@ struct QHolder {
class Q_SQL_EXPORT QSqlResultPrivate
{
+
public:
- QSqlResultPrivate(QSqlResult *d)
- : q(d),
+ QSqlResultPrivate()
+ : q_ptr(0),
idx(QSql::BeforeFirstRow),
active(false),
isSel(false),
@@ -81,6 +82,7 @@ public:
bindCount(0),
binds(QSqlResult::PositionalBinding)
{ }
+ virtual ~QSqlResultPrivate() { }
void clearValues()
{
@@ -106,17 +108,12 @@ public:
clearIndex();;
}
- // positionalToNamedBinding uses fieldSerial() by default, which converts to Oracle-style names,
- // because this style is used in the API. A driver can reuse positionalToNamedBinding()
- // internally for its own naming style by supplying its own fieldSerialFunc. We cannot make
- // fieldSerial() virtual because it would allow a driver to impose its naming style on
- // executedQuery when set by QSqlResult::savePrepare().
- static QString fieldSerial(int);
- static QString positionalToNamedBinding(const QString &query, QString (fieldSerialFunc)(int idx) = fieldSerial);
+ virtual QString fieldSerial(int) const;
+ QString positionalToNamedBinding(const QString &query) const;
QString namedToPositionalBinding(const QString &query);
QString holderAt(int index) const;
- QSqlResult *q;
+ QSqlResult *q_ptr;
QPointer<QSqlDriver> sqldriver;
int idx;
QString sql;
diff --git a/src/sql/models/qsqlquerymodel.h b/src/sql/models/qsqlquerymodel.h
index 25e0a68f9d..c00d905ec0 100644
--- a/src/sql/models/qsqlquerymodel.h
+++ b/src/sql/models/qsqlquerymodel.h
@@ -45,8 +45,6 @@
#include <QtCore/qabstractitemmodel.h>
#include <QtSql/qsqldatabase.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -113,6 +111,4 @@ protected:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQLQUERYMODEL_H
diff --git a/src/sql/models/qsqlquerymodel_p.h b/src/sql/models/qsqlquerymodel_p.h
index a79b62cda1..9d7b71faec 100644
--- a/src/sql/models/qsqlquerymodel_p.h
+++ b/src/sql/models/qsqlquerymodel_p.h
@@ -69,7 +69,7 @@ class QSqlQueryModelPrivate: public QAbstractItemModelPrivate
public:
QSqlQueryModelPrivate() : atEnd(false), nestedResetLevel(0) {}
~QSqlQueryModelPrivate();
-
+
void prefetch(int);
void initColOffsets(int size);
int columnInQuery(int modelColumn) const;
diff --git a/src/sql/models/qsqlrelationaldelegate.h b/src/sql/models/qsqlrelationaldelegate.h
index 8cecc02821..b878280bca 100644
--- a/src/sql/models/qsqlrelationaldelegate.h
+++ b/src/sql/models/qsqlrelationaldelegate.h
@@ -49,8 +49,6 @@
#include <QtWidgets/qcombobox.h>
#include <QtSql/qsqlrelationaltablemodel.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -110,8 +108,6 @@ void setModelData(QWidget *editor, QAbstractItemModel *model, const QModelIndex
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_WIDGETS_LIB
#endif // QSQLRELATIONALDELEGATE_H
diff --git a/src/sql/models/qsqlrelationaltablemodel.cpp b/src/sql/models/qsqlrelationaltablemodel.cpp
index 7cc7de2347..fb45468d2e 100644
--- a/src/sql/models/qsqlrelationaltablemodel.cpp
+++ b/src/sql/models/qsqlrelationaltablemodel.cpp
@@ -241,7 +241,7 @@ bool QRelation::isValid()
-QRelatedTableModel::QRelatedTableModel(QRelation *rel, QObject *parent, QSqlDatabase db) :
+QRelatedTableModel::QRelatedTableModel(QRelation *rel, QObject *parent, QSqlDatabase db) :
QSqlTableModel(parent, db), firstSelect(true), relation(rel)
{
}
diff --git a/src/sql/models/qsqlrelationaltablemodel.h b/src/sql/models/qsqlrelationaltablemodel.h
index 29acb88137..0ccfecd1c7 100644
--- a/src/sql/models/qsqlrelationaltablemodel.h
+++ b/src/sql/models/qsqlrelationaltablemodel.h
@@ -44,8 +44,6 @@
#include <QtSql/qsqltablemodel.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -112,6 +110,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQLRELATIONALTABLEMODEL_H
diff --git a/src/sql/models/qsqltablemodel.cpp b/src/sql/models/qsqltablemodel.cpp
index 2e395b0a59..94623548ed 100644
--- a/src/sql/models/qsqltablemodel.cpp
+++ b/src/sql/models/qsqltablemodel.cpp
@@ -195,29 +195,6 @@ bool QSqlTableModelPrivate::exec(const QString &stmt, bool prepStatement,
return true;
}
-QSqlRecord QSqlTableModelPrivate::primaryValues(const QSqlRecord &rec, const QSqlRecord &pIndex)
-{
- QSqlRecord pValues(pIndex);
-
- for (int i = pValues.count() - 1; i >= 0; --i)
- pValues.setValue(i, rec.value(pValues.fieldName(i)));
-
- return pValues;
-}
-
-QSqlRecord QSqlTableModelPrivate::primaryValues(int row) const
-{
- Q_Q(const QSqlTableModel);
-
- const QSqlRecord &pIndex = primaryIndex.isEmpty() ? rec : primaryIndex;
-
- ModifiedRow mr = cache.value(row);
- if (mr.op() != None)
- return mr.primaryValues(pIndex);
- else
- return primaryValues(q->QSqlQueryModel::record(row), pIndex);
-}
-
/*!
\class QSqlTableModel
\brief The QSqlTableModel class provides an editable data model
@@ -432,7 +409,7 @@ bool QSqlTableModel::selectRow(int row)
const QString table_filter = d->filter;
d->filter = d->db.driver()->sqlStatement(QSqlDriver::WhereStatement,
d->tableName,
- d->primaryValues(row),
+ primaryValues(row),
false);
static const QString wh = Sql::where() + Sql::sp();
if (d->filter.startsWith(wh, Qt::CaseInsensitive))
@@ -652,7 +629,7 @@ bool QSqlTableModel::updateRowInTable(int row, const QSqlRecord &values)
QSqlRecord rec(values);
emit beforeUpdate(row, rec);
- const QSqlRecord whereValues = d->primaryValues(row);
+ const QSqlRecord whereValues = primaryValues(row);
const bool prepStatement = d->db.driver()->hasFeature(QSqlDriver::PreparedQueries);
const QString stmt = d->db.driver()->sqlStatement(QSqlDriver::UpdateStatement, d->tableName,
rec, prepStatement);
@@ -718,7 +695,7 @@ bool QSqlTableModel::deleteRowFromTable(int row)
Q_D(QSqlTableModel);
emit beforeDelete(row);
- const QSqlRecord whereValues = d->primaryValues(row);
+ const QSqlRecord whereValues = primaryValues(row);
const bool prepStatement = d->db.driver()->hasFeature(QSqlDriver::PreparedQueries);
const QString stmt = d->db.driver()->sqlStatement(QSqlDriver::DeleteStatement,
d->tableName,
@@ -1439,4 +1416,24 @@ bool QSqlTableModel::setRecord(int row, const QSqlRecord &values)
return true;
}
+/*!
+ \since 5.1
+ Returns a record containing the fields represented in the primary key set to the values
+ at \a row. If no primary key is defined, the returned record will contain all fields.
+
+ \sa primaryKey()
+*/
+QSqlRecord QSqlTableModel::primaryValues(int row) const
+{
+ Q_D(const QSqlTableModel);
+
+ const QSqlRecord &pIndex = d->primaryIndex.isEmpty() ? d->rec : d->primaryIndex;
+
+ QSqlTableModelPrivate::ModifiedRow mr = d->cache.value(row);
+ if (mr.op() != QSqlTableModelPrivate::None)
+ return mr.primaryValues(pIndex);
+ else
+ return QSqlQueryModel::record(row).keyValues(pIndex);
+}
+
QT_END_NAMESPACE
diff --git a/src/sql/models/qsqltablemodel.h b/src/sql/models/qsqltablemodel.h
index efb9663a1c..1a4ce9b914 100644
--- a/src/sql/models/qsqltablemodel.h
+++ b/src/sql/models/qsqltablemodel.h
@@ -45,8 +45,6 @@
#include <QtSql/qsqldatabase.h>
#include <QtSql/qsqlquerymodel.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -136,10 +134,9 @@ protected:
void setPrimaryKey(const QSqlIndex &key);
void setQuery(const QSqlQuery &query);
QModelIndex indexInQuery(const QModelIndex &item) const;
+ QSqlRecord primaryValues(int row) const;
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSQLTABLEMODEL_H
diff --git a/src/sql/models/qsqltablemodel_p.h b/src/sql/models/qsqltablemodel_p.h
index 825490ea39..c02399166a 100644
--- a/src/sql/models/qsqltablemodel_p.h
+++ b/src/sql/models/qsqltablemodel_p.h
@@ -71,8 +71,6 @@ public:
busyInsertingRows(false)
{}
void clear();
- static QSqlRecord primaryValues(const QSqlRecord &rec, const QSqlRecord &pIndex);
- QSqlRecord primaryValues(int index) const;
virtual void clearCache();
QSqlRecord record(const QVector<QVariant> &values) const;
@@ -170,7 +168,7 @@ public:
if (m_op == None || m_op == Insert)
return QSqlRecord();
- return QSqlTableModelPrivate::primaryValues(m_db_values, pi);
+ return m_db_values.keyValues(pi);
}
private:
inline static void setGenerated(QSqlRecord& r, bool g)
diff --git a/src/src.pro b/src/src.pro
index 525c9c8855..b4c96025c1 100644
--- a/src/src.pro
+++ b/src/src.pro
@@ -1,7 +1,39 @@
TEMPLATE = subdirs
-src_tools.subdir = $$PWD/tools
-src_tools.target = sub-tools
+src_tools_bootstrap.subdir = tools/bootstrap
+src_tools_bootstrap.target = sub-bootstrap
+
+src_tools_moc.subdir = tools/moc
+src_tools_moc.target = sub-moc
+src_tools_moc.depends = src_tools_bootstrap
+
+src_tools_rcc.subdir = tools/rcc
+src_tools_rcc.target = sub-rcc
+src_tools_rcc.depends = src_tools_bootstrap
+
+src_tools_uic.subdir = tools/uic
+src_tools_uic.target = sub-uic
+force_bootstrap: src_tools_uic.depends = src_tools_bootstrap
+else: src_tools_uic.depends = src_corelib
+
+src_tools_qdoc.subdir = tools/qdoc
+src_tools_qdoc.target = sub-qdoc
+force_bootstrap: src_tools_qdoc.depends = src_tools_bootstrap
+else: src_tools_qdoc.depends = src_corelib src_xml
+
+src_tools_bootstrap_dbus.subdir = tools/bootstrap-dbus
+src_tools_bootstrap_dbus.target = sub-bootstrap_dbus
+src_tools_bootstrap_dbus.depends = src_tools_bootstrap
+
+src_tools_qdbusxml2cpp.subdir = tools/qdbusxml2cpp
+src_tools_qdbusxml2cpp.target = sub-qdbusxml2cpp
+force_bootstrap: src_tools_qdbusxml2cpp.depends = src_tools_bootstrap_dbus
+else: src_tools_qdbusxml2cpp.depends = src_dbus
+
+src_tools_qdbuscpp2xml.subdir = tools/qdbuscpp2xml
+src_tools_qdbuscpp2xml.target = sub-qdbuscpp2xml
+force_bootstrap: src_tools_qdbuscpp2xml.depends = src_tools_bootstrap_dbus
+else: src_tools_qdbuscpp2xml.depends = src_dbus
src_winmain.subdir = $$PWD/winmain
src_winmain.target = sub-winmain
@@ -9,7 +41,7 @@ src_winmain.depends = sub-corelib # just for the module .pri file
src_corelib.subdir = $$PWD/corelib
src_corelib.target = sub-corelib
-src_corelib.depends = src_tools
+src_corelib.depends = src_tools_moc src_tools_rcc
src_xml.subdir = $$PWD/xml
src_xml.target = sub-xml
@@ -48,27 +80,37 @@ src_platformsupport.depends = src_corelib src_gui src_network
src_widgets.subdir = $$PWD/widgets
src_widgets.target = sub-widgets
-src_widgets.depends = src_corelib src_gui
+src_widgets.depends = src_corelib src_gui src_tools_uic
src_opengl.subdir = $$PWD/opengl
src_opengl.target = sub-opengl
src_opengl.depends = src_gui src_widgets
+src_openglextensions.subdir = $$PWD/openglextensions
+src_openglextensions.target = sub-openglextensions
+src_openglextensions.depends = src_gui
+
src_printsupport.subdir = $$PWD/printsupport
src_printsupport.target = sub-printsupport
-src_printsupport.depends = src_corelib src_gui src_widgets
+src_printsupport.depends = src_corelib src_gui src_widgets src_tools_uic
src_plugins.subdir = $$PWD/plugins
src_plugins.target = sub-plugins
src_plugins.depends = src_sql src_xml src_network
+src_android.subdir = $$PWD/android
+
# this order is important
-SUBDIRS += src_tools src_corelib
+SUBDIRS += src_tools_bootstrap src_tools_moc src_tools_rcc src_corelib
win32:SUBDIRS += src_winmain
SUBDIRS += src_network src_sql src_xml src_testlib
contains(QT_CONFIG, dbus) {
SUBDIRS += src_dbus
- src_plugins.depends += src_dbus
+ force_bootstrap: SUBDIRS += src_tools_bootstrap_dbus
+ SUBDIRS += src_tools_qdbusxml2cpp src_tools_qdbuscpp2xml
+ contains(QT_CONFIG, accessibility-atspi-bridge): \
+ src_platformsupport.depends += src_dbus src_tools_qdbusxml2cpp
+ src_plugins.depends += src_dbus src_tools_qdbusxml2cpp src_tools_qdbuscpp2xml
}
contains(QT_CONFIG, concurrent):SUBDIRS += src_concurrent
!contains(QT_CONFIG, no-gui) {
@@ -77,9 +119,10 @@ contains(QT_CONFIG, concurrent):SUBDIRS += src_concurrent
src_gui.depends += src_angle
}
SUBDIRS += src_gui src_platformsupport
+ contains(QT_CONFIG, opengl(es1|es2)?):SUBDIRS += src_openglextensions
src_plugins.depends += src_gui src_platformsupport
!contains(QT_CONFIG, no-widgets) {
- SUBDIRS += src_widgets
+ SUBDIRS += src_tools_uic src_widgets
src_plugins.depends += src_widgets
contains(QT_CONFIG, opengl(es1|es2)?) {
SUBDIRS += src_opengl
@@ -91,6 +134,8 @@ contains(QT_CONFIG, concurrent):SUBDIRS += src_concurrent
}
}
}
-SUBDIRS += src_plugins
+SUBDIRS += src_plugins src_tools_qdoc
nacl: SUBDIRS -= src_network src_testlib
+
+android:!android-no-sdk: SUBDIRS += src_android
diff --git a/src/testlib/3rdparty/linux_perf_event_p.h b/src/testlib/3rdparty/linux_perf_event_p.h
new file mode 100644
index 0000000000..4f63c05d27
--- /dev/null
+++ b/src/testlib/3rdparty/linux_perf_event_p.h
@@ -0,0 +1,615 @@
+/*
+ * Performance events:
+ *
+ * Copyright (C) 2008-2009, Thomas Gleixner <tglx@linutronix.de>
+ * Copyright (C) 2008-2011, Red Hat, Inc., Ingo Molnar
+ * Copyright (C) 2008-2011, Red Hat, Inc., Peter Zijlstra
+ *
+ * Data type definitions, declarations, prototypes.
+ *
+ * Started by: Thomas Gleixner and Ingo Molnar
+ *
+ * For licencing details see kernel-base/COPYING
+ */
+#ifndef _UAPI_LINUX_PERF_EVENT_H
+#define _UAPI_LINUX_PERF_EVENT_H
+
+#include <linux/types.h>
+#include <linux/ioctl.h>
+#include <asm/byteorder.h>
+
+/*
+ * User-space ABI bits:
+ */
+
+/*
+ * attr.type
+ */
+enum perf_type_id {
+ PERF_TYPE_HARDWARE = 0,
+ PERF_TYPE_SOFTWARE = 1,
+ PERF_TYPE_TRACEPOINT = 2,
+ PERF_TYPE_HW_CACHE = 3,
+ PERF_TYPE_RAW = 4,
+ PERF_TYPE_BREAKPOINT = 5,
+
+ PERF_TYPE_MAX, /* non-ABI */
+};
+
+/*
+ * Generalized performance event event_id types, used by the
+ * attr.event_id parameter of the sys_perf_event_open()
+ * syscall:
+ */
+enum perf_hw_id {
+ /*
+ * Common hardware events, generalized by the kernel:
+ */
+ PERF_COUNT_HW_CPU_CYCLES = 0,
+ PERF_COUNT_HW_INSTRUCTIONS = 1,
+ PERF_COUNT_HW_CACHE_REFERENCES = 2,
+ PERF_COUNT_HW_CACHE_MISSES = 3,
+ PERF_COUNT_HW_BRANCH_INSTRUCTIONS = 4,
+ PERF_COUNT_HW_BRANCH_MISSES = 5,
+ PERF_COUNT_HW_BUS_CYCLES = 6,
+ PERF_COUNT_HW_STALLED_CYCLES_FRONTEND = 7,
+ PERF_COUNT_HW_STALLED_CYCLES_BACKEND = 8,
+ PERF_COUNT_HW_REF_CPU_CYCLES = 9,
+
+ PERF_COUNT_HW_MAX, /* non-ABI */
+};
+
+/*
+ * Generalized hardware cache events:
+ *
+ * { L1-D, L1-I, LLC, ITLB, DTLB, BPU, NODE } x
+ * { read, write, prefetch } x
+ * { accesses, misses }
+ */
+enum perf_hw_cache_id {
+ PERF_COUNT_HW_CACHE_L1D = 0,
+ PERF_COUNT_HW_CACHE_L1I = 1,
+ PERF_COUNT_HW_CACHE_LL = 2,
+ PERF_COUNT_HW_CACHE_DTLB = 3,
+ PERF_COUNT_HW_CACHE_ITLB = 4,
+ PERF_COUNT_HW_CACHE_BPU = 5,
+ PERF_COUNT_HW_CACHE_NODE = 6,
+
+ PERF_COUNT_HW_CACHE_MAX, /* non-ABI */
+};
+
+enum perf_hw_cache_op_id {
+ PERF_COUNT_HW_CACHE_OP_READ = 0,
+ PERF_COUNT_HW_CACHE_OP_WRITE = 1,
+ PERF_COUNT_HW_CACHE_OP_PREFETCH = 2,
+
+ PERF_COUNT_HW_CACHE_OP_MAX, /* non-ABI */
+};
+
+enum perf_hw_cache_op_result_id {
+ PERF_COUNT_HW_CACHE_RESULT_ACCESS = 0,
+ PERF_COUNT_HW_CACHE_RESULT_MISS = 1,
+
+ PERF_COUNT_HW_CACHE_RESULT_MAX, /* non-ABI */
+};
+
+/*
+ * Special "software" events provided by the kernel, even if the hardware
+ * does not support performance events. These events measure various
+ * physical and sw events of the kernel (and allow the profiling of them as
+ * well):
+ */
+enum perf_sw_ids {
+ PERF_COUNT_SW_CPU_CLOCK = 0,
+ PERF_COUNT_SW_TASK_CLOCK = 1,
+ PERF_COUNT_SW_PAGE_FAULTS = 2,
+ PERF_COUNT_SW_CONTEXT_SWITCHES = 3,
+ PERF_COUNT_SW_CPU_MIGRATIONS = 4,
+ PERF_COUNT_SW_PAGE_FAULTS_MIN = 5,
+ PERF_COUNT_SW_PAGE_FAULTS_MAJ = 6,
+ PERF_COUNT_SW_ALIGNMENT_FAULTS = 7,
+ PERF_COUNT_SW_EMULATION_FAULTS = 8,
+
+ PERF_COUNT_SW_MAX, /* non-ABI */
+};
+
+/*
+ * Bits that can be set in attr.sample_type to request information
+ * in the overflow packets.
+ */
+enum perf_event_sample_format {
+ PERF_SAMPLE_IP = 1U << 0,
+ PERF_SAMPLE_TID = 1U << 1,
+ PERF_SAMPLE_TIME = 1U << 2,
+ PERF_SAMPLE_ADDR = 1U << 3,
+ PERF_SAMPLE_READ = 1U << 4,
+ PERF_SAMPLE_CALLCHAIN = 1U << 5,
+ PERF_SAMPLE_ID = 1U << 6,
+ PERF_SAMPLE_CPU = 1U << 7,
+ PERF_SAMPLE_PERIOD = 1U << 8,
+ PERF_SAMPLE_STREAM_ID = 1U << 9,
+ PERF_SAMPLE_RAW = 1U << 10,
+ PERF_SAMPLE_BRANCH_STACK = 1U << 11,
+ PERF_SAMPLE_REGS_USER = 1U << 12,
+ PERF_SAMPLE_STACK_USER = 1U << 13,
+
+ PERF_SAMPLE_MAX = 1U << 14, /* non-ABI */
+};
+
+/*
+ * values to program into branch_sample_type when PERF_SAMPLE_BRANCH is set
+ *
+ * If the user does not pass priv level information via branch_sample_type,
+ * the kernel uses the event's priv level. Branch and event priv levels do
+ * not have to match. Branch priv level is checked for permissions.
+ *
+ * The branch types can be combined, however BRANCH_ANY covers all types
+ * of branches and therefore it supersedes all the other types.
+ */
+enum perf_branch_sample_type {
+ PERF_SAMPLE_BRANCH_USER = 1U << 0, /* user branches */
+ PERF_SAMPLE_BRANCH_KERNEL = 1U << 1, /* kernel branches */
+ PERF_SAMPLE_BRANCH_HV = 1U << 2, /* hypervisor branches */
+
+ PERF_SAMPLE_BRANCH_ANY = 1U << 3, /* any branch types */
+ PERF_SAMPLE_BRANCH_ANY_CALL = 1U << 4, /* any call branch */
+ PERF_SAMPLE_BRANCH_ANY_RETURN = 1U << 5, /* any return branch */
+ PERF_SAMPLE_BRANCH_IND_CALL = 1U << 6, /* indirect calls */
+
+ PERF_SAMPLE_BRANCH_MAX = 1U << 7, /* non-ABI */
+};
+
+#define PERF_SAMPLE_BRANCH_PLM_ALL \
+ (PERF_SAMPLE_BRANCH_USER|\
+ PERF_SAMPLE_BRANCH_KERNEL|\
+ PERF_SAMPLE_BRANCH_HV)
+
+/*
+ * Values to determine ABI of the registers dump.
+ */
+enum perf_sample_regs_abi {
+ PERF_SAMPLE_REGS_ABI_NONE = 0,
+ PERF_SAMPLE_REGS_ABI_32 = 1,
+ PERF_SAMPLE_REGS_ABI_64 = 2,
+};
+
+/*
+ * The format of the data returned by read() on a perf event fd,
+ * as specified by attr.read_format:
+ *
+ * struct read_format {
+ * { u64 value;
+ * { u64 time_enabled; } && PERF_FORMAT_TOTAL_TIME_ENABLED
+ * { u64 time_running; } && PERF_FORMAT_TOTAL_TIME_RUNNING
+ * { u64 id; } && PERF_FORMAT_ID
+ * } && !PERF_FORMAT_GROUP
+ *
+ * { u64 nr;
+ * { u64 time_enabled; } && PERF_FORMAT_TOTAL_TIME_ENABLED
+ * { u64 time_running; } && PERF_FORMAT_TOTAL_TIME_RUNNING
+ * { u64 value;
+ * { u64 id; } && PERF_FORMAT_ID
+ * } cntr[nr];
+ * } && PERF_FORMAT_GROUP
+ * };
+ */
+enum perf_event_read_format {
+ PERF_FORMAT_TOTAL_TIME_ENABLED = 1U << 0,
+ PERF_FORMAT_TOTAL_TIME_RUNNING = 1U << 1,
+ PERF_FORMAT_ID = 1U << 2,
+ PERF_FORMAT_GROUP = 1U << 3,
+
+ PERF_FORMAT_MAX = 1U << 4, /* non-ABI */
+};
+
+#define PERF_ATTR_SIZE_VER0 64 /* sizeof first published struct */
+#define PERF_ATTR_SIZE_VER1 72 /* add: config2 */
+#define PERF_ATTR_SIZE_VER2 80 /* add: branch_sample_type */
+#define PERF_ATTR_SIZE_VER3 96 /* add: sample_regs_user */
+ /* add: sample_stack_user */
+
+/*
+ * Hardware event_id to monitor via a performance monitoring event:
+ */
+struct perf_event_attr {
+
+ /*
+ * Major type: hardware/software/tracepoint/etc.
+ */
+ __u32 type;
+
+ /*
+ * Size of the attr structure, for fwd/bwd compat.
+ */
+ __u32 size;
+
+ /*
+ * Type specific configuration information.
+ */
+ __u64 config;
+
+ union {
+ __u64 sample_period;
+ __u64 sample_freq;
+ };
+
+ __u64 sample_type;
+ __u64 read_format;
+
+ __u64 disabled : 1, /* off by default */
+ inherit : 1, /* children inherit it */
+ pinned : 1, /* must always be on PMU */
+ exclusive : 1, /* only group on PMU */
+ exclude_user : 1, /* don't count user */
+ exclude_kernel : 1, /* ditto kernel */
+ exclude_hv : 1, /* ditto hypervisor */
+ exclude_idle : 1, /* don't count when idle */
+ mmap : 1, /* include mmap data */
+ comm : 1, /* include comm data */
+ freq : 1, /* use freq, not period */
+ inherit_stat : 1, /* per task counts */
+ enable_on_exec : 1, /* next exec enables */
+ task : 1, /* trace fork/exit */
+ watermark : 1, /* wakeup_watermark */
+ /*
+ * precise_ip:
+ *
+ * 0 - SAMPLE_IP can have arbitrary skid
+ * 1 - SAMPLE_IP must have constant skid
+ * 2 - SAMPLE_IP requested to have 0 skid
+ * 3 - SAMPLE_IP must have 0 skid
+ *
+ * See also PERF_RECORD_MISC_EXACT_IP
+ */
+ precise_ip : 2, /* skid constraint */
+ mmap_data : 1, /* non-exec mmap data */
+ sample_id_all : 1, /* sample_type all events */
+
+ exclude_host : 1, /* don't count in host */
+ exclude_guest : 1, /* don't count in guest */
+
+ exclude_callchain_kernel : 1, /* exclude kernel callchains */
+ exclude_callchain_user : 1, /* exclude user callchains */
+
+ __reserved_1 : 41;
+
+ union {
+ __u32 wakeup_events; /* wakeup every n events */
+ __u32 wakeup_watermark; /* bytes before wakeup */
+ };
+
+ __u32 bp_type;
+ union {
+ __u64 bp_addr;
+ __u64 config1; /* extension of config */
+ };
+ union {
+ __u64 bp_len;
+ __u64 config2; /* extension of config1 */
+ };
+ __u64 branch_sample_type; /* enum perf_branch_sample_type */
+
+ /*
+ * Defines set of user regs to dump on samples.
+ * See asm/perf_regs.h for details.
+ */
+ __u64 sample_regs_user;
+
+ /*
+ * Defines size of the user stack to dump on samples.
+ */
+ __u32 sample_stack_user;
+
+ /* Align to u64. */
+ __u32 __reserved_2;
+};
+
+#define perf_flags(attr) (*(&(attr)->read_format + 1))
+
+/*
+ * Ioctls that can be done on a perf event fd:
+ */
+#define PERF_EVENT_IOC_ENABLE _IO ('$', 0)
+#define PERF_EVENT_IOC_DISABLE _IO ('$', 1)
+#define PERF_EVENT_IOC_REFRESH _IO ('$', 2)
+#define PERF_EVENT_IOC_RESET _IO ('$', 3)
+#define PERF_EVENT_IOC_PERIOD _IOW('$', 4, __u64)
+#define PERF_EVENT_IOC_SET_OUTPUT _IO ('$', 5)
+#define PERF_EVENT_IOC_SET_FILTER _IOW('$', 6, char *)
+
+enum perf_event_ioc_flags {
+ PERF_IOC_FLAG_GROUP = 1U << 0,
+};
+
+/*
+ * Structure of the page that can be mapped via mmap
+ */
+struct perf_event_mmap_page {
+ __u32 version; /* version number of this structure */
+ __u32 compat_version; /* lowest version this is compat with */
+
+ /*
+ * Bits needed to read the hw events in user-space.
+ *
+ * u32 seq, time_mult, time_shift, idx, width;
+ * u64 count, enabled, running;
+ * u64 cyc, time_offset;
+ * s64 pmc = 0;
+ *
+ * do {
+ * seq = pc->lock;
+ * barrier()
+ *
+ * enabled = pc->time_enabled;
+ * running = pc->time_running;
+ *
+ * if (pc->cap_usr_time && enabled != running) {
+ * cyc = rdtsc();
+ * time_offset = pc->time_offset;
+ * time_mult = pc->time_mult;
+ * time_shift = pc->time_shift;
+ * }
+ *
+ * idx = pc->index;
+ * count = pc->offset;
+ * if (pc->cap_usr_rdpmc && idx) {
+ * width = pc->pmc_width;
+ * pmc = rdpmc(idx - 1);
+ * }
+ *
+ * barrier();
+ * } while (pc->lock != seq);
+ *
+ * NOTE: for obvious reason this only works on self-monitoring
+ * processes.
+ */
+ __u32 lock; /* seqlock for synchronization */
+ __u32 index; /* hardware event identifier */
+ __s64 offset; /* add to hardware event value */
+ __u64 time_enabled; /* time event active */
+ __u64 time_running; /* time event on cpu */
+ union {
+ __u64 capabilities;
+ __u64 cap_usr_time : 1,
+ cap_usr_rdpmc : 1,
+ cap_____res : 62;
+ };
+
+ /*
+ * If cap_usr_rdpmc this field provides the bit-width of the value
+ * read using the rdpmc() or equivalent instruction. This can be used
+ * to sign extend the result like:
+ *
+ * pmc <<= 64 - width;
+ * pmc >>= 64 - width; // signed shift right
+ * count += pmc;
+ */
+ __u16 pmc_width;
+
+ /*
+ * If cap_usr_time the below fields can be used to compute the time
+ * delta since time_enabled (in ns) using rdtsc or similar.
+ *
+ * u64 quot, rem;
+ * u64 delta;
+ *
+ * quot = (cyc >> time_shift);
+ * rem = cyc & ((1 << time_shift) - 1);
+ * delta = time_offset + quot * time_mult +
+ * ((rem * time_mult) >> time_shift);
+ *
+ * Where time_offset,time_mult,time_shift and cyc are read in the
+ * seqcount loop described above. This delta can then be added to
+ * enabled and possible running (if idx), improving the scaling:
+ *
+ * enabled += delta;
+ * if (idx)
+ * running += delta;
+ *
+ * quot = count / running;
+ * rem = count % running;
+ * count = quot * enabled + (rem * enabled) / running;
+ */
+ __u16 time_shift;
+ __u32 time_mult;
+ __u64 time_offset;
+
+ /*
+ * Hole for extension of the self monitor capabilities
+ */
+
+ __u64 __reserved[120]; /* align to 1k */
+
+ /*
+ * Control data for the mmap() data buffer.
+ *
+ * User-space reading the @data_head value should issue an rmb(), on
+ * SMP capable platforms, after reading this value -- see
+ * perf_event_wakeup().
+ *
+ * When the mapping is PROT_WRITE the @data_tail value should be
+ * written by userspace to reflect the last read data. In this case
+ * the kernel will not over-write unread data.
+ */
+ __u64 data_head; /* head in the data section */
+ __u64 data_tail; /* user-space written tail */
+};
+
+#define PERF_RECORD_MISC_CPUMODE_MASK (7 << 0)
+#define PERF_RECORD_MISC_CPUMODE_UNKNOWN (0 << 0)
+#define PERF_RECORD_MISC_KERNEL (1 << 0)
+#define PERF_RECORD_MISC_USER (2 << 0)
+#define PERF_RECORD_MISC_HYPERVISOR (3 << 0)
+#define PERF_RECORD_MISC_GUEST_KERNEL (4 << 0)
+#define PERF_RECORD_MISC_GUEST_USER (5 << 0)
+
+/*
+ * Indicates that the content of PERF_SAMPLE_IP points to
+ * the actual instruction that triggered the event. See also
+ * perf_event_attr::precise_ip.
+ */
+#define PERF_RECORD_MISC_EXACT_IP (1 << 14)
+/*
+ * Reserve the last bit to indicate some extended misc field
+ */
+#define PERF_RECORD_MISC_EXT_RESERVED (1 << 15)
+
+struct perf_event_header {
+ __u32 type;
+ __u16 misc;
+ __u16 size;
+};
+
+enum perf_event_type {
+
+ /*
+ * If perf_event_attr.sample_id_all is set then all event types will
+ * have the sample_type selected fields related to where/when
+ * (identity) an event took place (TID, TIME, ID, CPU, STREAM_ID)
+ * described in PERF_RECORD_SAMPLE below, it will be stashed just after
+ * the perf_event_header and the fields already present for the existing
+ * fields, i.e. at the end of the payload. That way a newer perf.data
+ * file will be supported by older perf tools, with these new optional
+ * fields being ignored.
+ *
+ * The MMAP events record the PROT_EXEC mappings so that we can
+ * correlate userspace IPs to code. They have the following structure:
+ *
+ * struct {
+ * struct perf_event_header header;
+ *
+ * u32 pid, tid;
+ * u64 addr;
+ * u64 len;
+ * u64 pgoff;
+ * char filename[];
+ * };
+ */
+ PERF_RECORD_MMAP = 1,
+
+ /*
+ * struct {
+ * struct perf_event_header header;
+ * u64 id;
+ * u64 lost;
+ * };
+ */
+ PERF_RECORD_LOST = 2,
+
+ /*
+ * struct {
+ * struct perf_event_header header;
+ *
+ * u32 pid, tid;
+ * char comm[];
+ * };
+ */
+ PERF_RECORD_COMM = 3,
+
+ /*
+ * struct {
+ * struct perf_event_header header;
+ * u32 pid, ppid;
+ * u32 tid, ptid;
+ * u64 time;
+ * };
+ */
+ PERF_RECORD_EXIT = 4,
+
+ /*
+ * struct {
+ * struct perf_event_header header;
+ * u64 time;
+ * u64 id;
+ * u64 stream_id;
+ * };
+ */
+ PERF_RECORD_THROTTLE = 5,
+ PERF_RECORD_UNTHROTTLE = 6,
+
+ /*
+ * struct {
+ * struct perf_event_header header;
+ * u32 pid, ppid;
+ * u32 tid, ptid;
+ * u64 time;
+ * };
+ */
+ PERF_RECORD_FORK = 7,
+
+ /*
+ * struct {
+ * struct perf_event_header header;
+ * u32 pid, tid;
+ *
+ * struct read_format values;
+ * };
+ */
+ PERF_RECORD_READ = 8,
+
+ /*
+ * struct {
+ * struct perf_event_header header;
+ *
+ * { u64 ip; } && PERF_SAMPLE_IP
+ * { u32 pid, tid; } && PERF_SAMPLE_TID
+ * { u64 time; } && PERF_SAMPLE_TIME
+ * { u64 addr; } && PERF_SAMPLE_ADDR
+ * { u64 id; } && PERF_SAMPLE_ID
+ * { u64 stream_id;} && PERF_SAMPLE_STREAM_ID
+ * { u32 cpu, res; } && PERF_SAMPLE_CPU
+ * { u64 period; } && PERF_SAMPLE_PERIOD
+ *
+ * { struct read_format values; } && PERF_SAMPLE_READ
+ *
+ * { u64 nr,
+ * u64 ips[nr]; } && PERF_SAMPLE_CALLCHAIN
+ *
+ * #
+ * # The RAW record below is opaque data wrt the ABI
+ * #
+ * # That is, the ABI doesn't make any promises wrt to
+ * # the stability of its content, it may vary depending
+ * # on event, hardware, kernel version and phase of
+ * # the moon.
+ * #
+ * # In other words, PERF_SAMPLE_RAW contents are not an ABI.
+ * #
+ *
+ * { u32 size;
+ * char data[size];}&& PERF_SAMPLE_RAW
+ *
+ * { u64 from, to, flags } lbr[nr];} && PERF_SAMPLE_BRANCH_STACK
+ *
+ * { u64 abi; # enum perf_sample_regs_abi
+ * u64 regs[weight(mask)]; } && PERF_SAMPLE_REGS_USER
+ *
+ * { u64 size;
+ * char data[size];
+ * u64 dyn_size; } && PERF_SAMPLE_STACK_USER
+ * };
+ */
+ PERF_RECORD_SAMPLE = 9,
+
+ PERF_RECORD_MAX, /* non-ABI */
+};
+
+#define PERF_MAX_STACK_DEPTH 127
+
+enum perf_callchain_context {
+ PERF_CONTEXT_HV = (__u64)-32,
+ PERF_CONTEXT_KERNEL = (__u64)-128,
+ PERF_CONTEXT_USER = (__u64)-512,
+
+ PERF_CONTEXT_GUEST = (__u64)-2048,
+ PERF_CONTEXT_GUEST_KERNEL = (__u64)-2176,
+ PERF_CONTEXT_GUEST_USER = (__u64)-2560,
+
+ PERF_CONTEXT_MAX = (__u64)-4095,
+};
+
+#define PERF_FLAG_FD_NO_GROUP (1U << 0)
+#define PERF_FLAG_FD_OUTPUT (1U << 1)
+#define PERF_FLAG_PID_CGROUP (1U << 2) /* pid=cgroup id, per-cpu mode only */
+
+#endif /* _UAPI_LINUX_PERF_EVENT_H */
diff --git a/src/testlib/doc/src/qttestlib-manual.qdoc b/src/testlib/doc/src/qttestlib-manual.qdoc
index 70bc6112c0..c44bb49ae3 100644
--- a/src/testlib/doc/src/qttestlib-manual.qdoc
+++ b/src/testlib/doc/src/qttestlib-manual.qdoc
@@ -247,6 +247,12 @@
2000.
\li \c -nocrashhandler \br
Disables the crash handler on Unix platforms.
+ \li \c -platform \e name \br
+ This command line argument applies to all Qt applications, but might be
+ especially useful in the context of auto-testing. By using the "offscreen"
+ platform plugin (-platform offscreen) it's possible to have tests that use
+ QWidget or QWindow run without showing anything on the screen. Currently
+ the offscreen platform plugin is only fully supported on X11.
\endlist
\section3 Benchmarking Options
@@ -262,6 +268,8 @@
Counts events received during benchmarks.
\li \c -minimumvalue \e n \br
Sets the minimum acceptable measurement value.
+ \li \c -minimumtotal \e n \br
+ Sets the minimum acceptable total for repeated executions of a test function.
\li \c -iterations \e n \br
Sets the number of accumulation iterations.
\li \c -median \e n \br
diff --git a/src/testlib/qabstracttestlogger.cpp b/src/testlib/qabstracttestlogger.cpp
index da7e793341..d039c3c342 100644
--- a/src/testlib/qabstracttestlogger.cpp
+++ b/src/testlib/qabstracttestlogger.cpp
@@ -82,9 +82,9 @@ QAbstractTestLogger::~QAbstractTestLogger()
void QAbstractTestLogger::filterUnprintable(char *str) const
{
- char *idx = str;
+ unsigned char *idx = reinterpret_cast<unsigned char *>(str);
while (*idx) {
- if (((*idx < 0x20 && *idx != '\n' && *idx != '\t') || *idx > 0x7e))
+ if (((*idx < 0x20 && *idx != '\n' && *idx != '\t') || *idx == 0x7f))
*idx = '?';
++idx;
}
diff --git a/src/testlib/qbenchmark.cpp b/src/testlib/qbenchmark.cpp
index 796d817ae2..3ef29e19ce 100644
--- a/src/testlib/qbenchmark.cpp
+++ b/src/testlib/qbenchmark.cpp
@@ -59,6 +59,7 @@ QBenchmarkGlobalData::QBenchmarkGlobalData()
, medianIterationCount(-1)
, createChart(false)
, verboseOutput(false)
+ , minimumTotal(-1)
, mode_(WallTime)
{
setMode(mode_);
@@ -87,6 +88,10 @@ QBenchmarkMeasurerBase * QBenchmarkGlobalData::createMeasurer()
} else if (mode_ == CallgrindChildProcess || mode_ == CallgrindParentProcess) {
measurer = new QBenchmarkCallgrindMeasurer;
#endif
+#ifdef QTESTLIB_USE_PERF_EVENTS
+ } else if (mode_ == PerfCounter) {
+ measurer = new QBenchmarkPerfEventsMeasurer;
+#endif
#ifdef HAVE_TICK_COUNTER
} else if (mode_ == TickCounter) {
measurer = new QBenchmarkTickMeasurer;
diff --git a/src/testlib/qbenchmark.h b/src/testlib/qbenchmark.h
index f166955249..ea5023c095 100644
--- a/src/testlib/qbenchmark.h
+++ b/src/testlib/qbenchmark.h
@@ -45,8 +45,6 @@
#include <QtTest/qtest_global.h>
#include <QtTest/qbenchmarkmetric.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -94,6 +92,4 @@ namespace QTest
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QBENCHMARK_H
diff --git a/src/testlib/qbenchmark_p.h b/src/testlib/qbenchmark_p.h
index 6b5d996966..351287b103 100644
--- a/src/testlib/qbenchmark_p.h
+++ b/src/testlib/qbenchmark_p.h
@@ -63,12 +63,21 @@
#undef QTESTLIB_USE_VALGRIND
#endif
+#if defined(Q_OS_LINUX) && !defined(QT_LINUXBASE) && !defined(Q_OS_ANDROID)
+#define QTESTLIB_USE_PERF_EVENTS
+#else
+#undef QTESTLIB_USE_PERF_EVENTS
+#endif
+
#include <QtTest/private/qbenchmarkmeasurement_p.h>
#include <QtCore/QMap>
#include <QtTest/qtest_global.h>
#ifdef QTESTLIB_USE_VALGRIND
#include <QtTest/private/qbenchmarkvalgrind_p.h>
#endif
+#ifdef QTESTLIB_USE_PERF_EVENTS
+#include <QtTest/private/qbenchmarkperfevents_p.h>
+#endif
#include <QtTest/private/qbenchmarkevent_p.h>
#include <QtTest/private/qbenchmarkmetric_p.h>
@@ -137,7 +146,7 @@ public:
QBenchmarkGlobalData();
~QBenchmarkGlobalData();
- enum Mode { WallTime, CallgrindParentProcess, CallgrindChildProcess, TickCounter, EventCounter };
+ enum Mode { WallTime, CallgrindParentProcess, CallgrindChildProcess, PerfCounter, TickCounter, EventCounter };
void setMode(Mode mode);
Mode mode() const { return mode_; }
QBenchmarkMeasurerBase *createMeasurer();
@@ -151,6 +160,7 @@ public:
bool createChart;
bool verboseOutput;
QString callgrindOutFileBase;
+ int minimumTotal;
private:
Mode mode_;
};
diff --git a/src/testlib/qbenchmarkmetric.cpp b/src/testlib/qbenchmarkmetric.cpp
index ca802e3688..727b9fb912 100644
--- a/src/testlib/qbenchmarkmetric.cpp
+++ b/src/testlib/qbenchmarkmetric.cpp
@@ -51,19 +51,39 @@
\value BitsPerSecond Bits per second
\value BytesPerSecond Bytes per second
\value WalltimeMilliseconds Clock time in milliseconds
- \value CPUTicks CPU time
- \value InstructionReads Instruction reads
- \value Events Event count
\value WalltimeNanoseconds Clock time in nanoseconds
\value BytesAllocated Memory usage in bytes
+ \value Events Event count
+ \value CPUTicks CPU time
+ \value CPUMigrations Process migrations between CPUs
+ \value CPUCycles CPU cycles
+ \value BusCycles Bus cycles
+ \value StalledCycles Cycles stalled
+ \value InstructionReads Instruction reads
+ \value Instructions Instructions executed
+ \value BranchInstructions Branch-type instructions
+ \value BranchMisses Branch instructions that were mispredicted
+ \value CacheReferences Cache accesses of any type
+ \value CacheMisses Cache misses of any type
+ \value CacheReads Cache reads / loads
+ \value CacheReadMisses Cache read / load misses
+ \value CacheWrites Cache writes / stores
+ \value CacheWriteMisses Cache write / store misses
+ \value CachePrefetches Cache prefetches
+ \value CachePrefetchMisses Cache prefetch misses
+ \value ContextSwitches Context switches
+ \value PageFaults Page faults of any type
+ \value MinorPageFaults Minor page faults
+ \value MajorPageFaults Major page faults
+ \value AlignmentFaults Faults caused due to misalignment
+ \value EmulationFaults Faults that needed software emulation
+
+ \sa QTest::benchmarkMetricName(), QTest::benchmarkMetricUnit()
Note that \c WalltimeNanoseconds and \c BytesAllocated are
only provided for use via \l setBenchmarkResult(), and results
in those metrics are not able to be provided automatically
by the QTest framework.
-
- \sa QTest::benchmarkMetricName(), QTest::benchmarkMetricUnit()
-
*/
/*!
@@ -82,16 +102,58 @@ const char * QTest::benchmarkMetricName(QBenchmarkMetric metric)
return "BytesPerSecond";
case WalltimeMilliseconds:
return "WalltimeMilliseconds";
+ case Events:
+ return "Events";
case CPUTicks:
return "CPUTicks";
+ case CPUMigrations:
+ return "CPUMigrations";
+ case CPUCycles:
+ return "CPUCycles";
+ case BusCycles:
+ return "BusCycles";
+ case StalledCycles:
+ return "StalledCycles";
case InstructionReads:
return "InstructionReads";
- case Events:
- return "Events";
+ case Instructions:
+ return "Instructions";
case WalltimeNanoseconds:
return "WalltimeNanoseconds";
case BytesAllocated:
return "BytesAllocated";
+ case BranchInstructions:
+ return "BranchInstructions";
+ case BranchMisses:
+ return "BranchMisses";
+ case CacheReferences:
+ return "CacheReferences";
+ case CacheReads:
+ return "CacheReads";
+ case CacheWrites:
+ return "CacheWrites";
+ case CachePrefetches:
+ return "CachePrefetches";
+ case CacheMisses:
+ return "CacheMisses";
+ case CacheReadMisses:
+ return "CacheReadMisses";
+ case CacheWriteMisses:
+ return "CacheWriteMisses";
+ case CachePrefetchMisses:
+ return "CachePrefetchMisses";
+ case ContextSwitches:
+ return "ContextSwitches";
+ case PageFaults:
+ return "PageFaults";
+ case MinorPageFaults:
+ return "MinorPageFaults";
+ case MajorPageFaults:
+ return "MajorPageFaults";
+ case AlignmentFaults:
+ return "AlignmentFaults";
+ case EmulationFaults:
+ return "EmulationFaults";
default:
return "";
}
@@ -113,16 +175,58 @@ const char * QTest::benchmarkMetricUnit(QBenchmarkMetric metric)
return "bytes/s";
case WalltimeMilliseconds:
return "msecs";
+ case Events:
+ return "events";
case CPUTicks:
return "CPU ticks";
+ case CPUMigrations:
+ return "CPU migrations";
+ case CPUCycles:
+ return "CPU cycles";
+ case BusCycles:
+ return "bus cycles";
+ case StalledCycles:
+ return "stalled cycles";
case InstructionReads:
return "instruction reads";
- case Events:
- return "events";
+ case Instructions:
+ return "instructions";
case WalltimeNanoseconds:
return "nsecs";
case BytesAllocated:
return "bytes";
+ case BranchInstructions:
+ return "branch instructions";
+ case BranchMisses:
+ return "branch misses";
+ case CacheReferences:
+ return "cache references";
+ case CacheReads:
+ return "cache loads";
+ case CacheWrites:
+ return "cache stores";
+ case CachePrefetches:
+ return "cache prefetches";
+ case CacheMisses:
+ return "cache misses";
+ case CacheReadMisses:
+ return "cache load misses";
+ case CacheWriteMisses:
+ return "cache store misses";
+ case CachePrefetchMisses:
+ return "cache prefetch misses";
+ case ContextSwitches:
+ return "context switches";
+ case PageFaults:
+ return "page faults";
+ case MinorPageFaults:
+ return "minor page faults";
+ case MajorPageFaults:
+ return "major page faults";
+ case AlignmentFaults:
+ return "alignment faults";
+ case EmulationFaults:
+ return "emulation faults";
default:
return "";
}
diff --git a/src/testlib/qbenchmarkmetric.h b/src/testlib/qbenchmarkmetric.h
index 9a59156e66..448df3f691 100644
--- a/src/testlib/qbenchmarkmetric.h
+++ b/src/testlib/qbenchmarkmetric.h
@@ -44,8 +44,6 @@
#include <QtTest/qtest_global.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -60,13 +58,32 @@ enum QBenchmarkMetric {
InstructionReads,
Events,
WalltimeNanoseconds,
- BytesAllocated
+ BytesAllocated,
+ CPUMigrations,
+ CPUCycles,
+ BusCycles,
+ StalledCycles,
+ Instructions,
+ BranchInstructions,
+ BranchMisses,
+ CacheReferences,
+ CacheReads,
+ CacheWrites,
+ CachePrefetches,
+ CacheMisses,
+ CacheReadMisses,
+ CacheWriteMisses,
+ CachePrefetchMisses,
+ ContextSwitches,
+ PageFaults,
+ MinorPageFaults,
+ MajorPageFaults,
+ AlignmentFaults,
+ EmulationFaults
};
}
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QBENCHMARK_H
diff --git a/src/testlib/qbenchmarkmetric_p.h b/src/testlib/qbenchmarkmetric_p.h
index ad819e8757..0af2ed2d1a 100644
--- a/src/testlib/qbenchmarkmetric_p.h
+++ b/src/testlib/qbenchmarkmetric_p.h
@@ -56,8 +56,6 @@
#include <QtTest/qtest_global.h>
#include <QtTest/qbenchmarkmetric.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -68,6 +66,4 @@ namespace QTest {
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QBENCHMARK_H
diff --git a/src/testlib/qbenchmarkperfevents.cpp b/src/testlib/qbenchmarkperfevents.cpp
new file mode 100644
index 0000000000..e3034d1f94
--- /dev/null
+++ b/src/testlib/qbenchmarkperfevents.cpp
@@ -0,0 +1,607 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Intel Corporation.
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qbenchmarkperfevents_p.h"
+#include "qbenchmarkmetric.h"
+#include "qbenchmark_p.h"
+
+#ifdef QTESTLIB_USE_PERF_EVENTS
+
+// include the qcore_unix_p.h without core-private
+// we only use inline functions anyway
+#include "../corelib/kernel/qcore_unix_p.h"
+
+#include <sys/types.h>
+#include <errno.h>
+#include <fcntl.h>
+#include <string.h>
+#include <stdio.h>
+
+#include <sys/syscall.h>
+#include <sys/ioctl.h>
+
+#include "3rdparty/linux_perf_event_p.h"
+
+// for PERF_TYPE_HW_CACHE, the config is a bitmask
+// lowest 8 bits: cache type
+// bits 8 to 15: cache operation
+// bits 16 to 23: cache result
+#define CACHE_L1D_READ (PERF_COUNT_HW_CACHE_L1D | PERF_COUNT_HW_CACHE_OP_READ << 8 | PERF_COUNT_HW_CACHE_RESULT_ACCESS << 16)
+#define CACHE_L1D_WRITE (PERF_COUNT_HW_CACHE_L1D | PERF_COUNT_HW_CACHE_OP_WRITE << 8 | PERF_COUNT_HW_CACHE_RESULT_ACCESS << 16)
+#define CACHE_L1D_PREFETCH (PERF_COUNT_HW_CACHE_L1D | PERF_COUNT_HW_CACHE_OP_PREFETCH << 8 | PERF_COUNT_HW_CACHE_RESULT_ACCESS << 16)
+#define CACHE_L1I_READ (PERF_COUNT_HW_CACHE_L1I | PERF_COUNT_HW_CACHE_OP_READ << 8 | PERF_COUNT_HW_CACHE_RESULT_ACCESS << 16)
+#define CACHE_L1I_PREFETCH (PERF_COUNT_HW_CACHE_L1I | PERF_COUNT_HW_CACHE_OP_PREFETCH << 8 | PERF_COUNT_HW_CACHE_RESULT_ACCESS << 16)
+#define CACHE_LLC_READ (PERF_COUNT_HW_CACHE_LL | PERF_COUNT_HW_CACHE_OP_READ << 8 | PERF_COUNT_HW_CACHE_RESULT_ACCESS << 16)
+#define CACHE_LLC_WRITE (PERF_COUNT_HW_CACHE_LL | PERF_COUNT_HW_CACHE_OP_WRITE << 8| PERF_COUNT_HW_CACHE_RESULT_ACCESS << 16)
+#define CACHE_LLC_PREFETCH (PERF_COUNT_HW_CACHE_LL | PERF_COUNT_HW_CACHE_OP_PREFETCH << 8 | PERF_COUNT_HW_CACHE_RESULT_ACCESS << 16)
+#define CACHE_L1D_READ_MISS (PERF_COUNT_HW_CACHE_L1D | PERF_COUNT_HW_CACHE_OP_READ << 8 | PERF_COUNT_HW_CACHE_RESULT_MISS << 16)
+#define CACHE_L1D_WRITE_MISS (PERF_COUNT_HW_CACHE_L1D | PERF_COUNT_HW_CACHE_OP_WRITE << 8 | PERF_COUNT_HW_CACHE_RESULT_MISS << 16)
+#define CACHE_L1D_PREFETCH_MISS (PERF_COUNT_HW_CACHE_L1D | PERF_COUNT_HW_CACHE_OP_PREFETCH << 8 | PERF_COUNT_HW_CACHE_RESULT_MISS << 16)
+#define CACHE_L1I_READ_MISS (PERF_COUNT_HW_CACHE_L1I | PERF_COUNT_HW_CACHE_OP_READ << 8 | PERF_COUNT_HW_CACHE_RESULT_MISS << 16)
+#define CACHE_L1I_PREFETCH_MISS (PERF_COUNT_HW_CACHE_L1I | PERF_COUNT_HW_CACHE_OP_PREFETCH << 8 | PERF_COUNT_HW_CACHE_RESULT_MISS << 16)
+#define CACHE_LLC_READ_MISS (PERF_COUNT_HW_CACHE_LL | PERF_COUNT_HW_CACHE_OP_READ << 8 | PERF_COUNT_HW_CACHE_RESULT_MISS << 16)
+#define CACHE_LLC_WRITE_MISS (PERF_COUNT_HW_CACHE_LL | PERF_COUNT_HW_CACHE_OP_WRITE << 8 | PERF_COUNT_HW_CACHE_RESULT_MISS << 16)
+#define CACHE_LLC_PREFETCH_MISS (PERF_COUNT_HW_CACHE_LL | PERF_COUNT_HW_CACHE_OP_PREFETCH << 8 | PERF_COUNT_HW_CACHE_RESULT_MISS << 16)
+#define CACHE_BRANCH_READ (PERF_COUNT_HW_CACHE_BPU | PERF_COUNT_HW_CACHE_OP_READ << 8 | PERF_COUNT_HW_CACHE_RESULT_ACCESS << 16)
+#define CACHE_BRANCH_READ_MISS (PERF_COUNT_HW_CACHE_BPU | PERF_COUNT_HW_CACHE_OP_READ << 8 | PERF_COUNT_HW_CACHE_RESULT_MISS << 16)
+
+QT_BEGIN_NAMESPACE
+
+static perf_event_attr attr;
+
+static void initPerf()
+{
+ static bool done;
+ if (!done) {
+ memset(&attr, 0, sizeof attr);
+ attr.size = sizeof attr;
+ attr.read_format = PERF_FORMAT_TOTAL_TIME_ENABLED | PERF_FORMAT_TOTAL_TIME_RUNNING;
+ attr.disabled = true; // we'll enable later
+ attr.inherit = true; // let children processes inherit the monitoring
+ attr.pinned = true; // keep it running in the hardware
+ attr.inherit_stat = true; // aggregate all the info from child processes
+ attr.task = true; // trace fork/exits
+
+ // set a default performance counter: CPU cycles
+ attr.type = PERF_TYPE_HARDWARE;
+ attr.config = PERF_COUNT_HW_CPU_CYCLES; // default
+
+ done = true;
+ }
+}
+
+/*!
+ \class QBenchmarkPerfEvents
+ \brief The Linux perf events benchmark backend
+
+ This benchmark backend uses the Linux Performance Counters interface,
+ introduced with the Linux kernel v2.6.31. The interface is done by one
+ system call (perf_event_open) which takes an attribute structure and
+ returns a file descriptor.
+
+ More information:
+ \li design docs: tools/perf/design.txt <http://lxr.linux.no/linux/tools/perf/design.txt>
+ \li sample tool: tools/perf/builtin-stat.c <http://lxr.linux.no/linux/tools/perf/builtin-stat.c>
+ (note: as of v3.3.1, the documentation is out-of-date with the kernel
+ interface, so reading the source code of existing tools is necessary)
+
+ This benchlib backend monitors the current process as well as child process
+ launched. We do not try to benchmark in kernel or hypervisor mode, as that
+ usually requires elevated privileges.
+ */
+
+static int perf_event_open(perf_event_attr *attr, pid_t pid, int cpu, int group_fd, unsigned long flags)
+{
+ return syscall(SYS_perf_event_open, attr, pid, cpu, group_fd, flags);
+}
+
+bool QBenchmarkPerfEventsMeasurer::isAvailable()
+{
+ // this generates an EFAULT because attr == NULL if perf_event_open is available
+ // if the kernel is too old, it generates ENOSYS
+ return perf_event_open(0, 0, 0, 0, 0) == -1 && errno != ENOSYS;
+}
+
+/* Event list structure
+ The following table provides the list of supported events
+
+ Event type Event counter Unit Name and aliases
+ HARDWARE CPU_CYCLES CPUCycles cycles cpu-cycles
+ HARDWARE INSTRUCTIONS Instructions instructions
+ HARDWARE CACHE_REFERENCES CacheReferences cache-references
+ HARDWARE CACHE_MISSES CacheMisses cache-misses
+ HARDWARE BRANCH_INSTRUCTIONS BranchInstructions branch-instructions branches
+ HARDWARE BRANCH_MISSES BranchMisses branch-misses
+ HARDWARE BUS_CYCLES BusCycles bus-cycles
+ HARDWARE STALLED_CYCLES_FRONTEND StalledCycles stalled-cycles-frontend idle-cycles-frontend
+ HARDWARE STALLED_CYCLES_BACKEND StalledCycles stalled-cycles-backend idle-cycles-backend
+ SOFTWARE CPU_CLOCK WalltimeMilliseconds cpu-clock
+ SOFTWARE TASK_CLOCK WalltimeMilliseconds task-clock
+ SOFTWARE PAGE_FAULTS PageFaults page-faults faults
+ SOFTWARE PAGE_FAULTS_MAJ MajorPageFaults major-faults
+ SOFTWARE PAGE_FAULTS_MIN MinorPageFaults minor-faults
+ SOFTWARE CONTEXT_SWITCHES ContextSwitches context-switches cs
+ SOFTWARE CPU_MIGRATIONS CPUMigrations cpu-migrations migrations
+ SOFTWARE ALIGNMENT_FAULTS AlignmentFaults alignment-faults
+ SOFTWARE EMULATION_FAULTS EmulationFaults emulation-faults
+ HW_CACHE L1D_READ CacheReads l1d-cache-reads l1d-cache-loads l1d-reads l1d-loads
+ HW_CACHE L1D_WRITE CacheWrites l1d-cache-writes l1d-cache-stores l1d-writes l1d-stores
+ HW_CACHE L1D_PREFETCH CachePrefetches l1d-cache-prefetches l1d-prefetches
+ HW_CACHE L1I_READ CacheReads l1i-cache-reads l1i-cache-loads l1i-reads l1i-loads
+ HW_CACHE L1I_PREFETCH CachePrefetches l1i-cache-prefetches l1i-prefetches
+ HW_CACHE LLC_READ CacheReads llc-cache-reads llc-cache-loads llc-loads llc-reads
+ HW_CACHE LLC_WRITE CacheWrites llc-cache-writes llc-cache-stores llc-writes llc-stores
+ HW_CACHE LLC_PREFETCH CachePrefetches llc-cache-prefetches llc-prefetches
+ HW_CACHE L1D_READ_MISS CacheReads l1d-cache-read-misses l1d-cache-load-misses l1d-read-misses l1d-load-misses
+ HW_CACHE L1D_WRITE_MISS CacheWrites l1d-cache-write-misses l1d-cache-store-misses l1d-write-misses l1d-store-misses
+ HW_CACHE L1D_PREFETCH_MISS CachePrefetches l1d-cache-prefetch-misses l1d-prefetch-misses
+ HW_CACHE L1I_READ_MISS CacheReads l1i-cache-read-misses l1i-cache-load-misses l1i-read-misses l1i-load-misses
+ HW_CACHE L1I_PREFETCH_MISS CachePrefetches l1i-cache-prefetch-misses l1i-prefetch-misses
+ HW_CACHE LLC_READ_MISS CacheReads llc-cache-read-misses llc-cache-load-misses llc-read-misses llc-load-misses
+ HW_CACHE LLC_WRITE_MISS CacheWrites llc-cache-write-misses llc-cache-store-misses llc-write-misses llc-store-misses
+ HW_CACHE LLC_PREFETCH_MISS CachePrefetches llc-cache-prefetch-misses llc-prefetch-misses
+ HW_CACHE BRANCH_READ BranchInstructions branch-reads branch-loads branch-predicts
+ HW_CACHE BRANCH_READ_MISS BranchMisses branch-mispredicts branch-read-misses branch-load-misses
+
+ Use the following Perl script to re-generate the list
+=== cut perl ===
+#!/usr/bin/env perl
+# Load all entries into %map
+while (<STDIN>) {
+ m/^\s*(.*)\s*$/;
+ @_ = split /\s+/, $1;
+ $type = shift @_;
+ $id = ($type eq "HARDWARE" ? "PERF_COUNT_HW_" :
+ $type eq "SOFTWARE" ? "PERF_COUNT_SW_" :
+ $type eq "HW_CACHE" ? "CACHE_" : "") . shift @_;
+ $unit = shift @_;
+
+ for $string (@_) {
+ die "$string was already seen!" if defined($map{$string});
+ $map{$string} = [-1, $type, $id, $unit];
+ push @strings, $string;
+ }
+}
+
+# sort the map and print the string list
+@strings = sort @strings;
+print "static const char eventlist_strings[] = \n";
+$counter = 0;
+for $entry (@strings) {
+ print " \"$entry\\0\"\n";
+ $map{$entry}[0] = $counter;
+ $counter += 1 + length $entry;
+}
+
+# print the table
+print " \"\\0\";\n\nstatic const Events eventlist[] = {\n";
+for $entry (sort @strings) {
+ printf " { %3d, PERF_TYPE_%s, %s, QTest::%s },\n",
+ $map{$entry}[0],
+ $map{$entry}[1],
+ $map{$entry}[2],
+ $map{$entry}[3];
+}
+print " { 0, PERF_TYPE_MAX, 0, QTest::Events }\n};\n";
+=== cut perl ===
+*/
+
+struct Events {
+ unsigned offset;
+ quint32 type;
+ quint64 event_id;
+ QTest::QBenchmarkMetric metric;
+};
+
+/* -- BEGIN GENERATED CODE -- */
+static const char eventlist_strings[] =
+ "alignment-faults\0"
+ "branch-instructions\0"
+ "branch-load-misses\0"
+ "branch-loads\0"
+ "branch-mispredicts\0"
+ "branch-misses\0"
+ "branch-predicts\0"
+ "branch-read-misses\0"
+ "branch-reads\0"
+ "branches\0"
+ "bus-cycles\0"
+ "cache-misses\0"
+ "cache-references\0"
+ "context-switches\0"
+ "cpu-clock\0"
+ "cpu-cycles\0"
+ "cpu-migrations\0"
+ "cs\0"
+ "cycles\0"
+ "emulation-faults\0"
+ "faults\0"
+ "idle-cycles-backend\0"
+ "idle-cycles-frontend\0"
+ "instructions\0"
+ "l1d-cache-load-misses\0"
+ "l1d-cache-loads\0"
+ "l1d-cache-prefetch-misses\0"
+ "l1d-cache-prefetches\0"
+ "l1d-cache-read-misses\0"
+ "l1d-cache-reads\0"
+ "l1d-cache-store-misses\0"
+ "l1d-cache-stores\0"
+ "l1d-cache-write-misses\0"
+ "l1d-cache-writes\0"
+ "l1d-load-misses\0"
+ "l1d-loads\0"
+ "l1d-prefetch-misses\0"
+ "l1d-prefetches\0"
+ "l1d-read-misses\0"
+ "l1d-reads\0"
+ "l1d-store-misses\0"
+ "l1d-stores\0"
+ "l1d-write-misses\0"
+ "l1d-writes\0"
+ "l1i-cache-load-misses\0"
+ "l1i-cache-loads\0"
+ "l1i-cache-prefetch-misses\0"
+ "l1i-cache-prefetches\0"
+ "l1i-cache-read-misses\0"
+ "l1i-cache-reads\0"
+ "l1i-load-misses\0"
+ "l1i-loads\0"
+ "l1i-prefetch-misses\0"
+ "l1i-prefetches\0"
+ "l1i-read-misses\0"
+ "l1i-reads\0"
+ "llc-cache-load-misses\0"
+ "llc-cache-loads\0"
+ "llc-cache-prefetch-misses\0"
+ "llc-cache-prefetches\0"
+ "llc-cache-read-misses\0"
+ "llc-cache-reads\0"
+ "llc-cache-store-misses\0"
+ "llc-cache-stores\0"
+ "llc-cache-write-misses\0"
+ "llc-cache-writes\0"
+ "llc-load-misses\0"
+ "llc-loads\0"
+ "llc-prefetch-misses\0"
+ "llc-prefetches\0"
+ "llc-read-misses\0"
+ "llc-reads\0"
+ "llc-store-misses\0"
+ "llc-stores\0"
+ "llc-write-misses\0"
+ "llc-writes\0"
+ "major-faults\0"
+ "migrations\0"
+ "minor-faults\0"
+ "page-faults\0"
+ "stalled-cycles-backend\0"
+ "stalled-cycles-frontend\0"
+ "task-clock\0"
+ "\0";
+
+static const Events eventlist[] = {
+ { 0, PERF_TYPE_SOFTWARE, PERF_COUNT_SW_ALIGNMENT_FAULTS, QTest::AlignmentFaults },
+ { 17, PERF_TYPE_HARDWARE, PERF_COUNT_HW_BRANCH_INSTRUCTIONS, QTest::BranchInstructions },
+ { 37, PERF_TYPE_HW_CACHE, CACHE_BRANCH_READ_MISS, QTest::BranchMisses },
+ { 56, PERF_TYPE_HW_CACHE, CACHE_BRANCH_READ, QTest::BranchInstructions },
+ { 69, PERF_TYPE_HW_CACHE, CACHE_BRANCH_READ_MISS, QTest::BranchMisses },
+ { 88, PERF_TYPE_HARDWARE, PERF_COUNT_HW_BRANCH_MISSES, QTest::BranchMisses },
+ { 102, PERF_TYPE_HW_CACHE, CACHE_BRANCH_READ, QTest::BranchInstructions },
+ { 118, PERF_TYPE_HW_CACHE, CACHE_BRANCH_READ_MISS, QTest::BranchMisses },
+ { 137, PERF_TYPE_HW_CACHE, CACHE_BRANCH_READ, QTest::BranchInstructions },
+ { 150, PERF_TYPE_HARDWARE, PERF_COUNT_HW_BRANCH_INSTRUCTIONS, QTest::BranchInstructions },
+ { 159, PERF_TYPE_HARDWARE, PERF_COUNT_HW_BUS_CYCLES, QTest::BusCycles },
+ { 170, PERF_TYPE_HARDWARE, PERF_COUNT_HW_CACHE_MISSES, QTest::CacheMisses },
+ { 183, PERF_TYPE_HARDWARE, PERF_COUNT_HW_CACHE_REFERENCES, QTest::CacheReferences },
+ { 200, PERF_TYPE_SOFTWARE, PERF_COUNT_SW_CONTEXT_SWITCHES, QTest::ContextSwitches },
+ { 217, PERF_TYPE_SOFTWARE, PERF_COUNT_SW_CPU_CLOCK, QTest::WalltimeMilliseconds },
+ { 227, PERF_TYPE_HARDWARE, PERF_COUNT_HW_CPU_CYCLES, QTest::CPUCycles },
+ { 238, PERF_TYPE_SOFTWARE, PERF_COUNT_SW_CPU_MIGRATIONS, QTest::CPUMigrations },
+ { 253, PERF_TYPE_SOFTWARE, PERF_COUNT_SW_CONTEXT_SWITCHES, QTest::ContextSwitches },
+ { 256, PERF_TYPE_HARDWARE, PERF_COUNT_HW_CPU_CYCLES, QTest::CPUCycles },
+ { 263, PERF_TYPE_SOFTWARE, PERF_COUNT_SW_EMULATION_FAULTS, QTest::EmulationFaults },
+ { 280, PERF_TYPE_SOFTWARE, PERF_COUNT_SW_PAGE_FAULTS, QTest::PageFaults },
+ { 287, PERF_TYPE_HARDWARE, PERF_COUNT_HW_STALLED_CYCLES_BACKEND, QTest::StalledCycles },
+ { 307, PERF_TYPE_HARDWARE, PERF_COUNT_HW_STALLED_CYCLES_FRONTEND, QTest::StalledCycles },
+ { 328, PERF_TYPE_HARDWARE, PERF_COUNT_HW_INSTRUCTIONS, QTest::Instructions },
+ { 341, PERF_TYPE_HW_CACHE, CACHE_L1D_READ_MISS, QTest::CacheReads },
+ { 363, PERF_TYPE_HW_CACHE, CACHE_L1D_READ, QTest::CacheReads },
+ { 379, PERF_TYPE_HW_CACHE, CACHE_L1D_PREFETCH_MISS, QTest::CachePrefetches },
+ { 405, PERF_TYPE_HW_CACHE, CACHE_L1D_PREFETCH, QTest::CachePrefetches },
+ { 426, PERF_TYPE_HW_CACHE, CACHE_L1D_READ_MISS, QTest::CacheReads },
+ { 448, PERF_TYPE_HW_CACHE, CACHE_L1D_READ, QTest::CacheReads },
+ { 464, PERF_TYPE_HW_CACHE, CACHE_L1D_WRITE_MISS, QTest::CacheWrites },
+ { 487, PERF_TYPE_HW_CACHE, CACHE_L1D_WRITE, QTest::CacheWrites },
+ { 504, PERF_TYPE_HW_CACHE, CACHE_L1D_WRITE_MISS, QTest::CacheWrites },
+ { 527, PERF_TYPE_HW_CACHE, CACHE_L1D_WRITE, QTest::CacheWrites },
+ { 544, PERF_TYPE_HW_CACHE, CACHE_L1D_READ_MISS, QTest::CacheReads },
+ { 560, PERF_TYPE_HW_CACHE, CACHE_L1D_READ, QTest::CacheReads },
+ { 570, PERF_TYPE_HW_CACHE, CACHE_L1D_PREFETCH_MISS, QTest::CachePrefetches },
+ { 590, PERF_TYPE_HW_CACHE, CACHE_L1D_PREFETCH, QTest::CachePrefetches },
+ { 605, PERF_TYPE_HW_CACHE, CACHE_L1D_READ_MISS, QTest::CacheReads },
+ { 621, PERF_TYPE_HW_CACHE, CACHE_L1D_READ, QTest::CacheReads },
+ { 631, PERF_TYPE_HW_CACHE, CACHE_L1D_WRITE_MISS, QTest::CacheWrites },
+ { 648, PERF_TYPE_HW_CACHE, CACHE_L1D_WRITE, QTest::CacheWrites },
+ { 659, PERF_TYPE_HW_CACHE, CACHE_L1D_WRITE_MISS, QTest::CacheWrites },
+ { 676, PERF_TYPE_HW_CACHE, CACHE_L1D_WRITE, QTest::CacheWrites },
+ { 687, PERF_TYPE_HW_CACHE, CACHE_L1I_READ_MISS, QTest::CacheReads },
+ { 709, PERF_TYPE_HW_CACHE, CACHE_L1I_READ, QTest::CacheReads },
+ { 725, PERF_TYPE_HW_CACHE, CACHE_L1I_PREFETCH_MISS, QTest::CachePrefetches },
+ { 751, PERF_TYPE_HW_CACHE, CACHE_L1I_PREFETCH, QTest::CachePrefetches },
+ { 772, PERF_TYPE_HW_CACHE, CACHE_L1I_READ_MISS, QTest::CacheReads },
+ { 794, PERF_TYPE_HW_CACHE, CACHE_L1I_READ, QTest::CacheReads },
+ { 810, PERF_TYPE_HW_CACHE, CACHE_L1I_READ_MISS, QTest::CacheReads },
+ { 826, PERF_TYPE_HW_CACHE, CACHE_L1I_READ, QTest::CacheReads },
+ { 836, PERF_TYPE_HW_CACHE, CACHE_L1I_PREFETCH_MISS, QTest::CachePrefetches },
+ { 856, PERF_TYPE_HW_CACHE, CACHE_L1I_PREFETCH, QTest::CachePrefetches },
+ { 871, PERF_TYPE_HW_CACHE, CACHE_L1I_READ_MISS, QTest::CacheReads },
+ { 887, PERF_TYPE_HW_CACHE, CACHE_L1I_READ, QTest::CacheReads },
+ { 897, PERF_TYPE_HW_CACHE, CACHE_LLC_READ_MISS, QTest::CacheReads },
+ { 919, PERF_TYPE_HW_CACHE, CACHE_LLC_READ, QTest::CacheReads },
+ { 935, PERF_TYPE_HW_CACHE, CACHE_LLC_PREFETCH_MISS, QTest::CachePrefetches },
+ { 961, PERF_TYPE_HW_CACHE, CACHE_LLC_PREFETCH, QTest::CachePrefetches },
+ { 982, PERF_TYPE_HW_CACHE, CACHE_LLC_READ_MISS, QTest::CacheReads },
+ { 1004, PERF_TYPE_HW_CACHE, CACHE_LLC_READ, QTest::CacheReads },
+ { 1020, PERF_TYPE_HW_CACHE, CACHE_LLC_WRITE_MISS, QTest::CacheWrites },
+ { 1043, PERF_TYPE_HW_CACHE, CACHE_LLC_WRITE, QTest::CacheWrites },
+ { 1060, PERF_TYPE_HW_CACHE, CACHE_LLC_WRITE_MISS, QTest::CacheWrites },
+ { 1083, PERF_TYPE_HW_CACHE, CACHE_LLC_WRITE, QTest::CacheWrites },
+ { 1100, PERF_TYPE_HW_CACHE, CACHE_LLC_READ_MISS, QTest::CacheReads },
+ { 1116, PERF_TYPE_HW_CACHE, CACHE_LLC_READ, QTest::CacheReads },
+ { 1126, PERF_TYPE_HW_CACHE, CACHE_LLC_PREFETCH_MISS, QTest::CachePrefetches },
+ { 1146, PERF_TYPE_HW_CACHE, CACHE_LLC_PREFETCH, QTest::CachePrefetches },
+ { 1161, PERF_TYPE_HW_CACHE, CACHE_LLC_READ_MISS, QTest::CacheReads },
+ { 1177, PERF_TYPE_HW_CACHE, CACHE_LLC_READ, QTest::CacheReads },
+ { 1187, PERF_TYPE_HW_CACHE, CACHE_LLC_WRITE_MISS, QTest::CacheWrites },
+ { 1204, PERF_TYPE_HW_CACHE, CACHE_LLC_WRITE, QTest::CacheWrites },
+ { 1215, PERF_TYPE_HW_CACHE, CACHE_LLC_WRITE_MISS, QTest::CacheWrites },
+ { 1232, PERF_TYPE_HW_CACHE, CACHE_LLC_WRITE, QTest::CacheWrites },
+ { 1243, PERF_TYPE_SOFTWARE, PERF_COUNT_SW_PAGE_FAULTS_MAJ, QTest::MajorPageFaults },
+ { 1256, PERF_TYPE_SOFTWARE, PERF_COUNT_SW_CPU_MIGRATIONS, QTest::CPUMigrations },
+ { 1267, PERF_TYPE_SOFTWARE, PERF_COUNT_SW_PAGE_FAULTS_MIN, QTest::MinorPageFaults },
+ { 1280, PERF_TYPE_SOFTWARE, PERF_COUNT_SW_PAGE_FAULTS, QTest::PageFaults },
+ { 1292, PERF_TYPE_HARDWARE, PERF_COUNT_HW_STALLED_CYCLES_BACKEND, QTest::StalledCycles },
+ { 1315, PERF_TYPE_HARDWARE, PERF_COUNT_HW_STALLED_CYCLES_FRONTEND, QTest::StalledCycles },
+ { 1339, PERF_TYPE_SOFTWARE, PERF_COUNT_SW_TASK_CLOCK, QTest::WalltimeMilliseconds },
+ { 0, PERF_TYPE_MAX, 0, QTest::Events }
+};
+/* -- END GENERATED CODE -- */
+
+QTest::QBenchmarkMetric QBenchmarkPerfEventsMeasurer::metricForEvent(quint32 type, quint64 event_id)
+{
+ const Events *ptr = eventlist;
+ for ( ; ptr->type != PERF_TYPE_MAX; ++ptr) {
+ if (ptr->type == type && ptr->event_id == event_id)
+ return ptr->metric;
+ }
+ return QTest::Events;
+}
+
+void QBenchmarkPerfEventsMeasurer::setCounter(const char *name)
+{
+ initPerf();
+ const char *colon = strchr(name, ':');
+ int n = colon ? colon - name : strlen(name);
+ const Events *ptr = eventlist;
+ for ( ; ptr->type != PERF_TYPE_MAX; ++ptr) {
+ int c = strncmp(name, eventlist_strings + ptr->offset, n);
+ if (c == 0)
+ break;
+ if (c < 0) {
+ fprintf(stderr, "ERROR: Performance counter type '%s' is unknown\n", name);
+ exit(1);
+ }
+ }
+
+ attr.type = ptr->type;
+ attr.config = ptr->event_id;
+
+ // now parse the attributes
+ if (!colon)
+ return;
+ while (*++colon) {
+ switch (*colon) {
+ case 'u':
+ attr.exclude_user = true;
+ break;
+ case 'k':
+ attr.exclude_kernel = true;
+ break;
+ case 'h':
+ attr.exclude_hv = true;
+ break;
+ case 'G':
+ attr.exclude_guest = true;
+ break;
+ case 'H':
+ attr.exclude_host = true;
+ break;
+ default:
+ fprintf(stderr, "ERROR: Unknown attribute '%c'\n", *colon);
+ exit(1);
+ }
+ }
+}
+
+void QBenchmarkPerfEventsMeasurer::listCounters()
+{
+ if (!isAvailable()) {
+ printf("Performance counters are not available on this system\n");
+ return;
+ }
+
+ printf("The following performance counters are available:\n");
+ const Events *ptr = eventlist;
+ for ( ; ptr->type != PERF_TYPE_MAX; ++ptr) {
+ printf(" %-30s [%s]\n", eventlist_strings + ptr->offset,
+ ptr->type == PERF_TYPE_HARDWARE ? "hardware" :
+ ptr->type == PERF_TYPE_SOFTWARE ? "software" :
+ ptr->type == PERF_TYPE_HW_CACHE ? "cache" : "other");
+ }
+
+ printf("\nAttributes can be specified by adding a colon and the following:\n"
+ " u - exclude measuring in the userspace\n"
+ " k - exclude measuring in kernel mode\n"
+ " h - exclude measuring in the hypervisor\n"
+ " G - exclude measuring when running virtualized (guest VM)\n"
+ " H - exclude measuring when running non-virtualized (host system)\n"
+ "Attributes can be combined, for example: -perfcounter branch-mispredicts:kh\n");
+}
+
+QBenchmarkPerfEventsMeasurer::QBenchmarkPerfEventsMeasurer()
+ : fd(-1)
+{
+}
+
+QBenchmarkPerfEventsMeasurer::~QBenchmarkPerfEventsMeasurer()
+{
+ qt_safe_close(fd);
+}
+
+void QBenchmarkPerfEventsMeasurer::init()
+{
+}
+
+void QBenchmarkPerfEventsMeasurer::start()
+{
+
+ initPerf();
+ // pid == 0 -> attach to the current process
+ // cpu == -1 -> monitor on all CPUs
+ // group_fd == -1 -> this is the group leader
+ // flags == 0 -> reserved, must be zero
+ fd = perf_event_open(&attr, 0, -1, -1, 0);
+ if (fd == -1) {
+ perror("QBenchmarkPerfEventsMeasurer::start: perf_event_open");
+ exit(1);
+ } else {
+ ::fcntl(fd, F_SETFD, FD_CLOEXEC);
+ }
+
+ // enable the counter
+ ::ioctl(fd, PERF_EVENT_IOC_RESET);
+ ::ioctl(fd, PERF_EVENT_IOC_ENABLE);
+}
+
+qint64 QBenchmarkPerfEventsMeasurer::checkpoint()
+{
+ ::ioctl(fd, PERF_EVENT_IOC_DISABLE);
+ qint64 value = readValue();
+ ::ioctl(fd, PERF_EVENT_IOC_ENABLE);
+ return value;
+}
+
+qint64 QBenchmarkPerfEventsMeasurer::stop()
+{
+ // disable the counter
+ ::ioctl(fd, PERF_EVENT_IOC_DISABLE);
+ return readValue();
+}
+
+bool QBenchmarkPerfEventsMeasurer::isMeasurementAccepted(qint64)
+{
+ return true;
+}
+
+int QBenchmarkPerfEventsMeasurer::adjustIterationCount(int)
+{
+ return 1;
+}
+
+int QBenchmarkPerfEventsMeasurer::adjustMedianCount(int)
+{
+ return 1;
+}
+
+QTest::QBenchmarkMetric QBenchmarkPerfEventsMeasurer::metricType()
+{
+ return metricForEvent(attr.type, attr.config);
+}
+
+static quint64 rawReadValue(int fd)
+{
+ /* from the kernel docs:
+ * struct read_format {
+ * { u64 value;
+ * { u64 time_enabled; } && PERF_FORMAT_TOTAL_TIME_ENABLED
+ * { u64 time_running; } && PERF_FORMAT_TOTAL_TIME_RUNNING
+ * { u64 id; } && PERF_FORMAT_ID
+ * } && !PERF_FORMAT_GROUP
+ */
+
+ struct read_format {
+ quint64 value;
+ quint64 time_enabled;
+ quint64 time_running;
+ } results;
+
+ size_t nread = 0;
+ while (nread < sizeof results) {
+ char *ptr = reinterpret_cast<char *>(&results);
+ qint64 r = qt_safe_read(fd, ptr + nread, sizeof results - nread);
+ if (r == -1) {
+ perror("QBenchmarkPerfEventsMeasurer::readValue: reading the results");
+ exit(1);
+ }
+ nread += quint64(r);
+ }
+
+ if (results.time_running == results.time_enabled)
+ return results.value;
+
+ // scale the results, though this shouldn't happen!
+ return results.value * (double(results.time_running) / double(results.time_enabled));
+}
+
+qint64 QBenchmarkPerfEventsMeasurer::readValue()
+{
+ quint64 raw = rawReadValue(fd);
+ if (metricType() == QTest::WalltimeMilliseconds) {
+ // perf returns nanoseconds
+ return raw / 1000000;
+ }
+ return raw;
+}
+
+QT_END_NAMESPACE
+
+#endif
diff --git a/src/testlib/qbenchmarkperfevents_p.h b/src/testlib/qbenchmarkperfevents_p.h
new file mode 100644
index 0000000000..f73d140300
--- /dev/null
+++ b/src/testlib/qbenchmarkperfevents_p.h
@@ -0,0 +1,88 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Intel Corporation.
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QBENCHMARKPERFEVENTS_P_H
+#define QBENCHMARKPERFEVENTS_P_H
+
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists purely as an
+// implementation detail. This header file may change from version to
+// version without notice, or even be removed.
+//
+// We mean it.
+//
+
+#include <QtTest/private/qbenchmarkmeasurement_p.h>
+
+QT_BEGIN_NAMESPACE
+
+class QBenchmarkPerfEventsMeasurer : public QBenchmarkMeasurerBase
+{
+public:
+ QBenchmarkPerfEventsMeasurer();
+ ~QBenchmarkPerfEventsMeasurer();
+ virtual void init();
+ virtual void start();
+ virtual qint64 checkpoint();
+ virtual qint64 stop();
+ virtual bool isMeasurementAccepted(qint64 measurement);
+ virtual int adjustIterationCount(int suggestion);
+ virtual int adjustMedianCount(int suggestion);
+ virtual bool repeatCount() { return 1; }
+ virtual bool needsWarmupIteration() { return true; }
+ virtual QTest::QBenchmarkMetric metricType();
+
+ static bool isAvailable();
+ static QTest::QBenchmarkMetric metricForEvent(quint32 type, quint64 event_id);
+ static void setCounter(const char *name);
+ static void listCounters();
+private:
+ int fd;
+
+ qint64 readValue();
+};
+
+QT_END_NAMESPACE
+
+#endif // QBENCHMARKPERFEVENTS_P_H
diff --git a/src/testlib/qplaintestlogger.cpp b/src/testlib/qplaintestlogger.cpp
index 93f0dd34ff..9fe82de19e 100644
--- a/src/testlib/qplaintestlogger.cpp
+++ b/src/testlib/qplaintestlogger.cpp
@@ -196,7 +196,7 @@ namespace QTest {
void QPlainTestLogger::outputMessage(const char *str)
{
#if defined(Q_OS_WINCE)
- QString strUtf16 = QString::fromLatin1(str);
+ QString strUtf16 = QString::fromLocal8Bit(str);
const int maxOutputLength = 255;
do {
QString tmp = strUtf16.left(maxOutputLength);
diff --git a/src/testlib/qsignalspy.h b/src/testlib/qsignalspy.h
index 0323fa111f..72a5df1ed9 100644
--- a/src/testlib/qsignalspy.h
+++ b/src/testlib/qsignalspy.h
@@ -50,8 +50,6 @@
#include <QtCore/qvector.h>
#include <QtTest/qtesteventloop.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -97,7 +95,7 @@ public:
return;
}
sig = ba;
- initArgs(mo->method(sigIndex));
+ initArgs(mo->method(sigIndex), obj);
}
inline bool isValid() const { return !sig.isEmpty(); }
@@ -131,10 +129,23 @@ public:
private:
void initArgs(const QMetaMethod &member)
{
+ initArgs(member, 0);
+ }
+
+ void initArgs(const QMetaMethod &member, const QObject *obj)
+ {
const QList<QByteArray> params = member.parameterTypes();
args.reserve(params.size());
for (int i = 0; i < params.count(); ++i) {
- const int tp = QMetaType::type(params.at(i).constData());
+ int tp = QMetaType::type(params.at(i).constData());
+ if (tp == QMetaType::UnknownType && obj) {
+ void *argv[] = { &tp, &i };
+ QMetaObject::metacall(const_cast<QObject*>(obj),
+ QMetaObject::RegisterMethodArgumentMetaType,
+ member.methodIndex(), argv);
+ if (tp == -1)
+ tp = QMetaType::UnknownType;
+ }
if (tp == QMetaType::UnknownType) {
Q_ASSERT(tp != QMetaType::Void); // void parameter => metaobject is corrupt
qWarning("Don't know how to handle '%s', use qRegisterMetaType to register it.",
@@ -172,6 +183,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qsignalspy.qdoc b/src/testlib/qsignalspy.qdoc
index e9f2cac531..77dcd99741 100644
--- a/src/testlib/qsignalspy.qdoc
+++ b/src/testlib/qsignalspy.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\class QSignalSpy
\inmodule QtTest
diff --git a/src/testlib/qtest.h b/src/testlib/qtest.h
index 6d130af27c..ac1d6cc9ef 100644
--- a/src/testlib/qtest.h
+++ b/src/testlib/qtest.h
@@ -60,8 +60,6 @@
#include <QtCore/qrect.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -70,12 +68,12 @@ namespace QTest
template<> inline char *toString(const QLatin1String &str)
{
- return qstrdup(str.latin1());
+ return qstrdup(qPrintable(QString(str)));
}
template<> inline char *toString(const QString &str)
{
- return qstrdup(str.toLatin1().constData());
+ return qstrdup(qPrintable(str));
}
template<> inline char *toString(const QByteArray &ba)
@@ -87,29 +85,29 @@ template<> inline char *toString(const QByteArray &ba)
template<> inline char *toString(const QTime &time)
{
return time.isValid()
- ? qstrdup(time.toString(QLatin1String("hh:mm:ss.zzz")).toLatin1().constData())
+ ? qstrdup(qPrintable(time.toString(QLatin1String("hh:mm:ss.zzz"))))
: qstrdup("Invalid QTime");
}
template<> inline char *toString(const QDate &date)
{
return date.isValid()
- ? qstrdup(date.toString(QLatin1String("yyyy/MM/dd")).toLatin1().constData())
+ ? qstrdup(qPrintable(date.toString(QLatin1String("yyyy/MM/dd"))))
: qstrdup("Invalid QDate");
}
template<> inline char *toString(const QDateTime &dateTime)
{
return dateTime.isValid()
- ? qstrdup((dateTime.toString(QLatin1String("yyyy/MM/dd hh:mm:ss.zzz")) +
- (dateTime.timeSpec() == Qt::LocalTime ? QLatin1String("[local time]") : QLatin1String("[UTC]"))).toLatin1().constData())
+ ? qstrdup(qPrintable(dateTime.toString(QLatin1String("yyyy/MM/dd hh:mm:ss.zzz")) +
+ (dateTime.timeSpec() == Qt::LocalTime ? QLatin1String("[local time]") : QLatin1String("[UTC]"))))
: qstrdup("Invalid QDateTime");
}
#endif // QT_NO_DATESTRING
template<> inline char *toString(const QChar &c)
{
- return qstrdup(QString::fromLatin1("QChar: '%1' (0x%2)").arg(c).arg(QString::number(static_cast<int>(c.unicode()), 16)).toLatin1().constData());
+ return qstrdup(qPrintable(QString::fromLatin1("QChar: '%1' (0x%2)").arg(c).arg(QString::number(static_cast<int>(c.unicode()), 16))));
}
template<> inline char *toString(const QPoint &p)
@@ -145,7 +143,7 @@ template<> inline char *toString(const QRectF &s)
template<> inline char *toString(const QUrl &uri)
{
if (!uri.isValid())
- return qstrdup(QByteArray("Invalid URL: " + uri.errorString().toLatin1()).constData());
+ return qstrdup(qPrintable(QStringLiteral("Invalid URL: ") + uri.errorString()));
return qstrdup(uri.toEncoded().constData());
}
@@ -161,7 +159,7 @@ template<> inline char *toString(const QVariant &v)
if (!v.isNull()) {
vstring.append(',');
if (v.canConvert(QVariant::String)) {
- vstring.append(qvariant_cast<QString>(v).toLatin1());
+ vstring.append(qvariant_cast<QString>(v).toLocal8Bit());
}
else {
vstring.append("<value not representable as string>");
@@ -186,9 +184,9 @@ inline bool qCompare(QLatin1String const &t1, QString const &t2, const char *act
return qCompare(QString(t1), t2, actual, expected, file, line);
}
-template<>
-inline bool qCompare(QStringList const &t1, QStringList const &t2,
- const char *actual, const char *expected, const char *file, int line)
+template <typename T>
+inline bool qCompare(QList<T> const &t1, QList<T> const &t2, const char *actual, const char *expected,
+ const char *file, int line)
{
char msg[1024];
msg[0] = '\0';
@@ -196,23 +194,30 @@ inline bool qCompare(QStringList const &t1, QStringList const &t2,
const int actualSize = t1.count();
const int expectedSize = t2.count();
if (actualSize != expectedSize) {
- qsnprintf(msg, sizeof(msg), "Compared QStringLists have different sizes.\n"
+ qsnprintf(msg, sizeof(msg), "Compared lists have different sizes.\n"
" Actual (%s) size: '%d'\n"
" Expected (%s) size: '%d'", actual, actualSize, expected, expectedSize);
isOk = false;
}
for (int i = 0; isOk && i < actualSize; ++i) {
- if (t1.at(i) != t2.at(i)) {
- qsnprintf(msg, sizeof(msg), "Compared QStringLists differ at index %d.\n"
+ if (!(t1.at(i) == t2.at(i))) {
+ qsnprintf(msg, sizeof(msg), "Compared lists differ at index %d.\n"
" Actual (%s): '%s'\n"
- " Expected (%s): '%s'", i, actual, t1.at(i).toLatin1().constData(),
- expected, t2.at(i).toLatin1().constData());
+ " Expected (%s): '%s'", i, actual, toString(t1.at(i)),
+ expected, toString(t2.at(i)));
isOk = false;
}
}
return compare_helper(isOk, msg, 0, 0, actual, expected, file, line);
}
+template <>
+inline bool qCompare(QStringList const &t1, QStringList const &t2, const char *actual, const char *expected,
+ const char *file, int line)
+{
+ return qCompare<QString>(t1, t2, actual, expected, file, line);
+}
+
template <typename T>
inline bool qCompare(QFlags<T> const &t1, T const &t2, const char *actual, const char *expected,
const char *file, int line)
@@ -227,6 +232,48 @@ inline bool qCompare(QFlags<T> const &t1, int const &t2, const char *actual, con
return qCompare(int(t1), t2, actual, expected, file, line);
}
+template<>
+inline bool qCompare(qint64 const &t1, qint32 const &t2, const char *actual,
+ const char *expected, const char *file, int line)
+{
+ return qCompare(t1, static_cast<qint64>(t2), actual, expected, file, line);
+}
+
+template<>
+inline bool qCompare(qint64 const &t1, quint32 const &t2, const char *actual,
+ const char *expected, const char *file, int line)
+{
+ return qCompare(t1, static_cast<qint64>(t2), actual, expected, file, line);
+}
+
+template<>
+inline bool qCompare(quint64 const &t1, quint32 const &t2, const char *actual,
+ const char *expected, const char *file, int line)
+{
+ return qCompare(t1, static_cast<quint64>(t2), actual, expected, file, line);
+}
+
+template<>
+inline bool qCompare(qint32 const &t1, qint64 const &t2, const char *actual,
+ const char *expected, const char *file, int line)
+{
+ return qCompare(static_cast<qint64>(t1), t2, actual, expected, file, line);
+}
+
+template<>
+inline bool qCompare(quint32 const &t1, qint64 const &t2, const char *actual,
+ const char *expected, const char *file, int line)
+{
+ return qCompare(static_cast<qint64>(t1), t2, actual, expected, file, line);
+}
+
+template<>
+inline bool qCompare(quint32 const &t1, quint64 const &t2, const char *actual,
+ const char *expected, const char *file, int line)
+{
+ return qCompare(static_cast<quint64>(t1), t2, actual, expected, file, line);
+}
+
}
QT_END_NAMESPACE
@@ -294,6 +341,4 @@ int main(int argc, char *argv[]) \
return QTest::qExec(&tc, argc, argv); \
}
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtest_global.h b/src/testlib/qtest_global.h
index 9e59713663..ac5a0b23f5 100644
--- a/src/testlib/qtest_global.h
+++ b/src/testlib/qtest_global.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -76,6 +74,4 @@ namespace QTest
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtest_gui.h b/src/testlib/qtest_gui.h
index 1962344f12..a9ac7777c3 100644
--- a/src/testlib/qtest_gui.h
+++ b/src/testlib/qtest_gui.h
@@ -69,8 +69,6 @@
#pragma qt_no_master_include
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -149,6 +147,4 @@ inline bool qCompare(QPixmap const &t1, QPixmap const &t2, const char *actual, c
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtest_widgets.h b/src/testlib/qtest_widgets.h
index 265b3a4703..1161b84edc 100644
--- a/src/testlib/qtest_widgets.h
+++ b/src/testlib/qtest_widgets.h
@@ -57,11 +57,9 @@
#pragma qt_no_master_include
#endif
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
#endif
diff --git a/src/testlib/qtestaccessible.h b/src/testlib/qtestaccessible.h
index d2f57a0ced..f27651c3ad 100644
--- a/src/testlib/qtestaccessible.h
+++ b/src/testlib/qtestaccessible.h
@@ -47,6 +47,8 @@
#pragma qt_no_master_include
#endif
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_ACCESSIBILITY
#define QVERIFY_EVENT(event) \
@@ -59,8 +61,6 @@
#include <QtTest/qtest_global.h>
#include <QtTest/qtestsystem.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -266,7 +266,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_ACCESSIBILITY
#endif // QTESTACCESSIBLE_H
diff --git a/src/testlib/qtestassert.h b/src/testlib/qtestassert.h
index 7e88fa9d4d..c6942534c5 100644
--- a/src/testlib/qtestassert.h
+++ b/src/testlib/qtestassert.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -55,6 +53,4 @@ QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtestcase.cpp b/src/testlib/qtestcase.cpp
index 987c5d88b2..27fcc64ceb 100644
--- a/src/testlib/qtestcase.cpp
+++ b/src/testlib/qtestcase.cpp
@@ -64,6 +64,8 @@
#include <QtTest/private/qbenchmark_p.h>
#include <QtTest/private/cycle_p.h>
+#include <numeric>
+
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
@@ -82,7 +84,7 @@
#include <time.h>
#endif
-#ifdef Q_OS_MAC
+#if defined(Q_OS_MAC) && !defined(Q_OS_IOS)
#include <IOKit/pwr_mgt/IOPMLib.h>
#endif
@@ -1341,11 +1343,17 @@ Q_TESTLIB_EXPORT void qtest_qParseArgs(int argc, char *argv[], bool qml)
#ifdef QTESTLIB_USE_VALGRIND
" -callgrind : Use callgrind to time benchmarks\n"
#endif
+#ifdef QTESTLIB_USE_PERF_EVENTS
+ " -perf : Use Linux perf events to time benchmarks\n"
+ " -perfcounter name : Use the counter named 'name'\n"
+ " -perfcounterlist : Lists the counters available\n"
+#endif
#ifdef HAVE_TICK_COUNTER
" -tickcounter : Use CPU tick counters to time benchmarks\n"
#endif
" -eventcounter : Counts events received during benchmarks\n"
" -minimumvalue n : Sets the minimum acceptable measurement value\n"
+ " -minimumtotal n : Sets the minimum acceptable total for repeated executions of a test function\n"
" -iterations n : Sets the number of accumulation iterations.\n"
" -median n : Sets the number of median iterations.\n"
" -vb : Print out verbose benchmarking information.\n";
@@ -1481,6 +1489,25 @@ Q_TESTLIB_EXPORT void qtest_qParseArgs(int argc, char *argv[], bool qml)
QBenchmarkGlobalData::current->callgrindOutFileBase =
QBenchmarkValgrindUtils::outFileBase();
#endif
+#ifdef QTESTLIB_USE_PERF_EVENTS
+ } else if (strcmp(argv[i], "-perf") == 0) {
+ if (QBenchmarkPerfEventsMeasurer::isAvailable()) {
+ // perf available
+ QBenchmarkGlobalData::current->setMode(QBenchmarkGlobalData::PerfCounter);
+ } else {
+ fprintf(stderr, "WARNING: Linux perf events not available. Using the walltime measurer.\n");
+ }
+ } else if (strcmp(argv[i], "-perfcounter") == 0) {
+ if (i + 1 >= argc) {
+ fprintf(stderr, "-perfcounter needs an extra parameter with the name of the counter\n");
+ exit(1);
+ } else {
+ QBenchmarkPerfEventsMeasurer::setCounter(argv[++i]);
+ }
+ } else if (strcmp(argv[i], "-perfcounterlist") == 0) {
+ QBenchmarkPerfEventsMeasurer::listCounters();
+ exit(0);
+#endif
#ifdef HAVE_TICK_COUNTER
} else if (strcmp(argv[i], "-tickcounter") == 0) {
QBenchmarkGlobalData::current->setMode(QBenchmarkGlobalData::TickCounter);
@@ -1494,6 +1521,13 @@ Q_TESTLIB_EXPORT void qtest_qParseArgs(int argc, char *argv[], bool qml)
} else {
QBenchmarkGlobalData::current->walltimeMinimum = qToInt(argv[++i]);
}
+ } else if (strcmp(argv[i], "-minimumtotal") == 0) {
+ if (i + 1 >= argc) {
+ fprintf(stderr, "-minimumtotal needs an extra parameter to indicate the minimum total measurement\n");
+ exit(1);
+ } else {
+ QBenchmarkGlobalData::current->minimumTotal = qToInt(argv[++i]);
+ }
} else if (strcmp(argv[i], "-iterations") == 0) {
if (i + 1 >= argc) {
fprintf(stderr, "-iterations needs an extra parameter to indicate the number of iterations\n");
@@ -1623,6 +1657,15 @@ struct QTestDataSetter
}
};
+namespace {
+
+qreal addResult(qreal current, const QBenchmarkResult& r)
+{
+ return current + r.value;
+}
+
+}
+
static void qInvokeTestMethodDataEntry(char *slot)
{
/* Benchmarking: for each median iteration*/
@@ -1631,6 +1674,7 @@ static void qInvokeTestMethodDataEntry(char *slot)
int i = (QBenchmarkGlobalData::current->measurer->needsWarmupIteration()) ? -1 : 0;
QList<QBenchmarkResult> results;
+ bool minimumTotalReached = false;
do {
QBenchmarkTestMethodData::current->beginDataRun();
@@ -1689,8 +1733,16 @@ static void qInvokeTestMethodDataEntry(char *slot)
}
}
}
+
+ // Verify if the minimum total measurement is reached, if it was specified:
+ if (QBenchmarkGlobalData::current->minimumTotal == -1) {
+ minimumTotalReached = true;
+ } else {
+ const qreal total = std::accumulate(results.begin(), results.end(), 0.0, addResult);
+ minimumTotalReached = (total >= QBenchmarkGlobalData::current->minimumTotal);
+ }
} while (isBenchmark
- && (++i < QBenchmarkGlobalData::current->adjustMedianIterationCount())
+ && ((++i < QBenchmarkGlobalData::current->adjustMedianIterationCount()) || !minimumTotalReached)
&& !QTestResult::skipCurrentTest() && !QTestResult::currentTestFailed());
// If the test is a benchmark, finalize the result after all iterations have finished.
@@ -2078,7 +2130,7 @@ int QTest::qExec(QObject *testObject, int argc, char **argv)
int callgrindChildExitCode = 0;
#endif
-#ifdef Q_OS_MAC
+#if defined(Q_OS_MAC) && !defined(Q_OS_IOS)
bool macNeedsActivate = qApp && (qstrcmp(qApp->metaObject()->className(), "QApplication") == 0);
IOPMAssertionID powerID;
#endif
@@ -2093,7 +2145,7 @@ int QTest::qExec(QObject *testObject, int argc, char **argv)
SetErrorMode(SetErrorMode(0) | SEM_NOGPFAULTERRORBOX);
#endif
-#ifdef Q_OS_MAC
+#if defined(Q_OS_MAC) && !defined(Q_OS_IOS)
if (macNeedsActivate) {
CFStringRef reasonForActivity= CFSTR("No Display Sleep");
IOReturn ok = IOPMAssertionCreateWithName(kIOPMAssertionTypeNoDisplaySleep, kIOPMAssertionLevelOn, reasonForActivity, &powerID);
@@ -2146,7 +2198,7 @@ int QTest::qExec(QObject *testObject, int argc, char **argv)
}
QTestLog::stopLogging();
-#ifdef Q_OS_MAC
+#if defined(Q_OS_MAC) && !defined(Q_OS_IOS)
if (macNeedsActivate) {
IOPMAssertionRelease(powerID);
}
@@ -2163,7 +2215,7 @@ int QTest::qExec(QObject *testObject, int argc, char **argv)
QSignalDumper::endDump();
-#ifdef Q_OS_MAC
+#if defined(Q_OS_MAC) && !defined(Q_OS_IOS)
if (macNeedsActivate) {
IOPMAssertionRelease(powerID);
}
@@ -2684,6 +2736,10 @@ bool QTest::compare_string_helper(const char *t1, const char *t2, const char *ac
\internal
*/
+/*! \fn bool QTest::qCompare(QList<T> const &t1, QList<T> const &t2, const char *actual, const char *expected, const char *file, int line)
+ \internal
+*/
+
/*! \fn bool QTest::qCompare(QFlags<T> const &t1, T const &t2, const char *actual, const char *expected, const char *file, int line)
\internal
*/
@@ -2692,6 +2748,30 @@ bool QTest::compare_string_helper(const char *t1, const char *t2, const char *ac
\internal
*/
+/*! \fn bool QTest::qCompare(qint64 const &t1, qint32 const &t2, const char *actual, const char *expected, const char *file, int line)
+ \internal
+*/
+
+/*! \fn bool QTest::qCompare(qint64 const &t1, quint32 const &t2, const char *actual, const char *expected, const char *file, int line)
+ \internal
+*/
+
+/*! \fn bool QTest::qCompare(quint64 const &t1, quint32 const &t2, const char *actual, const char *expected, const char *file, int line)
+ \internal
+*/
+
+/*! \fn bool QTest::qCompare(qint32 const &t1, qint64 const &t2, const char *actual, const char *expected, const char *file, int line)
+ \internal
+*/
+
+/*! \fn bool QTest::qCompare(quint32 const &t1, qint64 const &t2, const char *actual, const char *expected, const char *file, int line)
+ \internal
+*/
+
+/*! \fn bool QTest::qCompare(quint32 const &t1, quint64 const &t2, const char *actual, const char *expected, const char *file, int line)
+ \internal
+*/
+
/*! \fn bool QTest::qCompare(bool const &t1, int const &t2, const char *actual, const char *expected, const char *file, int line)
\internal
*/
diff --git a/src/testlib/qtestcase.h b/src/testlib/qtestcase.h
index a13bd49338..6b5e7a574b 100644
--- a/src/testlib/qtestcase.h
+++ b/src/testlib/qtestcase.h
@@ -51,8 +51,6 @@
#include <string.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -352,6 +350,4 @@ namespace QTest
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtestcoreelement_p.h b/src/testlib/qtestcoreelement_p.h
index 22aa676263..023c50ab2c 100644
--- a/src/testlib/qtestcoreelement_p.h
+++ b/src/testlib/qtestcoreelement_p.h
@@ -56,8 +56,6 @@
#include <QtTest/private/qtestcorelist_p.h>
#include <QtTest/private/qtestelementattribute_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -174,6 +172,4 @@ const QTestElementAttribute *QTestCoreElement<ElementType>::attribute(QTest::Att
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtestcorelist_p.h b/src/testlib/qtestcorelist_p.h
index b5044df8ed..bd08ede949 100644
--- a/src/testlib/qtestcorelist_p.h
+++ b/src/testlib/qtestcorelist_p.h
@@ -55,8 +55,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -141,6 +139,4 @@ int QTestCoreList<T>::count()
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtestdata.h b/src/testlib/qtestdata.h
index 6c4ef15bdc..d1bc3e7b4e 100644
--- a/src/testlib/qtestdata.h
+++ b/src/testlib/qtestdata.h
@@ -47,8 +47,6 @@
#include <QtCore/qmetatype.h>
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -99,6 +97,4 @@ inline QTestData &operator<<(QTestData &data, const QStringBuilder<A, B> &value)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtestelement_p.h b/src/testlib/qtestelement_p.h
index 77204c4ce5..71f05f94af 100644
--- a/src/testlib/qtestelement_p.h
+++ b/src/testlib/qtestelement_p.h
@@ -55,8 +55,6 @@
#include <QtTest/private/qtestcoreelement_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -80,6 +78,4 @@ class QTestElement: public QTestCoreElement<QTestElement>
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtestelementattribute_p.h b/src/testlib/qtestelementattribute_p.h
index 54afb7cd93..c84b6d07c8 100644
--- a/src/testlib/qtestelementattribute_p.h
+++ b/src/testlib/qtestelementattribute_p.h
@@ -55,8 +55,6 @@
#include <QtTest/private/qtestcorelist_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -116,6 +114,4 @@ class QTestElementAttribute: public QTestCoreList<QTestElementAttribute>
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtestevent.h b/src/testlib/qtestevent.h
index 20f988b216..a96cfa7370 100644
--- a/src/testlib/qtestevent.h
+++ b/src/testlib/qtestevent.h
@@ -58,8 +58,6 @@
#include <stdlib.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -227,6 +225,4 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QTestEventList)
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtestevent.qdoc b/src/testlib/qtestevent.qdoc
index bef4d1553a..0e7a7e7ac2 100644
--- a/src/testlib/qtestevent.qdoc
+++ b/src/testlib/qtestevent.qdoc
@@ -25,7 +25,7 @@
**
****************************************************************************/
-/*!
+/*!
\class QTestEventList
\inmodule QtTest
diff --git a/src/testlib/qtesteventloop.h b/src/testlib/qtesteventloop.h
index 15356bc445..b70954cf66 100644
--- a/src/testlib/qtesteventloop.h
+++ b/src/testlib/qtesteventloop.h
@@ -49,8 +49,6 @@
#include <QtCore/qobject.h>
#include <QtCore/qpointer.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -131,6 +129,4 @@ inline void QTestEventLoop::timerEvent(QTimerEvent *e)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtestkeyboard.h b/src/testlib/qtestkeyboard.h
index b1f135a722..878806737e 100644
--- a/src/testlib/qtestkeyboard.h
+++ b/src/testlib/qtestkeyboard.h
@@ -62,8 +62,6 @@
#include <QtWidgets/qapplication.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
Q_GUI_EXPORT void qt_handleKeyEvent(QWindow *w, QEvent::Type t, int k, Qt::KeyboardModifiers mods, const QString & text = QString(), bool autorep = false, ushort count = 1);
@@ -298,6 +296,4 @@ namespace QTest
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTESTKEYBOARD_H
diff --git a/src/testlib/qtestmouse.h b/src/testlib/qtestmouse.h
index c24b09b14c..ea57ac5b8c 100644
--- a/src/testlib/qtestmouse.h
+++ b/src/testlib/qtestmouse.h
@@ -54,14 +54,13 @@
#include <QtCore/qpoint.h>
#include <QtCore/qstring.h>
#include <QtGui/qevent.h>
+#include <QtGui/qwindow.h>
#ifdef QT_WIDGETS_LIB
#include <QtWidgets/qapplication.h>
#include <QtWidgets/qwidget.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
Q_GUI_EXPORT void qt_handleMouseEvent(QWindow *w, const QPointF & local, const QPointF & global, Qt::MouseButtons b, Qt::KeyboardModifiers mods = Qt::NoModifier);
@@ -227,6 +226,4 @@ namespace QTest
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTESTMOUSE_H
diff --git a/src/testlib/qtestspontaneevent.h b/src/testlib/qtestspontaneevent.h
index ac8ea74cc2..e299981670 100644
--- a/src/testlib/qtestspontaneevent.h
+++ b/src/testlib/qtestspontaneevent.h
@@ -49,8 +49,6 @@
#pragma qt_no_master_include
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -73,7 +71,7 @@ public:
class QSpontaneKeyEvent
{
public:
- void setSpontaneous() { spont = 1; }
+ void setSpontaneous() { spont = 1; Q_UNUSED(posted) Q_UNUSED(m_accept) Q_UNUSED(reserved) }
bool spontaneous() { return spont; }
virtual void dummyFunc() {}
virtual ~QSpontaneKeyEvent() {}
@@ -112,6 +110,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtestsystem.h b/src/testlib/qtestsystem.h
index 5633b06e02..2a719e96f1 100644
--- a/src/testlib/qtestsystem.h
+++ b/src/testlib/qtestsystem.h
@@ -52,8 +52,6 @@
# include <QtWidgets/QWidget>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
namespace QTest
@@ -72,7 +70,7 @@ namespace QTest
}
#ifdef QT_GUI_LIB
- inline static bool qWaitForWindowActive(QWindow *window, int timeout = 1000)
+ inline static bool qWaitForWindowActive(QWindow *window, int timeout = 5000)
{
QElapsedTimer timer;
timer.start();
@@ -101,7 +99,7 @@ namespace QTest
return window->isActive();
}
- inline static bool qWaitForWindowExposed(QWindow *window, int timeout = 1000)
+ inline static bool qWaitForWindowExposed(QWindow *window, int timeout = 5000)
{
QElapsedTimer timer;
timer.start();
@@ -145,7 +143,5 @@ namespace QTest
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qtesttouch.h b/src/testlib/qtesttouch.h
index a291507142..9a661b4ecd 100644
--- a/src/testlib/qtesttouch.h
+++ b/src/testlib/qtesttouch.h
@@ -53,12 +53,11 @@
#include <QtTest/qtestspontaneevent.h>
#include <QtCore/qmap.h>
#include <QtGui/qevent.h>
+#include <QtGui/qwindow.h>
#ifdef QT_WIDGETS_LIB
#include <QtWidgets/qwidget.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
Q_GUI_EXPORT void qt_handleTouchEvent(QWindow *w, QTouchDevice *device,
@@ -233,6 +232,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTESTTOUCH_H
diff --git a/src/testlib/qtestxunitstreamer_p.h b/src/testlib/qtestxunitstreamer_p.h
index e047f644d3..c3278b2b53 100644
--- a/src/testlib/qtestxunitstreamer_p.h
+++ b/src/testlib/qtestxunitstreamer_p.h
@@ -55,8 +55,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -90,6 +88,4 @@ class QTestXunitStreamer
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/testlib/qxmltestlogger.cpp b/src/testlib/qxmltestlogger.cpp
index 9bc5255bf6..3f77f152b5 100644
--- a/src/testlib/qxmltestlogger.cpp
+++ b/src/testlib/qxmltestlogger.cpp
@@ -246,12 +246,13 @@ void QXmlTestLogger::addBenchmarkResult(const QBenchmarkResult &result)
benchmarkMetricName(result.metric));
xmlQuote(&quotedTag, result.context.tag.toUtf8().constData());
+ const qreal valuePerIteration = qreal(result.value) / qreal(result.iterations);
QTest::qt_asprintf(
&buf,
QTest::benchmarkResultFormatString(),
quotedMetric.constData(),
quotedTag.constData(),
- QByteArray::number(result.value).constData(), //no 64-bit qsnprintf support
+ QByteArray::number(valuePerIteration).constData(), //no 64-bit qsnprintf support
result.iterations);
outputString(buf.constData());
}
diff --git a/src/testlib/qxunittestlogger.cpp b/src/testlib/qxunittestlogger.cpp
index bfe9de2158..0a1a5fb6f9 100644
--- a/src/testlib/qxunittestlogger.cpp
+++ b/src/testlib/qxunittestlogger.cpp
@@ -232,7 +232,9 @@ void QXunitTestLogger::addBenchmarkResult(const QBenchmarkResult &result)
QTest::AI_Metric,
QTest::benchmarkMetricName(QBenchmarkTestMethodData::current->result.metric));
benchmarkElement->addAttribute(QTest::AI_Tag, result.context.tag.toUtf8().data());
- benchmarkElement->addAttribute(QTest::AI_Value, QByteArray::number(result.value).constData());
+
+ const qreal valuePerIteration = qreal(result.value) / qreal(result.iterations);
+ benchmarkElement->addAttribute(QTest::AI_Value, QByteArray::number(valuePerIteration).constData());
char buf[100];
qsnprintf(buf, sizeof(buf), "%i", result.iterations);
diff --git a/src/testlib/testlib.pro b/src/testlib/testlib.pro
index 6b74f23454..97301de151 100644
--- a/src/testlib/testlib.pro
+++ b/src/testlib/testlib.pro
@@ -16,6 +16,7 @@ HEADERS = qbenchmark.h \
qbenchmarkmeasurement_p.h \
qbenchmarkvalgrind_p.h \
qbenchmarkevent_p.h \
+ qbenchmarkperfevents_p.h \
qbenchmarkmetric_p.h \
qsignalspy.h \
qtestaccessible.h \
@@ -48,6 +49,7 @@ SOURCES = qtestcase.cpp \
qbenchmarkmeasurement.cpp \
qbenchmarkvalgrind.cpp \
qbenchmarkevent.cpp \
+ qbenchmarkperfevents.cpp \
qbenchmarkmetric.cpp \
qtestelement.cpp \
qtestelementattribute.cpp \
@@ -74,9 +76,3 @@ mac {
}
load(qt_module)
-
-QMAKE_TARGET_PRODUCT = QTestLib
-QMAKE_TARGET_DESCRIPTION = Qt \
- Unit \
- Testing \
- Library
diff --git a/src/tools/bootstrap-dbus/bootstrap-dbus.pro b/src/tools/bootstrap-dbus/bootstrap-dbus.pro
new file mode 100644
index 0000000000..6af70efda7
--- /dev/null
+++ b/src/tools/bootstrap-dbus/bootstrap-dbus.pro
@@ -0,0 +1,32 @@
+option(host_build)
+
+MODULE = bootstrap_dbus
+TARGET = QtBootstrapDBus
+CONFIG += no_module_headers internal_module force_bootstrap
+
+DEFINES += \
+ QT_NO_CAST_FROM_ASCII
+
+MODULE_PRIVATE_INCLUDES = \
+ \$\$QT_MODULE_INCLUDE_BASE/QtDBus \
+ \$\$QT_MODULE_INCLUDE_BASE/QtDBus/$$QT_VERSION \
+ \$\$QT_MODULE_INCLUDE_BASE/QtDBus/$$QT_VERSION/QtDBus
+
+load(qt_module)
+
+QMAKE_CXXFLAGS += $$QT_CFLAGS_DBUS
+
+SOURCES = \
+ ../../dbus/qdbusintrospection.cpp \
+ ../../dbus/qdbusxmlparser.cpp \
+ ../../dbus/qdbuserror.cpp \
+ ../../dbus/qdbusutil.cpp \
+ ../../dbus/qdbusmisc.cpp \
+ ../../dbus/qdbusmetatype.cpp \
+ ../../dbus/qdbusargument.cpp \
+ ../../dbus/qdbusextratypes.cpp \
+ ../../dbus/qdbus_symbols.cpp \
+ ../../dbus/qdbusunixfiledescriptor.cpp
+
+lib.CONFIG = dummy_install
+INSTALLS = lib
diff --git a/src/tools/bootstrap/bootstrap.pro b/src/tools/bootstrap/bootstrap.pro
index 1ec54deeb5..4819dbdd07 100644
--- a/src/tools/bootstrap/bootstrap.pro
+++ b/src/tools/bootstrap/bootstrap.pro
@@ -2,8 +2,7 @@ option(host_build)
TARGET = QtBootstrap
QT =
-CONFIG += no_module_headers internal_module
-!build_pass: CONFIG += release
+CONFIG += internal_module force_bootstrap
# otherwise mingw headers do not declare common functions like putenv
win32-g++*:QMAKE_CXXFLAGS_CXX11 = -std=gnu++0x
@@ -26,6 +25,7 @@ MODULE_DEFINES = \
DEFINES += \
$$MODULE_DEFINES \
+ QT_CRYPTOGRAPHICHASH_ONLY_SHA1 \
QT_NO_CAST_FROM_ASCII
MODULE_PRIVATE_INCLUDES = \
@@ -37,6 +37,14 @@ MODULE_PRIVATE_INCLUDES = \
\$\$QT_MODULE_INCLUDE_BASE/QtXml/$$QT_VERSION \
\$\$QT_MODULE_INCLUDE_BASE/QtXml/$$QT_VERSION/QtXml
+# We need the forwarding headers before their respective modules are built,
+# so do a minimal syncqt run.
+CONFIG += minimal_syncqt
+QMAKE_SYNCQT_OPTIONS = -module QtCore -module QtDBus -module QtXml
+contains(QT_CONFIG, zlib): \
+ QMAKE_SYNCQT_OPTIONS += -module QtZlib
+QMAKE_SYNCQT_OPTIONS += -version $$QT_VERSION
+
load(qt_module)
INCLUDEPATH += $$QT_BUILD_TREE/src/corelib/global
@@ -66,6 +74,8 @@ SOURCES += \
../../corelib/io/qsettings.cpp \
../../corelib/io/qtemporaryfile.cpp \
../../corelib/io/qtextstream.cpp \
+ ../../corelib/io/qstandardpaths.cpp \
+ ../../corelib/kernel/qcoreapplication.cpp \
../../corelib/kernel/qcoreglobaldata.cpp \
../../corelib/kernel/qmetatype.cpp \
../../corelib/kernel/qvariant.cpp \
@@ -75,6 +85,7 @@ SOURCES += \
../../corelib/tools/qbytearray.cpp \
../../corelib/tools/qarraydata.cpp \
../../corelib/tools/qbytearraymatcher.cpp \
+ ../../corelib/tools/qcryptographichash.cpp \
../../corelib/tools/qdatetime.cpp \
../../corelib/tools/qhash.cpp \
../../corelib/tools/qlist.cpp \
@@ -111,14 +122,27 @@ win32:SOURCES += ../../corelib/io/qfilesystemengine_win.cpp \
../../corelib/io/qfilesystemiterator_win.cpp \
../../corelib/io/qfsfileengine_win.cpp \
../../corelib/io/qsettings_win.cpp \
+ ../../corelib/kernel/qcoreapplication_win.cpp \
../../corelib/plugin/qsystemlibrary.cpp \
-macx: {
- SOURCES += ../../corelib/io/qfilesystemengine_mac.cpp \
- ../../corelib/io/qsettings_mac.cpp \
+mac {
+ SOURCES += ../../corelib/io/qsettings_mac.cpp \
+ ../../corelib/kernel/qcoreapplication_mac.cpp \
../../corelib/kernel/qcore_mac.cpp
LIBS += -framework CoreServices
}
+
+macx {
+ SOURCES += \
+ ../../corelib/io/qstandardpaths_mac.cpp
+} else:unix {
+ SOURCES += \
+ ../../corelib/io/qstandardpaths_unix.cpp
+} else {
+ SOURCES += \
+ ../../corelib/io/qstandardpaths_win.cpp
+}
+
*-g++*: QMAKE_CXXFLAGS += -ffunction-sections
if(contains(QT_CONFIG, zlib)|cross_compile):include(../../3rdparty/zlib.pri)
@@ -128,19 +152,3 @@ win32:LIBS += -luser32 -lole32 -ladvapi32
lib.CONFIG = dummy_install
INSTALLS += lib
-
-!build_pass {
- # We need the forwarding headers before their respective modules are built,
- # so do a minimal syncqt run.
- qtPrepareTool(QMAKE_SYNCQT, syncqt)
- QTDIR = $$[QT_HOST_PREFIX]
- exists($$QTDIR/.qmake.cache): \
- mod_component_base = $$QTDIR
- else: \
- mod_component_base = $$dirname(_QMAKE_CACHE_)
- QMAKE_SYNCQT += -minimal -module QtCore -module QtDBus -module QtXml \
- -version $$VERSION -outdir $$mod_component_base $$dirname(_QMAKE_CONF_)
- contains(QT_CONFIG, zlib):QMAKE_SYNCQT += -module QtZlib
- !silent:message($$QMAKE_SYNCQT)
- system($$QMAKE_SYNCQT)|error("Failed to run: $$QMAKE_SYNCQT")
-}
diff --git a/src/tools/moc/generator.cpp b/src/tools/moc/generator.cpp
index ef3b381842..e6ffbe157a 100644
--- a/src/tools/moc/generator.cpp
+++ b/src/tools/moc/generator.cpp
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2013 Olivier Goffart <ogoffart@woboq.com>
** Contact: http://www.qt-project.org/
**
** This file is part of the tools applications of the Qt Toolkit.
@@ -522,11 +523,6 @@ void Generator::generateCode()
}
if (!purestSuperClass.isEmpty() && !isQObject) {
QByteArray superClass = purestSuperClass;
- // workaround for VC6
- if (superClass.contains("::")) {
- fprintf(out, " typedef %s QMocSuperClass;\n", superClass.constData());
- superClass = "QMocSuperClass";
- }
fprintf(out, " return %s::qt_metacast(_clname);\n", superClass.constData());
} else {
fprintf(out, " return 0;\n");
@@ -719,7 +715,9 @@ void Generator::generateProperties()
uint flags = Invalid;
if (!isBuiltinType(p.type))
flags |= EnumOrFlag;
- if (!p.read.isEmpty())
+ if (!p.member.isEmpty() && !p.constant)
+ flags |= Writable;
+ if (!p.read.isEmpty() || !p.member.isEmpty())
flags |= Readable;
if (!p.write.isEmpty()) {
flags |= Writable;
@@ -846,11 +844,6 @@ void Generator::generateMetacall()
if (!purestSuperClass.isEmpty() && !isQObject) {
QByteArray superClass = purestSuperClass;
- // workaround for VC6
- if (superClass.contains("::")) {
- fprintf(out, " typedef %s QMocSuperClass;\n", superClass.constData());
- superClass = "QMocSuperClass";
- }
fprintf(out, " _id = %s::qt_metacall(_c, _id, _a);\n", superClass.constData());
}
@@ -893,12 +886,12 @@ void Generator::generateMetacall()
bool needUser = false;
for (int i = 0; i < cdef->propertyList.size(); ++i) {
const PropertyDef &p = cdef->propertyList.at(i);
- needGet |= !p.read.isEmpty();
- if (!p.read.isEmpty())
+ needGet |= !p.read.isEmpty() || !p.member.isEmpty();
+ if (!p.read.isEmpty() || !p.member.isEmpty())
needTempVarForGet |= (p.gspec != PropertyDef::PointerSpec
&& p.gspec != PropertyDef::ReferenceSpec);
- needSet |= !p.write.isEmpty();
+ needSet |= !p.write.isEmpty() || (!p.member.isEmpty() && !p.constant);
needReset |= !p.reset.isEmpty();
needDesignable |= p.designable.endsWith(')');
needScriptable |= p.scriptable.endsWith(')');
@@ -917,7 +910,7 @@ void Generator::generateMetacall()
fprintf(out, " switch (_id) {\n");
for (int propindex = 0; propindex < cdef->propertyList.size(); ++propindex) {
const PropertyDef &p = cdef->propertyList.at(propindex);
- if (p.read.isEmpty())
+ if (p.read.isEmpty() && p.member.isEmpty())
continue;
QByteArray prefix;
if (p.inPrivateClass.size()) {
@@ -933,9 +926,12 @@ void Generator::generateMetacall()
else if (cdef->enumDeclarations.value(p.type, false))
fprintf(out, " case %d: *reinterpret_cast<int*>(_v) = QFlag(%s%s()); break;\n",
propindex, prefix.constData(), p.read.constData());
- else
+ else if (!p.read.isEmpty())
fprintf(out, " case %d: *reinterpret_cast< %s*>(_v) = %s%s(); break;\n",
propindex, p.type.constData(), prefix.constData(), p.read.constData());
+ else
+ fprintf(out, " case %d: *reinterpret_cast< %s*>(_v) = %s%s; break;\n",
+ propindex, p.type.constData(), prefix.constData(), p.member.constData());
}
fprintf(out, " }\n");
}
@@ -952,7 +948,9 @@ void Generator::generateMetacall()
fprintf(out, " switch (_id) {\n");
for (int propindex = 0; propindex < cdef->propertyList.size(); ++propindex) {
const PropertyDef &p = cdef->propertyList.at(propindex);
- if (p.write.isEmpty())
+ if (p.constant)
+ continue;
+ if (p.write.isEmpty() && p.member.isEmpty())
continue;
QByteArray prefix;
if (p.inPrivateClass.size()) {
@@ -962,9 +960,25 @@ void Generator::generateMetacall()
if (cdef->enumDeclarations.value(p.type, false)) {
fprintf(out, " case %d: %s%s(QFlag(*reinterpret_cast<int*>(_v))); break;\n",
propindex, prefix.constData(), p.write.constData());
- } else {
+ } else if (!p.write.isEmpty()) {
fprintf(out, " case %d: %s%s(*reinterpret_cast< %s*>(_v)); break;\n",
propindex, prefix.constData(), p.write.constData(), p.type.constData());
+ } else {
+ fprintf(out, " case %d:\n", propindex);
+ fprintf(out, " if (%s%s != *reinterpret_cast< %s*>(_v)) {\n",
+ prefix.constData(), p.member.constData(), p.type.constData());
+ fprintf(out, " %s%s = *reinterpret_cast< %s*>(_v);\n",
+ prefix.constData(), p.member.constData(), p.type.constData());
+ if (!p.notify.isEmpty() && p.notifyId != -1) {
+ const FunctionDef &f = cdef->signalList.at(p.notifyId);
+ if (f.arguments.size() == 0)
+ fprintf(out, " emit %s();\n", p.notify.constData());
+ else if (f.arguments.size() == 1 && f.arguments.at(0).normalizedType == p.type)
+ fprintf(out, " emit %s(%s%s);\n",
+ p.notify.constData(), prefix.constData(), p.member.constData());
+ }
+ fprintf(out, " }\n");
+ fprintf(out, " break;\n");
}
}
fprintf(out, " }\n");
diff --git a/src/tools/moc/keywords.cpp b/src/tools/moc/keywords.cpp
index 558e99c1d6..dc03af3378 100644
--- a/src/tools/moc/keywords.cpp
+++ b/src/tools/moc/keywords.cpp
@@ -45,7 +45,7 @@
static const short keyword_trans[][128] = {
{0,0,0,0,0,0,0,0,0,546,543,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 546,252,544,547,0,38,239,545,25,26,236,234,30,235,27,237,
+ 546,252,544,547,8,38,239,545,25,26,236,234,30,235,27,237,
22,22,22,22,22,22,22,22,22,22,34,41,23,39,24,43,
0,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,
8,21,8,8,8,8,8,8,8,8,8,31,549,32,238,8,
diff --git a/src/tools/moc/moc.cpp b/src/tools/moc/moc.cpp
index f49cc23ce5..1ebb82ffad 100644
--- a/src/tools/moc/moc.cpp
+++ b/src/tools/moc/moc.cpp
@@ -1059,6 +1059,12 @@ void Moc::createPropertyDef(PropertyDef &propDef)
v2 = "()";
}
switch (l[0]) {
+ case 'M':
+ if (l == "MEMBER")
+ propDef.member = v;
+ else
+ error(2);
+ break;
case 'R':
if (l == "READ")
propDef.read = v;
@@ -1099,11 +1105,11 @@ void Moc::createPropertyDef(PropertyDef &propDef)
error(2);
}
}
- if (propDef.read.isNull()) {
+ if (propDef.read.isNull() && propDef.member.isNull()) {
QByteArray msg;
msg += "Property declaration ";
msg += propDef.name;
- msg += " has no READ accessor function. The property will be invalid.";
+ msg += " has no READ accessor function or associated MEMBER variable. The property will be invalid.";
warning(msg.constData());
}
if (propDef.constant && !propDef.write.isNull()) {
@@ -1515,7 +1521,7 @@ void Moc::checkProperties(ClassDef *cdef)
//
for (int i = 0; i < cdef->propertyList.count(); ++i) {
PropertyDef &p = cdef->propertyList[i];
- if (p.read.isEmpty())
+ if (p.read.isEmpty() && p.member.isEmpty())
continue;
for (int j = 0; j < cdef->publicList.count(); ++j) {
const FunctionDef &f = cdef->publicList.at(j);
diff --git a/src/tools/moc/moc.h b/src/tools/moc/moc.h
index 5b3c364a73..f97a537215 100644
--- a/src/tools/moc/moc.h
+++ b/src/tools/moc/moc.h
@@ -127,7 +127,7 @@ struct FunctionDef
struct PropertyDef
{
PropertyDef():notifyId(-1), constant(false), final(false), gspec(ValueSpec), revision(0){}
- QByteArray name, type, read, write, reset, designable, scriptable, editable, stored, user, notify, inPrivateClass;
+ QByteArray name, type, member, read, write, reset, designable, scriptable, editable, stored, user, notify, inPrivateClass;
int notifyId;
bool constant;
bool final;
diff --git a/src/tools/moc/moc.pro b/src/tools/moc/moc.pro
index 3a6fd2a02d..d56c2805eb 100644
--- a/src/tools/moc/moc.pro
+++ b/src/tools/moc/moc.pro
@@ -1,4 +1,5 @@
option(host_build)
+CONFIG += force_bootstrap
DEFINES += QT_MOC QT_NO_CAST_FROM_ASCII QT_NO_CAST_FROM_BYTEARRAY QT_NO_COMPRESS
diff --git a/src/tools/moc/ppkeywords.cpp b/src/tools/moc/ppkeywords.cpp
index e9d199705d..76387d4b18 100644
--- a/src/tools/moc/ppkeywords.cpp
+++ b/src/tools/moc/ppkeywords.cpp
@@ -45,7 +45,7 @@
static const short pp_keyword_trans[][128] = {
{0,0,0,0,0,0,0,0,0,98,12,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
- 98,76,96,13,0,60,62,97,9,10,58,56,11,57,102,59,
+ 98,76,96,13,1,60,62,97,9,10,58,56,11,57,102,59,
6,6,6,6,6,6,6,6,6,6,92,0,7,81,8,91,
0,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,101,0,61,1,
diff --git a/src/tools/moc/util/generate_keywords.cpp b/src/tools/moc/util/generate_keywords.cpp
index 47ff0f9ac8..7ad553608c 100644
--- a/src/tools/moc/util/generate_keywords.cpp
+++ b/src/tools/moc/util/generate_keywords.cpp
@@ -268,7 +268,7 @@ inline bool is_ident_start(char s)
{
return ((s >= 'a' && s <= 'z')
|| (s >= 'A' && s <= 'Z')
- || s == '_'
+ || s == '_' || s == '$'
);
}
@@ -277,7 +277,7 @@ inline bool is_ident_char(char s)
return ((s >= 'a' && s <= 'z')
|| (s >= 'A' && s <= 'Z')
|| (s >= '0' && s <= '9')
- || s == '_'
+ || s == '_' || s == '$'
);
}
struct State
@@ -360,8 +360,9 @@ void makeTable(const Keyword keywords[])
newState(states, pre?"PP_CHARACTER":"CHARACTER", c);
for (c = 'A'; c <= 'Z'; ++c)
newState(states, pre?"PP_CHARACTER":"CHARACTER", c);
- c = '_';
- newState(states, pre?"PP_CHARACTER":"CHARACTER", c);
+
+ newState(states, pre?"PP_CHARACTER":"CHARACTER", '_');
+ newState(states, pre?"PP_CHARACTER":"CHARACTER", '$');
// add digits
for (c = '0'; c <= '9'; ++c)
diff --git a/src/tools/moc/utils.h b/src/tools/moc/utils.h
index aeb9b745f1..0dfd0999f4 100644
--- a/src/tools/moc/utils.h
+++ b/src/tools/moc/utils.h
@@ -60,7 +60,7 @@ inline bool is_ident_start(char s)
{
return ((s >= 'a' && s <= 'z')
|| (s >= 'A' && s <= 'Z')
- || s == '_'
+ || s == '_' || s == '$'
);
}
@@ -69,7 +69,7 @@ inline bool is_ident_char(char s)
return ((s >= 'a' && s <= 'z')
|| (s >= 'A' && s <= 'Z')
|| (s >= '0' && s <= '9')
- || s == '_'
+ || s == '_' || s == '$'
);
}
@@ -112,10 +112,10 @@ inline const char *skipQuote(const char *data)
}
++data;
}
-
+
if (*data) //Skip last quote
++data;
- return data;
+ return data;
}
QT_END_NAMESPACE
diff --git a/src/tools/qdbuscpp2xml/qdbuscpp2xml.cpp b/src/tools/qdbuscpp2xml/qdbuscpp2xml.cpp
index cdefd5bb37..a66757907d 100644
--- a/src/tools/qdbuscpp2xml/qdbuscpp2xml.cpp
+++ b/src/tools/qdbuscpp2xml/qdbuscpp2xml.cpp
@@ -52,8 +52,8 @@
#include <stdlib.h>
#include <string.h>
-#include "qdbusconnection.h" // for the Export* flags
-#include "qdbusconnection_p.h" // for the qDBusCheckAsyncTag
+#include <qdbusconnection.h> // for the Export* flags
+#include <private/qdbusconnection_p.h> // for the qDBusCheckAsyncTag
// copied from dbus-protocol.h:
static const char docTypeHeader[] =
@@ -64,9 +64,9 @@ static const char docTypeHeader[] =
#define QCLASSINFO_DBUS_INTERFACE "D-Bus Interface"
#define QCLASSINFO_DBUS_INTROSPECTION "D-Bus Introspection"
-#include "qdbusmetatype_p.h"
-#include "qdbusmetatype.h"
-#include "qdbusutil_p.h"
+#include <qdbusmetatype.h>
+#include <private/qdbusmetatype_p.h>
+#include <private/qdbusutil_p.h>
#include "moc.h"
#include "generator.h"
diff --git a/src/tools/qdbuscpp2xml/qdbuscpp2xml.pro b/src/tools/qdbuscpp2xml/qdbuscpp2xml.pro
index 02c3655f33..655158e457 100644
--- a/src/tools/qdbuscpp2xml/qdbuscpp2xml.pro
+++ b/src/tools/qdbuscpp2xml/qdbuscpp2xml.pro
@@ -1,26 +1,12 @@
option(host_build)
-
-include(../moc/moc.pri)
-
+QT = core-private
+force_bootstrap: QT += bootstrap_dbus-private
+else: QT += dbus-private
DEFINES += QT_NO_CAST_FROM_ASCII
-
-INCLUDEPATH += $$QT_BUILD_TREE/include \
- $$QT_BUILD_TREE/include/QtDBus \
- $$QT_BUILD_TREE/include/QtDBus/$$QT_VERSION \
- $$QT_BUILD_TREE/include/QtDBus/$$QT_VERSION/QtDBus \
- $$QT_SOURCE_TREE/src/dbus
-
-!isEmpty(DBUS_PATH): INCLUDEPATH += $$DBUS_PATH/include
-
QMAKE_CXXFLAGS += $$QT_CFLAGS_DBUS
-SOURCES += qdbuscpp2xml.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusmetatype.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusutil.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusmisc.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusargument.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusextratypes.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbus_symbols.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusunixfiledescriptor.cpp
+include(../moc/moc.pri)
+
+SOURCES += qdbuscpp2xml.cpp
load(qt_tool)
diff --git a/src/tools/qdbusxml2cpp/qdbusxml2cpp.cpp b/src/tools/qdbusxml2cpp/qdbusxml2cpp.cpp
index ce3936c301..e6d77643de 100644
--- a/src/tools/qdbusxml2cpp/qdbusxml2cpp.cpp
+++ b/src/tools/qdbusxml2cpp/qdbusxml2cpp.cpp
@@ -48,8 +48,8 @@
#include <qtextstream.h>
#include <qset.h>
-#include "qdbusmetatype.h"
-#include <qdbusintrospection_p.h>
+#include <qdbusmetatype.h>
+#include <private/qdbusintrospection_p.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/src/tools/qdbusxml2cpp/qdbusxml2cpp.pro b/src/tools/qdbusxml2cpp/qdbusxml2cpp.pro
index b473014938..dcc36c7913 100644
--- a/src/tools/qdbusxml2cpp/qdbusxml2cpp.pro
+++ b/src/tools/qdbusxml2cpp/qdbusxml2cpp.pro
@@ -1,26 +1,10 @@
option(host_build)
-
+QT = core-private
+force_bootstrap: QT += bootstrap_dbus-private
+else: QT += dbus-private
DEFINES += QT_NO_CAST_FROM_ASCII
-
-INCLUDEPATH += $$QT_BUILD_TREE/include \
- $$QT_BUILD_TREE/include/QtDBus \
- $$QT_BUILD_TREE/include/QtDBus/$$QT_VERSION \
- $$QT_BUILD_TREE/include/QtDBus/$$QT_VERSION/QtDBus \
- $$QT_SOURCE_TREE/src/dbus
-
-!isEmpty(DBUS_PATH): INCLUDEPATH += $$DBUS_PATH/include
-
QMAKE_CXXFLAGS += $$QT_CFLAGS_DBUS
-SOURCES = qdbusxml2cpp.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusintrospection.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusxmlparser.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbuserror.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusutil.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusmetatype.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusargument.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusextratypes.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbus_symbols.cpp \
- $$QT_SOURCE_TREE/src/dbus/qdbusunixfiledescriptor.cpp
+SOURCES = qdbusxml2cpp.cpp
load(qt_tool)
diff --git a/src/tools/qdoc/codemarker.cpp b/src/tools/qdoc/codemarker.cpp
index ff36064941..4e144d2f7d 100644
--- a/src/tools/qdoc/codemarker.cpp
+++ b/src/tools/qdoc/codemarker.cpp
@@ -381,8 +381,9 @@ QString CodeMarker::sortName(const Node *node, const QString* name)
if ((node->type() == Node::QmlMethod) ||
(node->type() == Node::QmlSignal) ||
(node->type() == Node::QmlSignalHandler)) {
- const FunctionNode* func = static_cast<const FunctionNode *>(node);
- return QLatin1Char('E') + func->signature();
+ //const FunctionNode* func = static_cast<const FunctionNode *>(node);
+ //return QLatin1Char('E') + func->name();
+ return QLatin1Char('E') + nodeName;
}
return QLatin1Char('B') + nodeName;
@@ -397,7 +398,8 @@ void CodeMarker::insert(FastSection &fastSection,
bool inheritedMember = false;
if (!node->relates()) {
if (node->parent() != fastSection.parent_) { // && !node->parent()->isAbstract()) {
- if (node->type() != Node::QmlProperty) {
+ if ((node->parent()->subType() != Node::QmlClass) || !node->parent()->isAbstract()) {
+ //if (node->type() != Node::QmlProperty) {
inheritedMember = true;
}
}
@@ -438,8 +440,7 @@ void CodeMarker::insert(FastSection &fastSection,
if (!irrelevant) {
if (!inheritedMember || style == Subpage) {
QString key = sortName(node);
- if (!fastSection.memberMap.contains(key))
- fastSection.memberMap.insert(key, node);
+ fastSection.memberMap.insertMulti(key, node);
}
else {
if (node->parent()->type() == Node::Class) {
@@ -519,14 +520,59 @@ bool CodeMarker::insertReimpFunc(FastSection& fs, Node* node, Status status)
void CodeMarker::append(QList<Section>& sectionList, const FastSection& fs, bool includeKeys)
{
if (!fs.isEmpty()) {
- Section section(fs.name,fs.divClass,fs.singularMember,fs.pluralMember);
- if (includeKeys) {
- section.keys = fs.memberMap.keys();
+ if (fs.classMapList_.isEmpty()) {
+ Section section(fs.name,fs.divClass,fs.singularMember,fs.pluralMember);
+ if (includeKeys) {
+ section.keys = fs.memberMap.keys();
+ }
+ section.members = fs.memberMap.values();
+ section.reimpMembers = fs.reimpMemberMap.values();
+ section.inherited = fs.inherited;
+ sectionList.append(section);
+ }
+ else {
+ Section section(fs.name,fs.divClass,fs.singularMember,fs.pluralMember);
+ sectionList.append(section);
+ Section* s = &sectionList[sectionList.size()-1];
+ for (int i=0; i<fs.classMapList_.size(); i++) {
+ ClassMap* classMap = fs.classMapList_[i];
+ ClassKeysNodes* ckn = new ClassKeysNodes;
+ ckn->first = classMap->first;
+ ckn->second.second = classMap->second.values();
+ ckn->second.first = classMap->second.keys();
+ s->classKeysNodesList_.append(ckn);
+ }
+ }
+ }
+}
+
+/*!
+ The destructor must delete each member of the
+ list of QML class lists, if it is not empty;
+ */
+Section::~Section()
+{
+ if (!classKeysNodesList_.isEmpty()) {
+ for (int i=0; i<classKeysNodesList_.size(); i++) {
+ ClassKeysNodes* classKeysNodes = classKeysNodesList_[i];
+ classKeysNodesList_[i] = 0;
+ delete classKeysNodes;
+ }
+ }
+}
+
+/*!
+ The destructor must delete the QML class maps in the class
+ map list, if the class map list is not empty.
+ */
+FastSection::~FastSection()
+{
+ if (!classMapList_.isEmpty()) {
+ for (int i=0; i<classMapList_.size(); i++) {
+ ClassMap* classMap = classMapList_[i];
+ classMapList_[i] = 0;
+ delete classMap;
}
- section.members = fs.memberMap.values();
- section.reimpMembers = fs.reimpMemberMap.values();
- section.inherited = fs.inherited;
- sectionList.append(section);
}
}
diff --git a/src/tools/qdoc/codemarker.h b/src/tools/qdoc/codemarker.h
index becd4b07c4..c31b43e875 100644
--- a/src/tools/qdoc/codemarker.h
+++ b/src/tools/qdoc/codemarker.h
@@ -56,6 +56,14 @@ QT_BEGIN_NAMESPACE
class Config;
class Tree;
+typedef QMultiMap<QString, Node*> MemberMap; // the string is the member signature
+typedef QPair<const QmlClassNode*, MemberMap> ClassMap; // the node is the QML type
+typedef QList<ClassMap*> ClassMapList;
+
+typedef QPair<QStringList, NodeList> KeysAndNodes;
+typedef QPair<const QmlClassNode*, KeysAndNodes> ClassKeysNodes;
+typedef QList<ClassKeysNodes*> ClassKeysNodesList;
+
struct Section
{
QString name;
@@ -66,6 +74,7 @@ struct Section
NodeList members;
NodeList reimpMembers;
QList<QPair<InnerNode *, int> > inherited;
+ ClassKeysNodesList classKeysNodesList_;
Section() { }
Section(const QString& name0,
@@ -76,6 +85,7 @@ struct Section
divClass(divClass0),
singularMember(singularMember0),
pluralMember(pluralMember0) { }
+ ~Section();
void appendMember(Node* node) { members.append(node); }
void appendReimpMember(Node* node) { reimpMembers.append(node); }
};
@@ -87,8 +97,9 @@ struct FastSection
QString divClass;
QString singularMember;
QString pluralMember;
- QMap<QString, Node *> memberMap;
- QMap<QString, Node *> reimpMemberMap;
+ QMultiMap<QString, Node *> memberMap;
+ QMultiMap<QString, Node *> reimpMemberMap;
+ ClassMapList classMapList_;
QList<QPair<InnerNode *, int> > inherited;
FastSection(const InnerNode *parent,
@@ -101,10 +112,12 @@ struct FastSection
divClass(divClass0),
singularMember(singularMember0),
pluralMember(pluralMember0) { }
+ ~FastSection();
bool isEmpty() const {
return (memberMap.isEmpty() &&
inherited.isEmpty() &&
- reimpMemberMap.isEmpty());
+ reimpMemberMap.isEmpty() &&
+ classMapList_.isEmpty());
}
};
diff --git a/src/tools/qdoc/cppcodemarker.cpp b/src/tools/qdoc/cppcodemarker.cpp
index ff7d9254fc..75e49f288a 100644
--- a/src/tools/qdoc/cppcodemarker.cpp
+++ b/src/tools/qdoc/cppcodemarker.cpp
@@ -142,8 +142,8 @@ QString CppCodeMarker::markedUpSynopsis(const Node *node,
name = linkTag(node, name);
name = "<@name>" + name + "</@name>";
- if (style == Detailed && !node->parent()->name().isEmpty() &&
- node->type() != Node::Property)
+ if ((style == Detailed) && !node->parent()->name().isEmpty() &&
+ (node->type() != Node::Property) && !node->isQmlNode())
name.prepend(taggedNode(node->parent()) + "::");
switch (node->type()) {
@@ -1258,10 +1258,24 @@ QList<Section> CppCodeMarker::qmlSections(const QmlClassNode* qmlClassNode, Syno
append(sections,qmlattachedmethods);
}
else {
+ /*
+ This is where the list of all members including inherited
+ members is prepared.
+ */
+ ClassMap* classMap = 0;
FastSection all(qmlClassNode,QString(),QString(),"member","members");
-
const QmlClassNode* current = qmlClassNode;
while (current != 0) {
+ /*
+ If the QML type is abstract, do not create
+ a new entry in the list for it. Instead,
+ add its members to the current entry.
+ */
+ if (!current->isAbstract()) {
+ classMap = new ClassMap;
+ classMap->first = current;
+ all.classMapList_.append(classMap);
+ }
NodeList::ConstIterator c = current->childNodes().constBegin();
while (c != current->childNodes().constEnd()) {
if ((*c)->subType() == Node::QmlPropertyGroup) {
@@ -1269,21 +1283,19 @@ QList<Section> CppCodeMarker::qmlSections(const QmlClassNode* qmlClassNode, Syno
NodeList::ConstIterator p = qpgn->childNodes().constBegin();
while (p != qpgn->childNodes().constEnd()) {
if ((*p)->type() == Node::QmlProperty) {
- QString key = current->name() + "::" + (*p)->name();
+ QString key = (*p)->name();
key = sortName(*p, &key);
- if (!all.memberMap.contains(key))
- all.memberMap.insert(key,*p);
- //insert(all,*p,style,Okay);
+ all.memberMap.insert(key,*p);
+ classMap->second.insert(key,*p);
}
++p;
}
}
else {
- QString key = current->name() + "::" + (*c)->name();
+ QString key = (*c)->name();
key = sortName(*c, &key);
- if (!all.memberMap.contains(key))
- all.memberMap.insert(key,*c);
- //insert(all,*c,style,Okay);
+ all.memberMap.insert(key,*c);
+ classMap->second.insert(key,*c);
}
++c;
}
diff --git a/src/tools/qdoc/doc.cpp b/src/tools/qdoc/doc.cpp
index a0a2e51198..12056502d5 100644
--- a/src/tools/qdoc/doc.cpp
+++ b/src/tools/qdoc/doc.cpp
@@ -2678,7 +2678,7 @@ QString DocParser::untabifyEtc(const QString& str)
if (c == QLatin1Char('\r'))
continue;
if (c == QLatin1Char('\t')) {
- result += " " + (column % tabSize);
+ result += &" "[column % tabSize];
column = ((column / tabSize) + 1) * tabSize;
continue;
}
@@ -3291,7 +3291,7 @@ QString Doc::canonicalTitle(const QString &title)
for (int i = 0; i != title.size(); ++i) {
uint c = title.at(i).unicode();
if (c >= 'A' && c <= 'Z')
- c -= 'A' - 'a';
+ c += 'a' - 'A';
bool alnum = (c >= 'a' && c <= 'z') || (c >= '0' && c <= '9');
if (alnum) {
result += QLatin1Char(c);
diff --git a/src/tools/qdoc/generator.cpp b/src/tools/qdoc/generator.cpp
index 95ba6d28bf..47ebded1b1 100644
--- a/src/tools/qdoc/generator.cpp
+++ b/src/tools/qdoc/generator.cpp
@@ -360,7 +360,7 @@ QString Generator::fileBase(const Node *node) const
QChar c = base.at(i);
uint u = c.unicode();
if (u >= 'A' && u <= 'Z')
- u -= 'A' - 'a';
+ u += 'a' - 'A';
if ((u >= 'a' && u <= 'z') || (u >= '0' && u <= '9')) {
res += QLatin1Char(u);
begun = true;
diff --git a/src/tools/qdoc/htmlgenerator.cpp b/src/tools/qdoc/htmlgenerator.cpp
index 69d1a69d31..7d7f9e811a 100644
--- a/src/tools/qdoc/htmlgenerator.cpp
+++ b/src/tools/qdoc/htmlgenerator.cpp
@@ -2067,8 +2067,38 @@ QString HtmlGenerator::generateAllQmlMembersFile(const QmlClassNode* qml_cn,
generateFullName(qml_cn, 0);
out() << ", including inherited members.</p>\n";
- Section section = sections.first();
- generateSectionList(section, 0, marker, CodeMarker::Subpage);
+ ClassKeysNodesList& cknl = sections.first().classKeysNodesList_;
+ if (!cknl.isEmpty()) {
+ for (int i=0; i<cknl.size(); i++) {
+ ClassKeysNodes* ckn = cknl[i];
+ const QmlClassNode* qcn = ckn->first;
+ KeysAndNodes& kn = ckn->second;
+ QStringList& keys = kn.first;
+ NodeList& nodes = kn.second;
+ if (nodes.isEmpty())
+ continue;
+ if (i != 0) {
+ out() << "<p>The following members are inherited from ";
+ generateFullName(qcn,0);
+ out() << ".</p>\n";
+ }
+ out() << "<ul>\n";
+ for (int j=0; j<keys.size(); j++) {
+ if (nodes[j]->access() == Node::Private) {
+ continue;
+ }
+ out() << "<li class=\"fn\">";
+ QString prefix;
+ if (!keys.isEmpty()) {
+ prefix = keys.at(j).mid(1);
+ prefix = prefix.left(keys.at(j).indexOf("::")+1);
+ }
+ generateSynopsis(nodes[j], qcn, marker, CodeMarker::Summary, false, &prefix);
+ out() << "</li>\n";
+ }
+ out() << "</ul>\n";
+ }
+ }
generateFooter();
endSubPage();
diff --git a/src/tools/qdoc/main.cpp b/src/tools/qdoc/main.cpp
index 50632f1da4..9c2dd4dcfc 100644
--- a/src/tools/qdoc/main.cpp
+++ b/src/tools/qdoc/main.cpp
@@ -40,7 +40,6 @@
****************************************************************************/
#include <qglobal.h>
-#include <qlibraryinfo.h>
#include <stdlib.h>
#include "codemarker.h"
#include "codeparser.h"
@@ -262,17 +261,6 @@ static void processQdocconfFile(const QString &fileName)
config.setStringList(CONFIG_OBSOLETELINKS, QStringList(obsoleteLinks ? "true" : "false"));
/*
- If QT_INSTALL_DOCS is not set, set it here so it can be used from
- the qdocconf files.
- */
- QString qt_install_docs = qgetenv("QT_INSTALL_DOCS");
- if (qt_install_docs.isEmpty()) {
- documentationPath = QLibraryInfo::rawLocation(QLibraryInfo::DocumentationPath,
- QLibraryInfo::EffectivePaths);
- qputenv("QT_INSTALL_DOCS", documentationPath.toLatin1());
- }
-
- /*
With the default configuration values in place, load
the qdoc configuration file. Note that the configuration
file may include other configuration files.
@@ -321,7 +309,7 @@ static void processQdocconfFile(const QString &fileName)
Load the language translators, if the configuration specifies any.
*/
QStringList fileNames = config.getStringList(CONFIG_TRANSLATORS);
- QStringList::Iterator fn = fileNames.constBegin();
+ QStringList::ConstIterator fn = fileNames.constBegin();
while (fn != fileNames.constEnd()) {
QTranslator *translator = new QTranslator(0);
if (!translator->load(*fn))
@@ -371,7 +359,9 @@ static void processQdocconfFile(const QString &fileName)
excludedDirsList = config.getCanonicalRelativePathList(CONFIG_EXCLUDEDIRS);
foreach (const QString &excludeDir, excludedDirsList) {
QString p = QDir::fromNativeSeparators(excludeDir);
- excludedDirs.insert(p);
+ QDir tmp(p);
+ if (tmp.exists())
+ excludedDirs.insert(p);
}
Generator::debugSegfault("Reading excludefiles");
diff --git a/src/tools/qdoc/node.cpp b/src/tools/qdoc/node.cpp
index abb348eb51..028c0a0b2a 100644
--- a/src/tools/qdoc/node.cpp
+++ b/src/tools/qdoc/node.cpp
@@ -662,6 +662,16 @@ bool InnerNode::hasMembers() const
}
/*!
+ Appends \a node to the members list, if and only if it
+ isn't already in the members list.
+ */
+void InnerNode::addMember(Node* node)
+{
+ if (!members_.contains(node))
+ members_.append(node);
+}
+
+/*!
Returns true if this node's members collection contains at
least one namespace node.
*/
@@ -1430,7 +1440,6 @@ NamespaceNode::NamespaceNode(InnerNode *parent, const QString& name)
ClassNode::ClassNode(InnerNode *parent, const QString& name)
: InnerNode(Class, parent, name)
{
- hidden = false;
abstract_ = false;
qmlelement = 0;
setPageType(ApiPage);
@@ -2188,6 +2197,20 @@ bool Node::setQmlModuleInfo(const QString& arg)
}
/*!
+ If this QML type node has a base type node,
+ return the fully qualified name of that QML
+ type, i.e. <QML-module-name>::<QML-type-name>.
+ */
+QString QmlClassNode::qmlFullBaseName() const
+{
+ QString result;
+ if (baseNode_) {
+ result = baseNode_->qmlModuleIdentifier() + "::" + baseNode_->name();
+ }
+ return result;
+}
+
+/*!
The name of this QML class node might be the same as the
name of some other QML class node. If so, then this node's
parent will be a NameCollisionNode.This function sets the
diff --git a/src/tools/qdoc/node.h b/src/tools/qdoc/node.h
index f76b115416..642bcec06a 100644
--- a/src/tools/qdoc/node.h
+++ b/src/tools/qdoc/node.h
@@ -240,6 +240,7 @@ public:
QString guid() const;
QString extractClassName(const QString &string) const;
virtual QString qmlTypeName() const { return name_; }
+ virtual QString qmlFullBaseName() const { return QString(); }
virtual QString qmlModuleName() const { return qmlModuleName_; }
virtual QString qmlModuleVersion() const { return qmlModuleVersionMajor_ + "." + qmlModuleVersionMinor_; }
virtual QString qmlModuleIdentifier() const { return qmlModuleName_ + qmlModuleVersionMajor_; }
@@ -332,7 +333,7 @@ public:
const NodeList & childNodes() const { return children_; }
const NodeList & relatedNodes() const { return related_; }
- virtual void addMember(Node* node) { members_.append(node); }
+ virtual void addMember(Node* node);
const NodeList& members() const { return members_; }
virtual bool hasMembers() const;
virtual bool hasNamespaces() const;
@@ -439,9 +440,6 @@ public:
const QList<RelatedClass> &derivedClasses() const { return derived; }
const QList<RelatedClass> &ignoredBaseClasses() const { return ignoredBases; }
- bool hideFromMainList() const { return hidden; }
- void setHideFromMainList(bool value) { hidden = value; }
-
QString serviceName() const { return sname; }
void setServiceName(const QString& value) { sname = value; }
QmlClassNode* qmlElement() { return qmlelement; }
@@ -455,7 +453,6 @@ private:
QList<RelatedClass> bases;
QList<RelatedClass> derived;
QList<RelatedClass> ignoredBases;
- bool hidden;
bool abstract_;
QString sname;
QmlClassNode* qmlelement;
@@ -563,6 +560,7 @@ public:
virtual bool isAbstract() const { return abstract_; }
virtual void setAbstract(bool b) { abstract_ = b; }
virtual bool isInternal() const { return (status() == Internal); }
+ virtual QString qmlFullBaseName() const;
const ImportList& importList() const { return importList_; }
void setImportList(const ImportList& il) { importList_ = il; }
const QString& qmlBaseName() const { return baseName_; }
diff --git a/src/tools/qdoc/qdoc.pro b/src/tools/qdoc/qdoc.pro
index 9df79ec718..3bd11bcd5b 100644
--- a/src/tools/qdoc/qdoc.pro
+++ b/src/tools/qdoc/qdoc.pro
@@ -1,6 +1,9 @@
option(host_build)
+QT = core xml
-DEFINES += QDOC2_COMPAT
+DEFINES += \
+ QT_QMLDEVTOOLS_LIB \ # force static exports even if not bootstrapping
+ QDOC2_COMPAT
INCLUDEPATH += $$QT_SOURCE_TREE/src/tools/qdoc \
$$QT_SOURCE_TREE/src/tools/qdoc/qmlparser
@@ -64,12 +67,11 @@ SOURCES += atom.cpp \
text.cpp \
tokenizer.cpp \
tree.cpp \
- yyindent.cpp \
- ../../corelib/tools/qcryptographichash.cpp
+ yyindent.cpp
### QML/JS Parser ###
-include(qmlparser/qmlparser.pri)
+include(qmlparser/parser.pri)
HEADERS += jscodemarker.h \
qmlcodemarker.h \
diff --git a/src/tools/qdoc/qdocdatabase.cpp b/src/tools/qdoc/qdocdatabase.cpp
index 256bc62dd2..30a9efaada 100644
--- a/src/tools/qdoc/qdocdatabase.cpp
+++ b/src/tools/qdoc/qdocdatabase.cpp
@@ -291,29 +291,29 @@ DocNode* QDocDatabase::addToModule(const QString& name, Node* node)
*/
DocNode* QDocDatabase::addToQmlModule(const QString& name, Node* node)
{
- QString longQmid, shortQmid;
+ QStringList qmid;
QStringList dotSplit;
QStringList blankSplit = name.split(QLatin1Char(' '));
+ qmid.append(blankSplit[0]);
if (blankSplit.size() > 1) {
- longQmid = blankSplit[0] + blankSplit[1];
+ qmid.append(blankSplit[0] + blankSplit[1]);
dotSplit = blankSplit[1].split(QLatin1Char('.'));
- shortQmid = blankSplit[0] + dotSplit[0];
+ qmid.append(blankSplit[0] + dotSplit[0]);
}
DocNode* dn = findQmlModule(name);
dn->addMember(node);
node->setQmlModuleInfo(name);
if (node->subType() == Node::QmlClass) {
QmlClassNode* n = static_cast<QmlClassNode*>(node);
- QString key = longQmid + "::" + node->name();
- for (int i=0; i<2; ++i) {
+ for (int i=0; i<qmid.size(); ++i) {
+ QString key = qmid[i] + "::" + node->name();
if (!qmlTypeMap_.contains(key))
qmlTypeMap_.insert(key,n);
if (!masterMap_.contains(key))
masterMap_.insert(key,node);
- if (!masterMap_.contains(node->name(),node))
- masterMap_.insert(node->name(),node);
- key = shortQmid + "::" + node->name();
}
+ if (!masterMap_.contains(node->name(),node))
+ masterMap_.insert(node->name(),node);
}
return dn;
}
@@ -448,18 +448,16 @@ void QDocDatabase::findAllClasses(const InnerNode* node)
!(*c)->parent()->name().isEmpty())
className = (*c)->parent()->name()+"::"+className;
- if (!(static_cast<const ClassNode *>(*c))->hideFromMainList()) {
- if ((*c)->status() == Node::Compat) {
- compatClasses_.insert(className, *c);
- }
- else if ((*c)->status() == Node::Obsolete) {
- obsoleteClasses_.insert(className, *c);
- }
- else {
- nonCompatClasses_.insert(className, *c);
- if ((*c)->status() == Node::Main)
- mainClasses_.insert(className, *c);
- }
+ if ((*c)->status() == Node::Compat) {
+ compatClasses_.insert(className, *c);
+ }
+ else if ((*c)->status() == Node::Obsolete) {
+ obsoleteClasses_.insert(className, *c);
+ }
+ else {
+ nonCompatClasses_.insert(className, *c);
+ if ((*c)->status() == Node::Main)
+ mainClasses_.insert(className, *c);
}
QString serviceName = (static_cast<const ClassNode *>(*c))->serviceName();
@@ -886,11 +884,16 @@ void QDocDatabase::resolveQmlInheritance(InnerNode* root)
QmlClassNode* qcn = static_cast<QmlClassNode*>(child);
if ((qcn->qmlBaseNode() == 0) && !qcn->qmlBaseName().isEmpty()) {
QmlClassNode* bqcn = 0;
- const ImportList& imports = qcn->importList();
- for (int i=0; i<imports.size(); ++i) {
- bqcn = findQmlType(imports[i], qcn->qmlBaseName());
- if (bqcn)
- break;
+ if (qcn->qmlBaseName().contains("::")) {
+ bqcn = qmlTypeMap_.value(qcn->qmlBaseName());
+ }
+ else {
+ const ImportList& imports = qcn->importList();
+ for (int i=0; i<imports.size(); ++i) {
+ bqcn = findQmlType(imports[i], qcn->qmlBaseName());
+ if (bqcn)
+ break;
+ }
}
if (bqcn == 0) {
bqcn = findQmlType(QString(), qcn->qmlBaseName());
diff --git a/src/tools/qdoc/qdocindexfiles.cpp b/src/tools/qdoc/qdocindexfiles.cpp
index 63d8639d0f..d7a51da952 100644
--- a/src/tools/qdoc/qdocindexfiles.cpp
+++ b/src/tools/qdoc/qdocindexfiles.cpp
@@ -64,6 +64,7 @@ QDocIndexFiles* QDocIndexFiles::qdocIndexFiles_ = NULL;
Constructs the singleton QDocIndexFiles.
*/
QDocIndexFiles::QDocIndexFiles()
+ : gen_( 0 )
{
qdb_ = QDocDatabase::qdocDB();
}
@@ -193,6 +194,9 @@ void QDocIndexFiles::readIndexSection(const QDomElement& element,
QString qmlModuleName = element.attribute("qml-module-name");
QString qmlModuleVersion = element.attribute("qml-module-version");
qdb_->addToQmlModule(qmlModuleName + " " + qmlModuleVersion, qcn);
+ QString qmlFullBaseName = element.attribute("qml-base-type");
+ if (!qmlFullBaseName.isEmpty())
+ qcn->setQmlBaseName(qmlFullBaseName);
if (element.hasAttribute("location"))
name = element.attribute("location", QString());
if (!indexUrl.isEmpty())
@@ -597,6 +601,7 @@ bool QDocIndexFiles::generateIndexSection(QXmlStreamWriter& writer,
QString nodeName;
QString qmlModuleName;
QString qmlModuleVersion;
+ QString qmlFullBaseName;
switch (node->type()) {
case Node::Namespace:
nodeName = "namespace";
@@ -610,6 +615,7 @@ bool QDocIndexFiles::generateIndexSection(QXmlStreamWriter& writer,
nodeName = "qmlclass";
qmlModuleName = node->qmlModuleName();
qmlModuleVersion = node->qmlModuleVersion();
+ qmlFullBaseName = node->qmlFullBaseName();
}
else if (node->subType() == Node::QmlBasicType)
nodeName = "qmlbasictype";
@@ -728,6 +734,8 @@ bool QDocIndexFiles::generateIndexSection(QXmlStreamWriter& writer,
if (!qmlModuleName.isEmpty()) {
writer.writeAttribute("qml-module-name", qmlModuleName);
writer.writeAttribute("qml-module-version", qmlModuleVersion);
+ if (!qmlFullBaseName.isEmpty())
+ writer.writeAttribute("qml-base-type", qmlFullBaseName);
}
QString fullName = node->fullDocumentName();
if (fullName != objName)
diff --git a/src/tools/qdoc/qmlcodeparser.cpp b/src/tools/qdoc/qmlcodeparser.cpp
index 02ab4b07fb..c86982eb95 100644
--- a/src/tools/qdoc/qmlcodeparser.cpp
+++ b/src/tools/qdoc/qmlcodeparser.cpp
@@ -86,6 +86,8 @@ QT_BEGIN_NAMESPACE
Constructs the QML code parser.
*/
QmlCodeParser::QmlCodeParser()
+ : lexer( 0 ),
+ parser( 0 )
{
}
diff --git a/src/tools/qdoc/qmlmarkupvisitor.cpp b/src/tools/qdoc/qmlmarkupvisitor.cpp
index 20cfeb1c4b..82836f02e8 100644
--- a/src/tools/qdoc/qmlmarkupvisitor.cpp
+++ b/src/tools/qdoc/qmlmarkupvisitor.cpp
@@ -407,7 +407,7 @@ bool QmlMarkupVisitor::visit(QQmlJS::AST::Elision *elision)
return true;
}
-bool QmlMarkupVisitor::visit(QQmlJS::AST::PropertyNameAndValueList *list)
+bool QmlMarkupVisitor::visit(QQmlJS::AST::PropertyNameAndValue *list)
{
QQmlJS::AST::Node::accept(list->name, this);
addVerbatim(list->colonToken, list->colonToken);
diff --git a/src/tools/qdoc/qmlmarkupvisitor.h b/src/tools/qdoc/qmlmarkupvisitor.h
index 6829260e58..7510dfbbea 100644
--- a/src/tools/qdoc/qmlmarkupvisitor.h
+++ b/src/tools/qdoc/qmlmarkupvisitor.h
@@ -94,7 +94,7 @@ public:
virtual bool visit(QQmlJS::AST::ElementList *);
virtual bool visit(QQmlJS::AST::Elision *);
- virtual bool visit(QQmlJS::AST::PropertyNameAndValueList *);
+ virtual bool visit(QQmlJS::AST::PropertyNameAndValue *);
virtual bool visit(QQmlJS::AST::ArrayMemberExpression *);
virtual bool visit(QQmlJS::AST::FieldMemberExpression *);
virtual bool visit(QQmlJS::AST::NewMemberExpression *);
diff --git a/src/tools/qdoc/qmlparser/qmlparser.pri b/src/tools/qdoc/qmlparser/parser.pri
index 6be85ba85a..e5b8ae2749 100644
--- a/src/tools/qdoc/qmlparser/qmlparser.pri
+++ b/src/tools/qdoc/qmlparser/parser.pri
@@ -8,7 +8,7 @@ HEADERS += \
$$PWD/qqmljsmemorypool_p.h \
$$PWD/qqmljsparser_p.h \
$$PWD/qqmljsglobal_p.h \
- $$PWD/qqmljskeywords_p.h
+ $$PWD/qqmljskeywords_p.h \
SOURCES += \
$$PWD/qqmljsast.cpp \
@@ -16,4 +16,7 @@ SOURCES += \
$$PWD/qqmljsengine_p.cpp \
$$PWD/qqmljsgrammar.cpp \
$$PWD/qqmljslexer.cpp \
- $$PWD/qqmljsparser.cpp
+ $$PWD/qqmljsparser.cpp \
+
+OTHER_FILES += \
+ $$PWD/qqmljs.g
diff --git a/src/tools/qdoc/qmlparser/qqmljs.g b/src/tools/qdoc/qmlparser/qqmljs.g
index bf1c5dd128..ff4f54374b 100644
--- a/src/tools/qdoc/qmlparser/qqmljs.g
+++ b/src/tools/qdoc/qmlparser/qqmljs.g
@@ -23,8 +23,8 @@
%parser QQmlJSGrammar
%decl qqmljsparser_p.h
-%impl qdeclarativejsparser.cpp
-%expect 2
+%impl qqmljsparser.cpp
+%expect 5
%expect-rr 2
%token T_AND "&" T_AND_AND "&&" T_AND_EQ "&="
@@ -60,12 +60,15 @@
%token T_RESERVED_WORD "reserved word"
%token T_MULTILINE_STRING_LITERAL "multiline string literal"
%token T_COMMENT "comment"
+%token T_COMPATIBILITY_SEMICOLON
--- context keywords.
%token T_PUBLIC "public"
%token T_IMPORT "import"
%token T_AS "as"
%token T_ON "on"
+%token T_GET "get"
+%token T_SET "set"
%token T_ERROR
@@ -78,7 +81,7 @@
%token T_FEED_JS_PROGRAM
%nonassoc SHIFT_THERE
-%nonassoc T_IDENTIFIER T_COLON T_SIGNAL T_PROPERTY T_READONLY
+%nonassoc T_IDENTIFIER T_COLON T_SIGNAL T_PROPERTY T_READONLY T_ON T_SET T_GET
%nonassoc REDUCE_HERE
%start TopLevel
@@ -124,16 +127,16 @@
**
****************************************************************************/
-#include <qdebug.h>
-#include <qcoreapplication.h>
-
-#include <string.h>
-
#include "qqmljsengine_p.h"
#include "qqmljslexer_p.h"
#include "qqmljsast_p.h"
#include "qqmljsmemorypool_p.h"
+#include <QtCore/qdebug.h>
+#include <QtCore/qcoreapplication.h>
+
+#include <string.h>
+
./
/:/****************************************************************************
@@ -190,20 +193,27 @@
//
//
-// This file is automatically generated from qmljs.g.
-// Changes will be lost.
+// W A R N I N G
+// -------------
+//
+// This file is automatically generated from qqmljs.g.
+// Changes should be made to that file, not here. Any change to this file will
+// be lost!
+//
+// To regenerate this file, run:
+// qlalr --no-debug --no-lines --qt qqmljs.g
//
-#ifndef QDECLARATIVEJSPARSER_P_H
-#define QDECLARATIVEJSPARSER_P_H
+#ifndef QQMLJSPARSER_P_H
+#define QQMLJSPARSER_P_H
#include "qqmljsglobal_p.h"
#include "qqmljsgrammar_p.h"
#include "qqmljsast_p.h"
#include "qqmljsengine_p.h"
-#include <qlist.h>
-#include <qstring.h>
+#include <QtCore/qlist.h>
+#include <QtCore/qstring.h>
QT_QML_BEGIN_NAMESPACE
@@ -232,7 +242,8 @@ public:
AST::FunctionDeclaration *FunctionDeclaration;
AST::Node *Node;
AST::PropertyName *PropertyName;
- AST::PropertyNameAndValueList *PropertyNameAndValueList;
+ AST::PropertyAssignment *PropertyAssignment;
+ AST::PropertyAssignmentList *PropertyAssignmentList;
AST::SourceElement *SourceElement;
AST::SourceElements *SourceElements;
AST::Statement *Statement;
@@ -380,11 +391,19 @@ protected:
/.
#include "qqmljsparser_p.h"
-#include <qvarlengtharray.h>
+#include <QtCore/qvarlengtharray.h>
+
+//
+// W A R N I N G
+// -------------
//
-// This file is automatically generated from qmljs.g.
-// Changes will be lost.
+// This file is automatically generated from qqmljs.g.
+// Changes should be made to that file, not here. Any change to this file will
+// be lost!
+//
+// To regenerate this file, run:
+// qlalr --no-debug --no-lines --qt qqmljs.g
//
using namespace QQmlJS;
@@ -413,6 +432,7 @@ Parser::Parser(Engine *engine):
state_stack(0),
location_stack(0),
string_stack(0),
+ program(0),
first_token(0),
last_token(0)
{
@@ -835,6 +855,7 @@ UiParameterList: UiParameterList T_COMMA UiPropertyType JsIdentifier ;
/.
case $rule_number: {
AST::UiParameterList *node = new (pool) AST::UiParameterList(sym(1).UiParameterList, stringRef(3), stringRef(4));
+ node->propertyTypeToken = loc(3);
node->commaToken = loc(2);
node->identifierToken = loc(4);
sym(1).Node = node;
@@ -1026,6 +1047,8 @@ JsIdentifier: T_PROPERTY ;
JsIdentifier: T_SIGNAL ;
JsIdentifier: T_READONLY ;
JsIdentifier: T_ON ;
+JsIdentifier: T_GET ;
+JsIdentifier: T_SET ;
--------------------------------------------------------------------------------------------------------
-- Expressions
@@ -1202,13 +1225,13 @@ case $rule_number: {
-- } break;
-- ./
-PrimaryExpression: T_LBRACE PropertyNameAndValueListOpt T_RBRACE ;
+PrimaryExpression: T_LBRACE PropertyAssignmentListOpt T_RBRACE ;
/.
case $rule_number: {
AST::ObjectLiteral *node = 0;
if (sym(2).Node)
node = new (pool) AST::ObjectLiteral(
- sym(2).PropertyNameAndValueList->finish ());
+ sym(2).PropertyAssignmentList->finish ());
else
node = new (pool) AST::ObjectLiteral();
node->lbraceToken = loc(1);
@@ -1217,11 +1240,11 @@ case $rule_number: {
} break;
./
-PrimaryExpression: T_LBRACE PropertyNameAndValueList T_COMMA T_RBRACE ;
+PrimaryExpression: T_LBRACE PropertyAssignmentList T_COMMA T_RBRACE ;
/.
case $rule_number: {
AST::ObjectLiteral *node = new (pool) AST::ObjectLiteral(
- sym(2).PropertyNameAndValueList->finish ());
+ sym(2).PropertyAssignmentList->finish ());
node->lbraceToken = loc(1);
node->rbraceToken = loc(4);
sym(1).Node = node;
@@ -1313,40 +1336,62 @@ case $rule_number: {
} break;
./
-PropertyNameAndValueList: PropertyName T_COLON AssignmentExpression ;
+PropertyAssignment: PropertyName T_COLON AssignmentExpression ;
/.
case $rule_number: {
- AST::PropertyNameAndValueList *node = new (pool) AST::PropertyNameAndValueList(
+ AST::PropertyNameAndValue *node = new (pool) AST::PropertyNameAndValue(
sym(1).PropertyName, sym(3).Expression);
node->colonToken = loc(2);
sym(1).Node = node;
} break;
./
-PropertyNameAndValueList: PropertyNameAndValueList T_COMMA PropertyName T_COLON AssignmentExpression ;
+PropertyAssignment: T_GET PropertyName T_LPAREN T_RPAREN T_LBRACE FunctionBodyOpt T_RBRACE ;
/.
case $rule_number: {
- AST::PropertyNameAndValueList *node = new (pool) AST::PropertyNameAndValueList(
- sym(1).PropertyNameAndValueList, sym(3).PropertyName, sym(5).Expression);
- node->commaToken = loc(2);
- node->colonToken = loc(4);
+ AST::PropertyGetterSetter *node = new (pool) AST::PropertyGetterSetter(
+ sym(2).PropertyName, sym(6).FunctionBody);
+ node->getSetToken = loc(1);
+ node->lparenToken = loc(3);
+ node->rparenToken = loc(4);
+ node->lbraceToken = loc(5);
+ node->rbraceToken = loc(7);
sym(1).Node = node;
} break;
./
-PropertyName: T_IDENTIFIER %prec SHIFT_THERE ;
+PropertyAssignment: T_SET PropertyName T_LPAREN FormalParameterListOpt T_RPAREN T_LBRACE FunctionBodyOpt T_RBRACE ;
/.
case $rule_number: {
- AST::IdentifierPropertyName *node = new (pool) AST::IdentifierPropertyName(stringRef(1));
- node->propertyNameToken = loc(1);
+ AST::PropertyGetterSetter *node = new (pool) AST::PropertyGetterSetter(
+ sym(2).PropertyName, sym(4).FormalParameterList, sym(7).FunctionBody);
+ node->getSetToken = loc(1);
+ node->lparenToken = loc(3);
+ node->rparenToken = loc(5);
+ node->lbraceToken = loc(6);
+ node->rbraceToken = loc(8);
sym(1).Node = node;
} break;
./
-PropertyName: T_SIGNAL ;
-/.case $rule_number:./
+PropertyAssignmentList: PropertyAssignment ;
+/.
+case $rule_number: {
+ sym(1).Node = new (pool) AST::PropertyAssignmentList(sym(1).PropertyAssignment);
+} break;
+./
+
+PropertyAssignmentList: PropertyAssignmentList T_COMMA PropertyAssignment ;
+/.
+case $rule_number: {
+ AST::PropertyAssignmentList *node = new (pool) AST::PropertyAssignmentList(
+ sym(1).PropertyAssignmentList, sym(3).PropertyAssignment);
+ node->commaToken = loc(2);
+ sym(1).Node = node;
+} break;
+./
-PropertyName: T_PROPERTY ;
+PropertyName: JsIdentifier %prec SHIFT_THERE ;
/.
case $rule_number: {
AST::IdentifierPropertyName *node = new (pool) AST::IdentifierPropertyName(stringRef(1));
@@ -2423,6 +2468,7 @@ case $rule_number: {
IterationStatement: T_DO Statement T_WHILE T_LPAREN Expression T_RPAREN T_AUTOMATIC_SEMICOLON ; -- automatic semicolon
+IterationStatement: T_DO Statement T_WHILE T_LPAREN Expression T_RPAREN T_COMPATIBILITY_SEMICOLON ; -- for JSC/V8 compatibility
IterationStatement: T_DO Statement T_WHILE T_LPAREN Expression T_RPAREN T_SEMICOLON ;
/.
case $rule_number: {
@@ -2651,20 +2697,7 @@ case $rule_number: {
} break;
./
-LabelledStatement: T_SIGNAL T_COLON Statement ;
-/.case $rule_number:./
-
-LabelledStatement: T_PROPERTY T_COLON Statement ;
-/.
-case $rule_number: {
- AST::LabelledStatement *node = new (pool) AST::LabelledStatement(stringRef(1), sym(3).Statement);
- node->identifierToken = loc(1);
- node->colonToken = loc(2);
- sym(1).Node = node;
-} break;
-./
-
-LabelledStatement: T_IDENTIFIER T_COLON Statement ;
+LabelledStatement: JsIdentifier T_COLON Statement ;
/.
case $rule_number: {
AST::LabelledStatement *node = new (pool) AST::LabelledStatement(stringRef(1), sym(3).Statement);
@@ -2744,7 +2777,12 @@ case $rule_number: {
} break;
./
-FunctionDeclaration: T_FUNCTION JsIdentifier T_LPAREN FormalParameterListOpt T_RPAREN T_LBRACE FunctionBodyOpt T_RBRACE ;
+-- tell the parser to prefer function declarations to function expressions.
+-- That is, the `Function' symbol is used to mark the start of a function
+-- declaration.
+Function: T_FUNCTION %prec REDUCE_HERE ;
+
+FunctionDeclaration: Function JsIdentifier T_LPAREN FormalParameterListOpt T_RPAREN T_LBRACE FunctionBodyOpt T_RBRACE ;
/.
case $rule_number: {
AST::FunctionDeclaration *node = new (pool) AST::FunctionDeclaration(stringRef(2), sym(4).FormalParameterList, sym(7).FunctionBody);
@@ -2758,7 +2796,7 @@ case $rule_number: {
} break;
./
-FunctionExpression: T_FUNCTION IdentifierOpt T_LPAREN FormalParameterListOpt T_RPAREN T_LBRACE FunctionBodyOpt T_RBRACE ;
+FunctionExpression: T_FUNCTION JsIdentifier T_LPAREN FormalParameterListOpt T_RPAREN T_LBRACE FunctionBodyOpt T_RBRACE ;
/.
case $rule_number: {
AST::FunctionExpression *node = new (pool) AST::FunctionExpression(stringRef(2), sym(4).FormalParameterList, sym(7).FunctionBody);
@@ -2773,6 +2811,19 @@ case $rule_number: {
} break;
./
+FunctionExpression: T_FUNCTION T_LPAREN FormalParameterListOpt T_RPAREN T_LBRACE FunctionBodyOpt T_RBRACE ;
+/.
+case $rule_number: {
+ AST::FunctionExpression *node = new (pool) AST::FunctionExpression(QStringRef(), sym(3).FormalParameterList, sym(6).FunctionBody);
+ node->functionToken = loc(1);
+ node->lparenToken = loc(2);
+ node->rparenToken = loc(4);
+ node->lbraceToken = loc(5);
+ node->rbraceToken = loc(7);
+ sym(1).Node = node;
+} break;
+./
+
FormalParameterList: JsIdentifier ;
/.
case $rule_number: {
@@ -2859,23 +2910,14 @@ case $rule_number: {
} break;
./
-IdentifierOpt: ;
-/.
-case $rule_number: {
- stringRef(1) = QStringRef();
-} break;
-./
-
-IdentifierOpt: JsIdentifier ;
-
-PropertyNameAndValueListOpt: ;
+PropertyAssignmentListOpt: ;
/.
case $rule_number: {
sym(1).Node = 0;
} break;
./
-PropertyNameAndValueListOpt: PropertyNameAndValueList ;
+PropertyAssignmentListOpt: PropertyAssignmentList ;
/.
} // switch
@@ -2887,7 +2929,8 @@ PropertyNameAndValueListOpt: PropertyNameAndValueList ;
const int errorState = state_stack[tos];
// automatic insertion of `;'
- if (yytoken != -1 && t_action(errorState, T_AUTOMATIC_SEMICOLON) && lexer->canInsertAutomaticSemicolon(yytoken)) {
+ if (yytoken != -1 && ((t_action(errorState, T_AUTOMATIC_SEMICOLON) && lexer->canInsertAutomaticSemicolon(yytoken))
+ || t_action(errorState, T_COMPATIBILITY_SEMICOLON))) {
SavedToken &tk = token_buffer[0];
tk.token = yytoken;
tk.dval = yylval;
@@ -3012,5 +3055,5 @@ QT_QML_END_NAMESPACE
-#endif // QDECLARATIVEJSPARSER_P_H
+#endif // QQMLJSPARSER_P_H
:/
diff --git a/src/tools/qdoc/qmlparser/qqmljsast.cpp b/src/tools/qdoc/qmlparser/qqmljsast.cpp
index 90ceeb9886..ea0df4a537 100644
--- a/src/tools/qdoc/qmlparser/qqmljsast.cpp
+++ b/src/tools/qdoc/qmlparser/qqmljsast.cpp
@@ -213,12 +213,32 @@ void Elision::accept0(Visitor *visitor)
visitor->endVisit(this);
}
-void PropertyNameAndValueList::accept0(Visitor *visitor)
+void PropertyNameAndValue::accept0(Visitor *visitor)
{
if (visitor->visit(this)) {
- for (PropertyNameAndValueList *it = this; it; it = it->next) {
- accept(it->name, visitor);
- accept(it->value, visitor);
+ accept(name, visitor);
+ accept(value, visitor);
+ }
+
+ visitor->endVisit(this);
+}
+
+void PropertyGetterSetter::accept0(Visitor *visitor)
+{
+ if (visitor->visit(this)) {
+ accept(name, visitor);
+ accept(formals, visitor);
+ accept(functionBody, visitor);
+ }
+
+ visitor->endVisit(this);
+}
+
+void PropertyAssignmentList::accept0(Visitor *visitor)
+{
+ if (visitor->visit(this)) {
+ for (PropertyAssignmentList *it = this; it; it = it->next) {
+ accept(it->assignment, visitor);
}
}
@@ -837,6 +857,13 @@ void UiObjectInitializer::accept0(Visitor *visitor)
visitor->endVisit(this);
}
+void UiParameterList::accept0(Visitor *visitor)
+{
+ if (visitor->visit(this)) {
+ }
+ visitor->endVisit(this);
+}
+
void UiObjectBinding::accept0(Visitor *visitor)
{
if (visitor->visit(this)) {
diff --git a/src/tools/qdoc/qmlparser/qqmljsast_p.h b/src/tools/qdoc/qmlparser/qqmljsast_p.h
index 03259ed614..01a872f1e8 100644
--- a/src/tools/qdoc/qmlparser/qqmljsast_p.h
+++ b/src/tools/qdoc/qmlparser/qqmljsast_p.h
@@ -57,7 +57,7 @@
#include "qqmljsglobal_p.h"
#include "qqmljsmemorypool_p.h"
-#include <qstring.h>
+#include <QtCore/qstring.h>
QT_QML_BEGIN_NAMESPACE
@@ -176,8 +176,10 @@ public:
Kind_PreDecrementExpression,
Kind_PreIncrementExpression,
Kind_Program,
+ Kind_PropertyAssignmentList,
+ Kind_PropertyGetterSetter,
Kind_PropertyName,
- Kind_PropertyNameAndValueList,
+ Kind_PropertyNameAndValue,
Kind_RegExpLiteral,
Kind_ReturnStatement,
Kind_SourceElement,
@@ -487,7 +489,7 @@ public:
ObjectLiteral():
properties (0) { kind = K; }
- ObjectLiteral(PropertyNameAndValueList *plist):
+ ObjectLiteral(PropertyAssignmentList *plist):
properties (plist) { kind = K; }
virtual void accept0(Visitor *visitor);
@@ -499,7 +501,7 @@ public:
{ return rbraceToken; }
// attributes
- PropertyNameAndValueList *properties;
+ PropertyAssignmentList *properties;
SourceLocation lbraceToken;
SourceLocation rbraceToken;
};
@@ -603,50 +605,113 @@ public:
SourceLocation propertyNameToken;
};
-class QML_PARSER_EXPORT PropertyNameAndValueList: public Node
+class QML_PARSER_EXPORT PropertyAssignment: public Node
{
public:
- QQMLJS_DECLARE_AST_NODE(PropertyNameAndValueList)
+ PropertyAssignment() {}
+};
- PropertyNameAndValueList(PropertyName *n, ExpressionNode *v):
- name (n), value (v), next (this)
- { kind = K; }
+class QML_PARSER_EXPORT PropertyAssignmentList: public Node
+{
+public:
+ QQMLJS_DECLARE_AST_NODE(PropertyAssignmentList)
- PropertyNameAndValueList(PropertyNameAndValueList *previous, PropertyName *n, ExpressionNode *v):
- name (n), value (v)
+ PropertyAssignmentList(PropertyAssignment *assignment)
+ : assignment(assignment)
+ , next(this)
+ { kind = K; }
+
+ PropertyAssignmentList(PropertyAssignmentList *previous, PropertyAssignment *assignment)
+ : assignment(assignment)
{
kind = K;
next = previous->next;
previous->next = this;
}
+ inline PropertyAssignmentList *finish ()
+ {
+ PropertyAssignmentList *front = next;
+ next = 0;
+ return front;
+ }
+
virtual void accept0(Visitor *visitor);
virtual SourceLocation firstSourceLocation() const
- { return name->firstSourceLocation(); }
+ { return assignment->firstSourceLocation(); }
virtual SourceLocation lastSourceLocation() const
- {
- if (next)
- return next->lastSourceLocation();
- return value->lastSourceLocation();
- }
+ { return next ? next->lastSourceLocation() : assignment->lastSourceLocation(); }
- inline PropertyNameAndValueList *finish ()
- {
- PropertyNameAndValueList *front = next;
- next = 0;
- return front;
- }
+// attributes
+ PropertyAssignment *assignment;
+ PropertyAssignmentList *next;
+ SourceLocation commaToken;
+};
+
+class QML_PARSER_EXPORT PropertyNameAndValue: public PropertyAssignment
+{
+public:
+ QQMLJS_DECLARE_AST_NODE(PropertyNameAndValue)
+
+ PropertyNameAndValue(PropertyName *n, ExpressionNode *v)
+ : name(n), value(v)
+ { kind = K; }
+
+ virtual void accept0(Visitor *visitor);
+
+ virtual SourceLocation firstSourceLocation() const
+ { return name->firstSourceLocation(); }
+
+ virtual SourceLocation lastSourceLocation() const
+ { return value->lastSourceLocation(); }
// attributes
PropertyName *name;
- ExpressionNode *value;
- PropertyNameAndValueList *next;
SourceLocation colonToken;
+ ExpressionNode *value;
SourceLocation commaToken;
};
+class QML_PARSER_EXPORT PropertyGetterSetter: public PropertyAssignment
+{
+public:
+ QQMLJS_DECLARE_AST_NODE(PropertyGetterSetter)
+
+ enum Type {
+ Getter,
+ Setter
+ };
+
+ PropertyGetterSetter(PropertyName *n, FunctionBody *b)
+ : type(Getter), name(n), formals(0), functionBody (b)
+ { kind = K; }
+
+ PropertyGetterSetter(PropertyName *n, FormalParameterList *f, FunctionBody *b)
+ : type(Setter), name(n), formals(f), functionBody (b)
+ { kind = K; }
+
+ virtual void accept0(Visitor *visitor);
+
+ virtual SourceLocation firstSourceLocation() const
+ { return getSetToken; }
+
+ virtual SourceLocation lastSourceLocation() const
+ { return rbraceToken; }
+
+// attributes
+ Type type;
+ SourceLocation getSetToken;
+ PropertyName *name;
+ SourceLocation lparenToken;
+ FormalParameterList *formals;
+ SourceLocation rparenToken;
+ SourceLocation lbraceToken;
+ FunctionBody *functionBody;
+ SourceLocation rbraceToken;
+};
+
class QML_PARSER_EXPORT IdentifierPropertyName: public PropertyName
{
public:
@@ -1642,7 +1707,7 @@ class QML_PARSER_EXPORT CaseBlock: public Node
public:
QQMLJS_DECLARE_AST_NODE(CaseBlock)
- explicit CaseBlock(CaseClauses *c, DefaultClause *d = 0, CaseClauses *r = 0):
+ CaseBlock(CaseClauses *c, DefaultClause *d = 0, CaseClauses *r = 0):
clauses (c), defaultClause (d), moreClauses (r)
{ kind = K; }
@@ -2402,7 +2467,7 @@ public:
previous->next = this;
}
- virtual void accept0(Visitor *) {}
+ virtual void accept0(Visitor *);
virtual SourceLocation firstSourceLocation() const
{ return propertyTypeToken; }
diff --git a/src/tools/qdoc/qmlparser/qqmljsastfwd_p.h b/src/tools/qdoc/qmlparser/qqmljsastfwd_p.h
index 986ef1deae..fe5572c4b2 100644
--- a/src/tools/qdoc/qmlparser/qqmljsastfwd_p.h
+++ b/src/tools/qdoc/qmlparser/qqmljsastfwd_p.h
@@ -39,12 +39,12 @@
**
****************************************************************************/
-#ifndef QQMLJSASTFWD_P_H
-#define QQMLJSASTFWD_P_H
+#ifndef QQMLJSAST_FWD_P_H
+#define QQMLJSAST_FWD_P_H
#include "qqmljsglobal_p.h"
-#include <qglobal.h>
+#include <QtCore/qglobal.h>
//
// W A R N I N G
@@ -64,7 +64,7 @@ namespace QQmlJS { namespace AST {
class SourceLocation
{
public:
- explicit SourceLocation(quint32 offset = 0, quint32 length = 0, quint32 line = 0, quint32 column = 0)
+ SourceLocation(quint32 offset = 0, quint32 length = 0, quint32 line = 0, quint32 column = 0)
: offset(offset), length(length),
startLine(line), startColumn(column)
{ }
@@ -98,7 +98,9 @@ class ArrayLiteral;
class ObjectLiteral;
class ElementList;
class Elision;
-class PropertyNameAndValueList;
+class PropertyAssignmentList;
+class PropertyGetterSetter;
+class PropertyNameAndValue;
class PropertyName;
class IdentifierPropertyName;
class StringLiteralPropertyName;
@@ -168,6 +170,7 @@ class UiProgram;
class UiImportList;
class UiImport;
class UiPublicMember;
+class UiParameterList;
class UiObjectDefinition;
class UiObjectInitializer;
class UiObjectBinding;
diff --git a/src/tools/qdoc/qmlparser/qqmljsastvisitor_p.h b/src/tools/qdoc/qmlparser/qqmljsastvisitor_p.h
index 703e18a39d..ef022f617c 100644
--- a/src/tools/qdoc/qmlparser/qqmljsastvisitor_p.h
+++ b/src/tools/qdoc/qmlparser/qqmljsastvisitor_p.h
@@ -80,6 +80,7 @@ public:
virtual bool visit(UiObjectBinding *) { return true; }
virtual bool visit(UiScriptBinding *) { return true; }
virtual bool visit(UiArrayBinding *) { return true; }
+ virtual bool visit(UiParameterList *) { return true; }
virtual bool visit(UiObjectMemberList *) { return true; }
virtual bool visit(UiArrayMemberList *) { return true; }
virtual bool visit(UiQualifiedId *) { return true; }
@@ -94,6 +95,7 @@ public:
virtual void endVisit(UiObjectBinding *) {}
virtual void endVisit(UiScriptBinding *) {}
virtual void endVisit(UiArrayBinding *) {}
+ virtual void endVisit(UiParameterList *) {}
virtual void endVisit(UiObjectMemberList *) {}
virtual void endVisit(UiArrayMemberList *) {}
virtual void endVisit(UiQualifiedId *) {}
@@ -135,8 +137,14 @@ public:
virtual bool visit(Elision *) { return true; }
virtual void endVisit(Elision *) {}
- virtual bool visit(PropertyNameAndValueList *) { return true; }
- virtual void endVisit(PropertyNameAndValueList *) {}
+ virtual bool visit(PropertyAssignmentList *) { return true; }
+ virtual void endVisit(PropertyAssignmentList *) {}
+
+ virtual bool visit(PropertyNameAndValue *) { return true; }
+ virtual void endVisit(PropertyNameAndValue *) {}
+
+ virtual bool visit(PropertyGetterSetter *) { return true; }
+ virtual void endVisit(PropertyGetterSetter *) {}
virtual bool visit(NestedExpression *) { return true; }
virtual void endVisit(NestedExpression *) {}
diff --git a/src/tools/qdoc/qmlparser/qqmljsengine_p.cpp b/src/tools/qdoc/qmlparser/qqmljsengine_p.cpp
index 8db6ce1641..7dc3b6f6cb 100644
--- a/src/tools/qdoc/qmlparser/qqmljsengine_p.cpp
+++ b/src/tools/qdoc/qmlparser/qqmljsengine_p.cpp
@@ -42,15 +42,15 @@
#include "qqmljsengine_p.h"
#include "qqmljsglobal_p.h"
-#include <qnumeric.h>
-#include <qhash.h>
-#include <qdebug.h>
+#include <QtCore/qnumeric.h>
+#include <QtCore/qhash.h>
+#include <QtCore/qdebug.h>
QT_QML_BEGIN_NAMESPACE
namespace QQmlJS {
-static int toDigit(char c)
+static inline int toDigit(char c)
{
if ((c >= '0') && (c <= '9'))
return c - '0';
diff --git a/src/tools/qdoc/qmlparser/qqmljsengine_p.h b/src/tools/qdoc/qmlparser/qqmljsengine_p.h
index 6f1411e29a..4f58e7f8ea 100644
--- a/src/tools/qdoc/qmlparser/qqmljsengine_p.h
+++ b/src/tools/qdoc/qmlparser/qqmljsengine_p.h
@@ -57,8 +57,8 @@
#include "qqmljsastfwd_p.h"
#include "qqmljsmemorypool_p.h"
-#include <qstring.h>
-#include <qset.h>
+#include <QtCore/qstring.h>
+#include <QtCore/qset.h>
QT_QML_BEGIN_NAMESPACE
diff --git a/src/tools/qdoc/qmlparser/qqmljsgrammar.cpp b/src/tools/qdoc/qmlparser/qqmljsgrammar.cpp
index 26a29e0640..4a5672a796 100644
--- a/src/tools/qdoc/qmlparser/qqmljsgrammar.cpp
+++ b/src/tools/qdoc/qmlparser/qqmljsgrammar.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtCore module of the Qt Toolkit.
+** This file is part of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -53,46 +53,47 @@ const char *const QQmlJSGrammar::spell [] = {
"||", "+", "+=", "++", "?", "}", "]", "%", "%=", "return",
")", ";", 0, "*", "*=", "string literal", "property", "signal", "readonly", "switch",
"this", "throw", "~", "try", "typeof", "var", "void", "while", "with", "^",
- "^=", "null", "true", "false", "const", "debugger", "reserved word", "multiline string literal", "comment", "public",
- "import", "as", "on", 0, 0, 0, 0, 0, 0, 0,
- 0, 0};
+ "^=", "null", "true", "false", "const", "debugger", "reserved word", "multiline string literal", "comment", 0,
+ "public", "import", "as", "on", "get", "set", 0, 0, 0, 0,
+ 0, 0, 0, 0, 0};
const short QQmlJSGrammar::lhs [] = {
- 102, 102, 102, 102, 102, 102, 103, 109, 109, 112,
- 112, 114, 113, 113, 113, 113, 113, 113, 113, 113,
- 116, 111, 110, 119, 119, 120, 120, 121, 121, 118,
- 107, 107, 107, 107, 123, 123, 123, 123, 123, 123,
- 123, 107, 131, 131, 131, 132, 132, 133, 133, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 117, 117, 117, 117,
- 117, 136, 136, 136, 136, 136, 136, 136, 136, 136,
- 136, 136, 136, 136, 136, 136, 136, 136, 136, 122,
- 138, 138, 138, 138, 137, 137, 140, 140, 142, 142,
- 142, 142, 142, 142, 143, 143, 143, 143, 143, 143,
- 143, 143, 143, 143, 143, 143, 143, 143, 143, 143,
- 143, 143, 143, 143, 143, 143, 143, 143, 143, 143,
- 143, 143, 143, 143, 143, 144, 144, 115, 115, 115,
- 115, 115, 147, 147, 148, 148, 148, 148, 146, 146,
- 149, 149, 150, 150, 151, 151, 151, 152, 152, 152,
- 152, 152, 152, 152, 152, 152, 152, 153, 153, 153,
- 153, 154, 154, 154, 155, 155, 155, 155, 156, 156,
- 156, 156, 156, 156, 156, 157, 157, 157, 157, 157,
- 157, 158, 158, 158, 158, 158, 159, 159, 159, 159,
- 159, 160, 160, 161, 161, 162, 162, 163, 163, 164,
- 164, 165, 165, 166, 166, 167, 167, 168, 168, 169,
- 169, 170, 170, 171, 171, 141, 141, 172, 172, 173,
- 173, 173, 173, 173, 173, 173, 173, 173, 173, 173,
- 173, 105, 105, 174, 174, 175, 175, 176, 176, 104,
- 104, 104, 104, 104, 104, 104, 104, 104, 104, 104,
- 104, 104, 104, 104, 124, 185, 185, 184, 184, 135,
- 135, 186, 186, 187, 187, 189, 189, 188, 190, 193,
- 191, 191, 194, 192, 192, 125, 126, 126, 127, 127,
- 177, 177, 177, 177, 177, 177, 177, 178, 178, 178,
- 178, 179, 179, 179, 179, 180, 180, 128, 129, 195,
- 195, 198, 198, 196, 196, 199, 197, 181, 181, 181,
- 182, 182, 130, 130, 130, 200, 201, 183, 183, 134,
- 145, 205, 205, 202, 202, 203, 203, 206, 108, 108,
- 207, 207, 106, 106, 204, 204, 139, 139, 208};
+ 105, 105, 105, 105, 105, 105, 106, 112, 112, 115,
+ 115, 117, 116, 116, 116, 116, 116, 116, 116, 116,
+ 119, 114, 113, 122, 122, 123, 123, 124, 124, 121,
+ 110, 110, 110, 110, 126, 126, 126, 126, 126, 126,
+ 126, 110, 134, 134, 134, 135, 135, 136, 136, 110,
+ 110, 110, 110, 110, 110, 110, 110, 110, 110, 110,
+ 110, 110, 110, 110, 110, 110, 120, 120, 120, 120,
+ 120, 120, 120, 139, 139, 139, 139, 139, 139, 139,
+ 139, 139, 139, 139, 139, 139, 139, 139, 139, 139,
+ 139, 125, 141, 141, 141, 141, 140, 140, 145, 145,
+ 145, 143, 143, 146, 146, 146, 146, 149, 149, 149,
+ 149, 149, 149, 149, 149, 149, 149, 149, 149, 149,
+ 149, 149, 149, 149, 149, 149, 149, 149, 149, 149,
+ 149, 149, 149, 149, 149, 149, 149, 149, 150, 150,
+ 118, 118, 118, 118, 118, 153, 153, 154, 154, 154,
+ 154, 152, 152, 155, 155, 156, 156, 157, 157, 157,
+ 158, 158, 158, 158, 158, 158, 158, 158, 158, 158,
+ 159, 159, 159, 159, 160, 160, 160, 161, 161, 161,
+ 161, 162, 162, 162, 162, 162, 162, 162, 163, 163,
+ 163, 163, 163, 163, 164, 164, 164, 164, 164, 165,
+ 165, 165, 165, 165, 166, 166, 167, 167, 168, 168,
+ 169, 169, 170, 170, 171, 171, 172, 172, 173, 173,
+ 174, 174, 175, 175, 176, 176, 177, 177, 144, 144,
+ 178, 178, 179, 179, 179, 179, 179, 179, 179, 179,
+ 179, 179, 179, 179, 108, 108, 180, 180, 181, 181,
+ 182, 182, 107, 107, 107, 107, 107, 107, 107, 107,
+ 107, 107, 107, 107, 107, 107, 107, 127, 191, 191,
+ 190, 190, 138, 138, 192, 192, 193, 193, 195, 195,
+ 194, 196, 199, 197, 197, 200, 198, 198, 128, 129,
+ 129, 130, 130, 183, 183, 183, 183, 183, 183, 183,
+ 183, 184, 184, 184, 184, 185, 185, 185, 185, 186,
+ 186, 131, 132, 201, 201, 204, 204, 202, 202, 205,
+ 203, 187, 188, 188, 133, 133, 133, 206, 207, 189,
+ 189, 208, 137, 151, 151, 209, 209, 148, 148, 147,
+ 147, 210, 111, 111, 211, 211, 109, 109, 142, 142,
+ 212};
const short QQmlJSGrammar::rhs [] = {
2, 2, 2, 2, 2, 2, 2, 1, 1, 1,
@@ -103,728 +104,759 @@ const short QQmlJSGrammar::rhs [] = {
6, 3, 3, 7, 7, 4, 4, 5, 5, 5,
6, 6, 10, 6, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 2, 3, 3, 4, 5, 3, 4, 3, 1,
- 1, 2, 3, 4, 1, 2, 3, 5, 1, 1,
+ 1, 1, 1, 2, 3, 3, 4, 5, 3, 4,
+ 3, 1, 1, 2, 3, 4, 1, 2, 3, 7,
+ 8, 1, 3, 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, 4,
- 3, 5, 1, 2, 4, 4, 4, 3, 0, 1,
- 1, 3, 1, 1, 1, 2, 2, 1, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 1, 3, 3,
- 3, 1, 3, 3, 1, 3, 3, 3, 1, 3,
- 3, 3, 3, 3, 3, 1, 3, 3, 3, 3,
- 3, 1, 3, 3, 3, 3, 1, 3, 3, 3,
- 3, 1, 3, 1, 3, 1, 3, 1, 3, 1,
- 3, 1, 3, 1, 3, 1, 3, 1, 3, 1,
- 3, 1, 5, 1, 5, 1, 3, 1, 3, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 3, 0, 1, 1, 3, 0, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 3, 1, 2, 0, 1, 3,
- 3, 1, 1, 1, 3, 1, 3, 2, 2, 2,
- 0, 1, 2, 0, 1, 1, 2, 2, 7, 5,
- 7, 7, 5, 9, 10, 7, 8, 2, 2, 3,
- 3, 2, 2, 3, 3, 3, 3, 5, 5, 3,
- 5, 1, 2, 0, 1, 4, 3, 3, 3, 3,
- 3, 3, 3, 3, 4, 5, 2, 2, 2, 8,
- 8, 1, 3, 0, 1, 0, 1, 1, 1, 1,
- 1, 2, 1, 1, 0, 1, 0, 1, 2};
+ 1, 1, 4, 3, 5, 1, 2, 4, 4, 4,
+ 3, 0, 1, 1, 3, 1, 1, 1, 2, 2,
+ 1, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 1, 3, 3, 3, 1, 3, 3, 1, 3, 3,
+ 3, 1, 3, 3, 3, 3, 3, 3, 1, 3,
+ 3, 3, 3, 3, 1, 3, 3, 3, 3, 1,
+ 3, 3, 3, 3, 1, 3, 1, 3, 1, 3,
+ 1, 3, 1, 3, 1, 3, 1, 3, 1, 3,
+ 1, 3, 1, 3, 1, 5, 1, 5, 1, 3,
+ 1, 3, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 3, 0, 1, 1, 3,
+ 0, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 3, 1, 2,
+ 0, 1, 3, 3, 1, 1, 1, 3, 1, 3,
+ 2, 2, 2, 0, 1, 2, 0, 1, 1, 2,
+ 2, 7, 5, 7, 7, 7, 5, 9, 10, 7,
+ 8, 2, 2, 3, 3, 2, 2, 3, 3, 3,
+ 3, 5, 5, 3, 5, 1, 2, 0, 1, 4,
+ 3, 3, 3, 3, 3, 3, 4, 5, 2, 2,
+ 2, 1, 8, 8, 7, 1, 3, 0, 1, 0,
+ 1, 1, 1, 1, 1, 2, 1, 1, 0, 1,
+ 2};
const short QQmlJSGrammar::action_default [] = {
- 0, 0, 22, 0, 0, 0, 22, 0, 175, 242,
- 206, 214, 210, 154, 226, 202, 3, 139, 73, 155,
- 218, 222, 143, 172, 153, 158, 138, 192, 179, 0,
- 80, 81, 76, 345, 67, 347, 0, 0, 0, 0,
- 78, 0, 0, 74, 77, 71, 0, 0, 68, 70,
- 69, 79, 72, 0, 75, 0, 0, 168, 0, 0,
- 155, 174, 157, 156, 0, 0, 0, 170, 171, 169,
- 173, 0, 203, 0, 0, 0, 0, 193, 0, 0,
- 0, 0, 0, 0, 183, 0, 0, 0, 177, 178,
- 176, 181, 185, 184, 182, 180, 195, 194, 196, 0,
- 211, 0, 207, 0, 0, 149, 136, 148, 137, 105,
- 106, 107, 132, 108, 133, 109, 110, 111, 112, 113,
- 114, 115, 116, 117, 118, 119, 120, 121, 134, 122,
- 123, 124, 125, 126, 127, 128, 129, 130, 131, 135,
- 0, 0, 147, 243, 150, 0, 151, 0, 152, 146,
- 0, 239, 232, 230, 237, 238, 236, 235, 241, 234,
- 233, 231, 240, 227, 0, 215, 0, 0, 219, 0,
- 0, 223, 0, 0, 149, 141, 0, 140, 0, 145,
- 159, 0, 346, 334, 335, 0, 332, 0, 333, 0,
- 336, 250, 257, 256, 264, 252, 0, 253, 337, 0,
- 344, 254, 255, 260, 258, 341, 338, 343, 261, 0,
- 272, 0, 0, 0, 0, 345, 67, 0, 347, 68,
- 244, 286, 69, 0, 0, 0, 273, 0, 0, 262,
- 263, 0, 251, 259, 287, 288, 331, 342, 0, 302,
- 303, 304, 305, 0, 298, 299, 300, 301, 328, 329,
- 0, 0, 0, 0, 0, 291, 292, 248, 246, 208,
- 216, 212, 228, 204, 249, 0, 155, 220, 224, 197,
- 186, 0, 0, 205, 0, 0, 0, 0, 198, 0,
- 0, 0, 0, 0, 190, 188, 191, 189, 187, 200,
- 199, 201, 0, 213, 0, 209, 0, 247, 155, 0,
- 229, 244, 245, 0, 244, 0, 0, 294, 0, 0,
- 0, 296, 0, 217, 0, 0, 221, 0, 0, 225,
- 284, 0, 276, 285, 279, 0, 283, 0, 244, 277,
- 0, 244, 0, 0, 295, 0, 0, 0, 297, 346,
- 334, 0, 0, 336, 0, 330, 0, 320, 0, 0,
- 0, 290, 0, 289, 0, 348, 0, 104, 266, 269,
- 0, 105, 272, 108, 133, 110, 111, 76, 115, 116,
- 67, 117, 120, 74, 77, 68, 244, 69, 79, 123,
- 72, 125, 75, 127, 128, 273, 130, 131, 135, 0,
- 97, 0, 0, 99, 103, 101, 88, 100, 102, 0,
- 98, 87, 267, 265, 143, 144, 149, 0, 142, 0,
- 319, 0, 306, 307, 0, 318, 0, 0, 0, 309,
- 314, 312, 315, 0, 0, 313, 314, 0, 310, 0,
- 311, 268, 317, 0, 268, 316, 0, 321, 322, 0,
- 268, 323, 324, 0, 0, 325, 0, 0, 0, 326,
- 327, 161, 160, 0, 0, 0, 293, 0, 0, 0,
- 308, 281, 274, 0, 282, 278, 0, 280, 270, 0,
- 271, 275, 91, 0, 0, 95, 82, 0, 84, 93,
- 0, 85, 94, 96, 86, 92, 83, 0, 89, 165,
- 163, 167, 164, 162, 166, 339, 6, 340, 4, 2,
- 65, 90, 0, 0, 68, 70, 69, 31, 5, 0,
- 66, 0, 45, 44, 43, 0, 0, 58, 0, 59,
- 35, 36, 37, 38, 40, 41, 62, 39, 0, 45,
- 0, 0, 0, 0, 0, 54, 0, 55, 0, 0,
- 26, 0, 0, 63, 27, 0, 30, 28, 24, 0,
- 29, 25, 0, 56, 0, 57, 143, 0, 60, 64,
- 0, 0, 0, 0, 61, 0, 52, 46, 53, 47,
- 0, 0, 0, 0, 49, 0, 50, 51, 48, 0,
- 0, 143, 268, 0, 0, 42, 105, 272, 108, 133,
- 110, 111, 76, 115, 116, 67, 117, 120, 74, 77,
- 68, 244, 69, 79, 123, 72, 125, 75, 127, 128,
- 273, 130, 131, 135, 0, 32, 33, 0, 34, 8,
- 0, 10, 0, 9, 0, 1, 21, 12, 0, 13,
- 0, 14, 0, 19, 20, 0, 15, 16, 0, 17,
- 18, 11, 23, 7, 349};
+ 0, 0, 22, 0, 0, 0, 22, 0, 178, 245,
+ 209, 217, 213, 157, 229, 205, 3, 142, 75, 158,
+ 221, 225, 146, 175, 156, 161, 141, 195, 182, 0,
+ 82, 83, 78, 0, 72, 67, 349, 0, 0, 0,
+ 0, 80, 0, 0, 76, 79, 71, 0, 0, 68,
+ 70, 73, 69, 81, 74, 0, 77, 0, 0, 171,
+ 0, 0, 158, 177, 160, 159, 0, 0, 0, 173,
+ 174, 172, 176, 0, 206, 0, 0, 0, 0, 196,
+ 0, 0, 0, 0, 0, 0, 186, 0, 0, 0,
+ 180, 181, 179, 184, 188, 187, 185, 183, 198, 197,
+ 199, 0, 214, 0, 210, 0, 0, 152, 139, 151,
+ 140, 108, 109, 110, 135, 111, 136, 112, 113, 114,
+ 115, 116, 117, 118, 119, 120, 121, 122, 123, 124,
+ 137, 125, 126, 127, 128, 129, 130, 131, 132, 133,
+ 134, 138, 0, 0, 150, 246, 153, 0, 154, 0,
+ 155, 149, 0, 242, 235, 233, 240, 241, 239, 238,
+ 244, 237, 236, 234, 243, 230, 0, 218, 0, 0,
+ 222, 0, 0, 226, 0, 0, 152, 144, 0, 143,
+ 0, 148, 162, 0, 338, 338, 339, 0, 336, 0,
+ 337, 0, 340, 253, 260, 259, 267, 255, 0, 256,
+ 0, 341, 0, 348, 257, 258, 75, 263, 261, 345,
+ 342, 347, 264, 0, 275, 0, 0, 0, 0, 332,
+ 0, 349, 247, 289, 0, 0, 0, 276, 0, 0,
+ 265, 266, 0, 254, 262, 290, 291, 0, 338, 0,
+ 0, 340, 0, 333, 334, 0, 322, 346, 0, 306,
+ 307, 308, 309, 0, 302, 303, 304, 305, 330, 331,
+ 0, 0, 0, 0, 0, 294, 295, 296, 251, 249,
+ 211, 219, 215, 231, 207, 252, 0, 158, 223, 227,
+ 200, 189, 0, 0, 208, 0, 0, 0, 0, 201,
+ 0, 0, 0, 0, 0, 193, 191, 194, 192, 190,
+ 203, 202, 204, 0, 216, 0, 212, 0, 250, 158,
+ 0, 232, 247, 248, 0, 247, 0, 0, 298, 0,
+ 0, 0, 300, 0, 220, 0, 0, 224, 0, 0,
+ 228, 287, 0, 279, 288, 282, 0, 286, 0, 247,
+ 280, 0, 247, 0, 0, 299, 0, 0, 0, 301,
+ 0, 0, 0, 293, 0, 292, 75, 102, 350, 0,
+ 0, 107, 269, 272, 0, 108, 275, 111, 136, 113,
+ 114, 78, 118, 119, 72, 120, 123, 76, 79, 247,
+ 73, 81, 126, 74, 128, 77, 130, 131, 276, 133,
+ 134, 138, 0, 104, 103, 106, 90, 105, 89, 0,
+ 99, 270, 268, 0, 0, 0, 340, 0, 100, 146,
+ 147, 152, 0, 145, 0, 310, 311, 0, 338, 0,
+ 0, 340, 0, 101, 0, 0, 0, 313, 318, 316,
+ 319, 0, 0, 317, 318, 0, 314, 0, 315, 271,
+ 321, 0, 271, 320, 0, 323, 324, 0, 271, 325,
+ 326, 0, 0, 327, 0, 0, 0, 328, 329, 164,
+ 163, 0, 0, 0, 297, 0, 0, 0, 312, 284,
+ 277, 0, 285, 281, 0, 283, 273, 0, 274, 278,
+ 0, 0, 340, 0, 335, 93, 0, 0, 97, 84,
+ 0, 86, 95, 0, 87, 96, 98, 88, 94, 85,
+ 0, 91, 168, 166, 170, 167, 165, 169, 343, 6,
+ 344, 4, 2, 65, 92, 0, 0, 68, 70, 69,
+ 31, 5, 0, 66, 0, 45, 44, 43, 0, 0,
+ 58, 0, 59, 35, 36, 37, 38, 40, 41, 62,
+ 39, 0, 45, 0, 0, 0, 0, 0, 54, 0,
+ 55, 0, 0, 26, 0, 0, 63, 27, 0, 30,
+ 28, 24, 0, 29, 25, 0, 56, 0, 57, 146,
+ 0, 60, 64, 0, 0, 0, 0, 61, 0, 52,
+ 46, 53, 47, 0, 0, 0, 0, 49, 0, 50,
+ 51, 48, 0, 0, 146, 271, 0, 0, 42, 75,
+ 108, 275, 111, 136, 113, 114, 78, 118, 119, 120,
+ 123, 76, 79, 247, 81, 126, 74, 128, 77, 130,
+ 131, 276, 133, 134, 138, 0, 32, 33, 0, 34,
+ 8, 0, 10, 0, 9, 0, 1, 21, 12, 0,
+ 13, 0, 14, 0, 19, 20, 0, 15, 16, 0,
+ 17, 18, 11, 23, 7, 351};
const short QQmlJSGrammar::goto_default [] = {
- 7, 625, 207, 196, 205, 508, 496, 624, 643, 495,
- 623, 621, 626, 22, 622, 18, 507, 549, 539, 546,
- 541, 526, 191, 195, 197, 201, 233, 208, 230, 530,
- 570, 569, 200, 232, 26, 474, 473, 356, 355, 9,
- 354, 357, 107, 17, 145, 24, 13, 144, 19, 25,
- 57, 23, 8, 28, 27, 269, 15, 263, 10, 259,
- 12, 261, 11, 260, 20, 267, 21, 268, 14, 262,
- 258, 299, 411, 264, 265, 202, 193, 192, 204, 203,
- 229, 194, 360, 359, 231, 463, 462, 321, 322, 465,
- 324, 464, 323, 419, 423, 426, 422, 421, 441, 442,
- 185, 199, 181, 184, 198, 206, 0};
+ 7, 636, 211, 198, 209, 521, 509, 635, 654, 508,
+ 634, 632, 637, 22, 633, 18, 520, 562, 552, 559,
+ 554, 539, 193, 197, 199, 204, 234, 212, 231, 543,
+ 583, 582, 203, 233, 26, 487, 486, 359, 358, 9,
+ 357, 360, 202, 480, 361, 109, 17, 147, 24, 13,
+ 146, 19, 25, 59, 23, 8, 28, 27, 280, 15,
+ 274, 10, 270, 12, 272, 11, 271, 20, 278, 21,
+ 279, 14, 273, 269, 310, 414, 275, 276, 205, 195,
+ 194, 208, 207, 230, 196, 364, 363, 232, 471, 470,
+ 332, 333, 473, 335, 472, 334, 427, 431, 434, 430,
+ 429, 449, 450, 200, 186, 201, 210, 0};
const short QQmlJSGrammar::action_index [] = {
- 404, 1275, 2411, 2411, 2509, 1000, 68, 92, 90, -102,
- 88, 62, 60, 256, -102, 298, 86, -102, -102, 638,
- 83, 134, 172, 219, -102, -102, -102, 454, 194, 1275,
- -102, -102, -102, 381, -102, 2215, 1555, 1275, 1275, 1275,
- -102, 790, 1275, -102, -102, -102, 1275, 1275, -102, -102,
- -102, -102, -102, 1275, -102, 1275, 1275, -102, 1275, 1275,
- 102, 217, -102, -102, 1275, 1275, 1275, -102, -102, -102,
- 204, 1275, 304, 1275, 1275, 1275, 1275, 539, 1275, 1275,
- 1275, 1275, 1275, 1275, 308, 1275, 1275, 1275, 103, 131,
- 135, 308, 210, 225, 216, 308, 444, 390, 434, 1275,
- 82, 1275, 100, 2117, 1275, 1275, -102, -102, -102, -102,
- -102, -102, -102, -102, -102, -102, -102, -102, -102, -102,
- -102, -102, -102, -102, -102, -102, -102, -102, -102, -102,
- -102, -102, -102, -102, -102, -102, -102, -102, -102, -102,
- 139, 1275, -102, -102, 91, 10, -102, 1275, -102, -102,
- 1275, -102, -102, -102, -102, -102, -102, -102, -102, -102,
- -102, -102, -102, -102, 1275, 26, 1275, 1275, 69, 66,
- 1275, -102, 2117, 1275, 1275, -102, 97, -102, 44, -102,
- -102, 67, -102, 297, 78, 24, -102, 291, -102, 36,
- 2411, -102, -102, -102, -102, -102, 234, -102, -102, 12,
- -102, -102, -102, -102, -102, -102, 2411, -102, -102, 464,
- -102, 461, 115, 2509, 42, 381, 58, 46, 2705, 70,
- 1275, -102, 74, 57, 1275, 65, -102, 59, 61, -102,
- -102, 367, -102, -102, -102, -102, -102, -102, 106, -102,
- -102, -102, -102, 87, -102, -102, -102, -102, -102, -102,
- 56, 55, 1275, 99, 84, -102, -102, 1461, -102, 75,
- 48, 52, -102, 306, 72, 53, 579, 77, 110, 370,
- 230, 381, 1275, 286, 1275, 1275, 1275, 1275, 380, 1275,
- 1275, 1275, 1275, 1275, 184, 169, 166, 190, 198, 460,
- 363, 353, 1275, 50, 1275, 63, 1275, -102, 638, 1275,
- -102, 1275, 64, 39, 1275, 30, 2509, -102, 1275, 173,
- 2509, -102, 1275, 79, 1275, 1275, 81, 80, 1275, -102,
- 71, 149, 32, -102, -102, 1275, -102, 381, 1275, -102,
- 73, 1275, 76, 2509, -102, 1275, 142, 2509, -102, -16,
- 381, -42, -12, 2411, -39, -102, 2509, -102, 1275, 154,
- 2509, 14, 2509, -102, 20, 16, -32, -102, -102, 2509,
- -51, 519, -4, 511, 136, 1275, 2509, -2, -35, 395,
- -1, -27, 908, 4, 6, -102, 1370, -102, 0, -36,
- 27, 1275, 47, 22, 1275, 45, 1275, 21, 17, 1275,
- -102, 2313, 144, -102, -102, -102, -102, -102, -102, 1275,
- -102, -102, -102, -102, 274, -102, 1275, -21, -102, 2509,
- -102, 138, -102, -102, 2509, -102, 1275, 132, 5, -102,
- 40, -102, 41, 101, 1275, -102, 38, 34, -102, -38,
- -102, 2509, -102, 105, 2509, -102, 245, -102, -102, 96,
- 2509, 11, -102, -7, -11, -102, 352, 8, 18, -102,
- -102, -102, -102, 1275, 129, 2509, -102, 1275, 130, 2509,
- -102, 49, -102, 226, -102, -102, 1275, -102, -102, 362,
- -102, -102, -102, 107, 1837, -102, -102, 1649, -102, -102,
- 1743, -102, -102, -102, -102, -102, -102, 114, -102, -102,
- -102, -102, -102, -102, -102, -102, -102, 2411, -102, -102,
- -102, 94, 9, 818, 189, -10, 31, -102, -102, 223,
- -102, 191, -102, -102, -102, 300, 178, -102, 1928, -102,
- -102, -102, -102, -102, -102, -102, -102, -102, 257, -25,
- 381, 195, -22, 305, 240, -102, -6, -102, 818, 127,
- -102, -18, 818, -102, -102, 1184, -102, -102, -102, 1092,
- -102, -102, 237, -102, 1928, -102, 294, -8, -102, -102,
- 176, 381, 19, 1928, -102, 165, -102, 174, -102, 2,
- -52, 381, 183, 381, -102, 117, -102, -102, -102, 2019,
- 880, 285, 2607, 1555, 3, -102, 522, 35, 453, 108,
- 1275, 2509, 51, 23, 475, 54, -17, 700, 7, 43,
- -102, 1370, -102, 28, -3, 33, 1275, 37, 15, 1275,
- 25, 1275, 1, 13, 124, -102, -102, 29, -102, -102,
- 728, -102, 250, -43, 627, -102, -102, 231, 372, -102,
- 222, -102, 111, -102, -102, 381, -102, -102, 104, -102,
- -102, -102, -102, -102, -102,
+ 235, 1289, 2663, 2663, 2562, 1005, 64, 90, 103, -105,
+ 88, 94, 79, 173, -105, 302, 69, -105, -105, 724,
+ 65, 135, 195, 239, -105, -105, -105, 367, 278, 1289,
+ -105, -105, -105, 485, -105, -105, 2360, 1772, 1289, 1289,
+ 1289, -105, 817, 1289, -105, -105, -105, 1289, 1289, -105,
+ -105, -105, -105, -105, -105, 1289, -105, 1289, 1289, -105,
+ 1289, 1289, 95, 207, -105, -105, 1289, 1289, 1289, -105,
+ -105, -105, 202, 1289, 300, 1289, 1289, 1289, 1289, 377,
+ 1289, 1289, 1289, 1289, 1289, 1289, 253, 1289, 1289, 1289,
+ 151, 147, 129, 196, 170, 199, 279, 270, 470, 470,
+ 387, 1289, 53, 1289, 80, 2158, 1289, 1289, -105, -105,
+ -105, -105, -105, -105, -105, -105, -105, -105, -105, -105,
+ -105, -105, -105, -105, -105, -105, -105, -105, -105, -105,
+ -105, -105, -105, -105, -105, -105, -105, -105, -105, -105,
+ -105, -105, 128, 1289, -105, -105, 74, 52, -105, 1289,
+ -105, -105, 1289, -105, -105, -105, -105, -105, -105, -105,
+ -105, -105, -105, -105, -105, -105, 1289, 51, 1289, 1289,
+ 77, 66, 1289, -105, 2158, 1289, 1289, -105, 125, -105,
+ 48, -105, -105, 47, 451, 374, 83, 87, -105, 397,
+ -105, 62, 2663, -105, -105, -105, -105, -105, 205, -105,
+ 415, -105, 68, -105, -105, -105, 86, -105, -105, -105,
+ 2663, -105, -105, 622, -105, 576, 102, 2562, 75, 89,
+ 81, 2865, 1289, -105, 70, 1289, 63, -105, 92, 93,
+ -105, -105, 546, -105, -105, -105, -105, 91, 546, 40,
+ 45, 2663, 49, -105, -105, 2562, -105, -105, 106, -105,
+ -105, -105, -105, 121, -105, -105, -105, -105, -105, -105,
+ 42, 44, 1289, 114, 222, -105, -105, -105, 1481, -105,
+ 84, 57, 56, -105, 388, 78, 54, 682, 82, 99,
+ 357, 247, 546, 1289, 295, 1289, 1289, 1289, 1289, 334,
+ 1289, 1289, 1289, 1289, 1289, 203, 217, 244, 263, 211,
+ 341, 319, 351, 1289, 56, 1289, 73, 1289, -105, 724,
+ 1289, -105, 1289, 67, 46, 1289, 61, 2562, -105, 1289,
+ 136, 2562, -105, 1289, 76, 1289, 1289, 85, 59, 1289,
+ -105, 71, 133, 72, -105, -105, 1289, -105, 546, 1289,
+ -105, -53, 1289, -60, 2562, -105, 1289, 143, 2562, -105,
+ 1289, 132, 2562, 8, 2562, -105, 7, -105, 12, -37,
+ 107, -105, -105, 2562, -33, 622, 22, 555, 115, 1289,
+ 2562, 23, -13, 502, 2259, -10, 817, 18, 6, 1387,
+ 2259, 0, 9, -6, 1289, -4, -23, 1289, 5, 1289,
+ -25, -27, 2461, -105, -105, -105, -105, -105, -105, 1289,
+ -105, -105, -105, -3, -1, 21, 2663, 1, -105, 218,
+ -105, 1289, 4, -105, 111, -105, -105, 26, 466, 16,
+ 38, 2663, 39, -105, 1289, 110, 37, -105, 55, -105,
+ 60, 116, 1289, -105, 58, 43, -105, -15, -105, 2562,
+ -105, 123, 2562, -105, 154, -105, -105, 96, 2562, 32,
+ -105, 3, 14, -105, 546, -11, 13, -105, -105, -105,
+ -105, 1289, 126, 2562, -105, 1289, 130, 2562, -105, 15,
+ -105, 301, -105, -105, 1289, -105, -105, 546, -105, -105,
+ -45, -12, 2663, -24, -105, -105, 204, 1578, -105, -105,
+ 1869, -105, -105, 1675, -105, -105, -105, -105, -105, -105,
+ 101, -105, -105, -105, -105, -105, -105, -105, -105, -105,
+ 2663, -105, -105, -105, 105, 2, 910, 206, -47, -2,
+ -105, -105, 246, -105, 214, -105, -105, -105, 364, 232,
+ -105, 1963, -105, -105, -105, -105, -105, -105, -105, -105,
+ -105, 191, 24, 394, 172, -18, 384, 215, -105, -30,
+ -105, 910, 149, -105, -16, 910, -105, -105, 1100, -105,
+ -105, -105, 1195, -105, -105, 225, -105, 1963, -105, 316,
+ -17, -105, -105, 269, 418, -5, 1963, -105, 184, -105,
+ 175, -105, 20, -9, 546, 182, 469, -105, 104, -105,
+ -105, -105, 2057, 910, 292, 2764, 1772, 10, -105, 35,
+ 622, 34, 525, 98, 1289, 2562, 50, 17, 536, 19,
+ 817, 31, 27, 1387, 28, 9, 29, 1289, 30, 11,
+ 1289, 41, 1289, 33, 36, 137, -105, -105, 25, -105,
+ -105, 910, -105, 268, -86, 910, -105, -105, 141, 546,
+ -105, 156, -105, 117, -105, -105, 546, -105, -105, 138,
+ -105, -105, -105, -105, -105, -105,
- -107, 9, -103, 2, 5, 266, 1, -107, -107, -107,
- -107, -107, -107, -107, -107, -107, -107, -107, -107, -39,
- -107, -107, -107, -107, -107, -107, -107, -107, -107, 86,
- -107, -107, -107, 8, -107, -107, -22, 19, 71, 174,
- -107, 186, 171, -107, -107, -107, 184, 178, -107, -107,
- -107, -107, -107, 144, -107, 124, 150, -107, 165, 161,
- -107, -107, -107, -107, 156, 160, 157, -107, -107, -107,
- -107, 147, -107, 142, 135, 179, 166, -107, 177, 170,
- 117, 72, 134, 92, -107, 75, 94, 66, -107, -107,
- -107, -107, -107, -107, -107, -107, -107, -107, -107, 181,
- -107, 106, -107, 143, 78, 55, -107, -107, -107, -107,
- -107, -107, -107, -107, -107, -107, -107, -107, -107, -107,
- -107, -107, -107, -107, -107, -107, -107, -107, -107, -107,
- -107, -107, -107, -107, -107, -107, -107, -107, -107, -107,
- -107, -5, -107, -107, -107, -107, -107, 54, -107, -107,
- 51, -107, -107, -107, -107, -107, -107, -107, -107, -107,
- -107, -107, -107, -107, 114, -107, 113, 38, -107, -107,
- 41, -107, 231, 63, 112, -107, -107, -107, -107, -107,
- -107, -107, -107, 30, -107, -107, -107, 52, -107, -107,
- -107, -107, -107, -107, -107, -107, -107, -107, -107, -107,
- -107, -107, -107, -107, -107, -107, 36, -107, -107, 45,
- -107, 42, -107, 40, -107, 80, -107, -107, 77, -107,
- 88, -107, -107, -107, 83, 74, -107, -107, -107, -107,
- -107, -10, -107, -107, -107, -107, -107, -107, -107, -107,
- -107, -107, -107, -107, -107, -107, -107, -107, -107, -107,
- -107, -107, 23, -107, -107, -107, -107, 100, -107, -107,
- -107, -107, -107, -107, -107, -107, -107, -107, -107, -107,
- -107, 4, 223, -107, 230, 236, 222, 205, -107, 127,
- 125, 115, 96, 102, -107, -107, -107, -107, -107, -107,
- -107, -107, 234, -107, 215, -107, 199, -107, -107, 197,
- -107, 190, -107, -107, 163, -107, 90, -107, 0, -107,
- -1, -107, 203, -107, 189, 211, -107, -107, 195, -107,
- -107, -107, -107, -107, -107, 191, -107, 98, 119, -107,
- -107, 95, -107, 81, -107, 79, -107, 82, -107, -107,
- 101, -107, -107, -16, -107, -107, 53, -107, 46, -107,
- 57, -107, 59, -107, -107, -107, -107, -107, -107, 35,
- -107, 33, -107, 39, -107, 89, 67, -107, -107, 58,
- -107, -107, 84, -107, -107, -107, 73, -107, -107, -107,
- -107, 65, -107, 43, 93, -107, 109, -107, -107, 49,
- -107, 47, -107, -107, -107, -107, -107, -107, -107, 50,
- -107, -107, -107, -107, -107, -107, 108, -107, -107, 61,
- -107, -107, -107, -107, 62, -107, 68, -107, -107, -107,
- -107, -107, -23, -107, 69, -107, -19, -107, -107, -107,
- -107, 97, -107, -107, 99, -107, -107, -107, -107, -107,
- 60, -61, -107, -107, 34, -107, 37, -107, 29, -107,
- -107, -107, -107, 32, -107, 76, -107, 44, -107, 56,
- -107, -107, -107, -107, -107, -107, 31, -107, -107, 116,
- -107, -107, -107, -107, -6, -107, -107, 70, -107, -107,
- 64, -107, -107, -107, -107, -107, -107, -107, -107, -107,
- -107, -107, -107, -107, -107, -107, -107, 193, -107, -107,
- -107, -107, -107, 7, -107, -107, -107, -107, -107, -107,
- -107, -20, -107, -107, -107, -7, -107, -107, 290, -107,
- -107, -107, -107, -107, -107, -107, -107, -107, -107, -107,
- -2, -25, -107, -15, -107, -107, -107, -107, 172, -107,
- -107, -107, 287, -107, -107, 288, -107, -107, -107, 291,
- -107, -107, -107, -107, 336, -107, -107, 20, -107, -107,
- 15, 3, -107, 304, -107, -107, -107, 24, -107, -107,
- -107, 28, 21, 26, -107, -107, -107, -107, -107, 320,
- 104, -107, 13, 381, -3, -107, 6, -107, 10, -107,
- 167, 22, -107, -107, 12, -107, -107, 87, -107, -107,
- -107, 25, -107, -107, -107, -107, 11, -107, 14, 85,
- -107, 121, -107, -107, -107, -107, -107, 27, -107, -107,
- 17, -107, -107, 18, 91, -107, -107, -107, 16, -107,
- -107, -107, -107, -107, -107, -4, -107, -107, -107, -107,
- -107, -107, -107, -107, -107};
+ -108, 0, 79, 128, 132, 301, 2, -108, -108, -108,
+ -108, -108, -108, -108, -108, -108, -108, -108, -108, -47,
+ -108, -108, -108, -108, -108, -108, -108, -108, -108, 51,
+ -108, -108, -108, -3, -108, -108, 8, -23, 12, 78,
+ 106, -108, 69, 74, -108, -108, -108, 195, 204, -108,
+ -108, -108, -108, -108, -108, 188, -108, 201, 200, -108,
+ 127, 129, -108, -108, -108, -108, 140, 137, 133, -108,
+ -108, -108, -108, 146, -108, 177, 168, 170, 167, -108,
+ 144, 152, 166, 158, 160, 131, -108, 194, 187, 207,
+ -108, -108, -108, -108, -108, -108, -108, -108, -108, -108,
+ -108, 88, -108, 112, -108, 121, 90, -38, -108, -108,
+ -108, -108, -108, -108, -108, -108, -108, -108, -108, -108,
+ -108, -108, -108, -108, -108, -108, -108, -108, -108, -108,
+ -108, -108, -108, -108, -108, -108, -108, -108, -108, -108,
+ -108, -108, -108, 32, -108, -108, -108, -108, -108, 26,
+ -108, -108, 27, -108, -108, -108, -108, -108, -108, -108,
+ -108, -108, -108, -108, -108, -108, 102, -108, 103, 41,
+ -108, -108, 37, -108, 250, 38, 83, -108, -108, -108,
+ -108, -108, -108, -108, 42, 126, -108, -108, -108, 40,
+ -108, -108, 43, -108, -108, -108, -108, -108, -108, -108,
+ 39, -108, -108, -108, -108, -108, -108, -108, -108, -108,
+ 225, -108, -108, 30, -108, 24, -108, 211, -108, 55,
+ -108, 77, 60, -108, -108, 66, 34, -108, -108, -108,
+ -108, -108, -8, -108, -108, -108, -108, -108, 153, -108,
+ -108, 164, -108, -108, -108, 241, -108, -108, -108, -108,
+ -108, -108, -108, -108, -108, -108, -108, -108, -108, -108,
+ -108, -108, 11, -108, -108, -108, -108, -108, 179, -108,
+ -108, -108, -108, -108, -108, -108, -108, -108, -108, -108,
+ -108, -108, 19, 259, -108, 255, 228, 240, 246, -108,
+ 52, 63, 67, 65, 50, -108, -108, -108, -108, -108,
+ -108, -108, -108, 210, -108, 256, -108, 226, -108, -108,
+ 252, -108, 161, -108, -108, 268, -108, 197, -108, 5,
+ -108, 218, -108, 222, -108, 213, 249, -108, -108, 236,
+ -108, -108, -108, -108, -108, -108, 212, -108, 80, 87,
+ -108, -108, 86, -108, 98, -108, 61, -108, 245, -108,
+ 59, -108, 208, -108, 192, -108, -108, -108, -108, -108,
+ -108, -108, -108, 257, -108, 33, -108, 28, -108, 73,
+ 71, -108, -108, 36, 57, -108, 62, -108, -108, 46,
+ 70, -108, -108, -108, 49, -108, 45, 99, -108, 84,
+ -108, -108, 100, -108, -108, -108, -108, -108, -108, 21,
+ -108, -108, -108, -108, -108, -108, 118, -108, -108, -108,
+ -108, 81, -108, -108, -108, -108, -108, -108, 123, -108,
+ -108, 134, -108, -108, 56, -108, -108, -108, -108, -108,
+ -58, -108, 47, -108, -57, -108, -108, -108, -108, 265,
+ -108, -108, 374, -108, -108, -108, -108, -108, 94, -66,
+ -108, -108, 25, -108, 22, -108, 31, -108, -108, -108,
+ -108, 58, -108, 229, -108, 35, -108, 235, -108, -108,
+ -108, -108, -108, -108, 29, -108, -108, 186, -108, -108,
+ -108, -108, 162, -108, -108, -108, -108, 48, -108, -108,
+ 163, -108, -108, 44, -108, -108, -108, -108, -108, -108,
+ -108, -108, -108, -108, -108, -108, -108, -108, -108, -108,
+ 141, -108, -108, -108, -108, -108, -7, -108, -108, -108,
+ -108, -108, -108, -108, -19, -108, -108, -108, -6, -108,
+ -108, 334, -108, -108, -108, -108, -108, -108, -108, -108,
+ -108, -108, -108, -15, -27, -108, -10, -108, -108, -108,
+ -108, 159, -108, -108, -108, 176, -108, -108, 319, -108,
+ -108, -108, 322, -108, -108, -108, -108, 469, -108, -108,
+ 10, -108, -108, 6, 16, -108, 342, -108, -108, -108,
+ 17, -108, -108, -108, 15, 3, 9, -108, -108, -108,
+ -108, -108, 358, 68, -108, 82, 310, 1, -108, -108,
+ -2, -108, 7, -108, 54, 76, -108, -108, 4, -108,
+ 64, -108, -108, 23, -108, -108, -108, 18, -108, -5,
+ 95, -108, 91, -108, -108, -108, -108, -108, -1, -108,
+ -108, 20, -108, -108, 14, 142, -108, -108, -108, 13,
+ -108, -108, -108, -108, -108, -108, -11, -108, -108, -108,
+ -108, -108, -108, -108, -108, -108};
const short QQmlJSGrammar::action_info [] = {
- 416, 257, 533, -132, 403, -113, 346, -102, 575, 348,
- 572, -121, 531, -103, -121, 545, 345, 430, 342, 348,
- 340, 343, 440, 401, 391, 545, 563, 389, 538, 446,
- 352, 444, -129, 416, -124, -102, 545, 453, 420, 408,
- -124, 431, -132, 424, -126, 424, 424, 620, 440, 457,
- -103, 440, -129, 457, -126, 440, 560, 453, -113, 257,
- 565, 346, 545, 335, 272, 346, 466, 236, 448, 190,
- 149, 164, 141, 170, 99, 511, 272, 409, 257, 312,
- 296, 414, 348, 312, 189, 164, 187, 318, 325, 71,
- 306, 252, 644, 416, 141, 453, 292, 457, 440, 147,
- 304, 71, 443, 183, 179, 141, 0, 141, 0, 172,
- 99, 427, 434, 141, 301, 477, 444, 0, 0, 0,
- 0, 0, 141, 0, 0, 0, 0, 292, 173, 294,
- 58, 294, 542, 251, 331, 542, 333, 141, 141, 101,
- 141, 59, 0, 58, 62, 256, 255, 141, 247, 246,
- 141, 399, 0, 177, 59, 63, 428, 327, 620, 254,
- 314, 101, 141, 478, 315, 640, 639, 242, 241, 249,
- 248, 58, 634, 633, 488, 58, 249, 248, 577, 576,
- 615, 141, 59, 543, 166, 518, 59, 172, 167, 455,
- 459, 85, 418, 86, 85, 142, 86, 249, 248, 413,
- 412, 567, 337, 512, 87, 512, 173, 87, 174, 85,
- 328, 86, 512, 0, 350, 85, 64, 86, 529, 85,
- 512, 86, 87, 85, 512, 86, 568, 566, 87, 64,
- 579, 64, 87, 310, 469, 85, 87, 86, 0, 519,
- 517, 85, 141, 86, 554, 0, 172, 536, 87, 514,
- 85, 514, 86, 141, 87, 85, 545, 86, 514, 0,
- 513, 65, 513, 87, 514, 173, 514, 66, 87, 513,
- 514, 103, 172, 0, 65, 513, 65, 513, 0, 0,
- 66, 513, 66, 637, 636, 0, 0, 470, 468, 172,
- 104, 173, 105, 406, 0, 235, 234, 630, 555, 553,
- 172, 537, 535, 0, 274, 275, 438, 437, 173, 172,
- 406, 631, 629, 635, 0, 580, 73, 74, -90, 173,
- 34, 174, 73, 74, 274, 275, 34, -90, 173, 34,
- 174, 276, 277, 85, 34, 86, 0, 0, 0, 0,
- 0, 628, 0, 75, 76, 0, 87, 0, 0, 75,
- 76, 276, 277, 0, 0, 0, 0, 48, 50, 49,
- 0, 0, 0, 48, 50, 49, 48, 50, 49, 0,
- 0, 48, 50, 49, 0, 0, 279, 280, 0, 0,
- 0, 34, 0, 45, 0, 281, 279, 280, 282, 45,
- 283, 34, 45, 279, 280, 281, 34, 45, 282, 0,
- 283, 34, 281, 279, 280, 282, 0, 283, 0, 0,
- 34, 0, 281, 78, 79, 282, 0, 283, 48, 50,
- 49, 80, 81, 0, 34, 82, 0, 83, 48, 50,
- 49, -345, 0, 48, 50, 49, 0, 0, 48, 50,
- 49, 0, 0, 0, 45, 0, 0, 48, 50, 49,
- 0, 0, 0, 0, 45, 0, 0, 78, 79, 45,
- 0, 48, 50, 49, 45, 80, 81, 78, 79, 82,
- 0, 83, 0, 45, 0, 80, 81, 78, 79, 82,
- 0, 83, 34, 279, 280, 80, 81, 45, 0, 82,
- 34, 83, 281, 34, 0, 282, 0, 283, 6, 5,
- 4, 1, 3, 2, 34, 0, 0, 0, 0, 0,
- 0, -345, 0, 0, 245, 244, 0, 0, 0, 48,
- 50, 49, 245, 244, 0, 240, 239, 48, 50, 49,
- 48, 50, 49, 0, 0, 0, 0, 0, 0, 0,
- 34, 48, 50, 49, 0, 45, 0, 0, 34, 0,
- 0, 34, 0, 45, 0, 0, 45, 0, 0, 0,
- 0, 0, 78, 79, 0, 0, 0, 45, 0, 0,
- 80, 81, 245, 244, 82, 0, 83, 48, 50, 49,
- 240, 239, 151, 240, 239, 48, 50, 49, 48, 50,
- 49, 0, 152, 0, 0, 0, 153, 0, 0, 0,
- 0, 0, 0, 45, 0, 154, 0, 155, 0, 0,
- 308, 45, 0, 0, 45, 0, 0, 0, 156, 0,
- 157, 62, 0, 0, 0, 0, 0, 0, 158, 0,
- 0, 159, 63, 0, 0, 0, 0, 160, 0, 30,
- 31, 151, 0, 161, 0, 0, 0, 0, 0, 33,
- 0, 152, 0, 0, 0, 153, 34, 0, 0, 162,
- 35, 36, 0, 37, 154, 0, 155, 0, 0, 0,
- 503, 0, 0, 0, 44, 0, 0, 156, 0, 157,
- 62, 0, 0, 0, 0, 0, 0, 158, 0, 0,
- 159, 63, 51, 48, 50, 49, 160, 52, 0, 0,
- 0, 0, 161, 0, 0, 0, 0, 0, 43, 54,
- 32, 0, 30, 31, 40, 0, 0, 0, 162, 45,
- 0, 0, 33, 0, 0, 0, 0, 0, 0, 34,
- 0, 0, 0, 35, 36, 0, 37, 0, 0, 0,
- 30, 31, 0, 41, 0, 0, 0, 44, 0, 0,
- 33, 0, 0, 0, 0, 0, 0, 34, 0, 0,
- 0, 35, 36, 0, 37, 51, 48, 50, 49, 0,
- 52, 503, 0, 0, 0, 44, 0, 0, 0, 0,
- 0, 43, 54, 32, 0, 0, 0, 40, 0, 0,
- 0, 0, 45, 51, 48, 50, 49, 0, 52, 0,
- 0, 0, 30, 31, 0, 0, 0, 0, 0, 43,
- 54, 32, 33, 0, 0, 40, 0, 0, 0, 34,
- 45, 0, 0, 35, 36, 0, 37, 0, 0, 0,
- 30, 31, 0, 41, 0, 0, 0, 44, 0, 0,
- 33, 0, 0, 0, 0, 0, 0, 34, 0, 0,
- 0, 35, 36, 0, 37, 51, 48, 50, 49, 0,
- 52, 503, 0, 0, 0, 44, 0, 0, 0, 0,
- 0, 43, 54, 32, 0, 0, 0, 40, 0, 0,
- 0, 0, 45, 51, 48, 50, 49, 0, 52, 0,
- 0, 0, 30, 31, 0, 0, 0, 0, 0, 43,
- 54, 32, 33, 0, 0, 40, 0, 0, 0, 34,
- 45, 0, 0, 35, 36, 0, 37, 0, 0, 0,
- 30, 31, 0, 503, 0, 0, 0, 44, 0, 0,
- 33, 0, 0, 0, 0, 0, 0, 34, 0, 0,
- 0, 35, 36, 0, 37, 51, 48, 50, 49, 0,
- 52, 41, 0, 0, 0, 44, 0, 0, 0, 0,
- 0, 43, 54, 32, 0, 0, 0, 40, 0, 0,
- 0, 0, 45, 51, 48, 50, 49, 0, 52, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 43,
- 54, 32, 0, 0, 0, 40, 0, 0, 0, 0,
- 45, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 502, 0, 30, 31, 0, 0, 0, 0, 0, 0,
- 0, 0, 215, 0, 0, 0, 0, 0, 0, 34,
- 0, 0, 0, 35, 36, 0, 37, 0, 0, 0,
- 0, 0, 0, 503, 0, 0, 0, 44, 0, 0,
+ 344, -127, 576, -129, 551, 631, 546, -105, 342, 465,
+ 448, 461, -132, -106, 245, 481, 558, 558, 398, 573,
+ 392, 482, 402, 268, 354, -124, 350, 578, 585, -135,
+ -116, 484, 474, 404, -106, -105, -127, -129, -124, 454,
+ 438, -135, 245, 558, 448, 424, 448, 448, -132, 456,
+ 439, 588, 452, 268, 406, 350, 408, -116, 558, 405,
+ 432, 544, 418, 432, 413, 432, 329, 166, 524, 461,
+ 428, 421, 465, 172, 283, 143, 420, 143, 241, 166,
+ 262, 73, 149, 185, 323, 283, 307, 323, 336, 73,
+ 655, 189, 0, 245, 423, 192, 448, 0, 0, 101,
+ 240, 0, 451, 346, 243, 303, 424, 315, 181, 143,
+ 0, 268, 151, 0, 399, 312, 452, 350, 143, 261,
+ 174, 317, 143, 244, 303, 184, 435, 238, 461, 465,
+ 442, 143, 103, 143, 143, 305, 143, 64, 143, 175,
+ 143, 338, 101, 60, 143, 555, 0, 191, 65, 325,
+ 0, 143, 0, 326, 61, 631, 174, 555, 103, 259,
+ 258, 501, 143, 259, 258, 590, 589, 252, 251, 60,
+ 426, 436, 416, 415, 264, 175, 259, 258, 645, 644,
+ 61, 179, 257, 256, 144, 168, 463, 60, 105, 169,
+ 467, 60, 352, 626, 339, 87, 321, 88, 61, 651,
+ 650, 525, 61, 348, 525, 556, 174, 106, 89, 107,
+ 174, 525, 490, 143, 66, 446, 445, 648, 647, 66,
+ 580, 87, 549, 88, 87, 175, 88, 411, 87, 175,
+ 88, 176, 567, 174, 89, 542, 87, 89, 88, 531,
+ 0, 89, 87, 525, 88, 581, 579, 527, 646, 89,
+ 527, 66, 175, 592, 411, 89, 0, 527, 526, 67,
+ 491, 526, 0, 0, 67, 68, 236, 235, 526, 87,
+ 68, 88, 87, 0, 88, 0, 550, 548, 87, 558,
+ 88, 527, 89, 267, 265, 89, 568, 566, 87, 527,
+ 88, 89, 526, 532, 530, 87, 67, 88, 525, 0,
+ 526, 89, 68, 87, 87, 88, 88, 174, 89, 477,
+ 0, 266, 0, 285, 286, 641, 89, 89, 75, 76,
+ 75, 76, 0, 0, 0, -92, 175, 0, 176, 642,
+ 640, 174, 6, 5, 4, 1, 3, 2, 0, 593,
+ 287, 288, 290, 291, 527, 77, 78, 77, 78, -92,
+ 175, 292, 176, 0, 293, 526, 294, 290, 291, 0,
+ 639, 0, 478, 476, 290, 291, 292, 0, 0, 293,
+ 0, 294, 0, 292, 290, 291, 293, 0, 294, 0,
+ 290, 291, 0, 292, 0, 0, 293, 0, 294, 292,
+ 80, 81, 293, 35, 294, 0, 0, 0, 82, 83,
+ 80, 81, 84, 35, 85, 0, 285, 286, 82, 83,
+ 80, 81, 84, 35, 85, 0, 0, 0, 82, 83,
+ 0, 0, 84, 35, 85, 0, 35, 0, 0, 0,
+ 49, 52, 50, 287, 288, 0, 0, 0, 0, 0,
+ 49, 52, 50, 0, 35, 0, 0, 35, 0, 0,
+ 49, 52, 50, 0, 0, 0, 0, 46, 34, 51,
+ 49, 52, 50, 49, 52, 50, 0, 46, 34, 51,
+ 0, 0, 0, 0, 0, 0, 0, 46, 34, 51,
+ 35, 49, 52, 50, 49, 52, 50, 46, 34, 51,
+ 46, 34, 51, 80, 81, 35, 0, 0, 35, 0,
+ 0, 82, 83, 0, 0, 84, 0, 85, 46, 34,
+ 51, 46, 34, 51, 35, 0, 0, 49, 52, 50,
+ 0, 184, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 35, 49, 52, 50, 49, 52, 50, 184, 0,
+ 0, 0, 0, 0, 46, 34, 51, 0, 0, 0,
+ 0, 49, 52, 50, 35, 0, 0, 0, 0, 46,
+ 34, 51, 46, 34, 51, 35, 0, 0, 49, 52,
+ 50, 0, 184, 0, 0, 35, 0, 0, 46, 34,
+ 51, 0, 0, 0, 35, 0, 255, 254, 0, 0,
+ 0, 49, 52, 50, 0, 46, 34, 51, 0, 0,
+ 0, 0, 49, 52, 50, 35, 0, 0, 0, 0,
+ 0, 0, 49, 52, 50, 0, 255, 254, 46, 34,
+ 51, 49, 52, 50, 0, 0, 0, 0, 0, 46,
+ 34, 51, 0, 0, 0, 0, 0, 255, 254, 46,
+ 34, 51, 49, 52, 50, 0, 0, 0, 46, 34,
+ 51, 35, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 46,
+ 34, 51, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 250, 249, 153, 0, 0, 49, 52,
+ 50, 0, 0, 0, 0, 154, 0, 0, 0, 155,
+ 0, 0, 0, 0, 0, 0, 0, 0, 156, 0,
+ 157, 0, 0, 319, 0, 46, 34, 51, 0, 0,
+ 0, 158, 0, 159, 64, 0, 0, 153, 0, 0,
+ 0, 160, 0, 0, 161, 65, 0, 154, 0, 0,
+ 162, 155, 0, 0, 0, 0, 163, 0, 0, 0,
+ 156, 0, 157, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 164, 158, 0, 159, 64, 0, 0, 0,
+ 0, 0, 0, 160, 0, 0, 161, 65, 0, 0,
+ 0, 0, 162, 0, 0, 0, 0, 0, 163, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 51, 504, 506, 505, 0,
- 52, 0, 0, 0, 0, 226, 0, 0, 0, 0,
- 0, 43, 54, 32, 210, 0, 0, 40, 0, 0,
+ 0, 0, 0, 0, 164, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 30,
+ 31, 0, 0, 0, 0, 0, 0, 0, 0, 33,
+ 0, 0, 0, 0, 0, 0, 35, 0, 0, 0,
+ 36, 37, 0, 38, 0, 0, 0, 0, 0, 0,
+ 42, 0, 0, 0, 45, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 53, 49, 52, 50, 0, 54, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 44, 56,
+ 32, 0, 0, 0, 41, 0, 0, 0, 0, 0,
+ 46, 34, 51, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 30, 31, 0, 0, 0, 0, 0, 0,
+ 0, 0, 33, 0, 0, 0, 0, 0, 0, 35,
+ 0, 0, 0, 36, 37, 0, 38, 0, 0, 0,
+ 0, 0, 0, 516, 0, 0, 0, 45, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 53, 49, 52, 50, 0,
+ 54, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 44, 56, 32, 0, 0, 0, 41, 0, 0,
+ 0, 0, 0, 46, 34, 51, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 515, 0, 30, 31, 0,
+ 0, 0, 0, 0, 0, 0, 0, 219, 0, 0,
+ 0, 0, 0, 0, 35, 0, 0, 0, 36, 37,
+ 0, 38, 0, 0, 0, 0, 0, 0, 516, 0,
0, 0, 45, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 502, 0, 30, 31, 0, 0, 0, 0,
- 0, 0, 0, 0, 215, 0, 0, 0, 0, 0,
- 0, 34, 0, 0, 0, 35, 36, 0, 37, 0,
- 0, 0, 0, 0, 0, 503, 0, 0, 0, 44,
- 0, 0, 0, 0, 0, 0, 0, 550, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 51, 504, 506,
- 505, 0, 52, 0, 0, 0, 0, 226, 0, 0,
- 0, 0, 0, 43, 54, 32, 210, 0, 0, 40,
- 0, 0, 0, 0, 45, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 502, 0, 30, 31, 0, 0,
- 0, 0, 0, 0, 0, 0, 215, 0, 0, 0,
- 0, 0, 0, 34, 0, 0, 0, 35, 36, 0,
- 37, 0, 0, 0, 0, 0, 0, 503, 0, 0,
- 0, 44, 0, 0, 0, 0, 0, 0, 0, 547,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 51,
- 504, 506, 505, 0, 52, 0, 0, 0, 0, 226,
- 0, 0, 0, 0, 0, 43, 54, 32, 210, 0,
- 0, 40, 0, 0, 0, 0, 45, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 29, 30, 31, 0,
- 0, 0, 0, 0, 0, 0, 0, 33, 0, 0,
- 0, 0, 0, 0, 34, 0, 0, 0, 35, 36,
- 0, 37, 0, 0, 0, 38, 0, 39, 41, 42,
- 0, 0, 44, 0, 0, 0, 46, 0, 47, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 51, 48, 50, 49, 0, 52, 0, 53, 0, 55,
- 0, 56, 0, 0, 0, 0, 43, 54, 32, 0,
- 0, 0, 40, 0, 0, 0, 0, 45, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, -122, 0, 0,
- 0, 29, 30, 31, 0, 0, 0, 0, 0, 0,
- 0, 0, 33, 0, 0, 0, 0, 0, 0, 34,
- 0, 0, 0, 35, 36, 0, 37, 0, 0, 0,
- 38, 0, 39, 41, 42, 0, 0, 44, 0, 0,
- 0, 46, 0, 47, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 51, 48, 50, 49, 0,
- 52, 0, 53, 0, 55, 0, 56, 0, 0, 0,
- 0, 43, 54, 32, 0, 0, 0, 40, 0, 0,
+ 53, 517, 519, 518, 0, 54, 0, 0, 0, 0,
+ 227, 0, 0, 0, 0, 0, 44, 56, 32, 214,
+ 0, 0, 41, 0, 0, 0, 0, 0, 46, 34,
+ 51, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 515, 0, 30, 31, 0, 0, 0, 0, 0, 0,
+ 0, 0, 219, 0, 0, 0, 0, 0, 0, 35,
+ 0, 0, 0, 36, 37, 0, 38, 0, 0, 0,
+ 0, 0, 0, 516, 0, 0, 0, 45, 0, 0,
+ 0, 0, 0, 0, 0, 560, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 53, 517, 519, 518, 0,
+ 54, 0, 0, 0, 0, 227, 0, 0, 0, 0,
+ 0, 44, 56, 32, 214, 0, 0, 41, 0, 0,
+ 0, 0, 0, 46, 34, 51, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 515, 0, 30, 31, 0,
+ 0, 0, 0, 0, 0, 0, 0, 219, 0, 0,
+ 0, 0, 0, 0, 35, 0, 0, 0, 36, 37,
+ 0, 38, 0, 0, 0, 0, 0, 0, 516, 0,
0, 0, 45, 0, 0, 0, 0, 0, 0, 0,
+ 563, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 53, 517, 519, 518, 0, 54, 0, 0, 0, 0,
+ 227, 0, 0, 0, 0, 0, 44, 56, 32, 214,
+ 0, 0, 41, 0, 0, 0, 0, 0, 46, 34,
+ 51, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 29, 30, 31, 0, 0, 0, 0, 0, 0, 0,
+ 0, 33, 0, 0, 0, 0, 0, 0, 35, 0,
+ 0, 0, 36, 37, 0, 38, 0, 0, 0, 39,
+ 0, 40, 42, 43, 0, 0, 45, 0, 0, 0,
+ 47, 0, 48, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 53, 49, 52, 50, 0, 54,
+ 0, 55, 0, 57, 0, 58, 0, 0, 0, 0,
+ 44, 56, 32, 0, 0, 0, 41, 0, 0, 0,
+ 0, 0, 46, 34, 51, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, -125, 0, 0, 0, 29, 30,
+ 31, 0, 0, 0, 0, 0, 0, 0, 0, 33,
+ 0, 0, 0, 0, 0, 0, 35, 0, 0, 0,
+ 36, 37, 0, 38, 0, 0, 0, 39, 0, 40,
+ 42, 43, 0, 0, 45, 0, 0, 0, 47, 0,
+ 48, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 53, 49, 52, 50, 0, 54, 0, 55,
+ 0, 57, 0, 58, 0, 0, 0, 0, 44, 56,
+ 32, 0, 0, 0, 41, 0, 0, 0, 0, 0,
+ 46, 34, 51, 0, 0, 0, 0, 0, 0, 0,
0, 0, 29, 30, 31, 0, 0, 0, 0, 0,
0, 0, 0, 33, 0, 0, 0, 0, 0, 0,
- 34, 0, 0, 0, 35, 36, 0, 37, 0, 0,
- 0, 38, 0, 39, 41, 42, 0, 0, 44, 0,
- 0, 0, 46, 0, 47, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 51, 48, 50, 49,
- 0, 52, 0, 53, 0, 55, 271, 56, 0, 0,
- 0, 0, 43, 54, 32, 0, 0, 0, 40, 0,
- 0, 0, 0, 45, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 475, 0, 0, 29, 30, 31, 0,
+ 35, 0, 0, 0, 36, 37, 0, 38, 0, 0,
+ 0, 39, 0, 40, 42, 43, 0, 0, 45, 0,
+ 0, 0, 47, 0, 48, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 53, 49, 52, 50,
+ 0, 54, 0, 55, 0, 57, 282, 58, 0, 0,
+ 0, 0, 44, 56, 32, 0, 0, 0, 41, 0,
+ 0, 0, 0, 0, 46, 34, 51, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 496, 0, 0, 29,
+ 30, 31, 0, 0, 0, 0, 0, 0, 0, 0,
+ 33, 0, 0, 0, 0, 0, 0, 35, 0, 0,
+ 0, 36, 37, 0, 38, 0, 0, 0, 39, 0,
+ 40, 42, 43, 0, 0, 45, 0, 0, 0, 47,
+ 0, 48, 0, 0, 499, 0, 0, 0, 0, 0,
+ 0, 0, 0, 53, 49, 52, 50, 0, 54, 0,
+ 55, 0, 57, 0, 58, 0, 0, 0, 0, 44,
+ 56, 32, 0, 0, 0, 41, 0, 0, 0, 0,
+ 0, 46, 34, 51, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 496, 0, 0, 29, 30, 31, 0,
0, 0, 0, 0, 0, 0, 0, 33, 0, 0,
- 0, 0, 0, 0, 34, 0, 0, 0, 35, 36,
- 0, 37, 0, 0, 0, 38, 0, 39, 41, 42,
- 0, 0, 44, 0, 0, 0, 46, 0, 47, 0,
- 0, 476, 0, 0, 0, 0, 0, 0, 0, 0,
- 51, 48, 50, 49, 0, 52, 0, 53, 0, 55,
- 0, 56, 0, 0, 0, 0, 43, 54, 32, 0,
- 0, 0, 40, 0, 0, 0, 0, 45, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 475, 0, 0,
+ 0, 0, 0, 0, 35, 0, 0, 0, 36, 37,
+ 0, 38, 0, 0, 0, 39, 0, 40, 42, 43,
+ 0, 0, 45, 0, 0, 0, 47, 0, 48, 0,
+ 0, 497, 0, 0, 0, 0, 0, 0, 0, 0,
+ 53, 49, 52, 50, 0, 54, 0, 55, 0, 57,
+ 0, 58, 0, 0, 0, 0, 44, 56, 32, 0,
+ 0, 0, 41, 0, 0, 0, 0, 0, 46, 34,
+ 51, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 488, 0, 0, 29, 30, 31, 0, 0, 0, 0,
+ 0, 0, 0, 0, 33, 0, 0, 0, 0, 0,
+ 0, 35, 0, 0, 0, 36, 37, 0, 38, 0,
+ 0, 0, 39, 0, 40, 42, 43, 0, 0, 45,
+ 0, 0, 0, 47, 0, 48, 0, 0, 489, 0,
+ 0, 0, 0, 0, 0, 0, 0, 53, 49, 52,
+ 50, 0, 54, 0, 55, 0, 57, 0, 58, 0,
+ 0, 0, 0, 44, 56, 32, 0, 0, 0, 41,
+ 0, 0, 0, 0, 0, 46, 34, 51, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 488, 0, 0,
29, 30, 31, 0, 0, 0, 0, 0, 0, 0,
- 0, 33, 0, 0, 0, 0, 0, 0, 34, 0,
- 0, 0, 35, 36, 0, 37, 0, 0, 0, 38,
- 0, 39, 41, 42, 0, 0, 44, 0, 0, 0,
- 46, 0, 47, 0, 0, 481, 0, 0, 0, 0,
- 0, 0, 0, 0, 51, 48, 50, 49, 0, 52,
- 0, 53, 0, 55, 0, 56, 0, 0, 0, 0,
- 43, 54, 32, 0, 0, 0, 40, 0, 0, 0,
- 0, 45, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 483, 0, 0, 29, 30, 31, 0, 0, 0,
+ 0, 33, 0, 0, 0, 0, 0, 0, 35, 0,
+ 0, 0, 36, 37, 0, 38, 0, 0, 0, 39,
+ 0, 40, 42, 43, 0, 0, 45, 0, 0, 0,
+ 47, 0, 48, 0, 0, 494, 0, 0, 0, 0,
+ 0, 0, 0, 0, 53, 49, 52, 50, 0, 54,
+ 0, 55, 0, 57, 0, 58, 0, 0, 0, 0,
+ 44, 56, 32, 0, 0, 0, 41, 0, 0, 0,
+ 0, 0, 46, 34, 51, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 29, 30, 31, 0, 0, 0,
0, 0, 0, 0, 0, 33, 0, 0, 0, 0,
- 0, 0, 34, 0, 0, 0, 35, 36, 0, 37,
- 0, 0, 0, 38, 0, 39, 41, 42, 0, 0,
- 44, 0, 0, 0, 46, 0, 47, 0, 0, 484,
- 0, 0, 0, 0, 0, 0, 0, 0, 51, 48,
- 50, 49, 0, 52, 0, 53, 0, 55, 0, 56,
- 0, 0, 0, 0, 43, 54, 32, 0, 0, 0,
- 40, 0, 0, 0, 0, 45, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 483, 0, 0, 29, 30,
+ 0, 0, 35, 220, 0, 0, 221, 37, 0, 38,
+ 0, 0, 0, 39, 0, 40, 42, 43, 0, 0,
+ 45, 0, 0, 0, 47, 0, 48, 0, 0, 0,
+ 0, 0, 0, 0, 223, 0, 0, 0, 53, 49,
+ 52, 50, 224, 54, 0, 55, 226, 57, 0, 58,
+ 0, 229, 0, 0, 44, 56, 32, 0, 0, 0,
+ 41, 0, 0, 0, 0, 0, 46, 34, 51, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 29, 30,
31, 0, 0, 0, 0, 0, 0, 0, 0, 33,
- 0, 0, 0, 0, 0, 0, 34, 0, 0, 0,
- 35, 36, 0, 37, 0, 0, 0, 38, 0, 39,
- 41, 42, 0, 0, 44, 0, 0, 0, 46, 0,
- 47, 0, 0, 486, 0, 0, 0, 0, 0, 0,
- 0, 0, 51, 48, 50, 49, 0, 52, 0, 53,
- 0, 55, 0, 56, 0, 0, 0, 0, 43, 54,
- 32, 0, 0, 0, 40, 0, 0, 0, 0, 45,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 29,
- 30, 31, 0, 0, 0, 0, 0, 0, 0, 0,
- 33, 0, 0, 0, 0, 0, 0, 34, 217, 0,
- 0, 218, 36, 0, 37, 0, 0, 0, 38, 0,
- 39, 41, 42, 0, 0, 44, 0, 0, 0, 46,
- 0, 47, 0, 0, 0, 0, 0, 0, 0, 221,
- 0, 0, 0, 51, 48, 50, 49, 223, 52, 0,
- 53, 225, 55, 0, 56, 0, 228, 0, 0, 43,
- 54, 32, 0, 0, 0, 40, 0, 0, 0, 0,
- 45, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 29, 30, 31, 0, 0, 0, 0, 0, 0, 0,
- 0, 33, 0, 0, 0, 0, 0, 0, 34, 217,
- 0, 0, 582, 583, 0, 37, 0, 0, 0, 38,
- 0, 39, 41, 42, 0, 0, 44, 0, 0, 0,
- 46, 0, 47, 0, 0, 0, 0, 0, 0, 0,
- 221, 0, 0, 0, 51, 48, 50, 49, 223, 52,
- 0, 53, 225, 55, 0, 56, 0, 228, 0, 0,
- 43, 54, 32, 0, 0, 0, 40, 0, 0, 0,
- 0, 45, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 109, 110, 111, 0, 0, 113, 115, 116, 0,
- 0, 117, 0, 118, 0, 0, 0, 120, 121, 122,
- 0, 0, 0, 0, 0, 0, 34, 123, 124, 125,
+ 0, 0, 0, 0, 0, 0, 35, 220, 0, 0,
+ 595, 596, 0, 38, 0, 0, 0, 39, 0, 40,
+ 42, 43, 0, 0, 45, 0, 0, 0, 47, 0,
+ 48, 0, 0, 0, 0, 0, 0, 0, 223, 0,
+ 0, 0, 53, 49, 52, 50, 224, 54, 0, 55,
+ 226, 57, 0, 58, 0, 229, 0, 0, 44, 56,
+ 32, 0, 0, 0, 41, 0, 0, 0, 0, 0,
+ 46, 34, 51, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 111, 112, 113, 0, 0, 115, 117, 118,
+ 0, 0, 119, 0, 120, 0, 0, 0, 122, 123,
+ 124, 0, 0, 0, 0, 0, 0, 35, 125, 126,
+ 127, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 128, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 131, 0, 0,
+ 0, 0, 0, 0, 49, 52, 50, 132, 133, 134,
+ 0, 136, 137, 138, 139, 140, 141, 0, 0, 129,
+ 135, 121, 114, 116, 130, 0, 0, 0, 0, 0,
+ 0, 46, 34, 51, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 111, 112, 113, 0, 0, 115, 117,
+ 118, 0, 0, 119, 0, 120, 0, 0, 0, 122,
+ 123, 124, 0, 0, 0, 0, 0, 0, 35, 125,
+ 126, 127, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 128, 0, 0, 0, 395, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 131, 0,
+ 0, 0, 0, 0, 397, 49, 52, 50, 132, 133,
+ 134, 0, 136, 137, 138, 139, 140, 141, 0, 0,
+ 129, 135, 121, 114, 116, 130, 0, 0, 0, 0,
+ 0, 0, 46, 34, 51, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 111, 112, 113, 0, 0, 115,
+ 117, 118, 0, 0, 119, 0, 120, 0, 0, 0,
+ 122, 123, 124, 0, 0, 0, 0, 0, 0, 35,
+ 125, 126, 127, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 128, 0, 0, 0, 395, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 131,
+ 0, 0, 0, 0, 0, 397, 49, 52, 50, 132,
+ 133, 134, 0, 136, 137, 138, 139, 140, 141, 0,
+ 0, 129, 135, 121, 114, 116, 130, 0, 0, 0,
+ 0, 0, 0, 46, 374, 380, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 111, 112, 113, 0, 0,
+ 115, 117, 118, 0, 0, 119, 0, 120, 0, 0,
+ 0, 122, 123, 124, 0, 0, 0, 0, 0, 0,
+ 35, 125, 126, 127, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 128, 0, 0, 0, 395, 0,
+ 0, 0, 0, 0, 0, 0, 396, 0, 0, 0,
+ 131, 0, 0, 0, 0, 0, 397, 49, 52, 50,
+ 132, 133, 134, 0, 136, 137, 138, 139, 140, 141,
+ 0, 0, 129, 135, 121, 114, 116, 130, 0, 0,
+ 0, 0, 0, 0, 46, 374, 380, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 213, 0, 0, 0,
+ 0, 215, 0, 29, 30, 31, 217, 0, 0, 0,
+ 0, 0, 0, 218, 33, 0, 0, 0, 0, 0,
+ 0, 35, 220, 0, 0, 221, 37, 0, 38, 0,
+ 0, 0, 39, 0, 40, 42, 43, 0, 0, 45,
+ 0, 0, 0, 47, 0, 48, 0, 0, 0, 0,
+ 0, 222, 0, 223, 0, 0, 0, 53, 49, 52,
+ 50, 224, 54, 225, 55, 226, 57, 227, 58, 228,
+ 229, 0, 0, 44, 56, 32, 214, 216, 0, 41,
+ 0, 0, 0, 0, 0, 46, 34, 51, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 213, 0, 0,
+ 0, 0, 215, 0, 29, 30, 31, 217, 0, 0,
+ 0, 0, 0, 0, 218, 219, 0, 0, 0, 0,
+ 0, 0, 35, 220, 0, 0, 221, 37, 0, 38,
+ 0, 0, 0, 39, 0, 40, 42, 43, 0, 0,
+ 45, 0, 0, 0, 47, 0, 48, 0, 0, 0,
+ 0, 0, 222, 0, 223, 0, 0, 0, 53, 49,
+ 52, 50, 224, 54, 225, 55, 226, 57, 227, 58,
+ 228, 229, 0, 0, 44, 56, 32, 214, 216, 0,
+ 41, 0, 0, 0, 0, 0, 46, 34, 51, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 600, 112,
+ 113, 0, 0, 602, 117, 604, 30, 31, 605, 0,
+ 120, 0, 0, 0, 122, 607, 608, 0, 0, 0,
+ 0, 0, 0, 35, 609, 126, 127, 221, 37, 0,
+ 38, 0, 0, 0, 39, 0, 40, 610, 43, 0,
+ 0, 612, 0, 0, 0, 47, 0, 48, 0, 0,
+ 0, 0, 0, 613, 0, 223, 0, 0, 0, 614,
+ 49, 52, 50, 615, 616, 617, 55, 619, 620, 621,
+ 622, 623, 624, 0, 0, 611, 618, 606, 601, 603,
+ 130, 41, 0, 0, 0, 0, 0, 46, 374, 380,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 365,
+ 112, 113, 0, 0, 367, 117, 369, 30, 31, 370,
+ 0, 120, 0, 0, 0, 122, 372, 373, 0, 0,
+ 0, 0, 0, 0, 35, 375, 126, 127, 221, 37,
+ 0, 38, 0, 0, 0, 39, 0, 40, 376, 43,
+ 0, 0, 378, 0, 0, 0, 47, 0, 48, 0,
+ -271, 0, 0, 0, 379, 0, 223, 0, 0, 0,
+ 381, 49, 52, 50, 382, 383, 384, 55, 386, 387,
+ 388, 389, 390, 391, 0, 0, 377, 385, 371, 366,
+ 368, 130, 41, 0, 0, 0, 0, 0, 46, 374,
+ 380, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+
+ 565, 148, 545, 16, 649, 547, 541, 469, 320, 529,
+ 528, 630, 183, 248, 263, 500, 485, 447, 629, 183,
+ 627, 444, 253, 393, 587, 652, 313, 152, 643, 572,
+ 591, 575, 586, 638, 331, 574, 453, 455, 466, 253,
+ 437, 178, 433, 253, 0, 248, 584, 458, 248, 313,
+ 441, 183, 444, 457, 237, 190, 447, 188, 206, 425,
+ 400, 462, 351, 313, 347, 150, 165, 447, 475, 444,
+ 183, 145, 393, 260, 0, 409, 173, 409, 260, 362,
+ 171, 514, 409, 495, 362, 393, 206, 498, 628, 313,
+ 313, 206, 356, 142, 206, 331, 362, 599, 403, 0,
+ 345, 62, 62, 62, 182, 62, 299, 182, 295, 206,
+ 410, 417, 410, 206, 62, 393, 62, 410, 62, 296,
+ 148, 298, 148, 297, 62, 62, 182, 504, 412, 62,
+ 180, 502, 511, 206, 512, 62, 108, 460, 188, 62,
+ 394, 188, 62, 206, 460, 247, 62, 206, 459, 206,
+ 62, 102, 459, 62, 62, 514, 206, 62, 653, 503,
+ 407, 343, 341, 62, 313, 110, 419, 167, 188, 187,
+ 170, 340, 514, 104, 0, 553, 422, 206, 62, 206,
+ 62, 63, 62, 72, 62, 510, 71, 97, 62, 514,
+ 70, 62, 557, 69, 355, 62, 239, 62, 493, 318,
+ 86, 469, 492, 62, 483, 74, 242, 206, 93, 62,
+ 353, 62, 206, 260, 95, 0, 96, 62, 62, 62,
+ 322, 62, 94, 206, 100, 98, 206, 99, 62, 247,
+ 277, 464, 0, 206, 79, 281, 314, 468, 62, 62,
+ 206, 507, 91, 246, 206, 62, 62, 349, 505, 90,
+ 206, 62, 62, 460, 459, 62, 206, 506, 62, 401,
+ 206, 62, 92, 309, 62, 108, 281, 362, 281, 281,
+ 0, 313, 206, 62, 304, 479, 0, 309, 281, 62,
+ 206, 327, 281, 0, 281, 337, 300, 309, 324, 0,
+ 0, 62, 281, 0, 110, 177, 281, 62, 301, 308,
+ 309, 0, 281, 309, 302, 281, 62, 62, 281, 330,
+ 62, 281, 281, 289, 514, 281, 0, 0, 306, 284,
+ 0, 522, 328, 569, 561, 311, 553, 564, 625, 0,
+ 0, 0, 514, 513, 523, 514, 0, 0, 0, 522,
+ 0, 0, 522, 316, 0, 0, 0, 0, 0, 485,
+ 440, 513, 523, 0, 513, 523, 533, 534, 535, 536,
+ 540, 537, 538, 577, 533, 534, 535, 536, 540, 537,
+ 538, 594, 0, 0, 0, 0, 362, 0, 597, 598,
+ 533, 534, 535, 536, 540, 537, 538, 0, 0, 206,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 126, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 129, 0, 0, 0,
- 0, 0, 0, 48, 50, 49, 130, 131, 132, 0,
- 134, 135, 136, 137, 138, 139, 0, 0, 127, 133,
- 119, 112, 114, 128, 0, 0, 0, 0, 0, 45,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 109,
- 110, 111, 0, 0, 113, 115, 116, 0, 0, 117,
- 0, 118, 0, 0, 0, 120, 121, 122, 0, 0,
- 0, 0, 0, 0, 393, 123, 124, 125, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 126, 0,
- 0, 0, 394, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 129, 0, 0, 0, 0, 0,
- 398, 395, 397, 0, 130, 131, 132, 0, 134, 135,
- 136, 137, 138, 139, 0, 0, 127, 133, 119, 112,
- 114, 128, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 109, 110, 111,
- 0, 0, 113, 115, 116, 0, 0, 117, 0, 118,
- 0, 0, 0, 120, 121, 122, 0, 0, 0, 0,
- 0, 0, 393, 123, 124, 125, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 126, 0, 0, 0,
- 394, 0, 0, 0, 0, 0, 0, 0, 396, 0,
- 0, 0, 129, 0, 0, 0, 0, 0, 398, 395,
- 397, 0, 130, 131, 132, 0, 134, 135, 136, 137,
- 138, 139, 0, 0, 127, 133, 119, 112, 114, 128,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 209, 0, 0, 0, 0,
- 211, 0, 29, 30, 31, 213, 0, 0, 0, 0,
- 0, 0, 214, 215, 0, 0, 0, 0, 0, 0,
- 216, 217, 0, 0, 218, 36, 0, 37, 0, 0,
- 0, 38, 0, 39, 41, 42, 0, 0, 44, 0,
- 0, 0, 46, 0, 47, 0, 0, 0, 0, 0,
- 220, 0, 221, 0, 0, 0, 51, 219, 222, 49,
- 223, 52, 224, 53, 225, 55, 226, 56, 227, 228,
- 0, 0, 43, 54, 32, 210, 212, 0, 40, 0,
- 0, 0, 0, 45, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 209, 0, 0, 0, 0, 211, 0,
- 29, 30, 31, 213, 0, 0, 0, 0, 0, 0,
- 214, 33, 0, 0, 0, 0, 0, 0, 216, 217,
- 0, 0, 218, 36, 0, 37, 0, 0, 0, 38,
- 0, 39, 41, 42, 0, 0, 44, 0, 0, 0,
- 46, 0, 47, 0, 0, 0, 0, 0, 220, 0,
- 221, 0, 0, 0, 51, 219, 222, 49, 223, 52,
- 224, 53, 225, 55, 226, 56, 227, 228, 0, 0,
- 43, 54, 32, 210, 212, 0, 40, 0, 0, 0,
- 0, 45, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 586, 110, 111, 0, 0, 588, 115, 590, 30,
- 31, 591, 0, 118, 0, 0, 0, 120, 593, 594,
- 0, 0, 0, 0, 0, 0, 595, 596, 124, 125,
- 218, 36, 0, 37, 0, 0, 0, 38, 0, 39,
- 597, 42, 0, 0, 599, 0, 0, 0, 46, 0,
- 47, 0, 0, 0, 0, 0, 601, 0, 221, 0,
- 0, 0, 603, 600, 602, 49, 604, 605, 606, 53,
- 608, 609, 610, 611, 612, 613, 0, 0, 598, 607,
- 592, 587, 589, 128, 40, 0, 0, 0, 0, 45,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 361,
- 110, 111, 0, 0, 363, 115, 365, 30, 31, 366,
- 0, 118, 0, 0, 0, 120, 368, 369, 0, 0,
- 0, 0, 0, 0, 370, 371, 124, 125, 218, 36,
- 0, 37, 0, 0, 0, 38, 0, 39, 372, 42,
- 0, 0, 374, 0, 0, 0, 46, 0, 47, 0,
- -268, 0, 0, 0, 376, 0, 221, 0, 0, 0,
- 378, 375, 377, 49, 379, 380, 381, 53, 383, 384,
- 385, 386, 387, 388, 0, 0, 373, 382, 367, 362,
- 364, 128, 40, 0, 0, 0, 0, 45, 0, 0,
- 0, 0, 0, 0, 0, 0, 0,
-
- 534, 311, 497, 309, 532, 461, 498, 499, 516, 515,
- 619, 638, 16, 552, 436, 358, 616, 472, 562, 320,
- 528, 238, 487, 182, 250, 243, 253, 182, 302, 641,
- 627, 632, 150, 485, 143, 454, 439, 402, 445, 559,
- 237, 574, 250, 578, 561, 186, 618, 458, 238, 349,
- 573, 449, 447, 571, 243, 347, 450, 243, 460, 351,
- 238, 353, 358, 410, 415, 439, 176, 188, 436, 250,
- 467, 417, 433, 182, 425, 429, 302, 169, 456, 358,
- 171, 140, 336, 334, 338, 344, 436, 392, 390, 400,
- 163, 302, 307, 148, 146, 339, 439, 404, 302, 358,
- 404, 358, 0, 482, 501, 480, 0, 642, 0, 479,
- 0, 0, 0, 320, 60, 0, 186, 501, 90, 60,
- 60, 489, 302, 60, 617, 93, 0, 88, 0, 405,
- 0, 461, 405, 60, 60, 451, 180, 60, 0, 180,
- 60, 60, 60, 451, 60, 95, 89, 146, 266, 287,
- 60, 146, 407, 270, 60, 288, 178, 60, 106, 452,
- 0, 60, 60, 60, 102, 60, 302, 332, 286, 60,
- 92, 452, 60, 60, 451, 60, 165, 168, 285, 432,
- 284, 435, 60, 60, 108, 501, 329, 94, 540, 96,
- 60, 330, 60, 302, 494, 60, 77, 237, 60, 404,
- 452, 341, 471, 72, 60, 60, 67, 69, 60, 60,
- 68, 0, 70, 60, 60, 60, 61, 180, 60, 60,
- 98, 491, 60, 91, 490, 60, 60, 60, 493, 60,
- 84, 405, 60, 97, 492, 305, 0, 60, 0, 298,
- 0, 100, 270, 298, 270, 298, 106, 298, 270, 0,
- 270, 60, 270, 60, 316, 0, 270, 0, 270, 298,
- 291, 326, 303, 60, 270, 319, 313, 300, 270, 297,
- 60, 60, 108, 175, 295, 270, 270, 290, 60, 501,
- 273, 317, 60, 270, 60, 278, 509, 270, 0, 270,
- 0, 289, 0, 548, 0, 293, 551, 0, 500, 510,
- 501, 501, 0, 544, 501, 0, 0, 0, 509, 0,
- 0, 509, 520, 521, 522, 523, 527, 524, 525, 0,
- 500, 510, 0, 500, 510, 564, 520, 521, 522, 523,
- 527, 524, 525, 581, 0, 0, 0, 0, 0, 0,
- 584, 585, 520, 521, 522, 523, 527, 524, 525, 556,
- 0, 0, 0, 0, 0, 0, 557, 558, 520, 521,
- 522, 523, 527, 524, 525, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 443,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 556, 0, 0, 540, 0, 614,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 569, 0, 0, 0, 0, 0, 0, 570,
+ 571, 533, 534, 535, 536, 540, 537, 538, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 472, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0};
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0};
const short QQmlJSGrammar::action_check [] = {
- 36, 36, 24, 7, 55, 7, 7, 7, 60, 36,
- 8, 7, 37, 7, 7, 33, 55, 55, 60, 36,
- 36, 33, 33, 55, 8, 33, 7, 7, 34, 36,
- 16, 20, 7, 36, 7, 7, 33, 36, 33, 60,
- 7, 7, 7, 5, 7, 5, 5, 90, 33, 36,
- 7, 33, 7, 36, 7, 33, 66, 36, 7, 36,
- 29, 7, 33, 31, 1, 7, 17, 55, 60, 33,
- 60, 2, 8, 7, 48, 66, 1, 7, 36, 2,
- 8, 7, 36, 2, 60, 2, 8, 7, 17, 1,
- 60, 36, 0, 36, 8, 36, 48, 36, 33, 8,
- 61, 1, 6, 36, 60, 8, -1, 8, -1, 15,
- 48, 10, 7, 8, 61, 8, 20, -1, -1, -1,
- -1, -1, 8, -1, -1, -1, -1, 48, 34, 79,
- 40, 79, 8, 77, 61, 8, 60, 8, 8, 79,
- 8, 51, -1, 40, 42, 61, 62, 8, 61, 62,
- 8, 7, -1, 56, 51, 53, 55, 8, 90, 60,
- 50, 79, 8, 56, 54, 61, 62, 61, 62, 61,
- 62, 40, 61, 62, 60, 40, 61, 62, 61, 62,
- 56, 8, 51, 56, 50, 7, 51, 15, 54, 60,
- 60, 25, 60, 27, 25, 56, 27, 61, 62, 61,
- 62, 36, 60, 29, 38, 29, 34, 38, 36, 25,
- 61, 27, 29, -1, 60, 25, 12, 27, 29, 25,
- 29, 27, 38, 25, 29, 27, 61, 62, 38, 12,
- 7, 12, 38, 60, 8, 25, 38, 27, -1, 61,
- 62, 25, 8, 27, 7, -1, 15, 7, 38, 75,
- 25, 75, 27, 8, 38, 25, 33, 27, 75, -1,
- 86, 57, 86, 38, 75, 34, 75, 63, 38, 86,
- 75, 15, 15, -1, 57, 86, 57, 86, -1, -1,
- 63, 86, 63, 61, 62, -1, -1, 61, 62, 15,
- 34, 34, 36, 36, -1, 61, 62, 47, 61, 62,
- 15, 61, 62, -1, 18, 19, 61, 62, 34, 15,
- 36, 61, 62, 91, -1, 92, 18, 19, 33, 34,
- 29, 36, 18, 19, 18, 19, 29, 33, 34, 29,
- 36, 45, 46, 25, 29, 27, -1, -1, -1, -1,
- -1, 91, -1, 45, 46, -1, 38, -1, -1, 45,
- 46, 45, 46, -1, -1, -1, -1, 66, 67, 68,
- -1, -1, -1, 66, 67, 68, 66, 67, 68, -1,
- -1, 66, 67, 68, -1, -1, 23, 24, -1, -1,
- -1, 29, -1, 92, -1, 32, 23, 24, 35, 92,
- 37, 29, 92, 23, 24, 32, 29, 92, 35, -1,
- 37, 29, 32, 23, 24, 35, -1, 37, -1, -1,
- 29, -1, 32, 23, 24, 35, -1, 37, 66, 67,
- 68, 31, 32, -1, 29, 35, -1, 37, 66, 67,
- 68, 36, -1, 66, 67, 68, -1, -1, 66, 67,
- 68, -1, -1, -1, 92, -1, -1, 66, 67, 68,
- -1, -1, -1, -1, 92, -1, -1, 23, 24, 92,
- -1, 66, 67, 68, 92, 31, 32, 23, 24, 35,
- -1, 37, -1, 92, -1, 31, 32, 23, 24, 35,
- -1, 37, 29, 23, 24, 31, 32, 92, -1, 35,
- 29, 37, 32, 29, -1, 35, -1, 37, 94, 95,
- 96, 97, 98, 99, 29, -1, -1, -1, -1, -1,
- -1, 36, -1, -1, 61, 62, -1, -1, -1, 66,
- 67, 68, 61, 62, -1, 61, 62, 66, 67, 68,
- 66, 67, 68, -1, -1, -1, -1, -1, -1, -1,
- 29, 66, 67, 68, -1, 92, -1, -1, 29, -1,
- -1, 29, -1, 92, -1, -1, 92, -1, -1, -1,
- -1, -1, 23, 24, -1, -1, -1, 92, -1, -1,
- 31, 32, 61, 62, 35, -1, 37, 66, 67, 68,
- 61, 62, 3, 61, 62, 66, 67, 68, 66, 67,
- 68, -1, 13, -1, -1, -1, 17, -1, -1, -1,
- -1, -1, -1, 92, -1, 26, -1, 28, -1, -1,
- 31, 92, -1, -1, 92, -1, -1, -1, 39, -1,
- 41, 42, -1, -1, -1, -1, -1, -1, 49, -1,
- -1, 52, 53, -1, -1, -1, -1, 58, -1, 12,
- 13, 3, -1, 64, -1, -1, -1, -1, -1, 22,
- -1, 13, -1, -1, -1, 17, 29, -1, -1, 80,
- 33, 34, -1, 36, 26, -1, 28, -1, -1, -1,
- 43, -1, -1, -1, 47, -1, -1, 39, -1, 41,
- 42, -1, -1, -1, -1, -1, -1, 49, -1, -1,
- 52, 53, 65, 66, 67, 68, 58, 70, -1, -1,
- -1, -1, 64, -1, -1, -1, -1, -1, 81, 82,
- 83, -1, 12, 13, 87, -1, -1, -1, 80, 92,
+ 60, 7, 7, 7, 34, 91, 24, 7, 61, 36,
+ 33, 36, 7, 7, 7, 60, 33, 33, 55, 66,
+ 8, 33, 55, 36, 16, 7, 36, 29, 8, 7,
+ 7, 55, 17, 36, 7, 7, 7, 7, 7, 36,
+ 55, 7, 7, 33, 33, 36, 33, 33, 7, 60,
+ 7, 60, 20, 36, 33, 36, 55, 7, 33, 60,
+ 5, 37, 36, 5, 60, 5, 7, 2, 66, 36,
+ 33, 33, 36, 7, 1, 8, 60, 8, 33, 2,
+ 36, 1, 8, 36, 2, 1, 8, 2, 17, 1,
+ 0, 8, -1, 7, 55, 33, 33, -1, -1, 48,
+ 60, -1, 6, 31, 55, 48, 36, 61, 60, 8,
+ -1, 36, 60, -1, 7, 61, 20, 36, 8, 77,
+ 15, 60, 8, 55, 48, 36, 10, 36, 36, 36,
+ 7, 8, 79, 8, 8, 79, 8, 42, 8, 34,
+ 8, 8, 48, 40, 8, 8, -1, 60, 53, 50,
+ -1, 8, -1, 54, 51, 91, 15, 8, 79, 61,
+ 62, 60, 8, 61, 62, 61, 62, 61, 62, 40,
+ 60, 55, 61, 62, 60, 34, 61, 62, 61, 62,
+ 51, 56, 61, 62, 56, 50, 60, 40, 15, 54,
+ 60, 40, 60, 56, 61, 25, 60, 27, 51, 61,
+ 62, 29, 51, 60, 29, 56, 15, 34, 38, 36,
+ 15, 29, 8, 8, 12, 61, 62, 61, 62, 12,
+ 36, 25, 7, 27, 25, 34, 27, 36, 25, 34,
+ 27, 36, 7, 15, 38, 29, 25, 38, 27, 7,
+ -1, 38, 25, 29, 27, 61, 62, 75, 92, 38,
+ 75, 12, 34, 7, 36, 38, -1, 75, 86, 57,
+ 56, 86, -1, -1, 57, 63, 61, 62, 86, 25,
+ 63, 27, 25, -1, 27, -1, 61, 62, 25, 33,
+ 27, 75, 38, 61, 62, 38, 61, 62, 25, 75,
+ 27, 38, 86, 61, 62, 25, 57, 27, 29, -1,
+ 86, 38, 63, 25, 25, 27, 27, 15, 38, 8,
+ -1, 89, -1, 18, 19, 47, 38, 38, 18, 19,
+ 18, 19, -1, -1, -1, 33, 34, -1, 36, 61,
+ 62, 15, 97, 98, 99, 100, 101, 102, -1, 93,
+ 45, 46, 23, 24, 75, 45, 46, 45, 46, 33,
+ 34, 32, 36, -1, 35, 86, 37, 23, 24, -1,
+ 92, -1, 61, 62, 23, 24, 32, -1, -1, 35,
+ -1, 37, -1, 32, 23, 24, 35, -1, 37, -1,
+ 23, 24, -1, 32, -1, -1, 35, -1, 37, 32,
+ 23, 24, 35, 29, 37, -1, -1, -1, 31, 32,
+ 23, 24, 35, 29, 37, -1, 18, 19, 31, 32,
+ 23, 24, 35, 29, 37, -1, -1, -1, 31, 32,
+ -1, -1, 35, 29, 37, -1, 29, -1, -1, -1,
+ 66, 67, 68, 45, 46, -1, -1, -1, -1, -1,
+ 66, 67, 68, -1, 29, -1, -1, 29, -1, -1,
+ 66, 67, 68, -1, -1, -1, -1, 93, 94, 95,
+ 66, 67, 68, 66, 67, 68, -1, 93, 94, 95,
+ -1, -1, -1, -1, -1, -1, -1, 93, 94, 95,
+ 29, 66, 67, 68, 66, 67, 68, 93, 94, 95,
+ 93, 94, 95, 23, 24, 29, -1, -1, 29, -1,
+ -1, 31, 32, -1, -1, 35, -1, 37, 93, 94,
+ 95, 93, 94, 95, 29, -1, -1, 66, 67, 68,
+ -1, 36, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, 29, 66, 67, 68, 66, 67, 68, 36, -1,
+ -1, -1, -1, -1, 93, 94, 95, -1, -1, -1,
+ -1, 66, 67, 68, 29, -1, -1, -1, -1, 93,
+ 94, 95, 93, 94, 95, 29, -1, -1, 66, 67,
+ 68, -1, 36, -1, -1, 29, -1, -1, 93, 94,
+ 95, -1, -1, -1, 29, -1, 61, 62, -1, -1,
+ -1, 66, 67, 68, -1, 93, 94, 95, -1, -1,
+ -1, -1, 66, 67, 68, 29, -1, -1, -1, -1,
+ -1, -1, 66, 67, 68, -1, 61, 62, 93, 94,
+ 95, 66, 67, 68, -1, -1, -1, -1, -1, 93,
+ 94, 95, -1, -1, -1, -1, -1, 61, 62, 93,
+ 94, 95, 66, 67, 68, -1, -1, -1, 93, 94,
+ 95, 29, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, 93,
+ 94, 95, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 61, 62, 3, -1, -1, 66, 67,
+ 68, -1, -1, -1, -1, 13, -1, -1, -1, 17,
+ -1, -1, -1, -1, -1, -1, -1, -1, 26, -1,
+ 28, -1, -1, 31, -1, 93, 94, 95, -1, -1,
+ -1, 39, -1, 41, 42, -1, -1, 3, -1, -1,
+ -1, 49, -1, -1, 52, 53, -1, 13, -1, -1,
+ 58, 17, -1, -1, -1, -1, 64, -1, -1, -1,
+ 26, -1, 28, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 80, 39, -1, 41, 42, -1, -1, -1,
+ -1, -1, -1, 49, -1, -1, 52, 53, -1, -1,
+ -1, -1, 58, -1, -1, -1, -1, -1, 64, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 80, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, 12,
+ 13, -1, -1, -1, -1, -1, -1, -1, -1, 22,
+ -1, -1, -1, -1, -1, -1, 29, -1, -1, -1,
+ 33, 34, -1, 36, -1, -1, -1, -1, -1, -1,
+ 43, -1, -1, -1, 47, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 65, 66, 67, 68, -1, 70, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 81, 82,
+ 83, -1, -1, -1, 87, -1, -1, -1, -1, -1,
+ 93, 94, 95, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 12, 13, -1, -1, -1, -1, -1, -1,
-1, -1, 22, -1, -1, -1, -1, -1, -1, 29,
-1, -1, -1, 33, 34, -1, 36, -1, -1, -1,
- 12, 13, -1, 43, -1, -1, -1, 47, -1, -1,
- 22, -1, -1, -1, -1, -1, -1, 29, -1, -1,
- -1, 33, 34, -1, 36, 65, 66, 67, 68, -1,
- 70, 43, -1, -1, -1, 47, -1, -1, -1, -1,
- -1, 81, 82, 83, -1, -1, -1, 87, -1, -1,
- -1, -1, 92, 65, 66, 67, 68, -1, 70, -1,
- -1, -1, 12, 13, -1, -1, -1, -1, -1, 81,
- 82, 83, 22, -1, -1, 87, -1, -1, -1, 29,
- 92, -1, -1, 33, 34, -1, 36, -1, -1, -1,
- 12, 13, -1, 43, -1, -1, -1, 47, -1, -1,
- 22, -1, -1, -1, -1, -1, -1, 29, -1, -1,
- -1, 33, 34, -1, 36, 65, 66, 67, 68, -1,
- 70, 43, -1, -1, -1, 47, -1, -1, -1, -1,
- -1, 81, 82, 83, -1, -1, -1, 87, -1, -1,
- -1, -1, 92, 65, 66, 67, 68, -1, 70, -1,
- -1, -1, 12, 13, -1, -1, -1, -1, -1, 81,
- 82, 83, 22, -1, -1, 87, -1, -1, -1, 29,
- 92, -1, -1, 33, 34, -1, 36, -1, -1, -1,
- 12, 13, -1, 43, -1, -1, -1, 47, -1, -1,
- 22, -1, -1, -1, -1, -1, -1, 29, -1, -1,
- -1, 33, 34, -1, 36, 65, 66, 67, 68, -1,
- 70, 43, -1, -1, -1, 47, -1, -1, -1, -1,
+ -1, -1, -1, 43, -1, -1, -1, 47, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, 65, 66, 67, 68, -1,
+ 70, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, 81, 82, 83, -1, -1, -1, 87, -1, -1,
- -1, -1, 92, 65, 66, 67, 68, -1, 70, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 81,
- 82, 83, -1, -1, -1, 87, -1, -1, -1, -1,
- 92, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 93, 94, 95, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, 10, -1, 12, 13, -1,
+ -1, -1, -1, -1, -1, -1, -1, 22, -1, -1,
+ -1, -1, -1, -1, 29, -1, -1, -1, 33, 34,
+ -1, 36, -1, -1, -1, -1, -1, -1, 43, -1,
+ -1, -1, 47, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ 65, 66, 67, 68, -1, 70, -1, -1, -1, -1,
+ 75, -1, -1, -1, -1, -1, 81, 82, 83, 84,
+ -1, -1, 87, -1, -1, -1, -1, -1, 93, 94,
+ 95, -1, -1, -1, -1, -1, -1, -1, -1, -1,
10, -1, 12, 13, -1, -1, -1, -1, -1, -1,
-1, -1, 22, -1, -1, -1, -1, -1, -1, 29,
-1, -1, -1, 33, 34, -1, 36, -1, -1, -1,
-1, -1, -1, 43, -1, -1, -1, 47, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, 55, -1, -1, -1, -1,
-1, -1, -1, -1, -1, 65, 66, 67, 68, -1,
70, -1, -1, -1, -1, 75, -1, -1, -1, -1,
-1, 81, 82, 83, 84, -1, -1, 87, -1, -1,
- -1, -1, 92, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 10, -1, 12, 13, -1, -1, -1, -1,
- -1, -1, -1, -1, 22, -1, -1, -1, -1, -1,
- -1, 29, -1, -1, -1, 33, 34, -1, 36, -1,
- -1, -1, -1, -1, -1, 43, -1, -1, -1, 47,
- -1, -1, -1, -1, -1, -1, -1, 55, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 65, 66, 67,
- 68, -1, 70, -1, -1, -1, -1, 75, -1, -1,
- -1, -1, -1, 81, 82, 83, 84, -1, -1, 87,
- -1, -1, -1, -1, 92, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, 10, -1, 12, 13, -1, -1,
- -1, -1, -1, -1, -1, -1, 22, -1, -1, -1,
- -1, -1, -1, 29, -1, -1, -1, 33, 34, -1,
- 36, -1, -1, -1, -1, -1, -1, 43, -1, -1,
- -1, 47, -1, -1, -1, -1, -1, -1, -1, 55,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 65,
- 66, 67, 68, -1, 70, -1, -1, -1, -1, 75,
- -1, -1, -1, -1, -1, 81, 82, 83, 84, -1,
- -1, 87, -1, -1, -1, -1, 92, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 11, 12, 13, -1,
+ -1, -1, -1, 93, 94, 95, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, 10, -1, 12, 13, -1,
-1, -1, -1, -1, -1, -1, -1, 22, -1, -1,
-1, -1, -1, -1, 29, -1, -1, -1, 33, 34,
- -1, 36, -1, -1, -1, 40, -1, 42, 43, 44,
- -1, -1, 47, -1, -1, -1, 51, -1, 53, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 65, 66, 67, 68, -1, 70, -1, 72, -1, 74,
- -1, 76, -1, -1, -1, -1, 81, 82, 83, -1,
- -1, -1, 87, -1, -1, -1, -1, 92, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 7, -1, -1,
- -1, 11, 12, 13, -1, -1, -1, -1, -1, -1,
- -1, -1, 22, -1, -1, -1, -1, -1, -1, 29,
- -1, -1, -1, 33, 34, -1, 36, -1, -1, -1,
- 40, -1, 42, 43, 44, -1, -1, 47, -1, -1,
- -1, 51, -1, 53, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, 65, 66, 67, 68, -1,
- 70, -1, 72, -1, 74, -1, 76, -1, -1, -1,
- -1, 81, 82, 83, -1, -1, -1, 87, -1, -1,
- -1, -1, 92, -1, -1, -1, -1, -1, -1, -1,
+ -1, 36, -1, -1, -1, -1, -1, -1, 43, -1,
+ -1, -1, 47, -1, -1, -1, -1, -1, -1, -1,
+ 55, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ 65, 66, 67, 68, -1, 70, -1, -1, -1, -1,
+ 75, -1, -1, -1, -1, -1, 81, 82, 83, 84,
+ -1, -1, 87, -1, -1, -1, -1, -1, 93, 94,
+ 95, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ 11, 12, 13, -1, -1, -1, -1, -1, -1, -1,
+ -1, 22, -1, -1, -1, -1, -1, -1, 29, -1,
+ -1, -1, 33, 34, -1, 36, -1, -1, -1, 40,
+ -1, 42, 43, 44, -1, -1, 47, -1, -1, -1,
+ 51, -1, 53, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 65, 66, 67, 68, -1, 70,
+ -1, 72, -1, 74, -1, 76, -1, -1, -1, -1,
+ 81, 82, 83, -1, -1, -1, 87, -1, -1, -1,
+ -1, -1, 93, 94, 95, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 7, -1, -1, -1, 11, 12,
+ 13, -1, -1, -1, -1, -1, -1, -1, -1, 22,
+ -1, -1, -1, -1, -1, -1, 29, -1, -1, -1,
+ 33, 34, -1, 36, -1, -1, -1, 40, -1, 42,
+ 43, 44, -1, -1, 47, -1, -1, -1, 51, -1,
+ 53, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 65, 66, 67, 68, -1, 70, -1, 72,
+ -1, 74, -1, 76, -1, -1, -1, -1, 81, 82,
+ 83, -1, -1, -1, 87, -1, -1, -1, -1, -1,
+ 93, 94, 95, -1, -1, -1, -1, -1, -1, -1,
-1, -1, 11, 12, 13, -1, -1, -1, -1, -1,
-1, -1, -1, 22, -1, -1, -1, -1, -1, -1,
29, -1, -1, -1, 33, 34, -1, 36, -1, -1,
@@ -833,7 +865,17 @@ const short QQmlJSGrammar::action_check [] = {
-1, -1, -1, -1, -1, -1, 65, 66, 67, 68,
-1, 70, -1, 72, -1, 74, 75, 76, -1, -1,
-1, -1, 81, 82, 83, -1, -1, -1, 87, -1,
- -1, -1, -1, 92, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 93, 94, 95, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 8, -1, -1, 11,
+ 12, 13, -1, -1, -1, -1, -1, -1, -1, -1,
+ 22, -1, -1, -1, -1, -1, -1, 29, -1, -1,
+ -1, 33, 34, -1, 36, -1, -1, -1, 40, -1,
+ 42, 43, 44, -1, -1, 47, -1, -1, -1, 51,
+ -1, 53, -1, -1, 56, -1, -1, -1, -1, -1,
+ -1, -1, -1, 65, 66, 67, 68, -1, 70, -1,
+ 72, -1, 74, -1, 76, -1, -1, -1, -1, 81,
+ 82, 83, -1, -1, -1, 87, -1, -1, -1, -1,
+ -1, 93, 94, 95, -1, -1, -1, -1, -1, -1,
-1, -1, -1, 8, -1, -1, 11, 12, 13, -1,
-1, -1, -1, -1, -1, -1, -1, 22, -1, -1,
-1, -1, -1, -1, 29, -1, -1, -1, 33, 34,
@@ -842,7 +884,17 @@ const short QQmlJSGrammar::action_check [] = {
-1, 56, -1, -1, -1, -1, -1, -1, -1, -1,
65, 66, 67, 68, -1, 70, -1, 72, -1, 74,
-1, 76, -1, -1, -1, -1, 81, 82, 83, -1,
- -1, -1, 87, -1, -1, -1, -1, 92, -1, -1,
+ -1, -1, 87, -1, -1, -1, -1, -1, 93, 94,
+ 95, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ 8, -1, -1, 11, 12, 13, -1, -1, -1, -1,
+ -1, -1, -1, -1, 22, -1, -1, -1, -1, -1,
+ -1, 29, -1, -1, -1, 33, 34, -1, 36, -1,
+ -1, -1, 40, -1, 42, 43, 44, -1, -1, 47,
+ -1, -1, -1, 51, -1, 53, -1, -1, 56, -1,
+ -1, -1, -1, -1, -1, -1, -1, 65, 66, 67,
+ 68, -1, 70, -1, 72, -1, 74, -1, 76, -1,
+ -1, -1, -1, 81, 82, 83, -1, -1, -1, 87,
+ -1, -1, -1, -1, -1, 93, 94, 95, -1, -1,
-1, -1, -1, -1, -1, -1, -1, 8, -1, -1,
11, 12, 13, -1, -1, -1, -1, -1, -1, -1,
-1, 22, -1, -1, -1, -1, -1, -1, 29, -1,
@@ -852,102 +904,96 @@ const short QQmlJSGrammar::action_check [] = {
-1, -1, -1, -1, 65, 66, 67, 68, -1, 70,
-1, 72, -1, 74, -1, 76, -1, -1, -1, -1,
81, 82, 83, -1, -1, -1, 87, -1, -1, -1,
- -1, 92, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 8, -1, -1, 11, 12, 13, -1, -1, -1,
+ -1, -1, 93, 94, 95, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 11, 12, 13, -1, -1, -1,
-1, -1, -1, -1, -1, 22, -1, -1, -1, -1,
- -1, -1, 29, -1, -1, -1, 33, 34, -1, 36,
+ -1, -1, 29, 30, -1, -1, 33, 34, -1, 36,
-1, -1, -1, 40, -1, 42, 43, 44, -1, -1,
- 47, -1, -1, -1, 51, -1, 53, -1, -1, 56,
- -1, -1, -1, -1, -1, -1, -1, -1, 65, 66,
- 67, 68, -1, 70, -1, 72, -1, 74, -1, 76,
- -1, -1, -1, -1, 81, 82, 83, -1, -1, -1,
- 87, -1, -1, -1, -1, 92, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, 8, -1, -1, 11, 12,
+ 47, -1, -1, -1, 51, -1, 53, -1, -1, -1,
+ -1, -1, -1, -1, 61, -1, -1, -1, 65, 66,
+ 67, 68, 69, 70, -1, 72, 73, 74, -1, 76,
+ -1, 78, -1, -1, 81, 82, 83, -1, -1, -1,
+ 87, -1, -1, -1, -1, -1, 93, 94, 95, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 11, 12,
13, -1, -1, -1, -1, -1, -1, -1, -1, 22,
- -1, -1, -1, -1, -1, -1, 29, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 29, 30, -1, -1,
33, 34, -1, 36, -1, -1, -1, 40, -1, 42,
43, 44, -1, -1, 47, -1, -1, -1, 51, -1,
- 53, -1, -1, 56, -1, -1, -1, -1, -1, -1,
- -1, -1, 65, 66, 67, 68, -1, 70, -1, 72,
- -1, 74, -1, 76, -1, -1, -1, -1, 81, 82,
- 83, -1, -1, -1, 87, -1, -1, -1, -1, 92,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 11,
- 12, 13, -1, -1, -1, -1, -1, -1, -1, -1,
- 22, -1, -1, -1, -1, -1, -1, 29, 30, -1,
- -1, 33, 34, -1, 36, -1, -1, -1, 40, -1,
- 42, 43, 44, -1, -1, 47, -1, -1, -1, 51,
- -1, 53, -1, -1, -1, -1, -1, -1, -1, 61,
- -1, -1, -1, 65, 66, 67, 68, 69, 70, -1,
- 72, 73, 74, -1, 76, -1, 78, -1, -1, 81,
- 82, 83, -1, -1, -1, 87, -1, -1, -1, -1,
- 92, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 11, 12, 13, -1, -1, -1, -1, -1, -1, -1,
- -1, 22, -1, -1, -1, -1, -1, -1, 29, 30,
- -1, -1, 33, 34, -1, 36, -1, -1, -1, 40,
- -1, 42, 43, 44, -1, -1, 47, -1, -1, -1,
- 51, -1, 53, -1, -1, -1, -1, -1, -1, -1,
- 61, -1, -1, -1, 65, 66, 67, 68, 69, 70,
- -1, 72, 73, 74, -1, 76, -1, 78, -1, -1,
- 81, 82, 83, -1, -1, -1, 87, -1, -1, -1,
- -1, 92, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 4, 5, 6, -1, -1, 9, 10, 11, -1,
- -1, 14, -1, 16, -1, -1, -1, 20, 21, 22,
- -1, -1, -1, -1, -1, -1, 29, 30, 31, 32,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 43, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 59, -1, -1, -1,
- -1, -1, -1, 66, 67, 68, 69, 70, 71, -1,
- 73, 74, 75, 76, 77, 78, -1, -1, 81, 82,
- 83, 84, 85, 86, -1, -1, -1, -1, -1, 92,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, 4,
- 5, 6, -1, -1, 9, 10, 11, -1, -1, 14,
- -1, 16, -1, -1, -1, 20, 21, 22, -1, -1,
- -1, -1, -1, -1, 29, 30, 31, 32, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 43, -1,
- -1, -1, 47, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, 59, -1, -1, -1, -1, -1,
- 65, 66, 67, -1, 69, 70, 71, -1, 73, 74,
- 75, 76, 77, 78, -1, -1, 81, 82, 83, 84,
- 85, 86, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 4, 5, 6,
- -1, -1, 9, 10, 11, -1, -1, 14, -1, 16,
- -1, -1, -1, 20, 21, 22, -1, -1, -1, -1,
- -1, -1, 29, 30, 31, 32, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 43, -1, -1, -1,
- 47, -1, -1, -1, -1, -1, -1, -1, 55, -1,
- -1, -1, 59, -1, -1, -1, -1, -1, 65, 66,
- 67, -1, 69, 70, 71, -1, 73, 74, 75, 76,
- 77, 78, -1, -1, 81, 82, 83, 84, 85, 86,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, 4, -1, -1, -1, -1,
- 9, -1, 11, 12, 13, 14, -1, -1, -1, -1,
- -1, -1, 21, 22, -1, -1, -1, -1, -1, -1,
- 29, 30, -1, -1, 33, 34, -1, 36, -1, -1,
- -1, 40, -1, 42, 43, 44, -1, -1, 47, -1,
- -1, -1, 51, -1, 53, -1, -1, -1, -1, -1,
- 59, -1, 61, -1, -1, -1, 65, 66, 67, 68,
- 69, 70, 71, 72, 73, 74, 75, 76, 77, 78,
- -1, -1, 81, 82, 83, 84, 85, -1, 87, -1,
- -1, -1, -1, 92, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 4, -1, -1, -1, -1, 9, -1,
- 11, 12, 13, 14, -1, -1, -1, -1, -1, -1,
+ 53, -1, -1, -1, -1, -1, -1, -1, 61, -1,
+ -1, -1, 65, 66, 67, 68, 69, 70, -1, 72,
+ 73, 74, -1, 76, -1, 78, -1, -1, 81, 82,
+ 83, -1, -1, -1, 87, -1, -1, -1, -1, -1,
+ 93, 94, 95, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 4, 5, 6, -1, -1, 9, 10, 11,
+ -1, -1, 14, -1, 16, -1, -1, -1, 20, 21,
+ 22, -1, -1, -1, -1, -1, -1, 29, 30, 31,
+ 32, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, 43, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, 59, -1, -1,
+ -1, -1, -1, -1, 66, 67, 68, 69, 70, 71,
+ -1, 73, 74, 75, 76, 77, 78, -1, -1, 81,
+ 82, 83, 84, 85, 86, -1, -1, -1, -1, -1,
+ -1, 93, 94, 95, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 4, 5, 6, -1, -1, 9, 10,
+ 11, -1, -1, 14, -1, 16, -1, -1, -1, 20,
21, 22, -1, -1, -1, -1, -1, -1, 29, 30,
- -1, -1, 33, 34, -1, 36, -1, -1, -1, 40,
- -1, 42, 43, 44, -1, -1, 47, -1, -1, -1,
- 51, -1, 53, -1, -1, -1, -1, -1, 59, -1,
- 61, -1, -1, -1, 65, 66, 67, 68, 69, 70,
- 71, 72, 73, 74, 75, 76, 77, 78, -1, -1,
- 81, 82, 83, 84, 85, -1, 87, -1, -1, -1,
- -1, 92, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 4, 5, 6, -1, -1, 9, 10, 11, 12,
- 13, 14, -1, 16, -1, -1, -1, 20, 21, 22,
- -1, -1, -1, -1, -1, -1, 29, 30, 31, 32,
- 33, 34, -1, 36, -1, -1, -1, 40, -1, 42,
- 43, 44, -1, -1, 47, -1, -1, -1, 51, -1,
- 53, -1, -1, -1, -1, -1, 59, -1, 61, -1,
- -1, -1, 65, 66, 67, 68, 69, 70, 71, 72,
- 73, 74, 75, 76, 77, 78, -1, -1, 81, 82,
- 83, 84, 85, 86, 87, -1, -1, -1, -1, 92,
+ 31, 32, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, 43, -1, -1, -1, 47, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 59, -1,
+ -1, -1, -1, -1, 65, 66, 67, 68, 69, 70,
+ 71, -1, 73, 74, 75, 76, 77, 78, -1, -1,
+ 81, 82, 83, 84, 85, 86, -1, -1, -1, -1,
+ -1, -1, 93, 94, 95, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 4, 5, 6, -1, -1, 9,
+ 10, 11, -1, -1, 14, -1, 16, -1, -1, -1,
+ 20, 21, 22, -1, -1, -1, -1, -1, -1, 29,
+ 30, 31, 32, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 43, -1, -1, -1, 47, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, 59,
+ -1, -1, -1, -1, -1, 65, 66, 67, 68, 69,
+ 70, 71, -1, 73, 74, 75, 76, 77, 78, -1,
+ -1, 81, 82, 83, 84, 85, 86, -1, -1, -1,
+ -1, -1, -1, 93, 94, 95, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, 4, 5, 6, -1, -1,
+ 9, 10, 11, -1, -1, 14, -1, 16, -1, -1,
+ -1, 20, 21, 22, -1, -1, -1, -1, -1, -1,
+ 29, 30, 31, 32, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 43, -1, -1, -1, 47, -1,
+ -1, -1, -1, -1, -1, -1, 55, -1, -1, -1,
+ 59, -1, -1, -1, -1, -1, 65, 66, 67, 68,
+ 69, 70, 71, -1, 73, 74, 75, 76, 77, 78,
+ -1, -1, 81, 82, 83, 84, 85, 86, -1, -1,
+ -1, -1, -1, -1, 93, 94, 95, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 4, -1, -1, -1,
+ -1, 9, -1, 11, 12, 13, 14, -1, -1, -1,
+ -1, -1, -1, 21, 22, -1, -1, -1, -1, -1,
+ -1, 29, 30, -1, -1, 33, 34, -1, 36, -1,
+ -1, -1, 40, -1, 42, 43, 44, -1, -1, 47,
+ -1, -1, -1, 51, -1, 53, -1, -1, -1, -1,
+ -1, 59, -1, 61, -1, -1, -1, 65, 66, 67,
+ 68, 69, 70, 71, 72, 73, 74, 75, 76, 77,
+ 78, -1, -1, 81, 82, 83, 84, 85, -1, 87,
+ -1, -1, -1, -1, -1, 93, 94, 95, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, 4, -1, -1,
+ -1, -1, 9, -1, 11, 12, 13, 14, -1, -1,
+ -1, -1, -1, -1, 21, 22, -1, -1, -1, -1,
+ -1, -1, 29, 30, -1, -1, 33, 34, -1, 36,
+ -1, -1, -1, 40, -1, 42, 43, 44, -1, -1,
+ 47, -1, -1, -1, 51, -1, 53, -1, -1, -1,
+ -1, -1, 59, -1, 61, -1, -1, -1, 65, 66,
+ 67, 68, 69, 70, 71, 72, 73, 74, 75, 76,
+ 77, 78, -1, -1, 81, 82, 83, 84, 85, -1,
+ 87, -1, -1, -1, -1, -1, 93, 94, 95, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 4, 5,
+ 6, -1, -1, 9, 10, 11, 12, 13, 14, -1,
+ 16, -1, -1, -1, 20, 21, 22, -1, -1, -1,
+ -1, -1, -1, 29, 30, 31, 32, 33, 34, -1,
+ 36, -1, -1, -1, 40, -1, 42, 43, 44, -1,
+ -1, 47, -1, -1, -1, 51, -1, 53, -1, -1,
+ -1, -1, -1, 59, -1, 61, -1, -1, -1, 65,
+ 66, 67, 68, 69, 70, 71, 72, 73, 74, 75,
+ 76, 77, 78, -1, -1, 81, 82, 83, 84, 85,
+ 86, 87, -1, -1, -1, -1, -1, 93, 94, 95,
-1, -1, -1, -1, -1, -1, -1, -1, -1, 4,
5, 6, -1, -1, 9, 10, 11, 12, 13, 14,
-1, 16, -1, -1, -1, 20, 21, 22, -1, -1,
@@ -957,57 +1003,66 @@ const short QQmlJSGrammar::action_check [] = {
55, -1, -1, -1, 59, -1, 61, -1, -1, -1,
65, 66, 67, 68, 69, 70, 71, 72, 73, 74,
75, 76, 77, 78, -1, -1, 81, 82, 83, 84,
- 85, 86, 87, -1, -1, -1, -1, 92, -1, -1,
- -1, -1, -1, -1, -1, -1, -1,
+ 85, 86, 87, -1, -1, -1, -1, -1, 93, 94,
+ 95, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 15, 2, 105, 3, 29, 15, 4, 2, 15, 29,
- 9, 15, 3, 15, 3, 2, 19, 39, 15, 15,
- 13, 15, 3, 15, 2, 15, 3, 15, 3, 11,
- 13, 15, 71, 39, 39, 3, 22, 2, 99, 19,
- 4, 15, 2, 15, 29, 15, 19, 3, 15, 3,
- 29, 22, 15, 29, 15, 2, 22, 15, 2, 2,
- 15, 2, 2, 2, 2, 22, 3, 15, 3, 2,
- 39, 3, 3, 15, 97, 94, 3, 39, 2, 2,
- 39, 3, 3, 2, 2, 101, 3, 40, 39, 39,
- 39, 3, 2, 39, 39, 15, 22, 13, 3, 2,
- 13, 2, -1, 39, 13, 35, -1, 16, -1, 39,
- -1, -1, -1, 15, 48, -1, 15, 13, 52, 48,
- 48, 50, 3, 48, 20, 53, -1, 52, -1, 45,
- -1, 15, 45, 48, 48, 50, 50, 48, -1, 50,
- 48, 48, 48, 50, 48, 53, 52, 39, 48, 53,
- 48, 39, 44, 53, 48, 53, 44, 48, 15, 50,
- -1, 48, 48, 48, 58, 48, 3, 72, 53, 48,
- 53, 50, 48, 48, 50, 48, 62, 64, 53, 82,
- 53, 82, 48, 48, 41, 13, 88, 53, 16, 54,
- 48, 72, 48, 3, 50, 48, 54, 4, 48, 13,
- 50, 100, 86, 56, 48, 48, 50, 50, 48, 48,
- 50, -1, 51, 48, 48, 48, 51, 50, 48, 48,
- 54, 50, 48, 53, 50, 48, 48, 48, 50, 48,
- 53, 45, 48, 54, 50, 72, -1, 48, -1, 48,
- -1, 60, 53, 48, 53, 48, 15, 48, 53, -1,
- 53, 48, 53, 48, 65, -1, 53, -1, 53, 48,
- 55, 70, 72, 48, 53, 70, 63, 70, 53, 70,
- 48, 48, 41, 42, 59, 53, 53, 55, 48, 13,
- 57, 70, 48, 53, 48, 55, 20, 53, -1, 53,
- -1, 55, -1, 5, -1, 61, 5, -1, 32, 33,
- 13, 13, -1, 16, 13, -1, -1, -1, 20, -1,
- -1, 20, 22, 23, 24, 25, 26, 27, 28, -1,
- 32, 33, -1, 32, 33, 21, 22, 23, 24, 25,
- 26, 27, 28, 13, -1, -1, -1, -1, -1, -1,
- 20, 21, 22, 23, 24, 25, 26, 27, 28, 13,
- -1, -1, -1, -1, -1, -1, 20, 21, 22, 23,
- 24, 25, 26, 27, 28, -1, -1, -1, -1, -1,
+ 15, 39, 29, 3, 15, 15, 13, 15, 3, 15,
+ 29, 9, 15, 15, 3, 3, 39, 22, 19, 15,
+ 19, 3, 15, 15, 15, 11, 3, 74, 15, 19,
+ 15, 15, 29, 13, 15, 29, 102, 15, 3, 15,
+ 97, 3, 100, 15, -1, 15, 29, 22, 15, 3,
+ 3, 15, 3, 22, 15, 15, 22, 15, 15, 3,
+ 39, 3, 3, 3, 3, 39, 39, 22, 39, 3,
+ 15, 39, 15, 2, -1, 13, 39, 13, 2, 2,
+ 39, 13, 13, 39, 2, 15, 15, 39, 20, 3,
+ 3, 15, 15, 3, 15, 15, 2, 15, 41, -1,
+ 2, 51, 51, 51, 53, 51, 56, 53, 56, 15,
+ 48, 41, 48, 15, 51, 15, 51, 48, 51, 56,
+ 39, 56, 39, 56, 51, 51, 53, 53, 47, 51,
+ 47, 53, 4, 15, 2, 51, 15, 53, 15, 51,
+ 40, 15, 51, 15, 53, 4, 51, 15, 53, 15,
+ 51, 63, 53, 51, 51, 13, 15, 51, 16, 53,
+ 42, 75, 75, 51, 3, 44, 43, 65, 15, 43,
+ 67, 91, 13, 61, -1, 16, 42, 15, 51, 15,
+ 51, 54, 51, 54, 51, 106, 53, 56, 51, 13,
+ 53, 51, 16, 53, 2, 51, 43, 51, 35, 2,
+ 56, 15, 39, 51, 42, 59, 42, 15, 56, 51,
+ 2, 51, 15, 2, 56, -1, 56, 51, 51, 51,
+ 2, 51, 56, 15, 57, 57, 15, 57, 51, 4,
+ 51, 2, -1, 15, 57, 56, 75, 2, 51, 51,
+ 15, 53, 55, 2, 15, 51, 51, 2, 53, 55,
+ 15, 51, 51, 53, 53, 51, 15, 53, 51, 2,
+ 15, 51, 55, 51, 51, 15, 56, 2, 56, 56,
+ -1, 3, 15, 51, 64, 89, -1, 51, 56, 51,
+ 15, 68, 56, -1, 56, 73, 58, 51, 66, -1,
+ -1, 51, 56, -1, 44, 45, 56, 51, 58, 73,
+ 51, -1, 56, 51, 58, 56, 51, 51, 56, 73,
+ 51, 56, 56, 58, 13, 56, -1, -1, 62, 60,
+ -1, 20, 73, 13, 5, 73, 16, 5, 18, -1,
+ -1, -1, 13, 32, 33, 13, -1, -1, -1, 20,
+ -1, -1, 20, 75, -1, -1, -1, -1, -1, 39,
+ 85, 32, 33, -1, 32, 33, 22, 23, 24, 25,
+ 26, 27, 28, 21, 22, 23, 24, 25, 26, 27,
+ 28, 13, -1, -1, -1, -1, 2, -1, 20, 21,
+ 22, 23, 24, 25, 26, 27, 28, -1, -1, 15,
+ -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, -1, -1, -1, -1, -1, 85,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, 13, -1, -1, 16, -1, 18,
+ -1, -1, 13, -1, -1, -1, -1, -1, -1, 20,
+ 21, 22, 23, 24, 25, 26, 27, 28, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 39, -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, -1, -1, -1};
+ -1, -1, -1, -1, -1, -1, -1};
QT_END_NAMESPACE
diff --git a/src/tools/qdoc/qmlparser/qqmljsgrammar_p.h b/src/tools/qdoc/qmlparser/qqmljsgrammar_p.h
index 34da969175..9ef4695d69 100644
--- a/src/tools/qdoc/qmlparser/qqmljsgrammar_p.h
+++ b/src/tools/qdoc/qmlparser/qqmljsgrammar_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtCore module of the Qt Toolkit.
+** This file is part of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -63,12 +63,12 @@ class QQmlJSGrammar
public:
enum VariousConstants {
EOF_SYMBOL = 0,
- REDUCE_HERE = 101,
- SHIFT_THERE = 100,
+ REDUCE_HERE = 104,
+ SHIFT_THERE = 103,
T_AND = 1,
T_AND_AND = 2,
T_AND_EQ = 3,
- T_AS = 91,
+ T_AS = 92,
T_AUTOMATIC_SEMICOLON = 62,
T_BREAK = 4,
T_CASE = 5,
@@ -76,6 +76,7 @@ public:
T_COLON = 7,
T_COMMA = 8,
T_COMMENT = 88,
+ T_COMPATIBILITY_SEMICOLON = 89,
T_CONST = 84,
T_CONTINUE = 9,
T_DEBUGGER = 85,
@@ -89,18 +90,19 @@ public:
T_EQ = 17,
T_EQ_EQ = 18,
T_EQ_EQ_EQ = 19,
- T_ERROR = 93,
+ T_ERROR = 96,
T_FALSE = 83,
- T_FEED_JS_EXPRESSION = 97,
- T_FEED_JS_PROGRAM = 99,
- T_FEED_JS_SOURCE_ELEMENT = 98,
- T_FEED_JS_STATEMENT = 96,
- T_FEED_UI_OBJECT_MEMBER = 95,
- T_FEED_UI_PROGRAM = 94,
+ T_FEED_JS_EXPRESSION = 100,
+ T_FEED_JS_PROGRAM = 102,
+ T_FEED_JS_SOURCE_ELEMENT = 101,
+ T_FEED_JS_STATEMENT = 99,
+ T_FEED_UI_OBJECT_MEMBER = 98,
+ T_FEED_UI_PROGRAM = 97,
T_FINALLY = 20,
T_FOR = 21,
T_FUNCTION = 22,
T_GE = 23,
+ T_GET = 94,
T_GT = 24,
T_GT_GT = 25,
T_GT_GT_EQ = 26,
@@ -108,7 +110,7 @@ public:
T_GT_GT_GT_EQ = 28,
T_IDENTIFIER = 29,
T_IF = 30,
- T_IMPORT = 90,
+ T_IMPORT = 91,
T_IN = 31,
T_INSTANCEOF = 32,
T_LBRACE = 33,
@@ -128,7 +130,7 @@ public:
T_NOT_EQ_EQ = 46,
T_NULL = 81,
T_NUMERIC_LITERAL = 47,
- T_ON = 92,
+ T_ON = 93,
T_OR = 48,
T_OR_EQ = 49,
T_OR_OR = 50,
@@ -136,7 +138,7 @@ public:
T_PLUS_EQ = 52,
T_PLUS_PLUS = 53,
T_PROPERTY = 66,
- T_PUBLIC = 89,
+ T_PUBLIC = 90,
T_QUESTION = 54,
T_RBRACE = 55,
T_RBRACKET = 56,
@@ -147,6 +149,7 @@ public:
T_RETURN = 59,
T_RPAREN = 60,
T_SEMICOLON = 61,
+ T_SET = 95,
T_SIGNAL = 67,
T_STAR = 63,
T_STAR_EQ = 64,
@@ -165,15 +168,15 @@ public:
T_XOR = 79,
T_XOR_EQ = 80,
- ACCEPT_STATE = 644,
- RULE_COUNT = 349,
- STATE_COUNT = 645,
- TERMINAL_COUNT = 102,
- NON_TERMINAL_COUNT = 107,
+ ACCEPT_STATE = 655,
+ RULE_COUNT = 351,
+ STATE_COUNT = 656,
+ TERMINAL_COUNT = 105,
+ NON_TERMINAL_COUNT = 108,
- GOTO_INDEX_OFFSET = 645,
- GOTO_INFO_OFFSET = 2807,
- GOTO_CHECK_OFFSET = 2807
+ GOTO_INDEX_OFFSET = 656,
+ GOTO_INFO_OFFSET = 2970,
+ GOTO_CHECK_OFFSET = 2970
};
static const char *const spell [];
diff --git a/src/tools/qdoc/qmlparser/qqmljskeywords_p.h b/src/tools/qdoc/qmlparser/qqmljskeywords_p.h
index 4bb39d077a..7fcf001303 100644
--- a/src/tools/qdoc/qmlparser/qqmljskeywords_p.h
+++ b/src/tools/qdoc/qmlparser/qqmljskeywords_p.h
@@ -53,10 +53,16 @@
// We mean it.
//
+#include "qqmljslexer_p.h"
+
+QT_QML_BEGIN_NAMESPACE
+
+namespace QQmlJS {
+
static inline int classify2(const QChar *s, bool qmlMode) {
if (s[0].unicode() == 'a') {
if (s[1].unicode() == 's') {
- return qmlMode ? Lexer::T_AS : Lexer::T_RESERVED_WORD;
+ return qmlMode ? Lexer::T_AS : Lexer::T_IDENTIFIER;
}
}
else if (s[0].unicode() == 'd') {
@@ -74,13 +80,13 @@ static inline int classify2(const QChar *s, bool qmlMode) {
}
else if (qmlMode && s[0].unicode() == 'o') {
if (s[1].unicode() == 'n') {
- return Lexer::T_ON;
+ return qmlMode ? Lexer::T_ON : Lexer::T_IDENTIFIER;
}
}
return Lexer::T_IDENTIFIER;
}
-static inline int classify3(const QChar *s, bool /*qmlMode*/) {
+static inline int classify3(const QChar *s, bool qmlMode) {
if (s[0].unicode() == 'f') {
if (s[1].unicode() == 'o') {
if (s[2].unicode() == 'r') {
@@ -88,10 +94,17 @@ static inline int classify3(const QChar *s, bool /*qmlMode*/) {
}
}
}
+ else if (s[0].unicode() == 'g') {
+ if (s[1].unicode() == 'e') {
+ if (s[2].unicode() == 't') {
+ return Lexer::T_GET;
+ }
+ }
+ }
else if (s[0].unicode() == 'i') {
if (s[1].unicode() == 'n') {
if (s[2].unicode() == 't') {
- return Lexer::T_INT;
+ return qmlMode ? int(Lexer::T_INT) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -102,6 +115,13 @@ static inline int classify3(const QChar *s, bool /*qmlMode*/) {
}
}
}
+ else if (s[0].unicode() == 's') {
+ if (s[1].unicode() == 'e') {
+ if (s[2].unicode() == 't') {
+ return Lexer::T_SET;
+ }
+ }
+ }
else if (s[0].unicode() == 't') {
if (s[1].unicode() == 'r') {
if (s[2].unicode() == 'y') {
@@ -119,12 +139,12 @@ static inline int classify3(const QChar *s, bool /*qmlMode*/) {
return Lexer::T_IDENTIFIER;
}
-static inline int classify4(const QChar *s, bool /*qmlMode*/) {
+static inline int classify4(const QChar *s, bool qmlMode) {
if (s[0].unicode() == 'b') {
if (s[1].unicode() == 'y') {
if (s[2].unicode() == 't') {
if (s[3].unicode() == 'e') {
- return Lexer::T_BYTE;
+ return qmlMode ? int(Lexer::T_BYTE) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -140,7 +160,7 @@ static inline int classify4(const QChar *s, bool /*qmlMode*/) {
else if (s[1].unicode() == 'h') {
if (s[2].unicode() == 'a') {
if (s[3].unicode() == 'r') {
- return Lexer::T_CHAR;
+ return qmlMode ? int(Lexer::T_CHAR) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -165,7 +185,7 @@ static inline int classify4(const QChar *s, bool /*qmlMode*/) {
if (s[1].unicode() == 'o') {
if (s[2].unicode() == 't') {
if (s[3].unicode() == 'o') {
- return Lexer::T_GOTO;
+ return qmlMode ? int(Lexer::T_GOTO) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -174,7 +194,7 @@ static inline int classify4(const QChar *s, bool /*qmlMode*/) {
if (s[1].unicode() == 'o') {
if (s[2].unicode() == 'n') {
if (s[3].unicode() == 'g') {
- return Lexer::T_LONG;
+ return qmlMode ? int(Lexer::T_LONG) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -225,7 +245,7 @@ static inline int classify4(const QChar *s, bool /*qmlMode*/) {
return Lexer::T_IDENTIFIER;
}
-static inline int classify5(const QChar *s, bool /*qmlMode*/) {
+static inline int classify5(const QChar *s, bool qmlMode) {
if (s[0].unicode() == 'b') {
if (s[1].unicode() == 'r') {
if (s[2].unicode() == 'e') {
@@ -260,7 +280,7 @@ static inline int classify5(const QChar *s, bool /*qmlMode*/) {
if (s[2].unicode() == 'n') {
if (s[3].unicode() == 's') {
if (s[4].unicode() == 't') {
- return Lexer::T_CONST;
+ return qmlMode ? int(Lexer::T_CONST) : int(Lexer::T_RESERVED_WORD);
}
}
}
@@ -280,7 +300,7 @@ static inline int classify5(const QChar *s, bool /*qmlMode*/) {
if (s[2].unicode() == 'n') {
if (s[3].unicode() == 'a') {
if (s[4].unicode() == 'l') {
- return Lexer::T_FINAL;
+ return qmlMode ? int(Lexer::T_FINAL) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -289,7 +309,7 @@ static inline int classify5(const QChar *s, bool /*qmlMode*/) {
if (s[2].unicode() == 'o') {
if (s[3].unicode() == 'a') {
if (s[4].unicode() == 't') {
- return Lexer::T_FLOAT;
+ return qmlMode ? int(Lexer::T_FLOAT) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -300,7 +320,7 @@ static inline int classify5(const QChar *s, bool /*qmlMode*/) {
if (s[2].unicode() == 'o') {
if (s[3].unicode() == 'r') {
if (s[4].unicode() == 't') {
- return Lexer::T_SHORT;
+ return qmlMode ? int(Lexer::T_SHORT) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -309,7 +329,7 @@ static inline int classify5(const QChar *s, bool /*qmlMode*/) {
if (s[2].unicode() == 'p') {
if (s[3].unicode() == 'e') {
if (s[4].unicode() == 'r') {
- return Lexer::T_SUPER;
+ return qmlMode ? int(Lexer::T_SUPER) : int(Lexer::T_RESERVED_WORD);
}
}
}
@@ -358,7 +378,7 @@ static inline int classify6(const QChar *s, bool qmlMode) {
if (s[3].unicode() == 'b') {
if (s[4].unicode() == 'l') {
if (s[5].unicode() == 'e') {
- return Lexer::T_DOUBLE;
+ return qmlMode ? int(Lexer::T_DOUBLE) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -384,7 +404,7 @@ static inline int classify6(const QChar *s, bool qmlMode) {
if (s[3].unicode() == 'o') {
if (s[4].unicode() == 'r') {
if (s[5].unicode() == 't') {
- return qmlMode ? Lexer::T_IMPORT : Lexer::T_RESERVED_WORD;
+ return qmlMode ? int(Lexer::T_IMPORT) : int(Lexer::T_RESERVED_WORD);
}
}
}
@@ -397,7 +417,7 @@ static inline int classify6(const QChar *s, bool qmlMode) {
if (s[3].unicode() == 'i') {
if (s[4].unicode() == 'v') {
if (s[5].unicode() == 'e') {
- return Lexer::T_NATIVE;
+ return qmlMode ? int(Lexer::T_NATIVE) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -410,7 +430,7 @@ static inline int classify6(const QChar *s, bool qmlMode) {
if (s[3].unicode() == 'l') {
if (s[4].unicode() == 'i') {
if (s[5].unicode() == 'c') {
- return qmlMode ? Lexer::T_PUBLIC : Lexer::T_RESERVED_WORD;
+ return qmlMode ? Lexer::T_PUBLIC : Lexer::T_IDENTIFIER;
}
}
}
@@ -447,7 +467,7 @@ static inline int classify6(const QChar *s, bool qmlMode) {
if (s[3].unicode() == 't') {
if (s[4].unicode() == 'i') {
if (s[5].unicode() == 'c') {
- return Lexer::T_STATIC;
+ return qmlMode ? int(Lexer::T_STATIC) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -471,7 +491,7 @@ static inline int classify6(const QChar *s, bool qmlMode) {
if (s[3].unicode() == 'o') {
if (s[4].unicode() == 'w') {
if (s[5].unicode() == 's') {
- return Lexer::T_THROWS;
+ return qmlMode ? int(Lexer::T_THROWS) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -492,7 +512,7 @@ static inline int classify6(const QChar *s, bool qmlMode) {
return Lexer::T_IDENTIFIER;
}
-static inline int classify7(const QChar *s, bool /*qmlMode*/) {
+static inline int classify7(const QChar *s, bool qmlMode) {
if (s[0].unicode() == 'b') {
if (s[1].unicode() == 'o') {
if (s[2].unicode() == 'o') {
@@ -500,7 +520,7 @@ static inline int classify7(const QChar *s, bool /*qmlMode*/) {
if (s[4].unicode() == 'e') {
if (s[5].unicode() == 'a') {
if (s[6].unicode() == 'n') {
- return Lexer::T_BOOLEAN;
+ return qmlMode ? int(Lexer::T_BOOLEAN) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -560,7 +580,7 @@ static inline int classify7(const QChar *s, bool /*qmlMode*/) {
if (s[4].unicode() == 'a') {
if (s[5].unicode() == 'g') {
if (s[6].unicode() == 'e') {
- return Lexer::T_PACKAGE;
+ return qmlMode ? int(Lexer::T_PACKAGE) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -573,7 +593,7 @@ static inline int classify7(const QChar *s, bool /*qmlMode*/) {
if (s[4].unicode() == 'a') {
if (s[5].unicode() == 't') {
if (s[6].unicode() == 'e') {
- return Lexer::T_PRIVATE;
+ return qmlMode ? int(Lexer::T_PRIVATE) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -593,7 +613,7 @@ static inline int classify8(const QChar *s, bool qmlMode) {
if (s[5].unicode() == 'a') {
if (s[6].unicode() == 'c') {
if (s[7].unicode() == 't') {
- return Lexer::T_ABSTRACT;
+ return qmlMode ? int(Lexer::T_ABSTRACT) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -661,7 +681,7 @@ static inline int classify8(const QChar *s, bool qmlMode) {
if (s[5].unicode() == 'r') {
if (s[6].unicode() == 't') {
if (s[7].unicode() == 'y') {
- return Lexer::T_PROPERTY;
+ return qmlMode ? Lexer::T_PROPERTY : Lexer::T_IDENTIFIER;
}
}
}
@@ -695,7 +715,7 @@ static inline int classify8(const QChar *s, bool qmlMode) {
if (s[5].unicode() == 'i') {
if (s[6].unicode() == 'l') {
if (s[7].unicode() == 'e') {
- return Lexer::T_VOLATILE;
+ return qmlMode ? int(Lexer::T_VOLATILE) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -707,7 +727,7 @@ static inline int classify8(const QChar *s, bool qmlMode) {
return Lexer::T_IDENTIFIER;
}
-static inline int classify9(const QChar *s, bool /*qmlMode*/) {
+static inline int classify9(const QChar *s, bool qmlMode) {
if (s[0].unicode() == 'i') {
if (s[1].unicode() == 'n') {
if (s[2].unicode() == 't') {
@@ -717,7 +737,7 @@ static inline int classify9(const QChar *s, bool /*qmlMode*/) {
if (s[6].unicode() == 'a') {
if (s[7].unicode() == 'c') {
if (s[8].unicode() == 'e') {
- return Lexer::T_INTERFACE;
+ return qmlMode ? int(Lexer::T_INTERFACE) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -736,7 +756,7 @@ static inline int classify9(const QChar *s, bool /*qmlMode*/) {
if (s[6].unicode() == 't') {
if (s[7].unicode() == 'e') {
if (s[8].unicode() == 'd') {
- return Lexer::T_PROTECTED;
+ return qmlMode ? int(Lexer::T_PROTECTED) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -755,7 +775,7 @@ static inline int classify9(const QChar *s, bool /*qmlMode*/) {
if (s[6].unicode() == 'e') {
if (s[7].unicode() == 'n') {
if (s[8].unicode() == 't') {
- return Lexer::T_TRANSIENT;
+ return qmlMode ? int(Lexer::T_TRANSIENT) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -768,7 +788,7 @@ static inline int classify9(const QChar *s, bool /*qmlMode*/) {
return Lexer::T_IDENTIFIER;
}
-static inline int classify10(const QChar *s, bool /*qmlMode*/) {
+static inline int classify10(const QChar *s, bool qmlMode) {
if (s[0].unicode() == 'i') {
if (s[1].unicode() == 'm') {
if (s[2].unicode() == 'p') {
@@ -779,7 +799,7 @@ static inline int classify10(const QChar *s, bool /*qmlMode*/) {
if (s[7].unicode() == 'n') {
if (s[8].unicode() == 't') {
if (s[9].unicode() == 's') {
- return Lexer::T_IMPLEMENTS;
+ return qmlMode ? int(Lexer::T_IMPLEMENTS) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -812,7 +832,7 @@ static inline int classify10(const QChar *s, bool /*qmlMode*/) {
return Lexer::T_IDENTIFIER;
}
-static inline int classify12(const QChar *s, bool /*qmlMode*/) {
+static inline int classify12(const QChar *s, bool qmlMode) {
if (s[0].unicode() == 's') {
if (s[1].unicode() == 'y') {
if (s[2].unicode() == 'n') {
@@ -825,7 +845,7 @@ static inline int classify12(const QChar *s, bool /*qmlMode*/) {
if (s[9].unicode() == 'z') {
if (s[10].unicode() == 'e') {
if (s[11].unicode() == 'd') {
- return Lexer::T_SYNCHRONIZED;
+ return qmlMode ? int(Lexer::T_SYNCHRONIZED) : int(Lexer::T_IDENTIFIER);
}
}
}
@@ -857,4 +877,8 @@ int Lexer::classify(const QChar *s, int n, bool qmlMode) {
} // switch
}
+} // namespace QQmlJS
+
+QT_QML_END_NAMESPACE
+
#endif // QQMLJSKEYWORDS_P_H
diff --git a/src/tools/qdoc/qmlparser/qqmljslexer.cpp b/src/tools/qdoc/qmlparser/qqmljslexer.cpp
index e84629095b..edd85ec878 100644
--- a/src/tools/qdoc/qmlparser/qqmljslexer.cpp
+++ b/src/tools/qdoc/qmlparser/qqmljslexer.cpp
@@ -42,15 +42,11 @@
#include "qqmljslexer_p.h"
#include "qqmljsengine_p.h"
#include "qqmljsmemorypool_p.h"
+#include "qqmljskeywords_p.h"
-#ifdef QT_BOOTSTRAPPED
-#define tr(x, y) QString(QLatin1String(y))
-#else
-#include <qcoreapplication.h>
-#define tr(x, y) QCoreApplication::translate(x, y)
-#endif
-#include <qvarlengtharray.h>
-#include <qdebug.h>
+#include <QtCore/qcoreapplication.h>
+#include <QtCore/qvarlengtharray.h>
+#include <QtCore/qdebug.h>
QT_BEGIN_NAMESPACE
Q_CORE_EXPORT double qstrtod(const char *s00, char const **se, bool *ok);
@@ -58,7 +54,7 @@ QT_END_NAMESPACE
using namespace QQmlJS;
-static inline int regExpFlagFromChar(QChar ch)
+static int regExpFlagFromChar(const QChar &ch)
{
switch (ch.unicode()) {
case 'g': return Lexer::RegExp_Global;
@@ -141,6 +137,7 @@ void Lexer::setCode(const QString &code, int lineno, bool qmlMode)
_tokenSpell = QStringRef();
_codePtr = code.unicode();
+ _endPtr = _codePtr + code.length();
_lastLinePtr = _codePtr;
_tokenLinePtr = _codePtr;
_tokenStartPtr = _codePtr;
@@ -171,14 +168,63 @@ void Lexer::setCode(const QString &code, int lineno, bool qmlMode)
void Lexer::scanChar()
{
+ unsigned sequenceLength = isLineTerminatorSequence();
_char = *_codePtr++;
+ if (sequenceLength == 2)
+ _char = *_codePtr++;
- if (_char == QLatin1Char('\n')) {
- _lastLinePtr = _codePtr; // points to the first character after the newline
+ if (unsigned sequenceLength = isLineTerminatorSequence()) {
+ _lastLinePtr = _codePtr + sequenceLength - 1; // points to the first character after the newline
++_currentLineNumber;
}
}
+namespace {
+inline bool isBinop(int tok)
+{
+ switch (tok) {
+ case Lexer::T_AND:
+ case Lexer::T_AND_AND:
+ case Lexer::T_AND_EQ:
+ case Lexer::T_DIVIDE_:
+ case Lexer::T_DIVIDE_EQ:
+ case Lexer::T_EQ:
+ case Lexer::T_EQ_EQ:
+ case Lexer::T_EQ_EQ_EQ:
+ case Lexer::T_GE:
+ case Lexer::T_GT:
+ case Lexer::T_GT_GT:
+ case Lexer::T_GT_GT_EQ:
+ case Lexer::T_GT_GT_GT:
+ case Lexer::T_GT_GT_GT_EQ:
+ case Lexer::T_LE:
+ case Lexer::T_LT:
+ case Lexer::T_LT_LT:
+ case Lexer::T_LT_LT_EQ:
+ case Lexer::T_MINUS:
+ case Lexer::T_MINUS_EQ:
+ case Lexer::T_NOT_EQ:
+ case Lexer::T_NOT_EQ_EQ:
+ case Lexer::T_OR:
+ case Lexer::T_OR_EQ:
+ case Lexer::T_OR_OR:
+ case Lexer::T_PLUS:
+ case Lexer::T_PLUS_EQ:
+ case Lexer::T_REMAINDER:
+ case Lexer::T_REMAINDER_EQ:
+ case Lexer::T_RETURN:
+ case Lexer::T_STAR:
+ case Lexer::T_STAR_EQ:
+ case Lexer::T_XOR:
+ case Lexer::T_XOR_EQ:
+ return true;
+
+ default:
+ return false;
+ }
+}
+} // anonymous namespace
+
int Lexer::lex()
{
const int previousTokenKind = _tokenKind;
@@ -195,9 +241,15 @@ int Lexer::lex()
switch (_tokenKind) {
case T_LBRACE:
case T_SEMICOLON:
+ case T_QUESTION:
case T_COLON:
+ case T_TILDE:
_delimited = true;
break;
+ default:
+ if (isBinop(_tokenKind))
+ _delimited = true;
+ break;
case T_IF:
case T_FOR:
@@ -277,6 +329,59 @@ QChar Lexer::decodeUnicodeEscapeCharacter(bool *ok)
return QChar();
}
+static inline bool isIdentifierStart(QChar ch)
+{
+ // fast path for ascii
+ if ((ch.unicode() >= 'a' && ch.unicode() <= 'z') ||
+ (ch.unicode() >= 'A' && ch.unicode() <= 'Z') ||
+ ch == '$' || ch == '_')
+ return true;
+
+ switch (ch.category()) {
+ case QChar::Number_Letter:
+ case QChar::Letter_Uppercase:
+ case QChar::Letter_Lowercase:
+ case QChar::Letter_Titlecase:
+ case QChar::Letter_Modifier:
+ case QChar::Letter_Other:
+ return true;
+ default:
+ break;
+ }
+ return false;
+}
+
+static bool isIdentifierPart(QChar ch)
+{
+ // fast path for ascii
+ if ((ch.unicode() >= 'a' && ch.unicode() <= 'z') ||
+ (ch.unicode() >= 'A' && ch.unicode() <= 'Z') ||
+ (ch.unicode() >= '0' && ch.unicode() <= '9') ||
+ ch == '$' || ch == '_' ||
+ ch.unicode() == 0x200c /* ZWNJ */ || ch.unicode() == 0x200d /* ZWJ */)
+ return true;
+
+ switch (ch.category()) {
+ case QChar::Mark_NonSpacing:
+ case QChar::Mark_SpacingCombining:
+
+ case QChar::Number_DecimalDigit:
+ case QChar::Number_Letter:
+
+ case QChar::Letter_Uppercase:
+ case QChar::Letter_Lowercase:
+ case QChar::Letter_Titlecase:
+ case QChar::Letter_Modifier:
+ case QChar::Letter_Other:
+
+ case QChar::Punctuation_Connector:
+ return true;
+ default:
+ break;
+ }
+ return false;
+}
+
int Lexer::scanToken()
{
if (_stackToken != -1) {
@@ -292,13 +397,13 @@ again:
_tokenLinePtr = _lastLinePtr;
while (_char.isSpace()) {
- if (_char == QLatin1Char('\n')) {
- _tokenLinePtr = _codePtr;
+ if (unsigned sequenceLength = isLineTerminatorSequence()) {
+ _tokenLinePtr = _codePtr + sequenceLength - 1;
if (_restrictedKeyword) {
// automatic semicolon insertion
_tokenLine = _currentLineNumber;
- _tokenStartPtr = _codePtr - 1; // ### TODO: insert it before the optional \r sequence.
+ _tokenStartPtr = _codePtr - 1;
return T_SEMICOLON;
} else {
_terminator = true;
@@ -312,7 +417,7 @@ again:
_tokenStartPtr = _codePtr - 1;
_tokenLine = _currentLineNumber;
- if (_char.isNull())
+ if (_codePtr > _endPtr)
return EOF_SYMBOL;
const QChar ch = _char;
@@ -397,7 +502,7 @@ again:
case '/':
if (_char == QLatin1Char('*')) {
scanChar();
- while (!_char.isNull()) {
+ while (_codePtr <= _endPtr) {
if (_char == QLatin1Char('*')) {
scanChar();
if (_char == QLatin1Char('/')) {
@@ -415,7 +520,7 @@ again:
}
}
} else if (_char == QLatin1Char('/')) {
- while (!_char.isNull() && _char != QLatin1Char('\n')) {
+ while (_codePtr <= _endPtr && !isLineTerminator()) {
scanChar();
}
if (_engine) {
@@ -469,7 +574,7 @@ again:
if (end - begin != chars.size() - 1) {
_errorCode = IllegalExponentIndicator;
- _errorMessage = tr("QQmlParser", "Illegal syntax for exponential number");
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Illegal syntax for exponential number");
return T_ERROR;
}
@@ -557,8 +662,14 @@ again:
const QChar *startCode = _codePtr;
if (_engine) {
- while (!_char.isNull()) {
- if (_char == QLatin1Char('\n') || _char == QLatin1Char('\\')) {
+ while (_codePtr <= _endPtr) {
+ if (isLineTerminator()) {
+ if (qmlMode())
+ break;
+ _errorCode = IllegalCharacter;
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Stray newline in string literal");
+ return T_ERROR;
+ } else if (_char == QLatin1Char('\\')) {
break;
} else if (_char == quote) {
_tokenSpell = _engine->midRef(startCode - _code.unicode() - 1, _codePtr - startCode);
@@ -573,13 +684,15 @@ again:
_validTokenText = true;
_tokenText.resize(0);
startCode--;
- while (startCode != _codePtr - 1)
+ while (startCode != _codePtr - 1)
_tokenText += *startCode++;
- while (! _char.isNull()) {
- if (_char == QLatin1Char('\n')) {
+ while (_codePtr <= _endPtr) {
+ if (unsigned sequenceLength = isLineTerminatorSequence()) {
multilineStringLiteral = true;
_tokenText += _char;
+ if (sequenceLength == 2)
+ _tokenText += *_codePtr;
scanChar();
} else if (_char == quote) {
scanChar();
@@ -598,13 +711,15 @@ again:
// unicode escape sequence
case 'u':
u = decodeUnicodeEscapeCharacter(&ok);
- if (! ok)
- u = _char;
+ if (! ok) {
+ _errorCode = IllegalUnicodeEscapeSequence;
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Illegal unicode escape sequence");
+ return T_ERROR;
+ }
break;
// hex escape sequence
case 'x':
- case 'X':
if (isHexDigit(_codePtr[0]) && isHexDigit(_codePtr[1])) {
scanChar();
@@ -632,33 +747,43 @@ again:
case 'v': u = QLatin1Char('\v'); scanChar(); break;
case '0':
- if (! _codePtr[1].isDigit()) {
+ if (! _codePtr->isDigit()) {
scanChar();
u = QLatin1Char('\0');
- } else {
- // ### parse deprecated octal escape sequence ?
- u = _char;
+ break;
}
- break;
+ // fall through
+ case '1':
+ case '2':
+ case '3':
+ case '4':
+ case '5':
+ case '6':
+ case '7':
+ case '8':
+ case '9':
+ _errorCode = IllegalEscapeSequence;
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Octal escape sequences are not allowed");
+ return T_ERROR;
case '\r':
- while (_char == QLatin1Char('\r'))
- scanChar();
-
- if (_char == QLatin1Char('\n')) {
- u = _char;
- scanChar();
- } else {
+ if (isLineTerminatorSequence() == 2) {
+ _tokenText += QLatin1Char('\r');
u = QLatin1Char('\n');
+ } else {
+ u = QLatin1Char('\r');
}
-
+ scanChar();
break;
case '\n':
+ case 0x2028u:
+ case 0x2029u:
u = _char;
scanChar();
break;
+
default:
// non escape character
u = _char;
@@ -673,32 +798,43 @@ again:
}
_errorCode = UnclosedStringLiteral;
- _errorMessage = tr("QQmlParser", "Unclosed string at end of line");
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Unclosed string at end of line");
return T_ERROR;
}
-
- default:
- if (ch.isLetter() || ch == QLatin1Char('$') || ch == QLatin1Char('_') || (ch == QLatin1Char('\\') && _char == QLatin1Char('u'))) {
- bool identifierWithEscapeChars = false;
- if (ch == QLatin1Char('\\')) {
- identifierWithEscapeChars = true;
+ case '0':
+ case '1':
+ case '2':
+ case '3':
+ case '4':
+ case '5':
+ case '6':
+ case '7':
+ case '8':
+ case '9':
+ return scanNumber(ch);
+
+ default: {
+ QChar c = ch;
+ bool identifierWithEscapeChars = false;
+ if (c == QLatin1Char('\\') && _char == QLatin1Char('u')) {
+ identifierWithEscapeChars = true;
+ bool ok = false;
+ c = decodeUnicodeEscapeCharacter(&ok);
+ if (! ok) {
+ _errorCode = IllegalUnicodeEscapeSequence;
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Illegal unicode escape sequence");
+ return T_ERROR;
+ }
+ }
+ if (isIdentifierStart(c)) {
+ if (identifierWithEscapeChars) {
_tokenText.resize(0);
- bool ok = false;
- _tokenText += decodeUnicodeEscapeCharacter(&ok);
+ _tokenText += c;
_validTokenText = true;
- if (! ok) {
- _errorCode = IllegalUnicodeEscapeSequence;
- _errorMessage = tr("QQmlParser", "Illegal unicode escape sequence");
- return T_ERROR;
- }
}
while (true) {
- if (_char.isLetterOrNumber() || _char == QLatin1Char('$') || _char == QLatin1Char('_')) {
- if (identifierWithEscapeChars)
- _tokenText += _char;
-
- scanChar();
- } else if (_char == QLatin1Char('\\') && _codePtr[0] == QLatin1Char('u')) {
+ c = _char;
+ if (_char == QLatin1Char('\\') && _codePtr[0] == QLatin1Char('u')) {
if (! identifierWithEscapeChars) {
identifierWithEscapeChars = true;
_tokenText.resize(0);
@@ -708,142 +844,175 @@ again:
scanChar(); // skip '\\'
bool ok = false;
- _tokenText += decodeUnicodeEscapeCharacter(&ok);
+ c = decodeUnicodeEscapeCharacter(&ok);
if (! ok) {
_errorCode = IllegalUnicodeEscapeSequence;
- _errorMessage = tr("QQmlParser", "Illegal unicode escape sequence");
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Illegal unicode escape sequence");
return T_ERROR;
}
- } else {
- _tokenLength = _codePtr - _tokenStartPtr - 1;
+ if (isIdentifierPart(c))
+ _tokenText += c;
+ continue;
+ } else if (isIdentifierPart(c)) {
+ if (identifierWithEscapeChars)
+ _tokenText += c;
+
+ scanChar();
+ continue;
+ }
- int kind = T_IDENTIFIER;
+ _tokenLength = _codePtr - _tokenStartPtr - 1;
- if (! identifierWithEscapeChars)
- kind = classify(_tokenStartPtr, _tokenLength, _qmlMode);
+ int kind = T_IDENTIFIER;
- if (_engine) {
- if (kind == T_IDENTIFIER && identifierWithEscapeChars)
- _tokenSpell = _engine->newStringRef(_tokenText);
- else
- _tokenSpell = _engine->midRef(_tokenStartPtr - _code.unicode(), _tokenLength);
- }
+ if (! identifierWithEscapeChars)
+ kind = classify(_tokenStartPtr, _tokenLength, _qmlMode);
- return kind;
+ if (_engine) {
+ if (kind == T_IDENTIFIER && identifierWithEscapeChars)
+ _tokenSpell = _engine->newStringRef(_tokenText);
+ else
+ _tokenSpell = _engine->midRef(_tokenStartPtr - _code.unicode(), _tokenLength);
}
+
+ return kind;
}
- } else if (ch.isDigit()) {
- if (ch != QLatin1Char('0')) {
- double integer = ch.unicode() - '0';
-
- QChar n = _char;
- const QChar *code = _codePtr;
- while (n.isDigit()) {
- integer = integer * 10 + (n.unicode() - '0');
- n = *code++;
- }
+ }
+ }
- if (n != QLatin1Char('.') && n != QLatin1Char('e') && n != QLatin1Char('E')) {
- if (code != _codePtr) {
- _codePtr = code - 1;
- scanChar();
- }
- _tokenValue = integer;
- return T_NUMERIC_LITERAL;
- }
+ break;
+ }
+
+ return T_ERROR;
+}
+
+int Lexer::scanNumber(QChar ch)
+{
+ if (ch != QLatin1Char('0')) {
+ QByteArray buf;
+ buf.reserve(64);
+ buf += ch.toLatin1();
+
+ QChar n = _char;
+ const QChar *code = _codePtr;
+ while (n.isDigit()) {
+ buf += n.toLatin1();
+ n = *code++;
+ }
+
+ if (n != QLatin1Char('.') && n != QLatin1Char('e') && n != QLatin1Char('E')) {
+ if (code != _codePtr) {
+ _codePtr = code - 1;
+ scanChar();
}
+ buf.append('\0');
+ _tokenValue = strtod(buf.constData(), 0);
+ return T_NUMERIC_LITERAL;
+ }
+ } else if (_char.isDigit() && !qmlMode()) {
+ _errorCode = IllegalCharacter;
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Decimal numbers can't start with '0'");
+ return T_ERROR;
+ }
- QVarLengthArray<char,32> chars;
- chars.append(ch.unicode());
+ QVarLengthArray<char,32> chars;
+ chars.append(ch.unicode());
- if (ch == QLatin1Char('0') && (_char == QLatin1Char('x') || _char == QLatin1Char('X'))) {
- // parse hex integer literal
+ if (ch == QLatin1Char('0') && (_char == QLatin1Char('x') || _char == QLatin1Char('X'))) {
+ ch = _char; // remember the x or X to use it in the error message below.
- chars.append(_char.unicode());
- scanChar(); // consume `x'
+ // parse hex integer literal
+ chars.append(_char.unicode());
+ scanChar(); // consume `x'
- while (isHexDigit(_char)) {
- chars.append(_char.unicode());
- scanChar();
- }
+ while (isHexDigit(_char)) {
+ chars.append(_char.unicode());
+ scanChar();
+ }
- _tokenValue = integerFromString(chars.constData(), chars.size(), 16);
- return T_NUMERIC_LITERAL;
- }
+ if (chars.size() < 3) {
+ _errorCode = IllegalHexNumber;
+ _errorMessage = QCoreApplication::translate("QQmlParser", "At least one hexadecimal digit is required after '0%1'").arg(ch);
+ return T_ERROR;
+ }
- // decimal integer literal
- while (_char.isDigit()) {
- chars.append(_char.unicode());
- scanChar(); // consume the digit
- }
+ _tokenValue = integerFromString(chars.constData(), chars.size(), 16);
+ return T_NUMERIC_LITERAL;
+ }
- if (_char == QLatin1Char('.')) {
- chars.append(_char.unicode());
- scanChar(); // consume `.'
+ // decimal integer literal
+ while (_char.isDigit()) {
+ chars.append(_char.unicode());
+ scanChar(); // consume the digit
+ }
- while (_char.isDigit()) {
- chars.append(_char.unicode());
- scanChar();
- }
+ if (_char == QLatin1Char('.')) {
+ chars.append(_char.unicode());
+ scanChar(); // consume `.'
- if (_char == QLatin1Char('e') || _char == QLatin1Char('E')) {
- if (_codePtr[0].isDigit() || ((_codePtr[0] == QLatin1Char('+') || _codePtr[0] == QLatin1Char('-')) &&
- _codePtr[1].isDigit())) {
+ while (_char.isDigit()) {
+ chars.append(_char.unicode());
+ scanChar();
+ }
- chars.append(_char.unicode());
- scanChar(); // consume `e'
+ if (_char == QLatin1Char('e') || _char == QLatin1Char('E')) {
+ if (_codePtr[0].isDigit() || ((_codePtr[0] == QLatin1Char('+') || _codePtr[0] == QLatin1Char('-')) &&
+ _codePtr[1].isDigit())) {
- if (_char == QLatin1Char('+') || _char == QLatin1Char('-')) {
- chars.append(_char.unicode());
- scanChar(); // consume the sign
- }
+ chars.append(_char.unicode());
+ scanChar(); // consume `e'
- while (_char.isDigit()) {
- chars.append(_char.unicode());
- scanChar();
- }
- }
+ if (_char == QLatin1Char('+') || _char == QLatin1Char('-')) {
+ chars.append(_char.unicode());
+ scanChar(); // consume the sign
}
- } else if (_char == QLatin1Char('e') || _char == QLatin1Char('E')) {
- if (_codePtr[0].isDigit() || ((_codePtr[0] == QLatin1Char('+') || _codePtr[0] == QLatin1Char('-')) &&
- _codePtr[1].isDigit())) {
+ while (_char.isDigit()) {
chars.append(_char.unicode());
- scanChar(); // consume `e'
+ scanChar();
+ }
+ }
+ }
+ } else if (_char == QLatin1Char('e') || _char == QLatin1Char('E')) {
+ if (_codePtr[0].isDigit() || ((_codePtr[0] == QLatin1Char('+') || _codePtr[0] == QLatin1Char('-')) &&
+ _codePtr[1].isDigit())) {
- if (_char == QLatin1Char('+') || _char == QLatin1Char('-')) {
- chars.append(_char.unicode());
- scanChar(); // consume the sign
- }
+ chars.append(_char.unicode());
+ scanChar(); // consume `e'
- while (_char.isDigit()) {
- chars.append(_char.unicode());
- scanChar();
- }
- }
+ if (_char == QLatin1Char('+') || _char == QLatin1Char('-')) {
+ chars.append(_char.unicode());
+ scanChar(); // consume the sign
}
- chars.append('\0');
+ while (_char.isDigit()) {
+ chars.append(_char.unicode());
+ scanChar();
+ }
+ }
+ }
- const char *begin = chars.constData();
- const char *end = 0;
- bool ok = false;
+ if (chars.length() == 1) {
+ // if we ended up with a single digit, then it was a '0'
+ _tokenValue = 0;
+ return T_NUMERIC_LITERAL;
+ }
- _tokenValue = qstrtod(begin, &end, &ok);
+ chars.append('\0');
- if (end - begin != chars.size() - 1) {
- _errorCode = IllegalExponentIndicator;
- _errorMessage = tr("QQmlParser", "Illegal syntax for exponential number");
- return T_ERROR;
- }
+ const char *begin = chars.constData();
+ const char *end = 0;
+ bool ok = false;
- return T_NUMERIC_LITERAL;
- }
+ _tokenValue = qstrtod(begin, &end, &ok);
- break;
+ if (end - begin != chars.size() - 1) {
+ _errorCode = IllegalExponentIndicator;
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Illegal syntax for exponential number");
+ return T_ERROR;
}
- return T_ERROR;
+ return T_NUMERIC_LITERAL;
}
bool Lexer::scanRegExp(RegExpBodyPrefix prefix)
@@ -857,11 +1026,6 @@ bool Lexer::scanRegExp(RegExpBodyPrefix prefix)
while (true) {
switch (_char.unicode()) {
- case 0: // eof
- case '\n': case '\r': // line terminator
- _errorMessage = tr("QQmlParser", "Unterminated regular expression literal");
- return false;
-
case '/':
scanChar();
@@ -870,7 +1034,7 @@ bool Lexer::scanRegExp(RegExpBodyPrefix prefix)
while (isIdentLetter(_char)) {
int flag = regExpFlagFromChar(_char);
if (flag == 0) {
- _errorMessage = tr("QQmlParser", "Invalid regular expression flag '%0'")
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Invalid regular expression flag '%0'")
.arg(QChar(_char));
return false;
}
@@ -886,8 +1050,8 @@ bool Lexer::scanRegExp(RegExpBodyPrefix prefix)
_tokenText += _char;
scanChar();
- if (_char.isNull() || isLineTerminator()) {
- _errorMessage = tr("QQmlParser", "Unterminated regular expression backslash sequence");
+ if (_codePtr > _endPtr || isLineTerminator()) {
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Unterminated regular expression backslash sequence");
return false;
}
@@ -900,7 +1064,7 @@ bool Lexer::scanRegExp(RegExpBodyPrefix prefix)
_tokenText += _char;
scanChar();
- while (! _char.isNull() && ! isLineTerminator()) {
+ while (_codePtr <= _endPtr && ! isLineTerminator()) {
if (_char == QLatin1Char(']'))
break;
else if (_char == QLatin1Char('\\')) {
@@ -908,8 +1072,8 @@ bool Lexer::scanRegExp(RegExpBodyPrefix prefix)
_tokenText += _char;
scanChar();
- if (_char.isNull() || isLineTerminator()) {
- _errorMessage = tr("QQmlParser", "Unterminated regular expression backslash sequence");
+ if (_codePtr > _endPtr || isLineTerminator()) {
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Unterminated regular expression backslash sequence");
return false;
}
@@ -922,7 +1086,7 @@ bool Lexer::scanRegExp(RegExpBodyPrefix prefix)
}
if (_char != QLatin1Char(']')) {
- _errorMessage = tr("QQmlParser", "Unterminated regular expression class");
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Unterminated regular expression class");
return false;
}
@@ -931,8 +1095,13 @@ bool Lexer::scanRegExp(RegExpBodyPrefix prefix)
break;
default:
- _tokenText += _char;
- scanChar();
+ if (_codePtr > _endPtr || isLineTerminator()) {
+ _errorMessage = QCoreApplication::translate("QQmlParser", "Unterminated regular expression literal");
+ return false;
+ } else {
+ _tokenText += _char;
+ scanChar();
+ }
} // switch
} // while
@@ -941,7 +1110,28 @@ bool Lexer::scanRegExp(RegExpBodyPrefix prefix)
bool Lexer::isLineTerminator() const
{
- return (_char == QLatin1Char('\n') || _char == QLatin1Char('\r'));
+ const ushort unicode = _char.unicode();
+ return unicode == 0x000Au
+ || unicode == 0x000Du
+ || unicode == 0x2028u
+ || unicode == 0x2029u;
+}
+
+unsigned Lexer::isLineTerminatorSequence() const
+{
+ switch (_char.unicode()) {
+ case 0x000Au:
+ case 0x2028u:
+ case 0x2029u:
+ return 1;
+ case 0x000Du:
+ if (_codePtr->unicode() == 0x000Au)
+ return 2;
+ else
+ return 1;
+ default:
+ return 0;
+ }
}
bool Lexer::isIdentLetter(QChar ch)
@@ -975,31 +1165,6 @@ bool Lexer::isOctalDigit(ushort c)
return (c >= '0' && c <= '7');
}
-int Lexer::tokenKind() const
-{
- return _tokenKind;
-}
-
-int Lexer::tokenOffset() const
-{
- return _tokenStartPtr - _code.unicode();
-}
-
-int Lexer::tokenLength() const
-{
- return _tokenLength;
-}
-
-int Lexer::tokenStartLine() const
-{
- return _tokenLine;
-}
-
-int Lexer::tokenStartColumn() const
-{
- return _tokenStartPtr - _tokenLinePtr + 1;
-}
-
int Lexer::tokenEndLine() const
{
return _currentLineNumber;
@@ -1010,16 +1175,6 @@ int Lexer::tokenEndColumn() const
return _codePtr - _lastLinePtr;
}
-QStringRef Lexer::tokenSpell() const
-{
- return _tokenSpell;
-}
-
-double Lexer::tokenValue() const
-{
- return _tokenValue;
-}
-
QString Lexer::tokenText() const
{
if (_validTokenText)
@@ -1144,7 +1299,7 @@ bool Lexer::scanDirectives(Directives *directives)
//
// recognize the mandatory `as' followed by the module name
//
- if (! (lex() == T_RESERVED_WORD && tokenText() == QLatin1String("as")))
+ if (! (lex() == T_IDENTIFIER && tokenText() == QLatin1String("as")))
return false; // expected `as'
if (lex() != T_IDENTIFIER)
@@ -1167,5 +1322,3 @@ bool Lexer::scanDirectives(Directives *directives)
return true;
}
-
-#include "qqmljskeywords_p.h"
diff --git a/src/tools/qdoc/qmlparser/qqmljslexer_p.h b/src/tools/qdoc/qmlparser/qqmljslexer_p.h
index cb6ff6bcdf..e1b51da92b 100644
--- a/src/tools/qdoc/qmlparser/qqmljslexer_p.h
+++ b/src/tools/qdoc/qmlparser/qqmljslexer_p.h
@@ -55,8 +55,8 @@
#include "qqmljsglobal_p.h"
#include "qqmljsgrammar_p.h"
-#include "tr.h"
-#include <qstring.h>
+
+#include <QtCore/qstring.h>
QT_QML_BEGIN_NAMESPACE
@@ -88,8 +88,6 @@ public:
class QML_PARSER_EXPORT Lexer: public QQmlJSGrammar
{
- Q_DECLARE_TR_FUNCTIONS(QDoc::QQmlJS::Lexer)
-
public:
enum {
T_ABSTRACT = T_RESERVED_WORD,
@@ -107,7 +105,6 @@ public:
T_IMPLEMENTS = T_RESERVED_WORD,
T_INT = T_RESERVED_WORD,
T_INTERFACE = T_RESERVED_WORD,
- T_LET = T_RESERVED_WORD,
T_LONG = T_RESERVED_WORD,
T_NATIVE = T_RESERVED_WORD,
T_PACKAGE = T_RESERVED_WORD,
@@ -119,13 +116,13 @@ public:
T_SYNCHRONIZED = T_RESERVED_WORD,
T_THROWS = T_RESERVED_WORD,
T_TRANSIENT = T_RESERVED_WORD,
- T_VOLATILE = T_RESERVED_WORD,
- T_YIELD = T_RESERVED_WORD
+ T_VOLATILE = T_RESERVED_WORD
};
enum Error {
NoError,
IllegalCharacter,
+ IllegalHexNumber,
UnclosedStringLiteral,
IllegalEscapeSequence,
IllegalUnicodeEscapeSequence,
@@ -161,18 +158,18 @@ public:
int regExpFlags() const { return _patternFlags; }
QString regExpPattern() const { return _tokenText; }
- int tokenKind() const;
- int tokenOffset() const;
- int tokenLength() const;
+ int tokenKind() const { return _tokenKind; }
+ int tokenOffset() const { return _tokenStartPtr - _code.unicode(); }
+ int tokenLength() const { return _tokenLength; }
- int tokenStartLine() const;
- int tokenStartColumn() const;
+ int tokenStartLine() const { return _tokenLine; }
+ int tokenStartColumn() const { return _tokenStartPtr - _tokenLinePtr + 1; }
int tokenEndLine() const;
int tokenEndColumn() const;
- QStringRef tokenSpell() const;
- double tokenValue() const;
+ inline QStringRef tokenSpell() const { return _tokenSpell; }
+ double tokenValue() const { return _tokenValue; }
QString tokenText() const;
Error errorCode() const;
@@ -194,8 +191,10 @@ protected:
private:
inline void scanChar();
int scanToken();
+ int scanNumber(QChar ch);
bool isLineTerminator() const;
+ unsigned isLineTerminatorSequence() const;
static bool isIdentLetter(QChar c);
static bool isDecimalDigit(ushort c);
static bool isHexDigit(QChar c);
@@ -214,6 +213,7 @@ private:
QStringRef _tokenSpell;
const QChar *_codePtr;
+ const QChar *_endPtr;
const QChar *_lastLinePtr;
const QChar *_tokenLinePtr;
const QChar *_tokenStartPtr;
diff --git a/src/tools/qdoc/qmlparser/qqmljsmemorypool_p.h b/src/tools/qdoc/qmlparser/qqmljsmemorypool_p.h
index 541966fd15..820ae8ed71 100644
--- a/src/tools/qdoc/qmlparser/qqmljsmemorypool_p.h
+++ b/src/tools/qdoc/qmlparser/qqmljsmemorypool_p.h
@@ -60,7 +60,6 @@
#include <QtCore/qdebug.h>
#include <cstring>
-#include <stdlib.h>
QT_QML_BEGIN_NAMESPACE
diff --git a/src/tools/qdoc/qmlparser/qqmljsparser.cpp b/src/tools/qdoc/qmlparser/qqmljsparser.cpp
index b7f571aa62..a0fa7a4711 100644
--- a/src/tools/qdoc/qmlparser/qqmljsparser.cpp
+++ b/src/tools/qdoc/qmlparser/qqmljsparser.cpp
@@ -39,23 +39,31 @@
**
****************************************************************************/
-#include <qdebug.h>
-
-#include <string.h>
-
#include "qqmljsengine_p.h"
#include "qqmljslexer_p.h"
#include "qqmljsast_p.h"
#include "qqmljsmemorypool_p.h"
+#include <QtCore/qdebug.h>
+#include <QtCore/qcoreapplication.h>
+
+#include <string.h>
#include "qqmljsparser_p.h"
-#include <qvarlengtharray.h>
+#include <QtCore/qvarlengtharray.h>
+
+//
+// W A R N I N G
+// -------------
+//
+// This file is automatically generated from qqmljs.g.
+// Changes should be made to that file, not here. Any change to this file will
+// be lost!
//
-// This file is automatically generated from qmljs.g.
-// Changes will be lost.
+// To regenerate this file, run:
+// qlalr --no-debug --no-lines --qt qqmljs.g
//
using namespace QQmlJS;
@@ -84,6 +92,7 @@ Parser::Parser(Engine *engine):
state_stack(0),
location_stack(0),
string_stack(0),
+ program(0),
first_token(0),
last_token(0)
{
@@ -384,6 +393,7 @@ case 47: {
case 48: {
AST::UiParameterList *node = new (pool) AST::UiParameterList(sym(1).UiParameterList, stringRef(3), stringRef(4));
+ node->propertyTypeToken = loc(3);
node->commaToken = loc(2);
node->identifierToken = loc(4);
sym(1).Node = node;
@@ -527,49 +537,49 @@ case 65: {
sym(1).Node = new (pool) AST::UiSourceElement(sym(1).Node);
} break;
-case 71: {
+case 73: {
AST::ThisExpression *node = new (pool) AST::ThisExpression();
node->thisToken = loc(1);
sym(1).Node = node;
} break;
-case 72: {
+case 74: {
AST::IdentifierExpression *node = new (pool) AST::IdentifierExpression(stringRef(1));
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 73: {
+case 75: {
AST::NullExpression *node = new (pool) AST::NullExpression();
node->nullToken = loc(1);
sym(1).Node = node;
} break;
-case 74: {
+case 76: {
AST::TrueLiteral *node = new (pool) AST::TrueLiteral();
node->trueToken = loc(1);
sym(1).Node = node;
} break;
-case 75: {
+case 77: {
AST::FalseLiteral *node = new (pool) AST::FalseLiteral();
node->falseToken = loc(1);
sym(1).Node = node;
} break;
-case 76: {
+case 78: {
AST::NumericLiteral *node = new (pool) AST::NumericLiteral(sym(1).dval);
node->literalToken = loc(1);
sym(1).Node = node;
} break;
-case 77:
-case 78: {
+case 79:
+case 80: {
AST::StringLiteral *node = new (pool) AST::StringLiteral(stringRef(1));
node->literalToken = loc(1);
sym(1).Node = node;
} break;
-case 79: {
+case 81: {
bool rx = lexer->scanRegExp(Lexer::NoPrefix);
if (!rx) {
diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, location(lexer), lexer->errorMessage()));
@@ -585,7 +595,7 @@ case 79: {
sym(1).Node = node;
} break;
-case 80: {
+case 82: {
bool rx = lexer->scanRegExp(Lexer::EqualPrefix);
if (!rx) {
diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, location(lexer), lexer->errorMessage()));
@@ -601,28 +611,28 @@ case 80: {
sym(1).Node = node;
} break;
-case 81: {
+case 83: {
AST::ArrayLiteral *node = new (pool) AST::ArrayLiteral((AST::Elision *) 0);
node->lbracketToken = loc(1);
node->rbracketToken = loc(2);
sym(1).Node = node;
} break;
-case 82: {
+case 84: {
AST::ArrayLiteral *node = new (pool) AST::ArrayLiteral(sym(2).Elision->finish());
node->lbracketToken = loc(1);
node->rbracketToken = loc(3);
sym(1).Node = node;
} break;
-case 83: {
+case 85: {
AST::ArrayLiteral *node = new (pool) AST::ArrayLiteral(sym(2).ElementList->finish ());
node->lbracketToken = loc(1);
node->rbracketToken = loc(3);
sym(1).Node = node;
} break;
-case 84: {
+case 86: {
AST::ArrayLiteral *node = new (pool) AST::ArrayLiteral(sym(2).ElementList->finish (),
(AST::Elision *) 0);
node->lbracketToken = loc(1);
@@ -631,7 +641,7 @@ case 84: {
sym(1).Node = node;
} break;
-case 85: {
+case 87: {
AST::ArrayLiteral *node = new (pool) AST::ArrayLiteral(sym(2).ElementList->finish (),
sym(4).Elision->finish());
node->lbracketToken = loc(1);
@@ -640,11 +650,11 @@ case 85: {
sym(1).Node = node;
} break;
-case 86: {
+case 88: {
AST::ObjectLiteral *node = 0;
if (sym(2).Node)
node = new (pool) AST::ObjectLiteral(
- sym(2).PropertyNameAndValueList->finish ());
+ sym(2).PropertyAssignmentList->finish ());
else
node = new (pool) AST::ObjectLiteral();
node->lbraceToken = loc(1);
@@ -652,22 +662,22 @@ case 86: {
sym(1).Node = node;
} break;
-case 87: {
+case 89: {
AST::ObjectLiteral *node = new (pool) AST::ObjectLiteral(
- sym(2).PropertyNameAndValueList->finish ());
+ sym(2).PropertyAssignmentList->finish ());
node->lbraceToken = loc(1);
node->rbraceToken = loc(4);
sym(1).Node = node;
} break;
-case 88: {
+case 90: {
AST::NestedExpression *node = new (pool) AST::NestedExpression(sym(2).Expression);
node->lparenToken = loc(1);
node->rparenToken = loc(3);
sym(1).Node = node;
} break;
-case 89: {
+case 91: {
if (AST::ArrayMemberExpression *mem = AST::cast<AST::ArrayMemberExpression *>(sym(1).Expression)) {
diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Warning, mem->lbracketToken,
QLatin1String("Ignored annotation")));
@@ -687,100 +697,119 @@ case 89: {
}
} break;
-case 90: {
+case 92: {
sym(1).Node = new (pool) AST::ElementList((AST::Elision *) 0, sym(1).Expression);
} break;
-case 91: {
+case 93: {
sym(1).Node = new (pool) AST::ElementList(sym(1).Elision->finish(), sym(2).Expression);
} break;
-case 92: {
+case 94: {
AST::ElementList *node = new (pool) AST::ElementList(sym(1).ElementList,
(AST::Elision *) 0, sym(3).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 93: {
+case 95: {
AST::ElementList *node = new (pool) AST::ElementList(sym(1).ElementList, sym(3).Elision->finish(),
sym(4).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 94: {
+case 96: {
AST::Elision *node = new (pool) AST::Elision();
node->commaToken = loc(1);
sym(1).Node = node;
} break;
-case 95: {
+case 97: {
AST::Elision *node = new (pool) AST::Elision(sym(1).Elision);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 96: {
- AST::PropertyNameAndValueList *node = new (pool) AST::PropertyNameAndValueList(
+case 98: {
+ AST::PropertyNameAndValue *node = new (pool) AST::PropertyNameAndValue(
sym(1).PropertyName, sym(3).Expression);
node->colonToken = loc(2);
sym(1).Node = node;
} break;
-case 97: {
- AST::PropertyNameAndValueList *node = new (pool) AST::PropertyNameAndValueList(
- sym(1).PropertyNameAndValueList, sym(3).PropertyName, sym(5).Expression);
- node->commaToken = loc(2);
- node->colonToken = loc(4);
+case 99: {
+ AST::PropertyGetterSetter *node = new (pool) AST::PropertyGetterSetter(
+ sym(2).PropertyName, sym(6).FunctionBody);
+ node->getSetToken = loc(1);
+ node->lparenToken = loc(3);
+ node->rparenToken = loc(4);
+ node->lbraceToken = loc(5);
+ node->rbraceToken = loc(7);
sym(1).Node = node;
} break;
-case 98: {
- AST::IdentifierPropertyName *node = new (pool) AST::IdentifierPropertyName(stringRef(1));
- node->propertyNameToken = loc(1);
+case 100: {
+ AST::PropertyGetterSetter *node = new (pool) AST::PropertyGetterSetter(
+ sym(2).PropertyName, sym(4).FormalParameterList, sym(7).FunctionBody);
+ node->getSetToken = loc(1);
+ node->lparenToken = loc(3);
+ node->rparenToken = loc(5);
+ node->lbraceToken = loc(6);
+ node->rbraceToken = loc(8);
sym(1).Node = node;
} break;
-case 99:
-case 100: {
+
+case 101: {
+ sym(1).Node = new (pool) AST::PropertyAssignmentList(sym(1).PropertyAssignment);
+} break;
+
+case 102: {
+ AST::PropertyAssignmentList *node = new (pool) AST::PropertyAssignmentList(
+ sym(1).PropertyAssignmentList, sym(3).PropertyAssignment);
+ node->commaToken = loc(2);
+ sym(1).Node = node;
+} break;
+
+case 103: {
AST::IdentifierPropertyName *node = new (pool) AST::IdentifierPropertyName(stringRef(1));
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
-case 101: {
+case 104: {
AST::StringLiteralPropertyName *node = new (pool) AST::StringLiteralPropertyName(stringRef(1));
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
-case 102: {
+case 105: {
AST::NumericLiteralPropertyName *node = new (pool) AST::NumericLiteralPropertyName(sym(1).dval);
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
-case 103: {
+case 106: {
AST::IdentifierPropertyName *node = new (pool) AST::IdentifierPropertyName(stringRef(1));
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
-case 139: {
+case 142: {
AST::ArrayMemberExpression *node = new (pool) AST::ArrayMemberExpression(sym(1).Expression, sym(3).Expression);
node->lbracketToken = loc(2);
node->rbracketToken = loc(4);
sym(1).Node = node;
} break;
-case 140: {
+case 143: {
AST::FieldMemberExpression *node = new (pool) AST::FieldMemberExpression(sym(1).Expression, stringRef(3));
node->dotToken = loc(2);
node->identifierToken = loc(3);
sym(1).Node = node;
} break;
-case 141: {
+case 144: {
AST::NewMemberExpression *node = new (pool) AST::NewMemberExpression(sym(2).Expression, sym(4).ArgumentList);
node->newToken = loc(1);
node->lparenToken = loc(3);
@@ -788,384 +817,384 @@ case 141: {
sym(1).Node = node;
} break;
-case 143: {
+case 146: {
AST::NewExpression *node = new (pool) AST::NewExpression(sym(2).Expression);
node->newToken = loc(1);
sym(1).Node = node;
} break;
-case 144: {
+case 147: {
AST::CallExpression *node = new (pool) AST::CallExpression(sym(1).Expression, sym(3).ArgumentList);
node->lparenToken = loc(2);
node->rparenToken = loc(4);
sym(1).Node = node;
} break;
-case 145: {
+case 148: {
AST::CallExpression *node = new (pool) AST::CallExpression(sym(1).Expression, sym(3).ArgumentList);
node->lparenToken = loc(2);
node->rparenToken = loc(4);
sym(1).Node = node;
} break;
-case 146: {
+case 149: {
AST::ArrayMemberExpression *node = new (pool) AST::ArrayMemberExpression(sym(1).Expression, sym(3).Expression);
node->lbracketToken = loc(2);
node->rbracketToken = loc(4);
sym(1).Node = node;
} break;
-case 147: {
+case 150: {
AST::FieldMemberExpression *node = new (pool) AST::FieldMemberExpression(sym(1).Expression, stringRef(3));
node->dotToken = loc(2);
node->identifierToken = loc(3);
sym(1).Node = node;
} break;
-case 148: {
+case 151: {
sym(1).Node = 0;
} break;
-case 149: {
+case 152: {
sym(1).Node = sym(1).ArgumentList->finish();
} break;
-case 150: {
+case 153: {
sym(1).Node = new (pool) AST::ArgumentList(sym(1).Expression);
} break;
-case 151: {
+case 154: {
AST::ArgumentList *node = new (pool) AST::ArgumentList(sym(1).ArgumentList, sym(3).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 155: {
+case 158: {
AST::PostIncrementExpression *node = new (pool) AST::PostIncrementExpression(sym(1).Expression);
node->incrementToken = loc(2);
sym(1).Node = node;
} break;
-case 156: {
+case 159: {
AST::PostDecrementExpression *node = new (pool) AST::PostDecrementExpression(sym(1).Expression);
node->decrementToken = loc(2);
sym(1).Node = node;
} break;
-case 158: {
+case 161: {
AST::DeleteExpression *node = new (pool) AST::DeleteExpression(sym(2).Expression);
node->deleteToken = loc(1);
sym(1).Node = node;
} break;
-case 159: {
+case 162: {
AST::VoidExpression *node = new (pool) AST::VoidExpression(sym(2).Expression);
node->voidToken = loc(1);
sym(1).Node = node;
} break;
-case 160: {
+case 163: {
AST::TypeOfExpression *node = new (pool) AST::TypeOfExpression(sym(2).Expression);
node->typeofToken = loc(1);
sym(1).Node = node;
} break;
-case 161: {
+case 164: {
AST::PreIncrementExpression *node = new (pool) AST::PreIncrementExpression(sym(2).Expression);
node->incrementToken = loc(1);
sym(1).Node = node;
} break;
-case 162: {
+case 165: {
AST::PreDecrementExpression *node = new (pool) AST::PreDecrementExpression(sym(2).Expression);
node->decrementToken = loc(1);
sym(1).Node = node;
} break;
-case 163: {
+case 166: {
AST::UnaryPlusExpression *node = new (pool) AST::UnaryPlusExpression(sym(2).Expression);
node->plusToken = loc(1);
sym(1).Node = node;
} break;
-case 164: {
+case 167: {
AST::UnaryMinusExpression *node = new (pool) AST::UnaryMinusExpression(sym(2).Expression);
node->minusToken = loc(1);
sym(1).Node = node;
} break;
-case 165: {
+case 168: {
AST::TildeExpression *node = new (pool) AST::TildeExpression(sym(2).Expression);
node->tildeToken = loc(1);
sym(1).Node = node;
} break;
-case 166: {
+case 169: {
AST::NotExpression *node = new (pool) AST::NotExpression(sym(2).Expression);
node->notToken = loc(1);
sym(1).Node = node;
} break;
-case 168: {
+case 171: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Mul, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 169: {
+case 172: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Div, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 170: {
+case 173: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Mod, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 172: {
+case 175: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Add, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 173: {
+case 176: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Sub, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 175: {
+case 178: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::LShift, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 176: {
+case 179: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::RShift, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 177: {
+case 180: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::URShift, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 179: {
+case 182: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Lt, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 180: {
+case 183: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Gt, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 181: {
+case 184: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Le, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 182: {
+case 185: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Ge, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 183: {
+case 186: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::InstanceOf, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 184: {
+case 187: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::In, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 186: {
+case 189: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Lt, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 187: {
+case 190: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Gt, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 188: {
+case 191: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Le, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 189: {
+case 192: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Ge, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 190: {
+case 193: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::InstanceOf, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 192: {
+case 195: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Equal, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 193: {
+case 196: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::NotEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 194: {
+case 197: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::StrictEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 195: {
+case 198: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::StrictNotEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 197: {
+case 200: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Equal, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 198: {
+case 201: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::NotEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 199: {
+case 202: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::StrictEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 200: {
+case 203: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::StrictNotEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 202: {
+case 205: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::BitAnd, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 204: {
+case 207: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::BitAnd, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 206: {
+case 209: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::BitXor, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 208: {
+case 211: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::BitXor, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 210: {
+case 213: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::BitOr, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 212: {
+case 215: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::BitOr, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 214: {
+case 217: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::And, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 216: {
+case 219: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::And, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 218: {
+case 221: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Or, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 220: {
+case 223: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
QSOperator::Or, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 222: {
+case 225: {
AST::ConditionalExpression *node = new (pool) AST::ConditionalExpression(sym(1).Expression,
sym(3).Expression, sym(5).Expression);
node->questionToken = loc(2);
@@ -1173,7 +1202,7 @@ case 222: {
sym(1).Node = node;
} break;
-case 224: {
+case 227: {
AST::ConditionalExpression *node = new (pool) AST::ConditionalExpression(sym(1).Expression,
sym(3).Expression, sym(5).Expression);
node->questionToken = loc(2);
@@ -1181,112 +1210,112 @@ case 224: {
sym(1).Node = node;
} break;
-case 226: {
+case 229: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
sym(2).ival, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 228: {
+case 231: {
AST::BinaryExpression *node = new (pool) AST::BinaryExpression(sym(1).Expression,
sym(2).ival, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 229: {
+case 232: {
sym(1).ival = QSOperator::Assign;
} break;
-case 230: {
+case 233: {
sym(1).ival = QSOperator::InplaceMul;
} break;
-case 231: {
+case 234: {
sym(1).ival = QSOperator::InplaceDiv;
} break;
-case 232: {
+case 235: {
sym(1).ival = QSOperator::InplaceMod;
} break;
-case 233: {
+case 236: {
sym(1).ival = QSOperator::InplaceAdd;
} break;
-case 234: {
+case 237: {
sym(1).ival = QSOperator::InplaceSub;
} break;
-case 235: {
+case 238: {
sym(1).ival = QSOperator::InplaceLeftShift;
} break;
-case 236: {
+case 239: {
sym(1).ival = QSOperator::InplaceRightShift;
} break;
-case 237: {
+case 240: {
sym(1).ival = QSOperator::InplaceURightShift;
} break;
-case 238: {
+case 241: {
sym(1).ival = QSOperator::InplaceAnd;
} break;
-case 239: {
+case 242: {
sym(1).ival = QSOperator::InplaceXor;
} break;
-case 240: {
+case 243: {
sym(1).ival = QSOperator::InplaceOr;
} break;
-case 242: {
+case 245: {
AST::Expression *node = new (pool) AST::Expression(sym(1).Expression, sym(3).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 243: {
+case 246: {
sym(1).Node = 0;
} break;
-case 246: {
+case 249: {
AST::Expression *node = new (pool) AST::Expression(sym(1).Expression, sym(3).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 247: {
+case 250: {
sym(1).Node = 0;
} break;
-case 264: {
+case 267: {
AST::Block *node = new (pool) AST::Block(sym(2).StatementList);
node->lbraceToken = loc(1);
node->rbraceToken = loc(3);
sym(1).Node = node;
} break;
-case 265: {
+case 268: {
sym(1).Node = new (pool) AST::StatementList(sym(1).Statement);
} break;
-case 266: {
+case 269: {
sym(1).Node = new (pool) AST::StatementList(sym(1).StatementList, sym(2).Statement);
} break;
-case 267: {
+case 270: {
sym(1).Node = 0;
} break;
-case 268: {
+case 271: {
sym(1).Node = sym(1).StatementList->finish ();
} break;
-case 270: {
+case 273: {
AST::VariableStatement *node = new (pool) AST::VariableStatement(
sym(2).VariableDeclarationList->finish (/*readOnly=*/sym(1).ival == T_CONST));
node->declarationKindToken = loc(1);
@@ -1294,76 +1323,76 @@ case 270: {
sym(1).Node = node;
} break;
-case 271: {
+case 274: {
sym(1).ival = T_CONST;
} break;
-case 272: {
+case 275: {
sym(1).ival = T_VAR;
} break;
-case 273: {
+case 276: {
sym(1).Node = new (pool) AST::VariableDeclarationList(sym(1).VariableDeclaration);
} break;
-case 274: {
+case 277: {
AST::VariableDeclarationList *node = new (pool) AST::VariableDeclarationList(
sym(1).VariableDeclarationList, sym(3).VariableDeclaration);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 275: {
+case 278: {
sym(1).Node = new (pool) AST::VariableDeclarationList(sym(1).VariableDeclaration);
} break;
-case 276: {
+case 279: {
sym(1).Node = new (pool) AST::VariableDeclarationList(sym(1).VariableDeclarationList, sym(3).VariableDeclaration);
} break;
-case 277: {
+case 280: {
AST::VariableDeclaration *node = new (pool) AST::VariableDeclaration(stringRef(1), sym(2).Expression);
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 278: {
+case 281: {
AST::VariableDeclaration *node = new (pool) AST::VariableDeclaration(stringRef(1), sym(2).Expression);
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 279: {
+case 282: {
// ### TODO: AST for initializer
sym(1) = sym(2);
} break;
-case 280: {
+case 283: {
sym(1).Node = 0;
} break;
-case 282: {
+case 285: {
// ### TODO: AST for initializer
sym(1) = sym(2);
} break;
-case 283: {
+case 286: {
sym(1).Node = 0;
} break;
-case 285: {
+case 288: {
AST::EmptyStatement *node = new (pool) AST::EmptyStatement();
node->semicolonToken = loc(1);
sym(1).Node = node;
} break;
-case 287: {
+case 290: {
AST::ExpressionStatement *node = new (pool) AST::ExpressionStatement(sym(1).Expression);
node->semicolonToken = loc(2);
sym(1).Node = node;
} break;
-case 288: {
+case 291: {
AST::IfStatement *node = new (pool) AST::IfStatement(sym(3).Expression, sym(5).Statement, sym(7).Statement);
node->ifToken = loc(1);
node->lparenToken = loc(2);
@@ -1372,7 +1401,7 @@ case 288: {
sym(1).Node = node;
} break;
-case 289: {
+case 292: {
AST::IfStatement *node = new (pool) AST::IfStatement(sym(3).Expression, sym(5).Statement);
node->ifToken = loc(1);
node->lparenToken = loc(2);
@@ -1380,7 +1409,7 @@ case 289: {
sym(1).Node = node;
} break;
-case 291: {
+case 295: {
AST::DoWhileStatement *node = new (pool) AST::DoWhileStatement(sym(2).Statement, sym(5).Expression);
node->doToken = loc(1);
node->whileToken = loc(3);
@@ -1390,7 +1419,7 @@ case 291: {
sym(1).Node = node;
} break;
-case 292: {
+case 296: {
AST::WhileStatement *node = new (pool) AST::WhileStatement(sym(3).Expression, sym(5).Statement);
node->whileToken = loc(1);
node->lparenToken = loc(2);
@@ -1398,7 +1427,7 @@ case 292: {
sym(1).Node = node;
} break;
-case 293: {
+case 297: {
AST::ForStatement *node = new (pool) AST::ForStatement(sym(3).Expression,
sym(5).Expression, sym(7).Expression, sym(9).Statement);
node->forToken = loc(1);
@@ -1409,7 +1438,7 @@ case 293: {
sym(1).Node = node;
} break;
-case 294: {
+case 298: {
AST::LocalForStatement *node = new (pool) AST::LocalForStatement(
sym(4).VariableDeclarationList->finish (/*readOnly=*/false), sym(6).Expression,
sym(8).Expression, sym(10).Statement);
@@ -1422,7 +1451,7 @@ case 294: {
sym(1).Node = node;
} break;
-case 295: {
+case 299: {
AST:: ForEachStatement *node = new (pool) AST::ForEachStatement(sym(3).Expression,
sym(5).Expression, sym(7).Statement);
node->forToken = loc(1);
@@ -1432,7 +1461,7 @@ case 295: {
sym(1).Node = node;
} break;
-case 296: {
+case 300: {
AST::LocalForEachStatement *node = new (pool) AST::LocalForEachStatement(
sym(4).VariableDeclaration, sym(6).Expression, sym(8).Statement);
node->forToken = loc(1);
@@ -1443,14 +1472,14 @@ case 296: {
sym(1).Node = node;
} break;
-case 298: {
+case 302: {
AST::ContinueStatement *node = new (pool) AST::ContinueStatement();
node->continueToken = loc(1);
node->semicolonToken = loc(2);
sym(1).Node = node;
} break;
-case 300: {
+case 304: {
AST::ContinueStatement *node = new (pool) AST::ContinueStatement(stringRef(2));
node->continueToken = loc(1);
node->identifierToken = loc(2);
@@ -1458,14 +1487,14 @@ case 300: {
sym(1).Node = node;
} break;
-case 302: {
+case 306: {
AST::BreakStatement *node = new (pool) AST::BreakStatement(QStringRef());
node->breakToken = loc(1);
node->semicolonToken = loc(2);
sym(1).Node = node;
} break;
-case 304: {
+case 308: {
AST::BreakStatement *node = new (pool) AST::BreakStatement(stringRef(2));
node->breakToken = loc(1);
node->identifierToken = loc(2);
@@ -1473,14 +1502,14 @@ case 304: {
sym(1).Node = node;
} break;
-case 306: {
+case 310: {
AST::ReturnStatement *node = new (pool) AST::ReturnStatement(sym(2).Expression);
node->returnToken = loc(1);
node->semicolonToken = loc(3);
sym(1).Node = node;
} break;
-case 307: {
+case 311: {
AST::WithStatement *node = new (pool) AST::WithStatement(sym(3).Expression, sym(5).Statement);
node->withToken = loc(1);
node->lparenToken = loc(2);
@@ -1488,7 +1517,7 @@ case 307: {
sym(1).Node = node;
} break;
-case 308: {
+case 312: {
AST::SwitchStatement *node = new (pool) AST::SwitchStatement(sym(3).Expression, sym(5).CaseBlock);
node->switchToken = loc(1);
node->lparenToken = loc(2);
@@ -1496,90 +1525,83 @@ case 308: {
sym(1).Node = node;
} break;
-case 309: {
+case 313: {
AST::CaseBlock *node = new (pool) AST::CaseBlock(sym(2).CaseClauses);
node->lbraceToken = loc(1);
node->rbraceToken = loc(3);
sym(1).Node = node;
} break;
-case 310: {
+case 314: {
AST::CaseBlock *node = new (pool) AST::CaseBlock(sym(2).CaseClauses, sym(3).DefaultClause, sym(4).CaseClauses);
node->lbraceToken = loc(1);
node->rbraceToken = loc(5);
sym(1).Node = node;
} break;
-case 311: {
+case 315: {
sym(1).Node = new (pool) AST::CaseClauses(sym(1).CaseClause);
} break;
-case 312: {
+case 316: {
sym(1).Node = new (pool) AST::CaseClauses(sym(1).CaseClauses, sym(2).CaseClause);
} break;
-case 313: {
+case 317: {
sym(1).Node = 0;
} break;
-case 314: {
+case 318: {
sym(1).Node = sym(1).CaseClauses->finish ();
} break;
-case 315: {
+case 319: {
AST::CaseClause *node = new (pool) AST::CaseClause(sym(2).Expression, sym(4).StatementList);
node->caseToken = loc(1);
node->colonToken = loc(3);
sym(1).Node = node;
} break;
-case 316: {
+case 320: {
AST::DefaultClause *node = new (pool) AST::DefaultClause(sym(3).StatementList);
node->defaultToken = loc(1);
node->colonToken = loc(2);
sym(1).Node = node;
} break;
-case 317:
-case 318: {
- AST::LabelledStatement *node = new (pool) AST::LabelledStatement(stringRef(1), sym(3).Statement);
- node->identifierToken = loc(1);
- node->colonToken = loc(2);
- sym(1).Node = node;
-} break;
-case 319: {
+case 321: {
AST::LabelledStatement *node = new (pool) AST::LabelledStatement(stringRef(1), sym(3).Statement);
node->identifierToken = loc(1);
node->colonToken = loc(2);
sym(1).Node = node;
} break;
-case 321: {
+case 323: {
AST::ThrowStatement *node = new (pool) AST::ThrowStatement(sym(2).Expression);
node->throwToken = loc(1);
node->semicolonToken = loc(3);
sym(1).Node = node;
} break;
-case 322: {
+case 324: {
AST::TryStatement *node = new (pool) AST::TryStatement(sym(2).Statement, sym(3).Catch);
node->tryToken = loc(1);
sym(1).Node = node;
} break;
-case 323: {
+case 325: {
AST::TryStatement *node = new (pool) AST::TryStatement(sym(2).Statement, sym(3).Finally);
node->tryToken = loc(1);
sym(1).Node = node;
} break;
-case 324: {
+case 326: {
AST::TryStatement *node = new (pool) AST::TryStatement(sym(2).Statement, sym(3).Catch, sym(4).Finally);
node->tryToken = loc(1);
sym(1).Node = node;
} break;
-case 325: {
+case 327: {
AST::Catch *node = new (pool) AST::Catch(stringRef(3), sym(5).Block);
node->catchToken = loc(1);
node->lparenToken = loc(2);
@@ -1588,20 +1610,20 @@ case 325: {
sym(1).Node = node;
} break;
-case 326: {
+case 328: {
AST::Finally *node = new (pool) AST::Finally(sym(2).Block);
node->finallyToken = loc(1);
sym(1).Node = node;
} break;
-case 328: {
+case 330: {
AST::DebuggerStatement *node = new (pool) AST::DebuggerStatement();
node->debuggerToken = loc(1);
node->semicolonToken = loc(2);
sym(1).Node = node;
} break;
-case 329: {
+case 332: {
AST::FunctionDeclaration *node = new (pool) AST::FunctionDeclaration(stringRef(2), sym(4).FormalParameterList, sym(7).FunctionBody);
node->functionToken = loc(1);
node->identifierToken = loc(2);
@@ -1612,7 +1634,7 @@ case 329: {
sym(1).Node = node;
} break;
-case 330: {
+case 333: {
AST::FunctionExpression *node = new (pool) AST::FunctionExpression(stringRef(2), sym(4).FormalParameterList, sym(7).FunctionBody);
node->functionToken = loc(1);
if (! stringRef(2).isNull())
@@ -1624,60 +1646,66 @@ case 330: {
sym(1).Node = node;
} break;
-case 331: {
+case 334: {
+ AST::FunctionExpression *node = new (pool) AST::FunctionExpression(QStringRef(), sym(3).FormalParameterList, sym(6).FunctionBody);
+ node->functionToken = loc(1);
+ node->lparenToken = loc(2);
+ node->rparenToken = loc(4);
+ node->lbraceToken = loc(5);
+ node->rbraceToken = loc(7);
+ sym(1).Node = node;
+} break;
+
+case 335: {
AST::FormalParameterList *node = new (pool) AST::FormalParameterList(stringRef(1));
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 332: {
+case 336: {
AST::FormalParameterList *node = new (pool) AST::FormalParameterList(sym(1).FormalParameterList, stringRef(3));
node->commaToken = loc(2);
node->identifierToken = loc(3);
sym(1).Node = node;
} break;
-case 333: {
+case 337: {
sym(1).Node = 0;
} break;
-case 334: {
+case 338: {
sym(1).Node = sym(1).FormalParameterList->finish ();
} break;
-case 335: {
+case 339: {
sym(1).Node = 0;
} break;
-case 337: {
+case 341: {
sym(1).Node = new (pool) AST::FunctionBody(sym(1).SourceElements->finish ());
} break;
-case 339: {
+case 343: {
sym(1).Node = new (pool) AST::Program(sym(1).SourceElements->finish ());
} break;
-case 340: {
+case 344: {
sym(1).Node = new (pool) AST::SourceElements(sym(1).SourceElement);
} break;
-case 341: {
+case 345: {
sym(1).Node = new (pool) AST::SourceElements(sym(1).SourceElements, sym(2).SourceElement);
} break;
-case 342: {
+case 346: {
sym(1).Node = new (pool) AST::StatementSourceElement(sym(1).Statement);
} break;
-case 343: {
+case 347: {
sym(1).Node = new (pool) AST::FunctionSourceElement(sym(1).FunctionDeclaration);
} break;
-case 344: {
- stringRef(1) = QStringRef();
-} break;
-
-case 346: {
+case 348: {
sym(1).Node = 0;
} break;
@@ -1690,7 +1718,8 @@ case 346: {
const int errorState = state_stack[tos];
// automatic insertion of `;'
- if (yytoken != -1 && t_action(errorState, T_AUTOMATIC_SEMICOLON) && lexer->canInsertAutomaticSemicolon(yytoken)) {
+ if (yytoken != -1 && ((t_action(errorState, T_AUTOMATIC_SEMICOLON) && lexer->canInsertAutomaticSemicolon(yytoken))
+ || t_action(errorState, T_COMPATIBILITY_SEMICOLON))) {
SavedToken &tk = token_buffer[0];
tk.token = yytoken;
tk.dval = yylval;
@@ -1702,7 +1731,7 @@ case 346: {
yylloc.startColumn += yylloc.length;
yylloc.length = 0;
- //const QString msg = tr("QQmlParser", "Missing `;'");
+ //const QString msg = qApp->translate("QQmlParser", "Missing `;'");
//diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Warning, yylloc, msg));
first_token = &token_buffer[0];
@@ -1732,9 +1761,9 @@ case 346: {
QString msg;
int token = token_buffer[0].token;
if (token < 0 || token >= TERMINAL_COUNT)
- msg = tr("QQmlParser", "Syntax error");
+ msg = qApp->translate("QQmlParser", "Syntax error");
else
- msg = tr("QQmlParser", "Unexpected token `%1'").arg(QLatin1String(spell[token]));
+ msg = qApp->translate("QQmlParser", "Unexpected token `%1'").arg(QLatin1String(spell[token]));
diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, token_buffer[0].loc, msg));
action = errorState;
@@ -1762,7 +1791,7 @@ case 346: {
for (int *tk = tokens; *tk != EOF_SYMBOL; ++tk) {
int a = t_action(errorState, *tk);
if (a > 0 && t_action(a, yytoken)) {
- const QString msg = tr("QQmlParser", "Expected token `%1'").arg(QLatin1String(spell[*tk]));
+ const QString msg = qApp->translate("QQmlParser", "Expected token `%1'").arg(QLatin1String(spell[*tk]));
diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, token_buffer[0].loc, msg));
yytoken = *tk;
@@ -1786,7 +1815,7 @@ case 346: {
int a = t_action(errorState, tk);
if (a > 0 && t_action(a, yytoken)) {
- const QString msg = tr("QQmlParser", "Expected token `%1'").arg(QLatin1String(spell[tk]));
+ const QString msg = qApp->translate("QQmlParser", "Expected token `%1'").arg(QLatin1String(spell[tk]));
diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, token_buffer[0].loc, msg));
yytoken = tk;
@@ -1799,7 +1828,7 @@ case 346: {
}
}
- const QString msg = tr("QQmlParser", "Syntax error");
+ const QString msg = qApp->translate("QQmlParser", "Syntax error");
diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, token_buffer[0].loc, msg));
}
diff --git a/src/tools/qdoc/qmlparser/qqmljsparser_p.h b/src/tools/qdoc/qmlparser/qqmljsparser_p.h
index 9fe7428bc2..1b13690547 100644
--- a/src/tools/qdoc/qmlparser/qqmljsparser_p.h
+++ b/src/tools/qdoc/qmlparser/qqmljsparser_p.h
@@ -52,8 +52,15 @@
//
//
-// This file is automatically generated from qmljs.g.
-// Changes will be lost.
+// W A R N I N G
+// -------------
+//
+// This file is automatically generated from qqmljs.g.
+// Changes should be made to that file, not here. Any change to this file will
+// be lost!
+//
+// To regenerate this file, run:
+// qlalr --no-debug --no-lines --qt qqmljs.g
//
#ifndef QQMLJSPARSER_P_H
@@ -64,8 +71,8 @@
#include "qqmljsast_p.h"
#include "qqmljsengine_p.h"
-#include <qlist.h>
-#include <qstring.h>
+#include <QtCore/qlist.h>
+#include <QtCore/qstring.h>
QT_QML_BEGIN_NAMESPACE
@@ -75,8 +82,6 @@ class Engine;
class QML_PARSER_EXPORT Parser: protected QQmlJSGrammar
{
- Q_DECLARE_TR_FUNCTIONS(QDoc::QQmlJS::Parser)
-
public:
union Value {
int ival;
@@ -96,7 +101,8 @@ public:
AST::FunctionDeclaration *FunctionDeclaration;
AST::Node *Node;
AST::PropertyName *PropertyName;
- AST::PropertyNameAndValueList *PropertyNameAndValueList;
+ AST::PropertyAssignment *PropertyAssignment;
+ AST::PropertyAssignmentList *PropertyAssignmentList;
AST::SourceElement *SourceElement;
AST::SourceElements *SourceElements;
AST::Statement *Statement;
@@ -239,9 +245,9 @@ protected:
-#define J_SCRIPT_REGEXPLITERAL_RULE1 79
+#define J_SCRIPT_REGEXPLITERAL_RULE1 81
-#define J_SCRIPT_REGEXPLITERAL_RULE2 80
+#define J_SCRIPT_REGEXPLITERAL_RULE2 82
QT_QML_END_NAMESPACE
diff --git a/src/tools/qdoc/qmlvisitor.cpp b/src/tools/qdoc/qmlvisitor.cpp
index 8b6f81de3e..ffe1afe28b 100644
--- a/src/tools/qdoc/qmlvisitor.cpp
+++ b/src/tools/qdoc/qmlvisitor.cpp
@@ -88,6 +88,7 @@ QmlDocVisitor::QmlDocVisitor(const QString &filePath,
QSet<QString> &topics)
: nestingLevel(0)
{
+ lastEndOffset = 0;
this->filePath = filePath;
this->name = QFileInfo(filePath).baseName();
document = code;
@@ -117,21 +118,21 @@ QQmlJS::AST::SourceLocation QmlDocVisitor::precedingComment(quint32 offset) cons
QQmlJS::AST::SourceLocation loc = it.previous();
- if (loc.begin() <= lastEndOffset)
+ if (loc.begin() <= lastEndOffset) {
// Return if we reach the end of the preceding structure.
break;
-
- else if (usedComments.contains(loc.begin()))
+ }
+ else if (usedComments.contains(loc.begin())) {
// Return if we encounter a previously used comment.
break;
-
+ }
else if (loc.begin() > lastEndOffset && loc.end() < offset) {
-
// Only examine multiline comments in order to avoid snippet markers.
if (document.at(loc.offset - 1) == QLatin1Char('*')) {
QString comment = document.mid(loc.offset, loc.length);
- if (comment.startsWith(QLatin1Char('!')) || comment.startsWith(QLatin1Char('*')))
+ if (comment.startsWith(QLatin1Char('!')) || comment.startsWith(QLatin1Char('*'))) {
return loc;
+ }
}
}
}
@@ -165,8 +166,9 @@ bool QmlDocVisitor::applyDocumentation(QQmlJS::AST::SourceLocation location, Nod
node->setDoc(doc);
applyMetacommands(loc, node, doc);
usedComments.insert(loc.offset);
- if (doc.isEmpty())
+ if (doc.isEmpty()) {
return false;
+ }
return true;
}
Location codeLoc(filePath);
@@ -424,8 +426,9 @@ bool QmlDocVisitor::visit(QQmlJS::AST::UiObjectDefinition *definition)
*/
void QmlDocVisitor::endVisit(QQmlJS::AST::UiObjectDefinition *definition)
{
- if (nestingLevel > 0)
+ if (nestingLevel > 0) {
--nestingLevel;
+ }
lastEndOffset = definition->lastSourceLocation().end();
}
@@ -461,6 +464,26 @@ void QmlDocVisitor::endVisit(QQmlJS::AST::UiImportList *definition)
lastEndOffset = definition->lastSourceLocation().end();
}
+bool QmlDocVisitor::visit(QQmlJS::AST::UiObjectBinding *)
+{
+ ++nestingLevel;
+ return true;
+}
+
+void QmlDocVisitor::endVisit(QQmlJS::AST::UiObjectBinding *)
+{
+ --nestingLevel;
+}
+
+bool QmlDocVisitor::visit(QQmlJS::AST::UiArrayBinding *)
+{
+ return true;
+}
+
+void QmlDocVisitor::endVisit(QQmlJS::AST::UiArrayBinding *)
+{
+}
+
/*!
Visits the public \a member declaration, which can be a
signal or a property. It is a custom signal or property.
@@ -468,8 +491,9 @@ void QmlDocVisitor::endVisit(QQmlJS::AST::UiImportList *definition)
*/
bool QmlDocVisitor::visit(QQmlJS::AST::UiPublicMember *member)
{
- if (nestingLevel > 1)
+ if (nestingLevel > 1) {
return true;
+ }
switch (member->type) {
case QQmlJS::AST::UiPublicMember::Signal:
{
@@ -535,8 +559,9 @@ bool QmlDocVisitor::visit(QQmlJS::AST::IdentifierPropertyName *)
*/
bool QmlDocVisitor::visit(QQmlJS::AST::FunctionDeclaration* fd)
{
- if (nestingLevel > 1)
+ if (nestingLevel > 1) {
return true;
+ }
if (current->type() == Node::Document) {
QmlClassNode* qmlClass = static_cast<QmlClassNode*>(current);
if (qmlClass) {
@@ -578,11 +603,18 @@ void QmlDocVisitor::endVisit(QQmlJS::AST::FunctionDeclaration* fd)
/*!
Begin the visit of the signal handler declaration \a sb, but only
if the nesting level is 1.
+
+ This visit is now deprecated. It has been decided to document
+ public signals. If a signal handler must be discussed in the
+ documentation, that discussion must take place in the comment
+ for the signal.
*/
-bool QmlDocVisitor::visit(QQmlJS::AST::UiScriptBinding* sb)
+bool QmlDocVisitor::visit(QQmlJS::AST::UiScriptBinding* )
{
- if (nestingLevel > 1)
+#if 0
+ if (nestingLevel > 1) {
return true;
+ }
if (current->type() == Node::Document) {
QString handler = sb->qualifiedId->name.toString();
if (handler.length() > 2 && handler.startsWith("on") && handler.at(2).isUpper()) {
@@ -593,6 +625,7 @@ bool QmlDocVisitor::visit(QQmlJS::AST::UiScriptBinding* sb)
}
}
}
+#endif
return true;
}
diff --git a/src/tools/qdoc/qmlvisitor.h b/src/tools/qdoc/qmlvisitor.h
index bfec61eb34..cc00ccbe6c 100644
--- a/src/tools/qdoc/qmlvisitor.h
+++ b/src/tools/qdoc/qmlvisitor.h
@@ -85,6 +85,11 @@ public:
bool visit(QQmlJS::AST::UiPublicMember *member);
void endVisit(QQmlJS::AST::UiPublicMember *definition);
+ virtual bool visit(QQmlJS::AST::UiObjectBinding *);
+ virtual void endVisit(QQmlJS::AST::UiObjectBinding *);
+ virtual void endVisit(QQmlJS::AST::UiArrayBinding *);
+ virtual bool visit(QQmlJS::AST::UiArrayBinding *);
+
bool visit(QQmlJS::AST::IdentifierPropertyName *idproperty);
bool visit(QQmlJS::AST::FunctionDeclaration *);
diff --git a/src/tools/rcc/main.cpp b/src/tools/rcc/main.cpp
index b6d5965dae..c0ed7401bc 100644
--- a/src/tools/rcc/main.cpp
+++ b/src/tools/rcc/main.cpp
@@ -216,7 +216,7 @@ int runRcc(int argc, char *argv[])
}
QFile errorDevice;
errorDevice.open(stderr, QIODevice::WriteOnly|QIODevice::Text);
-
+
if (library.verbose())
errorDevice.write("Qt resource compiler\n");
@@ -251,7 +251,7 @@ int runRcc(int argc, char *argv[])
out.write("\n");
}
return 0;
- }
+ }
return library.output(out, errorDevice) ? 0 : 1;
}
diff --git a/src/tools/rcc/rcc.h b/src/tools/rcc/rcc.h
index cd9828fc35..7e16fe038d 100644
--- a/src/tools/rcc/rcc.h
+++ b/src/tools/rcc/rcc.h
@@ -95,10 +95,10 @@ public:
void setResourceRoot(const QString &root) { m_resourceRoot = root; }
QString resourceRoot() const { return m_resourceRoot; }
-
+
void setUseNameSpace(bool v) { m_useNameSpace = v; }
bool useNameSpace() const { return m_useNameSpace; }
-
+
QStringList failedResources() const { return m_failedResources; }
private:
diff --git a/src/tools/rcc/rcc.pro b/src/tools/rcc/rcc.pro
index f4ad2f63d7..354747db01 100644
--- a/src/tools/rcc/rcc.pro
+++ b/src/tools/rcc/rcc.pro
@@ -1,4 +1,5 @@
option(host_build)
+CONFIG += force_bootstrap
DEFINES += QT_RCC QT_NO_CAST_FROM_ASCII
diff --git a/src/tools/tools.pro b/src/tools/tools.pro
deleted file mode 100644
index fa9ed54c50..0000000000
--- a/src/tools/tools.pro
+++ /dev/null
@@ -1,43 +0,0 @@
-TEMPLATE = subdirs
-
-TOOLS_SUBDIRS = src_tools_bootstrap src_tools_moc src_tools_rcc src_tools_qdoc
-contains(QT_CONFIG, dbus): TOOLS_SUBDIRS += src_tools_qdbusxml2cpp src_tools_qdbuscpp2xml
-!contains(QT_CONFIG, no-widgets): TOOLS_SUBDIRS += src_tools_uic
-# Set subdir and respective target name
-src_tools_bootstrap.subdir = bootstrap
-src_tools_bootstrap.target = sub-tools-bootstrap
-src_tools_moc.subdir = moc
-src_tools_moc.target = sub-moc
-src_tools_rcc.subdir = rcc
-src_tools_rcc.target = sub-rcc
-src_tools_uic.subdir = uic
-src_tools_uic.target = sub-uic
-src_tools_qdoc.subdir = qdoc
-src_tools_qdoc.target = sub-qdoc
-contains(QT_CONFIG, dbus) {
- src_tools_qdbusxml2cpp.subdir = qdbusxml2cpp
- src_tools_qdbusxml2cpp.target = sub-qdbusxml2cpp
- src_tools_qdbuscpp2xml.subdir = qdbuscpp2xml
- src_tools_qdbuscpp2xml.target = sub-qdbuscpp2xml
-}
-
-!ordered {
- # Set dependencies for each subdir
- src_tools_moc.depends = src_tools_bootstrap
- src_tools_rcc.depends = src_tools_bootstrap
- src_tools_uic.depends = src_tools_bootstrap
- src_tools_qdoc.depends = src_tools_bootstrap
- contains(QT_CONFIG, dbus) {
- src_tools_qdbusxml2cpp.depends = src_tools_bootstrap
- src_tools_qdbuscpp2xml.depends = src_tools_bootstrap
- }
-}
-
-SUBDIRS = $$TOOLS_SUBDIRS
-
-# Ensure qdoc is built before making any docs. We rely on the existing dependency
-# on bootstrap for each of the other tools to ensure they also build qdoc first,
-# and likewise, the dependency of the rest of the build on tools, src, etc.
-bootstrap_prepare_docs.depends += $${src_tools_qdoc.target}-make_first
-bootstrap_prepare_docs.target = $${src_tools_bootstrap.target}-prepare_docs
-QMAKE_EXTRA_TARGETS += bootstrap_prepare_docs
diff --git a/src/tools/uic/cpp/cppwriteincludes.cpp b/src/tools/uic/cpp/cppwriteincludes.cpp
index 44049409de..c473566e3a 100644
--- a/src/tools/uic/cpp/cppwriteincludes.cpp
+++ b/src/tools/uic/cpp/cppwriteincludes.cpp
@@ -88,8 +88,8 @@ WriteIncludes::WriteIncludes(Uic *uic)
// and create a re-mapping of the old header "qclass.h" to it. Do not do this
// for the "Phonon::Someclass" classes, however.
const QString namespaceDelimiter = QLatin1String("::");
- const ClassInfoEntry *classLibEnd = qclass_lib_map + sizeof(qclass_lib_map)/sizeof(ClassInfoEntry);
- for(const ClassInfoEntry *it = qclass_lib_map; it < classLibEnd; ++it) {
+ const ClassInfoEntry *classLibEnd = qclass_lib_map + sizeof(qclass_lib_map)/sizeof(ClassInfoEntry);
+ for (const ClassInfoEntry *it = qclass_lib_map; it < classLibEnd; ++it) {
const QString klass = QLatin1String(it->klass);
const QString module = QLatin1String(it->module);
QLatin1String header = QLatin1String(it->header);
@@ -173,7 +173,7 @@ void WriteIncludes::insertIncludeForClass(const QString &className, QString head
if (!header.isEmpty())
break;
- // Known class
+ // Known class
const StringMap::const_iterator it = m_classToHeader.constFind(className);
if (it != m_classToHeader.constEnd()) {
header = it.value();
diff --git a/src/tools/uic/customwidgetsinfo.h b/src/tools/uic/customwidgetsinfo.h
index 5e6405807d..d4ac02aba9 100644
--- a/src/tools/uic/customwidgetsinfo.h
+++ b/src/tools/uic/customwidgetsinfo.h
@@ -83,7 +83,6 @@ public:
private:
typedef QMap<QString, DomCustomWidget*> NameCustomWidgetMap;
NameCustomWidgetMap m_customWidgets;
- bool m_scriptsActivated;
};
QT_END_NAMESPACE
diff --git a/src/tools/uic/driver.cpp b/src/tools/uic/driver.cpp
index 9fc1a649ef..5c99ffb208 100644
--- a/src/tools/uic/driver.cpp
+++ b/src/tools/uic/driver.cpp
@@ -304,7 +304,7 @@ bool Driver::uic(const QString &fileName, QTextStream *out)
m_output = out;
} else {
#ifdef Q_OS_WIN
- // As one might also redirect the output to a file on win,
+ // As one might also redirect the output to a file on win,
// we should not create the textstream with QFile::Text flag.
// The redirected file is opened in TextMode and this will
// result in broken line endings as writing will replace \n again.
diff --git a/src/tools/uic/qclass_lib_map.h b/src/tools/uic/qclass_lib_map.h
index 1b13850817..6859cd0cd4 100644
--- a/src/tools/uic/qclass_lib_map.h
+++ b/src/tools/uic/qclass_lib_map.h
@@ -556,24 +556,6 @@ QT_CLASS_LIB(QSqlRelationalDelegate, QtSql, qsqlrelationaldelegate.h)
QT_CLASS_LIB(QSqlRelation, QtSql, qsqlrelationaltablemodel.h)
QT_CLASS_LIB(QSqlRelationalTableModel, QtSql, qsqlrelationaltablemodel.h)
QT_CLASS_LIB(QSqlTableModel, QtSql, qsqltablemodel.h)
-QT_CLASS_LIB(QDB2Result, QtSql, qsql_db2.h)
-QT_CLASS_LIB(QDB2Driver, QtSql, qsql_db2.h)
-QT_CLASS_LIB(QIBaseResult, QtSql, qsql_ibase.h)
-QT_CLASS_LIB(QIBaseDriver, QtSql, qsql_ibase.h)
-QT_CLASS_LIB(QMYSQLResult, QtSql, qsql_mysql.h)
-QT_CLASS_LIB(QMYSQLDriver, QtSql, qsql_mysql.h)
-QT_CLASS_LIB(QOCIResult, QtSql, qsql_oci.h)
-QT_CLASS_LIB(QOCIDriver, QtSql, qsql_oci.h)
-QT_CLASS_LIB(QODBCResult, QtSql, qsql_odbc.h)
-QT_CLASS_LIB(QODBCDriver, QtSql, qsql_odbc.h)
-QT_CLASS_LIB(QPSQLResult, QtSql, qsql_psql.h)
-QT_CLASS_LIB(QPSQLDriver, QtSql, qsql_psql.h)
-QT_CLASS_LIB(QSQLiteResult, QtSql, qsql_sqlite.h)
-QT_CLASS_LIB(QSQLiteDriver, QtSql, qsql_sqlite.h)
-QT_CLASS_LIB(QSQLite2Result, QtSql, qsql_sqlite2.h)
-QT_CLASS_LIB(QSQLite2Driver, QtSql, qsql_sqlite2.h)
-QT_CLASS_LIB(QTDSResult, QtSql, qsql_tds.h)
-QT_CLASS_LIB(QTDSDriver, QtSql, qsql_tds.h)
QT_CLASS_LIB(QAccessible, QtWidgets, qaccessible.h)
QT_CLASS_LIB(QAccessibleInterface, QtWidgets, qaccessible.h)
QT_CLASS_LIB(QAccessibleInterfaceEx, QtWidgets, qaccessible.h)
diff --git a/src/widgets/QtGui.dynlist b/src/widgets/QtGui.dynlist
deleted file mode 100644
index ea47f598a7..0000000000
--- a/src/widgets/QtGui.dynlist
+++ /dev/null
@@ -1,8 +0,0 @@
-{
- extern "C++" {
- "qt_x11ft_convert_pattern(_FcPattern*, QByteArray*, int*, bool*)";
- "QApplication::x11ClientMessage(QWidget*, _XEvent*, bool)";
- "QApplication::notify(QObject*, QEvent*)";
- "QApplication::qwsEventFilter(QWSEvent*)";
- };
-};
diff --git a/src/widgets/QtWidgets.dynlist b/src/widgets/QtWidgets.dynlist
new file mode 100644
index 0000000000..94fd207dde
--- /dev/null
+++ b/src/widgets/QtWidgets.dynlist
@@ -0,0 +1,5 @@
+{
+ extern "C++" {
+ "QApplication::notify(QObject*, QEvent*)";
+ };
+};
diff --git a/src/widgets/accessible/accessible.pri b/src/widgets/accessible/accessible.pri
index 9fb2f18950..84d366e78a 100644
--- a/src/widgets/accessible/accessible.pri
+++ b/src/widgets/accessible/accessible.pri
@@ -1,6 +1,6 @@
# Qt accessibility module
contains(QT_CONFIG, accessibility) {
- HEADERS += accessible/qaccessiblewidget.h
+ HEADERS += accessible/qaccessiblewidget_p.h
SOURCES += accessible/qaccessiblewidget.cpp
}
diff --git a/src/widgets/accessible/qaccessiblewidget.cpp b/src/widgets/accessible/qaccessiblewidget.cpp
index bed0480059..dcbf276356 100644
--- a/src/widgets/accessible/qaccessiblewidget.cpp
+++ b/src/widgets/accessible/qaccessiblewidget.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include "qaccessiblewidget.h"
+#include "qaccessiblewidget_p.h"
#ifndef QT_NO_ACCESSIBILITY
@@ -55,6 +55,7 @@
#include <QRubberBand>
#include <QFocusFrame>
#include <QMenu>
+#include <QtWidgets/private/qwidget_p.h>
QT_BEGIN_NAMESPACE
@@ -64,7 +65,7 @@ static QList<QWidget*> childWidgets(const QWidget *widget)
QList<QWidget*> widgets;
for (int i = 0; i < list.size(); ++i) {
QWidget *w = qobject_cast<QWidget *>(list.at(i));
- if (w && !w->isWindow()
+ if (w && !w->isWindow()
&& !qobject_cast<QFocusFrame*>(w)
#if !defined(QT_NO_MENU)
&& !qobject_cast<QMenu*>(w)
@@ -152,6 +153,7 @@ QString Q_WIDGETS_EXPORT qt_accHotKey(const QString &text)
return QString();
}
+// ### inherit QAccessibleObjectPrivate
class QAccessibleWidgetPrivate
{
public:
@@ -202,9 +204,17 @@ QAccessibleWidget::QAccessibleWidget(QWidget *w, QAccessible::Role role, const Q
d->name = name;
}
+bool QAccessibleWidget::isValid() const
+{
+ if (!object() || static_cast<QWidget *>(object())->d_func()->data.in_destructor)
+ return false;
+ return QAccessibleObject::isValid();
+}
+
/*! \reimp */
QWindow *QAccessibleWidget::window() const
{
+ Q_ASSERT(widget());
return widget()->windowHandle();
}
@@ -343,6 +353,7 @@ QAccessibleWidget::relations(QAccessible::Relation match /*= QAccessible::AllRel
/*! \reimp */
QAccessibleInterface *QAccessibleWidget::parent() const
{
+ Q_ASSERT(widget());
QObject *parentWidget= widget()->parentWidget();
if (!parentWidget)
parentWidget = qApp;
@@ -352,6 +363,7 @@ QAccessibleInterface *QAccessibleWidget::parent() const
/*! \reimp */
QAccessibleInterface *QAccessibleWidget::child(int index) const
{
+ Q_ASSERT(widget());
QWidgetList childList = childWidgets(widget());
if (index >= 0 && index < childList.size())
return QAccessible::queryAccessibleInterface(childList.at(index));
@@ -383,6 +395,8 @@ int QAccessibleWidget::childCount() const
/*! \reimp */
int QAccessibleWidget::indexOfChild(const QAccessibleInterface *child) const
{
+ if (!child)
+ return -1;
QWidgetList cl = childWidgets(widget());
return cl.indexOf(qobject_cast<QWidget *>(child->object()));
}
diff --git a/src/widgets/accessible/qaccessiblewidget.h b/src/widgets/accessible/qaccessiblewidget_p.h
index 5e43f201cb..cb1ce37734 100644
--- a/src/widgets/accessible/qaccessiblewidget.h
+++ b/src/widgets/accessible/qaccessiblewidget_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -43,8 +43,7 @@
#define QACCESSIBLEWIDGET_H
#include <QtGui/qaccessibleobject.h>
-
-QT_BEGIN_HEADER
+#include <QtGui/private/qaccessible2_p.h>
QT_BEGIN_NAMESPACE
@@ -57,6 +56,7 @@ class Q_WIDGETS_EXPORT QAccessibleWidget : public QAccessibleObject, public QAcc
{
public:
explicit QAccessibleWidget(QWidget *o, QAccessible::Role r = QAccessible::Client, const QString& name = QString());
+ bool isValid() const;
QWindow *window() const;
int childCount() const;
@@ -99,6 +99,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QACCESSIBLEWIDGET_H
diff --git a/src/widgets/dialogs/qcolordialog.cpp b/src/widgets/dialogs/qcolordialog.cpp
index af43ecc8df..d6254076c5 100644
--- a/src/widgets/dialogs/qcolordialog.cpp
+++ b/src/widgets/dialogs/qcolordialog.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -1857,15 +1857,12 @@ void QColorDialog::setVisible(bool visible)
}
#else
- if (!(options() & DontUseNativeDialog))
+ if (!(options() & DontUseNativeDialog) && d->nativeDialogInUse) {
d->setNativeDialogVisible(visible);
-
- if (d->nativeDialogInUse) {
// Set WA_DontShowOnScreen so that QDialog::setVisible(visible) below
// updates the state correctly, but skips showing the non-native version:
setAttribute(Qt::WA_DontShowOnScreen);
} else {
- d->nativeDialogInUse = false;
setAttribute(Qt::WA_DontShowOnScreen, false);
}
#endif
diff --git a/src/widgets/dialogs/qcolordialog.h b/src/widgets/dialogs/qcolordialog.h
index 2149c9c6d2..80a31c4268 100644
--- a/src/widgets/dialogs/qcolordialog.h
+++ b/src/widgets/dialogs/qcolordialog.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qdialog.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -133,6 +131,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QColorDialog::ColorDialogOptions)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOLORDIALOG_H
diff --git a/src/widgets/dialogs/qcolordialog_p.h b/src/widgets/dialogs/qcolordialog_p.h
index 6711ba9287..900b38fc61 100644
--- a/src/widgets/dialogs/qcolordialog_p.h
+++ b/src/widgets/dialogs/qcolordialog_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qdialog.cpp b/src/widgets/dialogs/qdialog.cpp
index e397ed4576..a76c88dc5e 100644
--- a/src/widgets/dialogs/qdialog.cpp
+++ b/src/widgets/dialogs/qdialog.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qdialog.h b/src/widgets/dialogs/qdialog.h
index eeb0ac56b5..efbc475118 100644
--- a/src/widgets/dialogs/qdialog.h
+++ b/src/widgets/dialogs/qdialog.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -125,6 +123,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDIALOG_H
diff --git a/src/widgets/dialogs/qdialog_p.h b/src/widgets/dialogs/qdialog_p.h
index 3ef210045e..eb0cb2372b 100644
--- a/src/widgets/dialogs/qdialog_p.h
+++ b/src/widgets/dialogs/qdialog_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qerrormessage.cpp b/src/widgets/dialogs/qerrormessage.cpp
index 6cb5888a75..cc79582cb0 100644
--- a/src/widgets/dialogs/qerrormessage.cpp
+++ b/src/widgets/dialogs/qerrormessage.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qerrormessage.h b/src/widgets/dialogs/qerrormessage.h
index 4bba3131c9..6be063b57b 100644
--- a/src/widgets/dialogs/qerrormessage.h
+++ b/src/widgets/dialogs/qerrormessage.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qdialog.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -79,6 +77,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QERRORMESSAGE_H
diff --git a/src/widgets/dialogs/qfiledialog.cpp b/src/widgets/dialogs/qfiledialog.cpp
index c60f2476c3..c42752311f 100644
--- a/src/widgets/dialogs/qfiledialog.cpp
+++ b/src/widgets/dialogs/qfiledialog.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -941,7 +941,9 @@ Q_AUTOTEST_EXPORT QString qt_tildeExpansion(const QString &path, bool *expanded
} else {
QString userName = tokens.first();
userName.remove(0, 1);
-#if defined(_POSIX_THREAD_SAFE_FUNCTIONS) && !defined(Q_OS_OPENBSD)
+#if defined(Q_OS_VXWORKS)
+ const QString homePath = QDir::homePath();
+#elif defined(_POSIX_THREAD_SAFE_FUNCTIONS) && !defined(Q_OS_OPENBSD)
passwd pw;
passwd *tmpPw;
char buf[200];
diff --git a/src/widgets/dialogs/qfiledialog.h b/src/widgets/dialogs/qfiledialog.h
index 18aaa781fd..98d1fd5695 100644
--- a/src/widgets/dialogs/qfiledialog.h
+++ b/src/widgets/dialogs/qfiledialog.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtCore/qstring.h>
#include <QtWidgets/qdialog.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -265,6 +263,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QFileDialog::Options)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFILEDIALOG_H
diff --git a/src/widgets/dialogs/qfiledialog.ui b/src/widgets/dialogs/qfiledialog.ui
index fa4fa4cdf5..89adaf530e 100644
--- a/src/widgets/dialogs/qfiledialog.ui
+++ b/src/widgets/dialogs/qfiledialog.ui
@@ -5,7 +5,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -90,6 +90,9 @@
<property name="accessibleDescription">
<string>Go back</string>
</property>
+ <property name="shortcut">
+ <string>Alt+Left</string>
+ </property>
</widget>
</item>
<item>
@@ -103,6 +106,9 @@
<property name="accessibleDescription">
<string>Go forward</string>
</property>
+ <property name="shortcut">
+ <string>Alt+Right</string>
+ </property>
</widget>
</item>
<item>
@@ -116,6 +122,9 @@
<property name="accessibleDescription">
<string>Go to the parent directory</string>
</property>
+ <property name="shortcut">
+ <string>Alt+Up</string>
+ </property>
</widget>
</item>
<item>
diff --git a/src/widgets/dialogs/qfiledialog_embedded.ui b/src/widgets/dialogs/qfiledialog_embedded.ui
index 5988211aea..16128dc0a0 100644
--- a/src/widgets/dialogs/qfiledialog_embedded.ui
+++ b/src/widgets/dialogs/qfiledialog_embedded.ui
@@ -4,7 +4,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qfiledialog_p.h b/src/widgets/dialogs/qfiledialog_p.h
index ffaa2bc6f8..f8f33eb18d 100644
--- a/src/widgets/dialogs/qfiledialog_p.h
+++ b/src/widgets/dialogs/qfiledialog_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -53,6 +53,8 @@
// We mean it.
//
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_FILEDIALOG
#include "qfiledialog.h"
diff --git a/src/widgets/dialogs/qfileinfogatherer.cpp b/src/widgets/dialogs/qfileinfogatherer.cpp
index fc86576f55..213aefe5f5 100644
--- a/src/widgets/dialogs/qfileinfogatherer.cpp
+++ b/src/widgets/dialogs/qfileinfogatherer.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -238,7 +238,7 @@ QExtendedInformation QFileInfoGatherer::getInfo(const QFileInfo &fileInfo) const
#endif
#ifdef Q_OS_WIN
- if (fileInfo.isSymLink() && m_resolveSymlinks) {
+ if (m_resolveSymlinks && fileInfo.isSymLink()) {
QFileInfo resolvedInfo(fileInfo.symLinkTarget());
resolvedInfo = resolvedInfo.canonicalFilePath();
if (resolvedInfo.exists()) {
diff --git a/src/widgets/dialogs/qfileinfogatherer_p.h b/src/widgets/dialogs/qfileinfogatherer_p.h
index f9566eb0af..0c4e644e40 100644
--- a/src/widgets/dialogs/qfileinfogatherer_p.h
+++ b/src/widgets/dialogs/qfileinfogatherer_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qfilesystemmodel.cpp b/src/widgets/dialogs/qfilesystemmodel.cpp
index 4d3c7a24ec..9556c0ed15 100644
--- a/src/widgets/dialogs/qfilesystemmodel.cpp
+++ b/src/widgets/dialogs/qfilesystemmodel.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -800,7 +800,7 @@ QString QFileSystemModelPrivate::name(const QModelIndex &index) const
if (!index.isValid())
return QString();
QFileSystemNode *dirNode = node(index);
- if (dirNode->isSymLink() && fileInfoGatherer.resolveSymlinks()) {
+ if (fileInfoGatherer.resolveSymlinks() && !resolvedSymLinks.isEmpty() && dirNode->isSymLink()) {
QString fullPath = QDir::fromNativeSeparators(filePath(index));
if (resolvedSymLinks.contains(fullPath))
return resolvedSymLinks[fullPath];
@@ -964,6 +964,8 @@ Qt::ItemFlags QFileSystemModel::flags(const QModelIndex &index) const
flags |= Qt::ItemIsEditable;
if (indexNode->isDir())
flags |= Qt::ItemIsDropEnabled;
+ else
+ flags |= Qt::ItemNeverHasChildren;
}
return flags;
}
@@ -1520,9 +1522,9 @@ QDir::Filters QFileSystemModel::filter() const
\property QFileSystemModel::resolveSymlinks
\brief Whether the directory model should resolve symbolic links
- This is only relevant on operating systems that support symbolic links.
+ This is only relevant on Windows.
- By default, this property is false.
+ By default, this property is true.
*/
void QFileSystemModel::setResolveSymlinks(bool enable)
{
diff --git a/src/widgets/dialogs/qfilesystemmodel.h b/src/widgets/dialogs/qfilesystemmodel.h
index 18df89d736..0b52b6565b 100644
--- a/src/widgets/dialogs/qfilesystemmodel.h
+++ b/src/widgets/dialogs/qfilesystemmodel.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -48,8 +48,6 @@
#include <QtGui/qicon.h>
#include <QtCore/qdiriterator.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -173,7 +171,5 @@ inline QFileInfo QFileSystemModel::fileInfo(const QModelIndex &aindex) const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFILESYSTEMMODEL_H
diff --git a/src/widgets/dialogs/qfilesystemmodel_p.h b/src/widgets/dialogs/qfilesystemmodel_p.h
index 4f5eeb9ff7..d61936d545 100644
--- a/src/widgets/dialogs/qfilesystemmodel_p.h
+++ b/src/widgets/dialogs/qfilesystemmodel_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qfontdialog.cpp b/src/widgets/dialogs/qfontdialog.cpp
index 4036dc80ab..313b475f1f 100644
--- a/src/widgets/dialogs/qfontdialog.cpp
+++ b/src/widgets/dialogs/qfontdialog.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qfontdialog.h b/src/widgets/dialogs/qfontdialog.h
index 51d68d1b88..c2d930bc1e 100644
--- a/src/widgets/dialogs/qfontdialog.h
+++ b/src/widgets/dialogs/qfontdialog.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtWidgets/qdialog.h>
#include <QtGui/qfont.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -126,6 +124,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QFontDialog::FontDialogOptions)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFONTDIALOG_H
diff --git a/src/widgets/dialogs/qfontdialog_p.h b/src/widgets/dialogs/qfontdialog_p.h
index 90b6a6eff8..18429e8ede 100644
--- a/src/widgets/dialogs/qfontdialog_p.h
+++ b/src/widgets/dialogs/qfontdialog_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qfscompleter_p.h b/src/widgets/dialogs/qfscompleter_p.h
index 9099ea1a5e..e995114ee9 100644
--- a/src/widgets/dialogs/qfscompleter_p.h
+++ b/src/widgets/dialogs/qfscompleter_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qinputdialog.cpp b/src/widgets/dialogs/qinputdialog.cpp
index 99ecf02bdb..a0aefdef9d 100644
--- a/src/widgets/dialogs/qinputdialog.cpp
+++ b/src/widgets/dialogs/qinputdialog.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qinputdialog.h b/src/widgets/dialogs/qinputdialog.h
index 096a81d4bc..41dca1f94f 100644
--- a/src/widgets/dialogs/qinputdialog.h
+++ b/src/widgets/dialogs/qinputdialog.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtCore/qstring.h>
#include <QtWidgets/qlineedit.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -215,6 +213,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QInputDialog::InputDialogOptions)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QINPUTDIALOG_H
diff --git a/src/widgets/dialogs/qmessagebox.cpp b/src/widgets/dialogs/qmessagebox.cpp
index 57ed4da8a6..a485a55609 100644
--- a/src/widgets/dialogs/qmessagebox.cpp
+++ b/src/widgets/dialogs/qmessagebox.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -1225,6 +1225,30 @@ void QMessageBox::setTextFormat(Qt::TextFormat format)
}
/*!
+ \property QMessageBox::textInteractionFlags
+ \since 5.1
+
+ Specifies how the label of the message box should interact with user
+ input.
+
+ The default value depends on the style.
+
+ \sa QStyle::SH_MessageBox_TextInteractionFlags
+*/
+
+Qt::TextInteractionFlags QMessageBox::textInteractionFlags() const
+{
+ Q_D(const QMessageBox);
+ return d->label->textInteractionFlags();
+}
+
+void QMessageBox::setTextInteractionFlags(Qt::TextInteractionFlags flags)
+{
+ Q_D(QMessageBox);
+ d->label->setTextInteractionFlags(flags);
+}
+
+/*!
\reimp
*/
bool QMessageBox::event(QEvent *e)
diff --git a/src/widgets/dialogs/qmessagebox.h b/src/widgets/dialogs/qmessagebox.h
index e0eb47ea2a..32b7027d89 100644
--- a/src/widgets/dialogs/qmessagebox.h
+++ b/src/widgets/dialogs/qmessagebox.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qdialog.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -69,6 +67,7 @@ class Q_WIDGETS_EXPORT QMessageBox : public QDialog
Q_PROPERTY(QString detailedText READ detailedText WRITE setDetailedText)
#endif
Q_PROPERTY(QString informativeText READ informativeText WRITE setInformativeText)
+ Q_PROPERTY(Qt::TextInteractionFlags textInteractionFlags READ textInteractionFlags WRITE setTextInteractionFlags)
public:
enum Icon {
@@ -186,6 +185,9 @@ public:
Qt::TextFormat textFormat() const;
void setTextFormat(Qt::TextFormat format);
+ void setTextInteractionFlags(Qt::TextInteractionFlags flags);
+ Qt::TextInteractionFlags textInteractionFlags() const;
+
static StandardButton information(QWidget *parent, const QString &title,
const QString &text, StandardButtons buttons = Ok,
StandardButton defaultButton = NoButton);
@@ -329,6 +331,4 @@ str)).arg(QString::fromLatin1(qVersion())); QMessageBox::critical(0, QApplicatio
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMESSAGEBOX_H
diff --git a/src/widgets/dialogs/qprogressdialog.cpp b/src/widgets/dialogs/qprogressdialog.cpp
index de86e2ed7c..78612f3181 100644
--- a/src/widgets/dialogs/qprogressdialog.cpp
+++ b/src/widgets/dialogs/qprogressdialog.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -297,7 +297,7 @@ QProgressDialog::QProgressDialog(QWidget *parent, Qt::WindowFlags f)
The \a labelText is the text used to remind the user what is progressing.
- The \a cancelButtonText is the text to display on the cancel button. If
+ The \a cancelButtonText is the text to display on the cancel button. If
QString() is passed then no cancel button is shown.
The \a minimum and \a maximum is the number of steps in the operation for
@@ -438,7 +438,7 @@ void QProgressDialog::setCancelButton(QPushButton *cancelButton)
/*!
Sets the cancel button's text to \a cancelButtonText. If the text
- is set to QString() then it will cause the cancel button to be
+ is set to QString() then it will cause the cancel button to be
hidden and deleted.
\sa setCancelButton()
diff --git a/src/widgets/dialogs/qprogressdialog.h b/src/widgets/dialogs/qprogressdialog.h
index 1f17727900..20b658eb58 100644
--- a/src/widgets/dialogs/qprogressdialog.h
+++ b/src/widgets/dialogs/qprogressdialog.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qdialog.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -139,6 +137,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPROGRESSDIALOG_H
diff --git a/src/widgets/dialogs/qsidebar.cpp b/src/widgets/dialogs/qsidebar.cpp
index 37bcc62425..3d22992e3a 100644
--- a/src/widgets/dialogs/qsidebar.cpp
+++ b/src/widgets/dialogs/qsidebar.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qsidebar_p.h b/src/widgets/dialogs/qsidebar_p.h
index 72d632280c..319006f167 100644
--- a/src/widgets/dialogs/qsidebar_p.h
+++ b/src/widgets/dialogs/qsidebar_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/dialogs/qwizard.cpp b/src/widgets/dialogs/qwizard.cpp
index 8bc2eb92c1..3f214809b4 100644
--- a/src/widgets/dialogs/qwizard.cpp
+++ b/src/widgets/dialogs/qwizard.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -54,6 +54,7 @@
#include "qlabel.h"
#include "qlineedit.h"
#include "qpainter.h"
+#include "qwindow.h"
#include "qpushbutton.h"
#include "qset.h"
#include "qstyle.h"
@@ -506,16 +507,18 @@ void QWizardPagePrivate::_q_updateCachedCompleteState()
class QWizardAntiFlickerWidget : public QWidget
{
- QWizard *wizard;
- QWizardPrivate *wizardPrivate;
public:
+#if !defined(QT_NO_STYLE_WINDOWSVISTA)
+ QWizardPrivate *wizardPrivate;
QWizardAntiFlickerWidget(QWizard *wizard, QWizardPrivate *wizardPrivate)
: QWidget(wizard)
- , wizard(wizard)
, wizardPrivate(wizardPrivate) {}
-#if !defined(QT_NO_STYLE_WINDOWSVISTA)
protected:
void paintEvent(QPaintEvent *);
+#else
+ QWizardAntiFlickerWidget(QWizard *wizard, QWizardPrivate *)
+ : QWidget(wizard)
+ {}
#endif
};
@@ -592,7 +595,7 @@ public:
#if !defined(QT_NO_STYLE_WINDOWSVISTA)
bool vistaDisabled() const;
bool isVistaThemeEnabled(QVistaHelper::VistaState state) const;
- void handleAeroStyleChange();
+ bool handleAeroStyleChange();
#endif
bool isVistaThemeEnabled() const;
void disableUpdates();
@@ -1514,33 +1517,48 @@ bool QWizardPrivate::isVistaThemeEnabled(QVistaHelper::VistaState state) const
&& !vistaDisabled();
}
-void QWizardPrivate::handleAeroStyleChange()
+bool QWizardPrivate::handleAeroStyleChange()
{
Q_Q(QWizard);
if (inHandleAeroStyleChange)
- return; // prevent recursion
+ return false; // prevent recursion
+ // For top-level wizards, we need the platform window handle for the
+ // DWM changes. Delay aero initialization to the show event handling if
+ // it does not exist. If we are a child, skip DWM and just make room by
+ // moving the antiFlickerWidget.
+ const bool isWindow = q->isWindow();
+ if (isWindow && (!q->windowHandle() || !q->windowHandle()->handle()))
+ return false;
inHandleAeroStyleChange = true;
vistaHelper->disconnectBackButton();
q->removeEventFilter(vistaHelper);
+ bool vistaMargins = false;
+
if (isVistaThemeEnabled()) {
if (isVistaThemeEnabled(QVistaHelper::VistaAero)) {
- vistaHelper->setDWMTitleBar(QVistaHelper::ExtendedTitleBar);
- q->installEventFilter(vistaHelper);
+ if (isWindow) {
+ vistaHelper->setDWMTitleBar(QVistaHelper::ExtendedTitleBar);
+ q->installEventFilter(vistaHelper);
+ }
q->setMouseTracking(true);
antiFlickerWidget->move(0, vistaHelper->titleBarSize() + vistaHelper->topOffset());
vistaHelper->backButton()->move(
0, vistaHelper->topOffset() // ### should ideally work without the '+ 1'
- qMin(vistaHelper->topOffset(), vistaHelper->topPadding() + 1));
+ vistaMargins = true;
+ vistaHelper->backButton()->show();
} else {
- vistaHelper->setDWMTitleBar(QVistaHelper::NormalTitleBar);
+ if (isWindow)
+ vistaHelper->setDWMTitleBar(QVistaHelper::NormalTitleBar);
q->setMouseTracking(true);
antiFlickerWidget->move(0, vistaHelper->topOffset());
vistaHelper->backButton()->move(0, -1); // ### should ideally work with (0, 0)
}
- vistaHelper->setTitleBarIconAndCaptionVisible(false);
+ if (isWindow)
+ vistaHelper->setTitleBarIconAndCaptionVisible(false);
QObject::connect(
vistaHelper->backButton(), SIGNAL(clicked()), q, buttonSlots[QWizard::BackButton]);
vistaHelper->backButton()->show();
@@ -1551,15 +1569,16 @@ void QWizardPrivate::handleAeroStyleChange()
#endif
antiFlickerWidget->move(0, 0);
vistaHelper->hideBackButton();
- vistaHelper->setTitleBarIconAndCaptionVisible(true);
+ if (isWindow)
+ vistaHelper->setTitleBarIconAndCaptionVisible(true);
}
_q_updateButtonStates();
- if (q->isVisible())
- vistaHelper->setWindowPosHack();
+ vistaHelper->updateCustomMargins(vistaMargins);
inHandleAeroStyleChange = false;
+ return true;
}
#endif
@@ -1917,7 +1936,7 @@ void QWizardAntiFlickerWidget::paintEvent(QPaintEvent *)
Here, we call QWizardPage::field() to access the contents of the
\c className field (which was defined in the \c ClassInfoPage)
- and use it to initialize the \c OuputFilePage. The field's
+ and use it to initialize the \c OutputFilePage. The field's
contents is returned as a QVariant.
When we create a field using QWizardPage::registerField(), we
@@ -2507,8 +2526,9 @@ void QWizard::setWizardStyle(WizardStyle style)
updateGeometry();
d->enableUpdates();
#if !defined(QT_NO_STYLE_WINDOWSVISTA)
- if (aeroStyleChange)
- d->handleAeroStyleChange();
+ // Delay initialization when activating Aero style fails due to missing native window.
+ if (aeroStyleChange && !d->handleAeroStyleChange() && d->wizStyle == AeroStyle)
+ d->vistaInitPending = true;
#endif
}
}
@@ -3111,6 +3131,16 @@ bool QWizard::event(QEvent *event)
d->handleAeroStyleChange();
}
else if (d->isVistaThemeEnabled()) {
+ if (event->type() == QEvent::Resize
+ || event->type() == QEvent::LayoutDirectionChange) {
+ const int buttonLeft = (layoutDirection() == Qt::RightToLeft
+ ? width() - d->vistaHelper->backButton()->sizeHint().width()
+ : 0);
+
+ d->vistaHelper->backButton()->move(buttonLeft,
+ d->vistaHelper->backButton()->y());
+ }
+
d->vistaHelper->mouseEvent(event);
}
#endif
diff --git a/src/widgets/dialogs/qwizard.h b/src/widgets/dialogs/qwizard.h
index 7a95492f94..9dea9a8e6f 100644
--- a/src/widgets/dialogs/qwizard.h
+++ b/src/widgets/dialogs/qwizard.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qdialog.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -261,8 +259,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_WIZARD
#endif // QWIZARD_H
diff --git a/src/widgets/dialogs/qwizard_win.cpp b/src/widgets/dialogs/qwizard_win.cpp
index 2bcb7a2167..b57614c018 100644
--- a/src/widgets/dialogs/qwizard_win.cpp
+++ b/src/widgets/dialogs/qwizard_win.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -49,7 +49,10 @@
#include "qwizard.h"
#include "qpaintengine.h"
#include "qapplication.h"
+#include <QtCore/QVariant>
+#include <QtCore/QDebug>
#include <QtGui/QMouseEvent>
+#include <QtGui/QWindow>
#include <QtWidgets/QDesktopWidget>
// Note, these tests are duplicates in qwindowsxpstyle_p.h.
@@ -66,10 +69,12 @@
#include <uxtheme.h>
+Q_DECLARE_METATYPE(QMargins)
+
QT_BEGIN_NAMESPACE
//DWM related
-typedef struct { //MARGINS
+typedef struct { //MARGINS
int cxLeftWidth; // width of left border that retains its size
int cxRightWidth; // width of right border that retains its size
int cyTopHeight; // height of top border that retains its size
@@ -216,9 +221,11 @@ void QVistaBackButton::paintEvent(QPaintEvent *)
QRect r = rect();
HANDLE theme = pOpenThemeData(0, L"Navigation");
//RECT rect;
+ QPoint origin;
+ const HDC hdc = QVistaHelper::backingStoreDC(parentWidget(), &origin);
RECT clipRect;
- int xoffset = QWidget::mapToParent(r.topLeft()).x() - 1;
- int yoffset = QWidget::mapToParent(r.topLeft()).y() - 1;
+ int xoffset = origin.x() + QWidget::mapToParent(r.topLeft()).x() - 1;
+ int yoffset = origin.y() + QWidget::mapToParent(r.topLeft()).y() - 1;
clipRect.top = r.top() + yoffset;
clipRect.bottom = r.bottom() + yoffset;
@@ -233,9 +240,11 @@ void QVistaBackButton::paintEvent(QPaintEvent *)
else if (underMouse())
state = WIZ_NAV_BB_HOT;
- QPlatformNativeInterface *nativeInterface = QGuiApplication::platformNativeInterface();
- HDC hdc = static_cast<HDC>(nativeInterface->nativeResourceForBackingStore("getDC", backingStore()));
- pDrawThemeBackground(theme, hdc, WIZ_NAV_BACKBUTTON, state, &clipRect, &clipRect);
+ WIZ_NAVIGATIONPARTS buttonType = (layoutDirection() == Qt::LeftToRight
+ ? WIZ_NAV_BACKBUTTON
+ : WIZ_NAV_FORWARDBUTTON);
+
+ pDrawThemeBackground(theme, hdc, buttonType, state, &clipRect, &clipRect);
}
/******************************************************************************
@@ -251,8 +260,10 @@ QVistaHelper::QVistaHelper(QWizard *wizard)
is_vista = resolveSymbols();
if (instanceCount++ == 0)
cachedVistaState = Dirty;
- if (is_vista)
+ if (is_vista) {
backButton_ = new QVistaBackButton(wizard);
+ backButton_->hide();
+ }
// Handle diff between Windows 7 and Vista
iconSpacing = QStyleHelper::dpiScaled(7);
@@ -265,6 +276,26 @@ QVistaHelper::~QVistaHelper()
--instanceCount;
}
+void QVistaHelper::updateCustomMargins(bool vistaMargins)
+{
+ if (QSysInfo::WindowsVersion >= QSysInfo::WV_WINDOWS8)
+ return; // Negative margins are not supported on Windows 8.
+ if (QWindow *window = wizard->windowHandle()) {
+ // Reduce top frame to zero since we paint it ourselves.
+ const QMargins customMargins = vistaMargins ?
+ QMargins(0, -titleBarSize(), 0, 0) : QMargins();
+ const QVariant customMarginsV = qVariantFromValue(customMargins);
+ // The dynamic property takes effect when creating the platform window.
+ window->setProperty("_q_windowsCustomMargins", customMarginsV);
+ // If a platform window exists, change via native interface.
+ if (QPlatformWindow *platformWindow = window->handle()) {
+ QGuiApplication::platformNativeInterface()->
+ setWindowProperty(platformWindow, QStringLiteral("WindowsCustomMargins"),
+ customMarginsV);
+ }
+ }
+}
+
bool QVistaHelper::isCompositionEnabled()
{
bool value = is_vista;
@@ -291,6 +322,12 @@ QVistaHelper::VistaState QVistaHelper::vistaState()
return cachedVistaState;
}
+void QVistaHelper::disconnectBackButton()
+{
+ if (backButton_) // Leave QStyleSheetStyle's connections on destroyed() intact.
+ backButton_->disconnect(SIGNAL(clicked()));
+}
+
QColor QVistaHelper::basicWindowFrameColor()
{
DWORD rgb;
@@ -315,9 +352,9 @@ bool QVistaHelper::setDWMTitleBar(TitleBarChangeType type)
mar.cyTopHeight = 0;
else
mar.cyTopHeight = titleBarSize() + topOffset();
- HWND wizardHandle = QApplicationPrivate::getHWNDForWidget(wizard);
- HRESULT hr = pDwmExtendFrameIntoClientArea(wizardHandle, &mar);
- value = SUCCEEDED(hr);
+ if (const HWND wizardHandle = wizardHWND())
+ if (SUCCEEDED(pDwmExtendFrameIntoClientArea(wizardHandle, &mar)))
+ value = true;
}
return value;
}
@@ -327,11 +364,11 @@ Q_GUI_EXPORT HICON qt_pixmapToWinHICON(const QPixmap &);
void QVistaHelper::drawTitleBar(QPainter *painter)
{
Q_ASSERT(backButton_);
- QPlatformNativeInterface *nativeInterface = QGuiApplication::platformNativeInterface();
- QBackingStore *backingStore = backButton_->backingStore();
- HDC hdc = static_cast<HDC>(nativeInterface->nativeResourceForBackingStore("getDC", backingStore));
+ QPoint origin;
+ const bool isWindow = wizard->isWindow();
+ const HDC hdc = QVistaHelper::backingStoreDC(wizard, &origin);
- if (vistaState() == VistaAero)
+ if (vistaState() == VistaAero && isWindow)
drawBlackRect(QRect(0, 0, wizard->width(),
titleBarSize() + topOffset()), hdc);
const int btnTop = backButton_->mapToParent(QPoint()).y();
@@ -352,14 +389,28 @@ void QVistaHelper::drawTitleBar(QPainter *painter)
glowOffset = glowSize();
}
- drawTitleText(
- painter, text,
- QRect(titleOffset() - glowOffset, verticalCenter - textHeight / 2, textWidth, textHeight),
- hdc);
+ const int titleLeft = (wizard->layoutDirection() == Qt::LeftToRight
+ ? titleOffset() - glowOffset
+ : wizard->width() - titleOffset() - textWidth + glowOffset);
+
+ const QRect textRectangle(titleLeft, verticalCenter - textHeight / 2, textWidth, textHeight);
+ if (isWindow) {
+ drawTitleText(painter, text, textRectangle, hdc);
+ } else {
+ painter->save();
+ painter->setFont(font);
+ painter->drawText(textRectangle, Qt::AlignVCenter | Qt::AlignHCenter, text);
+ painter->restore();
+ }
const QIcon windowIcon = wizard->windowIcon();
if (!windowIcon.isNull()) {
- QRect rect(leftMargin(), verticalCenter - iconSize() / 2, iconSize(), iconSize());
+ const int iconLeft = (wizard->layoutDirection() == Qt::LeftToRight
+ ? leftMargin()
+ : wizard->width() - leftMargin() - iconSize());
+
+ const QRect rect(origin.x() + iconLeft,
+ origin.y() + verticalCenter - iconSize() / 2, iconSize(), iconSize());
const HICON hIcon = qt_pixmapToWinHICON(windowIcon.pixmap(iconSize()));
DrawIconEx(hdc, rect.left(), rect.top(), hIcon, 0, 0, 0, NULL, DI_NORMAL | DI_COMPAT);
DestroyIcon(hIcon);
@@ -375,8 +426,8 @@ void QVistaHelper::setTitleBarIconAndCaptionVisible(bool visible)
opt.dwMask = 0;
else
opt.dwMask = WIZ_WTNCA_NODRAWICON | WIZ_WTNCA_NODRAWCAPTION;
- HWND handle = QApplicationPrivate::getHWNDForWidget(wizard);
- pSetWindowThemeAttribute(handle, WIZ_WTA_NONCLIENT, &opt, sizeof(WIZ_WTA_OPTIONS));
+ if (const HWND handle = wizardHWND())
+ pSetWindowThemeAttribute(handle, WIZ_WTA_NONCLIENT, &opt, sizeof(WIZ_WTA_OPTIONS));
}
}
@@ -402,13 +453,6 @@ bool QVistaHelper::winEvent(MSG* msg, long* result)
}
break;
}
-// case WM_NCCALCSIZE: { #fixme: If the frame size is changed, it needs to be communicated to the QWindow.
-// NCCALCSIZE_PARAMS* lpncsp = (NCCALCSIZE_PARAMS*)msg->lParam;
-// *result = DefWindowProc(msg->hwnd, msg->message, msg->wParam, msg->lParam);
-// lpncsp->rgrc[0].top -= (vistaState() == VistaAero ? titleBarSize() : 0);
-//
-// break;
-// }
default:
LRESULT lResult;
// Pass to DWM to handle
@@ -449,38 +493,6 @@ void QVistaHelper::mouseEvent(QEvent *event)
}
}
-// The following hack ensures that the titlebar is updated correctly
-// when the wizard style changes to and from AeroStyle. Specifically,
-// this function causes a Windows message of type WM_NCCALCSIZE to
-// be triggered.
-void QVistaHelper::setWindowPosHack()
-{
- const int x = wizard->geometry().x(); // ignored by SWP_NOMOVE
- const int y = wizard->geometry().y(); // ignored by SWP_NOMOVE
- const int w = wizard->width();
- const int h = wizard->height();
- HWND handle = QApplicationPrivate::getHWNDForWidget(wizard);
- SetWindowPos(handle, 0, x, y, w, h, SWP_NOMOVE | SWP_NOZORDER | SWP_FRAMECHANGED);
-}
-
-// The following hack allows any QWidget subclass to access
-// QWidgetPrivate::topData() without being declared as a
-// friend by QWidget.
-class QHackWidget : public QWidget
-{
-public:
- Q_DECLARE_PRIVATE(QWidget)
- QTLWExtra* topData() { return d_func()->topData(); }
-};
-
-void QVistaHelper::collapseTopFrameStrut()
-{
- QTLWExtra *top = ((QHackWidget *)wizard)->d_func()->topData();
- int x1, y1, x2, y2;
- top->frameStrut.getCoords(&x1, &y1, &x2, &y2);
- top->frameStrut.setCoords(x1, 0, x2, y2);
-}
-
bool QVistaHelper::handleWinEvent(MSG *message, long *result)
{
if (message->message == WIZ_WM_THEMECHANGED || message->message == WIZ_WM_DWMCOMPOSITIONCHANGED)
@@ -489,12 +501,8 @@ bool QVistaHelper::handleWinEvent(MSG *message, long *result)
bool status = false;
if (wizard->wizardStyle() == QWizard::AeroStyle && vistaState() == VistaAero) {
status = winEvent(message, result);
- if (message->message == WM_NCCALCSIZE) {
-// if (status) #fixme
-// collapseTopFrameStrut();
- } else if (message->message == WM_NCPAINT) {
+ if (message->message == WM_NCPAINT)
wizard->update();
- }
}
return status;
}
@@ -598,8 +606,7 @@ bool QVistaHelper::eventFilter(QObject *obj, QEvent *event)
msg.message = WM_NCHITTEST;
msg.wParam = 0;
msg.lParam = MAKELPARAM(mouseEvent->globalX(), mouseEvent->globalY());
- HWND handle = QApplicationPrivate::getHWNDForWidget(wizard);
- msg.hwnd = handle;
+ msg.hwnd = wizardHWND();
winEvent(&msg, &result);
msg.wParam = result;
msg.message = WM_NCMOUSEMOVE;
@@ -613,8 +620,7 @@ bool QVistaHelper::eventFilter(QObject *obj, QEvent *event)
msg.message = WM_NCHITTEST;
msg.wParam = 0;
msg.lParam = MAKELPARAM(mouseEvent->globalX(), mouseEvent->globalY());
- HWND handle = QApplicationPrivate::getHWNDForWidget(wizard);
- msg.hwnd = handle;
+ msg.hwnd = wizardHWND();
winEvent(&msg, &result);
msg.wParam = result;
msg.message = WM_NCLBUTTONDOWN;
@@ -629,8 +635,7 @@ bool QVistaHelper::eventFilter(QObject *obj, QEvent *event)
msg.message = WM_NCHITTEST;
msg.wParam = 0;
msg.lParam = MAKELPARAM(mouseEvent->globalX(), mouseEvent->globalY());
- HWND handle = QApplicationPrivate::getHWNDForWidget(wizard);
- msg.hwnd = handle;
+ msg.hwnd = wizardHWND();
winEvent(&msg, &result);
msg.wParam = result;
msg.message = WM_NCLBUTTONUP;
@@ -657,6 +662,31 @@ HFONT QVistaHelper::getCaptionFont(HANDLE hTheme)
return CreateFontIndirect(&lf);
}
+// Return a HDC for the wizard along with the transformation if the
+// wizard is a child window.
+HDC QVistaHelper::backingStoreDC(const QWidget *wizard, QPoint *offset)
+{
+ HDC hdc = static_cast<HDC>(QGuiApplication::platformNativeInterface()->nativeResourceForBackingStore(QByteArrayLiteral("getDC"), wizard->backingStore()));
+ *offset = QPoint(0, 0);
+ if (!wizard->windowHandle())
+ if (QWidget *nativeParent = wizard->nativeParentWidget())
+ *offset = wizard->mapTo(nativeParent, *offset);
+ return hdc;
+}
+
+HWND QVistaHelper::wizardHWND() const
+{
+ // Obtain the HWND if the wizard is a top-level window.
+ // Do not use winId() as this enforces native children of the parent
+ // widget when called before show() as happens when calling setWizardStyle().
+ if (QWindow *window = wizard->windowHandle())
+ if (window->handle())
+ if (void *vHwnd = QGuiApplication::platformNativeInterface()->nativeResourceForWindow(QByteArrayLiteral("handle"), window))
+ return static_cast<HWND>(vHwnd);
+ qWarning().nospace() << "Failed to obtain HWND for wizard.";
+ return 0;
+}
+
bool QVistaHelper::drawTitleText(QPainter *painter, const QString &text, const QRect &rect, HDC hdc)
{
bool value = false;
@@ -677,14 +707,14 @@ bool QVistaHelper::drawTitleText(QPainter *painter, const QString &text, const Q
dib.bmiHeader.biPlanes = 1;
dib.bmiHeader.biBitCount = 32;
dib.bmiHeader.biCompression = BI_RGB;
-
+
bmp = CreateDIBSection(hdc, &dib, DIB_RGB_COLORS, NULL, NULL, 0);
// Set up the DC
HFONT hCaptionFont = getCaptionFont(hTheme);
HBITMAP hOldBmp = (HBITMAP)SelectObject(dcMem, (HGDIOBJ) bmp);
HFONT hOldFont = (HFONT)SelectObject(dcMem, (HGDIOBJ) hCaptionFont);
-
+
// Draw the text!
WIZ_DTTOPTS dto;
dto.dwSize = sizeof(WIZ_DTTOPTS);
@@ -693,7 +723,7 @@ bool QVistaHelper::drawTitleText(QPainter *painter, const QString &text, const Q
dto.dwFlags = WIZ_DTT_COMPOSITED|WIZ_DTT_GLOWSIZE;
dto.iGlowSize = glowSize();
-
+
pDrawThemeTextEx(hTheme, dcMem, 0, 0, (LPCWSTR)text.utf16(), -1, uFormat, &rctext, &dto );
BitBlt(hdc, rect.left(), rect.top(), rect.width(), rect.height(), dcMem, 0, 0, SRCCOPY);
SelectObject(dcMem, (HGDIOBJ) hOldBmp);
@@ -725,7 +755,7 @@ bool QVistaHelper::drawBlackRect(const QRect &rect, HDC hdc)
dib.bmiHeader.biPlanes = 1;
dib.bmiHeader.biBitCount = 32;
dib.bmiHeader.biCompression = BI_RGB;
-
+
bmp = CreateDIBSection(hdc, &dib, DIB_RGB_COLORS, NULL, NULL, 0);
HBITMAP hOldBmp = (HBITMAP)SelectObject(dcMem, (HGDIOBJ) bmp);
@@ -789,6 +819,19 @@ int QVistaHelper::titleOffset()
return leftMargin() + iconOffset;
}
+int QVistaHelper::topOffset()
+{
+ if (vistaState() != VistaAero)
+ return titleBarSize() + 3;
+ static const int aeroOffset =
+ QSysInfo::WindowsVersion == QSysInfo::WV_WINDOWS7 ?
+ QStyleHelper::dpiScaled(4) : QStyleHelper::dpiScaled(13);
+ int result = aeroOffset;
+ if (QSysInfo::WindowsVersion < QSysInfo::WV_WINDOWS8)
+ result += titleBarSize();
+ return result;
+}
+
QT_END_NAMESPACE
#endif // QT_NO_STYLE_WINDOWSVISTA
diff --git a/src/widgets/dialogs/qwizard_win_p.h b/src/widgets/dialogs/qwizard_win_p.h
index cd0b2da38e..a7713d889b 100644
--- a/src/widgets/dialogs/qwizard_win_p.h
+++ b/src/widgets/dialogs/qwizard_win_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -53,6 +53,8 @@
// We mean it.
//
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_WIZARD
#ifndef QT_NO_STYLE_WINDOWSVISTA
@@ -87,6 +89,7 @@ public:
QVistaHelper(QWizard *wizard);
~QVistaHelper();
enum TitleBarChangeType { NormalTitleBar, ExtendedTitleBar };
+ void updateCustomMargins(bool vistaMargins);
bool setDWMTitleBar(TitleBarChangeType type);
void setTitleBarIconAndCaptionVisible(bool visible);
void mouseEvent(QEvent *event);
@@ -94,9 +97,8 @@ public:
void resizeEvent(QResizeEvent *event);
void paintEvent(QPaintEvent *event);
QVistaBackButton *backButton() const { return backButton_; }
- void disconnectBackButton() { if (backButton_) backButton_->disconnect(); }
+ void disconnectBackButton();
void hideBackButton() { if (backButton_) backButton_->hide(); }
- void setWindowPosHack();
QColor basicWindowFrameColor();
enum VistaState { VistaAero, VistaBasic, Classic, Dirty };
static VistaState vistaState();
@@ -105,12 +107,13 @@ public:
return int(QStyleHelper::dpiScaled(
QSysInfo::WindowsVersion >= QSysInfo::WV_WINDOWS7 ? 4 : 6));
}
- static int topOffset() {
- static int aeroOffset = QSysInfo::WindowsVersion >= QSysInfo::WV_WINDOWS7 ?
- QStyleHelper::dpiScaled(4) : QStyleHelper::dpiScaled(13);
- return (titleBarSize() + (vistaState() == VistaAero ? aeroOffset : 3)); }
+ static int topOffset();
+
+ static HDC backingStoreDC(const QWidget *wizard, QPoint *offset);
+
private:
static HFONT getCaptionFont(HANDLE hTheme);
+ HWND wizardHWND() const;
bool drawTitleText(QPainter *painter, const QString &text, const QRect &rect, HDC hdc);
static bool drawBlackRect(const QRect &rect, HDC hdc);
diff --git a/doc/src/images/customcompleter-example.png b/src/widgets/doc/images/customcompleter-example.png
index a525208118..a525208118 100644
--- a/doc/src/images/customcompleter-example.png
+++ b/src/widgets/doc/images/customcompleter-example.png
Binary files differ
diff --git a/doc/src/images/customcompleter-insertcompletion.png b/src/widgets/doc/images/customcompleter-insertcompletion.png
index 0bb2c25c39..0bb2c25c39 100644
--- a/doc/src/images/customcompleter-insertcompletion.png
+++ b/src/widgets/doc/images/customcompleter-insertcompletion.png
Binary files differ
diff --git a/src/widgets/doc/snippets/code/src_gui_itemviews_qdatawidgetmapper.cpp b/src/widgets/doc/snippets/code/src_gui_itemviews_qdatawidgetmapper.cpp
index b5d9708f99..0b6ae83ffb 100644
--- a/src/widgets/doc/snippets/code/src_gui_itemviews_qdatawidgetmapper.cpp
+++ b/src/widgets/doc/snippets/code/src_gui_itemviews_qdatawidgetmapper.cpp
@@ -57,7 +57,7 @@ mapper->addMapping(ageSpinBox, 1);
//! [2]
-QDataWidgetMapper *mapper = new QDataWidgetMapper();
+QDataWidgetMapper *mapper = new QDataWidgetMapper();
connect(myTableView->selectionModel(), SIGNAL(currentRowChanged(QModelIndex,QModelIndex)),
mapper, SLOT(setCurrentModelIndex(QModelIndex)));
//! [2]
diff --git a/src/widgets/doc/snippets/customviewstyle.cpp b/src/widgets/doc/snippets/customviewstyle.cpp
index 6bb022574d..cdb4ed1d77 100644
--- a/src/widgets/doc/snippets/customviewstyle.cpp
+++ b/src/widgets/doc/snippets/customviewstyle.cpp
@@ -61,7 +61,7 @@ void CustomViewStyle::drawPrimitive(PrimitiveElement element, const QStyleOption
painter->restore();
break;
- }
+ }
default:
QProxyStyle::drawPrimitive(element, option, painter, widget);
}
diff --git a/src/widgets/doc/snippets/javastyle.cpp b/src/widgets/doc/snippets/javastyle.cpp
index 15cc53ce2d..37f02c7f13 100644
--- a/src/widgets/doc/snippets/javastyle.cpp
+++ b/src/widgets/doc/snippets/javastyle.cpp
@@ -103,7 +103,7 @@ QPalette JavaStyle::standardPalette() const
palette.setBrush(QPalette::Inactive, QPalette::Highlight, QColor(184, 207, 229));
palette.setBrush(QPalette::Inactive, QPalette::HighlightedText, Qt::black);
-
+
palette.setBrush(QPalette::Disabled, QPalette::Button,
QColor(238, 238, 238));
palette.setBrush(QPalette::Disabled, QPalette::WindowText,
@@ -968,7 +968,7 @@ void JavaStyle::drawControl(ControlElement control, const QStyleOption *option,
painter->setBrush(QColor(200, 221, 242));
painter->drawPath(outerPath);
painter->setPen(QColor(200, 221, 242));
- painter->drawRect(QRect(bottomLeft + adjustTabPoint(
+ painter->drawRect(QRect(bottomLeft + adjustTabPoint(
QPoint(2, -3), tab->shape),
bottomRight + adjustTabPoint(
QPoint(-2, 0), tab->shape)));
@@ -976,7 +976,7 @@ void JavaStyle::drawControl(ControlElement control, const QStyleOption *option,
painter->setBrush(Qt::NoBrush);
painter->drawPath(whitePath);
- if (option->state & State_HasFocus) {
+ if (option->state & State_HasFocus) {
painter->setPen(option->palette.color(QPalette::Mid));
painter->drawPath(innerPath);
}
@@ -1699,7 +1699,7 @@ void JavaStyle::drawComplexControl(ComplexControl control,
menuOption.rect = menuRect;
QStyleOptionToolButton label = *button;
- int fw = 5;
+ int fw = 5;
drawControl(CE_ToolButtonLabel, &label, painter, widget);
if (button->subControls & SC_ToolButtonMenu) {
@@ -1713,7 +1713,7 @@ void JavaStyle::drawComplexControl(ComplexControl control,
drawPrimitive(PE_FrameFocusRect, &focusOption, painter, widget);
}
-
+
break;
}
case CC_ComboBox: {
@@ -2113,7 +2113,7 @@ void JavaStyle::drawPrimitive(PrimitiveElement element,
painter->drawLine(center, QPoint(center.x(),
option->rect.bottom()));
}
-
+
if (option->state & State_Children)
if (option->state & State_Open)
painter->drawPixmap(pixmapRect.topLeft(), closedPixmap);
@@ -2198,7 +2198,7 @@ void JavaStyle::drawPrimitive(PrimitiveElement element,
painter->drawPoint(center.x() + 1 + add, center.y() + 1 + add);
break;
}
- case PE_FrameDockWidget: {
+ case PE_FrameDockWidget: {
drawPrimitive(PE_FrameWindow, option, painter, widget);
break;
}
@@ -2226,7 +2226,7 @@ void JavaStyle::drawPrimitive(PrimitiveElement element,
painter->drawPoint(offset + xySwitch(QPoint(add + 8, i),
horizontal));
}
-
+
break;
}
case PE_IndicatorToolBarSeparator: {
@@ -2591,7 +2591,7 @@ int JavaStyle::styleHint(StyleHint hint, const QStyleOption *option,
break;
}
case QStyle::SH_Menu_Scrollable:
- ret = 1;
+ ret = 1;
break;
default:
ret = QCommonStyle::styleHint(hint, option, widget, returnData);
@@ -2719,7 +2719,7 @@ QSize JavaStyle::sizeFromContents(ContentsType type,
int height = 0;
if (!menuItem->icon.isNull()) {
- width += 20;
+ width += 20;
height += 20;
}
if (!menuItem->text.isEmpty()) {
diff --git a/src/widgets/doc/snippets/layouts/layouts.cpp b/src/widgets/doc/snippets/layouts/layouts.cpp
index c41f370070..9ec2349615 100644
--- a/src/widgets/doc/snippets/layouts/layouts.cpp
+++ b/src/widgets/doc/snippets/layouts/layouts.cpp
@@ -72,7 +72,7 @@ int main(int argc, char *argv[])
window->show();
//! [5]
}
-
+
{
//! [6]
QWidget *window = new QWidget;
@@ -101,7 +101,7 @@ int main(int argc, char *argv[])
window->show();
//! [11]
}
-
+
{
//! [12]
QWidget *window = new QWidget;
@@ -158,7 +158,7 @@ int main(int argc, char *argv[])
window->setWindowTitle("QFormLayout");
//! [23]
window->show();
-//! [23]
+//! [23]
}
{
diff --git a/src/widgets/doc/snippets/mainwindowsnippet.cpp b/src/widgets/doc/snippets/mainwindowsnippet.cpp
index 1ba58ca0e7..a9a9012d46 100644
--- a/src/widgets/doc/snippets/mainwindowsnippet.cpp
+++ b/src/widgets/doc/snippets/mainwindowsnippet.cpp
@@ -55,10 +55,10 @@ void MainWindow::createMenus()
//setMenuWidget(new QPushButton("Hello"));
QMenu *menu = new QMenu("File");
menu->addAction("Save &As");
-
+
QMenuBar *bar = new QMenuBar;
bar->addMenu(menu);
-
+
setMenuWidget(new QWidget());
}
@@ -84,9 +84,9 @@ void MainWindow::createDockWidgets()
//! [0]
QDockWidget *dockWidget = new QDockWidget(tr("Dock Widget"), this);
- dockWidget->setAllowedAreas(Qt::LeftDockWidgetArea |
+ dockWidget->setAllowedAreas(Qt::LeftDockWidgetArea |
Qt::RightDockWidgetArea);
dockWidget->setWidget(dockWidgetContents);
- addDockWidget(Qt::LeftDockWidgetArea, dockWidget);
+ addDockWidget(Qt::LeftDockWidgetArea, dockWidget);
//! [0]
}
diff --git a/src/widgets/doc/snippets/mdiareasnippets.cpp b/src/widgets/doc/snippets/mdiareasnippets.cpp
index 51555f8984..42902b4cd7 100644
--- a/src/widgets/doc/snippets/mdiareasnippets.cpp
+++ b/src/widgets/doc/snippets/mdiareasnippets.cpp
@@ -57,7 +57,7 @@ void addingSubWindowsExample()
{
QWidget *internalWidget1 = new QWidget;
QWidget *internalWidget2 = new QWidget;
-
+
//! [1]
QMdiArea mdiArea;
QMdiSubWindow *subWindow1 = new QMdiSubWindow;
diff --git a/src/widgets/doc/snippets/myscrollarea.cpp b/src/widgets/doc/snippets/myscrollarea.cpp
index 48434952c3..675acf89ef 100644
--- a/src/widgets/doc/snippets/myscrollarea.cpp
+++ b/src/widgets/doc/snippets/myscrollarea.cpp
@@ -121,7 +121,7 @@ int main(int argv, char **args)
MyScrollArea area(&label);
area.resize(300, 300);
area.show();
-
+
area.setWidget(&label);
return app.exec();
diff --git a/src/widgets/doc/snippets/qtablewidget-using/mainwindow.cpp b/src/widgets/doc/snippets/qtablewidget-using/mainwindow.cpp
index d9f9853d9c..85b5baf56e 100644
--- a/src/widgets/doc/snippets/qtablewidget-using/mainwindow.cpp
+++ b/src/widgets/doc/snippets/qtablewidget-using/mainwindow.cpp
@@ -117,7 +117,7 @@ void MainWindow::averageItems()
foreach (item, selected) {
bool ok;
double value = item->text().toDouble(&ok);
-
+
if (ok && !item->text().isEmpty()) {
total += value;
number++;
diff --git a/src/widgets/doc/snippets/simplemodel-use/main.cpp b/src/widgets/doc/snippets/simplemodel-use/main.cpp
index ed435f9897..d291a02b6b 100644
--- a/src/widgets/doc/snippets/simplemodel-use/main.cpp
+++ b/src/widgets/doc/snippets/simplemodel-use/main.cpp
@@ -66,7 +66,7 @@ int main(int argc, char *argv[])
title->setBackgroundRole(QPalette::Base);
title->setMargin(8);
layout->addWidget(title);
-
+
//! [0]
QFileSystemModel *model = new QFileSystemModel;
QModelIndex parentIndex = model->index(QDir::currentPath());
diff --git a/src/widgets/doc/snippets/stringlistmodel/model.cpp b/src/widgets/doc/snippets/stringlistmodel/model.cpp
index 3bf91ec326..b1fa2abdf0 100644
--- a/src/widgets/doc/snippets/stringlistmodel/model.cpp
+++ b/src/widgets/doc/snippets/stringlistmodel/model.cpp
@@ -60,7 +60,7 @@ int StringListModel::rowCount(const QModelIndex &parent) const
#ifdef 0
-// This represents a read-only version of data(), an early stage in the
+// This represents a read-only version of data(), an early stage in the
// development of the example leading to an editable StringListModel.
/*!
@@ -103,7 +103,7 @@ QVariant StringListModel::data(const QModelIndex &index, int role) const
if (index.row() >= stringList.size())
return QVariant();
-
+
if (role == Qt::DisplayRole || role == Qt::EditRole)
return stringList.at(index.row());
else
diff --git a/src/widgets/doc/snippets/timeline/main.cpp b/src/widgets/doc/snippets/timeline/main.cpp
index eb2e8a2c70..9e4d218a88 100644
--- a/src/widgets/doc/snippets/timeline/main.cpp
+++ b/src/widgets/doc/snippets/timeline/main.cpp
@@ -47,17 +47,17 @@ int main(int argv, char *args[])
//! [0]
QGraphicsItem *ball = new QGraphicsEllipseItem(0, 0, 20, 20);
-
+
QTimeLine *timer = new QTimeLine(5000);
timer->setFrameRange(0, 100);
-
+
QGraphicsItemAnimation *animation = new QGraphicsItemAnimation;
animation->setItem(ball);
animation->setTimeLine(timer);
- for (int i = 0; i < 200; ++i)
+ for (int i = 0; i < 200; ++i)
animation->setPosAt(i / 200.0, QPointF(i, i));
-
+
QGraphicsScene *scene = new QGraphicsScene();
scene->setSceneRect(0, 0, 250, 250);
scene->addItem(ball);
diff --git a/src/widgets/doc/src/model-view-programming.qdoc b/src/widgets/doc/src/model-view-programming.qdoc
index a1c6a29066..6bcd0943a1 100644
--- a/src/widgets/doc/src/model-view-programming.qdoc
+++ b/src/widgets/doc/src/model-view-programming.qdoc
@@ -280,7 +280,7 @@
In the above example, we neglected to mention how to handle selections
of items. This subject is covered in more detail in the section about
- \l{Handling Selections in Item Views}.
+ \l{Handling Selections in Item Views}.
\section1 Model classes
diff --git a/src/widgets/doc/src/widgets-and-layouts/focus.qdoc b/src/widgets/doc/src/widgets-and-layouts/focus.qdoc
index 5cb7775c32..427d5a24d6 100644
--- a/src/widgets/doc/src/widgets-and-layouts/focus.qdoc
+++ b/src/widgets/doc/src/widgets-and-layouts/focus.qdoc
@@ -34,7 +34,7 @@
\keyword keyboard focus
Qt's widgets handle keyboard focus in the ways that have become
- customary in GUIs.
+ customary in GUIs.
The basic issue is that the user's key strokes can be directed at any
of several windows on the screen, and any of several widgets inside
@@ -47,7 +47,7 @@
\section1 Focus Motion
The customs which have evolved for directing keyboard focus to a
- particular widget are these:
+ particular widget are these:
\list 1
@@ -89,7 +89,7 @@
For example, in a data entry dialog, there might be a field that
is only necessary in one per cent of all cases. In such a dialog,
\uicontrol Tab could skip this field, and the dialog could use one of
- these mechanisms:
+ these mechanisms:
\list 1
diff --git a/src/widgets/doc/src/widgets-and-layouts/layout.qdoc b/src/widgets/doc/src/widgets-and-layouts/layout.qdoc
index b658fc809c..f74da2fa0a 100644
--- a/src/widgets/doc/src/widgets-and-layouts/layout.qdoc
+++ b/src/widgets/doc/src/widgets-and-layouts/layout.qdoc
@@ -70,7 +70,7 @@
\endlist
\section1 Qt's Layout Classes
-
+
Qt's layout classes were designed for hand-written C++ code, allowing
measurements to be specified in pixels for simplicity, so they are easy to
understand and use. The code generated for forms created using Qt Designer also
@@ -136,11 +136,11 @@
the fifth argument to QGridLayout::addWidget().
QFormLayout will add two widgets on a row, commonly a QLabel and a QLineEdit
- to create forms. Adding a QLabel and a QLineEdit on the same row will set
- the QLineEdit as the QLabel's buddy. The following code will use the
+ to create forms. Adding a QLabel and a QLineEdit on the same row will set
+ the QLineEdit as the QLabel's buddy. The following code will use the
QFormLayout to place three \l{QPushButton}{QPushButtons} and a corresponding
- QLineEdit on a row.
-
+ QLineEdit on a row.
+
\snippet layouts/layouts.cpp 18
\snippet layouts/layouts.cpp 19
\snippet layouts/layouts.cpp 20
@@ -327,7 +327,7 @@
Then we define two functions that iterate over the layout: \c{itemAt()}
and \c{takeAt()}. These functions are used internally by the layout system
to handle deletion of widgets. They are also available for application
- programmers.
+ programmers.
\c{itemAt()} returns the item at the given index. \c{takeAt()} removes the
item at the given index, and returns it. In this case we use the list index
@@ -348,7 +348,7 @@
\snippet code/doc_src_layout.cpp 4
The layout takes over responsibility of the items added. Since QLayoutItem
- does not inherit QObject, we must delete the items manually. In the
+ does not inherit QObject, we must delete the items manually. In the
destructor, we remove each item from the list using \c{takeAt()}, and
then delete it.
diff --git a/src/widgets/doc/src/windows-and-dialogs/dialogs.qdoc b/src/widgets/doc/src/windows-and-dialogs/dialogs.qdoc
index 5aae7fb02b..1f1d8154da 100644
--- a/src/widgets/doc/src/windows-and-dialogs/dialogs.qdoc
+++ b/src/widgets/doc/src/windows-and-dialogs/dialogs.qdoc
@@ -29,7 +29,7 @@
\group standard-dialogs
\ingroup qt-gui-concepts
\title Standard Dialogs
- \brief A list of Qt classes for implementing standard dialogs.
+ \brief A list of Qt classes for implementing standard dialogs.
*/
/*!
@@ -37,7 +37,7 @@
\title Dialog Windows
\ingroup qt-gui-concepts
\brief An overview over dialog windows.
-
+
\previouspage Application Main Window
\contentspage Application Windows and Dialogs
\nextpage Desktop Integration
diff --git a/src/widgets/doc/src/windows-and-dialogs/mainwindow.qdoc b/src/widgets/doc/src/windows-and-dialogs/mainwindow.qdoc
index 1d7d9d1b4c..9315acb85f 100644
--- a/src/widgets/doc/src/windows-and-dialogs/mainwindow.qdoc
+++ b/src/widgets/doc/src/windows-and-dialogs/mainwindow.qdoc
@@ -49,7 +49,7 @@
be listed in the desktop's task bar. This is usually only wanted for one
window in the application, the \e{primary window}.
- In addition, a QWidget that has a parent can become a window by setting the
+ In addition, a QWidget that has a parent can become a window by setting the
Qt::Window flag. Depending on the window management system
such \e{secondary windows} are usually stacked on top of their respective parent
window, and not have a task bar entry of their own.
diff --git a/src/widgets/effects/qgraphicseffect.cpp b/src/widgets/effects/qgraphicseffect.cpp
index cf8abf0d95..ac873709e1 100644
--- a/src/widgets/effects/qgraphicseffect.cpp
+++ b/src/widgets/effects/qgraphicseffect.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/effects/qgraphicseffect.h b/src/widgets/effects/qgraphicseffect.h
index f08f937799..8acb832eee 100644
--- a/src/widgets/effects/qgraphicseffect.h
+++ b/src/widgets/effects/qgraphicseffect.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -49,8 +49,6 @@
#include <QtGui/qbrush.h>
#ifndef QT_NO_GRAPHICSEFFECT
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -281,7 +279,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
#endif //QT_NO_GRAPHICSEFFECT
#endif // QGRAPHICSEFFECT_H
diff --git a/src/widgets/effects/qgraphicseffect_p.h b/src/widgets/effects/qgraphicseffect_p.h
index 2455954a0c..7cdb071196 100644
--- a/src/widgets/effects/qgraphicseffect_p.h
+++ b/src/widgets/effects/qgraphicseffect_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/effects/qpixmapfilter.cpp b/src/widgets/effects/qpixmapfilter.cpp
index 8f4c0b2e76..c7ae4e2996 100644
--- a/src/widgets/effects/qpixmapfilter.cpp
+++ b/src/widgets/effects/qpixmapfilter.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/effects/qpixmapfilter_p.h b/src/widgets/effects/qpixmapfilter_p.h
index e93c1adc3c..624079c3ba 100644
--- a/src/widgets/effects/qpixmapfilter_p.h
+++ b/src/widgets/effects/qpixmapfilter_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -58,8 +58,6 @@
#include <QtWidgets/qgraphicseffect.h>
#ifndef QT_NO_GRAPHICSEFFECT
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -189,7 +187,5 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QT_NO_GRAPHICSEFFECT
#endif // QPIXMAPFILTER_H
diff --git a/src/widgets/graphicsview/qgraph_p.h b/src/widgets/graphicsview/qgraph_p.h
index a889a03a0b..2368c6fbec 100644
--- a/src/widgets/graphicsview/qgraph_p.h
+++ b/src/widgets/graphicsview/qgraph_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsanchorlayout.cpp b/src/widgets/graphicsview/qgraphicsanchorlayout.cpp
index 8c82b97c92..47cb42195f 100644
--- a/src/widgets/graphicsview/qgraphicsanchorlayout.cpp
+++ b/src/widgets/graphicsview/qgraphicsanchorlayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsanchorlayout.h b/src/widgets/graphicsview/qgraphicsanchorlayout.h
index b8aa221630..c924a0386a 100644
--- a/src/widgets/graphicsview/qgraphicsanchorlayout.h
+++ b/src/widgets/graphicsview/qgraphicsanchorlayout.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtWidgets/qgraphicslayout.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -122,6 +120,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/widgets/graphicsview/qgraphicsanchorlayout_p.cpp b/src/widgets/graphicsview/qgraphicsanchorlayout_p.cpp
index 1cc3f5a1ed..e281e4a7a3 100644
--- a/src/widgets/graphicsview/qgraphicsanchorlayout_p.cpp
+++ b/src/widgets/graphicsview/qgraphicsanchorlayout_p.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsanchorlayout_p.h b/src/widgets/graphicsview/qgraphicsanchorlayout_p.h
index 96553a5344..37defccc96 100644
--- a/src/widgets/graphicsview/qgraphicsanchorlayout_p.h
+++ b/src/widgets/graphicsview/qgraphicsanchorlayout_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsgridlayout.cpp b/src/widgets/graphicsview/qgraphicsgridlayout.cpp
index 01d08f229a..6d9dd98839 100644
--- a/src/widgets/graphicsview/qgraphicsgridlayout.cpp
+++ b/src/widgets/graphicsview/qgraphicsgridlayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsgridlayout.h b/src/widgets/graphicsview/qgraphicsgridlayout.h
index d833ea3b33..6d0ef5ea10 100644
--- a/src/widgets/graphicsview/qgraphicsgridlayout.h
+++ b/src/widgets/graphicsview/qgraphicsgridlayout.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qgraphicsitem.h>
#include <QtWidgets/qgraphicslayout.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -137,7 +135,5 @@ inline void QGraphicsGridLayout::addItem(QGraphicsLayoutItem *aitem, int arow, i
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/widgets/graphicsview/qgraphicsitem.cpp b/src/widgets/graphicsview/qgraphicsitem.cpp
index fd13ee83cd..62eab6a7a2 100644
--- a/src/widgets/graphicsview/qgraphicsitem.cpp
+++ b/src/widgets/graphicsview/qgraphicsitem.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -1864,15 +1864,46 @@ void QGraphicsItem::setFlags(GraphicsItemFlags flags)
d_ptr->scene->d_func()->updateInputMethodSensitivityInViews();
}
+ if ((flags & ItemIsPanel) != (oldFlags & ItemIsPanel)) {
+ bool becomesPanel = (flags & ItemIsPanel);
+ if ((d_ptr->panelModality != NonModal) && d_ptr->scene) {
+ // update the panel's modal state
+ if (becomesPanel)
+ d_ptr->scene->d_func()->enterModal(this);
+ else
+ d_ptr->scene->d_func()->leaveModal(this);
+ }
+ if (d_ptr->isWidget && (becomesPanel || parentWidget())) {
+ QGraphicsWidget *w = static_cast<QGraphicsWidget *>(this);
+ QGraphicsWidget *focusFirst = w;
+ QGraphicsWidget *focusLast = w;
+ for (;;) {
+ QGraphicsWidget *test = focusLast->d_func()->focusNext;
+ if (!w->isAncestorOf(test) || test == w)
+ break;
+ focusLast = test;
+ }
- if ((d_ptr->panelModality != NonModal)
- && d_ptr->scene
- && (flags & ItemIsPanel) != (oldFlags & ItemIsPanel)) {
- // update the panel's modal state
- if (flags & ItemIsPanel)
- d_ptr->scene->d_func()->enterModal(this);
- else
- d_ptr->scene->d_func()->leaveModal(this);
+ if (becomesPanel) {
+ // unlink own widgets from focus chain
+ QGraphicsWidget *beforeMe = w->d_func()->focusPrev;
+ QGraphicsWidget *afterMe = focusLast->d_func()->focusNext;
+ beforeMe->d_func()->focusNext = afterMe;
+ afterMe->d_func()->focusPrev = beforeMe;
+ focusFirst->d_func()->focusPrev = focusLast;
+ focusLast->d_func()->focusNext = focusFirst;
+ if (!isAncestorOf(focusFirst->d_func()->focusNext))
+ focusFirst->d_func()->focusNext = w;
+ } else if (QGraphicsWidget *pw = parentWidget()) {
+ // link up own widgets to focus chain
+ QGraphicsWidget *beforeMe = pw;
+ QGraphicsWidget *afterMe = pw->d_func()->focusNext;
+ beforeMe->d_func()->focusNext = w;
+ afterMe->d_func()->focusPrev = focusLast;
+ w->d_func()->focusPrev = beforeMe;
+ focusLast->d_func()->focusNext = afterMe;
+ }
+ }
}
if (d_ptr->scene) {
@@ -2256,7 +2287,7 @@ void QGraphicsItemPrivate::setVisibleHelper(bool newVisible, bool explicitly,
scene->d_func()->leaveModal(q_ptr);
}
if (hasFocus && scene) {
- // Hiding the closest non-panel ancestor of the focus item
+ // Hiding the focus item or the closest non-panel ancestor of the focus item
QGraphicsItem *focusItem = scene->focusItem();
bool clear = true;
if (isWidget && !focusItem->isPanel()) {
@@ -3153,16 +3184,20 @@ void QGraphicsItem::setActive(bool active)
// Activate this item.
d_ptr->scene->setActivePanel(this);
} else {
- // Deactivate this item, and reactivate the parent panel,
- // or the last active panel (if any).
- QGraphicsItem *nextToActivate = 0;
- if (d_ptr->parent)
- nextToActivate = d_ptr->parent->panel();
- if (!nextToActivate)
- nextToActivate = d_ptr->scene->d_func()->lastActivePanel;
- if (nextToActivate == this || isAncestorOf(nextToActivate))
- nextToActivate = 0;
- d_ptr->scene->setActivePanel(nextToActivate);
+ QGraphicsItem *activePanel = d_ptr->scene->activePanel();
+ QGraphicsItem *thisPanel = panel();
+ if (!activePanel || activePanel == thisPanel) {
+ // Deactivate this item, and reactivate the parent panel,
+ // or the last active panel (if any).
+ QGraphicsItem *nextToActivate = 0;
+ if (d_ptr->parent)
+ nextToActivate = d_ptr->parent->panel();
+ if (!nextToActivate)
+ nextToActivate = d_ptr->scene->d_func()->lastActivePanel;
+ if (nextToActivate == this || isAncestorOf(nextToActivate))
+ nextToActivate = 0;
+ d_ptr->scene->setActivePanel(nextToActivate);
+ }
}
}
}
diff --git a/src/widgets/graphicsview/qgraphicsitem.h b/src/widgets/graphicsview/qgraphicsitem.h
index 446aea4754..4283deb5b8 100644
--- a/src/widgets/graphicsview/qgraphicsitem.h
+++ b/src/widgets/graphicsview/qgraphicsitem.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -52,8 +52,6 @@
class tst_QGraphicsItem;
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -1059,6 +1057,4 @@ QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGRAPHICSITEM_H
diff --git a/src/widgets/graphicsview/qgraphicsitem_p.h b/src/widgets/graphicsview/qgraphicsitem_p.h
index 5803340075..d80df7c4ad 100644
--- a/src/widgets/graphicsview/qgraphicsitem_p.h
+++ b/src/widgets/graphicsview/qgraphicsitem_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsitemanimation.cpp b/src/widgets/graphicsview/qgraphicsitemanimation.cpp
index 5e035be5f7..45e8b436b1 100644
--- a/src/widgets/graphicsview/qgraphicsitemanimation.cpp
+++ b/src/widgets/graphicsview/qgraphicsitemanimation.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsitemanimation.h b/src/widgets/graphicsview/qgraphicsitemanimation.h
index d87fc8a868..1e8f27ef53 100644
--- a/src/widgets/graphicsview/qgraphicsitemanimation.h
+++ b/src/widgets/graphicsview/qgraphicsitemanimation.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#if !defined(QT_NO_GRAPHICSVIEW)
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -113,7 +111,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_GRAPHICSVIEW
#endif
diff --git a/src/widgets/graphicsview/qgraphicslayout.cpp b/src/widgets/graphicsview/qgraphicslayout.cpp
index fdd6f9f508..f7c89cf376 100644
--- a/src/widgets/graphicsview/qgraphicslayout.cpp
+++ b/src/widgets/graphicsview/qgraphicslayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicslayout.h b/src/widgets/graphicsview/qgraphicslayout.h
index 85668d8deb..719ac0dd4d 100644
--- a/src/widgets/graphicsview/qgraphicslayout.h
+++ b/src/widgets/graphicsview/qgraphicslayout.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qgraphicslayoutitem.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -93,7 +91,5 @@ Q_DECLARE_INTERFACE(QGraphicsLayout, "org.qt-project.Qt.QGraphicsLayout")
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/widgets/graphicsview/qgraphicslayout_p.cpp b/src/widgets/graphicsview/qgraphicslayout_p.cpp
index 8e3d4a62f8..d856416564 100644
--- a/src/widgets/graphicsview/qgraphicslayout_p.cpp
+++ b/src/widgets/graphicsview/qgraphicslayout_p.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -187,7 +187,7 @@ void QGraphicsLayoutPrivate::activateRecursive(QGraphicsLayoutItem *item)
layout->invalidate(); // ### LOOKS SUSPICIOUSLY WRONG!!???
}
}
-
+
for (int i = layout->count() - 1; i >= 0; --i) {
QGraphicsLayoutItem *childItem = layout->itemAt(i);
if (childItem)
diff --git a/src/widgets/graphicsview/qgraphicslayout_p.h b/src/widgets/graphicsview/qgraphicslayout_p.h
index b1e93ef602..4257e5bc94 100644
--- a/src/widgets/graphicsview/qgraphicslayout_p.h
+++ b/src/widgets/graphicsview/qgraphicslayout_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicslayoutitem.cpp b/src/widgets/graphicsview/qgraphicslayoutitem.cpp
index e633514365..78b75e08d1 100644
--- a/src/widgets/graphicsview/qgraphicslayoutitem.cpp
+++ b/src/widgets/graphicsview/qgraphicslayoutitem.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicslayoutitem.h b/src/widgets/graphicsview/qgraphicslayoutitem.h
index b753790121..e1dfadcca0 100644
--- a/src/widgets/graphicsview/qgraphicslayoutitem.h
+++ b/src/widgets/graphicsview/qgraphicslayoutitem.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtWidgets/qsizepolicy.h>
#include <QtGui/qevent.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -148,6 +146,4 @@ inline qreal QGraphicsLayoutItem::maximumHeight() const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/widgets/graphicsview/qgraphicslayoutitem_p.h b/src/widgets/graphicsview/qgraphicslayoutitem_p.h
index 8c153c14e7..62f93f9091 100644
--- a/src/widgets/graphicsview/qgraphicslayoutitem_p.h
+++ b/src/widgets/graphicsview/qgraphicslayoutitem_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicslinearlayout.cpp b/src/widgets/graphicsview/qgraphicslinearlayout.cpp
index cd022bbf78..00076502ea 100644
--- a/src/widgets/graphicsview/qgraphicslinearlayout.cpp
+++ b/src/widgets/graphicsview/qgraphicslinearlayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicslinearlayout.h b/src/widgets/graphicsview/qgraphicslinearlayout.h
index 0aabc808a0..04e27515f1 100644
--- a/src/widgets/graphicsview/qgraphicslinearlayout.h
+++ b/src/widgets/graphicsview/qgraphicslinearlayout.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qgraphicsitem.h>
#include <QtWidgets/qgraphicslayout.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -112,7 +110,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/widgets/graphicsview/qgraphicsproxywidget.cpp b/src/widgets/graphicsview/qgraphicsproxywidget.cpp
index e9be1e015a..f84201cedf 100644
--- a/src/widgets/graphicsview/qgraphicsproxywidget.cpp
+++ b/src/widgets/graphicsview/qgraphicsproxywidget.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsproxywidget.h b/src/widgets/graphicsview/qgraphicsproxywidget.h
index a88899b900..8180cb9966 100644
--- a/src/widgets/graphicsview/qgraphicsproxywidget.h
+++ b/src/widgets/graphicsview/qgraphicsproxywidget.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qgraphicswidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -140,7 +138,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/widgets/graphicsview/qgraphicsproxywidget_p.h b/src/widgets/graphicsview/qgraphicsproxywidget_p.h
index bbc1c7ebc1..2eb4efaf18 100644
--- a/src/widgets/graphicsview/qgraphicsproxywidget_p.h
+++ b/src/widgets/graphicsview/qgraphicsproxywidget_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsscene.cpp b/src/widgets/graphicsview/qgraphicsscene.cpp
index cea376fea8..8a0b983c73 100644
--- a/src/widgets/graphicsview/qgraphicsscene.cpp
+++ b/src/widgets/graphicsview/qgraphicsscene.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -604,7 +604,7 @@ void QGraphicsScenePrivate::removeItemHelper(QGraphicsItem *item)
q->removeItem(item->d_ptr->children.at(i));
}
- if (!item->d_ptr->inDestructor && item == tabFocusFirst) {
+ if (!item->d_ptr->inDestructor && !item->parentItem() && item->isWidget()) {
QGraphicsWidget *widget = static_cast<QGraphicsWidget *>(item);
widget->d_func()->fixFocusChainBeforeReparenting(0, oldScene, 0);
}
@@ -739,12 +739,14 @@ void QGraphicsScenePrivate::setActivePanelHelper(QGraphicsItem *item, bool durin
if (panel == activePanel || (!q->isActive() && !duringActivationEvent))
return;
+ QGraphicsItem *oldFocusItem = focusItem;
+
// Deactivate the last active panel.
if (activePanel) {
if (QGraphicsItem *fi = activePanel->focusItem()) {
// Remove focus from the current focus item.
if (fi == q->focusItem())
- q->setFocusItem(0, Qt::ActiveWindowFocusReason);
+ setFocusItemHelper(0, Qt::ActiveWindowFocusReason, /* emitFocusChanged = */ false);
}
QEvent event(QEvent::WindowDeactivate);
@@ -768,9 +770,23 @@ void QGraphicsScenePrivate::setActivePanelHelper(QGraphicsItem *item, bool durin
QEvent event(QEvent::WindowActivate);
q->sendEvent(panel, &event);
- // Set focus on the panel's focus item.
- if (QGraphicsItem *focusItem = panel->focusItem())
- focusItem->setFocus(Qt::ActiveWindowFocusReason);
+ // Set focus on the panel's focus item, or itself if it's
+ // focusable, or on the first focusable item in the panel's
+ // focus chain as a last resort.
+ if (QGraphicsItem *focusItem = panel->focusItem()) {
+ setFocusItemHelper(focusItem, Qt::ActiveWindowFocusReason, /* emitFocusChanged = */ false);
+ } else if (panel->flags() & QGraphicsItem::ItemIsFocusable) {
+ setFocusItemHelper(panel, Qt::ActiveWindowFocusReason, /* emitFocusChanged = */ false);
+ } else if (panel->isWidget()) {
+ QGraphicsWidget *fw = static_cast<QGraphicsWidget *>(panel)->d_func()->focusNext;
+ do {
+ if (fw->focusPolicy() & Qt::TabFocus) {
+ setFocusItemHelper(fw, Qt::ActiveWindowFocusReason, /* emitFocusChanged = */ false);
+ break;
+ }
+ fw = fw->d_func()->focusNext;
+ } while (fw != panel);
+ }
} else if (q->isActive()) {
// Activate the scene
QEvent event(QEvent::WindowActivate);
@@ -779,13 +795,23 @@ void QGraphicsScenePrivate::setActivePanelHelper(QGraphicsItem *item, bool durin
q->sendEvent(item, &event);
}
}
+
+ emit q->focusItemChanged(focusItem, oldFocusItem, Qt::ActiveWindowFocusReason);
}
/*!
\internal
+
+ \a emitFocusChanged needs to be false when focus passes from one
+ item to another through setActivePanel(); i.e. when activation
+ passes from one panel to another, to avoid getting two focusChanged()
+ emissions; one focusChanged(0, lastFocus), then one
+ focusChanged(newFocus, 0). Instead setActivePanel() emits the signal
+ once itself: focusChanged(newFocus, oldFocus).
*/
void QGraphicsScenePrivate::setFocusItemHelper(QGraphicsItem *item,
- Qt::FocusReason focusReason)
+ Qt::FocusReason focusReason,
+ bool emitFocusChanged)
{
Q_Q(QGraphicsScene);
if (item == focusItem)
@@ -801,10 +827,14 @@ void QGraphicsScenePrivate::setFocusItemHelper(QGraphicsItem *item,
// Set focus on the scene if an item requests focus.
if (item) {
q->setFocus(focusReason);
- if (item == focusItem)
+ if (item == focusItem) {
+ if (emitFocusChanged)
+ emit q->focusItemChanged(focusItem, (QGraphicsItem *)0, focusReason);
return;
+ }
}
+ QGraphicsItem *oldFocusItem = focusItem;
if (focusItem) {
lastFocusItem = focusItem;
@@ -837,6 +867,9 @@ void QGraphicsScenePrivate::setFocusItemHelper(QGraphicsItem *item,
QFocusEvent event(QEvent::FocusIn, focusReason);
sendEvent(item, &event);
}
+
+ if (emitFocusChanged)
+ emit q->focusItemChanged(focusItem, oldFocusItem, focusReason);
}
/*!
@@ -2517,14 +2550,13 @@ void QGraphicsScene::addItem(QGraphicsItem *item)
// No first tab focus widget - make this the first tab focus
// widget.
d->tabFocusFirst = widget;
- } else if (!widget->parentWidget()) {
+ } else if (!widget->parentWidget() && !widget->isPanel()) {
// Adding a widget that is not part of a tab focus chain.
- QGraphicsWidget *last = d->tabFocusFirst->d_func()->focusPrev;
- QGraphicsWidget *lastNew = widget->d_func()->focusPrev;
- last->d_func()->focusNext = widget;
- widget->d_func()->focusPrev = last;
- d->tabFocusFirst->d_func()->focusPrev = lastNew;
- lastNew->d_func()->focusNext = d->tabFocusFirst;
+ QGraphicsWidget *myNewPrev = d->tabFocusFirst->d_func()->focusPrev;
+ myNewPrev->d_func()->focusNext = widget;
+ widget->d_func()->focusPrev->d_func()->focusNext = d->tabFocusFirst;
+ d->tabFocusFirst->d_func()->focusPrev = widget->d_func()->focusPrev;
+ widget->d_func()->focusPrev = myNewPrev;
}
}
@@ -5318,8 +5350,23 @@ bool QGraphicsScene::focusNextPrevChild(bool next)
setFocusItem(d->lastFocusItem, next ? Qt::TabFocusReason : Qt::BacktabFocusReason);
return true;
}
+ if (d->activePanel) {
+ if (d->activePanel->flags() & QGraphicsItem::ItemIsFocusable) {
+ setFocusItem(d->activePanel, next ? Qt::TabFocusReason : Qt::BacktabFocusReason);
+ return true;
+ }
+ if (d->activePanel->isWidget()) {
+ QGraphicsWidget *fw = static_cast<QGraphicsWidget *>(d->activePanel)->d_func()->focusNext;
+ do {
+ if (fw->focusPolicy() & Qt::TabFocus) {
+ setFocusItem(fw, next ? Qt::TabFocusReason : Qt::BacktabFocusReason);
+ return true;
+ }
+ } while (fw != d->activePanel);
+ }
+ }
}
- if (!d->tabFocusFirst) {
+ if (!item && !d->tabFocusFirst) {
// No widgets...
return false;
}
@@ -5331,8 +5378,10 @@ bool QGraphicsScene::focusNextPrevChild(bool next)
} else {
QGraphicsWidget *test = static_cast<QGraphicsWidget *>(item);
widget = next ? test->d_func()->focusNext : test->d_func()->focusPrev;
- if ((next && widget == d->tabFocusFirst) || (!next && widget == d->tabFocusFirst->d_func()->focusPrev))
+ if (!widget->panel() && ((next && widget == d->tabFocusFirst) || (!next && widget == d->tabFocusFirst->d_func()->focusPrev))) {
+ // Tab out of the scene.
return false;
+ }
}
QGraphicsWidget *widgetThatHadFocus = widget;
@@ -5396,6 +5445,25 @@ bool QGraphicsScene::focusNextPrevChild(bool next)
*/
/*!
+ \fn QGraphicsScene::focusChanged(QGraphicsItem *newFocusItem, QGraphicsItem *oldFocusItem, Qt::FocusReason reason)
+
+ This signal is emitted by QGraphicsScene whenever focus changes in the
+ scene (i.e., when an item gains or loses input focus, or when focus
+ passes from one item to another). You can connect to this signal if you
+ need to keep track of when other items gain input focus. It is
+ particularily useful for implementing virtual keyboards, input methods,
+ and cursor items.
+
+ \a oldFocusItem is a pointer to the item that previously had focus, or
+ 0 if no item had focus before the signal was emitted. \a newFocusItem
+ is a pointer to the item that gained input focus, or 0 if focus was lost.
+ \a reason is the reason for the focus change (e.g., if the scene was
+ deactivated while an input field had focus, \a oldFocusItem would point
+ to the input field item, \a newFocusItem would be 0, and \a reason would be
+ Qt::ActiveWindowFocusReason.
+*/
+
+/*!
\since 4.4
Returns the scene's style, or the same as QApplication::style() if the
@@ -5753,7 +5821,7 @@ void QGraphicsScenePrivate::touchEventHandler(QTouchEvent *sceneTouchEvent)
}
if (itemsNeedingEvents.isEmpty()) {
- sceneTouchEvent->accept();
+ sceneTouchEvent->ignore();
return;
}
diff --git a/src/widgets/graphicsview/qgraphicsscene.h b/src/widgets/graphicsview/qgraphicsscene.h
index 802d9c4970..cde0eda125 100644
--- a/src/widgets/graphicsview/qgraphicsscene.h
+++ b/src/widgets/graphicsview/qgraphicsscene.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -51,8 +51,6 @@
#include <QtGui/qmatrix.h>
#include <QtGui/qpen.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -292,6 +290,7 @@ Q_SIGNALS:
void changed(const QList<QRectF> &region);
void sceneRectChanged(const QRectF &rect);
void selectionChanged();
+ void focusItemChanged(QGraphicsItem *newFocus, QGraphicsItem *oldFocus, Qt::FocusReason reason);
private:
Q_DECLARE_PRIVATE(QGraphicsScene)
@@ -324,6 +323,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QGraphicsScene::SceneLayers)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/widgets/graphicsview/qgraphicsscene_bsp.cpp b/src/widgets/graphicsview/qgraphicsscene_bsp.cpp
index fa042bd9c5..55c52d1c6a 100644
--- a/src/widgets/graphicsview/qgraphicsscene_bsp.cpp
+++ b/src/widgets/graphicsview/qgraphicsscene_bsp.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsscene_bsp_p.h b/src/widgets/graphicsview/qgraphicsscene_bsp_p.h
index 17bdc6b390..88e34b7dea 100644
--- a/src/widgets/graphicsview/qgraphicsscene_bsp_p.h
+++ b/src/widgets/graphicsview/qgraphicsscene_bsp_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsscene_p.h b/src/widgets/graphicsview/qgraphicsscene_p.h
index 14cc240fa3..9e5bcec488 100644
--- a/src/widgets/graphicsview/qgraphicsscene_p.h
+++ b/src/widgets/graphicsview/qgraphicsscene_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -157,7 +157,8 @@ public:
int activationRefCount;
int childExplicitActivation;
void setActivePanelHelper(QGraphicsItem *item, bool duringActivationEvent);
- void setFocusItemHelper(QGraphicsItem *item, Qt::FocusReason focusReason);
+ void setFocusItemHelper(QGraphicsItem *item, Qt::FocusReason focusReason,
+ bool emitFocusChanged = true);
QList<QGraphicsWidget *> popupWidgets;
void addPopup(QGraphicsWidget *widget);
diff --git a/src/widgets/graphicsview/qgraphicsscenebsptreeindex.cpp b/src/widgets/graphicsview/qgraphicsscenebsptreeindex.cpp
index 64fc97cadf..f70e66f685 100644
--- a/src/widgets/graphicsview/qgraphicsscenebsptreeindex.cpp
+++ b/src/widgets/graphicsview/qgraphicsscenebsptreeindex.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicssceneevent.cpp b/src/widgets/graphicsview/qgraphicssceneevent.cpp
index 1b78228301..8eb1395a45 100644
--- a/src/widgets/graphicsview/qgraphicssceneevent.cpp
+++ b/src/widgets/graphicsview/qgraphicssceneevent.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicssceneevent.h b/src/widgets/graphicsview/qgraphicssceneevent.h
index 81a5321e0c..e744d08edf 100644
--- a/src/widgets/graphicsview/qgraphicssceneevent.h
+++ b/src/widgets/graphicsview/qgraphicssceneevent.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -50,8 +50,6 @@
#include <QtCore/qset.h>
#include <QtCore/qhash.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -320,6 +318,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/widgets/graphicsview/qgraphicssceneindex.cpp b/src/widgets/graphicsview/qgraphicssceneindex.cpp
index e07edd37e9..4b1c990578 100644
--- a/src/widgets/graphicsview/qgraphicssceneindex.cpp
+++ b/src/widgets/graphicsview/qgraphicssceneindex.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicssceneindex_p.h b/src/widgets/graphicsview/qgraphicssceneindex_p.h
index c5500e3d6e..29b321fb1d 100644
--- a/src/widgets/graphicsview/qgraphicssceneindex_p.h
+++ b/src/widgets/graphicsview/qgraphicssceneindex_p.h
@@ -61,8 +61,6 @@
#include <QtCore/qobject.h>
#include <QtGui/qtransform.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -176,6 +174,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGRAPHICSSCENEINDEX_H
diff --git a/src/widgets/graphicsview/qgraphicsscenelinearindex.cpp b/src/widgets/graphicsview/qgraphicsscenelinearindex.cpp
index 7b5bb7d04c..f4f5f8b30b 100644
--- a/src/widgets/graphicsview/qgraphicsscenelinearindex.cpp
+++ b/src/widgets/graphicsview/qgraphicsscenelinearindex.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsscenelinearindex_p.h b/src/widgets/graphicsview/qgraphicsscenelinearindex_p.h
index 607a15b949..7debcfb501 100644
--- a/src/widgets/graphicsview/qgraphicsscenelinearindex_p.h
+++ b/src/widgets/graphicsview/qgraphicsscenelinearindex_p.h
@@ -62,8 +62,6 @@
#include <QtWidgets/qgraphicsitem.h>
#include <private/qgraphicssceneindex_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -103,6 +101,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGRAPHICSSCENELINEARINDEX_H
diff --git a/src/widgets/graphicsview/qgraphicstransform.h b/src/widgets/graphicsview/qgraphicstransform.h
index 6c2c0d67f0..6f274201be 100644
--- a/src/widgets/graphicsview/qgraphicstransform.h
+++ b/src/widgets/graphicsview/qgraphicstransform.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -48,8 +48,6 @@
#include <QtGui/QMatrix4x4>
#ifndef QT_NO_GRAPHICSVIEW
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -152,7 +150,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
#endif //QT_NO_GRAPHICSVIEW
#endif // QFXTRANSFORM_H
diff --git a/src/widgets/graphicsview/qgraphicstransform_p.h b/src/widgets/graphicsview/qgraphicstransform_p.h
index 6215f58fe0..211443a77c 100644
--- a/src/widgets/graphicsview/qgraphicstransform_p.h
+++ b/src/widgets/graphicsview/qgraphicstransform_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicsview.cpp b/src/widgets/graphicsview/qgraphicsview.cpp
index 22ec829507..0424517346 100644
--- a/src/widgets/graphicsview/qgraphicsview.cpp
+++ b/src/widgets/graphicsview/qgraphicsview.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -256,6 +256,20 @@ static const int QGRAPHICSVIEW_PREALLOC_STYLE_OPTIONS = 503; // largest prime <
\sa dragMode, QGraphicsScene::setSelectionArea()
*/
+/*!
+ \since 5.1
+
+ \fn void QGraphicsView::rubberBandChanged(QRect rubberBandRect, QPointF fromScenePoint, QPointF toScenePoint)
+
+ This signal is emitted when the rubber band rect is changed. The viewport Rect is specified by \a rubberBandRect.
+ The drag start position and drag end position are provided in scene points with \a fromScenePoint and \a toScenePoint.
+
+ When rubberband selection ends this signal will be emitted with null vales.
+
+ \sa rubberBandRect()
+*/
+
+
#include "qgraphicsview.h"
#include "qgraphicsview_p.h"
@@ -706,56 +720,61 @@ QRegion QGraphicsViewPrivate::rubberBandRegion(const QWidget *widget, const QRec
return tmp;
}
-void QGraphicsViewPrivate::updateRubberBand(QMouseEvent *event)
+void QGraphicsViewPrivate::updateRubberBand(const QMouseEvent *event)
{
Q_Q(QGraphicsView);
- if (dragMode == QGraphicsView::RubberBandDrag && sceneInteractionAllowed) {
- storeMouseEvent(event);
- if (rubberBanding) {
- // Check for enough drag distance
- if ((mousePressViewPoint - event->pos()).manhattanLength()
- < QApplication::startDragDistance()) {
- return;
- }
+ if (dragMode != QGraphicsView::RubberBandDrag || !sceneInteractionAllowed || !rubberBanding)
+ return;
+ // Check for enough drag distance
+ if ((mousePressViewPoint - event->pos()).manhattanLength() < QApplication::startDragDistance())
+ return;
- // Update old rubberband
- if (viewportUpdateMode != QGraphicsView::NoViewportUpdate && !rubberBandRect.isEmpty()) {
- if (viewportUpdateMode != QGraphicsView::FullViewportUpdate)
- q->viewport()->update(rubberBandRegion(q->viewport(), rubberBandRect));
- else
- updateAll();
- }
+ // Update old rubberband
+ if (viewportUpdateMode != QGraphicsView::NoViewportUpdate && !rubberBandRect.isEmpty()) {
+ if (viewportUpdateMode != QGraphicsView::FullViewportUpdate)
+ q->viewport()->update(rubberBandRegion(q->viewport(), rubberBandRect));
+ else
+ updateAll();
+ }
- // Stop rubber banding if the user has let go of all buttons (even
- // if we didn't get the release events).
- if (!event->buttons()) {
- rubberBanding = false;
- rubberBandRect = QRect();
- return;
- }
+ // Stop rubber banding if the user has let go of all buttons (even
+ // if we didn't get the release events).
+ if (!event->buttons()) {
+ rubberBanding = false;
+ if (!rubberBandRect.isNull()) {
+ rubberBandRect = QRect();
+ emit q->rubberBandChanged(rubberBandRect, QPointF(), QPointF());
+ }
+ return;
+ }
- // Update rubberband position
- const QPoint mp = q->mapFromScene(mousePressScenePoint);
- const QPoint ep = event->pos();
- rubberBandRect = QRect(qMin(mp.x(), ep.x()), qMin(mp.y(), ep.y()),
- qAbs(mp.x() - ep.x()) + 1, qAbs(mp.y() - ep.y()) + 1);
+ QRect oldRubberband = rubberBandRect;
- // Update new rubberband
- if (viewportUpdateMode != QGraphicsView::NoViewportUpdate){
- if (viewportUpdateMode != QGraphicsView::FullViewportUpdate)
- q->viewport()->update(rubberBandRegion(q->viewport(), rubberBandRect));
- else
- updateAll();
- }
- // Set the new selection area
- QPainterPath selectionArea;
- selectionArea.addPolygon(mapToScene(rubberBandRect));
- selectionArea.closeSubpath();
- if (scene)
- scene->setSelectionArea(selectionArea, rubberBandSelectionMode,
- q->viewportTransform());
- }
+ // Update rubberband position
+ const QPoint mp = q->mapFromScene(mousePressScenePoint);
+ const QPoint ep = event->pos();
+ rubberBandRect = QRect(qMin(mp.x(), ep.x()), qMin(mp.y(), ep.y()),
+ qAbs(mp.x() - ep.x()) + 1, qAbs(mp.y() - ep.y()) + 1);
+
+ if (rubberBandRect != oldRubberband || lastRubberbandScenePoint != lastMouseMoveScenePoint) {
+ lastRubberbandScenePoint = lastMouseMoveScenePoint;
+ oldRubberband = rubberBandRect;
+ emit q->rubberBandChanged(rubberBandRect, mousePressScenePoint, lastRubberbandScenePoint);
}
+
+ // Update new rubberband
+ if (viewportUpdateMode != QGraphicsView::NoViewportUpdate) {
+ if (viewportUpdateMode != QGraphicsView::FullViewportUpdate)
+ q->viewport()->update(rubberBandRegion(q->viewport(), rubberBandRect));
+ else
+ updateAll();
+ }
+ // Set the new selection area
+ QPainterPath selectionArea;
+ selectionArea.addPolygon(mapToScene(rubberBandRect));
+ selectionArea.closeSubpath();
+ if (scene)
+ scene->setSelectionArea(selectionArea, rubberBandSelectionMode, q->viewportTransform());
}
#endif
@@ -1502,7 +1521,7 @@ void QGraphicsView::setDragMode(DragMode mode)
The default value is Qt::IntersectsItemShape; all items whose shape
intersects with or is contained by the rubber band are selected.
- \sa dragMode, items()
+ \sa dragMode, items(), rubberBandRect()
*/
Qt::ItemSelectionMode QGraphicsView::rubberBandSelectionMode() const
{
@@ -1514,6 +1533,27 @@ void QGraphicsView::setRubberBandSelectionMode(Qt::ItemSelectionMode mode)
Q_D(QGraphicsView);
d->rubberBandSelectionMode = mode;
}
+
+/*!
+ \since 5.1
+ This functions returns the current rubber band area (in viewport coordinates) if the user
+ is currently doing an itemselection with rubber band. When the user is not using the
+ rubber band this functions returns (a null) QRectF().
+
+ Notice that part of this QRect can be outise the visual viewport. It can e.g
+ contain negative values.
+
+ \sa rubberBandSelectionMode, rubberBandChanged()
+*/
+
+QRect QGraphicsView::rubberBandRect() const
+{
+ Q_D(const QGraphicsView);
+ if (d->dragMode != QGraphicsView::RubberBandDrag || !d->sceneInteractionAllowed || !d->rubberBanding)
+ return QRect();
+
+ return d->rubberBandRect;
+}
#endif
/*!
@@ -3301,7 +3341,10 @@ void QGraphicsView::mouseReleaseEvent(QMouseEvent *event)
d->updateAll();
}
d->rubberBanding = false;
- d->rubberBandRect = QRect();
+ if (!d->rubberBandRect.isNull()) {
+ d->rubberBandRect = QRect();
+ emit rubberBandChanged(d->rubberBandRect, QPointF(), QPointF());
+ }
}
} else
#endif
diff --git a/src/widgets/graphicsview/qgraphicsview.h b/src/widgets/graphicsview/qgraphicsview.h
index 488e12511c..670c3251b5 100644
--- a/src/widgets/graphicsview/qgraphicsview.h
+++ b/src/widgets/graphicsview/qgraphicsview.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtWidgets/qscrollarea.h>
#include <QtWidgets/qgraphicsscene.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -148,6 +146,7 @@ public:
#ifndef QT_NO_RUBBERBAND
Qt::ItemSelectionMode rubberBandSelectionMode() const;
void setRubberBandSelectionMode(Qt::ItemSelectionMode mode);
+ QRect rubberBandRect() const;
#endif
CacheMode cacheMode() const;
@@ -228,6 +227,11 @@ public Q_SLOTS:
void invalidateScene(const QRectF &rect = QRectF(), QGraphicsScene::SceneLayers layers = QGraphicsScene::AllLayers);
void updateSceneRect(const QRectF &rect);
+#ifndef QT_NO_RUBBERBAND
+Q_SIGNALS:
+ void rubberBandChanged(QRect viewportRect, QPointF fromScenePoint, QPointF toScenePoint);
+#endif
+
protected Q_SLOTS:
void setupViewport(QWidget *widget);
@@ -310,6 +314,4 @@ inline QPolygon QGraphicsView::mapFromScene(qreal ax, qreal ay, qreal w, qreal h
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGRAPHICSVIEW_H
diff --git a/src/widgets/graphicsview/qgraphicsview_p.h b/src/widgets/graphicsview/qgraphicsview_p.h
index 9f0e3e3b24..5725fd9c19 100644
--- a/src/widgets/graphicsview/qgraphicsview_p.h
+++ b/src/widgets/graphicsview/qgraphicsview_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -110,6 +110,7 @@ public:
QPoint mousePressViewPoint;
QPoint mousePressScreenPoint;
QPointF lastMouseMoveScenePoint;
+ QPointF lastRubberbandScenePoint;
QPoint lastMouseMoveScreenPoint;
QPoint dirtyScrollOffset;
Qt::MouseButton mousePressButton;
@@ -138,7 +139,7 @@ public:
#ifndef QT_NO_RUBBERBAND
QRect rubberBandRect;
QRegion rubberBandRegion(const QWidget *widget, const QRect &rect) const;
- void updateRubberBand(QMouseEvent *event);
+ void updateRubberBand(const QMouseEvent *event);
bool rubberBanding;
Qt::ItemSelectionMode rubberBandSelectionMode;
#endif
diff --git a/src/widgets/graphicsview/qgraphicswidget.cpp b/src/widgets/graphicsview/qgraphicswidget.cpp
index 2d7fca8000..ddd3ee2e68 100644
--- a/src/widgets/graphicsview/qgraphicswidget.cpp
+++ b/src/widgets/graphicsview/qgraphicswidget.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgraphicswidget.h b/src/widgets/graphicsview/qgraphicswidget.h
index 3f8720f6e9..8881fec1d6 100644
--- a/src/widgets/graphicsview/qgraphicswidget.h
+++ b/src/widgets/graphicsview/qgraphicswidget.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtWidgets/qgraphicsitem.h>
#include <QtGui/qpalette.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -245,7 +243,5 @@ inline void QGraphicsWidget::setGeometry(qreal ax, qreal ay, qreal aw, qreal ah)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/widgets/graphicsview/qgraphicswidget_p.cpp b/src/widgets/graphicsview/qgraphicswidget_p.cpp
index e97ec90cd0..14cd7007ba 100644
--- a/src/widgets/graphicsview/qgraphicswidget_p.cpp
+++ b/src/widgets/graphicsview/qgraphicswidget_p.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -764,73 +764,59 @@ bool QGraphicsWidgetPrivate::hasDecoration() const
void QGraphicsWidgetPrivate::fixFocusChainBeforeReparenting(QGraphicsWidget *newParent, QGraphicsScene *oldScene, QGraphicsScene *newScene)
{
Q_Q(QGraphicsWidget);
-
Q_ASSERT(focusNext && focusPrev);
- QGraphicsWidget *n = q; //last one in 'new' list
- QGraphicsWidget *o = 0; //last one in 'old' list
-
- QGraphicsWidget *w = focusNext;
-
- QGraphicsWidget *firstOld = 0;
- bool wasPreviousNew = true;
-
- while (w != q) {
- bool isCurrentNew = q->isAncestorOf(w);
- if (isCurrentNew) {
- if (!wasPreviousNew) {
- n->d_func()->focusNext = w;
- w->d_func()->focusPrev = n;
- }
- n = w;
- } else /*if (!isCurrentNew)*/ {
- if (wasPreviousNew) {
- if (o) {
- o->d_func()->focusNext = w;
- w->d_func()->focusPrev = o;
- } else {
- firstOld = w;
- }
- }
- o = w;
- }
- w = w->d_func()->focusNext;
- wasPreviousNew = isCurrentNew;
- }
-
- // repair the 'old' chain
- if (firstOld) {
- o->d_func()->focusNext = firstOld;
- firstOld->d_func()->focusPrev = o;
+ if (q_ptr->isPanel()) {
+ // panels are never a part of their parent's or ancestors' focus
+ // chains. so reparenting a panel is easy; there's nothing to
+ // do.
+ return;
}
- // update tabFocusFirst for oldScene if the item is going to be removed from oldScene
- if (newParent)
- newScene = newParent->scene();
-
- if (oldScene && newScene != oldScene)
- oldScene->d_func()->tabFocusFirst = (firstOld && firstOld->scene() == oldScene) ? firstOld : 0;
-
- QGraphicsItem *topLevelItem = newParent ? newParent->topLevelItem() : 0;
- QGraphicsWidget *topLevel = 0;
- if (topLevelItem && topLevelItem->isWidget())
- topLevel = static_cast<QGraphicsWidget *>(topLevelItem);
+ // we're not a panel, so find the first widget in the focus chain
+ // (this), and the last (this, or the last widget that is still
+ // a descendent of this). also find the widgets that currently /
+ // before reparenting point to this widgets' focus chain.
+ QGraphicsWidget *focusFirst = q;
+ QGraphicsWidget *focusBefore = focusPrev;
+ QGraphicsWidget *focusLast = focusFirst;
+ QGraphicsWidget *focusAfter = focusNext;
+ do {
+ if (!q->isAncestorOf(focusAfter))
+ break;
+ focusLast = focusAfter;
+ } while ((focusAfter = focusAfter->d_func()->focusNext));
- if (topLevel && newParent) {
- QGraphicsWidget *last = topLevel->d_func()->focusPrev;
- // link last with new chain
- last->d_func()->focusNext = q;
- focusPrev = last;
+ if (!parent && oldScene && oldScene != newScene && oldScene->d_func()->tabFocusFirst == q) {
+ // detach from old scene's top level focus chain.
+ oldScene->d_func()->tabFocusFirst = (focusAfter != q) ? focusAfter : 0;
+ }
- // link last in chain with
- topLevel->d_func()->focusPrev = n;
- n->d_func()->focusNext = topLevel;
+ // detach from current focus chain; skip this widget subtree.
+ focusBefore->d_func()->focusNext = focusAfter;
+ focusAfter->d_func()->focusPrev = focusBefore;
+
+ if (newParent) {
+ // attach to new parent's focus chain as the last element
+ // in its chain.
+ QGraphicsWidget *newFocusFirst = newParent;
+ QGraphicsWidget *newFocusLast = newFocusFirst;
+ QGraphicsWidget *newFocusAfter = newFocusFirst->d_func()->focusNext;
+ do {
+ if (!newParent->isAncestorOf(newFocusAfter))
+ break;
+ newFocusLast = newFocusAfter;
+ } while ((newFocusAfter = newFocusAfter->d_func()->focusNext));
+
+ newFocusLast->d_func()->focusNext = q;
+ focusLast->d_func()->focusNext = newFocusAfter;
+ newFocusAfter->d_func()->focusPrev = focusLast;
+ focusPrev = newFocusLast;
} else {
- // q is the start of the focus chain
- n->d_func()->focusNext = q;
- focusPrev = n;
+ // no new parent, so just link up our own prev->last widgets.
+ focusPrev = focusLast;
+ focusLast->d_func()->focusNext = q;
}
-
}
void QGraphicsWidgetPrivate::setLayout_helper(QGraphicsLayout *l)
diff --git a/src/widgets/graphicsview/qgraphicswidget_p.h b/src/widgets/graphicsview/qgraphicswidget_p.h
index d0d3fe3b22..759d8561b0 100644
--- a/src/widgets/graphicsview/qgraphicswidget_p.h
+++ b/src/widgets/graphicsview/qgraphicswidget_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgridlayoutengine.cpp b/src/widgets/graphicsview/qgridlayoutengine.cpp
index cfb4ae3e3e..b80612bc47 100644
--- a/src/widgets/graphicsview/qgridlayoutengine.cpp
+++ b/src/widgets/graphicsview/qgridlayoutengine.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qgridlayoutengine_p.h b/src/widgets/graphicsview/qgridlayoutengine_p.h
index 34f6940e23..fbc5bd6ad2 100644
--- a/src/widgets/graphicsview/qgridlayoutengine_p.h
+++ b/src/widgets/graphicsview/qgridlayoutengine_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qsimplex_p.cpp b/src/widgets/graphicsview/qsimplex_p.cpp
index ec665498a8..a2437d8ab1 100644
--- a/src/widgets/graphicsview/qsimplex_p.cpp
+++ b/src/widgets/graphicsview/qsimplex_p.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/graphicsview/qsimplex_p.h b/src/widgets/graphicsview/qsimplex_p.h
index 692e2e7155..842044fa7f 100644
--- a/src/widgets/graphicsview/qsimplex_p.h
+++ b/src/widgets/graphicsview/qsimplex_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qabstractitemdelegate.cpp b/src/widgets/itemviews/qabstractitemdelegate.cpp
index 4c73cf71a5..7786a74cc6 100644
--- a/src/widgets/itemviews/qabstractitemdelegate.cpp
+++ b/src/widgets/itemviews/qabstractitemdelegate.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qabstractitemdelegate.h b/src/widgets/itemviews/qabstractitemdelegate.h
index 28635b0595..13e4f06687 100644
--- a/src/widgets/itemviews/qabstractitemdelegate.h
+++ b/src/widgets/itemviews/qabstractitemdelegate.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtCore/qobject.h>
#include <QtWidgets/qstyleoption.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -131,6 +129,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QABSTRACTITEMDELEGATE_H
diff --git a/src/widgets/itemviews/qabstractitemview.cpp b/src/widgets/itemviews/qabstractitemview.cpp
index fa873b63a5..70c8f44a73 100644
--- a/src/widgets/itemviews/qabstractitemview.cpp
+++ b/src/widgets/itemviews/qabstractitemview.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -63,7 +63,7 @@
#include <private/qabstractitemmodel_p.h>
#ifndef QT_NO_ACCESSIBILITY
#include <qaccessible.h>
-#include <qaccessible2.h>
+#include <private/qaccessible2_p.h>
#endif
#ifndef QT_NO_GESTURES
# include <qscroller.h>
@@ -1853,7 +1853,8 @@ void QAbstractItemView::mouseReleaseEvent(QMouseEvent *event)
QStyleOptionViewItem option = d->viewOptions();
if (d->pressedAlreadySelected)
option.state |= QStyle::State_Selected;
- if (style()->styleHint(QStyle::SH_ItemView_ActivateItemOnSingleClick, &option, this))
+ if ((model()->flags(index) & Qt::ItemIsEnabled)
+ && style()->styleHint(QStyle::SH_ItemView_ActivateItemOnSingleClick, &option, this))
emit activated(index);
}
}
@@ -3816,13 +3817,31 @@ QItemSelectionModel::SelectionFlags QAbstractItemView::selectionCommand(const QM
const QEvent *event) const
{
Q_D(const QAbstractItemView);
+ Qt::KeyboardModifiers keyModifiers = Qt::NoModifier;
+ if (event) {
+ switch (event->type()) {
+ case QEvent::MouseButtonDblClick:
+ case QEvent::MouseButtonPress:
+ case QEvent::MouseButtonRelease:
+ case QEvent::MouseMove:
+ case QEvent::KeyPress:
+ case QEvent::KeyRelease:
+ keyModifiers = (static_cast<const QInputEvent*>(event))->modifiers();
+ break;
+ default:
+ keyModifiers = QApplication::keyboardModifiers();
+ }
+ }
switch (d->selectionMode) {
case NoSelection: // Never update selection model
return QItemSelectionModel::NoUpdate;
case SingleSelection: // ClearAndSelect on valid index otherwise NoUpdate
if (event && event->type() == QEvent::MouseButtonRelease)
return QItemSelectionModel::NoUpdate;
- return QItemSelectionModel::ClearAndSelect|d->selectionBehaviorFlags();
+ if ((keyModifiers & Qt::ControlModifier) && d->selectionModel->isSelected(index))
+ return QItemSelectionModel::Deselect | d->selectionBehaviorFlags();
+ else
+ return QItemSelectionModel::ClearAndSelect | d->selectionBehaviorFlags();
case MultiSelection:
return d->multiSelectionCommand(index, event);
case ExtendedSelection:
diff --git a/src/widgets/itemviews/qabstractitemview.h b/src/widgets/itemviews/qabstractitemview.h
index ad5e1de562..96428515ae 100644
--- a/src/widgets/itemviews/qabstractitemview.h
+++ b/src/widgets/itemviews/qabstractitemview.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtCore/qitemselectionmodel.h>
#include <QtWidgets/qabstractitemdelegate.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -376,6 +374,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QAbstractItemView::EditTriggers)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QABSTRACTITEMVIEW_H
diff --git a/src/widgets/itemviews/qabstractitemview_p.h b/src/widgets/itemviews/qabstractitemview_p.h
index c7b807cf5f..86eab174ed 100644
--- a/src/widgets/itemviews/qabstractitemview_p.h
+++ b/src/widgets/itemviews/qabstractitemview_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qbsptree.cpp b/src/widgets/itemviews/qbsptree.cpp
index c0be07e3c1..a4da0b73fd 100644
--- a/src/widgets/itemviews/qbsptree.cpp
+++ b/src/widgets/itemviews/qbsptree.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qbsptree_p.h b/src/widgets/itemviews/qbsptree_p.h
index 4d652193eb..3210efbd3d 100644
--- a/src/widgets/itemviews/qbsptree_p.h
+++ b/src/widgets/itemviews/qbsptree_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qcolumnview.cpp b/src/widgets/itemviews/qcolumnview.cpp
index 0951626a41..5aee78fab4 100644
--- a/src/widgets/itemviews/qcolumnview.cpp
+++ b/src/widgets/itemviews/qcolumnview.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qcolumnview.h b/src/widgets/itemviews/qcolumnview.h
index a340be0823..a13433bb2d 100644
--- a/src/widgets/itemviews/qcolumnview.h
+++ b/src/widgets/itemviews/qcolumnview.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qabstractitemview.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -116,7 +114,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOLUMNVIEW_H
diff --git a/src/widgets/itemviews/qcolumnview_p.h b/src/widgets/itemviews/qcolumnview_p.h
index b25f690165..3d54c9098a 100644
--- a/src/widgets/itemviews/qcolumnview_p.h
+++ b/src/widgets/itemviews/qcolumnview_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qcolumnviewgrip.cpp b/src/widgets/itemviews/qcolumnviewgrip.cpp
index f93965f49f..614916dc61 100644
--- a/src/widgets/itemviews/qcolumnviewgrip.cpp
+++ b/src/widgets/itemviews/qcolumnviewgrip.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qcolumnviewgrip_p.h b/src/widgets/itemviews/qcolumnviewgrip_p.h
index 9d57231c30..c508c58c5b 100644
--- a/src/widgets/itemviews/qcolumnviewgrip_p.h
+++ b/src/widgets/itemviews/qcolumnviewgrip_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qdatawidgetmapper.cpp b/src/widgets/itemviews/qdatawidgetmapper.cpp
index 9ba0e2a102..e5b7e810fb 100644
--- a/src/widgets/itemviews/qdatawidgetmapper.cpp
+++ b/src/widgets/itemviews/qdatawidgetmapper.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qdatawidgetmapper.h b/src/widgets/itemviews/qdatawidgetmapper.h
index d65d06a4ab..b8742196b2 100644
--- a/src/widgets/itemviews/qdatawidgetmapper.h
+++ b/src/widgets/itemviews/qdatawidgetmapper.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#ifndef QT_NO_DATAWIDGETMAPPER
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -120,8 +118,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_DATAWIDGETMAPPER
#endif
diff --git a/src/widgets/itemviews/qdirmodel.cpp b/src/widgets/itemviews/qdirmodel.cpp
index fcf8c92a7b..e1ba0ede57 100644
--- a/src/widgets/itemviews/qdirmodel.cpp
+++ b/src/widgets/itemviews/qdirmodel.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qdirmodel.h b/src/widgets/itemviews/qdirmodel.h
index 6ecd9a3990..c0214395ef 100644
--- a/src/widgets/itemviews/qdirmodel.h
+++ b/src/widgets/itemviews/qdirmodel.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtCore/qdir.h>
#include <QtWidgets/qfileiconprovider.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -154,6 +152,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDIRMODEL_H
diff --git a/src/widgets/itemviews/qfileiconprovider.cpp b/src/widgets/itemviews/qfileiconprovider.cpp
index b016fcdffe..8a0736ec70 100644
--- a/src/widgets/itemviews/qfileiconprovider.cpp
+++ b/src/widgets/itemviews/qfileiconprovider.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qfileiconprovider.h b/src/widgets/itemviews/qfileiconprovider.h
index a7a7d508ce..cac135fe71 100644
--- a/src/widgets/itemviews/qfileiconprovider.h
+++ b/src/widgets/itemviews/qfileiconprovider.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtCore/qscopedpointer.h>
#include <QtGui/qicon.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -75,7 +73,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFILEICONPROVIDER_H
diff --git a/src/widgets/itemviews/qheaderview.cpp b/src/widgets/itemviews/qheaderview.cpp
index ec5620c14c..edfbc5c8f1 100644
--- a/src/widgets/itemviews/qheaderview.cpp
+++ b/src/widgets/itemviews/qheaderview.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -1082,6 +1082,8 @@ int QHeaderView::logicalIndex(int visualIndex) const
}
/*!
+ \since 5.0
+
If \a movable is true, the header may be moved by the user; otherwise it
is fixed in place.
@@ -1105,6 +1107,8 @@ void QHeaderView::setSectionsMovable(bool movable)
*/
/*!
+ \since 5.0
+
Returns true if the header can be moved by the user; otherwise returns
false.
@@ -1128,6 +1132,8 @@ bool QHeaderView::sectionsMovable() const
*/
/*!
+ \since 5.0
+
If \a clickable is true, the header will respond to single clicks.
\sa sectionsClickable(), sectionClicked(), sectionPressed(),
@@ -1151,6 +1157,8 @@ void QHeaderView::setSectionsClickable(bool clickable)
*/
/*!
+ \since 5.0
+
Returns true if the header is clickable; otherwise returns false. A
clickable header could be set up to allow the user to change the
representation of the data in the view related to the header.
@@ -1187,6 +1195,8 @@ bool QHeaderView::highlightSections() const
}
/*!
+ \since 5.0
+
Sets the constraints on how the header can be resized to those described
by the given \a mode.
@@ -1205,6 +1215,8 @@ void QHeaderView::setSectionResizeMode(ResizeMode mode)
}
/*!
+ \since 5.0
+
Sets the constraints on how the section specified by \a logicalIndex in
the header can be resized to those described by the given \a mode. The logical
index should exist at the time this function is called.
@@ -1259,6 +1271,8 @@ void QHeaderView::setSectionResizeMode(int logicalIndex, ResizeMode mode)
*/
/*!
+ \since 5.0
+
Returns the resize mode that applies to the section specified by the given
\a logicalIndex.
diff --git a/src/widgets/itemviews/qheaderview.h b/src/widgets/itemviews/qheaderview.h
index 4e2b7d24c6..8fcd8d7a36 100644
--- a/src/widgets/itemviews/qheaderview.h
+++ b/src/widgets/itemviews/qheaderview.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qabstractitemview.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -263,6 +261,4 @@ inline void QHeaderView::showSection(int alogicalIndex)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QHEADERVIEW_H
diff --git a/src/widgets/itemviews/qheaderview_p.h b/src/widgets/itemviews/qheaderview_p.h
index 4abca63519..7fda0c8873 100644
--- a/src/widgets/itemviews/qheaderview_p.h
+++ b/src/widgets/itemviews/qheaderview_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qitemdelegate.cpp b/src/widgets/itemviews/qitemdelegate.cpp
index 299f916098..f2c3c4702f 100644
--- a/src/widgets/itemviews/qitemdelegate.cpp
+++ b/src/widgets/itemviews/qitemdelegate.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -1299,6 +1299,9 @@ QStyleOptionViewItem QItemDelegate::setOptions(const QModelIndex &index,
if (value.canConvert<QBrush>())
opt.palette.setBrush(QPalette::Text, qvariant_cast<QBrush>(value));
+ // disable style animations for checkboxes etc. within itemviews (QTBUG-30146)
+ opt.styleObject = 0;
+
return opt;
}
diff --git a/src/widgets/itemviews/qitemdelegate.h b/src/widgets/itemviews/qitemdelegate.h
index 17b0e94625..2866a4bb8b 100644
--- a/src/widgets/itemviews/qitemdelegate.h
+++ b/src/widgets/itemviews/qitemdelegate.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtGui/qpixmap.h>
#include <QtCore/qvariant.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -135,6 +133,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QITEMDELEGATE_H
diff --git a/src/widgets/itemviews/qitemeditorfactory.cpp b/src/widgets/itemviews/qitemeditorfactory.cpp
index 99e8c2e36e..b3ef21e3e5 100644
--- a/src/widgets/itemviews/qitemeditorfactory.cpp
+++ b/src/widgets/itemviews/qitemeditorfactory.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qitemeditorfactory.h b/src/widgets/itemviews/qitemeditorfactory.h
index f52f4c5b64..9affe14925 100644
--- a/src/widgets/itemviews/qitemeditorfactory.h
+++ b/src/widgets/itemviews/qitemeditorfactory.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtCore/qhash.h>
#include <QtCore/qvariant.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -118,6 +116,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QITEMEDITORFACTORY_H
diff --git a/src/widgets/itemviews/qitemeditorfactory_p.h b/src/widgets/itemviews/qitemeditorfactory_p.h
index ca4334e015..c652da764c 100644
--- a/src/widgets/itemviews/qitemeditorfactory_p.h
+++ b/src/widgets/itemviews/qitemeditorfactory_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qlistview.cpp b/src/widgets/itemviews/qlistview.cpp
index 6198953857..8ccb0557cb 100644
--- a/src/widgets/itemviews/qlistview.cpp
+++ b/src/widgets/itemviews/qlistview.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qlistview.h b/src/widgets/itemviews/qlistview.h
index a7164142dd..e4ae2d03fd 100644
--- a/src/widgets/itemviews/qlistview.h
+++ b/src/widgets/itemviews/qlistview.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qabstractitemview.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -193,6 +191,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLISTVIEW_H
diff --git a/src/widgets/itemviews/qlistview_p.h b/src/widgets/itemviews/qlistview_p.h
index 8d6f7f864a..35d11140ef 100644
--- a/src/widgets/itemviews/qlistview_p.h
+++ b/src/widgets/itemviews/qlistview_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qlistwidget.cpp b/src/widgets/itemviews/qlistwidget.cpp
index 7de571f59b..39d03124ce 100644
--- a/src/widgets/itemviews/qlistwidget.cpp
+++ b/src/widgets/itemviews/qlistwidget.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qlistwidget.h b/src/widgets/itemviews/qlistwidget.h
index 1a8c56c907..a7f993d25c 100644
--- a/src/widgets/itemviews/qlistwidget.h
+++ b/src/widgets/itemviews/qlistwidget.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtCore/qvector.h>
#include <QtCore/qitemselectionmodel.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -329,6 +327,4 @@ inline bool QListWidgetItem::isHidden() const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLISTWIDGET_H
diff --git a/src/widgets/itemviews/qlistwidget_p.h b/src/widgets/itemviews/qlistwidget_p.h
index 22a3d8ea88..2181a77fcb 100644
--- a/src/widgets/itemviews/qlistwidget_p.h
+++ b/src/widgets/itemviews/qlistwidget_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qstyleditemdelegate.cpp b/src/widgets/itemviews/qstyleditemdelegate.cpp
index 995be3e786..b121800c31 100644
--- a/src/widgets/itemviews/qstyleditemdelegate.cpp
+++ b/src/widgets/itemviews/qstyleditemdelegate.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -355,7 +355,10 @@ void QStyledItemDelegate::initStyleOption(QStyleOptionViewItem *option,
else
mode = QIcon::Normal;
QIcon::State state = option->state & QStyle::State_Open ? QIcon::On : QIcon::Off;
- option->decorationSize = option->icon.actualSize(option->decorationSize, mode, state);
+ QSize actualSize = option->icon.actualSize(option->decorationSize, mode, state);
+ // For highdpi icons actualSize might be larger than decorationSize, which we don't want. Clamp it to decorationSize.
+ option->decorationSize = QSize(qMin(option->decorationSize.width(), actualSize.width()),
+ qMin(option->decorationSize.height(), actualSize.height()));
break;
}
case QVariant::Color: {
@@ -367,13 +370,13 @@ void QStyledItemDelegate::initStyleOption(QStyleOptionViewItem *option,
case QVariant::Image: {
QImage image = qvariant_cast<QImage>(value);
option->icon = QIcon(QPixmap::fromImage(image));
- option->decorationSize = image.size();
+ option->decorationSize = image.size() / image.devicePixelRatio();
break;
}
case QVariant::Pixmap: {
QPixmap pixmap = qvariant_cast<QPixmap>(value);
option->icon = QIcon(pixmap);
- option->decorationSize = pixmap.size();
+ option->decorationSize = pixmap.size() / pixmap.devicePixelRatio();
break;
}
default:
@@ -388,6 +391,9 @@ void QStyledItemDelegate::initStyleOption(QStyleOptionViewItem *option,
}
option->backgroundBrush = qvariant_cast<QBrush>(index.data(Qt::BackgroundRole));
+
+ // disable style animations for checkboxes etc. within itemviews (QTBUG-30146)
+ option->styleObject = 0;
}
/*!
diff --git a/src/widgets/itemviews/qstyleditemdelegate.h b/src/widgets/itemviews/qstyleditemdelegate.h
index 8aa056d769..aeb25a55b7 100644
--- a/src/widgets/itemviews/qstyleditemdelegate.h
+++ b/src/widgets/itemviews/qstyleditemdelegate.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtGui/qpixmap.h>
#include <QtCore/qvariant.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -110,6 +108,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTYLEDITEMDELEGATE_H
diff --git a/src/widgets/itemviews/qtableview.cpp b/src/widgets/itemviews/qtableview.cpp
index 3f19a0fb1f..38e4a0bf9b 100644
--- a/src/widgets/itemviews/qtableview.cpp
+++ b/src/widgets/itemviews/qtableview.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qtableview.h b/src/widgets/itemviews/qtableview.h
index 8f4c73d9f1..824348dbe8 100644
--- a/src/widgets/itemviews/qtableview.h
+++ b/src/widgets/itemviews/qtableview.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qabstractitemview.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -192,6 +190,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTABLEVIEW_H
diff --git a/src/widgets/itemviews/qtableview_p.h b/src/widgets/itemviews/qtableview_p.h
index 5cd970b684..923beec253 100644
--- a/src/widgets/itemviews/qtableview_p.h
+++ b/src/widgets/itemviews/qtableview_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qtablewidget.cpp b/src/widgets/itemviews/qtablewidget.cpp
index ca92c3687a..d56314b23d 100644
--- a/src/widgets/itemviews/qtablewidget.cpp
+++ b/src/widgets/itemviews/qtablewidget.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qtablewidget.h b/src/widgets/itemviews/qtablewidget.h
index 6d9da27fdf..fba76129a7 100644
--- a/src/widgets/itemviews/qtablewidget.h
+++ b/src/widgets/itemviews/qtablewidget.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtCore/qvector.h>
//#include <QtWidgets/qitemselectionmodel.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -371,6 +369,4 @@ inline bool QTableWidgetItem::isSelected() const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTABLEWIDGET_H
diff --git a/src/widgets/itemviews/qtablewidget_p.h b/src/widgets/itemviews/qtablewidget_p.h
index a6b33bd5bb..43eb56a4a5 100644
--- a/src/widgets/itemviews/qtablewidget_p.h
+++ b/src/widgets/itemviews/qtablewidget_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qtreeview.cpp b/src/widgets/itemviews/qtreeview.cpp
index 6046ef50a5..70523815e8 100644
--- a/src/widgets/itemviews/qtreeview.cpp
+++ b/src/widgets/itemviews/qtreeview.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -52,9 +52,10 @@
#include <qevent.h>
#include <qpen.h>
#include <qdebug.h>
+#include <QMetaMethod>
#ifndef QT_NO_ACCESSIBILITY
#include <qaccessible.h>
-#include <qaccessible2.h>
+#include <private/qaccessible2_p.h>
#endif
#include <private/qtreeview_p.h>
@@ -749,6 +750,8 @@ void QTreeView::expand(const QModelIndex &index)
Q_D(QTreeView);
if (!d->isIndexValid(index))
return;
+ if (index.flags() & Qt::ItemNeverHasChildren)
+ return;
if (d->delayedPendingLayout) {
//A complete relayout is going to be performed, just store the expanded index, no need to layout.
if (d->storeExpanded(index))
@@ -2644,7 +2647,17 @@ void QTreeView::expandAll()
void QTreeView::collapseAll()
{
Q_D(QTreeView);
+ QSet<QPersistentModelIndex> old_expandedIndexes;
+ old_expandedIndexes = d->expandedIndexes;
d->expandedIndexes.clear();
+ if (!signalsBlocked() && isSignalConnected(QMetaMethod::fromSignal(&QTreeView::collapsed))) {
+ QSet<QPersistentModelIndex>::const_iterator i = old_expandedIndexes.constBegin();
+ for (; i != old_expandedIndexes.constEnd(); ++i) {
+ const QPersistentModelIndex &mi = (*i);
+ if (mi.isValid() && !(mi.flags() & Qt::ItemNeverHasChildren))
+ emit collapsed(mi);
+ }
+ }
doItemsLayout();
}
@@ -2658,6 +2671,8 @@ void QTreeView::expandToDepth(int depth)
{
Q_D(QTreeView);
d->viewItems.clear();
+ QSet<QPersistentModelIndex> old_expandedIndexes;
+ old_expandedIndexes = d->expandedIndexes;
d->expandedIndexes.clear();
d->interruptDelayedItemsLayout();
d->layout(-1);
@@ -2668,6 +2683,29 @@ void QTreeView::expandToDepth(int depth)
d->storeExpanded(d->viewItems.at(i).index);
}
}
+
+ bool someSignalEnabled = isSignalConnected(QMetaMethod::fromSignal(&QTreeView::collapsed));
+ someSignalEnabled |= isSignalConnected(QMetaMethod::fromSignal(&QTreeView::expanded));
+
+ if (!signalsBlocked() && someSignalEnabled) {
+ // emit signals
+ QSet<QPersistentModelIndex> collapsedIndexes = old_expandedIndexes - d->expandedIndexes;
+ QSet<QPersistentModelIndex>::const_iterator i = collapsedIndexes.constBegin();
+ for (; i != collapsedIndexes.constEnd(); ++i) {
+ const QPersistentModelIndex &mi = (*i);
+ if (mi.isValid() && !(mi.flags() & Qt::ItemNeverHasChildren))
+ emit collapsed(mi);
+ }
+
+ QSet<QPersistentModelIndex> expandedIndexs = d->expandedIndexes - old_expandedIndexes;
+ i = expandedIndexs.constBegin();
+ for (; i != expandedIndexs.constEnd(); ++i) {
+ const QPersistentModelIndex &mi = (*i);
+ if (mi.isValid() && !(mi.flags() & Qt::ItemNeverHasChildren))
+ emit expanded(mi);
+ }
+ }
+
updateGeometries();
d->viewport->update();
}
@@ -2887,6 +2925,9 @@ void QTreeViewPrivate::expand(int item, bool emitSignal)
if (item == -1 || viewItems.at(item).expanded)
return;
+ const QModelIndex index = viewItems.at(item).index;
+ if (index.flags() & Qt::ItemNeverHasChildren)
+ return;
#ifndef QT_NO_ANIMATION
if (emitSignal && animationsEnabled)
@@ -2896,7 +2937,6 @@ void QTreeViewPrivate::expand(int item, bool emitSignal)
if (state != QAbstractItemView::AnimatingState)
stateBeforeAnimation = state;
q->setState(QAbstractItemView::ExpandingState);
- const QModelIndex index = viewItems.at(item).index;
storeExpanded(index);
viewItems[item].expanded = true;
layout(item);
@@ -3189,9 +3229,9 @@ void QTreeViewPrivate::layout(int i, bool recursiveExpanding, bool afterIsUninit
item->expanded = false;
item->total = 0;
item->hasMoreSiblings = false;
- if (recursiveExpanding || isIndexExpanded(current)) {
- if (recursiveExpanding)
- expandedIndexes.insert(current);
+ if ((recursiveExpanding && !(current.flags() & Qt::ItemNeverHasChildren)) || isIndexExpanded(current)) {
+ if (recursiveExpanding && storeExpanded(current) && !q->signalsBlocked())
+ emit q->expanded(current);
item->expanded = true;
layout(last, recursiveExpanding, afterIsUninitialized);
item = &viewItems[last];
@@ -3699,6 +3739,8 @@ QPair<int,int> QTreeViewPrivate::startAndEndColumns(const QRect &rect) const
bool QTreeViewPrivate::hasVisibleChildren(const QModelIndex& parent) const
{
Q_Q(const QTreeView);
+ if (parent.flags() & Qt::ItemNeverHasChildren)
+ return false;
if (model->hasChildren(parent)) {
if (hiddenIndexes.isEmpty())
return true;
diff --git a/src/widgets/itemviews/qtreeview.h b/src/widgets/itemviews/qtreeview.h
index 54e580985c..73f11f1a48 100644
--- a/src/widgets/itemviews/qtreeview.h
+++ b/src/widgets/itemviews/qtreeview.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qabstractitemview.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -235,6 +233,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTREEVIEW_H
diff --git a/src/widgets/itemviews/qtreeview_p.h b/src/widgets/itemviews/qtreeview_p.h
index 5a0821c9cf..90e83cb58c 100644
--- a/src/widgets/itemviews/qtreeview_p.h
+++ b/src/widgets/itemviews/qtreeview_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -203,7 +203,7 @@ public:
inline bool isIndexExpanded(const QModelIndex &idx) const {
//We first check if the idx is a QPersistentModelIndex, because creating QPersistentModelIndex is slow
- return isPersistent(idx) && expandedIndexes.contains(idx);
+ return !(idx.flags() & Qt::ItemNeverHasChildren) && isPersistent(idx) && expandedIndexes.contains(idx);
}
// used when hiding and showing items
@@ -229,7 +229,7 @@ public:
{ viewItems[item].height = 0; }
inline int accessibleTable2Index(const QModelIndex &index) const {
- return (viewIndex(index) + (header ? 1 : 0)) * model->columnCount()+index.column() + 1;
+ return (viewIndex(index) + (header ? 1 : 0)) * model->columnCount()+index.column();
}
// used for spanning rows
diff --git a/src/widgets/itemviews/qtreewidget.cpp b/src/widgets/itemviews/qtreewidget.cpp
index 8e86775a2d..653a9170b2 100644
--- a/src/widgets/itemviews/qtreewidget.cpp
+++ b/src/widgets/itemviews/qtreewidget.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qtreewidget.h b/src/widgets/itemviews/qtreewidget.h
index a16a1cd9c2..7aa927a443 100644
--- a/src/widgets/itemviews/qtreewidget.h
+++ b/src/widgets/itemviews/qtreewidget.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtCore/qvariant.h>
#include <QtCore/qvector.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -423,6 +421,4 @@ inline bool QTreeWidgetItem::isDisabled() const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTREEWIDGET_H
diff --git a/src/widgets/itemviews/qtreewidget_p.h b/src/widgets/itemviews/qtreewidget_p.h
index be19025ab3..620520bd79 100644
--- a/src/widgets/itemviews/qtreewidget_p.h
+++ b/src/widgets/itemviews/qtreewidget_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qtreewidgetitemiterator.cpp b/src/widgets/itemviews/qtreewidgetitemiterator.cpp
index e8854d8197..f99b3899df 100644
--- a/src/widgets/itemviews/qtreewidgetitemiterator.cpp
+++ b/src/widgets/itemviews/qtreewidgetitemiterator.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -101,7 +101,7 @@ QTreeWidgetItemIterator::QTreeWidgetItemIterator(QTreeWidget *widget, IteratorFl
Q_ASSERT(model);
d_ptr.reset(new QTreeWidgetItemIteratorPrivate(this, model));
model->iterators.append(this);
- if (!model->rootItem->children.isEmpty()) current = model->rootItem->children.first();
+ if (!model->rootItem->children.isEmpty()) current = model->rootItem->child(0);
if (current && !matchesFlags(current))
++(*this);
}
@@ -130,14 +130,13 @@ QTreeWidgetItemIterator::QTreeWidgetItemIterator(QTreeWidgetItem *item, Iterator
// the beginning.
QTreeWidgetItem *parent = item;
parent = parent->parent();
- QList<QTreeWidgetItem *> children = parent ? parent->children : d->m_model->rootItem->children;
- d->m_currentIndex = children.indexOf(item);
+ QTreeWidgetItem *root = d->m_model->rootItem;
+ d->m_currentIndex = (parent ? parent : root)->indexOfChild(item);
while (parent) {
QTreeWidgetItem *itm = parent;
parent = parent->parent();
- QList<QTreeWidgetItem *> children = parent ? parent->children : d->m_model->rootItem->children;
- int index = children.indexOf(itm);
+ const int index = (parent ? parent : root)->indexOfChild(itm);
d->m_parentIndex.prepend(index);
}
diff --git a/src/widgets/itemviews/qtreewidgetitemiterator.h b/src/widgets/itemviews/qtreewidgetitemiterator.h
index ec604e8b1a..01efbc88f2 100644
--- a/src/widgets/itemviews/qtreewidgetitemiterator.h
+++ b/src/widgets/itemviews/qtreewidgetitemiterator.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtCore/qglobal.h>
#include <QtCore/qscopedpointer.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -153,6 +151,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QTreeWidgetItemIterator::IteratorFlags)
QT_END_NAMESPACE
#endif // QT_NO_TREEWIDGET
-QT_END_HEADER
-
#endif // QTREEWIDGETITEMITERATOR_H
diff --git a/src/widgets/itemviews/qtreewidgetitemiterator_p.h b/src/widgets/itemviews/qtreewidgetitemiterator_p.h
index d0aff063a5..cf2d32cb62 100644
--- a/src/widgets/itemviews/qtreewidgetitemiterator_p.h
+++ b/src/widgets/itemviews/qtreewidgetitemiterator_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/itemviews/qwidgetitemdata_p.h b/src/widgets/itemviews/qwidgetitemdata_p.h
index 9cdf74048b..a8ab58174f 100644
--- a/src/widgets/itemviews/qwidgetitemdata_p.h
+++ b/src/widgets/itemviews/qwidgetitemdata_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/kernel.pri b/src/widgets/kernel/kernel.pri
index 4d3d7c4e0a..533b696faa 100644
--- a/src/widgets/kernel/kernel.pri
+++ b/src/widgets/kernel/kernel.pri
@@ -34,7 +34,8 @@ HEADERS += \
kernel/qgesturerecognizer.h \
kernel/qgesturemanager_p.h \
kernel/qdesktopwidget_qpa_p.h \
- kernel/qwidgetwindow_qpa_p.h
+ kernel/qwidgetwindow_qpa_p.h \
+ kernel/qwindowcontainer_p.h
SOURCES += \
kernel/qaction.cpp \
@@ -62,7 +63,8 @@ SOURCES += \
kernel/qapplication_qpa.cpp \
kernel/qdesktopwidget_qpa.cpp \
kernel/qwidget_qpa.cpp \
- kernel/qwidgetwindow.cpp
+ kernel/qwidgetwindow.cpp \
+ kernel/qwindowcontainer.cpp
# TODO
diff --git a/src/widgets/kernel/mac.pri b/src/widgets/kernel/mac.pri
index 5474a41f15..4c507ae80e 100644
--- a/src/widgets/kernel/mac.pri
+++ b/src/widgets/kernel/mac.pri
@@ -1,4 +1,4 @@
-!x11::mac {
+!x11:mac:!ios {
LIBS_PRIVATE += -framework Carbon -framework Cocoa -lz
*-mwerks:INCLUDEPATH += compat
}
diff --git a/src/widgets/kernel/qaction.cpp b/src/widgets/kernel/qaction.cpp
index f01576d92c..267d787116 100644
--- a/src/widgets/kernel/qaction.cpp
+++ b/src/widgets/kernel/qaction.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qaction.h b/src/widgets/kernel/qaction.h
index 5fb4c655eb..f2346acfcd 100644
--- a/src/widgets/kernel/qaction.h
+++ b/src/widgets/kernel/qaction.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -48,8 +48,6 @@
#include <QtCore/qvariant.h>
#include <QtGui/qicon.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -221,6 +219,4 @@ QT_END_INCLUDE_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QACTION_H
diff --git a/src/widgets/kernel/qaction_p.h b/src/widgets/kernel/qaction_p.h
index d08c42688d..70c9b4ad2b 100644
--- a/src/widgets/kernel/qaction_p.h
+++ b/src/widgets/kernel/qaction_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qactiongroup.cpp b/src/widgets/kernel/qactiongroup.cpp
index 4e19f116bb..8f1b01eca5 100644
--- a/src/widgets/kernel/qactiongroup.cpp
+++ b/src/widgets/kernel/qactiongroup.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qactiongroup.h b/src/widgets/kernel/qactiongroup.h
index 13c5ea8ef1..eab1d8bd43 100644
--- a/src/widgets/kernel/qactiongroup.h
+++ b/src/widgets/kernel/qactiongroup.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qaction.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -99,6 +97,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QACTIONGROUP_H
diff --git a/src/widgets/kernel/qapplication.cpp b/src/widgets/kernel/qapplication.cpp
index 4c6d8cfdc7..ac25d3ed7f 100644
--- a/src/widgets/kernel/qapplication.cpp
+++ b/src/widgets/kernel/qapplication.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -588,6 +588,8 @@ extern void qRegisterWidgetsVariant();
*/
void QApplicationPrivate::initialize()
{
+ is_app_running = false; // Starting up.
+
QWidgetPrivate::mapper = new QWidgetMapper;
QWidgetPrivate::allWidgets = new QWidgetSet;
@@ -601,12 +603,8 @@ void QApplicationPrivate::initialize()
qRegisterGuiStateMachine();
#endif
- is_app_running = true; // no longer starting up
-
- Q_Q(QApplication);
-
if (qgetenv("QT_USE_NATIVE_WINDOWS").toInt() > 0)
- q->setAttribute(Qt::AA_NativeWindows);
+ QCoreApplication::setAttribute(Qt::AA_NativeWindows);
#ifdef Q_OS_WINCE
#ifdef QT_AUTO_MAXIMIZE_THRESHOLD
@@ -629,6 +627,8 @@ void QApplicationPrivate::initialize()
if (QApplication::desktopSettingsAware())
if (const QPlatformTheme *theme = QGuiApplicationPrivate::platformTheme())
QApplicationPrivate::enabledAnimations = theme->themeHint(QPlatformTheme::UiEffects).toInt();
+
+ is_app_running = true; // no longer starting up
}
/*****************************************************************************
@@ -967,11 +967,7 @@ QStyle *QApplication::style()
// Compile-time search for default style
//
QString style;
-#ifdef QT_BUILD_INTERNAL
QString envStyle = QString::fromLocal8Bit(qgetenv("QT_STYLE_OVERRIDE"));
-#else
- QString envStyle;
-#endif
if (!QApplicationPrivate::styleOverride.isEmpty()) {
style = QApplicationPrivate::styleOverride;
} else if (!envStyle.isEmpty()) {
@@ -2010,7 +2006,8 @@ void QApplication::setActiveWindow(QWidget* act)
* Returns 0 if a new focus widget could not be found.
* Shared with QGraphicsProxyWidgetPrivate::findFocusChild()
*/
-QWidget *QApplicationPrivate::focusNextPrevChild_helper(QWidget *toplevel, bool next)
+QWidget *QApplicationPrivate::focusNextPrevChild_helper(QWidget *toplevel, bool next,
+ bool *wrappingOccurred)
{
uint focus_flag = qt_tab_all_widgets() ? Qt::TabFocus : Qt::StrongFocus;
@@ -2020,18 +2017,29 @@ QWidget *QApplicationPrivate::focusNextPrevChild_helper(QWidget *toplevel, bool
QWidget *w = f;
QWidget *test = f->d_func()->focus_next;
+ bool seenWindow = false;
+ bool focusWidgetAfterWindow = false;
while (test && test != f) {
+ if (test->isWindow())
+ seenWindow = true;
+
if ((test->focusPolicy() & focus_flag) == focus_flag
&& !(test->d_func()->extra && test->d_func()->extra->focus_proxy)
&& test->isVisibleTo(toplevel) && test->isEnabled()
&& !(w->windowType() == Qt::SubWindow && !w->isAncestorOf(test))
&& (toplevel->windowType() != Qt::SubWindow || toplevel->isAncestorOf(test))) {
w = test;
+ if (seenWindow)
+ focusWidgetAfterWindow = true;
if (next)
break;
}
test = test->d_func()->focus_next;
}
+
+ if (wrappingOccurred != 0)
+ *wrappingOccurred = next ? focusWidgetAfterWindow : !focusWidgetAfterWindow;
+
if (w == f) {
if (qt_in_tab_key_event) {
w->window()->setAttribute(Qt::WA_KeyboardFocusChange);
@@ -3359,6 +3367,34 @@ bool QApplication::notify(QObject *receiver, QEvent *e)
break;
}
#endif // QT_NO_GESTURES
+#ifdef Q_OS_MAC
+ // Enable touch events on enter, disable on leave.
+ typedef void (*RegisterTouchWindowFn)(QWindow *, bool);
+ case QEvent::Enter:
+ if (receiver->isWidgetType()) {
+ QWidget *w = static_cast<QWidget *>(receiver);
+ if (w->testAttribute(Qt::WA_AcceptTouchEvents)) {
+ RegisterTouchWindowFn registerTouchWindow = reinterpret_cast<RegisterTouchWindowFn>
+ (platformNativeInterface()->nativeResourceFunctionForIntegration("registertouchwindow"));
+ if (registerTouchWindow)
+ registerTouchWindow(w->window()->windowHandle(), true);
+ }
+ }
+ res = d->notify_helper(receiver, e);
+ break;
+ case QEvent::Leave:
+ if (receiver->isWidgetType()) {
+ QWidget *w = static_cast<QWidget *>(receiver);
+ if (w->testAttribute(Qt::WA_AcceptTouchEvents)) {
+ RegisterTouchWindowFn registerTouchWindow = reinterpret_cast<RegisterTouchWindowFn>
+ (platformNativeInterface()->nativeResourceFunctionForIntegration("registertouchwindow"));
+ if (registerTouchWindow)
+ registerTouchWindow(w->window()->windowHandle(), false);
+ }
+ }
+ res = d->notify_helper(receiver, e);
+ break;
+#endif
default:
res = d->notify_helper(receiver, e);
break;
@@ -3560,8 +3596,8 @@ int QApplication::doubleClickInterval()
\since 4.2
\deprecated
- Returns the current keyboard input direction. Replaced with QInputPanel::inputDirection()
- \sa QInputPanel::inputDirection()
+ Returns the current keyboard input direction. Replaced with QInputMethod::inputDirection()
+ \sa QInputMethod::inputDirection()
*/
/*!
@@ -3765,8 +3801,6 @@ private:
bool QApplicationPrivate::translateTouchToMouse(QWidget *widget, QTouchEvent *event)
{
- Q_Q(QApplication);
-
// Check if the platform wants synthesized mouse events.
if (!QGuiApplicationPrivate::platformIntegration()->styleHint(QPlatformIntegration::SynthesizeMouseFromTouchEvents).toBool())
return false;
@@ -3782,7 +3816,7 @@ bool QApplicationPrivate::translateTouchToMouse(QWidget *widget, QTouchEvent *ev
const QPoint pos = widget->mapFromGlobal(p.screenPos().toPoint());
- QMouseEvent mouseEvent(eventType, pos,
+ QMouseEvent mouseEvent(eventType, pos, p.screenPos().toPoint(),
Qt::LeftButton, Qt::LeftButton,
event->modifiers());
mouseEvent.setAccepted(true);
@@ -3797,7 +3831,7 @@ bool QApplicationPrivate::translateTouchToMouse(QWidget *widget, QTouchEvent *ev
// Note it has to be a spontaneous event if we want the focus management
// and input method support to behave properly. Quite some of the code
// related to those aspect check for the spontaneous flag.
- const bool res = q->sendSpontaneousEvent(widget, &mouseEvent);
+ const bool res = QCoreApplication::sendSpontaneousEvent(widget, &mouseEvent);
event->setAccepted(mouseEvent.isAccepted());
if (mouseEvent.isAccepted())
diff --git a/src/widgets/kernel/qapplication.h b/src/widgets/kernel/qapplication.h
index 29f5ddf455..83673eef4e 100644
--- a/src/widgets/kernel/qapplication.h
+++ b/src/widgets/kernel/qapplication.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -55,8 +55,6 @@
#endif
#include <QtGui/qguiapplication.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -247,6 +245,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QAPPLICATION_H
diff --git a/src/widgets/kernel/qapplication_p.h b/src/widgets/kernel/qapplication_p.h
index fbd96366fb..ca1bccb727 100644
--- a/src/widgets/kernel/qapplication_p.h
+++ b/src/widgets/kernel/qapplication_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -165,7 +165,8 @@ public:
void closePopup(QWidget *popup);
void openPopup(QWidget *popup);
static void setFocusWidget(QWidget *focus, Qt::FocusReason reason);
- static QWidget *focusNextPrevChild_helper(QWidget *toplevel, bool next);
+ static QWidget *focusNextPrevChild_helper(QWidget *toplevel, bool next,
+ bool *wrappingOccurred = 0);
#ifndef QT_NO_GRAPHICSVIEW
// Maintain a list of all scenes to ensure font and palette propagation to
diff --git a/src/widgets/kernel/qapplication_qpa.cpp b/src/widgets/kernel/qapplication_qpa.cpp
index 6c3c5de55f..54eb443c43 100644
--- a/src/widgets/kernel/qapplication_qpa.cpp
+++ b/src/widgets/kernel/qapplication_qpa.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qboxlayout.cpp b/src/widgets/kernel/qboxlayout.cpp
index c3661f5c50..e1a7903628 100644
--- a/src/widgets/kernel/qboxlayout.cpp
+++ b/src/widgets/kernel/qboxlayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -248,7 +248,7 @@ void QBoxLayoutPrivate::effectiveMargins(int *left, int *top, int *right, int *b
if (right)
r = qMax(r, wr.right() - lir.right());
}
- }
+ }
}
#endif
if (left)
@@ -509,7 +509,7 @@ void QBoxLayoutPrivate::calcHfw(int w)
\list
\li setContentsMargins() sets the width of the outer border on
- each side of the widget. This is the width of the reserved space
+ each side of the widget. This is the width of the reserved space
along each of the QBoxLayout's four sides.
\li setSpacing() sets the width between neighboring boxes. (You
can use addSpacing() to get more space at a particular spot.)
@@ -595,7 +595,7 @@ int QBoxLayout::spacing() const
/*!
Reimplements QLayout::setSpacing(). Sets the spacing
- property to \a spacing.
+ property to \a spacing.
\sa QLayout::setSpacing(), spacing()
*/
diff --git a/src/widgets/kernel/qboxlayout.h b/src/widgets/kernel/qboxlayout.h
index 3ced397c1d..4c7b27a4ec 100644
--- a/src/widgets/kernel/qboxlayout.h
+++ b/src/widgets/kernel/qboxlayout.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -49,8 +49,6 @@
#include <limits.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -141,6 +139,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QBOXLAYOUT_H
diff --git a/src/widgets/kernel/qdesktopwidget.cpp b/src/widgets/kernel/qdesktopwidget.cpp
index 63b0a3c873..649978a912 100644
--- a/src/widgets/kernel/qdesktopwidget.cpp
+++ b/src/widgets/kernel/qdesktopwidget.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qdesktopwidget.h b/src/widgets/kernel/qdesktopwidget.h
index c27e96a2d9..da44242b86 100644
--- a/src/widgets/kernel/qdesktopwidget.h
+++ b/src/widgets/kernel/qdesktopwidget.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -104,6 +102,4 @@ inline int QDesktopWidget::screenCount() const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDESKTOPWIDGET_H
diff --git a/src/widgets/kernel/qdesktopwidget.qdoc b/src/widgets/kernel/qdesktopwidget.qdoc
index 15ddd3b32f..789a812afb 100644
--- a/src/widgets/kernel/qdesktopwidget.qdoc
+++ b/src/widgets/kernel/qdesktopwidget.qdoc
@@ -120,9 +120,9 @@
/*!
\fn int QDesktopWidget::numScreens() const
-
+
Returns the number of available screens.
-
+
\obsolete
This function is deprecated. Use screenCount instead.
@@ -239,7 +239,7 @@
\brief the number of screens currently available on the system.
\since 4.6
-
+
\sa screenCountChanged()
*/
@@ -265,6 +265,6 @@
\since 4.6
This signal is emitted when the number of screens changes to \a newCount.
-
+
\sa screenCount
*/
diff --git a/src/widgets/kernel/qdesktopwidget_qpa.cpp b/src/widgets/kernel/qdesktopwidget_qpa.cpp
index b71734bebb..64236321a4 100644
--- a/src/widgets/kernel/qdesktopwidget_qpa.cpp
+++ b/src/widgets/kernel/qdesktopwidget_qpa.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qdesktopwidget_qpa_p.h b/src/widgets/kernel/qdesktopwidget_qpa_p.h
index 9f0089616b..017934fbf1 100644
--- a/src/widgets/kernel/qdesktopwidget_qpa_p.h
+++ b/src/widgets/kernel/qdesktopwidget_qpa_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -61,9 +61,8 @@ QT_BEGIN_NAMESPACE
class QDesktopScreenWidget : public QWidget {
Q_OBJECT
public:
- QDesktopScreenWidget(int screenNumber = -1)
+ QDesktopScreenWidget(int screenNumber = -1) : QWidget(0, Qt::Desktop)
{
- setWindowFlags(Qt::Desktop);
setVisible(false);
QTLWExtra *topData = d_func()->topData();
topData->screenIndex = screenNumber;
diff --git a/src/widgets/kernel/qformlayout.cpp b/src/widgets/kernel/qformlayout.cpp
index 9388532406..e2d25de537 100644
--- a/src/widgets/kernel/qformlayout.cpp
+++ b/src/widgets/kernel/qformlayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qformlayout.h b/src/widgets/kernel/qformlayout.h
index a206e90009..d59f71eb32 100644
--- a/src/widgets/kernel/qformlayout.h
+++ b/src/widgets/kernel/qformlayout.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/QLayout>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -157,6 +155,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/widgets/kernel/qgesture.cpp b/src/widgets/kernel/qgesture.cpp
index 24ae437b48..4baeae9021 100644
--- a/src/widgets/kernel/qgesture.cpp
+++ b/src/widgets/kernel/qgesture.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -367,7 +367,7 @@ void QPanGesture::setAcceleration(qreal value)
/*!
\enum QPinchGesture::ChangeFlag
-
+
This enum describes the changes that can occur to the properties of
the gesture object.
diff --git a/src/widgets/kernel/qgesture.h b/src/widgets/kernel/qgesture.h
index 4384600f80..056fc35402 100644
--- a/src/widgets/kernel/qgesture.h
+++ b/src/widgets/kernel/qgesture.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -52,8 +52,6 @@
#ifndef QT_NO_GESTURES
-QT_BEGIN_HEADER
-
Q_DECLARE_METATYPE(Qt::GestureState)
Q_DECLARE_METATYPE(Qt::GestureType)
@@ -328,8 +326,6 @@ private:
QT_END_NAMESPACE
Q_DECLARE_METATYPE(QGesture::GestureCancelPolicy)
-QT_END_HEADER
-
#endif // QT_NO_GESTURES
#endif // QGESTURE_H
diff --git a/src/widgets/kernel/qgesture_p.h b/src/widgets/kernel/qgesture_p.h
index c842e279b5..c041af7317 100644
--- a/src/widgets/kernel/qgesture_p.h
+++ b/src/widgets/kernel/qgesture_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qgesturemanager.cpp b/src/widgets/kernel/qgesturemanager.cpp
index 528d6120cf..d90b187bf0 100644
--- a/src/widgets/kernel/qgesturemanager.cpp
+++ b/src/widgets/kernel/qgesturemanager.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qgesturemanager_p.h b/src/widgets/kernel/qgesturemanager_p.h
index 5c78932f1d..4ab631a921 100644
--- a/src/widgets/kernel/qgesturemanager_p.h
+++ b/src/widgets/kernel/qgesturemanager_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qgesturerecognizer.cpp b/src/widgets/kernel/qgesturerecognizer.cpp
index b6b0e3c1cb..88983e255b 100644
--- a/src/widgets/kernel/qgesturerecognizer.cpp
+++ b/src/widgets/kernel/qgesturerecognizer.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qgesturerecognizer.h b/src/widgets/kernel/qgesturerecognizer.h
index b85aa54a6b..a1ce86b50d 100644
--- a/src/widgets/kernel/qgesturerecognizer.h
+++ b/src/widgets/kernel/qgesturerecognizer.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#ifndef QT_NO_GESTURES
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -94,8 +92,6 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QGestureRecognizer::Result)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_GESTURES
#endif // QGESTURERECOGNIZER_H
diff --git a/src/widgets/kernel/qgridlayout.cpp b/src/widgets/kernel/qgridlayout.cpp
index fb343264d2..12049f3303 100644
--- a/src/widgets/kernel/qgridlayout.cpp
+++ b/src/widgets/kernel/qgridlayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qgridlayout.h b/src/widgets/kernel/qgridlayout.h
index 9349c7807d..6a788d9cc8 100644
--- a/src/widgets/kernel/qgridlayout.h
+++ b/src/widgets/kernel/qgridlayout.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -49,8 +49,6 @@
#include <limits.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -132,6 +130,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGRIDLAYOUT_H
diff --git a/src/widgets/kernel/qlayout.cpp b/src/widgets/kernel/qlayout.cpp
index 493a04d2ba..d59a9db75d 100644
--- a/src/widgets/kernel/qlayout.cpp
+++ b/src/widgets/kernel/qlayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -1270,7 +1270,7 @@ QRect QLayout::alignmentRect(const QRect &r) const
Removes the widget \a widget from the layout. After this call, it
is the caller's responsibility to give the widget a reasonable
geometry or to put the widget back into a layout.
-
+
\b{Note:} The ownership of \a widget remains the same as
when it was added.
diff --git a/src/widgets/kernel/qlayout.h b/src/widgets/kernel/qlayout.h
index 09ddebeb2a..c293939bd3 100644
--- a/src/widgets/kernel/qlayout.h
+++ b/src/widgets/kernel/qlayout.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -50,8 +50,6 @@
#include <limits.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -171,6 +169,4 @@ QT_END_NAMESPACE
#include <QtWidgets/qboxlayout.h>
#include <QtWidgets/qgridlayout.h>
-QT_END_HEADER
-
#endif // QLAYOUT_H
diff --git a/src/widgets/kernel/qlayout_p.h b/src/widgets/kernel/qlayout_p.h
index e6d96a8253..9321bfc0dc 100644
--- a/src/widgets/kernel/qlayout_p.h
+++ b/src/widgets/kernel/qlayout_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qlayoutengine.cpp b/src/widgets/kernel/qlayoutengine.cpp
index 8fb625581b..8800da33b4 100644
--- a/src/widgets/kernel/qlayoutengine.cpp
+++ b/src/widgets/kernel/qlayoutengine.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qlayoutengine_p.h b/src/widgets/kernel/qlayoutengine_p.h
index beecf529fb..8a26b389df 100644
--- a/src/widgets/kernel/qlayoutengine_p.h
+++ b/src/widgets/kernel/qlayoutengine_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qlayoutitem.cpp b/src/widgets/kernel/qlayoutitem.cpp
index 31276d015d..223bcf1d9b 100644
--- a/src/widgets/kernel/qlayoutitem.cpp
+++ b/src/widgets/kernel/qlayoutitem.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -150,7 +150,7 @@ QSizePolicy::operator QVariant() const
\brief The QWidgetItem class is a layout item that represents a widget.
\inmodule QtWidgets
-
+
Normally, you don't need to use this class directly. Qt's
built-in layout managers provide the following functions for
manipulating widgets in layouts:
@@ -446,20 +446,20 @@ void QWidgetItem::setGeometry(const QRect &rect)
QRect r = !wid->testAttribute(Qt::WA_LayoutUsesWidgetRect)
? fromLayoutItemRect(wid->d_func(), rect)
: rect;
- const QSize widgetRectSurplus = r.size() - rect.size();
-
- /*
- For historical reasons, this code is done using widget rect
- coordinates, not layout item rect coordinates. However,
- QWidgetItem's sizeHint(), maximumSize(), and heightForWidth()
- all work in terms of layout item rect coordinates, so we have to
- add or subtract widgetRectSurplus here and there. The code could
- be much simpler if we did everything using layout item rect
- coordinates and did the conversion right before the call to
- QWidget::setGeometry().
- */
-
- QSize s = r.size().boundedTo(maximumSize() + widgetRectSurplus);
+ const QSize widgetRectSurplus = r.size() - rect.size();
+
+ /*
+ For historical reasons, this code is done using widget rect
+ coordinates, not layout item rect coordinates. However,
+ QWidgetItem's sizeHint(), maximumSize(), and heightForWidth()
+ all work in terms of layout item rect coordinates, so we have to
+ add or subtract widgetRectSurplus here and there. The code could
+ be much simpler if we did everything using layout item rect
+ coordinates and did the conversion right before the call to
+ QWidget::setGeometry().
+ */
+
+ QSize s = r.size().boundedTo(maximumSize() + widgetRectSurplus);
int x = r.x();
int y = r.y();
if (align & (Qt::AlignHorizontal_Mask | Qt::AlignVertical_Mask)) {
@@ -474,8 +474,8 @@ void QWidgetItem::setGeometry(const QRect &rect)
s.setWidth(qMin(s.width(), pref.width()));
if (align & Qt::AlignVertical_Mask) {
if (hasHeightForWidth())
- s.setHeight(qMin(s.height(),
- heightForWidth(s.width() - widgetRectSurplus.width())
+ s.setHeight(qMin(s.height(),
+ heightForWidth(s.width() - widgetRectSurplus.width())
+ widgetRectSurplus.height()));
else
s.setHeight(qMin(s.height(), pref.height()));
diff --git a/src/widgets/kernel/qlayoutitem.h b/src/widgets/kernel/qlayoutitem.h
index b19a7c789f..4af57f1458 100644
--- a/src/widgets/kernel/qlayoutitem.h
+++ b/src/widgets/kernel/qlayoutitem.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,12 +47,10 @@
#include <limits.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
-static const int QLAYOUTSIZE_MAX = INT_MAX/256/16;
+static const Q_DECL_UNUSED int QLAYOUTSIZE_MAX = INT_MAX/256/16;
class QLayout;
class QLayoutItem;
@@ -180,6 +178,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLAYOUTITEM_H
diff --git a/src/widgets/kernel/qshortcut.cpp b/src/widgets/kernel/qshortcut.cpp
index 07e22e27e2..f323c682d1 100644
--- a/src/widgets/kernel/qshortcut.cpp
+++ b/src/widgets/kernel/qshortcut.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qshortcut.h b/src/widgets/kernel/qshortcut.h
index f5daa381f7..372cd9ff66 100644
--- a/src/widgets/kernel/qshortcut.h
+++ b/src/widgets/kernel/qshortcut.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qwidget.h>
#include <QtGui/qkeysequence.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -101,6 +99,4 @@ protected:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSHORTCUT_H
diff --git a/src/widgets/kernel/qsizepolicy.h b/src/widgets/kernel/qsizepolicy.h
index 0a878674cc..2fe85cbe0c 100644
--- a/src/widgets/kernel/qsizepolicy.h
+++ b/src/widgets/kernel/qsizepolicy.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -183,6 +181,4 @@ inline void QSizePolicy::transpose() {
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSIZEPOLICY_H
diff --git a/src/widgets/kernel/qstackedlayout.cpp b/src/widgets/kernel/qstackedlayout.cpp
index f38f0a6f08..9514877e50 100644
--- a/src/widgets/kernel/qstackedlayout.cpp
+++ b/src/widgets/kernel/qstackedlayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qstackedlayout.h b/src/widgets/kernel/qstackedlayout.h
index a8067b5bab..87715d10d8 100644
--- a/src/widgets/kernel/qstackedlayout.h
+++ b/src/widgets/kernel/qstackedlayout.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qlayout.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -111,6 +109,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTACKEDLAYOUT_H
diff --git a/src/widgets/kernel/qstandardgestures.cpp b/src/widgets/kernel/qstandardgestures.cpp
index 98fdfb4b75..e3131e7e56 100644
--- a/src/widgets/kernel/qstandardgestures.cpp
+++ b/src/widgets/kernel/qstandardgestures.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qstandardgestures_p.h b/src/widgets/kernel/qstandardgestures_p.h
index 61645f364a..70cd241ab4 100644
--- a/src/widgets/kernel/qstandardgestures_p.h
+++ b/src/widgets/kernel/qstandardgestures_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qt_widgets_pch.h b/src/widgets/kernel/qt_widgets_pch.h
index 144a5913cf..9e16d8f19e 100644
--- a/src/widgets/kernel/qt_widgets_pch.h
+++ b/src/widgets/kernel/qt_widgets_pch.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qtooltip.cpp b/src/widgets/kernel/qtooltip.cpp
index 69dd1f9e63..864ed6a555 100644
--- a/src/widgets/kernel/qtooltip.cpp
+++ b/src/widgets/kernel/qtooltip.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qtooltip.h b/src/widgets/kernel/qtooltip.h
index 3a09803598..25b138b855 100644
--- a/src/widgets/kernel/qtooltip.h
+++ b/src/widgets/kernel/qtooltip.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -72,6 +70,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTOOLTIP_H
diff --git a/src/widgets/kernel/qwhatsthis.cpp b/src/widgets/kernel/qwhatsthis.cpp
index 1152ef4f8d..b96bd024cb 100644
--- a/src/widgets/kernel/qwhatsthis.cpp
+++ b/src/widgets/kernel/qwhatsthis.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qwhatsthis.h b/src/widgets/kernel/qwhatsthis.h
index 7e41e5ab58..37887b8cd5 100644
--- a/src/widgets/kernel/qwhatsthis.h
+++ b/src/widgets/kernel/qwhatsthis.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtCore/qobject.h>
#include <QtGui/qcursor.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -74,6 +72,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWHATSTHIS_H
diff --git a/src/widgets/kernel/qwidget.cpp b/src/widgets/kernel/qwidget.cpp
index 5ec713140e..edd2329df8 100644
--- a/src/widgets/kernel/qwidget.cpp
+++ b/src/widgets/kernel/qwidget.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -354,6 +354,7 @@ void QWidgetPrivate::updateWidgetTransform()
QPoint p = q->mapTo(q->topLevelWidget(), QPoint(0,0));
t.translate(p.x(), p.y());
qApp->inputMethod()->setInputItemTransform(t);
+ qApp->inputMethod()->setInputItemRectangle(q->rect());
}
}
@@ -677,7 +678,7 @@ void QWidget::setAutoFillBackground(bool enabled)
(to move the keyboard focus), and passes on most of the other events to
one of the more specialized handlers above.
- Events and the mechanism used to deliver them are covered in
+ Events and the mechanism used to deliver them are covered in
\l{The Event System}.
\section1 Groups of Functions and Properties
@@ -1082,7 +1083,8 @@ void QWidgetPrivate::adjustFlags(Qt::WindowFlags &flags, QWidget *w)
else
flags |= Qt::WindowTitleHint | Qt::WindowSystemMenuHint | Qt::WindowMinimizeButtonHint |
Qt::WindowMaximizeButtonHint | Qt::WindowCloseButtonHint | Qt::WindowFullscreenButtonHint;
-
+ if (w->testAttribute(Qt::WA_TransparentForMouseEvents))
+ flags |= Qt::WindowTransparentForInput;
}
void QWidgetPrivate::init(QWidget *parentWidget, Qt::WindowFlags f)
@@ -6137,10 +6139,34 @@ bool QWidget::focusNextPrevChild(bool next)
if (d->extra && d->extra->proxyWidget)
return d->extra->proxyWidget->focusNextPrevChild(next);
#endif
- QWidget *w = QApplicationPrivate::focusNextPrevChild_helper(this, next);
+
+ bool wrappingOccurred = false;
+ QWidget *w = QApplicationPrivate::focusNextPrevChild_helper(this, next,
+ &wrappingOccurred);
if (!w) return false;
- w->setFocus(next ? Qt::TabFocusReason : Qt::BacktabFocusReason);
+ Qt::FocusReason reason = next ? Qt::TabFocusReason : Qt::BacktabFocusReason;
+
+ /* If we are about to wrap the focus chain, give the platform
+ * implementation a chance to alter the wrapping behavior. This is
+ * especially needed when the window is embedded in a window created by
+ * another process.
+ */
+ if (wrappingOccurred) {
+ QWindow *window = windowHandle();
+ if (window != 0) {
+ QWindowPrivate *winp = qt_window_private(window);
+
+ if (winp->platformWindow != 0) {
+ QFocusEvent event(QEvent::FocusIn, reason);
+ event.ignore();
+ winp->platformWindow->windowEvent(&event);
+ if (event.isAccepted()) return true;
+ }
+ }
+ }
+
+ w->setFocus(reason);
return true;
}
@@ -6916,14 +6942,15 @@ void QWidget::setUpdatesEnabled(bool enable)
Shows the widget and its child widgets. This function is
equivalent to setVisible(true) in the normal case, and equivalent
to showFullScreen() if the QStyleHints::showIsFullScreen() hint
- is true.
+ is true and the window is not a popup.
\sa raise(), showEvent(), hide(), setVisible(), showMinimized(), showMaximized(),
- showNormal(), isVisible()
+ showNormal(), isVisible(), windowFlags()
*/
void QWidget::show()
{
- if (isWindow() && qApp->styleHints()->showIsFullScreen())
+ bool isPopup = data->window_flags & Qt::Popup & ~Qt::Window;
+ if (isWindow() && !isPopup && qApp->styleHints()->showIsFullScreen())
showFullScreen();
else
setVisible(true);
@@ -8232,7 +8259,7 @@ bool QWidget::event(QEvent *event)
#ifndef QT_NO_PROPERTIES
case QEvent::DynamicPropertyChange: {
const QByteArray &propName = static_cast<QDynamicPropertyChangeEvent *>(event)->propertyName();
- if (!qstrncmp(propName, "_q_customDpi", 12) && propName.length() == 13) {
+ if (propName.length() == 13 && !qstrncmp(propName, "_q_customDpi", 12)) {
uint value = property(propName.constData()).toUInt();
if (!d->extra)
d->createExtra();
@@ -8574,6 +8601,10 @@ void QWidget::focusOutEvent(QFocusEvent *)
{
if (focusPolicy() != Qt::NoFocus || !isWindow())
update();
+
+ // automatically hide the SIP
+ if (qApp->autoSipEnabled() && testAttribute(Qt::WA_InputMethodEnabled))
+ qApp->inputMethod()->hide();
}
/*!
@@ -8796,7 +8827,7 @@ void QWidget::inputMethodEvent(QInputMethodEvent *event)
\a query specifies which property is queried.
- \sa inputMethodEvent(), QInputMethodEven, inputMethodHints
+ \sa inputMethodEvent(), QInputMethodEvent, QInputMethodQueryEvent, inputMethodHints
*/
QVariant QWidget::inputMethodQuery(Qt::InputMethodQuery query) const
{
@@ -9096,7 +9127,7 @@ QLayout *QWidget::layout() const
existing layout manager (returned by layout()) before you can
call setLayout() with the new layout.
- If \a layout is the layout manger on a different widget, setLayout()
+ If \a layout is the layout manager on a different widget, setLayout()
will reparent the layout and make it the layout manager for this widget.
Example:
@@ -9254,7 +9285,7 @@ int QWidget::heightForWidth(int w) const
\since 5.0
Returns true if the widget's preferred height depends on its width; otherwise returns false.
-*/
+*/
bool QWidget::hasHeightForWidth() const
{
Q_D(const QWidget);
@@ -9486,6 +9517,9 @@ void QWidget::setParent(QWidget *parent, Qt::WindowFlags f)
bool wasCreated = testAttribute(Qt::WA_WState_Created);
QWidget *oldtlw = window();
+ if (f & Qt::Window) // Frame geometry likely changes, refresh.
+ d->data.fstrut_dirty = true;
+
QWidget *desktopWidget = 0;
if (parent && parent->windowType() == Qt::Desktop)
desktopWidget = parent;
diff --git a/src/widgets/kernel/qwidget.h b/src/widgets/kernel/qwidget.h
index 25dac1ed5e..f90f2ee5f5 100644
--- a/src/widgets/kernel/qwidget.h
+++ b/src/widgets/kernel/qwidget.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -60,8 +60,6 @@
#include <QtGui/qevent.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -593,6 +591,8 @@ public:
QWindow *windowHandle() const;
+ static QWidget *createWindowContainer(QWindow *window, QWidget *parent=0, Qt::WindowFlags flags=0);
+
friend class QDesktopScreenWidget;
Q_SIGNALS:
@@ -704,6 +704,8 @@ private:
friend class QStyleSheetStyle;
friend struct QWidgetExceptionCleaner;
friend class QWidgetWindow;
+ friend class QAccessibleWidget;
+ friend class QAccessibleTable;
#ifndef QT_NO_GESTURES
friend class QGestureManager;
friend class QWinNativePanGestureRecognizer;
@@ -855,6 +857,4 @@ inline bool QWidget::testAttribute(Qt::WidgetAttribute attribute) const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWIDGET_H
diff --git a/src/widgets/kernel/qwidget_p.h b/src/widgets/kernel/qwidget_p.h
index 37f295bc9f..50f32af8b0 100644
--- a/src/widgets/kernel/qwidget_p.h
+++ b/src/widgets/kernel/qwidget_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qwidget_qpa.cpp b/src/widgets/kernel/qwidget_qpa.cpp
index 84693d02a5..1374d25cef 100644
--- a/src/widgets/kernel/qwidget_qpa.cpp
+++ b/src/widgets/kernel/qwidget_qpa.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -109,7 +109,10 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
win->setFlags(data.window_flags);
fixPosIncludesFrame();
- win->setGeometry(q->geometry());
+ if (q->testAttribute(Qt::WA_Moved))
+ win->setGeometry(q->geometry());
+ else
+ win->resize(q->size());
win->setScreen(QGuiApplication::screens().value(topData()->screenIndex, 0));
if (q->testAttribute(Qt::WA_TranslucentBackground)) {
@@ -466,19 +469,6 @@ void QWidget::activateWindow()
wnd->requestActivate();
}
-// Position top level windows at the center, avoid showing
-// Windows at the default 0,0 position excluding the frame.
-static inline QRect positionTopLevelWindow(QRect geometry, const QScreen *screen)
-{
- if (screen && geometry.x() == 0 && geometry.y() == 0) {
- const QRect availableGeometry = screen->availableGeometry();
- if (availableGeometry.width() > geometry.width()
- && availableGeometry.height() > geometry.height())
- geometry.moveCenter(availableGeometry.center());
- }
- return geometry;
-}
-
// move() was invoked with Qt::WA_WState_Created not set (frame geometry
// unknown), that is, crect has a position including the frame.
// If we can determine the frame strut, fix that and clear the flag.
@@ -529,16 +519,16 @@ void QWidgetPrivate::show_sys()
if (q->isWindow())
fixPosIncludesFrame();
QRect geomRect = q->geometry();
- if (q->isWindow()) {
- if (!q->testAttribute(Qt::WA_Moved))
- geomRect = positionTopLevelWindow(geomRect, window->screen());
- } else {
+ if (!q->isWindow()) {
QPoint topLeftOfWindow = q->mapTo(q->nativeParentWidget(),QPoint());
geomRect.moveTopLeft(topLeftOfWindow);
}
const QRect windowRect = window->geometry();
if (windowRect != geomRect) {
- window->setGeometry(geomRect);
+ if (q->testAttribute(Qt::WA_Moved))
+ window->setGeometry(geomRect);
+ else
+ window->resize(geomRect.size());
}
if (QBackingStore *store = q->backingStore()) {
@@ -887,7 +877,12 @@ void QWidgetPrivate::createTLSysExtra()
extra->topextra->window->setMinimumSize(QSize(extra->minw, extra->minh));
if (extra->maxw != QWIDGETSIZE_MAX || extra->maxh != QWIDGETSIZE_MAX)
extra->topextra->window->setMaximumSize(QSize(extra->maxw, extra->maxh));
+#ifdef Q_OS_WIN
+ if (q->inherits("QTipLabel") || q->inherits("QAlphaWidget"))
+ extra->topextra->window->setProperty("_q_windowsDropShadow", QVariant(true));
+#endif
}
+
}
void QWidgetPrivate::deleteTLSysExtra()
@@ -999,6 +994,12 @@ static inline void applyCursor(QWidget *w, QCursor c)
window->setCursor(c);
}
+static inline void unsetCursor(QWidget *w)
+{
+ if (QWindow *window = w->windowHandle())
+ window->unsetCursor();
+}
+
void qt_qpa_set_cursor(QWidget *w, bool force)
{
if (!w->testAttribute(Qt::WA_WState_Created))
@@ -1032,11 +1033,11 @@ void qt_qpa_set_cursor(QWidget *w, bool force)
else
// Enforce the windows behavior of clearing the cursor on
// disabled widgets.
- applyCursor(nativeParent, Qt::ArrowCursor);
+ unsetCursor(nativeParent);
} else {
- applyCursor(nativeParent, Qt::ArrowCursor);
+ unsetCursor(nativeParent);
}
}
-#endif //QT_NO_CURSOR
+#endif //QT_NO_CURSOR
QT_END_NAMESPACE
diff --git a/src/widgets/kernel/qwidgetaction.cpp b/src/widgets/kernel/qwidgetaction.cpp
index fc82fd09f2..7ccb4e2a5c 100644
--- a/src/widgets/kernel/qwidgetaction.cpp
+++ b/src/widgets/kernel/qwidgetaction.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qwidgetaction.h b/src/widgets/kernel/qwidgetaction.h
index 14f1bfaf7f..7fc24bab9b 100644
--- a/src/widgets/kernel/qwidgetaction.h
+++ b/src/widgets/kernel/qwidgetaction.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qaction.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -61,13 +59,13 @@ class Q_WIDGETS_EXPORT QWidgetAction : public QAction
public:
explicit QWidgetAction(QObject *parent);
virtual ~QWidgetAction();
-
+
void setDefaultWidget(QWidget *w);
QWidget *defaultWidget() const;
QWidget *requestWidget(QWidget *parent);
void releaseWidget(QWidget *widget);
-
+
protected:
virtual bool event(QEvent *);
virtual bool eventFilter(QObject *, QEvent *);
@@ -85,6 +83,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWIDGETACTION_H
diff --git a/src/widgets/kernel/qwidgetaction_p.h b/src/widgets/kernel/qwidgetaction_p.h
index a95fe07534..8f591bf320 100644
--- a/src/widgets/kernel/qwidgetaction_p.h
+++ b/src/widgets/kernel/qwidgetaction_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -66,7 +66,7 @@ public:
QList<QWidget *> createdWidgets;
uint defaultWidgetInUse : 1;
uint autoCreated : 1; // created by QToolBar::addWidget and the like
-
+
inline void _q_widgetDestroyed(QObject *o) {
createdWidgets.removeAll(static_cast<QWidget *>(o));
}
diff --git a/src/widgets/kernel/qwidgetbackingstore.cpp b/src/widgets/kernel/qwidgetbackingstore.cpp
index 294ef9f28c..02fa80bef6 100644
--- a/src/widgets/kernel/qwidgetbackingstore.cpp
+++ b/src/widgets/kernel/qwidgetbackingstore.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qwidgetbackingstore_p.h b/src/widgets/kernel/qwidgetbackingstore_p.h
index 00016a8e7d..39583c8caa 100644
--- a/src/widgets/kernel/qwidgetbackingstore_p.h
+++ b/src/widgets/kernel/qwidgetbackingstore_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qwidgetsfunctions_wince.h b/src/widgets/kernel/qwidgetsfunctions_wince.h
index 5d3640ae75..ca742e296a 100644
--- a/src/widgets/kernel/qwidgetsfunctions_wince.h
+++ b/src/widgets/kernel/qwidgetsfunctions_wince.h
@@ -40,14 +40,15 @@
****************************************************************************/
#ifndef QWIDGETSFUNCTIONS_WCE_H
#define QWIDGETSFUNCTIONS_WCE_H
+
+#include <QtCore/qglobal.h>
+
#ifdef Q_OS_WINCE
#include <QtCore/qfunctions_wince.h>
#ifdef QT_BUILD_GUI_LIB
-QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
#endif
diff --git a/src/widgets/kernel/qwidgetsvariant.cpp b/src/widgets/kernel/qwidgetsvariant.cpp
index b5b5999c2b..5ac46c1f59 100644
--- a/src/widgets/kernel/qwidgetsvariant.cpp
+++ b/src/widgets/kernel/qwidgetsvariant.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/kernel/qwidgetwindow.cpp b/src/widgets/kernel/qwidgetwindow.cpp
index 50b61beb05..ddb570d6c7 100644
--- a/src/widgets/kernel/qwidgetwindow.cpp
+++ b/src/widgets/kernel/qwidgetwindow.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -52,6 +52,8 @@
QT_BEGIN_NAMESPACE
+Q_WIDGETS_EXPORT extern bool qt_tab_all_widgets();
+
QWidget *qt_button_down = 0; // widget got last button-down
static QWidget *qt_tablet_target = 0;
@@ -123,6 +125,8 @@ bool QWidgetWindow::event(QEvent *event)
// these should not be sent to QWidget, the corresponding events
// are sent by QApplicationPrivate::notifyActiveWindowChange()
case QEvent::FocusIn:
+ handleFocusInEvent(static_cast<QFocusEvent *>(event));
+ // Fallthrough
case QEvent::FocusOut: {
#ifndef QT_NO_ACCESSIBILITY
QAccessible::State state;
@@ -284,6 +288,42 @@ void QWidgetWindow::handleEnterLeaveEvent(QEvent *event)
}
}
+QWidget *QWidgetWindow::getFocusWidget(FocusWidgets fw)
+{
+ QWidget *tlw = m_widget;
+ QWidget *w = tlw->nextInFocusChain();
+
+ QWidget *last = tlw;
+
+ uint focus_flag = qt_tab_all_widgets() ? Qt::TabFocus : Qt::StrongFocus;
+
+ while (w != tlw)
+ {
+ if (((w->focusPolicy() & focus_flag) == focus_flag)
+ && w->isVisibleTo(m_widget) && w->isEnabled())
+ {
+ last = w;
+ if (fw == FirstFocusWidget)
+ break;
+ }
+ w = w->nextInFocusChain();
+ }
+
+ return last;
+}
+
+void QWidgetWindow::handleFocusInEvent(QFocusEvent *e)
+{
+ QWidget *focusWidget = 0;
+ if (e->reason() == Qt::BacktabFocusReason)
+ focusWidget = getFocusWidget(LastFocusWidget);
+ else if (e->reason() == Qt::TabFocusReason)
+ focusWidget = getFocusWidget(FirstFocusWidget);
+
+ if (focusWidget != 0)
+ focusWidget->setFocus();
+}
+
void QWidgetWindow::handleNonClientAreaMouseEvent(QMouseEvent *e)
{
QApplication::sendSpontaneousEvent(m_widget, e);
@@ -352,6 +392,27 @@ void QWidgetWindow::handleMouseEvent(QMouseEvent *event)
&& qt_replay_popup_mouse_event) {
if (m_widget->windowType() != Qt::Popup)
qt_button_down = 0;
+ if (event->type() == QEvent::MouseButtonPress) {
+ // the popup disappeared, replay the mouse press event
+ QWidget *w = QApplication::widgetAt(event->globalPos());
+ if (w && !QApplicationPrivate::isBlockedByModal(w)) {
+ // activate window of the widget under mouse pointer
+ if (!w->isActiveWindow()) {
+ w->activateWindow();
+ w->raise();
+ }
+
+ QWindow *win = w->windowHandle();
+ if (!win)
+ win = w->nativeParentWidget()->windowHandle();
+ if (win && win->geometry().contains(event->globalPos())) {
+ const QPoint localPos = win->mapFromGlobal(event->globalPos());
+ QMouseEvent e(QEvent::MouseButtonPress, localPos, localPos, event->globalPos(), event->button(), event->buttons(), event->modifiers());
+ e.setTimestamp(event->timestamp());
+ QApplication::sendSpontaneousEvent(win, &e);
+ }
+ }
+ }
qt_replay_popup_mouse_event = false;
#ifndef QT_NO_CONTEXTMENU
} else if (event->type() == QEvent::MouseButtonPress
diff --git a/src/widgets/kernel/qwidgetwindow_qpa_p.h b/src/widgets/kernel/qwidgetwindow_qpa_p.h
index 7e40ded8c8..cb7bef8f3e 100644
--- a/src/widgets/kernel/qwidgetwindow_qpa_p.h
+++ b/src/widgets/kernel/qwidgetwindow_qpa_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtCore/private/qobject_p.h>
#include <QtGui/private/qevent_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -72,6 +70,7 @@ protected:
void handleCloseEvent(QCloseEvent *);
void handleEnterLeaveEvent(QEvent *);
+ void handleFocusInEvent(QFocusEvent *);
void handleKeyEvent(QKeyEvent *);
void handleMouseEvent(QMouseEvent *);
void handleNonClientAreaMouseEvent(QMouseEvent *);
@@ -102,6 +101,12 @@ private slots:
private:
void updateGeometry();
+ enum FocusWidgets {
+ FirstFocusWidget,
+ LastFocusWidget
+ };
+ QWidget *getFocusWidget(FocusWidgets fw);
+
QWidget *m_widget;
QPointer<QWidget> m_implicit_mouse_grabber;
#ifndef QT_NO_DRAGANDDROP
@@ -111,6 +116,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWIDGETWINDOW_QPA_P_H
diff --git a/src/widgets/kernel/qwindowcontainer.cpp b/src/widgets/kernel/qwindowcontainer.cpp
new file mode 100644
index 0000000000..b02b05552f
--- /dev/null
+++ b/src/widgets/kernel/qwindowcontainer.cpp
@@ -0,0 +1,218 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtWidgets module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qwindowcontainer_p.h"
+#include "qwidget_p.h"
+#include <QtGui/qwindow.h>
+
+QT_BEGIN_NAMESPACE
+
+class QWindowContainerPrivate : public QWidgetPrivate
+{
+public:
+ Q_DECLARE_PUBLIC(QWindowContainer)
+
+ QWindowContainerPrivate() : window(0), oldFocusWindow(0) { }
+ ~QWindowContainerPrivate() { }
+
+ QPointer<QWindow> window;
+ QWindow *oldFocusWindow;
+};
+
+
+
+/*!
+ \fn QWidget *QWidget::createWindowContainer(QWindow *window, QWidget *parent, Qt::WindowFlags flags);
+
+ Creates a QWidget that makes it possible to embed \a window into
+ a QWidget-based application.
+
+ The window container is created as a child of \a parent and with
+ window flags \a flags.
+
+ Once the window has been embedded into the container, the
+ container will control the window's geometry and
+ visibility. Explicit calls to QWindow::setGeometry(),
+ QWindow::show() or QWindow::hide() on an embedded window is not
+ recommended.
+
+ The container takes over ownership of \a window. The window can
+ be removed from the window container with a call to
+ QWindow::setParent().
+
+ The window container has a number of known limitations:
+
+ \list
+
+ \li Stacking order; The embedded window will stack on top of the
+ widget hierarchy as an opaque box. The stacking order of multiple
+ overlapping window container instances is undefined.
+
+ \li Window Handles; The window container will explicitly invoke
+ winId() which will force the use of native window handles
+ inside the application. See \l {Native Widgets vs Alien Widgets}
+ {QWidget documentation} for more details.
+
+ \li Rendering Integration; The window container does not interoperate
+ with QGraphicsProxyWidget, QWidget::render() or similar functionality.
+
+ \li Focus Handling; It is possible to let the window container
+ instance have any focus policy and it will delegate focus to the
+ window via a call to QWindow::requestActivate(). However,
+ returning to the normal focus chain from the QWindow instance will
+ be up to the QWindow instance implementation itself. For instance,
+ when entering a Qt Quick based window with tab focus, it is quite
+ likely that further tab presses will only cycle inside the QML
+ application. Also, whether QWindow::requestActivate() actually
+ gives the window focus, is platform dependent.
+
+ \li Using many window container instances in a QWidget-based
+ application can greatly hurt the overall performance of the
+ application.
+
+ \endlist
+ */
+
+QWidget *QWidget::createWindowContainer(QWindow *window, QWidget *parent, Qt::WindowFlags flags)
+{
+ return new QWindowContainer(window, parent, flags);
+}
+
+
+
+/*!
+ \internal
+ */
+
+QWindowContainer::QWindowContainer(QWindow *embeddedWindow, QWidget *parent, Qt::WindowFlags flags)
+ : QWidget(*new QWindowContainerPrivate, parent, flags)
+{
+ Q_D(QWindowContainer);
+ if (!embeddedWindow) {
+ qWarning("QWindowContainer: embedded window cannot be null");
+ return;
+ }
+
+ d->window = embeddedWindow;
+
+ // We force this window to become a native window and reparent the
+ // window directly to it. This is done so that the order in which
+ // the QWindowContainer is added to a QWidget tree and when it
+ // gets a window does not matter.
+ winId();
+ d->window->setParent(windowHandle());
+
+ connect(QGuiApplication::instance(), SIGNAL(focusWindowChanged(QWindow *)), this, SLOT(focusWindowChanged(QWindow *)));
+}
+
+
+
+/*!
+ \internal
+ */
+
+QWindowContainer::~QWindowContainer()
+{
+ Q_D(QWindowContainer);
+ delete d->window;
+}
+
+
+
+/*!
+ \internal
+ */
+
+void QWindowContainer::focusWindowChanged(QWindow *focusWindow)
+{
+ Q_D(QWindowContainer);
+ d->oldFocusWindow = focusWindow;
+}
+
+
+
+/*!
+ \internal
+ */
+
+bool QWindowContainer::event(QEvent *e)
+{
+ Q_D(QWindowContainer);
+ if (!d->window)
+ return QWidget::event(e);
+
+ QEvent::Type type = e->type();
+ switch (type) {
+ case QEvent::ChildRemoved: {
+ QChildEvent *ce = static_cast<QChildEvent *>(e);
+ if (ce->child() == d->window)
+ d->window = 0;
+ break;
+ }
+ // The only thing we are interested in is making sure our sizes stay
+ // in sync, so do a catch-all case.
+ case QEvent::Resize:
+ case QEvent::Move:
+ case QEvent::PolishRequest:
+ d->window->setGeometry(0, 0, width(), height());
+ break;
+ case QEvent::Show:
+ d->window->show();
+ break;
+ case QEvent::Hide:
+ d->window->hide();
+ break;
+ case QEvent::FocusIn:
+ if (d->oldFocusWindow != d->window) {
+ d->window->requestActivate();
+ } else {
+ QWidget *next = nextInFocusChain();
+ next->setFocus();
+ }
+ break;
+ default:
+ break;
+ }
+
+ return QWidget::event(e);
+}
+
+QT_END_NAMESPACE
diff --git a/src/widgets/kernel/qwindowcontainer_p.h b/src/widgets/kernel/qwindowcontainer_p.h
new file mode 100644
index 0000000000..37c023fc1d
--- /dev/null
+++ b/src/widgets/kernel/qwindowcontainer_p.h
@@ -0,0 +1,69 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtWidgets module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QWINDOWCONTAINER_H
+#define QWINDOWCONTAINER_H
+
+#include <QtWidgets/qwidget.h>
+
+QT_BEGIN_NAMESPACE
+
+class QWindowContainerPrivate;
+
+class QWindowContainer : public QWidget
+{
+ Q_OBJECT
+ Q_DECLARE_PRIVATE(QWindowContainer)
+
+public:
+ explicit QWindowContainer(QWindow *embeddedWindow, QWidget *parent = 0, Qt::WindowFlags f = 0);
+ ~QWindowContainer();
+
+protected:
+ bool event(QEvent *ev);
+
+private slots:
+ void focusWindowChanged(QWindow *focusWindow);
+};
+
+QT_END_NAMESPACE
+
+#endif // QWINDOWCONTAINER_H
diff --git a/src/widgets/statemachine/qbasickeyeventtransition.cpp b/src/widgets/statemachine/qbasickeyeventtransition.cpp
index edc656119e..5a1b98690e 100644
--- a/src/widgets/statemachine/qbasickeyeventtransition.cpp
+++ b/src/widgets/statemachine/qbasickeyeventtransition.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/statemachine/qbasickeyeventtransition_p.h b/src/widgets/statemachine/qbasickeyeventtransition_p.h
index 45a32ca0d0..0d1e815dec 100644
--- a/src/widgets/statemachine/qbasickeyeventtransition_p.h
+++ b/src/widgets/statemachine/qbasickeyeventtransition_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/statemachine/qbasicmouseeventtransition.cpp b/src/widgets/statemachine/qbasicmouseeventtransition.cpp
index 99ad1cb1fa..67d45c86db 100644
--- a/src/widgets/statemachine/qbasicmouseeventtransition.cpp
+++ b/src/widgets/statemachine/qbasicmouseeventtransition.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/statemachine/qbasicmouseeventtransition_p.h b/src/widgets/statemachine/qbasicmouseeventtransition_p.h
index 7a779d3e1b..47c9f967c0 100644
--- a/src/widgets/statemachine/qbasicmouseeventtransition_p.h
+++ b/src/widgets/statemachine/qbasicmouseeventtransition_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/statemachine/qguistatemachine.cpp b/src/widgets/statemachine/qguistatemachine.cpp
index e574dd7406..d737a1e323 100644
--- a/src/widgets/statemachine/qguistatemachine.cpp
+++ b/src/widgets/statemachine/qguistatemachine.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -138,7 +138,7 @@ static QEvent *cloneEvent(QEvent *e)
return new QEvent(*e);
case QEvent::DeferredDelete:
return new QEvent(*e);
-#ifndef QT_NO_DRAGANDDROP
+#ifndef QT_NO_DRAGANDDROP
case QEvent::DragEnter:
return new QDragEnterEvent(*static_cast<QDragEnterEvent*>(e));
case QEvent::DragMove:
diff --git a/src/widgets/statemachine/qkeyeventtransition.cpp b/src/widgets/statemachine/qkeyeventtransition.cpp
index 9f54742ad9..f9a67642e0 100644
--- a/src/widgets/statemachine/qkeyeventtransition.cpp
+++ b/src/widgets/statemachine/qkeyeventtransition.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/statemachine/qkeyeventtransition.h b/src/widgets/statemachine/qkeyeventtransition.h
index 9be5a67c0f..dc310167a3 100644
--- a/src/widgets/statemachine/qkeyeventtransition.h
+++ b/src/widgets/statemachine/qkeyeventtransition.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtCore/qeventtransition.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -82,6 +80,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/widgets/statemachine/qmouseeventtransition.cpp b/src/widgets/statemachine/qmouseeventtransition.cpp
index 3ea3dc74d4..427e60b75e 100644
--- a/src/widgets/statemachine/qmouseeventtransition.cpp
+++ b/src/widgets/statemachine/qmouseeventtransition.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/statemachine/qmouseeventtransition.h b/src/widgets/statemachine/qmouseeventtransition.h
index b215df8bc1..a3606e81bc 100644
--- a/src/widgets/statemachine/qmouseeventtransition.h
+++ b/src/widgets/statemachine/qmouseeventtransition.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtCore/qeventtransition.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -86,6 +84,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/src/widgets/styles/images/toolbar-ext.png b/src/widgets/styles/images/toolbar-ext.png
new file mode 100644
index 0000000000..37bd403ff8
--- /dev/null
+++ b/src/widgets/styles/images/toolbar-ext.png
Binary files differ
diff --git a/src/widgets/styles/images/toolbar-ext@2x.png b/src/widgets/styles/images/toolbar-ext@2x.png
new file mode 100644
index 0000000000..6fc729efb0
--- /dev/null
+++ b/src/widgets/styles/images/toolbar-ext@2x.png
Binary files differ
diff --git a/src/widgets/styles/qandroidstyle.cpp b/src/widgets/styles/qandroidstyle.cpp
new file mode 100644
index 0000000000..d82a06987a
--- /dev/null
+++ b/src/widgets/styles/qandroidstyle.cpp
@@ -0,0 +1,1601 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtWidgets module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qandroidstyle_p.h"
+
+#if !defined(QT_NO_STYLE_ANDROID) || defined(QT_PLUGIN)
+
+#include <QFile>
+#include <QFont>
+#include <QApplication>
+#include <QTime>
+#include <qdrawutil.h>
+#include <QPixmapCache>
+#include <QFileInfo>
+#include <QStyleOption>
+#include <QPainter>
+#include <QJsonDocument>
+#include <QJsonObject>
+
+#include <QDebug>
+
+QT_BEGIN_NAMESPACE
+
+namespace {
+ const int textStyle_bold = 1;
+ const int textStyle_italic = 2;
+
+ const int typeface_sans = 1;
+ const int typeface_serif = 2;
+ const int typeface_monospace = 3;
+
+ const quint32 NO_COLOR = 1;
+ const quint32 TRANSPARENT_COLOR = 0;
+}
+
+
+QAndroidStyle::QAndroidStyle()
+ : QCommonStyle()
+{
+ QString stylePath(QLatin1String(qgetenv("MINISTRO_ANDROID_STYLE_PATH")));
+
+ if (stylePath.isEmpty())
+ stylePath = QLatin1String("/data/data/org.kde.necessitas.ministro/files/qt/style/");
+ Q_ASSERT(!stylePath.isEmpty());
+
+ QFile f(stylePath + QLatin1String("style.json"));
+ if (!f.open(QIODevice::ReadOnly))
+ return;
+
+ QJsonParseError error;
+ QJsonDocument document = QJsonDocument::fromJson(f.readAll(), &error);
+ if (document.isNull()) {
+ qCritical() << error.errorString();
+ return;
+ }
+
+ if (!document.isObject()) {
+ qCritical() << "Style.json does not contain a valid style.";
+ return;
+ }
+
+ QJsonObject object = document.object();
+ for (QJsonObject::const_iterator objectIterator = object.constBegin();
+ objectIterator != object.constEnd();
+ ++objectIterator) {
+ QString key = objectIterator.key();
+ QJsonValue value = objectIterator.value();
+ if (!value.isObject()) {
+ qWarning("Style.json structure is unrecognized.");
+ continue;
+ }
+
+ QJsonObject item = value.toObject();
+ QJsonObject::const_iterator attributeIterator = item.find(QLatin1String("qtClass"));
+ if (attributeIterator != item.constEnd()) {
+ // The item has palette and font information for a specific Qt Class (e.g. QWidget, QPushButton, etc.)
+ const QString qtClassName = attributeIterator.value().toString();
+
+ // Extract font information
+ QFont font;
+
+ // Font size (in pixels)
+ attributeIterator = item.find(QLatin1String("TextAppearance_textSize"));
+ if (attributeIterator != item.constEnd())
+ font.setPixelSize(int(attributeIterator.value().toDouble()));
+
+ // Font style
+ attributeIterator = item.find(QLatin1String("TextAppearance_textStyle"));
+ if (attributeIterator != item.constEnd()) {
+ const int style = int(attributeIterator.value().toDouble());
+ font.setBold(style & textStyle_bold);
+ font.setItalic(style & textStyle_italic);
+ }
+
+ // Font typeface
+ attributeIterator = item.find(QLatin1String("TextAppearance_typeface"));
+ if (attributeIterator != item.constEnd()) {
+ QFont::StyleHint styleHint = QFont::AnyStyle;
+ switch (int(attributeIterator.value().toDouble())) {
+ case typeface_sans:
+ styleHint = QFont::SansSerif;
+ break;
+ case typeface_serif:
+ styleHint = QFont::Serif;
+ break;
+ case typeface_monospace:
+ styleHint = QFont::Monospace;
+ break;
+ }
+ font.setStyleHint(styleHint, QFont::PreferMatch);
+ }
+ QApplication::setFont(font, qtClassName.toUtf8());
+ // Extract font information
+
+ // Extract palette information
+ QPalette palette;
+ attributeIterator = item.find(QLatin1String("TextAppearance_textColor"));
+ if (attributeIterator != item.constEnd())
+ setPaletteColor(attributeIterator.value().toObject().toVariantMap(), palette, QPalette::WindowText);
+
+ attributeIterator = item.find(QLatin1String("TextAppearance_textColorLink"));
+ if (attributeIterator != item.constEnd())
+ setPaletteColor(attributeIterator.value().toObject().toVariantMap(), palette, QPalette::Link);
+
+ attributeIterator = item.find(QLatin1String("TextAppearance_textColorHighlight"));
+ if (attributeIterator != item.constEnd())
+ palette.setColor(QPalette::Highlight, QRgb(int(attributeIterator.value().toDouble())));
+ palette.setColor(QPalette::Window, Qt::black);
+ QApplication::setPalette(palette, qtClassName.toUtf8());
+ if (QLatin1String("QWidget") == qtClassName)
+ m_standardPalette = palette;
+ // Extract palette information
+ }
+ QAndroidStyle::ItemType itemType = qtControl(key);
+ if (QC_UnknownType == itemType)
+ continue;
+
+ switch (itemType) {
+ case QC_Checkbox:
+ case QC_RadioButton:
+ m_androidControlsHash[int(itemType)] = new AndroidCompoundButtonControl(item.toVariantMap(),
+ itemType);
+ break;
+
+ case QC_ProgressBar:
+ m_androidControlsHash[int(itemType)] = new AndroidProgressBarControl(item.toVariantMap(),
+ itemType);
+ break;
+
+ case QC_Slider:
+ m_androidControlsHash[int(itemType)] = new AndroidSeekBarControl(item.toVariantMap(),
+ itemType);
+ break;
+
+ case QC_Combobox:
+ m_androidControlsHash[int(itemType)] = new AndroidSpinnerControl(item.toVariantMap(),
+ itemType);
+ break;
+
+ default:
+ m_androidControlsHash[int(itemType)] = new AndroidControl(item.toVariantMap(),
+ itemType);
+ break;
+ }
+ }
+ QApplication::setPalette(QApplication::palette("simple_list_item"), "QListView");
+ QApplication::setFont(QApplication::font("simple_list_item"), "QListView");
+ QApplication::setPalette(QApplication::palette("simple_list_item"), "QAbstractItemView");
+ QApplication::setFont(QApplication::font("simple_list_item"), "QAbstractItemView");
+}
+
+QAndroidStyle::~QAndroidStyle()
+{
+ qDeleteAll(m_androidControlsHash);
+}
+
+
+void QAndroidStyle::setPaletteColor(const QVariantMap &object,
+ QPalette &palette,
+ QPalette::ColorRole role)
+{
+ // QPalette::Active -> ENABLED_FOCUSED_WINDOW_FOCUSED_STATE_SET
+ palette.setColor(QPalette::Active,
+ role,
+ QRgb(object.value(QLatin1String("ENABLED_FOCUSED_WINDOW_FOCUSED_STATE_SET")).toInt()));
+
+ // QPalette::Inactive -> ENABLED_STATE_SET
+ palette.setColor(QPalette::Inactive,
+ role,
+ QRgb(object.value(QLatin1String("ENABLED_STATE_SET")).toInt()));
+
+ // QPalette::Disabled -> EMPTY_STATE_SET
+ palette.setColor(QPalette::Disabled,
+ role,
+ QRgb(object.value(QLatin1String("EMPTY_STATE_SET")).toInt()));
+
+ palette.setColor(QPalette::Current, role, palette.color(QPalette::Active, role));
+
+ if (role == QPalette::WindowText) {
+ // QPalette::BrightText -> PRESSED
+ // QPalette::Active -> PRESSED_ENABLED_FOCUSED_WINDOW_FOCUSED_STATE_SET
+ palette.setColor(QPalette::Active,
+ QPalette::BrightText,
+ QRgb(object.value(QLatin1String("PRESSED_ENABLED_FOCUSED_WINDOW_FOCUSED_STATE_SET")).toInt()));
+
+ // QPalette::Inactive -> PRESSED_ENABLED_STATE_SET
+ palette.setColor(QPalette::Inactive,
+ QPalette::BrightText,
+ QRgb(object.value(QLatin1String("PRESSED_ENABLED_STATE_SET")).toInt()));
+
+ // QPalette::Disabled -> PRESSED_STATE_SET
+ palette.setColor(QPalette::Disabled,
+ QPalette::BrightText,
+ QRgb(object.value(QLatin1String("PRESSED_STATE_SET")).toInt()));
+
+ palette.setColor(QPalette::Current, QPalette::BrightText, palette.color(QPalette::Active, QPalette::BrightText));
+
+ // QPalette::HighlightedText -> SELECTED
+ // QPalette::Active -> ENABLED_SELECTED_WINDOW_FOCUSED_STATE_SET
+ palette.setColor(QPalette::Active,
+ QPalette::HighlightedText,
+ QRgb(object.value(QLatin1String("ENABLED_SELECTED_WINDOW_FOCUSED_STATE_SET")).toInt()));
+
+ // QPalette::Inactive -> ENABLED_SELECTED_STATE_SET
+ palette.setColor(QPalette::Inactive,
+ QPalette::HighlightedText,
+ QRgb(object.value(QLatin1String("ENABLED_SELECTED_STATE_SET")).toInt()));
+
+ // QPalette::Disabled -> SELECTED_STATE_SET
+ palette.setColor(QPalette::Disabled,
+ QPalette::HighlightedText,
+ QRgb(object.value(QLatin1String("SELECTED_STATE_SET")).toInt()));
+
+ palette.setColor(QPalette::Current,
+ QPalette::HighlightedText,
+ palette.color(QPalette::Active, QPalette::HighlightedText));
+
+ // Same colors for Text
+ palette.setColor(QPalette::Active, QPalette::Text, palette.color(QPalette::Active, role));
+ palette.setColor(QPalette::Inactive, QPalette::Text, palette.color(QPalette::Inactive, role));
+ palette.setColor(QPalette::Disabled, QPalette::Text, palette.color(QPalette::Disabled, role));
+ palette.setColor(QPalette::Current, QPalette::Text, palette.color(QPalette::Current, role));
+
+ // And for ButtonText
+ palette.setColor(QPalette::Active, QPalette::ButtonText, palette.color(QPalette::Active, role));
+ palette.setColor(QPalette::Inactive, QPalette::ButtonText, palette.color(QPalette::Inactive, role));
+ palette.setColor(QPalette::Disabled, QPalette::ButtonText, palette.color(QPalette::Disabled, role));
+ palette.setColor(QPalette::Current, QPalette::ButtonText, palette.color(QPalette::Current, role));
+ }
+}
+
+QAndroidStyle::ItemType QAndroidStyle::qtControl(const QString &android)
+{
+ if (android == QLatin1String("buttonStyle"))
+ return QC_Button;
+ if (android == QLatin1String("editTextStyle"))
+ return QC_EditText;
+ if (android == QLatin1String("radioButtonStyle"))
+ return QC_RadioButton;
+ if (android == QLatin1String("checkboxStyle"))
+ return QC_Checkbox;
+ if (android == QLatin1String("textViewStyle"))
+ return QC_View;
+ if (android == QLatin1String("buttonStyleToggle"))
+ return QC_Switch;
+ if (android == QLatin1String("spinnerStyle"))
+ return QC_Combobox;
+ if (android == QLatin1String("progressBarStyleHorizontal"))
+ return QC_ProgressBar;
+ if (android == QLatin1String("seekBarStyle"))
+ return QC_Slider;
+
+ return QC_UnknownType;
+}
+
+QAndroidStyle::ItemType QAndroidStyle::qtControl(QStyle::ComplexControl control)
+{
+ switch (control) {
+ case CC_ComboBox:
+ return QC_Combobox;
+ case CC_Slider:
+ return QC_Slider;
+ case CC_GroupBox:
+ return QC_View;
+ default:
+ return QC_UnknownType;
+ }
+}
+
+QAndroidStyle::ItemType QAndroidStyle::qtControl(QStyle::ContentsType contentsType)
+{
+ switch (contentsType) {
+ case CT_PushButton:
+ return QC_Button;
+ case CT_CheckBox:
+ return QC_Checkbox;
+ case CT_RadioButton:
+ return QC_RadioButton;
+ case CT_ComboBox:
+ return QC_Combobox;
+ case CT_ProgressBar:
+ return QC_ProgressBar;
+ case CT_Slider:
+ return QC_Slider;
+ case CT_TabWidget:
+ return QC_Tab;
+ case CT_TabBarTab:
+ return QC_TabButton;
+ case CT_LineEdit:
+ return QC_EditText;
+ case CT_GroupBox:
+ return QC_GroupBox;
+ default:
+ return QC_UnknownType;
+ }
+}
+
+QAndroidStyle::ItemType QAndroidStyle::qtControl(QStyle::ControlElement controlElement)
+{
+ switch (controlElement) {
+ case CE_PushButton:
+ case CE_PushButtonBevel:
+ case CE_PushButtonLabel:
+ return QC_Button;
+
+ case CE_CheckBox:
+ case CE_CheckBoxLabel:
+ return QC_Checkbox;
+
+ case CE_RadioButton:
+ case CE_RadioButtonLabel:
+ return QC_RadioButton;
+
+ case CE_TabBarTab:
+ case CE_TabBarTabShape:
+ case CE_TabBarTabLabel:
+ return QC_Tab;
+
+ case CE_ProgressBar:
+ case CE_ProgressBarGroove:
+ case CE_ProgressBarContents:
+ case CE_ProgressBarLabel:
+ return QC_ProgressBar;
+
+ case CE_ComboBoxLabel:
+ return QC_Combobox;
+
+ default:
+ return QC_UnknownType;
+ }
+}
+
+QAndroidStyle::ItemType QAndroidStyle::qtControl(QStyle::PrimitiveElement primitiveElement)
+{
+ switch (primitiveElement) {
+ case QStyle::PE_PanelLineEdit:
+ case QStyle::PE_FrameLineEdit:
+ return QC_EditText;
+
+ case QStyle::PE_FrameWindow:
+ case QStyle::PE_Widget:
+ case QStyle::PE_Frame:
+ case QStyle::PE_FrameFocusRect:
+ return QC_View;
+ default:
+ return QC_UnknownType;
+ }
+}
+
+QAndroidStyle::ItemType QAndroidStyle::qtControl(QStyle::SubElement subElement)
+{
+ switch (subElement) {
+ case QStyle::SE_LineEditContents:
+ return QC_EditText;
+
+ case QStyle::SE_PushButtonContents:
+ case QStyle::SE_PushButtonFocusRect:
+ return QC_Button;
+
+ case SE_RadioButtonContents:
+ return QC_RadioButton;
+
+ case SE_CheckBoxContents:
+ return QC_Checkbox;
+
+ default:
+ return QC_UnknownType;
+ }
+}
+
+void QAndroidStyle::drawPrimitive(PrimitiveElement pe,
+ const QStyleOption *opt,
+ QPainter *p,
+ const QWidget *w) const
+{
+ const ItemType itemType = qtControl(pe);
+ AndroidControlsHash::const_iterator it = itemType != QC_UnknownType
+ ? m_androidControlsHash.find(itemType)
+ : m_androidControlsHash.end();
+ if (it != m_androidControlsHash.end())
+ it.value()->drawControl(opt, p, w);
+ else
+ QCommonStyle::drawPrimitive(pe, opt, p, w);
+}
+
+
+void QAndroidStyle::drawControl(QStyle::ControlElement element,
+ const QStyleOption *opt,
+ QPainter *p,
+ const QWidget *w) const
+{
+ const ItemType itemType = qtControl(element);
+ AndroidControlsHash::const_iterator it = itemType != QC_UnknownType
+ ? m_androidControlsHash.find(itemType)
+ : m_androidControlsHash.end();
+ if (it != m_androidControlsHash.end()) {
+ it.value()->drawControl(opt, p, w);
+
+ switch (itemType) {
+ case QC_Button:
+ if (const QStyleOptionButton *buttonOption =
+ qstyleoption_cast<const QStyleOptionButton *>(opt)) {
+ QMargins padding = it.value()->padding();
+ QStyleOptionButton copy (*buttonOption);
+ copy.rect.adjust(padding.left(), padding.top(), -padding.right(), -padding.bottom());
+ QCommonStyle::drawControl(CE_PushButtonLabel, &copy, p, w);
+ }
+ break;
+ case QC_Checkbox:
+ case QC_RadioButton:
+ if (const QStyleOptionButton *btn =
+ qstyleoption_cast<const QStyleOptionButton *>(opt)) {
+ const bool isRadio = (element == CE_RadioButton);
+ QStyleOptionButton subopt(*btn);
+ subopt.rect = subElementRect(isRadio ? SE_RadioButtonContents
+ : SE_CheckBoxContents, btn, w);
+ QCommonStyle::drawControl(isRadio ? CE_RadioButtonLabel : CE_CheckBoxLabel, &subopt, p, w);
+ }
+ break;
+ case QC_Combobox:
+ if (const QStyleOptionComboBox *comboboxOption =
+ qstyleoption_cast<const QStyleOptionComboBox *>(opt)) {
+ QMargins padding = it.value()->padding();
+ QStyleOptionComboBox copy (*comboboxOption);
+ copy.rect.adjust(padding.left(), padding.top(), -padding.right(), -padding.bottom());
+ p->setFont(QApplication::font("simple_spinner_item"));
+ p->setPen(QApplication::palette("QPushButton").color(QPalette::Active, QPalette::Text));
+ QCommonStyle::drawControl(CE_ComboBoxLabel, comboboxOption, p, w);
+ }
+ break;
+ default:
+ break;
+ }
+ }
+ else
+ QCommonStyle::drawControl(element, opt, p, w);
+}
+
+QRect QAndroidStyle::subElementRect(SubElement subElement,
+ const QStyleOption *option,
+ const QWidget *widget) const
+{
+ const ItemType itemType = qtControl(subElement);
+ AndroidControlsHash::const_iterator it = itemType != QC_UnknownType
+ ? m_androidControlsHash.find(itemType)
+ : m_androidControlsHash.end();
+ if (it != m_androidControlsHash.end())
+ return it.value()->subElementRect(subElement, option, widget);
+ return QCommonStyle::subElementRect(subElement, option, widget);
+}
+
+void QAndroidStyle::drawComplexControl(ComplexControl cc,
+ const QStyleOptionComplex *opt,
+ QPainter *p,
+ const QWidget *widget) const
+{
+ const ItemType itemType = qtControl(cc);
+ AndroidControlsHash::const_iterator it = itemType != QC_UnknownType
+ ? m_androidControlsHash.find(itemType)
+ : m_androidControlsHash.end();
+ if (it != m_androidControlsHash.end())
+ it.value()->drawControl(opt, p, widget);
+ else
+ QCommonStyle::drawComplexControl(cc, opt, p, widget);
+}
+
+QStyle::SubControl QAndroidStyle::hitTestComplexControl(ComplexControl cc,
+ const QStyleOptionComplex *opt,
+ const QPoint &pt,
+ const QWidget *widget) const
+{
+ const ItemType itemType = qtControl(cc);
+ AndroidControlsHash::const_iterator it = itemType != QC_UnknownType
+ ? m_androidControlsHash.find(itemType)
+ : m_androidControlsHash.end();
+ if (it != m_androidControlsHash.end()) {
+ switch (cc) {
+ case CC_Slider:
+ if (const QStyleOptionSlider *slider = qstyleoption_cast<const QStyleOptionSlider *>(opt)) {
+ QRect r = it.value()->subControlRect(slider, SC_SliderHandle, widget);
+ if (r.isValid() && r.contains(pt)) {
+ return SC_SliderHandle;
+ } else {
+ r = it.value()->subControlRect(slider, SC_SliderGroove, widget);
+ if (r.isValid() && r.contains(pt))
+ return SC_SliderGroove;
+ }
+ }
+ break;
+ default:
+ break;
+ }
+ }
+ return QCommonStyle::hitTestComplexControl(cc, opt, pt, widget);
+}
+
+QRect QAndroidStyle::subControlRect(ComplexControl cc,
+ const QStyleOptionComplex *opt,
+ SubControl sc,
+ const QWidget *widget) const
+{
+ const ItemType itemType = qtControl(cc);
+ AndroidControlsHash::const_iterator it = itemType != QC_UnknownType
+ ? m_androidControlsHash.find(itemType)
+ : m_androidControlsHash.end();
+ if (it != m_androidControlsHash.end())
+ return it.value()->subControlRect(opt, sc, widget);
+ return QCommonStyle::subControlRect(cc, opt, sc, widget);
+}
+
+int QAndroidStyle::pixelMetric(PixelMetric metric, const QStyleOption *option,
+ const QWidget *widget) const
+{
+ switch (metric) {
+ case PM_ButtonMargin:
+ case PM_FocusFrameVMargin:
+ case PM_FocusFrameHMargin:
+ case PM_ComboBoxFrameWidth:
+ case PM_SpinBoxFrameWidth:
+ return 0;
+ default:
+ return QCommonStyle::pixelMetric(metric, option, widget);
+ }
+
+}
+
+QSize QAndroidStyle::sizeFromContents(ContentsType ct,
+ const QStyleOption *opt,
+ const QSize &contentsSize,
+ const QWidget *w) const
+{
+ QSize sz=QCommonStyle::sizeFromContents(ct, opt, contentsSize, w);
+ const ItemType itemType = qtControl(ct);
+ AndroidControlsHash::const_iterator it = itemType != QC_UnknownType
+ ? m_androidControlsHash.find(itemType)
+ : m_androidControlsHash.end();
+ if (it != m_androidControlsHash.end())
+ return it.value()->sizeFromContents(opt, sz, w);
+ return sz;
+}
+
+QPixmap QAndroidStyle::standardPixmap(StandardPixmap standardPixmap,
+ const QStyleOption *opt,
+ const QWidget *widget) const
+{
+ return QCommonStyle::standardPixmap(standardPixmap, opt, widget);
+}
+
+QPixmap QAndroidStyle::generatedIconPixmap(QIcon::Mode iconMode,
+ const QPixmap &pixmap,
+ const QStyleOption *opt) const
+{
+ return QCommonStyle::generatedIconPixmap(iconMode, pixmap, opt);
+}
+
+QPalette QAndroidStyle::standardPalette() const
+{
+ return m_standardPalette;
+}
+
+QAndroidStyle::AndroidDrawable::AndroidDrawable(const QVariantMap &drawable,
+ QAndroidStyle::ItemType itemType)
+{
+ initPadding(drawable);
+ m_itemType = itemType;
+}
+
+QAndroidStyle::AndroidDrawable::~AndroidDrawable()
+{
+}
+
+void QAndroidStyle::AndroidDrawable::initPadding(const QVariantMap &drawable)
+{
+ QVariantMap::const_iterator it = drawable.find(QLatin1String("padding"));
+ if (it != drawable.end())
+ m_padding = extractMargins(it.value().toMap());
+}
+
+const QMargins &QAndroidStyle::AndroidDrawable::padding() const
+{
+ return m_padding;
+}
+
+QSize QAndroidStyle::AndroidDrawable::size() const
+{
+ if (type() == Image || type() == NinePatch)
+ return static_cast<const QAndroidStyle::AndroidImageDrawable *>(this)->size();
+
+ return QSize();
+}
+
+QAndroidStyle::AndroidDrawable * QAndroidStyle::AndroidDrawable::fromMap(const QVariantMap &drawable,
+ ItemType itemType)
+{
+ const QString type = drawable.value(QLatin1String("type")).toString();
+ if (type == QLatin1String("image"))
+ return new QAndroidStyle::AndroidImageDrawable(drawable, itemType);
+ if (type == QLatin1String("9patch"))
+ return new QAndroidStyle::Android9PatchDrawable(drawable, itemType);
+ if (type == QLatin1String("stateslist"))
+ return new QAndroidStyle::AndroidStateDrawable(drawable, itemType);
+ if (type == QLatin1String("layer"))
+ return new QAndroidStyle::AndroidLayerDrawable(drawable, itemType);
+ if (type == QLatin1String("gradient"))
+ return new QAndroidStyle::AndroidGradientDrawable(drawable, itemType);
+ if (type == QLatin1String("clipDrawable"))
+ return new QAndroidStyle::AndroidClipDrawable(drawable, itemType);
+ if (type == QLatin1String("color"))
+ return new QAndroidStyle::AndroidColorDrawable(drawable, itemType);
+ return 0;
+}
+
+QMargins QAndroidStyle::AndroidDrawable::extractMargins(const QVariantMap &value)
+{
+ QMargins m;
+ m.setLeft(value.value(QLatin1String("left")).toInt());
+ m.setRight(value.value(QLatin1String("right")).toInt());
+ m.setTop(value.value(QLatin1String("top")).toInt());
+ m.setBottom(value.value(QLatin1String("bottom")).toInt());
+ return m;
+}
+
+
+QAndroidStyle::AndroidImageDrawable::AndroidImageDrawable(const QVariantMap &drawable,
+ QAndroidStyle::ItemType itemType)
+ : AndroidDrawable(drawable, itemType)
+{
+ m_filePath = drawable.value(QLatin1String("path")).toString();
+ m_size.setHeight(drawable.value(QLatin1String("height")).toInt());
+ m_size.setWidth(drawable.value(QLatin1String("width")).toInt());
+}
+
+QAndroidStyle::AndroidDrawableType QAndroidStyle::AndroidImageDrawable::type() const
+{
+ return QAndroidStyle::Image;
+}
+
+void QAndroidStyle::AndroidImageDrawable::draw(QPainter *painter, const QStyleOption *opt) const
+{
+ if (m_hashKey.isEmpty())
+ m_hashKey = QFileInfo(m_filePath).fileName();
+
+ QPixmap pm;
+ if (!QPixmapCache::find(m_hashKey, &pm)) {
+ pm.load(m_filePath);
+ QPixmapCache::insert(m_hashKey, pm);
+ }
+
+ painter->drawPixmap(opt->rect.x(), (opt->rect.height() - pm.height()) / 2, pm);
+}
+
+QSize QAndroidStyle::AndroidImageDrawable::size() const
+{
+ return m_size;
+}
+
+QAndroidStyle::AndroidColorDrawable::AndroidColorDrawable(const QVariantMap &drawable,
+ ItemType itemType)
+ : AndroidDrawable(drawable, itemType)
+{
+ m_color.setRgba(QRgb(drawable.value(QLatin1String("color")).toInt()));
+}
+
+QAndroidStyle::AndroidDrawableType QAndroidStyle::AndroidColorDrawable::type() const
+{
+ return QAndroidStyle::Color;
+}
+
+void QAndroidStyle::AndroidColorDrawable::draw(QPainter *painter, const QStyleOption *opt) const
+{
+ painter->fillRect(opt->rect, m_color);
+}
+
+QAndroidStyle::Android9PatchDrawable::Android9PatchDrawable(const QVariantMap &drawable,
+ QAndroidStyle::ItemType itemType)
+ : AndroidImageDrawable(drawable.value(QLatin1String("drawable")).toMap(), itemType)
+{
+ initPadding(drawable);
+ QVariantMap chunk = drawable.value(QLatin1String("chunkInfo")).toMap();
+ extractIntArray(chunk.value(QLatin1String("xdivs")).toList(), m_chunkData.xDivs);
+ extractIntArray(chunk.value(QLatin1String("ydivs")).toList(), m_chunkData.yDivs);
+ extractIntArray(chunk.value(QLatin1String("colors")).toList(), m_chunkData.colors);
+}
+
+QAndroidStyle::AndroidDrawableType QAndroidStyle::Android9PatchDrawable::type() const
+{
+ return QAndroidStyle::NinePatch;
+}
+
+int QAndroidStyle::Android9PatchDrawable::calculateStretch(int boundsLimit,
+ int startingPoint,
+ int srcSpace,
+ int numStrechyPixelsRemaining,
+ int numFixedPixelsRemaining)
+{
+ int spaceRemaining = boundsLimit - startingPoint;
+ int stretchySpaceRemaining = spaceRemaining - numFixedPixelsRemaining;
+ return (float(srcSpace) * stretchySpaceRemaining / numStrechyPixelsRemaining + .5);
+}
+
+void QAndroidStyle::Android9PatchDrawable::extractIntArray(const QVariantList &values,
+ QVector<int> & array)
+{
+ foreach (QVariant value, values)
+ array << value.toInt();
+}
+
+
+void QAndroidStyle::Android9PatchDrawable::draw(QPainter * painter, const QStyleOption *opt) const
+{
+ if (m_hashKey.isEmpty())
+ m_hashKey = QFileInfo(m_filePath).fileName();
+
+ QPixmap pixmap;
+ if (!QPixmapCache::find(m_hashKey, &pixmap)) {
+ pixmap.load(m_filePath);
+ QPixmapCache::insert(m_hashKey, pixmap);
+ }
+
+ const QRect &bounds=opt->rect;
+
+ // shamelessly stolen from Android's sources (NinepatchImpl.cpp) and adapted for Qt
+ const int pixmapWidth = pixmap.width();
+ const int pixmapHeight = pixmap.height();
+
+ if (bounds.isNull() || !pixmapWidth || !pixmapHeight)
+ return;
+
+ QPainter::RenderHints savedHints = painter->renderHints();
+
+ // The patchs doesn't need smooth transform !
+ painter->setRenderHints(QPainter::SmoothPixmapTransform, false);
+
+ QRectF dst;
+ QRectF src;
+
+ const qint32 x0 = m_chunkData.xDivs[0];
+ const qint32 y0 = m_chunkData.yDivs[0];
+ const quint8 numXDivs = m_chunkData.xDivs.size();
+ const quint8 numYDivs = m_chunkData.yDivs.size();
+ int i;
+ int j;
+ int colorIndex = 0;
+ quint32 color;
+ bool xIsStretchable;
+ const bool initialXIsStretchable = (x0 == 0);
+ bool yIsStretchable = (y0 == 0);
+ const int bitmapWidth = pixmap.width();
+ const int bitmapHeight = pixmap.height();
+
+ int *dstRights = static_cast<int *>(alloca((numXDivs + 1) * sizeof(int)));
+ bool dstRightsHaveBeenCached = false;
+
+ int numStretchyXPixelsRemaining = 0;
+ for (i = 0; i < numXDivs; i += 2)
+ numStretchyXPixelsRemaining += m_chunkData.xDivs[i + 1] - m_chunkData.xDivs[i];
+
+ int numFixedXPixelsRemaining = bitmapWidth - numStretchyXPixelsRemaining;
+ int numStretchyYPixelsRemaining = 0;
+ for (i = 0; i < numYDivs; i += 2)
+ numStretchyYPixelsRemaining += m_chunkData.yDivs[i + 1] - m_chunkData.yDivs[i];
+
+ int numFixedYPixelsRemaining = bitmapHeight - numStretchyYPixelsRemaining;
+ src.setTop(0);
+ dst.setTop(bounds.top());
+ // The first row always starts with the top being at y=0 and the bottom
+ // being either yDivs[1] (if yDivs[0]=0) of yDivs[0]. In the former case
+ // the first row is stretchable along the Y axis, otherwise it is fixed.
+ // The last row always ends with the bottom being bitmap.height and the top
+ // being either yDivs[numYDivs-2] (if yDivs[numYDivs-1]=bitmap.height) or
+ // yDivs[numYDivs-1]. In the former case the last row is stretchable along
+ // the Y axis, otherwise it is fixed.
+ //
+ // The first and last columns are similarly treated with respect to the X
+ // axis.
+ //
+ // The above is to help explain some of the special casing that goes on the
+ // code below.
+
+ // The initial yDiv and whether the first row is considered stretchable or
+ // not depends on whether yDiv[0] was zero or not.
+ for (j = yIsStretchable ? 1 : 0;
+ j <= numYDivs && src.top() < bitmapHeight;
+ j++, yIsStretchable = !yIsStretchable) {
+ src.setLeft(0);
+ dst.setLeft(bounds.left());
+ if (j == numYDivs) {
+ src.setBottom(bitmapHeight);
+ dst.setBottom(bounds.bottom());
+ } else {
+ src.setBottom(m_chunkData.yDivs[j]);
+ const int srcYSize = src.bottom() - src.top();
+ if (yIsStretchable) {
+ dst.setBottom(dst.top() + calculateStretch(bounds.bottom(), dst.top(),
+ srcYSize,
+ numStretchyYPixelsRemaining,
+ numFixedYPixelsRemaining));
+ numStretchyYPixelsRemaining -= srcYSize;
+ } else {
+ dst.setBottom(dst.top() + srcYSize);
+ numFixedYPixelsRemaining -= srcYSize;
+ }
+ }
+
+ xIsStretchable = initialXIsStretchable;
+ // The initial xDiv and whether the first column is considered
+ // stretchable or not depends on whether xDiv[0] was zero or not.
+ for (i = xIsStretchable ? 1 : 0;
+ i <= numXDivs && src.left() < bitmapWidth;
+ i++, xIsStretchable = !xIsStretchable) {
+ color = m_chunkData.colors[colorIndex++];
+ if (i == numXDivs) {
+ src.setRight(bitmapWidth);
+ dst.setRight(bounds.right());
+ } else {
+ src.setRight(m_chunkData.xDivs[i]);
+ if (dstRightsHaveBeenCached) {
+ dst.setRight(dstRights[i]);
+ } else {
+ const int srcXSize = src.right() - src.left();
+ if (xIsStretchable) {
+ dst.setRight(dst.left() + calculateStretch(bounds.right(), dst.left(),
+ srcXSize,
+ numStretchyXPixelsRemaining,
+ numFixedXPixelsRemaining));
+ numStretchyXPixelsRemaining -= srcXSize;
+ } else {
+ dst.setRight(dst.left() + srcXSize);
+ numFixedXPixelsRemaining -= srcXSize;
+ }
+ dstRights[i] = dst.right();
+ }
+ }
+ // If this horizontal patch is too small to be displayed, leave
+ // the destination left edge where it is and go on to the next patch
+ // in the source.
+ if (src.left() >= src.right()) {
+ src.setLeft(src.right());
+ continue;
+ }
+ // Make sure that we actually have room to draw any bits
+ if (dst.right() <= dst.left() || dst.bottom() <= dst.top()) {
+ goto nextDiv;
+ }
+ // If this patch is transparent, skip and don't draw.
+ if (color == TRANSPARENT_COLOR)
+ goto nextDiv;
+ if (color != NO_COLOR)
+ painter->fillRect(dst, (QRgb)color);
+ else
+ painter->drawPixmap(dst, pixmap, src);
+nextDiv:
+ src.setLeft(src.right());
+ dst.setLeft(dst.right());
+ }
+ src.setTop(src.bottom());
+ dst.setTop(dst.bottom());
+ dstRightsHaveBeenCached = true;
+ }
+ painter->setRenderHints(savedHints);
+}
+
+QAndroidStyle::AndroidGradientDrawable::AndroidGradientDrawable(const QVariantMap &drawable,
+ QAndroidStyle::ItemType itemType)
+ : AndroidDrawable(drawable, itemType), m_orientation(TOP_BOTTOM)
+{
+ m_radius = drawable.value(QLatin1String("radius")).toInt();
+ if (m_radius < 0)
+ m_radius = 0;
+
+ QVariantList colors = drawable.value(QLatin1String("colors")).toList();
+ QVariantList positions = drawable.value(QLatin1String("positions")).toList();
+ int min=colors.size() < positions.size() ? colors.size() : positions.size();
+ for (int i = 0; i < min; i++)
+ m_gradient.setColorAt(positions.at(i).toDouble(), (QRgb)colors.at(i).toInt());
+
+ QByteArray orientation=drawable.value(QLatin1String("orientation")).toByteArray();
+ if (orientation == "TOP_BOTTOM") // draw the gradient from the top to the bottom
+ m_orientation = TOP_BOTTOM;
+ else if (orientation == "TR_BL") // draw the gradient from the top-right to the bottom-left
+ m_orientation = TR_BL;
+ else if (orientation == "RIGHT_LEFT") // draw the gradient from the right to the left
+ m_orientation = RIGHT_LEFT;
+ else if (orientation == "BR_TL") // draw the gradient from the bottom-right to the top-left
+ m_orientation = BR_TL;
+ else if (orientation == "BOTTOM_TOP") // draw the gradient from the bottom to the top
+ m_orientation = BOTTOM_TOP;
+ else if (orientation == "BL_TR") // draw the gradient from the bottom-left to the top-right
+ m_orientation = BL_TR;
+ else if (orientation == "LEFT_RIGHT") // draw the gradient from the left to the right
+ m_orientation = LEFT_RIGHT;
+ else if (orientation == "TL_BR") // draw the gradient from the top-left to the bottom-right
+ m_orientation = TL_BR;
+ else
+ qWarning("AndroidGradientDrawable: unknown orientation");
+}
+
+QAndroidStyle::AndroidDrawableType QAndroidStyle::AndroidGradientDrawable::type() const
+{
+ return QAndroidStyle::Gradient;
+}
+
+void QAndroidStyle::AndroidGradientDrawable::draw(QPainter *painter, const QStyleOption *opt) const
+{
+ const int width = opt->rect.width();
+ const int height = opt->rect.height();
+ switch (m_orientation) {
+ case TOP_BOTTOM:
+ // draw the gradient from the top to the bottom
+ m_gradient.setStart(width/2,0);
+ m_gradient.setFinalStop(width/2,height);
+ break;
+ case TR_BL:
+ // draw the gradient from the top-right to the bottom-left
+ m_gradient.setStart(width,0);
+ m_gradient.setFinalStop(0,height);
+ break;
+ case RIGHT_LEFT:
+ // draw the gradient from the right to the left
+ m_gradient.setStart(width,height/2);
+ m_gradient.setFinalStop(0,height/2);
+ break;
+ case BR_TL:
+ // draw the gradient from the bottom-right to the top-left
+ m_gradient.setStart(width,height);
+ m_gradient.setFinalStop(0,0);
+ break;
+ case BOTTOM_TOP:
+ // draw the gradient from the bottom to the top
+ m_gradient.setStart(width/2,height);
+ m_gradient.setFinalStop(width/2,0);
+ break;
+ case BL_TR:
+ // draw the gradient from the bottom-left to the top-right
+ m_gradient.setStart(0,height);
+ m_gradient.setFinalStop(width,0);
+ break;
+ case LEFT_RIGHT:
+ // draw the gradient from the left to the right
+ m_gradient.setStart(0,height/2);
+ m_gradient.setFinalStop(width,height/2);
+ break;
+ case TL_BR:
+ // draw the gradient from the top-left to the bottom-right
+ m_gradient.setStart(0,0);
+ m_gradient.setFinalStop(width,height);
+ break;
+ }
+
+ const QBrush &oldBrush = painter->brush();
+ const QPen oldPen = painter->pen();
+ painter->setPen(Qt::NoPen);
+ painter->setBrush(m_gradient);
+ painter->drawRoundedRect(opt->rect, m_radius, m_radius);
+ painter->setBrush(oldBrush);
+ painter->setPen(oldPen);
+}
+
+QSize QAndroidStyle::AndroidGradientDrawable::size() const
+{
+ return QSize(m_radius*2, m_radius*2);
+}
+
+QAndroidStyle::AndroidClipDrawable::AndroidClipDrawable(const QVariantMap &drawable,
+ QAndroidStyle::ItemType itemType)
+ : AndroidDrawable(drawable, itemType)
+{
+ m_drawable = fromMap(drawable.value(QLatin1String("drawable")).toMap(), itemType);
+ m_factor = 0;
+ m_orientation = Qt::Horizontal;
+}
+
+QAndroidStyle::AndroidClipDrawable::~AndroidClipDrawable()
+{
+ delete m_drawable;
+}
+
+QAndroidStyle::AndroidDrawableType QAndroidStyle::AndroidClipDrawable::type() const
+{
+ return QAndroidStyle::Clip;
+}
+
+void QAndroidStyle::AndroidClipDrawable::setFactor(double factor, Qt::Orientation orientation)
+{
+ m_factor = factor;
+ m_orientation = orientation;
+}
+
+void QAndroidStyle::AndroidClipDrawable::draw(QPainter *painter, const QStyleOption *opt) const
+{
+ QStyleOption copy(*opt);
+ if (m_orientation == Qt::Horizontal)
+ copy.rect.setWidth(copy.rect.width()*m_factor);
+ else
+ copy.rect.setHeight(copy.rect.height()*m_factor);
+
+ m_drawable->draw(painter, &copy);
+}
+
+QAndroidStyle::AndroidStateDrawable::AndroidStateDrawable(const QVariantMap &drawable,
+ QAndroidStyle::ItemType itemType)
+ : AndroidDrawable(drawable, itemType)
+{
+ QVariantList states = drawable.value(QLatin1String("stateslist")).toList();
+ foreach (QVariant stateVariant, states) {
+ QVariantMap state = stateVariant.toMap();
+ const int s = extractState(state.value(QLatin1String("states")).toMap());
+ if (-1 == s)
+ continue;
+ const AndroidDrawable *ad = fromMap(state.value(QLatin1String("drawable")).toMap(), itemType);
+ if (!ad)
+ continue;
+ StateType item;
+ item.first = s;
+ item.second = ad;
+ m_states<<item;
+ }
+}
+
+QAndroidStyle::AndroidStateDrawable::~AndroidStateDrawable()
+{
+ foreach (const StateType type, m_states)
+ delete type.second;
+}
+
+QAndroidStyle::AndroidDrawableType QAndroidStyle::AndroidStateDrawable::type() const
+{
+ return QAndroidStyle::State;
+}
+
+void QAndroidStyle::AndroidStateDrawable::draw(QPainter *painter, const QStyleOption *opt) const
+{
+ const AndroidDrawable *drawable=bestAndroidStateMatch(opt);
+ if (drawable)
+ drawable->draw(painter, opt);
+}
+
+const QAndroidStyle::AndroidDrawable* QAndroidStyle::AndroidStateDrawable::bestAndroidStateMatch(const QStyleOption *opt) const
+{
+ const AndroidDrawable *bestMatch = 0;
+ if (!opt) {
+ if (m_states.size())
+ return m_states[0].second;
+ return bestMatch;
+ }
+
+ uint bestCost=0xffff;
+ foreach (const StateType & state, m_states) {
+ if (int(opt->state) == state.first)
+ return state.second;
+ uint cost = 0;
+
+ int difference = int(opt->state^state.first);
+
+ if (difference & QStyle::State_Active)
+ cost += 1000;
+
+ if (difference & QStyle::State_Enabled)
+ cost += 1000;
+
+ if ((m_itemType == QC_Button || m_itemType == QC_EditText) && (difference & QStyle::State_Raised))
+ cost += 1000;
+
+ if ((m_itemType == QC_Button || m_itemType == QC_EditText) && (difference & QStyle::State_Sunken))
+ cost += 1000;
+
+ if (difference & QStyle::State_Off)
+ cost += 1000;
+
+ if (difference & QStyle::State_On)
+ cost += 1000;
+
+ if (difference & QStyle::State_HasFocus)
+ cost += 1000;
+
+ if (difference & QStyle::State_Selected)
+ cost += 1000;
+
+ if (cost < bestCost) {
+ bestCost = cost;
+ bestMatch = state.second;
+ }
+ }
+ return bestMatch;
+}
+
+int QAndroidStyle::AndroidStateDrawable::extractState(const QVariantMap &value)
+{
+ int state = QStyle::State_None;
+ foreach (const QString key, value.keys()) {
+ bool val = value.value(key).toString() == QLatin1String("true");
+ if (key == QLatin1String("enabled") && val) {
+ state |= QStyle::State_Enabled;
+ continue;
+ }
+
+ if (key == QLatin1String("window_focused") && val) {
+ state |= QStyle::State_Active;
+ continue;
+ }
+
+ if (key == QLatin1String("focused") && val) {
+ state |= QStyle::State_HasFocus;
+ continue;
+ }
+
+ if (key == QLatin1String("checked")) {
+ state |= val ? QStyle::State_On : QStyle::State_Off;
+ continue;
+ }
+
+ if (key == QLatin1String("pressed")) {
+ state |= val ? QStyle::State_Raised : QStyle::State_Sunken;
+ state |= QStyle::State_Enabled | QStyle::State_HasFocus;
+ continue;
+ }
+
+ if (key == QLatin1String("selected") && val) {
+ state |= QStyle::State_Selected;
+ state |= QStyle::State_Enabled | QStyle::State_HasFocus;
+ continue;
+ }
+
+ if (key == QLatin1String("active") && val) {
+ state |= QStyle::State_Active;
+ continue;
+ }
+
+ // Keep misspelling for compatibility
+ if (key == QLatin1String("backgroud") && val)
+ return -1;
+ }
+ return state;
+}
+
+QAndroidStyle::AndroidLayerDrawable::AndroidLayerDrawable(const QVariantMap &drawable,
+ QAndroidStyle::ItemType itemType)
+ : AndroidDrawable(drawable, itemType)
+{
+ QVariantList layers = drawable.value(QLatin1String("layers")).toList();
+ foreach (QVariant layer, layers) {
+ QVariantMap layerMap = layer.toMap();
+ AndroidDrawable *ad = fromMap(layerMap, itemType);
+ if (ad) {
+ LayerType l;
+ l.second = ad;
+ l.first = layerMap.value(QLatin1String("id")).toInt();
+ m_layers << l;
+ }
+ }
+}
+
+QAndroidStyle::AndroidLayerDrawable::~AndroidLayerDrawable()
+{
+ foreach (const LayerType &layer, m_layers)
+ delete layer.second;
+}
+
+QAndroidStyle::AndroidDrawableType QAndroidStyle::AndroidLayerDrawable::type() const
+{
+ return QAndroidStyle::Layer;
+}
+
+void QAndroidStyle::AndroidLayerDrawable::draw(QPainter *painter, const QStyleOption *opt) const
+{
+ foreach (const LayerType &layer, m_layers)
+ layer.second->draw(painter, opt);
+}
+
+QAndroidStyle::AndroidDrawable *QAndroidStyle::AndroidLayerDrawable::layer(int id) const
+{
+ foreach (const LayerType &layer, m_layers)
+ if (layer.first == id)
+ return layer.second;
+ return 0;
+}
+
+QSize QAndroidStyle::AndroidLayerDrawable::size() const
+{
+ QSize sz;
+ foreach (const LayerType &layer, m_layers)
+ sz = sz.expandedTo(layer.second->size());
+ return sz;
+}
+
+QAndroidStyle::AndroidControl::AndroidControl(const QVariantMap &control,
+ QAndroidStyle::ItemType itemType)
+{
+ QVariantMap::const_iterator it = control.find(QLatin1String("View_background"));
+ if (it != control.end())
+ m_background = AndroidDrawable::fromMap(it.value().toMap(), itemType);
+ else
+ m_background = 0;
+
+ it = control.find(QLatin1String("View_minWidth"));
+ if (it!=control.end())
+ m_minSize.setWidth(it.value().toInt());
+
+ it = control.find(QLatin1String("View_minHeight"));
+ if (it != control.end())
+ m_minSize.setHeight(it.value().toInt());
+
+ it = control.find(QLatin1String("View_maxWidth"));
+ if (it != control.end())
+ m_maxSize.setWidth(it.value().toInt());
+
+ it = control.find(QLatin1String("View_maxHeight"));
+ if (it != control.end())
+ m_maxSize.setHeight(it.value().toInt());
+}
+
+QAndroidStyle::AndroidControl::~AndroidControl()
+{
+ delete m_background;
+}
+
+void QAndroidStyle::AndroidControl::drawControl(const QStyleOption *opt, QPainter *p, const QWidget * /* w */)
+{
+ if (m_background)
+ m_background->draw(p, opt);
+}
+
+QRect QAndroidStyle::AndroidControl::subElementRect(QStyle::SubElement /* subElement */,
+ const QStyleOption *option,
+ const QWidget * /* widget */) const
+{
+ if (const AndroidDrawable *drawable=m_background) {
+ if (drawable->type() == State)
+ drawable = static_cast<const AndroidStateDrawable *>(m_background)->bestAndroidStateMatch(option);
+
+ const QMargins &padding = drawable->padding();
+
+ QRect r = option->rect.adjusted(padding.left(), padding.top(),
+ -padding.right(), -padding.bottom());
+
+ if (r.width() < m_minSize.width())
+ r.setWidth(m_minSize.width());
+
+ if (r.height() < m_minSize.height())
+ r.setHeight(m_minSize.height());
+
+ return visualRect(option->direction, option->rect, r);
+ }
+ return option->rect;
+
+}
+
+QRect QAndroidStyle::AndroidControl::subControlRect(const QStyleOptionComplex *option,
+ QStyle::SubControl /*sc*/,
+ const QWidget *widget) const
+{
+ return subElementRect(QStyle::SE_CustomBase, option, widget);
+}
+
+QSize QAndroidStyle::AndroidControl::sizeFromContents(const QStyleOption *opt,
+ const QSize &contentsSize,
+ const QWidget * /* w */) const
+{
+ QSize sz;
+ if (const AndroidDrawable *drawable=m_background) {
+
+ if (drawable->type() == State)
+ drawable = static_cast<const AndroidStateDrawable*>(m_background)->bestAndroidStateMatch(opt);
+ const QMargins &padding = drawable->padding();
+ sz.setWidth(padding.left() + padding.right());
+ sz.setHeight(padding.top() + padding.bottom());
+ if (sz.isEmpty())
+ sz = drawable->size();
+ }
+ sz += contentsSize;
+ if (contentsSize.height() < opt->fontMetrics.height())
+ sz.setHeight(sz.height() + (opt->fontMetrics.height() - contentsSize.height()));
+ if (sz.height() < m_minSize.height())
+ sz.setHeight(m_minSize.height());
+ if (sz.width() < m_minSize.width())
+ sz.setWidth(m_minSize.width());
+ return sz;
+}
+
+QMargins QAndroidStyle::AndroidControl::padding()
+{
+ if (const AndroidDrawable *drawable = m_background)
+ {
+ if (drawable->type() == State)
+ drawable=static_cast<const AndroidStateDrawable *>(m_background)->bestAndroidStateMatch(0);
+ return drawable->padding();
+ }
+ return QMargins();
+}
+
+QAndroidStyle::AndroidCompoundButtonControl::AndroidCompoundButtonControl(const QVariantMap &control,
+ ItemType itemType)
+ : AndroidControl(control, itemType)
+{
+ QVariantMap::const_iterator it = control.find(QLatin1String("CompoundButton_button"));
+ if (it != control.end())
+ m_button = AndroidDrawable::fromMap(it.value().toMap(), itemType);
+ else
+ m_button = 0;
+}
+
+QAndroidStyle::AndroidCompoundButtonControl::~AndroidCompoundButtonControl()
+{
+ delete m_button;
+}
+
+void QAndroidStyle::AndroidCompoundButtonControl::drawControl(const QStyleOption *opt,
+ QPainter *p,
+ const QWidget *w)
+{
+ AndroidControl::drawControl(opt, p, w);
+ if (m_button)
+ m_button->draw(p, opt);
+}
+
+QAndroidStyle::AndroidProgressBarControl::AndroidProgressBarControl(const QVariantMap &control,
+ ItemType itemType)
+ : AndroidControl(control, itemType)
+{
+ QVariantMap::const_iterator it = control.find(QLatin1String("ProgressBar_indeterminateDrawable"));
+ if (it != control.end())
+ m_indeterminateDrawable = AndroidDrawable::fromMap(it.value().toMap(), itemType);
+ else
+ m_indeterminateDrawable = 0;
+
+ it = control.find(QLatin1String("ProgressBar_progressDrawable"));
+ if (it != control.end())
+ m_progressDrawable = AndroidDrawable::fromMap(it.value().toMap(), itemType);
+ else
+ m_progressDrawable = 0;
+
+ it = control.find(QLatin1String("ProgressBar_progress_id"));
+ if (it != control.end())
+ m_progressId = it.value().toInt();
+
+ it = control.find(QLatin1String("ProgressBar_secondaryProgress_id"));
+ if (it != control.end())
+ m_secondaryProgress_id = it.value().toInt();
+
+ it = control.find(QLatin1String("ProgressBar_minWidth"));
+ if (it != control.end())
+ m_minSize.setWidth(it.value().toInt());
+
+ it = control.find(QLatin1String("ProgressBar_minHeight"));
+ if (it != control.end())
+ m_minSize.setHeight(it.value().toInt());
+
+ it = control.find(QLatin1String("ProgressBar_maxWidth"));
+ if (it != control.end())
+ m_maxSize.setWidth(it.value().toInt());
+
+ it = control.find(QLatin1String("ProgressBar_maxHeight"));
+ if (it != control.end())
+ m_maxSize.setHeight(it.value().toInt());
+}
+
+QAndroidStyle::AndroidProgressBarControl::~AndroidProgressBarControl()
+{
+ delete m_progressDrawable;
+ delete m_indeterminateDrawable;
+}
+
+void QAndroidStyle::AndroidProgressBarControl::drawControl(const QStyleOption *option, QPainter *p, const QWidget * /* w */)
+{
+ if (!m_progressDrawable)
+ return;
+
+ if (const QStyleOptionProgressBar *progressBarOption =
+ qstyleoption_cast<const QStyleOptionProgressBar *>(option)) {
+ QStyleOptionProgressBarV2 progressBarV2(*progressBarOption);
+ if (m_progressDrawable->type() == QAndroidStyle::Layer) {
+ QAndroidStyle::AndroidDrawable *clipDrawable = static_cast<QAndroidStyle::AndroidLayerDrawable *>(m_progressDrawable)->layer(m_progressId);
+ if (clipDrawable->type() == QAndroidStyle::Clip)
+ static_cast<QAndroidStyle::AndroidClipDrawable *>(clipDrawable)->setFactor(double(progressBarV2.progress/(progressBarV2.maximum-progressBarV2.minimum)),
+ progressBarV2.orientation);
+ }
+ m_progressDrawable->draw(p, option);
+ }
+}
+
+QRect QAndroidStyle::AndroidProgressBarControl::subElementRect(QStyle::SubElement subElement,
+ const QStyleOption *option,
+ const QWidget *widget) const
+{
+ if (const QStyleOptionProgressBar *progressBarOption =
+ qstyleoption_cast<const QStyleOptionProgressBar *>(option)) {
+ QStyleOptionProgressBarV2 progressBarV2(*progressBarOption);
+ const bool horizontal = progressBarV2.orientation == Qt::Vertical;
+ if (!m_background)
+ return option->rect;
+
+ QMargins padding = m_background->padding();
+ QRect p(padding.left(), padding.top(), padding.right()-padding.left(), padding.bottom()-padding.top());
+ padding = m_indeterminateDrawable->padding();
+ p |= QRect(padding.left(), padding.top(), padding.right()-padding.left(), padding.bottom()-padding.top());
+ padding = m_progressDrawable->padding();
+ p |= QRect(padding.left(), padding.top(), padding.right()-padding.left(), padding.bottom()-padding.top());
+
+ QRect r = option->rect.adjusted(p.left(), p.top(), -p.right(), -p.bottom());
+
+ if (horizontal) {
+ if (r.height()<m_minSize.height())
+ r.setHeight(m_minSize.height());
+
+ if (r.height()>m_maxSize.height())
+ r.setHeight(m_maxSize.height());
+ } else {
+ if (r.width()<m_minSize.width())
+ r.setWidth(m_minSize.width());
+
+ if (r.width()>m_maxSize.width())
+ r.setWidth(m_maxSize.width());
+ }
+ return visualRect(option->direction, option->rect, r);
+ }
+ return AndroidControl::subElementRect(subElement, option, widget);
+}
+
+QSize QAndroidStyle::AndroidProgressBarControl::sizeFromContents(const QStyleOption *opt,
+ const QSize &contentsSize,
+ const QWidget * /* w */) const
+{
+ QSize sz(contentsSize);
+ if (sz.height() < m_minSize.height())
+ sz.setHeight(m_minSize.height());
+ if (sz.width() < m_minSize.width())
+ sz.setWidth(m_minSize.width());
+
+ if (const QStyleOptionProgressBar *progressBarOption =
+ qstyleoption_cast<const QStyleOptionProgressBar *>(opt)) {
+ QStyleOptionProgressBarV2 progressBarV2(*progressBarOption);
+ if (progressBarV2.orientation == Qt::Vertical) {
+ if (sz.height() > m_maxSize.height())
+ sz.setHeight(m_maxSize.height());
+ } else {
+ if (sz.width() > m_maxSize.width())
+ sz.setWidth(m_maxSize.width());
+ }
+ }
+ return contentsSize;
+}
+
+QAndroidStyle::AndroidSeekBarControl::AndroidSeekBarControl(const QVariantMap &control,
+ ItemType itemType)
+ : AndroidProgressBarControl(control, itemType)
+{
+ QVariantMap::const_iterator it = control.find(QLatin1String("SeekBar_thumb"));
+ if (it != control.end())
+ m_seekBarThumb = AndroidDrawable::fromMap(it.value().toMap(), itemType);
+ else
+ m_seekBarThumb = 0;
+}
+
+QAndroidStyle::AndroidSeekBarControl::~AndroidSeekBarControl()
+{
+ delete m_seekBarThumb;
+}
+
+void QAndroidStyle::AndroidSeekBarControl::drawControl(const QStyleOption *option,
+ QPainter *p,
+ const QWidget * /* w */)
+{
+ if (!m_seekBarThumb || !m_progressDrawable)
+ return;
+
+ if (const QStyleOptionSlider *styleOption =
+ qstyleoption_cast<const QStyleOptionSlider *>(option)) {
+ double factor = double(styleOption->sliderPosition/(styleOption->maximum-styleOption->minimum));
+ if (m_progressDrawable->type()==QAndroidStyle::Layer) {
+ QAndroidStyle::AndroidDrawable *clipDrawable = static_cast<QAndroidStyle::AndroidLayerDrawable *>(m_progressDrawable)->layer(m_progressId);
+ if (clipDrawable->type() == QAndroidStyle::Clip)
+ static_cast<QAndroidStyle::AndroidClipDrawable *>(clipDrawable)->setFactor(factor, styleOption->orientation);
+ }
+ const AndroidDrawable *drawable=m_seekBarThumb;
+ if (drawable->type() == State)
+ drawable = static_cast<const QAndroidStyle::AndroidStateDrawable *>(m_seekBarThumb)->bestAndroidStateMatch(option);
+ QStyleOption copy(*option);
+ copy.rect.setY((copy.rect.height()-m_minSize.height())/2);
+ copy.rect.setHeight(m_minSize.height());
+ copy.rect.setWidth(copy.rect.width()-drawable->size().width());
+ copy.rect.translate(drawable->size().width()/2,0);
+ m_progressDrawable->draw(p, &copy);
+ if (styleOption->orientation == Qt::Vertical)
+ qCritical() << "Vertical slider are not supported";
+ int pos = (double(copy.rect.width()*factor - drawable->size().width()) / 2);
+ copy.rect.translate(pos, 0);
+ copy.rect.setSize(drawable->size());
+ m_seekBarThumb->draw(p, &copy);
+ }
+}
+
+QSize QAndroidStyle::AndroidSeekBarControl::sizeFromContents(const QStyleOption *opt,
+ const QSize &contentsSize,
+ const QWidget *w) const
+{
+ QSize sz = AndroidProgressBarControl::sizeFromContents(opt, contentsSize, w);
+ if (!m_seekBarThumb)
+ return sz;
+ const AndroidDrawable *drawable=m_seekBarThumb;
+ if (drawable->type() == State)
+ drawable = static_cast<const QAndroidStyle::AndroidStateDrawable *>(m_seekBarThumb)->bestAndroidStateMatch(opt);
+ return sz.expandedTo(drawable->size());
+}
+
+QRect QAndroidStyle::AndroidSeekBarControl::subControlRect(const QStyleOptionComplex *option,
+ SubControl sc,
+ const QWidget * /* widget */) const
+{
+ const QStyleOptionSlider *styleOption =
+ qstyleoption_cast<const QStyleOptionSlider *>(option);
+
+ if (m_seekBarThumb && sc == SC_SliderHandle && styleOption) {
+ const AndroidDrawable *drawable = m_seekBarThumb;
+ if (drawable->type() == State)
+ drawable = static_cast<const QAndroidStyle::AndroidStateDrawable *>(m_seekBarThumb)->bestAndroidStateMatch(option);
+
+ QRect r(option->rect);
+ double factor = double(styleOption->sliderPosition/(styleOption->maximum-styleOption->minimum));
+ int pos=(double(option->rect.width()*factor - drawable->size().width()) / 2);
+ r.setX(r.x()+pos);
+ r.setSize(drawable->size());
+ return r;
+ }
+ return option->rect;
+}
+
+QAndroidStyle::AndroidSpinnerControl::AndroidSpinnerControl(const QVariantMap &control,
+ QAndroidStyle::ItemType itemType)
+ : AndroidControl(control, itemType)
+{}
+
+QRect QAndroidStyle::AndroidSpinnerControl::subControlRect(const QStyleOptionComplex *option,
+ SubControl sc,
+ const QWidget *widget) const
+{
+ if (sc == QStyle::SC_ComboBoxListBoxPopup)
+ return option->rect;
+ return AndroidControl::subControlRect(option, sc, widget);
+}
+
+QT_END_NAMESPACE
+
+#endif // !defined(QT_NO_STYLE_ANDROID) || defined(QT_PLUGIN)
diff --git a/src/widgets/styles/qandroidstyle_p.h b/src/widgets/styles/qandroidstyle_p.h
new file mode 100644
index 0000000000..2d9abd65c5
--- /dev/null
+++ b/src/widgets/styles/qandroidstyle_p.h
@@ -0,0 +1,382 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtWidgets module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef QANDROIDSTYLE_P_H
+#define QANDROIDSTYLE_P_H
+
+//
+// W A R N I N G
+// -------------
+//
+// This file is not part of the Qt API. It exists for the convenience
+// of qstylefactory.cpp. This header may change from version to version
+// without notice, or even be removed.
+//
+// We mean it.
+//
+
+#include <QtCore/QList>
+#include <QtCore/QMargins>
+#include <QtWidgets/QCommonStyle>
+#include <QtCore/QHash>
+#include <QtCore/QVariantMap>
+
+QT_BEGIN_NAMESPACE
+
+#if !defined(QT_NO_STYLE_ANDROID)
+
+class Q_WIDGETS_EXPORT QAndroidStyle : public QCommonStyle
+{
+ Q_OBJECT
+
+public:
+ enum ItemType
+ {
+ QC_UnknownType = -1,
+ QC_View,
+ QC_GroupBox,
+ QC_Button,
+ QC_Checkbox,
+ QC_RadioButton,
+ QC_Slider,
+ QC_Switch,
+ QC_EditText,
+ QC_Combobox,
+ QC_BusyIndicator,
+ QC_ProgressBar,
+ QC_Tab,
+ QC_TabButton,
+ QC_RatingIndicator,
+ QC_SearchBox,
+ QC_CustomCOntrol=0xf00,
+ QC_ControlMask=0xfff
+ };
+
+ struct Android9PatchChunk
+ {
+ QVector<int> xDivs;
+ QVector<int> yDivs;
+ QVector<int> colors;
+ };
+
+ struct AndroidItemStateInfo
+ {
+ AndroidItemStateInfo():state(0){}
+ int state;
+ QByteArray filePath;
+ QByteArray hashKey;
+ Android9PatchChunk chunkData;
+ QSize size;
+ QMargins padding;
+ };
+
+ enum AndroidDrawableType
+ {
+ Color,
+ Image,
+ Clip,
+ NinePatch,
+ Gradient,
+ State,
+ Layer
+ };
+
+ class AndroidDrawable
+ {
+ public:
+ AndroidDrawable(const QVariantMap &drawable, ItemType itemType);
+ virtual ~AndroidDrawable();
+ virtual void initPadding(const QVariantMap &drawable);
+ virtual AndroidDrawableType type() const = 0;
+ virtual void draw(QPainter *painter,const QStyleOption *opt) const = 0;
+ const QMargins &padding() const;
+ virtual QSize size() const;
+ static AndroidDrawable *fromMap(const QVariantMap &drawable, ItemType itemType);
+ static QMargins extractMargins(const QVariantMap &value);
+ protected:
+ ItemType m_itemType;
+ QMargins m_padding;
+ };
+
+ class AndroidColorDrawable: public AndroidDrawable
+ {
+ public:
+ AndroidColorDrawable(const QVariantMap &drawable, ItemType itemType);
+ virtual AndroidDrawableType type() const;
+ virtual void draw(QPainter *painter,const QStyleOption *opt) const;
+
+ protected:
+ QColor m_color;
+ };
+
+ class AndroidImageDrawable: public AndroidDrawable
+ {
+ public:
+ AndroidImageDrawable(const QVariantMap &drawable, ItemType itemType);
+ virtual AndroidDrawableType type() const;
+ virtual void draw(QPainter *painter,const QStyleOption *opt) const;
+ virtual QSize size() const;
+
+ protected:
+ QString m_filePath;
+ mutable QString m_hashKey;
+ QSize m_size;
+ };
+
+ class Android9PatchDrawable: public AndroidImageDrawable
+ {
+ public:
+ Android9PatchDrawable(const QVariantMap &drawable, ItemType itemType);
+ virtual AndroidDrawableType type() const;
+ virtual void draw(QPainter *painter, const QStyleOption *opt) const;
+ private:
+ static int calculateStretch(int boundsLimit, int startingPoint,
+ int srcSpace, int numStrechyPixelsRemaining,
+ int numFixedPixelsRemaining);
+ void extractIntArray(const QVariantList &values, QVector<int> &array);
+ private:
+ Android9PatchChunk m_chunkData;
+ };
+
+ class AndroidGradientDrawable: public AndroidDrawable
+ {
+ public:
+ enum GradientOrientation
+ {
+ TOP_BOTTOM,
+ TR_BL,
+ RIGHT_LEFT,
+ BR_TL,
+ BOTTOM_TOP,
+ BL_TR,
+ LEFT_RIGHT,
+ TL_BR
+ };
+
+ public:
+ AndroidGradientDrawable(const QVariantMap &drawable, ItemType itemType);
+ virtual AndroidDrawableType type() const;
+ virtual void draw(QPainter *painter, const QStyleOption *opt) const;
+ QSize size() const;
+ private:
+ mutable QLinearGradient m_gradient;
+ GradientOrientation m_orientation;
+ int m_radius;
+ };
+
+ class AndroidClipDrawable: public AndroidDrawable
+ {
+ public:
+ AndroidClipDrawable(const QVariantMap &drawable, ItemType itemType);
+ ~AndroidClipDrawable();
+ virtual AndroidDrawableType type() const;
+ virtual void setFactor(double factor, Qt::Orientation orientation);
+ virtual void draw(QPainter *painter, const QStyleOption *opt) const;
+
+ private:
+ double m_factor;
+ Qt::Orientation m_orientation;
+ const AndroidDrawable *m_drawable;
+ };
+
+ class AndroidStateDrawable: public AndroidDrawable
+ {
+ public:
+ AndroidStateDrawable(const QVariantMap &drawable, ItemType itemType);
+ ~AndroidStateDrawable();
+ virtual AndroidDrawableType type() const;
+ virtual void draw(QPainter *painter, const QStyleOption *opt) const;
+ inline const AndroidDrawable *bestAndroidStateMatch(const QStyleOption *opt) const;
+ static int extractState(const QVariantMap &value);
+
+ private:
+ typedef QPair<int, const AndroidDrawable *> StateType;
+ QList<StateType> m_states;
+ };
+
+ class AndroidLayerDrawable: public AndroidDrawable
+ {
+ public:
+ AndroidLayerDrawable(const QVariantMap &drawable, QAndroidStyle::ItemType itemType);
+ ~AndroidLayerDrawable();
+ virtual AndroidDrawableType type() const;
+ virtual void draw(QPainter *painter, const QStyleOption *opt) const;
+ AndroidDrawable *layer(int id) const;
+ QSize size() const;
+ private:
+ typedef QPair<int, AndroidDrawable *> LayerType;
+ QList<LayerType> m_layers;
+ };
+
+ class AndroidControl
+ {
+ public:
+ AndroidControl(const QVariantMap &control, ItemType itemType);
+ virtual ~AndroidControl();
+ virtual void drawControl(const QStyleOption *opt, QPainter *p, const QWidget *w);
+ virtual QRect subElementRect(SubElement subElement,
+ const QStyleOption *option,
+ const QWidget *widget = 0) const;
+ virtual QRect subControlRect(const QStyleOptionComplex *option,
+ SubControl sc,
+ const QWidget *widget = 0) const;
+ virtual QSize sizeFromContents(const QStyleOption *opt,
+ const QSize &contentsSize,
+ const QWidget *w) const;
+ virtual QMargins padding();
+ protected:
+ const AndroidDrawable *m_background;
+ QSize m_minSize;
+ QSize m_maxSize;
+ };
+
+ class AndroidCompoundButtonControl : public AndroidControl
+ {
+ public:
+ AndroidCompoundButtonControl(const QVariantMap &control, ItemType itemType);
+ virtual ~AndroidCompoundButtonControl();
+ virtual void drawControl(const QStyleOption *opt, QPainter *p, const QWidget *w);
+
+ protected:
+ const AndroidDrawable *m_button;
+ };
+
+ class AndroidProgressBarControl : public AndroidControl
+ {
+ public:
+ AndroidProgressBarControl(const QVariantMap &control, ItemType itemType);
+ virtual ~AndroidProgressBarControl();
+ virtual void drawControl(const QStyleOption *option, QPainter *p, const QWidget *w);
+ virtual QRect subElementRect(SubElement subElement,
+ const QStyleOption *option,
+ const QWidget *widget = 0) const;
+
+ QSize sizeFromContents(const QStyleOption *opt,
+ const QSize &contentsSize,
+ const QWidget *w) const;
+ protected:
+ AndroidDrawable *m_progressDrawable;
+ AndroidDrawable *m_indeterminateDrawable;
+ int m_secondaryProgress_id;
+ int m_progressId;
+ };
+
+ class AndroidSeekBarControl : public AndroidProgressBarControl
+ {
+ public:
+ AndroidSeekBarControl(const QVariantMap &control, ItemType itemType);
+ virtual ~AndroidSeekBarControl();
+ virtual void drawControl(const QStyleOption *option, QPainter *p, const QWidget *w);
+ QSize sizeFromContents(const QStyleOption *opt,
+ const QSize &contentsSize, const QWidget *w) const;
+ QRect subControlRect(const QStyleOptionComplex *option, SubControl sc,
+ const QWidget *widget = 0) const;
+ private:
+ AndroidDrawable *m_seekBarThumb;
+ };
+
+ class AndroidSpinnerControl : public AndroidControl
+ {
+ public:
+ AndroidSpinnerControl(const QVariantMap &control, ItemType itemType);
+ virtual ~AndroidSpinnerControl(){}
+ virtual QRect subControlRect(const QStyleOptionComplex *option,
+ SubControl sc,
+ const QWidget *widget = 0) const;
+ };
+
+ typedef QList<AndroidItemStateInfo *> AndroidItemStateInfoList;
+
+public:
+ QAndroidStyle();
+ ~QAndroidStyle();
+
+ virtual void drawPrimitive(PrimitiveElement pe, const QStyleOption *opt, QPainter *p,
+ const QWidget *w = 0) const;
+
+ virtual void drawControl(QStyle::ControlElement element, const QStyleOption *opt, QPainter *p,
+ const QWidget *w = 0) const;
+
+ virtual QRect subElementRect(SubElement subElement, const QStyleOption *option,
+ const QWidget *widget = 0) const;
+ virtual void drawComplexControl(ComplexControl cc, const QStyleOptionComplex *opt, QPainter *p,
+ const QWidget *widget = 0) const;
+ virtual SubControl hitTestComplexControl(ComplexControl cc, const QStyleOptionComplex *opt,
+ const QPoint &pt, const QWidget *widget = 0) const;
+ virtual QRect subControlRect(ComplexControl cc, const QStyleOptionComplex *opt,
+ SubControl sc, const QWidget *widget = 0) const;
+
+ virtual int pixelMetric(PixelMetric metric, const QStyleOption *option = 0,
+ const QWidget *widget = 0) const;
+
+ virtual QSize sizeFromContents(ContentsType ct, const QStyleOption *opt,
+ const QSize &contentsSize, const QWidget *w = 0) const;
+
+ virtual QPixmap standardPixmap(StandardPixmap standardPixmap, const QStyleOption *opt = 0,
+ const QWidget *widget = 0) const;
+
+ virtual QPixmap generatedIconPixmap(QIcon::Mode iconMode, const QPixmap &pixmap,
+ const QStyleOption *opt) const;
+
+ virtual QPalette standardPalette() const;
+private:
+ Q_DISABLE_COPY(QAndroidStyle)
+ static ItemType qtControl(QStyle::ComplexControl control);
+ static ItemType qtControl(QStyle::ContentsType contentsType);
+ static ItemType qtControl(QStyle::ControlElement controlElement);
+ static ItemType qtControl(QStyle::PrimitiveElement primitiveElement);
+ static ItemType qtControl(QStyle::SubElement subElement);
+ static ItemType qtControl(const QString &android);
+
+ static void setPaletteColor(const QVariantMap &object,
+ QPalette &palette,
+ QPalette::ColorRole role);
+private:
+ typedef QHash<int, AndroidControl *> AndroidControlsHash;
+ AndroidControlsHash m_androidControlsHash;
+ QPalette m_standardPalette;
+};
+
+#endif // QT_NO_STYLE_ANDROID
+
+QT_END_NAMESPACE
+
+#endif // QANDROIDSTYLE_P_H
diff --git a/src/widgets/styles/qcommonstyle.cpp b/src/widgets/styles/qcommonstyle.cpp
index d1d80f5af0..f7ae667a82 100644
--- a/src/widgets/styles/qcommonstyle.cpp
+++ b/src/widgets/styles/qcommonstyle.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -1115,6 +1115,8 @@ void QCommonStylePrivate::tabLayout(const QStyleOptionTabV3 *opt, const QWidget
QSize tabIconSize = opt->icon.actualSize(iconSize,
(opt->state & QStyle::State_Enabled) ? QIcon::Normal : QIcon::Disabled,
(opt->state & QStyle::State_Selected) ? QIcon::On : QIcon::Off );
+ // High-dpi icons do not need adjustmet; make sure tabIconSize is not larger than iconSize
+ tabIconSize = QSize(qMin(tabIconSize.width(), iconSize.width()), qMin(tabIconSize.height(), iconSize.width()));
*iconRect = QRect(tr.left(), tr.center().y() - tabIconSize.height() / 2,
tabIconSize.width(), tabIconSize .height());
@@ -1236,8 +1238,11 @@ void QCommonStyle::drawControl(ControlElement element, const QStyleOption *opt,
state = QIcon::On;
QPixmap pixmap = button->icon.pixmap(button->iconSize, mode, state);
- int labelWidth = pixmap.width();
- int labelHeight = pixmap.height();
+
+ int pixmapWidth = pixmap.width() / pixmap.devicePixelRatio();
+ int pixmapHeight = pixmap.height() / pixmap.devicePixelRatio();
+ int labelWidth = pixmapWidth;
+ int labelHeight = pixmapHeight;
int iconSpacing = 4;//### 4 is currently hardcoded in QPushButton::sizeHint()
int textWidth = button->fontMetrics.boundingRect(opt->rect, tf, button->text).width();
if (!button->text.isEmpty())
@@ -1245,7 +1250,7 @@ void QCommonStyle::drawControl(ControlElement element, const QStyleOption *opt,
iconRect = QRect(textRect.x() + (textRect.width() - labelWidth) / 2,
textRect.y() + (textRect.height() - labelHeight) / 2,
- pixmap.width(), pixmap.height());
+ pixmapWidth, pixmapHeight);
iconRect = visualRect(button->direction, textRect, iconRect);
@@ -1517,9 +1522,9 @@ void QCommonStyle::drawControl(ControlElement element, const QStyleOption *opt,
if (!header->icon.isNull()) {
QPixmap pixmap
= header->icon.pixmap(proxy()->pixelMetric(PM_SmallIconSize), (header->state & State_Enabled) ? QIcon::Normal : QIcon::Disabled);
- int pixw = pixmap.width();
+ int pixw = pixmap.width() / pixmap.devicePixelRatio();
- QRect aligned = alignedRect(header->direction, QFlag(header->iconAlignment), pixmap.size(), rect);
+ QRect aligned = alignedRect(header->direction, QFlag(header->iconAlignment), pixmap.size() / pixmap.devicePixelRatio(), rect);
QRect inter = aligned.intersected(rect);
p->drawPixmap(inter.x(), inter.y(), pixmap, inter.x() - aligned.x(), inter.y() - aligned.y(), inter.width(), inter.height());
@@ -1574,7 +1579,7 @@ void QCommonStyle::drawControl(ControlElement element, const QStyleOption *opt,
mode = QIcon::Normal;
pm = toolbutton->icon.pixmap(toolbutton->rect.size().boundedTo(toolbutton->iconSize),
mode, state);
- pmSize = pm.size();
+ pmSize = pm.size() / pm.devicePixelRatio();
}
if (toolbutton->toolButtonStyle != Qt::ToolButtonIconOnly) {
@@ -1800,8 +1805,8 @@ void QCommonStyle::drawControl(ControlElement element, const QStyleOption *opt,
tr = cr;
tr.adjust(4, 0, -8, 0);
} else {
- int iw = pm.width() + 4;
- ih = pm.height();
+ int iw = pm.width() / pm.devicePixelRatio() + 4;
+ ih = pm.height()/ pm.devicePixelRatio();
ir = QRect(cr.left() + 4, cr.top(), iw + 2, ih);
tr = QRect(ir.right(), cr.top(), cr.width() - ir.right() - 4, cr.height());
}
@@ -2138,9 +2143,9 @@ void QCommonStyle::drawControl(ControlElement element, const QStyleOption *opt,
p->save();
p->setClipRect(opt->rect);
- QRect checkRect = subElementRect(SE_ItemViewItemCheckIndicator, vopt, widget);
- QRect iconRect = subElementRect(SE_ItemViewItemDecoration, vopt, widget);
- QRect textRect = subElementRect(SE_ItemViewItemText, vopt, widget);
+ QRect checkRect = proxy()->subElementRect(SE_ItemViewItemCheckIndicator, vopt, widget);
+ QRect iconRect = proxy()->subElementRect(SE_ItemViewItemDecoration, vopt, widget);
+ QRect textRect = proxy()->subElementRect(SE_ItemViewItemText, vopt, widget);
// draw the background
proxy()->drawPrimitive(PE_PanelItemViewItem, opt, p, widget);
@@ -2265,11 +2270,11 @@ void QCommonStyle::drawControl(ControlElement element, const QStyleOption *opt,
case QFrame::VLine: {
QPoint p1, p2;
if (frameShape == QFrame::HLine) {
- p1 = QPoint(opt->rect.x(), opt->rect.height() / 2);
+ p1 = QPoint(opt->rect.x(), opt->rect.y() + opt->rect.height() / 2);
p2 = QPoint(opt->rect.x() + opt->rect.width(), p1.y());
} else {
- p1 = QPoint(opt->rect.x()+opt->rect.width() / 2, 0);
- p2 = QPoint(p1.x(), opt->rect.height());
+ p1 = QPoint(opt->rect.x() + opt->rect.width() / 2, opt->rect.y());
+ p2 = QPoint(p1.x(), p1.y() + opt->rect.height());
}
if (frameShadow == QFrame::Plain) {
QPen oldPen = p->pen();
@@ -3003,7 +3008,7 @@ QRect QCommonStyle::subElementRect(SubElement sr, const QStyleOption *opt,
case SE_ToolBarHandle:
if (const QStyleOptionToolBar *tbopt = qstyleoption_cast<const QStyleOptionToolBar *>(opt)) {
if (tbopt->features & QStyleOptionToolBar::Movable) {
- ///we need to access the widget here because the style option doesn't
+ ///we need to access the widget here because the style option doesn't
//have all the information we need (ie. the layout's margin)
const QToolBar *tb = qobject_cast<const QToolBar*>(widget);
const int margin = tb && tb->layout() ? tb->layout()->margin() : 2;
@@ -4808,6 +4813,16 @@ QSize QCommonStyle::sizeFromContents(ContentsType ct, const QStyleOption *opt,
}
break;
#endif // QT_NO_ITEMVIEWS
+#ifndef QT_NO_SPINBOX
+ case CT_SpinBox:
+ if (const QStyleOptionSpinBox *vopt = qstyleoption_cast<const QStyleOptionSpinBox *>(opt)) {
+ // Add button + frame widths
+ int buttonWidth = 20;
+ int fw = vopt->frame ? proxy()->pixelMetric(PM_SpinBoxFrameWidth, vopt, widget) : 0;
+ sz += QSize(buttonWidth + 2*fw, 2*fw);
+ }
+ break;
+#endif
case CT_ScrollBar:
case CT_MenuBar:
case CT_Menu:
@@ -5090,11 +5105,18 @@ int QCommonStyle::styleHint(StyleHint sh, const QStyleOption *opt, const QWidget
ret = theme->themeHint(QPlatformTheme::ToolButtonStyle).toInt();
break;
case SH_RequestSoftwareInputPanel:
+#ifdef Q_OS_ANDROID
+ ret = RSIP_OnMouseClick;
+#else
ret = RSIP_OnMouseClickAndAlreadyFocused;
+#endif
break;
case SH_ScrollBar_Transient:
ret = false;
break;
+ case SH_Menu_SupportsSections:
+ ret = false;
+ break;
default:
ret = 0;
break;
diff --git a/src/widgets/styles/qcommonstyle.h b/src/widgets/styles/qcommonstyle.h
index 1d203ded34..942721a6a3 100644
--- a/src/widgets/styles/qcommonstyle.h
+++ b/src/widgets/styles/qcommonstyle.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qstyle.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QCommonStylePrivate;
@@ -53,7 +51,7 @@ class QCommonStylePrivate;
class Q_WIDGETS_EXPORT QCommonStyle: public QStyle
{
Q_OBJECT
-
+
public:
QCommonStyle();
~QCommonStyle();
@@ -105,6 +103,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOMMONSTYLE_H
diff --git a/src/widgets/styles/qcommonstyle_p.h b/src/widgets/styles/qcommonstyle_p.h
index dbb4d3cd37..979c2a5548 100644
--- a/src/widgets/styles/qcommonstyle_p.h
+++ b/src/widgets/styles/qcommonstyle_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qcommonstylepixmaps_p.h b/src/widgets/styles/qcommonstylepixmaps_p.h
index 0699ff8914..d47b16d1a4 100644
--- a/src/widgets/styles/qcommonstylepixmaps_p.h
+++ b/src/widgets/styles/qcommonstylepixmaps_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -39,6 +39,8 @@
**
****************************************************************************/
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_IMAGEFORMAT_XPM
//
diff --git a/src/widgets/styles/qdrawutil.cpp b/src/widgets/styles/qdrawutil.cpp
index 0f73a16bcb..3df3bfa50d 100644
--- a/src/widgets/styles/qdrawutil.cpp
+++ b/src/widgets/styles/qdrawutil.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -748,10 +748,10 @@ void qDrawPlainRect(QPainter *p, const QRect &r, const QColor &c,
\since 4.6
\inmodule QtWidgets
-
+
\brief The QTileRules class provides the rules used to draw a
pixmap or image split into nine segments.
-
+
Spliiting is similar to \l{http://www.w3.org/TR/css3-background/}{CSS3 border-images}.
\sa Qt::TileRule, QMargins
diff --git a/src/widgets/styles/qdrawutil.h b/src/widgets/styles/qdrawutil.h
index f0cc98f54a..6e9dc26591 100644
--- a/src/widgets/styles/qdrawutil.h
+++ b/src/widgets/styles/qdrawutil.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtCore/qstring.h> // char*->QString conversion
#include <QtCore/qmargins.h>
#include <QtGui/qpixmap.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -169,6 +167,4 @@ inline void qDrawBorderPixmap(QPainter *painter,
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDRAWUTIL_H
diff --git a/src/widgets/styles/qfusionstyle.cpp b/src/widgets/styles/qfusionstyle.cpp
index 11558de16a..bfc22807a0 100644
--- a/src/widgets/styles/qfusionstyle.cpp
+++ b/src/widgets/styles/qfusionstyle.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -1086,7 +1086,7 @@ void QFusionStyle::drawControl(ControlElement element, const QStyleOption *optio
case CE_ToolBar:
if (const QStyleOptionToolBar *toolBar = qstyleoption_cast<const QStyleOptionToolBar *>(option)) {
// Reserve the beveled appearance only for mainwindow toolbars
- if (!(widget && qobject_cast<const QMainWindow*> (widget->parentWidget())))
+ if (widget && !(qobject_cast<const QMainWindow*> (widget->parentWidget())))
break;
// Draws the light line above and the dark line below menu bars and
@@ -1768,12 +1768,10 @@ void QFusionStyle::drawControl(ControlElement element, const QStyleOption *optio
painter->save();
{
painter->fillRect(rect, option->palette.window());
- if (widget && qobject_cast<const QMainWindow *>(widget->parentWidget())) {
- QColor shadow = mergedColors(option->palette.background().color().darker(120),
- outline.lighter(140), 60);
- painter->setPen(QPen(shadow));
- painter->drawLine(option->rect.bottomLeft(), option->rect.bottomRight());
- }
+ QColor shadow = mergedColors(option->palette.background().color().darker(120),
+ outline.lighter(140), 60);
+ painter->setPen(QPen(shadow));
+ painter->drawLine(option->rect.bottomLeft(), option->rect.bottomRight());
}
painter->restore();
break;
@@ -2800,53 +2798,6 @@ void QFusionStyle::drawComplexControl(ComplexControl control, const QStyleOption
painter->restore();
}
- // draw handle
- if ((option->subControls & SC_SliderHandle) ) {
- QString handlePixmapName = QStyleHelper::uniqueName(QLatin1String("slider_handle"), option, handle.size());
- if (!QPixmapCache::find(handlePixmapName, cache)) {
- cache = styleCachePixmap(handle.size());
- cache.fill(Qt::transparent);
- QRect pixmapRect(0, 0, handle.width(), handle.height());
- QPainter handlePainter(&cache);
- QRect gradRect = pixmapRect.adjusted(2, 2, -2, -2);
-
- // gradient fill
- QRect r = pixmapRect.adjusted(1, 1, -2, -2);
- QLinearGradient gradient = qt_fusion_gradient(gradRect, d->buttonColor(option->palette),horizontal ? TopDown : FromLeft);
-
- handlePainter.setRenderHint(QPainter::Antialiasing, true);
- handlePainter.translate(0.5, 0.5);
-
- handlePainter.setPen(Qt::NoPen);
- handlePainter.setBrush(QColor(0, 0, 0, 40));
- handlePainter.drawRect(r.adjusted(-1, 2, 1, -2));
-
- handlePainter.setPen(QPen(d->outline(option->palette)));
- if (option->state & State_HasFocus && option->state & State_KeyboardFocusChange)
- handlePainter.setPen(QPen(d->highlightedOutline(option->palette)));
-
- handlePainter.setBrush(gradient);
- handlePainter.drawRoundedRect(r, 2, 2);
- handlePainter.setBrush(Qt::NoBrush);
- handlePainter.setPen(d->innerContrastLine());
- handlePainter.drawRoundedRect(r.adjusted(1, 1, -1, -1), 2, 2);
-
- QColor cornerAlpha = outline.darker(120);
- cornerAlpha.setAlpha(80);
-
- //handle shadow
- handlePainter.setPen(shadowAlpha);
- handlePainter.drawLine(QPoint(r.left() + 2, r.bottom() + 1), QPoint(r.right() - 2, r.bottom() + 1));
- handlePainter.drawLine(QPoint(r.right() + 1, r.bottom() - 3), QPoint(r.right() + 1, r.top() + 4));
- handlePainter.drawLine(QPoint(r.right() - 1, r.bottom()), QPoint(r.right() + 1, r.bottom() - 2));
-
- handlePainter.end();
- QPixmapCache::insert(handlePixmapName, cache);
- }
-
- painter->drawPixmap(handle.topLeft(), cache);
-
- }
if (option->subControls & SC_SliderTickmarks) {
painter->setPen(outline);
int tickSize = proxy()->pixelMetric(PM_SliderTickmarkOffset, option, widget);
@@ -2902,6 +2853,53 @@ void QFusionStyle::drawComplexControl(ComplexControl control, const QStyleOption
v = nextInterval;
}
}
+ // draw handle
+ if ((option->subControls & SC_SliderHandle) ) {
+ QString handlePixmapName = QStyleHelper::uniqueName(QLatin1String("slider_handle"), option, handle.size());
+ if (!QPixmapCache::find(handlePixmapName, cache)) {
+ cache = styleCachePixmap(handle.size());
+ cache.fill(Qt::transparent);
+ QRect pixmapRect(0, 0, handle.width(), handle.height());
+ QPainter handlePainter(&cache);
+ QRect gradRect = pixmapRect.adjusted(2, 2, -2, -2);
+
+ // gradient fill
+ QRect r = pixmapRect.adjusted(1, 1, -2, -2);
+ QLinearGradient gradient = qt_fusion_gradient(gradRect, d->buttonColor(option->palette),horizontal ? TopDown : FromLeft);
+
+ handlePainter.setRenderHint(QPainter::Antialiasing, true);
+ handlePainter.translate(0.5, 0.5);
+
+ handlePainter.setPen(Qt::NoPen);
+ handlePainter.setBrush(QColor(0, 0, 0, 40));
+ handlePainter.drawRect(r.adjusted(-1, 2, 1, -2));
+
+ handlePainter.setPen(QPen(d->outline(option->palette)));
+ if (option->state & State_HasFocus && option->state & State_KeyboardFocusChange)
+ handlePainter.setPen(QPen(d->highlightedOutline(option->palette)));
+
+ handlePainter.setBrush(gradient);
+ handlePainter.drawRoundedRect(r, 2, 2);
+ handlePainter.setBrush(Qt::NoBrush);
+ handlePainter.setPen(d->innerContrastLine());
+ handlePainter.drawRoundedRect(r.adjusted(1, 1, -1, -1), 2, 2);
+
+ QColor cornerAlpha = outline.darker(120);
+ cornerAlpha.setAlpha(80);
+
+ //handle shadow
+ handlePainter.setPen(shadowAlpha);
+ handlePainter.drawLine(QPoint(r.left() + 2, r.bottom() + 1), QPoint(r.right() - 2, r.bottom() + 1));
+ handlePainter.drawLine(QPoint(r.right() + 1, r.bottom() - 3), QPoint(r.right() + 1, r.top() + 4));
+ handlePainter.drawLine(QPoint(r.right() - 1, r.bottom()), QPoint(r.right() + 1, r.bottom() - 2));
+
+ handlePainter.end();
+ QPixmapCache::insert(handlePixmapName, cache);
+ }
+
+ painter->drawPixmap(handle.topLeft(), cache);
+
+ }
painter->setBrush(oldBrush);
painter->setPen(oldPen);
}
@@ -2922,6 +2920,8 @@ void QFusionStyle::drawComplexControl(ComplexControl control, const QStyleOption
int QFusionStyle::pixelMetric(PixelMetric metric, const QStyleOption *option, const QWidget *widget) const
{
switch (metric) {
+ case PM_SliderTickmarkOffset:
+ return 4;
case PM_HeaderMargin:
return 2;
case PM_ToolTipLabelFrameWidth:
@@ -3475,6 +3475,7 @@ int QFusionStyle::styleHint(StyleHint hint, const QStyleOption *option, const QW
case SH_ItemView_ChangeHighlightOnFocus:
case SH_MenuBar_MouseTracking:
case SH_Menu_MouseTracking:
+ case SH_Menu_SupportsSections:
return 1;
case SH_ToolBox_SelectedPageTitleBold:
diff --git a/src/widgets/styles/qfusionstyle_p.h b/src/widgets/styles/qfusionstyle_p.h
index e024677a9b..9e5a55918d 100644
--- a/src/widgets/styles/qfusionstyle_p.h
+++ b/src/widgets/styles/qfusionstyle_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qcommonstyle.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -106,6 +104,4 @@ protected:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QFUSIONSTYLE_P_H
diff --git a/src/widgets/styles/qfusionstyle_p_p.h b/src/widgets/styles/qfusionstyle_p_p.h
index d3f2ff5f40..acdf409dbf 100644
--- a/src/widgets/styles/qfusionstyle_p_p.h
+++ b/src/widgets/styles/qfusionstyle_p_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -88,9 +88,9 @@ public:
// On mac we want a standard blue color used when the system palette is used
bool isMacSystemPalette(const QPalette &pal) const {
Q_UNUSED(pal);
-#ifdef Q_OS_MAC
+#if defined(Q_OS_MAC) && !defined(Q_OS_IOS)
const QPalette *themePalette = QGuiApplicationPrivate::platformTheme()->palette();
- if (themePalette->color(QPalette::Normal, QPalette::Highlight) ==
+ if (themePalette && themePalette->color(QPalette::Normal, QPalette::Highlight) ==
pal.color(QPalette::Normal, QPalette::Highlight) &&
themePalette->color(QPalette::Normal, QPalette::HighlightedText) ==
pal.color(QPalette::Normal, QPalette::HighlightedText))
diff --git a/src/widgets/styles/qgtk2painter.cpp b/src/widgets/styles/qgtk2painter.cpp
index 4d00a7385e..7b9bd975d8 100644
--- a/src/widgets/styles/qgtk2painter.cpp
+++ b/src/widgets/styles/qgtk2painter.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qgtk2painter_p.h b/src/widgets/styles/qgtk2painter_p.h
index 286430cd33..f1444a87de 100644
--- a/src/widgets/styles/qgtk2painter_p.h
+++ b/src/widgets/styles/qgtk2painter_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qgtkglobal_p.h b/src/widgets/styles/qgtkglobal_p.h
index 24da8c8e64..06ed7cfce4 100644
--- a/src/widgets/styles/qgtkglobal_p.h
+++ b/src/widgets/styles/qgtkglobal_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qgtkpainter.cpp b/src/widgets/styles/qgtkpainter.cpp
index dac98a199c..a733049f65 100644
--- a/src/widgets/styles/qgtkpainter.cpp
+++ b/src/widgets/styles/qgtkpainter.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qgtkpainter_p.h b/src/widgets/styles/qgtkpainter_p.h
index 58833b7c95..12d4dc9bc4 100644
--- a/src/widgets/styles/qgtkpainter_p.h
+++ b/src/widgets/styles/qgtkpainter_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qgtkstyle.cpp b/src/widgets/styles/qgtkstyle.cpp
index 159f8dce83..15fa00d8a6 100644
--- a/src/widgets/styles/qgtkstyle.cpp
+++ b/src/widgets/styles/qgtkstyle.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -2121,7 +2121,7 @@ void QGtkStyle::drawComplexControl(ComplexControl control, const QStyleOptionCom
label.state = bflags;
GtkWidget *gtkButton = d->gtkWidget("GtkToolButton.GtkButton");
QPalette pal = toolbutton->palette;
- if (option->state & State_Enabled &&
+ if (option->state & State_Enabled &&
option->state & State_MouseOver && !(widget && widget->testAttribute(Qt::WA_SetPalette))) {
GdkColor gdkText = d->gtk_widget_get_style(gtkButton)->fg[GTK_STATE_PRELIGHT];
QColor textColor = QColor(gdkText.red>>8, gdkText.green>>8, gdkText.blue>>8);
@@ -2971,7 +2971,7 @@ void QGtkStyle::drawControl(ControlElement element,
if (option->state & State_Sunken)
shadow = GTK_SHADOW_IN;
-
+
gtkPainter->paintBox(gtkTreeHeader, "button", option->rect.adjusted(-1, 0, 0, 0), state, shadow, d->gtk_widget_get_style(gtkTreeHeader));
}
@@ -3171,7 +3171,8 @@ void QGtkStyle::drawControl(ControlElement element,
#ifndef QT_NO_COMBOBOX
- if (qobject_cast<const QComboBox*>(widget))
+ if (qobject_cast<const QComboBox*>(widget) ||
+ (option->styleObject && option->styleObject->property("_q_isComboBoxPopupItem").toBool()))
ignoreCheckMark = true; // Ignore the checkmarks provided by the QComboMenuDelegate
#endif
@@ -3912,7 +3913,7 @@ QSize QGtkStyle::sizeFromContents(ContentsType type, const QStyleOption *option,
break;
case CT_SpinBox:
// QSpinBox does some nasty things that depends on CT_LineEdit
- newSize = size + QSize(0, -d->gtk_widget_get_style(d->gtkWidget("GtkSpinButton"))->ythickness * 2);
+ newSize = newSize + QSize(0, -d->gtk_widget_get_style(d->gtkWidget("GtkSpinButton"))->ythickness * 2);
break;
case CT_RadioButton:
case CT_CheckBox:
diff --git a/src/widgets/styles/qgtkstyle_p.cpp b/src/widgets/styles/qgtkstyle_p.cpp
index 810a8995f8..a53a961a89 100644
--- a/src/widgets/styles/qgtkstyle_p.cpp
+++ b/src/widgets/styles/qgtkstyle_p.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -529,18 +529,6 @@ void QGtkStylePrivate::initGtkWidgets() const
return;
}
- static QString themeName;
- if (!gtkWidgetMap()->contains("GtkWindow") && themeName.isEmpty()) {
- themeName = getThemeName();
-
- if (themeName == QLS("Qt") || themeName == QLS("Qt4")) {
- // Due to namespace conflicts with Qt3 and obvious recursion with Qt4,
- // we cannot support the GTK_Qt Gtk engine
- qWarning("QGtkStyle cannot be used together with the GTK_Qt engine.");
- return;
- }
- }
-
if (QGtkStylePrivate::gtk_init) {
#ifndef Q_OS_MAC
// Gtk will set the Qt error handler so we have to reset it afterwards
@@ -688,38 +676,12 @@ bool QGtkStylePrivate::getGConfBool(const QString &key, bool fallback)
QString QGtkStylePrivate::getThemeName()
{
QString themeName;
- // We try to parse the gtkrc file first
- // primarily to avoid resolving Gtk functions if
- // the KDE 3 "Qt" style is currently in use
- QString rcPaths = QString::fromLocal8Bit(qgetenv("GTK2_RC_FILES"));
- if (!rcPaths.isEmpty()) {
- QStringList paths = rcPaths.split(QLS(":"));
- foreach (const QString &rcPath, paths) {
- if (!rcPath.isEmpty()) {
- QFile rcFile(rcPath);
- if (rcFile.open(QIODevice::ReadOnly | QIODevice::Text)) {
- QTextStream in(&rcFile);
- while(!in.atEnd()) {
- QString line = in.readLine();
- if (line.contains(QLS("gtk-theme-name"))) {
- line = line.right(line.length() - line.indexOf(QLatin1Char('=')) - 1);
- line.remove(QLatin1Char('\"'));
- line = line.trimmed();
- themeName = line;
- break;
- }
- }
- }
- }
- if (!themeName.isEmpty())
- break;
- }
- }
-
- // Fall back to gconf
- if (themeName.isEmpty() && resolveGConf())
- themeName = getGConfString(QLS("/desktop/gnome/interface/gtk_theme"));
-
+ // Read the theme name from GtkSettings
+ GtkSettings *settings = QGtkStylePrivate::gtk_settings_get_default();
+ gchararray value;
+ g_object_get(settings, "gtk-theme-name", &value, NULL);
+ themeName = QString::fromUtf8(value);
+ g_free(value);
return themeName;
}
diff --git a/src/widgets/styles/qgtkstyle_p.h b/src/widgets/styles/qgtkstyle_p.h
index f2710af4c6..525d7f840a 100644
--- a/src/widgets/styles/qgtkstyle_p.h
+++ b/src/widgets/styles/qgtkstyle_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtGui/QFont>
#include <QtWidgets/QFileDialog>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -119,6 +117,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QGTKSTYLE_P_H
diff --git a/src/widgets/styles/qgtkstyle_p_p.h b/src/widgets/styles/qgtkstyle_p_p.h
index fc77aea48b..6f3759bd9e 100644
--- a/src/widgets/styles/qgtkstyle_p_p.h
+++ b/src/widgets/styles/qgtkstyle_p_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qmacstyle.qdoc b/src/widgets/styles/qmacstyle.qdoc
index 9f5299032f..9ee464667a 100644
--- a/src/widgets/styles/qmacstyle.qdoc
+++ b/src/widgets/styles/qmacstyle.qdoc
@@ -104,43 +104,43 @@
*/
/*! \fn void QMacStyle::polish(QPalette &pal)
- \reimp
+ \reimp
*/
/*! \fn void QMacStyle::polish(QApplication *)
- \reimp
+ \reimp
*/
/*! \fn void QMacStyle::unpolish(QApplication *)
- \reimp
+ \reimp
*/
/*! \fn void QMacStyle::polish(QWidget* w)
- \reimp
+ \reimp
*/
/*! \fn void QMacStyle::unpolish(QWidget* w)
- \reimp
+ \reimp
*/
/*! \fn int QMacStyle::pixelMetric(PixelMetric metric, const QStyleOption *opt, const QWidget *widget) const
- \reimp
+ \reimp
*/
/*! \fn QPalette QMacStyle::standardPalette() const
- \reimp
+ \reimp
*/
/*! \fn int QMacStyle::styleHint(StyleHint sh, const QStyleOption *opt, const QWidget *w, QStyleHintReturn *hret) const
- \reimp
+ \reimp
*/
/*! \fn QPixmap QMacStyle::generatedIconPixmap(QIcon::Mode iconMode, const QPixmap &pixmap, const QStyleOption *opt) const
- \reimp
+ \reimp
*/
/*! \fn QPixmap QMacStyle::standardPixmap(StandardPixmap standardPixmap, const QStyleOption *opt, const QWidget *widget) const
- \reimp
+ \reimp
*/
/*!
@@ -199,41 +199,41 @@
/*! \fn void QMacStyle::drawPrimitive(PrimitiveElement pe, const QStyleOption *opt, QPainter *p, const QWidget *w) const
- \reimp
+ \reimp
*/
/*! \fn void QMacStyle::drawControl(ControlElement ce, const QStyleOption *opt, QPainter *p, const QWidget *w) const
- \reimp
+ \reimp
*/
/*! \fn QRect QMacStyle::subElementRect(SubElement sr, const QStyleOption *opt, const QWidget *widget) const
- \reimp
+ \reimp
*/
/*! \fn void QMacStyle::drawComplexControl(ComplexControl cc, const QStyleOptionComplex *opt, QPainter *p, const QWidget *widget) const
- \reimp
+ \reimp
*/
/*! \fn QStyle::SubControl QMacStyle::hitTestComplexControl(ComplexControl cc, const QStyleOptionComplex *opt, const QPoint &pt, const QWidget *widget) const
- \reimp
+ \reimp
*/
/*! \fn QRect QMacStyle::subControlRect(ComplexControl cc, const QStyleOptionComplex *opt, SubControl sc, const QWidget *widget) const
- \reimp
+ \reimp
*/
/*! \fn QSize QMacStyle::sizeFromContents(ContentsType ct, const QStyleOption *opt, const QSize &csz, const QWidget *widget) const
- \reimp
+ \reimp
*/
/*! \fn void QMacStyle::drawItemText(QPainter *p, const QRect &r, int flags, const QPalette &pal, bool enabled, const QString &text, QPalette::ColorRole textRole) const
- \reimp
+ \reimp
*/
/*! \fn bool QMacStyle::event(QEvent *e)
- \reimp
+ \reimp
*/
/*! \fn QIcon QMacStyle::standardIcon(StandardPixmap standardIcon, const QStyleOption *opt, const QWidget *widget) const
diff --git a/src/widgets/styles/qmacstyle_mac.mm b/src/widgets/styles/qmacstyle_mac.mm
index dab8e3fe74..04fea3ec47 100644
--- a/src/widgets/styles/qmacstyle_mac.mm
+++ b/src/widgets/styles/qmacstyle_mac.mm
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -41,14 +41,13 @@
/*
Note: The qdoc comments for QMacStyle are contained in
- .../doc/src/qstyles.qdoc.
+ .../doc/src/qstyles.qdoc.
*/
#include <Cocoa/Cocoa.h>
#include "qmacstyle_mac_p.h"
#include "qmacstyle_mac_p_p.h"
-#include "qmacstylepixmaps_mac_p.h"
#define QMAC_QAQUASTYLE_SIZE_CONSTRAIN
//#define DEBUG_SIZE_CONSTRAINT
@@ -589,11 +588,9 @@ static CGColorSpaceRef qt_mac_genericColorSpace()
{
#if 0
if (!m_genericColorSpace) {
-#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4
if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_4) {
m_genericColorSpace = CGColorSpaceCreateWithName(kCGColorSpaceGenericRGB);
} else
-#endif
{
m_genericColorSpace = CGColorSpaceCreateDeviceRGB();
}
@@ -1208,7 +1205,6 @@ void QMacStylePrivate::initHIThemePushButton(const QStyleOptionButton *btn,
const ThemeDrawState tds,
HIThemeButtonDrawInfo *bdi) const
{
- bool drawColorless = btn->palette.currentColorGroup() == QPalette::Active;
ThemeDrawState tdsModified = tds;
if (btn->state & QStyle::State_On)
tdsModified = kThemeStatePressed;
@@ -1216,7 +1212,7 @@ void QMacStylePrivate::initHIThemePushButton(const QStyleOptionButton *btn,
bdi->state = tdsModified;
bdi->value = kThemeButtonOff;
- if (drawColorless && tdsModified == kThemeStateInactive)
+ if (tds == kThemeStateInactive)
bdi->state = kThemeStateActive;
if (btn->state & QStyle::State_HasFocus)
bdi->adornment = kThemeAdornmentFocus;
@@ -1287,10 +1283,9 @@ void QMacStylePrivate::initComboboxBdi(const QStyleOptionComboBox *combo, HIThem
bdi->value = kThemeButtonOff;
if (combo->state & QStyle::State_HasFocus)
bdi->adornment = kThemeAdornmentFocus;
- bool drawColorless = combo->palette.currentColorGroup() == QPalette::Active && tds == kThemeStateInactive;
if (combo->activeSubControls & QStyle::SC_ComboBoxArrow)
bdi->state = kThemeStatePressed;
- else if (drawColorless)
+ else if (tds == kThemeStateInactive)
bdi->state = kThemeStateActive;
else
bdi->state = tds;
@@ -1611,8 +1606,6 @@ void QMacStylePrivate::getSliderInfo(QStyle::ComplexControl cc, const QStyleOpti
tdi->enableState = (slider->state & QStyle::State_Enabled) ? kThemeTrackActive
: kThemeTrackDisabled;
- if (!(slider->state & QStyle::State_Active))
- tdi->enableState = kThemeTrackInactive;
if (!isScrollbar) {
if (slider->state & QStyle::QStyle::State_HasFocus)
tdi->attributes |= kThemeTrackHasFocus;
@@ -2377,6 +2370,9 @@ int QMacStyle::pixelMetric(PixelMetric metric, const QStyleOption *opt, const QW
case PM_MenuHMargin:
ret = 0;
break;
+ case PM_ToolBarExtensionExtent:
+ ret = 21;
+ break;
case PM_ToolBarFrameWidth:
ret = 1;
if (widget) {
@@ -2960,16 +2956,16 @@ void QMacStyle::drawPrimitive(PrimitiveElement pe, const QStyleOption *opt, QPai
p->save();
QPainterPath path;
int x = opt->rect.x() + 6;
- int y = opt->rect.y() + 5;
+ int y = opt->rect.y() + 7;
static const int RectHeight = 2;
if (opt->state & State_Horizontal) {
- while (y < opt->rect.height() - RectHeight - 6) {
+ while (y < opt->rect.height() - RectHeight - 5) {
path.moveTo(x, y);
path.addRect(x, y, RectHeight, RectHeight);
y += 6;
}
} else {
- while (x < opt->rect.width() - RectHeight - 6) {
+ while (x < opt->rect.width() - RectHeight - 5) {
path.moveTo(x, y);
path.addRect(x, y, RectHeight, RectHeight);
x += 6;
@@ -2981,12 +2977,6 @@ void QMacStyle::drawPrimitive(PrimitiveElement pe, const QStyleOption *opt, QPai
QColor light = opt->palette.light().color();
light.setAlphaF(0.6);
p->fillPath(path, light);
- p->save();
- p->translate(1, 1);
- p->fillPath(path, dark);
- p->restore();
- p->translate(3, 3);
- p->fillPath(path, light);
p->translate(1, 1);
p->fillPath(path, dark);
p->restore();
@@ -3033,12 +3023,11 @@ void QMacStyle::drawPrimitive(PrimitiveElement pe, const QStyleOption *opt, QPai
case PE_IndicatorViewItemCheck:
case PE_IndicatorRadioButton:
case PE_IndicatorCheckBox: {
- bool drawColorless = (!(opt->state & State_Active))
- && opt->palette.currentColorGroup() == QPalette::Active;
+ bool drawColorless = tds == kThemeStateInactive;
HIThemeButtonDrawInfo bdi;
bdi.version = qt_mac_hitheme_version;
bdi.state = tds;
- if (drawColorless && tds == kThemeStateInactive)
+ if (drawColorless)
bdi.state = kThemeStateActive;
bdi.adornment = kThemeDrawIndicatorOnly;
if (opt->state & State_HasFocus)
@@ -3203,18 +3192,6 @@ void QMacStyle::drawPrimitive(PrimitiveElement pe, const QStyleOption *opt, QPai
drawTabCloseButton(p, hover, active, selected);
} break;
case PE_PanelStatusBar: {
- if (QSysInfo::MacintoshVersion <= QSysInfo::MV_10_4) {
- QCommonStyle::drawPrimitive(pe, opt, p, w);
- break;
- }
- // Use the Leopard style only if the status bar is the status bar for a
- // QMainWindow with a unifed toolbar.
- if (w == 0 || w->parent() == 0 || qobject_cast<QMainWindow *>(w->parent()) == 0 ||
- qobject_cast<QMainWindow *>(w->parent())->unifiedTitleAndToolBarOnMac() == false ) {
- QCommonStyle::drawPrimitive(pe, opt, p, w);
- break;
- }
-
// Fill the status bar with the titlebar gradient.
QLinearGradient linearGrad(0, opt->rect.top(), 0, opt->rect.bottom());
if (opt->state & QStyle::State_Active) {
@@ -3359,9 +3336,9 @@ void QMacStyle::drawControl(ControlElement ce, const QStyleOption *opt, QPainter
QPixmap pixmap = header->icon.pixmap(proxy()->pixelMetric(PM_SmallIconSize), mode);
QRect pixr = header->rect;
- pixr.setY(header->rect.center().y() - (pixmap.height() - 1) / 2);
+ pixr.setY(header->rect.center().y() - (pixmap.height() / pixmap.devicePixelRatio() - 1) / 2);
proxy()->drawItemPixmap(p, pixr, Qt::AlignVCenter, pixmap);
- textr.translate(pixmap.width() + 2, 0);
+ textr.translate(pixmap.width() / pixmap.devicePixelRatio() + 2, 0);
}
p->setFont(qt_app_fonts_hash()->value("QSmallFont", QFont()));
@@ -3415,15 +3392,15 @@ void QMacStyle::drawControl(ControlElement ce, const QStyleOption *opt, QPainter
if (tb->toolButtonStyle == Qt::ToolButtonTextUnderIcon) {
QMainWindow *mw = qobject_cast<QMainWindow *>(w->window());
if (mw && mw->unifiedTitleAndToolBarOnMac()) {
- pr.setHeight(pixmap.size().height());
+ pr.setHeight(pixmap.size().height() / pixmap.devicePixelRatio());
cr.adjust(0, pr.bottom() + 1, 0, 1);
} else {
- pr.setHeight(pixmap.size().height() + 6);
+ pr.setHeight(pixmap.size().height() / pixmap.devicePixelRatio() + 6);
cr.adjust(0, pr.bottom(), 0, -3);
- }
+ }
alignment |= Qt::AlignCenter;
} else {
- pr.setWidth(pixmap.width() + 8);
+ pr.setWidth(pixmap.width() / pixmap.devicePixelRatio() + 8);
cr.adjust(pr.right(), 0, 0, 0);
alignment |= Qt::AlignLeft | Qt::AlignVCenter;
}
@@ -3572,13 +3549,10 @@ void QMacStyle::drawControl(ControlElement ce, const QStyleOption *opt, QPainter
int arrowYOffset = bdi.kind == kThemePushButton ? 4 : 2;
HIRect arrowRect = CGRectMake(ir.right() - mbi - QMacStylePrivate::PushButtonRightOffset,
ir.height() / 2 - arrowYOffset, mbi, ir.height() / 2);
- bool drawColorless = btn->palette.currentColorGroup() == QPalette::Active;
- if (drawColorless && tds == kThemeStateInactive)
- tds = kThemeStateActive;
HIThemePopupArrowDrawInfo pdi;
pdi.version = qt_mac_hitheme_version;
- pdi.state = tds;
+ pdi.state = tds == kThemeStateInactive ? kThemeStateActive : tds;
pdi.orientation = kThemeArrowDown;
if (arrowRect.size.width < 8.)
pdi.size = kThemeArrow5pt;
@@ -3664,10 +3638,12 @@ void QMacStyle::drawControl(ControlElement ce, const QStyleOption *opt, QPainter
if (btn->state & State_On)
state = QIcon::On;
QPixmap pixmap = btn->icon.pixmap(btn->iconSize, mode, state);
- contentW += pixmap.width() + QMacStylePrivate::PushButtonContentPadding;
+ int pixmapWidth = pixmap.width() / pixmap.devicePixelRatio();
+ int pixmapHeight = pixmap.height() / pixmap.devicePixelRatio();
+ contentW += pixmapWidth + QMacStylePrivate::PushButtonContentPadding;
int iconLeftOffset = freeContentRect.x() + (freeContentRect.width() - contentW) / 2;
- int iconTopOffset = freeContentRect.y() + (freeContentRect.height() - pixmap.height()) / 2;
- QRect iconDestRect(iconLeftOffset, iconTopOffset, pixmap.width(), pixmap.height());
+ int iconTopOffset = freeContentRect.y() + (freeContentRect.height() - pixmapHeight) / 2;
+ QRect iconDestRect(iconLeftOffset, iconTopOffset, pixmapWidth, pixmapHeight);
QRect visualIconDestRect = visualRect(btn->direction, freeContentRect, iconDestRect);
proxy()->drawItemPixmap(p, visualIconDestRect, Qt::AlignLeft | Qt::AlignVCenter, pixmap);
int newOffset = iconDestRect.x() + iconDestRect.width()
@@ -4009,7 +3985,6 @@ void QMacStyle::drawControl(ControlElement ce, const QStyleOption *opt, QPainter
HIRect cr;
bool needAlpha = mi->palette.color(QPalette::Button) == Qt::transparent;
if (needAlpha) {
- needAlpha = true;
CGContextSaveGState(cg);
CGContextSetAlpha(cg, 0.0);
}
@@ -4026,7 +4001,7 @@ void QMacStyle::drawControl(ControlElement ce, const QStyleOption *opt, QPainter
if (!enabled)
p->setPen(mi->palette.text().color());
else if (active)
- p->setPen(QColor(Qt::white)); // QPalette's API is incomplete for this case
+ p->setPen(mi->palette.highlightedText().color());
else
p->setPen(mi->palette.buttonText().color());
@@ -4097,8 +4072,8 @@ void QMacStyle::drawControl(ControlElement ce, const QStyleOption *opt, QPainter
iconSize = comboBox->iconSize();
}
QPixmap pixmap = mi->icon.pixmap(iconSize, mode);
- int pixw = pixmap.width();
- int pixh = pixmap.height();
+ int pixw = pixmap.width() / pixmap.devicePixelRatio();
+ int pixh = pixmap.height() / pixmap.devicePixelRatio();
QRect cr(xpos, contentRect.y(), checkcol, contentRect.height());
QRect pmr(0, 0, pixw, pixh);
pmr.moveCenter(cr.center());
@@ -4915,14 +4890,12 @@ void QMacStyle::drawComplexControl(ComplexControl cc, const QStyleOptionComplex
} else {
if (!(slider->subControls & SC_SliderHandle))
tdi.attributes &= ~kThemeTrackShowThumb;
-#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5
if (!(slider->subControls & SC_SliderGroove))
tdi.attributes |= kThemeTrackHideTrack;
-#endif
}
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_7
- if (cc == CC_ScrollBar && proxy()->styleHint(SH_ScrollBar_Transient, 0, widget)) {
+ if (cc == CC_ScrollBar && proxy()->styleHint(SH_ScrollBar_Transient, opt, widget)) {
bool wasActive = false;
CGFloat opacity = 1.0;
CGFloat expandScale = 1.0;
@@ -5019,6 +4992,8 @@ void QMacStyle::drawComplexControl(ComplexControl cc, const QStyleOptionComplex
bgColor.blue() < 128;
if (isDarkBg)
[scroller setKnobStyle:NSScrollerKnobStyleLight];
+ else
+ [scroller setKnobStyle:NSScrollerKnobStyleDefault];
[scroller setControlSize:(tdi.kind == kThemeSmallScrollBar ? NSMiniControlSize
: NSRegularControlSize)];
@@ -5136,7 +5111,7 @@ void QMacStyle::drawComplexControl(ComplexControl cc, const QStyleOptionComplex
HIThemeFrameDrawInfo fdi;
fdi.version = qt_mac_hitheme_version;
- fdi.state = tds;
+ fdi.state = tds == kThemeStateInactive ? kThemeStateActive : tds;
fdi.kind = kHIThemeFrameTextFieldSquare;
fdi.isFocused = false;
HIRect hirect = qt_hirectForQRect(lineeditRect);
@@ -5167,11 +5142,10 @@ void QMacStyle::drawComplexControl(ComplexControl cc, const QStyleOptionComplex
else if (sb->activeSubControls == SC_SpinBoxUp
&& (sb->state & State_Sunken))
tds = kThemeStatePressedUp;
- bdi.state = tds;
- if (!(sb->state & State_Active)
- && sb->palette.currentColorGroup() == QPalette::Active
- && tds == kThemeStateInactive)
+ if (tds == kThemeStateInactive)
bdi.state = kThemeStateActive;
+ else
+ bdi.state = tds;
bdi.value = kThemeButtonOff;
bdi.adornment = kThemeAdornmentNone;
@@ -5188,7 +5162,10 @@ void QMacStyle::drawComplexControl(ComplexControl cc, const QStyleOptionComplex
int(outRect.size.height - newRect.size.height));
newRect = qt_hirectForQRect(updown, off_rct);
- HIThemeDrawButton(&newRect, &bdi, cg, kHIThemeOrientationNormal, 0);
+ if (tds == kThemeStateInactive)
+ d->drawColorlessButton(newRect, &bdi, p, sb);
+ else
+ HIThemeDrawButton(&newRect, &bdi, cg, kHIThemeOrientationNormal, 0);
}
}
break;
@@ -5196,8 +5173,7 @@ void QMacStyle::drawComplexControl(ComplexControl cc, const QStyleOptionComplex
if (const QStyleOptionComboBox *combo = qstyleoption_cast<const QStyleOptionComboBox *>(opt)){
HIThemeButtonDrawInfo bdi;
d->initComboboxBdi(combo, &bdi, widget, d->getDrawState(opt->state));
- bool drawColorless = combo->palette.currentColorGroup() == QPalette::Active && tds == kThemeStateInactive;
- if (!drawColorless)
+ if (!tds == kThemeStateInactive)
QMacStylePrivate::drawCombobox(qt_hirectForQRect(combo->rect), bdi, p);
else
d->drawColorlessButton(qt_hirectForQRect(combo->rect), &bdi, p, opt);
@@ -5310,7 +5286,7 @@ void QMacStyle::drawComplexControl(ComplexControl cc, const QStyleOptionComplex
else
x += br.width() / 2 - p->fontMetrics().width(titlebar->text) / 2;
if (iw)
- p->drawPixmap(x - iw, y,
+ p->drawPixmap(x - iw, y,
titlebar->icon.pixmap(proxy()->pixelMetric(PM_SmallIconSize), QIcon::Normal));
drawItemText(p, br, Qt::AlignCenter, opt->palette, tds == kThemeStateActive,
titlebar->text, QPalette::Text);
@@ -5988,10 +5964,11 @@ QSize QMacStyle::sizeFromContents(ContentsType ct, const QStyleOption *opt,
switch (ct) {
case QStyle::CT_SpinBox:
- // hack to work around horrible sizeHint() code in QAbstractSpinBox
+ // hack to work around horrible sizeHint() code in QAbstractSpinBox
+ sz = QCommonStyle::sizeFromContents(ct, opt, csz, widget);
sz.setHeight(sz.height() - 3);
break;
- case QStyle::CT_TabWidget:
+ case QStyle::CT_TabWidget:
// the size between the pane and the "contentsRect" (+4,+4)
// (the "contentsRect" is on the inside of the pane)
sz = QCommonStyle::sizeFromContents(ct, opt, csz, widget);
@@ -6019,12 +5996,12 @@ QSize QMacStyle::sizeFromContents(ContentsType ct, const QStyleOption *opt,
------------------------------ <- top of stack widget
- To summarize:
- * 2 is the distance between the pane and the contentsRect
+ To summarize:
+ * 2 is the distance between the pane and the contentsRect
* The 14 and the 1's are the distance from the contentsRect to the stack widget.
(same value as used in SE_TabWidgetTabContents)
* overlap is how much the pane should overlap the tab bar
- */
+ */
// then add the size between the stackwidget and the "contentsRect"
if (const QStyleOptionTabWidgetFrame *twf
@@ -6375,9 +6352,10 @@ QIcon QMacStyle::standardIcon(StandardPixmap standardIcon, const QStyleOption *o
return QCommonStyle::standardIcon(standardIcon, opt, widget);
case SP_ToolBarHorizontalExtensionButton:
case SP_ToolBarVerticalExtensionButton: {
- QPixmap pixmap(qt_mac_toolbar_ext);
+ QPixmap pixmap(QLatin1String(":/qt-project.org/styles/macstyle/images/toolbar-ext.png"));
if (standardIcon == SP_ToolBarVerticalExtensionButton) {
QPixmap pix2(pixmap.height(), pixmap.width());
+ pix2.setDevicePixelRatio(pixmap.devicePixelRatio());
pix2.fill(Qt::transparent);
QPainter p(&pix2);
p.translate(pix2.width(), 0);
@@ -6527,7 +6505,7 @@ void qt_mac_scale_region(QRegion *region, qreal scaleFactor)
scaledRects.reserve(region->rects().count());
foreach (const QRect &rect, region->rects()) {
- scaledRects.append(QRect(rect.topLeft(), rect.size() * scaleFactor));
+ scaledRects.append(QRect(rect.topLeft() * scaleFactor, rect.size() * scaleFactor));
}
region->setRects(&scaledRects[0], scaledRects.count());
}
@@ -6556,15 +6534,16 @@ QMacCGContext::QMacCGContext(QPainter *p)
context = CGBitmapContextCreate((void *) image->bits(), image->width(), image->height(),
8, image->bytesPerLine(), colorspace, flags);
+ // Invert y axis.
CGContextTranslateCTM(context, 0, image->height());
CGContextScaleCTM(context, 1, -1);
+ const qreal devicePixelRatio = image->devicePixelRatio();
+
if (devType == QInternal::Widget) {
// Set the clip rect which is an intersection of the system clip
// and the painter clip. To make matters more interesting these
// are in device pixels and device-independent pixels, respectively.
- const qreal devicePixelRatio = image->devicePixelRatio();
-
QRegion clip = p->paintEngine()->systemClip(); // get system clip in device pixels
QTransform native = p->deviceTransform(); // get device transform. dx/dy is in device pixels
@@ -6582,6 +6561,9 @@ QMacCGContext::QMacCGContext(QPainter *p)
// Scale the context so that painting happens in device-independet pixels.
CGContextScaleCTM(context, devicePixelRatio, devicePixelRatio);
CGContextTranslateCTM(context, native.dx() / devicePixelRatio, native.dy() / devicePixelRatio);
+ } else {
+ // Scale to paint in device-independent pixels.
+ CGContextScaleCTM(context, devicePixelRatio, devicePixelRatio);
}
} else {
qDebug() << "QMacCGContext:: Unsupported painter devtype type" << devType;
diff --git a/src/widgets/styles/qmacstyle_mac_p.h b/src/widgets/styles/qmacstyle_mac_p.h
index d06a5a951f..305bcf871c 100644
--- a/src/widgets/styles/qmacstyle_mac_p.h
+++ b/src/widgets/styles/qmacstyle_mac_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qcommonstyle.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -130,6 +128,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMACSTYLE_MAC_P_H
diff --git a/src/widgets/styles/qmacstyle_mac_p_p.h b/src/widgets/styles/qmacstyle_mac_p_p.h
index 6c0493fe04..c424ff0c3c 100644
--- a/src/widgets/styles/qmacstyle_mac_p_p.h
+++ b/src/widgets/styles/qmacstyle_mac_p_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qproxystyle.cpp b/src/widgets/styles/qproxystyle.cpp
index 66ace0f60b..b63e820bb9 100644
--- a/src/widgets/styles/qproxystyle.cpp
+++ b/src/widgets/styles/qproxystyle.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -59,7 +59,7 @@ QT_BEGIN_NAMESPACE
\since 4.6
\inmodule QtWidgets
-
+
A QProxyStyle wraps a QStyle (usually the default system style) for the
purpose of dynamically overriding painting or other specific style behavior.
@@ -108,10 +108,9 @@ void QProxyStylePrivate::ensureBaseStyle() const
}
/*!
- Constructs a QProxyStyle object for overriding behavior in \a style
- or in the current application \l{QStyle}{style} if \a style is 0
- (default). Normally \a style is 0, because you want to override
- behavior in the system style.
+ Constructs a QProxyStyle object for overriding behavior in the
+ specified base \a style, or in the current \l{QApplication::style}
+ {application style} if base \a style is not specified.
Ownership of \a style is transferred to QProxyStyle.
*/
@@ -127,6 +126,26 @@ QProxyStyle::QProxyStyle(QStyle *style) :
}
/*!
+ Constructs a QProxyStyle object for overriding behavior in
+ the base style specified by style \a key, or in the current
+ \l{QApplication::style}{application style} if the specified
+ style \a key is unrecognized.
+
+ \sa QStyleFactory::create()
+*/
+QProxyStyle::QProxyStyle(const QString &key) :
+ QCommonStyle(*new QProxyStylePrivate())
+{
+ Q_D(QProxyStyle);
+ QStyle *style = QStyleFactory::create(key);
+ if (style) {
+ d->baseStyle = style;
+ style->setProxy(this);
+ style->setParent(this); // Take ownership
+ }
+}
+
+/*!
Destroys the QProxyStyle object.
*/
QProxyStyle::~QProxyStyle()
diff --git a/src/widgets/styles/qproxystyle.h b/src/widgets/styles/qproxystyle.h
index 52b02c8e5b..5864c195c6 100644
--- a/src/widgets/styles/qproxystyle.h
+++ b/src/widgets/styles/qproxystyle.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/QCommonStyle>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -57,7 +55,8 @@ class Q_WIDGETS_EXPORT QProxyStyle : public QCommonStyle
Q_OBJECT
public:
- QProxyStyle(QStyle *baseStyle = 0);
+ QProxyStyle(QStyle *style = 0);
+ QProxyStyle(const QString &key);
~QProxyStyle();
QStyle *baseStyle() const;
@@ -107,6 +106,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPROXYSTYLE_H
diff --git a/src/widgets/styles/qproxystyle_p.h b/src/widgets/styles/qproxystyle_p.h
index 3d428a0c84..92f6f73ccc 100644
--- a/src/widgets/styles/qproxystyle_p.h
+++ b/src/widgets/styles/qproxystyle_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qstyle.cpp b/src/widgets/styles/qstyle.cpp
index 9c4901795d..603d0e50a5 100644
--- a/src/widgets/styles/qstyle.cpp
+++ b/src/widgets/styles/qstyle.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -137,7 +137,7 @@ static int unpackControlTypes(QSizePolicy::ControlTypes controls, QSizePolicy::C
state.
\endtable
-
+
For more information about widget styling and appearance, see the
\l{Styles and Style Aware Widgets}.
*/
@@ -1891,6 +1891,9 @@ void QStyle::drawItemPixmap(QPainter *painter, const QRect &rect, int alignment,
\value SH_ScrollBar_Transient Determines if the style supports transient scroll bars. Transient
scroll bars appear when the content is scrolled and disappear when they are no longer needed.
+ \value SH_Menu_SupportsSections Determines if the style displays sections in menus or treat them as
+ plain separators. Sections are separators with a text and icon hint.
+
\sa styleHint()
*/
diff --git a/src/widgets/styles/qstyle.h b/src/widgets/styles/qstyle.h
index b69f5da6c5..beafad326e 100644
--- a/src/widgets/styles/qstyle.h
+++ b/src/widgets/styles/qstyle.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -50,8 +50,6 @@
#include <QtGui/qpalette.h>
#include <QtWidgets/qsizepolicy.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -699,6 +697,7 @@ public:
SH_ToolButtonStyle,
SH_RequestSoftwareInputPanel,
SH_ScrollBar_Transient,
+ SH_Menu_SupportsSections,
// Add new style hint values here
SH_CustomBase = 0xf0000000
@@ -831,6 +830,4 @@ Q_WIDGETS_EXPORT QDebug operator<<(QDebug debug, QStyle::State state);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTYLE_H
diff --git a/src/widgets/styles/qstyle.qrc b/src/widgets/styles/qstyle.qrc
index d835728928..28ad484032 100644
--- a/src/widgets/styles/qstyle.qrc
+++ b/src/widgets/styles/qstyle.qrc
@@ -133,5 +133,7 @@
<file>images/closedock-down-16.png</file>
<file>images/dockdock-16.png</file>
<file>images/dockdock-down-16.png</file>
+ <file>images/toolbar-ext.png</file>
+ <file>images/toolbar-ext@2x.png</file>
</qresource>
</RCC>
diff --git a/src/widgets/styles/qstyle_p.h b/src/widgets/styles/qstyle_p.h
index 6cc28b7506..70221f6d8f 100644
--- a/src/widgets/styles/qstyle_p.h
+++ b/src/widgets/styles/qstyle_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qstyleanimation.cpp b/src/widgets/styles/qstyleanimation.cpp
index 61048df96a..4fb67d90c0 100644
--- a/src/widgets/styles/qstyleanimation.cpp
+++ b/src/widgets/styles/qstyleanimation.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,13 +46,9 @@
QT_BEGIN_NAMESPACE
-QStyleAnimation::QStyleAnimation(QObject *target) : QAbstractAnimation(),
+QStyleAnimation::QStyleAnimation(QObject *target) : QAbstractAnimation(target),
_delay(0), _duration(-1), _startTime(QTime::currentTime())
{
- if (target) {
- moveToThread(target->thread());
- setParent(target);
- }
}
QStyleAnimation::~QStyleAnimation()
diff --git a/src/widgets/styles/qstyleanimation_p.h b/src/widgets/styles/qstyleanimation_p.h
index f9f0eced9d..77962bedac 100644
--- a/src/widgets/styles/qstyleanimation_p.h
+++ b/src/widgets/styles/qstyleanimation_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qstylefactory.cpp b/src/widgets/styles/qstylefactory.cpp
index 471d3b748d..2b81acf246 100644
--- a/src/widgets/styles/qstylefactory.cpp
+++ b/src/widgets/styles/qstylefactory.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -48,6 +48,9 @@
#include "qwindowsstyle_p.h"
#ifndef QT_NO_STYLE_FUSION
#include "qfusionstyle_p.h"
+#ifndef QT_NO_STYLE_ANDROID
+#include "qandroidstyle_p.h"
+#endif
#endif
#ifndef QT_NO_STYLE_GTK
#include "qgtkstyle_p.h"
@@ -143,6 +146,11 @@ QStyle *QStyleFactory::create(const QString& key)
ret = new QFusionStyle;
else
#endif
+#ifndef QT_NO_STYLE_ANDROID
+ if (style == QLatin1String("android"))
+ ret = new QAndroidStyle;
+ else
+#endif
#ifndef QT_NO_STYLE_GTK
if (style == QLatin1String("gtk") || style == QLatin1String("gtk+"))
ret = new QGtkStyle;
@@ -206,6 +214,10 @@ QStringList QStyleFactory::keys()
(QSysInfo::WindowsVersion >= QSysInfo::WV_VISTA && (QSysInfo::WindowsVersion & QSysInfo::WV_NT_based)))
list << QLatin1String("WindowsVista");
#endif
+#ifndef QT_NO_STYLE_ANDROID
+ if (!list.contains(QLatin1String("Android")))
+ list << QLatin1String("Android");
+#endif
#ifndef QT_NO_STYLE_GTK
if (!list.contains(QLatin1String("GTK+")))
list << QLatin1String("GTK+");
diff --git a/src/widgets/styles/qstylefactory.h b/src/widgets/styles/qstylefactory.h
index 500e86a9d4..539f47464b 100644
--- a/src/widgets/styles/qstylefactory.h
+++ b/src/widgets/styles/qstylefactory.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtCore/qstringlist.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -60,6 +58,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTYLEFACTORY_H
diff --git a/src/widgets/styles/qstylehelper.cpp b/src/widgets/styles/qstylehelper.cpp
index 75c74e4a88..fc73488154 100644
--- a/src/widgets/styles/qstylehelper.cpp
+++ b/src/widgets/styles/qstylehelper.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -92,7 +92,6 @@ bool isInstanceOf(QObject *obj, QAccessible::Role role)
bool match = false;
QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(obj);
match = iface && iface->role() == role;
- delete iface;
return match;
}
diff --git a/src/widgets/styles/qstylehelper_p.h b/src/widgets/styles/qstylehelper_p.h
index 01772e765c..6355cbc985 100644
--- a/src/widgets/styles/qstylehelper_p.h
+++ b/src/widgets/styles/qstylehelper_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qstyleoption.cpp b/src/widgets/styles/qstyleoption.cpp
index 01e51d594d..4f4cd71070 100644
--- a/src/widgets/styles/qstyleoption.cpp
+++ b/src/widgets/styles/qstyleoption.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -206,7 +206,7 @@ void QStyleOption::init(const QWidget *widget)
if (!(state & QStyle::State_Active) && !qt_mac_can_clickThrough(widget))
state &= ~QStyle::State_Enabled;
#endif
-#ifdef Q_OS_MAC
+#if defined(Q_OS_MAC) && !defined(Q_OS_IOS)
switch (QMacStyle::widgetSizePolicy(widget)) {
case QMacStyle::SizeSmall:
state |= QStyle::State_Small;
@@ -374,7 +374,7 @@ QStyleOption &QStyleOption::operator=(const QStyleOption &other)
parameters for drawing a focus rectangle with QStyle.
\inmodule QtWidgets
-
+
For performance reasons, the access to the member variables is
direct (i.e., using the \c . or \c -> operator). This low-level feel
makes the structures straightforward to use and emphasizes that
@@ -458,7 +458,7 @@ QStyleOptionFocusRect::QStyleOptionFocusRect(int version)
parameters for drawing a frame.
\inmodule QtWidgets
-
+
QStyleOptionFrame is used for drawing several built-in Qt widgets,
including QFrame, QGroupBox, QLineEdit, and QMenu.
@@ -738,7 +738,7 @@ QStyleOptionGroupBox::QStyleOptionGroupBox(int version)
parameters for drawing a header.
\inmodule QtWidgets
-
+
QStyleOptionHeader contains all the information that QStyle
functions need to draw the item views' header pane, header sort
arrow, and header label.
@@ -925,7 +925,7 @@ QStyleOptionHeader::QStyleOptionHeader(int version)
parameters for drawing buttons.
\inmodule QtWidgets
-
+
QStyleOptionButton contains all the information that QStyle
functions need to draw graphical elements like QPushButton,
QCheckBox, and QRadioButton.
@@ -1237,7 +1237,7 @@ QStyleOptionToolBar::QStyleOptionToolBar(int version)
parameters for drawing a tab bar.
\inmodule QtWidgets
-
+
The QStyleOptionTab class is used for drawing several built-in Qt
widgets including \l QTabBar and the panel for \l QTabWidget.
@@ -1662,7 +1662,7 @@ QStyleOptionProgressBar::QStyleOptionProgressBar(int version)
parameter necessary for drawing a menu item.
\inmodule QtWidgets
-
+
QStyleOptionMenuItem contains all the information that QStyle
functions need to draw the menu items from \l QMenu. It is also
used for drawing other menu-related widgets.
@@ -1862,7 +1862,7 @@ QStyleOptionMenuItem::QStyleOptionMenuItem(int version)
common to all complex controls.
\inmodule QtWidgets
-
+
This class is not used on its own. Instead it is used to derive
other complex control options, for example QStyleOptionSlider and
QStyleOptionSpinBox.
@@ -1953,7 +1953,7 @@ QStyleOptionComplex::QStyleOptionComplex(int version, int type)
parameters needed for drawing a slider.
\inmodule QtWidgets
-
+
QStyleOptionSlider contains all the information that QStyle
functions need to draw QSlider and QScrollBar.
@@ -2152,7 +2152,7 @@ QStyleOptionSlider::QStyleOptionSlider(int version)
parameters necessary for drawing a spin box.
\inmodule QtWidgets
-
+
QStyleOptionSpinBox contains all the information that QStyle
functions need to draw QSpinBox and QDateTimeEdit.
@@ -2257,7 +2257,7 @@ QStyleOptionSpinBox::QStyleOptionSpinBox(int version)
parameters for drawing a dock widget.
\inmodule QtWidgets
-
+
QStyleOptionDockWidget contains all the information that QStyle
functions need to draw graphical elements like QDockWidget.
diff --git a/src/widgets/styles/qstyleoption.h b/src/widgets/styles/qstyleoption.h
index 4109c8e702..4f817a3353 100644
--- a/src/widgets/styles/qstyleoption.h
+++ b/src/widgets/styles/qstyleoption.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -56,8 +56,6 @@
# include <QtCore/qabstractitemmodel.h>
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -751,6 +749,4 @@ Q_WIDGETS_EXPORT QDebug operator<<(QDebug debug, const QStyleOption &option);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTYLEOPTION_H
diff --git a/src/widgets/styles/qstylepainter.cpp b/src/widgets/styles/qstylepainter.cpp
index 1faf4a743b..5c2c44b45b 100644
--- a/src/widgets/styles/qstylepainter.cpp
+++ b/src/widgets/styles/qstylepainter.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qstylepainter.h b/src/widgets/styles/qstylepainter.h
index dee01c09a3..2031921d12 100644
--- a/src/widgets/styles/qstylepainter.h
+++ b/src/widgets/styles/qstylepainter.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtWidgets/qstyle.h>
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -106,6 +104,4 @@ void QStylePainter::drawItemPixmap(const QRect &r, int flags, const QPixmap &pix
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTYLEPAINTER_H
diff --git a/src/widgets/styles/qstyleplugin.cpp b/src/widgets/styles/qstyleplugin.cpp
index e8f9878603..77f5bd30f4 100644
--- a/src/widgets/styles/qstyleplugin.cpp
+++ b/src/widgets/styles/qstyleplugin.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qstyleplugin.h b/src/widgets/styles/qstyleplugin.h
index d34f0c0a15..041bdbfa68 100644
--- a/src/widgets/styles/qstyleplugin.h
+++ b/src/widgets/styles/qstyleplugin.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtCore/qplugin.h>
#include <QtCore/qfactoryinterface.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -66,6 +64,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTYLEPLUGIN_H
diff --git a/src/widgets/styles/qstylesheetstyle.cpp b/src/widgets/styles/qstylesheetstyle.cpp
index 7087e2a5ca..be89abf2b2 100644
--- a/src/widgets/styles/qstylesheetstyle.cpp
+++ b/src/widgets/styles/qstylesheetstyle.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qstylesheetstyle_default.cpp b/src/widgets/styles/qstylesheetstyle_default.cpp
index 2c9a72b4b4..bca4c8928a 100644
--- a/src/widgets/styles/qstylesheetstyle_default.cpp
+++ b/src/widgets/styles/qstylesheetstyle_default.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qstylesheetstyle_p.h b/src/widgets/styles/qstylesheetstyle_p.h
index a199721200..9ca3c9ed24 100644
--- a/src/widgets/styles/qstylesheetstyle_p.h
+++ b/src/widgets/styles/qstylesheetstyle_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qwindowscestyle.cpp b/src/widgets/styles/qwindowscestyle.cpp
index f297e64631..564e84b35b 100644
--- a/src/widgets/styles/qwindowscestyle.cpp
+++ b/src/widgets/styles/qwindowscestyle.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qwindowscestyle_p.h b/src/widgets/styles/qwindowscestyle_p.h
index 5d38abe41b..73fb2b7ab7 100644
--- a/src/widgets/styles/qwindowscestyle_p.h
+++ b/src/widgets/styles/qwindowscestyle_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <private/qwindowsstyle_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -98,6 +96,4 @@ public:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWINDOWSCESTYLE_P_H
diff --git a/src/widgets/styles/qwindowscestyle_p_p.h b/src/widgets/styles/qwindowscestyle_p_p.h
index 7fbf6d8160..f17aae7cbb 100644
--- a/src/widgets/styles/qwindowscestyle_p_p.h
+++ b/src/widgets/styles/qwindowscestyle_p_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qwindowsmobilestyle.cpp b/src/widgets/styles/qwindowsmobilestyle.cpp
index 2b30bf5a2d..36c5d7e1bb 100644
--- a/src/widgets/styles/qwindowsmobilestyle.cpp
+++ b/src/widgets/styles/qwindowsmobilestyle.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -90,7 +90,7 @@ static const int windowsMobileExclusiveIndicatorSize = 14;
static const int windowsMobileSliderThickness = 6;
static const int windowsMobileIconSize = 16;
static const int PE_IndicatorArrowUpBig = 0xf000101;
-static const int PE_IndicatorArrowDownBig = 0xf000102;
+static const int PE_IndicatorArrowDownBig = 0xf000102;
static const int PE_IndicatorArrowLeftBig = 0xf000103;
static const int PE_IndicatorArrowRightBig = 0xf000104;
@@ -241,7 +241,7 @@ static const char *const radiochecked_xpm[] = {
static const char * const radiochecked_low_xpm[] = {
"9 9 2 1",
" c None",
- ". c #000000",
+ ". c #000000",
" ... ",
" ....... ",
" ....... ",
@@ -3904,39 +3904,39 @@ QColor fromHsl(QColor c)
qreal ca[3] = {0, 0, 0};
if (s == 0 || h == 1) {
- // achromatic case
+ // achromatic case
ca[0] = ca[1] = ca[2] = l;
- } else {
- // chromatic case
- qreal temp2;
- if (l < qreal(0.5))
- temp2 = l * (qreal(1.0) + s);
- else
- temp2 = l + s - (l * s);
-
- const qreal temp1 = (qreal(2.0) * l) - temp2;
- qreal temp3[3] = { h + (qreal(1.0) / qreal(3.0)),
- h,
- h - (qreal(1.0) / qreal(3.0)) };
-
- for (int i = 0; i != 3; ++i) {
- if (temp3[i] < qreal(0.0))
- temp3[i] += qreal(1.0);
- else if (temp3[i] > qreal(1.0))
+ } else {
+ // chromatic case
+ qreal temp2;
+ if (l < qreal(0.5))
+ temp2 = l * (qreal(1.0) + s);
+ else
+ temp2 = l + s - (l * s);
+
+ const qreal temp1 = (qreal(2.0) * l) - temp2;
+ qreal temp3[3] = { h + (qreal(1.0) / qreal(3.0)),
+ h,
+ h - (qreal(1.0) / qreal(3.0)) };
+
+ for (int i = 0; i != 3; ++i) {
+ if (temp3[i] < qreal(0.0))
+ temp3[i] += qreal(1.0);
+ else if (temp3[i] > qreal(1.0))
temp3[i] -= qreal(1.0);
const qreal sixtemp3 = temp3[i] * qreal(6.0);
- if (sixtemp3 < qreal(1.0))
- ca[i] = ((temp1 + (temp2 - temp1) * sixtemp3));
- else if ((temp3[i] * qreal(2.0)) < qreal(1.0))
- ca[i] = (temp2);
- else if ((temp3[i] * qreal(3.0)) < qreal(2.0))
+ if (sixtemp3 < qreal(1.0))
+ ca[i] = ((temp1 + (temp2 - temp1) * sixtemp3));
+ else if ((temp3[i] * qreal(2.0)) < qreal(1.0))
+ ca[i] = (temp2);
+ else if ((temp3[i] * qreal(3.0)) < qreal(2.0))
ca[i] = temp1 + (temp2 -temp1) * (qreal(2.0) /qreal(3.0) - temp3[i]) * qreal(6.0);
else ca[i] = temp1;
}
}
-
+
return QColor::fromRgbF(ca[0], ca[1], ca[2]);
}
@@ -3945,7 +3945,7 @@ QColor fromHsl(QColor c)
QColor toHsl(QColor c)
{
- QColor color;
+ QColor color;
qreal h;
qreal s;
qreal l;
@@ -3953,36 +3953,36 @@ QColor toHsl(QColor c)
const qreal r = c.redF();
const qreal g = c.greenF();
const qreal b = c.blueF();
- const qreal max = Q_MAX_3(r, g, b);
- const qreal min = Q_MIN_3(r, g, b);
- const qreal delta = max - min;
- const qreal delta2 = max + min;
- const qreal lightness = qreal(0.5) * delta2;
+ const qreal max = Q_MAX_3(r, g, b);
+ const qreal min = Q_MIN_3(r, g, b);
+ const qreal delta = max - min;
+ const qreal delta2 = max + min;
+ const qreal lightness = qreal(0.5) * delta2;
l = (lightness);
- if (qFuzzyIsNull(delta)) {
- // achromatic case, hue is undefined
+ if (qFuzzyIsNull(delta)) {
+ // achromatic case, hue is undefined
h = 0;
- s = 0;
+ s = 0;
} else {
- // chromatic case
- qreal hue = 0;
- if (lightness < qreal(0.5))
- s = ((delta / delta2));
- else
- s = ((delta / (qreal(2.0) - delta2)));
- if (qFuzzyCompare(r, max)) {
- hue = ((g - b) /delta);
- } else if (qFuzzyCompare(g, max)) {
- hue = (2.0 + (b - r) / delta);
- } else if (qFuzzyCompare(b, max)) {
- hue = (4.0 + (r - g) / delta);
- } else {
- Q_ASSERT_X(false, "QColor::toHsv", "internal error");
+ // chromatic case
+ qreal hue = 0;
+ if (lightness < qreal(0.5))
+ s = ((delta / delta2));
+ else
+ s = ((delta / (qreal(2.0) - delta2)));
+ if (qFuzzyCompare(r, max)) {
+ hue = ((g - b) /delta);
+ } else if (qFuzzyCompare(g, max)) {
+ hue = (2.0 + (b - r) / delta);
+ } else if (qFuzzyCompare(b, max)) {
+ hue = (4.0 + (r - g) / delta);
+ } else {
+ Q_ASSERT_X(false, "QColor::toHsv", "internal error");
}
- hue *= 60.0;
- if (hue < 0.0)
- hue += 360.0;
- h = (hue * 100);
+ hue *= 60.0;
+ if (hue < 0.0)
+ hue += 360.0;
+ h = (hue * 100);
}
h = h / 36000;
@@ -4083,7 +4083,7 @@ void QWindowsMobileStylePrivate::tintListViewHighlight(QColor color)
imageListViewHighlightMiddle = QImage(listviewhighmiddle_xpm);
tintImage(&imageListViewHighlightMiddle, color, qreal(0.0));
-
+
int height = imageListViewHighlightMiddle.height();
if (!doubleControls) {
height = height / 2;
@@ -4218,7 +4218,7 @@ void QWindowsMobileStylePrivate::drawPanelItemViewSelected(QPainter *painter, co
QRect r;
if (rect.isValid())
r = rect;
- else
+ else
r = option->rect;
tintImagesHigh(option->palette.highlight().color());
@@ -4892,7 +4892,7 @@ void QWindowsMobileStyle::drawPrimitive(PrimitiveElement element, const QStyleOp
} else {
QRect r = QRect(option->rect.x(), option->rect.y(), windowsMobileitemViewCheckBoxSize, windowsMobileitemViewCheckBoxSize);
qDrawPlainRect(painter, r, option->palette.shadow().color(), 1);
- }
+ }
if (option->state & State_Enabled)
d->imageChecked.setColor(1, option->palette.shadow().color().rgba());
else
@@ -5129,7 +5129,7 @@ void QWindowsMobileStyle::drawPrimitive(PrimitiveElement element, const QStyleOp
image.setColor(1, color.rgba());
painter->drawImage(option->rect.x() + xoffset, option->rect.y() + yoffset, image);
}
- else {
+ else {
QPoint points[7];
switch (element) {
case PE_IndicatorArrowUp:
@@ -5194,7 +5194,7 @@ void QWindowsMobileStyle::drawPrimitive(PrimitiveElement element, const QStyleOp
painter->drawLine(points[2], points[3]);
painter->drawLine(points[4], points[5]);
painter->drawPoint(points[6]);
- }
+ }
}
painter->restore();
break; }
@@ -5432,7 +5432,7 @@ void QWindowsMobileStyle::drawControl(ControlElement element, const QStyleOption
QWindowsMobileStylePrivate *d = const_cast<QWindowsMobileStylePrivate*>(d_func());
-
+
painter->setClipping(false);
switch (element) {
case CE_MenuBarEmptyArea:
@@ -5527,7 +5527,7 @@ void QWindowsMobileStyle::drawControl(ControlElement element, const QStyleOption
break;
case CE_TabBarTabShape:
if (const QStyleOptionTab *tab = qstyleoption_cast<const QStyleOptionTab *>(option)) {
-
+
if (tab->shape == QTabBar::RoundedNorth || tab->shape == QTabBar::RoundedEast ||
tab->shape == QTabBar::RoundedSouth || tab->shape == QTabBar::RoundedWest) {
d->drawTabBarTab(painter, tab);
@@ -5564,7 +5564,7 @@ void QWindowsMobileStyle::drawControl(ControlElement element, const QStyleOption
proxy()->drawControl(CE_HeaderSection, header, painter, widget);
QStyleOptionHeader subopt = *header;
subopt.rect = proxy()->subElementRect(SE_HeaderLabel, header, widget);
- if (header->state & State_Sunken)
+ if (header->state & State_Sunken)
subopt.palette.setColor(QPalette::ButtonText, header->palette.brightText().color());
subopt.state |= QStyle::State_On;
if (subopt.rect.isValid())
@@ -7079,7 +7079,7 @@ int QWindowsMobileStyle::pixelMetric(PixelMetric pm, const QStyleOption *opt, co
}
break;
case PM_ScrollBarExtent: {
-
+
if (d->smartphone)
ret = 9;
else
diff --git a/src/widgets/styles/qwindowsmobilestyle_p.h b/src/widgets/styles/qwindowsmobilestyle_p.h
index 21df982344..4262bf5c73 100644
--- a/src/widgets/styles/qwindowsmobilestyle_p.h
+++ b/src/widgets/styles/qwindowsmobilestyle_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <private/qwindowsstyle_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -111,6 +109,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif //QWINDOWSMOBILESTYLE_P_H
diff --git a/src/widgets/styles/qwindowsmobilestyle_p_p.h b/src/widgets/styles/qwindowsmobilestyle_p_p.h
index d73c6eebaa..45e02fb379 100644
--- a/src/widgets/styles/qwindowsmobilestyle_p_p.h
+++ b/src/widgets/styles/qwindowsmobilestyle_p_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qwindowsstyle.cpp b/src/widgets/styles/qwindowsstyle.cpp
index 2b48096a7b..86fccabcbc 100644
--- a/src/widgets/styles/qwindowsstyle.cpp
+++ b/src/widgets/styles/qwindowsstyle.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -2358,7 +2358,6 @@ QSize QWindowsStyle::sizeFromContents(ContentsType ct, const QStyleOption *opt,
sz += QSize(QWindowsStylePrivate::windowsItemHMargin * 4, QWindowsStylePrivate::windowsItemVMargin * 2);
break;
#endif
- // Otherwise, fall through
case CT_ToolButton:
if (qstyleoption_cast<const QStyleOptionToolButton *>(opt))
return sz += QSize(7, 6);
diff --git a/src/widgets/styles/qwindowsstyle_p.h b/src/widgets/styles/qwindowsstyle_p.h
index 65573acf67..1107e70061 100644
--- a/src/widgets/styles/qwindowsstyle_p.h
+++ b/src/widgets/styles/qwindowsstyle_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qcommonstyle.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -103,6 +101,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWINDOWSSTYLE_P_H
diff --git a/src/widgets/styles/qwindowsstyle_p_p.h b/src/widgets/styles/qwindowsstyle_p_p.h
index ca77964fb8..872b6f0e9e 100644
--- a/src/widgets/styles/qwindowsstyle_p_p.h
+++ b/src/widgets/styles/qwindowsstyle_p_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qwindowsvistastyle.cpp b/src/widgets/styles/qwindowsvistastyle.cpp
index a621cab04d..f65e52305c 100644
--- a/src/widgets/styles/qwindowsvistastyle.cpp
+++ b/src/widgets/styles/qwindowsvistastyle.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -273,15 +273,15 @@ void QWindowsVistaAnimation::paint(QPainter *painter, const QStyleOption *option
/*!
\internal
-
+
Animations are used for some state transitions on specific widgets.
-
+
Only one running animation can exist for a widget at any specific
time. Animations can be added through
QWindowsVistaStylePrivate::startAnimation(Animation *) and any
existing animation on a widget can be retrieved with
QWindowsVistaStylePrivate::widgetAnimation(Widget *).
-
+
Once an animation has been started,
QWindowsVistaStylePrivate::timerEvent(QTimerEvent *) will
continuously call update() on the widget until it is stopped,
@@ -377,8 +377,9 @@ void QWindowsVistaStyle::drawPrimitive(PrimitiveElement element, const QStyleOpt
// The end state of the transition is simply the result we would have painted
// if the style was not animated.
+ styleOption->styleObject = 0;
styleOption->state = option->state;
- drawPrimitive(element, styleOption, &endPainter, widget);
+ proxy()->drawPrimitive(element, styleOption, &endPainter, widget);
t->setEndImage(endImage);
@@ -521,7 +522,8 @@ void QWindowsVistaStyle::drawPrimitive(PrimitiveElement element, const QStyleOpt
break;
case PE_Frame: {
#ifndef QT_NO_ACCESSIBILITY
- if (QStyleHelper::isInstanceOf(option->styleObject, QAccessible::EditableText)) {
+ if (QStyleHelper::isInstanceOf(option->styleObject, QAccessible::EditableText)
+ || QStyleHelper::isInstanceOf(option->styleObject, QAccessible::StaticText)) {
#else
if (false) {
#endif
@@ -536,16 +538,13 @@ void QWindowsVistaStyle::drawPrimitive(PrimitiveElement element, const QStyleOpt
XPThemeData theme(widget, painter,
QWindowsXPStylePrivate::EditTheme,
EP_EDITBORDER_HVSCROLL, stateId, option->rect);
- uint resolve_mask = option->palette.resolve();
- if (resolve_mask & (1 << QPalette::Base)) {
- // Since EP_EDITBORDER_HVSCROLL does not us borderfill, theme.noContent cannot be used for clipping
- int borderSize = 1;
- pGetThemeInt(theme.handle(), theme.partId, theme.stateId, TMT_BORDERSIZE, &borderSize);
- QRegion clipRegion = option->rect;
- QRegion content = option->rect.adjusted(borderSize, borderSize, -borderSize, -borderSize);
- clipRegion ^= content;
- painter->setClipRegion(clipRegion);
- }
+ // Since EP_EDITBORDER_HVSCROLL does not us borderfill, theme.noContent cannot be used for clipping
+ int borderSize = 1;
+ pGetThemeInt(theme.handle(), theme.partId, theme.stateId, TMT_BORDERSIZE, &borderSize);
+ QRegion clipRegion = option->rect;
+ QRegion content = option->rect.adjusted(borderSize, borderSize, -borderSize, -borderSize);
+ clipRegion ^= content;
+ painter->setClipRegion(clipRegion);
d->drawBackground(theme);
painter->restore();
} else {
@@ -798,17 +797,17 @@ void QWindowsVistaStyle::drawPrimitive(PrimitiveElement element, const QStyleOpt
|| vopt->viewItemPosition == QStyleOptionViewItem::Invalid)
painter->drawPixmap(pixmapRect.topLeft(), pixmap);
else if (reverse ? rightSection : leftSection){
- painter->drawPixmap(QRect(pixmapRect.topLeft(),
- QSize(frame, pixmapRect.height())), pixmap,
+ painter->drawPixmap(QRect(pixmapRect.topLeft(),
+ QSize(frame, pixmapRect.height())), pixmap,
QRect(QPoint(0, 0), QSize(frame, pixmapRect.height())));
- painter->drawPixmap(pixmapRect.adjusted(frame, 0, 0, 0),
+ painter->drawPixmap(pixmapRect.adjusted(frame, 0, 0, 0),
pixmap, srcRect.adjusted(frame, 0, -frame, 0));
} else if (reverse ? leftSection : rightSection) {
- painter->drawPixmap(QRect(pixmapRect.topRight() - QPoint(frame - 1, 0),
- QSize(frame, pixmapRect.height())), pixmap,
- QRect(QPoint(pixmapRect.width() - frame, 0),
+ painter->drawPixmap(QRect(pixmapRect.topRight() - QPoint(frame - 1, 0),
+ QSize(frame, pixmapRect.height())), pixmap,
+ QRect(QPoint(pixmapRect.width() - frame, 0),
QSize(frame, pixmapRect.height())));
- painter->drawPixmap(pixmapRect.adjusted(0, 0, -frame, 0),
+ painter->drawPixmap(pixmapRect.adjusted(0, 0, -frame, 0),
pixmap, srcRect.adjusted(frame, 0, -frame, 0));
} else if (vopt->viewItemPosition == QStyleOptionViewItem::Middle)
painter->drawPixmap(pixmapRect, pixmap,
@@ -1110,7 +1109,7 @@ void QWindowsVistaStyle::drawControl(ControlElement element, const QStyleOption
} else {
animRect = QRect(rect.left() - glowSize + animOffset,
rect.top(), glowSize, rect.height());
- animRect = QStyle::visualRect(reverse ? Qt::RightToLeft : Qt::LeftToRight,
+ animRect = QStyle::visualRect(reverse ? Qt::RightToLeft : Qt::LeftToRight,
option->rect, animRect);
pixmapSize.setWidth(animRect.width());
}
@@ -1156,7 +1155,7 @@ void QWindowsVistaStyle::drawControl(ControlElement element, const QStyleOption
double vc6_workaround = ((progress - qint64(bar->minimum)) / qMax(double(1.0), double(qint64(bar->maximum) - qint64(bar->minimum))) * maxWidth);
int width = isIndeterminate ? maxWidth : qMax(int(vc6_workaround), minWidth);
theme.rect.setWidth(width);
- theme.rect = QStyle::visualRect(reverse ? Qt::RightToLeft : Qt::LeftToRight,
+ theme.rect = QStyle::visualRect(reverse ? Qt::RightToLeft : Qt::LeftToRight,
option->rect, theme.rect);
}
d->drawBackground(theme);
@@ -1522,7 +1521,7 @@ void QWindowsVistaStyle::drawControl(ControlElement element, const QStyleOption
QStyleOptionViewItem adjustedOption = *vopt;
adjustedOption.palette = palette;
// We hide the focusrect in singleselection as it is not required
- if ((view->selectionMode() == QAbstractItemView::SingleSelection)
+ if ((view->selectionMode() == QAbstractItemView::SingleSelection)
&& !(vopt->state & State_KeyboardFocusChange))
adjustedOption.state &= ~State_HasFocus;
QWindowsXPStyle::drawControl(element, &adjustedOption, painter, widget);
@@ -1585,7 +1584,7 @@ void QWindowsVistaStyle::drawComplexControl(ComplexControl control, const QStyle
bool doTransition = ((state & State_Sunken) != (oldState & State_Sunken) ||
(state & State_On) != (oldState & State_On) ||
(state & State_MouseOver) != (oldState & State_MouseOver) ||
- oldActiveControls != option->activeSubControls);
+ oldActiveControls != int(option->activeSubControls));
if (qstyleoption_cast<const QStyleOptionSlider *>(option)) {
QRect oldSliderPos = styleObject->property("_q_stylesliderpos").toRect();
@@ -1944,7 +1943,7 @@ QSize QWindowsVistaStyle::sizeFromContents(ContentsType type, const QStyleOption
minimumHeight = qMax<qint32>(size.cy + margins.cyBottomHeight+ margins.cyTopHeight, sz.height());
sz.rwidth() += size.cx + margins.cxLeftWidth + margins.cxRightWidth;
}
-
+
if (const QStyleOptionMenuItem *menuitem = qstyleoption_cast<const QStyleOptionMenuItem *>(option)) {
if (menuitem->menuItemType != QStyleOptionMenuItem::Separator)
sz.setHeight(minimumHeight);
diff --git a/src/widgets/styles/qwindowsvistastyle_p.h b/src/widgets/styles/qwindowsvistastyle_p.h
index 2a06c78806..f7914f1645 100644
--- a/src/widgets/styles/qwindowsvistastyle_p.h
+++ b/src/widgets/styles/qwindowsvistastyle_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <private/qwindowsxpstyle_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -99,6 +97,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWINDOWSVISTASTYLE_P_H
diff --git a/src/widgets/styles/qwindowsvistastyle_p_p.h b/src/widgets/styles/qwindowsvistastyle_p_p.h
index 17d510abf2..f2f208fbb5 100644
--- a/src/widgets/styles/qwindowsvistastyle_p_p.h
+++ b/src/widgets/styles/qwindowsvistastyle_p_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qwindowsxpstyle.cpp b/src/widgets/styles/qwindowsxpstyle.cpp
index 8bd5699e4a..64569cfd9b 100644
--- a/src/widgets/styles/qwindowsxpstyle.cpp
+++ b/src/widgets/styles/qwindowsxpstyle.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/qwindowsxpstyle_p.h b/src/widgets/styles/qwindowsxpstyle_p.h
index 626bcc4ad7..d61132295c 100644
--- a/src/widgets/styles/qwindowsxpstyle_p.h
+++ b/src/widgets/styles/qwindowsxpstyle_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <private/qwindowsstyle_p.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -99,6 +97,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWINDOWSXPSTYLE_P_H
diff --git a/src/widgets/styles/qwindowsxpstyle_p_p.h b/src/widgets/styles/qwindowsxpstyle_p_p.h
index 234b8e8a59..783adc3085 100644
--- a/src/widgets/styles/qwindowsxpstyle_p_p.h
+++ b/src/widgets/styles/qwindowsxpstyle_p_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/styles/styles.pri b/src/widgets/styles/styles.pri
index b15eb1fa48..b39b17fd86 100644
--- a/src/widgets/styles/styles.pri
+++ b/src/widgets/styles/styles.pri
@@ -40,7 +40,7 @@ contains( styles, all ) {
styles = fusion mac windows windowsxp windowsvista
}
-!macx-*|ios:styles -= mac
+!macx:styles -= mac
contains(QT_CONFIG, gtkstyle) {
QMAKE_CXXFLAGS += $$QT_CFLAGS_QGTKSTYLE
@@ -52,7 +52,6 @@ contains(QT_CONFIG, gtkstyle) {
contains( styles, mac ) {
HEADERS += \
styles/qmacstyle_mac_p.h \
- styles/qmacstylepixmaps_mac_p.h \
styles/qmacstyle_mac_p_p.h
OBJECTIVE_SOURCES += styles/qmacstyle_mac.mm
@@ -136,3 +135,10 @@ contains( styles, windowsmobile ) {
} else {
DEFINES += QT_NO_STYLE_WINDOWSMOBILE
}
+
+contains( styles, android ) {
+ HEADERS += styles/qandroidstyle_p.h
+ SOURCES += styles/qandroidstyle.cpp
+} else {
+ DEFINES += QT_NO_STYLE_ANDROID
+}
diff --git a/src/widgets/util/qcolormap.cpp b/src/widgets/util/qcolormap.cpp
index 24457520c4..03ee8a395e 100644
--- a/src/widgets/util/qcolormap.cpp
+++ b/src/widgets/util/qcolormap.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qcolormap.h b/src/widgets/util/qcolormap.h
index d3b9535923..b869bd9555 100644
--- a/src/widgets/util/qcolormap.h
+++ b/src/widgets/util/qcolormap.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtCore/qvector.h>
#include <QtGui/qwindowdefs.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -91,6 +89,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOLORMAP_H
diff --git a/src/widgets/util/qcolormap.qdoc b/src/widgets/util/qcolormap.qdoc
index 48fe1c7eec..ae337b511c 100644
--- a/src/widgets/util/qcolormap.qdoc
+++ b/src/widgets/util/qcolormap.qdoc
@@ -67,7 +67,7 @@
/*!
\fn QColormap::~QColormap()
-
+
Destroys the colormap.
*/
diff --git a/src/widgets/util/qcompleter.cpp b/src/widgets/util/qcompleter.cpp
index d8186d795d..64b7b12e90 100644
--- a/src/widgets/util/qcompleter.cpp
+++ b/src/widgets/util/qcompleter.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,7 +45,7 @@
\since 4.2
\inmodule QtWidgets
-
+
You can use QCompleter to provide auto completions in any Qt
widget, such as QLineEdit and QComboBox.
When the user starts typing a word, QCompleter suggests possible ways of
diff --git a/src/widgets/util/qcompleter.h b/src/widgets/util/qcompleter.h
index ba43e4470a..737d9f5fba 100644
--- a/src/widgets/util/qcompleter.h
+++ b/src/widgets/util/qcompleter.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -48,8 +48,6 @@
#include <QtCore/qabstractitemmodel.h>
#include <QtCore/qrect.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -165,6 +163,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOMPLETER_H
diff --git a/src/widgets/util/qcompleter_p.h b/src/widgets/util/qcompleter_p.h
index 1eb2002319..26d539a57b 100644
--- a/src/widgets/util/qcompleter_p.h
+++ b/src/widgets/util/qcompleter_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qflickgesture.cpp b/src/widgets/util/qflickgesture.cpp
index 980f144a0f..b0cd4a9540 100644
--- a/src/widgets/util/qflickgesture.cpp
+++ b/src/widgets/util/qflickgesture.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qflickgesture_p.h b/src/widgets/util/qflickgesture_p.h
index 04cf847860..49a8049d44 100644
--- a/src/widgets/util/qflickgesture_p.h
+++ b/src/widgets/util/qflickgesture_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qscroller.cpp b/src/widgets/util/qscroller.cpp
index 1670d0ab57..0a58711b92 100644
--- a/src/widgets/util/qscroller.cpp
+++ b/src/widgets/util/qscroller.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -237,7 +237,7 @@ private:
\since 5.0
\inmodule QtWidgets
-
+
With kinetic scrolling, the user can push the widget in a given
direction and it will continue to scroll in this direction until it is
stopped either by the user or by friction. Aspects of inertia, friction
diff --git a/src/widgets/util/qscroller.h b/src/widgets/util/qscroller.h
index b0ff9dc5c5..1b382f3d31 100644
--- a/src/widgets/util/qscroller.h
+++ b/src/widgets/util/qscroller.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtCore/QPointF>
#include <QtWidgets/QScrollerProperties>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -149,6 +147,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSCROLLER_H
diff --git a/src/widgets/util/qscroller_mac.mm b/src/widgets/util/qscroller_mac.mm
index 4bde960ecd..0f9f2a028c 100644
--- a/src/widgets/util/qscroller_mac.mm
+++ b/src/widgets/util/qscroller_mac.mm
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qscroller_p.h b/src/widgets/util/qscroller_p.h
index 73f5814291..a12c364960 100644
--- a/src/widgets/util/qscroller_p.h
+++ b/src/widgets/util/qscroller_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qscrollerproperties.cpp b/src/widgets/util/qscrollerproperties.cpp
index ed593ea2cb..cebb054a53 100644
--- a/src/widgets/util/qscrollerproperties.cpp
+++ b/src/widgets/util/qscrollerproperties.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -94,7 +94,7 @@ QScrollerPropertiesPrivate *QScrollerPropertiesPrivate::defaults()
\since 4.8
\inmodule QtWidgets
-
+
The QScrollerProperties class stores the parameters used by QScroller.
The default settings are platform dependent so that Qt emulates the
diff --git a/src/widgets/util/qscrollerproperties.h b/src/widgets/util/qscrollerproperties.h
index 58bce74bca..eb34c9701e 100644
--- a/src/widgets/util/qscrollerproperties.h
+++ b/src/widgets/util/qscrollerproperties.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtCore/QMetaType>
#include <QtCore/QVariant>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -134,6 +132,4 @@ QT_END_NAMESPACE
Q_DECLARE_METATYPE(QScrollerProperties::OvershootPolicy)
Q_DECLARE_METATYPE(QScrollerProperties::FrameRates)
-QT_END_HEADER
-
#endif // QSCROLLERPROPERTIES_H
diff --git a/src/widgets/util/qscrollerproperties_p.h b/src/widgets/util/qscrollerproperties_p.h
index 8abe7c7a2e..4d962b6b78 100644
--- a/src/widgets/util/qscrollerproperties_p.h
+++ b/src/widgets/util/qscrollerproperties_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qsystemtrayicon.cpp b/src/widgets/util/qsystemtrayicon.cpp
index a5d3aedf76..f74d88f6a0 100644
--- a/src/widgets/util/qsystemtrayicon.cpp
+++ b/src/widgets/util/qsystemtrayicon.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -81,7 +81,7 @@ QT_BEGIN_NAMESPACE
tray specification, including recent versions of KDE and GNOME.
\li All supported versions of Mac OS X. Note that the Growl
notification system must be installed for
- QSystemTrayIcon::showMessage() to display messages.
+ QSystemTrayIcon::showMessage() to display messages on Mac OS X prior to 10.8 (Mountain Lion).
\endlist
To check whether a system tray is present on the user's desktop,
@@ -379,7 +379,7 @@ bool QSystemTrayIcon::supportsMessages()
On Mac OS X, the Growl notification system must be installed for this function to
display messages.
-
+
\sa show(), supportsMessages()
*/
void QSystemTrayIcon::showMessage(const QString& title, const QString& msg,
diff --git a/src/widgets/util/qsystemtrayicon.h b/src/widgets/util/qsystemtrayicon.h
index 201ea85253..278efae586 100644
--- a/src/widgets/util/qsystemtrayicon.h
+++ b/src/widgets/util/qsystemtrayicon.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -48,8 +48,6 @@
#include <QtGui/qicon.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -126,7 +124,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_SYSTEMTRAYICON
#endif // QSYSTEMTRAYICON_H
diff --git a/src/widgets/util/qsystemtrayicon_p.h b/src/widgets/util/qsystemtrayicon_p.h
index c61ba733e9..211ef308f1 100644
--- a/src/widgets/util/qsystemtrayicon_p.h
+++ b/src/widgets/util/qsystemtrayicon_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qsystemtrayicon_qpa.cpp b/src/widgets/util/qsystemtrayicon_qpa.cpp
index 113f0b68b2..3ce89e352d 100644
--- a/src/widgets/util/qsystemtrayicon_qpa.cpp
+++ b/src/widgets/util/qsystemtrayicon_qpa.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qsystemtrayicon_win.cpp b/src/widgets/util/qsystemtrayicon_win.cpp
index 209fb206e1..d273060f7b 100644
--- a/src/widgets/util/qsystemtrayicon_win.cpp
+++ b/src/widgets/util/qsystemtrayicon_win.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -117,7 +117,7 @@ public:
bool trayMessage(DWORD msg);
void setIconContents(NOTIFYICONDATA &data);
bool showMessage(const QString &title, const QString &message, QSystemTrayIcon::MessageIcon type, uint uSecs);
- QRect findIconGeometry(const int a_iButtonID);
+ QRect findIconGeometry(UINT iconId);
HICON createIcon();
bool winEvent(MSG *m, long *result);
@@ -345,12 +345,12 @@ bool QSystemTrayIconSys::winEvent( MSG *m, long *result )
case NIN_KEYSELECT:
if (ignoreNextMouseRelease)
ignoreNextMouseRelease = false;
- else
+ else
emit q->activated(QSystemTrayIcon::Trigger);
break;
case WM_LBUTTONDBLCLK:
- ignoreNextMouseRelease = true; // Since DBLCLICK Generates a second mouse
+ ignoreNextMouseRelease = true; // Since DBLCLICK Generates a second mouse
// release we must ignore it
emit q->activated(QSystemTrayIcon::DoubleClick);
break;
@@ -413,8 +413,15 @@ void QSystemTrayIconPrivate::install_sys()
*
* If it fails an invalid rect is returned.
*/
-QRect QSystemTrayIconSys::findIconGeometry(const int iconId)
+
+QRect QSystemTrayIconSys::findIconGeometry(UINT iconId)
{
+ struct AppData
+ {
+ HWND hwnd;
+ UINT uID;
+ };
+
static PtrShell_NotifyIconGetRect Shell_NotifyIconGetRect =
(PtrShell_NotifyIconGetRect)QSystemLibrary::resolve(QLatin1String("shell32"),
"Shell_NotifyIconGetRect");
@@ -474,21 +481,18 @@ QRect QSystemTrayIconSys::findIconGeometry(const int iconId)
//search for our icon among all toolbar buttons
for (int toolbarButton = 0; toolbarButton < buttonCount; ++toolbarButton ) {
SIZE_T numBytes = 0;
- DWORD appData[2] = { 0, 0 };
+ AppData appData = { 0, 0 };
SendMessage(trayHandle, TB_GETBUTTON, toolbarButton , (LPARAM)data);
if (!ReadProcessMemory(trayProcess, data, &buttonData, sizeof(TBBUTTON), &numBytes))
continue;
- if (!ReadProcessMemory(trayProcess, (LPVOID) buttonData.dwData, appData, sizeof(appData), &numBytes))
+ if (!ReadProcessMemory(trayProcess, (LPVOID) buttonData.dwData, &appData, sizeof(AppData), &numBytes))
continue;
- int currentIconId = appData[1];
- HWND currentIconHandle = (HWND) appData[0];
bool isHidden = buttonData.fsState & TBSTATE_HIDDEN;
- if (currentIconHandle == m_hwnd &&
- currentIconId == iconId && !isHidden) {
+ if (m_hwnd == appData.hwnd && appData.uID == iconId && !isHidden) {
SendMessage(trayHandle, TB_GETITEMRECT, toolbarButton , (LPARAM)data);
RECT iconRect = {0, 0, 0, 0};
if(ReadProcessMemory(trayProcess, data, &iconRect, sizeof(RECT), &numBytes)) {
diff --git a/src/widgets/util/qsystemtrayicon_wince.cpp b/src/widgets/util/qsystemtrayicon_wince.cpp
index b6937aee2f..6347ee6c04 100644
--- a/src/widgets/util/qsystemtrayicon_wince.cpp
+++ b/src/widgets/util/qsystemtrayicon_wince.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -166,7 +166,7 @@ bool QSystemTrayIconSys::winEvent( MSG *m, long *result )
break;
case WM_LBUTTONDBLCLK:
- ignoreNextMouseRelease = true; // Since DBLCLICK Generates a second mouse
+ ignoreNextMouseRelease = true; // Since DBLCLICK Generates a second mouse
// release we must ignore it
emit q->activated(QSystemTrayIcon::DoubleClick);
break;
diff --git a/src/widgets/util/qsystemtrayicon_x11.cpp b/src/widgets/util/qsystemtrayicon_x11.cpp
index 7d2b94ef11..e04656974d 100644
--- a/src/widgets/util/qsystemtrayicon_x11.cpp
+++ b/src/widgets/util/qsystemtrayicon_x11.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qundogroup.cpp b/src/widgets/util/qundogroup.cpp
index 7a524cf416..57563c434b 100644
--- a/src/widgets/util/qundogroup.cpp
+++ b/src/widgets/util/qundogroup.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qundogroup.h b/src/widgets/util/qundogroup.h
index 8e888f993b..9a961d7eda 100644
--- a/src/widgets/util/qundogroup.h
+++ b/src/widgets/util/qundogroup.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtCore/qobject.h>
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QUndoGroupPrivate;
@@ -104,6 +102,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QUNDOGROUP_H
diff --git a/src/widgets/util/qundostack.cpp b/src/widgets/util/qundostack.cpp
index 77726adf27..46730ef7bd 100644
--- a/src/widgets/util/qundostack.cpp
+++ b/src/widgets/util/qundostack.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -54,7 +54,7 @@ QT_BEGIN_NAMESPACE
\since 4.2
\inmodule QtWidgets
-
+
For an overview of Qt's Undo Framework, see the
\l{Overview of Qt's Undo Framework}{overview document}.
@@ -324,7 +324,7 @@ const QUndoCommand *QUndoCommand::child(int index) const
\since 4.2
\inmodule QtWidgets
-
+
For an overview of Qt's Undo Framework, see the
\l{Overview of Qt's Undo Framework}{overview document}.
@@ -1009,7 +1009,7 @@ void QUndoStack::endMacro()
This function returns a const pointer, because modifying a command,
once it has been pushed onto the stack and executed, almost always
- causes corruption of the state of the document, if the command is
+ causes corruption of the state of the document, if the command is
later undone or redone.
\sa QUndoCommand::child()
diff --git a/src/widgets/util/qundostack.h b/src/widgets/util/qundostack.h
index 44b8337f57..4756ca314f 100644
--- a/src/widgets/util/qundostack.h
+++ b/src/widgets/util/qundostack.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtCore/qobject.h>
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -153,6 +151,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QUNDOSTACK_H
diff --git a/src/widgets/util/qundostack_p.h b/src/widgets/util/qundostack_p.h
index 7299a38b4d..039350ea90 100644
--- a/src/widgets/util/qundostack_p.h
+++ b/src/widgets/util/qundostack_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qundoview.cpp b/src/widgets/util/qundoview.cpp
index 3b1b2e1117..a7d89e7749 100644
--- a/src/widgets/util/qundoview.cpp
+++ b/src/widgets/util/qundoview.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/util/qundoview.h b/src/widgets/util/qundoview.h
index bc262799d9..80a0548bce 100644
--- a/src/widgets/util/qundoview.h
+++ b/src/widgets/util/qundoview.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#ifndef QT_NO_UNDOVIEW
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
class QUndoViewPrivate;
@@ -95,7 +93,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_UNDOVIEW
#endif // QUNDOVIEW_H
diff --git a/src/widgets/util/util.pri b/src/widgets/util/util.pri
index 5847b12166..598a3082c0 100644
--- a/src/widgets/util/util.pri
+++ b/src/widgets/util/util.pri
@@ -36,6 +36,6 @@ win32:!wince* {
SOURCES += util/qsystemtrayicon_qpa.cpp
}
-macx {
+mac {
OBJECTIVE_SOURCES += util/qscroller_mac.mm
}
diff --git a/src/widgets/widgets.pro b/src/widgets/widgets.pro
index 6b9aa92fd9..18a4d57900 100644
--- a/src/widgets/widgets.pro
+++ b/src/widgets/widgets.pro
@@ -32,7 +32,7 @@ QMAKE_LIBS += $$QMAKE_LIBS_GUI
contains(DEFINES,QT_EVAL):include($$QT_SOURCE_TREE/src/corelib/eval.pri)
-QMAKE_DYNAMIC_LIST_FILE = $$PWD/QtGui.dynlist
+QMAKE_DYNAMIC_LIST_FILE = $$PWD/QtWidgets.dynlist
# Code coverage with TestCocoon
# The following is required as extra compilers use $$QMAKE_CXX instead of $(CXX).
diff --git a/src/widgets/widgets/qabstractbutton.cpp b/src/widgets/widgets/qabstractbutton.cpp
index 5e9d100214..3f9b28a883 100644
--- a/src/widgets/widgets/qabstractbutton.cpp
+++ b/src/widgets/widgets/qabstractbutton.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -380,7 +380,7 @@ void QAbstractButtonPrivate::moveFocus(int key)
QAbstractButton *fb = qobject_cast<QAbstractButton *>(f);
if (!fb || !buttonList.contains(fb))
return;
-
+
QAbstractButton *candidate = 0;
int bestScore = -1;
QRect target = f->rect().translated(f->mapToGlobal(QPoint(0,0)));
diff --git a/src/widgets/widgets/qabstractbutton.h b/src/widgets/widgets/qabstractbutton.h
index 9c27e3523f..4732f461e4 100644
--- a/src/widgets/widgets/qabstractbutton.h
+++ b/src/widgets/widgets/qabstractbutton.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtGui/qkeysequence.h>
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -155,6 +153,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QABSTRACTBUTTON_H
diff --git a/src/widgets/widgets/qabstractbutton_p.h b/src/widgets/widgets/qabstractbutton_p.h
index 2e347ae933..4585728848 100644
--- a/src/widgets/widgets/qabstractbutton_p.h
+++ b/src/widgets/widgets/qabstractbutton_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qabstractscrollarea.cpp b/src/widgets/widgets/qabstractscrollarea.cpp
index 391a06917c..900e95f4da 100644
--- a/src/widgets/widgets/qabstractscrollarea.cpp
+++ b/src/widgets/widgets/qabstractscrollarea.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -452,7 +452,7 @@ void QAbstractScrollAreaPrivate::layoutChildren()
// no corner widget. Also, on the Mac we paint if there is a native
// (transparent) sizegrip in the area where a corner widget would be.
if ((needv && needh && hasCornerWidget == false && scrollOverlap == 0)
- || ((needv || needh)
+ || ((needv || needh)
#ifdef Q_WS_MAC
&& hasMacSizeGrip
#endif
diff --git a/src/widgets/widgets/qabstractscrollarea.h b/src/widgets/widgets/qabstractscrollarea.h
index 79038e9fdd..ccf16b5e5c 100644
--- a/src/widgets/widgets/qabstractscrollarea.h
+++ b/src/widgets/widgets/qabstractscrollarea.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qframe.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -140,6 +138,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QABSTRACTSCROLLAREA_H
diff --git a/src/widgets/widgets/qabstractscrollarea_p.h b/src/widgets/widgets/qabstractscrollarea_p.h
index 2766211732..34d767fe29 100644
--- a/src/widgets/widgets/qabstractscrollarea_p.h
+++ b/src/widgets/widgets/qabstractscrollarea_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qabstractslider.cpp b/src/widgets/widgets/qabstractslider.cpp
index 5932e1be9b..8c3dedb84f 100644
--- a/src/widgets/widgets/qabstractslider.cpp
+++ b/src/widgets/widgets/qabstractslider.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -724,7 +724,7 @@ bool QAbstractSliderPrivate::scrollByDelta(Qt::Orientation orientation, Qt::Keyb
#else
// Native UI-elements on Mac can scroll hundreds of lines at a time as
// a result of acceleration. So keep the same behaviour in Qt, and
- // don't restrict stepsToScroll to certain maximum (pageStep):
+ // don't restrict stepsToScroll to certain maximum (pageStep):
stepsToScroll = int(offset_accumulated);
#endif
offset_accumulated -= int(offset_accumulated);
diff --git a/src/widgets/widgets/qabstractslider.h b/src/widgets/widgets/qabstractslider.h
index a49970a2d5..82c8f409a0 100644
--- a/src/widgets/widgets/qabstractslider.h
+++ b/src/widgets/widgets/qabstractslider.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -163,6 +161,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QABSTRACTSLIDER_H
diff --git a/src/widgets/widgets/qabstractslider_p.h b/src/widgets/widgets/qabstractslider_p.h
index 42f25501b1..35ee934096 100644
--- a/src/widgets/widgets/qabstractslider_p.h
+++ b/src/widgets/widgets/qabstractslider_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -87,7 +87,7 @@ public:
QBasicTimer repeatActionTimer;
int repeatActionTime;
QAbstractSlider::SliderAction repeatAction;
-
+
#ifdef QT_KEYPAD_NAVIGATION
int origValue;
diff --git a/src/widgets/widgets/qabstractspinbox.cpp b/src/widgets/widgets/qabstractspinbox.cpp
index 14d22c458b..765dcb8981 100644
--- a/src/widgets/widgets/qabstractspinbox.cpp
+++ b/src/widgets/widgets/qabstractspinbox.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -825,14 +825,13 @@ QSize QAbstractSpinBox::sizeHint() const
ensurePolished();
const QFontMetrics fm(fontMetrics());
- int h = d->edit->sizeHint().height() + 4;
+ int h = d->edit->sizeHint().height();
int w = 0;
QString s;
- s = d->prefix + d->textFromValue(d->minimum) + d->suffix + QLatin1Char(' ');
- s.truncate(18);
+ QString fixedContent = d->prefix + d->suffix + QLatin1Char(' ');
+ s = d->textFromValue(d->minimum) + fixedContent;
w = qMax(w, fm.width(s));
- s = d->prefix + d->textFromValue(d->maximum) + d->suffix + QLatin1Char(' ');
- s.truncate(18);
+ s = d->textFromValue(d->maximum) + fixedContent;
w = qMax(w, fm.width(s));
if (d->specialValueText.size()) {
s = d->specialValueText;
@@ -857,27 +856,29 @@ QSize QAbstractSpinBox::minimumSizeHint() const
{
Q_D(const QAbstractSpinBox);
if (d->cachedMinimumSizeHint.isEmpty()) {
+ //Use the prefix and range to calculate the minimumSizeHint
ensurePolished();
const QFontMetrics fm(fontMetrics());
int h = d->edit->minimumSizeHint().height();
- int w = fm.width(QLatin1String("1000"));
+ int w = 0;
+
+ QString s;
+ QString fixedContent = d->prefix + QLatin1Char(' ');
+ s = d->textFromValue(d->minimum) + fixedContent;
+ w = qMax(w, fm.width(s));
+ s = d->textFromValue(d->maximum) + fixedContent;
+ w = qMax(w, fm.width(s));
+
+ if (d->specialValueText.size()) {
+ s = d->specialValueText;
+ w = qMax(w, fm.width(s));
+ }
w += 2; // cursor blinking space
QStyleOptionSpinBox opt;
initStyleOption(&opt);
QSize hint(w, h);
- QSize extra(35, 6);
- opt.rect.setSize(hint + extra);
- extra += hint - style()->subControlRect(QStyle::CC_SpinBox, &opt,
- QStyle::SC_SpinBoxEditField, this).size();
- // get closer to final result by repeating the calculation
- opt.rect.setSize(hint + extra);
- extra += hint - style()->subControlRect(QStyle::CC_SpinBox, &opt,
- QStyle::SC_SpinBoxEditField, this).size();
- hint += extra;
-
- opt.rect = rect();
d->cachedMinimumSizeHint = style()->sizeFromContents(QStyle::CT_SpinBox, &opt, hint, this)
.expandedTo(QApplication::globalStrut());
@@ -1724,7 +1725,8 @@ void QAbstractSpinBoxPrivate::setRange(const QVariant &min, const QVariant &max)
clearCache();
minimum = min;
maximum = (variantCompare(min, max) < 0 ? max : min);
- cachedSizeHint = QSize(); // minimumSizeHint doesn't care about min/max
+ cachedSizeHint = QSize();
+ cachedMinimumSizeHint = QSize(); // minimumSizeHint cares about min/max
reset();
if (!(bound(value) == value)) {
diff --git a/src/widgets/widgets/qabstractspinbox.h b/src/widgets/widgets/qabstractspinbox.h
index 49cd8f38f1..4f6aad0cde 100644
--- a/src/widgets/widgets/qabstractspinbox.h
+++ b/src/widgets/widgets/qabstractspinbox.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qwidget.h>
#include <QtGui/qvalidator.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -175,6 +173,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QAbstractSpinBox::StepEnabled)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QABSTRACTSPINBOX_H
diff --git a/src/widgets/widgets/qabstractspinbox_p.h b/src/widgets/widgets/qabstractspinbox_p.h
index d4484b7a56..0eeec02abc 100644
--- a/src/widgets/widgets/qabstractspinbox_p.h
+++ b/src/widgets/widgets/qabstractspinbox_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qbuttongroup.cpp b/src/widgets/widgets/qbuttongroup.cpp
index 3da81f8360..f22910007f 100644
--- a/src/widgets/widgets/qbuttongroup.cpp
+++ b/src/widgets/widgets/qbuttongroup.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -139,7 +139,7 @@
\fn void QButtonGroup::buttonPressed(QAbstractButton *button)
\since 4.2
- This signal is emitted when the given \a button is pressed down.
+ This signal is emitted when the given \a button is pressed down.
\sa QAbstractButton::pressed()
*/
@@ -158,7 +158,7 @@
\fn void QButtonGroup::buttonReleased(QAbstractButton *button)
\since 4.2
- This signal is emitted when the given \a button is released.
+ This signal is emitted when the given \a button is released.
\sa QAbstractButton::released()
*/
diff --git a/src/widgets/widgets/qbuttongroup.h b/src/widgets/widgets/qbuttongroup.h
index 76ce549d95..84fe26e0df 100644
--- a/src/widgets/widgets/qbuttongroup.h
+++ b/src/widgets/widgets/qbuttongroup.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtCore/qobject.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -100,6 +98,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QBUTTONGROUP_H
diff --git a/src/widgets/widgets/qcalendartextnavigator_p.h b/src/widgets/widgets/qcalendartextnavigator_p.h
index b153e4a24e..88bd3c6a71 100644
--- a/src/widgets/widgets/qcalendartextnavigator_p.h
+++ b/src/widgets/widgets/qcalendartextnavigator_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qcalendarwidget.cpp b/src/widgets/widgets/qcalendarwidget.cpp
index 0fdf039bc3..82c5a29497 100644
--- a/src/widgets/widgets/qcalendarwidget.cpp
+++ b/src/widgets/widgets/qcalendarwidget.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -2591,7 +2591,7 @@ QCalendarWidget::HorizontalHeaderFormat QCalendarWidget::horizontalHeaderFormat(
}
-/*!
+/*!
\enum QCalendarWidget::VerticalHeaderFormat
This enum type defines the various formats the vertical header can display.
diff --git a/src/widgets/widgets/qcalendarwidget.h b/src/widgets/widgets/qcalendarwidget.h
index 5d4c1722b4..4a4d21ebd6 100644
--- a/src/widgets/widgets/qcalendarwidget.h
+++ b/src/widgets/widgets/qcalendarwidget.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qwidget.h>
#include <QtCore/qdatetime.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -191,7 +189,5 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCALENDARWIDGET_H
diff --git a/src/widgets/widgets/qcheckbox.cpp b/src/widgets/widgets/qcheckbox.cpp
index fb8ed6c890..50d0ab8276 100644
--- a/src/widgets/widgets/qcheckbox.cpp
+++ b/src/widgets/widgets/qcheckbox.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qcheckbox.h b/src/widgets/widgets/qcheckbox.h
index 1bf1bf56a0..9adf5f6567 100644
--- a/src/widgets/widgets/qcheckbox.h
+++ b/src/widgets/widgets/qcheckbox.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qabstractbutton.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -92,6 +90,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCHECKBOX_H
diff --git a/src/widgets/widgets/qcocoatoolbardelegate_mac.mm b/src/widgets/widgets/qcocoatoolbardelegate_mac.mm
index 2b637bc93c..2ea66b0d40 100644
--- a/src/widgets/widgets/qcocoatoolbardelegate_mac.mm
+++ b/src/widgets/widgets/qcocoatoolbardelegate_mac.mm
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qcocoatoolbardelegate_mac_p.h b/src/widgets/widgets/qcocoatoolbardelegate_mac_p.h
index 94534beaac..f74f608660 100644
--- a/src/widgets/widgets/qcocoatoolbardelegate_mac_p.h
+++ b/src/widgets/widgets/qcocoatoolbardelegate_mac_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qcombobox.cpp b/src/widgets/widgets/qcombobox.cpp
index bb57fa336b..6103b9b4c2 100644
--- a/src/widgets/widgets/qcombobox.cpp
+++ b/src/widgets/widgets/qcombobox.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qcombobox.h b/src/widgets/widgets/qcombobox.h
index 0eb5881b93..d167ac7d11 100644
--- a/src/widgets/widgets/qcombobox.h
+++ b/src/widgets/widgets/qcombobox.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtCore/qabstractitemmodel.h>
#include <QtCore/qvariant.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#ifndef QT_NO_COMBOBOX
@@ -280,6 +278,4 @@ inline void QComboBox::insertItem(int aindex, const QString &atext,
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOMBOBOX_H
diff --git a/src/widgets/widgets/qcombobox_p.h b/src/widgets/widgets/qcombobox_p.h
index 0004e3d5ab..14cf9e7925 100644
--- a/src/widgets/widgets/qcombobox_p.h
+++ b/src/widgets/widgets/qcombobox_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -282,8 +282,8 @@ private:
QComboBox *mCombo;
};
-// Note that this class is intentionally not using QStyledItemDelegate
-// Vista does not use the new theme for combo boxes and there might
+// Note that this class is intentionally not using QStyledItemDelegate
+// Vista does not use the new theme for combo boxes and there might
// be other side effects from using the new class
class QComboBoxDelegate : public QItemDelegate
{ Q_OBJECT
diff --git a/src/widgets/widgets/qcommandlinkbutton.cpp b/src/widgets/widgets/qcommandlinkbutton.cpp
index f9be0053e8..18f7b1784e 100644
--- a/src/widgets/widgets/qcommandlinkbutton.cpp
+++ b/src/widgets/widgets/qcommandlinkbutton.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qcommandlinkbutton.h b/src/widgets/widgets/qcommandlinkbutton.h
index a74d6a7b84..e18fb0a4f0 100644
--- a/src/widgets/widgets/qcommandlinkbutton.h
+++ b/src/widgets/widgets/qcommandlinkbutton.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qpushbutton.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -81,6 +79,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOMMANDLINKBUTTON
diff --git a/src/widgets/widgets/qdatetimeedit.cpp b/src/widgets/widgets/qdatetimeedit.cpp
index fb64850923..a0bbbbf7c7 100644
--- a/src/widgets/widgets/qdatetimeedit.cpp
+++ b/src/widgets/widgets/qdatetimeedit.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -981,9 +981,9 @@ QSize QDateTimeEdit::sizeHint() const
int h = d->edit->sizeHint().height();
int w = 0;
QString s;
- s = d->textFromValue(d->minimum) + QLatin1String(" ");
+ s = d->textFromValue(d->minimum) + QLatin1Char(' ');
w = qMax<int>(w, fm.width(s));
- s = d->textFromValue(d->maximum) + QLatin1String(" ");
+ s = d->textFromValue(d->maximum) + QLatin1Char(' ');
w = qMax<int>(w, fm.width(s));
if (d->specialValueText.size()) {
s = d->specialValueText;
@@ -1000,19 +1000,8 @@ QSize QDateTimeEdit::sizeHint() const
} else
#endif
{
- QSize extra(35, 6);
QStyleOptionSpinBox opt;
initStyleOption(&opt);
- opt.rect.setSize(hint + extra);
- extra += hint - style()->subControlRect(QStyle::CC_SpinBox, &opt,
- QStyle::SC_SpinBoxEditField, this).size();
- // get closer to final result by repeating the calculation
- opt.rect.setSize(hint + extra);
- extra += hint - style()->subControlRect(QStyle::CC_SpinBox, &opt,
- QStyle::SC_SpinBoxEditField, this).size();
- hint += extra;
-
- opt.rect = rect();
d->cachedSizeHint = style()->sizeFromContents(QStyle::CT_SpinBox, &opt, hint, this)
.expandedTo(QApplication::globalStrut());
}
@@ -1023,6 +1012,7 @@ QSize QDateTimeEdit::sizeHint() const
return d->cachedSizeHint;
}
+
/*!
\reimp
*/
diff --git a/src/widgets/widgets/qdatetimeedit.h b/src/widgets/widgets/qdatetimeedit.h
index d3197632cf..0b6dfb6e28 100644
--- a/src/widgets/widgets/qdatetimeedit.h
+++ b/src/widgets/widgets/qdatetimeedit.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -46,8 +46,6 @@
#include <QtCore/qvariant.h>
#include <QtWidgets/qabstractspinbox.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -235,6 +233,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QDateTimeEdit::Sections)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDATETIMEEDIT_H
diff --git a/src/widgets/widgets/qdatetimeedit_p.h b/src/widgets/widgets/qdatetimeedit_p.h
index c8c9cd0e23..143979d4bc 100644
--- a/src/widgets/widgets/qdatetimeedit_p.h
+++ b/src/widgets/widgets/qdatetimeedit_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qdial.cpp b/src/widgets/widgets/qdial.cpp
index c7c6c51c53..b415b5254a 100644
--- a/src/widgets/widgets/qdial.cpp
+++ b/src/widgets/widgets/qdial.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qdial.h b/src/widgets/widgets/qdial.h
index c7be201b96..16c4001517 100644
--- a/src/widgets/widgets/qdial.h
+++ b/src/widgets/widgets/qdial.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qabstractslider.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -105,6 +103,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDIAL_H
diff --git a/src/widgets/widgets/qdialogbuttonbox.cpp b/src/widgets/widgets/qdialogbuttonbox.cpp
index 3ebad888a4..bc5d84e259 100644
--- a/src/widgets/widgets/qdialogbuttonbox.cpp
+++ b/src/widgets/widgets/qdialogbuttonbox.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qdialogbuttonbox.h b/src/widgets/widgets/qdialogbuttonbox.h
index 06776bbd93..6715c590e2 100644
--- a/src/widgets/widgets/qdialogbuttonbox.h
+++ b/src/widgets/widgets/qdialogbuttonbox.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -162,6 +160,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QDialogButtonBox::StandardButtons)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDIALOGBUTTONBOX_H
diff --git a/src/widgets/widgets/qdockarealayout.cpp b/src/widgets/widgets/qdockarealayout.cpp
index 7631014905..ca831f5a39 100644
--- a/src/widgets/widgets/qdockarealayout.cpp
+++ b/src/widgets/widgets/qdockarealayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -2004,7 +2004,7 @@ bool QDockAreaLayoutInfo::restoreState(QDataStream &stream, QList<QDockWidget*>
//we need to make sure the element is in the list so the dock widget can eventually be docked correctly
if (!testing)
item_list.append(item);
-
+
//here we need to make sure we change the item in the item_list
QDockAreaLayoutItem &lastItem = testing ? item : item_list.last();
diff --git a/src/widgets/widgets/qdockarealayout_p.h b/src/widgets/widgets/qdockarealayout_p.h
index 53e16911c1..86bf4d32e5 100644
--- a/src/widgets/widgets/qdockarealayout_p.h
+++ b/src/widgets/widgets/qdockarealayout_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qdockwidget.cpp b/src/widgets/widgets/qdockwidget.cpp
index a2e363f991..7485644a08 100644
--- a/src/widgets/widgets/qdockwidget.cpp
+++ b/src/widgets/widgets/qdockwidget.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qdockwidget.h b/src/widgets/widgets/qdockwidget.h
index 993ae6b914..ecf8c67e45 100644
--- a/src/widgets/widgets/qdockwidget.h
+++ b/src/widgets/widgets/qdockwidget.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -140,6 +138,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QDockWidget::DockWidgetFeatures)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDYNAMICDOCKWIDGET_H
diff --git a/src/widgets/widgets/qdockwidget_p.h b/src/widgets/widgets/qdockwidget_p.h
index 7b2e6f97d1..800f523825 100644
--- a/src/widgets/widgets/qdockwidget_p.h
+++ b/src/widgets/widgets/qdockwidget_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qeffects.cpp b/src/widgets/widgets/qeffects.cpp
index 8cd944e133..83060bb571 100644
--- a/src/widgets/widgets/qeffects.cpp
+++ b/src/widgets/widgets/qeffects.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -276,7 +276,7 @@ void QAlphaWidget::render()
#endif // Q_OS_WIN
widget->hide();
} else {
- //Since we are faking the visibility of the widget
+ //Since we are faking the visibility of the widget
//we need to unset the hidden state on it before calling show
widget->setAttribute(Qt::WA_WState_Hidden, true);
widget->show();
@@ -541,7 +541,7 @@ void QRollEffect::scroll()
#endif
widget->hide();
} else {
- //Since we are faking the visibility of the widget
+ //Since we are faking the visibility of the widget
//we need to unset the hidden state on it before calling show
widget->setAttribute(Qt::WA_WState_Hidden, true);
widget->show();
diff --git a/src/widgets/widgets/qeffects_p.h b/src/widgets/widgets/qeffects_p.h
index bbf11face4..a96a60a956 100644
--- a/src/widgets/widgets/qeffects_p.h
+++ b/src/widgets/widgets/qeffects_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qfocusframe.cpp b/src/widgets/widgets/qfocusframe.cpp
index 02d8d5aae9..70b335bfb1 100644
--- a/src/widgets/widgets/qfocusframe.cpp
+++ b/src/widgets/widgets/qfocusframe.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qfocusframe.h b/src/widgets/widgets/qfocusframe.h
index 2993ed5c7f..e1b0004ffc 100644
--- a/src/widgets/widgets/qfocusframe.h
+++ b/src/widgets/widgets/qfocusframe.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -76,6 +74,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFOCUSFRAME_H
diff --git a/src/widgets/widgets/qfontcombobox.cpp b/src/widgets/widgets/qfontcombobox.cpp
index 1b9a08b0d2..5f929caf03 100644
--- a/src/widgets/widgets/qfontcombobox.cpp
+++ b/src/widgets/widgets/qfontcombobox.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -56,46 +56,33 @@ QT_BEGIN_NAMESPACE
static QFontDatabase::WritingSystem writingSystemForFont(const QFont &font, bool *hasLatin)
{
- *hasLatin = true;
-
QList<QFontDatabase::WritingSystem> writingSystems = QFontDatabase().writingSystems(font.family());
// qDebug() << font.family() << writingSystems;
// this just confuses the algorithm below. Vietnamese is Latin with lots of special chars
- writingSystems.removeAll(QFontDatabase::Vietnamese);
+ writingSystems.removeOne(QFontDatabase::Vietnamese);
+ *hasLatin = writingSystems.removeOne(QFontDatabase::Latin);
+
+ if (writingSystems.isEmpty())
+ return QFontDatabase::Any;
- QFontDatabase::WritingSystem system = QFontDatabase::Any;
+ QFontDatabase::WritingSystem system = writingSystems.last();
- if (!writingSystems.contains(QFontDatabase::Latin)) {
- *hasLatin = false;
+ if (!*hasLatin) {
// we need to show something
- if (writingSystems.count())
- system = writingSystems.last();
- } else {
- writingSystems.removeAll(QFontDatabase::Latin);
+ return system;
}
- if (writingSystems.isEmpty())
+ if (writingSystems.count() == 1 && system > QFontDatabase::Cyrillic)
return system;
- if (writingSystems.count() == 1 && writingSystems.at(0) > QFontDatabase::Cyrillic) {
- system = writingSystems.at(0);
+ if (writingSystems.count() <= 2 && system > QFontDatabase::Armenian && system < QFontDatabase::Vietnamese)
return system;
- }
- if (writingSystems.count() <= 2
- && writingSystems.last() > QFontDatabase::Armenian
- && writingSystems.last() < QFontDatabase::Vietnamese) {
- system = writingSystems.last();
+ if (writingSystems.count() <= 5 && system >= QFontDatabase::SimplifiedChinese && system <= QFontDatabase::Korean)
return system;
- }
- if (writingSystems.count() <= 5
- && writingSystems.last() >= QFontDatabase::SimplifiedChinese
- && writingSystems.last() <= QFontDatabase::Korean)
- system = writingSystems.last();
-
- return system;
+ return QFontDatabase::Any;
}
class QFontFamilyDelegate : public QAbstractItemDelegate
diff --git a/src/widgets/widgets/qfontcombobox.h b/src/widgets/widgets/qfontcombobox.h
index e5e1580cdb..66fc9b4581 100644
--- a/src/widgets/widgets/qfontcombobox.h
+++ b/src/widgets/widgets/qfontcombobox.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#ifndef QT_NO_FONTCOMBOBOX
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -105,7 +103,5 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QFontComboBox::FontFilters)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_FONTCOMBOBOX
#endif
diff --git a/src/widgets/widgets/qframe.cpp b/src/widgets/widgets/qframe.cpp
index 3dc30674e2..b7ef2ed3b1 100644
--- a/src/widgets/widgets/qframe.cpp
+++ b/src/widgets/widgets/qframe.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qframe.h b/src/widgets/widgets/qframe.h
index 021d7f5ab0..f121c0d725 100644
--- a/src/widgets/widgets/qframe.h
+++ b/src/widgets/widgets/qframe.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -125,6 +123,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QFRAME_H
diff --git a/src/widgets/widgets/qframe_p.h b/src/widgets/widgets/qframe_p.h
index faa170ae94..377f6f942e 100644
--- a/src/widgets/widgets/qframe_p.h
+++ b/src/widgets/widgets/qframe_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qgroupbox.cpp b/src/widgets/widgets/qgroupbox.cpp
index 6c8da10b8e..d82f151165 100644
--- a/src/widgets/widgets/qgroupbox.cpp
+++ b/src/widgets/widgets/qgroupbox.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -121,7 +121,7 @@ void QGroupBox::initStyleOption(QStyleOptionGroupBox *option) const
option->state |= QStyle::State_Sunken;
}
- if (!option->palette.isBrushSet(isEnabled() ? QPalette::Active :
+ if (!option->palette.isBrushSet(isEnabled() ? QPalette::Active :
QPalette::Disabled, QPalette::WindowText))
option->textColor = QColor(style()->styleHint(QStyle::SH_GroupBox_TextLabelColor,
option, this));
@@ -229,7 +229,7 @@ void QGroupBoxPrivate::init()
overCheckBox = false;
pressedControl = QStyle::SC_None;
calculateFrame();
- q->setSizePolicy(QSizePolicy(QSizePolicy::Preferred, QSizePolicy::Preferred,
+ q->setSizePolicy(QSizePolicy(QSizePolicy::Preferred, QSizePolicy::Preferred,
QSizePolicy::GroupBox));
}
diff --git a/src/widgets/widgets/qgroupbox.h b/src/widgets/widgets/qgroupbox.h
index d462a574fd..6c18cf8c0f 100644
--- a/src/widgets/widgets/qgroupbox.h
+++ b/src/widgets/widgets/qgroupbox.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qframe.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -97,7 +95,7 @@ protected:
void changeEvent(QEvent *event);
void mousePressEvent(QMouseEvent *event);
void mouseMoveEvent(QMouseEvent *event);
- void mouseReleaseEvent(QMouseEvent *event);
+ void mouseReleaseEvent(QMouseEvent *event);
void initStyleOption(QStyleOptionGroupBox *option) const;
@@ -111,6 +109,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QGROUPBOX_H
diff --git a/src/widgets/widgets/qlabel.cpp b/src/widgets/widgets/qlabel.cpp
index a9a9c0cea5..7f2a7684eb 100644
--- a/src/widgets/widgets/qlabel.cpp
+++ b/src/widgets/widgets/qlabel.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -1032,20 +1032,6 @@ void QLabel::paintEvent(QPaintEvent *)
d->ensureTextLayouted();
QAbstractTextDocumentLayout::PaintContext context;
- if (!isEnabled() && !d->control &&
- // We cannot support etched for rich text controls because custom
- // colors and links will override the light palette
- style->styleHint(QStyle::SH_EtchDisabledText, &opt, this)) {
- context.palette = opt.palette;
- context.palette.setColor(QPalette::Text, context.palette.light().color());
- painter.save();
- painter.translate(lr.x() + 1, lr.y() + 1);
- painter.setClipRect(lr.translated(-lr.x() - 1, -lr.y() - 1));
- QAbstractTextDocumentLayout *layout = d->control->document()->documentLayout();
- layout->draw(&painter, context);
- painter.restore();
- }
-
// Adjust the palette
context.palette = opt.palette;
diff --git a/src/widgets/widgets/qlabel.h b/src/widgets/widgets/qlabel.h
index 114d239918..8edb099560 100644
--- a/src/widgets/widgets/qlabel.h
+++ b/src/widgets/widgets/qlabel.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qframe.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -164,6 +162,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLABEL_H
diff --git a/src/widgets/widgets/qlabel_p.h b/src/widgets/widgets/qlabel_p.h
index 2a8958099b..a82ae0653b 100644
--- a/src/widgets/widgets/qlabel_p.h
+++ b/src/widgets/widgets/qlabel_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qlcdnumber.cpp b/src/widgets/widgets/qlcdnumber.cpp
index 876acf4c0c..3ba9ad9ba3 100644
--- a/src/widgets/widgets/qlcdnumber.cpp
+++ b/src/widgets/widgets/qlcdnumber.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qlcdnumber.h b/src/widgets/widgets/qlcdnumber.h
index 4495f40f7f..3dde1527f2 100644
--- a/src/widgets/widgets/qlcdnumber.h
+++ b/src/widgets/widgets/qlcdnumber.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qframe.h>
#include <QtCore/qbitarray.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -122,6 +120,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLCDNUMBER_H
diff --git a/src/widgets/widgets/qlineedit.cpp b/src/widgets/widgets/qlineedit.cpp
index 65969a7ebb..ea58ec1429 100644
--- a/src/widgets/widgets/qlineedit.cpp
+++ b/src/widgets/widgets/qlineedit.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -139,9 +139,9 @@ void QLineEdit::initStyleOption(QStyleOptionFrame *option) const
The length of the text can be constrained to maxLength(). The text
can be arbitrarily constrained using a validator() or an
- inputMask(), or both. When switching between a validator and an input mask
- on the same line edit, it is best to clear the validator or input mask to
- prevent undefined behavior.
+ inputMask(), or both. When switching between a validator and an input mask
+ on the same line edit, it is best to clear the validator or input mask to
+ prevent undefined behavior.
A related class is QTextEdit which allows multi-line, rich text
@@ -1758,7 +1758,7 @@ void QLineEdit::focusOutEvent(QFocusEvent *e)
QObject::disconnect(d->control->completer(), 0, this, 0);
}
#endif
- update();
+ QWidget::focusOutEvent(e);
}
/*!\reimp
@@ -1801,7 +1801,7 @@ void QLineEdit::paintEvent(QPaintEvent *)
int minRB = qMax(0, -fm.minRightBearing());
if (d->control->text().isEmpty()) {
- if (!hasFocus() && !d->placeholderText.isEmpty()) {
+ if (!d->placeholderText.isEmpty()) {
QColor col = pal.text().color();
col.setAlpha(128);
QPen oldpen = p.pen();
@@ -1810,7 +1810,6 @@ void QLineEdit::paintEvent(QPaintEvent *)
QString elidedText = fm.elidedText(d->placeholderText, Qt::ElideRight, lineRect.width());
p.drawText(lineRect, va, elidedText);
p.setPen(oldpen);
- return;
}
}
diff --git a/src/widgets/widgets/qlineedit.h b/src/widgets/widgets/qlineedit.h
index af50170d3d..e2b944314b 100644
--- a/src/widgets/widgets/qlineedit.h
+++ b/src/widgets/widgets/qlineedit.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -47,8 +47,6 @@
#include <QtCore/qstring.h>
#include <QtCore/qmargins.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -248,6 +246,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QLINEEDIT_H
diff --git a/src/widgets/widgets/qlineedit_p.cpp b/src/widgets/widgets/qlineedit_p.cpp
index 7f800d831f..1999216e65 100644
--- a/src/widgets/widgets/qlineedit_p.cpp
+++ b/src/widgets/widgets/qlineedit_p.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -180,7 +180,7 @@ void QLineEditPrivate::init(const QString& txt)
#endif
QObject::connect(control, SIGNAL(cursorPositionChanged(int,int)),
q, SLOT(updateMicroFocus()));
-
+
QObject::connect(control, SIGNAL(textChanged(QString)),
q, SLOT(updateMicroFocus()));
diff --git a/src/widgets/widgets/qlineedit_p.h b/src/widgets/widgets/qlineedit_p.h
index 8f1ca48865..4eb35b7dc6 100644
--- a/src/widgets/widgets/qlineedit_p.h
+++ b/src/widgets/widgets/qlineedit_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qmaccocoaviewcontainer_mac.h b/src/widgets/widgets/qmaccocoaviewcontainer_mac.h
index 1bb631d296..b89b796819 100644
--- a/src/widgets/widgets/qmaccocoaviewcontainer_mac.h
+++ b/src/widgets/widgets/qmaccocoaviewcontainer_mac.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/QWidget>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -67,6 +65,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QCOCOAVIEWCONTAINER_H
diff --git a/src/widgets/widgets/qmaccocoaviewcontainer_mac.mm b/src/widgets/widgets/qmaccocoaviewcontainer_mac.mm
index 1eadb62d5c..2be11f34d5 100644
--- a/src/widgets/widgets/qmaccocoaviewcontainer_mac.mm
+++ b/src/widgets/widgets/qmaccocoaviewcontainer_mac.mm
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -112,7 +112,7 @@ QMacCocoaViewContainerPrivate::~QMacCocoaViewContainerPrivate()
/*!
\fn QMacCocoaViewContainer::QMacCocoaViewContainer(void *cocoaViewToWrap, QWidget *parent)
-
+
Create a new QMacCocoaViewContainer using the NSView pointer in \a
cocoaViewToWrap with parent, \a parent. QMacCocoaViewContainer will
retain \a cocoaViewToWrap.
diff --git a/src/widgets/widgets/qmacnativewidget_mac.h b/src/widgets/widgets/qmacnativewidget_mac.h
index 0a227f1756..796d7b38d4 100644
--- a/src/widgets/widgets/qmacnativewidget_mac.h
+++ b/src/widgets/widgets/qmacnativewidget_mac.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/QWidget>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -68,6 +66,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMACNATIVEWIDGET_H
diff --git a/src/widgets/widgets/qmacnativewidget_mac.mm b/src/widgets/widgets/qmacnativewidget_mac.mm
index 240bd6d92e..50907b8dfc 100644
--- a/src/widgets/widgets/qmacnativewidget_mac.mm
+++ b/src/widgets/widgets/qmacnativewidget_mac.mm
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qmainwindow.cpp b/src/widgets/widgets/qmainwindow.cpp
index 5bb331a99a..436fb65dd2 100644
--- a/src/widgets/widgets/qmainwindow.cpp
+++ b/src/widgets/widgets/qmainwindow.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qmainwindow.h b/src/widgets/widgets/qmainwindow.h
index d00e75d7ae..d9edf711e0 100644
--- a/src/widgets/widgets/qmainwindow.h
+++ b/src/widgets/widgets/qmainwindow.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qwidget.h>
#include <QtWidgets/qtabwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -210,6 +208,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QMainWindow::DockOptions)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDYNAMICMAINWINDOW_H
diff --git a/src/widgets/widgets/qmainwindowlayout.cpp b/src/widgets/widgets/qmainwindowlayout.cpp
index 17a3f06e79..cfeb0e2c67 100644
--- a/src/widgets/widgets/qmainwindowlayout.cpp
+++ b/src/widgets/widgets/qmainwindowlayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qmainwindowlayout_mac.mm b/src/widgets/widgets/qmainwindowlayout_mac.mm
index 4fea391339..38605c2e09 100644
--- a/src/widgets/widgets/qmainwindowlayout_mac.mm
+++ b/src/widgets/widgets/qmainwindowlayout_mac.mm
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qmainwindowlayout_p.h b/src/widgets/widgets/qmainwindowlayout_p.h
index 50fcf8a15f..f866a554dc 100644
--- a/src/widgets/widgets/qmainwindowlayout_p.h
+++ b/src/widgets/widgets/qmainwindowlayout_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qmdiarea.cpp b/src/widgets/widgets/qmdiarea.cpp
index 5135cf6962..b2409e300c 100644
--- a/src/widgets/widgets/qmdiarea.cpp
+++ b/src/widgets/widgets/qmdiarea.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qmdiarea.h b/src/widgets/widgets/qmdiarea.h
index 52278e35aa..87ecd432dc 100644
--- a/src/widgets/widgets/qmdiarea.h
+++ b/src/widgets/widgets/qmdiarea.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qabstractscrollarea.h>
#include <QtWidgets/qtabwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -172,7 +170,5 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QMdiArea::AreaOptions)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_MDIAREA
#endif // QMDIAREA_H
diff --git a/src/widgets/widgets/qmdiarea_p.h b/src/widgets/widgets/qmdiarea_p.h
index 4c953b80ef..90db55438a 100644
--- a/src/widgets/widgets/qmdiarea_p.h
+++ b/src/widgets/widgets/qmdiarea_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qmdisubwindow.cpp b/src/widgets/widgets/qmdisubwindow.cpp
index 01ee2528f3..b38dea074f 100644
--- a/src/widgets/widgets/qmdisubwindow.cpp
+++ b/src/widgets/widgets/qmdisubwindow.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -164,6 +164,7 @@
#include <private/qmacstyle_mac_p.h>
#endif
#include <QMdiArea>
+#include <QScopedValueRollback>
QT_BEGIN_NAMESPACE
@@ -183,14 +184,6 @@ static const QStyle::SubControl SubControls[] =
};
static const int NumSubControls = sizeof(SubControls) / sizeof(SubControls[0]);
-static const QStyle::StandardPixmap ButtonPixmaps[] =
-{
- QStyle::SP_TitleBarMinButton,
- QStyle::SP_TitleBarNormalButton,
- QStyle::SP_TitleBarCloseButton
-};
-static const int NumButtonPixmaps = sizeof(ButtonPixmaps) / sizeof(ButtonPixmaps[0]);
-
static const Qt::WindowFlags CustomizeWindowFlags =
Qt::FramelessWindowHint
| Qt::CustomizeWindowHint
@@ -2797,6 +2790,10 @@ bool QMdiSubWindow::event(QEvent *event)
bool wasShaded = isShaded();
bool wasMinimized = isMinimized();
bool wasMaximized = isMaximized();
+ // Don't emit subWindowActivated, the app doesn't have to know about our hacks
+ const QScopedValueRollback<bool> activationEnabledSaver(d->activationEnabled);
+ d->activationEnabled = false;
+
ensurePolished();
setContentsMargins(0, 0, 0, 0);
if (wasMinimized || wasMaximized || wasShaded)
@@ -3016,7 +3013,8 @@ void QMdiSubWindow::changeEvent(QEvent *changeEvent)
if (d->isActive)
d->ensureWindowState(Qt::WindowActive);
- emit windowStateChanged(oldState, windowState());
+ if (d->activationEnabled)
+ emit windowStateChanged(oldState, windowState());
}
/*!
diff --git a/src/widgets/widgets/qmdisubwindow.h b/src/widgets/widgets/qmdisubwindow.h
index 9dac7e1ee0..915fef758b 100644
--- a/src/widgets/widgets/qmdisubwindow.h
+++ b/src/widgets/widgets/qmdisubwindow.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -151,8 +149,6 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QMdiSubWindow::SubWindowOptions)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_MDIAREA
#endif // QMDISUBWINDOW_H
diff --git a/src/widgets/widgets/qmdisubwindow_p.h b/src/widgets/widgets/qmdisubwindow_p.h
index 810fd3d27d..90369ff526 100644
--- a/src/widgets/widgets/qmdisubwindow_p.h
+++ b/src/widgets/widgets/qmdisubwindow_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qmenu.cpp b/src/widgets/widgets/qmenu.cpp
index 922a38b324..dfa906d2ea 100644
--- a/src/widgets/widgets/qmenu.cpp
+++ b/src/widgets/widgets/qmenu.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -67,6 +67,7 @@
#include "qwidgetaction.h"
#include "qtoolbutton.h"
#include "qpushbutton.h"
+#include "qtooltip.h"
#include <private/qpushbutton_p.h>
#include <private/qaction_p.h>
#include <private/qguiapplication_p.h>
@@ -259,12 +260,15 @@ void QMenuPrivate::updateActionRects(const QRect &screen) const
bool previousWasSeparator = true; // this is true to allow removing the leading separators
for(int i = 0; i <= lastVisibleAction; i++) {
QAction *action = actions.at(i);
+ const bool isSection = action->isSeparator() && (!action->text().isEmpty() || !action->icon().isNull());
+ const bool isPlainSeparator = (isSection && !q->style()->styleHint(QStyle::SH_Menu_SupportsSections))
+ || (action->isSeparator() && !isSection);
if (!action->isVisible() ||
- (collapsibleSeparators && previousWasSeparator && action->isSeparator()))
+ (collapsibleSeparators && previousWasSeparator && isPlainSeparator))
continue; // we continue, this action will get an empty QRect
- previousWasSeparator = action->isSeparator();
+ previousWasSeparator = isPlainSeparator;
//let the style modify the above size..
QStyleOptionMenuItem opt;
@@ -1510,6 +1514,54 @@ QAction *QMenu::addSeparator()
}
/*!
+ \since 5.1
+
+ This convenience function creates a new section action, i.e. an
+ action with QAction::isSeparator() returning true but also
+ having \a text hint, and adds the new action to this menu's list
+ of actions. It returns the newly created action.
+
+ The rendering of the hint is style and platform dependent. Widget
+ styles can use the text information in the rendering for sections,
+ or can choose to ignore it and render sections like simple separators.
+
+ QMenu takes ownership of the returned QAction.
+
+ \sa QWidget::addAction()
+*/
+QAction *QMenu::addSection(const QString &text)
+{
+ QAction *action = new QAction(text, this);
+ action->setSeparator(true);
+ addAction(action);
+ return action;
+}
+
+/*!
+ \since 5.1
+
+ This convenience function creates a new section action, i.e. an
+ action with QAction::isSeparator() returning true but also
+ having \a text and \a icon hints, and adds the new action to this menu's
+ list of actions. It returns the newly created action.
+
+ The rendering of the hints is style and platform dependent. Widget
+ styles can use the text and icon information in the rendering for sections,
+ or can choose to ignore them and render sections like simple separators.
+
+ QMenu takes ownership of the returned QAction.
+
+ \sa QWidget::addAction()
+*/
+QAction *QMenu::addSection(const QIcon &icon, const QString &text)
+{
+ QAction *action = new QAction(icon, text, this);
+ action->setSeparator(true);
+ addAction(action);
+ return action;
+}
+
+/*!
This convenience function inserts \a menu before action \a before
and returns the menus menuAction().
@@ -1541,6 +1593,55 @@ QAction *QMenu::insertSeparator(QAction *before)
}
/*!
+ \since 5.1
+
+ This convenience function creates a new title action, i.e. an
+ action with QAction::isSeparator() returning true but also having
+ \a text hint. The function inserts the newly created action
+ into this menu's list of actions before action \a before and
+ returns it.
+
+ The rendering of the hint is style and platform dependent. Widget
+ styles can use the text information in the rendering for sections,
+ or can choose to ignore it and render sections like simple separators.
+
+ QMenu takes ownership of the returned QAction.
+
+ \sa QWidget::insertAction(), addSection()
+*/
+QAction *QMenu::insertSection(QAction *before, const QString &text)
+{
+ QAction *action = new QAction(text, this);
+ action->setSeparator(true);
+ insertAction(before, action);
+ return action;
+}
+
+/*!
+ \since 5.1
+
+ This convenience function creates a new title action, i.e. an
+ action with QAction::isSeparator() returning true but also having
+ \a text and \a icon hints. The function inserts the newly created action
+ into this menu's list of actions before action \a before and returns it.
+
+ The rendering of the hints is style and platform dependent. Widget
+ styles can use the text and icon information in the rendering for sections,
+ or can choose to ignore them and render sections like simple separators.
+
+ QMenu takes ownership of the returned QAction.
+
+ \sa QWidget::insertAction(), addSection()
+*/
+QAction *QMenu::insertSection(QAction *before, const QIcon &icon, const QString &text)
+{
+ QAction *action = new QAction(icon, text, this);
+ action->setSeparator(true);
+ insertAction(before, action);
+ return action;
+}
+
+/*!
This sets the default action to \a act. The default action may have
a visual cue, depending on the current QStyle. A default action
usually indicates what will happen by default when a drop occurs.
@@ -2368,6 +2469,19 @@ QMenu::event(QEvent *e)
if (d->currentAction)
d->popupAction(d->currentAction, 0, false);
break;
+#ifndef QT_NO_TOOLTIP
+ case QEvent::ToolTip:
+ if (d->toolTipsVisible) {
+ const QHelpEvent *ev = static_cast<const QHelpEvent*>(e);
+ if (const QAction *action = actionAt(ev->pos())) {
+ const QString toolTip = action->d_func()->tooltip;
+ if (!toolTip.isEmpty())
+ QToolTip::showText(ev->globalPos(), toolTip, this);
+ return true;
+ }
+ }
+ break;
+#endif // QT_NO_TOOLTIP
#ifndef QT_NO_WHATSTHIS
case QEvent::QueryWhatsThis:
e->setAccepted(d->whatsThis.size());
@@ -2826,7 +2940,7 @@ QMenu::timerEvent(QTimerEvent *e)
}
}
-void copyActionToPlatformItem(const QAction *action, QPlatformMenuItem* item)
+static void copyActionToPlatformItem(const QAction *action, QPlatformMenuItem* item)
{
item->setText(action->text());
item->setIsSeparator(action->isSeparator());
@@ -2834,6 +2948,7 @@ void copyActionToPlatformItem(const QAction *action, QPlatformMenuItem* item)
item->setIcon(action->icon());
item->setVisible(action->isVisible());
item->setShortcut(action->shortcut());
+ item->setCheckable(action->isCheckable());
item->setChecked(action->isChecked());
item->setFont(action->font());
item->setRole((QPlatformMenuItem::MenuRole) action->menuRole());
@@ -3089,6 +3204,32 @@ void QMenu::setSeparatorsCollapsible(bool collapse)
d->platformMenu->syncSeparatorsCollapsible(collapse);
}
+/*!
+ \property QMenu::toolTipsVisible
+ \since 5.1
+
+ \brief whether tooltips of menu actions should be visible
+
+ This property specifies whether action menu entries show
+ their tooltip.
+
+ By default, this property is false.
+*/
+bool QMenu::toolTipsVisible() const
+{
+ Q_D(const QMenu);
+ return d->toolTipsVisible;
+}
+
+void QMenu::setToolTipsVisible(bool visible)
+{
+ Q_D(QMenu);
+ if (d->toolTipsVisible == visible)
+ return;
+
+ d->toolTipsVisible = visible;
+}
+
QT_END_NAMESPACE
// for private slots
diff --git a/src/widgets/widgets/qmenu.h b/src/widgets/widgets/qmenu.h
index e58e7a231f..518771d846 100644
--- a/src/widgets/widgets/qmenu.h
+++ b/src/widgets/widgets/qmenu.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -51,8 +51,6 @@
#include <windef.h> // for HMENU
#endif
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -72,6 +70,7 @@ private:
Q_PROPERTY(QString title READ title WRITE setTitle)
Q_PROPERTY(QIcon icon READ icon WRITE setIcon)
Q_PROPERTY(bool separatorsCollapsible READ separatorsCollapsible WRITE setSeparatorsCollapsible)
+ Q_PROPERTY(bool toolTipsVisible READ toolTipsVisible WRITE setToolTipsVisible)
public:
explicit QMenu(QWidget *parent = 0);
@@ -94,8 +93,13 @@ public:
QAction *addSeparator();
+ QAction *addSection(const QString &text);
+ QAction *addSection(const QIcon &icon, const QString &text);
+
QAction *insertMenu(QAction *before, QMenu *menu);
QAction *insertSeparator(QAction *before);
+ QAction *insertSection(QAction *before, const QString &text);
+ QAction *insertSection(QAction *before, const QIcon &icon, const QString &text);
bool isEmpty() const;
void clear();
@@ -141,6 +145,9 @@ public:
bool separatorsCollapsible() const;
void setSeparatorsCollapsible(bool collapse);
+ bool toolTipsVisible() const;
+ void setToolTipsVisible(bool visible);
+
Q_SIGNALS:
void aboutToShow();
void aboutToHide();
@@ -201,6 +208,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMENU_H
diff --git a/src/widgets/widgets/qmenu_p.h b/src/widgets/widgets/qmenu_p.h
index 0b8137cff3..6cc88c56e2 100644
--- a/src/widgets/widgets/qmenu_p.h
+++ b/src/widgets/widgets/qmenu_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -84,7 +84,8 @@ class QMenuPrivate : public QWidgetPrivate
Q_DECLARE_PUBLIC(QMenu)
public:
QMenuPrivate() : itemsDirty(0), maxIconWidth(0), tabWidth(0), ncols(0),
- collapsibleSeparators(true), activationRecursionGuard(false), hasHadMouse(0), aboutToHide(0), motions(0),
+ collapsibleSeparators(true), toolTipsVisible(false),
+ activationRecursionGuard(false), hasHadMouse(0), aboutToHide(0), motions(0),
currentAction(0),
#ifdef QT_KEYPAD_NAVIGATION
selectAction(0),
@@ -123,6 +124,7 @@ public:
QRect popupGeometry(int screen = -1) const;
mutable uint ncols : 4; //4 bits is probably plenty
uint collapsibleSeparators : 1;
+ uint toolTipsVisible : 1;
QSize adjustMenuSizeForScreen(const QRect & screen);
int getLastVisibleAction() const;
diff --git a/src/widgets/widgets/qmenu_wince.cpp b/src/widgets/widgets/qmenu_wince.cpp
index 68a2022e97..a82cc4abb9 100644
--- a/src/widgets/widgets/qmenu_wince.cpp
+++ b/src/widgets/widgets/qmenu_wince.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -116,14 +116,14 @@ static void resolveAygLibs()
}
}
-static void qt_wce_enable_soft_key(HWND handle, uint command)
+static void qt_wce_enable_soft_key(HWND handle, uint command)
{
resolveAygLibs();
if (ptrEnableSoftKey)
ptrEnableSoftKey(handle, command, false, true);
}
-static void qt_wce_disable_soft_key(HWND handle, uint command)
+static void qt_wce_disable_soft_key(HWND handle, uint command)
{
resolveAygLibs();
if (ptrEnableSoftKey)
@@ -148,7 +148,7 @@ static QAction* qt_wce_get_quit_action(QList<QAction *> actionItems)
QAction *action = actionItems.at(i);
if (action->menuRole() == QAction::QuitRole)
returnAction = action;
- else
+ else
if (action->menu())
returnAction = qt_wce_get_quit_action(action->menu()->actions());
if (returnAction)
@@ -252,7 +252,7 @@ static void qt_wce_insert_action(HMENU menu, QWceMenuAction *action)
if (action->action->isCheckable())
if (action->action->isChecked())
CheckMenuItem(menu, action->command, MF_BYCOMMAND | MF_CHECKED);
- else
+ else
CheckMenuItem(menu, action->command, MF_BYCOMMAND | MF_UNCHECKED);
}
}
@@ -264,8 +264,8 @@ static void qt_wce_clear_menu(HMENU hMenu)
}
/*!
- \internal
-
+ \internal
+
This function refreshes the native Windows CE menu.
*/
@@ -281,8 +281,8 @@ void QMenuBarPrivate::wceRefresh()
}
/*!
- \internal
-
+ \internal
+
This function sends native Windows CE commands to Qt menus.
*/
@@ -293,8 +293,8 @@ QAction* QMenu::wceCommands(uint command)
}
/*!
- \internal
-
+ \internal
+
This function sends native Windows CE commands to Qt menu bars
and all their child menus.
*/
@@ -457,7 +457,7 @@ void QMenuPrivate::QWceMenuPrivate::addAction(QWceMenuAction *action, QWceMenuAc
/*!
\internal
-
+
This function will return the HMENU used to create the native
Windows CE menu bar bindings.
*/
@@ -642,7 +642,7 @@ void QMenuBarPrivate::QWceMenuBarPrivate::rebuild()
qt_wce_rename_menu_item(menubarHandle, leftButtonCommand, leftButtonAction->text());
qt_wce_enable_soft_key(menubarHandle, leftButtonCommand);
} else {
- qt_wce_rename_menu_item(menubarHandle, leftButtonCommand, QLatin1String(""));
+ qt_wce_rename_menu_item(menubarHandle, leftButtonCommand, QLatin1String(""));
qt_wce_disable_soft_key(menubarHandle, leftButtonCommand);
}
} else {
diff --git a/src/widgets/widgets/qmenu_wince.rc b/src/widgets/widgets/qmenu_wince.rc
index 631cd9d47a..0bcd32c7e5 100644
--- a/src/widgets/widgets/qmenu_wince.rc
+++ b/src/widgets/widgets/qmenu_wince.rc
@@ -14,19 +14,19 @@
#define I_IMAGENONE (-2)
#define NOMENU 0xFFFF
-IDR_MAIN_MENU MENU DISCARDABLE
+IDR_MAIN_MENU MENU DISCARDABLE
BEGIN
POPUP "Menu"
BEGIN
- MENUITEM "About", IDM_ABOUT
+ MENUITEM "About", IDM_ABOUT
END
END
-IDR_MAIN_MENU2 MENU DISCARDABLE
+IDR_MAIN_MENU2 MENU DISCARDABLE
BEGIN
POPUP "Menu"
BEGIN
- MENUITEM "About", IDM_ABOUT
+ MENUITEM "About", IDM_ABOUT
END
POPUP "Display"
BEGIN
@@ -35,7 +35,7 @@ BEGIN
END
-IDR_MAIN_MENU3 MENU DISCARDABLE
+IDR_MAIN_MENU3 MENU DISCARDABLE
BEGIN
POPUP "Menu1"
BEGIN
@@ -55,7 +55,7 @@ BEGIN
END
END
-IDR_MAIN_MENU4 MENU DISCARDABLE
+IDR_MAIN_MENU4 MENU DISCARDABLE
BEGIN
POPUP "Menu1"
BEGIN
@@ -83,7 +83,7 @@ BEGIN
END
END
-IDR_MAIN_MENU5 MENU DISCARDABLE
+IDR_MAIN_MENU5 MENU DISCARDABLE
BEGIN
POPUP "Menu1"
BEGIN
@@ -119,8 +119,8 @@ BEGIN
END
END
-STRINGTABLE
-BEGIN
+STRINGTABLE
+BEGIN
IDS_EXIT "Exit"
IDS_MENU "Menu"
IDS_LEFTMENU "Display"
@@ -136,31 +136,31 @@ END
IDR_MAIN_MENU SHMENUBAR DISCARDABLE
BEGIN
- IDR_MAIN_MENU,
+ IDR_MAIN_MENU,
2,
I_IMAGENONE, IDM_EXIT, TBSTATE_ENABLED, TBSTYLE_BUTTON | TBSTYLE_AUTOSIZE,
IDS_EXIT, 0, NOMENU,
-
+
I_IMAGENONE, IDM_MENU, TBSTATE_ENABLED, TBSTYLE_DROPDOWN | TBSTYLE_AUTOSIZE,
IDS_MENU, 0, 0,
END
IDR_MAIN_MENU2 SHMENUBAR DISCARDABLE
BEGIN
- IDR_MAIN_MENU2,
+ IDR_MAIN_MENU2,
2,
I_IMAGENONE, IDM_LEFTMENU, TBSTATE_ENABLED, TBSTYLE_DROPDOWN | TBSTYLE_AUTOSIZE,
IDS_LEFTMENU, 0, 1,
-
+
I_IMAGENONE, IDM_MENU, TBSTATE_ENABLED, TBSTYLE_DROPDOWN | TBSTYLE_AUTOSIZE,
IDS_MENU, 0, 0,
END
IDR_MAIN_MENU3 SHMENUBAR DISCARDABLE
BEGIN
- IDR_MAIN_MENU3,
+ IDR_MAIN_MENU3,
4,
I_IMAGENONE, IDM_MENU1, TBSTATE_ENABLED, TBSTYLE_DROPDOWN | TBSTYLE_AUTOSIZE,
@@ -178,7 +178,7 @@ END
IDR_MAIN_MENU4 SHMENUBAR DISCARDABLE
BEGIN
- IDR_MAIN_MENU4,
+ IDR_MAIN_MENU4,
6,
I_IMAGENONE, IDM_MENU1, TBSTATE_ENABLED, TBSTYLE_DROPDOWN | TBSTYLE_AUTOSIZE,
@@ -202,7 +202,7 @@ END
IDR_MAIN_MENU5 SHMENUBAR DISCARDABLE
BEGIN
- IDR_MAIN_MENU5,
+ IDR_MAIN_MENU5,
8,
I_IMAGENONE, IDM_MENU1, TBSTATE_ENABLED, TBSTYLE_DROPDOWN | TBSTYLE_AUTOSIZE,
diff --git a/src/widgets/widgets/qmenu_wince_resource_p.h b/src/widgets/widgets/qmenu_wince_resource_p.h
index c3ec386780..3ecf05a02a 100644
--- a/src/widgets/widgets/qmenu_wince_resource_p.h
+++ b/src/widgets/widgets/qmenu_wince_resource_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -50,7 +50,6 @@
// We mean it.
//
-QT_BEGIN_HEADER
#define IDR_MAIN_MENU 102
#define IDR_MAIN_MENU2 103
@@ -90,5 +89,3 @@ QT_BEGIN_HEADER
#define IDM_MENU7 40009
#define IDM_MENU8 40010
-QT_END_HEADER
-
diff --git a/src/widgets/widgets/qmenubar.cpp b/src/widgets/widgets/qmenubar.cpp
index 5fdd505f16..f22c48b26f 100644
--- a/src/widgets/widgets/qmenubar.cpp
+++ b/src/widgets/widgets/qmenubar.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qmenubar.h b/src/widgets/widgets/qmenubar.h
index 4b850ca3fe..e88a0c07c0 100644
--- a/src/widgets/widgets/qmenubar.h
+++ b/src/widgets/widgets/qmenubar.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qmenu.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -159,6 +157,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QMENUBAR_H
diff --git a/src/widgets/widgets/qmenubar_p.h b/src/widgets/widgets/qmenubar_p.h
index b39d370c76..817df945c5 100644
--- a/src/widgets/widgets/qmenubar_p.h
+++ b/src/widgets/widgets/qmenubar_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qplaintextedit.cpp b/src/widgets/widgets/qplaintextedit.cpp
index 8f00201e70..95271adeb0 100644
--- a/src/widgets/widgets/qplaintextedit.cpp
+++ b/src/widgets/widgets/qplaintextedit.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qplaintextedit.h b/src/widgets/widgets/qplaintextedit.h
index 1e9fc373bb..42e8288cf3 100644
--- a/src/widgets/widgets/qplaintextedit.h
+++ b/src/widgets/widgets/qplaintextedit.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -53,8 +53,6 @@
#ifndef QT_NO_TEXTEDIT
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -319,8 +317,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_TEXTEDIT
diff --git a/src/widgets/widgets/qplaintextedit_p.h b/src/widgets/widgets/qplaintextedit_p.h
index 6173234f5a..ab464676e5 100644
--- a/src/widgets/widgets/qplaintextedit_p.h
+++ b/src/widgets/widgets/qplaintextedit_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qprogressbar.cpp b/src/widgets/widgets/qprogressbar.cpp
index 72e937b604..e317933e4d 100644
--- a/src/widgets/widgets/qprogressbar.cpp
+++ b/src/widgets/widgets/qprogressbar.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -41,6 +41,7 @@
#include "qprogressbar.h"
#ifndef QT_NO_PROGRESSBAR
+#include <qlocale.h>
#include <qevent.h>
#include <qpainter.h>
#include <qstylepainter.h>
@@ -61,6 +62,7 @@ public:
QProgressBarPrivate();
void init();
+ void initDefaultFormat();
inline void resetLayoutItemMargins();
int minimum;
@@ -68,6 +70,7 @@ public:
int value;
Qt::Alignment alignment;
uint textVisible : 1;
+ uint defaultFormat: 1;
int lastPaintedValue;
Qt::Orientation orientation;
bool invertedAppearance;
@@ -79,9 +82,16 @@ public:
QProgressBarPrivate::QProgressBarPrivate()
: minimum(0), maximum(100), value(-1), alignment(Qt::AlignLeft), textVisible(true),
- lastPaintedValue(-1), orientation(Qt::Horizontal), invertedAppearance(false),
- textDirection(QProgressBar::TopToBottom), format(QLatin1String("%p%"))
+ defaultFormat(true), lastPaintedValue(-1), orientation(Qt::Horizontal), invertedAppearance(false),
+ textDirection(QProgressBar::TopToBottom)
{
+ initDefaultFormat();
+}
+
+void QProgressBarPrivate::initDefaultFormat()
+{
+ if (defaultFormat)
+ format = QLatin1String("%p") + locale.percent();
}
void QProgressBarPrivate::init()
@@ -466,19 +476,21 @@ QString QProgressBar::text() const
qint64 totalSteps = qint64(d->maximum) - d->minimum;
QString result = d->format;
- result.replace(QLatin1String("%m"), QString::number(totalSteps));
- result.replace(QLatin1String("%v"), QString::number(d->value));
+ QLocale locale = d->locale; // Omit group separators for compatibility with previous versions that were non-localized.
+ locale.setNumberOptions(locale.numberOptions() | QLocale::OmitGroupSeparator);
+ result.replace(QLatin1String("%m"), locale.toString(totalSteps));
+ result.replace(QLatin1String("%v"), locale.toString(d->value));
// If max and min are equal and we get this far, it means that the
// progress bar has one step and that we are on that step. Return
// 100% here in order to avoid division by zero further down.
if (totalSteps == 0) {
- result.replace(QLatin1String("%p"), QString::number(100));
+ result.replace(QLatin1String("%p"), locale.toString(int(100)));
return result;
}
int progress = (qreal(d->value) - d->minimum) * 100.0 / totalSteps;
- result.replace(QLatin1String("%p"), QString::number(progress));
+ result.replace(QLatin1String("%p"), locale.toString(progress));
return result;
}
@@ -568,12 +580,19 @@ QProgressBar::Direction QProgressBar::textDirection() const
bool QProgressBar::event(QEvent *e)
{
Q_D(QProgressBar);
- if (e->type() == QEvent::StyleChange
+ switch (e->type()) {
+ case QEvent::StyleChange:
#ifdef Q_OS_MAC
- || e->type() == QEvent::MacSizeChange
+ case QEvent::MacSizeChange:
#endif
- )
d->resetLayoutItemMargins();
+ break;
+ case QEvent::LocaleChange:
+ d->initDefaultFormat();
+ break;
+ default:
+ break;
+ }
return QWidget::event(e);
}
@@ -596,6 +615,15 @@ void QProgressBar::setFormat(const QString &format)
if (d->format == format)
return;
d->format = format;
+ d->defaultFormat = false;
+ update();
+}
+
+void QProgressBar::resetFormat()
+{
+ Q_D(QProgressBar);
+ d->defaultFormat = true;
+ d->initDefaultFormat();
update();
}
diff --git a/src/widgets/widgets/qprogressbar.h b/src/widgets/widgets/qprogressbar.h
index a1b0fcee1d..2f66aaad9e 100644
--- a/src/widgets/widgets/qprogressbar.h
+++ b/src/widgets/widgets/qprogressbar.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qframe.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -67,7 +65,7 @@ class Q_WIDGETS_EXPORT QProgressBar : public QWidget
Q_PROPERTY(Qt::Orientation orientation READ orientation WRITE setOrientation)
Q_PROPERTY(bool invertedAppearance READ invertedAppearance WRITE setInvertedAppearance)
Q_PROPERTY(Direction textDirection READ textDirection WRITE setTextDirection)
- Q_PROPERTY(QString format READ format WRITE setFormat)
+ Q_PROPERTY(QString format READ format WRITE setFormat RESET resetFormat)
public:
enum Direction { TopToBottom, BottomToTop };
@@ -98,6 +96,7 @@ public:
QProgressBar::Direction textDirection() const;
void setFormat(const QString &format);
+ void resetFormat();
QString format() const;
public Q_SLOTS:
@@ -125,6 +124,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPROGRESSBAR_H
diff --git a/src/widgets/widgets/qpushbutton.cpp b/src/widgets/widgets/qpushbutton.cpp
index 139e3949d1..a10d726e36 100644
--- a/src/widgets/widgets/qpushbutton.cpp
+++ b/src/widgets/widgets/qpushbutton.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qpushbutton.h b/src/widgets/widgets/qpushbutton.h
index 3aa3673478..7806e96763 100644
--- a/src/widgets/widgets/qpushbutton.h
+++ b/src/widgets/widgets/qpushbutton.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qabstractbutton.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -105,13 +103,11 @@ public:
private:
Q_DISABLE_COPY(QPushButton)
Q_DECLARE_PRIVATE(QPushButton)
-#ifndef QT_NO_MENU
+#ifndef QT_NO_MENU
Q_PRIVATE_SLOT(d_func(), void _q_popupPressed())
#endif
};
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QPUSHBUTTON_H
diff --git a/src/widgets/widgets/qpushbutton_p.h b/src/widgets/widgets/qpushbutton_p.h
index 803bb0c4ac..93069d295f 100644
--- a/src/widgets/widgets/qpushbutton_p.h
+++ b/src/widgets/widgets/qpushbutton_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qradiobutton.cpp b/src/widgets/widgets/qradiobutton.cpp
index 1195b5fad4..7bc57df12b 100644
--- a/src/widgets/widgets/qradiobutton.cpp
+++ b/src/widgets/widgets/qradiobutton.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qradiobutton.h b/src/widgets/widgets/qradiobutton.h
index 13a73ba3c9..104d4a12e0 100644
--- a/src/widgets/widgets/qradiobutton.h
+++ b/src/widgets/widgets/qradiobutton.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qabstractbutton.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -79,6 +77,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QRADIOBUTTON_H
diff --git a/src/widgets/widgets/qrubberband.cpp b/src/widgets/widgets/qrubberband.cpp
index 2adc81fd3e..112a9b66cd 100644
--- a/src/widgets/widgets/qrubberband.cpp
+++ b/src/widgets/widgets/qrubberband.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qrubberband.h b/src/widgets/widgets/qrubberband.h
index 34962e52cc..b603415d1a 100644
--- a/src/widgets/widgets/qrubberband.h
+++ b/src/widgets/widgets/qrubberband.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -98,6 +96,4 @@ inline void QRubberBand::move(int ax, int ay)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QRUBBERBAND_H
diff --git a/src/widgets/widgets/qscrollarea.cpp b/src/widgets/widgets/qscrollarea.cpp
index 590225e850..93c335c56b 100644
--- a/src/widgets/widgets/qscrollarea.cpp
+++ b/src/widgets/widgets/qscrollarea.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -240,7 +240,7 @@ QWidget *QScrollArea::widget() const
The \a widget becomes a child of the scroll area, and will be
destroyed when the scroll area is deleted or when a new widget is
set.
-
+
The widget's \l{QWidget::setAutoFillBackground()}{autoFillBackground}
property will be set to \c{true}.
diff --git a/src/widgets/widgets/qscrollarea.h b/src/widgets/widgets/qscrollarea.h
index 18a9fac598..576c9bc9e0 100644
--- a/src/widgets/widgets/qscrollarea.h
+++ b/src/widgets/widgets/qscrollarea.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qabstractscrollarea.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -95,6 +93,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSCROLLAREA_H
diff --git a/src/widgets/widgets/qscrollarea_p.h b/src/widgets/widgets/qscrollarea_p.h
index ee38221877..919d1c8df2 100644
--- a/src/widgets/widgets/qscrollarea_p.h
+++ b/src/widgets/widgets/qscrollarea_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -53,6 +53,8 @@
// We mean it.
//
+#include <QtCore/qglobal.h>
+
#ifndef QT_NO_SCROLLAREA
#include "private/qabstractscrollarea_p.h"
diff --git a/src/widgets/widgets/qscrollbar.cpp b/src/widgets/widgets/qscrollbar.cpp
index bddef57f5d..e1e2723a2d 100644
--- a/src/widgets/widgets/qscrollbar.cpp
+++ b/src/widgets/widgets/qscrollbar.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qscrollbar.h b/src/widgets/widgets/qscrollbar.h
index e9514c59a9..27d0169b40 100644
--- a/src/widgets/widgets/qscrollbar.h
+++ b/src/widgets/widgets/qscrollbar.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qwidget.h>
#include <QtWidgets/qabstractslider.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -94,6 +92,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSCROLLBAR_H
diff --git a/src/widgets/widgets/qscrollbar_p.h b/src/widgets/widgets/qscrollbar_p.h
index 75fea46e04..c62c337a40 100644
--- a/src/widgets/widgets/qscrollbar_p.h
+++ b/src/widgets/widgets/qscrollbar_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qsizegrip.cpp b/src/widgets/widgets/qsizegrip.cpp
index 0b9341de58..106a8d770a 100644
--- a/src/widgets/widgets/qsizegrip.cpp
+++ b/src/widgets/widgets/qsizegrip.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qsizegrip.h b/src/widgets/widgets/qsizegrip.h
index c79e4716da..11dadfa306 100644
--- a/src/widgets/widgets/qsizegrip.h
+++ b/src/widgets/widgets/qsizegrip.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -83,6 +81,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSIZEGRIP_H
diff --git a/src/widgets/widgets/qslider.cpp b/src/widgets/widgets/qslider.cpp
index f10a693117..2d91cd07e6 100644
--- a/src/widgets/widgets/qslider.cpp
+++ b/src/widgets/widgets/qslider.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qslider.h b/src/widgets/widgets/qslider.h
index 460d52e57c..a8d7019c1f 100644
--- a/src/widgets/widgets/qslider.h
+++ b/src/widgets/widgets/qslider.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qabstractslider.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -106,6 +104,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSLIDER_H
diff --git a/src/widgets/widgets/qspinbox.cpp b/src/widgets/widgets/qspinbox.cpp
index e61c1c877a..0ce5473ad8 100644
--- a/src/widgets/widgets/qspinbox.cpp
+++ b/src/widgets/widgets/qspinbox.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -268,6 +268,7 @@ void QSpinBox::setPrefix(const QString &prefix)
d->updateEdit();
d->cachedSizeHint = QSize();
+ d->cachedMinimumSizeHint = QSize(); // minimumSizeHint cares about the prefix
updateGeometry();
}
diff --git a/src/widgets/widgets/qspinbox.h b/src/widgets/widgets/qspinbox.h
index 7be16f460b..4963f87a1a 100644
--- a/src/widgets/widgets/qspinbox.h
+++ b/src/widgets/widgets/qspinbox.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qabstractspinbox.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -172,6 +170,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSPINBOX_H
diff --git a/src/widgets/widgets/qsplashscreen.cpp b/src/widgets/widgets/qsplashscreen.cpp
index 3711b2f43e..746c02e4e2 100644
--- a/src/widgets/widgets/qsplashscreen.cpp
+++ b/src/widgets/widgets/qsplashscreen.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -80,7 +80,7 @@ public:
be shown during application startup.
\inmodule QtWidgets
-
+
A splash screen is a widget that is usually displayed when an
application is being started. Splash screens are often used for
applications that have long start up times (e.g. database or
diff --git a/src/widgets/widgets/qsplashscreen.h b/src/widgets/widgets/qsplashscreen.h
index af97a38cf8..a1af8e45ef 100644
--- a/src/widgets/widgets/qsplashscreen.h
+++ b/src/widgets/widgets/qsplashscreen.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtGui/qpixmap.h>
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -88,6 +86,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSPLASHSCREEN_H
diff --git a/src/widgets/widgets/qsplitter.cpp b/src/widgets/widgets/qsplitter.cpp
index a8399ed8d5..031763b80c 100644
--- a/src/widgets/widgets/qsplitter.cpp
+++ b/src/widgets/widgets/qsplitter.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -1665,7 +1665,7 @@ bool QSplitter::restoreState(const QByteArray &state)
have a stretch factor of \a stretch.
\a stretch is not the effective stretch factor; the effective
- stretch factor is calculated by taking the initial size of the
+ stretch factor is calculated by taking the initial size of the
widget and multiplying it with \a stretch.
This function is provided for convenience. It is equivalent to
diff --git a/src/widgets/widgets/qsplitter.h b/src/widgets/widgets/qsplitter.h
index 79785b257e..ed4102d31e 100644
--- a/src/widgets/widgets/qsplitter.h
+++ b/src/widgets/widgets/qsplitter.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qframe.h>
#include <QtWidgets/qsizepolicy.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -170,6 +168,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSPLITTER_H
diff --git a/src/widgets/widgets/qsplitter_p.h b/src/widgets/widgets/qsplitter_p.h
index e829fd2f69..f1e050b8f6 100644
--- a/src/widgets/widgets/qsplitter_p.h
+++ b/src/widgets/widgets/qsplitter_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qstackedwidget.cpp b/src/widgets/widgets/qstackedwidget.cpp
index 4dd11a00b8..4b7170a596 100644
--- a/src/widgets/widgets/qstackedwidget.cpp
+++ b/src/widgets/widgets/qstackedwidget.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qstackedwidget.h b/src/widgets/widgets/qstackedwidget.h
index 451de7fe40..a147577ba6 100644
--- a/src/widgets/widgets/qstackedwidget.h
+++ b/src/widgets/widgets/qstackedwidget.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qframe.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -94,6 +92,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTACKEDWIDGET_H
diff --git a/src/widgets/widgets/qstatusbar.cpp b/src/widgets/widgets/qstatusbar.cpp
index 880ddfaf35..86fd10699c 100644
--- a/src/widgets/widgets/qstatusbar.cpp
+++ b/src/widgets/widgets/qstatusbar.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -534,7 +534,7 @@ void QStatusBar::reformat()
}
/*!
-
+
Hides the normal status indications and displays the given \a
message for the specified number of milli-seconds (\a{timeout}). If
\a{timeout} is 0 (default), the \a {message} remains displayed until
@@ -744,7 +744,7 @@ bool QStatusBar::event(QEvent *e)
}
}
}
-
+
// On Mac OS X Leopard it is possible to drag the window by clicking
// on the tool bar on most applications.
#ifndef Q_WS_MAC
@@ -755,7 +755,7 @@ bool QStatusBar::event(QEvent *e)
// Enable drag-click only if the status bar is the status bar for a
// QMainWindow with a unifed toolbar.
- if (parent() == 0 || qobject_cast<QMainWindow *>(parent()) == 0 ||
+ if (parent() == 0 || qobject_cast<QMainWindow *>(parent()) == 0 ||
qobject_cast<QMainWindow *>(parent())->unifiedTitleAndToolBarOnMac() == false )
return QWidget::event(e);
diff --git a/src/widgets/widgets/qstatusbar.h b/src/widgets/widgets/qstatusbar.h
index de3982cffd..4a5b1ee494 100644
--- a/src/widgets/widgets/qstatusbar.h
+++ b/src/widgets/widgets/qstatusbar.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -101,6 +99,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QSTATUSBAR_H
diff --git a/src/widgets/widgets/qtabbar.cpp b/src/widgets/widgets/qtabbar.cpp
index e0ea3e798d..b975035dcf 100644
--- a/src/widgets/widgets/qtabbar.cpp
+++ b/src/widgets/widgets/qtabbar.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -80,7 +80,7 @@ inline static bool verticalTabs(QTabBar::Shape shape)
void QTabBarPrivate::updateMacBorderMetrics()
{
-#if (defined Q_WS_MAC) && (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5)
+#if defined(Q_WS_MAC)
if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_5) {
Q_Q(QTabBar);
::HIContentBorderMetrics metrics;
diff --git a/src/widgets/widgets/qtabbar.h b/src/widgets/widgets/qtabbar.h
index 0bb10c2aa9..72c19ab520 100644
--- a/src/widgets/widgets/qtabbar.h
+++ b/src/widgets/widgets/qtabbar.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -212,6 +210,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTABBAR_H
diff --git a/src/widgets/widgets/qtabbar_p.h b/src/widgets/widgets/qtabbar_p.h
index 2dc7569d27..7468144146 100644
--- a/src/widgets/widgets/qtabbar_p.h
+++ b/src/widgets/widgets/qtabbar_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qtabwidget.cpp b/src/widgets/widgets/qtabwidget.cpp
index 2f0acc3ea4..4df55e2537 100644
--- a/src/widgets/widgets/qtabwidget.cpp
+++ b/src/widgets/widgets/qtabwidget.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qtabwidget.h b/src/widgets/widgets/qtabwidget.h
index 54bf1e638d..1a1eb2ef2b 100644
--- a/src/widgets/widgets/qtabwidget.h
+++ b/src/widgets/widgets/qtabwidget.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qwidget.h>
#include <QtGui/qicon.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -181,6 +179,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTABWIDGET_H
diff --git a/src/widgets/widgets/qtextbrowser.cpp b/src/widgets/widgets/qtextbrowser.cpp
index 61e7a5fbfb..e05da51207 100644
--- a/src/widgets/widgets/qtextbrowser.cpp
+++ b/src/widgets/widgets/qtextbrowser.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -151,12 +151,18 @@ public:
QString QTextBrowserPrivate::findFile(const QUrl &name) const
{
QString fileName;
- if (name.scheme() == QLatin1String("qrc"))
+ if (name.scheme() == QLatin1String("qrc")) {
fileName = QLatin1String(":/") + name.path();
- else if (name.scheme().isEmpty())
+ } else if (name.scheme().isEmpty()) {
fileName = name.path();
- else
- fileName = name.toLocalFile();
+ } else {
+#if defined(Q_OS_ANDROID)
+ if (name.scheme() == QLatin1String("assets"))
+ fileName = QLatin1String("assets:") + name.path();
+ else
+#endif
+ fileName = name.toLocalFile();
+ }
if (QFileInfo(fileName).isAbsolute())
return fileName;
@@ -217,13 +223,14 @@ void QTextBrowserPrivate::_q_activateAnchor(const QString &href)
textOrSourceChanged = false;
#ifndef QT_NO_DESKTOPSERVICES
- if ((openExternalLinks
- && url.scheme() != QLatin1String("file")
- && url.scheme() != QLatin1String("qrc")
- && !url.isRelative())
- || (url.isRelative() && !currentURL.isRelative()
- && currentURL.scheme() != QLatin1String("file")
- && currentURL.scheme() != QLatin1String("qrc"))) {
+ bool isFileScheme =
+ url.scheme() == QLatin1String("file")
+#if defined(Q_OS_ANDROID)
+ || url.scheme() == QLatin1String("assets")
+#endif
+ || url.scheme() == QLatin1String("qrc");
+ if ((openExternalLinks && !isFileScheme && !url.isRelative())
+ || (url.isRelative() && !currentURL.isRelative() && !isFileScheme)) {
QDesktopServices::openUrl(url);
return;
}
diff --git a/src/widgets/widgets/qtextbrowser.h b/src/widgets/widgets/qtextbrowser.h
index 900dd27211..244d8a32df 100644
--- a/src/widgets/widgets/qtextbrowser.h
+++ b/src/widgets/widgets/qtextbrowser.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qtextedit.h>
#include <QtCore/qurl.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -129,6 +127,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTEXTBROWSER_H
diff --git a/src/widgets/widgets/qtextedit.cpp b/src/widgets/widgets/qtextedit.cpp
index f033b6544c..bf2c8a4495 100644
--- a/src/widgets/widgets/qtextedit.cpp
+++ b/src/widgets/widgets/qtextedit.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -182,7 +182,7 @@ void QTextEditPrivate::init(const QString &html)
q->setFocusPolicy(Qt::WheelFocus);
q->setAttribute(Qt::WA_KeyCompression);
q->setAttribute(Qt::WA_InputMethodEnabled);
-
+ q->setInputMethodHints(Qt::ImhMultiLine);
#ifndef QT_NO_CURSOR
viewport->setCursor(Qt::IBeamCursor);
#endif
diff --git a/src/widgets/widgets/qtextedit.h b/src/widgets/widgets/qtextedit.h
index b44083a502..e1471848e7 100644
--- a/src/widgets/widgets/qtextedit.h
+++ b/src/widgets/widgets/qtextedit.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -51,8 +51,6 @@
#ifndef QT_NO_TEXTEDIT
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -314,8 +312,6 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QTextEdit::AutoFormatting)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_TEXTEDIT
#endif // QTEXTEDIT_H
diff --git a/src/widgets/widgets/qtextedit_p.h b/src/widgets/widgets/qtextedit_p.h
index a2ca2dc6f4..1ce68dc23e 100644
--- a/src/widgets/widgets/qtextedit_p.h
+++ b/src/widgets/widgets/qtextedit_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qtoolbar.cpp b/src/widgets/widgets/qtoolbar.cpp
index 907874fc0e..0c2dd20d77 100644
--- a/src/widgets/widgets/qtoolbar.cpp
+++ b/src/widgets/widgets/qtoolbar.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qtoolbar.h b/src/widgets/widgets/qtoolbar.h
index a706ccf46e..663497493f 100644
--- a/src/widgets/widgets/qtoolbar.h
+++ b/src/widgets/widgets/qtoolbar.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qwidget.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -172,6 +170,4 @@ inline QAction *QToolBar::actionAt(int ax, int ay) const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDYNAMICTOOLBAR_H
diff --git a/src/widgets/widgets/qtoolbar_p.h b/src/widgets/widgets/qtoolbar_p.h
index 464f653059..9ff0b9d61c 100644
--- a/src/widgets/widgets/qtoolbar_p.h
+++ b/src/widgets/widgets/qtoolbar_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qtoolbararealayout.cpp b/src/widgets/widgets/qtoolbararealayout.cpp
index 02279ad014..94a1148ded 100644
--- a/src/widgets/widgets/qtoolbararealayout.cpp
+++ b/src/widgets/widgets/qtoolbararealayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -810,7 +810,7 @@ QLayoutItem *QToolBarAreaLayout::insertToolBar(QToolBar *before, QToolBar *toolB
QInternal::DockPosition pos = findToolBar(before);
if (pos == QInternal::DockCount)
return 0;
-
+
return docks[pos].insertToolBar(before, toolBar);
}
@@ -869,7 +869,7 @@ void QToolBarAreaLayout::insertItem(QToolBar *before, QLayoutItem *item)
QInternal::DockPosition pos = findToolBar(before);
if (pos == QInternal::DockCount)
return;
-
+
docks[pos].insertItem(before, item);
}
diff --git a/src/widgets/widgets/qtoolbararealayout_p.h b/src/widgets/widgets/qtoolbararealayout_p.h
index 5cbb4a4756..ec7d1f26f1 100644
--- a/src/widgets/widgets/qtoolbararealayout_p.h
+++ b/src/widgets/widgets/qtoolbararealayout_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -169,7 +169,7 @@ public:
void removeToolBar(QToolBar *toolBar);
void insertToolBarBreak(QToolBar *before);
void removeToolBarBreak(QToolBar *before);
- void moveToolBar(QToolBar *toolbar, int pos);
+ void moveToolBar(QToolBar *toolbar, int pos);
QList<int> gapIndex(const QPoint &pos, int *maxDistance) const;
bool insertGap(const QList<int> &path, QLayoutItem *item);
@@ -215,7 +215,7 @@ public:
void insertToolBarBreak(QToolBar *before);
void removeToolBarBreak(QToolBar *before);
void addToolBarBreak(QInternal::DockPosition pos);
- void moveToolBar(QToolBar *toolbar, int pos);
+ void moveToolBar(QToolBar *toolbar, int pos);
void insertItem(QInternal::DockPosition pos, QLayoutItem *item);
void insertItem(QToolBar *before, QLayoutItem *item);
diff --git a/src/widgets/widgets/qtoolbarextension.cpp b/src/widgets/widgets/qtoolbarextension.cpp
index 682ababc33..1e1999d4f3 100644
--- a/src/widgets/widgets/qtoolbarextension.cpp
+++ b/src/widgets/widgets/qtoolbarextension.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qtoolbarextension_p.h b/src/widgets/widgets/qtoolbarextension_p.h
index 5175d7bc2d..ccb2e411b0 100644
--- a/src/widgets/widgets/qtoolbarextension_p.h
+++ b/src/widgets/widgets/qtoolbarextension_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qtoolbarlayout.cpp b/src/widgets/widgets/qtoolbarlayout.cpp
index 1dde9c0a1d..3c0c84ee2f 100644
--- a/src/widgets/widgets/qtoolbarlayout.cpp
+++ b/src/widgets/widgets/qtoolbarlayout.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -409,7 +409,7 @@ void QToolBarLayout::setGeometry(const QRect &rect)
}
}
#endif
-
+
}
bool QToolBarLayout::layoutActions(const QSize &size)
diff --git a/src/widgets/widgets/qtoolbarlayout_p.h b/src/widgets/widgets/qtoolbarlayout_p.h
index 5796c21861..8605a9a6ac 100644
--- a/src/widgets/widgets/qtoolbarlayout_p.h
+++ b/src/widgets/widgets/qtoolbarlayout_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qtoolbarseparator.cpp b/src/widgets/widgets/qtoolbarseparator.cpp
index a5b5bb9569..140f26eaed 100644
--- a/src/widgets/widgets/qtoolbarseparator.cpp
+++ b/src/widgets/widgets/qtoolbarseparator.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qtoolbarseparator_p.h b/src/widgets/widgets/qtoolbarseparator_p.h
index bea892c6fb..8db7205b4f 100644
--- a/src/widgets/widgets/qtoolbarseparator_p.h
+++ b/src/widgets/widgets/qtoolbarseparator_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qtoolbox.cpp b/src/widgets/widgets/qtoolbox.cpp
index 52ab5465ae..1264a5b6f2 100644
--- a/src/widgets/widgets/qtoolbox.cpp
+++ b/src/widgets/widgets/qtoolbox.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qtoolbox.h b/src/widgets/widgets/qtoolbox.h
index 6d7166f2ac..3a15ca1850 100644
--- a/src/widgets/widgets/qtoolbox.h
+++ b/src/widgets/widgets/qtoolbox.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -45,8 +45,6 @@
#include <QtWidgets/qframe.h>
#include <QtGui/qicon.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -126,6 +124,4 @@ inline int QToolBox::insertItem(int index, QWidget *item, const QString &text)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTOOLBOX_H
diff --git a/src/widgets/widgets/qtoolbutton.cpp b/src/widgets/widgets/qtoolbutton.cpp
index 54c73588f7..88690f8bff 100644
--- a/src/widgets/widgets/qtoolbutton.cpp
+++ b/src/widgets/widgets/qtoolbutton.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qtoolbutton.h b/src/widgets/widgets/qtoolbutton.h
index 778f2d8f15..3310476b44 100644
--- a/src/widgets/widgets/qtoolbutton.h
+++ b/src/widgets/widgets/qtoolbutton.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -44,8 +44,6 @@
#include <QtWidgets/qabstractbutton.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -139,6 +137,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTOOLBUTTON_H
diff --git a/src/widgets/widgets/qwidgetanimator.cpp b/src/widgets/widgets/qwidgetanimator.cpp
index c6520a010e..bbd96ca29a 100644
--- a/src/widgets/widgets/qwidgetanimator.cpp
+++ b/src/widgets/widgets/qwidgetanimator.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qwidgetanimator_p.h b/src/widgets/widgets/qwidgetanimator_p.h
index fa2421c1fa..776ca74b1f 100644
--- a/src/widgets/widgets/qwidgetanimator_p.h
+++ b/src/widgets/widgets/qwidgetanimator_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qwidgetlinecontrol.cpp b/src/widgets/widgets/qwidgetlinecontrol.cpp
index 579c1713aa..9212f942c5 100644
--- a/src/widgets/widgets/qwidgetlinecontrol.cpp
+++ b/src/widgets/widgets/qwidgetlinecontrol.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qwidgetlinecontrol_p.h b/src/widgets/widgets/qwidgetlinecontrol_p.h
index f5fd900681..1cee67bfd2 100644
--- a/src/widgets/widgets/qwidgetlinecontrol_p.h
+++ b/src/widgets/widgets/qwidgetlinecontrol_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -69,8 +69,6 @@
#include "qplatformdefs.h"
-QT_BEGIN_HEADER
-
#ifdef DrawText
# undef DrawText
#endif
@@ -533,8 +531,6 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QT_NO_LINEEDIT
#endif // QWidgetLineControl_P_H
diff --git a/src/widgets/widgets/qwidgetresizehandler.cpp b/src/widgets/widgets/qwidgetresizehandler.cpp
index 362f46ac6a..ba4e69126a 100644
--- a/src/widgets/widgets/qwidgetresizehandler.cpp
+++ b/src/widgets/widgets/qwidgetresizehandler.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qwidgetresizehandler_p.h b/src/widgets/widgets/qwidgetresizehandler_p.h
index 8c6b8cd669..6ace370e9d 100644
--- a/src/widgets/widgets/qwidgetresizehandler_p.h
+++ b/src/widgets/widgets/qwidgetresizehandler_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/qwidgettextcontrol.cpp b/src/widgets/widgets/qwidgettextcontrol.cpp
index 9a2a83503b..99493704b5 100644
--- a/src/widgets/widgets/qwidgettextcontrol.cpp
+++ b/src/widgets/widgets/qwidgettextcontrol.cpp
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -1726,12 +1726,13 @@ void QWidgetTextControlPrivate::mouseReleaseEvent(QEvent *e, Qt::MouseButton but
{
Q_Q(QWidgetTextControl);
+ const QTextCursor oldSelection = cursor;
if (sendMouseEventToInputContext(
e, QEvent::MouseButtonRelease, button, pos, modifiers, buttons, globalPos)) {
+ repaintOldAndNewSelection(oldSelection);
return;
}
- const QTextCursor oldSelection = cursor;
const int oldCursorPos = cursor.position();
#ifndef QT_NO_DRAGANDDROP
diff --git a/src/widgets/widgets/qwidgettextcontrol_p.h b/src/widgets/widgets/qwidgettextcontrol_p.h
index 070dc660c6..e857fffba5 100644
--- a/src/widgets/widgets/qwidgettextcontrol_p.h
+++ b/src/widgets/widgets/qwidgettextcontrol_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -65,8 +65,6 @@
#include <QtGui/qclipboard.h>
#include <QtCore/qmimedata.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -297,6 +295,4 @@ private:
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QWidgetTextControl_H
diff --git a/src/widgets/widgets/qwidgettextcontrol_p_p.h b/src/widgets/widgets/qwidgettextcontrol_p_p.h
index 86a7f1e48e..727821015e 100644
--- a/src/widgets/widgets/qwidgettextcontrol_p_p.h
+++ b/src/widgets/widgets/qwidgettextcontrol_p_p.h
@@ -3,7 +3,7 @@
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
diff --git a/src/widgets/widgets/widgets.pri b/src/widgets/widgets/widgets.pri
index 797f3e9b76..9780d3c24c 100644
--- a/src/widgets/widgets/widgets.pri
+++ b/src/widgets/widgets/widgets.pri
@@ -145,7 +145,7 @@ SOURCES += \
false:mac {
HEADERS += widgets/qmacnativewidget_mac.h \
widgets/qmaccocoaviewcontainer_mac.h
- OBJECTIVE_HEADERS += widgets/qcocoatoolbardelegate_mac_p.h \
+ OBJECTIVE_HEADERS += widgets/qcocoatoolbardelegate_mac_p.h \
widgets/qcocoamenu_mac_p.h
OBJECTIVE_SOURCES += widgets/qmaccocoaviewcontainer_mac.mm \
widgets/qcocoatoolbardelegate_mac.mm \
diff --git a/src/xml/doc/src/qtxml-index.qdoc b/src/xml/doc/src/qtxml-index.qdoc
index 2247ce5ace..ded8f3de3c 100644
--- a/src/xml/doc/src/qtxml-index.qdoc
+++ b/src/xml/doc/src/qtxml-index.qdoc
@@ -31,7 +31,7 @@
\brief The Qt XML module provides C++ implementations of the SAX and DOM standards for XML.
The module is not actively maintained anymore. Please use
- the QXmlStreamReader and QXmlStreamwriter classes in Qt Core instead.
+ the QXmlStreamReader and QXmlStreamWriter classes in Qt Core instead.
To include the definitions of the module's classes, use the
following directive:
diff --git a/src/xml/dom/qdom.h b/src/xml/dom/qdom.h
index 36eee0caeb..f1c04a422d 100644
--- a/src/xml/dom/qdom.h
+++ b/src/xml/dom/qdom.h
@@ -45,8 +45,6 @@
#include <QtXml/qtxmlglobal.h>
#include <QtCore/qstring.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -675,6 +673,4 @@ Q_XML_EXPORT QTextStream& operator<<(QTextStream&, const QDomNode&);
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QDOM_H
diff --git a/src/xml/qtxmlglobal.h b/src/xml/qtxmlglobal.h
index fb86e57e9e..c7209ad054 100644
--- a/src/xml/qtxmlglobal.h
+++ b/src/xml/qtxmlglobal.h
@@ -44,8 +44,6 @@
#include <QtCore/qglobal.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
#ifndef QT_STATIC
@@ -60,6 +58,4 @@ QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QTXMLGLOBAL_H
diff --git a/src/xml/sax/qxml.cpp b/src/xml/sax/qxml.cpp
index 689c75774e..47e137976b 100644
--- a/src/xml/sax/qxml.cpp
+++ b/src/xml/sax/qxml.cpp
@@ -3037,10 +3037,10 @@ void QXmlSimpleReaderPrivate::initIncrementalParsing()
A common way to perform incremental parsing is to connect the \c
readyRead() signal of a \l{QNetworkReply} {network reply} a slot,
and handle the incoming data there. See QNetworkAccessManager.
-
+
Aspects of the parsing behavior can be adapted using setFeature()
and setProperty().
-
+
\snippet code/src_xml_sax_qxml.cpp 0
QXmlSimpleReader is not reentrant. If you want to use the class
diff --git a/src/xml/sax/qxml.h b/src/xml/sax/qxml.h
index 069e344ce4..4ce2c26b05 100644
--- a/src/xml/sax/qxml.h
+++ b/src/xml/sax/qxml.h
@@ -50,8 +50,6 @@
#include <QtCore/qlist.h>
#include <QtCore/qscopedpointer.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -417,6 +415,4 @@ inline int QXmlAttributes::count() const
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QXML_H
diff --git a/sync.profile b/sync.profile
index 756f83e409..e07b285dbb 100644
--- a/sync.profile
+++ b/sync.profile
@@ -3,7 +3,7 @@
"QtWidgets" => "$basedir/src/widgets",
"QtPrintSupport" => "$basedir/src/printsupport",
"QtOpenGL" => "$basedir/src/opengl",
- "QtCore" => "$basedir/src/corelib;^$basedir/src/3rdparty/harfbuzz/src",
+ "QtCore" => "$basedir/src/corelib",
"QtXml" => "$basedir/src/xml",
"QtSql" => "$basedir/src/sql",
"QtNetwork" => "$basedir/src/network",
@@ -15,6 +15,7 @@
"GLES2" => "$basedir/src/3rdparty/angle/include/GLES2",
"EGL" => "$basedir/src/3rdparty/angle/include/EGL",
"QtZlib" => "$basedir/src/3rdparty/zlib",
+ "QtOpenGLExtensions" => "$basedir/src/openglextensions",
);
%moduleheaders = ( # restrict the module headers to those found in relative path
);
@@ -56,11 +57,9 @@
my @angle_headers = ('egl.h', 'eglext.h', 'eglplatform.h', 'gl2.h', 'gl2ext.h', 'gl2platform.h', 'ShaderLang.h', 'khrplatform.h');
my @internal_zlib_headers = ( "crc32.h", "deflate.h", "gzguts.h", "inffast.h", "inffixed.h", "inflate.h", "inftrees.h", "trees.h", "zutil.h" );
my @zlib_headers = ( "zconf.h", "zlib.h" );
-my @harfbuzz_headers = ( "harfbuzz-buffer-private.h", "harfbuzz-buffer.h", "harfbuzz-dump.h", "harfbuzz-external.h", "harfbuzz-gdef-private.h", "harfbuzz-gdef.h", "harfbuzz-global.h", "harfbuzz-gpos-private.h", "harfbuzz-gpos.h", "harfbuzz-gsub-private.h", "harfbuzz-gsub.h", "harfbuzz-impl.h", "harfbuzz-open-private.h", "harfbuzz-open.h", "harfbuzz-shape.h", "harfbuzz-shaper-private.h", "harfbuzz-shaper.h", "harfbuzz-stream-private.h", "harfbuzz-stream.h", "harfbuzz.h" );
@ignore_headers = ( @internal_zlib_headers );
-@ignore_for_include_check = ( "qsystemdetection.h", "qcompilerdetection.h", "qprocessordetection.h", @zlib_headers, @angle_headers, @harfbuzz_headers);
-@ignore_for_qt_begin_header_check = ( "qiconset.h", "qconfig.h", "qconfig-dist.h", "qconfig-large.h", "qconfig-medium.h", "qconfig-minimal.h", "qconfig-small.h", "qfeatures.h", "qt_windows.h", @zlib_headers, @angle_headers, @harfbuzz_headers);
-@ignore_for_qt_begin_namespace_check = ( "qconfig.h", "qconfig-dist.h", "qconfig-large.h", "qconfig-medium.h", "qconfig-minimal.h", "qconfig-small.h", "qfeatures.h", "qatomic_arch.h", "qatomic_windowsce.h", "qt_windows.h", "qatomic_macosx.h", @zlib_headers, @angle_headers, @harfbuzz_headers);
+@ignore_for_include_check = ( "qsystemdetection.h", "qcompilerdetection.h", "qprocessordetection.h", @zlib_headers, @angle_headers);
+@ignore_for_qt_begin_namespace_check = ( "qconfig.h", "qconfig-dist.h", "qconfig-large.h", "qconfig-medium.h", "qconfig-minimal.h", "qconfig-small.h", "qfeatures.h", "qatomic_arch.h", "qatomic_windowsce.h", "qt_windows.h", "qatomic_macosx.h", @zlib_headers, @angle_headers);
%inject_headers = ( "$basedir/src/corelib/global" => [ "qconfig.h" ] );
# Module dependencies.
# Every module that is required to build this module should have one entry.
diff --git a/tests/auto/android/AndroidManifest.xml b/tests/auto/android/AndroidManifest.xml
new file mode 100644
index 0000000000..bd1e0afc68
--- /dev/null
+++ b/tests/auto/android/AndroidManifest.xml
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+ package="org.qtproject.qt5.android.tests"
+ android:versionCode="1"
+ android:versionName="1.0">
+ <uses-sdk android:minSdkVersion="4" />
+ <application android:label="@string/app_name" android:name="org.qtproject.qt5.android.QtNative">
+ <activity android:label="@string/app_name" android:name="org.qtproject.qt5.android.QtActivity">
+ <intent-filter>
+ <action android:name="android.intent.action.MAIN" />
+ <category android:name="android.intent.category.LAUNCHER" />
+ </intent-filter>
+ </activity>
+ </application>
+ <supports-screens android:largeScreens="true" android:normalScreens="true" android:anyDensity="true" android:smallScreens="true"/>
+ <uses-permission android:name="android.permission.INTERNET"/>
+ <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
+ <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
+ <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
+ <uses-permission android:name="android.permission.ACCESS_MOCK_LOCATION"/>
+ <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
+ <uses-permission android:name="android.permission.ACCESS_SURFACE_FLINGER"/>
+ <uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
+ <uses-permission android:name="android.permission.BLUETOOTH"/>
+ <uses-permission android:name="android.permission.BLUETOOTH_ADMIN"/>
+ <uses-permission android:name="android.permission.CAMERA"/>
+ <uses-permission android:name="android.permission.CHANGE_WIFI_MULTICAST_STATE"/>
+ <uses-permission android:name="android.permission.INJECT_EVENTS"/>
+ <uses-permission android:name="android.permission.NFC"/>
+ <uses-permission android:name="android.permission.READ_PHONE_STATE"/>
+ <uses-permission android:name="android.permission.SET_ORIENTATION"/>
+ <uses-permission android:name="android.permission.STATUS_BAR"/>
+ <uses-permission android:name="android.permission.VIBRATE"/>
+ <uses-permission android:name="android.permission.WAKE_LOCK"/>
+ <uses-permission android:name="android.permission.WRITE_CALENDAR"/>
+ <uses-permission android:name="android.permission.WRITE_CONTACTS"/>
+</manifest>
diff --git a/tests/auto/android/res/layout/main.xml b/tests/auto/android/res/layout/main.xml
new file mode 100644
index 0000000000..7fe6bbac67
--- /dev/null
+++ b/tests/auto/android/res/layout/main.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+ android:orientation="vertical"
+ android:layout_width="fill_parent"
+ android:layout_height="fill_parent"
+ >
+<TextView
+ android:layout_width="fill_parent"
+ android:layout_height="fill_parent"
+ android:id="@+id/textView"
+ />
+</LinearLayout>
diff --git a/tests/auto/android/res/values/libs.xml b/tests/auto/android/res/values/libs.xml
new file mode 100644
index 0000000000..43f1d4aff4
--- /dev/null
+++ b/tests/auto/android/res/values/libs.xml
@@ -0,0 +1,21 @@
+<?xml version='1.0' encoding='utf-8'?>
+<resources>
+ <array name="qt_libs">
+ <item>gnustl_shared</item>
+ <item>Qt5Core</item>
+ <item>Qt5Gui</item>
+ <item>Qt5Widgets</item>
+ <item>Qt5Test</item>
+ <item>Qt5OpenGL</item>
+ <item>Qt5Network</item>
+ <item>Qt5Script</item>
+ <item>Qt5Sql</item>
+ <item>Qt5Xml</item>
+ <item>Qt5ScriptTools</item>
+ <item>Qt5Svg</item>
+ <item>Qt5XmlPatterns</item>
+ <item>Qt5Declarative</item>
+ <item>Qt5WebKit</item>
+ </array>
+ <array name="bundled_libs"/>
+</resources>
diff --git a/tests/auto/android/res/values/strings.xml b/tests/auto/android/res/values/strings.xml
new file mode 100644
index 0000000000..faf61040b5
--- /dev/null
+++ b/tests/auto/android/res/values/strings.xml
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+ <string name="app_name">Quadruplor</string>
+</resources>
diff --git a/tests/auto/android/runtests.pl b/tests/auto/android/runtests.pl
new file mode 100755
index 0000000000..7bb6833859
--- /dev/null
+++ b/tests/auto/android/runtests.pl
@@ -0,0 +1,366 @@
+#!/usr/bin/perl -w
+#############################################################################
+##
+## Copyright (C) 2012-2013 BogDan Vatra <bogdan@kde.org>
+## Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+## Contact: http://www.qt-project.org/legal
+##
+## This file is part of the test suite of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:LGPL$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and Digia. For licensing terms and
+## conditions see http://qt.digia.com/licensing. For further information
+## use the contact form at http://qt.digia.com/contact-us.
+##
+## GNU Lesser General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU Lesser
+## General Public License version 2.1 as published by the Free Software
+## Foundation and appearing in the file LICENSE.LGPL included in the
+## packaging of this file. Please review the following information to
+## ensure the GNU Lesser General Public License version 2.1 requirements
+## will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+##
+## In addition, as a special exception, Digia gives you certain additional
+## rights. These rights are described in the Digia Qt LGPL Exception
+## version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3.0 as published by the Free Software
+## Foundation and appearing in the file LICENSE.GPL included in the
+## packaging of this file. Please review the following information to
+## ensure the GNU General Public License version 3.0 requirements will be
+## met: http://www.gnu.org/copyleft/gpl.html.
+##
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+use Cwd;
+use Cwd 'abs_path';
+use File::Basename;
+use File::Temp 'tempdir';
+use File::Path 'remove_tree';
+use Getopt::Long;
+use Pod::Usage;
+
+### default options
+my @stack = cwd;
+my $device_serial=""; # "-s device_serial";
+my $packageName="org.qtproject.qt5.android.tests";
+my $intentName="$packageName/org.qtproject.qt5.android.QtActivity";
+my $jobs = 4;
+my $testsubset = "";
+my $man = 0;
+my $help = 0;
+my $make_clean = 0;
+my $deploy_qt = 0;
+my $time_out=400;
+my $android_sdk_dir = "$ENV{'ANDROID_SDK_ROOT'}";
+my $android_ndk_dir = "$ENV{'ANDROID_NDK_ROOT'}";
+my $ant_tool = `which ant`;
+chomp $ant_tool;
+my $strip_tool="";
+my $readelf_tool="";
+GetOptions('h|help' => \$help
+ , man => \$man
+ , 's|serial=s' => \$device_serial
+ , 't|test=s' => \$testsubset
+ , 'c|clean' => \$make_clean
+ , 'd|deploy' => \$deploy_qt
+ , 'j|jobs=i' => \$jobs
+ , 'sdk=s' => \$android_sdk_dir
+ , 'ndk=s' => \$android_ndk_dir
+ , 'ant=s' => \$ant_tool
+ , 'strip=s' => \$strip_tool
+ , 'readelf=s' => \$readelf_tool
+ ) or pod2usage(2);
+pod2usage(1) if $help;
+pod2usage(-verbose => 2) if $man;
+
+my $adb_tool="$android_sdk_dir/platform-tools/adb";
+system("$adb_tool devices") == 0 or die "No device found, please plug/start at least one device/emulator\n"; # make sure we have at least on device attached
+
+$device_serial = "-s $device_serial" if ($device_serial);
+$testsubset="/$testsubset" if ($testsubset);
+
+$strip_tool="$android_ndk_dir/toolchains/arm-linux-androideabi-4.7/prebuilt/linux-x86/bin/arm-linux-androideabi-strip" unless($strip_tool);
+$readelf_tool="$android_ndk_dir/toolchains/arm-linux-androideabi-4.7/prebuilt/linux-x86/bin/arm-linux-androideabi-readelf" unless($readelf_tool);
+$readelf_tool="$readelf_tool -d -w ";
+
+sub dir
+{
+# print "@stack\n";
+}
+
+sub pushd ($)
+{
+ unless ( chdir $_[0] )
+ {
+ warn "Error: $!\n";
+ return;
+ }
+ unshift @stack, cwd;
+ dir;
+}
+
+sub popd ()
+{
+ @stack > 1 and shift @stack;
+ chdir $stack[0];
+ dir;
+}
+
+
+sub waitForProcess
+{
+ my $process=shift;
+ my $action=shift;
+ my $timeout=shift;
+ my $sleepPeriod=shift;
+ $sleepPeriod=1 if !defined($sleepPeriod);
+ print "Waiting for $process ".$timeout*$sleepPeriod." seconds to";
+ print $action?" start...\n":" die...\n";
+ while ($timeout--)
+ {
+ my $output = `$adb_tool $device_serial shell ps 2>&1`; # get current processes
+ #FIXME check why $output is not matching m/.*S $process\n/ or m/.*S $process$/ (eol)
+ my $res=($output =~ m/.*S $process/)?1:0; # check the procress
+ if ($action == $res)
+ {
+ print "... succeed\n";
+ return 1;
+ }
+ sleep($sleepPeriod);
+ print "timeount in ".$timeout*$sleepPeriod." seconds\n"
+ }
+ print "... failed\n";
+ return 0;
+}
+
+my $src_dir_qt=abs_path(dirname($0)."/../../..");
+my $quadruplor_dir="$src_dir_qt/tests/auto/android";
+my $qmake_path="$src_dir_qt/bin/qmake";
+my $tests_dir="$src_dir_qt/tests$testsubset";
+my $temp_dir=tempdir(CLEANUP => 1);
+my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime(time);
+my $output_dir=$stack[0]."/".(1900+$year)."-$mon-$mday-$hour:$min";
+mkdir($output_dir);
+my $sdk_api=0;
+my $output = `$adb_tool $device_serial shell getprop`; # get device properties
+if ($output =~ m/.*\[ro.build.version.sdk\]: \[(\d+)\]/)
+{
+ $sdk_api=int($1);
+ $sdk_api=5 if ($sdk_api>5 && $sdk_api<8);
+ $sdk_api=9 if ($sdk_api>9);
+}
+
+sub reinstallQuadruplor
+{
+ pushd($quadruplor_dir);
+ system("$android_sdk_dir/tools/android update project -p . -t android-4")==0 or die "Can't update project ...\n";
+ system("$ant_tool uninstall clean debug install")==0 or die "Can't install Quadruplor\n";
+ system("$adb_tool $device_serial shell am start -n $intentName"); # create application folders
+ waitForProcess($packageName,1,10);
+ waitForProcess($packageName,0,20);
+ popd();
+}
+sub killProcess
+{
+ reinstallQuadruplor;
+# #### it seems I'm too idiot to use perl regexp
+# my $process=shift;
+# my $output = `$adb_tool $device_serial shell ps 2>&1`; # get current processes
+# $output =~ s/\r//g; # replace all "\r" with ""
+# chomp($output);
+# print $output;
+# if ($output =~ m/^.*_\d+\s+(\d+).*S $process/) # check the procress
+# {
+# print("Killing $process PID:$1\n");
+# system("$adb_tool $device_serial shell kill $1");
+# waitForProcess($process,0,20);
+# }
+# else
+# {
+# print("Can't kill the process $process\n");
+# }
+}
+
+
+sub startTest
+{
+ my $libs = shift;
+ my $mainLib = shift;
+ my $openGL = ((shift)?"true":"false");
+ system("$adb_tool $device_serial shell am start -n $intentName --ez needsOpenGl $openGL --es extra_libs \"$libs\" --es lib_name \"$mainLib\""); # start intent
+ #wait to start
+ return 0 unless(waitForProcess($packageName,1,10));
+ #wait to stop
+ unless(waitForProcess($packageName,0,$time_out,5))
+ {
+ killProcess($packageName);
+ return 1;
+ }
+ my $output_file = shift;
+ system("$adb_tool $device_serial pull /data/data/$packageName/app_files/output.xml $output_dir/$output_file");
+ return 1;
+}
+
+sub needsOpenGl
+{
+ my $app=$readelf_tool.shift.' |grep -e "^.*(NEEDED).*Shared library: \[libQtOpenGL\.so\]$"';
+ my $res=`$app`;
+ chomp $res;
+ return $res;
+}
+
+########### delpoy qt libs ###########
+if ($deploy_qt)
+{
+
+ pushd($src_dir_qt);
+ mkdir("$temp_dir/lib");
+ my @libs=`find lib -name *.so`; # libs must be handled diferently
+ foreach (@libs)
+ {
+ chomp;
+ print ("cp -L $_ $temp_dir/lib\n");
+ system("cp -L $_ $temp_dir/lib");
+ }
+ system("cp -a plugins $temp_dir");
+ system("cp -a imports $temp_dir");
+ system("cp -a qml $temp_dir");
+ pushd($temp_dir);
+ system("find -name *.so | xargs $strip_tool --strip-unneeded");
+ popd;
+ system("$adb_tool $device_serial shell rm -r /data/local/tmp/qt"); # remove old qt libs
+ system("$adb_tool $device_serial push $temp_dir /data/local/tmp/qt"); # copy newer qt libs
+ popd;
+}
+
+########### build & install quadruplor ###########
+reinstallQuadruplor;
+
+########### build qt tests and benchmarks ###########
+pushd($tests_dir);
+print "Building $tests_dir \n";
+system("make distclean") if ($make_clean);
+system("$qmake_path CONFIG-=QTDIR_build -r") == 0 or die "Can't run qmake\n"; #exec qmake
+system("make -j$jobs") == 0 or warn "Can't build all tests\n"; #exec make
+my $testsFiles=`find . -name libtst_*.so`; # only tests
+foreach (split("\n",$testsFiles))
+{
+ chomp; #remove white spaces
+ pushd(abs_path(dirname($_))); # cd to application dir
+ system("make INSTALL_ROOT=$temp_dir install"); # install the application to temp dir
+ system("$adb_tool $device_serial shell rm -r /data/data/$packageName/app_files/*"); # remove old data
+ system("$adb_tool $device_serial push $temp_dir /data/data/$packageName/app_files"); # copy
+ my $application=basename(cwd);
+ my $output_name=dirname($_);
+ $output_name =~ s/\.//; # remove first "." character
+ $output_name =~ s/\///; # remove first "/" character
+ $output_name =~ s/\//_/g; # replace all "/" with "_"
+ $output_name=$application unless($output_name);
+ $time_out=5*60/5; # 5 minutes time out for a normal test
+ if (-e "$temp_dir/libtst_bench_$application.so")
+ {
+ $time_out=5*60/5; # 10 minutes for a benchmark
+ $application = "bench_$application";
+ }
+
+ if (-e "$temp_dir/libtst_$application.so")
+ {
+ if (needsOpenGl("$temp_dir/libtst_$application.so"))
+ {
+ startTest("/data/local/tmp/qt/plugins/platforms/android/libqtforandroidGL.so", "/data/data/$packageName/app_files/libtst_$application.so", 1
+ , "$output_name.xml") or warn "Can't run $application ...\n";
+ }
+ else
+ {
+ startTest("/data/local/tmp/qt/plugins/platforms/android/libqtforandroid.so", "/data/data/$packageName/app_files/libtst_$application.so", 0
+ , "$output_name.xml") or warn "Can't run $application stopping tests ...\n";
+ }
+ }
+ else
+ { #ups this test application doesn't respect name convention
+ warn "$application test application doesn't respect name convention please fix it !\n";
+ }
+ popd();
+ remove_tree( $temp_dir, {keep_root => 1} );
+}
+popd();
+
+__END__
+
+=head1 NAME
+
+Script to run all qt tests/benchmarks to an android device/emulator
+
+=head1 SYNOPSIS
+
+runtests.pl [options]
+
+=head1 OPTIONS
+
+=over 8
+
+=item B<-s --serial = serial>
+
+Device serial number. May be empty if only one device is attached.
+
+=item B<-t --test = test_subset>
+
+Tests subset (e.g. benchmarks, auto, auto/qbuffer, etc.).
+
+=item B<-d --deploy>
+
+Deploy current qt libs.
+
+=item B<-c --clean>
+
+Clean tests before building them.
+
+=item B<-j --jobs = number>
+
+Make jobs when building tests.
+
+=item B<--sdk = sdk_path>
+
+Android SDK path.
+
+=item B<--ndk = ndk_path>
+
+Android NDK path.
+
+=item B<--ant = ant_tool_path>
+
+Ant tool path.
+
+=item B<--strip = strip_tool_path>
+
+Android strip tool path, used to deploy qt libs.
+
+=item B<--readelf = readelf_tool_path>
+
+Android readelf tool path, used to check if a test application uses qt OpenGL.
+
+=item B<-h --help>
+
+Print a brief help message and exits.
+
+=item B<--man>
+
+Prints the manual page and exits.
+
+=back
+
+=head1 DESCRIPTION
+
+B<This program> will run all qt tests/benchmarks to an android device/emulator.
+
+=cut
diff --git a/tests/auto/android/src/org/qtproject/qt5/android/QtActivity.java b/tests/auto/android/src/org/qtproject/qt5/android/QtActivity.java
new file mode 100644
index 0000000000..6242f55488
--- /dev/null
+++ b/tests/auto/android/src/org/qtproject/qt5/android/QtActivity.java
@@ -0,0 +1,328 @@
+/*
+ Copyright (c) 2012, BogDan Vatra <bogdan@kde.org>
+ Contact: http://www.qt-project.org/legal
+
+ 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 AUTHOR ``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 AUTHOR 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.
+*/
+
+package org.qtproject.qt5.android;
+
+import java.io.File;
+import java.util.ArrayList;
+import java.util.Iterator;
+
+import org.qtproject.qt5.android.tests.R;
+
+import android.app.Activity;
+import android.content.Context;
+import android.content.res.Configuration;
+import android.graphics.Rect;
+import android.os.Bundle;
+import android.text.method.MetaKeyKeyListener;
+import android.util.DisplayMetrics;
+import android.util.Log;
+import android.view.KeyCharacterMap;
+import android.view.KeyEvent;
+import android.view.Menu;
+import android.view.MenuItem;
+import android.view.Window;
+import android.view.WindowManager;
+import android.view.inputmethod.InputMethodManager;
+
+public class QtActivity extends Activity {
+ private int m_id =- 1;
+ private boolean softwareKeyboardIsVisible = false;
+ private long m_metaState;
+ private int m_lastChar = 0;
+ private boolean m_fullScreen = false;
+ private boolean m_started = false;
+ private QtSurface m_surface = null;
+ private boolean m_usesGL = false;
+ private void loadQtLibs(String[] libs, String environment, String params, String mainLib, String nativeLibDir) throws Exception
+ {
+ QtNative.loadQtLibraries(libs);
+ // start application
+
+ final String envPaths = "NECESSITAS_API_LEVEL=2\tHOME=" + getDir("files", MODE_WORLD_WRITEABLE).getAbsolutePath() +
+ "\tTMPDIR=" + getDir("files", MODE_WORLD_WRITEABLE).getAbsolutePath() +
+ "\tCACHE_PATH=" + getDir("files", MODE_WORLD_WRITEABLE).getAbsolutePath();
+ if (environment != null && environment.length() > 0)
+ environment = envPaths + "\t" + environment;
+ else
+ environment = envPaths;
+
+ try {
+ Thread.sleep(5000);
+ } catch (InterruptedException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ QtNative.startApplication(params, environment, mainLib, nativeLibDir);
+ m_surface.applicationStarted(m_usesGL);
+ m_started = true;
+ }
+
+ private boolean m_quitApp = true;
+ private Process m_debuggerProcess = null; // debugger process
+
+ private void startApp(final boolean firstStart)
+ {
+ try {
+ String qtLibs[] = getResources().getStringArray(R.array.qt_libs);
+ ArrayList<String> libraryList = new ArrayList<String>();
+ for (int i = 0; i < qtLibs.length; i++)
+ libraryList.add("/data/local/tmp/qt/lib/lib" + qtLibs[i] + ".so");
+
+ String mainLib = null;
+ String nativeLibDir = null;
+ if (getIntent().getExtras() != null) {
+ if (getIntent().getExtras().containsKey("extra_libs")) {
+ String extra_libs = getIntent().getExtras().getString("extra_libs");
+ for (String lib : extra_libs.split(":"))
+ libraryList.add(lib);
+ }
+ if (getIntent().getExtras().containsKey("lib_name")) {
+ mainLib = getIntent().getExtras().getString("lib_name");
+ int slash = mainLib.lastIndexOf("/");
+ if (slash >= 0) {
+ nativeLibDir = mainLib.substring(0, slash+1);
+ mainLib = mainLib.substring(slash+1+3, mainLib.length()-3); //remove lib and .so
+ } else {
+ nativeLibDir = "";
+ }
+ }
+
+ if (getIntent().getExtras().containsKey("needsOpenGl"))
+ m_usesGL = getIntent().getExtras().getBoolean("needsOpenGl");
+ } else {
+ try {
+ Thread.sleep(5000);
+ } catch (InterruptedException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ System.exit(0);
+ }
+ String[] libs = new String[libraryList.size()];
+ libs = libraryList.toArray(libs);
+ loadQtLibs(libs
+ ,"QT_QPA_EGLFS_HIDECURSOR=1\tQML2_IMPORT_PATH=/data/local/tmp/qt/qml\tQML_IMPORT_PATH=/data/local/tmp/qt/imports\tQT_PLUGIN_PATH=/data/local/tmp/qt/plugins"
+ , "-xml\t-silent\t-o\toutput.xml", mainLib, nativeLibDir);
+ } catch (Exception e) {
+ Log.e(QtNative.QtTAG, "Can't create main activity", e);
+ }
+ }
+
+ @Override
+ public void onCreate(Bundle savedInstanceState)
+ {
+ super.onCreate(savedInstanceState);
+ getDir("files", MODE_WORLD_WRITEABLE);
+ requestWindowFeature(Window.FEATURE_NO_TITLE);
+ m_quitApp = true;
+ QtNative.setMainActivity(this);
+ if (null == getLastNonConfigurationInstance()) {
+ DisplayMetrics metrics = new DisplayMetrics();
+ getWindowManager().getDefaultDisplay().getMetrics(metrics);
+ QtNative.setApplicationDisplayMetrics(metrics.widthPixels, metrics.heightPixels,
+ metrics.widthPixels, metrics.heightPixels,
+ metrics.xdpi, metrics.ydpi);
+ }
+ m_surface = new QtSurface(this, m_id);
+ setContentView(m_surface);
+ if (null == getLastNonConfigurationInstance())
+ startApp(true);
+ }
+
+ public QtSurface getQtSurface()
+ {
+ return m_surface;
+ }
+
+ @Override
+ public Object onRetainNonConfigurationInstance()
+ {
+ super.onRetainNonConfigurationInstance();
+ m_quitApp = false;
+ return true;
+ }
+
+ @Override
+ protected void onDestroy()
+ {
+ QtNative.setMainActivity(null);
+ super.onDestroy();
+ if (m_quitApp) {
+ Log.i(QtNative.QtTAG, "onDestroy");
+ if (m_debuggerProcess != null)
+ m_debuggerProcess.destroy();
+ System.exit(0);// FIXME remove it or find a better way
+ }
+ QtNative.setMainActivity(null);
+ }
+
+ @Override
+ protected void onResume()
+ {
+ // fire all lostActions
+ synchronized (QtNative.m_mainActivityMutex) {
+ Iterator<Runnable> itr = QtNative.getLostActions().iterator();
+ while (itr.hasNext())
+ runOnUiThread(itr.next());
+ if (m_started) {
+ QtNative.clearLostActions();
+ QtNative.updateWindow();
+ }
+ }
+ super.onResume();
+ }
+
+ public void redrawWindow(int left, int top, int right, int bottom)
+ {
+ m_surface.drawBitmap(new Rect(left, top, right, bottom));
+ }
+
+ public void setFullScreen(boolean enterFullScreen)
+ {
+ if (m_fullScreen == enterFullScreen)
+ return;
+ if (m_fullScreen = enterFullScreen)
+ getWindow().addFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
+ else
+ getWindow().clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
+ }
+
+ @Override
+ protected void onSaveInstanceState(Bundle outState)
+ {
+ super.onSaveInstanceState(outState);
+ outState.putBoolean("FullScreen", m_fullScreen);
+ outState.putBoolean("Started", m_started);
+ }
+
+ @Override
+ protected void onRestoreInstanceState(Bundle savedInstanceState)
+ {
+ super.onRestoreInstanceState(savedInstanceState);
+ setFullScreen(savedInstanceState.getBoolean("FullScreen"));
+ m_started = savedInstanceState.getBoolean("Started");
+ if (m_started)
+ m_surface.applicationStarted(true);
+ }
+
+ public void showSoftwareKeyboard()
+ {
+ softwareKeyboardIsVisible = true;
+ InputMethodManager imm = (InputMethodManager)getSystemService(Context.INPUT_METHOD_SERVICE);
+ imm.toggleSoftInput(InputMethodManager.SHOW_FORCED, InputMethodManager.HIDE_IMPLICIT_ONLY);
+ }
+
+ public void resetSoftwareKeyboard()
+ {
+ }
+
+ public void hideSoftwareKeyboard()
+ {
+ if (softwareKeyboardIsVisible) {
+ InputMethodManager imm = (InputMethodManager)getSystemService(Context.INPUT_METHOD_SERVICE);
+ imm.toggleSoftInput(0, 0);
+ }
+ softwareKeyboardIsVisible = false;
+ }
+
+ @Override
+ public boolean dispatchKeyEvent(KeyEvent event)
+ {
+ if (m_started && event.getAction() == KeyEvent.ACTION_MULTIPLE &&
+ event.getCharacters() != null &&
+ event.getCharacters().length() == 1 &&
+ event.getKeyCode() == 0) {
+ Log.i(QtNative.QtTAG, "dispatchKeyEvent at MULTIPLE with one character: " + event.getCharacters());
+ QtNative.keyDown(0, event.getCharacters().charAt(0), event.getMetaState());
+ QtNative.keyUp(0, event.getCharacters().charAt(0), event.getMetaState());
+ }
+
+ return super.dispatchKeyEvent(event);
+ }
+
+ @Override
+ public boolean onKeyDown(int keyCode, KeyEvent event)
+ {
+ if (!m_started)
+ return false;
+ m_metaState = MetaKeyKeyListener.handleKeyDown(m_metaState, keyCode, event);
+ int c = event.getUnicodeChar(MetaKeyKeyListener.getMetaState(m_metaState));
+ int lc = c;
+ m_metaState = MetaKeyKeyListener.adjustMetaAfterKeypress(m_metaState);
+
+ if ((c & KeyCharacterMap.COMBINING_ACCENT) != 0) {
+ c = c & KeyCharacterMap.COMBINING_ACCENT_MASK;
+ int composed = KeyEvent.getDeadChar(m_lastChar, c);
+ c = composed;
+ }
+ m_lastChar = lc;
+ if (keyCode != KeyEvent.KEYCODE_BACK)
+ QtNative.keyDown(keyCode, c, event.getMetaState());
+ return true;
+ }
+
+ @Override
+ public boolean onKeyUp(int keyCode, KeyEvent event)
+ {
+ if (!m_started)
+ return false;
+ m_metaState = MetaKeyKeyListener.handleKeyUp(m_metaState, keyCode, event);
+ QtNative.keyUp(keyCode, event.getUnicodeChar(), event.getMetaState());
+ return true;
+ }
+
+ public void onConfigurationChanged(Configuration newConfig) {
+ super.onConfigurationChanged(newConfig);
+ }
+
+/* public boolean onCreateOptionsMenu(Menu menu)
+ {
+ QtNative.createOptionsMenu(menu);
+ try {
+ return onPrepareOptionsMenu(menu);
+ } catch (Exception e) {
+ e.printStackTrace();
+ return false;
+ }
+ }
+
+ public boolean onPrepareOptionsMenu(Menu menu)
+ {
+ QtNative.prepareOptionsMenu(menu);
+ try {
+ return (Boolean) onPrepareOptionsMenu(menu);
+ } catch (Exception e) {
+ e.printStackTrace();
+ return false;
+ }
+ }
+
+ public boolean onOptionsItemSelected(MenuItem item)
+ {
+ return QtNative.optionsItemSelected(item.getGroupId(), item.getItemId());
+ }*/
+}
diff --git a/tests/auto/android/src/org/qtproject/qt5/android/QtInputConnection.java b/tests/auto/android/src/org/qtproject/qt5/android/QtInputConnection.java
new file mode 100644
index 0000000000..e69a03061b
--- /dev/null
+++ b/tests/auto/android/src/org/qtproject/qt5/android/QtInputConnection.java
@@ -0,0 +1,209 @@
+/*
+ Copyright (c) 2012, BogDan Vatra <bogdan@kde.org>
+ Contact: http://www.qt-project.org/legal
+
+ 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 AUTHOR ``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 AUTHOR 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.
+*/
+
+package org.qtproject.qt5.android;
+
+import android.content.Context;
+import android.content.Intent;
+import android.text.Editable;
+import android.text.InputFilter;
+import android.util.Log;
+import android.view.KeyEvent;
+import android.view.View;
+import android.view.inputmethod.BaseInputConnection;
+import android.view.inputmethod.CompletionInfo;
+import android.view.inputmethod.ExtractedText;
+import android.view.inputmethod.ExtractedTextRequest;
+import android.view.inputmethod.InputMethodManager;
+
+class QtExtractedText
+{
+ public int partialEndOffset;
+ public int partialStartOffset;
+ public int selectionEnd;
+ public int selectionStart;
+ public int startOffset;
+ public String text;
+}
+
+class QtNativeInputConnection
+{
+ static native boolean commitText(String text, int newCursorPosition);
+ static native boolean commitCompletion(String text, int position);
+ static native boolean deleteSurroundingText(int leftLength, int rightLength);
+ static native boolean finishComposingText();
+ static native int getCursorCapsMode(int reqModes);
+ static native QtExtractedText getExtractedText(int hintMaxChars, int hintMaxLines, int flags);
+ static native String getSelectedText(int flags);
+ static native String getTextAfterCursor(int length, int flags);
+ static native String getTextBeforeCursor(int length, int flags);
+ static native boolean setComposingText(String text, int newCursorPosition);
+ static native boolean setSelection(int start, int end);
+ static native boolean selectAll();
+ static native boolean cut();
+ static native boolean copy();
+ static native boolean copyURL();
+ static native boolean paste();
+}
+
+public class QtInputConnection extends BaseInputConnection
+{
+ private static final int ID_SELECT_ALL = android.R.id.selectAll;
+ private static final int ID_START_SELECTING_TEXT = android.R.id.startSelectingText;
+ private static final int ID_STOP_SELECTING_TEXT = android.R.id.stopSelectingText;
+ private static final int ID_CUT = android.R.id.cut;
+ private static final int ID_COPY = android.R.id.copy;
+ private static final int ID_PASTE = android.R.id.paste;
+ private static final int ID_COPY_URL = android.R.id.copyUrl;
+ private static final int ID_SWITCH_INPUT_METHOD = android.R.id.switchInputMethod;
+ private static final int ID_ADD_TO_DICTIONARY = android.R.id.addToDictionary;
+ View m_view;
+
+ public QtInputConnection(View targetView)
+ {
+ super(targetView, true);
+ m_view = targetView;
+ }
+
+ @Override
+ public boolean beginBatchEdit()
+ {
+ return true;
+ }
+
+ @Override
+ public boolean endBatchEdit()
+ {
+ return true;
+ }
+
+ @Override
+ public boolean commitCompletion(CompletionInfo text)
+ {
+ return QtNativeInputConnection.commitCompletion(text.getText().toString(), text.getPosition());
+ }
+
+ @Override
+ public boolean commitText(CharSequence text, int newCursorPosition)
+ {
+ return QtNativeInputConnection.commitText(text.toString(), newCursorPosition);
+ }
+
+ @Override
+ public boolean deleteSurroundingText(int leftLength, int rightLength)
+ {
+ return QtNativeInputConnection.deleteSurroundingText(leftLength, rightLength);
+ }
+
+ @Override
+ public boolean finishComposingText()
+ {
+ return QtNativeInputConnection.finishComposingText();
+ }
+
+ @Override
+ public int getCursorCapsMode(int reqModes)
+ {
+ return QtNativeInputConnection.getCursorCapsMode(reqModes);
+ }
+
+ @Override
+ public ExtractedText getExtractedText(ExtractedTextRequest request, int flags)
+ {
+ QtExtractedText qExtractedText = QtNativeInputConnection.getExtractedText(request.hintMaxChars, request.hintMaxLines, flags);
+ ExtractedText extractedText = new ExtractedText();
+ extractedText.partialEndOffset = qExtractedText.partialEndOffset;
+ extractedText.partialStartOffset = qExtractedText.partialStartOffset;
+ extractedText.selectionEnd = qExtractedText.selectionEnd;
+ extractedText.selectionStart = qExtractedText.selectionStart;
+ extractedText.startOffset = qExtractedText.startOffset;
+ extractedText.text = qExtractedText.text;
+ return extractedText;
+ }
+
+ public CharSequence getSelectedText(int flags)
+ {
+ return QtNativeInputConnection.getSelectedText(flags);
+ }
+
+ @Override
+ public CharSequence getTextAfterCursor(int length, int flags)
+ {
+ return QtNativeInputConnection.getTextAfterCursor(length, flags);
+ }
+
+ @Override
+ public CharSequence getTextBeforeCursor(int length, int flags)
+ {
+ return QtNativeInputConnection.getTextBeforeCursor(length, flags);
+ }
+
+ @Override
+ public boolean performContextMenuAction(int id)
+ {
+ switch (id) {
+ case ID_SELECT_ALL:
+ return QtNativeInputConnection.selectAll();
+ case ID_COPY:
+ return QtNativeInputConnection.copy();
+ case ID_COPY_URL:
+ return QtNativeInputConnection.copyURL();
+ case ID_CUT:
+ return QtNativeInputConnection.cut();
+ case ID_PASTE:
+ return QtNativeInputConnection.paste();
+
+ case ID_SWITCH_INPUT_METHOD:
+ InputMethodManager imm = (InputMethodManager)m_view.getContext().getSystemService(Context.INPUT_METHOD_SERVICE);
+ if (imm != null) {
+ imm.showInputMethodPicker();
+ }
+ return true;
+
+ case ID_ADD_TO_DICTIONARY:
+// TODO
+// String word = m_editable.subSequence(0, m_editable.length()).toString();
+// if (word != null) {
+// Intent i = new Intent("com.android.settings.USER_DICTIONARY_INSERT");
+// i.putExtra("word", word);
+// i.setFlags(i.getFlags() | Intent.FLAG_ACTIVITY_NEW_TASK);
+// m_view.getContext().startActivity(i);
+// }
+ return true;
+ }
+ return super.performContextMenuAction(id);
+ }
+
+ @Override
+ public boolean setComposingText(CharSequence text, int newCursorPosition) {
+ return QtNativeInputConnection.setComposingText(text.toString(), newCursorPosition);
+ }
+
+ @Override
+ public boolean setSelection(int start, int end) {
+ return QtNativeInputConnection.setSelection(start, end);
+ }
+}
diff --git a/tests/auto/android/src/org/qtproject/qt5/android/QtNative.java b/tests/auto/android/src/org/qtproject/qt5/android/QtNative.java
new file mode 100644
index 0000000000..d9995e3178
--- /dev/null
+++ b/tests/auto/android/src/org/qtproject/qt5/android/QtNative.java
@@ -0,0 +1,466 @@
+/*
+ Copyright (c) 2012, BogDan Vatra <bogdan@kde.org>
+ Contact: http://www.qt-project.org/legal
+
+ 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 AUTHOR ``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 AUTHOR 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.
+*/
+
+package org.qtproject.qt5.android;
+
+import java.io.File;
+import java.util.ArrayList;
+
+import android.app.Activity;
+import android.app.Application;
+import android.content.Intent;
+import android.net.Uri;
+import android.util.Log;
+import android.view.ContextMenu;
+import android.view.Menu;
+import android.view.MotionEvent;
+
+public class QtNative extends Application
+{
+ private static QtActivity m_mainActivity = null;
+ private static QtSurface m_mainView = null;
+ public static Object m_mainActivityMutex = new Object(); // mutex used to synchronize runnable operations
+
+ public static final String QtTAG = "Qt JAVA"; // string used for Log.x
+ private static ArrayList<Runnable> m_lostActions = new ArrayList<Runnable>(); // a list containing all actions which could not be performed (e.g. the main activity is destroyed, etc.)
+ private static boolean m_started = false;
+ private static int m_displayMetricsScreenWidthPixels = 0;
+ private static int m_displayMetricsScreenHeightPixels = 0;
+ private static int m_displayMetricsDesktopWidthPixels = 0;
+ private static int m_displayMetricsDesktopHeightPixels = 0;
+ private static double m_displayMetricsXDpi = .0;
+ private static double m_displayMetricsYDpi = .0;
+ private static int m_oldx, m_oldy;
+ private static final int m_moveThreshold = 0;
+
+ public static ClassLoader classLoader()
+ {
+ return m_mainActivity.getClassLoader();
+ }
+
+ public static Activity activity()
+ {
+ return m_mainActivity;
+ }
+
+ public static QtSurface mainView()
+ {
+ return m_mainView;
+ }
+
+ public static void openURL(String url)
+ {
+ Uri uri = Uri.parse(url);
+ Intent intent = new Intent(Intent.ACTION_VIEW, uri);
+ activity().startActivity(intent);
+ }
+
+ // this method loads full path libs
+ public static void loadQtLibraries(String[] libraries)
+ {
+ if (libraries == null)
+ return;
+
+ for (int i = 0; i < libraries.length; i++) {
+ try {
+ File f = new File(libraries[i]);
+ if (f.exists())
+ System.load(libraries[i]);
+ } catch (SecurityException e) {
+ Log.i(QtTAG, "Can't load '" + libraries[i] + "'", e);
+ } catch (Exception e) {
+ Log.i(QtTAG, "Can't load '" + libraries[i] + "'", e);
+ }
+ }
+ }
+
+ // this method loads bundled libs by name.
+ public static void loadBundledLibraries(String[] libraries)
+ {
+ for (int i = 0; i < libraries.length; i++) {
+ try {
+ System.loadLibrary(libraries[i]);
+ } catch (UnsatisfiedLinkError e) {
+ Log.i(QtTAG, "Can't load '" + libraries[i] + "'", e);
+ } catch (SecurityException e) {
+ Log.i(QtTAG, "Can't load '" + libraries[i] + "'", e);
+ } catch (Exception e) {
+ Log.i(QtTAG, "Can't load '" + libraries[i] + "'", e);
+ }
+ }
+ }
+
+ public static void setMainActivity(QtActivity qtMainActivity)
+ {
+ synchronized (m_mainActivityMutex) {
+ m_mainActivity = qtMainActivity;
+ }
+ }
+ public static void setMainView(QtSurface qtSurface)
+ {
+ synchronized (m_mainActivityMutex) {
+ m_mainView = qtSurface;
+ }
+ }
+
+ static public ArrayList<Runnable> getLostActions()
+ {
+ return m_lostActions;
+ }
+
+ static public void clearLostActions()
+ {
+ m_lostActions.clear();
+ }
+
+ private static boolean runAction(Runnable action)
+ {
+ synchronized (m_mainActivityMutex) {
+ if (m_mainActivity == null)
+ m_lostActions.add(action);
+ else
+ m_mainActivity.runOnUiThread(action);
+ return m_mainActivity != null;
+ }
+ }
+
+ public static boolean startApplication(String params, String environment, String mainLibrary, String nativeLibraryDir) throws Exception
+ {
+ File f = new File(nativeLibraryDir+"lib"+mainLibrary+".so");
+ if (!f.exists())
+ throw new Exception("Can't find main library '" + mainLibrary + "'");
+
+ if (params == null)
+ params = "-platform\tandroid";
+
+ boolean res = false;
+ synchronized (m_mainActivityMutex) {
+ res = startQtAndroidPlugin();
+ setDisplayMetrics(m_displayMetricsScreenWidthPixels,
+ m_displayMetricsScreenHeightPixels,
+ m_displayMetricsDesktopWidthPixels,
+ m_displayMetricsDesktopHeightPixels,
+ m_displayMetricsXDpi,
+ m_displayMetricsYDpi);
+ startQtApplication(f.getAbsolutePath()+"\t"+params, environment);
+ m_started = true;
+ }
+ return res;
+ }
+
+ public static void setApplicationDisplayMetrics(int screenWidthPixels,
+ int screenHeightPixels, int desktopWidthPixels,
+ int desktopHeightPixels, double XDpi, double YDpi)
+ {
+ /* Fix buggy dpi report */
+ if (XDpi < android.util.DisplayMetrics.DENSITY_LOW)
+ XDpi = android.util.DisplayMetrics.DENSITY_LOW;
+ if (YDpi < android.util.DisplayMetrics.DENSITY_LOW)
+ YDpi = android.util.DisplayMetrics.DENSITY_LOW;
+
+ synchronized (m_mainActivityMutex) {
+ if (m_started) {
+ setDisplayMetrics(screenWidthPixels, screenHeightPixels, desktopWidthPixels, desktopHeightPixels, XDpi, YDpi);
+ } else {
+ m_displayMetricsScreenWidthPixels = screenWidthPixels;
+ m_displayMetricsScreenHeightPixels = screenHeightPixels;
+ m_displayMetricsDesktopWidthPixels = desktopWidthPixels;
+ m_displayMetricsDesktopHeightPixels = desktopHeightPixels;
+ m_displayMetricsXDpi = XDpi;
+ m_displayMetricsYDpi = YDpi;
+ }
+ }
+ }
+
+ public static void pauseApplication()
+ {
+ synchronized (m_mainActivityMutex) {
+ if (m_started)
+ pauseQtApp();
+ }
+ }
+
+ public static void resumeApplication()
+ {
+ synchronized (m_mainActivityMutex) {
+ if (m_started) {
+ resumeQtApp();
+ updateWindow();
+ }
+ }
+ }
+ // application methods
+ public static native void startQtApplication(String params, String env);
+ public static native void pauseQtApp();
+ public static native void resumeQtApp();
+ public static native boolean startQtAndroidPlugin();
+ public static native void quitQtAndroidPlugin();
+ public static native void terminateQt();
+ // application methods
+
+ private static void quitApp()
+ {
+ m_mainActivity.finish();
+ }
+
+ private static void redrawSurface(final int left, final int top, final int right, final int bottom )
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_mainActivity.redrawWindow(left, top, right, bottom);
+ }
+ });
+ }
+
+ @Override
+ public void onTerminate()
+ {
+ if (m_started)
+ terminateQt();
+ super.onTerminate();
+ }
+
+
+ static public void sendTouchEvent(MotionEvent event, int id)
+ {
+ switch (event.getAction()) {
+ case MotionEvent.ACTION_UP:
+ mouseUp(id,(int) event.getX(), (int) event.getY());
+ break;
+
+ case MotionEvent.ACTION_DOWN:
+ mouseDown(id,(int) event.getX(), (int) event.getY());
+ m_oldx = (int) event.getX();
+ m_oldy = (int) event.getY();
+ break;
+
+ case MotionEvent.ACTION_MOVE:
+ int dx = (int) (event.getX() - m_oldx);
+ int dy = (int) (event.getY() - m_oldy);
+ if (Math.abs(dx) > m_moveThreshold || Math.abs(dy) > m_moveThreshold) {
+ mouseMove(id,(int) event.getX(), (int) event.getY());
+ m_oldx = (int) event.getX();
+ m_oldy = (int) event.getY();
+ }
+ break;
+ }
+ }
+
+ static public void sendTrackballEvent(MotionEvent event, int id)
+ {
+ switch (event.getAction()) {
+ case MotionEvent.ACTION_UP:
+ mouseUp(id, (int) event.getX(), (int) event.getY());
+ break;
+
+ case MotionEvent.ACTION_DOWN:
+ mouseDown(id, (int) event.getX(), (int) event.getY());
+ m_oldx = (int) event.getX();
+ m_oldy = (int) event.getY();
+ break;
+
+ case MotionEvent.ACTION_MOVE:
+ int dx = (int) (event.getX() - m_oldx);
+ int dy = (int) (event.getY() - m_oldy);
+ if (Math.abs(dx) > 5 || Math.abs(dy) > 5) {
+ mouseMove(id, (int) event.getX(), (int) event.getY());
+ m_oldx = (int) event.getX();
+ m_oldy = (int) event.getY();
+ }
+ break;
+ }
+ }
+
+ private static void updateSelection(final int selStart, final int selEnd, final int candidatesStart, final int candidatesEnd)
+ {
+ }
+
+ private static void showSoftwareKeyboard(final int x, final int y
+ , final int width, final int height
+ , final int inputHints )
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_mainActivity.showSoftwareKeyboard();
+ }
+ });
+ }
+
+ private static void resetSoftwareKeyboard()
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_mainActivity.resetSoftwareKeyboard();
+ }
+ });
+ }
+
+ private static void hideSoftwareKeyboard()
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_mainActivity.hideSoftwareKeyboard();
+ }
+ });
+ }
+
+ private static boolean isSoftwareKeyboardVisible()
+ {
+ return false;
+ }
+
+ private static void setFullScreen(final boolean fullScreen)
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ m_mainActivity.setFullScreen(fullScreen);
+ updateWindow();
+ }
+ });
+ }
+
+ private static void registerClipboardManager()
+ {
+ }
+
+ private static void setClipboardText(String text)
+ {
+ }
+
+ private static boolean hasClipboardText()
+ {
+ return false;
+ }
+
+ private static String getClipboardText()
+ {
+ return "Qt";
+ }
+
+ private static void openContextMenu()
+ {
+ }
+
+ private static void closeContextMenu()
+ {
+ }
+
+ private static void resetOptionsMenu()
+ {
+ }
+
+ // screen methods
+ public static native void setDisplayMetrics(int screenWidthPixels,
+ int screenHeightPixels, int desktopWidthPixels,
+ int desktopHeightPixels, double XDpi, double YDpi);
+ public static native void handleOrientationChanged(int newOrientation);
+ // screen methods
+
+ private static void showOptionsMenu()
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ if (m_mainActivity != null)
+ m_mainActivity.openOptionsMenu();
+ }
+ });
+ }
+
+ private static void hideOptionsMenu()
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ if (m_mainActivity != null)
+ m_mainActivity.closeOptionsMenu();
+ }
+ });
+ }
+
+ private static void showContextMenu()
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ if (m_mainActivity != null)
+ m_mainActivity.openContextMenu(m_mainView);
+ }
+ });
+ }
+
+ private static void hideContextMenu()
+ {
+ runAction(new Runnable() {
+ @Override
+ public void run() {
+ if (m_mainActivity != null)
+ m_mainActivity.closeContextMenu();
+ }
+ });
+ }
+
+ // pointer methods
+ public static native void mouseDown(int winId, int x, int y);
+ public static native void mouseUp(int winId, int x, int y);
+ public static native void mouseMove(int winId, int x, int y);
+ public static native void touchBegin(int winId);
+ public static native void touchAdd(int winId, int pointerId, int action, boolean primary, int x, int y, float size, float pressure);
+ public static native void touchEnd(int winId, int action);
+ public static native void longPress(int winId, int x, int y);
+ // pointer methods
+
+ // keyboard methods
+ public static native void keyDown(int key, int unicode, int modifier);
+ public static native void keyUp(int key, int unicode, int modifier);
+ // keyboard methods
+
+ // surface methods
+ public static native void destroySurface();
+ public static native void setSurface(Object surface);
+ public static native void lockSurface();
+ public static native void unlockSurface();
+ // surface methods
+
+ // window methods
+ public static native void updateWindow();
+ // window methods
+
+ // menu methods
+ public static native boolean onPrepareOptionsMenu(Menu menu);
+ public static native boolean onOptionsItemSelected(int itemId, boolean checked);
+ public static native void onOptionsMenuClosed(Menu menu);
+
+ public static native void onCreateContextMenu(ContextMenu menu);
+ public static native boolean onContextItemSelected(int itemId, boolean checked);
+ public static native void onContextMenuClosed(Menu menu);
+ // menu methods
+}
diff --git a/tests/auto/android/src/org/qtproject/qt5/android/QtSurface.java b/tests/auto/android/src/org/qtproject/qt5/android/QtSurface.java
new file mode 100644
index 0000000000..7e7db031ec
--- /dev/null
+++ b/tests/auto/android/src/org/qtproject/qt5/android/QtSurface.java
@@ -0,0 +1,163 @@
+/*
+ Copyright (c) 2012, BogDan Vatra <bogdan@kde.org>
+ Contact: http://www.qt-project.org/legal
+
+ 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 AUTHOR ``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 AUTHOR 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.
+*/
+
+package org.qtproject.qt5.android;
+
+import android.app.Activity;
+import android.content.Context;
+import android.graphics.Bitmap;
+import android.graphics.Canvas;
+import android.graphics.PixelFormat;
+import android.graphics.Rect;
+import android.util.DisplayMetrics;
+import android.util.Log;
+import android.view.MotionEvent;
+import android.view.SurfaceHolder;
+import android.view.SurfaceView;
+
+public class QtSurface extends SurfaceView implements SurfaceHolder.Callback
+{
+ private Bitmap m_bitmap=null;
+ private boolean m_started = false;
+ private boolean m_usesGL = false;
+ public QtSurface(Context context, int id)
+ {
+ super(context);
+ setFocusable(true);
+ getHolder().addCallback(this);
+ getHolder().setType(SurfaceHolder.SURFACE_TYPE_GPU);
+ setId(id);
+ }
+
+ public void applicationStarted(boolean usesGL)
+ {
+ m_started = true;
+ m_usesGL = usesGL;
+ if (getWidth() < 1 || getHeight() < 1)
+ return;
+ if (m_usesGL) {
+ QtNative.setSurface(getHolder().getSurface());
+ } else {
+ QtNative.lockSurface();
+ QtNative.setSurface(null);
+ m_bitmap=Bitmap.createBitmap(getWidth(), getHeight(), Bitmap.Config.RGB_565);
+ QtNative.setSurface(m_bitmap);
+ QtNative.unlockSurface();
+ }
+ }
+
+ @Override
+ public void surfaceCreated(SurfaceHolder holder)
+ {
+ DisplayMetrics metrics = new DisplayMetrics();
+ ((Activity) getContext()).getWindowManager().getDefaultDisplay().getMetrics(metrics);
+ QtNative.setApplicationDisplayMetrics(metrics.widthPixels,
+ metrics.heightPixels, getWidth(), getHeight(), metrics.xdpi, metrics.ydpi);
+
+ if (m_usesGL)
+ holder.setFormat(PixelFormat.RGBA_8888);
+ else
+ holder.setFormat(PixelFormat.RGB_565);
+ }
+
+ @Override
+ public void surfaceChanged(SurfaceHolder holder, int format, int width, int height)
+ {
+ Log.i(QtNative.QtTAG,"surfaceChanged: "+width+","+height);
+ if (width < 1 || height < 1)
+ return;
+
+ DisplayMetrics metrics = new DisplayMetrics();
+ ((Activity) getContext()).getWindowManager().getDefaultDisplay().getMetrics(metrics);
+ QtNative.setApplicationDisplayMetrics(metrics.widthPixels,
+ metrics.heightPixels, width, height, metrics.xdpi, metrics.ydpi);
+
+ if (!m_started)
+ return;
+
+ if (m_usesGL) {
+ QtNative.setSurface(holder.getSurface());
+ } else {
+ QtNative.lockSurface();
+ QtNative.setSurface(null);
+ m_bitmap=Bitmap.createBitmap(width, height, Bitmap.Config.RGB_565);
+ QtNative.setSurface(m_bitmap);
+ QtNative.unlockSurface();
+ QtNative.updateWindow();
+ }
+ }
+
+ @Override
+ public void surfaceDestroyed(SurfaceHolder holder)
+ {
+ Log.i(QtNative.QtTAG,"surfaceDestroyed ");
+ if (m_usesGL) {
+ QtNative.destroySurface();
+ } else {
+ if (!m_started)
+ return;
+
+ QtNative.lockSurface();
+ QtNative.setSurface(null);
+ QtNative.unlockSurface();
+ }
+ }
+
+ public void drawBitmap(Rect rect)
+ {
+ if (!m_started)
+ return;
+ QtNative.lockSurface();
+ if (null != m_bitmap) {
+ try {
+ Canvas cv=getHolder().lockCanvas(rect);
+ cv.drawBitmap(m_bitmap, rect, rect, null);
+ getHolder().unlockCanvasAndPost(cv);
+ } catch (Exception e) {
+ Log.e(QtNative.QtTAG, "Can't create main activity", e);
+ }
+ }
+ QtNative.unlockSurface();
+ }
+
+ @Override
+ public boolean onTouchEvent(MotionEvent event)
+ {
+ if (!m_started)
+ return false;
+ QtNative.sendTouchEvent(event, getId());
+ return true;
+ }
+
+ @Override
+ public boolean onTrackballEvent(MotionEvent event)
+ {
+ if (!m_started)
+ return false;
+ QtNative.sendTrackballEvent(event, getId());
+ return true;
+ }
+}
diff --git a/tests/auto/auto.pro b/tests/auto/auto.pro
index 6ff0734186..758d89ab72 100644
--- a/tests/auto/auto.pro
+++ b/tests/auto/auto.pro
@@ -20,5 +20,7 @@ wince*: SUBDIRS -= printsupport
cross_compile: SUBDIRS -= tools
!qtHaveModule(opengl): SUBDIRS -= opengl
!unix|embedded|!qtHaveModule(dbus): SUBDIRS -= dbus
-!qtHaveModule(widgets): SUBDIRS -= widgets printsupport
+!qtHaveModule(widgets): SUBDIRS -= widgets
+!qtHaveModule(printsupport): SUBDIRS -= printsupport
!qtHaveModule(concurrent): SUBDIRS -= concurrent
+!qtHaveModule(network): SUBDIRS -= network
diff --git a/tests/auto/bic/data/QtGui.5.0.0.linux-gcc-amd64.txt b/tests/auto/bic/data/QtGui.5.0.0.linux-gcc-amd64.txt
index 875b25ffc5..d2db7b0a8f 100644
--- a/tests/auto/bic/data/QtGui.5.0.0.linux-gcc-amd64.txt
+++ b/tests/auto/bic/data/QtGui.5.0.0.linux-gcc-amd64.txt
@@ -4198,157 +4198,6 @@ QAccessibleTableModelChangeEvent (0x7f718033a138) 0
QAccessibleEvent (0x7f7180652840) 0
primary-for QAccessibleTableModelChangeEvent (0x7f718033a138)
-Vtable for QAccessibleTextInterface
-QAccessibleTextInterface::_ZTV24QAccessibleTextInterface: 20u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI24QAccessibleTextInterface)
-16 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-24 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-96 (int (*)(...))QAccessibleTextInterface::textBeforeOffset
-104 (int (*)(...))QAccessibleTextInterface::textAfterOffset
-112 (int (*)(...))QAccessibleTextInterface::textAtOffset
-120 (int (*)(...))__cxa_pure_virtual
-128 (int (*)(...))__cxa_pure_virtual
-136 (int (*)(...))__cxa_pure_virtual
-144 (int (*)(...))__cxa_pure_virtual
-152 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTextInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleTextInterface (0x7f7180652900) 0 nearly-empty
- vptr=((& QAccessibleTextInterface::_ZTV24QAccessibleTextInterface) + 16u)
-
-Vtable for QAccessibleEditableTextInterface
-QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface: 7u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI32QAccessibleEditableTextInterface)
-16 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-24 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleEditableTextInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleEditableTextInterface (0x7f7180652960) 0 nearly-empty
- vptr=((& QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface) + 16u)
-
-Vtable for QAccessibleValueInterface
-QAccessibleValueInterface::_ZTV25QAccessibleValueInterface: 9u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI25QAccessibleValueInterface)
-16 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-24 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleValueInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleValueInterface (0x7f71806529c0) 0 nearly-empty
- vptr=((& QAccessibleValueInterface::_ZTV25QAccessibleValueInterface) + 16u)
-
-Vtable for QAccessibleTableCellInterface
-QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface: 13u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI29QAccessibleTableCellInterface)
-16 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-24 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-96 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableCellInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleTableCellInterface (0x7f7180652a20) 0 nearly-empty
- vptr=((& QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface) + 16u)
-
-Vtable for QAccessibleTableInterface
-QAccessibleTableInterface::_ZTV25QAccessibleTableInterface: 23u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI25QAccessibleTableInterface)
-16 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-24 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-96 (int (*)(...))__cxa_pure_virtual
-104 (int (*)(...))__cxa_pure_virtual
-112 (int (*)(...))__cxa_pure_virtual
-120 (int (*)(...))__cxa_pure_virtual
-128 (int (*)(...))__cxa_pure_virtual
-136 (int (*)(...))__cxa_pure_virtual
-144 (int (*)(...))__cxa_pure_virtual
-152 (int (*)(...))__cxa_pure_virtual
-160 (int (*)(...))__cxa_pure_virtual
-168 (int (*)(...))__cxa_pure_virtual
-176 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleTableInterface (0x7f7180652a80) 0 nearly-empty
- vptr=((& QAccessibleTableInterface::_ZTV25QAccessibleTableInterface) + 16u)
-
-Vtable for QAccessibleActionInterface
-QAccessibleActionInterface::_ZTV26QAccessibleActionInterface: 9u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI26QAccessibleActionInterface)
-16 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-24 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))QAccessibleActionInterface::localizedActionName
-48 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleActionInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleActionInterface (0x7f7180652ae0) 0 nearly-empty
- vptr=((& QAccessibleActionInterface::_ZTV26QAccessibleActionInterface) + 16u)
-
-Vtable for QAccessibleImageInterface
-QAccessibleImageInterface::_ZTV25QAccessibleImageInterface: 7u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI25QAccessibleImageInterface)
-16 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-24 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleImageInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleImageInterface (0x7f7180652b40) 0 nearly-empty
- vptr=((& QAccessibleImageInterface::_ZTV25QAccessibleImageInterface) + 16u)
-
Vtable for QAccessibleBridge
QAccessibleBridge::_ZTV17QAccessibleBridge: 6u entries
0 (int (*)(...))0
diff --git a/tests/auto/bic/data/QtGui.5.0.0.linux-gcc-ia32.txt b/tests/auto/bic/data/QtGui.5.0.0.linux-gcc-ia32.txt
index cb310963bd..433c0eaacc 100644
--- a/tests/auto/bic/data/QtGui.5.0.0.linux-gcc-ia32.txt
+++ b/tests/auto/bic/data/QtGui.5.0.0.linux-gcc-ia32.txt
@@ -4198,157 +4198,6 @@ QAccessibleTableModelChangeEvent (0xb3a81bb8) 0
QAccessibleEvent (0xb39af8c0) 0
primary-for QAccessibleTableModelChangeEvent (0xb3a81bb8)
-Vtable for QAccessibleTextInterface
-QAccessibleTextInterface::_ZTV24QAccessibleTextInterface: 20u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI24QAccessibleTextInterface)
-8 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-12 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-36 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-44 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))QAccessibleTextInterface::textBeforeOffset
-52 (int (*)(...))QAccessibleTextInterface::textAfterOffset
-56 (int (*)(...))QAccessibleTextInterface::textAtOffset
-60 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-68 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-76 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTextInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleTextInterface (0xb39bbea8) 0 nearly-empty
- vptr=((& QAccessibleTextInterface::_ZTV24QAccessibleTextInterface) + 8u)
-
-Vtable for QAccessibleEditableTextInterface
-QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface: 7u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI32QAccessibleEditableTextInterface)
-8 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-12 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleEditableTextInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleEditableTextInterface (0xb39c80e0) 0 nearly-empty
- vptr=((& QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface) + 8u)
-
-Vtable for QAccessibleValueInterface
-QAccessibleValueInterface::_ZTV25QAccessibleValueInterface: 9u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI25QAccessibleValueInterface)
-8 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-12 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleValueInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleValueInterface (0xb39c8348) 0 nearly-empty
- vptr=((& QAccessibleValueInterface::_ZTV25QAccessibleValueInterface) + 8u)
-
-Vtable for QAccessibleTableCellInterface
-QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface: 13u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI29QAccessibleTableCellInterface)
-8 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-12 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-36 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-44 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableCellInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleTableCellInterface (0xb39c85b0) 0 nearly-empty
- vptr=((& QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface) + 8u)
-
-Vtable for QAccessibleTableInterface
-QAccessibleTableInterface::_ZTV25QAccessibleTableInterface: 23u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI25QAccessibleTableInterface)
-8 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-12 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-36 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-44 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-52 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-60 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-68 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-76 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-84 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleTableInterface (0xb39c8818) 0 nearly-empty
- vptr=((& QAccessibleTableInterface::_ZTV25QAccessibleTableInterface) + 8u)
-
-Vtable for QAccessibleActionInterface
-QAccessibleActionInterface::_ZTV26QAccessibleActionInterface: 9u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI26QAccessibleActionInterface)
-8 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-12 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))QAccessibleActionInterface::localizedActionName
-24 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleActionInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleActionInterface (0xb39c8a80) 0 nearly-empty
- vptr=((& QAccessibleActionInterface::_ZTV26QAccessibleActionInterface) + 8u)
-
-Vtable for QAccessibleImageInterface
-QAccessibleImageInterface::_ZTV25QAccessibleImageInterface: 7u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI25QAccessibleImageInterface)
-8 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-12 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleImageInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleImageInterface (0xb39c8dc8) 0 nearly-empty
- vptr=((& QAccessibleImageInterface::_ZTV25QAccessibleImageInterface) + 8u)
-
Vtable for QAccessibleBridge
QAccessibleBridge::_ZTV17QAccessibleBridge: 6u entries
0 (int (*)(...))0
diff --git a/tests/auto/bic/data/QtOpenGL.5.0.0.linux-gcc-amd64.txt b/tests/auto/bic/data/QtOpenGL.5.0.0.linux-gcc-amd64.txt
index 0f51bab46e..125e529c33 100644
--- a/tests/auto/bic/data/QtOpenGL.5.0.0.linux-gcc-amd64.txt
+++ b/tests/auto/bic/data/QtOpenGL.5.0.0.linux-gcc-amd64.txt
@@ -4198,157 +4198,6 @@ QAccessibleTableModelChangeEvent (0x7f04b9031138) 0
QAccessibleEvent (0x7f04b8efecc0) 0
primary-for QAccessibleTableModelChangeEvent (0x7f04b9031138)
-Vtable for QAccessibleTextInterface
-QAccessibleTextInterface::_ZTV24QAccessibleTextInterface: 20u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI24QAccessibleTextInterface)
-16 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-24 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-96 (int (*)(...))QAccessibleTextInterface::textBeforeOffset
-104 (int (*)(...))QAccessibleTextInterface::textAfterOffset
-112 (int (*)(...))QAccessibleTextInterface::textAtOffset
-120 (int (*)(...))__cxa_pure_virtual
-128 (int (*)(...))__cxa_pure_virtual
-136 (int (*)(...))__cxa_pure_virtual
-144 (int (*)(...))__cxa_pure_virtual
-152 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTextInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleTextInterface (0x7f04b8efed80) 0 nearly-empty
- vptr=((& QAccessibleTextInterface::_ZTV24QAccessibleTextInterface) + 16u)
-
-Vtable for QAccessibleEditableTextInterface
-QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface: 7u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI32QAccessibleEditableTextInterface)
-16 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-24 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleEditableTextInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleEditableTextInterface (0x7f04b8efede0) 0 nearly-empty
- vptr=((& QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface) + 16u)
-
-Vtable for QAccessibleValueInterface
-QAccessibleValueInterface::_ZTV25QAccessibleValueInterface: 9u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI25QAccessibleValueInterface)
-16 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-24 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleValueInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleValueInterface (0x7f04b8efee40) 0 nearly-empty
- vptr=((& QAccessibleValueInterface::_ZTV25QAccessibleValueInterface) + 16u)
-
-Vtable for QAccessibleTableCellInterface
-QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface: 13u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI29QAccessibleTableCellInterface)
-16 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-24 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-96 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableCellInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleTableCellInterface (0x7f04b8efeea0) 0 nearly-empty
- vptr=((& QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface) + 16u)
-
-Vtable for QAccessibleTableInterface
-QAccessibleTableInterface::_ZTV25QAccessibleTableInterface: 23u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI25QAccessibleTableInterface)
-16 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-24 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-96 (int (*)(...))__cxa_pure_virtual
-104 (int (*)(...))__cxa_pure_virtual
-112 (int (*)(...))__cxa_pure_virtual
-120 (int (*)(...))__cxa_pure_virtual
-128 (int (*)(...))__cxa_pure_virtual
-136 (int (*)(...))__cxa_pure_virtual
-144 (int (*)(...))__cxa_pure_virtual
-152 (int (*)(...))__cxa_pure_virtual
-160 (int (*)(...))__cxa_pure_virtual
-168 (int (*)(...))__cxa_pure_virtual
-176 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleTableInterface (0x7f04b8efef00) 0 nearly-empty
- vptr=((& QAccessibleTableInterface::_ZTV25QAccessibleTableInterface) + 16u)
-
-Vtable for QAccessibleActionInterface
-QAccessibleActionInterface::_ZTV26QAccessibleActionInterface: 9u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI26QAccessibleActionInterface)
-16 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-24 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))QAccessibleActionInterface::localizedActionName
-48 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleActionInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleActionInterface (0x7f04b8efef60) 0 nearly-empty
- vptr=((& QAccessibleActionInterface::_ZTV26QAccessibleActionInterface) + 16u)
-
-Vtable for QAccessibleImageInterface
-QAccessibleImageInterface::_ZTV25QAccessibleImageInterface: 7u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI25QAccessibleImageInterface)
-16 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-24 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleImageInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleImageInterface (0x7f04b908d000) 0 nearly-empty
- vptr=((& QAccessibleImageInterface::_ZTV25QAccessibleImageInterface) + 16u)
-
Vtable for QAccessibleBridge
QAccessibleBridge::_ZTV17QAccessibleBridge: 6u entries
0 (int (*)(...))0
@@ -6303,56 +6152,6 @@ QRegExpValidator (0x7f04b7707ea0) 0
QObject (0x7f04b7a677e0) 0
primary-for QValidator (0x7f04b7707f08)
-Vtable for QAccessibleWidget
-QAccessibleWidget::_ZTV17QAccessibleWidget: 35u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI17QAccessibleWidget)
-16 (int (*)(...))QAccessibleWidget::~QAccessibleWidget
-24 (int (*)(...))QAccessibleWidget::~QAccessibleWidget
-32 (int (*)(...))QAccessibleObject::isValid
-40 (int (*)(...))QAccessibleObject::object
-48 (int (*)(...))QAccessibleWidget::window
-56 (int (*)(...))QAccessibleWidget::relations
-64 (int (*)(...))QAccessibleWidget::focusChild
-72 (int (*)(...))QAccessibleObject::childAt
-80 (int (*)(...))QAccessibleWidget::parent
-88 (int (*)(...))QAccessibleWidget::child
-96 (int (*)(...))QAccessibleWidget::childCount
-104 (int (*)(...))QAccessibleWidget::indexOfChild
-112 (int (*)(...))QAccessibleWidget::text
-120 (int (*)(...))QAccessibleObject::setText
-128 (int (*)(...))QAccessibleWidget::rect
-136 (int (*)(...))QAccessibleWidget::role
-144 (int (*)(...))QAccessibleWidget::state
-152 (int (*)(...))QAccessibleWidget::foregroundColor
-160 (int (*)(...))QAccessibleWidget::backgroundColor
-168 (int (*)(...))QAccessibleInterface::virtual_hook
-176 (int (*)(...))QAccessibleWidget::interface_cast
-184 (int (*)(...))QAccessibleWidget::actionNames
-192 (int (*)(...))QAccessibleWidget::doAction
-200 (int (*)(...))QAccessibleWidget::keyBindingsForAction
-208 (int (*)(...))-16
-216 (int (*)(...))(& _ZTI17QAccessibleWidget)
-224 (int (*)(...))QAccessibleWidget::_ZThn16_N17QAccessibleWidgetD1Ev
-232 (int (*)(...))QAccessibleWidget::_ZThn16_N17QAccessibleWidgetD0Ev
-240 (int (*)(...))QAccessibleWidget::_ZThn16_NK17QAccessibleWidget11actionNamesEv
-248 (int (*)(...))QAccessibleActionInterface::localizedActionName
-256 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-264 (int (*)(...))QAccessibleWidget::_ZThn16_N17QAccessibleWidget8doActionERK7QString
-272 (int (*)(...))QAccessibleWidget::_ZThn16_NK17QAccessibleWidget20keyBindingsForActionERK7QString
-
-Class QAccessibleWidget
- size=32 align=8
- base size=32 base align=8
-QAccessibleWidget (0x7f04b7710bd0) 0
- vptr=((& QAccessibleWidget::_ZTV17QAccessibleWidget) + 16u)
- QAccessibleObject (0x7f04b7718c98) 0
- primary-for QAccessibleWidget (0x7f04b7710bd0)
- QAccessibleInterface (0x7f04b7a678a0) 0 nearly-empty
- primary-for QAccessibleObject (0x7f04b7718c98)
- QAccessibleActionInterface (0x7f04b7a67900) 16 nearly-empty
- vptr=((& QAccessibleWidget::_ZTV17QAccessibleWidget) + 224u)
-
Class QSizePolicy
size=4 align=4
base size=4 base align=4
diff --git a/tests/auto/bic/data/QtOpenGL.5.0.0.linux-gcc-ia32.txt b/tests/auto/bic/data/QtOpenGL.5.0.0.linux-gcc-ia32.txt
index 78509e24cc..7d8a99d222 100644
--- a/tests/auto/bic/data/QtOpenGL.5.0.0.linux-gcc-ia32.txt
+++ b/tests/auto/bic/data/QtOpenGL.5.0.0.linux-gcc-ia32.txt
@@ -4198,157 +4198,6 @@ QAccessibleTableModelChangeEvent (0xb384230c) 0
QAccessibleEvent (0xb385ca48) 0
primary-for QAccessibleTableModelChangeEvent (0xb384230c)
-Vtable for QAccessibleTextInterface
-QAccessibleTextInterface::_ZTV24QAccessibleTextInterface: 20u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI24QAccessibleTextInterface)
-8 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-12 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-36 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-44 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))QAccessibleTextInterface::textBeforeOffset
-52 (int (*)(...))QAccessibleTextInterface::textAfterOffset
-56 (int (*)(...))QAccessibleTextInterface::textAtOffset
-60 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-68 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-76 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTextInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleTextInterface (0xb3871038) 0 nearly-empty
- vptr=((& QAccessibleTextInterface::_ZTV24QAccessibleTextInterface) + 8u)
-
-Vtable for QAccessibleEditableTextInterface
-QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface: 7u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI32QAccessibleEditableTextInterface)
-8 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-12 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleEditableTextInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleEditableTextInterface (0xb38712a0) 0 nearly-empty
- vptr=((& QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface) + 8u)
-
-Vtable for QAccessibleValueInterface
-QAccessibleValueInterface::_ZTV25QAccessibleValueInterface: 9u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI25QAccessibleValueInterface)
-8 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-12 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleValueInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleValueInterface (0xb3871508) 0 nearly-empty
- vptr=((& QAccessibleValueInterface::_ZTV25QAccessibleValueInterface) + 8u)
-
-Vtable for QAccessibleTableCellInterface
-QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface: 13u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI29QAccessibleTableCellInterface)
-8 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-12 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-36 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-44 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableCellInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleTableCellInterface (0xb3871770) 0 nearly-empty
- vptr=((& QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface) + 8u)
-
-Vtable for QAccessibleTableInterface
-QAccessibleTableInterface::_ZTV25QAccessibleTableInterface: 23u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI25QAccessibleTableInterface)
-8 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-12 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-36 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-44 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-52 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-60 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-68 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-76 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-84 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleTableInterface (0xb38719d8) 0 nearly-empty
- vptr=((& QAccessibleTableInterface::_ZTV25QAccessibleTableInterface) + 8u)
-
-Vtable for QAccessibleActionInterface
-QAccessibleActionInterface::_ZTV26QAccessibleActionInterface: 9u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI26QAccessibleActionInterface)
-8 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-12 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))QAccessibleActionInterface::localizedActionName
-24 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleActionInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleActionInterface (0xb3871c40) 0 nearly-empty
- vptr=((& QAccessibleActionInterface::_ZTV26QAccessibleActionInterface) + 8u)
-
-Vtable for QAccessibleImageInterface
-QAccessibleImageInterface::_ZTV25QAccessibleImageInterface: 7u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI25QAccessibleImageInterface)
-8 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-12 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleImageInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleImageInterface (0xb3871f88) 0 nearly-empty
- vptr=((& QAccessibleImageInterface::_ZTV25QAccessibleImageInterface) + 8u)
-
Vtable for QAccessibleBridge
QAccessibleBridge::_ZTV17QAccessibleBridge: 6u entries
0 (int (*)(...))0
@@ -6303,56 +6152,6 @@ QRegExpValidator (0xb2afe258) 0
QObject (0xb2947460) 0
primary-for QValidator (0xb2afe294)
-Vtable for QAccessibleWidget
-QAccessibleWidget::_ZTV17QAccessibleWidget: 35u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI17QAccessibleWidget)
-8 (int (*)(...))QAccessibleWidget::~QAccessibleWidget
-12 (int (*)(...))QAccessibleWidget::~QAccessibleWidget
-16 (int (*)(...))QAccessibleObject::isValid
-20 (int (*)(...))QAccessibleObject::object
-24 (int (*)(...))QAccessibleWidget::window
-28 (int (*)(...))QAccessibleWidget::relations
-32 (int (*)(...))QAccessibleWidget::focusChild
-36 (int (*)(...))QAccessibleObject::childAt
-40 (int (*)(...))QAccessibleWidget::parent
-44 (int (*)(...))QAccessibleWidget::child
-48 (int (*)(...))QAccessibleWidget::childCount
-52 (int (*)(...))QAccessibleWidget::indexOfChild
-56 (int (*)(...))QAccessibleWidget::text
-60 (int (*)(...))QAccessibleObject::setText
-64 (int (*)(...))QAccessibleWidget::rect
-68 (int (*)(...))QAccessibleWidget::role
-72 (int (*)(...))QAccessibleWidget::state
-76 (int (*)(...))QAccessibleWidget::foregroundColor
-80 (int (*)(...))QAccessibleWidget::backgroundColor
-84 (int (*)(...))QAccessibleInterface::virtual_hook
-88 (int (*)(...))QAccessibleWidget::interface_cast
-92 (int (*)(...))QAccessibleWidget::actionNames
-96 (int (*)(...))QAccessibleWidget::doAction
-100 (int (*)(...))QAccessibleWidget::keyBindingsForAction
-104 (int (*)(...))-0x00000000000000008
-108 (int (*)(...))(& _ZTI17QAccessibleWidget)
-112 (int (*)(...))QAccessibleWidget::_ZThn8_N17QAccessibleWidgetD1Ev
-116 (int (*)(...))QAccessibleWidget::_ZThn8_N17QAccessibleWidgetD0Ev
-120 (int (*)(...))QAccessibleWidget::_ZThn8_NK17QAccessibleWidget11actionNamesEv
-124 (int (*)(...))QAccessibleActionInterface::localizedActionName
-128 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-132 (int (*)(...))QAccessibleWidget::_ZThn8_N17QAccessibleWidget8doActionERK7QString
-136 (int (*)(...))QAccessibleWidget::_ZThn8_NK17QAccessibleWidget20keyBindingsForActionERK7QString
-
-Class QAccessibleWidget
- size=16 align=4
- base size=16 base align=4
-QAccessibleWidget (0xb294a300) 0
- vptr=((& QAccessibleWidget::_ZTV17QAccessibleWidget) + 8u)
- QAccessibleObject (0xb2afe2d0) 0
- primary-for QAccessibleWidget (0xb294a300)
- QAccessibleInterface (0xb2947d90) 0 nearly-empty
- primary-for QAccessibleObject (0xb2afe2d0)
- QAccessibleActionInterface (0xb2947dc8) 8 nearly-empty
- vptr=((& QAccessibleWidget::_ZTV17QAccessibleWidget) + 112u)
-
Class QSizePolicy
size=4 align=4
base size=4 base align=4
diff --git a/tests/auto/bic/data/QtPrintSupport.5.0.0.linux-gcc-amd64.txt b/tests/auto/bic/data/QtPrintSupport.5.0.0.linux-gcc-amd64.txt
index bcdbbaf895..20988597b1 100644
--- a/tests/auto/bic/data/QtPrintSupport.5.0.0.linux-gcc-amd64.txt
+++ b/tests/auto/bic/data/QtPrintSupport.5.0.0.linux-gcc-amd64.txt
@@ -4203,157 +4203,6 @@ QAccessibleTableModelChangeEvent (0x7f0bd5f7e138) 0
QAccessibleEvent (0x7f0bd5e7e8a0) 0
primary-for QAccessibleTableModelChangeEvent (0x7f0bd5f7e138)
-Vtable for QAccessibleTextInterface
-QAccessibleTextInterface::_ZTV24QAccessibleTextInterface: 20u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI24QAccessibleTextInterface)
-16 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-24 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-96 (int (*)(...))QAccessibleTextInterface::textBeforeOffset
-104 (int (*)(...))QAccessibleTextInterface::textAfterOffset
-112 (int (*)(...))QAccessibleTextInterface::textAtOffset
-120 (int (*)(...))__cxa_pure_virtual
-128 (int (*)(...))__cxa_pure_virtual
-136 (int (*)(...))__cxa_pure_virtual
-144 (int (*)(...))__cxa_pure_virtual
-152 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTextInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleTextInterface (0x7f0bd5e7e960) 0 nearly-empty
- vptr=((& QAccessibleTextInterface::_ZTV24QAccessibleTextInterface) + 16u)
-
-Vtable for QAccessibleEditableTextInterface
-QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface: 7u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI32QAccessibleEditableTextInterface)
-16 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-24 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleEditableTextInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleEditableTextInterface (0x7f0bd5e7e9c0) 0 nearly-empty
- vptr=((& QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface) + 16u)
-
-Vtable for QAccessibleValueInterface
-QAccessibleValueInterface::_ZTV25QAccessibleValueInterface: 9u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI25QAccessibleValueInterface)
-16 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-24 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleValueInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleValueInterface (0x7f0bd5e7ea20) 0 nearly-empty
- vptr=((& QAccessibleValueInterface::_ZTV25QAccessibleValueInterface) + 16u)
-
-Vtable for QAccessibleTableCellInterface
-QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface: 13u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI29QAccessibleTableCellInterface)
-16 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-24 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-96 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableCellInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleTableCellInterface (0x7f0bd5e7ea80) 0 nearly-empty
- vptr=((& QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface) + 16u)
-
-Vtable for QAccessibleTableInterface
-QAccessibleTableInterface::_ZTV25QAccessibleTableInterface: 23u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI25QAccessibleTableInterface)
-16 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-24 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-96 (int (*)(...))__cxa_pure_virtual
-104 (int (*)(...))__cxa_pure_virtual
-112 (int (*)(...))__cxa_pure_virtual
-120 (int (*)(...))__cxa_pure_virtual
-128 (int (*)(...))__cxa_pure_virtual
-136 (int (*)(...))__cxa_pure_virtual
-144 (int (*)(...))__cxa_pure_virtual
-152 (int (*)(...))__cxa_pure_virtual
-160 (int (*)(...))__cxa_pure_virtual
-168 (int (*)(...))__cxa_pure_virtual
-176 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleTableInterface (0x7f0bd5e7eae0) 0 nearly-empty
- vptr=((& QAccessibleTableInterface::_ZTV25QAccessibleTableInterface) + 16u)
-
-Vtable for QAccessibleActionInterface
-QAccessibleActionInterface::_ZTV26QAccessibleActionInterface: 9u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI26QAccessibleActionInterface)
-16 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-24 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))QAccessibleActionInterface::localizedActionName
-48 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleActionInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleActionInterface (0x7f0bd5e7eb40) 0 nearly-empty
- vptr=((& QAccessibleActionInterface::_ZTV26QAccessibleActionInterface) + 16u)
-
-Vtable for QAccessibleImageInterface
-QAccessibleImageInterface::_ZTV25QAccessibleImageInterface: 7u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI25QAccessibleImageInterface)
-16 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-24 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleImageInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleImageInterface (0x7f0bd5e7eba0) 0 nearly-empty
- vptr=((& QAccessibleImageInterface::_ZTV25QAccessibleImageInterface) + 16u)
-
Vtable for QAccessibleBridge
QAccessibleBridge::_ZTV17QAccessibleBridge: 6u entries
0 (int (*)(...))0
@@ -6308,56 +6157,6 @@ QRegExpValidator (0x7f0bd4652ea0) 0
QObject (0x7f0bd46103c0) 0
primary-for QValidator (0x7f0bd4652f08)
-Vtable for QAccessibleWidget
-QAccessibleWidget::_ZTV17QAccessibleWidget: 35u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI17QAccessibleWidget)
-16 (int (*)(...))QAccessibleWidget::~QAccessibleWidget
-24 (int (*)(...))QAccessibleWidget::~QAccessibleWidget
-32 (int (*)(...))QAccessibleObject::isValid
-40 (int (*)(...))QAccessibleObject::object
-48 (int (*)(...))QAccessibleWidget::window
-56 (int (*)(...))QAccessibleWidget::relations
-64 (int (*)(...))QAccessibleWidget::focusChild
-72 (int (*)(...))QAccessibleObject::childAt
-80 (int (*)(...))QAccessibleWidget::parent
-88 (int (*)(...))QAccessibleWidget::child
-96 (int (*)(...))QAccessibleWidget::childCount
-104 (int (*)(...))QAccessibleWidget::indexOfChild
-112 (int (*)(...))QAccessibleWidget::text
-120 (int (*)(...))QAccessibleObject::setText
-128 (int (*)(...))QAccessibleWidget::rect
-136 (int (*)(...))QAccessibleWidget::role
-144 (int (*)(...))QAccessibleWidget::state
-152 (int (*)(...))QAccessibleWidget::foregroundColor
-160 (int (*)(...))QAccessibleWidget::backgroundColor
-168 (int (*)(...))QAccessibleInterface::virtual_hook
-176 (int (*)(...))QAccessibleWidget::interface_cast
-184 (int (*)(...))QAccessibleWidget::actionNames
-192 (int (*)(...))QAccessibleWidget::doAction
-200 (int (*)(...))QAccessibleWidget::keyBindingsForAction
-208 (int (*)(...))-16
-216 (int (*)(...))(& _ZTI17QAccessibleWidget)
-224 (int (*)(...))QAccessibleWidget::_ZThn16_N17QAccessibleWidgetD1Ev
-232 (int (*)(...))QAccessibleWidget::_ZThn16_N17QAccessibleWidgetD0Ev
-240 (int (*)(...))QAccessibleWidget::_ZThn16_NK17QAccessibleWidget11actionNamesEv
-248 (int (*)(...))QAccessibleActionInterface::localizedActionName
-256 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-264 (int (*)(...))QAccessibleWidget::_ZThn16_N17QAccessibleWidget8doActionERK7QString
-272 (int (*)(...))QAccessibleWidget::_ZThn16_NK17QAccessibleWidget20keyBindingsForActionERK7QString
-
-Class QAccessibleWidget
- size=32 align=8
- base size=32 base align=8
-QAccessibleWidget (0x7f0bd465cbd0) 0
- vptr=((& QAccessibleWidget::_ZTV17QAccessibleWidget) + 16u)
- QAccessibleObject (0x7f0bd4665c98) 0
- primary-for QAccessibleWidget (0x7f0bd465cbd0)
- QAccessibleInterface (0x7f0bd4610480) 0 nearly-empty
- primary-for QAccessibleObject (0x7f0bd4665c98)
- QAccessibleActionInterface (0x7f0bd46104e0) 16 nearly-empty
- vptr=((& QAccessibleWidget::_ZTV17QAccessibleWidget) + 224u)
-
Class QSizePolicy
size=4 align=4
base size=4 base align=4
diff --git a/tests/auto/bic/data/QtPrintSupport.5.0.0.linux-gcc-ia32.txt b/tests/auto/bic/data/QtPrintSupport.5.0.0.linux-gcc-ia32.txt
index 19cbef7918..6162fcde57 100644
--- a/tests/auto/bic/data/QtPrintSupport.5.0.0.linux-gcc-ia32.txt
+++ b/tests/auto/bic/data/QtPrintSupport.5.0.0.linux-gcc-ia32.txt
@@ -4198,157 +4198,6 @@ QAccessibleTableModelChangeEvent (0xb3b22ca8) 0
QAccessibleEvent (0xb384fa48) 0
primary-for QAccessibleTableModelChangeEvent (0xb3b22ca8)
-Vtable for QAccessibleTextInterface
-QAccessibleTextInterface::_ZTV24QAccessibleTextInterface: 20u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI24QAccessibleTextInterface)
-8 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-12 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-36 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-44 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))QAccessibleTextInterface::textBeforeOffset
-52 (int (*)(...))QAccessibleTextInterface::textAfterOffset
-56 (int (*)(...))QAccessibleTextInterface::textAtOffset
-60 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-68 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-76 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTextInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleTextInterface (0xb3864038) 0 nearly-empty
- vptr=((& QAccessibleTextInterface::_ZTV24QAccessibleTextInterface) + 8u)
-
-Vtable for QAccessibleEditableTextInterface
-QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface: 7u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI32QAccessibleEditableTextInterface)
-8 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-12 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleEditableTextInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleEditableTextInterface (0xb38642a0) 0 nearly-empty
- vptr=((& QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface) + 8u)
-
-Vtable for QAccessibleValueInterface
-QAccessibleValueInterface::_ZTV25QAccessibleValueInterface: 9u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI25QAccessibleValueInterface)
-8 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-12 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleValueInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleValueInterface (0xb3864508) 0 nearly-empty
- vptr=((& QAccessibleValueInterface::_ZTV25QAccessibleValueInterface) + 8u)
-
-Vtable for QAccessibleTableCellInterface
-QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface: 13u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI29QAccessibleTableCellInterface)
-8 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-12 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-36 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-44 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableCellInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleTableCellInterface (0xb3864770) 0 nearly-empty
- vptr=((& QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface) + 8u)
-
-Vtable for QAccessibleTableInterface
-QAccessibleTableInterface::_ZTV25QAccessibleTableInterface: 23u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI25QAccessibleTableInterface)
-8 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-12 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-36 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-44 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-52 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-60 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-68 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-76 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-84 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleTableInterface (0xb38649d8) 0 nearly-empty
- vptr=((& QAccessibleTableInterface::_ZTV25QAccessibleTableInterface) + 8u)
-
-Vtable for QAccessibleActionInterface
-QAccessibleActionInterface::_ZTV26QAccessibleActionInterface: 9u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI26QAccessibleActionInterface)
-8 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-12 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))QAccessibleActionInterface::localizedActionName
-24 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleActionInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleActionInterface (0xb3864c40) 0 nearly-empty
- vptr=((& QAccessibleActionInterface::_ZTV26QAccessibleActionInterface) + 8u)
-
-Vtable for QAccessibleImageInterface
-QAccessibleImageInterface::_ZTV25QAccessibleImageInterface: 7u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI25QAccessibleImageInterface)
-8 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-12 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleImageInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleImageInterface (0xb3864f88) 0 nearly-empty
- vptr=((& QAccessibleImageInterface::_ZTV25QAccessibleImageInterface) + 8u)
-
Vtable for QAccessibleBridge
QAccessibleBridge::_ZTV17QAccessibleBridge: 6u entries
0 (int (*)(...))0
@@ -6303,56 +6152,6 @@ QRegExpValidator (0xb2ea6bf4) 0
QObject (0xb293a460) 0
primary-for QValidator (0xb2ea6c30)
-Vtable for QAccessibleWidget
-QAccessibleWidget::_ZTV17QAccessibleWidget: 35u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI17QAccessibleWidget)
-8 (int (*)(...))QAccessibleWidget::~QAccessibleWidget
-12 (int (*)(...))QAccessibleWidget::~QAccessibleWidget
-16 (int (*)(...))QAccessibleObject::isValid
-20 (int (*)(...))QAccessibleObject::object
-24 (int (*)(...))QAccessibleWidget::window
-28 (int (*)(...))QAccessibleWidget::relations
-32 (int (*)(...))QAccessibleWidget::focusChild
-36 (int (*)(...))QAccessibleObject::childAt
-40 (int (*)(...))QAccessibleWidget::parent
-44 (int (*)(...))QAccessibleWidget::child
-48 (int (*)(...))QAccessibleWidget::childCount
-52 (int (*)(...))QAccessibleWidget::indexOfChild
-56 (int (*)(...))QAccessibleWidget::text
-60 (int (*)(...))QAccessibleObject::setText
-64 (int (*)(...))QAccessibleWidget::rect
-68 (int (*)(...))QAccessibleWidget::role
-72 (int (*)(...))QAccessibleWidget::state
-76 (int (*)(...))QAccessibleWidget::foregroundColor
-80 (int (*)(...))QAccessibleWidget::backgroundColor
-84 (int (*)(...))QAccessibleInterface::virtual_hook
-88 (int (*)(...))QAccessibleWidget::interface_cast
-92 (int (*)(...))QAccessibleWidget::actionNames
-96 (int (*)(...))QAccessibleWidget::doAction
-100 (int (*)(...))QAccessibleWidget::keyBindingsForAction
-104 (int (*)(...))-0x00000000000000008
-108 (int (*)(...))(& _ZTI17QAccessibleWidget)
-112 (int (*)(...))QAccessibleWidget::_ZThn8_N17QAccessibleWidgetD1Ev
-116 (int (*)(...))QAccessibleWidget::_ZThn8_N17QAccessibleWidgetD0Ev
-120 (int (*)(...))QAccessibleWidget::_ZThn8_NK17QAccessibleWidget11actionNamesEv
-124 (int (*)(...))QAccessibleActionInterface::localizedActionName
-128 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-132 (int (*)(...))QAccessibleWidget::_ZThn8_N17QAccessibleWidget8doActionERK7QString
-136 (int (*)(...))QAccessibleWidget::_ZThn8_NK17QAccessibleWidget20keyBindingsForActionERK7QString
-
-Class QAccessibleWidget
- size=16 align=4
- base size=16 base align=4
-QAccessibleWidget (0xb293c300) 0
- vptr=((& QAccessibleWidget::_ZTV17QAccessibleWidget) + 8u)
- QAccessibleObject (0xb2ea6c6c) 0
- primary-for QAccessibleWidget (0xb293c300)
- QAccessibleInterface (0xb293ad90) 0 nearly-empty
- primary-for QAccessibleObject (0xb2ea6c6c)
- QAccessibleActionInterface (0xb293adc8) 8 nearly-empty
- vptr=((& QAccessibleWidget::_ZTV17QAccessibleWidget) + 112u)
-
Class QSizePolicy
size=4 align=4
base size=4 base align=4
diff --git a/tests/auto/bic/data/QtWidgets.5.0.0.linux-gcc-amd64.txt b/tests/auto/bic/data/QtWidgets.5.0.0.linux-gcc-amd64.txt
index 25e4d7d84e..35a4d3a30a 100644
--- a/tests/auto/bic/data/QtWidgets.5.0.0.linux-gcc-amd64.txt
+++ b/tests/auto/bic/data/QtWidgets.5.0.0.linux-gcc-amd64.txt
@@ -4198,157 +4198,6 @@ QAccessibleTableModelChangeEvent (0x7f871fb16138) 0
QAccessibleEvent (0x7f871fa158a0) 0
primary-for QAccessibleTableModelChangeEvent (0x7f871fb16138)
-Vtable for QAccessibleTextInterface
-QAccessibleTextInterface::_ZTV24QAccessibleTextInterface: 20u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI24QAccessibleTextInterface)
-16 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-24 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-96 (int (*)(...))QAccessibleTextInterface::textBeforeOffset
-104 (int (*)(...))QAccessibleTextInterface::textAfterOffset
-112 (int (*)(...))QAccessibleTextInterface::textAtOffset
-120 (int (*)(...))__cxa_pure_virtual
-128 (int (*)(...))__cxa_pure_virtual
-136 (int (*)(...))__cxa_pure_virtual
-144 (int (*)(...))__cxa_pure_virtual
-152 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTextInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleTextInterface (0x7f871fa15960) 0 nearly-empty
- vptr=((& QAccessibleTextInterface::_ZTV24QAccessibleTextInterface) + 16u)
-
-Vtable for QAccessibleEditableTextInterface
-QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface: 7u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI32QAccessibleEditableTextInterface)
-16 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-24 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleEditableTextInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleEditableTextInterface (0x7f871fa159c0) 0 nearly-empty
- vptr=((& QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface) + 16u)
-
-Vtable for QAccessibleValueInterface
-QAccessibleValueInterface::_ZTV25QAccessibleValueInterface: 9u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI25QAccessibleValueInterface)
-16 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-24 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleValueInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleValueInterface (0x7f871fa15a20) 0 nearly-empty
- vptr=((& QAccessibleValueInterface::_ZTV25QAccessibleValueInterface) + 16u)
-
-Vtable for QAccessibleTableCellInterface
-QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface: 13u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI29QAccessibleTableCellInterface)
-16 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-24 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-96 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableCellInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleTableCellInterface (0x7f871fa15a80) 0 nearly-empty
- vptr=((& QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface) + 16u)
-
-Vtable for QAccessibleTableInterface
-QAccessibleTableInterface::_ZTV25QAccessibleTableInterface: 23u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI25QAccessibleTableInterface)
-16 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-24 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-96 (int (*)(...))__cxa_pure_virtual
-104 (int (*)(...))__cxa_pure_virtual
-112 (int (*)(...))__cxa_pure_virtual
-120 (int (*)(...))__cxa_pure_virtual
-128 (int (*)(...))__cxa_pure_virtual
-136 (int (*)(...))__cxa_pure_virtual
-144 (int (*)(...))__cxa_pure_virtual
-152 (int (*)(...))__cxa_pure_virtual
-160 (int (*)(...))__cxa_pure_virtual
-168 (int (*)(...))__cxa_pure_virtual
-176 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleTableInterface (0x7f871fa15ae0) 0 nearly-empty
- vptr=((& QAccessibleTableInterface::_ZTV25QAccessibleTableInterface) + 16u)
-
-Vtable for QAccessibleActionInterface
-QAccessibleActionInterface::_ZTV26QAccessibleActionInterface: 9u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI26QAccessibleActionInterface)
-16 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-24 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))QAccessibleActionInterface::localizedActionName
-48 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-56 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleActionInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleActionInterface (0x7f871fa15b40) 0 nearly-empty
- vptr=((& QAccessibleActionInterface::_ZTV26QAccessibleActionInterface) + 16u)
-
-Vtable for QAccessibleImageInterface
-QAccessibleImageInterface::_ZTV25QAccessibleImageInterface: 7u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI25QAccessibleImageInterface)
-16 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-24 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-32 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleImageInterface
- size=8 align=8
- base size=8 base align=8
-QAccessibleImageInterface (0x7f871fa15ba0) 0 nearly-empty
- vptr=((& QAccessibleImageInterface::_ZTV25QAccessibleImageInterface) + 16u)
-
Vtable for QAccessibleBridge
QAccessibleBridge::_ZTV17QAccessibleBridge: 6u entries
0 (int (*)(...))0
@@ -6303,56 +6152,6 @@ QRegExpValidator (0x7f871e1ecea0) 0
QObject (0x7f871e1a93c0) 0
primary-for QValidator (0x7f871e1ecf08)
-Vtable for QAccessibleWidget
-QAccessibleWidget::_ZTV17QAccessibleWidget: 35u entries
-0 (int (*)(...))0
-8 (int (*)(...))(& _ZTI17QAccessibleWidget)
-16 (int (*)(...))QAccessibleWidget::~QAccessibleWidget
-24 (int (*)(...))QAccessibleWidget::~QAccessibleWidget
-32 (int (*)(...))QAccessibleObject::isValid
-40 (int (*)(...))QAccessibleObject::object
-48 (int (*)(...))QAccessibleWidget::window
-56 (int (*)(...))QAccessibleWidget::relations
-64 (int (*)(...))QAccessibleWidget::focusChild
-72 (int (*)(...))QAccessibleObject::childAt
-80 (int (*)(...))QAccessibleWidget::parent
-88 (int (*)(...))QAccessibleWidget::child
-96 (int (*)(...))QAccessibleWidget::childCount
-104 (int (*)(...))QAccessibleWidget::indexOfChild
-112 (int (*)(...))QAccessibleWidget::text
-120 (int (*)(...))QAccessibleObject::setText
-128 (int (*)(...))QAccessibleWidget::rect
-136 (int (*)(...))QAccessibleWidget::role
-144 (int (*)(...))QAccessibleWidget::state
-152 (int (*)(...))QAccessibleWidget::foregroundColor
-160 (int (*)(...))QAccessibleWidget::backgroundColor
-168 (int (*)(...))QAccessibleInterface::virtual_hook
-176 (int (*)(...))QAccessibleWidget::interface_cast
-184 (int (*)(...))QAccessibleWidget::actionNames
-192 (int (*)(...))QAccessibleWidget::doAction
-200 (int (*)(...))QAccessibleWidget::keyBindingsForAction
-208 (int (*)(...))-16
-216 (int (*)(...))(& _ZTI17QAccessibleWidget)
-224 (int (*)(...))QAccessibleWidget::_ZThn16_N17QAccessibleWidgetD1Ev
-232 (int (*)(...))QAccessibleWidget::_ZThn16_N17QAccessibleWidgetD0Ev
-240 (int (*)(...))QAccessibleWidget::_ZThn16_NK17QAccessibleWidget11actionNamesEv
-248 (int (*)(...))QAccessibleActionInterface::localizedActionName
-256 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-264 (int (*)(...))QAccessibleWidget::_ZThn16_N17QAccessibleWidget8doActionERK7QString
-272 (int (*)(...))QAccessibleWidget::_ZThn16_NK17QAccessibleWidget20keyBindingsForActionERK7QString
-
-Class QAccessibleWidget
- size=32 align=8
- base size=32 base align=8
-QAccessibleWidget (0x7f871e1f7bd0) 0
- vptr=((& QAccessibleWidget::_ZTV17QAccessibleWidget) + 16u)
- QAccessibleObject (0x7f871e200c98) 0
- primary-for QAccessibleWidget (0x7f871e1f7bd0)
- QAccessibleInterface (0x7f871e1a9480) 0 nearly-empty
- primary-for QAccessibleObject (0x7f871e200c98)
- QAccessibleActionInterface (0x7f871e1a94e0) 16 nearly-empty
- vptr=((& QAccessibleWidget::_ZTV17QAccessibleWidget) + 224u)
-
Class QSizePolicy
size=4 align=4
base size=4 base align=4
diff --git a/tests/auto/bic/data/QtWidgets.5.0.0.linux-gcc-ia32.txt b/tests/auto/bic/data/QtWidgets.5.0.0.linux-gcc-ia32.txt
index 64234d8c58..fe8f00314f 100644
--- a/tests/auto/bic/data/QtWidgets.5.0.0.linux-gcc-ia32.txt
+++ b/tests/auto/bic/data/QtWidgets.5.0.0.linux-gcc-ia32.txt
@@ -4198,157 +4198,6 @@ QAccessibleTableModelChangeEvent (0xb3ae3ca8) 0
QAccessibleEvent (0xb3811a48) 0
primary-for QAccessibleTableModelChangeEvent (0xb3ae3ca8)
-Vtable for QAccessibleTextInterface
-QAccessibleTextInterface::_ZTV24QAccessibleTextInterface: 20u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI24QAccessibleTextInterface)
-8 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-12 (int (*)(...))QAccessibleTextInterface::~QAccessibleTextInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-36 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-44 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))QAccessibleTextInterface::textBeforeOffset
-52 (int (*)(...))QAccessibleTextInterface::textAfterOffset
-56 (int (*)(...))QAccessibleTextInterface::textAtOffset
-60 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-68 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-76 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTextInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleTextInterface (0xb3825038) 0 nearly-empty
- vptr=((& QAccessibleTextInterface::_ZTV24QAccessibleTextInterface) + 8u)
-
-Vtable for QAccessibleEditableTextInterface
-QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface: 7u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI32QAccessibleEditableTextInterface)
-8 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-12 (int (*)(...))QAccessibleEditableTextInterface::~QAccessibleEditableTextInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleEditableTextInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleEditableTextInterface (0xb38252a0) 0 nearly-empty
- vptr=((& QAccessibleEditableTextInterface::_ZTV32QAccessibleEditableTextInterface) + 8u)
-
-Vtable for QAccessibleValueInterface
-QAccessibleValueInterface::_ZTV25QAccessibleValueInterface: 9u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI25QAccessibleValueInterface)
-8 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-12 (int (*)(...))QAccessibleValueInterface::~QAccessibleValueInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleValueInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleValueInterface (0xb3825508) 0 nearly-empty
- vptr=((& QAccessibleValueInterface::_ZTV25QAccessibleValueInterface) + 8u)
-
-Vtable for QAccessibleTableCellInterface
-QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface: 13u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI29QAccessibleTableCellInterface)
-8 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-12 (int (*)(...))QAccessibleTableCellInterface::~QAccessibleTableCellInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-36 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-44 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableCellInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleTableCellInterface (0xb3825770) 0 nearly-empty
- vptr=((& QAccessibleTableCellInterface::_ZTV29QAccessibleTableCellInterface) + 8u)
-
-Vtable for QAccessibleTableInterface
-QAccessibleTableInterface::_ZTV25QAccessibleTableInterface: 23u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI25QAccessibleTableInterface)
-8 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-12 (int (*)(...))QAccessibleTableInterface::~QAccessibleTableInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-36 (int (*)(...))__cxa_pure_virtual
-40 (int (*)(...))__cxa_pure_virtual
-44 (int (*)(...))__cxa_pure_virtual
-48 (int (*)(...))__cxa_pure_virtual
-52 (int (*)(...))__cxa_pure_virtual
-56 (int (*)(...))__cxa_pure_virtual
-60 (int (*)(...))__cxa_pure_virtual
-64 (int (*)(...))__cxa_pure_virtual
-68 (int (*)(...))__cxa_pure_virtual
-72 (int (*)(...))__cxa_pure_virtual
-76 (int (*)(...))__cxa_pure_virtual
-80 (int (*)(...))__cxa_pure_virtual
-84 (int (*)(...))__cxa_pure_virtual
-88 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleTableInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleTableInterface (0xb38259d8) 0 nearly-empty
- vptr=((& QAccessibleTableInterface::_ZTV25QAccessibleTableInterface) + 8u)
-
-Vtable for QAccessibleActionInterface
-QAccessibleActionInterface::_ZTV26QAccessibleActionInterface: 9u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI26QAccessibleActionInterface)
-8 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-12 (int (*)(...))QAccessibleActionInterface::~QAccessibleActionInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))QAccessibleActionInterface::localizedActionName
-24 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-28 (int (*)(...))__cxa_pure_virtual
-32 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleActionInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleActionInterface (0xb3825c40) 0 nearly-empty
- vptr=((& QAccessibleActionInterface::_ZTV26QAccessibleActionInterface) + 8u)
-
-Vtable for QAccessibleImageInterface
-QAccessibleImageInterface::_ZTV25QAccessibleImageInterface: 7u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI25QAccessibleImageInterface)
-8 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-12 (int (*)(...))QAccessibleImageInterface::~QAccessibleImageInterface
-16 (int (*)(...))__cxa_pure_virtual
-20 (int (*)(...))__cxa_pure_virtual
-24 (int (*)(...))__cxa_pure_virtual
-
-Class QAccessibleImageInterface
- size=4 align=4
- base size=4 base align=4
-QAccessibleImageInterface (0xb3825f88) 0 nearly-empty
- vptr=((& QAccessibleImageInterface::_ZTV25QAccessibleImageInterface) + 8u)
-
Vtable for QAccessibleBridge
QAccessibleBridge::_ZTV17QAccessibleBridge: 6u entries
0 (int (*)(...))0
@@ -6303,56 +6152,6 @@ QRegExpValidator (0xb2e67bf4) 0
QObject (0xb28fc460) 0
primary-for QValidator (0xb2e67c30)
-Vtable for QAccessibleWidget
-QAccessibleWidget::_ZTV17QAccessibleWidget: 35u entries
-0 (int (*)(...))0
-4 (int (*)(...))(& _ZTI17QAccessibleWidget)
-8 (int (*)(...))QAccessibleWidget::~QAccessibleWidget
-12 (int (*)(...))QAccessibleWidget::~QAccessibleWidget
-16 (int (*)(...))QAccessibleObject::isValid
-20 (int (*)(...))QAccessibleObject::object
-24 (int (*)(...))QAccessibleWidget::window
-28 (int (*)(...))QAccessibleWidget::relations
-32 (int (*)(...))QAccessibleWidget::focusChild
-36 (int (*)(...))QAccessibleObject::childAt
-40 (int (*)(...))QAccessibleWidget::parent
-44 (int (*)(...))QAccessibleWidget::child
-48 (int (*)(...))QAccessibleWidget::childCount
-52 (int (*)(...))QAccessibleWidget::indexOfChild
-56 (int (*)(...))QAccessibleWidget::text
-60 (int (*)(...))QAccessibleObject::setText
-64 (int (*)(...))QAccessibleWidget::rect
-68 (int (*)(...))QAccessibleWidget::role
-72 (int (*)(...))QAccessibleWidget::state
-76 (int (*)(...))QAccessibleWidget::foregroundColor
-80 (int (*)(...))QAccessibleWidget::backgroundColor
-84 (int (*)(...))QAccessibleInterface::virtual_hook
-88 (int (*)(...))QAccessibleWidget::interface_cast
-92 (int (*)(...))QAccessibleWidget::actionNames
-96 (int (*)(...))QAccessibleWidget::doAction
-100 (int (*)(...))QAccessibleWidget::keyBindingsForAction
-104 (int (*)(...))-0x00000000000000008
-108 (int (*)(...))(& _ZTI17QAccessibleWidget)
-112 (int (*)(...))QAccessibleWidget::_ZThn8_N17QAccessibleWidgetD1Ev
-116 (int (*)(...))QAccessibleWidget::_ZThn8_N17QAccessibleWidgetD0Ev
-120 (int (*)(...))QAccessibleWidget::_ZThn8_NK17QAccessibleWidget11actionNamesEv
-124 (int (*)(...))QAccessibleActionInterface::localizedActionName
-128 (int (*)(...))QAccessibleActionInterface::localizedActionDescription
-132 (int (*)(...))QAccessibleWidget::_ZThn8_N17QAccessibleWidget8doActionERK7QString
-136 (int (*)(...))QAccessibleWidget::_ZThn8_NK17QAccessibleWidget20keyBindingsForActionERK7QString
-
-Class QAccessibleWidget
- size=16 align=4
- base size=16 base align=4
-QAccessibleWidget (0xb28fd300) 0
- vptr=((& QAccessibleWidget::_ZTV17QAccessibleWidget) + 8u)
- QAccessibleObject (0xb2e67c6c) 0
- primary-for QAccessibleWidget (0xb28fd300)
- QAccessibleInterface (0xb28fcd90) 0 nearly-empty
- primary-for QAccessibleObject (0xb2e67c6c)
- QAccessibleActionInterface (0xb28fcdc8) 8 nearly-empty
- vptr=((& QAccessibleWidget::_ZTV17QAccessibleWidget) + 112u)
-
Class QSizePolicy
size=4 align=4
base size=4 base align=4
diff --git a/tests/auto/cmake/CMakeLists.txt b/tests/auto/cmake/CMakeLists.txt
index 6da0c9bfa6..ad31956f62 100644
--- a/tests/auto/cmake/CMakeLists.txt
+++ b/tests/auto/cmake/CMakeLists.txt
@@ -51,20 +51,22 @@ if(NOT ${CMAKE_VERSION} VERSION_LESS 2.8.9)
# Requires INCLUDE_DIRECTORIES target property in CMake 2.8.8
# and POSITION_INDEPENDENT_CODE target property in 2.8.9
expect_pass(test_use_modules_function)
+ expect_pass(test_umbrella_config)
else()
- message("CMake version older than 2.8.9 (Found ${CMAKE_VERSION}). Not running test \"test_use_modules_function\"")
+ message("CMake version older than 2.8.9 (Found ${CMAKE_VERSION}). Not running test \"test_use_modules_function\" or \"test_umbrella_config\"")
endif()
+
expect_pass(test_wrap_cpp_and_resources)
-expect_pass(test_dependent_modules)
+if (NOT NO_WIDGETS)
+ expect_pass(test_dependent_modules)
+ expect_pass("test(needsquoting)dirname")
+endif()
expect_fail(test_add_resource_options)
expect_fail(test_wrap_cpp_options)
-expect_pass("test(needsquoting)dirname")
expect_pass(test_platform_defs_include)
expect_pass(test_qtmainwin_library)
-# If Qt D-Bus has been installed then run the tests for its macros.
-find_package(Qt5DBus QUIET)
-if (Qt5DBus_FOUND AND NOT APPLE)
+if (NOT NO_DBUS)
expect_pass(test_dbus_module)
endif()
expect_pass(test_multiple_find_package)
@@ -78,30 +80,37 @@ expect_pass(test_testlib_definitions)
expect_pass(test_json_plugin_includes)
expect_fail(test_testlib_no_link_gui)
-expect_fail(test_testlib_no_link_widgets)
-
execute_process(COMMAND ${CMAKE_COMMAND} -E copy
"${CMAKE_CURRENT_SOURCE_DIR}/test_testlib_definitions/main.cpp"
"${CMAKE_CURRENT_BINARY_DIR}/failbuild/test_testlib_no_link_gui/test_testlib_no_link_gui/"
)
-execute_process(COMMAND ${CMAKE_COMMAND} -E copy
- "${CMAKE_CURRENT_SOURCE_DIR}/test_testlib_definitions/main.cpp"
- "${CMAKE_CURRENT_BINARY_DIR}/failbuild/test_testlib_no_link_widgets/test_testlib_no_link_widgets/"
-)
+
+if (NOT NO_WIDGETS)
+ expect_fail(test_testlib_no_link_widgets)
+ execute_process(COMMAND ${CMAKE_COMMAND} -E copy
+ "${CMAKE_CURRENT_SOURCE_DIR}/test_testlib_definitions/main.cpp"
+ "${CMAKE_CURRENT_BINARY_DIR}/failbuild/test_testlib_no_link_widgets/test_testlib_no_link_widgets/"
+ )
+endif()
set(qt_module_includes
Core QObject
Gui QImage
- Widgets QWidget
Network QHostInfo
- OpenGL QGLBuffer
Sql QSqlError
Test QTestEventList
Xml QDomDocument
- PrintSupport QPrintDialog
)
-if (UNIX AND NOT APPLE AND NOT QNXNTO)
+if (NOT NO_WIDGETS)
+ list(APPEND qt_module_includes
+ Widgets QWidget
+ OpenGL QGLBuffer
+ PrintSupport QPrintDialog
+ )
+endif()
+
+if (NOT NO_DBUS)
list(APPEND qt_module_includes
DBus QDBusMessage
)
@@ -111,3 +120,8 @@ test_module_includes(
${qt_module_includes}
)
expect_pass(test_concurrent_module)
+expect_pass(test_openglextensions_module)
+
+if (NOT CMAKE_VERSION VERSION_LESS 2.8.11)
+ expect_pass(test_interface)
+endif()
diff --git a/tests/auto/cmake/cmake.pro b/tests/auto/cmake/cmake.pro
index bf2dbcb772..715e710490 100644
--- a/tests/auto/cmake/cmake.pro
+++ b/tests/auto/cmake/cmake.pro
@@ -2,4 +2,14 @@
# Cause make to do nothing.
TEMPLATE = subdirs
+CMAKE_QT_MODULES_UNDER_TEST = core network xml sql testlib
+
+qtHaveModule(dbus): CMAKE_QT_MODULES_UNDER_TEST += dbus
+qtHaveModule(gui): CMAKE_QT_MODULES_UNDER_TEST += gui
+qtHaveModule(openglextensions): CMAKE_QT_MODULES_UNDER_TEST += openglextensions
+qtHaveModule(widgets): CMAKE_QT_MODULES_UNDER_TEST += widgets
+qtHaveModule(printsupport): CMAKE_QT_MODULES_UNDER_TEST += printsupport
+qtHaveModule(opengl): CMAKE_QT_MODULES_UNDER_TEST += opengl
+qtHaveModule(concurrent): CMAKE_QT_MODULES_UNDER_TEST += concurrent
+
CONFIG += ctest_testcase
diff --git a/tests/auto/cmake/test(needsquoting)dirname/CMakeLists.txt b/tests/auto/cmake/test(needsquoting)dirname/CMakeLists.txt
index 12ce93ca26..e4c7f07256 100644
--- a/tests/auto/cmake/test(needsquoting)dirname/CMakeLists.txt
+++ b/tests/auto/cmake/test(needsquoting)dirname/CMakeLists.txt
@@ -3,13 +3,11 @@ cmake_minimum_required(VERSION 2.8)
project("test(needsquoting)dirname")
-find_package(Qt5Core REQUIRED)
-find_package(Qt5Gui REQUIRED)
find_package(Qt5Widgets REQUIRED)
-include_directories(${Qt5Core_INCLUDE_DIRS} ${Qt5Gui_INCLUDE_DIRS} ${Qt5Widgets_INCLUDE_DIRS})
+include_directories(${Qt5Widgets_INCLUDE_DIRS})
-add_definitions(${Qt5Core_DEFINITIONS})
+add_definitions(${Qt5Widgets_DEFINITIONS})
set(CMAKE_INCLUDE_CURRENT_DIR ON)
diff --git a/tests/auto/cmake/test_concurrent_module/CMakeLists.txt b/tests/auto/cmake/test_concurrent_module/CMakeLists.txt
index efd7b725ea..7014fe51cd 100644
--- a/tests/auto/cmake/test_concurrent_module/CMakeLists.txt
+++ b/tests/auto/cmake/test_concurrent_module/CMakeLists.txt
@@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 2.8)
project(test_concurrent_module)
-find_package(Qt5Concurrent REQUIRED)
+find_package(Qt5Concurrent 5.0.0 REQUIRED)
include_directories(
${Qt5Concurrent_INCLUDE_DIRS}
diff --git a/tests/auto/cmake/test_dbus_module/CMakeLists.txt b/tests/auto/cmake/test_dbus_module/CMakeLists.txt
index 6bbb52697c..36480e85e8 100644
--- a/tests/auto/cmake/test_dbus_module/CMakeLists.txt
+++ b/tests/auto/cmake/test_dbus_module/CMakeLists.txt
@@ -3,17 +3,15 @@ cmake_minimum_required(VERSION 2.8)
project(test_dbus_module)
-find_package(Qt5Core REQUIRED)
-find_package(Qt5DBus REQUIRED)
+find_package(Qt5DBus 5.0.0 REQUIRED)
include_directories(
- ${Qt5Core_INCLUDE_DIRS}
${Qt5DBus_INCLUDE_DIRS}
)
-add_definitions(${Qt5Core_DEFINITIONS} ${Qt5DBus_DEFINITIONS})
+add_definitions(${Qt5DBus_DEFINITIONS})
-set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${Qt5Core_EXECUTABLE_COMPILE_FLAGS}")
+set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${Qt5DBus_EXECUTABLE_COMPILE_FLAGS}")
set(CMAKE_INCLUDE_CURRENT_DIR ON)
@@ -33,4 +31,4 @@ qt5_add_dbus_adaptor(my_srcs
)
add_executable(myobject ${my_srcs} ${moc_files})
-target_link_libraries(myobject ${Qt5DBus_LIBRARIES} ${Qt5Core_LIBRARIES})
+target_link_libraries(myobject ${Qt5DBus_LIBRARIES})
diff --git a/tests/auto/cmake/test_interface/CMakeLists.txt b/tests/auto/cmake/test_interface/CMakeLists.txt
new file mode 100644
index 0000000000..a8af92da63
--- /dev/null
+++ b/tests/auto/cmake/test_interface/CMakeLists.txt
@@ -0,0 +1,36 @@
+
+cmake_minimum_required(VERSION 2.8.11)
+
+project(test_interface)
+
+find_package(Qt5Widgets)
+
+set(CMAKE_AUTOMOC ON)
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+add_executable(test_interface_exe WIN32 main.cpp mainwindow.cpp)
+
+# No need to specify include directories, compile definitions, the PIC flag, or to
+# link explicitly to Qt5::WinMain.
+target_link_libraries(test_interface_exe Qt5::Widgets)
+
+file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/try_compile-test.cpp"
+ "
+#include <QString>
+#include <QWidget>
+
+int main(int,char**) { QWidget w; w.show(); return 0; }
+"
+)
+
+# The try_compile works because Qt5::Widgets is listed in the LINK_LIBRARIES,
+# which causes the includes, defines and appropriate PIC flag to be used.
+try_compile(_TRY_COMPILE_RES "${CMAKE_CURRENT_BINARY_DIR}/try_compile-test"
+ "${CMAKE_CURRENT_BINARY_DIR}/try_compile-test.cpp"
+ LINK_LIBRARIES Qt5::Widgets
+ OUTPUT_VARIABLE TC_OV
+)
+
+if (NOT _TRY_COMPILE_RES)
+ message(SEND_ERROR "The use of try_compile with Qt5::Widgets failed. The output was :\n${TC_OV}")
+endif()
diff --git a/tests/auto/cmake/test_interface/main.cpp b/tests/auto/cmake/test_interface/main.cpp
new file mode 100644
index 0000000000..c1d699219b
--- /dev/null
+++ b/tests/auto/cmake/test_interface/main.cpp
@@ -0,0 +1,58 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Stephen Kelly <stephen.kelly@kdab.com>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QApplication>
+
+#include "mainwindow.h"
+
+#if !defined(QT_CORE_LIB) || !defined(QT_GUI_LIB) || !defined(QT_WIDGETS_LIB)
+#error Missing module definitions
+#endif
+
+int main(int argc, char **argv)
+{
+ QApplication app(argc, argv);
+
+ MainWindow mw;
+ mw.show();
+
+ return app.exec();
+}
diff --git a/mkspecs/unsupported/linux-android-armeabi-g++/qplatformdefs.h b/tests/auto/cmake/test_interface/mainwindow.cpp
index 38b5f6e6d2..1f79bd4a1d 100644
--- a/mkspecs/unsupported/linux-android-armeabi-g++/qplatformdefs.h
+++ b/tests/auto/cmake/test_interface/mainwindow.cpp
@@ -1,9 +1,9 @@
/****************************************************************************
**
-** Copyright (C) 2012 Collabora Ltd, author <robin.burchell@collabora.co.uk>
+** Copyright (C) 2012 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Stephen Kelly <stephen.kelly@kdab.com>
** Contact: http://www.qt-project.org/legal
**
-** This file is part of the QtCore module of the Qt Toolkit.
+** This file is part of the test suite of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
@@ -39,4 +39,10 @@
**
****************************************************************************/
-#include "../../common/android/qplatformdefs.h"
+#include "mainwindow.h"
+
+MainWindow::MainWindow(QWidget *parent)
+ : QWidget(parent)
+{
+
+}
diff --git a/tests/auto/cmake/test_interface/mainwindow.h b/tests/auto/cmake/test_interface/mainwindow.h
new file mode 100644
index 0000000000..2037c59eab
--- /dev/null
+++ b/tests/auto/cmake/test_interface/mainwindow.h
@@ -0,0 +1,57 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Stephen Kelly <stephen.kelly@kdab.com>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef MAINWINDOW_H
+#define MAINWINDOW_H
+
+#include <QWidget>
+
+class MainWindow : public QWidget
+{
+ Q_OBJECT
+public:
+ MainWindow(QWidget *parent = 0);
+
+signals:
+ void somethingHappened();
+};
+
+#endif
diff --git a/tests/auto/cmake/test_openglextensions_module/CMakeLists.txt b/tests/auto/cmake/test_openglextensions_module/CMakeLists.txt
new file mode 100644
index 0000000000..3c23bce2bd
--- /dev/null
+++ b/tests/auto/cmake/test_openglextensions_module/CMakeLists.txt
@@ -0,0 +1,22 @@
+
+cmake_minimum_required(VERSION 2.8)
+
+project(test_openglextensions_module)
+
+find_package(Qt5OpenGLExtensions 5.1.0 REQUIRED)
+
+include_directories(
+ ${Qt5OpenGLExtensions_INCLUDE_DIRS}
+)
+
+add_definitions(
+ ${Qt5OpenGLExtensions_DEFINITIONS}
+)
+
+set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${Qt5OpenGLExtensions_EXECUTABLE_COMPILE_FLAGS}")
+
+add_executable(mainapp main.cpp)
+
+target_link_libraries(mainapp
+ ${Qt5OpenGLExtensions_LIBRARIES}
+)
diff --git a/tests/auto/cmake/test_openglextensions_module/main.cpp b/tests/auto/cmake/test_openglextensions_module/main.cpp
new file mode 100644
index 0000000000..cb4847a691
--- /dev/null
+++ b/tests/auto/cmake/test_openglextensions_module/main.cpp
@@ -0,0 +1,56 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Stephen Kelly <stephen.kelly@kdab.com>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtOpenGLExtensions>
+#include <QtOpenGLExtensions/QtOpenGLExtensions>
+#include <QtOpenGLExtensions/QOpenGLExtensions>
+#include <QOpenGLExtensions>
+
+int main(int argc, char **argv)
+{
+#if defined(QT_OPENGL_ES_2)
+ QOpenGLExtension_OES_vertex_array_object obj;
+#else
+ QOpenGLExtension_ARB_draw_buffers obj;
+#endif
+
+ return 0;
+}
diff --git a/tests/auto/cmake/test_testlib_definitions/CMakeLists.txt b/tests/auto/cmake/test_testlib_definitions/CMakeLists.txt
index c370e8effa..cc54bf5bc3 100644
--- a/tests/auto/cmake/test_testlib_definitions/CMakeLists.txt
+++ b/tests/auto/cmake/test_testlib_definitions/CMakeLists.txt
@@ -35,4 +35,6 @@ endmacro()
add_subdirectory(core_only)
add_subdirectory(gui)
-add_subdirectory(widgets)
+if(NOT NO_WIDGETS)
+ add_subdirectory(widgets)
+endif()
diff --git a/tests/auto/cmake/test_umbrella_config/CMakeLists.txt b/tests/auto/cmake/test_umbrella_config/CMakeLists.txt
new file mode 100644
index 0000000000..a8fc2b53ed
--- /dev/null
+++ b/tests/auto/cmake/test_umbrella_config/CMakeLists.txt
@@ -0,0 +1,20 @@
+
+cmake_minimum_required(VERSION 2.8)
+
+project(test_umbrella_config)
+
+add_subdirectory(components_found)
+
+if (Qt5_FOUND)
+ message(SEND_ERROR "Qt5_FOUND variable leaked!")
+endif()
+
+if (Qt5Core_FOUND)
+ message(SEND_ERROR "Qt5Core_FOUND variable leaked!")
+endif()
+
+if (TARGET Qt5::Core)
+ message(SEND_ERROR "Qt5::Core target leaked!")
+endif()
+
+add_subdirectory(components_not_found)
diff --git a/tests/auto/cmake/test_umbrella_config/components_found/CMakeLists.txt b/tests/auto/cmake/test_umbrella_config/components_found/CMakeLists.txt
new file mode 100644
index 0000000000..2099e36068
--- /dev/null
+++ b/tests/auto/cmake/test_umbrella_config/components_found/CMakeLists.txt
@@ -0,0 +1,18 @@
+
+# The module finds its dependencies
+find_package(Qt5 5.1.0
+ COMPONENTS Core
+ OPTIONAL_COMPONENTS DoesNotExist
+)
+
+if (NOT Qt5_FOUND)
+ message(SEND_ERROR "Qt5 umbrella package not found!")
+endif()
+
+if (NOT Qt5Core_FOUND)
+ message(SEND_ERROR "Qt5Core package not found!")
+endif()
+
+if (Qt5DoesNotExist_FOUND)
+ message(SEND_ERROR "Non-existent package found!")
+endif()
diff --git a/tests/auto/cmake/test_umbrella_config/components_not_found/CMakeLists.txt b/tests/auto/cmake/test_umbrella_config/components_not_found/CMakeLists.txt
new file mode 100644
index 0000000000..424c3e3445
--- /dev/null
+++ b/tests/auto/cmake/test_umbrella_config/components_not_found/CMakeLists.txt
@@ -0,0 +1,17 @@
+
+# The module finds its dependencies
+find_package(Qt5
+ COMPONENTS Core DoesNotExist
+)
+
+if (Qt5_FOUND)
+ message(SEND_ERROR "Qt5 umbrella package found, though it should not be!")
+endif()
+
+if (NOT Qt5Core_FOUND)
+ message(SEND_ERROR "Qt5Core package not found!")
+endif()
+
+if (Qt5DoesNotExist_FOUND)
+ message(SEND_ERROR "Non-existent package found!")
+endif()
diff --git a/tests/auto/cmake/test_use_modules_function/CMakeLists.txt b/tests/auto/cmake/test_use_modules_function/CMakeLists.txt
index 4ce01938cb..bfcdd9d1d7 100644
--- a/tests/auto/cmake/test_use_modules_function/CMakeLists.txt
+++ b/tests/auto/cmake/test_use_modules_function/CMakeLists.txt
@@ -13,4 +13,4 @@ add_executable(three three.cpp)
find_package(Qt5Core)
qt5_use_modules(two Test)
-qt5_use_modules(three Widgets Test)
+qt5_use_modules(three Gui Test)
diff --git a/tests/auto/cmake/test_use_modules_function/three.cpp b/tests/auto/cmake/test_use_modules_function/three.cpp
index c3aff71b03..42ae910981 100644
--- a/tests/auto/cmake/test_use_modules_function/three.cpp
+++ b/tests/auto/cmake/test_use_modules_function/three.cpp
@@ -40,7 +40,7 @@
****************************************************************************/
#include <QtTest>
-#include <QWidget>
+#include <QWindow>
class Three : public QObject
{
@@ -48,7 +48,7 @@ class Three : public QObject
public:
Three(QObject *parent = 0)
{
- QWidget *w = new QWidget;
+ QWindow *w = new QWindow;
w->show();
}
};
diff --git a/tests/auto/concurrent/qtconcurrentfilter/qtconcurrentfilter.pro b/tests/auto/concurrent/qtconcurrentfilter/qtconcurrentfilter.pro
index 6a1e7a5180..e82d101de0 100644
--- a/tests/auto/concurrent/qtconcurrentfilter/qtconcurrentfilter.pro
+++ b/tests/auto/concurrent/qtconcurrentfilter/qtconcurrentfilter.pro
@@ -3,4 +3,3 @@ TARGET = tst_qtconcurrentfilter
QT = core testlib concurrent
SOURCES = tst_qtconcurrentfilter.cpp
DEFINES += QT_STRICT_ITERATORS
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/concurrent/qtconcurrentfilter/tst_qtconcurrentfilter.cpp b/tests/auto/concurrent/qtconcurrentfilter/tst_qtconcurrentfilter.cpp
index 69d1535ccf..4ce11f208f 100644
--- a/tests/auto/concurrent/qtconcurrentfilter/tst_qtconcurrentfilter.cpp
+++ b/tests/auto/concurrent/qtconcurrentfilter/tst_qtconcurrentfilter.cpp
@@ -100,7 +100,6 @@ void tst_QtConcurrentFilter::filter()
QCOMPARE(vector, QVector<int>() << 2 << 4);
}
-
// function
{
QList<int> list;
@@ -554,7 +553,6 @@ void tst_QtConcurrentFilter::filteredReduced()
int sum = QtConcurrent::filteredReduced<int>(vector, KeepEvenIntegers(), IntSumReduce());
QCOMPARE(sum, 6);
}
-
{
int sum = QtConcurrent::filteredReduced<int>(list.begin(),
list.end(),
@@ -1396,43 +1394,42 @@ void tst_QtConcurrentFilter::filteredReduced()
// ### the same as above, with an initial result value
}
-bool filterfn(int i)
-{
+bool filterfn(int i)
+{
return (i % 2);
-}
+}
void tst_QtConcurrentFilter::resultAt()
{
- QList<int> ints;
+ QList<int> ints;
for (int i=0; i < 1000; ++i)
ints << i;
QFuture<int> future = QtConcurrent::filtered(ints, filterfn);
- future.waitForFinished();
+ future.waitForFinished();
-
for (int i = 0; i < future.resultCount(); ++i) {
QCOMPARE(future.resultAt(i), ints.at(i * 2 + 1));
}
}
-bool waitFilterfn(const int &i)
-{
+bool waitFilterfn(const int &i)
+{
QTest::qWait(1);
return (i % 2);
-}
+}
void tst_QtConcurrentFilter::incrementalResults()
{
const int count = 200;
- QList<int> ints;
+ QList<int> ints;
for (int i=0; i < count; ++i)
ints << i;
QFuture<int> future = QtConcurrent::filtered(ints, waitFilterfn);
-
+
QList<int> results;
while (future.isFinished() == false) {
diff --git a/tests/auto/concurrent/qtconcurrentiteratekernel/qtconcurrentiteratekernel.pro b/tests/auto/concurrent/qtconcurrentiteratekernel/qtconcurrentiteratekernel.pro
index 82446e55a2..4cfebc0e3d 100644
--- a/tests/auto/concurrent/qtconcurrentiteratekernel/qtconcurrentiteratekernel.pro
+++ b/tests/auto/concurrent/qtconcurrentiteratekernel/qtconcurrentiteratekernel.pro
@@ -2,4 +2,3 @@ CONFIG += testcase parallel_test
TARGET = tst_qtconcurrentiteratekernel
QT = core testlib concurrent
SOURCES = tst_qtconcurrentiteratekernel.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/concurrent/qtconcurrentiteratekernel/tst_qtconcurrentiteratekernel.cpp b/tests/auto/concurrent/qtconcurrentiteratekernel/tst_qtconcurrentiteratekernel.cpp
index 3613e8df60..33133e876f 100644
--- a/tests/auto/concurrent/qtconcurrentiteratekernel/tst_qtconcurrentiteratekernel.cpp
+++ b/tests/auto/concurrent/qtconcurrentiteratekernel/tst_qtconcurrentiteratekernel.cpp
@@ -112,7 +112,7 @@ public:
return false;
}
bool runIteration(TestIterator it, int index , void *result)
- {
+ {
return runIterations(it, index, index + 1, result);
}
@@ -132,7 +132,7 @@ public:
return false;
}
bool runIteration(TestIterator it, int index , void *result)
- {
+ {
return runIterations(it, index, index + 1, result);
}
};
@@ -166,7 +166,7 @@ public:
return false;
}
bool runIteration(TestIterator it, int index , void *result)
- {
+ {
return runIterations(it, index, index + 1, result);
}
};
@@ -217,13 +217,13 @@ public:
if (100 >= begin && 100 < end) {
throttling = true;
}
-
+
QTest::qWait(1);
return false;
}
bool runIteration(TestIterator it, int index , void *result)
- {
+ {
return runIterations(it, index, index + 1, result);
}
diff --git a/tests/auto/concurrent/qtconcurrentmap/qtconcurrentmap.pro b/tests/auto/concurrent/qtconcurrentmap/qtconcurrentmap.pro
index eeb534a0e1..199e5ad4d6 100644
--- a/tests/auto/concurrent/qtconcurrentmap/qtconcurrentmap.pro
+++ b/tests/auto/concurrent/qtconcurrentmap/qtconcurrentmap.pro
@@ -3,4 +3,3 @@ TARGET = tst_qtconcurrentmap
QT = core testlib concurrent
SOURCES = tst_qtconcurrentmap.cpp
DEFINES += QT_STRICT_ITERATORS
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/concurrent/qtconcurrentmap/tst_qtconcurrentmap.cpp b/tests/auto/concurrent/qtconcurrentmap/tst_qtconcurrentmap.cpp
index eeacf2ccbb..1743ec3459 100644
--- a/tests/auto/concurrent/qtconcurrentmap/tst_qtconcurrentmap.cpp
+++ b/tests/auto/concurrent/qtconcurrentmap/tst_qtconcurrentmap.cpp
@@ -2226,12 +2226,12 @@ int mapper(const int &i)
void tst_QtConcurrentMap::incrementalResults()
{
const int count = 200;
- QList<int> ints;
+ QList<int> ints;
for (int i=0; i < count; ++i)
ints << i;
QFuture<int> future = QtConcurrent::mapped(ints, mapper);
-
+
QList<int> results;
while (future.isFinished() == false) {
@@ -2311,7 +2311,7 @@ void tst_QtConcurrentMap::stlContainers()
QCOMPARE(list2.size(), (std::vector<int>::size_type)(2));
QtConcurrent::mapped(list, mapper).waitForFinished();
-
+
QtConcurrent::blockingMap(list, multiplyBy2Immutable);
}
diff --git a/tests/auto/concurrent/qtconcurrentrun/qtconcurrentrun.pro b/tests/auto/concurrent/qtconcurrentrun/qtconcurrentrun.pro
index 23c8049952..03d77b33a2 100644
--- a/tests/auto/concurrent/qtconcurrentrun/qtconcurrentrun.pro
+++ b/tests/auto/concurrent/qtconcurrentrun/qtconcurrentrun.pro
@@ -2,4 +2,3 @@ CONFIG += testcase parallel_test
TARGET = tst_qtconcurrentrun
QT = core testlib concurrent
SOURCES = tst_qtconcurrentrun.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/concurrent/qtconcurrentrun/tst_qtconcurrentrun.cpp b/tests/auto/concurrent/qtconcurrentrun/tst_qtconcurrentrun.cpp
index ab1b0e9d06..8a289ff4e1 100644
--- a/tests/auto/concurrent/qtconcurrentrun/tst_qtconcurrentrun.cpp
+++ b/tests/auto/concurrent/qtconcurrentrun/tst_qtconcurrentrun.cpp
@@ -137,10 +137,10 @@ public:
void tst_QtConcurrentRun::returnValue()
{
QFuture<int> f;
-
+
f = run(returnInt0);
QCOMPARE(f.result(), 10);
-
+
A a;
f = run(&a, &A::member0);
QCOMPARE(f.result(), 10);
@@ -214,7 +214,7 @@ void tst_QtConcurrentRun::functionObject()
{
QFuture<void> f;
TestClass c;
-
+
f = run(c);
f = run(&c);
f = run(c, 10);
diff --git a/tests/auto/concurrent/qtconcurrentthreadengine/qtconcurrentthreadengine.pro b/tests/auto/concurrent/qtconcurrentthreadengine/qtconcurrentthreadengine.pro
index fd2222ade8..f6ddd33504 100644
--- a/tests/auto/concurrent/qtconcurrentthreadengine/qtconcurrentthreadengine.pro
+++ b/tests/auto/concurrent/qtconcurrentthreadengine/qtconcurrentthreadengine.pro
@@ -2,4 +2,3 @@ CONFIG += testcase parallel_test
TARGET = tst_qtconcurrentthreadengine
QT = core testlib concurrent
SOURCES = tst_qtconcurrentthreadengine.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/corelib/animation/qsequentialanimationgroup/tst_qsequentialanimationgroup.cpp b/tests/auto/corelib/animation/qsequentialanimationgroup/tst_qsequentialanimationgroup.cpp
index ccc23851b7..51f07993cd 100644
--- a/tests/auto/corelib/animation/qsequentialanimationgroup/tst_qsequentialanimationgroup.cpp
+++ b/tests/auto/corelib/animation/qsequentialanimationgroup/tst_qsequentialanimationgroup.cpp
@@ -44,7 +44,6 @@
#include <QtCore/qsequentialanimationgroup.h>
Q_DECLARE_METATYPE(QAbstractAnimation::State)
-Q_DECLARE_METATYPE(QAbstractAnimation*)
class tst_QSequentialAnimationGroup : public QObject
{
@@ -84,7 +83,6 @@ private slots:
void tst_QSequentialAnimationGroup::initTestCase()
{
qRegisterMetaType<QAbstractAnimation::State>("QAbstractAnimation::State");
- qRegisterMetaType<QAbstractAnimation*>("QAbstractAnimation*");
}
void tst_QSequentialAnimationGroup::construction()
diff --git a/tests/auto/corelib/codecs/qtextcodec/tst_qtextcodec.cpp b/tests/auto/corelib/codecs/qtextcodec/tst_qtextcodec.cpp
index 6c566e017b..b5f736cfbb 100644
--- a/tests/auto/corelib/codecs/qtextcodec/tst_qtextcodec.cpp
+++ b/tests/auto/corelib/codecs/qtextcodec/tst_qtextcodec.cpp
@@ -84,6 +84,7 @@ private slots:
void utfHeaders_data();
void utfHeaders();
+ void codecForHtml_data();
void codecForHtml();
void codecForUtfText_data();
@@ -1853,23 +1854,81 @@ void tst_QTextCodec::utfHeaders()
}
}
-void tst_QTextCodec::codecForHtml()
+void tst_QTextCodec::codecForHtml_data()
{
- QByteArray html("<html><head></head><body>blah</body></html>");
+ QTest::addColumn<QByteArray>("html");
+ QTest::addColumn<int>("defaultCodecMib");
+ QTest::addColumn<int>("expectedMibEnum");
- QCOMPARE(QTextCodec::codecForHtml(html)->mibEnum(), 4); // latin 1
+ int noDefault = -1;
+ int fallback = 4; // latin 1
+ QByteArray html = "<html><head></head><body>blah</body></html>";
+ QTest::newRow("no charset, latin 1") << html << noDefault << fallback;
- QCOMPARE(QTextCodec::codecForHtml(html, QTextCodec::codecForMib(106))->mibEnum(), 106); // UTF-8
+ QTest::newRow("no charset, default UTF-8") << html << 106 << 106;
html = "<html><head><meta http-equiv=\"content-type\" content=\"text/html; charset=ISO-8859-15\" /></head></html>";
- QCOMPARE(QTextCodec::codecForHtml(html, QTextCodec::codecForMib(106))->mibEnum(), 111); // latin 15
+ QTest::newRow("latin 15, default UTF-8") << html << 106 << 111;
html = "<html><head><meta content=\"text/html; charset=ISO-8859-15\" http-equiv=\"content-type\" /></head></html>";
- QCOMPARE(QTextCodec::codecForHtml(html, QTextCodec::codecForMib(106))->mibEnum(), 111); // latin 15
+ QTest::newRow("latin 15, default UTF-8 (#2)") << html << 106 << 111;
+
+ html = "<!DOCTYPE html><html><head><meta charset=\"utf-8\"><meta http-equiv=\"X-UA-Compatible\" content=\"IE=9,chrome=1\"><title>Test</title></head>";
+ QTest::newRow("UTF-8, no default") << html << noDefault << 106;
+
+ html = "<!DOCTYPE html><html><head><meta charset=\"ISO_8859-1:1987\"><meta http-equiv=\"X-UA-Compatible\" content=\"IE=9,chrome=1\"><title>Test</title></head>";
+ QTest::newRow("latin 1, no default") << html << noDefault << 4;
+
+ html = "<!DOCTYPE html><html><head><meta http-equiv=\"X-UA-Compatible\" content=\"IE=9,chrome=1\"><meta charset=\"utf-8\"><title>Test</title></head>";
+ QTest::newRow("UTF-8, no default (#2)") << html << noDefault << 106;
+
+ html = "<html><head><meta http-equiv=\"content-type\" content=\"text/html; charset=UTF-8/></head></html>";
+ QTest::newRow("UTF-8, no quotes") << html << noDefault << 106;
+
+ html = "<html><head><meta http-equiv=\"content-type\" content=\"text/html; charset='UTF-8'/></head></html>";
+ QTest::newRow("UTF-8, single quotes") << html << noDefault << 106;
+
+ html = "<!DOCTYPE html><html><head><meta charset=utf-8><title>Test</title></head>";
+ QTest::newRow("UTF-8, > terminator") << html << noDefault << 106;
+
+ html = "<!DOCTYPE html><html><head><meta charset= utf-8 ><title>Test</title></head>";
+ QTest::newRow("UTF-8, > terminator with spaces") << html << noDefault << 106;
+
+ html = "<!DOCTYPE html><html><head><meta charset= utf/8 ><title>Test</title></head>";
+ QTest::newRow("UTF-8, > teminator with early backslash)") << html << noDefault << 106;
+ // Test invalid charsets.
html = "<html><head><meta http-equiv=\"content-type\" content=\"text/html; charset=invalid-foo\" /></head></html>";
- QCOMPARE(QTextCodec::codecForHtml(html, QTextCodec::codecForMib(106))->mibEnum(), 106); // UTF-8
- QCOMPARE(QTextCodec::codecForHtml(html)->mibEnum(), 4); // latin 1
+ QTest::newRow("invalid charset, no default") << html << noDefault << fallback;
+ QTest::newRow("invalid charset, default UTF-8") << html << 106 << 106;
+
+ html = "<!DOCTYPE html><html><head><meta http-equiv=\"X-UA-Compatible\" content=\"IE=9,chrome=1\"><meta charset=\"";
+ html.prepend(QByteArray().fill(' ', 512 - html.size()));
+ QTest::newRow("invalid charset (large header)") << html << noDefault << fallback;
+
+ html = "<!DOCTYPE html><html><head><meta http-equiv=\"X-UA-Compatible\" content=\"IE=9,chrome=1\"><meta charset=\"utf-8";
+ QTest::newRow("invalid charset (no closing double quote)") << html << noDefault << fallback;
+
+ html = "<!DOCTYPE html><html><head><meta http-equiv=\"X-UA-Compatible\" content=\"IE=9,chrome=1\"><meta charset='utf-8";
+ QTest::newRow("invalid charset (no closing single quote)") << html << noDefault << fallback;
+
+ html = "<!DOCTYPE html><html><head><meta charset=utf-8 foo=bar><title>Test</title></head>";
+ QTest::newRow("invalid (space terminator)") << html << noDefault << fallback;
+
+ html = "<!DOCTYPE html><html><head><meta charset=\" utf' 8 /><title>Test</title></head>";
+ QTest::newRow("invalid charset, early terminator (')") << html << noDefault << fallback;
+}
+
+void tst_QTextCodec::codecForHtml()
+{
+ QFETCH(QByteArray, html);
+ QFETCH(int, defaultCodecMib);
+ QFETCH(int, expectedMibEnum);
+
+ if (defaultCodecMib != -1)
+ QCOMPARE(QTextCodec::codecForHtml(html, QTextCodec::codecForMib(defaultCodecMib))->mibEnum(), expectedMibEnum);
+ else // Test one parameter version when there is no default codec.
+ QCOMPARE(QTextCodec::codecForHtml(html)->mibEnum(), expectedMibEnum);
}
void tst_QTextCodec::codecForUtfText_data()
diff --git a/tests/auto/corelib/global/global.pro b/tests/auto/corelib/global/global.pro
index 5489b8330d..c05905bd15 100644
--- a/tests/auto/corelib/global/global.pro
+++ b/tests/auto/corelib/global/global.pro
@@ -7,4 +7,6 @@ SUBDIRS=\
qnumeric \
qrand \
qlogging \
- qtendian
+ qtendian \
+ qglobalstatic \
+
diff --git a/tests/auto/corelib/global/qgetputenv/tst_qgetputenv.cpp b/tests/auto/corelib/global/qgetputenv/tst_qgetputenv.cpp
index a4aca82aa9..ef41ef8801 100644
--- a/tests/auto/corelib/global/qgetputenv/tst_qgetputenv.cpp
+++ b/tests/auto/corelib/global/qgetputenv/tst_qgetputenv.cpp
@@ -75,6 +75,13 @@ void tst_QGetPutEnv::getSetCheck()
QVERIFY(result == "supervalue");
qputenv(varName,QByteArray());
+
+ // Now test qunsetenv
+ QVERIFY(qunsetenv(varName));
+ QVERIFY(!qEnvironmentVariableIsSet(varName));
+ QVERIFY(qEnvironmentVariableIsEmpty(varName));
+ result = qgetenv(varName);
+ QCOMPARE(result, QByteArray());
}
QTEST_MAIN(tst_QGetPutEnv)
diff --git a/tests/auto/corelib/global/qglobal/tst_qglobal.cpp b/tests/auto/corelib/global/qglobal/tst_qglobal.cpp
index f54af657c0..3696ee264f 100644
--- a/tests/auto/corelib/global/qglobal/tst_qglobal.cpp
+++ b/tests/auto/corelib/global/qglobal/tst_qglobal.cpp
@@ -55,6 +55,8 @@ private slots:
void checkptr();
void qstaticassert();
void qConstructorFunction();
+ void qCoreAppStartupFunction();
+ void qCoreAppStartupFunctionRestart();
void isEnum();
void qAlignOf();
};
@@ -303,6 +305,33 @@ void tst_QGlobal::qConstructorFunction()
QCOMPARE(qConstructorFunctionValue, 123);
}
+static int qStartupFunctionValue;
+static void myStartupFunc()
+{
+ Q_ASSERT(QCoreApplication::instance());
+ if (QCoreApplication::instance())
+ qStartupFunctionValue += 124;
+}
+
+Q_COREAPP_STARTUP_FUNCTION(myStartupFunc)
+
+void tst_QGlobal::qCoreAppStartupFunction()
+{
+ QCOMPARE(qStartupFunctionValue, 0);
+ int argc = 1;
+ char *argv[] = { const_cast<char*>("tst_qglobal") };
+ QCoreApplication app(argc, argv);
+ QCOMPARE(qStartupFunctionValue, 124);
+}
+
+void tst_QGlobal::qCoreAppStartupFunctionRestart()
+{
+ qStartupFunctionValue = 0;
+ qCoreAppStartupFunction();
+ qStartupFunctionValue = 0;
+ qCoreAppStartupFunction();
+}
+
struct isEnum_A {
int n_;
};
@@ -532,5 +561,5 @@ void tst_QGlobal::qAlignOf()
#undef TEST_AlignOf_RValueRef
#undef TEST_AlignOf_impl
-QTEST_MAIN(tst_QGlobal)
+QTEST_APPLESS_MAIN(tst_QGlobal)
#include "tst_qglobal.moc"
diff --git a/tests/auto/corelib/global/qglobalstatic/qglobalstatic.pro b/tests/auto/corelib/global/qglobalstatic/qglobalstatic.pro
new file mode 100644
index 0000000000..21cab8f67d
--- /dev/null
+++ b/tests/auto/corelib/global/qglobalstatic/qglobalstatic.pro
@@ -0,0 +1,12 @@
+QT += testlib core-private
+
+QT -= gui
+
+TARGET = tst_qglobalstatic
+CONFIG += console
+CONFIG -= app_bundle
+CONFIG += exceptions
+
+SOURCES += tst_qglobalstatic.cpp
+DEFINES += SRCDIR=\\\"$$PWD/\\\"
+DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/corelib/global/qglobalstatic/tst_qglobalstatic.cpp b/tests/auto/corelib/global/qglobalstatic/tst_qglobalstatic.cpp
new file mode 100644
index 0000000000..131b37f821
--- /dev/null
+++ b/tests/auto/corelib/global/qglobalstatic/tst_qglobalstatic.cpp
@@ -0,0 +1,236 @@
+/****************************************************************************
+**
+** Copyright (C) 2011 Thiago Macieira <thiago@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore 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$
+**
+****************************************************************************/
+
+#include <QtCore/QThread>
+#include <QtTest/QtTest>
+
+class tst_QGlobalStatic : public QObject
+{
+ Q_OBJECT
+
+private Q_SLOTS:
+ void beforeInitialization();
+ void api();
+ void constVolatile();
+ void exception();
+ void threadedException();
+ void threadStressTest();
+ void afterDestruction();
+};
+
+Q_GLOBAL_STATIC_WITH_ARGS(const int, constInt, (42))
+Q_GLOBAL_STATIC_WITH_ARGS(volatile int, volatileInt, (-47))
+
+void otherFunction()
+{
+ // never called
+ constInt();
+ volatileInt();
+}
+
+// do not initialize the following Q_GLOBAL_STATIC
+Q_GLOBAL_STATIC(int, checkedBeforeInitialization)
+void tst_QGlobalStatic::beforeInitialization()
+{
+ QVERIFY(!checkedBeforeInitialization.exists());
+ QVERIFY(!checkedBeforeInitialization.isDestroyed());
+}
+
+struct Type {
+ int i;
+};
+
+Q_GLOBAL_STATIC(Type, checkedAfterInitialization)
+void tst_QGlobalStatic::api()
+{
+ // check the API
+ QVERIFY((Type *)checkedAfterInitialization);
+ QVERIFY(checkedAfterInitialization());
+ *checkedAfterInitialization = Type();
+ *checkedAfterInitialization() = Type();
+
+ checkedAfterInitialization()->i = 47;
+ checkedAfterInitialization->i = 42;
+ QCOMPARE(checkedAfterInitialization()->i, 42);
+ checkedAfterInitialization()->i = 47;
+ QCOMPARE(checkedAfterInitialization->i, 47);
+
+ QVERIFY(checkedAfterInitialization.exists());
+ QVERIFY(!checkedAfterInitialization.isDestroyed());
+}
+
+void tst_QGlobalStatic::constVolatile()
+{
+ QCOMPARE(*constInt(), 42);
+ QCOMPARE((int)*volatileInt(), -47);
+ QCOMPARE(*constInt(), 42);
+ QCOMPARE((int)*volatileInt(), -47);
+}
+
+struct ThrowingType
+{
+ static QBasicAtomicInt constructedCount;
+ static QBasicAtomicInt destructedCount;
+ ThrowingType()
+ {
+ throw 0;
+ }
+
+ ThrowingType(QBasicAtomicInt &throwControl)
+ {
+ constructedCount.ref();
+ if (throwControl.fetchAndAddRelaxed(-1) != 0)
+ throw 0;
+ }
+ ~ThrowingType() { destructedCount.ref(); }
+};
+
+QBasicAtomicInt ThrowingType::constructedCount = Q_BASIC_ATOMIC_INITIALIZER(0);
+QBasicAtomicInt ThrowingType::destructedCount = Q_BASIC_ATOMIC_INITIALIZER(0);
+
+Q_GLOBAL_STATIC(ThrowingType, throwingGS)
+void tst_QGlobalStatic::exception()
+{
+ bool exceptionCaught = false;
+ try {
+ throwingGS();
+ } catch (int) {
+ exceptionCaught = true;
+ }
+ QVERIFY(exceptionCaught);
+ QCOMPARE(Q_QGS_throwingGS::guard.load(), 0);
+ QVERIFY(!throwingGS.exists());
+ QVERIFY(!throwingGS.isDestroyed());
+}
+
+QBasicAtomicInt exceptionControlVar = Q_BASIC_ATOMIC_INITIALIZER(1);
+Q_GLOBAL_STATIC_WITH_ARGS(ThrowingType, exceptionGS, (exceptionControlVar))
+void tst_QGlobalStatic::threadedException()
+{
+ if (exceptionControlVar.load() != 1)
+ QSKIP("This test cannot be run more than once");
+ ThrowingType::constructedCount.store(0);
+ ThrowingType::destructedCount.store(0);
+
+ bool exceptionCaught = false;
+ try {
+ exceptionGS();
+ } catch (int) {
+ exceptionCaught = true;
+ }
+ QCOMPARE(ThrowingType::constructedCount.load(), 1);
+ QVERIFY(exceptionCaught);
+
+ exceptionGS();
+ QCOMPARE(ThrowingType::constructedCount.load(), 2);
+}
+
+QBasicAtomicInt threadStressTestControlVar = Q_BASIC_ATOMIC_INITIALIZER(5);
+Q_GLOBAL_STATIC_WITH_ARGS(ThrowingType, threadStressTestGS, (threadStressTestControlVar))
+
+
+void tst_QGlobalStatic::threadStressTest()
+{
+ class ThreadStressTestThread: public QThread
+ {
+ public:
+ QReadWriteLock *lock;
+ void run()
+ {
+ QReadLocker l(lock);
+ //usleep(qrand() * 200 / RAND_MAX);
+ // thundering herd
+ try {
+ threadStressTestGS();
+ } catch (int) {
+ }
+ }
+ };
+
+ ThrowingType::constructedCount.store(0);
+ ThrowingType::destructedCount.store(0);
+ int expectedConstructionCount = threadStressTestControlVar.load() + 1;
+ if (expectedConstructionCount <= 0)
+ QSKIP("This test cannot be run more than once");
+
+ const int numThreads = 200;
+ ThreadStressTestThread threads[numThreads];
+ QReadWriteLock lock;
+ lock.lockForWrite();
+ for (int i = 0; i < numThreads; ++i) {
+ threads[i].lock = &lock;
+ threads[i].start();
+ }
+
+ // wait for all threads
+ // release the herd
+ lock.unlock();
+
+ for (int i = 0; i < numThreads; ++i)
+ threads[i].wait();
+
+ QCOMPARE(ThrowingType::constructedCount.loadAcquire(), expectedConstructionCount);
+ QCOMPARE(ThrowingType::destructedCount.loadAcquire(), 0);
+}
+
+Q_GLOBAL_STATIC(int, checkedAfterDestruction)
+void tst_QGlobalStatic::afterDestruction()
+{
+ // this test will not produce results now
+ // it will simply run some code on destruction (after the global statics have been deleted)
+ // if that fails, this will cause a crash
+
+ // static destruction is LIFO: so we must add our exit-time code before the
+ // global static is used for the first time
+ static struct RunAtExit {
+ ~RunAtExit() {
+ int *ptr = checkedAfterDestruction();
+ if (ptr)
+ qFatal("Global static is not null as was expected");
+ }
+ } runAtExit;
+ (void) runAtExit;
+
+ *checkedAfterDestruction = 42;
+}
+
+QTEST_APPLESS_MAIN(tst_QGlobalStatic);
+
+#include "tst_qglobalstatic.moc"
diff --git a/tests/auto/corelib/global/qlogging/tst_qlogging.cpp b/tests/auto/corelib/global/qlogging/tst_qlogging.cpp
index fc96d656a0..04ce504189 100644
--- a/tests/auto/corelib/global/qlogging/tst_qlogging.cpp
+++ b/tests/auto/corelib/global/qlogging/tst_qlogging.cpp
@@ -64,9 +64,11 @@ private slots:
#endif
void qMessagePattern();
+ void qMessagePatternIf();
private:
QString m_appDir;
+ QStringList m_baseEnvironment;
};
static QtMsgType s_type;
@@ -98,6 +100,14 @@ void tst_qmessagehandler::initTestCase()
m_appDir = QFINDTESTDATA("app");
QVERIFY2(!m_appDir.isEmpty(), qPrintable(
QString::fromLatin1("Couldn't find helper app dir starting from %1.").arg(QDir::currentPath())));
+
+ m_baseEnvironment = QProcess::systemEnvironment();
+ for (int i = 0; i < m_baseEnvironment.count(); ++i) {
+ if (m_baseEnvironment.at(i).startsWith("QT_MESSAGE_PATTERN=")) {
+ m_baseEnvironment.removeAt(i);
+ break;
+ }
+ }
}
void tst_qmessagehandler::cleanup()
@@ -637,7 +647,7 @@ void tst_qmessagehandler::qMessagePattern()
//
// test QT_MESSAGE_PATTERN
//
- QStringList environment = QProcess::systemEnvironment();
+ QStringList environment = m_baseEnvironment;
// %{file} is tricky because of shadow builds
environment.prepend("QT_MESSAGE_PATTERN=\"%{type} %{appname} %{line} %{function} %{message}\"");
process.setEnvironment(environment);
@@ -659,7 +669,7 @@ void tst_qmessagehandler::qMessagePattern()
QVERIFY(output.contains("critical tst_qlogging 58 main qCritical"));
QVERIFY(output.contains("debug tst_qlogging 62 main qDebug2"));
- environment = QProcess::systemEnvironment();
+ environment = m_baseEnvironment;
environment.prepend("QT_MESSAGE_PATTERN=\"PREFIX: %{unknown} %{message}\"");
process.setEnvironment(environment);
@@ -702,5 +712,68 @@ void tst_qmessagehandler::qMessagePattern()
QCOMPARE(QString::fromLatin1(output), QString::fromLatin1(expected));
}
+void tst_qmessagehandler::qMessagePatternIf()
+{
+ QProcess process;
+ const QString appExe = m_appDir + "/app";
+
+ QStringList environment = m_baseEnvironment;
+ environment.prepend("QT_MESSAGE_PATTERN=\"[%{if-debug}D%{endif}%{if-warning}W%{endif}%{if-critical}C%{endif}%{if-fatal}F%{endif}] %{message}\"");
+ process.setEnvironment(environment);
+ process.start(appExe);
+ QVERIFY2(process.waitForStarted(), qPrintable(
+ QString::fromLatin1("Could not start %1: %2").arg(appExe, process.errorString())));
+ process.waitForFinished();
+
+ QByteArray output = process.readAllStandardError();
+ // qDebug() << output;
+ QVERIFY(!output.isEmpty());
+ QVERIFY(!output.contains("QT_MESSAGE_PATTERN"));
+
+ QVERIFY(output.contains("[D] static constructor"));
+ // we can't be sure whether the QT_MESSAGE_PATTERN is already destructed
+ QVERIFY(output.contains("static destructor"));
+ QVERIFY(output.contains("[D] qDebug"));
+ QVERIFY(output.contains("[W] qWarning"));
+ QVERIFY(output.contains("[C] qCritical"));
+ QVERIFY(output.contains("[D] qDebug2"));
+
+ //
+ // Tests some errors
+ //
+ environment = m_baseEnvironment;
+ environment.prepend("QT_MESSAGE_PATTERN=\"PREFIX: %{unknown} %{endif} %{if-warning}\"");
+ process.setEnvironment(environment);
+
+ process.start(appExe);
+ QVERIFY2(process.waitForStarted(), qPrintable(
+ QString::fromLatin1("Could not start %1: %2").arg(appExe, process.errorString())));
+ process.waitForFinished();
+
+ output = process.readAllStandardError();
+ // qDebug() << output;
+ QVERIFY(!output.isEmpty());
+ QVERIFY(output.contains("QT_MESSAGE_PATTERN: Unknown placeholder %{unknown}"));
+ QVERIFY(output.contains("QT_MESSAGE_PATTERN: %{endif} without an %{if-*}"));
+ QVERIFY(output.contains("QT_MESSAGE_PATTERN: missing %{endif}"));
+
+
+ environment = m_baseEnvironment;
+ environment.prepend("QT_MESSAGE_PATTERN=\"A %{if-debug}DEBUG%{if-warning}WARNING%{endif} %{message} \"");
+ process.setEnvironment(environment);
+
+ process.start(appExe);
+ QVERIFY2(process.waitForStarted(), qPrintable(
+ QString::fromLatin1("Could not start %1: %2").arg(appExe, process.errorString())));
+ process.waitForFinished();
+
+ output = process.readAllStandardError();
+ // qDebug() << output;
+ QVERIFY(!output.isEmpty());
+ QVERIFY(output.contains("QT_MESSAGE_PATTERN: %{if-*} cannot be nested"));
+ QVERIFY(output.contains("A DEBUG qDebug"));
+ QVERIFY(output.contains("A qWarning"));
+}
+
QTEST_MAIN(tst_qmessagehandler)
#include "tst_qlogging.moc"
diff --git a/tests/auto/corelib/global/qrand/tst_qrand.cpp b/tests/auto/corelib/global/qrand/tst_qrand.cpp
index 6f64ad74b2..4cbbb8de0f 100644
--- a/tests/auto/corelib/global/qrand/tst_qrand.cpp
+++ b/tests/auto/corelib/global/qrand/tst_qrand.cpp
@@ -64,7 +64,7 @@ void tst_QRand::testqrand()
for (int i=0; i<numTestValues; ++i)
if (generatedNumbers[i] != qrand())
generatesSameSequence = false;
-
+
QVERIFY(generatesSameSequence);
for (unsigned int seed=1; seed < 10; seed+=100) {
diff --git a/tests/auto/corelib/io/io.pro b/tests/auto/corelib/io/io.pro
index 03b42a2cbb..b3a51c6f6e 100644
--- a/tests/auto/corelib/io/io.pro
+++ b/tests/auto/corelib/io/io.pro
@@ -14,12 +14,14 @@ SUBDIRS=\
qfilesystemwatcher \
qiodevice \
qipaddress \
+ qlockfile \
qnodebug \
qprocess \
qprocess-noapplication \
qprocessenvironment \
qresourceengine \
qsettings \
+ qsavefile \
qstandardpaths \
qtemporarydir \
qtemporaryfile \
@@ -34,6 +36,12 @@ SUBDIRS=\
qwinoverlappedionotifier
}
+!qtHaveModule(network): SUBDIRS -= \
+ qfile \
+ qiodevice \
+ qprocess \
+ qtextstream
+
!contains(QT_CONFIG, private_tests): SUBDIRS -= \
qabstractfileengine \
qfileinfo \
diff --git a/tests/auto/corelib/io/qdatastream/tst_qdatastream.cpp b/tests/auto/corelib/io/qdatastream/tst_qdatastream.cpp
index 299d375c9c..d7fc76d980 100644
--- a/tests/auto/corelib/io/qdatastream/tst_qdatastream.cpp
+++ b/tests/auto/corelib/io/qdatastream/tst_qdatastream.cpp
@@ -883,7 +883,7 @@ static QBrush qBrushData(int index)
return custom;
}
case 7:
- QLinearGradient gradient(QPoint(2.718, 3.142), QPoint(3.1337, 42));
+ QLinearGradient gradient(QPointF(2.718, 3.142), QPointF(3.1337, 42));
gradient.setCoordinateMode(QGradient::ObjectBoundingMode);
gradient.setSpread(QGradient::ReflectSpread);
gradient.setInterpolationMode(QGradient::ComponentInterpolation);
diff --git a/tests/auto/corelib/io/qdebug/tst_qdebug.cpp b/tests/auto/corelib/io/qdebug/tst_qdebug.cpp
index 333ccc8e49..f452efc1b3 100644
--- a/tests/auto/corelib/io/qdebug/tst_qdebug.cpp
+++ b/tests/auto/corelib/io/qdebug/tst_qdebug.cpp
@@ -52,7 +52,8 @@ private slots:
void warningWithoutDebug() const;
void criticalWithoutDebug() const;
void debugWithBool() const;
- void debugNoSpaces() const;
+ void debugSpaceHandling() const;
+ void stateSaver() const;
void veryLongWarningMessage() const;
void qDebugQStringRef() const;
void qDebugQLatin1String() const;
@@ -150,7 +151,36 @@ void tst_QDebug::debugWithBool() const
QCOMPARE(QString::fromLatin1(s_function), function);
}
-void tst_QDebug::debugNoSpaces() const
+class MyPoint
+{
+public:
+ MyPoint(int val1, int val2)
+ : v1(val1), v2(val2) {}
+ int v1;
+ int v2;
+};
+QDebug operator<< (QDebug s, const MyPoint& point)
+{
+ const QDebugStateSaver saver(s);
+ return s.nospace() << "MyPoint(" << point.v1 << ", " << point.v2 << ")";
+}
+
+class MyLine
+{
+public:
+ MyLine(const MyPoint& point1, const MyPoint& point2)
+ : p1(point1), p2(point2) {}
+ MyPoint p1;
+ MyPoint p2;
+};
+QDebug operator<< (QDebug s, const MyLine& line)
+{
+ const QDebugStateSaver saver(s);
+ s.nospace() << "MyLine(" << line.p1 << ", " << line.p2 << ")";
+ return s;
+}
+
+void tst_QDebug::debugSpaceHandling() const
{
MessageHandlerSetter mhs(myMessageHandler);
{
@@ -166,8 +196,26 @@ void tst_QDebug::debugNoSpaces() const
d << "key=" << "value";
d.space();
d << 1 << 2;
+ MyLine line(MyPoint(10, 11), MyPoint (12, 13));
+ d << line;
+ // With the old implementation of MyPoint doing dbg.nospace() << ...; dbg.space() we ended up with
+ // MyLine(MyPoint(10, 11) , MyPoint(12, 13) )
+ }
+ QCOMPARE(s_msg, QString::fromLatin1(" foo key=value 1 2 MyLine(MyPoint(10, 11), MyPoint(12, 13))"));
+}
+
+void tst_QDebug::stateSaver() const
+{
+ MessageHandlerSetter mhs(myMessageHandler);
+ {
+ QDebug d = qDebug();
+ {
+ QDebugStateSaver saver(d);
+ d.nospace() << hex << right << qSetFieldWidth(3) << qSetPadChar('0') << 42;
+ }
+ d.space() << 42;
}
- QCOMPARE(s_msg, QString::fromLatin1(" foo key=value 1 2 "));
+ QCOMPARE(s_msg, QString::fromLatin1("02a 42 "));
}
void tst_QDebug::veryLongWarningMessage() const
diff --git a/tests/auto/corelib/io/qfile/stdinprocess/main.cpp b/tests/auto/corelib/io/qfile/stdinprocess/main.cpp
index 1c22da45b3..9ca531f615 100644
--- a/tests/auto/corelib/io/qfile/stdinprocess/main.cpp
+++ b/tests/auto/corelib/io/qfile/stdinprocess/main.cpp
@@ -50,7 +50,7 @@ int main(int argc, char *argv[])
printf("echos all its input to its output.\n");
return 1;
}
-
+
QFile file;
if (strcmp(argv[1], "all") == 0) {
diff --git a/tests/auto/corelib/io/qfile/tst_qfile.cpp b/tests/auto/corelib/io/qfile/tst_qfile.cpp
index df7b397481..929865d4d6 100644
--- a/tests/auto/corelib/io/qfile/tst_qfile.cpp
+++ b/tests/auto/corelib/io/qfile/tst_qfile.cpp
@@ -80,6 +80,18 @@ QT_END_NAMESPACE
# include <sys/statfs.h>
#elif defined(Q_OS_WINCE)
# include <qplatformdefs.h>
+#elif defined(Q_OS_VXWORKS)
+# include <fcntl.h>
+#if defined(_WRS_KERNEL)
+#undef QT_OPEN
+#define QT_OPEN(path, oflag) ::open(path, oflag, 0)
+#endif
+#endif
+
+#ifdef Q_OS_QNX
+#ifdef open
+#undef open
+#endif
#endif
#include <stdio.h>
@@ -481,11 +493,6 @@ void tst_QFile::open_data()
QTest::addColumn<bool>("ok");
QTest::addColumn<QFile::FileError>("status");
-#ifdef Q_OS_MAC
- static const QString denied("Operation not permitted");
-#else
- static const QString denied("Permission denied");
-#endif
QTest::newRow( "exist_readOnly" )
<< m_testFile << int(QIODevice::ReadOnly)
<< true << QFile::NoError;
@@ -545,7 +552,7 @@ void tst_QFile::open()
QFETCH( bool, ok );
-#if defined(Q_OS_UNIX)
+#if defined(Q_OS_UNIX) && !defined(Q_OS_VXWORKS)
if (::getuid() == 0)
// root and Chuck Norris don't care for file permissions. Skip.
QSKIP("Running this test as root doesn't make sense");
@@ -1315,7 +1322,7 @@ void tst_QFile::copyFallback()
QVERIFY(QFile::exists("file-copy-destination.txt"));
QVERIFY(!file.isOpen());
- file.close();
+ file.close();
QFile::setPermissions("file-copy-destination.txt",
QFile::ReadOwner | QFile::WriteOwner);
}
@@ -2242,7 +2249,7 @@ static QByteArray getLargeDataBlock()
if (array.isNull())
{
-#if defined(Q_OS_WINCE)
+#if defined(Q_OS_WINCE) || defined(Q_OS_VXWORKS)
int resizeSize = 1024 * 1024; // WinCE does not have much space
#else
int resizeSize = 64 * 1024 * 1024;
@@ -2432,7 +2439,9 @@ void tst_QFile::rename()
#if defined(Q_OS_UNIX)
if (strcmp(QTest::currentDataTag(), "renamefile -> /etc/renamefile") == 0) {
+#if !defined(Q_OS_VXWORKS)
if (::getuid() == 0)
+#endif
QSKIP("Running this test as root doesn't make sense");
}
#endif
@@ -2919,8 +2928,8 @@ void tst_QFile::map()
// exotic test to make sure that multiple maps work
// note: windows ce does not reference count mutliple maps
- // it's essentially just the same reference but it
- // cause a resource lock on the file which prevents it
+ // it's essentially just the same reference but it
+ // cause a resource lock on the file which prevents it
// from being removed uchar *memory1 = file.map(0, file.size());
uchar *memory1 = file.map(0, file.size());
QCOMPARE(file.error(), QFile::NoError);
@@ -2941,6 +2950,7 @@ void tst_QFile::map()
file.close();
+#if !defined(Q_OS_VXWORKS)
#if defined(Q_OS_UNIX)
if (::getuid() != 0)
// root always has permissions
@@ -2955,6 +2965,7 @@ void tst_QFile::map()
QVERIFY(!memory);
QVERIFY(file.setPermissions(originalPermissions));
}
+#endif
QVERIFY(file.remove());
}
@@ -3336,7 +3347,7 @@ void tst_QFile::autocloseHandle()
{
QFile file("readonlyfile");
QVERIFY(openFile(file, QIODevice::ReadOnly, OpenStream, QFile::DontCloseHandle));
- QCOMPARE(file.handle(), QT_FILENO(stream_));
+ QCOMPARE(file.handle(), int(QT_FILENO(stream_)));
file.close();
QCOMPARE(file.handle(), -1);
//file is not closed, read should succeed
diff --git a/tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp b/tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp
index ded77c649f..bcc971bf4b 100644
--- a/tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp
+++ b/tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp
@@ -46,6 +46,7 @@
#include <qcoreapplication.h>
#include <qlibrary.h>
#include <qtemporaryfile.h>
+#include <qtemporarydir.h>
#include <qdir.h>
#include <qfileinfo.h>
#ifdef Q_OS_UNIX
@@ -54,10 +55,11 @@
#include <unistd.h>
#include <sys/stat.h>
#include <sys/types.h>
+#ifndef Q_OS_VXWORKS
#include <pwd.h>
#endif
+#endif
#ifdef Q_OS_WIN
-#define _WIN32_WINNT 0x500
#include <qt_windows.h>
#include <qlibrary.h>
#if !defined(Q_OS_WINCE)
@@ -72,6 +74,10 @@
#include <private/qfileinfo_p.h>
#include "../../../../shared/filesystem.h"
+#if defined(Q_OS_VXWORKS)
+#define Q_NO_SYMLINKS
+#endif
+
QT_BEGIN_NAMESPACE
extern Q_AUTOTEST_EXPORT bool qIsLikelyToBeNfs(int /* handle */);
QT_END_NAMESPACE
@@ -80,7 +86,11 @@ class tst_QFileInfo : public QObject
{
Q_OBJECT
+public:
+ tst_QFileInfo() : m_currentDir(QDir::currentPath()) {}
+
private slots:
+ void initTestCase();
void cleanupTestCase();
void getSetCheck();
@@ -190,32 +200,27 @@ private slots:
void invalidState();
void nonExistingFileDates();
+
+private:
+ const QString m_currentDir;
+ QString m_sourceFile;
+ QString m_resourcesDir;
+ QTemporaryDir m_dir;
};
-void tst_QFileInfo::cleanupTestCase()
+void tst_QFileInfo::initTestCase()
{
- QFile::remove("brokenlink.lnk");
- QFile::remove("link.lnk");
- QFile::remove("file1");
- QFile::remove("dummyfile");
- QFile::remove("simplefile.txt");
- QFile::remove("longFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileNamelongFileName.txt");
- QFile::remove("tempfile.txt");
+ m_sourceFile = QFINDTESTDATA("tst_qfileinfo.cpp");
+ QVERIFY(!m_sourceFile.isEmpty());
+ m_resourcesDir = QFINDTESTDATA("resources");
+ QVERIFY(!m_resourcesDir.isEmpty());
+ QVERIFY(m_dir.isValid());
+ QVERIFY(QDir::setCurrent(m_dir.path()));
+}
-#if defined(Q_OS_UNIX)
- QDir().rmdir("./.hidden-directory");
- QFile::remove("link_to_tst_qfileinfo");
-#endif
-#if defined(Q_OS_WIN) && !defined(Q_OS_WINCE)
- QDir().rmdir("./hidden-directory");
- QDir().rmdir("abs_symlink");
- QDir().rmdir("rel_symlink");
- QDir().rmdir("junction_pwd");
- QDir().rmdir("junction_root");
- QDir().rmdir("mountpoint");
- QFile::remove("abs_symlink.cpp");
- QFile::remove("rel_symlink.cpp");
-#endif
+void tst_QFileInfo::cleanupTestCase()
+{
+ QDir::setCurrent(m_currentDir); // Release temporary directory so that it can be deleted on Windows
}
// Testing get/set functions
@@ -237,10 +242,9 @@ static QFileInfoPrivate* getPrivate(QFileInfo &info)
void tst_QFileInfo::copy()
{
- QTemporaryFile *t;
- t = new QTemporaryFile;
- t->open();
- QFileInfo info(t->fileName());
+ QTemporaryFile t;
+ t.open();
+ QFileInfo info(t.fileName());
QVERIFY(info.exists());
//copy constructor
@@ -287,7 +291,7 @@ void tst_QFileInfo::isFile_data()
QTest::addColumn<bool>("expected");
QTest::newRow("data0") << QDir::currentPath() << false;
- QTest::newRow("data1") << QFINDTESTDATA("tst_qfileinfo.cpp") << true;
+ QTest::newRow("data1") << m_sourceFile << true;
QTest::newRow("data2") << ":/tst_qfileinfo/resources/" << false;
QTest::newRow("data3") << ":/tst_qfileinfo/resources/file1" << true;
QTest::newRow("data4") << ":/tst_qfileinfo/resources/afilethatshouldnotexist" << false;
@@ -320,13 +324,13 @@ void tst_QFileInfo::isDir_data()
QTest::addColumn<bool>("expected");
QTest::newRow("data0") << QDir::currentPath() << true;
- QTest::newRow("data1") << QFINDTESTDATA("tst_qfileinfo.cpp") << false;
+ QTest::newRow("data1") << m_sourceFile << false;
QTest::newRow("data2") << ":/tst_qfileinfo/resources/" << true;
QTest::newRow("data3") << ":/tst_qfileinfo/resources/file1" << false;
QTest::newRow("data4") << ":/tst_qfileinfo/resources/afilethatshouldnotexist" << false;
- QTest::newRow("simple dir") << QFINDTESTDATA("resources") << true;
- QTest::newRow("simple dir with slash") << QFINDTESTDATA("resources/") << true;
+ QTest::newRow("simple dir") << m_resourcesDir << true;
+ QTest::newRow("simple dir with slash") << (m_resourcesDir + QLatin1Char('/')) << true;
QTest::newRow("broken link") << "brokenlink.lnk" << false;
@@ -366,8 +370,8 @@ void tst_QFileInfo::isRoot_data()
QTest::newRow("data4") << ":/tst_qfileinfo/resources/" << false;
QTest::newRow("data5") << ":/" << true;
- QTest::newRow("simple dir") << QFINDTESTDATA("resources") << false;
- QTest::newRow("simple dir with slash") << QFINDTESTDATA("resources/") << false;
+ QTest::newRow("simple dir") << m_resourcesDir << false;
+ QTest::newRow("simple dir with slash") << (m_resourcesDir + QLatin1Char('/')) << false;
#if (defined(Q_OS_WIN) && !defined(Q_OS_WINCE))
QTest::newRow("drive 1") << "c:" << false;
QTest::newRow("drive 2") << "c:/" << true;
@@ -398,21 +402,21 @@ void tst_QFileInfo::exists_data()
QTest::addColumn<bool>("expected");
QTest::newRow("data0") << QDir::currentPath() << true;
- QTest::newRow("data1") << QFINDTESTDATA("tst_qfileinfo.cpp") << true;
+ QTest::newRow("data1") << m_sourceFile << true;
QTest::newRow("data2") << "/I/do_not_expect_this_path_to_exist/" << false;
QTest::newRow("data3") << ":/tst_qfileinfo/resources/" << true;
QTest::newRow("data4") << ":/tst_qfileinfo/resources/file1" << true;
QTest::newRow("data5") << ":/I/do_not_expect_this_path_to_exist/" << false;
- QTest::newRow("data6") << (QFINDTESTDATA("resources/") + "*") << false;
- QTest::newRow("data7") << (QFINDTESTDATA("resources/") + "*.foo") << false;
- QTest::newRow("data8") << (QFINDTESTDATA("resources/") + "*.ext1") << false;
- QTest::newRow("data9") << (QFINDTESTDATA("resources/") + "file?.ext1") << false;
+ QTest::newRow("data6") << (m_resourcesDir + "/*") << false;
+ QTest::newRow("data7") << (m_resourcesDir + "/*.foo") << false;
+ QTest::newRow("data8") << (m_resourcesDir + "/*.ext1") << false;
+ QTest::newRow("data9") << (m_resourcesDir + "/file?.ext1") << false;
QTest::newRow("data10") << "." << true;
QTest::newRow("data11") << ". " << false;
QTest::newRow("empty") << "" << false;
- QTest::newRow("simple dir") << QFINDTESTDATA("resources") << true;
- QTest::newRow("simple dir with slash") << QFINDTESTDATA("resources/") << true;
+ QTest::newRow("simple dir") << m_resourcesDir << true;
+ QTest::newRow("simple dir with slash") << (m_resourcesDir + QLatin1Char('/')) << true;
#if defined(Q_OS_WIN) && !defined(Q_OS_WINCE)
QTest::newRow("unc 1") << "//" + QtNetworkSettings::winServerName() << true;
@@ -561,7 +565,7 @@ void tst_QFileInfo::canonicalFilePath()
// test symlinks
QFile::remove("link.lnk");
{
- QFile file(QFINDTESTDATA("tst_qfileinfo.cpp"));
+ QFile file(m_sourceFile);
if (file.link("link.lnk")) {
QFileInfo info1(file);
QFileInfo info2("link.lnk");
@@ -587,7 +591,7 @@ void tst_QFileInfo::canonicalFilePath()
QCOMPARE(info1.canonicalFilePath(), info2.canonicalFilePath());
QFileInfo info3(link + QDir::separator() + "link.lnk");
- QFileInfo info4(QFINDTESTDATA("tst_qfileinfo.cpp"));
+ QFileInfo info4(m_sourceFile);
QVERIFY(!info3.canonicalFilePath().isEmpty());
QCOMPARE(info4.canonicalFilePath(), info3.canonicalFilePath());
@@ -621,20 +625,21 @@ void tst_QFileInfo::canonicalFilePath()
// CreateSymbolicLink can return TRUE & still fail to create the link,
// the error code in that case is ERROR_PRIVILEGE_NOT_HELD (1314)
SetLastError(0);
- BOOL ret = ptrCreateSymbolicLink((wchar_t*)QString("res").utf16(), (wchar_t*)QString("resources").utf16(), 1);
+ const QString linkTarget = QStringLiteral("res");
+ BOOL ret = ptrCreateSymbolicLink((wchar_t*)linkTarget.utf16(), (wchar_t*)m_resourcesDir.utf16(), 1);
DWORD dwErr = GetLastError();
if (!ret)
QSKIP("Symbolic links aren't supported by FS");
QString currentPath = QDir::currentPath();
- bool is_res_Current = QDir::setCurrent("res");
+ bool is_res_Current = QDir::setCurrent(linkTarget);
if (!is_res_Current && dwErr == 1314)
QSKIP("Not enough privilages to create Symbolic links");
QCOMPARE(is_res_Current, true);
+ const QString actualCanonicalPath = QFileInfo("file1").canonicalFilePath();
+ QVERIFY(QDir::setCurrent(currentPath));
+ QCOMPARE(actualCanonicalPath, m_resourcesDir + QStringLiteral("/file1"));
- QCOMPARE(QFileInfo("file1").canonicalFilePath(), currentPath + "/resources/file1");
-
- QCOMPARE(QDir::setCurrent(currentPath), true);
- QDir::current().rmdir("res");
+ QDir::current().rmdir(linkTarget);
}
#endif
}
@@ -855,7 +860,7 @@ void tst_QFileInfo::permission_data()
QTest::addColumn<bool>("expected");
QTest::newRow("data0") << QCoreApplication::instance()->applicationFilePath() << int(QFile::ExeUser) << true;
- QTest::newRow("data1") << QFINDTESTDATA("tst_qfileinfo.cpp") << int(QFile::ReadUser) << true;
+ QTest::newRow("data1") << m_sourceFile << int(QFile::ReadUser) << true;
QTest::newRow("resource1") << ":/tst_qfileinfo/resources/file1.ext1" << int(QFile::ReadUser) << true;
QTest::newRow("resource2") << ":/tst_qfileinfo/resources/file1.ext1" << int(QFile::WriteUser) << false;
QTest::newRow("resource3") << ":/tst_qfileinfo/resources/file1.ext1" << int(QFile::ExeUser) << false;
@@ -921,13 +926,15 @@ void tst_QFileInfo::compare_data()
if (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_6)
caseSensitiveOnMac = false;
#endif
+ QString caseChangedSource = m_sourceFile;
+ caseChangedSource.replace("info", "Info");
QTest::newRow("data0")
- << QFINDTESTDATA("tst_qfileinfo.cpp")
- << QFINDTESTDATA("tst_qfileinfo.cpp")
+ << m_sourceFile
+ << m_sourceFile
<< true;
QTest::newRow("data1")
- << QFINDTESTDATA("tst_qfileinfo.cpp")
+ << m_sourceFile
<< QString::fromLatin1("/tst_qfileinfo.cpp")
<< false;
QTest::newRow("data2")
@@ -935,8 +942,8 @@ void tst_QFileInfo::compare_data()
<< QDir::currentPath() + QString::fromLatin1("/tst_qfileinfo.cpp")
<< true;
QTest::newRow("casesense1")
- << QFINDTESTDATA("tst_qfileinfo.cpp").replace("info", "Info")
- << QFINDTESTDATA("tst_qfileinfo.cpp")
+ << caseChangedSource
+ << m_sourceFile
#if defined(Q_OS_WIN)
<< true;
#elif defined(Q_OS_MAC)
@@ -1013,7 +1020,7 @@ void tst_QFileInfo::fileTimes()
QEXPECT_FAIL("longfile absolutepath", "No long filenames on WinCE", Abort);
#endif
QVERIFY(file.open(QFile::WriteOnly | QFile::Text));
-#ifdef Q_OS_UNIX
+#if defined(Q_OS_UNIX) && !defined(Q_OS_VXWORKS)
if (qIsLikelyToBeNfs(file.handle()))
QSKIP("This Test doesn't work on NFS");
#endif
@@ -1140,7 +1147,7 @@ void tst_QFileInfo::isSymLink_data()
QFile::remove("brokenlink.lnk");
QFile::remove("dummyfile");
- QFile file1(QFINDTESTDATA("tst_qfileinfo.cpp"));
+ QFile file1(m_sourceFile);
QVERIFY(file1.link("link.lnk"));
QFile file2("dummyfile");
@@ -1152,8 +1159,8 @@ void tst_QFileInfo::isSymLink_data()
QTest::addColumn<bool>("isSymLink");
QTest::addColumn<QString>("linkTarget");
- QTest::newRow("existent file") << QFINDTESTDATA("tst_qfileinfo.cpp") << false << "";
- QTest::newRow("link") << "link.lnk" << true << QFileInfo(QFINDTESTDATA("tst_qfileinfo.cpp")).absoluteFilePath();
+ QTest::newRow("existent file") << m_sourceFile << false << "";
+ QTest::newRow("link") << "link.lnk" << true << QFileInfo(m_sourceFile).absoluteFilePath();
QTest::newRow("broken link") << "brokenlink.lnk" << true << QFileInfo("dummyfile").absoluteFilePath();
}
@@ -1390,7 +1397,7 @@ void tst_QFileInfo::ntfsJunctionPointsAndSymlinks_data()
}
{
//File symlinks
- QFileInfo target(QFINDTESTDATA("tst_qfileinfo.cpp"));
+ QFileInfo target(m_sourceFile);
QString absTarget = QDir::toNativeSeparators(target.absoluteFilePath());
QString absSymlink = QDir::toNativeSeparators(pwd.absolutePath()).append("\\abs_symlink.cpp");
QString relTarget = QDir::toNativeSeparators(pwd.relativeFilePath(target.absoluteFilePath()));
@@ -1447,10 +1454,22 @@ void tst_QFileInfo::ntfsJunctionPointsAndSymlinks()
QFETCH(QString, canonicalFilePath);
QFileInfo fi(path);
- QCOMPARE(fi.isSymLink(), isSymLink);
+ const bool actualIsSymLink = fi.isSymLink();
+ const QString actualSymLinkTarget = isSymLink ? fi.symLinkTarget() : QString();
+ const QString actualCanonicalFilePath = isSymLink ? fi.canonicalFilePath() : QString();
+ // Ensure that junctions, mountpoints are removed. If this fails, do not remove
+ // temporary directory to prevent it from trashing the system.
+ if (fi.isDir()) {
+ if (!QDir().rmdir(fi.fileName())) {
+ qWarning("Unable to remove NTFS junction '%s'', keeping '%s'.",
+ qPrintable(fi.fileName()), qPrintable(QDir::toNativeSeparators(m_dir.path())));
+ m_dir.setAutoRemove(false);
+ }
+ }
+ QCOMPARE(actualIsSymLink, isSymLink);
if (isSymLink) {
- QCOMPARE(fi.symLinkTarget(), linkTarget);
- QCOMPARE(fi.canonicalFilePath(), canonicalFilePath);
+ QCOMPARE(actualSymLinkTarget, linkTarget);
+ QCOMPARE(actualCanonicalFilePath, canonicalFilePath);
}
}
@@ -1499,7 +1518,7 @@ void tst_QFileInfo::isWritable()
#if defined (Q_OS_BLACKBERRY)
// The Blackberry filesystem is read-only
QVERIFY(!QFileInfo("/etc/passwd").isWritable());
-#elif defined (Q_OS_UNIX)
+#elif defined (Q_OS_UNIX) && !defined(Q_OS_VXWORKS) // VxWorks does not have users/groups
if (::getuid() == 0)
QVERIFY(QFileInfo("/etc/passwd").isWritable());
else
@@ -1698,7 +1717,7 @@ QT_END_NAMESPACE
void tst_QFileInfo::owner()
{
QString userName;
-#if defined(Q_OS_UNIX)
+#if defined(Q_OS_UNIX) && !defined(Q_OS_VXWORKS)
{
passwd *user = getpwuid(geteuid());
QVERIFY(user);
@@ -1761,7 +1780,7 @@ void tst_QFileInfo::owner()
void tst_QFileInfo::group()
{
QString expected;
-#if defined(Q_OS_UNIX)
+#if defined(Q_OS_UNIX) && !defined(Q_OS_VXWORKS)
struct group *gr;
gid_t gid = getegid();
diff --git a/tests/auto/corelib/io/qlockfile/qlockfile.pro b/tests/auto/corelib/io/qlockfile/qlockfile.pro
new file mode 100644
index 0000000000..91f104305c
--- /dev/null
+++ b/tests/auto/corelib/io/qlockfile/qlockfile.pro
@@ -0,0 +1,3 @@
+TEMPLATE = subdirs
+
+SUBDIRS += tst_qlockfile.pro qlockfiletesthelper/qlockfile_test_helper.pro
diff --git a/tests/auto/corelib/io/qlockfile/qlockfiletesthelper/qlockfile_test_helper.cpp b/tests/auto/corelib/io/qlockfile/qlockfiletesthelper/qlockfile_test_helper.cpp
new file mode 100644
index 0000000000..63f6291034
--- /dev/null
+++ b/tests/auto/corelib/io/qlockfile/qlockfiletesthelper/qlockfile_test_helper.cpp
@@ -0,0 +1,78 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 David Faure <faure+bluesystems@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QDebug>
+#include <QCoreApplication>
+#include <QLockFile>
+#include <QThread>
+
+int main(int argc, char *argv[])
+{
+ QCoreApplication app(argc, argv);
+
+ if (argc <= 1)
+ return -1;
+
+ const QString lockName = QString::fromLocal8Bit(argv[1]);
+
+ QString option;
+ if (argc > 2)
+ option = QString::fromLocal8Bit(argv[2]);
+
+ if (option == "-crash") {
+ QLockFile *lockFile = new QLockFile(lockName);
+ lockFile->lock();
+ // leak the lockFile on purpose, so that the lock remains!
+ return 0;
+ } else if (option == "-busy") {
+ QLockFile lockFile(lockName);
+ lockFile.lock();
+ QThread::msleep(500);
+ return 0;
+ } else {
+ QLockFile lockFile(lockName);
+ if (lockFile.isLocked()) // cannot happen, before calling lock or tryLock
+ return QLockFile::UnknownError;
+
+ lockFile.tryLock();
+ return lockFile.error();
+ }
+}
diff --git a/tests/auto/corelib/io/qlockfile/qlockfiletesthelper/qlockfile_test_helper.pro b/tests/auto/corelib/io/qlockfile/qlockfiletesthelper/qlockfile_test_helper.pro
new file mode 100644
index 0000000000..3ac3be9c9b
--- /dev/null
+++ b/tests/auto/corelib/io/qlockfile/qlockfiletesthelper/qlockfile_test_helper.pro
@@ -0,0 +1,7 @@
+TARGET = qlockfile_test_helper
+SOURCES += qlockfile_test_helper.cpp
+
+CONFIG += console
+CONFIG -= app_bundle
+QT = core
+DESTDIR = ./
diff --git a/tests/auto/corelib/io/qlockfile/tst_qlockfile.cpp b/tests/auto/corelib/io/qlockfile/tst_qlockfile.cpp
new file mode 100644
index 0000000000..c0bf77cfb2
--- /dev/null
+++ b/tests/auto/corelib/io/qlockfile/tst_qlockfile.cpp
@@ -0,0 +1,379 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 David Faure <faure+bluesystems@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+#include <QtTest/QtTest>
+#include <QtConcurrentRun>
+#include <qlockfile.h>
+#include <qtemporarydir.h>
+
+class tst_QLockFile : public QObject
+{
+ Q_OBJECT
+
+private slots:
+ void initTestCase();
+ void lockUnlock();
+ void lockOutOtherProcess();
+ void lockOutOtherThread();
+ void waitForLock_data();
+ void waitForLock();
+ void staleLockFromCrashedProcess_data();
+ void staleLockFromCrashedProcess();
+ void staleShortLockFromBusyProcess();
+ void staleLongLockFromBusyProcess();
+ void staleLockRace();
+ void noPermissions();
+
+public:
+ QString m_helperApp;
+ QTemporaryDir dir;
+};
+
+void tst_QLockFile::initTestCase()
+{
+#ifdef QT_NO_PROCESS
+ QSKIP("This test requires QProcess support");
+#else
+ // chdir to our testdata path and execute helper apps relative to that.
+ QString testdata_dir = QFileInfo(QFINDTESTDATA("qlockfiletesthelper")).absolutePath();
+ QVERIFY2(QDir::setCurrent(testdata_dir), qPrintable("Could not chdir to " + testdata_dir));
+ m_helperApp = "qlockfiletesthelper/qlockfile_test_helper";
+#endif
+}
+
+void tst_QLockFile::lockUnlock()
+{
+ const QString fileName = dir.path() + "/lock1";
+ QVERIFY(!QFile(fileName).exists());
+ QLockFile lockFile(fileName);
+ QVERIFY(lockFile.lock());
+ QVERIFY(lockFile.isLocked());
+ QCOMPARE(int(lockFile.error()), int(QLockFile::NoError));
+ QVERIFY(QFile::exists(fileName));
+
+ // Recursive locking is not allowed
+ // (can't test lock() here, it would wait forever)
+ QVERIFY(!lockFile.tryLock());
+ QCOMPARE(int(lockFile.error()), int(QLockFile::LockFailedError));
+ qint64 pid;
+ QString hostname, appname;
+ QVERIFY(lockFile.getLockInfo(&pid, &hostname, &appname));
+ QCOMPARE(pid, QCoreApplication::applicationPid());
+ QCOMPARE(appname, qAppName());
+ QVERIFY(!lockFile.tryLock(200));
+ QCOMPARE(int(lockFile.error()), int(QLockFile::LockFailedError));
+
+ // Unlock deletes the lock file
+ lockFile.unlock();
+ QCOMPARE(int(lockFile.error()), int(QLockFile::NoError));
+ QVERIFY(!lockFile.isLocked());
+ QVERIFY(!QFile::exists(fileName));
+}
+
+void tst_QLockFile::lockOutOtherProcess()
+{
+ // Lock
+ const QString fileName = dir.path() + "/lockOtherProcess";
+ QLockFile lockFile(fileName);
+ QVERIFY(lockFile.lock());
+
+ // Other process can't acquire lock
+ QProcess proc;
+ proc.start(m_helperApp, QStringList() << fileName);
+ QVERIFY2(proc.waitForStarted(), qPrintable(proc.errorString()));
+ QVERIFY(proc.waitForFinished());
+ QCOMPARE(proc.exitCode(), int(QLockFile::LockFailedError));
+
+ // Unlock
+ lockFile.unlock();
+ QVERIFY(!QFile::exists(fileName));
+
+ // Other process can now acquire lock
+ int ret = QProcess::execute(m_helperApp, QStringList() << fileName);
+ QCOMPARE(ret, int(QLockFile::NoError));
+ // Lock doesn't survive process though (on clean exit)
+ QVERIFY(!QFile::exists(fileName));
+}
+
+static QLockFile::LockError tryLockFromThread(const QString &fileName)
+{
+ QLockFile lockInThread(fileName);
+ lockInThread.tryLock();
+ return lockInThread.error();
+}
+
+void tst_QLockFile::lockOutOtherThread()
+{
+ const QString fileName = dir.path() + "/lockOtherThread";
+ QLockFile lockFile(fileName);
+ QVERIFY(lockFile.lock());
+
+ // Other thread can't acquire lock
+ QFuture<QLockFile::LockError> ret = QtConcurrent::run<QLockFile::LockError>(tryLockFromThread, fileName);
+ QCOMPARE(ret.result(), QLockFile::LockFailedError);
+
+ lockFile.unlock();
+
+ // Now other thread can acquire lock
+ QFuture<QLockFile::LockError> ret2 = QtConcurrent::run<QLockFile::LockError>(tryLockFromThread, fileName);
+ QCOMPARE(ret2.result(), QLockFile::NoError);
+}
+
+static bool lockFromThread(const QString &fileName, int sleepMs, QSemaphore *semThreadReady, QSemaphore *semMainThreadDone)
+{
+ QLockFile lockFile(fileName);
+ if (!lockFile.lock()) {
+ qWarning() << "Locking failed" << lockFile.error();
+ return false;
+ }
+ semThreadReady->release();
+ QThread::msleep(sleepMs);
+ semMainThreadDone->acquire();
+ lockFile.unlock();
+ return true;
+}
+
+void tst_QLockFile::waitForLock_data()
+{
+ QTest::addColumn<int>("testNumber");
+ QTest::addColumn<int>("threadSleepMs");
+ QTest::addColumn<bool>("releaseEarly");
+ QTest::addColumn<int>("tryLockTimeout");
+ QTest::addColumn<bool>("expectedResult");
+
+ int tn = 0; // test number
+ QTest::newRow("wait_forever_succeeds") << ++tn << 500 << true << -1 << true;
+ QTest::newRow("wait_longer_succeeds") << ++tn << 500 << true << 1000 << true;
+ QTest::newRow("wait_zero_fails") << ++tn << 500 << false << 0 << false;
+ QTest::newRow("wait_not_enough_fails") << ++tn << 500 << false << 100 << false;
+}
+
+void tst_QLockFile::waitForLock()
+{
+ QFETCH(int, testNumber);
+ QFETCH(int, threadSleepMs);
+ QFETCH(bool, releaseEarly);
+ QFETCH(int, tryLockTimeout);
+ QFETCH(bool, expectedResult);
+
+ const QString fileName = dir.path() + "/waitForLock" + QString::number(testNumber);
+ QLockFile lockFile(fileName);
+ QSemaphore semThreadReady, semMainThreadDone;
+ // Lock file from a thread
+ QFuture<bool> ret = QtConcurrent::run<bool>(lockFromThread, fileName, threadSleepMs, &semThreadReady, &semMainThreadDone);
+ semThreadReady.acquire();
+
+ if (releaseEarly) // let the thread release the lock after threadSleepMs
+ semMainThreadDone.release();
+
+ QCOMPARE(lockFile.tryLock(tryLockTimeout), expectedResult);
+ if (expectedResult)
+ QCOMPARE(int(lockFile.error()), int(QLockFile::NoError));
+ else
+ QCOMPARE(int(lockFile.error()), int(QLockFile::LockFailedError));
+
+ if (!releaseEarly) // only let the thread release the lock now
+ semMainThreadDone.release();
+
+ QVERIFY(ret); // waits for the thread to finish
+}
+
+void tst_QLockFile::staleLockFromCrashedProcess_data()
+{
+ QTest::addColumn<int>("staleLockTime");
+
+ // Test both use cases for QLockFile, should make no difference here.
+ QTest::newRow("short") << 30000;
+ QTest::newRow("long") << 0;
+}
+
+void tst_QLockFile::staleLockFromCrashedProcess()
+{
+ QFETCH(int, staleLockTime);
+ const QString fileName = dir.path() + "/staleLockFromCrashedProcess";
+
+ int ret = QProcess::execute(m_helperApp, QStringList() << fileName << "-crash");
+ QCOMPARE(ret, int(QLockFile::NoError));
+ QTRY_VERIFY(QFile::exists(fileName));
+
+ QLockFile secondLock(fileName);
+ secondLock.setStaleLockTime(staleLockTime);
+ // tryLock detects and removes the stale lock (since the PID is dead)
+#ifdef Q_OS_WIN
+ // It can take a bit of time on Windows, though.
+ QVERIFY(secondLock.tryLock(30000));
+#else
+ QVERIFY(secondLock.tryLock());
+#endif
+ QCOMPARE(int(secondLock.error()), int(QLockFile::NoError));
+}
+
+void tst_QLockFile::staleShortLockFromBusyProcess()
+{
+ const QString fileName = dir.path() + "/staleLockFromBusyProcess";
+
+ QProcess proc;
+ proc.start(m_helperApp, QStringList() << fileName << "-busy");
+ QVERIFY2(proc.waitForStarted(), qPrintable(proc.errorString()));
+ QTRY_VERIFY(QFile::exists(fileName));
+
+ QLockFile secondLock(fileName);
+ QVERIFY(!secondLock.tryLock()); // held by other process
+ QCOMPARE(int(secondLock.error()), int(QLockFile::LockFailedError));
+ qint64 pid;
+ QString hostname, appname;
+ QTRY_VERIFY(secondLock.getLockInfo(&pid, &hostname, &appname));
+#ifdef Q_OS_UNIX
+ QCOMPARE(pid, proc.pid());
+#endif
+
+ secondLock.setStaleLockTime(100);
+ QTest::qSleep(100); // make the lock stale
+ // We can't "steal" (delete+recreate) a lock file from a running process
+ // until the file descriptor is closed.
+ QVERIFY(!secondLock.tryLock());
+
+ proc.waitForFinished();
+ QVERIFY(secondLock.tryLock());
+}
+
+void tst_QLockFile::staleLongLockFromBusyProcess()
+{
+ const QString fileName = dir.path() + "/staleLockFromBusyProcess";
+
+ QProcess proc;
+ proc.start(m_helperApp, QStringList() << fileName << "-busy");
+ QVERIFY2(proc.waitForStarted(), qPrintable(proc.errorString()));
+ QTRY_VERIFY(QFile::exists(fileName));
+
+ QLockFile secondLock(fileName);
+ secondLock.setStaleLockTime(0);
+ QVERIFY(!secondLock.tryLock(100)); // never stale
+ QCOMPARE(int(secondLock.error()), int(QLockFile::LockFailedError));
+ qint64 pid;
+ QTRY_VERIFY(secondLock.getLockInfo(&pid, NULL, NULL));
+ QVERIFY(pid > 0);
+
+ // As long as the other process is running, we can't remove the lock file
+ QVERIFY(!secondLock.removeStaleLockFile());
+
+ proc.waitForFinished();
+}
+
+static QString tryStaleLockFromThread(const QString &fileName)
+{
+ QLockFile lockInThread(fileName + ".lock");
+ lockInThread.setStaleLockTime(1000);
+ if (!lockInThread.lock())
+ return "Error locking: " + QString::number(lockInThread.error());
+
+ // The concurrent use of the file below (write, read, delete) is protected by the lock file above.
+ // (provided that it doesn't become stale due to this operation taking too long)
+ QFile theFile(fileName);
+ if (!theFile.open(QIODevice::WriteOnly))
+ return "Couldn't open for write";
+ theFile.write("Hello world");
+ theFile.flush();
+ theFile.close();
+ QFile reader(fileName);
+ if (!reader.open(QIODevice::ReadOnly))
+ return "Couldn't open for read";
+ const QByteArray read = reader.readAll();
+ if (read != "Hello world")
+ return "File didn't have the expected contents:" + read;
+ reader.remove();
+ return QString();
+}
+
+void tst_QLockFile::staleLockRace()
+{
+ // Multiple threads notice a stale lock at the same time
+ // Only one thread should delete it, otherwise a race will ensue
+ const QString fileName = dir.path() + "/sharedFile";
+ const QString lockName = fileName + ".lock";
+ int ret = QProcess::execute(m_helperApp, QStringList() << lockName << "-crash");
+ QCOMPARE(ret, int(QLockFile::NoError));
+ QTRY_VERIFY(QFile::exists(lockName));
+
+ QThreadPool::globalInstance()->setMaxThreadCount(10);
+ QFutureSynchronizer<QString> synchronizer;
+ for (int i = 0; i < 8; ++i)
+ synchronizer.addFuture(QtConcurrent::run<QString>(tryStaleLockFromThread, fileName));
+ synchronizer.waitForFinished();
+ foreach (const QFuture<QString> &future, synchronizer.futures())
+ QVERIFY2(future.result().isEmpty(), qPrintable(future.result()));
+}
+
+void tst_QLockFile::noPermissions()
+{
+#ifdef Q_OS_WIN
+ // A readonly directory still allows us to create files, on Windows.
+ QSKIP("No permission testing on Windows");
+#endif
+ // Restore permissions so that the QTemporaryDir cleanup can happen
+ class PermissionRestorer
+ {
+ QString m_path;
+ public:
+ PermissionRestorer(const QString& path)
+ : m_path(path)
+ {}
+
+ ~PermissionRestorer()
+ {
+ QFile file(m_path);
+ file.setPermissions(QFile::Permissions(QFile::ReadOwner | QFile::WriteOwner | QFile::ExeOwner));
+ }
+ };
+
+ const QString fileName = dir.path() + "/staleLock";
+ QFile dirAsFile(dir.path()); // I have to use QFile to change a dir's permissions...
+ QVERIFY2(dirAsFile.setPermissions(QFile::Permissions(0)), qPrintable(dir.path())); // no permissions
+ PermissionRestorer permissionRestorer(dir.path());
+
+ QLockFile lockFile(fileName);
+ QVERIFY(!lockFile.lock());
+ QCOMPARE(int(lockFile.error()), int(QLockFile::PermissionError));
+}
+
+QTEST_MAIN(tst_QLockFile)
+#include "tst_qlockfile.moc"
diff --git a/tests/auto/corelib/io/qlockfile/tst_qlockfile.pro b/tests/auto/corelib/io/qlockfile/tst_qlockfile.pro
new file mode 100644
index 0000000000..2f7009b736
--- /dev/null
+++ b/tests/auto/corelib/io/qlockfile/tst_qlockfile.pro
@@ -0,0 +1,6 @@
+CONFIG += testcase
+CONFIG -= app_bundle
+TARGET = tst_qlockfile
+SOURCES += tst_qlockfile.cpp
+
+QT = core testlib concurrent
diff --git a/tests/auto/corelib/io/qprocess/testForwarding/testForwarding.pro b/tests/auto/corelib/io/qprocess/testForwarding/testForwarding.pro
index 271c7ead13..45b498c32a 100644
--- a/tests/auto/corelib/io/qprocess/testForwarding/testForwarding.pro
+++ b/tests/auto/corelib/io/qprocess/testForwarding/testForwarding.pro
@@ -2,3 +2,4 @@ SOURCES = main.cpp
CONFIG -= app_bundle
CONFIG += console
DESTDIR = ./
+QT = core
diff --git a/tests/auto/corelib/io/qprocess/testProcessEchoGui/main_win.cpp b/tests/auto/corelib/io/qprocess/testProcessEchoGui/main_win.cpp
index 270666deb6..df96e1cbf3 100644
--- a/tests/auto/corelib/io/qprocess/testProcessEchoGui/main_win.cpp
+++ b/tests/auto/corelib/io/qprocess/testProcessEchoGui/main_win.cpp
@@ -50,8 +50,8 @@ int APIENTRY WinMain(HINSTANCE /* hInstance */,
HANDLE hStdin = GetStdHandle(STD_INPUT_HANDLE);
HANDLE hStdout = GetStdHandle(STD_OUTPUT_HANDLE);
-
- HANDLE hStderr = GetStdHandle(STD_ERROR_HANDLE);
+
+ HANDLE hStderr = GetStdHandle(STD_ERROR_HANDLE);
for (;;) {
diff --git a/tests/auto/corelib/io/qprocess/testProcessNormal/testProcessNormal.pro b/tests/auto/corelib/io/qprocess/testProcessNormal/testProcessNormal.pro
index f7c57abc37..f7bb0985a3 100644
--- a/tests/auto/corelib/io/qprocess/testProcessNormal/testProcessNormal.pro
+++ b/tests/auto/corelib/io/qprocess/testProcessNormal/testProcessNormal.pro
@@ -4,3 +4,4 @@ CONFIG -= qt app_bundle
DESTDIR = ./
DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
+QT = core
diff --git a/tests/auto/corelib/io/qprocess/testProcessOutput/testProcessOutput.pro b/tests/auto/corelib/io/qprocess/testProcessOutput/testProcessOutput.pro
index 3940ddbf98..2de4534896 100644
--- a/tests/auto/corelib/io/qprocess/testProcessOutput/testProcessOutput.pro
+++ b/tests/auto/corelib/io/qprocess/testProcessOutput/testProcessOutput.pro
@@ -3,3 +3,4 @@ CONFIG -= qt app_bundle
CONFIG += console
DESTDIR = ./
DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
+QT = core
diff --git a/tests/auto/corelib/io/qprocess/testProcessSpacesArgs/twospaces.pro b/tests/auto/corelib/io/qprocess/testProcessSpacesArgs/twospaces.pro
index 43db95e675..8b16f65e34 100644
--- a/tests/auto/corelib/io/qprocess/testProcessSpacesArgs/twospaces.pro
+++ b/tests/auto/corelib/io/qprocess/testProcessSpacesArgs/twospaces.pro
@@ -6,3 +6,4 @@ OBJECTS_DIR = $${OBJECTS_DIR}-twospaces
TARGET = "two space s"
DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
+QT = core
diff --git a/tests/auto/corelib/io/qprocess/testSetWorkingDirectory/testSetWorkingDirectory.pro b/tests/auto/corelib/io/qprocess/testSetWorkingDirectory/testSetWorkingDirectory.pro
index 86d26c2c4a..d425d5569e 100644
--- a/tests/auto/corelib/io/qprocess/testSetWorkingDirectory/testSetWorkingDirectory.pro
+++ b/tests/auto/corelib/io/qprocess/testSetWorkingDirectory/testSetWorkingDirectory.pro
@@ -3,3 +3,4 @@ CONFIG += console
CONFIG -= app_bundle
DESTDIR = ./
DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
+QT = core
diff --git a/tests/auto/corelib/io/qprocess/testSoftExit/main_unix.cpp b/tests/auto/corelib/io/qprocess/testSoftExit/main_unix.cpp
index 02cc31168b..c7f5f88f9c 100644
--- a/tests/auto/corelib/io/qprocess/testSoftExit/main_unix.cpp
+++ b/tests/auto/corelib/io/qprocess/testSoftExit/main_unix.cpp
@@ -55,7 +55,7 @@ int main()
printf("Ready\n");
fflush(stdout);
-
+
for (int i = 0; i < 5; ++i)
sleep(1);
return 0;
diff --git a/tests/auto/corelib/io/qprocess/testSoftExit/main_win.cpp b/tests/auto/corelib/io/qprocess/testSoftExit/main_win.cpp
index bed8d921b3..e478a18bd6 100644
--- a/tests/auto/corelib/io/qprocess/testSoftExit/main_win.cpp
+++ b/tests/auto/corelib/io/qprocess/testSoftExit/main_win.cpp
@@ -53,6 +53,6 @@ int main()
if (msg.message == WM_CLOSE)
PostQuitMessage(0);
}
-
+
return int(msg.wParam);
}
diff --git a/tests/auto/corelib/io/qprocess/testSoftExit/testSoftExit.pro b/tests/auto/corelib/io/qprocess/testSoftExit/testSoftExit.pro
index c5fb286d0c..7f3b8ade3e 100644
--- a/tests/auto/corelib/io/qprocess/testSoftExit/testSoftExit.pro
+++ b/tests/auto/corelib/io/qprocess/testSoftExit/testSoftExit.pro
@@ -10,3 +10,4 @@ CONFIG -= qt app_bundle
CONFIG += console
DESTDIR = ./
DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
+QT = core
diff --git a/tests/auto/corelib/io/qprocess/testSpaceInName/testSpaceInName.pro b/tests/auto/corelib/io/qprocess/testSpaceInName/testSpaceInName.pro
index d0848e3303..b7213ae507 100644
--- a/tests/auto/corelib/io/qprocess/testSpaceInName/testSpaceInName.pro
+++ b/tests/auto/corelib/io/qprocess/testSpaceInName/testSpaceInName.pro
@@ -7,3 +7,4 @@ mac {
CONFIG -= app_bundle
}
DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
+QT = core
diff --git a/tests/auto/corelib/io/qprocess/tst_qprocess.cpp b/tests/auto/corelib/io/qprocess/tst_qprocess.cpp
index 7965d1d431..f01e319872 100644
--- a/tests/auto/corelib/io/qprocess/tst_qprocess.cpp
+++ b/tests/auto/corelib/io/qprocess/tst_qprocess.cpp
@@ -81,6 +81,7 @@ private slots:
void getSetCheck();
void constructing();
void simpleStart();
+ void startWithOpen();
void execute();
void startDetached();
void crashTest();
@@ -283,6 +284,25 @@ void tst_QProcess::simpleStart()
QCOMPARE(qvariant_cast<QProcess::ProcessState>(spy.at(1).at(0)), QProcess::Running);
QCOMPARE(qvariant_cast<QProcess::ProcessState>(spy.at(2).at(0)), QProcess::NotRunning);
}
+
+//-----------------------------------------------------------------------------
+void tst_QProcess::startWithOpen()
+{
+ QProcess p;
+ QTest::ignoreMessage(QtWarningMsg, "QProcess::start: program not set");
+ QCOMPARE(p.open(QIODevice::ReadOnly), false);
+
+ p.setProgram("testProcessNormal/testProcessNormal");
+ QCOMPARE(p.program(), QString("testProcessNormal/testProcessNormal"));
+
+ p.setArguments(QStringList() << "arg1" << "arg2");
+ QCOMPARE(p.arguments().size(), 2);
+
+ QVERIFY(p.open(QIODevice::ReadOnly));
+ QCOMPARE(p.openMode(), QIODevice::ReadOnly);
+ QVERIFY(p.waitForFinished(5000));
+}
+
//-----------------------------------------------------------------------------
void tst_QProcess::execute()
{
@@ -1256,7 +1276,6 @@ void tst_QProcess::waitForBytesWrittenInABytesWrittenSlot()
process->start("testProcessEcho/testProcessEcho");
QVERIFY(process->waitForStarted(5000));
- qRegisterMetaType<qint64>("qint64");
QSignalSpy spy(process, SIGNAL(bytesWritten(qint64)));
QVERIFY(spy.isValid());
process->write("f");
diff --git a/tests/auto/corelib/io/qresourceengine/tst_qresourceengine.cpp b/tests/auto/corelib/io/qresourceengine/tst_qresourceengine.cpp
index 11dbc1e9c1..515a10426c 100644
--- a/tests/auto/corelib/io/qresourceengine/tst_qresourceengine.cpp
+++ b/tests/auto/corelib/io/qresourceengine/tst_qresourceengine.cpp
@@ -402,7 +402,7 @@ void tst_QResourceEngine::checkUnregisterResource_data()
QTest::addColumn<int>("size");
QTest::newRow("currentdir.txt") << QFINDTESTDATA("runtime_resource.rcc") << QString("/check_unregister/")
- << QString(":/check_unregister/runtime_resource/test/abc/123/+++/currentdir.txt")
+ << QString(":/check_unregister/runtime_resource/test/abc/123/+++/currentdir.txt")
<< (int)QFileInfo(QFINDTESTDATA("testqrc/currentdir.txt")).size();
}
diff --git a/tests/auto/corelib/io/qsavefile/qsavefile.pro b/tests/auto/corelib/io/qsavefile/qsavefile.pro
new file mode 100644
index 0000000000..36db000fa7
--- /dev/null
+++ b/tests/auto/corelib/io/qsavefile/qsavefile.pro
@@ -0,0 +1,5 @@
+CONFIG += testcase parallel_test
+TARGET = tst_qsavefile
+QT = core testlib
+SOURCES = tst_qsavefile.cpp
+TESTDATA += tst_qsavefile.cpp
diff --git a/tests/auto/corelib/io/qsavefile/tst_qsavefile.cpp b/tests/auto/corelib/io/qsavefile/tst_qsavefile.cpp
new file mode 100644
index 0000000000..d9292b8460
--- /dev/null
+++ b/tests/auto/corelib/io/qsavefile/tst_qsavefile.cpp
@@ -0,0 +1,339 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 David Faure <faure@kde.org>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtCore module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtTest/QtTest>
+#include <qcoreapplication.h>
+#include <qstring.h>
+#include <qtemporaryfile.h>
+#include <qfile.h>
+#include <qdir.h>
+#include <qset.h>
+
+#if defined(Q_OS_UNIX)
+# include <unistd.h> // for geteuid
+# include <sys/types.h>
+#endif
+
+#if defined(Q_OS_WIN)
+# include <windows.h>
+#endif
+
+class tst_QSaveFile : public QObject
+{
+ Q_OBJECT
+public slots:
+
+private slots:
+ void transactionalWrite();
+ void textStreamManualFlush();
+ void textStreamAutoFlush();
+ void saveTwice();
+ void transactionalWriteNoPermissionsOnDir_data();
+ void transactionalWriteNoPermissionsOnDir();
+ void transactionalWriteNoPermissionsOnFile();
+ void transactionalWriteCanceled();
+ void transactionalWriteErrorRenaming();
+};
+
+void tst_QSaveFile::transactionalWrite()
+{
+ QTemporaryDir dir;
+ const QString targetFile = dir.path() + QString::fromLatin1("/outfile");
+ QFile::remove(targetFile);
+ QSaveFile file(targetFile);
+ QVERIFY(file.open(QIODevice::WriteOnly));
+ QVERIFY(file.isOpen());
+ QCOMPARE(file.fileName(), targetFile);
+ QVERIFY(!QFile::exists(targetFile));
+
+ QCOMPARE(file.write("Hello"), Q_INT64_C(5));
+ QCOMPARE(file.error(), QFile::NoError);
+ QVERIFY(!QFile::exists(targetFile));
+
+ QVERIFY(file.commit());
+ QVERIFY(QFile::exists(targetFile));
+ QCOMPARE(file.fileName(), targetFile);
+
+ QFile reader(targetFile);
+ QVERIFY(reader.open(QIODevice::ReadOnly));
+ QCOMPARE(QString::fromLatin1(reader.readAll()), QString::fromLatin1("Hello"));
+}
+
+void tst_QSaveFile::saveTwice()
+{
+ // Check that we can reuse a QSaveFile object
+ // (and test the case of an existing target file)
+ QTemporaryDir dir;
+ const QString targetFile = dir.path() + QString::fromLatin1("/outfile");
+ QSaveFile file(targetFile);
+ QVERIFY(file.open(QIODevice::WriteOnly));
+ QCOMPARE(file.write("Hello"), Q_INT64_C(5));
+ QVERIFY2(file.commit(), qPrintable(file.errorString()));
+
+ QVERIFY(file.open(QIODevice::WriteOnly));
+ QCOMPARE(file.write("World"), Q_INT64_C(5));
+ QVERIFY2(file.commit(), qPrintable(file.errorString()));
+
+ QFile reader(targetFile);
+ QVERIFY(reader.open(QIODevice::ReadOnly));
+ QCOMPARE(QString::fromLatin1(reader.readAll()), QString::fromLatin1("World"));
+}
+
+void tst_QSaveFile::textStreamManualFlush()
+{
+ QTemporaryDir dir;
+ const QString targetFile = dir.path() + QString::fromLatin1("/outfile");
+ QSaveFile file(targetFile);
+ QVERIFY(file.open(QIODevice::WriteOnly));
+
+ QTextStream ts(&file);
+ ts << "Manual flush";
+ ts.flush();
+ QCOMPARE(file.error(), QFile::NoError);
+ QVERIFY(!QFile::exists(targetFile));
+
+ QVERIFY(file.commit());
+ QFile reader(targetFile);
+ QVERIFY(reader.open(QIODevice::ReadOnly));
+ QCOMPARE(QString::fromLatin1(reader.readAll().constData()), QString::fromLatin1("Manual flush"));
+ QFile::remove(targetFile);
+}
+
+void tst_QSaveFile::textStreamAutoFlush()
+{
+ QTemporaryDir dir;
+ const QString targetFile = dir.path() + QString::fromLatin1("/outfile");
+ QSaveFile file(targetFile);
+ QVERIFY(file.open(QIODevice::WriteOnly));
+
+ QTextStream ts(&file);
+ ts << "Auto-flush.";
+ // no flush
+ QVERIFY(file.commit()); // QIODevice::close will emit aboutToClose, which will flush the stream
+ QFile reader(targetFile);
+ QVERIFY(reader.open(QIODevice::ReadOnly));
+ QCOMPARE(QString::fromLatin1(reader.readAll().constData()), QString::fromLatin1("Auto-flush."));
+ QFile::remove(targetFile);
+}
+
+void tst_QSaveFile::transactionalWriteNoPermissionsOnDir_data()
+{
+ QTest::addColumn<bool>("directWriteFallback");
+
+ QTest::newRow("default") << false;
+ QTest::newRow("directWriteFallback") << true;
+}
+
+void tst_QSaveFile::transactionalWriteNoPermissionsOnDir()
+{
+#ifdef Q_OS_UNIX
+ QFETCH(bool, directWriteFallback);
+ // Restore permissions so that the QTemporaryDir cleanup can happen
+ class PermissionRestorer
+ {
+ QString m_path;
+ public:
+ PermissionRestorer(const QString& path)
+ : m_path(path)
+ {}
+
+ ~PermissionRestorer()
+ {
+ restore();
+ }
+ void restore()
+ {
+ QFile file(m_path);
+ file.setPermissions(QFile::Permissions(QFile::ReadOwner | QFile::WriteOwner | QFile::ExeOwner));
+ }
+ };
+
+
+ QTemporaryDir dir;
+ QVERIFY(QFile(dir.path()).setPermissions(QFile::ReadOwner | QFile::ExeOwner));
+ PermissionRestorer permissionRestorer(dir.path());
+
+ const QString targetFile = dir.path() + QString::fromLatin1("/outfile");
+ QSaveFile firstTry(targetFile);
+ QVERIFY(!firstTry.open(QIODevice::WriteOnly));
+ QCOMPARE((int)firstTry.error(), (int)QFile::OpenError);
+ QVERIFY(!firstTry.commit());
+
+ // Now make an existing writable file
+ permissionRestorer.restore();
+ QFile f(targetFile);
+ QVERIFY(f.open(QIODevice::WriteOnly));
+ QCOMPARE(f.write("Hello"), Q_INT64_C(5));
+ f.close();
+
+ // Make the directory non-writable again
+ QVERIFY(QFile(dir.path()).setPermissions(QFile::ReadOwner | QFile::ExeOwner));
+
+ // And write to it again using QSaveFile; only works if directWriteFallback is enabled
+ QSaveFile file(targetFile);
+ file.setDirectWriteFallback(directWriteFallback);
+ QCOMPARE(file.directWriteFallback(), directWriteFallback);
+ if (directWriteFallback) {
+ QVERIFY(file.open(QIODevice::WriteOnly));
+ QCOMPARE((int)file.error(), (int)QFile::NoError);
+ QCOMPARE(file.write("World"), Q_INT64_C(5));
+ QVERIFY(file.commit());
+
+ QFile reader(targetFile);
+ QVERIFY(reader.open(QIODevice::ReadOnly));
+ QCOMPARE(QString::fromLatin1(reader.readAll()), QString::fromLatin1("World"));
+ reader.close();
+
+ QVERIFY(file.open(QIODevice::WriteOnly));
+ QCOMPARE((int)file.error(), (int)QFile::NoError);
+ QCOMPARE(file.write("W"), Q_INT64_C(1));
+ file.cancelWriting(); // no effect, as per the documentation
+ QVERIFY(file.commit());
+
+ QVERIFY(reader.open(QIODevice::ReadOnly));
+ QCOMPARE(QString::fromLatin1(reader.readAll()), QString::fromLatin1("W"));
+ } else {
+ QVERIFY(!file.open(QIODevice::WriteOnly));
+ QCOMPARE((int)file.error(), (int)QFile::OpenError);
+ }
+#endif
+}
+
+void tst_QSaveFile::transactionalWriteNoPermissionsOnFile()
+{
+ // Setup an existing but readonly file
+ QTemporaryDir dir;
+ const QString targetFile = dir.path() + QString::fromLatin1("/outfile");
+ QFile file(targetFile);
+ QVERIFY(file.open(QIODevice::WriteOnly));
+ QCOMPARE(file.write("Hello"), Q_INT64_C(5));
+ file.close();
+ file.setPermissions(QFile::ReadOwner);
+ QVERIFY(!file.open(QIODevice::WriteOnly));
+
+ // Try saving into it
+ {
+ QSaveFile saveFile(targetFile);
+ QVERIFY(!saveFile.open(QIODevice::WriteOnly)); // just like QFile
+ }
+ QVERIFY(file.exists());
+}
+
+void tst_QSaveFile::transactionalWriteCanceled()
+{
+ QTemporaryDir dir;
+ const QString targetFile = dir.path() + QString::fromLatin1("/outfile");
+ QFile::remove(targetFile);
+ QSaveFile file(targetFile);
+ QVERIFY(file.open(QIODevice::WriteOnly));
+
+ QTextStream ts(&file);
+ ts << "This writing operation will soon be canceled.\n";
+ ts.flush();
+ QCOMPARE(file.error(), QFile::NoError);
+ QVERIFY(!QFile::exists(targetFile));
+
+ // We change our mind, let's abort writing
+ file.cancelWriting();
+
+ QVERIFY(!file.commit());
+
+ QVERIFY(!QFile::exists(targetFile)); // temp file was discarded
+ QCOMPARE(file.fileName(), targetFile);
+}
+
+void tst_QSaveFile::transactionalWriteErrorRenaming()
+{
+ QTemporaryDir dir;
+ const QString targetFile = dir.path() + QString::fromLatin1("/outfile");
+ QSaveFile file(targetFile);
+ QVERIFY(file.open(QIODevice::WriteOnly));
+ QCOMPARE(file.write("Hello"), qint64(5));
+ QVERIFY(!QFile::exists(targetFile));
+
+ // Restore permissions so that the QTemporaryDir cleanup can happen
+ class PermissionRestorer
+ {
+ public:
+ PermissionRestorer(const QString& path)
+ : m_path(path)
+ {}
+
+ ~PermissionRestorer()
+ {
+ QFile file(m_path);
+#ifdef Q_OS_UNIX
+ file.setPermissions(QFile::Permissions(QFile::ReadOwner | QFile::WriteOwner | QFile::ExeOwner));
+#else
+ file.setPermissions(QFile::WriteOwner);
+ file.remove();
+#endif
+ }
+
+ private:
+ QString m_path;
+ };
+
+#ifdef Q_OS_UNIX
+ // Make rename() fail for lack of permissions in the directory
+ QFile dirAsFile(dir.path()); // yay, I have to use QFile to change a dir's permissions...
+ QVERIFY(dirAsFile.setPermissions(QFile::Permissions(0))); // no permissions
+ PermissionRestorer permissionRestorer(dir.path());
+#else
+ // Windows: Make rename() fail for lack of permissions on an existing target file
+ QFile existingTargetFile(targetFile);
+ QVERIFY(existingTargetFile.open(QIODevice::WriteOnly));
+ QCOMPARE(file.write("Target"), qint64(6));
+ existingTargetFile.close();
+ QVERIFY(existingTargetFile.setPermissions(QFile::ReadOwner));
+ PermissionRestorer permissionRestorer(targetFile);
+#endif
+
+ // The saving should fail.
+ QVERIFY(!file.commit());
+#ifdef Q_OS_UNIX
+ QVERIFY(!QFile::exists(targetFile)); // renaming failed
+#endif
+ QCOMPARE(file.error(), QFile::RenameError);
+}
+
+QTEST_MAIN(tst_QSaveFile)
+#include "tst_qsavefile.moc"
diff --git a/tests/auto/corelib/io/qsettings/tst_qsettings.cpp b/tests/auto/corelib/io/qsettings/tst_qsettings.cpp
index f152c48c7d..c2909cf7c5 100644
--- a/tests/auto/corelib/io/qsettings/tst_qsettings.cpp
+++ b/tests/auto/corelib/io/qsettings/tst_qsettings.cpp
@@ -694,7 +694,9 @@ void tst_QSettings::testErrorHandling()
#ifdef Q_OS_WIN
QSKIP("Windows doesn't support most file modes, including read-only directories, so this test is moot.");
#elif defined(Q_OS_UNIX)
+#if !defined(Q_OS_VXWORKS) // VxWorks does not have users/groups
if (::getuid() == 0)
+#endif
QSKIP("Running this test as root doesn't work, since file perms do not bother him");
#else
QFETCH(int, filePerms);
diff --git a/tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp b/tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp
index c4453fd5f2..f94c8eac4f 100644
--- a/tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp
+++ b/tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp
@@ -45,6 +45,7 @@
#include <qstandardpaths.h>
#include <qfileinfo.h>
#include <qsysinfo.h>
+#include <qregexp.h>
#ifdef Q_OS_UNIX
#include <unistd.h>
@@ -72,6 +73,7 @@ private slots:
void testCustomRuntimeDirectory();
void testAllWritableLocations_data();
void testAllWritableLocations();
+ void testCleanPath();
private:
#ifdef Q_XDG_PLATFORM
@@ -430,6 +432,18 @@ void tst_qstandardpaths::testAllWritableLocations()
QCOMPARE(loc.endsWith(QLatin1Char('/')), false);
}
+void tst_qstandardpaths::testCleanPath()
+{
+ const QRegExp filter(QStringLiteral("\\\\"));
+ QVERIFY(filter.isValid());
+ for (int i = 0; i <= QStandardPaths::GenericCacheLocation; ++i) {
+ const QStringList paths = QStandardPaths::standardLocations(QStandardPaths::StandardLocation(i));
+ QVERIFY2(paths.filter(filter).isEmpty(),
+ qPrintable(QString::fromLatin1("Backslash found in %1 %2")
+ .arg(i).arg(paths.join(QLatin1Char(',')))));
+ }
+}
+
QTEST_MAIN(tst_qstandardpaths)
#include "tst_qstandardpaths.moc"
diff --git a/tests/auto/corelib/io/qtemporaryfile/tst_qtemporaryfile.cpp b/tests/auto/corelib/io/qtemporaryfile/tst_qtemporaryfile.cpp
index 28cf7a904a..6eb6f83d2a 100644
--- a/tests/auto/corelib/io/qtemporaryfile/tst_qtemporaryfile.cpp
+++ b/tests/auto/corelib/io/qtemporaryfile/tst_qtemporaryfile.cpp
@@ -92,6 +92,7 @@ private slots:
void createNativeFile();
void QTBUG_4796_data();
void QTBUG_4796();
+ void guaranteeUnique();
};
void tst_QTemporaryFile::initTestCase()
@@ -782,5 +783,39 @@ void tst_QTemporaryFile::QTBUG_4796()
cleaner.reset();
}
+void tst_QTemporaryFile::guaranteeUnique()
+{
+ QDir dir(QDir::tempPath());
+ QString takenFileName;
+
+ // First pass. See which filename QTemporaryFile will try first.
+ {
+ // Fix the random seed.
+ qsrand(1135);
+ QTemporaryFile tmpFile("testFile1.XXXXXX");
+ tmpFile.open();
+ takenFileName = tmpFile.fileName();
+ QVERIFY(QFile::exists(takenFileName));
+ }
+
+ QVERIFY(!QFile::exists(takenFileName));
+
+ // Create a directory with same name.
+ QVERIFY(dir.mkdir(takenFileName));
+
+ // Second pass, now we have blocked its first attempt with a directory.
+ {
+ // Fix the random seed.
+ qsrand(1135);
+ QTemporaryFile tmpFile("testFile1.XXXXXX");
+ QVERIFY(tmpFile.open());
+ QString uniqueFileName = tmpFile.fileName();
+ QVERIFY(QFileInfo(uniqueFileName).isFile());
+ QVERIFY(uniqueFileName != takenFileName);
+ }
+
+ QVERIFY(dir.rmdir(takenFileName));
+}
+
QTEST_MAIN(tst_QTemporaryFile)
#include "tst_qtemporaryfile.moc"
diff --git a/tests/auto/corelib/io/qurl/tst_qurl.cpp b/tests/auto/corelib/io/qurl/tst_qurl.cpp
index 1f59336fc6..898aefffd3 100644
--- a/tests/auto/corelib/io/qurl/tst_qurl.cpp
+++ b/tests/auto/corelib/io/qurl/tst_qurl.cpp
@@ -79,6 +79,8 @@ private slots:
void toString();
void toString_constructed_data();
void toString_constructed();
+ void toAndFromStringList_data();
+ void toAndFromStringList();
void isParentOf_data();
void isParentOf();
void toLocalFile_data();
@@ -948,6 +950,25 @@ void tst_QUrl::toString()
QCOMPARE(url.toString(QUrl::FormattingOptions(options)), string);
}
+void tst_QUrl::toAndFromStringList_data()
+{
+ QTest::addColumn<QStringList>("strings");
+
+ QTest::newRow("empty") << QStringList();
+ QTest::newRow("local") << (QStringList() << "file:///tmp" << "file:///");
+ QTest::newRow("remote") << (QStringList() << "http://qt-project.org");
+}
+
+void tst_QUrl::toAndFromStringList()
+{
+ QFETCH(QStringList, strings);
+
+ const QList<QUrl> urls = QUrl::fromStringList(strings);
+ QCOMPARE(urls.count(), strings.count());
+ const QStringList converted = QUrl::toStringList(urls);
+ QCOMPARE(converted, strings);
+}
+
//### more tests ... what do we expect ...
void tst_QUrl::isParentOf_data()
{
@@ -2163,33 +2184,52 @@ void tst_QUrl::tldRestrictions_data()
// current whitelist
QTest::newRow("ac") << QString("ac") << true;
+ QTest::newRow("ar") << QString("ar") << true;
+ QTest::newRow("asia") << QString("asia") << true;
QTest::newRow("at") << QString("at") << true;
+ QTest::newRow("biz") << QString("biz") << true;
QTest::newRow("br") << QString("br") << true;
QTest::newRow("cat") << QString("cat") << true;
QTest::newRow("ch") << QString("ch") << true;
QTest::newRow("cl") << QString("cl") << true;
QTest::newRow("cn") << QString("cn") << true;
+ QTest::newRow("com") << QString("com") << true;
QTest::newRow("de") << QString("de") << true;
QTest::newRow("dk") << QString("dk") << true;
+ QTest::newRow("es") << QString("es") << true;
QTest::newRow("fi") << QString("fi") << true;
+ QTest::newRow("gr") << QString("gr") << true;
QTest::newRow("hu") << QString("hu") << true;
+ QTest::newRow("il") << QString("il") << true;
QTest::newRow("info") << QString("info") << true;
QTest::newRow("io") << QString("io") << true;
+ QTest::newRow("is") << QString("is") << true;
+ QTest::newRow("ir") << QString("ir") << true;
QTest::newRow("jp") << QString("jp") << true;
QTest::newRow("kr") << QString("kr") << true;
QTest::newRow("li") << QString("li") << true;
QTest::newRow("lt") << QString("lt") << true;
+ QTest::newRow("lu") << QString("lu") << true;
+ QTest::newRow("lv") << QString("lv") << true;
QTest::newRow("museum") << QString("museum") << true;
+ QTest::newRow("name") << QString("name") << true;
+ QTest::newRow("net") << QString("name") << true;
QTest::newRow("no") << QString("no") << true;
+ QTest::newRow("nu") << QString("nu") << true;
+ QTest::newRow("nz") << QString("nz") << true;
+ QTest::newRow("org") << QString("org") << true;
+ QTest::newRow("pl") << QString("pl") << true;
+ QTest::newRow("pr") << QString("pr") << true;
QTest::newRow("se") << QString("se") << true;
QTest::newRow("sh") << QString("sh") << true;
+ QTest::newRow("tel") << QString("tel") << true;
QTest::newRow("th") << QString("th") << true;
QTest::newRow("tm") << QString("tm") << true;
QTest::newRow("tw") << QString("tw") << true;
+ QTest::newRow("ua") << QString("ua") << true;
QTest::newRow("vn") << QString("vn") << true;
// known blacklists:
- QTest::newRow("com") << QString("com") << false;
QTest::newRow("foo") << QString("foo") << false;
}
@@ -2796,6 +2836,12 @@ void tst_QUrl::effectiveTLDs_data()
QTest::newRow("yes6") << QUrl::fromEncoded("http://www.com.com.cn") << ".com.cn";
QTest::newRow("yes7") << QUrl::fromEncoded("http://www.test.org.ws") << ".org.ws";
QTest::newRow("yes9") << QUrl::fromEncoded("http://www.com.co.uk.wallonie.museum") << ".wallonie.museum";
+ QTest::newRow("yes10") << QUrl::fromEncoded("http://www.com.evje-og-hornnes.no") << ".evje-og-hornnes.no";
+ QTest::newRow("yes11") << QUrl::fromEncoded("http://www.bla.kamijima.ehime.jp") << ".kamijima.ehime.jp";
+ QTest::newRow("yes12") << QUrl::fromEncoded("http://www.bla.kakuda.miyagi.jp") << ".kakuda.miyagi.jp";
+ QTest::newRow("yes13") << QUrl::fromEncoded("http://mypage.betainabox.com") << ".betainabox.com";
+ QTest::newRow("yes14") << QUrl::fromEncoded("http://mypage.rhcloud.com") << ".rhcloud.com";
+ QTest::newRow("yes15") << QUrl::fromEncoded("http://mypage.int.az") << ".int.az";
}
void tst_QUrl::effectiveTLDs()
diff --git a/tests/auto/corelib/io/qurlinternal/tst_qurlinternal.cpp b/tests/auto/corelib/io/qurlinternal/tst_qurlinternal.cpp
index 6ba659856c..fa3dec620a 100644
--- a/tests/auto/corelib/io/qurlinternal/tst_qurlinternal.cpp
+++ b/tests/auto/corelib/io/qurlinternal/tst_qurlinternal.cpp
@@ -649,6 +649,20 @@ void tst_QUrlInternal::ace_testsuite_data()
<< "xn----rmckbbajlc6dj7bxne2c.xn--wgbh1c"
<< "."
<< egyptianIDN;
+
+ QString russianIDN = QString::fromUtf8("\321\217\320\275\320\264\320\265\320\272\321\201.\321\200\321\204");
+ QTest::newRow("russian-tld-ace")
+ << "xn--d1acpjx3f.xn--p1ai"
+ << "xn--d1acpjx3f.xn--p1ai"
+ << "."
+ << russianIDN;
+
+ QString taiwaneseIDN = QString::fromUtf8("\345\217\260\345\214\227\346\214\211\346\221\251.\345\217\260\347\201\243");
+ QTest::newRow("taiwanese-tld-ace")
+ << "xn--djrptm67aikb.xn--kpry57d"
+ << "xn--djrptm67aikb.xn--kpry57d"
+ << "."
+ << taiwaneseIDN;
}
void tst_QUrlInternal::ace_testsuite()
diff --git a/tests/auto/corelib/io/qwinoverlappedionotifier/tst_qwinoverlappedionotifier.cpp b/tests/auto/corelib/io/qwinoverlappedionotifier/tst_qwinoverlappedionotifier.cpp
index 6e2eeced05..bad77b1e06 100644
--- a/tests/auto/corelib/io/qwinoverlappedionotifier/tst_qwinoverlappedionotifier.cpp
+++ b/tests/auto/corelib/io/qwinoverlappedionotifier/tst_qwinoverlappedionotifier.cpp
@@ -251,21 +251,24 @@ void tst_QWinOverlappedIoNotifier::multipleOperations()
// start async read on client
QByteArray clientReadBuffer(377, Qt::Uninitialized);
- OVERLAPPED clientReadOverlapped = {0};
+ OVERLAPPED clientReadOverlapped;
+ ZeroMemory(&clientReadOverlapped, sizeof(clientReadOverlapped));
BOOL readSuccess = ReadFile(hClient, clientReadBuffer.data(), clientReadBuffer.size(),
NULL, &clientReadOverlapped);
QVERIFY(readSuccess || GetLastError() == ERROR_IO_PENDING);
// start async write client -> server
QByteArray clientDataToWrite(233, 'B');
- OVERLAPPED clientWriteOverlapped = {0};
+ OVERLAPPED clientWriteOverlapped;
+ ZeroMemory(&clientWriteOverlapped, sizeof(clientWriteOverlapped));
BOOL writeSuccess = WriteFile(hClient, clientDataToWrite.data(), clientDataToWrite.size(),
NULL, &clientWriteOverlapped);
QVERIFY(writeSuccess || GetLastError() == ERROR_IO_PENDING);
// start async write server -> client
QByteArray serverDataToWrite(144, 'A');
- OVERLAPPED serverOverlapped = {0};
+ OVERLAPPED serverOverlapped;
+ ZeroMemory(&serverOverlapped, sizeof(serverOverlapped));
writeSuccess = WriteFile(hServer, serverDataToWrite.data(), serverDataToWrite.size(),
NULL, &serverOverlapped);
QVERIFY(writeSuccess || GetLastError() == ERROR_IO_PENDING);
@@ -284,9 +287,9 @@ void tst_QWinOverlappedIoNotifier::multipleOperations()
QTRY_COMPARE(sink.notifications.count(), 2);
foreach (const NotifierSink::IOResult &r, sink.notifications) {
QCOMPARE(r.errorCode, DWORD(ERROR_SUCCESS));
- if (r.bytes == serverDataToWrite.count())
+ if (r.bytes == DWORD(serverDataToWrite.count()))
QCOMPARE(r.overlapped, &clientReadOverlapped);
- else if (r.bytes == clientDataToWrite.count())
+ else if (r.bytes == DWORD(clientDataToWrite.count()))
QCOMPARE(r.overlapped, &clientWriteOverlapped);
else
QVERIFY2(false, "Unexpected number of bytes received.");
diff --git a/tests/auto/corelib/itemmodels/qabstractitemmodel/tst_qabstractitemmodel.cpp b/tests/auto/corelib/itemmodels/qabstractitemmodel/tst_qabstractitemmodel.cpp
index 20bd4fa433..d2fb56ce02 100644
--- a/tests/auto/corelib/itemmodels/qabstractitemmodel/tst_qabstractitemmodel.cpp
+++ b/tests/auto/corelib/itemmodels/qabstractitemmodel/tst_qabstractitemmodel.cpp
@@ -467,9 +467,6 @@ typedef QPair<int, int> Position;
typedef QVector<QPair<int, int> > Selection;
typedef QVector<QVector<QString> > StringTable;
typedef QVector<QString> StringTableRow;
-Q_DECLARE_METATYPE(Position)
-Q_DECLARE_METATYPE(Selection)
-Q_DECLARE_METATYPE(StringTable)
static StringTableRow qStringTableRow(const QString &s1, const QString &s2, const QString &s3)
{
@@ -1922,8 +1919,6 @@ public:
void tst_QAbstractItemModel::testDataChanged()
{
- qRegisterMetaType<QVector<int> >();
-
CustomRoleModel model;
QSignalSpy withRoles(&model, SIGNAL(dataChanged(QModelIndex,QModelIndex,QVector<int>)));
diff --git a/tests/auto/corelib/itemmodels/qabstractproxymodel/tst_qabstractproxymodel.cpp b/tests/auto/corelib/itemmodels/qabstractproxymodel/tst_qabstractproxymodel.cpp
index c8cbacf76e..c385a02b9c 100644
--- a/tests/auto/corelib/itemmodels/qabstractproxymodel/tst_qabstractproxymodel.cpp
+++ b/tests/auto/corelib/itemmodels/qabstractproxymodel/tst_qabstractproxymodel.cpp
@@ -281,8 +281,6 @@ void tst_QAbstractProxyModel::revert()
// public void setSourceModel(QAbstractItemModel* sourceModel)
void tst_QAbstractProxyModel::setSourceModel()
{
- qRegisterMetaType<QAbstractItemModel*>();
-
SubQAbstractProxyModel model;
QCOMPARE(model.property("sourceModel"), QVariant::fromValue<QAbstractItemModel*>(0));
diff --git a/tests/auto/corelib/itemmodels/qidentityproxymodel/tst_qidentityproxymodel.cpp b/tests/auto/corelib/itemmodels/qidentityproxymodel/tst_qidentityproxymodel.cpp
index f750b7a9d4..ea0a14c18c 100644
--- a/tests/auto/corelib/itemmodels/qidentityproxymodel/tst_qidentityproxymodel.cpp
+++ b/tests/auto/corelib/itemmodels/qidentityproxymodel/tst_qidentityproxymodel.cpp
@@ -79,6 +79,8 @@ private slots:
void reset();
void dataChanged();
+ void itemData();
+
protected:
void verifyIdentity(QAbstractItemModel *model, const QModelIndex &parent = QModelIndex());
@@ -364,5 +366,29 @@ void tst_QIdentityProxyModel::dataChanged()
m_proxy->setSourceModel(0);
}
+class AppendStringProxy : public QIdentityProxyModel
+{
+public:
+ QVariant data(const QModelIndex &index, int role) const
+ {
+ const QVariant result = sourceModel()->data(index, role);
+ if (role != Qt::DisplayRole)
+ return result;
+ return result.toString() + "_appended";
+ }
+};
+
+void tst_QIdentityProxyModel::itemData()
+{
+ QStringListModel model(QStringList() << "Monday" << "Tuesday" << "Wednesday");
+ AppendStringProxy proxy;
+ proxy.setSourceModel(&model);
+
+ const QModelIndex topIndex = proxy.index(0, 0);
+ QCOMPARE(topIndex.data(Qt::DisplayRole).toString(), QStringLiteral("Monday_appended"));
+ QCOMPARE(proxy.data(topIndex, Qt::DisplayRole).toString(), QStringLiteral("Monday_appended"));
+ QCOMPARE(proxy.itemData(topIndex).value(Qt::DisplayRole).toString(), QStringLiteral("Monday_appended"));
+}
+
QTEST_MAIN(tst_QIdentityProxyModel)
#include "tst_qidentityproxymodel.moc"
diff --git a/tests/auto/corelib/itemmodels/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp b/tests/auto/corelib/itemmodels/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp
index 02a4824c4b..923b9a3a07 100644
--- a/tests/auto/corelib/itemmodels/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp
+++ b/tests/auto/corelib/itemmodels/qsortfilterproxymodel/tst_qsortfilterproxymodel.cpp
@@ -54,6 +54,8 @@ typedef QList<int> IntList;
typedef QPair<int, int> IntPair;
typedef QList<IntPair> IntPairList;
+Q_DECLARE_METATYPE(QList<QPersistentModelIndex>)
+
class tst_QSortFilterProxyModel : public QObject
{
Q_OBJECT
@@ -134,6 +136,7 @@ private slots:
void testMultipleProxiesWithSelection();
void mapSelectionFromSource();
+ void testResetInternalData();
void filteredColumns();
void headerDataChanged();
@@ -143,6 +146,9 @@ private slots:
void hierarchyFilterInvalidation();
void simpleFilterInvalidation();
+ void chainedProxyModelRoleNames();
+
+ void noMapAfterSourceDelete();
protected:
void buildHierarchy(const QStringList &data, QAbstractItemModel *model);
void checkHierarchy(const QStringList &data, const QAbstractItemModel *model);
@@ -174,9 +180,7 @@ tst_QSortFilterProxyModel::tst_QSortFilterProxyModel()
void tst_QSortFilterProxyModel::initTestCase()
{
- qRegisterMetaType<IntList>("IntList");
- qRegisterMetaType<IntPair>("IntPair");
- qRegisterMetaType<IntPairList>("IntPairList");
+ qRegisterMetaType<QList<QPersistentModelIndex> >();
m_model = new QStandardItemModel(0, 1);
m_proxy = new QSortFilterProxyModel();
m_proxy->setSourceModel(m_model);
@@ -3242,7 +3246,142 @@ void tst_QSortFilterProxyModel::resetInvalidate()
QCOMPARE(ok, works);
}
-Q_DECLARE_METATYPE(QList<QPersistentModelIndex>)
+/**
+ * A proxy which changes the background color for items ending in 'y' or 'r'
+ */
+class CustomDataProxy : public QSortFilterProxyModel
+{
+ Q_OBJECT
+
+public:
+ CustomDataProxy(QObject *parent = 0)
+ : QSortFilterProxyModel(parent)
+ {
+ setDynamicSortFilter(true);
+ }
+
+ void setSourceModel(QAbstractItemModel *sourceModel)
+ {
+ // It would be possible to use only the modelReset signal of the source model to clear
+ // the data in *this, however, this requires that the slot is connected
+ // before QSortFilterProxyModel::setSourceModel is called, and even then depends
+ // on the order of invocation of slots being the same as the order of connection.
+ // ie, not reliable.
+// connect(sourceModel, SIGNAL(modelReset()), SLOT(resetInternalData()));
+ QSortFilterProxyModel::setSourceModel(sourceModel);
+ // Making the connect after the setSourceModel call clears the data too late.
+// connect(sourceModel, SIGNAL(modelReset()), SLOT(resetInternalData()));
+
+ // This could be done in data(), but the point is to need to cache something in the proxy
+ // which needs to be cleared on reset.
+ for (int i = 0; i < sourceModel->rowCount(); ++i)
+ {
+ if (sourceModel->index(i, 0).data().toString().endsWith(QLatin1Char('y')))
+ {
+ m_backgroundColours.insert(i, Qt::blue);
+ } else if (sourceModel->index(i, 0).data().toString().endsWith(QLatin1Char('r')))
+ {
+ m_backgroundColours.insert(i, Qt::red);
+ }
+ }
+ }
+
+ QVariant data(const QModelIndex &index, int role) const
+ {
+ if (role != Qt::BackgroundRole)
+ return QSortFilterProxyModel::data(index, role);
+ return m_backgroundColours.value(index.row());
+ }
+
+private slots:
+ void resetInternalData()
+ {
+ m_backgroundColours.clear();
+ }
+
+private:
+ QHash<int, QColor> m_backgroundColours;
+};
+
+class ModelObserver : public QObject
+{
+ Q_OBJECT
+public:
+ ModelObserver(QAbstractItemModel *model, QObject *parent = 0)
+ : QObject(parent), m_model(model)
+ {
+ connect(m_model, SIGNAL(modelAboutToBeReset()), SLOT(modelAboutToBeReset()));
+ connect(m_model, SIGNAL(modelReset()), SLOT(modelReset()));
+ }
+
+public slots:
+ void modelAboutToBeReset()
+ {
+ int reds = 0, blues = 0;
+ for (int i = 0; i < m_model->rowCount(); ++i)
+ {
+ QColor color = m_model->index(i, 0).data(Qt::BackgroundRole).value<QColor>();
+ if (color == Qt::blue)
+ ++blues;
+ if (color == Qt::red)
+ ++reds;
+ }
+ QCOMPARE(blues, 11);
+ QCOMPARE(reds, 4);
+ }
+
+ void modelReset()
+ {
+ int reds = 0, blues = 0;
+ for (int i = 0; i < m_model->rowCount(); ++i)
+ {
+ QColor color = m_model->index(i, 0).data(Qt::BackgroundRole).value<QColor>();
+ if (color == Qt::blue)
+ ++blues;
+ if (color == Qt::red)
+ ++reds;
+ }
+ QCOMPARE(reds, 0);
+ QCOMPARE(blues, 0);
+ }
+
+private:
+ QAbstractItemModel * const m_model;
+
+};
+
+void tst_QSortFilterProxyModel::testResetInternalData()
+{
+
+ QStringListModel model(QStringList() << "Monday"
+ << "Tuesday"
+ << "Wednesday"
+ << "Thursday"
+ << "Friday"
+ << "January"
+ << "February"
+ << "March"
+ << "April"
+ << "May"
+ << "Saturday"
+ << "June"
+ << "Sunday"
+ << "July"
+ << "August"
+ << "September"
+ << "October"
+ << "November"
+ << "December");
+
+ CustomDataProxy proxy;
+ proxy.setSourceModel(&model);
+
+ ModelObserver observer(&proxy);
+
+ // Cause the source model to reset.
+ model.setStringList(QStringList() << "Spam" << "Eggs");
+
+}
void tst_QSortFilterProxyModel::testParentLayoutChanged()
{
@@ -3276,8 +3415,6 @@ void tst_QSortFilterProxyModel::testParentLayoutChanged()
proxy2.setSourceModel(&proxy);
proxy2.setObjectName("proxy2");
- qRegisterMetaType<QList<QPersistentModelIndex> >();
-
QSignalSpy dataChangedSpy(&model, SIGNAL(dataChanged(QModelIndex,QModelIndex)));
QVERIFY(dataChangedSpy.isValid());
@@ -3411,8 +3548,6 @@ private:
void tst_QSortFilterProxyModel::moveSourceRows()
{
- qRegisterMetaType<QList<QPersistentModelIndex> >();
-
DynamicTreeModel model;
{
@@ -3635,6 +3770,79 @@ void tst_QSortFilterProxyModel::simpleFilterInvalidation()
model.insertRow(0, new QStandardItem("extra"));
}
+class CustomRoleNameModel : public QAbstractListModel
+{
+ Q_OBJECT
+public:
+ CustomRoleNameModel(QObject *parent = 0) : QAbstractListModel(parent) {}
+
+ QVariant data(const QModelIndex &index, int role) const
+ {
+ Q_UNUSED(index);
+ Q_UNUSED(role);
+ return QVariant();
+ }
+
+ int rowCount(const QModelIndex &parent = QModelIndex()) const
+ {
+ Q_UNUSED(parent);
+ return 0;
+ }
+
+ QHash<int, QByteArray> roleNames() const
+ {
+ QHash<int, QByteArray> rn = QAbstractListModel::roleNames();
+ rn[Qt::UserRole + 1] = "custom";
+ return rn;
+ }
+};
+
+void tst_QSortFilterProxyModel::chainedProxyModelRoleNames()
+{
+ QSortFilterProxyModel proxy1;
+ QSortFilterProxyModel proxy2;
+ CustomRoleNameModel customModel;
+
+ proxy2.setSourceModel(&proxy1);
+
+ // changing the sourceModel of proxy1 must also update roleNames of proxy2
+ proxy1.setSourceModel(&customModel);
+ QVERIFY(proxy2.roleNames().value(Qt::UserRole + 1) == "custom");
+}
+
+class SourceAssertion : public QSortFilterProxyModel
+{
+ Q_OBJECT
+public:
+ explicit SourceAssertion(QObject *parent = 0)
+ : QSortFilterProxyModel(parent)
+ {
+
+ }
+
+ QModelIndex mapToSource(const QModelIndex &proxyIndex) const
+ {
+ Q_ASSERT(sourceModel());
+ return QSortFilterProxyModel::mapToSource(proxyIndex);
+ }
+};
+
+void tst_QSortFilterProxyModel::noMapAfterSourceDelete()
+{
+ SourceAssertion proxy;
+ QStringListModel *model = new QStringListModel(QStringList() << "Foo" << "Bar");
+
+ proxy.setSourceModel(model);
+
+ // Create mappings
+ QPersistentModelIndex persistent = proxy.index(0, 0);
+
+ QVERIFY(persistent.isValid());
+
+ delete model;
+
+ QVERIFY(!persistent.isValid());
+}
QTEST_MAIN(tst_QSortFilterProxyModel)
#include "tst_qsortfilterproxymodel.moc"
diff --git a/tests/auto/corelib/json/tst_qtjson.cpp b/tests/auto/corelib/json/tst_qtjson.cpp
index a692b79fe9..6811551769 100644
--- a/tests/auto/corelib/json/tst_qtjson.cpp
+++ b/tests/auto/corelib/json/tst_qtjson.cpp
@@ -1003,49 +1003,81 @@ void tst_QtJson::toVariantList()
void tst_QtJson::toJson()
{
- QJsonObject object;
- object.insert("\\Key\n", QString("Value"));
- object.insert("null", QJsonValue());
- QJsonArray array;
- array.append(true);
- array.append(999.);
- array.append(QLatin1String("string"));
- array.append(QJsonValue());
- array.append(QLatin1String("\\\a\n\r\b\tabcABC\""));
- object.insert("Array", array);
+ // Test QJsonDocument::Indented format
+ {
+ QJsonObject object;
+ object.insert("\\Key\n", QString("Value"));
+ object.insert("null", QJsonValue());
+ QJsonArray array;
+ array.append(true);
+ array.append(999.);
+ array.append(QLatin1String("string"));
+ array.append(QJsonValue());
+ array.append(QLatin1String("\\\a\n\r\b\tabcABC\""));
+ object.insert("Array", array);
+
+ QByteArray json = QJsonDocument(object).toJson();
+
+ QByteArray expected =
+ "{\n"
+ " \"Array\": [\n"
+ " true,\n"
+ " 999,\n"
+ " \"string\",\n"
+ " null,\n"
+ " \"\\\\\\u0007\\n\\r\\b\\tabcABC\\\"\"\n"
+ " ],\n"
+ " \"\\\\Key\\n\": \"Value\",\n"
+ " \"null\": null\n"
+ "}\n";
+ QCOMPARE(json, expected);
- QByteArray json = QJsonDocument(object).toJson();
-
- QByteArray expected =
- "{\n"
- " \"Array\": [\n"
- " true,\n"
- " 999,\n"
- " \"string\",\n"
- " null,\n"
- " \"\\\\\\u0007\\n\\r\\b\\tabcABC\\\"\"\n"
- " ],\n"
- " \"\\\\Key\\n\": \"Value\",\n"
- " \"null\": null\n"
- "}\n";
- QCOMPARE(json, expected);
+ QJsonDocument doc;
+ doc.setObject(object);
+ json = doc.toJson();
+ QCOMPARE(json, expected);
- QJsonDocument doc;
- doc.setObject(object);
- json = doc.toJson();
- QCOMPARE(json, expected);
+ doc.setArray(array);
+ json = doc.toJson();
+ expected =
+ "[\n"
+ " true,\n"
+ " 999,\n"
+ " \"string\",\n"
+ " null,\n"
+ " \"\\\\\\u0007\\n\\r\\b\\tabcABC\\\"\"\n"
+ "]\n";
+ QCOMPARE(json, expected);
+ }
- doc.setArray(array);
- json = doc.toJson();
- expected =
- "[\n"
- " true,\n"
- " 999,\n"
- " \"string\",\n"
- " null,\n"
- " \"\\\\\\u0007\\n\\r\\b\\tabcABC\\\"\"\n"
- "]\n";
- QCOMPARE(json, expected);
+ // Test QJsonDocument::Compact format
+ {
+ QJsonObject object;
+ object.insert("\\Key\n", QString("Value"));
+ object.insert("null", QJsonValue());
+ QJsonArray array;
+ array.append(true);
+ array.append(999.);
+ array.append(QLatin1String("string"));
+ array.append(QJsonValue());
+ array.append(QLatin1String("\\\a\n\r\b\tabcABC\""));
+ object.insert("Array", array);
+
+ QByteArray json = QJsonDocument(object).toJson(QJsonDocument::Compact);
+ QByteArray expected =
+ "{\"Array\": [true,999,\"string\",null,\"\\\\\\u0007\\n\\r\\b\\tabcABC\\\"\"],\"\\\\Key\\n\": \"Value\",\"null\": null}";
+ QCOMPARE(json, expected);
+
+ QJsonDocument doc;
+ doc.setObject(object);
+ json = doc.toJson(QJsonDocument::Compact);
+ QCOMPARE(json, expected);
+
+ doc.setArray(array);
+ json = doc.toJson(QJsonDocument::Compact);
+ expected = "[true,999,\"string\",null,\"\\\\\\u0007\\n\\r\\b\\tabcABC\\\"\"]";
+ QCOMPARE(json, expected);
+ }
}
void tst_QtJson::fromJson()
@@ -1135,6 +1167,30 @@ void tst_QtJson::fromJson()
QCOMPARE(object.value("6").type(), QJsonValue::Object);
QCOMPARE(object.value("6").toObject().size(), 0);
}
+ {
+ QByteArray compactJson = "{\"Array\": [true,999,\"string\",null,\"\\\\\\u0007\\n\\r\\b\\tabcABC\\\"\"],\"\\\\Key\\n\": \"Value\",\"null\": null}";
+ QJsonDocument doc = QJsonDocument::fromJson(compactJson);
+ QVERIFY(!doc.isEmpty());
+ QCOMPARE(doc.isArray(), false);
+ QCOMPARE(doc.isObject(), true);
+ QJsonObject object = doc.object();
+ QCOMPARE(object.size(), 3);
+ QCOMPARE(object.value("\\Key\n").isString(), true);
+ QCOMPARE(object.value("\\Key\n").toString(), QString("Value"));
+ QCOMPARE(object.value("null").isNull(), true);
+ QCOMPARE(object.value("Array").isArray(), true);
+ QJsonArray array = object.value("Array").toArray();
+ QCOMPARE(array.size(), 5);
+ QCOMPARE(array.at(0).isBool(), true);
+ QCOMPARE(array.at(0).toBool(), true);
+ QCOMPARE(array.at(1).isDouble(), true);
+ QCOMPARE(array.at(1).toDouble(), 999.);
+ QCOMPARE(array.at(2).isString(), true);
+ QCOMPARE(array.at(2).toString(), QLatin1String("string"));
+ QCOMPARE(array.at(3).isNull(), true);
+ QCOMPARE(array.at(4).isString(), true);
+ QCOMPARE(array.at(4).toString(), QLatin1String("\\\a\n\r\b\tabcABC\""));
+ }
}
void tst_QtJson::fromJsonErrors()
diff --git a/tests/auto/corelib/kernel/kernel.pro b/tests/auto/corelib/kernel/kernel.pro
index 839d652be1..a283f5343d 100644
--- a/tests/auto/corelib/kernel/kernel.pro
+++ b/tests/auto/corelib/kernel/kernel.pro
@@ -21,6 +21,11 @@ SUBDIRS=\
qvariant \
qwineventnotifier
+!qtHaveModule(network): SUBDIRS -= \
+ qeventloop \
+ qobject \
+ qsocketnotifier
+
!contains(QT_CONFIG, private_tests): SUBDIRS -= \
qsocketnotifier \
qsharedmemory
@@ -28,3 +33,4 @@ SUBDIRS=\
# This test is only applicable on Windows
!win32*:SUBDIRS -= qwineventnotifier
+android|qnx: SUBDIRS -= qsharedmemory qsystemsemaphore
diff --git a/tests/auto/corelib/kernel/qcoreapplication/tst_qcoreapplication.cpp b/tests/auto/corelib/kernel/qcoreapplication/tst_qcoreapplication.cpp
index 42bf9eeca3..10c00e2a67 100644
--- a/tests/auto/corelib/kernel/qcoreapplication/tst_qcoreapplication.cpp
+++ b/tests/auto/corelib/kernel/qcoreapplication/tst_qcoreapplication.cpp
@@ -769,6 +769,18 @@ void tst_QCoreApplication::testQuitLock()
app.exec();
}
+static void createQObjectOnDestruction()
+{
+ // Make sure that we can create a QObject after the last QObject has been
+ // destroyed (especially after QCoreApplication has).
+ //
+ // Before the fixes, this would cause a dangling pointer dereference. If
+ // the problem comes back, it's possible that the following causes no
+ // effect.
+ QObject obj;
+ obj.thread()->setProperty("testing", 1);
+}
+Q_DESTRUCTOR_FUNCTION(createQObjectOnDestruction)
QTEST_APPLESS_MAIN(tst_QCoreApplication)
#include "tst_qcoreapplication.moc"
diff --git a/tests/auto/corelib/kernel/qmath/tst_qmath.cpp b/tests/auto/corelib/kernel/qmath/tst_qmath.cpp
index 0d977317ca..24934ac138 100644
--- a/tests/auto/corelib/kernel/qmath/tst_qmath.cpp
+++ b/tests/auto/corelib/kernel/qmath/tst_qmath.cpp
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2013 Laszlo Papp <lpapp@kde.org>
** Contact: http://www.qt-project.org/legal
**
** This file is part of the test suite of the Qt Toolkit.
@@ -42,13 +43,17 @@
#include <QtTest/QtTest>
#include <qmath.h>
-static const qreal PI = 3.14159265358979323846264338327950288;
+static const double PI = 3.14159265358979323846264338327950288;
class tst_QMath : public QObject
{
Q_OBJECT
private slots:
void fastSinCos();
+ void degreesToRadians_data();
+ void degreesToRadians();
+ void radiansToDegrees_data();
+ void radiansToDegrees();
};
void tst_QMath::fastSinCos()
@@ -62,6 +67,76 @@ void tst_QMath::fastSinCos()
}
}
+void tst_QMath::degreesToRadians_data()
+{
+ QTest::addColumn<float>("degreesFloat");
+ QTest::addColumn<float>("radiansFloat");
+ QTest::addColumn<double>("degreesDouble");
+ QTest::addColumn<double>("radiansDouble");
+
+ QTest::newRow( "pi" ) << 180.0f << float(M_PI) << 180.0 << PI;
+ QTest::newRow( "doublepi" ) << 360.0f << float(2*M_PI) << 360.0 << 2*PI;
+ QTest::newRow( "halfpi" ) << 90.0f << float(M_PI_2) << 90.0 << PI/2;
+
+ QTest::newRow( "random" ) << 123.1234567f << 2.1489097058516724f << 123.123456789123456789 << 2.148909707407169856192285627;
+ QTest::newRow( "bigrandom" ) << 987654321.9876543f << 17237819.79023679f << 987654321987654321.987654321987654321 << 17237819790236794.0;
+
+ QTest::newRow( "zero" ) << 0.0f << 0.0f << 0.0 << 0.0;
+
+ QTest::newRow( "minuspi" ) << -180.0f << float(-M_PI) << 180.0 << PI;
+ QTest::newRow( "minusdoublepi" ) << -360.0f << float(-2*M_PI) << -360.0 << -2*PI;
+ QTest::newRow( "minushalfpi" ) << -90.0f << float(-M_PI_2) << -90.0 << -PI/2;
+
+ QTest::newRow( "minusrandom" ) << -123.1234567f << -2.1489097058516724f << -123.123456789123456789 << -2.148909707407169856192285627;
+ QTest::newRow( "minusbigrandom" ) << -987654321.9876543f << -17237819.79023679f << -987654321987654321.987654321987654321 << -17237819790236794.0;
+}
+
+void tst_QMath::degreesToRadians()
+{
+ QFETCH(float, degreesFloat);
+ QFETCH(float, radiansFloat);
+ QFETCH(double, degreesDouble);
+ QFETCH(double, radiansDouble);
+
+ QCOMPARE(qDegreesToRadians(degreesFloat), radiansFloat);
+ QCOMPARE(qDegreesToRadians(degreesDouble), radiansDouble);
+}
+
+void tst_QMath::radiansToDegrees_data()
+{
+ QTest::addColumn<float>("radiansFloat");
+ QTest::addColumn<float>("degreesFloat");
+ QTest::addColumn<double>("radiansDouble");
+ QTest::addColumn<double>("degreesDouble");
+
+ QTest::newRow( "pi" ) << float(M_PI) << 180.0f << PI << 180.0;
+ QTest::newRow( "doublepi" ) << float(2*M_PI) << 360.0f << 2*PI << 360.0;
+ QTest::newRow( "halfpi" ) << float(M_PI_2) << 90.0f<< PI/2 << 90.0;
+
+ QTest::newRow( "random" ) << 123.1234567f << 7054.454427971739f << 123.123456789123456789 << 7054.4544330781363896676339209079742431640625;
+ QTest::newRow( "bigrandom" ) << 987654321.9876543f << 56588424267.74745f << 987654321987654321.987654321987654321 << 56588424267747450880.0;
+
+ QTest::newRow( "zero" ) << 0.0f << 0.0f << 0.0 << 0.0;
+
+ QTest::newRow( "minuspi" ) << float(-M_PI) << -180.0f << -PI << -180.0;
+ QTest::newRow( "minusdoublepi" ) << float(-2*M_PI) << -360.0f << -2*PI << -360.0;
+ QTest::newRow( "minushalfpi" ) << float(-M_PI_2) << -90.0f << -PI/2 << -90.0;
+
+ QTest::newRow( "minusrandom" ) << -123.1234567f << -7054.454427971739f << -123.123456789123456789 << -7054.4544330781363896676339209079742431640625;
+ QTest::newRow( "minusbigrandom" ) << -987654321.9876543f << -56588424267.74745f << -987654321987654321.987654321987654321 << -56588424267747450880.0;
+}
+
+void tst_QMath::radiansToDegrees()
+{
+ QFETCH(float, radiansFloat);
+ QFETCH(float, degreesFloat);
+ QFETCH(double, radiansDouble);
+ QFETCH(double, degreesDouble);
+
+ QCOMPARE(qRadiansToDegrees(radiansFloat), degreesFloat);
+ QCOMPARE(qRadiansToDegrees(radiansDouble), degreesDouble);
+}
+
QTEST_APPLESS_MAIN(tst_QMath)
#include "tst_qmath.moc"
diff --git a/tests/auto/corelib/kernel/qmetamethod/qmetamethod.pro b/tests/auto/corelib/kernel/qmetamethod/qmetamethod.pro
index e253702d56..8340bc06e3 100644
--- a/tests/auto/corelib/kernel/qmetamethod/qmetamethod.pro
+++ b/tests/auto/corelib/kernel/qmetamethod/qmetamethod.pro
@@ -3,5 +3,5 @@ CONFIG += parallel_test
TARGET = tst_qmetamethod
QT = core testlib
SOURCES = tst_qmetamethod.cpp
-macx:CONFIG -= app_bundle
+mac:CONFIG -= app_bundle
DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/corelib/kernel/qmetaobjectbuilder/qmetaobjectbuilder.pro b/tests/auto/corelib/kernel/qmetaobjectbuilder/qmetaobjectbuilder.pro
index 008b596b72..9e2d3519e6 100644
--- a/tests/auto/corelib/kernel/qmetaobjectbuilder/qmetaobjectbuilder.pro
+++ b/tests/auto/corelib/kernel/qmetaobjectbuilder/qmetaobjectbuilder.pro
@@ -2,5 +2,5 @@ CONFIG += testcase parallel_test
TARGET = tst_qmetaobjectbuilder
QT = core-private gui-private testlib
SOURCES = tst_qmetaobjectbuilder.cpp
-macx:CONFIG -= app_bundle
+mac:CONFIG -= app_bundle
DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/corelib/kernel/qmetatype/tst_qmetatype.cpp b/tests/auto/corelib/kernel/qmetatype/tst_qmetatype.cpp
index 7f7486ef4b..77ea39da53 100644
--- a/tests/auto/corelib/kernel/qmetatype/tst_qmetatype.cpp
+++ b/tests/auto/corelib/kernel/qmetatype/tst_qmetatype.cpp
@@ -110,6 +110,7 @@ private slots:
void saveAndLoadCustom();
void metaObject();
void constexprMetaTypeIds();
+ void constRefs();
};
struct Foo { int i; };
@@ -169,7 +170,7 @@ protected:
const QByteArray name = QString("Bar%1_%2").arg(i).arg((size_t)QThread::currentThreadId()).toLatin1();
const char *nm = name.constData();
int tp = qRegisterMetaType<Bar>(nm);
-#ifdef Q_OS_LINUX
+#if defined(Q_OS_LINUX) && !defined(Q_OS_ANDROID)
pthread_yield();
#endif
QMetaType info(tp);
@@ -1762,6 +1763,17 @@ void tst_QMetaType::constexprMetaTypeIds()
#endif
}
+void tst_QMetaType::constRefs()
+{
+ QCOMPARE(::qMetaTypeId<const int &>(), ::qMetaTypeId<int>());
+ QCOMPARE(::qMetaTypeId<const QString &>(), ::qMetaTypeId<QString>());
+ QCOMPARE(::qMetaTypeId<const CustomMovable &>(), ::qMetaTypeId<CustomMovable>());
+ QCOMPARE(::qMetaTypeId<const QList<CustomMovable> &>(), ::qMetaTypeId<QList<CustomMovable> >());
+#if defined(Q_COMPILER_CONSTEXPR)
+ Q_STATIC_ASSERT(::qMetaTypeId<const int &>() == ::qMetaTypeId<int>());
+#endif
+}
+
// Compile-time test, it should be possible to register function pointer types
class Undefined;
diff --git a/tests/auto/corelib/kernel/qobject/tst_qobject.cpp b/tests/auto/corelib/kernel/qobject/tst_qobject.cpp
index 865264c43a..06fc89f657 100644
--- a/tests/auto/corelib/kernel/qobject/tst_qobject.cpp
+++ b/tests/auto/corelib/kernel/qobject/tst_qobject.cpp
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2013 Olivier Goffart <ogoffart@woboq.com>
** Contact: http://www.qt-project.org/legal
**
** This file is part of the test suite of the Qt Toolkit.
@@ -68,7 +69,7 @@ class tst_QObject : public QObject
private slots:
void initTestCase();
void disconnect();
- void connectByName();
+ void connectSlotsByName();
void connectSignalsToSignalsWithDefaultArguments();
void receivers();
void normalize();
@@ -140,10 +141,22 @@ private slots:
void returnValue2_data();
void returnValue2();
void connectVirtualSlots();
+ void connectPrivateSlots();
void connectFunctorArgDifference();
+ void connectFunctorOverloads();
void disconnectDoesNotLeakFunctor();
};
+struct QObjectCreatedOnShutdown
+{
+ QObjectCreatedOnShutdown() {}
+ ~QObjectCreatedOnShutdown()
+ {
+ QObject();
+ }
+};
+static QObjectCreatedOnShutdown s_qobjectCreatedOnShutdown;
+
class SenderObject : public QObject
{
Q_OBJECT
@@ -368,6 +381,7 @@ public:
void emitSignalWithParams(int i) { emit signalWithParams(i); }
void emitSignalWithParams(int i, QString string) { emit signalWithParams(i, string); }
void emitSignalManyParams(int i1, int i2, int i3, QString string, bool onoff) { emit signalManyParams(i1, i2, i3, string, onoff); }
+ void emitSignalManyParams(int i1, int i2, int i3, QString string, bool onoff, bool dummy) { emit signalManyParams(i1, i2, i3, string, onoff, dummy); }
void emitSignalManyParams2(int i1, int i2, int i3, QString string, bool onoff) { emit signalManyParams2(i1, i2, i3, string, onoff); }
void emitSignalLoopBack() { emit signalLoopBack(); }
@@ -386,158 +400,89 @@ class AutoConnectReceiver : public QObject
Q_OBJECT
public:
+ QList<int> called_slots;
+
AutoConnectReceiver()
{
- reset();
-
connect(this, SIGNAL(on_Sender_signalLoopBack()), this, SLOT(slotLoopBack()));
}
- void reset() {
- called_slot10 = 0;
- called_slot9 = 0;
- called_slot8 = 0;
- called_slot7 = 0;
- called_slot6 = 0;
- called_slot5 = 0;
- called_slot4 = 0;
- called_slot3 = 0;
- called_slot2 = 0;
- called_slot1 = 0;
- }
-
- int called_slot1;
- int called_slot2;
- int called_slot3;
- int called_slot4;
- int called_slot5;
- int called_slot6;
- int called_slot7;
- int called_slot8;
- int called_slot9;
- int called_slot10;
-
- bool called(int slot) {
- switch (slot) {
- case 1: return called_slot1;
- case 2: return called_slot2;
- case 3: return called_slot3;
- case 4: return called_slot4;
- case 5: return called_slot5;
- case 6: return called_slot6;
- case 7: return called_slot7;
- case 8: return called_slot8;
- case 9: return called_slot9;
- case 10: return called_slot10;
- default: return false;
- }
- }
+ void emitSignalNoParams() { emit signalNoParams(); }
+ void emit_signal_with_underscore() { emit signal_with_underscore(); }
public slots:
- void on_Sender_signalNoParams() { ++called_slot1; }
- void on_Sender_signalWithParams(int i = 0) { ++called_slot2; Q_UNUSED(i); }
- void on_Sender_signalWithParams(int i, QString string) { ++called_slot3; Q_UNUSED(i);Q_UNUSED(string); }
- void on_Sender_signalManyParams() { ++called_slot4; }
- void on_Sender_signalManyParams(int i1, int i2, int i3, QString string, bool onoff) { ++called_slot5; Q_UNUSED(i1);Q_UNUSED(i2);Q_UNUSED(i3);Q_UNUSED(string);Q_UNUSED(onoff); }
+ void on_Sender_signalNoParams() { called_slots << 1; }
+ void on_Sender_signalWithParams(int i = 0) { called_slots << 2; Q_UNUSED(i); }
+ void on_Sender_signalWithParams(int i, QString string) { called_slots << 3; Q_UNUSED(i);Q_UNUSED(string); }
+ void on_Sender_signalManyParams() { called_slots << 4; }
+ void on_Sender_signalManyParams(int i1, int i2, int i3, QString string, bool onoff)
+ { called_slots << 5; Q_UNUSED(i1);Q_UNUSED(i2);Q_UNUSED(i3);Q_UNUSED(string);Q_UNUSED(onoff); }
void on_Sender_signalManyParams(int i1, int i2, int i3, QString string, bool onoff, bool dummy)
- { ++called_slot6; Q_UNUSED(i1);Q_UNUSED(i2);Q_UNUSED(i3);Q_UNUSED(string);Q_UNUSED(onoff); Q_UNUSED(dummy);}
+ { called_slots << 6; Q_UNUSED(i1);Q_UNUSED(i2);Q_UNUSED(i3);Q_UNUSED(string);Q_UNUSED(onoff); Q_UNUSED(dummy);}
void on_Sender_signalManyParams2(int i1, int i2, int i3, QString string, bool onoff)
- { ++called_slot7; Q_UNUSED(i1);Q_UNUSED(i2);Q_UNUSED(i3);Q_UNUSED(string);Q_UNUSED(onoff); }
- void slotLoopBack() { ++called_slot8; }
+ { called_slots << 7; Q_UNUSED(i1);Q_UNUSED(i2);Q_UNUSED(i3);Q_UNUSED(string);Q_UNUSED(onoff); }
+ void slotLoopBack() { called_slots << 8; }
+ void on_Receiver_signalNoParams() { called_slots << 9; }
+ void on_Receiver_signal_with_underscore() { called_slots << 10; }
protected slots:
- void o() { ++called_slot9; }
- void on() { ++called_slot10; }
+ void o() { called_slots << -1; }
+ void on() { called_slots << -1; }
+ void on_() { called_slots << -1; }
+ void on_something() { called_slots << -1; }
+ void on_child_signal() { called_slots << -1; }
signals:
void on_Sender_signalLoopBack();
+ void signalNoParams();
+ void signal_with_underscore();
};
-void tst_QObject::connectByName()
+void tst_QObject::connectSlotsByName()
{
AutoConnectReceiver receiver;
+ receiver.setObjectName("Receiver");
AutoConnectSender sender(&receiver);
sender.setObjectName("Sender");
+ QTest::ignoreMessage(QtWarningMsg, "QMetaObject::connectSlotsByName: No matching signal for on_child_signal()");
+ QTest::ignoreMessage(QtWarningMsg, "QMetaObject::connectSlotsByName: Connecting slot on_Sender_signalManyParams() with the first of the following compatible signals: (\"signalManyParams(int,int,int,QString,bool)\", \"signalManyParams(int,int,int,QString,bool,bool)\") ");
QMetaObject::connectSlotsByName(&receiver);
+ receiver.called_slots.clear();
sender.emitSignalNoParams();
- QCOMPARE(receiver.called(1), true);
- QCOMPARE(receiver.called(2), false);
- QCOMPARE(receiver.called(3), false);
- QCOMPARE(receiver.called(4), false);
- QCOMPARE(receiver.called(5), false);
- QCOMPARE(receiver.called(6), false);
- QCOMPARE(receiver.called(7), false);
- QCOMPARE(receiver.called(8), false);
- QCOMPARE(receiver.called(9), false);
- QCOMPARE(receiver.called(10), false);
- receiver.reset();
+ QCOMPARE(receiver.called_slots, QList<int>() << 1);
+ receiver.called_slots.clear();
sender.emitSignalWithParams(0);
- QCOMPARE(receiver.called(1), false);
- QCOMPARE(receiver.called(2), true);
- QCOMPARE(receiver.called(3), false);
- QCOMPARE(receiver.called(4), false);
- QCOMPARE(receiver.called(5), false);
- QCOMPARE(receiver.called(6), false);
- QCOMPARE(receiver.called(7), false);
- QCOMPARE(receiver.called(8), false);
- QCOMPARE(receiver.called(9), false);
- QCOMPARE(receiver.called(10), false);
- receiver.reset();
+ QCOMPARE(receiver.called_slots, QList<int>() << 2);
+ receiver.called_slots.clear();
sender.emitSignalWithParams(0, "string");
- QCOMPARE(receiver.called(1), false);
- QCOMPARE(receiver.called(2), false);
- QCOMPARE(receiver.called(3), true);
- QCOMPARE(receiver.called(4), false);
- QCOMPARE(receiver.called(5), false);
- QCOMPARE(receiver.called(6), false);
- QCOMPARE(receiver.called(7), false);
- QCOMPARE(receiver.called(8), false);
- QCOMPARE(receiver.called(9), false);
- QCOMPARE(receiver.called(10), false);
- receiver.reset();
+ QCOMPARE(receiver.called_slots, QList<int>() << 3);
+ receiver.called_slots.clear();
sender.emitSignalManyParams(1, 2, 3, "string", true);
- QCOMPARE(receiver.called(1), false);
- QCOMPARE(receiver.called(2), false);
- QCOMPARE(receiver.called(3), false);
- QCOMPARE(receiver.called(4), true);
- QCOMPARE(receiver.called(5), true);
- QCOMPARE(receiver.called(6), false);
- QCOMPARE(receiver.called(7), false);
- QCOMPARE(receiver.called(8), false);
- QCOMPARE(receiver.called(9), false);
- QCOMPARE(receiver.called(10), false);
- receiver.reset();
+ sender.emitSignalManyParams(1, 2, 3, "string", true, false);
+ // the slot '4' (signalManyParams()) will get connected
+ // to either of the two signalManyParams(...) overloads
+ QCOMPARE(receiver.called_slots, QList<int>() << 4 << 5 << 6);
+ receiver.called_slots.clear();
sender.emitSignalManyParams2(1, 2, 3, "string", true);
- QCOMPARE(receiver.called(1), false);
- QCOMPARE(receiver.called(2), false);
- QCOMPARE(receiver.called(3), false);
- QCOMPARE(receiver.called(4), false);
- QCOMPARE(receiver.called(5), false);
- QCOMPARE(receiver.called(6), false);
- QCOMPARE(receiver.called(7), true);
- QCOMPARE(receiver.called(8), false);
- QCOMPARE(receiver.called(9), false);
- QCOMPARE(receiver.called(10), false);
- receiver.reset();
+ QCOMPARE(receiver.called_slots, QList<int>() << 7);
+ receiver.called_slots.clear();
sender.emitSignalLoopBack();
- QCOMPARE(receiver.called(1), false);
- QCOMPARE(receiver.called(2), false);
- QCOMPARE(receiver.called(3), false);
- QCOMPARE(receiver.called(4), false);
- QCOMPARE(receiver.called(5), false);
- QCOMPARE(receiver.called(6), false);
- QCOMPARE(receiver.called(7), false);
- QCOMPARE(receiver.called(8), true);
- QCOMPARE(receiver.called(9), false);
- QCOMPARE(receiver.called(10), false);
- receiver.reset();
+ QCOMPARE(receiver.called_slots, QList<int>() << 8);
+
+ receiver.called_slots.clear();
+ receiver.emitSignalNoParams();
+ QCOMPARE(receiver.called_slots, QList<int>() << 9);
+
+ receiver.called_slots.clear();
+ receiver.emit_signal_with_underscore();
+ QCOMPARE(receiver.called_slots, QList<int>() << 10);
}
void tst_QObject::qobject_castTemplate()
@@ -1436,9 +1381,11 @@ public:
public slots:
void slot1(CustomType ct);
+ void slot2(const QList<CustomType> &ct);
signals:
void signal1(CustomType ct);
+ void signal2(const QList<CustomType> &ct);
public:
CustomType received;
@@ -1447,6 +1394,8 @@ public:
void QCustomTypeChecker::slot1(CustomType ct)
{ received = ct; }
+void QCustomTypeChecker::slot2(const QList< CustomType >& ct)
+{ received = ct[0]; }
void tst_QObject::customTypes()
{
@@ -4657,6 +4606,21 @@ void tst_QObject::customTypesPointer()
QCOMPARE(qRegisterMetaType<CustomType>("CustomType"), idx);
QCOMPARE(QMetaType::type("CustomType"), idx);
QVERIFY(QMetaType::isRegistered(idx));
+
+ // Test auto registered type (QList<CustomType>)
+ QList<CustomType> list;
+ QCOMPARE(instanceCount, 4);
+ list.append(t1);
+ QCOMPARE(instanceCount, 5);
+ QVERIFY(connect(&checker, &QCustomTypeChecker::signal2,
+ &checker, &QCustomTypeChecker::slot2, Qt::QueuedConnection));
+ emit checker.signal2(list);
+ QCOMPARE(instanceCount, 5); //because the list is implicitly shared.
+ list.clear();
+ QCOMPARE(instanceCount, 5);
+ QCoreApplication::processEvents();
+ QCOMPARE(checker.received.value(), t1.value());
+ QCOMPARE(instanceCount, 4);
}
QCOMPARE(instanceCount, 3);
}
@@ -5535,6 +5499,72 @@ void tst_QObject::connectVirtualSlots()
*/
}
+#ifndef QT_BUILD_INTERNAL
+void tst_QObject::connectPrivateSlots()
+{QSKIP("Needs QT_BUILD_INTERNAL");}
+#else
+class ConnectToPrivateSlotPrivate;
+
+class ConnectToPrivateSlot :public QObject {
+ Q_OBJECT
+public:
+ ConnectToPrivateSlot();
+ void test(SenderObject *obj1) ;
+ Q_DECLARE_PRIVATE(ConnectToPrivateSlot)
+};
+
+class ConnectToPrivateSlotPrivate : public QObjectPrivate {
+public:
+ Q_DECLARE_PUBLIC(ConnectToPrivateSlot)
+ int receivedCount;
+ QVariant receivedValue;
+
+ void thisIsAPrivateSlot() {
+ receivedCount++;
+ };
+
+ void thisIsAPrivateSlotWithArg(const QVariant &v) {
+ receivedCount++;
+ receivedValue = v;
+ };
+};
+
+ConnectToPrivateSlot::ConnectToPrivateSlot(): QObject(*new ConnectToPrivateSlotPrivate) {}
+
+void ConnectToPrivateSlot::test(SenderObject* obj1) {
+ Q_D(ConnectToPrivateSlot);
+ d->receivedCount = 0;
+ QVERIFY(QObjectPrivate::connect(obj1, &SenderObject::signal1, d, &ConnectToPrivateSlotPrivate::thisIsAPrivateSlot));
+ QVERIFY(QObjectPrivate::connect(obj1, &SenderObject::signal7, d, &ConnectToPrivateSlotPrivate::thisIsAPrivateSlotWithArg));
+ QCOMPARE(d->receivedCount, 0);
+ obj1->signal1();
+ QCOMPARE(d->receivedCount, 1);
+ QCOMPARE(d->receivedValue, QVariant());
+ obj1->signal7(666, QLatin1Literal("_"));
+ QCOMPARE(d->receivedCount, 2);
+ QCOMPARE(d->receivedValue, QVariant(666));
+ QVERIFY(QObjectPrivate::connect(obj1, &SenderObject::signal2, d, &ConnectToPrivateSlotPrivate::thisIsAPrivateSlot, Qt::UniqueConnection));
+ QVERIFY(!QObjectPrivate::connect(obj1, &SenderObject::signal2, d, &ConnectToPrivateSlotPrivate::thisIsAPrivateSlot, Qt::UniqueConnection));
+ obj1->signal2();
+ QCOMPARE(d->receivedCount, 3);
+ QVERIFY(QObjectPrivate::disconnect(obj1, &SenderObject::signal2, d, &ConnectToPrivateSlotPrivate::thisIsAPrivateSlot));
+ obj1->signal2();
+ QCOMPARE(d->receivedCount, 3);
+ QVERIFY(!QObjectPrivate::disconnect(obj1, &SenderObject::signal2, d, &ConnectToPrivateSlotPrivate::thisIsAPrivateSlot));
+}
+
+void tst_QObject::connectPrivateSlots()
+{
+ SenderObject sender;
+ {
+ ConnectToPrivateSlot o;
+ o.test(&sender);
+ }
+ sender.signal7(777, QLatin1String("check that deleting the object properly disconnected"));
+ sender.signal1();
+}
+#endif
+
struct SlotFunctor
{
void operator()() {}
@@ -5570,6 +5600,131 @@ void tst_QObject::connectFunctorArgDifference()
QVERIFY(true);
}
+struct ComplexFunctor {
+ ComplexFunctor(int &overload, QList<QVariant> &result) : overload(overload), result(result) {}
+ void operator()(int a, int b) {
+ overload = 1;
+ result << a << b;
+ }
+ void operator()(double a, double b) {
+ overload = 2;
+ result << a << b;
+ }
+ void operator()(const QString &s) {
+ overload = 3;
+ result << s;
+ }
+ void operator()(const QString &) const {
+ Q_ASSERT(!"Should not be called because the non-const one should");
+ overload = -1;
+ }
+ template<typename T1, typename T2, typename T3, typename T4>
+ void operator()(const T1 &t1, const T2 &t2, const T3 &t3, const T4 &t4) {
+ overload = 4;
+ result << QVariant::fromValue(t1) << QVariant::fromValue(t2) << QVariant::fromValue(t3) << QVariant::fromValue(t4);
+ }
+ int &overload;
+ QList<QVariant> &result;
+protected:
+ void operator()() const {
+ Q_ASSERT(!"Should not be called because it is protected");
+ overload = -1;
+ }
+};
+
+struct ComplexFunctorDeriv : ComplexFunctor {
+ ComplexFunctorDeriv(int &overload, QList<QVariant> &result) : ComplexFunctor(overload, result) {}
+
+ void operator()() const {
+ overload = 10;
+ }
+ void operator()(int a, int b) {
+ overload = 11;
+ result << a << b;
+ }
+ using ComplexFunctor::operator();
+private:
+ void operator()(int) {
+ Q_ASSERT(!"Should not be called because it is private");
+ overload = -1;
+ }
+};
+
+class FunctorArgDifferenceObject : public QObject
+{
+ Q_OBJECT
+signals:
+ void signal_ii(int,int);
+ void signal_iiS(int,int, const QString &);
+ void signal_dd(double,double);
+ void signal_ddS(double,double, const QString &);
+ void signal_S(const QString &);
+ void signal_SSSS(const QString &, const QString &, const QString &, const QString &);
+ void signal_iiSS(int, int, const QString &, const QString &);
+ void signal_VV(const QVariant &, const QVariant &);
+};
+
+template<typename Functor, typename Signal>
+void connectFunctorOverload_impl(Signal signal, int expOverload, QList<QVariant> expResult)
+{
+ FunctorArgDifferenceObject obj;
+ int overload;
+ QList<QVariant> result;
+ QVERIFY(QObject::connect(&obj, signal, Functor(overload, result)));
+
+ obj.signal_ii(1,2);
+ obj.signal_iiS(3,4,"5");
+ obj.signal_dd(6.6,7.7);
+ obj.signal_ddS(8.8,9.9,"10");
+ obj.signal_S("11");
+ obj.signal_SSSS("12", "13", "14", "15");
+ obj.signal_iiSS(16, 17, "18", "19");
+ obj.signal_VV(20,21);
+
+ QCOMPARE(overload, expOverload);
+ QCOMPARE(result, expResult);
+}
+
+void tst_QObject::connectFunctorOverloads()
+{
+#if defined (Q_COMPILER_DECLTYPE) && defined (Q_COMPILER_VARIADIC_TEMPLATES)
+ connectFunctorOverload_impl<ComplexFunctor>(&FunctorArgDifferenceObject::signal_ii, 1,
+ (QList<QVariant>() << 1 << 2));
+ connectFunctorOverload_impl<ComplexFunctor>(&FunctorArgDifferenceObject::signal_iiS, 1,
+ (QList<QVariant>() << 3 << 4));
+ connectFunctorOverload_impl<ComplexFunctor>(&FunctorArgDifferenceObject::signal_dd, 2,
+ (QList<QVariant>() << 6.6 << 7.7));
+ connectFunctorOverload_impl<ComplexFunctor>(&FunctorArgDifferenceObject::signal_ddS, 2,
+ (QList<QVariant>() << 8.8 << 9.9));
+ connectFunctorOverload_impl<ComplexFunctor>(&FunctorArgDifferenceObject::signal_S, 3,
+ (QList<QVariant>() << QString("11")));
+ connectFunctorOverload_impl<ComplexFunctor>(&FunctorArgDifferenceObject::signal_SSSS, 4,
+ (QList<QVariant>() << QString("12") << QString("13") << QString("14") << QString("15")));
+ connectFunctorOverload_impl<ComplexFunctor>(&FunctorArgDifferenceObject::signal_iiSS, 4,
+ (QList<QVariant>() << 16 << 17 << QString("18") << QString("19")));
+ connectFunctorOverload_impl<ComplexFunctorDeriv>(&FunctorArgDifferenceObject::signal_ii, 11,
+ (QList<QVariant>() << 1 << 2));
+ connectFunctorOverload_impl<ComplexFunctorDeriv>(&FunctorArgDifferenceObject::signal_iiS, 11,
+ (QList<QVariant>() << 3 << 4));
+ connectFunctorOverload_impl<ComplexFunctorDeriv>(&FunctorArgDifferenceObject::signal_dd, 2,
+ (QList<QVariant>() << 6.6 << 7.7));
+ connectFunctorOverload_impl<ComplexFunctorDeriv>(&FunctorArgDifferenceObject::signal_ddS, 2,
+ (QList<QVariant>() << 8.8 << 9.9));
+ connectFunctorOverload_impl<ComplexFunctorDeriv>(&FunctorArgDifferenceObject::signal_S, 3,
+ (QList<QVariant>() << QString("11")));
+ connectFunctorOverload_impl<ComplexFunctorDeriv>(&FunctorArgDifferenceObject::signal_SSSS, 4,
+ (QList<QVariant>() << QString("12") << QString("13") << QString("14") << QString("15")));
+ connectFunctorOverload_impl<ComplexFunctorDeriv>(&FunctorArgDifferenceObject::signal_iiSS, 4,
+ (QList<QVariant>() << 16 << 17 << QString("18") << QString("19")));
+ connectFunctorOverload_impl<ComplexFunctorDeriv>(&FunctorArgDifferenceObject::signal_VV, 10,
+ (QList<QVariant>()));
+
+
+#else
+ QSKIP("Does not compile without C++11 variadic template");
+#endif
+}
+
static int countedStructObjectsCount = 0;
struct CountedStruct
{
diff --git a/tests/auto/corelib/kernel/qpointer/tst_qpointer.cpp b/tests/auto/corelib/kernel/qpointer/tst_qpointer.cpp
index 7c6549364f..609b4b7dce 100644
--- a/tests/auto/corelib/kernel/qpointer/tst_qpointer.cpp
+++ b/tests/auto/corelib/kernel/qpointer/tst_qpointer.cpp
@@ -65,6 +65,7 @@ private slots:
void threadSafety();
void qvariantCast();
+ void constPointer();
};
void tst_QPointer::constructors()
@@ -384,6 +385,12 @@ void tst_QPointer::qvariantCast()
// QPointer<int> sop = qPointerFromVariant<int>(v);
}
+void tst_QPointer::constPointer()
+{
+ // Compile-time test that QPointer<const T> works.
+ QPointer<const QFile> fp = new QFile;
+ delete fp.data();
+}
QTEST_MAIN(tst_QPointer)
diff --git a/tests/auto/corelib/kernel/qsharedmemory/test/tst_qsharedmemory.cpp b/tests/auto/corelib/kernel/qsharedmemory/test/tst_qsharedmemory.cpp
index 3583c1cab3..ce5e83288f 100644
--- a/tests/auto/corelib/kernel/qsharedmemory/test/tst_qsharedmemory.cpp
+++ b/tests/auto/corelib/kernel/qsharedmemory/test/tst_qsharedmemory.cpp
@@ -748,6 +748,8 @@ void tst_QSharedMemory::simpleProcessProducerConsumer()
{
QFETCH(int, processes);
+ QSKIP("This test is unstable: QTBUG-25655");
+
rememberKey("market");
QProcess producer;
diff --git a/tests/auto/corelib/mimetypes/qmimedatabase/tst_qmimedatabase.cpp b/tests/auto/corelib/mimetypes/qmimedatabase/tst_qmimedatabase.cpp
index 79d8b3dfe4..a90bfadd73 100644
--- a/tests/auto/corelib/mimetypes/qmimedatabase/tst_qmimedatabase.cpp
+++ b/tests/auto/corelib/mimetypes/qmimedatabase/tst_qmimedatabase.cpp
@@ -442,6 +442,8 @@ void tst_QMimeDatabase::mimeTypeForFileWithContent()
txtTempFile.close();
mime = db.mimeTypeForFile(txtTempFileName);
QCOMPARE(mime.name(), QString::fromLatin1("text/plain"));
+ mime = db.mimeTypeForFile(txtTempFileName, QMimeDatabase::MatchContent);
+ QCOMPARE(mime.name(), QString::fromLatin1("application/smil"));
}
// Test what happens with an incorrect path
@@ -714,6 +716,8 @@ void tst_QMimeDatabase::findByData()
QFileInfo info(filePath);
QString mimeForInfo = database.mimeTypeForFile(info, QMimeDatabase::MatchContent).name();
QCOMPARE(mimeForInfo, resultMimeTypeName);
+ QString mimeForFile = database.mimeTypeForFile(filePath, QMimeDatabase::MatchContent).name();
+ QCOMPARE(mimeForFile, resultMimeTypeName);
}
void tst_QMimeDatabase::findByFile_data()
diff --git a/tests/auto/corelib/plugin/qpluginloader/lib/mylib.c b/tests/auto/corelib/plugin/qpluginloader/lib/mylib.c
index 324dce5b0c..a9abe471b1 100644
--- a/tests/auto/corelib/plugin/qpluginloader/lib/mylib.c
+++ b/tests/auto/corelib/plugin/qpluginloader/lib/mylib.c
@@ -53,6 +53,12 @@
# define BORLAND_STDCALL
#endif
+static int pluginVariable = 0xc0ffee;
+LIB_EXPORT int *pointerAddress()
+{
+ return &pluginVariable;
+}
+
LIB_EXPORT int BORLAND_STDCALL version()
{
return 1;
diff --git a/tests/auto/corelib/plugin/qpluginloader/qpluginloader.pro b/tests/auto/corelib/plugin/qpluginloader/qpluginloader.pro
index 5aa7b4805b..0cba19887e 100644
--- a/tests/auto/corelib/plugin/qpluginloader/qpluginloader.pro
+++ b/tests/auto/corelib/plugin/qpluginloader/qpluginloader.pro
@@ -4,7 +4,7 @@ CONFIG += ordered
SUBDIRS = lib \
theplugin \
tst
-!win32: !macx-*: SUBDIRS += almostplugin
+!win32: !mac: SUBDIRS += almostplugin
TARGET = tst_qpluginloader
# no special install rule for subdir
diff --git a/tests/auto/corelib/plugin/qpluginloader/theplugin/theplugin.cpp b/tests/auto/corelib/plugin/qpluginloader/theplugin/theplugin.cpp
index 6abb9b6c20..b26b24f454 100644
--- a/tests/auto/corelib/plugin/qpluginloader/theplugin/theplugin.cpp
+++ b/tests/auto/corelib/plugin/qpluginloader/theplugin/theplugin.cpp
@@ -46,3 +46,9 @@ QString ThePlugin::pluginName() const
{
return QLatin1String("Plugin ok");
}
+
+static int pluginVariable = 0xc0ffee;
+extern "C" Q_DECL_EXPORT int *pointerAddress()
+{
+ return &pluginVariable;
+}
diff --git a/tests/auto/corelib/plugin/qpluginloader/tst_qpluginloader.cpp b/tests/auto/corelib/plugin/qpluginloader/tst_qpluginloader.cpp
index f0be8cf6f1..cef4f53101 100644
--- a/tests/auto/corelib/plugin/qpluginloader/tst_qpluginloader.cpp
+++ b/tests/auto/corelib/plugin/qpluginloader/tst_qpluginloader.cpp
@@ -99,13 +99,19 @@
static QString sys_qualifiedLibraryName(const QString &fileName)
{
- return QFINDTESTDATA(QString("bin/%1%2%3").arg(PREFIX).arg(fileName).arg(SUFFIX));
+ QString libname = QFINDTESTDATA(QString("bin/%1%2%3").arg(PREFIX).arg(fileName).arg(SUFFIX));
+ QFileInfo fi(libname);
+ if (fi.exists())
+ return fi.canonicalFilePath();
+ return libname;
}
QT_FORWARD_DECLARE_CLASS(QPluginLoader)
class tst_QPluginLoader : public QObject
{
Q_OBJECT
+public slots:
+ void cleanup();
private slots:
void errorString();
void loadHints();
@@ -117,8 +123,25 @@ private slots:
#endif
void relativePath();
void reloadPlugin();
+ void preloadedPlugin_data();
+ void preloadedPlugin();
};
+void tst_QPluginLoader::cleanup()
+{
+ // check if the library/plugin was leaked
+ // we can't use QPluginLoader::isLoaded here because on some platforms the plugin is always loaded by QPluginLoader.
+ // Also, if this test fails once, it will keep on failing because we can't force the unload,
+ // so we report it only once.
+ static bool failedAlready = false;
+ if (!failedAlready) {
+ QLibrary lib(sys_qualifiedLibraryName("theplugin"));
+ failedAlready = true;
+ QVERIFY2(!lib.isLoaded(), "Plugin was leaked - will not check again");
+ failedAlready = false;
+ }
+}
+
void tst_QPluginLoader::errorString()
{
#if defined(Q_OS_WINCE)
@@ -334,6 +357,50 @@ void tst_QPluginLoader::reloadPlugin()
PluginInterface *instance2 = qobject_cast<PluginInterface*>(loader.instance());
QVERIFY(instance2);
QCOMPARE(instance2->pluginName(), QLatin1String("Plugin ok"));
+
+ QVERIFY(loader.unload());
+}
+
+void tst_QPluginLoader::preloadedPlugin_data()
+{
+ QTest::addColumn<bool>("doLoad");
+ QTest::addColumn<QString>("libname");
+ QTest::newRow("create-plugin") << false << sys_qualifiedLibraryName("theplugin");
+ QTest::newRow("load-plugin") << true << sys_qualifiedLibraryName("theplugin");
+ QTest::newRow("create-non-plugin") << false << sys_qualifiedLibraryName("tst_qpluginloaderlib");
+ QTest::newRow("load-non-plugin") << true << sys_qualifiedLibraryName("tst_qpluginloaderlib");
+}
+
+void tst_QPluginLoader::preloadedPlugin()
+{
+ // check that using QPluginLoader does not interfere with QLibrary
+ QFETCH(QString, libname);
+ QLibrary lib(libname);
+ QVERIFY(lib.load());
+
+ typedef int *(*pf_t)();
+ pf_t pf = (pf_t)lib.resolve("pointerAddress");
+ QVERIFY(pf);
+
+ int *pluginVariable = pf();
+ QVERIFY(pluginVariable);
+ QCOMPARE(*pluginVariable, 0xc0ffee);
+
+ {
+ // load the plugin
+ QPluginLoader loader(libname);
+ QFETCH(bool, doLoad);
+ if (doLoad && loader.load()) {
+ // unload() returns false because QLibrary has it loaded
+ QVERIFY(!loader.unload());
+ }
+ }
+
+ QVERIFY(lib.isLoaded());
+
+ // if the library was unloaded behind our backs, the following will crash:
+ QCOMPARE(*pluginVariable, 0xc0ffee);
+ QVERIFY(lib.unload());
}
QTEST_MAIN(tst_QPluginLoader)
diff --git a/tests/auto/corelib/plugin/quuid/testProcessUniqueness/main.cpp b/tests/auto/corelib/plugin/quuid/testProcessUniqueness/main.cpp
index 651fa3b1db..21e067bc73 100644
--- a/tests/auto/corelib/plugin/quuid/testProcessUniqueness/main.cpp
+++ b/tests/auto/corelib/plugin/quuid/testProcessUniqueness/main.cpp
@@ -47,7 +47,7 @@ int main(int argc, char **argv)
{
Q_UNUSED(argc)
Q_UNUSED(argv)
-
+
// First, break QUuid.
qrand();
diff --git a/tests/auto/corelib/statemachine/qstate/tst_qstate.cpp b/tests/auto/corelib/statemachine/qstate/tst_qstate.cpp
index 9d7bbd4f5c..ae32731cbc 100644
--- a/tests/auto/corelib/statemachine/qstate/tst_qstate.cpp
+++ b/tests/auto/corelib/statemachine/qstate/tst_qstate.cpp
@@ -77,7 +77,7 @@ public:
public slots:
void slot() { called = true; }
-
+
};
void tst_QState::assignProperty()
@@ -89,7 +89,7 @@ void tst_QState::assignProperty()
QState *s1 = new QState(&machine);
s1->assignProperty(object, "fooBar", 20);
-
+
machine.setInitialState(s1);
machine.start();
QCoreApplication::processEvents();
@@ -107,7 +107,7 @@ void tst_QState::assignPropertyTwice()
QState *s1 = new QState(&machine);
s1->assignProperty(object, "fooBar", 20);
s1->assignProperty(object, "fooBar", 30);
-
+
machine.setInitialState(s1);
machine.start();
QCoreApplication::processEvents();
@@ -118,7 +118,7 @@ void tst_QState::assignPropertyTwice()
class EventTestTransition: public QAbstractTransition
{
public:
- EventTestTransition(QEvent::Type type, QState *targetState)
+ EventTestTransition(QEvent::Type type, QState *targetState)
: QAbstractTransition(), m_type(type)
{
setTargetState(targetState);
@@ -134,18 +134,18 @@ protected:
private:
QEvent::Type m_type;
-
+
};
-void tst_QState::historyInitialState()
+void tst_QState::historyInitialState()
{
QStateMachine machine;
QState *s1 = new QState(&machine);
-
+
QState *s2 = new QState(&machine);
QHistoryState *h1 = new QHistoryState(s2);
-
+
s2->setInitialState(h1);
QState *s3 = new QState(s2);
diff --git a/tests/auto/corelib/thread/qfuture/tst_qfuture.cpp b/tests/auto/corelib/thread/qfuture/tst_qfuture.cpp
index c9a41b29f8..c86befdf1b 100644
--- a/tests/auto/corelib/thread/qfuture/tst_qfuture.cpp
+++ b/tests/auto/corelib/thread/qfuture/tst_qfuture.cpp
@@ -243,13 +243,13 @@ void tst_QFuture::resultStore()
store.addResult(2, &int2); // add result at index 2
QCOMPARE(store.contains(2), false); // but 1 is missing, so this 2 won't be reported yet.
- store.addResult(1, &int1);
+ store.addResult(1, &int1);
QCOMPARE(store.contains(1), true);
QCOMPARE(store.contains(2), true); // 2 should be visible now.
- store.addResult(4, &int0);
- store.addResult(5, &int0);
- store.addResult(7, &int0);
+ store.addResult(4, &int0);
+ store.addResult(5, &int0);
+ store.addResult(7, &int0);
QCOMPARE(store.contains(4), false);
QCOMPARE(store.contains(5), false);
QCOMPARE(store.contains(7), false);
@@ -273,9 +273,9 @@ void tst_QFuture::resultStore()
store.addResult(0, &int0);
QCOMPARE(store.contains(0), true);
-
+
store.addResult(2, &int0);
- QCOMPARE(store.contains(2), false);
+ QCOMPARE(store.contains(2), false);
store.addCanceledResult(1); // report no result at 1
@@ -289,7 +289,7 @@ void tst_QFuture::resultStore()
store.addResult(6, &int0);
store.addResult(7, &int0);
QCOMPARE(store.contains(3), false);
-
+
store.addCanceledResult(4);
store.addCanceledResult(5);
@@ -311,10 +311,10 @@ void tst_QFuture::resultStore()
store.addResult(0, &int0);
QCOMPARE(store.count(), 1); // result 0 becomes available
QCOMPARE(store.contains(0), true);
-
+
store.addResult(2, &int0);
QCOMPARE(store.count(), 1);
- QCOMPARE(store.contains(2), false);
+ QCOMPARE(store.contains(2), false);
store.addCanceledResult(1);
QCOMPARE(store.count(), 2); // result 2 is renamed to 1 and becomes available
@@ -332,7 +332,7 @@ void tst_QFuture::resultStore()
store.addResult(7, &int0);
QCOMPARE(store.count(), 3);
QCOMPARE(store.contains(3), false);
-
+
store.addCanceledResult(4);
store.addCanceledResult(5);
QCOMPARE(store.count(), 5); // 6 and 7 is renamed to 3 and 4 and becomes available
@@ -347,13 +347,13 @@ void tst_QFuture::resultStore()
QCOMPARE(store.contains(6), false);
QCOMPARE(store.contains(7), false);
}
-
+
{
// test resultCount in non-filtered mode. It should always be possible
// to iterate through the results 0 to resultCount.
QtPrivate::ResultStore<int> store;
store.addResult(0, &int0);
-
+
QCOMPARE(store.count(), 1);
store.addResult(2, &int0);
@@ -440,7 +440,7 @@ void tst_QFuture::resultStore()
store.addCanceledResults(0, 3);
QCOMPARE(store.count(), 2); // results at 3 and 4 become available at index 0, 1
- store.addResult(5, &int0);
+ store.addResult(5, &int0);
QCOMPARE(store.count(), 3);// result 5 becomes available at index 2
}
@@ -1112,9 +1112,9 @@ void tst_QFuture::iterators()
for (int i = 0; i < resultCount; ++i) {
e.reportResult(i);
}
-
+
e.reportFinished();
-
+
{
QFutureIterator<int> it(f);
QFutureIterator<int> it2(it);
@@ -1122,7 +1122,7 @@ void tst_QFuture::iterators()
{
QFutureIterator<int> it(f);
-
+
for (int i = 0; i < resultCount - 1; ++i) {
QVERIFY(it.hasNext());
QCOMPARE(it.peekNext(), i);
diff --git a/tests/auto/corelib/thread/qfuturewatcher/tst_qfuturewatcher.cpp b/tests/auto/corelib/thread/qfuturewatcher/tst_qfuturewatcher.cpp
index 467dd4b348..b2b0eace34 100644
--- a/tests/auto/corelib/thread/qfuturewatcher/tst_qfuturewatcher.cpp
+++ b/tests/auto/corelib/thread/qfuturewatcher/tst_qfuturewatcher.cpp
@@ -797,7 +797,7 @@ public:
ResultReadyTester(QFutureWatcher<int> *watcher)
:m_watcher(watcher), filter(false), ok(true), count(0)
{
-
+
}
public slots:
void resultReadyAt(int index)
@@ -834,7 +834,7 @@ void tst_QFutureWatcher::incrementalMapResults()
connect(&watcher, SIGNAL(resultReadyAt(int)), &resultReadyTester, SLOT(resultReadyAt(int)));
const int count = 10000;
- QList<int> ints;
+ QList<int> ints;
for (int i = 0; i < count; ++i)
ints << i;
@@ -846,7 +846,7 @@ void tst_QFutureWatcher::incrementalMapResults()
QCOMPARE(resultReadyTester.count, count);
QVERIFY(resultReadyTester.ok);
QVERIFY(watcher.isFinished());
- future.waitForFinished();
+ future.waitForFinished();
}
bool filterer(int i)
@@ -873,7 +873,7 @@ void tst_QFutureWatcher::incrementalFilterResults()
connect(&watcher, SIGNAL(resultReadyAt(int)), &resultReadyTester, SLOT(resultReadyAt(int)));
const int count = 10000;
- QList<int> ints;
+ QList<int> ints;
for (int i = 0; i < count; ++i)
ints << i;
@@ -885,12 +885,12 @@ void tst_QFutureWatcher::incrementalFilterResults()
QCOMPARE(resultReadyTester.count, count / 2);
QVERIFY(resultReadyTester.ok);
QVERIFY(watcher.isFinished());
- future.waitForFinished();
+ future.waitForFinished();
}
void tst_QFutureWatcher::qfutureSynchronizer()
{
- int taskCount = 1000;
+ int taskCount = 1000;
QTime t;
t.start();
diff --git a/tests/auto/corelib/thread/qthread/tst_qthread.cpp b/tests/auto/corelib/thread/qthread/tst_qthread.cpp
index e6d824be96..1ee628dde5 100644
--- a/tests/auto/corelib/thread/qthread/tst_qthread.cpp
+++ b/tests/auto/corelib/thread/qthread/tst_qthread.cpp
@@ -1026,7 +1026,7 @@ void tst_QThread::exitAndExec()
thread.sem2.acquire();
int v = thread.value;
QCOMPARE(v, 556);
-
+
//test that the thread is running by executing queued connected signal there
Syncronizer sync1;
sync1.moveToThread(&thread);
@@ -1221,9 +1221,9 @@ QT_END_NAMESPACE
class DummyEventDispatcher : public QAbstractEventDispatcher {
public:
- DummyEventDispatcher() : QAbstractEventDispatcher(), visited(false) {}
+ DummyEventDispatcher() : QAbstractEventDispatcher() {}
bool processEvents(QEventLoop::ProcessEventsFlags) {
- visited = true;
+ visited.store(true);
emit awake();
QCoreApplication::sendPostedEvents();
return false;
@@ -1247,7 +1247,7 @@ public:
void unregisterEventNotifier(QWinEventNotifier *) { }
#endif
- bool visited;
+ QBasicAtomicInt visited; // bool
};
class ThreadObj : public QObject
@@ -1285,7 +1285,7 @@ void tst_QThread::customEventDispatcher()
QMetaObject::invokeMethod(&obj, "visit", Qt::QueuedConnection);
loop.exec();
// test that the ED has really been used
- QVERIFY(ed->visited);
+ QVERIFY(ed->visited.load());
QPointer<DummyEventDispatcher> weak_ed(ed);
QVERIFY(!weak_ed.isNull());
diff --git a/tests/auto/corelib/thread/qthreadonce/qthreadonce.h b/tests/auto/corelib/thread/qthreadonce/qthreadonce.h
index eff7924410..5e04a16bb9 100644
--- a/tests/auto/corelib/thread/qthreadonce/qthreadonce.h
+++ b/tests/auto/corelib/thread/qthreadonce/qthreadonce.h
@@ -46,8 +46,6 @@
#include <QtCore/qglobal.h>
#include <QtCore/qatomic.h>
-QT_BEGIN_HEADER
-
#ifndef QT_NO_THREAD
@@ -108,6 +106,4 @@ public:
#endif // QT_NO_THREAD
-QT_END_HEADER
-
#endif
diff --git a/tests/auto/corelib/thread/qthreadpool/tst_qthreadpool.cpp b/tests/auto/corelib/thread/qthreadpool/tst_qthreadpool.cpp
index a586f81ccc..a93a94a470 100644
--- a/tests/auto/corelib/thread/qthreadpool/tst_qthreadpool.cpp
+++ b/tests/auto/corelib/thread/qthreadpool/tst_qthreadpool.cpp
@@ -64,6 +64,12 @@ QRunnable *createTask(FunctionPointer pointer)
class tst_QThreadPool : public QObject
{
Q_OBJECT
+public:
+ tst_QThreadPool();
+ ~tst_QThreadPool();
+
+ static QMutex *functionTestMutex;
+
private slots:
void runFunction();
void createThreadRunFunction();
@@ -92,8 +98,24 @@ private slots:
void waitForDoneTimeout();
void destroyingWaitsForTasksToFinish();
void stressTest();
+
+private:
+ QMutex m_functionTestMutex;
};
+
+QMutex *tst_QThreadPool::functionTestMutex = 0;
+
+tst_QThreadPool::tst_QThreadPool()
+{
+ tst_QThreadPool::functionTestMutex = &m_functionTestMutex;
+}
+
+tst_QThreadPool::~tst_QThreadPool()
+{
+ tst_QThreadPool::functionTestMutex = 0;
+}
+
int testFunctionCount;
void sleepTestFunction()
@@ -114,19 +136,19 @@ void noSleepTestFunction()
void sleepTestFunctionMutex()
{
- static QMutex testMutex;
+ Q_ASSERT(tst_QThreadPool::functionTestMutex);
QTest::qSleep(1000);
- testMutex.lock();
+ tst_QThreadPool::functionTestMutex->lock();
++testFunctionCount;
- testMutex.unlock();
+ tst_QThreadPool::functionTestMutex->unlock();
}
void noSleepTestFunctionMutex()
{
- static QMutex testMutex;
- testMutex.lock();
+ Q_ASSERT(tst_QThreadPool::functionTestMutex);
+ tst_QThreadPool::functionTestMutex->lock();
++testFunctionCount;
- testMutex.unlock();
+ tst_QThreadPool::functionTestMutex->unlock();
}
void tst_QThreadPool::runFunction()
@@ -761,7 +783,7 @@ void tst_QThreadPool::waitForDoneTimeout()
public:
QMutex mutex;
BlockedTask() { setAutoDelete(false); }
-
+
void run()
{
mutex.lock();
diff --git a/tests/auto/corelib/tools/qchar/tst_qchar.cpp b/tests/auto/corelib/tools/qchar/tst_qchar.cpp
index 478747bf15..c89d553112 100644
--- a/tests/auto/corelib/tools/qchar/tst_qchar.cpp
+++ b/tests/auto/corelib/tools/qchar/tst_qchar.cpp
@@ -709,40 +709,40 @@ void tst_QChar::lineBreakClass()
void tst_QChar::script()
{
- QVERIFY(QUnicodeTables::script(0x0020u) == QUnicodeTables::Common);
- QVERIFY(QUnicodeTables::script(0x0041u) == QUnicodeTables::Common); // ### Latin
- QVERIFY(QUnicodeTables::script(0x0375u) == QUnicodeTables::Greek);
- QVERIFY(QUnicodeTables::script(0x0400u) == QUnicodeTables::Cyrillic);
- QVERIFY(QUnicodeTables::script(0x0531u) == QUnicodeTables::Armenian);
- QVERIFY(QUnicodeTables::script(0x0591u) == QUnicodeTables::Hebrew);
- QVERIFY(QUnicodeTables::script(0x0600u) == QUnicodeTables::Arabic);
- QVERIFY(QUnicodeTables::script(0x0700u) == QUnicodeTables::Syriac);
- QVERIFY(QUnicodeTables::script(0x0780u) == QUnicodeTables::Thaana);
- QVERIFY(QUnicodeTables::script(0x07c0u) == QUnicodeTables::Nko);
- QVERIFY(QUnicodeTables::script(0x0900u) == QUnicodeTables::Devanagari);
- QVERIFY(QUnicodeTables::script(0x0981u) == QUnicodeTables::Bengali);
- QVERIFY(QUnicodeTables::script(0x0a01u) == QUnicodeTables::Gurmukhi);
- QVERIFY(QUnicodeTables::script(0x0a81u) == QUnicodeTables::Gujarati);
- QVERIFY(QUnicodeTables::script(0x0b01u) == QUnicodeTables::Oriya);
- QVERIFY(QUnicodeTables::script(0x0b82u) == QUnicodeTables::Tamil);
- QVERIFY(QUnicodeTables::script(0x0c01u) == QUnicodeTables::Telugu);
- QVERIFY(QUnicodeTables::script(0x0c82u) == QUnicodeTables::Kannada);
- QVERIFY(QUnicodeTables::script(0x0d02u) == QUnicodeTables::Malayalam);
- QVERIFY(QUnicodeTables::script(0x0d82u) == QUnicodeTables::Sinhala);
- QVERIFY(QUnicodeTables::script(0x0e01u) == QUnicodeTables::Thai);
- QVERIFY(QUnicodeTables::script(0x0e81u) == QUnicodeTables::Lao);
- QVERIFY(QUnicodeTables::script(0x0f00u) == QUnicodeTables::Tibetan);
- QVERIFY(QUnicodeTables::script(0x1000u) == QUnicodeTables::Myanmar);
- QVERIFY(QUnicodeTables::script(0x10a0u) == QUnicodeTables::Georgian);
- QVERIFY(QUnicodeTables::script(0x1100u) == QUnicodeTables::Hangul);
- QVERIFY(QUnicodeTables::script(0x1680u) == QUnicodeTables::Ogham);
- QVERIFY(QUnicodeTables::script(0x16a0u) == QUnicodeTables::Runic);
- QVERIFY(QUnicodeTables::script(0x1780u) == QUnicodeTables::Khmer);
- QVERIFY(QUnicodeTables::script(0x200cu) == QUnicodeTables::Inherited);
- QVERIFY(QUnicodeTables::script(0x200du) == QUnicodeTables::Inherited);
- QVERIFY(QUnicodeTables::script(0x1018au) == QUnicodeTables::Greek);
- QVERIFY(QUnicodeTables::script(0x1f130u) == QUnicodeTables::Common);
- QVERIFY(QUnicodeTables::script(0xe0100u) == QUnicodeTables::Inherited);
+ QVERIFY(QChar::script(0x0020u) == QChar::Script_Common);
+ QVERIFY(QChar::script(0x0041u) == QChar::Script_Latin);
+ QVERIFY(QChar::script(0x0375u) == QChar::Script_Greek);
+ QVERIFY(QChar::script(0x0400u) == QChar::Script_Cyrillic);
+ QVERIFY(QChar::script(0x0531u) == QChar::Script_Armenian);
+ QVERIFY(QChar::script(0x0591u) == QChar::Script_Hebrew);
+ QVERIFY(QChar::script(0x0600u) == QChar::Script_Arabic);
+ QVERIFY(QChar::script(0x0700u) == QChar::Script_Syriac);
+ QVERIFY(QChar::script(0x0780u) == QChar::Script_Thaana);
+ QVERIFY(QChar::script(0x07c0u) == QChar::Script_Nko);
+ QVERIFY(QChar::script(0x0900u) == QChar::Script_Devanagari);
+ QVERIFY(QChar::script(0x0981u) == QChar::Script_Bengali);
+ QVERIFY(QChar::script(0x0a01u) == QChar::Script_Gurmukhi);
+ QVERIFY(QChar::script(0x0a81u) == QChar::Script_Gujarati);
+ QVERIFY(QChar::script(0x0b01u) == QChar::Script_Oriya);
+ QVERIFY(QChar::script(0x0b82u) == QChar::Script_Tamil);
+ QVERIFY(QChar::script(0x0c01u) == QChar::Script_Telugu);
+ QVERIFY(QChar::script(0x0c82u) == QChar::Script_Kannada);
+ QVERIFY(QChar::script(0x0d02u) == QChar::Script_Malayalam);
+ QVERIFY(QChar::script(0x0d82u) == QChar::Script_Sinhala);
+ QVERIFY(QChar::script(0x0e01u) == QChar::Script_Thai);
+ QVERIFY(QChar::script(0x0e81u) == QChar::Script_Lao);
+ QVERIFY(QChar::script(0x0f00u) == QChar::Script_Tibetan);
+ QVERIFY(QChar::script(0x1000u) == QChar::Script_Myanmar);
+ QVERIFY(QChar::script(0x10a0u) == QChar::Script_Georgian);
+ QVERIFY(QChar::script(0x1100u) == QChar::Script_Hangul);
+ QVERIFY(QChar::script(0x1680u) == QChar::Script_Ogham);
+ QVERIFY(QChar::script(0x16a0u) == QChar::Script_Runic);
+ QVERIFY(QChar::script(0x1780u) == QChar::Script_Khmer);
+ QVERIFY(QChar::script(0x200cu) == QChar::Script_Inherited);
+ QVERIFY(QChar::script(0x200du) == QChar::Script_Inherited);
+ QVERIFY(QChar::script(0x1018au) == QChar::Script_Greek);
+ QVERIFY(QChar::script(0x1f130u) == QChar::Script_Common);
+ QVERIFY(QChar::script(0xe0100u) == QChar::Script_Inherited);
}
void tst_QChar::normalization_data()
diff --git a/tests/auto/corelib/tools/qcryptographichash/tst_qcryptographichash.cpp b/tests/auto/corelib/tools/qcryptographichash/tst_qcryptographichash.cpp
index 5ba2f2920a..de252a5d5e 100644
--- a/tests/auto/corelib/tools/qcryptographichash/tst_qcryptographichash.cpp
+++ b/tests/auto/corelib/tools/qcryptographichash/tst_qcryptographichash.cpp
@@ -52,6 +52,7 @@ private slots:
void intermediary_result_data();
void intermediary_result();
void sha1();
+ void sha3();
void files_data();
void files();
};
@@ -118,6 +119,23 @@ void tst_QCryptographicHash::intermediary_result_data()
<< QByteArray("abc") << QByteArray("abc")
<< QByteArray::fromHex("DDAF35A193617ABACC417349AE20413112E6FA4E89A97EA20A9EEEE64B55D39A2192992A274FC1A836BA3C23A3FEEBBD454D4423643CE80E2A9AC94FA54CA49F")
<< QByteArray::fromHex("F3C41E7B63EE869596FC28BAD64120612C520F65928AB4D126C72C6998B551B8FF1CEDDFED4373E6717554DC89D1EEE6F0AB22FD3675E561ABA9AE26A3EEC53B");
+
+ QTest::newRow("sha3_224") << int(QCryptographicHash::Sha3_224)
+ << QByteArray("abc") << QByteArray("abc")
+ << QByteArray::fromHex("C30411768506EBE1C2871B1EE2E87D38DF342317300A9B97A95EC6A8")
+ << QByteArray::fromHex("048330E7C7C8B4A41AB713B3A6F958D77B8CF3EE969930F1584DD550");
+ QTest::newRow("sha3_256") << int(QCryptographicHash::Sha3_256)
+ << QByteArray("abc") << QByteArray("abc")
+ << QByteArray::fromHex("4E03657AEA45A94FC7D47BA826C8D667C0D1E6E33A64A036EC44F58FA12D6C45")
+ << QByteArray::fromHex("9F0ADAD0A59B05D2E04A1373342B10B9EB16C57C164C8A3BFCBF46DCCEE39A21");
+ QTest::newRow("sha3_384") << int(QCryptographicHash::Sha3_384)
+ << QByteArray("abc") << QByteArray("abc")
+ << QByteArray::fromHex("F7DF1165F033337BE098E7D288AD6A2F74409D7A60B49C36642218DE161B1F99F8C681E4AFAF31A34DB29FB763E3C28E")
+ << QByteArray::fromHex("D733B87D392D270889D3DA23AE113F349E25574B445F319CDE4CD3F877C753E9E3C65980421339B3A131457FF393939F");
+ QTest::newRow("sha3_512") << int(QCryptographicHash::Sha3_512)
+ << QByteArray("abc") << QByteArray("abc")
+ << QByteArray::fromHex("18587DC2EA106B9A1563E32B3312421CA164C7F1F07BC922A9C83D77CEA3A1E5D0C69910739025372DC14AC9642629379540C17E2A65B19D77AA511A9D00BB96")
+ << QByteArray::fromHex("A7C392D2A42155761CA76BDDDE1C47D55486B007EDF465397BFB9DFA74D11C8F0D7C86CD29415283F1B5E7F655CEC25B869C9E9C33A8986F0B38542FB12BFB93");
}
void tst_QCryptographicHash::intermediary_result()
@@ -151,22 +169,71 @@ void tst_QCryptographicHash::sha1()
// A9993E36 4706816A BA3E2571 7850C26C 9CD0D89D
QCOMPARE(QCryptographicHash::hash("abc", QCryptographicHash::Sha1).toHex().toUpper(),
QByteArray("A9993E364706816ABA3E25717850C26C9CD0D89D"));
-
+
// SHA1("abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq") =
// 84983E44 1C3BD26E BAAE4AA1 F95129E5 E54670F1
QCOMPARE(QCryptographicHash::hash("abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
QCryptographicHash::Sha1).toHex().toUpper(),
QByteArray("84983E441C3BD26EBAAE4AA1F95129E5E54670F1"));
-
+
// SHA1(A million repetitions of "a") =
// 34AA973C D4C4DAA4 F61EEB2B DBAD2731 6534016F
QByteArray as;
for (int i = 0; i < 1000000; ++i)
as += 'a';
- QCOMPARE(QCryptographicHash::hash(as, QCryptographicHash::Sha1).toHex().toUpper(),
+ QCOMPARE(QCryptographicHash::hash(as, QCryptographicHash::Sha1).toHex().toUpper(),
QByteArray("34AA973CD4C4DAA4F61EEB2BDBAD27316534016F"));
}
+void tst_QCryptographicHash::sha3()
+{
+ // SHA3-224("The quick brown fox jumps over the lazy dog")
+ // 10aee6b30c47350576ac2873fa89fd190cdc488442f3ef654cf23fe
+ QCOMPARE(QCryptographicHash::hash("The quick brown fox jumps over the lazy dog",
+ QCryptographicHash::Sha3_224).toHex(),
+ QByteArray("310aee6b30c47350576ac2873fa89fd190cdc488442f3ef654cf23fe"));
+ // SHA3-224("The quick brown fox jumps over the lazy dog.")
+ // c59d4eaeac728671c635ff645014e2afa935bebffdb5fbd207ffdeab
+ QCOMPARE(QCryptographicHash::hash("The quick brown fox jumps over the lazy dog.",
+ QCryptographicHash::Sha3_224).toHex(),
+ QByteArray("c59d4eaeac728671c635ff645014e2afa935bebffdb5fbd207ffdeab"));
+
+ // SHA3-256("The quick brown fox jumps over the lazy dog")
+ // 4d741b6f1eb29cb2a9b9911c82f56fa8d73b04959d3d9d222895df6c0b28aa15
+ QCOMPARE(QCryptographicHash::hash("The quick brown fox jumps over the lazy dog",
+ QCryptographicHash::Sha3_256).toHex(),
+ QByteArray("4d741b6f1eb29cb2a9b9911c82f56fa8d73b04959d3d9d222895df6c0b28aa15"));
+
+ // SHA3-256("The quick brown fox jumps over the lazy dog.")
+ // 578951e24efd62a3d63a86f7cd19aaa53c898fe287d2552133220370240b572d
+ QCOMPARE(QCryptographicHash::hash("The quick brown fox jumps over the lazy dog.",
+ QCryptographicHash::Sha3_256).toHex(),
+ QByteArray("578951e24efd62a3d63a86f7cd19aaa53c898fe287d2552133220370240b572d"));
+
+ // SHA3-384("The quick brown fox jumps over the lazy dog")
+ // 283990fa9d5fb731d786c5bbee94ea4db4910f18c62c03d173fc0a5e494422e8a0b3da7574dae7fa0baf005e504063b3
+ QCOMPARE(QCryptographicHash::hash("The quick brown fox jumps over the lazy dog",
+ QCryptographicHash::Sha3_384).toHex(),
+ QByteArray("283990fa9d5fb731d786c5bbee94ea4db4910f18c62c03d173fc0a5e494422e8a0b3da7574dae7fa0baf005e504063b3"));
+
+ // SHA3-384("The quick brown fox jumps over the lazy dog.")
+ // 9ad8e17325408eddb6edee6147f13856ad819bb7532668b605a24a2d958f88bd5c169e56dc4b2f89ffd325f6006d820b
+ QCOMPARE(QCryptographicHash::hash("The quick brown fox jumps over the lazy dog.",
+ QCryptographicHash::Sha3_384).toHex(),
+ QByteArray("9ad8e17325408eddb6edee6147f13856ad819bb7532668b605a24a2d958f88bd5c169e56dc4b2f89ffd325f6006d820b"));
+
+ // SHA3-512("The quick brown fox jumps over the lazy dog")
+ // d135bb84d0439dbac432247ee573a23ea7d3c9deb2a968eb31d47c4fb45f1ef4422d6c531b5b9bd6f449ebcc449ea94d0a8f05f62130fda612da53c79659f609
+ QCOMPARE(QCryptographicHash::hash("The quick brown fox jumps over the lazy dog",
+ QCryptographicHash::Sha3_512).toHex(),
+ QByteArray("d135bb84d0439dbac432247ee573a23ea7d3c9deb2a968eb31d47c4fb45f1ef4422d6c531b5b9bd6f449ebcc449ea94d0a8f05f62130fda612da53c79659f609"));
+
+ // SHA3-512("The quick brown fox jumps over the lazy dog.")
+ // ab7192d2b11f51c7dd744e7b3441febf397ca07bf812cceae122ca4ded6387889064f8db9230f173f6d1ab6e24b6e50f065b039f799f5592360a6558eb52d760
+ QCOMPARE(QCryptographicHash::hash("The quick brown fox jumps over the lazy dog.",
+ QCryptographicHash::Sha3_512).toHex(),
+ QByteArray("ab7192d2b11f51c7dd744e7b3441febf397ca07bf812cceae122ca4ded6387889064f8db9230f173f6d1ab6e24b6e50f065b039f799f5592360a6558eb52d760"));
+}
Q_DECLARE_METATYPE(QCryptographicHash::Algorithm);
diff --git a/tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp b/tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp
index b1874131d7..b84039f557 100644
--- a/tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp
+++ b/tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp
@@ -145,6 +145,8 @@ private:
QDateTime invalidDateTime() const { return QDateTime(invalidDate(), invalidTime()); }
QDate invalidDate() const { return QDate(); }
QTime invalidTime() const { return QTime(-1, -1, -1); }
+ qint64 minJd() const { return QDateTimePrivate::minJd(); }
+ qint64 maxJd() const { return QDateTimePrivate::maxJd(); }
};
Q_DECLARE_METATYPE(Qt::TimeSpec)
@@ -462,14 +464,25 @@ void tst_QDateTime::setMSecsSinceEpoch_data()
<< (Q_INT64_C(123456) << 32)
<< QDateTime(QDate(18772, 8, 15), QTime(1, 8, 14, 976), Qt::UTC)
<< QDateTime(QDate(18772, 8, 15), QTime(3, 8, 14, 976));
- QTest::newRow("min_date") // julian day 0 is an invalid date for QDate
+ QTest::newRow("old min (Tue Nov 25 00:00:00 -4714)")
<< Q_INT64_C(-210866716800000)
<< QDateTime(QDate::fromJulianDay(1), QTime(), Qt::UTC)
<< QDateTime(QDate::fromJulianDay(1), QTime(1, 0));
- QTest::newRow("max_date") // technically jd is unsigned, but fromJulianDay takes int
+ QTest::newRow("old max (Tue Jun 3 21:59:59 5874898)")
<< Q_INT64_C(185331720376799999)
<< QDateTime(QDate::fromJulianDay(0x7fffffff), QTime(21, 59, 59, 999), Qt::UTC)
<< QDateTime(QDate::fromJulianDay(0x7fffffff), QTime(23, 59, 59, 999));
+ QTest::newRow("min")
+ // + 1 because, in the reference check below, calling addMSecs(qint64min)
+ // will internally apply unary minus to -qint64min, resulting in a
+ // positive value 1 too big for qint64max, causing an overflow.
+ << std::numeric_limits<qint64>::min() + 1
+ << QDateTime(QDate(-292275056, 5, 16), QTime(16, 47, 4, 193), Qt::UTC)
+ << QDateTime(QDate(-292275056, 5, 16), QTime(17, 47, 4, 193), Qt::LocalTime);
+ QTest::newRow("max")
+ << std::numeric_limits<qint64>::max()
+ << QDateTime(QDate(292278994, 8, 17), QTime(7, 12, 55, 807), Qt::UTC)
+ << QDateTime(QDate(292278994, 8, 17), QTime(9, 12, 55, 807), Qt::LocalTime);
}
void tst_QDateTime::setMSecsSinceEpoch()
@@ -821,6 +834,29 @@ void tst_QDateTime::toTimeSpec_data()
QTest::newRow("winter4") << QDateTime(QDate(6000, 2, 29), utcTime, Qt::UTC)
<< QDateTime(QDate(6000, 2, 29), localStandardTime, Qt::LocalTime);
+ // Test mktime boundaries (1970 - 2038) and adjustDate().
+ QTest::newRow("1969/12/31 23:00 UTC")
+ << QDateTime(QDate(1969, 12, 31), QTime(23, 0, 0), Qt::UTC)
+ << QDateTime(QDate(1970, 1, 1), QTime(0, 0, 0), Qt::LocalTime);
+ QTest::newRow("2037/12/31 23:00 UTC")
+ << QDateTime(QDate(2037, 12, 31), QTime(23, 0, 0), Qt::UTC)
+ << QDateTime(QDate(2038, 1, 1), QTime(0, 0, 0), Qt::LocalTime);
+
+ QTest::newRow("-271821/4/20 00:00 UTC (JavaScript min date, start of day)")
+ << QDateTime(QDate(-271821, 4, 20), QTime(0, 0, 0), Qt::UTC)
+ << QDateTime(QDate(-271821, 4, 20), QTime(1, 0, 0), Qt::LocalTime);
+ QTest::newRow("-271821/4/20 23:00 UTC (JavaScript min date, end of day)")
+ << QDateTime(QDate(-271821, 4, 20), QTime(23, 0, 0), Qt::UTC)
+ << QDateTime(QDate(-271821, 4, 21), QTime(0, 0, 0), Qt::LocalTime);
+
+ QTest::newRow("QDate min")
+ << QDateTime(QDate::fromJulianDay(minJd()), QTime(0, 0, 0), Qt::UTC)
+ << QDateTime(QDate::fromJulianDay(minJd()), QTime(1, 0, 0), Qt::LocalTime);
+
+ QTest::newRow("QDate max")
+ << QDateTime(QDate::fromJulianDay(maxJd()), QTime(22, 59, 59), Qt::UTC)
+ << QDateTime(QDate::fromJulianDay(maxJd()), QTime(23, 59, 59), Qt::LocalTime);
+
if (europeanTimeZone) {
QTest::newRow("summer1") << QDateTime(QDate(2004, 6, 30), utcTime, Qt::UTC)
<< QDateTime(QDate(2004, 6, 30), localDaylightTime, Qt::LocalTime);
@@ -835,6 +871,14 @@ void tst_QDateTime::toTimeSpec_data()
#endif
QTest::newRow("summer3") << QDateTime(QDate(4000, 6, 30), utcTime, Qt::UTC)
<< QDateTime(QDate(4000, 6, 30), localDaylightTime, Qt::LocalTime);
+
+ QTest::newRow("275760/9/23 00:00 UTC (JavaScript max date, start of day)")
+ << QDateTime(QDate(275760, 9, 23), QTime(0, 0, 0), Qt::UTC)
+ << QDateTime(QDate(275760, 9, 23), QTime(2, 0, 0), Qt::LocalTime);
+
+ QTest::newRow("275760/9/23 22:00 UTC (JavaScript max date, end of day)")
+ << QDateTime(QDate(275760, 9, 23), QTime(22, 0, 0), Qt::UTC)
+ << QDateTime(QDate(275760, 9, 24), QTime(0, 0, 0), Qt::LocalTime);
}
QTest::newRow("msec") << QDateTime(QDate(4000, 6, 30), utcTime.addMSecs(1), Qt::UTC)
diff --git a/tests/auto/corelib/tools/qhash/tst_qhash.cpp b/tests/auto/corelib/tools/qhash/tst_qhash.cpp
index 6df84e6363..1cbf181286 100644
--- a/tests/auto/corelib/tools/qhash/tst_qhash.cpp
+++ b/tests/auto/corelib/tools/qhash/tst_qhash.cpp
@@ -74,6 +74,7 @@ private slots:
void const_shared_null();
void twoArguments_qHash();
+ void initializerList();
};
struct Foo {
@@ -844,7 +845,7 @@ void tst_QHash::iterators()
//STL-Style iterators
QHash<int, QString>::iterator stlIt = hash.begin();
- for(stlIt = hash.begin(), i = 1; stlIt != hash.end(), i < 100; ++stlIt, ++i) {
+ for (stlIt = hash.begin(), i = 1; stlIt != hash.end() && i < 100; ++stlIt, ++i) {
testMap.insert(i,stlIt.value());
//QVERIFY(stlIt.value() == hash.value(
}
@@ -869,7 +870,7 @@ void tst_QHash::iterators()
//STL-Style const-iterators
QHash<int, QString>::const_iterator cstlIt = hash.constBegin();
- for(cstlIt = hash.constBegin(), i = 1; cstlIt != hash.constEnd(), i < 100; ++cstlIt, ++i) {
+ for (cstlIt = hash.constBegin(), i = 1; cstlIt != hash.constEnd() && i < 100; ++cstlIt, ++i) {
testMap.insert(i,cstlIt.value());
//QVERIFY(stlIt.value() == hash.value(
}
@@ -1300,5 +1301,34 @@ void tst_QHash::twoArguments_qHash()
QCOMPARE(wrongqHashOverload, 0);
}
+void tst_QHash::initializerList()
+{
+#ifdef Q_COMPILER_INITIALIZER_LISTS
+ QHash<int, QString> hash{{1, "hello"}, {2, "initializer_list"}};
+ QCOMPARE(hash.count(), 2);
+ QVERIFY(hash[1] == "hello");
+ QVERIFY(hash[2] == "initializer_list");
+
+ QMultiHash<QString, int> multiHash{{"il", 1}, {"il", 2}, {"il", 3}};
+ QCOMPARE(multiHash.count(), 3);
+ QList<int> values = multiHash.values("il");
+ QCOMPARE(values.count(), 3);
+
+ QHash<int, int> emptyHash{};
+ QVERIFY(emptyHash.isEmpty());
+
+ QHash<int, char> emptyPairs{{}, {}};
+ QVERIFY(!emptyPairs.isEmpty());
+
+ QMultiHash<QString, double> emptyMultiHash{};
+ QVERIFY(emptyMultiHash.isEmpty());
+
+ QMultiHash<int, float> emptyPairs2{{}, {}};
+ QVERIFY(!emptyPairs2.isEmpty());
+#else
+ QSKIP("Compiler doesn't support initializer lists");
+#endif
+}
+
QTEST_APPLESS_MAIN(tst_QHash)
#include "tst_qhash.moc"
diff --git a/tests/auto/corelib/tools/qlocale/tst_qlocale.cpp b/tests/auto/corelib/tools/qlocale/tst_qlocale.cpp
index d58d207546..f8775bc75f 100644
--- a/tests/auto/corelib/tools/qlocale/tst_qlocale.cpp
+++ b/tests/auto/corelib/tools/qlocale/tst_qlocale.cpp
@@ -42,12 +42,13 @@
#include <QtTest/QtTest>
#include <math.h>
-#include <qglobal.h>
+#include <qdebug.h>
#include <qdir.h>
#include <qfileinfo.h>
#include <QScopedArrayPointer>
#include <qtextcodec.h>
#include <qdatetime.h>
+#include <qprocess.h>
#include <float.h>
#include <qlocale.h>
@@ -145,6 +146,9 @@ private slots:
void measurementSystems();
void QTBUG_26035_positivesign();
+ void textDirection_data();
+ void textDirection();
+
private:
QString m_decimal, m_thousand, m_sdate, m_ldate, m_time;
QString m_sysapp;
@@ -712,6 +716,7 @@ void tst_QLocale::double_conversion()
QFETCH(QString, num_str);
QFETCH(bool, good);
QFETCH(double, num);
+ QStringRef num_strRef = num_str.leftRef(-1);
QLocale locale(locale_name);
QCOMPARE(locale.name(), locale_name);
@@ -726,6 +731,16 @@ void tst_QLocale::double_conversion()
diff = -diff;
QVERIFY(diff <= MY_DOUBLE_EPSILON);
}
+
+ d = locale.toDouble(num_strRef, &ok);
+ QCOMPARE(ok, good);
+
+ if (ok) {
+ double diff = d - num;
+ if (diff < 0)
+ diff = -diff;
+ QVERIFY(diff <= MY_DOUBLE_EPSILON);
+ }
}
void tst_QLocale::long_long_conversion_data()
@@ -787,6 +802,7 @@ void tst_QLocale::long_long_conversion()
QFETCH(QString, num_str);
QFETCH(bool, good);
QFETCH(qlonglong, num);
+ QStringRef num_strRef = num_str.leftRef(-1);
QLocale locale(locale_name);
QCOMPARE(locale.name(), locale_name);
@@ -795,9 +811,14 @@ void tst_QLocale::long_long_conversion()
qlonglong l = locale.toLongLong(num_str, &ok);
QCOMPARE(ok, good);
- if (ok) {
+ if (ok)
+ QCOMPARE(l, num);
+
+ l = locale.toLongLong(num_strRef, &ok);
+ QCOMPARE(ok, good);
+
+ if (ok)
QCOMPARE(l, num);
- }
}
void tst_QLocale::long_long_conversion_extra()
@@ -1281,7 +1302,7 @@ static QString getWinLocaleInfo(LCTYPE type)
int cnt = GetLocaleInfo(id, type, 0, 0) * 2;
if (cnt == 0) {
- qWarning("QLocale: empty windows locale info (%d)", type);
+ qWarning().nospace() << "QLocale: empty windows locale info (" << type << ')';
return QString();
}
cnt /= sizeof(wchar_t);
@@ -1289,7 +1310,7 @@ static QString getWinLocaleInfo(LCTYPE type)
cnt = GetLocaleInfo(id, type, buf.data(), cnt);
if (cnt == 0) {
- qWarning("QLocale: empty windows locale info (%d)", type);
+ qWarning().nospace() << "QLocale: empty windows locale info (" << type << ')';
return QString();
}
return QString::fromWCharArray(buf.data());
@@ -1616,10 +1637,10 @@ void tst_QLocale::defaultNumeringSystem()
QCOMPARE(pa.toString(123), QLatin1String("123"));
QLocale ne("ne_IN");
- QCOMPARE(ne.toString(123), QLatin1String("123"));
+ QCOMPARE(ne.toString(123), QString::fromUtf8("१२३"));
QLocale mr("mr_IN");
- QCOMPARE(mr.toString(123), QLatin1String("123"));
+ QCOMPARE(mr.toString(123), QString::fromUtf8("१२३"));
QLocale ml("ml_IN");
QCOMPARE(ml.toString(123), QLatin1String("123"));
@@ -1680,6 +1701,9 @@ void tst_QLocale::dateFormat()
const QLocale ja("ja_JP");
QCOMPARE(ja.dateFormat(QLocale::ShortFormat), QLatin1String("yyyy/MM/dd"));
+
+ const QLocale ir("ga_IE");
+ QCOMPARE(ir.dateFormat(QLocale::ShortFormat), QLatin1String("dd/MM/yyyy"));
}
void tst_QLocale::timeFormat()
@@ -1939,5 +1963,44 @@ void tst_QLocale::QTBUG_26035_positivesign()
QVERIFY(ok);
}
+void tst_QLocale::textDirection_data()
+{
+ QTest::addColumn<int>("language");
+ QTest::addColumn<int>("script");
+ QTest::addColumn<bool>("rightToLeft");
+
+ for (int language = QLocale::C; language <= QLocale::LastLanguage; ++language) {
+ bool rightToLeft = false;
+ switch (language) {
+ case QLocale::Arabic:
+ case QLocale::Hebrew:
+ case QLocale::Kashmiri:
+ case QLocale::Persian:
+ case QLocale::Pashto:
+ case QLocale::Urdu:
+ case QLocale::Syriac:
+ case QLocale::Divehi:
+ rightToLeft = QLocale(QLocale::Language(language)).language() == QLocale::Language(language); // false if there is no locale data for language
+ break;
+ default:
+ break;
+ }
+ QString testName = QLocalePrivate::languageToCode(QLocale::Language(language));
+ QTest::newRow(testName.toLatin1().constData()) << language << int(QLocale::AnyScript) << rightToLeft;
+ }
+ QTest::newRow("pa_Arab") << int(QLocale::Punjabi) << int(QLocale::ArabicScript) << true;
+ QTest::newRow("uz_Arab") << int(QLocale::Uzbek) << int(QLocale::ArabicScript) << true;
+}
+
+void tst_QLocale::textDirection()
+{
+ QFETCH(int, language);
+ QFETCH(int, script);
+ QFETCH(bool, rightToLeft);
+
+ QLocale locale(QLocale::Language(language), QLocale::Script(script), QLocale::AnyCountry);
+ QCOMPARE(locale.textDirection() == Qt::RightToLeft, rightToLeft);
+}
+
QTEST_MAIN(tst_QLocale)
#include "tst_qlocale.moc"
diff --git a/tests/auto/corelib/tools/qmap/tst_qmap.cpp b/tests/auto/corelib/tools/qmap/tst_qmap.cpp
index 5069b805bf..0742f19a5e 100644
--- a/tests/auto/corelib/tools/qmap/tst_qmap.cpp
+++ b/tests/auto/corelib/tools/qmap/tst_qmap.cpp
@@ -84,6 +84,9 @@ private slots:
void insert();
void checkMostLeftNode();
+ void initializerList();
+ void testInsertWithHint();
+ void testInsertMultiWithHint();
};
typedef QMap<QString, QString> StringMap;
@@ -937,6 +940,18 @@ void tst_QMap::qmultimap_specific()
QVERIFY(map2.remove(42,5));
QVERIFY(map1 == map2);
}
+
+ map1.insert(map1.constBegin(), -1, -1);
+ QCOMPARE(map1.size(), 45);
+ map1.insert(map1.constBegin(), -1, -1);
+ QCOMPARE(map1.size(), 46);
+ map1.insert(map1.constBegin(), -2, -2);
+ QCOMPARE(map1.size(), 47);
+ map1.insert(map1.constBegin(), 5, 5); // Invald hint
+ QCOMPARE(map1.size(), 48);
+ map1.insert(map1.constBegin(), 5, 5); // Invald hint
+ QCOMPARE(map1.size(), 49);
+ sanityCheckTree(map1, __LINE__);
}
void tst_QMap::const_shared_null()
@@ -1129,5 +1144,151 @@ void tst_QMap::checkMostLeftNode()
sanityCheckTree(map, __LINE__);
}
+void tst_QMap::initializerList()
+{
+#ifdef Q_COMPILER_INITIALIZER_LISTS
+ QMap<int, QString> map{{1, "hello"}, {2, "initializer_list"}};
+ QCOMPARE(map.count(), 2);
+ QVERIFY(map[1] == "hello");
+ QVERIFY(map[2] == "initializer_list");
+
+ QMultiMap<QString, int> multiMap{{"il", 1}, {"il", 2}, {"il", 3}};
+ QCOMPARE(multiMap.count(), 3);
+ QList<int> values = multiMap.values("il");
+ QCOMPARE(values.count(), 3);
+
+ QMap<int, int> emptyMap{};
+ QVERIFY(emptyMap.isEmpty());
+
+ QMap<char, char> emptyPairs{{}, {}};
+ QVERIFY(!emptyPairs.isEmpty());
+
+ QMultiMap<double, double> emptyMultiMap{};
+ QVERIFY(emptyMultiMap.isEmpty());
+
+ QMultiMap<float, float> emptyPairs2{{}, {}};
+ QVERIFY(!emptyPairs2.isEmpty());
+#else
+ QSKIP("Compiler doesn't support initializer lists");
+#endif
+}
+
+void tst_QMap::testInsertWithHint()
+{
+ QMap<int, int> map;
+ map.setSharable(false);
+
+ // Check with end hint();
+ map.insert(map.constEnd(), 3, 1); // size == 1
+ sanityCheckTree(map, __LINE__);
+ map.insert(map.constEnd(), 5, 1); // size = 2
+ sanityCheckTree(map, __LINE__);
+ map.insert(map.constEnd(), 50, 1); // size = 3
+ sanityCheckTree(map, __LINE__);
+ QMap<int, int>::const_iterator key75(map.insert(map.constEnd(), 75, 1)); // size = 4
+ sanityCheckTree(map, __LINE__);
+ map.insert(map.constEnd(), 100, 1); // size = 5
+ sanityCheckTree(map, __LINE__);
+ map.insert(map.constEnd(), 105, 1); // size = 6
+ sanityCheckTree(map, __LINE__);
+ map.insert(map.constEnd(), 10, 5); // invalid hint and size = 7
+ sanityCheckTree(map, __LINE__);
+ QMap<int, int>::iterator lastkey = map.insert(map.constEnd(), 105, 12); // overwrite
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(lastkey.value(), 12);
+ QCOMPARE(lastkey.key(), 105);
+ QCOMPARE(map.size(), 7);
+
+ // With regular hint
+ map.insert(key75, 75, 100); // overwrite current key
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 7);
+ QCOMPARE(key75.key(), 75);
+ QCOMPARE(key75.value(), 100);
+
+ map.insert(key75, 50, 101); // overwrite previous value
+ QMap<int, int>::const_iterator key50(key75);
+ --key50;
+ QCOMPARE(map.size(), 7);
+ QCOMPARE(key50.key(), 50);
+ QCOMPARE(key50.value(), 101);
+
+ map.insert(key75, 17, 125); // invalid hint - size 8
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 8);
+
+ // begin
+ map.insert(map.constBegin(), 1, 1); // size 9
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 9);
+
+ map.insert(map.constBegin(), 1, 10); // overwrite existing (leftmost) value
+ QCOMPARE(map.constBegin().value(), 10);
+
+ map.insert(map.constBegin(), 47, 47); // wrong hint - size 10
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 10);
+
+ // insert with right == 0
+ QMap<int, int>::const_iterator i1 (map.insert(key75, 70, 12)); // overwrite
+ map.insert(i1, 69, 12); // size 12
+
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 12);
+}
+
+void tst_QMap::testInsertMultiWithHint()
+{
+ QMap<int, int> map;
+ map.setSharable(false);
+
+ typedef QMap<int, int>::const_iterator cite; // Hack since we define QT_STRICT_ITERATORS
+ map.insertMulti(cite(map.end()), 64, 65);
+ map[128] = 129;
+ map[256] = 257;
+ sanityCheckTree(map, __LINE__);
+
+ map.insertMulti(cite(map.end()), 512, 513);
+ map.insertMulti(cite(map.end()), 512, 513 * 2);
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 5);
+ map.insertMulti(cite(map.end()), 256, 258); // wrong hint
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 6);
+
+ QMap<int, int>::iterator i = map.insertMulti(map.constBegin(), 256, 259); // wrong hint
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 7);
+
+ QMap<int, int>::iterator j = map.insertMulti(map.constBegin(), 69, 66);
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 8);
+
+ j = map.insertMulti(cite(j), 68, 259);
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 9);
+
+ j = map.insertMulti(cite(j), 67, 67);
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 10);
+
+ i = map.insertMulti(cite(i), 256, 259);
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 11);
+
+ i = map.insertMulti(cite(i), 256, 260);
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 12);
+
+ map.insertMulti(cite(i), 64, 67);
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 13);
+
+ map.insertMulti(map.constBegin(), 20, 20);
+ sanityCheckTree(map, __LINE__);
+ QCOMPARE(map.size(), 14);
+}
+
+
QTEST_APPLESS_MAIN(tst_QMap)
#include "tst_qmap.moc"
diff --git a/tests/auto/corelib/tools/qmargins/tst_qmargins.cpp b/tests/auto/corelib/tools/qmargins/tst_qmargins.cpp
index 9700f91128..d22e771b79 100644
--- a/tests/auto/corelib/tools/qmargins/tst_qmargins.cpp
+++ b/tests/auto/corelib/tools/qmargins/tst_qmargins.cpp
@@ -50,6 +50,7 @@ class tst_QMargins : public QObject
private slots:
void getSetCheck();
void dataStreamCheck();
+ void operators();
};
// Testing get/set functions
@@ -73,7 +74,50 @@ void tst_QMargins::getSetCheck()
margins.setRight(5);
QVERIFY(!margins.isNull());
QCOMPARE(margins, QMargins(5, 0, 5, 0));
-}
+}
+
+void tst_QMargins::operators()
+{
+ const QMargins m1(12, 14, 16, 18);
+ const QMargins m2(2, 3, 4, 5);
+
+ const QMargins added = m1 + m2;
+ QCOMPARE(added, QMargins(14, 17, 20, 23));
+ QMargins a = m1;
+ a += m2;
+ QCOMPARE(a, added);
+
+ const QMargins subtracted = m1 - m2;
+ QCOMPARE(subtracted, QMargins(10, 11, 12, 13));
+ a = m1;
+ a -= m2;
+ QCOMPARE(a, subtracted);
+
+ const QMargins doubled = m1 * 2;
+ QCOMPARE(doubled, QMargins(24, 28, 32, 36));
+ QCOMPARE(2 * m1, doubled);
+ QCOMPARE(qreal(2) * m1, doubled);
+ QCOMPARE(m1 * qreal(2), doubled);
+
+ a = m1;
+ a *= 2;
+ QCOMPARE(a, doubled);
+ a = m1;
+ a *= qreal(2);
+ QCOMPARE(a, doubled);
+
+ const QMargins halved = m1 / 2;
+ QCOMPARE(halved, QMargins(6, 7, 8, 9));
+
+ a = m1;
+ a /= 2;
+ QCOMPARE(a, halved);
+ a = m1;
+ a /= qreal(2);
+ QCOMPARE(a, halved);
+
+ QCOMPARE(m1 + (-m1), QMargins());
+}
// Testing QDataStream operators
void tst_QMargins::dataStreamCheck()
diff --git a/tests/auto/corelib/tools/qmessageauthenticationcode/.gitignore b/tests/auto/corelib/tools/qmessageauthenticationcode/.gitignore
new file mode 100644
index 0000000000..bfd53f437b
--- /dev/null
+++ b/tests/auto/corelib/tools/qmessageauthenticationcode/.gitignore
@@ -0,0 +1 @@
+tst_qmessageauthenticationcode
diff --git a/tests/auto/corelib/tools/qmessageauthenticationcode/qmessageauthenticationcode.pro b/tests/auto/corelib/tools/qmessageauthenticationcode/qmessageauthenticationcode.pro
new file mode 100644
index 0000000000..1ea23915b7
--- /dev/null
+++ b/tests/auto/corelib/tools/qmessageauthenticationcode/qmessageauthenticationcode.pro
@@ -0,0 +1,7 @@
+CONFIG += testcase parallel_test
+TARGET = tst_qmessageauthenticationcode
+QT = core testlib
+SOURCES = tst_qmessageauthenticationcode.cpp
+
+TESTDATA += data/*
+DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/corelib/tools/qmessageauthenticationcode/tst_qmessageauthenticationcode.cpp b/tests/auto/corelib/tools/qmessageauthenticationcode/tst_qmessageauthenticationcode.cpp
new file mode 100644
index 0000000000..0e243988e2
--- /dev/null
+++ b/tests/auto/corelib/tools/qmessageauthenticationcode/tst_qmessageauthenticationcode.cpp
@@ -0,0 +1,151 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Ruslan Nigmatullin <euroelessar@yandex.ru>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+#include <QtCore/QCoreApplication>
+#include <QtTest/QtTest>
+
+class tst_QMessageAuthenticationCode : public QObject
+{
+ Q_OBJECT
+private slots:
+ void result_data();
+ void result();
+ void result_incremental_data();
+ void result_incremental();
+};
+
+Q_DECLARE_METATYPE(QCryptographicHash::Algorithm)
+
+void tst_QMessageAuthenticationCode::result_data()
+{
+ QTest::addColumn<QCryptographicHash::Algorithm>("algo");
+ QTest::addColumn<QByteArray>("key");
+ QTest::addColumn<QByteArray>("message");
+ QTest::addColumn<QByteArray>("code");
+
+ // Empty values
+ QTest::newRow("md5-empty") << QCryptographicHash::Md5
+ << QByteArray()
+ << QByteArray()
+ << QByteArray::fromHex("74e6f7298a9c2d168935f58c001bad88");
+ QTest::newRow("sha1-empty") << QCryptographicHash::Sha1
+ << QByteArray()
+ << QByteArray()
+ << QByteArray::fromHex("fbdb1d1b18aa6c08324b7d64b71fb76370690e1d");
+ QTest::newRow("sha256-empty") << QCryptographicHash::Sha256
+ << QByteArray()
+ << QByteArray()
+ << QByteArray::fromHex("b613679a0814d9ec772f95d778c35fc5ff1697c493715653c6c712144292c5ad");
+
+ // Some not-empty
+ QTest::newRow("md5") << QCryptographicHash::Md5
+ << QByteArray("key")
+ << QByteArray("The quick brown fox jumps over the lazy dog")
+ << QByteArray::fromHex("80070713463e7749b90c2dc24911e275");
+ QTest::newRow("sha1") << QCryptographicHash::Sha1
+ << QByteArray("key")
+ << QByteArray("The quick brown fox jumps over the lazy dog")
+ << QByteArray::fromHex("de7c9b85b8b78aa6bc8a7a36f70a90701c9db4d9");
+ QTest::newRow("sha256") << QCryptographicHash::Sha256
+ << QByteArray("key")
+ << QByteArray("The quick brown fox jumps over the lazy dog")
+ << QByteArray::fromHex("f7bc83f430538424b13298e6aa6fb143ef4d59a14946175997479dbc2d1a3cd8");
+
+ // Some from rfc-2104
+ QTest::newRow("rfc-md5-1") << QCryptographicHash::Md5
+ << QByteArray::fromHex("0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b")
+ << QByteArray("Hi There")
+ << QByteArray::fromHex("9294727a3638bb1c13f48ef8158bfc9d");
+ QTest::newRow("rfc-md5-2") << QCryptographicHash::Md5
+ << QByteArray("Jefe")
+ << QByteArray("what do ya want for nothing?")
+ << QByteArray::fromHex("750c783e6ab0b503eaa86e310a5db738");
+ QTest::newRow("rfc-md5-3") << QCryptographicHash::Md5
+ << QByteArray::fromHex("AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA")
+ << QByteArray(50, 0xdd)
+ << QByteArray::fromHex("56be34521d144c88dbb8c733f0e8b3f6");
+}
+
+void tst_QMessageAuthenticationCode::result()
+{
+ QFETCH(QCryptographicHash::Algorithm, algo);
+ QFETCH(QByteArray, key);
+ QFETCH(QByteArray, message);
+ QFETCH(QByteArray, code);
+
+ QMessageAuthenticationCode mac(algo);
+ mac.setKey(key);
+ mac.addData(message);
+ QByteArray result = mac.result();
+
+ QCOMPARE(result, code);
+}
+
+void tst_QMessageAuthenticationCode::result_incremental_data()
+{
+ result_data();
+}
+
+void tst_QMessageAuthenticationCode::result_incremental()
+{
+ QFETCH(QCryptographicHash::Algorithm, algo);
+ QFETCH(QByteArray, key);
+ QFETCH(QByteArray, message);
+ QFETCH(QByteArray, code);
+
+ int index = message.length() / 2;
+ QByteArray leftPart(message.mid(0, index));
+ QByteArray rightPart(message.mid(index));
+
+ QCOMPARE(leftPart + rightPart, message);
+
+ QMessageAuthenticationCode mac(algo);
+ mac.setKey(key);
+ mac.addData(leftPart);
+ mac.addData(rightPart);
+ QByteArray result = mac.result();
+
+ QCOMPARE(result, code);
+}
+
+QTEST_MAIN(tst_QMessageAuthenticationCode)
+#include "tst_qmessageauthenticationcode.moc"
diff --git a/tests/auto/corelib/tools/qpoint/tst_qpoint.cpp b/tests/auto/corelib/tools/qpoint/tst_qpoint.cpp
index 924cac292e..3231469261 100644
--- a/tests/auto/corelib/tools/qpoint/tst_qpoint.cpp
+++ b/tests/auto/corelib/tools/qpoint/tst_qpoint.cpp
@@ -70,6 +70,9 @@ private slots:
void operator_divide_data();
void operator_divide();
+ void dotProduct_data();
+ void dotProduct();
+
void operator_unary_plus_data();
void operator_unary_plus();
@@ -271,6 +274,28 @@ void tst_QPoint::operator_divide()
QCOMPARE(point, expected);
}
+void tst_QPoint::dotProduct_data()
+{
+ QTest::addColumn<QPoint>("point1");
+ QTest::addColumn<QPoint>("point2");
+ QTest::addColumn<int>("expected");
+
+ QTest::newRow("(0, 0) dot (0, 0)") << QPoint(0, 0) << QPoint(0, 0)<< 0;
+ QTest::newRow("(10, 0) dot (0, 10)") << QPoint(10, 0) << QPoint(0, 10) << 0;
+ QTest::newRow("(0, 10) dot (10, 0)") << QPoint(0, 10) << QPoint(10, 0) << 0;
+ QTest::newRow("(10, 20) dot (-10, -20)") << QPoint(10, 20) << QPoint(-10, -20) << -500;
+ QTest::newRow("(-10, -20) dot (10, 20)") << QPoint(-10, -20) << QPoint(10, 20) << -500;
+}
+
+void tst_QPoint::dotProduct()
+{
+ QFETCH(QPoint, point1);
+ QFETCH(QPoint, point2);
+ QFETCH(int, expected);
+
+ QCOMPARE(QPoint::dotProduct(point1, point2), expected);
+}
+
void tst_QPoint::operator_unary_plus_data()
{
operator_unary_minus_data();
diff --git a/tests/auto/corelib/tools/qpointf/tst_qpointf.cpp b/tests/auto/corelib/tools/qpointf/tst_qpointf.cpp
index 0f2e74e68e..fc79b40a18 100644
--- a/tests/auto/corelib/tools/qpointf/tst_qpointf.cpp
+++ b/tests/auto/corelib/tools/qpointf/tst_qpointf.cpp
@@ -75,6 +75,9 @@ private slots:
void operator_divide();
void division();
+ void dotProduct_data();
+ void dotProduct();
+
void operator_unary_plus_data();
void operator_unary_plus();
@@ -290,6 +293,29 @@ void tst_QPointF::division()
}
}
+void tst_QPointF::dotProduct_data()
+{
+ QTest::addColumn<QPointF>("point1");
+ QTest::addColumn<QPointF>("point2");
+ QTest::addColumn<qreal>("expected");
+
+ QTest::newRow("(0, 0) dot (0, 0)") << QPointF(0, 0) << QPointF(0, 0) << qreal(0);
+ QTest::newRow("(10, 0) dot (0, 10)") << QPointF(10, 0) << QPointF(0, 10)<< qreal(0);
+ QTest::newRow("(0, 10) dot (10, 0)") << QPointF(0, 10) << QPointF(10, 0) << qreal(0);
+ QTest::newRow("(10, 20) dot (-10, -20)") << QPointF(10, 20) << QPointF(-10, -20) << qreal(-500);
+ QTest::newRow("(10.1, 20.2) dot (-10.1, -20.2)") << QPointF(10.1, 20.2) << QPointF(-10.1, -20.2) << qreal(-510.05);
+ QTest::newRow("(-10.1, -20.2) dot (10.1, 20.2)") << QPointF(-10.1, -20.2) << QPointF(10.1, 20.2) << qreal(-510.05);
+}
+
+void tst_QPointF::dotProduct()
+{
+ QFETCH(QPointF, point1);
+ QFETCH(QPointF, point2);
+ QFETCH(qreal, expected);
+
+ QCOMPARE(QPointF::dotProduct(point1, point2), expected);
+}
+
void tst_QPointF::operator_unary_plus_data()
{
operator_unary_minus_data();
diff --git a/tests/auto/corelib/tools/qqueue/tst_qqueue.cpp b/tests/auto/corelib/tools/qqueue/tst_qqueue.cpp
index 88de03e4bf..2fdde3c613 100644
--- a/tests/auto/corelib/tools/qqueue/tst_qqueue.cpp
+++ b/tests/auto/corelib/tools/qqueue/tst_qqueue.cpp
@@ -63,15 +63,15 @@ void tst_QQueue::enqueue_dequeue_data()
void tst_QQueue::enqueue_dequeue()
{
- QFETCH(int, num_items);
-
- int *values = new int[num_items];
- QQueue<int> queue_v;
- QQueue<int*> queue_p;
+ QFETCH(int, num_items);
+
+ int *values = new int[num_items];
+ QQueue<int> queue_v;
+ QQueue<int*> queue_p;
QVERIFY(queue_v.empty());
QVERIFY(queue_p.empty());
-
+
for (int i = 0; i < num_items; i++ ) {
values[i] = i;
queue_p.enqueue(values + i);
@@ -84,11 +84,11 @@ void tst_QQueue::enqueue_dequeue()
v = queue_v.head();
p = queue_p.head();
QCOMPARE(*p, v);
- QCOMPARE(v, i);
+ QCOMPARE(v, i);
v = queue_v.dequeue();
p = queue_p.dequeue();
- QCOMPARE(*p, v);
- QCOMPARE(v, values[i]);
+ QCOMPARE(*p, v);
+ QCOMPARE(v, values[i]);
}
QVERIFY(queue_v.empty());
QVERIFY(queue_p.empty());
diff --git a/tests/auto/corelib/tools/qrect/tst_qrect.cpp b/tests/auto/corelib/tools/qrect/tst_qrect.cpp
index b3fc8b0759..1b11673bd1 100644
--- a/tests/auto/corelib/tools/qrect/tst_qrect.cpp
+++ b/tests/auto/corelib/tools/qrect/tst_qrect.cpp
@@ -41,6 +41,7 @@
#include <QtTest/QtTest>
#include <qrect.h>
+#include <qmargins.h>
#include <limits.h>
#include <qdebug.h>
@@ -133,6 +134,7 @@ private slots:
void newMoveTopLeft();
void newMoveBottomRight_data();
void newMoveBottomRight();
+ void margins();
void translate_data();
void translate();
@@ -3484,6 +3486,25 @@ void tst_QRect::newMoveBottomRight()
QCOMPARE(r,nr);
}
+void tst_QRect::margins()
+{
+ const QRect rectangle = QRect(QPoint(10, 10), QSize(50 ,50));
+ const QMargins margins = QMargins(2, 3, 4, 5);
+
+ const QRect added = rectangle + margins;
+ QCOMPARE(added, QRect(QPoint(8, 7), QSize(56, 58)));
+ QCOMPARE(added, margins + rectangle);
+ QCOMPARE(added, rectangle.marginsAdded(margins));
+
+ QRect a = rectangle;
+ a += margins;
+ QCOMPARE(added, a);
+
+ a = rectangle;
+ a -= margins;
+ QCOMPARE(a, QRect(QPoint(12, 13), QSize(44, 42)));
+ QCOMPARE(a, rectangle.marginsRemoved(margins));
+}
void tst_QRect::translate_data()
{
diff --git a/tests/auto/corelib/tools/qregularexpression/tst_qregularexpression.cpp b/tests/auto/corelib/tools/qregularexpression/tst_qregularexpression.cpp
index 7073805db4..909725f4b8 100644
--- a/tests/auto/corelib/tools/qregularexpression/tst_qregularexpression.cpp
+++ b/tests/auto/corelib/tools/qregularexpression/tst_qregularexpression.cpp
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2012 Giuseppe D'Angelo <dangelog@gmail.com>.
+** Copyright (C) 2013 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
** Contact: http://www.qt-project.org/legal
**
** This file is part of the test suite of the Qt Toolkit.
@@ -126,8 +127,6 @@ bool operator!=(const Match &m, const QRegularExpressionMatch &rem)
bool operator==(const QRegularExpressionMatchIterator &iterator, const QList<Match> &expectedMatchList)
{
QRegularExpressionMatchIterator i = iterator;
- if (i.isValid() != (!expectedMatchList.isEmpty()))
- return false;
foreach (const Match &expectedMatch, expectedMatchList)
{
@@ -293,6 +292,31 @@ void tst_QRegularExpression::provideRegularExpressions()
| QRegularExpression::InvertedGreedinessOption);
}
+void tst_QRegularExpression::defaultConstructors()
+{
+ QRegularExpression re;
+ QCOMPARE(re.pattern(), QString());
+ QCOMPARE(re.patternOptions(), QRegularExpression::NoPatternOption);
+
+ QRegularExpressionMatch match;
+ QCOMPARE(match.regularExpression(), QRegularExpression());
+ QCOMPARE(match.regularExpression(), re);
+ QCOMPARE(match.matchType(), QRegularExpression::NoMatch);
+ QCOMPARE(match.matchOptions(), QRegularExpression::NoMatchOption);
+ QCOMPARE(match.hasMatch(), false);
+ QCOMPARE(match.hasPartialMatch(), false);
+ QCOMPARE(match.isValid(), true);
+ QCOMPARE(match.lastCapturedIndex(), -1);
+
+ QRegularExpressionMatchIterator iterator;
+ QCOMPARE(iterator.regularExpression(), QRegularExpression());
+ QCOMPARE(iterator.regularExpression(), re);
+ QCOMPARE(iterator.matchType(), QRegularExpression::NoMatch);
+ QCOMPARE(iterator.matchOptions(), QRegularExpression::NoMatchOption);
+ QCOMPARE(iterator.isValid(), true);
+ QCOMPARE(iterator.hasNext(), false);
+}
+
void tst_QRegularExpression::gettersSetters_data()
{
provideRegularExpressions();
@@ -693,12 +717,31 @@ void tst_QRegularExpression::normalMatch()
QFETCH(QRegularExpression::MatchOptions, matchOptions);
QFETCH(Match, match);
- QRegularExpressionMatch m = regexp.match(subject, offset, QRegularExpression::NormalMatch, matchOptions);
- consistencyCheck(m);
- QVERIFY(m == match);
+ {
+ QRegularExpressionMatch m = regexp.match(subject, offset, QRegularExpression::NormalMatch, matchOptions);
+ consistencyCheck(m);
+ QVERIFY(m == match);
+ QCOMPARE(m.regularExpression(), regexp);
+ QCOMPARE(m.matchType(), QRegularExpression::NormalMatch);
+ QCOMPARE(m.matchOptions(), matchOptions);
+ }
+ {
+ // ignore the expected results provided by the match object --
+ // we'll never get any result when testing the NoMatch type.
+ // Just check the validity of the match here.
+ Match realMatch;
+ realMatch.clear();
+ realMatch.isValid = match.isValid;
+
+ QRegularExpressionMatch m = regexp.match(subject, offset, QRegularExpression::NoMatch, matchOptions);
+ consistencyCheck(m);
+ QVERIFY(m == realMatch);
+ QCOMPARE(m.regularExpression(), regexp);
+ QCOMPARE(m.matchType(), QRegularExpression::NoMatch);
+ QCOMPARE(m.matchOptions(), matchOptions);
+ }
}
-
void tst_QRegularExpression::partialMatch_data()
{
QTest::addColumn<QRegularExpression>("regexp");
@@ -952,9 +995,29 @@ void tst_QRegularExpression::partialMatch()
QFETCH(QRegularExpression::MatchOptions, matchOptions);
QFETCH(Match, match);
- QRegularExpressionMatch m = regexp.match(subject, offset, matchType, matchOptions);
- consistencyCheck(m);
- QVERIFY(m == match);
+ {
+ QRegularExpressionMatch m = regexp.match(subject, offset, matchType, matchOptions);
+ consistencyCheck(m);
+ QVERIFY(m == match);
+ QCOMPARE(m.regularExpression(), regexp);
+ QCOMPARE(m.matchType(), matchType);
+ QCOMPARE(m.matchOptions(), matchOptions);
+ }
+ {
+ // ignore the expected results provided by the match object --
+ // we'll never get any result when testing the NoMatch type.
+ // Just check the validity of the match here.
+ Match realMatch;
+ realMatch.clear();
+ realMatch.isValid = match.isValid;
+
+ QRegularExpressionMatch m = regexp.match(subject, offset, QRegularExpression::NoMatch, matchOptions);
+ consistencyCheck(m);
+ QVERIFY(m == realMatch);
+ QCOMPARE(m.regularExpression(), regexp);
+ QCOMPARE(m.matchType(), QRegularExpression::NoMatch);
+ QCOMPARE(m.matchOptions(), matchOptions);
+ }
}
void tst_QRegularExpression::globalMatch_data()
@@ -1223,10 +1286,28 @@ void tst_QRegularExpression::globalMatch()
QFETCH(QRegularExpression::MatchType, matchType);
QFETCH(QRegularExpression::MatchOptions, matchOptions);
QFETCH(QList<Match>, matchList);
+ {
+ QRegularExpressionMatchIterator iterator = regexp.globalMatch(subject, offset, matchType, matchOptions);
+ consistencyCheck(iterator);
+ QVERIFY(iterator == matchList);
+ QCOMPARE(iterator.regularExpression(), regexp);
+ QCOMPARE(iterator.matchType(), matchType);
+ QCOMPARE(iterator.matchOptions(), matchOptions);
+ }
+ {
+ // ignore the expected results provided by the match object --
+ // we'll never get any result when testing the NoMatch type.
+ // Just check the validity of the match here.
+ QList<Match> realMatchList;
+
+ QRegularExpressionMatchIterator iterator = regexp.globalMatch(subject, offset, QRegularExpression::NoMatch, matchOptions);
+ consistencyCheck(iterator);
+ QVERIFY(iterator == realMatchList);
+ QCOMPARE(iterator.regularExpression(), regexp);
+ QCOMPARE(iterator.matchType(), QRegularExpression::NoMatch);
+ QCOMPARE(iterator.matchOptions(), matchOptions);
+ }
- QRegularExpressionMatchIterator iterator = regexp.globalMatch(subject, offset, matchType, matchOptions);
- consistencyCheck(iterator);
- QVERIFY(iterator == matchList);
}
void tst_QRegularExpression::serialize_data()
@@ -1338,6 +1419,86 @@ void tst_QRegularExpression::captureCount()
QCOMPARE(re.captureCount(), -1);
}
+// the comma in the template breaks QFETCH...
+typedef QMultiHash<QString, int> StringToIntMap;
+Q_DECLARE_METATYPE(StringToIntMap)
+
+void tst_QRegularExpression::captureNames_data()
+{
+ QTest::addColumn<QString>("pattern");
+ QTest::addColumn<StringToIntMap>("namedCapturesIndexMap");
+ StringToIntMap map;
+
+ QTest::newRow("captureNames01") << "a pattern" << map;
+ QTest::newRow("captureNames02") << "a.*pattern" << map;
+ QTest::newRow("captureNames03") << "(a) pattern" << map;
+ QTest::newRow("captureNames04") << "(a).*(pattern)" << map;
+
+ map.clear();
+ map.replace("named", 1);
+ QTest::newRow("captureNames05") << "a.*(?<named>pattern)" << map;
+
+ map.clear();
+ map.replace("named", 2);
+ QTest::newRow("captureNames06") << "(a).*(?<named>pattern)" << map;
+
+ map.clear();
+ map.replace("name1", 1);
+ map.replace("name2", 2);
+ QTest::newRow("captureNames07") << "(?<name1>a).*(?<name2>pattern)" << map;
+
+ map.clear();
+ map.replace("name1", 2);
+ map.replace("name2", 1);
+ QTest::newRow("captureNames08") << "(?<name2>a).*(?<name1>pattern)" << map;
+
+ map.clear();
+ map.replace("date", 1);
+ map.replace("month", 2);
+ map.replace("year", 3);
+ QTest::newRow("captureNames09") << "^(?<date>\\d\\d)/(?<month>\\d\\d)/(?<year>\\d\\d\\d\\d)$" << map;
+
+ map.clear();
+ map.replace("date", 2);
+ map.replace("month", 1);
+ map.replace("year", 3);
+ QTest::newRow("captureNames10") << "^(?<month>\\d\\d)/(?<date>\\d\\d)/(?<year>\\d\\d\\d\\d)$" << map;
+
+ map.clear();
+ map.replace("noun", 2);
+ QTest::newRow("captureNames11") << "(a)(?|(?<noun>b)|(?<noun>c))(d)" << map;
+
+ map.clear();
+ QTest::newRow("captureNames_invalid01") << "(.*" << map;
+ QTest::newRow("captureNames_invalid02") << "\\" << map;
+ QTest::newRow("captureNames_invalid03") << "(?<noun)" << map;
+ QTest::newRow("captureNames_invalid04") << "(?|(?<noun1>a)|(?<noun2>b))" << map;
+}
+
+void tst_QRegularExpression::captureNames()
+{
+ QFETCH(QString, pattern);
+ QFETCH(StringToIntMap, namedCapturesIndexMap);
+
+ const QRegularExpression re(pattern);
+ QStringList namedCaptureGroups = re.namedCaptureGroups();
+ int namedCaptureGroupsCount = namedCaptureGroups.size();
+
+ QCOMPARE(namedCaptureGroupsCount, re.captureCount() + 1);
+
+ for (int i = 0; i < namedCaptureGroupsCount; ++i) {
+ const QString &name = namedCaptureGroups.at(i);
+
+ if (name.isEmpty()) {
+ QVERIFY(!namedCapturesIndexMap.contains(name));
+ } else {
+ QVERIFY(namedCapturesIndexMap.contains(name));
+ QCOMPARE(i, namedCapturesIndexMap.value(name));
+ }
+ }
+
+}
+
void tst_QRegularExpression::pcreJitStackUsage_data()
{
QTest::addColumn<QString>("pattern");
@@ -1389,3 +1550,35 @@ void tst_QRegularExpression::regularExpressionMatch()
QTest::ignoreMessage(QtWarningMsg, "QRegularExpressionMatch::captured: empty capturing group name passed");
QCOMPARE(match.captured(QString()).isNull(), true);
}
+
+void tst_QRegularExpression::JOptionUsage_data()
+{
+ QTest::addColumn<QString>("pattern");
+ QTest::addColumn<bool>("isValid");
+ QTest::addColumn<bool>("JOptionUsed");
+
+ QTest::newRow("joption-notused-01") << "a.*b" << true << false;
+ QTest::newRow("joption-notused-02") << "^a(b)(c)$" << true << false;
+ QTest::newRow("joption-notused-03") << "a(b)(?<c>d)|e" << true << false;
+ QTest::newRow("joption-notused-04") << "(?<a>.)(?<a>.)" << false << false;
+
+ QTest::newRow("joption-used-01") << "(?J)a.*b" << true << true;
+ QTest::newRow("joption-used-02") << "(?-J)a.*b" << true << true;
+ QTest::newRow("joption-used-03") << "(?J)(?<a>.)(?<a>.)" << true << true;
+ QTest::newRow("joption-used-04") << "(?-J)(?<a>.)(?<a>.)" << false << true;
+
+}
+
+void tst_QRegularExpression::JOptionUsage()
+{
+ QFETCH(QString, pattern);
+ QFETCH(bool, isValid);
+ QFETCH(bool, JOptionUsed);
+
+ const QString warningMessage = QStringLiteral("QRegularExpressionPrivate::getPatternInfo(): the pattern '%1'\n is using the (?J) option; duplicate capturing group names are not supported by Qt");
+
+ QRegularExpression re(pattern);
+ if (isValid && JOptionUsed)
+ QTest::ignoreMessage(QtWarningMsg, qPrintable(warningMessage.arg(pattern)));
+ QCOMPARE(re.isValid(), isValid);
+}
diff --git a/tests/auto/corelib/tools/qregularexpression/tst_qregularexpression.h b/tests/auto/corelib/tools/qregularexpression/tst_qregularexpression.h
index d6f9312411..0f62570114 100644
--- a/tests/auto/corelib/tools/qregularexpression/tst_qregularexpression.h
+++ b/tests/auto/corelib/tools/qregularexpression/tst_qregularexpression.h
@@ -51,6 +51,7 @@ class tst_QRegularExpression : public QObject
Q_OBJECT
private slots:
+ void defaultConstructors();
void gettersSetters_data();
void gettersSetters();
void escape_data();
@@ -71,10 +72,14 @@ private slots:
void operatoreq();
void captureCount_data();
void captureCount();
+ void captureNames_data();
+ void captureNames();
void pcreJitStackUsage_data();
void pcreJitStackUsage();
void regularExpressionMatch_data();
void regularExpressionMatch();
+ void JOptionUsage_data();
+ void JOptionUsage();
private:
void provideRegularExpressions();
diff --git a/tests/auto/corelib/tools/qset/tst_qset.cpp b/tests/auto/corelib/tools/qset/tst_qset.cpp
index a3232d05c3..eaa1c018ba 100644
--- a/tests/auto/corelib/tools/qset/tst_qset.cpp
+++ b/tests/auto/corelib/tools/qset/tst_qset.cpp
@@ -79,6 +79,7 @@ private slots:
void javaIterator();
void javaMutableIterator();
void makeSureTheComfortFunctionsCompile();
+ void initializerList();
};
void tst_QSet::operator_eq()
@@ -918,6 +919,27 @@ void tst_QSet::makeSureTheComfortFunctionsCompile()
set1 = set2 - set3;
}
+void tst_QSet::initializerList()
+{
+#ifdef Q_COMPILER_INITIALIZER_LISTS
+ QSet<int> set{1, 2, 3, 4, 5};
+ QCOMPARE(set.count(), 5);
+ QVERIFY(set.contains(1));
+ QVERIFY(set.contains(2));
+ QVERIFY(set.contains(3));
+ QVERIFY(set.contains(4));
+ QVERIFY(set.contains(5));
+
+ QSet<int> emptySet{};
+ QVERIFY(emptySet.isEmpty());
+
+ QSet<int> set3{{}, {}, {}};
+ QVERIFY(!set3.isEmpty());
+#else
+ QSKIP("Compiler doesn't support initializer lists");
+#endif
+}
+
QTEST_APPLESS_MAIN(tst_QSet)
#include "tst_qset.moc"
diff --git a/tests/auto/corelib/tools/qsharedpointer/externaltests.pri b/tests/auto/corelib/tools/qsharedpointer/externaltests.pri
index 10d30e3c76..b3a01f7990 100644
--- a/tests/auto/corelib/tools/qsharedpointer/externaltests.pri
+++ b/tests/auto/corelib/tools/qsharedpointer/externaltests.pri
@@ -4,4 +4,4 @@ cleanedQMAKESPEC = $$replace(QMAKESPEC, \\\\, /)
DEFINES += DEFAULT_MAKESPEC=\\\"$$cleanedQMAKESPEC\\\"
cross_compile:DEFINES += QTEST_NO_RTTI QTEST_CROSS_COMPILED
-wince*:DEFINES += QTEST_CROSS_COMPILED QTEST_NO_RTTI
+wince*:DEFINES += QTEST_CROSS_COMPILED QTEST_NO_RTTI
diff --git a/tests/auto/corelib/tools/qsharedpointer/tst_qsharedpointer.cpp b/tests/auto/corelib/tools/qsharedpointer/tst_qsharedpointer.cpp
index 8e10b757c8..5b1a2cf076 100644
--- a/tests/auto/corelib/tools/qsharedpointer/tst_qsharedpointer.cpp
+++ b/tests/auto/corelib/tools/qsharedpointer/tst_qsharedpointer.cpp
@@ -97,6 +97,7 @@ private slots:
void lambdaCustomDeleter();
#endif
void creating();
+ void creatingVariadic();
void creatingQObject();
void mixTrackingPointerCode();
void reentrancyWhileDestructing();
@@ -176,6 +177,49 @@ public:
int Data::generationCounter = 0;
int Data::destructorCounter = 0;
+struct NoDefaultConstructor1
+{
+ int i;
+ NoDefaultConstructor1(int i) : i(i) {}
+ NoDefaultConstructor1(uint j) : i(j + 42) {}
+};
+
+struct NoDefaultConstructorRef1
+{
+ int &i;
+ NoDefaultConstructorRef1(int &i) : i(i) {}
+};
+
+struct NoDefaultConstructor2
+{
+ void *ptr;
+ int i;
+ NoDefaultConstructor2(void *ptr, int i) : ptr(ptr), i(i) {}
+};
+
+struct NoDefaultConstructorRef2
+{
+ QString str;
+ int i;
+ NoDefaultConstructorRef2(QString &str, int i) : str(str), i(i) {}
+};
+
+struct NoDefaultConstructorConstRef2
+{
+ QString str;
+ int i;
+ NoDefaultConstructorConstRef2(const QString &str, int i) : str(str), i(i) {}
+ NoDefaultConstructorConstRef2(const QByteArray &ba, int i = 42) : str(QString::fromLatin1(ba)), i(i) {}
+};
+
+#ifdef Q_COMPILER_RVALUE_REFS
+struct NoDefaultConstructorRRef1
+{
+ int &i;
+ NoDefaultConstructorRRef1(int &&i) : i(i) {}
+};
+#endif
+
void tst_QSharedPointer::basics_data()
{
QTest::addColumn<bool>("isNull");
@@ -1436,6 +1480,82 @@ void tst_QSharedPointer::creating()
safetyCheck();
}
+void tst_QSharedPointer::creatingVariadic()
+{
+#if !defined(Q_COMPILER_RVALUE_REFS) || !defined(Q_COMPILER_VARIADIC_TEMPLATES)
+ QSKIP("This compiler is not in C++11 mode or it doesn't support rvalue refs and variadic templates");
+#else
+ int i = 42;
+
+ {
+ NoDefaultConstructor1(1); // control check
+ QSharedPointer<NoDefaultConstructor1> ptr = QSharedPointer<NoDefaultConstructor1>::create(1);
+ QCOMPARE(ptr->i, 1);
+
+ NoDefaultConstructor1(0u); // control check
+ ptr = QSharedPointer<NoDefaultConstructor1>::create(0u);
+ QCOMPARE(ptr->i, 42);
+
+ NoDefaultConstructor1 x(i); // control check
+ ptr = QSharedPointer<NoDefaultConstructor1>::create(i);
+ QCOMPARE(ptr->i, i);
+ }
+ {
+ NoDefaultConstructor2((void*)0, 1); // control check
+ QSharedPointer<NoDefaultConstructor2> ptr = QSharedPointer<NoDefaultConstructor2>::create((void*)0, 1);
+ QCOMPARE(ptr->i, 1);
+ QCOMPARE(ptr->ptr, (void*)0);
+
+ int *null = 0;
+ NoDefaultConstructor2(null, 2); // control check
+ ptr = QSharedPointer<NoDefaultConstructor2>::create(null, 2);
+ QCOMPARE(ptr->i, 2);
+ QCOMPARE(ptr->ptr, (void*)0);
+
+#ifdef Q_COMPILER_NULLPTR
+ NoDefaultConstructor2(nullptr, 3); // control check
+ ptr = QSharedPointer<NoDefaultConstructor2>::create(nullptr, 3);
+ QCOMPARE(ptr->i, 3);
+ QCOMPARE(ptr->ptr, (void*)nullptr);
+#endif
+ }
+ {
+ NoDefaultConstructorRef1 x(i); // control check
+ QSharedPointer<NoDefaultConstructorRef1> ptr = QSharedPointer<NoDefaultConstructorRef1>::create(i);
+ QCOMPARE(ptr->i, i);
+ QCOMPARE(&ptr->i, &i);
+ }
+ {
+ NoDefaultConstructorRRef1(1); // control check
+ QSharedPointer<NoDefaultConstructorRRef1> ptr = QSharedPointer<NoDefaultConstructorRRef1>::create(1);
+ QCOMPARE(ptr->i, 1);
+
+ NoDefaultConstructorRRef1(std::move(i)); // control check
+ ptr = QSharedPointer<NoDefaultConstructorRRef1>::create(std::move(i));
+ QCOMPARE(ptr->i, i);
+ }
+ {
+ QString text("Hello, World");
+ NoDefaultConstructorRef2(text, 1); // control check
+ QSharedPointer<NoDefaultConstructorRef2> ptr = QSharedPointer<NoDefaultConstructorRef2>::create(text, 1);
+ QCOMPARE(ptr->str, text);
+ QCOMPARE(ptr->i, 1);
+ }
+ {
+ QSharedPointer<NoDefaultConstructorConstRef2> ptr;
+ NoDefaultConstructorConstRef2(QLatin1String("string"), 1); // control check
+ ptr = QSharedPointer<NoDefaultConstructorConstRef2>::create(QLatin1String("string"), 1);
+ QCOMPARE(ptr->str, QString("string"));
+ QCOMPARE(ptr->i, 1);
+
+ NoDefaultConstructorConstRef2(QByteArray("bytearray")); // control check
+ ptr = QSharedPointer<NoDefaultConstructorConstRef2>::create(QByteArray("bytearray"));
+ QCOMPARE(ptr->str, QString("bytearray"));
+ QCOMPARE(ptr->i, 42);
+ }
+#endif
+}
+
void tst_QSharedPointer::creatingQObject()
{
{
@@ -1876,7 +1996,7 @@ void tst_QSharedPointer::invalidConstructs()
QByteArray body = code.toLatin1();
bool result = (test.*testFunction)(body);
- if (qgetenv("QTEST_EXTERNAL_DEBUG").toInt() > 0) {
+ if (!result || qgetenv("QTEST_EXTERNAL_DEBUG").toInt() > 0) {
qDebug("External test output:");
#ifdef Q_CC_MSVC
// MSVC prints errors to stdout
diff --git a/tests/auto/corelib/tools/qstring/tst_qstring.cpp b/tests/auto/corelib/tools/qstring/tst_qstring.cpp
index 7b7869d033..0a1af0a058 100644
--- a/tests/auto/corelib/tools/qstring/tst_qstring.cpp
+++ b/tests/auto/corelib/tools/qstring/tst_qstring.cpp
@@ -196,6 +196,8 @@ private slots:
void stringRef_local8Bit();
void fromLatin1();
void fromAscii();
+ void fromUcs4();
+ void toUcs4();
void arg();
void number();
void arg_fillChar_data();
@@ -239,7 +241,7 @@ private slots:
#ifdef QT_USE_ICU
void toUpperLower_icu();
#endif
-#if defined(QT_UNICODE_LITERAL) && (defined(Q_COMPILER_LAMBDA) || defined(Q_CC_GNU))
+#if !defined(QT_NO_UNICODE_LITERAL) && defined(Q_COMPILER_LAMBDA)
void literals();
#endif
void eightBitLiterals_data();
@@ -1005,10 +1007,12 @@ void tst_QString::sprintf()
a.sprintf("%s%n%s", "hello", &n1, "goodbye");
QCOMPARE(n1, 5);
QCOMPARE(a, QString("hellogoodbye"));
+#ifndef Q_CC_MINGW // does not know %ll
qlonglong n2;
a.sprintf("%s%s%lln%s", "foo", "bar", &n2, "whiz");
QCOMPARE((int)n2, 6);
QCOMPARE(a, QString("foobarwhiz"));
+#endif
}
/*
@@ -1160,8 +1164,6 @@ void tst_QString::indexOf()
options |= QRegularExpression::CaseInsensitiveOption;
QRegularExpression re(QRegularExpression::escape(needle), options);
- QEXPECT_FAIL("data58", "QRegularExpression does not support case folding", Continue);
- QEXPECT_FAIL("data59", "QRegularExpression does not support case folding", Continue);
QCOMPARE( haystack.indexOf(re, startpos), resultpos );
}
@@ -1434,6 +1436,55 @@ void tst_QString::contains()
QVERIFY(a.contains(QRegularExpression("[FG][HI]")));
QVERIFY(a.contains(QRegularExpression("[G][HE]")));
+ {
+ QRegularExpressionMatch match;
+ QVERIFY(!match.hasMatch());
+
+ QVERIFY(a.contains(QRegularExpression("[FG][HI]"), &match));
+ QVERIFY(match.hasMatch());
+ QCOMPARE(match.capturedStart(), 6);
+ QCOMPARE(match.capturedEnd(), 8);
+ QCOMPARE(match.captured(), QStringLiteral("GH"));
+
+ QVERIFY(a.contains(QRegularExpression("[G][HE]"), &match));
+ QVERIFY(match.hasMatch());
+ QCOMPARE(match.capturedStart(), 6);
+ QCOMPARE(match.capturedEnd(), 8);
+ QCOMPARE(match.captured(), QStringLiteral("GH"));
+
+ QVERIFY(a.contains(QRegularExpression("[f](.*)[FG]"), &match));
+ QVERIFY(match.hasMatch());
+ QCOMPARE(match.capturedStart(), 10);
+ QCOMPARE(match.capturedEnd(), 15);
+ QCOMPARE(match.captured(), QString("fGEFG"));
+ QCOMPARE(match.capturedStart(1), 11);
+ QCOMPARE(match.capturedEnd(1), 14);
+ QCOMPARE(match.captured(1), QStringLiteral("GEF"));
+
+ QVERIFY(a.contains(QRegularExpression("[f](.*)[F]"), &match));
+ QVERIFY(match.hasMatch());
+ QCOMPARE(match.capturedStart(), 10);
+ QCOMPARE(match.capturedEnd(), 14);
+ QCOMPARE(match.captured(), QString("fGEF"));
+ QCOMPARE(match.capturedStart(1), 11);
+ QCOMPARE(match.capturedEnd(1), 13);
+ QCOMPARE(match.captured(1), QStringLiteral("GE"));
+
+ QVERIFY(!a.contains(QRegularExpression("ZZZ"), &match));
+ // doesn't match, but ensure match didn't change
+ QVERIFY(match.hasMatch());
+ QCOMPARE(match.capturedStart(), 10);
+ QCOMPARE(match.capturedEnd(), 14);
+ QCOMPARE(match.captured(), QStringLiteral("fGEF"));
+ QCOMPARE(match.capturedStart(1), 11);
+ QCOMPARE(match.capturedEnd(1), 13);
+ QCOMPARE(match.captured(1), QStringLiteral("GE"));
+
+ // don't crash with a null pointer
+ QVERIFY(a.contains(QRegularExpression("[FG][HI]"), 0));
+ QVERIFY(!a.contains(QRegularExpression("ZZZ"), 0));
+ }
+
CREATE_REF(QLatin1String("FG"));
QVERIFY(a.contains(ref));
QVERIFY(a.contains(ref, Qt::CaseInsensitive));
@@ -3894,6 +3945,52 @@ void tst_QString::fromAscii()
QVERIFY(a.size() == 5);
}
+void tst_QString::fromUcs4()
+{
+ QString s;
+ s = QString::fromUcs4( 0 );
+ QVERIFY( s.isNull() );
+ QCOMPARE( s.size(), 0 );
+ s = QString::fromUcs4( 0, 0 );
+ QVERIFY( s.isNull() );
+ QCOMPARE( s.size(), 0 );
+ s = QString::fromUcs4( 0, 5 );
+ QVERIFY( s.isNull() );
+ QCOMPARE( s.size(), 0 );
+
+ uint nil = '\0';
+ s = QString::fromUcs4( &nil );
+ QVERIFY( !s.isNull() );
+ QCOMPARE( s.size(), 0 );
+ s = QString::fromUcs4( &nil, 0 );
+ QVERIFY( !s.isNull() );
+ QCOMPARE( s.size(), 0 );
+
+ uint bmp = 'a';
+ s = QString::fromUcs4( &bmp, 1 );
+ QVERIFY( !s.isNull() );
+ QCOMPARE( s.size(), 1 );
+
+ uint smp = 0x10000;
+ s = QString::fromUcs4( &smp, 1 );
+ QVERIFY( !s.isNull() );
+ QCOMPARE( s.size(), 2 );
+}
+
+void tst_QString::toUcs4()
+{
+ QString s;
+ QCOMPARE( s.toUcs4().size(), 0 );
+
+ QChar bmp = QLatin1Char('a');
+ s = QString(&bmp, 1);
+ QCOMPARE( s.toUcs4().size(), 1 );
+
+ QChar smp[] = { QChar::highSurrogate(0x10000), QChar::lowSurrogate(0x10000) };
+ s = QString(smp, 2);
+ QCOMPARE( s.toUcs4().size(), 1 );
+}
+
void tst_QString::arg()
{
/*
@@ -5201,6 +5298,9 @@ void tst_QString::QCharRefDetaching() const
void tst_QString::sprintfZU() const
{
+#ifdef Q_CC_MINGW
+ QSKIP("MinGW does not support '%zu'.");
+#else
{
QString string;
size_t s = 6;
@@ -5229,6 +5329,7 @@ void tst_QString::sprintfZU() const
string.sprintf("%zu %s\n", s, "foo");
QCOMPARE(string, QString::fromLatin1("6 foo\n"));
}
+#endif // !Q_CC_MINGW
}
void tst_QString::repeatedSignature() const
@@ -5396,7 +5497,7 @@ void tst_QString::toUpperLower_icu()
}
#endif
-#if defined(QT_UNICODE_LITERAL) && (defined(Q_COMPILER_LAMBDA) || defined(Q_CC_GNU))
+#if !defined(QT_NO_UNICODE_LITERAL) && defined(Q_COMPILER_LAMBDA)
// Only tested on c++0x compliant compiler or gcc
void tst_QString::literals()
{
diff --git a/tests/auto/corelib/tools/qstringref/tst_qstringref.cpp b/tests/auto/corelib/tools/qstringref/tst_qstringref.cpp
index 66f40e05cb..1045d5929f 100644
--- a/tests/auto/corelib/tools/qstringref/tst_qstringref.cpp
+++ b/tests/auto/corelib/tools/qstringref/tst_qstringref.cpp
@@ -69,6 +69,25 @@ private slots:
void compare_data();
void compare();
void operator_eqeq_nullstring();
+ void toNum();
+ void toDouble_data();
+ void toDouble();
+ void toFloat();
+ void toLong_data();
+ void toLong();
+ void toULong_data();
+ void toULong();
+ void toLongLong();
+ void toULongLong();
+ void toUInt();
+ void toInt();
+ void toShort();
+ void toUShort();
+ void double_conversion_data();
+ void double_conversion();
+ void integer_conversion_data();
+ void integer_conversion();
+ void trimmed();
};
static QStringRef emptyRef()
@@ -840,6 +859,941 @@ void tst_QStringRef::compare()
}
}
+void tst_QStringRef::toNum()
+{
+#define TEST_TO_INT(num, func, type) \
+ a = #num; \
+ b = a.leftRef(-1); \
+ QCOMPARE(b.func(&ok), type(Q_INT64_C(num))); \
+ QVERIFY2(ok, "Failed: num=" #num);
+
+ QString a;
+ QStringRef b;
+ bool ok = false;
+
+ TEST_TO_INT(0, toInt, int)
+ TEST_TO_INT(-1, toInt, int)
+ TEST_TO_INT(1, toInt, int)
+ TEST_TO_INT(2147483647, toInt, int)
+ TEST_TO_INT(-2147483648, toInt, int)
+
+ TEST_TO_INT(0, toShort, short)
+ TEST_TO_INT(-1, toShort, short)
+ TEST_TO_INT(1, toShort, short)
+ TEST_TO_INT(32767, toShort, short)
+ TEST_TO_INT(-32768, toShort, short)
+
+ TEST_TO_INT(0, toLong, long)
+ TEST_TO_INT(-1, toLong, long)
+ TEST_TO_INT(1, toLong, long)
+ TEST_TO_INT(2147483647, toLong, long)
+ TEST_TO_INT(-2147483648, toLong, long)
+ TEST_TO_INT(0, toLongLong, (long long))
+ TEST_TO_INT(-1, toLongLong, (long long))
+ TEST_TO_INT(1, toLongLong, (long long))
+ TEST_TO_INT(9223372036854775807, toLongLong, (long long))
+ TEST_TO_INT(-9223372036854775807, toLongLong, (long long))
+
+#undef TEST_TO_INT
+
+#define TEST_TO_UINT(num, func, type) \
+ a = #num; \
+ b = a.leftRef(-1); \
+ QCOMPARE(b.func(&ok), type(Q_UINT64_C(num))); \
+ QVERIFY2(ok, "Failed: num=" #num);
+
+ TEST_TO_UINT(0, toUInt, (unsigned int))
+ TEST_TO_UINT(1, toUInt, (unsigned int))
+ TEST_TO_UINT(4294967295, toUInt, (unsigned int))
+
+ TEST_TO_UINT(0, toUShort, (unsigned short))
+ TEST_TO_UINT(1, toUShort, (unsigned short))
+ TEST_TO_UINT(65535, toUShort, (unsigned short))
+
+ TEST_TO_UINT(0, toULong, (unsigned long))
+ TEST_TO_UINT(1, toULong, (unsigned long))
+ TEST_TO_UINT(4294967295, toULong, (unsigned long))
+
+ TEST_TO_UINT(0, toULongLong, (unsigned long long))
+ TEST_TO_UINT(1, toULongLong, (unsigned long long))
+ TEST_TO_UINT(18446744073709551615, toULongLong, (unsigned long long))
+
+#undef TEST_TO_UINT
+
+#define TEST_BASE(str, base, num) \
+ a = str; \
+ b = a.leftRef(-1); \
+ QCOMPARE(b.toInt(&ok,base), int(num)); \
+ QVERIFY2(ok, "Failed: str=" #str " base= " #base " num=" #num ", func=toInt"); \
+ QCOMPARE(b.toUInt(&ok, base), (unsigned int)(num)); \
+ QVERIFY2(ok, "Failed: str=" #str " base= " #base " num=" #num ", func=toUInt"); \
+ QCOMPARE(b.toShort(&ok, base), short(num)); \
+ QVERIFY2(ok, "Failed: str=" #str " base= " #base " num=" #num ", func=toShort"); \
+ QCOMPARE(b.toUShort(&ok, base), (unsigned short)(num)); \
+ QVERIFY2(ok, "Failed: str=" #str " base= " #base " num=" #num ", func=toUShort"); \
+ QCOMPARE(b.toLong(&ok, base), long(num)); \
+ QVERIFY2(ok, "Failed: str=" #str " base= " #base " num=" #num ", func=toLong"); \
+ QCOMPARE(b.toULong(&ok, base), (unsigned long)(num)); \
+ QVERIFY2(ok, "Failed: str=" #str " base= " #base " num=" #num ", func=toULong"); \
+ QCOMPARE(b.toLongLong(&ok, base), (long long)(num)); \
+ QVERIFY2(ok, "Failed: str=" #str " base= " #base " num=" #num ", func=toLongLong"); \
+ QCOMPARE(b.toULongLong(&ok, base), (unsigned long long)(num)); \
+ QVERIFY2(ok, "Failed: str=" #str " base= " #base " num=" #num ", func=toULongLong");
+
+ TEST_BASE("FF", 16, 255)
+ TEST_BASE("0xFF", 16, 255)
+ TEST_BASE("77", 8, 63)
+ TEST_BASE("077", 8, 63)
+
+ TEST_BASE("0xFF", 0, 255)
+ TEST_BASE("077", 0, 63)
+ TEST_BASE("255", 0, 255)
+
+ TEST_BASE(" FF", 16, 255)
+ TEST_BASE(" 0xFF", 16, 255)
+ TEST_BASE(" 77", 8, 63)
+ TEST_BASE(" 077", 8, 63)
+
+ TEST_BASE(" 0xFF", 0, 255)
+ TEST_BASE(" 077", 0, 63)
+ TEST_BASE(" 255", 0, 255)
+
+ TEST_BASE("\tFF\t", 16, 255)
+ TEST_BASE("\t0xFF ", 16, 255)
+ TEST_BASE(" 77 ", 8, 63)
+ TEST_BASE("77 ", 8, 63)
+
+#undef TEST_BASE
+
+#define TEST_NEG_BASE(str, base, num) \
+ a = str; \
+ b = a.leftRef(-1); \
+ QCOMPARE(b.toInt(&ok, base), int(num)); \
+ QVERIFY2(ok, "Failed: str=" #str " base= "#base " num=" #num ", func=toInt"); \
+ QCOMPARE(b.toShort(&ok,base), short(num)); \
+ QVERIFY2(ok, "Failed: str=" #str " base= "#base " num=" #num ", func=toShort"); \
+ QCOMPARE(b.toLong(&ok, base), long(num)); \
+ QVERIFY2(ok, "Failed: str=" #str " base= "#base " num=" #num ", func=toLong"); \
+ QCOMPARE(b.toLongLong(&ok, base), (long long)(num)); \
+ QVERIFY2(ok, "Failed: str=" #str " base= "#base " num=" #num ", func=toLongLong");
+
+ TEST_NEG_BASE("-FE", 16, -254)
+ TEST_NEG_BASE("-0xFE", 16, -254)
+ TEST_NEG_BASE("-77", 8, -63)
+ TEST_NEG_BASE("-077", 8, -63)
+
+ TEST_NEG_BASE("-0xFE", 0, -254)
+ TEST_NEG_BASE("-077", 0, -63)
+ TEST_NEG_BASE("-254", 0, -254)
+
+#undef TEST_NEG_BASE
+
+#define TEST_DOUBLE(num, str) \
+ a = str; \
+ b = a.leftRef(-1); \
+ QCOMPARE(b.toDouble(&ok), num); \
+ QVERIFY(ok);
+
+ TEST_DOUBLE(1.2345, "1.2345")
+ TEST_DOUBLE(12.345, "1.2345e+01")
+ TEST_DOUBLE(12.345, "1.2345E+01")
+ TEST_DOUBLE(12345.6, "12345.6")
+
+#undef TEST_DOUBLE
+
+#define TEST_BAD(str, func) \
+ a = str; \
+ b = a.leftRef(-1); \
+ b.func(&ok); \
+ QVERIFY2(!ok, "Failed: str=" #str " func=" #func);
+
+ TEST_BAD("32768", toShort)
+ TEST_BAD("-32769", toShort)
+ TEST_BAD("65536", toUShort)
+ TEST_BAD("2147483648", toInt)
+ TEST_BAD("-2147483649", toInt)
+ TEST_BAD("4294967296", toUInt)
+ if (sizeof(long) == 4) {
+ TEST_BAD("2147483648", toLong)
+ TEST_BAD("-2147483649", toLong)
+ TEST_BAD("4294967296", toULong)
+ }
+ TEST_BAD("9223372036854775808", toLongLong)
+ TEST_BAD("-9223372036854775809", toLongLong)
+ TEST_BAD("18446744073709551616", toULongLong)
+ TEST_BAD("-1", toUShort)
+ TEST_BAD("-1", toUInt)
+ TEST_BAD("-1", toULong)
+ TEST_BAD("-1", toULongLong)
+
+#undef TEST_BAD
+
+#define TEST_BAD_ALL(str) \
+ a = str; \
+ b = a.leftRef(-1); \
+ b.toShort(&ok); \
+ QVERIFY2(!ok, "Failed: str=" #str); \
+ b.toUShort(&ok); \
+ QVERIFY2(!ok, "Failed: str=" #str); \
+ b.toInt(&ok); \
+ QVERIFY2(!ok, "Failed: str=" #str); \
+ b.toUInt(&ok); \
+ QVERIFY2(!ok, "Failed: str=" #str); \
+ b.toLong(&ok); \
+ QVERIFY2(!ok, "Failed: str=" #str); \
+ b.toULong(&ok); \
+ QVERIFY2(!ok, "Failed: str=" #str); \
+ b.toLongLong(&ok); \
+ QVERIFY2(!ok, "Failed: str=" #str); \
+ b.toULongLong(&ok); \
+ QVERIFY2(!ok, "Failed: str=" #str); \
+ b.toFloat(&ok); \
+ QVERIFY2(!ok, "Failed: str=" #str); \
+ b.toDouble(&ok); \
+ QVERIFY2(!ok, "Failed: str=" #str);
+
+ TEST_BAD_ALL((const char*)0);
+ TEST_BAD_ALL("");
+ TEST_BAD_ALL(" ");
+ TEST_BAD_ALL(".");
+ TEST_BAD_ALL("-");
+ TEST_BAD_ALL("hello");
+ TEST_BAD_ALL("1.2.3");
+ TEST_BAD_ALL("0x0x0x");
+ TEST_BAD_ALL("123-^~<");
+ TEST_BAD_ALL("123ThisIsNotANumber");
+
+#undef TEST_BAD_ALL
+
+ a = "FF";
+ b = a.leftRef(-1);
+ b.toULongLong(&ok, 10);
+ QVERIFY(!ok);
+
+ a = "FF";
+ b = a.leftRef(-1);
+ b.toULongLong(&ok, 0);
+ QVERIFY(!ok);
+
+#ifdef QT_NO_FPU
+ double d = 3.40282346638528e+38; // slightly off FLT_MAX when using hardfloats
+#else
+ double d = 3.4028234663852886e+38; // FLT_MAX
+#endif
+ QString::number(d, 'e', 17).leftRef(-1).toFloat(&ok);
+ QVERIFY(ok);
+ QString::number(d + 1e32, 'e', 17).leftRef(-1).toFloat(&ok);
+ QVERIFY(!ok);
+ a = QString::number(-d, 'e', 17).leftRef(-1).toFloat(&ok);
+ QVERIFY(ok);
+ QString::number(-d - 1e32, 'e', 17).leftRef(-1).toFloat(&ok);
+ QVERIFY(!ok);
+ QString::number(d + 1e32, 'e', 17).leftRef(-1).toDouble(&ok);
+ QVERIFY(ok);
+ QString::number(-d - 1e32, 'e', 17).leftRef(-1).toDouble(&ok);
+ QVERIFY(ok);
+}
+
+void tst_QStringRef::toUShort()
+{
+ QString a;
+ QStringRef b;
+ bool ok;
+ QCOMPARE(b.toUShort(), ushort(0));
+ QCOMPARE(b.toUShort(&ok), ushort(0));
+ QVERIFY(!ok);
+
+ a = "";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(0));
+ QCOMPARE(b.toUShort(&ok), ushort(0));
+ QVERIFY(!ok);
+
+ a = "COMPARE";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(0));
+ QCOMPARE(b.toUShort(&ok), ushort(0));
+ QVERIFY(!ok);
+
+ a = "123";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(123));
+ QCOMPARE(b.toUShort(&ok), ushort(123));
+ QVERIFY(ok);
+
+ a = "123A";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(0));
+ QCOMPARE(b.toUShort(&ok), ushort(0));
+ QVERIFY(!ok);
+
+ a = "1234567";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(0));
+ QCOMPARE(b.toUShort(&ok), ushort(0));
+ QVERIFY(!ok);
+
+ a = "aaa123aaa";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(0));
+ QCOMPARE(b.toUShort(&ok), ushort(0));
+ QVERIFY(!ok);
+
+ a = "aaa123";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(0));
+ QCOMPARE(b.toUShort(&ok), ushort(0));
+ QVERIFY(!ok);
+
+ a = "123aaa";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(0));
+ QCOMPARE(b.toUShort(&ok), ushort(0));
+ QVERIFY(!ok);
+
+ a = "32767";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(32767));
+ QCOMPARE(b.toUShort(&ok), ushort(32767));
+ QVERIFY(ok);
+
+ a = "-32767";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(0));
+ QCOMPARE(b.toUShort(&ok), ushort(0));
+ QVERIFY(!ok);
+
+ a = "65535";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(65535));
+ QCOMPARE(b.toUShort(&ok), ushort(65535));
+ QVERIFY(ok);
+
+ if (sizeof(short) == 2) {
+ a = "65536";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(0));
+ QCOMPARE(b.toUShort(&ok), ushort(0));
+ QVERIFY(!ok);
+
+ a = "123456";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUShort(), ushort(0));
+ QCOMPARE(b.toUShort(&ok), ushort(0));
+ QVERIFY(!ok);
+ }
+}
+
+void tst_QStringRef::toShort()
+{
+ QString a;
+ QStringRef b;
+ bool ok;
+ QCOMPARE(b.toShort(), short(0));
+ QCOMPARE(b.toShort(&ok), short(0));
+ QVERIFY(!ok);
+
+ a = "";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(0));
+ QCOMPARE(b.toShort(&ok), short(0));
+ QVERIFY(!ok);
+
+ a = "COMPARE";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(0));
+ QCOMPARE(b.toShort(&ok), short(0));
+ QVERIFY(!ok);
+
+ a = "123";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(123));
+ QCOMPARE(b.toShort(&ok), short(123));
+ QVERIFY(ok);
+
+ a = "123A";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(0));
+ QCOMPARE(b.toShort(&ok), short(0));
+ QVERIFY(!ok);
+
+ a = "1234567";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(0));
+ QCOMPARE(b.toShort(&ok), short(0));
+ QVERIFY(!ok);
+
+ a = "aaa123aaa";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(0));
+ QCOMPARE(b.toShort(&ok), short(0));
+ QVERIFY(!ok);
+
+ a = "aaa123";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(0));
+ QCOMPARE(b.toShort(&ok), short(0));
+ QVERIFY(!ok);
+
+ a = "123aaa";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(0));
+ QCOMPARE(b.toShort(&ok), short(0));
+ QVERIFY(!ok);
+
+ a = "32767";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(32767));
+ QCOMPARE(b.toShort(&ok), short(32767));
+ QVERIFY(ok);
+
+ a = "-32767";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(-32767));
+ QCOMPARE(b.toShort(&ok), short(-32767));
+ QVERIFY(ok);
+
+ a = "-32768";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(-32768));
+ QCOMPARE(b.toShort(&ok), short(-32768));
+ QVERIFY(ok);
+
+ if (sizeof(short) == 2) {
+ a = "32768";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(0));
+ QCOMPARE(b.toShort(&ok), short(0));
+ QVERIFY(!ok);
+
+ a = "-32769";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toShort(), short(0));
+ QCOMPARE(b.toShort(&ok), short(0));
+ QVERIFY(!ok);
+ }
+}
+
+void tst_QStringRef::toInt()
+{
+ QString a;
+ QStringRef b;
+ bool ok;
+ QCOMPARE(b.toInt(), 0);
+ QCOMPARE(b.toInt(&ok), 0);
+ QVERIFY(!ok);
+
+ a = "";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 0);
+ QCOMPARE(b.toInt(&ok), 0);
+ QVERIFY(!ok);
+
+ a = "COMPARE";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 0);
+ QCOMPARE(b.toInt(&ok), 0);
+ QVERIFY(!ok);
+
+ a = "123";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 123);
+ QCOMPARE(b.toInt(&ok), 123);
+ QVERIFY(ok);
+
+ a = "123A";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 0);
+ QCOMPARE(b.toInt(&ok), 0);
+ QVERIFY(!ok);
+
+ a = "1234567";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 1234567);
+ QCOMPARE(b.toInt(&ok), 1234567);
+ QVERIFY(ok);
+
+ a = "12345678901234";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 0);
+ QCOMPARE(b.toInt(&ok), 0);
+ QVERIFY(!ok);
+
+ a = "3234567890";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 0);
+ QCOMPARE(b.toInt(&ok), 0);
+ QVERIFY(!ok);
+
+ a = "aaa12345aaa";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 0);
+ QCOMPARE(b.toInt(&ok), 0);
+ QVERIFY(!ok);
+
+ a = "aaa12345";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 0);
+ QCOMPARE(b.toInt(&ok), 0);
+ QVERIFY(!ok);
+
+ a = "12345aaa";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 0);
+ QCOMPARE(b.toInt(&ok), 0);
+ QVERIFY(!ok);
+
+ a = "2147483647"; // 2**31 - 1
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 2147483647);
+ QCOMPARE(b.toInt(&ok), 2147483647);
+ QVERIFY(ok);
+
+ if (sizeof(int) == 4) {
+ a = "-2147483647"; // -(2**31 - 1)
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), -2147483647);
+ QCOMPARE(b.toInt(&ok), -2147483647);
+ QVERIFY(ok);
+
+ a = "2147483648"; // 2**31
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 0);
+ QCOMPARE(b.toInt(&ok), 0);
+ QVERIFY(!ok);
+
+ a = "-2147483648"; // -2**31
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), -2147483647 - 1);
+ QCOMPARE(b.toInt(&ok), -2147483647 - 1);
+ QVERIFY(ok);
+
+ a = "2147483649"; // 2**31 + 1
+ b = a.leftRef(-1);
+ QCOMPARE(b.toInt(), 0);
+ QCOMPARE(b.toInt(&ok), 0);
+ QVERIFY(!ok);
+ }
+}
+
+void tst_QStringRef::toUInt()
+{
+ bool ok;
+ QString a;
+ QStringRef b;
+ a = "3234567890";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUInt(&ok), 3234567890u);
+ QVERIFY(ok);
+
+ a = "-50";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUInt(), 0u);
+ QCOMPARE(b.toUInt(&ok), 0u);
+ QVERIFY(!ok);
+
+ a = "4294967295"; // 2**32 - 1
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUInt(), 4294967295u);
+ QCOMPARE(b.toUInt(&ok), 4294967295u);
+ QVERIFY(ok);
+
+ if (sizeof(int) == 4) {
+ a = "4294967296"; // 2**32
+ b = a.leftRef(-1);
+ QCOMPARE(b.toUInt(), 0u);
+ QCOMPARE(b.toUInt(&ok), 0u);
+ QVERIFY(!ok);
+ }
+}
+
+///////////////////////////// to*Long //////////////////////////////////////
+
+void tst_QStringRef::toULong_data()
+{
+ QTest::addColumn<QString>("str");
+ QTest::addColumn<int>("base");
+ QTest::addColumn<ulong>("result");
+ QTest::addColumn<bool>("ok");
+
+ QTest::newRow("default") << QString() << 10 << 0UL << false;
+ QTest::newRow("empty") << QString("") << 10 << 0UL << false;
+ QTest::newRow("ulong1") << QString("3234567890") << 10 << 3234567890UL << true;
+ QTest::newRow("ulong2") << QString("fFFfFfFf") << 16 << 0xFFFFFFFFUL << true;
+}
+
+void tst_QStringRef::toULong()
+{
+ QFETCH(QString, str);
+ QFETCH(int, base);
+ QFETCH(ulong, result);
+ QFETCH(bool, ok);
+ QStringRef strRef = str.leftRef(-1);
+
+ bool b;
+ QCOMPARE(strRef.toULong(0, base), result);
+ QCOMPARE(strRef.toULong(&b, base), result);
+ QCOMPARE(b, ok);
+}
+
+void tst_QStringRef::toLong_data()
+{
+ QTest::addColumn<QString>("str");
+ QTest::addColumn<int>("base");
+ QTest::addColumn<long>("result");
+ QTest::addColumn<bool>("ok");
+
+ QTest::newRow("default") << QString() << 10 << 0L << false;
+ QTest::newRow("empty") << QString("") << 10 << 0L << false;
+ QTest::newRow("normal") << QString("7fFFfFFf") << 16 << 0x7fFFfFFfL << true;
+ QTest::newRow("long_max") << QString("2147483647") << 10 << 2147483647L << true;
+ if (sizeof(long) == 4) {
+ QTest::newRow("long_max+1") << QString("2147483648") << 10 << 0L << false;
+ QTest::newRow("long_min-1") << QString("-80000001") << 16 << 0L << false;
+ }
+ QTest::newRow("negative") << QString("-7fffffff") << 16 << -0x7fffffffL << true;
+// QTest::newRow("long_min") << QString("-80000000") << 16 << 0x80000000uL << true;
+}
+
+void tst_QStringRef::toLong()
+{
+ QFETCH(QString, str);
+ QFETCH(int, base);
+ QFETCH(long, result);
+ QFETCH(bool, ok);
+ QStringRef strRef = str.leftRef(-1);
+
+ bool b;
+ QCOMPARE(strRef.toLong(0, base), result);
+ QCOMPARE(strRef.toLong(&b, base), result);
+ QCOMPARE(b, ok);
+}
+
+
+////////////////////////// to*LongLong //////////////////////////////////////
+
+void tst_QStringRef::toULongLong()
+{
+ QString str;
+ QStringRef strRef;
+ bool ok;
+ str = "18446744073709551615"; // ULLONG_MAX
+ strRef = str.leftRef(-1);
+ QCOMPARE(strRef.toULongLong(0), Q_UINT64_C(18446744073709551615));
+ QCOMPARE(strRef.toULongLong(&ok), Q_UINT64_C(18446744073709551615));
+ QVERIFY(ok);
+
+ str = "18446744073709551616"; // ULLONG_MAX + 1
+ strRef = str.leftRef(-1);
+ QCOMPARE(strRef.toULongLong(0), Q_UINT64_C(0));
+ QCOMPARE(strRef.toULongLong(&ok), Q_UINT64_C(0));
+ QVERIFY(!ok);
+
+ str = "-150";
+ strRef = str.leftRef(-1);
+ QCOMPARE(strRef.toULongLong(0), Q_UINT64_C(0));
+ QCOMPARE(strRef.toULongLong(&ok), Q_UINT64_C(0));
+ QVERIFY(!ok);
+}
+
+void tst_QStringRef::toLongLong()
+{
+ QString str;
+ QStringRef strRef;
+ bool ok;
+
+ str = "9223372036854775807"; // LLONG_MAX
+ strRef = str.leftRef(-1);
+ QCOMPARE(strRef.toLongLong(0), Q_INT64_C(9223372036854775807));
+ QCOMPARE(strRef.toLongLong(&ok), Q_INT64_C(9223372036854775807));
+ QVERIFY(ok);
+
+ str = "-9223372036854775808"; // LLONG_MIN
+ strRef = str.leftRef(-1);
+ QCOMPARE(strRef.toLongLong(0),
+ -Q_INT64_C(9223372036854775807) - Q_INT64_C(1));
+ QCOMPARE(strRef.toLongLong(&ok),
+ -Q_INT64_C(9223372036854775807) - Q_INT64_C(1));
+ QVERIFY(ok);
+
+ str = "aaaa9223372036854775807aaaa";
+ strRef = str.leftRef(-1);
+ QCOMPARE(strRef.toLongLong(0), Q_INT64_C(0));
+ QCOMPARE(strRef.toLongLong(&ok), Q_INT64_C(0));
+ QVERIFY(!ok);
+
+ str = "9223372036854775807aaaa";
+ strRef = str.leftRef(-1);
+ QCOMPARE(strRef.toLongLong(0), Q_INT64_C(0));
+ QCOMPARE(strRef.toLongLong(&ok), Q_INT64_C(0));
+ QVERIFY(!ok);
+
+ str = "aaaa9223372036854775807";
+ strRef = str.leftRef(-1);
+ QCOMPARE(strRef.toLongLong(0), Q_INT64_C(0));
+ QCOMPARE(strRef.toLongLong(&ok), Q_INT64_C(0));
+ QVERIFY(!ok);
+
+ static char digits[] = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ";
+
+ for (int i = 0; i < 36; ++i) {
+ for (int j = 0; j < 36; ++j) {
+ for (int k = 0; k < 36; ++k) {
+ QString str;
+ str += QChar(digits[i]);
+ str += QChar(digits[j]);
+ str += QChar(digits[k]);
+ strRef = str.leftRef(-1);
+ qlonglong value = (((i * 36) + j) * 36) + k;
+ QVERIFY(strRef.toLongLong(0, 36) == value);
+ }
+ }
+ }
+}
+
+////////////////////////////////////////////////////////////////////////////
+
+void tst_QStringRef::toFloat()
+{
+ QString a;
+ QStringRef b;
+ bool ok;
+ a = "0.000000000931322574615478515625";
+ b = a.leftRef(-1);
+ QCOMPARE(b.toFloat(&ok), float(0.000000000931322574615478515625));
+ QVERIFY(ok);
+}
+
+void tst_QStringRef::toDouble_data()
+{
+ QTest::addColumn<QString>("str");
+ QTest::addColumn<double>("result");
+ QTest::addColumn<bool>("result_ok");
+
+ QTest::newRow("ok00") << QString("0.000000000931322574615478515625") << 0.000000000931322574615478515625 << true;
+ QTest::newRow("ok01") << QString(" 123.45") << 123.45 << true;
+
+ QTest::newRow("ok02") << QString("0.1e10") << 0.1e10 << true;
+ QTest::newRow("ok03") << QString("0.1e-10") << 0.1e-10 << true;
+
+ QTest::newRow("ok04") << QString("1e10") << 1.0e10 << true;
+ QTest::newRow("ok05") << QString("1e+10") << 1.0e10 << true;
+ QTest::newRow("ok06") << QString("1e-10") << 1.0e-10 << true;
+
+ QTest::newRow("ok07") << QString(" 1e10") << 1.0e10 << true;
+ QTest::newRow("ok08") << QString(" 1e+10") << 1.0e10 << true;
+ QTest::newRow("ok09") << QString(" 1e-10") << 1.0e-10 << true;
+
+ QTest::newRow("ok10") << QString("1.") << 1.0 << true;
+ QTest::newRow("ok11") << QString(".1") << 0.1 << true;
+
+ QTest::newRow("wrong00") << QString("123.45 ") << 123.45 << true;
+ QTest::newRow("wrong01") << QString(" 123.45 ") << 123.45 << true;
+
+ QTest::newRow("wrong02") << QString("aa123.45aa") << 0.0 << false;
+ QTest::newRow("wrong03") << QString("123.45aa") << 0.0 << false;
+ QTest::newRow("wrong04") << QString("123erf") << 0.0 << false;
+
+ QTest::newRow("wrong05") << QString("abc") << 0.0 << false;
+ QTest::newRow("wrong06") << QString() << 0.0 << false;
+ QTest::newRow("wrong07") << QString("") << 0.0 << false;
+}
+
+void tst_QStringRef::toDouble()
+{
+ QFETCH(QString, str);
+ QFETCH(bool, result_ok);
+ QStringRef strRef = str.leftRef(-1);
+ bool ok;
+ double d = strRef.toDouble(&ok);
+ if (result_ok) {
+ QTEST(d, "result");
+ QVERIFY(ok);
+ } else {
+ QVERIFY(!ok);
+ }
+}
+
+void tst_QStringRef::integer_conversion_data()
+{
+ QTest::addColumn<QString>("num_str");
+ QTest::addColumn<int>("base");
+ QTest::addColumn<bool>("good");
+ QTest::addColumn<qlonglong>("num");
+
+ QTest::newRow("C empty 0") << QString("") << 0 << false << (qlonglong)0;
+ QTest::newRow("C empty 8") << QString("") << 8 << false << (qlonglong)0;
+ QTest::newRow("C empty 10") << QString("") << 10 << false << (qlonglong)0;
+ QTest::newRow("C empty 16") << QString("") << 16 << false << (qlonglong)0;
+
+ QTest::newRow("C null 0") << QString() << 0 << false << (qlonglong)0;
+ QTest::newRow("C null 8") << QString() << 8 << false << (qlonglong)0;
+ QTest::newRow("C null 10") << QString() << 10 << false << (qlonglong)0;
+ QTest::newRow("C null 16") << QString() << 16 << false << (qlonglong)0;
+
+ QTest::newRow("C -0xf 0") << QString(" -0xf") << 0 << true << (qlonglong)-15;
+ QTest::newRow("C -0xf 0") << QString("-0xf ") << 0 << true << (qlonglong)-15;
+ QTest::newRow("C \t0xf\t 0") << QString("\t0xf\t") << 0 << true << (qlonglong)15;
+ QTest::newRow("C -010 0") << QString(" -010") << 0 << true << (qlonglong)-8;
+ QTest::newRow("C 010 0") << QString("010 ") << 0 << true << (qlonglong)8;
+ QTest::newRow("C \t-010\t 0") << QString("\t-010\t") << 0 << true << (qlonglong)-8;
+ QTest::newRow("C 123 10") << QString(" 123") << 10 << true << (qlonglong)123;
+ QTest::newRow("C 123 10") << QString("123 ") << 10 << true << (qlonglong)123;
+ QTest::newRow("C \t123\t 10") << QString("\t123\t") << 10 << true << (qlonglong)123;
+ QTest::newRow("C -0xf 16") << QString(" -0xf") << 16 << true << (qlonglong)-15;
+ QTest::newRow("C -0xf 16") << QString("-0xf ") << 16 << true << (qlonglong)-15;
+ QTest::newRow("C \t0xf\t 16") << QString("\t0xf\t") << 16 << true << (qlonglong)15;
+
+ QTest::newRow("C -0 0") << QString("-0") << 0 << true << (qlonglong)0;
+ QTest::newRow("C -0 8") << QString("-0") << 8 << true << (qlonglong)0;
+ QTest::newRow("C -0 10") << QString("-0") << 10 << true << (qlonglong)0;
+ QTest::newRow("C -0 16") << QString("-0") << 16 << true << (qlonglong)0;
+
+ QTest::newRow("C 1.234 10") << QString("1.234") << 10 << false << (qlonglong)0;
+ QTest::newRow("C 1,234 10") << QString("1,234") << 10 << false << (qlonglong)0;
+
+ QTest::newRow("C 0x 0") << QString("0x") << 0 << false << (qlonglong)0;
+ QTest::newRow("C 0x 16") << QString("0x") << 16 << false << (qlonglong)0;
+
+ QTest::newRow("C 10 0") << QString("10") << 0 << true << (qlonglong)10;
+ QTest::newRow("C 010 0") << QString("010") << 0 << true << (qlonglong)8;
+ QTest::newRow("C 0x10 0") << QString("0x10") << 0 << true << (qlonglong)16;
+ QTest::newRow("C 10 8") << QString("10") << 8 << true << (qlonglong)8;
+ QTest::newRow("C 010 8") << QString("010") << 8 << true << (qlonglong)8;
+ QTest::newRow("C 0x10 8") << QString("0x10") << 8 << false << (qlonglong)0;
+ QTest::newRow("C 10 10") << QString("10") << 10 << true << (qlonglong)10;
+ QTest::newRow("C 010 10") << QString("010") << 10 << true << (qlonglong)10;
+ QTest::newRow("C 0x10 10") << QString("0x10") << 10 << false << (qlonglong)0;
+ QTest::newRow("C 10 16") << QString("10") << 16 << true << (qlonglong)16;
+ QTest::newRow("C 010 16") << QString("010") << 16 << true << (qlonglong)16;
+ QTest::newRow("C 0x10 16") << QString("0x10") << 16 << true << (qlonglong)16;
+
+ QTest::newRow("C -10 0") << QString("-10") << 0 << true << (qlonglong)-10;
+ QTest::newRow("C -010 0") << QString("-010") << 0 << true << (qlonglong)-8;
+ QTest::newRow("C -0x10 0") << QString("-0x10") << 0 << true << (qlonglong)-16;
+ QTest::newRow("C -10 8") << QString("-10") << 8 << true << (qlonglong)-8;
+ QTest::newRow("C -010 8") << QString("-010") << 8 << true << (qlonglong)-8;
+ QTest::newRow("C -0x10 8") << QString("-0x10") << 8 << false << (qlonglong)0;
+ QTest::newRow("C -10 10") << QString("-10") << 10 << true << (qlonglong)-10;
+ QTest::newRow("C -010 10") << QString("-010") << 10 << true << (qlonglong)-10;
+ QTest::newRow("C -0x10 10") << QString("-0x10") << 10 << false << (qlonglong)0;
+ QTest::newRow("C -10 16") << QString("-10") << 16 << true << (qlonglong)-16;
+ QTest::newRow("C -010 16") << QString("-010") << 16 << true << (qlonglong)-16;
+ QTest::newRow("C -0x10 16") << QString("-0x10") << 16 << true << (qlonglong)-16;
+
+ // Let's try some Arabic
+ const quint16 arabic_str[] = { 0x0661, 0x0662, 0x0663, 0x0664, 0x0000 }; // "1234"
+ QTest::newRow("ar_SA 1234 0") << QString::fromUtf16(arabic_str) << 0 << false << (qlonglong)0;
+}
+
+void tst_QStringRef::integer_conversion()
+{
+ QFETCH(QString, num_str);
+ QFETCH(int, base);
+ QFETCH(bool, good);
+ QFETCH(qlonglong, num);
+ QStringRef num_strRef = num_str.leftRef(-1);
+
+ bool ok;
+ qlonglong d = num_strRef.toLongLong(&ok, base);
+ QCOMPARE(ok, good);
+
+ if (ok) {
+ QCOMPARE(d, num);
+ }
+}
+
+void tst_QStringRef::double_conversion_data()
+{
+ QTest::addColumn<QString>("num_str");
+ QTest::addColumn<bool>("good");
+ QTest::addColumn<double>("num");
+
+ // The good...
+
+ QTest::newRow("C 1") << QString("1") << true << 1.0;
+ QTest::newRow("C 1.0") << QString("1.0") << true << 1.0;
+ QTest::newRow("C 1.234") << QString("1.234") << true << 1.234;
+ QTest::newRow("C 1.234e-10") << QString("1.234e-10") << true << 1.234e-10;
+ QTest::newRow("C 1.234E10") << QString("1.234E10") << true << 1.234e10;
+ QTest::newRow("C 1e10") << QString("1e10") << true << 1.0e10;
+
+ // The bad...
+
+ QTest::newRow("C empty") << QString("") << false << 0.0;
+ QTest::newRow("C null") << QString() << false << 0.0;
+ QTest::newRow("C .") << QString(".") << false << 0.0;
+ QTest::newRow("C 1e") << QString("1e") << false << 0.0;
+ QTest::newRow("C 1,") << QString("1,") << false << 0.0;
+ QTest::newRow("C 1,0") << QString("1,0") << false << 0.0;
+ QTest::newRow("C 1,000") << QString("1,000") << false << 0.0;
+ QTest::newRow("C 1e1.0") << QString("1e1.0") << false << 0.0;
+ QTest::newRow("C 1e+") << QString("1e+") << false << 0.0;
+ QTest::newRow("C 1e-") << QString("1e-") << false << 0.0;
+ QTest::newRow("de_DE 1,0") << QString("1,0") << false << 0.0;
+ QTest::newRow("de_DE 1,234") << QString("1,234") << false << 0.0;
+ QTest::newRow("de_DE 1,234e-10") << QString("1,234e-10") << false << 0.0;
+ QTest::newRow("de_DE 1,234E10") << QString("1,234E10") << false << 0.0;
+
+ // And the ugly...
+
+ QTest::newRow("C .1") << QString(".1") << true << 0.1;
+ QTest::newRow("C -.1") << QString("-.1") << true << -0.1;
+ QTest::newRow("C 1.") << QString("1.") << true << 1.0;
+ QTest::newRow("C 1.E10") << QString("1.E10") << true << 1.0e10;
+ QTest::newRow("C 1e+10") << QString("1e+10") << true << 1.0e+10;
+ QTest::newRow("C 1") << QString(" 1") << true << 1.0;
+ QTest::newRow("C 1 ") << QString("1 ") << true << 1.0;
+
+ // Let's try some Arabic
+ const quint16 arabic_str[] = { 0x0660, 0x066B, 0x0661, 0x0662,
+ 0x0663, 0x0664, 0x0065, 0x0662,
+ 0x0000 }; // "0.1234e2"
+ QTest::newRow("ar_SA") << QString::fromUtf16(arabic_str) << false << 0.0;
+}
+
+void tst_QStringRef::double_conversion()
+{
+#define MY_DOUBLE_EPSILON (2.22045e-16)
+
+ QFETCH(QString, num_str);
+ QFETCH(bool, good);
+ QFETCH(double, num);
+ QStringRef num_strRef = num_str.leftRef(-1);
+
+ bool ok;
+ double d = num_strRef.toDouble(&ok);
+ QCOMPARE(ok, good);
+
+ if (ok) {
+ double diff = d - num;
+ if (diff < 0)
+ diff = -diff;
+ QVERIFY(diff <= MY_DOUBLE_EPSILON);
+ }
+}
+
+void tst_QStringRef::trimmed()
+{
+ QString a;
+ QStringRef b;
+ a = "Text";
+ b = a.leftRef(-1);
+ QCOMPARE(b.compare(QStringLiteral("Text")), 0);
+ QCOMPARE(b.trimmed().compare(QStringLiteral("Text")), 0);
+ a = " ";
+ b = a.leftRef(-1);
+ QCOMPARE(b.compare(QStringLiteral(" ")), 0);
+ QCOMPARE(b.trimmed().compare(QStringLiteral("")), 0);
+ a = " a ";
+ b = a.leftRef(-1);
+ QCOMPARE(b.trimmed().compare(QStringLiteral("a")), 0);
+ a = "Text a ";
+ b = a.midRef(4);
+ QCOMPARE(b.compare(QStringLiteral(" a ")), 0);
+ QCOMPARE(b.trimmed().compare(QStringLiteral("a")), 0);
+}
+
QTEST_APPLESS_MAIN(tst_QStringRef)
#include "tst_qstringref.moc"
diff --git a/tests/auto/corelib/tools/qtimeline/tst_qtimeline.cpp b/tests/auto/corelib/tools/qtimeline/tst_qtimeline.cpp
index 4d05f45252..e6629301f9 100644
--- a/tests/auto/corelib/tools/qtimeline/tst_qtimeline.cpp
+++ b/tests/auto/corelib/tools/qtimeline/tst_qtimeline.cpp
@@ -69,6 +69,7 @@ private slots:
void stateInFinishedSignal();
void resume();
void restart();
+ void setPaused();
protected slots:
void finishedSlot();
@@ -681,6 +682,28 @@ void tst_QTimeLine::restart()
QCOMPARE(timeLine.currentTime(), 0);
}
+void tst_QTimeLine::setPaused()
+{
+ QTimeLine timeLine(1000);
+ {
+ QCOMPARE(timeLine.currentTime(), 0);
+ timeLine.start();
+ QTest::qWait(250);
+ timeLine.setPaused(true);
+ int oldCurrentTime = timeLine.currentTime();
+ QVERIFY(oldCurrentTime > 0);
+ QVERIFY(oldCurrentTime < 1000);
+ QTest::qWait(1000);
+ timeLine.setPaused(false);
+ QTest::qWait(250);
+ int currentTime = timeLine.currentTime();
+ QVERIFY(currentTime > 0);
+ QVERIFY(currentTime > oldCurrentTime);
+ QVERIFY(currentTime < 1000);
+ timeLine.stop();
+ }
+}
+
QTEST_MAIN(tst_QTimeLine)
#include "tst_qtimeline.moc"
diff --git a/tests/auto/corelib/tools/qvarlengtharray/tst_qvarlengtharray.cpp b/tests/auto/corelib/tools/qvarlengtharray/tst_qvarlengtharray.cpp
index bda3a2596f..c19080e345 100644
--- a/tests/auto/corelib/tools/qvarlengtharray/tst_qvarlengtharray.cpp
+++ b/tests/auto/corelib/tools/qvarlengtharray/tst_qvarlengtharray.cpp
@@ -58,6 +58,7 @@ private slots:
void count();
void first();
void last();
+ void squeeze();
};
int fooCtor = 0;
@@ -653,5 +654,28 @@ void tst_QVarLengthArray::last()
QCOMPARE(list.length(), 1);
}
+void tst_QVarLengthArray::squeeze()
+{
+ QVarLengthArray<int> list;
+ int sizeOnStack = list.capacity();
+ int sizeOnHeap = sizeOnStack * 2;
+ list.resize(0);
+ QCOMPARE(list.capacity(), sizeOnStack);
+ list.resize(sizeOnHeap);
+ QCOMPARE(list.capacity(), sizeOnHeap);
+ list.resize(sizeOnStack);
+ QCOMPARE(list.capacity(), sizeOnHeap);
+ list.resize(0);
+ QCOMPARE(list.capacity(), sizeOnHeap);
+ list.squeeze();
+ QCOMPARE(list.capacity(), sizeOnStack);
+ list.resize(sizeOnStack);
+ list.squeeze();
+ QCOMPARE(list.capacity(), sizeOnStack);
+ list.resize(sizeOnHeap);
+ list.squeeze();
+ QCOMPARE(list.capacity(), sizeOnHeap);
+}
+
QTEST_APPLESS_MAIN(tst_QVarLengthArray)
#include "tst_qvarlengtharray.moc"
diff --git a/tests/auto/corelib/tools/qvector/tst_qvector.cpp b/tests/auto/corelib/tools/qvector/tst_qvector.cpp
index 7738a2c797..53caec4a64 100644
--- a/tests/auto/corelib/tools/qvector/tst_qvector.cpp
+++ b/tests/auto/corelib/tools/qvector/tst_qvector.cpp
@@ -236,6 +236,7 @@ private slots:
void removeInt() const;
void removeMovable() const;
void removeCustom() const;
+ void removeFirstLast() const;
void resizePOD_data() const;
void resizePOD() const;
void resizeComplexMovable_data() const;
@@ -1393,6 +1394,103 @@ void tst_QVector::removeCustom() const
QCOMPARE(instancesCount, Custom::counter.loadAcquire());
}
+struct RemoveLastTestClass
+{
+ RemoveLastTestClass() { other = 0; deleted = false; }
+ RemoveLastTestClass *other;
+ bool deleted;
+ ~RemoveLastTestClass()
+ {
+ deleted = true;
+ if (other)
+ other->other = 0;
+ }
+};
+
+void tst_QVector::removeFirstLast() const
+{
+ // pop_pack - pop_front
+ QVector<int> t, t2;
+ t.append(1);
+ t.append(2);
+ t.append(3);
+ t.append(4);
+ t2 = t;
+ t.pop_front();
+ QCOMPARE(t.size(), 3);
+ QCOMPARE(t.at(0), 2);
+ t.pop_back();
+ QCOMPARE(t.size(), 2);
+ QCOMPARE(t.at(0), 2);
+ QCOMPARE(t.at(1), 3);
+
+ // takefirst - takeLast
+ int n1 = t2.takeLast();
+ QCOMPARE(t2.size(), 3);
+ QCOMPARE(n1, 4);
+ QCOMPARE(t2.at(0), 1);
+ QCOMPARE(t2.at(2), 3);
+ n1 = t2.takeFirst();
+ QCOMPARE(t2.size(), 2);
+ QCOMPARE(n1, 1);
+ QCOMPARE(t2.at(0), 2);
+ QCOMPARE(t2.at(1), 3);
+
+ // remove first
+ QVector<int> x, y;
+ x.append(1);
+ x.append(2);
+ y = x;
+ x.removeFirst();
+ QCOMPARE(x.size(), 1);
+ QCOMPARE(y.size(), 2);
+ QCOMPARE(x.at(0), 2);
+
+ // remove Last
+ QVector<RemoveLastTestClass> v;
+ v.resize(2);
+ v[0].other = &(v[1]);
+ v[1].other = &(v[0]);
+ // Check dtor - complex type
+ QVERIFY(v.at(0).other != 0);
+ v.removeLast();
+ QVERIFY(v.at(0).other == 0);
+ QCOMPARE(v.at(0).deleted, false);
+ // check iterator
+ int count = 0;
+ for (QVector<RemoveLastTestClass>::const_iterator i = v.constBegin(); i != v.constEnd(); ++i) {
+ ++count;
+ QVERIFY(i->other == 0);
+ QCOMPARE(i->deleted, false);
+ }
+ // Check size
+ QCOMPARE(count, 1);
+ QCOMPARE(v.size(), 1);
+ v.removeLast();
+ QCOMPARE(v.size(), 0);
+ // Check if we do correct realloc
+ QVector<int> v2, v3;
+ v2.append(1);
+ v2.append(2);
+ v3 = v2; // shared
+ v2.removeLast();
+ QCOMPARE(v2.size(), 1);
+ QCOMPARE(v3.size(), 2);
+ QCOMPARE(v2.at(0), 1);
+ QCOMPARE(v3.at(0), 1);
+ QCOMPARE(v3.at(1), 2);
+
+ // Remove last with shared
+ QVector<int> z1, z2;
+ z1.append(9);
+ z2 = z1;
+ z1.removeLast();
+ QCOMPARE(z1.size(), 0);
+ QCOMPARE(z2.size(), 1);
+ QCOMPARE(z2.at(0), 9);
+}
+
+
void tst_QVector::resizePOD_data() const
{
QTest::addColumn<QVector<int> >("vector");
diff --git a/tests/auto/corelib/tools/tools.pro b/tests/auto/corelib/tools/tools.pro
index 100409e58b..f8b2437d35 100644
--- a/tests/auto/corelib/tools/tools.pro
+++ b/tests/auto/corelib/tools/tools.pro
@@ -22,6 +22,7 @@ SUBDIRS=\
qlocale \
qmap \
qmargins \
+ qmessageauthenticationcode \
qpair \
qpoint \
qpointf \
diff --git a/tests/auto/corelib/xml/xml.pro b/tests/auto/corelib/xml/xml.pro
index 53836cb7f0..20519edf1b 100644
--- a/tests/auto/corelib/xml/xml.pro
+++ b/tests/auto/corelib/xml/xml.pro
@@ -1,3 +1,3 @@
TEMPLATE=subdirs
-SUBDIRS=\
+qtHaveModule(network): SUBDIRS= \
qxmlstream
diff --git a/tests/auto/dbus/qdbusabstractinterface/tst_qdbusabstractinterface.cpp b/tests/auto/dbus/qdbusabstractinterface/tst_qdbusabstractinterface.cpp
index c28d1dc022..308e12b9ab 100644
--- a/tests/auto/dbus/qdbusabstractinterface/tst_qdbusabstractinterface.cpp
+++ b/tests/auto/dbus/qdbusabstractinterface/tst_qdbusabstractinterface.cpp
@@ -159,6 +159,11 @@ private slots:
void followSignal();
+ void connectDisconnect_data();
+ void connectDisconnect();
+ void connectDisconnectPeer_data();
+ void connectDisconnectPeer();
+
void createErrors_data();
void createErrors();
@@ -196,6 +201,15 @@ private:
QProcess proc;
};
+class SignalReceiver : public QObject
+{
+ Q_OBJECT
+public:
+ int callCount;
+ SignalReceiver() : callCount(0) {}
+public slots:
+ void receive() { ++callCount; }
+};
tst_QDBusAbstractInterface::tst_QDBusAbstractInterface()
{
@@ -1017,21 +1031,87 @@ void tst_QDBusAbstractInterface::followSignal()
// now the signal must have been received:
QCOMPARE(s.size(), 1);
QVERIFY(s.at(0).size() == 0);
- s.clear();
- // disconnect the signal
- disconnect(p.data(), SIGNAL(voidSignal()), &QTestEventLoop::instance(), 0);
+ // cleanup:
+ con.interface()->unregisterService(serviceToFollow);
+}
+
+void tst_QDBusAbstractInterface::connectDisconnect_data()
+{
+ QTest::addColumn<int>("connectCount");
+ QTest::addColumn<int>("disconnectCount");
+
+ // we don't actually need multiple disconnects
+ // QObject::disconnect() disconnects all matching rules
+ // we'd have to use QMetaObject::disconnectOne if we wanted just one
+ QTest::newRow("null") << 0 << 0;
+ QTest::newRow("connect-disconnect") << 1 << 1;
+ QTest::newRow("connect-disconnect-wildcard") << 1 << -1;
+ QTest::newRow("connect-twice") << 2 << 0;
+ QTest::newRow("connect-twice-disconnect") << 2 << 1;
+ QTest::newRow("connect-twice-disconnect-wildcard") << 2 << -1;
+}
+
+void tst_QDBusAbstractInterface::connectDisconnect()
+{
+ QFETCH(int, connectCount);
+ QFETCH(int, disconnectCount);
+
+ Pinger p = getPinger();
+ QVERIFY2(p, "Not connected to D-Bus");
+
+ // connect the exitLoop slot first
+ // if the disconnect() below does something weird, we'll get a timeout
+ QTestEventLoop::instance().connect(p.data(), SIGNAL(voidSignal()), SLOT(exitLoop()));
+
+ SignalReceiver sr;
+ for (int i = 0; i < connectCount; ++i)
+ sr.connect(p.data(), SIGNAL(voidSignal()), SLOT(receive()));
+ if (disconnectCount)
+ QObject::disconnect(p.data(), disconnectCount > 0 ? SIGNAL(voidSignal()) : 0, &sr, SLOT(receive()));
- // emit the signal again:
emit targetObj.voidSignal();
QTestEventLoop::instance().enterLoop(2);
QVERIFY(!QTestEventLoop::instance().timeout());
- // and now it mustn't have been received
- QVERIFY(s.isEmpty());
+ if (disconnectCount != 0)
+ QCOMPARE(sr.callCount, 0);
+ else
+ QCOMPARE(sr.callCount, connectCount);
+}
- // cleanup:
- con.interface()->unregisterService(serviceToFollow);
+void tst_QDBusAbstractInterface::connectDisconnectPeer_data()
+{
+ connectDisconnect_data();
+}
+
+void tst_QDBusAbstractInterface::connectDisconnectPeer()
+{
+ QFETCH(int, connectCount);
+ QFETCH(int, disconnectCount);
+
+ Pinger p = getPingerPeer();
+ QVERIFY2(p, "Not connected to D-Bus");
+
+ // connect the exitLoop slot first
+ // if the disconnect() below does something weird, we'll get a timeout
+ QTestEventLoop::instance().connect(p.data(), SIGNAL(voidSignal()), SLOT(exitLoop()));
+
+ SignalReceiver sr;
+ for (int i = 0; i < connectCount; ++i)
+ sr.connect(p.data(), SIGNAL(voidSignal()), SLOT(receive()));
+ if (disconnectCount)
+ QObject::disconnect(p.data(), disconnectCount > 0 ? SIGNAL(voidSignal()) : 0, &sr, SLOT(receive()));
+
+ QDBusMessage req = QDBusMessage::createMethodCall(serviceName, objectPath, interfaceName, "voidSignal");
+ QVERIFY(QDBusConnection::sessionBus().send(req));
+ QTestEventLoop::instance().enterLoop(2);
+ QVERIFY(!QTestEventLoop::instance().timeout());
+
+ if (disconnectCount != 0)
+ QCOMPARE(sr.callCount, 0);
+ else
+ QCOMPARE(sr.callCount, connectCount);
}
void tst_QDBusAbstractInterface::createErrors_data()
diff --git a/tests/auto/dbus/qdbusconnection/tst_qdbusconnection.cpp b/tests/auto/dbus/qdbusconnection/tst_qdbusconnection.cpp
index c56a47bbc6..1da7f8a92a 100644
--- a/tests/auto/dbus/qdbusconnection/tst_qdbusconnection.cpp
+++ b/tests/auto/dbus/qdbusconnection/tst_qdbusconnection.cpp
@@ -1200,6 +1200,19 @@ void tst_QDBusConnection::registerVirtualObject()
QVERIFY(!con.registerVirtualObject(path, &obj, QDBusConnection::SubPath));
QCOMPARE(con.objectRegisteredAt(path), static_cast<QObject *>(0));
}
+
+ {
+ // Register object, make sure no SubPath handling object can be registered on a parent path.
+ // (same as above, but deeper)
+ QObject objectAtSubPath;
+ QVERIFY(con.registerObject(childChildPath, &objectAtSubPath));
+ QCOMPARE(con.objectRegisteredAt(childChildPath), static_cast<QObject *>(&objectAtSubPath));
+
+ VirtualObject obj;
+ QVERIFY(!con.registerVirtualObject(path, &obj, QDBusConnection::SubPath));
+ QCOMPARE(con.objectRegisteredAt(path), static_cast<QObject *>(0));
+ }
+
QCOMPARE(con.objectRegisteredAt(path), static_cast<QObject *>(0));
QCOMPARE(con.objectRegisteredAt(childPath), static_cast<QObject *>(0));
QCOMPARE(con.objectRegisteredAt(childChildPath), static_cast<QObject *>(0));
diff --git a/tests/auto/dbus/qdbusmetaobject/tst_qdbusmetaobject.cpp b/tests/auto/dbus/qdbusmetaobject/tst_qdbusmetaobject.cpp
index 7b7ad1800c..6340f0f7a6 100644
--- a/tests/auto/dbus/qdbusmetaobject/tst_qdbusmetaobject.cpp
+++ b/tests/auto/dbus/qdbusmetaobject/tst_qdbusmetaobject.cpp
@@ -442,7 +442,7 @@ void tst_QDBusMetaObject::types()
class MethodTest1: public QObject
{
Q_OBJECT
-
+
public slots:
void method() { }
};
@@ -452,7 +452,7 @@ const char MethodTest1_xml[] =
class MethodTest2: public QObject
{
Q_OBJECT
-
+
public slots:
void method(int) { }
};
@@ -462,7 +462,7 @@ const char MethodTest2_xml[] =
class MethodTest3: public QObject
{
Q_OBJECT
-
+
public slots:
void method(int input0) { Q_UNUSED(input0); }
};
@@ -472,7 +472,7 @@ const char MethodTest3_xml[] =
class MethodTest4: public QObject
{
Q_OBJECT
-
+
public slots:
int method() { return 0; }
};
@@ -484,7 +484,7 @@ const char MethodTest4_xml2[] =
class MethodTest5: public QObject
{
Q_OBJECT
-
+
public slots:
int method(int input0) { return input0; }
};
@@ -497,7 +497,7 @@ const char MethodTest5_xml[] =
class MethodTest6: public QObject
{
Q_OBJECT
-
+
public slots:
int method(int input0, int input1) { Q_UNUSED(input0); return input1; }
};
@@ -511,7 +511,7 @@ const char MethodTest6_xml[] =
class MethodTest7: public QObject
{
Q_OBJECT
-
+
public slots:
int method(int input0, int input1, int &output1) { output1 = input1; return input0; }
};
@@ -526,7 +526,7 @@ const char MethodTest7_xml[] =
class MethodTest8: public QObject
{
Q_OBJECT
-
+
public slots:
int method(int input0, int input1, int &output1, int &output2) { output1 = output2 = input1; return input0; }
};
@@ -542,7 +542,7 @@ const char MethodTest8_xml[] =
class MethodTest9: public QObject
{
Q_OBJECT
-
+
public slots:
Q_NOREPLY void method(int) { }
};
@@ -577,7 +577,7 @@ void tst_QDBusMetaObject::methods()
class SignalTest1: public QObject
{
Q_OBJECT
-
+
signals:
void signal();
};
@@ -587,7 +587,7 @@ const char SignalTest1_xml[] =
class SignalTest2: public QObject
{
Q_OBJECT
-
+
signals:
void signal(int);
};
@@ -597,7 +597,7 @@ const char SignalTest2_xml[] =
class SignalTest3: public QObject
{
Q_OBJECT
-
+
signals:
void signal(int output0);
};
@@ -607,7 +607,7 @@ const char SignalTest3_xml[] =
class SignalTest4: public QObject
{
Q_OBJECT
-
+
signals:
void signal(int output0, int);
};
diff --git a/tests/auto/dbus/qdbuspendingreply/tst_qdbuspendingreply.cpp b/tests/auto/dbus/qdbuspendingreply/tst_qdbuspendingreply.cpp
index 841e09c865..a45a0fefbb 100644
--- a/tests/auto/dbus/qdbuspendingreply/tst_qdbuspendingreply.cpp
+++ b/tests/auto/dbus/qdbuspendingreply/tst_qdbuspendingreply.cpp
@@ -572,6 +572,8 @@ void tst_QDBusPendingReply::errors()
QVERIFY(rint.isError());
error = rint.error();
VERIFY_ERROR(error);
+ int dummyint = rint;
+ QCOMPARE(dummyint, int());
QDBusPendingReply<int,int> rintint(iface->asyncCall("sendError"));
rintint.waitForFinished();
@@ -579,6 +581,9 @@ void tst_QDBusPendingReply::errors()
QVERIFY(rintint.isError());
error = rintint.error();
VERIFY_ERROR(error);
+ dummyint = rintint;
+ QCOMPARE(dummyint, int());
+ QCOMPARE(rintint.argumentAt<1>(), int());
QDBusPendingReply<QString> rstring(iface->asyncCall("sendError"));
rstring.waitForFinished();
@@ -586,6 +591,8 @@ void tst_QDBusPendingReply::errors()
QVERIFY(rstring.isError());
error = rstring.error();
VERIFY_ERROR(error);
+ QString dummystring = rstring;
+ QCOMPARE(dummystring, QString());
}
QTEST_MAIN(tst_QDBusPendingReply)
diff --git a/tests/auto/dbus/qdbusreply/tst_qdbusreply.cpp b/tests/auto/dbus/qdbusreply/tst_qdbusreply.cpp
index 5e60e468a2..8b0fa92adf 100644
--- a/tests/auto/dbus/qdbusreply/tst_qdbusreply.cpp
+++ b/tests/auto/dbus/qdbusreply/tst_qdbusreply.cpp
@@ -97,6 +97,7 @@ private slots:
void simpleTypes();
void complexTypes();
void wrongTypes();
+ void error();
};
class TypesInterface: public QDBusAbstractAdaptor
@@ -372,6 +373,30 @@ void tst_QDBusReply::wrongTypes()
QVERIFY(!rstruct.isValid());
}
+void tst_QDBusReply::error()
+{
+ {
+ // Wrong type
+ QDBusReply<bool> result = iface->call(QDBus::BlockWithGui, "retrieveInt");
+ QVERIFY(result.error().isValid());
+ }
+ {
+ // Wrong type, const version
+ const QDBusReply<bool> result = iface->call(QDBus::BlockWithGui, "retrieveInt");
+ QVERIFY(result.error().isValid());
+ }
+ {
+ // Ok type
+ QDBusReply<void> result = iface->call(QDBus::BlockWithGui, "retrieveInt");
+ QVERIFY(!result.error().isValid());
+ }
+ {
+ // Ok type, const version
+ const QDBusReply<void> result = iface->call(QDBus::BlockWithGui, "retrieveInt");
+ QVERIFY(!result.error().isValid());
+ }
+}
+
QTEST_MAIN(tst_QDBusReply)
#include "tst_qdbusreply.moc"
diff --git a/tests/auto/dbus/qdbusxmlparser/tst_qdbusxmlparser.cpp b/tests/auto/dbus/qdbusxmlparser/tst_qdbusxmlparser.cpp
index 08b8ce3db3..8c94f87fd6 100644
--- a/tests/auto/dbus/qdbusxmlparser/tst_qdbusxmlparser.cpp
+++ b/tests/auto/dbus/qdbusxmlparser/tst_qdbusxmlparser.cpp
@@ -96,7 +96,7 @@ void tst_QDBusXmlParser::parsing_data()
QTest::newRow("null") << QString() << 0 << 0 << 0 << introspection;
QTest::newRow("empty") << QString("") << 0 << 0 << 0 << introspection;
-
+
QTest::newRow("junk") << "<junk/>" << 0 << 0 << 0 << introspection;
QTest::newRow("interface-inside-junk") << "<junk><interface name=\"iface.iface1\" /></junk>"
<< 0 << 0 << 0 << introspection;
@@ -429,7 +429,7 @@ void tst_QDBusXmlParser::signals__data()
QTest::newRow("one-out-no-direction") <<
"<signal name=\"Signal\">"
"<arg type=\"s\"/>"
- "</signal>" << map;
+ "</signal>" << map;
// two args with name
signal.outputArgs << arg("i", "bar");
diff --git a/tests/auto/gui/image/image.pro b/tests/auto/gui/image/image.pro
index 1ef52df4ba..9199763c40 100644
--- a/tests/auto/gui/image/image.pro
+++ b/tests/auto/gui/image/image.pro
@@ -11,6 +11,9 @@ SUBDIRS=\
qpicture \
qicon \
+!qtHaveModule(network): SUBDIRS -= \
+ qimagereader
+
!contains(QT_CONFIG, private_tests): SUBDIRS -= \
qpixmapcache \
diff --git a/tests/auto/gui/image/qicoimageformat/qicoimageformat.pro b/tests/auto/gui/image/qicoimageformat/qicoimageformat.pro
index 41f7fb626e..83af3960a6 100644
--- a/tests/auto/gui/image/qicoimageformat/qicoimageformat.pro
+++ b/tests/auto/gui/image/qicoimageformat/qicoimageformat.pro
@@ -14,4 +14,3 @@ wince*: {
DEPLOYMENT += addPlugins
}
TESTDATA += icons/*
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/image/qicon/qicon.pro b/tests/auto/gui/image/qicon/qicon.pro
index 337b938915..f48fe90dd8 100644
--- a/tests/auto/gui/image/qicon/qicon.pro
+++ b/tests/auto/gui/image/qicon/qicon.pro
@@ -8,4 +8,3 @@ SOURCES += tst_qicon.cpp
RESOURCES = tst_qicon.qrc
TESTDATA += icons/* *.png *.svg *.svgz
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/image/qicon/tst_qicon.cpp b/tests/auto/gui/image/qicon/tst_qicon.cpp
index 11fd5f9b2e..c21f725b55 100644
--- a/tests/auto/gui/image/qicon/tst_qicon.cpp
+++ b/tests/auto/gui/image/qicon/tst_qicon.cpp
@@ -80,7 +80,7 @@ private:
const static QIcon staticIcon;
};
-// Creating an icon statically should not cause a crash.
+// Creating an icon statically should not cause a crash.
// But we do not officially support this. See QTBUG-8666
const QIcon tst_QIcon::staticIcon = QIcon::fromTheme("edit-find");
diff --git a/tests/auto/gui/image/qimage/qimage.pro b/tests/auto/gui/image/qimage/qimage.pro
index f7b1e4001a..467a59ec9f 100644
--- a/tests/auto/gui/image/qimage/qimage.pro
+++ b/tests/auto/gui/image/qimage/qimage.pro
@@ -6,4 +6,3 @@ SOURCES += tst_qimage.cpp
QT += core-private gui-private testlib
TESTDATA += images/*
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/image/qimageiohandler/qimageiohandler.pro b/tests/auto/gui/image/qimageiohandler/qimageiohandler.pro
index 43507d9336..bbcf8d23c9 100644
--- a/tests/auto/gui/image/qimageiohandler/qimageiohandler.pro
+++ b/tests/auto/gui/image/qimageiohandler/qimageiohandler.pro
@@ -6,4 +6,3 @@ QT += testlib
SOURCES += tst_qimageiohandler.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/image/qimageiohandler/tst_qimageiohandler.cpp b/tests/auto/gui/image/qimageiohandler/tst_qimageiohandler.cpp
index d76e954ccd..f7d8eef721 100644
--- a/tests/auto/gui/image/qimageiohandler/tst_qimageiohandler.cpp
+++ b/tests/auto/gui/image/qimageiohandler/tst_qimageiohandler.cpp
@@ -63,7 +63,7 @@ class MyImageIOHandler : public QImageIOHandler
{
public:
MyImageIOHandler() : QImageIOHandler() { }
- bool canRead() const { return true; }
+ bool canRead() const { return true; }
bool read(QImage *) { return true; }
};
diff --git a/tests/auto/gui/image/qimagereader/images/black.xpm b/tests/auto/gui/image/qimagereader/images/black.xpm
index d7925bf211..4a1f4ec861 100644
--- a/tests/auto/gui/image/qimagereader/images/black.xpm
+++ b/tests/auto/gui/image/qimagereader/images/black.xpm
@@ -15,21 +15,21 @@ static char * ddd_xpm[] = {
"+ c white m white g white g4 white s Light ",
"* c DarkGreen m black g grey25 g4 grey25 s Eye ",
/* Pixels */
-" . . ",
-" . .. ",
-" . . ",
-" .. . ",
-" .. .. .. ",
-" .. . . . ",
-" . . . . .. ",
-" . .X. . ",
-" . *.X.* .. ",
-" .. .. .XXX. .. ... ",
-" . .X...XXX...X. . ",
-" .. ..XXX.XXX.XXX. .. ",
-" .....XXXX...XXXX. . ",
-" .. ..XXXXXXXXX.. .. ",
-" ...XXXXXXX..... ",
+" . . ",
+" . .. ",
+" . . ",
+" .. . ",
+" .. .. .. ",
+" .. . . . ",
+" . . . . .. ",
+" . .X. . ",
+" . *.X.* .. ",
+" .. .. .XXX. .. ... ",
+" . .X...XXX...X. . ",
+" .. ..XXX.XXX.XXX. .. ",
+" .....XXXX...XXXX. . ",
+" .. ..XXXXXXXXX.. .. ",
+" ...XXXXXXX..... ",
" ......... ",
" .XXXXXXX. ",
" .....XXX..... ",
diff --git a/tests/auto/gui/image/qimagereader/qimagereader.pro b/tests/auto/gui/image/qimagereader/qimagereader.pro
index 432d3db19a..7686643b3a 100644
--- a/tests/auto/gui/image/qimagereader/qimagereader.pro
+++ b/tests/auto/gui/image/qimagereader/qimagereader.pro
@@ -11,4 +11,3 @@ win32-msvc.net:QMAKE_CXXFLAGS -= -Zm300
win32-msvc.net:QMAKE_CXXFLAGS += -Zm1100
TESTDATA += images/* baseline/*
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/image/qimagereader/tst_qimagereader.cpp b/tests/auto/gui/image/qimagereader/tst_qimagereader.cpp
index 4b3db26685..b684231e10 100644
--- a/tests/auto/gui/image/qimagereader/tst_qimagereader.cpp
+++ b/tests/auto/gui/image/qimagereader/tst_qimagereader.cpp
@@ -94,6 +94,7 @@ private slots:
void multiWordNamedColorXPM();
void supportedFormats();
+ void supportedMimeTypes();
void readFromDevice_data();
void readFromDevice();
@@ -571,6 +572,26 @@ void tst_QImageReader::supportedFormats()
QCOMPARE(formatSet.size(), formats.size());
}
+void tst_QImageReader::supportedMimeTypes()
+{
+ QList<QByteArray> mimeTypes = QImageReader::supportedMimeTypes();
+ QList<QByteArray> sortedMimeTypes = mimeTypes;
+ qSort(sortedMimeTypes);
+
+ // check that the list is sorted
+ QCOMPARE(mimeTypes, sortedMimeTypes);
+
+ QSet<QByteArray> mimeTypeSet;
+ foreach (QByteArray mimeType, mimeTypes)
+ mimeTypeSet << mimeType;
+
+ // check the list as a minimum contains image/bmp
+ QVERIFY(mimeTypeSet.contains("image/bmp"));
+
+ // check that the list does not contain duplicates
+ QCOMPARE(mimeTypeSet.size(), mimeTypes.size());
+}
+
void tst_QImageReader::setBackgroundColor_data()
{
QTest::addColumn<QString>("fileName");
diff --git a/tests/auto/gui/image/qimagewriter/qimagewriter.pro b/tests/auto/gui/image/qimagewriter/qimagewriter.pro
index 3006bfe09e..f77ff0659b 100644
--- a/tests/auto/gui/image/qimagewriter/qimagewriter.pro
+++ b/tests/auto/gui/image/qimagewriter/qimagewriter.pro
@@ -7,4 +7,3 @@ win32-msvc:QMAKE_CXXFLAGS -= -Zm200
win32-msvc:QMAKE_CXXFLAGS += -Zm800
TESTDATA += images/*
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/image/qimagewriter/tst_qimagewriter.cpp b/tests/auto/gui/image/qimagewriter/tst_qimagewriter.cpp
index 3c36482d62..f1d0e227f6 100644
--- a/tests/auto/gui/image/qimagewriter/tst_qimagewriter.cpp
+++ b/tests/auto/gui/image/qimagewriter/tst_qimagewriter.cpp
@@ -81,6 +81,7 @@ private slots:
void writeImage2_data();
void writeImage2();
void supportedFormats();
+ void supportedMimeTypes();
void writeToInvalidDevice();
@@ -352,6 +353,26 @@ void tst_QImageWriter::supportedFormats()
QCOMPARE(formatSet.size(), formats.size());
}
+void tst_QImageWriter::supportedMimeTypes()
+{
+ QList<QByteArray> mimeTypes = QImageWriter::supportedMimeTypes();
+ QList<QByteArray> sortedMimeTypes = mimeTypes;
+ qSort(sortedMimeTypes);
+
+ // check that the list is sorted
+ QCOMPARE(mimeTypes, sortedMimeTypes);
+
+ QSet<QByteArray> mimeTypeSet;
+ foreach (QByteArray mimeType, mimeTypes)
+ mimeTypeSet << mimeType;
+
+ // check the list as a minimum contains image/bmp
+ QVERIFY(mimeTypeSet.contains("image/bmp"));
+
+ // check that the list does not contain duplicates
+ QCOMPARE(mimeTypeSet.size(), mimeTypes.size());
+}
+
void tst_QImageWriter::writeToInvalidDevice()
{
QLatin1String fileName("/these/directories/do/not/exist/001.png");
diff --git a/tests/auto/gui/image/qmovie/qmovie.pro b/tests/auto/gui/image/qmovie/qmovie.pro
index 9290588625..4e7030b1f7 100644
--- a/tests/auto/gui/image/qmovie/qmovie.pro
+++ b/tests/auto/gui/image/qmovie/qmovie.pro
@@ -11,4 +11,3 @@ MOC_DIR=tmp
RESOURCES += resources.qrc
TESTDATA += animations/*
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/image/qpicture/qpicture.pro b/tests/auto/gui/image/qpicture/qpicture.pro
index b4927b4536..a24b8ec481 100644
--- a/tests/auto/gui/image/qpicture/qpicture.pro
+++ b/tests/auto/gui/image/qpicture/qpicture.pro
@@ -7,4 +7,3 @@ SOURCES += tst_qpicture.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/image/qpicture/tst_qpicture.cpp b/tests/auto/gui/image/qpicture/tst_qpicture.cpp
index 3e628981b6..2e766c5bf5 100644
--- a/tests/auto/gui/image/qpicture/tst_qpicture.cpp
+++ b/tests/auto/gui/image/qpicture/tst_qpicture.cpp
@@ -174,28 +174,28 @@ void tst_QPicture::operator_lt_lt()
{
// streaming of null pictures
{
- QPicture pic1, pic2;
- QByteArray ba( 100, 0 );
- QDataStream str1( &ba, QIODevice::WriteOnly );
- str1 << pic1;
- QDataStream str2( &ba, QIODevice::ReadOnly );
- str2 >> pic2;
- QVERIFY( pic2.isNull() );
+ QPicture pic1, pic2;
+ QByteArray ba( 100, 0 );
+ QDataStream str1( &ba, QIODevice::WriteOnly );
+ str1 << pic1;
+ QDataStream str2( &ba, QIODevice::ReadOnly );
+ str2 >> pic2;
+ QVERIFY( pic2.isNull() );
}
// picture with a simple line, checking bitwise equality
{
- QPicture pic1, pic2;
- QPainter p( &pic1 );
- p.drawLine( 10, 20, 30, 40 );
- p.end();
- QByteArray ba( 10 * pic1.size(), 0 );
- QDataStream str1( &ba, QIODevice::WriteOnly );
- str1 << pic1;
- QDataStream str2( &ba, QIODevice::ReadOnly );
- str2 >> pic2;
- QCOMPARE( pic1.size(), pic2.size() );
- QVERIFY( memcmp( pic1.data(), pic2.data(), pic1.size() ) == 0 );
+ QPicture pic1, pic2;
+ QPainter p( &pic1 );
+ p.drawLine( 10, 20, 30, 40 );
+ p.end();
+ QByteArray ba( 10 * pic1.size(), 0 );
+ QDataStream str1( &ba, QIODevice::WriteOnly );
+ str1 << pic1;
+ QDataStream str2( &ba, QIODevice::ReadOnly );
+ str2 >> pic2;
+ QCOMPARE( pic1.size(), pic2.size() );
+ QVERIFY( memcmp( pic1.data(), pic2.data(), pic1.size() ) == 0 );
}
}
@@ -268,7 +268,6 @@ void tst_QPicture::boundaryValues_data()
QTest::newRow("min x, max y") << INT_MIN << INT_MAX;
QTest::newRow("max x, min y") << INT_MAX << INT_MIN;
-
}
void tst_QPicture::boundaryValues()
@@ -283,8 +282,6 @@ void tst_QPicture::boundaryValues()
painter.drawPoint(QPoint(x, y));
painter.end();
-
-
}
diff --git a/tests/auto/gui/image/qpixmap/qpixmap.pro b/tests/auto/gui/image/qpixmap/qpixmap.pro
index 6188bf2c6e..bdd0c15788 100644
--- a/tests/auto/gui/image/qpixmap/qpixmap.pro
+++ b/tests/auto/gui/image/qpixmap/qpixmap.pro
@@ -11,4 +11,3 @@ SOURCES += tst_qpixmap.cpp
RESOURCES += qpixmap.qrc
TESTDATA += convertFromImage/* convertFromToHICON/* loadFromData/* images/*
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/image/qpixmap/tst_qpixmap.cpp b/tests/auto/gui/image/qpixmap/tst_qpixmap.cpp
index 61f53a5073..531ec68fdc 100644
--- a/tests/auto/gui/image/qpixmap/tst_qpixmap.cpp
+++ b/tests/auto/gui/image/qpixmap/tst_qpixmap.cpp
@@ -114,6 +114,7 @@ private slots:
void convertFromImageNoDetach();
void convertFromImageDetach();
+ void convertFromImageCacheKey();
#if defined(Q_OS_WIN)
void toWinHBITMAP_data();
@@ -782,6 +783,28 @@ void tst_QPixmap::convertFromImageDetach()
QVERIFY(copy.isDetached());
}
+void tst_QPixmap::convertFromImageCacheKey()
+{
+ QPixmap randomPixmap(10, 10);
+ if (randomPixmap.handle()->classId() != QPlatformPixmap::RasterClass)
+ QSKIP("Test only valid for raster pixmaps");
+
+ //first get the screen format
+ QImage::Format screenFormat = randomPixmap.toImage().format();
+ QVERIFY(screenFormat != QImage::Format_Invalid);
+
+ QImage orig(100,100, screenFormat);
+ orig.fill(0);
+
+ QPixmap pix = QPixmap::fromImage(orig);
+ QImage copy = pix.toImage();
+
+ QVERIFY(copy.format() == screenFormat);
+
+ QCOMPARE(orig.cacheKey(), pix.cacheKey());
+ QCOMPARE(copy.cacheKey(), pix.cacheKey());
+}
+
#if defined(Q_OS_WIN)
QT_BEGIN_NAMESPACE
diff --git a/tests/auto/gui/image/qpixmapcache/qpixmapcache.pro b/tests/auto/gui/image/qpixmapcache/qpixmapcache.pro
index c332497783..a81712ba23 100644
--- a/tests/auto/gui/image/qpixmapcache/qpixmapcache.pro
+++ b/tests/auto/gui/image/qpixmapcache/qpixmapcache.pro
@@ -6,4 +6,3 @@ SOURCES += tst_qpixmapcache.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/itemmodels/qstandarditem/qstandarditem.pro b/tests/auto/gui/itemmodels/qstandarditem/qstandarditem.pro
index 4fa7bbe253..282737ed7d 100644
--- a/tests/auto/gui/itemmodels/qstandarditem/qstandarditem.pro
+++ b/tests/auto/gui/itemmodels/qstandarditem/qstandarditem.pro
@@ -5,4 +5,3 @@ QT += gui testlib
SOURCES += tst_qstandarditem.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/itemmodels/qstandarditem/tst_qstandarditem.cpp b/tests/auto/gui/itemmodels/qstandarditem/tst_qstandarditem.cpp
index 649bc071b9..5406256c9f 100644
--- a/tests/auto/gui/itemmodels/qstandarditem/tst_qstandarditem.cpp
+++ b/tests/auto/gui/itemmodels/qstandarditem/tst_qstandarditem.cpp
@@ -187,7 +187,7 @@ void tst_QStandardItem::getSetData()
item.setBackground(backgroundColor);
QCOMPARE(item.background().color(), backgroundColor);
- QColor textColor((i == i) ? Qt::green : Qt::cyan);
+ QColor textColor((i == 1) ? Qt::green : Qt::cyan);
item.setForeground(textColor);
QCOMPARE(item.foreground().color(), textColor);
diff --git a/tests/auto/gui/itemmodels/qstandarditemmodel/qstandarditemmodel.pro b/tests/auto/gui/itemmodels/qstandarditemmodel/qstandarditemmodel.pro
index 5743bf4074..71ef4acb88 100644
--- a/tests/auto/gui/itemmodels/qstandarditemmodel/qstandarditemmodel.pro
+++ b/tests/auto/gui/itemmodels/qstandarditemmodel/qstandarditemmodel.pro
@@ -8,4 +8,3 @@ QT += core-private gui-private
SOURCES += tst_qstandarditemmodel.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/itemmodels/qstandarditemmodel/tst_qstandarditemmodel.cpp b/tests/auto/gui/itemmodels/qstandarditemmodel/tst_qstandarditemmodel.cpp
index 5fb8df3f59..085dfd0461 100644
--- a/tests/auto/gui/itemmodels/qstandarditemmodel/tst_qstandarditemmodel.cpp
+++ b/tests/auto/gui/itemmodels/qstandarditemmodel/tst_qstandarditemmodel.cpp
@@ -718,6 +718,8 @@ void tst_QStandardItemModel::checkChildren()
QVERIFY(!model.hasChildren());
QCOMPARE(model.rowCount(), 0);
QCOMPARE(model.columnCount(), 1);
+
+ QVERIFY(!model.index(0,0).sibling(100,100).isValid());
}
void tst_QStandardItemModel::data()
diff --git a/tests/auto/gui/kernel/kernel.pro b/tests/auto/gui/kernel/kernel.pro
index 7e3f25d377..85a81de632 100644
--- a/tests/auto/gui/kernel/kernel.pro
+++ b/tests/auto/gui/kernel/kernel.pro
@@ -15,6 +15,7 @@ SUBDIRS=\
qmouseevent_modal \
qpalette \
qscreen \
+ qsurfaceformat \
qtouchevent \
qwindow \
qguiapplication \
diff --git a/tests/auto/gui/kernel/qbackingstore/qbackingstore.pro b/tests/auto/gui/kernel/qbackingstore/qbackingstore.pro
index e1b7246fe2..c3113ed4b1 100644
--- a/tests/auto/gui/kernel/qbackingstore/qbackingstore.pro
+++ b/tests/auto/gui/kernel/qbackingstore/qbackingstore.pro
@@ -5,4 +5,3 @@ TARGET = tst_qbackingstore
QT += core-private gui-private testlib
SOURCES += tst_qbackingstore.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qclipboard/copier/copier.pro b/tests/auto/gui/kernel/qclipboard/copier/copier.pro
index 25f08fbef7..def50b6476 100644
--- a/tests/auto/gui/kernel/qclipboard/copier/copier.pro
+++ b/tests/auto/gui/kernel/qclipboard/copier/copier.pro
@@ -2,4 +2,3 @@ CONFIG -= app_bundle
win32: DESTDIR = ../copier
SOURCES += main.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qclipboard/paster/paster.pro b/tests/auto/gui/kernel/qclipboard/paster/paster.pro
index 1ab295111c..ef91e77b6e 100644
--- a/tests/auto/gui/kernel/qclipboard/paster/paster.pro
+++ b/tests/auto/gui/kernel/qclipboard/paster/paster.pro
@@ -2,4 +2,3 @@ win32: DESTDIR = ../paster
CONFIG -= app_bundle
SOURCES += main.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qclipboard/test/test.pro b/tests/auto/gui/kernel/qclipboard/test/test.pro
index 494b155d45..586404871f 100644
--- a/tests/auto/gui/kernel/qclipboard/test/test.pro
+++ b/tests/auto/gui/kernel/qclipboard/test/test.pro
@@ -18,4 +18,3 @@ wince* {
TEST_HELPER_INSTALLS = \
../copier/copier \
../paster/paster
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp b/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp
index 4470961f7b..89807f3747 100644
--- a/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp
+++ b/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp
@@ -208,11 +208,12 @@ static bool runHelper(const QString &program, const QStringList &arguments, QByt
// Windows: Due to implementation changes, the event loop needs
// to be spun since we ourselves also need to answer the
// WM_DRAWCLIPBOARD message as we are in the chain of clipboard
- // viewers.
+ // viewers. Check for running before waitForFinished() in case
+ // the process terminated while processEvents() was executed.
bool running = true;
for (int i = 0; i < 60 && running; ++i) {
QGuiApplication::processEvents(QEventLoop::ExcludeUserInputEvents);
- if (process.waitForFinished(500))
+ if (process.state() != QProcess::Running || process.waitForFinished(500))
running = false;
}
if (running) {
diff --git a/tests/auto/gui/kernel/qdrag/qdrag.pro b/tests/auto/gui/kernel/qdrag/qdrag.pro
index 21df5c798a..d4a7bc2705 100644
--- a/tests/auto/gui/kernel/qdrag/qdrag.pro
+++ b/tests/auto/gui/kernel/qdrag/qdrag.pro
@@ -9,4 +9,3 @@ QT += testlib
SOURCES += tst_qdrag.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qevent/qevent.pro b/tests/auto/gui/kernel/qevent/qevent.pro
index 502c9ccc97..09d4395f4d 100644
--- a/tests/auto/gui/kernel/qevent/qevent.pro
+++ b/tests/auto/gui/kernel/qevent/qevent.pro
@@ -3,4 +3,3 @@ TARGET = tst_qevent
SOURCES += tst_qevent.cpp
QT = core testlib
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/qfileopeneventexternal.pro b/tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/qfileopeneventexternal.pro
index dc6d38f866..b84ff760ca 100644
--- a/tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/qfileopeneventexternal.pro
+++ b/tests/auto/gui/kernel/qfileopenevent/qfileopeneventexternal/qfileopeneventexternal.pro
@@ -2,4 +2,3 @@ TEMPLATE = app
TARGET = qfileopeneventexternal
QT += core gui
SOURCES += qfileopeneventexternal.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qfileopenevent/test/test.pro b/tests/auto/gui/kernel/qfileopenevent/test/test.pro
index 78fcc4ce38..a6d3f322ef 100644
--- a/tests/auto/gui/kernel/qfileopenevent/test/test.pro
+++ b/tests/auto/gui/kernel/qfileopenevent/test/test.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qfileopenevent
QT += testlib
SOURCES += tst_qfileopenevent.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qguiapplication/qguiapplication.pro b/tests/auto/gui/kernel/qguiapplication/qguiapplication.pro
index 8c26529170..a9baf29996 100644
--- a/tests/auto/gui/kernel/qguiapplication/qguiapplication.pro
+++ b/tests/auto/gui/kernel/qguiapplication/qguiapplication.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qguiapplication
QT += core gui gui-private testlib
SOURCES = tst_qguiapplication.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qguieventdispatcher/qguieventdispatcher.pro b/tests/auto/gui/kernel/qguieventdispatcher/qguieventdispatcher.pro
index 3b1f14756d..3057037e74 100644
--- a/tests/auto/gui/kernel/qguieventdispatcher/qguieventdispatcher.pro
+++ b/tests/auto/gui/kernel/qguieventdispatcher/qguieventdispatcher.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qguieventdispatcher
QT = core gui testlib
SOURCES += ../../../corelib/kernel/qeventdispatcher/tst_qeventdispatcher.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qguimetatype/qguimetatype.pro b/tests/auto/gui/kernel/qguimetatype/qguimetatype.pro
index a0b433a6e9..914142404b 100644
--- a/tests/auto/gui/kernel/qguimetatype/qguimetatype.pro
+++ b/tests/auto/gui/kernel/qguimetatype/qguimetatype.pro
@@ -3,4 +3,3 @@ TARGET = tst_qguimetatype
SOURCES += tst_qguimetatype.cpp
QT = core gui testlib
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qguitimer/qguitimer.pro b/tests/auto/gui/kernel/qguitimer/qguitimer.pro
index 8023b56b34..15793d6e70 100644
--- a/tests/auto/gui/kernel/qguitimer/qguitimer.pro
+++ b/tests/auto/gui/kernel/qguitimer/qguitimer.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qguitimer
QT = core gui testlib
SOURCES += ../../../corelib/kernel/qtimer/tst_qtimer.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qguivariant/no_application/no_application.pro b/tests/auto/gui/kernel/qguivariant/no_application/no_application.pro
index 8f6160cfe5..cc72c225a3 100644
--- a/tests/auto/gui/kernel/qguivariant/no_application/no_application.pro
+++ b/tests/auto/gui/kernel/qguivariant/no_application/no_application.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = no_application
SOURCES += main.cpp
QT += testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qguivariant/test/test.pro b/tests/auto/gui/kernel/qguivariant/test/test.pro
index a2f18956d7..d47cf7bf6f 100644
--- a/tests/auto/gui/kernel/qguivariant/test/test.pro
+++ b/tests/auto/gui/kernel/qguivariant/test/test.pro
@@ -4,4 +4,3 @@ TARGET = tst_qguivariant
SOURCES += tst_qguivariant.cpp
INCLUDEPATH += $$PWD/../../../../other/qvariant_common
QT += testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qinputmethod/qinputmethod.pro b/tests/auto/gui/kernel/qinputmethod/qinputmethod.pro
index afbc595467..ff491c1e25 100644
--- a/tests/auto/gui/kernel/qinputmethod/qinputmethod.pro
+++ b/tests/auto/gui/kernel/qinputmethod/qinputmethod.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qinputmethod
SOURCES += tst_qinputmethod.cpp
QT += core-private gui-private testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qkeysequence/tst_qkeysequence.cpp b/tests/auto/gui/kernel/qkeysequence/tst_qkeysequence.cpp
index a2ee14db45..a6134de497 100644
--- a/tests/auto/gui/kernel/qkeysequence/tst_qkeysequence.cpp
+++ b/tests/auto/gui/kernel/qkeysequence/tst_qkeysequence.cpp
@@ -133,6 +133,10 @@ private slots:
void parseString();
void fromString_data();
void fromString();
+ void listToString_data();
+ void listToString();
+ void listFromString_data();
+ void listFromString();
#ifdef QT_BUILD_INTERNAL
void ensureSorted();
#endif
@@ -631,6 +635,104 @@ void tst_QKeySequence::fromString()
QCOMPARE(ks4, ks1);
}
+void tst_QKeySequence::listToString_data()
+{
+ QTest::addColumn<QString>("strSequences");
+ QTest::addColumn<QList<QKeySequence> >("sequences");
+
+ QList<QKeySequence> sequences;
+
+ sequences << QKeySequence(Qt::CTRL + Qt::Key_Left)
+ << QKeySequence(Qt::META + Qt::Key_A);
+ QTest::newRow("Ctrl+Left; Meta+A") << "Ctrl+Left; Meta+A" << sequences;
+
+ sequences.clear();
+ sequences << QKeySequence(Qt::CTRL + Qt::Key_Semicolon)
+ << QKeySequence(Qt::META + Qt::Key_A);
+ QTest::newRow("Ctrl+;; Meta+A") << "Ctrl+;; Meta+A" << sequences;
+
+ sequences.clear();
+ sequences << QKeySequence(Qt::Key_Semicolon)
+ << QKeySequence(Qt::META + Qt::Key_A);
+ QTest::newRow(";; Meta+A") << ";; Meta+A" << sequences;
+
+ sequences.clear();
+ sequences << QKeySequence(Qt::CTRL + Qt::Key_Left)
+ << QKeySequence(Qt::META + Qt::Key_Semicolon);
+ QTest::newRow("Ctrl+Left; Meta+;") << "Ctrl+Left; Meta+;" << sequences;
+
+ sequences.clear();
+ sequences << QKeySequence(Qt::CTRL + Qt::Key_Left)
+ << QKeySequence();
+ QTest::newRow("Ctrl+Left; ") << "Ctrl+Left; " << sequences;
+
+ sequences.clear();
+ sequences << QKeySequence(Qt::CTRL + Qt::Key_Left)
+ << QKeySequence()
+ << QKeySequence(Qt::META + Qt::Key_A);
+ QTest::newRow("Ctrl+Left; ; Meta+A") << "Ctrl+Left; ; Meta+A" << sequences;
+}
+
+void tst_QKeySequence::listToString()
+{
+ QFETCH(QList<QKeySequence>, sequences);
+ QFETCH(QString, strSequences);
+
+ QCOMPARE(QKeySequence::listToString(sequences), strSequences);
+}
+
+void tst_QKeySequence::listFromString_data()
+{
+ QTest::addColumn<QString>("strSequences");
+ QTest::addColumn<QList<QKeySequence> >("sequences");
+
+ QList<QKeySequence> sequences;
+
+ sequences << QKeySequence(Qt::CTRL + Qt::Key_Left)
+ << QKeySequence(Qt::META + Qt::Key_A);
+ QTest::newRow("Ctrl+Left; Meta+A") << "Ctrl+Left; Meta+A" << sequences;
+
+ sequences.clear();
+ sequences << QKeySequence(Qt::CTRL + Qt::Key_Semicolon)
+ << QKeySequence(Qt::META + Qt::Key_A);
+ QTest::newRow("Ctrl+;; Meta+A") << "Ctrl+;; Meta+A" << sequences;
+
+ sequences.clear();
+ sequences << QKeySequence(Qt::Key_Semicolon)
+ << QKeySequence(Qt::META + Qt::Key_A);
+ QTest::newRow(";; Meta+A") << ";; Meta+A" << sequences;
+
+ sequences.clear();
+ sequences << QKeySequence(Qt::CTRL + Qt::Key_Left)
+ << QKeySequence(Qt::META + Qt::Key_Semicolon);
+ QTest::newRow("Ctrl+Left; Meta+;") << "Ctrl+Left; Meta+;" << sequences;
+
+ sequences.clear();
+ sequences << QKeySequence(Qt::CTRL + Qt::Key_Left)
+ << QKeySequence();
+ QTest::newRow("Ctrl+Left; ") << "Ctrl+Left; " << sequences;
+
+ sequences.clear();
+ sequences << QKeySequence(Qt::CTRL + Qt::Key_Left)
+ << QKeySequence()
+ << QKeySequence(Qt::META + Qt::Key_A);
+ QTest::newRow("Ctrl+Left; ; Meta+A") << "Ctrl+Left; ; Meta+A" << sequences;
+
+ sequences.clear();
+ sequences << QKeySequence(Qt::CTRL + Qt::Key_Left)
+ << QKeySequence(Qt::Key_unknown)
+ << QKeySequence(Qt::META + Qt::Key_A);
+ QTest::newRow("Ctrl+Left; 4+3=2; Meta+A") << "Ctrl+Left; 4+3=2; Meta+A" << sequences;
+}
+
+void tst_QKeySequence::listFromString()
+{
+ QFETCH(QList<QKeySequence>, sequences);
+ QFETCH(QString, strSequences);
+
+ QCOMPARE(QKeySequence::listFromString(strSequences), sequences);
+}
+
#if !defined (Q_OS_MAC) && !defined (Q_OS_WINCE)
void tst_QKeySequence::translated_data()
{
diff --git a/tests/auto/gui/kernel/qmouseevent/qmouseevent.pro b/tests/auto/gui/kernel/qmouseevent/qmouseevent.pro
index 029a559417..5fa886334a 100644
--- a/tests/auto/gui/kernel/qmouseevent/qmouseevent.pro
+++ b/tests/auto/gui/kernel/qmouseevent/qmouseevent.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qmouseevent
QT += testlib
SOURCES += tst_qmouseevent.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qmouseevent_modal/qmouseevent_modal.pro b/tests/auto/gui/kernel/qmouseevent_modal/qmouseevent_modal.pro
index 3eefe49c00..7fd3a59edc 100644
--- a/tests/auto/gui/kernel/qmouseevent_modal/qmouseevent_modal.pro
+++ b/tests/auto/gui/kernel/qmouseevent_modal/qmouseevent_modal.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qmouseevent_modal.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qpalette/qpalette.pro b/tests/auto/gui/kernel/qpalette/qpalette.pro
index 079332ee9f..de87e8fafe 100644
--- a/tests/auto/gui/kernel/qpalette/qpalette.pro
+++ b/tests/auto/gui/kernel/qpalette/qpalette.pro
@@ -6,4 +6,3 @@ SOURCES += tst_qpalette.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qscreen/qscreen.pro b/tests/auto/gui/kernel/qscreen/qscreen.pro
index bb549da2ec..b2c98a9dfd 100644
--- a/tests/auto/gui/kernel/qscreen/qscreen.pro
+++ b/tests/auto/gui/kernel/qscreen/qscreen.pro
@@ -5,4 +5,3 @@ TARGET = tst_qscreen
QT += core-private gui-private testlib
SOURCES += tst_qscreen.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qsurfaceformat/qsurfaceformat.pro b/tests/auto/gui/kernel/qsurfaceformat/qsurfaceformat.pro
new file mode 100644
index 0000000000..9a705f443e
--- /dev/null
+++ b/tests/auto/gui/kernel/qsurfaceformat/qsurfaceformat.pro
@@ -0,0 +1,7 @@
+CONFIG += testcase
+CONFIG += parallel_test
+TARGET = tst_qsurfaceformat
+
+QT += core-private gui-private testlib
+
+SOURCES += tst_qsurfaceformat.cpp
diff --git a/tests/auto/gui/kernel/qsurfaceformat/tst_qsurfaceformat.cpp b/tests/auto/gui/kernel/qsurfaceformat/tst_qsurfaceformat.cpp
new file mode 100644
index 0000000000..bd4fc88b3c
--- /dev/null
+++ b/tests/auto/gui/kernel/qsurfaceformat/tst_qsurfaceformat.cpp
@@ -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 test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <qsurfaceformat.h>
+
+#include <QtTest/QtTest>
+
+class tst_QSurfaceFormat: public QObject
+{
+ Q_OBJECT
+
+private slots:
+ void versionCheck_data();
+ void versionCheck();
+};
+
+void tst_QSurfaceFormat::versionCheck_data()
+{
+ QTest::addColumn<int>("formatMajor");
+ QTest::addColumn<int>("formatMinor");
+ QTest::addColumn<int>("compareMajor");
+ QTest::addColumn<int>("compareMinor");
+ QTest::addColumn<bool>("expected");
+
+ QTest::newRow("lower major, lower minor")
+ << 3 << 2 << 2 << 1 << true;
+ QTest::newRow("lower major, same minor")
+ << 3 << 2 << 2 << 2 << true;
+ QTest::newRow("lower major, greater minor")
+ << 3 << 2 << 2 << 3 << true;
+ QTest::newRow("same major, lower minor")
+ << 3 << 2 << 3 << 1 << true;
+ QTest::newRow("same major, same minor")
+ << 3 << 2 << 3 << 2 << true;
+ QTest::newRow("same major, greater minor")
+ << 3 << 2 << 3 << 3 << false;
+ QTest::newRow("greater major, lower minor")
+ << 3 << 2 << 4 << 1 << false;
+ QTest::newRow("greater major, same minor")
+ << 3 << 2 << 4 << 2 << false;
+ QTest::newRow("greater major, greater minor")
+ << 3 << 2 << 4 << 3 << false;
+}
+
+void tst_QSurfaceFormat::versionCheck()
+{
+ QFETCH( int, formatMajor );
+ QFETCH( int, formatMinor );
+ QFETCH( int, compareMajor );
+ QFETCH( int, compareMinor );
+ QFETCH( bool, expected );
+
+ QSurfaceFormat format;
+ format.setMinorVersion(formatMinor);
+ format.setMajorVersion(formatMajor);
+
+ QCOMPARE(format.version() >= qMakePair(compareMajor, compareMinor), expected);
+
+ format.setVersion(formatMajor, formatMinor);
+ QCOMPARE(format.version() >= qMakePair(compareMajor, compareMinor), expected);
+}
+
+#include <tst_qsurfaceformat.moc>
+QTEST_MAIN(tst_QSurfaceFormat);
diff --git a/tests/auto/gui/kernel/qtouchevent/qtouchevent.pro b/tests/auto/gui/kernel/qtouchevent/qtouchevent.pro
index c6e9aa8a2e..7136611165 100644
--- a/tests/auto/gui/kernel/qtouchevent/qtouchevent.pro
+++ b/tests/auto/gui/kernel/qtouchevent/qtouchevent.pro
@@ -1,4 +1,3 @@
SOURCES=tst_qtouchevent.cpp
TARGET=tst_qtouchevent
QT += testlib widgets gui-private
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qtouchevent/tst_qtouchevent.cpp b/tests/auto/gui/kernel/qtouchevent/tst_qtouchevent.cpp
index 9aebe135ef..5934776c5b 100644
--- a/tests/auto/gui/kernel/qtouchevent/tst_qtouchevent.cpp
+++ b/tests/auto/gui/kernel/qtouchevent/tst_qtouchevent.cpp
@@ -414,7 +414,7 @@ void tst_QTouchEvent::touchBeginPropagatesWhenIgnored()
// QGraphicsView
{
QGraphicsScene scene;
- tst_QTouchEventGraphicsItem root, child, grandchild;
+ tst_QTouchEventGraphicsItem root, child, grandchild;
QGraphicsView view(&scene);
scene.addItem(&root);
root.setPos(100, 100);
@@ -778,7 +778,7 @@ void tst_QTouchEvent::multiPointRawEventTranslationOnTouchScreen()
QVERIFY(rightWidget.seenTouchBegin);
QVERIFY(!rightWidget.seenTouchUpdate);
QVERIFY(!rightWidget.seenTouchEnd);
- QCOMPARE(leftWidget.touchBeginPoints.count(), 1);
+ QCOMPARE(leftWidget.touchBeginPoints.count(), 1);
QCOMPARE(rightWidget.touchBeginPoints.count(), 1);
{
QTouchEvent::TouchPoint leftTouchPoint = leftWidget.touchBeginPoints.first();
@@ -1633,4 +1633,4 @@ void tst_QTouchEvent::testMultiDevice()
QTEST_MAIN(tst_QTouchEvent)
-#include "tst_qtouchevent.moc"
+#include "tst_qtouchevent.moc"
diff --git a/tests/auto/gui/kernel/qwindow/qwindow.pro b/tests/auto/gui/kernel/qwindow/qwindow.pro
index 8e9be27139..e419a10440 100644
--- a/tests/auto/gui/kernel/qwindow/qwindow.pro
+++ b/tests/auto/gui/kernel/qwindow/qwindow.pro
@@ -4,4 +4,3 @@ TARGET = tst_qwindow
QT += core-private gui-private testlib
SOURCES += tst_qwindow.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp b/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp
index 30666aaf2a..b67920737e 100644
--- a/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp
+++ b/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp
@@ -49,6 +49,7 @@
// For QSignalSpy slot connections.
Q_DECLARE_METATYPE(Qt::ScreenOrientation)
+Q_DECLARE_METATYPE(QWindow::Visibility)
class tst_QWindow: public QObject
{
@@ -75,6 +76,8 @@ private slots:
void inputReentrancy();
void tabletEvents();
void windowModality_QTBUG27039();
+ void visibility();
+ void mask();
void initTestCase()
{
@@ -1079,6 +1082,60 @@ void tst_QWindow::windowModality_QTBUG27039()
QCOMPARE(modalA.mousePressedCount, 1);
}
+void tst_QWindow::visibility()
+{
+ qRegisterMetaType<Qt::WindowModality>("QWindow::Visibility");
+
+ QWindow window;
+ QSignalSpy spy(&window, SIGNAL(visibilityChanged(QWindow::Visibility)));
+
+ window.setVisibility(QWindow::AutomaticVisibility);
+ QVERIFY(window.isVisible());
+ QVERIFY(window.visibility() != QWindow::Hidden);
+ QVERIFY(window.visibility() != QWindow::AutomaticVisibility);
+ QCOMPARE(spy.count(), 1);
+ spy.clear();
+
+ window.setVisibility(QWindow::Hidden);
+ QVERIFY(!window.isVisible());
+ QCOMPARE(window.visibility(), QWindow::Hidden);
+ QCOMPARE(spy.count(), 1);
+ spy.clear();
+
+ window.setVisibility(QWindow::FullScreen);
+ QVERIFY(window.isVisible());
+ QCOMPARE(window.windowState(), Qt::WindowFullScreen);
+ QCOMPARE(window.visibility(), QWindow::FullScreen);
+ QCOMPARE(spy.count(), 1);
+ spy.clear();
+
+ window.setWindowState(Qt::WindowNoState);
+ QCOMPARE(window.visibility(), QWindow::Windowed);
+ QCOMPARE(spy.count(), 1);
+ spy.clear();
+
+ window.setVisible(false);
+ QCOMPARE(window.visibility(), QWindow::Hidden);
+ QCOMPARE(spy.count(), 1);
+ spy.clear();
+}
+
+void tst_QWindow::mask()
+{
+ QRegion mask = QRect(10, 10, 800 - 20, 600 - 20);
+
+ QWindow window;
+ window.resize(800, 600);
+ window.setMask(mask);
+
+ QCOMPARE(window.mask(), QRegion());
+
+ window.create();
+ window.setMask(mask);
+
+ QCOMPARE(window.mask(), mask);
+}
+
#include <tst_qwindow.moc>
QTEST_MAIN(tst_QWindow)
diff --git a/tests/auto/gui/math3d/qquaternion/qquaternion.pro b/tests/auto/gui/math3d/qquaternion/qquaternion.pro
index cc2039cc73..d20719fd11 100644
--- a/tests/auto/gui/math3d/qquaternion/qquaternion.pro
+++ b/tests/auto/gui/math3d/qquaternion/qquaternion.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qquaternion
SOURCES += tst_qquaternion.cpp
QT += testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/math3d/qvectornd/qvectornd.pro b/tests/auto/gui/math3d/qvectornd/qvectornd.pro
index 7c4d4a04b2..9504b4a02b 100644
--- a/tests/auto/gui/math3d/qvectornd/qvectornd.pro
+++ b/tests/auto/gui/math3d/qvectornd/qvectornd.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qvectornd
SOURCES += tst_qvectornd.cpp
QT += testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/math3d/qvectornd/tst_qvectornd.cpp b/tests/auto/gui/math3d/qvectornd/tst_qvectornd.cpp
index 5cd597aeb8..0041ad0015 100644
--- a/tests/auto/gui/math3d/qvectornd/tst_qvectornd.cpp
+++ b/tests/auto/gui/math3d/qvectornd/tst_qvectornd.cpp
@@ -128,10 +128,16 @@ private slots:
void crossProduct();
void normal_data();
void normal();
+ void distanceToPoint2_data();
+ void distanceToPoint2();
+ void distanceToPoint3_data();
+ void distanceToPoint3();
void distanceToPlane_data();
void distanceToPlane();
- void distanceToLine_data();
- void distanceToLine();
+ void distanceToLine2_data();
+ void distanceToLine2();
+ void distanceToLine3_data();
+ void distanceToLine3();
void dotProduct2_data();
void dotProduct2();
@@ -1788,6 +1794,108 @@ void tst_QVectorND::normal()
QVERIFY(QVector3D::normal(point, v1 + point, v2 + point) == v3.normalized());
}
+// Test distance to point calculations.
+void tst_QVectorND::distanceToPoint2_data()
+{
+ QTest::addColumn<float>("x1"); // Point to test for distance
+ QTest::addColumn<float>("y1");
+ QTest::addColumn<float>("x2"); // Point to test against
+ QTest::addColumn<float>("y2");
+
+ QTest::addColumn<float>("distance");
+
+ QTest::newRow("null")
+ << 0.0f << 0.0f
+ << 0.0f << 1.0f
+ << 1.0f;
+
+ QTest::newRow("on point")
+ << 1.0f << 1.0f
+ << 1.0f << 1.0f
+ << 0.0f;
+
+ QTest::newRow("off point")
+ << 0.0f << 1.0f
+ << 0.0f << 2.0f
+ << 1.0f;
+
+ QTest::newRow("off point 2")
+ << 0.0f << 0.0f
+ << 0.0f << 2.0f
+ << 2.0f;
+
+ QTest::newRow("minus point")
+ << 0.0f << 0.0f
+ << 0.0f << -2.0f
+ << 2.0f;
+}
+void tst_QVectorND::distanceToPoint2()
+{
+ QFETCH(float, x1);
+ QFETCH(float, y1);
+ QFETCH(float, x2);
+ QFETCH(float, y2);
+ QFETCH(float, distance);
+
+ QVector2D v1(x1, y1);
+ QVector2D v2(x2, y2);
+
+ QCOMPARE(v1.distanceToPoint(v2), distance);
+}
+
+// Test distance to point calculations.
+void tst_QVectorND::distanceToPoint3_data()
+{
+ QTest::addColumn<float>("x1"); // Point to test for distance
+ QTest::addColumn<float>("y1");
+ QTest::addColumn<float>("z1");
+ QTest::addColumn<float>("x2"); // Point to test against
+ QTest::addColumn<float>("y2");
+ QTest::addColumn<float>("z2");
+
+ QTest::addColumn<float>("distance");
+
+ QTest::newRow("null")
+ << 0.0f << 0.0f << 0.0f
+ << 0.0f << 0.0f << 1.0f
+ << 1.0f;
+
+ QTest::newRow("on point")
+ << 0.0f << 0.0f << 0.0f
+ << 0.0f << 0.0f << 0.0f
+ << 0.0f;
+
+ QTest::newRow("off point")
+ << 0.0f << 0.0f << 1.0f
+ << 0.0f << 0.0f << 2.0f
+ << 1.0f;
+
+ QTest::newRow("off point 2")
+ << 0.0f << 0.0f << 0.0f
+ << 0.0f << 2.0f << 0.0f
+ << 2.0f;
+
+ QTest::newRow("minus point")
+ << 0.0f << 0.0f << 0.0f
+ << 0.0f << -2.0f << 0.0f
+ << 2.0f;
+}
+void tst_QVectorND::distanceToPoint3()
+{
+ QFETCH(float, x1);
+ QFETCH(float, y1);
+ QFETCH(float, z1);
+ QFETCH(float, x2);
+ QFETCH(float, y2);
+ QFETCH(float, z2);
+ QFETCH(float, distance);
+
+ QVector3D v1(x1, y1, z1);
+ QVector3D v2(x2, y2, z2);
+
+ QCOMPARE(v1.distanceToPoint(v2), distance);
+}
+
// Test distance to plane calculations.
void tst_QVectorND::distanceToPlane_data()
{
@@ -1862,7 +1970,65 @@ void tst_QVectorND::distanceToPlane()
}
// Test distance to line calculations.
-void tst_QVectorND::distanceToLine_data()
+void tst_QVectorND::distanceToLine2_data()
+{
+ QTest::addColumn<float>("x1"); // Point on line
+ QTest::addColumn<float>("y1");
+ QTest::addColumn<float>("x2"); // Direction of the line
+ QTest::addColumn<float>("y2");
+ QTest::addColumn<float>("x3"); // Point to test for distance
+ QTest::addColumn<float>("y3");
+ QTest::addColumn<float>("distance");
+
+ QTest::newRow("null")
+ << 0.0f << 0.0f
+ << 0.0f << 0.1f
+ << 0.0f << 0.0f
+ << 0.0f;
+
+ QTest::newRow("on line")
+ << 0.0f << 0.0f
+ << 0.0f << 1.0f
+ << 0.0f << 5.0f
+ << 0.0f;
+
+ QTest::newRow("off line")
+ << 0.0f << 0.0f
+ << 0.0f << 1.0f
+ << 1.0f << 0.0f
+ << 1.0f;
+
+ QTest::newRow("off line 2")
+ << 0.0f << 0.0f
+ << 0.0f << 1.0f
+ << -2.0f << 0.0f
+ << 2.0f;
+
+ QTest::newRow("points")
+ << 0.0f << 0.0f
+ << 0.0f << 0.0f
+ << 0.0f << 5.0f
+ << 5.0f;
+}
+
+void tst_QVectorND::distanceToLine2()
+{
+ QFETCH(float, x1);
+ QFETCH(float, y1);
+ QFETCH(float, x2);
+ QFETCH(float, y2);
+ QFETCH(float, x3);
+ QFETCH(float, y3);
+ QFETCH(float, distance);
+
+ QVector2D v1(x1, y1);
+ QVector2D v2(x2, y2);
+ QVector2D v3(x3, y3);
+
+ QCOMPARE(v3.distanceToLine(v1, v2), distance);
+}
+// Test distance to line calculations.
+void tst_QVectorND::distanceToLine3_data()
{
QTest::addColumn<float>("x1"); // Point on line
QTest::addColumn<float>("y1");
@@ -1905,7 +2071,7 @@ void tst_QVectorND::distanceToLine_data()
<< 0.0f << 5.0f << 0.0f
<< 5.0f;
}
-void tst_QVectorND::distanceToLine()
+void tst_QVectorND::distanceToLine3()
{
QFETCH(float, x1);
QFETCH(float, y1);
diff --git a/tests/auto/gui/painting/qbrush/qbrush.pro b/tests/auto/gui/painting/qbrush/qbrush.pro
index 3710c4593f..526de12815 100644
--- a/tests/auto/gui/painting/qbrush/qbrush.pro
+++ b/tests/auto/gui/painting/qbrush/qbrush.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qbrush
QT += testlib
SOURCES += tst_qbrush.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/painting/qcolor/qcolor.pro b/tests/auto/gui/painting/qcolor/qcolor.pro
index 77e89d5cf5..f7439c243c 100644
--- a/tests/auto/gui/painting/qcolor/qcolor.pro
+++ b/tests/auto/gui/painting/qcolor/qcolor.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qcolor
SOURCES += tst_qcolor.cpp
QT += testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/painting/qpaintengine/qpaintengine.pro b/tests/auto/gui/painting/qpaintengine/qpaintengine.pro
index 7691b5b625..1cf79af0a7 100644
--- a/tests/auto/gui/painting/qpaintengine/qpaintengine.pro
+++ b/tests/auto/gui/painting/qpaintengine/qpaintengine.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qpaintengine
SOURCES += tst_qpaintengine.cpp
QT += testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/painting/qpainter/qpainter.pro b/tests/auto/gui/painting/qpainter/qpainter.pro
index a30564cc50..752f9be1f4 100644
--- a/tests/auto/gui/painting/qpainter/qpainter.pro
+++ b/tests/auto/gui/painting/qpainter/qpainter.pro
@@ -4,7 +4,6 @@ TARGET = tst_qpainter
QT += testlib
qtHaveModule(widgets): QT += widgets widgets-private
-qtHaveModule(widgets):!wince*: QT += printsupport
SOURCES += tst_qpainter.cpp
diff --git a/tests/auto/gui/painting/qpainter/tst_qpainter.cpp b/tests/auto/gui/painting/qpainter/tst_qpainter.cpp
index 57ffcaf30d..4f1213dff9 100644
--- a/tests/auto/gui/painting/qpainter/tst_qpainter.cpp
+++ b/tests/auto/gui/painting/qpainter/tst_qpainter.cpp
@@ -53,9 +53,6 @@
#include <qthread.h>
#include <limits.h>
#if !defined(Q_OS_WINCE)
-#ifndef QT_NO_WIDGETS
-#include <qprinter.h>
-#endif
#include <math.h>
#endif
#include <qpaintengine.h>
diff --git a/tests/auto/gui/painting/qpainterpath/qpainterpath.pro b/tests/auto/gui/painting/qpainterpath/qpainterpath.pro
index ab41241779..0c0fe8951a 100644
--- a/tests/auto/gui/painting/qpainterpath/qpainterpath.pro
+++ b/tests/auto/gui/painting/qpainterpath/qpainterpath.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qpainterpath
SOURCES += tst_qpainterpath.cpp
QT += testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/painting/qpainterpathstroker/qpainterpathstroker.pro b/tests/auto/gui/painting/qpainterpathstroker/qpainterpathstroker.pro
index bd9500ad05..8ad476b498 100644
--- a/tests/auto/gui/painting/qpainterpathstroker/qpainterpathstroker.pro
+++ b/tests/auto/gui/painting/qpainterpathstroker/qpainterpathstroker.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qpainterpathstroker
SOURCES += tst_qpainterpathstroker.cpp
QT += testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/painting/qpathclipper/paths.cpp b/tests/auto/gui/painting/qpathclipper/paths.cpp
index d7f0d6d59b..3bc2484578 100644
--- a/tests/auto/gui/painting/qpathclipper/paths.cpp
+++ b/tests/auto/gui/painting/qpathclipper/paths.cpp
@@ -127,7 +127,7 @@ QPainterPath Paths::body()
path.cubicTo(105.28125,81.341000, 89.784000,65.812500, 70.531250,65.812500);
path.lineTo(54.437500,65.812500);
path.closeSubpath();
-
+
return path;
}
@@ -143,7 +143,7 @@ QPainterPath Paths::mailbox()
path.lineTo(443.62570,100.11509);
path.lineTo(355.22951,136.82424);
path.closeSubpath();
-
+
return path;
}
@@ -271,7 +271,7 @@ QPainterPath Paths::lips()
path.cubicTo(283.58862,123.78263, 270.15105,136.64382, 243.62716,155.61729);
path.cubicTo(217.47805,174.32266, 199.38332,176.65905, 177.02257,176.65905);
path.closeSubpath();
-
+
return path;
}
@@ -290,14 +290,14 @@ QPainterPath Paths::bezier2()
QPainterPath path;
path.moveTo(200,200);
path.cubicTo(200,125, 500,100, 500,500);
-
+
return path;
}
QPainterPath Paths::random1()
{
QPainterPath path;
-
+
path.moveTo(65.714286,91.428571);
path.lineTo(217.14286, 102.85714);
path.cubicTo(219.04762, 106.66666,
@@ -341,7 +341,7 @@ QPainterPath Paths::random1()
QPainterPath Paths::random2()
{
QPainterPath path;
-
+
path.moveTo(314.28571,160);
path.cubicTo(434.28571,125.71429,
505.71429,200,
@@ -573,7 +573,7 @@ QPainterPath Paths::triangle1()
}
QPainterPath Paths::triangle2()
-{
+{
QPainterPath path;
path.moveTo(0, 120);
diff --git a/tests/auto/gui/painting/qpathclipper/qpathclipper.pro b/tests/auto/gui/painting/qpathclipper/qpathclipper.pro
index 5be81a1cce..18f7ccef2f 100644
--- a/tests/auto/gui/painting/qpathclipper/qpathclipper.pro
+++ b/tests/auto/gui/painting/qpathclipper/qpathclipper.pro
@@ -9,4 +9,3 @@ QT += gui-private testlib
requires(contains(QT_CONFIG,private_tests))
unix:!mac:LIBS+=-lm
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/painting/qpen/qpen.pro b/tests/auto/gui/painting/qpen/qpen.pro
index 122aeaf843..cafec29947 100644
--- a/tests/auto/gui/painting/qpen/qpen.pro
+++ b/tests/auto/gui/painting/qpen/qpen.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qpen
SOURCES += tst_qpen.cpp
QT += testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/painting/qpolygon/qpolygon.pro b/tests/auto/gui/painting/qpolygon/qpolygon.pro
index 874704887b..f3e75d7e9e 100644
--- a/tests/auto/gui/painting/qpolygon/qpolygon.pro
+++ b/tests/auto/gui/painting/qpolygon/qpolygon.pro
@@ -7,4 +7,3 @@ SOURCES += tst_qpolygon.cpp
unix:!mac:LIBS+=-lm
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/painting/qregion/qregion.pro b/tests/auto/gui/painting/qregion/qregion.pro
index 66ed81053f..01eb9dd937 100644
--- a/tests/auto/gui/painting/qregion/qregion.pro
+++ b/tests/auto/gui/painting/qregion/qregion.pro
@@ -8,4 +8,3 @@ SOURCES += tst_qregion.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/painting/qtransform/qtransform.pro b/tests/auto/gui/painting/qtransform/qtransform.pro
index b3767cdd04..1b5c2a4f25 100644
--- a/tests/auto/gui/painting/qtransform/qtransform.pro
+++ b/tests/auto/gui/painting/qtransform/qtransform.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qtransform.cpp
QT += testlib
unix:!mac:LIBS+=-lm
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/painting/qwmatrix/qwmatrix.pro b/tests/auto/gui/painting/qwmatrix/qwmatrix.pro
index 39f14b10b6..e0e260555a 100644
--- a/tests/auto/gui/painting/qwmatrix/qwmatrix.pro
+++ b/tests/auto/gui/painting/qwmatrix/qwmatrix.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qwmatrix.cpp
QT += testlib
unix:!mac:LIBS+=-lm
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/painting/qwmatrix/tst_qwmatrix.cpp b/tests/auto/gui/painting/qwmatrix/tst_qwmatrix.cpp
index cd4f808c4e..4c73676329 100644
--- a/tests/auto/gui/painting/qwmatrix/tst_qwmatrix.cpp
+++ b/tests/auto/gui/painting/qwmatrix/tst_qwmatrix.cpp
@@ -154,7 +154,7 @@ void tst_QWMatrix::mapping_data()
<< QRect( 0, 0, 30, 40 )
<< QPolygon( QRect( -300, -400, 300, 400 ) );
-#if defined(Q_OS_WIN32) || defined(Q_OS_WINCE)
+#if (defined(Q_OS_WIN) || defined(Q_OS_WINCE)) && !defined(M_PI)
#define M_PI 3.14159265897932384626433832795f
#endif
diff --git a/tests/auto/gui/qopengl/qopengl.pro b/tests/auto/gui/qopengl/qopengl.pro
index a7e9bef108..91eeda34c3 100644
--- a/tests/auto/gui/qopengl/qopengl.pro
+++ b/tests/auto/gui/qopengl/qopengl.pro
@@ -8,4 +8,3 @@ TARGET = tst_qopengl
QT += gui gui-private core-private testlib
SOURCES += tst_qopengl.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/qopengl/tst_qopengl.cpp b/tests/auto/gui/qopengl/tst_qopengl.cpp
index 1d498773ae..97f3ec128d 100644
--- a/tests/auto/gui/qopengl/tst_qopengl.cpp
+++ b/tests/auto/gui/qopengl/tst_qopengl.cpp
@@ -47,6 +47,7 @@
#include <QtGui/QPainter>
#include <QtGui/QScreen>
#include <QtGui/QWindow>
+#include <QtGui/QOffscreenSurface>
#include <QtTest/QtTest>
@@ -57,12 +58,18 @@ class tst_QOpenGL : public QObject
Q_OBJECT
private slots:
+ void sharedResourceCleanup_data();
void sharedResourceCleanup();
+ void multiGroupSharedResourceCleanup_data();
void multiGroupSharedResourceCleanup();
+ void multiGroupSharedResourceCleanupCustom_data();
void multiGroupSharedResourceCleanupCustom();
+ void fboSimpleRendering_data();
void fboSimpleRendering();
+ void fboRendering_data();
void fboRendering();
void fboHandleNulledAfterContextDestroyed();
+ void openGLPaintDevice_data();
void openGLPaintDevice();
void aboutToBeDestroyed();
void QTBUG15621_triangulatingStrokerDivZero();
@@ -129,16 +136,43 @@ struct SharedResource : public QOpenGLSharedResource
SharedResourceTracker *tracker;
};
+static QSurface *createSurface(int surfaceClass)
+{
+ if (surfaceClass == int(QSurface::Window)) {
+ QWindow *window = new QWindow;
+ window->setSurfaceType(QWindow::OpenGLSurface);
+ window->setGeometry(0, 0, 10, 10);
+ window->create();
+ return window;
+ } else if (surfaceClass == int(QSurface::Offscreen)) {
+ QOffscreenSurface *offscreenSurface = new QOffscreenSurface;
+ offscreenSurface->create();
+ return offscreenSurface;
+ }
+ return 0;
+}
+
+static void common_data()
+{
+ QTest::addColumn<int>("surfaceClass");
+
+ QTest::newRow("Using QWindow") << int(QSurface::Window);
+ QTest::newRow("Using QOffscreenSurface") << int(QSurface::Offscreen);
+}
+
+void tst_QOpenGL::sharedResourceCleanup_data()
+{
+ common_data();
+}
+
void tst_QOpenGL::sharedResourceCleanup()
{
- QWindow window;
- window.setSurfaceType(QWindow::OpenGLSurface);
- window.setGeometry(0, 0, 10, 10);
- window.create();
+ QFETCH(int, surfaceClass);
+ QScopedPointer<QSurface> surface(createSurface(surfaceClass));
QOpenGLContext *ctx = new QOpenGLContext;
ctx->create();
- ctx->makeCurrent(&window);
+ ctx->makeCurrent(surface.data());
SharedResourceTracker tracker;
SharedResource *resource = new SharedResource(&tracker);
@@ -165,7 +199,7 @@ void tst_QOpenGL::sharedResourceCleanup()
QCOMPARE(tracker.freeResourceCalls, 0);
QCOMPARE(tracker.destructorCalls, 0);
- ctx2->makeCurrent(&window);
+ ctx2->makeCurrent(surface.data());
// freeResource() should now have been called
QCOMPARE(tracker.invalidateResourceCalls, 0);
@@ -192,17 +226,20 @@ void tst_QOpenGL::sharedResourceCleanup()
QCOMPARE(tracker.destructorCalls, 1);
}
+void tst_QOpenGL::multiGroupSharedResourceCleanup_data()
+{
+ common_data();
+}
+
void tst_QOpenGL::multiGroupSharedResourceCleanup()
{
- QWindow window;
- window.setSurfaceType(QWindow::OpenGLSurface);
- window.setGeometry(0, 0, 10, 10);
- window.create();
+ QFETCH(int, surfaceClass);
+ QScopedPointer<QSurface> surface(createSurface(surfaceClass));
for (int i = 0; i < 10; ++i) {
QOpenGLContext *gl = new QOpenGLContext();
gl->create();
- gl->makeCurrent(&window);
+ gl->makeCurrent(surface.data());
{
// Cause QOpenGLMultiGroupSharedResource instantiation.
QOpenGLFunctions func(gl);
@@ -214,16 +251,19 @@ void tst_QOpenGL::multiGroupSharedResourceCleanup()
// Shouldn't crash when application exits.
}
+void tst_QOpenGL::multiGroupSharedResourceCleanupCustom_data()
+{
+ common_data();
+}
+
void tst_QOpenGL::multiGroupSharedResourceCleanupCustom()
{
- QWindow window;
- window.setSurfaceType(QWindow::OpenGLSurface);
- window.setGeometry(0, 0, 10, 10);
- window.create();
+ QFETCH(int, surfaceClass);
+ QScopedPointer<QSurface> surface(createSurface(surfaceClass));
QOpenGLContext *ctx = new QOpenGLContext();
ctx->create();
- ctx->makeCurrent(&window);
+ ctx->makeCurrent(surface.data());
QOpenGLMultiGroupSharedResource multiGroupSharedResource;
SharedResource *resource = multiGroupSharedResource.value<SharedResource>(ctx);
@@ -350,17 +390,20 @@ void qt_opengl_check_test_pattern(const QImage& img)
QFUZZY_COMPARE_PIXELS(img.pixel(192, 64), QColor(Qt::green).rgb());
}
+void tst_QOpenGL::fboSimpleRendering_data()
+{
+ common_data();
+}
void tst_QOpenGL::fboSimpleRendering()
{
- QWindow window;
- window.setSurfaceType(QWindow::OpenGLSurface);
- window.setGeometry(0, 0, 10, 10);
- window.create();
+ QFETCH(int, surfaceClass);
+ QScopedPointer<QSurface> surface(createSurface(surfaceClass));
+
QOpenGLContext ctx;
ctx.create();
- ctx.makeCurrent(&window);
+ ctx.makeCurrent(surface.data());
if (!QOpenGLFramebufferObject::hasOpenGLFramebufferObjects())
QSKIP("QOpenGLFramebufferObject not supported on this platform");
@@ -386,6 +429,11 @@ void tst_QOpenGL::fboSimpleRendering()
delete fbo;
}
+void tst_QOpenGL::fboRendering_data()
+{
+ common_data();
+}
+
// NOTE: This tests that CombinedDepthStencil attachment works by assuming the
// GL2 engine is being used and is implemented the same way as it was when
// this autotest was written. If this is not the case, there may be some
@@ -397,14 +445,13 @@ void tst_QOpenGL::fboRendering()
QSKIP("QTBUG-22617");
#endif
- QWindow window;
- window.setSurfaceType(QWindow::OpenGLSurface);
- window.setGeometry(0, 0, 10, 10);
- window.create();
+ QFETCH(int, surfaceClass);
+ QScopedPointer<QSurface> surface(createSurface(surfaceClass));
+
QOpenGLContext ctx;
ctx.create();
- ctx.makeCurrent(&window);
+ ctx.makeCurrent(surface.data());
if (!QOpenGLFramebufferObject::hasOpenGLFramebufferObjects())
QSKIP("QOpenGLFramebufferObject not supported on this platform");
@@ -461,16 +508,19 @@ void tst_QOpenGL::fboHandleNulledAfterContextDestroyed()
QCOMPARE(fbo->handle(), 0U);
}
+void tst_QOpenGL::openGLPaintDevice_data()
+{
+ common_data();
+}
+
void tst_QOpenGL::openGLPaintDevice()
{
#if defined(Q_OS_LINUX) && defined(Q_CC_GNU) && !defined(__x86_64__)
QSKIP("QTBUG-22617");
#endif
- QWindow window;
- window.setSurfaceType(QWindow::OpenGLSurface);
- window.setGeometry(0, 0, 128, 128);
- window.create();
+ QFETCH(int, surfaceClass);
+ QScopedPointer<QSurface> surface(createSurface(surfaceClass));
QOpenGLContext ctx;
ctx.create();
@@ -478,7 +528,7 @@ void tst_QOpenGL::openGLPaintDevice()
QSurfaceFormat format = ctx.format();
if (format.majorVersion() < 2)
QSKIP("This test requires at least OpenGL 2.0");
- ctx.makeCurrent(&window);
+ ctx.makeCurrent(surface.data());
QImage image(128, 128, QImage::Format_RGB32);
QPainter p(&image);
diff --git a/tests/auto/gui/text/qabstracttextdocumentlayout/qabstracttextdocumentlayout.pro b/tests/auto/gui/text/qabstracttextdocumentlayout/qabstracttextdocumentlayout.pro
index bb6457853e..866638f154 100644
--- a/tests/auto/gui/text/qabstracttextdocumentlayout/qabstracttextdocumentlayout.pro
+++ b/tests/auto/gui/text/qabstracttextdocumentlayout/qabstracttextdocumentlayout.pro
@@ -9,4 +9,3 @@ QT += testlib
SOURCES += tst_qabstracttextdocumentlayout.cpp
linux: CONFIG += insignificant_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qcssparser/qcssparser.pro b/tests/auto/gui/text/qcssparser/qcssparser.pro
index 43d363dc7b..346a38d5f6 100644
--- a/tests/auto/gui/text/qcssparser/qcssparser.pro
+++ b/tests/auto/gui/text/qcssparser/qcssparser.pro
@@ -15,4 +15,3 @@ wince* {
DEPLOYMENT += addFiles timesFont
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qfontcache/.gitignore b/tests/auto/gui/text/qfontcache/.gitignore
new file mode 100644
index 0000000000..e963ab010a
--- /dev/null
+++ b/tests/auto/gui/text/qfontcache/.gitignore
@@ -0,0 +1 @@
+tst_qfontcache
diff --git a/tests/auto/gui/text/qfontcache/qfontcache.pro b/tests/auto/gui/text/qfontcache/qfontcache.pro
new file mode 100644
index 0000000000..5068c12cd6
--- /dev/null
+++ b/tests/auto/gui/text/qfontcache/qfontcache.pro
@@ -0,0 +1,7 @@
+CONFIG += testcase
+CONFIG += parallel_test
+TARGET = tst_qfontcache
+QT += testlib
+QT += core-private gui-private
+SOURCES += tst_qfontcache.cpp
+
diff --git a/tests/auto/gui/text/qfontcache/tst_qfontcache.cpp b/tests/auto/gui/text/qfontcache/tst_qfontcache.cpp
new file mode 100644
index 0000000000..a85fadfce7
--- /dev/null
+++ b/tests/auto/gui/text/qfontcache/tst_qfontcache.cpp
@@ -0,0 +1,148 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+#include <QtTest/QtTest>
+
+
+#include <qfont.h>
+#include <private/qfont_p.h>
+#include <private/qfontengine_p.h>
+
+class tst_QFontCache : public QObject
+{
+Q_OBJECT
+
+public:
+ tst_QFontCache();
+ virtual ~tst_QFontCache();
+
+private slots:
+ void clear();
+};
+
+QT_BEGIN_NAMESPACE
+extern void qt_setQtEnableTestFont(bool value); // qfontdatabase.cpp
+
+#ifdef QT_BUILD_INTERNAL
+// qfontengine.cpp
+extern void QFontEngine_startCollectingEngines();
+extern QList<QFontEngine *> QFontEngine_stopCollectingEngines();
+#endif
+QT_END_NAMESPACE
+
+tst_QFontCache::tst_QFontCache()
+{
+}
+
+tst_QFontCache::~tst_QFontCache()
+{
+}
+
+void tst_QFontCache::clear()
+{
+#ifdef QT_BUILD_INTERNAL
+ QFontEngine_startCollectingEngines();
+#else
+ // must not crash, at very least ;)
+#endif
+
+ QFontEngine *fontEngine = 0;
+
+ {
+ // we're never caching the box (and the "test") font engines
+ // let's ensure we're not leaking them as well as the cached ones
+ qt_setQtEnableTestFont(true);
+
+ QFont f;
+ f.setFamily("__Qt__Box__Engine__");
+ f.exactMatch(); // loads engine
+ }
+ {
+ QFontDatabase db;
+
+ QFont f;
+ f.setStyleHint(QFont::Serif);
+ const QString familyForHint(f.defaultFamily());
+
+ // it should at least return a family that is available
+ QVERIFY(db.hasFamily(familyForHint));
+ f.exactMatch(); // loads engine
+
+ fontEngine = QFontPrivate::get(f)->engineForScript(QChar::Script_Common);
+ QVERIFY(fontEngine);
+ QVERIFY(QFontCache::instance()->engineCacheCount.value(fontEngine) > 0); // ensure it is cached
+
+ // acquire the engine to use it somewhere else:
+ // (e.g. like the we do in QFontSubset() or like QRawFont does in fromFont())
+ fontEngine->ref.ref();
+
+ // cache the engine once again; there is a special case when the engine is cached more than once
+ QFontCache::instance()->insertEngine(QFontCache::Key(QFontDef(), 0, 0), fontEngine);
+ }
+
+ // use it:
+ // e.g. fontEngine->stringToCMap(..);
+
+ // and whilst it is alive, don't hesitate to add/remove the app-local fonts:
+ // (QFontDatabase::{add,remove}ApplicationFont() clears the cache)
+ QFontCache::instance()->clear();
+
+ // release the acquired engine:
+ if (fontEngine) {
+ if (!fontEngine->ref.deref())
+ delete fontEngine;
+ fontEngine = 0;
+ }
+
+ // we may even exit the application now:
+ QFontCache::instance()->cleanup();
+
+#ifdef QT_BUILD_INTERNAL
+ QList<QFontEngine *> leakedEngines = QFontEngine_stopCollectingEngines();
+for (int i = 0; i < leakedEngines.size(); ++i) qWarning() << i << leakedEngines.at(i) << leakedEngines.at(i)->ref.load();
+ // and we are not leaking!
+ QCOMPARE(leakedEngines.size(), 0);
+#endif
+}
+
+QTEST_MAIN(tst_QFontCache)
+#include "tst_qfontcache.moc"
diff --git a/tests/auto/gui/text/qfontdatabase/qfontdatabase.pro b/tests/auto/gui/text/qfontdatabase/qfontdatabase.pro
index 3111f515ec..43e04a006f 100644
--- a/tests/auto/gui/text/qfontdatabase/qfontdatabase.pro
+++ b/tests/auto/gui/text/qfontdatabase/qfontdatabase.pro
@@ -4,11 +4,10 @@ TARGET = tst_qfontdatabase
SOURCES += tst_qfontdatabase.cpp
DEFINES += SRCDIR=\\\"$$PWD\\\"
QT += testlib
-!mac: QT += core-private gui-private platformsupport-private
+!mac: QT += core-private gui-private
wince* {
additionalFiles.files = FreeMono.ttf
additionalFiles.path = .
DEPLOYMENT += additionalFiles
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qfontdatabase/tst_qfontdatabase.cpp b/tests/auto/gui/text/qfontdatabase/tst_qfontdatabase.cpp
index 7afc049023..a9ad299ad8 100644
--- a/tests/auto/gui/text/qfontdatabase/tst_qfontdatabase.cpp
+++ b/tests/auto/gui/text/qfontdatabase/tst_qfontdatabase.cpp
@@ -44,9 +44,6 @@
#include <qfontdatabase.h>
#include <qfontinfo.h>
#include <qfontmetrics.h>
-#ifndef Q_OS_MAC
-#include <QtPlatformSupport/private/qbasicfontdatabase_p.h>
-#endif
class tst_QFontDatabase : public QObject
{
@@ -76,10 +73,6 @@ private slots:
void addAppFont_data();
void addAppFont();
-
-#ifndef Q_OS_MAC
- void fontName();
-#endif
};
tst_QFontDatabase::tst_QFontDatabase()
@@ -275,13 +268,5 @@ void tst_QFontDatabase::addAppFont()
QCOMPARE(db.families(), oldFamilies);
}
-#ifndef Q_OS_MAC
-void tst_QFontDatabase::fontName()
-{
- QString fontName = QBasicFontDatabase::fontNameFromTTFile(QStringLiteral("FreeMono.ttf"));
- QCOMPARE(fontName, QStringLiteral("FreeMono"));
-}
-#endif
-
QTEST_MAIN(tst_QFontDatabase)
#include "tst_qfontdatabase.moc"
diff --git a/tests/auto/gui/text/qfontmetrics/qfontmetrics.pro b/tests/auto/gui/text/qfontmetrics/qfontmetrics.pro
index 88436f6a0e..7286c53d74 100644
--- a/tests/auto/gui/text/qfontmetrics/qfontmetrics.pro
+++ b/tests/auto/gui/text/qfontmetrics/qfontmetrics.pro
@@ -4,4 +4,3 @@ TARGET = tst_qfontmetrics
QT += testlib core-private gui-private
SOURCES += tst_qfontmetrics.cpp
RESOURCES += testfont.qrc
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qfontmetrics/tst_qfontmetrics.cpp b/tests/auto/gui/text/qfontmetrics/tst_qfontmetrics.cpp
index 15e8c2ee90..cddec5b6e7 100644
--- a/tests/auto/gui/text/qfontmetrics/tst_qfontmetrics.cpp
+++ b/tests/auto/gui/text/qfontmetrics/tst_qfontmetrics.cpp
@@ -281,7 +281,7 @@ void tst_QFontMetrics::inFontUcs4()
}
{
- QFontEngine *engine = QFontPrivate::get(font)->engineForScript(QUnicodeTables::Common);
+ QFontEngine *engine = QFontPrivate::get(font)->engineForScript(QChar::Script_Common);
QGlyphLayout glyphs;
glyphs.numGlyphs = 3;
uint buf[3];
diff --git a/tests/auto/gui/text/qglyphrun/qglyphrun.pro b/tests/auto/gui/text/qglyphrun/qglyphrun.pro
index 45680febf3..db28a690a7 100644
--- a/tests/auto/gui/text/qglyphrun/qglyphrun.pro
+++ b/tests/auto/gui/text/qglyphrun/qglyphrun.pro
@@ -13,4 +13,3 @@ wince* {
} else {
DEFINES += SRCDIR=\\\"$$PWD/\\\"
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qrawfont/qrawfont.pro b/tests/auto/gui/text/qrawfont/qrawfont.pro
index ce4d0aec40..540ffb94d7 100644
--- a/tests/auto/gui/text/qrawfont/qrawfont.pro
+++ b/tests/auto/gui/text/qrawfont/qrawfont.pro
@@ -8,4 +8,3 @@ SOURCES += \
tst_qrawfont.cpp
TESTDATA += testfont_bold_italic.ttf testfont.ttf
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qstatictext/qstatictext.pro b/tests/auto/gui/text/qstatictext/qstatictext.pro
index 772b68cfff..55b218deb7 100644
--- a/tests/auto/gui/text/qstatictext/qstatictext.pro
+++ b/tests/auto/gui/text/qstatictext/qstatictext.pro
@@ -5,4 +5,3 @@ TARGET = tst_qstatictext
QT += testlib
QT += core core-private gui gui-private
SOURCES += tst_qstatictext.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qstatictext/tst_qstatictext.cpp b/tests/auto/gui/text/qstatictext/tst_qstatictext.cpp
index f62e5f188b..46f97840af 100644
--- a/tests/auto/gui/text/qstatictext/tst_qstatictext.cpp
+++ b/tests/auto/gui/text/qstatictext/tst_qstatictext.cpp
@@ -224,7 +224,7 @@ void tst_QStaticText::drawToRect()
#endif
QVERIFY(imageDrawText.toImage() != m_whiteSquare);
- QCOMPARE(imageDrawStaticText, imageDrawText);
+ QCOMPARE(imageDrawStaticText, imageDrawText);
}
void tst_QStaticText::prepareToCorrectData()
diff --git a/tests/auto/gui/text/qsyntaxhighlighter/qsyntaxhighlighter.pro b/tests/auto/gui/text/qsyntaxhighlighter/qsyntaxhighlighter.pro
index 24b58c7d3e..a8dd6437ba 100644
--- a/tests/auto/gui/text/qsyntaxhighlighter/qsyntaxhighlighter.pro
+++ b/tests/auto/gui/text/qsyntaxhighlighter/qsyntaxhighlighter.pro
@@ -4,4 +4,3 @@ TARGET = tst_qsyntaxhighlighter
SOURCES += tst_qsyntaxhighlighter.cpp
QT += testlib
qtHaveModule(widgets) QT += widgets
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qsyntaxhighlighter/tst_qsyntaxhighlighter.cpp b/tests/auto/gui/text/qsyntaxhighlighter/tst_qsyntaxhighlighter.cpp
index fa2a2985f0..5484c9ed93 100644
--- a/tests/auto/gui/text/qsyntaxhighlighter/tst_qsyntaxhighlighter.cpp
+++ b/tests/auto/gui/text/qsyntaxhighlighter/tst_qsyntaxhighlighter.cpp
@@ -527,26 +527,26 @@ void tst_QSyntaxHighlighter::rehighlight()
void tst_QSyntaxHighlighter::rehighlightBlock()
{
TestHighlighter *hl = new TestHighlighter(doc);
-
+
cursor.movePosition(QTextCursor::Start);
cursor.beginEditBlock();
cursor.insertText("Hello");
cursor.insertBlock();
cursor.insertText("World");
cursor.endEditBlock();
-
+
hl->callCount = 0;
hl->highlightedText.clear();
QTextBlock block = doc->begin();
hl->rehighlightBlock(block);
-
+
QCOMPARE(hl->highlightedText, QString("Hello"));
QCOMPARE(hl->callCount, 1);
-
+
hl->callCount = 0;
hl->highlightedText.clear();
hl->rehighlightBlock(block.next());
-
+
QCOMPARE(hl->highlightedText, QString("World"));
QCOMPARE(hl->callCount, 1);
}
diff --git a/tests/auto/gui/text/qtextblock/qtextblock.pro b/tests/auto/gui/text/qtextblock/qtextblock.pro
index ebf992469e..6048361f7a 100644
--- a/tests/auto/gui/text/qtextblock/qtextblock.pro
+++ b/tests/auto/gui/text/qtextblock/qtextblock.pro
@@ -9,4 +9,3 @@ SOURCES += tst_qtextblock.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextcursor/qtextcursor.pro b/tests/auto/gui/text/qtextcursor/qtextcursor.pro
index 278cf91cc8..5e045404f1 100644
--- a/tests/auto/gui/text/qtextcursor/qtextcursor.pro
+++ b/tests/auto/gui/text/qtextcursor/qtextcursor.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qtextcursor
SOURCES += tst_qtextcursor.cpp
QT += testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextdocument/qtextdocument.pro b/tests/auto/gui/text/qtextdocument/qtextdocument.pro
index c995fee678..1f06e297f2 100644
--- a/tests/auto/gui/text/qtextdocument/qtextdocument.pro
+++ b/tests/auto/gui/text/qtextdocument/qtextdocument.pro
@@ -5,4 +5,3 @@ HEADERS += common.h
SOURCES += tst_qtextdocument.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextdocumentfragment/qtextdocumentfragment.pro b/tests/auto/gui/text/qtextdocumentfragment/qtextdocumentfragment.pro
index 5aee639da6..da8d120c69 100644
--- a/tests/auto/gui/text/qtextdocumentfragment/qtextdocumentfragment.pro
+++ b/tests/auto/gui/text/qtextdocumentfragment/qtextdocumentfragment.pro
@@ -7,4 +7,3 @@ SOURCES += tst_qtextdocumentfragment.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextdocumentlayout/qtextdocumentlayout.pro b/tests/auto/gui/text/qtextdocumentlayout/qtextdocumentlayout.pro
index 76dd370a8d..42c6406fdb 100644
--- a/tests/auto/gui/text/qtextdocumentlayout/qtextdocumentlayout.pro
+++ b/tests/auto/gui/text/qtextdocumentlayout/qtextdocumentlayout.pro
@@ -6,4 +6,3 @@ qtHaveModule(widgets) QT += widgets
SOURCES += tst_qtextdocumentlayout.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextformat/qtextformat.pro b/tests/auto/gui/text/qtextformat/qtextformat.pro
index 4689ecb982..b137dac9eb 100644
--- a/tests/auto/gui/text/qtextformat/qtextformat.pro
+++ b/tests/auto/gui/text/qtextformat/qtextformat.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qtextformat
QT += testlib
SOURCES += tst_qtextformat.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextformat/tst_qtextformat.cpp b/tests/auto/gui/text/qtextformat/tst_qtextformat.cpp
index f7b4456c43..1eb073d3b4 100644
--- a/tests/auto/gui/text/qtextformat/tst_qtextformat.cpp
+++ b/tests/auto/gui/text/qtextformat/tst_qtextformat.cpp
@@ -72,7 +72,7 @@ private slots:
/*! \internal
This (used to) trigger a crash in:
-
+
QDataStream &operator>>(QDataStream &stream, QTextFormat &fmt)
which is most easily produced through QSettings.
diff --git a/tests/auto/gui/text/qtextlayout/qtextlayout.pro b/tests/auto/gui/text/qtextlayout/qtextlayout.pro
index 9833a5bd1a..1e67626d23 100644
--- a/tests/auto/gui/text/qtextlayout/qtextlayout.pro
+++ b/tests/auto/gui/text/qtextlayout/qtextlayout.pro
@@ -3,5 +3,3 @@ TARGET = tst_qtextlayout
QT += core-private gui-private testlib
HEADERS +=
SOURCES += tst_qtextlayout.cpp
-DEFINES += QT_COMPILES_IN_HARFBUZZ
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextlist/qtextlist.pro b/tests/auto/gui/text/qtextlist/qtextlist.pro
index ef33e182c0..b837f1f81b 100644
--- a/tests/auto/gui/text/qtextlist/qtextlist.pro
+++ b/tests/auto/gui/text/qtextlist/qtextlist.pro
@@ -9,4 +9,3 @@ HEADERS += ../qtextdocument/common.h
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextobject/qtextobject.pro b/tests/auto/gui/text/qtextobject/qtextobject.pro
index ebeba2a64a..b2bf793e8e 100644
--- a/tests/auto/gui/text/qtextobject/qtextobject.pro
+++ b/tests/auto/gui/text/qtextobject/qtextobject.pro
@@ -10,4 +10,3 @@ qtHaveModule(widgets): QT += widgets
SOURCES += tst_qtextobject.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextodfwriter/qtextodfwriter.pro b/tests/auto/gui/text/qtextodfwriter/qtextodfwriter.pro
index afbf86cbfe..2c8bb39f6d 100644
--- a/tests/auto/gui/text/qtextodfwriter/qtextodfwriter.pro
+++ b/tests/auto/gui/text/qtextodfwriter/qtextodfwriter.pro
@@ -4,4 +4,3 @@ QT += core-private gui-private testlib
SOURCES += tst_qtextodfwriter.cpp
DEFINES += SRCDIR=\\\"$$PWD\\\"
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextpiecetable/qtextpiecetable.pro b/tests/auto/gui/text/qtextpiecetable/qtextpiecetable.pro
index 344d643201..1419e32012 100644
--- a/tests/auto/gui/text/qtextpiecetable/qtextpiecetable.pro
+++ b/tests/auto/gui/text/qtextpiecetable/qtextpiecetable.pro
@@ -8,4 +8,3 @@ HEADERS += ../qtextdocument/common.h
requires(!win32)
requires(contains(QT_CONFIG,private_tests))
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextscriptengine/generate/generate.pro b/tests/auto/gui/text/qtextscriptengine/generate/generate.pro
index bd85c108c2..6de4910107 100644
--- a/tests/auto/gui/text/qtextscriptengine/generate/generate.pro
+++ b/tests/auto/gui/text/qtextscriptengine/generate/generate.pro
@@ -1,6 +1,5 @@
CONFIG -= moc
-QT += core-private # for harfbuzz
+QT += core-private
INCLUDEPATH += . /usr/include/freetype2
SOURCES += main.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextscriptengine/generate/main.cpp b/tests/auto/gui/text/qtextscriptengine/generate/main.cpp
index 1dcdc28d81..f3fa42ec2e 100644
--- a/tests/auto/gui/text/qtextscriptengine/generate/main.cpp
+++ b/tests/auto/gui/text/qtextscriptengine/generate/main.cpp
@@ -81,7 +81,7 @@ void MyEdit::setText(const QString &str)
result = "Using font '" + e->fontEngine(e->layoutData->items[0])->fontDef.family + "'\n\n";
result += "{ { ";
- for (int i = 0; i < str.length(); ++i)
+ for (int i = 0; i < str.length(); ++i)
result += "0x" + QString::number(str.at(i).unicode(), 16) + ", ";
result += "0x0 },\n { ";
for (int i = 0; i < e->layoutData->items[0].num_glyphs; ++i)
diff --git a/tests/auto/gui/text/qtextscriptengine/qtextscriptengine.pro b/tests/auto/gui/text/qtextscriptengine/qtextscriptengine.pro
index e355a90e5c..2179fcbdf8 100644
--- a/tests/auto/gui/text/qtextscriptengine/qtextscriptengine.pro
+++ b/tests/auto/gui/text/qtextscriptengine/qtextscriptengine.pro
@@ -6,4 +6,3 @@ QT += core-private gui-private testlib
HEADERS +=
SOURCES += tst_qtextscriptengine.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qtextscriptengine/tst_qtextscriptengine.cpp b/tests/auto/gui/text/qtextscriptengine/tst_qtextscriptengine.cpp
index a6da20cc2b..eebac28323 100644
--- a/tests/auto/gui/text/qtextscriptengine/tst_qtextscriptengine.cpp
+++ b/tests/auto/gui/text/qtextscriptengine/tst_qtextscriptengine.cpp
@@ -48,7 +48,7 @@
class tst_QTextScriptEngine : public QObject
{
-Q_OBJECT
+ Q_OBJECT
public:
tst_QTextScriptEngine();
@@ -210,93 +210,93 @@ void tst_QTextScriptEngine::devanagari_data()
{
if (QFontDatabase().families(QFontDatabase::Devanagari).contains("Raghindi")) {
QFont f("Raghindi");
- const ShapeTable shape_table [] = {
- // Ka
- { { 0x0915, 0x0 },
- { 0x0080, 0x0 } },
- // Ka Halant
- { { 0x0915, 0x094d, 0x0 },
- { 0x0080, 0x0051, 0x0 } },
- // Ka Halant Ka
- { { 0x0915, 0x094d, 0x0915, 0x0 },
- { 0x00c8, 0x0080, 0x0 } },
- // Ka MatraI
- { { 0x0915, 0x093f, 0x0 },
- { 0x01d1, 0x0080, 0x0 } },
- // Ra Halant Ka
- { { 0x0930, 0x094d, 0x0915, 0x0 },
- { 0x0080, 0x005b, 0x0 } },
- // Ra Halant Ka MatraI
- { { 0x0930, 0x094d, 0x0915, 0x093f, 0x0 },
- { 0x01d1, 0x0080, 0x005b, 0x0 } },
- // MatraI
- { { 0x093f, 0x0 },
- { 0x01d4, 0x029c, 0x0 } },
- // Ka Nukta
- { { 0x0915, 0x093c, 0x0 },
- { 0x00a4, 0x0 } },
- // Ka Halant Ra
- { { 0x0915, 0x094d, 0x0930, 0x0 },
- { 0x0110, 0x0 } },
- // Ka Halant Ra Halant Ka
- { { 0x0915, 0x094d, 0x0930, 0x094d, 0x0915, 0x0 },
- { 0x0158, 0x0080, 0x0 } },
- { { 0x0930, 0x094d, 0x200d, 0x0 },
- { 0x00e2, 0x0 } },
- { { 0x0915, 0x094d, 0x0930, 0x094d, 0x200d, 0x0 },
- { 0x0158, 0x0 } },
-
- { {0}, {0} }
- };
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find Raghindi");
+ const ShapeTable shape_table [] = {
+ // Ka
+ { { 0x0915, 0x0 },
+ { 0x0080, 0x0 } },
+ // Ka Halant
+ { { 0x0915, 0x094d, 0x0 },
+ { 0x0080, 0x0051, 0x0 } },
+ // Ka Halant Ka
+ { { 0x0915, 0x094d, 0x0915, 0x0 },
+ { 0x00c8, 0x0080, 0x0 } },
+ // Ka MatraI
+ { { 0x0915, 0x093f, 0x0 },
+ { 0x01d1, 0x0080, 0x0 } },
+ // Ra Halant Ka
+ { { 0x0930, 0x094d, 0x0915, 0x0 },
+ { 0x0080, 0x005b, 0x0 } },
+ // Ra Halant Ka MatraI
+ { { 0x0930, 0x094d, 0x0915, 0x093f, 0x0 },
+ { 0x01d1, 0x0080, 0x005b, 0x0 } },
+ // MatraI
+ { { 0x093f, 0x0 },
+ { 0x01d4, 0x029c, 0x0 } },
+ // Ka Nukta
+ { { 0x0915, 0x093c, 0x0 },
+ { 0x00a4, 0x0 } },
+ // Ka Halant Ra
+ { { 0x0915, 0x094d, 0x0930, 0x0 },
+ { 0x0110, 0x0 } },
+ // Ka Halant Ra Halant Ka
+ { { 0x0915, 0x094d, 0x0930, 0x094d, 0x0915, 0x0 },
+ { 0x0158, 0x0080, 0x0 } },
+ { { 0x0930, 0x094d, 0x200d, 0x0 },
+ { 0x00e2, 0x0 } },
+ { { 0x0915, 0x094d, 0x0930, 0x094d, 0x200d, 0x0 },
+ { 0x0158, 0x0 } },
+
+ { {0}, {0} }
+ };
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find Raghindi");
}
{
if (QFontDatabase().families(QFontDatabase::Devanagari).contains("Mangal")) {
QFont f("Mangal");
- const ShapeTable shape_table [] = {
- // Ka
- { { 0x0915, 0x0 },
- { 0x0080, 0x0 } },
- // Ka Halant
- { { 0x0915, 0x094d, 0x0 },
- { 0x0080, 0x0051, 0x0 } },
- // Ka Halant Ka
- { { 0x0915, 0x094d, 0x0915, 0x0 },
- { 0x00c8, 0x0080, 0x0 } },
- // Ka MatraI
- { { 0x0915, 0x093f, 0x0 },
- { 0x01d1, 0x0080, 0x0 } },
- // Ra Halant Ka
- { { 0x0930, 0x094d, 0x0915, 0x0 },
- { 0x0080, 0x005b, 0x0 } },
- // Ra Halant Ka MatraI
- { { 0x0930, 0x094d, 0x0915, 0x093f, 0x0 },
- { 0x01d1, 0x0080, 0x005b, 0x0 } },
- // MatraI
- { { 0x093f, 0x0 },
- { 0x01d4, 0x029c, 0x0 } },
- // Ka Nukta
- { { 0x0915, 0x093c, 0x0 },
- { 0x00a4, 0x0 } },
- // Ka Halant Ra
- { { 0x0915, 0x094d, 0x0930, 0x0 },
- { 0x0110, 0x0 } },
- // Ka Halant Ra Halant Ka
- { { 0x0915, 0x094d, 0x0930, 0x094d, 0x0915, 0x0 },
- { 0x0158, 0x0080, 0x0 } },
+ const ShapeTable shape_table [] = {
+ // Ka
+ { { 0x0915, 0x0 },
+ { 0x0080, 0x0 } },
+ // Ka Halant
+ { { 0x0915, 0x094d, 0x0 },
+ { 0x0080, 0x0051, 0x0 } },
+ // Ka Halant Ka
+ { { 0x0915, 0x094d, 0x0915, 0x0 },
+ { 0x00c8, 0x0080, 0x0 } },
+ // Ka MatraI
+ { { 0x0915, 0x093f, 0x0 },
+ { 0x01d1, 0x0080, 0x0 } },
+ // Ra Halant Ka
+ { { 0x0930, 0x094d, 0x0915, 0x0 },
+ { 0x0080, 0x005b, 0x0 } },
+ // Ra Halant Ka MatraI
+ { { 0x0930, 0x094d, 0x0915, 0x093f, 0x0 },
+ { 0x01d1, 0x0080, 0x005b, 0x0 } },
+ // MatraI
+ { { 0x093f, 0x0 },
+ { 0x01d4, 0x029c, 0x0 } },
+ // Ka Nukta
+ { { 0x0915, 0x093c, 0x0 },
+ { 0x00a4, 0x0 } },
+ // Ka Halant Ra
+ { { 0x0915, 0x094d, 0x0930, 0x0 },
+ { 0x0110, 0x0 } },
+ // Ka Halant Ra Halant Ka
+ { { 0x0915, 0x094d, 0x0930, 0x094d, 0x0915, 0x0 },
+ { 0x0158, 0x0080, 0x0 } },
{ { 0x92b, 0x94d, 0x930, 0x0 },
{ 0x125, 0x0 } },
{ { 0x92b, 0x93c, 0x94d, 0x930, 0x0 },
- { 0x149, 0x0 } },
- { {0}, {0} }
- };
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find mangal");
+ { 0x149, 0x0 } },
+ { {0}, {0} }
+ };
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find mangal");
}
}
@@ -317,224 +317,224 @@ void tst_QTextScriptEngine::bengali_data()
{
if (QFontDatabase().families(QFontDatabase::Bengali).contains("Akaash")) {
QFont f("Akaash");
- const ShapeTable shape_table [] = {
- // Ka
- { { 0x0995, 0x0 },
- { 0x0151, 0x0 } },
- // Ka Halant
- { { 0x0995, 0x09cd, 0x0 },
- { 0x0151, 0x017d, 0x0 } },
- // Ka Halant Ka
- { { 0x0995, 0x09cd, 0x0995, 0x0 },
- { 0x019b, 0x0 } },
- // Ka MatraI
- { { 0x0995, 0x09bf, 0x0 },
- { 0x0173, 0x0151, 0x0 } },
- // Ra Halant Ka
- { { 0x09b0, 0x09cd, 0x0995, 0x0 },
- { 0x0151, 0x0276, 0x0 } },
- // Ra Halant Ka MatraI
- { { 0x09b0, 0x09cd, 0x0995, 0x09bf, 0x0 },
- { 0x0173, 0x0151, 0x0276, 0x0 } },
- // Ka Nukta
- { { 0x0995, 0x09bc, 0x0 },
- { 0x0151, 0x0171, 0x0 } },
- // Ka Halant Ra
- { { 0x0995, 0x09cd, 0x09b0, 0x0 },
- { 0x01f4, 0x0 } },
- // Ka Halant Ra Halant Ka
- { { 0x0995, 0x09cd, 0x09b0, 0x09cd, 0x0995, 0x0 },
- { 0x025c, 0x0276, 0x0151, 0x0 } },
- // Ya + Halant
- { { 0x09af, 0x09cd, 0x0 },
- { 0x016a, 0x017d, 0x0 } },
- // Da Halant Ya -> Da Ya-Phala
- { { 0x09a6, 0x09cd, 0x09af, 0x0 },
- { 0x01e5, 0x0 } },
- // A Halant Ya -> A Ya-phala
- { { 0x0985, 0x09cd, 0x09af, 0x0 },
- { 0x0145, 0x01cf, 0x0 } },
- // Na Halant Ka
- { { 0x09a8, 0x09cd, 0x0995, 0x0 },
- { 0x026f, 0x0151, 0x0 } },
- // Na Halant ZWNJ Ka
- { { 0x09a8, 0x09cd, 0x200c, 0x0995, 0x0 },
- { 0x0164, 0x017d, 0x0151, 0x0 } },
- // Na Halant ZWJ Ka
- { { 0x09a8, 0x09cd, 0x200d, 0x0995, 0x0 },
- { 0x026f, 0x0151, 0x0 } },
- // Ka Halant ZWNJ Ka
- { { 0x0995, 0x09cd, 0x200c, 0x0995, 0x0 },
- { 0x0151, 0x017d, 0x0151, 0x0 } },
- // Ka Halant ZWJ Ka
- { { 0x0995, 0x09cd, 0x200d, 0x0995, 0x0 },
- { 0x025c, 0x0151, 0x0 } },
- // Na Halant Ra
- { { 0x09a8, 0x09cd, 0x09b0, 0x0 },
- { 0x0207, 0x0 } },
- // Na Halant ZWNJ Ra
- { { 0x09a8, 0x09cd, 0x200c, 0x09b0, 0x0 },
- { 0x0164, 0x017d, 0x016b, 0x0 } },
- // Na Halant ZWJ Ra
- { { 0x09a8, 0x09cd, 0x200d, 0x09b0, 0x0 },
- { 0x026f, 0x016b, 0x0 } },
- // Na Halant Ba
- { { 0x09a8, 0x09cd, 0x09ac, 0x0 },
- { 0x022f, 0x0 } },
- // Na Halant ZWNJ Ba
- { { 0x09a8, 0x09cd, 0x200c, 0x09ac, 0x0 },
- { 0x0164, 0x017d, 0x0167, 0x0 } },
- // Na Halant ZWJ Ba
- { { 0x09a8, 0x09cd, 0x200d, 0x09ac, 0x0 },
- { 0x026f, 0x0167, 0x0 } },
- // Na Halant Dha
- { { 0x09a8, 0x09cd, 0x09a7, 0x0 },
- { 0x01d3, 0x0 } },
- // Na Halant ZWNJ Dha
- { { 0x09a8, 0x09cd, 0x200c, 0x09a7, 0x0 },
- { 0x0164, 0x017d, 0x0163, 0x0 } },
- // Na Halant ZWJ Dha
- { { 0x09a8, 0x09cd, 0x200d, 0x09a7, 0x0 },
- { 0x026f, 0x0163, 0x0 } },
- // Ra Halant Ka MatraAU
- { { 0x09b0, 0x09cd, 0x0995, 0x09cc, 0x0 },
- { 0x0179, 0x0151, 0x0276, 0x017e, 0x0 } },
- // Ra Halant Ba Halant Ba
- { { 0x09b0, 0x09cd, 0x09ac, 0x09cd, 0x09ac, 0x0 },
- { 0x0232, 0x0276, 0x0 } },
+ const ShapeTable shape_table [] = {
+ // Ka
+ { { 0x0995, 0x0 },
+ { 0x0151, 0x0 } },
+ // Ka Halant
+ { { 0x0995, 0x09cd, 0x0 },
+ { 0x0151, 0x017d, 0x0 } },
+ // Ka Halant Ka
+ { { 0x0995, 0x09cd, 0x0995, 0x0 },
+ { 0x019b, 0x0 } },
+ // Ka MatraI
+ { { 0x0995, 0x09bf, 0x0 },
+ { 0x0173, 0x0151, 0x0 } },
+ // Ra Halant Ka
+ { { 0x09b0, 0x09cd, 0x0995, 0x0 },
+ { 0x0151, 0x0276, 0x0 } },
+ // Ra Halant Ka MatraI
+ { { 0x09b0, 0x09cd, 0x0995, 0x09bf, 0x0 },
+ { 0x0173, 0x0151, 0x0276, 0x0 } },
+ // Ka Nukta
+ { { 0x0995, 0x09bc, 0x0 },
+ { 0x0151, 0x0171, 0x0 } },
+ // Ka Halant Ra
+ { { 0x0995, 0x09cd, 0x09b0, 0x0 },
+ { 0x01f4, 0x0 } },
+ // Ka Halant Ra Halant Ka
+ { { 0x0995, 0x09cd, 0x09b0, 0x09cd, 0x0995, 0x0 },
+ { 0x025c, 0x0276, 0x0151, 0x0 } },
+ // Ya + Halant
+ { { 0x09af, 0x09cd, 0x0 },
+ { 0x016a, 0x017d, 0x0 } },
+ // Da Halant Ya -> Da Ya-Phala
+ { { 0x09a6, 0x09cd, 0x09af, 0x0 },
+ { 0x01e5, 0x0 } },
+ // A Halant Ya -> A Ya-phala
+ { { 0x0985, 0x09cd, 0x09af, 0x0 },
+ { 0x0145, 0x01cf, 0x0 } },
+ // Na Halant Ka
+ { { 0x09a8, 0x09cd, 0x0995, 0x0 },
+ { 0x026f, 0x0151, 0x0 } },
+ // Na Halant ZWNJ Ka
+ { { 0x09a8, 0x09cd, 0x200c, 0x0995, 0x0 },
+ { 0x0164, 0x017d, 0x0151, 0x0 } },
+ // Na Halant ZWJ Ka
+ { { 0x09a8, 0x09cd, 0x200d, 0x0995, 0x0 },
+ { 0x026f, 0x0151, 0x0 } },
+ // Ka Halant ZWNJ Ka
+ { { 0x0995, 0x09cd, 0x200c, 0x0995, 0x0 },
+ { 0x0151, 0x017d, 0x0151, 0x0 } },
+ // Ka Halant ZWJ Ka
+ { { 0x0995, 0x09cd, 0x200d, 0x0995, 0x0 },
+ { 0x025c, 0x0151, 0x0 } },
+ // Na Halant Ra
+ { { 0x09a8, 0x09cd, 0x09b0, 0x0 },
+ { 0x0207, 0x0 } },
+ // Na Halant ZWNJ Ra
+ { { 0x09a8, 0x09cd, 0x200c, 0x09b0, 0x0 },
+ { 0x0164, 0x017d, 0x016b, 0x0 } },
+ // Na Halant ZWJ Ra
+ { { 0x09a8, 0x09cd, 0x200d, 0x09b0, 0x0 },
+ { 0x026f, 0x016b, 0x0 } },
+ // Na Halant Ba
+ { { 0x09a8, 0x09cd, 0x09ac, 0x0 },
+ { 0x022f, 0x0 } },
+ // Na Halant ZWNJ Ba
+ { { 0x09a8, 0x09cd, 0x200c, 0x09ac, 0x0 },
+ { 0x0164, 0x017d, 0x0167, 0x0 } },
+ // Na Halant ZWJ Ba
+ { { 0x09a8, 0x09cd, 0x200d, 0x09ac, 0x0 },
+ { 0x026f, 0x0167, 0x0 } },
+ // Na Halant Dha
+ { { 0x09a8, 0x09cd, 0x09a7, 0x0 },
+ { 0x01d3, 0x0 } },
+ // Na Halant ZWNJ Dha
+ { { 0x09a8, 0x09cd, 0x200c, 0x09a7, 0x0 },
+ { 0x0164, 0x017d, 0x0163, 0x0 } },
+ // Na Halant ZWJ Dha
+ { { 0x09a8, 0x09cd, 0x200d, 0x09a7, 0x0 },
+ { 0x026f, 0x0163, 0x0 } },
+ // Ra Halant Ka MatraAU
+ { { 0x09b0, 0x09cd, 0x0995, 0x09cc, 0x0 },
+ { 0x0179, 0x0151, 0x0276, 0x017e, 0x0 } },
+ // Ra Halant Ba Halant Ba
+ { { 0x09b0, 0x09cd, 0x09ac, 0x09cd, 0x09ac, 0x0 },
+ { 0x0232, 0x0276, 0x0 } },
{ { 0x9b0, 0x9cd, 0x995, 0x9be, 0x982, 0x0 },
{ 0x151, 0x276, 0x172, 0x143, 0x0 } },
{ { 0x9b0, 0x9cd, 0x995, 0x9be, 0x983, 0x0 },
- { 0x151, 0x276, 0x172, 0x144, 0x0 } },
+ { 0x151, 0x276, 0x172, 0x144, 0x0 } },
// test decomposed two parts matras
{ { 0x995, 0x9c7, 0x9be, 0x0 },
{ 0x179, 0x151, 0x172, 0x0 } },
{ { 0x995, 0x9c7, 0x9d7, 0x0 },
{ 0x179, 0x151, 0x17e, 0x0 } },
- { {0}, {0} }
- };
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find Akaash");
+ { {0}, {0} }
+ };
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find Akaash");
}
{
if (QFontDatabase().families(QFontDatabase::Bengali).contains("Mukti Narrow")) {
QFont f("Mukti Narrow");
- const ShapeTable shape_table [] = {
- // Ka
- { { 0x0995, 0x0 },
- { 0x0073, 0x0 } },
- // Ka Halant
- { { 0x0995, 0x09cd, 0x0 },
- { 0x00b9, 0x0 } },
- // Ka Halant Ka
- { { 0x0995, 0x09cd, 0x0995, 0x0 },
- { 0x0109, 0x0 } },
- // Ka MatraI
- { { 0x0995, 0x09bf, 0x0 },
- { 0x0095, 0x0073, 0x0 } },
- // Ra Halant Ka
- { { 0x09b0, 0x09cd, 0x0995, 0x0 },
- { 0x0073, 0x00e1, 0x0 } },
- // Ra Halant Ka MatraI
- { { 0x09b0, 0x09cd, 0x0995, 0x09bf, 0x0 },
- { 0x0095, 0x0073, 0x00e1, 0x0 } },
- // MatraI
- { { 0x09bf, 0x0 },
- { 0x0095, 0x01c8, 0x0 } },
- // Ka Nukta
- { { 0x0995, 0x09bc, 0x0 },
- { 0x0073, 0x0093, 0x0 } },
- // Ka Halant Ra
- { { 0x0995, 0x09cd, 0x09b0, 0x0 },
- { 0x00e5, 0x0 } },
- // Ka Halant Ra Halant Ka
+ const ShapeTable shape_table [] = {
+ // Ka
+ { { 0x0995, 0x0 },
+ { 0x0073, 0x0 } },
+ // Ka Halant
+ { { 0x0995, 0x09cd, 0x0 },
+ { 0x00b9, 0x0 } },
+ // Ka Halant Ka
+ { { 0x0995, 0x09cd, 0x0995, 0x0 },
+ { 0x0109, 0x0 } },
+ // Ka MatraI
+ { { 0x0995, 0x09bf, 0x0 },
+ { 0x0095, 0x0073, 0x0 } },
+ // Ra Halant Ka
+ { { 0x09b0, 0x09cd, 0x0995, 0x0 },
+ { 0x0073, 0x00e1, 0x0 } },
+ // Ra Halant Ka MatraI
+ { { 0x09b0, 0x09cd, 0x0995, 0x09bf, 0x0 },
+ { 0x0095, 0x0073, 0x00e1, 0x0 } },
+ // MatraI
+ { { 0x09bf, 0x0 },
+ { 0x0095, 0x01c8, 0x0 } },
+ // Ka Nukta
+ { { 0x0995, 0x09bc, 0x0 },
+ { 0x0073, 0x0093, 0x0 } },
+ // Ka Halant Ra
+ { { 0x0995, 0x09cd, 0x09b0, 0x0 },
+ { 0x00e5, 0x0 } },
+ // Ka Halant Ra Halant Ka
{ { 0x995, 0x9cd, 0x9b0, 0x9cd, 0x995, 0x0 },
- { 0x234, 0x24e, 0x73, 0x0 } },
- // Ya + Halant
- { { 0x09af, 0x09cd, 0x0 },
- { 0x00d2, 0x0 } },
- // Da Halant Ya -> Da Ya-Phala
- { { 0x09a6, 0x09cd, 0x09af, 0x0 },
- { 0x0084, 0x00e2, 0x0 } },
- // A Halant Ya -> A Ya-phala
- { { 0x0985, 0x09cd, 0x09af, 0x0 },
- { 0x0067, 0x00e2, 0x0 } },
- // Na Halant Ka
- { { 0x09a8, 0x09cd, 0x0995, 0x0 },
- { 0x0188, 0x0 } },
- // Na Halant ZWNJ Ka
+ { 0x234, 0x24e, 0x73, 0x0 } },
+ // Ya + Halant
+ { { 0x09af, 0x09cd, 0x0 },
+ { 0x00d2, 0x0 } },
+ // Da Halant Ya -> Da Ya-Phala
+ { { 0x09a6, 0x09cd, 0x09af, 0x0 },
+ { 0x0084, 0x00e2, 0x0 } },
+ // A Halant Ya -> A Ya-phala
+ { { 0x0985, 0x09cd, 0x09af, 0x0 },
+ { 0x0067, 0x00e2, 0x0 } },
+ // Na Halant Ka
+ { { 0x09a8, 0x09cd, 0x0995, 0x0 },
+ { 0x0188, 0x0 } },
+ // Na Halant ZWNJ Ka
{ { 0x9a8, 0x9cd, 0x200c, 0x995, 0x0 },
- { 0xcc, 0x73, 0x0 } },
- // Na Halant ZWJ Ka
+ { 0xcc, 0x73, 0x0 } },
+ // Na Halant ZWJ Ka
{ { 0x9a8, 0x9cd, 0x200d, 0x995, 0x0 },
- { 0x247, 0x73, 0x0 } },
- // Ka Halant ZWNJ Ka
+ { 0x247, 0x73, 0x0 } },
+ // Ka Halant ZWNJ Ka
{ { 0x9a8, 0x9cd, 0x200d, 0x995, 0x0 },
- { 0x247, 0x73, 0x0 } },
- // Ka Halant ZWJ Ka
+ { 0x247, 0x73, 0x0 } },
+ // Ka Halant ZWJ Ka
{ { 0x9a8, 0x9cd, 0x200d, 0x995, 0x0 },
- { 0x247, 0x73, 0x0 } },
- // Na Halant Ra
- { { 0x09a8, 0x09cd, 0x09b0, 0x0 },
- { 0x00f8, 0x0 } },
- // Na Halant ZWNJ Ra
- { { 0x09a8, 0x09cd, 0x200c, 0x09b0, 0x0 },
- { 0xcc, 0x8d, 0x0 } },
- // Na Halant ZWJ Ra
+ { 0x247, 0x73, 0x0 } },
+ // Na Halant Ra
+ { { 0x09a8, 0x09cd, 0x09b0, 0x0 },
+ { 0x00f8, 0x0 } },
+ // Na Halant ZWNJ Ra
+ { { 0x09a8, 0x09cd, 0x200c, 0x09b0, 0x0 },
+ { 0xcc, 0x8d, 0x0 } },
+ // Na Halant ZWJ Ra
{ { 0x9a8, 0x9cd, 0x200d, 0x9b0, 0x0 },
- { 0x247, 0x8d, 0x0 } },
- // Na Halant Ba
- { { 0x09a8, 0x09cd, 0x09ac, 0x0 },
- { 0x0139, 0x0 } },
- // Na Halant ZWNJ Ba
+ { 0x247, 0x8d, 0x0 } },
+ // Na Halant Ba
+ { { 0x09a8, 0x09cd, 0x09ac, 0x0 },
+ { 0x0139, 0x0 } },
+ // Na Halant ZWNJ Ba
{ { 0x9a8, 0x9cd, 0x200c, 0x9ac, 0x0 },
- { 0xcc, 0x89, 0x0 } },
- // Na Halant ZWJ Ba
+ { 0xcc, 0x89, 0x0 } },
+ // Na Halant ZWJ Ba
{ { 0x9a8, 0x9cd, 0x200d, 0x9ac, 0x0 },
- { 0x247, 0x89, 0x0 } },
- // Na Halant Dha
- { { 0x09a8, 0x09cd, 0x09a7, 0x0 },
- { 0x0145, 0x0 } },
- // Na Halant ZWNJ Dha
- { { 0x09a8, 0x09cd, 0x200c, 0x09a7, 0x0 },
- { 0xcc, 0x85, 0x0 } },
- // Na Halant ZWJ Dha
- { { 0x09a8, 0x09cd, 0x200d, 0x09a7, 0x0 },
- { 0x247, 0x85, 0x0 } },
- // Ra Halant Ka MatraAU
+ { 0x247, 0x89, 0x0 } },
+ // Na Halant Dha
+ { { 0x09a8, 0x09cd, 0x09a7, 0x0 },
+ { 0x0145, 0x0 } },
+ // Na Halant ZWNJ Dha
+ { { 0x09a8, 0x09cd, 0x200c, 0x09a7, 0x0 },
+ { 0xcc, 0x85, 0x0 } },
+ // Na Halant ZWJ Dha
+ { { 0x09a8, 0x09cd, 0x200d, 0x09a7, 0x0 },
+ { 0x247, 0x85, 0x0 } },
+ // Ra Halant Ka MatraAU
{ { 0x9b0, 0x9cd, 0x995, 0x9cc, 0x0 },
- { 0x232, 0x73, 0xe1, 0xa0, 0x0 } },
- // Ra Halant Ba Halant Ba
- { { 0x09b0, 0x09cd, 0x09ac, 0x09cd, 0x09ac, 0x0 },
- { 0x013b, 0x00e1, 0x0 } },
-
- { {0}, {0} }
- };
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find Mukti");
+ { 0x232, 0x73, 0xe1, 0xa0, 0x0 } },
+ // Ra Halant Ba Halant Ba
+ { { 0x09b0, 0x09cd, 0x09ac, 0x09cd, 0x09ac, 0x0 },
+ { 0x013b, 0x00e1, 0x0 } },
+
+ { {0}, {0} }
+ };
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find Mukti");
}
{
if (QFontDatabase().families(QFontDatabase::Bengali).contains("Likhan")) {
QFont f("Likhan");
- const ShapeTable shape_table [] = {
+ const ShapeTable shape_table [] = {
{ { 0x9a8, 0x9cd, 0x9af, 0x0 },
{ 0x1ca, 0x0 } },
- { { 0x09b8, 0x09cd, 0x09af, 0x0 },
+ { { 0x09b8, 0x09cd, 0x09af, 0x0 },
{ 0x020e, 0x0 } },
- { { 0x09b6, 0x09cd, 0x09af, 0x0 },
+ { { 0x09b6, 0x09cd, 0x09af, 0x0 },
{ 0x01f4, 0x0 } },
- { { 0x09b7, 0x09cd, 0x09af, 0x0 },
+ { { 0x09b7, 0x09cd, 0x09af, 0x0 },
{ 0x01fe, 0x0 } },
- { { 0x09b0, 0x09cd, 0x09a8, 0x09cd, 0x200d, 0x0 },
+ { { 0x09b0, 0x09cd, 0x09a8, 0x09cd, 0x200d, 0x0 },
{ 0x10b, 0x167, 0x0 } },
- { {0}, {0} }
- };
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find Likhan");
+ { {0}, {0} }
+ };
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find Likhan");
}
}
@@ -555,14 +555,14 @@ void tst_QTextScriptEngine::gurmukhi_data()
{
if (QFontDatabase().families(QFontDatabase::Gurmukhi).contains("Lohit Punjabi")) {
QFont f("Lohit Punjabi");
- const ShapeTable shape_table [] = {
- { { 0xA15, 0xA4D, 0xa39, 0x0 },
- { 0x3b, 0x8b, 0x0 } },
- { {0}, {0} }
- };
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find Lohit Punjabi");
+ const ShapeTable shape_table [] = {
+ { { 0xA15, 0xA4D, 0xa39, 0x0 },
+ { 0x3b, 0x8b, 0x0 } },
+ { {0}, {0} }
+ };
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find Lohit Punjabi");
}
}
@@ -583,27 +583,27 @@ void tst_QTextScriptEngine::oriya_data()
{
if (QFontDatabase().families(QFontDatabase::Oriya).contains("utkal")) {
QFont f("utkal");
- const ShapeTable shape_table [] = {
+ const ShapeTable shape_table [] = {
{ { 0xb15, 0xb4d, 0xb24, 0xb4d, 0xb30, 0x0 },
- { 0x150, 0x125, 0x0 } },
+ { 0x150, 0x125, 0x0 } },
{ { 0xb24, 0xb4d, 0xb24, 0xb4d, 0xb2c, 0x0 },
- { 0x151, 0x120, 0x0 } },
+ { 0x151, 0x120, 0x0 } },
{ { 0xb28, 0xb4d, 0xb24, 0xb4d, 0xb2c, 0x0 },
- { 0x152, 0x120, 0x0 } },
+ { 0x152, 0x120, 0x0 } },
{ { 0xb28, 0xb4d, 0xb24, 0xb4d, 0xb2c, 0x0 },
- { 0x152, 0x120, 0x0 } },
+ { 0x152, 0x120, 0x0 } },
{ { 0xb28, 0xb4d, 0xb24, 0xb4d, 0xb30, 0x0 },
- { 0x176, 0x0 } },
+ { 0x176, 0x0 } },
{ { 0xb38, 0xb4d, 0xb24, 0xb4d, 0xb30, 0x0 },
- { 0x177, 0x0 } },
+ { 0x177, 0x0 } },
{ { 0xb28, 0xb4d, 0xb24, 0xb4d, 0xb30, 0xb4d, 0xb2f, 0x0 },
- { 0x176, 0x124, 0x0 } },
+ { 0x176, 0x124, 0x0 } },
{ {0}, {0} }
};
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find utkal");
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find utkal");
}
}
@@ -624,51 +624,51 @@ void tst_QTextScriptEngine::tamil_data()
{
if (QFontDatabase().families(QFontDatabase::Tamil).contains("AkrutiTml1")) {
QFont f("AkrutiTml1");
- const ShapeTable shape_table [] = {
- { { 0x0b95, 0x0bc2, 0x0 },
- { 0x004e, 0x0 } },
- { { 0x0bae, 0x0bc2, 0x0 },
- { 0x009e, 0x0 } },
- { { 0x0b9a, 0x0bc2, 0x0 },
- { 0x0058, 0x0 } },
- { { 0x0b99, 0x0bc2, 0x0 },
- { 0x0053, 0x0 } },
- { { 0x0bb0, 0x0bc2, 0x0 },
- { 0x00a8, 0x0 } },
- { { 0x0ba4, 0x0bc2, 0x0 },
- { 0x008e, 0x0 } },
- { { 0x0b9f, 0x0bc2, 0x0 },
- { 0x0062, 0x0 } },
- { { 0x0b95, 0x0bc6, 0x0 },
- { 0x000a, 0x0031, 0x0 } },
- { { 0x0b95, 0x0bca, 0x0 },
- { 0x000a, 0x0031, 0x0007, 0x0 } },
- { { 0x0b95, 0x0bc6, 0x0bbe, 0x0 },
- { 0x000a, 0x0031, 0x007, 0x0 } },
- { { 0x0b95, 0x0bcd, 0x0bb7, 0x0 },
- { 0x0049, 0x0 } },
- { { 0x0b95, 0x0bcd, 0x0bb7, 0x0bca, 0x0 },
- { 0x000a, 0x0049, 0x007, 0x0 } },
- { { 0x0b95, 0x0bcd, 0x0bb7, 0x0bc6, 0x0bbe, 0x0 },
- { 0x000a, 0x0049, 0x007, 0x0 } },
- { { 0x0b9f, 0x0bbf, 0x0 },
- { 0x005f, 0x0 } },
- { { 0x0b9f, 0x0bc0, 0x0 },
- { 0x0060, 0x0 } },
- { { 0x0bb2, 0x0bc0, 0x0 },
- { 0x00ab, 0x0 } },
- { { 0x0bb2, 0x0bbf, 0x0 },
- { 0x00aa, 0x0 } },
- { { 0x0bb0, 0x0bcd, 0x0 },
- { 0x00a4, 0x0 } },
- { { 0x0bb0, 0x0bbf, 0x0 },
- { 0x00a5, 0x0 } },
- { { 0x0bb0, 0x0bc0, 0x0 },
- { 0x00a6, 0x0 } },
- { { 0x0b83, 0x0 },
- { 0x0025, 0x0 } },
- { { 0x0b83, 0x0b95, 0x0 },
- { 0x0025, 0x0031, 0x0 } },
+ const ShapeTable shape_table [] = {
+ { { 0x0b95, 0x0bc2, 0x0 },
+ { 0x004e, 0x0 } },
+ { { 0x0bae, 0x0bc2, 0x0 },
+ { 0x009e, 0x0 } },
+ { { 0x0b9a, 0x0bc2, 0x0 },
+ { 0x0058, 0x0 } },
+ { { 0x0b99, 0x0bc2, 0x0 },
+ { 0x0053, 0x0 } },
+ { { 0x0bb0, 0x0bc2, 0x0 },
+ { 0x00a8, 0x0 } },
+ { { 0x0ba4, 0x0bc2, 0x0 },
+ { 0x008e, 0x0 } },
+ { { 0x0b9f, 0x0bc2, 0x0 },
+ { 0x0062, 0x0 } },
+ { { 0x0b95, 0x0bc6, 0x0 },
+ { 0x000a, 0x0031, 0x0 } },
+ { { 0x0b95, 0x0bca, 0x0 },
+ { 0x000a, 0x0031, 0x0007, 0x0 } },
+ { { 0x0b95, 0x0bc6, 0x0bbe, 0x0 },
+ { 0x000a, 0x0031, 0x007, 0x0 } },
+ { { 0x0b95, 0x0bcd, 0x0bb7, 0x0 },
+ { 0x0049, 0x0 } },
+ { { 0x0b95, 0x0bcd, 0x0bb7, 0x0bca, 0x0 },
+ { 0x000a, 0x0049, 0x007, 0x0 } },
+ { { 0x0b95, 0x0bcd, 0x0bb7, 0x0bc6, 0x0bbe, 0x0 },
+ { 0x000a, 0x0049, 0x007, 0x0 } },
+ { { 0x0b9f, 0x0bbf, 0x0 },
+ { 0x005f, 0x0 } },
+ { { 0x0b9f, 0x0bc0, 0x0 },
+ { 0x0060, 0x0 } },
+ { { 0x0bb2, 0x0bc0, 0x0 },
+ { 0x00ab, 0x0 } },
+ { { 0x0bb2, 0x0bbf, 0x0 },
+ { 0x00aa, 0x0 } },
+ { { 0x0bb0, 0x0bcd, 0x0 },
+ { 0x00a4, 0x0 } },
+ { { 0x0bb0, 0x0bbf, 0x0 },
+ { 0x00a5, 0x0 } },
+ { { 0x0bb0, 0x0bc0, 0x0 },
+ { 0x00a6, 0x0 } },
+ { { 0x0b83, 0x0 },
+ { 0x0025, 0x0 } },
+ { { 0x0b83, 0x0b95, 0x0 },
+ { 0x0025, 0x0031, 0x0 } },
{ { 0xb95, 0xbc6, 0xbbe, 0x0 },
{ 0xa, 0x31, 0x7, 0x0 } },
{ { 0xb95, 0xbc7, 0xbbe, 0x0 },
@@ -676,11 +676,11 @@ void tst_QTextScriptEngine::tamil_data()
{ { 0xb95, 0xbc6, 0xbd7, 0x0 },
{ 0xa, 0x31, 0x40, 0x0 } },
- { {0}, {0} }
- };
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find AkrutiTml1");
+ { {0}, {0} }
+ };
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find AkrutiTml1");
}
}
@@ -701,35 +701,35 @@ void tst_QTextScriptEngine::telugu_data()
{
if (QFontDatabase().families(QFontDatabase::Telugu).contains("Pothana2000")) {
QFont f("Pothana2000");
- const ShapeTable shape_table [] = {
+ const ShapeTable shape_table [] = {
{ { 0xc15, 0xc4d, 0x0 },
- { 0xbb, 0x0 } },
+ { 0xbb, 0x0 } },
{ { 0xc15, 0xc4d, 0xc37, 0x0 },
- { 0x4b, 0x0 } },
+ { 0x4b, 0x0 } },
{ { 0xc15, 0xc4d, 0xc37, 0xc4d, 0x0 },
- { 0xe0, 0x0 } },
+ { 0xe0, 0x0 } },
{ { 0xc15, 0xc4d, 0xc37, 0xc4d, 0xc23, 0x0 },
- { 0x4b, 0x91, 0x0 } },
+ { 0x4b, 0x91, 0x0 } },
{ { 0xc15, 0xc4d, 0xc30, 0x0 },
- { 0x5a, 0xb2, 0x0 } },
+ { 0x5a, 0xb2, 0x0 } },
{ { 0xc15, 0xc4d, 0xc30, 0xc4d, 0x0 },
- { 0xbb, 0xb2, 0x0 } },
+ { 0xbb, 0xb2, 0x0 } },
{ { 0xc15, 0xc4d, 0xc30, 0xc4d, 0xc15, 0x0 },
- { 0x5a, 0xb2, 0x83, 0x0 } },
+ { 0x5a, 0xb2, 0x83, 0x0 } },
{ { 0xc15, 0xc4d, 0xc30, 0xc3f, 0x0 },
- { 0xe2, 0xb2, 0x0 } },
+ { 0xe2, 0xb2, 0x0 } },
{ { 0xc15, 0xc4d, 0xc15, 0xc48, 0x0 },
{ 0xe6, 0xb3, 0x83, 0x0 } },
{ { 0xc15, 0xc4d, 0xc30, 0xc48, 0x0 },
- { 0xe6, 0xb3, 0x9f, 0x0 } },
+ { 0xe6, 0xb3, 0x9f, 0x0 } },
{ { 0xc15, 0xc46, 0xc56, 0x0 },
{ 0xe6, 0xb3, 0x0 } },
{ {0}, {0} }
};
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find Pothana2000");
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find Pothana2000");
}
}
@@ -750,42 +750,42 @@ void tst_QTextScriptEngine::kannada_data()
{
if (QFontDatabase().families(QFontDatabase::Kannada).contains("Sampige")) {
QFont f("Sampige");
- const ShapeTable shape_table [] = {
- { { 0x0ca8, 0x0ccd, 0x0ca8, 0x0 },
- { 0x0049, 0x00ba, 0x0 } },
- { { 0x0ca8, 0x0ccd, 0x0ca1, 0x0 },
- { 0x0049, 0x00b3, 0x0 } },
- { { 0x0caf, 0x0cc2, 0x0 },
- { 0x004f, 0x005d, 0x0 } },
- { { 0x0ce0, 0x0 },
- { 0x006a, 0x0 } },
- { { 0x0ce6, 0x0ce7, 0x0ce8, 0x0 },
- { 0x006b, 0x006c, 0x006d, 0x0 } },
- { { 0x0cb5, 0x0ccb, 0x0 },
- { 0x015f, 0x0067, 0x0 } },
- { { 0x0cb0, 0x0ccd, 0x0cae, 0x0 },
- { 0x004e, 0x0082, 0x0 } },
- { { 0x0cb0, 0x0ccd, 0x0c95, 0x0 },
- { 0x0036, 0x0082, 0x0 } },
- { { 0x0c95, 0x0ccd, 0x0cb0, 0x0 },
- { 0x0036, 0x00c1, 0x0 } },
- { { 0x0cb0, 0x0ccd, 0x200d, 0x0c95, 0x0 },
- { 0x0050, 0x00a7, 0x0 } },
-
- { {0}, {0} }
- };
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find Sampige");
+ const ShapeTable shape_table [] = {
+ { { 0x0ca8, 0x0ccd, 0x0ca8, 0x0 },
+ { 0x0049, 0x00ba, 0x0 } },
+ { { 0x0ca8, 0x0ccd, 0x0ca1, 0x0 },
+ { 0x0049, 0x00b3, 0x0 } },
+ { { 0x0caf, 0x0cc2, 0x0 },
+ { 0x004f, 0x005d, 0x0 } },
+ { { 0x0ce0, 0x0 },
+ { 0x006a, 0x0 } },
+ { { 0x0ce6, 0x0ce7, 0x0ce8, 0x0 },
+ { 0x006b, 0x006c, 0x006d, 0x0 } },
+ { { 0x0cb5, 0x0ccb, 0x0 },
+ { 0x015f, 0x0067, 0x0 } },
+ { { 0x0cb0, 0x0ccd, 0x0cae, 0x0 },
+ { 0x004e, 0x0082, 0x0 } },
+ { { 0x0cb0, 0x0ccd, 0x0c95, 0x0 },
+ { 0x0036, 0x0082, 0x0 } },
+ { { 0x0c95, 0x0ccd, 0x0cb0, 0x0 },
+ { 0x0036, 0x00c1, 0x0 } },
+ { { 0x0cb0, 0x0ccd, 0x200d, 0x0c95, 0x0 },
+ { 0x0050, 0x00a7, 0x0 } },
+
+ { {0}, {0} }
+ };
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find Sampige");
}
{
if (QFontDatabase().families(QFontDatabase::Kannada).contains("Tunga")) {
QFont f("Tunga");
- const ShapeTable shape_table [] = {
- { { 0x0cb7, 0x0cc6, 0x0 },
- { 0x00b0, 0x006c, 0x0 } },
- { { 0x0cb7, 0x0ccd, 0x0 },
- { 0x0163, 0x0 } },
+ const ShapeTable shape_table [] = {
+ { { 0x0cb7, 0x0cc6, 0x0 },
+ { 0x00b0, 0x006c, 0x0 } },
+ { { 0x0cb7, 0x0ccd, 0x0 },
+ { 0x0163, 0x0 } },
{ { 0xc95, 0xcbf, 0xcd5, 0x0 },
{ 0x114, 0x73, 0x0 } },
{ { 0xc95, 0xcc6, 0xcd5, 0x0 },
@@ -796,11 +796,11 @@ void tst_QTextScriptEngine::kannada_data()
{ 0x90, 0x6c, 0x69, 0x0 } },
{ { 0xc95, 0xcca, 0xcd5, 0x0 },
{ 0x90, 0x6c, 0x69, 0x73, 0x0 } },
- { {0}, {0} }
- };
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find Tunga");
+ { {0}, {0} }
+ };
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find Tunga");
}
}
@@ -821,33 +821,33 @@ void tst_QTextScriptEngine::malayalam_data()
{
if (QFontDatabase().families(QFontDatabase::Malayalam).contains("AkrutiMal2")) {
QFont f("AkrutiMal2");
- const ShapeTable shape_table [] = {
- { { 0x0d15, 0x0d46, 0x0 },
- { 0x005e, 0x0034, 0x0 } },
- { { 0x0d15, 0x0d47, 0x0 },
- { 0x005f, 0x0034, 0x0 } },
- { { 0x0d15, 0x0d4b, 0x0 },
- { 0x005f, 0x0034, 0x0058, 0x0 } },
- { { 0x0d15, 0x0d48, 0x0 },
- { 0x0060, 0x0034, 0x0 } },
- { { 0x0d15, 0x0d4a, 0x0 },
- { 0x005e, 0x0034, 0x0058, 0x0 } },
- { { 0x0d30, 0x0d4d, 0x0d15, 0x0 },
- { 0x009e, 0x0034, 0x0 } },
- { { 0x0d15, 0x0d4d, 0x0d35, 0x0 },
- { 0x0034, 0x007a, 0x0 } },
- { { 0x0d15, 0x0d4d, 0x0d2f, 0x0 },
- { 0x0034, 0x00a2, 0x0 } },
- { { 0x0d1f, 0x0d4d, 0x0d1f, 0x0 },
- { 0x0069, 0x0 } },
- { { 0x0d26, 0x0d4d, 0x0d26, 0x0 },
- { 0x0074, 0x0 } },
- { { 0x0d30, 0x0d4d, 0x0 },
- { 0x009e, 0x0 } },
- { { 0x0d30, 0x0d4d, 0x200c, 0x0 },
- { 0x009e, 0x0 } },
- { { 0x0d30, 0x0d4d, 0x200d, 0x0 },
- { 0x009e, 0x0 } },
+ const ShapeTable shape_table [] = {
+ { { 0x0d15, 0x0d46, 0x0 },
+ { 0x005e, 0x0034, 0x0 } },
+ { { 0x0d15, 0x0d47, 0x0 },
+ { 0x005f, 0x0034, 0x0 } },
+ { { 0x0d15, 0x0d4b, 0x0 },
+ { 0x005f, 0x0034, 0x0058, 0x0 } },
+ { { 0x0d15, 0x0d48, 0x0 },
+ { 0x0060, 0x0034, 0x0 } },
+ { { 0x0d15, 0x0d4a, 0x0 },
+ { 0x005e, 0x0034, 0x0058, 0x0 } },
+ { { 0x0d30, 0x0d4d, 0x0d15, 0x0 },
+ { 0x009e, 0x0034, 0x0 } },
+ { { 0x0d15, 0x0d4d, 0x0d35, 0x0 },
+ { 0x0034, 0x007a, 0x0 } },
+ { { 0x0d15, 0x0d4d, 0x0d2f, 0x0 },
+ { 0x0034, 0x00a2, 0x0 } },
+ { { 0x0d1f, 0x0d4d, 0x0d1f, 0x0 },
+ { 0x0069, 0x0 } },
+ { { 0x0d26, 0x0d4d, 0x0d26, 0x0 },
+ { 0x0074, 0x0 } },
+ { { 0x0d30, 0x0d4d, 0x0 },
+ { 0x009e, 0x0 } },
+ { { 0x0d30, 0x0d4d, 0x200c, 0x0 },
+ { 0x009e, 0x0 } },
+ { { 0x0d30, 0x0d4d, 0x200d, 0x0 },
+ { 0x009e, 0x0 } },
{ { 0xd15, 0xd46, 0xd3e, 0x0 },
{ 0x5e, 0x34, 0x58, 0x0 } },
{ { 0xd15, 0xd47, 0xd3e, 0x0 },
@@ -856,11 +856,11 @@ void tst_QTextScriptEngine::malayalam_data()
{ 0x5e, 0x34, 0x65, 0x0 } },
{ { 0xd15, 0xd57, 0x0 },
{ 0x34, 0x65, 0x0 } },
- { {0}, {0} }
- };
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find AkrutiMal2");
+ { {0}, {0} }
+ };
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find AkrutiMal2");
}
{
if (QFontDatabase().families(QFontDatabase::Malayalam).contains("Rachana")) {
@@ -879,7 +879,7 @@ void tst_QTextScriptEngine::malayalam_data()
{ {0}, {0} }
};
- prepareShapingTest(f, shape_table);
+ prepareShapingTest(f, shape_table);
} else
QSKIP("couldn't find Rachana");
}
@@ -917,7 +917,7 @@ void tst_QTextScriptEngine::sinhala_data()
{ 0x4a, 0x61, 0x42, 0x41, 0x0 } },
{ {0}, {0} }
};
- prepareShapingTest(f, shape_table);
+ prepareShapingTest(f, shape_table);
} else
QSKIP("couldn't find Malithi Web");
}
@@ -940,30 +940,30 @@ void tst_QTextScriptEngine::khmer_data()
{
if (QFontDatabase().families(QFontDatabase::Khmer).contains("Khmer OS")) {
QFont f("Khmer OS");
- const ShapeTable shape_table [] = {
- { { 0x179a, 0x17cd, 0x0 },
- { 0x24c, 0x27f, 0x0 } },
- { { 0x179f, 0x17c5, 0x0 },
- { 0x273, 0x203, 0x0 } },
- { { 0x1790, 0x17d2, 0x1784, 0x17c3, 0x0 },
- { 0x275, 0x242, 0x182, 0x0 } },
- { { 0x179a, 0x0 },
- { 0x24c, 0x0 } },
- { { 0x1781, 0x17d2, 0x1798, 0x17c2, 0x0 },
- { 0x274, 0x233, 0x197, 0x0 } },
- { { 0x1798, 0x17b6, 0x0 },
- { 0x1cb, 0x0 } },
- { { 0x179a, 0x17b8, 0x0 },
- { 0x24c, 0x26a, 0x0 } },
- { { 0x1787, 0x17b6, 0x0 },
- { 0x1ba, 0x0 } },
- { { 0x1798, 0x17d2, 0x1796, 0x17bb, 0x0 },
- { 0x24a, 0x195, 0x26d, 0x0 } },
- { {0}, {0} }
- };
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find Khmer OS");
+ const ShapeTable shape_table [] = {
+ { { 0x179a, 0x17cd, 0x0 },
+ { 0x24c, 0x27f, 0x0 } },
+ { { 0x179f, 0x17c5, 0x0 },
+ { 0x273, 0x203, 0x0 } },
+ { { 0x1790, 0x17d2, 0x1784, 0x17c3, 0x0 },
+ { 0x275, 0x242, 0x182, 0x0 } },
+ { { 0x179a, 0x0 },
+ { 0x24c, 0x0 } },
+ { { 0x1781, 0x17d2, 0x1798, 0x17c2, 0x0 },
+ { 0x274, 0x233, 0x197, 0x0 } },
+ { { 0x1798, 0x17b6, 0x0 },
+ { 0x1cb, 0x0 } },
+ { { 0x179a, 0x17b8, 0x0 },
+ { 0x24c, 0x26a, 0x0 } },
+ { { 0x1787, 0x17b6, 0x0 },
+ { 0x1ba, 0x0 } },
+ { { 0x1798, 0x17d2, 0x1796, 0x17bb, 0x0 },
+ { 0x24a, 0x195, 0x26d, 0x0 } },
+ { {0}, {0} }
+ };
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find Khmer OS");
}
}
@@ -984,14 +984,14 @@ void tst_QTextScriptEngine::linearB_data()
{
if (QFontDatabase().families(QFontDatabase::Any).contains("Penuturesu")) {
QFont f("Penuturesu");
- const ShapeTable shape_table [] = {
- { { 0xd800, 0xdc01, 0xd800, 0xdc02, 0xd800, 0xdc03, 0 },
+ const ShapeTable shape_table [] = {
+ { { 0xd800, 0xdc01, 0xd800, 0xdc02, 0xd800, 0xdc03, 0 },
{ 0x5, 0x6, 0x7, 0 } },
- { {0}, {0} }
- };
- prepareShapingTest(f, shape_table);
- } else
- QSKIP("couldn't find Penuturesu");
+ { {0}, {0} }
+ };
+ prepareShapingTest(f, shape_table);
+ } else
+ QSKIP("couldn't find Penuturesu");
}
}
@@ -1134,8 +1134,8 @@ void tst_QTextScriptEngine::mirroredChars()
s.append(QLatin1Char('('));
s.append(QLatin1Char(')'));
- HB_Glyph leftParenthesis;
- HB_Glyph rightParenthesis;
+ glyph_t leftParenthesis;
+ glyph_t rightParenthesis;
{
QTextLayout layout(s);
layout.setCacheEnabled(true);
diff --git a/tests/auto/gui/text/qtexttable/qtexttable.pro b/tests/auto/gui/text/qtexttable/qtexttable.pro
index 1c59bf1471..1e7249090a 100644
--- a/tests/auto/gui/text/qtexttable/qtexttable.pro
+++ b/tests/auto/gui/text/qtexttable/qtexttable.pro
@@ -7,4 +7,3 @@ SOURCES += tst_qtexttable.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/qzip/qzip.pro b/tests/auto/gui/text/qzip/qzip.pro
index 479f48ff1d..309f2167d1 100644
--- a/tests/auto/gui/text/qzip/qzip.pro
+++ b/tests/auto/gui/text/qzip/qzip.pro
@@ -11,4 +11,3 @@ wince* {
} else {
DEFINES += SRCDIR=\\\"$$PWD\\\"
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/text/text.pro b/tests/auto/gui/text/text.pro
index 5055ab61a3..6c0def4d63 100644
--- a/tests/auto/gui/text/text.pro
+++ b/tests/auto/gui/text/text.pro
@@ -3,6 +3,7 @@ SUBDIRS=\
qabstracttextdocumentlayout \
qcssparser \
qfont \
+ qfontcache \
qfontdatabase \
qfontmetrics \
qglyphrun \
@@ -27,6 +28,7 @@ contains(QT_CONFIG, OdfWriter):SUBDIRS += qzip qtextodfwriter
win32:SUBDIRS -= qtextpiecetable
!contains(QT_CONFIG, private_tests): SUBDIRS -= \
+ qfontcache \
qcssparser \
qstatictext \
qtextlayout \
diff --git a/tests/auto/gui/util/qdoublevalidator/qdoublevalidator.pro b/tests/auto/gui/util/qdoublevalidator/qdoublevalidator.pro
index 1941bea02c..9f04bdbb60 100644
--- a/tests/auto/gui/util/qdoublevalidator/qdoublevalidator.pro
+++ b/tests/auto/gui/util/qdoublevalidator/qdoublevalidator.pro
@@ -5,4 +5,3 @@ QT += testlib
SOURCES += tst_qdoublevalidator.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/util/qintvalidator/qintvalidator.pro b/tests/auto/gui/util/qintvalidator/qintvalidator.pro
index 1afc806ee1..4bc35416b5 100644
--- a/tests/auto/gui/util/qintvalidator/qintvalidator.pro
+++ b/tests/auto/gui/util/qintvalidator/qintvalidator.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qintvalidator
SOURCES += tst_qintvalidator.cpp
QT += testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/util/qregexpvalidator/qregexpvalidator.pro b/tests/auto/gui/util/qregexpvalidator/qregexpvalidator.pro
index f2797466e3..5b70d7b11d 100644
--- a/tests/auto/gui/util/qregexpvalidator/qregexpvalidator.pro
+++ b/tests/auto/gui/util/qregexpvalidator/qregexpvalidator.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qregexpvalidator
SOURCES += tst_qregexpvalidator.cpp
QT += testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/gui/util/qregularexpressionvalidator/.gitignore b/tests/auto/gui/util/qregularexpressionvalidator/.gitignore
new file mode 100644
index 0000000000..a4022144d5
--- /dev/null
+++ b/tests/auto/gui/util/qregularexpressionvalidator/.gitignore
@@ -0,0 +1 @@
+tst_qregularexpressionvalidator
diff --git a/tests/auto/gui/util/qregularexpressionvalidator/qregularexpressionvalidator.pro b/tests/auto/gui/util/qregularexpressionvalidator/qregularexpressionvalidator.pro
new file mode 100644
index 0000000000..1e8e50563e
--- /dev/null
+++ b/tests/auto/gui/util/qregularexpressionvalidator/qregularexpressionvalidator.pro
@@ -0,0 +1,4 @@
+CONFIG += testcase parallel_test
+TARGET = tst_qregularexpressionvalidator
+SOURCES += tst_qregularexpressionvalidator.cpp
+QT += testlib
diff --git a/tests/auto/gui/util/qregularexpressionvalidator/tst_qregularexpressionvalidator.cpp b/tests/auto/gui/util/qregularexpressionvalidator/tst_qregularexpressionvalidator.cpp
new file mode 100644
index 0000000000..61d26104bd
--- /dev/null
+++ b/tests/auto/gui/util/qregularexpressionvalidator/tst_qregularexpressionvalidator.cpp
@@ -0,0 +1,120 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com, author Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QRegularExpressionValidator>
+#include <QtTest/QtTest>
+
+class tst_QRegularExpressionValidator : public QObject
+{
+ Q_OBJECT
+
+private slots:
+ void validate_data();
+ void validate();
+};
+
+Q_DECLARE_METATYPE(QValidator::State)
+
+void tst_QRegularExpressionValidator::validate_data()
+{
+ QTest::addColumn<QRegularExpression>("re");
+ QTest::addColumn<QString>("value");
+ QTest::addColumn<QValidator::State>("state");
+
+ QTest::newRow("data0") << QRegularExpression("[1-9]\\d{0,3}") << QString("0") << QValidator::Invalid;
+ QTest::newRow("data1") << QRegularExpression("[1-9]\\d{0,3}") << QString("12345") << QValidator::Invalid;
+ QTest::newRow("data2") << QRegularExpression("[1-9]\\d{0,3}") << QString("1") << QValidator::Acceptable;
+
+ QTest::newRow("data3") << QRegularExpression("\\S+") << QString("myfile.txt") << QValidator::Acceptable;
+ QTest::newRow("data4") << QRegularExpression("\\S+") << QString("my file.txt") << QValidator::Invalid;
+
+ QTest::newRow("data5") << QRegularExpression("[A-C]\\d{5}[W-Z]") << QString("a12345Z") << QValidator::Invalid;
+ QTest::newRow("data6") << QRegularExpression("[A-C]\\d{5}[W-Z]") << QString("A12345Z") << QValidator::Acceptable;
+ QTest::newRow("data7") << QRegularExpression("[A-C]\\d{5}[W-Z]") << QString("B12") << QValidator::Intermediate;
+
+ QTest::newRow("data8") << QRegularExpression("read\\S?me(\\.(txt|asc|1st))?") << QString("readme") << QValidator::Acceptable;
+ QTest::newRow("data9") << QRegularExpression("read\\S?me(\\.(txt|asc|1st))?") << QString("read me.txt") << QValidator::Invalid;
+ QTest::newRow("data10") << QRegularExpression("read\\S?me(\\.(txt|asc|1st))?") << QString("readm") << QValidator::Intermediate;
+
+ QTest::newRow("data11") << QRegularExpression("read\\S?me(\\.(txt|asc|1st))?") << QString("read me.txt") << QValidator::Invalid;
+ QTest::newRow("data12") << QRegularExpression("read\\S?me(\\.(txt|asc|1st))?") << QString("readm") << QValidator::Intermediate;
+
+ QTest::newRow("data13") << QRegularExpression("\\w\\d\\d") << QString("A57") << QValidator::Acceptable;
+ QTest::newRow("data14") << QRegularExpression("\\w\\d\\d") << QString("E5") << QValidator::Intermediate;
+ QTest::newRow("data15") << QRegularExpression("\\w\\d\\d") << QString("+9") << QValidator::Invalid;
+
+ QTest::newRow("empty01") << QRegularExpression() << QString() << QValidator::Acceptable;
+ QTest::newRow("empty02") << QRegularExpression() << QString("test") << QValidator::Acceptable;
+}
+
+void tst_QRegularExpressionValidator::validate()
+{
+ QFETCH(QRegularExpression, re);
+ QFETCH(QString, value);
+
+ QRegularExpressionValidator rv;
+
+ // setting the same regexp won't emit signals
+ const int signalCount = (rv.regularExpression() == re) ? 0 : 1;
+
+ QSignalSpy spy(&rv, SIGNAL(regularExpressionChanged(QRegularExpression)));
+ QSignalSpy changedSpy(&rv, SIGNAL(changed()));
+
+ rv.setRegularExpression(re);
+ QCOMPARE(rv.regularExpression(), re);
+
+ int pos = -1;
+ QValidator::State result = rv.validate(value, pos);
+
+ QTEST(result, "state");
+ if (result == QValidator::Invalid)
+ QCOMPARE(pos, value.length());
+ else
+ QCOMPARE(pos, -1); // ensure pos is not modified if validate returned Acceptable or Intermediate
+
+ QCOMPARE(spy.count(), signalCount);
+ QCOMPARE(changedSpy.count(), signalCount);
+}
+
+QTEST_GUILESS_MAIN(tst_QRegularExpressionValidator)
+
+#include "tst_qregularexpressionvalidator.moc"
diff --git a/tests/auto/gui/util/util.pro b/tests/auto/gui/util/util.pro
index a0963980c9..f2c4515dc2 100644
--- a/tests/auto/gui/util/util.pro
+++ b/tests/auto/gui/util/util.pro
@@ -4,4 +4,5 @@ SUBDIRS= \
qdoublevalidator \
qintvalidator \
qregexpvalidator \
+ qregularexpressionvalidator \
diff --git a/tests/auto/network/access/qhttpnetworkconnection/tst_qhttpnetworkconnection.cpp b/tests/auto/network/access/qhttpnetworkconnection/tst_qhttpnetworkconnection.cpp
index d629b30ca6..7bb435952b 100644
--- a/tests/auto/network/access/qhttpnetworkconnection/tst_qhttpnetworkconnection.cpp
+++ b/tests/auto/network/access/qhttpnetworkconnection/tst_qhttpnetworkconnection.cpp
@@ -875,17 +875,17 @@ void tst_QHttpNetworkConnection::getMultipleWithPipeliningAndMultiplePriorities(
request = new QHttpNetworkRequest("http://" + QtNetworkSettings::serverName() + "/qtest/rfc3252.txt", QHttpNetworkRequest::Get);
else
request = new QHttpNetworkRequest("http://" + QtNetworkSettings::serverName() + "/qtest/rfc3252.txt", QHttpNetworkRequest::Head);
-
+
if (i % 2 || i % 3)
request->setPipeliningAllowed(true);
-
+
if (i % 3)
request->setPriority(QHttpNetworkRequest::HighPriority);
else if (i % 5)
request->setPriority(QHttpNetworkRequest::NormalPriority);
else if (i % 7)
request->setPriority(QHttpNetworkRequest::LowPriority);
-
+
requests.append(request);
QHttpNetworkReply *reply = connection.sendRequest(*request);
replies.append(reply);
diff --git a/tests/auto/network/access/qnetworkcookiejar/tst_qnetworkcookiejar.cpp b/tests/auto/network/access/qnetworkcookiejar/tst_qnetworkcookiejar.cpp
index 284201db29..4ee4b67ec0 100644
--- a/tests/auto/network/access/qnetworkcookiejar/tst_qnetworkcookiejar.cpp
+++ b/tests/auto/network/access/qnetworkcookiejar/tst_qnetworkcookiejar.cpp
@@ -451,7 +451,7 @@ void tst_QNetworkCookieJar::effectiveTLDs_data()
QTest::newRow("yes-wildcard1.5") << "anything.jm" << true;
QTest::newRow("yes-wildcard2") << "something.kh" << true;
QTest::newRow("yes-wildcard3") << "whatever.uk" << true;
- QTest::newRow("yes-wildcard4") << "anything.shizuoka.jp" << true;
+ QTest::newRow("yes-wildcard4") << "anything.sendai.jp" << true;
QTest::newRow("yes-wildcard5") << "foo.sch.uk" << true;
}
diff --git a/tests/auto/network/access/qnetworkdiskcache/tst_qnetworkdiskcache.cpp b/tests/auto/network/access/qnetworkdiskcache/tst_qnetworkdiskcache.cpp
index 55eb1fed82..54b560cc1b 100644
--- a/tests/auto/network/access/qnetworkdiskcache/tst_qnetworkdiskcache.cpp
+++ b/tests/auto/network/access/qnetworkdiskcache/tst_qnetworkdiskcache.cpp
@@ -79,7 +79,7 @@ private slots:
void oldCacheVersionFile_data();
void oldCacheVersionFile();
-
+
void sync();
void crashWhenParentingCache();
diff --git a/tests/auto/network/access/qnetworkreply/echo/main.cpp b/tests/auto/network/access/qnetworkreply/echo/main.cpp
index 6a4a959cdc..1f91c5da97 100644
--- a/tests/auto/network/access/qnetworkreply/echo/main.cpp
+++ b/tests/auto/network/access/qnetworkreply/echo/main.cpp
@@ -48,7 +48,7 @@ int main(int argc, char **)
printf("echos all its input to its output.\n");
return 1;
}
-
+
QFile file;
file.open(stdin, QFile::ReadWrite);
QByteArray data = file.readAll();
diff --git a/tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp b/tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp
index 624ce5e800..bcc0641973 100644
--- a/tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp
+++ b/tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp
@@ -71,6 +71,9 @@
#ifndef QT_NO_SSL
#include <QtNetwork/qsslerror.h>
#include <QtNetwork/qsslconfiguration.h>
+#ifdef QT_BUILD_INTERNAL
+#include <QtNetwork/private/qsslconfiguration_p.h>
+#endif
#endif
#ifndef QT_NO_BEARERMANAGEMENT
#include <QtNetwork/qnetworkconfigmanager.h>
@@ -173,6 +176,9 @@ public Q_SLOTS:
void sslErrors(QNetworkReply*,const QList<QSslError> &);
void storeSslConfiguration();
void ignoreSslErrorListSlot(QNetworkReply *reply, const QList<QSslError> &);
+#ifdef QT_BUILD_INTERNAL
+ void sslSessionSharingHelperSlot();
+#endif
#endif
protected Q_SLOTS:
@@ -355,8 +361,13 @@ private Q_SLOTS:
void ignoreSslErrorsList();
void ignoreSslErrorsListWithSlot_data();
void ignoreSslErrorsListWithSlot();
+ void encrypted();
void sslConfiguration_data();
void sslConfiguration();
+#ifdef QT_BUILD_INTERNAL
+ void sslSessionSharing_data();
+ void sslSessionSharing();
+#endif
#endif
void getAndThenDeleteObject_data();
@@ -5857,6 +5868,24 @@ void tst_QNetworkReply::sslConfiguration_data()
QTest::newRow("secure") << conf << true;
}
+void tst_QNetworkReply::encrypted()
+{
+ qDebug() << QtNetworkSettings::serverName();
+ QUrl url("https://" + QtNetworkSettings::serverName());
+ QNetworkRequest request(url);
+ QNetworkReply *reply = manager.get(request);
+ reply->ignoreSslErrors();
+
+ QSignalSpy spy(reply, SIGNAL(encrypted()));
+ connect(reply, SIGNAL(finished()), &QTestEventLoop::instance(), SLOT(exitLoop()));
+ QTestEventLoop::instance().enterLoop(20);
+ QVERIFY(!QTestEventLoop::instance().timeout());
+
+ QCOMPARE(spy.count(), 1);
+
+ reply->deleteLater();
+}
+
void tst_QNetworkReply::sslConfiguration()
{
QNetworkRequest request(QUrl("https://" + QtNetworkSettings::serverName() + "/index.html"));
@@ -5871,6 +5900,73 @@ void tst_QNetworkReply::sslConfiguration()
QCOMPARE(reply->error(), expectedError);
}
+#ifdef QT_BUILD_INTERNAL
+
+void tst_QNetworkReply::sslSessionSharing_data()
+{
+ QTest::addColumn<bool>("sessionSharingEnabled");
+ QTest::newRow("enabled") << true;
+ QTest::newRow("disabled") << false;
+}
+
+void tst_QNetworkReply::sslSessionSharing()
+{
+ QString urlString("https://" + QtNetworkSettings::serverName());
+ QList<QNetworkReplyPtr> replies;
+
+ // warm up SSL session cache
+ QNetworkRequest warmupRequest(urlString);
+ QFETCH(bool, sessionSharingEnabled);
+ warmupRequest.setAttribute(QNetworkRequest::User, sessionSharingEnabled); // so we can read it from the slot
+ if (! sessionSharingEnabled) {
+ QSslConfiguration configuration(QSslConfiguration::defaultConfiguration());
+ configuration.setSslOption(QSsl::SslOptionDisableSessionTickets, true);
+ warmupRequest.setSslConfiguration(configuration);
+ }
+ QNetworkReply *reply = manager.get(warmupRequest);
+ reply->ignoreSslErrors();
+ connect(reply, SIGNAL(finished()), &QTestEventLoop::instance(), SLOT(exitLoop()));
+ QTestEventLoop::instance().enterLoop(20);
+ QVERIFY(!QTestEventLoop::instance().timeout());
+ QCOMPARE(reply->error(), QNetworkReply::NoError);
+ reply->deleteLater();
+
+ // now send several requests at the same time, so we open more sockets and reuse the SSL session
+ for (int a = 0; a < 6; a++) {
+ QNetworkRequest request(warmupRequest);
+ replies.append(QNetworkReplyPtr(manager.get(request)));
+ connect(replies.at(a), SIGNAL(finished()), this, SLOT(sslSessionSharingHelperSlot()));
+ }
+ QTestEventLoop::instance().enterLoop(20);
+ QVERIFY(!QTestEventLoop::instance().timeout());
+}
+
+void tst_QNetworkReply::sslSessionSharingHelperSlot()
+{
+ static int count = 0;
+
+ // check that SSL session sharing was used in at least one of the replies
+ static bool sslSessionSharingWasUsed = false;
+ QNetworkReply *reply = qobject_cast<QNetworkReply *>(sender());
+ bool sslSessionSharingWasUsedInReply = QSslConfigurationPrivate::peerSessionWasShared(reply->sslConfiguration());
+ if (sslSessionSharingWasUsedInReply)
+ sslSessionSharingWasUsed = true;
+
+ QString urlQueryString = reply->url().query();
+ QCOMPARE(reply->error(), QNetworkReply::NoError);
+
+ count++;
+
+ if (count == 6) { // all replies have finished
+ QTestEventLoop::instance().exitLoop();
+ bool sessionSharingWasEnabled = reply->request().attribute(QNetworkRequest::User).toBool();
+ QCOMPARE(sslSessionSharingWasUsed, sessionSharingWasEnabled);
+ count = 0; // reset for next row
+ sslSessionSharingWasUsed = false; // reset for next row
+ }
+}
+
+#endif // QT_BUILD_INTERNAL
#endif // QT_NO_SSL
void tst_QNetworkReply::getAndThenDeleteObject_data()
diff --git a/tests/auto/network/bearer/qnetworkconfiguration/tst_qnetworkconfiguration.cpp b/tests/auto/network/bearer/qnetworkconfiguration/tst_qnetworkconfiguration.cpp
index a38b5f5338..f4cbfbe8f2 100644
--- a/tests/auto/network/bearer/qnetworkconfiguration/tst_qnetworkconfiguration.cpp
+++ b/tests/auto/network/bearer/qnetworkconfiguration/tst_qnetworkconfiguration.cpp
@@ -96,7 +96,7 @@ void tst_QNetworkConfiguration::invalidPoint()
void tst_QNetworkConfiguration::comparison()
{
//test copy constructor and assignment operator
- //compare invalid connection points
+ //compare invalid connection points
QNetworkConfiguration pt1;
QVERIFY(!pt1.isValid());
QVERIFY(pt1.type() == QNetworkConfiguration::Invalid);
@@ -110,7 +110,7 @@ void tst_QNetworkConfiguration::comparison()
QVERIFY(pt1.state() == pt2.state());
QVERIFY(pt1.purpose() == pt2.purpose());
-
+
QNetworkConfiguration pt3;
pt3 = pt1;
QVERIFY(pt1==pt3);
@@ -170,12 +170,12 @@ void tst_QNetworkConfiguration::isRoamingAvailable()
{
QNetworkConfigurationManager manager;
QList<QNetworkConfiguration> configs = manager.allConfigurations();
-
+
//force update to get maximum list
QSignalSpy spy(&manager, SIGNAL(updateCompleted()));
manager.updateConfigurations(); //initiate scans
QTRY_VERIFY_WITH_TIMEOUT(spy.count() == 1, TestTimeOut); //wait for scan to complete
-
+
foreach(QNetworkConfiguration c, configs)
{
QVERIFY(QNetworkConfiguration::UserChoice != c.type());
diff --git a/tests/auto/network/bearer/qnetworkconfigurationmanager/tst_qnetworkconfigurationmanager.cpp b/tests/auto/network/bearer/qnetworkconfigurationmanager/tst_qnetworkconfigurationmanager.cpp
index 835b9aecfb..18aba51fe6 100644
--- a/tests/auto/network/bearer/qnetworkconfigurationmanager/tst_qnetworkconfigurationmanager.cpp
+++ b/tests/auto/network/bearer/qnetworkconfigurationmanager/tst_qnetworkconfigurationmanager.cpp
@@ -64,7 +64,7 @@ private slots:
#ifndef QT_NO_BEARERMANAGEMENT
void printConfigurationDetails(const QNetworkConfiguration& p)
{
- qDebug() << p.name() <<": isvalid->" <<p.isValid() << " type->"<< p.type() <<
+ qDebug() << p.name() <<": isvalid->" <<p.isValid() << " type->"<< p.type() <<
" roaming->" << p.isRoamingAvailable() << "identifier->" << p.identifier() <<
" purpose->" << p.purpose() << " state->" << p.state();
}
@@ -189,7 +189,7 @@ void tst_QNetworkConfigurationManager::configurationFromIdentifier()
QSignalSpy spy(&manager, SIGNAL(updateCompleted()));
manager.updateConfigurations(); //initiate scans
QTRY_VERIFY_WITH_TIMEOUT(spy.count() == 1, TestTimeOut); //wait for scan to complete
-
+
QList<QNetworkConfiguration> configs = manager.allConfigurations();
foreach(QNetworkConfiguration c, configs) {
diff --git a/tests/auto/network/bearer/qnetworksession/test/tst_qnetworksession.cpp b/tests/auto/network/bearer/qnetworksession/test/tst_qnetworksession.cpp
index 529f45f001..5dede11e5b 100644
--- a/tests/auto/network/bearer/qnetworksession/test/tst_qnetworksession.cpp
+++ b/tests/auto/network/bearer/qnetworksession/test/tst_qnetworksession.cpp
@@ -139,7 +139,7 @@ void tst_QNetworkSession::cleanupTestCase()
}
// Robustness test for calling interfaces in nonsense order / with nonsense parameters
-void tst_QNetworkSession::robustnessBombing()
+void tst_QNetworkSession::robustnessBombing()
{
QNetworkConfigurationManager mgr;
QNetworkSession testSession(mgr.defaultConfiguration());
@@ -199,18 +199,18 @@ void tst_QNetworkSession::invalidSession()
QVERIFY(!session.isOpen());
QVERIFY(session.state() == QNetworkSession::Invalid);
QVERIFY(session.error() == QNetworkSession::InvalidConfigurationError);
-
+
// 2. Verify that opening session with invalid configuration both 1) emits invalidconfigurationerror and 2) sets session's state as invalid.
QSignalSpy errorSpy(&session, SIGNAL(error(QNetworkSession::SessionError)));
session.open();
session.waitForOpened(1000); // Should bail out right away
- QVERIFY(errorSpy.count() == 1);
+ QVERIFY(errorSpy.count() == 1);
QNetworkSession::SessionError error =
qvariant_cast<QNetworkSession::SessionError> (errorSpy.first().at(0));
QVERIFY(error == QNetworkSession::InvalidConfigurationError);
QVERIFY(session.error() == QNetworkSession::InvalidConfigurationError);
QVERIFY(session.state() == QNetworkSession::Invalid);
-
+
#ifdef QNETWORKSESSION_MANUAL_TESTS
QNetworkConfiguration invalidatedConfig = suitableConfiguration("WLAN",QNetworkConfiguration::InternetAccessPoint);
@@ -354,7 +354,7 @@ void tst_QNetworkSession::repeatedOpenClose()
QNetworkSession permanentSession(config);
if (!openSession(&permanentSession) || !closeSession(&permanentSession))
QSKIP("Unable to open/close session, skipping this round of repeated open-close test.");
- for (int i = 0; i < repeatTimes; i++) {
+ for (int i = 0; i < repeatTimes; i++) {
qDebug() << "Opening, loop number " << i;
QVERIFY(openSession(&permanentSession));
qDebug() << "Closing, loop number, then waiting 5 seconds: " << i;
@@ -469,7 +469,7 @@ void tst_QNetworkSession::userChoiceSession()
QVERIFY(activeConfiguration.isValid());
QVERIFY(activeConfiguration.type() == QNetworkConfiguration::InternetAccessPoint);
-
+
//resetting ActiveConfiguration is ignored (read only property)
session.setSessionProperty("ActiveConfiguration", testIdentifier);
QVERIFY(session.sessionProperty("ActiveConfiguration").toString() != testIdentifier);
@@ -612,7 +612,7 @@ void tst_QNetworkSession::sessionOpenCloseStop()
QVERIFY(session.error() == QNetworkSession::UnknownSessionError);
session2.open();
-
+
QTRY_VERIFY_WITH_TIMEOUT(!sessionOpenedSpy2.isEmpty() || !errorSpy2.isEmpty(), TestTimeOut);
if (errorSpy2.isEmpty()) {
@@ -666,10 +666,10 @@ void tst_QNetworkSession::sessionOpenCloseStop()
QVERIFY(errorSpy.isEmpty());
QVERIFY(errorSpy2.isEmpty());
-
- // Wait for Disconnected state
+
+ // Wait for Disconnected state
QTRY_NOOP(session2.state() == QNetworkSession::Disconnected);
-
+
if (expectStateChange)
QTRY_VERIFY_WITH_TIMEOUT(stateChangedSpy2.count() >= 1 || !errorSpy2.isEmpty(), TestTimeOut);
@@ -722,14 +722,14 @@ void tst_QNetworkSession::sessionOpenCloseStop()
} else {
QFAIL("Unexpected amount of state changes when roaming.");
}
-
+
QTRY_VERIFY_WITH_TIMEOUT(session.state() == QNetworkSession::Roaming ||
session.state() == QNetworkSession::Connected ||
session.state() == QNetworkSession::Disconnected, TestTimeOut);
-
+
QTRY_VERIFY_WITH_TIMEOUT(stateChangedSpy.count() > 0, TestTimeOut);
- state = qvariant_cast<QNetworkSession::State>(stateChangedSpy.at(stateChangedSpy.count() - 1).at(0));
-
+ state = qvariant_cast<QNetworkSession::State>(stateChangedSpy.at(stateChangedSpy.count() - 1).at(0));
+
for (int i = 0; i < stateChangedSpy.count(); i++) {
QNetworkSession::State state_temp =
qvariant_cast<QNetworkSession::State>(stateChangedSpy.at(i).at(0));
@@ -753,7 +753,7 @@ void tst_QNetworkSession::sessionOpenCloseStop()
QTRY_VERIFY_WITH_TIMEOUT(errorSpy.isEmpty(),TestTimeOut);
if (stateChangedSpy.count() > 1) {
- state = qvariant_cast<QNetworkSession::State>(stateChangedSpy.at(stateChangedSpy.count() - 2).at(0));
+ state = qvariant_cast<QNetworkSession::State>(stateChangedSpy.at(stateChangedSpy.count() - 2).at(0));
QVERIFY(state == QNetworkSession::Roaming);
}
roamedSuccessfully = true;
@@ -778,7 +778,7 @@ void tst_QNetworkSession::sessionOpenCloseStop()
QVERIFY(!errorSpy.isEmpty());
} else {
QTest::qWait(2000); // Wait awhile to get all signals from platform
-
+
if (stateChangedSpy2.count() == 2) {
QNetworkSession::State state =
qvariant_cast<QNetworkSession::State>(stateChangedSpy2.at(0).at(0));
@@ -797,7 +797,7 @@ void tst_QNetworkSession::sessionOpenCloseStop()
QNetworkSession::State state =
qvariant_cast<QNetworkSession::State>(stateChangedSpy2.at(stateChangedSpy2.count() - 1).at(0));
- QVERIFY(state == QNetworkSession::Disconnected);
+ QVERIFY(state == QNetworkSession::Disconnected);
}
}
@@ -920,7 +920,7 @@ void tst_QNetworkSession::outOfProcessSession()
// Cannot read/write to processes on WinCE.
// Easiest alternative is to use sockets for IPC.
QLocalServer oopServer;
- // First remove possible earlier listening address which would cause listen to fail
+ // First remove possible earlier listening address which would cause listen to fail
// (e.g. previously abruptly ended unit test might cause this)
QLocalServer::removeServer("tst_qnetworksession");
oopServer.listen("tst_qnetworksession");
@@ -1034,7 +1034,7 @@ QNetworkConfiguration suitableConfiguration(QString bearerType, QNetworkConfigur
// qDebug() << "Dumping config because bearer mismatches (cellular): " << config.name();
discoveredConfigs.removeOne(config);
}
- } else if ((config.type() == QNetworkConfiguration::InternetAccessPoint) &&
+ } else if ((config.type() == QNetworkConfiguration::InternetAccessPoint) &&
bearerType != config.bearerTypeName()) {
// qDebug() << "Dumping config because bearer mismatches (WLAN): " << config.name();
discoveredConfigs.removeOne(config);
@@ -1109,12 +1109,12 @@ bool openSession(QNetworkSession *session) {
qDebug("tst_QNetworkSession::openSession() failure: QNetworkSession::error() - signal was detected.");
result = false;
}
- if (sessionInitState != QNetworkSession::Connected &&
+ if (sessionInitState != QNetworkSession::Connected &&
stateChangeSpy.isEmpty()) {
qDebug("tst_QNetworkSession::openSession() failure: QNetworkSession::stateChanged() - signals not detected.");
result = false;
}
- if (configInitState != QNetworkConfiguration::Active &&
+ if (configInitState != QNetworkConfiguration::Active &&
configChangeSpy.isEmpty()) {
qDebug("tst_QNetworkSession::openSession() failure: QNetworkConfigurationManager::configurationChanged() - signals not detected.");
result = false;
@@ -1132,7 +1132,7 @@ bool openSession(QNetworkSession *session) {
qDebug() << "tst_QNetworkSession::openSession() name of the configuration is: " << session->configuration().name();
qDebug() << "tst_QNetworkSession::openSession() configuration state is: " << session->configuration().state();
qDebug() << "tst_QNetworkSession::openSession() session state is: " << session->state();
-
+
return result;
}
@@ -1146,26 +1146,26 @@ bool closeSession(QNetworkSession *session, bool lastSessionOnConfiguration) {
qDebug("tst_QNetworkSession::closeSession() failure: NULL session given");
return false;
}
-
+
qDebug() << "tst_QNetworkSession::closeSession() name of the configuration to be closed: " << session->configuration().name();
qDebug() << "tst_QNetworkSession::closeSession() state of the configuration to be closed: " << session->configuration().state();
qDebug() << "tst_QNetworkSession::closeSession() state of the session to be closed: " << session->state();
-
- if (session->state() != QNetworkSession::Connected ||
+
+ if (session->state() != QNetworkSession::Connected ||
!session->isOpen()) {
qDebug("tst_QNetworkSession::closeSession() failure: session is not opened.");
return false;
- }
+ }
QNetworkConfigurationManager mgr;
QSignalSpy sessionClosedSpy(session, SIGNAL(closed()));
QSignalSpy sessionStateChangedSpy(session, SIGNAL(stateChanged(QNetworkSession::State)));
QSignalSpy sessionErrorSpy(session, SIGNAL(error(QNetworkSession::SessionError)));
QSignalSpy configChangeSpy(&mgr, SIGNAL(configurationChanged(QNetworkConfiguration)));
-
+
bool result = true;
session->close();
QTest::qWait(5000); // Wait a moment so that all signals are propagated
-
+
if (!sessionErrorSpy.isEmpty()) {
qDebug("tst_QNetworkSession::closeSession() failure: QNetworkSession::error() received.");
result = false;
@@ -1174,7 +1174,7 @@ bool closeSession(QNetworkSession *session, bool lastSessionOnConfiguration) {
qDebug("tst_QNetworkSession::closeSession() failure: QNetworkSession::closed() signal not received.");
result = false;
}
- if (lastSessionOnConfiguration &&
+ if (lastSessionOnConfiguration &&
sessionStateChangedSpy.isEmpty()) {
qDebug("tst_QNetworkSession::closeSession() failure: QNetworkSession::stateChanged() signals not received.");
result = false;
@@ -1199,7 +1199,7 @@ bool closeSession(QNetworkSession *session, bool lastSessionOnConfiguration) {
qDebug() << "tst_QNetworkSession::closeSession() closing session failed.";
} else {
qDebug() << "tst_QNetworkSession::closeSession() closing session succeeded.";
- }
+ }
qDebug() << "tst_QNetworkSession::closeSession() name of the configuration is: " << session->configuration().name();
qDebug() << "tst_QNetworkSession::closeSession() configuration state is: " << session->configuration().state();
qDebug() << "tst_QNetworkSession::closeSession() session state is: " << session->state();
diff --git a/tests/auto/network/kernel/qhostaddress/tst_qhostaddress.cpp b/tests/auto/network/kernel/qhostaddress/tst_qhostaddress.cpp
index 3b4af27d4e..dd9202c748 100644
--- a/tests/auto/network/kernel/qhostaddress/tst_qhostaddress.cpp
+++ b/tests/auto/network/kernel/qhostaddress/tst_qhostaddress.cpp
@@ -266,7 +266,7 @@ void tst_QHostAddress::specialAddresses_data()
QTest::newRow("null_1") << QString("") << (int)QHostAddress::Null << true;
QTest::newRow("null_2") << QString("bjarne") << (int)QHostAddress::Null << true;
-
+
QTest::newRow("compare_from_null") << QString("") << (int)QHostAddress::Broadcast << false;
QTest::newRow("broadcast_1") << QString("255.255.255.255") << (int)QHostAddress::Any << false;
diff --git a/tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp b/tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp
index 1b64f1dd73..7780b80179 100644
--- a/tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp
+++ b/tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp
@@ -91,11 +91,14 @@ void tst_QNetworkInterface::initTestCase()
QSKIP("No network test server available");
#ifndef QT_NO_BEARERMANAGEMENT
netConfMan = new QNetworkConfigurationManager(this);
- networkConfiguration = netConfMan->defaultConfiguration();
- networkSession.reset(new QNetworkSession(networkConfiguration));
- if (!networkSession->isOpen()) {
- networkSession->open();
- QVERIFY(networkSession->waitForOpened(30000));
+ if (netConfMan->capabilities()
+ & QNetworkConfigurationManager::NetworkSessionRequired) {
+ networkConfiguration = netConfMan->defaultConfiguration();
+ networkSession.reset(new QNetworkSession(networkConfiguration));
+ if (!networkSession->isOpen()) {
+ networkSession->open();
+ QVERIFY(networkSession->waitForOpened(30000));
+ }
}
#endif
}
diff --git a/tests/auto/network/kernel/qnetworkproxyfactory/tst_qnetworkproxyfactory.cpp b/tests/auto/network/kernel/qnetworkproxyfactory/tst_qnetworkproxyfactory.cpp
index 90e6797117..d57a99a758 100644
--- a/tests/auto/network/kernel/qnetworkproxyfactory/tst_qnetworkproxyfactory.cpp
+++ b/tests/auto/network/kernel/qnetworkproxyfactory/tst_qnetworkproxyfactory.cpp
@@ -105,7 +105,7 @@ QString tst_QNetworkProxyFactory::formatProxyName(const QNetworkProxy & proxy) c
{
QString proxyName;
if (!proxy.user().isNull())
- proxyName.append("%1:%2@").arg(proxy.user(), proxy.password());
+ proxyName.append(QString("%1:%2@").arg(proxy.user(), proxy.password()));
proxyName.append(QString("%1:%2").arg(proxy.hostName()).arg(proxy.port()));
proxyName.append(QString(" (type=%1, capabilities=%2)").arg(proxy.type()).arg(proxy.capabilities()));
diff --git a/tests/auto/network/socket/platformsocketengine/tst_platformsocketengine.cpp b/tests/auto/network/socket/platformsocketengine/tst_platformsocketengine.cpp
index 50952237fa..40f22d6d1e 100644
--- a/tests/auto/network/socket/platformsocketengine/tst_platformsocketengine.cpp
+++ b/tests/auto/network/socket/platformsocketengine/tst_platformsocketengine.cpp
@@ -139,7 +139,7 @@ void tst_PlatformSocketEngine::construction()
QVERIFY(socketDevice.error() == QAbstractSocket::UnknownSocketError);
QTest::ignoreMessage(QtWarningMsg, PLATFORMSOCKETENGINESTRING "::bytesAvailable() was called in QAbstractSocket::UnconnectedState");
- QVERIFY(socketDevice.bytesAvailable() == 0);
+ QVERIFY(socketDevice.bytesAvailable() == -1);
QTest::ignoreMessage(QtWarningMsg, PLATFORMSOCKETENGINESTRING "::hasPendingDatagrams() was called in QAbstractSocket::UnconnectedState");
QVERIFY(!socketDevice.hasPendingDatagrams());
diff --git a/tests/auto/network/socket/qlocalsocket/tst_qlocalsocket.cpp b/tests/auto/network/socket/qlocalsocket/tst_qlocalsocket.cpp
index 0ffcb60090..159f276c77 100644
--- a/tests/auto/network/socket/qlocalsocket/tst_qlocalsocket.cpp
+++ b/tests/auto/network/socket/qlocalsocket/tst_qlocalsocket.cpp
@@ -986,7 +986,7 @@ public:
if (!socket.waitForConnected(3000))
exec();
- connect(&socket, SIGNAL(bytesWritten(qint64)),
+ connect(&socket, SIGNAL(bytesWritten(qint64)),
this, SLOT(bytesWritten(qint64)), Qt::QueuedConnection);
socket.write("testing\n");
exec();
@@ -1004,9 +1004,9 @@ private:
signal.
Create a thread that will write to a socket.
- If the bytesWritten(qint64) signal is generated,
+ If the bytesWritten(qint64) signal is generated,
the slot connected to it will exit the thread,
- indicating test success.
+ indicating test success.
*/
void tst_QLocalSocket::bytesWrittenSignal()
diff --git a/tests/auto/network/socket/qtcpsocket/stressTest/Test.cpp b/tests/auto/network/socket/qtcpsocket/stressTest/Test.cpp
index 27f6640bdc..15ce1a0a12 100644
--- a/tests/auto/network/socket/qtcpsocket/stressTest/Test.cpp
+++ b/tests/auto/network/socket/qtcpsocket/stressTest/Test.cpp
@@ -48,7 +48,7 @@
#include "Test.h"
//------------------------------------------------------------------------------
-My4Socket::My4Socket(QObject *parent)
+My4Socket::My4Socket(QObject *parent)
: QTcpSocket(parent), safeShutDown(false)
{
connect(this, SIGNAL(readyRead()), this, SLOT(read()));
@@ -74,7 +74,7 @@ void My4Socket::read(void)
if (reply == 42)
++reply;
}
-
+
// Reply with a bigger number
sendTest(reply);
}
diff --git a/tests/auto/network/socket/qtcpsocket/stressTest/main.cpp b/tests/auto/network/socket/qtcpsocket/stressTest/main.cpp
index 8bbe351b45..4376e872e8 100644
--- a/tests/auto/network/socket/qtcpsocket/stressTest/main.cpp
+++ b/tests/auto/network/socket/qtcpsocket/stressTest/main.cpp
@@ -62,6 +62,6 @@ int main(int argc, char **argv)
}
Test test(type);
-
+
return app.exec();
}
diff --git a/tests/auto/network/socket/qtcpsocket/tst_qtcpsocket.cpp b/tests/auto/network/socket/qtcpsocket/tst_qtcpsocket.cpp
index a1082714f5..2b9dfc5081 100644
--- a/tests/auto/network/socket/qtcpsocket/tst_qtcpsocket.cpp
+++ b/tests/auto/network/socket/qtcpsocket/tst_qtcpsocket.cpp
@@ -238,7 +238,6 @@ private:
mutable int proxyAuthCalled;
- bool gotClosedSignal;
int numConnections;
static int loopLevel;
diff --git a/tests/auto/network/socket/qudpsocket/clientserver/main.cpp b/tests/auto/network/socket/qudpsocket/clientserver/main.cpp
index 233d9d1a1c..645aacf22e 100644
--- a/tests/auto/network/socket/qudpsocket/clientserver/main.cpp
+++ b/tests/auto/network/socket/qudpsocket/clientserver/main.cpp
@@ -79,7 +79,7 @@ public:
}
fflush(stdout);
- connect(this, SIGNAL(readyRead()), this, SLOT(readData()));
+ connect(this, SIGNAL(readyRead()), this, SLOT(readTestData()));
}
protected:
@@ -101,7 +101,7 @@ protected:
}
private slots:
- void readData()
+ void readTestData()
{
printf("readData()\n");
switch (type) {
diff --git a/tests/auto/network/socket/qudpsocket/udpServer/main.cpp b/tests/auto/network/socket/qudpsocket/udpServer/main.cpp
index 6d866c2aa7..47adac3e77 100644
--- a/tests/auto/network/socket/qudpsocket/udpServer/main.cpp
+++ b/tests/auto/network/socket/qudpsocket/udpServer/main.cpp
@@ -68,10 +68,10 @@ private slots:
qint64 bytes = serverSocket.readDatagram(data, sizeof(data), &senderAddress, &senderPort);
if (bytes == 1 && data[0] == '\0')
QCoreApplication::instance()->quit();
-
+
for (int i = 0; i < bytes; ++i)
data[i] += 1;
- serverSocket.writeDatagram(data, bytes, senderAddress, senderPort);
+ serverSocket.writeDatagram(data, bytes, senderAddress, senderPort);
}
private:
@@ -83,7 +83,7 @@ int main(int argc, char **argv)
QCoreApplication app(argc, argv);
Server server(app.arguments().at(1).toInt());
-
+
return app.exec();
}
diff --git a/tests/auto/network/ssl/qsslerror/tst_qsslerror.cpp b/tests/auto/network/ssl/qsslerror/tst_qsslerror.cpp
index 4f375c8ab3..73537d124f 100644
--- a/tests/auto/network/ssl/qsslerror/tst_qsslerror.cpp
+++ b/tests/auto/network/ssl/qsslerror/tst_qsslerror.cpp
@@ -81,7 +81,7 @@ public slots:
private slots:
void constructing();
#endif
-
+
private:
static int loopLevel;
};
diff --git a/tests/auto/network/ssl/qsslsocket/certs/ca.crt b/tests/auto/network/ssl/qsslsocket/certs/ca.crt
new file mode 100644
index 0000000000..5cbe8ef726
--- /dev/null
+++ b/tests/auto/network/ssl/qsslsocket/certs/ca.crt
@@ -0,0 +1,22 @@
+-----BEGIN CERTIFICATE-----
+MIIDpTCCAl2gAwIBAgIQAKraD9BoqaSa75qOqcP7ZTANBgkqhkiG9w0BAQUFADA8
+MQswCQYDVQQGEwJHQjEZMBcGA1UEChMQV2VzdHBvaW50IENBIEtleTESMBAGA1UE
+ChMJV2VzdHBvaW50MB4XDTEzMDIxNjE2NTMwOFoXDTIzMDIxNjE2NTMwOFowPDEL
+MAkGA1UEBhMCR0IxGTAXBgNVBAoTEFdlc3Rwb2ludCBDQSBLZXkxEjAQBgNVBAoT
+CVdlc3Rwb2ludDCCAVIwDQYJKoZIhvcNAQEBBQADggE/ADCCAToCggExAJv0H92j
+WjDB9h1DmSQzt772IPSirpE82sN9ls5J19TJcPnw49LdUUqkELJkpS1ty2hYPdUw
+7q3n00D+nzS+rt1QIDSKwDVoqeIyFZw4h0ULbASErfy51xBjVIr6NNoiqazp59wQ
+RDvqps7of+b/NcbOh73MsiYi8T5OoI4Quv9rMBefQTAI3d2NRQ4GUzS6Hzh2INOc
+4twApTDYY+yrU8IalXttIOVdKJZTHeTCdIXD3HMfHCkzyELz8rCI1/wDEp8zyoqF
+/tpBStZ5LUSrlRRM7PegqcnM+aojXyrEiXBvPuqO7tabU3nsfix9+8+7GDweDXsP
+OUHv+ahGNTUya7hBDaQmVk3/5hbig9kQlNiOcvcdnYYyJqiXhvjPPzOBbRaFNvBT
+uG/ehHNHYsdhEBkCAwEAAaNDMEEwDwYDVR0TAQH/BAUwAwEB/zAPBgNVHQ8BAf8E
+BQMDBwYAMB0GA1UdDgQWBBSUJzi1uYQUxqb3Nr33LOLCaUUTyTANBgkqhkiG9w0B
+AQUFAAOCATEAPeGh2GiIhT3cii3DU8ihd5TmnEstuHKz2FwHDChmen0zxE8lf08/
+onL1yIeaxbDA8KwZnv71/zZHJv02sPtIMUfuXQc0wOIFjDf0ngc6xIBuU7FUpLxF
+2dK7g9OsiNeC7L/ZemRXgpJURdNF2Ujge9/H9yfpHFBXZztmaWir+TXc5g3PKIu6
+97t75Og+stPhTcSlph8ZHYep08b2uthCfcnuIRGeDW9LkfR8VugnuUf7GoIlqSTs
+SR6bNuyTnnCHQMJzbsQ472+ag3aZS5HzoR8wyGiPmpc43lQM5ZEDrWGu8bub2gKa
+/+KeqHd0wnl7Y5cxnmAptQjxvzBXX/pl4sWczesiGcYm5z5mabp4CY09Y8JtrJZT
+IJodXy9ykRmEurgtRoRVc1aSp+xfV725bQ==
+-----END CERTIFICATE-----
diff --git a/tests/auto/network/ssl/qsslsocket/certs/inter.crt b/tests/auto/network/ssl/qsslsocket/certs/inter.crt
new file mode 100644
index 0000000000..4e1d67c3e0
--- /dev/null
+++ b/tests/auto/network/ssl/qsslsocket/certs/inter.crt
@@ -0,0 +1,22 @@
+-----BEGIN CERTIFICATE-----
+MIIDvDCCAnSgAwIBAgIQO+uZxerYC10Ll11PBnVL4TANBgkqhkiG9w0BAQUFADA8
+MQswCQYDVQQGEwJHQjEZMBcGA1UEChMQV2VzdHBvaW50IENBIEtleTESMBAGA1UE
+ChMJV2VzdHBvaW50MB4XDTEzMDIxNjE2NTMwOFoXDTIzMDIxNjE2NTMwOFowMjEL
+MAkGA1UEBhMCR0IxIzAhBgNVBAoTGldlc3Rwb2ludCBJbnRlcm1lZGlhdGUgS2V5
+MIIBUjANBgkqhkiG9w0BAQEFAAOCAT8AMIIBOgKCATEAsR4tRskg2IFfQFMfGBJ1
+eqlrNejANw0oM6k5HlEB8uFA9qeyAzmflwQUPoJ55KRQ/gVHTOBdWrtgGgPMiekF
+1Q36Ry1elwbAl4a+LZ6qsc9ASipvk8HirKpt1v5L9hG+aI4yDxyvjNztFtg5R4P5
+zqsh/WwhCgsYmEVfcSDbhUjqoqxGRLaZxPKO+IMCNFrjZqi0yxc8f6Un4G5SQzHA
+4szi/ezcITnAFYWxHG2yaed4hawpxNS1WXabk2rzCi0pWeIcHuIczaCfZ7ElRcqV
+VNNXbGTtUDlfIsh6FAVI5kTUDcPV27uf6BmHuFOu/R9Tjni25+vBFvohwQh7ZwCX
+5COXnfkJLPkJQQEFVQv8nS27ht/vmyoKjERUeiuMd+hFcN5zl7bS5A2JCgi7erlP
+ZQIDAQABo2QwYjAPBgNVHRMBAf8EBTADAQH/MA8GA1UdDwEB/wQFAwMHBgAwHQYD
+VR0OBBYEFGn5shQ0SeTcc3x/cNu6TkoV0bPmMB8GA1UdIwQYMBaAFJQnOLW5hBTG
+pvc2vfcs4sJpRRPJMA0GCSqGSIb3DQEBBQUAA4IBMQAVDS0enQQ1FL0d92xOFfwx
+mjcNPz9oO7jMyEVxAs2eR2QD+xZ3Xj4gAiUEp40aGieDcLv+dg+cmuBFWF61IYSR
+UyuoakVm08VDcLAwUzU+xtSvJiSSROb0GsAnVsYZj4TYlvKDplqfapOYaiIkwF+c
+iE4n7G0hQW9fzqO+n3FGtBD8YUjghRqLggeRVJ2+8S3Bm8cfx8xPpRIO3ksA6opn
+CORRGuzetDHihbks59mkoY3GqKFgBOyrC3kG07nv5wtKjdKDtmD/kS/SAc4fIXKy
+Uruq2uXNf/1BUgF5gFGRyj22yB2D0763fJJpl5nqcLrL5RmnVObQKZGhE2VsRTV0
+untj+AmiJivhiAjjkHfw3XDf8tuL7D4pTmEkGgl5xl23fyeTIuygDCLT8fRD3ZqQ
+-----END CERTIFICATE-----
diff --git a/tests/auto/network/ssl/qsslsocket/certs/leaf.crt b/tests/auto/network/ssl/qsslsocket/certs/leaf.crt
new file mode 100644
index 0000000000..4a7dc40540
--- /dev/null
+++ b/tests/auto/network/ssl/qsslsocket/certs/leaf.crt
@@ -0,0 +1,23 @@
+-----BEGIN CERTIFICATE-----
+MIID3zCCApegAwIBAgIQEKCtd1j2bq5Gk6ND+VmKnjANBgkqhkiG9w0BAQUFADAy
+MQswCQYDVQQGEwJHQjEjMCEGA1UEChMaV2VzdHBvaW50IEludGVybWVkaWF0ZSBL
+ZXkwHhcNMTMwMjE2MTY1MzA4WhcNMjMwMjE2MTY1MzA4WjA1MQswCQYDVQQGEwJH
+QjESMBAGA1UEChMJV2VzdHBvaW50MRIwEAYDVQQDEwkxMjcuMC4wLjEwggFSMA0G
+CSqGSIb3DQEBAQUAA4IBPwAwggE6AoIBMQC7EIWIzb7XCfmQQ1KFdZ5E9f49eNK/
+KvsXYfq/iV29K1cz2hUyvfdKgyU5F/+BOPQKQ5zdWn1CraZosFv/ibuO3mhRpMfB
+SfNn3rfdrE7WtA0wgT2YNIN0L4aCe+C15j2ESdmyMaFLUaUIS47JS66UtaYxp5ia
+mJFO1hSNaoI0pGHyPFTTtfOza9z/01qkBbHB4htzauqs/fX5ZrnyCDSrfpVipXke
+zkPKg4MkkytEkjRKw6tSXLpWIgF3ee2N/jBdefqlw8YPW08K0wmwF5qGuX6PZ8vB
+sOZeWeCfVr136BopkbfP3TkGWw2BrD8xSzOUez9HVc0v4SZ/7pe5w3L4V/mzYQLt
+O+1AHevCjX8+M58HYGBaWCAjxYUPGcGKcj0LLtgZgL6wY88N7RtfeOY3AgMBAAGj
+gY0wgYowFAYDVR0RBA0wC4IJMTI3LjAuMC4xMAwGA1UdEwEB/wQCMAAwEwYDVR0l
+BAwwCgYIKwYBBQUHAwEwDwYDVR0PAQH/BAUDAwcoADAdBgNVHQ4EFgQUKKuyJSrT
+Y+dnm1do7l0sVMX96SYwHwYDVR0jBBgwFoAUafmyFDRJ5NxzfH9w27pOShXRs+Yw
+DQYJKoZIhvcNAQEFBQADggExAHELijlIFdcncP3B+vxEp0SGKl0arIaCXahivb2F
+VxeM3WajN6O+oDRLFltzMeDKA9RVkao7fgITzXQgCGzeNhKv0vc9iDyvR9/67vuS
+W8xEEJrYowtw3VK5H1y0ewqZaxJhvKUjm4TBRWe8FGKD3s64lEsfbjOaI5VPidVc
+DXmdAlXsj0Hk+v4Ej8mshPQAnVSyJ3D0ZMgTjk8Di28N0qROFIYJaTObK1rCb1nQ
+GaCcmbZU6JnkYvVZ+iUe5U0GXFbb+LRNTUT8/fw1zADeHnv/G+WWVrfND+sov5Oc
+33fkNE6z+n6ayABVnGLuCYhbzD38sv0dnxeh8vbykNBPzYdzPg6nw3Czv2vlhKpJ
+8Yj/maoXuAyTXVf30K1/fAWyU45noq57MjQpU6UxIX1D7qw=
+-----END CERTIFICATE-----
diff --git a/tests/auto/network/ssl/qsslsocket/certs/leaf.key b/tests/auto/network/ssl/qsslsocket/certs/leaf.key
new file mode 100644
index 0000000000..54327925d8
--- /dev/null
+++ b/tests/auto/network/ssl/qsslsocket/certs/leaf.key
@@ -0,0 +1,32 @@
+-----BEGIN RSA PRIVATE KEY-----
+MIIFfAIBAAKCATEAuxCFiM2+1wn5kENShXWeRPX+PXjSvyr7F2H6v4ldvStXM9oV
+Mr33SoMlORf/gTj0CkOc3Vp9Qq2maLBb/4m7jt5oUaTHwUnzZ9633axO1rQNMIE9
+mDSDdC+GgnvgteY9hEnZsjGhS1GlCEuOyUuulLWmMaeYmpiRTtYUjWqCNKRh8jxU
+07Xzs2vc/9NapAWxweIbc2rqrP31+Wa58gg0q36VYqV5Hs5DyoODJJMrRJI0SsOr
+Uly6ViIBd3ntjf4wXXn6pcPGD1tPCtMJsBeahrl+j2fLwbDmXlngn1a9d+gaKZG3
+z905BlsNgaw/MUszlHs/R1XNL+Emf+6XucNy+Ff5s2EC7TvtQB3rwo1/PjOfB2Bg
+WlggI8WFDxnBinI9Cy7YGYC+sGPPDe0bX3jmNwIDAQABAoIBMQCczBNyAStGqjjC
+oHuKHHWmTh9mPWFBFfDTv6/jXmvxRWPZtaHxH2Qp09Wejqv/D9MWy2ev7spx2oZS
+2Ai1ICjTbz83uAwryyW4Wen6aBTJSLCJiLstWk8ZU0DHHLjVH4FO4mwUPh95t5zC
+YDr2JXbXdY8xrc5vPxUFZNJjWvR61ZK37bQYpTn5mZ7r3KfsNk2yOylRTDwa9XFo
+ZZ+B82NKdrrz0UvGOnXZa5qd1ap7V+67FIAS2Mt8AMzSCG8TW0JXRUk89ISgAd8r
+NQTPtX9XCnMZSbBzDKdznXfHS9ZlJcSrpsbQCPcvMVNrdBfCF0eNnsRJffJGdaXI
+MsN6PvbcXWD08lXNGyeLjon03RdJnTAamNM3YQEIcjFmu5Y0o0CCJkZSCJPKJGMG
+0d/1tN/5AoGZANOcOgQZ9Wiu0ej3YoQ3aSHu3y8ZBJH4B3ViX8i+2x/6UnG7KNaa
+4Ygid1upnX6hk4CW5WZcoxGFacrFRpInKh5Ng8lEIHGp0VSzOBVDR0L5sAxutFuX
+6N9C0CuH80vD101mOloNnfT5KHZMI5RXqP6sDGUFlwak2XybDL1qOAza3gZAy25H
+vS/ll1BneBavikR5j+zxoTztAoGZAOJOJ5RyOrqpNuhiWZylah5LIFT9N1lCF4Hl
+ZbFIjUZ4jcApJ7JxkMXNQ4RU/3AiKCC1xr5ib7dd/qyjKXhdMo4SnLoKhapx5R9G
+3XOsQMahiCD/Zcymv9tmk8MxxzbLxhZYhEPzIP/NFkua3CHiX+d1e6fkzFLF/EiX
+ZGQOgRcFKrlzUeBputRQRXAkKJH+kMClgAWvy28zAoGYKyaMXhG9DV+4xjzMBhIW
+iijfsgbz+6AMRU+OIK1qmZa+ARsdNMXYf54noLVxvETOg0ZB+SGizwvZitO3lE4Q
+NKWx3fTaeNMcMJ1rLkrN2UZ5M8/PT24muoAxWu8aGbURzmKuO3bTYwT7z0OvbayC
+dYw36tG8/knXX6Vub6GdVGG9LKFB2nceiQnUVT0EK/wXwebYBoUvT/ECgZgF9qdG
+Wyg/CPyAbS8NWLKOL86fTrjpqjsyWhgu7smCROT/XlZEdoepHrqbvx2oF85U5lVh
+aPimrVxrsjUCjfoqEkV9BY/2KOAvzc9CIBTo5xLOQ8yr8uz1XCOiriogwIfsyNJb
+dAm3k/D1dxQ79FowoEDs8LONrtfyFcM4e8VdFO7GSkqrDj41IBRkWx+SkVHBMdtI
+yxQiTwKBmQCWym2iDCJg1ZZq4/lVwRudMhVmHoD0yoCAwADYHjjAi8QBplM0vfdd
+CESKsnBhlcrPGB279BKVJyZHehKZG+/dfnFs+to14l6A3IqU2d6+pu3EyFNX34HS
+xo+64QxMeF0akWnSaIPfUJfk36phjCvLBr4eLXN1i4jW3RdGFwF1THXt29VSSGmU
+q/hM51H0bsQ13AIVUSdNHA==
+-----END RSA PRIVATE KEY-----
diff --git a/tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp b/tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp
index e950ae1d28..feb6978690 100644
--- a/tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp
+++ b/tests/auto/network/ssl/qsslsocket/tst_qsslsocket.cpp
@@ -142,6 +142,8 @@ private slots:
void protocolServerSide();
void setCaCertificates();
void setLocalCertificate();
+ void localCertificateChain();
+ void setLocalCertificateChain();
void setPrivateKey();
void setSocketDescriptor();
void setSslConfiguration_data();
@@ -929,15 +931,20 @@ class SslServer : public QTcpServer
{
Q_OBJECT
public:
- SslServer(const QString &keyFile = SRCDIR "certs/fluke.key", const QString &certFile = SRCDIR "certs/fluke.cert")
+ SslServer(const QString &keyFile = SRCDIR "certs/fluke.key",
+ const QString &certFile = SRCDIR "certs/fluke.cert",
+ const QString &interFile = QString())
: socket(0),
protocol(QSsl::TlsV1_0),
m_keyFile(keyFile),
- m_certFile(certFile) { }
+ m_certFile(certFile),
+ m_interFile(interFile)
+ { }
QSslSocket *socket;
QSsl::SslProtocol protocol;
QString m_keyFile;
QString m_certFile;
+ QString m_interFile;
protected:
void incomingConnection(qintptr socketDescriptor)
@@ -952,10 +959,24 @@ protected:
QVERIFY(!key.isNull());
socket->setPrivateKey(key);
- QList<QSslCertificate> localCert = QSslCertificate::fromPath(m_certFile);
- QVERIFY(!localCert.isEmpty());
- QVERIFY(localCert.first().handle());
- socket->setLocalCertificate(localCert.first());
+ // If we have a cert issued directly from the CA
+ if (m_interFile.isEmpty()) {
+ QList<QSslCertificate> localCert = QSslCertificate::fromPath(m_certFile);
+ QVERIFY(!localCert.isEmpty());
+ QVERIFY(localCert.first().handle());
+ socket->setLocalCertificate(localCert.first());
+ }
+ else {
+ QList<QSslCertificate> localCert = QSslCertificate::fromPath(m_certFile);
+ QVERIFY(!localCert.isEmpty());
+ QVERIFY(localCert.first().handle());
+
+ QList<QSslCertificate> interCert = QSslCertificate::fromPath(m_interFile);
+ QVERIFY(!interCert.isEmpty());
+ QVERIFY(interCert.first().handle());
+
+ socket->setLocalCertificateChain(localCert + interCert);
+ }
QVERIFY(socket->setSocketDescriptor(socketDescriptor, QAbstractSocket::ConnectedState));
QVERIFY(!socket->peerAddress().isNull());
@@ -1102,6 +1123,55 @@ void tst_QSslSocket::setLocalCertificate()
{
}
+void tst_QSslSocket::localCertificateChain()
+{
+ if (!QSslSocket::supportsSsl())
+ return;
+
+ QSslSocket socket;
+ socket.setLocalCertificate(QLatin1String(SRCDIR "certs/fluke.cert"));
+
+ QSslConfiguration conf = socket.sslConfiguration();
+ QList<QSslCertificate> chain = conf.localCertificateChain();
+ QCOMPARE(chain.size(), 1);
+ QCOMPARE(chain[0], conf.localCertificate());
+ QCOMPARE(chain[0], socket.localCertificate());
+}
+
+void tst_QSslSocket::setLocalCertificateChain()
+{
+ if (!QSslSocket::supportsSsl())
+ return;
+
+ QFETCH_GLOBAL(bool, setProxy);
+ if (setProxy)
+ return;
+
+ SslServer server(QLatin1String(SRCDIR "certs/leaf.key"),
+ QLatin1String(SRCDIR "certs/leaf.crt"),
+ QLatin1String(SRCDIR "certs/inter.crt"));
+
+ QVERIFY(server.listen());
+
+ QEventLoop loop;
+ QTimer::singleShot(5000, &loop, SLOT(quit()));
+
+ socket = new QSslSocket();
+ connect(socket, SIGNAL(encrypted()), &loop, SLOT(quit()));
+ connect(socket, SIGNAL(error(QAbstractSocket::SocketError)), &loop, SLOT(quit()));
+ connect(socket, SIGNAL(sslErrors(QList<QSslError>)), this, SLOT(ignoreErrorSlot()));
+
+ socket->connectToHostEncrypted(QHostAddress(QHostAddress::LocalHost).toString(), server.serverPort());
+ loop.exec();
+
+ QList<QSslCertificate> chain = socket->peerCertificateChain();
+ QCOMPARE(chain.size(), 2);
+ QCOMPARE(chain[0].serialNumber(), QByteArray("10:a0:ad:77:58:f6:6e:ae:46:93:a3:43:f9:59:8a:9e"));
+ QCOMPARE(chain[1].serialNumber(), QByteArray("3b:eb:99:c5:ea:d8:0b:5d:0b:97:5d:4f:06:75:4b:e1"));
+
+ socket->deleteLater();
+}
+
void tst_QSslSocket::setPrivateKey()
{
}
@@ -1535,6 +1605,8 @@ public slots:
void tst_QSslSocket::setReadBufferSize_task_250027()
{
+ QSKIP("QTBUG-29730 - flakey test blocking integration");
+
// do not execute this when a proxy is set.
QFETCH_GLOBAL(bool, setProxy);
if (setProxy)
@@ -1571,7 +1643,14 @@ void tst_QSslSocket::setReadBufferSize_task_250027()
setReadBufferSize_task_250027_handler.waitSomeMore(socket.data());
QByteArray secondRead = socket->readAll();
// second read should be some more data
- QVERIFY(secondRead.size() > 0);
+
+ int secondReadSize = secondRead.size();
+
+ if (secondReadSize <= 0) {
+ QEXPECT_FAIL("", "QTBUG-29730", Continue);
+ }
+
+ QVERIFY(secondReadSize > 0);
socket->close();
}
diff --git a/tests/auto/opengl/qgl/tst_qgl.cpp b/tests/auto/opengl/qgl/tst_qgl.cpp
index d4d109b981..00973cf533 100644
--- a/tests/auto/opengl/qgl/tst_qgl.cpp
+++ b/tests/auto/opengl/qgl/tst_qgl.cpp
@@ -78,7 +78,6 @@ private slots:
void shareRegister();
void textureCleanup();
#endif
- void graphicsViewClipping();
void partialGLWidgetUpdates_data();
void partialGLWidgetUpdates();
void glWidgetWithAlpha();
@@ -98,6 +97,7 @@ private slots:
void destroyFBOAfterContext();
void threadImages();
void nullRectCrash();
+ void graphicsViewClipping();
};
tst_QGL::tst_QGL()
@@ -874,7 +874,7 @@ void tst_QGL::graphicsViewClipping()
scene.setSceneRect(view.viewport()->rect());
- QTest::qWaitForWindowExposed(&view);
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
QTRY_VERIFY(widget->painted);
diff --git a/tests/auto/opengl/qglbuffer/tst_qglbuffer.cpp b/tests/auto/opengl/qglbuffer/tst_qglbuffer.cpp
index 475054940b..915f503b3f 100644
--- a/tests/auto/opengl/qglbuffer/tst_qglbuffer.cpp
+++ b/tests/auto/opengl/qglbuffer/tst_qglbuffer.cpp
@@ -202,6 +202,11 @@ void tst_QGLBuffer::testBuffer(QGLBuffer::Type type)
void tst_QGLBuffer::bufferSharing()
{
+#if defined(Q_OS_WIN)
+ // Needs investigation on Windows: https://bugreports.qt-project.org/browse/QTBUG-29692
+ QSKIP("Unreproducible timeout on Windows (MSVC/MinGW) CI bots");
+#endif
+
QGLWidget *w1 = new QGLWidget();
w1->makeCurrent();
diff --git a/tests/auto/other/collections/tst_collections.cpp b/tests/auto/other/collections/tst_collections.cpp
index e145cc17df..df622602c3 100644
--- a/tests/auto/other/collections/tst_collections.cpp
+++ b/tests/auto/other/collections/tst_collections.cpp
@@ -3359,7 +3359,7 @@ void testVectorAlignment()
for (int i = 0; i < 200; ++i)
container.append(Aligned());
-
+
for (int i = 0; i < container.size(); ++i)
QCOMPARE(quintptr(&container.at(i)) % Aligned::PreferredAlignment, quintptr(0));
}
diff --git a/tests/auto/other/lancelot/lancelot.pro b/tests/auto/other/lancelot/lancelot.pro
index b577e0dbc9..ef557691e3 100644
--- a/tests/auto/other/lancelot/lancelot.pro
+++ b/tests/auto/other/lancelot/lancelot.pro
@@ -1,5 +1,6 @@
CONFIG += testcase
CONFIG += parallel_test
+CONFIG -= app_bundle
TARGET = tst_lancelot
QT += xml widgets testlib
diff --git a/tests/auto/other/lancelot/scripts/background.qps b/tests/auto/other/lancelot/scripts/background.qps
index 000cfcdd91..d1efe5c178 100644
--- a/tests/auto/other/lancelot/scripts/background.qps
+++ b/tests/auto/other/lancelot/scripts/background.qps
@@ -14,12 +14,12 @@ path_lineTo path 0 50
bitmap_load bitmap.png bitmap
begin_block drawing
- save
+ save
drawRect 0 0 50 50
translate 60 0
drawEllipse 0 0 50 50
-
+
translate 60 0
drawPolygon [0 0 50 0 25 50 25 25]
@@ -28,9 +28,9 @@ begin_block drawing
translate 60 0
drawPie 0 0 50 50 1440 2000
-
+
translate 60 0
- drawChord 0 0 50 50 1440 2000
+ drawChord 0 0 50 50 1440 2000
translate 60 0
drawLine 0 0 50 0
@@ -44,10 +44,10 @@ begin_block drawing
drawArc 0 0 50 50 1440 2000
translate 60 0
- drawText 0 10 "Jambi-Bambi"
+ drawText 0 10 "Jambi-Bambi"
translate 80 0
- drawPixmap bitmap 0 0
+ drawPixmap bitmap 0 0
restore
save
@@ -57,7 +57,7 @@ begin_block drawing
translate 60 0
drawEllipse 0 0 50 50
-
+
translate 60 0
drawPolygon [0 0 50 0 25 50 25 25]
@@ -66,9 +66,9 @@ begin_block drawing
translate 60 0
drawPie 0 0 50 50 1440 2000
-
+
translate 60 0
- drawChord 0 0 50 50 1440 2000
+ drawChord 0 0 50 50 1440 2000
translate 60 0
drawLine 0 0 50 0
@@ -82,10 +82,10 @@ begin_block drawing
drawArc 0 0 50 50 1440 2000
translate 60 0
- drawText 0 10 "Jambi-Bambi"
+ drawText 0 10 "Jambi-Bambi"
translate 80 0
- drawPixmap bitmap 0 0
+ drawPixmap bitmap 0 0
restore
end_block
@@ -102,12 +102,12 @@ repeat_block drawing
translate 0 160
setBackgroundMode Transparent
setPen ff7f7f 4 dashline flatcap beveljoin
-repeat_block drawing
+repeat_block drawing
translate 0 160
setBackgroundMode OpaqueMode
setPen ff7f7f 4 dashline flatcap beveljoin
-repeat_block drawing
+repeat_block drawing
resetMatrix
diff --git a/tests/auto/other/lancelot/scripts/bitmaps.qps b/tests/auto/other/lancelot/scripts/bitmaps.qps
index a816b9d497..4966490337 100644
--- a/tests/auto/other/lancelot/scripts/bitmaps.qps
+++ b/tests/auto/other/lancelot/scripts/bitmaps.qps
@@ -122,12 +122,12 @@ translate 110 0
save
translate 20 -10
rotate 10
- setBackgroundMode Transparent
+ setBackgroundMode Transparent
repeat_block draw_subrected
restore
translate 110 0
-save
+save
translate 20 -10
rotate 10
setBackgroundMode Opaque
diff --git a/tests/auto/other/lancelot/scripts/clippaths.qps b/tests/auto/other/lancelot/scripts/clippaths.qps
index fba89784df..fe8e198a17 100644
--- a/tests/auto/other/lancelot/scripts/clippaths.qps
+++ b/tests/auto/other/lancelot/scripts/clippaths.qps
@@ -4,7 +4,7 @@
path_addRect hor 0 0 50 10
path_addRect ver 0 0 10 50
-translate 10 10
+translate 10 10
setPen NoPen
begin_block clipping
@@ -13,7 +13,7 @@ save
setBrush 0x7f7fff
save
setClipPath hor
- drawRect 0 0 100 100
+ drawRect 0 0 100 100
setClipPath ver IntersectClip
setBrush black CrossPattern
@@ -21,18 +21,18 @@ save
restore
translate 100 0
- save
+ save
setClipPath hor
drawRect 0 0 100 100
setClipPath ver ReplaceClip
setBrush black CrossPattern
- drawRect 0 0 100 100
+ drawRect 0 0 100 100
restore
translate 100 0
- save
- setClipPath hor
+ save
+ setClipPath hor
drawRect 0 0 100 100
setClipPath ver UniteClip
diff --git a/tests/auto/other/lancelot/scripts/cliprects.qps b/tests/auto/other/lancelot/scripts/cliprects.qps
index 0d28b035b4..aa0367eccf 100644
--- a/tests/auto/other/lancelot/scripts/cliprects.qps
+++ b/tests/auto/other/lancelot/scripts/cliprects.qps
@@ -3,7 +3,7 @@
-translate 10 10
+translate 10 10
setPen NoPen
begin_block clipping
@@ -11,8 +11,8 @@ save
setBrush 0x7f7fff
save
- setClipRect 0 0 50 10
- drawRect 0 0 100 100
+ setClipRect 0 0 50 10
+ drawRect 0 0 100 100
setClipRect 0 0 10 50 IntersectClip
setBrush black CrossPattern
@@ -20,17 +20,17 @@ save
restore
translate 100 0
- save
+ save
setClipRect 0 0 50 10
drawRect 0 0 100 100
setClipRect 0 0 10 50 ReplaceClip
setBrush black CrossPattern
- drawRect 0 0 100 100
+ drawRect 0 0 100 100
restore
translate 100 0
- save
+ save
setClipRect 0 0 50 10
drawRect 0 0 100 100
diff --git a/tests/auto/other/lancelot/scripts/conical_gradients.qps b/tests/auto/other/lancelot/scripts/conical_gradients.qps
index 2e897b1813..d6eb860f3f 100644
--- a/tests/auto/other/lancelot/scripts/conical_gradients.qps
+++ b/tests/auto/other/lancelot/scripts/conical_gradients.qps
@@ -64,7 +64,7 @@ setBrush nobrush
begin_block ellipse_draw
setClipRect 0 0 100 100
drawEllipse 35 35 11 11
- save
+ save
translate 40 40
rotate -50
drawLine -100 0 100 0
diff --git a/tests/auto/other/lancelot/scripts/dashes.qps b/tests/auto/other/lancelot/scripts/dashes.qps
index 649f56cf66..185443a292 100644
--- a/tests/auto/other/lancelot/scripts/dashes.qps
+++ b/tests/auto/other/lancelot/scripts/dashes.qps
@@ -15,7 +15,7 @@ save
setPen black 1 SolidLine RoundCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
-
+
setPen black 2 SolidLine FlatCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
@@ -25,7 +25,7 @@ save
setPen black 2 SolidLine RoundCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
-
+
setPen black 6 SolidLine FlatCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
@@ -36,8 +36,8 @@ save
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
restore
-
-
+
+
translate 100 0
save
setPen black 1 DotLine FlatCap BevelJoin
@@ -49,7 +49,7 @@ save
setPen black 1 DotLine RoundCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
-
+
setPen black 2 DotLine FlatCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
@@ -59,7 +59,7 @@ save
setPen black 2 DotLine RoundCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
-
+
setPen black 6 DotLine FlatCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
@@ -70,7 +70,7 @@ save
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
restore
-
+
translate 100 0
save
setPen black 1 DashLine FlatCap BevelJoin
@@ -82,7 +82,7 @@ save
setPen black 1 DashLine RoundCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
-
+
setPen black 2 DashLine FlatCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
@@ -92,7 +92,7 @@ save
setPen black 2 DashLine RoundCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
-
+
setPen black 6 DashLine FlatCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
@@ -103,9 +103,9 @@ save
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
restore
-
+
translate 100 0
-
+
save
setPen black 1 DashDotLine FlatCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
@@ -116,7 +116,7 @@ save
setPen black 1 DashDotLine RoundCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
-
+
setPen black 2 DashDotLine FlatCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
@@ -126,7 +126,7 @@ save
setPen black 2 DashDotLine RoundCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
-
+
setPen black 6 DashDotLine FlatCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
@@ -137,7 +137,7 @@ save
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
restore
-
+
translate 100 0
save
@@ -150,7 +150,7 @@ save
setPen black 1 DashDotDotLine RoundCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
-
+
setPen black 2 DashDotDotLine FlatCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
@@ -160,7 +160,7 @@ save
setPen black 2 DashDotDotLine RoundCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
-
+
setPen black 4 DashDotDotLine FlatCap BevelJoin
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
@@ -187,7 +187,7 @@ save
pen_setDashPattern [1 4 9 4 27 4]
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
-
+
setPen black 2 SolidLine FlatCap BevelJoin
pen_setDashPattern [1 4 9 4 27 4]
drawPolyline [0 0 80 0 80 30 40 20 0 30]
@@ -200,7 +200,7 @@ save
pen_setDashPattern [1 4 9 4 27 4]
drawPolyline [0 0 80 0 80 30 40 20 0 30]
translate 0 40
-
+
setPen black 4 SolidLine FlatCap BevelJoin
pen_setDashPattern [1 4 9 4 27 4]
drawPolyline [0 0 80 0 80 30 40 20 0 30]
@@ -217,7 +217,7 @@ save
restore
end_block
-
+
translate 0 400
setRenderHint Antialiasing
repeat_block draw
diff --git a/tests/auto/other/lancelot/scripts/deviceclipping.qps b/tests/auto/other/lancelot/scripts/deviceclipping.qps
index cedfc1e363..8608a50994 100644
--- a/tests/auto/other/lancelot/scripts/deviceclipping.qps
+++ b/tests/auto/other/lancelot/scripts/deviceclipping.qps
@@ -22,7 +22,7 @@ begin_block drawing
drawRect 300 -500000 1000000 1000000
drawPath path
-
+
end_block
save
diff --git a/tests/auto/other/lancelot/scripts/pixmap_scaling.qps b/tests/auto/other/lancelot/scripts/pixmap_scaling.qps
index 651896f4a3..8a5ab2c60e 100644
--- a/tests/auto/other/lancelot/scripts/pixmap_scaling.qps
+++ b/tests/auto/other/lancelot/scripts/pixmap_scaling.qps
@@ -8,8 +8,8 @@
translate 5 25
setFont "arial" 8
-save
- drawText 15 0 "opaque image"
+save
+ drawText 15 0 "opaque image"
translate 50 50
save
translate 1 1
@@ -21,23 +21,23 @@ save
scale -20 20
drawImage solid2x2.png 0 0
restore
- save
+ save
translate 1 -1
scale 20 -20
drawImage solid2x2.png 0 0
restore
- save
+ save
translate -1 -1
scale -20 -20
drawImage solid2x2.png 0 0
restore
-
-restore
+
+restore
save
translate 150 0
- drawText 15 0 "alpha image"
+ drawText 15 0 "alpha image"
translate 50 50
save
translate 1 1
@@ -49,12 +49,12 @@ save
scale -20 20
drawImage alpha2x2.png 0 0
restore
- save
+ save
translate 1 -1
scale 20 -20
drawImage alpha2x2.png 0 0
restore
- save
+ save
translate -1 -1
scale -20 -20
drawImage alpha2x2.png 0 0
@@ -64,7 +64,7 @@ restore
save
translate 0 150
- drawText 15 0 "solid pixmap"
+ drawText 15 0 "solid pixmap"
translate 50 50
save
translate 1 1
@@ -76,12 +76,12 @@ save
scale -20 20
drawPixmap solid2x2.png 0 0
restore
- save
+ save
translate 1 -1
scale 20 -20
drawPixmap solid2x2.png 0 0
restore
- save
+ save
translate -1 -1
scale -20 -20
drawPixmap solid2x2.png 0 0
@@ -90,9 +90,9 @@ restore
save
- translate 150 150
+ translate 150 150
drawText 15 0 "alpha pixmap"
- translate 50 50
+ translate 50 50
save
translate 1 1
scale 20 20
@@ -103,12 +103,12 @@ save
scale -20 20
drawPixmap alpha2x2.png 0 0
restore
- save
+ save
translate 1 -1
scale 20 -20
drawPixmap alpha2x2.png 0 0
restore
- save
+ save
translate -1 -1
scale -20 -20
drawPixmap alpha2x2.png 0 0
@@ -116,7 +116,7 @@ save
restore
-save
+save
translate 300 10
save
drawText 0 -10 "subrect solid image"
@@ -143,7 +143,7 @@ save
drawImage solid2x2.png 45 0 5 50 1.8 0 0.2 2
restore
- save
+ save
translate 150 0
drawText 0 -10 "subrect solid image"
drawImage alpha2x2.png 0 0 50 5 0 0.0 2 0.2
@@ -156,7 +156,7 @@ save
drawImage alpha2x2.png 0 35 50 5 0 1.4 2 0.2
drawImage alpha2x2.png 0 40 50 5 0 1.6 2 0.2
drawImage alpha2x2.png 0 45 50 5 0 1.8 2 0.2
- translate 60 0
+ translate 60 0
drawImage alpha2x2.png 0 0 5 50 0.0 0 0.2 2
drawImage alpha2x2.png 5 0 5 50 0.2 0 0.2 2
drawImage alpha2x2.png 10 0 5 50 0.4 0 0.2 2
diff --git a/tests/auto/other/lancelot/scripts/pixmap_subpixel.qps b/tests/auto/other/lancelot/scripts/pixmap_subpixel.qps
index 908f7c3465..d5b7b92fc9 100644
--- a/tests/auto/other/lancelot/scripts/pixmap_subpixel.qps
+++ b/tests/auto/other/lancelot/scripts/pixmap_subpixel.qps
@@ -6,7 +6,7 @@ translate 50 50
# Pixmaps at 0.1 offset, unclipped
begin_block draw_pixmaps
-save
+save
drawPixmap border.png 0 0
translate 20.1 0.1
drawPixmap border.png 0 0
@@ -27,7 +27,7 @@ save
translate 20.1 0.1
drawPixmap border.png 0 0
translate 20.1 0.1
-
+
drawPixmap border.png 0 0
translate 20.1 0.1
drawPixmap border.png 0 0
@@ -49,12 +49,12 @@ save
drawPixmap border.png 0 0
translate 20.1 0.1
restore
-end_block
+end_block
# Tiled pixmaps at 0.1 offsets, unclipped
translate 0 50
begin_block draw_tiled
-save
+save
drawTiledPixmap border.png 0 0 16 16 0 0
translate 20.1 0.1
drawTiledPixmap border.png 0 0 16 16 0 0
@@ -75,7 +75,7 @@ save
translate 20.1 0.1
drawTiledPixmap border.png 0 0 16 16 0 0
translate 20.1 0.1
-
+
drawTiledPixmap border.png 0 0 16 16 0 0
translate 20.1 0.1
drawTiledPixmap border.png 0 0 16 16 0 0
@@ -97,7 +97,7 @@ save
drawTiledPixmap border.png 0 0 16 16 0 0
translate 20.1 0.1
restore
-end_block
+end_block
path_moveTo clip 0 0
diff --git a/tests/auto/other/lancelot/scripts/pixmaps.qps b/tests/auto/other/lancelot/scripts/pixmaps.qps
index 8e60997acc..0b4ba2c4fb 100644
--- a/tests/auto/other/lancelot/scripts/pixmaps.qps
+++ b/tests/auto/other/lancelot/scripts/pixmaps.qps
@@ -15,13 +15,13 @@ save
drawPixmap the_pixmap 0 0
# sub recting
- translate 120 0
+ translate 120 0
drawPixmap the_pixmap 0 0 40 40 0 0 40 40
drawPixmap the_pixmap 60 0 40 40 60 0 40 40
drawPixmap the_pixmap 0 60 40 40 0 60 40 40
drawPixmap the_pixmap 60 60 40 40 60 60 40 40
drawPixmap the_pixmap 0 40 40 20 0 40 40 20
- drawPixmap the_pixmap 60 40 40 20 60 40 40 20
+ drawPixmap the_pixmap 60 40 40 20 60 40 40 20
drawPixmap the_pixmap 40 0 20 100 40 0 20 100
# subrecting w/scale
@@ -30,15 +30,15 @@ save
drawPixmap the_pixmap 50 0 50 50 25 0 25 25
drawPixmap the_pixmap 0 50 50 50 0 25 25 25
drawPixmap the_pixmap 50 50 50 50 25 25 25 25
-
+
# subrecting w/scale & smooth xform
translate 120 0
- setRenderHint SmoothPixmapTransformation
+ setRenderHint SmoothPixmapTransformation
drawPixmap the_pixmap 0 0 50 50 0 0 25 25
drawPixmap the_pixmap 50 0 50 50 25 0 25 25
drawPixmap the_pixmap 0 50 50 50 0 25 25 25
drawPixmap the_pixmap 50 50 50 50 25 25 25 25
-
+
# Rotation w/o smooth xform
translate 120 0
diff --git a/tests/auto/other/lancelot/scripts/rasterops.qps b/tests/auto/other/lancelot/scripts/rasterops.qps
index 21f943b543..d0f2da42df 100644
--- a/tests/auto/other/lancelot/scripts/rasterops.qps
+++ b/tests/auto/other/lancelot/scripts/rasterops.qps
@@ -13,9 +13,9 @@ begin_block drawShape
setBrush 0xffff0000
drawEllipse 5 5 30 30
setBrush 0xff00ff00
- drawRect 0 0 20 20
+ drawRect 0 0 20 20
setBrush 0xff0000ff
- drawRect 20 20 20 20
+ drawRect 20 20 20 20
end_block
begin_block loop
diff --git a/tests/auto/other/lancelot/scripts/sizes.qps b/tests/auto/other/lancelot/scripts/sizes.qps
index 68e01c3262..12b0f4af1e 100644
--- a/tests/auto/other/lancelot/scripts/sizes.qps
+++ b/tests/auto/other/lancelot/scripts/sizes.qps
@@ -4,7 +4,7 @@
setPen NoPen
setBrush black
-translate 10 10
+translate 10 10
begin_block testblock
drawRect 0 0 10 10
@@ -75,9 +75,9 @@ drawChord 180 100 19 19 0 4320
end_block
-setPen red
+setPen red
translate 0 150
-repeat_block testblock
+repeat_block testblock
setRenderHint LineAntialiasing
diff --git a/tests/auto/other/lancelot/scripts/statictext.qps b/tests/auto/other/lancelot/scripts/statictext.qps
index b62b623462..c5ddda197f 100644
--- a/tests/auto/other/lancelot/scripts/statictext.qps
+++ b/tests/auto/other/lancelot/scripts/statictext.qps
@@ -50,7 +50,25 @@ save
drawStaticText 0 80 "scaled sansserif 10pt, bold italic"
restore
- translate 0 100
+ translate 200 200
+ setPen black
+ save
+ scale -1 -1
+
+ setFont "sansserif" 10 normal
+ drawStaticText 0 20 "flipped sansserif 10pt, normal"
+
+ setFont "sansserif" 12 normal
+ drawStaticText 0 40 "flipped sansserif 12pt, normal"
+
+ setFont "sansserif" 10 bold
+ drawStaticText 0 60 "flipped sansserif 12pt, bold"
+
+ setFont "sansserif" 10 bold italic
+ drawStaticText 0 80 "flipped sansserif 10pt, bold italic"
+ restore
+
+ translate -200 20
setPen black
save
translate 200 90
@@ -91,26 +109,26 @@ restore
end_block
translate 250 0
-drawStaticText 25 520 "clipped to rectangle"
+drawStaticText 25 640 "clipped to rectangle"
save
setPen #3f000000
setBrush nobrush
- drawRect 20 0 100 500
- setClipRect 20 0 100 500
+ drawRect 20 0 100 620
+ setClipRect 20 0 100 620
setPen black
repeat_block text_drawing
restore
translate 150 0
-drawStaticText 25 520 "clipped to path"
+drawStaticText 25 640 "clipped to path"
save
path_moveTo clip 20 0
path_cubicTo clip 0 200 40 400 20 400
- path_lineTo clip 30 500
+ path_lineTo clip 30 620
path_lineTo clip 30 0
path_lineTo clip 40 0
- path_lineTo clip 40 500
- path_lineTo clip 120 500
+ path_lineTo clip 40 620
+ path_lineTo clip 120 620
path_lineTo clip 120 0
path_lineTo clip 20 0
setPen #3f000000
diff --git a/tests/auto/other/lancelot/scripts/text.qps b/tests/auto/other/lancelot/scripts/text.qps
index d7ee83290b..e7d47448ea 100644
--- a/tests/auto/other/lancelot/scripts/text.qps
+++ b/tests/auto/other/lancelot/scripts/text.qps
@@ -7,112 +7,130 @@ begin_block text_drawing
save
setFont "sansserif" 10 normal
drawText 0 20 "sansserif 10pt, normal"
-
+
setFont "sansserif" 12 normal
drawText 0 40 "sansserif 12pt, normal"
-
+
setFont "sansserif" 10 bold
drawText 0 60 "sansserif 12pt, bold"
-
+
setFont "sansserif" 10 bold italic
drawText 0 80 "sansserif 10pt, bold italic"
-
-
+
+
translate 0 100
setPen #7fff0000
-
+
setFont "sansserif" 10 normal
drawText 0 20 "alpha sansserif 10pt, normal"
-
+
setFont "sansserif" 12 normal
drawText 0 40 "alpha sansserif 12pt, normal"
-
+
setFont "sansserif" 10 bold
drawText 0 60 "alpha sansserif 12pt, bold"
-
+
setFont "sansserif" 10 bold italic
drawText 0 80 "alpha sansserif 10pt, bold italic"
-
-
+
+
translate 0 100
setPen black
save
scale 0.9 0.9
-
+
setFont "sansserif" 10 normal
drawText 0 20 "scaled sansserif 10pt, normal"
-
+
setFont "sansserif" 12 normal
drawText 0 40 "scaled sansserif 12pt, normal"
-
+
setFont "sansserif" 10 bold
drawText 0 60 "scaled sansserif 12pt, bold"
-
+
setFont "sansserif" 10 bold italic
drawText 0 80 "scaled sansserif 10pt, bold italic"
restore
- translate 0 100
+ translate 200 200
+ setPen black
+ save
+ scale -1 -1
+
+ setFont "sansserif" 10 normal
+ drawStaticText 0 20 "flipped sansserif 10pt, normal"
+
+ setFont "sansserif" 12 normal
+ drawStaticText 0 40 "flipped sansserif 12pt, normal"
+
+ setFont "sansserif" 10 bold
+ drawStaticText 0 60 "flipped sansserif 12pt, bold"
+
+ setFont "sansserif" 10 bold italic
+ drawStaticText 0 80 "flipped sansserif 10pt, bold italic"
+ restore
+
+ translate -200 20
setPen black
save
translate 200 90
rotate 185
-
+
setFont "sansserif" 10 normal
drawText 0 20 "scaled sansserif 10pt, normal"
-
+
setFont "sansserif" 12 normal
drawText 0 40 "scaled sansserif 12pt, normal"
-
+
setFont "sansserif" 10 bold
drawText 0 60 "scaled sansserif 12pt, bold"
-
+
setFont "sansserif" 10 bold italic
drawText 0 80 "scaled sansserif 10pt, bold italic"
restore
-
+
translate 0 100
gradient_appendStop 0 red
gradient_appendStop 0.5 #00ff00
gradient_appendStop 1 blue
gradient_setLinear 0 0 200 0
setPen brush
-
+
setFont "sansserif" 10 normal
drawText 0 0 "gradient sansserif 10pt, normal"
-
+
setFont "sansserif" 12 normal
drawText 0 20 "gradient sansserif 12pt, normal"
-
+
setFont "sansserif" 10 bold
drawText 0 40 "gradient sansserif 12pt, bold"
-
+
setFont "sansserif" 10 bold italic
drawText 0 60 "gradient sansserif 10pt, bold italic"
restore
end_block
translate 250 0
-drawText 25 520 "clipped to rectangle"
+drawText 25 640 "clipped to rectangle"
save
setPen #3f000000
setBrush nobrush
- drawRect 20 0 100 500
- setClipRect 20 0 100 500
+ drawRect 20 0 100 620
+ setClipRect 20 0 100 620
setPen black
repeat_block text_drawing
restore
translate 150 0
-drawText 25 520 "clipped to path"
-save
+drawText 25 640 "clipped to path"
+save
path_moveTo clip 20 0
path_cubicTo clip 0 200 40 400 20 400
- path_lineTo clip 30 500
+ path_lineTo clip 30 620
path_lineTo clip 30 0
path_lineTo clip 40 0
- path_lineTo clip 40 500
- path_lineTo clip 120 500
+ path_lineTo clip 40 620
+ path_lineTo clip 120 620
path_lineTo clip 120 0
path_lineTo clip 20 0
setPen #3f000000
diff --git a/tests/auto/other/lancelot/scripts/tiled_pixmap.qps b/tests/auto/other/lancelot/scripts/tiled_pixmap.qps
index 9cb5e0dd1f..0ce3a7834c 100644
--- a/tests/auto/other/lancelot/scripts/tiled_pixmap.qps
+++ b/tests/auto/other/lancelot/scripts/tiled_pixmap.qps
@@ -5,7 +5,7 @@
translate 0 10
setRenderHint Antialiasing
-pixmap_load dome_argb32 the_pixmap
+pixmap_load dome_argb32 the_pixmap
begin_block draw_stuff
save
@@ -25,7 +25,7 @@ save
setRenderHint SmoothPixmapTransform false
drawTiledPixmap the_pixmap 0 0 150 100 25 25
restore
-
+
# xformed with smooth xform
translate 160 0
save
@@ -38,17 +38,17 @@ restore
end_block
translate 0 120
-pixmap_load dome_rgb32 the_pixmap
+pixmap_load dome_rgb32 the_pixmap
repeat_block draw_stuff
translate 0 120
-pixmap_load dome_indexed the_pixmap
+pixmap_load dome_indexed the_pixmap
repeat_block draw_stuff
translate 0 120
-pixmap_load dome_indexed_mask the_pixmap
+pixmap_load dome_indexed_mask the_pixmap
repeat_block draw_stuff
diff --git a/tests/auto/other/macgui/guitest.cpp b/tests/auto/other/macgui/guitest.cpp
index d4af5c1386..d7431dd88e 100644
--- a/tests/auto/other/macgui/guitest.cpp
+++ b/tests/auto/other/macgui/guitest.cpp
@@ -84,7 +84,6 @@ public:
void WidgetNavigator::printAll(QWidget *widget)
{
QAccessibleInterface * const iface = QAccessible::queryAccessibleInterface(widget);
- deleteInDestructor(iface);
printAll(iface);
}
@@ -97,7 +96,6 @@ void WidgetNavigator::printAll(QAccessibleInterface *interface)
QAccessibleInterface *WidgetNavigator::find(QAccessible::Text textType, const QString &text, QWidget *start)
{
QAccessibleInterface *const iface = QAccessible::queryAccessibleInterface(start);
- deleteInDestructor(iface);
return find(textType, text, iface);
}
@@ -118,27 +116,21 @@ QAccessibleInterface *WidgetNavigator::recursiveSearch(TestBase *test, QAccessib
while (todoInterfaces.isEmpty() == false) {
QAccessibleInterface *testInterface = todoInterfaces.pop();
-
+
if ((*test)(testInterface))
return testInterface;
-
+
const int numChildren = testInterface->childCount();
for (int i = 0; i < numChildren; ++i) {
QAccessibleInterface *childInterface = testInterface->child(i);
if (childInterface) {
todoInterfaces.push(childInterface);
- deleteInDestructor(childInterface);
}
}
}
return 0;
}
-void WidgetNavigator::deleteInDestructor(QAccessibleInterface *interface)
-{
- interfaces.insert(interface);
-}
-
QWidget *WidgetNavigator::getWidget(QAccessibleInterface *interface)
{
return qobject_cast<QWidget *>(interface->object());
@@ -146,9 +138,6 @@ QWidget *WidgetNavigator::getWidget(QAccessibleInterface *interface)
WidgetNavigator::~WidgetNavigator()
{
- foreach(QAccessibleInterface *interface, interfaces) {
- delete interface;
- }
}
///////////////////////////////////////////////////////////////////////////////
@@ -160,17 +149,17 @@ namespace NativeEvents {
CGPoint position;
position.x = globalPos.x();
position.y = globalPos.y();
-
+
const bool updateMousePosition = (updateMouse == UpdatePosition);
-
+
// Mouse down.
- CGPostMouseEvent(position, updateMousePosition, 3,
- (buttons & Qt::LeftButton) ? true : false,
- (buttons & Qt::MidButton/* Middlebutton! */) ? true : false,
+ CGPostMouseEvent(position, updateMousePosition, 3,
+ (buttons & Qt::LeftButton) ? true : false,
+ (buttons & Qt::MidButton/* Middlebutton! */) ? true : false,
(buttons & Qt::RightButton) ? true : false);
// Mouse up.
- CGPostMouseEvent(position, updateMousePosition, 3, false, false, false);
+ CGPostMouseEvent(position, updateMousePosition, 3, false, false, false);
}
#else
# error Oops, NativeEvents::mouseClick() is not implemented on this platform.
@@ -200,7 +189,7 @@ bool checkPixel(QColor pixel, QColor expected)
}
/*
- Tests that the pixels inside rect in image all have the given color.
+ Tests that the pixels inside rect in image all have the given color.
*/
bool GuiTester::isFilled(const QImage image, const QRect &rect, const QColor &color)
{
@@ -218,7 +207,7 @@ bool GuiTester::isFilled(const QImage image, const QRect &rect, const QColor &co
/*
Tests that stuff is painted to the pixels inside rect.
- This test fails if any lines in the given direction have pixels
+ This test fails if any lines in the given direction have pixels
of only one color.
*/
bool GuiTester::isContent(const QImage image, const QRect &rect, Directions directions)
@@ -239,7 +228,7 @@ bool GuiTester::isContent(const QImage image, const QRect &rect, Directions dire
}
}
return true;
- }
+ }
if (directions & Vertical) {
for (int x = rect.left(); x <= rect.right(); ++x) {
diff --git a/tests/auto/other/macgui/guitest.h b/tests/auto/other/macgui/guitest.h
index 1b5f933769..569a67d7fe 100644
--- a/tests/auto/other/macgui/guitest.h
+++ b/tests/auto/other/macgui/guitest.h
@@ -70,13 +70,12 @@ public:
void printAll(QWidget *widget);
void printAll(QAccessibleInterface *interface);
-
+
QAccessibleInterface *find(QAccessible::Text textType, const QString &text, QWidget *start);
QAccessibleInterface *find(QAccessible::Text textType, const QString &text, QAccessibleInterface *start);
QAccessibleInterface *recursiveSearch(TestBase *test, QAccessibleInterface *iface);
-
- void deleteInDestructor(QAccessibleInterface * interface);
+
static QWidget *getWidget(QAccessibleInterface *interface);
private:
QSet<QAccessibleInterface *> interfaces;
@@ -99,7 +98,7 @@ class ColorWidget : public QWidget
public:
ColorWidget(QWidget *parent = 0, QColor color = QColor(Qt::red))
: QWidget(parent), color(color) {}
-
+
QColor color;
protected:
@@ -139,7 +138,7 @@ private:
};
/*
-
+
*/
class GuiTester : public QObject
{
diff --git a/tests/auto/other/macgui/tst_macgui.cpp b/tests/auto/other/macgui/tst_macgui.cpp
index cfe27095a8..e796b44843 100644
--- a/tests/auto/other/macgui/tst_macgui.cpp
+++ b/tests/auto/other/macgui/tst_macgui.cpp
@@ -41,7 +41,7 @@
#include <QApplication>
-#include <QMessageBox>
+#include <QMessageBox>
#include <QtTest/QtTest>
#include <QSplashScreen>
#include <QScrollBar>
@@ -55,7 +55,7 @@ class tst_MacGui : public GuiTester
Q_OBJECT
private slots:
void scrollbarPainting();
-
+
void dummy();
void splashScreenModality();
void nonModalOrder();
@@ -216,7 +216,7 @@ void tst_MacGui::spinBoxArrowButtons()
spinBox2.move(0, 100);
colorWidget.show();
QTest::qWait(100);
-
+
// Grab an unfocused spin box.
const QImage noFocus = grabWindowContents(&colorWidget).toImage();
diff --git a/tests/auto/other/macnativeevents/tst_macnativeevents.cpp b/tests/auto/other/macnativeevents/tst_macnativeevents.cpp
index 3072d163c3..ae59672c72 100644
--- a/tests/auto/other/macnativeevents/tst_macnativeevents.cpp
+++ b/tests/auto/other/macnativeevents/tst_macnativeevents.cpp
@@ -293,7 +293,7 @@ void tst_MacNativeEvents::testMouseEnter()
void tst_MacNativeEvents::testChildDialogInFrontOfModalParent()
{
- // Test that a child dialog of a modal parent dialog is
+ // Test that a child dialog of a modal parent dialog is
// in front of the parent, and active:
QDialog parent;
parent.setWindowModality(Qt::ApplicationModal);
diff --git a/tests/auto/other/other.pro b/tests/auto/other/other.pro
index 35aaf4d48f..1f7582243e 100644
--- a/tests/auto/other/other.pro
+++ b/tests/auto/other/other.pro
@@ -42,6 +42,14 @@ SUBDIRS=\
qaccessibility \
qaccessibilitylinux \
+!qtHaveModule(network): SUBDIRS -= \
+ baselineexample \
+ headersclean \
+ lancelot \
+ networkselftest \
+ qnetworkaccessmanager_and_qprogressdialog \
+ qobjectperformance
+
testcocoon: SUBDIRS -= headersclean
cross_compile: SUBDIRS -= \
diff --git a/tests/auto/other/qaccessibility/qaccessibility.pro b/tests/auto/other/qaccessibility/qaccessibility.pro
index 54a076b8fa..071b0bb66c 100644
--- a/tests/auto/other/qaccessibility/qaccessibility.pro
+++ b/tests/auto/other/qaccessibility/qaccessibility.pro
@@ -1,7 +1,7 @@
CONFIG += testcase
TARGET = tst_qaccessibility
requires(contains(QT_CONFIG,accessibility))
-QT += widgets testlib gui-private
+QT += testlib gui-private widgets-private
SOURCES += tst_qaccessibility.cpp
unix:!mac:LIBS+=-lm
diff --git a/tests/auto/other/qaccessibility/tst_qaccessibility.cpp b/tests/auto/other/qaccessibility/tst_qaccessibility.cpp
index b0d0459326..4e0b3298fc 100644
--- a/tests/auto/other/qaccessibility/tst_qaccessibility.cpp
+++ b/tests/auto/other/qaccessibility/tst_qaccessibility.cpp
@@ -58,7 +58,9 @@
#endif
#include <QtTest/QtTest>
#include <QtGui>
+#include <QtGui/private/qaccessible2_p.h>
#include <QtWidgets>
+#include <QtWidgets/private/qaccessiblewidget_p.h>
#include <math.h>
#include <qpa/qplatformnativeinterface.h>
@@ -66,7 +68,8 @@
# undef interface
#endif
-
+#include <QtGui/private/qaccessible2_p.h>
+#include <QtWidgets/private/qaccessiblewidget_p.h>
#include "QtTest/qtestaccessible.h"
// Make a widget frameless to prevent size constraints of title bars
@@ -93,8 +96,6 @@ inline bool IsValidCEPlatform() {
}
#endif
-typedef QSharedPointer<QAccessibleInterface> QAIPtr;
-
static inline bool verifyChild(QWidget *child, QAccessibleInterface *interface,
int index, const QRect &domain)
{
@@ -109,7 +110,7 @@ static inline bool verifyChild(QWidget *child, QAccessibleInterface *interface,
}
// Verify that we get a valid QAccessibleInterface for the child.
- QAIPtr childInterface(QAccessible::queryAccessibleInterface(child));
+ QAccessibleInterface *childInterface(QAccessible::queryAccessibleInterface(child));
if (!childInterface) {
qWarning("tst_QAccessibility::verifyChild: Failed to retrieve interface for child.");
return false;
@@ -117,7 +118,7 @@ static inline bool verifyChild(QWidget *child, QAccessibleInterface *interface,
// QAccessibleInterface::indexOfChild():
// Verify that indexOfChild() returns an index equal to the index passed in
- int indexFromIndexOfChild = interface->indexOfChild(childInterface.data());
+ int indexFromIndexOfChild = interface->indexOfChild(childInterface);
if (indexFromIndexOfChild != index) {
qWarning("tst_QAccessibility::verifyChild (indexOfChild()):");
qWarning() << "Expected:" << index;
@@ -126,7 +127,7 @@ static inline bool verifyChild(QWidget *child, QAccessibleInterface *interface,
}
// Navigate to child, compare its object and role with the interface from queryAccessibleInterface(child).
- QAIPtr navigatedChildInterface(interface->child(index));
+ QAccessibleInterface *navigatedChildInterface(interface->child(index));
if (!navigatedChildInterface)
return false;
@@ -136,7 +137,7 @@ static inline bool verifyChild(QWidget *child, QAccessibleInterface *interface,
// Calculate global child position and check that the interface
// returns the correct index for that position.
QPoint globalChildPos = child->mapToGlobal(QPoint(0, 0));
- QAIPtr childAtInterface(interface->childAt(globalChildPos.x(), globalChildPos.y()));
+ QAccessibleInterface *childAtInterface(interface->childAt(globalChildPos.x(), globalChildPos.y()));
if (!childAtInterface) {
qWarning("tst_QAccessibility::verifyChild (childAt()):");
qWarning() << "Expected:" << childInterface;
@@ -174,10 +175,10 @@ static inline int indexOfChild(QAccessibleInterface *parentInterface, QWidget *c
{
if (!parentInterface || !childWidget)
return -1;
- QAIPtr childInterface(QAccessible::queryAccessibleInterface(childWidget));
+ QAccessibleInterface *childInterface(QAccessible::queryAccessibleInterface(childWidget));
if (!childInterface)
return -1;
- return parentInterface->indexOfChild(childInterface.data());
+ return parentInterface->indexOfChild(childInterface);
}
#define EXPECT(cond) \
@@ -193,20 +194,20 @@ static int verifyHierarchy(QAccessibleInterface *iface)
{
int errorAt = 0;
static int treelevel = 0; // for error diagnostics
- QAIPtr middleChild;
- QAIPtr if2;
+ QAccessibleInterface *if2 = 0;
++treelevel;
for (int i = 0; i < iface->childCount() && !errorAt; ++i) {
- if2 = QAIPtr(iface->child(i));
+ if2 = iface->child(i);
EXPECT(if2 != 0);
- EXPECT(iface->indexOfChild(if2.data()) == i);
+ EXPECT(iface->indexOfChild(if2) == i);
// navigate Ancestor
- QAIPtr parent(if2->parent());
+ QAccessibleInterface *parent = if2->parent();
EXPECT(iface->object() == parent->object());
+ EXPECT(iface == parent);
// verify children
if (!errorAt)
- errorAt = verifyHierarchy(if2.data());
+ errorAt = verifyHierarchy(if2);
}
--treelevel;
@@ -215,7 +216,7 @@ static int verifyHierarchy(QAccessibleInterface *iface)
QRect childRect(QAccessibleInterface *iface, int index = 0)
{
- return QAIPtr(iface->child(index))->rect();
+ return iface->child(index)->rect();
}
class tst_QAccessibility : public QObject
@@ -234,6 +235,7 @@ private slots:
void eventTest();
void customWidget();
void deletedWidget();
+ void subclassedWidget();
void statesStructTest();
void navigateHierarchy();
@@ -284,7 +286,7 @@ private:
QAccessible::State state(QWidget * const widget)
{
- QAIPtr iface(QAccessible::queryAccessibleInterface(widget));
+ QAccessibleInterface *iface(QAccessible::queryAccessibleInterface(widget));
if (!iface) {
qWarning() << "Cannot get QAccessibleInterface for widget";
return QAccessible::State();
@@ -292,38 +294,6 @@ QAccessible::State state(QWidget * const widget)
return iface->state();
}
-class QtTestAccessibleWidget: public QWidget
-{
- Q_OBJECT
-public:
- QtTestAccessibleWidget(QWidget *parent, const char *name): QWidget(parent)
- {
- setObjectName(name);
- QPalette pal;
- pal.setColor(backgroundRole(), Qt::black);//black is beautiful
- setPalette(pal);
- setFixedSize(5, 5);
- }
-};
-
-class QtTestAccessibleWidgetIface: public QAccessibleWidget
-{
-public:
- QtTestAccessibleWidgetIface(QtTestAccessibleWidget *w): QAccessibleWidget(w) {}
- QString text(QAccessible::Text t) const
- {
- if (t == QAccessible::Help)
- return QString::fromLatin1("Help yourself");
- return QAccessibleWidget::text(t);
- }
- static QAccessibleInterface *ifaceFactory(const QString &key, QObject *o)
- {
- if (key == "QtTestAccessibleWidget")
- return new QtTestAccessibleWidgetIface(static_cast<QtTestAccessibleWidget*>(o));
- return 0;
- }
-};
-
tst_QAccessibility::tst_QAccessibility()
{
click_count = 0;
@@ -341,7 +311,6 @@ void tst_QAccessibility::onClicked()
void tst_QAccessibility::initTestCase()
{
QTestAccessibility::initialize();
- QAccessible::installFactory(QtTestAccessibleWidgetIface::ifaceFactory);
}
void tst_QAccessibility::cleanupTestCase()
@@ -370,6 +339,7 @@ void tst_QAccessibility::cleanup()
void tst_QAccessibility::eventTest()
{
QPushButton* button = new QPushButton(0);
+ QAccessible::queryAccessibleInterface(button);
button->setObjectName(QString("Olaf"));
setFrameless(button);
@@ -394,26 +364,112 @@ void tst_QAccessibility::eventTest()
QVERIFY(QTestAccessibility::containsEvent(&hideEvent));
delete button;
+
+ // Make sure that invalid events don't bring down the system
+ // these events can be in user code.
+ QWidget *widget = new QWidget();
+ QAccessibleEvent ev1(widget, QAccessible::Focus);
+ QAccessible::updateAccessibility(&ev1);
+
+ QAccessibleEvent ev2(widget, QAccessible::Focus);
+ ev2.setChild(7);
+ QAccessible::updateAccessibility(&ev2);
+ delete widget;
+
+ QObject *object = new QObject();
+ QAccessibleEvent ev3(object, QAccessible::Focus);
+ QAccessible::updateAccessibility(&ev3);
+ delete object;
+
+ QTestAccessibility::clearEvents();
}
+
+class QtTestAccessibleWidget: public QWidget
+{
+ Q_OBJECT
+public:
+ QtTestAccessibleWidget(QWidget *parent, const char *name): QWidget(parent)
+ {
+ setObjectName(name);
+ }
+};
+
+class QtTestAccessibleWidgetIface: public QAccessibleWidget
+{
+public:
+ QtTestAccessibleWidgetIface(QtTestAccessibleWidget *w): QAccessibleWidget(w) {}
+ QString text(QAccessible::Text t) const
+ {
+ if (t == QAccessible::Help)
+ return QString::fromLatin1("Help yourself");
+ return QAccessibleWidget::text(t);
+ }
+ static QAccessibleInterface *ifaceFactory(const QString &key, QObject *o)
+ {
+ if (key == "QtTestAccessibleWidget")
+ return new QtTestAccessibleWidgetIface(static_cast<QtTestAccessibleWidget*>(o));
+ return 0;
+ }
+};
+
+class QtTestAccessibleWidgetSubclass: public QtTestAccessibleWidget
+{
+ Q_OBJECT
+public:
+ QtTestAccessibleWidgetSubclass(QWidget *parent, const char *name): QtTestAccessibleWidget(parent, name)
+ {}
+};
+
void tst_QAccessibility::customWidget()
{
+ {
QtTestAccessibleWidget* widget = new QtTestAccessibleWidget(0, "Heinz");
-
+ widget->show();
+ QTest::qWaitForWindowExposed(widget);
+ // By default we create QAccessibleWidget
+ QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(widget);
+ QVERIFY(iface != 0);
+ QVERIFY(iface->isValid());
+ QCOMPARE(iface->object(), (QObject*)widget);
+ QCOMPARE(iface->object()->objectName(), QString("Heinz"));
+ QCOMPARE(iface->rect().height(), widget->height());
+ QCOMPARE(iface->text(QAccessible::Help), QString());
+ QCOMPARE(iface->rect().height(), widget->height());
+ delete widget;
+ }
+ {
+ QAccessible::installFactory(QtTestAccessibleWidgetIface::ifaceFactory);
+ QtTestAccessibleWidget* widget = new QtTestAccessibleWidget(0, "Heinz");
+ widget->show();
+ QTest::qWaitForWindowExposed(widget);
QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(widget);
QVERIFY(iface != 0);
QVERIFY(iface->isValid());
QCOMPARE(iface->object(), (QObject*)widget);
QCOMPARE(iface->object()->objectName(), QString("Heinz"));
+ QCOMPARE(iface->rect().height(), widget->height());
+ // The help text is only set if our factory works
QCOMPARE(iface->text(QAccessible::Help), QString("Help yourself"));
-
- delete iface;
delete widget;
+ }
+ {
+ // A subclass of any class should still get the right QAccessibleInterface
+ QtTestAccessibleWidgetSubclass* subclassedWidget = new QtTestAccessibleWidgetSubclass(0, "Hans");
+ QAccessibleInterface *subIface = QAccessible::queryAccessibleInterface(subclassedWidget);
+ QVERIFY(subIface != 0);
+ QVERIFY(subIface->isValid());
+ QCOMPARE(subIface->object(), (QObject*)subclassedWidget);
+ QCOMPARE(subIface->text(QAccessible::Help), QString("Help yourself"));
+ delete subclassedWidget;
+ }
+ QTestAccessibility::clearEvents();
}
void tst_QAccessibility::deletedWidget()
{
QtTestAccessibleWidget *widget = new QtTestAccessibleWidget(0, "Ralf");
+ QAccessible::installFactory(QtTestAccessibleWidgetIface::ifaceFactory);
QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(widget);
QVERIFY(iface != 0);
QVERIFY(iface->isValid());
@@ -421,8 +477,25 @@ void tst_QAccessibility::deletedWidget()
delete widget;
widget = 0;
- QVERIFY(!iface->isValid());
- delete iface;
+ // fixme: QVERIFY(!iface->isValid());
+}
+
+class KFooButton: public QPushButton
+{
+ Q_OBJECT
+public:
+ KFooButton(const QString &text, QWidget* parent = 0) : QPushButton(text, parent)
+ {}
+};
+
+void tst_QAccessibility::subclassedWidget()
+{
+ KFooButton button("Ploink", 0);
+ QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(&button);
+ QVERIFY(iface);
+ QCOMPARE(iface->object(), (QObject*)&button);
+ QCOMPARE(iface->text(QAccessible::Name), button.text());
+ QTestAccessibility::clearEvents();
}
void tst_QAccessibility::statesStructTest()
@@ -452,7 +525,7 @@ void tst_QAccessibility::sliderTest()
setFrameless(slider);
slider->setObjectName(QString("Slidy"));
slider->show();
- QAIPtr iface(QAccessible::queryAccessibleInterface(slider));
+ QAccessibleInterface *iface(QAccessible::queryAccessibleInterface(slider));
QVERIFY(iface);
QVERIFY(iface->isValid());
@@ -499,16 +572,16 @@ void tst_QAccessibility::navigateHierarchy()
w31->setObjectName(QString("31"));
w31->show();
- QAIPtr ifaceW(QAccessible::queryAccessibleInterface(w));
+ QAccessibleInterface *ifaceW(QAccessible::queryAccessibleInterface(w));
QVERIFY(ifaceW != 0);
QVERIFY(ifaceW->isValid());
- QAIPtr target = QAIPtr(ifaceW->child(14));
+ QAccessibleInterface *target = ifaceW->child(14);
QVERIFY(target == 0);
- target = QAIPtr(ifaceW->child(-1));
+ target = ifaceW->child(-1);
QVERIFY(target == 0);
- target = QAIPtr(ifaceW->child(0));
- QAIPtr interfaceW1(ifaceW->child(0));
+ target = ifaceW->child(0);
+ QAccessibleInterface *interfaceW1(ifaceW->child(0));
QVERIFY(target);
QVERIFY(target->isValid());
QCOMPARE(target->object(), (QObject*)w1);
@@ -516,24 +589,24 @@ void tst_QAccessibility::navigateHierarchy()
QVERIFY(interfaceW1->isValid());
QCOMPARE(interfaceW1->object(), (QObject*)w1);
- target = QAIPtr(ifaceW->child(2));
+ target = ifaceW->child(2);
QVERIFY(target != 0);
QVERIFY(target->isValid());
QCOMPARE(target->object(), (QObject*)w3);
- QAIPtr child = QAIPtr(target->child(1));
+ QAccessibleInterface *child = target->child(1);
QVERIFY(child == 0);
- child = QAIPtr(target->child(0));
+ child = target->child(0);
QVERIFY(child != 0);
QVERIFY(child->isValid());
QCOMPARE(child->object(), (QObject*)w31);
- ifaceW = QAIPtr(QAccessible::queryAccessibleInterface(w));
- QAIPtr acc3(ifaceW->child(2));
- target = QAIPtr(acc3->child(0));
+ ifaceW = QAccessible::queryAccessibleInterface(w);
+ QAccessibleInterface *acc3(ifaceW->child(2));
+ target = acc3->child(0);
QCOMPARE(target->object(), (QObject*)w31);
- QAIPtr parent = QAIPtr(target->parent());
+ QAccessibleInterface *parent = target->parent();
QVERIFY(parent != 0);
QVERIFY(parent->isValid());
QCOMPARE(parent->object(), (QObject*)w3);
@@ -596,10 +669,8 @@ void tst_QAccessibility::accessibleName()
{
QWidget *toplevel = createWidgets();
toplevel->show();
-#if defined(Q_OS_UNIX)
- QCoreApplication::processEvents();
- QTest::qWait(100);
-#endif
+ QVERIFY(QTest::qWaitForWindowExposed(toplevel));
+
QLayout *lout = toplevel->layout();
for (int i = 0; i < lout->count(); i++) {
QLayoutItem *item = lout->itemAt(i);
@@ -608,12 +679,12 @@ void tst_QAccessibility::accessibleName()
QString name = tr("Widget Name %1").arg(i);
child->setAccessibleName(name);
QAccessibleInterface *acc = QAccessible::queryAccessibleInterface(child);
+ QVERIFY(acc);
QCOMPARE(acc->text(QAccessible::Name), name);
QString desc = tr("Widget Description %1").arg(i);
child->setAccessibleDescription(desc);
QCOMPARE(acc->text(QAccessible::Description), desc);
-
}
delete toplevel;
@@ -731,7 +802,6 @@ void tst_QAccessibility::actionTest()
widget->setFocusPolicy(Qt::StrongFocus);
QCOMPARE(actions->actionNames(), QStringList(QAccessibleActionInterface::setFocusAction()));
- delete interface;
delete widget;
}
QTestAccessibility::clearEvents();
@@ -760,7 +830,6 @@ void tst_QAccessibility::actionTest()
QTest::qWait(500);
QCOMPARE(click_count, 1);
- delete interface;
delete button;
}
QTestAccessibility::clearEvents();
@@ -768,12 +837,40 @@ void tst_QAccessibility::actionTest()
void tst_QAccessibility::applicationTest()
{
+ {
QLatin1String name = QLatin1String("My Name");
qApp->setApplicationName(name);
QAccessibleInterface *interface = QAccessible::queryAccessibleInterface(qApp);
QCOMPARE(interface->text(QAccessible::Name), name);
+ QCOMPARE(interface->text(QAccessible::Description), qApp->applicationFilePath());
+ QCOMPARE(interface->text(QAccessible::Value), QString());
QCOMPARE(interface->role(), QAccessible::Application);
- delete interface;
+ QCOMPARE(interface->window(), static_cast<QWindow*>(0));
+ QCOMPARE(interface->parent(), static_cast<QAccessibleInterface*>(0));
+ QCOMPARE(interface->focusChild(), static_cast<QAccessibleInterface*>(0));
+ QCOMPARE(interface->indexOfChild(0), -1);
+ QCOMPARE(interface->child(0), static_cast<QAccessibleInterface*>(0));
+ QCOMPARE(interface->child(-1), static_cast<QAccessibleInterface*>(0));
+ QCOMPARE(interface->child(1), static_cast<QAccessibleInterface*>(0));
+ QCOMPARE(interface->childCount(), 0);
+
+ QWidget widget;
+ widget.show();
+ qApp->setActiveWindow(&widget);
+ QVERIFY(QTest::qWaitForWindowActive(&widget));
+
+ QAccessibleInterface *widgetIface = QAccessible::queryAccessibleInterface(&widget);
+ QCOMPARE(interface->childCount(), 1);
+ QAccessibleInterface *focus = interface->focusChild();
+ QCOMPARE(focus->object(), &widget);
+ QCOMPARE(interface->indexOfChild(0), -1);
+ QCOMPARE(interface->indexOfChild(widgetIface), 0);
+ QAccessibleInterface *child = interface->child(0);
+ QCOMPARE(child->object(), &widget);
+ QCOMPARE(interface->child(-1), static_cast<QAccessibleInterface*>(0));
+ QCOMPARE(interface->child(1), static_cast<QAccessibleInterface*>(0));
+ }
+ QTestAccessibility::clearEvents();
}
void tst_QAccessibility::mainWindowTest()
@@ -802,7 +899,6 @@ void tst_QAccessibility::mainWindowTest()
QVERIFY(iface->state().active);
- delete iface;
delete mw;
}
QTestAccessibility::clearEvents();
@@ -815,7 +911,7 @@ void tst_QAccessibility::mainWindowTest()
// We currently don't have an accessible interface for QWindow
// the active state is either in the QMainWindow or QQuickView
-// QAIPtr windowIface(QAccessible::queryAccessibleInterface(&window));
+// QAccessibleInterface *windowIface(QAccessible::queryAccessibleInterface(&window));
// QVERIFY(windowIface->state().active);
QAccessible::State activeState;
@@ -900,7 +996,6 @@ void tst_QAccessibility::buttonTest()
actionInterface->doAction(QAccessibleActionInterface::pressAction());
QTest::qWait(500);
QCOMPARE(pushButton.clickCount, 1);
- delete interface;
// test toggle button
interface = QAccessible::queryAccessibleInterface(&toggleButton);
@@ -915,7 +1010,6 @@ void tst_QAccessibility::buttonTest()
QVERIFY(toggleButton.isChecked());
QCOMPARE(actionInterface->actionNames().at(0), QAccessibleActionInterface::toggleAction());
QVERIFY(interface->state().checked);
- delete interface;
{
// test menu push button
@@ -934,7 +1028,6 @@ void tst_QAccessibility::buttonTest()
// showing the menu enters a new event loop...
// interface->actionInterface()->doAction(QAccessibleActionInterface::showMenuAction());
// QTest::qWait(500);
- delete interface;
delete menu;
}
@@ -959,7 +1052,6 @@ void tst_QAccessibility::buttonTest()
QVERIFY_EVENT(&ev);
checkBox.setChecked(false);
QVERIFY_EVENT(&ev);
- delete interface;
}
{
@@ -978,7 +1070,6 @@ void tst_QAccessibility::buttonTest()
st.checked = true;
QAccessibleStateChangeEvent ev(&radio, st);
QVERIFY_EVENT(&ev);
- delete interface;
}
// // test standard toolbutton
@@ -1071,7 +1162,6 @@ void tst_QAccessibility::scrollBarTest()
const QRect scrollBarRect = scrollBarInterface->rect();
QVERIFY(scrollBarRect.isValid());
- delete scrollBarInterface;
delete scrollBar;
QTestAccessibility::clearEvents();
@@ -1092,7 +1182,6 @@ void tst_QAccessibility::tabTest()
QAccessibleInterface *leftButton = interface->child(0);
QCOMPARE(leftButton->role(), QAccessible::PushButton);
QVERIFY(leftButton->state().invisible);
- delete leftButton;
const int lots = 5;
for (int i = 0; i < lots; ++i)
@@ -1128,9 +1217,6 @@ void tst_QAccessibility::tabTest()
QCOMPARE(tabBar->currentIndex(), 1);
delete tabBar;
- delete interface;
- delete child1;
- delete child2;
QTestAccessibility::clearEvents();
}
@@ -1179,10 +1265,6 @@ void tst_QAccessibility::tabWidgetTest()
QVERIFY(tabButtonRight);
QCOMPARE(tabButtonRight->role(), QAccessible::PushButton);
QCOMPARE(tabButtonRight->text(QAccessible::Name), QLatin1String("Scroll Right"));
- delete tabButton1Interface;
- delete tabButton2Interface;
- delete tabButtonLeft;
- delete tabButtonRight;
QAccessibleInterface* stackWidgetInterface = interface->child(0);
QVERIFY(stackWidgetInterface);
@@ -1205,7 +1287,6 @@ void tst_QAccessibility::tabWidgetTest()
QCOMPARE(parent->childCount(), 2);
#endif
QCOMPARE(parent->role(), QAccessible::LayeredPane);
- delete parent;
QAccessibleInterface* stackChild2Interface = stackWidgetInterface->child(1);
QVERIFY(stackChild2Interface);
@@ -1220,13 +1301,7 @@ void tst_QAccessibility::tabWidgetTest()
QCOMPARE(parent->childCount(), 2);
#endif
QCOMPARE(parent->role(), QAccessible::LayeredPane);
- delete parent;
- delete tabBarInterface;
- delete stackChild1Interface;
- delete stackChild2Interface;
- delete stackWidgetInterface;
- delete interface;
delete tabWidget;
QTestAccessibility::clearEvents();
}
@@ -1274,7 +1349,6 @@ void tst_QAccessibility::menuTest()
QAccessibleInterface *interface = QAccessible::queryAccessibleInterface(&mw);
QCOMPARE(verifyHierarchy(interface), 0);
- delete interface;
interface = QAccessible::queryAccessibleInterface(mw.menuBar());
@@ -1351,7 +1425,6 @@ void tst_QAccessibility::menuTest()
QVERIFY(interface->actionInterface());
QCOMPARE(interface->actionInterface()->actionNames(), QStringList());
- delete interface;
interface = QAccessible::queryAccessibleInterface(file);
QCOMPARE(interface->childCount(), 5);
QCOMPARE(interface->role(), QAccessible::PopupMenu);
@@ -1392,9 +1465,7 @@ void tst_QAccessibility::menuTest()
iface2 = interface->child(child);
QVERIFY(iface2);
QCOMPARE(iface2->role(), fileRoles[child]);
- delete iface2;
}
- delete iface;
// "New" item
iface = interface->child(0);
@@ -1403,20 +1474,16 @@ void tst_QAccessibility::menuTest()
// "New" menu
iface2 = iface->child(0);
- delete iface;
iface = iface2;
QVERIFY(iface);
QCOMPARE(iface->role(), QAccessible::PopupMenu);
// "Text file" menu item
iface2 = iface->child(0);
- delete iface;
iface = iface2;
QVERIFY(iface);
QCOMPARE(iface->role(), QAccessible::MenuItem);
- delete iface;
-
// move mouse pointer away, since that might influence the
// subsequent tests
QTest::mouseMove(&mw, QPoint(-1, -1));
@@ -1435,13 +1502,6 @@ void tst_QAccessibility::menuTest()
QTestAccessibility::clearEvents();
mw.hide();
- delete iFile;
- delete iFileNew;
- delete iFileOpen;
- delete iFileSave;
- delete iFileSeparator;
- delete iFileExit;
-
// Do not crash if the menu don't have a parent
QMenu *menu = new QMenu;
menu->addAction(QLatin1String("one"));
@@ -1453,8 +1513,6 @@ void tst_QAccessibility::menuTest()
QCOMPARE(iface2->role(), QAccessible::Application);
// caused a *crash*
iface2->state();
- delete iface2;
- delete iface;
delete menu;
}
@@ -1486,7 +1544,6 @@ void tst_QAccessibility::spinBoxTest()
QCOMPARE(lineEdit->role(), QAccessible::EditableText);
QCOMPARE(lineEdit->text(QAccessible::Value), QLatin1String("3"));
- delete lineEdit;
QVERIFY(interface->valueInterface());
QCOMPARE(interface->valueInterface()->currentValue().toInt(), 3);
@@ -1525,7 +1582,6 @@ void tst_QAccessibility::doubleSpinBoxTest()
QAccessibleInterface *childIface = interface->child(i);
const QRect childRect = childIface->rect();
QVERIFY(childRect.isValid());
- delete childIface;
}
delete doubleSpinBox;
@@ -1588,10 +1644,10 @@ void tst_QAccessibility::textEditTest()
QTest::qWaitForWindowShown(&edit);
QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(&edit);
QCOMPARE(iface->text(QAccessible::Value), edit.toPlainText());
- QCOMPARE(iface->textInterface()->textAtOffset(8, QAccessible2::WordBoundary, &startOffset, &endOffset), QString("world"));
+ QCOMPARE(iface->textInterface()->textAtOffset(8, QAccessible::WordBoundary, &startOffset, &endOffset), QString("world"));
QCOMPARE(startOffset, 6);
QCOMPARE(endOffset, 11);
- QCOMPARE(iface->textInterface()->textAtOffset(15, QAccessible2::LineBoundary, &startOffset, &endOffset), QString("How are you today?"));
+ QCOMPARE(iface->textInterface()->textAtOffset(15, QAccessible::LineBoundary, &startOffset, &endOffset), QString("How are you today?"));
QCOMPARE(startOffset, 13);
QCOMPARE(endOffset, 31);
QCOMPARE(iface->textInterface()->characterCount(), 48);
@@ -1649,10 +1705,10 @@ void tst_QAccessibility::textBrowserTest()
QCOMPARE(iface->text(QAccessible::Value), text);
int startOffset;
int endOffset;
- QCOMPARE(iface->textInterface()->textAtOffset(8, QAccessible2::WordBoundary, &startOffset, &endOffset), QString("world"));
+ QCOMPARE(iface->textInterface()->textAtOffset(8, QAccessible::WordBoundary, &startOffset, &endOffset), QString("world"));
QCOMPARE(startOffset, 6);
QCOMPARE(endOffset, 11);
- QCOMPARE(iface->textInterface()->textAtOffset(14, QAccessible2::LineBoundary, &startOffset, &endOffset), QString("how are you today?"));
+ QCOMPARE(iface->textInterface()->textAtOffset(14, QAccessible::LineBoundary, &startOffset, &endOffset), QString("how are you today?"));
QCOMPARE(startOffset, 12);
QCOMPARE(endOffset, 30);
QCOMPARE(iface->textInterface()->characterCount(), 31);
@@ -1783,7 +1839,6 @@ void tst_QAccessibility::mdiSubWindowTest()
QAccessibleInterface *child = interface->childAt(globalWidgetPos.x(), globalWidgetPos.y());
QCOMPARE(child->role(), QAccessible::PushButton);
QCOMPARE(child->text(QAccessible::Name), QString("QAccessibilityTest"));
- delete child;
testWindow->widget()->hide();
QCOMPARE(interface->childAt(globalWidgetPos.x(), globalWidgetPos.y()), static_cast<QAccessibleInterface*>(0));
@@ -1796,7 +1851,7 @@ void tst_QAccessibility::lineEditTest()
QWidget *toplevel = new QWidget;
{
QLineEdit *le = new QLineEdit;
- QAIPtr iface(QAccessible::queryAccessibleInterface(le));
+ QAccessibleInterface *iface(QAccessible::queryAccessibleInterface(le));
QVERIFY(iface);
le->show();
@@ -1862,7 +1917,7 @@ void tst_QAccessibility::lineEditTest()
QString cite = "I always pass on good advice. It is the only thing to do with it. It is never of any use to oneself. --Oscar Wilde";
QLineEdit *le3 = new QLineEdit(cite, toplevel);
le3->show();
- QAIPtr iface(QAccessible::queryAccessibleInterface(le3));
+ QAccessibleInterface *iface(QAccessible::queryAccessibleInterface(le3));
QAccessibleTextInterface* textIface = iface->textInterface();
le3->deselect();
QTestAccessibility::clearEvents();
@@ -1876,45 +1931,45 @@ void tst_QAccessibility::lineEditTest()
int start, end;
QCOMPARE(textIface->text(0, 8), QString::fromLatin1("I always"));
- QCOMPARE(textIface->textAtOffset(0, QAccessible2::CharBoundary,&start,&end), QString::fromLatin1("I"));
+ QCOMPARE(textIface->textAtOffset(0, QAccessible::CharBoundary,&start,&end), QString::fromLatin1("I"));
QCOMPARE(start, 0);
QCOMPARE(end, 1);
- QCOMPARE(textIface->textBeforeOffset(0, QAccessible2::CharBoundary,&start,&end), QString());
- QCOMPARE(textIface->textAfterOffset(0, QAccessible2::CharBoundary,&start,&end), QString::fromLatin1(" "));
+ QCOMPARE(textIface->textBeforeOffset(0, QAccessible::CharBoundary,&start,&end), QString());
+ QCOMPARE(textIface->textAfterOffset(0, QAccessible::CharBoundary,&start,&end), QString::fromLatin1(" "));
QCOMPARE(start, 1);
QCOMPARE(end, 2);
- QCOMPARE(textIface->textAtOffset(5, QAccessible2::CharBoundary,&start,&end), QString::fromLatin1("a"));
+ QCOMPARE(textIface->textAtOffset(5, QAccessible::CharBoundary,&start,&end), QString::fromLatin1("a"));
QCOMPARE(start, 5);
QCOMPARE(end, 6);
- QCOMPARE(textIface->textBeforeOffset(5, QAccessible2::CharBoundary,&start,&end), QString::fromLatin1("w"));
- QCOMPARE(textIface->textAfterOffset(5, QAccessible2::CharBoundary,&start,&end), QString::fromLatin1("y"));
+ QCOMPARE(textIface->textBeforeOffset(5, QAccessible::CharBoundary,&start,&end), QString::fromLatin1("w"));
+ QCOMPARE(textIface->textAfterOffset(5, QAccessible::CharBoundary,&start,&end), QString::fromLatin1("y"));
- QCOMPARE(textIface->textAtOffset(5, QAccessible2::WordBoundary,&start,&end), QString::fromLatin1("always"));
+ QCOMPARE(textIface->textAtOffset(5, QAccessible::WordBoundary,&start,&end), QString::fromLatin1("always"));
QCOMPARE(start, 2);
QCOMPARE(end, 8);
- QCOMPARE(textIface->textAtOffset(2, QAccessible2::WordBoundary,&start,&end), QString::fromLatin1("always"));
- QCOMPARE(textIface->textAtOffset(7, QAccessible2::WordBoundary,&start,&end), QString::fromLatin1("always"));
- QCOMPARE(textIface->textAtOffset(8, QAccessible2::WordBoundary,&start,&end), QString::fromLatin1(" "));
- QCOMPARE(textIface->textAtOffset(25, QAccessible2::WordBoundary,&start,&end), QString::fromLatin1("advice"));
- QCOMPARE(textIface->textAtOffset(92, QAccessible2::WordBoundary,&start,&end), QString::fromLatin1("oneself"));
- QCOMPARE(textIface->textAtOffset(101, QAccessible2::WordBoundary,&start,&end), QString::fromLatin1(". --"));
+ QCOMPARE(textIface->textAtOffset(2, QAccessible::WordBoundary,&start,&end), QString::fromLatin1("always"));
+ QCOMPARE(textIface->textAtOffset(7, QAccessible::WordBoundary,&start,&end), QString::fromLatin1("always"));
+ QCOMPARE(textIface->textAtOffset(8, QAccessible::WordBoundary,&start,&end), QString::fromLatin1(" "));
+ QCOMPARE(textIface->textAtOffset(25, QAccessible::WordBoundary,&start,&end), QString::fromLatin1("advice"));
+ QCOMPARE(textIface->textAtOffset(92, QAccessible::WordBoundary,&start,&end), QString::fromLatin1("oneself"));
+ QCOMPARE(textIface->textAtOffset(101, QAccessible::WordBoundary,&start,&end), QString::fromLatin1(". --"));
- QCOMPARE(textIface->textBeforeOffset(5, QAccessible2::WordBoundary,&start,&end), QString::fromLatin1(" "));
- QCOMPARE(textIface->textAfterOffset(5, QAccessible2::WordBoundary,&start,&end), QString::fromLatin1(" "));
- QCOMPARE(textIface->textAtOffset(5, QAccessible2::SentenceBoundary,&start,&end), QString::fromLatin1("I always pass on good advice. "));
+ QCOMPARE(textIface->textBeforeOffset(5, QAccessible::WordBoundary,&start,&end), QString::fromLatin1(" "));
+ QCOMPARE(textIface->textAfterOffset(5, QAccessible::WordBoundary,&start,&end), QString::fromLatin1(" "));
+ QCOMPARE(textIface->textAtOffset(5, QAccessible::SentenceBoundary,&start,&end), QString::fromLatin1("I always pass on good advice. "));
QCOMPARE(start, 0);
QCOMPARE(end, 30);
- QCOMPARE(textIface->textBeforeOffset(40, QAccessible2::SentenceBoundary,&start,&end), QString::fromLatin1("I always pass on good advice. "));
- QCOMPARE(textIface->textAfterOffset(5, QAccessible2::SentenceBoundary,&start,&end), QString::fromLatin1("It is the only thing to do with it. "));
+ QCOMPARE(textIface->textBeforeOffset(40, QAccessible::SentenceBoundary,&start,&end), QString::fromLatin1("I always pass on good advice. "));
+ QCOMPARE(textIface->textAfterOffset(5, QAccessible::SentenceBoundary,&start,&end), QString::fromLatin1("It is the only thing to do with it. "));
- QCOMPARE(textIface->textAtOffset(5, QAccessible2::ParagraphBoundary,&start,&end), cite);
+ QCOMPARE(textIface->textAtOffset(5, QAccessible::ParagraphBoundary,&start,&end), cite);
QCOMPARE(start, 0);
QCOMPARE(end, cite.length());
- QCOMPARE(textIface->textAtOffset(5, QAccessible2::LineBoundary,&start,&end), cite);
- QCOMPARE(textIface->textAtOffset(5, QAccessible2::NoBoundary,&start,&end), cite);
+ QCOMPARE(textIface->textAtOffset(5, QAccessible::LineBoundary,&start,&end), cite);
+ QCOMPARE(textIface->textAtOffset(5, QAccessible::NoBoundary,&start,&end), cite);
QTestAccessibility::clearEvents();
}
@@ -1924,7 +1979,7 @@ void tst_QAccessibility::lineEditTest()
// characterRect()
le.show();
QTest::qWaitForWindowShown(&le);
- QAIPtr iface(QAccessible::queryAccessibleInterface(&le));
+ QAccessibleInterface *iface(QAccessible::queryAccessibleInterface(&le));
QAccessibleTextInterface* textIface = iface->textInterface();
QVERIFY(textIface);
const QRect lineEditRect = iface->rect();
@@ -2062,10 +2117,6 @@ void tst_QAccessibility::groupBoxTest()
QCOMPARE(relation.first->object(), groupBox);
QCOMPARE(relation.second, QAccessible::Label);
- delete relation.first;
-
- delete rButtonIface;
- delete iface;
delete groupBox;
}
@@ -2095,7 +2146,6 @@ void tst_QAccessibility::groupBoxTest()
QAccessibleStateChangeEvent ev2(groupBox, st);
QVERIFY_EVENT(&ev2);
- delete iface;
delete groupBox;
}
}
@@ -2161,7 +2211,6 @@ void tst_QAccessibility::dialogButtonBoxTest()
break;
}
QCOMPARE(actualOrder, expectedOrder);
- delete iface;
QApplication::processEvents();
QTestAccessibility::clearEvents();
}
@@ -2201,7 +2250,6 @@ void tst_QAccessibility::dialogButtonBoxTest()
<< QDialogButtonBox::tr("Help");
QCOMPARE(actualOrder, expectedOrder);
- delete iface;
QApplication::processEvents();
}
@@ -2251,7 +2299,6 @@ void tst_QAccessibility::rubberBandTest()
QAccessibleInterface *interface = QAccessible::queryAccessibleInterface(&rubberBand);
QVERIFY(interface);
QCOMPARE(interface->role(), QAccessible::Border);
- delete interface;
QTestAccessibility::clearEvents();
}
@@ -2336,7 +2383,6 @@ void tst_QAccessibility::abstractScrollAreaTest()
QCOMPARE(verifyHierarchy(interface), 0);
- delete interface;
}
QTestAccessibility::clearEvents();
@@ -2354,7 +2400,6 @@ void tst_QAccessibility::scrollAreaTest()
QAccessibleInterface *interface = QAccessible::queryAccessibleInterface(&scrollArea);
QVERIFY(interface);
QCOMPARE(interface->childCount(), 1); // The viewport.
- delete interface;
}
QTestAccessibility::clearEvents();
}
@@ -2372,27 +2417,27 @@ void tst_QAccessibility::listTest()
QCoreApplication::processEvents();
QTest::qWait(100);
- QAIPtr iface = QAIPtr(QAccessible::queryAccessibleInterface(listView));
- QCOMPARE(verifyHierarchy(iface.data()), 0);
+ QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(listView);
+ QCOMPARE(verifyHierarchy(iface), 0);
QCOMPARE((int)iface->role(), (int)QAccessible::List);
QCOMPARE(iface->childCount(), 3);
{
- QAIPtr child1 = QAIPtr(iface->child(0));
+ QAccessibleInterface *child1 = iface->child(0);
QVERIFY(child1);
- QCOMPARE(iface->indexOfChild(child1.data()), 0);
+ QCOMPARE(iface->indexOfChild(child1), 0);
QCOMPARE(child1->text(QAccessible::Name), QString("Oslo"));
QCOMPARE(child1->role(), QAccessible::ListItem);
- QAIPtr child2 = QAIPtr(iface->child(1));
+ QAccessibleInterface *child2 = iface->child(1);
QVERIFY(child2);
- QCOMPARE(iface->indexOfChild(child2.data()), 1);
+ QCOMPARE(iface->indexOfChild(child2), 1);
QCOMPARE(child2->text(QAccessible::Name), QString("Berlin"));
- QAIPtr child3 = QAIPtr(iface->child(2));
+ QAccessibleInterface *child3 = iface->child(2);
QVERIFY(child3);
- QCOMPARE(iface->indexOfChild(child3.data()), 2);
+ QCOMPARE(iface->indexOfChild(child3), 2);
QCOMPARE(child3->text(QAccessible::Name), QString("Brisbane"));
}
QTestAccessibility::clearEvents();
@@ -2422,11 +2467,11 @@ void tst_QAccessibility::listTest()
QVERIFY(table2);
QCOMPARE(table2->columnCount(), 1);
QCOMPARE(table2->rowCount(), 4);
- QAIPtr cell1 = QAIPtr(table2->cellAt(0,0));
+ QAccessibleInterface *cell1 = table2->cellAt(0,0);
QVERIFY(cell1);
QCOMPARE(cell1->text(QAccessible::Name), QString("Oslo"));
- QAIPtr cell4 = QAIPtr(table2->cellAt(3,0));
+ QAccessibleInterface *cell4 = table2->cellAt(3,0);
QVERIFY(cell4);
QCOMPARE(cell4->text(QAccessible::Name), QString("Munich"));
QCOMPARE(cell4->role(), QAccessible::ListItem);
@@ -2440,7 +2485,7 @@ void tst_QAccessibility::listTest()
QCOMPARE(cellInterface->rowHeaderCells(), QList<QAccessibleInterface*>());
QCOMPARE(cellInterface->columnHeaderCells(), QList<QAccessibleInterface*>());
- QCOMPARE(QAIPtr(cellInterface->table())->object(), listView);
+ QCOMPARE(cellInterface->table()->object(), listView);
listView->clearSelection();
QVERIFY(!(cell4->state().expandable));
@@ -2457,6 +2502,25 @@ void tst_QAccessibility::listTest()
QVERIFY(table2->cellAt(0, 1) == 0);
QVERIFY(table2->cellAt(4, 0) == 0);
+ // verify that unique id stays the same
+ QAccessible::Id axidMunich = QAccessible::uniqueId(cell4);
+ // insertion and deletion of items
+ listView->insertItem(1, "Helsinki");
+ // list: Oslo, Helsinki, Berlin, Brisbane, Munich
+
+ QAccessibleInterface *cellMunich2 = table2->cellAt(4,0);
+ QCOMPARE(cell4, cellMunich2);
+ QCOMPARE(axidMunich, QAccessible::uniqueId(cellMunich2));
+
+ delete listView->takeItem(2);
+ delete listView->takeItem(2);
+ // list: Oslo, Helsinki, Munich
+
+ QAccessibleInterface *cellMunich3 = table2->cellAt(2,0);
+ QCOMPARE(cell4, cellMunich3);
+ QCOMPARE(axidMunich, QAccessible::uniqueId(cellMunich3));
+
+
delete listView;
}
QTestAccessibility::clearEvents();
@@ -2512,29 +2576,24 @@ void tst_QAccessibility::treeTest()
// header and 2 rows (the others are not expanded, thus not visible)
QCOMPARE(iface->childCount(), 6);
- QAccessibleInterface *header1 = 0;
- header1 = iface->child(0);
+ QAccessibleInterface *header1 = iface->child(0);
QVERIFY(header1);
QCOMPARE(iface->indexOfChild(header1), 0);
QCOMPARE(header1->text(QAccessible::Name), QString("Artist"));
QCOMPARE(header1->role(), QAccessible::ColumnHeader);
- delete header1;
- QAccessibleInterface *child1 = 0;
- child1 = iface->child(2);
+ QAccessibleInterface *child1 = iface->child(2);
QVERIFY(child1);
QCOMPARE(iface->indexOfChild(child1), 2);
QCOMPARE(child1->text(QAccessible::Name), QString("Spain"));
QCOMPARE(child1->role(), QAccessible::TreeItem);
QVERIFY(!(child1->state().expanded));
- delete child1;
QAccessibleInterface *child2 = 0;
child2 = iface->child(4);
QVERIFY(child2);
QCOMPARE(iface->indexOfChild(child2), 4);
QCOMPARE(child2->text(QAccessible::Name), QString("Austria"));
- delete child2;
QTestAccessibility::clearEvents();
@@ -2556,8 +2615,6 @@ void tst_QAccessibility::treeTest()
QCOMPARE(iface->indexOfChild(cell2), 4);
QVERIFY(!(cell2->state().expanded));
QCOMPARE(table2->columnDescription(1), QString("Work"));
- delete cell2;
- delete cell1;
treeView->expandAll();
@@ -2583,14 +2640,13 @@ void tst_QAccessibility::treeTest()
QModelIndex index = treeView->model()->index(0, 0, treeView->model()->index(1, 0));
pos += treeView->visualRect(index).center();
pos += QPoint(0, treeView->header()->height());
- QAIPtr childAt2(iface->childAt(pos.x(), pos.y()));
+ QAccessibleInterface *childAt2(iface->childAt(pos.x(), pos.y()));
QVERIFY(childAt2);
QCOMPARE(childAt2->text(QAccessible::Name), QString("Klimt"));
QCOMPARE(table2->columnDescription(0), QString("Artist"));
QCOMPARE(table2->columnDescription(1), QString("Work"));
- delete iface;
delete treeView;
QTestAccessibility::clearEvents();
}
@@ -2622,36 +2678,36 @@ void tst_QAccessibility::tableTest()
tableView->show();
QTest::qWaitForWindowExposed(tableView);
- QAIPtr iface = QAIPtr(QAccessible::queryAccessibleInterface(tableView));
- QCOMPARE(verifyHierarchy(iface.data()), 0);
+ QAccessibleInterface *iface = QAccessible::queryAccessibleInterface(tableView);
+ QCOMPARE(verifyHierarchy(iface), 0);
QCOMPARE(iface->role(), QAccessible::Table);
// header and 2 rows (the others are not expanded, thus not visible)
QCOMPARE(iface->childCount(), 9+3+3+1); // cell+headers+topleft button
- QAIPtr cornerButton(iface->child(0));
+ QAccessibleInterface *cornerButton(iface->child(0));
QVERIFY(cornerButton);
- QCOMPARE(iface->indexOfChild(cornerButton.data()), 0);
+ QCOMPARE(iface->indexOfChild(cornerButton), 0);
QCOMPARE(cornerButton->role(), QAccessible::Pane);
- QAIPtr h2(iface->child(2));
+ QAccessibleInterface *h2(iface->child(2));
QVERIFY(h2);
- QCOMPARE(iface->indexOfChild(h2.data()), 2);
+ QCOMPARE(iface->indexOfChild(h2), 2);
QCOMPARE(h2->text(QAccessible::Name), QString("h2"));
QCOMPARE(h2->role(), QAccessible::ColumnHeader);
QVERIFY(!(h2->state().expanded));
- QAIPtr v3(iface->child(12));
+ QAccessibleInterface *v3(iface->child(12));
QVERIFY(v3);
- QCOMPARE(iface->indexOfChild(v3.data()), 12);
+ QCOMPARE(iface->indexOfChild(v3), 12);
QCOMPARE(v3->text(QAccessible::Name), QString("v3"));
QCOMPARE(v3->role(), QAccessible::RowHeader);
QVERIFY(!(v3->state().expanded));
- QAIPtr child10(iface->child(10));
+ QAccessibleInterface *child10(iface->child(10));
QVERIFY(child10);
- QCOMPARE(iface->indexOfChild(child10.data()), 10);
+ QCOMPARE(iface->indexOfChild(child10), 10);
QCOMPARE(child10->text(QAccessible::Name), QString("1.1"));
QAccessibleTableCellInterface *cell10Iface = child10->tableCellInterface();
QCOMPARE(cell10Iface->rowIndex(), 1);
@@ -2659,11 +2715,11 @@ void tst_QAccessibility::tableTest()
QPoint pos = tableView->mapToGlobal(QPoint(0,0));
pos += tableView->visualRect(tableView->model()->index(1, 1)).center();
pos += QPoint(tableView->verticalHeader()->width(), tableView->horizontalHeader()->height());
- QAIPtr childAt10(iface->childAt(pos.x(), pos.y()));
+ QAccessibleInterface *childAt10(iface->childAt(pos.x(), pos.y()));
QCOMPARE(childAt10->text(QAccessible::Name), QString("1.1"));
- QAIPtr child11(iface->child(11));
- QCOMPARE(iface->indexOfChild(child11.data()), 11);
+ QAccessibleInterface *child11(iface->child(11));
+ QCOMPARE(iface->indexOfChild(child11), 11);
QCOMPARE(child11->text(QAccessible::Name), QString("1.2"));
@@ -2679,21 +2735,21 @@ void tst_QAccessibility::tableTest()
QCOMPARE(cell1->text(QAccessible::Name), QString("0.0"));
QCOMPARE(iface->indexOfChild(cell1), 5);
- QAIPtr cell2(table2->cellAt(0,1));
+ QAccessibleInterface *cell2(table2->cellAt(0,1));
QVERIFY(cell2);
QCOMPARE(cell2->text(QAccessible::Name), QString("0.1"));
QCOMPARE(cell2->role(), QAccessible::Cell);
QCOMPARE(cell2->tableCellInterface()->rowIndex(), 0);
QCOMPARE(cell2->tableCellInterface()->columnIndex(), 1);
- QCOMPARE(iface->indexOfChild(cell2.data()), 6);
+ QCOMPARE(iface->indexOfChild(cell2), 6);
- QAIPtr cell3(table2->cellAt(1,2));
+ QAccessibleInterface *cell3(table2->cellAt(1,2));
QVERIFY(cell3);
QCOMPARE(cell3->text(QAccessible::Name), QString("1.2"));
QCOMPARE(cell3->role(), QAccessible::Cell);
QCOMPARE(cell3->tableCellInterface()->rowIndex(), 1);
QCOMPARE(cell3->tableCellInterface()->columnIndex(), 2);
- QCOMPARE(iface->indexOfChild(cell3.data()), 11);
+ QCOMPARE(iface->indexOfChild(cell3), 11);
QCOMPARE(table2->columnDescription(0), QString("h1"));
QCOMPARE(table2->columnDescription(1), QString("h2"));
@@ -2702,8 +2758,171 @@ void tst_QAccessibility::tableTest()
QCOMPARE(table2->rowDescription(1), QString("v2"));
QCOMPARE(table2->rowDescription(2), QString("v3"));
+ tableView->clearSelection();
+ tableView->setSelectionBehavior(QAbstractItemView::SelectItems);
+ tableView->setSelectionMode(QAbstractItemView::SingleSelection);
+ QVERIFY(!table2->selectRow(0));
+ QVERIFY(!table2->isRowSelected(0));
+ tableView->setSelectionBehavior(QAbstractItemView::SelectRows);
+ QVERIFY(table2->selectRow(0));
+ QVERIFY(table2->selectRow(1));
+ QVERIFY(!table2->isRowSelected(0));
+ tableView->setSelectionMode(QAbstractItemView::MultiSelection);
+ QVERIFY(table2->selectRow(0));
+ QVERIFY(table2->isRowSelected(1));
+ QVERIFY(table2->unselectRow(0));
+ QVERIFY(!table2->isRowSelected(0));
+ tableView->setSelectionBehavior(QAbstractItemView::SelectColumns);
+ QVERIFY(!table2->selectRow(0));
+ QVERIFY(!table2->isRowSelected(0));
+ tableView->clearSelection();
+ QCOMPARE(table2->selectedColumnCount(), 0);
+ QCOMPARE(table2->selectedRowCount(), 0);
+ QVERIFY(table2->selectColumn(1));
+ QVERIFY(table2->isColumnSelected(1));
+ tableView->clearSelection();
+ tableView->setSelectionMode(QAbstractItemView::ContiguousSelection);
+ table2->selectColumn(0);
+ table2->selectColumn(2);
+ QVERIFY(!(table2->isColumnSelected(2) && table2->isColumnSelected(0)));
+ tableView->clearSelection();
+ tableView->setSelectionBehavior(QAbstractItemView::SelectItems);
+ tableView->setSelectionMode(QAbstractItemView::MultiSelection);
+ table2->selectColumn(1);
+ table2->selectRow(1);
+ QVERIFY(table2->isColumnSelected(1));
+ QVERIFY(table2->isRowSelected(1));
+
+ QAccessibleInterface *cell4 = table2->cellAt(2,2);
+ QVERIFY(cell1->actionInterface());
+ QVERIFY(cell1->tableCellInterface());
+
+ tableView->clearSelection();
+ tableView->setSelectionBehavior(QAbstractItemView::SelectRows);
+ tableView->setSelectionMode(QAbstractItemView::SingleSelection);
+ QVERIFY(!cell1->tableCellInterface()->isSelected());
+ QVERIFY(cell1->actionInterface()->actionNames().contains(QAccessibleActionInterface::toggleAction()));
+ cell1->actionInterface()->doAction(QAccessibleActionInterface::toggleAction());
+ QVERIFY(cell2->tableCellInterface()->isSelected());
+
+ tableView->clearSelection();
+ tableView->setSelectionBehavior(QAbstractItemView::SelectColumns);
+ cell3->actionInterface()->doAction(QAccessibleActionInterface::toggleAction());
+ QVERIFY(cell4->tableCellInterface()->isSelected());
+
+ tableView->clearSelection();
+ tableView->setSelectionBehavior(QAbstractItemView::SelectItems);
+ tableView->setSelectionMode(QAbstractItemView::SingleSelection);
+ cell1->actionInterface()->doAction(QAccessibleActionInterface::toggleAction());
+ QVERIFY(cell1->tableCellInterface()->isSelected());
+ cell2->actionInterface()->doAction(QAccessibleActionInterface::toggleAction());
+ QVERIFY(!cell1->tableCellInterface()->isSelected());
+
+ tableView->clearSelection();
+ tableView->setSelectionMode(QAbstractItemView::MultiSelection);
+ cell1->actionInterface()->doAction(QAccessibleActionInterface::toggleAction());
+ cell2->actionInterface()->doAction(QAccessibleActionInterface::toggleAction());
+ QVERIFY(cell1->tableCellInterface()->isSelected());
+ QVERIFY(cell2->tableCellInterface()->isSelected());
+ cell2->actionInterface()->doAction(QAccessibleActionInterface::toggleAction());
+ QVERIFY(cell1->tableCellInterface()->isSelected());
+ QVERIFY(!cell2->tableCellInterface()->isSelected());
+
+ QAccessibleInterface *cell00 = table2->cellAt(0, 0);
+ QAccessible::Id id00 = QAccessible::uniqueId(cell00);
+ QVERIFY(id00);
+ QCOMPARE(cell00->tableCellInterface()->rowIndex(), 0);
+ QCOMPARE(cell00->tableCellInterface()->columnIndex(), 0);
+
+ QAccessibleInterface *cell01 = table2->cellAt(0, 1);
+
+ QAccessibleInterface *cell02 = table2->cellAt(0, 2);
+ QAccessible::Id id02 = QAccessible::uniqueId(cell02);
+ QVERIFY(id02);
+ QCOMPARE(cell02->tableCellInterface()->rowIndex(), 0);
+ QCOMPARE(cell02->tableCellInterface()->columnIndex(), 2);
+
+ QAccessibleInterface *cell20 = table2->cellAt(2, 0);
+ QAccessible::Id id20 = QAccessible::uniqueId(cell20);
+ QVERIFY(id20);
+ QCOMPARE(cell20->tableCellInterface()->rowIndex(), 2);
+ QCOMPARE(cell20->tableCellInterface()->columnIndex(), 0);
+
+ QAccessibleInterface *cell22 = table2->cellAt(2, 2);
+ QAccessible::Id id22 = QAccessible::uniqueId(cell22);
+ QVERIFY(id22);
+ QCOMPARE(cell22->tableCellInterface()->rowIndex(), 2);
+ QCOMPARE(cell22->tableCellInterface()->columnIndex(), 2);
+
+ // modification: inserting and removing rows/columns
+ tableView->insertRow(2);
+ // Button (0) | h1 (1) | h2 (2) | h3 (3)
+ // v1 (4) | 0.0 (5) | 1.0 (6) | 2.0 (7)
+ // v2 (8) | 0.1 (9) | 1.1 (10) | 2.1 (11)
+ // new (12) | (13) | (14) | (15)
+ // v3 (16) | 0.2 (17) | 1.2 (18) | 2.2 (19)
+
+ QAccessibleInterface *cell00_new = table2->cellAt(0, 0);
+ QCOMPARE(cell00, cell00_new);
+ QCOMPARE(cell00->tableCellInterface()->rowIndex(), 0);
+ QCOMPARE(cell00->tableCellInterface()->columnIndex(), 0);
+
+ QAccessibleInterface *cell02_new = table2->cellAt(0, 2);
+ QCOMPARE(cell02, cell02_new);
+ QCOMPARE(cell02_new->tableCellInterface()->rowIndex(), 0);
+ QCOMPARE(cell02_new->tableCellInterface()->columnIndex(), 2);
+
+ QAccessibleInterface *cell20_new = table2->cellAt(2, 0);
+ QAccessibleInterface *cell30_new = table2->cellAt(3, 0);
+ QAccessible::Id id20_new = QAccessible::uniqueId(cell20_new);
+ QVERIFY(id20_new != id20);
+ QAccessible::Id id30_new = QAccessible::uniqueId(cell30_new);
+ QCOMPARE(id20, id30_new);
+ QCOMPARE(cell20->tableCellInterface()->rowIndex(), 3);
+ QCOMPARE(cell20->tableCellInterface()->columnIndex(), 0);
+
+ QAccessibleInterface *cell22_new = table2->cellAt(2, 2);
+ QAccessibleInterface *cell32_new = table2->cellAt(3, 2);
+ QAccessible::Id id22_new = QAccessible::uniqueId(cell22_new);
+ QVERIFY(id22_new != id22);
+ QAccessible::Id id32_new = QAccessible::uniqueId(cell32_new);
+ QCOMPARE(id22, id32_new);
+ QCOMPARE(cell32_new->tableCellInterface()->rowIndex(), 3);
+ QCOMPARE(cell32_new->tableCellInterface()->columnIndex(), 2);
+
+
+ QVERIFY(table2->cellAt(0, 0) == cell1);
+
+ tableView->insertColumn(2);
+ // Button (0) | h1 (1) | h2 (2) | (3) | h3 (4)
+ // v1 (5) | 0.0 (6) | 1.0 (7) | (8) | 2.0 (9)
+ // v2 (10) | 0.1 (11) | 1.1 (12) | (13) | 2.1 (14)
+ // new (15) | (16) | (17) | (18) | (19)
+ // v3 (20) | 0.2 (21) | 1.2 (22) | (23) | 2.2 (24)
+
+ cell00_new = table2->cellAt(0, 0);
+ QCOMPARE(cell00, cell00_new);
+ QCOMPARE(cell00->tableCellInterface()->rowIndex(), 0);
+ QCOMPARE(cell00->tableCellInterface()->columnIndex(), 0);
+
+ QAccessibleInterface *cell01_new = table2->cellAt(0, 1);
+ QCOMPARE(cell01, cell01_new);
+ QCOMPARE(cell01_new->tableCellInterface()->rowIndex(), 0);
+ QCOMPARE(cell01_new->tableCellInterface()->columnIndex(), 1);
+
+ QAccessibleInterface *cell03_new = table2->cellAt(0, 3);
+ QVERIFY(cell03_new);
+ QCOMPARE(cell03_new->tableCellInterface()->rowIndex(), 0);
+ QCOMPARE(cell03_new->tableCellInterface()->columnIndex(), 3);
+ QCOMPARE(iface->indexOfChild(cell03_new), 9);
+ QCOMPARE(cell03_new, cell02);
+
+ cell30_new = table2->cellAt(3, 0);
+ QCOMPARE(cell30_new, cell20);
+ QCOMPARE(iface->indexOfChild(cell30_new), 21);
delete tableView;
+ QVERIFY(!QAccessible::accessibleInterface(id00));
QTestAccessibility::clearEvents();
}
@@ -2780,9 +2999,7 @@ void tst_QAccessibility::calendarWidgetTest()
// In order for geometric navigation to work they must share the same parent
QCOMPARE(navigationBarInterface->parent()->object(), calendarViewInterface->parent()->object());
QVERIFY(navigationBarInterface->rect().bottom() < calendarViewInterface->rect().top());
- delete calendarViewInterface;
calendarViewInterface = 0;
- delete navigationBarInterface;
navigationBarInterface = 0;
}
@@ -2827,8 +3044,6 @@ void tst_QAccessibility::dockWidgetTest()
if (accMainWindow->role() == QAccessible::Window) {
if (accDock1 && qobject_cast<QDockWidget*>(accDock1->object()) == dock1) {
break;
- } else {
- delete accDock1;
}
}
}
@@ -2838,7 +3053,6 @@ void tst_QAccessibility::dockWidgetTest()
QAccessibleInterface *dock1TitleBar = accDock1->child(0);
QCOMPARE(dock1TitleBar->role(), QAccessible::TitleBar);
QVERIFY(accDock1->rect().contains(dock1TitleBar->rect()));
- delete dock1TitleBar;
QPoint globalPos = dock1->mapToGlobal(QPoint(0,0));
globalPos.rx()+=5; //### query style
@@ -2846,7 +3060,6 @@ void tst_QAccessibility::dockWidgetTest()
QAccessibleInterface *childAt = accDock1->childAt(globalPos.x(), globalPos.y()); //###
QCOMPARE(childAt->role(), QAccessible::TitleBar);
int index = accDock1->indexOfChild(childAt);
- delete childAt;
QAccessibleInterface *accTitleBar = accDock1->child(index);
QCOMPARE(accTitleBar->role(), QAccessible::TitleBar);
@@ -2856,9 +3069,6 @@ void tst_QAccessibility::dockWidgetTest()
QVERIFY(acc);
QCOMPARE(acc->role(), QAccessible::Window);
-
- delete accTitleBar;
- delete accDock1;
delete pb1;
delete pb2;
delete dock1;
@@ -2908,7 +3118,6 @@ void tst_QAccessibility::comboBoxTest()
iface->actionInterface()->doAction(QAccessibleActionInterface::showMenuAction());
QTRY_VERIFY(combo.view()->isVisible());
- delete iface;
}
{ // editable combobox
@@ -2928,10 +3137,6 @@ void tst_QAccessibility::comboBoxTest()
QCOMPARE(listIface->role(), QAccessible::List);
QAccessibleInterface *editIface = iface->child(1);
QCOMPARE(editIface->role(), QAccessible::EditableText);
-
- delete listIface;
- delete editIface;
- delete iface;
}
QTestAccessibility::clearEvents();
@@ -2954,7 +3159,6 @@ void tst_QAccessibility::labelTest()
QCOMPARE(acc_label->text(QAccessible::Name), text);
- delete acc_label;
delete label;
QTestAccessibility::clearEvents();
@@ -2976,8 +3180,6 @@ void tst_QAccessibility::labelTest()
const QPoint labelPos = imageLabel.mapToGlobal(QPoint(0,0));
QCOMPARE(imageInterface->imagePosition().topLeft(), labelPos);
- delete acc_label;
-
QTestAccessibility::clearEvents();
}
@@ -3247,8 +3449,9 @@ void tst_QAccessibility::bridgeTest()
IAccessible *accTableCell = 0;
hr = ia2Table->get_cellAt(1, 2, (IUnknown**)&accTableCell);
- IAccessibleTableCell *ia2TableCell = (IAccessibleTableCell *)queryIA2(accTableCell, IID_IAccessibleTableCell);
QVERIFY(SUCCEEDED(hr));
+ QVERIFY(accTableCell);
+ IAccessibleTableCell *ia2TableCell = (IAccessibleTableCell *)queryIA2(accTableCell, IID_IAccessibleTableCell);
QVERIFY(ia2TableCell);
LONG index;
ia2TableCell->get_rowIndex(&index);
diff --git a/tests/auto/other/qnetworkaccessmanager_and_qprogressdialog/tst_qnetworkaccessmanager_and_qprogressdialog.cpp b/tests/auto/other/qnetworkaccessmanager_and_qprogressdialog/tst_qnetworkaccessmanager_and_qprogressdialog.cpp
index c6cc50d97f..756a899b1b 100644
--- a/tests/auto/other/qnetworkaccessmanager_and_qprogressdialog/tst_qnetworkaccessmanager_and_qprogressdialog.cpp
+++ b/tests/auto/other/qnetworkaccessmanager_and_qprogressdialog/tst_qnetworkaccessmanager_and_qprogressdialog.cpp
@@ -82,7 +82,7 @@ public slots:
QNetworkRequest request(QUrl("http://" + QtNetworkSettings::serverName() + "/qtest/bigfile"));
if (zeroCopy)
request.setAttribute(QNetworkRequest::MaximumDownloadBufferSizeAttribute, 10*1024*1024);
-
+
QNetworkReply *reply = netmanager.get(
QNetworkRequest(
QUrl("http://" + QtNetworkSettings::serverName() + "/qtest/bigfile")
diff --git a/tests/auto/other/windowsmobile/test/tst_windowsmobile.cpp b/tests/auto/other/windowsmobile/test/tst_windowsmobile.cpp
index 5bcaaf5543..68db218164 100644
--- a/tests/auto/other/windowsmobile/test/tst_windowsmobile.cpp
+++ b/tests/auto/other/windowsmobile/test/tst_windowsmobile.cpp
@@ -133,7 +133,7 @@ void compareScreenshots(const QString &image1, const QString &image2)
QPainter p1(&screenShot);
QPainter p2(&original);
- //screenShot.save("scr1.png", "PNG");
+ //screenShot.save("scr1.png", "PNG");
p1.fillRect(0, 0, desktopFrameRect.width(), desktopClientRect.y(), Qt::black);
p2.fillRect(0, 0, desktopFrameRect.width(), desktopClientRect.y(), Qt::black);
diff --git a/tests/auto/other/windowsmobile/testQMenuBar/main.cpp b/tests/auto/other/windowsmobile/testQMenuBar/main.cpp
index 64f87dc080..a96966a451 100644
--- a/tests/auto/other/windowsmobile/testQMenuBar/main.cpp
+++ b/tests/auto/other/windowsmobile/testQMenuBar/main.cpp
@@ -89,7 +89,7 @@ int main(int argc, char * argv[])
optionsMenu->addMenu("Settings");
optionsMenu->addMenu("Standard");
optionsMenu->addMenu("Extended");
-
+
QMenu *subMenu = helpMenu->addMenu("Help");
subMenu->addAction("Index");
subMenu->addSeparator();
diff --git a/tests/auto/sql/kernel/qsql/qsql.pro b/tests/auto/sql/kernel/qsql/qsql.pro
index 980a35b99f..0735986438 100644
--- a/tests/auto/sql/kernel/qsql/qsql.pro
+++ b/tests/auto/sql/kernel/qsql/qsql.pro
@@ -3,11 +3,10 @@ CONFIG += parallel_test
TARGET = tst_qsql
SOURCES += tst_qsql.cpp
-QT += sql sql-private gui testlib
+QT += sql sql-private gui testlib core-private
wince*: {
DEPLOYMENT_PLUGIN += qsqlite
}
win32-g++*: LIBS += -lws2_32
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/sql/kernel/qsql/tst_qsql.cpp b/tests/auto/sql/kernel/qsql/tst_qsql.cpp
index bb00f52969..bc6b36931a 100644
--- a/tests/auto/sql/kernel/qsql/tst_qsql.cpp
+++ b/tests/auto/sql/kernel/qsql/tst_qsql.cpp
@@ -56,7 +56,7 @@
class tst_QSql : public QObject
{
-Q_OBJECT
+ Q_OBJECT
public:
tst_QSql();
@@ -105,7 +105,6 @@ void tst_QSql::cleanup()
{
}
-
// this is a very basic test for drivers that cannot create/delete tables
// it can be used while developing new drivers,
// it's original purpose is to test ODBC Text datasources that are basically
@@ -120,35 +119,34 @@ void tst_QSql::basicDriverTest()
tst_Databases dbs;
dbs.open();
- foreach( const QString& dbName, dbs.dbNames )
- {
- QSqlDatabase db = QSqlDatabase::database( dbName );
- QVERIFY_SQL( db, isValid() );
+ foreach (const QString& dbName, dbs.dbNames) {
+ QSqlDatabase db = QSqlDatabase::database(dbName);
+ QVERIFY_SQL(db, isValid());
QStringList tables = db.tables();
QString tableName;
- if ( tables.contains( "qtest_basictest.txt" ) )
+ if (tables.contains("qtest_basictest.txt"))
tableName = "qtest_basictest.txt";
- else if ( tables.contains( "qtest_basictest" ) )
+ else if (tables.contains("qtest_basictest"))
tableName = "qtest_basictest";
- else if ( tables.contains( "QTEST_BASICTEST" ) )
+ else if (tables.contains("QTEST_BASICTEST"))
tableName = "QTEST_BASICTEST";
else {
- QVERIFY( 1 );
+ QVERIFY(1);
continue;
}
- qDebug("Testing: %s", qPrintable(tst_Databases::dbToString( db )));
+ qDebug("Testing: %s", qPrintable(tst_Databases::dbToString(db)));
- QSqlRecord rInf = db.record( tableName );
- QCOMPARE( rInf.count(), 2 );
- QCOMPARE( rInf.fieldName( 0 ).toLower(), QString( "id" ) );
- QCOMPARE( rInf.fieldName( 1 ).toLower(), QString( "name" ) );
+ QSqlRecord rInf = db.record(tableName);
+ QCOMPARE(rInf.count(), 2);
+ QCOMPARE(rInf.fieldName(0).toLower(), QString("id"));
+ QCOMPARE(rInf.fieldName(1).toLower(), QString("name"));
}
dbs.close();
- QVERIFY( 1 ); // make sure the test doesn't fail if no database drivers are there
+ QVERIFY(1); // make sure the test doesn't fail if no database drivers are there
}
// make sure that the static stuff will be deleted
@@ -159,18 +157,18 @@ void tst_QSql::open()
int argc = 1;
const char *argv[] = {"test"};
int count = -1;
- for ( i = 0; i < 10; ++i ) {
+ for (i = 0; i < 10; ++i) {
QGuiApplication app(argc, const_cast<char **>(argv), false);
- tst_Databases dbs;
-
- dbs.open();
- if ( count == -1 )
- // first iteration: see how many dbs are open
- count = (int) dbs.dbNames.count();
- else
- // next iterations: make sure all are opened again
- QCOMPARE( count, (int)dbs.dbNames.count() );
- dbs.close();
+ tst_Databases dbs;
+
+ dbs.open();
+ if (count == -1)
+ // first iteration: see how many dbs are open
+ count = (int) dbs.dbNames.count();
+ else
+ // next iterations: make sure all are opened again
+ QCOMPARE(count, (int)dbs.dbNames.count());
+ dbs.close();
}
}
@@ -191,21 +189,21 @@ void tst_QSql::concurrentAccess()
tst_Databases dbs;
dbs.open();
- foreach ( const QString& dbName, dbs.dbNames ) {
- QSqlDatabase db = QSqlDatabase::database( dbName );
- QVERIFY( db.isValid() );
+ foreach (const QString& dbName, dbs.dbNames) {
+ QSqlDatabase db = QSqlDatabase::database(dbName);
+ QVERIFY(db.isValid());
if (tst_Databases::isMSAccess(db))
continue;
- QSqlDatabase ndb = QSqlDatabase::addDatabase( db.driverName(), "tst_QSql::concurrentAccess" );
- ndb.setDatabaseName( db.databaseName() );
- ndb.setHostName( db.hostName() );
- ndb.setPort( db.port() );
- ndb.setUserName( db.userName() );
- ndb.setPassword( db.password() );
- QVERIFY_SQL( ndb, open() );
+ QSqlDatabase ndb = QSqlDatabase::addDatabase(db.driverName(), "tst_QSql::concurrentAccess");
+ ndb.setDatabaseName(db.databaseName());
+ ndb.setHostName(db.hostName());
+ ndb.setPort(db.port());
+ ndb.setUserName(db.userName());
+ ndb.setPassword(db.password());
+ QVERIFY_SQL(ndb, open());
- QCOMPARE( db.tables(), ndb.tables() );
+ QCOMPARE(db.tables(), ndb.tables());
}
// no database servers installed - don't fail
QVERIFY(1);
@@ -222,41 +220,41 @@ void tst_QSql::openErrorRecovery()
dbs.addDbs();
if (dbs.dbNames.isEmpty())
QSKIP("No database drivers installed");
- foreach ( const QString& dbName, dbs.dbNames ) {
- QSqlDatabase db = QSqlDatabase::database( dbName, false );
- CHECK_DATABASE( db );
+ foreach (const QString& dbName, dbs.dbNames) {
+ QSqlDatabase db = QSqlDatabase::database(dbName, false);
+ CHECK_DATABASE(db);
- QString userName = db.userName();
- QString password = db.password();
+ QString userName = db.userName();
+ QString password = db.password();
- // force an open error
- if ( db.open( "dummy130977", "doesnt_exist" ) ) {
+ // force an open error
+ if (db.open("dummy130977", "doesnt_exist")) {
qDebug("Promiscuous database server without access control - test skipped for %s",
- qPrintable(tst_Databases::dbToString( db )) );
- QVERIFY(1);
- continue;
- }
-
- QFAIL_SQL( db, isOpen() );
- QVERIFY_SQL( db, isOpenError() );
-
- // now open it
- if ( !db.open( userName, password ) ) {
- qDebug() << "Could not open Database " << tst_Databases::dbToString( db ) <<
- ". Assuming DB is down, skipping... (Error: " <<
- tst_Databases::printError( db.lastError() ) << ")";
- continue;
- }
- QVERIFY_SQL( db, open( userName, password ) );
- QVERIFY_SQL( db, isOpen() );
- QFAIL_SQL( db, isOpenError() );
- db.close();
- QFAIL_SQL( db, isOpen() );
-
- // force another open error
- QFAIL_SQL( db, open( "dummy130977", "doesnt_exist" ) );
- QFAIL_SQL( db, isOpen() );
- QVERIFY_SQL( db, isOpenError() );
+ qPrintable(tst_Databases::dbToString(db)));
+ QVERIFY(1);
+ continue;
+ }
+
+ QFAIL_SQL(db, isOpen());
+ QVERIFY_SQL(db, isOpenError());
+
+ // now open it
+ if (!db.open(userName, password)) {
+ qDebug() << "Could not open Database " << tst_Databases::dbToString(db) <<
+ ". Assuming DB is down, skipping... (Error: " <<
+ tst_Databases::printError(db.lastError()) << ")";
+ continue;
+ }
+ QVERIFY_SQL(db, open(userName, password));
+ QVERIFY_SQL(db, isOpen());
+ QFAIL_SQL(db, isOpenError());
+ db.close();
+ QFAIL_SQL(db, isOpen());
+
+ // force another open error
+ QFAIL_SQL(db, open("dummy130977", "doesnt_exist"));
+ QFAIL_SQL(db, isOpen());
+ QVERIFY_SQL(db, isOpenError());
}
}
@@ -266,13 +264,13 @@ void tst_QSql::registerSqlDriver()
const char *argv[] = {"test"};
QGuiApplication app(argc, const_cast<char **>(argv), false);
- QSqlDatabase::registerSqlDriver( "QSQLTESTDRIVER", new QSqlDriverCreator<QSqlNullDriver> );
- QVERIFY( QSqlDatabase::drivers().contains( "QSQLTESTDRIVER" ) );
+ QSqlDatabase::registerSqlDriver("QSQLTESTDRIVER", new QSqlDriverCreator<QSqlNullDriver>);
+ QVERIFY(QSqlDatabase::drivers().contains("QSQLTESTDRIVER"));
- QSqlDatabase db = QSqlDatabase::addDatabase( "QSQLTESTDRIVER" );
- QVERIFY( db.isValid() );
+ QSqlDatabase db = QSqlDatabase::addDatabase("QSQLTESTDRIVER");
+ QVERIFY(db.isValid());
- QCOMPARE( db.tables(), QStringList() );
+ QCOMPARE(db.tables(), QStringList());
}
QTEST_APPLESS_MAIN(tst_QSql)
diff --git a/tests/auto/sql/kernel/qsqldatabase/qsqldatabase.pro b/tests/auto/sql/kernel/qsqldatabase/qsqldatabase.pro
index ae11916a72..d562e47c55 100644
--- a/tests/auto/sql/kernel/qsqldatabase/qsqldatabase.pro
+++ b/tests/auto/sql/kernel/qsqldatabase/qsqldatabase.pro
@@ -2,7 +2,7 @@ CONFIG += testcase
TARGET = tst_qsqldatabase
SOURCES += tst_qsqldatabase.cpp
-QT = core sql testlib
+QT = core sql testlib core-private sql-private
win32: {
!wince*: LIBS += -lws2_32
@@ -17,4 +17,3 @@ wince*: {
DEPLOYMENT += testData
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/sql/kernel/qsqldatabase/tst_databases.h b/tests/auto/sql/kernel/qsqldatabase/tst_databases.h
index 9d3523576f..e47140b61b 100644
--- a/tests/auto/sql/kernel/qsqldatabase/tst_databases.h
+++ b/tests/auto/sql/kernel/qsqldatabase/tst_databases.h
@@ -52,7 +52,7 @@
#include <QVariant>
#include <QDebug>
#include <QSqlTableModel>
-
+#include <QtSql/private/qsqldriver_p.h>
#include <QtTest/QtTest>
#if defined (Q_OS_WIN) || defined (Q_OS_WIN32)
@@ -96,14 +96,26 @@ static QString qGetHostName()
// to prevent nameclashes on our database server, each machine
// will use its own set of table names. Call this function to get
// "tablename_hostname"
-inline static QString qTableName( const QString& prefix, const char *sourceFileName )
+inline QString fixupTableName(const QString &tableName, QSqlDatabase db)
+{
+ QString tbName = tableName;
+ // On Oracle we are limited to 30 character tablenames
+ QSqlDriverPrivate *d = static_cast<QSqlDriverPrivate *>(QObjectPrivate::get(db.driver()));
+ if (d && d->dbmsType == QSqlDriverPrivate::Oracle)
+ tbName.truncate(30);
+ return tbName;
+}
+
+inline static QString qTableName(const QString& prefix, const char *sourceFileName, QSqlDatabase db)
{
- return QLatin1String("dbtst")+QString::number(qHash(QLatin1String(sourceFileName) + "_" + qGetHostName().replace( "-", "_" )), 16)+"_"+prefix;
+ return fixupTableName(QString(QLatin1String("dbtst") + QString::number(qHash(QLatin1String(sourceFileName) +
+ "_" + qGetHostName().replace( "-", "_" )), 16) + "_" + prefix), db);
}
-inline static QString qTableName( const QString& prefix, QSqlDriver* driver )
+inline static QString qTableName(const QString& prefix, QSqlDatabase db)
{
- return driver->escapeIdentifier( prefix + "_" + qGetHostName(), QSqlDriver::TableName );
+ return fixupTableName(QString(db.driver()->escapeIdentifier(prefix + "_" + qGetHostName(), QSqlDriver::TableName)),
+ db);
}
inline static bool testWhiteSpaceNames( const QString &name )
@@ -467,6 +479,8 @@ public:
{
if (db.driverName().startsWith("QPSQL"))
return QLatin1String("timestamp");
+ if (db.driverName().startsWith("QOCI") && getOraVersion(db) >= 9)
+ return QLatin1String("timestamp(0)");
return QLatin1String("datetime");
}
@@ -510,11 +524,8 @@ public:
static bool isSqlServer( QSqlDatabase db )
{
- return db.databaseName().contains( "sql server", Qt::CaseInsensitive )
- || db.databaseName().contains( "sqlserver", Qt::CaseInsensitive )
- || db.databaseName().contains( "sql native client", Qt::CaseInsensitive )
- || db.databaseName().contains( "bq-winserv", Qt::CaseInsensitive )
- || db.hostName().contains( "bq-winserv", Qt::CaseInsensitive );
+ QSqlDriverPrivate *d = static_cast<QSqlDriverPrivate *>(QObjectPrivate::get(db.driver()));
+ return d->dbmsType == QSqlDriverPrivate::MSSqlServer;
}
static bool isMSAccess( QSqlDatabase db )
@@ -524,16 +535,19 @@ public:
static bool isPostgreSQL( QSqlDatabase db )
{
- return db.driverName().startsWith("QPSQL") || (db.driverName().startsWith("QODBC") && ( db.databaseName().contains("PostgreSQL", Qt::CaseInsensitive) || db.databaseName().contains("pgsql", Qt::CaseInsensitive) ) );
+ QSqlDriverPrivate *d = static_cast<QSqlDriverPrivate *>(QObjectPrivate::get(db.driver()));
+ return d->dbmsType == QSqlDriverPrivate::PostgreSQL;
}
static bool isMySQL( QSqlDatabase db )
{
- return db.driverName().startsWith("QMYSQL") || (db.driverName().startsWith("QODBC") && db.databaseName().contains("MySQL", Qt::CaseInsensitive) );
+ QSqlDriverPrivate *d = static_cast<QSqlDriverPrivate *>(QObjectPrivate::get(db.driver()));
+ return d->dbmsType == QSqlDriverPrivate::MySqlServer;
}
static bool isDB2( QSqlDatabase db )
{
- return db.driverName().startsWith("QDB2") || (db.driverName().startsWith("QODBC") && db.databaseName().contains("db2", Qt::CaseInsensitive) );
+ QSqlDriverPrivate *d = static_cast<QSqlDriverPrivate *>(QObjectPrivate::get(db.driver()));
+ return d->dbmsType == QSqlDriverPrivate::DB2;
}
// -1 on fail, else Oracle version
diff --git a/tests/auto/sql/kernel/qsqldatabase/tst_qsqldatabase.cpp b/tests/auto/sql/kernel/qsqldatabase/tst_qsqldatabase.cpp
index b294570df8..b958a30108 100644
--- a/tests/auto/sql/kernel/qsqldatabase/tst_qsqldatabase.cpp
+++ b/tests/auto/sql/kernel/qsqldatabase/tst_qsqldatabase.cpp
@@ -242,10 +242,10 @@ struct FieldDef {
// excluding the primary key field
static int createFieldTable(const FieldDef fieldDefs[], QSqlDatabase db)
{
- tst_Databases::safeDropTable(db, qTableName("qtestfields", __FILE__));
+ tst_Databases::safeDropTable(db, qTableName("qtestfields", __FILE__, db));
QSqlQuery q(db);
// construct a create table statement consisting of all fieldtypes
- QString qs = "create table " + qTableName("qtestfields", __FILE__);
+ QString qs = "create table " + qTableName("qtestfields", __FILE__, db);
QString autoName = tst_Databases::autoFieldName(db);
if (tst_Databases::isMSAccess(db))
qs.append(" (id int not null");
@@ -299,18 +299,18 @@ void tst_QSqlDatabase::createTestTables(QSqlDatabase db)
// please never ever change this table; otherwise fix all tests ;)
if (tst_Databases::isMSAccess(db)) {
- QVERIFY_SQL(q, exec("create table " + qTableName("qtest", __FILE__) +
+ QVERIFY_SQL(q, exec("create table " + qTableName("qtest", __FILE__, db) +
" (id int not null, t_varchar varchar(40) not null, t_char char(40), "
"t_numeric number, primary key (id, t_varchar))"));
} else {
- QVERIFY_SQL(q, exec("create table " + qTableName("qtest", __FILE__) +
+ QVERIFY_SQL(q, exec("create table " + qTableName("qtest", __FILE__, db) +
" (id integer not null, t_varchar varchar(40) not null, "
"t_char char(40), t_numeric numeric(6, 3), primary key (id, t_varchar))"));
}
if (testWhiteSpaceNames(db.driverName())) {
QString qry = "create table "
- + db.driver()->escapeIdentifier(qTableName("qtest", __FILE__) + " test", QSqlDriver::TableName)
+ + db.driver()->escapeIdentifier(qTableName("qtest", __FILE__, db) + " test", QSqlDriver::TableName)
+ '('
+ db.driver()->escapeIdentifier(QLatin1String("test test"), QSqlDriver::FieldName)
+ " int not null primary key)";
@@ -329,45 +329,45 @@ void tst_QSqlDatabase::dropTestTables(QSqlDatabase db)
}
// drop the view first, otherwise we'll get dependency problems
- tst_Databases::safeDropViews(db, QStringList() << qTableName("qtest_view", __FILE__) << qTableName("qtest_view2", __FILE__));
+ tst_Databases::safeDropViews(db, QStringList() << qTableName("qtest_view", __FILE__, db) << qTableName("qtest_view2", __FILE__, db));
QStringList tableNames;
- tableNames << qTableName("qtest", __FILE__)
- << qTableName("qtestfields", __FILE__)
- << qTableName("qtestalter", __FILE__)
- << qTableName("qtest_temp", __FILE__)
- << qTableName("qtest_bigint", __FILE__)
- << qTableName("qtest_xmltype", __FILE__)
- << qTableName("latin1table", __FILE__)
- << qTableName("qtest_sqlguid", __FILE__)
- << qTableName("batable", __FILE__)
- << qTableName("qtest_prec", __FILE__)
- << qTableName("uint", __FILE__)
- << qTableName("strings", __FILE__)
- << qTableName("numericfields", __FILE__)
- << qTableName("qtest_ibaseblobs", __FILE__)
- << qTableName("qtestBindBool", __FILE__)
- << qTableName("testqGetString", __FILE__)
- << qTableName("qtest_sqlguid", __FILE__)
- << qTableName("uint_table", __FILE__)
- << qTableName("uint_test", __FILE__)
- << qTableName("bug_249059", __FILE__);
+ tableNames << qTableName("qtest", __FILE__, db)
+ << qTableName("qtestfields", __FILE__, db)
+ << qTableName("qtestalter", __FILE__, db)
+ << qTableName("qtest_temp", __FILE__, db)
+ << qTableName("qtest_bigint", __FILE__, db)
+ << qTableName("qtest_xmltype", __FILE__, db)
+ << qTableName("latin1table", __FILE__, db)
+ << qTableName("qtest_sqlguid", __FILE__, db)
+ << qTableName("batable", __FILE__, db)
+ << qTableName("qtest_prec", __FILE__, db)
+ << qTableName("uint", __FILE__, db)
+ << qTableName("strings", __FILE__, db)
+ << qTableName("numericfields", __FILE__, db)
+ << qTableName("qtest_ibaseblobs", __FILE__, db)
+ << qTableName("qtestBindBool", __FILE__, db)
+ << qTableName("testqGetString", __FILE__, db)
+ << qTableName("qtest_sqlguid", __FILE__, db)
+ << qTableName("uint_table", __FILE__, db)
+ << qTableName("uint_test", __FILE__, db)
+ << qTableName("bug_249059", __FILE__, db);
QSqlQuery q(0, db);
if (db.driverName().startsWith("QPSQL")) {
- q.exec("drop schema " + qTableName("qtestschema", __FILE__) + " cascade");
- q.exec("drop schema " + qTableName("qtestScHeMa", __FILE__) + " cascade");
+ q.exec("drop schema " + qTableName("qtestschema", __FILE__, db) + " cascade");
+ q.exec("drop schema " + qTableName("qtestScHeMa", __FILE__, db) + " cascade");
}
if (testWhiteSpaceNames(db.driverName()))
- tableNames << db.driver()->escapeIdentifier(qTableName("qtest", __FILE__) + " test", QSqlDriver::TableName);
+ tableNames << db.driver()->escapeIdentifier(qTableName("qtest", __FILE__, db) + " test", QSqlDriver::TableName);
tst_Databases::safeDropTables(db, tableNames);
if (db.driverName().startsWith("QOCI")) {
- q.exec("drop user "+qTableName("CREATOR", __FILE__)+" cascade");
- q.exec("drop user "+qTableName("APPUSER", __FILE__)+" cascade");
- q.exec("DROP TABLE system."+qTableName("mypassword", __FILE__));
+ q.exec("drop user "+qTableName("CREATOR", __FILE__, db)+ " cascade");
+ q.exec("drop user "+qTableName("APPUSER", __FILE__, db) + " cascade");
+ q.exec("DROP TABLE sys."+qTableName("mypassword", __FILE__, db));
}
}
@@ -377,7 +377,7 @@ void tst_QSqlDatabase::populateTestTables(QSqlDatabase db)
if (!db.isValid())
return;
QSqlQuery q(db);
- const QString qtest(qTableName("qtest", __FILE__));
+ const QString qtest(qTableName("qtest", __FILE__, db));
q.exec("delete from " + qtest); //non-fatal
QVERIFY_SQL(q, exec("insert into " + qtest + " (id, t_varchar, t_char, t_numeric) values (0, 'VarChar0', 'Char0', 1.1)"));
@@ -502,7 +502,7 @@ void tst_QSqlDatabase::tables()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString qtest(qTableName("qtest", __FILE__)), qtest_view(qTableName("qtest_view", __FILE__)), temp_tab(qTableName("test_tab", __FILE__));
+ const QString qtest(qTableName("qtest", __FILE__, db)), qtest_view(qTableName("qtest_view", __FILE__, db)), temp_tab(qTableName("test_tab", __FILE__, db));
bool views = true;
bool tempTables = false;
@@ -567,7 +567,7 @@ void tst_QSqlDatabase::whitespaceInIdentifiers()
CHECK_DATABASE(db);
if (testWhiteSpaceNames(db.driverName())) {
- const QString tableName(qTableName("qtest", __FILE__) + " test");
+ const QString tableName(qTableName("qtest", __FILE__, db) + " test");
QVERIFY(db.tables().contains(tableName, Qt::CaseInsensitive));
QSqlRecord rec = db.record(db.driver()->escapeIdentifier(tableName, QSqlDriver::TableName));
@@ -595,7 +595,7 @@ void tst_QSqlDatabase::alterTable()
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString qtestalter(qTableName("qtestalter", __FILE__));
+ const QString qtestalter(qTableName("qtestalter", __FILE__, db));
QSqlQuery q(db);
@@ -671,12 +671,12 @@ void tst_QSqlDatabase::commonFieldTest(const FieldDef fieldDefs[], QSqlDatabase
{
CHECK_DATABASE(db);
- QSqlRecord rec = db.record(qTableName("qtestfields", __FILE__));
+ QSqlRecord rec = db.record(qTableName("qtestfields", __FILE__, db));
QCOMPARE((int)rec.count(), fieldCount+1);
testRecord(fieldDefs, rec, db);
QSqlQuery q(db);
- QVERIFY_SQL(q, exec("select * from " + qTableName("qtestfields", __FILE__)));
+ QVERIFY_SQL(q, exec("select * from " + qTableName("qtestfields", __FILE__, db)));
}
void tst_QSqlDatabase::recordTDS()
@@ -772,12 +772,12 @@ void tst_QSqlDatabase::recordOCI()
commonFieldTest(fieldDefs, db, fieldCount);
// some additional tests
- QSqlRecord rec = db.record(qTableName("qtestfields", __FILE__));
+ QSqlRecord rec = db.record(qTableName("qtestfields", __FILE__, db));
QCOMPARE(rec.field("T_NUMBER").length(), 10);
QCOMPARE(rec.field("T_NUMBER").precision(), 5);
QSqlQuery q(db);
- QVERIFY_SQL(q, exec("SELECT * FROM " + qTableName("qtestfields", __FILE__)));
+ QVERIFY_SQL(q, exec("SELECT * FROM " + qTableName("qtestfields", __FILE__, db)));
rec = q.record();
QCOMPARE(rec.field("T_NUMBER").length(), 10);
QCOMPARE(rec.field("T_NUMBER").precision(), 5);
@@ -834,11 +834,11 @@ void tst_QSqlDatabase::recordPSQL()
if(tst_Databases::isPostgreSQL(db))
QVERIFY_SQL( q, exec("set client_min_messages='warning'"));
- q.exec("drop sequence " + qTableName("qtestfields", __FILE__) + "_t_bigserial_seq");
- q.exec("drop sequence " + qTableName("qtestfields", __FILE__) + "_t_serial_seq");
+ q.exec("drop sequence " + qTableName("qtestfields", __FILE__, db) + "_t_bigserial_seq");
+ q.exec("drop sequence " + qTableName("qtestfields", __FILE__, db) + "_t_serial_seq");
// older psql cut off the table name
- q.exec("drop sequence " + qTableName("qtestfields", __FILE__).left(15) + "_t_bigserial_seq");
- q.exec("drop sequence " + qTableName("qtestfields", __FILE__).left(18) + "_t_serial_seq");
+ q.exec("drop sequence " + qTableName("qtestfields", __FILE__, db).left(15) + "_t_bigserial_seq");
+ q.exec("drop sequence " + qTableName("qtestfields", __FILE__, db).left(18) + "_t_serial_seq");
const int fieldCount = createFieldTable(fieldDefs, db);
QVERIFY(fieldCount > 0);
@@ -1075,7 +1075,7 @@ void tst_QSqlDatabase::transaction()
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString qtest(qTableName("qtest", __FILE__));
+ const QString qtest(qTableName("qtest", __FILE__, db));
if (!db.driver()->hasFeature(QSqlDriver::Transactions))
QSKIP("DBMS not transaction capable");
@@ -1125,7 +1125,7 @@ void tst_QSqlDatabase::bigIntField()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
QString drvName = db.driverName();
- const QString qtest_bigint(qTableName("qtest_bigint", __FILE__));
+ const QString qtest_bigint(qTableName("qtest_bigint", __FILE__, db));
QSqlQuery q(db);
q.setForwardOnly(true);
@@ -1196,21 +1196,21 @@ void tst_QSqlDatabase::caseSensivity()
|| db.driverName().startsWith("QODBC"))
cs = true;
- QSqlRecord rec = db.record(qTableName("qtest", __FILE__));
+ QSqlRecord rec = db.record(qTableName("qtest", __FILE__, db));
QVERIFY((int)rec.count() > 0);
if (!cs) {
- rec = db.record(qTableName("QTEST", __FILE__).toUpper());
+ rec = db.record(qTableName("QTEST", __FILE__, db).toUpper());
QVERIFY((int)rec.count() > 0);
- rec = db.record(qTableName("qTesT", __FILE__));
+ rec = db.record(qTableName("qTesT", __FILE__, db));
QVERIFY((int)rec.count() > 0);
}
- rec = db.primaryIndex(qTableName("qtest", __FILE__));
+ rec = db.primaryIndex(qTableName("qtest", __FILE__, db));
QVERIFY((int)rec.count() > 0);
if (!cs) {
- rec = db.primaryIndex(qTableName("QTEST", __FILE__).toUpper());
+ rec = db.primaryIndex(qTableName("QTEST", __FILE__, db).toUpper());
QVERIFY((int)rec.count() > 0);
- rec = db.primaryIndex(qTableName("qTesT", __FILE__));
+ rec = db.primaryIndex(qTableName("qTesT", __FILE__, db));
QVERIFY((int)rec.count() > 0);
}
}
@@ -1226,7 +1226,7 @@ void tst_QSqlDatabase::noEscapedFieldNamesInRecord()
fieldname = fieldname.toUpper();
QSqlQuery q(db);
- QString query = "SELECT " + db.driver()->escapeIdentifier(fieldname, QSqlDriver::FieldName) + " FROM " + qTableName("qtest", __FILE__);
+ QString query = "SELECT " + db.driver()->escapeIdentifier(fieldname, QSqlDriver::FieldName) + " FROM " + qTableName("qtest", __FILE__, db);
QVERIFY_SQL(q, exec(query));
QCOMPARE(q.record().fieldName(0), fieldname);
}
@@ -1246,9 +1246,9 @@ void tst_QSqlDatabase::psql_schemas()
QVERIFY_SQL( q, exec("set client_min_messages='warning'"));
}
- QVERIFY_SQL(q, exec("CREATE SCHEMA " + qTableName("qtestschema", __FILE__)));
+ QVERIFY_SQL(q, exec("CREATE SCHEMA " + qTableName("qtestschema", __FILE__, db)));
- QString table = qTableName("qtestschema", __FILE__) + '.' + qTableName("qtesttable", __FILE__);
+ QString table = qTableName("qtestschema", __FILE__, db) + '.' + qTableName("qtesttable", __FILE__, db);
QVERIFY_SQL(q, exec("CREATE TABLE " + table + " (id int primary key, name varchar(20))"));
QVERIFY(db.tables().contains(table));
@@ -1278,8 +1278,8 @@ void tst_QSqlDatabase::psql_escapedIdentifiers()
if(tst_Databases::isPostgreSQL(db))
QVERIFY_SQL( q, exec("set client_min_messages='warning'"));
- const QString schemaName(qTableName("qtestScHeMa", __FILE__)),
- tableName(qTableName("qtest", __FILE__)),
+ const QString schemaName(qTableName("qtestScHeMa", __FILE__, db)),
+ tableName(qTableName("qtest", __FILE__, db)),
field1Name(QLatin1String("fIeLdNaMe")),
field2Name(QLatin1String("ZuLu"));
@@ -1318,7 +1318,7 @@ void tst_QSqlDatabase::psql_escapeBytea()
QByteArray ba(dta, 4);
QSqlQuery q(db);
- const QString tableName(qTableName("batable", __FILE__));
+ const QString tableName(qTableName("batable", __FILE__, db));
QVERIFY_SQL(q, exec(QString("CREATE TABLE %1 (ba bytea)").arg(tableName)));
QSqlQuery iq(db);
@@ -1351,7 +1351,7 @@ void tst_QSqlDatabase::bug_249059()
QSKIP("Test requires PostgreSQL >= 7.3");
QSqlQuery q(db);
- const QString tableName(qTableName("bug_249059", __FILE__));
+ const QString tableName(qTableName("bug_249059", __FILE__, db));
QVERIFY_SQL(q, exec(QString("CREATE TABLE %1 (dt timestamp, t time)").arg(tableName)));
QSqlQuery iq(db);
@@ -1386,7 +1386,7 @@ void tst_QSqlDatabase::precisionPolicy()
// DBMS_SPECIFIC(db, "QPSQL");
QSqlQuery q(db);
- const QString tableName(qTableName("qtest_prec", __FILE__));
+ const QString tableName(qTableName("qtest_prec", __FILE__, db));
if(!db.driver()->hasFeature(QSqlDriver::LowPrecisionNumbers))
QSKIP("Driver or database doesn't support setting precision policy");
@@ -1422,8 +1422,6 @@ void tst_QSqlDatabase::precisionPolicy()
q.setNumericalPrecisionPolicy(QSql::LowPrecisionInt32);
QVERIFY_SQL(q, exec(query));
- if(db.driverName().startsWith("QOCI"))
- QEXPECT_FAIL("", "Oracle fails to move to next when data columns are oversize", Abort);
QVERIFY_SQL(q, next());
if(db.driverName().startsWith("QSQLITE"))
QEXPECT_FAIL("", "SQLite returns this value as determined by contents of the field, not the declaration", Continue);
@@ -1481,7 +1479,7 @@ void tst_QSqlDatabase::mysqlOdbc_unsignedIntegers()
QSKIP("MySQL through ODBC-driver specific test");
QSqlQuery q(db);
- const QString tableName(qTableName("uint", __FILE__));
+ const QString tableName(qTableName("uint", __FILE__, db));
QVERIFY_SQL(q, exec(QString("CREATE TABLE %1 (foo integer(10) unsigned, bar integer(10))").arg(tableName)));
QVERIFY_SQL(q, exec(QString("INSERT INTO %1 VALUES (-4000000000, -4000000000)").arg(tableName)));
QVERIFY_SQL(q, exec(QString("INSERT INTO %1 VALUES (4000000000, 4000000000)").arg(tableName)));
@@ -1505,7 +1503,7 @@ void tst_QSqlDatabase::accessOdbc_strings()
QSKIP("MS Access specific test");
QSqlQuery q(db);
- const QString tableName(qTableName("strings", __FILE__));
+ const QString tableName(qTableName("strings", __FILE__, db));
QVERIFY_SQL(q, exec(QString("CREATE TABLE %1 (aStr memo, bStr memo, cStr memo, dStr memo"
", eStr memo, fStr memo, gStr memo, hStr memo)").arg(tableName)));
@@ -1543,7 +1541,7 @@ void tst_QSqlDatabase::ibase_numericFields()
CHECK_DATABASE(db);
QSqlQuery q(db);
- const QString tableName(qTableName("numericfields", __FILE__));
+ const QString tableName(qTableName("numericfields", __FILE__, db));
QVERIFY_SQL(q, exec(QString("CREATE TABLE %1 (id int not null, num1 NUMERIC(2,1), "
"num2 NUMERIC(5,2), num3 NUMERIC(10,3), "
"num4 NUMERIC(18,4))").arg(tableName)));
@@ -1615,7 +1613,7 @@ void tst_QSqlDatabase::ibase_fetchBlobs()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString tableName(qTableName("qtest_ibaseblobs", __FILE__));
+ const QString tableName(qTableName("qtest_ibaseblobs", __FILE__, db));
QSqlQuery q(db);
QVERIFY_SQL(q, exec(QString("CREATE TABLE %1 (blob1 BLOB segment size 256)").arg(tableName)));
@@ -1648,7 +1646,7 @@ void tst_QSqlDatabase::ibase_procWithoutReturnValues()
CHECK_DATABASE(db);
QSqlQuery q(db);
- const QString procName(qTableName("qtest_proc1", __FILE__));
+ const QString procName(qTableName("qtest_proc1", __FILE__, db));
q.exec(QString("drop procedure %1").arg(procName));
QVERIFY_SQL(q, exec("CREATE PROCEDURE " + procName + " (str VARCHAR(10))\nAS BEGIN\nstr='test';\nEND;"));
QVERIFY_SQL(q, exec(QString("execute procedure %1('qtest')").arg(procName)));
@@ -1664,7 +1662,7 @@ void tst_QSqlDatabase::ibase_procWithReturnValues()
if (!db.driverName().startsWith("QIBASE"))
QSKIP("InterBase specific test");
- const QString procName(qTableName("qtest_proc2", __FILE__));
+ const QString procName(qTableName("qtest_proc2", __FILE__, db));
QSqlQuery q(db);
q.exec(QString("drop procedure %1").arg(procName));
@@ -1706,11 +1704,11 @@ void tst_QSqlDatabase::formatValueTrimStrings()
QSqlQuery q(db);
- QVERIFY_SQL(q, exec(QString("INSERT INTO %1 (id, t_varchar, t_char) values (50, 'Trim Test ', 'Trim Test 2 ')").arg(qTableName("qtest", __FILE__))));
- QVERIFY_SQL(q, exec(QString("INSERT INTO %1 (id, t_varchar, t_char) values (51, 'TrimTest', 'Trim Test 2')").arg(qTableName("qtest", __FILE__))));
- QVERIFY_SQL(q, exec(QString("INSERT INTO %1 (id, t_varchar, t_char) values (52, ' ', ' ')").arg(qTableName("qtest", __FILE__))));
+ QVERIFY_SQL(q, exec(QString("INSERT INTO %1 (id, t_varchar, t_char) values (50, 'Trim Test ', 'Trim Test 2 ')").arg(qTableName("qtest", __FILE__, db))));
+ QVERIFY_SQL(q, exec(QString("INSERT INTO %1 (id, t_varchar, t_char) values (51, 'TrimTest', 'Trim Test 2')").arg(qTableName("qtest", __FILE__, db))));
+ QVERIFY_SQL(q, exec(QString("INSERT INTO %1 (id, t_varchar, t_char) values (52, ' ', ' ')").arg(qTableName("qtest", __FILE__, db))));
- QVERIFY_SQL(q, exec(QString("SELECT t_varchar, t_char FROM %1 WHERE id >= 50 AND id <= 52 ORDER BY id").arg(qTableName("qtest", __FILE__))));
+ QVERIFY_SQL(q, exec(QString("SELECT t_varchar, t_char FROM %1 WHERE id >= 50 AND id <= 52 ORDER BY id").arg(qTableName("qtest", __FILE__, db))));
QVERIFY_SQL(q, next());
@@ -1734,10 +1732,10 @@ void tst_QSqlDatabase::odbc_reopenDatabase()
CHECK_DATABASE(db);
QSqlQuery q(db);
- QVERIFY_SQL(q, exec("SELECT * from " + qTableName("qtest", __FILE__)));
+ QVERIFY_SQL(q, exec("SELECT * from " + qTableName("qtest", __FILE__, db)));
QVERIFY_SQL(q, next());
db.open();
- QVERIFY_SQL(q, exec("SELECT * from " + qTableName("qtest", __FILE__)));
+ QVERIFY_SQL(q, exec("SELECT * from " + qTableName("qtest", __FILE__, db)));
QVERIFY_SQL(q, next());
db.open();
}
@@ -1752,10 +1750,10 @@ void tst_QSqlDatabase::odbc_bindBoolean()
QSKIP("MySql has inconsistent behaviour of bit field type across versions.");
QSqlQuery q(db);
- QVERIFY_SQL(q, exec("CREATE TABLE " + qTableName("qtestBindBool", __FILE__) + "(id int, boolvalue bit)"));
+ QVERIFY_SQL(q, exec("CREATE TABLE " + qTableName("qtestBindBool", __FILE__, db) + "(id int, boolvalue bit)"));
// Bind and insert
- QVERIFY_SQL(q, prepare("INSERT INTO " + qTableName("qtestBindBool", __FILE__) + " VALUES(?, ?)"));
+ QVERIFY_SQL(q, prepare("INSERT INTO " + qTableName("qtestBindBool", __FILE__, db) + " VALUES(?, ?)"));
q.bindValue(0, 1);
q.bindValue(1, true);
QVERIFY_SQL(q, exec());
@@ -1764,7 +1762,7 @@ void tst_QSqlDatabase::odbc_bindBoolean()
QVERIFY_SQL(q, exec());
// Retrive
- QVERIFY_SQL(q, exec("SELECT id, boolvalue FROM " + qTableName("qtestBindBool", __FILE__) + " ORDER BY id"));
+ QVERIFY_SQL(q, exec("SELECT id, boolvalue FROM " + qTableName("qtestBindBool", __FILE__, db) + " ORDER BY id"));
QVERIFY_SQL(q, next());
QCOMPARE(q.value(0).toInt(), 1);
QCOMPARE(q.value(1).toBool(), true);
@@ -1778,7 +1776,7 @@ void tst_QSqlDatabase::odbc_testqGetString()
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString testqGetString(qTableName("testqGetString", __FILE__));
+ const QString testqGetString(qTableName("testqGetString", __FILE__, db));
QSqlQuery q(db);
if (tst_Databases::isSqlServer(db))
@@ -1822,7 +1820,7 @@ void tst_QSqlDatabase::mysql_multiselect()
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString qtest(qTableName("qtest", __FILE__));
+ const QString qtest(qTableName("qtest", __FILE__, db));
QSqlQuery q(db);
QString version=tst_Databases::getMySqlVersion( db );
@@ -1848,7 +1846,7 @@ void tst_QSqlDatabase::ibase_useCustomCharset()
db.setConnectOptions("ISC_DPB_LC_CTYPE=Latin1");
db.open();
- const QString tableName(qTableName("latin1table", __FILE__));
+ const QString tableName(qTableName("latin1table", __FILE__, db));
QSqlQuery q(db);
QVERIFY_SQL(q, exec(QString("CREATE TABLE %1(text VARCHAR(6) CHARACTER SET Latin1)").arg(tableName)));
@@ -1886,8 +1884,8 @@ void tst_QSqlDatabase::oci_xmltypeSupport()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString tableName(qTableName("qtest_xmltype", __FILE__));
- QString xml("<?xml version=\"1.0\"?><TABLE_NAME>MY_TABLE</TABLE_NAME>");
+ const QString tableName(qTableName("qtest_xmltype", __FILE__, db));
+ QString xml("<?xml version=\"1.0\"?>\n<TABLE_NAME>MY_TABLE</TABLE_NAME>\n");
QSqlQuery q(db);
// Embedding the XML in the statement
@@ -1914,7 +1912,7 @@ void tst_QSqlDatabase::oci_fieldLength()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString tableName(qTableName("qtest", __FILE__));
+ const QString tableName(qTableName("qtest", __FILE__, db));
QSqlQuery q(db);
QVERIFY_SQL(q, exec(QString("SELECT t_varchar, t_char FROM %1").arg(tableName)));
@@ -1930,7 +1928,7 @@ void tst_QSqlDatabase::oci_synonymstest()
CHECK_DATABASE(db);
QSqlQuery q(db);
- const QString creator(qTableName("CREATOR", __FILE__)), appuser(qTableName("APPUSER", __FILE__)), table1(qTableName("TABLE1", __FILE__));
+ const QString creator(qTableName("CREATOR", __FILE__, db)), appuser(qTableName("APPUSER", __FILE__, db)), table1(qTableName("TABLE1", __FILE__, db));
// QVERIFY_SQL(q, exec("drop public synonym "+table1));
QVERIFY_SQL(q, exec(QString("create user %1 identified by %2 default tablespace users temporary tablespace temp").arg(creator).arg(creator)));
QVERIFY_SQL(q, exec(QString("grant CONNECT to %1").arg(creator)));
@@ -1948,8 +1946,8 @@ void tst_QSqlDatabase::oci_synonymstest()
db3.close();
QVERIFY_SQL(db3, open(appuser,appuser));
QSqlQuery q3(db3);
- QVERIFY_SQL(q3, exec("create synonym "+appuser+'.'+qTableName("synonyms", __FILE__)+" for "+creator+'.'+table1));
- QVERIFY_SQL(db3, tables().filter(qTableName("synonyms", __FILE__), Qt::CaseInsensitive).count() >= 1);
+ QVERIFY_SQL(q3, exec("create synonym " + appuser + '.' + qTableName("synonyms", __FILE__, db) + " for " + creator + '.' + table1));
+ QVERIFY_SQL(db3, tables().filter(qTableName("synonyms", __FILE__, db), Qt::CaseInsensitive).count() >= 1);
}
@@ -1963,7 +1961,7 @@ void tst_QSqlDatabase::odbc_uniqueidentifier()
if (!tst_Databases::isSqlServer(db))
QSKIP("SQL Server (ODBC) specific test");
- const QString tableName(qTableName("qtest_sqlguid", __FILE__));
+ const QString tableName(qTableName("qtest_sqlguid", __FILE__, db));
QString guid = QString("AAAAAAAA-BBBB-CCCC-DDDD-EEEEEEEEEEEE");
QString invalidGuid = QString("GAAAAAAA-BBBB-CCCC-DDDD-EEEEEEEEEEEE");
@@ -2006,7 +2004,7 @@ void tst_QSqlDatabase::odbc_uintfield()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString tableName(qTableName("uint_table", __FILE__));
+ const QString tableName(qTableName("uint_table", __FILE__, db));
unsigned int val = 4294967295U;
QSqlQuery q(db);
@@ -2070,7 +2068,7 @@ void tst_QSqlDatabase::eventNotificationIBase()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString procedureName(qTableName("posteventProc", __FILE__));
+ const QString procedureName(qTableName("posteventProc", __FILE__, db));
QSqlDriver *driver=db.driver();
QVERIFY_SQL(*driver, subscribeToNotification(procedureName));
QTest::qWait(300); // Interbase needs some time to call the driver callback.
@@ -2100,7 +2098,7 @@ void tst_QSqlDatabase::eventNotificationPSQL()
CHECK_DATABASE(db);
QSqlQuery query(db);
- QString procedureName = qTableName("posteventProc", __FILE__);
+ QString procedureName = qTableName("posteventProc", __FILE__, db);
QString payload = "payload";
QSqlDriver &driver=*(db.driver());
QVERIFY_SQL(driver, subscribeToNotification(procedureName));
@@ -2124,7 +2122,7 @@ void tst_QSqlDatabase::sqlite_bindAndFetchUInt()
QSKIP("SQLite3 specific test");
QSqlQuery q(db);
- const QString tableName(qTableName("uint_test", __FILE__));
+ const QString tableName(qTableName("uint_test", __FILE__, db));
QVERIFY_SQL(q, exec(QString("CREATE TABLE %1(uint_field UNSIGNED INTEGER)").arg(tableName)));
QVERIFY_SQL(q, prepare(QString("INSERT INTO %1 VALUES(?)").arg(tableName)));
q.addBindValue(4000000000U);
@@ -2144,7 +2142,7 @@ void tst_QSqlDatabase::db2_valueCacheUpdate()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString tableName(qTableName("qtest", __FILE__));
+ const QString tableName(qTableName("qtest", __FILE__, db));
QSqlQuery q(db);
q.exec(QString("SELECT id, t_varchar, t_char, t_numeric FROM %1").arg(tableName));
q.next();
@@ -2167,7 +2165,7 @@ void tst_QSqlDatabase::sqlStatementUseIsNull_189093()
// select a record with NULL value
QSqlQuery q(QString::null, db);
- QVERIFY_SQL(q, exec("select * from " + qTableName("qtest", __FILE__) + " where id = 4"));
+ QVERIFY_SQL(q, exec("select * from " + qTableName("qtest", __FILE__, db) + " where id = 4"));
QVERIFY_SQL(q, next());
QSqlDriver *driver = db.driver();
@@ -2190,17 +2188,18 @@ void tst_QSqlDatabase::mysql_savepointtest()
QSqlQuery q(db);
QVERIFY_SQL(q, exec("begin"));
- QVERIFY_SQL(q, exec("insert into "+qTableName("qtest", __FILE__)+" VALUES (54, 'foo', 'foo', 54.54)"));
+ QVERIFY_SQL(q, exec("insert into " + qTableName("qtest", __FILE__, db) + " VALUES (54, 'foo', 'foo', 54.54)"));
QVERIFY_SQL(q, exec("savepoint foo"));
}
void tst_QSqlDatabase::oci_tables()
{
+ QSKIP("Requires specific permissions to create a system table");
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
QSqlQuery q(db);
- const QString systemTableName("system."+qTableName("mypassword", __FILE__));
+ const QString systemTableName("sys." + qTableName("mypassword", __FILE__, db).toUpper());
QVERIFY_SQL(q, exec("CREATE TABLE "+systemTableName+"(name VARCHAR(20))"));
QVERIFY(!db.tables().contains(systemTableName.toUpper()));
QVERIFY(db.tables(QSql::SystemTables).contains(systemTableName.toUpper()));
@@ -2220,8 +2219,8 @@ void tst_QSqlDatabase::sqlite_enable_cache_mode()
db2.setConnectOptions("QSQLITE_ENABLE_SHARED_CACHE");
QVERIFY_SQL(db2, open());
QSqlQuery q(db), q2(db2);
- QVERIFY_SQL(q, exec("select * from "+qTableName("qtest", __FILE__)));
- QVERIFY_SQL(q2, exec("select * from "+qTableName("qtest", __FILE__)));
+ QVERIFY_SQL(q, exec("select * from " + qTableName("qtest", __FILE__, db)));
+ QVERIFY_SQL(q2, exec("select * from " + qTableName("qtest", __FILE__, db)));
}
QTEST_MAIN(tst_QSqlDatabase)
diff --git a/tests/auto/sql/kernel/qsqldriver/qsqldriver.pro b/tests/auto/sql/kernel/qsqldriver/qsqldriver.pro
index de50f43b76..abdc157c7f 100644
--- a/tests/auto/sql/kernel/qsqldriver/qsqldriver.pro
+++ b/tests/auto/sql/kernel/qsqldriver/qsqldriver.pro
@@ -3,7 +3,7 @@ CONFIG += parallel_test
TARGET = tst_qsqldriver
SOURCES += tst_qsqldriver.cpp
-QT = core sql testlib
+QT = core sql testlib core-private sql-private
wince*: {
plugFiles.files = ../../../plugins/sqldrivers
@@ -17,4 +17,3 @@ wince*: {
LIBS += ws2_32.lib
}
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/sql/kernel/qsqldriver/tst_qsqldriver.cpp b/tests/auto/sql/kernel/qsqldriver/tst_qsqldriver.cpp
index 852cb8f41e..3500e26f5e 100644
--- a/tests/auto/sql/kernel/qsqldriver/tst_qsqldriver.cpp
+++ b/tests/auto/sql/kernel/qsqldriver/tst_qsqldriver.cpp
@@ -77,7 +77,7 @@ void tst_QSqlDriver::initTestCase_data()
void tst_QSqlDriver::recreateTestTables(QSqlDatabase db)
{
QSqlQuery q(db);
- const QString relTEST1(qTableName("relTEST1", __FILE__));
+ const QString relTEST1(qTableName("relTEST1", __FILE__, db));
if(tst_Databases::isPostgreSQL(db))
QVERIFY_SQL( q, exec("set client_min_messages='warning'"));
@@ -102,7 +102,7 @@ void tst_QSqlDriver::cleanupTestCase()
{
foreach (const QString &dbName, dbs.dbNames) {
QSqlDatabase db = QSqlDatabase::database(dbName);
- tst_Databases::safeDropTable( db, qTableName( "relTEST1", __FILE__ ) );
+ tst_Databases::safeDropTable(db, qTableName("relTEST1", __FILE__, db));
}
dbs.close();
}
@@ -121,7 +121,7 @@ void tst_QSqlDriver::record()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- QString tablename(qTableName("relTEST1", __FILE__));
+ QString tablename(qTableName("relTEST1", __FILE__, db));
QStringList fields;
fields << "id" << "name" << "title_key" << "another_title_key";
@@ -178,7 +178,7 @@ void tst_QSqlDriver::primaryIndex()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- QString tablename(qTableName("relTEST1", __FILE__));
+ QString tablename(qTableName("relTEST1", __FILE__, db));
//check that we can get primary index using unquoted mixed case table name
QSqlIndex index = db.driver()->primaryIndex(tablename);
QCOMPARE(index.count(), 1);
diff --git a/tests/auto/sql/kernel/qsqlerror/qsqlerror.pro b/tests/auto/sql/kernel/qsqlerror/qsqlerror.pro
index 3076e1aa8b..c217e27645 100644
--- a/tests/auto/sql/kernel/qsqlerror/qsqlerror.pro
+++ b/tests/auto/sql/kernel/qsqlerror/qsqlerror.pro
@@ -8,4 +8,3 @@ TARGET = tst_qsqlerror
QT = core sql testlib
SOURCES += tst_qsqlerror.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/sql/kernel/qsqlfield/qsqlfield.pro b/tests/auto/sql/kernel/qsqlfield/qsqlfield.pro
index 16ad209031..6b74041a17 100644
--- a/tests/auto/sql/kernel/qsqlfield/qsqlfield.pro
+++ b/tests/auto/sql/kernel/qsqlfield/qsqlfield.pro
@@ -4,4 +4,3 @@ TARGET = tst_qsqlfield
SOURCES += tst_qsqlfield.cpp
QT = core sql testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/sql/kernel/qsqlquery/qsqlquery.pro b/tests/auto/sql/kernel/qsqlquery/qsqlquery.pro
index 40c21cf51b..360d874f1a 100644
--- a/tests/auto/sql/kernel/qsqlquery/qsqlquery.pro
+++ b/tests/auto/sql/kernel/qsqlquery/qsqlquery.pro
@@ -3,7 +3,7 @@ CONFIG += testcase
SOURCES += tst_qsqlquery.cpp
-QT = core sql testlib
+QT = core sql testlib core-private sql-private
!wince*:win32:LIBS += -lws2_32
@@ -13,4 +13,3 @@ wince*: {
DEPLOYMENT += plugFiles
LIBS += -lws2
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/sql/kernel/qsqlquery/tst_qsqlquery.cpp b/tests/auto/sql/kernel/qsqlquery/tst_qsqlquery.cpp
index 1d2a60506f..ff458d6f2b 100644
--- a/tests/auto/sql/kernel/qsqlquery/tst_qsqlquery.cpp
+++ b/tests/auto/sql/kernel/qsqlquery/tst_qsqlquery.cpp
@@ -44,7 +44,7 @@
#include "../qsqldatabase/tst_databases.h"
-const QString qtest(qTableName( "qtest", __FILE__ ));
+const QString qtest(qTableName("qtest", __FILE__, QSqlDatabase()));
class tst_QSqlQuery : public QObject
{
@@ -221,6 +221,9 @@ private slots:
void QTBUG_16967(); //clean close
void QTBUG_23895_data() { generic_data("QSQLITE"); }
void QTBUG_23895(); //sqlite boolean type
+ void QTBUG_14904_data() { generic_data("QSQLITE"); }
+ void QTBUG_14904();
+
void QTBUG_2192_data() { generic_data(); }
void QTBUG_2192();
@@ -315,59 +318,59 @@ void tst_QSqlQuery::dropTestTables( QSqlDatabase db )
QStringList tablenames;
// drop all the table in case a testcase failed
tablenames << qtest
- << qTableName( "qtest_null", __FILE__ )
- << qTableName( "qtest_blob", __FILE__ )
- << qTableName( "qtest_bittest", __FILE__ )
- << qTableName( "qtest_nullblob", __FILE__ )
- << qTableName( "qtest_rawtest", __FILE__ )
- << qTableName( "qtest_precision", __FILE__ )
- << qTableName( "qtest_prepare", __FILE__ )
- << qTableName( "qtestj1", __FILE__ )
- << qTableName( "qtestj2", __FILE__ )
- << qTableName( "char1Select", __FILE__ )
- << qTableName( "char1SU", __FILE__ )
- << qTableName( "qxmltest", __FILE__ )
- << qTableName( "qtest_exerr", __FILE__ )
- << qTableName( "qtest_empty", __FILE__ )
- << qTableName( "clobby", __FILE__ )
- << qTableName( "bindtest", __FILE__ )
- << qTableName( "more_results", __FILE__ )
- << qTableName( "blobstest", __FILE__ )
- << qTableName( "oraRowId", __FILE__ )
- << qTableName( "qtest_batch", __FILE__ )
- << qTableName("bug6421", __FILE__).toUpper()
- << qTableName("bug5765", __FILE__)
- << qTableName("bug6852", __FILE__)
- << qTableName("bug21884", __FILE__)
- << qTableName("bug23895", __FILE__)
- << qTableName( "qtest_lockedtable", __FILE__ )
- << qTableName( "Planet", __FILE__ )
- << qTableName( "task_250026", __FILE__ )
- << qTableName( "task_234422", __FILE__ )
- << qTableName("test141895", __FILE__)
- << qTableName("qtest_oraOCINumber", __FILE__)
- << qTableName( "bug2192", __FILE__);
+ << qTableName("qtest_null", __FILE__, db)
+ << qTableName("qtest_blob", __FILE__, db)
+ << qTableName("qtest_bittest", __FILE__, db)
+ << qTableName("qtest_nullblob", __FILE__, db)
+ << qTableName("qtest_rawtest", __FILE__, db)
+ << qTableName("qtest_precision", __FILE__, db)
+ << qTableName("qtest_prepare", __FILE__, db)
+ << qTableName("qtestj1", __FILE__, db)
+ << qTableName("qtestj2", __FILE__, db)
+ << qTableName("char1Select", __FILE__, db)
+ << qTableName("char1SU", __FILE__, db)
+ << qTableName("qxmltest", __FILE__, db)
+ << qTableName("qtest_exerr", __FILE__, db)
+ << qTableName("qtest_empty", __FILE__, db)
+ << qTableName("clobby", __FILE__, db)
+ << qTableName("bindtest", __FILE__, db)
+ << qTableName("more_results", __FILE__, db)
+ << qTableName("blobstest", __FILE__, db)
+ << qTableName("oraRowId", __FILE__, db)
+ << qTableName("qtest_batch", __FILE__, db)
+ << qTableName("bug6421", __FILE__, db).toUpper()
+ << qTableName("bug5765", __FILE__, db)
+ << qTableName("bug6852", __FILE__, db)
+ << qTableName("bug21884", __FILE__, db)
+ << qTableName("bug23895", __FILE__, db)
+ << qTableName("qtest_lockedtable", __FILE__, db)
+ << qTableName("Planet", __FILE__, db)
+ << qTableName("task_250026", __FILE__, db)
+ << qTableName("task_234422", __FILE__, db)
+ << qTableName("test141895", __FILE__, db)
+ << qTableName("qtest_oraOCINumber", __FILE__, db)
+ << qTableName("bug2192", __FILE__, db);
if ( db.driverName().startsWith("QPSQL") )
- tablenames << qTableName("task_233829", __FILE__);
+ tablenames << qTableName("task_233829", __FILE__, db);
if ( db.driverName().startsWith("QSQLITE") )
- tablenames << qTableName( "record_sqlite", __FILE__ );
+ tablenames << qTableName("record_sqlite", __FILE__, db);
if ( tst_Databases::isSqlServer( db ) || db.driverName().startsWith( "QOCI" ) )
- tablenames << qTableName( "qtest_longstr", __FILE__ );
+ tablenames << qTableName("qtest_longstr", __FILE__, db);
if (tst_Databases::isSqlServer( db ))
- db.exec("DROP PROCEDURE " + qTableName("test141895_proc", __FILE__));
+ db.exec("DROP PROCEDURE " + qTableName("test141895_proc", __FILE__, db));
if (tst_Databases::isMySQL( db ))
- db.exec("DROP PROCEDURE IF EXISTS "+qTableName("bug6852_proc", __FILE__));
+ db.exec("DROP PROCEDURE IF EXISTS "+qTableName("bug6852_proc", __FILE__, db));
tst_Databases::safeDropTables( db, tablenames );
if ( db.driverName().startsWith( "QOCI" ) ) {
QSqlQuery q( db );
- q.exec( "DROP PACKAGE " + qTableName("pkg", __FILE__) );
+ q.exec("DROP PACKAGE " + qTableName("pkg", __FILE__, db));
}
}
@@ -388,15 +391,15 @@ void tst_QSqlQuery::createTestTables( QSqlDatabase db )
QVERIFY_SQL( q, exec( "create table " + qtest + " (id int "+tst_Databases::autoFieldName(db) +" NOT NULL, t_varchar varchar(20), t_char char(20), primary key(id))" ) );
if ( tst_Databases::isSqlServer( db ) || db.driverName().startsWith( "QTDS" ) )
- QVERIFY_SQL( q, exec( "create table " + qTableName( "qtest_null", __FILE__ ) + " (id int null, t_varchar varchar(20) null)" ) );
+ QVERIFY_SQL(q, exec("create table " + qTableName("qtest_null", __FILE__, db) + " (id int null, t_varchar varchar(20) null)"));
else
- QVERIFY_SQL( q, exec( "create table " + qTableName( "qtest_null", __FILE__ ) + " (id int, t_varchar varchar(20))" ) );
+ QVERIFY_SQL(q, exec("create table " + qTableName("qtest_null", __FILE__, db) + " (id int, t_varchar varchar(20))"));
}
void tst_QSqlQuery::populateTestTables( QSqlDatabase db )
{
QSqlQuery q( db );
- const QString qtest_null(qTableName( "qtest_null", __FILE__ ));
+ const QString qtest_null(qTableName( "qtest_null", __FILE__, db));
q.exec( "delete from " + qtest );
QVERIFY_SQL( q, exec( "insert into " + qtest + " values (1, 'VarChar1', 'Char1')" ) );
QVERIFY_SQL( q, exec( "insert into " + qtest + " values (2, 'VarChar2', 'Char2')" ) );
@@ -420,7 +423,7 @@ void tst_QSqlQuery::char1Select()
{
QSqlQuery q( db );
- const QString tbl = qTableName("char1Select", __FILE__);
+ const QString tbl = qTableName("char1Select", __FILE__, db);
q.exec( "drop table " + tbl);
QVERIFY_SQL(q, exec("create table " + tbl + " (id char(1))"));
QVERIFY_SQL(q, exec("insert into " + tbl + " values ('a')"));
@@ -453,7 +456,7 @@ void tst_QSqlQuery::char1SelectUnicode()
QSKIP( "Test requires MySQL >= 5.0");
QString createQuery;
- const QString char1SelectUnicode(qTableName( "char1SU", __FILE__ ));
+ const QString char1SelectUnicode(qTableName("char1SU", __FILE__, db));
if ( tst_Databases::isSqlServer( db ) )
createQuery = "create table " + char1SelectUnicode + "(id nchar(1))";
@@ -498,7 +501,7 @@ void tst_QSqlQuery::oraRowId()
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
- const QString oraRowId(qTableName("oraRowId", __FILE__));
+ const QString oraRowId(qTableName("oraRowId", __FILE__, db));
QSqlQuery q( db );
QVERIFY_SQL( q, exec( "select rowid from " + qtest ) );
@@ -533,7 +536,7 @@ void tst_QSqlQuery::mysqlOutValues()
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
- const QString hello(qTableName( "hello", __FILE__ )), qtestproc(qTableName( "qtestproc", __FILE__ ));
+ const QString hello(qTableName("hello", __FILE__, db)), qtestproc(qTableName("qtestproc", __FILE__, db));
QSqlQuery q( db );
@@ -591,7 +594,7 @@ void tst_QSqlQuery::bindBool()
CHECK_DATABASE( db );
QSqlQuery q(db);
- const QString tableName(qTableName( "bindBool", __FILE__ ));
+ const QString tableName(qTableName("bindBool", __FILE__, db));
q.exec("DROP TABLE " + tableName);
QString colType = db.driverName().startsWith("QPSQL") ? QLatin1String("BOOLEAN") : QLatin1String("INT");
QVERIFY_SQL(q, exec("CREATE TABLE " + tableName + " (id INT, flag " + colType + " NOT NULL, PRIMARY KEY(id))"));
@@ -619,7 +622,7 @@ void tst_QSqlQuery::oraOutValues()
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
- const QString tst_outValues(qTableName("tst_outValues", __FILE__));
+ const QString tst_outValues(qTableName("tst_outValues", __FILE__, db));
if ( !db.driver()->hasFeature( QSqlDriver::PreparedQueries ) )
QSKIP( "Test requires prepared query support");
@@ -715,7 +718,7 @@ void tst_QSqlQuery::oraClob()
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
- const QString clobby(qTableName("clobby", __FILE__));
+ const QString clobby(qTableName("clobby", __FILE__, db));
QSqlQuery q( db );
@@ -768,16 +771,16 @@ void tst_QSqlQuery::storedProceduresIBase()
CHECK_DATABASE( db );
QSqlQuery q( db );
- q.exec( "drop procedure " + qTableName( "TESTPROC", __FILE__ ) );
+ q.exec("drop procedure " + qTableName("TESTPROC", __FILE__, db));
- QVERIFY_SQL( q, exec( "create procedure " + qTableName( "TESTPROC", __FILE__ ) +
+ QVERIFY_SQL(q, exec("create procedure " + qTableName("TESTPROC", __FILE__, db) +
" RETURNS (x integer, y varchar(20)) "
"AS BEGIN "
" x = 42; "
" y = 'Hello Anders'; "
"END" ) );
- QVERIFY_SQL( q, prepare( "execute procedure " + qTableName( "TestProc", __FILE__ ) ) );
+ QVERIFY_SQL(q, prepare("execute procedure " + qTableName("TestProc", __FILE__, db)));
QVERIFY_SQL( q, exec() );
// check for a valid result set
@@ -794,7 +797,7 @@ void tst_QSqlQuery::storedProceduresIBase()
// the second next shall fail
QVERIFY( !q.next() );
- q.exec( "drop procedure " + qTableName( "TestProc", __FILE__ ) );
+ q.exec("drop procedure " + qTableName("TestProc", __FILE__, db));
}
void tst_QSqlQuery::outValuesDB2()
@@ -810,8 +813,8 @@ void tst_QSqlQuery::outValuesDB2()
q.setForwardOnly( true );
- q.exec( "drop procedure " + qTableName( "tst_outValues", __FILE__ ) ); //non-fatal
- QVERIFY_SQL( q, exec( "CREATE PROCEDURE " + qTableName( "tst_outValues", __FILE__ ) +
+ q.exec("drop procedure " + qTableName("tst_outValues", __FILE__, db)); //non-fatal
+ QVERIFY_SQL( q, exec( "CREATE PROCEDURE " + qTableName("tst_outValues", __FILE__, db) +
" (OUT x int, OUT x2 double, OUT x3 char(20))\n"
"LANGUAGE SQL\n"
"P1: BEGIN\n"
@@ -820,7 +823,7 @@ void tst_QSqlQuery::outValuesDB2()
" SET x3 = 'Homer';\n"
"END P1" ) );
- QVERIFY_SQL( q, prepare( "call " + qTableName( "tst_outValues", __FILE__ ) + "(?, ?, ?)" ) );
+ QVERIFY_SQL(q, prepare("call " + qTableName("tst_outValues", __FILE__, db) + "(?, ?, ?)"));
q.addBindValue( 0, QSql::Out );
q.addBindValue( 0.0, QSql::Out );
@@ -838,7 +841,7 @@ void tst_QSqlQuery::outValues()
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
- const QString tst_outValues(qTableName("tst_outValues", __FILE__));
+ const QString tst_outValues(qTableName("tst_outValues", __FILE__, db));
if ( !db.driver()->hasFeature( QSqlDriver::PreparedQueries ) )
QSKIP( "Test requires prepared query support");
@@ -902,11 +905,11 @@ void tst_QSqlQuery::blob()
q.setForwardOnly( true );
- QString queryString = QString( "create table " + qTableName( "qtest_blob", __FILE__ ) +
+ QString queryString = QString("create table " + qTableName("qtest_blob", __FILE__, db) +
" (id int not null primary key, t_blob %1)" ).arg( tst_Databases::blobTypeName( db, BLOBSIZE ) );
QVERIFY_SQL( q, exec( queryString ) );
- QVERIFY_SQL( q, prepare( "insert into " + qTableName( "qtest_blob", __FILE__ ) + " (id, t_blob) values (?, ?)" ) );
+ QVERIFY_SQL(q, prepare("insert into " + qTableName("qtest_blob", __FILE__, db) + " (id, t_blob) values (?, ?)"));
for ( i = 0; i < BLOBCOUNT; ++i ) {
q.addBindValue( i );
@@ -914,7 +917,7 @@ void tst_QSqlQuery::blob()
QVERIFY_SQL( q, exec() );
}
- QVERIFY_SQL( q, exec( "select * from " + qTableName( "qtest_blob", __FILE__ ) ) );
+ QVERIFY_SQL(q, exec("select * from " + qTableName("qtest_blob", __FILE__, db)));
for ( i = 0; i < BLOBCOUNT; ++i ) {
QVERIFY( q.next() );
@@ -1027,6 +1030,10 @@ void tst_QSqlQuery::isActive()
QVERIFY_SQL( q, exec( "delete from " + qtest + " where id = 42" ) );
QVERIFY( q.isActive() );
+
+ QVERIFY_SQL( q, exec( "delete from " + qtest + " where id = 42" ) );
+
+ QVERIFY( q.isActive() );
}
void tst_QSqlQuery::numRowsAffected()
@@ -1375,7 +1382,7 @@ void tst_QSqlQuery::isNull()
CHECK_DATABASE( db );
QSqlQuery q( db );
- QVERIFY_SQL( q, exec( "select id, t_varchar from " + qTableName( "qtest_null", __FILE__ ) + " order by id" ) );
+ QVERIFY_SQL(q, exec("select id, t_varchar from " + qTableName("qtest_null", __FILE__, db) + " order by id"));
QVERIFY( q.next() );
QVERIFY( !q.isNull( 0 ) );
QVERIFY( q.isNull( 1 ) );
@@ -1401,13 +1408,13 @@ void tst_QSqlQuery::bitField()
QSqlQuery q( db );
- QVERIFY_SQL( q, exec( "create table " + qTableName( "qtest_bittest", __FILE__ ) + " (bitty bit)" ) );
+ QVERIFY_SQL(q, exec("create table " + qTableName("qtest_bittest", __FILE__, db) + " (bitty bit)"));
- QVERIFY_SQL( q, exec( "insert into " + qTableName( "qtest_bittest", __FILE__ ) + " values (0)" ) );
+ QVERIFY_SQL(q, exec("insert into " + qTableName("qtest_bittest", __FILE__, db) + " values (0)"));
- QVERIFY_SQL( q, exec( "insert into " + qTableName( "qtest_bittest", __FILE__ ) + " values (1)" ) );
+ QVERIFY_SQL(q, exec("insert into " + qTableName("qtest_bittest", __FILE__, db) + " values (1)"));
- QVERIFY_SQL( q, exec( "select bitty from " + qTableName( "qtest_bittest", __FILE__ ) ) );
+ QVERIFY_SQL(q, exec("select bitty from " + qTableName("qtest_bittest", __FILE__, db)));
QVERIFY( q.next() );
@@ -1425,7 +1432,7 @@ void tst_QSqlQuery::nullBlob()
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
- const QString qtest_nullblob(qTableName("qtest_nullblob", __FILE__));
+ const QString qtest_nullblob(qTableName("qtest_nullblob", __FILE__, db));
QSqlQuery q( db );
QVERIFY_SQL( q, exec( "create table " + qtest_nullblob + " (id int primary key, bb blob)" ) );
@@ -1455,7 +1462,7 @@ void tst_QSqlQuery::rawField()
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
- const QString qtest_rawtest(qTableName("qtest_rawtest", __FILE__));
+ const QString qtest_rawtest(qTableName("qtest_rawtest", __FILE__, db));
QSqlQuery q( db );
q.setForwardOnly( true );
@@ -1480,7 +1487,7 @@ void tst_QSqlQuery::precision()
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
- const QString qtest_precision(qTableName( "qtest_precision", __FILE__ ));
+ const QString qtest_precision(qTableName("qtest_precision", __FILE__, db));
static const char* precStr = "1.2345678901234567891";
@@ -1639,7 +1646,7 @@ void tst_QSqlQuery::joins()
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
- const QString qtestj1(qTableName("qtestj1", __FILE__)), qtestj2(qTableName("qtestj2", __FILE__));
+ const QString qtestj1(qTableName("qtestj1", __FILE__, db)), qtestj2(qTableName("qtestj2", __FILE__, db));
if ( db.driverName().startsWith( "QOCI" )
|| db.driverName().startsWith( "QTDS" )
@@ -1724,7 +1731,7 @@ void tst_QSqlQuery::prepare_bind_exec()
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
- const QString qtest_prepare(qTableName("qtest_prepare", __FILE__));
+ const QString qtest_prepare(qTableName("qtest_prepare", __FILE__, db));
if(db.driverName().startsWith("QIBASE") && (db.databaseName() == "silence.nokia.troll.no:c:\\ibase\\testdb_ascii" || db.databaseName() == "/opt/interbase/qttest.gdb"))
QSKIP("Can't transliterate extended unicode to ascii");
@@ -2024,9 +2031,9 @@ void tst_QSqlQuery::sqlServerLongStrings()
QSqlQuery q( db );
- QVERIFY_SQL( q, exec( "CREATE TABLE " + qTableName( "qtest_longstr", __FILE__ ) + " (id int primary key, longstring ntext)" ) );
+ QVERIFY_SQL(q, exec("CREATE TABLE " + qTableName("qtest_longstr", __FILE__, db) + " (id int primary key, longstring ntext)"));
- QVERIFY_SQL( q, prepare( "INSERT INTO " + qTableName( "qtest_longstr", __FILE__ ) + " VALUES (?, ?)" ) );
+ QVERIFY_SQL(q, prepare("INSERT INTO " + qTableName("qtest_longstr", __FILE__, db) + " VALUES (?, ?)"));
q.addBindValue( 0 );
@@ -2044,7 +2051,7 @@ void tst_QSqlQuery::sqlServerLongStrings()
QVERIFY_SQL( q, exec() );
- QVERIFY_SQL( q, exec( "select * from " + qTableName( "qtest_longstr", __FILE__ ) ) );
+ QVERIFY_SQL(q, exec("select * from " + qTableName( "qtest_longstr", __FILE__, db)));
QVERIFY_SQL( q, next() );
@@ -2096,7 +2103,7 @@ void tst_QSqlQuery::batchExec()
QSKIP( "Database can't do BatchOperations");
QSqlQuery q( db );
- const QString tableName = qTableName( "qtest_batch", __FILE__ );
+ const QString tableName = qTableName("qtest_batch", __FILE__, db);
QVERIFY_SQL( q, exec( "create table " + tableName + " (id int, name varchar(20), dt date, num numeric(8, 4))" ) );
QVERIFY_SQL( q, prepare( "insert into " + tableName + " (id, name, dt, num) values (?, ?, ?, ?)" ) );
@@ -2240,9 +2247,9 @@ void tst_QSqlQuery::record_sqlite()
QSqlQuery q( db );
- QVERIFY_SQL( q, exec( "create table "+qTableName( "record_sqlite", __FILE__ )+"(id integer primary key, name varchar, title int)" ) );
+ QVERIFY_SQL(q, exec("create table " + qTableName("record_sqlite", __FILE__, db) + "(id integer primary key, name varchar, title int)"));
- QSqlRecord rec = db.record( qTableName( "record_sqlite", __FILE__ ) );
+ QSqlRecord rec = db.record(qTableName("record_sqlite", __FILE__, db));
QCOMPARE( rec.count(), 3 );
QCOMPARE( rec.field( 0 ).type(), QVariant::Int );
@@ -2250,7 +2257,7 @@ void tst_QSqlQuery::record_sqlite()
QCOMPARE( rec.field( 2 ).type(), QVariant::Int );
/* important - select from an empty table */
- QVERIFY_SQL( q, exec( "select id, name, title from "+qTableName( "record_sqlite", __FILE__ ) ) );
+ QVERIFY_SQL(q, exec("select id, name, title from " + qTableName("record_sqlite", __FILE__, db)));
rec = q.record();
QCOMPARE( rec.count(), 3 );
@@ -2269,13 +2276,13 @@ void tst_QSqlQuery::oraLong()
QString aLotOfText( 127000, QLatin1Char( 'H' ) );
- QVERIFY_SQL( q, exec( "create table " + qTableName( "qtest_longstr", __FILE__ ) + " (id int primary key, astr long)" ) );
- QVERIFY_SQL( q, prepare( "insert into " + qTableName( "qtest_longstr", __FILE__ ) + " (id, astr) values (?, ?)" ) );
+ QVERIFY_SQL(q, exec("create table " + qTableName("qtest_longstr", __FILE__, db) + " (id int primary key, astr long)"));
+ QVERIFY_SQL(q, prepare("insert into " + qTableName("qtest_longstr", __FILE__, db) + " (id, astr) values (?, ?)"));
q.addBindValue( 1 );
q.addBindValue( aLotOfText );
QVERIFY_SQL( q, exec() );
- QVERIFY_SQL( q, exec( "select id,astr from " + qTableName( "qtest_longstr", __FILE__ ) ) );
+ QVERIFY_SQL(q, exec("select id,astr from " + qTableName("qtest_longstr", __FILE__, db)));
QVERIFY( q.next() );
QCOMPARE( q.value( 0 ).toInt(), 1 );
@@ -2290,7 +2297,7 @@ void tst_QSqlQuery::execErrorRecovery()
QSqlQuery q( db );
- const QString tbl = qTableName("qtest_exerr", __FILE__);
+ const QString tbl = qTableName("qtest_exerr", __FILE__, db);
q.exec("drop table " + tbl);
QVERIFY_SQL(q, exec("create table " + tbl + " (id int not null primary key)"));
QVERIFY_SQL(q, prepare("insert into " + tbl + " values (?)" ));
@@ -2347,7 +2354,7 @@ void tst_QSqlQuery::bindWithDoubleColonCastOperator()
if ( !db.driverName().startsWith( "QPSQL" ) )
QSKIP( "Test requires PostgreSQL");
- const QString tablename(qTableName( "bindtest", __FILE__ ));
+ const QString tablename(qTableName("bindtest", __FILE__, db));
QSqlQuery q( db );
@@ -2509,7 +2516,7 @@ void tst_QSqlQuery::sqlite_finish()
db2.setDatabaseName( db.databaseName() );
QVERIFY_SQL( db2, open() );
- const QString tableName(qTableName( "qtest_lockedtable", __FILE__ ));
+ const QString tableName(qTableName("qtest_lockedtable", __FILE__, db));
QSqlQuery q( db );
tst_Databases::safeDropTable( db, tableName );
@@ -2559,7 +2566,7 @@ void tst_QSqlQuery::nextResult()
else if ( db.driverName().startsWith( "QDB2" ) )
driverType = DB2;
- const QString tableName(qTableName( "more_results", __FILE__ ));
+ const QString tableName(qTableName("more_results", __FILE__, db));
QVERIFY_SQL( q, exec( "CREATE TABLE " + tableName + " (id integer, text varchar(20), num numeric(6, 3), empty varchar(10));" ) );
@@ -2663,7 +2670,7 @@ void tst_QSqlQuery::nextResult()
}
// Stored procedure with multiple result sets
- const QString procName(qTableName( "proc_more_res", __FILE__ ));
+ const QString procName(qTableName("proc_more_res", __FILE__, db));
q.exec( QString( "DROP PROCEDURE %1;" ).arg( procName ) );
@@ -2741,7 +2748,7 @@ void tst_QSqlQuery::blobsPreparedQuery()
if ( !db.driver()->hasFeature( QSqlDriver::BLOB ) || !db.driver()->hasFeature( QSqlDriver::PreparedQueries ) )
QSKIP( "DBMS does not support BLOBs or prepared queries");
- const QString tableName(qTableName( "blobstest", __FILE__ ));
+ const QString tableName(qTableName("blobstest", __FILE__, db));
QSqlQuery q( db );
q.setForwardOnly( true ); // This is needed to make the test work with DB2.
@@ -2796,10 +2803,10 @@ void tst_QSqlQuery::emptyTableNavigate()
{
QSqlQuery q( db );
- const QString tbl = qTableName("qtest_empty", __FILE__);
+ const QString tbl = qTableName("qtest_empty", __FILE__, db);
q.exec("drop table " + tbl);
QVERIFY_SQL(q, exec("create table " + tbl + " (id char(10))"));
- QVERIFY_SQL(q, prepare("select * from " + qTableName("qtest_empty", __FILE__ )));
+ QVERIFY_SQL(q, prepare("select * from " + tbl));
QVERIFY_SQL( q, exec() );
QVERIFY( !q.next() );
QCOMPARE( q.lastError().isValid(), false );
@@ -2812,7 +2819,7 @@ void tst_QSqlQuery::task_217003()
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
QSqlQuery q( db );
- const QString Planet(qTableName( "Planet", __FILE__));
+ const QString Planet(qTableName( "Planet", __FILE__, db));
q.exec("drop table " + Planet);
QVERIFY_SQL( q, exec( "create table " + Planet + " (Name varchar(20))" ) );
@@ -2843,7 +2850,7 @@ void tst_QSqlQuery::task_250026()
CHECK_DATABASE( db );
QSqlQuery q( db );
- const QString tableName(qTableName( "task_250026", __FILE__ ));
+ const QString tableName(qTableName("task_250026", __FILE__, db));
if ( !q.exec( "create table " + tableName + " (longfield varchar(1100))" ) ) {
qDebug() << "Error" << q.lastError();
@@ -2891,7 +2898,7 @@ void tst_QSqlQuery::task_229811()
QSqlQuery q( db );
- const QString tableName(qTableName( "task_229811", __FILE__ ));
+ const QString tableName(qTableName("task_229811", __FILE__, db));
if ( !q.exec( "CREATE TABLE " + tableName + " (Word varchar(20))" ) ) {
qDebug() << "Warning" << q.lastError();
@@ -2938,7 +2945,7 @@ void tst_QSqlQuery::task_234422()
m_airlines << "Lufthansa" << "SAS" << "United" << "KLM" << "Aeroflot";
m_countries << "DE" << "SE" << "US" << "NL" << "RU";
- const QString tableName(qTableName( "task_234422", __FILE__ ));
+ const QString tableName(qTableName("task_234422", __FILE__, db));
QVERIFY_SQL(query,exec("CREATE TABLE " + tableName + " (id int primary key, "
"name varchar(20), homecountry varchar(2))"));
@@ -2970,7 +2977,7 @@ void tst_QSqlQuery::task_233829()
CHECK_DATABASE( db );
QSqlQuery q( db );
- const QString tableName(qTableName("task_233829", __FILE__));
+ const QString tableName(qTableName("task_233829", __FILE__, db));
QVERIFY_SQL(q,exec("CREATE TABLE " + tableName + "(dbl1 double precision,dbl2 double precision) without oids;"));
QString queryString("INSERT INTO " + tableName +"(dbl1, dbl2) VALUES(?,?)");
@@ -2990,7 +2997,7 @@ void tst_QSqlQuery::sqlServerReturn0()
if (!tst_Databases::isSqlServer( db ))
QSKIP("SQL Server specific test");
- const QString tableName(qTableName("test141895", __FILE__)), procName(qTableName("test141895_proc", __FILE__));
+ const QString tableName(qTableName("test141895", __FILE__, db)), procName(qTableName("test141895_proc", __FILE__, db));
QSqlQuery q( db );
q.exec("DROP TABLE " + tableName);
q.exec("DROP PROCEDURE " + procName);
@@ -3016,7 +3023,7 @@ void tst_QSqlQuery::QTBUG_551()
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
QSqlQuery q(db);
- const QString pkgname(qTableName("pkg", __FILE__));
+ const QString pkgname(qTableName("pkg", __FILE__, db));
QVERIFY_SQL(q, exec("CREATE OR REPLACE PACKAGE "+pkgname+" IS \n\
\n\
TYPE IntType IS TABLE OF INTEGER INDEX BY BINARY_INTEGER;\n\
@@ -3063,7 +3070,7 @@ void tst_QSqlQuery::QTBUG_14132()
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
QSqlQuery q(db);
- const QString procedureName(qTableName("procedure", __FILE__));
+ const QString procedureName(qTableName("procedure", __FILE__, db));
QVERIFY_SQL(q, exec("CREATE OR REPLACE PROCEDURE "+ procedureName + " (outStr OUT varchar2) \n\
is \n\
begin \n\
@@ -3086,7 +3093,7 @@ void tst_QSqlQuery::QTBUG_18435()
return;
QSqlQuery q(db);
- QString procName(qTableName("qtbug_18435_proc", __FILE__));
+ QString procName(qTableName("qtbug_18435_proc", __FILE__, db));
q.exec("DROP PROCEDURE " + procName);
const QString stmt =
@@ -3111,7 +3118,7 @@ void tst_QSqlQuery::QTBUG_5251()
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
- const QString timetest(qTableName("timetest", __FILE__));
+ const QString timetest(qTableName("timetest", __FILE__, db));
if (!db.driverName().startsWith( "QPSQL" )) return;
@@ -3144,7 +3151,7 @@ void tst_QSqlQuery::QTBUG_6421()
CHECK_DATABASE( db );
QSqlQuery q(db);
- const QString tableName(qTableName("bug6421", __FILE__).toUpper());
+ const QString tableName(qTableName("bug6421", __FILE__, db).toUpper());
QVERIFY_SQL(q, exec("create table "+tableName+"(COL1 char(10), COL2 char(10), COL3 char(10))"));
QVERIFY_SQL(q, exec("create index INDEX1 on "+tableName+" (COL1 desc)"));
@@ -3169,16 +3176,16 @@ void tst_QSqlQuery::QTBUG_6618()
QSKIP("SQL Server specific test");
QSqlQuery q(db);
- q.exec( "drop procedure " + qTableName( "tst_raiseError", __FILE__ ) ); //non-fatal
+ q.exec("drop procedure " + qTableName("tst_raiseError", __FILE__, db)); //non-fatal
QString errorString;
for (int i=0;i<110;i++)
errorString+="reallylong";
errorString+=" error";
- QVERIFY_SQL( q, exec("create procedure " + qTableName( "tst_raiseError", __FILE__ ) + " as\n"
+ QVERIFY_SQL(q, exec("create procedure " + qTableName("tst_raiseError", __FILE__, db) + " as\n"
"begin\n"
" raiserror('" + errorString + "', 16, 1)\n"
"end\n" ));
- q.exec( "{call " + qTableName( "tst_raiseError", __FILE__ ) + "}" );
+ q.exec("{call " + qTableName("tst_raiseError", __FILE__, db) + "}");
QVERIFY(q.lastError().text().contains(errorString));
}
@@ -3191,7 +3198,7 @@ void tst_QSqlQuery::QTBUG_6852()
QSKIP( "Test requires MySQL >= 5.0");
QSqlQuery q(db);
- const QString tableName(qTableName("bug6852", __FILE__)), procName(qTableName("bug6852_proc", __FILE__));
+ const QString tableName(qTableName("bug6852", __FILE__, db)), procName(qTableName("bug6852_proc", __FILE__, db));
QVERIFY_SQL(q, exec("DROP PROCEDURE IF EXISTS "+procName));
QVERIFY_SQL(q, exec("CREATE TABLE "+tableName+"(\n"
@@ -3225,7 +3232,7 @@ void tst_QSqlQuery::QTBUG_5765()
QSKIP( "Test requires MySQL >= 4.1");
QSqlQuery q(db);
- const QString tableName(qTableName("bug5765", __FILE__));
+ const QString tableName(qTableName("bug5765", __FILE__, db));
QVERIFY_SQL(q, exec("CREATE TABLE "+tableName+"(testval TINYINT(1) DEFAULT 0)"));
q.prepare("INSERT INTO "+tableName+" SET testval = :VALUE");
@@ -3268,7 +3275,7 @@ void tst_QSqlQuery::QTBUG_21884()
QSqlQuery q(db);
QStringList stList;
- QString tableName(qTableName("bug21884", __FILE__ ));
+ QString tableName(qTableName("bug21884", __FILE__, db));
stList << "create table " + tableName + "(id integer primary key, note string)";
stList << "select * from " + tableName + ";";
stList << "select * from " + tableName + "; \t\n\r";
@@ -3363,7 +3370,7 @@ void tst_QSqlQuery::QTBUG_23895()
QSqlQuery q(db);
- QString tableName(qTableName("bug23895", __FILE__ ));
+ QString tableName(qTableName("bug23895", __FILE__, db));
q.prepare("create table " + tableName + "(id integer primary key, val1 bool, val2 boolean)");
QVERIFY_SQL(q, exec());
q.prepare("insert into " + tableName + "(id, val1, val2) values(?, ?, ?);");
@@ -3407,26 +3414,67 @@ void tst_QSqlQuery::QTBUG_23895()
QVERIFY(!q.next());
}
+/**
+ * Test for aliases with dots
+ */
+void tst_QSqlQuery::QTBUG_14904()
+{
+ QFETCH(QString, dbName);
+ QSqlDatabase db = QSqlDatabase::database(dbName);
+ CHECK_DATABASE(db);
+
+ QSqlQuery q(db);
+
+ QString tableName(qTableName("bug14904", __FILE__, db));
+ tst_Databases::safeDropTable( db, tableName );
+
+ q.prepare("create table " + tableName + "(val1 bool)");
+ QVERIFY_SQL(q, exec());
+ q.prepare("insert into " + tableName + "(val1) values(?);");
+ q.addBindValue(true);
+ QVERIFY_SQL(q, exec());
+
+ QString sql="select val1 AS value1 from " + tableName;
+ QVERIFY_SQL(q, exec(sql));
+ QVERIFY_SQL(q, next());
+
+ QCOMPARE(q.record().indexOf("value1"), 0);
+ QCOMPARE(q.record().field(0).type(), QVariant::Bool);
+ QCOMPARE(q.value(0).toBool(), true);
+
+ sql="select val1 AS 'value.one' from " + tableName;
+ QVERIFY_SQL(q, exec(sql));
+ QVERIFY_SQL(q, next());
+ QCOMPARE(q.record().indexOf("value.one"), 0); // was -1 before bug fix
+ QCOMPARE(q.record().field(0).type(), QVariant::Bool);
+ QCOMPARE(q.value(0).toBool(), true);
+}
+
void tst_QSqlQuery::QTBUG_2192()
{
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
{
- const QString tableName(qTableName("bug2192", __FILE__));
+ const QString tableName(qTableName("bug2192", __FILE__, db));
tst_Databases::safeDropTable( db, tableName );
QSqlQuery q(db);
QVERIFY_SQL(q, exec(QString("CREATE TABLE " + tableName + " (dt %1)").arg(tst_Databases::dateTimeTypeName(db))));
+ QDateTime dt = QDateTime(QDate(2012, 7, 4), QTime(23, 59, 59, 999));
QVERIFY_SQL(q, prepare("INSERT INTO " + tableName + " (dt) VALUES (?)"));
- q.bindValue(0, QVariant(QDateTime(QDate(2012, 7, 4), QTime(23, 59, 59, 999))));
+ q.bindValue(0, dt);
QVERIFY_SQL(q, exec());
- // Check if value was stored with at least second precision.
QVERIFY_SQL(q, exec("SELECT dt FROM " + tableName));
QVERIFY_SQL(q, next());
- QVERIFY(q.value(0).toDateTime().msecsTo(QDateTime(QDate(2012, 7, 4), QTime(23, 59, 59, 999))) < 1000 );
+
+ // Check if retrieved value preserves reported precision
+ int precision = qMax(0, q.record().field("dt").precision());
+ int diff = qAbs(q.value(0).toDateTime().msecsTo(dt));
+ int keep = qMin(1000, (int)qPow(10.0, precision));
+ QVERIFY(diff <= 1000 - keep);
}
}
@@ -3435,7 +3483,7 @@ void tst_QSqlQuery::oraOCINumber()
QFETCH( QString, dbName );
QSqlDatabase db = QSqlDatabase::database( dbName );
CHECK_DATABASE( db );
- const QString qtest_oraOCINumber(qTableName("qtest_oraOCINumber", __FILE__));
+ const QString qtest_oraOCINumber(qTableName("qtest_oraOCINumber", __FILE__, db));
QSqlQuery q( db );
q.setForwardOnly( true );
@@ -3544,7 +3592,7 @@ void tst_QSqlQuery::sqlite_constraint()
QSKIP("Sqlite3 specific test");
QSqlQuery q(db);
- const QString trigger(qTableName("test_constraint", __FILE__));
+ const QString trigger(qTableName("test_constraint", __FILE__, db));
QVERIFY_SQL(q, exec("CREATE TEMP TRIGGER "+trigger+" BEFORE DELETE ON "+qtest+
"\nFOR EACH ROW "
@@ -3562,7 +3610,7 @@ void tst_QSqlQuery::sqlite_real()
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString tableName(qTableName("sqliterealtype", __FILE__));
+ const QString tableName(qTableName("sqliterealtype", __FILE__, db));
tst_Databases::safeDropTable( db, tableName );
QSqlQuery q(db);
@@ -3593,8 +3641,10 @@ void tst_QSqlQuery::aggregateFunctionTypes()
// QPSQL uses LongLong for manipulation of integers
if (db.driverName().startsWith("QPSQL") || db.driverName().startsWith("QMYSQL"))
intType = QVariant::LongLong;
+ else if (db.driverName().startsWith("QOCI"))
+ intType = QVariant::Double;
{
- const QString tableName(qTableName("numericFunctionsWithIntValues", __FILE__));
+ const QString tableName(qTableName("numericFunctionsWithIntValues", __FILE__, db));
tst_Databases::safeDropTable( db, tableName );
QSqlQuery q(db);
@@ -3624,7 +3674,7 @@ void tst_QSqlQuery::aggregateFunctionTypes()
QVERIFY_SQL(q, exec("SELECT AVG(id) FROM " + tableName));
QVERIFY(q.next());
if (db.driverName().startsWith("QSQLITE") || db.driverName().startsWith("QPSQL")
- || (db.driverName().startsWith("QMYSQL"))) {
+ || db.driverName().startsWith("QMYSQL") || db.driverName().startsWith("QOCI")) {
QCOMPARE(q.value(0).toDouble(), 1.5);
QCOMPARE(q.record().field(0).type(), QVariant::Double);
} else {
@@ -3640,15 +3690,15 @@ void tst_QSqlQuery::aggregateFunctionTypes()
QVERIFY_SQL(q, exec("SELECT MIN(id) FROM " + tableName));
QVERIFY(q.next());
QCOMPARE(q.value(0).toInt(), 1);
- QCOMPARE(q.record().field(0).type(), QVariant::Int);
+ QCOMPARE(q.record().field(0).type(), intType);
QVERIFY_SQL(q, exec("SELECT MAX(id) FROM " + tableName));
QVERIFY(q.next());
QCOMPARE(q.value(0).toInt(), 2);
- QCOMPARE(q.record().field(0).type(), QVariant::Int);
+ QCOMPARE(q.record().field(0).type(), intType);
}
{
- const QString tableName(qTableName("numericFunctionsWithDoubleValues", __FILE__));
+ const QString tableName(qTableName("numericFunctionsWithDoubleValues", __FILE__, db));
tst_Databases::safeDropTable( db, tableName );
QSqlQuery q(db);
@@ -3707,7 +3757,7 @@ void tst_QSqlQuery::aggregateFunctionTypes()
}
}
{
- const QString tableName(qTableName("stringFunctions", __FILE__));
+ const QString tableName(qTableName("stringFunctions", __FILE__, db));
tst_Databases::safeDropTable( db, tableName );
QSqlQuery q(db);
diff --git a/tests/auto/sql/kernel/qsqlrecord/qsqlrecord.pro b/tests/auto/sql/kernel/qsqlrecord/qsqlrecord.pro
index 5c71b07d33..0e92797bb0 100644
--- a/tests/auto/sql/kernel/qsqlrecord/qsqlrecord.pro
+++ b/tests/auto/sql/kernel/qsqlrecord/qsqlrecord.pro
@@ -4,4 +4,3 @@ TARGET = tst_qsqlrecord
SOURCES += tst_qsqlrecord.cpp
QT = core sql testlib
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/sql/kernel/qsqlresult/qsqlresult.pro b/tests/auto/sql/kernel/qsqlresult/qsqlresult.pro
index abd32ee017..ef6c7a7e09 100644
--- a/tests/auto/sql/kernel/qsqlresult/qsqlresult.pro
+++ b/tests/auto/sql/kernel/qsqlresult/qsqlresult.pro
@@ -8,4 +8,3 @@ HEADERS += testsqldriver.h
win32-g++*: LIBS += -lws2_32
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/sql/kernel/qsqlresult/testsqldriver.h b/tests/auto/sql/kernel/qsqlresult/testsqldriver.h
index 7040ddf360..9d435a0f7c 100644
--- a/tests/auto/sql/kernel/qsqlresult/testsqldriver.h
+++ b/tests/auto/sql/kernel/qsqlresult/testsqldriver.h
@@ -86,6 +86,8 @@ public:
case QSqlDriver::PreparedQueries:
case QSqlDriver::NamedPlaceholders:
return true;
+ default:
+ break;
}
return false;
}
diff --git a/tests/auto/sql/kernel/qsqlthread/qsqlthread.pro b/tests/auto/sql/kernel/qsqlthread/qsqlthread.pro
index 4bae8ba882..3249309bf4 100644
--- a/tests/auto/sql/kernel/qsqlthread/qsqlthread.pro
+++ b/tests/auto/sql/kernel/qsqlthread/qsqlthread.pro
@@ -2,7 +2,7 @@ CONFIG += testcase
TARGET = tst_qsqlthread
SOURCES += tst_qsqlthread.cpp
-QT = core sql testlib
+QT = core sql testlib core-private sql-private
wince*: {
@@ -14,4 +14,3 @@ wince*: {
win32:LIBS += -lws2_32
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/sql/kernel/qsqlthread/tst_qsqlthread.cpp b/tests/auto/sql/kernel/qsqlthread/tst_qsqlthread.cpp
index a3fe47be69..1be74dc5fa 100644
--- a/tests/auto/sql/kernel/qsqlthread/tst_qsqlthread.cpp
+++ b/tests/auto/sql/kernel/qsqlthread/tst_qsqlthread.cpp
@@ -53,7 +53,7 @@
#include <pthread.h>
#endif
-const QString qtest(qTableName("qtest", __FILE__));
+const QString qtest(qTableName("qtest", __FILE__, QSqlDatabase()));
// set this define if Oracle is built with threading support
//#define QOCI_THREADED
@@ -303,7 +303,7 @@ void tst_QSqlThread::dropTestTables()
QSqlDatabase db = QSqlDatabase::database(dbs.dbNames.at(i));
QSqlQuery q(db);
- tst_Databases::safeDropTables(db, QStringList() << qtest << qTableName("qtest2", __FILE__) << qTableName("emptytable", __FILE__));
+ tst_Databases::safeDropTables(db, QStringList() << qtest << qTableName("qtest2", __FILE__, db) << qTableName("emptytable", __FILE__, db));
}
}
@@ -316,10 +316,10 @@ void tst_QSqlThread::createTestTables()
QVERIFY_SQL(q, exec("create table " + qtest
+ "(id int NOT NULL primary key, name varchar(20), title int)"));
- QVERIFY_SQL(q, exec("create table " + qTableName("qtest2", __FILE__)
+ QVERIFY_SQL(q, exec("create table " + qTableName("qtest2", __FILE__, db)
+ "(id int NOT NULL primary key, title varchar(20))"));
- QVERIFY_SQL(q, exec("create table " + qTableName("emptytable", __FILE__)
+ QVERIFY_SQL(q, exec("create table " + qTableName("emptytable", __FILE__, db)
+ "(id int NOT NULL primary key)"));
}
}
@@ -335,9 +335,9 @@ void tst_QSqlThread::repopulateTestTables()
QVERIFY_SQL(q, exec("insert into " + qtest + " values(2, 'trond', 2)"));
QVERIFY_SQL(q, exec("insert into " + qtest + " values(3, 'vohi', 3)"));
- QVERIFY_SQL(q, exec("delete from " + qTableName("qtest2", __FILE__)));
- QVERIFY_SQL(q, exec("insert into " + qTableName("qtest2", __FILE__) + " values(1, 'herr')"));
- QVERIFY_SQL(q, exec("insert into " + qTableName("qtest2", __FILE__) + " values(2, 'mister')"));
+ QVERIFY_SQL(q, exec("delete from " + qTableName("qtest2", __FILE__, db)));
+ QVERIFY_SQL(q, exec("insert into " + qTableName("qtest2", __FILE__, db) + " values(1, 'herr')"));
+ QVERIFY_SQL(q, exec("insert into " + qTableName("qtest2", __FILE__, db) + " values(2, 'mister')"));
}
}
diff --git a/tests/auto/sql/models/qsqlquerymodel/qsqlquerymodel.pro b/tests/auto/sql/models/qsqlquerymodel/qsqlquerymodel.pro
index 915404c196..40ec56d473 100644
--- a/tests/auto/sql/models/qsqlquerymodel/qsqlquerymodel.pro
+++ b/tests/auto/sql/models/qsqlquerymodel/qsqlquerymodel.pro
@@ -2,7 +2,7 @@ CONFIG += testcase
TARGET = tst_qsqlquerymodel
SOURCES += tst_qsqlquerymodel.cpp
-QT += widgets sql testlib
+QT += widgets sql testlib core-private sql-private
wince*: {
DEPLOYMENT_PLUGIN += qsqlite
@@ -11,4 +11,3 @@ wince*: {
win32:LIBS += -lws2_32
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/sql/models/qsqlquerymodel/tst_qsqlquerymodel.cpp b/tests/auto/sql/models/qsqlquerymodel/tst_qsqlquerymodel.cpp
index 774620b366..cb9b4a5c1f 100644
--- a/tests/auto/sql/models/qsqlquerymodel/tst_qsqlquerymodel.cpp
+++ b/tests/auto/sql/models/qsqlquerymodel/tst_qsqlquerymodel.cpp
@@ -147,10 +147,10 @@ void tst_QSqlQueryModel::cleanupTestCase()
void tst_QSqlQueryModel::dropTestTables(QSqlDatabase db)
{
QStringList tableNames;
- tableNames << qTableName("test", __FILE__)
- << qTableName("test2", __FILE__)
- << qTableName("test3", __FILE__)
- << qTableName("many", __FILE__);
+ tableNames << qTableName("test", __FILE__, db)
+ << qTableName("test2", __FILE__, db)
+ << qTableName("test3", __FILE__, db)
+ << qTableName("many", __FILE__, db);
tst_Databases::safeDropTables(db, tableNames);
}
@@ -160,10 +160,10 @@ void tst_QSqlQueryModel::createTestTables(QSqlDatabase db)
QSqlQuery q(db);
if(tst_Databases::isPostgreSQL(db))
QVERIFY_SQL( q, exec("set client_min_messages='warning'"));
- QVERIFY_SQL( q, exec("create table " + qTableName("test", __FILE__) + "(id integer not null, name varchar(20), title integer, primary key (id))"));
- QVERIFY_SQL( q, exec("create table " + qTableName("test2", __FILE__) + "(id integer not null, title varchar(20), primary key (id))"));
- QVERIFY_SQL( q, exec("create table " + qTableName("test3", __FILE__) + "(id integer not null, primary key (id))"));
- QVERIFY_SQL( q, exec("create table " + qTableName("many", __FILE__) + "(id integer not null, name varchar(20), primary key (id))"));
+ QVERIFY_SQL( q, exec("create table " + qTableName("test", __FILE__, db) + "(id integer not null, name varchar(20), title integer, primary key (id))"));
+ QVERIFY_SQL( q, exec("create table " + qTableName("test2", __FILE__, db) + "(id integer not null, title varchar(20), primary key (id))"));
+ QVERIFY_SQL( q, exec("create table " + qTableName("test3", __FILE__, db) + "(id integer not null, primary key (id))"));
+ QVERIFY_SQL( q, exec("create table " + qTableName("many", __FILE__, db) + "(id integer not null, name varchar(20), primary key (id))"));
}
void tst_QSqlQueryModel::populateTestTables(QSqlDatabase db)
@@ -173,38 +173,38 @@ void tst_QSqlQueryModel::populateTestTables(QSqlDatabase db)
QSqlQuery q(db), q2(db);
- tst_Databases::safeDropTables(db, QStringList() << qTableName("manytmp", __FILE__) << qTableName("test3tmp", __FILE__));
- QVERIFY_SQL(q, exec("create table " + qTableName("manytmp", __FILE__) + "(id integer not null, name varchar(20), primary key (id))"));
- QVERIFY_SQL(q, exec("create table " + qTableName("test3tmp", __FILE__) + "(id integer not null, primary key (id))"));
+ tst_Databases::safeDropTables(db, QStringList() << qTableName("manytmp", __FILE__, db) << qTableName("test3tmp", __FILE__, db));
+ QVERIFY_SQL(q, exec("create table " + qTableName("manytmp", __FILE__, db) + "(id integer not null, name varchar(20), primary key (id))"));
+ QVERIFY_SQL(q, exec("create table " + qTableName("test3tmp", __FILE__, db) + "(id integer not null, primary key (id))"));
if (hasTransactions) QVERIFY_SQL(db, transaction());
- QVERIFY_SQL(q, exec("insert into " + qTableName("test", __FILE__) + " values(1, 'harry', 1)"));
- QVERIFY_SQL(q, exec("insert into " + qTableName("test", __FILE__) + " values(2, 'trond', 2)"));
- QVERIFY_SQL(q, exec("insert into " + qTableName("test2", __FILE__) + " values(1, 'herr')"));
- QVERIFY_SQL(q, exec("insert into " + qTableName("test2", __FILE__) + " values(2, 'mister')"));
+ QVERIFY_SQL(q, exec("insert into " + qTableName("test", __FILE__, db) + " values(1, 'harry', 1)"));
+ QVERIFY_SQL(q, exec("insert into " + qTableName("test", __FILE__, db) + " values(2, 'trond', 2)"));
+ QVERIFY_SQL(q, exec("insert into " + qTableName("test2", __FILE__, db) + " values(1, 'herr')"));
+ QVERIFY_SQL(q, exec("insert into " + qTableName("test2", __FILE__, db) + " values(2, 'mister')"));
- QVERIFY_SQL(q, exec(QString("insert into " + qTableName("test3", __FILE__) + " values(0)")));
- QVERIFY_SQL(q, prepare("insert into "+qTableName("test3", __FILE__)+"(id) select id + ? from "+qTableName("test3tmp", __FILE__)));
+ QVERIFY_SQL(q, exec(QString("insert into " + qTableName("test3", __FILE__, db) + " values(0)")));
+ QVERIFY_SQL(q, prepare("insert into "+ qTableName("test3", __FILE__, db) + "(id) select id + ? from " + qTableName("test3tmp", __FILE__, db)));
for (int i=1; i<260; i*=2) {
- q2.exec("delete from "+qTableName("test3tmp", __FILE__));
- QVERIFY_SQL(q2, exec("insert into "+qTableName("test3tmp", __FILE__)+"(id) select id from "+qTableName("test3", __FILE__)));
+ q2.exec("delete from " + qTableName("test3tmp", __FILE__, db));
+ QVERIFY_SQL(q2, exec("insert into " + qTableName("test3tmp", __FILE__, db) + "(id) select id from " + qTableName("test3", __FILE__, db)));
q.bindValue(0, i);
QVERIFY_SQL(q, exec());
}
- QVERIFY_SQL(q, exec(QString("insert into " + qTableName("many", __FILE__) + "(id, name) values (0, \'harry\')")));
- QVERIFY_SQL(q, prepare("insert into "+qTableName("many", __FILE__)+"(id, name) select id + ?, name from "+qTableName("manytmp", __FILE__)));
+ QVERIFY_SQL(q, exec(QString("insert into " + qTableName("many", __FILE__, db) + "(id, name) values (0, \'harry\')")));
+ QVERIFY_SQL(q, prepare("insert into " + qTableName("many", __FILE__, db) + "(id, name) select id + ?, name from " + qTableName("manytmp", __FILE__, db)));
for (int i=1; i < 2048; i*=2) {
- q2.exec("delete from "+qTableName("manytmp", __FILE__));
- QVERIFY_SQL(q2, exec("insert into "+qTableName("manytmp", __FILE__)+"(id, name) select id, name from "+qTableName("many", __FILE__)));
+ q2.exec("delete from " + qTableName("manytmp", __FILE__, db));
+ QVERIFY_SQL(q2, exec("insert into " + qTableName("manytmp", __FILE__, db) + "(id, name) select id, name from " + qTableName("many", __FILE__, db)));
q.bindValue(0, i);
QVERIFY_SQL(q, exec());
}
if (hasTransactions) QVERIFY_SQL(db, commit());
- tst_Databases::safeDropTables(db, QStringList() << qTableName("manytmp", __FILE__) << qTableName("test3tmp", __FILE__));
+ tst_Databases::safeDropTables(db, QStringList() << qTableName("manytmp", __FILE__, db) << qTableName("test3tmp", __FILE__, db));
}
void tst_QSqlQueryModel::generic_data(const QString& engine)
@@ -232,7 +232,7 @@ void tst_QSqlQueryModel::removeColumn()
CHECK_DATABASE(db);
DBTestModel model;
- model.setQuery(QSqlQuery("select * from " + qTableName("test", __FILE__), db));
+ model.setQuery(QSqlQuery("select * from " + qTableName("test", __FILE__, db), db));
model.fetchMore();
QSignalSpy spy(&model, SIGNAL(columnsAboutToBeRemoved(QModelIndex,int,int)));
@@ -314,7 +314,7 @@ void tst_QSqlQueryModel::insertColumn()
CHECK_DATABASE(db);
DBTestModel model;
- model.setQuery(QSqlQuery("select * from " + qTableName("test", __FILE__), db));
+ model.setQuery(QSqlQuery("select * from " + qTableName("test", __FILE__, db), db));
model.fetchMore(); // necessary???
bool isToUpper = db.driverName().startsWith("QIBASE") || db.driverName().startsWith("QOCI") || db.driverName().startsWith("QDB2");
@@ -417,7 +417,7 @@ void tst_QSqlQueryModel::record()
CHECK_DATABASE(db);
QSqlQueryModel model;
- model.setQuery(QSqlQuery("select * from " + qTableName("test", __FILE__), db));
+ model.setQuery(QSqlQuery("select * from " + qTableName("test", __FILE__, db), db));
QSqlRecord rec = model.record();
@@ -451,7 +451,7 @@ void tst_QSqlQueryModel::setHeaderData()
QVERIFY(!model.setHeaderData(5, Qt::Vertical, "foo"));
QVERIFY(model.headerData(5, Qt::Vertical).isValid());
- model.setQuery(QSqlQuery("select * from " + qTableName("test", __FILE__), db));
+ model.setQuery(QSqlQuery("select * from " + qTableName("test", __FILE__, db), db));
qRegisterMetaType<Qt::Orientation>("Qt::Orientation");
QSignalSpy spy(&model, SIGNAL(headerDataChanged(Qt::Orientation,int,int)));
@@ -482,7 +482,7 @@ void tst_QSqlQueryModel::fetchMore()
QSignalSpy modelAboutToBeResetSpy(&model, SIGNAL(modelAboutToBeReset()));
QSignalSpy modelResetSpy(&model, SIGNAL(modelReset()));
- model.setQuery(QSqlQuery("select * from " + qTableName("many", __FILE__), db));
+ model.setQuery(QSqlQuery("select * from " + qTableName("many", __FILE__, db), db));
int rowCount = model.rowCount();
QCOMPARE(modelAboutToBeResetSpy.count(), 1);
@@ -514,7 +514,7 @@ void tst_QSqlQueryModel::withSortFilterProxyModel()
QSKIP("Test applies only for drivers not reporting the query size.");
QSqlQueryModel model;
- model.setQuery(QSqlQuery("SELECT * FROM " + qTableName("test3", __FILE__), db));
+ model.setQuery(QSqlQuery("SELECT * FROM " + qTableName("test3", __FILE__, db), db));
QSortFilterProxyModel proxy;
proxy.setSourceModel(&model);
@@ -524,7 +524,7 @@ void tst_QSqlQueryModel::withSortFilterProxyModel()
QSignalSpy modelAboutToBeResetSpy(&model, SIGNAL(modelAboutToBeReset()));
QSignalSpy modelResetSpy(&model, SIGNAL(modelReset()));
QSignalSpy modelRowsInsertedSpy(&model, SIGNAL(rowsInserted(QModelIndex,int,int)));
- model.setQuery(QSqlQuery("SELECT * FROM " + qTableName("test3", __FILE__), db));
+ model.setQuery(QSqlQuery("SELECT * FROM " + qTableName("test3", __FILE__, db), db));
view.scrollToBottom();
QTestEventLoop::instance().enterLoop(1);
@@ -555,13 +555,13 @@ void tst_QSqlQueryModel::setQuerySignalEmission()
QSignalSpy modelResetSpy(&model, SIGNAL(modelReset()));
// First select, the model was empty and no rows had to be removed, but model resets anyway.
- model.setQuery(QSqlQuery("SELECT * FROM " + qTableName("test", __FILE__), db));
+ model.setQuery(QSqlQuery("SELECT * FROM " + qTableName("test", __FILE__, db), db));
QCOMPARE(modelAboutToBeResetSpy.count(), 1);
QCOMPARE(modelResetSpy.count(), 1);
// Second select, the model wasn't empty and two rows had to be removed!
// setQuery() resets the model accompanied by begin and end signals
- model.setQuery(QSqlQuery("SELECT * FROM " + qTableName("test", __FILE__), db));
+ model.setQuery(QSqlQuery("SELECT * FROM " + qTableName("test", __FILE__, db), db));
QCOMPARE(modelAboutToBeResetSpy.count(), 2);
QCOMPARE(modelResetSpy.count(), 2);
}
@@ -580,7 +580,7 @@ void tst_QSqlQueryModel::setQueryWithNoRowsInResultSet()
// The query's result set will be empty so no signals should be emitted!
QSqlQuery query(db);
- QVERIFY_SQL(query, exec("SELECT * FROM " + qTableName("test", __FILE__) + " where 0 = 1"));
+ QVERIFY_SQL(query, exec("SELECT * FROM " + qTableName("test", __FILE__, db) + " where 0 = 1"));
model.setQuery(query);
QCOMPARE(modelRowsAboutToBeInsertedSpy.count(), 0);
QCOMPARE(modelRowsInsertedSpy.count(), 0);
@@ -649,7 +649,7 @@ void tst_QSqlQueryModel::task_180617()
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString test3(qTableName("test3", __FILE__));
+ const QString test3(qTableName("test3", __FILE__, db));
QTableView view;
QCOMPARE(view.columnAt(0), -1);
diff --git a/tests/auto/sql/models/qsqlrelationaltablemodel/qsqlrelationaltablemodel.pro b/tests/auto/sql/models/qsqlrelationaltablemodel/qsqlrelationaltablemodel.pro
index 90f26730bf..0d7318a5c9 100644
--- a/tests/auto/sql/models/qsqlrelationaltablemodel/qsqlrelationaltablemodel.pro
+++ b/tests/auto/sql/models/qsqlrelationaltablemodel/qsqlrelationaltablemodel.pro
@@ -2,7 +2,7 @@ CONFIG += testcase
TARGET = tst_qsqlrelationaltablemodel
SOURCES += tst_qsqlrelationaltablemodel.cpp
-QT = core sql testlib
+QT = core sql testlib core-private sql-private
wince*: {
plugFiles.files = ../../../plugins/sqldrivers
@@ -16,4 +16,3 @@ wince*: {
LIBS += ws2_32.lib
}
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/sql/models/qsqlrelationaltablemodel/tst_qsqlrelationaltablemodel.cpp b/tests/auto/sql/models/qsqlrelationaltablemodel/tst_qsqlrelationaltablemodel.cpp
index 58ad995245..b218a0c4f7 100644
--- a/tests/auto/sql/models/qsqlrelationaltablemodel/tst_qsqlrelationaltablemodel.cpp
+++ b/tests/auto/sql/models/qsqlrelationaltablemodel/tst_qsqlrelationaltablemodel.cpp
@@ -45,11 +45,11 @@
#include "../../kernel/qsqldatabase/tst_databases.h"
-const QString reltest1(qTableName("reltest1", __FILE__)),
- reltest2(qTableName("reltest2", __FILE__)),
- reltest3(qTableName("reltest3", __FILE__)),
- reltest4(qTableName("reltest4", __FILE__)),
- reltest5(qTableName("reltest5", __FILE__));
+const QString reltest1(qTableName("reltest1", __FILE__, QSqlDatabase())),
+ reltest2(qTableName("reltest2", __FILE__, QSqlDatabase())),
+ reltest3(qTableName("reltest3", __FILE__, QSqlDatabase())),
+ reltest4(qTableName("reltest4", __FILE__, QSqlDatabase())),
+ reltest5(qTableName("reltest5", __FILE__, QSqlDatabase()));
class tst_QSqlRelationalTableModel : public QObject
{
@@ -134,13 +134,13 @@ void tst_QSqlRelationalTableModel::recreateTestTables(QSqlDatabase db)
QVERIFY_SQL( q, exec("insert into " + reltest5 + " values('mister', 'Mr')"));
if (testWhiteSpaceNames(db.driverName())) {
- QString reltest6 = db.driver()->escapeIdentifier(qTableName("rel", __FILE__)+" test6", QSqlDriver::TableName);
+ QString reltest6 = db.driver()->escapeIdentifier(qTableName("rel", __FILE__, db) + " test6", QSqlDriver::TableName);
QVERIFY_SQL( q, exec("create table " + reltest6 + " (id int not null primary key, " + db.driver()->escapeIdentifier("city key", QSqlDriver::FieldName) +
" int, " + db.driver()->escapeIdentifier("extra field", QSqlDriver::FieldName) + " int)"));
QVERIFY_SQL( q, exec("insert into " + reltest6 + " values(1, 1,9)"));
QVERIFY_SQL( q, exec("insert into " + reltest6 + " values(2, 2,8)"));
- QString reltest7 = db.driver()->escapeIdentifier(qTableName("rel", __FILE__)+" test7", QSqlDriver::TableName);
+ QString reltest7 = db.driver()->escapeIdentifier(qTableName("rel", __FILE__, db) + " test7", QSqlDriver::TableName);
QVERIFY_SQL( q, exec("create table " + reltest7 + " (" + db.driver()->escapeIdentifier("city id", QSqlDriver::TableName) + " int not null primary key, " + db.driver()->escapeIdentifier("city name", QSqlDriver::FieldName) + " varchar(20))"));
QVERIFY_SQL( q, exec("insert into " + reltest7 + " values(1, 'New York')"));
QVERIFY_SQL( q, exec("insert into " + reltest7 + " values(2, 'Washington')"));
@@ -181,14 +181,14 @@ void tst_QSqlRelationalTableModel::dropTestTables( QSqlDatabase db )
<< reltest3
<< reltest4
<< reltest5
- << (qTableName( "rel", __FILE__)+" test6")
- << (qTableName( "rel", __FILE__)+" test7")
- << qTableName("CASETEST1", db.driver() )
- << qTableName("casetest1", db.driver() );
+ << (qTableName("rel", __FILE__, db) + " test6")
+ << (qTableName( "rel", __FILE__, db) + " test7")
+ << qTableName("CASETEST1", db)
+ << qTableName("casetest1", db);
tst_Databases::safeDropTables( db, tableNames );
- db.exec("DROP SCHEMA "+qTableName("QTBUG_5373", __FILE__)+" CASCADE");
- db.exec("DROP SCHEMA "+qTableName("QTBUG_5373_s2", __FILE__)+" CASCADE");
+ db.exec("DROP SCHEMA " + qTableName("QTBUG_5373", __FILE__, db) + " CASCADE");
+ db.exec("DROP SCHEMA " + qTableName("QTBUG_5373_s2", __FILE__, db) + " CASCADE");
}
void tst_QSqlRelationalTableModel::init()
@@ -1095,54 +1095,54 @@ void tst_QSqlRelationalTableModel::casing()
QSKIP("The casing test for this database is irrelevant since this database does not treat different cases as separate entities");
QSqlQuery q(db);
- QVERIFY_SQL( q, exec("create table " + qTableName("CASETEST1", db.driver()).toUpper() +
+ QVERIFY_SQL( q, exec("create table " + qTableName("CASETEST1", db).toUpper() +
" (id int not null primary key, name varchar(20), title_key int, another_title_key int)"));
- if( !q.exec("create table " + qTableName("casetest1", db.driver()) +
+ if (!q.exec("create table " + qTableName("casetest1", db) +
" (ident int not null primary key, name varchar(20), title_key int)"))
QSKIP("The casing test for this database is irrelevant since this database does not treat different cases as separate entities");
- QVERIFY_SQL( q, exec("insert into " + qTableName("CASETEST1", db.driver()).toUpper() + " values(1, 'harry', 1, 2)"));
- QVERIFY_SQL( q, exec("insert into " + qTableName("CASETEST1", db.driver()).toUpper() + " values(2, 'trond', 2, 1)"));
- QVERIFY_SQL( q, exec("insert into " + qTableName("CASETEST1", db.driver()).toUpper() + " values(3, 'vohi', 1, 2)"));
- QVERIFY_SQL( q, exec("insert into " + qTableName("CASETEST1", db.driver()).toUpper() + " values(4, 'boris', 2, 2)"));
- QVERIFY_SQL( q, exec("insert into " + qTableName("casetest1", db.driver()) + " values(1, 'jerry', 1)"));
- QVERIFY_SQL( q, exec("insert into " + qTableName("casetest1", db.driver()) + " values(2, 'george', 2)"));
- QVERIFY_SQL( q, exec("insert into " + qTableName("casetest1", db.driver()) + " values(4, 'kramer', 2)"));
+ QVERIFY_SQL( q, exec("insert into " + qTableName("CASETEST1", db).toUpper() + " values(1, 'harry', 1, 2)"));
+ QVERIFY_SQL( q, exec("insert into " + qTableName("CASETEST1", db).toUpper() + " values(2, 'trond', 2, 1)"));
+ QVERIFY_SQL( q, exec("insert into " + qTableName("CASETEST1", db).toUpper() + " values(3, 'vohi', 1, 2)"));
+ QVERIFY_SQL( q, exec("insert into " + qTableName("CASETEST1", db).toUpper() + " values(4, 'boris', 2, 2)"));
+ QVERIFY_SQL( q, exec("insert into " + qTableName("casetest1", db) + " values(1, 'jerry', 1)"));
+ QVERIFY_SQL( q, exec("insert into " + qTableName("casetest1", db) + " values(2, 'george', 2)"));
+ QVERIFY_SQL( q, exec("insert into " + qTableName("casetest1", db) + " values(4, 'kramer', 2)"));
if (db.driverName().startsWith("QOCI")) {
//try an owner that doesn't exist
- QSqlRecord rec = db.driver()->record("doug." + qTableName("CASETEST1", db.driver()).toUpper());
+ QSqlRecord rec = db.driver()->record("doug." + qTableName("CASETEST1", db).toUpper());
QCOMPARE( rec.count(), 0);
//try an owner that does exist
- rec = db.driver()->record(db.userName() + "." + qTableName("CASETEST1", db.driver()).toUpper());
+ rec = db.driver()->record(db.userName() + "." + qTableName("CASETEST1", db).toUpper());
QCOMPARE( rec.count(), 4);
}
- QSqlRecord rec = db.driver()->record(qTableName("CASETEST1", db.driver()).toUpper());
+ QSqlRecord rec = db.driver()->record(qTableName("CASETEST1", db).toUpper());
QCOMPARE( rec.count(), 4);
- rec = db.driver()->record(qTableName("casetest1", db.driver()));
+ rec = db.driver()->record(qTableName("casetest1", db));
QCOMPARE( rec.count(), 3);
QSqlTableModel upperCaseModel(0, db);
- upperCaseModel.setTable(qTableName("CASETEST1", db.driver()).toUpper());
+ upperCaseModel.setTable(qTableName("CASETEST1", db).toUpper());
- QCOMPARE(upperCaseModel.tableName(),qTableName("CASETEST1",db.driver()).toUpper());
+ QCOMPARE(upperCaseModel.tableName(), qTableName("CASETEST1", db).toUpper());
QVERIFY_SQL(upperCaseModel, select());
QCOMPARE(upperCaseModel.rowCount(), 4);
QSqlTableModel lowerCaseModel(0, db);
- lowerCaseModel.setTable(qTableName("casetest1", db.driver()));
- QCOMPARE(lowerCaseModel.tableName(), qTableName("casetest1",db.driver()));
+ lowerCaseModel.setTable(qTableName("casetest1", db));
+ QCOMPARE(lowerCaseModel.tableName(), qTableName("casetest1", db));
QVERIFY_SQL(lowerCaseModel, select());
QCOMPARE(lowerCaseModel.rowCount(), 3);
QSqlRelationalTableModel model(0, db);
- model.setTable(qTableName("CASETEST1", db.driver()).toUpper());
+ model.setTable(qTableName("CASETEST1", db).toUpper());
model.setRelation(2, QSqlRelation(reltest2, "tid", "title"));
QVERIFY_SQL(model, select());
@@ -1372,9 +1372,9 @@ void tst_QSqlRelationalTableModel::whiteSpaceInIdentifiers()
if (!testWhiteSpaceNames(db.driverName()))
QSKIP("White space test irrelevant for driver");
QSqlRelationalTableModel model(0, db);
- model.setTable(db.driver()->escapeIdentifier(qTableName("rel", __FILE__)+" test6", QSqlDriver::TableName));
+ model.setTable(db.driver()->escapeIdentifier(qTableName("rel", __FILE__, db) + " test6", QSqlDriver::TableName));
model.setSort(0, Qt::DescendingOrder);
- model.setRelation(1, QSqlRelation(db.driver()->escapeIdentifier(qTableName("rel", __FILE__)+" test7", QSqlDriver::TableName),
+ model.setRelation(1, QSqlRelation(db.driver()->escapeIdentifier(qTableName("rel", __FILE__, db) + " test7", QSqlDriver::TableName),
db.driver()->escapeIdentifier("city id", QSqlDriver::FieldName),
db.driver()->escapeIdentifier("city name", QSqlDriver::FieldName)));
QVERIFY_SQL(model, select());
@@ -1459,13 +1459,15 @@ void tst_QSqlRelationalTableModel::psqlSchemaTest()
QSqlRelationalTableModel model(0, db);
QSqlQuery q(db);
- QVERIFY_SQL(q, exec("create schema "+qTableName("QTBUG_5373", __FILE__)));
- QVERIFY_SQL(q, exec("create schema "+qTableName("QTBUG_5373_s2", __FILE__)));
- QVERIFY_SQL(q, exec("create table "+qTableName("QTBUG_5373", __FILE__)+"."+qTableName("document", __FILE__)+"(document_id int primary key, relatingid int, userid int)"));
- QVERIFY_SQL(q, exec("create table "+qTableName("QTBUG_5373_s2", __FILE__)+"."+qTableName("user", __FILE__)+"(userid int primary key, username char(40))"));
- model.setTable(qTableName("QTBUG_5373", __FILE__)+"."+qTableName("document", __FILE__));
- model.setRelation(1, QSqlRelation(qTableName("QTBUG_5373_s2", __FILE__)+"."+qTableName("user", __FILE__), "userid", "username"));
- model.setRelation(2, QSqlRelation(qTableName("QTBUG_5373_s2", __FILE__)+"."+qTableName("user", __FILE__), "userid", "username"));
+ QVERIFY_SQL(q, exec("create schema " + qTableName("QTBUG_5373", __FILE__, db)));
+ QVERIFY_SQL(q, exec("create schema " + qTableName("QTBUG_5373_s2", __FILE__, db)));
+ QVERIFY_SQL(q, exec("create table " + qTableName("QTBUG_5373", __FILE__, db) + "." + qTableName("document", __FILE__, db) +
+ "(document_id int primary key, relatingid int, userid int)"));
+ QVERIFY_SQL(q, exec("create table " + qTableName("QTBUG_5373_s2", __FILE__, db) + "." + qTableName("user", __FILE__, db) +
+ "(userid int primary key, username char(40))"));
+ model.setTable(qTableName("QTBUG_5373", __FILE__, db) + "." + qTableName("document", __FILE__, db));
+ model.setRelation(1, QSqlRelation(qTableName("QTBUG_5373_s2", __FILE__, db) + "." + qTableName("user", __FILE__, db), "userid", "username"));
+ model.setRelation(2, QSqlRelation(qTableName("QTBUG_5373_s2", __FILE__, db) + "." + qTableName("user", __FILE__, db), "userid", "username"));
QVERIFY_SQL(model, select());
model.setJoinMode(QSqlRelationalTableModel::LeftJoin);
@@ -1503,8 +1505,8 @@ void tst_QSqlRelationalTableModel::relationOnFirstColumn()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- QString testTable1 = qTableName("QTBUG_20038_test1", __FILE__);
- QString testTable2 = qTableName("QTBUG_20038_test2", __FILE__);
+ QString testTable1 = qTableName("QTBUG_20038_test1", __FILE__, db);
+ QString testTable2 = qTableName("QTBUG_20038_test2", __FILE__, db);
tst_Databases::safeDropTables(db, QStringList() << testTable1 << testTable2);
//prepare test1 table
diff --git a/tests/auto/sql/models/qsqltablemodel/qsqltablemodel.pro b/tests/auto/sql/models/qsqltablemodel/qsqltablemodel.pro
index 3ad44d61ef..e7d01afb40 100644
--- a/tests/auto/sql/models/qsqltablemodel/qsqltablemodel.pro
+++ b/tests/auto/sql/models/qsqltablemodel/qsqltablemodel.pro
@@ -13,4 +13,3 @@ wince*: {
win32:LIBS += -lws2_32
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/sql/models/qsqltablemodel/tst_qsqltablemodel.cpp b/tests/auto/sql/models/qsqltablemodel/tst_qsqltablemodel.cpp
index df89ba3cf8..771c224963 100644
--- a/tests/auto/sql/models/qsqltablemodel/tst_qsqltablemodel.cpp
+++ b/tests/auto/sql/models/qsqltablemodel/tst_qsqltablemodel.cpp
@@ -45,9 +45,9 @@
#include <QtSql>
#include <QtSql/private/qsqltablemodel_p.h>
-const QString test(qTableName("test", __FILE__)),
- test2(qTableName("test2", __FILE__)),
- test3(qTableName("test3", __FILE__));
+const QString test(qTableName("test", __FILE__, QSqlDatabase())),
+ test2(qTableName("test2", __FILE__, QSqlDatabase())),
+ test3(qTableName("test3", __FILE__, QSqlDatabase()));
class tst_QSqlTableModel : public QObject
@@ -176,18 +176,18 @@ void tst_QSqlTableModel::dropTestTables()
tableNames << test
<< test2
<< test3
- << qTableName("test4", __FILE__)
- << qTableName("emptytable", __FILE__)
- << qTableName("bigtable", __FILE__)
- << qTableName("foo", __FILE__)
- << qTableName("pktest", __FILE__);
+ << qTableName("test4", __FILE__, db)
+ << qTableName("emptytable", __FILE__, db)
+ << qTableName("bigtable", __FILE__, db)
+ << qTableName("foo", __FILE__, db)
+ << qTableName("pktest", __FILE__, db);
if (testWhiteSpaceNames(db.driverName()))
- tableNames << qTableName("qtestw hitespace", db.driver());
+ tableNames << qTableName("qtestw hitespace", db);
tst_Databases::safeDropTables(db, tableNames);
if (db.driverName().startsWith("QPSQL")) {
- q.exec("DROP SCHEMA " + qTableName("testschema", __FILE__) + " CASCADE");
+ q.exec("DROP SCHEMA " + qTableName("testschema", __FILE__, db) + " CASCADE");
}
}
}
@@ -205,19 +205,19 @@ void tst_QSqlTableModel::createTestTables()
QVERIFY_SQL( q, exec("create table " + test3 + "(id int, random varchar(20), randomtwo varchar(20))"));
if(!tst_Databases::isSqlServer(db))
- QVERIFY_SQL( q, exec("create table " + qTableName("test4", __FILE__) + "(column1 varchar(50), column2 varchar(50), column3 varchar(50))"));
+ QVERIFY_SQL(q, exec("create table " + qTableName("test4", __FILE__, db) + "(column1 varchar(50), column2 varchar(50), column3 varchar(50))"));
else
- QVERIFY_SQL( q, exec("create table " + qTableName("test4", __FILE__) + "(column1 varchar(50), column2 varchar(50) NULL, column3 varchar(50))"));
+ QVERIFY_SQL(q, exec("create table " + qTableName("test4", __FILE__, db) + "(column1 varchar(50), column2 varchar(50) NULL, column3 varchar(50))"));
- QVERIFY_SQL( q, exec("create table " + qTableName("emptytable", __FILE__) + "(id int)"));
+ QVERIFY_SQL(q, exec("create table " + qTableName("emptytable", __FILE__, db) + "(id int)"));
if (testWhiteSpaceNames(db.driverName())) {
- QString qry = "create table " + qTableName("qtestw hitespace", db.driver()) + " ("+ db.driver()->escapeIdentifier("a field", QSqlDriver::FieldName) + " int)";
+ QString qry = "create table " + qTableName("qtestw hitespace", db) + " ("+ db.driver()->escapeIdentifier("a field", QSqlDriver::FieldName) + " int)";
QVERIFY_SQL( q, exec(qry));
}
- QVERIFY_SQL( q, exec("create table "+qTableName("pktest", __FILE__)+"(id int not null primary key, a varchar(20))"));
+ QVERIFY_SQL(q, exec("create table " + qTableName("pktest", __FILE__, db) + "(id int not null primary key, a varchar(20))"));
}
}
@@ -343,7 +343,7 @@ void tst_QSqlTableModel::selectRow()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- QString tbl = qTableName("pktest", __FILE__);
+ QString tbl = qTableName("pktest", __FILE__, db);
QSqlQuery q(db);
q.exec("DELETE FROM " + tbl);
q.exec("INSERT INTO " + tbl + " (id, a) VALUES (0, 'a')");
@@ -403,7 +403,7 @@ void tst_QSqlTableModel::selectRowOverride()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- QString tbl = qTableName("pktest", __FILE__);
+ QString tbl = qTableName("pktest", __FILE__, db);
QSqlQuery q(db);
q.exec("DELETE FROM " + tbl);
q.exec("INSERT INTO " + tbl + " (id, a) VALUES (0, 'a')");
@@ -827,7 +827,7 @@ void tst_QSqlTableModel::insertRowFailure()
CHECK_DATABASE(db);
QSqlTableModel model(0, db);
- model.setTable(qTableName("pktest", __FILE__));
+ model.setTable(qTableName("pktest", __FILE__, db));
model.setEditStrategy(submitpolicy);
QSqlRecord values = model.record();
@@ -975,7 +975,7 @@ void tst_QSqlTableModel::insertWithAutoColumn()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- QString tbl = qTableName("autoColumnTest", __FILE__);
+ QString tbl = qTableName("autoColumnTest", __FILE__, db);
QSqlQuery q(db);
q.exec("DROP TABLE " + tbl);
QVERIFY_SQL(q, exec("CREATE TABLE " + tbl + "(id INTEGER PRIMARY KEY AUTOINCREMENT, val TEXT)"));
@@ -1378,8 +1378,8 @@ void tst_QSqlTableModel::revert()
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- QString tblA = qTableName("revertATest", __FILE__);
- QString tblB = qTableName("revertBTest", __FILE__);
+ QString tblA = qTableName("revertATest", __FILE__, db);
+ QString tblB = qTableName("revertBTest", __FILE__, db);
QSqlQuery q(db);
q.exec("PRAGMA foreign_keys = ON;");
q.exec("DROP TABLE " + tblB);
@@ -1646,7 +1646,7 @@ void tst_QSqlTableModel::emptyTable()
QCOMPARE(model.rowCount(), 0);
QCOMPARE(model.columnCount(), 0);
- model.setTable(qTableName("emptytable", __FILE__));
+ model.setTable(qTableName("emptytable", __FILE__, db));
QCOMPARE(model.rowCount(), 0);
QCOMPARE(model.columnCount(), 1);
@@ -1670,9 +1670,9 @@ void tst_QSqlTableModel::tablesAndSchemas()
CHECK_DATABASE(db);
QSqlQuery q(db);
- q.exec("DROP SCHEMA " + qTableName("testschema", __FILE__) + " CASCADE");
- QVERIFY_SQL( q, exec("create schema " + qTableName("testschema", __FILE__)));
- QString tableName = qTableName("testschema", __FILE__) + '.' + qTableName("testtable", __FILE__);
+ q.exec("DROP SCHEMA " + qTableName("testschema", __FILE__, db) + " CASCADE");
+ QVERIFY_SQL( q, exec("create schema " + qTableName("testschema", __FILE__, db)));
+ QString tableName = qTableName("testschema", __FILE__, db) + '.' + qTableName("testtable", __FILE__, db);
QVERIFY_SQL( q, exec("create table " + tableName + "(id int)"));
QVERIFY_SQL( q, exec("insert into " + tableName + " values(1)"));
QVERIFY_SQL( q, exec("insert into " + tableName + " values(2)"));
@@ -1693,7 +1693,7 @@ void tst_QSqlTableModel::whitespaceInIdentifiers()
if (!testWhiteSpaceNames(db.driverName()))
QSKIP("DBMS doesn't support whitespaces in identifiers");
- QString tableName = qTableName("qtestw hitespace", db.driver());
+ QString tableName = qTableName("qtestw hitespace", db);
QSqlTableModel model(0, db);
model.setTable(tableName);
@@ -1711,10 +1711,10 @@ void tst_QSqlTableModel::primaryKeyOrder()
if(tst_Databases::isPostgreSQL(db))
QVERIFY_SQL( q, exec("set client_min_messages='warning'"));
- QVERIFY_SQL( q, exec("create table "+qTableName("foo", __FILE__)+"(a varchar(20), id int not null primary key, b varchar(20))"));
+ QVERIFY_SQL(q, exec("create table " + qTableName("foo", __FILE__, db) + "(a varchar(20), id int not null primary key, b varchar(20))"));
QSqlTableModel model(0, db);
- model.setTable(qTableName("foo", __FILE__));
+ model.setTable(qTableName("foo", __FILE__, db));
QSqlIndex pk = model.primaryKey();
QCOMPARE(pk.count(), 1);
@@ -1783,7 +1783,7 @@ void tst_QSqlTableModel::sqlite_bigTable()
QFETCH(QString, dbName);
QSqlDatabase db = QSqlDatabase::database(dbName);
CHECK_DATABASE(db);
- const QString bigtable(qTableName("bigtable", __FILE__));
+ const QString bigtable(qTableName("bigtable", __FILE__, db));
bool hasTransactions = db.driver()->hasFeature(QSqlDriver::Transactions);
if (hasTransactions) QVERIFY(db.transaction());
@@ -1865,7 +1865,7 @@ void tst_QSqlTableModel::submitAllOnInvalidTable()
// setTable returns a void, so the error can only be caught by
// manually checking lastError(). ### Qt5: This should be changed!
- model.setTable(qTableName("invalidTable", __FILE__));
+ model.setTable(qTableName("invalidTable", __FILE__, db));
QCOMPARE(model.lastError().type(), QSqlError::StatementError);
// This will give us an empty record which is expected behavior
@@ -1975,7 +1975,7 @@ void tst_QSqlTableModel::tableModifyWithBlank()
CHECK_DATABASE(db);
QSqlTableModel model(0, db);
- model.setTable(qTableName("test4", __FILE__));
+ model.setTable(qTableName("test4", __FILE__, db));
model.select();
//generate a time stamp for the test. Add one second to the current time to make sure
diff --git a/tests/auto/test.pl b/tests/auto/test.pl
index 568dbeec54..72b7e6aa17 100755
--- a/tests/auto/test.pl
+++ b/tests/auto/test.pl
@@ -42,6 +42,7 @@
use strict;
use Cwd;
+use warnings;
# Usage: test.pl <SearchPath> <ExecutionMode> <TestResults> <Timeout [Default 300 seconds]>
# Variable declarations to keep strict happy
@@ -56,8 +57,8 @@ our $timeoutChildren;
our $totalExecuted;
our $totalStarted;
our $totalTimedOut;
-our $next;
our $currentDirectory;
+our $testRoot;
# Where do we run this script? What directory?
$SEARCH_PATH=$ARGV[0];
@@ -67,7 +68,7 @@ if(!$SEARCH_PATH)
exit(0);
}
-# We have four options:
+# We have four options:
# 'U': Unix
# 'W': Windows
# 'M': Mac
@@ -86,8 +87,8 @@ if($EXEC_MODE =~ /^U$/)
} elsif($EXEC_MODE =~ /^M$/)
{
print "Using OSX execution mode\n";
- $EXE_PREFIX="/Content/MacOS/";
- $EXE_SUFFIX="";
+ $EXE_PREFIX="/Contents/MacOS/";
+ $EXE_SUFFIX=".app";
} elsif($EXEC_MODE =~ /^E$/)
{
print "Using embedded execution mode\n";
@@ -101,24 +102,18 @@ if($EXEC_MODE =~ /^U$/)
# We get the current directory, we 'll need it afterwards
$currentDirectory = getcwd();
+$testRoot = Cwd::abs_path($SEARCH_PATH);
+
# We assume that by default goes to "reports" unless the user specifies it.
$REPORTDIR = $ARGV[2];
if(!$REPORTDIR)
{
- if($SEARCH_PATH =~ /^\.$/)
- {
-# '.' ie current directory
- $REPORTDIR = $currentDirectory."/reports";
- } elsif($SEARCH_PATH =~ /^\//) {
-# Absolute path
- $REPORTDIR = $SEARCH_PATH."/reports";
- } else {
-# Relative path
- $REPORTDIR = $currentDirectory.$SEARCH_PATH."/reports";
- }
+ $REPORTDIR = $testRoot."/reports";
+ mkdir $REPORTDIR;
+} else {
+ mkdir $REPORTDIR;
+ $REPORTDIR = Cwd::abs_path($REPORTDIR);
}
-# Let's create the directory
-mkdir $REPORTDIR;
# If given we use it, otherwise we default to 300 seconds.
$TIMEOUT = $ARGV[3];
@@ -139,23 +134,51 @@ $totalTimedOut = 0;
$SIG{'CHLD'} = 'handleDeath';
$SIG{'ALRM'} = 'handleTimeout';
-while ($next = <$SEARCH_PATH/*>)
-{
- if( -d $next )
+handleDir($testRoot);
+
+print " ** Statistics ** \n";
+print " Tests started: $totalStarted \n";
+print " Tests executed: $totalExecuted \n";
+print " Tests timed out: $totalTimedOut \n";
+
+sub handleDir {
+
+ my ($dir) = @_;
+ my $currentDir = getcwd();
+
+ chdir($dir) || die("Could not chdir to $dir");
+ my @components;
+ my $command;
+ @components = split(/\//, $dir);
+ my $component = $components[$#components];
+
+ $command = "tst_".$component;
+
+ if ( -e $command.$EXE_SUFFIX )
{
- print "Examining $next \n";
- chdir($next) || die("Could not chdir to $next");
- my @components;
- my $command;
- @components = split(/\//, $next);
- if($EXEC_MODE =~ /^M$/)
+ executeTestCurrentDir($command);
+ } else {
+ opendir(DIR, $dir);
+ my @files = readdir(DIR);
+ closedir DIR;
+ my $file;
+ foreach $file (@files)
{
- $command = "tst_".$components[1].".app";
- } else {
- $command = "tst_".$components[1];
+ #skip hidden files
+ next if (substr($file,0,1) eq ".");
+
+ if ( -d $dir."/".$file)
+ {
+ handleDir($dir."/".$file)
+ }
+
}
- if( -e $command)
- {
+ }
+ chdir($currentDir);
+}
+
+sub executeTestCurrentDir {
+ my ($command) = @_;
print "Executing $command \n";
my $myPid;
$myPid = fork();
@@ -164,11 +187,12 @@ while ($next = <$SEARCH_PATH/*>)
my $realCommand;
if($EXEC_MODE =~/^M$/)
{
- $realCommand = "./".$command.".app".$EXE_PREFIX.$command;
+ $realCommand = "./".$command.$EXE_SUFFIX.$EXE_PREFIX.$command;
} else {
$realCommand = $EXE_PREFIX.$command.$EXE_SUFFIX;
}
- my $outputRedirection = $REPORTDIR."/".$command.".xml";
+ my $outputRedirection = $REPORTDIR."/".$command.$EXE_SUFFIX.".xml";
+
if($EXEC_MODE =~ /^E$/)
{
exec($realCommand, "-qws", "-xml", "-o", $outputRedirection);
@@ -210,15 +234,8 @@ while ($next = <$SEARCH_PATH/*>)
} else {
print "Problems trying to execute $command";
}
- }
- }
- chdir($currentDirectory);
}
-print " ** Statistics ** \n";
-print " Tests started: $totalStarted \n";
-print " Tests executed: $totalExecuted \n";
-print " Tests timed out: $totalTimedOut \n";
# This procedure takes care of handling dead children on due time
sub handleDeath {
diff --git a/tests/auto/testlib/qsignalspy/qsignalspy.pro b/tests/auto/testlib/qsignalspy/qsignalspy.pro
index cdeac8c41c..72ae3a5009 100644
--- a/tests/auto/testlib/qsignalspy/qsignalspy.pro
+++ b/tests/auto/testlib/qsignalspy/qsignalspy.pro
@@ -3,4 +3,3 @@ TARGET = tst_qsignalspy
SOURCES += tst_qsignalspy.cpp
QT = core testlib
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/alive/alive.pro b/tests/auto/testlib/selftests/alive/alive.pro
index f4c18d54fa..d3df09b10d 100644
--- a/tests/auto/testlib/selftests/alive/alive.pro
+++ b/tests/auto/testlib/selftests/alive/alive.pro
@@ -6,4 +6,3 @@ CONFIG -= debug_and_release_target
TARGET = alive
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/assert/assert.pro b/tests/auto/testlib/selftests/assert/assert.pro
index 0930724059..cfc6a0c6b3 100644
--- a/tests/auto/testlib/selftests/assert/assert.pro
+++ b/tests/auto/testlib/selftests/assert/assert.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = assert
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/badxml/badxml.pro b/tests/auto/testlib/selftests/badxml/badxml.pro
index 6c5e6320f8..7b3b0f701c 100644
--- a/tests/auto/testlib/selftests/badxml/badxml.pro
+++ b/tests/auto/testlib/selftests/badxml/badxml.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = badxml
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/benchlibcallgrind/benchlibcallgrind.pro b/tests/auto/testlib/selftests/benchlibcallgrind/benchlibcallgrind.pro
index f0cfecd4ff..6cbefe518c 100644
--- a/tests/auto/testlib/selftests/benchlibcallgrind/benchlibcallgrind.pro
+++ b/tests/auto/testlib/selftests/benchlibcallgrind/benchlibcallgrind.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = benchlibcallgrind
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/benchlibcounting/benchlibcounting.pro b/tests/auto/testlib/selftests/benchlibcounting/benchlibcounting.pro
index d3c841f0d5..b495995eac 100644
--- a/tests/auto/testlib/selftests/benchlibcounting/benchlibcounting.pro
+++ b/tests/auto/testlib/selftests/benchlibcounting/benchlibcounting.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = benchlibcounting
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/benchlibeventcounter/benchlibeventcounter.pro b/tests/auto/testlib/selftests/benchlibeventcounter/benchlibeventcounter.pro
index 5c38140bc4..5e2b963491 100644
--- a/tests/auto/testlib/selftests/benchlibeventcounter/benchlibeventcounter.pro
+++ b/tests/auto/testlib/selftests/benchlibeventcounter/benchlibeventcounter.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = benchlibeventcounter
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/benchliboptions/benchliboptions.pro b/tests/auto/testlib/selftests/benchliboptions/benchliboptions.pro
index 77dcf853e9..f4bcc92129 100644
--- a/tests/auto/testlib/selftests/benchliboptions/benchliboptions.pro
+++ b/tests/auto/testlib/selftests/benchliboptions/benchliboptions.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = benchliboptions
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/benchlibtickcounter/benchlibtickcounter.pro b/tests/auto/testlib/selftests/benchlibtickcounter/benchlibtickcounter.pro
index 5763b8dc32..ce0ec7012c 100644
--- a/tests/auto/testlib/selftests/benchlibtickcounter/benchlibtickcounter.pro
+++ b/tests/auto/testlib/selftests/benchlibtickcounter/benchlibtickcounter.pro
@@ -6,4 +6,3 @@ CONFIG -= debug_and_release_target
TARGET = benchlibtickcounter
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/benchlibwalltime/benchlibwalltime.pro b/tests/auto/testlib/selftests/benchlibwalltime/benchlibwalltime.pro
index 2faa7585ac..0e689871ab 100644
--- a/tests/auto/testlib/selftests/benchlibwalltime/benchlibwalltime.pro
+++ b/tests/auto/testlib/selftests/benchlibwalltime/benchlibwalltime.pro
@@ -6,4 +6,3 @@ CONFIG -= debug_and_release_target
TARGET = benchlibwalltime
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/cmptest/cmptest.pro b/tests/auto/testlib/selftests/cmptest/cmptest.pro
index e8e467dc8a..a793c203dd 100644
--- a/tests/auto/testlib/selftests/cmptest/cmptest.pro
+++ b/tests/auto/testlib/selftests/cmptest/cmptest.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = cmptest
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp b/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp
index 6506479d1d..e9ad1778fa 100644
--- a/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp
+++ b/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp
@@ -136,6 +136,8 @@ private slots:
void compare_tostring_data();
void compareQStringLists();
void compareQStringLists_data();
+ void compareQListInt();
+ void compareQListDouble();
void compareQPixmaps();
void compareQPixmaps_data();
void compareQImages();
@@ -307,6 +309,20 @@ void tst_Cmptest::compareQStringLists()
QCOMPARE(opA, opB);
}
+void tst_Cmptest::compareQListInt()
+{
+ QList<int> int1; int1 << 1 << 2 << 3;
+ QList<int> int2; int2 << 1 << 2 << 4;
+ QCOMPARE(int1, int2);
+}
+
+void tst_Cmptest::compareQListDouble()
+{
+ QList<double> double1; double1 << 1.5 << 2 << 3;
+ QList<double> double2; double2 << 1 << 2 << 4;
+ QCOMPARE(double1, double2);
+}
+
void tst_Cmptest::compareQPixmaps_data()
{
QTest::addColumn<QPixmap>("opA");
diff --git a/tests/auto/testlib/selftests/commandlinedata/commandlinedata.pro b/tests/auto/testlib/selftests/commandlinedata/commandlinedata.pro
index d1ed7143a6..056388333a 100644
--- a/tests/auto/testlib/selftests/commandlinedata/commandlinedata.pro
+++ b/tests/auto/testlib/selftests/commandlinedata/commandlinedata.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = commandlinedata
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/counting/counting.pro b/tests/auto/testlib/selftests/counting/counting.pro
index e9c53ed3b4..8aa2fe5753 100644
--- a/tests/auto/testlib/selftests/counting/counting.pro
+++ b/tests/auto/testlib/selftests/counting/counting.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = counting
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/crashes/crashes.pro b/tests/auto/testlib/selftests/crashes/crashes.pro
index 80b438fb5e..25e24243d1 100644
--- a/tests/auto/testlib/selftests/crashes/crashes.pro
+++ b/tests/auto/testlib/selftests/crashes/crashes.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = crashes
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/datatable/datatable.pro b/tests/auto/testlib/selftests/datatable/datatable.pro
index 2b8e368497..72fa851ae6 100644
--- a/tests/auto/testlib/selftests/datatable/datatable.pro
+++ b/tests/auto/testlib/selftests/datatable/datatable.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = datatable
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/datetime/datetime.pro b/tests/auto/testlib/selftests/datetime/datetime.pro
index 94d34bfcad..d65c59354f 100644
--- a/tests/auto/testlib/selftests/datetime/datetime.pro
+++ b/tests/auto/testlib/selftests/datetime/datetime.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = datetime
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/datetime/tst_datetime.cpp b/tests/auto/testlib/selftests/datetime/tst_datetime.cpp
index 25e50df72a..39ba9f5908 100644
--- a/tests/auto/testlib/selftests/datetime/tst_datetime.cpp
+++ b/tests/auto/testlib/selftests/datetime/tst_datetime.cpp
@@ -69,7 +69,7 @@ void tst_DateTime::qurl() const
{
QFETCH(QUrl, operandA);
QFETCH(QUrl, operandB);
-
+
QCOMPARE(operandA, operandB);
}
diff --git a/tests/auto/testlib/selftests/differentexec/differentexec.pro b/tests/auto/testlib/selftests/differentexec/differentexec.pro
index ba7fc5bedd..7f148ba996 100644
--- a/tests/auto/testlib/selftests/differentexec/differentexec.pro
+++ b/tests/auto/testlib/selftests/differentexec/differentexec.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = differentexec
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/exceptionthrow/exceptionthrow.pro b/tests/auto/testlib/selftests/exceptionthrow/exceptionthrow.pro
index 76000ce7db..fe89f6f3cd 100644
--- a/tests/auto/testlib/selftests/exceptionthrow/exceptionthrow.pro
+++ b/tests/auto/testlib/selftests/exceptionthrow/exceptionthrow.pro
@@ -6,4 +6,3 @@ CONFIG -= debug_and_release_target
CONFIG += exceptions
TARGET = exceptionthrow
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/expected_cmptest.lightxml b/tests/auto/testlib/selftests/expected_cmptest.lightxml
index 83b2e6e137..54c5bb85f0 100644
--- a/tests/auto/testlib/selftests/expected_cmptest.lightxml
+++ b/tests/auto/testlib/selftests/expected_cmptest.lightxml
@@ -49,35 +49,49 @@
</Incident>
<Incident type="fail" file="/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp" line="308">
<DataTag><![CDATA[last item different]]></DataTag>
- <Description><![CDATA[Compared QStringLists differ at index 2.
+ <Description><![CDATA[Compared lists differ at index 2.
Actual (opA): 'string3'
Expected (opB): 'DIFFERS']]></Description>
</Incident>
<Incident type="fail" file="/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp" line="308">
<DataTag><![CDATA[second-last item different]]></DataTag>
- <Description><![CDATA[Compared QStringLists differ at index 2.
+ <Description><![CDATA[Compared lists differ at index 2.
Actual (opA): 'string3'
Expected (opB): 'DIFFERS']]></Description>
</Incident>
<Incident type="fail" file="/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp" line="308">
<DataTag><![CDATA[prefix]]></DataTag>
- <Description><![CDATA[Compared QStringLists have different sizes.
+ <Description><![CDATA[Compared lists have different sizes.
Actual (opA) size: '2'
Expected (opB) size: '1']]></Description>
</Incident>
<Incident type="fail" file="/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp" line="308">
<DataTag><![CDATA[short list second]]></DataTag>
- <Description><![CDATA[Compared QStringLists have different sizes.
+ <Description><![CDATA[Compared lists have different sizes.
Actual (opA) size: '12'
Expected (opB) size: '1']]></Description>
</Incident>
<Incident type="fail" file="/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp" line="308">
<DataTag><![CDATA[short list first]]></DataTag>
- <Description><![CDATA[Compared QStringLists have different sizes.
+ <Description><![CDATA[Compared lists have different sizes.
Actual (opA) size: '1'
Expected (opB) size: '12']]></Description>
</Incident>
</TestFunction>
+<TestFunction name="compareQListInt">
+<Incident type="fail" file="tst_cmptest.cpp" line="316">
+ <Description><![CDATA[Compared lists differ at index 2.
+ Actual (int1): '3'
+ Expected (int2): '4']]></Description>
+</Incident>
+</TestFunction>
+<TestFunction name="compareQListDouble">
+<Incident type="fail" file="tst_cmptest.cpp" line="323">
+ <Description><![CDATA[Compared lists differ at index 0.
+ Actual (double1): '1.5'
+ Expected (double2): '1']]></Description>
+</Incident>
+</TestFunction>
<TestFunction name="compareQPixmaps">
<Incident type="pass" file="" line="0">
<DataTag><![CDATA[both null]]></DataTag>
diff --git a/tests/auto/testlib/selftests/expected_cmptest.txt b/tests/auto/testlib/selftests/expected_cmptest.txt
index de666ed8b1..d41da53b06 100644
--- a/tests/auto/testlib/selftests/expected_cmptest.txt
+++ b/tests/auto/testlib/selftests/expected_cmptest.txt
@@ -22,26 +22,34 @@ FAIL! : tst_Cmptest::compare_tostring(both non-null user type) Compared values
Loc: [/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp(214)]
PASS : tst_Cmptest::compareQStringLists(empty lists)
PASS : tst_Cmptest::compareQStringLists(equal lists)
-FAIL! : tst_Cmptest::compareQStringLists(last item different) Compared QStringLists differ at index 2.
+FAIL! : tst_Cmptest::compareQStringLists(last item different) Compared lists differ at index 2.
Actual (opA): 'string3'
Expected (opB): 'DIFFERS'
Loc: [/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp(308)]
-FAIL! : tst_Cmptest::compareQStringLists(second-last item different) Compared QStringLists differ at index 2.
+FAIL! : tst_Cmptest::compareQStringLists(second-last item different) Compared lists differ at index 2.
Actual (opA): 'string3'
Expected (opB): 'DIFFERS'
Loc: [/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp(308)]
-FAIL! : tst_Cmptest::compareQStringLists(prefix) Compared QStringLists have different sizes.
+FAIL! : tst_Cmptest::compareQStringLists(prefix) Compared lists have different sizes.
Actual (opA) size: '2'
Expected (opB) size: '1'
Loc: [/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp(308)]
-FAIL! : tst_Cmptest::compareQStringLists(short list second) Compared QStringLists have different sizes.
+FAIL! : tst_Cmptest::compareQStringLists(short list second) Compared lists have different sizes.
Actual (opA) size: '12'
Expected (opB) size: '1'
Loc: [/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp(308)]
-FAIL! : tst_Cmptest::compareQStringLists(short list first) Compared QStringLists have different sizes.
+FAIL! : tst_Cmptest::compareQStringLists(short list first) Compared lists have different sizes.
Actual (opA) size: '1'
Expected (opB) size: '12'
Loc: [/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp(308)]
+FAIL! : tst_Cmptest::compareQListInt() Compared lists differ at index 2.
+ Actual (int1): '3'
+ Expected (int2): '4'
+ Loc: [/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp(316)]
+FAIL! : tst_Cmptest::compareQListDouble() Compared lists differ at index 0.
+ Actual (double1): '1.5'
+ Expected (double2): '1'
+ Loc: [/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp(323)]
PASS : tst_Cmptest::compareQPixmaps(both null)
FAIL! : tst_Cmptest::compareQPixmaps(one null) Compared QPixmaps differ.
Actual (opA).isNull(): 1
@@ -79,5 +87,5 @@ FAIL! : tst_Cmptest::compareQImages(different format) Compared QImages differ i
FAIL! : tst_Cmptest::compareQImages(different pixels) Compared values are not the same
Loc: [/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp(360)]
PASS : tst_Cmptest::cleanupTestCase()
-Totals: 11 passed, 18 failed, 0 skipped
+Totals: 11 passed, 20 failed, 0 skipped
********* Finished testing of tst_Cmptest *********
diff --git a/tests/auto/testlib/selftests/expected_cmptest.xml b/tests/auto/testlib/selftests/expected_cmptest.xml
index 0e5b6de335..ccab93d7c0 100644
--- a/tests/auto/testlib/selftests/expected_cmptest.xml
+++ b/tests/auto/testlib/selftests/expected_cmptest.xml
@@ -51,35 +51,49 @@
</Incident>
<Incident type="fail" file="/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp" line="308">
<DataTag><![CDATA[last item different]]></DataTag>
- <Description><![CDATA[Compared QStringLists differ at index 2.
+ <Description><![CDATA[Compared lists differ at index 2.
Actual (opA): 'string3'
Expected (opB): 'DIFFERS']]></Description>
</Incident>
<Incident type="fail" file="/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp" line="308">
<DataTag><![CDATA[second-last item different]]></DataTag>
- <Description><![CDATA[Compared QStringLists differ at index 2.
+ <Description><![CDATA[Compared lists differ at index 2.
Actual (opA): 'string3'
Expected (opB): 'DIFFERS']]></Description>
</Incident>
<Incident type="fail" file="/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp" line="308">
<DataTag><![CDATA[prefix]]></DataTag>
- <Description><![CDATA[Compared QStringLists have different sizes.
+ <Description><![CDATA[Compared lists have different sizes.
Actual (opA) size: '2'
Expected (opB) size: '1']]></Description>
</Incident>
<Incident type="fail" file="/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp" line="308">
<DataTag><![CDATA[short list second]]></DataTag>
- <Description><![CDATA[Compared QStringLists have different sizes.
+ <Description><![CDATA[Compared lists have different sizes.
Actual (opA) size: '12'
Expected (opB) size: '1']]></Description>
</Incident>
<Incident type="fail" file="/home/user/dev/qt5/qtbase/tests/auto/testlib/selftests/cmptest/tst_cmptest.cpp" line="308">
<DataTag><![CDATA[short list first]]></DataTag>
- <Description><![CDATA[Compared QStringLists have different sizes.
+ <Description><![CDATA[Compared lists have different sizes.
Actual (opA) size: '1'
Expected (opB) size: '12']]></Description>
</Incident>
</TestFunction>
+<TestFunction name="compareQListInt">
+<Incident type="fail" file="tst_cmptest.cpp" line="316">
+ <Description><![CDATA[Compared lists differ at index 2.
+ Actual (int1): '3'
+ Expected (int2): '4']]></Description>
+</Incident>
+</TestFunction>
+<TestFunction name="compareQListDouble">
+<Incident type="fail" file="tst_cmptest.cpp" line="323">
+ <Description><![CDATA[Compared lists differ at index 0.
+ Actual (double1): '1.5'
+ Expected (double2): '1']]></Description>
+</Incident>
+</TestFunction>
<TestFunction name="compareQPixmaps">
<Incident type="pass" file="" line="0">
<DataTag><![CDATA[both null]]></DataTag>
diff --git a/tests/auto/testlib/selftests/expected_cmptest.xunitxml b/tests/auto/testlib/selftests/expected_cmptest.xunitxml
index 33e78a5290..0cb88147b0 100644
--- a/tests/auto/testlib/selftests/expected_cmptest.xunitxml
+++ b/tests/auto/testlib/selftests/expected_cmptest.xunitxml
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" ?>
-<testsuite errors="0" failures="18" tests="8" name="tst_Cmptest">
+<testsuite errors="0" failures="20" tests="10" name="tst_Cmptest">
<properties>
<property value="@INSERT_QT_VERSION_HERE@" name="QTestVersion"/>
<property value="@INSERT_QT_VERSION_HERE@" name="QtVersion"/>
@@ -22,22 +22,32 @@
Expected (expected): QVariant(PhonyClass,&lt;value not representable as string&gt;)" result="fail"/>
</testcase>
<testcase result="fail" name="compareQStringLists">
- <failure tag="last item different" message="Compared QStringLists differ at index 2.
+ <failure tag="last item different" message="Compared lists differ at index 2.
Actual (opA): &apos;string3&apos;
Expected (opB): &apos;DIFFERS&apos;" result="fail"/>
- <failure tag="second&#x002D;last item different" message="Compared QStringLists differ at index 2.
+ <failure tag="second&#x002D;last item different" message="Compared lists differ at index 2.
Actual (opA): &apos;string3&apos;
Expected (opB): &apos;DIFFERS&apos;" result="fail"/>
- <failure tag="prefix" message="Compared QStringLists have different sizes.
+ <failure tag="prefix" message="Compared lists have different sizes.
Actual (opA) size: &apos;2&apos;
Expected (opB) size: &apos;1&apos;" result="fail"/>
- <failure tag="short list second" message="Compared QStringLists have different sizes.
+ <failure tag="short list second" message="Compared lists have different sizes.
Actual (opA) size: &apos;12&apos;
Expected (opB) size: &apos;1&apos;" result="fail"/>
- <failure tag="short list first" message="Compared QStringLists have different sizes.
+ <failure tag="short list first" message="Compared lists have different sizes.
Actual (opA) size: &apos;1&apos;
Expected (opB) size: &apos;12&apos;" result="fail"/>
</testcase>
+ <testcase result="fail" name="compareQListInt">
+ <failure message="Compared lists differ at index 2.
+ Actual (int1): &apos;3&apos;
+ Expected (int2): &apos;4&apos;" result="fail"/>
+ </testcase>
+ <testcase result="fail" name="compareQListDouble">
+ <failure message="Compared lists differ at index 0.
+ Actual (double1): &apos;1.5&apos;
+ Expected (double2): &apos;1&apos;" result="fail"/>
+ </testcase>
<testcase result="fail" name="compareQPixmaps">
<failure tag="one null" message="Compared QPixmaps differ.
Actual (opA).isNull(): 1
diff --git a/tests/auto/testlib/selftests/expectfail/expectfail.pro b/tests/auto/testlib/selftests/expectfail/expectfail.pro
index fdaf888263..c1849990f2 100644
--- a/tests/auto/testlib/selftests/expectfail/expectfail.pro
+++ b/tests/auto/testlib/selftests/expectfail/expectfail.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = expectfail
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/failcleanup/failcleanup.pro b/tests/auto/testlib/selftests/failcleanup/failcleanup.pro
index b4781fd062..426d7cc45b 100644
--- a/tests/auto/testlib/selftests/failcleanup/failcleanup.pro
+++ b/tests/auto/testlib/selftests/failcleanup/failcleanup.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = failcleanup
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/failinit/failinit.pro b/tests/auto/testlib/selftests/failinit/failinit.pro
index 7e926f379f..6a30a5af68 100644
--- a/tests/auto/testlib/selftests/failinit/failinit.pro
+++ b/tests/auto/testlib/selftests/failinit/failinit.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = failinit
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/failinitdata/failinitdata.pro b/tests/auto/testlib/selftests/failinitdata/failinitdata.pro
index 312d32605a..b608c67dbb 100644
--- a/tests/auto/testlib/selftests/failinitdata/failinitdata.pro
+++ b/tests/auto/testlib/selftests/failinitdata/failinitdata.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = failinitdata
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/fetchbogus/fetchbogus.pro b/tests/auto/testlib/selftests/fetchbogus/fetchbogus.pro
index 63b9d223b5..33b306ca75 100644
--- a/tests/auto/testlib/selftests/fetchbogus/fetchbogus.pro
+++ b/tests/auto/testlib/selftests/fetchbogus/fetchbogus.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = fetchbogus
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/findtestdata/findtestdata.pro b/tests/auto/testlib/selftests/findtestdata/findtestdata.pro
index 25d48376d3..f04a640c59 100644
--- a/tests/auto/testlib/selftests/findtestdata/findtestdata.pro
+++ b/tests/auto/testlib/selftests/findtestdata/findtestdata.pro
@@ -7,4 +7,3 @@ CONFIG -= debug_and_release_target
RESOURCES = findtestdata.qrc
TARGET = findtestdata
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/float/float.pro b/tests/auto/testlib/selftests/float/float.pro
index d739abcc06..95980eeac8 100644
--- a/tests/auto/testlib/selftests/float/float.pro
+++ b/tests/auto/testlib/selftests/float/float.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = float
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/globaldata/globaldata.pro b/tests/auto/testlib/selftests/globaldata/globaldata.pro
index f98ddac02d..c0b1554c0f 100644
--- a/tests/auto/testlib/selftests/globaldata/globaldata.pro
+++ b/tests/auto/testlib/selftests/globaldata/globaldata.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = globaldata
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/longstring/longstring.pro b/tests/auto/testlib/selftests/longstring/longstring.pro
index d531fe6984..d16ba85095 100644
--- a/tests/auto/testlib/selftests/longstring/longstring.pro
+++ b/tests/auto/testlib/selftests/longstring/longstring.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = longstring
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/maxwarnings/maxwarnings.pro b/tests/auto/testlib/selftests/maxwarnings/maxwarnings.pro
index ef810bd022..79451af1ec 100644
--- a/tests/auto/testlib/selftests/maxwarnings/maxwarnings.pro
+++ b/tests/auto/testlib/selftests/maxwarnings/maxwarnings.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = maxwarnings
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/multiexec/multiexec.pro b/tests/auto/testlib/selftests/multiexec/multiexec.pro
index 4638c3c653..2038acbd31 100644
--- a/tests/auto/testlib/selftests/multiexec/multiexec.pro
+++ b/tests/auto/testlib/selftests/multiexec/multiexec.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = multiexec
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/printdatatags/printdatatags.pro b/tests/auto/testlib/selftests/printdatatags/printdatatags.pro
index 646e55bf8f..cd06384835 100644
--- a/tests/auto/testlib/selftests/printdatatags/printdatatags.pro
+++ b/tests/auto/testlib/selftests/printdatatags/printdatatags.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = printdatatags
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/printdatatagswithglobaltags/printdatatagswithglobaltags.pro b/tests/auto/testlib/selftests/printdatatagswithglobaltags/printdatatagswithglobaltags.pro
index bf07434e80..f1cf25d104 100644
--- a/tests/auto/testlib/selftests/printdatatagswithglobaltags/printdatatagswithglobaltags.pro
+++ b/tests/auto/testlib/selftests/printdatatagswithglobaltags/printdatatagswithglobaltags.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = printdatatagswithglobaltags
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/qexecstringlist/qexecstringlist.pro b/tests/auto/testlib/selftests/qexecstringlist/qexecstringlist.pro
index 80fb419ac9..bd967f32e6 100644
--- a/tests/auto/testlib/selftests/qexecstringlist/qexecstringlist.pro
+++ b/tests/auto/testlib/selftests/qexecstringlist/qexecstringlist.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = qexecstringlist
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/silent/silent.pro b/tests/auto/testlib/selftests/silent/silent.pro
index c4c2e41d6f..3150f65a5e 100644
--- a/tests/auto/testlib/selftests/silent/silent.pro
+++ b/tests/auto/testlib/selftests/silent/silent.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = silent
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/singleskip/singleskip.pro b/tests/auto/testlib/selftests/singleskip/singleskip.pro
index fed6755dc6..9f63e62747 100644
--- a/tests/auto/testlib/selftests/singleskip/singleskip.pro
+++ b/tests/auto/testlib/selftests/singleskip/singleskip.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = singleskip
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/skip/skip.pro b/tests/auto/testlib/selftests/skip/skip.pro
index 1bc72da113..8780d295cf 100644
--- a/tests/auto/testlib/selftests/skip/skip.pro
+++ b/tests/auto/testlib/selftests/skip/skip.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = skip
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/skipcleanup/skipcleanup.pro b/tests/auto/testlib/selftests/skipcleanup/skipcleanup.pro
index 596166b0b6..f98cda7596 100644
--- a/tests/auto/testlib/selftests/skipcleanup/skipcleanup.pro
+++ b/tests/auto/testlib/selftests/skipcleanup/skipcleanup.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = skipcleanup
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/skipinit/skipinit.pro b/tests/auto/testlib/selftests/skipinit/skipinit.pro
index 791782a5c2..7defce9a52 100644
--- a/tests/auto/testlib/selftests/skipinit/skipinit.pro
+++ b/tests/auto/testlib/selftests/skipinit/skipinit.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = skipinit
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/skipinitdata/skipinitdata.pro b/tests/auto/testlib/selftests/skipinitdata/skipinitdata.pro
index f3f8043b78..cd806c2a43 100644
--- a/tests/auto/testlib/selftests/skipinitdata/skipinitdata.pro
+++ b/tests/auto/testlib/selftests/skipinitdata/skipinitdata.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = skipinitdata
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/sleep/sleep.pro b/tests/auto/testlib/selftests/sleep/sleep.pro
index c3a8dae37d..affcba22ee 100644
--- a/tests/auto/testlib/selftests/sleep/sleep.pro
+++ b/tests/auto/testlib/selftests/sleep/sleep.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = sleep
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/strcmp/strcmp.pro b/tests/auto/testlib/selftests/strcmp/strcmp.pro
index 498a1ba4f1..f5f6eecc88 100644
--- a/tests/auto/testlib/selftests/strcmp/strcmp.pro
+++ b/tests/auto/testlib/selftests/strcmp/strcmp.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = strcmp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/subtest/subtest.pro b/tests/auto/testlib/selftests/subtest/subtest.pro
index 6b18f1960a..09dee1b1b9 100644
--- a/tests/auto/testlib/selftests/subtest/subtest.pro
+++ b/tests/auto/testlib/selftests/subtest/subtest.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = subtest
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/test/test.pro b/tests/auto/testlib/selftests/test/test.pro
index 83538edab1..0a31810105 100644
--- a/tests/auto/testlib/selftests/test/test.pro
+++ b/tests/auto/testlib/selftests/test/test.pro
@@ -18,4 +18,3 @@ RESOURCES += ../selftests.qrc
include(../selftests.pri)
for(file, SUBPROGRAMS): TEST_HELPER_INSTALLS += "../$${file}/$${file}"
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/tst_selftests.cpp b/tests/auto/testlib/selftests/tst_selftests.cpp
index 4b19ee57ea..441254c126 100644
--- a/tests/auto/testlib/selftests/tst_selftests.cpp
+++ b/tests/auto/testlib/selftests/tst_selftests.cpp
@@ -563,6 +563,9 @@ void tst_Selftests::doRunSubTest(QString const& subdir, QStringList const& logge
&& subdir != QLatin1String("cmptest") // QImage comparison requires QGuiApplication
&& subdir != QLatin1String("fetchbogus")
&& subdir != QLatin1String("xunit")
+#ifdef Q_CC_MINGW
+ && subdir != QLatin1String("silent") // calls qFatal()
+#endif
&& subdir != QLatin1String("benchlibcallgrind"))
QVERIFY2(err.isEmpty(), err.constData());
@@ -570,8 +573,8 @@ void tst_Selftests::doRunSubTest(QString const& subdir, QStringList const& logge
QString logger = loggers[n];
QList<QByteArray> res = splitLines(actualOutputs[n]);
QList<QByteArray> exp = expectedResult(subdir, logger);
-#ifdef Q_CC_MSVC
- // MSVC formats double numbers differently
+#if defined (Q_CC_MSVC) || defined(Q_CC_MINGW)
+ // MSVC, MinGW format double numbers differently
if (n == 0 && subdir == QStringLiteral("float")) {
for (int i = 0; i < exp.size(); ++i) {
exp[i].replace("e-07", "e-007");
diff --git a/tests/auto/testlib/selftests/verbose1/verbose1.pro b/tests/auto/testlib/selftests/verbose1/verbose1.pro
index eae793fc0f..f00ae69d17 100644
--- a/tests/auto/testlib/selftests/verbose1/verbose1.pro
+++ b/tests/auto/testlib/selftests/verbose1/verbose1.pro
@@ -8,4 +8,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = verbose1
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/verbose2/verbose2.pro b/tests/auto/testlib/selftests/verbose2/verbose2.pro
index 744d51b563..796cdeb975 100644
--- a/tests/auto/testlib/selftests/verbose2/verbose2.pro
+++ b/tests/auto/testlib/selftests/verbose2/verbose2.pro
@@ -8,4 +8,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = verbose2
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/warnings/warnings.pro b/tests/auto/testlib/selftests/warnings/warnings.pro
index 9ea291606d..0c6cddcefb 100644
--- a/tests/auto/testlib/selftests/warnings/warnings.pro
+++ b/tests/auto/testlib/selftests/warnings/warnings.pro
@@ -5,4 +5,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = warnings
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/testlib/selftests/xunit/xunit.pro b/tests/auto/testlib/selftests/xunit/xunit.pro
index e3a3955735..b8c606e828 100644
--- a/tests/auto/testlib/selftests/xunit/xunit.pro
+++ b/tests/auto/testlib/selftests/xunit/xunit.pro
@@ -6,4 +6,3 @@ mac:CONFIG -= app_bundle
CONFIG -= debug_and_release_target
TARGET = xunit
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/tools/moc/dollars.h b/tests/auto/tools/moc/dollars.h
new file mode 100644
index 0000000000..8fab45559c
--- /dev/null
+++ b/tests/auto/tools/moc/dollars.h
@@ -0,0 +1,70 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Olivier Goffart <ogoffart@woboq.com>
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+/* both GCC and clang allow $ in identifiers
+ * So moc should not throw a parse error if it parses a file that contains such identifiers
+ */
+
+#include <QObject>
+
+#define macro$1 function1
+#define $macro2 function2
+
+namespace $NS {
+ class $CLS : public QObject
+ {
+ Q_PROPERTY(int rich$ MEMBER m_$rich$)
+ Q_PROPERTY(int money$$$ READ $$$money$$$ WRITE $$$setMoney$$$)
+ Q_OBJECT
+
+ int m_$rich$;
+ int m_money;
+ int $$$money$$$() { return m_money; }
+ int $$$setMoney$$$(int m) { return m_money = m; }
+
+ Q_SIGNALS:
+ void macro$1 ();
+ void $macro2 ();
+
+ void function$3 ($CLS * cl$s);
+ };
+}
+
diff --git a/tests/auto/tools/moc/gadgetwithnoenums.h b/tests/auto/tools/moc/gadgetwithnoenums.h
index 5a9a789471..0da75e8eb1 100644
--- a/tests/auto/tools/moc/gadgetwithnoenums.h
+++ b/tests/auto/tools/moc/gadgetwithnoenums.h
@@ -43,20 +43,24 @@
#include <QObject>
-class GadgetWithNoEnums {
+class GadgetWithNoEnums
+{
Q_GADGET
- public:
- GadgetWithNoEnums() {}
- virtual ~GadgetWithNoEnums() {}
-};
-
-class DerivedGadgetWithEnums : public GadgetWithNoEnums {
- Q_GADGET
- Q_ENUMS( FooEnum )
- public:
- enum FooEnum { FooValue };
- DerivedGadgetWithEnums() {}
- ~DerivedGadgetWithEnums() {}
+
+public:
+ GadgetWithNoEnums() {}
+ virtual ~GadgetWithNoEnums() {}
+};
+
+class DerivedGadgetWithEnums : public GadgetWithNoEnums
+{
+ Q_GADGET
+ Q_ENUMS( FooEnum )
+
+public:
+ enum FooEnum { FooValue };
+ DerivedGadgetWithEnums() {}
+ ~DerivedGadgetWithEnums() {}
};
#endif
diff --git a/tests/auto/tools/moc/moc.pro b/tests/auto/tools/moc/moc.pro
index 772086d3c4..1600c458b5 100644
--- a/tests/auto/tools/moc/moc.pro
+++ b/tests/auto/tools/moc/moc.pro
@@ -11,7 +11,6 @@ TARGET = tst_moc
INCLUDEPATH += testproject/include testproject
-DEFINES += SRCDIR=\\\"$$PWD\\\"
cross_compile: DEFINES += MOC_CROSS_COMPILED
HEADERS += using-namespaces.h no-keywords.h task87883.h c-comments.h backslash-newlines.h oldstyle-casts.h \
@@ -27,6 +26,7 @@ HEADERS += using-namespaces.h no-keywords.h task87883.h c-comments.h backslash-n
if(*-g++*|*-icc*|*-clang*|*-llvm):!irix-*:!win32-*: HEADERS += os9-newlines.h win-newlines.h
+if(*-g++*|*-clang*): HEADERS += dollars.h
SOURCES += tst_moc.cpp
QT -= gui
diff --git a/tests/auto/tools/moc/parse-defines.h b/tests/auto/tools/moc/parse-defines.h
index f12899e368..aaadcef601 100644
--- a/tests/auto/tools/moc/parse-defines.h
+++ b/tests/auto/tools/moc/parse-defines.h
@@ -64,7 +64,7 @@
#define PD_CLASSINFO Q_CLASSINFO
-#if defined(Q_COMPILER_VARIADIC_MACROS)
+#if defined(Q_COMPILER_VARIADIC_MACROS) || defined (Q_MOC_RUN)
#define PD_VARARG(x, ...) x(__VA_ARGS__)
#if defined(Q_CC_GNU) || defined(Q_MOC_RUN)
@@ -104,7 +104,7 @@ public slots:
PD_TEST_IDENTIFIER_ARG(void, combined6()) {}
-#if defined(Q_COMPILER_VARIADIC_MACROS)
+#if defined(Q_COMPILER_VARIADIC_MACROS) || defined (Q_MOC_RUN)
PD_VARARG(void vararg1) {}
PD_VARARG(void vararg2, int) {}
PD_VARARG(void vararg3, int, int) {}
@@ -112,6 +112,13 @@ public slots:
PD_VARARGEXT(void vararg4) {}
PD_VARARGEXT(void vararg5, int) {}
PD_VARARGEXT(void vararg6, int, int) {}
+#else
+ void vararg1() {}
+ void vararg2(int) {}
+ void vararg3(int,int) {}
+ void vararg4() {}
+ void vararg5(int) {}
+ void vararg6(int,int) {}
#endif
#define OUTERFUNCTION(x) x
diff --git a/tests/auto/tools/moc/task189996.h b/tests/auto/tools/moc/task189996.h
index 975d762fa8..01b210d6eb 100644
--- a/tests/auto/tools/moc/task189996.h
+++ b/tests/auto/tools/moc/task189996.h
@@ -43,10 +43,12 @@
#ifndef TASK189996_H
#define TASK189996_H
-#include <QObject>
-
-class InlineSlotsWithThrowDeclaration : public QObject {
- Q_OBJECT
+#include <QObject>
+
+class InlineSlotsWithThrowDeclaration : public QObject
+{
+ Q_OBJECT
+
public slots:
void a() throw() { }
void b() const throw() { }
diff --git a/tests/auto/tools/moc/template-gtgt.h b/tests/auto/tools/moc/template-gtgt.h
index baa8553103..2c2f56c34d 100644
--- a/tests/auto/tools/moc/template-gtgt.h
+++ b/tests/auto/tools/moc/template-gtgt.h
@@ -39,13 +39,13 @@
**
****************************************************************************/
template<class TYPE, size_t COUNT>
-class myTemplate :
+class myTemplate :
QString,
QVector<TYPE, QList<COUNT>>
{};
template<class TYPE, size_t COUNT>
-class myTemplate2 :
+class myTemplate2 :
QString,
QVector<TYPE, QList< (4 >> 2) >>
{};
diff --git a/tests/auto/tools/moc/tst_moc.cpp b/tests/auto/tools/moc/tst_moc.cpp
index ee82dc0652..3cd2f1f936 100644
--- a/tests/auto/tools/moc/tst_moc.cpp
+++ b/tests/auto/tools/moc/tst_moc.cpp
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2013 Olivier Goffart <ogoffart@woboq.com>
** Contact: http://www.qt-project.org/legal
**
** This file is part of the test suite of the Qt Toolkit.
@@ -447,15 +448,6 @@ public:
#endif
#endif
-static QString srcify(const char *path)
-{
-#ifndef Q_OS_IRIX
- return QString(SRCDIR) + QLatin1Char('/') + QLatin1String(path);
-#else
- return QString(QLatin1String(path));
-#endif
-}
-
class CtorTestClass : public QObject
{
Q_OBJECT
@@ -480,6 +472,8 @@ CtorTestClass::CtorTestClass(QObject *parent)
CtorTestClass::CtorTestClass(int, int, int) {}
+class PrivatePropertyTest;
+
class tst_Moc : public QObject
{
Q_OBJECT
@@ -487,9 +481,15 @@ class tst_Moc : public QObject
Q_PROPERTY(bool user1 READ user1 USER true )
Q_PROPERTY(bool user2 READ user2 USER false)
Q_PROPERTY(bool user3 READ user3 USER userFunction())
+ Q_PROPERTY(QString member1 MEMBER sMember)
+ Q_PROPERTY(QString member2 MEMBER sMember READ member2)
+ Q_PROPERTY(QString member3 MEMBER sMember WRITE setMember3)
+ Q_PROPERTY(QString member4 MEMBER sMember NOTIFY member4Changed)
+ Q_PROPERTY(QString member5 MEMBER sMember NOTIFY member5Changed)
+ Q_PROPERTY(QString member6 MEMBER sConst CONSTANT)
public:
- inline tst_Moc() {}
+ inline tst_Moc() : sConst("const") {}
private slots:
void initTestCase();
@@ -546,6 +546,9 @@ private slots:
void cxx11Enums_data();
void cxx11Enums();
void returnRefs();
+ void memberProperties_data();
+ void memberProperties();
+ void memberProperties2();
void privateSignalConnection();
void finalClasses_data();
void finalClasses();
@@ -553,6 +556,7 @@ private slots:
void explicitOverrideControl();
void autoPropertyMetaTypeRegistration();
void autoMethodArgumentMetaTypeRegistration();
+ void autoSignalSpyMetaTypeRegistration();
void parseDefines();
void preprocessorOnly();
void unterminatedFunctionMacro();
@@ -565,6 +569,8 @@ signals:
void sigWithCustomType(const MyStruct);
void constSignal1() const;
void constSignal2(int arg) const;
+ void member4Changed();
+ void member5Changed(const QString &newVal);
private:
bool user1() { return true; };
@@ -572,14 +578,23 @@ private:
bool user3() { return false; };
bool userFunction(){ return false; };
template <class T> void revisions_T();
+ QString member2() const { return sMember; }
+ void setMember3( const QString &sVal ) { sMember = sVal; }
private:
+ QString m_sourceDirectory;
QString qtIncludePath;
class PrivateClass;
+ QString sMember;
+ const QString sConst;
+ PrivatePropertyTest *pPPTest;
};
void tst_Moc::initTestCase()
{
+ const QString testHeader = QFINDTESTDATA("backslash-newlines.h");
+ QVERIFY(!testHeader.isEmpty());
+ m_sourceDirectory = QFileInfo(testHeader).absolutePath();
#if defined(Q_OS_UNIX) && !defined(QT_NO_PROCESS)
QProcess proc;
proc.start("qmake", QStringList() << "-query" << "QT_INSTALL_HEADERS");
@@ -626,7 +641,7 @@ void tst_Moc::oldStyleCasts()
#endif
#if defined(Q_OS_LINUX) && defined(Q_CC_GNU) && !defined(QT_NO_PROCESS)
QProcess proc;
- proc.start("moc", QStringList(srcify("/oldstyle-casts.h")));
+ proc.start("moc", QStringList(m_sourceDirectory + QStringLiteral("/oldstyle-casts.h")));
QVERIFY(proc.waitForFinished());
QCOMPARE(proc.exitCode(), 0);
QByteArray mocOut = proc.readAllStandardOutput();
@@ -656,15 +671,16 @@ void tst_Moc::warnOnExtraSignalSlotQualifiaction()
#endif
#if defined(Q_OS_LINUX) && defined(Q_CC_GNU) && !defined(QT_NO_PROCESS)
QProcess proc;
- proc.start("moc", QStringList(srcify("extraqualification.h")));
+ const QString header = m_sourceDirectory + QStringLiteral("/extraqualification.h");
+ proc.start("moc", QStringList(header));
QVERIFY(proc.waitForFinished());
QCOMPARE(proc.exitCode(), 0);
QByteArray mocOut = proc.readAllStandardOutput();
QVERIFY(!mocOut.isEmpty());
QString mocWarning = QString::fromLocal8Bit(proc.readAllStandardError());
- QCOMPARE(mocWarning, QString(SRCDIR) +
- QString("/extraqualification.h:53: Warning: Function declaration Test::badFunctionDeclaration contains extra qualification. Ignoring as signal or slot.\n") +
- QString(SRCDIR) + QString("/extraqualification.h:56: Warning: parsemaybe: Function declaration Test::anotherOne contains extra qualification. Ignoring as signal or slot.\n"));
+ QCOMPARE(mocWarning, header +
+ QString(":53: Warning: Function declaration Test::badFunctionDeclaration contains extra qualification. Ignoring as signal or slot.\n") +
+ header + QString(":56: Warning: parsemaybe: Function declaration Test::anotherOne contains extra qualification. Ignoring as signal or slot.\n"));
#else
QSKIP("Only tested on linux/gcc");
#endif
@@ -694,7 +710,7 @@ void tst_Moc::inputFileNameWithDotsButNoExtension()
#endif
#if defined(Q_OS_LINUX) && defined(Q_CC_GNU) && !defined(QT_NO_PROCESS)
QProcess proc;
- proc.setWorkingDirectory(QString(SRCDIR) + "/task71021");
+ proc.setWorkingDirectory(m_sourceDirectory + QStringLiteral("/task71021"));
proc.start("moc", QStringList("../Header"));
QVERIFY(proc.waitForFinished());
QCOMPARE(proc.exitCode(), 0);
@@ -933,16 +949,16 @@ void tst_Moc::warnOnMultipleInheritance()
#if defined(Q_OS_LINUX) && defined(Q_CC_GNU) && !defined(QT_NO_PROCESS)
QProcess proc;
QStringList args;
- args << "-I" << qtIncludePath + "/QtGui"
- << srcify("warn-on-multiple-qobject-subclasses.h");
+ const QString header = m_sourceDirectory + QStringLiteral("/warn-on-multiple-qobject-subclasses.h");
+ args << "-I" << qtIncludePath + "/QtGui" << header;
proc.start("moc", args);
QVERIFY(proc.waitForFinished());
QCOMPARE(proc.exitCode(), 0);
QByteArray mocOut = proc.readAllStandardOutput();
QVERIFY(!mocOut.isEmpty());
QString mocWarning = QString::fromLocal8Bit(proc.readAllStandardError());
- QCOMPARE(mocWarning, QString(SRCDIR) +
- QString("/warn-on-multiple-qobject-subclasses.h:53: Warning: Class Bar inherits from two QObject subclasses QWindow and Foo. This is not supported!\n"));
+ QCOMPARE(mocWarning, header +
+ QString(":53: Warning: Class Bar inherits from two QObject subclasses QWindow and Foo. This is not supported!\n"));
#else
QSKIP("Only tested on linux/gcc");
#endif
@@ -956,16 +972,16 @@ void tst_Moc::forgottenQInterface()
#if defined(Q_OS_LINUX) && defined(Q_CC_GNU) && !defined(QT_NO_PROCESS)
QProcess proc;
QStringList args;
- args << "-I" << qtIncludePath + "/QtCore"
- << srcify("forgotten-qinterface.h");
+ const QString header = m_sourceDirectory + QStringLiteral("/forgotten-qinterface.h");
+ args << "-I" << qtIncludePath + "/QtCore" << header;
proc.start("moc", args);
QVERIFY(proc.waitForFinished());
QCOMPARE(proc.exitCode(), 0);
QByteArray mocOut = proc.readAllStandardOutput();
QVERIFY(!mocOut.isEmpty());
QString mocWarning = QString::fromLocal8Bit(proc.readAllStandardError());
- QCOMPARE(mocWarning, QString(SRCDIR) +
- QString("/forgotten-qinterface.h:55: Warning: Class Test implements the interface MyInterface but does not list it in Q_INTERFACES. qobject_cast to MyInterface will not work!\n"));
+ QCOMPARE(mocWarning, header +
+ QString(":55: Warning: Class Test implements the interface MyInterface but does not list it in Q_INTERFACES. qobject_cast to MyInterface will not work!\n"));
#else
QSKIP("Only tested on linux/gcc");
#endif
@@ -976,7 +992,7 @@ void tst_Moc::os9Newline()
#if !defined(SKIP_NEWLINE_TEST)
const QMetaObject &mo = Os9Newlines::staticMetaObject;
QVERIFY(mo.indexOfSlot("testSlot()") != -1);
- QFile f(srcify("os9-newlines.h"));
+ QFile f(m_sourceDirectory + QStringLiteral("/os9-newlines.h"));
QVERIFY(f.open(QIODevice::ReadOnly)); // no QIODevice::Text!
QByteArray data = f.readAll();
f.close();
@@ -990,7 +1006,7 @@ void tst_Moc::winNewline()
#if !defined(SKIP_NEWLINE_TEST)
const QMetaObject &mo = WinNewlines::staticMetaObject;
QVERIFY(mo.indexOfSlot("testSlot()") != -1);
- QFile f(srcify("win-newlines.h"));
+ QFile f(m_sourceDirectory + QStringLiteral("/win-newlines.h"));
QVERIFY(f.open(QIODevice::ReadOnly)); // no QIODevice::Text!
QByteArray data = f.readAll();
f.close();
@@ -1037,8 +1053,8 @@ void tst_Moc::frameworkSearchPath()
#endif
#if defined(Q_OS_UNIX) && !defined(QT_NO_PROCESS)
QStringList args;
- args << "-F" << srcify(".")
- << srcify("interface-from-framework.h")
+ args << "-F" << m_sourceDirectory + QStringLiteral("/.")
+ << m_sourceDirectory + QStringLiteral("/interface-from-framework.h")
;
QProcess proc;
@@ -1075,7 +1091,7 @@ void tst_Moc::templateGtGt()
#endif
#if defined(Q_OS_LINUX) && defined(Q_CC_GNU) && !defined(QT_NO_PROCESS)
QProcess proc;
- proc.start("moc", QStringList(srcify("template-gtgt.h")));
+ proc.start("moc", QStringList(m_sourceDirectory + QStringLiteral("/template-gtgt.h")));
QVERIFY(proc.waitForFinished());
QCOMPARE(proc.exitCode(), 0);
QByteArray mocOut = proc.readAllStandardOutput();
@@ -1094,7 +1110,7 @@ void tst_Moc::defineMacroViaCmdline()
QStringList args;
args << "-DFOO";
- args << srcify("macro-on-cmdline.h");
+ args << m_sourceDirectory + QStringLiteral("/macro-on-cmdline.h");
proc.start("moc", args);
QVERIFY(proc.waitForFinished());
@@ -1164,25 +1180,38 @@ class PrivatePropertyTest : public QObject
Q_PRIVATE_PROPERTY(d, int bar READ bar WRITE setBar)
Q_PRIVATE_PROPERTY(PrivatePropertyTest::d, int plop READ plop WRITE setPlop)
Q_PRIVATE_PROPERTY(PrivatePropertyTest::d_func(), int baz READ baz WRITE setBaz)
+ Q_PRIVATE_PROPERTY(PrivatePropertyTest::d, QString blub MEMBER mBlub)
+ Q_PRIVATE_PROPERTY(PrivatePropertyTest::d, QString blub2 MEMBER mBlub READ blub)
+ Q_PRIVATE_PROPERTY(PrivatePropertyTest::d, QString blub3 MEMBER mBlub WRITE setBlub)
+ Q_PRIVATE_PROPERTY(PrivatePropertyTest::d, QString blub4 MEMBER mBlub NOTIFY blub4Changed)
+ Q_PRIVATE_PROPERTY(PrivatePropertyTest::d, QString blub5 MEMBER mBlub NOTIFY blub5Changed)
+ Q_PRIVATE_PROPERTY(PrivatePropertyTest::d, QString blub6 MEMBER mConst CONSTANT)
class MyDPointer {
public:
- MyDPointer() : mBar(0), mPlop(0) {}
+ MyDPointer() : mConst("const"), mBar(0), mPlop(0) {}
int bar() { return mBar ; }
void setBar(int value) { mBar = value; }
int plop() { return mPlop ; }
void setPlop(int value) { mPlop = value; }
int baz() { return mBaz ; }
void setBaz(int value) { mBaz = value; }
+ QString blub() const { return mBlub; }
+ void setBlub(const QString &value) { mBlub = value; }
+ QString mBlub;
+ const QString mConst;
private:
int mBar;
int mPlop;
int mBaz;
};
public:
- PrivatePropertyTest() : mFoo(0), d (new MyDPointer) {}
+ PrivatePropertyTest(QObject *parent = 0) : QObject(parent), mFoo(0), d (new MyDPointer) {}
int foo() { return mFoo ; }
void setFoo(int value) { mFoo = value; }
MyDPointer *d_func() {return d;}
+signals:
+ void blub4Changed();
+ void blub5Changed(const QString &newBlub);
private:
int mFoo;
MyDPointer *d;
@@ -1229,14 +1258,15 @@ void tst_Moc::warnOnPropertyWithoutREAD()
#endif
#if defined(Q_OS_LINUX) && defined(Q_CC_GNU) && !defined(QT_NO_PROCESS)
QProcess proc;
- proc.start("moc", QStringList(srcify("warn-on-property-without-read.h")));
+ const QString header = m_sourceDirectory + QStringLiteral("/warn-on-property-without-read.h");
+ proc.start("moc", QStringList(header));
QVERIFY(proc.waitForFinished());
QCOMPARE(proc.exitCode(), 0);
QByteArray mocOut = proc.readAllStandardOutput();
QVERIFY(!mocOut.isEmpty());
QString mocWarning = QString::fromLocal8Bit(proc.readAllStandardError());
- QCOMPARE(mocWarning, QString(SRCDIR) +
- QString("/warn-on-property-without-read.h:46: Warning: Property declaration foo has no READ accessor function. The property will be invalid.\n"));
+ QCOMPARE(mocWarning, header +
+ QString(":46: Warning: Property declaration foo has no READ accessor function or associated MEMBER variable. The property will be invalid.\n"));
#else
QSKIP("Only tested on linux/gcc");
#endif
@@ -1339,14 +1369,15 @@ void tst_Moc::warnOnVirtualSignal()
#endif
#if defined(Q_OS_LINUX) && defined(Q_CC_GNU) && !defined(QT_NO_PROCESS)
QProcess proc;
- proc.start("moc", QStringList(srcify("pure-virtual-signals.h")));
+ const QString header = m_sourceDirectory + QStringLiteral("/pure-virtual-signals.h");
+ proc.start("moc", QStringList(header));
QVERIFY(proc.waitForFinished());
QCOMPARE(proc.exitCode(), 0);
QByteArray mocOut = proc.readAllStandardOutput();
QVERIFY(!mocOut.isEmpty());
QString mocWarning = QString::fromLocal8Bit(proc.readAllStandardError());
- QCOMPARE(mocWarning, QString(SRCDIR) + QString("/pure-virtual-signals.h:48: Warning: Signals cannot be declared virtual\n") +
- QString(SRCDIR) + QString("/pure-virtual-signals.h:50: Warning: Signals cannot be declared virtual\n"));
+ QCOMPARE(mocWarning, header + QString(":48: Warning: Signals cannot be declared virtual\n") +
+ header + QString(":50: Warning: Signals cannot be declared virtual\n"));
#else
QSKIP("Only tested on linux/gcc");
#endif
@@ -1451,15 +1482,16 @@ void tst_Moc::notifyError()
#endif
#if defined(Q_OS_LINUX) && defined(Q_CC_GNU) && !defined(QT_NO_PROCESS)
QProcess proc;
- proc.start("moc", QStringList(srcify("error-on-wrong-notify.h")));
+ const QString header = m_sourceDirectory + QStringLiteral("/error-on-wrong-notify.h");
+ proc.start("moc", QStringList(header));
QVERIFY(proc.waitForFinished());
QCOMPARE(proc.exitCode(), 1);
QCOMPARE(proc.exitStatus(), QProcess::NormalExit);
QByteArray mocOut = proc.readAllStandardOutput();
QVERIFY(mocOut.isEmpty());
QString mocError = QString::fromLocal8Bit(proc.readAllStandardError());
- QCOMPARE(mocError, QString(SRCDIR) +
- QString("/error-on-wrong-notify.h:52: Error: NOTIFY signal 'fooChanged' of property 'foo' does not exist in class ClassWithWrongNOTIFY.\n"));
+ QCOMPARE(mocError, header +
+ QString(":52: Error: NOTIFY signal 'fooChanged' of property 'foo' does not exist in class ClassWithWrongNOTIFY.\n"));
#else
QSKIP("Only tested on linux/gcc");
#endif
@@ -1640,7 +1672,7 @@ void tst_Moc::warnings_data()
<< QStringList()
<< 0
<< QString("IGNORE_ALL_STDOUT")
- << QString("standard input:1: Warning: Property declaration x has no READ accessor function. The property will be invalid.");
+ << QString("standard input:1: Warning: Property declaration x has no READ accessor function or associated MEMBER variable. The property will be invalid.");
// Passing "-nn" should NOT suppress the warning
QTest::newRow("Invalid property warning with -nn")
@@ -1648,7 +1680,7 @@ void tst_Moc::warnings_data()
<< (QStringList() << "-nn")
<< 0
<< QString("IGNORE_ALL_STDOUT")
- << QString("standard input:1: Warning: Property declaration x has no READ accessor function. The property will be invalid.");
+ << QString("standard input:1: Warning: Property declaration x has no READ accessor function or associated MEMBER variable. The property will be invalid.");
// Passing "-nw" should suppress the warning
QTest::newRow("Invalid property warning with -nw")
@@ -1782,6 +1814,103 @@ void tst_Moc::returnRefs()
// they used to cause miscompilation of the moc generated file.
}
+void tst_Moc::memberProperties_data()
+{
+ QTest::addColumn<int>("object");
+ QTest::addColumn<QString>("property");
+ QTest::addColumn<QString>("signal");
+ QTest::addColumn<QString>("writeValue");
+ QTest::addColumn<bool>("expectedWriteResult");
+ QTest::addColumn<QString>("expectedReadResult");
+
+ pPPTest = new PrivatePropertyTest( this );
+
+ QTest::newRow("MEMBER property")
+ << 0 << "member1" << "" << "abc" << true << "abc";
+ QTest::newRow("MEMBER property with READ function")
+ << 0 << "member2" << "" << "def" << true << "def";
+ QTest::newRow("MEMBER property with WRITE function")
+ << 0 << "member3" << "" << "ghi" << true << "ghi";
+ QTest::newRow("MEMBER property with NOTIFY")
+ << 0 << "member4" << "member4Changed()" << "lmn" << true << "lmn";
+ QTest::newRow("MEMBER property with NOTIFY(value)")
+ << 0 << "member5" << "member5Changed(const QString&)" << "opq" << true << "opq";
+ QTest::newRow("MEMBER property with CONSTANT")
+ << 0 << "member6" << "" << "test" << false << "const";
+ QTest::newRow("private MEMBER property")
+ << 1 << "blub" << "" << "abc" << true << "abc";
+ QTest::newRow("private MEMBER property with READ function")
+ << 1 << "blub2" << "" << "def" << true << "def";
+ QTest::newRow("private MEMBER property with WRITE function")
+ << 1 << "blub3" << "" << "ghi" << true << "ghi";
+ QTest::newRow("private MEMBER property with NOTIFY")
+ << 1 << "blub4" << "blub4Changed()" << "jkl" << true << "jkl";
+ QTest::newRow("private MEMBER property with NOTIFY(value)")
+ << 1 << "blub5" << "blub5Changed(const QString&)" << "mno" << true << "mno";
+ QTest::newRow("private MEMBER property with CONSTANT")
+ << 1 << "blub6" << "" << "test" << false << "const";
+}
+
+void tst_Moc::memberProperties()
+{
+ QFETCH(int, object);
+ QFETCH(QString, property);
+ QFETCH(QString, signal);
+ QFETCH(QString, writeValue);
+ QFETCH(bool, expectedWriteResult);
+ QFETCH(QString, expectedReadResult);
+
+ QObject *pObj = (object == 0) ? this : static_cast<QObject*>(pPPTest);
+
+ QString sSignalDeclaration;
+ if (!signal.isEmpty())
+ sSignalDeclaration = QString(SIGNAL(%1)).arg(signal);
+ else
+ QTest::ignoreMessage(QtWarningMsg, "QSignalSpy: Not a valid signal, use the SIGNAL macro");
+ QSignalSpy notifySpy(pObj, sSignalDeclaration.toLatin1().constData());
+
+ int index = pObj->metaObject()->indexOfProperty(property.toLatin1().constData());
+ QVERIFY(index != -1);
+ QMetaProperty prop = pObj->metaObject()->property(index);
+
+ QCOMPARE(prop.write(pObj, writeValue), expectedWriteResult);
+
+ QVariant readValue = prop.read(pObj);
+ QCOMPARE(readValue.toString(), expectedReadResult);
+
+ if (!signal.isEmpty())
+ {
+ QCOMPARE(notifySpy.count(), 1);
+ if (prop.notifySignal().parameterNames().size() > 0) {
+ QList<QVariant> arguments = notifySpy.takeFirst();
+ QCOMPARE(arguments.size(), 1);
+ QCOMPARE(arguments.at(0).toString(), expectedReadResult);
+ }
+
+ notifySpy.clear();
+ // a second write with the same value should not cause the signal to be emitted again
+ QCOMPARE(prop.write(pObj, writeValue), expectedWriteResult);
+ QCOMPARE(notifySpy.count(), 0);
+ }
+}
+
+//this used to fail to compile
+class ClassWithOneMember : public QObject {
+ Q_PROPERTY(int member MEMBER member)
+ Q_OBJECT
+public:
+ int member;
+};
+
+void tst_Moc::memberProperties2()
+{
+ ClassWithOneMember o;
+ o.member = 442;
+ QCOMPARE(o.property("member").toInt(), 442);
+ QVERIFY(o.setProperty("member", 6666));
+ QCOMPARE(o.member, 6666);
+}
+
class SignalConnectionTester : public QObject
{
Q_OBJECT
@@ -2389,6 +2518,7 @@ struct CustomObject8 {};
struct CustomObject9 {};
struct CustomObject10 {};
struct CustomObject11 {};
+struct CustomObject12 {};
Q_DECLARE_METATYPE(CustomObject3)
Q_DECLARE_METATYPE(CustomObject4)
@@ -2399,6 +2529,7 @@ Q_DECLARE_METATYPE(CustomObject8)
Q_DECLARE_METATYPE(CustomObject9)
Q_DECLARE_METATYPE(CustomObject10)
Q_DECLARE_METATYPE(CustomObject11)
+Q_DECLARE_METATYPE(CustomObject12)
class AutoRegistrationObject : public QObject
{
@@ -2521,6 +2652,9 @@ public slots:
void ref2(QList<int>&) {}
void ref3(CustomQObject2&) {}
void ref4(QSharedPointer<CustomQObject2>&) {}
+
+signals:
+ void someSignal(CustomObject12);
};
void tst_Moc::autoPropertyMetaTypeRegistration()
@@ -2584,6 +2718,16 @@ void tst_Moc::autoMethodArgumentMetaTypeRegistration()
int i = metaObject->methodOffset(); // Start after QObject built-in slots;
+ while (i < metaObject->methodCount()) {
+ // Skip over signals so we start at the first slot.
+ const QMetaMethod method = metaObject->method(i);
+ if (method.methodType() == QMetaMethod::Signal)
+ ++i;
+ else
+ break;
+
+ }
+
#define TYPE_LOOP(TYPE) \
{ \
const QMetaMethod method = metaObject->method(i); \
@@ -2710,6 +2854,26 @@ void tst_Moc::autoMethodArgumentMetaTypeRegistration()
}
+void tst_Moc::autoSignalSpyMetaTypeRegistration()
+{
+ AutoRegistrationObject aro;
+
+ QVector<int> methodArgMetaTypeIds;
+
+ const QMetaObject *metaObject = aro.metaObject();
+
+ int i = metaObject->indexOfSignal(QMetaObject::normalizedSignature("someSignal(CustomObject12)"));
+
+ QVERIFY(i > 0);
+
+ QCOMPARE(QMetaType::type("CustomObject12"), (int)QMetaType::UnknownType);
+
+ QSignalSpy spy(&aro, SIGNAL(someSignal(CustomObject12)));
+
+ QVERIFY(QMetaType::type("CustomObject12") != QMetaType::UnknownType);
+ QCOMPARE(QMetaType::type("CustomObject12"), qMetaTypeId<CustomObject12>());
+}
+
void tst_Moc::parseDefines()
{
const QMetaObject *mo = &PD_NAMESPACE::PD_CLASSNAME::staticMetaObject;
@@ -2738,7 +2902,6 @@ void tst_Moc::parseDefines()
index = mo->indexOfSlot("combined6()");
QVERIFY(index != -1);
-#if defined(Q_COMPILER_VARIADIC_MACROS)
index = mo->indexOfSlot("vararg1()");
QVERIFY(index != -1);
index = mo->indexOfSlot("vararg2(int)");
@@ -2751,7 +2914,6 @@ void tst_Moc::parseDefines()
QVERIFY(index != -1);
index = mo->indexOfSlot("vararg6(int,int)");
QVERIFY(index != -1);
-#endif
index = mo->indexOfSlot("INNERFUNCTION(int)");
QVERIFY(index != -1);
@@ -2792,7 +2954,7 @@ void tst_Moc::preprocessorOnly()
#endif
#if defined(Q_OS_LINUX) && defined(Q_CC_GNU) && !defined(QT_NO_PROCESS)
QProcess proc;
- proc.start("moc", QStringList() << "-E" << srcify("/pp-dollar-signs.h"));
+ proc.start("moc", QStringList() << "-E" << m_sourceDirectory + QStringLiteral("/pp-dollar-signs.h"));
QVERIFY(proc.waitForFinished());
QCOMPARE(proc.exitCode(), 0);
QByteArray mocOut = proc.readAllStandardOutput();
@@ -2813,7 +2975,7 @@ void tst_Moc::unterminatedFunctionMacro()
#endif
#if defined(Q_OS_LINUX) && defined(Q_CC_GNU) && !defined(QT_NO_PROCESS)
QProcess proc;
- proc.start("moc", QStringList() << "-E" << srcify("/unterminated-function-macro.h"));
+ proc.start("moc", QStringList() << "-E" << m_sourceDirectory + QStringLiteral("/unterminated-function-macro.h"));
QVERIFY(proc.waitForFinished());
QCOMPARE(proc.exitCode(), 1);
QCOMPARE(proc.readAllStandardOutput(), QByteArray());
diff --git a/tests/auto/tools/qmake/tst_qmake.cpp b/tests/auto/tools/qmake/tst_qmake.cpp
index 186ecd77a4..0935b1bca4 100644
--- a/tests/auto/tools/qmake/tst_qmake.cpp
+++ b/tests/auto/tools/qmake/tst_qmake.cpp
@@ -85,8 +85,7 @@ private slots:
void one_space();
void findMocs();
void findDeps();
-#ifndef Q_OS_WIN
- // Test requires make
+#if defined(Q_OS_MAC)
void bundle_spaces();
#endif
void includefunction();
@@ -456,7 +455,7 @@ struct TempFile
}
};
-#ifndef Q_OS_WIN
+#if defined(Q_OS_MAC)
void tst_qmake::bundle_spaces()
{
QString workDir = base_path + "/testdata/bundle-spaces";
@@ -465,7 +464,7 @@ void tst_qmake::bundle_spaces()
// Bundles and since this might be the wrong output we rely on dry-running
// make (-n).
- test_compiler.setArguments("-n", "-spec macx-g++");
+ test_compiler.setArguments("-n", "-spec macx-clang");
QVERIFY( test_compiler.qmake(workDir, "bundle-spaces") );
@@ -486,7 +485,7 @@ void tst_qmake::bundle_spaces()
QVERIFY( !non_existing_file.exists() );
QVERIFY( test_compiler.removeMakefile(workDir) );
}
-#endif // Q_OS_WIN
+#endif // defined(Q_OS_MAC)
void tst_qmake::includefunction()
{
diff --git a/tests/auto/widgets/dialogs/dialogs.pro b/tests/auto/widgets/dialogs/dialogs.pro
index 034f37c6e0..e767c9767e 100644
--- a/tests/auto/widgets/dialogs/dialogs.pro
+++ b/tests/auto/widgets/dialogs/dialogs.pro
@@ -20,3 +20,4 @@ wince*:SUBDIRS -= qabstractprintdialog
qsidebar \
mac:qinputdialog.CONFIG += no_check_target # QTBUG-25496
+win32-g++*: SUBDIRS -= qfilesystemmodel # QTBUG-29403
diff --git a/tests/auto/widgets/dialogs/qabstractprintdialog/qabstractprintdialog.pro b/tests/auto/widgets/dialogs/qabstractprintdialog/qabstractprintdialog.pro
index b4bdb91726..2e9ae33592 100644
--- a/tests/auto/widgets/dialogs/qabstractprintdialog/qabstractprintdialog.pro
+++ b/tests/auto/widgets/dialogs/qabstractprintdialog/qabstractprintdialog.pro
@@ -7,4 +7,3 @@ CONFIG += parallel_test
TARGET = tst_qabstractprintdialog
QT += widgets printsupport testlib
SOURCES += tst_qabstractprintdialog.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/dialogs/qcolordialog/qcolordialog.pro b/tests/auto/widgets/dialogs/qcolordialog/qcolordialog.pro
index 0f02de8840..22f6bab497 100644
--- a/tests/auto/widgets/dialogs/qcolordialog/qcolordialog.pro
+++ b/tests/auto/widgets/dialogs/qcolordialog/qcolordialog.pro
@@ -6,4 +6,3 @@ SOURCES += tst_qcolordialog.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/dialogs/qdialog/qdialog.pro b/tests/auto/widgets/dialogs/qdialog/qdialog.pro
index 6039ec350d..72a2dc52b3 100644
--- a/tests/auto/widgets/dialogs/qdialog/qdialog.pro
+++ b/tests/auto/widgets/dialogs/qdialog/qdialog.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qdialog
QT += widgets testlib
SOURCES += tst_qdialog.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/dialogs/qdialog/tst_qdialog.cpp b/tests/auto/widgets/dialogs/qdialog/tst_qdialog.cpp
index 749687aef5..6d847086d9 100644
--- a/tests/auto/widgets/dialogs/qdialog/tst_qdialog.cpp
+++ b/tests/auto/widgets/dialogs/qdialog/tst_qdialog.cpp
@@ -247,7 +247,7 @@ void tst_QDialog::showMaximized()
QDialog dialog(0);
dialog.setSizeGripEnabled(true);
#ifndef QT_NO_SIZEGRIP
- QSizeGrip *sizeGrip = qFindChild<QSizeGrip *>(&dialog);
+ QSizeGrip *sizeGrip = dialog.findChild<QSizeGrip *>();
QVERIFY(sizeGrip);
#endif
@@ -324,11 +324,10 @@ void tst_QDialog::showFullScreen()
QDialog dialog(0, Qt::X11BypassWindowManagerHint);
dialog.setSizeGripEnabled(true);
#ifndef QT_NO_SIZEGRIP
- QSizeGrip *sizeGrip = qFindChild<QSizeGrip *>(&dialog);
+ QSizeGrip *sizeGrip = dialog.findChild<QSizeGrip *>();
QVERIFY(sizeGrip);
#endif
- qApp->syncX();
dialog.showFullScreen();
QVERIFY(dialog.isFullScreen());
QVERIFY(dialog.isVisible());
@@ -336,7 +335,6 @@ void tst_QDialog::showFullScreen()
QVERIFY(!sizeGrip->isVisible());
#endif
- qApp->syncX();
dialog.showNormal();
QVERIFY(!dialog.isFullScreen());
QVERIFY(dialog.isVisible());
@@ -344,32 +342,26 @@ void tst_QDialog::showFullScreen()
QVERIFY(sizeGrip->isVisible());
#endif
- qApp->syncX();
dialog.showFullScreen();
QVERIFY(dialog.isFullScreen());
QVERIFY(dialog.isVisible());
- qApp->syncX();
dialog.hide();
QVERIFY(dialog.isFullScreen());
QVERIFY(!dialog.isVisible());
- qApp->syncX();
dialog.show();
QVERIFY(dialog.isFullScreen());
QVERIFY(dialog.isVisible());
- qApp->syncX();
dialog.hide();
QVERIFY(dialog.isFullScreen());
QVERIFY(!dialog.isVisible());
- qApp->syncX();
dialog.showFullScreen();
QVERIFY(dialog.isFullScreen());
QVERIFY(dialog.isVisible());
- qApp->syncX();
dialog.hide();
QVERIFY(dialog.isFullScreen());
QVERIFY(!dialog.isVisible());
@@ -446,7 +438,7 @@ void tst_QDialog::showSizeGrip()
QVERIFY(!dialog.isSizeGripEnabled());
dialog.setSizeGripEnabled(true);
- QPointer<QSizeGrip> sizeGrip = qFindChild<QSizeGrip *>(&dialog);
+ QPointer<QSizeGrip> sizeGrip = dialog.findChild<QSizeGrip *>();
QVERIFY(sizeGrip);
QVERIFY(sizeGrip->isVisible());
QVERIFY(dialog.isSizeGripEnabled());
@@ -464,7 +456,7 @@ void tst_QDialog::showSizeGrip()
dialog.showExtension(false);
QVERIFY(dialog.extension() && !dialog.extension()->isVisible());
QVERIFY(dialog.isSizeGripEnabled());
- sizeGrip = qFindChild<QSizeGrip *>(&dialog);
+ sizeGrip = dialog.findChild<QSizeGrip *>();
QVERIFY(sizeGrip);
QVERIFY(sizeGrip->isVisible());
@@ -482,7 +474,7 @@ void tst_QDialog::showSizeGrip()
QVERIFY(!dialog.isSizeGripEnabled());
dialog.setSizeGripEnabled(true);
- sizeGrip = qFindChild<QSizeGrip *>(&dialog);
+ sizeGrip = dialog.findChild<QSizeGrip *>();
QVERIFY(sizeGrip);
QVERIFY(sizeGrip->isVisible());
sizeGrip->hide();
diff --git a/tests/auto/widgets/dialogs/qerrormessage/qerrormessage.pro b/tests/auto/widgets/dialogs/qerrormessage/qerrormessage.pro
index 509bf17bdc..a88f449494 100644
--- a/tests/auto/widgets/dialogs/qerrormessage/qerrormessage.pro
+++ b/tests/auto/widgets/dialogs/qerrormessage/qerrormessage.pro
@@ -6,4 +6,3 @@ TARGET = tst_qerrormessage
QT += widgets testlib
SOURCES += tst_qerrormessage.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/dialogs/qerrormessage/tst_qerrormessage.cpp b/tests/auto/widgets/dialogs/qerrormessage/tst_qerrormessage.cpp
index 9654f3ac5e..cb2aaeea46 100644
--- a/tests/auto/widgets/dialogs/qerrormessage/tst_qerrormessage.cpp
+++ b/tests/auto/widgets/dialogs/qerrormessage/tst_qerrormessage.cpp
@@ -61,17 +61,17 @@ void tst_QErrorMessage::dontShowAgain()
QErrorMessage errorMessageDialog(0);
- // show an error with plain string
+ // show an error with plain string
errorMessageDialog.showMessage(plainString);
QVERIFY(errorMessageDialog.isVisible());
- checkBox = qFindChild<QCheckBox*>(&errorMessageDialog);
+ checkBox = errorMessageDialog.findChild<QCheckBox*>();
QVERIFY(checkBox);
QVERIFY(checkBox->isChecked());
errorMessageDialog.close();
errorMessageDialog.showMessage(plainString);
QVERIFY(errorMessageDialog.isVisible());
- checkBox = qFindChild<QCheckBox*>(&errorMessageDialog);
+ checkBox = errorMessageDialog.findChild<QCheckBox*>();
QVERIFY(checkBox);
QVERIFY(checkBox->isChecked());
checkBox->setChecked(false);
@@ -83,7 +83,7 @@ void tst_QErrorMessage::dontShowAgain()
// show an error with an html string
errorMessageDialog.showMessage(htmlString);
QVERIFY(errorMessageDialog.isVisible());
- checkBox = qFindChild<QCheckBox*>(&errorMessageDialog);
+ checkBox = errorMessageDialog.findChild<QCheckBox*>();
QVERIFY(checkBox);
QVERIFY(!checkBox->isChecked());
checkBox->setChecked(true);
@@ -91,7 +91,7 @@ void tst_QErrorMessage::dontShowAgain()
errorMessageDialog.showMessage(htmlString);
QVERIFY(errorMessageDialog.isVisible());
- checkBox = qFindChild<QCheckBox*>(&errorMessageDialog);
+ checkBox = errorMessageDialog.findChild<QCheckBox*>();
QVERIFY(checkBox);
QVERIFY(checkBox->isChecked());
checkBox->setChecked(false);
@@ -111,7 +111,7 @@ void tst_QErrorMessage::dontShowCategoryAgain()
errorMessageDialog.showMessage(htmlString,"Cat 1");
QVERIFY(errorMessageDialog.isVisible());
- checkBox = qFindChild<QCheckBox*>(&errorMessageDialog);
+ checkBox = errorMessageDialog.findChild<QCheckBox*>();
QVERIFY(checkBox);
QVERIFY(checkBox->isChecked());
checkBox->setChecked(true);
@@ -119,7 +119,7 @@ void tst_QErrorMessage::dontShowCategoryAgain()
errorMessageDialog.showMessage(htmlString,"Cat 1");
QVERIFY(errorMessageDialog.isVisible());
- checkBox = qFindChild<QCheckBox*>(&errorMessageDialog);
+ checkBox = errorMessageDialog.findChild<QCheckBox*>();
QVERIFY(checkBox);
QVERIFY(checkBox->isChecked());
checkBox->setChecked(true);
@@ -127,7 +127,7 @@ void tst_QErrorMessage::dontShowCategoryAgain()
errorMessageDialog.showMessage(htmlString2,"Cat 1");
QVERIFY(errorMessageDialog.isVisible());
- checkBox = qFindChild<QCheckBox*>(&errorMessageDialog);
+ checkBox = errorMessageDialog.findChild<QCheckBox*>();
QVERIFY(checkBox);
QVERIFY(checkBox->isChecked());
checkBox->setChecked(true);
@@ -135,7 +135,7 @@ void tst_QErrorMessage::dontShowCategoryAgain()
errorMessageDialog.showMessage(htmlString,"Cat 1");
QVERIFY(errorMessageDialog.isVisible());
- checkBox = qFindChild<QCheckBox*>(&errorMessageDialog);
+ checkBox = errorMessageDialog.findChild<QCheckBox*>();
QVERIFY(checkBox);
QVERIFY(checkBox->isChecked());
checkBox->setChecked(false);
diff --git a/tests/auto/widgets/dialogs/qfiledialog/qfiledialog.pro b/tests/auto/widgets/dialogs/qfiledialog/qfiledialog.pro
index 043e37f92e..3a96827352 100644
--- a/tests/auto/widgets/dialogs/qfiledialog/qfiledialog.pro
+++ b/tests/auto/widgets/dialogs/qfiledialog/qfiledialog.pro
@@ -21,5 +21,3 @@ wince* {
} else {
DEFINES += SRCDIR=\\\"$$PWD/\\\"
}
-
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/dialogs/qfiledialog/tst_qfiledialog.cpp b/tests/auto/widgets/dialogs/qfiledialog/tst_qfiledialog.cpp
index 0a7a06f445..d797c553db 100644
--- a/tests/auto/widgets/dialogs/qfiledialog/tst_qfiledialog.cpp
+++ b/tests/auto/widgets/dialogs/qfiledialog/tst_qfiledialog.cpp
@@ -200,7 +200,7 @@ void tst_QFiledialog::currentChangedSignal()
fd.setViewMode(QFileDialog::List);
QSignalSpy spyCurrentChanged(&fd, SIGNAL(currentChanged(QString)));
- QListView* listView = qFindChild<QListView*>(&fd, "listView");
+ QListView* listView = fd.findChild<QListView*>("listView");
QVERIFY(listView);
fd.setDirectory(QDir::root());
QModelIndex root = listView->rootIndex();
@@ -229,14 +229,14 @@ void tst_QFiledialog::directoryEnteredSignal()
QSignalSpy spyDirectoryEntered(&fd, SIGNAL(directoryEntered(QString)));
// sidebar
- QSidebar *sidebar = qFindChild<QSidebar*>(&fd, "sidebar");
+ QSidebar *sidebar = fd.findChild<QSidebar*>("sidebar");
sidebar->setCurrentIndex(sidebar->model()->index(1, 0));
QTest::keyPress(sidebar->viewport(), Qt::Key_Return);
QCOMPARE(spyDirectoryEntered.count(), 1);
spyDirectoryEntered.clear();
// lookInCombo
- QComboBox *comboBox = qFindChild<QComboBox*>(&fd, "lookInCombo");
+ QComboBox *comboBox = fd.findChild<QComboBox*>("lookInCombo");
comboBox->showPopup();
QVERIFY(comboBox->view()->model()->index(1, 0).isValid());
comboBox->view()->setCurrentIndex(comboBox->view()->model()->index(1, 0));
@@ -248,7 +248,7 @@ void tst_QFiledialog::directoryEnteredSignal()
/*
// platform specific
fd.setViewMode(QFileDialog::ViewMode(QFileDialog::List));
- QListView* listView = qFindChild<QListView*>(&fd, "listView");
+ QListView* listView = fd.findChild<QListView*>("listView");
QVERIFY(listView);
QModelIndex root = listView->rootIndex();
QTRY_COMPARE(listView->model()->rowCount(root) > 0, true);
@@ -293,7 +293,7 @@ void tst_QFiledialog::filesSelectedSignal()
fd.show();
QVERIFY(QTest::qWaitForWindowExposed(&fd));
- QListView *listView = qFindChild<QListView*>(&fd, "listView");
+ QListView *listView = fd.findChild<QListView*>("listView");
QVERIFY(listView);
QModelIndex root = listView->rootIndex();
@@ -314,7 +314,7 @@ void tst_QFiledialog::filesSelectedSignal()
listView->selectionModel()->select(file, QItemSelectionModel::Select | QItemSelectionModel::Rows);
listView->setCurrentIndex(file);
- QDialogButtonBox *buttonBox = qFindChild<QDialogButtonBox*>(&fd, "buttonBox");
+ QDialogButtonBox *buttonBox = fd.findChild<QDialogButtonBox*>("buttonBox");
QPushButton *button = buttonBox->button(QDialogButtonBox::Open);
QVERIFY(button);
QVERIFY(button->isEnabled());
@@ -338,7 +338,7 @@ void tst_QFiledialog::filterSelectedSignal()
fd.setNameFilters(filterChoices);
QCOMPARE(fd.nameFilters(), filterChoices);
- QComboBox *filters = qFindChild<QComboBox*>(&fd, "fileTypeCombo");
+ QComboBox *filters = fd.findChild<QComboBox*>("fileTypeCombo");
QVERIFY(filters);
QVERIFY(filters->view());
QCOMPARE(filters->isVisible(), true);
@@ -367,7 +367,7 @@ void tst_QFiledialog::directory()
{
QNonNativeFileDialog fd;
fd.setViewMode(QFileDialog::List);
- QFileSystemModel *model = qFindChild<QFileSystemModel*>(&fd, "qt_filesystem_model");
+ QFileSystemModel *model = fd.findChild<QFileSystemModel*>("qt_filesystem_model");
QVERIFY(model);
fd.setDirectory(QDir::currentPath());
QSignalSpy spyCurrentChanged(&fd, SIGNAL(currentChanged(QString)));
@@ -392,7 +392,7 @@ void tst_QFiledialog::directory()
QCOMPARE(spyFilterSelected.count(), 0);
// Check my way
- QList<QListView*> list = qFindChildren<QListView*>(&fd, "listView");
+ QList<QListView*> list = fd.findChildren<QListView*>("listView");
QVERIFY(list.count() > 0);
#ifdef Q_OS_WIN
QCOMPARE(list.at(0)->rootIndex().data().toString().toLower(), temp.dirName().toLower());
@@ -476,9 +476,9 @@ void tst_QFiledialog::completer()
fd.show();
QVERIFY(QTest::qWaitForWindowExposed(&fd));
QVERIFY(fd.isVisible());
- QFileSystemModel *model = qFindChild<QFileSystemModel*>(&fd, "qt_filesystem_model");
+ QFileSystemModel *model = fd.findChild<QFileSystemModel*>("qt_filesystem_model");
QVERIFY(model);
- QLineEdit *lineEdit = qFindChild<QLineEdit*>(&fd, "fileNameEdit");
+ QLineEdit *lineEdit = fd.findChild<QLineEdit*>("fileNameEdit");
QVERIFY(lineEdit);
QCompleter *completer = lineEdit->completer();
QVERIFY(completer);
@@ -567,7 +567,7 @@ void tst_QFiledialog::completer_up()
QSignalSpy spyFilterSelected(&fd, SIGNAL(filterSelected(QString)));
fd.show();
- QLineEdit *lineEdit = qFindChild<QLineEdit*>(&fd, "fileNameEdit");
+ QLineEdit *lineEdit = fd.findChild<QLineEdit*>("fileNameEdit");
QVERIFY(lineEdit);
QCOMPARE(spyFilesSelected.count(), 0);
int depth = QDir::currentPath().split('/').count();
@@ -586,7 +586,7 @@ void tst_QFiledialog::acceptMode()
QNonNativeFileDialog fd;
fd.show();
- QToolButton* newButton = qFindChild<QToolButton*>(&fd, "newFolderButton");
+ QToolButton* newButton = fd.findChild<QToolButton*>("newFolderButton");
QVERIFY(newButton);
// default
@@ -658,7 +658,7 @@ void tst_QFiledialog::filters()
QCOMPARE(fd.nameFilters(), QStringList("All Files (*)"));
// effects
- QList<QComboBox*> views = qFindChildren<QComboBox*>(&fd, "fileTypeCombo");
+ QList<QComboBox*> views = fd.findChildren<QComboBox*>("fileTypeCombo");
QVERIFY(views.count() == 1);
QCOMPARE(views.at(0)->isVisible(), false);
@@ -728,7 +728,7 @@ void tst_QFiledialog::history()
{
QNonNativeFileDialog fd;
fd.setViewMode(QFileDialog::List);
- QFileSystemModel *model = qFindChild<QFileSystemModel*>(&fd, "qt_filesystem_model");
+ QFileSystemModel *model = fd.findChild<QFileSystemModel*>("qt_filesystem_model");
QVERIFY(model);
QSignalSpy spyCurrentChanged(&fd, SIGNAL(currentChanged(QString)));
QSignalSpy spyDirectoryEntered(&fd, SIGNAL(directoryEntered(QString)));
@@ -744,7 +744,7 @@ void tst_QFiledialog::history()
if (fd.history() != history) {
qDebug() << fd.history() << history;
// quick and dirty output for windows failure.
- QListView* list = qFindChild<QListView*>(&fd, "listView");
+ QListView* list = fd.findChild<QListView*>("listView");
QVERIFY(list);
QModelIndex root = list->rootIndex();
while (root.isValid()) {
@@ -781,9 +781,9 @@ void tst_QFiledialog::isReadOnly()
{
QNonNativeFileDialog fd;
- QPushButton* newButton = qFindChild<QPushButton*>(&fd, "newFolderButton");
- QAction* renameAction = qFindChild<QAction*>(&fd, "qt_rename_action");
- QAction* deleteAction = qFindChild<QAction*>(&fd, "qt_delete_action");
+ QPushButton* newButton = fd.findChild<QPushButton*>("newFolderButton");
+ QAction* renameAction = fd.findChild<QAction*>("qt_rename_action");
+ QAction* deleteAction = fd.findChild<QAction*>("qt_delete_action");
QCOMPARE(fd.isReadOnly(), false);
@@ -862,7 +862,7 @@ void tst_QFiledialog::selectFile()
QFETCH(QString, file);
QFETCH(int, count);
QNonNativeFileDialog fd;
- QFileSystemModel *model = qFindChild<QFileSystemModel*>(&fd, "qt_filesystem_model");
+ QFileSystemModel *model = fd.findChild<QFileSystemModel*>("qt_filesystem_model");
QVERIFY(model);
fd.setDirectory(QDir::currentPath());
// default value
@@ -912,7 +912,7 @@ void tst_QFiledialog::selectFiles()
QStringList list = fd.directory().entryList(QDir::Files);
QModelIndexList toSelect;
QVERIFY(list.count() > 1);
- QListView* listView = qFindChild<QListView*>(&fd, "listView");
+ QListView* listView = fd.findChild<QListView*>("listView");
QVERIFY(listView);
for (int i = 0; i < list.count(); ++i) {
fd.selectFile(fd.directory().path() + "/" + list.at(i));
@@ -945,7 +945,7 @@ void tst_QFiledialog::selectFiles()
dialog->selectFile(temporary);
dialog->show();
QVERIFY(QTest::qWaitForWindowExposed(dialog));
- QLineEdit *lineEdit = qFindChild<QLineEdit*>(dialog, "fileNameEdit");
+ QLineEdit *lineEdit = dialog->findChild<QLineEdit*>("fileNameEdit");
QVERIFY(lineEdit);
QCOMPARE(lineEdit->text(),QLatin1String("blah"));
delete dialog;
@@ -958,13 +958,13 @@ void tst_QFiledialog::viewMode()
fd.show();
// find widgets
- QList<QTreeView*> treeView = qFindChildren<QTreeView*>(&fd, "treeView");
+ QList<QTreeView*> treeView = fd.findChildren<QTreeView*>("treeView");
QCOMPARE(treeView.count(), 1);
- QList<QListView*> listView = qFindChildren<QListView*>(&fd, "listView");
+ QList<QListView*> listView = fd.findChildren<QListView*>("listView");
QCOMPARE(listView.count(), 1);
- QList<QToolButton*> listButton = qFindChildren<QToolButton*>(&fd, "listModeButton");
+ QList<QToolButton*> listButton = fd.findChildren<QToolButton*>("listModeButton");
QCOMPARE(listButton.count(), 1);
- QList<QToolButton*> treeButton = qFindChildren<QToolButton*>(&fd, "detailModeButton");
+ QList<QToolButton*> treeButton = fd.findChildren<QToolButton*>("detailModeButton");
QCOMPARE(treeButton.count(), 1);
// default value
@@ -1068,9 +1068,8 @@ void tst_QFiledialog::focus()
// make sure the tests work with focus follows mouse
QCursor::setPos(fd.geometry().center());
- QApplication::syncX();
- QList<QWidget*> treeView = qFindChildren<QWidget*>(&fd, "fileNameEdit");
+ QList<QWidget*> treeView = fd.findChildren<QWidget*>("fileNameEdit");
QCOMPARE(treeView.count(), 1);
QVERIFY(treeView.at(0));
QTRY_COMPARE(treeView.at(0)->hasFocus(), true);
@@ -1081,11 +1080,11 @@ void tst_QFiledialog::focus()
void tst_QFiledialog::historyBack()
{
QNonNativeFileDialog fd;
- QFileSystemModel *model = qFindChild<QFileSystemModel*>(&fd, "qt_filesystem_model");
+ QFileSystemModel *model = fd.findChild<QFileSystemModel*>("qt_filesystem_model");
QVERIFY(model);
- QToolButton *backButton = qFindChild<QToolButton*>(&fd, "backButton");
+ QToolButton *backButton = fd.findChild<QToolButton*>("backButton");
QVERIFY(backButton);
- QToolButton *forwardButton = qFindChild<QToolButton*>(&fd, "forwardButton");
+ QToolButton *forwardButton = fd.findChild<QToolButton*>("forwardButton");
QVERIFY(forwardButton);
QSignalSpy spy(model, SIGNAL(rootPathChanged(QString)));
@@ -1129,12 +1128,12 @@ void tst_QFiledialog::historyForward()
{
QNonNativeFileDialog fd;
fd.setDirectory(QDir::currentPath());
- QToolButton *backButton = qFindChild<QToolButton*>(&fd, "backButton");
+ QToolButton *backButton = fd.findChild<QToolButton*>("backButton");
QVERIFY(backButton);
- QToolButton *forwardButton = qFindChild<QToolButton*>(&fd, "forwardButton");
+ QToolButton *forwardButton = fd.findChild<QToolButton*>("forwardButton");
QVERIFY(forwardButton);
- QFileSystemModel *model = qFindChild<QFileSystemModel*>(&fd, "qt_filesystem_model");
+ QFileSystemModel *model = fd.findChild<QFileSystemModel*>("qt_filesystem_model");
QVERIFY(model);
QSignalSpy spy(model, SIGNAL(rootPathChanged(QString)));
@@ -1205,7 +1204,7 @@ void tst_QFiledialog::disableSaveButton()
QNonNativeFileDialog fd(0, "caption", path);
fd.setAcceptMode(QFileDialog::AcceptSave);
- QDialogButtonBox *buttonBox = qFindChild<QDialogButtonBox*>(&fd, "buttonBox");
+ QDialogButtonBox *buttonBox = fd.findChild<QDialogButtonBox*>("buttonBox");
QPushButton *button = buttonBox->button(QDialogButtonBox::Save);
QVERIFY(button);
QCOMPARE(button->isEnabled(), isEnabled);
@@ -1236,7 +1235,7 @@ void tst_QFiledialog::saveButtonText()
fd.setLabelText(QFileDialog::Accept, label);
fd.setDirectory(QDir::temp());
fd.selectFile(path);
- QDialogButtonBox *buttonBox = qFindChild<QDialogButtonBox*>(&fd, "buttonBox");
+ QDialogButtonBox *buttonBox = fd.findChild<QDialogButtonBox*>("buttonBox");
QVERIFY(buttonBox);
QPushButton *button = buttonBox->button(QDialogButtonBox::Save);
QVERIFY(button);
@@ -1254,12 +1253,12 @@ void tst_QFiledialog::clearLineEdit()
//play it really safe by creating a directory
QDir::home().mkdir("_____aaaaaaaaaaaaaaaaaaaaaa");
- QLineEdit *lineEdit = qFindChild<QLineEdit*>(&fd, "fileNameEdit");
+ QLineEdit *lineEdit = fd.findChild<QLineEdit*>("fileNameEdit");
QVERIFY(lineEdit);
QVERIFY(lineEdit->text() == "foo");
fd.setDirectory(QDir::home());
- QListView* list = qFindChild<QListView*>(&fd, "listView");
+ QListView* list = fd.findChild<QListView*>("listView");
QVERIFY(list);
// saving a file the text shouldn't be cleared
@@ -1309,7 +1308,7 @@ void tst_QFiledialog::enableChooseButton()
QNonNativeFileDialog fd;
fd.setFileMode(QFileDialog::Directory);
fd.show();
- QDialogButtonBox *buttonBox = qFindChild<QDialogButtonBox*>(&fd, "buttonBox");
+ QDialogButtonBox *buttonBox = fd.findChild<QDialogButtonBox*>("buttonBox");
QPushButton *button = buttonBox->button(QDialogButtonBox::Open);
QVERIFY(button);
QCOMPARE(button->isEnabled(), true);
diff --git a/tests/auto/widgets/dialogs/qfiledialog2/qfiledialog2.pro b/tests/auto/widgets/dialogs/qfiledialog2/qfiledialog2.pro
index efa123cdd7..db36eea11d 100644
--- a/tests/auto/widgets/dialogs/qfiledialog2/qfiledialog2.pro
+++ b/tests/auto/widgets/dialogs/qfiledialog2/qfiledialog2.pro
@@ -19,4 +19,3 @@ wince* {
} else {
DEFINES += SRCDIR=\\\"$$PWD/\\\"
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/dialogs/qfiledialog2/tst_qfiledialog2.cpp b/tests/auto/widgets/dialogs/qfiledialog2/tst_qfiledialog2.cpp
index 018021ddac..98b096031e 100644
--- a/tests/auto/widgets/dialogs/qfiledialog2/tst_qfiledialog2.cpp
+++ b/tests/auto/widgets/dialogs/qfiledialog2/tst_qfiledialog2.cpp
@@ -257,7 +257,7 @@ void tst_QFileDialog2::deleteDirAndFiles()
void tst_QFileDialog2::filter()
{
QNonNativeFileDialog fd;
- QAction *hiddenAction = qFindChild<QAction*>(&fd, "qt_show_hidden_action");
+ QAction *hiddenAction = fd.findChild<QAction*>("qt_show_hidden_action");
QVERIFY(hiddenAction);
QVERIFY(hiddenAction->isEnabled());
QVERIFY(!hiddenAction->isChecked());
@@ -270,7 +270,7 @@ void tst_QFileDialog2::filter()
void tst_QFileDialog2::showNameFilterDetails()
{
QNonNativeFileDialog fd;
- QComboBox *filters = qFindChild<QComboBox*>(&fd, "fileTypeCombo");
+ QComboBox *filters = fd.findChild<QComboBox*>("fileTypeCombo");
QVERIFY(filters);
QVERIFY(fd.isNameFilterDetailsVisible());
@@ -302,7 +302,7 @@ void tst_QFileDialog2::unc()
#endif
QVERIFY(QFile::exists(dir));
QNonNativeFileDialog fd(0, QString(), dir);
- QFileSystemModel *model = qFindChild<QFileSystemModel*>(&fd, "qt_filesystem_model");
+ QFileSystemModel *model = fd.findChild<QFileSystemModel*>("qt_filesystem_model");
QVERIFY(model);
QCOMPARE(model->index(fd.directory().absolutePath()), model->index(dir));
}
@@ -311,12 +311,12 @@ void tst_QFileDialog2::emptyUncPath()
{
QNonNativeFileDialog fd;
fd.show();
- QLineEdit *lineEdit = qFindChild<QLineEdit*>(&fd, "fileNameEdit");
+ QLineEdit *lineEdit = fd.findChild<QLineEdit*>("fileNameEdit");
QVERIFY(lineEdit);
// press 'keys' for the input
for (int i = 0; i < 3 ; ++i)
QTest::keyPress(lineEdit, Qt::Key_Backslash);
- QFileSystemModel *model = qFindChild<QFileSystemModel*>(&fd, "qt_filesystem_model");
+ QFileSystemModel *model = fd.findChild<QFileSystemModel*>("qt_filesystem_model");
QVERIFY(model);
}
@@ -327,7 +327,7 @@ struct MenuCloser : public QObject {
void close()
{
- QMenu *menu = qFindChild<QMenu*>(w);
+ QMenu *menu = w->findChild<QMenu*>();
if (!menu) {
qDebug("%s: cannot find file dialog child of type QMenu", Q_FUNC_INFO);
w->close();
@@ -337,7 +337,7 @@ struct MenuCloser : public QObject {
};
static bool openContextMenu(QFileDialog &fd)
{
- QListView *list = qFindChild<QListView*>(&fd, "listView");
+ QListView *list = fd.findChild<QListView*>("listView");
if (!list) {
qDebug("%s: didn't find file dialog child \"listView\"", Q_FUNC_INFO);
return false;
@@ -386,9 +386,9 @@ void tst_QFileDialog2::task143519_deleteAndRenameActionBehavior()
QTest::qWaitForWindowActive(&fd);
// grab some internals:
- QAction *rm = qFindChild<QAction*>(&fd, "qt_delete_action");
+ QAction *rm = fd.findChild<QAction*>("qt_delete_action");
QVERIFY(rm);
- QAction *mv = qFindChild<QAction*>(&fd, "qt_rename_action");
+ QAction *mv = fd.findChild<QAction*>("qt_rename_action");
QVERIFY(mv);
// these are the real test cases:
@@ -458,7 +458,7 @@ void tst_QFileDialog2::task180459_lastDirectory()
{
//first visit the temp directory and close the dialog
QNonNativeFileDialog *dlg = new QNonNativeFileDialog(0, "", tempDir.path());
- QFileSystemModel *model = qFindChild<QFileSystemModel*>(dlg, "qt_filesystem_model");
+ QFileSystemModel *model = dlg->findChild<QFileSystemModel*>("qt_filesystem_model");
QVERIFY(model);
QCOMPARE(model->index(tempDir.path()), model->index(dlg->directory().absolutePath()));
delete dlg;
@@ -469,12 +469,12 @@ void tst_QFileDialog2::task180459_lastDirectory()
QFETCH(QString, result);
dlg = new QNonNativeFileDialog(0, "", path);
- model = qFindChild<QFileSystemModel*>(dlg, "qt_filesystem_model");
+ model = dlg->findChild<QFileSystemModel*>("qt_filesystem_model");
QVERIFY(model);
dlg->setAcceptMode(QFileDialog::AcceptSave);
QCOMPARE(model->index(dlg->directory().absolutePath()), model->index(directory));
- QDialogButtonBox *buttonBox = qFindChild<QDialogButtonBox*>(dlg, "buttonBox");
+ QDialogButtonBox *buttonBox = dlg->findChild<QDialogButtonBox*>("buttonBox");
QPushButton *button = buttonBox->button(QDialogButtonBox::Save);
QVERIFY(button);
QCOMPARE(button->isEnabled(), isEnabled);
@@ -564,7 +564,7 @@ void tst_QFileDialog2::task227304_proxyOnFileDialog()
QNonNativeFileDialog fd(0, "", QDir::currentPath(), 0);
fd.setProxyModel(new FilterDirModel(QDir::currentPath()));
fd.show();
- QLineEdit *edit = qFindChild<QLineEdit*>(&fd, "fileNameEdit");
+ QLineEdit *edit = fd.findChild<QLineEdit*>("fileNameEdit");
QTest::qWait(200);
QTest::keyClick(edit, Qt::Key_T);
QTest::keyClick(edit, Qt::Key_S);
@@ -575,7 +575,7 @@ void tst_QFileDialog2::task227304_proxyOnFileDialog()
dialog->setFileMode(QFileDialog::ExistingFile);
dialog->show();
- QListView *list = qFindChild<QListView*>(dialog, "listView");
+ QListView *list = dialog->findChild<QListView*>("listView");
QTest::qWait(200);
QTest::keyClick(list, Qt::Key_Down);
QTest::keyClick(list, Qt::Key_Return);
@@ -588,7 +588,7 @@ void tst_QFileDialog2::task227304_proxyOnFileDialog()
QSortFilterProxyModel *pm = new QSortFilterProxyModel;
fd2.setProxyModel(pm);
fd2.show();
- QSidebar *sidebar = qFindChild<QSidebar*>(&fd2, "sidebar");
+ QSidebar *sidebar = fd2.findChild<QSidebar*>("sidebar");
sidebar->setFocus();
sidebar->selectUrl(QUrl::fromLocalFile(QDir::homePath()));
QTest::mouseClick(sidebar->viewport(), Qt::LeftButton, 0, sidebar->visualRect(sidebar->model()->index(1, 0)).center());
@@ -616,7 +616,7 @@ void tst_QFileDialog2::task227930_correctNavigationKeyboardBehavior()
fd.setViewMode(QFileDialog::List);
fd.setDirectory(current.absolutePath());
fd.show();
- QListView *list = qFindChild<QListView*>(&fd, "listView");
+ QListView *list = fd.findChild<QListView*>("listView");
QTest::qWait(200);
QTest::keyClick(list, Qt::Key_Down);
QTest::keyClick(list, Qt::Key_Return);
@@ -646,8 +646,8 @@ void tst_QFileDialog2::task226366_lowerCaseHardDriveWindows()
QNonNativeFileDialog fd;
fd.setDirectory(QDir::root().path());
fd.show();
- QLineEdit *edit = qFindChild<QLineEdit*>(&fd, "fileNameEdit");
- QToolButton *buttonParent = qFindChild<QToolButton*>(&fd, "toParentButton");
+ QLineEdit *edit = fd.findChild<QLineEdit*>("fileNameEdit");
+ QToolButton *buttonParent = fd.findChild<QToolButton*>("toParentButton");
QTest::qWait(200);
QTest::mouseClick(buttonParent, Qt::LeftButton,0,QPoint(0,0));
QTest::qWait(2000);
@@ -712,7 +712,7 @@ void tst_QFileDialog2::completionOnLevelAfterRoot()
QSKIP("This test requires to have an etc directory under /");
#endif
fd.show();
- QLineEdit *edit = qFindChild<QLineEdit*>(&fd, "fileNameEdit");
+ QLineEdit *edit = fd.findChild<QLineEdit*>("fileNameEdit");
QTest::qWait(2000);
#if defined(Q_OS_WIN) && !defined(Q_OS_WINCE)
//I love testlib :D
@@ -741,14 +741,14 @@ void tst_QFileDialog2::task233037_selectingDirectory()
fd.setDirectory(current.absolutePath());
fd.setAcceptMode( QFileDialog::AcceptSave);
fd.show();
- QListView *list = qFindChild<QListView*>(&fd, "listView");
+ QListView *list = fd.findChild<QListView*>("listView");
QTest::qWait(3000); // Wait for sort to settle (I need a signal).
#ifdef QT_KEYPAD_NAVIGATION
list->setEditFocus(true);
#endif
QTest::keyClick(list, Qt::Key_Down);
QTest::qWait(100);
- QDialogButtonBox *buttonBox = qFindChild<QDialogButtonBox*>(&fd, "buttonBox");
+ QDialogButtonBox *buttonBox = fd.findChild<QDialogButtonBox*>("buttonBox");
QPushButton *button = buttonBox->button(QDialogButtonBox::Save);
QVERIFY(button);
QCOMPARE(button->isEnabled(), true);
@@ -763,7 +763,7 @@ void tst_QFileDialog2::task235069_hideOnEscape()
fd.setDirectory(current.absolutePath());
fd.setAcceptMode( QFileDialog::AcceptSave);
fd.show();
- QListView *list = qFindChild<QListView*>(&fd, "listView");
+ QListView *list = fd.findChild<QListView*>("listView");
list->setFocus();
QTest::qWait(200);
QTest::keyClick(list, Qt::Key_Escape);
@@ -772,7 +772,7 @@ void tst_QFileDialog2::task235069_hideOnEscape()
fd2.setDirectory(current.absolutePath());
fd2.setAcceptMode( QFileDialog::AcceptSave);
fd2.show();
- QLineEdit *edit = qFindChild<QLineEdit*>(&fd2, "fileNameEdit");
+ QLineEdit *edit = fd2.findChild<QLineEdit*>("fileNameEdit");
QTest::keyClick(edit, Qt::Key_Escape);
QCOMPARE(fd2.isVisible(), false);
}
@@ -789,7 +789,7 @@ void tst_QFileDialog2::task236402_dontWatchDeletedDir()
fd.setDirectory(current.absolutePath());
fd.setAcceptMode( QFileDialog::AcceptSave);
fd.show();
- QListView *list = qFindChild<QListView*>(&fd, "listView");
+ QListView *list = fd.findChild<QListView*>("listView");
list->setFocus();
QTest::qWait(200);
QTest::keyClick(list, Qt::Key_Return);
@@ -812,12 +812,12 @@ void tst_QFileDialog2::task203703_returnProperSeparator()
fd.setFileMode(QFileDialog::Directory);
fd.show();
QTest::qWait(500);
- QListView *list = qFindChild<QListView*>(&fd, "listView");
+ QListView *list = fd.findChild<QListView*>("listView");
list->setFocus();
QTest::qWait(200);
QTest::keyClick(list, Qt::Key_Return);
QTest::qWait(1000);
- QDialogButtonBox *buttonBox = qFindChild<QDialogButtonBox*>(&fd, "buttonBox");
+ QDialogButtonBox *buttonBox = fd.findChild<QDialogButtonBox*>("buttonBox");
QPushButton *button = buttonBox->button(QDialogButtonBox::Cancel);
QTest::keyClick(button, Qt::Key_Return);
QTest::qWait(500);
@@ -852,10 +852,10 @@ void tst_QFileDialog2::task228844_ensurePreviousSorting()
#else
QTest::qWait(500);
#endif
- QTreeView *tree = qFindChild<QTreeView*>(&fd, "treeView");
+ QTreeView *tree = fd.findChild<QTreeView*>("treeView");
tree->header()->setSortIndicator(3,Qt::DescendingOrder);
QTest::qWait(200);
- QDialogButtonBox *buttonBox = qFindChild<QDialogButtonBox*>(&fd, "buttonBox");
+ QDialogButtonBox *buttonBox = fd.findChild<QDialogButtonBox*>("buttonBox");
QPushButton *button = buttonBox->button(QDialogButtonBox::Open);
QTest::mouseClick(button, Qt::LeftButton);
#if defined(Q_OS_WINCE)
@@ -874,12 +874,12 @@ void tst_QFileDialog2::task228844_ensurePreviousSorting()
#else
QTest::qWait(500);
#endif
- QTreeView *tree2 = qFindChild<QTreeView*>(&fd2, "treeView");
+ QTreeView *tree2 = fd2.findChild<QTreeView*>("treeView");
tree2->setFocus();
QCOMPARE(tree2->rootIndex().data(QFileSystemModel::FilePathRole).toString(),current.absolutePath());
- QDialogButtonBox *buttonBox2 = qFindChild<QDialogButtonBox*>(&fd2, "buttonBox");
+ QDialogButtonBox *buttonBox2 = fd2.findChild<QDialogButtonBox*>("buttonBox");
QPushButton *button2 = buttonBox2->button(QDialogButtonBox::Open);
fd2.selectFile("g");
QTest::mouseClick(button2, Qt::LeftButton);
@@ -899,12 +899,12 @@ void tst_QFileDialog2::task228844_ensurePreviousSorting()
#else
QTest::qWait(500);
#endif
- QTreeView *tree3 = qFindChild<QTreeView*>(&fd3, "treeView");
+ QTreeView *tree3 = fd3.findChild<QTreeView*>("treeView");
tree3->setFocus();
QCOMPARE(tree3->rootIndex().data(QFileSystemModel::FilePathRole).toString(), current.absolutePath());
- QDialogButtonBox *buttonBox3 = qFindChild<QDialogButtonBox*>(&fd3, "buttonBox");
+ QDialogButtonBox *buttonBox3 = fd3.findChild<QDialogButtonBox*>("buttonBox");
QPushButton *button3 = buttonBox3->button(QDialogButtonBox::Open);
QTest::mouseClick(button3, Qt::LeftButton);
#if defined(Q_OS_WINCE)
@@ -988,7 +988,7 @@ void tst_QFileDialog2::task251321_sideBarHiddenEntries()
fd.show();
QTest::qWait(250);
- QSidebar *sidebar = qFindChild<QSidebar*>(&fd, "sidebar");
+ QSidebar *sidebar = fd.findChild<QSidebar*>("sidebar");
sidebar->setFocus();
sidebar->selectUrl(QUrl::fromLocalFile(hiddenSubDir.absolutePath()));
QTest::mouseClick(sidebar->viewport(), Qt::LeftButton, 0, sidebar->visualRect(sidebar->model()->index(0, 0)).center());
@@ -999,7 +999,7 @@ void tst_QFileDialog2::task251321_sideBarHiddenEntries()
QTest::qWait(250);
#endif
- QFileSystemModel *model = qFindChild<QFileSystemModel*>(&fd, "qt_filesystem_model");
+ QFileSystemModel *model = fd.findChild<QFileSystemModel*>("qt_filesystem_model");
QCOMPARE(model->rowCount(model->index(hiddenSubDir.absolutePath())), 2);
hiddenSubDir.rmdir("happy2");
@@ -1045,14 +1045,14 @@ void tst_QFileDialog2::task251341_sideBarRemoveEntries()
fd.show();
QTest::qWait(250);
- QSidebar *sidebar = qFindChild<QSidebar*>(&fd, "sidebar");
+ QSidebar *sidebar = fd.findChild<QSidebar*>("sidebar");
sidebar->setFocus();
//We enter in the first bookmark
sidebar->selectUrl(QUrl::fromLocalFile(testSubDir.absolutePath()));
QTest::mouseClick(sidebar->viewport(), Qt::LeftButton, 0, sidebar->visualRect(sidebar->model()->index(0, 0)).center());
QTest::qWait(250);
- QFileSystemModel *model = qFindChild<QFileSystemModel*>(&fd, "qt_filesystem_model");
+ QFileSystemModel *model = fd.findChild<QFileSystemModel*>("qt_filesystem_model");
//There is no file
QCOMPARE(model->rowCount(model->index(testSubDir.absolutePath())), 0);
//Icon is not enabled QUrlModel::EnabledRole
@@ -1116,10 +1116,10 @@ void tst_QFileDialog2::task254490_selectFileMultipleTimes()
fd.show();
QTest::qWait(250);
- QLineEdit *lineEdit = qFindChild<QLineEdit*>(&fd, "fileNameEdit");
+ QLineEdit *lineEdit = fd.findChild<QLineEdit*>("fileNameEdit");
QVERIFY(lineEdit);
QCOMPARE(lineEdit->text(),QLatin1String("new_file.txt"));
- QListView *list = qFindChild<QListView*>(&fd, "listView");
+ QListView *list = fd.findChild<QListView*>("listView");
QVERIFY(list);
QCOMPARE(list->selectionModel()->selectedRows(0).count(), 0);
@@ -1136,7 +1136,7 @@ void tst_QFileDialog2::task257579_sideBarWithNonCleanUrls()
QString url = QString::fromLatin1("%1/%2/..").arg(dir.absolutePath()).arg(dirname);
QNonNativeFileDialog fd;
fd.setSidebarUrls(QList<QUrl>() << QUrl::fromLocalFile(url));
- QSidebar *sidebar = qFindChild<QSidebar*>(&fd, "sidebar");
+ QSidebar *sidebar = fd.findChild<QSidebar*>("sidebar");
QCOMPARE(sidebar->urls().count(), 1);
QVERIFY(sidebar->urls().first().toLocalFile() != url);
QCOMPARE(sidebar->urls().first().toLocalFile(), QDir::cleanPath(url));
@@ -1161,7 +1161,7 @@ void tst_QFileDialog2::task259105_filtersCornerCases()
QTest::qWait(250);
//Extensions are hidden
- QComboBox *filters = qFindChild<QComboBox*>(&fd, "fileTypeCombo");
+ QComboBox *filters = fd.findChild<QComboBox*>("fileTypeCombo");
QVERIFY(filters);
QCOMPARE(filters->currentText(), QLatin1String("All Files!"));
filters->setCurrentIndex(1);
@@ -1215,7 +1215,7 @@ void tst_QFileDialog2::QTBUG4419_lineEditSelectAll()
QCOMPARE(fd.isVisible(), true);
QCOMPARE(QApplication::activeWindow(), static_cast<QWidget*>(&fd));
- QLineEdit *lineEdit = qFindChild<QLineEdit*>(&fd, "fileNameEdit");
+ QLineEdit *lineEdit = fd.findChild<QLineEdit*>("fileNameEdit");
QVERIFY(lineEdit);
QTRY_COMPARE(tempPath + QChar('/') + lineEdit->text(), t->fileName());
@@ -1258,7 +1258,7 @@ void tst_QFileDialog2::QTBUG6558_showDirsOnly()
QCOMPARE(fd.isVisible(), true);
QCOMPARE(QApplication::activeWindow(), static_cast<QWidget*>(&fd));
- QFileSystemModel *model = qFindChild<QFileSystemModel*>(&fd, "qt_filesystem_model");
+ QFileSystemModel *model = fd.findChild<QFileSystemModel*>("qt_filesystem_model");
QTRY_COMPARE(model->rowCount(model->index(dir.absolutePath())), 2);
fd.setOption(QFileDialog::ShowDirsOnly, false);
@@ -1306,7 +1306,7 @@ void tst_QFileDialog2::QTBUG4842_selectFilterWithHideNameFilterDetails()
QCOMPARE(fd.isVisible(), true);
QCOMPARE(QApplication::activeWindow(), static_cast<QWidget*>(&fd));
- QComboBox *filters = qFindChild<QComboBox*>(&fd, "fileTypeCombo");
+ QComboBox *filters = fd.findChild<QComboBox*>("fileTypeCombo");
//We compare the current combobox text with the stripped version
QCOMPARE(filters->currentText(), QString("Text files"));
@@ -1322,7 +1322,7 @@ void tst_QFileDialog2::QTBUG4842_selectFilterWithHideNameFilterDetails()
QCOMPARE(fd2.isVisible(), true);
QCOMPARE(QApplication::activeWindow(), static_cast<QWidget*>(&fd2));
- QComboBox *filters2 = qFindChild<QComboBox*>(&fd2, "fileTypeCombo");
+ QComboBox *filters2 = fd2.findChild<QComboBox*>("fileTypeCombo");
//We compare the current combobox text with the non stripped version
QCOMPARE(filters2->currentText(), chosenFilterString);
@@ -1340,7 +1340,7 @@ void tst_QFileDialog2::dontShowCompleterOnRoot()
QCOMPARE(QApplication::activeWindow(), static_cast<QWidget*>(&fd));
fd.setDirectory("");
- QLineEdit *lineEdit = qFindChild<QLineEdit*>(&fd, "fileNameEdit");
+ QLineEdit *lineEdit = fd.findChild<QLineEdit*>("fileNameEdit");
QTRY_VERIFY(lineEdit->text().isEmpty());
//The gatherer thread will then return the result
diff --git a/tests/auto/widgets/dialogs/qfilesystemmodel/qfilesystemmodel.pro b/tests/auto/widgets/dialogs/qfilesystemmodel/qfilesystemmodel.pro
index 5606033240..e77364c3f0 100644
--- a/tests/auto/widgets/dialogs/qfilesystemmodel/qfilesystemmodel.pro
+++ b/tests/auto/widgets/dialogs/qfilesystemmodel/qfilesystemmodel.pro
@@ -1,12 +1,11 @@
CONFIG += testcase
-CONFIG += parallel_test
-win32:testcase.timeout = 900 # this testcase can be slow on Windows
+# This testcase can be slow on Windows and may interfere with other file system tests.
+win32:testcase.timeout = 900
QT += widgets widgets-private
QT += core-private gui testlib
SOURCES += tst_qfilesystemmodel.cpp
TARGET = tst_qfilesystemmodel
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
mac:CONFIG+=insignificant_test # QTBUG-27890
diff --git a/tests/auto/widgets/dialogs/qfilesystemmodel/tst_qfilesystemmodel.cpp b/tests/auto/widgets/dialogs/qfilesystemmodel/tst_qfilesystemmodel.cpp
index db80aa1b22..e36eaa5af2 100644
--- a/tests/auto/widgets/dialogs/qfilesystemmodel/tst_qfilesystemmodel.cpp
+++ b/tests/auto/widgets/dialogs/qfilesystemmodel/tst_qfilesystemmodel.cpp
@@ -48,6 +48,7 @@
#include <QFileIconProvider>
#include <QTreeView>
#include <QHeaderView>
+#include <QStandardPaths>
#include <QTime>
#include <QStyle>
#include <QtGlobal>
@@ -109,6 +110,7 @@ private slots:
void setData_data();
void setData();
+ void sortPersistentIndex();
void sort_data();
void sort();
@@ -207,27 +209,30 @@ void tst_QFileSystemModel::rootPath()
QCOMPARE(rootChanged.count(), 0);
QString oldRootPath = model->rootPath();
- root = model->setRootPath(QDir::homePath());
+ const QStringList documentPaths = QStandardPaths::standardLocations(QStandardPaths::DocumentsLocation);
+ QVERIFY(!documentPaths.isEmpty());
+ const QString documentPath = documentPaths.front();
+ root = model->setRootPath(documentPath);
QTRY_VERIFY(model->rowCount(root) >= 0);
- QCOMPARE(model->rootPath(), QString(QDir::homePath()));
+ QCOMPARE(model->rootPath(), QString(documentPath));
QCOMPARE(rootChanged.count(), oldRootPath == model->rootPath() ? 0 : 1);
- QCOMPARE(model->rootDirectory().absolutePath(), QDir::homePath());
+ QCOMPARE(model->rootDirectory().absolutePath(), documentPath);
model->setRootPath(QDir::rootPath());
int oldCount = rootChanged.count();
oldRootPath = model->rootPath();
- root = model->setRootPath(QDir::homePath() + QLatin1String("/."));
+ root = model->setRootPath(documentPath + QLatin1String("/."));
QTRY_VERIFY(model->rowCount(root) >= 0);
- QCOMPARE(model->rootPath(), QDir::homePath());
+ QCOMPARE(model->rootPath(), documentPath);
QCOMPARE(rootChanged.count(), oldRootPath == model->rootPath() ? oldCount : oldCount + 1);
- QCOMPARE(model->rootDirectory().absolutePath(), QDir::homePath());
+ QCOMPARE(model->rootDirectory().absolutePath(), documentPath);
- QDir newdir = QDir::home();
+ QDir newdir = documentPath;
if (newdir.cdUp()) {
oldCount = rootChanged.count();
oldRootPath = model->rootPath();
- root = model->setRootPath(QDir::homePath() + QLatin1String("/.."));
+ root = model->setRootPath(documentPath + QLatin1String("/.."));
QTRY_VERIFY(model->rowCount(root) >= 0);
QCOMPARE(model->rootPath(), newdir.path());
QCOMPARE(rootChanged.count(), oldCount + 1);
@@ -310,9 +315,9 @@ void tst_QFileSystemModel::naturalCompare()
void tst_QFileSystemModel::readOnly()
{
QCOMPARE(model->isReadOnly(), true);
- QTemporaryFile file;
+ QTemporaryFile file(flatDirTestPath + QStringLiteral("/XXXXXX.dat"));
file.open();
- QModelIndex root = model->setRootPath(QDir::tempPath());
+ QModelIndex root = model->setRootPath(flatDirTestPath);
QTRY_VERIFY(model->rowCount(root) > 0);
QVERIFY(!(model->flags(model->index(file.fileName())) & Qt::ItemIsEditable));
@@ -358,7 +363,10 @@ void tst_QFileSystemModel::iconProvider()
delete p;
QFileSystemModel *myModel = new QFileSystemModel();
- myModel->setRootPath(QDir::homePath());
+ const QStringList documentPaths = QStandardPaths::standardLocations(QStandardPaths::DocumentsLocation);
+ QVERIFY(!documentPaths.isEmpty());
+ const QString documentPath = documentPaths.front();
+ myModel->setRootPath(documentPath);
//Let's wait to populate the model
QTest::qWait(250);
//We change the provider, icons must me updated
@@ -791,6 +799,19 @@ void tst_QFileSystemModel::setData()
QTRY_COMPARE(model->rowCount(root), files.count());
}
+void tst_QFileSystemModel::sortPersistentIndex()
+{
+ QTemporaryFile file(flatDirTestPath + QStringLiteral("/XXXXXX.dat"));
+ file.open();
+ QModelIndex root = model->setRootPath(flatDirTestPath);
+ QTRY_VERIFY(model->rowCount(root) > 0);
+
+ QPersistentModelIndex idx = model->index(0, 1, root);
+ model->sort(0, Qt::AscendingOrder);
+ model->sort(0, Qt::DescendingOrder);
+ QVERIFY(idx.column() != 0);
+}
+
class MyFriendFileSystemModel : public QFileSystemModel
{
friend class tst_QFileSystemModel;
@@ -806,18 +827,6 @@ void tst_QFileSystemModel::sort_data()
void tst_QFileSystemModel::sort()
{
- QTemporaryFile file;
- file.open();
- QModelIndex root = model->setRootPath(QDir::tempPath());
- QTRY_VERIFY(model->rowCount(root) > 0);
-
- QPersistentModelIndex idx = model->index(0, 1, root);
- model->sort(0, Qt::AscendingOrder);
- model->sort(0, Qt::DescendingOrder);
- QVERIFY(idx.column() != 0);
-
- model->setRootPath(QDir::homePath());
-
QFETCH(bool, fileDialogMode);
MyFriendFileSystemModel *myModel = new MyFriendFileSystemModel();
diff --git a/tests/auto/widgets/dialogs/qfontdialog/qfontdialog.pro b/tests/auto/widgets/dialogs/qfontdialog/qfontdialog.pro
index 6645937329..8116fe379a 100644
--- a/tests/auto/widgets/dialogs/qfontdialog/qfontdialog.pro
+++ b/tests/auto/widgets/dialogs/qfontdialog/qfontdialog.pro
@@ -13,4 +13,3 @@ mac {
# LIBS += -framework Cocoa
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/dialogs/qinputdialog/qinputdialog.pro b/tests/auto/widgets/dialogs/qinputdialog/qinputdialog.pro
index 1ccfa5ec6d..cc479812a8 100644
--- a/tests/auto/widgets/dialogs/qinputdialog/qinputdialog.pro
+++ b/tests/auto/widgets/dialogs/qinputdialog/qinputdialog.pro
@@ -2,6 +2,3 @@ CONFIG += testcase
TARGET = tst_qinputdialog
QT += widgets testlib
SOURCES += tst_qinputdialog.cpp
-
-
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/dialogs/qinputdialog/tst_qinputdialog.cpp b/tests/auto/widgets/dialogs/qinputdialog/tst_qinputdialog.cpp
index 581696c509..7d8077d77d 100644
--- a/tests/auto/widgets/dialogs/qinputdialog/tst_qinputdialog.cpp
+++ b/tests/auto/widgets/dialogs/qinputdialog/tst_qinputdialog.cpp
@@ -153,13 +153,13 @@ void testInvalidateAndRestore(
template <typename SpinBoxType, typename ValueType>
void testGetNumeric(QInputDialog *dialog, SpinBoxType * = 0, ValueType * = 0)
{
- SpinBoxType *sbox = qFindChild<SpinBoxType *>(dialog);
+ SpinBoxType *sbox = dialog->findChild<SpinBoxType *>();
QVERIFY(sbox != 0);
- QLineEdit *ledit = qFindChild<QLineEdit *>(static_cast<QObject *>(sbox));
+ QLineEdit *ledit = static_cast<QObject *>(sbox)->findChild<QLineEdit *>();
QVERIFY(ledit != 0);
- QDialogButtonBox *bbox = qFindChild<QDialogButtonBox *>(dialog);
+ QDialogButtonBox *bbox = dialog->findChild<QDialogButtonBox *>();
QVERIFY(bbox != 0);
QPushButton *okButton = bbox->button(QDialogButtonBox::Ok);
QVERIFY(okButton != 0);
@@ -189,10 +189,10 @@ void testGetNumeric(QInputDialog *dialog, SpinBoxType * = 0, ValueType * = 0)
void testGetText(QInputDialog *dialog)
{
- QLineEdit *ledit = qFindChild<QLineEdit *>(dialog);
+ QLineEdit *ledit = dialog->findChild<QLineEdit *>();
QVERIFY(ledit);
- QDialogButtonBox *bbox = qFindChild<QDialogButtonBox *>(dialog);
+ QDialogButtonBox *bbox = dialog->findChild<QDialogButtonBox *>();
QVERIFY(bbox);
QPushButton *okButton = bbox->button(QDialogButtonBox::Ok);
QVERIFY(okButton);
@@ -207,10 +207,10 @@ void testGetText(QInputDialog *dialog)
void testGetItem(QInputDialog *dialog)
{
- QComboBox *cbox = qFindChild<QComboBox *>(dialog);
+ QComboBox *cbox = dialog->findChild<QComboBox *>();
QVERIFY(cbox);
- QDialogButtonBox *bbox = qFindChild<QDialogButtonBox *>(dialog);
+ QDialogButtonBox *bbox = dialog->findChild<QDialogButtonBox *>();
QVERIFY(bbox);
QPushButton *okButton = bbox->button(QDialogButtonBox::Ok);
QVERIFY(okButton);
@@ -245,7 +245,7 @@ void tst_QInputDialog::testFuncGetItem(QInputDialog *dialog)
void tst_QInputDialog::timerEvent(QTimerEvent *event)
{
killTimer(event->timerId());
- QInputDialog *dialog = qFindChild<QInputDialog *>(parent);
+ QInputDialog *dialog = parent->findChild<QInputDialog *>();
QVERIFY(dialog);
if (testFunc)
testFunc(dialog);
diff --git a/tests/auto/widgets/dialogs/qmessagebox/qmessagebox.pro b/tests/auto/widgets/dialogs/qmessagebox/qmessagebox.pro
index 60040282bb..e9f220101b 100644
--- a/tests/auto/widgets/dialogs/qmessagebox/qmessagebox.pro
+++ b/tests/auto/widgets/dialogs/qmessagebox/qmessagebox.pro
@@ -5,4 +5,3 @@ CONFIG += testcase
CONFIG += parallel_test
SOURCES += tst_qmessagebox.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/dialogs/qprogressdialog/qprogressdialog.pro b/tests/auto/widgets/dialogs/qprogressdialog/qprogressdialog.pro
index 0cc956679a..290374f825 100644
--- a/tests/auto/widgets/dialogs/qprogressdialog/qprogressdialog.pro
+++ b/tests/auto/widgets/dialogs/qprogressdialog/qprogressdialog.pro
@@ -7,6 +7,3 @@ CONFIG += parallel_test
TARGET = tst_qprogressdialog
QT += widgets testlib
SOURCES += tst_qprogressdialog.cpp
-
-
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/dialogs/qprogressdialog/tst_qprogressdialog.cpp b/tests/auto/widgets/dialogs/qprogressdialog/tst_qprogressdialog.cpp
index 09f115a489..d49f356d8c 100644
--- a/tests/auto/widgets/dialogs/qprogressdialog/tst_qprogressdialog.cpp
+++ b/tests/auto/widgets/dialogs/qprogressdialog/tst_qprogressdialog.cpp
@@ -141,7 +141,7 @@ void tst_QProgressDialog::task198202()
QProgressDialog dlg(QLatin1String("test"),QLatin1String("test"),1,10);
dlg.show();
QVERIFY(QTest::qWaitForWindowExposed(&dlg));
- int futureHeight = dlg.sizeHint().height() - qFindChild<QLabel*>(&dlg)->sizeHint().height();
+ int futureHeight = dlg.sizeHint().height() - dlg.findChild<QLabel*>()->sizeHint().height();
dlg.setLabel(0);
QTest::ignoreMessage(QtWarningMsg, "QProgressDialog::setBar: Cannot set a null progress bar");
dlg.setBar(0);
diff --git a/tests/auto/widgets/dialogs/qwizard/qwizard.pro b/tests/auto/widgets/dialogs/qwizard/qwizard.pro
index 193c6585a0..a1d72e854a 100644
--- a/tests/auto/widgets/dialogs/qwizard/qwizard.pro
+++ b/tests/auto/widgets/dialogs/qwizard/qwizard.pro
@@ -4,4 +4,3 @@ TARGET = tst_qwizard
QT += widgets testlib
SOURCES += tst_qwizard.cpp tst_qwizard_2.cpp
RESOURCES = qwizard.qrc
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/dialogs/qwizard/tst_qwizard.cpp b/tests/auto/widgets/dialogs/qwizard/tst_qwizard.cpp
index 3922cce5cc..c3fc050275 100644
--- a/tests/auto/widgets/dialogs/qwizard/tst_qwizard.cpp
+++ b/tests/auto/widgets/dialogs/qwizard/tst_qwizard.cpp
@@ -611,7 +611,7 @@ void tst_QWizard::addPage()
arguments = spy.takeFirst();
QCOMPARE(arguments.at(0).toInt(), N + 52);
- QTest::ignoreMessage(QtWarningMsg,"QWizard::setPage: Cannot insert null page");
+ QTest::ignoreMessage(QtWarningMsg,"QWizard::setPage: Cannot insert null page");
wizard.addPage(0); // generates a warning
QCOMPARE(spy.count(), 0);
delete parent;
@@ -638,7 +638,7 @@ void tst_QWizard::setPage()
QCOMPARE(wizard.nextId(), -1);
page = new QWizardPage(parent);
- QTest::ignoreMessage(QtWarningMsg,"QWizard::setPage: Cannot insert page with ID -1");
+ QTest::ignoreMessage(QtWarningMsg,"QWizard::setPage: Cannot insert page with ID -1");
wizard.setPage(-1, page); // gives a warning and does nothing
QCOMPARE(spy.count(), 0);
QVERIFY(!wizard.page(-2));
@@ -2453,7 +2453,7 @@ private:
QLayout *layout_ = new QVBoxLayout(this);
layout_->addWidget(treeWidget = new QTreeWidget);
-
+
QSizePolicy policy = sizePolicy();
policy.setVerticalPolicy(verticalPolicy);
treeWidget->setSizePolicy(policy);
@@ -2518,7 +2518,7 @@ void tst_QWizard::task161658_alignments()
wizard.show();
QVERIFY(QTest::qWaitForWindowExposed(&wizard));
- foreach (QLabel *subtitleLabel, qFindChildren<QLabel *>(&wizard)) {
+ foreach (QLabel *subtitleLabel, wizard.findChildren<QLabel *>()) {
if (subtitleLabel->text().startsWith("SUBTITLE#")) {
QCOMPARE(lineEdit1.mapToGlobal(lineEdit1.contentsRect().bottomRight()).x(),
subtitleLabel->mapToGlobal(subtitleLabel->contentsRect().bottomRight()).x());
diff --git a/tests/auto/widgets/effects/qpixmapfilter/qpixmapfilter.pro b/tests/auto/widgets/effects/qpixmapfilter/qpixmapfilter.pro
index 542c6959d1..879d31604b 100644
--- a/tests/auto/widgets/effects/qpixmapfilter/qpixmapfilter.pro
+++ b/tests/auto/widgets/effects/qpixmapfilter/qpixmapfilter.pro
@@ -13,4 +13,3 @@ wince*: {
DEPLOYMENT += addFiles
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicsanchorlayout/qgraphicsanchorlayout.pro b/tests/auto/widgets/graphicsview/qgraphicsanchorlayout/qgraphicsanchorlayout.pro
index df4aaf6e3b..3eb18e61eb 100644
--- a/tests/auto/widgets/graphicsview/qgraphicsanchorlayout/qgraphicsanchorlayout.pro
+++ b/tests/auto/widgets/graphicsview/qgraphicsanchorlayout/qgraphicsanchorlayout.pro
@@ -4,4 +4,3 @@ QT += widgets widgets-private testlib
QT += core-private gui-private
SOURCES += tst_qgraphicsanchorlayout.cpp
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/qgraphicsanchorlayout1.pro b/tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/qgraphicsanchorlayout1.pro
index 12a7b8e4e3..6e8717c86d 100644
--- a/tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/qgraphicsanchorlayout1.pro
+++ b/tests/auto/widgets/graphicsview/qgraphicsanchorlayout1/qgraphicsanchorlayout1.pro
@@ -4,4 +4,3 @@ QT += widgets widgets-private testlib
QT += core-private gui-private
SOURCES += tst_qgraphicsanchorlayout1.cpp
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicseffectsource/qgraphicseffectsource.pro b/tests/auto/widgets/graphicsview/qgraphicseffectsource/qgraphicseffectsource.pro
index 3aeaef318e..4fe3405d11 100644
--- a/tests/auto/widgets/graphicsview/qgraphicseffectsource/qgraphicseffectsource.pro
+++ b/tests/auto/widgets/graphicsview/qgraphicseffectsource/qgraphicseffectsource.pro
@@ -6,4 +6,3 @@ QT += core-private gui-private
SOURCES += tst_qgraphicseffectsource.cpp
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicseffectsource/tst_qgraphicseffectsource.cpp b/tests/auto/widgets/graphicsview/qgraphicseffectsource/tst_qgraphicseffectsource.cpp
index c5863c9dc3..20d58b5f6b 100644
--- a/tests/auto/widgets/graphicsview/qgraphicseffectsource/tst_qgraphicseffectsource.cpp
+++ b/tests/auto/widgets/graphicsview/qgraphicseffectsource/tst_qgraphicseffectsource.cpp
@@ -260,7 +260,7 @@ void tst_QGraphicsEffectSource::boundingRect()
QCOMPARE(effect->source()->boundingRect(Qt::DeviceCoordinates), QRectF());
QRectF itemBoundingRect = item->boundingRect();
- if (!item->children().isEmpty())
+ if (!item->childItems().isEmpty())
itemBoundingRect |= item->childrenBoundingRect();
// We can at least check that the device bounding rect was correct in QGraphicsEffect::draw.
diff --git a/tests/auto/widgets/graphicsview/qgraphicsgridlayout/qgraphicsgridlayout.pro b/tests/auto/widgets/graphicsview/qgraphicsgridlayout/qgraphicsgridlayout.pro
index 9b1fa1b0c2..5796cbfd73 100644
--- a/tests/auto/widgets/graphicsview/qgraphicsgridlayout/qgraphicsgridlayout.pro
+++ b/tests/auto/widgets/graphicsview/qgraphicsgridlayout/qgraphicsgridlayout.pro
@@ -4,4 +4,3 @@ TARGET = tst_qgraphicsgridlayout
QT += widgets testlib
SOURCES += tst_qgraphicsgridlayout.cpp
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicsgridlayout/tst_qgraphicsgridlayout.cpp b/tests/auto/widgets/graphicsview/qgraphicsgridlayout/tst_qgraphicsgridlayout.cpp
index fb55cf3d8f..41e5ed466c 100644
--- a/tests/auto/widgets/graphicsview/qgraphicsgridlayout/tst_qgraphicsgridlayout.cpp
+++ b/tests/auto/widgets/graphicsview/qgraphicsgridlayout/tst_qgraphicsgridlayout.cpp
@@ -1549,7 +1549,7 @@ void tst_QGraphicsGridLayout::setColumnSpacing()
}
void tst_QGraphicsGridLayout::setGeometry_data()
-{
+{
QTest::addColumn<QRectF>("rect");
QTest::newRow("null") << QRectF();
QTest::newRow("normal") << QRectF(0,0, 50, 50);
diff --git a/tests/auto/widgets/graphicsview/qgraphicsitem/tst_qgraphicsitem.cpp b/tests/auto/widgets/graphicsview/qgraphicsitem/tst_qgraphicsitem.cpp
index b14e68951b..37190c3cf2 100644
--- a/tests/auto/widgets/graphicsview/qgraphicsitem/tst_qgraphicsitem.cpp
+++ b/tests/auto/widgets/graphicsview/qgraphicsitem/tst_qgraphicsitem.cpp
@@ -424,6 +424,7 @@ private slots:
void activate();
void setActivePanelOnInactiveScene();
void activationOnShowHide();
+ void deactivateInactivePanel();
void moveWhileDeleting();
void ensureDirtySceneTransform();
void focusScope();
@@ -548,7 +549,7 @@ void tst_QGraphicsItem::construction()
QCOMPARE(item->scene(), (QGraphicsScene *)0);
QCOMPARE(item->parentItem(), (QGraphicsItem *)0);
- QVERIFY(item->children().isEmpty());
+ QVERIFY(item->childItems().isEmpty());
QVERIFY(item->isVisible());
QVERIFY(item->isEnabled());
QVERIFY(!item->isSelected());
@@ -588,7 +589,7 @@ public:
QRectF boundingRect() const
{
QRectF tmp = QGraphicsRectItem::boundingRect();
- foreach (QGraphicsItem *child, children())
+ foreach (QGraphicsItem *child, childItems())
tmp |= child->boundingRect(); // <- might be pure virtual
return tmp;
}
@@ -604,11 +605,11 @@ void tst_QGraphicsItem::constructionWithParent()
scene.addItem(item0);
scene.addItem(item1);
QGraphicsItem *item2 = new BoundingRectItem(item1);
- QCOMPARE(item1->children(), QList<QGraphicsItem *>() << item2);
+ QCOMPARE(item1->childItems(), QList<QGraphicsItem *>() << item2);
QCOMPARE(item1->boundingRect(), QRectF(0, 0, 200, 200));
item2->setParentItem(item0);
- QCOMPARE(item0->children(), QList<QGraphicsItem *>() << item2);
+ QCOMPARE(item0->childItems(), QList<QGraphicsItem *>() << item2);
QCOMPARE(item0->boundingRect(), QRectF(0, 0, 200, 200));
}
@@ -635,9 +636,9 @@ void tst_QGraphicsItem::destruction()
QGraphicsItem *parent = new QGraphicsRectItem;
Item *child = new Item;
child->setParentItem(parent);
- QCOMPARE(parent->children().size(), 1);
+ QCOMPARE(parent->childItems().size(), 1);
delete child;
- QCOMPARE(parent->children().size(), 0);
+ QCOMPARE(parent->childItems().size(), 0);
delete parent;
QCOMPARE(itemDeleted, 2);
}
@@ -660,9 +661,9 @@ void tst_QGraphicsItem::destruction()
child->setParentItem(parent);
scene.addItem(parent);
QCOMPARE(child->scene(), &scene);
- QCOMPARE(parent->children().size(), 1);
+ QCOMPARE(parent->childItems().size(), 1);
delete child;
- QCOMPARE(parent->children().size(), 0);
+ QCOMPARE(parent->childItems().size(), 0);
delete parent;
QCOMPARE(itemDeleted, 4);
}
@@ -691,7 +692,7 @@ void tst_QGraphicsItem::destruction()
QCOMPARE(child->scene(), (QGraphicsScene *)0);
QCOMPARE(parent->scene(), &scene);
QCOMPARE(child->parentItem(), (QGraphicsItem *)0);
- QVERIFY(parent->children().isEmpty());
+ QVERIFY(parent->childItems().isEmpty());
delete parent;
QCOMPARE(itemDeleted, 5);
delete child;
@@ -861,15 +862,15 @@ void tst_QGraphicsItem::setParentItem()
void tst_QGraphicsItem::children()
{
QGraphicsRectItem item;
- QVERIFY(item.children().isEmpty());
+ QVERIFY(item.childItems().isEmpty());
QGraphicsRectItem *item2 = new QGraphicsRectItem(QRectF(), &item);
- QCOMPARE(item.children().size(), 1);
- QCOMPARE(item.children().first(), (QGraphicsItem *)item2);
- QVERIFY(item2->children().isEmpty());
+ QCOMPARE(item.childItems().size(), 1);
+ QCOMPARE(item.childItems().first(), (QGraphicsItem *)item2);
+ QVERIFY(item2->childItems().isEmpty());
delete item2;
- QVERIFY(item.children().isEmpty());
+ QVERIFY(item.childItems().isEmpty());
}
void tst_QGraphicsItem::flags()
@@ -2204,7 +2205,6 @@ void tst_QGraphicsItem::sceneMatrix()
void tst_QGraphicsItem::setMatrix()
{
QGraphicsScene scene;
- qRegisterMetaType<QList<QRectF> >("QList<QRectF>");
QSignalSpy spy(&scene, SIGNAL(changed(QList<QRectF>)));
QRectF unrotatedRect(-12, -34, 56, 78);
QGraphicsRectItem item(unrotatedRect, 0);
@@ -3573,7 +3573,7 @@ void tst_QGraphicsItem::group()
QCOMPARE(parent->sceneBoundingRect(), parentSceneBoundingRect);
QCOMPARE(parent->parentItem(), (QGraphicsItem *)group);
- QCOMPARE(group->children().size(), 1);
+ QCOMPARE(group->childItems().size(), 1);
QCOMPARE(scene.items().size(), 4);
QCOMPARE(scene.items(group->sceneBoundingRect()).size(), 3);
@@ -3585,7 +3585,7 @@ void tst_QGraphicsItem::group()
QCOMPARE(parent2->sceneBoundingRect(), parent2SceneBoundingRect);
QCOMPARE(parent2->parentItem(), (QGraphicsItem *)group);
- QCOMPARE(group->children().size(), 2);
+ QCOMPARE(group->childItems().size(), 2);
QCOMPARE(scene.items().size(), 4);
QCOMPARE(scene.items(group->sceneBoundingRect()).size(), 4);
@@ -3686,7 +3686,7 @@ void tst_QGraphicsItem::nestedGroups()
QCOMPARE(rect->group(), group1);
QCOMPARE(rect2->group(), group1);
QCOMPARE(group1->group(), (QGraphicsItemGroup *)0);
- QVERIFY(group2->children().isEmpty());
+ QVERIFY(group2->childItems().isEmpty());
delete group2;
}
@@ -3737,7 +3737,7 @@ void tst_QGraphicsItem::removeFromGroup()
QGraphicsItemGroup *group = scene.createItemGroup(scene.selectedItems());
QVERIFY(group);
- QCOMPARE(group->children().size(), 2);
+ QCOMPARE(group->childItems().size(), 2);
qApp->processEvents(); // index items
qApp->processEvents(); // emit changed
@@ -4505,10 +4505,10 @@ protected:
case QGraphicsItem::ItemParentHasChanged:
break;
case QGraphicsItem::ItemChildAddedChange:
- oldValues << children().size();
+ oldValues << childItems().size();
break;
case QGraphicsItem::ItemChildRemovedChange:
- oldValues << children().size();
+ oldValues << childItems().size();
break;
case QGraphicsItem::ItemSceneChange:
oldValues << QVariant::fromValue<QGraphicsScene *>(scene());
@@ -9030,6 +9030,40 @@ public:
}
};
+void tst_QGraphicsItem::deactivateInactivePanel()
+{
+ QGraphicsScene scene;
+ QGraphicsItem *panel1 = scene.addRect(QRectF(0, 0, 10, 10));
+ panel1->setFlag(QGraphicsItem::ItemIsPanel);
+
+ QGraphicsItem *panel2 = scene.addRect(QRectF(0, 0, 10, 10));
+ panel2->setFlag(QGraphicsItem::ItemIsPanel);
+
+ QEvent event(QEvent::WindowActivate);
+ qApp->sendEvent(&scene, &event);
+
+ panel1->setActive(true);
+ QVERIFY(scene.isActive());
+ QVERIFY(panel1->isActive());
+ QVERIFY(!panel2->isActive());
+ QCOMPARE(scene.activePanel(), panel1);
+
+ panel2->setActive(true);
+ QVERIFY(panel2->isActive());
+ QVERIFY(!panel1->isActive());
+ QCOMPARE(scene.activePanel(), panel2);
+
+ panel2->setActive(false);
+ QVERIFY(panel1->isActive());
+ QVERIFY(!panel2->isActive());
+ QCOMPARE(scene.activePanel(), panel1);
+
+ panel2->setActive(false);
+ QVERIFY(panel1->isActive());
+ QVERIFY(!panel2->isActive());
+ QCOMPARE(scene.activePanel(), panel1);
+}
+
void tst_QGraphicsItem::moveWhileDeleting()
{
QGraphicsScene scene;
@@ -10333,23 +10367,24 @@ void tst_QGraphicsItem::modality_clickFocus()
EventSpy2 rect1Spy(&scene, rect1);
EventSpy2 rect2Spy(&scene, rect2);
- // activate rect1, it should not get focus
+ // activate rect1, it should get focus
rect1->setActive(true);
- QCOMPARE(scene.focusItem(), (QGraphicsItem *) 0);
+ QCOMPARE(scene.focusItem(), (QGraphicsItem *) rect1);
- // focus stays unset when rect2 becomes modal
+ // focus stays when rect2 becomes modal
rect2->setPanelModality(QGraphicsItem::SceneModal);
- QCOMPARE(scene.focusItem(), (QGraphicsItem *) 0);
- QCOMPARE(rect1Spy.counts[QEvent::FocusIn], 0);
+ QCOMPARE(scene.focusItem(), (QGraphicsItem *) rect1);
+ QCOMPARE(rect1Spy.counts[QEvent::FocusIn], 1);
QCOMPARE(rect1Spy.counts[QEvent::FocusOut], 0);
QCOMPARE(rect2Spy.counts[QEvent::FocusIn], 0);
QCOMPARE(rect2Spy.counts[QEvent::FocusOut], 0);
// clicking on rect1 should not set it's focus item
+ rect1->clearFocus();
sendMouseClick(&scene, QPointF(-25, -25));
QCOMPARE(rect1->focusItem(), (QGraphicsItem *) 0);
- QCOMPARE(rect1Spy.counts[QEvent::FocusIn], 0);
- QCOMPARE(rect1Spy.counts[QEvent::FocusOut], 0);
+ QCOMPARE(rect1Spy.counts[QEvent::FocusIn], 1);
+ QCOMPARE(rect1Spy.counts[QEvent::FocusOut], 1);
QCOMPARE(rect2Spy.counts[QEvent::FocusIn], 0);
QCOMPARE(rect2Spy.counts[QEvent::FocusOut], 0);
@@ -10357,33 +10392,34 @@ void tst_QGraphicsItem::modality_clickFocus()
rect2->setActive(true);
sendMouseClick(&scene, QPointF(75, 75));
QCOMPARE(scene.focusItem(), (QGraphicsItem *) rect2);
- QCOMPARE(rect1Spy.counts[QEvent::FocusIn], 0);
- QCOMPARE(rect1Spy.counts[QEvent::FocusOut], 0);
+ QCOMPARE(rect1Spy.counts[QEvent::FocusIn], 1);
+ QCOMPARE(rect1Spy.counts[QEvent::FocusOut], 1);
QCOMPARE(rect2Spy.counts[QEvent::FocusIn], 1);
QCOMPARE(rect2Spy.counts[QEvent::FocusOut], 0);
// clicking on rect1 does *not* give it focus
rect1->setActive(true);
+ rect1->clearFocus();
sendMouseClick(&scene, QPointF(-25, -25));
QCOMPARE(scene.focusItem(), (QGraphicsItem *) 0);
- QCOMPARE(rect1Spy.counts[QEvent::FocusIn], 0);
- QCOMPARE(rect1Spy.counts[QEvent::FocusOut], 0);
+ QCOMPARE(rect1Spy.counts[QEvent::FocusIn], 2);
+ QCOMPARE(rect1Spy.counts[QEvent::FocusOut], 2);
QCOMPARE(rect2Spy.counts[QEvent::FocusIn], 1);
QCOMPARE(rect2Spy.counts[QEvent::FocusOut], 1);
// focus doesn't change when leaving modality either
rect2->setPanelModality(QGraphicsItem::NonModal);
QCOMPARE(scene.focusItem(), (QGraphicsItem *) 0);
- QCOMPARE(rect1Spy.counts[QEvent::FocusIn], 0);
- QCOMPARE(rect1Spy.counts[QEvent::FocusOut], 0);
+ QCOMPARE(rect1Spy.counts[QEvent::FocusIn], 2);
+ QCOMPARE(rect1Spy.counts[QEvent::FocusOut], 2);
QCOMPARE(rect2Spy.counts[QEvent::FocusIn], 1);
QCOMPARE(rect2Spy.counts[QEvent::FocusOut], 1);
// click on rect1, it should get focus now
sendMouseClick(&scene, QPointF(-25, -25));
QCOMPARE(scene.focusItem(), (QGraphicsItem *) rect1);
- QCOMPARE(rect1Spy.counts[QEvent::FocusIn], 1);
- QCOMPARE(rect1Spy.counts[QEvent::FocusOut], 0);
+ QCOMPARE(rect1Spy.counts[QEvent::FocusIn], 3);
+ QCOMPARE(rect1Spy.counts[QEvent::FocusOut], 2);
QCOMPARE(rect2Spy.counts[QEvent::FocusIn], 1);
QCOMPARE(rect2Spy.counts[QEvent::FocusOut], 1);
}
diff --git a/tests/auto/widgets/graphicsview/qgraphicsitemanimation/qgraphicsitemanimation.pro b/tests/auto/widgets/graphicsview/qgraphicsitemanimation/qgraphicsitemanimation.pro
index 98517311d5..484f4ba5f8 100644
--- a/tests/auto/widgets/graphicsview/qgraphicsitemanimation/qgraphicsitemanimation.pro
+++ b/tests/auto/widgets/graphicsview/qgraphicsitemanimation/qgraphicsitemanimation.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qgraphicsitemanimation.cpp
DEFINES += QT_NO_CAST_TO_ASCII
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicslayout/qgraphicslayout.pro b/tests/auto/widgets/graphicsview/qgraphicslayout/qgraphicslayout.pro
index ceab1a05c8..254a91ef6a 100644
--- a/tests/auto/widgets/graphicsview/qgraphicslayout/qgraphicslayout.pro
+++ b/tests/auto/widgets/graphicsview/qgraphicslayout/qgraphicslayout.pro
@@ -8,4 +8,3 @@ QT += widgets testlib
SOURCES += tst_qgraphicslayout.cpp
DEFINES += QT_USE_USING_NAMESPACE
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicslayoutitem/qgraphicslayoutitem.pro b/tests/auto/widgets/graphicsview/qgraphicslayoutitem/qgraphicslayoutitem.pro
index a9e5004c88..ef5cc36d05 100644
--- a/tests/auto/widgets/graphicsview/qgraphicslayoutitem/qgraphicslayoutitem.pro
+++ b/tests/auto/widgets/graphicsview/qgraphicslayoutitem/qgraphicslayoutitem.pro
@@ -4,4 +4,3 @@ QT += widgets testlib
SOURCES += tst_qgraphicslayoutitem.cpp
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicslinearlayout/qgraphicslinearlayout.pro b/tests/auto/widgets/graphicsview/qgraphicslinearlayout/qgraphicslinearlayout.pro
index 42c91f24ae..50a886cece 100644
--- a/tests/auto/widgets/graphicsview/qgraphicslinearlayout/qgraphicslinearlayout.pro
+++ b/tests/auto/widgets/graphicsview/qgraphicslinearlayout/qgraphicslinearlayout.pro
@@ -4,4 +4,3 @@ QT += widgets testlib
SOURCES += tst_qgraphicslinearlayout.cpp
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicsobject/qgraphicsobject.pro b/tests/auto/widgets/graphicsview/qgraphicsobject/qgraphicsobject.pro
index d17dc54fd0..60f09c2228 100644
--- a/tests/auto/widgets/graphicsview/qgraphicsobject/qgraphicsobject.pro
+++ b/tests/auto/widgets/graphicsview/qgraphicsobject/qgraphicsobject.pro
@@ -6,4 +6,3 @@ QT += core-private
SOURCES += tst_qgraphicsobject.cpp
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicspixmapitem/qgraphicspixmapitem.pro b/tests/auto/widgets/graphicsview/qgraphicspixmapitem/qgraphicspixmapitem.pro
index 0f91888684..6452e39c56 100644
--- a/tests/auto/widgets/graphicsview/qgraphicspixmapitem/qgraphicspixmapitem.pro
+++ b/tests/auto/widgets/graphicsview/qgraphicspixmapitem/qgraphicspixmapitem.pro
@@ -4,4 +4,3 @@ QT += widgets testlib
SOURCES += tst_qgraphicspixmapitem.cpp
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicspolygonitem/qgraphicspolygonitem.pro b/tests/auto/widgets/graphicsview/qgraphicspolygonitem/qgraphicspolygonitem.pro
index 08033c2fa0..bca0ecc20c 100644
--- a/tests/auto/widgets/graphicsview/qgraphicspolygonitem/qgraphicspolygonitem.pro
+++ b/tests/auto/widgets/graphicsview/qgraphicspolygonitem/qgraphicspolygonitem.pro
@@ -4,4 +4,3 @@ QT += widgets testlib
SOURCES += tst_qgraphicspolygonitem.cpp
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicsproxywidget/tst_qgraphicsproxywidget.cpp b/tests/auto/widgets/graphicsview/qgraphicsproxywidget/tst_qgraphicsproxywidget.cpp
index a859fb922a..beea46c979 100644
--- a/tests/auto/widgets/graphicsview/qgraphicsproxywidget/tst_qgraphicsproxywidget.cpp
+++ b/tests/auto/widgets/graphicsview/qgraphicsproxywidget/tst_qgraphicsproxywidget.cpp
@@ -3081,7 +3081,7 @@ protected:
private slots:
void checkMenu()
{
- if (qFindChild<QMenu *>(this))
+ if (this->findChild<QMenu *>())
embeddedPopup = true;
hide();
}
diff --git a/tests/auto/widgets/graphicsview/qgraphicsscene/tst_qgraphicsscene.cpp b/tests/auto/widgets/graphicsview/qgraphicsscene/tst_qgraphicsscene.cpp
index 7a5f7319bc..fe1df6c8f0 100644
--- a/tests/auto/widgets/graphicsview/qgraphicsscene/tst_qgraphicsscene.cpp
+++ b/tests/auto/widgets/graphicsview/qgraphicsscene/tst_qgraphicsscene.cpp
@@ -240,7 +240,7 @@ private slots:
void update();
void update2();
void views();
- void event();
+ void testEvent();
void eventsToDisabledItems();
void exposedRect();
void tabFocus_emptyScene();
@@ -266,6 +266,7 @@ private slots:
void siblingIndexAlwaysValid();
void removeFullyTransparentItem();
void zeroScale();
+ void focusItemChangedSignal();
// task specific tests below me
void task139710_bspTreeCrash();
@@ -2910,7 +2911,7 @@ protected:
}
};
-void tst_QGraphicsScene::event()
+void tst_QGraphicsScene::testEvent()
{
// Test that QGraphicsScene properly propagates events to QObject.
CustomScene scene;
@@ -3883,11 +3884,11 @@ void tst_QGraphicsScene::initialFocus_data()
QTest::addColumn<bool>("shouldHaveFocus");
QTest::newRow("inactive scene, normal item") << false << false << false << false;
- QTest::newRow("inactive scene, panel item") << false << false << true << false;
+ QTest::newRow("inactive scene, panel item") << false << false << true << true;
QTest::newRow("inactive scene, normal item, explicit focus") << false << true << false << true;
QTest::newRow("inactive scene, panel, explicit focus") << false << true << true << true;
QTest::newRow("active scene, normal item") << true << false << false << false;
- QTest::newRow("active scene, panel item") << true << false << true << false;
+ QTest::newRow("active scene, panel item") << true << false << true << true;
QTest::newRow("active scene, normal item, explicit focus") << true << true << false << true;
QTest::newRow("active scene, panel, explicit focus") << true << true << true << true;
}
@@ -4561,6 +4562,119 @@ void tst_QGraphicsScene::zeroScale()
QTRY_COMPARE(cl.changes.count(), 2);
}
+void tst_QGraphicsScene::focusItemChangedSignal()
+{
+ qRegisterMetaType<QGraphicsItem *>("QGraphicsItem *");
+ qRegisterMetaType<Qt::FocusReason>("Qt::FocusReason");
+
+ QGraphicsScene scene;
+ QSignalSpy spy(&scene, SIGNAL(focusItemChanged(QGraphicsItem *, QGraphicsItem *, Qt::FocusReason)));
+ QVERIFY(spy.isValid());
+ QCOMPARE(spy.count(), 0);
+ scene.setFocus();
+ QCOMPARE(spy.count(), 0);
+ QEvent activateEvent(QEvent::WindowActivate);
+ qApp->sendEvent(&scene, &activateEvent);
+ QCOMPARE(spy.count(), 0);
+
+ QGraphicsRectItem *topLevelItem1 = new QGraphicsRectItem;
+ topLevelItem1->setFlag(QGraphicsItem::ItemIsFocusable);
+ scene.addItem(topLevelItem1);
+ QCOMPARE(spy.count(), 0);
+ QVERIFY(!topLevelItem1->hasFocus());
+
+ QGraphicsRectItem *topLevelItem2 = new QGraphicsRectItem;
+ topLevelItem2->setFlag(QGraphicsItem::ItemIsFocusable);
+ topLevelItem2->setFocus();
+ QVERIFY(!topLevelItem2->hasFocus());
+ scene.addItem(topLevelItem2);
+ QCOMPARE(spy.count(), 1);
+ QList<QVariant> arguments = spy.takeFirst();
+ QCOMPARE(arguments.size(), 3);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(0)), (QGraphicsItem *)topLevelItem2);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(1)), (QGraphicsItem *)0);
+ QCOMPARE(qVariantValue<Qt::FocusReason>(arguments.at(2)), Qt::OtherFocusReason);
+ QVERIFY(topLevelItem2->hasFocus());
+
+ scene.clearFocus();
+ QCOMPARE(spy.count(), 1);
+ arguments = spy.takeFirst();
+ QCOMPARE(arguments.size(), 3);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(0)), (QGraphicsItem *)0);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(1)), (QGraphicsItem *)topLevelItem2);
+ QCOMPARE(qVariantValue<Qt::FocusReason>(arguments.at(2)), Qt::OtherFocusReason);
+
+ scene.setFocus(Qt::MenuBarFocusReason);
+ QCOMPARE(spy.count(), 1);
+ arguments = spy.takeFirst();
+ QCOMPARE(arguments.size(), 3);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(0)), (QGraphicsItem *)topLevelItem2);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(1)), (QGraphicsItem *)0);
+ QCOMPARE(qVariantValue<Qt::FocusReason>(arguments.at(2)), Qt::MenuBarFocusReason);
+
+ for (int i = 0; i < 3; ++i) {
+ topLevelItem1->setFocus(Qt::TabFocusReason);
+ arguments = spy.takeFirst();
+ QCOMPARE(arguments.size(), 3);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(0)), (QGraphicsItem *)topLevelItem1);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(1)), (QGraphicsItem *)topLevelItem2);
+ QCOMPARE(qVariantValue<Qt::FocusReason>(arguments.at(2)), Qt::TabFocusReason);
+
+ topLevelItem2->setFocus(Qt::TabFocusReason);
+ arguments = spy.takeFirst();
+ QCOMPARE(arguments.size(), 3);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(0)), (QGraphicsItem *)topLevelItem2);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(1)), (QGraphicsItem *)topLevelItem1);
+ QCOMPARE(qVariantValue<Qt::FocusReason>(arguments.at(2)), Qt::TabFocusReason);
+ }
+
+ // The following two are unexpected, but fixing this (i.e., losing and gaining focus
+ // when the scene activation changes) breaks quite a few tests so leave this fix
+ // for some future release. See QTBUG-28346.
+ QEvent deactivateEvent(QEvent::WindowDeactivate);
+ qApp->sendEvent(&scene, &deactivateEvent);
+ QEXPECT_FAIL("", "QTBUG-28346", Continue);
+ QCOMPARE(spy.count(), 1);
+ qApp->sendEvent(&scene, &activateEvent);
+ QEXPECT_FAIL("", "QTBUG-28346", Continue);
+ QCOMPARE(spy.count(), 1);
+
+ QGraphicsRectItem *panel1 = new QGraphicsRectItem;
+ panel1->setFlags(QGraphicsItem::ItemIsPanel | QGraphicsItem::ItemIsFocusable);
+ panel1->setFocus();
+ scene.addItem(panel1);
+ QCOMPARE(spy.count(), 1);
+ arguments = spy.takeFirst();
+ QCOMPARE(arguments.size(), 3);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(0)), (QGraphicsItem *)panel1);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(1)), (QGraphicsItem *)topLevelItem2);
+ QCOMPARE(qVariantValue<Qt::FocusReason>(arguments.at(2)), Qt::ActiveWindowFocusReason);
+
+ QGraphicsRectItem *panel2 = new QGraphicsRectItem;
+ panel2->setFlags(QGraphicsItem::ItemIsPanel | QGraphicsItem::ItemIsFocusable);
+ scene.addItem(panel2);
+ QCOMPARE(spy.count(), 0);
+
+ for (int i = 0; i < 3; ++i) {
+ scene.setActivePanel(panel2);
+ QCOMPARE(spy.count(), 1);
+ arguments = spy.takeFirst();
+ QCOMPARE(arguments.size(), 3);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(0)), (QGraphicsItem *)panel2);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(1)), (QGraphicsItem *)panel1);
+ QCOMPARE(qVariantValue<Qt::FocusReason>(arguments.at(2)), Qt::ActiveWindowFocusReason);
+
+ scene.setActivePanel(panel1);
+ QCOMPARE(spy.count(), 1);
+ arguments = spy.takeFirst();
+ QCOMPARE(arguments.size(), 3);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(0)), (QGraphicsItem *)panel1);
+ QCOMPARE(qVariantValue<QGraphicsItem *>(arguments.at(1)), (QGraphicsItem *)panel2);
+ QCOMPARE(qVariantValue<Qt::FocusReason>(arguments.at(2)), Qt::ActiveWindowFocusReason);
+ }
+
+}
+
void tst_QGraphicsScene::taskQTBUG_15977_renderWithDeviceCoordinateCache()
{
QGraphicsScene scene;
diff --git a/tests/auto/widgets/graphicsview/qgraphicstransform/qgraphicstransform.pro b/tests/auto/widgets/graphicsview/qgraphicstransform/qgraphicstransform.pro
index c11ca1a9bb..a46c803e41 100644
--- a/tests/auto/widgets/graphicsview/qgraphicstransform/qgraphicstransform.pro
+++ b/tests/auto/widgets/graphicsview/qgraphicstransform/qgraphicstransform.pro
@@ -4,4 +4,3 @@ QT += widgets testlib
SOURCES += tst_qgraphicstransform.cpp
CONFIG += parallel_test
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp b/tests/auto/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp
index 095c1e87d3..9e06435ca7 100644
--- a/tests/auto/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp
+++ b/tests/auto/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp
@@ -845,7 +845,7 @@ void tst_QGraphicsView::dragMode_rubberBand()
QCOMPARE(view.verticalScrollBar()->value(), verticalScrollBarValue);
// We don't use QRubberBand as of 4.3; the band is drawn internally.
- QVERIFY(!qFindChild<QRubberBand *>(&view));
+ QVERIFY(!view.findChild<QRubberBand *>());
QTest::qWait(25);
@@ -3025,7 +3025,7 @@ void tst_QGraphicsView::task187791_setSceneCausesUpdate()
QGraphicsView view(&scene);
view.show();
qApp->setActiveWindow(&view);
- QVERIFY(QTest::qWaitForWindowShown(&view));
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
EventSpy updateSpy(view.viewport(), QEvent::Paint);
QCOMPARE(updateSpy.count(), 0);
diff --git a/tests/auto/widgets/graphicsview/qgraphicswidget/tst_qgraphicswidget.cpp b/tests/auto/widgets/graphicsview/qgraphicswidget/tst_qgraphicswidget.cpp
index 69665572f7..4cfdfccd63 100644
--- a/tests/auto/widgets/graphicsview/qgraphicswidget/tst_qgraphicswidget.cpp
+++ b/tests/auto/widgets/graphicsview/qgraphicswidget/tst_qgraphicswidget.cpp
@@ -172,12 +172,12 @@ private slots:
void initialShow2();
void itemChangeEvents();
void itemSendGeometryPosChangesDeactivated();
-
void fontPropagatesResolveToChildren();
void fontPropagatesResolveToGrandChildren();
void fontPropagatesResolveInParentChange();
void fontPropagatesResolveViaNonWidget();
void fontPropagatesResolveFromScene();
+ void tabFocus();
// Task fixes
void task236127_bspTreeIndexFails();
@@ -3302,6 +3302,103 @@ void tst_QGraphicsWidget::itemSendGeometryPosChangesDeactivated()
QCOMPARE(item->geometry(), QRectF(10, 10, 60, 60));
}
+class TabFocusWidget : public QGraphicsWidget
+{
+ Q_OBJECT
+public:
+ TabFocusWidget(const QString &name, QGraphicsItem *parent = 0)
+ : QGraphicsWidget(parent)
+ { setFocusPolicy(Qt::TabFocus); setData(0, name); }
+};
+
+void verifyTabFocus(QGraphicsScene *scene, const QList<QGraphicsWidget *> &chain, bool wrapsAround)
+{
+ QKeyEvent tabEvent(QEvent::KeyPress, Qt::Key_Tab, 0);
+ QKeyEvent backtabEvent(QEvent::KeyPress, Qt::Key_Backtab, 0);
+
+ for (int i = 0; i < chain.size(); ++i)
+ chain.at(i)->clearFocus();
+
+ int n = chain.size() * (wrapsAround ? 3 : 1);
+ for (int i = 0; i < n; ++i)
+ {
+ qApp->sendEvent(scene, &tabEvent);
+ QVERIFY(chain.at(i % chain.size())->hasFocus());
+ QCOMPARE(scene->focusItem(), chain.at(i % chain.size()));
+ }
+ for (int i = n - 2; i >= 0; --i)
+ {
+ qApp->sendEvent(scene, &backtabEvent);
+ QVERIFY(chain.at(i % chain.size())->hasFocus());
+ QCOMPARE(scene->focusItem(), chain.at(i % chain.size()));
+ }
+}
+
+void tst_QGraphicsWidget::tabFocus()
+{
+ QGraphicsScene scene;
+ scene.setFocus();
+
+ QEvent activate(QEvent::WindowActivate);
+ qApp->sendEvent(&scene, &activate);
+
+ TabFocusWidget *widget = new TabFocusWidget("1");
+ scene.addItem(widget);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget, false);
+
+ TabFocusWidget *widget2 = new TabFocusWidget("2");
+ scene.addItem(widget2);
+ scene.setFocusItem(0);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget << widget2, false);
+
+ TabFocusWidget *widget3 = new TabFocusWidget("3");
+ widget3->setFlag(QGraphicsItem::ItemIsPanel);
+ scene.addItem(widget3);
+ QCOMPARE(scene.activePanel(), (QGraphicsItem *)widget3);
+ scene.setActivePanel(0);
+ scene.setFocusItem(0);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget << widget2, false);
+
+ scene.setActivePanel(widget3);
+ QCOMPARE(scene.focusItem(), (QGraphicsItem *)widget3);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget3, true);
+
+ TabFocusWidget *widget4 = new TabFocusWidget("4");
+ widget4->setParentItem(widget3);
+ QVERIFY(widget3->hasFocus());
+ widget3->clearFocus();
+ QVERIFY(!widget3->focusItem());
+ QCOMPARE(scene.activePanel(), (QGraphicsItem *)widget3);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget3 << widget4, true);
+
+ QGraphicsWidget *widget5 = new QGraphicsWidget; widget5->setData(0, QLatin1String("5"));
+ widget5->setParentItem(widget3);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget3 << widget4, true);
+
+ widget5->setFocusPolicy(Qt::TabFocus);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget3 << widget4 << widget5, true);
+
+ TabFocusWidget *widget6 = new TabFocusWidget("6");
+ widget6->setParentItem(widget4);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget3 << widget4 << widget6 << widget5, true);
+
+ TabFocusWidget *widget7 = new TabFocusWidget("7", widget6);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget3 << widget4 << widget6 << widget7 << widget5, true);
+
+ TabFocusWidget *widget8 = new TabFocusWidget("8", widget6);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget3 << widget4 << widget6 << widget7 << widget8 << widget5, true);
+ widget6->setFlag(QGraphicsItem::ItemIsPanel);
+ widget6->setActive(true);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget6 << widget7 << widget8, true);
+ widget3->setActive(true);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget3 << widget4 << widget5, true);
+ widget6->setFlag(QGraphicsItem::ItemIsPanel, false);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget3 << widget4 << widget6 << widget7 << widget8 << widget5, true);
+ scene.removeItem(widget6);
+ verifyTabFocus(&scene, QList<QGraphicsWidget *>() << widget3 << widget4 << widget5, true);
+ delete widget6;
+}
+
void tst_QGraphicsWidget::QT_BUG_6544_tabFocusFirstUnsetWhenRemovingItems()
{
QGraphicsScene scene;
diff --git a/tests/auto/widgets/itemviews/qabstractitemview/qabstractitemview.pro b/tests/auto/widgets/itemviews/qabstractitemview/qabstractitemview.pro
index bb7a7b2b6d..8fbc3c15a8 100644
--- a/tests/auto/widgets/itemviews/qabstractitemview/qabstractitemview.pro
+++ b/tests/auto/widgets/itemviews/qabstractitemview/qabstractitemview.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qabstractitemview
QT += widgets testlib
SOURCES += tst_qabstractitemview.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qabstractitemview/tst_qabstractitemview.cpp b/tests/auto/widgets/itemviews/qabstractitemview/tst_qabstractitemview.cpp
index 2d95c9d3a4..0c6d369254 100644
--- a/tests/auto/widgets/itemviews/qabstractitemview/tst_qabstractitemview.cpp
+++ b/tests/auto/widgets/itemviews/qabstractitemview/tst_qabstractitemview.cpp
@@ -235,6 +235,8 @@ private slots:
void testDelegateDestroyEditor();
void testClickedSignal();
void testChangeEditorState();
+ void deselectInSingleSelection();
+ void testNoActivateOnDisabledItem();
};
class MyAbstractItemDelegate : public QAbstractItemDelegate
@@ -740,7 +742,7 @@ void tst_QAbstractItemView::persistentEditorFocus()
view.openPersistentEditor(model.index(0, 2));
//these are spinboxes because we put numbers inside
- QList<QSpinBox*> list = qFindChildren<QSpinBox*>(view.viewport());
+ QList<QSpinBox*> list = view.viewport()->findChildren<QSpinBox*>();
QCOMPARE(list.count(), 2); //these should be the 2 editors
view.setCurrentIndex(model.index(0, 0));
@@ -1046,7 +1048,6 @@ void tst_QAbstractItemView::setItemDelegate()
v.show();
#ifdef Q_WS_X11
QCursor::setPos(v.geometry().center());
- QApplication::syncX();
#endif
QApplication::setActiveWindow(&v);
QVERIFY(QTest::qWaitForWindowActive(&v));
@@ -1269,21 +1270,21 @@ void tst_QAbstractItemView::task257481_emptyEditor()
treeView.show();
treeView.edit(model.index(0,0));
- QList<QLineEdit *> lineEditors = qFindChildren<QLineEdit *>(treeView.viewport());
+ QList<QLineEdit *> lineEditors = treeView.viewport()->findChildren<QLineEdit *>();
QCOMPARE(lineEditors.count(), 1);
QVERIFY(!lineEditors.first()->size().isEmpty());
QTest::qWait(30);
treeView.edit(model.index(1,0));
- lineEditors = qFindChildren<QLineEdit *>(treeView.viewport());
+ lineEditors = treeView.viewport()->findChildren<QLineEdit *>();
QCOMPARE(lineEditors.count(), 1);
QVERIFY(!lineEditors.first()->size().isEmpty());
QTest::qWait(30);
treeView.edit(model.index(2,0));
- lineEditors = qFindChildren<QLineEdit *>(treeView.viewport());
+ lineEditors = treeView.viewport()->findChildren<QLineEdit *>();
QCOMPARE(lineEditors.count(), 1);
QVERIFY(!lineEditors.first()->size().isEmpty());
}
@@ -1599,5 +1600,70 @@ void tst_QAbstractItemView::testChangeEditorState()
// No segfault - the test passes.
}
+void tst_QAbstractItemView::deselectInSingleSelection()
+{
+ QTableView view;
+ QStandardItemModel s;
+ s.setRowCount(10);
+ s.setColumnCount(10);
+ view.setModel(&s);
+ view.show();
+ view.setSelectionMode(QAbstractItemView::SingleSelection);
+ view.setEditTriggers(QAbstractItemView::NoEditTriggers);
+ QApplication::setActiveWindow(&view);
+ QVERIFY(QTest::qWaitForWindowExposed(&view));
+ // mouse
+ QModelIndex index22 = s.index(2, 2);
+ QRect rect22 = view.visualRect(index22);
+ QPoint clickpos = rect22.center();
+ QTest::mouseClick(view.viewport(), Qt::LeftButton, Qt::NoModifier, clickpos);
+ QCOMPARE(view.currentIndex(), index22);
+ QCOMPARE(view.selectionModel()->selectedIndexes().count(), 1);
+ QTest::mouseClick(view.viewport(), Qt::LeftButton, Qt::ControlModifier, clickpos);
+ QCOMPARE(view.currentIndex(), index22);
+ QCOMPARE(view.selectionModel()->selectedIndexes().count(), 0);
+
+ // second click with modifier however does select
+ QTest::mouseClick(view.viewport(), Qt::LeftButton, Qt::ControlModifier, clickpos);
+ QCOMPARE(view.currentIndex(), index22);
+ QCOMPARE(view.selectionModel()->selectedIndexes().count(), 1);
+
+ // keyboard
+ QTest::keyClick(&view, Qt::Key_Space, Qt::NoModifier);
+ QCOMPARE(view.currentIndex(), index22);
+ QCOMPARE(view.selectionModel()->selectedIndexes().count(), 1);
+ QTest::keyClick(&view, Qt::Key_Space, Qt::ControlModifier);
+ QCOMPARE(view.currentIndex(), index22);
+ QCOMPARE(view.selectionModel()->selectedIndexes().count(), 0);
+
+ // second keypress with modifier however does select
+ QTest::keyClick(&view, Qt::Key_Space, Qt::ControlModifier);
+ QCOMPARE(view.currentIndex(), index22);
+ QCOMPARE(view.selectionModel()->selectedIndexes().count(), 1);
+}
+
+void tst_QAbstractItemView::testNoActivateOnDisabledItem()
+{
+ QTreeView treeView;
+ QStandardItemModel model(1, 1);
+ QStandardItem *item = new QStandardItem("item");
+ model.setItem(0, 0, item);
+ item->setFlags(Qt::NoItemFlags);
+ treeView.setModel(&model);
+ treeView.show();
+
+ QApplication::setActiveWindow(&treeView);
+ QVERIFY(QTest::qWaitForWindowActive(&treeView));
+
+ QSignalSpy activatedSpy(&treeView, SIGNAL(activated(QModelIndex)));
+
+ // Ensure clicking on a disabled item doesn't emit itemActivated.
+ QModelIndex itemIndex = treeView.model()->index(0, 0);
+ QPoint clickPos = treeView.visualRect(itemIndex).center();
+ QTest::mouseClick(treeView.viewport(), Qt::LeftButton, 0, clickPos);
+
+ QCOMPARE(activatedSpy.count(), 0);
+}
+
QTEST_MAIN(tst_QAbstractItemView)
#include "tst_qabstractitemview.moc"
diff --git a/tests/auto/widgets/itemviews/qcolumnview/qcolumnview.pro b/tests/auto/widgets/itemviews/qcolumnview/qcolumnview.pro
index 4980b45389..8bc1bf2412 100644
--- a/tests/auto/widgets/itemviews/qcolumnview/qcolumnview.pro
+++ b/tests/auto/widgets/itemviews/qcolumnview/qcolumnview.pro
@@ -5,4 +5,3 @@ QT += gui-private core-private testlib
SOURCES += tst_qcolumnview.cpp
TARGET = tst_qcolumnview
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qcolumnview/tst_qcolumnview.cpp b/tests/auto/widgets/itemviews/qcolumnview/tst_qcolumnview.cpp
index 81736ad0d0..3fa3fbe0ee 100644
--- a/tests/auto/widgets/itemviews/qcolumnview/tst_qcolumnview.cpp
+++ b/tests/auto/widgets/itemviews/qcolumnview/tst_qcolumnview.cpp
@@ -165,7 +165,8 @@ public:
QColumnView::setSelection(rect, command);
}
- QRegion visualRegionForSelection(QItemSelection selection){
+ // visualRegionForSelection() is protected in QColumnView.
+ QRegion getVisualRegionForSelection(const QItemSelection &selection){
return QColumnView::visualRegionForSelection(selection);
}
protected:
@@ -664,7 +665,7 @@ void tst_QColumnView::visualRegionForSelection()
{
ColumnView view;
QItemSelection emptyItemSelection;
- QCOMPARE(QRegion(), view.visualRegionForSelection(emptyItemSelection));
+ QCOMPARE(QRegion(), view.getVisualRegionForSelection(emptyItemSelection));
// a region that isn't empty
QDirModel model;
@@ -680,7 +681,7 @@ void tst_QColumnView::visualRegionForSelection()
QModelIndex home = model.index(location);
QVERIFY(model.rowCount(home) > 1);
QItemSelection itemSelection(model.index(0, 0, home), model.index(model.rowCount(home) - 1, 0, home));
- QVERIFY(QRegion() != view.visualRegionForSelection(itemSelection));
+ QVERIFY(QRegion() != view.getVisualRegionForSelection(itemSelection));
}
void tst_QColumnView::moveGrip_basic()
diff --git a/tests/auto/widgets/itemviews/qdatawidgetmapper/qdatawidgetmapper.pro b/tests/auto/widgets/itemviews/qdatawidgetmapper/qdatawidgetmapper.pro
index e7618cd833..3f4cb491f4 100644
--- a/tests/auto/widgets/itemviews/qdatawidgetmapper/qdatawidgetmapper.pro
+++ b/tests/auto/widgets/itemviews/qdatawidgetmapper/qdatawidgetmapper.pro
@@ -5,4 +5,3 @@ QT += widgets testlib
SOURCES += tst_qdatawidgetmapper.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qdirmodel/qdirmodel.pro b/tests/auto/widgets/itemviews/qdirmodel/qdirmodel.pro
index 31e3cf498c..680286d1e4 100644
--- a/tests/auto/widgets/itemviews/qdirmodel/qdirmodel.pro
+++ b/tests/auto/widgets/itemviews/qdirmodel/qdirmodel.pro
@@ -19,4 +19,3 @@ wince*: {
DEFINES += SRCDIR=\\\"$$PWD/\\\"
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qfileiconprovider/qfileiconprovider.pro b/tests/auto/widgets/itemviews/qfileiconprovider/qfileiconprovider.pro
index d7be6452ec..0c3a780405 100644
--- a/tests/auto/widgets/itemviews/qfileiconprovider/qfileiconprovider.pro
+++ b/tests/auto/widgets/itemviews/qfileiconprovider/qfileiconprovider.pro
@@ -5,4 +5,3 @@ QT += widgets testlib
SOURCES += tst_qfileiconprovider.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qheaderview/tst_qheaderview.cpp b/tests/auto/widgets/itemviews/qheaderview/tst_qheaderview.cpp
index 63d5389e12..fa67e16db9 100644
--- a/tests/auto/widgets/itemviews/qheaderview/tst_qheaderview.cpp
+++ b/tests/auto/widgets/itemviews/qheaderview/tst_qheaderview.cpp
@@ -157,7 +157,7 @@ private slots:
void sortIndicatorTracking();
void removeAndInsertRow();
void unhideSection();
- void event();
+ void testEvent();
void headerDataChanged();
void currentChanged();
void horizontalOffset();
@@ -1368,7 +1368,7 @@ void tst_QHeaderView::unhideSection()
}
-void tst_QHeaderView::event()
+void tst_QHeaderView::testEvent()
{
protected_QHeaderView x(Qt::Vertical);
x.testEvent();
diff --git a/tests/auto/widgets/itemviews/qitemdelegate/qitemdelegate.pro b/tests/auto/widgets/itemviews/qitemdelegate/qitemdelegate.pro
index 628db489a2..cb935fd2fd 100644
--- a/tests/auto/widgets/itemviews/qitemdelegate/qitemdelegate.pro
+++ b/tests/auto/widgets/itemviews/qitemdelegate/qitemdelegate.pro
@@ -4,4 +4,3 @@ QT += widgets testlib
SOURCES += tst_qitemdelegate.cpp
win32:!wince*: LIBS += -luser32
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp b/tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp
index 0224f9019a..d47eebe03a 100644
--- a/tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp
+++ b/tests/auto/widgets/itemviews/qitemdelegate/tst_qitemdelegate.cpp
@@ -220,7 +220,7 @@ private slots:
void doLayout();
void rect_data();
void rect();
- void eventFilter();
+ void testEventFilter();
void dateTimeEditor_data();
void dateTimeEditor();
void dateAndTimeEditorTest2();
@@ -365,7 +365,7 @@ void tst_QItemDelegate::editorKeyPress()
view.setCurrentIndex(index); // the editor will only selectAll on the current index
view.edit(index);
- QList<QLineEdit*> lineEditors = qFindChildren<QLineEdit *>(view.viewport());
+ QList<QLineEdit*> lineEditors = view.viewport()->findChildren<QLineEdit *>();
QCOMPARE(lineEditors.count(), 1);
QLineEdit *editor = lineEditors.at(0);
@@ -394,7 +394,7 @@ void tst_QItemDelegate::doubleEditorNegativeInput()
view.setCurrentIndex(index); // the editor will only selectAll on the current index
view.edit(index);
- QList<QDoubleSpinBox*> editors = qFindChildren<QDoubleSpinBox *>(view.viewport());
+ QList<QDoubleSpinBox*> editors = view.viewport()->findChildren<QDoubleSpinBox *>();
QCOMPARE(editors.count(), 1);
QDoubleSpinBox *editor = editors.at(0);
@@ -695,7 +695,7 @@ void tst_QItemDelegate::rect()
//TODO : Add a test for the keyPress event
//with Qt::Key_Enter and Qt::Key_Return
-void tst_QItemDelegate::eventFilter()
+void tst_QItemDelegate::testEventFilter()
{
TestItemDelegate delegate;
QWidget widget;
@@ -776,7 +776,7 @@ void tst_QItemDelegate::dateTimeEditor()
QTestEventLoop::instance().enterLoop(1);
- QTimeEdit *timeEditor = qFindChild<QTimeEdit *>(widget.viewport());
+ QTimeEdit *timeEditor = widget.viewport()->findChild<QTimeEdit *>();
QVERIFY(timeEditor);
QCOMPARE(timeEditor->time(), time);
// The data must actually be different in order for the model
@@ -790,7 +790,7 @@ void tst_QItemDelegate::dateTimeEditor()
QTestEventLoop::instance().enterLoop(1);
- QDateEdit *dateEditor = qFindChild<QDateEdit *>(widget.viewport());
+ QDateEdit *dateEditor = widget.viewport()->findChild<QDateEdit *>();
QVERIFY(dateEditor);
QCOMPARE(dateEditor->date(), date);
dateEditor->setDate(date.addDays(60));
@@ -1312,7 +1312,7 @@ void tst_QItemDelegate::enterKey()
view.edit(index);
QTest::qWait(30);
- QList<QWidget*> lineEditors = qFindChildren<QWidget *>(view.viewport(), QString::fromLatin1("TheEditor"));
+ QList<QWidget*> lineEditors = view.viewport()->findChildren<QWidget *>(QString::fromLatin1("TheEditor"));
QCOMPARE(lineEditors.count(), 1);
QPointer<QWidget> editor = lineEditors.at(0);
@@ -1344,7 +1344,7 @@ void tst_QItemDelegate::task257859_finalizeEdit()
view.edit(index);
QTest::qWait(30);
- QList<QLineEdit *> lineEditors = qFindChildren<QLineEdit *>(view.viewport());
+ QList<QLineEdit *> lineEditors = view.viewport()->findChildren<QLineEdit *>();
QCOMPARE(lineEditors.count(), 1);
QPointer<QWidget> editor = lineEditors.at(0);
@@ -1397,7 +1397,7 @@ void tst_QItemDelegate::comboBox()
QTestEventLoop::instance().enterLoop(1);
- QComboBox *boolEditor = qFindChild<QComboBox*>(widget.viewport());
+ QComboBox *boolEditor = widget.viewport()->findChild<QComboBox*>();
QVERIFY(boolEditor);
QCOMPARE(boolEditor->currentIndex(), 1); // True is selected initially.
// The data must actually be different in order for the model
diff --git a/tests/auto/widgets/itemviews/qitemeditorfactory/qitemeditorfactory.pro b/tests/auto/widgets/itemviews/qitemeditorfactory/qitemeditorfactory.pro
index 3c1b9ba29b..55df1d83f1 100644
--- a/tests/auto/widgets/itemviews/qitemeditorfactory/qitemeditorfactory.pro
+++ b/tests/auto/widgets/itemviews/qitemeditorfactory/qitemeditorfactory.pro
@@ -5,4 +5,3 @@ QT += widgets testlib
SOURCES += tst_qitemeditorfactory.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qitemview/qitemview.pro b/tests/auto/widgets/itemviews/qitemview/qitemview.pro
index 0d36edc870..6e1697f790 100644
--- a/tests/auto/widgets/itemviews/qitemview/qitemview.pro
+++ b/tests/auto/widgets/itemviews/qitemview/qitemview.pro
@@ -5,4 +5,3 @@ QT += widgets testlib
SOURCES += tst_qitemview.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qlistview/qlistview.pro b/tests/auto/widgets/itemviews/qlistview/qlistview.pro
index 1fb5b7f767..413304bdcf 100644
--- a/tests/auto/widgets/itemviews/qlistview/qlistview.pro
+++ b/tests/auto/widgets/itemviews/qlistview/qlistview.pro
@@ -3,4 +3,3 @@ TARGET = tst_qlistview
QT += widgets gui-private widgets-private core-private testlib
SOURCES += tst_qlistview.cpp
win32:!wince*: LIBS += -luser32
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qlistview/tst_qlistview.cpp b/tests/auto/widgets/itemviews/qlistview/tst_qlistview.cpp
index 02d5c5cdb7..5d7925aeec 100644
--- a/tests/auto/widgets/itemviews/qlistview/tst_qlistview.cpp
+++ b/tests/auto/widgets/itemviews/qlistview/tst_qlistview.cpp
@@ -505,11 +505,12 @@ class QMoveCursorListView : public QListView
public:
QMoveCursorListView() : QListView() {}
+ // enum CursorAction and moveCursor() are protected in QListView.
enum CursorAction { MoveUp, MoveDown, MoveLeft, MoveRight,
MoveHome, MoveEnd, MovePageUp, MovePageDown,
MoveNext, MovePrevious };
- QModelIndex moveCursor(QMoveCursorListView::CursorAction action, Qt::KeyboardModifiers modifiers)
+ QModelIndex doMoveCursor(QMoveCursorListView::CursorAction action, Qt::KeyboardModifiers modifiers)
{
return QListView::moveCursor((QListView::CursorAction)action, modifiers);
}
@@ -540,9 +541,9 @@ void tst_QListView::moveCursor2()
vu.selectionModel()->setCurrentIndex(model.index(0,0), QItemSelectionModel::SelectCurrent);
QCoreApplication::processEvents();
- QModelIndex idx = vu.moveCursor(QMoveCursorListView::MoveHome, Qt::NoModifier);
+ QModelIndex idx = vu.doMoveCursor(QMoveCursorListView::MoveHome, Qt::NoModifier);
QCOMPARE(idx, model.index(0,0));
- idx = vu.moveCursor(QMoveCursorListView::MoveDown, Qt::NoModifier);
+ idx = vu.doMoveCursor(QMoveCursorListView::MoveDown, Qt::NoModifier);
QCOMPARE(idx, model.index(8,0));
}
@@ -1628,7 +1629,7 @@ void tst_QListView::task196118_visualRegionForSelection()
class MyListView : public QListView
{
public:
- QRegion visualRegionForSelection() const
+ QRegion getVisualRegionForSelection() const
{ return QListView::visualRegionForSelection( selectionModel()->selection()); }
} view;
@@ -1643,7 +1644,7 @@ void tst_QListView::task196118_visualRegionForSelection()
view.selectionModel()->select(top1.index(), QItemSelectionModel::Select);
QCOMPARE(view.selectionModel()->selectedIndexes().count(), 1);
- QVERIFY(view.visualRegionForSelection().isEmpty());
+ QVERIFY(view.getVisualRegionForSelection().isEmpty());
}
void tst_QListView::task254449_draggingItemToNegativeCoordinates()
@@ -1977,11 +1978,11 @@ void tst_QListView::taskQTBUG_5877_skippingItemInPageDownUp()
vu.selectionModel()->setCurrentIndex(model.index(currentItemIndexes[i], 0),
QItemSelectionModel::SelectCurrent);
- QModelIndex idx = vu.moveCursor(QMoveCursorListView::MovePageDown, Qt::NoModifier);
+ QModelIndex idx = vu.doMoveCursor(QMoveCursorListView::MovePageDown, Qt::NoModifier);
int newCurrent = qMin(currentItemIndexes[i] + scrolledRowCount, 99);
QCOMPARE(idx, model.index(newCurrent, 0));
- idx = vu.moveCursor(QMoveCursorListView::MovePageUp, Qt::NoModifier);
+ idx = vu.doMoveCursor(QMoveCursorListView::MovePageUp, Qt::NoModifier);
newCurrent = qMax(currentItemIndexes[i] - scrolledRowCount, 0);
QCOMPARE(idx, model.index(newCurrent, 0));
}
@@ -2206,7 +2207,7 @@ void tst_QListView::taskQTBUG_21804_hiddenItemsAndScrollingWithKeys()
lv.setSpacing(spacing);
lv.setModel(&model);
lv.show();
- QTest::qWaitForWindowShown(&lv);
+ QTest::qWaitForWindowExposed(&lv);
// hide every odd number row
for (int i = 1; i < model.rowCount(); i+=2)
@@ -2282,7 +2283,7 @@ void tst_QListView::spacing()
lv.setModel(&model);
lv.setSpacing(spacing);
lv.show();
- QTest::qWaitForWindowShown(&lv);
+ QTest::qWaitForWindowExposed(&lv);
// check size and position of first two items
QRect item1 = lv.visualRect(lv.model()->index(0, 0));
diff --git a/tests/auto/widgets/itemviews/qlistwidget/qlistwidget.pro b/tests/auto/widgets/itemviews/qlistwidget/qlistwidget.pro
index f1e2bbf402..b4aedf1bcf 100644
--- a/tests/auto/widgets/itemviews/qlistwidget/qlistwidget.pro
+++ b/tests/auto/widgets/itemviews/qlistwidget/qlistwidget.pro
@@ -4,4 +4,3 @@ QT += widgets widgets-private testlib
QT += core-private gui-private
SOURCES += tst_qlistwidget.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qtableview/tst_qtableview.cpp b/tests/auto/widgets/itemviews/qtableview/tst_qtableview.cpp
index 8a679fd1a0..13476a7ffa 100644
--- a/tests/auto/widgets/itemviews/qtableview/tst_qtableview.cpp
+++ b/tests/auto/widgets/itemviews/qtableview/tst_qtableview.cpp
@@ -437,6 +437,7 @@ public:
this, SLOT(itemSelectionChanged(QItemSelection,QItemSelection)));
}
+ // enum CursorAction and moveCursor() are protected in QTableView.
enum CursorAction {
MoveUp = QAbstractItemView::MoveUp,
MoveDown = QAbstractItemView::MoveDown,
@@ -450,7 +451,7 @@ public:
MovePrevious = QAbstractItemView::MovePrevious
};
- QModelIndex moveCursor(QtTestTableView::CursorAction cursorAction,
+ QModelIndex doMoveCursor(QtTestTableView::CursorAction cursorAction,
Qt::KeyboardModifiers modifiers)
{
return QTableView::moveCursor((QAbstractItemView::CursorAction)cursorAction, modifiers);
@@ -1192,7 +1193,7 @@ void tst_QTableView::moveCursor()
QModelIndex index = model.index(startRow, startColumn);
view.setCurrentIndex(index);
- QModelIndex newIndex = view.moveCursor((QtTestTableView::CursorAction)cursorMoveAction,
+ QModelIndex newIndex = view.doMoveCursor((QtTestTableView::CursorAction)cursorMoveAction,
(Qt::KeyboardModifiers)modifier);
// expected fails, task 119433
if(newIndex.row() == -1)
@@ -1339,7 +1340,7 @@ void tst_QTableView::moveCursorStrikesBack()
int newRow = -1;
int newColumn = -1;
foreach (int cursorMoveAction, cursorMoveActions) {
- QModelIndex newIndex = view.moveCursor((QtTestTableView::CursorAction)cursorMoveAction, 0);
+ QModelIndex newIndex = view.doMoveCursor((QtTestTableView::CursorAction)cursorMoveAction, 0);
view.setCurrentIndex(newIndex);
newRow = newIndex.row();
newColumn = newIndex.column();
@@ -3726,7 +3727,7 @@ void tst_QTableView::addColumnWhileEditing()
//let's see if the editor is moved to the right location
//after adding a column
model.setColumnCount(model.columnCount() + 1);
- QPointer<QLineEdit> editor = qFindChild<QLineEdit*>(&view);
+ QPointer<QLineEdit> editor = view.findChild<QLineEdit*>();
QVERIFY(editor);
QCOMPARE(editor->geometry(), view.visualRect(last));
diff --git a/tests/auto/widgets/itemviews/qtablewidget/qtablewidget.pro b/tests/auto/widgets/itemviews/qtablewidget/qtablewidget.pro
index ddc66c34df..d2c962b4de 100644
--- a/tests/auto/widgets/itemviews/qtablewidget/qtablewidget.pro
+++ b/tests/auto/widgets/itemviews/qtablewidget/qtablewidget.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qtablewidget
QT += widgets testlib
SOURCES += tst_qtablewidget.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qtablewidget/tst_qtablewidget.cpp b/tests/auto/widgets/itemviews/qtablewidget/tst_qtablewidget.cpp
index e64dce1a11..f72467de08 100644
--- a/tests/auto/widgets/itemviews/qtablewidget/tst_qtablewidget.cpp
+++ b/tests/auto/widgets/itemviews/qtablewidget/tst_qtablewidget.cpp
@@ -1444,7 +1444,7 @@ void tst_QTableWidget::task231094()
tw.setCurrentCell(1, 1);
QCOMPARE(tw.currentRow(), 1);
QCOMPARE(tw.currentColumn(), 1);
-
+
//this would provoke a end-less loop
QTest::keyClick(&tw, '1');
diff --git a/tests/auto/widgets/itemviews/qtreeview/qtreeview.pro b/tests/auto/widgets/itemviews/qtreeview/qtreeview.pro
index 8640e152d3..001331c0cf 100644
--- a/tests/auto/widgets/itemviews/qtreeview/qtreeview.pro
+++ b/tests/auto/widgets/itemviews/qtreeview/qtreeview.pro
@@ -4,4 +4,3 @@ QT += widgets testlib
QT += widgets-private gui-private core-private
SOURCES += tst_qtreeview.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp b/tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp
index 0f69e951bf..9a7b7956d8 100644
--- a/tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp
+++ b/tests/auto/widgets/itemviews/qtreeview/tst_qtreeview.cpp
@@ -89,7 +89,8 @@ struct PublicView : public QTreeView
MovePrevious = QAbstractItemView::MovePrevious
};
- inline QModelIndex moveCursor(PublicCursorAction ca, Qt::KeyboardModifiers kbm)
+ // enum PublicCursorAction and moveCursor() are protected in QTreeView.
+ inline QModelIndex doMoveCursor(PublicCursorAction ca, Qt::KeyboardModifiers kbm)
{ return QTreeView::moveCursor((CursorAction)ca, kbm); }
inline void setSelection(const QRect &rect, QItemSelectionModel::SelectionFlags command)
@@ -177,6 +178,7 @@ private slots:
void emptyModel();
void removeRows();
void removeCols();
+ void limitedExpand();
void expandAndCollapse_data();
void expandAndCollapse();
void expandAndCollapseAll();
@@ -256,6 +258,7 @@ private slots:
void taskQTBUG_13567_removeLastItemRegression();
void taskQTBUG_25333_adjustViewOptionsForIndex();
void taskQTBUG_18539_emitLayoutChanged();
+ void taskQTBUG_8176_emitOnExpandAll();
};
class QtTestModel: public QAbstractItemModel
@@ -816,7 +819,7 @@ void tst_QTreeView::editTriggers()
view.setCurrentIndex(view.model()->index(0, 0));
// Verify that we don't have any editor initially
- QVERIFY(!qFindChild<QLineEdit *>(&view, QString()));
+ QVERIFY(!view.findChild<QLineEdit *>(QString()));
// Set the triggers
view.setEditTriggers(editTriggers);
@@ -862,7 +865,7 @@ void tst_QTreeView::editTriggers()
#ifdef Q_OS_MAC
QEXPECT_FAIL("EditKeyPressed 4", "QTBUG-23696", Continue);
#endif
- QTRY_COMPARE(qFindChild<QLineEdit *>(&view, QString()) != 0, editorOpened);
+ QTRY_COMPARE(view.findChild<QLineEdit *>(QString()) != 0, editorOpened);
}
void tst_QTreeView::hasAutoScroll()
@@ -1029,7 +1032,7 @@ void tst_QTreeView::indexWidget()
QCOMPARE(view.indexWidget(index), static_cast<QWidget *>(widget));
QCOMPARE(widget->parentWidget(), view.viewport());
- QCOMPARE(widget->geometry(), view.visualRect(index).intersect(widget->geometry()));
+ QCOMPARE(widget->geometry(), view.visualRect(index).intersected(widget->geometry()));
QCOMPARE(widget->toPlainText(), text);
}
@@ -1225,15 +1228,15 @@ void tst_QTreeView::openPersistentEditor()
view.setModel(&treeModel);
view.show();
- QVERIFY(!qFindChild<QLineEdit *>(view.viewport()));
+ QVERIFY(!view.viewport()->findChild<QLineEdit *>());
view.openPersistentEditor(view.model()->index(0, 0));
- QVERIFY(qFindChild<QLineEdit *>(view.viewport()));
+ QVERIFY(view.viewport()->findChild<QLineEdit *>());
view.closePersistentEditor(view.model()->index(0, 0));
- QVERIFY(!qFindChild<QLineEdit *>(view.viewport())->isVisible());
+ QVERIFY(!view.viewport()->findChild<QLineEdit *>()->isVisible());
qApp->sendPostedEvents(0, QEvent::DeferredDelete);
- QVERIFY(!qFindChild<QLineEdit *>(view.viewport()));
+ QVERIFY(!view.viewport()->findChild<QLineEdit *>());
}
void tst_QTreeView::rootIndex()
@@ -1414,6 +1417,45 @@ void tst_QTreeView::removeCols()
QCOMPARE(view.header()->count(), model.cols);
}
+void tst_QTreeView::limitedExpand()
+{
+ {
+ QStandardItemModel model;
+ QStandardItem *parentItem = model.invisibleRootItem();
+ parentItem->appendRow(new QStandardItem);
+ parentItem->appendRow(new QStandardItem);
+ parentItem->appendRow(new QStandardItem);
+
+ QStandardItem *firstItem = model.item(0, 0);
+ firstItem->setFlags(firstItem->flags() | Qt::ItemNeverHasChildren);
+
+ QTreeView view;
+ view.setModel(&model);
+
+ QSignalSpy spy(&view, SIGNAL(expanded(QModelIndex)));
+ QVERIFY(spy.isValid());
+
+ view.expand(model.index(0, 0));
+ QCOMPARE(spy.count(), 0);
+
+ view.expand(model.index(1, 0));
+ QCOMPARE(spy.count(), 1);
+ }
+ {
+ QStringListModel model(QStringList() << "one" << "two");
+ QTreeView view;
+ view.setModel(&model);
+
+ QSignalSpy spy(&view, SIGNAL(expanded(QModelIndex)));
+ QVERIFY(spy.isValid());
+
+ view.expand(model.index(0, 0));
+ QCOMPARE(spy.count(), 0);
+ view.expandAll();
+ QCOMPARE(spy.count(), 0);
+ }
+}
+
void tst_QTreeView::expandAndCollapse_data()
{
QTest::addColumn<bool>("animationEnabled");
@@ -1581,13 +1623,10 @@ void tst_QTreeView::expandAndCollapseAll()
for (int r = 0; r < rows; ++r)
parents.push(model.index(r, 0, p));
}
-// ### why is expanded() signal not emitted?
-// QCOMPARE(expandedSpy.count(), count);
+ QCOMPARE(expandedSpy.count(), 12); // == (3+1)*(2+1) from QtTestModel model(3, 2);
view.collapseAll();
- QCOMPARE(expandedSpy.count(), 0);
-
parents.push(QModelIndex());
count = 0;
while (!parents.isEmpty()) {
@@ -1599,8 +1638,7 @@ void tst_QTreeView::expandAndCollapseAll()
for (int r = 0; r < rows; ++r)
parents.push(model.index(r, 0, p));
}
-// ### why is collapsed() signal not emitted?
-// QCOMPARE(collapsedSpy.count(), count);
+ QCOMPARE(collapsedSpy.count(), 12);
}
void tst_QTreeView::expandWithNoChildren()
@@ -1765,7 +1803,7 @@ void tst_QTreeView::moveCursor()
QCOMPARE(view.currentIndex(), expected);
//then pressing down should go to the next line
- QModelIndex actual = view.moveCursor(PublicView::MoveDown, Qt::NoModifier);
+ QModelIndex actual = view.doMoveCursor(PublicView::MoveDown, Qt::NoModifier);
expected = model.index(2, 1, QModelIndex());
QCOMPARE(actual, expected);
@@ -1774,7 +1812,7 @@ void tst_QTreeView::moveCursor()
// PageUp was broken with uniform row heights turned on
view.setCurrentIndex(model.index(1, 0));
- actual = view.moveCursor(PublicView::MovePageUp, Qt::NoModifier);
+ actual = view.doMoveCursor(PublicView::MovePageUp, Qt::NoModifier);
expected = model.index(0, 0, QModelIndex());
QCOMPARE(actual, expected);
@@ -2818,7 +2856,7 @@ void tst_QTreeView::evilModel()
view.setSelection(rect, QItemSelectionModel::Select);
model.change();
- view.moveCursor(PublicView::MoveDown, Qt::NoModifier);
+ view.doMoveCursor(PublicView::MoveDown, Qt::NoModifier);
model.change();
view.resizeColumnToContents(1);
@@ -4158,6 +4196,47 @@ void tst_QTreeView::taskQTBUG_18539_emitLayoutChanged()
QCOMPARE(afterRISpy.size(), 0);
}
+void tst_QTreeView::taskQTBUG_8176_emitOnExpandAll()
+{
+ QTreeWidget tw;
+ QTreeWidgetItem *item = new QTreeWidgetItem(&tw, QStringList(QString("item 1")));
+ QTreeWidgetItem *item2 = new QTreeWidgetItem(item, QStringList(QString("item 2")));
+ new QTreeWidgetItem(item2, QStringList(QString("item 3")));
+ new QTreeWidgetItem(item2, QStringList(QString("item 4")));
+ QTreeWidgetItem *item5 = new QTreeWidgetItem(&tw, QStringList(QString("item 5")));
+ new QTreeWidgetItem(item5, QStringList(QString("item 6")));
+ QSignalSpy spy(&tw, SIGNAL(expanded(const QModelIndex&)));
+
+ // expand all
+ tw.expandAll();
+ QCOMPARE(spy.size(), 6);
+ spy.clear();
+ tw.collapseAll();
+ item2->setExpanded(true);
+ spy.clear();
+ tw.expandAll();
+ QCOMPARE(spy.size(), 5);
+
+ // collapse all
+ QSignalSpy spy2(&tw, SIGNAL(collapsed(const QModelIndex&)));
+ tw.collapseAll();
+ QCOMPARE(spy2.size(), 6);
+ tw.expandAll();
+ item2->setExpanded(false);
+ spy2.clear();
+ tw.collapseAll();
+ QCOMPARE(spy2.size(), 5);
+
+ // expand to depth
+ item2->setExpanded(true);
+ spy.clear();
+ spy2.clear();
+ tw.expandToDepth(0);
+
+ QCOMPARE(spy.size(), 2); // item and item5 are expanded
+ QCOMPARE(spy2.size(), 1); // item2 is collapsed
+}
+
#ifndef QT_NO_ANIMATION
void tst_QTreeView::quickExpandCollapse()
{
@@ -4176,7 +4255,7 @@ void tst_QTreeView::quickExpandCollapse()
QVERIFY(rootIndex.isValid());
tree.show();
- QTest::qWaitForWindowShown(&tree);
+ QTest::qWaitForWindowExposed(&tree);
int initialState = tree.state();
diff --git a/tests/auto/widgets/itemviews/qtreewidget/qtreewidget.pro b/tests/auto/widgets/itemviews/qtreewidget/qtreewidget.pro
index 8e17d1b83f..3fa0681691 100644
--- a/tests/auto/widgets/itemviews/qtreewidget/qtreewidget.pro
+++ b/tests/auto/widgets/itemviews/qtreewidget/qtreewidget.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qtreewidget
QT += widgets testlib
SOURCES += tst_qtreewidget.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qtreewidget/tst_qtreewidget.cpp b/tests/auto/widgets/itemviews/qtreewidget/tst_qtreewidget.cpp
index f119c3fbec..83ba1ddcda 100644
--- a/tests/auto/widgets/itemviews/qtreewidget/tst_qtreewidget.cpp
+++ b/tests/auto/widgets/itemviews/qtreewidget/tst_qtreewidget.cpp
@@ -467,7 +467,7 @@ void tst_QTreeWidget::editItem()
tree.editItem(item, col);
QApplication::instance()->processEvents();
QApplication::instance()->processEvents();
- QLineEdit *editor = qFindChild<QLineEdit*>(&tree);
+ QLineEdit *editor = tree.findChild<QLineEdit*>();
if (editor) {
QVERIFY(item->flags() & Qt::ItemIsEditable);
QCOMPARE(editor->selectedText(), editor->text());
@@ -2079,7 +2079,7 @@ void tst_QTreeWidget::itemWidget()
// ### should you really be able to open a persistent
// editor for an item that isn't editable??
tree.openPersistentEditor(item, col);
- QWidget *editor = qFindChild<QLineEdit*>(&tree);
+ QWidget *editor = tree.findChild<QLineEdit*>();
QVERIFY(editor != 0);
tree.closePersistentEditor(item, col);
}
diff --git a/tests/auto/widgets/itemviews/qtreewidgetitemiterator/qtreewidgetitemiterator.pro b/tests/auto/widgets/itemviews/qtreewidgetitemiterator/qtreewidgetitemiterator.pro
index f2025b6929..5fa6762617 100644
--- a/tests/auto/widgets/itemviews/qtreewidgetitemiterator/qtreewidgetitemiterator.pro
+++ b/tests/auto/widgets/itemviews/qtreewidgetitemiterator/qtreewidgetitemiterator.pro
@@ -5,4 +5,3 @@ QT += widgets testlib
SOURCES += tst_qtreewidgetitemiterator.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/itemviews/qtreewidgetitemiterator/tst_qtreewidgetitemiterator.cpp b/tests/auto/widgets/itemviews/qtreewidgetitemiterator/tst_qtreewidgetitemiterator.cpp
index 7ab68345fa..f1f9f1c01a 100644
--- a/tests/auto/widgets/itemviews/qtreewidgetitemiterator/tst_qtreewidgetitemiterator.cpp
+++ b/tests/auto/widgets/itemviews/qtreewidgetitemiterator/tst_qtreewidgetitemiterator.cpp
@@ -80,6 +80,7 @@ private slots:
void updateIteratorAfterDeletedItem_and_ContinueIteration_data();
void updateIteratorAfterDeletedItem_and_ContinueIteration();
void initializeIterator();
+ void sortingEnabled();
private:
QTreeWidget *testWidget;
};
@@ -1236,5 +1237,31 @@ void tst_QTreeWidgetItemIterator::initializeIterator()
QCOMPARE((*it), static_cast<QTreeWidgetItem*>(0));
}
+void tst_QTreeWidgetItemIterator::sortingEnabled()
+{
+ QTreeWidget *tree = new QTreeWidget;
+ tree->setColumnCount(2);
+ tree->headerItem()->setText(0, "Id");
+ tree->headerItem()->setText(1, "Color");
+
+ tree->setSortingEnabled(true);
+ tree->sortByColumn(0, Qt::AscendingOrder);
+
+ QTreeWidgetItem *second = new QTreeWidgetItem;
+ second->setText(0, "2");
+ second->setText(1, "second");
+ QTreeWidgetItem *first = new QTreeWidgetItem;
+ first->setText(0, "1");
+ first->setText(1, "first");
+
+ tree->addTopLevelItem(second);
+ tree->addTopLevelItem(first);
+
+ QTreeWidgetItemIterator it(tree);
+ QCOMPARE(*it, first);
+ ++it;
+ QCOMPARE(*it, second);
+}
+
QTEST_MAIN(tst_QTreeWidgetItemIterator)
#include "tst_qtreewidgetitemiterator.moc"
diff --git a/tests/auto/widgets/kernel/kernel.pro b/tests/auto/widgets/kernel/kernel.pro
index b280f44f05..20720dc928 100644
--- a/tests/auto/widgets/kernel/kernel.pro
+++ b/tests/auto/widgets/kernel/kernel.pro
@@ -15,6 +15,7 @@ SUBDIRS=\
qwidgetaction \
qwidgetmetatype \
qwidgetsvariant \
+ qwindowcontainer \
qshortcut \
qsizepolicy
diff --git a/tests/auto/widgets/kernel/qaction/qaction.pro b/tests/auto/widgets/kernel/qaction/qaction.pro
index 2cd1351dd7..c57107b1b0 100644
--- a/tests/auto/widgets/kernel/qaction/qaction.pro
+++ b/tests/auto/widgets/kernel/qaction/qaction.pro
@@ -4,4 +4,3 @@ QT += gui-private core-private widgets testlib
SOURCES += tst_qaction.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qactiongroup/qactiongroup.pro b/tests/auto/widgets/kernel/qactiongroup/qactiongroup.pro
index 6acbc24d86..82c0204aa8 100644
--- a/tests/auto/widgets/kernel/qactiongroup/qactiongroup.pro
+++ b/tests/auto/widgets/kernel/qactiongroup/qactiongroup.pro
@@ -5,4 +5,3 @@ QT += widgets testlib
SOURCES += tst_qactiongroup.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qapplication/desktopsettingsaware/desktopsettingsaware.pro b/tests/auto/widgets/kernel/qapplication/desktopsettingsaware/desktopsettingsaware.pro
index 8084dd0f83..a10ff71b05 100644
--- a/tests/auto/widgets/kernel/qapplication/desktopsettingsaware/desktopsettingsaware.pro
+++ b/tests/auto/widgets/kernel/qapplication/desktopsettingsaware/desktopsettingsaware.pro
@@ -4,4 +4,3 @@ CONFIG -= app_bundle debug_and_release_target
DESTDIR = ./
SOURCES += main.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qapplication/modal/modal.pro b/tests/auto/widgets/kernel/qapplication/modal/modal.pro
index 1eac401b47..a34871d2aa 100644
--- a/tests/auto/widgets/kernel/qapplication/modal/modal.pro
+++ b/tests/auto/widgets/kernel/qapplication/modal/modal.pro
@@ -5,4 +5,3 @@ DESTDIR = ./
CONFIG -= app_bundle debug_and_release_target
HEADERS += base.h
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qapplication/test/test.pro b/tests/auto/widgets/kernel/qapplication/test/test.pro
index 53d18fa2df..7b00ba5293 100644
--- a/tests/auto/widgets/kernel/qapplication/test/test.pro
+++ b/tests/auto/widgets/kernel/qapplication/test/test.pro
@@ -13,6 +13,3 @@ SUBPROGRAMS = desktopsettingsaware modal
win32: !wince*: SUBPROGRAMS += wincmdline
for(file, SUBPROGRAMS): TEST_HELPER_INSTALLS += "../$${file}/$${file}"
-
-
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qapplication/tst_qapplication.cpp b/tests/auto/widgets/kernel/qapplication/tst_qapplication.cpp
index 52cd1051ba..c6835f6076 100644
--- a/tests/auto/widgets/kernel/qapplication/tst_qapplication.cpp
+++ b/tests/auto/widgets/kernel/qapplication/tst_qapplication.cpp
@@ -316,7 +316,6 @@ void tst_QApplication::alert()
widget.activateWindow();
QApplication::setActiveWindow(&widget);
app.alert(&widget, 200);
- app.syncX();
}
void tst_QApplication::multiple_data()
@@ -1242,7 +1241,7 @@ public slots:
void DeleteLaterWidget::runTest()
{
- QObject *stillAlive = qFindChild<QObject*>(this, "deleteLater");
+ QObject *stillAlive = this->findChild<QObject*>("deleteLater");
QWidget *w = new QWidget(this);
connect(w, SIGNAL(destroyed()), this, SLOT(childDeleted()));
@@ -1288,7 +1287,7 @@ void tst_QApplication::testDeleteLater()
object->setObjectName("deleteLater");
object->deleteLater();
- QObject *stillAlive = qFindChild<QObject*>(wgt, "deleteLater");
+ QObject *stillAlive = wgt->findChild<QObject*>("deleteLater");
QVERIFY(stillAlive);
app.exec();
diff --git a/tests/auto/widgets/kernel/qapplication/wincmdline/main.cpp b/tests/auto/widgets/kernel/qapplication/wincmdline/main.cpp
index e24c21feab..e935cfd53a 100644
--- a/tests/auto/widgets/kernel/qapplication/wincmdline/main.cpp
+++ b/tests/auto/widgets/kernel/qapplication/wincmdline/main.cpp
@@ -40,14 +40,15 @@
****************************************************************************/
#include <QApplication>
#include <stdio.h>
-int main(int argc, char *argv[])
+
+int main(int argc, char *argv[])
{
- QApplication app(argc, argv);
+ QApplication app(argc, argv);
if (argc > 1)
fprintf(stderr, "%s", argv[1]);
else
fprintf(stderr, "Failed");
fflush(stderr);
- return 0;
+ return 0;
}
diff --git a/tests/auto/widgets/kernel/qapplication/wincmdline/wincmdline.pro b/tests/auto/widgets/kernel/qapplication/wincmdline/wincmdline.pro
index d4759da7a8..3e32a6798d 100644
--- a/tests/auto/widgets/kernel/qapplication/wincmdline/wincmdline.pro
+++ b/tests/auto/widgets/kernel/qapplication/wincmdline/wincmdline.pro
@@ -3,4 +3,3 @@ CONFIG -= app_bundle debug_and_release_target
SOURCES += main.cpp
DESTDIR = ./
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qboxlayout/qboxlayout.pro b/tests/auto/widgets/kernel/qboxlayout/qboxlayout.pro
index b683a34e51..e30a4b57b1 100644
--- a/tests/auto/widgets/kernel/qboxlayout/qboxlayout.pro
+++ b/tests/auto/widgets/kernel/qboxlayout/qboxlayout.pro
@@ -5,4 +5,3 @@ QT += widgets testlib
SOURCES += tst_qboxlayout.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qdesktopwidget/qdesktopwidget.pro b/tests/auto/widgets/kernel/qdesktopwidget/qdesktopwidget.pro
index c0057661d2..77709df5da 100644
--- a/tests/auto/widgets/kernel/qdesktopwidget/qdesktopwidget.pro
+++ b/tests/auto/widgets/kernel/qdesktopwidget/qdesktopwidget.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qdesktopwidget
QT += widgets testlib
SOURCES += tst_qdesktopwidget.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qdesktopwidget/tst_qdesktopwidget.cpp b/tests/auto/widgets/kernel/qdesktopwidget/tst_qdesktopwidget.cpp
index 63ffc13c68..4efe8c4273 100644
--- a/tests/auto/widgets/kernel/qdesktopwidget/tst_qdesktopwidget.cpp
+++ b/tests/auto/widgets/kernel/qdesktopwidget/tst_qdesktopwidget.cpp
@@ -42,6 +42,7 @@
#include <QtTest/QtTest>
#include <QtWidgets/QDesktopWidget>
+#include <QtGui/QWindow>
#include <QDebug>
class tst_QDesktopWidget : public QObject
@@ -63,6 +64,7 @@ private slots:
void screenNumberForQPoint();
void availableGeometry();
void screenGeometry();
+ void topLevels();
};
tst_QDesktopWidget::tst_QDesktopWidget()
@@ -177,6 +179,21 @@ void tst_QDesktopWidget::screenGeometry()
}
}
+void tst_QDesktopWidget::topLevels()
+{
+ // Desktop widgets/windows should not be listed as top-levels.
+ int topLevelDesktopWidgets = 0;
+ int topLevelDesktopWindows = 0;
+ foreach (const QWidget *w, QApplication::topLevelWidgets())
+ if (w->windowType() == Qt::Desktop)
+ topLevelDesktopWidgets++;
+ foreach (const QWindow *w, QGuiApplication::topLevelWindows())
+ if (w->type() == Qt::Desktop)
+ topLevelDesktopWindows++;
+ QCOMPARE(topLevelDesktopWidgets, 0);
+ QCOMPARE(topLevelDesktopWindows, 0);
+}
+
QTEST_MAIN(tst_QDesktopWidget)
#include "tst_qdesktopwidget.moc"
diff --git a/tests/auto/widgets/kernel/qformlayout/qformlayout.pro b/tests/auto/widgets/kernel/qformlayout/qformlayout.pro
index 4a522bbf72..668b890c97 100644
--- a/tests/auto/widgets/kernel/qformlayout/qformlayout.pro
+++ b/tests/auto/widgets/kernel/qformlayout/qformlayout.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qformlayout
QT += widgets testlib
SOURCES += tst_qformlayout.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qformlayout/tst_qformlayout.cpp b/tests/auto/widgets/kernel/qformlayout/tst_qformlayout.cpp
index d77dd003d7..b970de8e87 100644
--- a/tests/auto/widgets/kernel/qformlayout/tst_qformlayout.cpp
+++ b/tests/auto/widgets/kernel/qformlayout/tst_qformlayout.cpp
@@ -169,11 +169,11 @@ void tst_QFormLayout::rowCount()
fl->addRow(tr("Label 2"), new QLineEdit);
fl->addRow(tr("Label 3"), new QLineEdit);
QCOMPARE(fl->rowCount(), 3);
-
+
fl->addRow(new QWidget);
fl->addRow(new QHBoxLayout);
QCOMPARE(fl->rowCount(), 5);
-
+
fl->insertRow(1, tr("Label 0.5"), new QLineEdit);
QCOMPARE(fl->rowCount(), 6);
@@ -206,7 +206,7 @@ void tst_QFormLayout::buddies()
fl->addRow(le3);
QWidget *label3 = fl->labelForField(le3);
QVERIFY(label3 == 0);
-
+
//TODO: empty label?
delete w;
diff --git a/tests/auto/widgets/kernel/qgridlayout/qgridlayout.pro b/tests/auto/widgets/kernel/qgridlayout/qgridlayout.pro
index a952756080..febcee6c55 100644
--- a/tests/auto/widgets/kernel/qgridlayout/qgridlayout.pro
+++ b/tests/auto/widgets/kernel/qgridlayout/qgridlayout.pro
@@ -10,4 +10,3 @@ FORMS += sortdialog.ui
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qlayout/qlayout.pro b/tests/auto/widgets/kernel/qlayout/qlayout.pro
index c7751aa698..4a5db512c8 100644
--- a/tests/auto/widgets/kernel/qlayout/qlayout.pro
+++ b/tests/auto/widgets/kernel/qlayout/qlayout.pro
@@ -11,4 +11,3 @@ wince* {
} else {
TESTDATA += baseline/*
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp b/tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp
index f830ead6c0..2b9b4fd761 100644
--- a/tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp
+++ b/tests/auto/widgets/kernel/qlayout/tst_qlayout.cpp
@@ -155,7 +155,7 @@ void tst_QLayout::geometry()
void tst_QLayout::smartMaxSize()
{
- QVector<int> expectedWidths;
+ QVector<int> expectedWidths;
QFile f(QFINDTESTDATA("baseline/smartmaxsize"));
@@ -170,9 +170,9 @@ void tst_QLayout::smartMaxSize()
f.close();
int sizeCombinations[] = { 0, 10, 20, QWIDGETSIZE_MAX};
- QSizePolicy::Policy policies[] = { QSizePolicy::Fixed,
- QSizePolicy::Minimum,
- QSizePolicy::Maximum,
+ QSizePolicy::Policy policies[] = { QSizePolicy::Fixed,
+ QSizePolicy::Minimum,
+ QSizePolicy::Maximum,
QSizePolicy::Preferred,
QSizePolicy::Expanding,
QSizePolicy::MinimumExpanding,
@@ -250,7 +250,7 @@ void tst_QLayout::setContentsMargins()
MyLayout layout;
layout.invalidated = false;
int left, top, right, bottom;
-
+
layout.setContentsMargins(52, 53, 54, 55);
QVERIFY(layout.invalidated);
layout.invalidated = false;
@@ -260,7 +260,7 @@ void tst_QLayout::setContentsMargins()
QCOMPARE(top, 53);
QCOMPARE(right, 54);
QCOMPARE(bottom, 55);
-
+
layout.setContentsMargins(52, 53, 54, 55);
QVERIFY(!layout.invalidated);
}
diff --git a/tests/auto/widgets/kernel/qshortcut/qshortcut.pro b/tests/auto/widgets/kernel/qshortcut/qshortcut.pro
index 4d2e8d8acc..043d062d60 100644
--- a/tests/auto/widgets/kernel/qshortcut/qshortcut.pro
+++ b/tests/auto/widgets/kernel/qshortcut/qshortcut.pro
@@ -8,6 +8,3 @@ INCLUDEPATH += ../
QT += widgets testlib
HEADERS +=
SOURCES += tst_qshortcut.cpp
-
-
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qshortcut/tst_qshortcut.cpp b/tests/auto/widgets/kernel/qshortcut/tst_qshortcut.cpp
index 1958ebfab1..962fd3a8ab 100644
--- a/tests/auto/widgets/kernel/qshortcut/tst_qshortcut.cpp
+++ b/tests/auto/widgets/kernel/qshortcut/tst_qshortcut.cpp
@@ -610,7 +610,6 @@ void tst_QShortcut::disabledItems()
{
clearAllShortcuts();
mainW->activateWindow();
- qApp->syncX();
QTest::qWait(100);
/* Testing Disabled Shortcuts
@@ -1072,7 +1071,6 @@ void tst_QShortcut::context()
// Changing focus to 'other2' should make the Focus context there work
other2->activateWindow();
other2->setFocus(); // ###
- qApp->syncX();
QTRY_COMPARE(qApp->activeWindow(), other2->window());
QCOMPARE(qApp->focusWidget(), (QWidget *)other2);
diff --git a/tests/auto/widgets/kernel/qsizepolicy/qsizepolicy.pro b/tests/auto/widgets/kernel/qsizepolicy/qsizepolicy.pro
index 301d097b4f..84629c7c0a 100644
--- a/tests/auto/widgets/kernel/qsizepolicy/qsizepolicy.pro
+++ b/tests/auto/widgets/kernel/qsizepolicy/qsizepolicy.pro
@@ -4,4 +4,3 @@ TARGET = tst_qsizepolicy
QT += widgets widgets-private testlib
SOURCES += tst_qsizepolicy.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qstackedlayout/qstackedlayout.pro b/tests/auto/widgets/kernel/qstackedlayout/qstackedlayout.pro
index ad780e77fa..cd80253e12 100644
--- a/tests/auto/widgets/kernel/qstackedlayout/qstackedlayout.pro
+++ b/tests/auto/widgets/kernel/qstackedlayout/qstackedlayout.pro
@@ -6,4 +6,3 @@ SOURCES += tst_qstackedlayout.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qstackedlayout/tst_qstackedlayout.cpp b/tests/auto/widgets/kernel/qstackedlayout/tst_qstackedlayout.cpp
index c4c8022237..9ab7bb5305 100644
--- a/tests/auto/widgets/kernel/qstackedlayout/tst_qstackedlayout.cpp
+++ b/tests/auto/widgets/kernel/qstackedlayout/tst_qstackedlayout.cpp
@@ -132,7 +132,6 @@ void tst_QStackedLayout::init()
// make sure the tests work with focus follows mouse
QCursor::setPos(testWidget->geometry().center());
testWidget->activateWindow();
- QApplication::syncX();
QTest::qWait(250);
}
diff --git a/tests/auto/widgets/kernel/qtooltip/qtooltip.pro b/tests/auto/widgets/kernel/qtooltip/qtooltip.pro
index 8a875d3c6a..6e5dd738cb 100644
--- a/tests/auto/widgets/kernel/qtooltip/qtooltip.pro
+++ b/tests/auto/widgets/kernel/qtooltip/qtooltip.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qtooltip
QT += widgets testlib
SOURCES += tst_qtooltip.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qtooltip/tst_qtooltip.cpp b/tests/auto/widgets/kernel/qtooltip/tst_qtooltip.cpp
index 2d3e3c1702..441277ef53 100644
--- a/tests/auto/widgets/kernel/qtooltip/tst_qtooltip.cpp
+++ b/tests/auto/widgets/kernel/qtooltip/tst_qtooltip.cpp
@@ -132,7 +132,7 @@ void tst_QToolTip::whatsThis()
{
qApp->setStyleSheet( "QWidget { font-size: 72px; }" );
QWhatsThis::showText(QPoint(0,0), "THis is text");
- QTest::qWait(400);
+ QTest::qWait(400);
QWidget *whatsthis = 0;
foreach (QWidget *widget, QApplication::topLevelWidgets()) {
if (widget->inherits("QWhatsThat")) {
diff --git a/tests/auto/widgets/kernel/qwidget/qwidget.pro b/tests/auto/widgets/kernel/qwidget/qwidget.pro
index 997311179a..6916ee85e6 100644
--- a/tests/auto/widgets/kernel/qwidget/qwidget.pro
+++ b/tests/auto/widgets/kernel/qwidget/qwidget.pro
@@ -23,4 +23,3 @@ x11 {
!wince*:win32: LIBS += -luser32 -lgdi32
mac:CONFIG+=insignificant_test # QTBUG-25300, QTBUG-23695
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp b/tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp
index ba60dd0c01..69d890fb7a 100644
--- a/tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp
+++ b/tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp
@@ -412,6 +412,7 @@ private slots:
void keyboardModifiers();
void mouseDoubleClickBubbling_QTBUG29680();
+ void largerThanScreen_QTBUG30142();
private:
bool ensureScreenSize(int width, int height);
@@ -4239,11 +4240,11 @@ void tst_QWidget::isOpaque()
*/
void tst_QWidget::scroll()
{
- if (m_platform == QStringLiteral("xcb"))
- QSKIP("X11: Skip unstable test");
+ const int w = qMin(500, qApp->desktop()->availableGeometry().width() / 2);
+ const int h = qMin(500, qApp->desktop()->availableGeometry().height() / 2);
UpdateWidget updateWidget;
- updateWidget.resize(500, 500);
+ updateWidget.resize(w, h);
updateWidget.reset();
updateWidget.move(QGuiApplication::primaryScreen()->geometry().center() - QPoint(250, 250));
updateWidget.show();
@@ -4255,8 +4256,8 @@ void tst_QWidget::scroll()
updateWidget.reset();
updateWidget.scroll(10, 10);
qApp->processEvents();
- QRegion dirty(QRect(0, 0, 500, 10));
- dirty += QRegion(QRect(0, 10, 10, 490));
+ QRegion dirty(QRect(0, 0, w, 10));
+ dirty += QRegion(QRect(0, 10, 10, h - 10));
QTRY_COMPARE(updateWidget.paintedRegion, dirty);
}
@@ -4265,11 +4266,14 @@ void tst_QWidget::scroll()
updateWidget.update(0, 0, 10, 10);
updateWidget.scroll(0, 10);
qApp->processEvents();
- QRegion dirty(QRect(0, 0, 500, 10));
+ QRegion dirty(QRect(0, 0, w, 10));
dirty += QRegion(QRect(0, 10, 10, 10));
QTRY_COMPARE(updateWidget.paintedRegion, dirty);
}
+ if (updateWidget.width() < 200 || updateWidget.height() < 200)
+ QSKIP("Skip this test due to too small screen geometry.");
+
{
updateWidget.reset();
updateWidget.update(0, 0, 100, 100);
@@ -5434,7 +5438,7 @@ void tst_QWidget::setToolTip()
QScopedPointer<QWidget> popup(new QWidget(0, Qt::Popup));
popup->setObjectName(QString::fromLatin1("tst_qwidget setToolTip #%1").arg(pass));
popup->setWindowTitle(popup->objectName());
- popup->resize(150, 50);
+ popup->setGeometry(50, 50, 150, 50);
QFrame *frame = new QFrame(popup.data());
frame->setGeometry(0, 0, 50, 50);
frame->setFrameStyle(QFrame::Box | QFrame::Plain);
@@ -5630,6 +5634,7 @@ void tst_QWidget::showHideShowX11()
qApp->installNativeEventFilter(&w);
w.show();
+ QVERIFY(QTest::qWaitForWindowExposed(&w));
w.hide();
QEventLoop eventLoop;
@@ -6125,7 +6130,7 @@ static void workaroundPaletteIssue(QWidget *widget)
if (!widget)
return;
- QWidget *navigationBar = qFindChild<QWidget *>(widget, QLatin1String("qt_calendar_navigationbar"));
+ QWidget *navigationBar = widget->findChild<QWidget *>(QLatin1String("qt_calendar_navigationbar"));
QVERIFY(navigationBar);
QPalette palette = navigationBar->palette();
@@ -6224,7 +6229,7 @@ void tst_QWidget::renderInvisible()
}
// Get navigation bar and explicitly hide it.
- QWidget *navigationBar = qFindChild<QWidget *>(calendar.data(), QLatin1String("qt_calendar_navigationbar"));
+ QWidget *navigationBar = calendar.data()->findChild<QWidget *>(QLatin1String("qt_calendar_navigationbar"));
QVERIFY(navigationBar);
navigationBar->hide();
@@ -6247,7 +6252,7 @@ void tst_QWidget::renderInvisible()
}
// Get next month button.
- QWidget *nextMonthButton = qFindChild<QWidget *>(navigationBar, QLatin1String("qt_calendar_nextmonth"));
+ QWidget *nextMonthButton = navigationBar->findChild<QWidget *>(QLatin1String("qt_calendar_nextmonth"));
QVERIFY(nextMonthButton);
{ // Render next month button.
@@ -7014,7 +7019,7 @@ void tst_QWidget::moveWindowInShowEvent()
// show it
widget.show();
- QVERIFY(QTest::qWaitForWindowShown(&widget));
+ QVERIFY(QTest::qWaitForWindowExposed(&widget));
QTest::qWait(100);
// it should have moved
QCOMPARE(widget.pos(), position);
@@ -10077,5 +10082,20 @@ void tst_QWidget::mouseDoubleClickBubbling_QTBUG29680()
QTRY_VERIFY(parent.triggered);
}
+void tst_QWidget::largerThanScreen_QTBUG30142()
+{
+ QWidget widget;
+ widget.resize(200, 4000);
+ widget.show();
+ QVERIFY(QTest::qWaitForWindowExposed(&widget));
+ QVERIFY(widget.frameGeometry().y() >= 0);
+
+ QWidget widget2;
+ widget2.resize(10000, 400);
+ widget2.show();
+ QVERIFY(QTest::qWaitForWindowExposed(&widget2));
+ QVERIFY(widget2.frameGeometry().x() >= 0);
+}
+
QTEST_MAIN(tst_QWidget)
#include "tst_qwidget.moc"
diff --git a/tests/auto/widgets/kernel/qwidget_window/qwidget_window.pro b/tests/auto/widgets/kernel/qwidget_window/qwidget_window.pro
index 9798f1559a..baa2823f9a 100644
--- a/tests/auto/widgets/kernel/qwidget_window/qwidget_window.pro
+++ b/tests/auto/widgets/kernel/qwidget_window/qwidget_window.pro
@@ -8,4 +8,3 @@ x11 {
LIBS += $$QMAKE_LIBS_X11
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qwidgetaction/qwidgetaction.pro b/tests/auto/widgets/kernel/qwidgetaction/qwidgetaction.pro
index 3f8b26791b..0029ebd51e 100644
--- a/tests/auto/widgets/kernel/qwidgetaction/qwidgetaction.pro
+++ b/tests/auto/widgets/kernel/qwidgetaction/qwidgetaction.pro
@@ -5,4 +5,3 @@ QT += widgets testlib
SOURCES += tst_qwidgetaction.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qwidgetmetatype/qwidgetmetatype.pro b/tests/auto/widgets/kernel/qwidgetmetatype/qwidgetmetatype.pro
index 3fb0db9426..55228e6a1e 100644
--- a/tests/auto/widgets/kernel/qwidgetmetatype/qwidgetmetatype.pro
+++ b/tests/auto/widgets/kernel/qwidgetmetatype/qwidgetmetatype.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qwidgetmetatype
QT += widgets testlib
SOURCES += tst_qwidgetmetatype.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qwidgetsvariant/qwidgetsvariant.pro b/tests/auto/widgets/kernel/qwidgetsvariant/qwidgetsvariant.pro
index 9ad0e9a8c8..e3f2da96bd 100644
--- a/tests/auto/widgets/kernel/qwidgetsvariant/qwidgetsvariant.pro
+++ b/tests/auto/widgets/kernel/qwidgetsvariant/qwidgetsvariant.pro
@@ -5,4 +5,3 @@ INCLUDEPATH += $$PWD/../../../other/qvariant_common
SOURCES += tst_qwidgetsvariant.cpp
QT += testlib widgets
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/kernel/qwindowcontainer/.gitignore b/tests/auto/widgets/kernel/qwindowcontainer/.gitignore
new file mode 100644
index 0000000000..038f477220
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwindowcontainer/.gitignore
@@ -0,0 +1 @@
+tst_qwindowcontainer
diff --git a/tests/auto/widgets/kernel/qwindowcontainer/qwindowcontainer.pro b/tests/auto/widgets/kernel/qwindowcontainer/qwindowcontainer.pro
new file mode 100644
index 0000000000..4ff05eb04a
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwindowcontainer/qwindowcontainer.pro
@@ -0,0 +1,6 @@
+CONFIG += testcase
+mac:CONFIG -= app_bundle
+# CONFIG += parallel_test // Cannot be parallel due to the activation test
+TARGET = tst_qwindowcontainer
+QT += widgets testlib
+SOURCES += tst_qwindowcontainer.cpp
diff --git a/tests/auto/widgets/kernel/qwindowcontainer/tst_qwindowcontainer.cpp b/tests/auto/widgets/kernel/qwindowcontainer/tst_qwindowcontainer.cpp
new file mode 100644
index 0000000000..440639cd49
--- /dev/null
+++ b/tests/auto/widgets/kernel/qwindowcontainer/tst_qwindowcontainer.cpp
@@ -0,0 +1,226 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+#include <QtTest/QtTest>
+
+#include <qapplication.h>
+#include <qwindow.h>
+#include <qwidget.h>
+
+
+
+class Window : public QWindow
+{
+public:
+ Window()
+ : numberOfExposes(0)
+ , numberOfObscures(0)
+ {
+ }
+
+ void exposeEvent(QExposeEvent *) {
+ if (isExposed())
+ ++numberOfExposes;
+ else
+ ++numberOfObscures;
+ }
+
+ int numberOfExposes;
+ int numberOfObscures;
+};
+
+
+
+class tst_QWindowContainer: public QObject
+{
+ Q_OBJECT
+private slots:
+ void testShow();
+ void testPositionAndSize();
+ void testExposeObscure();
+ void testOwnership();
+ void testBehindTheScenesDeletion();
+ void testUnparenting();
+ void testActivation();
+};
+
+
+
+void tst_QWindowContainer::testShow()
+{
+ QWidget root;
+ root.setGeometry(100, 100, 400, 400);
+
+ Window *window = new Window();
+ QWidget *container = QWidget::createWindowContainer(window, &root);
+
+ container->setGeometry(50, 50, 200, 200);
+
+ root.show();
+
+ QVERIFY(QTest::qWaitForWindowExposed(window));
+}
+
+
+
+void tst_QWindowContainer::testPositionAndSize()
+{
+ QWindow *window = new QWindow();
+ window->setGeometry(300, 400, 500, 600);
+
+ QWidget *container = QWidget::createWindowContainer(window);
+ container->setGeometry(50, 50, 200, 200);
+
+
+ container->show();
+ QVERIFY(QTest::qWaitForWindowExposed(container));
+
+ QCOMPARE(window->x(), 0);
+ QCOMPARE(window->y(), 0);
+ QCOMPARE(window->width(), container->width());
+ QCOMPARE(window->height(), container->height());
+}
+
+
+
+void tst_QWindowContainer::testExposeObscure()
+{
+ Window *window = new Window();
+
+ QWidget *container = QWidget::createWindowContainer(window);
+ container->setGeometry(50, 50, 200, 200);
+
+ container->show();
+ QVERIFY(QTest::qWaitForWindowExposed(container));
+ QVERIFY(QTest::qWaitForWindowExposed(window));
+
+ QVERIFY(window->numberOfExposes > 0);
+
+ container->hide();
+
+ QElapsedTimer timer;
+ timer.start();
+ while (window->numberOfObscures == 0 && timer.elapsed() < 5000) {
+ QTest::qWait(10);
+ }
+
+ QVERIFY(window->numberOfObscures > 0);
+}
+
+
+
+void tst_QWindowContainer::testOwnership()
+{
+ QPointer<QWindow> window(new QWindow());
+ QWidget *container = QWidget::createWindowContainer(window);
+
+ delete container;
+
+ QCOMPARE(window.data(), (QWindow *) 0);
+}
+
+
+
+void tst_QWindowContainer::testBehindTheScenesDeletion()
+{
+ QWindow *window = new QWindow();
+ QWidget *container = QWidget::createWindowContainer(window);
+
+ delete window;
+
+ // The child got removed, showing not should not have any side effects,
+ // such as for instance, crashing...
+ container->show();
+ QVERIFY(QTest::qWaitForWindowExposed(container));
+ delete container;
+}
+
+
+
+void tst_QWindowContainer::testActivation()
+{
+ QWidget root;
+
+ QWindow *window = new QWindow();
+ QWidget *container = QWidget::createWindowContainer(window, &root);
+
+ container->setGeometry(100, 100, 200, 100);
+ root.setGeometry(100, 100, 400, 300);
+
+ root.show();
+ root.activateWindow();
+
+ QVERIFY(QTest::qWaitForWindowActive(root.windowHandle()));
+ QVERIFY(QGuiApplication::focusWindow() == root.windowHandle());
+
+ // Under KDE (ubuntu 12.10), we experience that doing two activateWindow in a row
+ // does not work. The second gets ignored by the window manager, even though the
+ // timestamp in the xcb connection is unique for both.
+ if (QGuiApplication::platformName() == "xcb")
+ QTest::qWait(100);
+
+ window->requestActivate();
+ QVERIFY(QTest::qWaitForWindowActive(window));
+ QVERIFY(QGuiApplication::focusWindow() == window);
+}
+
+
+
+void tst_QWindowContainer::testUnparenting()
+{
+ QWindow *window = new QWindow();
+ QWidget *container = QWidget::createWindowContainer(window);
+ container->setGeometry(100, 100, 200, 100);
+
+ window->setParent(0);
+
+ container->show();
+
+ QVERIFY(QTest::qWaitForWindowExposed(container));
+
+ // Window should not be made visible by container..
+ QVERIFY(!window->isVisible());
+}
+
+QTEST_MAIN(tst_QWindowContainer)
+
+#include "tst_qwindowcontainer.moc"
diff --git a/tests/auto/widgets/styles/qmacstyle/qmacstyle.pro b/tests/auto/widgets/styles/qmacstyle/qmacstyle.pro
index 91b48f858d..4cd85ab7f2 100644
--- a/tests/auto/widgets/styles/qmacstyle/qmacstyle.pro
+++ b/tests/auto/widgets/styles/qmacstyle/qmacstyle.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qmacstyle
QT += widgets testlib
SOURCES += tst_qmacstyle.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/styles/qmacstyle/tst_qmacstyle.cpp b/tests/auto/widgets/styles/qmacstyle/tst_qmacstyle.cpp
index 12e9fe451c..7925820b70 100644
--- a/tests/auto/widgets/styles/qmacstyle/tst_qmacstyle.cpp
+++ b/tests/auto/widgets/styles/qmacstyle/tst_qmacstyle.cpp
@@ -117,7 +117,7 @@ void tst_QMacStyle::sizeHints_data()
void tst_QMacStyle::sizeHints()
{
- QFETCH(Size, size);
+ QFETCH(Size, size);
QDialog w;
setSize(&w, size);
@@ -234,7 +234,7 @@ void tst_QMacStyle::layoutMargins_data()
void tst_QMacStyle::layoutMargins()
{
- QFETCH(Size, size);
+ QFETCH(Size, size);
QWidget w;
setSize(&w, size);
diff --git a/tests/auto/widgets/styles/qstyle/qstyle.pro b/tests/auto/widgets/styles/qstyle/qstyle.pro
index 99fba3ca39..2b9268f35d 100644
--- a/tests/auto/widgets/styles/qstyle/qstyle.pro
+++ b/tests/auto/widgets/styles/qstyle/qstyle.pro
@@ -13,4 +13,3 @@ wince* {
} else {
DEFINES += SRCDIR=\\\"$$PWD\\\"
}
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/styles/qstyle/tst_qstyle.cpp b/tests/auto/widgets/styles/qstyle/tst_qstyle.cpp
index cf867194cc..ef91d6d3d2 100644
--- a/tests/auto/widgets/styles/qstyle/tst_qstyle.cpp
+++ b/tests/auto/widgets/styles/qstyle/tst_qstyle.cpp
@@ -234,7 +234,10 @@ void tst_QStyle::testProxyStyle()
QVERIFY(proxyStyle->baseStyle());
qApp->setStyle(proxyStyle);
- QProxyStyle doubleProxy(new QProxyStyle(QStyleFactory::create("Windows")));
+ QProxyStyle* baseStyle = new QProxyStyle("Windows");
+ QCOMPARE(baseStyle->baseStyle()->objectName(), style->objectName());
+
+ QProxyStyle doubleProxy(baseStyle);
QVERIFY(testAllFunctions(&doubleProxy));
CustomProxy customStyle;
@@ -686,7 +689,7 @@ void tst_QStyle::lineUpLayoutTest(QStyle *style)
widget.setLayout(&layout);
widget.setStyle(style);
// propagate the style.
- foreach (QWidget *w, qFindChildren<QWidget *>(&widget))
+ foreach (QWidget *w, widget.findChildren<QWidget *>())
w->setStyle(style);
widget.show();
QVERIFY(QTest::qWaitForWindowExposed(&widget));
@@ -738,7 +741,7 @@ public:
void tst_QStyle::testDrawingShortcuts()
{
- {
+ {
QWidget w;
setFrameless(&w);
QToolButton *tb = new QToolButton(&w);
@@ -768,14 +771,14 @@ void tst_QStyle::testDrawingShortcuts()
bool showMnemonic = dts->styleHint(QStyle::SH_UnderlineShortcut, &sotb, tb);
QVERIFY(dts->alignment & (showMnemonic ? Qt::TextShowMnemonic : Qt::TextHideMnemonic));
delete dts;
- }
+ }
}
#define SCROLLBAR_SPACING 33
class FrameTestStyle : public QProxyStyle {
public:
- FrameTestStyle() : QProxyStyle(QStyleFactory::create("Windows")) { }
+ FrameTestStyle() : QProxyStyle("Windows") { }
int styleHint(StyleHint hint, const QStyleOption *opt, const QWidget *widget, QStyleHintReturn *returnData) const {
if (hint == QStyle::SH_ScrollView_FrameOnlyAroundContents)
return 1;
diff --git a/tests/auto/widgets/styles/qstyleoption/qstyleoption.pro b/tests/auto/widgets/styles/qstyleoption/qstyleoption.pro
index 270515453c..2ca24c4f43 100644
--- a/tests/auto/widgets/styles/qstyleoption/qstyleoption.pro
+++ b/tests/auto/widgets/styles/qstyleoption/qstyleoption.pro
@@ -6,4 +6,3 @@ CONFIG += parallel_test
QT += widgets testlib
SOURCES += tst_qstyleoption.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/styles/qstyleoption/tst_qstyleoption.cpp b/tests/auto/widgets/styles/qstyleoption/tst_qstyleoption.cpp
index 1203e12045..8a00198cf1 100644
--- a/tests/auto/widgets/styles/qstyleoption/tst_qstyleoption.cpp
+++ b/tests/auto/widgets/styles/qstyleoption/tst_qstyleoption.cpp
@@ -44,7 +44,7 @@
#include <QStyleOption>
-class tst_QStyleOption: public QObject
+class tst_QStyleOption: public QObject
{
Q_OBJECT
@@ -54,7 +54,7 @@ private slots:
void copyconstructors();
};
-// Just a simple container for QStyleOption-pointer
+// Just a simple container for QStyleOption-pointer
struct StyleOptionPointerBase
{
QStyleOption *pointer;
@@ -80,7 +80,7 @@ void tst_QStyleOption::qstyleoptioncast_data()
{
QTest::addColumn<StyleOptionPointerBase *>("testOption");
QTest::addColumn<bool>("canCastToComplex");
- QTest::addColumn<int>("type");
+ QTest::addColumn<int>("type");
QTest::newRow("optionDefault") << stylePtr(new QStyleOption) << false << int(QStyleOption::SO_Default);
QTest::newRow("optionButton") << stylePtr(new QStyleOptionButton) << false << int(QStyleOption::SO_Button);
diff --git a/tests/auto/widgets/styles/qstylesheetstyle/qstylesheetstyle.pro b/tests/auto/widgets/styles/qstylesheetstyle/qstylesheetstyle.pro
index dca6a8c28d..c96004bd5d 100644
--- a/tests/auto/widgets/styles/qstylesheetstyle/qstylesheetstyle.pro
+++ b/tests/auto/widgets/styles/qstylesheetstyle/qstylesheetstyle.pro
@@ -6,4 +6,3 @@ SOURCES += tst_qstylesheetstyle.cpp
RESOURCES += resources.qrc
requires(contains(QT_CONFIG,private_tests))
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/styles/qstylesheetstyle/tst_qstylesheetstyle.cpp b/tests/auto/widgets/styles/qstylesheetstyle/tst_qstylesheetstyle.cpp
index 305bee4e49..24e3ac2c99 100644
--- a/tests/auto/widgets/styles/qstylesheetstyle/tst_qstylesheetstyle.cpp
+++ b/tests/auto/widgets/styles/qstylesheetstyle/tst_qstylesheetstyle.cpp
@@ -656,7 +656,7 @@ void tst_QStyleSheetStyle::fontPropagation()
QTabWidget tw;
tw.setStyleSheet("QTabWidget { font-size: 20pt; }");
QVERIFY(FONTSIZE(tw) == 20);
- QWidget *child = qFindChild<QWidget *>(&tw, "qt_tabwidget_tabbar");
+ QWidget *child = tw.findChild<QWidget *>("qt_tabwidget_tabbar");
QVERIFY2(child, "QTabWidget did not contain a widget named \"qt_tabwidget_tabbar\"");
QVERIFY(FONTSIZE(*child) == 20);
}
@@ -957,7 +957,7 @@ void tst_QStyleSheetStyle::tabAlignement()
tabWidget.resize(QSize(400,400));
topLevel.show();
QVERIFY(QTest::qWaitForWindowExposed(&topLevel));
- QTabBar *bar = qFindChild<QTabBar*>(&tabWidget);
+ QTabBar *bar = tabWidget.findChild<QTabBar*>();
QVERIFY(bar);
//check the tab is on the right
tabWidget.setStyleSheet("QTabWidget::tab-bar { alignment: right ; }");
@@ -1030,7 +1030,7 @@ void tst_QStyleSheetStyle::minmaxSizes()
QVERIFY(qAbs(page3->maximumSize().height() - 500 - 2) <= 2);
QVERIFY(qAbs(page3->minimumSize().height() - 250 - 2) <= 2);
QVERIFY(qAbs(page3->minimumSize().height() - 250 - 2) <= 2);
- QTabBar *bar = qFindChild<QTabBar*>(&tabWidget);
+ QTabBar *bar = tabWidget.findChild<QTabBar*>();
QVERIFY(bar);
#ifdef Q_OS_MAC
QEXPECT_FAIL("", "QTBUG-23686", Continue);
diff --git a/tests/auto/widgets/util/qcompleter/qcompleter.pro b/tests/auto/widgets/util/qcompleter/qcompleter.pro
index d28e44232c..19d8d500b8 100644
--- a/tests/auto/widgets/util/qcompleter/qcompleter.pro
+++ b/tests/auto/widgets/util/qcompleter/qcompleter.pro
@@ -4,4 +4,3 @@ TARGET = tst_qcompleter
QT += widgets testlib
SOURCES += tst_qcompleter.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/util/qcompleter/tst_qcompleter.cpp b/tests/auto/widgets/util/qcompleter/tst_qcompleter.cpp
index d0b9b0a14a..d7050033f3 100644
--- a/tests/auto/widgets/util/qcompleter/tst_qcompleter.cpp
+++ b/tests/auto/widgets/util/qcompleter/tst_qcompleter.cpp
@@ -178,6 +178,7 @@ private:
tst_QCompleter::tst_QCompleter() : completer(0), completionColumn(0), columnCount(3)
{
treeWidget = new QTreeWidget;
+ treeWidget->move(100, 100);
treeWidget->setColumnCount(columnCount);
}
@@ -1065,12 +1066,13 @@ void tst_QCompleter::modelDeletion()
completer->setCompletionPrefix("i");
completer->setModel(listModel);
QVERIFY(completer->completionCount() == 3);
- QListView *view = new QListView;
+ QScopedPointer<QListView> view(new QListView);
view->setModel(completer->completionModel());
delete listModel;
+ view->move(200, 200);
view->show();
qApp->processEvents();
- delete view;
+ view.reset();
QVERIFY(completer->completionCount() == 0);
QVERIFY(completer->currentRow() == -1);
}
@@ -1083,10 +1085,10 @@ void tst_QCompleter::multipleWidgets()
completer.setCompletionMode(QCompleter::InlineCompletion);
QWidget window;
+ window.move(200, 200);
window.show();
QApplication::setActiveWindow(&window);
QVERIFY(QTest::qWaitForWindowActive(&window));
- QVERIFY(qApp->activeWindow() == &window);
QFocusEvent focusIn(QEvent::FocusIn);
QFocusEvent focusOut(QEvent::FocusOut);
@@ -1128,13 +1130,11 @@ void tst_QCompleter::focusIn()
QCompleter completer(list);
QWidget window;
+ window.move(200, 200);
window.show();
- QTest::qWait(100);
window.activateWindow();
QApplication::setActiveWindow(&window);
- QTest::qWait(100);
-
- QTRY_COMPARE(qApp->activeWindow(), &window);
+ QVERIFY(QTest::qWaitForWindowActive(&window));
QComboBox *comboBox = new QComboBox(&window);
comboBox->setEditable(true);
@@ -1194,7 +1194,9 @@ void tst_QCompleter::disabledItems()
QCompleter *completer = new QCompleter(model, &lineEdit);
QSignalSpy spy(completer, SIGNAL(activated(QString)));
lineEdit.setCompleter(completer);
+ lineEdit.move(200, 200);
lineEdit.show();
+ QVERIFY(QTest::qWaitForWindowExposed(&lineEdit));
QTest::keyPress(&lineEdit, Qt::Key_S);
QTest::keyPress(&lineEdit, Qt::Key_U);
@@ -1212,15 +1214,19 @@ void tst_QCompleter::task178797_activatedOnReturn()
{
QStringList words;
words << "foobar1" << "foobar2";
- QLineEdit *ledit = new QLineEdit;
+ QLineEdit ledit;
+ setFrameless(&ledit);
QCompleter *completer = new QCompleter(words);
- ledit->setCompleter(completer);
+ ledit.setCompleter(completer);
QSignalSpy spy(completer, SIGNAL(activated(QString)));
QCOMPARE(spy.count(), 0);
- ledit->show();
- QTest::keyClick(ledit, Qt::Key_F);
+ ledit.move(200, 200);
+ ledit.show();
+ qApp->setActiveWindow(&ledit);
+ QVERIFY(QTest::qWaitForWindowActive(&ledit));
+ QTest::keyClick(&ledit, Qt::Key_F);
qApp->processEvents();
- QVERIFY(qApp->activePopupWidget());
+ QTRY_VERIFY(qApp->activePopupWidget());
QTest::keyClick(qApp->activePopupWidget(), Qt::Key_Down);
qApp->processEvents();
QTest::keyClick(qApp->activePopupWidget(), Qt::Key_Return);
@@ -1289,19 +1295,20 @@ private slots:
void tst_QCompleter::task246056_setCompletionPrefix()
{
- task246056_ComboBox *comboBox = new task246056_ComboBox;
- setFrameless(comboBox);
- QVERIFY(comboBox->completer());
- comboBox->addItem("");
- comboBox->addItem("a1");
- comboBox->addItem("a2");
- comboBox->show();
- comboBox->setFocus();
- QTest::qWait(100);
- QTest::keyPress(comboBox, 'a');
- QTest::keyPress(comboBox->completer()->popup(), Qt::Key_Down);
- QTest::keyPress(comboBox->completer()->popup(), Qt::Key_Down);
- QTest::keyPress(comboBox->completer()->popup(), Qt::Key_Enter); // don't crash!
+ task246056_ComboBox comboBox;
+ setFrameless(&comboBox);
+ QVERIFY(comboBox.completer());
+ comboBox.addItem("");
+ comboBox.addItem("a1");
+ comboBox.addItem("a2");
+ comboBox.move(200, 200);
+ comboBox.show();
+ QApplication::setActiveWindow(&comboBox);
+ QVERIFY(QTest::qWaitForWindowActive(&comboBox));
+ QTest::keyPress(&comboBox, 'a');
+ QTest::keyPress(comboBox.completer()->popup(), Qt::Key_Down);
+ QTest::keyPress(comboBox.completer()->popup(), Qt::Key_Down);
+ QTest::keyPress(comboBox.completer()->popup(), Qt::Key_Enter); // don't crash!
}
class task250064_TextEdit : public QTextEdit
@@ -1326,39 +1333,41 @@ class task250064_Widget : public QWidget
{
Q_OBJECT
public:
- task250064_TextEdit *textEdit;
-
- task250064_Widget(task250064_TextEdit *textEdit)
- : textEdit(textEdit)
+ task250064_Widget() : m_textEdit(new task250064_TextEdit)
{
QTabWidget *tabWidget = new QTabWidget;
tabWidget->setFocusPolicy(Qt::ClickFocus);
- tabWidget->addTab(textEdit, "untitled");
+ tabWidget->addTab(m_textEdit, "untitled");
QVBoxLayout *layout = new QVBoxLayout(this);
layout->addWidget(tabWidget);
- textEdit->setPlainText("bla bla bla");
- textEdit->setFocus();
+ m_textEdit->setPlainText("bla bla bla");
+ m_textEdit->setFocus();
}
void setCompletionModel()
{
- textEdit->completer->setModel(0);
+ m_textEdit->completer->setModel(0);
}
+
+ QTextEdit *textEdit() const { return m_textEdit; }
+
+private:
+ task250064_TextEdit *m_textEdit;
};
void tst_QCompleter::task250064_lostFocus()
{
- task250064_TextEdit *textEdit = new task250064_TextEdit;
- task250064_Widget *widget = new task250064_Widget(textEdit);
- widget->show();
- QTest::qWait(100);
- QTest::keyPress(textEdit, 'a');
- Qt::FocusPolicy origPolicy = textEdit->focusPolicy();
+ task250064_Widget widget;
+ widget.show();
+ QApplication::setActiveWindow(&widget);
+ QVERIFY(QTest::qWaitForWindowActive(&widget));
+ QTest::keyPress(widget.textEdit(), 'a');
+ Qt::FocusPolicy origPolicy = widget.textEdit()->focusPolicy();
QVERIFY(origPolicy != Qt::NoFocus);
- widget->setCompletionModel();
- QCOMPARE(textEdit->focusPolicy(), origPolicy);
+ widget.setCompletionModel();
+ QCOMPARE(widget.textEdit()->focusPolicy(), origPolicy);
}
void tst_QCompleter::task253125_lineEditCompletion_data()
@@ -1391,6 +1400,7 @@ void tst_QCompleter::task253125_lineEditCompletion()
QLineEdit edit;
edit.setCompleter(completer);
+ edit.move(200, 200);
edit.show();
edit.setFocus();
QApplication::setActiveWindow(&edit);
@@ -1423,6 +1433,7 @@ void tst_QCompleter::task247560_keyboardNavigation()
QLineEdit edit;
edit.setCompleter(&completer);
+ edit.move(200, 200);
edit.show();
edit.setFocus();
QApplication::setActiveWindow(&edit);
@@ -1543,6 +1554,7 @@ void tst_QCompleter::QTBUG_14292_filesystem()
comp.setModel(&model);
edit.setCompleter(&comp);
+ edit.move(200, 200);
edit.show();
QApplication::setActiveWindow(&edit);
QVERIFY(QTest::qWaitForWindowActive(&edit));
@@ -1583,6 +1595,7 @@ void tst_QCompleter::QTBUG_14292_filesystem()
QTRY_VERIFY(!comp.popup()->isVisible());
QWidget w;
+ w.move(400, 200);
w.show();
QApplication::setActiveWindow(&w);
QVERIFY(QTest::qWaitForWindowActive(&w));
diff --git a/tests/auto/widgets/util/qscroller/qscroller.pro b/tests/auto/widgets/util/qscroller/qscroller.pro
index 6f999f62c6..55f57f5ed1 100644
--- a/tests/auto/widgets/util/qscroller/qscroller.pro
+++ b/tests/auto/widgets/util/qscroller/qscroller.pro
@@ -4,4 +4,3 @@ TARGET = tst_qscroller
QT += widgets testlib gui-private
SOURCES += tst_qscroller.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/util/qscroller/tst_qscroller.cpp b/tests/auto/widgets/util/qscroller/tst_qscroller.cpp
index fa0db59311..bbd71a9284 100644
--- a/tests/auto/widgets/util/qscroller/tst_qscroller.cpp
+++ b/tests/auto/widgets/util/qscroller/tst_qscroller.cpp
@@ -153,7 +153,6 @@ void tst_QScroller::kineticScroll( tst_QScrollerWidget *sw, QPointF from, QPoint
QCOMPARE( s1->state(), QScroller::Inactive );
QScrollerProperties sp1 = QScroller::scroller(sw)->scrollerProperties();
- int fps = 60;
QTouchEvent::TouchPoint rawTouchPoint;
rawTouchPoint.setId(0);
@@ -192,8 +191,7 @@ void tst_QScroller::kineticScroll( tst_QScrollerWidget *sw, QPointF from, QPoint
QCOMPARE( sw->receivedPrepare, true );
- QTest::qWait(1000 / fps * 2); // wait until the first scroll move
- QCOMPARE( sw->receivedFirst, true );
+ QTRY_COMPARE( sw->receivedFirst, true );
QCOMPARE( sw->receivedScroll, true );
QCOMPARE( sw->receivedOvershoot, false );
@@ -365,6 +363,9 @@ void tst_QScroller::scrollerProperties()
void tst_QScroller::scrollTo()
{
+#ifdef Q_OS_MAC
+ QSKIP("Flakey test - https://bugreports.qt-project.org/browse/QTBUG-29950");
+#endif
{
tst_QScrollerWidget *sw = new tst_QScrollerWidget();
sw->scrollArea = QRectF( 0, 0, 1000, 1000 );
@@ -391,11 +392,9 @@ void tst_QScroller::scrollTo()
void tst_QScroller::scroll()
{
-#if defined(Q_OS_MACX) && (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_6)
- QSKIP("Mac OS X < 10.6 does not support QTouchEvents");
- return;
+#ifdef Q_OS_MAC
+ QSKIP("Flakey test - https://bugreports.qt-project.org/browse/QTBUG-30133");
#endif
-
#ifndef QT_NO_GESTURES
// -- good case. normal scroll
tst_QScrollerWidget *sw = new tst_QScrollerWidget();
@@ -406,7 +405,7 @@ void tst_QScroller::scroll()
QScroller *s1 = QScroller::scroller(sw);
kineticScroll(sw, QPointF(500, 500), QPoint(0, 0), QPoint(100, 100), QPoint(200, 200));
// now we should be scrolling
- QCOMPARE( s1->state(), QScroller::Scrolling );
+ QTRY_COMPARE( s1->state(), QScroller::Scrolling );
// wait until finished, check that no further first scroll is send
sw->receivedFirst = false;
@@ -438,11 +437,9 @@ void tst_QScroller::scroll()
void tst_QScroller::overshoot()
{
-#if defined(Q_OS_MACX) && (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_6)
- QSKIP("Mac OS X < 10.6 does not support QTouchEvents");
- return;
+#ifdef Q_OS_MAC
+ QSKIP("Flakey test - https://bugreports.qt-project.org/browse/QTBUG-29950");
#endif
-
#ifndef QT_NO_GESTURES
tst_QScrollerWidget *sw = new tst_QScrollerWidget();
sw->scrollArea = QRectF(0, 0, 1000, 1000);
diff --git a/tests/auto/widgets/util/qsystemtrayicon/qsystemtrayicon.pro b/tests/auto/widgets/util/qsystemtrayicon/qsystemtrayicon.pro
index 68b2d85a64..d409d23650 100644
--- a/tests/auto/widgets/util/qsystemtrayicon/qsystemtrayicon.pro
+++ b/tests/auto/widgets/util/qsystemtrayicon/qsystemtrayicon.pro
@@ -9,4 +9,3 @@ QT += widgets testlib
SOURCES += tst_qsystemtrayicon.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/util/qundogroup/qundogroup.pro b/tests/auto/widgets/util/qundogroup/qundogroup.pro
index a74ef2b511..bd8dac197b 100644
--- a/tests/auto/widgets/util/qundogroup/qundogroup.pro
+++ b/tests/auto/widgets/util/qundogroup/qundogroup.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
QT += widgets testlib
SOURCES += tst_qundogroup.cpp
TARGET = tst_qundogroup
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/util/qundogroup/tst_qundogroup.cpp b/tests/auto/widgets/util/qundogroup/tst_qundogroup.cpp
index c8a12a9866..ddab98ebc6 100644
--- a/tests/auto/widgets/util/qundogroup/tst_qundogroup.cpp
+++ b/tests/auto/widgets/util/qundogroup/tst_qundogroup.cpp
@@ -599,7 +599,7 @@ void tst_QUndoGroup::addStackAndDie()
{
// Test that QUndoStack doesn't keep a reference to QUndoGroup after the
// group is deleted.
- QUndoStack *stack = new QUndoStack;
+ QUndoStack *stack = new QUndoStack;
QUndoGroup *group = new QUndoGroup;
group->addStack(stack);
delete group;
diff --git a/tests/auto/widgets/util/qundostack/qundostack.pro b/tests/auto/widgets/util/qundostack/qundostack.pro
index e473e1a275..294debb51c 100644
--- a/tests/auto/widgets/util/qundostack/qundostack.pro
+++ b/tests/auto/widgets/util/qundostack/qundostack.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
QT += widgets testlib
SOURCES += tst_qundostack.cpp
TARGET = tst_qundostack
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/util/qundostack/tst_qundostack.cpp b/tests/auto/widgets/util/qundostack/tst_qundostack.cpp
index 9b48dc7798..4556816655 100644
--- a/tests/auto/widgets/util/qundostack/tst_qundostack.cpp
+++ b/tests/auto/widgets/util/qundostack/tst_qundostack.cpp
@@ -290,52 +290,52 @@ static void checkState(QSignalSpy &redoTextChangedSpy,
const bool _undoChanged,
const bool _redoChanged)
{
- QCOMPARE(stack.count(), _count);
- QCOMPARE(stack.isClean(), _clean);
- QCOMPARE(stack.index(), _index);
- QCOMPARE(stack.canUndo(), _canUndo);
- QCOMPARE(stack.undoText(), QString(_undoText));
- QCOMPARE(stack.canRedo(), _canRedo);
- QCOMPARE(stack.redoText(), QString(_redoText));
- if (_indexChanged) {
- QCOMPARE(indexChangedSpy.count(), 1);
- QCOMPARE(indexChangedSpy.at(0).at(0).toInt(), _index);
- indexChangedSpy.clear();
- } else {
- QCOMPARE(indexChangedSpy.count(), 0);
- }
- if (_cleanChanged) {
- QCOMPARE(cleanChangedSpy.count(), 1);
- QCOMPARE(cleanChangedSpy.at(0).at(0).toBool(), _clean);
- cleanChangedSpy.clear();
- } else {
- QCOMPARE(cleanChangedSpy.count(), 0);
- }
- if (_undoChanged) {
- QCOMPARE(canUndoChangedSpy.count(), 1);
- QCOMPARE(canUndoChangedSpy.at(0).at(0).toBool(), _canUndo);
- QCOMPARE(undoAction->isEnabled(), _canUndo);
- QCOMPARE(undoTextChangedSpy.count(), 1);
- QCOMPARE(undoTextChangedSpy.at(0).at(0).toString(), QString(_undoText));
- QCOMPARE(undoAction->text(), glue("foo", _undoText));
- canUndoChangedSpy.clear();
- undoTextChangedSpy.clear();
- } else {
- QCOMPARE(canUndoChangedSpy.count(), 0);
- QCOMPARE(undoTextChangedSpy.count(), 0);
- }
- if (_redoChanged) {
- QCOMPARE(canRedoChangedSpy.count(), 1);
- QCOMPARE(canRedoChangedSpy.at(0).at(0).toBool(), _canRedo);
- QCOMPARE(redoAction->isEnabled(), _canRedo);
- QCOMPARE(redoTextChangedSpy.count(), 1);
- QCOMPARE(redoTextChangedSpy.at(0).at(0).toString(), QString(_redoText));
- QCOMPARE(redoAction->text(), glue("bar", _redoText));
- canRedoChangedSpy.clear();
- redoTextChangedSpy.clear();
- } else {
- QCOMPARE(canRedoChangedSpy.count(), 0);
- QCOMPARE(redoTextChangedSpy.count(), 0);
+ QCOMPARE(stack.count(), _count);
+ QCOMPARE(stack.isClean(), _clean);
+ QCOMPARE(stack.index(), _index);
+ QCOMPARE(stack.canUndo(), _canUndo);
+ QCOMPARE(stack.undoText(), QString(_undoText));
+ QCOMPARE(stack.canRedo(), _canRedo);
+ QCOMPARE(stack.redoText(), QString(_redoText));
+ if (_indexChanged) {
+ QCOMPARE(indexChangedSpy.count(), 1);
+ QCOMPARE(indexChangedSpy.at(0).at(0).toInt(), _index);
+ indexChangedSpy.clear();
+ } else {
+ QCOMPARE(indexChangedSpy.count(), 0);
+ }
+ if (_cleanChanged) {
+ QCOMPARE(cleanChangedSpy.count(), 1);
+ QCOMPARE(cleanChangedSpy.at(0).at(0).toBool(), _clean);
+ cleanChangedSpy.clear();
+ } else {
+ QCOMPARE(cleanChangedSpy.count(), 0);
+ }
+ if (_undoChanged) {
+ QCOMPARE(canUndoChangedSpy.count(), 1);
+ QCOMPARE(canUndoChangedSpy.at(0).at(0).toBool(), _canUndo);
+ QCOMPARE(undoAction->isEnabled(), _canUndo);
+ QCOMPARE(undoTextChangedSpy.count(), 1);
+ QCOMPARE(undoTextChangedSpy.at(0).at(0).toString(), QString(_undoText));
+ QCOMPARE(undoAction->text(), glue("foo", _undoText));
+ canUndoChangedSpy.clear();
+ undoTextChangedSpy.clear();
+ } else {
+ QCOMPARE(canUndoChangedSpy.count(), 0);
+ QCOMPARE(undoTextChangedSpy.count(), 0);
+ }
+ if (_redoChanged) {
+ QCOMPARE(canRedoChangedSpy.count(), 1);
+ QCOMPARE(canRedoChangedSpy.at(0).at(0).toBool(), _canRedo);
+ QCOMPARE(redoAction->isEnabled(), _canRedo);
+ QCOMPARE(redoTextChangedSpy.count(), 1);
+ QCOMPARE(redoTextChangedSpy.at(0).at(0).toString(), QString(_redoText));
+ QCOMPARE(redoAction->text(), glue("bar", _redoText));
+ canRedoChangedSpy.clear();
+ redoTextChangedSpy.clear();
+ } else {
+ QCOMPARE(canRedoChangedSpy.count(), 0);
+ QCOMPARE(redoTextChangedSpy.count(), 0);
}
}
diff --git a/tests/auto/widgets/widgets/qabstractbutton/qabstractbutton.pro b/tests/auto/widgets/widgets/qabstractbutton/qabstractbutton.pro
index 1873d4f42f..2f0111f483 100644
--- a/tests/auto/widgets/widgets/qabstractbutton/qabstractbutton.pro
+++ b/tests/auto/widgets/widgets/qabstractbutton/qabstractbutton.pro
@@ -4,4 +4,3 @@ QT += widgets testlib
SOURCES += tst_qabstractbutton.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qabstractscrollarea/qabstractscrollarea.pro b/tests/auto/widgets/widgets/qabstractscrollarea/qabstractscrollarea.pro
index 3bb8403333..911898407b 100644
--- a/tests/auto/widgets/widgets/qabstractscrollarea/qabstractscrollarea.pro
+++ b/tests/auto/widgets/widgets/qabstractscrollarea/qabstractscrollarea.pro
@@ -9,4 +9,3 @@ QT += widgets testlib
SOURCES += tst_qabstractscrollarea.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qabstractslider/qabstractslider.pro b/tests/auto/widgets/widgets/qabstractslider/qabstractslider.pro
index 4bf42fd055..020be08867 100644
--- a/tests/auto/widgets/widgets/qabstractslider/qabstractslider.pro
+++ b/tests/auto/widgets/widgets/qabstractslider/qabstractslider.pro
@@ -5,4 +5,3 @@ QT += widgets testlib
SOURCES += tst_qabstractslider.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qabstractspinbox/qabstractspinbox.pro b/tests/auto/widgets/widgets/qabstractspinbox/qabstractspinbox.pro
index 8efd364c5b..8fa1c0fcac 100644
--- a/tests/auto/widgets/widgets/qabstractspinbox/qabstractspinbox.pro
+++ b/tests/auto/widgets/widgets/qabstractspinbox/qabstractspinbox.pro
@@ -9,4 +9,3 @@ QT += widgets testlib
SOURCES += tst_qabstractspinbox.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qbuttongroup/qbuttongroup.pro b/tests/auto/widgets/widgets/qbuttongroup/qbuttongroup.pro
index 41c0e1d916..36049cdf0d 100644
--- a/tests/auto/widgets/widgets/qbuttongroup/qbuttongroup.pro
+++ b/tests/auto/widgets/widgets/qbuttongroup/qbuttongroup.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qbuttongroup.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qcalendarwidget/qcalendarwidget.pro b/tests/auto/widgets/widgets/qcalendarwidget/qcalendarwidget.pro
index 0232a0b026..f16110cbd1 100644
--- a/tests/auto/widgets/widgets/qcalendarwidget/qcalendarwidget.pro
+++ b/tests/auto/widgets/widgets/qcalendarwidget/qcalendarwidget.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qcalendarwidget
QT += widgets testlib
SOURCES += tst_qcalendarwidget.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qcalendarwidget/tst_qcalendarwidget.cpp b/tests/auto/widgets/widgets/qcalendarwidget/tst_qcalendarwidget.cpp
index 1d4a022aaf..14a8496b42 100644
--- a/tests/auto/widgets/widgets/qcalendarwidget/tst_qcalendarwidget.cpp
+++ b/tests/auto/widgets/widgets/qcalendarwidget/tst_qcalendarwidget.cpp
@@ -183,24 +183,24 @@ void tst_QCalendarWidget::buttonClickCheck()
QDate selectedDate(2005, 1, 1);
//click on the month buttons
int month = object.monthShown();
- QToolButton *button = qFindChild<QToolButton *>(&object, "qt_calendar_prevmonth");
+ QToolButton *button = object.findChild<QToolButton *>("qt_calendar_prevmonth");
QTest::mouseClick(button, Qt::LeftButton);
QCOMPARE(month > 1 ? month-1 : 12, object.monthShown());
- button = qFindChild<QToolButton *>(&object, "qt_calendar_nextmonth");
+ button = object.findChild<QToolButton *>("qt_calendar_nextmonth");
QTest::mouseClick(button, Qt::LeftButton);
QCOMPARE(month, object.monthShown());
- button = qFindChild<QToolButton *>(&object, "qt_calendar_yearbutton");
+ button = object.findChild<QToolButton *>("qt_calendar_yearbutton");
QTest::mouseClick(button, Qt::LeftButton, Qt::NoModifier, button->rect().center(), 2);
QVERIFY(!button->isVisible());
- QSpinBox *spinbox = qFindChild<QSpinBox *>(&object, "qt_calendar_yearedit");
+ QSpinBox *spinbox = object.findChild<QSpinBox *>("qt_calendar_yearedit");
QTest::qWait(500);
QTest::keyClick(spinbox, '2');
QTest::keyClick(spinbox, '0');
QTest::keyClick(spinbox, '0');
QTest::keyClick(spinbox, '6');
QTest::qWait(500);
- QWidget *widget = qFindChild<QWidget *>(&object, "qt_calendar_calendarview");
+ QWidget *widget = object.findChild<QWidget *>("qt_calendar_calendarview");
QTest::mouseMove(widget);
QTest::mouseClick(widget, Qt::LeftButton);
QCOMPARE(2006, object.yearShown());
@@ -212,11 +212,11 @@ void tst_QCalendarWidget::buttonClickCheck()
object.setDateRange(QDate(2006,1,1), QDate(2006,2,28));
object.setSelectedDate(QDate(2006,1,1));
object.showSelectedDate();
- button = qFindChild<QToolButton *>(&object, "qt_calendar_prevmonth");
+ button = object.findChild<QToolButton *>("qt_calendar_prevmonth");
QTest::mouseClick(button, Qt::LeftButton);
QCOMPARE(1, object.monthShown());
- button = qFindChild<QToolButton *>(&object, "qt_calendar_nextmonth");
+ button = object.findChild<QToolButton *>("qt_calendar_nextmonth");
QTest::mouseClick(button, Qt::LeftButton);
QCOMPARE(2, object.monthShown());
QTest::mouseClick(button, Qt::LeftButton);
@@ -351,7 +351,7 @@ void tst_QCalendarWidget::showPrevNext()
// QTBUG-4058
QTest::qWait(20);
- QToolButton *button = qFindChild<QToolButton *>(&calWidget, "qt_calendar_prevmonth");
+ QToolButton *button = calWidget.findChild<QToolButton *>("qt_calendar_prevmonth");
QTest::mouseClick(button, Qt::LeftButton);
expectedDate = expectedDate.addMonths(-1);
QCOMPARE(calWidget.yearShown(), expectedDate.year());
diff --git a/tests/auto/widgets/widgets/qcheckbox/qcheckbox.pro b/tests/auto/widgets/widgets/qcheckbox/qcheckbox.pro
index 78cd61e4cd..4282b25c9f 100644
--- a/tests/auto/widgets/widgets/qcheckbox/qcheckbox.pro
+++ b/tests/auto/widgets/widgets/qcheckbox/qcheckbox.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qcheckbox.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qcombobox/tst_qcombobox.cpp b/tests/auto/widgets/widgets/qcombobox/tst_qcombobox.cpp
index ef6a4571d9..7c468fcaed 100644
--- a/tests/auto/widgets/widgets/qcombobox/tst_qcombobox.cpp
+++ b/tests/auto/widgets/widgets/qcombobox/tst_qcombobox.cpp
@@ -2059,15 +2059,15 @@ void tst_QComboBox::task190351_layout()
listCombo.setCurrentIndex(70);
listCombo.showPopup();
QTRY_VERIFY(listCombo.view());
- QTest::qWaitForWindowShown(listCombo.view());
+ QTest::qWaitForWindowExposed(listCombo.view());
QTRY_VERIFY(listCombo.view()->isVisible());
QApplication::processEvents();
#ifdef QT_BUILD_INTERNAL
- QFrame *container = qFindChild<QComboBoxPrivateContainer *>(&listCombo);
+ QFrame *container = listCombo.findChild<QComboBoxPrivateContainer *>();
QVERIFY(container);
- QCOMPARE(static_cast<QAbstractItemView *>(list), qFindChild<QAbstractItemView *>(container));
- QWidget *top = qFindChild<QComboBoxPrivateScroller *>(container);
+ QCOMPARE(static_cast<QAbstractItemView *>(list), container->findChild<QAbstractItemView *>());
+ QWidget *top = container->findChild<QComboBoxPrivateScroller *>();
QVERIFY(top);
QVERIFY(top->isVisible());
QCOMPARE(top->mapToGlobal(QPoint(0, top->height())).y(), list->mapToGlobal(QPoint()).y());
@@ -2138,10 +2138,10 @@ void tst_QComboBox::task191329_size()
QTRY_VERIFY(tableCombo.view()->isVisible());
#ifdef QT_BUILD_INTERNAL
- QFrame *container = qFindChild<QComboBoxPrivateContainer *>(&tableCombo);
+ QFrame *container = tableCombo.findChild<QComboBoxPrivateContainer *>();
QVERIFY(container);
- QCOMPARE(static_cast<QAbstractItemView *>(table), qFindChild<QAbstractItemView *>(container));
- foreach (QWidget *button, qFindChildren<QComboBoxPrivateScroller *>(container)) {
+ QCOMPARE(static_cast<QAbstractItemView *>(table), container->findChild<QAbstractItemView *>());
+ foreach (QWidget *button, container->findChildren<QComboBoxPrivateScroller *>()) {
//the popup should be large enough to contains everithing so the top and left button are hidden
QVERIFY(!button->isVisible());
}
@@ -2197,11 +2197,11 @@ void tst_QComboBox::task248169_popupWithMinimalSize()
QTRY_VERIFY(comboBox.isVisible());
comboBox.showPopup();
QTRY_VERIFY(comboBox.view());
- QTest::qWaitForWindowShown(comboBox.view());
+ QTest::qWaitForWindowExposed(comboBox.view());
QTRY_VERIFY(comboBox.view()->isVisible());
#ifdef QT_BUILD_INTERNAL
- QFrame *container = qFindChild<QComboBoxPrivateContainer *>(&comboBox);
+ QFrame *container = comboBox.findChild<QComboBoxPrivateContainer *>();
QVERIFY(container);
QTRY_VERIFY(desktop.screenGeometry(container).contains(container->geometry()));
#endif
diff --git a/tests/auto/widgets/widgets/qcommandlinkbutton/qcommandlinkbutton.pro b/tests/auto/widgets/widgets/qcommandlinkbutton/qcommandlinkbutton.pro
index 4219ab3d7b..be3cfcd104 100644
--- a/tests/auto/widgets/widgets/qcommandlinkbutton/qcommandlinkbutton.pro
+++ b/tests/auto/widgets/widgets/qcommandlinkbutton/qcommandlinkbutton.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qcommandlinkbutton.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qdatetimeedit/qdatetimeedit.pro b/tests/auto/widgets/widgets/qdatetimeedit/qdatetimeedit.pro
index 44df6ef883..690edd5c9e 100644
--- a/tests/auto/widgets/widgets/qdatetimeedit/qdatetimeedit.pro
+++ b/tests/auto/widgets/widgets/qdatetimeedit/qdatetimeedit.pro
@@ -5,4 +5,3 @@ QT += widgets testlib core-private widgets-private
SOURCES += tst_qdatetimeedit.cpp
wincewm50smart-msvc2005: DEFINES += WINCE_NO_MODIFIER_KEYS
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qdatetimeedit/tst_qdatetimeedit.cpp b/tests/auto/widgets/widgets/qdatetimeedit/tst_qdatetimeedit.cpp
index 9ecb0650c5..bfffa357a8 100644
--- a/tests/auto/widgets/widgets/qdatetimeedit/tst_qdatetimeedit.cpp
+++ b/tests/auto/widgets/widgets/qdatetimeedit/tst_qdatetimeedit.cpp
@@ -316,7 +316,6 @@ void tst_QDateTimeEdit::getSetCheck()
tst_QDateTimeEdit::tst_QDateTimeEdit()
{
- qRegisterMetaType<QList<int> >("QList<int>");
}
tst_QDateTimeEdit::~tst_QDateTimeEdit()
@@ -759,6 +758,11 @@ void tst_QDateTimeEdit::displayFormat()
void tst_QDateTimeEdit::selectAndScrollWithKeys()
{
+#ifdef Q_OS_MAC
+ QSKIP("QTBUG-23674");
+ return;
+#endif
+
qApp->setActiveWindow(testWidget);
testWidget->setDate(QDate(2004, 05, 11));
testWidget->setDisplayFormat("dd/MM/yyyy");
@@ -769,9 +773,6 @@ void tst_QDateTimeEdit::selectAndScrollWithKeys()
QTest::keyClick(testWidget, Qt::Key_Home);
#endif
QTest::keyClick(testWidget, Qt::Key_Right, Qt::ShiftModifier);
-#ifdef Q_OS_MAC
- QEXPECT_FAIL("", "QTBUG-23674", Abort);
-#endif
QCOMPARE(testWidget->lineEdit()->selectedText(), QString("1"));
QTest::keyClick(testWidget, Qt::Key_Right, Qt::ShiftModifier);
QCOMPARE(testWidget->lineEdit()->selectedText(), QString("11"));
@@ -2817,7 +2818,7 @@ void tst_QDateTimeEdit::calendarPopup()
opt.subControls = QStyle::SC_ComboBoxArrow;
QRect rect = style->subControlRect(QStyle::CC_ComboBox, &opt, QStyle::SC_ComboBoxArrow, testWidget);
QTest::mouseClick(testWidget, Qt::LeftButton, 0, QPoint(rect.left()+rect.width()/2, rect.top()+rect.height()/2));
- QWidget *wid = qFindChild<QWidget *>(testWidget, "qt_datetimedit_calendar");
+ QWidget *wid = testWidget->findChild<QWidget *>("qt_datetimedit_calendar");
QVERIFY(wid != 0);
testWidget->hide();
@@ -2829,7 +2830,7 @@ void tst_QDateTimeEdit::calendarPopup()
opt.subControls = QStyle::SC_ComboBoxArrow;
rect = style->subControlRect(QStyle::CC_ComboBox, &opt, QStyle::SC_ComboBoxArrow, &timeEdit);
QTest::mouseClick(&timeEdit, Qt::LeftButton, 0, QPoint(rect.left()+rect.width()/2, rect.top()+rect.height()/2));
- QWidget *wid2 = qFindChild<QWidget *>(&timeEdit, "qt_datetimedit_calendar");
+ QWidget *wid2 = timeEdit.findChild<QWidget *>("qt_datetimedit_calendar");
QVERIFY(wid2 == 0);
timeEdit.hide();
@@ -2843,7 +2844,7 @@ void tst_QDateTimeEdit::calendarPopup()
opt.subControls = QStyle::SC_ComboBoxArrow;
rect = style->subControlRect(QStyle::CC_ComboBox, &opt, QStyle::SC_ComboBoxArrow, &dateEdit);
QTest::mouseClick(&dateEdit, Qt::LeftButton, 0, QPoint(rect.left()+rect.width()/2, rect.top()+rect.height()/2));
- QWidget *wid3 = qFindChild<QWidget *>(&dateEdit, "qt_datetimedit_calendar");
+ QWidget *wid3 = dateEdit.findChild<QWidget *>("qt_datetimedit_calendar");
QVERIFY(wid3 == 0);
dateEdit.hide();
}
@@ -3426,11 +3427,11 @@ void tst_QDateTimeEdit::deleteCalendarWidget()
edit.setCalendarPopup(true);
QVERIFY(edit.calendarWidget());
edit.calendarWidget()->setObjectName("cw1");;
-
+
// delete
cw = edit.calendarWidget();
delete cw;
-
+
// it should create a new widget
QVERIFY(edit.calendarWidget());
QVERIFY(edit.calendarWidget()->objectName() != "cw1");
diff --git a/tests/auto/widgets/widgets/qdial/qdial.pro b/tests/auto/widgets/widgets/qdial/qdial.pro
index 5c33916d15..0af9633236 100644
--- a/tests/auto/widgets/widgets/qdial/qdial.pro
+++ b/tests/auto/widgets/widgets/qdial/qdial.pro
@@ -5,4 +5,3 @@ QT += widgets testlib
SOURCES += tst_qdial.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qdialogbuttonbox/qdialogbuttonbox.pro b/tests/auto/widgets/widgets/qdialogbuttonbox/qdialogbuttonbox.pro
index fb7e799838..9892c48e0c 100644
--- a/tests/auto/widgets/widgets/qdialogbuttonbox/qdialogbuttonbox.pro
+++ b/tests/auto/widgets/widgets/qdialogbuttonbox/qdialogbuttonbox.pro
@@ -6,4 +6,3 @@ SOURCES += tst_qdialogbuttonbox.cpp
TARGET = tst_qdialogbuttonbox
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qdialogbuttonbox/tst_qdialogbuttonbox.cpp b/tests/auto/widgets/widgets/qdialogbuttonbox/tst_qdialogbuttonbox.cpp
index c7c9980f13..b0e454b643 100644
--- a/tests/auto/widgets/widgets/qdialogbuttonbox/tst_qdialogbuttonbox.cpp
+++ b/tests/auto/widgets/widgets/qdialogbuttonbox/tst_qdialogbuttonbox.cpp
@@ -68,8 +68,8 @@ public slots:
private slots:
void standardButtons();
void testConstructor1();
- void testConstrurtor2();
- void testConstrurtor2_data();
+ void testConstructor2();
+ void testConstructor2_data();
void testConstructor3();
void testConstructor3_data();
void setOrientation_data();
@@ -146,7 +146,7 @@ void tst_QDialogButtonBox::layoutReuse()
delete box;
}
-void tst_QDialogButtonBox::testConstrurtor2_data()
+void tst_QDialogButtonBox::testConstructor2_data()
{
QTest::addColumn<int>("orientation");
@@ -154,7 +154,7 @@ void tst_QDialogButtonBox::testConstrurtor2_data()
QTest::newRow("vertical") << int(Qt::Vertical);
}
-void tst_QDialogButtonBox::testConstrurtor2()
+void tst_QDialogButtonBox::testConstructor2()
{
QFETCH(int, orientation);
Qt::Orientation orient = Qt::Orientation(orientation);
@@ -265,7 +265,7 @@ void tst_QDialogButtonBox::addButton1()
QPushButton *button = new QPushButton();
buttonBox.addButton(button, role);
QTEST(buttonBox.buttons().count(), "totalCount");
- QList<QAbstractButton *> children = qFindChildren<QAbstractButton *>(&buttonBox);
+ QList<QAbstractButton *> children = buttonBox.findChildren<QAbstractButton *>();
QTEST(children.count(), "totalCount");
delete button;
}
@@ -292,7 +292,7 @@ void tst_QDialogButtonBox::addButton2()
QCOMPARE(buttonBox.buttons().count(), 0);
buttonBox.addButton(text, role);
QTEST(buttonBox.buttons().count(), "totalCount");
- QList<QAbstractButton *> children = qFindChildren<QAbstractButton *>(&buttonBox);
+ QList<QAbstractButton *> children = buttonBox.findChildren<QAbstractButton *>();
QTEST(children.count(), "totalCount");
}
@@ -319,7 +319,7 @@ void tst_QDialogButtonBox::addButton3()
QCOMPARE(buttonBox.buttons().count(), 0);
buttonBox.addButton(button);
QTEST(buttonBox.buttons().count(), "totalCount");
- QList<QAbstractButton *> children = qFindChildren<QAbstractButton *>(&buttonBox);
+ QList<QAbstractButton *> children = buttonBox.findChildren<QAbstractButton *>();
QTEST(children.count(), "totalCount");
}
@@ -341,7 +341,7 @@ void tst_QDialogButtonBox::clear()
buttonBox.addButton("Happy", QDialogButtonBox::ButtonRole(i));
buttonBox.clear();
QCOMPARE(buttonBox.buttons().count(), 0);
- QList<QAbstractButton *> children = qFindChildren<QAbstractButton *>(&buttonBox);
+ QList<QAbstractButton *> children = buttonBox.findChildren<QAbstractButton *>();
QCOMPARE(children.count(), 0);
}
@@ -376,11 +376,11 @@ void tst_QDialogButtonBox::testDelete()
QPushButton *deleteMe = new QPushButton("Happy");
buttonBox.addButton(deleteMe, QDialogButtonBox::HelpRole);
QCOMPARE(buttonBox.buttons().count(), 1);
- QList<QAbstractButton *> children = qFindChildren<QAbstractButton *>(&buttonBox);
+ QList<QAbstractButton *> children = buttonBox.findChildren<QAbstractButton *>();
QCOMPARE(children.count(), 1);
delete deleteMe;
- children = qFindChildren<QAbstractButton *>(&buttonBox);
+ children = buttonBox.findChildren<QAbstractButton *>();
QCOMPARE(children.count(), 0);
QCOMPARE(buttonBox.buttons().count(), 0);
}
diff --git a/tests/auto/widgets/widgets/qdockwidget/qdockwidget.pro b/tests/auto/widgets/widgets/qdockwidget/qdockwidget.pro
index e6b203fdd2..eca396f1a8 100644
--- a/tests/auto/widgets/widgets/qdockwidget/qdockwidget.pro
+++ b/tests/auto/widgets/widgets/qdockwidget/qdockwidget.pro
@@ -5,4 +5,3 @@ QT += widgets widgets-private testlib
QT += core-private gui-private
SOURCES += tst_qdockwidget.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qdoublespinbox/qdoublespinbox.pro b/tests/auto/widgets/widgets/qdoublespinbox/qdoublespinbox.pro
index e882ff3eae..cc66eaae26 100644
--- a/tests/auto/widgets/widgets/qdoublespinbox/qdoublespinbox.pro
+++ b/tests/auto/widgets/widgets/qdoublespinbox/qdoublespinbox.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qdoublespinbox
QT += widgets testlib
SOURCES += tst_qdoublespinbox.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qfocusframe/qfocusframe.pro b/tests/auto/widgets/widgets/qfocusframe/qfocusframe.pro
index 00cf56f1d9..6fa0589f95 100644
--- a/tests/auto/widgets/widgets/qfocusframe/qfocusframe.pro
+++ b/tests/auto/widgets/widgets/qfocusframe/qfocusframe.pro
@@ -9,4 +9,3 @@ QT += widgets testlib
SOURCES += tst_qfocusframe.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qfontcombobox/qfontcombobox.pro b/tests/auto/widgets/widgets/qfontcombobox/qfontcombobox.pro
index e3d19bb301..b21729bb9b 100644
--- a/tests/auto/widgets/widgets/qfontcombobox/qfontcombobox.pro
+++ b/tests/auto/widgets/widgets/qfontcombobox/qfontcombobox.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qfontcombobox
QT += widgets testlib
SOURCES += tst_qfontcombobox.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qgroupbox/qgroupbox.pro b/tests/auto/widgets/widgets/qgroupbox/qgroupbox.pro
index 7c5a4d30e5..4a5e76ff65 100644
--- a/tests/auto/widgets/widgets/qgroupbox/qgroupbox.pro
+++ b/tests/auto/widgets/widgets/qgroupbox/qgroupbox.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qgroupbox.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qlabel/qlabel.pro b/tests/auto/widgets/widgets/qlabel/qlabel.pro
index 8e9e7f04a5..6c259bc5a3 100644
--- a/tests/auto/widgets/widgets/qlabel/qlabel.pro
+++ b/tests/auto/widgets/widgets/qlabel/qlabel.pro
@@ -8,4 +8,3 @@ QT += core-private gui-private
SOURCES += tst_qlabel.cpp
TESTDATA += testdata/* *.png
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qlcdnumber/qlcdnumber.pro b/tests/auto/widgets/widgets/qlcdnumber/qlcdnumber.pro
index d70185b910..220380b1d5 100644
--- a/tests/auto/widgets/widgets/qlcdnumber/qlcdnumber.pro
+++ b/tests/auto/widgets/widgets/qlcdnumber/qlcdnumber.pro
@@ -9,4 +9,3 @@ QT += widgets testlib
SOURCES += tst_qlcdnumber.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qlineedit/qlineedit.pro b/tests/auto/widgets/widgets/qlineedit/qlineedit.pro
index 40eff1f968..715dcb9550 100644
--- a/tests/auto/widgets/widgets/qlineedit/qlineedit.pro
+++ b/tests/auto/widgets/widgets/qlineedit/qlineedit.pro
@@ -3,4 +3,3 @@ TARGET = tst_qlineedit
QT += gui-private core-private widgets widgets-private testlib
SOURCES += tst_qlineedit.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qlineedit/tst_qlineedit.cpp b/tests/auto/widgets/widgets/qlineedit/tst_qlineedit.cpp
index 210e52f0aa..3fa669c1fb 100644
--- a/tests/auto/widgets/widgets/qlineedit/tst_qlineedit.cpp
+++ b/tests/auto/widgets/widgets/qlineedit/tst_qlineedit.cpp
@@ -3902,6 +3902,11 @@ void tst_QLineEdit::inputMethod()
// removing focus allows input method to commit preedit
testWidget->setText("");
testWidget->activateWindow();
+ // TODO setFocus should not be necessary here, because activateWindow
+ // should focus it, and the window is the QLineEdit. But the test can fail
+ // on Windows if we don't do this. If each test had a unique QLineEdit
+ // instance, maybe such problems would go away.
+ testWidget->setFocus();
QTRY_VERIFY(testWidget->hasFocus());
QTRY_COMPARE(qApp->focusObject(), testWidget);
diff --git a/tests/auto/widgets/widgets/qmainwindow/qmainwindow.pro b/tests/auto/widgets/widgets/qmainwindow/qmainwindow.pro
index 28f1e417f0..bd4fc6ba97 100644
--- a/tests/auto/widgets/widgets/qmainwindow/qmainwindow.pro
+++ b/tests/auto/widgets/widgets/qmainwindow/qmainwindow.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qmainwindow
QT += widgets widgets-private testlib
SOURCES += tst_qmainwindow.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qmainwindow/tst_qmainwindow.cpp b/tests/auto/widgets/widgets/qmainwindow/tst_qmainwindow.cpp
index 6e3432b575..b42bfcac81 100644
--- a/tests/auto/widgets/widgets/qmainwindow/tst_qmainwindow.cpp
+++ b/tests/auto/widgets/widgets/qmainwindow/tst_qmainwindow.cpp
@@ -59,7 +59,7 @@
#include "../../../qtest-config.h"
-static uchar restoreData41[] = { 0x0, 0x0, 0x0, 0xff, 0x0, 0x0, 0x0, 0x0, 0xfc, 0x0, 0x0, 0x0, 0x0, 0xfd, 0x0, 0x0, 0x0, 0x4, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x64, 0x0, 0x0, 0x1, 0x19, 0xfc, 0x2, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x30, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x45, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x34, 0x1, 0x0, 0x0, 0x0, 0x49, 0x0, 0x0, 0x0, 0x40, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x38, 0x1, 0x0, 0x0, 0x0, 0x8d, 0x0, 0x0, 0x0, 0x43, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x32, 0x1, 0x0, 0x0, 0x0, 0xd4, 0x0, 0x0, 0x0, 0x45, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x64, 0x0, 0x0, 0x1, 0x19, 0xfc, 0x2, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x45, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x35, 0x1, 0x0, 0x0, 0x0, 0x49, 0x0, 0x0, 0x0, 0x40, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x39, 0x1, 0x0, 0x0, 0x0, 0x8d, 0x0, 0x0, 0x0, 0x43, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x33, 0x1, 0x0, 0x0, 0x0, 0xd4, 0x0, 0x0, 0x0, 0x45, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x2, 0x0, 0x0, 0x1, 0x89, 0x0, 0x0, 0x0, 0xe, 0xfc, 0x1, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x32, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x5f, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x36, 0x1, 0x0, 0x0, 0x0, 0x63, 0x0, 0x0, 0x0, 0x61, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x30, 0x1, 0x0, 0x0, 0x0, 0xc8, 0x0, 0x0, 0x0, 0x5e, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x34, 0x1, 0x0, 0x0, 0x1, 0x2a, 0x0, 0x0, 0x0, 0x5f, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x3, 0x0, 0x0, 0x1, 0x89, 0x0, 0x0, 0x0, 0xe, 0xfc, 0x1, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x33, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x5f, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x37, 0x1, 0x0, 0x0, 0x0, 0x63, 0x0, 0x0, 0x0, 0x61, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x31, 0x1, 0x0, 0x0, 0x0, 0xc8, 0x0, 0x0, 0x0, 0x5e, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x35, 0x1, 0x0, 0x0, 0x1, 0x2a, 0x0, 0x0, 0x0, 0x5f, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0xc1, 0x0, 0x0, 0x1, 0x19};
+static uchar restoreData41[] = { 0x0, 0x0, 0x0, 0xff, 0x0, 0x0, 0x0, 0x0, 0xfc, 0x0, 0x0, 0x0, 0x0, 0xfd, 0x0, 0x0, 0x0, 0x4, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x64, 0x0, 0x0, 0x1, 0x19, 0xfc, 0x2, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x30, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x45, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x34, 0x1, 0x0, 0x0, 0x0, 0x49, 0x0, 0x0, 0x0, 0x40, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x38, 0x1, 0x0, 0x0, 0x0, 0x8d, 0x0, 0x0, 0x0, 0x43, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x32, 0x1, 0x0, 0x0, 0x0, 0xd4, 0x0, 0x0, 0x0, 0x45, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x64, 0x0, 0x0, 0x1, 0x19, 0xfc, 0x2, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x45, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x35, 0x1, 0x0, 0x0, 0x0, 0x49, 0x0, 0x0, 0x0, 0x40, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x39, 0x1, 0x0, 0x0, 0x0, 0x8d, 0x0, 0x0, 0x0, 0x43, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x33, 0x1, 0x0, 0x0, 0x0, 0xd4, 0x0, 0x0, 0x0, 0x45, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x2, 0x0, 0x0, 0x1, 0x89, 0x0, 0x0, 0x0, 0xe, 0xfc, 0x1, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x32, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x5f, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x36, 0x1, 0x0, 0x0, 0x0, 0x63, 0x0, 0x0, 0x0, 0x61, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x30, 0x1, 0x0, 0x0, 0x0, 0xc8, 0x0, 0x0, 0x0, 0x5e, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x34, 0x1, 0x0, 0x0, 0x1, 0x2a, 0x0, 0x0, 0x0, 0x5f, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x3, 0x0, 0x0, 0x1, 0x89, 0x0, 0x0, 0x0, 0xe, 0xfc, 0x1, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x33, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x5f, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x37, 0x1, 0x0, 0x0, 0x0, 0x63, 0x0, 0x0, 0x0, 0x61, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x31, 0x1, 0x0, 0x0, 0x0, 0xc8, 0x0, 0x0, 0x0, 0x5e, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x35, 0x1, 0x0, 0x0, 0x1, 0x2a, 0x0, 0x0, 0x0, 0x5f, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0xc1, 0x0, 0x0, 0x1, 0x19};
static uchar restoreData42[] = { 0x0, 0x0, 0x0, 0xff, 0x0, 0x0, 0x0, 0x0, 0xfc, 0x0, 0x0, 0x0, 0x0, 0xfd, 0x0, 0x0, 0x0, 0x4, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x24, 0x0, 0x0, 0x2, 0x2b, 0xfc, 0x2, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x30, 0x1, 0x0, 0x0, 0x0, 0x2a, 0x0, 0x0, 0x0, 0x88, 0x0, 0x0, 0x0, 0x21, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x34, 0x1, 0x0, 0x0, 0x0, 0xb6, 0x0, 0x0, 0x0, 0x88, 0x0, 0x0, 0x0, 0x21, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x38, 0x1, 0x0, 0x0, 0x1, 0x42, 0x0, 0x0, 0x0, 0x87, 0x0, 0x0, 0x0, 0x21, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x32, 0x1, 0x0, 0x0, 0x1, 0xcd, 0x0, 0x0, 0x0, 0x88, 0x0, 0x0, 0x0, 0x21, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x98, 0x0, 0x0, 0x2, 0x2b, 0xfc, 0x2, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x1, 0x0, 0x0, 0x0, 0x2a, 0x0, 0x0, 0x0, 0x88, 0x0, 0x0, 0x0, 0x21, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x35, 0x1, 0x0, 0x0, 0x0, 0xb6, 0x0, 0x0, 0x0, 0x88, 0x0, 0x0, 0x0, 0x21, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x39, 0x1, 0x0, 0x0, 0x1, 0x42, 0x0, 0x0, 0x0, 0x87, 0x0, 0x0, 0x0, 0x21, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x33, 0x1, 0x0, 0x0, 0x1, 0xcd, 0x0, 0x0, 0x0, 0x88, 0x0, 0x0, 0x0, 0x21, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x2, 0x0, 0x0, 0x4, 0x4e, 0x0, 0x0, 0x0, 0x26, 0xfc, 0x1, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x32, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x12, 0x0, 0x0, 0x0, 0xa, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x36, 0x1, 0x0, 0x0, 0x1, 0x16, 0x0, 0x0, 0x1, 0xe, 0x0, 0x0, 0x0, 0xa, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x30, 0x1, 0x0, 0x0, 0x2, 0x28, 0x0, 0x0, 0x1, 0x14, 0x0, 0x0, 0x0, 0xa, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x34, 0x1, 0x0, 0x0, 0x3, 0x40, 0x0, 0x0, 0x1, 0xe, 0x0, 0x0, 0x0, 0xa, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x3, 0x0, 0x0, 0x4, 0x4e, 0x0, 0x0, 0x0, 0x26, 0xfc, 0x1, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x33, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0x12, 0x0, 0x0, 0x0, 0xa, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x37, 0x1, 0x0, 0x0, 0x1, 0x16, 0x0, 0x0, 0x1, 0xe, 0x0, 0x0, 0x0, 0xa, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x31, 0x1, 0x0, 0x0, 0x2, 0x28, 0x0, 0x0, 0x1, 0x14, 0x0, 0x0, 0x0, 0xa, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x35, 0x1, 0x0, 0x0, 0x3, 0x40, 0x0, 0x0, 0x1, 0xe, 0x0, 0x0, 0x0, 0xa, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x3, 0x8a, 0x0, 0x0, 0x2, 0x2b, 0x0, 0x0, 0x0, 0x4, 0x0, 0x0, 0x0, 0x4, 0x0, 0x0, 0x0, 0x8, 0x0, 0x0, 0x0, 0x8};
static uchar restoreData43[] = { 0x0, 0x0, 0x0, 0xff, 0x0, 0x0, 0x0, 0x0, 0xfd, 0x0, 0x0, 0x0, 0x4, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x50, 0x0, 0x0, 0x0, 0xa0, 0xfc, 0x2, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x30, 0x1, 0x0, 0x0, 0x0, 0x2a, 0x0, 0x0, 0x0, 0x25, 0x0, 0x0, 0x0, 0x16, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x34, 0x1, 0x0, 0x0, 0x0, 0x53, 0x0, 0x0, 0x0, 0x25, 0x0, 0x0, 0x0, 0x16, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x38, 0x1, 0x0, 0x0, 0x0, 0x7c, 0x0, 0x0, 0x0, 0x25, 0x0, 0x0, 0x0, 0x16, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x32, 0x1, 0x0, 0x0, 0x0, 0xa5, 0x0, 0x0, 0x0, 0x25, 0x0, 0x0, 0x0, 0x16, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0x98, 0x0, 0x0, 0x0, 0xa0, 0xfc, 0x2, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x1, 0x0, 0x0, 0x0, 0x2a, 0x0, 0x0, 0x0, 0x25, 0x0, 0x0, 0x0, 0x16, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x35, 0x1, 0x0, 0x0, 0x0, 0x53, 0x0, 0x0, 0x0, 0x25, 0x0, 0x0, 0x0, 0x16, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x39, 0x1, 0x0, 0x0, 0x0, 0x7c, 0x0, 0x0, 0x0, 0x25, 0x0, 0x0, 0x0, 0x16, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x33, 0x1, 0x0, 0x0, 0x0, 0xa5, 0x0, 0x0, 0x0, 0x25, 0x0, 0x0, 0x0, 0x16, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x2, 0x0, 0x0, 0x1, 0xa8, 0x0, 0x0, 0x0, 0x26, 0xfc, 0x1, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x32, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x68, 0x0, 0x0, 0x0, 0x50, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x36, 0x1, 0x0, 0x0, 0x0, 0x6c, 0x0, 0x0, 0x0, 0x66, 0x0, 0x0, 0x0, 0x50, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x30, 0x1, 0x0, 0x0, 0x0, 0xd6, 0x0, 0x0, 0x0, 0x68, 0x0, 0x0, 0x0, 0x50, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x34, 0x1, 0x0, 0x0, 0x1, 0x42, 0x0, 0x0, 0x0, 0x66, 0x0, 0x0, 0x0, 0x50, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0x3, 0x0, 0x0, 0x1, 0xa8, 0x0, 0x0, 0x0, 0x26, 0xfc, 0x1, 0x0, 0x0, 0x0, 0x4, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x33, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x68, 0x0, 0x0, 0x0, 0x50, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xc, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x37, 0x1, 0x0, 0x0, 0x0, 0x6c, 0x0, 0x0, 0x0, 0x66, 0x0, 0x0, 0x0, 0x50, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x31, 0x1, 0x0, 0x0, 0x0, 0xd6, 0x0, 0x0, 0x0, 0x68, 0x0, 0x0, 0x0, 0x50, 0x0, 0xff, 0xff, 0xff, 0xfb, 0x0, 0x0, 0x0, 0xe, 0x0, 0x64, 0x0, 0x6f, 0x0, 0x63, 0x0, 0x6b, 0x0, 0x20, 0x0, 0x31, 0x0, 0x35, 0x1, 0x0, 0x0, 0x1, 0x42, 0x0, 0x0, 0x0, 0x66, 0x0, 0x0, 0x0, 0x50, 0x0, 0xff, 0xff, 0xff, 0x0, 0x0, 0x0, 0xb8, 0x0, 0x0, 0x0, 0xa0, 0x0, 0x0, 0x0, 0x4, 0x0, 0x0, 0x0, 0x4, 0x0, 0x0, 0x0, 0x8, 0x0, 0x0, 0x0, 0x8, 0xfc, 0x0, 0x0, 0x0, 0x0};
// Local scope class to simulate toolbar move.
@@ -731,7 +731,7 @@ void tst_QMainWindow::statusBar()
// deleting the status bar should remove it from the main window
QMainWindow mw;
QStatusBar *sb = mw.statusBar();
- QMainWindowLayout *l = qFindChild<QMainWindowLayout *>(&mw);
+ QMainWindowLayout *l = mw.findChild<QMainWindowLayout *>();
QVERIFY(l);
int indexOfSb = l->indexOf(sb);
QVERIFY(indexOfSb != -1);
@@ -1273,7 +1273,7 @@ void tst_QMainWindow::restoreStateFromPreviousVersion()
QMainWindow win;
win.setCentralWidget(new QTextEdit);
QVector<QDockWidget*> docks;
-
+
for(int i = 0; i < 16; ++i) {
const QString name = QString::fromLatin1("dock %1").arg(i);
QDockWidget *dock = new QDockWidget(name);
@@ -1288,7 +1288,7 @@ void tst_QMainWindow::restoreStateFromPreviousVersion()
QCOMPARE( win.dockWidgetArea(docks[i]), Qt::DockWidgetArea(1 << i%4));
}
}
-
+
}
@@ -1425,7 +1425,7 @@ void AddDockWidget::apply(QMainWindow *mw) const
QDockWidget *other = 0;
if (mode == SplitMode || mode == TabMode) {
- other = qFindChild<QDockWidget*>(mw, this->other);
+ other = mw->findChild<QDockWidget*>(this->other);
QVERIFY(other != 0);
}
@@ -1463,14 +1463,14 @@ Q_DECLARE_METATYPE(MoveList)
void MoveSeparator::apply(QMainWindow *mw) const
{
- QMainWindowLayout *l = qFindChild<QMainWindowLayout *>(mw);
+ QMainWindowLayout *l = mw->findChild<QMainWindowLayout *>();
QVERIFY(l);
QList<int> path;
if (name.isEmpty()) {
path << area;
} else {
- QDockWidget *dw = qFindChild<QDockWidget*>(mw, name);
+ QDockWidget *dw = mw->findChild<QDockWidget*>(name);
QVERIFY(dw != 0);
path = l->layoutState.dockAreaLayout.indexOf(dw);
}
@@ -1488,7 +1488,7 @@ void MoveSeparator::apply(QMainWindow *mw) const
QMap<QString, QRect> dockWidgetGeometries(QMainWindow *mw)
{
QMap<QString, QRect> result;
- QList<QDockWidget*> dockWidgets = qFindChildren<QDockWidget*>(mw);
+ QList<QDockWidget*> dockWidgets = mw->findChildren<QDockWidget*>();
foreach (QDockWidget *dw, dockWidgets)
result.insert(dw->objectName(), dw->geometry());
return result;
@@ -1631,7 +1631,7 @@ void tst_QMainWindow::isSeparator()
QVERIFY( mw.isSeparator(QPoint(4, dockw->pos().y() + dockw->size().height())));
QVERIFY( mw.isSeparator(QPoint(4, dockw->pos().y() + dockw->size().height() + margin)));
QVERIFY(!mw.isSeparator(QPoint(4, dockw->pos().y() + dockw->size().height() + 15)));
-
+
}
class MainWindow : public QMainWindow {
@@ -1668,7 +1668,7 @@ void tst_QMainWindow::addToolbarAfterShow()
//this is for task 243119
QMainWindow mainWindow;
mainWindow.show();
-
+
QToolBar toolBar;
mainWindow.addToolBar(&toolBar);
QTest::qWait(100);
diff --git a/tests/auto/widgets/widgets/qmdiarea/qmdiarea.pro b/tests/auto/widgets/widgets/qmdiarea/qmdiarea.pro
index cc2bcb3c30..cfd0dd5463 100644
--- a/tests/auto/widgets/widgets/qmdiarea/qmdiarea.pro
+++ b/tests/auto/widgets/widgets/qmdiarea/qmdiarea.pro
@@ -13,4 +13,3 @@ mac {
}
!mac:!win32:CONFIG+=insignificant_test # QTBUG-25298
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qmdiarea/tst_qmdiarea.cpp b/tests/auto/widgets/widgets/qmdiarea/tst_qmdiarea.cpp
index 6364727e0e..6364a736cd 100644
--- a/tests/auto/widgets/widgets/qmdiarea/tst_qmdiarea.cpp
+++ b/tests/auto/widgets/widgets/qmdiarea/tst_qmdiarea.cpp
@@ -111,7 +111,7 @@ static bool tabBetweenSubWindowsIn(QMdiArea *mdiArea, int tabCount = -1, bool re
if (tabCount > 1)
QTest::qWait(500);
if (walkThrough) {
- QRubberBand *rubberBand = qFindChild<QRubberBand *>(mdiArea->viewport());
+ QRubberBand *rubberBand = mdiArea->viewport()->findChild<QRubberBand *>();
if (!rubberBand) {
qWarning("No rubber band");
return false;
@@ -290,7 +290,6 @@ private slots:
private:
QMdiSubWindow *activeWindow;
- bool accelPressed;
};
tst_QMdiArea::tst_QMdiArea()
@@ -2335,14 +2334,14 @@ void tst_QMdiArea::setViewMode()
// Default.
QVERIFY(!activeSubWindow->isMaximized());
- QTabBar *tabBar = qFindChild<QTabBar *>(&mdiArea);
+ QTabBar *tabBar = mdiArea.findChild<QTabBar *>();
QVERIFY(!tabBar);
QCOMPARE(mdiArea.viewMode(), QMdiArea::SubWindowView);
// Tabbed view.
mdiArea.setViewMode(QMdiArea::TabbedView);
QCOMPARE(mdiArea.viewMode(), QMdiArea::TabbedView);
- tabBar = qFindChild<QTabBar *>(&mdiArea);
+ tabBar = mdiArea.findChild<QTabBar *>();
QVERIFY(tabBar);
QVERIFY(tabBar->isVisible());
@@ -2409,7 +2408,7 @@ void tst_QMdiArea::setViewMode()
// Go back to default (QMdiArea::SubWindowView).
mdiArea.setViewMode(QMdiArea::SubWindowView);
QVERIFY(!activeSubWindow->isMaximized());
- tabBar = qFindChild<QTabBar *>(&mdiArea);
+ tabBar = mdiArea.findChild<QTabBar *>();
QVERIFY(!tabBar);
QCOMPARE(mdiArea.viewMode(), QMdiArea::SubWindowView);
}
@@ -2423,14 +2422,14 @@ void tst_QMdiArea::setTabsClosable()
QCOMPARE(mdiArea.tabsClosable(), false);
// change value before tab bar exists
- QTabBar *tabBar = qFindChild<QTabBar *>(&mdiArea);
+ QTabBar *tabBar = mdiArea.findChild<QTabBar *>();
QVERIFY(!tabBar);
mdiArea.setTabsClosable(true);
QCOMPARE(mdiArea.tabsClosable(), true);
// force tab bar creation
mdiArea.setViewMode(QMdiArea::TabbedView);
- tabBar = qFindChild<QTabBar *>(&mdiArea);
+ tabBar = mdiArea.findChild<QTabBar *>();
QVERIFY(tabBar);
// value must've been propagated
@@ -2453,14 +2452,14 @@ void tst_QMdiArea::setTabsMovable()
QCOMPARE(mdiArea.tabsMovable(), false);
// change value before tab bar exists
- QTabBar *tabBar = qFindChild<QTabBar *>(&mdiArea);
+ QTabBar *tabBar = mdiArea.findChild<QTabBar *>();
QVERIFY(!tabBar);
mdiArea.setTabsMovable(true);
QCOMPARE(mdiArea.tabsMovable(), true);
// force tab bar creation
mdiArea.setViewMode(QMdiArea::TabbedView);
- tabBar = qFindChild<QTabBar *>(&mdiArea);
+ tabBar = mdiArea.findChild<QTabBar *>();
QVERIFY(tabBar);
// value must've been propagated
@@ -2501,7 +2500,7 @@ void tst_QMdiArea::setTabShape()
mdiArea.setViewMode(QMdiArea::TabbedView);
- QTabBar *tabBar = qFindChild<QTabBar *>(&mdiArea);
+ QTabBar *tabBar = mdiArea.findChild<QTabBar *>();
QVERIFY(tabBar);
QCOMPARE(tabBar->shape(), QTabBar::TriangularNorth);
@@ -2544,7 +2543,7 @@ void tst_QMdiArea::setTabPosition()
// Default.
QCOMPARE(mdiArea.tabPosition(), QTabWidget::North);
mdiArea.setViewMode(QMdiArea::TabbedView);
- QTabBar *tabBar = qFindChild<QTabBar *>(&mdiArea);
+ QTabBar *tabBar = mdiArea.findChild<QTabBar *>();
QVERIFY(tabBar);
QCOMPARE(tabBar->shape(), QTabBar::RoundedNorth);
diff --git a/tests/auto/widgets/widgets/qmdisubwindow/qmdisubwindow.pro b/tests/auto/widgets/widgets/qmdisubwindow/qmdisubwindow.pro
index 34b3954701..4299f7711e 100644
--- a/tests/auto/widgets/widgets/qmdisubwindow/qmdisubwindow.pro
+++ b/tests/auto/widgets/widgets/qmdisubwindow/qmdisubwindow.pro
@@ -4,4 +4,3 @@ QT += widgets testlib
INCLUDEPATH += .
SOURCES += tst_qmdisubwindow.cpp
DEFINES += QT_NO_CAST_TO_ASCII QT_NO_CAST_FROM_ASCII
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qmdisubwindow/tst_qmdisubwindow.cpp b/tests/auto/widgets/widgets/qmdisubwindow/tst_qmdisubwindow.cpp
index 2163426cac..5b146cf443 100644
--- a/tests/auto/widgets/widgets/qmdisubwindow/tst_qmdisubwindow.cpp
+++ b/tests/auto/widgets/widgets/qmdisubwindow/tst_qmdisubwindow.cpp
@@ -154,6 +154,7 @@ Q_DECLARE_METATYPE(Qt::WindowState);
Q_DECLARE_METATYPE(Qt::WindowStates);
Q_DECLARE_METATYPE(Qt::WindowType);
Q_DECLARE_METATYPE(Qt::WindowFlags);
+Q_DECLARE_METATYPE(QMdiSubWindow*);
class tst_QMdiSubWindow : public QObject
{
@@ -204,6 +205,7 @@ private slots:
void task_182852();
void task_233197();
void task_226929();
+ void styleChange();
};
void tst_QMdiSubWindow::initTestCase()
@@ -596,7 +598,7 @@ void tst_QMdiSubWindow::showShaded()
QWidget *mouseReceiver = 0;
#ifdef Q_OS_MAC
if (window->style()->inherits("QMacStyle"))
- mouseReceiver = qFindChild<QSizeGrip *>(window);
+ mouseReceiver = window->findChild<QSizeGrip *>();
else
#endif
mouseReceiver = window;
@@ -705,7 +707,7 @@ void tst_QMdiSubWindow::setOpaqueResizeAndMove()
QWidget *mouseReceiver = 0;
if (window->style()->inherits("QMacStyle"))
- mouseReceiver = qFindChild<QSizeGrip *>(window);
+ mouseReceiver = window->findChild<QSizeGrip *>();
else
mouseReceiver = window;
QVERIFY(mouseReceiver);
@@ -1445,12 +1447,12 @@ void tst_QMdiSubWindow::defaultSizeGrip()
// QSizeGrip on windows with decoration.
QMdiSubWindow *windowWithDecoration = mdiArea.addSubWindow(new QWidget);
windowWithDecoration->show();
- QVERIFY(qFindChild<QSizeGrip *>(windowWithDecoration));
+ QVERIFY(windowWithDecoration->findChild<QSizeGrip *>());
// ...but not on windows without decoration (Qt::FramelessWindowHint).
QMdiSubWindow *windowWithoutDecoration = mdiArea.addSubWindow(new QWidget, Qt::FramelessWindowHint);
windowWithoutDecoration->show();
- QVERIFY(!qFindChild<QSizeGrip *>(windowWithoutDecoration));
+ QVERIFY(!windowWithoutDecoration->findChild<QSizeGrip *>());
}
#endif
@@ -2018,6 +2020,35 @@ void tst_QMdiSubWindow::task_226929()
QVERIFY(sub1->isMaximized());
}
+void tst_QMdiSubWindow::styleChange()
+{
+ QMdiArea mdiArea;
+ mdiArea.show();
+ QVERIFY(QTest::qWaitForWindowExposed(&mdiArea));
+
+ QMdiSubWindow *sub1 = mdiArea.addSubWindow(new QTextEdit);
+ sub1->showMaximized();
+
+ QMdiSubWindow *sub2 = mdiArea.addSubWindow(new QTextEdit);
+ sub2->showMinimized();
+
+ mdiArea.setActiveSubWindow(sub1);
+
+ QTest::qWait(100);
+
+ qRegisterMetaType<QMdiSubWindow *>();
+ QSignalSpy spy(&mdiArea, SIGNAL(subWindowActivated(QMdiSubWindow*)));
+ QVERIFY(spy.isValid());
+
+ QEvent event(QEvent::StyleChange);
+ QApplication::sendEvent(sub1, &event);
+ QApplication::sendEvent(sub2, &event);
+
+ // subWindowActivated should NOT be activated by a style change,
+ // even if internally QMdiSubWindow un-minimizes subwindows temporarily.
+ QCOMPARE(spy.count(), 0);
+}
+
QTEST_MAIN(tst_QMdiSubWindow)
#include "tst_qmdisubwindow.moc"
diff --git a/tests/auto/widgets/widgets/qmenu/qmenu.pro b/tests/auto/widgets/widgets/qmenu/qmenu.pro
index c474ef9f86..9efd0302bf 100644
--- a/tests/auto/widgets/widgets/qmenu/qmenu.pro
+++ b/tests/auto/widgets/widgets/qmenu/qmenu.pro
@@ -3,4 +3,3 @@ TARGET = tst_qmenu
QT += widgets testlib
SOURCES += tst_qmenu.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qmenubar/qmenubar.pro b/tests/auto/widgets/widgets/qmenubar/qmenubar.pro
index 903d5be387..3fb6ae61a8 100644
--- a/tests/auto/widgets/widgets/qmenubar/qmenubar.pro
+++ b/tests/auto/widgets/widgets/qmenubar/qmenubar.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qmenubar
QT += widgets testlib
SOURCES += tst_qmenubar.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qmenubar/tst_qmenubar.cpp b/tests/auto/widgets/widgets/qmenubar/tst_qmenubar.cpp
index 354ccea06c..d1e6693608 100644
--- a/tests/auto/widgets/widgets/qmenubar/tst_qmenubar.cpp
+++ b/tests/auto/widgets/widgets/qmenubar/tst_qmenubar.cpp
@@ -294,7 +294,6 @@ void tst_QMenuBar::initSimpleMenubar()
connect(pm2, SIGNAL(triggered(QAction*)), this, SLOT(onActivated(QAction*)));
mb->show();
- qApp->syncX();
qApp->processEvents();
}
@@ -1122,7 +1121,6 @@ void tst_QMenuBar::check_menuPosition()
void tst_QMenuBar::task223138_triggered()
{
- qRegisterMetaType<QAction *>("QAction *");
//we create a window with submenus and we check that both menubar and menus get the triggered signal
QMainWindow win;
QMenu *menu = win.menuBar()->addMenu("test");
diff --git a/tests/auto/widgets/widgets/qplaintextedit/qplaintextedit.pro b/tests/auto/widgets/widgets/qplaintextedit/qplaintextedit.pro
index 7bb4094709..e98bae2089 100644
--- a/tests/auto/widgets/widgets/qplaintextedit/qplaintextedit.pro
+++ b/tests/auto/widgets/widgets/qplaintextedit/qplaintextedit.pro
@@ -9,4 +9,3 @@ INCLUDEPATH += ../
HEADERS +=
SOURCES += tst_qplaintextedit.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qplaintextedit/tst_qplaintextedit.cpp b/tests/auto/widgets/widgets/qplaintextedit/tst_qplaintextedit.cpp
index fdb17d1eaf..11c4e238ec 100644
--- a/tests/auto/widgets/widgets/qplaintextedit/tst_qplaintextedit.cpp
+++ b/tests/auto/widgets/widgets/qplaintextedit/tst_qplaintextedit.cpp
@@ -1119,7 +1119,7 @@ void tst_QPlainTextEdit::mimeDataReimplementations()
QCOMPARE(ed.insertCallCount, 0);
#ifdef QT_BUILD_INTERNAL
- QWidgetTextControl *control = qFindChild<QWidgetTextControl *>(&ed);
+ QWidgetTextControl *control = ed.findChild<QWidgetTextControl *>();
QVERIFY(control);
control->canInsertFromMimeData(QApplication::clipboard()->mimeData());
diff --git a/tests/auto/widgets/widgets/qprogressbar/qprogressbar.pro b/tests/auto/widgets/widgets/qprogressbar/qprogressbar.pro
index e7f60a0144..1de3e6309f 100644
--- a/tests/auto/widgets/widgets/qprogressbar/qprogressbar.pro
+++ b/tests/auto/widgets/widgets/qprogressbar/qprogressbar.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qprogressbar.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qprogressbar/tst_qprogressbar.cpp b/tests/auto/widgets/widgets/qprogressbar/tst_qprogressbar.cpp
index 5ad9aa7690..e373e50e0a 100644
--- a/tests/auto/widgets/widgets/qprogressbar/tst_qprogressbar.cpp
+++ b/tests/auto/widgets/widgets/qprogressbar/tst_qprogressbar.cpp
@@ -42,6 +42,7 @@
#include <QtTest/QtTest>
#include "qprogressbar.h"
+#include <qlocale.h>
#include <qapplication.h>
#include <qstyleoption.h>
#include <qdebug.h>
@@ -64,6 +65,7 @@ private slots:
void sizeHint();
void formatedText_data();
void formatedText();
+ void localizedFormattedText();
void task245201_testChangeStyleAndDelete_data();
void task245201_testChangeStyleAndDelete();
@@ -113,7 +115,9 @@ void tst_QProgressBar::minMaxSameValue()
QProgressBar bar;
bar.setRange(10, 10);
bar.setValue(10);
+ bar.move(300, 300);
bar.show();
+ QVERIFY(QTest::qWaitForWindowExposed(&bar));
}
void tst_QProgressBar::destroyIndeterminate()
@@ -123,7 +127,9 @@ void tst_QProgressBar::destroyIndeterminate()
// it's deleted.
QPointer<QProgressBar> bar = new QProgressBar;
bar->setMaximum(0);
+ bar->move(300, 300);
bar->show();
+ QVERIFY(QTest::qWaitForWindowExposed(bar.data()));
QEventLoop loop;
QTimer::singleShot(500, bar, SLOT(deleteLater()));
@@ -166,8 +172,10 @@ void tst_QProgressBar::format()
ProgressBar bar;
bar.setRange(0, 10);
bar.setValue(1);
+ bar.move(300, 300);
bar.show();
QVERIFY(QTest::qWaitForWindowExposed(&bar));
+ QVERIFY(QTest::qWaitForWindowExposed(&bar));
QTest::qWait(20);
bar.repainted = false;
@@ -202,6 +210,7 @@ void tst_QProgressBar::setValueRepaint()
pbar.setMinimum(0);
pbar.setMaximum(10);
pbar.setFormat("%v");
+ pbar.move(300, 300);
pbar.show();
QVERIFY(QTest::qWaitForWindowExposed(&pbar));
@@ -224,7 +233,9 @@ void tst_QProgressBar::setMinMaxRepaint()
pbar.setMinimum(0);
pbar.setMaximum(10);
pbar.setFormat("%v");
+ pbar.move(300, 300);
pbar.show();
+ qApp->setActiveWindow(&pbar);
QVERIFY(QTest::qWaitForWindowActive(&pbar));
// No repaint when setting minimum to the current minimum
@@ -301,6 +312,40 @@ void tst_QProgressBar::formatedText()
QCOMPARE(bar.text(), text);
}
+void tst_QProgressBar::localizedFormattedText() // QTBUG-28751
+{
+ QProgressBar bar;
+ const int value = 42;
+ bar.setValue(value);
+ const QString defaultExpectedNumber = QString::number(value);
+ const QString defaultExpectedValue = defaultExpectedNumber + QLatin1Char('%');
+ QCOMPARE(bar.text(), defaultExpectedValue);
+
+ // Temporarily switch to Egyptian, which has a different percent sign and number formatting
+ QLocale egypt(QLocale::Arabic, QLocale::Egypt);
+ bar.setLocale(egypt);
+ const QString egyptianExpectedNumber = egypt.toString(value);
+ const QString egyptianExpectedValue = egyptianExpectedNumber + egypt.percent();
+ if (egyptianExpectedValue == defaultExpectedValue)
+ QSKIP("Egyptian locale does not work on this system.");
+ QCOMPARE(bar.text(), egyptianExpectedValue);
+
+ bar.setLocale(QLocale());
+ QCOMPARE(bar.text(), defaultExpectedValue);
+
+ // Set a custom format containing only the number
+ bar.setFormat(QStringLiteral("%p"));
+ QCOMPARE(bar.text(), defaultExpectedNumber);
+ bar.setLocale(egypt);
+ QCOMPARE(bar.text(), egyptianExpectedNumber);
+
+ // Clear the format
+ bar.resetFormat();
+ QCOMPARE(bar.text(), egyptianExpectedValue);
+ bar.setLocale(QLocale());
+ QCOMPARE(bar.text(), defaultExpectedValue);
+}
+
void tst_QProgressBar::task245201_testChangeStyleAndDelete_data()
{
QTest::addColumn<QString>("style1_str");
@@ -319,7 +364,9 @@ void tst_QProgressBar::task245201_testChangeStyleAndDelete()
QStyle *style = QStyleFactory::create(style1_str);
bar->setStyle(style);
+ bar->move(300, 300);
bar->show();
+ QVERIFY(QTest::qWaitForWindowExposed(bar));
QStyle *style2 = QStyleFactory::create(style2_str);
bar->setStyle(style2);
QTest::qWait(10);
diff --git a/tests/auto/widgets/widgets/qpushbutton/qpushbutton.pro b/tests/auto/widgets/widgets/qpushbutton/qpushbutton.pro
index 4f7bacce70..353ad06ca2 100644
--- a/tests/auto/widgets/widgets/qpushbutton/qpushbutton.pro
+++ b/tests/auto/widgets/widgets/qpushbutton/qpushbutton.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qpushbutton.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qpushbutton/tst_qpushbutton.cpp b/tests/auto/widgets/widgets/qpushbutton/tst_qpushbutton.cpp
index 09a6565ca6..75c826c4cc 100644
--- a/tests/auto/widgets/widgets/qpushbutton/tst_qpushbutton.cpp
+++ b/tests/auto/widgets/widgets/qpushbutton/tst_qpushbutton.cpp
@@ -659,7 +659,7 @@ void tst_QPushButton::taskQTBUG_20191_shortcutWithKeypadModifer()
QDialog dialog;
dialog.setLayout(layout);
dialog.show();
- QTest::qWaitForWindowShown(&dialog);
+ QTest::qWaitForWindowExposed(&dialog);
QApplication::setActiveWindow(&dialog);
// add shortcut '5' to button1 and test with keyboard and keypad '5' keys
diff --git a/tests/auto/widgets/widgets/qradiobutton/qradiobutton.pro b/tests/auto/widgets/widgets/qradiobutton/qradiobutton.pro
index 961400d07b..a89733e9e1 100644
--- a/tests/auto/widgets/widgets/qradiobutton/qradiobutton.pro
+++ b/tests/auto/widgets/widgets/qradiobutton/qradiobutton.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qradiobutton.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qscrollarea/qscrollarea.pro b/tests/auto/widgets/widgets/qscrollarea/qscrollarea.pro
index 87649fa366..0cd706420e 100644
--- a/tests/auto/widgets/widgets/qscrollarea/qscrollarea.pro
+++ b/tests/auto/widgets/widgets/qscrollarea/qscrollarea.pro
@@ -9,4 +9,3 @@ QT += widgets testlib
SOURCES += tst_qscrollarea.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qscrollarea/tst_qscrollarea.cpp b/tests/auto/widgets/widgets/qscrollarea/tst_qscrollarea.cpp
index 26daf11b3a..a1a4e33a4b 100644
--- a/tests/auto/widgets/widgets/qscrollarea/tst_qscrollarea.cpp
+++ b/tests/auto/widgets/widgets/qscrollarea/tst_qscrollarea.cpp
@@ -120,7 +120,7 @@ void tst_QScrollArea::ensureMicroFocusVisible_Task_167838()
parent->setLayout(new QVBoxLayout);
QWidget *child = new WidgetWithMicroFocus;
parent->layout()->addWidget(child);
- parent->resize(300, 300);
+ parent->resize(300, 300);
scrollArea.setWidget(parent);
scrollArea.ensureWidgetVisible(child, 10, 10);
QRect microFocus = child->inputMethodQuery(Qt::ImMicroFocus).toRect();
diff --git a/tests/auto/widgets/widgets/qscrollbar/qscrollbar.pro b/tests/auto/widgets/widgets/qscrollbar/qscrollbar.pro
index 3a9778b46d..8c6ea6e1d4 100644
--- a/tests/auto/widgets/widgets/qscrollbar/qscrollbar.pro
+++ b/tests/auto/widgets/widgets/qscrollbar/qscrollbar.pro
@@ -3,4 +3,3 @@ CONFIG += parallel_test
TARGET = tst_qscrollbar
QT += widgets testlib
SOURCES += tst_qscrollbar.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qsizegrip/qsizegrip.pro b/tests/auto/widgets/widgets/qsizegrip/qsizegrip.pro
index 3c63c5b0f5..ceb897c612 100644
--- a/tests/auto/widgets/widgets/qsizegrip/qsizegrip.pro
+++ b/tests/auto/widgets/widgets/qsizegrip/qsizegrip.pro
@@ -4,4 +4,3 @@ TARGET = tst_qsizegrip
INCLUDEPATH += .
QT += widgets testlib
SOURCES += tst_qsizegrip.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qslider/qslider.pro b/tests/auto/widgets/widgets/qslider/qslider.pro
index e704042d4a..d0a61e5a95 100644
--- a/tests/auto/widgets/widgets/qslider/qslider.pro
+++ b/tests/auto/widgets/widgets/qslider/qslider.pro
@@ -9,4 +9,3 @@ QT += widgets testlib
SOURCES += tst_qslider.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qspinbox/qspinbox.pro b/tests/auto/widgets/widgets/qspinbox/qspinbox.pro
index 59eb7141eb..0541eaadeb 100644
--- a/tests/auto/widgets/widgets/qspinbox/qspinbox.pro
+++ b/tests/auto/widgets/widgets/qspinbox/qspinbox.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qspinbox
QT += widgets testlib
SOURCES += tst_qspinbox.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qsplitter/qsplitter.pro b/tests/auto/widgets/widgets/qsplitter/qsplitter.pro
index 801b6b69c5..c43847b11f 100644
--- a/tests/auto/widgets/widgets/qsplitter/qsplitter.pro
+++ b/tests/auto/widgets/widgets/qsplitter/qsplitter.pro
@@ -5,4 +5,3 @@ QT += widgets testlib
SOURCES += tst_qsplitter.cpp
TESTDATA += extradata.txt setSizes3.dat
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qsplitter/tst_qsplitter.cpp b/tests/auto/widgets/widgets/qsplitter/tst_qsplitter.cpp
index a2c7c04977..340eefbf17 100644
--- a/tests/auto/widgets/widgets/qsplitter/tst_qsplitter.cpp
+++ b/tests/auto/widgets/widgets/qsplitter/tst_qsplitter.cpp
@@ -242,17 +242,17 @@ void tst_QSplitter::saveAndRestoreState()
QFETCH(IntList, initialSizes);
splitter->setSizes(initialSizes);
QApplication::instance()->sendPostedEvents();
-
+
QSplitter *splitter2 = new QSplitter(splitter->orientation() == Qt::Horizontal ?
Qt::Vertical : Qt::Horizontal);
for (int i = 0; i < splitter->count(); ++i) {
- splitter2->addWidget(new QWidget());
+ splitter2->addWidget(new QWidget());
}
- splitter2->resize(splitter->size());
+ splitter2->resize(splitter->size());
splitter2->setChildrenCollapsible(!splitter->childrenCollapsible());
splitter2->setOpaqueResize(!splitter->opaqueResize());
splitter2->setHandleWidth(splitter->handleWidth()+3);
-
+
QByteArray ba = splitter->saveState();
QVERIFY(splitter2->restoreState(ba));
@@ -269,10 +269,10 @@ void tst_QSplitter::saveAndRestoreState()
}
// destroy version and magic number
- for (int i = 0; i < ba.size(); ++i)
+ for (int i = 0; i < ba.size(); ++i)
ba[i] = ~ba.at(i);
QVERIFY(!splitter2->restoreState(ba));
-
+
delete splitter2;
}
@@ -688,7 +688,7 @@ void tst_QSplitter::task187373_addAbstractScrollAreas()
}
//! A simple QTextEdit which can switch between two different size states
-class MyTextEdit : public QTextEdit
+class MyTextEdit : public QTextEdit
{
public:
MyTextEdit(const QString & text, QWidget* parent = NULL)
diff --git a/tests/auto/widgets/widgets/qstackedwidget/qstackedwidget.pro b/tests/auto/widgets/widgets/qstackedwidget/qstackedwidget.pro
index f334da7ef2..d016caf393 100644
--- a/tests/auto/widgets/widgets/qstackedwidget/qstackedwidget.pro
+++ b/tests/auto/widgets/widgets/qstackedwidget/qstackedwidget.pro
@@ -9,4 +9,3 @@ QT += widgets testlib
SOURCES += tst_qstackedwidget.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qstatusbar/qstatusbar.pro b/tests/auto/widgets/widgets/qstatusbar/qstatusbar.pro
index 980a1e8cb1..5cf40f7b36 100644
--- a/tests/auto/widgets/widgets/qstatusbar/qstatusbar.pro
+++ b/tests/auto/widgets/widgets/qstatusbar/qstatusbar.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qstatusbar.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qstatusbar/tst_qstatusbar.cpp b/tests/auto/widgets/widgets/qstatusbar/tst_qstatusbar.cpp
index 62dfd07f3e..3bdf583153 100644
--- a/tests/auto/widgets/widgets/qstatusbar/tst_qstatusbar.cpp
+++ b/tests/auto/widgets/widgets/qstatusbar/tst_qstatusbar.cpp
@@ -175,7 +175,7 @@ void tst_QStatusBar::setSizeGripEnabled()
QVERIFY(QTest::qWaitForWindowExposed(&mainWindow));
QTRY_VERIFY(statusBar->isVisible());
- QPointer<QSizeGrip> sizeGrip = qFindChild<QSizeGrip *>(statusBar);
+ QPointer<QSizeGrip> sizeGrip = statusBar->findChild<QSizeGrip *>();
QVERIFY(sizeGrip);
QVERIFY(sizeGrip->isVisible());
@@ -211,7 +211,7 @@ void tst_QStatusBar::setSizeGripEnabled()
statusBar = mainWindow.statusBar();
QVERIFY(statusBar);
- sizeGrip = qFindChild<QSizeGrip *>(statusBar);
+ sizeGrip = statusBar->findChild<QSizeGrip *>();
QVERIFY(sizeGrip);
QVERIFY(!sizeGrip->isVisible());
diff --git a/tests/auto/widgets/widgets/qtabbar/qtabbar.pro b/tests/auto/widgets/widgets/qtabbar/qtabbar.pro
index 32c1a6b0d4..8772005bef 100644
--- a/tests/auto/widgets/widgets/qtabbar/qtabbar.pro
+++ b/tests/auto/widgets/widgets/qtabbar/qtabbar.pro
@@ -6,4 +6,3 @@ SOURCES += tst_qtabbar.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qtabwidget/qtabwidget.pro b/tests/auto/widgets/widgets/qtabwidget/qtabwidget.pro
index 560aa86946..72956a6867 100644
--- a/tests/auto/widgets/widgets/qtabwidget/qtabwidget.pro
+++ b/tests/auto/widgets/widgets/qtabwidget/qtabwidget.pro
@@ -9,4 +9,3 @@ HEADERS +=
SOURCES += tst_qtabwidget.cpp
win32:!wince*:LIBS += -luser32
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qtabwidget/tst_qtabwidget.cpp b/tests/auto/widgets/widgets/qtabwidget/tst_qtabwidget.cpp
index 48cbc66ba9..5dd9ee9b0f 100644
--- a/tests/auto/widgets/widgets/qtabwidget/tst_qtabwidget.cpp
+++ b/tests/auto/widgets/widgets/qtabwidget/tst_qtabwidget.cpp
@@ -454,7 +454,7 @@ void tst_QTabWidget::removeTab()
tw->addTab(new QLabel("5"), "5");
QCOMPARE(ob.count, 1);
QCOMPARE(tw->count(), 5);
-
+
tw->setCurrentIndex(4);
QCOMPARE(ob.count,5);
tw->removeTab(4);
@@ -533,7 +533,7 @@ void tst_QTabWidget::keyboardNavigation()
tw->setTabEnabled(2, false);
QTest::keyClick(tw, Qt::Key_Tab, Qt::ControlModifier);
// TODO: Disabling the current tab will move current tab to the next,
- // but what if next tab is also disabled. We should look into this.
+ // but what if next tab is also disabled. We should look into this.
QVERIFY(tw->currentIndex() < 3 && tw->currentIndex() >= 0);
}
diff --git a/tests/auto/widgets/widgets/qtextbrowser/qtextbrowser.pro b/tests/auto/widgets/widgets/qtextbrowser/qtextbrowser.pro
index 334b3cd9b3..5416c1c71f 100644
--- a/tests/auto/widgets/widgets/qtextbrowser/qtextbrowser.pro
+++ b/tests/auto/widgets/widgets/qtextbrowser/qtextbrowser.pro
@@ -5,4 +5,3 @@ SOURCES += tst_qtextbrowser.cpp
QT += widgets testlib
TESTDATA += *.html subdir/*
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qtextedit/qtextedit.pro b/tests/auto/widgets/widgets/qtextedit/qtextedit.pro
index dad0f6ad7e..6e0fff17d5 100644
--- a/tests/auto/widgets/widgets/qtextedit/qtextedit.pro
+++ b/tests/auto/widgets/widgets/qtextedit/qtextedit.pro
@@ -4,4 +4,3 @@ TARGET = tst_qtextedit
QT += widgets widgets-private gui-private core-private testlib
SOURCES += tst_qtextedit.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qtextedit/tst_qtextedit.cpp b/tests/auto/widgets/widgets/qtextedit/tst_qtextedit.cpp
index b8ff6f1c33..11bb5c88a1 100644
--- a/tests/auto/widgets/widgets/qtextedit/tst_qtextedit.cpp
+++ b/tests/auto/widgets/widgets/qtextedit/tst_qtextedit.cpp
@@ -1483,7 +1483,7 @@ void tst_QTextEdit::mimeDataReimplementations()
QCOMPARE(ed.insertCallCount, 0);
#ifdef QT_BUILD_INTERNAL
- QWidgetTextControl *control = qFindChild<QWidgetTextControl *>(&ed);
+ QWidgetTextControl *control = ed.findChild<QWidgetTextControl *>();
QVERIFY(control);
control->canInsertFromMimeData(QApplication::clipboard()->mimeData());
@@ -2104,7 +2104,7 @@ void tst_QTextEdit::cursorRect()
#ifdef QT_BUILD_INTERNAL
void tst_QTextEdit::setDocumentPreservesPalette()
{
- QWidgetTextControl *control = qFindChild<QWidgetTextControl *>(ed);
+ QWidgetTextControl *control = ed->findChild<QWidgetTextControl *>();
QVERIFY(control);
QPalette defaultPal = ed->palette();
diff --git a/tests/auto/widgets/widgets/qtoolbar/qtoolbar.pro b/tests/auto/widgets/widgets/qtoolbar/qtoolbar.pro
index db8ea04967..ef1a0e0ba0 100644
--- a/tests/auto/widgets/widgets/qtoolbar/qtoolbar.pro
+++ b/tests/auto/widgets/widgets/qtoolbar/qtoolbar.pro
@@ -6,4 +6,3 @@ SOURCES += tst_qtoolbar.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qtoolbox/qtoolbox.pro b/tests/auto/widgets/widgets/qtoolbox/qtoolbox.pro
index ccf9996ea4..a8c62ec54a 100644
--- a/tests/auto/widgets/widgets/qtoolbox/qtoolbox.pro
+++ b/tests/auto/widgets/widgets/qtoolbox/qtoolbox.pro
@@ -6,4 +6,3 @@ SOURCES += tst_qtoolbox.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/widgets/widgets/qtoolbutton/qtoolbutton.pro b/tests/auto/widgets/widgets/qtoolbutton/qtoolbutton.pro
index a685100eca..441477e956 100644
--- a/tests/auto/widgets/widgets/qtoolbutton/qtoolbutton.pro
+++ b/tests/auto/widgets/widgets/qtoolbutton/qtoolbutton.pro
@@ -2,4 +2,3 @@ CONFIG += testcase
TARGET = tst_qtoolbutton
QT += widgets testlib
SOURCES += tst_qtoolbutton.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/xml/dom/qdom/qdom.pro b/tests/auto/xml/dom/qdom/qdom.pro
index 69e99aa0da..db19a8ba89 100644
--- a/tests/auto/xml/dom/qdom/qdom.pro
+++ b/tests/auto/xml/dom/qdom/qdom.pro
@@ -11,4 +11,3 @@ wince* {
}
}
TESTDATA += testdata/* doubleNamespaces.xml umlaut.xml
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/xml/dom/qdom/tst_qdom.cpp b/tests/auto/xml/dom/qdom/tst_qdom.cpp
index e654a41ddd..6b4bc3cd35 100644
--- a/tests/auto/xml/dom/qdom/tst_qdom.cpp
+++ b/tests/auto/xml/dom/qdom/tst_qdom.cpp
@@ -1684,7 +1684,7 @@ static const QChar umlautName[] =
/*!
\internal
-
+
Write a german umlaut to a QByteArray, via a QTextStream.
*/
void tst_QDom::germanUmlautToByteArray() const
@@ -1701,7 +1701,7 @@ void tst_QDom::germanUmlautToByteArray() const
ts.setCodec("UTF-8");
ts << d.toString();
buffer.close();
-
+
QByteArray baseline("<a");
/* http://www.fileformat.info/info/unicode/char/00FC/index.htm */
@@ -1714,7 +1714,7 @@ void tst_QDom::germanUmlautToByteArray() const
/*!
\internal
-
+
Write a german umlaut to a QFile, via a QTextStream.
*/
void tst_QDom::germanUmlautToFile() const
@@ -1757,15 +1757,15 @@ void tst_QDom::germanUmlautToFile() const
void tst_QDom::setInvalidDataPolicy() const
{
- QDomImplementation::setInvalidDataPolicy(QDomImplementation::ReturnNullNode);
- QDomDocument doc;
- QDomElement elem = doc.createElement("invalid name");
+ QDomImplementation::setInvalidDataPolicy(QDomImplementation::ReturnNullNode);
+ QDomDocument doc;
+ QDomElement elem = doc.createElement("invalid name");
QVERIFY(elem.isNull());
}
void tst_QDom::crashInSetContent() const
{
- QDomImplementation::setInvalidDataPolicy(QDomImplementation::ReturnNullNode);
+ QDomImplementation::setInvalidDataPolicy(QDomImplementation::ReturnNullNode);
QDomDocument docImport;
QCOMPARE(docImport.setContent(QLatin1String("<a:>text</a:>"), true), false);
@@ -1774,7 +1774,7 @@ void tst_QDom::crashInSetContent() const
void tst_QDom::doubleNamespaceDeclarations() const
{
- QDomDocument doc;
+ QDomDocument doc;
QString testFile = QFINDTESTDATA("doubleNamespaces.xml");
if (testFile.isEmpty())
@@ -1782,7 +1782,7 @@ void tst_QDom::doubleNamespaceDeclarations() const
QFile file(testFile);
QVERIFY(file.open(QIODevice::ReadOnly));
- QXmlSimpleReader reader;
+ QXmlSimpleReader reader;
QXmlInputSource source(&file);
QVERIFY(doc.setContent(&source, &reader));
diff --git a/tests/auto/xml/sax/qxml/qxml.pro b/tests/auto/xml/sax/qxml/qxml.pro
index 1c29f92677..e5fd4eafe3 100644
--- a/tests/auto/xml/sax/qxml/qxml.pro
+++ b/tests/auto/xml/sax/qxml/qxml.pro
@@ -6,4 +6,3 @@ SOURCES += tst_qxml.cpp
QT = core xml testlib
TESTDATA += 0x010D.xml
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/xml/sax/qxml/tst_qxml.cpp b/tests/auto/xml/sax/qxml/tst_qxml.cpp
index 7f597f83d3..0ce8d363c9 100644
--- a/tests/auto/xml/sax/qxml/tst_qxml.cpp
+++ b/tests/auto/xml/sax/qxml/tst_qxml.cpp
@@ -62,7 +62,7 @@ class MyXmlEntityResolver : public QXmlEntityResolver
{
public:
MyXmlEntityResolver() : QXmlEntityResolver() {}
- QString errorString() const { return QString(); }
+ QString errorString() const { return QString(); }
bool resolveEntity(const QString &, const QString &, QXmlInputSource *&) { return false; }
};
@@ -88,7 +88,7 @@ class MyXmlErrorHandler : public QXmlErrorHandler
{
public:
MyXmlErrorHandler() : QXmlErrorHandler() {}
- QString errorString() const { return QString(); }
+ QString errorString() const { return QString(); }
bool error(const QXmlParseException &) { return false; }
bool fatalError(const QXmlParseException &) { return false; }
bool warning(const QXmlParseException &) { return false; }
@@ -193,7 +193,7 @@ void tst_QXml::interpretedAs0D() const
};
const QString document(QLatin1String("<element ") +
- QChar(0x010D) +
+ QChar(0x010D) +
QLatin1String("reated-by=\"an attr value\"/>"));
QString testFile = QFINDTESTDATA("0x010D.xml");
diff --git a/tests/auto/xml/sax/qxmlinputsource/qxmlinputsource.pro b/tests/auto/xml/sax/qxmlinputsource/qxmlinputsource.pro
index 1fbcd7d2c8..a8bf834074 100644
--- a/tests/auto/xml/sax/qxmlinputsource/qxmlinputsource.pro
+++ b/tests/auto/xml/sax/qxmlinputsource/qxmlinputsource.pro
@@ -5,4 +5,3 @@ QT += core xml network testlib
QT -= gui
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/xml/sax/qxmlinputsource/tst_qxmlinputsource.cpp b/tests/auto/xml/sax/qxmlinputsource/tst_qxmlinputsource.cpp
index 2084c95cf4..b8837f8c14 100644
--- a/tests/auto/xml/sax/qxmlinputsource/tst_qxmlinputsource.cpp
+++ b/tests/auto/xml/sax/qxmlinputsource/tst_qxmlinputsource.cpp
@@ -72,7 +72,7 @@ private slots:
void tst_QXmlInputSource::reset() const
{
const QString input(QString::fromLatin1("<element attribute1='value1' attribute2='value2'/>"));
-
+
QXmlSimpleReader reader;
QXmlDefaultHandler handler;
reader.setContentHandler(&handler);
@@ -100,7 +100,7 @@ void tst_QXmlInputSource::reset() const
void tst_QXmlInputSource::resetSimplified() const
{
const QString input(QString::fromLatin1("<element/>"));
-
+
QXmlSimpleReader reader;
QXmlInputSource source;
diff --git a/tests/auto/xml/sax/qxmlsimplereader/parser/parser.cpp b/tests/auto/xml/sax/qxmlsimplereader/parser/parser.cpp
index 7c6c675fbe..c00a5c7caa 100644
--- a/tests/auto/xml/sax/qxmlsimplereader/parser/parser.cpp
+++ b/tests/auto/xml/sax/qxmlsimplereader/parser/parser.cpp
@@ -103,7 +103,7 @@ class ContentHandler : public QXmlDefaultHandler
const QString &result() const { return m_result; }
const QString &errorMsg() const { return m_error_msg; }
-
+
private:
QString nestPrefix() const { return QString().fill(' ', 3*m_nest); }
QString formatAttributes(const QXmlAttributes & atts);
diff --git a/tests/auto/xml/sax/qxmlsimplereader/parser/parser.pro b/tests/auto/xml/sax/qxmlsimplereader/parser/parser.pro
index 053f0d9285..f801200942 100644
--- a/tests/auto/xml/sax/qxmlsimplereader/parser/parser.pro
+++ b/tests/auto/xml/sax/qxmlsimplereader/parser/parser.pro
@@ -2,4 +2,3 @@ QT += xml
HEADERS += parser.h
SOURCES += main.cpp parser.cpp
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/xml/sax/qxmlsimplereader/qxmlsimplereader.pro b/tests/auto/xml/sax/qxmlsimplereader/qxmlsimplereader.pro
index 298e41fc89..981f506c6d 100644
--- a/tests/auto/xml/sax/qxmlsimplereader/qxmlsimplereader.pro
+++ b/tests/auto/xml/sax/qxmlsimplereader/qxmlsimplereader.pro
@@ -10,4 +10,3 @@ QT += network xml testlib
QT -= gui
TESTDATA += encodings/* xmldocs/*
-DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/auto/xml/sax/sax.pro b/tests/auto/xml/sax/sax.pro
index 13aeb21d07..d232ee90e7 100644
--- a/tests/auto/xml/sax/sax.pro
+++ b/tests/auto/xml/sax/sax.pro
@@ -1,6 +1,8 @@
TEMPLATE=subdirs
SUBDIRS=\
- qxmlinputsource \
qxml \
+
+qtHaveModule(network): SUBDIRS += \
+ qxmlinputsource \
qxmlsimplereader \
diff --git a/tests/baselineserver/shared/lookup3.cpp b/tests/baselineserver/shared/lookup3.cpp
index b2d9ffeb94..2959356ca8 100644
--- a/tests/baselineserver/shared/lookup3.cpp
+++ b/tests/baselineserver/shared/lookup3.cpp
@@ -47,8 +47,8 @@ These functions are based on:
lookup3.c, by Bob Jenkins, May 2006, Public Domain.
These are functions for producing 32-bit hashes for hash table lookup.
-hashword(), hashlittle(), hashlittle2(), hashbig(), mix(), and final()
-are externally useful functions. Routines to test the hash are included
+hashword(), hashlittle(), hashlittle2(), hashbig(), mix(), and final()
+are externally useful functions. Routines to test the hash are included
if SELF_TEST is defined. You can use this free for any purpose. It's in
the public domain. It has no warranty.
@@ -56,7 +56,7 @@ You probably want to use hashlittle(). hashlittle() and hashbig()
hash byte arrays. hashlittle() is is faster than hashbig() on
little-endian machines. Intel and AMD are little-endian machines.
On second thought, you probably want hashlittle2(), which is identical to
-hashlittle() except it returns two 32-bit hashes for the price of one.
+hashlittle() except it returns two 32-bit hashes for the price of one.
You could implement hashbig2() if you wanted but I haven't bothered here.
If you want to find a hash of, say, exactly 7 integers, do
@@ -69,9 +69,9 @@ If you want to find a hash of, say, exactly 7 integers, do
then use c as the hash value. If you have a variable length array of
4-byte integers to hash, use hashword(). If you have a byte array (like
a character string), use hashlittle(). If you have several byte arrays, or
-a mix of things, see the comments above hashlittle().
+a mix of things, see the comments above hashlittle().
-Why is this so big? I read 12 bytes at a time into 3 4-byte integers,
+Why is this so big? I read 12 bytes at a time into 3 4-byte integers,
then mix those integers. This is fast (you can do a lot more thorough
mixing with 12*3 instructions on 3 integers than you can with 3 instructions
on 1 byte), but shoehorning those bytes into integers efficiently is messy.
@@ -110,7 +110,7 @@ This was tested for:
the output delta to a Gray code (a^(a>>1)) so a string of 1's (as
is commonly produced by subtraction) look like a single 1-bit
difference.
-* the base values were pseudorandom, all zero but one bit set, or
+* the base values were pseudorandom, all zero but one bit set, or
all zero plus a counter that starts at zero.
Some k values for my "a-=c; a^=rot(c,k); c+=b;" arrangement that
@@ -120,7 +120,7 @@ satisfy this are
14 9 3 7 17 3
Well, "9 15 3 18 27 15" didn't quite get 32 bits diffing
for "differ" defined as + with a one-bit base and a two-bit delta. I
-used http://burtleburtle.net/bob/hash/avalanche.html to choose
+used http://burtleburtle.net/bob/hash/avalanche.html to choose
the operations, constants, and arrangements of the variables.
This does not achieve avalanche. There are input bits of (a,b,c)
@@ -159,7 +159,7 @@ produce values of c that look totally different. This was tested for
the output delta to a Gray code (a^(a>>1)) so a string of 1's (as
is commonly produced by subtraction) look like a single 1-bit
difference.
-* the base values were pseudorandom, all zero but one bit set, or
+* the base values were pseudorandom, all zero but one bit set, or
all zero plus a counter that starts at zero.
These constants passed:
@@ -218,7 +218,7 @@ quint32 initval) /* the previous hash, or an arbitrary value */
/*------------------------------------------- handle the last 3 quint32's */
switch(length) /* all the case statements fall through */
- {
+ {
case 3 : c+=k[2];
case 2 : b+=k[1];
case 1 : a+=k[0];
@@ -235,7 +235,7 @@ quint32 initval) /* the previous hash, or an arbitrary value */
--------------------------------------------------------------------
hashword2() -- same as hashword(), but take two seeds and return two
32-bit values. pc and pb must both be nonnull, and *pc and *pb must
-both be initialized with seeds. If you pass in (*pb)==0, the output
+both be initialized with seeds. If you pass in (*pb)==0, the output
(*pc) will be the same as the return value from hashword().
--------------------------------------------------------------------
*/
@@ -264,7 +264,7 @@ quint32 *pb) /* IN: more seed OUT: secondary hash value */
/*------------------------------------------- handle the last 3 quint32's */
switch(length) /* all the case statements fall through */
- {
+ {
case 3 : c+=k[2];
case 2 : b+=k[1];
case 1 : a+=k[0];
@@ -328,7 +328,7 @@ quint32 hashlittle( const void *key, size_t length, quint32 initval)
}
/*----------------------------- handle the last (probably partial) block */
- /*
+ /*
* "k[2]&0xffffff" actually reads beyond the end of the string, but
* then masks off the part it's not allowed to read. Because the
* string is aligned, the masked-off tail is in the same word as the
@@ -483,7 +483,7 @@ quint32 hashlittle( const void *key, size_t length, quint32 initval)
* the key. *pc is better mixed than *pb, so use *pc first. If you want
* a 64-bit value do something like "*pc + (((uint64_t)*pb)<<32)".
*/
-void hashlittle2(
+void hashlittle2(
const void *key, /* the key to hash */
size_t length, /* length of the key */
quint32 *pc, /* IN: primary initval, OUT: primary hash */
@@ -512,7 +512,7 @@ void hashlittle2(
}
/*----------------------------- handle the last (probably partial) block */
- /*
+ /*
* "k[2]&0xffffff" actually reads beyond the end of the string, but
* then masks off the part it's not allowed to read. Because the
* string is aligned, the masked-off tail is in the same word as the
@@ -662,7 +662,7 @@ void hashlittle2(
* hashbig():
* This is the same as hashword() on big-endian machines. It is different
* from hashlittle() on all machines. hashbig() takes advantage of
- * big-endian byte ordering.
+ * big-endian byte ordering.
*/
quint32 hashbig( const void *key, size_t length, quint32 initval)
{
@@ -688,7 +688,7 @@ quint32 hashbig( const void *key, size_t length, quint32 initval)
}
/*----------------------------- handle the last (probably partial) block */
- /*
+ /*
* "k[2]<<8" actually reads beyond the end of the string, but
* then shifts out the part it's not allowed to read. Because the
* string is aligned, the illegal read is in the same word as the
diff --git a/tests/benchmarks/README b/tests/benchmarks/README
index d437299fee..8d017cd9a7 100644
--- a/tests/benchmarks/README
+++ b/tests/benchmarks/README
@@ -2,7 +2,7 @@ The most reliable way of running benchmarks is to do it in an otherwise idle
system. On a busy system, the results will vary according to the other tasks
demanding attention in the system.
-We have managed to obtain quite reliable results by doing the following on
+We have managed to obtain quite reliable results by doing the following on
Linux (and you need root):
- switching the scheduler to a Real-Time mode
@@ -10,23 +10,23 @@ Linux (and you need root):
- disabling the other thread of the same core
This should work rather well for CPU-intensive tasks. A task that is in Real-
-Time mode will simply not be preempted by the OS. But if you make OS syscalls,
-especially I/O ones, your task will be de-scheduled. Note that this includes
-page faults, so if you can, make sure your benchmark's warmup code paths touch
+Time mode will simply not be preempted by the OS. But if you make OS syscalls,
+especially I/O ones, your task will be de-scheduled. Note that this includes
+page faults, so if you can, make sure your benchmark's warmup code paths touch
most of the data.
-To do this you need a tool called schedtool (package schedtool), from
+To do this you need a tool called schedtool (package schedtool), from
http://freequaos.host.sk/schedtool/
From this point on, we are using CPU0 for all tasks:
-If you have a Hyperthreaded multi-core processor (Core-i5 and Core-i7), you
-have to disable the other thread of the same core as CPU0. To discover which
+If you have a Hyperthreaded multi-core processor (Core-i5 and Core-i7), you
+have to disable the other thread of the same core as CPU0. To discover which
one it is:
$ cat /sys/devices/system/cpu/cpu0/topology/thread_siblings_list
-This will print something like 0,4, meaning that CPUs 0 and 4 are sibling
+This will print something like 0,4, meaning that CPUs 0 and 4 are sibling
threads on the same core. So we'll turn CPU 4 off:
(as root)
@@ -34,7 +34,7 @@ threads on the same core. So we'll turn CPU 4 off:
To turn it back on, echo 1 into the same file.
-To run a task on CPU 0 exclusively, using FIFO RT priority 10, you run the
+To run a task on CPU 0 exclusively, using FIFO RT priority 10, you run the
following:
(as root)
@@ -43,38 +43,38 @@ following:
For example:
# schedtool -F -p 10 -a 1 -e ./tst_bench_qstring -tickcounter
-Warning: if your task livelocks or takes far too long to complete, your system
-may be unusable for a long time, especially if you don't have other cores to
+Warning: if your task livelocks or takes far too long to complete, your system
+may be unusable for a long time, especially if you don't have other cores to
run stuff on. To prevent that, run it before schedtool and time it.
-You can also limit the CPU time that the task is allowed to take. Run in the
+You can also limit the CPU time that the task is allowed to take. Run in the
same shell as you'll run schedtool:
$ ulimit -s 300
To limit to 300 seconds (5 minutes)
-If your task runs away, it will get a SIGXCPU after consuming 5 minutes of CPU
+If your task runs away, it will get a SIGXCPU after consuming 5 minutes of CPU
time (5 minutes running at 100%).
-If your app is multithreaded, you may want to give it more CPUs, like CPU0 and
+If your app is multithreaded, you may want to give it more CPUs, like CPU0 and
CPU1 with -a 3 (it's a bitmask).
-For best results, you should disable ALL other cores and threads of the same
-processor. The new Core-i7 have one processor with 4 cores,
-each core can run 2 threads; the older Mac Pros have two processors with 4
-cores each. So on those Mac Pros, you'd disable cores 1, 2 and 3, while on the
+For best results, you should disable ALL other cores and threads of the same
+processor. The new Core-i7 have one processor with 4 cores,
+each core can run 2 threads; the older Mac Pros have two processors with 4
+cores each. So on those Mac Pros, you'd disable cores 1, 2 and 3, while on the
Core-i7, you'll need to disable all other CPUs.
-However, disabling just the sibling thread seems to produce very reliable
-results for me already, with variance often below 0.5% (even though there are
+However, disabling just the sibling thread seems to produce very reliable
+results for me already, with variance often below 0.5% (even though there are
some measurable spikes).
Other things to try:
-Running the benchmark with highest priority, i.e. "sudo nice -19"
-usually produces stable results on some machines. If the benchmark also
-involves displaying something on the screen (on X11), running it with
-"-sync" is a must. Though, in that case the "real" cost is not correct,
+Running the benchmark with highest priority, i.e. "sudo nice -19"
+usually produces stable results on some machines. If the benchmark also
+involves displaying something on the screen (on X11), running it with
+"-sync" is a must. Though, in that case the "real" cost is not correct,
but it is useful to discover regressions.
Also; not many people know about ionice (1)
diff --git a/tests/benchmarks/benchmarks.pro b/tests/benchmarks/benchmarks.pro
index 5fd8ff6368..e5a6f5d7d2 100644
--- a/tests/benchmarks/benchmarks.pro
+++ b/tests/benchmarks/benchmarks.pro
@@ -2,11 +2,11 @@ TEMPLATE = subdirs
SUBDIRS = \
corelib \
gui \
- network \
sql \
# removed-by-refactor qtHaveModule(opengl): SUBDIRS += opengl
qtHaveModule(dbus): SUBDIRS += dbus
+qtHaveModule(network): SUBDIRS += network
check-trusted.CONFIG += recursive
QMAKE_EXTRA_TARGETS += check-trusted
diff --git a/tests/benchmarks/corelib/io/qdir/tree/bench_qdir_tree.cpp b/tests/benchmarks/corelib/io/qdir/tree/bench_qdir_tree.cpp
index 9a82711b84..37f52a3dce 100644
--- a/tests/benchmarks/corelib/io/qdir/tree/bench_qdir_tree.cpp
+++ b/tests/benchmarks/corelib/io/qdir/tree/bench_qdir_tree.cpp
@@ -123,14 +123,14 @@ private slots:
for (int i=0;i<1000;i++) {
if ((i % 10) == 0)
QVERIFY(fs.createDirectory(QString("%1/directory%2").arg(musicprefix).arg(i/10)));
- qint64 size = fs.createFileWithContent(QString("%1/directory%2/file%3").arg(musicprefix).arg(i/10).arg(i));
+ qint64 size = fs.createFileWithContent(QString("%1/directory%2/file%3").arg(musicprefix).arg(i/10).arg(i));
QVERIFY(size > 0);
musicsize += size;
}
//Use case: photos - 1000 files in 1 directory
QVERIFY(fs.createDirectory(photoprefix));
for (int i=0;i<1000;i++) {
- qint64 size = fs.createFileWithContent(QString("%1/file%2").arg(photoprefix).arg(i));
+ qint64 size = fs.createFileWithContent(QString("%1/file%2").arg(photoprefix).arg(i));
QVERIFY(size > 0);
photosize += size;
}
@@ -141,7 +141,7 @@ private slots:
QVERIFY(fs.createDirectory(QString("%1/directory%2").arg(sourceprefix).arg(i/100)));
if ((i % 10) == 0)
QVERIFY(fs.createDirectory(QString("%1/directory%2/subdirectory%3").arg(sourceprefix).arg(i/100).arg(i/10)));
- qint64 size = fs.createFileWithContent(QString("%1/directory%2/subdirectory%3/file%4").arg(sourceprefix).arg(i/100).arg(i/10).arg(i));
+ qint64 size = fs.createFileWithContent(QString("%1/directory%2/subdirectory%3/file%4").arg(sourceprefix).arg(i/100).arg(i/10).arg(i));
QVERIFY(size > 0);
sourcesize += size;
}
diff --git a/tests/benchmarks/corelib/io/qdiriterator/qfilesystemiterator.cpp b/tests/benchmarks/corelib/io/qdiriterator/qfilesystemiterator.cpp
index 598153e3ce..bb4a921fc7 100644
--- a/tests/benchmarks/corelib/io/qdiriterator/qfilesystemiterator.cpp
+++ b/tests/benchmarks/corelib/io/qdiriterator/qfilesystemiterator.cpp
@@ -368,7 +368,7 @@ bool QFileSystemIteratorPrivate::shouldFollowDirectory(const QFileInfo &fileInfo
// If we're doing flat iteration, we're done.
if (!(iteratorFlags & QFileSystemIterator::Subdirectories))
return false;
-
+
// Never follow non-directory entries
if (!fileInfo.isDir())
return false;
@@ -378,7 +378,7 @@ bool QFileSystemIteratorPrivate::shouldFollowDirectory(const QFileInfo &fileInfo
if (fileInfo.fileName() == QLatin1String(".") || fileInfo.fileName() == QLatin1String(".."))
return false;
-
+
// Check symlinks
if (fileInfo.isSymLink() && !(iteratorFlags & QFileSystemIterator::FollowSymlinks)) {
// Follow symlinks only if FollowSymlinks was passed
@@ -388,10 +388,10 @@ bool QFileSystemIteratorPrivate::shouldFollowDirectory(const QFileInfo &fileInfo
// Stop link loops
if (visitedLinks.contains(fileInfo.canonicalFilePath()))
return false;
-
+
return true;
}
-
+
/*!
\internal
@@ -454,7 +454,7 @@ bool QFileSystemIteratorPrivate::matchesFilters(const QAbstractFileEngineIterato
return false;
}
#endif
-
+
bool dotOrDotDot = (fileName == QLatin1String(".") || fileName == QLatin1String(".."));
if ((filters & QDir::NoDotAndDotDot) && dotOrDotDot)
return false;
@@ -495,7 +495,7 @@ bool QFileSystemIteratorPrivate::matchesFilters(const QAbstractFileEngineIterato
|| (!fi.exists() && fi.isSymLink()))) {
return false;
}
-
+
return true;
}
#endif
@@ -608,7 +608,7 @@ bool QFileSystemIterator::atEnd() const
This function is provided for the convenience when iterating single
directories. For recursive iteration, you should call filePath() or
fileInfo() instead.
-
+
\sa filePath(), fileInfo()
*/
QString QFileSystemIterator::fileName() const
diff --git a/tests/benchmarks/corelib/io/qdiriterator/qfilesystemiterator.h b/tests/benchmarks/corelib/io/qdiriterator/qfilesystemiterator.h
index 3c23a4d85b..d59678823d 100644
--- a/tests/benchmarks/corelib/io/qdiriterator/qfilesystemiterator.h
+++ b/tests/benchmarks/corelib/io/qdiriterator/qfilesystemiterator.h
@@ -44,8 +44,6 @@
#include <QtCore/qdir.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -93,6 +91,4 @@ Q_DECLARE_OPERATORS_FOR_FLAGS(QFileSystemIterator::IteratorFlags)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif
diff --git a/tests/benchmarks/corelib/io/qfile/main.cpp b/tests/benchmarks/corelib/io/qfile/main.cpp
index 4eb123f00c..ef5fd36254 100644
--- a/tests/benchmarks/corelib/io/qfile/main.cpp
+++ b/tests/benchmarks/corelib/io/qfile/main.cpp
@@ -184,9 +184,9 @@ void tst_qfile::readBigFile_QFSFileEngine()
QSKIP("This test requires -developer-build.");
#endif
}
-void tst_qfile::readBigFile_posix()
-{
- readBigFile();
+void tst_qfile::readBigFile_posix()
+{
+ readBigFile();
}
void tst_qfile::readBigFile_Win32() { readBigFile(); }
@@ -509,13 +509,13 @@ void tst_qfile::readSmallFiles_QFSFileEngine()
QSKIP("This test requires -developer-build.");
#endif
}
-void tst_qfile::readSmallFiles_posix()
+void tst_qfile::readSmallFiles_posix()
{
- readSmallFiles();
+ readSmallFiles();
}
-void tst_qfile::readSmallFiles_Win32()
-{
- readSmallFiles();
+void tst_qfile::readSmallFiles_Win32()
+{
+ readSmallFiles();
}
void tst_qfile::readSmallFiles_QFile_data()
diff --git a/tests/benchmarks/corelib/tools/containers-associative/main.cpp b/tests/benchmarks/corelib/tools/containers-associative/main.cpp
index e4511f4935..d2275ddb92 100644
--- a/tests/benchmarks/corelib/tools/containers-associative/main.cpp
+++ b/tests/benchmarks/corelib/tools/containers-associative/main.cpp
@@ -52,7 +52,7 @@ private slots:
void lookup();
};
-template <typename T>
+template <typename T>
void testInsert(int size)
{
T container;
@@ -69,7 +69,7 @@ void tst_associative_containers::insert_data()
QTest::addColumn<int>("size");
for (int size = 10; size < 20000; size += 100) {
-
+
const QByteArray sizeString = QByteArray::number(size);
QTest::newRow(QByteArray("hash--" + sizeString).constData()) << true << size;
@@ -86,9 +86,9 @@ void tst_associative_containers::insert()
QMap<int, int> testMap;
if (useHash) {
- testInsert<QHash<int, int> >(size);
+ testInsert<QHash<int, int> >(size);
} else {
- testInsert<QMap<int, int> >(size);
+ testInsert<QMap<int, int> >(size);
}
}
@@ -101,7 +101,7 @@ void tst_associative_containers::lookup_data()
QTest::addColumn<int>("size");
for (int size = 10; size < 20000; size += 100) {
-
+
const QByteArray sizeString = QByteArray::number(size);
QTest::newRow(QByteArray("hash--" + sizeString).constData()) << true << size;
@@ -109,11 +109,11 @@ void tst_associative_containers::lookup_data()
}
}
-template <typename T>
+template <typename T>
void testLookup(int size)
{
T container;
-
+
for (int i = 0; i < size; ++i)
container.insert(i, i);
@@ -122,7 +122,7 @@ void testLookup(int size)
QBENCHMARK {
for (int i = 0; i < size; ++i)
val = container.value(i);
-
+
}
}
diff --git a/tests/benchmarks/corelib/tools/qmap/main.cpp b/tests/benchmarks/corelib/tools/qmap/main.cpp
index e0bd994967..53b2a90fab 100644
--- a/tests/benchmarks/corelib/tools/qmap/main.cpp
+++ b/tests/benchmarks/corelib/tools/qmap/main.cpp
@@ -64,6 +64,14 @@ private slots:
void iterator_begin();
void ctorStdMap();
+
+ void insertion_int_intx();
+ void insertion_int_int_with_hint1();
+ void insertion_int_int2();
+ void insertion_int_int_with_hint2();
+
+ void insertion_string_int2();
+ void insertion_string_int2_hint();
};
@@ -76,6 +84,44 @@ void tst_QMap::insertion_int_int()
}
}
+void tst_QMap::insertion_int_intx()
+{
+ // This is the same test - but executed later.
+ // The results in the beginning of the test seems to be a somewhat inaccurate.
+ QMap<int, int> map;
+ QBENCHMARK {
+ for (int i = 0; i < 100000; ++i)
+ map.insert(i, i);
+ }
+}
+
+void tst_QMap::insertion_int_int_with_hint1()
+{
+ QMap<int, int> map;
+ QBENCHMARK {
+ for (int i = 0; i < 100000; ++i)
+ map.insert(map.constEnd(), i, i);
+ }
+}
+
+void tst_QMap::insertion_int_int2()
+{
+ QMap<int, int> map;
+ QBENCHMARK {
+ for (int i = 100000; i >= 0; --i)
+ map.insert(i, i);
+ }
+}
+
+void tst_QMap::insertion_int_int_with_hint2()
+{
+ QMap<int, int> map;
+ QBENCHMARK {
+ for (int i = 100000; i >= 0; --i)
+ map.insert(map.constBegin(), i, i);
+ }
+}
+
void tst_QMap::insertion_int_string()
{
QMap<int, QString> map;
@@ -203,6 +249,38 @@ void tst_QMap::ctorStdMap()
}
}
+class XString : public QString
+{
+public:
+ bool operator < (const XString& x) const // an expensive operator <
+ {
+ return toInt() < x.toInt();
+ }
+};
+
+void tst_QMap::insertion_string_int2()
+{
+ QMap<XString, int> map;
+ QBENCHMARK {
+ for (int i = 1; i < 5000; ++i) {
+ XString str;
+ str.setNum(i);
+ map.insert(str, i);
+ }
+ }
+}
+
+void tst_QMap::insertion_string_int2_hint()
+{
+ QMap<XString, int> map;
+ QBENCHMARK {
+ for (int i = 1; i < 5000; ++i) {
+ XString str;
+ str.setNum(i);
+ map.insert(map.end(), str, i);
+ }
+ }
+}
QTEST_MAIN(tst_QMap)
diff --git a/tests/benchmarks/corelib/tools/qregexp/main.cpp b/tests/benchmarks/corelib/tools/qregexp/main.cpp
index a34888ab13..3f8ebbecc5 100644
--- a/tests/benchmarks/corelib/tools/qregexp/main.cpp
+++ b/tests/benchmarks/corelib/tools/qregexp/main.cpp
@@ -139,13 +139,13 @@ void tst_qregexp::escape_data()
QTest::newRow("escape 0") << "Hello world" << "Hello world";
QTest::newRow("escape 1") << "(Hello world)" << "\\(Hello world\\)";
- {
+ {
QString s;
for (int i = 0; i < 10; ++i)
s += "(escape)";
QTest::newRow("escape 10") << s << QRegExp::escape(s);
}
- {
+ {
QString s;
for (int i = 0; i < 100; ++i)
s += "(escape)";
@@ -242,7 +242,7 @@ void tst_qregexp::escape_new2()
*quotedData = c;
++quotedData;
}
- quoted.resize(pattern.size() + escaped);
+ quoted.resize(pattern.size() + escaped);
verify(quoted, expected);
}
@@ -329,7 +329,7 @@ void tst_qregexp::escape_new4()
const QLatin1Char backslash('\\');
QString quoted(n * 2, backslash);
QChar *quotedData = quoted.data();
- for (int j = 0; j != i; ++j)
+ for (int j = 0; j != i; ++j)
*quotedData++ = *patternData++;
int escaped = 0;
for (; i != n; ++i) {
@@ -342,7 +342,7 @@ void tst_qregexp::escape_new4()
++quotedData;
++patternData;
}
- quoted.resize(n + escaped);
+ quoted.resize(n + escaped);
verify(quoted, expected);
// "return quoted"
}
diff --git a/tests/benchmarks/corelib/tools/qvector/main.cpp b/tests/benchmarks/corelib/tools/qvector/main.cpp
index 1795f2dc6f..f7325f7998 100644
--- a/tests/benchmarks/corelib/tools/qvector/main.cpp
+++ b/tests/benchmarks/corelib/tools/qvector/main.cpp
@@ -83,7 +83,7 @@ qvector_const_read_access:
xorl %eax, %eax
.L183:
! fldl s
-! faddl 16(%edx,%eax,8)
+! faddl 16(%edx,%eax,8)
! addl $1, %eax
! cmpl $10000, %eax
! fstpl s
@@ -206,6 +206,7 @@ private slots:
void qvector_separator() { qWarning() << "QVector results: "; }
void qvector_const_read_access();
void qvector_mutable_read_access();
+ void qvector_pop_back();
#ifdef TEST_RETURN
void qvector_fill_and_return();
#endif
@@ -214,6 +215,8 @@ private slots:
void stdvector() { qWarning() << "std::vector results: "; }
void stdvector_const_read_access();
void stdvector_mutable_read_access();
+ void stdvector_pop_back();
+
#ifdef TEST_RETURN
void stdvector_fill_and_return();
#endif
@@ -315,6 +318,24 @@ void tst_QVector::qrawvector_mutable_read_access()
}
}
+void tst_QVector::qvector_pop_back()
+{
+ const int c1 = 100000;
+ QVERIFY(N % c1 == 0);
+
+ QVector<int> v;
+ v.resize(N);
+
+ QBENCHMARK {
+ for (int i = 0; i < c1; ++i)
+ v.pop_back();
+ if (v.size() == 0)
+ v.resize(N);
+ }
+}
+
+
+
#ifdef TEST_RETURN
extern QVector<double> qrawvector_fill_and_return_helper();
@@ -356,6 +377,22 @@ void tst_QVector::stdvector_mutable_read_access()
}
}
+void tst_QVector::stdvector_pop_back()
+{
+ const int c1 = 100000;
+ QVERIFY(N % c1 == 0);
+
+ std::vector<int> v;
+ v.resize(N);
+
+ QBENCHMARK {
+ for (int i = 0; i < c1; ++i)
+ v.pop_back();
+ if (v.size() == 0)
+ v.resize(N);
+ }
+}
+
#ifdef TEST_RETURN
extern std::vector<double> stdvector_fill_and_return_helper();
diff --git a/tests/benchmarks/corelib/tools/qvector/qrawvector.h b/tests/benchmarks/corelib/tools/qvector/qrawvector.h
index 1bfc107d39..f358909eb1 100644
--- a/tests/benchmarks/corelib/tools/qvector/qrawvector.h
+++ b/tests/benchmarks/corelib/tools/qvector/qrawvector.h
@@ -55,8 +55,6 @@
#include <stdlib.h>
#include <string.h>
-QT_BEGIN_HEADER
-
QT_BEGIN_NAMESPACE
@@ -102,7 +100,7 @@ public:
static T *fromBase(void *d)
{ return (T*)((char*)d + offsetOfTypedData()); }
- inline QRawVector()
+ inline QRawVector()
{ m_begin = fromBase(0); m_alloc = m_size = 0; realloc(m_size, m_alloc, true); }
explicit QRawVector(int size);
QRawVector(int size, const T &t);
@@ -752,6 +750,4 @@ Q_DECLARE_MUTABLE_SEQUENTIAL_ITERATOR(RawVector)
QT_END_NAMESPACE
-QT_END_HEADER
-
#endif // QRAWVECTOR_H
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.cpp
index 5e4b1e3a2f..e9204e3282 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemcontainer.cpp
@@ -259,7 +259,7 @@ void AbstractItemContainer::updateItemBuffer()
QModelIndex index;
if (m_items.count() > 0)
index = m_items.last()->modelIndex();
- while (m_items.count() < maxCount) {
+ while (m_items.count() < maxCount) {
index = m_itemView->nextIndex(index);
if (!index.isValid())
@@ -311,7 +311,7 @@ void AbstractItemContainer::insertItem(int pos, const QModelIndex &index)
item = m_prototype->newItemInstance();
if (item) {
- item->setModel(m_itemView->model());
+ item->setModel(m_itemView->model());
item->setModelIndex(index);
item->setTwoColumns(m_twoColumns);
m_items.insert(pos, item);
@@ -335,7 +335,7 @@ void AbstractItemContainer::findFirstAndLastVisibleBufferIndex(int &firstVisible
lastVisibleBufferIndex = -1;
int count = m_items.count();
- for (int i = 0; i < count; ++i) {
+ for (int i = 0; i < count; ++i) {
if (itemVisibleInView(m_items.at(i), viewRect, fullyVisible)) {
if (firstVisibleBufferIndex == -1)
firstVisibleBufferIndex = i;
@@ -359,13 +359,13 @@ int AbstractItemContainer::maxItemCountInItemBuffer() const
void AbstractItemContainer::themeChange()
{
- for (int i = 0; i <m_items.count(); ++i)
+ for (int i = 0; i <m_items.count(); ++i)
m_items.at(i)->themeChange();
}
-void AbstractItemContainer::updateContent()
+void AbstractItemContainer::updateContent()
{
- for (int i = 0; i <m_items.count(); ++i)
+ for (int i = 0; i <m_items.count(); ++i)
m_items.at(i)->updateItemContents();
}
@@ -389,7 +389,7 @@ void AbstractItemContainer::setTwoColumns(const bool enabled)
}
bool AbstractItemContainer::twoColumns()
-{
+{
return m_twoColumns;
}
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.cpp
index 06fd5d9754..779b99a0c5 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractitemview.cpp
@@ -63,8 +63,8 @@ AbstractItemView::~AbstractItemView()
/*virtual*/
void AbstractItemView::setModel(QAbstractItemModel *model, AbstractViewItem *prototype)
-{
- if( m_model == model || !model)
+{
+ if (m_model == model || !model)
return;
if (m_model) {
@@ -236,7 +236,7 @@ void AbstractItemView::currentIndexChanged(const QModelIndex &current, const QMo
/*virtual*/
void AbstractItemView::currentSelectionChanged(const QItemSelection &selected,
- const QItemSelection &deselected)
+ const QItemSelection &deselected)
{
Q_UNUSED(selected)
Q_UNUSED(deselected)
@@ -260,7 +260,6 @@ void AbstractItemView::rowsAboutToBeInserted(const QModelIndex &index, int start
// TODO implement
}
-
/*virtual*/
void AbstractItemView::rowsAboutToBeRemoved(const QModelIndex &index,int start, int end)
{
@@ -346,7 +345,7 @@ bool AbstractItemView::event(QEvent *e)
m_container->resize(this->size().width()-verticalScrollBar()->size().width(),
m_container->preferredHeight());
- if(verticalScrollBar()->sliderPosition() > verticalScrollBar()->sliderSize())
+ if (verticalScrollBar()->sliderPosition() > verticalScrollBar()->sliderSize())
verticalScrollBar()->setSliderPosition(verticalScrollBar()->sliderSize());
result = true;
@@ -371,7 +370,7 @@ void AbstractItemView::refreshContainerGeometry()
ScrollBar *sb = verticalScrollBar();
if (sb) {
- AbstractViewItem *item = m_container->itemAt(0);
+ AbstractViewItem *item = m_container->itemAt(0);
if (item) {
qreal oneItemH = item->size().height();
sb->setSliderSize(oneItemH*m_model->rowCount(m_rootIndex)-size().height());
@@ -394,10 +393,9 @@ void AbstractItemView::scrollContentsBy(qreal dx, qreal dy)
qreal itemH = 1;
AbstractViewItem *item = m_container->itemAt(0);
- if(item && item->size().height() > 1) {
+ if (item && item->size().height() > 1) {
itemH = item->size().height();
- }
- else if(item && item->preferredHeight() > 1) {
+ } else if (item && item->preferredHeight() > 1) {
itemH = item->preferredHeight();
}
@@ -407,8 +405,7 @@ void AbstractItemView::scrollContentsBy(qreal dx, qreal dy)
if ((vpy+m_container->size().height()-dy > pos().y()+size().height()) &&
(qAbs(dy) < itemH) && (vpy-dy <= 0)) {
m_container->setPos(vpx, vpy-dy);
- }
- else {
+ } else {
qreal vPos = verticalScrollBar()->sliderPosition();
int startRow = m_model->index(vPos/itemH, 0).row();
int itemsInContainer = m_container->itemCount();
@@ -428,13 +425,13 @@ void AbstractItemView::scrollContentsBy(qreal dx, qreal dy)
}
}
-void AbstractItemView::changeTheme()
+void AbstractItemView::changeTheme()
{
if (m_container)
m_container->themeChange();
}
-void AbstractItemView::updateViewContent()
+void AbstractItemView::updateViewContent()
{
if (m_container)
m_container->updateContent();
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.cpp
index c904cb520b..bdd18e234f 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.cpp
@@ -54,11 +54,11 @@ AbstractScrollArea::AbstractScrollArea(QGraphicsWidget *parent)
, m_prevVerticalValue(0.0)
{
setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
- setContentsMargins(0, 0, 0, 0);
+ setContentsMargins(0, 0, 0, 0);
m_horizontalScrollBar = new ScrollBar(Qt::Horizontal, this);
m_horizontalScrollBar->hide();
- m_horizontalScrollBar->setContentsMargins(0, 0, 0, 0);
+ m_horizontalScrollBar->setContentsMargins(0, 0, 0, 0);
m_horizontalScrollBarPolicy = Qt::ScrollBarAsNeeded;
m_horizontalScrollBar->setZValue(zValue()+1); // Raise scroll bar to top
m_horizontalScrollBar->setVisible(false);
@@ -70,7 +70,7 @@ AbstractScrollArea::AbstractScrollArea(QGraphicsWidget *parent)
m_verticalScrollBar = new ScrollBar(Qt::Vertical, this);
m_verticalScrollBar->hide();
- m_verticalScrollBar->setContentsMargins(0, 0, 0, 0);
+ m_verticalScrollBar->setContentsMargins(0, 0, 0, 0);
m_verticalScrollBarPolicy = Qt::ScrollBarAsNeeded;
m_verticalScrollBar->setZValue(zValue()+1); // Raise scroll bar to top
m_verticalScrollBar->setVisible(false);
@@ -153,8 +153,8 @@ bool AbstractScrollArea::event(QEvent *e)
{
if (e->type() == QEvent::ApplicationLayoutDirectionChange
|| e->type() == QEvent::LayoutDirectionChange) {
- } else if (e->type() == QEvent::GraphicsSceneResize) {
- QGraphicsSceneResizeEvent *event =
+ } else if (e->type() == QEvent::GraphicsSceneResize) {
+ QGraphicsSceneResizeEvent *event =
static_cast<QGraphicsSceneResizeEvent*>(e);
QSizeF newSize = event->newSize();
@@ -186,7 +186,7 @@ void AbstractScrollArea::scrollContentsBy(qreal dx, qreal dy)
void AbstractScrollArea::verticalScrollStart()
{
- m_prevVerticalValue = m_verticalScrollBar->sliderPosition();
+ m_prevVerticalValue = m_verticalScrollBar->sliderPosition();
}
void AbstractScrollArea::verticalScroll(qreal value)
@@ -200,7 +200,7 @@ void AbstractScrollArea::verticalScroll(qreal value)
void AbstractScrollArea::horizontalScrollStart()
{
- m_prevHorizontalValue = m_horizontalScrollBar->sliderPosition();
+ m_prevHorizontalValue = m_horizontalScrollBar->sliderPosition();
}
void AbstractScrollArea::horizontalScroll(qreal value)
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.h
index 8f90277994..b4c32bf668 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/abstractscrollarea.h
@@ -90,8 +90,8 @@ private:
void adjustScrollBars();
QGraphicsWidget *m_viewport;
- ScrollBar *m_horizontalScrollBar;
- ScrollBar *m_verticalScrollBar;
+ ScrollBar *m_horizontalScrollBar;
+ ScrollBar *m_verticalScrollBar;
Qt::ScrollBarPolicy m_verticalScrollBarPolicy;
Qt::ScrollBarPolicy m_horizontalScrollBarPolicy;
qreal m_prevHorizontalValue;
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.cpp
index 04626c4855..c4e10a36c6 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.cpp
@@ -59,7 +59,6 @@ BackgroundItem::BackgroundItem(const QString &filename, QGraphicsWidget *parent)
BackgroundItem::~BackgroundItem()
{
-
}
void BackgroundItem::resizeEvent(QGraphicsSceneResizeEvent *event)
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.h
index a637a50408..38a176e73d 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/backgrounditem.h
@@ -51,19 +51,19 @@ class QGraphicsWidget;
class BackgroundItem : public GvbWidget
{
Q_OBJECT
-
+
public:
BackgroundItem(const QString &filename, QGraphicsWidget *parent=0);
~BackgroundItem();
-
+
void paint(QPainter *painter,
const QStyleOptionGraphicsItem *option,
QWidget *widget = 0);
void resizeEvent(QGraphicsSceneResizeEvent *event);
-
+
public slots:
void themeChange();
-
+
private:
QPixmap m_background;
QString m_fileName;
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/button.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/button.cpp
index 37d2318746..8ca4307c8b 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/button.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/button.cpp
@@ -50,7 +50,7 @@ class ButtonPrivate {
public:
- ButtonPrivate(Button *button)
+ ButtonPrivate(Button *button)
: down(false)
, q_ptr(button)
{
@@ -65,7 +65,7 @@ public:
Button::Button(const QString &text, QGraphicsItem *parent, QSizeF minimumSize)
: QGraphicsWidget(parent)
, d_ptr(new ButtonPrivate(this)), m_background(), m_selected(false)
-{
+{
Q_D(Button);
setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Fixed);
//setCacheMode(QGraphicsItem::ItemCoordinateCache);
@@ -105,13 +105,13 @@ QString Button::text()
return d->textItem->text();
}
-void Button::paint(QPainter *painter,
- const QStyleOptionGraphicsItem *option,
+void Button::paint(QPainter *painter,
+ const QStyleOptionGraphicsItem *option,
QWidget *widget)
{
Q_UNUSED(widget);
Q_UNUSED(option);
-
+
if(!m_background.isNull())
painter->drawPixmap(QPoint(), m_background);
if(m_selected) {
@@ -121,8 +121,8 @@ void Button::paint(QPainter *painter,
}
}
-QSizeF Button::sizeHint(Qt::SizeHint which,
- const QSizeF &constraint) const
+QSizeF Button::sizeHint(Qt::SizeHint which,
+ const QSizeF &constraint) const
{
Q_D(const Button);
@@ -146,7 +146,7 @@ QSizeF Button::sizeHint(Qt::SizeHint which,
void Button::mousePressEvent(QGraphicsSceneMouseEvent *event)
{
Q_D(Button);
-
+
if (event->button() != Qt::LeftButton ||
!sceneBoundingRect().contains(event->scenePos()))
return;
@@ -162,7 +162,7 @@ void Button::mouseReleaseEvent(QGraphicsSceneMouseEvent *event)
{
Q_D(Button);
- if (!d->down || event->button() != Qt::LeftButton)
+ if (!d->down || event->button() != Qt::LeftButton)
return;
d->down = false;
@@ -184,11 +184,11 @@ void Button::resizeEvent(QGraphicsSceneResizeEvent *event)
{
Q_D(Button);
QGraphicsWidget::resizeEvent(event);
-
+
QRectF rect = d->textItem->boundingRect();
QRectF buttonrect = this->boundingRect();
d->textItem->setPos((buttonrect.width() - rect.width())/2, (buttonrect.height() - rect.height())/2 );
-
+
QSize currentSize = buttonrect.size().toSize();
if( m_background.size() != currentSize && (currentSize.width() > 0 && currentSize.height() > 0) ) {
m_background = Theme::p()->pixmap("status_field_middle.svg", buttonrect.size().toSize());
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/button.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/button.h
index 14ffb15626..8641d8a9b6 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/button.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/button.h
@@ -47,7 +47,7 @@
class ButtonPrivate;
class QTextDocument;
-class QPixmap;
+class QPixmap;
class QFont;
class Button : public QGraphicsWidget
@@ -73,7 +73,7 @@ public slots:
QString text();
public:
-
+
void setBackground(QPixmap& background);
bool isDown();
void select(bool select){m_selected = select;}
@@ -81,9 +81,9 @@ public:
private:
- void paint(QPainter *painter, const QStyleOptionGraphicsItem *option,
+ void paint(QPainter *painter, const QStyleOptionGraphicsItem *option,
QWidget *widget = 0);
- QSizeF sizeHint(Qt::SizeHint which,
+ QSizeF sizeHint(Qt::SizeHint which,
const QSizeF &constraint = QSizeF()) const;
void mousePressEvent(QGraphicsSceneMouseEvent *event);
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.cpp
index d98beefea6..06dea1b864 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.cpp
@@ -127,7 +127,7 @@ bool readSettingsFromCommandLine(int argc, char *argv[],
argv[i] = 0;
i++;
argv[i] = 0;
- }
+ }
}
if (!argv[i])
@@ -160,7 +160,7 @@ bool readSettingsFromCommandLine(int argc, char *argv[],
argv[i] = 0;
i++;
argv[i] = 0;
- }
+ }
} else if (strcmp(argv[i], "-subtree-cache") == 0) {
options |= Settings::UseListItemCache;
argv[i] = 0;
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.h
index 20d3706e9c..16525487da 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/commandline.h
@@ -44,7 +44,7 @@
#include "settings.h"
-bool readSettingsFromCommandLine(int argc,
+bool readSettingsFromCommandLine(int argc,
char *argv[],
Settings& settings);
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.cpp
index 86fc78d3f7..259e94aa2f 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.cpp
@@ -51,19 +51,19 @@ DummyDataGenerator::DummyDataGenerator() : m_isMale(false)
while (!countryCodeFile.atEnd()) {
m_countryCodes << QString(countryCodeFile.readLine()).remove("\n");
}
-
+
QFile firstNameFFile(":/contact/firstnamesF.txt");
firstNameFFile.open(QIODevice::ReadOnly);
while (!firstNameFFile.atEnd()) {
m_firstNamesF << QString(firstNameFFile.readLine()).remove("\n");
}
-
+
QFile firstNameMFile(":/contact/firstnamesM.txt");
firstNameMFile.open(QIODevice::ReadOnly);
while (!firstNameMFile.atEnd()) {
m_firstNamesM << QString(firstNameMFile.readLine()).remove("\n");
}
-
+
QFile lastNameFile(":/contact/lastnames.txt");
lastNameFile.open(QIODevice::ReadOnly);
while (!lastNameFile.atEnd()) {
@@ -74,7 +74,6 @@ DummyDataGenerator::DummyDataGenerator() : m_isMale(false)
DummyDataGenerator::~DummyDataGenerator()
{
-
}
void DummyDataGenerator::Reset()
@@ -89,7 +88,7 @@ QString DummyDataGenerator::randomPhoneNumber(QString indexNumber)
QString areaCode = QString::number(index) + QString("0").repeated(2-QString::number(index).length());
QString beginNumber = QString::number(555-index*2);
QString endNumber = QString("0").repeated(4-indexNumber.length()) + indexNumber;
-
+
return countryCode +" " + areaCode +" " + beginNumber +" " + endNumber;
}
@@ -116,14 +115,14 @@ QString DummyDataGenerator::randomIconItem()
QString avatar = Theme::p()->pixmapPath() + "contact_default_icon.svg";
if (qrand()%4) {
int randVal = 1+qrand()%25;
-
- if(m_isMale && randVal > 15) {
- randVal -= 15;
+
+ if (m_isMale && randVal > 15) {
+ randVal -= 15;
}
- if(!m_isMale && randVal <= 10) {
+ if (!m_isMale && randVal <= 10) {
randVal += 10;
}
-
+
avatar = QString(":/avatars/avatar_%1.png").arg(randVal, 3, 10, QChar('0'));
}
return avatar;
@@ -131,8 +130,7 @@ QString DummyDataGenerator::randomIconItem()
QString DummyDataGenerator::randomStatusItem()
{
- switch ( qrand()%3 )
- {
+ switch (qrand()%3) {
case 0: return Theme::p()->pixmapPath() + "contact_status_online.svg";
case 1: return Theme::p()->pixmapPath() + "contact_status_offline.svg";
case 2: return Theme::p()->pixmapPath() + "contact_status_idle.svg";
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.h
index 5e64357919..9f418390f0 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/dummydatagen.h
@@ -51,7 +51,7 @@ class DummyDataGenerator : public QObject
public:
DummyDataGenerator();
~DummyDataGenerator();
-
+
public:
void Reset();
QString randomPhoneNumber(QString indexNumber);
@@ -60,7 +60,7 @@ public:
QString randomName();
QString randomIconItem();
QString randomStatusItem();
-
+
private:
QStringList m_countryCodes;
QStringList m_firstNamesF;
@@ -69,4 +69,4 @@ private:
bool m_isMale;
};
-#endif // __DUMMYDATAGEN_H__
+#endif // __DUMMYDATAGEN_H__
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.h
index 8348d429b5..5d23c55102 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/gvbwidget.h
@@ -44,7 +44,7 @@
#include <QGraphicsWidget>
-class GvbWidget : public QGraphicsWidget
+class GvbWidget : public QGraphicsWidget
{
Q_OBJECT
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.cpp
index 13713940c8..d68d7f799f 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.cpp
@@ -45,7 +45,7 @@
#include "iconitem.h"
-IconItem::IconItem(const QString &filename, QGraphicsItem *parent)
+IconItem::IconItem(const QString &filename, QGraphicsItem *parent)
: GvbWidget(parent)
, m_filename(filename)
, m_rotation(0.0)
@@ -79,7 +79,7 @@ void IconItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option,
painter->drawPixmap(0,0, m_pixmap);
}
-QSizeF IconItem::sizeHint(Qt::SizeHint which,
+QSizeF IconItem::sizeHint(Qt::SizeHint which,
const QSizeF &constraint) const
{
switch (which)
@@ -144,7 +144,7 @@ void IconItem::setOpacityEffectEnabled(const bool enable)
gradient.setColorAt(0.0, QColor(0,0,0, 255));
gradient.setColorAt(0.46, QColor(0,0,0, 255));
gradient.setColorAt(0.62, QColor(0,0,0, 0));
-
+
m_opacityEffect = new QGraphicsOpacityEffect;
m_opacityEffect->setOpacityMask(gradient);
m_opacityEffect->setOpacity(1.0);
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.h
index 7d4510479b..9d1fb168de 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/iconitem.h
@@ -74,7 +74,7 @@ public:
private:
virtual void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget */*widget = 0*/);
- QSizeF sizeHint(Qt::SizeHint which,
+ QSizeF sizeHint(Qt::SizeHint which,
const QSizeF &constraint = QSizeF()) const;
private:
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.cpp
index 1856d74500..fc6d5683ee 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.cpp
@@ -52,7 +52,7 @@
ItemRecyclingList::ItemRecyclingList(const int itemBuffer, QGraphicsWidget * parent)
: ItemRecyclingListView(parent),
m_listModel(new ListModel(this))
-{
+{
ListItemContainer *container = new ListItemContainer(itemBuffer, this, this);
container->setParentItem(this);
ItemRecyclingListView::setContainer(container);
@@ -153,7 +153,7 @@ void ItemRecyclingList::themeChange()
item->setBackgroundBrush(Theme::p()->listItemBackgroundBrushEven());
item->setBackgroundOpacity(Theme::p()->listItemBackgroundOpacityEven());
}
-
+
// Update borders
item->setBorderPen(Theme::p()->listItemBorderPen());
item->setRounding(Theme::p()->listItemRounding());
@@ -177,7 +177,7 @@ void ItemRecyclingList::keyPressEvent(QKeyEvent *event)
static qreal step = 0.0;
static bool repeat = false;
int interval = keyPressInterval.elapsed();
-
+
ScrollBar* sb = verticalScrollBar();
qreal currentValue = sb->sliderPosition();
@@ -193,11 +193,11 @@ void ItemRecyclingList::keyPressEvent(QKeyEvent *event)
step = m_listModel->item(0)->size().height();
repeat = false;
}
-
+
if(event->key() == Qt::Key_Up ) { //Up Arrow
sb->setSliderPosition(currentValue - step);
}
-
+
if(event->key() == Qt::Key_Down ) { //Down Arrow
sb->setSliderPosition(currentValue + step);
}
@@ -255,7 +255,7 @@ void ItemRecyclingList::setTwoColumns(const bool enabled)
}
bool ItemRecyclingList::twoColumns()
-{
+{
return m_container->twoColumns();
}
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.h
index f865740632..b86fe345f4 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/itemrecyclinglist.h
@@ -59,7 +59,7 @@ public:
virtual ~ItemRecyclingList();
virtual void insertItem(int index, RecycledListItem *item);
- virtual void addItem(RecycledListItem *item);
+ virtual void addItem(RecycledListItem *item);
virtual void clear();
virtual AbstractViewItem *takeItem(const int row);
virtual void setItemPrototype(AbstractViewItem* prototype);
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/label.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/label.cpp
index bc45f11df0..847b55237d 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/label.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/label.cpp
@@ -43,7 +43,7 @@
#include "label.h"
-Label::Label(const QString& text, QGraphicsItem *parent)
+Label::Label(const QString &text, QGraphicsItem *parent)
: GvbWidget(parent)
{
m_textItem = new QGraphicsSimpleTextItem(this);
@@ -58,8 +58,8 @@ Label::~Label()
{
}
-void Label::setText(const QString& text)
-{
+void Label::setText(const QString &text)
+{
m_textItem->setText(text);
prepareGeometryChange();
}
@@ -74,22 +74,20 @@ void Label::setFont(const QFont font)
m_textItem->setFont(font);
}
-void Label::resizeEvent(QGraphicsSceneResizeEvent *event)
+void Label::resizeEvent(QGraphicsSceneResizeEvent *event)
{
GvbWidget::resizeEvent(event);
}
QSizeF Label::sizeHint(Qt::SizeHint which, const QSizeF &constraint) const
{
- switch (which)
- {
+ switch (which) {
case Qt::MinimumSize:
// fall thru
- case Qt::PreferredSize:
- {
+ case Qt::PreferredSize: {
QFontMetricsF fm(m_textItem->font());
return QSizeF(fm.width(m_textItem->text()), fm.height());
- }
+ }
default:
return GvbWidget::sizeHint(which, constraint);
}
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/label.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/label.h
index e5c83ab3b0..74ffc39d37 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/label.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/label.h
@@ -65,7 +65,7 @@ public:
private:
void resizeEvent(QGraphicsSceneResizeEvent *event);
- QSizeF sizeHint(Qt::SizeHint which,
+ QSizeF sizeHint(Qt::SizeHint which,
const QSizeF &constraint = QSizeF()) const;
private:
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.cpp
index 27ce0a2919..222e4eea50 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitem.cpp
@@ -64,25 +64,25 @@ struct ItemData
Q_DECLARE_METATYPE(ItemData);
ListItem::ListItem(QGraphicsWidget *parent)
- : GvbWidget(parent),
- m_txtlayout(new QGraphicsGridLayout()),
- m_layout(new QGraphicsLinearLayout(Qt::Horizontal)),
- m_liconlayout(new QGraphicsLinearLayout(Qt::Horizontal)),
- m_riconlayout(new QGraphicsLinearLayout(Qt::Horizontal))
- ,m_fonts()
- ,m_borderPen(Qt::NoPen)
- ,m_backgroundBrush(QBrush())
- ,m_backgroundOpacity(1.0)
- ,m_rounding(0.0, 0.0)
-{
+ : GvbWidget(parent)
+ , m_txtlayout(new QGraphicsGridLayout())
+ , m_layout(new QGraphicsLinearLayout(Qt::Horizontal))
+ , m_liconlayout(new QGraphicsLinearLayout(Qt::Horizontal))
+ , m_riconlayout(new QGraphicsLinearLayout(Qt::Horizontal))
+ , m_fonts()
+ , m_borderPen(Qt::NoPen)
+ , m_backgroundBrush(QBrush())
+ , m_backgroundOpacity(1.0)
+ , m_rounding(0.0, 0.0)
+{
setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed);
setContentsMargins(0,4,4,0);
- m_layout->setContentsMargins(0,0,0,0);
+ m_layout->setContentsMargins(0,0,0,0);
m_txtlayout->setContentsMargins(0,8,0,8);
m_liconlayout->setContentsMargins(8,8,8,8);
m_riconlayout->setContentsMargins(0,8,4,8);
-
+
m_layout->insertItem(0, m_liconlayout);
m_layout->insertItem(1, m_txtlayout);
m_layout->insertItem(2, m_riconlayout);
@@ -95,47 +95,44 @@ ListItem::ListItem(QGraphicsWidget *parent)
setLayout(m_layout);
}
-ListItem::~ListItem()
+ListItem::~ListItem()
{
- if ( !m_liconlayout->parentLayoutItem() )
+ if (!m_liconlayout->parentLayoutItem())
delete m_liconlayout;
- if ( !m_riconlayout->parentLayoutItem() )
+ if (!m_riconlayout->parentLayoutItem())
delete m_riconlayout;
}
-void ListItem::setIcon( IconItem *iconItem, const IconItemPos iconPos )
+void ListItem::setIcon(IconItem *iconItem, const IconItemPos iconPos)
{
if (iconPos == LeftIcon) {
if (m_liconlayout->count() > 0 && m_liconlayout->itemAt(0)) {
delete m_liconlayout->itemAt(0);
- m_liconlayout->addItem( iconItem );
+ m_liconlayout->addItem(iconItem);
+ } else {
+ m_liconlayout->addItem(iconItem);
}
- else {
- m_liconlayout->addItem( iconItem );
- }
- m_liconlayout->itemAt(0)->setMaximumSize(58,58);
- }
- else if (iconPos == RightIcon) {
+ m_liconlayout->itemAt(0)->setMaximumSize(58, 58);
+ } else if (iconPos == RightIcon) {
if (m_riconlayout->count() > 0 && m_riconlayout->itemAt(0)) {
delete m_riconlayout->itemAt(0);
- m_riconlayout->addItem( iconItem );
+ m_riconlayout->addItem(iconItem);
+ } else {
+ m_riconlayout->addItem(iconItem);
}
- else {
- m_riconlayout->addItem( iconItem );
- }
- m_riconlayout->itemAt(0)->setMaximumSize(22,22);
+ m_riconlayout->itemAt(0)->setMaximumSize(22, 22);
}
m_layout->invalidate();
}
-IconItem* ListItem::icon( const IconItemPos iconPos ) const
+IconItem* ListItem::icon(const IconItemPos iconPos) const
{
QGraphicsLayoutItem* item = 0;
if (iconPos == LeftIcon && m_liconlayout->count() > 0) {
item = m_liconlayout->itemAt(0);
- }
+ }
else if (iconPos == RightIcon && m_riconlayout->count() > 0) {
item = m_riconlayout->itemAt(0);
}
@@ -203,13 +200,13 @@ void ListItem::setData(const QVariant &value, int role)
ItemData data = value.value<ItemData>();
QList<ListItem::TextPos> textkeys = data.texts.keys();
- for( int i = 0; i<textkeys.count(); ++i) {
- setText(data.texts[textkeys.at(i)],textkeys.at(i));
+ for (int i = 0; i<textkeys.count(); ++i) {
+ setText(data.texts[textkeys.at(i)], textkeys.at(i));
setFont(data.fonts[textkeys.at(i)], textkeys.at(i));
}
QList<ListItem::IconItemPos> iconkeys = data.icons.keys();
- for( int i = 0; i<iconkeys.count(); ++i) {
+ for (int i = 0; i<iconkeys.count(); ++i) {
IconItem *iconItem = icon(iconkeys.at(i));
if (iconItem)
iconItem->setFileName(data.icons[iconkeys.at(i)]);
@@ -249,8 +246,7 @@ void ListItem::setText(const QString str, const TextPos position)
m_txtlayout->addItem(label, position, 0);
if (m_fonts.contains(position))
label->setFont(m_fonts[position]);
- }
- else {
+ } else {
Label *titem = static_cast<Label *>(item);
titem->setText(str);
}
@@ -290,14 +286,12 @@ void ListItem::paint(QPainter *painter, const QStyleOptionGraphicsItem */*option
QRectF r = rect();
r.adjust(penWidth, penWidth, -penWidth, -penWidth);
- if (m_borderPen != Qt::NoPen)
- {
+ if (m_borderPen != Qt::NoPen) {
painter->setPen(m_borderPen);
painter->drawRoundedRect(r, m_rounding.width(), m_rounding.height());
}
- if (m_backgroundBrush != Qt::NoBrush)
- {
+ if (m_backgroundBrush != Qt::NoBrush) {
painter->setPen(Qt::NoPen);
painter->setBrush(m_backgroundBrush);
painter->setOpacity(m_backgroundOpacity);
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.cpp
index 451f1f8031..a1fa8df047 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.cpp
@@ -53,7 +53,7 @@ ListItemCache::~ListItemCache()
QPixmapCache::remove(m_cacheKey);
}
-void ListItemCache::draw(QPainter * painter)
+void ListItemCache::draw(QPainter * painter)
{
QRectF irect = sourceBoundingRect(Qt::LogicalCoordinates);
QRectF vrect = painter->clipPath().boundingRect();
@@ -80,7 +80,7 @@ void ListItemCache::draw(QPainter * painter)
//qDebug() << "ListItemCache: blitting" << m_visibleRect;
painter->drawPixmap(0, 0, pixmap);
- }
+ }
}
void ListItemCache::sourceChanged(ChangeFlags)
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.h
index a7b36c95c6..3e9153ce53 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcache.h
@@ -45,7 +45,7 @@
#include <QGraphicsEffect>
#include <QPixmapCache>
-class ListItemCache : public QGraphicsEffect
+class ListItemCache : public QGraphicsEffect
{
Q_OBJECT
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.cpp
index 0b787f077d..91dba0bc7d 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listitemcontainer.cpp
@@ -56,7 +56,7 @@ ListItemContainer::ListItemContainer(int bufferSize, ItemRecyclingList *view, QG
, m_layout(new QGraphicsLinearLayout(Qt::Vertical))
, m_listItemCaching(false)
{
- setContentsMargins(0,0,0,0);
+ setContentsMargins(0,0,0,0);
m_layout->setContentsMargins(0,0,0,0);
m_layout->setSpacing(0);
setLayout(m_layout);
@@ -80,13 +80,13 @@ bool ListItemContainer::listItemCaching() const
}
void ListItemContainer::setListItemCaching(const bool enabled)
-{
+{
if (m_listItemCaching == enabled)
return;
m_listItemCaching = enabled;
- const int itemCount = m_layout->count();
+ const int itemCount = m_layout->count();
for (int i = 0; i < itemCount; ++i)
setListItemCaching(enabled, i);
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.cpp
index 95eadeece1..f219402aca 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listmodel.cpp
@@ -106,7 +106,7 @@ void ListModel::insert(int row, RecycledListItem *item)
{
if (item)
item->setModel(this);
- if (!item || m_items.contains(item) ) {
+ if (!item || m_items.contains(item) ) {
return;
}
if (row < 0)
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.cpp
index 1cce930d09..1626e1c5d3 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/listwidget.cpp
@@ -47,14 +47,14 @@
ListWidget::ListWidget(QGraphicsWidget * parent)
: GvbWidget(parent),
- m_layout(new QGraphicsLinearLayout(Qt::Vertical)),
+ m_layout(new QGraphicsLinearLayout(Qt::Vertical)),
m_listView(new SimpleListView(this))
-{
+{
//listView->setViewport(listView->content());
//listView->content()->setParentItem(listView);
setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
setContentsMargins(0,0,0,0);
- m_layout->setContentsMargins(0,0,0,0);
+ m_layout->setContentsMargins(0,0,0,0);
m_listView->setContentsMargins(0,0,0,0);
m_layout->addItem(m_listView);
setLayout(m_layout);
@@ -64,7 +64,7 @@ ListWidget::ListWidget(QGraphicsWidget * parent)
m_listView->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
}
-ListWidget::~ListWidget()
+ListWidget::~ListWidget()
{
}
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.cpp
index 57cff5f902..afd8581932 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.cpp
@@ -82,7 +82,7 @@ MainView::~MainView()
}
void MainView::setTestWidget(QGraphicsWidget *testWidget)
-{
+{
if (!testWidget)
return;
@@ -99,7 +99,7 @@ void MainView::setTestWidget(QGraphicsWidget *testWidget)
QGraphicsWidget *MainView::takeTestWidget()
{
if (m_testWidget) {
- m_mainLayout->removeItem(m_testWidget);
+ m_mainLayout->removeItem(m_testWidget);
QGraphicsWidget *tmp = m_testWidget;
m_testWidget = 0;
return tmp;
@@ -229,30 +229,30 @@ void MainView::keyPressEvent(QKeyEvent *event)
else
showFullScreen();
}
-
+
//S60 3.x specific
if(m_menu->menuVisible()) {
m_menu->keyPressEvent(event);
return;
}
-
+
if(event->key() == 16777235 ) { //Up Arrow
GvbWidget* widget = qobject_cast<GvbWidget*>(m_testWidget);
if(widget)
widget->keyPressEvent(event);
}
-
+
if(event->key() == 16777237 ) { //Down Arrow
GvbWidget* widget = qobject_cast<GvbWidget*>(m_testWidget);
if(widget)
widget->keyPressEvent(event);
}
-
+
if(event->key() == 17825792 ) { //LSK
if(!m_menu->menuVisible())
m_menu->menuShowHide();
}
-
+
if(event->key() == 17825793 ) { //RSK
QApplication::quit();
}
@@ -265,7 +265,7 @@ void MainView::construct()
#ifndef QT_NO_OPENGL
if (m_enableOpenGL) {
qDebug() << "OpenGL enabled";
- m_scene->setSortCacheEnabled(false);
+ m_scene->setSortCacheEnabled(false);
setViewport(new QGLWidget);
// Qt doc says: This is the preferred update mode for
@@ -311,7 +311,7 @@ void MainView::construct()
m_mainLayout->addItem(m_topBar);
m_topBar->setZValue(1);
connect(m_topBar, SIGNAL(clicked(bool)), m_menu, SLOT(menuShowHide()));
-
+
setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
setContentsMargins(0,0,0,0);
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.h
index 3a484bd7d1..ee8625edce 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/mainview.h
@@ -57,9 +57,9 @@ class BackgroundItem;
class TopBar;
class MainView : public QGraphicsView {
-
+
Q_OBJECT
-
+
public:
MainView(const bool enableOpenGL, const bool outputFps, const bool imageBasedRendering = false, QWidget *parent = 0);
~MainView();
@@ -94,7 +94,7 @@ private slots:
private:
void construct();
void resizeContent(const QSize &s);
-
+
private:
Q_DISABLE_COPY(MainView)
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.cpp
index f8655bf725..540d7cf31b 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.cpp
@@ -73,14 +73,14 @@ Menu::~Menu()
void Menu::init()
{
m_ButtonContainer = new QList<Button*>;
-
+
m_Layout->setContentsMargins(0,0,0,0);
m_Layout->setSpacing(0);
-
- setMinimumWidth(150);
-
+
+ setMinimumWidth(150);
+
setLayout(m_Layout);
-
+
connect(Theme::p(), SIGNAL(themeChanged()), this, SLOT(themeChange()));
}
@@ -124,9 +124,9 @@ void Menu::menuHide()
void Menu::themeChange()
{
- QPixmap pixmap = Theme::p()->pixmap("status_field_middle.svg",
+ QPixmap pixmap = Theme::p()->pixmap("status_field_middle.svg",
QSize(MinMenuItemWidth, MinMenuItemHeight));
-
+
for(int i = 0; i < m_ButtonContainer->count(); i++) {
Button* button = m_ButtonContainer->at(i);
button->setBackground(pixmap);
@@ -142,7 +142,7 @@ void Menu::keyPressEvent(QKeyEvent *event)
Button* button = m_ButtonContainer->at(m_currentSelectedIndex);
button->select(false);
button->update();
-
+
m_currentSelectedIndex--;
button = m_ButtonContainer->at(m_currentSelectedIndex);
button->select(true);
@@ -162,7 +162,7 @@ void Menu::keyPressEvent(QKeyEvent *event)
}
}
}
-
+
if(event->key() == 16777237 ) { //Down Arrow
if (m_currentSelectedIndex < m_ButtonContainer->count()-1) { //One step down
if(m_currentSelectedIndex >= 0) {
@@ -187,15 +187,15 @@ void Menu::keyPressEvent(QKeyEvent *event)
}
}
}
-
+
if(event->key() == 17825792 || event->key() == 16842752 || //LSK, center key or enter
- event->key() == 16777221 ) {
+ event->key() == 16777221 ) {
if(m_currentSelectedIndex >= 0) {
Button* button = m_ButtonContainer->at(m_currentSelectedIndex);
button->click();
}
}
-
+
if(event->key() == 17825793 ) { //RSK
menuShowHide();
}
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.h
index 84a2e87100..564f6cee53 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/menu.h
@@ -66,12 +66,12 @@ public slots:
public slots:
void menuShowHide();
-
+
private:
void init();
void menuShow();
void menuHide();
-
+
private:
Q_DISABLE_COPY(Menu)
QGraphicsView* m_Parent;
@@ -81,4 +81,4 @@ private:
int m_currentSelectedIndex;
};
-#endif // __MENU_H__
+#endif // __MENU_H__
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.cpp
index 9e487846a0..d73ec2f4ba 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/recycledlistitem.cpp
@@ -57,7 +57,7 @@ RecycledListItem::RecycledListItem(QGraphicsWidget *parent)
{
m_item->setMinimumWidth(MinItemWidth);
setContentsMargins(0,0,0,0);
- setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
+ setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
m_layout->addItem(m_item, 0, 0);
setLayout(m_layout);
m_layout->setContentsMargins(0,0,0,0);
@@ -118,7 +118,7 @@ void RecycledListItem::resizeEvent(QGraphicsSceneResizeEvent *event)
void RecycledListItem::updateItemContents()
{
- AbstractViewItem::updateItemContents();
+ AbstractViewItem::updateItemContents();
if (m_model && m_index.isValid())
setData(m_model->data(m_index,Qt::DisplayRole), Qt::DisplayRole);
}
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/resourcemoninterface.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/resourcemoninterface.h
index cf301e434c..e8dd6292b1 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/resourcemoninterface.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/resourcemoninterface.h
@@ -52,7 +52,7 @@ public:
int availableMemoryInAppThreadHeap;
qint64 availableMemoryInSystem;
qint64 totalMemoryInSystem;
- MemoryAllocation() :
+ MemoryAllocation() :
allocatedInAppThread(0),
numberOfAllocatedCellsInAppThread(0),
availableMemoryInAppThreadHeap(0),
@@ -60,17 +60,17 @@ public:
totalMemoryInSystem(0)
{}
};
-
+
struct CpuUsage
{
qreal systemUsage;
qreal appTreadUsage;
- CpuUsage() :
+ CpuUsage() :
systemUsage(0.0),
appTreadUsage(0.0)
{}
};
-
+
public:
virtual ~ResourceMonitorInterface() {}
@@ -78,17 +78,17 @@ public:
//for symbian, prepares the resource monitor for data capture, opens handle to ekern null
//thread and sets initial values
virtual bool Prepare(QString applicationThreadName) = 0;
-
+
//functions for CPU load and memory - Call Prepare before calling these
virtual CpuUsage CPULoad()=0;
virtual MemoryAllocation MemoryLoad()=0;
-
+
virtual void BeginMeasureMemoryLoad()=0;
virtual MemoryAllocation EndMeasureMemoryLoad()=0;
-
+
virtual void BeginMeasureCPULoad()=0;
virtual CpuUsage EndMeasureCPULoad()=0;
-
+
};
Q_DECLARE_INTERFACE(ResourceMonitorInterface,
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.cpp
index e3c751dbca..2499c7094a 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.cpp
@@ -52,7 +52,7 @@ class ScrollBarPrivate {
public:
- ScrollBarPrivate(Qt::Orientation orientation, ScrollBar *scrollBar)
+ ScrollBarPrivate(Qt::Orientation orientation, ScrollBar *scrollBar)
: orientation(orientation)
, sliderPosition(0.0)
, sliderSize(0.0)
@@ -96,15 +96,15 @@ public:
void updateSlider()
{
QRectF oldSlider = slider;
- slider = q_func()->boundingRect();
-
+ slider = q_func()->boundingRect();
+
qreal x = 0;
qreal y = 0;
qreal w = scrollerPixmap.width();
qreal h = scrollerPixmap.height();
-
+
//Adjust the scrollBar in relation to the scroller
-
+
if (orientation == Qt::Horizontal) {
qreal scrollBarHeight = scrollBarPixmap.height();
@@ -120,7 +120,7 @@ public:
}
slider.setWidth(scrollBarWidth);
}
-
+
if(oldSlider != slider && (slider.size().width() > 0 &&slider.size().height() > 0 )) {
scrollBarPixmap = Theme::p()->pixmap("scrollbar.svg", slider.size().toSize());
}
@@ -153,7 +153,7 @@ public:
ScrollBar::ScrollBar(Qt::Orientation orientation, QGraphicsWidget *parent)
: QGraphicsWidget(parent)
, d_ptr(new ScrollBarPrivate(orientation, this))
-{
+{
setSizePolicy(QSizePolicy::Fixed, QSizePolicy::MinimumExpanding);
setContentsMargins(0, 0, 0, 0);
@@ -198,8 +198,8 @@ bool ScrollBar::sliderDown() const
return d->sliderDown;
}
-void ScrollBar::paint(QPainter *painter,
- const QStyleOptionGraphicsItem *option,
+void ScrollBar::paint(QPainter *painter,
+ const QStyleOptionGraphicsItem *option,
QWidget *widget)
{
Q_D(ScrollBar);
@@ -208,23 +208,23 @@ void ScrollBar::paint(QPainter *painter,
d->updateSlider();
- QRect sliderRect = d->slider.toRect();
+ QRect sliderRect = d->slider.toRect();
painter->drawPixmap(sliderRect.topLeft(), d->scrollBarPixmap);
-
+
QRect cursorRect = d->cursor.toRect();
painter->drawPixmap(cursorRect.topLeft(), d->scrollerPixmap);
}
-QSizeF ScrollBar::sizeHint(Qt::SizeHint which,
- const QSizeF &constraint) const
+QSizeF ScrollBar::sizeHint(Qt::SizeHint which,
+ const QSizeF &constraint) const
{
Q_D(const ScrollBar);
QSizeF s;
- if (d->orientation == Qt::Horizontal)
+ if (d->orientation == Qt::Horizontal)
s = QSizeF(-1, qMax(d->scrollBarPixmap.height(), d->scrollerPixmap.height()));
- else
+ else
s = QSizeF(qMax(d->scrollBarPixmap.width(), d->scrollerPixmap.width()), -1);
switch (which)
@@ -265,18 +265,18 @@ void ScrollBar::mouseMoveEvent(QGraphicsSceneMouseEvent *event)
{
Q_D(ScrollBar);
- if (!d->sliderDown)
+ if (!d->sliderDown)
return;
if (d->orientation == Qt::Horizontal) {
qreal f = (event->pos().x() - d->pressPos.x())/(d->slider.width() - d->cursor.width());
qreal dx = f * d->sliderSize;
-
+
d->setSliderPosition(d->sliderPosition + dx);
} else {
qreal f = (event->pos().y() - d->pressPos.y())/(d->slider.height() - d->cursor.height());
qreal dy = f * d->sliderSize;
-
+
d->setSliderPosition(d->sliderPosition + dy);
}
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.h
index 82e95046b7..9cb15b16c1 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scrollbar.h
@@ -77,11 +77,11 @@ public slots:
private:
- void paint(QPainter *painter,
- const QStyleOptionGraphicsItem *option,
+ void paint(QPainter *painter,
+ const QStyleOptionGraphicsItem *option,
QWidget *widget);
- QSizeF sizeHint(Qt::SizeHint which,
+ QSizeF sizeHint(Qt::SizeHint which,
const QSizeF &constraint = QSizeF()) const;
void mousePressEvent(QGraphicsSceneMouseEvent *event);
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.cpp
index 6fab34ca93..a30e03188f 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/scroller.cpp
@@ -78,7 +78,7 @@ void ScrollerPrivate::stopScrolling()
m_scrollTimer.stop();
}
-//Maps screen coordinates to scrollArea coordinates though current m_eventViewport widget
+//Maps screen coordinates to scrollArea coordinates though current m_eventViewport widget
QPointF ScrollerPrivate::mapToScrollArea(const QPoint &point)
{
if (!m_scrollArea || !m_eventViewport)
@@ -106,7 +106,7 @@ bool ScrollerPrivate::eventFilter(QObject *obj, QEvent *event)
&& event->type() != QEvent::GraphicsSceneKeyReleased*/))
return false;
- QGraphicsSceneMouseEvent* mouseEvent =
+ QGraphicsSceneMouseEvent* mouseEvent =
static_cast<QGraphicsSceneMouseEvent*>(event);
m_eventViewport = mouseEvent->widget();
@@ -130,7 +130,7 @@ bool ScrollerPrivate::eventFilter(QObject *obj, QEvent *event)
m_cursorPos = QCursor::pos();
m_state = ManualScrolling;
- if (!m_scrollTimer.isActive())
+ if (!m_scrollTimer.isActive())
m_scrollTimer.start(UpdateScrollingInterval);
else {
m_scrollTimer.stop();
@@ -154,7 +154,7 @@ bool ScrollerPrivate::eventFilter(QObject *obj, QEvent *event)
ScrollBar *hscroll = m_scrollArea->horizontalScrollBar();
ScrollBar *vscroll = m_scrollArea->verticalScrollBar();
- QPointF d = m_scrollFactor * (mapToScrollArea(QCursor::pos()) - mapToScrollArea(m_cursorPos));
+ QPointF d = m_scrollFactor * (mapToScrollArea(QCursor::pos()) - mapToScrollArea(m_cursorPos));
hscroll->setSliderPosition(hscroll->sliderPosition() - d.x());
vscroll->setSliderPosition(vscroll->sliderPosition() - d.y());
@@ -249,7 +249,7 @@ void ScrollerPrivate::updateScrolling()
hscroll->setSliderPosition(hscroll->sliderPosition() - m_scrollFactor * d.x());
vscroll->setSliderPosition(vscroll->sliderPosition() - m_scrollFactor * d.y());
- } else {
+ } else {
m_state = Stopped;
scrollOngoing = false;
}
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.h
index d84303fd8b..69e300517d 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/settings.h
@@ -76,7 +76,7 @@ public:
int resultFormat() const
{ return m_resultFormat; }
- void setResultFormat(int resultFormat)
+ void setResultFormat(int resultFormat)
{ m_resultFormat = resultFormat; }
const QSize& size() const
@@ -86,7 +86,7 @@ public:
int angle() const
{ return m_angle; }
- void setAngle(int angle)
+ void setAngle(int angle)
{ m_angle = angle; }
const Options& options() const
@@ -106,9 +106,9 @@ private:
QString m_outputFileName;
int m_resultFormat;
QSize m_size;
- int m_angle;
+ int m_angle;
int m_listItemCount;
- Options m_options;
+ Options m_options;
};
Q_DECLARE_OPERATORS_FOR_FLAGS(Settings::Options)
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.cpp
index 4d30286070..cc5df42a66 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelist.cpp
@@ -60,8 +60,8 @@ SimpleList::SimpleList(QGraphicsWidget *parent)
}
/*virtual*/
-SimpleList::~SimpleList()
-{
+SimpleList::~SimpleList()
+{
}
void SimpleList::addItem(ListItem *item)
@@ -116,7 +116,7 @@ void SimpleList::keyPressEvent(QKeyEvent *event)
static qreal step = 0.0;
static bool repeat = false;
int interval = keyPressInterval.elapsed();
-
+
ScrollBar* sb = verticalScrollBar();
qreal currentValue = sb->sliderPosition();
@@ -132,11 +132,11 @@ void SimpleList::keyPressEvent(QKeyEvent *event)
step = itemAt(0)->size().height();
repeat = false;
}
-
+
if(event->key() == Qt::Key_Up ) { //Up Arrow
sb->setSliderPosition(currentValue - step);
}
-
+
if(event->key() == Qt::Key_Down ) { //Down Arrow
sb->setSliderPosition(currentValue + step);
}
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.cpp
index 7bfda5173f..c59bd378e1 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.cpp
@@ -55,7 +55,7 @@ class SimpleListViewPrivate
public:
- SimpleListViewPrivate(SimpleListView *button)
+ SimpleListViewPrivate(SimpleListView *button)
: m_content(0)
, m_layout(0)
, m_twoColumns(false)
@@ -100,7 +100,7 @@ public:
m_content->resize(q->viewport()->size().width(),
m_layout->preferredHeight());
- const bool clip =
+ const bool clip =
m_content->size().width() > q->viewport()->size().width()
|| m_content->size().height() > q->viewport()->size().height();
@@ -161,7 +161,7 @@ public:
const QString defaultIcon = Theme::p()->pixmapPath()+"contact_default_icon.svg";
const int itemCount = m_layout->count();
-
+
for (int i=0; i<itemCount; ++i) {
ListItem* item = static_cast<ListItem*>(m_layout->itemAt(i));
@@ -251,7 +251,7 @@ public:
QGraphicsLayoutItem *item = m_layout->itemAt(i);
m_layout->removeAt(i);
moveditems.append(item);
- }
+ }
for ( int i = 0; i < moveditems.count(); ++i)
m_layout->addItem(moveditems.at(i), i, 1);
@@ -267,7 +267,7 @@ public:
moveditems.append(m_layout->itemAt(i));
else
moveditems.insert(moveditems.begin(), m_layout->itemAt(i));
- m_layout->removeAt(i);
+ m_layout->removeAt(i);
}
for (int i = 0; i<moveditems.count(); ++i) {
m_layout->addItem(moveditems.at(i), m_layout->count(), 0);
@@ -292,17 +292,17 @@ public:
bool m_listItemCaching;
};
-SimpleListView::SimpleListView(QGraphicsWidget *parent)
+SimpleListView::SimpleListView(QGraphicsWidget *parent)
: AbstractScrollArea(parent)
, d_ptr(new SimpleListViewPrivate(this))
-{
+{
setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
setContentsMargins(0, 0, 0, 0);
verticalScrollBar()->hide();
horizontalScrollBar()->hide();
}
-SimpleListView::~SimpleListView()
+SimpleListView::~SimpleListView()
{
Q_D(SimpleListView);
@@ -403,7 +403,7 @@ bool SimpleListView::listItemCaching() const
void SimpleListView::setListItemCaching(bool enabled)
{
Q_D(SimpleListView);
-
+
if (d->m_listItemCaching == enabled)
return;
@@ -430,13 +430,13 @@ void SimpleListView::scrollContentsBy(qreal dx, qreal dy)
if (newy < miny)
newy = miny;
- else if (newy > 0)
+ else if (newy > 0)
newy = 0.0;
d->m_content->setPos(contentPos.x(), newy);
}
-void SimpleListView::resizeEvent(QGraphicsSceneResizeEvent *event)
+void SimpleListView::resizeEvent(QGraphicsSceneResizeEvent *event)
{
Q_D(SimpleListView);
@@ -446,7 +446,7 @@ void SimpleListView::resizeEvent(QGraphicsSceneResizeEvent *event)
}
QSizeF SimpleListView::sizeHint(Qt::SizeHint which, const QSizeF & constraint) const
-{
+{
Q_D(const SimpleListView);
if (which == Qt::PreferredSize)
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.h
index 57ec90e717..fcc6805a2f 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/simplelistview.h
@@ -79,7 +79,7 @@ protected:
virtual void scrollContentsBy(qreal dx, qreal dy);
void resizeEvent(QGraphicsSceneResizeEvent *event);
- QSizeF sizeHint(Qt::SizeHint which,
+ QSizeF sizeHint(Qt::SizeHint which,
const QSizeF & constraint) const;
private:
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.cpp
index 136c7ed5ff..4983c574e1 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.cpp
@@ -44,10 +44,10 @@
ThemeEvent::ThemeEvent( const QString &newTheme, Type type) : QEvent(type),
m_theme(newTheme)
{
-
+
}
ThemeEvent::~ThemeEvent()
{
-
+
}
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.h
index eb94123b54..e48fb5f273 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/themeevent.h
@@ -55,7 +55,7 @@ public:
public:
inline QString getTheme() { return m_theme; }
-
+
private:
QString m_theme;
};
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.cpp
index a7a4ad3a3f..9ff6d6d2f1 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.cpp
@@ -55,7 +55,7 @@ TopBar::TopBar(QGraphicsView* mainView, QGraphicsWidget* parent) :
m_orientation(TopBar::None), m_topBarPixmap(), m_sizesBlue(), m_sizesLime()
{
setDefaultSizes();
-
+
m_titleFont = Theme::p()->font(Theme::TitleBar);
m_statusFont = Theme::p()->font(Theme::StatusBar);
@@ -71,7 +71,7 @@ void TopBar::resizeEvent(QGraphicsSceneResizeEvent* /*event*/)
//Check orientation
QString topbarName;
QSize mainViewSize = m_mainView->size();
- int rotationAngle = static_cast<MainView*>(m_mainView)->rotationAngle();
+ int rotationAngle = static_cast<MainView*>(m_mainView)->rotationAngle();
if(rotationAngle == 90 || rotationAngle == 270 ) {
int wd = mainViewSize.width();
int ht = mainViewSize.height();
@@ -91,49 +91,49 @@ void TopBar::resizeEvent(QGraphicsSceneResizeEvent* /*event*/)
m_orientation = TopBar::Landscape;
topbarName = "topbar_horisontal.svg";
}
-
+
//Calculate new size, resize by height, don't make it wider than the screen
- QHash<QString, QSize>sizes = (Theme::p()->theme() == Theme::Blue) ?
+ QHash<QString, QSize>sizes = (Theme::p()->theme() == Theme::Blue) ?
m_sizesBlue : m_sizesLime;
-
+
//Get current size for topbarpixmap
- QSize currentSize = !m_topBarPixmap.isNull() && !m_orientationChanged ?
+ QSize currentSize = !m_topBarPixmap.isNull() && !m_orientationChanged ?
m_topBarPixmap.size() : sizes[topbarName];
QSize newSize = !m_orientationChanged ? QSize(currentSize) : sizes[topbarName];
-
+
//Scale according to aspect ratio
newSize.scale(size().toSize(), Qt::KeepAspectRatio);
-
+
//fix width to window widht if previous scaling produced too narrow image
if(newSize.width() < size().width()) {
newSize.scale(size().toSize(), Qt::KeepAspectRatioByExpanding);
}
-
+
//Calculate scaling factor for rest of the graphics scaling
qreal scaleFactor = (newSize.width() *1.0) / (currentSize.width() * 1.0);
-
+
//Scale graphics, if the scalefactor applies
//This is really heavy since the SVG graphics are read again from the resource
if(scaleFactor != 1 || m_topBarPixmap.isNull() ) {
m_topBarPixmap = Theme::p()->pixmap(topbarName, newSize );
- m_topBarUserIcon = Theme::p()->pixmap("user_default_icon.svg",
+ m_topBarUserIcon = Theme::p()->pixmap("user_default_icon.svg",
!m_topBarUserIcon.isNull() && !m_orientationChanged ? m_topBarUserIcon.size()* scaleFactor : sizes["user_default_icon.svg"] * scaleFactor);
-
- m_topBarUserStatus = Theme::p()->pixmap("user_status_online.svg",
+
+ m_topBarUserStatus = Theme::p()->pixmap("user_status_online.svg",
!m_topBarUserStatus.isNull() && !m_orientationChanged ? m_topBarUserStatus.size() * scaleFactor : sizes["user_status_online.svg"] * scaleFactor);
-
- m_topBarStatusBarLeft = Theme::p()->pixmap("status_field_left.svg",
+
+ m_topBarStatusBarLeft = Theme::p()->pixmap("status_field_left.svg",
!m_topBarStatusBarLeft.isNull() && !m_orientationChanged ? m_topBarStatusBarLeft.size()* scaleFactor : sizes["status_field_left.svg"] * scaleFactor);
-
+
m_topBarStatusBarRight = Theme::p()->pixmap("status_field_right.svg",
!m_topBarStatusBarRight.isNull() && !m_orientationChanged ? m_topBarStatusBarRight.size()* scaleFactor : sizes["status_field_right.svg"] * scaleFactor);
-
+
m_topBarStatusBarMiddle = Theme::p()->pixmap("status_field_middle.svg",
!m_topBarStatusBarMiddle.isNull() && !m_orientationChanged ? m_topBarStatusBarMiddle.size() * scaleFactor : QSize(185, sizes["status_field_middle.svg"].height()) * scaleFactor);
-
+
//Update the sizeHint to match the size of the scaled m_topBarPixmap
updateGeometry();
-
+
//Point Update - Positions relative to the Top Bar "Backgroud" size.
//TODO: consider some layout instead of calculating relative locations
QSize topBarPixmapSize = m_topBarPixmap.size();
@@ -141,40 +141,40 @@ void TopBar::resizeEvent(QGraphicsSceneResizeEvent* /*event*/)
QSize topBarUserStatusSize = m_topBarUserStatus.size();
QSize topBarStatusBarLeftSize = m_topBarStatusBarLeft.size();
QSize topBarStatusBarMiddleSize = m_topBarStatusBarMiddle.size();
-
+
//Location for Title text 5% width, 35% height of the background pixmap
- m_topBarTitlePoint = QPoint(topBarPixmapSize.width()* 0.05,
+ m_topBarTitlePoint = QPoint(topBarPixmapSize.width()* 0.05,
topBarPixmapSize.height() * 0.35);
-
+
//User Icon location
//Placing 70% of the width and 10% of the height of the top bar background
m_topBarUserIconPoint = QPoint((topBarPixmapSize.width() * 0.7), (topBarPixmapSize.height() * 0.1));
-
+
//If Blue theme is in use - position user status icon on the right side of the user icon
if(!m_isLimeTheme) {
//Place the status icon on top of the right edge of the user icon, lower it by 35% of the height of the user icon
- m_topBarUserStatusPoint = QPoint( ( (m_topBarUserIconPoint.x()+topBarUserIconSize.width() ) -
- ( topBarUserStatusSize.width()/2 )),
+ m_topBarUserStatusPoint = QPoint( ( (m_topBarUserIconPoint.x()+topBarUserIconSize.width() ) -
+ ( topBarUserStatusSize.width()/2 )),
(m_topBarUserIconPoint.y() + (topBarUserIconSize.height() * 0.35 )));
}
//If Lime theme is in use - position user status icon on the left side of the user icon
else {
//Place the status icon on top of the left side of the user icon, lower it by 50% of the height of the user icon
//and move left by 5% of the icon
- m_topBarUserStatusPoint = QPoint( m_topBarUserIconPoint.x() + ( topBarUserIconSize.width() * 0.05),
+ m_topBarUserStatusPoint = QPoint( m_topBarUserIconPoint.x() + ( topBarUserIconSize.width() * 0.05),
(m_topBarUserIconPoint.y() + (topBarUserIconSize.height() * 0.5 )));
}
-
+
//Status bar
//Placing the left side of the status bar 5% of the width, 50% of the height of the top bar background
//Set the text baseline 80% of the height of the status bar
- m_topBarStatusBarLeftPoint = QPoint( (topBarPixmapSize.width()* 0.05),
+ m_topBarStatusBarLeftPoint = QPoint( (topBarPixmapSize.width()* 0.05),
(topBarPixmapSize.height() * 0.5));
- m_topBarStatusBarMiddlePoint = QPoint( (m_topBarStatusBarLeftPoint.x() + topBarStatusBarLeftSize.width()),
+ m_topBarStatusBarMiddlePoint = QPoint( (m_topBarStatusBarLeftPoint.x() + topBarStatusBarLeftSize.width()),
(m_topBarStatusBarLeftPoint.y()));
- m_topBarStatusBarRightPoint = QPoint( (m_topBarStatusBarMiddlePoint.x() + topBarStatusBarMiddleSize.width()),
+ m_topBarStatusBarRightPoint = QPoint( (m_topBarStatusBarMiddlePoint.x() + topBarStatusBarMiddleSize.width()),
(m_topBarStatusBarMiddlePoint.y() ) );
- m_topBarStatusBarTextPoint = QPoint(m_topBarStatusBarMiddlePoint.x(),
+ m_topBarStatusBarTextPoint = QPoint(m_topBarStatusBarMiddlePoint.x(),
m_topBarStatusBarMiddlePoint.y() + (topBarStatusBarMiddleSize.height()*0.8) );
} //if scalefactor
}
@@ -183,18 +183,18 @@ void TopBar::paint( QPainter *painter, const QStyleOptionGraphicsItem *option, Q
{
//Topbar background
painter->drawPixmap(option->exposedRect, m_topBarPixmap, option->exposedRect);
-
+
//User Icon
painter->drawPixmap(m_topBarUserIconPoint, m_topBarUserIcon);
-
+
//User Status
painter->drawPixmap(m_topBarUserStatusPoint, m_topBarUserStatus);
-
+
//Status bar
painter->drawPixmap(m_topBarStatusBarLeftPoint, m_topBarStatusBarLeft);
painter->drawPixmap(m_topBarStatusBarMiddlePoint, m_topBarStatusBarMiddle);
painter->drawPixmap(m_topBarStatusBarRightPoint, m_topBarStatusBarRight);
-
+
//Title text
painter->save();
painter->setFont(m_titleFont);
@@ -210,14 +210,14 @@ void TopBar::paint( QPainter *painter, const QStyleOptionGraphicsItem *option, Q
QRectF TopBar::boundingRect() const
{
- //It's possible that m_topBarPixmap is not allocated yet,
+ //It's possible that m_topBarPixmap is not allocated yet,
//in this case default size is used for setting boundingRect
- QHash<QString, QSize>sizes = (Theme::p()->theme() == Theme::Blue) ?
- m_sizesBlue : m_sizesLime;
-
- if(!m_topBarPixmap.isNull())
+ QHash<QString, QSize>sizes = (Theme::p()->theme() == Theme::Blue) ?
+ m_sizesBlue : m_sizesLime;
+
+ if (!m_topBarPixmap.isNull())
return QRectF(0, 0, m_topBarPixmap.size().width(), m_topBarPixmap.size().height());
- else
+ else
return QRectF(0, 0, sizes["topbar.svg"].width(), sizes["topbar.svg"].height());
}
@@ -227,95 +227,95 @@ void TopBar::themeChange()
m_statusFont = Theme::p()->font(Theme::StatusBar);
//Calculate the scaling factor
- QHash<QString, QSize>sizes = (Theme::p()->theme() == Theme::Blue) ?
+ QHash<QString, QSize>sizes = (Theme::p()->theme() == Theme::Blue) ?
m_sizesBlue : m_sizesLime;
-
- QString topbarString= m_orientation == TopBar::Portrait ?
+
+ QString topbarString= m_orientation == TopBar::Portrait ?
"topbar.svg" : "topbar_horisontal.svg";
-
+
QSize topBarSize = sizes[topbarString];
QSize newSize = QSize(topBarSize);
-
+
//Scale according to aspect ratio
newSize.scale(size().toSize(), Qt::KeepAspectRatio);
-
+
//fix width to window widht if previous scaling produced too narrow image
if(newSize.width() < size().width()) {
newSize.scale(size().toSize(), Qt::KeepAspectRatioByExpanding);
}
-
+
//Calculate scaling factor for rest of the graphics scaling
qreal scaleFactor = (newSize.width() *1.0) / (topBarSize.width() * 1.0);
//Background
m_topBarPixmap = Theme::p()->pixmap(topbarString, sizes[topbarString] * scaleFactor);
-
+
//User Icon
m_topBarUserIcon = Theme::p()->pixmap("user_default_icon.svg", sizes["user_default_icon.svg"] * scaleFactor);
-
+
//User Status
- m_topBarUserStatus = Theme::p()->pixmap("user_status_online.svg", sizes["user_status_online.svg"] * scaleFactor);
-
- //Status Bar
+ m_topBarUserStatus = Theme::p()->pixmap("user_status_online.svg", sizes["user_status_online.svg"] * scaleFactor);
+
+ //Status Bar
m_topBarStatusBarLeft = Theme::p()->pixmap("status_field_left.svg", sizes["status_field_left.svg"] * scaleFactor);
m_topBarStatusBarRight = Theme::p()->pixmap("status_field_right.svg", sizes["status_field_right.svg"] * scaleFactor);
- m_topBarStatusBarMiddle = Theme::p()->pixmap("status_field_middle.svg",
+ m_topBarStatusBarMiddle = Theme::p()->pixmap("status_field_middle.svg",
QSize(185, sizes["status_field_middle.svg"].height())* scaleFactor);
-
+
//Update Drawing points for Top Bar elements, points are relative to the top bar background size
QSize topBarPixmapSize = m_topBarPixmap.size();
QSize topBarUserIconSize = m_topBarUserIcon.size();
QSize topBarUserStatusSize = m_topBarUserStatus.size();
QSize topBarStatusBarLeftSize = m_topBarStatusBarLeft.size();
- QSize topBarStatusBarMiddleSize = m_topBarStatusBarMiddle.size();
-
+ QSize topBarStatusBarMiddleSize = m_topBarStatusBarMiddle.size();
+
//Theme Check
(Theme::p()->theme() == Theme::Lime) ? m_isLimeTheme = true : m_isLimeTheme = false;
-
+
//User Icon location
//Placing 70% of the width and 10% of the height of the top bar background
m_topBarUserIconPoint = QPoint((0.7*topBarPixmapSize.width()), (0.1*topBarPixmapSize.height()));
-
+
//If Blue theme is in use - position user status icon on the right side of the user icon
if(!m_isLimeTheme) {
//Place the status icon on top of the right edge of the user icon, lower it by 35% of the height of the user icon
- m_topBarUserStatusPoint = QPoint( ( (m_topBarUserIconPoint.x()+topBarUserIconSize.width() ) - ( topBarUserStatusSize.width()/2 )),
+ m_topBarUserStatusPoint = QPoint( ( (m_topBarUserIconPoint.x()+topBarUserIconSize.width() ) - ( topBarUserStatusSize.width()/2 )),
(m_topBarUserIconPoint.y() + (topBarUserIconSize.height() * 0.35 )));
}
//If Lime theme is in use - position user status icon on the left side of the user icon
else {
//Place the status icon on top of the left side of the user icon, lower it by 50% of the height of the user icon
//and move left by 5% of the icon
- m_topBarUserStatusPoint = QPoint( m_topBarUserIconPoint.x() + ( topBarUserIconSize.width() * 0.05),
+ m_topBarUserStatusPoint = QPoint( m_topBarUserIconPoint.x() + ( topBarUserIconSize.width() * 0.05),
(m_topBarUserIconPoint.y() + (topBarUserIconSize.height() * 0.5 )));
}
-
+
//Status bar
//Placing the left side of the status bar 5% of the width, 50% of the height of the top bar background
//Set the text baseline 80% of the height of the status bar
- m_topBarStatusBarLeftPoint = QPoint( (topBarPixmapSize.width()* 0.05),
+ m_topBarStatusBarLeftPoint = QPoint( (topBarPixmapSize.width()* 0.05),
(topBarPixmapSize.height() * 0.5));
- m_topBarStatusBarMiddlePoint = QPoint( (m_topBarStatusBarLeftPoint.x() + topBarStatusBarLeftSize.width()),
+ m_topBarStatusBarMiddlePoint = QPoint( (m_topBarStatusBarLeftPoint.x() + topBarStatusBarLeftSize.width()),
(m_topBarStatusBarLeftPoint.y()));
- m_topBarStatusBarRightPoint = QPoint( (m_topBarStatusBarMiddlePoint.x() + topBarStatusBarMiddleSize.width()),
+ m_topBarStatusBarRightPoint = QPoint( (m_topBarStatusBarMiddlePoint.x() + topBarStatusBarMiddleSize.width()),
(m_topBarStatusBarMiddlePoint.y() ) );
- m_topBarStatusBarTextPoint = QPoint(m_topBarStatusBarMiddlePoint.x(),
+ m_topBarStatusBarTextPoint = QPoint(m_topBarStatusBarMiddlePoint.x(),
m_topBarStatusBarMiddlePoint.y() + (topBarStatusBarMiddleSize.height()*0.8) );
-
+
update();
}
-QSizeF TopBar::sizeHint(Qt::SizeHint which,
- const QSizeF &constraint) const
+QSizeF TopBar::sizeHint(Qt::SizeHint which,
+ const QSizeF &constraint) const
{
- //It's possible that m_topBarPixmap is not allocated yet,
+ //It's possible that m_topBarPixmap is not allocated yet,
//in this case default size is used for setting size hint
- QHash<QString, QSize>sizes = (Theme::p()->theme() == Theme::Blue) ?
- m_sizesBlue : m_sizesLime;
-
- int height = !m_topBarPixmap.isNull() ?
- m_topBarPixmap.height() : sizes["topbar.svg"].height();
-
+ QHash<QString, QSize>sizes = (Theme::p()->theme() == Theme::Blue) ?
+ m_sizesBlue : m_sizesLime;
+
+ int height = !m_topBarPixmap.isNull() ?
+ m_topBarPixmap.height() : sizes["topbar.svg"].height();
+
switch (which)
{
case Qt::MinimumSize:
@@ -330,7 +330,7 @@ QSizeF TopBar::sizeHint(Qt::SizeHint which,
}
void TopBar::setDefaultSizes()
-{
+{
m_sizesBlue["topbar.svg"] = QSize(356,96);
m_sizesBlue["topbar_horisontal.svg"] = QSize(636,96);
m_sizesBlue["user_default_icon.svg"] = QSize(68,68);
@@ -338,7 +338,7 @@ void TopBar::setDefaultSizes()
m_sizesBlue["status_field_left.svg"] = QSize(14,24);
m_sizesBlue["status_field_right.svg"] = QSize(10,24);
m_sizesBlue["status_field_middle.svg"] = QSize(14,24);
-
+
m_sizesLime["topbar.svg"] = QSize(356,96);
m_sizesLime["topbar_horisontal.svg"] = QSize(636,96);
m_sizesLime["user_default_icon.svg"] = QSize(84,68);
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.h
index dabffa9d06..808064d04d 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/topbar.h
@@ -55,7 +55,7 @@ class QFont;
class TopBar : public GvbWidget
{
Q_OBJECT
-
+
public:
enum Orientation
{
@@ -63,33 +63,34 @@ public:
Landscape,
None
};
-
+
public:
TopBar(QGraphicsView* mainView, QGraphicsWidget* parent);
~TopBar();
-
+
public:
void paint( QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0 );
QRectF boundingRect() const;
void resizeEvent(QGraphicsSceneResizeEvent *event);
- inline QPoint getStatusBarLocation() { return m_topBarStatusBarMiddlePoint +
- m_topBarStatusBarMiddle.rect().bottomLeft(); }
-
+ inline QPoint getStatusBarLocation()
+ {
+ return m_topBarStatusBarMiddlePoint + m_topBarStatusBarMiddle.rect().bottomLeft();
+ }
+
public slots:
void themeChange();
-
+
protected:
void mousePressEvent(QGraphicsSceneMouseEvent *event);
-
+
signals:
void clicked(bool checked = false);
-
+
private:
- QSizeF sizeHint(Qt::SizeHint which,
+ QSizeF sizeHint(Qt::SizeHint which,
const QSizeF &constraint = QSizeF()) const;
void setDefaultSizes();
-
-
+
private:
Q_DISABLE_COPY(TopBar)
@@ -100,7 +101,7 @@ private:
//Fonts
QFont m_titleFont;
QFont m_statusFont;
-
+
//Pixmaps
QPixmap m_topBarPixmap;
QPixmap m_topBarUserIcon;
@@ -108,7 +109,7 @@ private:
QPixmap m_topBarStatusBarLeft;
QPixmap m_topBarStatusBarRight;
QPixmap m_topBarStatusBarMiddle;
-
+
//Drawing points
QPoint m_topBarUserIconPoint;
QPoint m_topBarUserStatusPoint;
@@ -117,7 +118,7 @@ private:
QPoint m_topBarStatusBarMiddlePoint;
QPoint m_topBarStatusBarTextPoint;
QPoint m_topBarTitlePoint;
-
+
//Sizes
QHash<QString, QSize> m_sizesBlue;
QHash<QString, QSize> m_sizesLime;
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.cpp b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.cpp
index 0883580d70..4fee19230d 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.cpp
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/webview.cpp
@@ -46,7 +46,7 @@
static const int MotionEndWaitTime = 2000;
static const int TileSideLength = 128;
-WebViewPrivate::WebViewPrivate(WebView *w)
+WebViewPrivate::WebViewPrivate(WebView *w)
: q(w)
, cache(0)
{
@@ -56,14 +56,14 @@ WebViewPrivate::WebViewPrivate(WebView *w)
web->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
web->page()->mainFrame()->setScrollBarPolicy(
- Qt::Horizontal, Qt::ScrollBarAlwaysOff);
+ Qt::Horizontal, Qt::ScrollBarAlwaysOff);
web->page()->mainFrame()->setScrollBarPolicy(
Qt::Vertical, Qt::ScrollBarAlwaysOff);
web->setZValue(3);
// cache = new WebViewCache(web);
// web->setGraphicsEffect(cache);
-
+
adjustSize();
}
@@ -85,9 +85,8 @@ void WebViewPrivate::adjustSize()
q->horizontalScrollBar()->setSliderSize(w);
else
q->horizontalScrollBar()->setSliderSize(0.0);
-
- if (h > q->viewport()->boundingRect().height())
+ if (h > q->viewport()->boundingRect().height())
q->verticalScrollBar()->setSliderSize(h);
else
q->verticalScrollBar()->setSliderSize(0.0);
@@ -116,7 +115,7 @@ void WebViewPrivate::_q_loadFinished(bool ok)
void WebViewPrivate::_q_viewportChanged(QGraphicsWidget* viewport)
{
web->setParentItem(viewport);
- viewport->setFlag(QGraphicsItem::ItemClipsChildrenToShape,
+ viewport->setFlag(QGraphicsItem::ItemClipsChildrenToShape,
true);
adjustSize();
}
@@ -131,7 +130,6 @@ void WebViewPrivate::_q_motionEnded()
WebViewCache::WebViewCache(QGraphicsWebView *webView)
: m_webView(webView)
{
-
}
WebViewCache::~WebViewCache()
@@ -178,8 +176,8 @@ void WebViewCache::draw(QPainter * painter, QGraphicsEffectSource * source)
for (int j = 0; j < tilesY; j++) {
int x = i * TileSideLength;
int y = j * TileSideLength;
-
- m_tileRects[i + j * tilesX]
+
+ m_tileRects[i + j * tilesX]
= QRectF(x, y, TileSideLength, TileSideLength);
}
}
@@ -205,13 +203,13 @@ void WebViewCache::draw(QPainter * painter, QGraphicsEffectSource * source)
QWebFrame *webFrame = m_webView->page()->mainFrame();
- QPainter tilePainter(&tilePixmap);
+ QPainter tilePainter(&tilePixmap);
tilePainter.translate(-m_tileRects[i].left(), -m_tileRects[i].top());
webFrame->render(&tilePainter, m_tileRects[i].toRect());
tilePainter.end();
m_tilePixmaps[i] = QPixmapCache::insert(tilePixmap);
- }
+ }
tileRect = tileRect.translated(-itemPos);
@@ -233,7 +231,7 @@ WebView::WebView(QGraphicsWidget *parent)
this, SLOT(_q_loadFinished(bool)));
connect(this, SIGNAL(viewportChanged(QGraphicsWidget*)),
this, SLOT(_q_viewportChanged(QGraphicsWidget*)));
- connect(&d->motionTimer, SIGNAL(timeout()),
+ connect(&d->motionTimer, SIGNAL(timeout()),
this, SLOT(_q_motionEnded()));
}
@@ -272,21 +270,21 @@ void WebView::scrollContentsBy(qreal dx, qreal dy)
if (x < minx)
x = minx;
- else if (x > 0)
+ else if (x > 0)
x = 0.0;
qreal y = d->web->pos().y() - dy;
if (y < miny)
y = miny;
- else if (y > 0)
+ else if (y > 0)
y = 0.0;
d->web->setPos(x, y);
}
QSizeF WebView::sizeHint(Qt::SizeHint which, const QSizeF & constraint) const
-{
+{
if (which == Qt::PreferredSize) {
QSizeF contentSize = d->web->page()->mainFrame()->contentsSize();
return contentSize;
diff --git a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/webview_p.h b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/webview_p.h
index ded7df7f60..a1391cc125 100644
--- a/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/webview_p.h
+++ b/tests/benchmarks/gui/graphicsview/functional/GraphicsViewBenchmark/widgets/webview_p.h
@@ -71,7 +71,7 @@ public:
QTimer motionTimer;
};
-class WebViewCache : public QGraphicsEffect
+class WebViewCache : public QGraphicsEffect
{
Q_OBJECT
diff --git a/tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/main.cpp b/tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/main.cpp
index 7394a9410e..e8b6388941 100644
--- a/tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/main.cpp
+++ b/tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/main.cpp
@@ -51,7 +51,7 @@ int main(int argc, char **argv)
app.setAttribute(Qt::AA_DontCreateNativeWidgetSiblings);
MainWindow window;
- window.show();
+ window.show();
return app.exec();
}
diff --git a/tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.h b/tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.h
index ed3d74919d..74c1fedfac 100644
--- a/tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.h
+++ b/tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/mainwindow.h
@@ -55,7 +55,7 @@ class MainWindow : public QWidget
Q_OBJECT
public:
MainWindow(QWidget *parent = 0);
-
+
private:
void setupMatrix();
void populateScene();
diff --git a/tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/view.h b/tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/view.h
index 3fac23ede0..db2f219222 100644
--- a/tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/view.h
+++ b/tests/benchmarks/gui/graphicsview/qgraphicsview/benchapps/chipTest/view.h
@@ -71,7 +71,7 @@ private slots:
void rotateRight();
void timerEvent(QTimerEvent *);
-
+
private:
QGraphicsView *graphicsView;
QLabel *label;
diff --git a/tests/benchmarks/gui/graphicsview/qgraphicsview/chiptester/chiptester.h b/tests/benchmarks/gui/graphicsview/qgraphicsview/chiptester/chiptester.h
index 711eb833f6..4e5b436f8d 100644
--- a/tests/benchmarks/gui/graphicsview/qgraphicsview/chiptester/chiptester.h
+++ b/tests/benchmarks/gui/graphicsview/qgraphicsview/chiptester/chiptester.h
@@ -62,7 +62,7 @@ public:
Translate
};
ChipTester(QWidget *parent = 0);
-
+
void setAntialias(bool enabled);
void setOpenGL(bool enabled);
void runBenchmark();
@@ -75,7 +75,7 @@ protected:
private:
void populateScene();
- QGraphicsView *view;
+ QGraphicsView *view;
QGraphicsScene *scene;
int npaints;
int timerId;
diff --git a/tests/benchmarks/gui/image/blendbench/main.cpp b/tests/benchmarks/gui/image/blendbench/main.cpp
index 1d8aa60394..3e912e83b3 100644
--- a/tests/benchmarks/gui/image/blendbench/main.cpp
+++ b/tests/benchmarks/gui/image/blendbench/main.cpp
@@ -100,7 +100,7 @@ QLatin1String brushTypes[] = {
class BlendBench : public QObject
{
Q_OBJECT
-private slots:
+private slots:
void blendBench_data();
void blendBench();
diff --git a/tests/benchmarks/gui/image/image.pro b/tests/benchmarks/gui/image/image.pro
index 2d5db35a73..71228f4499 100644
--- a/tests/benchmarks/gui/image/image.pro
+++ b/tests/benchmarks/gui/image/image.pro
@@ -6,5 +6,5 @@ SUBDIRS = \
qpixmap \
qpixmapcache
-!qtHaveModule(widgets): SUBDIRS -= \
+!qtHaveModule(widgets)|!qtHaveModule(network): SUBDIRS -= \
qimagereader
diff --git a/tests/benchmarks/gui/image/qimagereader/images/black.xpm b/tests/benchmarks/gui/image/qimagereader/images/black.xpm
index d7925bf211..4a1f4ec861 100644
--- a/tests/benchmarks/gui/image/qimagereader/images/black.xpm
+++ b/tests/benchmarks/gui/image/qimagereader/images/black.xpm
@@ -15,21 +15,21 @@ static char * ddd_xpm[] = {
"+ c white m white g white g4 white s Light ",
"* c DarkGreen m black g grey25 g4 grey25 s Eye ",
/* Pixels */
-" . . ",
-" . .. ",
-" . . ",
-" .. . ",
-" .. .. .. ",
-" .. . . . ",
-" . . . . .. ",
-" . .X. . ",
-" . *.X.* .. ",
-" .. .. .XXX. .. ... ",
-" . .X...XXX...X. . ",
-" .. ..XXX.XXX.XXX. .. ",
-" .....XXXX...XXXX. . ",
-" .. ..XXXXXXXXX.. .. ",
-" ...XXXXXXX..... ",
+" . . ",
+" . .. ",
+" . . ",
+" .. . ",
+" .. .. .. ",
+" .. . . . ",
+" . . . . .. ",
+" . .X. . ",
+" . *.X.* .. ",
+" .. .. .XXX. .. ... ",
+" . .X...XXX...X. . ",
+" .. ..XXX.XXX.XXX. .. ",
+" .....XXXX...XXXX. . ",
+" .. ..XXXXXXXXX.. .. ",
+" ...XXXXXXX..... ",
" ......... ",
" .XXXXXXX. ",
" .....XXX..... ",
diff --git a/tests/benchmarks/gui/itemviews/qtableview/tst_qtableview.cpp b/tests/benchmarks/gui/itemviews/qtableview/tst_qtableview.cpp
index 07ee8b7804..c32ff0d099 100644
--- a/tests/benchmarks/gui/itemviews/qtableview/tst_qtableview.cpp
+++ b/tests/benchmarks/gui/itemviews/qtableview/tst_qtableview.cpp
@@ -174,7 +174,7 @@ void tst_QTableView::spanInit_helper(QTableView *view)
for (int i=0; i < 40; i++) {
view->setSpan(1+i%2, 1+4*i, 1+i%3, 2);
}
-
+
for (int i=1; i < 40; i++) {
view->setSpan(6 + i*7, 4, 4, 50);
}
@@ -185,7 +185,7 @@ void tst_QTableView::spanInit()
QtTestTableModel model(500, 500);
QTableView v;
v.setModel(&model);
-
+
QBENCHMARK {
spanInit_helper(&v);
}
@@ -196,7 +196,7 @@ void tst_QTableView::spanDraw()
QtTestTableModel model(500, 500);
QTableView v;
v.setModel(&model);
-
+
spanInit_helper(&v);
v.show();
v.resize(500,500);
@@ -214,11 +214,11 @@ void tst_QTableView::spanSelectAll()
QtTestTableModel model(500, 500);
QTableView v;
v.setModel(&model);
-
+
spanInit_helper(&v);
v.show();
QTest::qWait(30);
-
+
QBENCHMARK {
v.selectAll();
}
@@ -229,11 +229,11 @@ void tst_QTableView::spanSelectColumn()
QtTestTableModel model(500, 500);
QTableView v;
v.setModel(&model);
-
+
spanInit_helper(&v);
v.show();
QTest::qWait(30);
-
+
QBENCHMARK {
v.selectColumn(22);
}
diff --git a/tests/benchmarks/gui/painting/qtbench/benchmarktests.h b/tests/benchmarks/gui/painting/qtbench/benchmarktests.h
index 9c0e149ec5..0413290b21 100644
--- a/tests/benchmarks/gui/painting/qtbench/benchmarktests.h
+++ b/tests/benchmarks/gui/painting/qtbench/benchmarktests.h
@@ -487,7 +487,7 @@ public:
m_pixmaps.clear();
m_currentPixmap = 0;
QRect m_bounds = QRect(0,0,p->device()->width(), p->device()->height());
- switch (m_mode) {
+ switch (m_mode) {
case PainterMode:
m_size = (p->boundingRect(m_bounds, 0, m_text)).size();
// m_rect = m_rect.translated(-m_rect.topLeft());
diff --git a/tests/benchmarks/gui/text/qtext/main.cpp b/tests/benchmarks/gui/text/qtext/main.cpp
index 3a7d406777..e7e22f0e65 100644
--- a/tests/benchmarks/gui/text/qtext/main.cpp
+++ b/tests/benchmarks/gui/text/qtext/main.cpp
@@ -291,7 +291,7 @@ void tst_QText::fontResolution()
font.setFamily("DejaVu");
font2.setBold(true);
- QBENCHMARK {
+ QBENCHMARK {
QFont res = font.resolve(font2);
}
}
diff --git a/tests/benchmarks/network/access/qnetworkreply/tst_qnetworkreply.cpp b/tests/benchmarks/network/access/qnetworkreply/tst_qnetworkreply.cpp
index e653e8dffb..f62ce6bf5c 100644
--- a/tests/benchmarks/network/access/qnetworkreply/tst_qnetworkreply.cpp
+++ b/tests/benchmarks/network/access/qnetworkreply/tst_qnetworkreply.cpp
@@ -471,6 +471,10 @@ private slots:
void httpDownloadPerformanceDownloadBuffer_data();
void httpDownloadPerformanceDownloadBuffer();
void httpsRequestChain();
+ void httpsUpload();
+
+private:
+ void runHttpsUploadRequest(const QByteArray &data, const QNetworkRequest &request);
};
void tst_qnetworkreply::initTestCase()
@@ -825,6 +829,28 @@ void tst_qnetworkreply::httpsRequestChain()
}
+void tst_qnetworkreply::runHttpsUploadRequest(const QByteArray &data, const QNetworkRequest &request)
+{
+ QNetworkReply* reply = manager.post(request, data);
+ reply->ignoreSslErrors();
+ connect(reply, SIGNAL(finished()), &QTestEventLoop::instance(), SLOT(exitLoop()));
+ QTestEventLoop::instance().enterLoop(15);
+ QVERIFY(!QTestEventLoop::instance().timeout());
+ QCOMPARE(reply->error(), QNetworkReply::NoError);
+ reply->deleteLater();
+}
+
+void tst_qnetworkreply::httpsUpload()
+{
+ QByteArray data = QByteArray(2*1024*1024+1, '\177');
+ QNetworkRequest request(QUrl("https://" + QtNetworkSettings::serverName() + "/qtest/cgi-bin/md5sum.cgi"));
+ request.setHeader(QNetworkRequest::ContentTypeHeader, "application/octet-stream");
+// for (int a = 0; a < 10; ++a)
+// runHttpsUploadRequest(data, request); // to warmup all TCP connections
+ QBENCHMARK {
+ runHttpsUploadRequest(data, request);
+ }
+}
QTEST_MAIN(tst_qnetworkreply)
diff --git a/tests/benchmarks/sql/kernel/qsqlquery/main.cpp b/tests/benchmarks/sql/kernel/qsqlquery/main.cpp
index d7ef32e520..2bce545f90 100644
--- a/tests/benchmarks/sql/kernel/qsqlquery/main.cpp
+++ b/tests/benchmarks/sql/kernel/qsqlquery/main.cpp
@@ -44,7 +44,7 @@
#include "../../../../auto/sql/kernel/qsqldatabase/tst_databases.h"
-const QString qtest(qTableName( "qtest", __FILE__ ));
+const QString qtest(qTableName("qtest", __FILE__, QSqlDatabase()));
class tst_QSqlQuery : public QObject
{
@@ -149,56 +149,56 @@ void tst_QSqlQuery::dropTestTables( QSqlDatabase db )
QStringList tablenames;
// drop all the table in case a testcase failed
tablenames << qtest
- << qTableName( "qtest_null", __FILE__ )
- << qTableName( "qtest_blob", __FILE__ )
- << qTableName( "qtest_bittest", __FILE__ )
- << qTableName( "qtest_nullblob", __FILE__ )
- << qTableName( "qtest_rawtest", __FILE__ )
- << qTableName( "qtest_precision", __FILE__ )
- << qTableName( "qtest_prepare", __FILE__ )
- << qTableName( "qtestj1", __FILE__ )
- << qTableName( "qtestj2", __FILE__ )
- << qTableName( "char1Select", __FILE__ )
- << qTableName( "char1SU", __FILE__ )
- << qTableName( "qxmltest", __FILE__ )
- << qTableName( "qtest_exerr", __FILE__ )
- << qTableName( "qtest_empty", __FILE__ )
- << qTableName( "clobby", __FILE__ )
- << qTableName( "bindtest", __FILE__ )
- << qTableName( "more_results", __FILE__ )
- << qTableName( "blobstest", __FILE__ )
- << qTableName( "oraRowId", __FILE__ )
- << qTableName( "qtest_batch", __FILE__ )
- << qTableName("bug6421", __FILE__).toUpper()
- << qTableName("bug5765", __FILE__)
- << qTableName("bug6852", __FILE__)
- << qTableName( "qtest_lockedtable", __FILE__ )
- << qTableName( "Planet", __FILE__ )
- << qTableName( "task_250026", __FILE__ )
- << qTableName( "task_234422", __FILE__ )
- << qTableName("test141895", __FILE__)
- << qTableName("qtest_oraOCINumber", __FILE__);
+ << qTableName("qtest_null", __FILE__, db)
+ << qTableName("qtest_blob", __FILE__, db)
+ << qTableName("qtest_bittest", __FILE__, db)
+ << qTableName("qtest_nullblob", __FILE__, db)
+ << qTableName("qtest_rawtest", __FILE__, db)
+ << qTableName("qtest_precision", __FILE__, db)
+ << qTableName("qtest_prepare", __FILE__, db)
+ << qTableName("qtestj1", __FILE__, db)
+ << qTableName("qtestj2", __FILE__, db)
+ << qTableName("char1Select", __FILE__, db)
+ << qTableName("char1SU", __FILE__, db)
+ << qTableName("qxmltest", __FILE__, db)
+ << qTableName("qtest_exerr", __FILE__, db)
+ << qTableName("qtest_empty", __FILE__, db)
+ << qTableName("clobby", __FILE__, db)
+ << qTableName("bindtest", __FILE__, db)
+ << qTableName("more_results", __FILE__, db)
+ << qTableName("blobstest", __FILE__, db)
+ << qTableName("oraRowId", __FILE__, db)
+ << qTableName("qtest_batch", __FILE__, db)
+ << qTableName("bug6421", __FILE__, db).toUpper()
+ << qTableName("bug5765", __FILE__, db)
+ << qTableName("bug6852", __FILE__, db)
+ << qTableName("qtest_lockedtable", __FILE__, db)
+ << qTableName("Planet", __FILE__, db)
+ << qTableName("task_250026", __FILE__, db)
+ << qTableName("task_234422", __FILE__, db)
+ << qTableName("test141895", __FILE__, db)
+ << qTableName("qtest_oraOCINumber", __FILE__, db);
if ( db.driverName().startsWith("QPSQL") )
- tablenames << qTableName("task_233829", __FILE__);
+ tablenames << qTableName("task_233829", __FILE__, db);
if ( db.driverName().startsWith("QSQLITE") )
- tablenames << qTableName( "record_sqlite", __FILE__ );
+ tablenames << qTableName("record_sqlite", __FILE__, db);
if ( tst_Databases::isSqlServer( db ) || db.driverName().startsWith( "QOCI" ) )
- tablenames << qTableName( "qtest_longstr", __FILE__ );
+ tablenames << qTableName("qtest_longstr", __FILE__, db);
if (tst_Databases::isSqlServer( db ))
- db.exec("DROP PROCEDURE " + qTableName("test141895_proc", __FILE__));
+ db.exec("DROP PROCEDURE " + qTableName("test141895_proc", __FILE__, db));
if (tst_Databases::isMySQL( db ))
- db.exec("DROP PROCEDURE IF EXISTS "+qTableName("bug6852_proc", __FILE__));
+ db.exec("DROP PROCEDURE IF EXISTS "+qTableName("bug6852_proc", __FILE__, db));
tst_Databases::safeDropTables( db, tablenames );
if ( db.driverName().startsWith( "QOCI" ) ) {
QSqlQuery q( db );
- q.exec( "DROP PACKAGE " + qTableName("pkg", __FILE__) );
+ q.exec("DROP PACKAGE " + qTableName("pkg", __FILE__, db));
}
}
@@ -219,15 +219,15 @@ void tst_QSqlQuery::createTestTables( QSqlDatabase db )
QVERIFY_SQL( q, exec( "create table " + qtest + " (id int "+tst_Databases::autoFieldName(db) +" NOT NULL, t_varchar varchar(20), t_char char(20), primary key(id))" ) );
if ( tst_Databases::isSqlServer( db ) || db.driverName().startsWith( "QTDS" ) )
- QVERIFY_SQL( q, exec( "create table " + qTableName( "qtest_null", __FILE__ ) + " (id int null, t_varchar varchar(20) null)" ) );
+ QVERIFY_SQL(q, exec("create table " + qTableName("qtest_null", __FILE__, db) + " (id int null, t_varchar varchar(20) null)" ) );
else
- QVERIFY_SQL( q, exec( "create table " + qTableName( "qtest_null", __FILE__ ) + " (id int, t_varchar varchar(20))" ) );
+ QVERIFY_SQL(q, exec("create table " + qTableName("qtest_null", __FILE__, db) + " (id int, t_varchar varchar(20))" ) );
}
void tst_QSqlQuery::populateTestTables( QSqlDatabase db )
{
QSqlQuery q( db );
- const QString qtest_null(qTableName( "qtest_null", __FILE__ ));
+ const QString qtest_null(qTableName("qtest_null", __FILE__, db));
q.exec( "delete from " + qtest );
QVERIFY_SQL( q, exec( "insert into " + qtest + " values (1, 'VarChar1', 'Char1')" ) );
QVERIFY_SQL( q, exec( "insert into " + qtest + " values (2, 'VarChar2', 'Char2')" ) );
@@ -251,7 +251,7 @@ void tst_QSqlQuery::benchmark()
QSKIP( "Test requires MySQL >= 5.0");
QSqlQuery q(db);
- const QString tableName(qTableName("benchmark", __FILE__));
+ const QString tableName(qTableName("benchmark", __FILE__, db));
tst_Databases::safeDropTable( db, tableName );
diff --git a/tests/benchmarks/sql/kernel/qsqlquery/qsqlquery.pro b/tests/benchmarks/sql/kernel/qsqlquery/qsqlquery.pro
index 5c17220190..bfea404980 100644
--- a/tests/benchmarks/sql/kernel/qsqlquery/qsqlquery.pro
+++ b/tests/benchmarks/sql/kernel/qsqlquery/qsqlquery.pro
@@ -2,6 +2,6 @@ TARGET = tst_bench_qsqlquery
SOURCES += main.cpp
-QT = core sql testlib
+QT = core sql testlib core-private sql-private
win32: LIBS += -lws2_32
DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/manual/bearerex/bearerex.cpp b/tests/manual/bearerex/bearerex.cpp
index 4417253930..185dbe123e 100644
--- a/tests/manual/bearerex/bearerex.cpp
+++ b/tests/manual/bearerex/bearerex.cpp
@@ -49,9 +49,9 @@ BearerEx::BearerEx(QWidget* parent)
: QMainWindow(parent)
{
setupUi(this);
-
+
createMenus();
-
+
connect(&m_NetworkConfigurationManager, SIGNAL(updateCompleted()), this, SLOT(configurationsUpdateCompleted()));
connect(&m_NetworkConfigurationManager, SIGNAL(configurationAdded(QNetworkConfiguration)),
this, SLOT(configurationAdded(QNetworkConfiguration)));
@@ -79,19 +79,19 @@ void BearerEx::showConfigurations()
{
listWidget->clear();
QListWidgetItem* listItem;
-
+
QNetworkConfiguration defaultConfig = m_NetworkConfigurationManager.defaultConfiguration();
if (defaultConfig.type() == QNetworkConfiguration::UserChoice) {
listItem = new QListWidgetItem();
QFont font = listItem->font();
font.setBold(true);
font.setUnderline(true);
- listItem->setFont(font);
+ listItem->setFont(font);
listItem->setText(" UserChoice");
listItem->setData(Qt::UserRole, QVariant::fromValue(defaultConfig));
listWidget->addItem(listItem);
}
-
+
QList<QNetworkConfiguration> configurations = m_NetworkConfigurationManager.allConfigurations();
for (int i=0; i<configurations.count(); i++)
{
@@ -102,7 +102,7 @@ void BearerEx::showConfigurations()
} else if (configurations[i].type() == QNetworkConfiguration::ServiceNetwork) {
text.append("(SNAP,");
}
-
+
if ((configurations[i].state() & QNetworkConfiguration::Active) == QNetworkConfiguration::Active) {
text.append("Act) ");
} else if ((configurations[i].state() & QNetworkConfiguration::Discovered) == QNetworkConfiguration::Discovered) {
@@ -111,12 +111,12 @@ void BearerEx::showConfigurations()
text.append("Def) ");
}
text.append(configurations[i].name());
-
+
if (defaultConfig.isValid() && defaultConfig == configurations[i]) {
QFont font = listItem->font();
font.setBold(true);
font.setUnderline(true);
- listItem->setFont(font);
+ listItem->setFont(font);
}
listItem->setText(text);
listItem->setData(Qt::UserRole, QVariant::fromValue(configurations[i]));
@@ -151,7 +151,7 @@ void BearerEx::on_createSessionButton_clicked()
QListWidgetItem* item = listWidget->currentItem();
if (!item) {
return;
- }
+ }
QNetworkConfiguration networkConfiguration = qvariant_cast<QNetworkConfiguration>(item->data(Qt::UserRole));
int newTabIndex = mainTabWidget->count();
SessionTab* newTab = new SessionTab(&networkConfiguration,&m_NetworkConfigurationManager,eventListWidget,newTabIndex-1);
@@ -184,7 +184,7 @@ void BearerEx::onlineStateChanged(bool isOnline)
QListWidgetItem* listItem = new QListWidgetItem();
QFont font = listItem->font();
font.setBold(true);
- listItem->setFont(font);
+ listItem->setFont(font);
if (isOnline) {
listItem->setText(QString("> Online"));
} else {
@@ -231,7 +231,7 @@ DetailedInfoDialog::DetailedInfoDialog(QNetworkConfiguration* apNetworkConfigura
tableWidget->setColumnCount(2);
int rowCount = 2;
-
+
if (apNetworkConfiguration->type() == QNetworkConfiguration::ServiceNetwork) {
rowCount = rowCount + apNetworkConfiguration->children().count();
}
@@ -274,7 +274,7 @@ SessionTab::SessionTab(QNetworkConfiguration* apNetworkConfiguration,
connect(m_NetworkSession, SIGNAL(opened()), this, SLOT(opened()));
connect(m_NetworkSession, SIGNAL(closed()), this, SLOT(closed()));
connect(m_NetworkSession, SIGNAL(error(QNetworkSession::SessionError)), this, SLOT(error(QNetworkSession::SessionError)));
-
+
if (apNetworkConfiguration->type() == QNetworkConfiguration::InternetAccessPoint) {
snapLabel->hide();
snapLineEdit->hide();
@@ -342,7 +342,7 @@ void SessionTab::on_openSessionButton_clicked()
{
m_NetworkSession->open();
if (m_NetworkSession->isOpen()) {
- newState(m_NetworkSession->state());
+ newState(m_NetworkSession->state());
}
}
@@ -350,7 +350,7 @@ void SessionTab::on_closeSessionButton_clicked()
{
m_NetworkSession->close();
if (!m_NetworkSession->isOpen()) {
- newState(m_NetworkSession->state());
+ newState(m_NetworkSession->state());
}
}
@@ -414,10 +414,10 @@ void SessionTab::opened()
QListWidgetItem* listItem = new QListWidgetItem();
QFont font = listItem->font();
font.setBold(true);
- listItem->setFont(font);
+ listItem->setFont(font);
listItem->setText(QString("S")+QString::number(m_index)+QString(" - ")+QString("Opened"));
m_eventListWidget->addItem(listItem);
-
+
QVariant identifier = m_NetworkSession->sessionProperty("ActiveConfiguration");
if (!identifier.isNull()) {
QString configId = identifier.toString();
@@ -445,7 +445,7 @@ void SessionTab::closed()
QListWidgetItem* listItem = new QListWidgetItem();
QFont font = listItem->font();
font.setBold(true);
- listItem->setFont(font);
+ listItem->setFont(font);
listItem->setText(QString("S")+QString::number(m_index)+QString(" - ")+QString("Closed"));
m_eventListWidget->addItem(listItem);
}
@@ -492,10 +492,10 @@ void SessionTab::on_dataObjectChanged(const QString &newObjectType)
}
-void SessionTab::stateChanged(QNetworkSession::State state)
+void SessionTab::stateChanged(QNetworkSession::State state)
{
newState(state);
-
+
QListWidgetItem* listItem = new QListWidgetItem();
listItem->setText(QString("S")+QString::number(m_index)+QString(" - ")+stateString(state));
m_eventListWidget->addItem(listItem);
@@ -527,7 +527,7 @@ void SessionTab::error(QNetworkSession::SessionError error)
QListWidgetItem* listItem = new QListWidgetItem();
QMessageBox msgBox;
msgBox.setStandardButtons(QMessageBox::Close);
-
+
QString errorString;
switch (error)
{
@@ -549,7 +549,7 @@ void SessionTab::error(QNetworkSession::SessionError error)
}
listItem->setText(QString("S")+QString::number(m_index)+QString(" - ")+errorString);
m_eventListWidget->addItem(listItem);
-
+
msgBox.setText(errorString);
msgBox.exec();
}
diff --git a/tests/manual/bearerex/bearerex.h b/tests/manual/bearerex/bearerex.h
index 5ec2e17060..8de2b1d41d 100644
--- a/tests/manual/bearerex/bearerex.h
+++ b/tests/manual/bearerex/bearerex.h
@@ -88,7 +88,7 @@ private Q_SLOTS:
void configurationAdded(const QNetworkConfiguration& config);
void configurationRemoved(const QNetworkConfiguration& config);
void onlineStateChanged(bool isOnline);
- void configurationChanged(const QNetworkConfiguration & config);
+ void configurationChanged(const QNetworkConfiguration & config);
private:
QNetworkConfigurationManager m_NetworkConfigurationManager;
@@ -112,8 +112,8 @@ public:
SessionTab(QNetworkConfiguration* apNetworkConfiguration = 0, QNetworkConfigurationManager* configManager = 0,
QListWidget* eventListWidget = 0, int index = 0, BearerEx* parent = 0);
~SessionTab();
-
- QString stateString(QNetworkSession::State state);
+
+ QString stateString(QNetworkSession::State state);
private Q_SLOTS:
void on_createQNetworkAccessManagerButton_clicked();
@@ -125,7 +125,7 @@ private Q_SLOTS:
void on_dataObjectChanged(const QString& newObjectType);
void on_alrButton_clicked();
void finished(quint32 errorCode, qint64 dataReceived, QString errorType);
-
+
void newConfigurationActivated();
void preferredConfigurationChanged(const QNetworkConfiguration& config, bool isSeamless);
void stateChanged(QNetworkSession::State state);
diff --git a/tests/manual/bearerex/xqlistwidget.cpp b/tests/manual/bearerex/xqlistwidget.cpp
index 556d9e400f..cb03f6e9bf 100644
--- a/tests/manual/bearerex/xqlistwidget.cpp
+++ b/tests/manual/bearerex/xqlistwidget.cpp
@@ -42,7 +42,7 @@
#include "xqlistwidget.h"
XQListWidget::XQListWidget(QWidget* parent) : QListWidget(parent)
-{
+{
}
void XQListWidget::keyPressEvent(QKeyEvent* event)
@@ -59,7 +59,7 @@ void XQListWidget::keyPressEvent(QKeyEvent* event)
focusNextChild();
break;
}
- default:
+ default:
{
QListWidget::keyPressEvent(event);
}
diff --git a/tests/manual/bearerex/xqlistwidget.h b/tests/manual/bearerex/xqlistwidget.h
index b23dfb5735..80aecceb0b 100644
--- a/tests/manual/bearerex/xqlistwidget.h
+++ b/tests/manual/bearerex/xqlistwidget.h
@@ -48,8 +48,8 @@
class XQListWidget: public QListWidget
{
public:
- XQListWidget(QWidget* parent = 0);
-
+ XQListWidget(QWidget* parent = 0);
+
protected:
void keyPressEvent(QKeyEvent* event);
};
diff --git a/tests/manual/cocoa/nativewidgets/main.cpp b/tests/manual/cocoa/nativewidgets/main.cpp
new file mode 100644
index 0000000000..2ff919b125
--- /dev/null
+++ b/tests/manual/cocoa/nativewidgets/main.cpp
@@ -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 test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtCore>
+#include <QtWidgets>
+
+class ColorWidget : public QWidget
+{
+ QColor color;
+ int s;
+ int v;
+
+ void changeColor()
+ {
+ color.setHsv((qreal(qrand()) / RAND_MAX) * 50 + 200, s, s);
+ }
+
+public:
+ ColorWidget()
+ {
+ s = 150;
+ v = 150;
+ changeColor();
+ setMouseTracking(true);
+ }
+
+ void mousePressEvent(QMouseEvent *)
+ {
+ changeColor();
+ update();
+ }
+
+ void mouseMoveEvent(QMouseEvent *)
+ {
+ changeColor();
+ update();
+ }
+
+ void enterEvent(QEvent *)
+ {
+ s = 200;
+ v = 200;
+ changeColor();
+ update();
+ }
+
+ void leaveEvent(QEvent *)
+ {
+ s = 75;
+ v = 75;
+ changeColor();
+ update();
+ }
+
+ void paintEvent(QPaintEvent *){
+ QPainter p(this);
+ p.fillRect(QRect(QPoint(0, 0), size()), QBrush(color));
+ }
+};
+
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ ColorWidget window;
+
+ QWidget *w1 = new ColorWidget;
+ QWidget *w2 = new ColorWidget;
+ QWidget *w3 = new ColorWidget;
+
+ QHBoxLayout *layout = new QHBoxLayout;
+ layout->addWidget(w1);
+ layout->addWidget(w2);
+ layout->addWidget(w3);
+
+ QWidget *w3_1 = new ColorWidget;
+ QWidget *w3_2 = new ColorWidget;
+ QWidget *w3_3 = new ColorWidget;
+
+ QVBoxLayout *layout3 = new QVBoxLayout;
+ layout3->setMargin(0);
+ layout3->addWidget(w3_1);
+ layout3->addWidget(w3_2);
+ layout3->addWidget(w3_3);
+ w3->setLayout(layout3);
+
+ window.setLayout(layout);
+
+ bool native = 1;
+
+ if (native) {
+ w1->winId();
+ w2->winId();
+ w3->winId();
+
+ w3_1->winId();
+ w3_2->winId();
+ w3_3->winId();
+ }
+
+ window.resize(640, 480);
+ window.show();
+
+ return app.exec();
+}
+
+
+
diff --git a/tests/manual/cocoa/nativewidgets/nativewigets.pro b/tests/manual/cocoa/nativewidgets/nativewigets.pro
new file mode 100644
index 0000000000..f1b1260688
--- /dev/null
+++ b/tests/manual/cocoa/nativewidgets/nativewigets.pro
@@ -0,0 +1,7 @@
+TEMPLATE = app
+
+HEADERS +=
+SOURCES += main.cpp
+
+QT += core widgets
+DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0
diff --git a/tests/manual/dialogs/colordialogpanel.cpp b/tests/manual/dialogs/colordialogpanel.cpp
new file mode 100644
index 0000000000..695e37a4c7
--- /dev/null
+++ b/tests/manual/dialogs/colordialogpanel.cpp
@@ -0,0 +1,261 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "colordialogpanel.h"
+
+#include <QGroupBox>
+#include <QCheckBox>
+#include <QPushButton>
+#include <QVBoxLayout>
+#include <QHBoxLayout>
+#include <QMessageBox>
+#include <QSortFilterProxyModel>
+#include <QComboBox>
+#include <QTimer>
+#include <QDebug>
+
+// SVG color keyword names provided by the World Wide Web Consortium
+static inline QStringList svgColorNames()
+{
+ return QStringList()
+ << "aliceblue" << "antiquewhite" << "aqua" << "aquamarine" << "azure" << "beige" << "bisque"
+ << "black" << "blanchedalmond" << "blue" << "blueviolet" << "brown" << "burlywood" << "cadetblue"
+ << "chartreuse" << "chocolate" << "coral" << "cornflowerblue" << "cornsilk" << "crimson" << "cyan"
+ << "darkblue" << "darkcyan" << "darkgoldenrod" << "darkgray" << "darkgreen" << "darkgrey"
+ << "darkkhaki" << "darkmagenta" << "darkolivegreen" << "darkorange" << "darkorchid" << "darkred"
+ << "darksalmon" << "darkseagreen" << "darkslateblue" << "darkslategray" << "darkslategrey"
+ << "darkturquoise" << "darkviolet" << "deeppink" << "deepskyblue" << "dimgray" << "dimgrey"
+ << "dodgerblue" << "firebrick" << "floralwhite" << "forestgreen" << "fuchsia" << "gainsboro"
+ << "ghostwhite" << "gold" << "goldenrod" << "gray" << "grey" << "green" << "greenyellow"
+ << "honeydew" << "hotpink" << "indianred" << "indigo" << "ivory" << "khaki" << "lavender"
+ << "lavenderblush" << "lawngreen" << "lemonchiffon" << "lightblue" << "lightcoral" << "lightcyan"
+ << "lightgoldenrodyellow" << "lightgray" << "lightgreen" << "lightgrey" << "lightpink"
+ << "lightsalmon" << "lightseagreen" << "lightskyblue" << "lightslategray" << "lightslategrey"
+ << "lightsteelblue" << "lightyellow" << "lime" << "limegreen" << "linen" << "magenta"
+ << "maroon" << "mediumaquamarine" << "mediumblue" << "mediumorchid" << "mediumpurple"
+ << "mediumseagreen" << "mediumslateblue" << "mediumspringgreen" << "mediumturquoise"
+ << "mediumvioletred" << "midnightblue" << "mintcream" << "mistyrose" << "moccasin"
+ << "navajowhite" << "navy" << "oldlace" << "olive" << "olivedrab" << "orange" << "orangered"
+ << "orchid" << "palegoldenrod" << "palegreen" << "paleturquoise" << "palevioletred"
+ << "papayawhip" << "peachpuff" << "peru" << "pink" << "plum" << "powderblue" << "purple" << "red"
+ << "rosybrown" << "royalblue" << "saddlebrown" << "salmon" << "sandybrown" << "seagreen"
+ << "seashell" << "sienna" << "silver" << "skyblue" << "slateblue" << "slategray" << "slategrey"
+ << "snow" << "springgreen" << "steelblue" << "tan" << "teal" << "thistle" << "tomato"
+ << "turquoise" << "violet" << "wheat" << "white" << "whitesmoke" << "yellow" << "yellowgreen";
+}
+
+static inline QPushButton *addButton(const QString &description, QVBoxLayout *layout,
+ QObject *receiver, const char *slotFunc)
+{
+ QPushButton *button = new QPushButton(description);
+ QObject::connect(button, SIGNAL(clicked()), receiver, slotFunc);
+ layout->addWidget(button);
+ return button;
+}
+
+class ColorProxyModel : public QSortFilterProxyModel
+{
+public:
+ ColorProxyModel(QObject *parent = 0) : QSortFilterProxyModel(parent)
+ {
+ }
+
+ QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const
+ {
+ if (role == Qt::DisplayRole) {
+ QString name = data(index, Qt::EditRole).toString();
+ return tr("%1 (%2)").arg(name, QColor(name).name());
+ }
+ if (role == Qt::DecorationRole)
+ return QColor(data(index, Qt::EditRole).toString());
+ return QSortFilterProxyModel::data(index, role);
+ }
+};
+
+ColorDialogPanel::ColorDialogPanel(QWidget *parent)
+ : QWidget(parent)
+ , m_colorComboBox(new QComboBox)
+ , m_showAlphaChannel(new QCheckBox(tr("Show alpha channel")))
+ , m_noButtons(new QCheckBox(tr("Don't display OK/Cancel buttons")))
+ , m_dontUseNativeDialog(new QCheckBox(tr("Don't use native dialog")))
+{
+ // Options
+ QGroupBox *optionsGroupBox = new QGroupBox(tr("Options"), this);
+ QVBoxLayout *optionsLayout = new QVBoxLayout(optionsGroupBox);
+ optionsLayout->addWidget(m_showAlphaChannel);
+ optionsLayout->addWidget(m_noButtons);
+ optionsLayout->addWidget(m_dontUseNativeDialog);
+
+ // Color
+ QGroupBox *colorGroupBox = new QGroupBox(tr("Color"), this);
+ QVBoxLayout *colorLayout = new QVBoxLayout(colorGroupBox);
+ colorLayout->addWidget(m_colorComboBox);
+ m_colorComboBox->addItems(svgColorNames());
+ m_colorComboBox->setEditable(true);
+
+ QAbstractItemModel *sourceModel = m_colorComboBox->model();
+ ColorProxyModel* proxyModel = new ColorProxyModel(m_colorComboBox);
+ proxyModel->setSourceModel(sourceModel);
+ sourceModel->setParent(proxyModel);
+ m_colorComboBox->setModel(proxyModel);
+
+ // Buttons
+ QGroupBox *buttonsGroupBox = new QGroupBox(tr("Show"));
+ QVBoxLayout *buttonsLayout = new QVBoxLayout(buttonsGroupBox);
+ addButton(tr("Exec modal"), buttonsLayout, this, SLOT(execModal()));
+ addButton(tr("Show modal"), buttonsLayout, this, SLOT(showModal()));
+ m_deleteModalDialogButton =
+ addButton(tr("Delete modal"), buttonsLayout, this, SLOT(deleteModalDialog()));
+ addButton(tr("Show non-modal"), buttonsLayout, this, SLOT(showNonModal()));
+ m_deleteNonModalDialogButton =
+ addButton(tr("Delete non-modal"), buttonsLayout, this, SLOT(deleteNonModalDialog()));
+ addButton(tr("Restore defaults"), buttonsLayout, this, SLOT(restoreDefaults()));
+ buttonsLayout->addStretch();
+
+ // Main layout
+ QHBoxLayout *mainLayout = new QHBoxLayout(this);
+ QVBoxLayout *leftLayout = new QVBoxLayout;
+ leftLayout->addWidget(optionsGroupBox);
+ leftLayout->addWidget(colorGroupBox);
+ leftLayout->addStretch();
+ mainLayout->addLayout(leftLayout);
+ mainLayout->addWidget(buttonsGroupBox);
+
+ enableDeleteModalDialogButton();
+ enableDeleteNonModalDialogButton();
+ restoreDefaults();
+}
+
+void ColorDialogPanel::execModal()
+{
+ QColorDialog dialog(this);
+ applySettings(&dialog);
+ connect(&dialog, SIGNAL(accepted()), this, SLOT(accepted()));
+ dialog.setWindowTitle(tr("Modal Color Dialog Qt %1").arg(QLatin1String(QT_VERSION_STR)));
+ dialog.exec();
+}
+
+void ColorDialogPanel::showModal()
+{
+ if (m_modalDialog.isNull()) {
+ static int n = 0;
+ m_modalDialog = new QColorDialog(this);
+ m_modalDialog->setModal(true);
+ connect(m_modalDialog.data(), SIGNAL(accepted()), this, SLOT(accepted()));
+ m_modalDialog->setWindowTitle(tr("Modal Color Dialog #%1 Qt %2")
+ .arg(++n)
+ .arg(QLatin1String(QT_VERSION_STR)));
+ enableDeleteModalDialogButton();
+ }
+ applySettings(m_modalDialog);
+ m_modalDialog->show();
+}
+
+void ColorDialogPanel::showNonModal()
+{
+ if (m_nonModalDialog.isNull()) {
+ static int n = 0;
+ m_nonModalDialog = new QColorDialog(this);
+ connect(m_nonModalDialog.data(), SIGNAL(accepted()), this, SLOT(accepted()));
+ m_nonModalDialog->setWindowTitle(tr("Non-Modal Color Dialog #%1 Qt %2")
+ .arg(++n)
+ .arg(QLatin1String(QT_VERSION_STR)));
+ enableDeleteNonModalDialogButton();
+ }
+ applySettings(m_nonModalDialog);
+ m_nonModalDialog->show();
+}
+
+void ColorDialogPanel::deleteNonModalDialog()
+{
+ if (!m_nonModalDialog.isNull())
+ delete m_nonModalDialog;
+ enableDeleteNonModalDialogButton();
+}
+
+void ColorDialogPanel::deleteModalDialog()
+{
+ if (!m_modalDialog.isNull())
+ delete m_modalDialog;
+ enableDeleteModalDialogButton();
+}
+
+void ColorDialogPanel::accepted()
+{
+ const QColorDialog *d = qobject_cast<const QColorDialog *>(sender());
+ Q_ASSERT(d);
+ m_result.clear();
+ QDebug(&m_result).nospace()
+ << "Current color: " << d->currentColor()
+ << "\nSelected color: " << d->selectedColor();
+ QTimer::singleShot(0, this, SLOT(showAcceptedResult())); // Avoid problems with the closing (modal) dialog as parent.
+}
+
+void ColorDialogPanel::showAcceptedResult()
+{
+ QMessageBox::information(this, tr("Color Dialog Accepted"), m_result, QMessageBox::Ok);
+}
+
+void ColorDialogPanel::restoreDefaults()
+{
+ QColorDialog d;
+ m_showAlphaChannel->setChecked(d.testOption(QColorDialog::ShowAlphaChannel));
+ m_noButtons->setChecked(d.testOption(QColorDialog::NoButtons));
+ m_dontUseNativeDialog->setChecked(d.testOption(QColorDialog::DontUseNativeDialog));
+}
+
+void ColorDialogPanel::enableDeleteNonModalDialogButton()
+{
+ m_deleteNonModalDialogButton->setEnabled(!m_nonModalDialog.isNull());
+}
+
+void ColorDialogPanel::enableDeleteModalDialogButton()
+{
+ m_deleteModalDialogButton->setEnabled(!m_modalDialog.isNull());
+}
+
+void ColorDialogPanel::applySettings(QColorDialog *d) const
+{
+ d->setOption(QColorDialog::ShowAlphaChannel, m_showAlphaChannel->isChecked());
+ d->setOption(QColorDialog::NoButtons, m_noButtons->isChecked());
+ d->setOption(QColorDialog::DontUseNativeDialog, m_dontUseNativeDialog->isChecked());
+ d->setCurrentColor(QColor(m_colorComboBox->itemData(m_colorComboBox->currentIndex(), Qt::EditRole).toString()));
+}
diff --git a/tests/manual/dialogs/colordialogpanel.h b/tests/manual/dialogs/colordialogpanel.h
new file mode 100644
index 0000000000..bcd2cf6e52
--- /dev/null
+++ b/tests/manual/dialogs/colordialogpanel.h
@@ -0,0 +1,86 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef COLORDIALOGPANEL_H
+#define COLORDIALOGPANEL_H
+
+#include <QPointer>
+#include <QColorDialog>
+
+class QComboBox;
+class QCheckBox;
+class QPushButton;
+
+class ColorDialogPanel : public QWidget
+{
+ Q_OBJECT
+public:
+ explicit ColorDialogPanel(QWidget *parent = 0);
+
+public slots:
+ void execModal();
+ void showModal();
+ void showNonModal();
+ void deleteNonModalDialog();
+ void deleteModalDialog();
+ void accepted();
+ void showAcceptedResult();
+ void restoreDefaults();
+
+private slots:
+ void enableDeleteNonModalDialogButton();
+ void enableDeleteModalDialogButton();
+
+private:
+ void applySettings(QColorDialog *d) const;
+
+ QComboBox *m_colorComboBox;
+ QCheckBox *m_showAlphaChannel;
+ QCheckBox *m_noButtons;
+ QCheckBox *m_dontUseNativeDialog;
+ QPushButton *m_deleteNonModalDialogButton;
+ QPushButton *m_deleteModalDialogButton;
+ QString m_result;
+ QPointer<QColorDialog> m_modalDialog;
+ QPointer<QColorDialog> m_nonModalDialog;
+};
+
+#endif // COLORDIALOGPANEL_H
diff --git a/tests/manual/dialogs/dialogs.pro b/tests/manual/dialogs/dialogs.pro
index ff916d3854..4ed200ab7f 100644
--- a/tests/manual/dialogs/dialogs.pro
+++ b/tests/manual/dialogs/dialogs.pro
@@ -4,5 +4,7 @@ greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
TARGET = dialogs
TEMPLATE = app
-SOURCES += main.cpp filedialogpanel.cpp
-HEADERS += filedialogpanel.h
+SOURCES += main.cpp filedialogpanel.cpp colordialogpanel.cpp fontdialogpanel.cpp \
+ wizardpanel.cpp
+HEADERS += filedialogpanel.h colordialogpanel.h fontdialogpanel.h \
+ wizardpanel.h
diff --git a/tests/manual/dialogs/filedialogpanel.cpp b/tests/manual/dialogs/filedialogpanel.cpp
index 66a5201db0..636e65b684 100644
--- a/tests/manual/dialogs/filedialogpanel.cpp
+++ b/tests/manual/dialogs/filedialogpanel.cpp
@@ -44,6 +44,7 @@
#include <QGridLayout>
#include <QVBoxLayout>
#include <QHBoxLayout>
+#include <QGridLayout>
#include <QFormLayout>
#include <QSpacerItem>
#include <QGroupBox>
@@ -105,11 +106,13 @@ inline void setComboBoxValue(QComboBox *c, int v)
c->setCurrentIndex(c->findData(QVariant(v)));
}
-static inline void addButton(const QString &description, QBoxLayout *layout, QObject *receiver, const char *slotFunc)
+static inline QPushButton *addButton(const QString &description, QGridLayout *layout,
+ int &row, int column, QObject *receiver, const char *slotFunc)
{
QPushButton *button = new QPushButton(description);
QObject::connect(button, SIGNAL(clicked()), receiver, slotFunc);
- layout->addWidget(button);
+ layout->addWidget(button, row++, column);
+ return button;
}
// A line edit for editing the label fields of the dialog, keeping track of whether it has
@@ -159,6 +162,8 @@ FileDialogPanel::FileDialogPanel(QWidget *parent)
, m_selectedFileName(new QLineEdit(this))
, m_nameFilters(new QPlainTextEdit)
, m_selectedNameFilter(new QLineEdit(this))
+ , m_deleteNonModalDialogButton(0)
+ , m_deleteModalDialogButton(0)
{
// Options
QGroupBox *optionsGroupBox = new QGroupBox(tr("Options"));
@@ -197,19 +202,24 @@ FileDialogPanel::FileDialogPanel(QWidget *parent)
labelsLayout->addRow(tr("Reject label:"), m_labelLineEdits.back());
// Buttons
- QVBoxLayout *buttonLayout = new QVBoxLayout;
- buttonLayout->addSpacerItem(new QSpacerItem(0, 0, QSizePolicy::Ignored, QSizePolicy::MinimumExpanding));
- addButton(tr("Show modal"), buttonLayout, this, SLOT(showModal()));
- addButton(tr("Show non-modal"), buttonLayout, this, SLOT(showNonModal()));
- addButton(tr("getOpenFileName"), buttonLayout, this, SLOT(getOpenFileName()));
- addButton(tr("getOpenFileNames"), buttonLayout, this, SLOT(getOpenFileNames()));
- addButton(tr("getSaveFileName"), buttonLayout, this, SLOT(getSaveFileName()));
- addButton(tr("getExistingDirectory"), buttonLayout, this, SLOT(getExistingDirectory()));
- addButton(tr("Restore defaults"), buttonLayout, this, SLOT(restoreDefaults()));
QGroupBox *buttonsGroupBox = new QGroupBox(tr("Show"));
- QHBoxLayout *buttonsGroupLayout = new QHBoxLayout(buttonsGroupBox);
- buttonsGroupLayout->addSpacerItem(new QSpacerItem(0, 0, QSizePolicy::MinimumExpanding, QSizePolicy::Ignored));
- buttonsGroupLayout->addLayout(buttonLayout);
+ QGridLayout *buttonLayout = new QGridLayout(buttonsGroupBox);
+ int row = 0;
+ int column = 0;
+ addButton(tr("Exec modal"), buttonLayout, row, column, this, SLOT(execModal()));
+ addButton(tr("Show modal"), buttonLayout, row, column, this, SLOT(showModal()));
+ m_deleteModalDialogButton =
+ addButton(tr("Delete modal"), buttonLayout, row, column, this, SLOT(deleteModalDialog()));
+ addButton(tr("Show non-modal"), buttonLayout, row, column, this, SLOT(showNonModal()));
+ m_deleteNonModalDialogButton =
+ addButton(tr("Delete non-modal"), buttonLayout, row, column, this, SLOT(deleteNonModalDialog()));
+ row = 0;
+ column++;
+ addButton(tr("getOpenFileName"), buttonLayout, row, column, this, SLOT(getOpenFileName()));
+ addButton(tr("getOpenFileNames"), buttonLayout, row, column, this, SLOT(getOpenFileNames()));
+ addButton(tr("getSaveFileName"), buttonLayout, row, column, this, SLOT(getSaveFileName()));
+ addButton(tr("getExistingDirectory"), buttonLayout, row, column, this, SLOT(getExistingDirectory()));
+ addButton(tr("Restore defaults"), buttonLayout, row, column, this, SLOT(restoreDefaults()));
// Main layout
QGridLayout *gridLayout = new QGridLayout(this);
@@ -218,26 +228,76 @@ FileDialogPanel::FileDialogPanel(QWidget *parent)
gridLayout->addWidget(labelsGroupBox, 1, 0);
gridLayout->addWidget(buttonsGroupBox, 1, 1);
+ enableDeleteModalDialogButton();
+ enableDeleteNonModalDialogButton();
restoreDefaults();
}
-void FileDialogPanel::showModal()
+void FileDialogPanel::execModal()
{
QFileDialog dialog(this);
applySettings(&dialog);
+ connect(&dialog, SIGNAL(accepted()), this, SLOT(accepted()));
dialog.setWindowTitle(tr("Modal File Dialog Qt %1").arg(QLatin1String(QT_VERSION_STR)));
dialog.exec();
}
+void FileDialogPanel::showModal()
+{
+ if (m_modalDialog.isNull()) {
+ static int n = 0;
+ m_modalDialog = new QFileDialog(this);
+ m_modalDialog->setModal(true);
+ connect(m_modalDialog.data(), SIGNAL(accepted()), this, SLOT(accepted()));
+ m_modalDialog->setWindowTitle(tr("Modal File Dialog #%1 Qt %2")
+ .arg(++n)
+ .arg(QLatin1String(QT_VERSION_STR)));
+ enableDeleteModalDialogButton();
+ }
+ applySettings(m_modalDialog);
+ m_modalDialog->show();
+}
+
void FileDialogPanel::showNonModal()
{
- QFileDialog *dialog = new QFileDialog(this);
- dialog->setAttribute(Qt::WA_DeleteOnClose);
- applySettings(dialog);
- dialog->setWindowTitle(tr("Non-Modal File Dialog Qt %1").arg(QLatin1String(QT_VERSION_STR)));
- dialog->show();
+ if (m_nonModalDialog.isNull()) {
+ static int n = 0;
+ m_nonModalDialog = new QFileDialog(this);
+ connect(m_nonModalDialog.data(), SIGNAL(accepted()), this, SLOT(accepted()));
+ m_nonModalDialog->setWindowTitle(tr("Non-Modal File Dialog #%1 Qt %2")
+ .arg(++n)
+ .arg(QLatin1String(QT_VERSION_STR)));
+ enableDeleteNonModalDialogButton();
+ }
+ applySettings(m_nonModalDialog);
+ m_nonModalDialog->show();
+}
+
+void FileDialogPanel::deleteNonModalDialog()
+{
+ if (!m_nonModalDialog.isNull())
+ delete m_nonModalDialog;
+ enableDeleteNonModalDialogButton();
}
+void FileDialogPanel::deleteModalDialog()
+{
+ if (!m_modalDialog.isNull())
+ delete m_modalDialog;
+ enableDeleteModalDialogButton();
+}
+
+void FileDialogPanel::enableDeleteNonModalDialogButton()
+{
+ m_deleteNonModalDialogButton->setEnabled(!m_nonModalDialog.isNull());
+}
+
+void FileDialogPanel::enableDeleteModalDialogButton()
+{
+ m_deleteModalDialogButton->setEnabled(!m_modalDialog.isNull());
+}
+
+
QString FileDialogPanel::filterString() const
{
return m_nameFilters->toPlainText().trimmed().replace(QLatin1String("\n"), QLatin1String(";;"));
@@ -340,7 +400,9 @@ void FileDialogPanel::applySettings(QFileDialog *d) const
d->setFileMode(comboBoxValue<QFileDialog::FileMode>(m_fileMode));
d->setOptions(options());
d->setDefaultSuffix(m_defaultSuffix->text().trimmed());
- d->setDirectory(m_directory->text().trimmed());
+ const QString directory = m_directory->text().trimmed();
+ if (!directory.isEmpty())
+ d->setDirectory(directory);
const QString file = m_selectedFileName->text().trimmed();
if (!file.isEmpty())
d->selectFile(file);
@@ -350,7 +412,6 @@ void FileDialogPanel::applySettings(QFileDialog *d) const
d->selectNameFilter(filter);
foreach (LabelLineEdit *l, m_labelLineEdits)
l->apply(d);
- connect(d, SIGNAL(accepted()), this, SLOT(accepted()));
}
void FileDialogPanel::accepted()
diff --git a/tests/manual/dialogs/filedialogpanel.h b/tests/manual/dialogs/filedialogpanel.h
index 699d917e4d..7ee7cb3f60 100644
--- a/tests/manual/dialogs/filedialogpanel.h
+++ b/tests/manual/dialogs/filedialogpanel.h
@@ -44,7 +44,9 @@
#include <QGroupBox>
#include <QFileDialog>
+#include <QPointer>
+class QPushButton;
class QCheckBox;
class QComboBox;
class QLineEdit;
@@ -58,8 +60,11 @@ public:
explicit FileDialogPanel(QWidget *parent = 0);
public slots:
+ void execModal();
void showModal();
void showNonModal();
+ void deleteNonModalDialog();
+ void deleteModalDialog();
void getOpenFileNames();
void getOpenFileName();
void getSaveFileName();
@@ -68,6 +73,10 @@ public slots:
void showAcceptedResult();
void restoreDefaults();
+private slots:
+ void enableDeleteNonModalDialogButton();
+ void enableDeleteModalDialogButton();
+
private:
QString filterString() const;
QFileDialog::Options options() const;
@@ -87,7 +96,11 @@ private:
QList<LabelLineEdit *> m_labelLineEdits;
QPlainTextEdit *m_nameFilters;
QLineEdit *m_selectedNameFilter;
+ QPushButton *m_deleteNonModalDialogButton;
+ QPushButton *m_deleteModalDialogButton;
QString m_result;
+ QPointer<QFileDialog> m_modalDialog;
+ QPointer<QFileDialog> m_nonModalDialog;
};
#endif // FILEDIALOGPANEL_H
diff --git a/tests/manual/dialogs/fontdialogpanel.cpp b/tests/manual/dialogs/fontdialogpanel.cpp
new file mode 100644
index 0000000000..2bdbb0625a
--- /dev/null
+++ b/tests/manual/dialogs/fontdialogpanel.cpp
@@ -0,0 +1,208 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "fontdialogpanel.h"
+
+#include <QGroupBox>
+#include <QCheckBox>
+#include <QPushButton>
+#include <QVBoxLayout>
+#include <QHBoxLayout>
+#include <QMessageBox>
+#include <QFontComboBox>
+#include <QDoubleSpinBox>
+#include <QTimer>
+#include <QDebug>
+
+static inline QPushButton *addButton(const QString &description, QVBoxLayout *layout,
+ QObject *receiver, const char *slotFunc)
+{
+ QPushButton *button = new QPushButton(description);
+ QObject::connect(button, SIGNAL(clicked()), receiver, slotFunc);
+ layout->addWidget(button);
+ return button;
+}
+
+FontDialogPanel::FontDialogPanel(QWidget *parent)
+ : QWidget(parent)
+ , m_fontFamilyBox(new QFontComboBox)
+ , m_fontSizeBox(new QDoubleSpinBox)
+ , m_noButtons(new QCheckBox(tr("Don't display OK/Cancel buttons")))
+ , m_dontUseNativeDialog(new QCheckBox(tr("Don't use native dialog")))
+{
+ // Options
+ QGroupBox *optionsGroupBox = new QGroupBox(tr("Options"), this);
+ QVBoxLayout *optionsLayout = new QVBoxLayout(optionsGroupBox);
+ optionsLayout->addWidget(m_noButtons);
+ optionsLayout->addWidget(m_dontUseNativeDialog);
+
+ // Font
+ QGroupBox *fontGroupBox = new QGroupBox(tr("Font"), this);
+ QHBoxLayout *fontLayout = new QHBoxLayout(fontGroupBox);
+ fontLayout->addWidget(m_fontFamilyBox);
+ fontLayout->addWidget(m_fontSizeBox);
+ m_fontSizeBox->setValue(QFont().pointSizeF());
+
+ // Buttons
+ QGroupBox *buttonsGroupBox = new QGroupBox(tr("Show"));
+ QVBoxLayout *buttonsLayout = new QVBoxLayout(buttonsGroupBox);
+ addButton(tr("Exec modal"), buttonsLayout, this, SLOT(execModal()));
+ addButton(tr("Show modal"), buttonsLayout, this, SLOT(showModal()));
+ m_deleteModalDialogButton =
+ addButton(tr("Delete modal"), buttonsLayout, this, SLOT(deleteModalDialog()));
+ addButton(tr("Show non-modal"), buttonsLayout, this, SLOT(showNonModal()));
+ m_deleteNonModalDialogButton =
+ addButton(tr("Delete non-modal"), buttonsLayout, this, SLOT(deleteNonModalDialog()));
+ addButton(tr("Restore defaults"), buttonsLayout, this, SLOT(restoreDefaults()));
+ buttonsLayout->addStretch();
+
+ // Main layout
+ QHBoxLayout *mainLayout = new QHBoxLayout(this);
+ QVBoxLayout *leftLayout = new QVBoxLayout;
+ leftLayout->addWidget(optionsGroupBox);
+ leftLayout->addWidget(fontGroupBox);
+ leftLayout->addStretch();
+ mainLayout->addLayout(leftLayout);
+ mainLayout->addWidget(buttonsGroupBox);
+
+ enableDeleteModalDialogButton();
+ enableDeleteNonModalDialogButton();
+ restoreDefaults();
+}
+
+void FontDialogPanel::execModal()
+{
+ QFontDialog dialog(this);
+ applySettings(&dialog);
+ connect(&dialog, SIGNAL(accepted()), this, SLOT(accepted()));
+ dialog.setWindowTitle(tr("Modal Font Dialog Qt %1").arg(QLatin1String(QT_VERSION_STR)));
+ dialog.exec();
+}
+
+void FontDialogPanel::showModal()
+{
+ if (m_modalDialog.isNull()) {
+ static int n = 0;
+ m_modalDialog = new QFontDialog(this);
+ m_modalDialog->setModal(true);
+ connect(m_modalDialog.data(), SIGNAL(accepted()), this, SLOT(accepted()));
+ m_modalDialog->setWindowTitle(tr("Modal Font Dialog #%1 Qt %2")
+ .arg(++n)
+ .arg(QLatin1String(QT_VERSION_STR)));
+ enableDeleteModalDialogButton();
+ }
+ applySettings(m_modalDialog);
+ m_modalDialog->show();
+}
+
+void FontDialogPanel::showNonModal()
+{
+ if (m_nonModalDialog.isNull()) {
+ static int n = 0;
+ m_nonModalDialog = new QFontDialog(this);
+ connect(m_nonModalDialog.data(), SIGNAL(accepted()), this, SLOT(accepted()));
+ m_nonModalDialog->setWindowTitle(tr("Non-Modal Font Dialog #%1 Qt %2")
+ .arg(++n)
+ .arg(QLatin1String(QT_VERSION_STR)));
+ enableDeleteNonModalDialogButton();
+ }
+ applySettings(m_nonModalDialog);
+ m_nonModalDialog->show();
+}
+
+void FontDialogPanel::deleteNonModalDialog()
+{
+ if (!m_nonModalDialog.isNull())
+ delete m_nonModalDialog;
+ enableDeleteNonModalDialogButton();
+}
+
+void FontDialogPanel::deleteModalDialog()
+{
+ if (!m_modalDialog.isNull())
+ delete m_modalDialog;
+ enableDeleteModalDialogButton();
+}
+
+void FontDialogPanel::accepted()
+{
+ const QFontDialog *d = qobject_cast<const QFontDialog *>(sender());
+ Q_ASSERT(d);
+ m_result.clear();
+ QDebug(&m_result).nospace()
+ << "Current font: " << d->currentFont()
+ << "\nSelected font: " << d->selectedFont();
+ QTimer::singleShot(0, this, SLOT(showAcceptedResult())); // Avoid problems with the closing (modal) dialog as parent.
+}
+
+void FontDialogPanel::showAcceptedResult()
+{
+ QMessageBox::information(this, tr("Color Dialog Accepted"), m_result, QMessageBox::Ok);
+}
+
+void FontDialogPanel::restoreDefaults()
+{
+ QFontDialog d;
+ m_noButtons->setChecked(d.testOption(QFontDialog::NoButtons));
+ m_dontUseNativeDialog->setChecked(d.testOption(QFontDialog::DontUseNativeDialog));
+ m_fontFamilyBox->setCurrentFont(QFont());
+ m_fontSizeBox->setValue(QFont().pointSizeF());
+}
+
+void FontDialogPanel::enableDeleteNonModalDialogButton()
+{
+ m_deleteNonModalDialogButton->setEnabled(!m_nonModalDialog.isNull());
+}
+
+void FontDialogPanel::enableDeleteModalDialogButton()
+{
+ m_deleteModalDialogButton->setEnabled(!m_modalDialog.isNull());
+}
+
+void FontDialogPanel::applySettings(QFontDialog *d) const
+{
+ d->setOption(QFontDialog::NoButtons, m_noButtons->isChecked());
+ d->setOption(QFontDialog::DontUseNativeDialog, m_dontUseNativeDialog->isChecked());
+
+ QFont font = m_fontFamilyBox->currentFont();
+ font.setPointSizeF(m_fontSizeBox->value());
+ d->setCurrentFont(font);
+}
diff --git a/tests/manual/dialogs/fontdialogpanel.h b/tests/manual/dialogs/fontdialogpanel.h
new file mode 100644
index 0000000000..92f2b7313f
--- /dev/null
+++ b/tests/manual/dialogs/fontdialogpanel.h
@@ -0,0 +1,87 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef FONTDIALOGPANEL_H
+#define FONTDIALOGPANEL_H
+
+#include <QPointer>
+#include <QFontDialog>
+
+class QCheckBox;
+class QPushButton;
+class QFontComboBox;
+class QDoubleSpinBox;
+
+class FontDialogPanel : public QWidget
+{
+ Q_OBJECT
+public:
+ explicit FontDialogPanel(QWidget *parent = 0);
+
+public slots:
+ void execModal();
+ void showModal();
+ void showNonModal();
+ void deleteNonModalDialog();
+ void deleteModalDialog();
+ void accepted();
+ void showAcceptedResult();
+ void restoreDefaults();
+
+private slots:
+ void enableDeleteNonModalDialogButton();
+ void enableDeleteModalDialogButton();
+
+private:
+ void applySettings(QFontDialog *d) const;
+
+ QFontComboBox *m_fontFamilyBox;
+ QDoubleSpinBox *m_fontSizeBox;
+ QCheckBox *m_noButtons;
+ QCheckBox *m_dontUseNativeDialog;
+ QPushButton *m_deleteNonModalDialogButton;
+ QPushButton *m_deleteModalDialogButton;
+ QString m_result;
+ QPointer<QFontDialog> m_modalDialog;
+ QPointer<QFontDialog> m_nonModalDialog;
+};
+
+#endif // FONTDIALOGPANEL_H
diff --git a/tests/manual/dialogs/main.cpp b/tests/manual/dialogs/main.cpp
index c1ea7b0d8f..86e6c90b3f 100644
--- a/tests/manual/dialogs/main.cpp
+++ b/tests/manual/dialogs/main.cpp
@@ -40,6 +40,9 @@
****************************************************************************/
#include "filedialogpanel.h"
+#include "colordialogpanel.h"
+#include "fontdialogpanel.h"
+#include "wizardpanel.h"
#include <QMainWindow>
#include <QApplication>
@@ -50,7 +53,6 @@
#include <QKeySequence>
// Test for dialogs, allowing to play with all dialog options for implementing native dialogs.
-// Currently, only QFileDialog is implemented.
// Compiles with Qt 4.8 and Qt 5.
class MainWindow : public QMainWindow {
@@ -68,6 +70,9 @@ MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent)
connect(quitAction, SIGNAL(triggered()), qApp, SLOT(quit()));
QTabWidget *tabWidget = new QTabWidget;
tabWidget->addTab(new FileDialogPanel, tr("QFileDialog"));
+ tabWidget->addTab(new ColorDialogPanel, tr("QColorDialog"));
+ tabWidget->addTab(new FontDialogPanel, tr("QFontDialog"));
+ tabWidget->addTab(new WizardPanel, tr("QWizard"));
setCentralWidget(tabWidget);
}
diff --git a/tests/manual/dialogs/wizardpanel.cpp b/tests/manual/dialogs/wizardpanel.cpp
new file mode 100644
index 0000000000..1306062426
--- /dev/null
+++ b/tests/manual/dialogs/wizardpanel.cpp
@@ -0,0 +1,361 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "wizardpanel.h"
+
+#include <QWizard>
+#include <QWizardPage>
+#include <QVBoxLayout>
+#include <QGridLayout>
+#include <QRadioButton>
+#include <QPushButton>
+#include <QCheckBox>
+#include <QButtonGroup>
+#include <QSpacerItem>
+#include <QGroupBox>
+#include <QLabel>
+#include <QStyle>
+#include <QIcon>
+#include <QImage>
+#include <QPainter>
+#include <QFont>
+#include <QFontMetrics>
+#include <QHash>
+
+static QIcon coloredIcon(const Qt::GlobalColor color)
+{
+ QImage image(QSize(24, 24), QImage::Format_RGB32);
+ image.fill(color);
+ return QIcon(QPixmap::fromImage(image));
+}
+
+static QPixmap pixmapWithText(const QString &text, const QColor color)
+{
+ QFont font;
+ QFontMetrics metric(font);
+ QRect rectangle = metric.boundingRect(text);
+ rectangle.setBottomRight(rectangle.bottomRight() + QPoint(20, 20));
+ QImage image(rectangle.size(), QImage::Format_RGB32);
+ image.fill(color);
+ QPainter painter(&image);
+ painter.setFont(font);
+ painter.drawText(rectangle, Qt::AlignHCenter | Qt::AlignVCenter, text);
+ return QPixmap::fromImage(image);
+}
+
+// A radio-group control for QWizard::WizardStyle.
+class WizardStyleControl : public QGroupBox
+{
+ Q_OBJECT
+public:
+ WizardStyleControl(QWidget *parent = 0);
+
+ void setWizardStyle(int style);
+ QWizard::WizardStyle wizardStyle() const;
+
+signals:
+ void wizardStyleChanged(int);
+
+private:
+ QButtonGroup *m_group;
+};
+
+WizardStyleControl::WizardStyleControl(QWidget *parent)
+ : QGroupBox(tr("Style"), parent)
+ , m_group(new QButtonGroup(this))
+{
+ m_group->setExclusive(true);
+ connect(m_group, SIGNAL(buttonClicked(int)), this, SIGNAL(wizardStyleChanged(int)));
+ QVBoxLayout *vLayout = new QVBoxLayout(this);
+ QRadioButton *radioButton = new QRadioButton(tr("None/OS Default"), this);
+ m_group->addButton(radioButton, QWizard::NStyles);
+ vLayout->addWidget(radioButton);
+ radioButton = new QRadioButton(tr("ClassicStyle"), this);
+ m_group->addButton(radioButton, QWizard::ClassicStyle);
+ vLayout->addWidget(radioButton);
+ radioButton = new QRadioButton(tr("ModernStyle"), this);
+ m_group->addButton(radioButton, QWizard::ModernStyle);
+ vLayout->addWidget(radioButton);
+ radioButton = new QRadioButton(tr("MacStyle"), this);
+ m_group->addButton(radioButton, QWizard::MacStyle);
+ vLayout->addWidget(radioButton);
+ radioButton = new QRadioButton(tr("AeroStyle"), this);
+ m_group->addButton(radioButton, QWizard::AeroStyle);
+ vLayout->addWidget(radioButton);
+ vLayout->addItem(new QSpacerItem(0, 0, QSizePolicy::Ignored, QSizePolicy::MinimumExpanding));
+
+ setWizardStyle(style()->styleHint(QStyle::SH_WizardStyle));
+}
+
+QWizard::WizardStyle WizardStyleControl::wizardStyle() const
+{
+ return static_cast<QWizard::WizardStyle>(m_group->checkedId());
+}
+
+void WizardStyleControl::setWizardStyle(int wizardStyle)
+{
+ if (wizardStyle < 0 || wizardStyle > QWizard::NStyles)
+ wizardStyle = QWizard::NStyles;
+ QAbstractButton *button = m_group->button(wizardStyle);
+ Q_ASSERT(button);
+ const bool blocked = m_group->blockSignals(true);
+ button->setChecked(true);
+ m_group->blockSignals(blocked);
+}
+
+// A control with checkboxes for QWizard::WizardOption.
+class WizardOptionsControl : public QGroupBox
+{
+public:
+ explicit WizardOptionsControl(QWidget *parent = 0);
+
+ QWizard::WizardOption wizardOptions() const;
+ void setWizardOptions(int options);
+
+private:
+ typedef QHash<int, QCheckBox *> CheckBoxHash;
+
+ void addCheckBox(QVBoxLayout *layout, int flag, const QString &title);
+
+ CheckBoxHash m_checkBoxes;
+};
+
+WizardOptionsControl::WizardOptionsControl(QWidget *parent)
+ : QGroupBox(tr("Options"), parent)
+{
+ QVBoxLayout *vLayout = new QVBoxLayout(this);
+ addCheckBox(vLayout, QWizard::IndependentPages, QLatin1String("IndependentPages"));
+ addCheckBox(vLayout, QWizard::IgnoreSubTitles, QLatin1String("IgnoreSubTitles"));
+ addCheckBox(vLayout, QWizard::ExtendedWatermarkPixmap, QLatin1String("ExtendedWatermarkPixmap"));
+ addCheckBox(vLayout, QWizard::NoDefaultButton, QLatin1String("NoDefaultButton"));
+ addCheckBox(vLayout, QWizard::NoBackButtonOnStartPage, QLatin1String("NoBackButtonOnStartPage"));
+ addCheckBox(vLayout, QWizard::NoBackButtonOnLastPage, QLatin1String("NoBackButtonOnLastPage"));
+ addCheckBox(vLayout, QWizard::DisabledBackButtonOnLastPage, QLatin1String("DisabledBackButtonOnLastPage"));
+ addCheckBox(vLayout, QWizard::HaveNextButtonOnLastPage, QLatin1String("HaveNextButtonOnLastPage"));
+ addCheckBox(vLayout, QWizard::HaveFinishButtonOnEarlyPages, QLatin1String("HaveFinishButtonOnEarlyPages"));
+ addCheckBox(vLayout, QWizard::NoCancelButton, QLatin1String("NoCancelButton"));
+ addCheckBox(vLayout, QWizard::CancelButtonOnLeft, QLatin1String("CancelButtonOnLeft"));
+ addCheckBox(vLayout, QWizard::HaveHelpButton, QLatin1String("HaveHelpButton"));
+ addCheckBox(vLayout, QWizard::HelpButtonOnRight, QLatin1String("HelpButtonOnRight"));
+ addCheckBox(vLayout, QWizard::HaveCustomButton1, QLatin1String("HaveCustomButton1"));
+ addCheckBox(vLayout, QWizard::HaveCustomButton2, QLatin1String("HaveCustomButton2"));
+ addCheckBox(vLayout, QWizard::HaveCustomButton3, QLatin1String("HaveCustomButton3"));
+ vLayout->addItem(new QSpacerItem(0, 0, QSizePolicy::Ignored, QSizePolicy::MinimumExpanding));
+}
+
+void WizardOptionsControl::addCheckBox(QVBoxLayout *layout, int flag, const QString &title)
+{
+ QCheckBox *checkBox = new QCheckBox(title, this);
+ layout->addWidget(checkBox);
+ m_checkBoxes.insert(flag, checkBox);
+}
+
+QWizard::WizardOption WizardOptionsControl::wizardOptions() const
+{
+ int result = 0;
+ typedef CheckBoxHash::const_iterator ConstIterator;
+ const ConstIterator cend = m_checkBoxes.constEnd();
+ for (ConstIterator it = m_checkBoxes.constBegin(); it != cend; ++it)
+ if (it.value()->isChecked())
+ result |= it.key();
+ return static_cast<QWizard::WizardOption>(result);
+}
+
+void WizardOptionsControl::setWizardOptions(int options)
+{
+ typedef CheckBoxHash::iterator Iterator;
+ const Iterator end = m_checkBoxes.end();
+ for (Iterator it = m_checkBoxes.begin(); it != end; ++it)
+ it.value()->setChecked(options & it.key());
+}
+
+// A test wizard with a slot to change its style.
+class Wizard : public QWizard {
+ Q_OBJECT
+public:
+ explicit Wizard(QWidget *parent = 0, Qt::WindowFlags flags = 0);
+
+public slots:
+ void changeWizardStyle(int newStyle);
+};
+
+void Wizard::changeWizardStyle(int newStyle)
+{
+ if (newStyle >= 0 && newStyle < int(QWizard::NStyles))
+ setWizardStyle(static_cast<QWizard::WizardStyle>(newStyle));
+}
+
+// A test wizard page with a WizardStyleControl.
+class WizardPage : public QWizardPage
+{
+public:
+ explicit WizardPage(const QString &title, QWidget *parent = 0);
+
+ void initializePage();
+
+private:
+ WizardStyleControl *m_styleControl;
+ bool m_firstTimeShown;
+};
+
+WizardPage::WizardPage(const QString &title, QWidget *parent)
+ : QWizardPage(parent)
+ , m_styleControl(new WizardStyleControl(this))
+ , m_firstTimeShown(true)
+{
+ setTitle(title);
+ setSubTitle(title + QLatin1String(" SubTitle"));
+ QVBoxLayout *vLayout = new QVBoxLayout(this);
+ vLayout->addWidget(m_styleControl);
+}
+
+void WizardPage::initializePage()
+{
+ m_styleControl->setWizardStyle(wizard()->wizardStyle());
+ if (m_firstTimeShown) {
+ m_firstTimeShown = false;
+ connect(m_styleControl, SIGNAL(wizardStyleChanged(int)),
+ wizard(), SLOT(changeWizardStyle(int)));
+ }
+}
+
+Wizard::Wizard(QWidget *parent, Qt::WindowFlags flags)
+ : QWizard(parent, flags)
+{
+ setWindowIcon(coloredIcon(Qt::red));
+ setWindowTitle(QLatin1String("Wizard ") + QLatin1String(QT_VERSION_STR));
+ addPage(new WizardPage(tr("Page 1"), this));
+ addPage(new WizardPage(tr("Page 2"), this));
+ addPage(new WizardPage(tr("Page 3"), this));
+}
+
+// A dialog using a Wizard as child widget (emulating Qt Designer).
+class WizardEmbeddingDialog : public QDialog {
+public:
+ explicit WizardEmbeddingDialog(QWidget *parent = 0);
+
+ Wizard *wizard() const { return m_wizard; }
+
+private:
+ Wizard *m_wizard;
+};
+
+WizardEmbeddingDialog::WizardEmbeddingDialog(QWidget *parent)
+ : QDialog(parent)
+ , m_wizard(new Wizard)
+{
+ setWindowTitle(QString::fromLatin1("Dialog Embedding QWizard %1").arg(QT_VERSION_STR));
+ QGridLayout *gridLayout = new QGridLayout(this);
+ gridLayout->addWidget(new QLabel(tr("Above wizard")), 0, 0, 1, 3);
+ gridLayout->addWidget(new QLabel(tr("Left of wizard")), 1, 0);
+ m_wizard->setObjectName(QLatin1String("EmbeddedWizard"));
+ m_wizard->setParent(this, Qt::Widget);
+ gridLayout->addWidget(m_wizard, 1, 1);
+ gridLayout->addWidget(new QLabel(tr("Right of wizard")), 1, 2);
+ gridLayout->addWidget(new QLabel(tr("Below wizard")), 2, 0, 1, 3);
+}
+
+WizardPanel::WizardPanel(QWidget *parent)
+ : QWidget(parent)
+ , m_styleControl(new WizardStyleControl(this))
+ , m_optionsControl(new WizardOptionsControl(this))
+{
+ {
+ QWizard wizard;
+ m_optionsControl->setWizardOptions(wizard.options());
+ m_styleControl->setWizardStyle(wizard.wizardStyle());
+ }
+
+ QGridLayout *gridLayout = new QGridLayout(this);
+ gridLayout->addWidget(m_optionsControl, 0, 0, 2, 1);
+ gridLayout->addWidget(m_styleControl, 0, 1);
+ QGroupBox *buttonGroupBox = new QGroupBox(this);
+ QVBoxLayout *vLayout = new QVBoxLayout(buttonGroupBox);
+ QPushButton *button = new QPushButton(tr("Show modal"), this);
+ connect(button, SIGNAL(clicked()), this, SLOT(showModal()));
+ vLayout->addWidget(button);
+ button = new QPushButton(tr("Show non-modal"), this);
+ connect(button, SIGNAL(clicked()), this, SLOT(showNonModal()));
+ vLayout->addWidget(button);
+ button = new QPushButton(tr("Show embedded"), this);
+ button->setToolTip(tr("Test QWizard's behavior when used as a widget child."));
+ connect(button, SIGNAL(clicked()), this, SLOT(showEmbedded()));
+ vLayout->addWidget(button);
+ vLayout->addItem(new QSpacerItem(0, 0, QSizePolicy::Ignored, QSizePolicy::MinimumExpanding));
+ gridLayout->addWidget(buttonGroupBox, 1, 1);
+}
+
+void WizardPanel::showModal()
+{
+ Wizard wizard(this);
+ applyParameters(&wizard);
+ wizard.exec();
+}
+
+void WizardPanel::showNonModal()
+{
+ Wizard *wizard = new Wizard(this);
+ applyParameters(wizard);
+ wizard->setModal(false);
+ wizard->setAttribute(Qt::WA_DeleteOnClose);
+ wizard->show();
+}
+
+void WizardPanel::showEmbedded()
+{
+ WizardEmbeddingDialog *dialog = new WizardEmbeddingDialog(this);
+ applyParameters(dialog->wizard());
+ dialog->setModal(false);
+ dialog->setAttribute(Qt::WA_DeleteOnClose);
+ dialog->show();
+}
+
+void WizardPanel::applyParameters(QWizard *wizard) const
+{
+ wizard->setWizardStyle(m_styleControl->wizardStyle());
+ wizard->setOptions(m_optionsControl->wizardOptions());
+ wizard->setPixmap(QWizard::WatermarkPixmap, pixmapWithText(QLatin1String("Watermark"), QColor(Qt::blue).lighter()));
+ wizard->setPixmap(QWizard::LogoPixmap, pixmapWithText(QLatin1String("Logo"), Qt::green));
+ wizard->setPixmap(QWizard::BannerPixmap, pixmapWithText(QLatin1String("Banner"), Qt::green));
+ wizard->setPixmap(QWizard::BackgroundPixmap, pixmapWithText(QLatin1String("Background"), QColor(Qt::red).lighter()));
+}
+
+#include "wizardpanel.moc"
diff --git a/tests/manual/dialogs/wizardpanel.h b/tests/manual/dialogs/wizardpanel.h
new file mode 100644
index 0000000000..0a4ec8e467
--- /dev/null
+++ b/tests/manual/dialogs/wizardpanel.h
@@ -0,0 +1,69 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef WIZARDPANEL_H
+#define WIZARDPANEL_H
+
+#include <QWidget>
+
+class WizardStyleControl;
+class WizardOptionsControl;
+class QWizard;
+
+class WizardPanel : public QWidget
+{
+ Q_OBJECT
+public:
+ explicit WizardPanel(QWidget *parent = 0);
+
+public slots:
+ void showModal();
+ void showNonModal();
+ void showEmbedded();
+
+private:
+ void applyParameters(QWizard *wizard) const;
+
+ WizardStyleControl *m_styleControl;
+ WizardOptionsControl *m_optionsControl;
+};
+
+#endif // WIZARDPANEL_H
diff --git a/tests/manual/filetest/main.cpp b/tests/manual/filetest/main.cpp
index 9d94265df7..2f7c5cdd06 100644
--- a/tests/manual/filetest/main.cpp
+++ b/tests/manual/filetest/main.cpp
@@ -46,6 +46,7 @@
#include <QDir>
#include <iostream>
+#include <string>
static const char usage1[] =
"\nTests various file functionality in Qt\n\n"
@@ -58,11 +59,46 @@ static const char usage2[] =" [KEYWORD] [ARGUMENTS]\n\n"
" rmr DIR remove directory recursively\n"
" using QDir::removeRecursively\n";
+static inline std::string permissions(QFile::Permissions permissions)
+{
+ std::string result(10, '-');
+ if (permissions & QFile::ReadOwner)
+ result[1] = 'r';
+ if (permissions & QFile::WriteOwner)
+ result[2] = 'w';
+ if (permissions & QFile::ExeOwner)
+ result[3] = 'x';
+ if (permissions & QFile::ReadGroup)
+ result[4] = 'r';
+ if (permissions & QFile::WriteGroup)
+ result[5] = 'w';
+ if (permissions & QFile::ExeGroup)
+ result[6] = 'x';
+ if (permissions & QFile::ReadOther)
+ result[7] = 'r';
+ if (permissions & QFile::WriteOther)
+ result[8] = 'w';
+ if (permissions & QFile::ExeOther)
+ result[9] = 'x';
+ return result;
+}
+
+static inline std::string permissions(const QFileInfo &fi)
+{
+ std::string result = permissions(fi.permissions());
+ if (fi.isSymLink())
+ result[0] = 'l';
+ else if (fi.isDir())
+ result[0] = 'd';
+ return result;
+}
+
static int ls(int argCount, char **args)
{
for (int i = 0 ; i < argCount; ++i) {
const QFileInfo fi(QString::fromLocal8Bit(args[i]));
- std::cout << QDir::toNativeSeparators(fi.absoluteFilePath()).toStdString() << ' ' << fi.size();
+ std::cout << QDir::toNativeSeparators(fi.absoluteFilePath()).toStdString() << ' ' << fi.size()
+ << ' ' << permissions(fi);
if (fi.exists())
std::cout << " [exists]";
if (fi.isFile())
@@ -73,6 +109,7 @@ static int ls(int argCount, char **args)
}
if (fi.isDir())
std::cout << " [dir]";
+
std::cout << std::endl;
}
return 0;
@@ -110,12 +147,18 @@ static int rm(const char *fileName)
static int rmr(const char *dirName)
{
+#if QT_VERSION < 0x050000
+ Q_UNUSED(dirName)
+ return 1;
+#else
QDir dir(QString::fromLocal8Bit(dirName));
if (!dir.removeRecursively()) {
qWarning().nospace() << "Failed to remove " << dir.absolutePath();
return -1;
}
+
return 0;
+#endif
}
int main(int argc, char *argv[])
diff --git a/tests/manual/gestures/graphicsview/main.cpp b/tests/manual/gestures/graphicsview/main.cpp
index d6551e53bf..cc06cb1986 100644
--- a/tests/manual/gestures/graphicsview/main.cpp
+++ b/tests/manual/gestures/graphicsview/main.cpp
@@ -39,7 +39,16 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QApplication>
+#include <QMainWindow>
+#include <QGraphicsScene>
+#include <QGraphicsView>
+#include <QScrollBar>
+#include <QImageReader>
+#include <QVBoxLayout>
+#include <QGestureEvent>
+#include <QDir>
+#include <QFileDialog>
#include "imageitem.h"
#include "gestures.h"
diff --git a/tests/manual/gestures/scrollarea/main.cpp b/tests/manual/gestures/scrollarea/main.cpp
index 7917b76418..3acce40d50 100644
--- a/tests/manual/gestures/scrollarea/main.cpp
+++ b/tests/manual/gestures/scrollarea/main.cpp
@@ -39,7 +39,17 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QApplication>
+#include <QSlider>
+#include <QScrollArea>
+#include <QScrollBar>
+#include <QMainWindow>
+#include <QLabel>
+#include <QPushButton>
+#include <QVBoxLayout>
+#include <QGestureEvent>
+#include <QPanGesture>
+#include <QDebug>
#include "mousepangesturerecognizer.h"
diff --git a/tests/manual/highdpi/highdpi.qrc b/tests/manual/highdpi/highdpi.qrc
index b43c2c07ad..10efac44fa 100644
--- a/tests/manual/highdpi/highdpi.qrc
+++ b/tests/manual/highdpi/highdpi.qrc
@@ -1,7 +1,9 @@
<RCC>
<qresource prefix="/">
- <file>qticon.png</file>
- <file>qticon@2x.png</file>
- <file>qticon_large.png</file>
+ <file>qticon16.png</file>
+ <file>qticon16@2x.png</file>
+ <file>qticon32.png</file>
+ <file>qticon32@2x.png</file>
+ <file>qticon64.png</file>
</qresource>
</RCC>
diff --git a/tests/manual/highdpi/main.cpp b/tests/manual/highdpi/main.cpp
index fb1e06f0f1..d093569ea8 100644
--- a/tests/manual/highdpi/main.cpp
+++ b/tests/manual/highdpi/main.cpp
@@ -62,16 +62,16 @@ public:
PixmapPainter::PixmapPainter()
{
- pixmap1X = QPixmap(":/qticon.png");
- pixmap2X = QPixmap(":/qticon@2x.png");
- pixmapLarge = QPixmap(":/qticon_large.png");
+ pixmap1X = QPixmap(":/qticon32.png");
+ pixmap2X = QPixmap(":/qticon32@2x.png");
+ pixmapLarge = QPixmap(":/qticon64.png");
- image1X = QImage(":/qticon.png");
- image2X = QImage(":/qticon@2x.png");
- imageLarge = QImage(":/qticon_large.png");
+ image1X = QImage(":/qticon32.png");
+ image2X = QImage(":/qticon32@2x.png");
+ imageLarge = QImage(":/qticon64.png");
- qtIcon.addFile(":/qticon.png");
- qtIcon.addFile(":/qticon@2x.png");
+ qtIcon.addFile(":/qticon32.png");
+ qtIcon.addFile(":/qticon32@2x.png");
}
void PixmapPainter::paintEvent(QPaintEvent *event)
@@ -79,12 +79,12 @@ void PixmapPainter::paintEvent(QPaintEvent *event)
QPainter p(this);
p.fillRect(QRect(QPoint(0, 0), size()), QBrush(Qt::gray));
- int pixmapPointSize = 64;
+ int pixmapPointSize = 32;
int y = 30;
- int dy = 150;
+ int dy = 90;
int x = 10;
- int dx = 80;
+ int dx = 40;
// draw at point
// qDebug() << "paint pixmap" << pixmap1X.devicePixelRatio();
p.drawPixmap(x, y, pixmap1X);
@@ -95,7 +95,7 @@ void PixmapPainter::paintEvent(QPaintEvent *event)
x+=dx;p.drawImage(x, y, image2X);
x+=dx;p.drawImage(x, y, imageLarge);
- // draw at 64x64 rect
+ // draw at 32x32 rect
y+=dy;
x = 10;
p.drawPixmap(QRect(x, y, pixmapPointSize, pixmapPointSize), pixmap1X);
@@ -107,7 +107,7 @@ void PixmapPainter::paintEvent(QPaintEvent *event)
x+=dx;p.drawImage(QRect(x, y, pixmapPointSize, pixmapPointSize), imageLarge);
- // draw at 128x128 rect
+ // draw at 64x64 rect
y+=dy - 50;
x = 10;
p.drawPixmap(QRect(x, y, pixmapPointSize * 2, pixmapPointSize * 2), pixmap1X);
@@ -132,12 +132,12 @@ public:
Labels::Labels()
{
- pixmap1X = QPixmap(":/qticon.png");
- pixmap2X = QPixmap(":/qticon@2x.png");
- pixmapLarge = QPixmap(":/qticon_large.png");
+ pixmap1X = QPixmap(":/qticon32.png");
+ pixmap2X = QPixmap(":/qticon32@2x.png");
+ pixmapLarge = QPixmap(":/qticon64.png");
- qtIcon.addFile(":/qticon.png");
- qtIcon.addFile(":/qticon@2x.png");
+ qtIcon.addFile(":/qticon32.png");
+ qtIcon.addFile(":/qticon32@2x.png");
setWindowIcon(qtIcon);
setWindowTitle("Labels");
@@ -146,15 +146,15 @@ Labels::Labels()
QLabel *label2x = new QLabel();
label2x->setPixmap(pixmap2X);
QLabel *labelIcon = new QLabel();
- labelIcon->setPixmap(qtIcon.pixmap(QSize(64,64)));
+ labelIcon->setPixmap(qtIcon.pixmap(QSize(32,32)));
QLabel *labelLarge = new QLabel();
labelLarge->setPixmap(pixmapLarge);
QHBoxLayout *layout = new QHBoxLayout(this);
-// layout->addWidget(label1x); //expected low-res on high-dpi displays
- layout->addWidget(label2x);
-// layout->addWidget(labelIcon);
-// layout->addWidget(labelLarge); // expected large size and low-res
+ layout->addWidget(label1x); //expected low-res on high-dpi displays
+ layout->addWidget(label2x); //expected high-res on high-dpi displays
+ layout->addWidget(labelIcon); //expected high-res on high-dpi displays
+ layout->addWidget(labelLarge); // expected large size and low-res
setLayout(layout);
}
@@ -172,16 +172,14 @@ public:
MainWindow::MainWindow()
{
- qtIcon.addFile(":/qticon.png");
- qtIcon.addFile(":/qticon@2x.png");
- qtIcon1x.addFile(":/qticon.png");
- qtIcon2x.addFile(":/qticon@2x.png");
+ // beware that QIcon auto-loads the @2x versions.
+ qtIcon1x.addFile(":/qticon16.png");
+ qtIcon2x.addFile(":/qticon32.png");
setWindowIcon(qtIcon);
setWindowTitle("MainWindow");
fileToolBar = addToolBar(tr("File"));
// fileToolBar->setToolButtonStyle(Qt::ToolButtonTextUnderIcon);
- fileToolBar->addAction(new QAction(qtIcon, QString("1x and 2x"), this));
fileToolBar->addAction(new QAction(qtIcon1x, QString("1x"), this));
fileToolBar->addAction(new QAction(qtIcon2x, QString("2x"), this));
}
@@ -331,36 +329,165 @@ void apiTest()
apiTestdevicePixelRatioSetter<QPixmap>();
}
+// Request and draw an icon at different sizes
+class IconDrawing : public QWidget
+{
+public:
+ QIcon *iconHighDPI;
+ QIcon *iconNormalDpi;
+
+ IconDrawing()
+ {
+ QFile::copy(":/qticon32.png", "/tmp/qticon32-2.png");
+
+ QFile::copy(":/qticon32.png", "/tmp/qticon32.png");
+ QFile::copy(":/qticon32@2x.png", "/tmp/qticon32@2x.png");
+
+ iconHighDPI = new QIcon("/tmp/qticon32.png"); // will auto-load @2x version.
+ iconNormalDpi = new QIcon("/tmp/qticon32-2.png"); // does not have a 2x version.
+ }
+
+ ~IconDrawing()
+ {
+ delete iconHighDPI;
+ delete iconNormalDpi;
+// Qile::
+ }
+
+ void paintEvent(QPaintEvent *event)
+ {
+ int x = 10;
+ int y = 10;
+ int dx = 50;
+ int dy = 50;
+ int maxX = 600;
+ int minSize = 5;
+ int maxSize = 64;
+ int sizeIncrement = 5;
+
+ // Disable high-dpi icons
+ qApp->setAttribute(Qt::AA_UseHighDpiPixmaps, false);
+
+ // normal icon
+ for (int size = minSize; size < maxSize; size += sizeIncrement) {
+ QPainter p(this);
+ p.drawPixmap(x, y, iconNormalDpi->pixmap(size, size));
+ if (x + dx > maxX)
+ y+=dy;
+ x = ((x + dx) % maxX);
+ }
+ x = 10;
+ y+=dy;
+
+ // high-dpi icon
+ for (int size = minSize; size < maxSize; size += sizeIncrement) {
+ QPainter p(this);
+ p.drawPixmap(x, y, iconHighDPI->pixmap(size, size));
+ if (x + dx > maxX)
+ y+=dy;
+ x = ((x + dx) % maxX);
+ }
+
+ x = 10;
+ y+=dy;
+
+ // Enable high-dpi icons
+ qApp->setAttribute(Qt::AA_UseHighDpiPixmaps, true);
+
+ // normal icon
+ for (int size = minSize; size < maxSize; size += sizeIncrement) {
+ QPainter p(this);
+ p.drawPixmap(x, y, iconNormalDpi->pixmap(size, size));
+ if (x + dx > maxX)
+ y+=dy;
+ x = ((x + dx) % maxX);
+ }
+ x = 10;
+ y+=dy;
+
+ // high-dpi icon (draw point)
+ for (int size = minSize; size < maxSize; size += sizeIncrement) {
+ QPainter p(this);
+ p.drawPixmap(x, y, iconHighDPI->pixmap(size, size));
+ if (x + dx > maxX)
+ y+=dy;
+ x = ((x + dx) % maxX);
+ }
+
+ x = 10;
+ y+=dy;
+
+ };
+};
+
+// Icons on buttons
+class Buttons : public QWidget
+{
+public:
+ Buttons()
+ {
+ QIcon icon;
+ icon.addFile(":/qticon16@2x.png");
+
+ QPushButton *button = new QPushButton(this);
+ button->setIcon(icon);
+ button->setText("16@2x");
+
+ QTabBar *tab = new QTabBar(this);
+ tab->addTab(QIcon(":/qticon16.png"), "16@1x");
+ tab->addTab(QIcon(":/qticon16@2x.png"), "16@2x");
+ tab->addTab(QIcon(":/qticon16.png"), "");
+ tab->addTab(QIcon(":/qticon16@2x.png"), "");
+ tab->move(10, 100);
+ tab->show();
+
+ QToolBar *toolBar = new QToolBar(this);
+ toolBar->addAction(QIcon(":/qticon16.png"), "16");
+ toolBar->addAction(QIcon(":/qticon16@2x.png"), "16@2x");
+ toolBar->addAction(QIcon(":/qticon32.png"), "32");
+ toolBar->addAction(QIcon(":/qticon32@2x.png"), "32@2x");
+
+ toolBar->move(10, 200);
+ toolBar->show();
+ }
+};
+
+
int main(int argc, char **argv)
{
- qputenv("QT_HIGHDPI_AWARE", "1");
QApplication app(argc, argv);
+ qApp->setAttribute(Qt::AA_UseHighDpiPixmaps);
PixmapPainter pixmapPainter;
-
-// Enable for lots of pixmap drawing
pixmapPainter.show();
Labels label;
label.resize(200, 200);
- label.show();
+// label.show();
MainWindow mainWindow;
- mainWindow.show();
+// mainWindow.show();
StandardIcons icons;
icons.resize(510, 510);
- icons.show();
+// icons.show();
Caching caching;
caching.resize(300, 300);
- caching.show();
+// caching.show();
Style style;
- style.show();
+// style.show();
Fonts fonts;
- fonts.show();
+// fonts.show();
+
+ IconDrawing iconDrawing;
+// iconDrawing.show();
+
+ Buttons buttons;
+// buttons.show();
+
return app.exec();
}
diff --git a/tests/manual/highdpi/qticon16.png b/tests/manual/highdpi/qticon16.png
new file mode 100644
index 0000000000..b6b01a4d64
--- /dev/null
+++ b/tests/manual/highdpi/qticon16.png
Binary files differ
diff --git a/tests/manual/highdpi/qticon16@2x.png b/tests/manual/highdpi/qticon16@2x.png
new file mode 100644
index 0000000000..205461daf0
--- /dev/null
+++ b/tests/manual/highdpi/qticon16@2x.png
Binary files differ
diff --git a/tests/manual/highdpi/qticon32.png b/tests/manual/highdpi/qticon32.png
new file mode 100644
index 0000000000..205461daf0
--- /dev/null
+++ b/tests/manual/highdpi/qticon32.png
Binary files differ
diff --git a/tests/manual/highdpi/qticon.png b/tests/manual/highdpi/qticon32@2x.png
index 76f02c6c96..76f02c6c96 100644
--- a/tests/manual/highdpi/qticon.png
+++ b/tests/manual/highdpi/qticon32@2x.png
Binary files differ
diff --git a/tests/manual/highdpi/qticon64.png b/tests/manual/highdpi/qticon64.png
new file mode 100644
index 0000000000..76f02c6c96
--- /dev/null
+++ b/tests/manual/highdpi/qticon64.png
Binary files differ
diff --git a/tests/manual/highdpi/qticon@2x.png b/tests/manual/highdpi/qticon@2x.png
deleted file mode 100644
index 0b00c00c96..0000000000
--- a/tests/manual/highdpi/qticon@2x.png
+++ /dev/null
Binary files differ
diff --git a/tests/manual/highdpi/qticon_large.png b/tests/manual/highdpi/qticon_large.png
deleted file mode 100644
index 0b00c00c96..0000000000
--- a/tests/manual/highdpi/qticon_large.png
+++ /dev/null
Binary files differ
diff --git a/tests/manual/inputmethodhints/inputmethodhints.h b/tests/manual/inputmethodhints/inputmethodhints.h
index 09c6ca41f5..da1262da39 100644
--- a/tests/manual/inputmethodhints/inputmethodhints.h
+++ b/tests/manual/inputmethodhints/inputmethodhints.h
@@ -42,7 +42,7 @@
#ifndef INPUTMETHODHINTS_H
#define INPUTMETHODHINTS_H
-#include <QtWidgets/QMainWindow>
+#include <QMainWindow>
#include "ui_inputmethodhints.h"
class inputmethodhints : public QMainWindow
@@ -52,7 +52,7 @@ class inputmethodhints : public QMainWindow
public:
inputmethodhints(QWidget *parent = 0);
~inputmethodhints();
-
+
public slots:
void checkboxChanged(int);
diff --git a/tests/manual/inputmethodhints/main.cpp b/tests/manual/inputmethodhints/main.cpp
index c96dc65633..fc294dfc43 100644
--- a/tests/manual/inputmethodhints/main.cpp
+++ b/tests/manual/inputmethodhints/main.cpp
@@ -41,7 +41,6 @@
#include "inputmethodhints.h"
-#include <QtWidgets>
#include <QApplication>
int main(int argc, char *argv[])
diff --git a/tests/manual/keypadnavigation/main.cpp b/tests/manual/keypadnavigation/main.cpp
index c631288d60..71a0072fba 100644
--- a/tests/manual/keypadnavigation/main.cpp
+++ b/tests/manual/keypadnavigation/main.cpp
@@ -39,7 +39,14 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QMainWindow>
+#include <QApplication>
+#include <QColorDialog>
+#include <QFileDialog>
+#include <QFontDialog>
+#include <QInputDialog>
+#include <QMessageBox>
+#include <QSignalMapper>
#include "ui_keypadnavigation.h"
class KeypadNavigation : public QMainWindow
diff --git a/tests/manual/lance/lance.pro b/tests/manual/lance/lance.pro
index 177ca0e40e..430c9196e6 100644
--- a/tests/manual/lance/lance.pro
+++ b/tests/manual/lance/lance.pro
@@ -1,5 +1,6 @@
LANCELOT_DIR = $$PWD/../../auto/other/lancelot
CONFIG+=console moc
+CONFIG -= app_bundle
TEMPLATE = app
INCLUDEPATH += . $$LANCELOT_DIR
QT += core-private gui-private widgets printsupport
diff --git a/tests/manual/manual.pro b/tests/manual/manual.pro
index 525f596d0e..5a974842a4 100644
--- a/tests/manual/manual.pro
+++ b/tests/manual/manual.pro
@@ -20,6 +20,7 @@ qlocale \
qnetworkaccessmanager/qget \
qnetworkconfigurationmanager \
qnetworkreply \
+qpainfo \
qscreen \
qssloptions \
qtabletevent \
@@ -34,11 +35,17 @@ windowflags \
windowgeometry \
windowmodality \
widgetgrab \
+xembed-raster \
+xembed-widgets \
dialogs
!contains(QT_CONFIG, openssl):!contains(QT_CONFIG, openssl-linked):SUBDIRS -= qssloptions
-# disable some tests on wince because of missing dependencies
-wince*:SUBDIRS -= \
- lance windowmodality \
- network_remote_stresstest network_stresstest
+win32 {
+ SUBDIRS -= network_remote_stresstest network_stresstest
+ # disable some tests on wince because of missing dependencies
+ wince*:SUBDIRS -= lance windowmodality
+}
+
+lessThan(QT_MAJOR_VERSION, 5): SUBDIRS -= bearerex lance qnetworkaccessmanager/qget qnetworkreply \
+qpainfo qscreen socketengine xembed-raster xembed-widgets
diff --git a/tests/manual/qcursor/allcursors/main.cpp b/tests/manual/qcursor/allcursors/main.cpp
index 5a9a172a2d..247841de31 100644
--- a/tests/manual/qcursor/allcursors/main.cpp
+++ b/tests/manual/qcursor/allcursors/main.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include <QtWidgets/QApplication>
+#include <QApplication>
#include "mainwindow.h"
int main(int argc, char *argv[])
diff --git a/tests/manual/qcursor/allcursors/mainwindow.h b/tests/manual/qcursor/allcursors/mainwindow.h
index 4b7dc91a18..9c6adcaddd 100644
--- a/tests/manual/qcursor/allcursors/mainwindow.h
+++ b/tests/manual/qcursor/allcursors/mainwindow.h
@@ -42,7 +42,7 @@
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
-#include <QtWidgets/QMainWindow>
+#include <QMainWindow>
class QTimer;
diff --git a/tests/manual/qcursor/grab_override/main.cpp b/tests/manual/qcursor/grab_override/main.cpp
index 5a9a172a2d..247841de31 100644
--- a/tests/manual/qcursor/grab_override/main.cpp
+++ b/tests/manual/qcursor/grab_override/main.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include <QtWidgets/QApplication>
+#include <QApplication>
#include "mainwindow.h"
int main(int argc, char *argv[])
diff --git a/tests/manual/qcursor/grab_override/mainwindow.h b/tests/manual/qcursor/grab_override/mainwindow.h
index c105e22850..31ecaee43f 100644
--- a/tests/manual/qcursor/grab_override/mainwindow.h
+++ b/tests/manual/qcursor/grab_override/mainwindow.h
@@ -42,7 +42,7 @@
#ifndef MAINWINDOW_H
#define MAINWINDOW_H
-#include <QtWidgets/QMainWindow>
+#include <QMainWindow>
class QTimer;
@@ -64,11 +64,11 @@ private slots:
private:
void keyPressEvent(QKeyEvent* event);
-
+
Ui::MainWindow *ui;
QTimer *timer;
int override;
-
+
QCursor ccurs;
QCursor bcurs;
};
diff --git a/tests/manual/qdesktopwidget/main.cpp b/tests/manual/qdesktopwidget/main.cpp
index 3873a6a1e1..1a10cbfbd2 100644
--- a/tests/manual/qdesktopwidget/main.cpp
+++ b/tests/manual/qdesktopwidget/main.cpp
@@ -39,7 +39,11 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QGraphicsView>
+#include <QGraphicsRectItem>
+#include <QDesktopWidget>
+#include <QApplication>
+#include <QDebug>
class DesktopView : public QGraphicsView
{
diff --git a/tests/manual/qgraphicsitem/main.cpp b/tests/manual/qgraphicsitem/main.cpp
index 84364e6bc0..e21baa3d18 100644
--- a/tests/manual/qgraphicsitem/main.cpp
+++ b/tests/manual/qgraphicsitem/main.cpp
@@ -39,11 +39,11 @@
**
****************************************************************************/
-#include <QtWidgets/QApplication>
-#include <QtWidgets/QGraphicsView>
-#include <QtWidgets/QGraphicsScene>
-#include <QtWidgets/QGraphicsItem>
-#include <QtWidgets/QMessageBox>
+#include <QApplication>
+#include <QGraphicsView>
+#include <QGraphicsScene>
+#include <QGraphicsItem>
+#include <QMessageBox>
class MyObject : public QObject
{
diff --git a/tests/manual/qgraphicsitemgroup/main.cpp b/tests/manual/qgraphicsitemgroup/main.cpp
index 97dbafd059..75f36e54af 100644
--- a/tests/manual/qgraphicsitemgroup/main.cpp
+++ b/tests/manual/qgraphicsitemgroup/main.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include <QtWidgets/QApplication>
+#include <QApplication>
#include "widget.h"
int main(int argc, char *argv[])
diff --git a/tests/manual/qgraphicslayout/flicker/main.cpp b/tests/manual/qgraphicslayout/flicker/main.cpp
index 4b6589f9f8..2f4140e39a 100644
--- a/tests/manual/qgraphicslayout/flicker/main.cpp
+++ b/tests/manual/qgraphicslayout/flicker/main.cpp
@@ -39,7 +39,8 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QMainWindow>
+#include <QApplication>
#include "window.h"
int main(int argc, char **argv)
diff --git a/tests/manual/qgraphicslayout/flicker/window.h b/tests/manual/qgraphicslayout/flicker/window.h
index 3a0eb77fcc..190e9c4890 100644
--- a/tests/manual/qgraphicslayout/flicker/window.h
+++ b/tests/manual/qgraphicslayout/flicker/window.h
@@ -43,7 +43,21 @@
#define WINDOW_H
-#include <QtWidgets>
+#include <QGraphicsScene>
+#include <QGraphicsWidget>
+#include <QGraphicsLinearLayout>
+#include <QGraphicsView>
+#include <QSpinBox>
+#include <QCheckBox>
+#include <QPushButton>
+#include <QLabel>
+#include <QHBoxLayout>
+#include <QPainter>
+#include <QApplication>
+#include <QThread>
+#include <QMap>
+#include <QTime>
+#include <QDebug>
struct Statistics {
Statistics() : setGeometryCount(0), sleepMsecs(0), output(0),
@@ -57,7 +71,11 @@ struct Statistics {
QLabel *output;
void sleep()
{
+#if QT_VERSION >= 0x050000
QThread::msleep(sleepMsecs);
+#else
+ qWarning("%s unimplemented", Q_FUNC_INFO);
+#endif
}
int currentBenchmarkIteration;
bool relayoutClicked;
diff --git a/tests/manual/qimagereader/main.cpp b/tests/manual/qimagereader/main.cpp
index ea33ef1e01..4dc41ac542 100644
--- a/tests/manual/qimagereader/main.cpp
+++ b/tests/manual/qimagereader/main.cpp
@@ -39,7 +39,12 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QWidget>
+#include <QHBoxLayout>
+#include <QApplication>
+#include <QPainter>
+#include <QImage>
+#include <QImageReader>
class MyWidget : public QWidget
{
diff --git a/tests/manual/qlocale/calendar.cpp b/tests/manual/qlocale/calendar.cpp
index d91e181461..6b3d3c213d 100644
--- a/tests/manual/qlocale/calendar.cpp
+++ b/tests/manual/qlocale/calendar.cpp
@@ -38,10 +38,17 @@
**
****************************************************************************/
-#include <QtWidgets>
-
#include "calendar.h"
+#include <QComboBox>
+#include <QGridLayout>
+#include <QGroupBox>
+#include <QCalendarWidget>
+#include <QLabel>
+#include <QDateEdit>
+#include <QCheckBox>
+#include <QTextCharFormat>
+
CalendarWidget::CalendarWidget()
{
createPreviewGroupBox();
@@ -397,9 +404,9 @@ void CalendarWidget::createTextFormatsGroupBox()
QComboBox *CalendarWidget::createColorComboBox()
{
QComboBox *comboBox = new QComboBox;
- comboBox->addItem(tr("Red"), Qt::red);
- comboBox->addItem(tr("Blue"), Qt::blue);
- comboBox->addItem(tr("Black"), Qt::black);
- comboBox->addItem(tr("Magenta"), Qt::magenta);
+ comboBox->addItem(tr("Red"), QColor(Qt::red));
+ comboBox->addItem(tr("Blue"), QColor(Qt::blue));
+ comboBox->addItem(tr("Black"), QColor(Qt::black));
+ comboBox->addItem(tr("Magenta"), QColor(Qt::magenta));
return comboBox;
}
diff --git a/tests/manual/qlocale/calendar.h b/tests/manual/qlocale/calendar.h
index fd5f2c3931..ec152a7f4e 100644
--- a/tests/manual/qlocale/calendar.h
+++ b/tests/manual/qlocale/calendar.h
@@ -41,7 +41,17 @@
#ifndef CALENDAR_H
#define CALENDAR_H
-#include <QtWidgets>
+#include <QWidget>
+#include <QDate>
+#include <QLocale>
+
+class QComboBox;
+class QGridLayout;
+class QGroupBox;
+class QCalendarWidget;
+class QLabel;
+class QDateEdit;
+class QCheckBox;
class CalendarWidget : public QWidget
{
diff --git a/tests/manual/qlocale/currency.cpp b/tests/manual/qlocale/currency.cpp
index 46d1cd9b29..5be527ae91 100644
--- a/tests/manual/qlocale/currency.cpp
+++ b/tests/manual/qlocale/currency.cpp
@@ -39,6 +39,10 @@
****************************************************************************/
#include "currency.h"
+#include <QLineEdit>
+#include <QLabel>
+#include <QHBoxLayout>
+#include <QLocale>
CurrencyWidget::CurrencyWidget()
{
diff --git a/tests/manual/qlocale/currency.h b/tests/manual/qlocale/currency.h
index 5185a35983..b81a67e51e 100644
--- a/tests/manual/qlocale/currency.h
+++ b/tests/manual/qlocale/currency.h
@@ -41,7 +41,11 @@
#ifndef CURRENCY_H
#define CURRENCY_H
-#include <QtWidgets>
+#include <QWidget>
+#include <QLocale>
+
+class QLabel;
+class QLineEdit;
class CurrencyWidget : public QWidget
{
diff --git a/tests/manual/qlocale/dateformats.cpp b/tests/manual/qlocale/dateformats.cpp
index ffdef0993f..3b523ca863 100644
--- a/tests/manual/qlocale/dateformats.cpp
+++ b/tests/manual/qlocale/dateformats.cpp
@@ -40,6 +40,13 @@
#include "dateformats.h"
+#include <QLineEdit>
+#include <QScrollArea>
+#include <QGridLayout>
+#include <QComboBox>
+#include <QLabel>
+#include <QDateTime>
+
DateFormatsWidget::DateFormatsWidget()
{
scrollArea = new QScrollArea;
diff --git a/tests/manual/qlocale/dateformats.h b/tests/manual/qlocale/dateformats.h
index cd50e14cbc..ae3621403e 100644
--- a/tests/manual/qlocale/dateformats.h
+++ b/tests/manual/qlocale/dateformats.h
@@ -41,7 +41,13 @@
#ifndef DATEFORMATS_H
#define DATEFORMATS_H
-#include <QtWidgets>
+#include <QWidget>
+#include <QLocale>
+
+class QLineEdit;
+class QScrollArea;
+class QGridLayout;
+class QComboBox;
class DateFormatsWidget : public QWidget
{
diff --git a/tests/manual/qlocale/info.cpp b/tests/manual/qlocale/info.cpp
index 229d167209..e3d392fd46 100644
--- a/tests/manual/qlocale/info.cpp
+++ b/tests/manual/qlocale/info.cpp
@@ -40,6 +40,12 @@
#include "info.h"
+#include <QLineEdit>
+#include <QScrollArea>
+#include <QGridLayout>
+#include <QLabel>
+#include <QLocale>
+
InfoWidget::InfoWidget()
{
scrollArea = new QScrollArea;
diff --git a/tests/manual/qlocale/info.h b/tests/manual/qlocale/info.h
index 877151d53d..9657f3264c 100644
--- a/tests/manual/qlocale/info.h
+++ b/tests/manual/qlocale/info.h
@@ -41,7 +41,12 @@
#ifndef INFO_H
#define INFO_H
-#include <QtWidgets>
+#include <QWidget>
+#include <QLocale>
+
+class QLineEdit;
+class QScrollArea;
+class QGridLayout;
class InfoWidget : public QWidget
{
diff --git a/tests/manual/qlocale/languages.cpp b/tests/manual/qlocale/languages.cpp
index 9f285530b7..828b43ae62 100644
--- a/tests/manual/qlocale/languages.cpp
+++ b/tests/manual/qlocale/languages.cpp
@@ -40,6 +40,10 @@
#include "languages.h"
+#include <QLabel>
+#include <QListWidget>
+#include <QHBoxLayout>
+
LanguagesWidget::LanguagesWidget()
{
QVBoxLayout *l = new QVBoxLayout(this);
diff --git a/tests/manual/qlocale/languages.h b/tests/manual/qlocale/languages.h
index b685bd04c3..57fbf456f3 100644
--- a/tests/manual/qlocale/languages.h
+++ b/tests/manual/qlocale/languages.h
@@ -41,7 +41,11 @@
#ifndef LANGUAGES_H
#define LANGUAGES_H
-#include <QtWidgets>
+#include <QWidget>
+#include <QLocale>
+
+class QLabel;
+class QListWidget;
class LanguagesWidget : public QWidget
{
diff --git a/tests/manual/qlocale/main.cpp b/tests/manual/qlocale/main.cpp
index 0ca64d3d7c..cacc0c0181 100644
--- a/tests/manual/qlocale/main.cpp
+++ b/tests/manual/qlocale/main.cpp
@@ -38,7 +38,7 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QApplication>
#include "window.h"
diff --git a/tests/manual/qlocale/miscellaneous.cpp b/tests/manual/qlocale/miscellaneous.cpp
index 374ee588a4..62ebac09e4 100644
--- a/tests/manual/qlocale/miscellaneous.cpp
+++ b/tests/manual/qlocale/miscellaneous.cpp
@@ -40,6 +40,10 @@
#include "miscellaneous.h"
+#include <QLineEdit>
+#include <QVBoxLayout>
+#include <QLabel>
+
MiscWidget::MiscWidget()
{
QGridLayout *l = new QGridLayout;
diff --git a/tests/manual/qlocale/miscellaneous.h b/tests/manual/qlocale/miscellaneous.h
index fe11ecd89b..29543a81e6 100644
--- a/tests/manual/qlocale/miscellaneous.h
+++ b/tests/manual/qlocale/miscellaneous.h
@@ -41,7 +41,11 @@
#ifndef MISCELLANEOUS_H
#define MISCELLANEOUS_H
-#include <QtWidgets>
+#include <QWidget>
+#include <QLocale>
+
+class QLineEdit;
+class QLabel;
class MiscWidget : public QWidget
{
diff --git a/tests/manual/qlocale/numberformats.cpp b/tests/manual/qlocale/numberformats.cpp
index 3882009f81..edab69b48c 100644
--- a/tests/manual/qlocale/numberformats.cpp
+++ b/tests/manual/qlocale/numberformats.cpp
@@ -40,6 +40,12 @@
#include "numberformats.h"
+#include <QGridLayout>
+#include <QLabel>
+#include <QLineEdit>
+#include <QLocale>
+#include <QVBoxLayout>
+
NumberFormatsWidget::NumberFormatsWidget()
{
QGridLayout *l = new QGridLayout;
diff --git a/tests/manual/qlocale/numberformats.h b/tests/manual/qlocale/numberformats.h
index dde5f1fa2c..2a91dd3f81 100644
--- a/tests/manual/qlocale/numberformats.h
+++ b/tests/manual/qlocale/numberformats.h
@@ -41,7 +41,11 @@
#ifndef NUMBERFORMATS_H
#define NUMBERFORMATS_H
-#include <QtWidgets>
+#include <QWidget>
+#include <QLocale>
+
+class QLineEdit;
+class QLabel;
class NumberFormatsWidget : public QWidget
{
diff --git a/tests/manual/qlocale/window.cpp b/tests/manual/qlocale/window.cpp
index 9a2e3e3188..40d1316050 100644
--- a/tests/manual/qlocale/window.cpp
+++ b/tests/manual/qlocale/window.cpp
@@ -40,6 +40,13 @@
#include "window.h"
+#include <QComboBox>
+#include <QLocale>
+#include <QLabel>
+#include <QTabWidget>
+#include <QHBoxLayout>
+#include <QEvent>
+
Window::Window()
{
localeCombo = new QComboBox;
diff --git a/tests/manual/qlocale/window.h b/tests/manual/qlocale/window.h
index b7d3369e57..25b8de0ce5 100644
--- a/tests/manual/qlocale/window.h
+++ b/tests/manual/qlocale/window.h
@@ -41,7 +41,7 @@
#ifndef WINDOW_H
#define WINDOW_H
-#include <QtWidgets>
+#include <QMainWindow>
#include "calendar.h"
#include "currency.h"
@@ -51,6 +51,9 @@
#include "miscellaneous.h"
#include "info.h"
+class QLabel;
+class QComboBox;
+
class Window : public QMainWindow
{
Q_OBJECT
diff --git a/tests/manual/qnetworkreply/main.cpp b/tests/manual/qnetworkreply/main.cpp
index feb07b4c7d..2f47985261 100644
--- a/tests/manual/qnetworkreply/main.cpp
+++ b/tests/manual/qnetworkreply/main.cpp
@@ -49,7 +49,7 @@
#include <QtNetwork/qsslconfiguration.h>
#include "../../auto/network-settings.h"
-#ifdef QT_BUILD_INTERNAL
+#if defined(QT_BUILD_INTERNAL) && !defined(QT_NO_SSL)
#include "private/qsslsocket_p.h"
#endif
@@ -147,6 +147,9 @@ void tst_qnetworkreply::setSslConfiguration_data()
void tst_qnetworkreply::setSslConfiguration()
{
+#ifdef QT_NO_SSL
+ QSKIP("SSL is not enabled.");
+#else
QFETCH(QUrl, url);
QNetworkRequest request(url);
QSslConfiguration conf = request.sslConfiguration();
@@ -171,6 +174,7 @@ void tst_qnetworkreply::setSslConfiguration()
QCOMPARE(reply->error(), QNetworkReply::SslHandshakeFailedError);
}
#endif
+#endif // QT_NO_SSL
}
QTEST_MAIN(tst_qnetworkreply)
diff --git a/tests/manual/qpainfo/main.cpp b/tests/manual/qpainfo/main.cpp
new file mode 100644
index 0000000000..6b712304a0
--- /dev/null
+++ b/tests/manual/qpainfo/main.cpp
@@ -0,0 +1,220 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QGuiApplication>
+#include <QStyleHints>
+#include <QLibraryInfo>
+#include <private/qguiapplication_p.h>
+#include <qpa/qplatformintegration.h>
+#include <qpa/qplatformtheme.h>
+#include <QScreen>
+#include <QStringList>
+#include <QVariant>
+#include <QFont>
+#include <QSysInfo>
+#include <QLibraryInfo>
+#include <QStandardPaths>
+#include <QDir>
+
+#include <iostream>
+#include <string>
+
+std::ostream &operator<<(std::ostream &str, const QSize &s)
+{
+ str << s.width() << 'x' << s.height();
+ return str;
+}
+
+std::ostream &operator<<(std::ostream &str, const QSizeF &s)
+{
+ str << s.width() << 'x' << s.height();
+ return str;
+}
+
+std::ostream &operator<<(std::ostream &str, const QRect &r)
+{
+ str << r.size() << '+' << r.x() << '+' << r.y();
+ return str;
+}
+
+std::ostream &operator<<(std::ostream &str, const QStringList &l)
+{
+ for (int i = 0; i < l.size(); ++i) {
+ if (i)
+ str << ',';
+ str << l.at(i).toStdString();
+ }
+ return str;
+}
+
+static QStringList toNativeSeparators(QStringList in)
+{
+ for (int i = 0; i < in.size(); ++i)
+ in[i] = QDir::toNativeSeparators(in.at(i));
+ return in;
+}
+
+#define DUMP_CAPABILITY(integration, capability) \
+ if (platformIntegration->hasCapability(QPlatformIntegration::capability)) \
+ std::cout << ' ' << #capability;
+
+#define DUMP_STANDARDPATH(location) \
+ std::cout << " " << #location << ": \"" \
+ << QStandardPaths::displayName(QStandardPaths::location).toStdString() << '"' \
+ << ' ' << toNativeSeparators(QStandardPaths::standardLocations(QStandardPaths::location)) << '\n';
+
+#define DUMP_LIBRARYPATH(loc) \
+ std::cout << " " << #loc << ": " << QDir::toNativeSeparators(QLibraryInfo::location(QLibraryInfo::loc)).toStdString() << '\n';
+
+int main(int argc, char **argv)
+{
+ QGuiApplication app(argc, argv);
+
+ const QPlatformIntegration *platformIntegration = QGuiApplicationPrivate::platformIntegration();
+ std::cout << "Qt " << QT_VERSION_STR << " on \"" << QGuiApplication::platformName().toStdString() << "\" "
+ << QSysInfo::WordSize << " bit/"
+ << (QSysInfo::ByteOrder == QSysInfo::LittleEndian ? "little endian" : "big endian") << '/'
+ << (QLibraryInfo::isDebugBuild() ? "debug" : "release")
+ << '\n';
+
+#if defined(Q_OS_WIN)
+ std::cout << std::hex << "Windows version: 0x" << QSysInfo::windowsVersion() << std::dec << '\n';
+#elif defined(Q_OS_MAC)
+ std::cout << std::hex << "Mac OS version: 0x" << QSysInfo::macVersion() << std::dec << '\n';
+#endif
+
+ std::cout << "\nLibrary info:\n";
+ DUMP_LIBRARYPATH(PrefixPath)
+ DUMP_LIBRARYPATH(DocumentationPath)
+ DUMP_LIBRARYPATH(HeadersPath)
+ DUMP_LIBRARYPATH(LibrariesPath)
+ DUMP_LIBRARYPATH(LibraryExecutablesPath)
+ DUMP_LIBRARYPATH(BinariesPath)
+ DUMP_LIBRARYPATH(PluginsPath)
+ DUMP_LIBRARYPATH(ImportsPath)
+ DUMP_LIBRARYPATH(Qml2ImportsPath)
+ DUMP_LIBRARYPATH(ArchDataPath)
+ DUMP_LIBRARYPATH(DataPath)
+ DUMP_LIBRARYPATH(TranslationsPath)
+ DUMP_LIBRARYPATH(ExamplesPath)
+ DUMP_LIBRARYPATH(TestsPath)
+
+ std::cout << "\nStandard paths:\n";
+ DUMP_STANDARDPATH(DesktopLocation)
+ DUMP_STANDARDPATH(DocumentsLocation)
+ DUMP_STANDARDPATH(FontsLocation)
+ DUMP_STANDARDPATH(ApplicationsLocation)
+ DUMP_STANDARDPATH(MusicLocation)
+ DUMP_STANDARDPATH(MoviesLocation)
+ DUMP_STANDARDPATH(PicturesLocation)
+ DUMP_STANDARDPATH(TempLocation)
+ DUMP_STANDARDPATH(HomeLocation)
+ DUMP_STANDARDPATH(DataLocation)
+ DUMP_STANDARDPATH(CacheLocation)
+ DUMP_STANDARDPATH(GenericDataLocation)
+ DUMP_STANDARDPATH(RuntimeLocation)
+ DUMP_STANDARDPATH(ConfigLocation)
+ DUMP_STANDARDPATH(DownloadLocation)
+ DUMP_STANDARDPATH(GenericCacheLocation)
+
+ std::cout << "\nPlatform capabilities:";
+ DUMP_CAPABILITY(platformIntegration, ThreadedPixmaps)
+ DUMP_CAPABILITY(platformIntegration, OpenGL)
+ DUMP_CAPABILITY(platformIntegration, ThreadedOpenGL)
+ DUMP_CAPABILITY(platformIntegration, SharedGraphicsCache)
+ DUMP_CAPABILITY(platformIntegration, BufferQueueingOpenGL)
+ DUMP_CAPABILITY(platformIntegration, WindowMasks)
+ DUMP_CAPABILITY(platformIntegration, MultipleWindows)
+ DUMP_CAPABILITY(platformIntegration, ApplicationState)
+ DUMP_CAPABILITY(platformIntegration, ForeignWindows)
+ std::cout << '\n';
+
+ const QStyleHints *styleHints = QGuiApplication::styleHints();
+ std::cout << "\nStyle hints: mouseDoubleClickInterval=" << styleHints->mouseDoubleClickInterval() << " startDragDistance="
+ << styleHints->startDragDistance() << " startDragTime=" << styleHints->startDragTime()
+ << " startDragVelocity=" << styleHints->startDragVelocity() << " keyboardInputInterval=" << styleHints->keyboardInputInterval()
+ << " keyboardAutoRepeatRate=" << styleHints->keyboardAutoRepeatRate() << " cursorFlashTime=" << styleHints->cursorFlashTime()
+ << " showIsFullScreen=" << styleHints->showIsFullScreen() << " passwordMaskDelay=" << styleHints->passwordMaskDelay()
+ << " fontSmoothingGamma=" << styleHints->fontSmoothingGamma() << " useRtlExtensions=" << styleHints->useRtlExtensions() << '\n';
+
+ const QPlatformTheme *platformTheme = QGuiApplicationPrivate::platformTheme();
+ std::cout << "\nTheme:\n Styles: " << platformTheme->themeHint(QPlatformTheme::StyleNames).toStringList();
+ const QString iconTheme = platformTheme->themeHint(QPlatformTheme::SystemIconThemeName).toString();
+ if (!iconTheme.isEmpty()) {
+ std::cout << "\n Icon theme: " << iconTheme.toStdString()
+ << ", " << platformTheme->themeHint(QPlatformTheme::SystemIconFallbackThemeName).toString().toStdString()
+ << " from " << platformTheme->themeHint(QPlatformTheme::IconThemeSearchPaths).toStringList() << '\n';
+ }
+ if (const QFont *systemFont = platformTheme->font())
+ std::cout << " System font: \"" << systemFont->family().toStdString() << "\" " << systemFont->pointSize() << '\n';
+ if (platformTheme->usePlatformNativeDialog(QPlatformTheme::FileDialog))
+ std::cout << " Native file dialog\n";
+ if (platformTheme->usePlatformNativeDialog(QPlatformTheme::ColorDialog))
+ std::cout << " Native color dialog\n";
+ if (platformTheme->usePlatformNativeDialog(QPlatformTheme::FontDialog))
+ std::cout << " Native font dialog\n";
+
+ const QList<QScreen*> screens = QGuiApplication::screens();
+ const int screenCount = screens.size();
+ std::cout << "\nScreens: " << screenCount << '\n';
+ for (int s = 0; s < screenCount; ++s) {
+ const QScreen *screen = screens.at(s);
+ std::cout << (screen == QGuiApplication::primaryScreen() ? '*' : ' ')
+ << '#' << ' ' << s << " \"" << screen->name().toStdString() << '"'
+ << "\n Geometry: " << screen->geometry() << " Available: " << screen->availableGeometry();
+ if (screen->geometry() != screen->virtualGeometry())
+ std::cout << "\n Virtual geometry: " << screen->virtualGeometry() << " Available: " << screen->availableVirtualGeometry();
+ if (screen->virtualSiblings().size() > 1)
+ std::cout << "\n " << screen->virtualSiblings().size() << " virtual siblings";
+ std::cout << "\n Physical size: " << screen->physicalSize() << " mm"
+ << " Refresh: " << screen->refreshRate() << " Hz"
+ << "\n Physical DPI: " << screen->physicalDotsPerInchX()
+ << ',' << screen->physicalDotsPerInchY()
+ << " Logical DPI: " << screen->logicalDotsPerInchX()
+ << ',' << screen->logicalDotsPerInchY()
+ << "\n DevicePixelRatio: " << screen->devicePixelRatio()
+ << " Primary orientation: " << screen->primaryOrientation()
+ << "\n Orientation: " << screen->orientation()
+ << " OrientationUpdateMask: " << screen->orientationUpdateMask()
+ << "\n\n";
+ }
+ return 0;
+}
diff --git a/tests/manual/qpainfo/qpainfo.pro b/tests/manual/qpainfo/qpainfo.pro
new file mode 100644
index 0000000000..374f951300
--- /dev/null
+++ b/tests/manual/qpainfo/qpainfo.pro
@@ -0,0 +1,7 @@
+TEMPLATE = app
+TARGET = qpainfo
+CONFIG+=console
+CONFIG -= app_bundle
+QT = core-private gui-private
+
+SOURCES += main.cpp
diff --git a/tests/manual/qtbug-8933/main.cpp b/tests/manual/qtbug-8933/main.cpp
index 97dbafd059..75f36e54af 100644
--- a/tests/manual/qtbug-8933/main.cpp
+++ b/tests/manual/qtbug-8933/main.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include <QtWidgets/QApplication>
+#include <QApplication>
#include "widget.h"
int main(int argc, char *argv[])
diff --git a/tests/manual/qtouchevent/main.cpp b/tests/manual/qtouchevent/main.cpp
index e0bd9ad063..7c1ed81c37 100644
--- a/tests/manual/qtouchevent/main.cpp
+++ b/tests/manual/qtouchevent/main.cpp
@@ -39,7 +39,7 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QApplication>
#include <QtTest>
#include "ui_form.h"
@@ -55,6 +55,7 @@ public:
{
setAttribute(Qt::WA_QuitOnClose, false);
setupUi(this);
+ setWindowTitle(QT_VERSION_STR);
}
void closeEvent(QCloseEvent *event)
diff --git a/tests/manual/qtouchevent/qtouchevent.pro b/tests/manual/qtouchevent/qtouchevent.pro
index aa4339f693..6a1ca85335 100644
--- a/tests/manual/qtouchevent/qtouchevent.pro
+++ b/tests/manual/qtouchevent/qtouchevent.pro
@@ -1,4 +1,5 @@
-QT += widgets testlib
+QT += testlib
+greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
SOURCES = main.cpp \
touchwidget.cpp
FORMS += form.ui
diff --git a/tests/manual/qtouchevent/touchwidget.cpp b/tests/manual/qtouchevent/touchwidget.cpp
index 68206aad22..e2834203f7 100644
--- a/tests/manual/qtouchevent/touchwidget.cpp
+++ b/tests/manual/qtouchevent/touchwidget.cpp
@@ -122,7 +122,7 @@ bool TouchWidget::event(QEvent *event)
case QEvent::MouseButtonRelease:
seenMouseRelease = true;
if (closeWindowOnMouseRelease)
- window()->close();
+ window()->close();
if (acceptMouseRelease) {
event->accept();
return true;
diff --git a/tests/manual/qwidget_zorder/main.cpp b/tests/manual/qwidget_zorder/main.cpp
index 7697cc1794..7773ecef9c 100644
--- a/tests/manual/qwidget_zorder/main.cpp
+++ b/tests/manual/qwidget_zorder/main.cpp
@@ -39,7 +39,11 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QApplication>
+#include <QPushButton>
+#include <QPlainTextEdit>
+#include <QCalendarWidget>
+#include <QVBoxLayout>
class Widget : public QWidget
{
diff --git a/tests/manual/repaint/mainwindow/main.cpp b/tests/manual/repaint/mainwindow/main.cpp
index 173f81de06..abf5857afc 100644
--- a/tests/manual/repaint/mainwindow/main.cpp
+++ b/tests/manual/repaint/mainwindow/main.cpp
@@ -39,7 +39,14 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QApplication>
+#include <QMainWindow>
+#include <QToolBar>
+#include <QDockWidget>
+#include <QStatusBar>
+#include <QSpinBox>
+#include <QAction>
+
#include "../shared/shared.h"
int main(int argc, char **argv)
@@ -47,16 +54,16 @@ int main(int argc, char **argv)
QApplication app(argc, argv);
QMainWindow mainWindow;
-
+
mainWindow.setCentralWidget(new StaticWidget());
mainWindow.setStatusBar(new QStatusBar());
-
+
QDockWidget *dockWidget = new QDockWidget();
dockWidget->setWidget(new StaticWidget());
mainWindow.addDockWidget(Qt::LeftDockWidgetArea, dockWidget);
-
+
QToolBar *toolBar = new QToolBar();
-
+
toolBar->addWidget(new StaticWidget())->setVisible(true);;
toolBar->addWidget(new QSpinBox())->setVisible(true);;
@@ -64,6 +71,6 @@ int main(int argc, char **argv)
mainWindow.resize(600, 400);
mainWindow.show();
-
+
return app.exec();
}
diff --git a/tests/manual/repaint/scrollarea/main.cpp b/tests/manual/repaint/scrollarea/main.cpp
index 44b43c30f7..dbe5cab893 100644
--- a/tests/manual/repaint/scrollarea/main.cpp
+++ b/tests/manual/repaint/scrollarea/main.cpp
@@ -39,9 +39,11 @@
**
****************************************************************************/
-#include <QtWidgets>
-#include "../shared/shared.h"
+#include <QApplication>
+#include <QMainWindow>
+#include <QScrollArea>
+#include "../shared/shared.h"
int main(int argc, char **argv)
{
@@ -57,8 +59,7 @@ int main(int argc, char **argv)
scrollView.resize(600, 400);
scrollView.show();
-
-
+
return app.exec();
}
diff --git a/tests/manual/repaint/shared/shared.h b/tests/manual/repaint/shared/shared.h
index 8cc5a61aca..8550e6e907 100644
--- a/tests/manual/repaint/shared/shared.h
+++ b/tests/manual/repaint/shared/shared.h
@@ -39,7 +39,11 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QWidget>
+#include <QPainter>
+#include <QMouseEvent>
+#include <QDebug>
+
class StaticWidget : public QWidget
{
Q_OBJECT
diff --git a/tests/manual/repaint/splitter/main.cpp b/tests/manual/repaint/splitter/main.cpp
index 5ee1e19402..44f76eae2c 100644
--- a/tests/manual/repaint/splitter/main.cpp
+++ b/tests/manual/repaint/splitter/main.cpp
@@ -39,9 +39,12 @@
**
****************************************************************************/
-#include <QtWidgets>
#include "../shared/shared.h"
+#include <QApplication>
+#include <QMainWindow>
+#include <QSplitter>
+
int main(int argc, char **argv)
{
QApplication app(argc, argv);
@@ -53,6 +56,6 @@ int main(int argc, char **argv)
splitter.resize(600, 400);
splitter.show();
-
+
return app.exec();
}
diff --git a/tests/manual/repaint/tableview/main.cpp b/tests/manual/repaint/tableview/main.cpp
index 442b1668e0..c26c1264d7 100644
--- a/tests/manual/repaint/tableview/main.cpp
+++ b/tests/manual/repaint/tableview/main.cpp
@@ -39,13 +39,17 @@
**
****************************************************************************/
-#include <QtWidgets>
#include "../shared/shared.h"
+#include <QApplication>
+#include <QMainWindow>
+#include <QTableWidget>
+#include <QPaintEvent>
+
class CellWidget : public QWidget
{
public:
- CellWidget (QWidget *parent = 0) : QWidget(parent) { }
+ CellWidget(QWidget *parent = 0) : QWidget(parent) {}
void paintEvent(QPaintEvent * event)
{
static int value = 200;
@@ -69,8 +73,7 @@ int main(int argc, char **argv)
tableWidget.setCellWidget(row, col, new CellWidget());
tableWidget.resize(400, 600);
tableWidget.show();
-
-
+
return app.exec();
}
diff --git a/tests/manual/repaint/task141091/main.cpp b/tests/manual/repaint/task141091/main.cpp
index d2b0f76606..d8a37299be 100644
--- a/tests/manual/repaint/task141091/main.cpp
+++ b/tests/manual/repaint/task141091/main.cpp
@@ -39,17 +39,20 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QApplication>
+#include <QMainWindow>
+#include <QPaintEvent>
#include <QDebug>
class MyWidget : public QWidget
{
public:
- MyWidget() : QWidget() {
-
-
+ MyWidget() : QWidget()
+ {
setAttribute(Qt::WA_OpaquePaintEvent);
- setAttribute(Qt::WA_StaticContents); }
+ setAttribute(Qt::WA_StaticContents);
+ }
+
protected:
void paintEvent(QPaintEvent *e) { qDebug() << e->rect(); }
};
@@ -60,4 +63,4 @@ int main(int argc, char **argv)
MyWidget w;
w.show();
return a.exec();
-} \ No newline at end of file
+}
diff --git a/tests/manual/repaint/toplevel/main.cpp b/tests/manual/repaint/toplevel/main.cpp
index 006da2635f..fd2902f21b 100644
--- a/tests/manual/repaint/toplevel/main.cpp
+++ b/tests/manual/repaint/toplevel/main.cpp
@@ -39,9 +39,10 @@
**
****************************************************************************/
-#include <QtWidgets>
#include "../shared/shared.h"
+#include <QApplication>
+
int main(int argc, char **argv)
{
QApplication app(argc, argv);
diff --git a/tests/manual/repaint/widget/main.cpp b/tests/manual/repaint/widget/main.cpp
index 520b3e22f5..e2370abf3e 100644
--- a/tests/manual/repaint/widget/main.cpp
+++ b/tests/manual/repaint/widget/main.cpp
@@ -39,9 +39,11 @@
**
****************************************************************************/
-#include <QtWidgets>
#include "../shared/shared.h"
+#include <QApplication>
+#include <QPushButton>
+
class Child : public StaticWidget
{
Q_OBJECT
@@ -108,24 +110,24 @@ protected:
QPushButton * resizeButton;
QPushButton * movebutton;
QPushButton * moveResizebutton;
- QPushButton * scrollbutton;
+ QPushButton * scrollbutton;
};
int main(int argc, char **argv)
{
QApplication app(argc, argv);
-
+
TopLevel bc;
bc.resize(500, 500);
c = new Child(&bc);
c->move(100, 100);
c->resize(100, 100);
-
+
QWidget *gc = new StaticWidget(c);
gc->move(20, 20);
gc->resize(50,50);
-
+
bc.show();
return app.exec();
diff --git a/tests/manual/textrendering/glyphshaping/main.cpp b/tests/manual/textrendering/glyphshaping/main.cpp
index 21e57152dd..e7720522fb 100644
--- a/tests/manual/textrendering/glyphshaping/main.cpp
+++ b/tests/manual/textrendering/glyphshaping/main.cpp
@@ -39,7 +39,15 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QApplication>
+#include <QStringList>
+#include <QVector>
+#include <QFile>
+#include <QDir>
+#include <QPainter>
+#include <QFontMetrics>
+#include <QImage>
+#include <QXmlStreamReader>
static const int fontPixelSize = 25;
static const QLatin1String fontFamily("Series 60 Sans");
diff --git a/tests/manual/textrendering/textperformance/main.cpp b/tests/manual/textrendering/textperformance/main.cpp
index 7d02c8c03b..373102436c 100644
--- a/tests/manual/textrendering/textperformance/main.cpp
+++ b/tests/manual/textrendering/textperformance/main.cpp
@@ -39,7 +39,12 @@
**
****************************************************************************/
-#include <QtWidgets>
+#include <QApplication>
+#include <QDialog>
+#include <QFontDatabase>
+#include <QPainter>
+#include <QTime>
+#include <QTimer>
static const int lastMeasurementsCount = 50;
diff --git a/tests/manual/transientwindow/main.cpp b/tests/manual/transientwindow/main.cpp
new file mode 100644
index 0000000000..aebb051688
--- /dev/null
+++ b/tests/manual/transientwindow/main.cpp
@@ -0,0 +1,51 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+#include "mainwindow.h"
+#include <QApplication>
+
+int main(int argc, char *argv[])
+{
+ QApplication a(argc, argv);
+ MainWindow w;
+ w.show();
+
+ return a.exec();
+}
diff --git a/tests/manual/transientwindow/mainwindow.cpp b/tests/manual/transientwindow/mainwindow.cpp
new file mode 100644
index 0000000000..25123c4936
--- /dev/null
+++ b/tests/manual/transientwindow/mainwindow.cpp
@@ -0,0 +1,66 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+#include "mainwindow.h"
+#include <QDebug>
+
+MainWindow::MainWindow(QWidget *parent)
+ : QMainWindow(parent), m_showButton("Toggle visible", this), m_window(0)
+{
+ connect(&m_showButton, SIGNAL(clicked()), this, SLOT(toggleVisible()));
+ setWindowTitle(QString::fromLatin1("Main Window"));
+ m_showButton.setVisible(true);
+ setMinimumSize(300, 200);
+}
+
+MainWindow::~MainWindow()
+{
+}
+
+void MainWindow::toggleVisible()
+{
+ if (!m_window) {
+ m_window = new QWindow();
+ m_window->setTransientParent(windowHandle());
+ m_window->setMinimumSize(QSize(200, 100));
+ m_window->setTitle("Transient Window");
+ }
+ m_window->setVisible(!m_window->isVisible());
+}
diff --git a/tests/manual/transientwindow/mainwindow.h b/tests/manual/transientwindow/mainwindow.h
new file mode 100644
index 0000000000..352fc961e1
--- /dev/null
+++ b/tests/manual/transientwindow/mainwindow.h
@@ -0,0 +1,64 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the test suite of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+#ifndef MAINWINDOW_H
+#define MAINWINDOW_H
+
+#include <QMainWindow>
+#include <QPushButton>
+#include <QWindow>
+
+class MainWindow : public QMainWindow
+{
+ Q_OBJECT
+
+public:
+ MainWindow(QWidget *parent = 0);
+ ~MainWindow();
+
+public slots:
+ void toggleVisible();
+
+private:
+ QPushButton m_showButton;
+ QWindow* m_window;
+};
+
+#endif // MAINWINDOW_H
diff --git a/tests/manual/transientwindow/transientwindow.pro b/tests/manual/transientwindow/transientwindow.pro
new file mode 100644
index 0000000000..a07ee09dbc
--- /dev/null
+++ b/tests/manual/transientwindow/transientwindow.pro
@@ -0,0 +1,6 @@
+QT += core gui widgets
+TARGET = transientwindow
+TEMPLATE = app
+SOURCES += main.cpp\
+ mainwindow.cpp
+HEADERS += mainwindow.h
diff --git a/tests/manual/widgets/itemviews/delegate/example.cpp b/tests/manual/widgets/itemviews/delegate/example.cpp
index ae45561f03..c65f49f266 100644
--- a/tests/manual/widgets/itemviews/delegate/example.cpp
+++ b/tests/manual/widgets/itemviews/delegate/example.cpp
@@ -39,7 +39,12 @@
**
****************************************************************************/
-#include <QtWidgets/QtWidgets>
+#include <QLineEdit>
+#include <QApplication>
+#include <QTableView>
+#include <QStandardItemModel>
+#include <QItemDelegate>
+#include <QDebug>
class ExampleEditor : public QLineEdit
{
diff --git a/tests/manual/widgets/itemviews/qheaderview/qheaderviewtest1.cpp b/tests/manual/widgets/itemviews/qheaderview/qheaderviewtest1.cpp
index 7a8c1d159d..b5aeb023f4 100644
--- a/tests/manual/widgets/itemviews/qheaderview/qheaderviewtest1.cpp
+++ b/tests/manual/widgets/itemviews/qheaderview/qheaderviewtest1.cpp
@@ -99,6 +99,9 @@ int main(int argc, char *argv[])
m.setRowCount(500);
m.setColumnCount(250);
tv.setModel(&m);
+ tv.setSelectionMode(QAbstractItemView::SingleSelection);
+ // Comment in the line below to test selection with keyboard (space)
+ // tv.setEditTriggers(QAbstractItemView::NoEditTriggers);
SomeHandler handler(tv.horizontalHeader(), &tv);
tv.horizontalHeader()->setDefaultSectionSize(30);
tv.show();
diff --git a/tests/manual/widgets/qgraphicsview/rubberband/rubberbandtest.cpp b/tests/manual/widgets/qgraphicsview/rubberband/rubberbandtest.cpp
index 186203e7d8..aec2479239 100644
--- a/tests/manual/widgets/qgraphicsview/rubberband/rubberbandtest.cpp
+++ b/tests/manual/widgets/qgraphicsview/rubberband/rubberbandtest.cpp
@@ -60,11 +60,12 @@ public:
class MyGraphicsView : public QGraphicsView
{
-
+ Q_OBJECT
public:
- MyGraphicsView() : QGraphicsView()
+ MyGraphicsView(QWidget *w, QLabel *l) : QGraphicsView(w), rubberbandLabel(l)
{
setDragMode(QGraphicsView::RubberBandDrag);
+ connect(this, SIGNAL(rubberBandChanged(QRect, QPointF, QPointF)), this, SLOT(updateRubberbandInfo(QRect, QPointF, QPointF)));
}
protected:
void mouseMoveEvent(QMouseEvent *event)
@@ -81,26 +82,46 @@ protected:
if (yglobal > bottomPos)
verticalScrollBar()->setValue(verticalScrollBar()->value() + 10);
}
+
+protected slots:
+ void updateRubberbandInfo(QRect r, QPointF from, QPointF to)
+ {
+ QString textToShow;
+ QDebug s(&textToShow);
+ s << r << from << to;
+ rubberbandLabel->setText(textToShow);
+ }
+protected:
+ QLabel *rubberbandLabel;
};
int main(int argc, char *argv[])
{
QApplication app(argc, argv);
- MyGraphicsView v;
+
+ QWidget w;
+ w.setLayout(new QVBoxLayout);
+ QLabel *l = new QLabel(&w);
+ MyGraphicsView *v = new MyGraphicsView(&w, l);
+
+ w.layout()->addWidget(v);
+ w.layout()->addWidget(l);
QGraphicsScene s(0.0, 0.0, 5000.0, 5000.0);
- v.setScene(&s);
- v.setInteractive(true);
- v.setRubberBandSelectionMode(Qt::IntersectsItemBoundingRect);
- s.addRect( (qreal) 0.0, 0.0, 1000.0, 50.0, QPen(),QBrush(QColor(0,0,255)));
+ v->setScene(&s);
+ v->setInteractive(true);
+ v->setRubberBandSelectionMode(Qt::IntersectsItemBoundingRect);
for (int u = 0; u < 100; ++u)
- for (int v = 0; v < 100; ++v) {
+ for (int n = 0; n < 100; ++n) {
MyGraphicsItem *item = new MyGraphicsItem();
- item->setRect(QRectF(v * 80.0, u * 80.0, 50.0, 20.0));
+ item->setRect(QRectF(n * 80.0, u * 80.0, 50.0, 20.0));
s.addItem(item);
}
- v.show();
+
+ w.show();
app.exec();
return 0;
}
+
+#include "rubberbandtest.moc"
diff --git a/tests/manual/windowflags/controls.cpp b/tests/manual/windowflags/controls.cpp
index cad84617fc..422656ff03 100644
--- a/tests/manual/windowflags/controls.cpp
+++ b/tests/manual/windowflags/controls.cpp
@@ -123,8 +123,10 @@ Qt::WindowFlags HintControl::hints() const
flags |= Qt::WindowMinimizeButtonHint;
if (windowMaximizeButtonCheckBox->isChecked())
flags |= Qt::WindowMaximizeButtonHint;
+#if QT_VERSION >= 0x050000
if (windowFullscreenButtonCheckBox->isChecked())
flags |= Qt::WindowFullscreenButtonHint;
+#endif
if (windowCloseButtonCheckBox->isChecked())
flags |= Qt::WindowCloseButtonHint;
if (windowContextHelpButtonCheckBox->isChecked())
@@ -153,7 +155,9 @@ void HintControl::setHints(Qt::WindowFlags flags)
windowSystemMenuCheckBox->setChecked(flags & Qt::WindowSystemMenuHint);
windowMinimizeButtonCheckBox->setChecked(flags & Qt::WindowMinimizeButtonHint);
windowMaximizeButtonCheckBox->setChecked(flags & Qt::WindowMaximizeButtonHint);
+#if QT_VERSION >= 0x050000
windowFullscreenButtonCheckBox->setChecked(flags & Qt::WindowFullscreenButtonHint);
+#endif
windowCloseButtonCheckBox->setChecked(flags & Qt::WindowCloseButtonHint);
windowContextHelpButtonCheckBox->setChecked(flags & Qt::WindowContextHelpButtonHint);
windowShadeButtonCheckBox->setChecked(flags & Qt::WindowShadeButtonHint);
diff --git a/tests/manual/windowgeometry/controllerwidget.cpp b/tests/manual/windowgeometry/controllerwidget.cpp
index 8340b90654..d8c74ef8a3 100644
--- a/tests/manual/windowgeometry/controllerwidget.cpp
+++ b/tests/manual/windowgeometry/controllerwidget.cpp
@@ -311,7 +311,7 @@ public:
, m_backingStore(new QBackingStore(this))
{
setObjectName(QStringLiteral("window"));
- setWindowTitle(tr("TestWindow"));
+ setTitle(tr("TestWindow"));
}
protected:
@@ -363,9 +363,9 @@ private:
virtual QPoint objectMapToGlobal(const QObject *o, const QPoint &p) const
{ return static_cast<const QWindow *>(o)->mapToGlobal(p); }
virtual Qt::WindowFlags objectWindowFlags(const QObject *o) const
- { return static_cast<const QWindow *>(o)->windowFlags(); }
+ { return static_cast<const QWindow *>(o)->flags(); }
virtual void setObjectWindowFlags(QObject *o, Qt::WindowFlags f)
- { static_cast<QWindow *>(o)->setWindowFlags(f); }
+ { static_cast<QWindow *>(o)->setFlags(f); }
WindowStateControl *m_stateControl;
};
@@ -374,7 +374,7 @@ WindowControl::WindowControl(QWindow *w )
: BaseWindowControl(w)
, m_stateControl(new WindowStateControl(WindowStateControl::WantVisibleCheckBox | WindowStateControl::WantMinimizeRadioButton))
{
- setTitle(w->windowTitle());
+ setTitle(w->title());
QGroupBox *stateGroupBox = new QGroupBox(tr("State"));
QVBoxLayout *l = new QVBoxLayout(stateGroupBox);
l->addWidget(m_stateControl);
@@ -454,7 +454,7 @@ ControllerWidget::ControllerWidget(QWidget *parent)
#if QT_VERSION >= 0x050000
x += 300;
- m_testWindow->setWindowFlags(Qt::Window | Qt::WindowSystemMenuHint | Qt::WindowCloseButtonHint
+ m_testWindow->setFlags(Qt::Window | Qt::WindowSystemMenuHint | Qt::WindowCloseButtonHint
| Qt::WindowMinimizeButtonHint | Qt::WindowMaximizeButtonHint
| Qt::WindowTitleHint | Qt::WindowFullscreenButtonHint);
m_testWindow->setFramePosition(QPoint(x, y));
@@ -467,7 +467,7 @@ ControllerWidget::ControllerWidget(QWidget *parent)
m_testWindow->showFullScreen();
else
m_testWindow->show();
- m_testWindow->setWindowTitle(tr("TestWindow"));
+ m_testWindow->setTitle(tr("TestWindow"));
#endif
QWidget *central = new QWidget ;
diff --git a/tests/manual/xembed-raster/gtk-embedder.py b/tests/manual/xembed-raster/gtk-embedder.py
new file mode 100755
index 0000000000..bd19789f84
--- /dev/null
+++ b/tests/manual/xembed-raster/gtk-embedder.py
@@ -0,0 +1,74 @@
+#!/usr/bin/python
+#############################################################################
+##
+## Copyright (C) 2013 Canonical Ltd.
+## Contact: http://www.qt-project.org/legal
+##
+## This file is part of the test suite of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:LGPL$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and Digia. For licensing terms and
+## conditions see http://qt.digia.com/licensing. For further information
+## use the contact form at http://qt.digia.com/contact-us.
+##
+## GNU Lesser General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU Lesser
+## General Public License version 2.1 as published by the Free Software
+## Foundation and appearing in the file LICENSE.LGPL included in the
+## packaging of this file. Please review the following information to
+## ensure the GNU Lesser General Public License version 2.1 requirements
+## will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+##
+## In addition, as a special exception, Digia gives you certain additional
+## rights. These rights are described in the Digia Qt LGPL Exception
+## version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3.0 as published by the Free Software
+## Foundation and appearing in the file LICENSE.GPL included in the
+## packaging of this file. Please review the following information to
+## ensure the GNU General Public License version 3.0 requirements will be
+## met: http://www.gnu.org/copyleft/gpl.html.
+##
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+from gi.repository import Gtk
+from subprocess import Popen
+
+window = Gtk.Window()
+
+box = Gtk.VBox(False, 0)
+window.add(box)
+
+child = None
+def on_button_clicked(button, socket):
+ global child
+ child = Popen(['./rasterwindow', str(socket.get_id())])
+
+button = Gtk.Button("Press me to embed a Qt client")
+box.pack_start(button, False, False, 0)
+
+socket = Gtk.Socket()
+socket.set_size_request(200, 200)
+box.add(socket)
+
+button.connect("clicked", on_button_clicked, socket)
+window.connect("destroy", Gtk.main_quit)
+
+def plugged_event(widget):
+ print("A window was embedded!")
+
+socket.connect("plug-added", plugged_event)
+
+window.show_all()
+Gtk.main()
+if child:
+ child.terminate()
diff --git a/tests/manual/xembed-raster/main.cpp b/tests/manual/xembed-raster/main.cpp
new file mode 100644
index 0000000000..dc5fb8a5ca
--- /dev/null
+++ b/tests/manual/xembed-raster/main.cpp
@@ -0,0 +1,66 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the examples 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$
+**
+****************************************************************************/
+
+#include "rasterwindow.h"
+#include <QDebug>
+
+int main(int argc, char **argv)
+{
+ QGuiApplication app(argc, argv);
+
+ QStringList args = app.arguments();
+
+ WId winId = 0;
+ if (args.count() > 1) {
+ bool ok;
+ winId = args[1].toUInt(&ok);
+ Q_ASSERT(ok);
+ }
+
+ RasterWindow window;
+ window.show();
+
+ QWindow *foreign = QWindow::fromWinId(winId);
+ Q_ASSERT(foreign != 0);
+
+ window.setParent(foreign);
+
+ return app.exec();
+}
diff --git a/tests/manual/xembed-raster/rasterwindow.cpp b/tests/manual/xembed-raster/rasterwindow.cpp
new file mode 100644
index 0000000000..cad5081280
--- /dev/null
+++ b/tests/manual/xembed-raster/rasterwindow.cpp
@@ -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 examples 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$
+**
+****************************************************************************/
+
+#include "rasterwindow.h"
+
+RasterWindow::RasterWindow(QWindow *parent)
+ : QWindow(parent)
+ , m_update_pending(false)
+{
+ m_backingStore = new QBackingStore(this);
+ create();
+
+ setGeometry(100, 100, 300, 200);
+}
+
+
+bool RasterWindow::event(QEvent *event)
+{
+ if (event->type() == QEvent::UpdateRequest) {
+ m_update_pending = false;
+ renderNow();
+ return true;
+ }
+ return QWindow::event(event);
+}
+
+void RasterWindow::renderLater()
+{
+ if (!m_update_pending) {
+ m_update_pending = true;
+ QCoreApplication::postEvent(this, new QEvent(QEvent::UpdateRequest));
+ }
+}
+
+void RasterWindow::resizeEvent(QResizeEvent *resizeEvent)
+{
+ m_backingStore->resize(resizeEvent->size());
+ if (isExposed())
+ renderNow();
+}
+
+void RasterWindow::exposeEvent(QExposeEvent *)
+{
+ if (isExposed()) {
+ renderNow();
+ }
+}
+
+void RasterWindow::renderNow()
+{
+ if (!isExposed())
+ return;
+
+ QRect rect(0, 0, width(), height());
+ m_backingStore->beginPaint(rect);
+
+ QPaintDevice *device = m_backingStore->paintDevice();
+ QPainter painter(device);
+
+ painter.fillRect(0, 0, width(), height(), Qt::white);
+ render(&painter);
+
+ m_backingStore->endPaint();
+ m_backingStore->flush(rect);
+}
+
+void RasterWindow::render(QPainter *painter)
+{
+ painter->drawText(QRectF(0, 0, width(), height()), Qt::AlignCenter, QStringLiteral("QWindow"));
+}
diff --git a/tests/manual/xembed-raster/rasterwindow.h b/tests/manual/xembed-raster/rasterwindow.h
new file mode 100644
index 0000000000..3fed06d7de
--- /dev/null
+++ b/tests/manual/xembed-raster/rasterwindow.h
@@ -0,0 +1,69 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the examples 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$
+**
+****************************************************************************/
+
+#ifndef RASTERWINDOW_H
+#define RASTERWINDOW_H
+
+#include <QtGui>
+
+class RasterWindow : public QWindow
+{
+ Q_OBJECT
+public:
+ explicit RasterWindow(QWindow *parent = 0);
+
+ virtual void render(QPainter *painter);
+
+public slots:
+ void renderLater();
+ void renderNow();
+
+protected:
+ bool event(QEvent *event);
+
+ void resizeEvent(QResizeEvent *event);
+ void exposeEvent(QExposeEvent *event);
+
+private:
+ QBackingStore *m_backingStore;
+ bool m_update_pending;
+};
+
+#endif // RASTERWINDOW_H
diff --git a/tests/manual/xembed-raster/xembed-raster.pro b/tests/manual/xembed-raster/xembed-raster.pro
new file mode 100644
index 0000000000..adaf9c4d25
--- /dev/null
+++ b/tests/manual/xembed-raster/xembed-raster.pro
@@ -0,0 +1,9 @@
+TEMPLATE = app
+TARGET= rasterwindow
+QT += gui
+
+SOURCES += \
+ main.cpp \
+ rasterwindow.cpp
+HEADERS += \
+ rasterwindow.h
diff --git a/tests/manual/xembed-widgets/gtk-embedder.py b/tests/manual/xembed-widgets/gtk-embedder.py
new file mode 100755
index 0000000000..bcb9813441
--- /dev/null
+++ b/tests/manual/xembed-widgets/gtk-embedder.py
@@ -0,0 +1,77 @@
+#!/usr/bin/python
+#############################################################################
+##
+## Copyright (C) 2013 Canonical Ltd.
+## Contact: http://www.qt-project.org/legal
+##
+## This file is part of the test suite of the Qt Toolkit.
+##
+## $QT_BEGIN_LICENSE:LGPL$
+## Commercial License Usage
+## Licensees holding valid commercial Qt licenses may use this file in
+## accordance with the commercial license agreement provided with the
+## Software or, alternatively, in accordance with the terms contained in
+## a written agreement between you and Digia. For licensing terms and
+## conditions see http://qt.digia.com/licensing. For further information
+## use the contact form at http://qt.digia.com/contact-us.
+##
+## GNU Lesser General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU Lesser
+## General Public License version 2.1 as published by the Free Software
+## Foundation and appearing in the file LICENSE.LGPL included in the
+## packaging of this file. Please review the following information to
+## ensure the GNU Lesser General Public License version 2.1 requirements
+## will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+##
+## In addition, as a special exception, Digia gives you certain additional
+## rights. These rights are described in the Digia Qt LGPL Exception
+## version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+##
+## GNU General Public License Usage
+## Alternatively, this file may be used under the terms of the GNU
+## General Public License version 3.0 as published by the Free Software
+## Foundation and appearing in the file LICENSE.GPL included in the
+## packaging of this file. Please review the following information to
+## ensure the GNU General Public License version 3.0 requirements will be
+## met: http://www.gnu.org/copyleft/gpl.html.
+##
+##
+## $QT_END_LICENSE$
+##
+#############################################################################
+
+from gi.repository import Gtk
+from subprocess import Popen
+
+window = Gtk.Window()
+
+box = Gtk.VBox(False, 0)
+window.add(box)
+
+child = None
+def on_button_clicked(button, socket):
+ global child
+ child = Popen(['./lineedits', str(socket.get_id())])
+
+button = Gtk.Button("Press me to embed a Qt client")
+box.pack_start(button, False, False, 0)
+
+entry = Gtk.Entry()
+box.pack_start(entry, False, False, 0)
+
+socket = Gtk.Socket()
+socket.set_size_request(200, 200)
+box.add(socket)
+
+button.connect("clicked", on_button_clicked, socket)
+window.connect("destroy", Gtk.main_quit)
+
+def plugged_event(widget):
+ print("A window was embedded!")
+
+socket.connect("plug-added", plugged_event)
+
+window.show_all()
+Gtk.main()
+if child:
+ child.terminate()
diff --git a/tests/manual/xembed-widgets/main.cpp b/tests/manual/xembed-widgets/main.cpp
new file mode 100644
index 0000000000..fbd9773b61
--- /dev/null
+++ b/tests/manual/xembed-widgets/main.cpp
@@ -0,0 +1,69 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the examples 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$
+**
+****************************************************************************/
+
+#include <QApplication>
+#include <QDebug>
+#include <QWindow>
+
+#include "window.h"
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QStringList args = app.arguments();
+
+ WId winId = 0;
+ if (args.count() > 1) {
+ bool ok;
+ winId = args[1].toUInt(&ok);
+ Q_ASSERT(ok);
+ }
+
+ Window window;
+ window.show();
+
+ QWindow *foreign = QWindow::fromWinId(winId);
+ Q_ASSERT(foreign != 0);
+
+ window.windowHandle()->setParent(foreign);
+
+ return app.exec();
+}
diff --git a/tests/manual/xembed-widgets/window.cpp b/tests/manual/xembed-widgets/window.cpp
new file mode 100644
index 0000000000..92eccf50ba
--- /dev/null
+++ b/tests/manual/xembed-widgets/window.cpp
@@ -0,0 +1,228 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the examples 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$
+**
+****************************************************************************/
+
+#include <QtWidgets>
+
+#include "window.h"
+
+Window::Window()
+{
+ QGroupBox *echoGroup = new QGroupBox(tr("Echo"));
+
+ QLabel *echoLabel = new QLabel(tr("Mode:"));
+ QComboBox *echoComboBox = new QComboBox;
+ echoComboBox->addItem(tr("Normal"));
+ echoComboBox->addItem(tr("Password"));
+ echoComboBox->addItem(tr("PasswordEchoOnEdit"));
+ echoComboBox->addItem(tr("No Echo"));
+
+ echoLineEdit = new QLineEdit;
+ echoLineEdit->setFocus();
+
+ QGroupBox *validatorGroup = new QGroupBox(tr("Validator"));
+
+ QLabel *validatorLabel = new QLabel(tr("Type:"));
+ QComboBox *validatorComboBox = new QComboBox;
+ validatorComboBox->addItem(tr("No validator"));
+ validatorComboBox->addItem(tr("Integer validator"));
+ validatorComboBox->addItem(tr("Double validator"));
+
+ validatorLineEdit = new QLineEdit;
+
+ QGroupBox *alignmentGroup = new QGroupBox(tr("Alignment"));
+
+ QLabel *alignmentLabel = new QLabel(tr("Type:"));
+ QComboBox *alignmentComboBox = new QComboBox;
+ alignmentComboBox->addItem(tr("Left"));
+ alignmentComboBox->addItem(tr("Centered"));
+ alignmentComboBox->addItem(tr("Right"));
+
+ alignmentLineEdit = new QLineEdit;
+
+ QGroupBox *inputMaskGroup = new QGroupBox(tr("Input mask"));
+
+ QLabel *inputMaskLabel = new QLabel(tr("Type:"));
+ QComboBox *inputMaskComboBox = new QComboBox;
+ inputMaskComboBox->addItem(tr("No mask"));
+ inputMaskComboBox->addItem(tr("Phone number"));
+ inputMaskComboBox->addItem(tr("ISO date"));
+ inputMaskComboBox->addItem(tr("License key"));
+
+ inputMaskLineEdit = new QLineEdit;
+
+ QGroupBox *accessGroup = new QGroupBox(tr("Access"));
+
+ QLabel *accessLabel = new QLabel(tr("Read-only:"));
+ QComboBox *accessComboBox = new QComboBox;
+ accessComboBox->addItem(tr("False"));
+ accessComboBox->addItem(tr("True"));
+
+ accessLineEdit = new QLineEdit;
+
+ connect(echoComboBox, SIGNAL(activated(int)),
+ this, SLOT(echoChanged(int)));
+ connect(validatorComboBox, SIGNAL(activated(int)),
+ this, SLOT(validatorChanged(int)));
+ connect(alignmentComboBox, SIGNAL(activated(int)),
+ this, SLOT(alignmentChanged(int)));
+ connect(inputMaskComboBox, SIGNAL(activated(int)),
+ this, SLOT(inputMaskChanged(int)));
+ connect(accessComboBox, SIGNAL(activated(int)),
+ this, SLOT(accessChanged(int)));
+
+ QGridLayout *echoLayout = new QGridLayout;
+ echoLayout->addWidget(echoLabel, 0, 0);
+ echoLayout->addWidget(echoComboBox, 0, 1);
+ echoLayout->addWidget(echoLineEdit, 1, 0, 1, 2);
+ echoGroup->setLayout(echoLayout);
+
+ QGridLayout *validatorLayout = new QGridLayout;
+ validatorLayout->addWidget(validatorLabel, 0, 0);
+ validatorLayout->addWidget(validatorComboBox, 0, 1);
+ validatorLayout->addWidget(validatorLineEdit, 1, 0, 1, 2);
+ validatorGroup->setLayout(validatorLayout);
+
+ QGridLayout *alignmentLayout = new QGridLayout;
+ alignmentLayout->addWidget(alignmentLabel, 0, 0);
+ alignmentLayout->addWidget(alignmentComboBox, 0, 1);
+ alignmentLayout->addWidget(alignmentLineEdit, 1, 0, 1, 2);
+ alignmentGroup-> setLayout(alignmentLayout);
+
+ QGridLayout *inputMaskLayout = new QGridLayout;
+ inputMaskLayout->addWidget(inputMaskLabel, 0, 0);
+ inputMaskLayout->addWidget(inputMaskComboBox, 0, 1);
+ inputMaskLayout->addWidget(inputMaskLineEdit, 1, 0, 1, 2);
+ inputMaskGroup->setLayout(inputMaskLayout);
+
+ QGridLayout *accessLayout = new QGridLayout;
+ accessLayout->addWidget(accessLabel, 0, 0);
+ accessLayout->addWidget(accessComboBox, 0, 1);
+ accessLayout->addWidget(accessLineEdit, 1, 0, 1, 2);
+ accessGroup->setLayout(accessLayout);
+
+ QGridLayout *layout = new QGridLayout;
+ layout->addWidget(echoGroup, 0, 0);
+ layout->addWidget(validatorGroup, 1, 0);
+ layout->addWidget(alignmentGroup, 2, 0);
+ layout->addWidget(inputMaskGroup, 0, 1);
+ layout->addWidget(accessGroup, 1, 1);
+ setLayout(layout);
+
+ setWindowTitle(tr("Line Edits"));
+}
+
+void Window::echoChanged(int index)
+{
+ switch (index) {
+ case 0:
+ echoLineEdit->setEchoMode(QLineEdit::Normal);
+ break;
+ case 1:
+ echoLineEdit->setEchoMode(QLineEdit::Password);
+ break;
+ case 2:
+ echoLineEdit->setEchoMode(QLineEdit::PasswordEchoOnEdit);
+ break;
+ case 3:
+ echoLineEdit->setEchoMode(QLineEdit::NoEcho);
+ }
+}
+
+void Window::validatorChanged(int index)
+{
+ switch (index) {
+ case 0:
+ validatorLineEdit->setValidator(0);
+ break;
+ case 1:
+ validatorLineEdit->setValidator(new QIntValidator(
+ validatorLineEdit));
+ break;
+ case 2:
+ validatorLineEdit->setValidator(new QDoubleValidator(-999.0,
+ 999.0, 2, validatorLineEdit));
+ }
+
+ validatorLineEdit->clear();
+}
+
+void Window::alignmentChanged(int index)
+{
+ switch (index) {
+ case 0:
+ alignmentLineEdit->setAlignment(Qt::AlignLeft);
+ break;
+ case 1:
+ alignmentLineEdit->setAlignment(Qt::AlignCenter);
+ break;
+ case 2:
+ alignmentLineEdit->setAlignment(Qt::AlignRight);
+ }
+}
+
+void Window::inputMaskChanged(int index)
+{
+ switch (index) {
+ case 0:
+ inputMaskLineEdit->setInputMask("");
+ break;
+ case 1:
+ inputMaskLineEdit->setInputMask("+99 99 99 99 99;_");
+ break;
+ case 2:
+ inputMaskLineEdit->setInputMask("0000-00-00");
+ inputMaskLineEdit->setText("00000000");
+ inputMaskLineEdit->setCursorPosition(0);
+ break;
+ case 3:
+ inputMaskLineEdit->setInputMask(">AAAAA-AAAAA-AAAAA-AAAAA-AAAAA;#");
+ }
+}
+
+void Window::accessChanged(int index)
+{
+ switch (index) {
+ case 0:
+ accessLineEdit->setReadOnly(false);
+ break;
+ case 1:
+ accessLineEdit->setReadOnly(true);
+ }
+}
diff --git a/tests/manual/xembed-widgets/window.h b/tests/manual/xembed-widgets/window.h
new file mode 100644
index 0000000000..fbb9b82300
--- /dev/null
+++ b/tests/manual/xembed-widgets/window.h
@@ -0,0 +1,73 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the examples 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$
+**
+****************************************************************************/
+
+#ifndef WINDOW_H
+#define WINDOW_H
+
+#include <QWidget>
+
+QT_BEGIN_NAMESPACE
+class QComboBox;
+class QLineEdit;
+QT_END_NAMESPACE
+
+class Window : public QWidget
+{
+ Q_OBJECT
+
+public:
+ Window();
+
+public slots:
+ void echoChanged(int);
+ void validatorChanged(int);
+ void alignmentChanged(int);
+ void inputMaskChanged(int);
+ void accessChanged(int);
+
+private:
+ QLineEdit *echoLineEdit;
+ QLineEdit *validatorLineEdit;
+ QLineEdit *alignmentLineEdit;
+ QLineEdit *inputMaskLineEdit;
+ QLineEdit *accessLineEdit;
+};
+
+#endif
diff --git a/tests/manual/xembed-widgets/xembed-widgets.pro b/tests/manual/xembed-widgets/xembed-widgets.pro
new file mode 100644
index 0000000000..e406ee47fd
--- /dev/null
+++ b/tests/manual/xembed-widgets/xembed-widgets.pro
@@ -0,0 +1,9 @@
+TEMPLATE = app
+TARGET= lineedits
+QT += widgets
+
+SOURCES += \
+ main.cpp \
+ window.cpp
+HEADERS += \
+ window.h
diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp
index 22ee456038..dc11c0d0a2 100644
--- a/tools/configure/configureapp.cpp
+++ b/tools/configure/configureapp.cpp
@@ -1,6 +1,7 @@
/****************************************************************************
**
** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Copyright (C) 2013 Intel Corporation
** Contact: http://www.qt-project.org/legal
**
** This file is part of the tools applications of the Qt Toolkit.
@@ -69,7 +70,8 @@ enum Platforms {
WINDOWS,
WINDOWS_CE,
QNX,
- BLACKBERRY
+ BLACKBERRY,
+ ANDROID
};
std::ostream &operator<<(std::ostream &s, const QString &val) {
@@ -244,6 +246,7 @@ Configure::Configure(int& argc, char** argv)
dictionary[ "CFG_GCC_SYSROOT" ] = "yes";
dictionary[ "SLOG2" ] = "no";
dictionary[ "SYSTEM_PROXIES" ] = "no";
+ dictionary[ "WERROR" ] = "auto";
//Only used when cross compiling.
dictionary[ "QT_INSTALL_SETTINGS" ] = "/etc/xdg";
@@ -563,6 +566,9 @@ void Configure::parseCmdLine()
else if (configCmdLine.at(i) == "-angle") {
dictionary[ "ANGLE" ] = "yes";
dictionary[ "ANGLE_FROM" ] = "commandline";
+ } else if (configCmdLine.at(i) == "-angle-d3d11") {
+ dictionary[ "ANGLE" ] = "d3d11";
+ dictionary[ "ANGLE_FROM" ] = "commandline";
} else if (configCmdLine.at(i) == "-no-angle") {
dictionary[ "ANGLE" ] = "no";
dictionary[ "ANGLE_FROM" ] = "commandline";
@@ -891,6 +897,11 @@ void Configure::parseCmdLine()
dictionary[ "SYSTEM_PROXIES" ] = "no";
} else if (configCmdLine.at(i) == "-system-proxies") {
dictionary[ "SYSTEM_PROXIES" ] = "yes";
+ } else if (configCmdLine.at(i) == "-warnings-are-errors" ||
+ configCmdLine.at(i) == "-Werror") {
+ dictionary[ "WERROR" ] = "yes";
+ } else if (configCmdLine.at(i) == "-no-warnings-are-errors") {
+ dictionary[ "WERROR" ] = "no";
}
// Work around compiler nesting limitation
@@ -1243,6 +1254,41 @@ void Configure::parseCmdLine()
dictionary["QT_INSTALL_SETTINGS"] = configCmdLine.at(i);
}
+ else if (configCmdLine.at(i) == "-android-ndk") {
+ ++i;
+ if (i == argCount)
+ break;
+ dictionary[ "ANDROID_NDK_ROOT" ] = configCmdLine.at(i);
+ }
+
+ else if (configCmdLine.at(i) == "-android-sdk") {
+ ++i;
+ if (i == argCount)
+ break;
+ dictionary[ "ANDROID_SDK_ROOT" ] = configCmdLine.at(i);
+ }
+
+ else if (configCmdLine.at(i) == "-android-ndk-platform") {
+ ++i;
+ if (i == argCount)
+ break;
+ dictionary[ "ANDROID_PLATFORM" ] = configCmdLine.at(i);
+ }
+
+ else if (configCmdLine.at(i) == "-android-arch") {
+ ++i;
+ if (i == argCount)
+ break;
+ dictionary[ "ANDROID_TARGET_ARCH" ] = configCmdLine.at(i);
+ }
+
+ else if (configCmdLine.at(i) == "-android-toolchain-version") {
+ ++i;
+ if (i == argCount)
+ break;
+ dictionary[ "ANDROID_NDK_TOOLCHAIN_VERSION" ] = configCmdLine.at(i);
+ }
+
else {
dictionary[ "HELP" ] = "yes";
cout << "Unknown option " << configCmdLine.at(i) << endl;
@@ -1291,7 +1337,7 @@ void Configure::parseCmdLine()
dictionary[ "QMAKEMAKEFILE" ] = "Makefile.win32";
} else if (dictionary[ "QMAKESPEC" ] == QString("win32-g++")) {
if (dictionary[ "MAKE" ].isEmpty()) dictionary[ "MAKE" ] = "mingw32-make";
- dictionary[ "QMAKEMAKEFILE" ] = "Makefile.win32-g++";
+ dictionary[ "QMAKEMAKEFILE" ] = "Makefile.unix";
} else {
if (dictionary[ "MAKE" ].isEmpty()) dictionary[ "MAKE" ] = "make";
dictionary[ "QMAKEMAKEFILE" ] = "Makefile.win32";
@@ -1361,8 +1407,14 @@ void Configure::parseCmdLine()
}
// Allow tests for private classes to be compiled against internal builds
- if (dictionary["BUILDDEV"] == "yes")
- qtConfig += "private_tests";
+ if (dictionary["BUILDDEV"] == "yes") {
+ qtConfig << "private_tests";
+ if (dictionary["WERROR"] != "no")
+ qmakeConfig << "warnings_are_errors";
+ } else {
+ if (dictionary["WERROR"] == "yes")
+ qmakeConfig << "warnings_are_errors";
+ }
if (dictionary["FORCE_ASSERTS"] == "yes")
qtConfig += "force_asserts";
@@ -1590,6 +1642,14 @@ void Configure::applySpecSpecifics()
} else if ((platform() == QNX) || (platform() == BLACKBERRY)) {
dictionary["STACK_PROTECTOR_STRONG"] = "auto";
dictionary["SLOG2"] = "auto";
+ } else if (platform() == ANDROID) {
+ dictionary[ "REDUCE_EXPORTS" ] = "yes";
+ dictionary[ "BUILD" ] = "release";
+ dictionary[ "BUILDALL" ] = "no";
+ dictionary[ "LARGE_FILE" ] = "no";
+ dictionary[ "ANGLE" ] = "no";
+ dictionary[ "REDUCE_RELOCATIONS" ] = "yes";
+ dictionary[ "QT_GETIFADDRS" ] = "no";
}
}
@@ -1734,6 +1794,8 @@ bool Configure::displayHelp()
desc("SYSTEM_PROXIES", "yes", "-system-proxies", "Use system network proxies by default.");
desc("SYSTEM_PROXIES", "no", "-no-system-proxies", "Do not use system network proxies by default.\n");
+ desc("WERROR", "yes", "-warnings-are-errors", "Make warnings be treated as errors.");
+ desc("WERROR", "no", "-no-warnings-are-errors","Make warnings be treated normally.");
#if !defined(EVAL)
desc( "-qtnamespace <name>", "Wraps all Qt library code in 'namespace name {...}'.");
@@ -1779,6 +1841,7 @@ bool Configure::displayHelp()
}
desc("ANGLE", "yes", "-angle", "Use the ANGLE implementation of OpenGL ES 2.0.");
+ desc("ANGLE", "d3d11", "-angle-d3d11", "Use the Direct3D 11-based ANGLE implementation of OpenGL ES 2.0.");
desc("ANGLE", "no", "-no-angle", "Do not use ANGLE.\nSee http://code.google.com/p/angleproject/\n");
#endif
// Qt\Windows only options go below here --------------------------------------------------------------------------------
@@ -1979,7 +2042,7 @@ bool Configure::checkAngleAvailability(QString *errorMessage /* = 0 */) const
}
}
- const QString directXLibrary = QStringLiteral("d3d9.lib");
+ const QString directXLibrary = dictionary["ANGLE"] == "d3d11" ? QStringLiteral("d3d11.lib") : QStringLiteral("d3d9.lib");
if (!findFile(directXLibrary)) {
if (errorMessage)
*errorMessage = QString::fromLatin1("The library '%1' could not be found.").arg(directXLibrary);
@@ -2309,7 +2372,7 @@ bool Configure::verifyConfiguration()
}
// -angle given on command line, but Direct X cannot be found.
- if (dictionary["ANGLE"] == "yes") {
+ if (dictionary["ANGLE"] != "no") {
QString errorMessage;
if (!checkAngleAvailability(&errorMessage)) {
cout << "WARNING: ANGLE specified, but the DirectX SDK could not be detected:" << endl
@@ -2446,8 +2509,11 @@ void Configure::generateOutputVars()
qtConfig += "icu";
// ANGLE --------------------------------------------------------
- if (dictionary[ "ANGLE" ] == "yes")
+ if (dictionary[ "ANGLE" ] != "no") {
qtConfig += "angle";
+ if (dictionary[ "ANGLE" ] == "d3d11")
+ qmakeConfig += "angle_d3d11";
+ }
// Image formates -----------------------------------------------
if (dictionary[ "GIF" ] == "no")
@@ -2548,7 +2614,7 @@ void Configure::generateOutputVars()
qtConfig += "build_all";
}
if (dictionary[ "FORCEDEBUGINFO" ] == "yes")
- qtConfig += "force_debug_info";
+ qmakeConfig += "force_debug_info";
qmakeConfig += dictionary[ "BUILD" ];
dictionary[ "QMAKE_OUTDIR" ] = dictionary[ "BUILD" ];
@@ -2658,6 +2724,9 @@ void Configure::generateOutputVars()
if (dictionary["STACK_PROTECTOR_STRONG"] == "yes")
qtConfig += "stack-protector-strong";
+ if (dictionary["REDUCE_EXPORTS"] == "yes")
+ qtConfig += "reduce_exports";
+
// We currently have no switch for QtConcurrent, so add it unconditionally.
qtConfig += "concurrent";
@@ -2922,7 +2991,13 @@ void Configure::detectArch()
Environment::execute(command);
// find the executable that was generated
- QFile exe("arch.exe");
+ QString arch_exe;
+ if (qmakespec.startsWith("android")) {
+ arch_exe = "libarch.so";
+ } else {
+ arch_exe = "arch.exe";
+ }
+ QFile exe(arch_exe);
if (!exe.open(QFile::ReadOnly)) { // no Text, this is binary
exe.setFileName("arch");
if (!exe.open(QFile::ReadOnly)) {
@@ -3294,6 +3369,10 @@ void Configure::generateConfigfiles()
if (dictionary["QT_GLIB"] == "no") qconfigList += "QT_NO_GLIB";
if (dictionary["QT_INOTIFY"] == "no") qconfigList += "QT_NO_INOTIFY";
+ if (dictionary["REDUCE_EXPORTS"] == "yes") qconfigList += "QT_VISIBILITY_AVAILABLE";
+ if (dictionary["REDUCE_RELOCATIONS"] == "yes") qconfigList += "QT_REDUCE_RELOCATIONS";
+ if (dictionary["QT_GETIFADDRS"] == "no") qconfigList += "QT_NO_GETIFADDRS";
+
qconfigList.sort();
for (int i = 0; i < qconfigList.count(); ++i)
tmpStream << addDefine(qconfigList.at(i));
@@ -3327,6 +3406,33 @@ void Configure::generateConfigfiles()
tmpFile3.copy(outName);
tmpFile3.close();
}
+
+ QFile qdeviceFile(dictionary["QT_BUILD_TREE"] + "/mkspecs/qdevice.pri");
+ if (qdeviceFile.open(QIODevice::WriteOnly | QIODevice::Text)) {
+ tmpStream.setDevice(&qdeviceFile);
+ QString android_platform(dictionary.contains("ANDROID_PLATFORM")
+ ? dictionary["ANDROID_PLATFORM"]
+ : QString("android-9"));
+ tmpStream << "android_install {" << endl;
+ tmpStream << " DEFAULT_ANDROID_SDK_ROOT = " << formatPath(dictionary["ANDROID_SDK_ROOT"]) << endl;
+ tmpStream << " DEFAULT_ANDROID_NDK_ROOT = " << formatPath(dictionary["ANDROID_NDK_ROOT"]) << endl;
+ tmpStream << " DEFAULT_ANDROID_PLATFORM = " << android_platform << endl;
+ if (QSysInfo::WordSize == 64)
+ tmpStream << " DEFAULT_ANDROID_NDK_HOST = windows-x86_64" << endl;
+ else
+ tmpStream << " DEFAULT_ANDROID_NDK_HOST = windows" << endl;
+ QString android_arch(dictionary.contains("ANDROID_TARGET_ARCH")
+ ? dictionary["ANDROID_TARGET_ARCH"]
+ : QString("armeabi-v7a"));
+ QString android_tc_vers(dictionary.contains("ANDROID_NDK_TOOLCHAIN_VERSION")
+ ? dictionary["ANDROID_NDK_TOOLCHAIN_VERSION"]
+ : QString("4.7"));
+ tmpStream << " DEFAULT_ANDROID_TARGET_ARCH = " << android_arch << endl;
+ tmpStream << " DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION = " << android_tc_vers << endl;
+ tmpStream << "}" << endl;
+ tmpStream.flush();
+ qdeviceFile.close();
+ }
}
#endif
@@ -3710,12 +3816,64 @@ void Configure::buildQmake()
stream << "#AutoGenerated by configure.exe" << endl
<< "BUILD_PATH = " << QDir::toNativeSeparators(buildPath) << endl
<< "SOURCE_PATH = " << QDir::toNativeSeparators(sourcePath) << endl;
- stream << "QMAKESPEC = " << dictionary["QMAKESPEC"] << endl
- << "QT_VERSION = " << dictionary["VERSION"] << endl;
-
+ stream << "QT_VERSION = " << dictionary["VERSION"] << endl;
+ if (dictionary[ "QMAKESPEC" ] == QString("win32-g++")) {
+ stream << "QMAKESPEC = $(SOURCE_PATH)\\mkspecs\\win32-g++" << endl
+ << "EXTRA_CFLAGS = -DUNICODE" << endl
+ << "EXTRA_CXXFLAGS = -DUNICODE" << endl
+ << "QTOBJS = qfilesystemengine_win.o \\" << endl
+ << " qfilesystemiterator_win.o \\" << endl
+ << " qfsfileengine_win.o \\" << endl
+ << " qlocale_win.o \\" << endl
+ << " qsettings_win.o \\" << endl
+ << " qsystemlibrary.o \\" << endl
+ << " registry.o" << endl
+ << "QTSRCS=\"$(SOURCE_PATH)/src/corelib/io/qfilesystemengine_win.cpp\" \\" << endl
+ << " \"$(SOURCE_PATH)/src/corelib/io/qfilesystemiterator_win.cpp\" \\" << endl
+ << " \"$(SOURCE_PATH)/src/corelib/io/qfsfileengine_win.cpp\" \\" << endl
+ << " \"$(SOURCE_PATH)/src/corelib/io/qsettings_win.cpp\" \\" << endl
+ << " \"$(SOURCE_PATH)/src/corelib/tools/qlocale_win.cpp\" \\" << endl\
+ << " \"$(SOURCE_PATH)/src/corelib/plugin/qsystemlibrary.cpp\" \\" << endl
+ << " \"$(SOURCE_PATH)/tools/shared/windows/registry.cpp\"" << endl
+ << "EXEEXT=.exe" << endl
+ << "LFLAGS=-static -s -lole32 -luuid -ladvapi32 -lkernel32" << endl;
+ /*
+ ** SHELL is the full path of sh.exe, unless
+ ** 1) it is found in the current directory
+ ** 2) it is not found at all
+ ** 3) it is overridden on the command line with an existing file
+ ** ... otherwise it is always sh.exe. Specifically, SHELL from the
+ ** environment has no effect.
+ **
+ ** This check will fail if SHELL is explicitly set to a not
+ ** sh-compatible shell. This is not a problem, because configure.bat
+ ** will not do that.
+ */
+ stream << "ifeq ($(SHELL), sh.exe)" << endl
+ << " ifeq ($(wildcard $(CURDIR)/sh.exe), )" << endl
+ << " SH = 0" << endl
+ << " else" << endl
+ << " SH = 1" << endl
+ << " endif" << endl
+ << "else" << endl
+ << " SH = 1" << endl
+ << "endif" << endl
+ << "\n"
+ << "ifeq ($(SH), 1)" << endl
+ << " RM_F = rm -f" << endl
+ << " RM_RF = rm -rf" << endl
+ << "else" << endl
+ << " RM_F = del /f" << endl
+ << " RM_RF = rmdir /s /q" << endl
+ << "endif" << endl;
+ stream << "\n\n";
+ } else {
+ stream << "QMAKESPEC = " << dictionary["QMAKESPEC"] << endl;
+ }
if (dictionary["EDITION"] == "OpenSource" ||
dictionary["QT_EDITION"].contains("OPENSOURCE"))
- stream << "QMAKE_OPENSOURCE_EDITION = yes" << endl;
+ stream << "EXTRA_CPPFLAGS = -DQMAKE_OPENSOURCE_EDITION" << endl;
+
stream << "\n\n";
QFile in(sourcePath + "/qmake/" + dictionary["QMAKEMAKEFILE"]);
@@ -4079,6 +4237,8 @@ QString Configure::platformName() const
return QStringLiteral("Qt for QNX");
case BLACKBERRY:
return QStringLiteral("Qt for Blackberry");
+ case ANDROID:
+ return QStringLiteral("Qt for Android");
}
}
@@ -4093,6 +4253,8 @@ QString Configure::qpaPlatformName() const
return QStringLiteral("qnx");
case BLACKBERRY:
return QStringLiteral("blackberry");
+ case ANDROID:
+ return QStringLiteral("android");
}
}
@@ -4110,6 +4272,9 @@ int Configure::platform() const
if (xQMakeSpec.contains("blackberry"))
return BLACKBERRY;
+ if (xQMakeSpec.contains("android"))
+ return ANDROID;
+
return WINDOWS;
}
diff --git a/util/corelib/qurl-generateTLDs/main.cpp b/util/corelib/qurl-generateTLDs/main.cpp
index 0d7a58dee1..1809ced808 100644
--- a/util/corelib/qurl-generateTLDs/main.cpp
+++ b/util/corelib/qurl-generateTLDs/main.cpp
@@ -121,12 +121,14 @@ int main(int argc, char **argv) {
outIndicesBuffer.write("static const quint16 tldCount = ");
outIndicesBuffer.write(QByteArray::number(lineCount));
outIndicesBuffer.write(";\n");
- outIndicesBuffer.write("static const quint16 tldIndices[");
+ outIndicesBuffer.write("static const quint32 tldIndices[");
// outIndicesBuffer.write(QByteArray::number(lineCount+1)); // not needed
outIndicesBuffer.write("] = {\n");
- int utf8Size = 0;
-// int charSize = 0;
+ int totalUtf8Size = 0;
+ int chunkSize = 0;
+ int stringUtf8Size = 0;
+ QStringList chunks;
for (int a = 0; a < lineCount; a++) {
bool lineIsEmpty = strings.at(a).isEmpty();
if (!lineIsEmpty) {
@@ -136,25 +138,41 @@ int main(int argc, char **argv) {
int zeroCount = strings.at(a).count(QLatin1String("\\0"));
int utf8CharsCount = strings.at(a).count(QLatin1String("\\x"));
int quoteCount = strings.at(a).count('"');
+ stringUtf8Size = strings.at(a).count() - (zeroCount + quoteCount + utf8CharsCount * 3);
+ chunkSize += stringUtf8Size;
+ if (chunkSize > 65535) {
+ static int chunkCount = 0;
+ qWarning() << "chunk" << ++chunkCount << "has length" << chunkSize - stringUtf8Size;
+ outDataBuffer.write(",\n\n");
+ chunks.append(QByteArray::number(totalUtf8Size));
+ chunkSize = 0;
+ }
outDataBuffer.write(strings.at(a).toUtf8());
if (!lineIsEmpty)
outDataBuffer.write("\n");
- outIndicesBuffer.write(QByteArray::number(utf8Size));
+ outIndicesBuffer.write(QByteArray::number(totalUtf8Size));
outIndicesBuffer.write(",\n");
- utf8Size += strings.at(a).count() - (zeroCount + quoteCount + utf8CharsCount * 3);
-// charSize += strings.at(a).count();
+ totalUtf8Size += stringUtf8Size;
}
- outIndicesBuffer.write(QByteArray::number(utf8Size));
+ chunks.append(QByteArray::number(totalUtf8Size));
+ outIndicesBuffer.write(QByteArray::number(totalUtf8Size));
outIndicesBuffer.write("};\n");
outIndicesBuffer.close();
outFile.write(outIndicesBufferBA);
outDataBuffer.close();
- outFile.write("\nstatic const char tldData[");
+ outFile.write("\nstatic const char *tldData[");
// outFile.write(QByteArray::number(charSize)); // not needed
outFile.write("] = {\n");
outFile.write(outDataBufferBA);
outFile.write("};\n");
+
+ // write chunk information
+ outFile.write("\nstatic const quint16 tldChunkCount = ");
+ outFile.write(QByteArray::number(chunks.count()));
+ outFile.write(";\nstatic const quint32 tldChunks[] = {");
+ outFile.write(chunks.join(", ").toLatin1());
+ outFile.write("};\n");
outFile.close();
printf("data generated to %s . Now copy the data from this file to src/corelib/io/qurltlds_p.h in your Qt repo\n", argv[2]);
exit(0);
diff --git a/util/glgen/README.txt b/util/glgen/README.txt
new file mode 100644
index 0000000000..ea2411f619
--- /dev/null
+++ b/util/glgen/README.txt
@@ -0,0 +1,151 @@
+Overview
+========
+
+This is the glgen application used to generate OpenGL related classes from the
+official Khronos OpenGL specification and typemap files.
+
+To run this application download the gl.spec and gl.tm files from:
+
+http://www.opengl.org/registry/api/gl.spec
+http://www.opengl.org/registry/api/gl.tm
+
+and place them into the application directory. These files are not stored in
+the Qt Project's git repo or downloaded automatically to
+
+a) avoid copyright issues
+b) make sure the version of OpenGL used is controlled by a human
+
+The glgen application parses these files and generates:
+
+1) A set of public classes, one for each combination of OpenGL version and profile.
+2) A set of backend helper classes that contain the actual function pointers
+3) A factory class for the classes in 1)
+4) A set of classes, one for each OpenGL extension which introduces new entry points
+
+We will now describe each of these categories.
+
+
+OpenGL Version and Profile Classes
+==================================
+
+The base class of this set is QAbstractOpenGLFunctions. From this we inherit one class
+for each OpenGL version and if supported, profile.
+
+The Core profile contains only the non-deprecated functionality. The Compatibility profile
+also includes all functionality that was removed in OpenGL 3.1. Therefore, for OpenGL
+3.2 onwards we have two classes for each version.
+
+All of these classes are named with the following convention:
+
+QOpenGLFunctions_<MAJOR>_<MINOR>[_PROFILE]
+
+For example QOpenGLFunctions_2_1, QOpenGLFunctions_4_3_Core
+
+The source and header files for these classes take the form
+
+qopenglfunction_<MAJOR>_<MINOR>[_PROFILE].cpp
+qopenglfunction_<MAJOR>_<MINOR>[_PROFILE].h
+
+and should be moved to
+
+$QTBASE/src/gui/opengl/
+
+and forms part of the public QtGui library API.
+
+
+Backend Helper Classes
+======================
+
+Every OpenGL function is categorised by which version it was introduced with and
+whether it is part of the Core Profile and is deemed part of the core specification
+or whther it is only part of the Compatibility profile and has been marked as
+deprecated.
+
+Glgen creates a backend helper class containing function pointers to match each
+possible case. E.g. QOpenGLFunctions_1_5_CoreBackend contains functions introduced
+in OpenGL 1.5 which are still core (not deprecated).
+
+The public frontend classes described above contain pointers to the set of backend
+objects necessary to implement the functions for their version and profile.
+
+Creating new instances of these backend objects for each public version functions
+object would be wasteful in terms of memory (repeated function pointers) and CPU
+time (no need to keep re-solving the same functions).
+
+We cannot share the backend objects globally as OpenGL entry point addresses are
+specific to the OpenGL context. They cannot even be reliably shared between a
+context group. This is not surprising if you consider the case of contexts in a share
+group where the contexts have different versions or even profiles. We therefore share
+the backend instances at the QOpenGLContext level using a simple reference counting
+scheme.
+
+When the frontend version functions objects are intialized they check to see if
+the associated context already has suitable backend objects available. If so they use
+them, otherwise they will create backend objects and associate them with the context.
+
+The backend classes are in
+
+qopenglversionfunctions.h
+qopenglversionfunctions.cpp
+
+and should also be moved to
+
+$QTBASE/src/gui/opengl/
+
+
+OpenGL Version and Profile Factory
+==================================
+
+Instances of the OpenGL version and profile classes described above can be obtained
+from QOpenGLContext by means of the versionFunctions() member. The OpenGLContext
+retains ownership of the QOpenGLFunctions_* object. If a suitable object does not
+already exist it is created by the factory class generated by glgen.
+
+It is possible to request version functions objects for any version/profile
+combination from a context. However not all requests can be serviced. For example
+consider the case of an OpenGL 3.3 Core profile context. In this case:
+
+* Requesting a 3.3 core profile functions object would succeed.
+* Requesting a 3.3 compatibility profile functions object would fail. We would fail
+ to resolve the deprecated functions.
+* Requesting a 4.3 core profile functions object would fail. We would fail to resolve
+ the new core functions introduced in versions 4.0-4.3.
+* Requesting a 3.1 functions object would succeed. There is nothing in 3.1 that is not
+ also in 3.3 core.
+
+If a request is not able to be serviced the factory, and hence QOpenGLContext::versionFunctions()
+will return a null pointer that can be checked for.
+
+The source and header file for this class should be moved to
+
+$QTBASE/src/gui/opengl/
+
+and forms part of the QtGui library.
+
+If a user instantiates a version functions object directly (i.e. not via QOpenGLContext)
+then it bypasses the above checks. However, the same checks are applied in the
+initializeOpenGLFunctions() method and the result can once again be checked.
+
+This approach allows maximum flexibility but ensure's safety in that once the user
+posesses a functions object that has been successfully initialized they can rely upon its
+member functions being successfully resolved.
+
+
+OpenGL Extension Classes
+========================
+
+In addition, glgen also creates one class for each OpenGL extension that introduces
+new entry points. These classes are named with the convention
+
+QOpenGLExtension_<name-of-extension>
+
+The usage pattern for OpenGL extensions is to just use a small
+number of extensions out of the large number of those available.
+
+Rather than bloat QtGui with all possible extensions, a new static library will be
+introduced to hold these classes. That way users will only link in the code for
+the extensions that they actually use.
+
+The source and header file for these classes should be moved to
+
+$QTBASE/src/openglextensions/ \ No newline at end of file
diff --git a/util/glgen/codegenerator.cpp b/util/glgen/codegenerator.cpp
new file mode 100644
index 0000000000..c6a77569dc
--- /dev/null
+++ b/util/glgen/codegenerator.cpp
@@ -0,0 +1,1099 @@
+/***************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the utilities of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "codegenerator.h"
+
+#include <QDebug>
+#include <QFile>
+#include <QSettings>
+#include <QTextStream>
+
+static const QString extensionRegistryFileName = QStringLiteral("qopengl-extension-registry.ini");
+static const QString extensionIdGroupName = QStringLiteral("ExtensionIds");
+
+CodeGenerator::CodeGenerator()
+ : m_parser(0)
+{
+}
+
+void CodeGenerator::generateCoreClasses(const QString &baseFileName) const
+{
+ // Output header and implementation files for the backend and base class
+ writeCoreHelperClasses(baseFileName + QStringLiteral(".h"), Declaration);
+ writeCoreHelperClasses(baseFileName + QStringLiteral(".cpp"), Definition);
+
+ // Output the per-version and profile public classes
+ writeCoreClasses(baseFileName);
+
+ // We also need to generate a factory class that can be used by
+ // QOpenGLContext to actually create version function objects
+ writeCoreFactoryHeader(baseFileName + QStringLiteral("factory_p.h"));
+ writeCoreFactoryImplementation(baseFileName + QStringLiteral("factory.cpp"));
+}
+
+void CodeGenerator::generateExtensionClasses(const QString &baseFileName) const
+{
+ writeExtensionHeader(baseFileName + QStringLiteral(".h"));
+ writeExtensionImplementation(baseFileName + QStringLiteral(".cpp"));
+}
+
+bool CodeGenerator::isLegacyVersion(Version v) const
+{
+ return (v.major < 3 || (v.major == 3 && v.minor == 0));
+}
+
+bool CodeGenerator::versionHasProfiles(Version v) const
+{
+ VersionProfile vp;
+ vp.version = v;
+ return vp.hasProfiles();
+}
+
+void CodeGenerator::writeCoreHelperClasses(const QString &fileName, ClassComponent component) const
+{
+ if (!m_parser)
+ return;
+
+ QFile file(fileName);
+ if (!file.open(QIODevice::WriteOnly | QIODevice::Text))
+ return;
+ QTextStream stream(&file);
+
+ // Write the preamble
+ writePreamble(fileName, stream);
+
+ // Iterate over each OpenGL version. For each version output a private class for
+ // core functions and a private class for deprecated functions.
+ const QString privateRootClass = QStringLiteral("QOpenGLVersionFunctionsBackend");
+ Q_FOREACH (const VersionProfile &versionProfile, m_parser->versionProfiles()) {
+ switch (component) {
+ case Declaration:
+ writeBackendClassDeclaration(stream, versionProfile, privateRootClass);
+ break;
+
+ case Definition:
+ writeBackendClassImplementation(stream, versionProfile, privateRootClass);
+ break;
+ }
+ }
+
+ // Write the postamble
+ writePostamble(fileName, stream);
+}
+
+void CodeGenerator::writeCoreClasses(const QString &baseFileName) const
+{
+ // Iterate over each OpenGL version. For each version output a public class (for legacy
+ // versions or two public classes (for modern versions with profiles). Each public class
+ // is given pointers to private classes containing the actual entry points. For example,
+ // the class for OpenGL 1.1 will have pointers to the private classes for 1.0 core, 1.1
+ // core, 1.0 deprecated and 1.1 deprecated. Whereas the class for OpenGL 3.2 Core profile
+ // will have pointers to the private classes for 1.0 core, 1.1 core, ..., 3.2 core but
+ // not to any of the deprecated private classes
+ QList<ClassComponent> components = (QList<ClassComponent>() << Declaration << Definition);
+ Q_FOREACH (const ClassComponent &component, components) {
+ const QString rootClass = QStringLiteral("QAbstractOpenGLFunctions");
+ Q_FOREACH (const Version &classVersion, m_parser->versions()) {
+ VersionProfile v;
+ v.version = classVersion;
+ v.profile = VersionProfile::CompatibilityProfile;
+
+ if (isLegacyVersion(classVersion)) {
+ switch (component) {
+ case Declaration:
+ writePublicClassDeclaration(baseFileName, v, rootClass);
+ break;
+
+ case Definition:
+ writePublicClassImplementation(baseFileName, v, rootClass);
+ break;
+ }
+ } else {
+ switch (component) {
+ case Declaration:
+ writePublicClassDeclaration(baseFileName, v, rootClass);
+ v.profile = VersionProfile::CoreProfile;
+ writePublicClassDeclaration(baseFileName, v, rootClass);
+ break;
+
+ case Definition:
+ writePublicClassImplementation(baseFileName, v, rootClass);
+ v.profile = VersionProfile::CoreProfile;
+ writePublicClassImplementation(baseFileName, v, rootClass);
+ break;
+ }
+ }
+ }
+ }
+}
+
+void CodeGenerator::writeCoreFactoryHeader(const QString &fileName) const
+{
+ if (!m_parser)
+ return;
+
+ QFile file(fileName);
+ if (!file.open(QIODevice::WriteOnly | QIODevice::Text))
+ return;
+ QTextStream stream(&file);
+
+ // Write the preamble
+ writePreamble(fileName, stream);
+
+ // Write the postamble
+ writePostamble(fileName, stream);
+}
+
+void CodeGenerator::writeCoreFactoryImplementation(const QString &fileName) const
+{
+ if (!m_parser)
+ return;
+
+ QFile file(fileName);
+ if (!file.open(QIODevice::WriteOnly | QIODevice::Text))
+ return;
+ QTextStream stream(&file);
+
+ // Write the preamble
+ writePreamble(fileName, stream);
+
+ // Get the set of version functions classes we need to create
+ QList<Version> versions = m_parser->versions();
+ qSort(versions.begin(), versions.end(), qGreater<Version>());
+
+ // Outout the #include statements
+ stream << QStringLiteral("#if !defined(QT_OPENGL_ES_2)") << endl;
+ Q_FOREACH (const Version &classVersion, versions) {
+ if (!versionHasProfiles(classVersion)) {
+ stream << QString(QStringLiteral("#include \"qopenglfunctions_%1_%2.h\""))
+ .arg(classVersion.major)
+ .arg(classVersion.minor) << endl;
+ } else {
+ const QList<VersionProfile::OpenGLProfile> profiles = (QList<VersionProfile::OpenGLProfile>()
+ << VersionProfile::CoreProfile << VersionProfile::CompatibilityProfile);
+
+ Q_FOREACH (const VersionProfile::OpenGLProfile profile, profiles) {
+ const QString profileSuffix = profile == VersionProfile::CoreProfile
+ ? QStringLiteral("core")
+ : QStringLiteral("compatibility");
+ stream << QString(QStringLiteral("#include \"qopenglfunctions_%1_%2_%3.h\""))
+ .arg(classVersion.major)
+ .arg(classVersion.minor)
+ .arg(profileSuffix) << endl;
+ }
+ }
+ }
+ stream << QStringLiteral("#else") << endl;
+ stream << QStringLiteral("#include \"qopenglfunctions_es2.h\"") << endl;
+ stream << QStringLiteral("#endif") << endl;
+
+ stream << endl;
+
+ stream << QStringLiteral("QT_BEGIN_NAMESPACE") << endl << endl;
+ stream << QStringLiteral("QAbstractOpenGLFunctions *QOpenGLVersionFunctionsFactory::create(const QOpenGLVersionProfile &versionProfile)") << endl;
+ stream << QStringLiteral("{") << endl;
+ stream << QStringLiteral("#if !defined(QT_OPENGL_ES_2)") << endl;
+ stream << QStringLiteral(" const int major = versionProfile.version().first;") << endl;
+ stream << QStringLiteral(" const int minor = versionProfile.version().second;") << endl << endl;
+
+ // Iterate over classes with profiles
+ stream << QStringLiteral(" if (versionProfile.hasProfiles()) {") << endl;
+ stream << QStringLiteral(" switch (versionProfile.profile()) {") << endl;
+ const QList<VersionProfile::OpenGLProfile> profiles = (QList<VersionProfile::OpenGLProfile>()
+ << VersionProfile::CoreProfile << VersionProfile::CompatibilityProfile);
+ Q_FOREACH (const VersionProfile::OpenGLProfile profile, profiles) {
+ const QString caseLabel = profile == VersionProfile::CoreProfile
+ ? QStringLiteral("QSurfaceFormat::CoreProfile")
+ : QStringLiteral("QSurfaceFormat::CompatibilityProfile");
+ stream << QString(QStringLiteral(" case %1:")).arg(caseLabel) << endl;
+
+ int i = 0;
+ Q_FOREACH (const Version &classVersion, versions) {
+ if (!versionHasProfiles(classVersion))
+ continue;
+
+ const QString ifString = (i++ == 0) ? QStringLiteral("if") : QStringLiteral("else if");
+ stream << QString(QStringLiteral(" %1 (major == %2 && minor == %3)"))
+ .arg(ifString)
+ .arg(classVersion.major)
+ .arg(classVersion.minor) << endl;
+
+ VersionProfile v;
+ v.version = classVersion;
+ v.profile = profile;
+ stream << QString(QStringLiteral(" return new %1;"))
+ .arg(generateClassName(v)) << endl;
+ }
+
+ stream << QStringLiteral(" break;") << endl << endl;
+ }
+
+ stream << QStringLiteral(" case QSurfaceFormat::NoProfile:") << endl;
+ stream << QStringLiteral(" default:") << endl;
+ stream << QStringLiteral(" break;") << endl;
+ stream << QStringLiteral(" };") << endl;
+ stream << QStringLiteral(" } else {") << endl;
+
+ // Iterate over the legacy classes (no profiles)
+ int i = 0;
+ Q_FOREACH (const Version &classVersion, versions) {
+ if (versionHasProfiles(classVersion))
+ continue;
+
+ const QString ifString = (i++ == 0) ? QStringLiteral("if") : QStringLiteral("else if");
+ stream << QString(QStringLiteral(" %1 (major == %2 && minor == %3)"))
+ .arg(ifString)
+ .arg(classVersion.major)
+ .arg(classVersion.minor) << endl;
+
+ VersionProfile v;
+ v.version = classVersion;
+ stream << QString(QStringLiteral(" return new %1;"))
+ .arg(generateClassName(v)) << endl;
+ }
+
+ stream << QStringLiteral(" }") << endl;
+ stream << QStringLiteral(" return 0;") << endl;
+
+ stream << QStringLiteral("#else") << endl;
+ stream << QStringLiteral(" Q_UNUSED(versionProfile);") << endl;
+ stream << QStringLiteral(" return new QOpenGLFunctions_ES2;") << endl;
+ stream << QStringLiteral("#endif") << endl;
+ stream << QStringLiteral("}") << endl;
+
+ // Write the postamble
+ writePostamble(fileName, stream);
+}
+
+/**
+ \returns all functions to be included in the class defined by \a classVersionProfile
+ */
+FunctionCollection CodeGenerator::functionCollection( const VersionProfile& classVersionProfile ) const
+{
+ const Version classVersion = classVersionProfile.version;
+ FunctionCollection functionSet;
+ QList<Version> versions = m_parser->versions();
+
+ // Populate these based upon the class version and profile
+ Version minVersion;
+ minVersion.major = 1;
+ minVersion.minor = 0;
+ Version maxVersion = classVersion;
+ QList<VersionProfile::OpenGLProfile> profiles;
+ profiles << VersionProfile::CoreProfile; // Always need core functions
+
+ if (isLegacyVersion(classVersion)
+ || (classVersionProfile.hasProfiles()
+ && classVersionProfile.profile == VersionProfile::CompatibilityProfile)) {
+ // For versions < 3.1 and Compatibility profile we include both core and deprecated functions
+ profiles << VersionProfile::CompatibilityProfile;
+ }
+
+ Q_FOREACH (const Version &v, versions) {
+ // Only include functions from versions in the range
+ if (v < minVersion)
+ continue;
+ if (v > maxVersion)
+ break;
+
+ Q_FOREACH (VersionProfile::OpenGLProfile profile, profiles) {
+ // Combine version and profile for this subset of functions
+ VersionProfile version;
+ version.version = v;
+ version.profile = profile;
+
+ // Fetch the functions and add to collection for this class
+ QList<Function> functions = m_parser->functionsForVersion(version);
+ functionSet.insert(version, functions);
+ }
+ }
+
+ return functionSet;
+}
+
+void CodeGenerator::writePreamble(const QString &baseFileName, QTextStream &stream, const QString replacement) const
+{
+ const QString fileName = baseFileName + QStringLiteral(".header");
+ if (!QFile::exists(fileName))
+ return;
+
+ QFile file(fileName);
+ if (file.open(QIODevice::ReadOnly | QIODevice::Text)) {
+ QTextStream preambleStream(&file);
+ QString preamble = preambleStream.readAll();
+ if (!replacement.isEmpty())
+ preamble.replace(QStringLiteral("__VERSION__"), replacement, Qt::CaseSensitive);
+ stream << preamble;
+ }
+}
+
+void CodeGenerator::writePostamble(const QString &baseFileName, QTextStream &stream) const
+{
+ const QString fileName = baseFileName + QStringLiteral(".footer");
+ if (!QFile::exists(fileName))
+ return;
+
+ QFile file(fileName);
+ if (file.open(QIODevice::ReadOnly | QIODevice::Text)) {
+ QTextStream postambleStream(&file);
+ QString postamble = postambleStream.readAll();
+ stream << postamble;
+ }
+}
+
+QString CodeGenerator::passByType(const Argument &arg) const
+{
+ QString passBy;
+ switch (arg.mode) {
+ case Argument::Reference:
+ case Argument::Array:
+ passBy = QStringLiteral("*");
+ break;
+
+ default:
+ case Argument::Value:
+ passBy = QString();
+ }
+ return passBy;
+}
+
+QString CodeGenerator::safeArgumentName(const QString& arg) const
+{
+ if (arg == QStringLiteral("near")) // MS Windows defines near and far
+ return QStringLiteral("nearVal");
+ else if (arg == QStringLiteral("far"))
+ return QStringLiteral("farVal");
+ else if (arg == QStringLiteral("d"))
+ return QStringLiteral("dd"); // Don't shadow d pointer
+ else
+ return arg;
+}
+
+QString CodeGenerator::generateClassName(const VersionProfile &classVersion, ClassVisibility visibility) const
+{
+ QString className;
+ switch ( visibility ) {
+ case Public: {
+ // Class name and base class
+ QString profileSuffix;
+ if (classVersion.hasProfiles())
+ profileSuffix = (classVersion.profile == VersionProfile::CoreProfile ? QStringLiteral("_Core") : QStringLiteral("_Compatibility"));
+
+ className = QString(QStringLiteral("QOpenGLFunctions_%1_%2%3"))
+ .arg(classVersion.version.major)
+ .arg(classVersion.version.minor)
+ .arg(profileSuffix);
+ break;
+ }
+ case Private: {
+ QString statusSuffix = (classVersion.profile == VersionProfile::CoreProfile ? QStringLiteral("_Core") : QStringLiteral("_Deprecated"));
+
+ className = QString(QStringLiteral("QOpenGLFunctions_%1_%2%3Private"))
+ .arg(classVersion.version.major)
+ .arg(classVersion.version.minor)
+ .arg(statusSuffix);
+ break;
+ }
+ }
+
+ return className;
+}
+
+void CodeGenerator::writeBackendClassDeclaration(QTextStream &stream,
+ const VersionProfile &versionProfile,
+ const QString &baseClass) const
+{
+ const QString className = backendClassName(versionProfile);
+ stream << QString(QStringLiteral("class %1 : public %2"))
+ .arg(className)
+ .arg(baseClass)
+ << endl;
+ stream << QStringLiteral("{") << endl;
+ stream << QStringLiteral("public:") << endl;
+ stream << QString( QStringLiteral(" %1(QOpenGLContext *context);") ).arg(className) << endl << endl;
+
+ // Output function used for generating key used in QOpenGLContextPrivate
+ stream << QStringLiteral(" static QOpenGLVersionStatus versionStatus();") << endl << endl;
+
+ // Get the functions needed for this class
+ FunctionList functions = m_parser->functionsForVersion(versionProfile);
+ FunctionCollection functionSet;
+ functionSet.insert(versionProfile, functions);
+
+ // Declare the functions
+ writeClassFunctionDeclarations(stream, functionSet, Private);
+
+ stream << QStringLiteral("};") << endl;
+ stream << endl;
+}
+
+void CodeGenerator::writeBackendClassImplementation(QTextStream &stream,
+ const VersionProfile &versionProfile,
+ const QString &baseClass) const
+{
+ const QString className = backendClassName(versionProfile);
+ stream << QString(QStringLiteral("%1::%1(QOpenGLContext *context)")).arg(className) << endl;
+ stream << QString(QStringLiteral(" : %1(context)")).arg(baseClass) << endl
+ << QStringLiteral("{") << endl;
+
+ // Resolve the entry points for this set of functions
+ // Get the functions needed for this class
+ FunctionList functions = m_parser->functionsForVersion(versionProfile);
+ FunctionCollection functionSet;
+ functionSet.insert(versionProfile, functions);
+ writeEntryPointResolutionCode(stream, functionSet);
+
+ stream << QStringLiteral("}") << endl << endl;
+
+ stream << QString(QStringLiteral("QOpenGLVersionStatus %1::versionStatus()")).arg(className) << endl;
+ stream << QStringLiteral("{") << endl;
+ const QString status = versionProfile.profile == VersionProfile::CoreProfile
+ ? QStringLiteral("QOpenGLVersionStatus::CoreStatus")
+ : QStringLiteral("QOpenGLVersionStatus::DeprecatedStatus");
+ stream << QString(QStringLiteral(" return QOpenGLVersionStatus(%1, %2, %3);"))
+ .arg(versionProfile.version.major)
+ .arg(versionProfile.version.minor)
+ .arg(status) << endl;
+ stream << QStringLiteral("}") << endl << endl;
+}
+
+QString CodeGenerator::coreClassFileName(const VersionProfile &versionProfile,
+ const QString& fileExtension) const
+{
+ QString profileSuffix;
+ if (versionProfile.hasProfiles())
+ profileSuffix = (versionProfile.profile == VersionProfile::CoreProfile ? QStringLiteral("_core") : QStringLiteral("_compatibility"));
+
+ const QString fileName = QString(QStringLiteral("qopenglfunctions_%1_%2%3.%4"))
+ .arg(versionProfile.version.major)
+ .arg(versionProfile.version.minor)
+ .arg(profileSuffix)
+ .arg(fileExtension);
+ return fileName;
+}
+
+void CodeGenerator::writePublicClassDeclaration(const QString &baseFileName,
+ const VersionProfile &versionProfile,
+ const QString &baseClass) const
+{
+ const QString fileName = coreClassFileName(versionProfile, QStringLiteral("h"));
+ QFile file(fileName);
+ if (!file.open(QIODevice::WriteOnly | QIODevice::Text))
+ return;
+ QTextStream stream(&file);
+
+ // Write the preamble
+ const QString templateFileName = QString(QStringLiteral("%1__VERSION__.h"))
+ .arg(baseFileName);
+ QString profileSuffix;
+ if (versionProfile.hasProfiles())
+ profileSuffix = (versionProfile.profile == VersionProfile::CoreProfile ? QStringLiteral("_CORE") : QStringLiteral("_COMPATIBILITY"));
+
+ const QString versionProfileString = QString(QStringLiteral("_%1_%2%3"))
+ .arg(versionProfile.version.major)
+ .arg(versionProfile.version.minor)
+ .arg(profileSuffix);
+ writePreamble(templateFileName, stream, versionProfileString);
+
+ // Ctor, dtor, and initialize function;
+ const QString className = generateClassName(versionProfile, Public);
+ stream << QString(QStringLiteral("class Q_GUI_EXPORT %1 : public %2"))
+ .arg(className)
+ .arg(baseClass)
+ << endl;
+ stream << QStringLiteral("{") << endl;
+ stream << QStringLiteral("public:") << endl;
+ stream << QString(QStringLiteral(" %1();")).arg(className) << endl;
+ stream << QString(QStringLiteral(" ~%1();")).arg(className) << endl << endl;
+ stream << QStringLiteral(" bool initializeOpenGLFunctions() Q_DECL_OVERRIDE;") << endl << endl;
+
+ // Get the functions needed for this class and declare them
+ FunctionCollection functionSet = functionCollection(versionProfile);
+ writeClassFunctionDeclarations(stream, functionSet, Public);
+
+ // isCompatible function and backend variables
+ stream << QStringLiteral("private:") << endl;
+ stream << QStringLiteral(" friend class QOpenGLContext;") << endl << endl;
+ stream << QStringLiteral(" static bool isContextCompatible(QOpenGLContext *context);") << endl;
+ stream << QStringLiteral(" static QOpenGLVersionProfile versionProfile();") << endl << endl;
+ writeBackendVariableDeclarations(stream, backendsForFunctionCollection(functionSet));
+
+ stream << QStringLiteral("};") << endl << endl;
+
+ // Output the inline functions that forward OpenGL calls to the backends' entry points
+ writeClassInlineFunctions(stream, className, functionSet);
+
+ // Write the postamble
+ writePostamble(templateFileName, stream);
+}
+
+void CodeGenerator::writePublicClassImplementation(const QString &baseFileName,
+ const VersionProfile &versionProfile,
+ const QString& baseClass) const
+{
+ const QString fileName = coreClassFileName(versionProfile, QStringLiteral("cpp"));
+ QFile file(fileName);
+ if (!file.open(QIODevice::WriteOnly | QIODevice::Text))
+ return;
+ QTextStream stream(&file);
+
+ // Write the preamble
+ const QString templateFileName = QString(QStringLiteral("%1__VERSION__.cpp"))
+ .arg(baseFileName);
+ QString profileSuffix;
+ if (versionProfile.hasProfiles())
+ profileSuffix = (versionProfile.profile == VersionProfile::CoreProfile ? QStringLiteral("_core") : QStringLiteral("_compatibility"));
+
+ const QString versionProfileString = QString(QStringLiteral("_%1_%2%3"))
+ .arg(versionProfile.version.major)
+ .arg(versionProfile.version.minor)
+ .arg(profileSuffix);
+ writePreamble(templateFileName, stream, versionProfileString);
+
+ const QString className = generateClassName(versionProfile, Public);
+ stream << QStringLiteral("/*!") << endl
+ << QStringLiteral(" \\class ") << className << endl
+ << QStringLiteral(" \\inmodule QtGui") << endl
+ << QStringLiteral(" \\since 5.1") << endl
+ << QStringLiteral(" \\brief The ") << className
+ << QStringLiteral(" class provides all functions for this version and profile of OpenGL.") << endl << endl
+ << QStringLiteral(" \\sa QAbstractOpenGLFunctions") << endl
+ << QStringLiteral("*/") << endl << endl;
+
+ // Get the data we'll need for this class implementation
+ FunctionCollection functionSet = functionCollection(versionProfile);
+ QList<VersionProfile> backends = backendsForFunctionCollection(functionSet);
+
+ // Output default constructor
+ stream << className << QStringLiteral("::") << className << QStringLiteral("()") << endl;
+ stream << QStringLiteral(" : ") << baseClass << QStringLiteral("()");
+ Q_FOREACH (const VersionProfile &v, backends)
+ stream << endl << QString(QStringLiteral(" , %1(0)")).arg(backendVariableName(v));
+ stream << endl << QStringLiteral("{") << endl << QStringLiteral("}") << endl << endl;
+
+ // Output the destructor
+ stream << className << QStringLiteral("::~") << className << QStringLiteral("()") << endl;
+ stream << QStringLiteral("{") << endl;
+ Q_FOREACH (const VersionProfile &v, backends) {
+ const QString backendVar = backendVariableName(v);
+ const QString backendClass = backendClassName(v);
+ stream << QString(QStringLiteral(" if (%1 && !%1->refs.deref()) {")).arg(backendVar) << endl;
+ stream << QString(QStringLiteral(" QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(%1->context, %2::versionStatus());"))
+ .arg(backendVar)
+ .arg(backendClass) << endl;
+ stream << QString(QStringLiteral(" delete %1;")).arg(backendVar) << endl;
+ stream << QStringLiteral(" }") << endl;
+ }
+ stream << QStringLiteral("}") << endl << endl;
+
+ // Output the initialize function that creates the backend objects
+ stream << QString(QStringLiteral("bool %1::initializeOpenGLFunctions()")).arg(className) << endl;
+ stream << QStringLiteral("{") << endl;
+
+ stream << QStringLiteral(" if ( isInitialized() )") << endl;
+ stream << QStringLiteral(" return true;") << endl << endl;
+ stream << QStringLiteral(" QOpenGLContext* context = QOpenGLContext::currentContext();") << endl << endl;
+ stream << QStringLiteral(" // If owned by a context object make sure it is current.") << endl;
+ stream << QStringLiteral(" // Also check that current context is capable of resolving all needed functions") << endl;
+ stream << QStringLiteral(" if (((owningContext() && owningContext() == context) || !owningContext())") << endl;
+ stream << QString(QStringLiteral(" && %1::isContextCompatible(context))")).arg(className) << endl;
+ stream << QStringLiteral(" {") << endl;
+ stream << QStringLiteral(" // Associate with private implementation, creating if necessary") << endl;
+ stream << QStringLiteral(" // Function pointers in the backends are resolved at creation time") << endl;
+ stream << QStringLiteral(" QOpenGLVersionFunctionsBackend* d = 0;") << endl;
+
+ Q_FOREACH (const VersionProfile &v, backends) {
+ const QString backendClass = backendClassName(v);
+ const QString backendVar = backendVariableName(v);
+ stream << QString(QStringLiteral(" d = QAbstractOpenGLFunctionsPrivate::functionsBackend(context, %1::versionStatus());"))
+ .arg(backendClass) << endl;
+ stream << QStringLiteral(" if (!d) {") << endl;
+ stream << QString(QStringLiteral(" d = new %1(context);")).arg(backendClass) << endl;
+ stream << QString(QStringLiteral(" QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(context, %1::versionStatus(), d);"))
+ .arg(backendClass) << endl;
+ stream << QStringLiteral(" }") << endl;
+ stream << QString(QStringLiteral(" %1 = static_cast<%2*>(d);")).arg(backendVar).arg(backendClass) << endl;
+ stream << QStringLiteral(" d->refs.ref();") << endl << endl;
+ }
+
+ stream << QStringLiteral(" QAbstractOpenGLFunctions::initializeOpenGLFunctions();") << endl;
+ stream << QStringLiteral(" }") << endl;
+
+ stream << QStringLiteral(" return isInitialized();") << endl;
+ stream << QStringLiteral("}") << endl << endl;
+
+ // Output the context compatibility check function
+ stream << QString(QStringLiteral("bool %1::isContextCompatible(QOpenGLContext *context)")).arg(className) << endl;
+ stream << QStringLiteral("{") << endl;
+ stream << QStringLiteral(" Q_ASSERT(context);") << endl;
+ stream << QStringLiteral(" QSurfaceFormat f = context->format();") << endl;
+ stream << QStringLiteral(" const QPair<int, int> v = qMakePair(f.majorVersion(), f.minorVersion());") << endl;
+ stream << QString(QStringLiteral(" if (v < qMakePair(%1, %2))"))
+ .arg(versionProfile.version.major)
+ .arg(versionProfile.version.minor) << endl;
+ stream << QStringLiteral(" return false;") << endl << endl;
+
+ // If generating a legacy or compatibility profile class we need to ensure that
+ // the context does not expose only core functions
+ if (versionProfile.profile != VersionProfile::CoreProfile) {
+ stream << QStringLiteral(" if (f.profile() == QSurfaceFormat::CoreProfile)") << endl;
+ stream << QStringLiteral(" return false;") << endl << endl;
+ }
+
+ stream << QStringLiteral(" return true;") << endl;
+ stream << QStringLiteral("}") << endl << endl;
+
+ // Output static function used as helper in template versionFunctions() function
+ // in QOpenGLContext
+ stream << QString(QStringLiteral("QOpenGLVersionProfile %1::versionProfile()")).arg(className) << endl;
+ stream << QStringLiteral("{") << endl;
+ stream << QStringLiteral(" QOpenGLVersionProfile v;") << endl;
+ stream << QString(QStringLiteral(" v.setVersion(%1, %2);"))
+ .arg(versionProfile.version.major)
+ .arg(versionProfile.version.minor) << endl;
+ if (versionProfile.hasProfiles()) {
+ const QString profileName = versionProfile.profile == VersionProfile::CoreProfile
+ ? QStringLiteral("QSurfaceFormat::CoreProfile")
+ : QStringLiteral("QSurfaceFormat::CompatibilityProfile");
+ stream << QString(QStringLiteral(" v.setProfile(%1);")).arg(profileName) << endl;
+ }
+ stream << QStringLiteral(" return v;") << endl;
+ stream << QStringLiteral("}") << endl;
+
+ // Write the postamble
+ writePostamble(templateFileName, stream);
+}
+
+void CodeGenerator::writeClassFunctionDeclarations(QTextStream &stream,
+ const FunctionCollection &functionSet,
+ ClassVisibility visibility) const
+{
+ Q_FOREACH (const VersionProfile &version, functionSet.keys()) {
+ // Add a comment to the header
+ stream << QString(QStringLiteral(" // OpenGL %1.%2 %3 functions"))
+ .arg(version.version.major)
+ .arg(version.version.minor)
+ .arg((version.profile == VersionProfile::CoreProfile) ? QStringLiteral("core") : QStringLiteral("deprecated"))
+ << endl;
+
+ // Output function declarations
+ FunctionList functions = functionSet.value(version);
+ Q_FOREACH (const Function &f, functions)
+ writeFunctionDeclaration(stream, f, visibility);
+ stream << endl;
+ } // version and profile
+}
+
+void CodeGenerator::writeFunctionDeclaration(QTextStream &stream, const Function &f, ClassVisibility visibility) const
+{
+ QStringList argList;
+ Q_FOREACH (const Argument &arg, f.arguments) {
+ QString a = QString(QStringLiteral("%1%2 %3%4"))
+ .arg((arg.direction == Argument::In && arg.mode != Argument::Value) ? QStringLiteral("const ") : QString())
+ .arg(arg.type)
+ .arg(passByType(arg))
+ .arg(safeArgumentName(arg.name));
+ argList.append(a);
+ }
+ QString args = argList.join(QStringLiteral(", "));
+
+ QString signature;
+ switch (visibility) {
+ case Public:
+ signature = QString(QStringLiteral(" %1 gl%2(%3);")).arg(f.returnType).arg(f.name).arg(args);
+ break;
+
+ case Private:
+ default:
+ signature = QString(QStringLiteral(" %1 (QOPENGLF_APIENTRYP %2)(%3);")).arg(f.returnType).arg(f.name).arg(args);
+ }
+ stream << signature << endl;
+}
+
+void CodeGenerator::writeClassInlineFunctions(QTextStream &stream,
+ const QString &className,
+ const FunctionCollection &functionSet) const
+{
+ Q_FOREACH (const VersionProfile &version, functionSet.keys()) {
+
+ // Add a comment to the header
+ stream << QString(QStringLiteral("// OpenGL %1.%2 %3 functions"))
+ .arg(version.version.major)
+ .arg(version.version.minor)
+ .arg((version.profile == VersionProfile::CoreProfile) ? QStringLiteral("core") : QStringLiteral("deprecated"))
+ << endl;
+
+ // Output function declarations
+ const QString backendVar = backendVariableName(version);
+ FunctionList functions = functionSet.value(version);
+ Q_FOREACH (const Function &f, functions)
+ writeInlineFunction(stream, className, backendVar, f);
+
+ stream << endl;
+
+ } // version and profile
+}
+
+void CodeGenerator::writeInlineFunction(QTextStream &stream, const QString &className,
+ const QString &backendVar, const Function &f) const
+{
+ QStringList argList;
+ Q_FOREACH (const Argument &arg, f.arguments) {
+ QString a = QString(QStringLiteral("%1%2 %3%4"))
+ .arg((arg.direction == Argument::In && arg.mode != Argument::Value) ? QStringLiteral("const ") : QString())
+ .arg(arg.type)
+ .arg(passByType(arg))
+ .arg(safeArgumentName(arg.name));
+ argList.append(a);
+ }
+ QString args = argList.join(", ");
+
+
+ QString signature = QString(QStringLiteral("inline %1 %2::gl%3(%4)"))
+ .arg(f.returnType)
+ .arg(className)
+ .arg(f.name)
+ .arg(args);
+ stream << signature << endl << QStringLiteral("{") << endl;
+
+ QStringList argumentNames;
+ Q_FOREACH (const Argument &arg, f.arguments)
+ argumentNames.append(safeArgumentName(arg.name));
+ QString argNames = argumentNames.join(", ");
+
+ if (f.returnType == QStringLiteral("void"))
+ stream << QString(QStringLiteral(" %1->%2(%3);")).arg(backendVar).arg(f.name).arg(argNames) << endl;
+ else
+ stream << QString(QStringLiteral(" return %1->%2(%3);")).arg(backendVar).arg(f.name).arg(argNames) << endl;
+ stream << QStringLiteral("}") << endl << endl;
+}
+
+void CodeGenerator::writeEntryPointResolutionCode(QTextStream &stream,
+ const FunctionCollection &functionSet) const
+{
+ bool hasModuleHandle = false;
+ Q_FOREACH (const VersionProfile &version, functionSet.keys()) {
+
+ // Add a comment to the header
+ stream << QString(QStringLiteral(" // OpenGL %1.%2 %3 functions"))
+ .arg(version.version.major)
+ .arg(version.version.minor)
+ .arg((version.profile == VersionProfile::CoreProfile) ? QStringLiteral("core") : QStringLiteral("deprecated"))
+ << endl;
+
+ // Output function declarations
+ FunctionList functions = functionSet.value(version);
+
+ bool useGetProcAddress = (version.version.major == 1 && (version.version.minor == 0 || version.version.minor == 1));
+ if (useGetProcAddress) {
+ stream << "#if defined(Q_OS_WIN)" << endl;
+ if (!hasModuleHandle) {
+ stream << " HMODULE handle = GetModuleHandleA(\"opengl32.dll\");" << endl;
+ hasModuleHandle = true;
+ }
+
+ Q_FOREACH (const Function &f, functions)
+ writeEntryPointResolutionStatement(stream, f, QString(), useGetProcAddress);
+
+ stream << "#else" << endl;
+ }
+
+ Q_FOREACH (const Function &f, functions)
+ writeEntryPointResolutionStatement(stream, f);
+
+ if (useGetProcAddress)
+ stream << "#endif" << endl;
+
+ stream << endl;
+
+ } // version and profile
+}
+
+void CodeGenerator::writeEntryPointResolutionStatement(QTextStream &stream, const Function &f,
+ const QString &prefix, bool useGetProcAddress) const
+{
+ QStringList argList;
+ Q_FOREACH (const Argument &arg, f.arguments) {
+ QString a = QString("%1%2 %3")
+ .arg((arg.direction == Argument::In && arg.mode != Argument::Value) ? QStringLiteral("const ") : QString())
+ .arg(arg.type)
+ .arg(passByType(arg));
+ argList.append(a);
+ }
+ QString args = argList.join(QStringLiteral(", "));
+
+ QString signature;
+ if (!useGetProcAddress) {
+ signature = QString(QStringLiteral(" %4%3 = reinterpret_cast<%1 (QOPENGLF_APIENTRYP)(%2)>(context->getProcAddress(\"gl%3\"));"))
+ .arg(f.returnType)
+ .arg(args)
+ .arg(f.name)
+ .arg(prefix);
+ } else {
+ signature = QString(QStringLiteral(" %4%3 = reinterpret_cast<%1 (QOPENGLF_APIENTRYP)(%2)>(GetProcAddress(handle, \"gl%3\"));"))
+ .arg(f.returnType)
+ .arg(args)
+ .arg(f.name)
+ .arg(prefix);
+ }
+ stream << signature << endl;
+}
+
+QList<VersionProfile> CodeGenerator::backendsForFunctionCollection(const FunctionCollection &functionSet) const
+{
+ QList<VersionProfile> backends;
+ Q_FOREACH (const VersionProfile &versionProfile, functionSet.keys()) {
+ if (m_parser->versionProfiles().contains(versionProfile))
+ backends.append(versionProfile);
+ }
+ return backends;
+}
+
+QString CodeGenerator::backendClassName(const VersionProfile &v) const
+{
+ QString statusSuffix = v.profile == VersionProfile::CoreProfile
+ ? QStringLiteral("_Core")
+ : QStringLiteral("_Deprecated");
+ const QString className = QString(QStringLiteral("QOpenGLFunctions_%1_%2%3Backend"))
+ .arg(v.version.major)
+ .arg(v.version.minor)
+ .arg(statusSuffix);
+ return className;
+}
+
+QString CodeGenerator::backendVariableName(const VersionProfile &v) const
+{
+ const QString status = (v.profile == VersionProfile::CoreProfile)
+ ? QStringLiteral("Core")
+ : QStringLiteral("Deprecated");
+ const QString varName = QString(QStringLiteral("d_%1_%2_%3"))
+ .arg(v.version.major)
+ .arg(v.version.minor)
+ .arg(status);
+ return varName;
+}
+
+void CodeGenerator::writeBackendVariableDeclarations(QTextStream &stream, const QList<VersionProfile> &backends) const
+{
+ // We need a private class for each version and profile (status: core or deprecated)
+ Q_FOREACH (const VersionProfile &v, backends) {
+ const QString className = backendClassName(v);
+ const QString varName = backendVariableName(v);
+ stream << QString(QStringLiteral(" %1* %2;")).arg(className).arg(varName) << endl;
+ }
+}
+
+void CodeGenerator::writeExtensionHeader(const QString &fileName) const
+{
+ if (!m_parser)
+ return;
+
+ QFile file(fileName);
+ if (!file.open(QIODevice::WriteOnly | QIODevice::Text))
+ return;
+ QTextStream stream(&file);
+
+ // Write the preamble
+ writePreamble(fileName, stream);
+
+ // Iterate through the list of extensions and create one class per extension
+ QStringList extensions = m_parser->extensions();
+ Q_FOREACH (const QString &extension, extensions) {
+ writeExtensionClassDeclaration(stream, extension, Private);
+ writeExtensionClassDeclaration(stream, extension, Public);
+ }
+
+ // Write the postamble
+ writePostamble(fileName, stream);
+}
+
+void CodeGenerator::writeExtensionImplementation(const QString &fileName) const
+{
+ if (!m_parser)
+ return;
+
+ QFile file(fileName);
+ if (!file.open(QIODevice::WriteOnly | QIODevice::Text))
+ return;
+ QTextStream stream(&file);
+
+ // Write the preamble
+ writePreamble(fileName, stream);
+
+ // Iterate through the list of extensions and create one class per extension
+ QStringList extensions = m_parser->extensions();
+ Q_FOREACH (const QString &extension, extensions)
+ writeExtensionClassImplementation(stream, extension);
+
+ // Write the postamble
+ writePostamble(fileName, stream);
+}
+
+void CodeGenerator::writeExtensionClassDeclaration(QTextStream &stream, const QString &extension, ClassVisibility visibility) const
+{
+ const QString className = generateExtensionClassName(extension, visibility);
+
+ QString baseClass = (visibility == Public) ? QStringLiteral("QAbstractOpenGLExtension") : QStringLiteral("QAbstractOpenGLExtensionPrivate");
+
+ stream << QString(QStringLiteral("class %2 : public %3"))
+ .arg(className)
+ .arg(baseClass)
+ << endl << "{" << endl << "public:" << endl;
+
+ if (visibility == Public) {
+ // Default constructor
+ stream << QStringLiteral(" ") << className << QStringLiteral("();") << endl << endl;
+
+ // Base class virtual function(s)
+ QString resolveFunction = QStringLiteral(" bool initializeOpenGLFunctions() Q_DECL_FINAL;");
+ stream << resolveFunction << endl << endl;
+ }
+
+ // Output the functions provided by this extension
+ QList<Function> functions = m_parser->functionsForExtension(extension);
+ Q_FOREACH (const Function &f, functions)
+ writeFunctionDeclaration(stream, f, visibility);
+
+ if (visibility == Public) {
+ // Write out the protected ctor
+ stream << endl << QStringLiteral("protected:") << endl;
+ stream << QStringLiteral(" Q_DECLARE_PRIVATE(") << className << QStringLiteral(")") << endl;
+ }
+
+ // End the class declaration
+ stream << QStringLiteral("};") << endl << endl;
+
+ // Output the inline functions for public class
+ if (visibility == Public) {
+ Q_FOREACH (const Function &f, functions)
+ writeExtensionInlineFunction(stream, className, f);
+ }
+}
+
+void CodeGenerator::writeExtensionInlineFunction(QTextStream &stream, const QString &className, const Function &f) const
+{
+ QStringList argList;
+ Q_FOREACH (const Argument &arg, f.arguments) {
+ QString a = QString(QStringLiteral("%1%2 %3%4"))
+ .arg((arg.direction == Argument::In && arg.mode != Argument::Value) ? QStringLiteral("const ") : QString())
+ .arg(arg.type)
+ .arg(passByType(arg))
+ .arg(safeArgumentName(arg.name));
+ argList.append(a);
+ }
+ QString args = argList.join(", ");
+
+
+ QString signature = QString(QStringLiteral("inline %1 %2::gl%3(%4)"))
+ .arg(f.returnType)
+ .arg(className)
+ .arg(f.name)
+ .arg(args);
+ stream << signature << endl << QStringLiteral("{") << endl;
+
+ stream << QString(QStringLiteral(" Q_D(%1);")).arg(className) << endl;
+
+ QStringList argumentNames;
+ Q_FOREACH (const Argument &arg, f.arguments)
+ argumentNames.append(safeArgumentName(arg.name));
+ QString argNames = argumentNames.join(", ");
+
+ if (f.returnType == QStringLiteral("void"))
+ stream << QString(QStringLiteral(" d->%1(%2);")).arg(f.name).arg(argNames) << endl;
+ else
+ stream << QString(QStringLiteral(" return d->%1(%2);")).arg(f.name).arg(argNames) << endl;
+ stream << QStringLiteral("}") << endl << endl;
+}
+
+void CodeGenerator::writeExtensionClassImplementation(QTextStream &stream, const QString &extension) const
+{
+ const QString className = generateExtensionClassName(extension);
+ const QString privateClassName = generateExtensionClassName(extension, Private);
+
+ // Output default constructor
+ stream << className << QStringLiteral("::") << className << QStringLiteral("()") << endl;
+ stream << QStringLiteral(" : QAbstractOpenGLExtension(*(new ") << privateClassName << QStringLiteral("))") << endl;
+ stream << QStringLiteral("{") << endl << QStringLiteral("}") << endl << endl;
+
+
+ // Output function to initialize this class
+ stream << QStringLiteral("bool ") << className
+ << QStringLiteral("::initializeOpenGLFunctions()") << endl
+ << QStringLiteral("{") << endl;
+
+ stream << QStringLiteral(" if (isInitialized())") << endl;
+ stream << QStringLiteral(" return true;") << endl << endl;
+
+ stream << QStringLiteral(" QOpenGLContext *context = QOpenGLContext::currentContext();") << endl;
+ stream << QStringLiteral(" if (!context) {") << endl;
+ stream << QStringLiteral(" qWarning(\"A current OpenGL context is required to resolve OpenGL extension functions\");")
+ << endl;
+ stream << QStringLiteral(" return false;") << endl;
+ stream << QStringLiteral(" }") << endl << endl;
+
+ // Output code to resolve entry points for this class
+ stream << QStringLiteral(" // Resolve the functions") << endl;
+ stream << QStringLiteral(" Q_D(") << className << QStringLiteral(");") << endl;
+ stream << endl;
+
+ // Output function declarations
+ QList<Function> functions = m_parser->functionsForExtension(extension);
+ Q_FOREACH (const Function &f, functions)
+ writeEntryPointResolutionStatement(stream, f, QStringLiteral("d->"));
+
+ // Call the base class implementation
+ stream << QStringLiteral(" QAbstractOpenGLExtension::initializeOpenGLFunctions();") << endl;
+
+ // Finish off
+ stream << QStringLiteral(" return true;") << endl;
+ stream << QStringLiteral("}") << endl << endl;
+}
+
+QString CodeGenerator::generateExtensionClassName(const QString &extension, ClassVisibility visibility) const
+{
+ QString visibilitySuffix;
+ if (visibility == Private)
+ visibilitySuffix = QStringLiteral("Private");
+
+ return QString(QStringLiteral("QOpenGLExtension_%1%2"))
+ .arg(extension)
+ .arg(visibilitySuffix);
+}
diff --git a/util/glgen/codegenerator.h b/util/glgen/codegenerator.h
new file mode 100644
index 0000000000..7ad4d49e8d
--- /dev/null
+++ b/util/glgen/codegenerator.h
@@ -0,0 +1,149 @@
+/***************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the utilities of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef CODEGENERATOR_H
+#define CODEGENERATOR_H
+
+#include "specparser.h"
+
+class QTextStream;
+
+class CodeGenerator
+{
+public:
+ explicit CodeGenerator();
+
+ void setParser(SpecParser *parser) {m_parser = parser;}
+
+ void generateCoreClasses(const QString &baseFileName) const;
+
+ void generateExtensionClasses(const QString &baseFileName) const;
+
+private:
+ // Generic support
+ enum ClassVisibility {
+ Public,
+ Private
+ };
+
+ enum ClassComponent {
+ Declaration = 0,
+ Definition
+ };
+
+ bool isLegacyVersion(Version v) const;
+ bool versionHasProfiles(Version v) const;
+
+ FunctionCollection functionCollection( const VersionProfile& classVersionProfile ) const;
+
+ void writePreamble(const QString &baseFileName, QTextStream &stream, const QString replacement = QString()) const;
+ void writePostamble(const QString &baseFileName, QTextStream &stream) const;
+
+ QString passByType(const Argument &arg) const;
+ QString safeArgumentName(const QString& arg) const;
+
+ // Core functionality support
+ QString coreClassFileName(const VersionProfile &versionProfile,
+ const QString& fileExtension) const;
+ void writeCoreHelperClasses(const QString &fileName, ClassComponent component) const;
+ void writeCoreClasses(const QString &baseFileName) const;
+
+ void writeCoreFactoryHeader(const QString &fileName) const;
+ void writeCoreFactoryImplementation(const QString &fileName) const;
+
+ QString generateClassName(const VersionProfile &classVersion, ClassVisibility visibility = Public) const;
+
+ void writeBackendClassDeclaration(QTextStream &stream,
+ const VersionProfile &versionProfile,
+ const QString &baseClass) const;
+ void writeBackendClassImplementation(QTextStream &stream,
+ const VersionProfile &versionProfile,
+ const QString &baseClass) const;
+
+ void writePublicClassDeclaration(const QString &baseFileName,
+ const VersionProfile &versionProfile,
+ const QString &baseClass) const;
+ void writePublicClassImplementation(const QString &baseFileName,
+ const VersionProfile &versionProfile,
+ const QString& baseClass) const;
+
+ void writeClassFunctionDeclarations(QTextStream &stream,
+ const FunctionCollection &functionSets,
+ ClassVisibility visibility) const;
+
+ void writeFunctionDeclaration(QTextStream &stream, const Function &f, ClassVisibility visibility) const;
+
+ void writeClassInlineFunctions(QTextStream &stream,
+ const QString &className,
+ const FunctionCollection &functionSet) const;
+
+ void writeInlineFunction(QTextStream &stream, const QString &className,
+ const QString &backendVar, const Function &f) const;
+
+ void writeEntryPointResolutionCode(QTextStream &stream,
+ const FunctionCollection &functionSet) const;
+
+ void writeEntryPointResolutionStatement(QTextStream &stream, const Function &f,
+ const QString &prefix = QString(), bool useGetProcAddress = false) const;
+
+ QList<VersionProfile> backendsForFunctionCollection(const FunctionCollection &functionSet) const;
+ QString backendClassName(const VersionProfile &v) const;
+ QString backendVariableName(const VersionProfile &v) const;
+ void writeBackendVariableDeclarations(QTextStream &stream, const QList<VersionProfile> &backends) const;
+
+
+ // Extension class support
+ void writeExtensionHeader(const QString &fileName) const;
+ void writeExtensionImplementation(const QString &fileName) const;
+
+ void writeExtensionClassDeclaration(QTextStream &stream,
+ const QString &extension,
+ ClassVisibility visibility = Public) const;
+ void writeExtensionClassImplementation(QTextStream &stream, const QString &extension) const;
+
+ QString generateExtensionClassName(const QString &extension, ClassVisibility visibility = Public) const;
+ void writeExtensionInlineFunction(QTextStream &stream, const QString &className, const Function &f) const;
+
+ SpecParser *m_parser;
+ mutable QMap<QString, int> m_extensionIds;
+};
+
+#endif // CODEGENERATOR_H
diff --git a/util/glgen/glgen.pro b/util/glgen/glgen.pro
new file mode 100644
index 0000000000..9208ba9e8e
--- /dev/null
+++ b/util/glgen/glgen.pro
@@ -0,0 +1,35 @@
+QT -= gui
+CONFIG += console
+CONFIG -= app_bundle
+
+# Uncomment following to enable debug output
+#DEFINES += SPECPARSER_DEBUG
+
+TEMPLATE = app
+TARGET = glgen
+
+SOURCES += main.cpp \
+ specparser.cpp \
+ codegenerator.cpp
+
+HEADERS += \
+ specparser.h \
+ codegenerator.h
+
+OTHER_FILES += \
+ qopenglversionfunctions.h.header \
+ qopenglversionfunctions.h.footer \
+ qopenglversionfunctions.cpp.header \
+ qopenglversionfunctions.cpp.footer \
+ qopenglversionfunctions__VERSION__.cpp.footer \
+ qopenglversionfunctions__VERSION__.cpp.header \
+ qopenglversionfunctions__VERSION__.h.footer \
+ qopenglversionfunctions__VERSION__.h.header \
+ qopenglversionfunctionsfactory_p.h.header \
+ qopenglextensions.cpp.header \
+ qopenglextensions.cpp.footer \
+ qopenglextensions.h.header \
+ qopenglextensions.h.footer \
+ qopenglversionfunctionsfactory.cpp.header \
+ qopenglversionfunctionsfactory.cpp.footer \
+ README.txt
diff --git a/util/glgen/main.cpp b/util/glgen/main.cpp
new file mode 100644
index 0000000000..15c311caf3
--- /dev/null
+++ b/util/glgen/main.cpp
@@ -0,0 +1,61 @@
+/***************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the utilities of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "codegenerator.h"
+#include "specparser.h"
+
+int main(int argc, char *argv[])
+{
+ Q_UNUSED(argc);
+ Q_UNUSED(argv);
+
+ SpecParser parser;
+ parser.setTypeMapFileName(QStringLiteral("gl.tm"));
+ parser.setSpecFileName(QStringLiteral("gl.spec"));
+ parser.parse();
+
+ CodeGenerator generator;
+ generator.setParser(&parser);
+ generator.generateCoreClasses(QStringLiteral("qopenglversionfunctions"));
+ generator.generateExtensionClasses(QStringLiteral("qopenglextensions"));
+
+ return 0;
+}
diff --git a/util/glgen/qopenglextensions.cpp.footer b/util/glgen/qopenglextensions.cpp.footer
new file mode 100644
index 0000000000..d7bd157743
--- /dev/null
+++ b/util/glgen/qopenglextensions.cpp.footer
@@ -0,0 +1,792 @@
+
+#else
+
+QOpenGLExtension_OES_EGL_image::QOpenGLExtension_OES_EGL_image()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_OES_EGL_imagePrivate))
+{
+}
+
+bool QOpenGLExtension_OES_EGL_image::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_OES_EGL_image);
+
+ d->EGLImageTargetTexture2DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLeglImageOES image))context->getProcAddress("glEGLImageTargetTexture2DOES");
+ d->EGLImageTargetRenderbufferStorageOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLeglImageOES image))context->getProcAddress("glEGLImageTargetRenderbufferStorageOESs");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_OES_get_program_binary::QOpenGLExtension_OES_get_program_binary()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_OES_get_program_binaryPrivate))
+{
+}
+
+bool QOpenGLExtension_OES_get_program_binary::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_OES_get_program_binary);
+
+ d->GetProgramBinaryOES = (void (QOPENGLF_APIENTRYP)(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary))context->getProcAddress("glGetProgramBinaryOES");
+ d->ProgramBinaryOES = (void (QOPENGLF_APIENTRYP)(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLint length))context->getProcAddress("glProgramBinaryOES");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_OES_mapbuffer::QOpenGLExtension_OES_mapbuffer()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_OES_mapbufferPrivate))
+{
+}
+
+bool QOpenGLExtension_OES_mapbuffer::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_OES_mapbuffer);
+
+ d->MapBufferOES = (void* (QOPENGLF_APIENTRYP)(GLenum target, GLenum access))context->getProcAddress("glMapBufferOES");
+ d->UnmapBufferOES = (GLboolean (QOPENGLF_APIENTRYP)(GLenum target))context->getProcAddress("glUnmapBufferOES");
+ d->GetBufferPointervOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLenum pname, GLvoid** params))context->getProcAddress("glGetBufferPointervOES");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_OES_texture_3D::QOpenGLExtension_OES_texture_3D()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_OES_texture_3DPrivate))
+{
+}
+
+bool QOpenGLExtension_OES_texture_3D::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_OES_texture_3D);
+
+ d->TexImage3DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid* pixels))context->getProcAddress("glTexImage3DOES");
+ d->TexSubImage3DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid* pixels))context->getProcAddress("glTexSubImage3DOES");
+ d->CopyTexSubImage3DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height))context->getProcAddress("glCopyTexSubImage3DOES");
+ d->CompressedTexImage3DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data))context->getProcAddress("glCompressedTexImage3DOES");
+ d->CompressedTexSubImage3DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data))context->getProcAddress("glCompressedTexSubImage3DOES");
+ d->FramebufferTexture3DOES = (void (QOPENGLF_APIENTRYP)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset))context->getProcAddress("glFramebufferTexture3DOES");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_OES_vertex_array_object::QOpenGLExtension_OES_vertex_array_object()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_OES_vertex_array_objectPrivate))
+{
+}
+
+bool QOpenGLExtension_OES_vertex_array_object::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_OES_vertex_array_object);
+
+ d->BindVertexArrayOES = (void (QOPENGLF_APIENTRYP)(GLuint array))context->getProcAddress("glBindVertexArrayOES");
+ d->DeleteVertexArraysOES = (void (QOPENGLF_APIENTRYP)(GLsizei n, const GLuint *arrays))context->getProcAddress("glDeleteVertexArraysOES");
+ d->GenVertexArraysOES = (void (QOPENGLF_APIENTRYP)(GLsizei n, GLuint *arrays))context->getProcAddress("glGenVertexArraysOES");
+ d->IsVertexArrayOES = (GLboolean (QOPENGLF_APIENTRYP)(GLuint array))context->getProcAddress("glIsVertexArrayOES");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_AMD_performance_monitor::QOpenGLExtension_AMD_performance_monitor()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_AMD_performance_monitorPrivate))
+{
+}
+
+bool QOpenGLExtension_AMD_performance_monitor::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+
+ d->GetPerfMonitorGroupsAMD = (void (QOPENGLF_APIENTRYP)(GLint *numGroups, GLsizei groupsSize, GLuint *groups))context->getProcAddress("glGetPerfMonitorGroupsAMD");
+ d->GetPerfMonitorCountersAMD = (void (QOPENGLF_APIENTRYP)(GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters))context->getProcAddress("glGetPerfMonitorCountersAMD");
+ d->GetPerfMonitorGroupStringAMD = (void (QOPENGLF_APIENTRYP)(GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString))context->getProcAddress("glGetPerfMonitorGroupStringAMD");
+ d->GetPerfMonitorCounterStringAMD = (void (QOPENGLF_APIENTRYP)(GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString))context->getProcAddress("glGetPerfMonitorCounterStringAMD");
+ d->GetPerfMonitorCounterInfoAMD = (void (QOPENGLF_APIENTRYP)(GLuint group, GLuint counter, GLenum pname, GLvoid *data))context->getProcAddress("glGetPerfMonitorCounterInfoAMD");
+ d->GenPerfMonitorsAMD = (void (QOPENGLF_APIENTRYP)(GLsizei n, GLuint *monitors))context->getProcAddress("glGenPerfMonitorsAMD");
+ d->DeletePerfMonitorsAMD = (void (QOPENGLF_APIENTRYP)(GLsizei n, GLuint *monitors))context->getProcAddress("glDeletePerfMonitorsAMD");
+ d->SelectPerfMonitorCountersAMD = (void (QOPENGLF_APIENTRYP)(GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *countersList))context->getProcAddress("glSelectPerfMonitorCountersAMD");
+ d->BeginPerfMonitorAMD = (void (QOPENGLF_APIENTRYP)(GLuint monitor))context->getProcAddress("glBeginPerfMonitorAMD");
+ d->EndPerfMonitorAMD = (void (QOPENGLF_APIENTRYP )(GLuint monitor))context->getProcAddress("glEndPerfMonitorAMD");
+ d->GetPerfMonitorCounterDataAMD = (void (QOPENGLF_APIENTRYP)(GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten))context->getProcAddress("glGetPerfMonitorCounterDataAMD");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_ANGLE_framebuffer_blit::QOpenGLExtension_ANGLE_framebuffer_blit()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ANGLE_framebuffer_blitPrivate))
+{
+}
+
+bool QOpenGLExtension_ANGLE_framebuffer_blit::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ANGLE_framebuffer_blit);
+
+ d->BlitFramebufferANGLE = (void (QOPENGLF_APIENTRYP)(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter))context->getProcAddress("glBlitFramebufferANGLE");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_ANGLE_framebuffer_multisample::QOpenGLExtension_ANGLE_framebuffer_multisample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ANGLE_framebuffer_multisamplePrivate))
+{
+}
+
+bool QOpenGLExtension_ANGLE_framebuffer_multisample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ANGLE_framebuffer_multisample);
+
+ d->RenderbufferStorageMultisampleANGLE = (void (QOPENGLF_APIENTRYP)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height))context->getProcAddress("glRenderbufferStorageMultisampleANGLE");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_ANGLE_instanced_arrays::QOpenGLExtension_ANGLE_instanced_arrays()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ANGLE_instanced_arraysPrivate))
+{
+}
+
+bool QOpenGLExtension_ANGLE_instanced_arrays::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ANGLE_instanced_arrays);
+
+ d->DrawArraysInstancedANGLE = (void (QOPENGLF_APIENTRYP)(GLenum mode, GLint first, GLsizei count, GLsizei primcount))context->getProcAddress("glDrawArraysInstancedANGLE");
+ d->DrawElementsInstancedANGLE = (void (QOPENGLF_APIENTRYP)(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount))context->getProcAddress("glDrawElementsInstancedANGLE");
+ d->VertexAttribDivisorANGLE = (void (QOPENGLF_APIENTRYP)(GLuint index, GLuint divisor))context->getProcAddress("glVertexAttribDivisorANGLE");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_ANGLE_translated_shader_source::QOpenGLExtension_ANGLE_translated_shader_source()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_ANGLE_translated_shader_sourcePrivate))
+{
+}
+
+bool QOpenGLExtension_ANGLE_translated_shader_source::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_ANGLE_translated_shader_source);
+
+ d->GetTranslatedShaderSourceANGLE = (void (QOPENGLF_APIENTRYP)(GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source))context->getProcAddress("glGetTranslatedShaderSourceANGLE");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_APPLE_framebuffer_multisample::QOpenGLExtension_APPLE_framebuffer_multisample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_APPLE_framebuffer_multisamplePrivate))
+{
+}
+
+bool QOpenGLExtension_APPLE_framebuffer_multisample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_APPLE_framebuffer_multisample);
+
+ d->RenderbufferStorageMultisampleAPPLE = (void (QOPENGLF_APIENTRYP)(GLenum, GLsizei, GLenum, GLsizei, GLsizei))context->getProcAddress("glRenderbufferStorageMultisampleAPPLE");
+ d->ResolveMultisampleFramebufferAPPLE = (void (QOPENGLF_APIENTRYP)(void))context->getProcAddress("glResolveMultisampleFramebufferAPPLE");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_debug_label::QOpenGLExtension_EXT_debug_label()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_debug_labelPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_debug_label::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_debug_label);
+
+ d->LabelObjectEXT = (void (QOPENGLF_APIENTRYP)(GLenum type, GLuint object, GLsizei length, const GLchar *label))context->getProcAddress("glLabelObjectEXT");
+ d->GetObjectLabelEXT = (void (QOPENGLF_APIENTRYP)(GLenum type, GLuint object, GLsizei bufSize, GLsizei *length, GLchar *label))context->getProcAddress("glGetObjectLabelEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_debug_marker::QOpenGLExtension_EXT_debug_marker()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_debug_markerPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_debug_marker::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_debug_marker);
+
+ d->InsertEventMarkerEXT = (void (QOPENGLF_APIENTRYP)(GLsizei length, const GLchar *marker))context->getProcAddress("glInsertEventMarkerEXT");
+ d->PushGroupMarkerEXT = (void (QOPENGLF_APIENTRYP)(GLsizei length, const GLchar *marker))context->getProcAddress("glPushGroupMarkerEXT");
+ d->PopGroupMarkerEXT = (void (QOPENGLF_APIENTRYP)(void))context->getProcAddress("glPopGroupMarkerEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_discard_framebuffer::QOpenGLExtension_EXT_discard_framebuffer()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_discard_framebufferPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_discard_framebuffer::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_discard_framebuffer);
+
+ d->DiscardFramebufferEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLsizei numAttachments, const GLenum *attachments))context->getProcAddress("glDiscardFramebufferEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_multisampled_render_to_texture::QOpenGLExtension_EXT_multisampled_render_to_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_multisampled_render_to_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_multisampled_render_to_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_multisampled_render_to_texture);
+
+ d->RenderbufferStorageMultisampleEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height))context->getProcAddress("glRenderbufferStorageMultisampleEXT");
+ d->FramebufferTexture2DMultisampleEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples))context->getProcAddress("glFramebufferTexture2DMultisampleEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_multi_draw_arrays::QOpenGLExtension_EXT_multi_draw_arrays()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_multi_draw_arraysPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_multi_draw_arrays::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_multi_draw_arrays);
+
+ d->MultiDrawArraysEXT = (void (QOPENGLF_APIENTRYP)(GLenum mode, GLint *first, GLsizei *count, GLsizei primcount))context->getProcAddress("glMultiDrawArraysEXT");
+ d->MultiDrawElementsEXT = (void (QOPENGLF_APIENTRYP)(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount))context->getProcAddress("glMultiDrawElementsEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_occlusion_query_boolean::QOpenGLExtension_EXT_occlusion_query_boolean()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_occlusion_query_booleanPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_occlusion_query_boolean::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+
+ d->GenQueriesEXT = (void (QOPENGLF_APIENTRYP)(GLsizei n, GLuint *ids))context->getProcAddress("glGenQueriesEXT");
+ d->DeleteQueriesEXT = (void (QOPENGLF_APIENTRYP)(GLsizei n, const GLuint *ids))context->getProcAddress("glDeleteQueriesEXT");
+ d->IsQueryEXT = (GLboolean (QOPENGLF_APIENTRYP)(GLuint id))context->getProcAddress("glIsQueryEXT");
+ d->BeginQueryEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLuint id))context->getProcAddress("glBeginQueryEXT");
+ d->EndQueryEXT = (void (QOPENGLF_APIENTRYP)(GLenum target))context->getProcAddress("glEndQueryEXT");
+ d->GetQueryivEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLenum pname, GLint *params))context->getProcAddress("glGetQueryivEXT");
+ d->GetQueryObjectuivEXT = (void (QOPENGLF_APIENTRYP)(GLuint id, GLenum pname, GLuint *params))context->getProcAddress("glGetQueryObjectuivEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_robustness::QOpenGLExtension_EXT_robustness()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_robustnessPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_robustness::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_robustness);
+
+ d->GetGraphicsResetStatusEXT = (GLenum (QOPENGLF_APIENTRYP)(void))context->getProcAddress("glGetGraphicsResetStatusEXT");
+ d->ReadnPixelsEXT = (void (QOPENGLF_APIENTRYP)(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data))context->getProcAddress("glReadnPixelsEXT");
+ d->GetnUniformfvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei bufSize, float *params))context->getProcAddress("glGetnUniformfvEXT");
+ d->GetnUniformivEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei bufSize, GLint *params))context->getProcAddress("glGetnUniformivEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_separate_shader_objects::QOpenGLExtension_EXT_separate_shader_objects()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_separate_shader_objectsPrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_separate_shader_objects::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+
+ d->UseProgramStagesEXT = (void (QOPENGLF_APIENTRYP)(GLuint pipeline, GLbitfield stages, GLuint program))context->getProcAddress("glUseProgramStagesEXT");
+ d->ActiveShaderProgramEXT = (void (QOPENGLF_APIENTRYP)(GLuint pipeline, GLuint program))context->getProcAddress("glActiveShaderProgramEXT");
+ d->CreateShaderProgramvEXT = (GLuint (QOPENGLF_APIENTRYP)(GLenum type, GLsizei count, const GLchar **strings))context->getProcAddress("glCreateShaderProgramvEXT");
+ d->BindProgramPipelineEXT = (void (QOPENGLF_APIENTRYP)(GLuint pipeline))context->getProcAddress("glBindProgramPipelineEXT");
+ d->DeleteProgramPipelinesEXT = (void (QOPENGLF_APIENTRYP)(GLsizei n, const GLuint *pipelines))context->getProcAddress("glDeleteProgramPipelinesEXT");
+ d->GenProgramPipelinesEXT = (void (QOPENGLF_APIENTRYP)(GLsizei n, GLuint *pipelines))context->getProcAddress("glGenProgramPipelinesEXT");
+ d->IsProgramPipelineEXT = (GLboolean (QOPENGLF_APIENTRYP)(GLuint pipeline))context->getProcAddress("glIsProgramPipelineEXT");
+ d->ProgramParameteriEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLenum pname, GLint value))context->getProcAddress("glProgramParameteriEXT");
+ d->GetProgramPipelineivEXT = (void (QOPENGLF_APIENTRYP)(GLuint pipeline, GLenum pname, GLint *params))context->getProcAddress("glGetProgramPipelineivEXT");
+ d->ProgramUniform1iEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLint x))context->getProcAddress("glProgramUniform1iEXT");
+ d->ProgramUniform2iEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLint x, GLint y))context->getProcAddress("glProgramUniform2iEXT");
+ d->ProgramUniform3iEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLint x, GLint y, GLint z))context->getProcAddress("glProgramUniform3iEXT");
+ d->ProgramUniform4iEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLint x, GLint y, GLint z, GLint w))context->getProcAddress("glProgramUniform4iEXT");
+ d->ProgramUniform1fEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLfloat x))context->getProcAddress("glProgramUniform1fEXT");
+ d->ProgramUniform2fEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLfloat x, GLfloat y))context->getProcAddress("glProgramUniform2fEXT");
+ d->ProgramUniform3fEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z))context->getProcAddress("glProgramUniform3fEXT");
+ d->ProgramUniform4fEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w))context->getProcAddress("glProgramUniform4fEXT");
+ d->ProgramUniform1ivEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLint *value))context->getProcAddress("glProgramUniform1ivEXT");
+ d->ProgramUniform2ivEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLint *value))context->getProcAddress("glProgramUniform2ivEXT");
+ d->ProgramUniform3ivEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLint *value))context->getProcAddress("glProgramUniform3ivEXT");
+ d->ProgramUniform4ivEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLint *value))context->getProcAddress("glProgramUniform4ivEXT");
+ d->ProgramUniform1fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLfloat *value))context->getProcAddress("glProgramUniform1fvEXT");
+ d->ProgramUniform2fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLfloat *value))context->getProcAddress("glProgramUniform2fvEXT");
+ d->ProgramUniform3fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLfloat *value))context->getProcAddress("glProgramUniform3fvEXT");
+ d->ProgramUniform4fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, const GLfloat *value))context->getProcAddress("glProgramUniform4fvEXT");
+ d->ProgramUniformMatrix2fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value))context->getProcAddress("glProgramUniformMatrix2fvEXT");
+ d->ProgramUniformMatrix3fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value))context->getProcAddress("glProgramUniformMatrix3fvEXT");
+ d->ProgramUniformMatrix4fvEXT = (void (QOPENGLF_APIENTRYP)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value))context->getProcAddress("glProgramUniformMatrix4fvEXT");
+ d->ValidateProgramPipelineEXT = (void (QOPENGLF_APIENTRYP)(GLuint pipeline))context->getProcAddress("glValidateProgramPipelineEXT");
+ d->GetProgramPipelineInfoLogEXT = (void (QOPENGLF_APIENTRYP)(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog))context->getProcAddress("glGetProgramPipelineInfoLogEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_EXT_texture_storage::QOpenGLExtension_EXT_texture_storage()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_EXT_texture_storagePrivate))
+{
+}
+
+bool QOpenGLExtension_EXT_texture_storage::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+
+ d->TexStorage1DEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width))context->getProcAddress("glTexStorage1DEXT");
+ d->TexStorage2DEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height))context->getProcAddress("glTexStorage2DEXT");
+ d->TexStorage3DEXT = (void (QOPENGLF_APIENTRYP)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth))context->getProcAddress("glTexStorage3DEXT");
+ d->TextureStorage1DEXT = (void (QOPENGLF_APIENTRYP)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width))context->getProcAddress("glTextureStorage1DEXT");
+ d->TextureStorage2DEXT = (void (QOPENGLF_APIENTRYP)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height))context->getProcAddress("glTextureStorage2DEXT");
+ d->TextureStorage3DEXT = (void (QOPENGLF_APIENTRYP)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth))context->getProcAddress("glTextureStorage3DEXT");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_IMG_multisampled_render_to_texture::QOpenGLExtension_IMG_multisampled_render_to_texture()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_IMG_multisampled_render_to_texturePrivate))
+{
+}
+
+bool QOpenGLExtension_IMG_multisampled_render_to_texture::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_IMG_multisampled_render_to_texture);
+
+ d->RenderbufferStorageMultisampleIMG = (void (QOPENGLF_APIENTRYP)(GLenum, GLsizei, GLenum, GLsizei, GLsizei))context->getProcAddress("glRenderbufferStorageMultisampleIMG");
+ d->FramebufferTexture2DMultisampleIMG = (void (QOPENGLF_APIENTRYP)(GLenum, GLenum, GLenum, GLuint, GLint, GLsizei))context->getProcAddress("glFramebufferTexture2DMultisampleIMG");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_NV_coverage_sample::QOpenGLExtension_NV_coverage_sample()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_coverage_samplePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_coverage_sample::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_coverage_sample);
+
+ d->CoverageMaskNV = (void (QOPENGLF_APIENTRYP)(GLboolean mask))context->getProcAddress("glCoverageMaskNV");
+ d->CoverageOperationNV = (void (QOPENGLF_APIENTRYP)(GLenum operation))context->getProcAddress("glCoverageOperationNV");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_NV_draw_buffers::QOpenGLExtension_NV_draw_buffers()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_draw_buffersPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_draw_buffers::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_draw_buffers);
+
+ d->DrawBuffersNV = (void (QOPENGLF_APIENTRYP)(GLsizei n, const GLenum *bufs))context->getProcAddress("glDrawBuffersNV");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_NV_fence::QOpenGLExtension_NV_fence()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_fencePrivate))
+{
+}
+
+bool QOpenGLExtension_NV_fence::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_fence);
+
+ d->DeleteFencesNV = (void (QOPENGLF_APIENTRYP)(GLsizei n, const GLuint *fences))context->getProcAddress("glDeleteFencesNV");
+ d->GenFencesNV = (void (QOPENGLF_APIENTRYP)(GLsizei n, GLuint *fences))context->getProcAddress("glGenFencesNV");
+ d->IsFenceNV = (GLboolean (QOPENGLF_APIENTRYP)(GLuint fence))context->getProcAddress("glIsFenceNV");
+ d->TestFenceNV = (GLboolean (QOPENGLF_APIENTRYP)(GLuint fence))context->getProcAddress("glTestFenceNV");
+ d->GetFenceivNV = (void (QOPENGLF_APIENTRYP)(GLuint fence, GLenum pname, GLint *params))context->getProcAddress("glGetFenceivNV");
+ d->FinishFenceNV = (void (QOPENGLF_APIENTRYP)(GLuint fence))context->getProcAddress("glFinishFenceNV");
+ d->SetFenceNV = (void (QOPENGLF_APIENTRYP)(GLuint fence, GLenum condition))context->getProcAddress("glSetFenceNV");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_NV_read_buffer::QOpenGLExtension_NV_read_buffer()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_NV_read_bufferPrivate))
+{
+}
+
+bool QOpenGLExtension_NV_read_buffer::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_NV_read_buffer);
+
+ d->ReadBufferNV = (void (QOPENGLF_APIENTRYP)(GLenum mode))context->getProcAddress("glReadBufferNV");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_QCOM_alpha_test::QOpenGLExtension_QCOM_alpha_test()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_QCOM_alpha_testPrivate))
+{
+}
+
+bool QOpenGLExtension_QCOM_alpha_test::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_QCOM_alpha_test);
+
+ d->AlphaFuncQCOM = (void (QOPENGLF_APIENTRYP )(GLenum func, GLclampf ref))context->getProcAddress("glAlphaFuncQCOM");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_QCOM_driver_control::QOpenGLExtension_QCOM_driver_control()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_QCOM_driver_controlPrivate))
+{
+}
+
+bool QOpenGLExtension_QCOM_driver_control::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_QCOM_driver_control);
+
+ d->GetDriverControlsQCOM = (void (QOPENGLF_APIENTRYP)(GLint *num, GLsizei size, GLuint *driverControls))context->getProcAddress("glGetDriverControlsQCOM");
+ d->GetDriverControlStringQCOM = (void (QOPENGLF_APIENTRYP)(GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString))context->getProcAddress("glGetDriverControlStringQCOM");
+ d->EnableDriverControlQCOM = (void (QOPENGLF_APIENTRYP)(GLuint driverControl))context->getProcAddress("glEnableDriverControlQCOM");
+ d->DisableDriverControlQCOM = (void (QOPENGLF_APIENTRYP)(GLuint driverControl))context->getProcAddress("glDisableDriverControlQCOM");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_QCOM_extended_get::QOpenGLExtension_QCOM_extended_get()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_QCOM_extended_getPrivate))
+{
+}
+
+bool QOpenGLExtension_QCOM_extended_get::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+
+ d->ExtGetTexturesQCOM = (void (QOPENGLF_APIENTRYP)(GLuint *textures, GLint maxTextures, GLint *numTextures))context->getProcAddress("glExtGetTexturesQCOM");
+ d->ExtGetBuffersQCOM = (void (QOPENGLF_APIENTRYP)(GLuint *buffers, GLint maxBuffers, GLint *numBuffers))context->getProcAddress("glExtGetBuffersQCOM");
+ d->ExtGetRenderbuffersQCOM = (void (QOPENGLF_APIENTRYP)(GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers))context->getProcAddress("glExtGetRenderbuffersQCOM");
+ d->ExtGetFramebuffersQCOM = (void (QOPENGLF_APIENTRYP)(GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers))context->getProcAddress("glExtGetFramebuffersQCOM");
+ d->ExtGetTexLevelParameterivQCOM = (void (QOPENGLF_APIENTRYP)(GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params))context->getProcAddress("glExtGetTexLevelParameterivQCOM");
+ d->ExtTexObjectStateOverrideiQCOM = (void (QOPENGLF_APIENTRYP)(GLenum target, GLenum pname, GLint param))context->getProcAddress("glExtTexObjectStateOverrideiQCOM");
+ d->ExtGetTexSubImageQCOM = (void (QOPENGLF_APIENTRYP)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLvoid *texels))context->getProcAddress("glExtGetTexSubImageQCOM");
+ d->ExtGetBufferPointervQCOM = (void (QOPENGLF_APIENTRYP)(GLenum target, GLvoid **params))context->getProcAddress("glExtGetBufferPointervQCOM");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_QCOM_extended_get2::QOpenGLExtension_QCOM_extended_get2()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_QCOM_extended_get2Private))
+{
+}
+
+bool QOpenGLExtension_QCOM_extended_get2::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_QCOM_extended_get2);
+
+ d->ExtGetShadersQCOM = (void (QOPENGLF_APIENTRYP)(GLuint *shaders, GLint maxShaders, GLint *numShaders))context->getProcAddress("glExtGetShadersQCOM");
+ d->ExtGetProgramsQCOM = (void (QOPENGLF_APIENTRYP)(GLuint *programs, GLint maxPrograms, GLint *numPrograms))context->getProcAddress("glExtGetProgramsQCOM");
+ d->ExtIsProgramBinaryQCOM = (GLboolean (QOPENGLF_APIENTRYP)(GLuint program))context->getProcAddress("glExtIsProgramBinaryQCOM");
+ d->ExtGetProgramBinarySourceQCOM = (void (QOPENGLF_APIENTRYP)(GLuint program, GLenum shadertype, GLchar *source, GLint *length))context->getProcAddress("glExtGetProgramBinarySourceQCOM");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+QOpenGLExtension_QCOM_tiled_rendering::QOpenGLExtension_QCOM_tiled_rendering()
+ : QAbstractOpenGLExtension(*(new QOpenGLExtension_QCOM_tiled_renderingPrivate))
+{
+}
+
+bool QOpenGLExtension_QCOM_tiled_rendering::initializeOpenGLFunctions()
+{
+ if (isInitialized())
+ return true;
+
+ QOpenGLContext *context = QOpenGLContext::currentContext();
+ if (!context) {
+ qWarning("A current OpenGL context is required to resolve OpenGL extension functions");
+ return false;
+ }
+
+ // Resolve the functions
+ Q_D(QOpenGLExtension_QCOM_tiled_rendering);
+
+ d->StartTilingQCOM = (void (QOPENGLF_APIENTRYP)(GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask))context->getProcAddress("glStartTilingQCOM");
+ d->EndTilingQCOM = (void (QOPENGLF_APIENTRYP)(GLbitfield preserveMask))context->getProcAddress("glEndTilingQCOM");
+ return QAbstractOpenGLExtension::initializeOpenGLFunctions();
+}
+
+#endif
+
+QT_END_NAMESPACE
+
diff --git a/util/glgen/qopenglextensions.cpp.header b/util/glgen/qopenglextensions.cpp.header
new file mode 100644
index 0000000000..6a9f639d5d
--- /dev/null
+++ b/util/glgen/qopenglextensions.cpp.header
@@ -0,0 +1,76 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglextensions.h"
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+QAbstractOpenGLExtension::~QAbstractOpenGLExtension()
+{
+ if (d_ptr)
+ delete d_ptr;
+}
+
+bool QAbstractOpenGLExtension::initializeOpenGLFunctions()
+{
+ Q_D(QAbstractOpenGLExtension);
+ d->initialized = true;
+ return true;
+}
+
+bool QAbstractOpenGLExtension::isInitialized() const
+{
+ Q_D(const QAbstractOpenGLExtension);
+ return d->initialized;
+}
+
+#if !defined(QT_OPENGL_ES_2)
+
diff --git a/util/glgen/qopenglextensions.h.footer b/util/glgen/qopenglextensions.h.footer
new file mode 100644
index 0000000000..465b241c33
--- /dev/null
+++ b/util/glgen/qopenglextensions.h.footer
@@ -0,0 +1,1520 @@
+
+#else
+
+class QOpenGLExtension_OES_EGL_imagePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP EGLImageTargetTexture2DOES)(GLenum target, GLeglImageOES image);
+ void (QOPENGLF_APIENTRYP EGLImageTargetRenderbufferStorageOES)(GLenum target, GLeglImageOES image);
+};
+
+class QOpenGLExtension_OES_EGL_image : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_OES_EGL_image();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glEGLImageTargetTexture2DOES(GLenum target, GLeglImageOES image);
+ void glEGLImageTargetRenderbufferStorageOES(GLenum target, GLeglImageOES image);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_OES_EGL_image)
+};
+
+inline void QOpenGLExtension_OES_EGL_image::glEGLImageTargetTexture2DOES(GLenum target, GLeglImageOES image)
+{
+ Q_D(QOpenGLExtension_OES_EGL_image);
+ d->EGLImageTargetTexture2DOES(target, image);
+}
+
+inline void QOpenGLExtension_OES_EGL_image::glEGLImageTargetRenderbufferStorageOES(GLenum target, GLeglImageOES image)
+{
+ Q_D(QOpenGLExtension_OES_EGL_image);
+ d->EGLImageTargetRenderbufferStorageOES(target, image);
+}
+
+class QOpenGLExtension_OES_get_program_binaryPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetProgramBinaryOES)(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+ void (QOPENGLF_APIENTRYP ProgramBinaryOES)(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLint length);
+};
+
+class QOpenGLExtension_OES_get_program_binary : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_OES_get_program_binary();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetProgramBinaryOES(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary);
+ void glProgramBinaryOES(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLint length);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_OES_get_program_binary)
+};
+
+inline void QOpenGLExtension_OES_get_program_binary::glGetProgramBinaryOES(GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, GLvoid *binary)
+{
+ Q_D(QOpenGLExtension_OES_get_program_binary);
+ d->GetProgramBinaryOES(program, bufSize, length, binaryFormat, binary);
+}
+
+inline void QOpenGLExtension_OES_get_program_binary::glProgramBinaryOES(GLuint program, GLenum binaryFormat, const GLvoid *binary, GLint length)
+{
+ Q_D(QOpenGLExtension_OES_get_program_binary);
+ d->ProgramBinaryOES(program, binaryFormat, binary, length);
+}
+
+class QOpenGLExtension_OES_mapbufferPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void* (QOPENGLF_APIENTRYP MapBufferOES)(GLenum target, GLenum access);
+ GLboolean (QOPENGLF_APIENTRYP UnmapBufferOES)(GLenum target);
+ void (QOPENGLF_APIENTRYP GetBufferPointervOES)(GLenum target, GLenum pname, GLvoid** params);
+};
+
+class QOpenGLExtension_OES_mapbuffer : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_OES_mapbuffer();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void* glMapBufferOES(GLenum target, GLenum access);
+ GLboolean glUnmapBufferOES(GLenum target);
+ void glGetBufferPointervOES(GLenum target, GLenum pname, GLvoid** params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_OES_mapbuffer)
+};
+
+inline void *QOpenGLExtension_OES_mapbuffer::glMapBufferOES(GLenum target, GLenum access)
+{
+ Q_D(QOpenGLExtension_OES_mapbuffer);
+ return d->MapBufferOES(target, access);
+}
+
+inline GLboolean QOpenGLExtension_OES_mapbuffer::glUnmapBufferOES(GLenum target)
+{
+ Q_D(QOpenGLExtension_OES_mapbuffer);
+ return d->UnmapBufferOES(target);
+}
+
+inline void QOpenGLExtension_OES_mapbuffer::glGetBufferPointervOES(GLenum target, GLenum pname, GLvoid** params)
+{
+ Q_D(QOpenGLExtension_OES_mapbuffer);
+ d->GetBufferPointervOES(target, pname, params);
+}
+
+class QOpenGLExtension_OES_texture_3DPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexImage3DOES)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid* pixels);
+ void (QOPENGLF_APIENTRYP TexSubImage3DOES)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid* pixels);
+ void (QOPENGLF_APIENTRYP CopyTexSubImage3DOES)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP CompressedTexImage3DOES)(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+ void (QOPENGLF_APIENTRYP CompressedTexSubImage3DOES)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+ void (QOPENGLF_APIENTRYP FramebufferTexture3DOES)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+};
+
+class QOpenGLExtension_OES_texture_3D : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_OES_texture_3D();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexImage3DOES(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid* pixels);
+ void glTexSubImage3DOES(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid* pixels);
+ void glCopyTexSubImage3DOES(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+ void glCompressedTexImage3DOES(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+ void glCompressedTexSubImage3DOES(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+ void glFramebufferTexture3DOES(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_OES_texture_3D)
+};
+
+inline void QOpenGLExtension_OES_texture_3D::glTexImage3DOES(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid* pixels)
+{
+ Q_D(QOpenGLExtension_OES_texture_3D);
+ d->TexImage3DOES(target, level, internalformat, width, height, depth, border, format, type, pixels);
+}
+
+inline void QOpenGLExtension_OES_texture_3D::glTexSubImage3DOES(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid* pixels)
+{
+ Q_D(QOpenGLExtension_OES_texture_3D);
+ d->TexSubImage3DOES(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, pixels);
+}
+
+inline void QOpenGLExtension_OES_texture_3D::glCopyTexSubImage3DOES(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_OES_texture_3D);
+ d->CopyTexSubImage3DOES(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+inline void QOpenGLExtension_OES_texture_3D::glCompressedTexImage3DOES(GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ Q_D(QOpenGLExtension_OES_texture_3D);
+ d->CompressedTexImage3DOES(target, level, internalformat, width, height, depth, border, imageSize, data);
+}
+
+inline void QOpenGLExtension_OES_texture_3D::glCompressedTexSubImage3DOES(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ Q_D(QOpenGLExtension_OES_texture_3D);
+ d->CompressedTexSubImage3DOES(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+inline void QOpenGLExtension_OES_texture_3D::glFramebufferTexture3DOES(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ Q_D(QOpenGLExtension_OES_texture_3D);
+ d->FramebufferTexture3DOES(target, attachment, textarget, texture, level, zoffset);
+}
+
+class QOpenGLExtension_OES_vertex_array_objectPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BindVertexArrayOES)(GLuint array);
+ void (QOPENGLF_APIENTRYP DeleteVertexArraysOES)(GLsizei n, const GLuint *arrays);
+ void (QOPENGLF_APIENTRYP GenVertexArraysOES)(GLsizei n, GLuint *arrays);
+ GLboolean (QOPENGLF_APIENTRYP IsVertexArrayOES)(GLuint array);
+};
+
+class QOpenGLExtension_OES_vertex_array_object : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_OES_vertex_array_object();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBindVertexArrayOES(GLuint array);
+ void glDeleteVertexArraysOES(GLsizei n, const GLuint *arrays);
+ void glGenVertexArraysOES(GLsizei n, GLuint *arrays);
+ GLboolean glIsVertexArrayOES(GLuint array);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_OES_vertex_array_object)
+};
+
+inline void QOpenGLExtension_OES_vertex_array_object::glBindVertexArrayOES(GLuint array)
+{
+ Q_D(QOpenGLExtension_OES_vertex_array_object);
+ d->BindVertexArrayOES(array);
+}
+
+inline void QOpenGLExtension_OES_vertex_array_object::glDeleteVertexArraysOES(GLsizei n, const GLuint *arrays)
+{
+ Q_D(QOpenGLExtension_OES_vertex_array_object);
+ d->DeleteVertexArraysOES(n, arrays);
+}
+
+inline void QOpenGLExtension_OES_vertex_array_object::glGenVertexArraysOES(GLsizei n, GLuint *arrays)
+{
+ Q_D(QOpenGLExtension_OES_vertex_array_object);
+ d->GenVertexArraysOES(n, arrays);
+}
+
+inline GLboolean QOpenGLExtension_OES_vertex_array_object::glIsVertexArrayOES(GLuint array)
+{
+ Q_D(QOpenGLExtension_OES_vertex_array_object);
+ return d->IsVertexArrayOES(array);
+}
+
+class QOpenGLExtension_AMD_performance_monitorPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetPerfMonitorGroupsAMD)(GLint *numGroups, GLsizei groupsSize, GLuint *groups);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorCountersAMD)(GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorGroupStringAMD)(GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorCounterStringAMD)(GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorCounterInfoAMD)(GLuint group, GLuint counter, GLenum pname, GLvoid *data);
+ void (QOPENGLF_APIENTRYP GenPerfMonitorsAMD)(GLsizei n, GLuint *monitors);
+ void (QOPENGLF_APIENTRYP DeletePerfMonitorsAMD)(GLsizei n, GLuint *monitors);
+ void (QOPENGLF_APIENTRYP SelectPerfMonitorCountersAMD)(GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *countersList);
+ void (QOPENGLF_APIENTRYP BeginPerfMonitorAMD)(GLuint monitor);
+ void (QOPENGLF_APIENTRYP EndPerfMonitorAMD)(GLuint monitor);
+ void (QOPENGLF_APIENTRYP GetPerfMonitorCounterDataAMD)(GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten);
+};
+
+class QOpenGLExtension_AMD_performance_monitor : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_AMD_performance_monitor();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetPerfMonitorGroupsAMD(GLint *numGroups, GLsizei groupsSize, GLuint *groups);
+ void glGetPerfMonitorCountersAMD(GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters);
+ void glGetPerfMonitorGroupStringAMD(GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString);
+ void glGetPerfMonitorCounterStringAMD(GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString);
+ void glGetPerfMonitorCounterInfoAMD(GLuint group, GLuint counter, GLenum pname, GLvoid *data);
+ void glGenPerfMonitorsAMD(GLsizei n, GLuint *monitors);
+ void glDeletePerfMonitorsAMD(GLsizei n, GLuint *monitors);
+ void glSelectPerfMonitorCountersAMD(GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *countersList);
+ void glBeginPerfMonitorAMD(GLuint monitor);
+ void glEndPerfMonitorAMD(GLuint monitor);
+ void glGetPerfMonitorCounterDataAMD(GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_AMD_performance_monitor)
+};
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorGroupsAMD(GLint *numGroups, GLsizei groupsSize, GLuint *groups)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorGroupsAMD(numGroups, groupsSize, groups);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorCountersAMD(GLuint group, GLint *numCounters, GLint *maxActiveCounters, GLsizei counterSize, GLuint *counters)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorCountersAMD(group, numCounters, maxActiveCounters, counterSize, counters);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorGroupStringAMD(GLuint group, GLsizei bufSize, GLsizei *length, GLchar *groupString)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorGroupStringAMD(group, bufSize, length, groupString);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorCounterStringAMD(GLuint group, GLuint counter, GLsizei bufSize, GLsizei *length, GLchar *counterString)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorCounterStringAMD(group, counter, bufSize, length, counterString);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorCounterInfoAMD(GLuint group, GLuint counter, GLenum pname, GLvoid *data)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorCounterInfoAMD(group, counter, pname, data);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGenPerfMonitorsAMD(GLsizei n, GLuint *monitors)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GenPerfMonitorsAMD(n, monitors);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glDeletePerfMonitorsAMD(GLsizei n, GLuint *monitors)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->DeletePerfMonitorsAMD(n, monitors);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glSelectPerfMonitorCountersAMD(GLuint monitor, GLboolean enable, GLuint group, GLint numCounters, GLuint *countersList)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->SelectPerfMonitorCountersAMD(monitor, enable, group, numCounters, countersList);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glBeginPerfMonitorAMD(GLuint monitor)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->BeginPerfMonitorAMD(monitor);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glEndPerfMonitorAMD(GLuint monitor)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->EndPerfMonitorAMD(monitor);
+}
+
+inline void QOpenGLExtension_AMD_performance_monitor::glGetPerfMonitorCounterDataAMD(GLuint monitor, GLenum pname, GLsizei dataSize, GLuint *data, GLint *bytesWritten)
+{
+ Q_D(QOpenGLExtension_AMD_performance_monitor);
+ d->GetPerfMonitorCounterDataAMD(monitor, pname, dataSize, data, bytesWritten);
+}
+
+class QOpenGLExtension_ANGLE_framebuffer_blitPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP BlitFramebufferANGLE)(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+};
+
+class QOpenGLExtension_ANGLE_framebuffer_blit : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ANGLE_framebuffer_blit();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glBlitFramebufferANGLE(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ANGLE_framebuffer_blit)
+};
+
+inline void QOpenGLExtension_ANGLE_framebuffer_blit::glBlitFramebufferANGLE(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ Q_D(QOpenGLExtension_ANGLE_framebuffer_blit);
+ d->BlitFramebufferANGLE(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+class QOpenGLExtension_ANGLE_framebuffer_multisamplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP RenderbufferStorageMultisampleANGLE)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+};
+
+class QOpenGLExtension_ANGLE_framebuffer_multisample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ANGLE_framebuffer_multisample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glRenderbufferStorageMultisampleANGLE(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ANGLE_framebuffer_multisample)
+};
+
+inline void QOpenGLExtension_ANGLE_framebuffer_multisample::glRenderbufferStorageMultisampleANGLE(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_ANGLE_framebuffer_multisample);
+ d->RenderbufferStorageMultisampleANGLE(target, samples, internalformat, width, height);
+}
+
+class QOpenGLExtension_ANGLE_instanced_arraysPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawArraysInstancedANGLE)(GLenum mode, GLint first, GLsizei count, GLsizei primcount);
+ void (QOPENGLF_APIENTRYP DrawElementsInstancedANGLE)(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount);
+ void (QOPENGLF_APIENTRYP VertexAttribDivisorANGLE)(GLuint index, GLuint divisor);
+};
+
+class QOpenGLExtension_ANGLE_instanced_arrays : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ANGLE_instanced_arrays();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawArraysInstancedANGLE(GLenum mode, GLint first, GLsizei count, GLsizei primcount);
+ void glDrawElementsInstancedANGLE(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount);
+ void glVertexAttribDivisorANGLE(GLuint index, GLuint divisor);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ANGLE_instanced_arrays)
+};
+
+inline void QOpenGLExtension_ANGLE_instanced_arrays::glDrawArraysInstancedANGLE(GLenum mode, GLint first, GLsizei count, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_ANGLE_instanced_arrays);
+ d->DrawArraysInstancedANGLE(mode, first, count, primcount);
+}
+
+inline void QOpenGLExtension_ANGLE_instanced_arrays::glDrawElementsInstancedANGLE(GLenum mode, GLsizei count, GLenum type, const void *indices, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_ANGLE_instanced_arrays);
+ d->DrawElementsInstancedANGLE(mode, count, type, indices, primcount);
+}
+
+inline void QOpenGLExtension_ANGLE_instanced_arrays::glVertexAttribDivisorANGLE(GLuint index, GLuint divisor)
+{
+ Q_D(QOpenGLExtension_ANGLE_instanced_arrays);
+ d->VertexAttribDivisorANGLE(index, divisor);
+}
+
+class QOpenGLExtension_ANGLE_translated_shader_sourcePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetTranslatedShaderSourceANGLE)(GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source);
+};
+
+class QOpenGLExtension_ANGLE_translated_shader_source : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_ANGLE_translated_shader_source();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetTranslatedShaderSourceANGLE(GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_ANGLE_translated_shader_source)
+};
+
+inline void QOpenGLExtension_ANGLE_translated_shader_source::glGetTranslatedShaderSourceANGLE(GLuint shader, GLsizei bufsize, GLsizei *length, GLchar *source)
+{
+ Q_D(QOpenGLExtension_ANGLE_translated_shader_source);
+ d->GetTranslatedShaderSourceANGLE(shader, bufsize, length, source);
+}
+
+class QOpenGLExtension_APPLE_framebuffer_multisamplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP RenderbufferStorageMultisampleAPPLE)(GLenum, GLsizei, GLenum, GLsizei, GLsizei);
+ void (QOPENGLF_APIENTRYP ResolveMultisampleFramebufferAPPLE)(void);
+};
+
+class QOpenGLExtension_APPLE_framebuffer_multisample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_APPLE_framebuffer_multisample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glRenderbufferStorageMultisampleAPPLE(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glResolveMultisampleFramebufferAPPLE(void);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_APPLE_framebuffer_multisample)
+};
+
+inline void QOpenGLExtension_APPLE_framebuffer_multisample::glRenderbufferStorageMultisampleAPPLE(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_APPLE_framebuffer_multisample);
+ d->RenderbufferStorageMultisampleAPPLE(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_APPLE_framebuffer_multisample::glResolveMultisampleFramebufferAPPLE(void)
+{
+ Q_D(QOpenGLExtension_APPLE_framebuffer_multisample);
+ d->ResolveMultisampleFramebufferAPPLE();
+}
+
+class QOpenGLExtension_EXT_debug_labelPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP LabelObjectEXT)(GLenum type, GLuint object, GLsizei length, const GLchar *label);
+ void (QOPENGLF_APIENTRYP GetObjectLabelEXT)(GLenum type, GLuint object, GLsizei bufSize, GLsizei *length, GLchar *label);
+};
+
+class QOpenGLExtension_EXT_debug_label : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_debug_label();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glLabelObjectEXT(GLenum type, GLuint object, GLsizei length, const GLchar *label);
+ void glGetObjectLabelEXT(GLenum type, GLuint object, GLsizei bufSize, GLsizei *length, GLchar *label);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_debug_label)
+};
+
+inline void QOpenGLExtension_EXT_debug_label::glLabelObjectEXT(GLenum type, GLuint object, GLsizei length, const GLchar *label)
+{
+ Q_D(QOpenGLExtension_EXT_debug_label);
+ d->LabelObjectEXT(type, object, length, label);
+}
+
+inline void QOpenGLExtension_EXT_debug_label::glGetObjectLabelEXT(GLenum type, GLuint object, GLsizei bufSize, GLsizei *length, GLchar *label)
+{
+ Q_D(QOpenGLExtension_EXT_debug_label);
+ d->GetObjectLabelEXT(type, object, bufSize, length, label);
+}
+
+class QOpenGLExtension_EXT_debug_markerPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP InsertEventMarkerEXT)(GLsizei length, const GLchar *marker);
+ void (QOPENGLF_APIENTRYP PushGroupMarkerEXT)(GLsizei length, const GLchar *marker);
+ void (QOPENGLF_APIENTRYP PopGroupMarkerEXT)(void);
+};
+
+class QOpenGLExtension_EXT_debug_marker : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_debug_marker();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glInsertEventMarkerEXT(GLsizei length, const GLchar *marker);
+ void glPushGroupMarkerEXT(GLsizei length, const GLchar *marker);
+ void glPopGroupMarkerEXT(void);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_debug_marker)
+};
+
+inline void QOpenGLExtension_EXT_debug_marker::glInsertEventMarkerEXT(GLsizei length, const GLchar *marker)
+{
+ Q_D(QOpenGLExtension_EXT_debug_marker);
+ d->InsertEventMarkerEXT(length, marker);
+}
+
+inline void QOpenGLExtension_EXT_debug_marker::glPushGroupMarkerEXT(GLsizei length, const GLchar *marker)
+{
+ Q_D(QOpenGLExtension_EXT_debug_marker);
+ d->PushGroupMarkerEXT(length, marker);
+}
+
+inline void QOpenGLExtension_EXT_debug_marker::glPopGroupMarkerEXT(void)
+{
+ Q_D(QOpenGLExtension_EXT_debug_marker);
+ d->PopGroupMarkerEXT();
+}
+
+class QOpenGLExtension_EXT_discard_framebufferPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DiscardFramebufferEXT)(GLenum target, GLsizei numAttachments, const GLenum *attachments);
+};
+
+class QOpenGLExtension_EXT_discard_framebuffer : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_discard_framebuffer();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDiscardFramebufferEXT(GLenum target, GLsizei numAttachments, const GLenum *attachments);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_discard_framebuffer)
+};
+
+inline void QOpenGLExtension_EXT_discard_framebuffer::glDiscardFramebufferEXT(GLenum target, GLsizei numAttachments, const GLenum *attachments)
+{
+ Q_D(QOpenGLExtension_EXT_discard_framebuffer);
+ d->DiscardFramebufferEXT(target, numAttachments, attachments);
+}
+
+class QOpenGLExtension_EXT_multisampled_render_to_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP RenderbufferStorageMultisampleEXT)(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP FramebufferTexture2DMultisampleEXT)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples);
+};
+
+class QOpenGLExtension_EXT_multisampled_render_to_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_multisampled_render_to_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glRenderbufferStorageMultisampleEXT(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glFramebufferTexture2DMultisampleEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_multisampled_render_to_texture)
+};
+
+inline void QOpenGLExtension_EXT_multisampled_render_to_texture::glRenderbufferStorageMultisampleEXT(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_multisampled_render_to_texture);
+ d->RenderbufferStorageMultisampleEXT(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_EXT_multisampled_render_to_texture::glFramebufferTexture2DMultisampleEXT(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples)
+{
+ Q_D(QOpenGLExtension_EXT_multisampled_render_to_texture);
+ d->FramebufferTexture2DMultisampleEXT(target, attachment, textarget, texture, level, samples);
+}
+
+class QOpenGLExtension_EXT_multi_draw_arraysPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP MultiDrawArraysEXT)(GLenum mode, GLint *first, GLsizei *count, GLsizei primcount);
+ void (QOPENGLF_APIENTRYP MultiDrawElementsEXT)(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount);
+};
+
+class QOpenGLExtension_EXT_multi_draw_arrays : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_multi_draw_arrays();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glMultiDrawArraysEXT(GLenum mode, GLint *first, GLsizei *count, GLsizei primcount);
+ void glMultiDrawElementsEXT(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_multi_draw_arrays)
+};
+
+inline void QOpenGLExtension_EXT_multi_draw_arrays::glMultiDrawArraysEXT(GLenum mode, GLint *first, GLsizei *count, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_EXT_multi_draw_arrays);
+ d->MultiDrawArraysEXT(mode, first, count, primcount);
+}
+
+inline void QOpenGLExtension_EXT_multi_draw_arrays::glMultiDrawElementsEXT(GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount)
+{
+ Q_D(QOpenGLExtension_EXT_multi_draw_arrays);
+ d->MultiDrawElementsEXT(mode, count, type, indices, primcount);
+}
+
+class QOpenGLExtension_EXT_occlusion_query_booleanPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GenQueriesEXT)(GLsizei n, GLuint *ids);
+ void (QOPENGLF_APIENTRYP DeleteQueriesEXT)(GLsizei n, const GLuint *ids);
+ GLboolean (QOPENGLF_APIENTRYP IsQueryEXT)(GLuint id);
+ void (QOPENGLF_APIENTRYP BeginQueryEXT)(GLenum target, GLuint id);
+ void (QOPENGLF_APIENTRYP EndQueryEXT)(GLenum target);
+ void (QOPENGLF_APIENTRYP GetQueryivEXT)(GLenum target, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP GetQueryObjectuivEXT)(GLuint id, GLenum pname, GLuint *params);
+};
+
+class QOpenGLExtension_EXT_occlusion_query_boolean : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_occlusion_query_boolean();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGenQueriesEXT(GLsizei n, GLuint *ids);
+ void glDeleteQueriesEXT(GLsizei n, const GLuint *ids);
+ GLboolean glIsQueryEXT(GLuint id);
+ void glBeginQueryEXT(GLenum target, GLuint id);
+ void glEndQueryEXT(GLenum target);
+ void glGetQueryivEXT(GLenum target, GLenum pname, GLint *params);
+ void glGetQueryObjectuivEXT(GLuint id, GLenum pname, GLuint *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_occlusion_query_boolean)
+};
+
+inline void QOpenGLExtension_EXT_occlusion_query_boolean::glGenQueriesEXT(GLsizei n, GLuint *ids)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ d->GenQueriesEXT(n, ids);
+}
+
+inline void QOpenGLExtension_EXT_occlusion_query_boolean::glDeleteQueriesEXT(GLsizei n, const GLuint *ids)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ d->DeleteQueriesEXT(n, ids);
+}
+
+inline GLboolean QOpenGLExtension_EXT_occlusion_query_boolean::glIsQueryEXT(GLuint id)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ return d->IsQueryEXT(id);
+}
+
+inline void QOpenGLExtension_EXT_occlusion_query_boolean::glBeginQueryEXT(GLenum target, GLuint id)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ d->BeginQueryEXT(target, id);
+}
+
+inline void QOpenGLExtension_EXT_occlusion_query_boolean::glEndQueryEXT(GLenum target)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ d->EndQueryEXT(target);
+}
+
+inline void QOpenGLExtension_EXT_occlusion_query_boolean::glGetQueryivEXT(GLenum target, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ d->GetQueryivEXT(target, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_occlusion_query_boolean::glGetQueryObjectuivEXT(GLuint id, GLenum pname, GLuint *params)
+{
+ Q_D(QOpenGLExtension_EXT_occlusion_query_boolean);
+ d->GetQueryObjectuivEXT(id, pname, params);
+}
+
+class QOpenGLExtension_EXT_robustnessPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ GLenum (QOPENGLF_APIENTRYP GetGraphicsResetStatusEXT)(void);
+ void (QOPENGLF_APIENTRYP ReadnPixelsEXT)(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data);
+ void (QOPENGLF_APIENTRYP GetnUniformfvEXT)(GLuint program, GLint location, GLsizei bufSize, float *params);
+ void (QOPENGLF_APIENTRYP GetnUniformivEXT)(GLuint program, GLint location, GLsizei bufSize, GLint *params);
+};
+
+class QOpenGLExtension_EXT_robustness : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_robustness();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ GLenum glGetGraphicsResetStatusEXT(void);
+ void glReadnPixelsEXT(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data);
+ void glGetnUniformfvEXT(GLuint program, GLint location, GLsizei bufSize, float *params);
+ void glGetnUniformivEXT(GLuint program, GLint location, GLsizei bufSize, GLint *params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_robustness)
+};
+
+inline GLenum QOpenGLExtension_EXT_robustness::glGetGraphicsResetStatusEXT(void)
+{
+ Q_D(QOpenGLExtension_EXT_robustness);
+ return d->GetGraphicsResetStatusEXT();
+}
+
+inline void QOpenGLExtension_EXT_robustness::glReadnPixelsEXT(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, void *data)
+{
+ Q_D(QOpenGLExtension_EXT_robustness);
+ d->ReadnPixelsEXT(x, y, width, height, format, type, bufSize, data);
+}
+
+inline void QOpenGLExtension_EXT_robustness::glGetnUniformfvEXT(GLuint program, GLint location, GLsizei bufSize, float *params)
+{
+ Q_D(QOpenGLExtension_EXT_robustness);
+ d->GetnUniformfvEXT(program, location, bufSize, params);
+}
+
+inline void QOpenGLExtension_EXT_robustness::glGetnUniformivEXT(GLuint program, GLint location, GLsizei bufSize, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_robustness);
+ d->GetnUniformivEXT(program, location, bufSize, params);
+}
+
+class QOpenGLExtension_EXT_separate_shader_objectsPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP UseProgramStagesEXT)(GLuint pipeline, GLbitfield stages, GLuint program);
+ void (QOPENGLF_APIENTRYP ActiveShaderProgramEXT)(GLuint pipeline, GLuint program);
+ GLuint (QOPENGLF_APIENTRYP CreateShaderProgramvEXT)(GLenum type, GLsizei count, const GLchar **strings);
+ void (QOPENGLF_APIENTRYP BindProgramPipelineEXT)(GLuint pipeline);
+ void (QOPENGLF_APIENTRYP DeleteProgramPipelinesEXT)(GLsizei n, const GLuint *pipelines);
+ void (QOPENGLF_APIENTRYP GenProgramPipelinesEXT)(GLsizei n, GLuint *pipelines);
+ GLboolean (QOPENGLF_APIENTRYP IsProgramPipelineEXT)(GLuint pipeline);
+ void (QOPENGLF_APIENTRYP ProgramParameteriEXT)(GLuint program, GLenum pname, GLint value);
+ void (QOPENGLF_APIENTRYP GetProgramPipelineivEXT)(GLuint pipeline, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP ProgramUniform1iEXT)(GLuint program, GLint location, GLint x);
+ void (QOPENGLF_APIENTRYP ProgramUniform2iEXT)(GLuint program, GLint location, GLint x, GLint y);
+ void (QOPENGLF_APIENTRYP ProgramUniform3iEXT)(GLuint program, GLint location, GLint x, GLint y, GLint z);
+ void (QOPENGLF_APIENTRYP ProgramUniform4iEXT)(GLuint program, GLint location, GLint x, GLint y, GLint z, GLint w);
+ void (QOPENGLF_APIENTRYP ProgramUniform1fEXT)(GLuint program, GLint location, GLfloat x);
+ void (QOPENGLF_APIENTRYP ProgramUniform2fEXT)(GLuint program, GLint location, GLfloat x, GLfloat y);
+ void (QOPENGLF_APIENTRYP ProgramUniform3fEXT)(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z);
+ void (QOPENGLF_APIENTRYP ProgramUniform4fEXT)(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void (QOPENGLF_APIENTRYP ProgramUniform1ivEXT)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2ivEXT)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3ivEXT)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4ivEXT)(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform1fvEXT)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform2fvEXT)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform3fvEXT)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniform4fvEXT)(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix2fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix3fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ProgramUniformMatrix4fvEXT)(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void (QOPENGLF_APIENTRYP ValidateProgramPipelineEXT)(GLuint pipeline);
+ void (QOPENGLF_APIENTRYP GetProgramPipelineInfoLogEXT)(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+};
+
+class QOpenGLExtension_EXT_separate_shader_objects : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_separate_shader_objects();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glUseProgramStagesEXT(GLuint pipeline, GLbitfield stages, GLuint program);
+ void glActiveShaderProgramEXT(GLuint pipeline, GLuint program);
+ GLuint glCreateShaderProgramvEXT(GLenum type, GLsizei count, const GLchar **strings);
+ void glBindProgramPipelineEXT(GLuint pipeline);
+ void glDeleteProgramPipelinesEXT(GLsizei n, const GLuint *pipelines);
+ void glGenProgramPipelinesEXT(GLsizei n, GLuint *pipelines);
+ GLboolean glIsProgramPipelineEXT(GLuint pipeline);
+ void glProgramParameteriEXT(GLuint program, GLenum pname, GLint value);
+ void glGetProgramPipelineivEXT(GLuint pipeline, GLenum pname, GLint *params);
+ void glProgramUniform1iEXT(GLuint program, GLint location, GLint x);
+ void glProgramUniform2iEXT(GLuint program, GLint location, GLint x, GLint y);
+ void glProgramUniform3iEXT(GLuint program, GLint location, GLint x, GLint y, GLint z);
+ void glProgramUniform4iEXT(GLuint program, GLint location, GLint x, GLint y, GLint z, GLint w);
+ void glProgramUniform1fEXT(GLuint program, GLint location, GLfloat x);
+ void glProgramUniform2fEXT(GLuint program, GLint location, GLfloat x, GLfloat y);
+ void glProgramUniform3fEXT(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z);
+ void glProgramUniform4fEXT(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+ void glProgramUniform1ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform2ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform3ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform4ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value);
+ void glProgramUniform1fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform2fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform3fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniform4fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value);
+ void glProgramUniformMatrix2fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix3fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glProgramUniformMatrix4fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value);
+ void glValidateProgramPipelineEXT(GLuint pipeline);
+ void glGetProgramPipelineInfoLogEXT(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_separate_shader_objects)
+};
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glUseProgramStagesEXT(GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->UseProgramStagesEXT(pipeline, stages, program);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glActiveShaderProgramEXT(GLuint pipeline, GLuint program)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ActiveShaderProgramEXT(pipeline, program);
+}
+
+inline GLuint QOpenGLExtension_EXT_separate_shader_objects::glCreateShaderProgramvEXT(GLenum type, GLsizei count, const GLchar **strings)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ return d->CreateShaderProgramvEXT(type, count, strings);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glBindProgramPipelineEXT(GLuint pipeline)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->BindProgramPipelineEXT(pipeline);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glDeleteProgramPipelinesEXT(GLsizei n, const GLuint *pipelines)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->DeleteProgramPipelinesEXT(n, pipelines);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glGenProgramPipelinesEXT(GLsizei n, GLuint *pipelines)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->GenProgramPipelinesEXT(n, pipelines);
+}
+
+inline GLboolean QOpenGLExtension_EXT_separate_shader_objects::glIsProgramPipelineEXT(GLuint pipeline)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ return d->IsProgramPipelineEXT(pipeline);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramParameteriEXT(GLuint program, GLenum pname, GLint value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramParameteriEXT(program, pname, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glGetProgramPipelineivEXT(GLuint pipeline, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->GetProgramPipelineivEXT(pipeline, pname, params);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform1iEXT(GLuint program, GLint location, GLint x)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform1iEXT(program, location, x);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform2iEXT(GLuint program, GLint location, GLint x, GLint y)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform2iEXT(program, location, x, y);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform3iEXT(GLuint program, GLint location, GLint x, GLint y, GLint z)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform3iEXT(program, location, x, y, z);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform4iEXT(GLuint program, GLint location, GLint x, GLint y, GLint z, GLint w)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform4iEXT(program, location, x, y, z, w);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform1fEXT(GLuint program, GLint location, GLfloat x)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform1fEXT(program, location, x);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform2fEXT(GLuint program, GLint location, GLfloat x, GLfloat y)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform2fEXT(program, location, x, y);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform3fEXT(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform3fEXT(program, location, x, y, z);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform4fEXT(GLuint program, GLint location, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform4fEXT(program, location, x, y, z, w);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform1ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform1ivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform2ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform2ivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform3ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform3ivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform4ivEXT(GLuint program, GLint location, GLsizei count, const GLint *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform4ivEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform1fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform1fvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform2fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform2fvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform3fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform3fvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniform4fvEXT(GLuint program, GLint location, GLsizei count, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniform4fvEXT(program, location, count, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniformMatrix2fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniformMatrix2fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniformMatrix3fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniformMatrix3fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glProgramUniformMatrix4fvEXT(GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat *value)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ProgramUniformMatrix4fvEXT(program, location, count, transpose, value);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glValidateProgramPipelineEXT(GLuint pipeline)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->ValidateProgramPipelineEXT(pipeline);
+}
+
+inline void QOpenGLExtension_EXT_separate_shader_objects::glGetProgramPipelineInfoLogEXT(GLuint pipeline, GLsizei bufSize, GLsizei *length, GLchar *infoLog)
+{
+ Q_D(QOpenGLExtension_EXT_separate_shader_objects);
+ d->GetProgramPipelineInfoLogEXT(pipeline, bufSize, length, infoLog);
+}
+
+class QOpenGLExtension_EXT_texture_storagePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP TexStorage1DEXT)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void (QOPENGLF_APIENTRYP TexStorage2DEXT)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP TexStorage3DEXT)(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void (QOPENGLF_APIENTRYP TextureStorage1DEXT)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void (QOPENGLF_APIENTRYP TextureStorage2DEXT)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void (QOPENGLF_APIENTRYP TextureStorage3DEXT)(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+};
+
+class QOpenGLExtension_EXT_texture_storage : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_EXT_texture_storage();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glTexStorage1DEXT(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void glTexStorage3DEXT(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+ void glTextureStorage1DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width);
+ void glTextureStorage2DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height);
+ void glTextureStorage3DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_EXT_texture_storage)
+};
+
+inline void QOpenGLExtension_EXT_texture_storage::glTexStorage1DEXT(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width)
+{
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+ d->TexStorage1DEXT(target, levels, internalformat, width);
+}
+
+inline void QOpenGLExtension_EXT_texture_storage::glTexStorage2DEXT(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+ d->TexStorage2DEXT(target, levels, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_EXT_texture_storage::glTexStorage3DEXT(GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+ d->TexStorage3DEXT(target, levels, internalformat, width, height, depth);
+}
+
+inline void QOpenGLExtension_EXT_texture_storage::glTextureStorage1DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width)
+{
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+ d->TextureStorage1DEXT(texture, target, levels, internalformat, width);
+}
+
+inline void QOpenGLExtension_EXT_texture_storage::glTextureStorage2DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+ d->TextureStorage2DEXT(texture, target, levels, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_EXT_texture_storage::glTextureStorage3DEXT(GLuint texture, GLenum target, GLsizei levels, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ Q_D(QOpenGLExtension_EXT_texture_storage);
+ d->TextureStorage3DEXT(texture, target, levels, internalformat, width, height, depth);
+}
+
+class QOpenGLExtension_IMG_multisampled_render_to_texturePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP RenderbufferStorageMultisampleIMG)(GLenum, GLsizei, GLenum, GLsizei, GLsizei);
+ void (QOPENGLF_APIENTRYP FramebufferTexture2DMultisampleIMG)(GLenum, GLenum, GLenum, GLuint, GLint, GLsizei);
+};
+
+class QOpenGLExtension_IMG_multisampled_render_to_texture : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_IMG_multisampled_render_to_texture();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glRenderbufferStorageMultisampleIMG(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height);
+ void glFramebufferTexture2DMultisampleIMG(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_IMG_multisampled_render_to_texture)
+};
+
+inline void QOpenGLExtension_IMG_multisampled_render_to_texture::glRenderbufferStorageMultisampleIMG(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height)
+{
+ Q_D(QOpenGLExtension_IMG_multisampled_render_to_texture);
+ d->RenderbufferStorageMultisampleIMG(target, samples, internalformat, width, height);
+}
+
+inline void QOpenGLExtension_IMG_multisampled_render_to_texture::glFramebufferTexture2DMultisampleIMG(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLsizei samples)
+{
+ Q_D(QOpenGLExtension_IMG_multisampled_render_to_texture);
+ d->FramebufferTexture2DMultisampleIMG(target, attachment, textarget, texture, level, samples);
+}
+
+class QOpenGLExtension_NV_coverage_samplePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP CoverageMaskNV)(GLboolean mask);
+ void (QOPENGLF_APIENTRYP CoverageOperationNV)(GLenum operation);
+};
+
+class QOpenGLExtension_NV_coverage_sample : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_coverage_sample();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glCoverageMaskNV(GLboolean mask);
+ void glCoverageOperationNV(GLenum operation);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_coverage_sample)
+};
+
+inline void QOpenGLExtension_NV_coverage_sample::glCoverageMaskNV(GLboolean mask)
+{
+ Q_D(QOpenGLExtension_NV_coverage_sample);
+ d->CoverageMaskNV(mask);
+}
+
+inline void QOpenGLExtension_NV_coverage_sample::glCoverageOperationNV(GLenum operation)
+{
+ Q_D(QOpenGLExtension_NV_coverage_sample);
+ d->CoverageOperationNV(operation);
+}
+
+class QOpenGLExtension_NV_draw_buffersPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DrawBuffersNV)(GLsizei n, const GLenum *bufs);
+};
+
+class QOpenGLExtension_NV_draw_buffers : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_draw_buffers();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDrawBuffersNV(GLsizei n, const GLenum *bufs);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_draw_buffers)
+};
+
+inline void QOpenGLExtension_NV_draw_buffers::glDrawBuffersNV(GLsizei n, const GLenum *bufs)
+{
+ Q_D(QOpenGLExtension_NV_draw_buffers);
+ d->DrawBuffersNV(n, bufs);
+}
+
+class QOpenGLExtension_NV_fencePrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP DeleteFencesNV)(GLsizei n, const GLuint *fences);
+ void (QOPENGLF_APIENTRYP GenFencesNV)(GLsizei n, GLuint *fences);
+ GLboolean (QOPENGLF_APIENTRYP IsFenceNV)(GLuint fence);
+ GLboolean (QOPENGLF_APIENTRYP TestFenceNV)(GLuint fence);
+ void (QOPENGLF_APIENTRYP GetFenceivNV)(GLuint fence, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP FinishFenceNV)(GLuint fence);
+ void (QOPENGLF_APIENTRYP SetFenceNV)(GLuint fence, GLenum condition);
+};
+
+class QOpenGLExtension_NV_fence : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_fence();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glDeleteFencesNV(GLsizei n, const GLuint *fences);
+ void glGenFencesNV(GLsizei n, GLuint *fences);
+ GLboolean glIsFenceNV(GLuint fence);
+ GLboolean glTestFenceNV(GLuint fence);
+ void glGetFenceivNV(GLuint fence, GLenum pname, GLint *params);
+ void glFinishFenceNV(GLuint fence);
+ void glSetFenceNV(GLuint fence, GLenum condition);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_fence)
+};
+
+inline void QOpenGLExtension_NV_fence::glDeleteFencesNV(GLsizei n, const GLuint *fences)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->DeleteFencesNV(n, fences);
+}
+
+inline void QOpenGLExtension_NV_fence::glGenFencesNV(GLsizei n, GLuint *fences)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->GenFencesNV(n, fences);
+}
+
+inline GLboolean QOpenGLExtension_NV_fence::glIsFenceNV(GLuint fence)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ return d->IsFenceNV(fence);
+}
+
+inline GLboolean QOpenGLExtension_NV_fence::glTestFenceNV(GLuint fence)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ return d->TestFenceNV(fence);
+}
+
+inline void QOpenGLExtension_NV_fence::glGetFenceivNV(GLuint fence, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->GetFenceivNV(fence, pname, params);
+}
+
+inline void QOpenGLExtension_NV_fence::glFinishFenceNV(GLuint fence)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->FinishFenceNV(fence);
+}
+
+inline void QOpenGLExtension_NV_fence::glSetFenceNV(GLuint fence, GLenum condition)
+{
+ Q_D(QOpenGLExtension_NV_fence);
+ d->SetFenceNV(fence, condition);
+}
+
+class QOpenGLExtension_NV_read_bufferPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ReadBufferNV)(GLenum mode);
+};
+
+class QOpenGLExtension_NV_read_buffer : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_NV_read_buffer();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glReadBufferNV(GLenum mode);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_NV_read_buffer)
+};
+
+inline void QOpenGLExtension_NV_read_buffer::glReadBufferNV(GLenum mode)
+{
+ Q_D(QOpenGLExtension_NV_read_buffer);
+ d->ReadBufferNV(mode);
+}
+
+class QOpenGLExtension_QCOM_alpha_testPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP AlphaFuncQCOM)(GLenum func, GLclampf ref);
+};
+
+class QOpenGLExtension_QCOM_alpha_test : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_QCOM_alpha_test();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glAlphaFuncQCOM(GLenum func, GLclampf ref);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_QCOM_alpha_test)
+};
+
+inline void QOpenGLExtension_QCOM_alpha_test::glAlphaFuncQCOM(GLenum func, GLclampf ref)
+{
+ Q_D(QOpenGLExtension_QCOM_alpha_test);
+ d->AlphaFuncQCOM(func, ref);
+}
+
+class QOpenGLExtension_QCOM_driver_controlPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP GetDriverControlsQCOM)(GLint *num, GLsizei size, GLuint *driverControls);
+ void (QOPENGLF_APIENTRYP GetDriverControlStringQCOM)(GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString);
+ void (QOPENGLF_APIENTRYP EnableDriverControlQCOM)(GLuint driverControl);
+ void (QOPENGLF_APIENTRYP DisableDriverControlQCOM)(GLuint driverControl);
+};
+
+class QOpenGLExtension_QCOM_driver_control : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_QCOM_driver_control();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glGetDriverControlsQCOM(GLint *num, GLsizei size, GLuint *driverControls);
+ void glGetDriverControlStringQCOM(GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString);
+ void glEnableDriverControlQCOM(GLuint driverControl);
+ void glDisableDriverControlQCOM(GLuint driverControl);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_QCOM_driver_control)
+};
+
+inline void QOpenGLExtension_QCOM_driver_control::glGetDriverControlsQCOM(GLint *num, GLsizei size, GLuint *driverControls)
+{
+ Q_D(QOpenGLExtension_QCOM_driver_control);
+ d->GetDriverControlsQCOM(num, size, driverControls);
+}
+
+inline void QOpenGLExtension_QCOM_driver_control::glGetDriverControlStringQCOM(GLuint driverControl, GLsizei bufSize, GLsizei *length, GLchar *driverControlString)
+{
+ Q_D(QOpenGLExtension_QCOM_driver_control);
+ d->GetDriverControlStringQCOM(driverControl, bufSize, length, driverControlString);
+}
+
+inline void QOpenGLExtension_QCOM_driver_control::glEnableDriverControlQCOM(GLuint driverControl)
+{
+ Q_D(QOpenGLExtension_QCOM_driver_control);
+ d->EnableDriverControlQCOM(driverControl);
+}
+
+inline void QOpenGLExtension_QCOM_driver_control::glDisableDriverControlQCOM(GLuint driverControl)
+{
+ Q_D(QOpenGLExtension_QCOM_driver_control);
+ d->DisableDriverControlQCOM(driverControl);
+}
+
+class QOpenGLExtension_QCOM_extended_getPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ExtGetTexturesQCOM)(GLuint *textures, GLint maxTextures, GLint *numTextures);
+ void (QOPENGLF_APIENTRYP ExtGetBuffersQCOM)(GLuint *buffers, GLint maxBuffers, GLint *numBuffers);
+ void (QOPENGLF_APIENTRYP ExtGetRenderbuffersQCOM)(GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers);
+ void (QOPENGLF_APIENTRYP ExtGetFramebuffersQCOM)(GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers);
+ void (QOPENGLF_APIENTRYP ExtGetTexLevelParameterivQCOM)(GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params);
+ void (QOPENGLF_APIENTRYP ExtTexObjectStateOverrideiQCOM)(GLenum target, GLenum pname, GLint param);
+ void (QOPENGLF_APIENTRYP ExtGetTexSubImageQCOM)(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLvoid *texels);
+ void (QOPENGLF_APIENTRYP ExtGetBufferPointervQCOM)(GLenum target, GLvoid **params);
+};
+
+class QOpenGLExtension_QCOM_extended_get : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_QCOM_extended_get();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glExtGetTexturesQCOM(GLuint *textures, GLint maxTextures, GLint *numTextures);
+ void glExtGetBuffersQCOM(GLuint *buffers, GLint maxBuffers, GLint *numBuffers);
+ void glExtGetRenderbuffersQCOM(GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers);
+ void glExtGetFramebuffersQCOM(GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers);
+ void glExtGetTexLevelParameterivQCOM(GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params);
+ void glExtTexObjectStateOverrideiQCOM(GLenum target, GLenum pname, GLint param);
+ void glExtGetTexSubImageQCOM(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLvoid *texels);
+ void glExtGetBufferPointervQCOM(GLenum target, GLvoid **params);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_QCOM_extended_get)
+};
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetTexturesQCOM(GLuint *textures, GLint maxTextures, GLint *numTextures)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetTexturesQCOM(textures, maxTextures, numTextures);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetBuffersQCOM(GLuint *buffers, GLint maxBuffers, GLint *numBuffers)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetBuffersQCOM(buffers, maxBuffers, numBuffers);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetRenderbuffersQCOM(GLuint *renderbuffers, GLint maxRenderbuffers, GLint *numRenderbuffers)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetRenderbuffersQCOM(renderbuffers, maxRenderbuffers, numRenderbuffers);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetFramebuffersQCOM(GLuint *framebuffers, GLint maxFramebuffers, GLint *numFramebuffers)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetFramebuffersQCOM(framebuffers, maxFramebuffers, numFramebuffers);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetTexLevelParameterivQCOM(GLuint texture, GLenum face, GLint level, GLenum pname, GLint *params)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetTexLevelParameterivQCOM(texture, face, level, pname, params);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtTexObjectStateOverrideiQCOM(GLenum target, GLenum pname, GLint param)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtTexObjectStateOverrideiQCOM(target, pname, param);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetTexSubImageQCOM(GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLvoid *texels)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetTexSubImageQCOM(target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, texels);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get::glExtGetBufferPointervQCOM(GLenum target, GLvoid **params)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get);
+ d->ExtGetBufferPointervQCOM(target, params);
+}
+
+class QOpenGLExtension_QCOM_extended_get2Private : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP ExtGetShadersQCOM)(GLuint *shaders, GLint maxShaders, GLint *numShaders);
+ void (QOPENGLF_APIENTRYP ExtGetProgramsQCOM)(GLuint *programs, GLint maxPrograms, GLint *numPrograms);
+ GLboolean (QOPENGLF_APIENTRYP ExtIsProgramBinaryQCOM)(GLuint program);
+ void (QOPENGLF_APIENTRYP ExtGetProgramBinarySourceQCOM)(GLuint program, GLenum shadertype, GLchar *source, GLint *length);
+};
+
+class QOpenGLExtension_QCOM_extended_get2 : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_QCOM_extended_get2();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glExtGetShadersQCOM(GLuint *shaders, GLint maxShaders, GLint *numShaders);
+ void glExtGetProgramsQCOM(GLuint *programs, GLint maxPrograms, GLint *numPrograms);
+ GLboolean glExtIsProgramBinaryQCOM(GLuint program);
+ void glExtGetProgramBinarySourceQCOM(GLuint program, GLenum shadertype, GLchar *source, GLint *length);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_QCOM_extended_get2)
+};
+
+inline void QOpenGLExtension_QCOM_extended_get2::glExtGetShadersQCOM(GLuint *shaders, GLint maxShaders, GLint *numShaders)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get2);
+ d->ExtGetShadersQCOM(shaders, maxShaders, numShaders);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get2::glExtGetProgramsQCOM(GLuint *programs, GLint maxPrograms, GLint *numPrograms)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get2);
+ d->ExtGetProgramsQCOM(programs, maxPrograms, numPrograms);
+}
+
+inline GLboolean QOpenGLExtension_QCOM_extended_get2::glExtIsProgramBinaryQCOM(GLuint program)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get2);
+ return d->ExtIsProgramBinaryQCOM(program);
+}
+
+inline void QOpenGLExtension_QCOM_extended_get2::glExtGetProgramBinarySourceQCOM(GLuint program, GLenum shadertype, GLchar *source, GLint *length)
+{
+ Q_D(QOpenGLExtension_QCOM_extended_get2);
+ d->ExtGetProgramBinarySourceQCOM(program, shadertype, source, length);
+}
+
+class QOpenGLExtension_QCOM_tiled_renderingPrivate : public QAbstractOpenGLExtensionPrivate
+{
+public:
+ void (QOPENGLF_APIENTRYP StartTilingQCOM)(GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask);
+ void (QOPENGLF_APIENTRYP EndTilingQCOM)(GLbitfield preserveMask);
+};
+
+class QOpenGLExtension_QCOM_tiled_rendering : public QAbstractOpenGLExtension
+{
+public:
+ QOpenGLExtension_QCOM_tiled_rendering();
+
+ bool initializeOpenGLFunctions() Q_DECL_FINAL;
+
+ void glStartTilingQCOM(GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask);
+ void glEndTilingQCOM(GLbitfield preserveMask);
+
+protected:
+ Q_DECLARE_PRIVATE(QOpenGLExtension_QCOM_tiled_rendering)
+};
+
+inline void QOpenGLExtension_QCOM_tiled_rendering::glStartTilingQCOM(GLuint x, GLuint y, GLuint width, GLuint height, GLbitfield preserveMask)
+{
+ Q_D(QOpenGLExtension_QCOM_tiled_rendering);
+ d->StartTilingQCOM(x, y, width, height, preserveMask);
+}
+
+inline void QOpenGLExtension_QCOM_tiled_rendering::glEndTilingQCOM(GLbitfield preserveMask)
+{
+ Q_D(QOpenGLExtension_QCOM_tiled_rendering);
+ d->EndTilingQCOM(preserveMask);
+}
+
+#endif
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL
+
+#endif
diff --git a/util/glgen/qopenglextensions.h.header b/util/glgen/qopenglextensions.h.header
new file mode 100644
index 0000000000..b83b081166
--- /dev/null
+++ b/util/glgen/qopenglextensions.h.header
@@ -0,0 +1,96 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLEXTENSIONS_H
+#define QOPENGLEXTENSIONS_H
+
+#include <QtCore/qglobal.h>
+
+#ifndef QT_NO_OPENGL
+
+#include <QtGui/qopengl.h>
+
+class QOpenGLContext;
+
+QT_BEGIN_NAMESPACE
+
+#if 0
+// silence syncqt warnings
+#pragma qt_class(QOpenGLExtensions)
+#pragma qt_sync_stop_processing
+#endif
+
+
+class QAbstractOpenGLExtensionPrivate
+{
+public:
+ QAbstractOpenGLExtensionPrivate() : initialized(false) {}
+ bool initialized;
+};
+
+class QAbstractOpenGLExtension
+{
+public:
+ virtual ~QAbstractOpenGLExtension();
+
+ virtual bool initializeOpenGLFunctions();
+
+ Q_DECLARE_PRIVATE(QAbstractOpenGLExtension)
+
+protected:
+ bool isInitialized() const;
+
+ QAbstractOpenGLExtension() {}
+ QAbstractOpenGLExtension(QAbstractOpenGLExtensionPrivate &dd) : d_ptr(&dd) {}
+ QAbstractOpenGLExtensionPrivate *d_ptr;
+};
+
+#if !defined(QT_OPENGL_ES_2)
+
diff --git a/util/glgen/qopenglversionfunctions.cpp.footer b/util/glgen/qopenglversionfunctions.cpp.footer
new file mode 100644
index 0000000000..f003b56097
--- /dev/null
+++ b/util/glgen/qopenglversionfunctions.cpp.footer
@@ -0,0 +1,8 @@
+
+#else
+
+// No backends for OpenGL ES 2
+
+#endif // !QT_OPENGL_ES_2
+
+QT_END_NAMESPACE
diff --git a/util/glgen/qopenglversionfunctions.cpp.header b/util/glgen/qopenglversionfunctions.cpp.header
new file mode 100644
index 0000000000..316b79011d
--- /dev/null
+++ b/util/glgen/qopenglversionfunctions.cpp.header
@@ -0,0 +1,220 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglversionfunctions.h"
+#include "qopenglcontext.h"
+#include "qdebug.h"
+
+QT_BEGIN_NAMESPACE
+
+QOpenGLVersionFunctionsBackend *QAbstractOpenGLFunctionsPrivate::functionsBackend(QOpenGLContext *context,
+ const QOpenGLVersionStatus &v)
+{
+ Q_ASSERT(context);
+ return context->functionsBackend(v);
+}
+
+void QAbstractOpenGLFunctionsPrivate::insertFunctionsBackend(QOpenGLContext *context,
+ const QOpenGLVersionStatus &v,
+ QOpenGLVersionFunctionsBackend *backend)
+{
+ Q_ASSERT(context);
+ context->insertFunctionsBackend(v, backend);
+}
+
+void QAbstractOpenGLFunctionsPrivate::removeFunctionsBackend(QOpenGLContext *context, const QOpenGLVersionStatus &v)
+{
+ Q_ASSERT(context);
+ context->removeFunctionsBackend(v);
+}
+
+
+/*!
+ \class QAbstractOpenGLFunctions
+ \inmodule QtGui
+ \since 5.1
+ \brief The QAbstractOpenGLFunctions class is the base class of a family of
+ classes that expose all functions for each OpenGL version and
+ profile.
+
+ OpenGL implementations on different platforms are able to link to a variable
+ number of OpenGL functions depending upon the OpenGL ABI on that platform.
+ For example, on Microsoft Windows only functions up to those in OpenGL 1.1
+ can be linked to at build time. All other functions must be resolved at
+ runtime. The traditional solution to this has been to use either
+ QOpenGLContext::getProcAddress() or QOpenGLFunctions. The former is tedious
+ and error prone and means dealing directly with function pointers. The
+ latter only exposes those functions common to OpenGL ES 2 and desktop
+ OpenGL. There is however much new OpenGL functionality that is useful when
+ writing real world OpenGL applications.
+
+ Qt now provides a family of classes which all inherit from
+ QAbstractOpenGLFunctions which expose every core OpenGL function by way of a
+ corresponding member function. There is a class for every valid combination
+ of OpenGL version and profile. Each class follows the naming convention
+ QOpenGLFunctions_<MAJOR VERSION>_<MINOR VERSION>[_PROFILE].
+
+ For OpenGL versions 1.0 through to 3.0 there are no profiles, leading to the
+ classes:
+
+ \list
+ \li QOpenGLFunctions_1_0
+ \li QOpenGLFunctions_1_1
+ \li QOpenGLFunctions_1_2
+ \li QOpenGLFunctions_1_3
+ \li QOpenGLFunctions_1_4
+ \li QOpenGLFunctions_1_5
+ \li QOpenGLFunctions_2_0
+ \li QOpenGLFunctions_2_1
+ \li QOpenGLFunctions_3_0
+ \endlist
+
+ where each class inherits from QAbstractOpenGLFunctions.
+
+ OpenGL version 3.1 removed many deprecated functions leading to a much
+ simpler and generic API.
+
+ With OpenGL 3.2 the concept of profiles was introduced. Two profiles are
+ currently defined for OpenGL: Core and Compatibility.
+
+ The Core profile does not include any of the functions that were removed
+ in OpenGL 3.1. The Compatibility profile contains all functions in the
+ Core profile of the same version plus all of the functions that were
+ removed in OpenGL 3.1. In this way the Compatibility profile classes allow
+ use of newer OpenGL functionality but also allows you to keep using your
+ legacy OpenGL code. For new OpenGL code the Core profile should be
+ preferred.
+
+ Please note that some vendors, notably Apple, do not implement the
+ Compatibility profile. Therefore if you wish to target new OpenGL features
+ on OS X then you should ensure that you request a Core profile context via
+ QSurfaceFormat::setProfile().
+
+ Qt provides classes for all version and Core and Compatibility profile
+ combinations. The classes for OpenGL versions 3.1 through to 4.3 are:
+
+ \list
+ \li QOpenGLFunctions_3_1
+ \li QOpenGLFunctions_3_2_Core
+ \li QOpenGLFunctions_3_2_Compatibility
+ \li QOpenGLFunctions_3_3_Core
+ \li QOpenGLFunctions_3_3_Compatibility
+ \li QOpenGLFunctions_4_0_Core
+ \li QOpenGLFunctions_4_0_Compatibility
+ \li QOpenGLFunctions_4_1_Core
+ \li QOpenGLFunctions_4_1_Compatibility
+ \li QOpenGLFunctions_4_2_Core
+ \li QOpenGLFunctions_4_2_Compatibility
+ \li QOpenGLFunctions_4_3_Core
+ \li QOpenGLFunctions_4_3_Compatibility
+ \endlist
+
+ where each class inherits from QAbstractOpenGLFunctions.
+
+ A pointer to an object of the class corresponding to the version and
+ profile of OpenGL in use can be obtained from
+ QOpenGLFunctions::versionFunctions(). If obtained in this way, note that
+ the QOpenGLContext retains ownership of the object. This is so that only
+ one instance need be created.
+
+ Before calling any of the exposed OpenGL functions you must ensure that the
+ object has resolved the function pointers to the OpenGL functions. This
+ only needs to be done once per instance with initializeOpenGLFunctions().
+ Once initialized, the object can be used to call any OpenGL function for
+ the corresponding version and profile. Note that initializeOpenGLFunctions()
+ can fail in some circumstances so check the return value. Situations in
+ which initialization can fail are if you have a functions object for a version
+ or profile that contains functions that are not part of the context being
+ used to resolve the function pointers.
+
+ If you exclusively use function objects then you will get compile time
+ errors if you attempt to use a function not included in that version and
+ profile. This is obviously a lot easier to debug than undefined behavior
+ at run time.
+
+ \sa QOpenGLContext::versionFunctions()
+*/
+QAbstractOpenGLFunctions::QAbstractOpenGLFunctions()
+ : d_ptr(new QAbstractOpenGLFunctionsPrivate)
+{
+}
+
+QAbstractOpenGLFunctions::~QAbstractOpenGLFunctions()
+{
+ delete d_ptr;
+}
+
+bool QAbstractOpenGLFunctions::initializeOpenGLFunctions()
+{
+ Q_D(QAbstractOpenGLFunctions);
+ d->initialized = true;
+ return true;
+}
+
+bool QAbstractOpenGLFunctions::isInitialized() const
+{
+ Q_D(const QAbstractOpenGLFunctions);
+ return d->initialized;
+}
+
+void QAbstractOpenGLFunctions::setOwningContext(const QOpenGLContext *context)
+{
+ Q_D(QAbstractOpenGLFunctions);
+ d->owningContext = const_cast<QOpenGLContext*>(context);
+}
+
+QOpenGLContext *QAbstractOpenGLFunctions::owningContext() const
+{
+ Q_D(const QAbstractOpenGLFunctions);
+ return d->owningContext;
+}
+
+#if !defined(QT_OPENGL_ES_2)
+
diff --git a/util/glgen/qopenglversionfunctions.h.footer b/util/glgen/qopenglversionfunctions.h.footer
new file mode 100644
index 0000000000..dc29c75177
--- /dev/null
+++ b/util/glgen/qopenglversionfunctions.h.footer
@@ -0,0 +1,13 @@
+
+#else
+
+// No need for backend classes with function pointers with ES2.
+// All function addresses are independent of context and display.
+
+#endif // !QT_OPENGL_ES_2
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL
+
+#endif
diff --git a/util/glgen/qopenglversionfunctions.h.header b/util/glgen/qopenglversionfunctions.h.header
new file mode 100644
index 0000000000..69cdaf3728
--- /dev/null
+++ b/util/glgen/qopenglversionfunctions.h.header
@@ -0,0 +1,164 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS_H
+#define QOPENGLVERSIONFUNCTIONS_H
+
+#include <QtCore/qglobal.h>
+
+#ifndef QT_NO_OPENGL
+
+#include <QtCore/qhash.h>
+#include <QtCore/qpair.h>
+#include <QtGui/qopengl.h>
+
+QT_BEGIN_NAMESPACE
+
+class QOpenGLContext;
+
+#if 0
+// silence syncqt warnings
+#pragma qt_class(QOpenGLVersionFunctions)
+#pragma qt_sync_stop_processing
+#endif
+
+struct QOpenGLVersionStatus
+{
+ enum OpenGLStatus {
+ CoreStatus,
+ DeprecatedStatus,
+ InvalidStatus
+ };
+
+ QOpenGLVersionStatus()
+ : version(qMakePair(0, 0)),
+ status(InvalidStatus)
+ {}
+
+ QOpenGLVersionStatus(int majorVersion, int minorVersion, QOpenGLVersionStatus::OpenGLStatus functionStatus)
+ : version(qMakePair(majorVersion, minorVersion)),
+ status(functionStatus)
+ {}
+
+ QPair<int, int> version;
+ OpenGLStatus status;
+};
+
+inline uint qHash(const QOpenGLVersionStatus &v, uint seed)
+{
+ return qHash(static_cast<int>(v.status * 1000)
+ + v.version.first * 100 + v.version.second * 10, seed);
+}
+
+inline bool operator==(const QOpenGLVersionStatus &lhs, const QOpenGLVersionStatus &rhs)
+{
+ if (lhs.status != rhs.status)
+ return false;
+ return lhs.version == rhs.version;
+}
+
+inline bool operator!=(const QOpenGLVersionStatus &lhs, const QOpenGLVersionStatus &rhs)
+{
+ return !operator==(lhs, rhs);
+}
+
+class QOpenGLVersionFunctionsBackend
+{
+public:
+ QOpenGLVersionFunctionsBackend(QOpenGLContext *ctx)
+ : context(ctx)
+ {}
+
+ QOpenGLContext *context;
+ QAtomicInt refs;
+};
+
+class QAbstractOpenGLFunctionsPrivate
+{
+public:
+ QAbstractOpenGLFunctionsPrivate()
+ : owningContext(0),
+ initialized(false)
+ {}
+
+ static QOpenGLVersionFunctionsBackend *functionsBackend(QOpenGLContext *context,
+ const QOpenGLVersionStatus &v);
+ static void insertFunctionsBackend(QOpenGLContext *context,
+ const QOpenGLVersionStatus &v,
+ QOpenGLVersionFunctionsBackend *backend);
+ static void removeFunctionsBackend(QOpenGLContext *context, const QOpenGLVersionStatus &v);
+
+ QOpenGLContext *owningContext;
+ bool initialized;
+};
+
+class QAbstractOpenGLFunctions
+{
+public:
+ virtual ~QAbstractOpenGLFunctions();
+
+ virtual bool initializeOpenGLFunctions();
+
+ Q_DECLARE_PRIVATE(QAbstractOpenGLFunctions)
+
+protected:
+ QAbstractOpenGLFunctions();
+ QAbstractOpenGLFunctionsPrivate *d_ptr;
+
+ bool isInitialized() const;
+
+ void setOwningContext(const QOpenGLContext *context);
+ QOpenGLContext *owningContext() const;
+
+ friend class QOpenGLContext;
+};
+
+#if !defined(QT_OPENGL_ES_2)
+
diff --git a/util/glgen/qopenglversionfunctions__VERSION__.cpp.footer b/util/glgen/qopenglversionfunctions__VERSION__.cpp.footer
new file mode 100644
index 0000000000..b81ea7b6ea
--- /dev/null
+++ b/util/glgen/qopenglversionfunctions__VERSION__.cpp.footer
@@ -0,0 +1,2 @@
+
+QT_END_NAMESPACE
diff --git a/util/glgen/qopenglversionfunctions__VERSION__.cpp.header b/util/glgen/qopenglversionfunctions__VERSION__.cpp.header
new file mode 100644
index 0000000000..f92c0dd3fd
--- /dev/null
+++ b/util/glgen/qopenglversionfunctions__VERSION__.cpp.header
@@ -0,0 +1,55 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglfunctions__VERSION__.h"
+#include "qopenglcontext.h"
+
+QT_BEGIN_NAMESPACE
+
diff --git a/util/glgen/qopenglversionfunctions__VERSION__.h.footer b/util/glgen/qopenglversionfunctions__VERSION__.h.footer
new file mode 100644
index 0000000000..b81155c102
--- /dev/null
+++ b/util/glgen/qopenglversionfunctions__VERSION__.h.footer
@@ -0,0 +1,6 @@
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL && !QT_OPENGL_ES_2
+
+#endif
diff --git a/util/glgen/qopenglversionfunctions__VERSION__.h.header b/util/glgen/qopenglversionfunctions__VERSION__.h.header
new file mode 100644
index 0000000000..4b30dc1b65
--- /dev/null
+++ b/util/glgen/qopenglversionfunctions__VERSION__.h.header
@@ -0,0 +1,62 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONS__VERSION___H
+#define QOPENGLVERSIONFUNCTIONS__VERSION___H
+
+#include <QtCore/qglobal.h>
+
+#if !defined(QT_NO_OPENGL) && !defined(QT_OPENGL_ES_2)
+
+#include <QtGui/QOpenGLVersionFunctions>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
diff --git a/util/glgen/qopenglversionfunctionsfactory.cpp.footer b/util/glgen/qopenglversionfunctionsfactory.cpp.footer
new file mode 100644
index 0000000000..b81ea7b6ea
--- /dev/null
+++ b/util/glgen/qopenglversionfunctionsfactory.cpp.footer
@@ -0,0 +1,2 @@
+
+QT_END_NAMESPACE
diff --git a/util/glgen/qopenglversionfunctionsfactory.cpp.header b/util/glgen/qopenglversionfunctionsfactory.cpp.header
new file mode 100644
index 0000000000..6be93102dc
--- /dev/null
+++ b/util/glgen/qopenglversionfunctionsfactory.cpp.header
@@ -0,0 +1,52 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#include "qopenglversionfunctionsfactory_p.h"
+
diff --git a/util/glgen/qopenglversionfunctionsfactory_p.h.header b/util/glgen/qopenglversionfunctionsfactory_p.h.header
new file mode 100644
index 0000000000..2312e900f9
--- /dev/null
+++ b/util/glgen/qopenglversionfunctionsfactory_p.h.header
@@ -0,0 +1,73 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the QtGui module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+**
+** This file was generated by glgen version 0.1
+** Command line was: glgen
+**
+** glgen is Copyright (C) 2012 Klaralvdalens Datakonsult AB (KDAB)
+**
+** This is an auto-generated file.
+** Do not edit! All changes made to it will be lost.
+**
+****************************************************************************/
+
+#ifndef QOPENGLVERSIONFUNCTIONFACTORY_P_H
+#define QOPENGLVERSIONFUNCTIONFACTORY_P_H
+
+#ifndef QT_NO_OPENGL
+
+#include <QtCore/QtGlobal>
+#include <QtGui/qopenglcontext.h>
+
+QT_BEGIN_NAMESPACE
+
+class QAbstractOpenGLFunctions;
+
+class QOpenGLVersionFunctionsFactory
+{
+public:
+ static QAbstractOpenGLFunctions *create(const QOpenGLVersionProfile &versionProfile);
+};
+
+QT_END_NAMESPACE
+
+#endif // QT_NO_OPENGL
+
+#endif
diff --git a/util/glgen/specparser.cpp b/util/glgen/specparser.cpp
new file mode 100644
index 0000000000..91a906bca9
--- /dev/null
+++ b/util/glgen/specparser.cpp
@@ -0,0 +1,312 @@
+/***************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the utilities of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "specparser.h"
+
+#include <QDebug>
+#include <QFile>
+#include <QRegExp>
+#include <QStringList>
+#include <QTextStream>
+
+#ifdef SPECPARSER_DEBUG
+#define qSpecParserDebug qDebug
+#else
+#define qSpecParserDebug QT_NO_QDEBUG_MACRO
+#endif
+
+SpecParser::SpecParser()
+{
+}
+
+void SpecParser::parse()
+{
+ // Get the mapping form generic types to specific types suitable for use in C-headers
+ if (!parseTypeMap())
+ return;
+
+ // Open up a stream on the actual OpenGL function spec file
+ QFile file(m_specFileName);
+ if (!file.open(QIODevice::ReadOnly | QIODevice::Text)) {
+ qWarning() << "Failed to open spec file:" << m_specFileName << "Aborting";
+ return;
+ }
+
+ QTextStream stream(&file);
+
+ // Extract the info that we need
+ parseFunctions(stream);
+}
+
+bool SpecParser::parseTypeMap()
+{
+ QFile file(m_typeMapFileName);
+ if (!file.open(QIODevice::ReadOnly | QIODevice::Text)) {
+ qWarning() << "Failed to open spec file:" << m_specFileName << "Aborting";
+ return false;
+ }
+
+ QTextStream stream(&file);
+
+ static QRegExp typeMapRegExp("([^,]+)\\W+([^,]+)");
+
+ while (!stream.atEnd()) {
+ QString line = stream.readLine();
+
+ if (line.startsWith(QStringLiteral("#")))
+ continue;
+
+ if (typeMapRegExp.indexIn(line) != -1) {
+ QString key = typeMapRegExp.cap(1).simplified();
+ QString value = typeMapRegExp.cap(2).simplified();
+
+ // Special case for void
+ if (value == QStringLiteral("*"))
+ value = QStringLiteral("void");
+
+ m_typeMap.insert(key, value);
+ qSpecParserDebug() << "Found type mapping from" << key << "=>" << value;
+ }
+ }
+
+ return true;
+}
+
+void SpecParser::parseEnums()
+{
+}
+
+void SpecParser::parseFunctions(QTextStream &stream)
+{
+ static QRegExp functionRegExp("^(\\w+)\\(.*\\)");
+ static QRegExp returnRegExp("^\\treturn\\s+(\\S+)");
+ static QRegExp argumentRegExp("param\\s+(\\S+)\\s+(\\S+) (\\S+) (\\S+)");
+ static QRegExp versionRegExp("^\\tversion\\s+(\\S+)");
+ static QRegExp deprecatedRegExp("^\\tdeprecated\\s+(\\S+)");
+ static QRegExp categoryRegExp("^\\tcategory\\s+(\\S+)");
+ static QRegExp categoryVersionRegExp("VERSION_(\\d)_(\\d)");
+ static QRegExp extToCoreVersionRegExp("passthru:\\s/\\*\\sOpenGL\\s(\\d)\\.(\\d)\\s.*\\sextensions:");
+ static QRegExp extToCoreRegExp("passthru:\\s/\\*\\s(ARB_\\S*)\\s.*\\*/");
+
+ Function currentFunction;
+ VersionProfile currentVersionProfile;
+ QString currentCategory;
+ bool haveVersionInfo = false;
+ bool acceptCurrentFunctionInCore = false;
+ bool acceptCurrentFunctionInExtension = false;
+
+ QHash<QString, Version> extensionsNowInCore;
+ Version extToCoreCurrentVersion;
+ int functionCount = 0;
+
+ QSet<Version> versions;
+
+ while (!stream.atEnd()) {
+ QString line = stream.readLine();
+ if (line.startsWith("#"))
+ continue;
+
+ if (functionRegExp.indexIn(line) != -1) {
+
+ if (!currentFunction.name.isEmpty()) {
+
+ // NB - Special handling!
+ // Versions 4.2 and 4.3 (and probably newer) add functionality by
+ // subsuming extensions such as ARB_texture_storage. However, some extensions
+ // also include functions to interact with the EXT_direct_state_access
+ // extension. These functions should be added to the DSA extension rather
+ // than the core functionality. The core will already contain non-DSA
+ // versions of these functions.
+ if (acceptCurrentFunctionInCore && currentFunction.name.endsWith(QStringLiteral("EXT"))) {
+ acceptCurrentFunctionInCore = false;
+ acceptCurrentFunctionInExtension = true;
+ currentCategory = QStringLiteral("EXT_direct_state_access");
+ }
+
+ // Finish off previous function (if any) by inserting it into the core
+ // functionality or extension functionality (or both)
+ if (acceptCurrentFunctionInCore) {
+ m_functions.insert(currentVersionProfile, currentFunction);
+ versions.insert(currentVersionProfile.version);
+ }
+
+ if (acceptCurrentFunctionInExtension)
+ m_extensionFunctions.insert(currentCategory, currentFunction);
+ }
+
+ // Start a new function
+ ++functionCount;
+ haveVersionInfo = false;
+ acceptCurrentFunctionInCore = true;
+ acceptCurrentFunctionInExtension = false;
+ currentCategory = QString();
+ currentFunction = Function();
+
+ // We assume a core function unless we find a deprecated flag (see below)
+ currentVersionProfile = VersionProfile();
+ currentVersionProfile.profile = VersionProfile::CoreProfile;
+
+ // Extract the function name
+ QString functionName = functionRegExp.cap(1);
+ currentFunction.name = functionName;
+ qSpecParserDebug() << "Found function:" << functionName;
+
+ } else if (argumentRegExp.indexIn(line) != -1) {
+ // Extract info about this function argument
+ Argument arg;
+ arg.name = argumentRegExp.cap(1);
+
+ QString type = argumentRegExp.cap(2); // Lookup in type map
+ arg.type = m_typeMap.value(type);
+
+ QString direction = argumentRegExp.cap(3);
+ if (direction == QStringLiteral("in")) {
+ arg.direction = Argument::In;
+ } else if (direction == QStringLiteral("out")) {
+ arg.direction = Argument::Out;
+ } else {
+ qWarning() << "Invalid argument direction found:" << direction;
+ acceptCurrentFunctionInCore = false;
+ }
+
+ QString mode = argumentRegExp.cap(4);
+ if (mode == QStringLiteral("value")) {
+ arg.mode = Argument::Value;
+ } else if (mode == QStringLiteral("array")) {
+ arg.mode = Argument::Array;
+ } else if (mode == QStringLiteral("reference")) {
+ arg.mode = Argument::Reference;
+ } else {
+ qWarning() << "Invalid argument mode found:" << mode;
+ acceptCurrentFunctionInCore = false;
+ }
+
+ qSpecParserDebug() << " argument:" << arg.type << arg.name;
+ currentFunction.arguments.append(arg);
+
+ } else if (returnRegExp.indexIn(line) != -1) {
+ // Lookup the return type from the typemap
+ QString returnTypeKey = returnRegExp.cap(1).simplified();
+ if (!m_typeMap.contains(returnTypeKey)) {
+ qWarning() << "Unknown return type found:" << returnTypeKey;
+ acceptCurrentFunctionInCore = false;
+ }
+ QString returnType = m_typeMap.value(returnTypeKey);
+ qSpecParserDebug() << " return type:" << returnType;
+ currentFunction.returnType = returnType;
+
+ } else if (versionRegExp.indexIn(line) != -1 && !haveVersionInfo) { // Only use version line if no other source
+ // Extract the OpenGL version in which this function was introduced
+ QString version = versionRegExp.cap(1);
+ qSpecParserDebug() << " version:" << version;
+ QStringList parts = version.split(QLatin1Char('.'));
+ if (parts.size() != 2) {
+ qWarning() << "Found invalid version number";
+ continue;
+ }
+ int majorVersion = parts.first().toInt();
+ int minorVersion = parts.last().toInt();
+ Version v;
+ v.major = majorVersion;
+ v.minor = minorVersion;
+ currentVersionProfile.version = v;
+
+ } else if (deprecatedRegExp.indexIn(line) != -1) {
+ // Extract the OpenGL version in which this function was deprecated.
+ // If it is OpenGL 3.1 then it must be a compatibility profile function
+ QString deprecatedVersion = deprecatedRegExp.cap(1).simplified();
+ if (deprecatedVersion == QStringLiteral("3.1") && !inDeprecationException(currentFunction.name))
+ currentVersionProfile.profile = VersionProfile::CompatibilityProfile;
+
+ } else if (categoryRegExp.indexIn(line) != -1) {
+ // Extract the category for this function
+ QString category = categoryRegExp.cap(1).simplified();
+ qSpecParserDebug() << " category:" << category;
+
+ if (categoryVersionRegExp.indexIn(category) != -1) {
+ // Use the version info in the category in preference to the version
+ // entry as this is more applicable and consistent
+ int majorVersion = categoryVersionRegExp.cap(1).toInt();
+ int minorVersion = categoryVersionRegExp.cap(2).toInt();
+
+ Version v;
+ v.major = majorVersion;
+ v.minor = minorVersion;
+ currentVersionProfile.version = v;
+ haveVersionInfo = true;
+
+ } else {
+ // Make a note of the extension name and tag this function as being part of an extension
+ qSpecParserDebug() << "Found category =" << category;
+ currentCategory = category;
+ acceptCurrentFunctionInExtension = true;
+
+ // See if this category (extension) is in our set of extensions that
+ // have now been folded into the core feature set
+ if (extensionsNowInCore.contains(category)) {
+ currentVersionProfile.version = extensionsNowInCore.value(category);
+ haveVersionInfo = true;
+ } else {
+ acceptCurrentFunctionInCore = false;
+ }
+ }
+
+ } else if (extToCoreVersionRegExp.indexIn(line) != -1) {
+ qSpecParserDebug() << line;
+ int majorVersion = extToCoreVersionRegExp.cap(1).toInt();
+ int minorVersion = extToCoreVersionRegExp.cap(2).toInt();
+ extToCoreCurrentVersion.major = majorVersion;
+ extToCoreCurrentVersion.minor = minorVersion;
+
+ } else if (extToCoreRegExp.indexIn(line) != -1) {
+ QString extension = extToCoreRegExp.cap(1);
+ extensionsNowInCore.insert(extension, extToCoreCurrentVersion);
+ }
+ }
+
+ m_versions = versions.toList();
+ qSort(m_versions);
+}
+
+bool SpecParser::inDeprecationException(const QString &functionName) const
+{
+ return (functionName == QStringLiteral("TexImage3D"));
+}
diff --git a/util/glgen/specparser.h b/util/glgen/specparser.h
new file mode 100644
index 0000000000..19357841ca
--- /dev/null
+++ b/util/glgen/specparser.h
@@ -0,0 +1,210 @@
+/***************************************************************************
+**
+** Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB)
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the utilities of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** Commercial License Usage
+** Licensees holding valid commercial Qt licenses may use this file in
+** accordance with the commercial license agreement provided with the
+** Software or, alternatively, in accordance with the terms contained in
+** a written agreement between you and Digia. For licensing terms and
+** conditions see http://qt.digia.com/licensing. For further information
+** use the contact form at http://qt.digia.com/contact-us.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Digia gives you certain additional
+** rights. These rights are described in the Digia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#ifndef SPECPARSER_H
+#define SPECPARSER_H
+
+#include <QStringList>
+#include <QVariant>
+
+class QTextStream;
+
+struct Version {
+ int major;
+ int minor;
+};
+
+inline bool operator == (const Version &lhs, const Version &rhs)
+{
+ return (lhs.major == rhs.major && lhs.minor == rhs.minor);
+}
+
+inline bool operator < (const Version &lhs, const Version &rhs)
+{
+ if (lhs.major != rhs.major)
+ return (lhs.major < rhs.major);
+ else
+ return (lhs.minor < rhs.minor);
+}
+
+inline bool operator > (const Version &lhs, const Version &rhs)
+{
+ if (lhs.major != rhs.major)
+ return (lhs.major > rhs.major);
+ else
+ return (lhs.minor > rhs.minor);
+}
+
+inline uint qHash(const Version &v)
+{
+ return qHash(v.major * 100 + v.minor * 10);
+}
+
+struct VersionProfile
+{
+ enum OpenGLProfile {
+ CoreProfile = 0,
+ CompatibilityProfile
+ };
+
+ inline bool hasProfiles() const
+ {
+ return ( version.major > 3
+ || (version.major == 3 && version.minor > 1));
+ }
+
+ Version version;
+ OpenGLProfile profile;
+};
+
+inline bool operator == (const VersionProfile &lhs, const VersionProfile &rhs)
+{
+ if (lhs.profile != rhs.profile)
+ return false;
+ return lhs.version == rhs.version;
+}
+
+inline bool operator < (const VersionProfile &lhs, const VersionProfile &rhs)
+{
+ if (lhs.profile != rhs.profile)
+ return (lhs.profile < rhs.profile);
+ return (lhs.version < rhs.version);
+}
+
+inline uint qHash(const VersionProfile &v)
+{
+ return qHash(static_cast<int>(v.profile * 1000) + v.version.major * 100 + v.version.minor * 10);
+}
+
+struct Argument
+{
+ enum Direction {
+ In = 0,
+ Out
+ };
+
+ enum Mode {
+ Value = 0,
+ Array,
+ Reference
+ };
+
+ QString type;
+ QString name;
+ Direction direction;
+ Mode mode;
+};
+
+struct Function
+{
+ QString returnType;
+ QString name;
+ QList<Argument> arguments;
+};
+
+typedef QList<Function> FunctionList;
+typedef QMap<VersionProfile, FunctionList> FunctionCollection;
+
+class SpecParser
+{
+public:
+ explicit SpecParser();
+
+ QString specFileName() const
+ {
+ return m_specFileName;
+ }
+
+ QString typeMapFileName() const
+ {
+ return m_typeMapFileName;
+ }
+
+ QList<Version> versions() const {return m_versions;}
+ QList<VersionProfile> versionProfiles() const {return m_functions.uniqueKeys();}
+
+ QList<Function> functionsForVersion(const VersionProfile &v) const
+ {
+ return m_functions.values(v);
+ }
+
+ QStringList extensions() const
+ {
+ return QStringList(m_extensionFunctions.uniqueKeys());
+ }
+
+ QList<Function> functionsForExtension(const QString &extension)
+ {
+ return m_extensionFunctions.values(extension);
+ }
+
+ void setSpecFileName(QString arg)
+ {
+ m_specFileName = arg;
+ }
+
+ void setTypeMapFileName(QString arg)
+ {
+ m_typeMapFileName = arg;
+ }
+
+ void parse();
+
+protected:
+ bool parseTypeMap();
+ void parseEnums();
+ void parseFunctions(QTextStream &stream);
+ bool inDeprecationException(const QString &functionName) const;
+
+private:
+ QString m_specFileName;
+ QString m_typeMapFileName;
+
+ QMap<QString, QString> m_typeMap;
+ QMultiMap<VersionProfile, Function> m_functions;
+
+ QList<Version> m_versions;
+
+ // Extension support
+ QMultiMap<QString, Function> m_extensionFunctions;
+};
+
+#endif // SPECPARSER_H
diff --git a/util/lexgen/generator.cpp b/util/lexgen/generator.cpp
index a6fc93c0ca..06ba586c1f 100644
--- a/util/lexgen/generator.cpp
+++ b/util/lexgen/generator.cpp
@@ -48,7 +48,7 @@ void Function::printDeclaration(CodeBlock &block, const QString &funcNamePrefix)
block << (iline ? "inline " : "") << signature(funcNamePrefix) << (iline ? QLatin1String(" {") : QLatin1String(";"));
if (!iline)
return;
-
+
block.indent();
QString tmp = body;
if (tmp.endsWith(QLatin1Char('\n')))
@@ -81,7 +81,7 @@ QString Function::definition() const
QString result;
result += signature();
result += QLatin1String("\n{\n");
-
+
QString tmp = body;
if (tmp.endsWith(QLatin1Char('\n')))
@@ -92,7 +92,7 @@ QString Function::definition() const
tmp.replace(QLatin1Char('\n'), QLatin1String("\n "));
result += tmp;
-
+
result += QLatin1String("\n}\n");
return result;
@@ -102,16 +102,16 @@ void Class::Section::printDeclaration(const Class *klass, CodeBlock &block) cons
{
foreach (Function ctor, constructors)
ctor.printDeclaration(block, klass->name());
-
+
if (!constructors.isEmpty())
block.addNewLine();
-
+
foreach (Function func, functions)
func.printDeclaration(block);
-
+
if (!functions.isEmpty())
block.addNewLine();
-
+
foreach (QString var, variables)
block << var << ';';
}
@@ -133,13 +133,13 @@ void Class::addConstructor(Access access, const QString &body, const QString &_a
QString Class::Section::definition(const Class *klass) const
{
QString result;
-
+
foreach (Function ctor, constructors) {
ctor.setName(klass->name() + "::" + klass->name() + ctor.name());
result += ctor.definition();
result += QLatin1Char('\n');
}
-
+
foreach (Function func, functions) {
if (!func.hasBody()) continue;
func.setName(klass->name() + "::" + func.name());
@@ -153,10 +153,10 @@ QString Class::Section::definition(const Class *klass) const
QString Class::declaration() const
{
CodeBlock block;
-
+
block << QLatin1String("class ") << cname;
block << "{";
-
+
if (!sections[PublicMember].isEmpty()) {
block << "public:";
block.indent();
@@ -170,7 +170,7 @@ QString Class::declaration() const
sections[ProtectedMember].printDeclaration(this, block);
block.outdent();
}
-
+
if (!sections[PrivateMember].isEmpty()) {
block << "private:";
block.indent();
@@ -180,7 +180,7 @@ QString Class::declaration() const
block << "};";
block.addNewLine();
-
+
return block.toString();
}
@@ -406,12 +406,12 @@ void Generator::generateTransitions(CodeBlock &body, const TransitionMap &transi
QString Generator::generate()
{
Class klass(cfg.className);
-
+
klass.addMember(Class::PublicMember, "QString input");
klass.addMember(Class::PublicMember, "int pos");
klass.addMember(Class::PublicMember, "int lexemStart");
klass.addMember(Class::PublicMember, "int lexemLength");
-
+
{
CodeBlock body;
body << "input = inp;";
@@ -420,7 +420,7 @@ QString Generator::generate()
body << "lexemLength = 0;";
klass.addConstructor(Class::PublicMember, body, "const QString &inp");
}
-
+
{
Function next("QChar", "next()");
next.setInline(true);
@@ -430,7 +430,7 @@ QString Generator::generate()
next.addBody("return (pos < input.length()) ? input.at(pos++).toLower() : QChar();");
klass.addMember(Class::PublicMember, next);
}
-
+
/*
{
Function lexem("QString", "lexem()");
@@ -450,7 +450,7 @@ QString Generator::generate()
Function lexFunc;
lexFunc.setReturnType("int");
lexFunc.setName("lex()");
-
+
CodeBlock body;
body << "lexemStart = pos;";
body << "lexemLength = 0;";
@@ -487,14 +487,14 @@ QString Generator::generate()
body.outdent();
body.indent();
-
+
if (!dfa.at(i).transitions.isEmpty()) {
body << "ch = next();";
generateTransitions(body, dfa.at(i).transitions);
}
-
+
body << "goto out;";
-
+
body.outdent();
}
@@ -512,9 +512,9 @@ QString Generator::generate()
body.outdent();
body << "}";
body << "return token;";
-
+
lexFunc.addBody(body);
-
+
klass.addMember(Class::PublicMember, lexFunc);
QString header;
@@ -526,7 +526,7 @@ QString Generator::generate()
}
header += QLatin1String("// auto generated. DO NOT EDIT.\n");
-
+
return header + klass.declaration() + klass.definition();
}
diff --git a/util/lexgen/generator.h b/util/lexgen/generator.h
index 7037f13018..c56ee20756 100644
--- a/util/lexgen/generator.h
+++ b/util/lexgen/generator.h
@@ -82,11 +82,11 @@ public:
delete shared;
}
}
-
+
template <typename T>
LineStream &operator<<(const T &value)
{ (*shared->stream) << value; return *this; }
-
+
SharedStream *shared;
};
@@ -101,11 +101,11 @@ public:
template <typename T>
LineStream operator<<(const T &value)
{ stream << indentStr; stream << value; return LineStream(&stream); }
-
+
inline void addNewLine() { stream << endl; }
-
+
inline QString toString() const { stream.flush(); return output; }
-
+
private:
QString output;
mutable QTextStream stream;
@@ -121,20 +121,20 @@ public:
inline void setName(const QString &name) { fname = name; }
inline QString name() const { return fname; }
-
+
inline void setInline(bool i) { iline = i; }
inline bool isInline() const { return iline; }
-
+
inline void setReturnType(const QString &type) { rtype = type; }
inline QString returnType() const { return rtype; }
-
+
inline void addBody(const QString &_body) { body += _body; }
inline void addBody(const CodeBlock &block) { body += block.toString(); }
inline bool hasBody() const { return !body.isEmpty(); }
-
+
inline void setConst(bool konst) { cnst = konst; }
inline bool isConst() const { return cnst; }
-
+
void printDeclaration(CodeBlock &block, const QString &funcNamePrefix = QString()) const;
QString definition() const;
@@ -157,19 +157,19 @@ public:
inline void setName(const QString &name) { cname = name; }
inline QString name() const { return cname; }
-
+
inline void addMember(Access access, const QString &name)
{ sections[access].variables.append(name); }
inline void addMember(Access access, const Function &func)
{ sections[access].functions.append(func); }
-
+
void addConstructor(Access access, const QString &body, const QString &args = QString());
inline void addConstructor(Access access, const CodeBlock &body, const QString &args = QString())
{ addConstructor(access, body.toString(), args); }
-
+
QString declaration() const;
QString definition() const;
-
+
private:
QString cname;
struct Section
@@ -177,10 +177,10 @@ private:
QVector<Function> functions;
QStringList variables;
QVector<Function> constructors;
-
+
inline bool isEmpty() const
{ return functions.isEmpty() && variables.isEmpty() && constructors.isEmpty(); }
-
+
void printDeclaration(const Class *klass, CodeBlock &block) const;
QString definition(const Class *klass) const;
};
@@ -192,9 +192,9 @@ class Generator
{
public:
Generator(const DFA &dfa, const Config &config);
-
+
QString generate();
-
+
private:
void generateTransitions(CodeBlock &body, const TransitionMap &transitions);
bool isSingleReferencedFinalState(int i) const;
diff --git a/util/lexgen/main.cpp b/util/lexgen/main.cpp
index 7fdf587ae9..a6cd6ee94f 100644
--- a/util/lexgen/main.cpp
+++ b/util/lexgen/main.cpp
@@ -149,7 +149,7 @@ static QSet<InputType> determineMaxInputSet(const ConfigFile::Section &section)
if (inputTypeName == "quint8") {
for (int i = 1; i < 256; ++i)
set.insert(i);
- } /* else if ### */
+ } /* else if ### */
else {
qWarning("Error: Unknown input type '%s'", qPrintable(inputTypeName));
return QSet<InputType>();
@@ -313,7 +313,7 @@ int main(int argc, char **argv)
qDebug() << "Error while tokenizing!";
} else {
Generator gen(machine, cfg);
- QTextStream(stdout)
+ QTextStream(stdout)
<< gen.generate();
}
diff --git a/util/lexgen/nfa.cpp b/util/lexgen/nfa.cpp
index 5ae3beade5..1414d1eedd 100644
--- a/util/lexgen/nfa.cpp
+++ b/util/lexgen/nfa.cpp
@@ -288,7 +288,6 @@ DFA NFA::toDFA() const
if (transition.key() == Epsilon && epsilonStates.contains(transition.value()))
epsilonStates.insert(i, epsilonStates.value(transition.value()));
}
-
} while (lastCount != epsilonStates.count());
for (int i = 0; i < states.count(); ++i) {
@@ -313,7 +312,6 @@ DFA NFA::toDFA() const
*/
}
-
QSet<InputType> validInput;
foreach (const State &s, states)
for (TransitionMap::ConstIterator it = s.transitions.constBegin(),
@@ -504,5 +502,3 @@ DFA DFA::minimize() const
return *this;
}
-
-
diff --git a/util/lexgen/nfa.h b/util/lexgen/nfa.h
index 3eae9bcef8..0d8394a926 100644
--- a/util/lexgen/nfa.h
+++ b/util/lexgen/nfa.h
@@ -92,7 +92,7 @@ public:
static NFA applyQuantity(const NFA &a, int minOccurrences, int maxOccurrences);
void setTerminationSymbol(const QString &symbol);
-
+
DFA toDFA() const;
inline bool isEmpty() const { return states.isEmpty(); }
@@ -113,7 +113,7 @@ private:
inline void assertValidState(int state)
{ Q_UNUSED(state); Q_ASSERT(state >= 0); Q_ASSERT(state < states.count()); }
-
+
#if defined(AUTOTEST)
public:
#endif
diff --git a/util/lexgen/tests/tst_lexgen.cpp b/util/lexgen/tests/tst_lexgen.cpp
index a3741d2373..f45d295633 100644
--- a/util/lexgen/tests/tst_lexgen.cpp
+++ b/util/lexgen/tests/tst_lexgen.cpp
@@ -227,7 +227,7 @@ void tst_LexGen::lexgen_data()
d.cd("testdata");
foreach (QString test, d.entryList(QDir::Dirs | QDir::NoDotAndDotDot)) {
QString dir = d.absoluteFilePath(test) + '/';
- QTest::newRow(qPrintable(test))
+ QTest::newRow(qPrintable(test))
<< dir + "rules.lexgen"
<< dir + "input"
<< dir + "output"
diff --git a/util/local_database/enumdata.py b/util/local_database/enumdata.py
index 7d802e7492..b5935ca45f 100644
--- a/util/local_database/enumdata.py
+++ b/util/local_database/enumdata.py
@@ -173,7 +173,7 @@ language_list = {
125 : [ "Turkish", "tr" ],
126 : [ "Turkmen", "tk" ],
127 : [ "Tahitian", "ty" ],
- 128 : [ "Uigur", "ug" ],
+ 128 : [ "Uighur", "ug" ],
129 : [ "Ukrainian", "uk" ],
130 : [ "Urdu", "ur" ],
131 : [ "Uzbek", "uz" ], # macrolanguage
@@ -305,7 +305,58 @@ language_list = {
257 : [ "Ngomba", "jgo" ],
258 : [ "Kako", "kkj" ],
259 : [ "Meta", "mgo" ],
- 260 : [ "Ngiemboon", "nnh" ]
+ 260 : [ "Ngiemboon", "nnh" ],
+ 261 : [ "Aragonese", "an" ],
+ 262 : [ "Akkadian", "akk" ],
+ 263 : [ "AncientEgyptian", "egy" ],
+ 264 : [ "AncientGreek", "grc" ],
+ 265 : [ "Aramaic", "arc" ],
+ 266 : [ "Balinese", "ban" ],
+ 267 : [ "Bamun", "bax" ],
+ 268 : [ "BatakToba", "bbc" ],
+ 269 : [ "Buginese", "bug" ],
+ 270 : [ "Buhid", "bku" ],
+ 271 : [ "Carian", "xcr" ],
+ 272 : [ "Chakma", "ccp" ],
+ 273 : [ "ClassicalMandaic", "myz" ],
+ 274 : [ "Coptic", "cop" ],
+ 275 : [ "Dogri", "doi" ], # macrolanguage
+ 276 : [ "EasternCham", "cjm" ],
+ 277 : [ "EasternKayah", "eky" ],
+ 278 : [ "Etruscan", "ett" ],
+ 279 : [ "Gothic", "got" ],
+ 280 : [ "Hanunoo", "hnn" ],
+ 281 : [ "Ingush", "inh" ],
+ 282 : [ "LargeFloweryMiao", "hmd" ],
+ 283 : [ "Lepcha", "lep" ],
+ 284 : [ "Limbu", "lif" ],
+ 285 : [ "Lisu", "lis" ],
+ 286 : [ "Lu", "khb" ],
+ 287 : [ "Lycian", "xlc" ],
+ 288 : [ "Lydian", "xld" ],
+ 289 : [ "Mandingo", "man" ], # macrolanguage
+ 290 : [ "Manipuri", "mni" ],
+ 291 : [ "Meroitic", "xmr" ],
+ 292 : [ "NorthernThai", "nod" ],
+ 293 : [ "OldIrish", "sga" ],
+ 294 : [ "OldNorse", "non" ],
+ 295 : [ "OldPersian", "peo" ],
+ 296 : [ "OldTurkish", "otk" ],
+ 297 : [ "Pahlavi", "pal" ],
+ 298 : [ "Parthian", "xpr" ],
+ 299 : [ "Phoenician", "phn" ],
+ 300 : [ "PrakritLanguage", "pra" ],
+ 301 : [ "Rejang", "rej" ],
+ 302 : [ "Sabaean", "xsa" ],
+ 303 : [ "Samaritan", "smp" ],
+ 304 : [ "Santali", "sat" ],
+ 305 : [ "Saurashtra", "saz" ],
+ 306 : [ "Sora", "srb" ],
+ 307 : [ "Sylheti", "syl" ],
+ 308 : [ "Tagbanwa", "tbw" ],
+ 309 : [ "TaiDam", "blt" ],
+ 310 : [ "TaiNua", "tdd" ],
+ 311 : [ "Ugaritic", "uga" ]
}
country_list = {
@@ -602,9 +653,84 @@ script_list = {
30 : [ "Thai", "Thai" ],
31 : [ "Tibetan", "Tibt" ],
32 : [ "Sinhala", "Sinh" ],
- 33 : [ "Syriac", "Syri" ],
+ 33 : [ "Syriac", "Syrc" ],
34 : [ "Yi", "Yiii" ],
- 35 : [ "Vai", "Vaii" ]
+ 35 : [ "Vai", "Vaii" ],
+ 36 : [ "Avestan", "Avst" ],
+ 37 : [ "Balinese", "Bali" ],
+ 38 : [ "Bamum", "Bamu" ],
+ 39 : [ "Batak", "Batk" ],
+ 40 : [ "Bopomofo", "Bopo" ],
+ 41 : [ "Brahmi", "Brah" ],
+ 42 : [ "Buginese", "Bugi" ],
+ 43 : [ "Buhid", "Buhd" ],
+ 44 : [ "CanadianAboriginal", "Cans" ],
+ 45 : [ "Carian", "Cari" ],
+ 46 : [ "Chakma", "Cakm" ],
+ 47 : [ "Cham", "Cham" ],
+ 48 : [ "Coptic", "Copt" ],
+ 49 : [ "Cypriot", "Cprt" ],
+ 50 : [ "Egyptian Hieroglyphs", "Egyp" ],
+ 51 : [ "Fraser", "Lisu" ],
+ 52 : [ "Glagolitic", "Glag" ],
+ 53 : [ "Gothic", "Goth" ],
+ 54 : [ "Han", "Hani" ],
+ 55 : [ "Hangul", "Hang" ],
+ 56 : [ "Hanunoo", "Hano" ],
+ 57 : [ "Imperial Aramaic", "Armi" ],
+ 58 : [ "Inscriptional Pahlavi", "Phli" ],
+ 59 : [ "Inscriptional Parthian", "Prti" ],
+ 60 : [ "Javanese", "Java" ],
+ 61 : [ "Kaithi", "Kthi" ],
+ 62 : [ "Katakana", "Kana" ],
+ 63 : [ "Kayah Li", "Kali" ],
+ 64 : [ "Kharoshthi", "Khar" ],
+ 65 : [ "Lanna", "Lana" ],
+ 66 : [ "Lepcha", "Lepc" ],
+ 67 : [ "Limbu", "Limb" ],
+ 68 : [ "Linear B", "Linb" ],
+ 69 : [ "Lycian", "Lyci" ],
+ 70 : [ "Lydian", "Lydi" ],
+ 71 : [ "Mandaean", "Mand" ],
+ 72 : [ "Meitei Mayek", "Mtei" ],
+ 73 : [ "Meroitic", "Mero" ],
+ 74 : [ "Meroitic Cursive", "Merc" ],
+ 75 : [ "Nko", "Nkoo" ],
+ 76 : [ "New Tai Lue", "Talu" ],
+ 77 : [ "Ogham", "Ogam" ],
+ 78 : [ "Ol Chiki", "Olck" ],
+ 79 : [ "Old Italic", "Ital" ],
+ 80 : [ "Old Persian", "Xpeo" ],
+ 81 : [ "Old South Arabian", "Sarb" ],
+ 82 : [ "Orkhon", "Orkh" ],
+ 83 : [ "Osmanya", "Osma" ],
+ 84 : [ "Phags Pa", "Phag" ],
+ 85 : [ "Phoenician", "Phnx" ],
+ 86 : [ "Pollard Phonetic", "Plrd" ],
+ 87 : [ "Rejang", "Rjng" ],
+ 88 : [ "Runic", "Runr" ],
+ 89 : [ "Samaritan", "Samr" ],
+ 90 : [ "Saurashtra", "Saur" ],
+ 91 : [ "Sharada", "Shrd" ],
+ 92 : [ "Shavian", "Shaw" ],
+ 93 : [ "Sora Sompeng", "Sora" ],
+ 94 : [ "Cuneiform", "Xsux" ],
+ 95 : [ "Sundanese", "Sund" ],
+ 96 : [ "Syloti Nagri", "Sylo" ],
+ 97 : [ "Tagalog", "Tglg" ],
+ 98 : [ "Tagbanwa", "Tagb" ],
+ 99 : [ "Tai Le", "Tale" ],
+ 100 : [ "Tai Viet", "Tavt" ],
+ 101 : [ "Takri", "Takr" ],
+ 102 : [ "Ugaritic", "Ugar" ],
+ 103 : [ "Braille", "Brai" ],
+ 104 : [ "Hiragana", "Hira" ]
+
+# ### : [ "Blissymbols", "Blis" ],
+# ### : [ "Linear A", "Lina" ],
+# ### : [ "Naxi Geba", "Nkgb" ],
+# ### : [ "Pahawh Hmong", "Hmng" ],
+# ### : [ "Varang Kshiti", "Wara" ],
}
def countryCodeToId(code):
diff --git a/util/local_database/qlocalexml2cpp.py b/util/local_database/qlocalexml2cpp.py
index d3120d256f..f52979f6b6 100755
--- a/util/local_database/qlocalexml2cpp.py
+++ b/util/local_database/qlocalexml2cpp.py
@@ -554,7 +554,7 @@ def main():
if to_language != 0:
cmnt_to = cmnt_to + language_map[to_language][1]
else:
- cmnt_from = cmnt_from + "und"
+ cmnt_to = cmnt_to + "und"
if to_script != 0:
if cmnt_to:
cmnt_to = cmnt_to + "_"
@@ -899,6 +899,7 @@ def main():
qlocaleh_temp_file.write(" RhaetoRomance = Romansh,\n")
qlocaleh_temp_file.write(" Chewa = Nyanja,\n")
qlocaleh_temp_file.write(" Frisian = WesternFrisian,\n")
+ qlocaleh_temp_file.write(" Uigur = Uighur,\n")
qlocaleh_temp_file.write(" LastLanguage = " + language + "\n")
qlocaleh_temp_file.write(" };\n")
diff --git a/util/unicode/main.cpp b/util/unicode/main.cpp
index 6a134695f9..5affaeb59f 100644
--- a/util/unicode/main.cpp
+++ b/util/unicode/main.cpp
@@ -540,6 +540,137 @@ static void initLineBreak()
}
+static QHash<QByteArray, QChar::Script> scriptMap;
+
+static void initScriptMap()
+{
+ struct Scrpt {
+ QChar::Script script;
+ const char *name;
+ } scripts[] = {
+ // general
+ { QChar::Script_Unknown, "Unknown" },
+ { QChar::Script_Inherited, "Inherited" },
+ { QChar::Script_Common, "Common" },
+ // pre-4.0
+ { QChar::Script_Latin, "Latin" },
+ { QChar::Script_Greek, "Greek" },
+ { QChar::Script_Cyrillic, "Cyrillic" },
+ { QChar::Script_Armenian, "Armenian" },
+ { QChar::Script_Hebrew, "Hebrew" },
+ { QChar::Script_Arabic, "Arabic" },
+ { QChar::Script_Syriac, "Syriac" },
+ { QChar::Script_Thaana, "Thaana" },
+ { QChar::Script_Devanagari, "Devanagari" },
+ { QChar::Script_Bengali, "Bengali" },
+ { QChar::Script_Gurmukhi, "Gurmukhi" },
+ { QChar::Script_Gujarati, "Gujarati" },
+ { QChar::Script_Oriya, "Oriya" },
+ { QChar::Script_Tamil, "Tamil" },
+ { QChar::Script_Telugu, "Telugu" },
+ { QChar::Script_Kannada, "Kannada" },
+ { QChar::Script_Malayalam, "Malayalam" },
+ { QChar::Script_Sinhala, "Sinhala" },
+ { QChar::Script_Thai, "Thai" },
+ { QChar::Script_Lao, "Lao" },
+ { QChar::Script_Tibetan, "Tibetan" },
+ { QChar::Script_Myanmar, "Myanmar" },
+ { QChar::Script_Georgian, "Georgian" },
+ { QChar::Script_Hangul, "Hangul" },
+ { QChar::Script_Ethiopic, "Ethiopic" },
+ { QChar::Script_Cherokee, "Cherokee" },
+ { QChar::Script_CanadianAboriginal, "CanadianAboriginal" },
+ { QChar::Script_Ogham, "Ogham" },
+ { QChar::Script_Runic, "Runic" },
+ { QChar::Script_Khmer, "Khmer" },
+ { QChar::Script_Mongolian, "Mongolian" },
+ { QChar::Script_Hiragana, "Hiragana" },
+ { QChar::Script_Katakana, "Katakana" },
+ { QChar::Script_Bopomofo, "Bopomofo" },
+ { QChar::Script_Han, "Han" },
+ { QChar::Script_Yi, "Yi" },
+ { QChar::Script_OldItalic, "OldItalic" },
+ { QChar::Script_Gothic, "Gothic" },
+ { QChar::Script_Deseret, "Deseret" },
+ { QChar::Script_Tagalog, "Tagalog" },
+ { QChar::Script_Hanunoo, "Hanunoo" },
+ { QChar::Script_Buhid, "Buhid" },
+ { QChar::Script_Tagbanwa, "Tagbanwa" },
+ { QChar::Script_Coptic, "Coptic" },
+ // 4.0
+ { QChar::Script_Limbu, "Limbu" },
+ { QChar::Script_TaiLe, "TaiLe" },
+ { QChar::Script_LinearB, "LinearB" },
+ { QChar::Script_Ugaritic, "Ugaritic" },
+ { QChar::Script_Shavian, "Shavian" },
+ { QChar::Script_Osmanya, "Osmanya" },
+ { QChar::Script_Cypriot, "Cypriot" },
+ { QChar::Script_Braille, "Braille" },
+ // 4.1
+ { QChar::Script_Buginese, "Buginese" },
+ { QChar::Script_NewTaiLue, "NewTaiLue" },
+ { QChar::Script_Glagolitic, "Glagolitic" },
+ { QChar::Script_Tifinagh, "Tifinagh" },
+ { QChar::Script_SylotiNagri, "SylotiNagri" },
+ { QChar::Script_OldPersian, "OldPersian" },
+ { QChar::Script_Kharoshthi, "Kharoshthi" },
+ // 5.0
+ { QChar::Script_Balinese, "Balinese" },
+ { QChar::Script_Cuneiform, "Cuneiform" },
+ { QChar::Script_Phoenician, "Phoenician" },
+ { QChar::Script_PhagsPa, "PhagsPa" },
+ { QChar::Script_Nko, "Nko" },
+ // 5.1
+ { QChar::Script_Sundanese, "Sundanese" },
+ { QChar::Script_Lepcha, "Lepcha" },
+ { QChar::Script_OlChiki, "OlChiki" },
+ { QChar::Script_Vai, "Vai" },
+ { QChar::Script_Saurashtra, "Saurashtra" },
+ { QChar::Script_KayahLi, "KayahLi" },
+ { QChar::Script_Rejang, "Rejang" },
+ { QChar::Script_Lycian, "Lycian" },
+ { QChar::Script_Carian, "Carian" },
+ { QChar::Script_Lydian, "Lydian" },
+ { QChar::Script_Cham, "Cham" },
+ // 5.2
+ { QChar::Script_TaiTham, "TaiTham" },
+ { QChar::Script_TaiViet, "TaiViet" },
+ { QChar::Script_Avestan, "Avestan" },
+ { QChar::Script_EgyptianHieroglyphs, "EgyptianHieroglyphs" },
+ { QChar::Script_Samaritan, "Samaritan" },
+ { QChar::Script_Lisu, "Lisu" },
+ { QChar::Script_Bamum, "Bamum" },
+ { QChar::Script_Javanese, "Javanese" },
+ { QChar::Script_MeeteiMayek, "MeeteiMayek" },
+ { QChar::Script_ImperialAramaic, "ImperialAramaic" },
+ { QChar::Script_OldSouthArabian, "OldSouthArabian" },
+ { QChar::Script_InscriptionalParthian, "InscriptionalParthian" },
+ { QChar::Script_InscriptionalPahlavi, "InscriptionalPahlavi" },
+ { QChar::Script_OldTurkic, "OldTurkic" },
+ { QChar::Script_Kaithi, "Kaithi" },
+ // 6.0
+ { QChar::Script_Batak, "Batak" },
+ { QChar::Script_Brahmi, "Brahmi" },
+ { QChar::Script_Mandaic, "Mandaic" },
+ // 6.1
+ { QChar::Script_Chakma, "Chakma" },
+ { QChar::Script_MeroiticCursive, "MeroiticCursive" },
+ { QChar::Script_MeroiticHieroglyphs, "MeroiticHieroglyphs" },
+ { QChar::Script_Miao, "Miao" },
+ { QChar::Script_Sharada, "Sharada" },
+ { QChar::Script_SoraSompeng, "SoraSompeng" },
+ { QChar::Script_Takri, "Takri" },
+ // unhandled
+ { QChar::Script_Unknown, 0 }
+ };
+ Scrpt *p = scripts;
+ while (p->name) {
+ scriptMap.insert(p->name, p->script);
+ ++p;
+ }
+}
+
+
// Keep this one in sync with the code in createPropertyInfo
static const char *property_string =
"struct Properties {\n"
@@ -562,7 +693,7 @@ static const char *property_string =
" ushort wordBreakClass : 8; /* 4 used */\n"
" ushort sentenceBreakClass : 8; /* 4 used */\n"
" ushort lineBreakClass : 8; /* 6 used */\n"
- " ushort script : 8; /* 5 used */\n"
+ " ushort script : 8; /* 7 used */\n"
"};\n\n"
"Q_CORE_EXPORT const Properties * QT_FASTCALL properties(uint ucs4);\n"
"Q_CORE_EXPORT const Properties * QT_FASTCALL properties(ushort ucs2);\n"
@@ -584,10 +715,6 @@ static const char *methods =
"Q_CORE_EXPORT LineBreakClass QT_FASTCALL lineBreakClass(uint ucs4);\n"
"inline LineBreakClass lineBreakClass(QChar ch)\n"
"{ return lineBreakClass(ch.unicode()); }\n"
- "\n"
- "Q_CORE_EXPORT Script QT_FASTCALL script(uint ucs4);\n"
- "inline Script script(QChar ch)\n"
- "{ return script(ch.unicode()); }\n"
"\n";
static const int SizeOfPropertiesStruct = 20;
@@ -745,7 +872,7 @@ struct UnicodeData {
p.graphemeBreakClass = GraphemeBreak_Other;
p.wordBreakClass = WordBreak_Other;
p.sentenceBreakClass = SentenceBreak_Other;
- p.script = 0; // Common
+ p.script = QChar::Script_Unknown;
propertyIndex = -1;
excludedComposition = false;
}
@@ -1830,42 +1957,6 @@ static void readBlocks()
}
#endif
-static QList<QByteArray> scriptNames;
-static QList<int> scriptMap;
-
-static const char *specialScripts[] = {
- "Common",
- "Greek",
- "Cyrillic",
- "Armenian",
- "Hebrew",
- "Arabic",
- "Syriac",
- "Thaana",
- "Devanagari",
- "Bengali",
- "Gurmukhi",
- "Gujarati",
- "Oriya",
- "Tamil",
- "Telugu",
- "Kannada",
- "Malayalam",
- "Sinhala",
- "Thai",
- "Lao",
- "Tibetan",
- "Myanmar",
- "Georgian",
- "Hangul",
- "Ogham",
- "Runic",
- "Khmer",
- "Nko",
- "Inherited"
-};
-enum { specialScriptsCount = sizeof(specialScripts) / sizeof(const char *) };
-
static void readScripts()
{
qDebug("Reading Scripts.txt");
@@ -1876,13 +1967,6 @@ static void readScripts()
f.open(QFile::ReadOnly);
- int scriptsCount = specialScriptsCount;
- // ### preserve the old ordering (temporary)
- for (int i = 0; i < specialScriptsCount; ++i) {
- scriptNames.append(specialScripts[i]);
- scriptMap.append(i);
- }
-
while (!f.atEnd()) {
QByteArray line = f.readLine();
line.resize(line.size() - 1);
@@ -1914,57 +1998,17 @@ static void readScripts()
Q_ASSERT(ok);
}
- int scriptIndex = scriptNames.indexOf(scriptName);
- if (scriptIndex == -1) {
- scriptIndex = scriptNames.size();
- scriptNames.append(scriptName);
-
- // is the script alias for 'Common'?
- int s = specialScriptsCount;
- while (--s > 0) {
- if (scriptName == specialScripts[s])
- break;
- }
- scriptMap.append(s > 0 ? scriptsCount++ : 0);
- }
+ if (!scriptMap.contains(scriptName))
+ qFatal("Unhandled script property value: %s", scriptName.constData());
+ QChar::Script script = scriptMap.value(scriptName, QChar::Script_Unknown);
for (int codepoint = first; codepoint <= last; ++codepoint) {
UnicodeData &ud = UnicodeData::valueRef(codepoint);
- ud.p.script = scriptMap.at(scriptIndex);
+ ud.p.script = script;
}
}
}
-static QByteArray createScriptEnumDeclaration()
-{
- QByteArray declaration;
-
- declaration += "// See http://www.unicode.org/reports/tr24/tr24-5.html\n";
- declaration += "enum Script {\n Common";
-
- // output the ones with special processing first
- for (int i = 1; i < scriptNames.size(); ++i) {
- if (scriptMap.at(i) == 0)
- continue;
- declaration += ",\n ";
- declaration += scriptNames.at(i);
- }
- declaration += ",\n ScriptCount = Inherited";
-
- // output the ones that are an alias for 'Common'
- for (int i = 1; i < scriptNames.size(); ++i) {
- if (scriptMap.at(i) != 0)
- continue;
- declaration += ",\n ";
- declaration += scriptNames.at(i);
- declaration += " = Common";
- }
-
- declaration += "\n};\n\n";
-
- return declaration;
-}
-
#if 0
static void dump(int from, int to)
{
@@ -2214,7 +2258,7 @@ static QByteArray createPropertyInfo()
out += ", ";
out += QByteArray::number( p.lineBreakClass );
out += ", ";
-// " ushort script : 8; /* 5 used */\n"
+// " ushort script : 8; /* 7 used */\n"
out += QByteArray::number( p.script );
out += " },";
}
@@ -2263,11 +2307,7 @@ static QByteArray createPropertyInfo()
"{\n"
" return (LineBreakClass)qGetProp(ucs4)->lineBreakClass;\n"
"}\n"
- "\n"
- "Q_CORE_EXPORT Script QT_FASTCALL script(uint ucs4)\n"
- "{\n"
- " return (Script)qGetProp(ucs4)->script;\n"
- "}\n\n";
+ "\n";
return out;
}
@@ -2725,6 +2765,7 @@ int main(int, char **)
initWordBreak();
initSentenceBreak();
initLineBreak();
+ initScriptMap();
readUnicodeData();
readBidiMirroring();
@@ -2746,7 +2787,6 @@ int main(int, char **)
QByteArray compositions = createCompositionInfo();
QByteArray ligatures = createLigatureInfo();
QByteArray normalizationCorrections = createNormalizationCorrections();
- QByteArray scriptEnumDeclaration = createScriptEnumDeclaration();
QByteArray header =
"/****************************************************************************\n"
@@ -2837,7 +2877,6 @@ int main(int, char **)
f.write("#define UNICODE_DATA_VERSION "DATA_VERSION_STR"\n\n");
f.write("namespace QUnicodeTables {\n\n");
f.write(property_string);
- f.write(scriptEnumDeclaration);
f.write(grapheme_break_class_string);
f.write(word_break_class_string);
f.write(sentence_break_class_string);